From 537fa2cff891bbe0526090a77324354f5a0377da Mon Sep 17 00:00:00 2001 From: Anatoliy Belsky Date: Thu, 31 Jan 2013 20:32:02 +0100 Subject: [PATCH] readded clean 9.2.2 source with deleted .gitignore and patched libpq stuff --- .gitignore | 32 - README.md | 24 + _int.vcxproj | 154 - adminpack.vcxproj | 149 - ascii_and_mic.vcxproj | 149 - auth_delay.vcxproj | 149 - auto_explain.vcxproj | 149 - autoinc.vcxproj | 149 - btree_gin.vcxproj | 149 - btree_gist.vcxproj | 168 - chkpass.vcxproj | 149 - citext.vcxproj | 149 - clusterdb.vcxproj | 147 - contrib/btree_gin/.gitignore | 4 - contrib/btree_gist/.gitignore | 4 - contrib/citext/.gitignore | 4 - contrib/cube/.gitignore | 6 - contrib/cube/cubeparse.c | 1779 + contrib/cube/cubescan.c | 1855 + contrib/dblink/.gitignore | 4 - contrib/dict_int/.gitignore | 4 - contrib/dict_xsyn/.gitignore | 4 - contrib/earthdistance/.gitignore | 4 - contrib/file_fdw/.gitignore | 4 - contrib/file_fdw/expected/.gitignore | 1 - contrib/file_fdw/sql/.gitignore | 1 - contrib/hstore/.gitignore | 4 - contrib/intarray/.gitignore | 4 - contrib/ltree/.gitignore | 4 - contrib/oid2name/.gitignore | 1 - contrib/pg_archivecleanup/.gitignore | 1 - contrib/pg_standby/.gitignore | 1 - contrib/pg_test_fsync/.gitignore | 1 - contrib/pg_test_timing/.gitignore | 1 - contrib/pg_trgm/.gitignore | 4 - contrib/pg_upgrade/.gitignore | 6 - contrib/pgbench/.gitignore | 1 - contrib/pgcrypto/.gitignore | 4 - contrib/pgstattuple/.gitignore | 4 - contrib/seg/.gitignore | 6 - contrib/seg/segparse.c | 1718 + contrib/seg/segscan.c | 1855 + contrib/sepgsql/.gitignore | 7 - contrib/tablefunc/.gitignore | 4 - contrib/test_parser/.gitignore | 4 - contrib/tsearch2/.gitignore | 4 - contrib/unaccent/.gitignore | 4 - contrib/vacuumlo/.gitignore | 1 - contrib/xml2/.gitignore | 4 - createdb.vcxproj | 147 - createlang.vcxproj | 146 - createuser.vcxproj | 147 - cube.vcxproj | 172 - cyrillic_and_mic.vcxproj | 149 - dblink.vcxproj | 152 - dict_int.vcxproj | 149 - dict_snowball.vcxproj | 182 - dict_xsyn.vcxproj | 149 - doc/src/sgml/.gitignore | 33 - doc/src/sgml/html-stamp | 0 doc/src/sgml/html/LEGALNOTICE.html | 129 + doc/src/sgml/html/acronyms.html | 1279 + doc/src/sgml/html/admin.html | 830 + doc/src/sgml/html/adminpack.html | 205 + doc/src/sgml/html/app-clusterdb.html | 755 + doc/src/sgml/html/app-createdb.html | 881 + doc/src/sgml/html/app-createlang.html | 711 + doc/src/sgml/html/app-createuser.html | 1016 + doc/src/sgml/html/app-dropdb.html | 670 + doc/src/sgml/html/app-droplang.html | 702 + doc/src/sgml/html/app-dropuser.html | 665 + doc/src/sgml/html/app-ecpg.html | 593 + doc/src/sgml/html/app-initdb.html | 964 + doc/src/sgml/html/app-pg-ctl.html | 1507 + doc/src/sgml/html/app-pg-dumpall.html | 1171 + doc/src/sgml/html/app-pgbasebackup.html | 1092 + doc/src/sgml/html/app-pgconfig.html | 713 + doc/src/sgml/html/app-pgcontroldata.html | 273 + doc/src/sgml/html/app-pgdump.html | 2290 + doc/src/sgml/html/app-pgreceivexlog.html | 678 + doc/src/sgml/html/app-pgresetxlog.html | 604 + doc/src/sgml/html/app-pgrestore.html | 1747 + doc/src/sgml/html/app-postgres.html | 1710 + doc/src/sgml/html/app-postmaster.html | 228 + doc/src/sgml/html/app-psql.html | 7539 +++ doc/src/sgml/html/app-reindexdb.html | 832 + doc/src/sgml/html/app-vacuumdb.html | 900 + doc/src/sgml/html/appendixes.html | 1716 + doc/src/sgml/html/applevel-consistency.html | 419 + .../sgml/html/archive-recovery-settings.html | 357 + doc/src/sgml/html/arrays.html | 1221 + doc/src/sgml/html/auth-delay.html | 245 + doc/src/sgml/html/auth-methods.html | 1748 + doc/src/sgml/html/auth-pg-hba-conf.html | 1396 + doc/src/sgml/html/auth-username-maps.html | 444 + doc/src/sgml/html/auto-explain.html | 464 + doc/src/sgml/html/backup-dump.html | 858 + doc/src/sgml/html/backup-file.html | 347 + doc/src/sgml/html/backup.html | 291 + doc/src/sgml/html/biblio.html | 738 + doc/src/sgml/html/bki-commands.html | 710 + doc/src/sgml/html/bki-example.html | 199 + doc/src/sgml/html/bki-format.html | 210 + doc/src/sgml/html/bki-structure.html | 311 + doc/src/sgml/html/bki.html | 275 + doc/src/sgml/html/bookindex.html | 18228 ++++++ doc/src/sgml/html/btree-gin.html | 300 + doc/src/sgml/html/btree-gist.html | 419 + doc/src/sgml/html/bug-reporting.html | 753 + doc/src/sgml/html/catalog-pg-aggregate.html | 394 + doc/src/sgml/html/catalog-pg-am.html | 890 + doc/src/sgml/html/catalog-pg-amop.html | 534 + doc/src/sgml/html/catalog-pg-amproc.html | 356 + doc/src/sgml/html/catalog-pg-attrdef.html | 314 + doc/src/sgml/html/catalog-pg-attribute.html | 711 + .../sgml/html/catalog-pg-auth-members.html | 324 + doc/src/sgml/html/catalog-pg-authid.html | 463 + doc/src/sgml/html/catalog-pg-cast.html | 433 + doc/src/sgml/html/catalog-pg-class.html | 934 + doc/src/sgml/html/catalog-pg-collation.html | 402 + doc/src/sgml/html/catalog-pg-constraint.html | 860 + doc/src/sgml/html/catalog-pg-conversion.html | 354 + doc/src/sgml/html/catalog-pg-database.html | 506 + .../sgml/html/catalog-pg-db-role-setting.html | 289 + doc/src/sgml/html/catalog-pg-default-acl.html | 360 + doc/src/sgml/html/catalog-pg-depend.html | 544 + doc/src/sgml/html/catalog-pg-description.html | 320 + doc/src/sgml/html/catalog-pg-enum.html | 307 + doc/src/sgml/html/catalog-pg-extension.html | 389 + .../html/catalog-pg-foreign-data-wrapper.html | 357 + .../sgml/html/catalog-pg-foreign-server.html | 356 + .../sgml/html/catalog-pg-foreign-table.html | 293 + doc/src/sgml/html/catalog-pg-index.html | 633 + doc/src/sgml/html/catalog-pg-inherits.html | 283 + doc/src/sgml/html/catalog-pg-language.html | 424 + .../html/catalog-pg-largeobject-metadata.html | 269 + doc/src/sgml/html/catalog-pg-largeobject.html | 331 + doc/src/sgml/html/catalog-pg-namespace.html | 279 + doc/src/sgml/html/catalog-pg-opclass.html | 435 + doc/src/sgml/html/catalog-pg-operator.html | 559 + doc/src/sgml/html/catalog-pg-opfamily.html | 345 + doc/src/sgml/html/catalog-pg-pltemplate.html | 377 + doc/src/sgml/html/catalog-pg-proc.html | 953 + doc/src/sgml/html/catalog-pg-range.html | 391 + doc/src/sgml/html/catalog-pg-rewrite.html | 422 + doc/src/sgml/html/catalog-pg-seclabel.html | 328 + doc/src/sgml/html/catalog-pg-shdepend.html | 471 + .../sgml/html/catalog-pg-shdescription.html | 301 + doc/src/sgml/html/catalog-pg-shseclabel.html | 314 + doc/src/sgml/html/catalog-pg-statistic.html | 614 + doc/src/sgml/html/catalog-pg-tablespace.html | 310 + doc/src/sgml/html/catalog-pg-trigger.html | 624 + .../sgml/html/catalog-pg-ts-config-map.html | 311 + doc/src/sgml/html/catalog-pg-ts-config.html | 325 + doc/src/sgml/html/catalog-pg-ts-dict.html | 337 + doc/src/sgml/html/catalog-pg-ts-parser.html | 390 + doc/src/sgml/html/catalog-pg-ts-template.html | 315 + doc/src/sgml/html/catalog-pg-type.html | 1454 + .../sgml/html/catalog-pg-user-mapping.html | 287 + doc/src/sgml/html/catalogs-overview.html | 809 + doc/src/sgml/html/catalogs.html | 764 + doc/src/sgml/html/charset.html | 284 + doc/src/sgml/html/chkpass.html | 262 + doc/src/sgml/html/citext.html | 633 + .../html/client-authentication-problems.html | 225 + doc/src/sgml/html/client-authentication.html | 337 + doc/src/sgml/html/client-interfaces.html | 965 + doc/src/sgml/html/collation.html | 632 + doc/src/sgml/html/config-setting.html | 528 + doc/src/sgml/html/connect-estab.html | 243 + doc/src/sgml/html/continuous-archiving.html | 1772 + .../html/contrib-dblink-build-sql-delete.html | 330 + .../html/contrib-dblink-build-sql-insert.html | 347 + .../html/contrib-dblink-build-sql-update.html | 356 + .../html/contrib-dblink-cancel-query.html | 252 + doc/src/sgml/html/contrib-dblink-close.html | 315 + .../sgml/html/contrib-dblink-connect-u.html | 250 + doc/src/sgml/html/contrib-dblink-connect.html | 387 + .../sgml/html/contrib-dblink-disconnect.html | 259 + .../html/contrib-dblink-error-message.html | 241 + doc/src/sgml/html/contrib-dblink-exec.html | 335 + doc/src/sgml/html/contrib-dblink-fetch.html | 352 + .../sgml/html/contrib-dblink-function.html | 457 + .../html/contrib-dblink-get-connections.html | 217 + .../sgml/html/contrib-dblink-get-notify.html | 276 + .../sgml/html/contrib-dblink-get-pkey.html | 288 + .../sgml/html/contrib-dblink-get-result.html | 380 + doc/src/sgml/html/contrib-dblink-is-busy.html | 244 + doc/src/sgml/html/contrib-dblink-open.html | 359 + .../sgml/html/contrib-dblink-send-query.html | 272 + doc/src/sgml/html/contrib-prog-client.html | 224 + doc/src/sgml/html/contrib-prog-server.html | 250 + doc/src/sgml/html/contrib-prog.html | 220 + doc/src/sgml/html/contrib-spi.html | 515 + doc/src/sgml/html/contrib.html | 565 + doc/src/sgml/html/creating-cluster.html | 526 + doc/src/sgml/html/cube.html | 996 + doc/src/sgml/html/database-roles.html | 323 + doc/src/sgml/html/datatype-binary.html | 724 + doc/src/sgml/html/datatype-bit.html | 317 + doc/src/sgml/html/datatype-boolean.html | 423 + doc/src/sgml/html/datatype-character.html | 704 + doc/src/sgml/html/datatype-datetime.html | 3023 + doc/src/sgml/html/datatype-enum.html | 342 + doc/src/sgml/html/datatype-geometric.html | 1022 + doc/src/sgml/html/datatype-json.html | 209 + doc/src/sgml/html/datatype-money.html | 302 + doc/src/sgml/html/datatype-net-types.html | 710 + doc/src/sgml/html/datatype-numeric.html | 1207 + doc/src/sgml/html/datatype-oid.html | 585 + doc/src/sgml/html/datatype-pseudo.html | 443 + doc/src/sgml/html/datatype-textsearch.html | 526 + doc/src/sgml/html/datatype-uuid.html | 227 + doc/src/sgml/html/datatype-xml.html | 535 + doc/src/sgml/html/datatype.html | 1317 + doc/src/sgml/html/datetime-appendix.html | 212 + doc/src/sgml/html/datetime-config-files.html | 412 + doc/src/sgml/html/datetime-input-rules.html | 399 + doc/src/sgml/html/datetime-keywords.html | 430 + doc/src/sgml/html/datetime-units-history.html | 339 + doc/src/sgml/html/dblink.html | 286 + doc/src/sgml/html/ddl-alter.html | 511 + doc/src/sgml/html/ddl-basics.html | 346 + doc/src/sgml/html/ddl-constraints.html | 924 + doc/src/sgml/html/ddl-default.html | 262 + doc/src/sgml/html/ddl-depend.html | 284 + doc/src/sgml/html/ddl-foreign-data.html | 232 + doc/src/sgml/html/ddl-inherit.html | 705 + doc/src/sgml/html/ddl-others.html | 202 + doc/src/sgml/html/ddl-partitioning.html | 1021 + doc/src/sgml/html/ddl-priv.html | 335 + doc/src/sgml/html/ddl-schemas.html | 801 + doc/src/sgml/html/ddl-system-columns.html | 402 + doc/src/sgml/html/ddl.html | 393 + doc/src/sgml/html/dict-int.html | 284 + doc/src/sgml/html/dict-xsyn.html | 384 + .../html/different-replication-solutions.html | 718 + doc/src/sgml/html/disk-full.html | 196 + doc/src/sgml/html/disk-usage.html | 289 + doc/src/sgml/html/diskusage.html | 188 + doc/src/sgml/html/dml-delete.html | 200 + doc/src/sgml/html/dml-insert.html | 272 + doc/src/sgml/html/dml-update.html | 285 + doc/src/sgml/html/dml.html | 194 + doc/src/sgml/html/docguide-authoring.html | 367 + doc/src/sgml/html/docguide-build.html | 953 + doc/src/sgml/html/docguide-docbook.html | 219 + doc/src/sgml/html/docguide-style.html | 357 + doc/src/sgml/html/docguide-toolsets.html | 1138 + doc/src/sgml/html/docguide.html | 254 + doc/src/sgml/html/dummy-seclabel.html | 270 + doc/src/sgml/html/dynamic-trace.html | 1220 + doc/src/sgml/html/earthdistance.html | 516 + doc/src/sgml/html/ecpg-commands.html | 547 + doc/src/sgml/html/ecpg-concept.html | 264 + doc/src/sgml/html/ecpg-connect.html | 666 + doc/src/sgml/html/ecpg-cpp.html | 553 + doc/src/sgml/html/ecpg-descriptors.html | 1824 + doc/src/sgml/html/ecpg-develop.html | 448 + doc/src/sgml/html/ecpg-dynamic.html | 347 + doc/src/sgml/html/ecpg-errors.html | 1408 + doc/src/sgml/html/ecpg-informix-compat.html | 2782 + doc/src/sgml/html/ecpg-library.html | 355 + doc/src/sgml/html/ecpg-lo.html | 311 + doc/src/sgml/html/ecpg-pgtypes.html | 3286 + doc/src/sgml/html/ecpg-preproc.html | 602 + doc/src/sgml/html/ecpg-process.html | 304 + .../html/ecpg-sql-allocate-descriptor.html | 277 + doc/src/sgml/html/ecpg-sql-commands.html | 272 + doc/src/sgml/html/ecpg-sql-connect.html | 578 + .../html/ecpg-sql-deallocate-descriptor.html | 270 + doc/src/sgml/html/ecpg-sql-declare.html | 354 + doc/src/sgml/html/ecpg-sql-describe.html | 322 + doc/src/sgml/html/ecpg-sql-disconnect.html | 327 + .../sgml/html/ecpg-sql-execute-immediate.html | 268 + .../sgml/html/ecpg-sql-get-descriptor.html | 451 + doc/src/sgml/html/ecpg-sql-open.html | 328 + doc/src/sgml/html/ecpg-sql-prepare.html | 294 + .../sgml/html/ecpg-sql-set-autocommit.html | 220 + .../sgml/html/ecpg-sql-set-connection.html | 283 + .../sgml/html/ecpg-sql-set-descriptor.html | 369 + doc/src/sgml/html/ecpg-sql-type.html | 355 + doc/src/sgml/html/ecpg-sql-var.html | 269 + doc/src/sgml/html/ecpg-sql-whenever.html | 284 + doc/src/sgml/html/ecpg-variables.html | 2020 + doc/src/sgml/html/ecpg.html | 623 + doc/src/sgml/html/encryption-options.html | 319 + doc/src/sgml/html/errcodes-appendix.html | 3515 ++ .../sgml/html/error-message-reporting.html | 675 + doc/src/sgml/html/error-style-guide.html | 744 + doc/src/sgml/html/event-log-registration.html | 277 + doc/src/sgml/html/executor.html | 311 + doc/src/sgml/html/explicit-joins.html | 434 + doc/src/sgml/html/explicit-locking.html | 1240 + doc/src/sgml/html/extend-extensions.html | 1308 + doc/src/sgml/html/extend-how.html | 241 + doc/src/sgml/html/extend-pgxs.html | 739 + doc/src/sgml/html/extend-type-system.html | 478 + doc/src/sgml/html/extend.html | 650 + doc/src/sgml/html/external-admin-tools.html | 179 + doc/src/sgml/html/external-extensions.html | 202 + doc/src/sgml/html/external-interfaces.html | 337 + doc/src/sgml/html/external-pl.html | 311 + doc/src/sgml/html/external-projects.html | 206 + doc/src/sgml/html/fdw-callbacks.html | 579 + doc/src/sgml/html/fdw-functions.html | 230 + doc/src/sgml/html/fdw-helpers.html | 312 + doc/src/sgml/html/fdw-planning.html | 466 + doc/src/sgml/html/fdwhandler.html | 229 + doc/src/sgml/html/features-sql-standard.html | 3764 ++ doc/src/sgml/html/features.html | 359 + doc/src/sgml/html/file-fdw.html | 479 + doc/src/sgml/html/functions-admin.html | 2927 + doc/src/sgml/html/functions-aggregate.html | 1711 + doc/src/sgml/html/functions-array.html | 998 + doc/src/sgml/html/functions-binarystring.html | 946 + doc/src/sgml/html/functions-bitstring.html | 485 + doc/src/sgml/html/functions-comparison.html | 714 + doc/src/sgml/html/functions-comparisons.html | 762 + doc/src/sgml/html/functions-conditional.html | 666 + doc/src/sgml/html/functions-datetime.html | 3217 + doc/src/sgml/html/functions-enum.html | 335 + doc/src/sgml/html/functions-formatting.html | 2436 + doc/src/sgml/html/functions-geometry.html | 1711 + doc/src/sgml/html/functions-info.html | 3653 ++ doc/src/sgml/html/functions-json.html | 254 + doc/src/sgml/html/functions-logical.html | 412 + doc/src/sgml/html/functions-matching.html | 4381 ++ doc/src/sgml/html/functions-math.html | 1803 + doc/src/sgml/html/functions-net.html | 1087 + doc/src/sgml/html/functions-range.html | 875 + doc/src/sgml/html/functions-sequence.html | 715 + doc/src/sgml/html/functions-srf.html | 565 + doc/src/sgml/html/functions-string.html | 5187 ++ doc/src/sgml/html/functions-subquery.html | 854 + doc/src/sgml/html/functions-textsearch.html | 1703 + doc/src/sgml/html/functions-trigger.html | 220 + doc/src/sgml/html/functions-window.html | 811 + doc/src/sgml/html/functions-xml.html | 1533 + doc/src/sgml/html/functions.html | 620 + doc/src/sgml/html/fuzzystrmatch.html | 428 + doc/src/sgml/html/geqo-biblio.html | 227 + doc/src/sgml/html/geqo-intro.html | 231 + doc/src/sgml/html/geqo-intro2.html | 301 + doc/src/sgml/html/geqo-pg-intro.html | 407 + doc/src/sgml/html/geqo.html | 239 + doc/src/sgml/html/gin-examples.html | 241 + doc/src/sgml/html/gin-extensibility.html | 653 + doc/src/sgml/html/gin-implementation.html | 313 + doc/src/sgml/html/gin-intro.html | 256 + doc/src/sgml/html/gin-limit.html | 181 + doc/src/sgml/html/gin-tips.html | 296 + doc/src/sgml/html/gin.html | 215 + doc/src/sgml/html/gist-examples.html | 269 + doc/src/sgml/html/gist-extensibility.html | 1058 + doc/src/sgml/html/gist-implementation.html | 209 + doc/src/sgml/html/gist-intro.html | 213 + doc/src/sgml/html/gist.html | 191 + doc/src/sgml/html/git.html | 269 + doc/src/sgml/html/high-availability.html | 363 + doc/src/sgml/html/history.html | 633 + doc/src/sgml/html/hot-standby.html | 1424 + doc/src/sgml/html/hstore.html | 1603 + doc/src/sgml/html/index-catalog.html | 381 + doc/src/sgml/html/index-cost-estimation.html | 472 + doc/src/sgml/html/index-functions.html | 842 + doc/src/sgml/html/index-locking.html | 341 + doc/src/sgml/html/index-scanning.html | 466 + doc/src/sgml/html/index-unique-checks.html | 364 + doc/src/sgml/html/index.html | 623 + doc/src/sgml/html/indexam.html | 266 + doc/src/sgml/html/indexes-bitmap-scans.html | 301 + doc/src/sgml/html/indexes-collations.html | 211 + doc/src/sgml/html/indexes-examine.html | 312 + doc/src/sgml/html/indexes-expressional.html | 247 + doc/src/sgml/html/indexes-intro.html | 308 + doc/src/sgml/html/indexes-multicolumn.html | 300 + doc/src/sgml/html/indexes-opclass.html | 379 + doc/src/sgml/html/indexes-ordering.html | 327 + doc/src/sgml/html/indexes-partial.html | 479 + doc/src/sgml/html/indexes-types.html | 654 + doc/src/sgml/html/indexes-unique.html | 226 + doc/src/sgml/html/indexes.html | 242 + doc/src/sgml/html/information-schema.html | 745 + ...ema-administrable-role-authorizations.html | 257 + .../html/infoschema-applicable-roles.html | 266 + doc/src/sgml/html/infoschema-attributes.html | 811 + .../sgml/html/infoschema-character-sets.html | 425 + ...schema-check-constraint-routine-usage.html | 301 + .../html/infoschema-check-constraints.html | 266 + ...hema-collation-character-set-applicab.html | 299 + doc/src/sgml/html/infoschema-collations.html | 272 + .../html/infoschema-column-domain-usage.html | 307 + .../sgml/html/infoschema-column-options.html | 294 + .../html/infoschema-column-privileges.html | 362 + .../html/infoschema-column-udt-usage.html | 322 + doc/src/sgml/html/infoschema-columns.html | 1103 + .../infoschema-constraint-column-usage.html | 320 + .../infoschema-constraint-table-usage.html | 307 + .../html/infoschema-data-type-privileges.html | 306 + doc/src/sgml/html/infoschema-datatypes.html | 261 + .../html/infoschema-domain-constraints.html | 334 + .../html/infoschema-domain-udt-usage.html | 298 + doc/src/sgml/html/infoschema-domains.html | 713 + .../sgml/html/infoschema-element-types.html | 739 + .../sgml/html/infoschema-enabled-roles.html | 244 + ...foschema-foreign-data-wrapper-options.html | 267 + .../infoschema-foreign-data-wrappers.html | 281 + .../infoschema-foreign-server-options.html | 266 + .../sgml/html/infoschema-foreign-servers.html | 309 + .../infoschema-foreign-table-options.html | 308 + .../sgml/html/infoschema-foreign-tables.html | 280 + ...chema-information-schema-catalog-name.html | 220 + .../html/infoschema-key-column-usage.html | 350 + doc/src/sgml/html/infoschema-parameters.html | 754 + .../infoschema-referential-constraints.html | 397 + .../html/infoschema-role-column-grants.html | 356 + .../html/infoschema-role-routine-grants.html | 379 + .../html/infoschema-role-table-grants.html | 387 + .../sgml/html/infoschema-role-udt-grants.html | 338 + .../html/infoschema-role-usage-grants.html | 363 + .../html/infoschema-routine-privileges.html | 366 + doc/src/sgml/html/infoschema-routines.html | 1678 + doc/src/sgml/html/infoschema-schema.html | 182 + doc/src/sgml/html/infoschema-schemata.html | 318 + doc/src/sgml/html/infoschema-sequences.html | 424 + .../sgml/html/infoschema-sql-features.html | 331 + .../infoschema-sql-implementation-info.html | 296 + .../sgml/html/infoschema-sql-languages.html | 351 + .../sgml/html/infoschema-sql-packages.html | 301 + doc/src/sgml/html/infoschema-sql-parts.html | 299 + .../html/infoschema-sql-sizing-profiles.html | 290 + doc/src/sgml/html/infoschema-sql-sizing.html | 276 + .../html/infoschema-table-constraints.html | 365 + .../html/infoschema-table-privileges.html | 374 + doc/src/sgml/html/infoschema-tables.html | 423 + .../infoschema-triggered-update-columns.html | 319 + doc/src/sgml/html/infoschema-triggers.html | 625 + .../sgml/html/infoschema-udt-privileges.html | 329 + .../html/infoschema-usage-privileges.html | 386 + .../html/infoschema-user-defined-types.html | 722 + .../html/infoschema-user-mapping-options.html | 294 + .../sgml/html/infoschema-user-mappings.html | 258 + .../html/infoschema-view-column-usage.html | 330 + .../html/infoschema-view-routine-usage.html | 305 + .../html/infoschema-view-table-usage.html | 314 + doc/src/sgml/html/infoschema-views.html | 419 + doc/src/sgml/html/install-getsource.html | 210 + doc/src/sgml/html/install-post.html | 463 + doc/src/sgml/html/install-procedure.html | 2307 + doc/src/sgml/html/install-requirements.html | 765 + doc/src/sgml/html/install-short.html | 183 + doc/src/sgml/html/install-windows-full.html | 975 + doc/src/sgml/html/install-windows-libpq.html | 389 + doc/src/sgml/html/install-windows.html | 382 + .../html/installation-platform-notes.html | 1756 + doc/src/sgml/html/installation.html | 272 + doc/src/sgml/html/intagg.html | 336 + doc/src/sgml/html/intarray.html | 972 + doc/src/sgml/html/internals.html | 1188 + doc/src/sgml/html/intro-whatis.html | 275 + doc/src/sgml/html/isn.html | 784 + doc/src/sgml/html/kernel-resources.html | 1819 + doc/src/sgml/html/largeobjects.html | 287 + doc/src/sgml/html/libpq-async.html | 1030 + doc/src/sgml/html/libpq-build.html | 352 + doc/src/sgml/html/libpq-cancel.html | 389 + doc/src/sgml/html/libpq-connect.html | 2489 + doc/src/sgml/html/libpq-control.html | 385 + doc/src/sgml/html/libpq-copy.html | 1113 + doc/src/sgml/html/libpq-envars.html | 633 + doc/src/sgml/html/libpq-events.html | 1167 + doc/src/sgml/html/libpq-example.html | 680 + doc/src/sgml/html/libpq-exec.html | 3151 + doc/src/sgml/html/libpq-fastpath.html | 304 + doc/src/sgml/html/libpq-ldap.html | 320 + doc/src/sgml/html/libpq-misc.html | 716 + .../sgml/html/libpq-notice-processing.html | 310 + doc/src/sgml/html/libpq-notify.html | 369 + doc/src/sgml/html/libpq-pgpass.html | 278 + doc/src/sgml/html/libpq-pgservice.html | 225 + doc/src/sgml/html/libpq-single-row-mode.html | 341 + doc/src/sgml/html/libpq-ssl.html | 1052 + doc/src/sgml/html/libpq-status.html | 975 + doc/src/sgml/html/libpq-threading.html | 322 + doc/src/sgml/html/libpq.html | 495 + doc/src/sgml/html/lo-examplesect.html | 448 + doc/src/sgml/html/lo-funcs.html | 230 + doc/src/sgml/html/lo-implementation.html | 205 + doc/src/sgml/html/lo-interfaces.html | 818 + doc/src/sgml/html/lo-intro.html | 194 + doc/src/sgml/html/lo.html | 358 + doc/src/sgml/html/locale.html | 688 + doc/src/sgml/html/locking-indexes.html | 236 + .../sgml/html/log-shipping-alternative.html | 452 + doc/src/sgml/html/logfile-maintenance.html | 365 + doc/src/sgml/html/ltree.html | 1947 + doc/src/sgml/html/maintenance.html | 307 + doc/src/sgml/html/manage-ag-config.html | 217 + doc/src/sgml/html/manage-ag-createdb.html | 367 + doc/src/sgml/html/manage-ag-dropdb.html | 225 + doc/src/sgml/html/manage-ag-overview.html | 267 + doc/src/sgml/html/manage-ag-tablespaces.html | 409 + doc/src/sgml/html/manage-ag-templatedbs.html | 429 + doc/src/sgml/html/managing-databases.html | 218 + doc/src/sgml/html/monitoring-locks.html | 221 + doc/src/sgml/html/monitoring-ps.html | 322 + doc/src/sgml/html/monitoring-stats.html | 3765 ++ doc/src/sgml/html/monitoring.html | 282 + doc/src/sgml/html/multibyte.html | 2578 + doc/src/sgml/html/mvcc-intro.html | 237 + doc/src/sgml/html/mvcc.html | 265 + doc/src/sgml/html/nls-programmer.html | 508 + doc/src/sgml/html/nls-translator.html | 621 + doc/src/sgml/html/nls.html | 219 + doc/src/sgml/html/non-durability.html | 249 + doc/src/sgml/html/notation.html | 261 + doc/src/sgml/html/oid2name.html | 732 + doc/src/sgml/html/overview.html | 255 + doc/src/sgml/html/pageinspect.html | 423 + doc/src/sgml/html/parser-stage.html | 430 + doc/src/sgml/html/passwordcheck.html | 277 + doc/src/sgml/html/performance-tips.html | 303 + doc/src/sgml/html/perm-functions.html | 191 + doc/src/sgml/html/pgarchivecleanup.html | 561 + doc/src/sgml/html/pgbench.html | 1838 + doc/src/sgml/html/pgbuffercache.html | 481 + doc/src/sgml/html/pgcrypto.html | 2352 + doc/src/sgml/html/pgfreespacemap.html | 312 + doc/src/sgml/html/pgrowlocks.html | 396 + doc/src/sgml/html/pgstandby.html | 897 + doc/src/sgml/html/pgstatstatements.html | 933 + doc/src/sgml/html/pgstattuple.html | 651 + doc/src/sgml/html/pgtestfsync.html | 358 + doc/src/sgml/html/pgtesttiming.html | 552 + doc/src/sgml/html/pgtrgm.html | 707 + doc/src/sgml/html/pgupgrade.html | 1422 + doc/src/sgml/html/planner-optimizer.html | 383 + doc/src/sgml/html/planner-stats-details.html | 181 + doc/src/sgml/html/planner-stats.html | 426 + doc/src/sgml/html/plhandler.html | 540 + doc/src/sgml/html/plperl-builtins.html | 985 + doc/src/sgml/html/plperl-data.html | 180 + doc/src/sgml/html/plperl-funcs.html | 610 + doc/src/sgml/html/plperl-global.html | 256 + doc/src/sgml/html/plperl-triggers.html | 436 + doc/src/sgml/html/plperl-trusted.html | 333 + doc/src/sgml/html/plperl-under-the-hood.html | 426 + doc/src/sgml/html/plperl.html | 303 + .../sgml/html/plpgsql-control-structures.html | 2703 + doc/src/sgml/html/plpgsql-cursors.html | 1385 + doc/src/sgml/html/plpgsql-declarations.html | 1076 + .../sgml/html/plpgsql-development-tips.html | 450 + .../html/plpgsql-errors-and-messages.html | 615 + doc/src/sgml/html/plpgsql-expressions.html | 274 + doc/src/sgml/html/plpgsql-implementation.html | 795 + doc/src/sgml/html/plpgsql-overview.html | 473 + doc/src/sgml/html/plpgsql-porting.html | 1342 + doc/src/sgml/html/plpgsql-statements.html | 1592 + doc/src/sgml/html/plpgsql-structure.html | 396 + doc/src/sgml/html/plpgsql-trigger.html | 1002 + doc/src/sgml/html/plpgsql.html | 431 + doc/src/sgml/html/plpython-data.html | 788 + doc/src/sgml/html/plpython-database.html | 766 + doc/src/sgml/html/plpython-do.html | 180 + doc/src/sgml/html/plpython-envar.html | 263 + doc/src/sgml/html/plpython-funcs.html | 308 + doc/src/sgml/html/plpython-python23.html | 351 + doc/src/sgml/html/plpython-sharing.html | 192 + .../sgml/html/plpython-subtransaction.html | 354 + doc/src/sgml/html/plpython-trigger.html | 365 + doc/src/sgml/html/plpython-util.html | 330 + doc/src/sgml/html/plpython.html | 370 + doc/src/sgml/html/pltcl-data.html | 178 + doc/src/sgml/html/pltcl-dbaccess.html | 751 + doc/src/sgml/html/pltcl-functions.html | 334 + doc/src/sgml/html/pltcl-global.html | 241 + doc/src/sgml/html/pltcl-overview.html | 277 + doc/src/sgml/html/pltcl-procnames.html | 187 + doc/src/sgml/html/pltcl-trigger.html | 497 + doc/src/sgml/html/pltcl-unknown.html | 261 + doc/src/sgml/html/pltcl.html | 230 + doc/src/sgml/html/populate.html | 825 + doc/src/sgml/html/postgres-user.html | 197 + doc/src/sgml/html/preface.html | 324 + .../sgml/html/preventing-server-spoofing.html | 234 + doc/src/sgml/html/protocol-changes.html | 294 + doc/src/sgml/html/protocol-error-fields.html | 344 + doc/src/sgml/html/protocol-flow.html | 1571 + .../sgml/html/protocol-message-formats.html | 2460 + doc/src/sgml/html/protocol-message-types.html | 314 + doc/src/sgml/html/protocol-overview.html | 374 + doc/src/sgml/html/protocol-replication.html | 773 + doc/src/sgml/html/protocol.html | 335 + doc/src/sgml/html/queries-limit.html | 334 + doc/src/sgml/html/queries-order.html | 415 + doc/src/sgml/html/queries-overview.html | 299 + doc/src/sgml/html/queries-select-lists.html | 468 + .../sgml/html/queries-table-expressions.html | 1919 + doc/src/sgml/html/queries-union.html | 353 + doc/src/sgml/html/queries-values.html | 303 + doc/src/sgml/html/queries-with.html | 996 + doc/src/sgml/html/queries.html | 309 + doc/src/sgml/html/query-path.html | 309 + doc/src/sgml/html/querytree.html | 517 + doc/src/sgml/html/rangetypes.html | 1048 + doc/src/sgml/html/recovery-config.html | 225 + .../sgml/html/recovery-target-settings.html | 388 + doc/src/sgml/html/reference-client.html | 378 + doc/src/sgml/html/reference-server.html | 262 + doc/src/sgml/html/reference.html | 1212 + doc/src/sgml/html/regress-coverage.html | 203 + doc/src/sgml/html/regress-evaluation.html | 521 + doc/src/sgml/html/regress-run.html | 549 + doc/src/sgml/html/regress-variant.html | 360 + doc/src/sgml/html/regress.html | 274 + doc/src/sgml/html/release-0-01.html | 181 + doc/src/sgml/html/release-0-02.html | 228 + doc/src/sgml/html/release-0-03.html | 297 + doc/src/sgml/html/release-1-0.html | 231 + doc/src/sgml/html/release-1-01.html | 424 + doc/src/sgml/html/release-1-02.html | 336 + doc/src/sgml/html/release-1-09.html | 177 + doc/src/sgml/html/release-6-0.html | 319 + doc/src/sgml/html/release-6-1-1.html | 217 + doc/src/sgml/html/release-6-1.html | 381 + doc/src/sgml/html/release-6-2-1.html | 253 + doc/src/sgml/html/release-6-2.html | 338 + doc/src/sgml/html/release-6-3-1.html | 258 + doc/src/sgml/html/release-6-3-2.html | 245 + doc/src/sgml/html/release-6-3.html | 567 + doc/src/sgml/html/release-6-4-1.html | 237 + doc/src/sgml/html/release-6-4-2.html | 208 + doc/src/sgml/html/release-6-4.html | 505 + doc/src/sgml/html/release-6-5-1.html | 233 + doc/src/sgml/html/release-6-5-2.html | 234 + doc/src/sgml/html/release-6-5-3.html | 216 + doc/src/sgml/html/release-6-5.html | 656 + doc/src/sgml/html/release-7-0-1.html | 233 + doc/src/sgml/html/release-7-0-2.html | 210 + doc/src/sgml/html/release-7-0-3.html | 248 + doc/src/sgml/html/release-7-0.html | 721 + doc/src/sgml/html/release-7-1-1.html | 223 + doc/src/sgml/html/release-7-1-2.html | 214 + doc/src/sgml/html/release-7-1-3.html | 216 + doc/src/sgml/html/release-7-1.html | 461 + doc/src/sgml/html/release-7-2-1.html | 272 + doc/src/sgml/html/release-7-2-2.html | 263 + doc/src/sgml/html/release-7-2-3.html | 236 + doc/src/sgml/html/release-7-2-4.html | 241 + doc/src/sgml/html/release-7-2-5.html | 247 + doc/src/sgml/html/release-7-2-6.html | 236 + doc/src/sgml/html/release-7-2-7.html | 240 + doc/src/sgml/html/release-7-2-8.html | 260 + doc/src/sgml/html/release-7-2.html | 1688 + doc/src/sgml/html/release-7-3-1.html | 281 + doc/src/sgml/html/release-7-3-10.html | 393 + doc/src/sgml/html/release-7-3-11.html | 273 + doc/src/sgml/html/release-7-3-12.html | 236 + doc/src/sgml/html/release-7-3-13.html | 275 + doc/src/sgml/html/release-7-3-14.html | 250 + doc/src/sgml/html/release-7-3-15.html | 347 + doc/src/sgml/html/release-7-3-16.html | 236 + doc/src/sgml/html/release-7-3-17.html | 246 + doc/src/sgml/html/release-7-3-18.html | 229 + doc/src/sgml/html/release-7-3-19.html | 239 + doc/src/sgml/html/release-7-3-2.html | 334 + doc/src/sgml/html/release-7-3-20.html | 239 + doc/src/sgml/html/release-7-3-21.html | 339 + doc/src/sgml/html/release-7-3-3.html | 648 + doc/src/sgml/html/release-7-3-4.html | 244 + doc/src/sgml/html/release-7-3-5.html | 288 + doc/src/sgml/html/release-7-3-6.html | 268 + doc/src/sgml/html/release-7-3-7.html | 222 + doc/src/sgml/html/release-7-3-8.html | 232 + doc/src/sgml/html/release-7-3-9.html | 257 + doc/src/sgml/html/release-7-3.html | 1899 + doc/src/sgml/html/release-7-4-1.html | 428 + doc/src/sgml/html/release-7-4-10.html | 250 + doc/src/sgml/html/release-7-4-11.html | 285 + doc/src/sgml/html/release-7-4-12.html | 267 + doc/src/sgml/html/release-7-4-13.html | 382 + doc/src/sgml/html/release-7-4-14.html | 250 + doc/src/sgml/html/release-7-4-15.html | 289 + doc/src/sgml/html/release-7-4-16.html | 243 + doc/src/sgml/html/release-7-4-17.html | 258 + doc/src/sgml/html/release-7-4-18.html | 261 + doc/src/sgml/html/release-7-4-19.html | 390 + doc/src/sgml/html/release-7-4-2.html | 466 + doc/src/sgml/html/release-7-4-20.html | 385 + doc/src/sgml/html/release-7-4-21.html | 243 + doc/src/sgml/html/release-7-4-22.html | 266 + doc/src/sgml/html/release-7-4-23.html | 268 + doc/src/sgml/html/release-7-4-24.html | 285 + doc/src/sgml/html/release-7-4-25.html | 262 + doc/src/sgml/html/release-7-4-26.html | 338 + doc/src/sgml/html/release-7-4-27.html | 301 + doc/src/sgml/html/release-7-4-28.html | 325 + doc/src/sgml/html/release-7-4-29.html | 369 + doc/src/sgml/html/release-7-4-3.html | 293 + doc/src/sgml/html/release-7-4-30.html | 317 + doc/src/sgml/html/release-7-4-4.html | 270 + doc/src/sgml/html/release-7-4-5.html | 214 + doc/src/sgml/html/release-7-4-6.html | 299 + doc/src/sgml/html/release-7-4-7.html | 267 + doc/src/sgml/html/release-7-4-8.html | 532 + doc/src/sgml/html/release-7-4-9.html | 339 + doc/src/sgml/html/release-7-4.html | 3322 + doc/src/sgml/html/release-8-0-1.html | 302 + doc/src/sgml/html/release-8-0-10.html | 317 + doc/src/sgml/html/release-8-0-11.html | 243 + doc/src/sgml/html/release-8-0-12.html | 214 + doc/src/sgml/html/release-8-0-13.html | 263 + doc/src/sgml/html/release-8-0-14.html | 291 + doc/src/sgml/html/release-8-0-15.html | 476 + doc/src/sgml/html/release-8-0-16.html | 511 + doc/src/sgml/html/release-8-0-17.html | 243 + doc/src/sgml/html/release-8-0-18.html | 336 + doc/src/sgml/html/release-8-0-19.html | 297 + doc/src/sgml/html/release-8-0-2.html | 581 + doc/src/sgml/html/release-8-0-20.html | 282 + doc/src/sgml/html/release-8-0-21.html | 262 + doc/src/sgml/html/release-8-0-22.html | 394 + doc/src/sgml/html/release-8-0-23.html | 340 + doc/src/sgml/html/release-8-0-24.html | 387 + doc/src/sgml/html/release-8-0-25.html | 389 + doc/src/sgml/html/release-8-0-26.html | 404 + doc/src/sgml/html/release-8-0-3.html | 422 + doc/src/sgml/html/release-8-0-4.html | 449 + doc/src/sgml/html/release-8-0-5.html | 310 + doc/src/sgml/html/release-8-0-6.html | 322 + doc/src/sgml/html/release-8-0-7.html | 376 + doc/src/sgml/html/release-8-0-8.html | 399 + doc/src/sgml/html/release-8-0-9.html | 296 + doc/src/sgml/html/release-8-0.html | 3536 ++ doc/src/sgml/html/release-8-1-1.html | 349 + doc/src/sgml/html/release-8-1-10.html | 308 + doc/src/sgml/html/release-8-1-11.html | 522 + doc/src/sgml/html/release-8-1-12.html | 531 + doc/src/sgml/html/release-8-1-13.html | 266 + doc/src/sgml/html/release-8-1-14.html | 390 + doc/src/sgml/html/release-8-1-15.html | 362 + doc/src/sgml/html/release-8-1-16.html | 314 + doc/src/sgml/html/release-8-1-17.html | 320 + doc/src/sgml/html/release-8-1-18.html | 394 + doc/src/sgml/html/release-8-1-19.html | 368 + doc/src/sgml/html/release-8-1-2.html | 368 + doc/src/sgml/html/release-8-1-20.html | 401 + doc/src/sgml/html/release-8-1-21.html | 381 + doc/src/sgml/html/release-8-1-22.html | 416 + doc/src/sgml/html/release-8-1-23.html | 454 + doc/src/sgml/html/release-8-1-3.html | 438 + doc/src/sgml/html/release-8-1-4.html | 487 + doc/src/sgml/html/release-8-1-5.html | 369 + doc/src/sgml/html/release-8-1-6.html | 349 + doc/src/sgml/html/release-8-1-7.html | 275 + doc/src/sgml/html/release-8-1-8.html | 214 + doc/src/sgml/html/release-8-1-9.html | 278 + doc/src/sgml/html/release-8-1.html | 3316 + doc/src/sgml/html/release-8-2-1.html | 339 + doc/src/sgml/html/release-8-2-10.html | 458 + doc/src/sgml/html/release-8-2-11.html | 411 + doc/src/sgml/html/release-8-2-12.html | 385 + doc/src/sgml/html/release-8-2-13.html | 393 + doc/src/sgml/html/release-8-2-14.html | 462 + doc/src/sgml/html/release-8-2-15.html | 433 + doc/src/sgml/html/release-8-2-16.html | 503 + doc/src/sgml/html/release-8-2-17.html | 432 + doc/src/sgml/html/release-8-2-18.html | 498 + doc/src/sgml/html/release-8-2-19.html | 496 + doc/src/sgml/html/release-8-2-2.html | 348 + doc/src/sgml/html/release-8-2-20.html | 360 + doc/src/sgml/html/release-8-2-21.html | 318 + doc/src/sgml/html/release-8-2-22.html | 533 + doc/src/sgml/html/release-8-2-23.html | 483 + doc/src/sgml/html/release-8-2-3.html | 217 + doc/src/sgml/html/release-8-2-4.html | 346 + doc/src/sgml/html/release-8-2-5.html | 388 + doc/src/sgml/html/release-8-2-6.html | 573 + doc/src/sgml/html/release-8-2-7.html | 510 + doc/src/sgml/html/release-8-2-8.html | 449 + doc/src/sgml/html/release-8-2-9.html | 266 + doc/src/sgml/html/release-8-2.html | 4106 ++ doc/src/sgml/html/release-8-3-1.html | 577 + doc/src/sgml/html/release-8-3-10.html | 569 + doc/src/sgml/html/release-8-3-11.html | 468 + doc/src/sgml/html/release-8-3-12.html | 590 + doc/src/sgml/html/release-8-3-13.html | 534 + doc/src/sgml/html/release-8-3-14.html | 360 + doc/src/sgml/html/release-8-3-15.html | 350 + doc/src/sgml/html/release-8-3-16.html | 611 + doc/src/sgml/html/release-8-3-17.html | 534 + doc/src/sgml/html/release-8-3-18.html | 524 + doc/src/sgml/html/release-8-3-19.html | 445 + doc/src/sgml/html/release-8-3-2.html | 691 + doc/src/sgml/html/release-8-3-20.html | 466 + doc/src/sgml/html/release-8-3-21.html | 309 + doc/src/sgml/html/release-8-3-22.html | 568 + doc/src/sgml/html/release-8-3-3.html | 266 + doc/src/sgml/html/release-8-3-4.html | 609 + doc/src/sgml/html/release-8-3-5.html | 507 + doc/src/sgml/html/release-8-3-6.html | 508 + doc/src/sgml/html/release-8-3-7.html | 488 + doc/src/sgml/html/release-8-3-8.html | 552 + doc/src/sgml/html/release-8-3-9.html | 537 + doc/src/sgml/html/release-8-3.html | 3902 ++ doc/src/sgml/html/release-8-4-1.html | 578 + doc/src/sgml/html/release-8-4-10.html | 584 + doc/src/sgml/html/release-8-4-11.html | 606 + doc/src/sgml/html/release-8-4-12.html | 514 + doc/src/sgml/html/release-8-4-13.html | 522 + doc/src/sgml/html/release-8-4-14.html | 314 + doc/src/sgml/html/release-8-4-15.html | 573 + doc/src/sgml/html/release-8-4-2.html | 846 + doc/src/sgml/html/release-8-4-3.html | 738 + doc/src/sgml/html/release-8-4-4.html | 563 + doc/src/sgml/html/release-8-4-5.html | 783 + doc/src/sgml/html/release-8-4-6.html | 577 + doc/src/sgml/html/release-8-4-7.html | 360 + doc/src/sgml/html/release-8-4-8.html | 466 + doc/src/sgml/html/release-8-4-9.html | 793 + doc/src/sgml/html/release-8-4.html | 5247 ++ doc/src/sgml/html/release-9-0-1.html | 314 + doc/src/sgml/html/release-9-0-10.html | 345 + doc/src/sgml/html/release-9-0-11.html | 661 + doc/src/sgml/html/release-9-0-2.html | 733 + doc/src/sgml/html/release-9-0-3.html | 409 + doc/src/sgml/html/release-9-0-4.html | 587 + doc/src/sgml/html/release-9-0-5.html | 959 + doc/src/sgml/html/release-9-0-6.html | 657 + doc/src/sgml/html/release-9-0-7.html | 797 + doc/src/sgml/html/release-9-0-8.html | 565 + doc/src/sgml/html/release-9-0-9.html | 614 + doc/src/sgml/html/release-9-0.html | 5351 ++ doc/src/sgml/html/release-9-1-1.html | 244 + doc/src/sgml/html/release-9-1-2.html | 1029 + doc/src/sgml/html/release-9-1-3.html | 965 + doc/src/sgml/html/release-9-1-4.html | 789 + doc/src/sgml/html/release-9-1-5.html | 719 + doc/src/sgml/html/release-9-1-6.html | 507 + doc/src/sgml/html/release-9-1-7.html | 778 + doc/src/sgml/html/release-9-1.html | 4663 ++ doc/src/sgml/html/release-9-2-1.html | 397 + doc/src/sgml/html/release-9-2-2.html | 1136 + doc/src/sgml/html/release-9-2.html | 4527 ++ doc/src/sgml/html/release.html | 1364 + doc/src/sgml/html/resources.html | 258 + doc/src/sgml/html/role-attributes.html | 429 + doc/src/sgml/html/role-membership.html | 464 + doc/src/sgml/html/routine-reindex.html | 192 + doc/src/sgml/html/routine-vacuuming.html | 1441 + .../sgml/html/row-estimation-examples.html | 831 + doc/src/sgml/html/rowtypes.html | 625 + doc/src/sgml/html/rule-system.html | 248 + doc/src/sgml/html/rules-privileges.html | 463 + doc/src/sgml/html/rules-status.html | 243 + doc/src/sgml/html/rules-triggers.html | 412 + doc/src/sgml/html/rules-update.html | 1396 + doc/src/sgml/html/rules-views.html | 1088 + doc/src/sgml/html/rules.html | 297 + .../sgml/html/runtime-config-autovacuum.html | 535 + doc/src/sgml/html/runtime-config-client.html | 1547 + .../sgml/html/runtime-config-compatible.html | 767 + .../sgml/html/runtime-config-connection.html | 1103 + doc/src/sgml/html/runtime-config-custom.html | 193 + .../sgml/html/runtime-config-developer.html | 716 + .../html/runtime-config-error-handling.html | 216 + .../html/runtime-config-file-locations.html | 388 + doc/src/sgml/html/runtime-config-locks.html | 337 + doc/src/sgml/html/runtime-config-logging.html | 2468 + doc/src/sgml/html/runtime-config-preset.html | 514 + doc/src/sgml/html/runtime-config-query.html | 1156 + .../sgml/html/runtime-config-replication.html | 742 + .../sgml/html/runtime-config-resource.html | 1155 + doc/src/sgml/html/runtime-config-short.html | 571 + .../sgml/html/runtime-config-statistics.html | 468 + doc/src/sgml/html/runtime-config-wal.html | 1203 + doc/src/sgml/html/runtime-config.html | 478 + doc/src/sgml/html/runtime.html | 332 + doc/src/sgml/html/seg.html | 958 + doc/src/sgml/html/sepgsql.html | 1386 + doc/src/sgml/html/server-programming.html | 666 + doc/src/sgml/html/server-shutdown.html | 340 + doc/src/sgml/html/server-start.html | 663 + doc/src/sgml/html/source-format.html | 270 + doc/src/sgml/html/source.html | 270 + doc/src/sgml/html/sourcerepo.html | 208 + doc/src/sgml/html/spgist-examples.html | 180 + doc/src/sgml/html/spgist-extensibility.html | 1209 + doc/src/sgml/html/spgist-implementation.html | 382 + doc/src/sgml/html/spgist-intro.html | 231 + doc/src/sgml/html/spgist.html | 213 + doc/src/sgml/html/spi-examples.html | 342 + doc/src/sgml/html/spi-interface-support.html | 227 + doc/src/sgml/html/spi-interface.html | 335 + doc/src/sgml/html/spi-memory.html | 363 + doc/src/sgml/html/spi-realloc.html | 263 + doc/src/sgml/html/spi-spi-connect.html | 274 + doc/src/sgml/html/spi-spi-copytuple.html | 250 + doc/src/sgml/html/spi-spi-cursor-close.html | 232 + doc/src/sgml/html/spi-spi-cursor-fetch.html | 301 + doc/src/sgml/html/spi-spi-cursor-find.html | 240 + doc/src/sgml/html/spi-spi-cursor-move.html | 279 + .../html/spi-spi-cursor-open-with-args.html | 412 + .../spi-spi-cursor-open-with-paramlist.html | 322 + doc/src/sgml/html/spi-spi-cursor-open.html | 367 + doc/src/sgml/html/spi-spi-exec.html | 265 + doc/src/sgml/html/spi-spi-execp.html | 342 + .../spi-spi-execute-plan-with-paramlist.html | 329 + doc/src/sgml/html/spi-spi-execute-plan.html | 418 + .../sgml/html/spi-spi-execute-with-args.html | 423 + doc/src/sgml/html/spi-spi-execute.html | 777 + doc/src/sgml/html/spi-spi-finish.html | 247 + doc/src/sgml/html/spi-spi-fname.html | 270 + doc/src/sgml/html/spi-spi-fnumber.html | 273 + doc/src/sgml/html/spi-spi-freeplan.html | 256 + doc/src/sgml/html/spi-spi-freetuple.html | 232 + doc/src/sgml/html/spi-spi-freetupletable.html | 246 + doc/src/sgml/html/spi-spi-getargcount.html | 263 + doc/src/sgml/html/spi-spi-getargtypeid.html | 292 + doc/src/sgml/html/spi-spi-getbinval.html | 307 + doc/src/sgml/html/spi-spi-getnspname.html | 244 + doc/src/sgml/html/spi-spi-getrelname.html | 239 + doc/src/sgml/html/spi-spi-gettype.html | 266 + doc/src/sgml/html/spi-spi-gettypeid.html | 272 + doc/src/sgml/html/spi-spi-getvalue.html | 302 + doc/src/sgml/html/spi-spi-is-cursor-plan.html | 314 + doc/src/sgml/html/spi-spi-keepplan.html | 271 + doc/src/sgml/html/spi-spi-modifytuple.html | 411 + doc/src/sgml/html/spi-spi-palloc.html | 235 + doc/src/sgml/html/spi-spi-pfree.html | 239 + doc/src/sgml/html/spi-spi-pop.html | 196 + doc/src/sgml/html/spi-spi-prepare-cursor.html | 361 + doc/src/sgml/html/spi-spi-prepare-params.html | 302 + doc/src/sgml/html/spi-spi-prepare.html | 442 + doc/src/sgml/html/spi-spi-push.html | 235 + doc/src/sgml/html/spi-spi-returntuple.html | 289 + doc/src/sgml/html/spi-spi-saveplan.html | 314 + .../html/spi-spi-scroll-cursor-fetch.html | 347 + .../sgml/html/spi-spi-scroll-cursor-move.html | 352 + doc/src/sgml/html/spi-visibility.html | 230 + doc/src/sgml/html/spi.html | 556 + doc/src/sgml/html/sql-abort.html | 303 + doc/src/sgml/html/sql-alteraggregate.html | 427 + doc/src/sgml/html/sql-altercollation.html | 367 + doc/src/sgml/html/sql-alterconversion.html | 367 + doc/src/sgml/html/sql-alterdatabase.html | 562 + .../sgml/html/sql-alterdefaultprivileges.html | 537 + doc/src/sgml/html/sql-alterdomain.html | 716 + doc/src/sgml/html/sql-alterextension.html | 836 + .../html/sql-alterforeigndatawrapper.html | 482 + doc/src/sgml/html/sql-alterforeigntable.html | 830 + doc/src/sgml/html/sql-alterfunction.html | 837 + doc/src/sgml/html/sql-altergroup.html | 370 + doc/src/sgml/html/sql-alterindex.html | 521 + doc/src/sgml/html/sql-alterlanguage.html | 299 + doc/src/sgml/html/sql-alterlargeobject.html | 273 + doc/src/sgml/html/sql-alteropclass.html | 363 + doc/src/sgml/html/sql-alteroperator.html | 381 + doc/src/sgml/html/sql-alteropfamily.html | 789 + doc/src/sgml/html/sql-alterrole.html | 783 + doc/src/sgml/html/sql-alterschema.html | 316 + doc/src/sgml/html/sql-altersequence.html | 830 + doc/src/sgml/html/sql-alterserver.html | 416 + doc/src/sgml/html/sql-altertable.html | 2183 + doc/src/sgml/html/sql-altertablespace.html | 398 + doc/src/sgml/html/sql-altertrigger.html | 334 + doc/src/sgml/html/sql-altertsconfig.html | 540 + doc/src/sgml/html/sql-altertsdictionary.html | 417 + doc/src/sgml/html/sql-altertsparser.html | 301 + doc/src/sgml/html/sql-altertstemplate.html | 301 + doc/src/sgml/html/sql-altertype.html | 731 + doc/src/sgml/html/sql-alteruser.html | 332 + doc/src/sgml/html/sql-alterusermapping.html | 384 + doc/src/sgml/html/sql-alterview.html | 498 + doc/src/sgml/html/sql-analyze.html | 533 + doc/src/sgml/html/sql-begin.html | 425 + doc/src/sgml/html/sql-checkpoint.html | 248 + doc/src/sgml/html/sql-close.html | 356 + doc/src/sgml/html/sql-cluster.html | 522 + doc/src/sgml/html/sql-commands.html | 952 + doc/src/sgml/html/sql-comment.html | 866 + doc/src/sgml/html/sql-commit-prepared.html | 308 + doc/src/sgml/html/sql-commit.html | 291 + doc/src/sgml/html/sql-copy.html | 2024 + doc/src/sgml/html/sql-createaggregate.html | 760 + doc/src/sgml/html/sql-createcast.html | 954 + doc/src/sgml/html/sql-createcollation.html | 433 + doc/src/sgml/html/sql-createconversion.html | 420 + doc/src/sgml/html/sql-createdatabase.html | 687 + doc/src/sgml/html/sql-createdomain.html | 509 + doc/src/sgml/html/sql-createextension.html | 509 + .../html/sql-createforeigndatawrapper.html | 479 + doc/src/sgml/html/sql-createforeigntable.html | 478 + doc/src/sgml/html/sql-createfunction.html | 1509 + doc/src/sgml/html/sql-creategroup.html | 300 + doc/src/sgml/html/sql-createindex.html | 1238 + doc/src/sgml/html/sql-createlanguage.html | 778 + doc/src/sgml/html/sql-createopclass.html | 696 + doc/src/sgml/html/sql-createoperator.html | 661 + doc/src/sgml/html/sql-createopfamily.html | 334 + doc/src/sgml/html/sql-createrole.html | 1096 + doc/src/sgml/html/sql-createrule.html | 749 + doc/src/sgml/html/sql-createschema.html | 477 + doc/src/sgml/html/sql-createsequence.html | 836 + doc/src/sgml/html/sql-createserver.html | 425 + doc/src/sgml/html/sql-createtable.html | 2927 + doc/src/sgml/html/sql-createtableas.html | 788 + doc/src/sgml/html/sql-createtablespace.html | 399 + doc/src/sgml/html/sql-createtrigger.html | 1311 + doc/src/sgml/html/sql-createtsconfig.html | 337 + doc/src/sgml/html/sql-createtsdictionary.html | 351 + doc/src/sgml/html/sql-createtsparser.html | 379 + doc/src/sgml/html/sql-createtstemplate.html | 331 + doc/src/sgml/html/sql-createtype.html | 1964 + doc/src/sgml/html/sql-createuser.html | 328 + doc/src/sgml/html/sql-createusermapping.html | 357 + doc/src/sgml/html/sql-createview.html | 589 + doc/src/sgml/html/sql-deallocate.html | 281 + doc/src/sgml/html/sql-declare.html | 835 + doc/src/sgml/html/sql-delete.html | 738 + doc/src/sgml/html/sql-discard.html | 302 + doc/src/sgml/html/sql-do.html | 347 + doc/src/sgml/html/sql-drop-owned.html | 320 + doc/src/sgml/html/sql-dropaggregate.html | 330 + doc/src/sgml/html/sql-dropcast.html | 316 + doc/src/sgml/html/sql-dropcollation.html | 314 + doc/src/sgml/html/sql-dropconversion.html | 309 + doc/src/sgml/html/sql-dropdatabase.html | 301 + doc/src/sgml/html/sql-dropdomain.html | 309 + doc/src/sgml/html/sql-dropextension.html | 331 + .../sgml/html/sql-dropforeigndatawrapper.html | 312 + doc/src/sgml/html/sql-dropforeigntable.html | 314 + doc/src/sgml/html/sql-dropfunction.html | 401 + doc/src/sgml/html/sql-dropgroup.html | 226 + doc/src/sgml/html/sql-dropindex.html | 347 + doc/src/sgml/html/sql-droplanguage.html | 343 + doc/src/sgml/html/sql-dropopclass.html | 373 + doc/src/sgml/html/sql-dropoperator.html | 376 + doc/src/sgml/html/sql-dropopfamily.html | 351 + doc/src/sgml/html/sql-droprole.html | 336 + doc/src/sgml/html/sql-droprule.html | 317 + doc/src/sgml/html/sql-dropschema.html | 319 + doc/src/sgml/html/sql-dropsequence.html | 316 + doc/src/sgml/html/sql-dropserver.html | 312 + doc/src/sgml/html/sql-droptable.html | 341 + doc/src/sgml/html/sql-droptablespace.html | 313 + doc/src/sgml/html/sql-droptrigger.html | 338 + doc/src/sgml/html/sql-droptsconfig.html | 318 + doc/src/sgml/html/sql-droptsdictionary.html | 314 + doc/src/sgml/html/sql-droptsparser.html | 312 + doc/src/sgml/html/sql-droptstemplate.html | 313 + doc/src/sgml/html/sql-droptype.html | 317 + doc/src/sgml/html/sql-dropuser.html | 231 + doc/src/sgml/html/sql-dropusermapping.html | 330 + doc/src/sgml/html/sql-dropview.html | 309 + doc/src/sgml/html/sql-end.html | 305 + doc/src/sgml/html/sql-execute.html | 343 + doc/src/sgml/html/sql-explain.html | 863 + doc/src/sgml/html/sql-expressions.html | 2276 + doc/src/sgml/html/sql-fetch.html | 957 + doc/src/sgml/html/sql-grant.html | 1354 + doc/src/sgml/html/sql-insert.html | 785 + doc/src/sgml/html/sql-keywords-appendix.html | 11438 ++++ doc/src/sgml/html/sql-listen.html | 386 + doc/src/sgml/html/sql-load.html | 276 + doc/src/sgml/html/sql-lock.html | 650 + doc/src/sgml/html/sql-move.html | 371 + doc/src/sgml/html/sql-notify.html | 515 + .../sgml/html/sql-prepare-transaction.html | 471 + doc/src/sgml/html/sql-prepare.html | 491 + doc/src/sgml/html/sql-reassign-owned.html | 349 + doc/src/sgml/html/sql-reindex.html | 590 + doc/src/sgml/html/sql-release-savepoint.html | 330 + doc/src/sgml/html/sql-reset.html | 340 + doc/src/sgml/html/sql-revoke.html | 800 + doc/src/sgml/html/sql-rollback-prepared.html | 308 + doc/src/sgml/html/sql-rollback-to.html | 397 + doc/src/sgml/html/sql-rollback.html | 293 + doc/src/sgml/html/sql-savepoint.html | 346 + doc/src/sgml/html/sql-security-label.html | 597 + doc/src/sgml/html/sql-select.html | 4402 ++ doc/src/sgml/html/sql-selectinto.html | 517 + doc/src/sgml/html/sql-set-constraints.html | 396 + doc/src/sgml/html/sql-set-role.html | 408 + .../html/sql-set-session-authorization.html | 356 + doc/src/sgml/html/sql-set-transaction.html | 677 + doc/src/sgml/html/sql-set.html | 773 + doc/src/sgml/html/sql-show.html | 450 + doc/src/sgml/html/sql-start-transaction.html | 329 + .../sgml/html/sql-syntax-calling-funcs.html | 393 + doc/src/sgml/html/sql-syntax-lexical.html | 2223 + doc/src/sgml/html/sql-syntax.html | 327 + doc/src/sgml/html/sql-truncate.html | 549 + doc/src/sgml/html/sql-unlisten.html | 360 + doc/src/sgml/html/sql-update.html | 893 + doc/src/sgml/html/sql-vacuum.html | 611 + doc/src/sgml/html/sql-values.html | 667 + doc/src/sgml/html/sql.html | 926 + doc/src/sgml/html/ssh-tunnels.html | 319 + doc/src/sgml/html/ssl-tcp.html | 648 + doc/src/sgml/html/sslinfo.html | 409 + doc/src/sgml/html/standby-settings.html | 303 + doc/src/sgml/html/storage-file-layout.html | 716 + doc/src/sgml/html/storage-fsm.html | 213 + doc/src/sgml/html/storage-init.html | 169 + doc/src/sgml/html/storage-page-layout.html | 754 + doc/src/sgml/html/storage-toast.html | 477 + doc/src/sgml/html/storage-vm.html | 192 + doc/src/sgml/html/storage.html | 207 + doc/src/sgml/html/stylesheet.css | 96 + doc/src/sgml/html/supported-platforms.html | 241 + doc/src/sgml/html/tablefunc.html | 1528 + doc/src/sgml/html/tcn.html | 233 + doc/src/sgml/html/test-parser.html | 260 + .../sgml/html/textsearch-configuration.html | 331 + doc/src/sgml/html/textsearch-controls.html | 1329 + doc/src/sgml/html/textsearch-debugging.html | 918 + .../sgml/html/textsearch-dictionaries.html | 1451 + doc/src/sgml/html/textsearch-features.html | 1167 + doc/src/sgml/html/textsearch-indexes.html | 379 + doc/src/sgml/html/textsearch-intro.html | 876 + doc/src/sgml/html/textsearch-limitations.html | 244 + doc/src/sgml/html/textsearch-migration.html | 275 + doc/src/sgml/html/textsearch-parsers.html | 619 + doc/src/sgml/html/textsearch-psql.html | 427 + doc/src/sgml/html/textsearch-tables.html | 469 + doc/src/sgml/html/textsearch.html | 374 + doc/src/sgml/html/transaction-iso.html | 1038 + doc/src/sgml/html/trigger-datachanges.html | 274 + doc/src/sgml/html/trigger-definition.html | 704 + doc/src/sgml/html/trigger-example.html | 377 + doc/src/sgml/html/trigger-interface.html | 619 + doc/src/sgml/html/triggers.html | 233 + doc/src/sgml/html/tsearch2.html | 514 + doc/src/sgml/html/tutorial-accessdb.html | 428 + .../sgml/html/tutorial-advanced-intro.html | 202 + doc/src/sgml/html/tutorial-advanced.html | 206 + doc/src/sgml/html/tutorial-agg.html | 438 + doc/src/sgml/html/tutorial-arch.html | 251 + doc/src/sgml/html/tutorial-concepts.html | 231 + doc/src/sgml/html/tutorial-conclusion.html | 185 + doc/src/sgml/html/tutorial-createdb.html | 442 + doc/src/sgml/html/tutorial-delete.html | 221 + doc/src/sgml/html/tutorial-fk.html | 248 + doc/src/sgml/html/tutorial-inheritance.html | 363 + doc/src/sgml/html/tutorial-install.html | 233 + doc/src/sgml/html/tutorial-join.html | 452 + doc/src/sgml/html/tutorial-populate.html | 260 + doc/src/sgml/html/tutorial-select.html | 452 + doc/src/sgml/html/tutorial-sql-intro.html | 316 + doc/src/sgml/html/tutorial-sql.html | 219 + doc/src/sgml/html/tutorial-start.html | 191 + doc/src/sgml/html/tutorial-table.html | 335 + doc/src/sgml/html/tutorial-transactions.html | 391 + doc/src/sgml/html/tutorial-update.html | 197 + doc/src/sgml/html/tutorial-views.html | 197 + doc/src/sgml/html/tutorial-window.html | 570 + doc/src/sgml/html/tutorial.html | 345 + doc/src/sgml/html/typeconv-func.html | 585 + doc/src/sgml/html/typeconv-oper.html | 575 + doc/src/sgml/html/typeconv-overview.html | 419 + doc/src/sgml/html/typeconv-query.html | 303 + doc/src/sgml/html/typeconv-union-case.html | 382 + doc/src/sgml/html/typeconv.html | 243 + doc/src/sgml/html/unaccent.html | 402 + .../unsupported-features-sql-standard.html | 3355 + doc/src/sgml/html/upgrading.html | 602 + doc/src/sgml/html/user-manag.html | 233 + doc/src/sgml/html/using-explain.html | 1312 + doc/src/sgml/html/uuid-ossp.html | 434 + doc/src/sgml/html/vacuumlo.html | 505 + .../view-pg-available-extension-versions.html | 344 + .../html/view-pg-available-extensions.html | 284 + doc/src/sgml/html/view-pg-cursors.html | 395 + doc/src/sgml/html/view-pg-group.html | 295 + doc/src/sgml/html/view-pg-indexes.html | 330 + doc/src/sgml/html/view-pg-locks.html | 755 + .../html/view-pg-prepared-statements.html | 338 + doc/src/sgml/html/view-pg-prepared-xacts.html | 337 + doc/src/sgml/html/view-pg-roles.html | 464 + doc/src/sgml/html/view-pg-rules.html | 314 + doc/src/sgml/html/view-pg-seclabels.html | 395 + doc/src/sgml/html/view-pg-settings.html | 695 + doc/src/sgml/html/view-pg-shadow.html | 416 + doc/src/sgml/html/view-pg-stats.html | 557 + doc/src/sgml/html/view-pg-tables.html | 385 + .../sgml/html/view-pg-timezone-abbrevs.html | 255 + doc/src/sgml/html/view-pg-timezone-names.html | 290 + doc/src/sgml/html/view-pg-user-mappings.html | 360 + doc/src/sgml/html/view-pg-user.html | 350 + doc/src/sgml/html/view-pg-views.html | 301 + doc/src/sgml/html/views-overview.html | 471 + doc/src/sgml/html/wal-async-commit.html | 380 + doc/src/sgml/html/wal-configuration.html | 556 + doc/src/sgml/html/wal-internals.html | 294 + doc/src/sgml/html/wal-intro.html | 257 + doc/src/sgml/html/wal-reliability.html | 490 + doc/src/sgml/html/wal.html | 206 + doc/src/sgml/html/warm-standby-failover.html | 251 + doc/src/sgml/html/warm-standby.html | 1173 + doc/src/sgml/html/xaggr.html | 440 + doc/src/sgml/html/xfunc-c.html | 3835 ++ doc/src/sgml/html/xfunc-internal.html | 237 + doc/src/sgml/html/xfunc-overload.html | 278 + doc/src/sgml/html/xfunc-pl.html | 192 + doc/src/sgml/html/xfunc-sql.html | 1768 + doc/src/sgml/html/xfunc-volatility.html | 466 + doc/src/sgml/html/xfunc.html | 278 + doc/src/sgml/html/xindex.html | 2008 + doc/src/sgml/html/xml2.html | 852 + doc/src/sgml/html/xoper-optimization.html | 963 + doc/src/sgml/html/xoper.html | 270 + doc/src/sgml/html/xplang-install.html | 589 + doc/src/sgml/html/xplang.html | 239 + doc/src/sgml/html/xtypes.html | 563 + doc/src/sgml/man-stamp | 0 doc/src/sgml/man1/clusterdb.1 | 209 + doc/src/sgml/man1/createdb.1 | 256 + doc/src/sgml/man1/createlang.1 | 203 + doc/src/sgml/man1/createuser.1 | 331 + doc/src/sgml/man1/dropdb.1 | 197 + doc/src/sgml/man1/droplang.1 | 197 + doc/src/sgml/man1/dropuser.1 | 196 + doc/src/sgml/man1/ecpg.1 | 191 + doc/src/sgml/man1/initdb.1 | 265 + doc/src/sgml/man1/oid2name.1 | 328 + doc/src/sgml/man1/pg_archivecleanup.1 | 206 + doc/src/sgml/man1/pg_basebackup.1 | 364 + doc/src/sgml/man1/pg_config.1 | 269 + doc/src/sgml/man1/pg_controldata.1 | 58 + doc/src/sgml/man1/pg_ctl.1 | 462 + doc/src/sgml/man1/pg_dump.1 | 855 + doc/src/sgml/man1/pg_dumpall.1 | 375 + doc/src/sgml/man1/pg_receivexlog.1 | 203 + doc/src/sgml/man1/pg_resetxlog.1 | 220 + doc/src/sgml/man1/pg_restore.1 | 632 + doc/src/sgml/man1/pg_standby.1 | 414 + doc/src/sgml/man1/pg_test_fsync.1 | 86 + doc/src/sgml/man1/pg_test_timing.1 | 204 + doc/src/sgml/man1/pg_upgrade.1 | 684 + doc/src/sgml/man1/pgbench.1 | 799 + doc/src/sgml/man1/postgres.1 | 639 + doc/src/sgml/man1/postmaster.1 | 45 + doc/src/sgml/man1/psql.1 | 3103 + doc/src/sgml/man1/reindexdb.1 | 231 + doc/src/sgml/man1/vacuumdb.1 | 282 + doc/src/sgml/man1/vacuumlo.1 | 150 + doc/src/sgml/man3/SPI_connect.3 | 71 + doc/src/sgml/man3/SPI_copytuple.3 | 58 + doc/src/sgml/man3/SPI_cursor_close.3 | 52 + doc/src/sgml/man3/SPI_cursor_fetch.3 | 76 + doc/src/sgml/man3/SPI_cursor_find.3 | 53 + doc/src/sgml/man3/SPI_cursor_move.3 | 67 + doc/src/sgml/man3/SPI_cursor_open.3 | 98 + doc/src/sgml/man3/SPI_cursor_open_with_args.3 | 114 + .../man3/SPI_cursor_open_with_paramlist.3 | 82 + doc/src/sgml/man3/SPI_exec.3 | 61 + doc/src/sgml/man3/SPI_execp.3 | 94 + doc/src/sgml/man3/SPI_execute.3 | 300 + doc/src/sgml/man3/SPI_execute_plan.3 | 126 + .../man3/SPI_execute_plan_with_paramlist.3 | 86 + doc/src/sgml/man3/SPI_execute_with_args.3 | 119 + doc/src/sgml/man3/SPI_finish.3 | 59 + doc/src/sgml/man3/SPI_fname.3 | 66 + doc/src/sgml/man3/SPI_fnumber.3 | 65 + doc/src/sgml/man3/SPI_freeplan.3 | 62 + doc/src/sgml/man3/SPI_freetuple.3 | 51 + doc/src/sgml/man3/SPI_freetuptable.3 | 54 + doc/src/sgml/man3/SPI_getargcount.3 | 62 + doc/src/sgml/man3/SPI_getargtypeid.3 | 72 + doc/src/sgml/man3/SPI_getbinval.3 | 78 + doc/src/sgml/man3/SPI_getnspname.3 | 55 + doc/src/sgml/man3/SPI_getrelname.3 | 53 + doc/src/sgml/man3/SPI_gettype.3 | 64 + doc/src/sgml/man3/SPI_gettypeid.3 | 65 + doc/src/sgml/man3/SPI_getvalue.3 | 74 + doc/src/sgml/man3/SPI_is_cursor_plan.3 | 85 + doc/src/sgml/man3/SPI_keepplan.3 | 65 + doc/src/sgml/man3/SPI_modifytuple.3 | 116 + doc/src/sgml/man3/SPI_palloc.3 | 51 + doc/src/sgml/man3/SPI_pfree.3 | 54 + doc/src/sgml/man3/SPI_pop.3 | 43 + doc/src/sgml/man3/SPI_prepare.3 | 127 + doc/src/sgml/man3/SPI_prepare_cursor.3 | 94 + doc/src/sgml/man3/SPI_prepare_params.3 | 74 + doc/src/sgml/man3/SPI_push.3 | 60 + doc/src/sgml/man3/SPI_repalloc.3 | 60 + doc/src/sgml/man3/SPI_returntuple.3 | 74 + doc/src/sgml/man3/SPI_saveplan.3 | 82 + doc/src/sgml/man3/SPI_scroll_cursor_fetch.3 | 94 + doc/src/sgml/man3/SPI_scroll_cursor_move.3 | 95 + doc/src/sgml/man3/dblink.3 | 210 + doc/src/sgml/man3/dblink_build_sql_delete.3 | 100 + doc/src/sgml/man3/dblink_build_sql_insert.3 | 106 + doc/src/sgml/man3/dblink_build_sql_update.3 | 110 + doc/src/sgml/man3/dblink_cancel_query.3 | 64 + doc/src/sgml/man3/dblink_close.3 | 101 + doc/src/sgml/man3/dblink_connect.3 | 150 + doc/src/sgml/man3/dblink_connect_u.3 | 63 + doc/src/sgml/man3/dblink_disconnect.3 | 75 + doc/src/sgml/man3/dblink_error_message.3 | 61 + doc/src/sgml/man3/dblink_exec.3 | 118 + doc/src/sgml/man3/dblink_fetch.3 | 130 + doc/src/sgml/man3/dblink_get_connections.3 | 57 + doc/src/sgml/man3/dblink_get_notify.3 | 87 + doc/src/sgml/man3/dblink_get_pkey.3 | 94 + doc/src/sgml/man3/dblink_get_result.3 | 144 + doc/src/sgml/man3/dblink_is_busy.3 | 63 + doc/src/sgml/man3/dblink_open.3 | 114 + doc/src/sgml/man3/dblink_send_query.3 | 72 + doc/src/sgml/man7/ABORT.7 | 82 + doc/src/sgml/man7/ALTER_AGGREGATE.7 | 138 + doc/src/sgml/man7/ALTER_COLLATION.7 | 108 + doc/src/sgml/man7/ALTER_CONVERSION.7 | 108 + doc/src/sgml/man7/ALTER_DATABASE.7 | 151 + doc/src/sgml/man7/ALTER_DEFAULT_PRIVILEGES.7 | 190 + doc/src/sgml/man7/ALTER_DOMAIN.7 | 285 + doc/src/sgml/man7/ALTER_EXTENSION.7 | 236 + .../sgml/man7/ALTER_FOREIGN_DATA_WRAPPER.7 | 143 + doc/src/sgml/man7/ALTER_FOREIGN_TABLE.7 | 254 + doc/src/sgml/man7/ALTER_FUNCTION.7 | 285 + doc/src/sgml/man7/ALTER_GROUP.7 | 108 + doc/src/sgml/man7/ALTER_INDEX.7 | 167 + doc/src/sgml/man7/ALTER_LANGUAGE.7 | 67 + doc/src/sgml/man7/ALTER_LARGE_OBJECT.7 | 61 + doc/src/sgml/man7/ALTER_OPERATOR.7 | 101 + doc/src/sgml/man7/ALTER_OPERATOR_CLASS.7 | 82 + doc/src/sgml/man7/ALTER_OPERATOR_FAMILY.7 | 253 + doc/src/sgml/man7/ALTER_ROLE.7 | 269 + doc/src/sgml/man7/ALTER_SCHEMA.7 | 74 + doc/src/sgml/man7/ALTER_SEQUENCE.7 | 248 + doc/src/sgml/man7/ALTER_SERVER.7 | 121 + doc/src/sgml/man7/ALTER_TABLE.7 | 934 + doc/src/sgml/man7/ALTER_TABLESPACE.7 | 111 + .../man7/ALTER_TEXT_SEARCH_CONFIGURATION.7 | 145 + .../sgml/man7/ALTER_TEXT_SEARCH_DICTIONARY.7 | 133 + doc/src/sgml/man7/ALTER_TEXT_SEARCH_PARSER.7 | 69 + .../sgml/man7/ALTER_TEXT_SEARCH_TEMPLATE.7 | 69 + doc/src/sgml/man7/ALTER_TRIGGER.7 | 91 + doc/src/sgml/man7/ALTER_TYPE.7 | 251 + doc/src/sgml/man7/ALTER_USER.7 | 72 + doc/src/sgml/man7/ALTER_USER_MAPPING.7 | 106 + doc/src/sgml/man7/ALTER_VIEW.7 | 135 + doc/src/sgml/man7/ANALYZE.7 | 151 + doc/src/sgml/man7/BEGIN.7 | 130 + doc/src/sgml/man7/CHECKPOINT.7 | 64 + doc/src/sgml/man7/CLOSE.7 | 104 + doc/src/sgml/man7/CLUSTER.7 | 192 + doc/src/sgml/man7/COMMENT.7 | 257 + doc/src/sgml/man7/COMMIT.7 | 78 + doc/src/sgml/man7/COMMIT_PREPARED.7 | 80 + doc/src/sgml/man7/COPY.7 | 857 + doc/src/sgml/man7/CREATE_AGGREGATE.7 | 235 + doc/src/sgml/man7/CREATE_CAST.7 | 383 + doc/src/sgml/man7/CREATE_COLLATION.7 | 137 + doc/src/sgml/man7/CREATE_CONVERSION.7 | 137 + doc/src/sgml/man7/CREATE_DATABASE.7 | 234 + doc/src/sgml/man7/CREATE_DOMAIN.7 | 152 + doc/src/sgml/man7/CREATE_EXTENSION.7 | 162 + .../sgml/man7/CREATE_FOREIGN_DATA_WRAPPER.7 | 150 + doc/src/sgml/man7/CREATE_FOREIGN_TABLE.7 | 139 + doc/src/sgml/man7/CREATE_FUNCTION.7 | 590 + doc/src/sgml/man7/CREATE_GROUP.7 | 67 + doc/src/sgml/man7/CREATE_INDEX.7 | 523 + doc/src/sgml/man7/CREATE_LANGUAGE.7 | 260 + doc/src/sgml/man7/CREATE_OPERATOR.7 | 280 + doc/src/sgml/man7/CREATE_OPERATOR_CLASS.7 | 220 + doc/src/sgml/man7/CREATE_OPERATOR_FAMILY.7 | 82 + doc/src/sgml/man7/CREATE_ROLE.7 | 401 + doc/src/sgml/man7/CREATE_RULE.7 | 270 + doc/src/sgml/man7/CREATE_SCHEMA.7 | 169 + doc/src/sgml/man7/CREATE_SEQUENCE.7 | 333 + doc/src/sgml/man7/CREATE_SERVER.7 | 126 + doc/src/sgml/man7/CREATE_TABLE.7 | 1107 + doc/src/sgml/man7/CREATE_TABLESPACE.7 | 122 + doc/src/sgml/man7/CREATE_TABLE_AS.7 | 326 + .../man7/CREATE_TEXT_SEARCH_CONFIGURATION.7 | 87 + .../sgml/man7/CREATE_TEXT_SEARCH_DICTIONARY.7 | 100 + doc/src/sgml/man7/CREATE_TEXT_SEARCH_PARSER.7 | 99 + .../sgml/man7/CREATE_TEXT_SEARCH_TEMPLATE.7 | 83 + doc/src/sgml/man7/CREATE_TRIGGER.7 | 555 + doc/src/sgml/man7/CREATE_TYPE.7 | 670 + doc/src/sgml/man7/CREATE_USER.7 | 77 + doc/src/sgml/man7/CREATE_USER_MAPPING.7 | 92 + doc/src/sgml/man7/CREATE_VIEW.7 | 207 + doc/src/sgml/man7/DEALLOCATE.7 | 69 + doc/src/sgml/man7/DECLARE.7 | 329 + doc/src/sgml/man7/DELETE.7 | 322 + doc/src/sgml/man7/DISCARD.7 | 95 + doc/src/sgml/man7/DO.7 | 103 + doc/src/sgml/man7/DROP_AGGREGATE.7 | 93 + doc/src/sgml/man7/DROP_CAST.7 | 88 + doc/src/sgml/man7/DROP_COLLATION.7 | 90 + doc/src/sgml/man7/DROP_CONVERSION.7 | 85 + doc/src/sgml/man7/DROP_DATABASE.7 | 75 + doc/src/sgml/man7/DROP_DOMAIN.7 | 86 + doc/src/sgml/man7/DROP_EXTENSION.7 | 99 + doc/src/sgml/man7/DROP_FOREIGN_DATA_WRAPPER.7 | 88 + doc/src/sgml/man7/DROP_FOREIGN_TABLE.7 | 88 + doc/src/sgml/man7/DROP_FUNCTION.7 | 114 + doc/src/sgml/man7/DROP_GROUP.7 | 50 + doc/src/sgml/man7/DROP_INDEX.7 | 105 + doc/src/sgml/man7/DROP_LANGUAGE.7 | 107 + doc/src/sgml/man7/DROP_OPERATOR.7 | 130 + doc/src/sgml/man7/DROP_OPERATOR_CLASS.7 | 108 + doc/src/sgml/man7/DROP_OPERATOR_FAMILY.7 | 99 + doc/src/sgml/man7/DROP_OWNED.7 | 84 + doc/src/sgml/man7/DROP_ROLE.7 | 93 + doc/src/sgml/man7/DROP_RULE.7 | 89 + doc/src/sgml/man7/DROP_SCHEMA.7 | 91 + doc/src/sgml/man7/DROP_SEQUENCE.7 | 90 + doc/src/sgml/man7/DROP_SERVER.7 | 89 + doc/src/sgml/man7/DROP_TABLE.7 | 98 + doc/src/sgml/man7/DROP_TABLESPACE.7 | 88 + .../man7/DROP_TEXT_SEARCH_CONFIGURATION.7 | 90 + .../sgml/man7/DROP_TEXT_SEARCH_DICTIONARY.7 | 88 + doc/src/sgml/man7/DROP_TEXT_SEARCH_PARSER.7 | 88 + doc/src/sgml/man7/DROP_TEXT_SEARCH_TEMPLATE.7 | 88 + doc/src/sgml/man7/DROP_TRIGGER.7 | 94 + doc/src/sgml/man7/DROP_TYPE.7 | 90 + doc/src/sgml/man7/DROP_USER.7 | 52 + doc/src/sgml/man7/DROP_USER_MAPPING.7 | 95 + doc/src/sgml/man7/DROP_VIEW.7 | 86 + doc/src/sgml/man7/END.7 | 83 + doc/src/sgml/man7/EXECUTE.7 | 87 + doc/src/sgml/man7/EXPLAIN.7 | 391 + doc/src/sgml/man7/FETCH.7 | 358 + doc/src/sgml/man7/GRANT.7 | 560 + doc/src/sgml/man7/INSERT.7 | 358 + doc/src/sgml/man7/LISTEN.7 | 118 + doc/src/sgml/man7/LOAD.7 | 73 + doc/src/sgml/man7/LOCK.7 | 246 + doc/src/sgml/man7/MOVE.7 | 127 + doc/src/sgml/man7/NOTIFY.7 | 152 + doc/src/sgml/man7/PREPARE.7 | 153 + doc/src/sgml/man7/PREPARE_TRANSACTION.7 | 151 + doc/src/sgml/man7/REASSIGN_OWNED.7 | 92 + doc/src/sgml/man7/REINDEX.7 | 253 + doc/src/sgml/man7/RELEASE_SAVEPOINT.7 | 94 + doc/src/sgml/man7/RESET.7 | 111 + doc/src/sgml/man7/REVOKE.7 | 289 + doc/src/sgml/man7/ROLLBACK.7 | 78 + doc/src/sgml/man7/ROLLBACK_PREPARED.7 | 80 + doc/src/sgml/man7/ROLLBACK_TO_SAVEPOINT.7 | 135 + doc/src/sgml/man7/SAVEPOINT.7 | 113 + doc/src/sgml/man7/SECURITY_LABEL.7 | 168 + doc/src/sgml/man7/SELECT.7 | 2035 + doc/src/sgml/man7/SELECT_INTO.7 | 148 + doc/src/sgml/man7/SET.7 | 303 + doc/src/sgml/man7/SET_CONSTRAINTS.7 | 118 + doc/src/sgml/man7/SET_ROLE.7 | 143 + doc/src/sgml/man7/SET_SESSION_AUTHORIZATION.7 | 115 + doc/src/sgml/man7/SET_TRANSACTION.7 | 237 + doc/src/sgml/man7/SHOW.7 | 169 + doc/src/sgml/man7/START_TRANSACTION.7 | 84 + doc/src/sgml/man7/TABLE.7 | 1 + doc/src/sgml/man7/TRUNCATE.7 | 206 + doc/src/sgml/man7/UNLISTEN.7 | 120 + doc/src/sgml/man7/UPDATE.7 | 392 + doc/src/sgml/man7/VACUUM.7 | 224 + doc/src/sgml/man7/VALUES.7 | 282 + doc/src/sgml/man7/WITH.7 | 1 + dropdb.vcxproj | 147 - droplang.vcxproj | 146 - dropuser.vcxproj | 147 - dummy_seclabel.vcxproj | 149 - earthdistance.vcxproj | 149 - ecpg.vcxproj | 173 - euc2004_sjis2004.vcxproj | 149 - euc_cn_and_mic.vcxproj | 149 - euc_jp_and_sjis.vcxproj | 149 - euc_kr_and_mic.vcxproj | 149 - euc_tw_and_big5.vcxproj | 150 - file_fdw.vcxproj | 149 - fuzzystrmatch.vcxproj | 150 - hstore.vcxproj | 154 - initdb.vcxproj | 144 - insert_username.vcxproj | 149 - isn.vcxproj | 149 - isolationtester.vcxproj | 163 - latin2_and_win1250.vcxproj | 149 - latin_and_mic.vcxproj | 149 - libecpg.vcxproj | 157 - libecpg_compat.vcxproj | 145 - libpgport.vcxproj | 168 - libpgtypes.vcxproj | 145 - libpq.vcxproj | 166 - libpqwalreceiver.vcxproj | 152 - lo.vcxproj | 149 - ltree.vcxproj | 157 - moddatetime.vcxproj | 149 - oid2name.vcxproj | 140 - pageinspect.vcxproj | 152 - passwordcheck.vcxproj | 149 - pg_archivecleanup.vcxproj | 137 - pg_basebackup.vcxproj | 145 - pg_buffercache.vcxproj | 149 - pg_config.vcxproj | 140 - pg_controldata.vcxproj | 140 - pg_ctl.vcxproj | 143 - pg_dump.vcxproj | 156 - pg_dumpall.vcxproj | 147 - pg_freespacemap.vcxproj | 149 - pg_isolation_regress.vcxproj | 138 - pg_receivexlog.vcxproj | 145 - pg_regress.vcxproj | 138 - pg_regress_ecpg.vcxproj | 138 - pg_resetxlog.vcxproj | 140 - pg_restore.vcxproj | 154 - pg_standby.vcxproj | 137 - pg_stat_statements.vcxproj | 149 - pg_test_fsync.vcxproj | 137 - pg_test_timing.vcxproj | 137 - pg_trgm.vcxproj | 151 - pg_upgrade.vcxproj | 155 - pg_upgrade_support.vcxproj | 149 - pgbench.vcxproj | 140 - pgcrypto.vcxproj | 181 - pgevent.vcxproj | 139 - pgrowlocks.vcxproj | 149 - pgstattuple.vcxproj | 150 - plpgsql.vcxproj | 166 - postgres.vcxproj | 763 - psql.vcxproj | 173 - refint.vcxproj | 149 - regress.vcxproj | 149 - reindexdb.vcxproj | 147 - seg.vcxproj | 172 - src/.gitignore | 3 - src/backend/.gitignore | 2 - src/backend/bootstrap/.gitignore | 2 - src/backend/bootstrap/bootparse.c | 2164 + src/backend/bootstrap/bootscanner.c | 2118 + src/backend/catalog/.gitignore | 4 - src/backend/catalog/postgres.bki | 5443 ++ src/backend/catalog/postgres.description | 2511 + src/backend/catalog/postgres.shdescription | 1 + src/backend/catalog/schemapg.h | 186 + src/backend/parser/.gitignore | 3 - src/backend/parser/gram.c | 38592 ++++++++++++ src/backend/parser/gram.h | 527 + src/backend/parser/scan.c | 17565 ++++++ src/backend/port/.gitignore | 5 - src/backend/replication/.gitignore | 3 - src/backend/replication/repl_gram.c | 1725 + src/backend/replication/repl_gram.h | 84 + src/backend/replication/repl_scanner.c | 2005 + src/backend/snowball/.gitignore | 1 - src/backend/utils/.gitignore | 4 - src/backend/utils/errcodes.h | 324 + src/backend/utils/fmgroids.h | 2138 + src/backend/utils/fmgrtab.c | 4470 ++ .../utils/mb/conversion_procs/.gitignore | 1 - src/backend/utils/misc/.gitignore | 1 - src/backend/utils/misc/guc-file.c | 2547 + src/backend/utils/sort/.gitignore | 1 - src/backend/utils/sort/qsort_tuple.c | 280 + src/bin/initdb/.gitignore | 5 - src/bin/pg_basebackup/.gitignore | 2 - src/bin/pg_config/.gitignore | 1 - src/bin/pg_controldata/.gitignore | 1 - src/bin/pg_ctl/.gitignore | 1 - src/bin/pg_dump/.gitignore | 5 - src/bin/pg_resetxlog/.gitignore | 1 - src/bin/psql/.gitignore | 8 - src/bin/psql/psqlscan.c | 7681 +++ src/bin/psql/sql_help.c | 3346 + src/bin/psql/sql_help.h | 950 + src/bin/scripts/.gitignore | 15 - src/include/.gitignore | 5 - src/include/catalog/.gitignore | 1 - src/include/parser/.gitignore | 1 - src/include/utils/.gitignore | 3 - src/interfaces/ecpg/compatlib/.gitignore | 3 - .../ecpg/compatlib/blibecpg_compatdll.def | 89 + .../ecpg/compatlib/libecpg_compatddll.def | 45 + .../ecpg/compatlib/libecpg_compatdll.def | 45 + src/interfaces/ecpg/ecpglib/.gitignore | 8 - src/interfaces/ecpg/ecpglib/blibecpgdll.def | 63 + src/interfaces/ecpg/ecpglib/libecpgddll.def | 32 + src/interfaces/ecpg/ecpglib/libecpgdll.def | 32 + src/interfaces/ecpg/include/.gitignore | 2 - src/interfaces/ecpg/pgtypeslib/.gitignore | 5 - .../ecpg/pgtypeslib/blibpgtypesdll.def | 95 + .../ecpg/pgtypeslib/libpgtypesddll.def | 48 + .../ecpg/pgtypeslib/libpgtypesdll.def | 48 + src/interfaces/ecpg/preproc/.gitignore | 7 - src/interfaces/ecpg/preproc/pgc.c | 5158 ++ src/interfaces/ecpg/preproc/preproc.c | 51699 ++++++++++++++++ src/interfaces/ecpg/preproc/preproc.h | 582 + src/interfaces/ecpg/preproc/preproc.y | 14478 +++++ src/interfaces/ecpg/test/.gitignore | 5 - .../ecpg/test/compat_informix/.gitignore | 18 - src/interfaces/ecpg/test/connect/.gitignore | 10 - .../ecpg/test/pgtypeslib/.gitignore | 10 - src/interfaces/ecpg/test/preproc/.gitignore | 22 - src/interfaces/ecpg/test/sql/.gitignore | 40 - src/interfaces/ecpg/test/thread/.gitignore | 10 - src/interfaces/libpq/.gitignore | 21 - src/interfaces/libpq/libpq_debugdll.def | 164 + src/interfaces/libpq/libpqdll.def | 164 + src/interfaces/libpq/win32.mak | 6 +- src/pl/plperl/.gitignore | 9 - src/pl/plpgsql/src/.gitignore | 3 - src/pl/plpgsql/src/pl_gram.c | 6040 ++ src/pl/plpgsql/src/pl_gram.h | 231 + src/pl/plpgsql/src/plerrcodes.h | 886 + src/pl/plpython/.gitignore | 5 - src/pl/plpython/spiexceptions.h | 223 + src/pl/tcl/.gitignore | 4 - src/pl/tcl/modules/.gitignore | 3 - src/port/.gitignore | 3 - src/port/win32ver.rc | 31 + src/test/isolation/.gitignore | 12 - src/test/isolation/specparse.c | 1822 + src/test/isolation/specscanner.c | 1917 + src/test/regress/.gitignore | 7 - src/test/regress/expected/.gitignore | 9 - src/test/regress/sql/.gitignore | 8 - src/timezone/.gitignore | 1 - src/tools/entab/.gitignore | 1 - tablefunc.vcxproj | 149 - tcn.vcxproj | 149 - test_parser.vcxproj | 149 - timetravel.vcxproj | 149 - tsearch2.vcxproj | 149 - unaccent.vcxproj | 149 - utf8_and_ascii.vcxproj | 149 - utf8_and_big5.vcxproj | 149 - utf8_and_cyrillic.vcxproj | 149 - utf8_and_euc2004.vcxproj | 149 - utf8_and_euc_cn.vcxproj | 149 - utf8_and_euc_jp.vcxproj | 149 - utf8_and_euc_kr.vcxproj | 149 - utf8_and_euc_tw.vcxproj | 149 - utf8_and_gb18030.vcxproj | 149 - utf8_and_gbk.vcxproj | 149 - utf8_and_iso8859.vcxproj | 149 - utf8_and_iso8859_1.vcxproj | 149 - utf8_and_johab.vcxproj | 149 - utf8_and_sjis.vcxproj | 149 - utf8_and_sjis2004.vcxproj | 149 - utf8_and_uhc.vcxproj | 149 - utf8_and_win.vcxproj | 149 - vacuumdb.vcxproj | 144 - vacuumlo.vcxproj | 140 - zic.vcxproj | 140 - 1648 files changed, 936510 insertions(+), 17882 deletions(-) delete mode 100644 .gitignore create mode 100644 README.md delete mode 100644 _int.vcxproj delete mode 100644 adminpack.vcxproj delete mode 100644 ascii_and_mic.vcxproj delete mode 100644 auth_delay.vcxproj delete mode 100644 auto_explain.vcxproj delete mode 100644 autoinc.vcxproj delete mode 100644 btree_gin.vcxproj delete mode 100644 btree_gist.vcxproj delete mode 100644 chkpass.vcxproj delete mode 100644 citext.vcxproj delete mode 100644 clusterdb.vcxproj delete mode 100644 contrib/btree_gin/.gitignore delete mode 100644 contrib/btree_gist/.gitignore delete mode 100644 contrib/citext/.gitignore delete mode 100644 contrib/cube/.gitignore create mode 100644 contrib/cube/cubeparse.c create mode 100644 contrib/cube/cubescan.c delete mode 100644 contrib/dblink/.gitignore delete mode 100644 contrib/dict_int/.gitignore delete mode 100644 contrib/dict_xsyn/.gitignore delete mode 100644 contrib/earthdistance/.gitignore delete mode 100644 contrib/file_fdw/.gitignore delete mode 100644 contrib/file_fdw/expected/.gitignore delete mode 100644 contrib/file_fdw/sql/.gitignore delete mode 100644 contrib/hstore/.gitignore delete mode 100644 contrib/intarray/.gitignore delete mode 100644 contrib/ltree/.gitignore delete mode 100644 contrib/oid2name/.gitignore delete mode 100644 contrib/pg_archivecleanup/.gitignore delete mode 100644 contrib/pg_standby/.gitignore delete mode 100644 contrib/pg_test_fsync/.gitignore delete mode 100644 contrib/pg_test_timing/.gitignore delete mode 100644 contrib/pg_trgm/.gitignore delete mode 100644 contrib/pg_upgrade/.gitignore delete mode 100644 contrib/pgbench/.gitignore delete mode 100644 contrib/pgcrypto/.gitignore delete mode 100644 contrib/pgstattuple/.gitignore delete mode 100644 contrib/seg/.gitignore create mode 100644 contrib/seg/segparse.c create mode 100644 contrib/seg/segscan.c delete mode 100644 contrib/sepgsql/.gitignore delete mode 100644 contrib/tablefunc/.gitignore delete mode 100644 contrib/test_parser/.gitignore delete mode 100644 contrib/tsearch2/.gitignore delete mode 100644 contrib/unaccent/.gitignore delete mode 100644 contrib/vacuumlo/.gitignore delete mode 100644 contrib/xml2/.gitignore delete mode 100644 createdb.vcxproj delete mode 100644 createlang.vcxproj delete mode 100644 createuser.vcxproj delete mode 100644 cube.vcxproj delete mode 100644 cyrillic_and_mic.vcxproj delete mode 100644 dblink.vcxproj delete mode 100644 dict_int.vcxproj delete mode 100644 dict_snowball.vcxproj delete mode 100644 dict_xsyn.vcxproj delete mode 100644 doc/src/sgml/.gitignore create mode 100644 doc/src/sgml/html-stamp create mode 100644 doc/src/sgml/html/LEGALNOTICE.html create mode 100644 doc/src/sgml/html/acronyms.html create mode 100644 doc/src/sgml/html/admin.html create mode 100644 doc/src/sgml/html/adminpack.html create mode 100644 doc/src/sgml/html/app-clusterdb.html create mode 100644 doc/src/sgml/html/app-createdb.html create mode 100644 doc/src/sgml/html/app-createlang.html create mode 100644 doc/src/sgml/html/app-createuser.html create mode 100644 doc/src/sgml/html/app-dropdb.html create mode 100644 doc/src/sgml/html/app-droplang.html create mode 100644 doc/src/sgml/html/app-dropuser.html create mode 100644 doc/src/sgml/html/app-ecpg.html create mode 100644 doc/src/sgml/html/app-initdb.html create mode 100644 doc/src/sgml/html/app-pg-ctl.html create mode 100644 doc/src/sgml/html/app-pg-dumpall.html create mode 100644 doc/src/sgml/html/app-pgbasebackup.html create mode 100644 doc/src/sgml/html/app-pgconfig.html create mode 100644 doc/src/sgml/html/app-pgcontroldata.html create mode 100644 doc/src/sgml/html/app-pgdump.html create mode 100644 doc/src/sgml/html/app-pgreceivexlog.html create mode 100644 doc/src/sgml/html/app-pgresetxlog.html create mode 100644 doc/src/sgml/html/app-pgrestore.html create mode 100644 doc/src/sgml/html/app-postgres.html create mode 100644 doc/src/sgml/html/app-postmaster.html create mode 100644 doc/src/sgml/html/app-psql.html create mode 100644 doc/src/sgml/html/app-reindexdb.html create mode 100644 doc/src/sgml/html/app-vacuumdb.html create mode 100644 doc/src/sgml/html/appendixes.html create mode 100644 doc/src/sgml/html/applevel-consistency.html create mode 100644 doc/src/sgml/html/archive-recovery-settings.html create mode 100644 doc/src/sgml/html/arrays.html create mode 100644 doc/src/sgml/html/auth-delay.html create mode 100644 doc/src/sgml/html/auth-methods.html create mode 100644 doc/src/sgml/html/auth-pg-hba-conf.html create mode 100644 doc/src/sgml/html/auth-username-maps.html create mode 100644 doc/src/sgml/html/auto-explain.html create mode 100644 doc/src/sgml/html/backup-dump.html create mode 100644 doc/src/sgml/html/backup-file.html create mode 100644 doc/src/sgml/html/backup.html create mode 100644 doc/src/sgml/html/biblio.html create mode 100644 doc/src/sgml/html/bki-commands.html create mode 100644 doc/src/sgml/html/bki-example.html create mode 100644 doc/src/sgml/html/bki-format.html create mode 100644 doc/src/sgml/html/bki-structure.html create mode 100644 doc/src/sgml/html/bki.html create mode 100644 doc/src/sgml/html/bookindex.html create mode 100644 doc/src/sgml/html/btree-gin.html create mode 100644 doc/src/sgml/html/btree-gist.html create mode 100644 doc/src/sgml/html/bug-reporting.html create mode 100644 doc/src/sgml/html/catalog-pg-aggregate.html create mode 100644 doc/src/sgml/html/catalog-pg-am.html create mode 100644 doc/src/sgml/html/catalog-pg-amop.html create mode 100644 doc/src/sgml/html/catalog-pg-amproc.html create mode 100644 doc/src/sgml/html/catalog-pg-attrdef.html create mode 100644 doc/src/sgml/html/catalog-pg-attribute.html create mode 100644 doc/src/sgml/html/catalog-pg-auth-members.html create mode 100644 doc/src/sgml/html/catalog-pg-authid.html create mode 100644 doc/src/sgml/html/catalog-pg-cast.html create mode 100644 doc/src/sgml/html/catalog-pg-class.html create mode 100644 doc/src/sgml/html/catalog-pg-collation.html create mode 100644 doc/src/sgml/html/catalog-pg-constraint.html create mode 100644 doc/src/sgml/html/catalog-pg-conversion.html create mode 100644 doc/src/sgml/html/catalog-pg-database.html create mode 100644 doc/src/sgml/html/catalog-pg-db-role-setting.html create mode 100644 doc/src/sgml/html/catalog-pg-default-acl.html create mode 100644 doc/src/sgml/html/catalog-pg-depend.html create mode 100644 doc/src/sgml/html/catalog-pg-description.html create mode 100644 doc/src/sgml/html/catalog-pg-enum.html create mode 100644 doc/src/sgml/html/catalog-pg-extension.html create mode 100644 doc/src/sgml/html/catalog-pg-foreign-data-wrapper.html create mode 100644 doc/src/sgml/html/catalog-pg-foreign-server.html create mode 100644 doc/src/sgml/html/catalog-pg-foreign-table.html create mode 100644 doc/src/sgml/html/catalog-pg-index.html create mode 100644 doc/src/sgml/html/catalog-pg-inherits.html create mode 100644 doc/src/sgml/html/catalog-pg-language.html create mode 100644 doc/src/sgml/html/catalog-pg-largeobject-metadata.html create mode 100644 doc/src/sgml/html/catalog-pg-largeobject.html create mode 100644 doc/src/sgml/html/catalog-pg-namespace.html create mode 100644 doc/src/sgml/html/catalog-pg-opclass.html create mode 100644 doc/src/sgml/html/catalog-pg-operator.html create mode 100644 doc/src/sgml/html/catalog-pg-opfamily.html create mode 100644 doc/src/sgml/html/catalog-pg-pltemplate.html create mode 100644 doc/src/sgml/html/catalog-pg-proc.html create mode 100644 doc/src/sgml/html/catalog-pg-range.html create mode 100644 doc/src/sgml/html/catalog-pg-rewrite.html create mode 100644 doc/src/sgml/html/catalog-pg-seclabel.html create mode 100644 doc/src/sgml/html/catalog-pg-shdepend.html create mode 100644 doc/src/sgml/html/catalog-pg-shdescription.html create mode 100644 doc/src/sgml/html/catalog-pg-shseclabel.html create mode 100644 doc/src/sgml/html/catalog-pg-statistic.html create mode 100644 doc/src/sgml/html/catalog-pg-tablespace.html create mode 100644 doc/src/sgml/html/catalog-pg-trigger.html create mode 100644 doc/src/sgml/html/catalog-pg-ts-config-map.html create mode 100644 doc/src/sgml/html/catalog-pg-ts-config.html create mode 100644 doc/src/sgml/html/catalog-pg-ts-dict.html create mode 100644 doc/src/sgml/html/catalog-pg-ts-parser.html create mode 100644 doc/src/sgml/html/catalog-pg-ts-template.html create mode 100644 doc/src/sgml/html/catalog-pg-type.html create mode 100644 doc/src/sgml/html/catalog-pg-user-mapping.html create mode 100644 doc/src/sgml/html/catalogs-overview.html create mode 100644 doc/src/sgml/html/catalogs.html create mode 100644 doc/src/sgml/html/charset.html create mode 100644 doc/src/sgml/html/chkpass.html create mode 100644 doc/src/sgml/html/citext.html create mode 100644 doc/src/sgml/html/client-authentication-problems.html create mode 100644 doc/src/sgml/html/client-authentication.html create mode 100644 doc/src/sgml/html/client-interfaces.html create mode 100644 doc/src/sgml/html/collation.html create mode 100644 doc/src/sgml/html/config-setting.html create mode 100644 doc/src/sgml/html/connect-estab.html create mode 100644 doc/src/sgml/html/continuous-archiving.html create mode 100644 doc/src/sgml/html/contrib-dblink-build-sql-delete.html create mode 100644 doc/src/sgml/html/contrib-dblink-build-sql-insert.html create mode 100644 doc/src/sgml/html/contrib-dblink-build-sql-update.html create mode 100644 doc/src/sgml/html/contrib-dblink-cancel-query.html create mode 100644 doc/src/sgml/html/contrib-dblink-close.html create mode 100644 doc/src/sgml/html/contrib-dblink-connect-u.html create mode 100644 doc/src/sgml/html/contrib-dblink-connect.html create mode 100644 doc/src/sgml/html/contrib-dblink-disconnect.html create mode 100644 doc/src/sgml/html/contrib-dblink-error-message.html create mode 100644 doc/src/sgml/html/contrib-dblink-exec.html create mode 100644 doc/src/sgml/html/contrib-dblink-fetch.html create mode 100644 doc/src/sgml/html/contrib-dblink-function.html create mode 100644 doc/src/sgml/html/contrib-dblink-get-connections.html create mode 100644 doc/src/sgml/html/contrib-dblink-get-notify.html create mode 100644 doc/src/sgml/html/contrib-dblink-get-pkey.html create mode 100644 doc/src/sgml/html/contrib-dblink-get-result.html create mode 100644 doc/src/sgml/html/contrib-dblink-is-busy.html create mode 100644 doc/src/sgml/html/contrib-dblink-open.html create mode 100644 doc/src/sgml/html/contrib-dblink-send-query.html create mode 100644 doc/src/sgml/html/contrib-prog-client.html create mode 100644 doc/src/sgml/html/contrib-prog-server.html create mode 100644 doc/src/sgml/html/contrib-prog.html create mode 100644 doc/src/sgml/html/contrib-spi.html create mode 100644 doc/src/sgml/html/contrib.html create mode 100644 doc/src/sgml/html/creating-cluster.html create mode 100644 doc/src/sgml/html/cube.html create mode 100644 doc/src/sgml/html/database-roles.html create mode 100644 doc/src/sgml/html/datatype-binary.html create mode 100644 doc/src/sgml/html/datatype-bit.html create mode 100644 doc/src/sgml/html/datatype-boolean.html create mode 100644 doc/src/sgml/html/datatype-character.html create mode 100644 doc/src/sgml/html/datatype-datetime.html create mode 100644 doc/src/sgml/html/datatype-enum.html create mode 100644 doc/src/sgml/html/datatype-geometric.html create mode 100644 doc/src/sgml/html/datatype-json.html create mode 100644 doc/src/sgml/html/datatype-money.html create mode 100644 doc/src/sgml/html/datatype-net-types.html create mode 100644 doc/src/sgml/html/datatype-numeric.html create mode 100644 doc/src/sgml/html/datatype-oid.html create mode 100644 doc/src/sgml/html/datatype-pseudo.html create mode 100644 doc/src/sgml/html/datatype-textsearch.html create mode 100644 doc/src/sgml/html/datatype-uuid.html create mode 100644 doc/src/sgml/html/datatype-xml.html create mode 100644 doc/src/sgml/html/datatype.html create mode 100644 doc/src/sgml/html/datetime-appendix.html create mode 100644 doc/src/sgml/html/datetime-config-files.html create mode 100644 doc/src/sgml/html/datetime-input-rules.html create mode 100644 doc/src/sgml/html/datetime-keywords.html create mode 100644 doc/src/sgml/html/datetime-units-history.html create mode 100644 doc/src/sgml/html/dblink.html create mode 100644 doc/src/sgml/html/ddl-alter.html create mode 100644 doc/src/sgml/html/ddl-basics.html create mode 100644 doc/src/sgml/html/ddl-constraints.html create mode 100644 doc/src/sgml/html/ddl-default.html create mode 100644 doc/src/sgml/html/ddl-depend.html create mode 100644 doc/src/sgml/html/ddl-foreign-data.html create mode 100644 doc/src/sgml/html/ddl-inherit.html create mode 100644 doc/src/sgml/html/ddl-others.html create mode 100644 doc/src/sgml/html/ddl-partitioning.html create mode 100644 doc/src/sgml/html/ddl-priv.html create mode 100644 doc/src/sgml/html/ddl-schemas.html create mode 100644 doc/src/sgml/html/ddl-system-columns.html create mode 100644 doc/src/sgml/html/ddl.html create mode 100644 doc/src/sgml/html/dict-int.html create mode 100644 doc/src/sgml/html/dict-xsyn.html create mode 100644 doc/src/sgml/html/different-replication-solutions.html create mode 100644 doc/src/sgml/html/disk-full.html create mode 100644 doc/src/sgml/html/disk-usage.html create mode 100644 doc/src/sgml/html/diskusage.html create mode 100644 doc/src/sgml/html/dml-delete.html create mode 100644 doc/src/sgml/html/dml-insert.html create mode 100644 doc/src/sgml/html/dml-update.html create mode 100644 doc/src/sgml/html/dml.html create mode 100644 doc/src/sgml/html/docguide-authoring.html create mode 100644 doc/src/sgml/html/docguide-build.html create mode 100644 doc/src/sgml/html/docguide-docbook.html create mode 100644 doc/src/sgml/html/docguide-style.html create mode 100644 doc/src/sgml/html/docguide-toolsets.html create mode 100644 doc/src/sgml/html/docguide.html create mode 100644 doc/src/sgml/html/dummy-seclabel.html create mode 100644 doc/src/sgml/html/dynamic-trace.html create mode 100644 doc/src/sgml/html/earthdistance.html create mode 100644 doc/src/sgml/html/ecpg-commands.html create mode 100644 doc/src/sgml/html/ecpg-concept.html create mode 100644 doc/src/sgml/html/ecpg-connect.html create mode 100644 doc/src/sgml/html/ecpg-cpp.html create mode 100644 doc/src/sgml/html/ecpg-descriptors.html create mode 100644 doc/src/sgml/html/ecpg-develop.html create mode 100644 doc/src/sgml/html/ecpg-dynamic.html create mode 100644 doc/src/sgml/html/ecpg-errors.html create mode 100644 doc/src/sgml/html/ecpg-informix-compat.html create mode 100644 doc/src/sgml/html/ecpg-library.html create mode 100644 doc/src/sgml/html/ecpg-lo.html create mode 100644 doc/src/sgml/html/ecpg-pgtypes.html create mode 100644 doc/src/sgml/html/ecpg-preproc.html create mode 100644 doc/src/sgml/html/ecpg-process.html create mode 100644 doc/src/sgml/html/ecpg-sql-allocate-descriptor.html create mode 100644 doc/src/sgml/html/ecpg-sql-commands.html create mode 100644 doc/src/sgml/html/ecpg-sql-connect.html create mode 100644 doc/src/sgml/html/ecpg-sql-deallocate-descriptor.html create mode 100644 doc/src/sgml/html/ecpg-sql-declare.html create mode 100644 doc/src/sgml/html/ecpg-sql-describe.html create mode 100644 doc/src/sgml/html/ecpg-sql-disconnect.html create mode 100644 doc/src/sgml/html/ecpg-sql-execute-immediate.html create mode 100644 doc/src/sgml/html/ecpg-sql-get-descriptor.html create mode 100644 doc/src/sgml/html/ecpg-sql-open.html create mode 100644 doc/src/sgml/html/ecpg-sql-prepare.html create mode 100644 doc/src/sgml/html/ecpg-sql-set-autocommit.html create mode 100644 doc/src/sgml/html/ecpg-sql-set-connection.html create mode 100644 doc/src/sgml/html/ecpg-sql-set-descriptor.html create mode 100644 doc/src/sgml/html/ecpg-sql-type.html create mode 100644 doc/src/sgml/html/ecpg-sql-var.html create mode 100644 doc/src/sgml/html/ecpg-sql-whenever.html create mode 100644 doc/src/sgml/html/ecpg-variables.html create mode 100644 doc/src/sgml/html/ecpg.html create mode 100644 doc/src/sgml/html/encryption-options.html create mode 100644 doc/src/sgml/html/errcodes-appendix.html create mode 100644 doc/src/sgml/html/error-message-reporting.html create mode 100644 doc/src/sgml/html/error-style-guide.html create mode 100644 doc/src/sgml/html/event-log-registration.html create mode 100644 doc/src/sgml/html/executor.html create mode 100644 doc/src/sgml/html/explicit-joins.html create mode 100644 doc/src/sgml/html/explicit-locking.html create mode 100644 doc/src/sgml/html/extend-extensions.html create mode 100644 doc/src/sgml/html/extend-how.html create mode 100644 doc/src/sgml/html/extend-pgxs.html create mode 100644 doc/src/sgml/html/extend-type-system.html create mode 100644 doc/src/sgml/html/extend.html create mode 100644 doc/src/sgml/html/external-admin-tools.html create mode 100644 doc/src/sgml/html/external-extensions.html create mode 100644 doc/src/sgml/html/external-interfaces.html create mode 100644 doc/src/sgml/html/external-pl.html create mode 100644 doc/src/sgml/html/external-projects.html create mode 100644 doc/src/sgml/html/fdw-callbacks.html create mode 100644 doc/src/sgml/html/fdw-functions.html create mode 100644 doc/src/sgml/html/fdw-helpers.html create mode 100644 doc/src/sgml/html/fdw-planning.html create mode 100644 doc/src/sgml/html/fdwhandler.html create mode 100644 doc/src/sgml/html/features-sql-standard.html create mode 100644 doc/src/sgml/html/features.html create mode 100644 doc/src/sgml/html/file-fdw.html create mode 100644 doc/src/sgml/html/functions-admin.html create mode 100644 doc/src/sgml/html/functions-aggregate.html create mode 100644 doc/src/sgml/html/functions-array.html create mode 100644 doc/src/sgml/html/functions-binarystring.html create mode 100644 doc/src/sgml/html/functions-bitstring.html create mode 100644 doc/src/sgml/html/functions-comparison.html create mode 100644 doc/src/sgml/html/functions-comparisons.html create mode 100644 doc/src/sgml/html/functions-conditional.html create mode 100644 doc/src/sgml/html/functions-datetime.html create mode 100644 doc/src/sgml/html/functions-enum.html create mode 100644 doc/src/sgml/html/functions-formatting.html create mode 100644 doc/src/sgml/html/functions-geometry.html create mode 100644 doc/src/sgml/html/functions-info.html create mode 100644 doc/src/sgml/html/functions-json.html create mode 100644 doc/src/sgml/html/functions-logical.html create mode 100644 doc/src/sgml/html/functions-matching.html create mode 100644 doc/src/sgml/html/functions-math.html create mode 100644 doc/src/sgml/html/functions-net.html create mode 100644 doc/src/sgml/html/functions-range.html create mode 100644 doc/src/sgml/html/functions-sequence.html create mode 100644 doc/src/sgml/html/functions-srf.html create mode 100644 doc/src/sgml/html/functions-string.html create mode 100644 doc/src/sgml/html/functions-subquery.html create mode 100644 doc/src/sgml/html/functions-textsearch.html create mode 100644 doc/src/sgml/html/functions-trigger.html create mode 100644 doc/src/sgml/html/functions-window.html create mode 100644 doc/src/sgml/html/functions-xml.html create mode 100644 doc/src/sgml/html/functions.html create mode 100644 doc/src/sgml/html/fuzzystrmatch.html create mode 100644 doc/src/sgml/html/geqo-biblio.html create mode 100644 doc/src/sgml/html/geqo-intro.html create mode 100644 doc/src/sgml/html/geqo-intro2.html create mode 100644 doc/src/sgml/html/geqo-pg-intro.html create mode 100644 doc/src/sgml/html/geqo.html create mode 100644 doc/src/sgml/html/gin-examples.html create mode 100644 doc/src/sgml/html/gin-extensibility.html create mode 100644 doc/src/sgml/html/gin-implementation.html create mode 100644 doc/src/sgml/html/gin-intro.html create mode 100644 doc/src/sgml/html/gin-limit.html create mode 100644 doc/src/sgml/html/gin-tips.html create mode 100644 doc/src/sgml/html/gin.html create mode 100644 doc/src/sgml/html/gist-examples.html create mode 100644 doc/src/sgml/html/gist-extensibility.html create mode 100644 doc/src/sgml/html/gist-implementation.html create mode 100644 doc/src/sgml/html/gist-intro.html create mode 100644 doc/src/sgml/html/gist.html create mode 100644 doc/src/sgml/html/git.html create mode 100644 doc/src/sgml/html/high-availability.html create mode 100644 doc/src/sgml/html/history.html create mode 100644 doc/src/sgml/html/hot-standby.html create mode 100644 doc/src/sgml/html/hstore.html create mode 100644 doc/src/sgml/html/index-catalog.html create mode 100644 doc/src/sgml/html/index-cost-estimation.html create mode 100644 doc/src/sgml/html/index-functions.html create mode 100644 doc/src/sgml/html/index-locking.html create mode 100644 doc/src/sgml/html/index-scanning.html create mode 100644 doc/src/sgml/html/index-unique-checks.html create mode 100644 doc/src/sgml/html/index.html create mode 100644 doc/src/sgml/html/indexam.html create mode 100644 doc/src/sgml/html/indexes-bitmap-scans.html create mode 100644 doc/src/sgml/html/indexes-collations.html create mode 100644 doc/src/sgml/html/indexes-examine.html create mode 100644 doc/src/sgml/html/indexes-expressional.html create mode 100644 doc/src/sgml/html/indexes-intro.html create mode 100644 doc/src/sgml/html/indexes-multicolumn.html create mode 100644 doc/src/sgml/html/indexes-opclass.html create mode 100644 doc/src/sgml/html/indexes-ordering.html create mode 100644 doc/src/sgml/html/indexes-partial.html create mode 100644 doc/src/sgml/html/indexes-types.html create mode 100644 doc/src/sgml/html/indexes-unique.html create mode 100644 doc/src/sgml/html/indexes.html create mode 100644 doc/src/sgml/html/information-schema.html create mode 100644 doc/src/sgml/html/infoschema-administrable-role-authorizations.html create mode 100644 doc/src/sgml/html/infoschema-applicable-roles.html create mode 100644 doc/src/sgml/html/infoschema-attributes.html create mode 100644 doc/src/sgml/html/infoschema-character-sets.html create mode 100644 doc/src/sgml/html/infoschema-check-constraint-routine-usage.html create mode 100644 doc/src/sgml/html/infoschema-check-constraints.html create mode 100644 doc/src/sgml/html/infoschema-collation-character-set-applicab.html create mode 100644 doc/src/sgml/html/infoschema-collations.html create mode 100644 doc/src/sgml/html/infoschema-column-domain-usage.html create mode 100644 doc/src/sgml/html/infoschema-column-options.html create mode 100644 doc/src/sgml/html/infoschema-column-privileges.html create mode 100644 doc/src/sgml/html/infoschema-column-udt-usage.html create mode 100644 doc/src/sgml/html/infoschema-columns.html create mode 100644 doc/src/sgml/html/infoschema-constraint-column-usage.html create mode 100644 doc/src/sgml/html/infoschema-constraint-table-usage.html create mode 100644 doc/src/sgml/html/infoschema-data-type-privileges.html create mode 100644 doc/src/sgml/html/infoschema-datatypes.html create mode 100644 doc/src/sgml/html/infoschema-domain-constraints.html create mode 100644 doc/src/sgml/html/infoschema-domain-udt-usage.html create mode 100644 doc/src/sgml/html/infoschema-domains.html create mode 100644 doc/src/sgml/html/infoschema-element-types.html create mode 100644 doc/src/sgml/html/infoschema-enabled-roles.html create mode 100644 doc/src/sgml/html/infoschema-foreign-data-wrapper-options.html create mode 100644 doc/src/sgml/html/infoschema-foreign-data-wrappers.html create mode 100644 doc/src/sgml/html/infoschema-foreign-server-options.html create mode 100644 doc/src/sgml/html/infoschema-foreign-servers.html create mode 100644 doc/src/sgml/html/infoschema-foreign-table-options.html create mode 100644 doc/src/sgml/html/infoschema-foreign-tables.html create mode 100644 doc/src/sgml/html/infoschema-information-schema-catalog-name.html create mode 100644 doc/src/sgml/html/infoschema-key-column-usage.html create mode 100644 doc/src/sgml/html/infoschema-parameters.html create mode 100644 doc/src/sgml/html/infoschema-referential-constraints.html create mode 100644 doc/src/sgml/html/infoschema-role-column-grants.html create mode 100644 doc/src/sgml/html/infoschema-role-routine-grants.html create mode 100644 doc/src/sgml/html/infoschema-role-table-grants.html create mode 100644 doc/src/sgml/html/infoschema-role-udt-grants.html create mode 100644 doc/src/sgml/html/infoschema-role-usage-grants.html create mode 100644 doc/src/sgml/html/infoschema-routine-privileges.html create mode 100644 doc/src/sgml/html/infoschema-routines.html create mode 100644 doc/src/sgml/html/infoschema-schema.html create mode 100644 doc/src/sgml/html/infoschema-schemata.html create mode 100644 doc/src/sgml/html/infoschema-sequences.html create mode 100644 doc/src/sgml/html/infoschema-sql-features.html create mode 100644 doc/src/sgml/html/infoschema-sql-implementation-info.html create mode 100644 doc/src/sgml/html/infoschema-sql-languages.html create mode 100644 doc/src/sgml/html/infoschema-sql-packages.html create mode 100644 doc/src/sgml/html/infoschema-sql-parts.html create mode 100644 doc/src/sgml/html/infoschema-sql-sizing-profiles.html create mode 100644 doc/src/sgml/html/infoschema-sql-sizing.html create mode 100644 doc/src/sgml/html/infoschema-table-constraints.html create mode 100644 doc/src/sgml/html/infoschema-table-privileges.html create mode 100644 doc/src/sgml/html/infoschema-tables.html create mode 100644 doc/src/sgml/html/infoschema-triggered-update-columns.html create mode 100644 doc/src/sgml/html/infoschema-triggers.html create mode 100644 doc/src/sgml/html/infoschema-udt-privileges.html create mode 100644 doc/src/sgml/html/infoschema-usage-privileges.html create mode 100644 doc/src/sgml/html/infoschema-user-defined-types.html create mode 100644 doc/src/sgml/html/infoschema-user-mapping-options.html create mode 100644 doc/src/sgml/html/infoschema-user-mappings.html create mode 100644 doc/src/sgml/html/infoschema-view-column-usage.html create mode 100644 doc/src/sgml/html/infoschema-view-routine-usage.html create mode 100644 doc/src/sgml/html/infoschema-view-table-usage.html create mode 100644 doc/src/sgml/html/infoschema-views.html create mode 100644 doc/src/sgml/html/install-getsource.html create mode 100644 doc/src/sgml/html/install-post.html create mode 100644 doc/src/sgml/html/install-procedure.html create mode 100644 doc/src/sgml/html/install-requirements.html create mode 100644 doc/src/sgml/html/install-short.html create mode 100644 doc/src/sgml/html/install-windows-full.html create mode 100644 doc/src/sgml/html/install-windows-libpq.html create mode 100644 doc/src/sgml/html/install-windows.html create mode 100644 doc/src/sgml/html/installation-platform-notes.html create mode 100644 doc/src/sgml/html/installation.html create mode 100644 doc/src/sgml/html/intagg.html create mode 100644 doc/src/sgml/html/intarray.html create mode 100644 doc/src/sgml/html/internals.html create mode 100644 doc/src/sgml/html/intro-whatis.html create mode 100644 doc/src/sgml/html/isn.html create mode 100644 doc/src/sgml/html/kernel-resources.html create mode 100644 doc/src/sgml/html/largeobjects.html create mode 100644 doc/src/sgml/html/libpq-async.html create mode 100644 doc/src/sgml/html/libpq-build.html create mode 100644 doc/src/sgml/html/libpq-cancel.html create mode 100644 doc/src/sgml/html/libpq-connect.html create mode 100644 doc/src/sgml/html/libpq-control.html create mode 100644 doc/src/sgml/html/libpq-copy.html create mode 100644 doc/src/sgml/html/libpq-envars.html create mode 100644 doc/src/sgml/html/libpq-events.html create mode 100644 doc/src/sgml/html/libpq-example.html create mode 100644 doc/src/sgml/html/libpq-exec.html create mode 100644 doc/src/sgml/html/libpq-fastpath.html create mode 100644 doc/src/sgml/html/libpq-ldap.html create mode 100644 doc/src/sgml/html/libpq-misc.html create mode 100644 doc/src/sgml/html/libpq-notice-processing.html create mode 100644 doc/src/sgml/html/libpq-notify.html create mode 100644 doc/src/sgml/html/libpq-pgpass.html create mode 100644 doc/src/sgml/html/libpq-pgservice.html create mode 100644 doc/src/sgml/html/libpq-single-row-mode.html create mode 100644 doc/src/sgml/html/libpq-ssl.html create mode 100644 doc/src/sgml/html/libpq-status.html create mode 100644 doc/src/sgml/html/libpq-threading.html create mode 100644 doc/src/sgml/html/libpq.html create mode 100644 doc/src/sgml/html/lo-examplesect.html create mode 100644 doc/src/sgml/html/lo-funcs.html create mode 100644 doc/src/sgml/html/lo-implementation.html create mode 100644 doc/src/sgml/html/lo-interfaces.html create mode 100644 doc/src/sgml/html/lo-intro.html create mode 100644 doc/src/sgml/html/lo.html create mode 100644 doc/src/sgml/html/locale.html create mode 100644 doc/src/sgml/html/locking-indexes.html create mode 100644 doc/src/sgml/html/log-shipping-alternative.html create mode 100644 doc/src/sgml/html/logfile-maintenance.html create mode 100644 doc/src/sgml/html/ltree.html create mode 100644 doc/src/sgml/html/maintenance.html create mode 100644 doc/src/sgml/html/manage-ag-config.html create mode 100644 doc/src/sgml/html/manage-ag-createdb.html create mode 100644 doc/src/sgml/html/manage-ag-dropdb.html create mode 100644 doc/src/sgml/html/manage-ag-overview.html create mode 100644 doc/src/sgml/html/manage-ag-tablespaces.html create mode 100644 doc/src/sgml/html/manage-ag-templatedbs.html create mode 100644 doc/src/sgml/html/managing-databases.html create mode 100644 doc/src/sgml/html/monitoring-locks.html create mode 100644 doc/src/sgml/html/monitoring-ps.html create mode 100644 doc/src/sgml/html/monitoring-stats.html create mode 100644 doc/src/sgml/html/monitoring.html create mode 100644 doc/src/sgml/html/multibyte.html create mode 100644 doc/src/sgml/html/mvcc-intro.html create mode 100644 doc/src/sgml/html/mvcc.html create mode 100644 doc/src/sgml/html/nls-programmer.html create mode 100644 doc/src/sgml/html/nls-translator.html create mode 100644 doc/src/sgml/html/nls.html create mode 100644 doc/src/sgml/html/non-durability.html create mode 100644 doc/src/sgml/html/notation.html create mode 100644 doc/src/sgml/html/oid2name.html create mode 100644 doc/src/sgml/html/overview.html create mode 100644 doc/src/sgml/html/pageinspect.html create mode 100644 doc/src/sgml/html/parser-stage.html create mode 100644 doc/src/sgml/html/passwordcheck.html create mode 100644 doc/src/sgml/html/performance-tips.html create mode 100644 doc/src/sgml/html/perm-functions.html create mode 100644 doc/src/sgml/html/pgarchivecleanup.html create mode 100644 doc/src/sgml/html/pgbench.html create mode 100644 doc/src/sgml/html/pgbuffercache.html create mode 100644 doc/src/sgml/html/pgcrypto.html create mode 100644 doc/src/sgml/html/pgfreespacemap.html create mode 100644 doc/src/sgml/html/pgrowlocks.html create mode 100644 doc/src/sgml/html/pgstandby.html create mode 100644 doc/src/sgml/html/pgstatstatements.html create mode 100644 doc/src/sgml/html/pgstattuple.html create mode 100644 doc/src/sgml/html/pgtestfsync.html create mode 100644 doc/src/sgml/html/pgtesttiming.html create mode 100644 doc/src/sgml/html/pgtrgm.html create mode 100644 doc/src/sgml/html/pgupgrade.html create mode 100644 doc/src/sgml/html/planner-optimizer.html create mode 100644 doc/src/sgml/html/planner-stats-details.html create mode 100644 doc/src/sgml/html/planner-stats.html create mode 100644 doc/src/sgml/html/plhandler.html create mode 100644 doc/src/sgml/html/plperl-builtins.html create mode 100644 doc/src/sgml/html/plperl-data.html create mode 100644 doc/src/sgml/html/plperl-funcs.html create mode 100644 doc/src/sgml/html/plperl-global.html create mode 100644 doc/src/sgml/html/plperl-triggers.html create mode 100644 doc/src/sgml/html/plperl-trusted.html create mode 100644 doc/src/sgml/html/plperl-under-the-hood.html create mode 100644 doc/src/sgml/html/plperl.html create mode 100644 doc/src/sgml/html/plpgsql-control-structures.html create mode 100644 doc/src/sgml/html/plpgsql-cursors.html create mode 100644 doc/src/sgml/html/plpgsql-declarations.html create mode 100644 doc/src/sgml/html/plpgsql-development-tips.html create mode 100644 doc/src/sgml/html/plpgsql-errors-and-messages.html create mode 100644 doc/src/sgml/html/plpgsql-expressions.html create mode 100644 doc/src/sgml/html/plpgsql-implementation.html create mode 100644 doc/src/sgml/html/plpgsql-overview.html create mode 100644 doc/src/sgml/html/plpgsql-porting.html create mode 100644 doc/src/sgml/html/plpgsql-statements.html create mode 100644 doc/src/sgml/html/plpgsql-structure.html create mode 100644 doc/src/sgml/html/plpgsql-trigger.html create mode 100644 doc/src/sgml/html/plpgsql.html create mode 100644 doc/src/sgml/html/plpython-data.html create mode 100644 doc/src/sgml/html/plpython-database.html create mode 100644 doc/src/sgml/html/plpython-do.html create mode 100644 doc/src/sgml/html/plpython-envar.html create mode 100644 doc/src/sgml/html/plpython-funcs.html create mode 100644 doc/src/sgml/html/plpython-python23.html create mode 100644 doc/src/sgml/html/plpython-sharing.html create mode 100644 doc/src/sgml/html/plpython-subtransaction.html create mode 100644 doc/src/sgml/html/plpython-trigger.html create mode 100644 doc/src/sgml/html/plpython-util.html create mode 100644 doc/src/sgml/html/plpython.html create mode 100644 doc/src/sgml/html/pltcl-data.html create mode 100644 doc/src/sgml/html/pltcl-dbaccess.html create mode 100644 doc/src/sgml/html/pltcl-functions.html create mode 100644 doc/src/sgml/html/pltcl-global.html create mode 100644 doc/src/sgml/html/pltcl-overview.html create mode 100644 doc/src/sgml/html/pltcl-procnames.html create mode 100644 doc/src/sgml/html/pltcl-trigger.html create mode 100644 doc/src/sgml/html/pltcl-unknown.html create mode 100644 doc/src/sgml/html/pltcl.html create mode 100644 doc/src/sgml/html/populate.html create mode 100644 doc/src/sgml/html/postgres-user.html create mode 100644 doc/src/sgml/html/preface.html create mode 100644 doc/src/sgml/html/preventing-server-spoofing.html create mode 100644 doc/src/sgml/html/protocol-changes.html create mode 100644 doc/src/sgml/html/protocol-error-fields.html create mode 100644 doc/src/sgml/html/protocol-flow.html create mode 100644 doc/src/sgml/html/protocol-message-formats.html create mode 100644 doc/src/sgml/html/protocol-message-types.html create mode 100644 doc/src/sgml/html/protocol-overview.html create mode 100644 doc/src/sgml/html/protocol-replication.html create mode 100644 doc/src/sgml/html/protocol.html create mode 100644 doc/src/sgml/html/queries-limit.html create mode 100644 doc/src/sgml/html/queries-order.html create mode 100644 doc/src/sgml/html/queries-overview.html create mode 100644 doc/src/sgml/html/queries-select-lists.html create mode 100644 doc/src/sgml/html/queries-table-expressions.html create mode 100644 doc/src/sgml/html/queries-union.html create mode 100644 doc/src/sgml/html/queries-values.html create mode 100644 doc/src/sgml/html/queries-with.html create mode 100644 doc/src/sgml/html/queries.html create mode 100644 doc/src/sgml/html/query-path.html create mode 100644 doc/src/sgml/html/querytree.html create mode 100644 doc/src/sgml/html/rangetypes.html create mode 100644 doc/src/sgml/html/recovery-config.html create mode 100644 doc/src/sgml/html/recovery-target-settings.html create mode 100644 doc/src/sgml/html/reference-client.html create mode 100644 doc/src/sgml/html/reference-server.html create mode 100644 doc/src/sgml/html/reference.html create mode 100644 doc/src/sgml/html/regress-coverage.html create mode 100644 doc/src/sgml/html/regress-evaluation.html create mode 100644 doc/src/sgml/html/regress-run.html create mode 100644 doc/src/sgml/html/regress-variant.html create mode 100644 doc/src/sgml/html/regress.html create mode 100644 doc/src/sgml/html/release-0-01.html create mode 100644 doc/src/sgml/html/release-0-02.html create mode 100644 doc/src/sgml/html/release-0-03.html create mode 100644 doc/src/sgml/html/release-1-0.html create mode 100644 doc/src/sgml/html/release-1-01.html create mode 100644 doc/src/sgml/html/release-1-02.html create mode 100644 doc/src/sgml/html/release-1-09.html create mode 100644 doc/src/sgml/html/release-6-0.html create mode 100644 doc/src/sgml/html/release-6-1-1.html create mode 100644 doc/src/sgml/html/release-6-1.html create mode 100644 doc/src/sgml/html/release-6-2-1.html create mode 100644 doc/src/sgml/html/release-6-2.html create mode 100644 doc/src/sgml/html/release-6-3-1.html create mode 100644 doc/src/sgml/html/release-6-3-2.html create mode 100644 doc/src/sgml/html/release-6-3.html create mode 100644 doc/src/sgml/html/release-6-4-1.html create mode 100644 doc/src/sgml/html/release-6-4-2.html create mode 100644 doc/src/sgml/html/release-6-4.html create mode 100644 doc/src/sgml/html/release-6-5-1.html create mode 100644 doc/src/sgml/html/release-6-5-2.html create mode 100644 doc/src/sgml/html/release-6-5-3.html create mode 100644 doc/src/sgml/html/release-6-5.html create mode 100644 doc/src/sgml/html/release-7-0-1.html create mode 100644 doc/src/sgml/html/release-7-0-2.html create mode 100644 doc/src/sgml/html/release-7-0-3.html create mode 100644 doc/src/sgml/html/release-7-0.html create mode 100644 doc/src/sgml/html/release-7-1-1.html create mode 100644 doc/src/sgml/html/release-7-1-2.html create mode 100644 doc/src/sgml/html/release-7-1-3.html create mode 100644 doc/src/sgml/html/release-7-1.html create mode 100644 doc/src/sgml/html/release-7-2-1.html create mode 100644 doc/src/sgml/html/release-7-2-2.html create mode 100644 doc/src/sgml/html/release-7-2-3.html create mode 100644 doc/src/sgml/html/release-7-2-4.html create mode 100644 doc/src/sgml/html/release-7-2-5.html create mode 100644 doc/src/sgml/html/release-7-2-6.html create mode 100644 doc/src/sgml/html/release-7-2-7.html create mode 100644 doc/src/sgml/html/release-7-2-8.html create mode 100644 doc/src/sgml/html/release-7-2.html create mode 100644 doc/src/sgml/html/release-7-3-1.html create mode 100644 doc/src/sgml/html/release-7-3-10.html create mode 100644 doc/src/sgml/html/release-7-3-11.html create mode 100644 doc/src/sgml/html/release-7-3-12.html create mode 100644 doc/src/sgml/html/release-7-3-13.html create mode 100644 doc/src/sgml/html/release-7-3-14.html create mode 100644 doc/src/sgml/html/release-7-3-15.html create mode 100644 doc/src/sgml/html/release-7-3-16.html create mode 100644 doc/src/sgml/html/release-7-3-17.html create mode 100644 doc/src/sgml/html/release-7-3-18.html create mode 100644 doc/src/sgml/html/release-7-3-19.html create mode 100644 doc/src/sgml/html/release-7-3-2.html create mode 100644 doc/src/sgml/html/release-7-3-20.html create mode 100644 doc/src/sgml/html/release-7-3-21.html create mode 100644 doc/src/sgml/html/release-7-3-3.html create mode 100644 doc/src/sgml/html/release-7-3-4.html create mode 100644 doc/src/sgml/html/release-7-3-5.html create mode 100644 doc/src/sgml/html/release-7-3-6.html create mode 100644 doc/src/sgml/html/release-7-3-7.html create mode 100644 doc/src/sgml/html/release-7-3-8.html create mode 100644 doc/src/sgml/html/release-7-3-9.html create mode 100644 doc/src/sgml/html/release-7-3.html create mode 100644 doc/src/sgml/html/release-7-4-1.html create mode 100644 doc/src/sgml/html/release-7-4-10.html create mode 100644 doc/src/sgml/html/release-7-4-11.html create mode 100644 doc/src/sgml/html/release-7-4-12.html create mode 100644 doc/src/sgml/html/release-7-4-13.html create mode 100644 doc/src/sgml/html/release-7-4-14.html create mode 100644 doc/src/sgml/html/release-7-4-15.html create mode 100644 doc/src/sgml/html/release-7-4-16.html create mode 100644 doc/src/sgml/html/release-7-4-17.html create mode 100644 doc/src/sgml/html/release-7-4-18.html create mode 100644 doc/src/sgml/html/release-7-4-19.html create mode 100644 doc/src/sgml/html/release-7-4-2.html create mode 100644 doc/src/sgml/html/release-7-4-20.html create mode 100644 doc/src/sgml/html/release-7-4-21.html create mode 100644 doc/src/sgml/html/release-7-4-22.html create mode 100644 doc/src/sgml/html/release-7-4-23.html create mode 100644 doc/src/sgml/html/release-7-4-24.html create mode 100644 doc/src/sgml/html/release-7-4-25.html create mode 100644 doc/src/sgml/html/release-7-4-26.html create mode 100644 doc/src/sgml/html/release-7-4-27.html create mode 100644 doc/src/sgml/html/release-7-4-28.html create mode 100644 doc/src/sgml/html/release-7-4-29.html create mode 100644 doc/src/sgml/html/release-7-4-3.html create mode 100644 doc/src/sgml/html/release-7-4-30.html create mode 100644 doc/src/sgml/html/release-7-4-4.html create mode 100644 doc/src/sgml/html/release-7-4-5.html create mode 100644 doc/src/sgml/html/release-7-4-6.html create mode 100644 doc/src/sgml/html/release-7-4-7.html create mode 100644 doc/src/sgml/html/release-7-4-8.html create mode 100644 doc/src/sgml/html/release-7-4-9.html create mode 100644 doc/src/sgml/html/release-7-4.html create mode 100644 doc/src/sgml/html/release-8-0-1.html create mode 100644 doc/src/sgml/html/release-8-0-10.html create mode 100644 doc/src/sgml/html/release-8-0-11.html create mode 100644 doc/src/sgml/html/release-8-0-12.html create mode 100644 doc/src/sgml/html/release-8-0-13.html create mode 100644 doc/src/sgml/html/release-8-0-14.html create mode 100644 doc/src/sgml/html/release-8-0-15.html create mode 100644 doc/src/sgml/html/release-8-0-16.html create mode 100644 doc/src/sgml/html/release-8-0-17.html create mode 100644 doc/src/sgml/html/release-8-0-18.html create mode 100644 doc/src/sgml/html/release-8-0-19.html create mode 100644 doc/src/sgml/html/release-8-0-2.html create mode 100644 doc/src/sgml/html/release-8-0-20.html create mode 100644 doc/src/sgml/html/release-8-0-21.html create mode 100644 doc/src/sgml/html/release-8-0-22.html create mode 100644 doc/src/sgml/html/release-8-0-23.html create mode 100644 doc/src/sgml/html/release-8-0-24.html create mode 100644 doc/src/sgml/html/release-8-0-25.html create mode 100644 doc/src/sgml/html/release-8-0-26.html create mode 100644 doc/src/sgml/html/release-8-0-3.html create mode 100644 doc/src/sgml/html/release-8-0-4.html create mode 100644 doc/src/sgml/html/release-8-0-5.html create mode 100644 doc/src/sgml/html/release-8-0-6.html create mode 100644 doc/src/sgml/html/release-8-0-7.html create mode 100644 doc/src/sgml/html/release-8-0-8.html create mode 100644 doc/src/sgml/html/release-8-0-9.html create mode 100644 doc/src/sgml/html/release-8-0.html create mode 100644 doc/src/sgml/html/release-8-1-1.html create mode 100644 doc/src/sgml/html/release-8-1-10.html create mode 100644 doc/src/sgml/html/release-8-1-11.html create mode 100644 doc/src/sgml/html/release-8-1-12.html create mode 100644 doc/src/sgml/html/release-8-1-13.html create mode 100644 doc/src/sgml/html/release-8-1-14.html create mode 100644 doc/src/sgml/html/release-8-1-15.html create mode 100644 doc/src/sgml/html/release-8-1-16.html create mode 100644 doc/src/sgml/html/release-8-1-17.html create mode 100644 doc/src/sgml/html/release-8-1-18.html create mode 100644 doc/src/sgml/html/release-8-1-19.html create mode 100644 doc/src/sgml/html/release-8-1-2.html create mode 100644 doc/src/sgml/html/release-8-1-20.html create mode 100644 doc/src/sgml/html/release-8-1-21.html create mode 100644 doc/src/sgml/html/release-8-1-22.html create mode 100644 doc/src/sgml/html/release-8-1-23.html create mode 100644 doc/src/sgml/html/release-8-1-3.html create mode 100644 doc/src/sgml/html/release-8-1-4.html create mode 100644 doc/src/sgml/html/release-8-1-5.html create mode 100644 doc/src/sgml/html/release-8-1-6.html create mode 100644 doc/src/sgml/html/release-8-1-7.html create mode 100644 doc/src/sgml/html/release-8-1-8.html create mode 100644 doc/src/sgml/html/release-8-1-9.html create mode 100644 doc/src/sgml/html/release-8-1.html create mode 100644 doc/src/sgml/html/release-8-2-1.html create mode 100644 doc/src/sgml/html/release-8-2-10.html create mode 100644 doc/src/sgml/html/release-8-2-11.html create mode 100644 doc/src/sgml/html/release-8-2-12.html create mode 100644 doc/src/sgml/html/release-8-2-13.html create mode 100644 doc/src/sgml/html/release-8-2-14.html create mode 100644 doc/src/sgml/html/release-8-2-15.html create mode 100644 doc/src/sgml/html/release-8-2-16.html create mode 100644 doc/src/sgml/html/release-8-2-17.html create mode 100644 doc/src/sgml/html/release-8-2-18.html create mode 100644 doc/src/sgml/html/release-8-2-19.html create mode 100644 doc/src/sgml/html/release-8-2-2.html create mode 100644 doc/src/sgml/html/release-8-2-20.html create mode 100644 doc/src/sgml/html/release-8-2-21.html create mode 100644 doc/src/sgml/html/release-8-2-22.html create mode 100644 doc/src/sgml/html/release-8-2-23.html create mode 100644 doc/src/sgml/html/release-8-2-3.html create mode 100644 doc/src/sgml/html/release-8-2-4.html create mode 100644 doc/src/sgml/html/release-8-2-5.html create mode 100644 doc/src/sgml/html/release-8-2-6.html create mode 100644 doc/src/sgml/html/release-8-2-7.html create mode 100644 doc/src/sgml/html/release-8-2-8.html create mode 100644 doc/src/sgml/html/release-8-2-9.html create mode 100644 doc/src/sgml/html/release-8-2.html create mode 100644 doc/src/sgml/html/release-8-3-1.html create mode 100644 doc/src/sgml/html/release-8-3-10.html create mode 100644 doc/src/sgml/html/release-8-3-11.html create mode 100644 doc/src/sgml/html/release-8-3-12.html create mode 100644 doc/src/sgml/html/release-8-3-13.html create mode 100644 doc/src/sgml/html/release-8-3-14.html create mode 100644 doc/src/sgml/html/release-8-3-15.html create mode 100644 doc/src/sgml/html/release-8-3-16.html create mode 100644 doc/src/sgml/html/release-8-3-17.html create mode 100644 doc/src/sgml/html/release-8-3-18.html create mode 100644 doc/src/sgml/html/release-8-3-19.html create mode 100644 doc/src/sgml/html/release-8-3-2.html create mode 100644 doc/src/sgml/html/release-8-3-20.html create mode 100644 doc/src/sgml/html/release-8-3-21.html create mode 100644 doc/src/sgml/html/release-8-3-22.html create mode 100644 doc/src/sgml/html/release-8-3-3.html create mode 100644 doc/src/sgml/html/release-8-3-4.html create mode 100644 doc/src/sgml/html/release-8-3-5.html create mode 100644 doc/src/sgml/html/release-8-3-6.html create mode 100644 doc/src/sgml/html/release-8-3-7.html create mode 100644 doc/src/sgml/html/release-8-3-8.html create mode 100644 doc/src/sgml/html/release-8-3-9.html create mode 100644 doc/src/sgml/html/release-8-3.html create mode 100644 doc/src/sgml/html/release-8-4-1.html create mode 100644 doc/src/sgml/html/release-8-4-10.html create mode 100644 doc/src/sgml/html/release-8-4-11.html create mode 100644 doc/src/sgml/html/release-8-4-12.html create mode 100644 doc/src/sgml/html/release-8-4-13.html create mode 100644 doc/src/sgml/html/release-8-4-14.html create mode 100644 doc/src/sgml/html/release-8-4-15.html create mode 100644 doc/src/sgml/html/release-8-4-2.html create mode 100644 doc/src/sgml/html/release-8-4-3.html create mode 100644 doc/src/sgml/html/release-8-4-4.html create mode 100644 doc/src/sgml/html/release-8-4-5.html create mode 100644 doc/src/sgml/html/release-8-4-6.html create mode 100644 doc/src/sgml/html/release-8-4-7.html create mode 100644 doc/src/sgml/html/release-8-4-8.html create mode 100644 doc/src/sgml/html/release-8-4-9.html create mode 100644 doc/src/sgml/html/release-8-4.html create mode 100644 doc/src/sgml/html/release-9-0-1.html create mode 100644 doc/src/sgml/html/release-9-0-10.html create mode 100644 doc/src/sgml/html/release-9-0-11.html create mode 100644 doc/src/sgml/html/release-9-0-2.html create mode 100644 doc/src/sgml/html/release-9-0-3.html create mode 100644 doc/src/sgml/html/release-9-0-4.html create mode 100644 doc/src/sgml/html/release-9-0-5.html create mode 100644 doc/src/sgml/html/release-9-0-6.html create mode 100644 doc/src/sgml/html/release-9-0-7.html create mode 100644 doc/src/sgml/html/release-9-0-8.html create mode 100644 doc/src/sgml/html/release-9-0-9.html create mode 100644 doc/src/sgml/html/release-9-0.html create mode 100644 doc/src/sgml/html/release-9-1-1.html create mode 100644 doc/src/sgml/html/release-9-1-2.html create mode 100644 doc/src/sgml/html/release-9-1-3.html create mode 100644 doc/src/sgml/html/release-9-1-4.html create mode 100644 doc/src/sgml/html/release-9-1-5.html create mode 100644 doc/src/sgml/html/release-9-1-6.html create mode 100644 doc/src/sgml/html/release-9-1-7.html create mode 100644 doc/src/sgml/html/release-9-1.html create mode 100644 doc/src/sgml/html/release-9-2-1.html create mode 100644 doc/src/sgml/html/release-9-2-2.html create mode 100644 doc/src/sgml/html/release-9-2.html create mode 100644 doc/src/sgml/html/release.html create mode 100644 doc/src/sgml/html/resources.html create mode 100644 doc/src/sgml/html/role-attributes.html create mode 100644 doc/src/sgml/html/role-membership.html create mode 100644 doc/src/sgml/html/routine-reindex.html create mode 100644 doc/src/sgml/html/routine-vacuuming.html create mode 100644 doc/src/sgml/html/row-estimation-examples.html create mode 100644 doc/src/sgml/html/rowtypes.html create mode 100644 doc/src/sgml/html/rule-system.html create mode 100644 doc/src/sgml/html/rules-privileges.html create mode 100644 doc/src/sgml/html/rules-status.html create mode 100644 doc/src/sgml/html/rules-triggers.html create mode 100644 doc/src/sgml/html/rules-update.html create mode 100644 doc/src/sgml/html/rules-views.html create mode 100644 doc/src/sgml/html/rules.html create mode 100644 doc/src/sgml/html/runtime-config-autovacuum.html create mode 100644 doc/src/sgml/html/runtime-config-client.html create mode 100644 doc/src/sgml/html/runtime-config-compatible.html create mode 100644 doc/src/sgml/html/runtime-config-connection.html create mode 100644 doc/src/sgml/html/runtime-config-custom.html create mode 100644 doc/src/sgml/html/runtime-config-developer.html create mode 100644 doc/src/sgml/html/runtime-config-error-handling.html create mode 100644 doc/src/sgml/html/runtime-config-file-locations.html create mode 100644 doc/src/sgml/html/runtime-config-locks.html create mode 100644 doc/src/sgml/html/runtime-config-logging.html create mode 100644 doc/src/sgml/html/runtime-config-preset.html create mode 100644 doc/src/sgml/html/runtime-config-query.html create mode 100644 doc/src/sgml/html/runtime-config-replication.html create mode 100644 doc/src/sgml/html/runtime-config-resource.html create mode 100644 doc/src/sgml/html/runtime-config-short.html create mode 100644 doc/src/sgml/html/runtime-config-statistics.html create mode 100644 doc/src/sgml/html/runtime-config-wal.html create mode 100644 doc/src/sgml/html/runtime-config.html create mode 100644 doc/src/sgml/html/runtime.html create mode 100644 doc/src/sgml/html/seg.html create mode 100644 doc/src/sgml/html/sepgsql.html create mode 100644 doc/src/sgml/html/server-programming.html create mode 100644 doc/src/sgml/html/server-shutdown.html create mode 100644 doc/src/sgml/html/server-start.html create mode 100644 doc/src/sgml/html/source-format.html create mode 100644 doc/src/sgml/html/source.html create mode 100644 doc/src/sgml/html/sourcerepo.html create mode 100644 doc/src/sgml/html/spgist-examples.html create mode 100644 doc/src/sgml/html/spgist-extensibility.html create mode 100644 doc/src/sgml/html/spgist-implementation.html create mode 100644 doc/src/sgml/html/spgist-intro.html create mode 100644 doc/src/sgml/html/spgist.html create mode 100644 doc/src/sgml/html/spi-examples.html create mode 100644 doc/src/sgml/html/spi-interface-support.html create mode 100644 doc/src/sgml/html/spi-interface.html create mode 100644 doc/src/sgml/html/spi-memory.html create mode 100644 doc/src/sgml/html/spi-realloc.html create mode 100644 doc/src/sgml/html/spi-spi-connect.html create mode 100644 doc/src/sgml/html/spi-spi-copytuple.html create mode 100644 doc/src/sgml/html/spi-spi-cursor-close.html create mode 100644 doc/src/sgml/html/spi-spi-cursor-fetch.html create mode 100644 doc/src/sgml/html/spi-spi-cursor-find.html create mode 100644 doc/src/sgml/html/spi-spi-cursor-move.html create mode 100644 doc/src/sgml/html/spi-spi-cursor-open-with-args.html create mode 100644 doc/src/sgml/html/spi-spi-cursor-open-with-paramlist.html create mode 100644 doc/src/sgml/html/spi-spi-cursor-open.html create mode 100644 doc/src/sgml/html/spi-spi-exec.html create mode 100644 doc/src/sgml/html/spi-spi-execp.html create mode 100644 doc/src/sgml/html/spi-spi-execute-plan-with-paramlist.html create mode 100644 doc/src/sgml/html/spi-spi-execute-plan.html create mode 100644 doc/src/sgml/html/spi-spi-execute-with-args.html create mode 100644 doc/src/sgml/html/spi-spi-execute.html create mode 100644 doc/src/sgml/html/spi-spi-finish.html create mode 100644 doc/src/sgml/html/spi-spi-fname.html create mode 100644 doc/src/sgml/html/spi-spi-fnumber.html create mode 100644 doc/src/sgml/html/spi-spi-freeplan.html create mode 100644 doc/src/sgml/html/spi-spi-freetuple.html create mode 100644 doc/src/sgml/html/spi-spi-freetupletable.html create mode 100644 doc/src/sgml/html/spi-spi-getargcount.html create mode 100644 doc/src/sgml/html/spi-spi-getargtypeid.html create mode 100644 doc/src/sgml/html/spi-spi-getbinval.html create mode 100644 doc/src/sgml/html/spi-spi-getnspname.html create mode 100644 doc/src/sgml/html/spi-spi-getrelname.html create mode 100644 doc/src/sgml/html/spi-spi-gettype.html create mode 100644 doc/src/sgml/html/spi-spi-gettypeid.html create mode 100644 doc/src/sgml/html/spi-spi-getvalue.html create mode 100644 doc/src/sgml/html/spi-spi-is-cursor-plan.html create mode 100644 doc/src/sgml/html/spi-spi-keepplan.html create mode 100644 doc/src/sgml/html/spi-spi-modifytuple.html create mode 100644 doc/src/sgml/html/spi-spi-palloc.html create mode 100644 doc/src/sgml/html/spi-spi-pfree.html create mode 100644 doc/src/sgml/html/spi-spi-pop.html create mode 100644 doc/src/sgml/html/spi-spi-prepare-cursor.html create mode 100644 doc/src/sgml/html/spi-spi-prepare-params.html create mode 100644 doc/src/sgml/html/spi-spi-prepare.html create mode 100644 doc/src/sgml/html/spi-spi-push.html create mode 100644 doc/src/sgml/html/spi-spi-returntuple.html create mode 100644 doc/src/sgml/html/spi-spi-saveplan.html create mode 100644 doc/src/sgml/html/spi-spi-scroll-cursor-fetch.html create mode 100644 doc/src/sgml/html/spi-spi-scroll-cursor-move.html create mode 100644 doc/src/sgml/html/spi-visibility.html create mode 100644 doc/src/sgml/html/spi.html create mode 100644 doc/src/sgml/html/sql-abort.html create mode 100644 doc/src/sgml/html/sql-alteraggregate.html create mode 100644 doc/src/sgml/html/sql-altercollation.html create mode 100644 doc/src/sgml/html/sql-alterconversion.html create mode 100644 doc/src/sgml/html/sql-alterdatabase.html create mode 100644 doc/src/sgml/html/sql-alterdefaultprivileges.html create mode 100644 doc/src/sgml/html/sql-alterdomain.html create mode 100644 doc/src/sgml/html/sql-alterextension.html create mode 100644 doc/src/sgml/html/sql-alterforeigndatawrapper.html create mode 100644 doc/src/sgml/html/sql-alterforeigntable.html create mode 100644 doc/src/sgml/html/sql-alterfunction.html create mode 100644 doc/src/sgml/html/sql-altergroup.html create mode 100644 doc/src/sgml/html/sql-alterindex.html create mode 100644 doc/src/sgml/html/sql-alterlanguage.html create mode 100644 doc/src/sgml/html/sql-alterlargeobject.html create mode 100644 doc/src/sgml/html/sql-alteropclass.html create mode 100644 doc/src/sgml/html/sql-alteroperator.html create mode 100644 doc/src/sgml/html/sql-alteropfamily.html create mode 100644 doc/src/sgml/html/sql-alterrole.html create mode 100644 doc/src/sgml/html/sql-alterschema.html create mode 100644 doc/src/sgml/html/sql-altersequence.html create mode 100644 doc/src/sgml/html/sql-alterserver.html create mode 100644 doc/src/sgml/html/sql-altertable.html create mode 100644 doc/src/sgml/html/sql-altertablespace.html create mode 100644 doc/src/sgml/html/sql-altertrigger.html create mode 100644 doc/src/sgml/html/sql-altertsconfig.html create mode 100644 doc/src/sgml/html/sql-altertsdictionary.html create mode 100644 doc/src/sgml/html/sql-altertsparser.html create mode 100644 doc/src/sgml/html/sql-altertstemplate.html create mode 100644 doc/src/sgml/html/sql-altertype.html create mode 100644 doc/src/sgml/html/sql-alteruser.html create mode 100644 doc/src/sgml/html/sql-alterusermapping.html create mode 100644 doc/src/sgml/html/sql-alterview.html create mode 100644 doc/src/sgml/html/sql-analyze.html create mode 100644 doc/src/sgml/html/sql-begin.html create mode 100644 doc/src/sgml/html/sql-checkpoint.html create mode 100644 doc/src/sgml/html/sql-close.html create mode 100644 doc/src/sgml/html/sql-cluster.html create mode 100644 doc/src/sgml/html/sql-commands.html create mode 100644 doc/src/sgml/html/sql-comment.html create mode 100644 doc/src/sgml/html/sql-commit-prepared.html create mode 100644 doc/src/sgml/html/sql-commit.html create mode 100644 doc/src/sgml/html/sql-copy.html create mode 100644 doc/src/sgml/html/sql-createaggregate.html create mode 100644 doc/src/sgml/html/sql-createcast.html create mode 100644 doc/src/sgml/html/sql-createcollation.html create mode 100644 doc/src/sgml/html/sql-createconversion.html create mode 100644 doc/src/sgml/html/sql-createdatabase.html create mode 100644 doc/src/sgml/html/sql-createdomain.html create mode 100644 doc/src/sgml/html/sql-createextension.html create mode 100644 doc/src/sgml/html/sql-createforeigndatawrapper.html create mode 100644 doc/src/sgml/html/sql-createforeigntable.html create mode 100644 doc/src/sgml/html/sql-createfunction.html create mode 100644 doc/src/sgml/html/sql-creategroup.html create mode 100644 doc/src/sgml/html/sql-createindex.html create mode 100644 doc/src/sgml/html/sql-createlanguage.html create mode 100644 doc/src/sgml/html/sql-createopclass.html create mode 100644 doc/src/sgml/html/sql-createoperator.html create mode 100644 doc/src/sgml/html/sql-createopfamily.html create mode 100644 doc/src/sgml/html/sql-createrole.html create mode 100644 doc/src/sgml/html/sql-createrule.html create mode 100644 doc/src/sgml/html/sql-createschema.html create mode 100644 doc/src/sgml/html/sql-createsequence.html create mode 100644 doc/src/sgml/html/sql-createserver.html create mode 100644 doc/src/sgml/html/sql-createtable.html create mode 100644 doc/src/sgml/html/sql-createtableas.html create mode 100644 doc/src/sgml/html/sql-createtablespace.html create mode 100644 doc/src/sgml/html/sql-createtrigger.html create mode 100644 doc/src/sgml/html/sql-createtsconfig.html create mode 100644 doc/src/sgml/html/sql-createtsdictionary.html create mode 100644 doc/src/sgml/html/sql-createtsparser.html create mode 100644 doc/src/sgml/html/sql-createtstemplate.html create mode 100644 doc/src/sgml/html/sql-createtype.html create mode 100644 doc/src/sgml/html/sql-createuser.html create mode 100644 doc/src/sgml/html/sql-createusermapping.html create mode 100644 doc/src/sgml/html/sql-createview.html create mode 100644 doc/src/sgml/html/sql-deallocate.html create mode 100644 doc/src/sgml/html/sql-declare.html create mode 100644 doc/src/sgml/html/sql-delete.html create mode 100644 doc/src/sgml/html/sql-discard.html create mode 100644 doc/src/sgml/html/sql-do.html create mode 100644 doc/src/sgml/html/sql-drop-owned.html create mode 100644 doc/src/sgml/html/sql-dropaggregate.html create mode 100644 doc/src/sgml/html/sql-dropcast.html create mode 100644 doc/src/sgml/html/sql-dropcollation.html create mode 100644 doc/src/sgml/html/sql-dropconversion.html create mode 100644 doc/src/sgml/html/sql-dropdatabase.html create mode 100644 doc/src/sgml/html/sql-dropdomain.html create mode 100644 doc/src/sgml/html/sql-dropextension.html create mode 100644 doc/src/sgml/html/sql-dropforeigndatawrapper.html create mode 100644 doc/src/sgml/html/sql-dropforeigntable.html create mode 100644 doc/src/sgml/html/sql-dropfunction.html create mode 100644 doc/src/sgml/html/sql-dropgroup.html create mode 100644 doc/src/sgml/html/sql-dropindex.html create mode 100644 doc/src/sgml/html/sql-droplanguage.html create mode 100644 doc/src/sgml/html/sql-dropopclass.html create mode 100644 doc/src/sgml/html/sql-dropoperator.html create mode 100644 doc/src/sgml/html/sql-dropopfamily.html create mode 100644 doc/src/sgml/html/sql-droprole.html create mode 100644 doc/src/sgml/html/sql-droprule.html create mode 100644 doc/src/sgml/html/sql-dropschema.html create mode 100644 doc/src/sgml/html/sql-dropsequence.html create mode 100644 doc/src/sgml/html/sql-dropserver.html create mode 100644 doc/src/sgml/html/sql-droptable.html create mode 100644 doc/src/sgml/html/sql-droptablespace.html create mode 100644 doc/src/sgml/html/sql-droptrigger.html create mode 100644 doc/src/sgml/html/sql-droptsconfig.html create mode 100644 doc/src/sgml/html/sql-droptsdictionary.html create mode 100644 doc/src/sgml/html/sql-droptsparser.html create mode 100644 doc/src/sgml/html/sql-droptstemplate.html create mode 100644 doc/src/sgml/html/sql-droptype.html create mode 100644 doc/src/sgml/html/sql-dropuser.html create mode 100644 doc/src/sgml/html/sql-dropusermapping.html create mode 100644 doc/src/sgml/html/sql-dropview.html create mode 100644 doc/src/sgml/html/sql-end.html create mode 100644 doc/src/sgml/html/sql-execute.html create mode 100644 doc/src/sgml/html/sql-explain.html create mode 100644 doc/src/sgml/html/sql-expressions.html create mode 100644 doc/src/sgml/html/sql-fetch.html create mode 100644 doc/src/sgml/html/sql-grant.html create mode 100644 doc/src/sgml/html/sql-insert.html create mode 100644 doc/src/sgml/html/sql-keywords-appendix.html create mode 100644 doc/src/sgml/html/sql-listen.html create mode 100644 doc/src/sgml/html/sql-load.html create mode 100644 doc/src/sgml/html/sql-lock.html create mode 100644 doc/src/sgml/html/sql-move.html create mode 100644 doc/src/sgml/html/sql-notify.html create mode 100644 doc/src/sgml/html/sql-prepare-transaction.html create mode 100644 doc/src/sgml/html/sql-prepare.html create mode 100644 doc/src/sgml/html/sql-reassign-owned.html create mode 100644 doc/src/sgml/html/sql-reindex.html create mode 100644 doc/src/sgml/html/sql-release-savepoint.html create mode 100644 doc/src/sgml/html/sql-reset.html create mode 100644 doc/src/sgml/html/sql-revoke.html create mode 100644 doc/src/sgml/html/sql-rollback-prepared.html create mode 100644 doc/src/sgml/html/sql-rollback-to.html create mode 100644 doc/src/sgml/html/sql-rollback.html create mode 100644 doc/src/sgml/html/sql-savepoint.html create mode 100644 doc/src/sgml/html/sql-security-label.html create mode 100644 doc/src/sgml/html/sql-select.html create mode 100644 doc/src/sgml/html/sql-selectinto.html create mode 100644 doc/src/sgml/html/sql-set-constraints.html create mode 100644 doc/src/sgml/html/sql-set-role.html create mode 100644 doc/src/sgml/html/sql-set-session-authorization.html create mode 100644 doc/src/sgml/html/sql-set-transaction.html create mode 100644 doc/src/sgml/html/sql-set.html create mode 100644 doc/src/sgml/html/sql-show.html create mode 100644 doc/src/sgml/html/sql-start-transaction.html create mode 100644 doc/src/sgml/html/sql-syntax-calling-funcs.html create mode 100644 doc/src/sgml/html/sql-syntax-lexical.html create mode 100644 doc/src/sgml/html/sql-syntax.html create mode 100644 doc/src/sgml/html/sql-truncate.html create mode 100644 doc/src/sgml/html/sql-unlisten.html create mode 100644 doc/src/sgml/html/sql-update.html create mode 100644 doc/src/sgml/html/sql-vacuum.html create mode 100644 doc/src/sgml/html/sql-values.html create mode 100644 doc/src/sgml/html/sql.html create mode 100644 doc/src/sgml/html/ssh-tunnels.html create mode 100644 doc/src/sgml/html/ssl-tcp.html create mode 100644 doc/src/sgml/html/sslinfo.html create mode 100644 doc/src/sgml/html/standby-settings.html create mode 100644 doc/src/sgml/html/storage-file-layout.html create mode 100644 doc/src/sgml/html/storage-fsm.html create mode 100644 doc/src/sgml/html/storage-init.html create mode 100644 doc/src/sgml/html/storage-page-layout.html create mode 100644 doc/src/sgml/html/storage-toast.html create mode 100644 doc/src/sgml/html/storage-vm.html create mode 100644 doc/src/sgml/html/storage.html create mode 100644 doc/src/sgml/html/stylesheet.css create mode 100644 doc/src/sgml/html/supported-platforms.html create mode 100644 doc/src/sgml/html/tablefunc.html create mode 100644 doc/src/sgml/html/tcn.html create mode 100644 doc/src/sgml/html/test-parser.html create mode 100644 doc/src/sgml/html/textsearch-configuration.html create mode 100644 doc/src/sgml/html/textsearch-controls.html create mode 100644 doc/src/sgml/html/textsearch-debugging.html create mode 100644 doc/src/sgml/html/textsearch-dictionaries.html create mode 100644 doc/src/sgml/html/textsearch-features.html create mode 100644 doc/src/sgml/html/textsearch-indexes.html create mode 100644 doc/src/sgml/html/textsearch-intro.html create mode 100644 doc/src/sgml/html/textsearch-limitations.html create mode 100644 doc/src/sgml/html/textsearch-migration.html create mode 100644 doc/src/sgml/html/textsearch-parsers.html create mode 100644 doc/src/sgml/html/textsearch-psql.html create mode 100644 doc/src/sgml/html/textsearch-tables.html create mode 100644 doc/src/sgml/html/textsearch.html create mode 100644 doc/src/sgml/html/transaction-iso.html create mode 100644 doc/src/sgml/html/trigger-datachanges.html create mode 100644 doc/src/sgml/html/trigger-definition.html create mode 100644 doc/src/sgml/html/trigger-example.html create mode 100644 doc/src/sgml/html/trigger-interface.html create mode 100644 doc/src/sgml/html/triggers.html create mode 100644 doc/src/sgml/html/tsearch2.html create mode 100644 doc/src/sgml/html/tutorial-accessdb.html create mode 100644 doc/src/sgml/html/tutorial-advanced-intro.html create mode 100644 doc/src/sgml/html/tutorial-advanced.html create mode 100644 doc/src/sgml/html/tutorial-agg.html create mode 100644 doc/src/sgml/html/tutorial-arch.html create mode 100644 doc/src/sgml/html/tutorial-concepts.html create mode 100644 doc/src/sgml/html/tutorial-conclusion.html create mode 100644 doc/src/sgml/html/tutorial-createdb.html create mode 100644 doc/src/sgml/html/tutorial-delete.html create mode 100644 doc/src/sgml/html/tutorial-fk.html create mode 100644 doc/src/sgml/html/tutorial-inheritance.html create mode 100644 doc/src/sgml/html/tutorial-install.html create mode 100644 doc/src/sgml/html/tutorial-join.html create mode 100644 doc/src/sgml/html/tutorial-populate.html create mode 100644 doc/src/sgml/html/tutorial-select.html create mode 100644 doc/src/sgml/html/tutorial-sql-intro.html create mode 100644 doc/src/sgml/html/tutorial-sql.html create mode 100644 doc/src/sgml/html/tutorial-start.html create mode 100644 doc/src/sgml/html/tutorial-table.html create mode 100644 doc/src/sgml/html/tutorial-transactions.html create mode 100644 doc/src/sgml/html/tutorial-update.html create mode 100644 doc/src/sgml/html/tutorial-views.html create mode 100644 doc/src/sgml/html/tutorial-window.html create mode 100644 doc/src/sgml/html/tutorial.html create mode 100644 doc/src/sgml/html/typeconv-func.html create mode 100644 doc/src/sgml/html/typeconv-oper.html create mode 100644 doc/src/sgml/html/typeconv-overview.html create mode 100644 doc/src/sgml/html/typeconv-query.html create mode 100644 doc/src/sgml/html/typeconv-union-case.html create mode 100644 doc/src/sgml/html/typeconv.html create mode 100644 doc/src/sgml/html/unaccent.html create mode 100644 doc/src/sgml/html/unsupported-features-sql-standard.html create mode 100644 doc/src/sgml/html/upgrading.html create mode 100644 doc/src/sgml/html/user-manag.html create mode 100644 doc/src/sgml/html/using-explain.html create mode 100644 doc/src/sgml/html/uuid-ossp.html create mode 100644 doc/src/sgml/html/vacuumlo.html create mode 100644 doc/src/sgml/html/view-pg-available-extension-versions.html create mode 100644 doc/src/sgml/html/view-pg-available-extensions.html create mode 100644 doc/src/sgml/html/view-pg-cursors.html create mode 100644 doc/src/sgml/html/view-pg-group.html create mode 100644 doc/src/sgml/html/view-pg-indexes.html create mode 100644 doc/src/sgml/html/view-pg-locks.html create mode 100644 doc/src/sgml/html/view-pg-prepared-statements.html create mode 100644 doc/src/sgml/html/view-pg-prepared-xacts.html create mode 100644 doc/src/sgml/html/view-pg-roles.html create mode 100644 doc/src/sgml/html/view-pg-rules.html create mode 100644 doc/src/sgml/html/view-pg-seclabels.html create mode 100644 doc/src/sgml/html/view-pg-settings.html create mode 100644 doc/src/sgml/html/view-pg-shadow.html create mode 100644 doc/src/sgml/html/view-pg-stats.html create mode 100644 doc/src/sgml/html/view-pg-tables.html create mode 100644 doc/src/sgml/html/view-pg-timezone-abbrevs.html create mode 100644 doc/src/sgml/html/view-pg-timezone-names.html create mode 100644 doc/src/sgml/html/view-pg-user-mappings.html create mode 100644 doc/src/sgml/html/view-pg-user.html create mode 100644 doc/src/sgml/html/view-pg-views.html create mode 100644 doc/src/sgml/html/views-overview.html create mode 100644 doc/src/sgml/html/wal-async-commit.html create mode 100644 doc/src/sgml/html/wal-configuration.html create mode 100644 doc/src/sgml/html/wal-internals.html create mode 100644 doc/src/sgml/html/wal-intro.html create mode 100644 doc/src/sgml/html/wal-reliability.html create mode 100644 doc/src/sgml/html/wal.html create mode 100644 doc/src/sgml/html/warm-standby-failover.html create mode 100644 doc/src/sgml/html/warm-standby.html create mode 100644 doc/src/sgml/html/xaggr.html create mode 100644 doc/src/sgml/html/xfunc-c.html create mode 100644 doc/src/sgml/html/xfunc-internal.html create mode 100644 doc/src/sgml/html/xfunc-overload.html create mode 100644 doc/src/sgml/html/xfunc-pl.html create mode 100644 doc/src/sgml/html/xfunc-sql.html create mode 100644 doc/src/sgml/html/xfunc-volatility.html create mode 100644 doc/src/sgml/html/xfunc.html create mode 100644 doc/src/sgml/html/xindex.html create mode 100644 doc/src/sgml/html/xml2.html create mode 100644 doc/src/sgml/html/xoper-optimization.html create mode 100644 doc/src/sgml/html/xoper.html create mode 100644 doc/src/sgml/html/xplang-install.html create mode 100644 doc/src/sgml/html/xplang.html create mode 100644 doc/src/sgml/html/xtypes.html create mode 100644 doc/src/sgml/man-stamp create mode 100644 doc/src/sgml/man1/clusterdb.1 create mode 100644 doc/src/sgml/man1/createdb.1 create mode 100644 doc/src/sgml/man1/createlang.1 create mode 100644 doc/src/sgml/man1/createuser.1 create mode 100644 doc/src/sgml/man1/dropdb.1 create mode 100644 doc/src/sgml/man1/droplang.1 create mode 100644 doc/src/sgml/man1/dropuser.1 create mode 100644 doc/src/sgml/man1/ecpg.1 create mode 100644 doc/src/sgml/man1/initdb.1 create mode 100644 doc/src/sgml/man1/oid2name.1 create mode 100644 doc/src/sgml/man1/pg_archivecleanup.1 create mode 100644 doc/src/sgml/man1/pg_basebackup.1 create mode 100644 doc/src/sgml/man1/pg_config.1 create mode 100644 doc/src/sgml/man1/pg_controldata.1 create mode 100644 doc/src/sgml/man1/pg_ctl.1 create mode 100644 doc/src/sgml/man1/pg_dump.1 create mode 100644 doc/src/sgml/man1/pg_dumpall.1 create mode 100644 doc/src/sgml/man1/pg_receivexlog.1 create mode 100644 doc/src/sgml/man1/pg_resetxlog.1 create mode 100644 doc/src/sgml/man1/pg_restore.1 create mode 100644 doc/src/sgml/man1/pg_standby.1 create mode 100644 doc/src/sgml/man1/pg_test_fsync.1 create mode 100644 doc/src/sgml/man1/pg_test_timing.1 create mode 100644 doc/src/sgml/man1/pg_upgrade.1 create mode 100644 doc/src/sgml/man1/pgbench.1 create mode 100644 doc/src/sgml/man1/postgres.1 create mode 100644 doc/src/sgml/man1/postmaster.1 create mode 100644 doc/src/sgml/man1/psql.1 create mode 100644 doc/src/sgml/man1/reindexdb.1 create mode 100644 doc/src/sgml/man1/vacuumdb.1 create mode 100644 doc/src/sgml/man1/vacuumlo.1 create mode 100644 doc/src/sgml/man3/SPI_connect.3 create mode 100644 doc/src/sgml/man3/SPI_copytuple.3 create mode 100644 doc/src/sgml/man3/SPI_cursor_close.3 create mode 100644 doc/src/sgml/man3/SPI_cursor_fetch.3 create mode 100644 doc/src/sgml/man3/SPI_cursor_find.3 create mode 100644 doc/src/sgml/man3/SPI_cursor_move.3 create mode 100644 doc/src/sgml/man3/SPI_cursor_open.3 create mode 100644 doc/src/sgml/man3/SPI_cursor_open_with_args.3 create mode 100644 doc/src/sgml/man3/SPI_cursor_open_with_paramlist.3 create mode 100644 doc/src/sgml/man3/SPI_exec.3 create mode 100644 doc/src/sgml/man3/SPI_execp.3 create mode 100644 doc/src/sgml/man3/SPI_execute.3 create mode 100644 doc/src/sgml/man3/SPI_execute_plan.3 create mode 100644 doc/src/sgml/man3/SPI_execute_plan_with_paramlist.3 create mode 100644 doc/src/sgml/man3/SPI_execute_with_args.3 create mode 100644 doc/src/sgml/man3/SPI_finish.3 create mode 100644 doc/src/sgml/man3/SPI_fname.3 create mode 100644 doc/src/sgml/man3/SPI_fnumber.3 create mode 100644 doc/src/sgml/man3/SPI_freeplan.3 create mode 100644 doc/src/sgml/man3/SPI_freetuple.3 create mode 100644 doc/src/sgml/man3/SPI_freetuptable.3 create mode 100644 doc/src/sgml/man3/SPI_getargcount.3 create mode 100644 doc/src/sgml/man3/SPI_getargtypeid.3 create mode 100644 doc/src/sgml/man3/SPI_getbinval.3 create mode 100644 doc/src/sgml/man3/SPI_getnspname.3 create mode 100644 doc/src/sgml/man3/SPI_getrelname.3 create mode 100644 doc/src/sgml/man3/SPI_gettype.3 create mode 100644 doc/src/sgml/man3/SPI_gettypeid.3 create mode 100644 doc/src/sgml/man3/SPI_getvalue.3 create mode 100644 doc/src/sgml/man3/SPI_is_cursor_plan.3 create mode 100644 doc/src/sgml/man3/SPI_keepplan.3 create mode 100644 doc/src/sgml/man3/SPI_modifytuple.3 create mode 100644 doc/src/sgml/man3/SPI_palloc.3 create mode 100644 doc/src/sgml/man3/SPI_pfree.3 create mode 100644 doc/src/sgml/man3/SPI_pop.3 create mode 100644 doc/src/sgml/man3/SPI_prepare.3 create mode 100644 doc/src/sgml/man3/SPI_prepare_cursor.3 create mode 100644 doc/src/sgml/man3/SPI_prepare_params.3 create mode 100644 doc/src/sgml/man3/SPI_push.3 create mode 100644 doc/src/sgml/man3/SPI_repalloc.3 create mode 100644 doc/src/sgml/man3/SPI_returntuple.3 create mode 100644 doc/src/sgml/man3/SPI_saveplan.3 create mode 100644 doc/src/sgml/man3/SPI_scroll_cursor_fetch.3 create mode 100644 doc/src/sgml/man3/SPI_scroll_cursor_move.3 create mode 100644 doc/src/sgml/man3/dblink.3 create mode 100644 doc/src/sgml/man3/dblink_build_sql_delete.3 create mode 100644 doc/src/sgml/man3/dblink_build_sql_insert.3 create mode 100644 doc/src/sgml/man3/dblink_build_sql_update.3 create mode 100644 doc/src/sgml/man3/dblink_cancel_query.3 create mode 100644 doc/src/sgml/man3/dblink_close.3 create mode 100644 doc/src/sgml/man3/dblink_connect.3 create mode 100644 doc/src/sgml/man3/dblink_connect_u.3 create mode 100644 doc/src/sgml/man3/dblink_disconnect.3 create mode 100644 doc/src/sgml/man3/dblink_error_message.3 create mode 100644 doc/src/sgml/man3/dblink_exec.3 create mode 100644 doc/src/sgml/man3/dblink_fetch.3 create mode 100644 doc/src/sgml/man3/dblink_get_connections.3 create mode 100644 doc/src/sgml/man3/dblink_get_notify.3 create mode 100644 doc/src/sgml/man3/dblink_get_pkey.3 create mode 100644 doc/src/sgml/man3/dblink_get_result.3 create mode 100644 doc/src/sgml/man3/dblink_is_busy.3 create mode 100644 doc/src/sgml/man3/dblink_open.3 create mode 100644 doc/src/sgml/man3/dblink_send_query.3 create mode 100644 doc/src/sgml/man7/ABORT.7 create mode 100644 doc/src/sgml/man7/ALTER_AGGREGATE.7 create mode 100644 doc/src/sgml/man7/ALTER_COLLATION.7 create mode 100644 doc/src/sgml/man7/ALTER_CONVERSION.7 create mode 100644 doc/src/sgml/man7/ALTER_DATABASE.7 create mode 100644 doc/src/sgml/man7/ALTER_DEFAULT_PRIVILEGES.7 create mode 100644 doc/src/sgml/man7/ALTER_DOMAIN.7 create mode 100644 doc/src/sgml/man7/ALTER_EXTENSION.7 create mode 100644 doc/src/sgml/man7/ALTER_FOREIGN_DATA_WRAPPER.7 create mode 100644 doc/src/sgml/man7/ALTER_FOREIGN_TABLE.7 create mode 100644 doc/src/sgml/man7/ALTER_FUNCTION.7 create mode 100644 doc/src/sgml/man7/ALTER_GROUP.7 create mode 100644 doc/src/sgml/man7/ALTER_INDEX.7 create mode 100644 doc/src/sgml/man7/ALTER_LANGUAGE.7 create mode 100644 doc/src/sgml/man7/ALTER_LARGE_OBJECT.7 create mode 100644 doc/src/sgml/man7/ALTER_OPERATOR.7 create mode 100644 doc/src/sgml/man7/ALTER_OPERATOR_CLASS.7 create mode 100644 doc/src/sgml/man7/ALTER_OPERATOR_FAMILY.7 create mode 100644 doc/src/sgml/man7/ALTER_ROLE.7 create mode 100644 doc/src/sgml/man7/ALTER_SCHEMA.7 create mode 100644 doc/src/sgml/man7/ALTER_SEQUENCE.7 create mode 100644 doc/src/sgml/man7/ALTER_SERVER.7 create mode 100644 doc/src/sgml/man7/ALTER_TABLE.7 create mode 100644 doc/src/sgml/man7/ALTER_TABLESPACE.7 create mode 100644 doc/src/sgml/man7/ALTER_TEXT_SEARCH_CONFIGURATION.7 create mode 100644 doc/src/sgml/man7/ALTER_TEXT_SEARCH_DICTIONARY.7 create mode 100644 doc/src/sgml/man7/ALTER_TEXT_SEARCH_PARSER.7 create mode 100644 doc/src/sgml/man7/ALTER_TEXT_SEARCH_TEMPLATE.7 create mode 100644 doc/src/sgml/man7/ALTER_TRIGGER.7 create mode 100644 doc/src/sgml/man7/ALTER_TYPE.7 create mode 100644 doc/src/sgml/man7/ALTER_USER.7 create mode 100644 doc/src/sgml/man7/ALTER_USER_MAPPING.7 create mode 100644 doc/src/sgml/man7/ALTER_VIEW.7 create mode 100644 doc/src/sgml/man7/ANALYZE.7 create mode 100644 doc/src/sgml/man7/BEGIN.7 create mode 100644 doc/src/sgml/man7/CHECKPOINT.7 create mode 100644 doc/src/sgml/man7/CLOSE.7 create mode 100644 doc/src/sgml/man7/CLUSTER.7 create mode 100644 doc/src/sgml/man7/COMMENT.7 create mode 100644 doc/src/sgml/man7/COMMIT.7 create mode 100644 doc/src/sgml/man7/COMMIT_PREPARED.7 create mode 100644 doc/src/sgml/man7/COPY.7 create mode 100644 doc/src/sgml/man7/CREATE_AGGREGATE.7 create mode 100644 doc/src/sgml/man7/CREATE_CAST.7 create mode 100644 doc/src/sgml/man7/CREATE_COLLATION.7 create mode 100644 doc/src/sgml/man7/CREATE_CONVERSION.7 create mode 100644 doc/src/sgml/man7/CREATE_DATABASE.7 create mode 100644 doc/src/sgml/man7/CREATE_DOMAIN.7 create mode 100644 doc/src/sgml/man7/CREATE_EXTENSION.7 create mode 100644 doc/src/sgml/man7/CREATE_FOREIGN_DATA_WRAPPER.7 create mode 100644 doc/src/sgml/man7/CREATE_FOREIGN_TABLE.7 create mode 100644 doc/src/sgml/man7/CREATE_FUNCTION.7 create mode 100644 doc/src/sgml/man7/CREATE_GROUP.7 create mode 100644 doc/src/sgml/man7/CREATE_INDEX.7 create mode 100644 doc/src/sgml/man7/CREATE_LANGUAGE.7 create mode 100644 doc/src/sgml/man7/CREATE_OPERATOR.7 create mode 100644 doc/src/sgml/man7/CREATE_OPERATOR_CLASS.7 create mode 100644 doc/src/sgml/man7/CREATE_OPERATOR_FAMILY.7 create mode 100644 doc/src/sgml/man7/CREATE_ROLE.7 create mode 100644 doc/src/sgml/man7/CREATE_RULE.7 create mode 100644 doc/src/sgml/man7/CREATE_SCHEMA.7 create mode 100644 doc/src/sgml/man7/CREATE_SEQUENCE.7 create mode 100644 doc/src/sgml/man7/CREATE_SERVER.7 create mode 100644 doc/src/sgml/man7/CREATE_TABLE.7 create mode 100644 doc/src/sgml/man7/CREATE_TABLESPACE.7 create mode 100644 doc/src/sgml/man7/CREATE_TABLE_AS.7 create mode 100644 doc/src/sgml/man7/CREATE_TEXT_SEARCH_CONFIGURATION.7 create mode 100644 doc/src/sgml/man7/CREATE_TEXT_SEARCH_DICTIONARY.7 create mode 100644 doc/src/sgml/man7/CREATE_TEXT_SEARCH_PARSER.7 create mode 100644 doc/src/sgml/man7/CREATE_TEXT_SEARCH_TEMPLATE.7 create mode 100644 doc/src/sgml/man7/CREATE_TRIGGER.7 create mode 100644 doc/src/sgml/man7/CREATE_TYPE.7 create mode 100644 doc/src/sgml/man7/CREATE_USER.7 create mode 100644 doc/src/sgml/man7/CREATE_USER_MAPPING.7 create mode 100644 doc/src/sgml/man7/CREATE_VIEW.7 create mode 100644 doc/src/sgml/man7/DEALLOCATE.7 create mode 100644 doc/src/sgml/man7/DECLARE.7 create mode 100644 doc/src/sgml/man7/DELETE.7 create mode 100644 doc/src/sgml/man7/DISCARD.7 create mode 100644 doc/src/sgml/man7/DO.7 create mode 100644 doc/src/sgml/man7/DROP_AGGREGATE.7 create mode 100644 doc/src/sgml/man7/DROP_CAST.7 create mode 100644 doc/src/sgml/man7/DROP_COLLATION.7 create mode 100644 doc/src/sgml/man7/DROP_CONVERSION.7 create mode 100644 doc/src/sgml/man7/DROP_DATABASE.7 create mode 100644 doc/src/sgml/man7/DROP_DOMAIN.7 create mode 100644 doc/src/sgml/man7/DROP_EXTENSION.7 create mode 100644 doc/src/sgml/man7/DROP_FOREIGN_DATA_WRAPPER.7 create mode 100644 doc/src/sgml/man7/DROP_FOREIGN_TABLE.7 create mode 100644 doc/src/sgml/man7/DROP_FUNCTION.7 create mode 100644 doc/src/sgml/man7/DROP_GROUP.7 create mode 100644 doc/src/sgml/man7/DROP_INDEX.7 create mode 100644 doc/src/sgml/man7/DROP_LANGUAGE.7 create mode 100644 doc/src/sgml/man7/DROP_OPERATOR.7 create mode 100644 doc/src/sgml/man7/DROP_OPERATOR_CLASS.7 create mode 100644 doc/src/sgml/man7/DROP_OPERATOR_FAMILY.7 create mode 100644 doc/src/sgml/man7/DROP_OWNED.7 create mode 100644 doc/src/sgml/man7/DROP_ROLE.7 create mode 100644 doc/src/sgml/man7/DROP_RULE.7 create mode 100644 doc/src/sgml/man7/DROP_SCHEMA.7 create mode 100644 doc/src/sgml/man7/DROP_SEQUENCE.7 create mode 100644 doc/src/sgml/man7/DROP_SERVER.7 create mode 100644 doc/src/sgml/man7/DROP_TABLE.7 create mode 100644 doc/src/sgml/man7/DROP_TABLESPACE.7 create mode 100644 doc/src/sgml/man7/DROP_TEXT_SEARCH_CONFIGURATION.7 create mode 100644 doc/src/sgml/man7/DROP_TEXT_SEARCH_DICTIONARY.7 create mode 100644 doc/src/sgml/man7/DROP_TEXT_SEARCH_PARSER.7 create mode 100644 doc/src/sgml/man7/DROP_TEXT_SEARCH_TEMPLATE.7 create mode 100644 doc/src/sgml/man7/DROP_TRIGGER.7 create mode 100644 doc/src/sgml/man7/DROP_TYPE.7 create mode 100644 doc/src/sgml/man7/DROP_USER.7 create mode 100644 doc/src/sgml/man7/DROP_USER_MAPPING.7 create mode 100644 doc/src/sgml/man7/DROP_VIEW.7 create mode 100644 doc/src/sgml/man7/END.7 create mode 100644 doc/src/sgml/man7/EXECUTE.7 create mode 100644 doc/src/sgml/man7/EXPLAIN.7 create mode 100644 doc/src/sgml/man7/FETCH.7 create mode 100644 doc/src/sgml/man7/GRANT.7 create mode 100644 doc/src/sgml/man7/INSERT.7 create mode 100644 doc/src/sgml/man7/LISTEN.7 create mode 100644 doc/src/sgml/man7/LOAD.7 create mode 100644 doc/src/sgml/man7/LOCK.7 create mode 100644 doc/src/sgml/man7/MOVE.7 create mode 100644 doc/src/sgml/man7/NOTIFY.7 create mode 100644 doc/src/sgml/man7/PREPARE.7 create mode 100644 doc/src/sgml/man7/PREPARE_TRANSACTION.7 create mode 100644 doc/src/sgml/man7/REASSIGN_OWNED.7 create mode 100644 doc/src/sgml/man7/REINDEX.7 create mode 100644 doc/src/sgml/man7/RELEASE_SAVEPOINT.7 create mode 100644 doc/src/sgml/man7/RESET.7 create mode 100644 doc/src/sgml/man7/REVOKE.7 create mode 100644 doc/src/sgml/man7/ROLLBACK.7 create mode 100644 doc/src/sgml/man7/ROLLBACK_PREPARED.7 create mode 100644 doc/src/sgml/man7/ROLLBACK_TO_SAVEPOINT.7 create mode 100644 doc/src/sgml/man7/SAVEPOINT.7 create mode 100644 doc/src/sgml/man7/SECURITY_LABEL.7 create mode 100644 doc/src/sgml/man7/SELECT.7 create mode 100644 doc/src/sgml/man7/SELECT_INTO.7 create mode 100644 doc/src/sgml/man7/SET.7 create mode 100644 doc/src/sgml/man7/SET_CONSTRAINTS.7 create mode 100644 doc/src/sgml/man7/SET_ROLE.7 create mode 100644 doc/src/sgml/man7/SET_SESSION_AUTHORIZATION.7 create mode 100644 doc/src/sgml/man7/SET_TRANSACTION.7 create mode 100644 doc/src/sgml/man7/SHOW.7 create mode 100644 doc/src/sgml/man7/START_TRANSACTION.7 create mode 100644 doc/src/sgml/man7/TABLE.7 create mode 100644 doc/src/sgml/man7/TRUNCATE.7 create mode 100644 doc/src/sgml/man7/UNLISTEN.7 create mode 100644 doc/src/sgml/man7/UPDATE.7 create mode 100644 doc/src/sgml/man7/VACUUM.7 create mode 100644 doc/src/sgml/man7/VALUES.7 create mode 100644 doc/src/sgml/man7/WITH.7 delete mode 100644 dropdb.vcxproj delete mode 100644 droplang.vcxproj delete mode 100644 dropuser.vcxproj delete mode 100644 dummy_seclabel.vcxproj delete mode 100644 earthdistance.vcxproj delete mode 100644 ecpg.vcxproj delete mode 100644 euc2004_sjis2004.vcxproj delete mode 100644 euc_cn_and_mic.vcxproj delete mode 100644 euc_jp_and_sjis.vcxproj delete mode 100644 euc_kr_and_mic.vcxproj delete mode 100644 euc_tw_and_big5.vcxproj delete mode 100644 file_fdw.vcxproj delete mode 100644 fuzzystrmatch.vcxproj delete mode 100644 hstore.vcxproj delete mode 100644 initdb.vcxproj delete mode 100644 insert_username.vcxproj delete mode 100644 isn.vcxproj delete mode 100644 isolationtester.vcxproj delete mode 100644 latin2_and_win1250.vcxproj delete mode 100644 latin_and_mic.vcxproj delete mode 100644 libecpg.vcxproj delete mode 100644 libecpg_compat.vcxproj delete mode 100644 libpgport.vcxproj delete mode 100644 libpgtypes.vcxproj delete mode 100644 libpq.vcxproj delete mode 100644 libpqwalreceiver.vcxproj delete mode 100644 lo.vcxproj delete mode 100644 ltree.vcxproj delete mode 100644 moddatetime.vcxproj delete mode 100644 oid2name.vcxproj delete mode 100644 pageinspect.vcxproj delete mode 100644 passwordcheck.vcxproj delete mode 100644 pg_archivecleanup.vcxproj delete mode 100644 pg_basebackup.vcxproj delete mode 100644 pg_buffercache.vcxproj delete mode 100644 pg_config.vcxproj delete mode 100644 pg_controldata.vcxproj delete mode 100644 pg_ctl.vcxproj delete mode 100644 pg_dump.vcxproj delete mode 100644 pg_dumpall.vcxproj delete mode 100644 pg_freespacemap.vcxproj delete mode 100644 pg_isolation_regress.vcxproj delete mode 100644 pg_receivexlog.vcxproj delete mode 100644 pg_regress.vcxproj delete mode 100644 pg_regress_ecpg.vcxproj delete mode 100644 pg_resetxlog.vcxproj delete mode 100644 pg_restore.vcxproj delete mode 100644 pg_standby.vcxproj delete mode 100644 pg_stat_statements.vcxproj delete mode 100644 pg_test_fsync.vcxproj delete mode 100644 pg_test_timing.vcxproj delete mode 100644 pg_trgm.vcxproj delete mode 100644 pg_upgrade.vcxproj delete mode 100644 pg_upgrade_support.vcxproj delete mode 100644 pgbench.vcxproj delete mode 100644 pgcrypto.vcxproj delete mode 100644 pgevent.vcxproj delete mode 100644 pgrowlocks.vcxproj delete mode 100644 pgstattuple.vcxproj delete mode 100644 plpgsql.vcxproj delete mode 100644 postgres.vcxproj delete mode 100644 psql.vcxproj delete mode 100644 refint.vcxproj delete mode 100644 regress.vcxproj delete mode 100644 reindexdb.vcxproj delete mode 100644 seg.vcxproj delete mode 100644 src/.gitignore delete mode 100644 src/backend/.gitignore delete mode 100644 src/backend/bootstrap/.gitignore create mode 100644 src/backend/bootstrap/bootparse.c create mode 100644 src/backend/bootstrap/bootscanner.c delete mode 100644 src/backend/catalog/.gitignore create mode 100644 src/backend/catalog/postgres.bki create mode 100644 src/backend/catalog/postgres.description create mode 100644 src/backend/catalog/postgres.shdescription create mode 100644 src/backend/catalog/schemapg.h delete mode 100644 src/backend/parser/.gitignore create mode 100644 src/backend/parser/gram.c create mode 100644 src/backend/parser/gram.h create mode 100644 src/backend/parser/scan.c delete mode 100644 src/backend/port/.gitignore delete mode 100644 src/backend/replication/.gitignore create mode 100644 src/backend/replication/repl_gram.c create mode 100644 src/backend/replication/repl_gram.h create mode 100644 src/backend/replication/repl_scanner.c delete mode 100644 src/backend/snowball/.gitignore delete mode 100644 src/backend/utils/.gitignore create mode 100644 src/backend/utils/errcodes.h create mode 100644 src/backend/utils/fmgroids.h create mode 100644 src/backend/utils/fmgrtab.c delete mode 100644 src/backend/utils/mb/conversion_procs/.gitignore delete mode 100644 src/backend/utils/misc/.gitignore create mode 100644 src/backend/utils/misc/guc-file.c delete mode 100644 src/backend/utils/sort/.gitignore create mode 100644 src/backend/utils/sort/qsort_tuple.c delete mode 100644 src/bin/initdb/.gitignore delete mode 100644 src/bin/pg_basebackup/.gitignore delete mode 100644 src/bin/pg_config/.gitignore delete mode 100644 src/bin/pg_controldata/.gitignore delete mode 100644 src/bin/pg_ctl/.gitignore delete mode 100644 src/bin/pg_dump/.gitignore delete mode 100644 src/bin/pg_resetxlog/.gitignore delete mode 100644 src/bin/psql/.gitignore create mode 100644 src/bin/psql/psqlscan.c create mode 100644 src/bin/psql/sql_help.c create mode 100644 src/bin/psql/sql_help.h delete mode 100644 src/bin/scripts/.gitignore delete mode 100644 src/include/.gitignore delete mode 100644 src/include/catalog/.gitignore delete mode 100644 src/include/parser/.gitignore delete mode 100644 src/include/utils/.gitignore delete mode 100644 src/interfaces/ecpg/compatlib/.gitignore create mode 100644 src/interfaces/ecpg/compatlib/blibecpg_compatdll.def create mode 100644 src/interfaces/ecpg/compatlib/libecpg_compatddll.def create mode 100644 src/interfaces/ecpg/compatlib/libecpg_compatdll.def delete mode 100644 src/interfaces/ecpg/ecpglib/.gitignore create mode 100644 src/interfaces/ecpg/ecpglib/blibecpgdll.def create mode 100644 src/interfaces/ecpg/ecpglib/libecpgddll.def create mode 100644 src/interfaces/ecpg/ecpglib/libecpgdll.def delete mode 100644 src/interfaces/ecpg/include/.gitignore delete mode 100644 src/interfaces/ecpg/pgtypeslib/.gitignore create mode 100644 src/interfaces/ecpg/pgtypeslib/blibpgtypesdll.def create mode 100644 src/interfaces/ecpg/pgtypeslib/libpgtypesddll.def create mode 100644 src/interfaces/ecpg/pgtypeslib/libpgtypesdll.def delete mode 100644 src/interfaces/ecpg/preproc/.gitignore create mode 100644 src/interfaces/ecpg/preproc/pgc.c create mode 100644 src/interfaces/ecpg/preproc/preproc.c create mode 100644 src/interfaces/ecpg/preproc/preproc.h create mode 100644 src/interfaces/ecpg/preproc/preproc.y delete mode 100644 src/interfaces/ecpg/test/.gitignore delete mode 100644 src/interfaces/ecpg/test/compat_informix/.gitignore delete mode 100644 src/interfaces/ecpg/test/connect/.gitignore delete mode 100644 src/interfaces/ecpg/test/pgtypeslib/.gitignore delete mode 100644 src/interfaces/ecpg/test/preproc/.gitignore delete mode 100644 src/interfaces/ecpg/test/sql/.gitignore delete mode 100644 src/interfaces/ecpg/test/thread/.gitignore delete mode 100644 src/interfaces/libpq/.gitignore create mode 100644 src/interfaces/libpq/libpq_debugdll.def create mode 100644 src/interfaces/libpq/libpqdll.def delete mode 100644 src/pl/plperl/.gitignore delete mode 100644 src/pl/plpgsql/src/.gitignore create mode 100644 src/pl/plpgsql/src/pl_gram.c create mode 100644 src/pl/plpgsql/src/pl_gram.h create mode 100644 src/pl/plpgsql/src/plerrcodes.h delete mode 100644 src/pl/plpython/.gitignore create mode 100644 src/pl/plpython/spiexceptions.h delete mode 100644 src/pl/tcl/.gitignore delete mode 100644 src/pl/tcl/modules/.gitignore delete mode 100644 src/port/.gitignore create mode 100644 src/port/win32ver.rc delete mode 100644 src/test/isolation/.gitignore create mode 100644 src/test/isolation/specparse.c create mode 100644 src/test/isolation/specscanner.c delete mode 100644 src/test/regress/.gitignore delete mode 100644 src/test/regress/expected/.gitignore delete mode 100644 src/test/regress/sql/.gitignore delete mode 100644 src/timezone/.gitignore delete mode 100644 src/tools/entab/.gitignore delete mode 100644 tablefunc.vcxproj delete mode 100644 tcn.vcxproj delete mode 100644 test_parser.vcxproj delete mode 100644 timetravel.vcxproj delete mode 100644 tsearch2.vcxproj delete mode 100644 unaccent.vcxproj delete mode 100644 utf8_and_ascii.vcxproj delete mode 100644 utf8_and_big5.vcxproj delete mode 100644 utf8_and_cyrillic.vcxproj delete mode 100644 utf8_and_euc2004.vcxproj delete mode 100644 utf8_and_euc_cn.vcxproj delete mode 100644 utf8_and_euc_jp.vcxproj delete mode 100644 utf8_and_euc_kr.vcxproj delete mode 100644 utf8_and_euc_tw.vcxproj delete mode 100644 utf8_and_gb18030.vcxproj delete mode 100644 utf8_and_gbk.vcxproj delete mode 100644 utf8_and_iso8859.vcxproj delete mode 100644 utf8_and_iso8859_1.vcxproj delete mode 100644 utf8_and_johab.vcxproj delete mode 100644 utf8_and_sjis.vcxproj delete mode 100644 utf8_and_sjis2004.vcxproj delete mode 100644 utf8_and_uhc.vcxproj delete mode 100644 utf8_and_win.vcxproj delete mode 100644 vacuumdb.vcxproj delete mode 100644 vacuumlo.vcxproj delete mode 100644 zic.vcxproj diff --git a/.gitignore b/.gitignore deleted file mode 100644 index 1e15ce5fc..000000000 --- a/.gitignore +++ /dev/null @@ -1,32 +0,0 @@ -# Global excludes across all subdirectories -*.o -*.so -*.so.[0-9] -*.so.[0-9].[0-9] -*.sl -*.sl.[0-9] -*.sl.[0-9].[0-9] -*.dylib -*.dll -*.a -*.mo -objfiles.txt -.deps/ -*.gcno -*.gcda -*.gcov -*.gcov.out -lcov.info -*.vcproj -win32ver.rc -*.exe -lib*dll.def - -# Local excludes in root directory -/GNUmakefile -/config.log -/config.status -/pgsql.sln -/pgsql.sln.cache -/Debug/ -/Release/ diff --git a/README.md b/README.md new file mode 100644 index 000000000..5dbaf8dcf --- /dev/null +++ b/README.md @@ -0,0 +1,24 @@ +# libpq + +## Available prebuilt libraries + +All prebuilt libraries are available in the php-libs +[repositories](http://windows.php.net/downloads/php-sdk/deps/) + +# Building for PHP + +## Requirements + + * postgres sources, fetch our patched [version](https://github.com/winlibs/) or the original [sources](http://www.postgresql.org) + + * Common tools used to compile PHP + + +## Compilation + + cd src + nmake /f win32.mak USE_SSL=1 SSL_INC= SSL_LIB_PATH= + +- for debug add DEBUG=1 +- for x64 add CPU=AMD64 +- openssl is optional at the time \ No newline at end of file diff --git a/_int.vcxproj b/_int.vcxproj deleted file mode 100644 index 3194448be..000000000 --- a/_int.vcxproj +++ /dev/null @@ -1,154 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {AC22644C-9512-4D70-BEAA-B88AA7D2EE8C} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\_int\ - .\Debug\_int\ - false - .\Release\_int\ - .\Release\_int\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\_int\ - .\Debug\_int\ - .\Debug\_int\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\_int\_int.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\_int\_int.pdb - false - .\Debug\_int\_int.map - Console - MachineX86 - Debug\_int\_int.lib - .\Debug\_int\_int.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\_int Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\_int\ - .\Release\_int\ - .\Release\_int\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\_int\_int.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\_int\_int.pdb - false - .\Release\_int\_int.map - Console - MachineX86 - Release\_int\_int.lib - .\Release\_int\_int.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\_int Win32 - - - - - - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/adminpack.vcxproj b/adminpack.vcxproj deleted file mode 100644 index 98e4eac87..000000000 --- a/adminpack.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {5EC58317-179B-47E9-9A52-9AB27002A25F} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\adminpack\ - .\Debug\adminpack\ - false - .\Release\adminpack\ - .\Release\adminpack\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\adminpack\ - .\Debug\adminpack\ - .\Debug\adminpack\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\adminpack\adminpack.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\adminpack\adminpack.pdb - false - .\Debug\adminpack\adminpack.map - Console - MachineX86 - Debug\adminpack\adminpack.lib - .\Debug\adminpack\adminpack.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\adminpack Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\adminpack\ - .\Release\adminpack\ - .\Release\adminpack\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\adminpack\adminpack.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\adminpack\adminpack.pdb - false - .\Release\adminpack\adminpack.map - Console - MachineX86 - Release\adminpack\adminpack.lib - .\Release\adminpack\adminpack.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\adminpack Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/ascii_and_mic.vcxproj b/ascii_and_mic.vcxproj deleted file mode 100644 index a31cfe354..000000000 --- a/ascii_and_mic.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {905EC387-8207-4899-9E4D-AF24C31352E6} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\ascii_and_mic\ - .\Debug\ascii_and_mic\ - false - .\Release\ascii_and_mic\ - .\Release\ascii_and_mic\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\ascii_and_mic\ - .\Debug\ascii_and_mic\ - .\Debug\ascii_and_mic\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\ascii_and_mic\ascii_and_mic.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\ascii_and_mic\ascii_and_mic.pdb - false - .\Debug\ascii_and_mic\ascii_and_mic.map - Console - MachineX86 - Debug\ascii_and_mic\ascii_and_mic.lib - .\Debug\ascii_and_mic\ascii_and_mic.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\ascii_and_mic Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\ascii_and_mic\ - .\Release\ascii_and_mic\ - .\Release\ascii_and_mic\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\ascii_and_mic\ascii_and_mic.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\ascii_and_mic\ascii_and_mic.pdb - false - .\Release\ascii_and_mic\ascii_and_mic.map - Console - MachineX86 - Release\ascii_and_mic\ascii_and_mic.lib - .\Release\ascii_and_mic\ascii_and_mic.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\ascii_and_mic Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/auth_delay.vcxproj b/auth_delay.vcxproj deleted file mode 100644 index 7bd3abc84..000000000 --- a/auth_delay.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {BA5C4BEE-7AB2-455F-844A-FA863B71F0D1} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\auth_delay\ - .\Debug\auth_delay\ - false - .\Release\auth_delay\ - .\Release\auth_delay\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\auth_delay\ - .\Debug\auth_delay\ - .\Debug\auth_delay\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\auth_delay\auth_delay.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\auth_delay\auth_delay.pdb - false - .\Debug\auth_delay\auth_delay.map - Console - MachineX86 - Debug\auth_delay\auth_delay.lib - .\Debug\auth_delay\auth_delay.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\auth_delay Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\auth_delay\ - .\Release\auth_delay\ - .\Release\auth_delay\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\auth_delay\auth_delay.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\auth_delay\auth_delay.pdb - false - .\Release\auth_delay\auth_delay.map - Console - MachineX86 - Release\auth_delay\auth_delay.lib - .\Release\auth_delay\auth_delay.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\auth_delay Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/auto_explain.vcxproj b/auto_explain.vcxproj deleted file mode 100644 index d3fa8a9d1..000000000 --- a/auto_explain.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {5A700A64-A3B0-40AD-9B83-43DF9B70D315} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\auto_explain\ - .\Debug\auto_explain\ - false - .\Release\auto_explain\ - .\Release\auto_explain\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\auto_explain\ - .\Debug\auto_explain\ - .\Debug\auto_explain\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\auto_explain\auto_explain.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\auto_explain\auto_explain.pdb - false - .\Debug\auto_explain\auto_explain.map - Console - MachineX86 - Debug\auto_explain\auto_explain.lib - .\Debug\auto_explain\auto_explain.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\auto_explain Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\auto_explain\ - .\Release\auto_explain\ - .\Release\auto_explain\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\auto_explain\auto_explain.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\auto_explain\auto_explain.pdb - false - .\Release\auto_explain\auto_explain.map - Console - MachineX86 - Release\auto_explain\auto_explain.lib - .\Release\auto_explain\auto_explain.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\auto_explain Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/autoinc.vcxproj b/autoinc.vcxproj deleted file mode 100644 index 2016a9f72..000000000 --- a/autoinc.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {2CDD212C-B468-43C4-A79B-941566BB6228} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\autoinc\ - .\Debug\autoinc\ - false - .\Release\autoinc\ - .\Release\autoinc\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\autoinc\ - .\Debug\autoinc\ - .\Debug\autoinc\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\autoinc\autoinc.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\autoinc\autoinc.pdb - false - .\Debug\autoinc\autoinc.map - Console - MachineX86 - Debug\autoinc\autoinc.lib - .\Debug\autoinc\autoinc.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\autoinc Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\autoinc\ - .\Release\autoinc\ - .\Release\autoinc\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\autoinc\autoinc.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\autoinc\autoinc.pdb - false - .\Release\autoinc\autoinc.map - Console - MachineX86 - Release\autoinc\autoinc.lib - .\Release\autoinc\autoinc.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\autoinc Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/btree_gin.vcxproj b/btree_gin.vcxproj deleted file mode 100644 index e9093e2ca..000000000 --- a/btree_gin.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {81F8A3A9-B761-4005-8BF3-29EEA4603685} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\btree_gin\ - .\Debug\btree_gin\ - false - .\Release\btree_gin\ - .\Release\btree_gin\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\btree_gin\ - .\Debug\btree_gin\ - .\Debug\btree_gin\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\btree_gin\btree_gin.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\btree_gin\btree_gin.pdb - false - .\Debug\btree_gin\btree_gin.map - Console - MachineX86 - Debug\btree_gin\btree_gin.lib - .\Debug\btree_gin\btree_gin.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\btree_gin Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\btree_gin\ - .\Release\btree_gin\ - .\Release\btree_gin\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\btree_gin\btree_gin.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\btree_gin\btree_gin.pdb - false - .\Release\btree_gin\btree_gin.map - Console - MachineX86 - Release\btree_gin\btree_gin.lib - .\Release\btree_gin\btree_gin.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\btree_gin Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/btree_gist.vcxproj b/btree_gist.vcxproj deleted file mode 100644 index afe6fffab..000000000 --- a/btree_gist.vcxproj +++ /dev/null @@ -1,168 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {B0A7EF59-63F6-4250-86B8-06F013D7D494} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\btree_gist\ - .\Debug\btree_gist\ - false - .\Release\btree_gist\ - .\Release\btree_gist\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\btree_gist\ - .\Debug\btree_gist\ - .\Debug\btree_gist\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\btree_gist\btree_gist.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\btree_gist\btree_gist.pdb - false - .\Debug\btree_gist\btree_gist.map - Console - MachineX86 - Debug\btree_gist\btree_gist.lib - .\Debug\btree_gist\btree_gist.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\btree_gist Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\btree_gist\ - .\Release\btree_gist\ - .\Release\btree_gist\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\btree_gist\btree_gist.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\btree_gist\btree_gist.pdb - false - .\Release\btree_gist\btree_gist.map - Console - MachineX86 - Release\btree_gist\btree_gist.lib - .\Release\btree_gist\btree_gist.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\btree_gist Win32 - - - - - - - - - - - - - - - - - - - - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/chkpass.vcxproj b/chkpass.vcxproj deleted file mode 100644 index 88f6215af..000000000 --- a/chkpass.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {7B6F65A9-3441-401A-9E5C-749156BDAA4F} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\chkpass\ - .\Debug\chkpass\ - false - .\Release\chkpass\ - .\Release\chkpass\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\chkpass\ - .\Debug\chkpass\ - .\Debug\chkpass\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\chkpass\chkpass.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\chkpass\chkpass.pdb - false - .\Debug\chkpass\chkpass.map - Console - MachineX86 - Debug\chkpass\chkpass.lib - .\Debug\chkpass\chkpass.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\chkpass Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\chkpass\ - .\Release\chkpass\ - .\Release\chkpass\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\chkpass\chkpass.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\chkpass\chkpass.pdb - false - .\Release\chkpass\chkpass.map - Console - MachineX86 - Release\chkpass\chkpass.lib - .\Release\chkpass\chkpass.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\chkpass Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/citext.vcxproj b/citext.vcxproj deleted file mode 100644 index 9901d9d6d..000000000 --- a/citext.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {E8829835-4D5E-45AF-AD7C-C3F40B5A2018} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\citext\ - .\Debug\citext\ - false - .\Release\citext\ - .\Release\citext\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\citext\ - .\Debug\citext\ - .\Debug\citext\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\citext\citext.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\citext\citext.pdb - false - .\Debug\citext\citext.map - Console - MachineX86 - Debug\citext\citext.lib - .\Debug\citext\citext.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\citext Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\citext\ - .\Release\citext\ - .\Release\citext\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\citext\citext.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\citext\citext.pdb - false - .\Release\citext\citext.map - Console - MachineX86 - Release\citext\citext.lib - .\Release\citext\citext.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\citext Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/clusterdb.vcxproj b/clusterdb.vcxproj deleted file mode 100644 index f95dd0904..000000000 --- a/clusterdb.vcxproj +++ /dev/null @@ -1,147 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {31D6C585-2703-4423-8E2C-A674872DD43E} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\clusterdb\ - .\Debug\clusterdb\ - false - .\Release\clusterdb\ - .\Release\clusterdb\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\bin\pg_dump;src\bin\psql;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\clusterdb\ - .\Debug\clusterdb\ - .\Debug\clusterdb\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\clusterdb\clusterdb.exe - Debug\libpq\libpq.lib;Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\clusterdb\clusterdb.pdb - false - .\Debug\clusterdb\clusterdb.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\bin\pg_dump;src\bin\psql;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\clusterdb\ - .\Release\clusterdb\ - .\Release\clusterdb\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\clusterdb\clusterdb.exe - Release\libpq\libpq.lib;Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\clusterdb\clusterdb.pdb - false - .\Release\clusterdb\clusterdb.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - - - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/contrib/btree_gin/.gitignore b/contrib/btree_gin/.gitignore deleted file mode 100644 index 5dcb3ff97..000000000 --- a/contrib/btree_gin/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -# Generated subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/contrib/btree_gist/.gitignore b/contrib/btree_gist/.gitignore deleted file mode 100644 index 5dcb3ff97..000000000 --- a/contrib/btree_gist/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -# Generated subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/contrib/citext/.gitignore b/contrib/citext/.gitignore deleted file mode 100644 index 5dcb3ff97..000000000 --- a/contrib/citext/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -# Generated subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/contrib/cube/.gitignore b/contrib/cube/.gitignore deleted file mode 100644 index cb4c989ff..000000000 --- a/contrib/cube/.gitignore +++ /dev/null @@ -1,6 +0,0 @@ -/cubeparse.c -/cubescan.c -# Generated subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/contrib/cube/cubeparse.c b/contrib/cube/cubeparse.c new file mode 100644 index 000000000..f4f0a7541 --- /dev/null +++ b/contrib/cube/cubeparse.c @@ -0,0 +1,1779 @@ + +/* A Bison parser, made by GNU Bison 2.4.1. */ + +/* Skeleton implementation for Bison's Yacc-like parsers in C + + Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 + Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . */ + +/* As a special exception, you may create a larger work that contains + part or all of the Bison parser skeleton and distribute that work + under terms of your choice, so long as that work isn't itself a + parser generator using the skeleton or a modified version thereof + as a parser skeleton. Alternatively, if you modify or redistribute + the parser skeleton itself, you may (at your option) remove this + special exception, which will cause the skeleton and the resulting + Bison output files to be licensed under the GNU General Public + License without this special exception. + + This special exception was added by the Free Software Foundation in + version 2.2 of Bison. */ + +/* C LALR(1) parser skeleton written by Richard Stallman, by + simplifying the original so-called "semantic" parser. */ + +/* All symbols defined below should begin with yy or YY, to avoid + infringing on user name space. This should be done even for local + variables, as they might otherwise be expanded by user macros. + There are some unavoidable exceptions within include files to + define necessary library symbols; they are noted "INFRINGES ON + USER NAME SPACE" below. */ + +/* Identify Bison output. */ +#define YYBISON 1 + +/* Bison version. */ +#define YYBISON_VERSION "2.4.1" + +/* Skeleton name. */ +#define YYSKELETON_NAME "yacc.c" + +/* Pure parsers. */ +#define YYPURE 0 + +/* Push parsers. */ +#define YYPUSH 0 + +/* Pull parsers. */ +#define YYPULL 1 + +/* Using locations. */ +#define YYLSP_NEEDED 0 + +/* Substitute the variable and function names. */ +#define yyparse cube_yyparse +#define yylex cube_yylex +#define yyerror cube_yyerror +#define yylval cube_yylval +#define yychar cube_yychar +#define yydebug cube_yydebug +#define yynerrs cube_yynerrs + + +/* Copy the first part of user declarations. */ + +/* Line 189 of yacc.c */ +#line 1 "cubeparse.y" + +/* NdBox = [(lowerleft),(upperright)] */ +/* [(xLL(1)...xLL(N)),(xUR(1)...xUR(n))] */ + +/* contrib/cube/cubeparse.y */ + +#define YYPARSE_PARAM result /* need this to pass a pointer (void *) to yyparse */ +#define YYSTYPE char * +#define YYDEBUG 1 + +#include "postgres.h" + +#include "cubedata.h" + +/* + * Bison doesn't allocate anything that needs to live across parser calls, + * so we can easily have it use palloc instead of malloc. This prevents + * memory leaks if we error out during parsing. Note this only works with + * bison >= 2.0. However, in bison 1.875 the default is to use alloca() + * if possible, so there's not really much problem anyhow, at least if + * you're building with gcc. + */ +#define YYMALLOC palloc +#define YYFREE pfree + +extern int cube_yylex(void); + +static char *scanbuf; +static int scanbuflen; + +void cube_yyerror(const char *message); +int cube_yyparse(void *result); + +static int delim_count(char *s, char delim); +static NDBOX * write_box(unsigned int dim, char *str1, char *str2); +static NDBOX * write_point_as_box(char *s, int dim); + + + +/* Line 189 of yacc.c */ +#line 121 "cubeparse.c" + +/* Enabling traces. */ +#ifndef YYDEBUG +# define YYDEBUG 0 +#endif + +/* Enabling verbose error messages. */ +#ifdef YYERROR_VERBOSE +# undef YYERROR_VERBOSE +# define YYERROR_VERBOSE 1 +#else +# define YYERROR_VERBOSE 0 +#endif + +/* Enabling the token table. */ +#ifndef YYTOKEN_TABLE +# define YYTOKEN_TABLE 0 +#endif + + +/* Tokens. */ +#ifndef YYTOKENTYPE +# define YYTOKENTYPE + /* Put the tokens into the symbol table, so that GDB and other debuggers + know about them. */ + enum yytokentype { + CUBEFLOAT = 258, + O_PAREN = 259, + C_PAREN = 260, + O_BRACKET = 261, + C_BRACKET = 262, + COMMA = 263 + }; +#endif + + + +#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED +typedef int YYSTYPE; +# define YYSTYPE_IS_TRIVIAL 1 +# define yystype YYSTYPE /* obsolescent; will be withdrawn */ +# define YYSTYPE_IS_DECLARED 1 +#endif + + +/* Copy the second part of user declarations. */ + + +/* Line 264 of yacc.c */ +#line 171 "cubeparse.c" + +#ifdef short +# undef short +#endif + +#ifdef YYTYPE_UINT8 +typedef YYTYPE_UINT8 yytype_uint8; +#else +typedef unsigned char yytype_uint8; +#endif + +#ifdef YYTYPE_INT8 +typedef YYTYPE_INT8 yytype_int8; +#elif (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +typedef signed char yytype_int8; +#else +typedef short int yytype_int8; +#endif + +#ifdef YYTYPE_UINT16 +typedef YYTYPE_UINT16 yytype_uint16; +#else +typedef unsigned short int yytype_uint16; +#endif + +#ifdef YYTYPE_INT16 +typedef YYTYPE_INT16 yytype_int16; +#else +typedef short int yytype_int16; +#endif + +#ifndef YYSIZE_T +# ifdef __SIZE_TYPE__ +# define YYSIZE_T __SIZE_TYPE__ +# elif defined size_t +# define YYSIZE_T size_t +# elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +# include /* INFRINGES ON USER NAME SPACE */ +# define YYSIZE_T size_t +# else +# define YYSIZE_T unsigned int +# endif +#endif + +#define YYSIZE_MAXIMUM ((YYSIZE_T) -1) + +#ifndef YY_ +# if YYENABLE_NLS +# if ENABLE_NLS +# include /* INFRINGES ON USER NAME SPACE */ +# define YY_(msgid) dgettext ("bison-runtime", msgid) +# endif +# endif +# ifndef YY_ +# define YY_(msgid) msgid +# endif +#endif + +/* Suppress unused-variable warnings by "using" E. */ +#if ! defined lint || defined __GNUC__ +# define YYUSE(e) ((void) (e)) +#else +# define YYUSE(e) /* empty */ +#endif + +/* Identity function, used to suppress warnings about constant conditions. */ +#ifndef lint +# define YYID(n) (n) +#else +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static int +YYID (int yyi) +#else +static int +YYID (yyi) + int yyi; +#endif +{ + return yyi; +} +#endif + +#if ! defined yyoverflow || YYERROR_VERBOSE + +/* The parser invokes alloca or malloc; define the necessary symbols. */ + +# ifdef YYSTACK_USE_ALLOCA +# if YYSTACK_USE_ALLOCA +# ifdef __GNUC__ +# define YYSTACK_ALLOC __builtin_alloca +# elif defined __BUILTIN_VA_ARG_INCR +# include /* INFRINGES ON USER NAME SPACE */ +# elif defined _AIX +# define YYSTACK_ALLOC __alloca +# elif defined _MSC_VER +# include /* INFRINGES ON USER NAME SPACE */ +# define alloca _alloca +# else +# define YYSTACK_ALLOC alloca +# if ! defined _ALLOCA_H && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +# include /* INFRINGES ON USER NAME SPACE */ +# ifndef _STDLIB_H +# define _STDLIB_H 1 +# endif +# endif +# endif +# endif +# endif + +# ifdef YYSTACK_ALLOC + /* Pacify GCC's `empty if-body' warning. */ +# define YYSTACK_FREE(Ptr) do { /* empty */; } while (YYID (0)) +# ifndef YYSTACK_ALLOC_MAXIMUM + /* The OS might guarantee only one guard page at the bottom of the stack, + and a page size can be as small as 4096 bytes. So we cannot safely + invoke alloca (N) if N exceeds 4096. Use a slightly smaller number + to allow for a few compiler-allocated temporary stack slots. */ +# define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */ +# endif +# else +# define YYSTACK_ALLOC YYMALLOC +# define YYSTACK_FREE YYFREE +# ifndef YYSTACK_ALLOC_MAXIMUM +# define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM +# endif +# if (defined __cplusplus && ! defined _STDLIB_H \ + && ! ((defined YYMALLOC || defined malloc) \ + && (defined YYFREE || defined free))) +# include /* INFRINGES ON USER NAME SPACE */ +# ifndef _STDLIB_H +# define _STDLIB_H 1 +# endif +# endif +# ifndef YYMALLOC +# define YYMALLOC malloc +# if ! defined malloc && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */ +# endif +# endif +# ifndef YYFREE +# define YYFREE free +# if ! defined free && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +void free (void *); /* INFRINGES ON USER NAME SPACE */ +# endif +# endif +# endif +#endif /* ! defined yyoverflow || YYERROR_VERBOSE */ + + +#if (! defined yyoverflow \ + && (! defined __cplusplus \ + || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) + +/* A type that is properly aligned for any stack member. */ +union yyalloc +{ + yytype_int16 yyss_alloc; + YYSTYPE yyvs_alloc; +}; + +/* The size of the maximum gap between one aligned stack and the next. */ +# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1) + +/* The size of an array large to enough to hold all stacks, each with + N elements. */ +# define YYSTACK_BYTES(N) \ + ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \ + + YYSTACK_GAP_MAXIMUM) + +/* Copy COUNT objects from FROM to TO. The source and destination do + not overlap. */ +# ifndef YYCOPY +# if defined __GNUC__ && 1 < __GNUC__ +# define YYCOPY(To, From, Count) \ + __builtin_memcpy (To, From, (Count) * sizeof (*(From))) +# else +# define YYCOPY(To, From, Count) \ + do \ + { \ + YYSIZE_T yyi; \ + for (yyi = 0; yyi < (Count); yyi++) \ + (To)[yyi] = (From)[yyi]; \ + } \ + while (YYID (0)) +# endif +# endif + +/* Relocate STACK from its old location to the new one. The + local variables YYSIZE and YYSTACKSIZE give the old and new number of + elements in the stack, and YYPTR gives the new location of the + stack. Advance YYPTR to a properly aligned location for the next + stack. */ +# define YYSTACK_RELOCATE(Stack_alloc, Stack) \ + do \ + { \ + YYSIZE_T yynewbytes; \ + YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \ + Stack = &yyptr->Stack_alloc; \ + yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ + yyptr += yynewbytes / sizeof (*yyptr); \ + } \ + while (YYID (0)) + +#endif + +/* YYFINAL -- State number of the termination state. */ +#define YYFINAL 9 +/* YYLAST -- Last index in YYTABLE. */ +#define YYLAST 17 + +/* YYNTOKENS -- Number of terminals. */ +#define YYNTOKENS 9 +/* YYNNTS -- Number of nonterminals. */ +#define YYNNTS 4 +/* YYNRULES -- Number of rules. */ +#define YYNRULES 8 +/* YYNRULES -- Number of states. */ +#define YYNSTATES 18 + +/* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */ +#define YYUNDEFTOK 2 +#define YYMAXUTOK 263 + +#define YYTRANSLATE(YYX) \ + ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) + +/* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */ +static const yytype_uint8 yytranslate[] = +{ + 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 1, 2, 3, 4, + 5, 6, 7, 8 +}; + +#if YYDEBUG +/* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in + YYRHS. */ +static const yytype_uint8 yyprhs[] = +{ + 0, 0, 3, 9, 13, 15, 17, 21, 23 +}; + +/* YYRHS -- A `-1'-separated list of the rules' RHS. */ +static const yytype_int8 yyrhs[] = +{ + 10, 0, -1, 6, 11, 8, 11, 7, -1, 11, + 8, 11, -1, 11, -1, 12, -1, 4, 12, 5, + -1, 3, -1, 12, 8, 3, -1 +}; + +/* YYRLINE[YYN] -- source line where rule number YYN was defined. */ +static const yytype_uint8 yyrline[] = +{ + 0, 50, 50, 77, 103, 120, 137, 143, 149 +}; +#endif + +#if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE +/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM. + First, the terminals, then, starting at YYNTOKENS, nonterminals. */ +static const char *const yytname[] = +{ + "$end", "error", "$undefined", "CUBEFLOAT", "O_PAREN", "C_PAREN", + "O_BRACKET", "C_BRACKET", "COMMA", "$accept", "box", "paren_list", + "list", 0 +}; +#endif + +# ifdef YYPRINT +/* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to + token YYLEX-NUM. */ +static const yytype_uint16 yytoknum[] = +{ + 0, 256, 257, 258, 259, 260, 261, 262, 263 +}; +# endif + +/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ +static const yytype_uint8 yyr1[] = +{ + 0, 9, 10, 10, 10, 10, 11, 12, 12 +}; + +/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */ +static const yytype_uint8 yyr2[] = +{ + 0, 2, 5, 3, 1, 1, 3, 1, 3 +}; + +/* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state + STATE-NUM when YYTABLE doesn't specify something else to do. Zero + means the default is an error. */ +static const yytype_uint8 yydefact[] = +{ + 0, 7, 0, 0, 0, 4, 5, 0, 0, 1, + 0, 0, 6, 0, 3, 8, 0, 2 +}; + +/* YYDEFGOTO[NTERM-NUM]. */ +static const yytype_int8 yydefgoto[] = +{ + -1, 4, 5, 6 +}; + +/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing + STATE-NUM. */ +#define YYPACT_NINF -4 +static const yytype_int8 yypact[] = +{ + -2, -4, 3, -1, 9, 4, 5, 0, 6, -4, + -1, 8, -4, -1, -4, -4, 10, -4 +}; + +/* YYPGOTO[NTERM-NUM]. */ +static const yytype_int8 yypgoto[] = +{ + -4, -4, -3, 13 +}; + +/* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If + positive, shift that token. If negative, reduce the rule which + number is the opposite. If zero, do what YYDEFACT says. + If YYTABLE_NINF, syntax error. */ +#define YYTABLE_NINF -1 +static const yytype_uint8 yytable[] = +{ + 8, 1, 2, 2, 3, 12, 1, 14, 11, 9, + 16, 15, 10, 11, 13, 7, 0, 17 +}; + +static const yytype_int8 yycheck[] = +{ + 3, 3, 4, 4, 6, 5, 3, 10, 8, 0, + 13, 3, 8, 8, 8, 2, -1, 7 +}; + +/* YYSTOS[STATE-NUM] -- The (internal number of the) accessing + symbol of state STATE-NUM. */ +static const yytype_uint8 yystos[] = +{ + 0, 3, 4, 6, 10, 11, 12, 12, 11, 0, + 8, 8, 5, 8, 11, 3, 11, 7 +}; + +#define yyerrok (yyerrstatus = 0) +#define yyclearin (yychar = YYEMPTY) +#define YYEMPTY (-2) +#define YYEOF 0 + +#define YYACCEPT goto yyacceptlab +#define YYABORT goto yyabortlab +#define YYERROR goto yyerrorlab + + +/* Like YYERROR except do call yyerror. This remains here temporarily + to ease the transition to the new meaning of YYERROR, for GCC. + Once GCC version 2 has supplanted version 1, this can go. */ + +#define YYFAIL goto yyerrlab + +#define YYRECOVERING() (!!yyerrstatus) + +#define YYBACKUP(Token, Value) \ +do \ + if (yychar == YYEMPTY && yylen == 1) \ + { \ + yychar = (Token); \ + yylval = (Value); \ + yytoken = YYTRANSLATE (yychar); \ + YYPOPSTACK (1); \ + goto yybackup; \ + } \ + else \ + { \ + yyerror (YY_("syntax error: cannot back up")); \ + YYERROR; \ + } \ +while (YYID (0)) + + +#define YYTERROR 1 +#define YYERRCODE 256 + + +/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N]. + If N is 0, then set CURRENT to the empty location which ends + the previous symbol: RHS[0] (always defined). */ + +#define YYRHSLOC(Rhs, K) ((Rhs)[K]) +#ifndef YYLLOC_DEFAULT +# define YYLLOC_DEFAULT(Current, Rhs, N) \ + do \ + if (YYID (N)) \ + { \ + (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \ + (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \ + (Current).last_line = YYRHSLOC (Rhs, N).last_line; \ + (Current).last_column = YYRHSLOC (Rhs, N).last_column; \ + } \ + else \ + { \ + (Current).first_line = (Current).last_line = \ + YYRHSLOC (Rhs, 0).last_line; \ + (Current).first_column = (Current).last_column = \ + YYRHSLOC (Rhs, 0).last_column; \ + } \ + while (YYID (0)) +#endif + + +/* YY_LOCATION_PRINT -- Print the location on the stream. + This macro was not mandated originally: define only if we know + we won't break user code: when these are the locations we know. */ + +#ifndef YY_LOCATION_PRINT +# if YYLTYPE_IS_TRIVIAL +# define YY_LOCATION_PRINT(File, Loc) \ + fprintf (File, "%d.%d-%d.%d", \ + (Loc).first_line, (Loc).first_column, \ + (Loc).last_line, (Loc).last_column) +# else +# define YY_LOCATION_PRINT(File, Loc) ((void) 0) +# endif +#endif + + +/* YYLEX -- calling `yylex' with the right arguments. */ + +#ifdef YYLEX_PARAM +# define YYLEX yylex (YYLEX_PARAM) +#else +# define YYLEX yylex () +#endif + +/* Enable debugging if requested. */ +#if YYDEBUG + +# ifndef YYFPRINTF +# include /* INFRINGES ON USER NAME SPACE */ +# define YYFPRINTF fprintf +# endif + +# define YYDPRINTF(Args) \ +do { \ + if (yydebug) \ + YYFPRINTF Args; \ +} while (YYID (0)) + +# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \ +do { \ + if (yydebug) \ + { \ + YYFPRINTF (stderr, "%s ", Title); \ + yy_symbol_print (stderr, \ + Type, Value); \ + YYFPRINTF (stderr, "\n"); \ + } \ +} while (YYID (0)) + + +/*--------------------------------. +| Print this symbol on YYOUTPUT. | +`--------------------------------*/ + +/*ARGSUSED*/ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep) +#else +static void +yy_symbol_value_print (yyoutput, yytype, yyvaluep) + FILE *yyoutput; + int yytype; + YYSTYPE const * const yyvaluep; +#endif +{ + if (!yyvaluep) + return; +# ifdef YYPRINT + if (yytype < YYNTOKENS) + YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep); +# else + YYUSE (yyoutput); +# endif + switch (yytype) + { + default: + break; + } +} + + +/*--------------------------------. +| Print this symbol on YYOUTPUT. | +`--------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep) +#else +static void +yy_symbol_print (yyoutput, yytype, yyvaluep) + FILE *yyoutput; + int yytype; + YYSTYPE const * const yyvaluep; +#endif +{ + if (yytype < YYNTOKENS) + YYFPRINTF (yyoutput, "token %s (", yytname[yytype]); + else + YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]); + + yy_symbol_value_print (yyoutput, yytype, yyvaluep); + YYFPRINTF (yyoutput, ")"); +} + +/*------------------------------------------------------------------. +| yy_stack_print -- Print the state stack from its BOTTOM up to its | +| TOP (included). | +`------------------------------------------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop) +#else +static void +yy_stack_print (yybottom, yytop) + yytype_int16 *yybottom; + yytype_int16 *yytop; +#endif +{ + YYFPRINTF (stderr, "Stack now"); + for (; yybottom <= yytop; yybottom++) + { + int yybot = *yybottom; + YYFPRINTF (stderr, " %d", yybot); + } + YYFPRINTF (stderr, "\n"); +} + +# define YY_STACK_PRINT(Bottom, Top) \ +do { \ + if (yydebug) \ + yy_stack_print ((Bottom), (Top)); \ +} while (YYID (0)) + + +/*------------------------------------------------. +| Report that the YYRULE is going to be reduced. | +`------------------------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_reduce_print (YYSTYPE *yyvsp, int yyrule) +#else +static void +yy_reduce_print (yyvsp, yyrule) + YYSTYPE *yyvsp; + int yyrule; +#endif +{ + int yynrhs = yyr2[yyrule]; + int yyi; + unsigned long int yylno = yyrline[yyrule]; + YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n", + yyrule - 1, yylno); + /* The symbols being reduced. */ + for (yyi = 0; yyi < yynrhs; yyi++) + { + YYFPRINTF (stderr, " $%d = ", yyi + 1); + yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi], + &(yyvsp[(yyi + 1) - (yynrhs)]) + ); + YYFPRINTF (stderr, "\n"); + } +} + +# define YY_REDUCE_PRINT(Rule) \ +do { \ + if (yydebug) \ + yy_reduce_print (yyvsp, Rule); \ +} while (YYID (0)) + +/* Nonzero means print parse trace. It is left uninitialized so that + multiple parsers can coexist. */ +int yydebug; +#else /* !YYDEBUG */ +# define YYDPRINTF(Args) +# define YY_SYMBOL_PRINT(Title, Type, Value, Location) +# define YY_STACK_PRINT(Bottom, Top) +# define YY_REDUCE_PRINT(Rule) +#endif /* !YYDEBUG */ + + +/* YYINITDEPTH -- initial size of the parser's stacks. */ +#ifndef YYINITDEPTH +# define YYINITDEPTH 200 +#endif + +/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only + if the built-in stack extension method is used). + + Do not make this value too large; the results are undefined if + YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH) + evaluated with infinite-precision integer arithmetic. */ + +#ifndef YYMAXDEPTH +# define YYMAXDEPTH 10000 +#endif + + + +#if YYERROR_VERBOSE + +# ifndef yystrlen +# if defined __GLIBC__ && defined _STRING_H +# define yystrlen strlen +# else +/* Return the length of YYSTR. */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static YYSIZE_T +yystrlen (const char *yystr) +#else +static YYSIZE_T +yystrlen (yystr) + const char *yystr; +#endif +{ + YYSIZE_T yylen; + for (yylen = 0; yystr[yylen]; yylen++) + continue; + return yylen; +} +# endif +# endif + +# ifndef yystpcpy +# if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE +# define yystpcpy stpcpy +# else +/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in + YYDEST. */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static char * +yystpcpy (char *yydest, const char *yysrc) +#else +static char * +yystpcpy (yydest, yysrc) + char *yydest; + const char *yysrc; +#endif +{ + char *yyd = yydest; + const char *yys = yysrc; + + while ((*yyd++ = *yys++) != '\0') + continue; + + return yyd - 1; +} +# endif +# endif + +# ifndef yytnamerr +/* Copy to YYRES the contents of YYSTR after stripping away unnecessary + quotes and backslashes, so that it's suitable for yyerror. The + heuristic is that double-quoting is unnecessary unless the string + contains an apostrophe, a comma, or backslash (other than + backslash-backslash). YYSTR is taken from yytname. If YYRES is + null, do not copy; instead, return the length of what the result + would have been. */ +static YYSIZE_T +yytnamerr (char *yyres, const char *yystr) +{ + if (*yystr == '"') + { + YYSIZE_T yyn = 0; + char const *yyp = yystr; + + for (;;) + switch (*++yyp) + { + case '\'': + case ',': + goto do_not_strip_quotes; + + case '\\': + if (*++yyp != '\\') + goto do_not_strip_quotes; + /* Fall through. */ + default: + if (yyres) + yyres[yyn] = *yyp; + yyn++; + break; + + case '"': + if (yyres) + yyres[yyn] = '\0'; + return yyn; + } + do_not_strip_quotes: ; + } + + if (! yyres) + return yystrlen (yystr); + + return yystpcpy (yyres, yystr) - yyres; +} +# endif + +/* Copy into YYRESULT an error message about the unexpected token + YYCHAR while in state YYSTATE. Return the number of bytes copied, + including the terminating null byte. If YYRESULT is null, do not + copy anything; just return the number of bytes that would be + copied. As a special case, return 0 if an ordinary "syntax error" + message will do. Return YYSIZE_MAXIMUM if overflow occurs during + size calculation. */ +static YYSIZE_T +yysyntax_error (char *yyresult, int yystate, int yychar) +{ + int yyn = yypact[yystate]; + + if (! (YYPACT_NINF < yyn && yyn <= YYLAST)) + return 0; + else + { + int yytype = YYTRANSLATE (yychar); + YYSIZE_T yysize0 = yytnamerr (0, yytname[yytype]); + YYSIZE_T yysize = yysize0; + YYSIZE_T yysize1; + int yysize_overflow = 0; + enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; + char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; + int yyx; + +# if 0 + /* This is so xgettext sees the translatable formats that are + constructed on the fly. */ + YY_("syntax error, unexpected %s"); + YY_("syntax error, unexpected %s, expecting %s"); + YY_("syntax error, unexpected %s, expecting %s or %s"); + YY_("syntax error, unexpected %s, expecting %s or %s or %s"); + YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"); +# endif + char *yyfmt; + char const *yyf; + static char const yyunexpected[] = "syntax error, unexpected %s"; + static char const yyexpecting[] = ", expecting %s"; + static char const yyor[] = " or %s"; + char yyformat[sizeof yyunexpected + + sizeof yyexpecting - 1 + + ((YYERROR_VERBOSE_ARGS_MAXIMUM - 2) + * (sizeof yyor - 1))]; + char const *yyprefix = yyexpecting; + + /* Start YYX at -YYN if negative to avoid negative indexes in + YYCHECK. */ + int yyxbegin = yyn < 0 ? -yyn : 0; + + /* Stay within bounds of both yycheck and yytname. */ + int yychecklim = YYLAST - yyn + 1; + int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; + int yycount = 1; + + yyarg[0] = yytname[yytype]; + yyfmt = yystpcpy (yyformat, yyunexpected); + + for (yyx = yyxbegin; yyx < yyxend; ++yyx) + if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR) + { + if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) + { + yycount = 1; + yysize = yysize0; + yyformat[sizeof yyunexpected - 1] = '\0'; + break; + } + yyarg[yycount++] = yytname[yyx]; + yysize1 = yysize + yytnamerr (0, yytname[yyx]); + yysize_overflow |= (yysize1 < yysize); + yysize = yysize1; + yyfmt = yystpcpy (yyfmt, yyprefix); + yyprefix = yyor; + } + + yyf = YY_(yyformat); + yysize1 = yysize + yystrlen (yyf); + yysize_overflow |= (yysize1 < yysize); + yysize = yysize1; + + if (yysize_overflow) + return YYSIZE_MAXIMUM; + + if (yyresult) + { + /* Avoid sprintf, as that infringes on the user's name space. + Don't have undefined behavior even if the translation + produced a string with the wrong number of "%s"s. */ + char *yyp = yyresult; + int yyi = 0; + while ((*yyp = *yyf) != '\0') + { + if (*yyp == '%' && yyf[1] == 's' && yyi < yycount) + { + yyp += yytnamerr (yyp, yyarg[yyi++]); + yyf += 2; + } + else + { + yyp++; + yyf++; + } + } + } + return yysize; + } +} +#endif /* YYERROR_VERBOSE */ + + +/*-----------------------------------------------. +| Release the memory associated to this symbol. | +`-----------------------------------------------*/ + +/*ARGSUSED*/ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep) +#else +static void +yydestruct (yymsg, yytype, yyvaluep) + const char *yymsg; + int yytype; + YYSTYPE *yyvaluep; +#endif +{ + YYUSE (yyvaluep); + + if (!yymsg) + yymsg = "Deleting"; + YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp); + + switch (yytype) + { + + default: + break; + } +} + +/* Prevent warnings from -Wmissing-prototypes. */ +#ifdef YYPARSE_PARAM +#if defined __STDC__ || defined __cplusplus +int yyparse (void *YYPARSE_PARAM); +#else +int yyparse (); +#endif +#else /* ! YYPARSE_PARAM */ +#if defined __STDC__ || defined __cplusplus +int yyparse (void); +#else +int yyparse (); +#endif +#endif /* ! YYPARSE_PARAM */ + + +/* The lookahead symbol. */ +int yychar; + +/* The semantic value of the lookahead symbol. */ +YYSTYPE yylval; + +/* Number of syntax errors so far. */ +int yynerrs; + + + +/*-------------------------. +| yyparse or yypush_parse. | +`-------------------------*/ + +#ifdef YYPARSE_PARAM +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +int +yyparse (void *YYPARSE_PARAM) +#else +int +yyparse (YYPARSE_PARAM) + void *YYPARSE_PARAM; +#endif +#else /* ! YYPARSE_PARAM */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +int +yyparse (void) +#else +int +yyparse () + +#endif +#endif +{ + + + int yystate; + /* Number of tokens to shift before error messages enabled. */ + int yyerrstatus; + + /* The stacks and their tools: + `yyss': related to states. + `yyvs': related to semantic values. + + Refer to the stacks thru separate pointers, to allow yyoverflow + to reallocate them elsewhere. */ + + /* The state stack. */ + yytype_int16 yyssa[YYINITDEPTH]; + yytype_int16 *yyss; + yytype_int16 *yyssp; + + /* The semantic value stack. */ + YYSTYPE yyvsa[YYINITDEPTH]; + YYSTYPE *yyvs; + YYSTYPE *yyvsp; + + YYSIZE_T yystacksize; + + int yyn; + int yyresult; + /* Lookahead token as an internal (translated) token number. */ + int yytoken; + /* The variables used to return semantic value and location from the + action routines. */ + YYSTYPE yyval; + +#if YYERROR_VERBOSE + /* Buffer for error messages, and its allocated size. */ + char yymsgbuf[128]; + char *yymsg = yymsgbuf; + YYSIZE_T yymsg_alloc = sizeof yymsgbuf; +#endif + +#define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N)) + + /* The number of symbols on the RHS of the reduced rule. + Keep to zero when no symbol should be popped. */ + int yylen = 0; + + yytoken = 0; + yyss = yyssa; + yyvs = yyvsa; + yystacksize = YYINITDEPTH; + + YYDPRINTF ((stderr, "Starting parse\n")); + + yystate = 0; + yyerrstatus = 0; + yynerrs = 0; + yychar = YYEMPTY; /* Cause a token to be read. */ + + /* Initialize stack pointers. + Waste one element of value and location stack + so that they stay on the same level as the state stack. + The wasted elements are never initialized. */ + yyssp = yyss; + yyvsp = yyvs; + + goto yysetstate; + +/*------------------------------------------------------------. +| yynewstate -- Push a new state, which is found in yystate. | +`------------------------------------------------------------*/ + yynewstate: + /* In all cases, when you get here, the value and location stacks + have just been pushed. So pushing a state here evens the stacks. */ + yyssp++; + + yysetstate: + *yyssp = yystate; + + if (yyss + yystacksize - 1 <= yyssp) + { + /* Get the current used size of the three stacks, in elements. */ + YYSIZE_T yysize = yyssp - yyss + 1; + +#ifdef yyoverflow + { + /* Give user a chance to reallocate the stack. Use copies of + these so that the &'s don't force the real ones into + memory. */ + YYSTYPE *yyvs1 = yyvs; + yytype_int16 *yyss1 = yyss; + + /* Each stack pointer address is followed by the size of the + data in use in that stack, in bytes. This used to be a + conditional around just the two extra args, but that might + be undefined if yyoverflow is a macro. */ + yyoverflow (YY_("memory exhausted"), + &yyss1, yysize * sizeof (*yyssp), + &yyvs1, yysize * sizeof (*yyvsp), + &yystacksize); + + yyss = yyss1; + yyvs = yyvs1; + } +#else /* no yyoverflow */ +# ifndef YYSTACK_RELOCATE + goto yyexhaustedlab; +# else + /* Extend the stack our own way. */ + if (YYMAXDEPTH <= yystacksize) + goto yyexhaustedlab; + yystacksize *= 2; + if (YYMAXDEPTH < yystacksize) + yystacksize = YYMAXDEPTH; + + { + yytype_int16 *yyss1 = yyss; + union yyalloc *yyptr = + (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize)); + if (! yyptr) + goto yyexhaustedlab; + YYSTACK_RELOCATE (yyss_alloc, yyss); + YYSTACK_RELOCATE (yyvs_alloc, yyvs); +# undef YYSTACK_RELOCATE + if (yyss1 != yyssa) + YYSTACK_FREE (yyss1); + } +# endif +#endif /* no yyoverflow */ + + yyssp = yyss + yysize - 1; + yyvsp = yyvs + yysize - 1; + + YYDPRINTF ((stderr, "Stack size increased to %lu\n", + (unsigned long int) yystacksize)); + + if (yyss + yystacksize - 1 <= yyssp) + YYABORT; + } + + YYDPRINTF ((stderr, "Entering state %d\n", yystate)); + + if (yystate == YYFINAL) + YYACCEPT; + + goto yybackup; + +/*-----------. +| yybackup. | +`-----------*/ +yybackup: + + /* Do appropriate processing given the current state. Read a + lookahead token if we need one and don't already have one. */ + + /* First try to decide what to do without reference to lookahead token. */ + yyn = yypact[yystate]; + if (yyn == YYPACT_NINF) + goto yydefault; + + /* Not known => get a lookahead token if don't already have one. */ + + /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */ + if (yychar == YYEMPTY) + { + YYDPRINTF ((stderr, "Reading a token: ")); + yychar = YYLEX; + } + + if (yychar <= YYEOF) + { + yychar = yytoken = YYEOF; + YYDPRINTF ((stderr, "Now at end of input.\n")); + } + else + { + yytoken = YYTRANSLATE (yychar); + YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc); + } + + /* If the proper action on seeing token YYTOKEN is to reduce or to + detect an error, take that action. */ + yyn += yytoken; + if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken) + goto yydefault; + yyn = yytable[yyn]; + if (yyn <= 0) + { + if (yyn == 0 || yyn == YYTABLE_NINF) + goto yyerrlab; + yyn = -yyn; + goto yyreduce; + } + + /* Count tokens shifted since error; after three, turn off error + status. */ + if (yyerrstatus) + yyerrstatus--; + + /* Shift the lookahead token. */ + YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc); + + /* Discard the shifted token. */ + yychar = YYEMPTY; + + yystate = yyn; + *++yyvsp = yylval; + + goto yynewstate; + + +/*-----------------------------------------------------------. +| yydefault -- do the default action for the current state. | +`-----------------------------------------------------------*/ +yydefault: + yyn = yydefact[yystate]; + if (yyn == 0) + goto yyerrlab; + goto yyreduce; + + +/*-----------------------------. +| yyreduce -- Do a reduction. | +`-----------------------------*/ +yyreduce: + /* yyn is the number of a rule to reduce with. */ + yylen = yyr2[yyn]; + + /* If YYLEN is nonzero, implement the default value of the action: + `$$ = $1'. + + Otherwise, the following line sets YYVAL to garbage. + This behavior is undocumented and Bison + users should not rely upon it. Assigning to YYVAL + unconditionally makes the parser a bit smaller, and it avoids a + GCC warning that YYVAL may be used uninitialized. */ + yyval = yyvsp[1-yylen]; + + + YY_REDUCE_PRINT (yyn); + switch (yyn) + { + case 2: + +/* Line 1455 of yacc.c */ +#line 51 "cubeparse.y" + { + int dim; + + dim = delim_count((yyvsp[(2) - (5)]), ',') + 1; + if ((delim_count((yyvsp[(4) - (5)]), ',') + 1) != dim) + { + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("bad cube representation"), + errdetail("Different point dimensions in (%s) and (%s).", + (yyvsp[(2) - (5)]), (yyvsp[(4) - (5)])))); + YYABORT; + } + if (dim > CUBE_MAX_DIM) { + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("bad cube representation"), + errdetail("A cube cannot have more than %d dimensions.", + CUBE_MAX_DIM))); + YYABORT; + } + + *((void **)result) = write_box( dim, (yyvsp[(2) - (5)]), (yyvsp[(4) - (5)]) ); + + ;} + break; + + case 3: + +/* Line 1455 of yacc.c */ +#line 78 "cubeparse.y" + { + int dim; + + dim = delim_count((yyvsp[(1) - (3)]), ',') + 1; + + if ( (delim_count((yyvsp[(3) - (3)]), ',') + 1) != dim ) { + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("bad cube representation"), + errdetail("Different point dimensions in (%s) and (%s).", + (yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])))); + YYABORT; + } + if (dim > CUBE_MAX_DIM) { + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("bad cube representation"), + errdetail("A cube cannot have more than %d dimensions.", + CUBE_MAX_DIM))); + YYABORT; + } + + *((void **)result) = write_box( dim, (yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]) ); + ;} + break; + + case 4: + +/* Line 1455 of yacc.c */ +#line 104 "cubeparse.y" + { + int dim; + + dim = delim_count((yyvsp[(1) - (1)]), ',') + 1; + if (dim > CUBE_MAX_DIM) { + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("bad cube representation"), + errdetail("A cube cannot have more than %d dimensions.", + CUBE_MAX_DIM))); + YYABORT; + } + + *((void **)result) = write_point_as_box((yyvsp[(1) - (1)]), dim); + ;} + break; + + case 5: + +/* Line 1455 of yacc.c */ +#line 121 "cubeparse.y" + { + int dim; + + dim = delim_count((yyvsp[(1) - (1)]), ',') + 1; + if (dim > CUBE_MAX_DIM) { + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("bad cube representation"), + errdetail("A cube cannot have more than %d dimensions.", + CUBE_MAX_DIM))); + YYABORT; + } + *((void **)result) = write_point_as_box((yyvsp[(1) - (1)]), dim); + ;} + break; + + case 6: + +/* Line 1455 of yacc.c */ +#line 138 "cubeparse.y" + { + (yyval) = (yyvsp[(2) - (3)]); + ;} + break; + + case 7: + +/* Line 1455 of yacc.c */ +#line 144 "cubeparse.y" + { + /* alloc enough space to be sure whole list will fit */ + (yyval) = palloc(scanbuflen + 1); + strcpy((yyval), (yyvsp[(1) - (1)])); + ;} + break; + + case 8: + +/* Line 1455 of yacc.c */ +#line 150 "cubeparse.y" + { + (yyval) = (yyvsp[(1) - (3)]); + strcat((yyval), ","); + strcat((yyval), (yyvsp[(3) - (3)])); + ;} + break; + + + +/* Line 1455 of yacc.c */ +#line 1490 "cubeparse.c" + default: break; + } + YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); + + YYPOPSTACK (yylen); + yylen = 0; + YY_STACK_PRINT (yyss, yyssp); + + *++yyvsp = yyval; + + /* Now `shift' the result of the reduction. Determine what state + that goes to, based on the state we popped back to and the rule + number reduced by. */ + + yyn = yyr1[yyn]; + + yystate = yypgoto[yyn - YYNTOKENS] + *yyssp; + if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp) + yystate = yytable[yystate]; + else + yystate = yydefgoto[yyn - YYNTOKENS]; + + goto yynewstate; + + +/*------------------------------------. +| yyerrlab -- here on detecting error | +`------------------------------------*/ +yyerrlab: + /* If not already recovering from an error, report this error. */ + if (!yyerrstatus) + { + ++yynerrs; +#if ! YYERROR_VERBOSE + yyerror (YY_("syntax error")); +#else + { + YYSIZE_T yysize = yysyntax_error (0, yystate, yychar); + if (yymsg_alloc < yysize && yymsg_alloc < YYSTACK_ALLOC_MAXIMUM) + { + YYSIZE_T yyalloc = 2 * yysize; + if (! (yysize <= yyalloc && yyalloc <= YYSTACK_ALLOC_MAXIMUM)) + yyalloc = YYSTACK_ALLOC_MAXIMUM; + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); + yymsg = (char *) YYSTACK_ALLOC (yyalloc); + if (yymsg) + yymsg_alloc = yyalloc; + else + { + yymsg = yymsgbuf; + yymsg_alloc = sizeof yymsgbuf; + } + } + + if (0 < yysize && yysize <= yymsg_alloc) + { + (void) yysyntax_error (yymsg, yystate, yychar); + yyerror (yymsg); + } + else + { + yyerror (YY_("syntax error")); + if (yysize != 0) + goto yyexhaustedlab; + } + } +#endif + } + + + + if (yyerrstatus == 3) + { + /* If just tried and failed to reuse lookahead token after an + error, discard it. */ + + if (yychar <= YYEOF) + { + /* Return failure if at end of input. */ + if (yychar == YYEOF) + YYABORT; + } + else + { + yydestruct ("Error: discarding", + yytoken, &yylval); + yychar = YYEMPTY; + } + } + + /* Else will try to reuse lookahead token after shifting the error + token. */ + goto yyerrlab1; + + +/*---------------------------------------------------. +| yyerrorlab -- error raised explicitly by YYERROR. | +`---------------------------------------------------*/ +yyerrorlab: + + /* Pacify compilers like GCC when the user code never invokes + YYERROR and the label yyerrorlab therefore never appears in user + code. */ + if (/*CONSTCOND*/ 0) + goto yyerrorlab; + + /* Do not reclaim the symbols of the rule which action triggered + this YYERROR. */ + YYPOPSTACK (yylen); + yylen = 0; + YY_STACK_PRINT (yyss, yyssp); + yystate = *yyssp; + goto yyerrlab1; + + +/*-------------------------------------------------------------. +| yyerrlab1 -- common code for both syntax error and YYERROR. | +`-------------------------------------------------------------*/ +yyerrlab1: + yyerrstatus = 3; /* Each real token shifted decrements this. */ + + for (;;) + { + yyn = yypact[yystate]; + if (yyn != YYPACT_NINF) + { + yyn += YYTERROR; + if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR) + { + yyn = yytable[yyn]; + if (0 < yyn) + break; + } + } + + /* Pop the current state because it cannot handle the error token. */ + if (yyssp == yyss) + YYABORT; + + + yydestruct ("Error: popping", + yystos[yystate], yyvsp); + YYPOPSTACK (1); + yystate = *yyssp; + YY_STACK_PRINT (yyss, yyssp); + } + + *++yyvsp = yylval; + + + /* Shift the error token. */ + YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp); + + yystate = yyn; + goto yynewstate; + + +/*-------------------------------------. +| yyacceptlab -- YYACCEPT comes here. | +`-------------------------------------*/ +yyacceptlab: + yyresult = 0; + goto yyreturn; + +/*-----------------------------------. +| yyabortlab -- YYABORT comes here. | +`-----------------------------------*/ +yyabortlab: + yyresult = 1; + goto yyreturn; + +#if !defined(yyoverflow) || YYERROR_VERBOSE +/*-------------------------------------------------. +| yyexhaustedlab -- memory exhaustion comes here. | +`-------------------------------------------------*/ +yyexhaustedlab: + yyerror (YY_("memory exhausted")); + yyresult = 2; + /* Fall through. */ +#endif + +yyreturn: + if (yychar != YYEMPTY) + yydestruct ("Cleanup: discarding lookahead", + yytoken, &yylval); + /* Do not reclaim the symbols of the rule which action triggered + this YYABORT or YYACCEPT. */ + YYPOPSTACK (yylen); + YY_STACK_PRINT (yyss, yyssp); + while (yyssp != yyss) + { + yydestruct ("Cleanup: popping", + yystos[*yyssp], yyvsp); + YYPOPSTACK (1); + } +#ifndef yyoverflow + if (yyss != yyssa) + YYSTACK_FREE (yyss); +#endif +#if YYERROR_VERBOSE + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); +#endif + /* Make sure YYID is used. */ + return YYID (yyresult); +} + + + +/* Line 1675 of yacc.c */ +#line 157 "cubeparse.y" + + +static int +delim_count(char *s, char delim) +{ + int ndelim = 0; + + while ((s = strchr(s, delim)) != NULL) + { + ndelim++; + s++; + } + return (ndelim); +} + +static NDBOX * +write_box(unsigned int dim, char *str1, char *str2) +{ + NDBOX *bp; + char *s; + int i; + int size = offsetof(NDBOX, x[0]) + sizeof(double) * dim * 2; + + bp = palloc0(size); + SET_VARSIZE(bp, size); + bp->dim = dim; + + s = str1; + bp->x[i=0] = strtod(s, NULL); + while ((s = strchr(s, ',')) != NULL) + { + s++; i++; + bp->x[i] = strtod(s, NULL); + } + + s = str2; + bp->x[i=dim] = strtod(s, NULL); + while ((s = strchr(s, ',')) != NULL) + { + s++; i++; + bp->x[i] = strtod(s, NULL); + } + + return(bp); +} + +static NDBOX * +write_point_as_box(char *str, int dim) +{ + NDBOX *bp; + int i, + size; + double x; + char *s = str; + + size = offsetof(NDBOX, x[0]) + sizeof(double) * dim * 2; + + bp = palloc0(size); + SET_VARSIZE(bp, size); + bp->dim = dim; + + i = 0; + x = strtod(s, NULL); + bp->x[0] = x; + bp->x[dim] = x; + while ((s = strchr(s, ',')) != NULL) + { + s++; i++; + x = strtod(s, NULL); + bp->x[i] = x; + bp->x[i+dim] = x; + } + + return(bp); +} + +#include "cubescan.c" + diff --git a/contrib/cube/cubescan.c b/contrib/cube/cubescan.c new file mode 100644 index 000000000..4f5433104 --- /dev/null +++ b/contrib/cube/cubescan.c @@ -0,0 +1,1855 @@ +#line 2 "cubescan.c" + +#line 4 "cubescan.c" + +#define YY_INT_ALIGNED short int + +/* A lexical scanner generated by flex */ + +#define yy_create_buffer cube_yy_create_buffer +#define yy_delete_buffer cube_yy_delete_buffer +#define yy_flex_debug cube_yy_flex_debug +#define yy_init_buffer cube_yy_init_buffer +#define yy_flush_buffer cube_yy_flush_buffer +#define yy_load_buffer_state cube_yy_load_buffer_state +#define yy_switch_to_buffer cube_yy_switch_to_buffer +#define yyin cube_yyin +#define yyleng cube_yyleng +#define yylex cube_yylex +#define yylineno cube_yylineno +#define yyout cube_yyout +#define yyrestart cube_yyrestart +#define yytext cube_yytext +#define yywrap cube_yywrap +#define yyalloc cube_yyalloc +#define yyrealloc cube_yyrealloc +#define yyfree cube_yyfree + +#define FLEX_SCANNER +#define YY_FLEX_MAJOR_VERSION 2 +#define YY_FLEX_MINOR_VERSION 5 +#define YY_FLEX_SUBMINOR_VERSION 35 +#if YY_FLEX_SUBMINOR_VERSION > 0 +#define FLEX_BETA +#endif + +/* First, we deal with platform-specific or compiler-specific issues. */ + +/* begin standard C headers. */ +#include +#include +#include +#include + +/* end standard C headers. */ + +/* flex integer type definitions */ + +#ifndef FLEXINT_H +#define FLEXINT_H + +/* C99 systems have . Non-C99 systems may or may not. */ + +#if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L + +/* C99 says to define __STDC_LIMIT_MACROS before including stdint.h, + * if you want the limit (max/min) macros for int types. + */ +#ifndef __STDC_LIMIT_MACROS +#define __STDC_LIMIT_MACROS 1 +#endif + +#include +typedef int8_t flex_int8_t; +typedef uint8_t flex_uint8_t; +typedef int16_t flex_int16_t; +typedef uint16_t flex_uint16_t; +typedef int32_t flex_int32_t; +typedef uint32_t flex_uint32_t; +#else +typedef signed char flex_int8_t; +typedef short int flex_int16_t; +typedef int flex_int32_t; +typedef unsigned char flex_uint8_t; +typedef unsigned short int flex_uint16_t; +typedef unsigned int flex_uint32_t; + +/* Limits of integral types. */ +#ifndef INT8_MIN +#define INT8_MIN (-128) +#endif +#ifndef INT16_MIN +#define INT16_MIN (-32767-1) +#endif +#ifndef INT32_MIN +#define INT32_MIN (-2147483647-1) +#endif +#ifndef INT8_MAX +#define INT8_MAX (127) +#endif +#ifndef INT16_MAX +#define INT16_MAX (32767) +#endif +#ifndef INT32_MAX +#define INT32_MAX (2147483647) +#endif +#ifndef UINT8_MAX +#define UINT8_MAX (255U) +#endif +#ifndef UINT16_MAX +#define UINT16_MAX (65535U) +#endif +#ifndef UINT32_MAX +#define UINT32_MAX (4294967295U) +#endif + +#endif /* ! C99 */ + +#endif /* ! FLEXINT_H */ + +#ifdef __cplusplus + +/* The "const" storage-class-modifier is valid. */ +#define YY_USE_CONST + +#else /* ! __cplusplus */ + +/* C99 requires __STDC__ to be defined as 1. */ +#if defined (__STDC__) + +#define YY_USE_CONST + +#endif /* defined (__STDC__) */ +#endif /* ! __cplusplus */ + +#ifdef YY_USE_CONST +#define yyconst const +#else +#define yyconst +#endif + +/* Returned upon end-of-file. */ +#define YY_NULL 0 + +/* Promotes a possibly negative, possibly signed char to an unsigned + * integer for use as an array index. If the signed char is negative, + * we want to instead treat it as an 8-bit unsigned char, hence the + * double cast. + */ +#define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c) + +/* Enter a start condition. This macro really ought to take a parameter, + * but we do it the disgusting crufty way forced on us by the ()-less + * definition of BEGIN. + */ +#define BEGIN (yy_start) = 1 + 2 * + +/* Translate the current start state into a value that can be later handed + * to BEGIN to return to the state. The YYSTATE alias is for lex + * compatibility. + */ +#define YY_START (((yy_start) - 1) / 2) +#define YYSTATE YY_START + +/* Action number for EOF rule of a given start state. */ +#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1) + +/* Special action meaning "start processing a new file". */ +#define YY_NEW_FILE cube_yyrestart(cube_yyin ) + +#define YY_END_OF_BUFFER_CHAR 0 + +/* Size of default input buffer. */ +#ifndef YY_BUF_SIZE +#ifdef __ia64__ +/* On IA-64, the buffer size is 16k, not 8k. + * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case. + * Ditto for the __ia64__ case accordingly. + */ +#define YY_BUF_SIZE 32768 +#else +#define YY_BUF_SIZE 16384 +#endif /* __ia64__ */ +#endif + +/* The state buf must be large enough to hold one state per character in the main buffer. + */ +#define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type)) + +#ifndef YY_TYPEDEF_YY_BUFFER_STATE +#define YY_TYPEDEF_YY_BUFFER_STATE +typedef struct yy_buffer_state *YY_BUFFER_STATE; +#endif + +extern int cube_yyleng; + +extern FILE *cube_yyin, *cube_yyout; + +#define EOB_ACT_CONTINUE_SCAN 0 +#define EOB_ACT_END_OF_FILE 1 +#define EOB_ACT_LAST_MATCH 2 + + #define YY_LESS_LINENO(n) + +/* Return all but the first "n" matched characters back to the input stream. */ +#define yyless(n) \ + do \ + { \ + /* Undo effects of setting up cube_yytext. */ \ + int yyless_macro_arg = (n); \ + YY_LESS_LINENO(yyless_macro_arg);\ + *yy_cp = (yy_hold_char); \ + YY_RESTORE_YY_MORE_OFFSET \ + (yy_c_buf_p) = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \ + YY_DO_BEFORE_ACTION; /* set up cube_yytext again */ \ + } \ + while ( 0 ) + +#define unput(c) yyunput( c, (yytext_ptr) ) + +#ifndef YY_TYPEDEF_YY_SIZE_T +#define YY_TYPEDEF_YY_SIZE_T +typedef size_t yy_size_t; +#endif + +#ifndef YY_STRUCT_YY_BUFFER_STATE +#define YY_STRUCT_YY_BUFFER_STATE +struct yy_buffer_state + { + FILE *yy_input_file; + + char *yy_ch_buf; /* input buffer */ + char *yy_buf_pos; /* current position in input buffer */ + + /* Size of input buffer in bytes, not including room for EOB + * characters. + */ + yy_size_t yy_buf_size; + + /* Number of characters read into yy_ch_buf, not including EOB + * characters. + */ + int yy_n_chars; + + /* Whether we "own" the buffer - i.e., we know we created it, + * and can realloc() it to grow it, and should free() it to + * delete it. + */ + int yy_is_our_buffer; + + /* Whether this is an "interactive" input source; if so, and + * if we're using stdio for input, then we want to use getc() + * instead of fread(), to make sure we stop fetching input after + * each newline. + */ + int yy_is_interactive; + + /* Whether we're considered to be at the beginning of a line. + * If so, '^' rules will be active on the next match, otherwise + * not. + */ + int yy_at_bol; + + int yy_bs_lineno; /**< The line count. */ + int yy_bs_column; /**< The column count. */ + + /* Whether to try to fill the input buffer when we reach the + * end of it. + */ + int yy_fill_buffer; + + int yy_buffer_status; + +#define YY_BUFFER_NEW 0 +#define YY_BUFFER_NORMAL 1 + /* When an EOF's been seen but there's still some text to process + * then we mark the buffer as YY_EOF_PENDING, to indicate that we + * shouldn't try reading from the input source any more. We might + * still have a bunch of tokens to match, though, because of + * possible backing-up. + * + * When we actually see the EOF, we change the status to "new" + * (via cube_yyrestart()), so that the user can continue scanning by + * just pointing cube_yyin at a new input file. + */ +#define YY_BUFFER_EOF_PENDING 2 + + }; +#endif /* !YY_STRUCT_YY_BUFFER_STATE */ + +/* Stack of input buffers. */ +static size_t yy_buffer_stack_top = 0; /**< index of top of stack. */ +static size_t yy_buffer_stack_max = 0; /**< capacity of stack. */ +static YY_BUFFER_STATE * yy_buffer_stack = 0; /**< Stack as an array. */ + +/* We provide macros for accessing buffer states in case in the + * future we want to put the buffer states in a more general + * "scanner state". + * + * Returns the top of the stack, or NULL. + */ +#define YY_CURRENT_BUFFER ( (yy_buffer_stack) \ + ? (yy_buffer_stack)[(yy_buffer_stack_top)] \ + : NULL) + +/* Same as previous macro, but useful when we know that the buffer stack is not + * NULL or when we need an lvalue. For internal use only. + */ +#define YY_CURRENT_BUFFER_LVALUE (yy_buffer_stack)[(yy_buffer_stack_top)] + +/* yy_hold_char holds the character lost when cube_yytext is formed. */ +static char yy_hold_char; +static int yy_n_chars; /* number of characters read into yy_ch_buf */ +int cube_yyleng; + +/* Points to current character in buffer. */ +static char *yy_c_buf_p = (char *) 0; +static int yy_init = 0; /* whether we need to initialize */ +static int yy_start = 0; /* start state number */ + +/* Flag which is used to allow cube_yywrap()'s to do buffer switches + * instead of setting up a fresh cube_yyin. A bit of a hack ... + */ +static int yy_did_buffer_switch_on_eof; + +void cube_yyrestart (FILE *input_file ); +void cube_yy_switch_to_buffer (YY_BUFFER_STATE new_buffer ); +YY_BUFFER_STATE cube_yy_create_buffer (FILE *file,int size ); +void cube_yy_delete_buffer (YY_BUFFER_STATE b ); +void cube_yy_flush_buffer (YY_BUFFER_STATE b ); +void cube_yypush_buffer_state (YY_BUFFER_STATE new_buffer ); +void cube_yypop_buffer_state (void ); + +static void cube_yyensure_buffer_stack (void ); +static void cube_yy_load_buffer_state (void ); +static void cube_yy_init_buffer (YY_BUFFER_STATE b,FILE *file ); + +#define YY_FLUSH_BUFFER cube_yy_flush_buffer(YY_CURRENT_BUFFER ) + +YY_BUFFER_STATE cube_yy_scan_buffer (char *base,yy_size_t size ); +YY_BUFFER_STATE cube_yy_scan_string (yyconst char *yy_str ); +YY_BUFFER_STATE cube_yy_scan_bytes (yyconst char *bytes,int len ); + +void *cube_yyalloc (yy_size_t ); +void *cube_yyrealloc (void *,yy_size_t ); +void cube_yyfree (void * ); + +#define yy_new_buffer cube_yy_create_buffer + +#define yy_set_interactive(is_interactive) \ + { \ + if ( ! YY_CURRENT_BUFFER ){ \ + cube_yyensure_buffer_stack (); \ + YY_CURRENT_BUFFER_LVALUE = \ + cube_yy_create_buffer(cube_yyin,YY_BUF_SIZE ); \ + } \ + YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \ + } + +#define yy_set_bol(at_bol) \ + { \ + if ( ! YY_CURRENT_BUFFER ){\ + cube_yyensure_buffer_stack (); \ + YY_CURRENT_BUFFER_LVALUE = \ + cube_yy_create_buffer(cube_yyin,YY_BUF_SIZE ); \ + } \ + YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \ + } + +#define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol) + +/* Begin user sect3 */ + +#define cube_yywrap(n) 1 +#define YY_SKIP_YYWRAP + +typedef unsigned char YY_CHAR; + +FILE *cube_yyin = (FILE *) 0, *cube_yyout = (FILE *) 0; + +typedef int yy_state_type; + +extern int cube_yylineno; + +int cube_yylineno = 1; + +extern char *cube_yytext; +#define yytext_ptr cube_yytext + +static yy_state_type yy_get_previous_state (void ); +static yy_state_type yy_try_NUL_trans (yy_state_type current_state ); +static int yy_get_next_buffer (void ); +static void yy_fatal_error (yyconst char msg[] ); + +/* Done after the current pattern has been matched and before the + * corresponding action - sets up cube_yytext. + */ +#define YY_DO_BEFORE_ACTION \ + (yytext_ptr) = yy_bp; \ + cube_yyleng = (size_t) (yy_cp - yy_bp); \ + (yy_hold_char) = *yy_cp; \ + *yy_cp = '\0'; \ + (yy_c_buf_p) = yy_cp; + +#define YY_NUM_RULES 9 +#define YY_END_OF_BUFFER 10 +/* This struct is not used in this scanner, + but its presence is necessary. */ +struct yy_trans_info + { + flex_int32_t yy_verify; + flex_int32_t yy_nxt; + }; +static yyconst flex_int16_t yy_accept[25] = + { 0, + 0, 0, 10, 8, 7, 7, 4, 5, 8, 6, + 8, 1, 2, 3, 7, 0, 1, 1, 1, 0, + 1, 0, 1, 0 + } ; + +static yyconst flex_int32_t yy_ec[256] = + { 0, + 1, 1, 1, 1, 1, 1, 1, 1, 2, 3, + 1, 2, 2, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 2, 1, 1, 1, 1, 1, 1, 1, 4, + 5, 1, 6, 7, 6, 8, 1, 9, 9, 9, + 9, 9, 9, 9, 9, 9, 9, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 10, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 11, 1, 12, 1, 1, 1, 1, 1, 1, 1, + + 10, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1 + } ; + +static yyconst flex_int32_t yy_meta[13] = + { 0, + 1, 2, 2, 1, 1, 1, 1, 1, 1, 1, + 1, 1 + } ; + +static yyconst flex_int16_t yy_base[26] = + { 0, + 0, 0, 28, 29, 0, 0, 29, 29, 5, 29, + 18, 7, 29, 29, 0, 17, 0, 9, 16, 14, + 0, 15, 13, 29, 19 + } ; + +static yyconst flex_int16_t yy_def[26] = + { 0, + 24, 1, 24, 24, 25, 25, 24, 24, 24, 24, + 24, 24, 24, 24, 25, 24, 12, 24, 18, 24, + 19, 24, 24, 0, 24 + } ; + +static yyconst flex_int16_t yy_nxt[42] = + { 0, + 4, 5, 6, 7, 8, 9, 10, 11, 12, 4, + 13, 14, 16, 17, 19, 17, 20, 18, 20, 22, + 15, 23, 23, 23, 21, 18, 18, 24, 3, 24, + 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, + 24 + } ; + +static yyconst flex_int16_t yy_chk[42] = + { 0, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 9, 9, 12, 12, 12, 18, 18, 20, + 25, 23, 20, 22, 19, 16, 11, 3, 24, 24, + 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, + 24 + } ; + +static yy_state_type yy_last_accepting_state; +static char *yy_last_accepting_cpos; + +extern int cube_yy_flex_debug; +int cube_yy_flex_debug = 0; + +/* The intent behind this definition is that it'll catch + * any uses of REJECT which flex missed. + */ +#define REJECT reject_used_but_not_detected +#define yymore() yymore_used_but_not_detected +#define YY_MORE_ADJ 0 +#define YY_RESTORE_YY_MORE_OFFSET +char *cube_yytext; +#line 1 "cubescan.l" +#line 2 "cubescan.l" +/* + * A scanner for EMP-style numeric ranges + * contrib/cube/cubescan.l + */ + +#include "postgres.h" + +/* No reason to constrain amount of data slurped */ +#define YY_READ_BUF_SIZE 16777216 + +/* Avoid exit() on fatal scanner errors (a bit ugly -- see yy_fatal_error) */ +#undef fprintf +#define fprintf(file, fmt, msg) ereport(ERROR, (errmsg_internal("%s", msg))) + +/* Handles to the buffer that the lexer uses internally */ +static YY_BUFFER_STATE scanbufhandle; +/* this is now declared in cubeparse.y: */ +/* static char *scanbuf; */ +/* static int scanbuflen; */ + +/* flex 2.5.4 doesn't bother with a decl for this */ +int cube_yylex(void); + +void cube_scanner_init(const char *str); +void cube_scanner_finish(void); +#define YY_NO_INPUT 1 +#line 523 "cubescan.c" + +#define INITIAL 0 + +#ifndef YY_NO_UNISTD_H +/* Special case for "unistd.h", since it is non-ANSI. We include it way + * down here because we want the user's section 1 to have been scanned first. + * The user has a chance to override it with an option. + */ +#include +#endif + +#ifndef YY_EXTRA_TYPE +#define YY_EXTRA_TYPE void * +#endif + +static int yy_init_globals (void ); + +/* Accessor methods to globals. + These are made visible to non-reentrant scanners for convenience. */ + +int cube_yylex_destroy (void ); + +int cube_yyget_debug (void ); + +void cube_yyset_debug (int debug_flag ); + +YY_EXTRA_TYPE cube_yyget_extra (void ); + +void cube_yyset_extra (YY_EXTRA_TYPE user_defined ); + +FILE *cube_yyget_in (void ); + +void cube_yyset_in (FILE * in_str ); + +FILE *cube_yyget_out (void ); + +void cube_yyset_out (FILE * out_str ); + +int cube_yyget_leng (void ); + +char *cube_yyget_text (void ); + +int cube_yyget_lineno (void ); + +void cube_yyset_lineno (int line_number ); + +/* Macros after this point can all be overridden by user definitions in + * section 1. + */ + +#ifndef YY_SKIP_YYWRAP +#ifdef __cplusplus +extern "C" int cube_yywrap (void ); +#else +extern int cube_yywrap (void ); +#endif +#endif + +#ifndef yytext_ptr +static void yy_flex_strncpy (char *,yyconst char *,int ); +#endif + +#ifdef YY_NEED_STRLEN +static int yy_flex_strlen (yyconst char * ); +#endif + +#ifndef YY_NO_INPUT + +#ifdef __cplusplus +static int yyinput (void ); +#else +static int input (void ); +#endif + +#endif + +/* Amount of stuff to slurp up with each read. */ +#ifndef YY_READ_BUF_SIZE +#ifdef __ia64__ +/* On IA-64, the buffer size is 16k, not 8k */ +#define YY_READ_BUF_SIZE 16384 +#else +#define YY_READ_BUF_SIZE 8192 +#endif /* __ia64__ */ +#endif + +/* Copy whatever the last rule matched to the standard output. */ +#ifndef ECHO +/* This used to be an fputs(), but since the string might contain NUL's, + * we now use fwrite(). + */ +#define ECHO do { if (fwrite( cube_yytext, cube_yyleng, 1, cube_yyout )) {} } while (0) +#endif + +/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL, + * is returned in "result". + */ +#ifndef YY_INPUT +#define YY_INPUT(buf,result,max_size) \ + if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \ + { \ + int c = '*'; \ + size_t n; \ + for ( n = 0; n < max_size && \ + (c = getc( cube_yyin )) != EOF && c != '\n'; ++n ) \ + buf[n] = (char) c; \ + if ( c == '\n' ) \ + buf[n++] = (char) c; \ + if ( c == EOF && ferror( cube_yyin ) ) \ + YY_FATAL_ERROR( "input in flex scanner failed" ); \ + result = n; \ + } \ + else \ + { \ + errno=0; \ + while ( (result = fread(buf, 1, max_size, cube_yyin))==0 && ferror(cube_yyin)) \ + { \ + if( errno != EINTR) \ + { \ + YY_FATAL_ERROR( "input in flex scanner failed" ); \ + break; \ + } \ + errno=0; \ + clearerr(cube_yyin); \ + } \ + }\ +\ + +#endif + +/* No semi-colon after return; correct usage is to write "yyterminate();" - + * we don't want an extra ';' after the "return" because that will cause + * some compilers to complain about unreachable statements. + */ +#ifndef yyterminate +#define yyterminate() return YY_NULL +#endif + +/* Number of entries by which start-condition stack grows. */ +#ifndef YY_START_STACK_INCR +#define YY_START_STACK_INCR 25 +#endif + +/* Report a fatal error. */ +#ifndef YY_FATAL_ERROR +#define YY_FATAL_ERROR(msg) yy_fatal_error( msg ) +#endif + +/* end tables serialization structures and prototypes */ + +/* Default declaration of generated scanner - a define so the user can + * easily add parameters. + */ +#ifndef YY_DECL +#define YY_DECL_IS_OURS 1 + +extern int cube_yylex (void); + +#define YY_DECL int cube_yylex (void) +#endif /* !YY_DECL */ + +/* Code executed at the beginning of each rule, after cube_yytext and cube_yyleng + * have been set up. + */ +#ifndef YY_USER_ACTION +#define YY_USER_ACTION +#endif + +/* Code executed at the end of each rule. */ +#ifndef YY_BREAK +#define YY_BREAK break; +#endif + +#define YY_RULE_SETUP \ + YY_USER_ACTION + +/** The main scanner function which does all the work. + */ +YY_DECL +{ + register yy_state_type yy_current_state; + register char *yy_cp, *yy_bp; + register int yy_act; + +#line 44 "cubescan.l" + + +#line 711 "cubescan.c" + + if ( !(yy_init) ) + { + (yy_init) = 1; + +#ifdef YY_USER_INIT + YY_USER_INIT; +#endif + + if ( ! (yy_start) ) + (yy_start) = 1; /* first start state */ + + if ( ! cube_yyin ) + cube_yyin = stdin; + + if ( ! cube_yyout ) + cube_yyout = stdout; + + if ( ! YY_CURRENT_BUFFER ) { + cube_yyensure_buffer_stack (); + YY_CURRENT_BUFFER_LVALUE = + cube_yy_create_buffer(cube_yyin,YY_BUF_SIZE ); + } + + cube_yy_load_buffer_state( ); + } + + while ( 1 ) /* loops until end-of-file is reached */ + { + yy_cp = (yy_c_buf_p); + + /* Support of cube_yytext. */ + *yy_cp = (yy_hold_char); + + /* yy_bp points to the position in yy_ch_buf of the start of + * the current run. + */ + yy_bp = yy_cp; + + yy_current_state = (yy_start); +yy_match: + do + { + register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)]; + if ( yy_accept[yy_current_state] ) + { + (yy_last_accepting_state) = yy_current_state; + (yy_last_accepting_cpos) = yy_cp; + } + while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) + { + yy_current_state = (int) yy_def[yy_current_state]; + if ( yy_current_state >= 25 ) + yy_c = yy_meta[(unsigned int) yy_c]; + } + yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; + ++yy_cp; + } + while ( yy_current_state != 24 ); + yy_cp = (yy_last_accepting_cpos); + yy_current_state = (yy_last_accepting_state); + +yy_find_action: + yy_act = yy_accept[yy_current_state]; + + YY_DO_BEFORE_ACTION; + +do_action: /* This label is used only to access EOF actions. */ + + switch ( yy_act ) + { /* beginning of action switch */ + case 0: /* must back up */ + /* undo the effects of YY_DO_BEFORE_ACTION */ + *yy_cp = (yy_hold_char); + yy_cp = (yy_last_accepting_cpos); + yy_current_state = (yy_last_accepting_state); + goto yy_find_action; + +case 1: +YY_RULE_SETUP +#line 46 "cubescan.l" +yylval = cube_yytext; return CUBEFLOAT; + YY_BREAK +case 2: +YY_RULE_SETUP +#line 47 "cubescan.l" +yylval = "("; return O_BRACKET; + YY_BREAK +case 3: +YY_RULE_SETUP +#line 48 "cubescan.l" +yylval = ")"; return C_BRACKET; + YY_BREAK +case 4: +YY_RULE_SETUP +#line 49 "cubescan.l" +yylval = "("; return O_PAREN; + YY_BREAK +case 5: +YY_RULE_SETUP +#line 50 "cubescan.l" +yylval = ")"; return C_PAREN; + YY_BREAK +case 6: +YY_RULE_SETUP +#line 51 "cubescan.l" +yylval = ")"; return COMMA; + YY_BREAK +case 7: +/* rule 7 can match eol */ +YY_RULE_SETUP +#line 52 "cubescan.l" +/* discard spaces */ + YY_BREAK +case 8: +YY_RULE_SETUP +#line 53 "cubescan.l" +return cube_yytext[0]; /* alert parser of the garbage */ + YY_BREAK +case 9: +YY_RULE_SETUP +#line 55 "cubescan.l" +YY_FATAL_ERROR( "flex scanner jammed" ); + YY_BREAK +#line 836 "cubescan.c" +case YY_STATE_EOF(INITIAL): + yyterminate(); + + case YY_END_OF_BUFFER: + { + /* Amount of text matched not including the EOB char. */ + int yy_amount_of_matched_text = (int) (yy_cp - (yytext_ptr)) - 1; + + /* Undo the effects of YY_DO_BEFORE_ACTION. */ + *yy_cp = (yy_hold_char); + YY_RESTORE_YY_MORE_OFFSET + + if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW ) + { + /* We're scanning a new file or input source. It's + * possible that this happened because the user + * just pointed cube_yyin at a new source and called + * cube_yylex(). If so, then we have to assure + * consistency between YY_CURRENT_BUFFER and our + * globals. Here is the right place to do so, because + * this is the first action (other than possibly a + * back-up) that will match for the new input source. + */ + (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars; + YY_CURRENT_BUFFER_LVALUE->yy_input_file = cube_yyin; + YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL; + } + + /* Note that here we test for yy_c_buf_p "<=" to the position + * of the first EOB in the buffer, since yy_c_buf_p will + * already have been incremented past the NUL character + * (since all states make transitions on EOB to the + * end-of-buffer state). Contrast this with the test + * in input(). + */ + if ( (yy_c_buf_p) <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] ) + { /* This was really a NUL. */ + yy_state_type yy_next_state; + + (yy_c_buf_p) = (yytext_ptr) + yy_amount_of_matched_text; + + yy_current_state = yy_get_previous_state( ); + + /* Okay, we're now positioned to make the NUL + * transition. We couldn't have + * yy_get_previous_state() go ahead and do it + * for us because it doesn't know how to deal + * with the possibility of jamming (and we don't + * want to build jamming into it because then it + * will run more slowly). + */ + + yy_next_state = yy_try_NUL_trans( yy_current_state ); + + yy_bp = (yytext_ptr) + YY_MORE_ADJ; + + if ( yy_next_state ) + { + /* Consume the NUL. */ + yy_cp = ++(yy_c_buf_p); + yy_current_state = yy_next_state; + goto yy_match; + } + + else + { + yy_cp = (yy_last_accepting_cpos); + yy_current_state = (yy_last_accepting_state); + goto yy_find_action; + } + } + + else switch ( yy_get_next_buffer( ) ) + { + case EOB_ACT_END_OF_FILE: + { + (yy_did_buffer_switch_on_eof) = 0; + + if ( cube_yywrap( ) ) + { + /* Note: because we've taken care in + * yy_get_next_buffer() to have set up + * cube_yytext, we can now set up + * yy_c_buf_p so that if some total + * hoser (like flex itself) wants to + * call the scanner after we return the + * YY_NULL, it'll still work - another + * YY_NULL will get returned. + */ + (yy_c_buf_p) = (yytext_ptr) + YY_MORE_ADJ; + + yy_act = YY_STATE_EOF(YY_START); + goto do_action; + } + + else + { + if ( ! (yy_did_buffer_switch_on_eof) ) + YY_NEW_FILE; + } + break; + } + + case EOB_ACT_CONTINUE_SCAN: + (yy_c_buf_p) = + (yytext_ptr) + yy_amount_of_matched_text; + + yy_current_state = yy_get_previous_state( ); + + yy_cp = (yy_c_buf_p); + yy_bp = (yytext_ptr) + YY_MORE_ADJ; + goto yy_match; + + case EOB_ACT_LAST_MATCH: + (yy_c_buf_p) = + &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)]; + + yy_current_state = yy_get_previous_state( ); + + yy_cp = (yy_c_buf_p); + yy_bp = (yytext_ptr) + YY_MORE_ADJ; + goto yy_find_action; + } + break; + } + + default: + YY_FATAL_ERROR( + "fatal flex scanner internal error--no action found" ); + } /* end of action switch */ + } /* end of scanning one token */ +} /* end of cube_yylex */ + +/* yy_get_next_buffer - try to read in a new buffer + * + * Returns a code representing an action: + * EOB_ACT_LAST_MATCH - + * EOB_ACT_CONTINUE_SCAN - continue scanning from current position + * EOB_ACT_END_OF_FILE - end of file + */ +static int yy_get_next_buffer (void) +{ + register char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf; + register char *source = (yytext_ptr); + register int number_to_move, i; + int ret_val; + + if ( (yy_c_buf_p) > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] ) + YY_FATAL_ERROR( + "fatal flex scanner internal error--end of buffer missed" ); + + if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 ) + { /* Don't try to fill the buffer, so this is an EOF. */ + if ( (yy_c_buf_p) - (yytext_ptr) - YY_MORE_ADJ == 1 ) + { + /* We matched a single character, the EOB, so + * treat this as a final EOF. + */ + return EOB_ACT_END_OF_FILE; + } + + else + { + /* We matched some text prior to the EOB, first + * process it. + */ + return EOB_ACT_LAST_MATCH; + } + } + + /* Try to read more data. */ + + /* First move last chars to start of buffer. */ + number_to_move = (int) ((yy_c_buf_p) - (yytext_ptr)) - 1; + + for ( i = 0; i < number_to_move; ++i ) + *(dest++) = *(source++); + + if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING ) + /* don't do the read, it's not guaranteed to return an EOF, + * just force an EOF + */ + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars) = 0; + + else + { + int num_to_read = + YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1; + + while ( num_to_read <= 0 ) + { /* Not enough room in the buffer - grow it. */ + + /* just a shorter name for the current buffer */ + YY_BUFFER_STATE b = YY_CURRENT_BUFFER; + + int yy_c_buf_p_offset = + (int) ((yy_c_buf_p) - b->yy_ch_buf); + + if ( b->yy_is_our_buffer ) + { + int new_size = b->yy_buf_size * 2; + + if ( new_size <= 0 ) + b->yy_buf_size += b->yy_buf_size / 8; + else + b->yy_buf_size *= 2; + + b->yy_ch_buf = (char *) + /* Include room in for 2 EOB chars. */ + cube_yyrealloc((void *) b->yy_ch_buf,b->yy_buf_size + 2 ); + } + else + /* Can't grow it, we don't own it. */ + b->yy_ch_buf = 0; + + if ( ! b->yy_ch_buf ) + YY_FATAL_ERROR( + "fatal error - scanner input buffer overflow" ); + + (yy_c_buf_p) = &b->yy_ch_buf[yy_c_buf_p_offset]; + + num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size - + number_to_move - 1; + + } + + if ( num_to_read > YY_READ_BUF_SIZE ) + num_to_read = YY_READ_BUF_SIZE; + + /* Read in more data. */ + YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]), + (yy_n_chars), (size_t) num_to_read ); + + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); + } + + if ( (yy_n_chars) == 0 ) + { + if ( number_to_move == YY_MORE_ADJ ) + { + ret_val = EOB_ACT_END_OF_FILE; + cube_yyrestart(cube_yyin ); + } + + else + { + ret_val = EOB_ACT_LAST_MATCH; + YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = + YY_BUFFER_EOF_PENDING; + } + } + + else + ret_val = EOB_ACT_CONTINUE_SCAN; + + if ((yy_size_t) ((yy_n_chars) + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) { + /* Extend the array by 50%, plus the number we really need. */ + yy_size_t new_size = (yy_n_chars) + number_to_move + ((yy_n_chars) >> 1); + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) cube_yyrealloc((void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,new_size ); + if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf ) + YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" ); + } + + (yy_n_chars) += number_to_move; + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] = YY_END_OF_BUFFER_CHAR; + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] = YY_END_OF_BUFFER_CHAR; + + (yytext_ptr) = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0]; + + return ret_val; +} + +/* yy_get_previous_state - get the state just before the EOB char was reached */ + + static yy_state_type yy_get_previous_state (void) +{ + register yy_state_type yy_current_state; + register char *yy_cp; + + yy_current_state = (yy_start); + + for ( yy_cp = (yytext_ptr) + YY_MORE_ADJ; yy_cp < (yy_c_buf_p); ++yy_cp ) + { + register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1); + if ( yy_accept[yy_current_state] ) + { + (yy_last_accepting_state) = yy_current_state; + (yy_last_accepting_cpos) = yy_cp; + } + while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) + { + yy_current_state = (int) yy_def[yy_current_state]; + if ( yy_current_state >= 25 ) + yy_c = yy_meta[(unsigned int) yy_c]; + } + yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; + } + + return yy_current_state; +} + +/* yy_try_NUL_trans - try to make a transition on the NUL character + * + * synopsis + * next_state = yy_try_NUL_trans( current_state ); + */ + static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state ) +{ + register int yy_is_jam; + register char *yy_cp = (yy_c_buf_p); + + register YY_CHAR yy_c = 1; + if ( yy_accept[yy_current_state] ) + { + (yy_last_accepting_state) = yy_current_state; + (yy_last_accepting_cpos) = yy_cp; + } + while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) + { + yy_current_state = (int) yy_def[yy_current_state]; + if ( yy_current_state >= 25 ) + yy_c = yy_meta[(unsigned int) yy_c]; + } + yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; + yy_is_jam = (yy_current_state == 24); + + return yy_is_jam ? 0 : yy_current_state; +} + +#ifndef YY_NO_INPUT +#ifdef __cplusplus + static int yyinput (void) +#else + static int input (void) +#endif + +{ + int c; + + *(yy_c_buf_p) = (yy_hold_char); + + if ( *(yy_c_buf_p) == YY_END_OF_BUFFER_CHAR ) + { + /* yy_c_buf_p now points to the character we want to return. + * If this occurs *before* the EOB characters, then it's a + * valid NUL; if not, then we've hit the end of the buffer. + */ + if ( (yy_c_buf_p) < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] ) + /* This was really a NUL. */ + *(yy_c_buf_p) = '\0'; + + else + { /* need more input */ + int offset = (yy_c_buf_p) - (yytext_ptr); + ++(yy_c_buf_p); + + switch ( yy_get_next_buffer( ) ) + { + case EOB_ACT_LAST_MATCH: + /* This happens because yy_g_n_b() + * sees that we've accumulated a + * token and flags that we need to + * try matching the token before + * proceeding. But for input(), + * there's no matching to consider. + * So convert the EOB_ACT_LAST_MATCH + * to EOB_ACT_END_OF_FILE. + */ + + /* Reset buffer status. */ + cube_yyrestart(cube_yyin ); + + /*FALLTHROUGH*/ + + case EOB_ACT_END_OF_FILE: + { + if ( cube_yywrap( ) ) + return EOF; + + if ( ! (yy_did_buffer_switch_on_eof) ) + YY_NEW_FILE; +#ifdef __cplusplus + return yyinput(); +#else + return input(); +#endif + } + + case EOB_ACT_CONTINUE_SCAN: + (yy_c_buf_p) = (yytext_ptr) + offset; + break; + } + } + } + + c = *(unsigned char *) (yy_c_buf_p); /* cast for 8-bit char's */ + *(yy_c_buf_p) = '\0'; /* preserve cube_yytext */ + (yy_hold_char) = *++(yy_c_buf_p); + + return c; +} +#endif /* ifndef YY_NO_INPUT */ + +/** Immediately switch to a different input stream. + * @param input_file A readable stream. + * + * @note This function does not reset the start condition to @c INITIAL . + */ + void cube_yyrestart (FILE * input_file ) +{ + + if ( ! YY_CURRENT_BUFFER ){ + cube_yyensure_buffer_stack (); + YY_CURRENT_BUFFER_LVALUE = + cube_yy_create_buffer(cube_yyin,YY_BUF_SIZE ); + } + + cube_yy_init_buffer(YY_CURRENT_BUFFER,input_file ); + cube_yy_load_buffer_state( ); +} + +/** Switch to a different input buffer. + * @param new_buffer The new input buffer. + * + */ + void cube_yy_switch_to_buffer (YY_BUFFER_STATE new_buffer ) +{ + + /* TODO. We should be able to replace this entire function body + * with + * cube_yypop_buffer_state(); + * cube_yypush_buffer_state(new_buffer); + */ + cube_yyensure_buffer_stack (); + if ( YY_CURRENT_BUFFER == new_buffer ) + return; + + if ( YY_CURRENT_BUFFER ) + { + /* Flush out information for old buffer. */ + *(yy_c_buf_p) = (yy_hold_char); + YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p); + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); + } + + YY_CURRENT_BUFFER_LVALUE = new_buffer; + cube_yy_load_buffer_state( ); + + /* We don't actually know whether we did this switch during + * EOF (cube_yywrap()) processing, but the only time this flag + * is looked at is after cube_yywrap() is called, so it's safe + * to go ahead and always set it. + */ + (yy_did_buffer_switch_on_eof) = 1; +} + +static void cube_yy_load_buffer_state (void) +{ + (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars; + (yytext_ptr) = (yy_c_buf_p) = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos; + cube_yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file; + (yy_hold_char) = *(yy_c_buf_p); +} + +/** Allocate and initialize an input buffer state. + * @param file A readable stream. + * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE. + * + * @return the allocated buffer state. + */ + YY_BUFFER_STATE cube_yy_create_buffer (FILE * file, int size ) +{ + YY_BUFFER_STATE b; + + b = (YY_BUFFER_STATE) cube_yyalloc(sizeof( struct yy_buffer_state ) ); + if ( ! b ) + YY_FATAL_ERROR( "out of dynamic memory in cube_yy_create_buffer()" ); + + b->yy_buf_size = size; + + /* yy_ch_buf has to be 2 characters longer than the size given because + * we need to put in 2 end-of-buffer characters. + */ + b->yy_ch_buf = (char *) cube_yyalloc(b->yy_buf_size + 2 ); + if ( ! b->yy_ch_buf ) + YY_FATAL_ERROR( "out of dynamic memory in cube_yy_create_buffer()" ); + + b->yy_is_our_buffer = 1; + + cube_yy_init_buffer(b,file ); + + return b; +} + +/** Destroy the buffer. + * @param b a buffer created with cube_yy_create_buffer() + * + */ + void cube_yy_delete_buffer (YY_BUFFER_STATE b ) +{ + + if ( ! b ) + return; + + if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */ + YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0; + + if ( b->yy_is_our_buffer ) + cube_yyfree((void *) b->yy_ch_buf ); + + cube_yyfree((void *) b ); +} + +/* Initializes or reinitializes a buffer. + * This function is sometimes called more than once on the same buffer, + * such as during a cube_yyrestart() or at EOF. + */ + static void cube_yy_init_buffer (YY_BUFFER_STATE b, FILE * file ) + +{ + int oerrno = errno; + + cube_yy_flush_buffer(b ); + + b->yy_input_file = file; + b->yy_fill_buffer = 1; + + /* If b is the current buffer, then cube_yy_init_buffer was _probably_ + * called from cube_yyrestart() or through yy_get_next_buffer. + * In that case, we don't want to reset the lineno or column. + */ + if (b != YY_CURRENT_BUFFER){ + b->yy_bs_lineno = 1; + b->yy_bs_column = 0; + } + + b->yy_is_interactive = 0; + + errno = oerrno; +} + +/** Discard all buffered characters. On the next scan, YY_INPUT will be called. + * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER. + * + */ + void cube_yy_flush_buffer (YY_BUFFER_STATE b ) +{ + if ( ! b ) + return; + + b->yy_n_chars = 0; + + /* We always need two end-of-buffer characters. The first causes + * a transition to the end-of-buffer state. The second causes + * a jam in that state. + */ + b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR; + b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR; + + b->yy_buf_pos = &b->yy_ch_buf[0]; + + b->yy_at_bol = 1; + b->yy_buffer_status = YY_BUFFER_NEW; + + if ( b == YY_CURRENT_BUFFER ) + cube_yy_load_buffer_state( ); +} + +/** Pushes the new state onto the stack. The new state becomes + * the current state. This function will allocate the stack + * if necessary. + * @param new_buffer The new state. + * + */ +void cube_yypush_buffer_state (YY_BUFFER_STATE new_buffer ) +{ + if (new_buffer == NULL) + return; + + cube_yyensure_buffer_stack(); + + /* This block is copied from cube_yy_switch_to_buffer. */ + if ( YY_CURRENT_BUFFER ) + { + /* Flush out information for old buffer. */ + *(yy_c_buf_p) = (yy_hold_char); + YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p); + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); + } + + /* Only push if top exists. Otherwise, replace top. */ + if (YY_CURRENT_BUFFER) + (yy_buffer_stack_top)++; + YY_CURRENT_BUFFER_LVALUE = new_buffer; + + /* copied from cube_yy_switch_to_buffer. */ + cube_yy_load_buffer_state( ); + (yy_did_buffer_switch_on_eof) = 1; +} + +/** Removes and deletes the top of the stack, if present. + * The next element becomes the new top. + * + */ +void cube_yypop_buffer_state (void) +{ + if (!YY_CURRENT_BUFFER) + return; + + cube_yy_delete_buffer(YY_CURRENT_BUFFER ); + YY_CURRENT_BUFFER_LVALUE = NULL; + if ((yy_buffer_stack_top) > 0) + --(yy_buffer_stack_top); + + if (YY_CURRENT_BUFFER) { + cube_yy_load_buffer_state( ); + (yy_did_buffer_switch_on_eof) = 1; + } +} + +/* Allocates the stack if it does not exist. + * Guarantees space for at least one push. + */ +static void cube_yyensure_buffer_stack (void) +{ + int num_to_alloc; + + if (!(yy_buffer_stack)) { + + /* First allocation is just for 2 elements, since we don't know if this + * scanner will even need a stack. We use 2 instead of 1 to avoid an + * immediate realloc on the next call. + */ + num_to_alloc = 1; + (yy_buffer_stack) = (struct yy_buffer_state**)cube_yyalloc + (num_to_alloc * sizeof(struct yy_buffer_state*) + ); + if ( ! (yy_buffer_stack) ) + YY_FATAL_ERROR( "out of dynamic memory in cube_yyensure_buffer_stack()" ); + + memset((yy_buffer_stack), 0, num_to_alloc * sizeof(struct yy_buffer_state*)); + + (yy_buffer_stack_max) = num_to_alloc; + (yy_buffer_stack_top) = 0; + return; + } + + if ((yy_buffer_stack_top) >= ((yy_buffer_stack_max)) - 1){ + + /* Increase the buffer to prepare for a possible push. */ + int grow_size = 8 /* arbitrary grow size */; + + num_to_alloc = (yy_buffer_stack_max) + grow_size; + (yy_buffer_stack) = (struct yy_buffer_state**)cube_yyrealloc + ((yy_buffer_stack), + num_to_alloc * sizeof(struct yy_buffer_state*) + ); + if ( ! (yy_buffer_stack) ) + YY_FATAL_ERROR( "out of dynamic memory in cube_yyensure_buffer_stack()" ); + + /* zero only the new slots.*/ + memset((yy_buffer_stack) + (yy_buffer_stack_max), 0, grow_size * sizeof(struct yy_buffer_state*)); + (yy_buffer_stack_max) = num_to_alloc; + } +} + +/** Setup the input buffer state to scan directly from a user-specified character buffer. + * @param base the character buffer + * @param size the size in bytes of the character buffer + * + * @return the newly allocated buffer state object. + */ +YY_BUFFER_STATE cube_yy_scan_buffer (char * base, yy_size_t size ) +{ + YY_BUFFER_STATE b; + + if ( size < 2 || + base[size-2] != YY_END_OF_BUFFER_CHAR || + base[size-1] != YY_END_OF_BUFFER_CHAR ) + /* They forgot to leave room for the EOB's. */ + return 0; + + b = (YY_BUFFER_STATE) cube_yyalloc(sizeof( struct yy_buffer_state ) ); + if ( ! b ) + YY_FATAL_ERROR( "out of dynamic memory in cube_yy_scan_buffer()" ); + + b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */ + b->yy_buf_pos = b->yy_ch_buf = base; + b->yy_is_our_buffer = 0; + b->yy_input_file = 0; + b->yy_n_chars = b->yy_buf_size; + b->yy_is_interactive = 0; + b->yy_at_bol = 1; + b->yy_fill_buffer = 0; + b->yy_buffer_status = YY_BUFFER_NEW; + + cube_yy_switch_to_buffer(b ); + + return b; +} + +/** Setup the input buffer state to scan a string. The next call to cube_yylex() will + * scan from a @e copy of @a str. + * @param yystr a NUL-terminated string to scan + * + * @return the newly allocated buffer state object. + * @note If you want to scan bytes that may contain NUL values, then use + * cube_yy_scan_bytes() instead. + */ +YY_BUFFER_STATE cube_yy_scan_string (yyconst char * yystr ) +{ + + return cube_yy_scan_bytes(yystr,strlen(yystr) ); +} + +/** Setup the input buffer state to scan the given bytes. The next call to cube_yylex() will + * scan from a @e copy of @a bytes. + * @param yybytes the byte buffer to scan + * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes. + * + * @return the newly allocated buffer state object. + */ +YY_BUFFER_STATE cube_yy_scan_bytes (yyconst char * yybytes, int _yybytes_len ) +{ + YY_BUFFER_STATE b; + char *buf; + yy_size_t n; + int i; + + /* Get memory for full buffer, including space for trailing EOB's. */ + n = _yybytes_len + 2; + buf = (char *) cube_yyalloc(n ); + if ( ! buf ) + YY_FATAL_ERROR( "out of dynamic memory in cube_yy_scan_bytes()" ); + + for ( i = 0; i < _yybytes_len; ++i ) + buf[i] = yybytes[i]; + + buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR; + + b = cube_yy_scan_buffer(buf,n ); + if ( ! b ) + YY_FATAL_ERROR( "bad buffer in cube_yy_scan_bytes()" ); + + /* It's okay to grow etc. this buffer, and we should throw it + * away when we're done. + */ + b->yy_is_our_buffer = 1; + + return b; +} + +#ifndef YY_EXIT_FAILURE +#define YY_EXIT_FAILURE 2 +#endif + +static void yy_fatal_error (yyconst char* msg ) +{ + (void) fprintf( stderr, "%s\n", msg ); + exit( YY_EXIT_FAILURE ); +} + +/* Redefine yyless() so it works in section 3 code. */ + +#undef yyless +#define yyless(n) \ + do \ + { \ + /* Undo effects of setting up cube_yytext. */ \ + int yyless_macro_arg = (n); \ + YY_LESS_LINENO(yyless_macro_arg);\ + cube_yytext[cube_yyleng] = (yy_hold_char); \ + (yy_c_buf_p) = cube_yytext + yyless_macro_arg; \ + (yy_hold_char) = *(yy_c_buf_p); \ + *(yy_c_buf_p) = '\0'; \ + cube_yyleng = yyless_macro_arg; \ + } \ + while ( 0 ) + +/* Accessor methods (get/set functions) to struct members. */ + +/** Get the current line number. + * + */ +int cube_yyget_lineno (void) +{ + + return cube_yylineno; +} + +/** Get the input stream. + * + */ +FILE *cube_yyget_in (void) +{ + return cube_yyin; +} + +/** Get the output stream. + * + */ +FILE *cube_yyget_out (void) +{ + return cube_yyout; +} + +/** Get the length of the current token. + * + */ +int cube_yyget_leng (void) +{ + return cube_yyleng; +} + +/** Get the current token. + * + */ + +char *cube_yyget_text (void) +{ + return cube_yytext; +} + +/** Set the current line number. + * @param line_number + * + */ +void cube_yyset_lineno (int line_number ) +{ + + cube_yylineno = line_number; +} + +/** Set the input stream. This does not discard the current + * input buffer. + * @param in_str A readable stream. + * + * @see cube_yy_switch_to_buffer + */ +void cube_yyset_in (FILE * in_str ) +{ + cube_yyin = in_str ; +} + +void cube_yyset_out (FILE * out_str ) +{ + cube_yyout = out_str ; +} + +int cube_yyget_debug (void) +{ + return cube_yy_flex_debug; +} + +void cube_yyset_debug (int bdebug ) +{ + cube_yy_flex_debug = bdebug ; +} + +static int yy_init_globals (void) +{ + /* Initialization is the same as for the non-reentrant scanner. + * This function is called from cube_yylex_destroy(), so don't allocate here. + */ + + (yy_buffer_stack) = 0; + (yy_buffer_stack_top) = 0; + (yy_buffer_stack_max) = 0; + (yy_c_buf_p) = (char *) 0; + (yy_init) = 0; + (yy_start) = 0; + +/* Defined in main.c */ +#ifdef YY_STDINIT + cube_yyin = stdin; + cube_yyout = stdout; +#else + cube_yyin = (FILE *) 0; + cube_yyout = (FILE *) 0; +#endif + + /* For future reference: Set errno on error, since we are called by + * cube_yylex_init() + */ + return 0; +} + +/* cube_yylex_destroy is for both reentrant and non-reentrant scanners. */ +int cube_yylex_destroy (void) +{ + + /* Pop the buffer stack, destroying each element. */ + while(YY_CURRENT_BUFFER){ + cube_yy_delete_buffer(YY_CURRENT_BUFFER ); + YY_CURRENT_BUFFER_LVALUE = NULL; + cube_yypop_buffer_state(); + } + + /* Destroy the stack itself. */ + cube_yyfree((yy_buffer_stack) ); + (yy_buffer_stack) = NULL; + + /* Reset the globals. This is important in a non-reentrant scanner so the next time + * cube_yylex() is called, initialization will occur. */ + yy_init_globals( ); + + return 0; +} + +/* + * Internal utility routines. + */ + +#ifndef yytext_ptr +static void yy_flex_strncpy (char* s1, yyconst char * s2, int n ) +{ + register int i; + for ( i = 0; i < n; ++i ) + s1[i] = s2[i]; +} +#endif + +#ifdef YY_NEED_STRLEN +static int yy_flex_strlen (yyconst char * s ) +{ + register int n; + for ( n = 0; s[n]; ++n ) + ; + + return n; +} +#endif + +void *cube_yyalloc (yy_size_t size ) +{ + return (void *) malloc( size ); +} + +void *cube_yyrealloc (void * ptr, yy_size_t size ) +{ + /* The cast to (char *) in the following accommodates both + * implementations that use char* generic pointers, and those + * that use void* generic pointers. It works with the latter + * because both ANSI C and C++ allow castless assignment from + * any pointer type to void*, and deal with argument conversions + * as though doing an assignment. + */ + return (void *) realloc( (char *) ptr, size ); +} + +void cube_yyfree (void * ptr ) +{ + free( (char *) ptr ); /* see cube_yyrealloc() for (char *) cast */ +} + +#define YYTABLES_NAME "yytables" + +#line 55 "cubescan.l" + + + +void +yyerror(const char *message) +{ + if (*cube_yytext == YY_END_OF_BUFFER_CHAR) + { + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("bad cube representation"), + /* translator: %s is typically "syntax error" */ + errdetail("%s at end of input", message))); + } + else + { + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("bad cube representation"), + /* translator: first %s is typically "syntax error" */ + errdetail("%s at or near \"%s\"", message, cube_yytext))); + } +} + + +/* + * Called before any actual parsing is done + */ +void +cube_scanner_init(const char *str) +{ + Size slen = strlen(str); + + /* + * Might be left over after ereport() + */ + if (YY_CURRENT_BUFFER) + cube_yy_delete_buffer(YY_CURRENT_BUFFER); + + /* + * Make a scan buffer with special termination needed by flex. + */ + scanbuflen = slen; + scanbuf = palloc(slen + 2); + memcpy(scanbuf, str, slen); + scanbuf[slen] = scanbuf[slen + 1] = YY_END_OF_BUFFER_CHAR; + scanbufhandle = cube_yy_scan_buffer(scanbuf,slen + 2); + + BEGIN(INITIAL); +} + + +/* + * Called after parsing is done to clean up after cube_scanner_init() + */ +void +cube_scanner_finish(void) +{ + cube_yy_delete_buffer(scanbufhandle); + pfree(scanbuf); +} + diff --git a/contrib/dblink/.gitignore b/contrib/dblink/.gitignore deleted file mode 100644 index 5dcb3ff97..000000000 --- a/contrib/dblink/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -# Generated subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/contrib/dict_int/.gitignore b/contrib/dict_int/.gitignore deleted file mode 100644 index 5dcb3ff97..000000000 --- a/contrib/dict_int/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -# Generated subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/contrib/dict_xsyn/.gitignore b/contrib/dict_xsyn/.gitignore deleted file mode 100644 index 5dcb3ff97..000000000 --- a/contrib/dict_xsyn/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -# Generated subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/contrib/earthdistance/.gitignore b/contrib/earthdistance/.gitignore deleted file mode 100644 index 5dcb3ff97..000000000 --- a/contrib/earthdistance/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -# Generated subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/contrib/file_fdw/.gitignore b/contrib/file_fdw/.gitignore deleted file mode 100644 index 5dcb3ff97..000000000 --- a/contrib/file_fdw/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -# Generated subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/contrib/file_fdw/expected/.gitignore b/contrib/file_fdw/expected/.gitignore deleted file mode 100644 index a464ad144..000000000 --- a/contrib/file_fdw/expected/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/file_fdw.out diff --git a/contrib/file_fdw/sql/.gitignore b/contrib/file_fdw/sql/.gitignore deleted file mode 100644 index ebf16fed9..000000000 --- a/contrib/file_fdw/sql/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/file_fdw.sql diff --git a/contrib/hstore/.gitignore b/contrib/hstore/.gitignore deleted file mode 100644 index 5dcb3ff97..000000000 --- a/contrib/hstore/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -# Generated subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/contrib/intarray/.gitignore b/contrib/intarray/.gitignore deleted file mode 100644 index 5dcb3ff97..000000000 --- a/contrib/intarray/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -# Generated subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/contrib/ltree/.gitignore b/contrib/ltree/.gitignore deleted file mode 100644 index 5dcb3ff97..000000000 --- a/contrib/ltree/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -# Generated subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/contrib/oid2name/.gitignore b/contrib/oid2name/.gitignore deleted file mode 100644 index fdefde108..000000000 --- a/contrib/oid2name/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/oid2name diff --git a/contrib/pg_archivecleanup/.gitignore b/contrib/pg_archivecleanup/.gitignore deleted file mode 100644 index 804089070..000000000 --- a/contrib/pg_archivecleanup/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/pg_archivecleanup diff --git a/contrib/pg_standby/.gitignore b/contrib/pg_standby/.gitignore deleted file mode 100644 index a401b085a..000000000 --- a/contrib/pg_standby/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/pg_standby diff --git a/contrib/pg_test_fsync/.gitignore b/contrib/pg_test_fsync/.gitignore deleted file mode 100644 index f3b593249..000000000 --- a/contrib/pg_test_fsync/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/pg_test_fsync diff --git a/contrib/pg_test_timing/.gitignore b/contrib/pg_test_timing/.gitignore deleted file mode 100644 index f6c664c76..000000000 --- a/contrib/pg_test_timing/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/pg_test_timing diff --git a/contrib/pg_trgm/.gitignore b/contrib/pg_trgm/.gitignore deleted file mode 100644 index 5dcb3ff97..000000000 --- a/contrib/pg_trgm/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -# Generated subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/contrib/pg_upgrade/.gitignore b/contrib/pg_upgrade/.gitignore deleted file mode 100644 index 9555f54e8..000000000 --- a/contrib/pg_upgrade/.gitignore +++ /dev/null @@ -1,6 +0,0 @@ -/pg_upgrade -# Generated by test suite -analyze_new_cluster.sh -delete_old_cluster.sh -/log/ -/tmp_check/ diff --git a/contrib/pgbench/.gitignore b/contrib/pgbench/.gitignore deleted file mode 100644 index 489a2d62d..000000000 --- a/contrib/pgbench/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/pgbench diff --git a/contrib/pgcrypto/.gitignore b/contrib/pgcrypto/.gitignore deleted file mode 100644 index 5dcb3ff97..000000000 --- a/contrib/pgcrypto/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -# Generated subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/contrib/pgstattuple/.gitignore b/contrib/pgstattuple/.gitignore deleted file mode 100644 index 5dcb3ff97..000000000 --- a/contrib/pgstattuple/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -# Generated subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/contrib/seg/.gitignore b/contrib/seg/.gitignore deleted file mode 100644 index 69e73d209..000000000 --- a/contrib/seg/.gitignore +++ /dev/null @@ -1,6 +0,0 @@ -/segparse.c -/segscan.c -# Generated subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/contrib/seg/segparse.c b/contrib/seg/segparse.c new file mode 100644 index 000000000..50f434004 --- /dev/null +++ b/contrib/seg/segparse.c @@ -0,0 +1,1718 @@ + +/* A Bison parser, made by GNU Bison 2.4.1. */ + +/* Skeleton implementation for Bison's Yacc-like parsers in C + + Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 + Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . */ + +/* As a special exception, you may create a larger work that contains + part or all of the Bison parser skeleton and distribute that work + under terms of your choice, so long as that work isn't itself a + parser generator using the skeleton or a modified version thereof + as a parser skeleton. Alternatively, if you modify or redistribute + the parser skeleton itself, you may (at your option) remove this + special exception, which will cause the skeleton and the resulting + Bison output files to be licensed under the GNU General Public + License without this special exception. + + This special exception was added by the Free Software Foundation in + version 2.2 of Bison. */ + +/* C LALR(1) parser skeleton written by Richard Stallman, by + simplifying the original so-called "semantic" parser. */ + +/* All symbols defined below should begin with yy or YY, to avoid + infringing on user name space. This should be done even for local + variables, as they might otherwise be expanded by user macros. + There are some unavoidable exceptions within include files to + define necessary library symbols; they are noted "INFRINGES ON + USER NAME SPACE" below. */ + +/* Identify Bison output. */ +#define YYBISON 1 + +/* Bison version. */ +#define YYBISON_VERSION "2.4.1" + +/* Skeleton name. */ +#define YYSKELETON_NAME "yacc.c" + +/* Pure parsers. */ +#define YYPURE 0 + +/* Push parsers. */ +#define YYPUSH 0 + +/* Pull parsers. */ +#define YYPULL 1 + +/* Using locations. */ +#define YYLSP_NEEDED 0 + +/* Substitute the variable and function names. */ +#define yyparse seg_yyparse +#define yylex seg_yylex +#define yyerror seg_yyerror +#define yylval seg_yylval +#define yychar seg_yychar +#define yydebug seg_yydebug +#define yynerrs seg_yynerrs + + +/* Copy the first part of user declarations. */ + +/* Line 189 of yacc.c */ +#line 1 "segparse.y" + +#define YYPARSE_PARAM result /* need this to pass a pointer (void *) to yyparse */ + +#include "postgres.h" + +#include + +#include "fmgr.h" +#include "utils/builtins.h" +#include "segdata.h" + +/* + * Bison doesn't allocate anything that needs to live across parser calls, + * so we can easily have it use palloc instead of malloc. This prevents + * memory leaks if we error out during parsing. Note this only works with + * bison >= 2.0. However, in bison 1.875 the default is to use alloca() + * if possible, so there's not really much problem anyhow, at least if + * you're building with gcc. + */ +#define YYMALLOC palloc +#define YYFREE pfree + +extern int seg_yylex(void); + +extern int significant_digits(char *str); /* defined in seg.c */ + +void seg_yyerror(const char *message); +int seg_yyparse(void *result); + +static float seg_atof(char *value); + +static char strbuf[25] = { + '0', '0', '0', '0', '0', + '0', '0', '0', '0', '0', + '0', '0', '0', '0', '0', + '0', '0', '0', '0', '0', + '0', '0', '0', '0', '\0' +}; + + + +/* Line 189 of yacc.c */ +#line 123 "segparse.c" + +/* Enabling traces. */ +#ifndef YYDEBUG +# define YYDEBUG 0 +#endif + +/* Enabling verbose error messages. */ +#ifdef YYERROR_VERBOSE +# undef YYERROR_VERBOSE +# define YYERROR_VERBOSE 1 +#else +# define YYERROR_VERBOSE 0 +#endif + +/* Enabling the token table. */ +#ifndef YYTOKEN_TABLE +# define YYTOKEN_TABLE 0 +#endif + + +/* Tokens. */ +#ifndef YYTOKENTYPE +# define YYTOKENTYPE + /* Put the tokens into the symbol table, so that GDB and other debuggers + know about them. */ + enum yytokentype { + SEGFLOAT = 258, + RANGE = 259, + PLUMIN = 260, + EXTENSION = 261 + }; +#endif + + + +#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED +typedef union YYSTYPE +{ + +/* Line 214 of yacc.c */ +#line 46 "segparse.y" + + struct BND { + float val; + char ext; + char sigd; + } bnd; + char * text; + + + +/* Line 214 of yacc.c */ +#line 176 "segparse.c" +} YYSTYPE; +# define YYSTYPE_IS_TRIVIAL 1 +# define yystype YYSTYPE /* obsolescent; will be withdrawn */ +# define YYSTYPE_IS_DECLARED 1 +#endif + + +/* Copy the second part of user declarations. */ + + +/* Line 264 of yacc.c */ +#line 188 "segparse.c" + +#ifdef short +# undef short +#endif + +#ifdef YYTYPE_UINT8 +typedef YYTYPE_UINT8 yytype_uint8; +#else +typedef unsigned char yytype_uint8; +#endif + +#ifdef YYTYPE_INT8 +typedef YYTYPE_INT8 yytype_int8; +#elif (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +typedef signed char yytype_int8; +#else +typedef short int yytype_int8; +#endif + +#ifdef YYTYPE_UINT16 +typedef YYTYPE_UINT16 yytype_uint16; +#else +typedef unsigned short int yytype_uint16; +#endif + +#ifdef YYTYPE_INT16 +typedef YYTYPE_INT16 yytype_int16; +#else +typedef short int yytype_int16; +#endif + +#ifndef YYSIZE_T +# ifdef __SIZE_TYPE__ +# define YYSIZE_T __SIZE_TYPE__ +# elif defined size_t +# define YYSIZE_T size_t +# elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +# include /* INFRINGES ON USER NAME SPACE */ +# define YYSIZE_T size_t +# else +# define YYSIZE_T unsigned int +# endif +#endif + +#define YYSIZE_MAXIMUM ((YYSIZE_T) -1) + +#ifndef YY_ +# if YYENABLE_NLS +# if ENABLE_NLS +# include /* INFRINGES ON USER NAME SPACE */ +# define YY_(msgid) dgettext ("bison-runtime", msgid) +# endif +# endif +# ifndef YY_ +# define YY_(msgid) msgid +# endif +#endif + +/* Suppress unused-variable warnings by "using" E. */ +#if ! defined lint || defined __GNUC__ +# define YYUSE(e) ((void) (e)) +#else +# define YYUSE(e) /* empty */ +#endif + +/* Identity function, used to suppress warnings about constant conditions. */ +#ifndef lint +# define YYID(n) (n) +#else +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static int +YYID (int yyi) +#else +static int +YYID (yyi) + int yyi; +#endif +{ + return yyi; +} +#endif + +#if ! defined yyoverflow || YYERROR_VERBOSE + +/* The parser invokes alloca or malloc; define the necessary symbols. */ + +# ifdef YYSTACK_USE_ALLOCA +# if YYSTACK_USE_ALLOCA +# ifdef __GNUC__ +# define YYSTACK_ALLOC __builtin_alloca +# elif defined __BUILTIN_VA_ARG_INCR +# include /* INFRINGES ON USER NAME SPACE */ +# elif defined _AIX +# define YYSTACK_ALLOC __alloca +# elif defined _MSC_VER +# include /* INFRINGES ON USER NAME SPACE */ +# define alloca _alloca +# else +# define YYSTACK_ALLOC alloca +# if ! defined _ALLOCA_H && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +# include /* INFRINGES ON USER NAME SPACE */ +# ifndef _STDLIB_H +# define _STDLIB_H 1 +# endif +# endif +# endif +# endif +# endif + +# ifdef YYSTACK_ALLOC + /* Pacify GCC's `empty if-body' warning. */ +# define YYSTACK_FREE(Ptr) do { /* empty */; } while (YYID (0)) +# ifndef YYSTACK_ALLOC_MAXIMUM + /* The OS might guarantee only one guard page at the bottom of the stack, + and a page size can be as small as 4096 bytes. So we cannot safely + invoke alloca (N) if N exceeds 4096. Use a slightly smaller number + to allow for a few compiler-allocated temporary stack slots. */ +# define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */ +# endif +# else +# define YYSTACK_ALLOC YYMALLOC +# define YYSTACK_FREE YYFREE +# ifndef YYSTACK_ALLOC_MAXIMUM +# define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM +# endif +# if (defined __cplusplus && ! defined _STDLIB_H \ + && ! ((defined YYMALLOC || defined malloc) \ + && (defined YYFREE || defined free))) +# include /* INFRINGES ON USER NAME SPACE */ +# ifndef _STDLIB_H +# define _STDLIB_H 1 +# endif +# endif +# ifndef YYMALLOC +# define YYMALLOC malloc +# if ! defined malloc && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */ +# endif +# endif +# ifndef YYFREE +# define YYFREE free +# if ! defined free && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +void free (void *); /* INFRINGES ON USER NAME SPACE */ +# endif +# endif +# endif +#endif /* ! defined yyoverflow || YYERROR_VERBOSE */ + + +#if (! defined yyoverflow \ + && (! defined __cplusplus \ + || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) + +/* A type that is properly aligned for any stack member. */ +union yyalloc +{ + yytype_int16 yyss_alloc; + YYSTYPE yyvs_alloc; +}; + +/* The size of the maximum gap between one aligned stack and the next. */ +# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1) + +/* The size of an array large to enough to hold all stacks, each with + N elements. */ +# define YYSTACK_BYTES(N) \ + ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \ + + YYSTACK_GAP_MAXIMUM) + +/* Copy COUNT objects from FROM to TO. The source and destination do + not overlap. */ +# ifndef YYCOPY +# if defined __GNUC__ && 1 < __GNUC__ +# define YYCOPY(To, From, Count) \ + __builtin_memcpy (To, From, (Count) * sizeof (*(From))) +# else +# define YYCOPY(To, From, Count) \ + do \ + { \ + YYSIZE_T yyi; \ + for (yyi = 0; yyi < (Count); yyi++) \ + (To)[yyi] = (From)[yyi]; \ + } \ + while (YYID (0)) +# endif +# endif + +/* Relocate STACK from its old location to the new one. The + local variables YYSIZE and YYSTACKSIZE give the old and new number of + elements in the stack, and YYPTR gives the new location of the + stack. Advance YYPTR to a properly aligned location for the next + stack. */ +# define YYSTACK_RELOCATE(Stack_alloc, Stack) \ + do \ + { \ + YYSIZE_T yynewbytes; \ + YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \ + Stack = &yyptr->Stack_alloc; \ + yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ + yyptr += yynewbytes / sizeof (*yyptr); \ + } \ + while (YYID (0)) + +#endif + +/* YYFINAL -- State number of the termination state. */ +#define YYFINAL 8 +/* YYLAST -- Last index in YYTABLE. */ +#define YYLAST 12 + +/* YYNTOKENS -- Number of terminals. */ +#define YYNTOKENS 7 +/* YYNNTS -- Number of nonterminals. */ +#define YYNNTS 4 +/* YYNRULES -- Number of rules. */ +#define YYNRULES 9 +/* YYNRULES -- Number of states. */ +#define YYNSTATES 14 + +/* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */ +#define YYUNDEFTOK 2 +#define YYMAXUTOK 261 + +#define YYTRANSLATE(YYX) \ + ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) + +/* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */ +static const yytype_uint8 yytranslate[] = +{ + 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 1, 2, 3, 4, + 5, 6 +}; + +#if YYDEBUG +/* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in + YYRHS. */ +static const yytype_uint8 yyprhs[] = +{ + 0, 0, 3, 7, 11, 14, 17, 19, 21, 24 +}; + +/* YYRHS -- A `-1'-separated list of the rules' RHS. */ +static const yytype_int8 yyrhs[] = +{ + 8, 0, -1, 9, 5, 10, -1, 9, 4, 9, + -1, 9, 4, -1, 4, 9, -1, 9, -1, 3, + -1, 6, 3, -1, 3, -1 +}; + +/* YYRLINE[YYN] -- source line where rule number YYN was defined. */ +static const yytype_uint8 yyrline[] = +{ + 0, 66, 66, 78, 96, 106, 116, 124, 133, 144 +}; +#endif + +#if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE +/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM. + First, the terminals, then, starting at YYNTOKENS, nonterminals. */ +static const char *const yytname[] = +{ + "$end", "error", "$undefined", "SEGFLOAT", "RANGE", "PLUMIN", + "EXTENSION", "$accept", "range", "boundary", "deviation", 0 +}; +#endif + +# ifdef YYPRINT +/* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to + token YYLEX-NUM. */ +static const yytype_uint16 yytoknum[] = +{ + 0, 256, 257, 258, 259, 260, 261 +}; +# endif + +/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ +static const yytype_uint8 yyr1[] = +{ + 0, 7, 8, 8, 8, 8, 8, 9, 9, 10 +}; + +/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */ +static const yytype_uint8 yyr2[] = +{ + 0, 2, 3, 3, 2, 2, 1, 1, 2, 1 +}; + +/* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state + STATE-NUM when YYTABLE doesn't specify something else to do. Zero + means the default is an error. */ +static const yytype_uint8 yydefact[] = +{ + 0, 7, 0, 0, 0, 6, 5, 8, 1, 4, + 0, 3, 9, 2 +}; + +/* YYDEFGOTO[NTERM-NUM]. */ +static const yytype_int8 yydefgoto[] = +{ + -1, 4, 5, 13 +}; + +/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing + STATE-NUM. */ +#define YYPACT_NINF -3 +static const yytype_int8 yypact[] = +{ + -1, -3, 3, 1, 8, 6, -3, -3, -3, 3, + 9, -3, -3, -3 +}; + +/* YYPGOTO[NTERM-NUM]. */ +static const yytype_int8 yypgoto[] = +{ + -3, -3, -2, -3 +}; + +/* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If + positive, shift that token. If negative, reduce the rule which + number is the opposite. If zero, do what YYDEFACT says. + If YYTABLE_NINF, syntax error. */ +#define YYTABLE_NINF -1 +static const yytype_uint8 yytable[] = +{ + 6, 0, 1, 2, 7, 3, 1, 11, 8, 3, + 9, 10, 12 +}; + +static const yytype_int8 yycheck[] = +{ + 2, -1, 3, 4, 3, 6, 3, 9, 0, 6, + 4, 5, 3 +}; + +/* YYSTOS[STATE-NUM] -- The (internal number of the) accessing + symbol of state STATE-NUM. */ +static const yytype_uint8 yystos[] = +{ + 0, 3, 4, 6, 8, 9, 9, 3, 0, 4, + 5, 9, 3, 10 +}; + +#define yyerrok (yyerrstatus = 0) +#define yyclearin (yychar = YYEMPTY) +#define YYEMPTY (-2) +#define YYEOF 0 + +#define YYACCEPT goto yyacceptlab +#define YYABORT goto yyabortlab +#define YYERROR goto yyerrorlab + + +/* Like YYERROR except do call yyerror. This remains here temporarily + to ease the transition to the new meaning of YYERROR, for GCC. + Once GCC version 2 has supplanted version 1, this can go. */ + +#define YYFAIL goto yyerrlab + +#define YYRECOVERING() (!!yyerrstatus) + +#define YYBACKUP(Token, Value) \ +do \ + if (yychar == YYEMPTY && yylen == 1) \ + { \ + yychar = (Token); \ + yylval = (Value); \ + yytoken = YYTRANSLATE (yychar); \ + YYPOPSTACK (1); \ + goto yybackup; \ + } \ + else \ + { \ + yyerror (YY_("syntax error: cannot back up")); \ + YYERROR; \ + } \ +while (YYID (0)) + + +#define YYTERROR 1 +#define YYERRCODE 256 + + +/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N]. + If N is 0, then set CURRENT to the empty location which ends + the previous symbol: RHS[0] (always defined). */ + +#define YYRHSLOC(Rhs, K) ((Rhs)[K]) +#ifndef YYLLOC_DEFAULT +# define YYLLOC_DEFAULT(Current, Rhs, N) \ + do \ + if (YYID (N)) \ + { \ + (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \ + (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \ + (Current).last_line = YYRHSLOC (Rhs, N).last_line; \ + (Current).last_column = YYRHSLOC (Rhs, N).last_column; \ + } \ + else \ + { \ + (Current).first_line = (Current).last_line = \ + YYRHSLOC (Rhs, 0).last_line; \ + (Current).first_column = (Current).last_column = \ + YYRHSLOC (Rhs, 0).last_column; \ + } \ + while (YYID (0)) +#endif + + +/* YY_LOCATION_PRINT -- Print the location on the stream. + This macro was not mandated originally: define only if we know + we won't break user code: when these are the locations we know. */ + +#ifndef YY_LOCATION_PRINT +# if YYLTYPE_IS_TRIVIAL +# define YY_LOCATION_PRINT(File, Loc) \ + fprintf (File, "%d.%d-%d.%d", \ + (Loc).first_line, (Loc).first_column, \ + (Loc).last_line, (Loc).last_column) +# else +# define YY_LOCATION_PRINT(File, Loc) ((void) 0) +# endif +#endif + + +/* YYLEX -- calling `yylex' with the right arguments. */ + +#ifdef YYLEX_PARAM +# define YYLEX yylex (YYLEX_PARAM) +#else +# define YYLEX yylex () +#endif + +/* Enable debugging if requested. */ +#if YYDEBUG + +# ifndef YYFPRINTF +# include /* INFRINGES ON USER NAME SPACE */ +# define YYFPRINTF fprintf +# endif + +# define YYDPRINTF(Args) \ +do { \ + if (yydebug) \ + YYFPRINTF Args; \ +} while (YYID (0)) + +# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \ +do { \ + if (yydebug) \ + { \ + YYFPRINTF (stderr, "%s ", Title); \ + yy_symbol_print (stderr, \ + Type, Value); \ + YYFPRINTF (stderr, "\n"); \ + } \ +} while (YYID (0)) + + +/*--------------------------------. +| Print this symbol on YYOUTPUT. | +`--------------------------------*/ + +/*ARGSUSED*/ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep) +#else +static void +yy_symbol_value_print (yyoutput, yytype, yyvaluep) + FILE *yyoutput; + int yytype; + YYSTYPE const * const yyvaluep; +#endif +{ + if (!yyvaluep) + return; +# ifdef YYPRINT + if (yytype < YYNTOKENS) + YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep); +# else + YYUSE (yyoutput); +# endif + switch (yytype) + { + default: + break; + } +} + + +/*--------------------------------. +| Print this symbol on YYOUTPUT. | +`--------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep) +#else +static void +yy_symbol_print (yyoutput, yytype, yyvaluep) + FILE *yyoutput; + int yytype; + YYSTYPE const * const yyvaluep; +#endif +{ + if (yytype < YYNTOKENS) + YYFPRINTF (yyoutput, "token %s (", yytname[yytype]); + else + YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]); + + yy_symbol_value_print (yyoutput, yytype, yyvaluep); + YYFPRINTF (yyoutput, ")"); +} + +/*------------------------------------------------------------------. +| yy_stack_print -- Print the state stack from its BOTTOM up to its | +| TOP (included). | +`------------------------------------------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop) +#else +static void +yy_stack_print (yybottom, yytop) + yytype_int16 *yybottom; + yytype_int16 *yytop; +#endif +{ + YYFPRINTF (stderr, "Stack now"); + for (; yybottom <= yytop; yybottom++) + { + int yybot = *yybottom; + YYFPRINTF (stderr, " %d", yybot); + } + YYFPRINTF (stderr, "\n"); +} + +# define YY_STACK_PRINT(Bottom, Top) \ +do { \ + if (yydebug) \ + yy_stack_print ((Bottom), (Top)); \ +} while (YYID (0)) + + +/*------------------------------------------------. +| Report that the YYRULE is going to be reduced. | +`------------------------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_reduce_print (YYSTYPE *yyvsp, int yyrule) +#else +static void +yy_reduce_print (yyvsp, yyrule) + YYSTYPE *yyvsp; + int yyrule; +#endif +{ + int yynrhs = yyr2[yyrule]; + int yyi; + unsigned long int yylno = yyrline[yyrule]; + YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n", + yyrule - 1, yylno); + /* The symbols being reduced. */ + for (yyi = 0; yyi < yynrhs; yyi++) + { + YYFPRINTF (stderr, " $%d = ", yyi + 1); + yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi], + &(yyvsp[(yyi + 1) - (yynrhs)]) + ); + YYFPRINTF (stderr, "\n"); + } +} + +# define YY_REDUCE_PRINT(Rule) \ +do { \ + if (yydebug) \ + yy_reduce_print (yyvsp, Rule); \ +} while (YYID (0)) + +/* Nonzero means print parse trace. It is left uninitialized so that + multiple parsers can coexist. */ +int yydebug; +#else /* !YYDEBUG */ +# define YYDPRINTF(Args) +# define YY_SYMBOL_PRINT(Title, Type, Value, Location) +# define YY_STACK_PRINT(Bottom, Top) +# define YY_REDUCE_PRINT(Rule) +#endif /* !YYDEBUG */ + + +/* YYINITDEPTH -- initial size of the parser's stacks. */ +#ifndef YYINITDEPTH +# define YYINITDEPTH 200 +#endif + +/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only + if the built-in stack extension method is used). + + Do not make this value too large; the results are undefined if + YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH) + evaluated with infinite-precision integer arithmetic. */ + +#ifndef YYMAXDEPTH +# define YYMAXDEPTH 10000 +#endif + + + +#if YYERROR_VERBOSE + +# ifndef yystrlen +# if defined __GLIBC__ && defined _STRING_H +# define yystrlen strlen +# else +/* Return the length of YYSTR. */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static YYSIZE_T +yystrlen (const char *yystr) +#else +static YYSIZE_T +yystrlen (yystr) + const char *yystr; +#endif +{ + YYSIZE_T yylen; + for (yylen = 0; yystr[yylen]; yylen++) + continue; + return yylen; +} +# endif +# endif + +# ifndef yystpcpy +# if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE +# define yystpcpy stpcpy +# else +/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in + YYDEST. */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static char * +yystpcpy (char *yydest, const char *yysrc) +#else +static char * +yystpcpy (yydest, yysrc) + char *yydest; + const char *yysrc; +#endif +{ + char *yyd = yydest; + const char *yys = yysrc; + + while ((*yyd++ = *yys++) != '\0') + continue; + + return yyd - 1; +} +# endif +# endif + +# ifndef yytnamerr +/* Copy to YYRES the contents of YYSTR after stripping away unnecessary + quotes and backslashes, so that it's suitable for yyerror. The + heuristic is that double-quoting is unnecessary unless the string + contains an apostrophe, a comma, or backslash (other than + backslash-backslash). YYSTR is taken from yytname. If YYRES is + null, do not copy; instead, return the length of what the result + would have been. */ +static YYSIZE_T +yytnamerr (char *yyres, const char *yystr) +{ + if (*yystr == '"') + { + YYSIZE_T yyn = 0; + char const *yyp = yystr; + + for (;;) + switch (*++yyp) + { + case '\'': + case ',': + goto do_not_strip_quotes; + + case '\\': + if (*++yyp != '\\') + goto do_not_strip_quotes; + /* Fall through. */ + default: + if (yyres) + yyres[yyn] = *yyp; + yyn++; + break; + + case '"': + if (yyres) + yyres[yyn] = '\0'; + return yyn; + } + do_not_strip_quotes: ; + } + + if (! yyres) + return yystrlen (yystr); + + return yystpcpy (yyres, yystr) - yyres; +} +# endif + +/* Copy into YYRESULT an error message about the unexpected token + YYCHAR while in state YYSTATE. Return the number of bytes copied, + including the terminating null byte. If YYRESULT is null, do not + copy anything; just return the number of bytes that would be + copied. As a special case, return 0 if an ordinary "syntax error" + message will do. Return YYSIZE_MAXIMUM if overflow occurs during + size calculation. */ +static YYSIZE_T +yysyntax_error (char *yyresult, int yystate, int yychar) +{ + int yyn = yypact[yystate]; + + if (! (YYPACT_NINF < yyn && yyn <= YYLAST)) + return 0; + else + { + int yytype = YYTRANSLATE (yychar); + YYSIZE_T yysize0 = yytnamerr (0, yytname[yytype]); + YYSIZE_T yysize = yysize0; + YYSIZE_T yysize1; + int yysize_overflow = 0; + enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; + char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; + int yyx; + +# if 0 + /* This is so xgettext sees the translatable formats that are + constructed on the fly. */ + YY_("syntax error, unexpected %s"); + YY_("syntax error, unexpected %s, expecting %s"); + YY_("syntax error, unexpected %s, expecting %s or %s"); + YY_("syntax error, unexpected %s, expecting %s or %s or %s"); + YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"); +# endif + char *yyfmt; + char const *yyf; + static char const yyunexpected[] = "syntax error, unexpected %s"; + static char const yyexpecting[] = ", expecting %s"; + static char const yyor[] = " or %s"; + char yyformat[sizeof yyunexpected + + sizeof yyexpecting - 1 + + ((YYERROR_VERBOSE_ARGS_MAXIMUM - 2) + * (sizeof yyor - 1))]; + char const *yyprefix = yyexpecting; + + /* Start YYX at -YYN if negative to avoid negative indexes in + YYCHECK. */ + int yyxbegin = yyn < 0 ? -yyn : 0; + + /* Stay within bounds of both yycheck and yytname. */ + int yychecklim = YYLAST - yyn + 1; + int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; + int yycount = 1; + + yyarg[0] = yytname[yytype]; + yyfmt = yystpcpy (yyformat, yyunexpected); + + for (yyx = yyxbegin; yyx < yyxend; ++yyx) + if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR) + { + if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) + { + yycount = 1; + yysize = yysize0; + yyformat[sizeof yyunexpected - 1] = '\0'; + break; + } + yyarg[yycount++] = yytname[yyx]; + yysize1 = yysize + yytnamerr (0, yytname[yyx]); + yysize_overflow |= (yysize1 < yysize); + yysize = yysize1; + yyfmt = yystpcpy (yyfmt, yyprefix); + yyprefix = yyor; + } + + yyf = YY_(yyformat); + yysize1 = yysize + yystrlen (yyf); + yysize_overflow |= (yysize1 < yysize); + yysize = yysize1; + + if (yysize_overflow) + return YYSIZE_MAXIMUM; + + if (yyresult) + { + /* Avoid sprintf, as that infringes on the user's name space. + Don't have undefined behavior even if the translation + produced a string with the wrong number of "%s"s. */ + char *yyp = yyresult; + int yyi = 0; + while ((*yyp = *yyf) != '\0') + { + if (*yyp == '%' && yyf[1] == 's' && yyi < yycount) + { + yyp += yytnamerr (yyp, yyarg[yyi++]); + yyf += 2; + } + else + { + yyp++; + yyf++; + } + } + } + return yysize; + } +} +#endif /* YYERROR_VERBOSE */ + + +/*-----------------------------------------------. +| Release the memory associated to this symbol. | +`-----------------------------------------------*/ + +/*ARGSUSED*/ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep) +#else +static void +yydestruct (yymsg, yytype, yyvaluep) + const char *yymsg; + int yytype; + YYSTYPE *yyvaluep; +#endif +{ + YYUSE (yyvaluep); + + if (!yymsg) + yymsg = "Deleting"; + YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp); + + switch (yytype) + { + + default: + break; + } +} + +/* Prevent warnings from -Wmissing-prototypes. */ +#ifdef YYPARSE_PARAM +#if defined __STDC__ || defined __cplusplus +int yyparse (void *YYPARSE_PARAM); +#else +int yyparse (); +#endif +#else /* ! YYPARSE_PARAM */ +#if defined __STDC__ || defined __cplusplus +int yyparse (void); +#else +int yyparse (); +#endif +#endif /* ! YYPARSE_PARAM */ + + +/* The lookahead symbol. */ +int yychar; + +/* The semantic value of the lookahead symbol. */ +YYSTYPE yylval; + +/* Number of syntax errors so far. */ +int yynerrs; + + + +/*-------------------------. +| yyparse or yypush_parse. | +`-------------------------*/ + +#ifdef YYPARSE_PARAM +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +int +yyparse (void *YYPARSE_PARAM) +#else +int +yyparse (YYPARSE_PARAM) + void *YYPARSE_PARAM; +#endif +#else /* ! YYPARSE_PARAM */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +int +yyparse (void) +#else +int +yyparse () + +#endif +#endif +{ + + + int yystate; + /* Number of tokens to shift before error messages enabled. */ + int yyerrstatus; + + /* The stacks and their tools: + `yyss': related to states. + `yyvs': related to semantic values. + + Refer to the stacks thru separate pointers, to allow yyoverflow + to reallocate them elsewhere. */ + + /* The state stack. */ + yytype_int16 yyssa[YYINITDEPTH]; + yytype_int16 *yyss; + yytype_int16 *yyssp; + + /* The semantic value stack. */ + YYSTYPE yyvsa[YYINITDEPTH]; + YYSTYPE *yyvs; + YYSTYPE *yyvsp; + + YYSIZE_T yystacksize; + + int yyn; + int yyresult; + /* Lookahead token as an internal (translated) token number. */ + int yytoken; + /* The variables used to return semantic value and location from the + action routines. */ + YYSTYPE yyval; + +#if YYERROR_VERBOSE + /* Buffer for error messages, and its allocated size. */ + char yymsgbuf[128]; + char *yymsg = yymsgbuf; + YYSIZE_T yymsg_alloc = sizeof yymsgbuf; +#endif + +#define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N)) + + /* The number of symbols on the RHS of the reduced rule. + Keep to zero when no symbol should be popped. */ + int yylen = 0; + + yytoken = 0; + yyss = yyssa; + yyvs = yyvsa; + yystacksize = YYINITDEPTH; + + YYDPRINTF ((stderr, "Starting parse\n")); + + yystate = 0; + yyerrstatus = 0; + yynerrs = 0; + yychar = YYEMPTY; /* Cause a token to be read. */ + + /* Initialize stack pointers. + Waste one element of value and location stack + so that they stay on the same level as the state stack. + The wasted elements are never initialized. */ + yyssp = yyss; + yyvsp = yyvs; + + goto yysetstate; + +/*------------------------------------------------------------. +| yynewstate -- Push a new state, which is found in yystate. | +`------------------------------------------------------------*/ + yynewstate: + /* In all cases, when you get here, the value and location stacks + have just been pushed. So pushing a state here evens the stacks. */ + yyssp++; + + yysetstate: + *yyssp = yystate; + + if (yyss + yystacksize - 1 <= yyssp) + { + /* Get the current used size of the three stacks, in elements. */ + YYSIZE_T yysize = yyssp - yyss + 1; + +#ifdef yyoverflow + { + /* Give user a chance to reallocate the stack. Use copies of + these so that the &'s don't force the real ones into + memory. */ + YYSTYPE *yyvs1 = yyvs; + yytype_int16 *yyss1 = yyss; + + /* Each stack pointer address is followed by the size of the + data in use in that stack, in bytes. This used to be a + conditional around just the two extra args, but that might + be undefined if yyoverflow is a macro. */ + yyoverflow (YY_("memory exhausted"), + &yyss1, yysize * sizeof (*yyssp), + &yyvs1, yysize * sizeof (*yyvsp), + &yystacksize); + + yyss = yyss1; + yyvs = yyvs1; + } +#else /* no yyoverflow */ +# ifndef YYSTACK_RELOCATE + goto yyexhaustedlab; +# else + /* Extend the stack our own way. */ + if (YYMAXDEPTH <= yystacksize) + goto yyexhaustedlab; + yystacksize *= 2; + if (YYMAXDEPTH < yystacksize) + yystacksize = YYMAXDEPTH; + + { + yytype_int16 *yyss1 = yyss; + union yyalloc *yyptr = + (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize)); + if (! yyptr) + goto yyexhaustedlab; + YYSTACK_RELOCATE (yyss_alloc, yyss); + YYSTACK_RELOCATE (yyvs_alloc, yyvs); +# undef YYSTACK_RELOCATE + if (yyss1 != yyssa) + YYSTACK_FREE (yyss1); + } +# endif +#endif /* no yyoverflow */ + + yyssp = yyss + yysize - 1; + yyvsp = yyvs + yysize - 1; + + YYDPRINTF ((stderr, "Stack size increased to %lu\n", + (unsigned long int) yystacksize)); + + if (yyss + yystacksize - 1 <= yyssp) + YYABORT; + } + + YYDPRINTF ((stderr, "Entering state %d\n", yystate)); + + if (yystate == YYFINAL) + YYACCEPT; + + goto yybackup; + +/*-----------. +| yybackup. | +`-----------*/ +yybackup: + + /* Do appropriate processing given the current state. Read a + lookahead token if we need one and don't already have one. */ + + /* First try to decide what to do without reference to lookahead token. */ + yyn = yypact[yystate]; + if (yyn == YYPACT_NINF) + goto yydefault; + + /* Not known => get a lookahead token if don't already have one. */ + + /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */ + if (yychar == YYEMPTY) + { + YYDPRINTF ((stderr, "Reading a token: ")); + yychar = YYLEX; + } + + if (yychar <= YYEOF) + { + yychar = yytoken = YYEOF; + YYDPRINTF ((stderr, "Now at end of input.\n")); + } + else + { + yytoken = YYTRANSLATE (yychar); + YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc); + } + + /* If the proper action on seeing token YYTOKEN is to reduce or to + detect an error, take that action. */ + yyn += yytoken; + if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken) + goto yydefault; + yyn = yytable[yyn]; + if (yyn <= 0) + { + if (yyn == 0 || yyn == YYTABLE_NINF) + goto yyerrlab; + yyn = -yyn; + goto yyreduce; + } + + /* Count tokens shifted since error; after three, turn off error + status. */ + if (yyerrstatus) + yyerrstatus--; + + /* Shift the lookahead token. */ + YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc); + + /* Discard the shifted token. */ + yychar = YYEMPTY; + + yystate = yyn; + *++yyvsp = yylval; + + goto yynewstate; + + +/*-----------------------------------------------------------. +| yydefault -- do the default action for the current state. | +`-----------------------------------------------------------*/ +yydefault: + yyn = yydefact[yystate]; + if (yyn == 0) + goto yyerrlab; + goto yyreduce; + + +/*-----------------------------. +| yyreduce -- Do a reduction. | +`-----------------------------*/ +yyreduce: + /* yyn is the number of a rule to reduce with. */ + yylen = yyr2[yyn]; + + /* If YYLEN is nonzero, implement the default value of the action: + `$$ = $1'. + + Otherwise, the following line sets YYVAL to garbage. + This behavior is undocumented and Bison + users should not rely upon it. Assigning to YYVAL + unconditionally makes the parser a bit smaller, and it avoids a + GCC warning that YYVAL may be used uninitialized. */ + yyval = yyvsp[1-yylen]; + + + YY_REDUCE_PRINT (yyn); + switch (yyn) + { + case 2: + +/* Line 1455 of yacc.c */ +#line 67 "segparse.y" + { + ((SEG *)result)->lower = (yyvsp[(1) - (3)].bnd).val - (yyvsp[(3) - (3)].bnd).val; + ((SEG *)result)->upper = (yyvsp[(1) - (3)].bnd).val + (yyvsp[(3) - (3)].bnd).val; + sprintf(strbuf, "%g", ((SEG *)result)->lower); + ((SEG *)result)->l_sigd = Max(Min(6, significant_digits(strbuf)), Max((yyvsp[(1) - (3)].bnd).sigd, (yyvsp[(3) - (3)].bnd).sigd)); + sprintf(strbuf, "%g", ((SEG *)result)->upper); + ((SEG *)result)->u_sigd = Max(Min(6, significant_digits(strbuf)), Max((yyvsp[(1) - (3)].bnd).sigd, (yyvsp[(3) - (3)].bnd).sigd)); + ((SEG *)result)->l_ext = '\0'; + ((SEG *)result)->u_ext = '\0'; + ;} + break; + + case 3: + +/* Line 1455 of yacc.c */ +#line 79 "segparse.y" + { + ((SEG *)result)->lower = (yyvsp[(1) - (3)].bnd).val; + ((SEG *)result)->upper = (yyvsp[(3) - (3)].bnd).val; + if ( ((SEG *)result)->lower > ((SEG *)result)->upper ) { + ereport(ERROR, + (errcode(ERRCODE_INVALID_PARAMETER_VALUE), + errmsg("swapped boundaries: %g is greater than %g", + ((SEG *)result)->lower, ((SEG *)result)->upper))); + + YYERROR; + } + ((SEG *)result)->l_sigd = (yyvsp[(1) - (3)].bnd).sigd; + ((SEG *)result)->u_sigd = (yyvsp[(3) - (3)].bnd).sigd; + ((SEG *)result)->l_ext = ( (yyvsp[(1) - (3)].bnd).ext ? (yyvsp[(1) - (3)].bnd).ext : '\0' ); + ((SEG *)result)->u_ext = ( (yyvsp[(3) - (3)].bnd).ext ? (yyvsp[(3) - (3)].bnd).ext : '\0' ); + ;} + break; + + case 4: + +/* Line 1455 of yacc.c */ +#line 97 "segparse.y" + { + ((SEG *)result)->lower = (yyvsp[(1) - (2)].bnd).val; + ((SEG *)result)->upper = HUGE_VAL; + ((SEG *)result)->l_sigd = (yyvsp[(1) - (2)].bnd).sigd; + ((SEG *)result)->u_sigd = 0; + ((SEG *)result)->l_ext = ( (yyvsp[(1) - (2)].bnd).ext ? (yyvsp[(1) - (2)].bnd).ext : '\0' ); + ((SEG *)result)->u_ext = '-'; + ;} + break; + + case 5: + +/* Line 1455 of yacc.c */ +#line 107 "segparse.y" + { + ((SEG *)result)->lower = -HUGE_VAL; + ((SEG *)result)->upper = (yyvsp[(2) - (2)].bnd).val; + ((SEG *)result)->l_sigd = 0; + ((SEG *)result)->u_sigd = (yyvsp[(2) - (2)].bnd).sigd; + ((SEG *)result)->l_ext = '-'; + ((SEG *)result)->u_ext = ( (yyvsp[(2) - (2)].bnd).ext ? (yyvsp[(2) - (2)].bnd).ext : '\0' ); + ;} + break; + + case 6: + +/* Line 1455 of yacc.c */ +#line 117 "segparse.y" + { + ((SEG *)result)->lower = ((SEG *)result)->upper = (yyvsp[(1) - (1)].bnd).val; + ((SEG *)result)->l_sigd = ((SEG *)result)->u_sigd = (yyvsp[(1) - (1)].bnd).sigd; + ((SEG *)result)->l_ext = ((SEG *)result)->u_ext = ( (yyvsp[(1) - (1)].bnd).ext ? (yyvsp[(1) - (1)].bnd).ext : '\0' ); + ;} + break; + + case 7: + +/* Line 1455 of yacc.c */ +#line 125 "segparse.y" + { + /* temp variable avoids a gcc 3.3.x bug on Sparc64 */ + float val = seg_atof((yyvsp[(1) - (1)].text)); + + (yyval.bnd).ext = '\0'; + (yyval.bnd).sigd = significant_digits((yyvsp[(1) - (1)].text)); + (yyval.bnd).val = val; + ;} + break; + + case 8: + +/* Line 1455 of yacc.c */ +#line 134 "segparse.y" + { + /* temp variable avoids a gcc 3.3.x bug on Sparc64 */ + float val = seg_atof((yyvsp[(2) - (2)].text)); + + (yyval.bnd).ext = (yyvsp[(1) - (2)].text)[0]; + (yyval.bnd).sigd = significant_digits((yyvsp[(2) - (2)].text)); + (yyval.bnd).val = val; + ;} + break; + + case 9: + +/* Line 1455 of yacc.c */ +#line 145 "segparse.y" + { + /* temp variable avoids a gcc 3.3.x bug on Sparc64 */ + float val = seg_atof((yyvsp[(1) - (1)].text)); + + (yyval.bnd).ext = '\0'; + (yyval.bnd).sigd = significant_digits((yyvsp[(1) - (1)].text)); + (yyval.bnd).val = val; + ;} + break; + + + +/* Line 1455 of yacc.c */ +#line 1492 "segparse.c" + default: break; + } + YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); + + YYPOPSTACK (yylen); + yylen = 0; + YY_STACK_PRINT (yyss, yyssp); + + *++yyvsp = yyval; + + /* Now `shift' the result of the reduction. Determine what state + that goes to, based on the state we popped back to and the rule + number reduced by. */ + + yyn = yyr1[yyn]; + + yystate = yypgoto[yyn - YYNTOKENS] + *yyssp; + if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp) + yystate = yytable[yystate]; + else + yystate = yydefgoto[yyn - YYNTOKENS]; + + goto yynewstate; + + +/*------------------------------------. +| yyerrlab -- here on detecting error | +`------------------------------------*/ +yyerrlab: + /* If not already recovering from an error, report this error. */ + if (!yyerrstatus) + { + ++yynerrs; +#if ! YYERROR_VERBOSE + yyerror (YY_("syntax error")); +#else + { + YYSIZE_T yysize = yysyntax_error (0, yystate, yychar); + if (yymsg_alloc < yysize && yymsg_alloc < YYSTACK_ALLOC_MAXIMUM) + { + YYSIZE_T yyalloc = 2 * yysize; + if (! (yysize <= yyalloc && yyalloc <= YYSTACK_ALLOC_MAXIMUM)) + yyalloc = YYSTACK_ALLOC_MAXIMUM; + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); + yymsg = (char *) YYSTACK_ALLOC (yyalloc); + if (yymsg) + yymsg_alloc = yyalloc; + else + { + yymsg = yymsgbuf; + yymsg_alloc = sizeof yymsgbuf; + } + } + + if (0 < yysize && yysize <= yymsg_alloc) + { + (void) yysyntax_error (yymsg, yystate, yychar); + yyerror (yymsg); + } + else + { + yyerror (YY_("syntax error")); + if (yysize != 0) + goto yyexhaustedlab; + } + } +#endif + } + + + + if (yyerrstatus == 3) + { + /* If just tried and failed to reuse lookahead token after an + error, discard it. */ + + if (yychar <= YYEOF) + { + /* Return failure if at end of input. */ + if (yychar == YYEOF) + YYABORT; + } + else + { + yydestruct ("Error: discarding", + yytoken, &yylval); + yychar = YYEMPTY; + } + } + + /* Else will try to reuse lookahead token after shifting the error + token. */ + goto yyerrlab1; + + +/*---------------------------------------------------. +| yyerrorlab -- error raised explicitly by YYERROR. | +`---------------------------------------------------*/ +yyerrorlab: + + /* Pacify compilers like GCC when the user code never invokes + YYERROR and the label yyerrorlab therefore never appears in user + code. */ + if (/*CONSTCOND*/ 0) + goto yyerrorlab; + + /* Do not reclaim the symbols of the rule which action triggered + this YYERROR. */ + YYPOPSTACK (yylen); + yylen = 0; + YY_STACK_PRINT (yyss, yyssp); + yystate = *yyssp; + goto yyerrlab1; + + +/*-------------------------------------------------------------. +| yyerrlab1 -- common code for both syntax error and YYERROR. | +`-------------------------------------------------------------*/ +yyerrlab1: + yyerrstatus = 3; /* Each real token shifted decrements this. */ + + for (;;) + { + yyn = yypact[yystate]; + if (yyn != YYPACT_NINF) + { + yyn += YYTERROR; + if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR) + { + yyn = yytable[yyn]; + if (0 < yyn) + break; + } + } + + /* Pop the current state because it cannot handle the error token. */ + if (yyssp == yyss) + YYABORT; + + + yydestruct ("Error: popping", + yystos[yystate], yyvsp); + YYPOPSTACK (1); + yystate = *yyssp; + YY_STACK_PRINT (yyss, yyssp); + } + + *++yyvsp = yylval; + + + /* Shift the error token. */ + YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp); + + yystate = yyn; + goto yynewstate; + + +/*-------------------------------------. +| yyacceptlab -- YYACCEPT comes here. | +`-------------------------------------*/ +yyacceptlab: + yyresult = 0; + goto yyreturn; + +/*-----------------------------------. +| yyabortlab -- YYABORT comes here. | +`-----------------------------------*/ +yyabortlab: + yyresult = 1; + goto yyreturn; + +#if !defined(yyoverflow) || YYERROR_VERBOSE +/*-------------------------------------------------. +| yyexhaustedlab -- memory exhaustion comes here. | +`-------------------------------------------------*/ +yyexhaustedlab: + yyerror (YY_("memory exhausted")); + yyresult = 2; + /* Fall through. */ +#endif + +yyreturn: + if (yychar != YYEMPTY) + yydestruct ("Cleanup: discarding lookahead", + yytoken, &yylval); + /* Do not reclaim the symbols of the rule which action triggered + this YYABORT or YYACCEPT. */ + YYPOPSTACK (yylen); + YY_STACK_PRINT (yyss, yyssp); + while (yyssp != yyss) + { + yydestruct ("Cleanup: popping", + yystos[*yyssp], yyvsp); + YYPOPSTACK (1); + } +#ifndef yyoverflow + if (yyss != yyssa) + YYSTACK_FREE (yyss); +#endif +#if YYERROR_VERBOSE + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); +#endif + /* Make sure YYID is used. */ + return YYID (yyresult); +} + + + +/* Line 1675 of yacc.c */ +#line 155 "segparse.y" + + + +static float +seg_atof(char *value) +{ + Datum datum; + + datum = DirectFunctionCall1(float4in, CStringGetDatum(value)); + return DatumGetFloat4(datum); +} + + +#include "segscan.c" + diff --git a/contrib/seg/segscan.c b/contrib/seg/segscan.c new file mode 100644 index 000000000..affc67ea2 --- /dev/null +++ b/contrib/seg/segscan.c @@ -0,0 +1,1855 @@ +#line 2 "segscan.c" + +#line 4 "segscan.c" + +#define YY_INT_ALIGNED short int + +/* A lexical scanner generated by flex */ + +#define yy_create_buffer seg_yy_create_buffer +#define yy_delete_buffer seg_yy_delete_buffer +#define yy_flex_debug seg_yy_flex_debug +#define yy_init_buffer seg_yy_init_buffer +#define yy_flush_buffer seg_yy_flush_buffer +#define yy_load_buffer_state seg_yy_load_buffer_state +#define yy_switch_to_buffer seg_yy_switch_to_buffer +#define yyin seg_yyin +#define yyleng seg_yyleng +#define yylex seg_yylex +#define yylineno seg_yylineno +#define yyout seg_yyout +#define yyrestart seg_yyrestart +#define yytext seg_yytext +#define yywrap seg_yywrap +#define yyalloc seg_yyalloc +#define yyrealloc seg_yyrealloc +#define yyfree seg_yyfree + +#define FLEX_SCANNER +#define YY_FLEX_MAJOR_VERSION 2 +#define YY_FLEX_MINOR_VERSION 5 +#define YY_FLEX_SUBMINOR_VERSION 35 +#if YY_FLEX_SUBMINOR_VERSION > 0 +#define FLEX_BETA +#endif + +/* First, we deal with platform-specific or compiler-specific issues. */ + +/* begin standard C headers. */ +#include +#include +#include +#include + +/* end standard C headers. */ + +/* flex integer type definitions */ + +#ifndef FLEXINT_H +#define FLEXINT_H + +/* C99 systems have . Non-C99 systems may or may not. */ + +#if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L + +/* C99 says to define __STDC_LIMIT_MACROS before including stdint.h, + * if you want the limit (max/min) macros for int types. + */ +#ifndef __STDC_LIMIT_MACROS +#define __STDC_LIMIT_MACROS 1 +#endif + +#include +typedef int8_t flex_int8_t; +typedef uint8_t flex_uint8_t; +typedef int16_t flex_int16_t; +typedef uint16_t flex_uint16_t; +typedef int32_t flex_int32_t; +typedef uint32_t flex_uint32_t; +#else +typedef signed char flex_int8_t; +typedef short int flex_int16_t; +typedef int flex_int32_t; +typedef unsigned char flex_uint8_t; +typedef unsigned short int flex_uint16_t; +typedef unsigned int flex_uint32_t; + +/* Limits of integral types. */ +#ifndef INT8_MIN +#define INT8_MIN (-128) +#endif +#ifndef INT16_MIN +#define INT16_MIN (-32767-1) +#endif +#ifndef INT32_MIN +#define INT32_MIN (-2147483647-1) +#endif +#ifndef INT8_MAX +#define INT8_MAX (127) +#endif +#ifndef INT16_MAX +#define INT16_MAX (32767) +#endif +#ifndef INT32_MAX +#define INT32_MAX (2147483647) +#endif +#ifndef UINT8_MAX +#define UINT8_MAX (255U) +#endif +#ifndef UINT16_MAX +#define UINT16_MAX (65535U) +#endif +#ifndef UINT32_MAX +#define UINT32_MAX (4294967295U) +#endif + +#endif /* ! C99 */ + +#endif /* ! FLEXINT_H */ + +#ifdef __cplusplus + +/* The "const" storage-class-modifier is valid. */ +#define YY_USE_CONST + +#else /* ! __cplusplus */ + +/* C99 requires __STDC__ to be defined as 1. */ +#if defined (__STDC__) + +#define YY_USE_CONST + +#endif /* defined (__STDC__) */ +#endif /* ! __cplusplus */ + +#ifdef YY_USE_CONST +#define yyconst const +#else +#define yyconst +#endif + +/* Returned upon end-of-file. */ +#define YY_NULL 0 + +/* Promotes a possibly negative, possibly signed char to an unsigned + * integer for use as an array index. If the signed char is negative, + * we want to instead treat it as an 8-bit unsigned char, hence the + * double cast. + */ +#define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c) + +/* Enter a start condition. This macro really ought to take a parameter, + * but we do it the disgusting crufty way forced on us by the ()-less + * definition of BEGIN. + */ +#define BEGIN (yy_start) = 1 + 2 * + +/* Translate the current start state into a value that can be later handed + * to BEGIN to return to the state. The YYSTATE alias is for lex + * compatibility. + */ +#define YY_START (((yy_start) - 1) / 2) +#define YYSTATE YY_START + +/* Action number for EOF rule of a given start state. */ +#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1) + +/* Special action meaning "start processing a new file". */ +#define YY_NEW_FILE seg_yyrestart(seg_yyin ) + +#define YY_END_OF_BUFFER_CHAR 0 + +/* Size of default input buffer. */ +#ifndef YY_BUF_SIZE +#ifdef __ia64__ +/* On IA-64, the buffer size is 16k, not 8k. + * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case. + * Ditto for the __ia64__ case accordingly. + */ +#define YY_BUF_SIZE 32768 +#else +#define YY_BUF_SIZE 16384 +#endif /* __ia64__ */ +#endif + +/* The state buf must be large enough to hold one state per character in the main buffer. + */ +#define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type)) + +#ifndef YY_TYPEDEF_YY_BUFFER_STATE +#define YY_TYPEDEF_YY_BUFFER_STATE +typedef struct yy_buffer_state *YY_BUFFER_STATE; +#endif + +extern int seg_yyleng; + +extern FILE *seg_yyin, *seg_yyout; + +#define EOB_ACT_CONTINUE_SCAN 0 +#define EOB_ACT_END_OF_FILE 1 +#define EOB_ACT_LAST_MATCH 2 + + #define YY_LESS_LINENO(n) + +/* Return all but the first "n" matched characters back to the input stream. */ +#define yyless(n) \ + do \ + { \ + /* Undo effects of setting up seg_yytext. */ \ + int yyless_macro_arg = (n); \ + YY_LESS_LINENO(yyless_macro_arg);\ + *yy_cp = (yy_hold_char); \ + YY_RESTORE_YY_MORE_OFFSET \ + (yy_c_buf_p) = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \ + YY_DO_BEFORE_ACTION; /* set up seg_yytext again */ \ + } \ + while ( 0 ) + +#define unput(c) yyunput( c, (yytext_ptr) ) + +#ifndef YY_TYPEDEF_YY_SIZE_T +#define YY_TYPEDEF_YY_SIZE_T +typedef size_t yy_size_t; +#endif + +#ifndef YY_STRUCT_YY_BUFFER_STATE +#define YY_STRUCT_YY_BUFFER_STATE +struct yy_buffer_state + { + FILE *yy_input_file; + + char *yy_ch_buf; /* input buffer */ + char *yy_buf_pos; /* current position in input buffer */ + + /* Size of input buffer in bytes, not including room for EOB + * characters. + */ + yy_size_t yy_buf_size; + + /* Number of characters read into yy_ch_buf, not including EOB + * characters. + */ + int yy_n_chars; + + /* Whether we "own" the buffer - i.e., we know we created it, + * and can realloc() it to grow it, and should free() it to + * delete it. + */ + int yy_is_our_buffer; + + /* Whether this is an "interactive" input source; if so, and + * if we're using stdio for input, then we want to use getc() + * instead of fread(), to make sure we stop fetching input after + * each newline. + */ + int yy_is_interactive; + + /* Whether we're considered to be at the beginning of a line. + * If so, '^' rules will be active on the next match, otherwise + * not. + */ + int yy_at_bol; + + int yy_bs_lineno; /**< The line count. */ + int yy_bs_column; /**< The column count. */ + + /* Whether to try to fill the input buffer when we reach the + * end of it. + */ + int yy_fill_buffer; + + int yy_buffer_status; + +#define YY_BUFFER_NEW 0 +#define YY_BUFFER_NORMAL 1 + /* When an EOF's been seen but there's still some text to process + * then we mark the buffer as YY_EOF_PENDING, to indicate that we + * shouldn't try reading from the input source any more. We might + * still have a bunch of tokens to match, though, because of + * possible backing-up. + * + * When we actually see the EOF, we change the status to "new" + * (via seg_yyrestart()), so that the user can continue scanning by + * just pointing seg_yyin at a new input file. + */ +#define YY_BUFFER_EOF_PENDING 2 + + }; +#endif /* !YY_STRUCT_YY_BUFFER_STATE */ + +/* Stack of input buffers. */ +static size_t yy_buffer_stack_top = 0; /**< index of top of stack. */ +static size_t yy_buffer_stack_max = 0; /**< capacity of stack. */ +static YY_BUFFER_STATE * yy_buffer_stack = 0; /**< Stack as an array. */ + +/* We provide macros for accessing buffer states in case in the + * future we want to put the buffer states in a more general + * "scanner state". + * + * Returns the top of the stack, or NULL. + */ +#define YY_CURRENT_BUFFER ( (yy_buffer_stack) \ + ? (yy_buffer_stack)[(yy_buffer_stack_top)] \ + : NULL) + +/* Same as previous macro, but useful when we know that the buffer stack is not + * NULL or when we need an lvalue. For internal use only. + */ +#define YY_CURRENT_BUFFER_LVALUE (yy_buffer_stack)[(yy_buffer_stack_top)] + +/* yy_hold_char holds the character lost when seg_yytext is formed. */ +static char yy_hold_char; +static int yy_n_chars; /* number of characters read into yy_ch_buf */ +int seg_yyleng; + +/* Points to current character in buffer. */ +static char *yy_c_buf_p = (char *) 0; +static int yy_init = 0; /* whether we need to initialize */ +static int yy_start = 0; /* start state number */ + +/* Flag which is used to allow seg_yywrap()'s to do buffer switches + * instead of setting up a fresh seg_yyin. A bit of a hack ... + */ +static int yy_did_buffer_switch_on_eof; + +void seg_yyrestart (FILE *input_file ); +void seg_yy_switch_to_buffer (YY_BUFFER_STATE new_buffer ); +YY_BUFFER_STATE seg_yy_create_buffer (FILE *file,int size ); +void seg_yy_delete_buffer (YY_BUFFER_STATE b ); +void seg_yy_flush_buffer (YY_BUFFER_STATE b ); +void seg_yypush_buffer_state (YY_BUFFER_STATE new_buffer ); +void seg_yypop_buffer_state (void ); + +static void seg_yyensure_buffer_stack (void ); +static void seg_yy_load_buffer_state (void ); +static void seg_yy_init_buffer (YY_BUFFER_STATE b,FILE *file ); + +#define YY_FLUSH_BUFFER seg_yy_flush_buffer(YY_CURRENT_BUFFER ) + +YY_BUFFER_STATE seg_yy_scan_buffer (char *base,yy_size_t size ); +YY_BUFFER_STATE seg_yy_scan_string (yyconst char *yy_str ); +YY_BUFFER_STATE seg_yy_scan_bytes (yyconst char *bytes,int len ); + +void *seg_yyalloc (yy_size_t ); +void *seg_yyrealloc (void *,yy_size_t ); +void seg_yyfree (void * ); + +#define yy_new_buffer seg_yy_create_buffer + +#define yy_set_interactive(is_interactive) \ + { \ + if ( ! YY_CURRENT_BUFFER ){ \ + seg_yyensure_buffer_stack (); \ + YY_CURRENT_BUFFER_LVALUE = \ + seg_yy_create_buffer(seg_yyin,YY_BUF_SIZE ); \ + } \ + YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \ + } + +#define yy_set_bol(at_bol) \ + { \ + if ( ! YY_CURRENT_BUFFER ){\ + seg_yyensure_buffer_stack (); \ + YY_CURRENT_BUFFER_LVALUE = \ + seg_yy_create_buffer(seg_yyin,YY_BUF_SIZE ); \ + } \ + YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \ + } + +#define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol) + +/* Begin user sect3 */ + +#define seg_yywrap(n) 1 +#define YY_SKIP_YYWRAP + +typedef unsigned char YY_CHAR; + +FILE *seg_yyin = (FILE *) 0, *seg_yyout = (FILE *) 0; + +typedef int yy_state_type; + +extern int seg_yylineno; + +int seg_yylineno = 1; + +extern char *seg_yytext; +#define yytext_ptr seg_yytext + +static yy_state_type yy_get_previous_state (void ); +static yy_state_type yy_try_NUL_trans (yy_state_type current_state ); +static int yy_get_next_buffer (void ); +static void yy_fatal_error (yyconst char msg[] ); + +/* Done after the current pattern has been matched and before the + * corresponding action - sets up seg_yytext. + */ +#define YY_DO_BEFORE_ACTION \ + (yytext_ptr) = yy_bp; \ + seg_yyleng = (size_t) (yy_cp - yy_bp); \ + (yy_hold_char) = *yy_cp; \ + *yy_cp = '\0'; \ + (yy_c_buf_p) = yy_cp; + +#define YY_NUM_RULES 9 +#define YY_END_OF_BUFFER 10 +/* This struct is not used in this scanner, + but its presence is necessary. */ +struct yy_trans_info + { + flex_int32_t yy_verify; + flex_int32_t yy_nxt; + }; +static yyconst flex_int16_t yy_accept[30] = + { 0, + 0, 0, 10, 8, 7, 7, 8, 8, 8, 8, + 3, 4, 5, 6, 7, 0, 0, 3, 1, 0, + 0, 0, 0, 1, 3, 0, 3, 2, 0 + } ; + +static yyconst flex_int32_t yy_ec[256] = + { 0, + 1, 1, 1, 1, 1, 1, 1, 1, 2, 3, + 1, 2, 2, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 2, 1, 1, 1, 1, 1, 1, 4, 5, + 6, 1, 7, 1, 8, 9, 1, 10, 10, 10, + 10, 10, 10, 10, 10, 10, 10, 1, 1, 11, + 1, 12, 1, 1, 1, 1, 1, 1, 13, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + + 13, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 14, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1 + } ; + +static yyconst flex_int32_t yy_meta[15] = + { 0, + 1, 1, 1, 1, 1, 1, 2, 2, 1, 2, + 1, 1, 1, 1 + } ; + +static yyconst flex_int16_t yy_base[31] = + { 0, + 0, 0, 40, 41, 13, 15, 32, 31, 27, 27, + 10, 41, 41, 41, 19, 27, 26, 0, 24, 22, + 21, 26, 23, 41, 14, 18, 16, 41, 41, 23 + } ; + +static yyconst flex_int16_t yy_def[31] = + { 0, + 29, 1, 29, 29, 29, 29, 29, 29, 29, 29, + 29, 29, 29, 29, 29, 29, 29, 11, 29, 29, + 30, 29, 29, 29, 29, 29, 29, 29, 0, 29 + } ; + +static yyconst flex_int16_t yy_nxt[56] = + { 0, + 4, 5, 6, 7, 8, 4, 9, 9, 10, 11, + 12, 13, 4, 14, 15, 15, 15, 15, 20, 18, + 15, 15, 21, 25, 26, 27, 21, 27, 28, 28, + 27, 25, 24, 23, 22, 19, 18, 17, 16, 29, + 3, 29, 29, 29, 29, 29, 29, 29, 29, 29, + 29, 29, 29, 29, 29 + } ; + +static yyconst flex_int16_t yy_chk[56] = + { 0, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 5, 5, 6, 6, 11, 11, + 15, 15, 11, 25, 30, 27, 25, 26, 23, 22, + 21, 20, 19, 17, 16, 10, 9, 8, 7, 3, + 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, + 29, 29, 29, 29, 29 + } ; + +static yy_state_type yy_last_accepting_state; +static char *yy_last_accepting_cpos; + +extern int seg_yy_flex_debug; +int seg_yy_flex_debug = 0; + +/* The intent behind this definition is that it'll catch + * any uses of REJECT which flex missed. + */ +#define REJECT reject_used_but_not_detected +#define yymore() yymore_used_but_not_detected +#define YY_MORE_ADJ 0 +#define YY_RESTORE_YY_MORE_OFFSET +char *seg_yytext; +#line 1 "segscan.l" +#line 2 "segscan.l" +/* + * A scanner for EMP-style numeric ranges + */ + +#include "postgres.h" + +/* No reason to constrain amount of data slurped */ +#define YY_READ_BUF_SIZE 16777216 + +/* Avoid exit() on fatal scanner errors (a bit ugly -- see yy_fatal_error) */ +#undef fprintf +#define fprintf(file, fmt, msg) ereport(ERROR, (errmsg_internal("%s", msg))) + +/* Handles to the buffer that the lexer uses internally */ +static YY_BUFFER_STATE scanbufhandle; +static char *scanbuf; +static int scanbuflen; + +/* flex 2.5.4 doesn't bother with a decl for this */ +int seg_yylex(void); + +void seg_scanner_init(const char *str); +void seg_scanner_finish(void); +#define YY_NO_INPUT 1 +#line 523 "segscan.c" + +#define INITIAL 0 + +#ifndef YY_NO_UNISTD_H +/* Special case for "unistd.h", since it is non-ANSI. We include it way + * down here because we want the user's section 1 to have been scanned first. + * The user has a chance to override it with an option. + */ +#include +#endif + +#ifndef YY_EXTRA_TYPE +#define YY_EXTRA_TYPE void * +#endif + +static int yy_init_globals (void ); + +/* Accessor methods to globals. + These are made visible to non-reentrant scanners for convenience. */ + +int seg_yylex_destroy (void ); + +int seg_yyget_debug (void ); + +void seg_yyset_debug (int debug_flag ); + +YY_EXTRA_TYPE seg_yyget_extra (void ); + +void seg_yyset_extra (YY_EXTRA_TYPE user_defined ); + +FILE *seg_yyget_in (void ); + +void seg_yyset_in (FILE * in_str ); + +FILE *seg_yyget_out (void ); + +void seg_yyset_out (FILE * out_str ); + +int seg_yyget_leng (void ); + +char *seg_yyget_text (void ); + +int seg_yyget_lineno (void ); + +void seg_yyset_lineno (int line_number ); + +/* Macros after this point can all be overridden by user definitions in + * section 1. + */ + +#ifndef YY_SKIP_YYWRAP +#ifdef __cplusplus +extern "C" int seg_yywrap (void ); +#else +extern int seg_yywrap (void ); +#endif +#endif + +#ifndef yytext_ptr +static void yy_flex_strncpy (char *,yyconst char *,int ); +#endif + +#ifdef YY_NEED_STRLEN +static int yy_flex_strlen (yyconst char * ); +#endif + +#ifndef YY_NO_INPUT + +#ifdef __cplusplus +static int yyinput (void ); +#else +static int input (void ); +#endif + +#endif + +/* Amount of stuff to slurp up with each read. */ +#ifndef YY_READ_BUF_SIZE +#ifdef __ia64__ +/* On IA-64, the buffer size is 16k, not 8k */ +#define YY_READ_BUF_SIZE 16384 +#else +#define YY_READ_BUF_SIZE 8192 +#endif /* __ia64__ */ +#endif + +/* Copy whatever the last rule matched to the standard output. */ +#ifndef ECHO +/* This used to be an fputs(), but since the string might contain NUL's, + * we now use fwrite(). + */ +#define ECHO do { if (fwrite( seg_yytext, seg_yyleng, 1, seg_yyout )) {} } while (0) +#endif + +/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL, + * is returned in "result". + */ +#ifndef YY_INPUT +#define YY_INPUT(buf,result,max_size) \ + if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \ + { \ + int c = '*'; \ + size_t n; \ + for ( n = 0; n < max_size && \ + (c = getc( seg_yyin )) != EOF && c != '\n'; ++n ) \ + buf[n] = (char) c; \ + if ( c == '\n' ) \ + buf[n++] = (char) c; \ + if ( c == EOF && ferror( seg_yyin ) ) \ + YY_FATAL_ERROR( "input in flex scanner failed" ); \ + result = n; \ + } \ + else \ + { \ + errno=0; \ + while ( (result = fread(buf, 1, max_size, seg_yyin))==0 && ferror(seg_yyin)) \ + { \ + if( errno != EINTR) \ + { \ + YY_FATAL_ERROR( "input in flex scanner failed" ); \ + break; \ + } \ + errno=0; \ + clearerr(seg_yyin); \ + } \ + }\ +\ + +#endif + +/* No semi-colon after return; correct usage is to write "yyterminate();" - + * we don't want an extra ';' after the "return" because that will cause + * some compilers to complain about unreachable statements. + */ +#ifndef yyterminate +#define yyterminate() return YY_NULL +#endif + +/* Number of entries by which start-condition stack grows. */ +#ifndef YY_START_STACK_INCR +#define YY_START_STACK_INCR 25 +#endif + +/* Report a fatal error. */ +#ifndef YY_FATAL_ERROR +#define YY_FATAL_ERROR(msg) yy_fatal_error( msg ) +#endif + +/* end tables serialization structures and prototypes */ + +/* Default declaration of generated scanner - a define so the user can + * easily add parameters. + */ +#ifndef YY_DECL +#define YY_DECL_IS_OURS 1 + +extern int seg_yylex (void); + +#define YY_DECL int seg_yylex (void) +#endif /* !YY_DECL */ + +/* Code executed at the beginning of each rule, after seg_yytext and seg_yyleng + * have been set up. + */ +#ifndef YY_USER_ACTION +#define YY_USER_ACTION +#endif + +/* Code executed at the end of each rule. */ +#ifndef YY_BREAK +#define YY_BREAK break; +#endif + +#define YY_RULE_SETUP \ + YY_USER_ACTION + +/** The main scanner function which does all the work. + */ +YY_DECL +{ + register yy_state_type yy_current_state; + register char *yy_cp, *yy_bp; + register int yy_act; + +#line 43 "segscan.l" + + +#line 711 "segscan.c" + + if ( !(yy_init) ) + { + (yy_init) = 1; + +#ifdef YY_USER_INIT + YY_USER_INIT; +#endif + + if ( ! (yy_start) ) + (yy_start) = 1; /* first start state */ + + if ( ! seg_yyin ) + seg_yyin = stdin; + + if ( ! seg_yyout ) + seg_yyout = stdout; + + if ( ! YY_CURRENT_BUFFER ) { + seg_yyensure_buffer_stack (); + YY_CURRENT_BUFFER_LVALUE = + seg_yy_create_buffer(seg_yyin,YY_BUF_SIZE ); + } + + seg_yy_load_buffer_state( ); + } + + while ( 1 ) /* loops until end-of-file is reached */ + { + yy_cp = (yy_c_buf_p); + + /* Support of seg_yytext. */ + *yy_cp = (yy_hold_char); + + /* yy_bp points to the position in yy_ch_buf of the start of + * the current run. + */ + yy_bp = yy_cp; + + yy_current_state = (yy_start); +yy_match: + do + { + register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)]; + if ( yy_accept[yy_current_state] ) + { + (yy_last_accepting_state) = yy_current_state; + (yy_last_accepting_cpos) = yy_cp; + } + while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) + { + yy_current_state = (int) yy_def[yy_current_state]; + if ( yy_current_state >= 30 ) + yy_c = yy_meta[(unsigned int) yy_c]; + } + yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; + ++yy_cp; + } + while ( yy_current_state != 29 ); + yy_cp = (yy_last_accepting_cpos); + yy_current_state = (yy_last_accepting_state); + +yy_find_action: + yy_act = yy_accept[yy_current_state]; + + YY_DO_BEFORE_ACTION; + +do_action: /* This label is used only to access EOF actions. */ + + switch ( yy_act ) + { /* beginning of action switch */ + case 0: /* must back up */ + /* undo the effects of YY_DO_BEFORE_ACTION */ + *yy_cp = (yy_hold_char); + yy_cp = (yy_last_accepting_cpos); + yy_current_state = (yy_last_accepting_state); + goto yy_find_action; + +case 1: +YY_RULE_SETUP +#line 45 "segscan.l" +yylval.text = seg_yytext; return RANGE; + YY_BREAK +case 2: +YY_RULE_SETUP +#line 46 "segscan.l" +yylval.text = seg_yytext; return PLUMIN; + YY_BREAK +case 3: +YY_RULE_SETUP +#line 47 "segscan.l" +yylval.text = seg_yytext; return SEGFLOAT; + YY_BREAK +case 4: +YY_RULE_SETUP +#line 48 "segscan.l" +yylval.text = "<"; return EXTENSION; + YY_BREAK +case 5: +YY_RULE_SETUP +#line 49 "segscan.l" +yylval.text = ">"; return EXTENSION; + YY_BREAK +case 6: +YY_RULE_SETUP +#line 50 "segscan.l" +yylval.text = "~"; return EXTENSION; + YY_BREAK +case 7: +/* rule 7 can match eol */ +YY_RULE_SETUP +#line 51 "segscan.l" +/* discard spaces */ + YY_BREAK +case 8: +YY_RULE_SETUP +#line 52 "segscan.l" +return seg_yytext[0]; /* alert parser of the garbage */ + YY_BREAK +case 9: +YY_RULE_SETUP +#line 54 "segscan.l" +YY_FATAL_ERROR( "flex scanner jammed" ); + YY_BREAK +#line 836 "segscan.c" +case YY_STATE_EOF(INITIAL): + yyterminate(); + + case YY_END_OF_BUFFER: + { + /* Amount of text matched not including the EOB char. */ + int yy_amount_of_matched_text = (int) (yy_cp - (yytext_ptr)) - 1; + + /* Undo the effects of YY_DO_BEFORE_ACTION. */ + *yy_cp = (yy_hold_char); + YY_RESTORE_YY_MORE_OFFSET + + if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW ) + { + /* We're scanning a new file or input source. It's + * possible that this happened because the user + * just pointed seg_yyin at a new source and called + * seg_yylex(). If so, then we have to assure + * consistency between YY_CURRENT_BUFFER and our + * globals. Here is the right place to do so, because + * this is the first action (other than possibly a + * back-up) that will match for the new input source. + */ + (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars; + YY_CURRENT_BUFFER_LVALUE->yy_input_file = seg_yyin; + YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL; + } + + /* Note that here we test for yy_c_buf_p "<=" to the position + * of the first EOB in the buffer, since yy_c_buf_p will + * already have been incremented past the NUL character + * (since all states make transitions on EOB to the + * end-of-buffer state). Contrast this with the test + * in input(). + */ + if ( (yy_c_buf_p) <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] ) + { /* This was really a NUL. */ + yy_state_type yy_next_state; + + (yy_c_buf_p) = (yytext_ptr) + yy_amount_of_matched_text; + + yy_current_state = yy_get_previous_state( ); + + /* Okay, we're now positioned to make the NUL + * transition. We couldn't have + * yy_get_previous_state() go ahead and do it + * for us because it doesn't know how to deal + * with the possibility of jamming (and we don't + * want to build jamming into it because then it + * will run more slowly). + */ + + yy_next_state = yy_try_NUL_trans( yy_current_state ); + + yy_bp = (yytext_ptr) + YY_MORE_ADJ; + + if ( yy_next_state ) + { + /* Consume the NUL. */ + yy_cp = ++(yy_c_buf_p); + yy_current_state = yy_next_state; + goto yy_match; + } + + else + { + yy_cp = (yy_last_accepting_cpos); + yy_current_state = (yy_last_accepting_state); + goto yy_find_action; + } + } + + else switch ( yy_get_next_buffer( ) ) + { + case EOB_ACT_END_OF_FILE: + { + (yy_did_buffer_switch_on_eof) = 0; + + if ( seg_yywrap( ) ) + { + /* Note: because we've taken care in + * yy_get_next_buffer() to have set up + * seg_yytext, we can now set up + * yy_c_buf_p so that if some total + * hoser (like flex itself) wants to + * call the scanner after we return the + * YY_NULL, it'll still work - another + * YY_NULL will get returned. + */ + (yy_c_buf_p) = (yytext_ptr) + YY_MORE_ADJ; + + yy_act = YY_STATE_EOF(YY_START); + goto do_action; + } + + else + { + if ( ! (yy_did_buffer_switch_on_eof) ) + YY_NEW_FILE; + } + break; + } + + case EOB_ACT_CONTINUE_SCAN: + (yy_c_buf_p) = + (yytext_ptr) + yy_amount_of_matched_text; + + yy_current_state = yy_get_previous_state( ); + + yy_cp = (yy_c_buf_p); + yy_bp = (yytext_ptr) + YY_MORE_ADJ; + goto yy_match; + + case EOB_ACT_LAST_MATCH: + (yy_c_buf_p) = + &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)]; + + yy_current_state = yy_get_previous_state( ); + + yy_cp = (yy_c_buf_p); + yy_bp = (yytext_ptr) + YY_MORE_ADJ; + goto yy_find_action; + } + break; + } + + default: + YY_FATAL_ERROR( + "fatal flex scanner internal error--no action found" ); + } /* end of action switch */ + } /* end of scanning one token */ +} /* end of seg_yylex */ + +/* yy_get_next_buffer - try to read in a new buffer + * + * Returns a code representing an action: + * EOB_ACT_LAST_MATCH - + * EOB_ACT_CONTINUE_SCAN - continue scanning from current position + * EOB_ACT_END_OF_FILE - end of file + */ +static int yy_get_next_buffer (void) +{ + register char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf; + register char *source = (yytext_ptr); + register int number_to_move, i; + int ret_val; + + if ( (yy_c_buf_p) > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] ) + YY_FATAL_ERROR( + "fatal flex scanner internal error--end of buffer missed" ); + + if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 ) + { /* Don't try to fill the buffer, so this is an EOF. */ + if ( (yy_c_buf_p) - (yytext_ptr) - YY_MORE_ADJ == 1 ) + { + /* We matched a single character, the EOB, so + * treat this as a final EOF. + */ + return EOB_ACT_END_OF_FILE; + } + + else + { + /* We matched some text prior to the EOB, first + * process it. + */ + return EOB_ACT_LAST_MATCH; + } + } + + /* Try to read more data. */ + + /* First move last chars to start of buffer. */ + number_to_move = (int) ((yy_c_buf_p) - (yytext_ptr)) - 1; + + for ( i = 0; i < number_to_move; ++i ) + *(dest++) = *(source++); + + if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING ) + /* don't do the read, it's not guaranteed to return an EOF, + * just force an EOF + */ + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars) = 0; + + else + { + int num_to_read = + YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1; + + while ( num_to_read <= 0 ) + { /* Not enough room in the buffer - grow it. */ + + /* just a shorter name for the current buffer */ + YY_BUFFER_STATE b = YY_CURRENT_BUFFER; + + int yy_c_buf_p_offset = + (int) ((yy_c_buf_p) - b->yy_ch_buf); + + if ( b->yy_is_our_buffer ) + { + int new_size = b->yy_buf_size * 2; + + if ( new_size <= 0 ) + b->yy_buf_size += b->yy_buf_size / 8; + else + b->yy_buf_size *= 2; + + b->yy_ch_buf = (char *) + /* Include room in for 2 EOB chars. */ + seg_yyrealloc((void *) b->yy_ch_buf,b->yy_buf_size + 2 ); + } + else + /* Can't grow it, we don't own it. */ + b->yy_ch_buf = 0; + + if ( ! b->yy_ch_buf ) + YY_FATAL_ERROR( + "fatal error - scanner input buffer overflow" ); + + (yy_c_buf_p) = &b->yy_ch_buf[yy_c_buf_p_offset]; + + num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size - + number_to_move - 1; + + } + + if ( num_to_read > YY_READ_BUF_SIZE ) + num_to_read = YY_READ_BUF_SIZE; + + /* Read in more data. */ + YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]), + (yy_n_chars), (size_t) num_to_read ); + + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); + } + + if ( (yy_n_chars) == 0 ) + { + if ( number_to_move == YY_MORE_ADJ ) + { + ret_val = EOB_ACT_END_OF_FILE; + seg_yyrestart(seg_yyin ); + } + + else + { + ret_val = EOB_ACT_LAST_MATCH; + YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = + YY_BUFFER_EOF_PENDING; + } + } + + else + ret_val = EOB_ACT_CONTINUE_SCAN; + + if ((yy_size_t) ((yy_n_chars) + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) { + /* Extend the array by 50%, plus the number we really need. */ + yy_size_t new_size = (yy_n_chars) + number_to_move + ((yy_n_chars) >> 1); + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) seg_yyrealloc((void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,new_size ); + if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf ) + YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" ); + } + + (yy_n_chars) += number_to_move; + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] = YY_END_OF_BUFFER_CHAR; + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] = YY_END_OF_BUFFER_CHAR; + + (yytext_ptr) = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0]; + + return ret_val; +} + +/* yy_get_previous_state - get the state just before the EOB char was reached */ + + static yy_state_type yy_get_previous_state (void) +{ + register yy_state_type yy_current_state; + register char *yy_cp; + + yy_current_state = (yy_start); + + for ( yy_cp = (yytext_ptr) + YY_MORE_ADJ; yy_cp < (yy_c_buf_p); ++yy_cp ) + { + register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1); + if ( yy_accept[yy_current_state] ) + { + (yy_last_accepting_state) = yy_current_state; + (yy_last_accepting_cpos) = yy_cp; + } + while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) + { + yy_current_state = (int) yy_def[yy_current_state]; + if ( yy_current_state >= 30 ) + yy_c = yy_meta[(unsigned int) yy_c]; + } + yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; + } + + return yy_current_state; +} + +/* yy_try_NUL_trans - try to make a transition on the NUL character + * + * synopsis + * next_state = yy_try_NUL_trans( current_state ); + */ + static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state ) +{ + register int yy_is_jam; + register char *yy_cp = (yy_c_buf_p); + + register YY_CHAR yy_c = 1; + if ( yy_accept[yy_current_state] ) + { + (yy_last_accepting_state) = yy_current_state; + (yy_last_accepting_cpos) = yy_cp; + } + while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) + { + yy_current_state = (int) yy_def[yy_current_state]; + if ( yy_current_state >= 30 ) + yy_c = yy_meta[(unsigned int) yy_c]; + } + yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; + yy_is_jam = (yy_current_state == 29); + + return yy_is_jam ? 0 : yy_current_state; +} + +#ifndef YY_NO_INPUT +#ifdef __cplusplus + static int yyinput (void) +#else + static int input (void) +#endif + +{ + int c; + + *(yy_c_buf_p) = (yy_hold_char); + + if ( *(yy_c_buf_p) == YY_END_OF_BUFFER_CHAR ) + { + /* yy_c_buf_p now points to the character we want to return. + * If this occurs *before* the EOB characters, then it's a + * valid NUL; if not, then we've hit the end of the buffer. + */ + if ( (yy_c_buf_p) < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] ) + /* This was really a NUL. */ + *(yy_c_buf_p) = '\0'; + + else + { /* need more input */ + int offset = (yy_c_buf_p) - (yytext_ptr); + ++(yy_c_buf_p); + + switch ( yy_get_next_buffer( ) ) + { + case EOB_ACT_LAST_MATCH: + /* This happens because yy_g_n_b() + * sees that we've accumulated a + * token and flags that we need to + * try matching the token before + * proceeding. But for input(), + * there's no matching to consider. + * So convert the EOB_ACT_LAST_MATCH + * to EOB_ACT_END_OF_FILE. + */ + + /* Reset buffer status. */ + seg_yyrestart(seg_yyin ); + + /*FALLTHROUGH*/ + + case EOB_ACT_END_OF_FILE: + { + if ( seg_yywrap( ) ) + return EOF; + + if ( ! (yy_did_buffer_switch_on_eof) ) + YY_NEW_FILE; +#ifdef __cplusplus + return yyinput(); +#else + return input(); +#endif + } + + case EOB_ACT_CONTINUE_SCAN: + (yy_c_buf_p) = (yytext_ptr) + offset; + break; + } + } + } + + c = *(unsigned char *) (yy_c_buf_p); /* cast for 8-bit char's */ + *(yy_c_buf_p) = '\0'; /* preserve seg_yytext */ + (yy_hold_char) = *++(yy_c_buf_p); + + return c; +} +#endif /* ifndef YY_NO_INPUT */ + +/** Immediately switch to a different input stream. + * @param input_file A readable stream. + * + * @note This function does not reset the start condition to @c INITIAL . + */ + void seg_yyrestart (FILE * input_file ) +{ + + if ( ! YY_CURRENT_BUFFER ){ + seg_yyensure_buffer_stack (); + YY_CURRENT_BUFFER_LVALUE = + seg_yy_create_buffer(seg_yyin,YY_BUF_SIZE ); + } + + seg_yy_init_buffer(YY_CURRENT_BUFFER,input_file ); + seg_yy_load_buffer_state( ); +} + +/** Switch to a different input buffer. + * @param new_buffer The new input buffer. + * + */ + void seg_yy_switch_to_buffer (YY_BUFFER_STATE new_buffer ) +{ + + /* TODO. We should be able to replace this entire function body + * with + * seg_yypop_buffer_state(); + * seg_yypush_buffer_state(new_buffer); + */ + seg_yyensure_buffer_stack (); + if ( YY_CURRENT_BUFFER == new_buffer ) + return; + + if ( YY_CURRENT_BUFFER ) + { + /* Flush out information for old buffer. */ + *(yy_c_buf_p) = (yy_hold_char); + YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p); + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); + } + + YY_CURRENT_BUFFER_LVALUE = new_buffer; + seg_yy_load_buffer_state( ); + + /* We don't actually know whether we did this switch during + * EOF (seg_yywrap()) processing, but the only time this flag + * is looked at is after seg_yywrap() is called, so it's safe + * to go ahead and always set it. + */ + (yy_did_buffer_switch_on_eof) = 1; +} + +static void seg_yy_load_buffer_state (void) +{ + (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars; + (yytext_ptr) = (yy_c_buf_p) = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos; + seg_yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file; + (yy_hold_char) = *(yy_c_buf_p); +} + +/** Allocate and initialize an input buffer state. + * @param file A readable stream. + * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE. + * + * @return the allocated buffer state. + */ + YY_BUFFER_STATE seg_yy_create_buffer (FILE * file, int size ) +{ + YY_BUFFER_STATE b; + + b = (YY_BUFFER_STATE) seg_yyalloc(sizeof( struct yy_buffer_state ) ); + if ( ! b ) + YY_FATAL_ERROR( "out of dynamic memory in seg_yy_create_buffer()" ); + + b->yy_buf_size = size; + + /* yy_ch_buf has to be 2 characters longer than the size given because + * we need to put in 2 end-of-buffer characters. + */ + b->yy_ch_buf = (char *) seg_yyalloc(b->yy_buf_size + 2 ); + if ( ! b->yy_ch_buf ) + YY_FATAL_ERROR( "out of dynamic memory in seg_yy_create_buffer()" ); + + b->yy_is_our_buffer = 1; + + seg_yy_init_buffer(b,file ); + + return b; +} + +/** Destroy the buffer. + * @param b a buffer created with seg_yy_create_buffer() + * + */ + void seg_yy_delete_buffer (YY_BUFFER_STATE b ) +{ + + if ( ! b ) + return; + + if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */ + YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0; + + if ( b->yy_is_our_buffer ) + seg_yyfree((void *) b->yy_ch_buf ); + + seg_yyfree((void *) b ); +} + +/* Initializes or reinitializes a buffer. + * This function is sometimes called more than once on the same buffer, + * such as during a seg_yyrestart() or at EOF. + */ + static void seg_yy_init_buffer (YY_BUFFER_STATE b, FILE * file ) + +{ + int oerrno = errno; + + seg_yy_flush_buffer(b ); + + b->yy_input_file = file; + b->yy_fill_buffer = 1; + + /* If b is the current buffer, then seg_yy_init_buffer was _probably_ + * called from seg_yyrestart() or through yy_get_next_buffer. + * In that case, we don't want to reset the lineno or column. + */ + if (b != YY_CURRENT_BUFFER){ + b->yy_bs_lineno = 1; + b->yy_bs_column = 0; + } + + b->yy_is_interactive = 0; + + errno = oerrno; +} + +/** Discard all buffered characters. On the next scan, YY_INPUT will be called. + * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER. + * + */ + void seg_yy_flush_buffer (YY_BUFFER_STATE b ) +{ + if ( ! b ) + return; + + b->yy_n_chars = 0; + + /* We always need two end-of-buffer characters. The first causes + * a transition to the end-of-buffer state. The second causes + * a jam in that state. + */ + b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR; + b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR; + + b->yy_buf_pos = &b->yy_ch_buf[0]; + + b->yy_at_bol = 1; + b->yy_buffer_status = YY_BUFFER_NEW; + + if ( b == YY_CURRENT_BUFFER ) + seg_yy_load_buffer_state( ); +} + +/** Pushes the new state onto the stack. The new state becomes + * the current state. This function will allocate the stack + * if necessary. + * @param new_buffer The new state. + * + */ +void seg_yypush_buffer_state (YY_BUFFER_STATE new_buffer ) +{ + if (new_buffer == NULL) + return; + + seg_yyensure_buffer_stack(); + + /* This block is copied from seg_yy_switch_to_buffer. */ + if ( YY_CURRENT_BUFFER ) + { + /* Flush out information for old buffer. */ + *(yy_c_buf_p) = (yy_hold_char); + YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p); + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); + } + + /* Only push if top exists. Otherwise, replace top. */ + if (YY_CURRENT_BUFFER) + (yy_buffer_stack_top)++; + YY_CURRENT_BUFFER_LVALUE = new_buffer; + + /* copied from seg_yy_switch_to_buffer. */ + seg_yy_load_buffer_state( ); + (yy_did_buffer_switch_on_eof) = 1; +} + +/** Removes and deletes the top of the stack, if present. + * The next element becomes the new top. + * + */ +void seg_yypop_buffer_state (void) +{ + if (!YY_CURRENT_BUFFER) + return; + + seg_yy_delete_buffer(YY_CURRENT_BUFFER ); + YY_CURRENT_BUFFER_LVALUE = NULL; + if ((yy_buffer_stack_top) > 0) + --(yy_buffer_stack_top); + + if (YY_CURRENT_BUFFER) { + seg_yy_load_buffer_state( ); + (yy_did_buffer_switch_on_eof) = 1; + } +} + +/* Allocates the stack if it does not exist. + * Guarantees space for at least one push. + */ +static void seg_yyensure_buffer_stack (void) +{ + int num_to_alloc; + + if (!(yy_buffer_stack)) { + + /* First allocation is just for 2 elements, since we don't know if this + * scanner will even need a stack. We use 2 instead of 1 to avoid an + * immediate realloc on the next call. + */ + num_to_alloc = 1; + (yy_buffer_stack) = (struct yy_buffer_state**)seg_yyalloc + (num_to_alloc * sizeof(struct yy_buffer_state*) + ); + if ( ! (yy_buffer_stack) ) + YY_FATAL_ERROR( "out of dynamic memory in seg_yyensure_buffer_stack()" ); + + memset((yy_buffer_stack), 0, num_to_alloc * sizeof(struct yy_buffer_state*)); + + (yy_buffer_stack_max) = num_to_alloc; + (yy_buffer_stack_top) = 0; + return; + } + + if ((yy_buffer_stack_top) >= ((yy_buffer_stack_max)) - 1){ + + /* Increase the buffer to prepare for a possible push. */ + int grow_size = 8 /* arbitrary grow size */; + + num_to_alloc = (yy_buffer_stack_max) + grow_size; + (yy_buffer_stack) = (struct yy_buffer_state**)seg_yyrealloc + ((yy_buffer_stack), + num_to_alloc * sizeof(struct yy_buffer_state*) + ); + if ( ! (yy_buffer_stack) ) + YY_FATAL_ERROR( "out of dynamic memory in seg_yyensure_buffer_stack()" ); + + /* zero only the new slots.*/ + memset((yy_buffer_stack) + (yy_buffer_stack_max), 0, grow_size * sizeof(struct yy_buffer_state*)); + (yy_buffer_stack_max) = num_to_alloc; + } +} + +/** Setup the input buffer state to scan directly from a user-specified character buffer. + * @param base the character buffer + * @param size the size in bytes of the character buffer + * + * @return the newly allocated buffer state object. + */ +YY_BUFFER_STATE seg_yy_scan_buffer (char * base, yy_size_t size ) +{ + YY_BUFFER_STATE b; + + if ( size < 2 || + base[size-2] != YY_END_OF_BUFFER_CHAR || + base[size-1] != YY_END_OF_BUFFER_CHAR ) + /* They forgot to leave room for the EOB's. */ + return 0; + + b = (YY_BUFFER_STATE) seg_yyalloc(sizeof( struct yy_buffer_state ) ); + if ( ! b ) + YY_FATAL_ERROR( "out of dynamic memory in seg_yy_scan_buffer()" ); + + b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */ + b->yy_buf_pos = b->yy_ch_buf = base; + b->yy_is_our_buffer = 0; + b->yy_input_file = 0; + b->yy_n_chars = b->yy_buf_size; + b->yy_is_interactive = 0; + b->yy_at_bol = 1; + b->yy_fill_buffer = 0; + b->yy_buffer_status = YY_BUFFER_NEW; + + seg_yy_switch_to_buffer(b ); + + return b; +} + +/** Setup the input buffer state to scan a string. The next call to seg_yylex() will + * scan from a @e copy of @a str. + * @param yystr a NUL-terminated string to scan + * + * @return the newly allocated buffer state object. + * @note If you want to scan bytes that may contain NUL values, then use + * seg_yy_scan_bytes() instead. + */ +YY_BUFFER_STATE seg_yy_scan_string (yyconst char * yystr ) +{ + + return seg_yy_scan_bytes(yystr,strlen(yystr) ); +} + +/** Setup the input buffer state to scan the given bytes. The next call to seg_yylex() will + * scan from a @e copy of @a bytes. + * @param yybytes the byte buffer to scan + * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes. + * + * @return the newly allocated buffer state object. + */ +YY_BUFFER_STATE seg_yy_scan_bytes (yyconst char * yybytes, int _yybytes_len ) +{ + YY_BUFFER_STATE b; + char *buf; + yy_size_t n; + int i; + + /* Get memory for full buffer, including space for trailing EOB's. */ + n = _yybytes_len + 2; + buf = (char *) seg_yyalloc(n ); + if ( ! buf ) + YY_FATAL_ERROR( "out of dynamic memory in seg_yy_scan_bytes()" ); + + for ( i = 0; i < _yybytes_len; ++i ) + buf[i] = yybytes[i]; + + buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR; + + b = seg_yy_scan_buffer(buf,n ); + if ( ! b ) + YY_FATAL_ERROR( "bad buffer in seg_yy_scan_bytes()" ); + + /* It's okay to grow etc. this buffer, and we should throw it + * away when we're done. + */ + b->yy_is_our_buffer = 1; + + return b; +} + +#ifndef YY_EXIT_FAILURE +#define YY_EXIT_FAILURE 2 +#endif + +static void yy_fatal_error (yyconst char* msg ) +{ + (void) fprintf( stderr, "%s\n", msg ); + exit( YY_EXIT_FAILURE ); +} + +/* Redefine yyless() so it works in section 3 code. */ + +#undef yyless +#define yyless(n) \ + do \ + { \ + /* Undo effects of setting up seg_yytext. */ \ + int yyless_macro_arg = (n); \ + YY_LESS_LINENO(yyless_macro_arg);\ + seg_yytext[seg_yyleng] = (yy_hold_char); \ + (yy_c_buf_p) = seg_yytext + yyless_macro_arg; \ + (yy_hold_char) = *(yy_c_buf_p); \ + *(yy_c_buf_p) = '\0'; \ + seg_yyleng = yyless_macro_arg; \ + } \ + while ( 0 ) + +/* Accessor methods (get/set functions) to struct members. */ + +/** Get the current line number. + * + */ +int seg_yyget_lineno (void) +{ + + return seg_yylineno; +} + +/** Get the input stream. + * + */ +FILE *seg_yyget_in (void) +{ + return seg_yyin; +} + +/** Get the output stream. + * + */ +FILE *seg_yyget_out (void) +{ + return seg_yyout; +} + +/** Get the length of the current token. + * + */ +int seg_yyget_leng (void) +{ + return seg_yyleng; +} + +/** Get the current token. + * + */ + +char *seg_yyget_text (void) +{ + return seg_yytext; +} + +/** Set the current line number. + * @param line_number + * + */ +void seg_yyset_lineno (int line_number ) +{ + + seg_yylineno = line_number; +} + +/** Set the input stream. This does not discard the current + * input buffer. + * @param in_str A readable stream. + * + * @see seg_yy_switch_to_buffer + */ +void seg_yyset_in (FILE * in_str ) +{ + seg_yyin = in_str ; +} + +void seg_yyset_out (FILE * out_str ) +{ + seg_yyout = out_str ; +} + +int seg_yyget_debug (void) +{ + return seg_yy_flex_debug; +} + +void seg_yyset_debug (int bdebug ) +{ + seg_yy_flex_debug = bdebug ; +} + +static int yy_init_globals (void) +{ + /* Initialization is the same as for the non-reentrant scanner. + * This function is called from seg_yylex_destroy(), so don't allocate here. + */ + + (yy_buffer_stack) = 0; + (yy_buffer_stack_top) = 0; + (yy_buffer_stack_max) = 0; + (yy_c_buf_p) = (char *) 0; + (yy_init) = 0; + (yy_start) = 0; + +/* Defined in main.c */ +#ifdef YY_STDINIT + seg_yyin = stdin; + seg_yyout = stdout; +#else + seg_yyin = (FILE *) 0; + seg_yyout = (FILE *) 0; +#endif + + /* For future reference: Set errno on error, since we are called by + * seg_yylex_init() + */ + return 0; +} + +/* seg_yylex_destroy is for both reentrant and non-reentrant scanners. */ +int seg_yylex_destroy (void) +{ + + /* Pop the buffer stack, destroying each element. */ + while(YY_CURRENT_BUFFER){ + seg_yy_delete_buffer(YY_CURRENT_BUFFER ); + YY_CURRENT_BUFFER_LVALUE = NULL; + seg_yypop_buffer_state(); + } + + /* Destroy the stack itself. */ + seg_yyfree((yy_buffer_stack) ); + (yy_buffer_stack) = NULL; + + /* Reset the globals. This is important in a non-reentrant scanner so the next time + * seg_yylex() is called, initialization will occur. */ + yy_init_globals( ); + + return 0; +} + +/* + * Internal utility routines. + */ + +#ifndef yytext_ptr +static void yy_flex_strncpy (char* s1, yyconst char * s2, int n ) +{ + register int i; + for ( i = 0; i < n; ++i ) + s1[i] = s2[i]; +} +#endif + +#ifdef YY_NEED_STRLEN +static int yy_flex_strlen (yyconst char * s ) +{ + register int n; + for ( n = 0; s[n]; ++n ) + ; + + return n; +} +#endif + +void *seg_yyalloc (yy_size_t size ) +{ + return (void *) malloc( size ); +} + +void *seg_yyrealloc (void * ptr, yy_size_t size ) +{ + /* The cast to (char *) in the following accommodates both + * implementations that use char* generic pointers, and those + * that use void* generic pointers. It works with the latter + * because both ANSI C and C++ allow castless assignment from + * any pointer type to void*, and deal with argument conversions + * as though doing an assignment. + */ + return (void *) realloc( (char *) ptr, size ); +} + +void seg_yyfree (void * ptr ) +{ + free( (char *) ptr ); /* see seg_yyrealloc() for (char *) cast */ +} + +#define YYTABLES_NAME "yytables" + +#line 54 "segscan.l" + + + +void +yyerror(const char *message) +{ + if (*seg_yytext == YY_END_OF_BUFFER_CHAR) + { + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("bad seg representation"), + /* translator: %s is typically "syntax error" */ + errdetail("%s at end of input", message))); + } + else + { + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("bad seg representation"), + /* translator: first %s is typically "syntax error" */ + errdetail("%s at or near \"%s\"", message, seg_yytext))); + } +} + + +/* + * Called before any actual parsing is done + */ +void +seg_scanner_init(const char *str) +{ + Size slen = strlen(str); + + /* + * Might be left over after ereport() + */ + if (YY_CURRENT_BUFFER) + seg_yy_delete_buffer(YY_CURRENT_BUFFER); + + /* + * Make a scan buffer with special termination needed by flex. + */ + scanbuflen = slen; + scanbuf = palloc(slen + 2); + memcpy(scanbuf, str, slen); + scanbuf[slen] = scanbuf[slen + 1] = YY_END_OF_BUFFER_CHAR; + scanbufhandle = seg_yy_scan_buffer(scanbuf,slen + 2); + + BEGIN(INITIAL); +} + + +/* + * Called after parsing is done to clean up after seg_scanner_init() + */ +void +seg_scanner_finish(void) +{ + seg_yy_delete_buffer(scanbufhandle); + pfree(scanbuf); +} + diff --git a/contrib/sepgsql/.gitignore b/contrib/sepgsql/.gitignore deleted file mode 100644 index 31613e011..000000000 --- a/contrib/sepgsql/.gitignore +++ /dev/null @@ -1,7 +0,0 @@ -/sepgsql.sql -/sepgsql-regtest.fc -/sepgsql-regtest.if -/sepgsql-regtest.pp -/tmp -# Generated subdirectories -/results/ diff --git a/contrib/tablefunc/.gitignore b/contrib/tablefunc/.gitignore deleted file mode 100644 index 5dcb3ff97..000000000 --- a/contrib/tablefunc/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -# Generated subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/contrib/test_parser/.gitignore b/contrib/test_parser/.gitignore deleted file mode 100644 index 5dcb3ff97..000000000 --- a/contrib/test_parser/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -# Generated subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/contrib/tsearch2/.gitignore b/contrib/tsearch2/.gitignore deleted file mode 100644 index 5dcb3ff97..000000000 --- a/contrib/tsearch2/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -# Generated subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/contrib/unaccent/.gitignore b/contrib/unaccent/.gitignore deleted file mode 100644 index 5dcb3ff97..000000000 --- a/contrib/unaccent/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -# Generated subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/contrib/vacuumlo/.gitignore b/contrib/vacuumlo/.gitignore deleted file mode 100644 index 07f6ab4fd..000000000 --- a/contrib/vacuumlo/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/vacuumlo diff --git a/contrib/xml2/.gitignore b/contrib/xml2/.gitignore deleted file mode 100644 index 5dcb3ff97..000000000 --- a/contrib/xml2/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -# Generated subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/createdb.vcxproj b/createdb.vcxproj deleted file mode 100644 index 2327a4594..000000000 --- a/createdb.vcxproj +++ /dev/null @@ -1,147 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {72DD3C8F-8691-4AB6-BFBC-A34A40FC7C9B} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\createdb\ - .\Debug\createdb\ - false - .\Release\createdb\ - .\Release\createdb\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\bin\pg_dump;src\bin\psql;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\createdb\ - .\Debug\createdb\ - .\Debug\createdb\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\createdb\createdb.exe - Debug\libpq\libpq.lib;Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\createdb\createdb.pdb - false - .\Debug\createdb\createdb.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\bin\pg_dump;src\bin\psql;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\createdb\ - .\Release\createdb\ - .\Release\createdb\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\createdb\createdb.exe - Release\libpq\libpq.lib;Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\createdb\createdb.pdb - false - .\Release\createdb\createdb.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - - - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/createlang.vcxproj b/createlang.vcxproj deleted file mode 100644 index 060a77084..000000000 --- a/createlang.vcxproj +++ /dev/null @@ -1,146 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {B4E20F6A-ABC3-4D63-B8DA-8616A4577739} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\createlang\ - .\Debug\createlang\ - false - .\Release\createlang\ - .\Release\createlang\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\bin\pg_dump;src\bin\psql;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\createlang\ - .\Debug\createlang\ - .\Debug\createlang\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\createlang\createlang.exe - Debug\libpq\libpq.lib;Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\createlang\createlang.pdb - false - .\Debug\createlang\createlang.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\bin\pg_dump;src\bin\psql;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\createlang\ - .\Release\createlang\ - .\Release\createlang\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\createlang\createlang.exe - Release\libpq\libpq.lib;Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\createlang\createlang.pdb - false - .\Release\createlang\createlang.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/createuser.vcxproj b/createuser.vcxproj deleted file mode 100644 index 131c9477b..000000000 --- a/createuser.vcxproj +++ /dev/null @@ -1,147 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {F956EEFC-D729-4EBC-A38D-9C89A261FBAA} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\createuser\ - .\Debug\createuser\ - false - .\Release\createuser\ - .\Release\createuser\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\bin\pg_dump;src\bin\psql;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\createuser\ - .\Debug\createuser\ - .\Debug\createuser\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\createuser\createuser.exe - Debug\libpq\libpq.lib;Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\createuser\createuser.pdb - false - .\Debug\createuser\createuser.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\bin\pg_dump;src\bin\psql;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\createuser\ - .\Release\createuser\ - .\Release\createuser\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\createuser\createuser.exe - Release\libpq\libpq.lib;Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\createuser\createuser.pdb - false - .\Release\createuser\createuser.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - - - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/cube.vcxproj b/cube.vcxproj deleted file mode 100644 index a4d955bc1..000000000 --- a/cube.vcxproj +++ /dev/null @@ -1,172 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {E48A9664-924E-4D72-8B9B-1684F0B80B43} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\cube\ - .\Debug\cube\ - false - .\Release\cube\ - .\Release\cube\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\cube\ - .\Debug\cube\ - .\Debug\cube\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\cube\cube.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\cube\cube.pdb - false - .\Debug\cube\cube.map - Console - MachineX86 - Debug\cube\cube.lib - .\Debug\cube\cube.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\cube Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\cube\ - .\Release\cube\ - .\Release\cube\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\cube\cube.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\cube\cube.pdb - false - .\Release\cube\cube.map - Console - MachineX86 - Release\cube\cube.lib - .\Release\cube\cube.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\cube Win32 - - - - - - - - - Running bison on contrib\cube\cubeparse.y - perl "src\tools\msvc\pgbison.pl" "contrib\cube\cubeparse.y" - %(AdditionalInputs) - contrib\cube\cubeparse.c;%(Outputs) - Running bison on contrib\cube\cubeparse.y - perl "src\tools\msvc\pgbison.pl" "contrib\cube\cubeparse.y" - %(AdditionalInputs) - contrib\cube\cubeparse.c;%(Outputs) - - - Running flex on contrib\cube\cubescan.l - perl "src\tools\msvc\pgflex.pl" "contrib\cube\cubescan.l" - %(AdditionalInputs) - contrib\cube\cubescan.c;%(Outputs) - Running flex on contrib\cube\cubescan.l - perl "src\tools\msvc\pgflex.pl" "contrib\cube\cubescan.l" - %(AdditionalInputs) - contrib\cube\cubescan.c;%(Outputs) - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/cyrillic_and_mic.vcxproj b/cyrillic_and_mic.vcxproj deleted file mode 100644 index b9f974793..000000000 --- a/cyrillic_and_mic.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {3A08A526-4964-4B82-9B27-A30FC23CFE35} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\cyrillic_and_mic\ - .\Debug\cyrillic_and_mic\ - false - .\Release\cyrillic_and_mic\ - .\Release\cyrillic_and_mic\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\cyrillic_and_mic\ - .\Debug\cyrillic_and_mic\ - .\Debug\cyrillic_and_mic\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\cyrillic_and_mic\cyrillic_and_mic.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\cyrillic_and_mic\cyrillic_and_mic.pdb - false - .\Debug\cyrillic_and_mic\cyrillic_and_mic.map - Console - MachineX86 - Debug\cyrillic_and_mic\cyrillic_and_mic.lib - .\Debug\cyrillic_and_mic\cyrillic_and_mic.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\cyrillic_and_mic Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\cyrillic_and_mic\ - .\Release\cyrillic_and_mic\ - .\Release\cyrillic_and_mic\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\cyrillic_and_mic\cyrillic_and_mic.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\cyrillic_and_mic\cyrillic_and_mic.pdb - false - .\Release\cyrillic_and_mic\cyrillic_and_mic.map - Console - MachineX86 - Release\cyrillic_and_mic\cyrillic_and_mic.lib - .\Release\cyrillic_and_mic\cyrillic_and_mic.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\cyrillic_and_mic Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/dblink.vcxproj b/dblink.vcxproj deleted file mode 100644 index e27ce1a95..000000000 --- a/dblink.vcxproj +++ /dev/null @@ -1,152 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {FB7E17D0-F9D8-4EA3-B950-57A5952C54E5} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\dblink\ - .\Debug\dblink\ - false - .\Release\dblink\ - .\Release\dblink\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src/backend;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\dblink\ - .\Debug\dblink\ - .\Debug\dblink\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\dblink\dblink.dll - Debug\postgres\postgres.lib;Debug\libpq\libpq.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\dblink\dblink.pdb - false - .\Debug\dblink\dblink.map - Console - MachineX86 - Debug\dblink\dblink.lib - .\Debug\dblink\dblink.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\dblink Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src/backend;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\dblink\ - .\Release\dblink\ - .\Release\dblink\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\dblink\dblink.dll - Release\postgres\postgres.lib;Release\libpq\libpq.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\dblink\dblink.pdb - false - .\Release\dblink\dblink.map - Console - MachineX86 - Release\dblink\dblink.lib - .\Release\dblink\dblink.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\dblink Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - - - - \ No newline at end of file diff --git a/dict_int.vcxproj b/dict_int.vcxproj deleted file mode 100644 index dd2426a1a..000000000 --- a/dict_int.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {4602E243-FDA8-471B-952D-D2FD3FE57F0C} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\dict_int\ - .\Debug\dict_int\ - false - .\Release\dict_int\ - .\Release\dict_int\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\dict_int\ - .\Debug\dict_int\ - .\Debug\dict_int\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\dict_int\dict_int.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\dict_int\dict_int.pdb - false - .\Debug\dict_int\dict_int.map - Console - MachineX86 - Debug\dict_int\dict_int.lib - .\Debug\dict_int\dict_int.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\dict_int Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\dict_int\ - .\Release\dict_int\ - .\Release\dict_int\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\dict_int\dict_int.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\dict_int\dict_int.pdb - false - .\Release\dict_int\dict_int.map - Console - MachineX86 - Release\dict_int\dict_int.lib - .\Release\dict_int\dict_int.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\dict_int Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/dict_snowball.vcxproj b/dict_snowball.vcxproj deleted file mode 100644 index f4e0832d8..000000000 --- a/dict_snowball.vcxproj +++ /dev/null @@ -1,182 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {54994B86-0436-4501-91D8-7D6972F2C760} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\dict_snowball\ - .\Debug\dict_snowball\ - false - .\Release\dict_snowball\ - .\Release\dict_snowball\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\include\snowball;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\dict_snowball\ - .\Debug\dict_snowball\ - .\Debug\dict_snowball\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\dict_snowball\dict_snowball.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\dict_snowball\dict_snowball.pdb - false - .\Debug\dict_snowball\dict_snowball.map - Console - MachineX86 - Debug\dict_snowball\dict_snowball.lib - .\Debug\dict_snowball\dict_snowball.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\dict_snowball Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\include\snowball;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\dict_snowball\ - .\Release\dict_snowball\ - .\Release\dict_snowball\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\dict_snowball\dict_snowball.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\dict_snowball\dict_snowball.pdb - false - .\Release\dict_snowball\dict_snowball.map - Console - MachineX86 - Release\dict_snowball\dict_snowball.lib - .\Release\dict_snowball\dict_snowball.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\dict_snowball Win32 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/dict_xsyn.vcxproj b/dict_xsyn.vcxproj deleted file mode 100644 index 6443416b0..000000000 --- a/dict_xsyn.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {D03AB46E-F74F-485D-B749-40FF7C33350B} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\dict_xsyn\ - .\Debug\dict_xsyn\ - false - .\Release\dict_xsyn\ - .\Release\dict_xsyn\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\dict_xsyn\ - .\Debug\dict_xsyn\ - .\Debug\dict_xsyn\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\dict_xsyn\dict_xsyn.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\dict_xsyn\dict_xsyn.pdb - false - .\Debug\dict_xsyn\dict_xsyn.map - Console - MachineX86 - Debug\dict_xsyn\dict_xsyn.lib - .\Debug\dict_xsyn\dict_xsyn.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\dict_xsyn Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\dict_xsyn\ - .\Release\dict_xsyn\ - .\Release\dict_xsyn\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\dict_xsyn\dict_xsyn.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\dict_xsyn\dict_xsyn.pdb - false - .\Release\dict_xsyn\dict_xsyn.map - Console - MachineX86 - Release\dict_xsyn\dict_xsyn.lib - .\Release\dict_xsyn\dict_xsyn.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\dict_xsyn Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/doc/src/sgml/.gitignore b/doc/src/sgml/.gitignore deleted file mode 100644 index e1b84b490..000000000 --- a/doc/src/sgml/.gitignore +++ /dev/null @@ -1,33 +0,0 @@ -# Stuff shipped in tarballs -/html/ -/html-stamp -/man1/ -/man3/ -/man7/ -/man-stamp -# Other popular build targets -/HISTORY -/INSTALL -/regress_README -/postgres-US.pdf -/postgres-A4.pdf -/postgres.html -/postgres.txt -# GENERATED_SGML -/features-supported.sgml -/features-unsupported.sgml -/errcodes-table.sgml -/version.sgml -/bookindex.sgml -/HTML.index -# Assorted byproducts from building the above -/postgres.xml -/HISTORY.html -/INSTALL.html -/regress_README.html -/postgres-US.aux -/postgres-US.log -/postgres-US.out -/postgres-A4.aux -/postgres-A4.log -/postgres-A4.out diff --git a/doc/src/sgml/html-stamp b/doc/src/sgml/html-stamp new file mode 100644 index 000000000..e69de29bb diff --git a/doc/src/sgml/html/LEGALNOTICE.html b/doc/src/sgml/html/LEGALNOTICE.html new file mode 100644 index 000000000..26952e049 --- /dev/null +++ b/doc/src/sgml/html/LEGALNOTICE.html @@ -0,0 +1,129 @@ + +

Legal Notice

PostgreSQL is Copyright © 1996-2012 + by the PostgreSQL Global Development Group. +

Postgres95 is Copyright © 1994-5 + by the Regents of the University of California. +

Permission to use, copy, modify, and distribute this software and + its documentation for any purpose, without fee, and without a + written agreement is hereby granted, provided that the above + copyright notice and this paragraph and the following two paragraphs + appear in all copies. +

IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY + PARTY FOR DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL + DAMAGES, INCLUDING LOST PROFITS, ARISING OUT OF THE USE OF THIS + SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE UNIVERSITY OF CALIFORNIA + HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +

THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY WARRANTIES, + INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE + PROVIDED HEREUNDER IS ON AN "AS-IS" BASIS, AND THE UNIVERSITY OF + CALIFORNIA HAS NO OBLIGATIONS TO PROVIDE MAINTENANCE, SUPPORT, + UPDATES, ENHANCEMENTS, OR MODIFICATIONS. +


 Home 
\ No newline at end of file diff --git a/doc/src/sgml/html/acronyms.html b/doc/src/sgml/html/acronyms.html new file mode 100644 index 000000000..f8a092c3e --- /dev/null +++ b/doc/src/sgml/html/acronyms.html @@ -0,0 +1,1279 @@ + +Acronyms

Appendix K. Acronyms

This is a list of acronyms commonly used in the PostgreSQL + documentation and in discussions about PostgreSQL. + +

ANSI

American National Standards Institute +

API

Application Programming Interface +

ASCII

American Standard + Code for Information Interchange +

BKI

Backend Interface +

CA

Certificate Authority +

CIDR

Classless + Inter-Domain Routing +

CPAN

Comprehensive Perl Archive Network +

CRL

Certificate + Revocation List +

CSV

Comma + Separated Values +

CTE

Common Table Expression +

CVE

Common Vulnerabilities and Exposures +

DBA

Database + Administrator +

DBI

Database Interface (Perl) +

DBMS

Database Management + System +

DDL

Data + Definition Language, SQL commands such as CREATE + TABLE, ALTER USER +

DML

Data + Manipulation Language, SQL commands such as INSERT, + UPDATE, DELETE +

DST

Daylight + Saving Time +

ECPG

Embedded C for PostgreSQL +

ESQL

Embedded + SQL +

FAQ

Frequently Asked + Questions +

FSM

Free Space Map +

GEQO

Genetic Query Optimizer +

GIN

Generalized Inverted Index +

GiST

Generalized Search Tree +

Git

Git +

GMT

Greenwich Mean Time +

GSSAPI

Generic + Security Services Application Programming Interface +

GUC

Grand Unified Configuration, + the PostgreSQL subsystem that handles server configuration +

HBA

Host-Based Authentication +

HOT

Heap-Only + Tuples +

IEC

International + Electrotechnical Commission +

IEEE

Institute of Electrical and + Electronics Engineers +

IPC

Inter-Process + Communication +

ISO

International Organization for + Standardization +

ISSN

International Standard + Serial Number +

JDBC

Java + Database Connectivity +

LDAP

Lightweight + Directory Access Protocol +

MSVC

Microsoft + Visual C +

MVCC

Multi-Version Concurrency Control +

NLS

National + Language Support +

ODBC

Open + Database Connectivity +

OID

Object Identifier +

OLAP

Online Analytical + Processing +

OLTP

Online Transaction + Processing +

ORDBMS

Object-Relational + Database Management System +

PAM

Pluggable + Authentication Modules +

PGSQL

PostgreSQL +

PGXS

PostgreSQL Extension System +

PID

Process Identifier +

PITR

Point-In-Time + Recovery (Continuous Archiving) +

PL

Procedural Languages (server-side) +

POSIX

Portable Operating + System Interface +

RDBMS

Relational + Database Management System +

RFC

Request For + Comments +

SGML

Standard Generalized + Markup Language +

SPI

Server Programming Interface +

SP-GiST

Space-Partitioned Generalized Search Tree +

SQL

Structured Query Language +

SRF

Set-Returning Function +

SSH

Secure + Shell +

SSL

Secure Sockets Layer +

SSPI

Security + Support Provider Interface +

SYSV

Unix System V +

TCP/IP

Transmission + Control Protocol (TCP) / Internet Protocol (IP) +

TID

Tuple Identifier +

TOAST

The Oversized-Attribute Storage Technique +

TPC

Transaction Processing + Performance Council +

URL

Uniform Resource + Locator +

UTC

Coordinated + Universal Time +

UTF

Unicode Transformation + Format +

UTF8

Eight-Bit Unicode + Transformation Format +

UUID

Universally Unique Identifier +

WAL

Write-Ahead Log +

XID

Transaction Identifier +

XML

Extensible Markup + Language +

+


PrevHomeNext
Style GuideUpBibliography
\ No newline at end of file diff --git a/doc/src/sgml/html/admin.html b/doc/src/sgml/html/admin.html new file mode 100644 index 000000000..84c041e1a --- /dev/null +++ b/doc/src/sgml/html/admin.html @@ -0,0 +1,830 @@ + +Server Administration

III. Server Administration

This part covers topics that are of interest to a + PostgreSQL database administrator. This includes + installation of the software, set up and configuration of the + server, management of users and databases, and maintenance tasks. + Anyone who runs a PostgreSQL server, even for + personal use, but especially in production, should be familiar + with the topics covered in this part. +

The information in this part is arranged approximately in the + order in which a new user should read it. But the chapters are + self-contained and can be read individually as desired. The + information in this part is presented in a narrative fashion in + topical units. Readers looking for a complete description of a + particular command should see Part VI. +

The first few chapters are written so they can be understood + without prerequisite knowledge, so new users who need to set + up their own server can begin their exploration with this part. + The rest of this part is about tuning and management; that material + assumes that the reader is familiar with the general use of + the PostgreSQL database system. Readers are + encouraged to look at Part I and Part II for additional information. +

Table of Contents
15. Installation from Source Code
15.1. Short Version
15.2. Requirements
15.3. Getting The Source
15.4. Installation Procedure
15.5. Post-Installation Setup
15.6. Supported Platforms
15.7. Platform-specific Notes
16. Installation from Source Code on Windows
16.1. Building with Visual C++ or the + Microsoft Windows SDK
16.2. Building libpq with + Visual C++ or + Borland C++
17. Server Setup and Operation
17.1. The PostgreSQL User Account
17.2. Creating a Database Cluster
17.3. Starting the Database Server
17.4. Managing Kernel Resources
17.5. Shutting Down the Server
17.6. Upgrading a PostgreSQL Cluster
17.7. Preventing Server Spoofing
17.8. Encryption Options
17.9. Secure TCP/IP Connections with SSL
17.10. Secure TCP/IP Connections with SSH Tunnels
17.11. Registering Event Log on Windows
18. Server Configuration
18.1. Setting Parameters
18.2. File Locations
18.3. Connections and Authentication
18.4. Resource Consumption
18.5. Write Ahead Log
18.6. Replication
18.7. Query Planning
18.8. Error Reporting and Logging
18.9. Run-time Statistics
18.10. Automatic Vacuuming
18.11. Client Connection Defaults
18.12. Lock Management
18.13. Version and Platform Compatibility
18.14. Error Handling
18.15. Preset Options
18.16. Customized Options
18.17. Developer Options
18.18. Short Options
19. Client Authentication
19.1. The pg_hba.conf File
19.2. User Name Maps
19.3. Authentication Methods
19.4. Authentication Problems
20. Database Roles
20.1. Database Roles
20.2. Role Attributes
20.3. Role Membership
20.4. Function and Trigger Security
21. Managing Databases
21.1. Overview
21.2. Creating a Database
21.3. Template Databases
21.4. Database Configuration
21.5. Destroying a Database
21.6. Tablespaces
22. Localization
22.1. Locale Support
22.2. Collation Support
22.3. Character Set Support
23. Routine Database Maintenance Tasks
23.1. Routine Vacuuming
23.2. Routine Reindexing
23.3. Log File Maintenance
24. Backup and Restore
24.1. SQL Dump
24.2. File System Level Backup
24.3. Continuous Archiving and Point-in-Time Recovery (PITR)
25. High Availability, Load Balancing, and Replication
25.1. Comparison of Different Solutions
25.2. Log-Shipping Standby Servers
25.3. Failover
25.4. Alternative Method for Log Shipping
25.5. Hot Standby
26. Recovery Configuration
26.1. Archive Recovery Settings
26.2. Recovery Target Settings
26.3. Standby Server Settings
27. Monitoring Database Activity
27.1. Standard Unix Tools
27.2. The Statistics Collector
27.3. Viewing Locks
27.4. Dynamic Tracing
28. Monitoring Disk Usage
28.1. Determining Disk Usage
28.2. Disk Full Failure
29. Reliability and the Write-Ahead Log
29.1. Reliability
29.2. Write-Ahead Logging (WAL)
29.3. Asynchronous Commit
29.4. WAL Configuration
29.5. WAL Internals
30. Regression Tests
30.1. Running the Tests
30.2. Test Evaluation
30.3. Variant Comparison Files
30.4. Test Coverage Examination

PrevHomeNext
Non-Durable Settings Installation from Source Code
\ No newline at end of file diff --git a/doc/src/sgml/html/adminpack.html b/doc/src/sgml/html/adminpack.html new file mode 100644 index 000000000..d483b8e90 --- /dev/null +++ b/doc/src/sgml/html/adminpack.html @@ -0,0 +1,205 @@ + +adminpack
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.1. adminpack

adminpack provides a number of support functions which + pgAdmin and other administration and management tools can + use to provide additional functionality, such as remote management + of server log files. +

F.1.1. Functions Implemented

The functions implemented by adminpack can only be run by a + superuser. Here's a list of these functions: + +

int8 pg_catalog.pg_file_write(fname text, data text, append bool)
+bool pg_catalog.pg_file_rename(oldname text, newname text, archivename text)
+bool pg_catalog.pg_file_rename(oldname text, newname text)
+bool pg_catalog.pg_file_unlink(fname text)
+setof record pg_catalog.pg_logdir_ls()
+
+/* Renaming of existing backend functions for pgAdmin compatibility */
+int8 pg_catalog.pg_file_read(fname text, data text, append bool)
+bigint pg_catalog.pg_file_length(text)
+int4 pg_catalog.pg_logfile_rotate()

+


PrevHomeNext
Additional Supplied ModulesUpauth_delay
\ No newline at end of file diff --git a/doc/src/sgml/html/app-clusterdb.html b/doc/src/sgml/html/app-clusterdb.html new file mode 100644 index 000000000..ee3c339ab --- /dev/null +++ b/doc/src/sgml/html/app-clusterdb.html @@ -0,0 +1,755 @@ + +clusterdb

clusterdb

Name

clusterdb -- cluster a PostgreSQL database

Synopsis

clusterdb [connection-option...] [--verbose | -v] [ --table | -t table ] [dbname]

clusterdb [connection-option...] [--verbose | -v] --all | -a

Description

clusterdb is a utility for reclustering tables + in a PostgreSQL database. It finds tables + that have previously been clustered, and clusters them again on the same + index that was last used. Tables that have never been clustered are not + affected. +

clusterdb is a wrapper around the SQL + command CLUSTER. + There is no effective difference between clustering databases via + this utility and via other methods for accessing the server. +

Options

clusterdb accepts the following command-line arguments: + +

-a
--all

Cluster all databases. +

[-d] dbname
[--dbname=]dbname

Specifies the name of the database to be clustered. + If this is not specified and -a (or + --all) is not used, the database name is read + from the environment variable PGDATABASE. If + that is not set, the user name specified for the connection is + used. +

-e
--echo

Echo the commands that clusterdb generates + and sends to the server. +

-q
--quiet

Do not display progress messages. +

-t table
--table=table

Cluster table only. +

-v
--verbose

Print detailed information during processing. +

-V
--version

Print the clusterdb version and exit. +

-?
--help

Show help about clusterdb command line + arguments, and exit. +

+

clusterdb also accepts + the following command-line arguments for connection parameters: + +

-h host
--host=host

Specifies the host name of the machine on which the server is + running. If the value begins with a slash, it is used as the + directory for the Unix domain socket. +

-p port
--port=port

Specifies the TCP port or local Unix domain socket file + extension on which the server + is listening for connections. +

-U username
--username=username

User name to connect as. +

-w
--no-password

Never issue a password prompt. If the server requires + password authentication and a password is not available by + other means such as a .pgpass file, the + connection attempt will fail. This option can be useful in + batch jobs and scripts where no user is present to enter a + password. +

-W
--password

Force clusterdb to prompt for a + password before connecting to a database. +

This option is never essential, since + clusterdb will automatically prompt + for a password if the server demands password authentication. + However, clusterdb will waste a + connection attempt finding out that the server wants a password. + In some cases it is worth typing -W to avoid the extra + connection attempt. +

--maintenance-db=dbname

Specifies the name of the database to connect to discover what other + databases should be clustered. If not specified, the + postgres database will be used, + and if that does not exist, template1 will be used. +

+

Environment

PGDATABASE
PGHOST
PGPORT
PGUSER

Default connection parameters +

This utility, like most other PostgreSQL utilities, + also uses the environment variables supported by libpq + (see Section 31.14). +

Diagnostics

In case of difficulty, see CLUSTER + and psql for + discussions of potential problems and error messages. + The database server must be running at the + targeted host. Also, any default connection settings and environment + variables used by the libpq front-end + library will apply. +

Examples

To cluster the database test: +

$ clusterdb test

+

To cluster a single table + foo in a database named + xyzzy: +

$ clusterdb --table foo xyzzy

See Also

CLUSTER

PrevHomeNext
PostgreSQL Client ApplicationsUpcreatedb
\ No newline at end of file diff --git a/doc/src/sgml/html/app-createdb.html b/doc/src/sgml/html/app-createdb.html new file mode 100644 index 000000000..9b605ecca --- /dev/null +++ b/doc/src/sgml/html/app-createdb.html @@ -0,0 +1,881 @@ + +createdb

createdb

Name

createdb -- create a new PostgreSQL database

Synopsis

createdb [connection-option...] [option...] [dbname + [description]]

Description +

createdb creates a new PostgreSQL + database. +

Normally, the database user who executes this command becomes the owner of + the new database. + However, a different owner can be specified via the -O + option, if the executing user has appropriate privileges. +

createdb is a wrapper around the + SQL command CREATE DATABASE. + There is no effective difference between creating databases via + this utility and via other methods for accessing the server. +

Options

createdb accepts the following command-line arguments: + +

dbname

Specifies the name of the database to be created. The name must be + unique among all PostgreSQL databases in this cluster. + The default is to create a database with the same name as the + current system user. +

description

Specifies a comment to be associated with the newly created + database. +

-D tablespace
--tablespace=tablespace

Specifies the default tablespace for the database. (This name + is processed as a double-quoted identifier.) +

-e
--echo

Echo the commands that createdb generates + and sends to the server. +

-E encoding
--encoding=encoding

Specifies the character encoding scheme to be used in this + database. The character sets supported by the + PostgreSQL server are described in + Section 22.3.1. +

-l locale
--locale=locale

Specifies the locale to be used in this database. This is equivalent + to specifying both --lc-collate and --lc-ctype. +

--lc-collate=locale

Specifies the LC_COLLATE setting to be used in this database. +

--lc-ctype=locale

Specifies the LC_CTYPE setting to be used in this database. +

-O owner
--owner=owner

Specifies the database user who will own the new database. + (This name is processed as a double-quoted identifier.) +

-T template
--template=template

Specifies the template database from which to build this + database. (This name is processed as a double-quoted identifier.) +

-V
--version

Print the createdb version and exit. +

-?
--help

Show help about createdb command line + arguments, and exit. +

+

The options -D, -l, -E, + -O, and + -T correspond to options of the underlying + SQL command CREATE DATABASE; see there for more information + about them. +

createdb also accepts the following + command-line arguments for connection parameters: + +

-h host
--host=host

Specifies the host name of the machine on which the + server is running. If the value begins with a slash, it is used + as the directory for the Unix domain socket. +

-p port
--port=port

Specifies the TCP port or the local Unix domain socket file + extension on which the server is listening for connections. +

-U username
--username=username

User name to connect as. +

-w
--no-password

Never issue a password prompt. If the server requires + password authentication and a password is not available by + other means such as a .pgpass file, the + connection attempt will fail. This option can be useful in + batch jobs and scripts where no user is present to enter a + password. +

-W
--password

Force createdb to prompt for a + password before connecting to a database. +

This option is never essential, since + createdb will automatically prompt + for a password if the server demands password authentication. + However, createdb will waste a + connection attempt finding out that the server wants a password. + In some cases it is worth typing -W to avoid the extra + connection attempt. +

--maintenance-db=dbname

Specifies the name of the database to connect to when creating the + new database. If not specified, the postgres + database will be used; if that does not exist (or if it is the name + of the new database being created), template1 will + be used. +

+

Environment

PGDATABASE

If set, the name of the database to create, unless overridden on + the command line. +

PGHOST
PGPORT
PGUSER

Default connection parameters. PGUSER also + determines the name of the database to create, if it is not + specified on the command line or by PGDATABASE. +

This utility, like most other PostgreSQL utilities, + also uses the environment variables supported by libpq + (see Section 31.14). +

Diagnostics

In case of difficulty, see CREATE DATABASE + and psql for + discussions of potential problems and error messages. + The database server must be running at the + targeted host. Also, any default connection settings and environment + variables used by the libpq front-end + library will apply. +

Examples

To create the database demo using the default + database server: +

$ createdb demo

+

To create the database demo using the + server on host eden, port 5000, using the + LATIN1 encoding scheme with a look at the + underlying command: +

$ createdb -p 5000 -h eden -E LATIN1 -e demo
+CREATE DATABASE demo ENCODING 'LATIN1';


PrevHomeNext
clusterdbUpcreatelang
\ No newline at end of file diff --git a/doc/src/sgml/html/app-createlang.html b/doc/src/sgml/html/app-createlang.html new file mode 100644 index 000000000..11d3d6717 --- /dev/null +++ b/doc/src/sgml/html/app-createlang.html @@ -0,0 +1,711 @@ + +createlang

createlang

Name

createlang -- install a PostgreSQL procedural language

Synopsis

createlang [connection-option...] langname [dbname]

createlang [connection-option...] --list | -l [dbname]

Description

createlang is a utility for adding a + procedural language to a PostgreSQL database. +

createlang is just a wrapper around the + CREATE EXTENSION SQL command. +

Caution

createlang is deprecated and may be removed + in a future PostgreSQL release. Direct use + of the CREATE EXTENSION command is recommended instead. +

Options

createlang accepts the following command-line arguments: + +

langname

Specifies the name of the procedural language to be + installed. (This name is lower-cased.) +

[-d] dbname
[--dbname=]dbname

Specifies the database to which the language should be added. + The default is to use the database with the same name as the + current system user. +

-e
--echo

Display SQL commands as they are executed. +

-l
--list

Show a list of already installed languages in the target database. +

-V
--version

Print the createlang version and exit. +

-?
--help

Show help about createlang command line + arguments, and exit. +

+

createlang also accepts + the following command-line arguments for connection parameters: + +

-h host
--host=host

Specifies the host name of the machine on which the + server + is running. If the value begins with a slash, it is used + as the directory for the Unix domain socket. +

-p port
--port=port

Specifies the TCP port or local Unix domain socket file + extension on which the server + is listening for connections. +

-U username
--username=username

User name to connect as. +

-w
--no-password

Never issue a password prompt. If the server requires + password authentication and a password is not available by + other means such as a .pgpass file, the + connection attempt will fail. This option can be useful in + batch jobs and scripts where no user is present to enter a + password. +

-W
--password

Force createlang to prompt for a + password before connecting to a database. +

This option is never essential, since + createlang will automatically prompt + for a password if the server demands password authentication. + However, createlang will waste a + connection attempt finding out that the server wants a password. + In some cases it is worth typing -W to avoid the extra + connection attempt. +

+

Environment

PGDATABASE
PGHOST
PGPORT
PGUSER

Default connection parameters +

This utility, like most other PostgreSQL utilities, + also uses the environment variables supported by libpq + (see Section 31.14). +

Diagnostics

Most error messages are self-explanatory. If not, run + createlang with the --echo + option and see the respective SQL command + for details. Also, any default connection settings and environment + variables used by the libpq front-end + library will apply. +

Notes

Use droplang to remove a language. +

Examples

To install the language pltcl into the database + template1: +

$ createlang pltcl template1

+ Note that installing the language into template1 + will cause it to be automatically installed into subsequently-created + databases as well. +


PrevHomeNext
createdbUpcreateuser
\ No newline at end of file diff --git a/doc/src/sgml/html/app-createuser.html b/doc/src/sgml/html/app-createuser.html new file mode 100644 index 000000000..90d6fa1af --- /dev/null +++ b/doc/src/sgml/html/app-createuser.html @@ -0,0 +1,1016 @@ + +createuser

createuser

Name

createuser -- define a new PostgreSQL user account

Synopsis

createuser [connection-option...] [option...] [username]

Description

createuser creates a + new PostgreSQL user (or more precisely, a role). + Only superusers and users with CREATEROLE privilege can create + new users, so createuser must be + invoked by someone who can connect as a superuser or a user with + CREATEROLE privilege. +

If you wish to create a new superuser, you must connect as a + superuser, not merely with CREATEROLE privilege. + Being a superuser implies the ability to bypass all access permission + checks within the database, so superuserdom should not be granted lightly. +

createuser is a wrapper around the + SQL command CREATE ROLE. + There is no effective difference between creating users via + this utility and via other methods for accessing the server. +

Options

createuser accepts the following command-line arguments: + +

username

Specifies the name of the PostgreSQL user + to be created. + This name must be different from all existing roles in this + PostgreSQL installation. +

-c number
--connection-limit=number

Set a maximum number of connections for the new user. + The default is to set no limit. +

-d
--createdb

The new user will be allowed to create databases. +

-D
--no-createdb

The new user will not be allowed to create databases. This is the + default. +

-e
--echo

Echo the commands that createuser generates + and sends to the server. +

-E
--encrypted

Encrypts the user's password stored in the database. If not + specified, the default password behavior is used. +

-i
--inherit

The new role will automatically inherit privileges of roles + it is a member of. + This is the default. +

-I
--no-inherit

The new role will not automatically inherit privileges of roles + it is a member of. +

--interactive

Prompt for the user name if none is specified on the command line, and + also prompt for whichever of the options + -d/-D, + -r/-R, + -s/-S is not specified on the command + line. (This was the default behavior up to PostgreSQL 9.1.) +

-l
--login

The new user will be allowed to log in (that is, the user name + can be used as the initial session user identifier). + This is the default. +

-L
--no-login

The new user will not be allowed to log in. + (A role without login privilege is still useful as a means of + managing database permissions.) +

-N
--unencrypted

Does not encrypt the user's password stored in the database. If + not specified, the default password behavior is used. +

-P
--pwprompt

If given, createuser will issue a prompt for + the password of the new user. This is not necessary if you do not plan + on using password authentication. +

-r
--createrole

The new user will be allowed to create new roles (that is, + this user will have CREATEROLE privilege). +

-R
--no-createrole

The new user will not be allowed to create new roles. This is the + default. +

-s
--superuser

The new user will be a superuser. +

-S
--no-superuser

The new user will not be a superuser. This is the default. +

-V
--version

Print the createuser version and exit. +

--replication

The new user will have the REPLICATION privilege, + which is described more fully in the documentation for CREATE ROLE. +

--no-replication

The new user will not have the REPLICATION + privilege, which is described more fully in the documentation for CREATE ROLE. +

-?
--help

Show help about createuser command line + arguments, and exit. +

+

createuser also accepts the following + command-line arguments for connection parameters: + +

-h host
--host=host

Specifies the host name of the machine on which the + server + is running. If the value begins with a slash, it is used + as the directory for the Unix domain socket. +

-p port
--port=port

Specifies the TCP port or local Unix domain socket file + extension on which the server + is listening for connections. +

-U username
--username=username

User name to connect as (not the user name to create). +

-w
--no-password

Never issue a password prompt. If the server requires + password authentication and a password is not available by + other means such as a .pgpass file, the + connection attempt will fail. This option can be useful in + batch jobs and scripts where no user is present to enter a + password. +

-W
--password

Force createuser to prompt for a + password (for connecting to the server, not for the + password of the new user). +

This option is never essential, since + createuser will automatically prompt + for a password if the server demands password authentication. + However, createuser will waste a + connection attempt finding out that the server wants a password. + In some cases it is worth typing -W to avoid the extra + connection attempt. +

+

Environment

PGHOST
PGPORT
PGUSER

Default connection parameters +

This utility, like most other PostgreSQL utilities, + also uses the environment variables supported by libpq + (see Section 31.14). +

Diagnostics

In case of difficulty, see CREATE ROLE + and psql for + discussions of potential problems and error messages. + The database server must be running at the + targeted host. Also, any default connection settings and environment + variables used by the libpq front-end + library will apply. +

Examples

To create a user joe on the default database + server: +

$ createuser joe

+

To create a user joe on the default database + server with prompting for some additional attributes: +

$ createuser --interactive joe
+Shall the new role be a superuser? (y/n) n
+Shall the new role be allowed to create databases? (y/n) n
+Shall the new role be allowed to create more new roles? (y/n) n

+

To create the same user joe using the + server on host eden, port 5000, with attributes explicitly specified, + taking a look at the underlying command: +

$ createuser -h eden -p 5000 -S -D -R -e joe
+CREATE ROLE joe NOSUPERUSER NOCREATEDB NOCREATEROLE INHERIT LOGIN;

+

To create the user joe as a superuser, + and assign a password immediately: +

$ createuser -P -s -e joe
+Enter password for new role: xyzzy
+Enter it again: xyzzy
+CREATE ROLE joe PASSWORD 'md5b5f5ba1a423792b526f799ae4eb3d59e' SUPERUSER CREATEDB CREATEROLE INHERIT LOGIN;

+ In the above example, the new password isn't actually echoed when typed, + but we show what was typed for clarity. As you see, the password is + encrypted before it is sent to the client. If the option --unencrypted + is used, the password will appear in the echoed command + (and possibly also in the server log and elsewhere), + so you don't want to use -e in that case, if + anyone else can see your screen. +


PrevHomeNext
createlangUpdropdb
\ No newline at end of file diff --git a/doc/src/sgml/html/app-dropdb.html b/doc/src/sgml/html/app-dropdb.html new file mode 100644 index 000000000..57b833f8e --- /dev/null +++ b/doc/src/sgml/html/app-dropdb.html @@ -0,0 +1,670 @@ + +dropdb

dropdb

Name

dropdb -- remove a PostgreSQL database

Synopsis

dropdb [connection-option...] [option...] dbname

Description

dropdb destroys an existing + PostgreSQL database. + The user who executes this command must be a database + superuser or the owner of the database. +

dropdb is a wrapper around the + SQL command DROP DATABASE. + There is no effective difference between dropping databases via + this utility and via other methods for accessing the server. +

Options

dropdb accepts the following command-line arguments: + +

dbname

Specifies the name of the database to be removed. +

-e
--echo

Echo the commands that dropdb generates + and sends to the server. +

-i
--interactive

Issues a verification prompt before doing anything destructive. +

-V
--version

Print the dropdb version and exit. +

--if-exists

Do not throw an error if the database does not exist. A notice is issued + in this case. +

-?
--help

Show help about dropdb command line + arguments, and exit. +

+ +

dropdb also accepts the following + command-line arguments for connection parameters: + +

-h host
--host=host

Specifies the host name of the machine on which the + server + is running. If the value begins with a slash, it is used + as the directory for the Unix domain socket. +

-p port
--port=port

Specifies the TCP port or local Unix domain socket file + extension on which the server + is listening for connections. +

-U username
--username=username

User name to connect as. +

-w
--no-password

Never issue a password prompt. If the server requires + password authentication and a password is not available by + other means such as a .pgpass file, the + connection attempt will fail. This option can be useful in + batch jobs and scripts where no user is present to enter a + password. +

-W
--password

Force dropdb to prompt for a + password before connecting to a database. +

This option is never essential, since + dropdb will automatically prompt + for a password if the server demands password authentication. + However, dropdb will waste a + connection attempt finding out that the server wants a password. + In some cases it is worth typing -W to avoid the extra + connection attempt. +

--maintenance-db=dbname

Specifies the name of the database to connect to in order to drop the + target database. If not specified, the postgres + database will be used; if that does not exist (or is the database + being dropped), template1 will be used. +

+

Environment

PGHOST
PGPORT
PGUSER

Default connection parameters +

This utility, like most other PostgreSQL utilities, + also uses the environment variables supported by libpq + (see Section 31.14). +

Diagnostics

In case of difficulty, see DROP DATABASE + and psql for + discussions of potential problems and error messages. + The database server must be running at the + targeted host. Also, any default connection settings and environment + variables used by the libpq front-end + library will apply. +

Examples

To destroy the database demo on the default + database server: +

$ dropdb demo

+

To destroy the database demo using the + server on host eden, port 5000, with verification and a peek + at the underlying command: +

$ dropdb -p 5000 -h eden -i -e demo
+Database "demo" will be permanently deleted.
+Are you sure? (y/n) y
+DROP DATABASE demo;


PrevHomeNext
createuserUpdroplang
\ No newline at end of file diff --git a/doc/src/sgml/html/app-droplang.html b/doc/src/sgml/html/app-droplang.html new file mode 100644 index 000000000..75dda3854 --- /dev/null +++ b/doc/src/sgml/html/app-droplang.html @@ -0,0 +1,702 @@ + +droplang

droplang

Name

droplang -- remove a PostgreSQL procedural language

Synopsis

droplang [connection-option...] langname [dbname]

droplang [connection-option...] --list | -l [dbname]

Description +

droplang is a utility for removing an + existing procedural language from a + PostgreSQL database. +

droplang is just a wrapper around the + DROP EXTENSION SQL command. +

Caution

droplang is deprecated and may be removed + in a future PostgreSQL release. Direct use + of the DROP EXTENSION command is recommended instead. +

Options

droplang accepts the following command line arguments: + +

langname

Specifies the name of the procedural language to be removed. + (This name is lower-cased.) +

[-d] dbname
[--dbname=]dbname

Specifies from which database the language should be removed. + The default is to use the database with the same name as the + current system user. +

-e
--echo

Display SQL commands as they are executed. +

-l
--list

Show a list of already installed languages in the target database. +

-V
--version

Print the droplang version and exit. +

-?
--help

Show help about droplang command line + arguments, and exit. +

+

droplang also accepts + the following command line arguments for connection parameters: + +

-h host
--host=host

Specifies the host name of the machine on which the + server + is running. If host begins with a slash, it is used + as the directory for the Unix domain socket. +

-p port
--port=port

Specifies the Internet TCP/IP port or local Unix domain socket file + extension on which the server + is listening for connections. +

-U username
--username=username

User name to connect as. +

-w
--no-password

Never issue a password prompt. If the server requires + password authentication and a password is not available by + other means such as a .pgpass file, the + connection attempt will fail. This option can be useful in + batch jobs and scripts where no user is present to enter a + password. +

-W
--password

Force droplang to prompt for a + password before connecting to a database. +

This option is never essential, since + droplang will automatically prompt + for a password if the server demands password authentication. + However, droplang will waste a + connection attempt finding out that the server wants a password. + In some cases it is worth typing -W to avoid the extra + connection attempt. +

+

Environment

PGDATABASE
PGHOST
PGPORT
PGUSER

Default connection parameters +

This utility, like most other PostgreSQL utilities, + also uses the environment variables supported by libpq + (see Section 31.14). +

Diagnostics

Most error messages are self-explanatory. If not, run + droplang with the --echo + option and see under the respective SQL command + for details. Also, any default connection settings and environment + variables used by the libpq front-end + library will apply. +

Notes

Use createlang to add a language. +

Examples

To remove the language pltcl: +

$ droplang pltcl dbname


PrevHomeNext
dropdbUpdropuser
\ No newline at end of file diff --git a/doc/src/sgml/html/app-dropuser.html b/doc/src/sgml/html/app-dropuser.html new file mode 100644 index 000000000..49a6878fb --- /dev/null +++ b/doc/src/sgml/html/app-dropuser.html @@ -0,0 +1,665 @@ + +dropuser

dropuser

Name

dropuser -- remove a PostgreSQL user account

Synopsis

dropuser [connection-option...] [option...] [username]

Description

dropuser removes an existing + PostgreSQL user. + Only superusers and users with the CREATEROLE privilege can + remove PostgreSQL users. (To remove a + superuser, you must yourself be a superuser.) +

dropuser is a wrapper around the + SQL command DROP ROLE. + There is no effective difference between dropping users via + this utility and via other methods for accessing the server. +

Options

dropuser accepts the following command-line arguments: + +

username

Specifies the name of the PostgreSQL user to be removed. + You will be prompted for a name if none is specified on the command + line and the -i/--interactive option + is used. +

-e
--echo

Echo the commands that dropuser generates + and sends to the server. +

-i
--interactive

Prompt for confirmation before actually removing the user, and prompt + for the user name if none is specified on the command line. +

-V
--version

Print the dropuser version and exit. +

--if-exists

Do not throw an error if the user does not exist. A notice is + issued in this case. +

-?
--help

Show help about dropuser command line + arguments, and exit. +

+

dropuser also accepts the following + command-line arguments for connection parameters: + +

-h host
--host=host

Specifies the host name of the machine on which the + server + is running. If the value begins with a slash, it is used + as the directory for the Unix domain socket. +

-p port
--port=port

Specifies the TCP port or local Unix domain socket file + extension on which the server + is listening for connections. +

-U username
--username=username

User name to connect as (not the user name to drop). +

-w
--no-password

Never issue a password prompt. If the server requires + password authentication and a password is not available by + other means such as a .pgpass file, the + connection attempt will fail. This option can be useful in + batch jobs and scripts where no user is present to enter a + password. +

-W
--password

Force dropuser to prompt for a + password before connecting to a database. +

This option is never essential, since + dropuser will automatically prompt + for a password if the server demands password authentication. + However, dropuser will waste a + connection attempt finding out that the server wants a password. + In some cases it is worth typing -W to avoid the extra + connection attempt. +

+

Environment

PGHOST
PGPORT
PGUSER

Default connection parameters +

This utility, like most other PostgreSQL utilities, + also uses the environment variables supported by libpq + (see Section 31.14). +

Diagnostics

In case of difficulty, see DROP ROLE + and psql for + discussions of potential problems and error messages. + The database server must be running at the + targeted host. Also, any default connection settings and environment + variables used by the libpq front-end + library will apply. +

Examples

To remove user joe from the default database + server: +

$ dropuser joe

+

To remove user joe using the server on host + eden, port 5000, with verification and a peek at the underlying + command: +

$ dropuser -p 5000 -h eden -i -e joe
+Role "joe" will be permanently removed.
+Are you sure? (y/n) y
+DROP ROLE joe;


PrevHomeNext
droplangUpecpg
\ No newline at end of file diff --git a/doc/src/sgml/html/app-ecpg.html b/doc/src/sgml/html/app-ecpg.html new file mode 100644 index 000000000..b6a2941d7 --- /dev/null +++ b/doc/src/sgml/html/app-ecpg.html @@ -0,0 +1,593 @@ + +ecpg

ecpg

Name

ecpg -- embedded SQL C preprocessor

Synopsis

ecpg [option...] file...

Description

ecpg is the embedded SQL preprocessor for C + programs. It converts C programs with embedded SQL statements to + normal C code by replacing the SQL invocations with special + function calls. The output files can then be processed with any C + compiler tool chain. +

ecpg will convert each input file given on the + command line to the corresponding C output file. Input files + preferably have the extension .pgc, in which + case the extension will be replaced by .c to + determine the output file name. If the extension of the input file + is not .pgc, then the output file name is + computed by appending .c to the full file name. + The output file name can also be overridden using the + -o option. +

This reference page does not describe the embedded SQL language. + See Chapter 33 for more information on that topic. +

Options

ecpg accepts the following command-line + arguments: + +

-c

Automatically generate certain C code from SQL code. Currently, this + works for EXEC SQL TYPE. +

-C mode

Set a compatibility mode. mode can + be INFORMIX or + INFORMIX_SE. +

-D symbol

Define a C preprocessor symbol. +

-i

Parse system include files as well. +

-I directory

Specify an additional include path, used to find files included + via EXEC SQL INCLUDE. Defaults are + . (current directory), + /usr/local/include, the + PostgreSQL include directory which + is defined at compile time (default: + /usr/local/pgsql/include), and + /usr/include, in that order. +

-o filename

Specifies that ecpg should write all + its output to the given filename. +

-r option

Selects run-time behavior. Option can be + one of the following: +

no_indicator

Do not use indicators but instead use special values to represent + null values. Historically there have been databases using this approach. +

prepare

Prepare all statements before using them. Libecpg will keep a cache of + prepared statements and reuse a statement if it gets executed again. If the + cache runs full, libecpg will free the least used statement. +

questionmarks

Allow question mark as placeholder for compatibility reasons. + This used to be the default long ago. +

-t

Turn on autocommit of transactions. In this mode, each SQL command is + automatically committed unless it is inside an explicit + transaction block. In the default mode, commands are committed + only when EXEC SQL COMMIT is issued. +

-v

Print additional information including the version and the + "include" path. +

--version

Print the ecpg version and exit. +

-?
--help

Show help about ecpg command line + arguments, and exit. +

+

Notes

When compiling the preprocessed C code files, the compiler needs to + be able to find the ECPG header files in the + PostgreSQL include directory. Therefore, you might + have to use the -I option when invoking the compiler + (e.g., -I/usr/local/pgsql/include). +

Programs using C code with embedded SQL have to be linked against + the libecpg library, for example using the + linker options -L/usr/local/pgsql/lib -lecpg. +

The value of either of these directories that is appropriate for + the installation can be found out using pg_config. +

Examples

If you have an embedded SQL C source file named + prog1.pgc, you can create an executable + program using the following sequence of commands: +

ecpg prog1.pgc
+cc -I/usr/local/pgsql/include -c prog1.c
+cc -o prog1 prog1.o -L/usr/local/pgsql/lib -lecpg


PrevHomeNext
dropuserUppg_basebackup
\ No newline at end of file diff --git a/doc/src/sgml/html/app-initdb.html b/doc/src/sgml/html/app-initdb.html new file mode 100644 index 000000000..a1cb76903 --- /dev/null +++ b/doc/src/sgml/html/app-initdb.html @@ -0,0 +1,964 @@ + +initdb

initdb

Name

initdb -- create a new PostgreSQL database cluster

Synopsis

initdb [option...] [--pgdata | -D] directory

Description +

initdb creates a new + PostgreSQL database cluster. A database + cluster is a collection of databases that are managed by a single + server instance. +

Creating a database cluster consists of creating the directories in + which the database data will live, generating the shared catalog + tables (tables that belong to the whole cluster rather than to any + particular database), and creating the template1 + and postgres databases. When you later create a + new database, everything in the template1 database is + copied. (Therefore, anything installed in template1 + is automatically copied into each database created later.) + The postgres database is a default database meant + for use by users, utilities and third party applications. +

Although initdb will attempt to create the + specified data directory, it might not have permission if the parent + directory of the desired data directory is root-owned. To initialize + in such a setup, create an empty data directory as root, then use + chown to assign ownership of that directory to the + database user account, then su to become the + database user to run initdb. +

initdb must be run as the user that will own the + server process, because the server needs to have access to the + files and directories that initdb creates. + Since the server cannot be run as root, you must not run + initdb as root either. (It will in fact refuse + to do so.) +

initdb initializes the database cluster's default + locale and character set encoding. The character set encoding, + collation order (LC_COLLATE) and character set classes + (LC_CTYPE, e.g. upper, lower, digit) can be set separately + for a database when it is created. initdb determines + those settings for the template1 database, which will + serve as the default for all other databases. +

To alter the default collation order or character set classes, use the + --lc-collate and --lc-ctype options. + Collation orders other than C or POSIX also have + a performance penalty. For these reasons it is important to choose the + right locale when running initdb. +

The remaining locale categories can be changed later when the server + is started. You can also use --locale to set the + default for all locale categories, including collation order and + character set classes. All server locale values (lc_*) can + be displayed via SHOW ALL. + More details can be found in Section 22.1. +

To alter the default encoding, use the --encoding. + More details can be found in Section 22.3. +

Options

-A authmethod
--auth=authmethod

This option specifies the authentication method for local users used + in pg_hba.conf (host + and local lines). Do not use trust + unless you trust all local users on your system. trust is + the default for ease of installation. +

--auth-host=authmethod

This option specifies the authentication method for local users via + TCP/IP connections used in pg_hba.conf + (host lines). +

--auth-local=authmethod

This option specifies the authentication method for local users via + Unix-domain socket connections used in pg_hba.conf + (local lines). +

-D directory
--pgdata=directory

This option specifies the directory where the database cluster + should be stored. This is the only information required by + initdb, but you can avoid writing it by + setting the PGDATA environment variable, which + can be convenient since the database server + (postgres) can find the database + directory later by the same variable. +

-E encoding
--encoding=encoding

Selects the encoding of the template database. This will also + be the default encoding of any database you create later, + unless you override it there. The default is derived from the locale, or + SQL_ASCII if that does not work. The character sets supported by + the PostgreSQL server are described + in Section 22.3.1. +

--locale=locale

Sets the default locale for the database cluster. If this + option is not specified, the locale is inherited from the + environment that initdb runs in. Locale + support is described in Section 22.1. +

--lc-collate=locale
--lc-ctype=locale
--lc-messages=locale
--lc-monetary=locale
--lc-numeric=locale
--lc-time=locale

Like --locale, but only sets the locale in + the specified category. +

--no-locale

Equivalent to --locale=C. +

--pwfile=filename

Makes initdb read the database superuser's password + from a file. The first line of the file is taken as the password. +

-T CFG
--text-search-config=CFG

Sets the default text search configuration. + See default_text_search_config for further information. +

-U username
--username=username

Selects the user name of the database superuser. This defaults + to the name of the effective user running + initdb. It is really not important what the + superuser's name is, but one might choose to keep the + customary name postgres, even if the operating + system user's name is different. +

-W
--pwprompt

Makes initdb prompt for a password + to give the database superuser. If you don't plan on using password + authentication, this is not important. Otherwise you won't be + able to use password authentication until you have a password + set up. +

-X directory
--xlogdir=directory

This option specifies the directory where the transaction log + should be stored. +

+

Other, less commonly used, options are also available: + +

-d
--debug

Print debugging output from the bootstrap backend and a few other + messages of lesser interest for the general public. + The bootstrap backend is the program initdb + uses to create the catalog tables. This option generates a tremendous + amount of extremely boring output. +

-L directory

Specifies where initdb should find + its input files to initialize the database cluster. This is + normally not necessary. You will be told if you need to + specify their location explicitly. +

-n
--noclean

By default, when initdb + determines that an error prevented it from completely creating the database + cluster, it removes any files it might have created before discovering + that it cannot finish the job. This option inhibits tidying-up and is + thus useful for debugging. +

+

Other options: + +

-V
--version

Print the initdb version and exit. +

-?
--help

Show help about initdb command line + arguments, and exit. +

+

Environment

PGDATA

Specifies the directory where the database cluster is to be + stored; can be overridden using the -D option. +

This utility, like most other PostgreSQL utilities, + also uses the environment variables supported by libpq + (see Section 31.14). +

Notes

initdb can also be invoked via + pg_ctl initdb. +

See Also

pg_ctl, postgres

PrevHomeNext
PostgreSQL Server ApplicationsUppg_controldata
\ No newline at end of file diff --git a/doc/src/sgml/html/app-pg-ctl.html b/doc/src/sgml/html/app-pg-ctl.html new file mode 100644 index 000000000..e40cb4bc0 --- /dev/null +++ b/doc/src/sgml/html/app-pg-ctl.html @@ -0,0 +1,1507 @@ + +pg_ctl

pg_ctl

Name

pg_ctl -- initialize, start, stop, or control a PostgreSQL server

Synopsis

pg_ctl init[db] [-s] [-D datadir] [-o initdb-options]

pg_ctl start [-w] [-t seconds] [-s] [-D datadir] [-l filename] [-o options] [-p path] [-c]

pg_ctl stop [-W] [-t seconds] [-s] [-D datadir] [-m + s[mart] | f[ast] | i[mmediate] + ]

pg_ctl restart [-w] [-t seconds] [-s] [-D datadir] [-c] [-m + s[mart] | f[ast] | i[mmediate] + ] [-o options]

pg_ctl reload [-s] [-D datadir]

pg_ctl status [-D datadir]

pg_ctl promote [-s] [-D datadir]

pg_ctl kill signal_name process_id

pg_ctl register [-N servicename] [-U username] [-P password] [-D datadir] [-S + a[uto] | d[emand] + ] [-w] [-t seconds] [-s] [-o options]

pg_ctl unregister [-N servicename]

Description

pg_ctl is a utility for initializing a + PostgreSQL database cluster, starting, + stopping, or restarting the PostgreSQL + database server (postgres), or displaying the + status of a running server. Although the server can be started + manually, pg_ctl encapsulates tasks such + as redirecting log output and properly detaching from the terminal + and process group. It also provides convenient options for + controlled shutdown. +

The init or initdb mode creates a new + PostgreSQL database cluster. A database + cluster is a collection of databases that are managed by a single + server instance. This mode invokes the initdb + command. See initdb for details. +

In start mode, a new server is launched. The + server is started in the background, and its standard input is attached + to /dev/null (or nul on Windows). + On Unix-like systems, by default, the server's standard output and + standard error are sent to pg_ctl's + standard output (not standard error). The standard output of + pg_ctl should then be redirected to a + file or piped to another process such as a log rotating program + like rotatelogs; otherwise postgres + will write its output to the controlling terminal (from the + background) and will not leave the shell's process group. On + Windows, by default the server's standard output and standard error + are sent to the terminal. These default behaviors can be changed + by using -l to append the server's output to a log file. + Use of either -l or output redirection is recommended. +

In stop mode, the server that is running in + the specified data directory is shut down. Three different + shutdown methods can be selected with the -m + option. "Smart" mode (the default) waits for all active + clients to disconnect and any online backup to finish. + If the server is in hot standby, recovery and streaming replication + will be terminated once all clients have disconnected. + "Fast" mode does not wait for clients to disconnect and + will terminate an online backup in progress. All active transactions are + rolled back and clients are forcibly disconnected, then the + server is shut down. "Immediate" mode will abort + all server processes immediately, without a clean shutdown. + This will lead to a crash-recovery run on the next restart. +

restart mode effectively executes a stop followed + by a start. This allows changing the postgres + command-line options. +

reload mode simply sends the + postgres process a SIGHUP + signal, causing it to reread its configuration files + (postgresql.conf, + pg_hba.conf, etc.). This allows changing of + configuration-file options that do not require a complete restart + to take effect. +

status mode checks whether a server is running in + the specified data directory. If it is, the PID + and the command line options that were used to invoke it are + displayed. If the server is not running, the process returns an + exit status of 3. +

In promote mode, the standby server that is + running in the specified data directory is commanded to exit + recovery and begin read-write operations. +

kill mode allows you to send a signal to a specified + process. This is particularly valuable for Microsoft Windows + which does not have a kill command. Use + --help to see a list of supported signal names. +

register mode allows you to register a system service + on Microsoft Windows. The -S option + allows selection of service start type, either "auto" (start + service automatically on system startup) or "demand" (start + service on demand). +

unregister mode allows you to unregister a system service + on Microsoft Windows. This undoes the effects of the + register command. +

Options

-c
--core-file

Attempt to allow server crashes to produce core files, on platforms + where this is possible, by lifting any soft resource limit placed on + core files. + This is useful in debugging or diagnosing problems by allowing a + stack trace to be obtained from a failed server process. +

-D datadir
--pgdata datadir

Specifies the file system location of the database files. If + this is omitted, the environment variable + PGDATA is used. +

-l filename
--log filename

Append the server log output to + filename. If the file does not + exist, it is created. The umask is set to 077, + so access to the log file is disallowed to other users by default. +

-m mode
--mode mode

Specifies the shutdown mode. mode + can be smart, fast, or + immediate, or the first letter of one of + these three. If this is omitted, smart is used. +

-o options

Specifies options to be passed directly to the + postgres command. +

The options should usually be surrounded by single or double + quotes to ensure that they are passed through as a group. +

-o initdb-options

Specifies options to be passed directly to the + initdb command. +

The options should usually be surrounded by single or double + quotes to ensure that they are passed through as a group. +

-p path

Specifies the location of the postgres + executable. By default the postgres executable is taken from the same + directory as pg_ctl, or failing that, the hard-wired + installation directory. It is not necessary to use this + option unless you are doing something unusual and get errors + that the postgres executable was not found. +

In init mode, this option analogously + specifies the location of the initdb + executable. +

-s
--silent

Print only errors, no informational messages. +

-t
--timeout

The maximum number of seconds to wait when waiting for startup or + shutdown to complete. The default is 60 seconds. +

-V
--version

Print the pg_ctl version and exit. +

-w

Wait for the startup or shutdown to complete. + Waiting is the default option for shutdowns, but not startups. + When waiting for startup, pg_ctl repeatedly + attempts to connect to the server. + When waiting for shutdown, pg_ctl waits for + the server to remove its PID file. + pg_ctl returns an exit code based on the + success of the startup or shutdown. +

-W

Do not wait for startup or shutdown to complete. This is the + default for start and restart modes. +

-?
--help

Show help about pg_ctl command line + arguments, and exit. +

Options for Windows

-N servicename

Name of the system service to register. The name will be used + as both the service name and the display name. +

-P password

Password for the user to start the service. +

-S start-type

Start type of the system service to register. start-type can + be auto, or demand, or + the first letter of one of these two. If this is omitted, + auto is used. +

-U username

User name for the user to start the service. For domain users, use the + format DOMAIN\username. +

Environment

PGDATA

Default data directory location. +

pg_ctl, like most other PostgreSQL + utilities, + also uses the environment variables supported by libpq + (see Section 31.14). + For additional server variables, see postgres. +

Files

postmaster.pid

The existence of this file in the data directory is used to help + pg_ctl determine if the server is + currently running. +

postmaster.opts

If this file exists in the data directory, + pg_ctl (in restart mode) + will pass the contents of the file as options to + postgres, unless overridden + by the -o option. The contents of this file + are also displayed in status mode. +

Examples

Starting the Server

To start the server: +

$ pg_ctl start

+

To start the server, waiting until the server is + accepting connections: +

$ pg_ctl -w start

+

To start the server using port 5433, and + running without fsync, use: +

$ pg_ctl -o "-F -p 5433" start

Stopping the Server

To stop the server, use: +

$ pg_ctl stop

+ The -m option allows control over + how the server shuts down: +

$ pg_ctl stop -m fast

Restarting the Server

Restarting the server is almost equivalent to stopping the + server and starting it again, + except that pg_ctl saves and reuses the command line options that + were passed to the previously running instance. To restart + the server in the simplest form, use: +

$ pg_ctl restart

+

To restart the server, + waiting for it to shut down and restart: +

$ pg_ctl -w restart

+

To restart using port 5433, disabling fsync upon restart: +

$ pg_ctl -o "-F -p 5433" restart

Showing the Server Status

Here is sample status output from + pg_ctl: +

$ pg_ctl status
+pg_ctl: server is running (PID: 13718)
+/usr/local/pgsql/bin/postgres "-D" "/usr/local/pgsql/data" "-p" "5433" "-B" "128"

+ This is the command line that would be invoked in restart mode. +

See Also

initdb, postgres

PrevHomeNext
pg_controldataUppg_resetxlog
\ No newline at end of file diff --git a/doc/src/sgml/html/app-pg-dumpall.html b/doc/src/sgml/html/app-pg-dumpall.html new file mode 100644 index 000000000..ff11cdd80 --- /dev/null +++ b/doc/src/sgml/html/app-pg-dumpall.html @@ -0,0 +1,1171 @@ + +pg_dumpall

pg_dumpall

Name

pg_dumpall -- extract a PostgreSQL database cluster into a script file

Synopsis

pg_dumpall [connection-option...] [option...]

Description

pg_dumpall is a utility for writing out + ("dumping") all PostgreSQL databases + of a cluster into one script file. The script file contains + SQL commands that can be used as input to psql to restore the databases. It does this by + calling pg_dump for each database in a cluster. + pg_dumpall also dumps global objects + that are common to all databases. + (pg_dump does not save these objects.) + This currently includes information about database users and + groups, tablespaces, and properties such as access permissions + that apply to databases as a whole. +

Since pg_dumpall reads tables from all + databases you will most likely have to connect as a database + superuser in order to produce a complete dump. Also you will need + superuser privileges to execute the saved script in order to be + allowed to add users and groups, and to create databases. +

The SQL script will be written to the standard output. Use the + [-f|file] option or shell operators to redirect it into a file. +

pg_dumpall needs to connect several + times to the PostgreSQL server (once per + database). If you use password authentication it will ask for + a password each time. It is convenient to have a + ~/.pgpass file in such cases. See Section 31.15 for more information. +

Options

The following command-line options control the content and + format of the output. + +

-a
--data-only

Dump only the data, not the schema (data definitions). +

-c
--clean

Include SQL commands to clean (drop) databases before + recreating them. DROP commands for roles and + tablespaces are added as well. +

-f filename
--file=filename

Send output to the specified file. If this is omitted, the + standard output is used. +

-g
--globals-only

Dump only global objects (roles and tablespaces), no databases. +

-i
--ignore-version

A deprecated option that is now ignored. +

-o
--oids

Dump object identifiers (OIDs) as part of the + data for every table. Use this option if your application references + the OID + columns in some way (e.g., in a foreign key constraint). + Otherwise, this option should not be used. +

-O
--no-owner

Do not output commands to set + ownership of objects to match the original database. + By default, pg_dumpall issues + ALTER OWNER or + SET SESSION AUTHORIZATION + statements to set ownership of created schema elements. + These statements + will fail when the script is run unless it is started by a superuser + (or the same user that owns all of the objects in the script). + To make a script that can be restored by any user, but will give + that user ownership of all the objects, specify -O. +

-r
--roles-only

Dump only roles, no databases or tablespaces. +

-s
--schema-only

Dump only the object definitions (schema), not data. +

-S username
--superuser=username

Specify the superuser user name to use when disabling triggers. + This is only relevant if --disable-triggers is used. + (Usually, it's better to leave this out, and instead start the + resulting script as superuser.) +

-t
--tablespaces-only

Dump only tablespaces, no databases or roles. +

-v
--verbose

Specifies verbose mode. This will cause + pg_dumpall to output start/stop + times to the dump file, and progress messages to standard error. + It will also enable verbose output in pg_dump. +

-V
--version

Print the pg_dumpall version and exit. +

-x
--no-privileges
--no-acl

Prevent dumping of access privileges (grant/revoke commands). +

--binary-upgrade

This option is for use by in-place upgrade utilities. Its use + for other purposes is not recommended or supported. The + behavior of the option may change in future releases without + notice. +

--column-inserts
--attribute-inserts

Dump data as INSERT commands with explicit + column names (INSERT INTO + table + (column, ...) VALUES + ...). This will make restoration very slow; it is mainly + useful for making dumps that can be loaded into + non-PostgreSQL databases. +

--disable-dollar-quoting

This option disables the use of dollar quoting for function bodies, + and forces them to be quoted using SQL standard string syntax. +

--disable-triggers

This option is only relevant when creating a data-only dump. + It instructs pg_dumpall to include commands + to temporarily disable triggers on the target tables while + the data is reloaded. Use this if you have referential + integrity checks or other triggers on the tables that you + do not want to invoke during data reload. +

Presently, the commands emitted for --disable-triggers + must be done as superuser. So, you should also specify + a superuser name with -S, or preferably be careful to + start the resulting script as a superuser. +

--inserts

Dump data as INSERT commands (rather + than COPY). This will make restoration very slow; + it is mainly useful for making dumps that can be loaded into + non-PostgreSQL databases. Note that + the restore might fail altogether if you have rearranged column order. + The --column-inserts option is safer, though even + slower. +

--lock-wait-timeout=timeout

Do not wait forever to acquire shared table locks at the beginning of + the dump. Instead, fail if unable to lock a table within the specified + timeout. The timeout may be + specified in any of the formats accepted by SET + statement_timeout. Allowed values vary depending on the server + version you are dumping from, but an integer number of milliseconds + is accepted by all versions since 7.3. This option is ignored when + dumping from a pre-7.3 server. +

--no-security-labels

Do not dump security labels. +

--no-tablespaces

Do not output commands to create tablespaces nor select tablespaces + for objects. + With this option, all objects will be created in whichever + tablespace is the default during restore. +

--no-unlogged-table-data

Do not dump the contents of unlogged tables. This option has no + effect on whether or not the table definitions (schema) are dumped; + it only suppresses dumping the table data. +

--quote-all-identifiers

Force quoting of all identifiers. This may be useful when dumping a + database for migration to a future version that may have introduced + additional keywords. +

--use-set-session-authorization

Output SQL-standard SET SESSION AUTHORIZATION commands + instead of ALTER OWNER commands to determine object + ownership. This makes the dump more standards compatible, but + depending on the history of the objects in the dump, might not restore + properly. +

-?
--help

Show help about pg_dumpall command line + arguments, and exit. +

+

The following command-line options control the database connection parameters. + +

-h host
--host=host

Specifies the host name of the machine on which the database + server is running. If the value begins with a slash, it is + used as the directory for the Unix domain socket. The default + is taken from the PGHOST environment variable, + if set, else a Unix domain socket connection is attempted. +

-l dbname
--database=dbname

Specifies the name of the database to connect to to dump global + objects and discover what other databases should be dumped. If + not specified, the postgres database will be used, + and if that does not exist, template1 will be used. +

-p port
--port=port

Specifies the TCP port or local Unix domain socket file + extension on which the server is listening for connections. + Defaults to the PGPORT environment variable, if + set, or a compiled-in default. +

-U username
--username=username

User name to connect as. +

-w
--no-password

Never issue a password prompt. If the server requires + password authentication and a password is not available by + other means such as a .pgpass file, the + connection attempt will fail. This option can be useful in + batch jobs and scripts where no user is present to enter a + password. +

-W
--password

Force pg_dumpall to prompt for a + password before connecting to a database. +

This option is never essential, since + pg_dumpall will automatically prompt + for a password if the server demands password authentication. + However, pg_dumpall will waste a + connection attempt finding out that the server wants a password. + In some cases it is worth typing -W to avoid the extra + connection attempt. +

Note that the password prompt will occur again for each database + to be dumped. Usually, it's better to set up a + ~/.pgpass file than to rely on manual password entry. +

--role=rolename

Specifies a role name to be used to create the dump. + This option causes pg_dumpall to issue a + SET ROLE rolename + command after connecting to the database. It is useful when the + authenticated user (specified by -U) lacks privileges + needed by pg_dumpall, but can switch to a role with + the required rights. Some installations have a policy against + logging in directly as a superuser, and use of this option allows + dumps to be made without violating the policy. +

+

Environment

PGHOST
PGOPTIONS
PGPORT
PGUSER

Default connection parameters +

This utility, like most other PostgreSQL utilities, + also uses the environment variables supported by libpq + (see Section 31.14). +

Notes

Since pg_dumpall calls + pg_dump internally, some diagnostic + messages will refer to pg_dump. +

Once restored, it is wise to run ANALYZE on each + database so the optimizer has useful statistics. You + can also run vacuumdb -a -z to analyze all + databases. +

pg_dumpall requires all needed + tablespace directories to exist before the restore; otherwise, + database creation will fail for databases in non-default + locations. +

Examples

To dump all databases: + +

$ pg_dumpall > db.out

+

To reload database(s) from this file, you can use: +

$ psql -f db.out postgres

+ (It is not important to which database you connect here since the + script file created by pg_dumpall will + contain the appropriate commands to create and connect to the saved + databases.) +

See Also

Check pg_dump for details on possible + error conditions. +


PrevHomeNext
pg_dumpUppg_receivexlog
\ No newline at end of file diff --git a/doc/src/sgml/html/app-pgbasebackup.html b/doc/src/sgml/html/app-pgbasebackup.html new file mode 100644 index 000000000..258a8d64b --- /dev/null +++ b/doc/src/sgml/html/app-pgbasebackup.html @@ -0,0 +1,1092 @@ + +pg_basebackup

pg_basebackup

Name

pg_basebackup -- take a base backup of a PostgreSQL cluster

Synopsis

pg_basebackup [option...]

Description +

pg_basebackup is used to take base backups of + a running PostgreSQL database cluster. These + are taken without affecting other clients to the database, and can be used + both for point-in-time recovery (see Section 24.3) + and as the starting point for a log shipping or streaming replication standby + servers (see Section 25.2). +

pg_basebackup makes a binary copy of the database + cluster files, while making sure the system is automatically put in and + out of backup mode automatically. Backups are always taken of the entire + database cluster, it is not possible to back up individual databases or + database objects. For individual database backups, a tool such as + pg_dump must be used. +

The backup is made over a regular PostgreSQL + connection, and uses the replication protocol. The connection must be made + with a superuser or a user having REPLICATION + permissions (see Section 20.2), + and pg_hba.conf must explicitly permit the replication + connection. The server must also be configured + with max_wal_senders set high enough to leave at least + one session available for the backup. +

There can be multiple pg_basebackups running at the same time, but it is + better from a performance point of view to take only one backup, and copy + the result. +

pg_basebackup can make a base backup from + not only the master but also the standby. To take a backup from the standby, + set up the standby so that it can accept replication connections (that is, set + max_wal_senders and hot_standby, + and configure host-based authentication). + You will also need to enable full_page_writes on the master. +

Note that there are some limitations in an online backup from the standby: + +

  • The backup history file is not created in the database cluster backed up. +

  • There is no guarantee that all WAL files required for the backup are archived + at the end of backup. If you are planning to use the backup for an archive + recovery and want to ensure that all required files are available at that moment, + you need to include them into the backup by using -x option. +

  • If the standby is promoted to the master during online backup, the backup fails. +

  • All WAL records required for the backup must contain sufficient full-page writes, + which requires you to enable full_page_writes on the master and + not to use the tool like pg_compresslog as + archive_command to remove full-page writes from WAL files. +

+

Options

The following command-line options control the location and format of the + output. + +

-D directory
--pgdata=directory

Directory to write the output to. + pg_basebackup will create the directory and + any parent directories if necessary. The directory may already exist, + but it is an error if the directory already exists and is not empty. +

When the backup is in tar mode, and the directory is specified as + - (dash), the tar file will be written to + stdout. +

This option is required. +

-F format
--format=format

Selects the format for the output. format + can be one of the following: + +

p
plain

Write the output as plain files, with the same layout as the + current data directory and tablespaces. When the cluster has + no additional tablespaces, the whole database will be placed in + the target directory. If the cluster contains additional + tablespaces, the main data directory will be placed in the + target directory, but all other tablespaces will be placed + in the same absolute path as they have on the server. +

This is the default format. +

t
tar

Write the output as tar files in the target directory. The main + data directory will be written to a file named + base.tar, and all other tablespaces will + be named after the tablespace OID. +

If the value - (dash) is specified as + target directory, the tar contents will be written to + standard output, suitable for piping to for example + gzip. This is only possible if + the cluster has no additional tablespaces. +

-x
--xlog

Using this option is equivalent of using -X with + method fetch. +

-X method
--xlog-method=method

Includes the required transaction log files (WAL files) in the + backup. This will include all transaction logs generated during + the backup. If this option is specified, it is possible to start + a postmaster directly in the extracted directory without the need + to consult the log archive, thus making this a completely standalone + backup. +

The following methods for collecting the transaction logs are + supported: + +

f
fetch

The transaction log files are collected at the end of the backup. + Therefore, it is necessary for the + wal_keep_segments parameter to be set high + enough that the log is not removed before the end of the backup. + If the log has been rotated when it's time to transfer it, the + backup will fail and be unusable. +

s
stream

Stream the transaction log while the backup is created. This will + open a second connection to the server and start streaming the + transaction log in parallel while running the backup. Therefore, + it will use up two slots configured by the + max_wal_senders parameter. As long as the + client can keep up with transaction log received, using this mode + requires no extra transaction logs to be saved on the master. +

+

-z
--gzip

Enables gzip compression of tar file output, with the default + compression level. Compression is only available when using + the tar format. +

-Z level
--compress=level

Enables gzip compression of tar file output, and specifies the + compression level (1 through 9, 9 being best + compression). Compression is only available when using the tar + format. +

+

The following command-line options control the generation of the + backup and the running of the program. + +

-c fast|spread
--checkpoint=fast|spread

Sets checkpoint mode to fast or spread (default). +

-l label
--label=label

Sets the label for the backup. If none is specified, a default value of + "pg_basebackup base backup" will be used. +

-P
--progress

Enables progress reporting. Turning this on will deliver an approximate + progress report during the backup. Since the database may change during + the backup, this is only an approximation and may not end at exactly + 100%. In particular, when WAL log is included in the + backup, the total amount of data cannot be estimated in advance, and + in this case the estimated target size will increase once it passes the + total estimate without WAL. +

When this is enabled, the backup will start by enumerating the size of + the entire database, and then go back and send the actual contents. + This may make the backup take slightly longer, and in particular it + will take longer before the first data is sent. +

-v
--verbose

Enables verbose mode. Will output some extra steps during startup and + shutdown, as well as show the exact file name that is currently being + processed if progress reporting is also enabled. +

+

The following command-line options control the database connection parameters. + +

-h host
--host=host

Specifies the host name of the machine on which the server is + running. If the value begins with a slash, it is used as the + directory for the Unix domain socket. The default is taken + from the PGHOST environment variable, if set, + else a Unix domain socket connection is attempted. +

-p port
--port=port

Specifies the TCP port or local Unix domain socket file + extension on which the server is listening for connections. + Defaults to the PGPORT environment variable, if + set, or a compiled-in default. +

-s interval
--status-interval=interval

Specifies the number of seconds between status packets sent back to the + server. This is required when streaming the transaction log (using + --xlog=stream) if replication timeout is configured + on the server, and allows for easier monitoring. A value of zero disables + the status updates completely. The default value is 10 seconds. +

-U username
--username=username

User name to connect as. +

-w
--no-password

Never issue a password prompt. If the server requires + password authentication and a password is not available by + other means such as a .pgpass file, the + connection attempt will fail. This option can be useful in + batch jobs and scripts where no user is present to enter a + password. +

-W
--password

Force pg_basebackup to prompt for a + password before connecting to a database. +

This option is never essential, since + pg_basebackup will automatically prompt + for a password if the server demands password authentication. + However, pg_basebackup will waste a + connection attempt finding out that the server wants a password. + In some cases it is worth typing -W to avoid the extra + connection attempt. +

+

Other options are also available: + +

-V
--version

Print the pg_basebackup version and exit. +

-?
--help

Show help about pg_basebackup command line + arguments, and exit. +

+

Environment

This utility, like most other PostgreSQL utilities, + uses the environment variables supported by libpq + (see Section 31.14). +

Notes

The backup will include all files in the data directory and tablespaces, + including the configuration files and any additional files placed in the + directory by third parties. Only regular files and directories are allowed + in the data directory, no symbolic links or special device files. +

The way PostgreSQL manages tablespaces, the path + for all additional tablespaces must be identical whenever a backup is + restored. The main data directory, however, is relocatable to any location. +

Examples

To create a base backup of the server at mydbserver + and store it in the local directory + /usr/local/pgsql/data: +

$ pg_basebackup -h mydbserver -D /usr/local/pgsql/data

+

To create a backup of the local server with one compressed + tar file for each tablespace, and store it in the directory + backup, showing a progress report while running: +

$ pg_basebackup -D backup -Ft -z -P

+

To create a backup of a single-tablespace local database and compress + this with bzip2: +

$ pg_basebackup -D - -Ft | bzip2 > backup.tar.bz2

+ (This command will fail if there are multiple tablespaces in the + database.) +

See Also

pg_dump

PrevHomeNext
ecpgUppg_config
\ No newline at end of file diff --git a/doc/src/sgml/html/app-pgconfig.html b/doc/src/sgml/html/app-pgconfig.html new file mode 100644 index 000000000..939396e74 --- /dev/null +++ b/doc/src/sgml/html/app-pgconfig.html @@ -0,0 +1,713 @@ + +pg_config

pg_config

Name

pg_config -- retrieve information about the installed version of PostgreSQL

Synopsis

pg_config [option...]

Description

The pg_config utility prints configuration parameters + of the currently installed version of PostgreSQL. It is + intended, for example, to be used by software packages that want to interface + to PostgreSQL to facilitate finding the required header files + and libraries. +

Options

To use pg_config, supply one or more of the following + options: +

--bindir

Print the location of user executables. Use this, for example, to find + the psql program. This is normally also the location + where the pg_config program resides. +

--docdir

Print the location of documentation files. +

--htmldir

Print the location of HTML documentation files. +

--includedir

Print the location of C header files of the client interfaces. +

--pkgincludedir

Print the location of other C header files. +

--includedir-server

Print the location of C header files for server programming. +

--libdir

Print the location of object code libraries. +

--pkglibdir

Print the location of dynamically loadable modules, or where + the server would search for them. (Other + architecture-dependent data files might also be installed in this + directory.) +

--localedir

Print the location of locale support files. (This will be an empty + string if locale support was not configured when + PostgreSQL was built.) +

--mandir

Print the location of manual pages. +

--sharedir

Print the location of architecture-independent support files. +

--sysconfdir

Print the location of system-wide configuration files. +

--pgxs

Print the location of extension makefiles. +

--configure

Print the options that were given to the configure + script when PostgreSQL was configured for building. + This can be used to reproduce the identical configuration, or + to find out with what options a binary package was built. (Note + however that binary packages often contain vendor-specific custom + patches.) See also the examples below. +

--cc

Print the value of the CC variable that was used for building + PostgreSQL. This shows the C compiler used. +

--cppflags

Print the value of the CPPFLAGS variable that was used for building + PostgreSQL. This shows C compiler switches needed + at preprocessing time (typically, -I switches). +

--cflags

Print the value of the CFLAGS variable that was used for building + PostgreSQL. This shows C compiler switches. +

--cflags_sl

Print the value of the CFLAGS_SL variable that was used for building + PostgreSQL. This shows extra C compiler switches + used for building shared libraries. +

--ldflags

Print the value of the LDFLAGS variable that was used for building + PostgreSQL. This shows linker switches. +

--ldflags_ex

Print the value of the LDFLAGS_EX variable that was used for building + PostgreSQL. This shows linker switches + used for building executables only. +

--ldflags_sl

Print the value of the LDFLAGS_SL variable that was used for building + PostgreSQL. This shows linker switches + used for building shared libraries only. +

--libs

Print the value of the LIBS variable that was used for building + PostgreSQL. This normally contains -l + switches for external libraries linked into PostgreSQL. +

--version

Print the version of PostgreSQL. +

-?
--help

Show help about pg_config command line + arguments, and exit. +

+ + If more than one option is given, the information is printed in that order, + one item per line. If no options are given, all available information + is printed, with labels. +

Notes

The option --includedir-server was added in + PostgreSQL 7.2. In prior releases, the server include files were + installed in the same location as the client headers, which could + be queried with the option --includedir. To make your + package handle both cases, try the newer option first and test the + exit status to see whether it succeeded. +

The options --docdir, --pkgincludedir, + --localedir, --mandir, + --sharedir, --sysconfdir, + --cc, --cppflags, + --cflags, --cflags_sl, + --ldflags, --ldflags_sl, + and --libs were added in PostgreSQL 8.1. + The option --htmldir was added in PostgreSQL 8.4. + The option --ldflags_ex was added in PostgreSQL 9.0. +

In releases prior to PostgreSQL 7.1, before + pg_config came to be, a method for finding the + equivalent configuration information did not exist. +

Example

To reproduce the build configuration of the current PostgreSQL + installation, run the following command: +

eval ./configure `pg_config --configure`

+ The output of pg_config --configure contains + shell quotation marks so arguments with spaces are represented + correctly. Therefore, using eval is required + for proper results. +


PrevHomeNext
pg_basebackupUppg_dump
\ No newline at end of file diff --git a/doc/src/sgml/html/app-pgcontroldata.html b/doc/src/sgml/html/app-pgcontroldata.html new file mode 100644 index 000000000..5161ae8a2 --- /dev/null +++ b/doc/src/sgml/html/app-pgcontroldata.html @@ -0,0 +1,273 @@ + +pg_controldata

pg_controldata

Name

pg_controldata -- display control information of a PostgreSQL database cluster

Synopsis

pg_controldata [option] [datadir]

Description

pg_controldata prints information initialized during + initdb, such as the catalog version. + It also shows information about write-ahead logging and checkpoint + processing. This information is cluster-wide, and not specific to any one + database. +

This utility can only be run by the user who initialized the cluster because + it requires read access to the data directory. + You can specify the data directory on the command line, or use + the environment variable PGDATA. This utility supports the options + -V and --version, which print the + pg_controldata version and exit. It also + supports options -? and --help, which output the + supported arguments. +

Environment

PGDATA

Default data directory location +


PrevHomeNext
initdbUppg_ctl
\ No newline at end of file diff --git a/doc/src/sgml/html/app-pgdump.html b/doc/src/sgml/html/app-pgdump.html new file mode 100644 index 000000000..86dabe2ca --- /dev/null +++ b/doc/src/sgml/html/app-pgdump.html @@ -0,0 +1,2290 @@ + +pg_dump

pg_dump

Name

pg_dump --  extract a PostgreSQL database into a script file or other archive file +

Synopsis

pg_dump [connection-option...] [option...] [dbname]

Description +

pg_dump is a utility for backing up a + PostgreSQL database. It makes consistent + backups even if the database is being used concurrently. + pg_dump does not block other users + accessing the database (readers or writers). +

Dumps can be output in script or archive file formats. Script + dumps are plain-text files containing the SQL commands required + to reconstruct the database to the state it was in at the time it was + saved. To restore from such a script, feed it to psql. Script files + can be used to reconstruct the database even on other machines and + other architectures; with some modifications, even on other SQL + database products. +

The alternative archive file formats must be used with + pg_restore to rebuild the database. They + allow pg_restore to be selective about + what is restored, or even to reorder the items prior to being + restored. + The archive file formats are designed to be portable across + architectures. +

When used with one of the archive file formats and combined with + pg_restore, + pg_dump provides a flexible archival and + transfer mechanism. pg_dump can be used to + backup an entire database, then pg_restore + can be used to examine the archive and/or select which parts of the + database are to be restored. The most flexible output file format is + the "custom" format (-Fc). It allows + for selection and reordering of all archived items, and is compressed + by default. +

While running pg_dump, one should examine the + output for any warnings (printed on standard error), especially in + light of the limitations listed below. +

Options

The following command-line options control the content and + format of the output. + +

dbname

Specifies the name of the database to be dumped. If this is + not specified, the environment variable + PGDATABASE is used. If that is not set, the + user name specified for the connection is used. +

-a
--data-only

Dump only the data, not the schema (data definitions). + Table data, large objects, and sequence values are dumped. +

This option is similar to, but for historical reasons not identical + to, specifying --section=data. +

-b
--blobs

Include large objects in the dump. This is the default behavior + except when --schema, --table, or + --schema-only is specified, so the -b + switch is only useful to add large objects to selective dumps. +

-c
--clean

Output commands to clean (drop) + database objects prior to outputting the commands for creating them. + (Restore might generate some harmless error messages, if any objects + were not present in the destination database.) +

This option is only meaningful for the plain-text format. For + the archive formats, you can specify the option when you + call pg_restore. +

-C
--create

Begin the output with a command to create the + database itself and reconnect to the created database. (With a + script of this form, it doesn't matter which database in the + destination installation you connect to before running the script.) + If --clean is also specified, the script drops and + recreates the target database before reconnecting to it. +

This option is only meaningful for the plain-text format. For + the archive formats, you can specify the option when you + call pg_restore. +

-E encoding
--encoding=encoding

Create the dump in the specified character set encoding. By default, + the dump is created in the database encoding. (Another way to get the + same result is to set the PGCLIENTENCODING environment + variable to the desired dump encoding.) +

-f file
--file=file

Send output to the specified file. This parameter can be omitted for + file based output formats, in which case the standard output is used. + It must be given for the directory output format however, where it + specifies the target directory instead of a file. In this case the + directory is created by pg_dump and must not exist + before. +

-F format
--format=format

Selects the format of the output. + format can be one of the following: + +

p
plain

Output a plain-text SQL script file (the default). +

c
custom

Output a custom-format archive suitable for input into + pg_restore. + Together with the directory output format, this is the most flexible + output format in that it allows manual selection and reordering of + archived items during restore. This format is also compressed by + default. +

d
directory

Output a directory-format archive suitable for input into + pg_restore. This will create a directory + with one file for each table and blob being dumped, plus a + so-called Table of Contents file describing the dumped objects in a + machine-readable format that pg_restore + can read. A directory format archive can be manipulated with + standard Unix tools; for example, files in an uncompressed archive + can be compressed with the gzip tool. + This format is compressed by default. +

t
tar

Output a tar-format archive suitable for input + into pg_restore. The tar-format is + compatible with the directory-format; extracting a tar-format + archive produces a valid directory-format archive. + However, the tar-format does not support compression and has a + limit of 8 GB on the size of individual tables. Also, the relative + order of table data items cannot be changed during restore. +

-i
--ignore-version

A deprecated option that is now ignored. +

-n schema
--schema=schema

Dump only schemas matching schema; this selects both the + schema itself, and all its contained objects. When this option is + not specified, all non-system schemas in the target database will be + dumped. Multiple schemas can be + selected by writing multiple -n switches. Also, the + schema parameter is + interpreted as a pattern according to the same rules used by + psql's \d commands (see Patterns), + so multiple schemas can also be selected by writing wildcard characters + in the pattern. When using wildcards, be careful to quote the pattern + if needed to prevent the shell from expanding the wildcards; see + Examples. +

Note: When -n is specified, pg_dump + makes no attempt to dump any other database objects that the selected + schema(s) might depend upon. Therefore, there is no guarantee + that the results of a specific-schema dump can be successfully + restored by themselves into a clean database. +

Note: Non-schema objects such as blobs are not dumped when -n is + specified. You can add blobs back to the dump with the + --blobs switch. +

-N schema
--exclude-schema=schema

Do not dump any schemas matching the schema pattern. The pattern is + interpreted according to the same rules as for -n. + -N can be given more than once to exclude schemas + matching any of several patterns. +

When both -n and -N are given, the behavior + is to dump just the schemas that match at least one -n + switch but no -N switches. If -N appears + without -n, then schemas matching -N are + excluded from what is otherwise a normal dump. +

-o
--oids

Dump object identifiers (OIDs) as part of the + data for every table. Use this option if your application references + the OID + columns in some way (e.g., in a foreign key constraint). + Otherwise, this option should not be used. +

-O
--no-owner

Do not output commands to set + ownership of objects to match the original database. + By default, pg_dump issues + ALTER OWNER or + SET SESSION AUTHORIZATION + statements to set ownership of created database objects. + These statements + will fail when the script is run unless it is started by a superuser + (or the same user that owns all of the objects in the script). + To make a script that can be restored by any user, but will give + that user ownership of all the objects, specify -O. +

This option is only meaningful for the plain-text format. For + the archive formats, you can specify the option when you + call pg_restore. +

-R
--no-reconnect

This option is obsolete but still accepted for backwards + compatibility. +

-s
--schema-only

Dump only the object definitions (schema), not data. +

This option is the inverse of --data-only. + It is similar to, but for historical reasons not identical to, + specifying + --section=pre-data --section=post-data. +

(Do not confuse this with the --schema option, which + uses the word "schema" in a different meaning.) +

To exclude table data for only a subset of tables in the database, + see --exclude-table-data. +

-S username
--superuser=username

Specify the superuser user name to use when disabling triggers. + This is only relevant if --disable-triggers is used. + (Usually, it's better to leave this out, and instead start the + resulting script as superuser.) +

-t table
--table=table

Dump only tables (or views or sequences or foreign tables) matching + table. Multiple tables + can be selected by writing multiple -t switches. Also, the + table parameter is + interpreted as a pattern according to the same rules used by + psql's \d commands (see Patterns), + so multiple tables can also be selected by writing wildcard characters + in the pattern. When using wildcards, be careful to quote the pattern + if needed to prevent the shell from expanding the wildcards; see + Examples. +

The -n and -N switches have no effect when + -t is used, because tables selected by -t will + be dumped regardless of those switches, and non-table objects will not + be dumped. +

Note: When -t is specified, pg_dump + makes no attempt to dump any other database objects that the selected + table(s) might depend upon. Therefore, there is no guarantee + that the results of a specific-table dump can be successfully + restored by themselves into a clean database. +

Note: The behavior of the -t switch is not entirely upward + compatible with pre-8.2 PostgreSQL + versions. Formerly, writing -t tab would dump all + tables named tab, but now it just dumps whichever one + is visible in your default search path. To get the old behavior + you can write -t '*.tab'. Also, you must write something + like -t sch.tab to select a table in a particular schema, + rather than the old locution of -n sch -t tab. +

-T table
--exclude-table=table

Do not dump any tables matching the table pattern. The pattern is + interpreted according to the same rules as for -t. + -T can be given more than once to exclude tables + matching any of several patterns. +

When both -t and -T are given, the behavior + is to dump just the tables that match at least one -t + switch but no -T switches. If -T appears + without -t, then tables matching -T are + excluded from what is otherwise a normal dump. +

-v
--verbose

Specifies verbose mode. This will cause + pg_dump to output detailed object + comments and start/stop times to the dump file, and progress + messages to standard error. +

-V
--version

Print the pg_dump version and exit. +

-x
--no-privileges
--no-acl

Prevent dumping of access privileges (grant/revoke commands). +

-Z 0..9
--compress=0..9

Specify the compression level to use. Zero means no compression. + For the custom archive format, this specifies compression of + individual table-data segments, and the default is to compress + at a moderate level. + For plain text output, setting a nonzero compression level causes + the entire output file to be compressed, as though it had been + fed through gzip; but the default is not to compress. + The tar archive format currently does not support compression at all. +

--binary-upgrade

This option is for use by in-place upgrade utilities. Its use + for other purposes is not recommended or supported. The + behavior of the option may change in future releases without + notice. +

--column-inserts
--attribute-inserts

Dump data as INSERT commands with explicit + column names (INSERT INTO + table + (column, ...) VALUES + ...). This will make restoration very slow; it is mainly + useful for making dumps that can be loaded into + non-PostgreSQL databases. + However, since this option generates a separate command for each row, + an error in reloading a row causes only that row to be lost rather + than the entire table contents. +

--disable-dollar-quoting

This option disables the use of dollar quoting for function bodies, + and forces them to be quoted using SQL standard string syntax. +

--disable-triggers

This option is only relevant when creating a data-only dump. + It instructs pg_dump to include commands + to temporarily disable triggers on the target tables while + the data is reloaded. Use this if you have referential + integrity checks or other triggers on the tables that you + do not want to invoke during data reload. +

Presently, the commands emitted for --disable-triggers + must be done as superuser. So, you should also specify + a superuser name with -S, or preferably be careful to + start the resulting script as a superuser. +

This option is only meaningful for the plain-text format. For + the archive formats, you can specify the option when you + call pg_restore. +

--exclude-table-data=table

Do not dump data for any tables matching the table pattern. The pattern is + interpreted according to the same rules as for -t. + --exclude-table-data can be given more than once to + exclude tables matching any of several patterns. This option is + useful when you need the definition of a particular table even + though you do not need the data in it. +

To exclude data for all tables in the database, see --schema-only. +

--inserts

Dump data as INSERT commands (rather + than COPY). This will make restoration very slow; + it is mainly useful for making dumps that can be loaded into + non-PostgreSQL databases. + However, since this option generates a separate command for each row, + an error in reloading a row causes only that row to be lost rather + than the entire table contents. + Note that + the restore might fail altogether if you have rearranged column order. + The --column-inserts option is safe against column + order changes, though even slower. +

--lock-wait-timeout=timeout

Do not wait forever to acquire shared table locks at the beginning of + the dump. Instead fail if unable to lock a table within the specified + timeout. The timeout may be + specified in any of the formats accepted by SET + statement_timeout. (Allowed values vary depending on the server + version you are dumping from, but an integer number of milliseconds + is accepted by all versions since 7.3. This option is ignored when + dumping from a pre-7.3 server.) +

--no-security-labels

Do not dump security labels. +

--no-tablespaces

Do not output commands to select tablespaces. + With this option, all objects will be created in whichever + tablespace is the default during restore. +

This option is only meaningful for the plain-text format. For + the archive formats, you can specify the option when you + call pg_restore. +

--no-unlogged-table-data

Do not dump the contents of unlogged tables. This option has no + effect on whether or not the table definitions (schema) are dumped; + it only suppresses dumping the table data. +

--quote-all-identifiers

Force quoting of all identifiers. This may be useful when dumping a + database for migration to a future version that may have introduced + additional keywords. +

--section=sectionname

Only dump the named section. The section name can be + pre-data, data, or post-data. + This option can be specified more than once to select multiple + sections. The default is to dump all sections. +

The data section contains actual table data, large-object + contents, and sequence values. + Post-data items include definitions of indexes, triggers, rules, + and constraints other than validated check constraints. + Pre-data items include all other data definition items. +

--serializable-deferrable

Use a serializable transaction for the dump, to + ensure that the snapshot used is consistent with later database + states; but do this by waiting for a point in the transaction stream + at which no anomalies can be present, so that there isn't a risk of + the dump failing or causing other transactions to roll back with a + serialization_failure. See Chapter 13 + for more information about transaction isolation and concurrency + control. +

This option is not beneficial for a dump which is intended only for + disaster recovery. It could be useful for a dump used to load a + copy of the database for reporting or other read-only load sharing + while the original database continues to be updated. Without it the + dump may reflect a state which is not consistent with any serial + execution of the transactions eventually committed. For example, if + batch processing techniques are used, a batch may show as closed in + the dump without all of the items which are in the batch appearing. +

This option will make no difference if there are no read-write + transactions active when pg_dump is started. If read-write + transactions are active, the start of the dump may be delayed for an + indeterminate length of time. Once running, performance with or + without the switch is the same. +

--use-set-session-authorization

Output SQL-standard SET SESSION AUTHORIZATION commands + instead of ALTER OWNER commands to determine object + ownership. This makes the dump more standards-compatible, but + depending on the history of the objects in the dump, might not restore + properly. Also, a dump using SET SESSION AUTHORIZATION + will certainly require superuser privileges to restore correctly, + whereas ALTER OWNER requires lesser privileges. +

-?
--help

Show help about pg_dump command line + arguments, and exit. +

+

The following command-line options control the database connection parameters. + +

-h host
--host=host

Specifies the host name of the machine on which the server is + running. If the value begins with a slash, it is used as the + directory for the Unix domain socket. The default is taken + from the PGHOST environment variable, if set, + else a Unix domain socket connection is attempted. +

-p port
--port=port

Specifies the TCP port or local Unix domain socket file + extension on which the server is listening for connections. + Defaults to the PGPORT environment variable, if + set, or a compiled-in default. +

-U username
--username=username

User name to connect as. +

-w
--no-password

Never issue a password prompt. If the server requires + password authentication and a password is not available by + other means such as a .pgpass file, the + connection attempt will fail. This option can be useful in + batch jobs and scripts where no user is present to enter a + password. +

-W
--password

Force pg_dump to prompt for a + password before connecting to a database. +

This option is never essential, since + pg_dump will automatically prompt + for a password if the server demands password authentication. + However, pg_dump will waste a + connection attempt finding out that the server wants a password. + In some cases it is worth typing -W to avoid the extra + connection attempt. +

--role=rolename

Specifies a role name to be used to create the dump. + This option causes pg_dump to issue a + SET ROLE rolename + command after connecting to the database. It is useful when the + authenticated user (specified by -U) lacks privileges + needed by pg_dump, but can switch to a role with + the required rights. Some installations have a policy against + logging in directly as a superuser, and use of this option allows + dumps to be made without violating the policy. +

+

Environment

PGDATABASE
PGHOST
PGOPTIONS
PGPORT
PGUSER

Default connection parameters. +

This utility, like most other PostgreSQL utilities, + also uses the environment variables supported by libpq + (see Section 31.14). +

Diagnostics

pg_dump internally executes + SELECT statements. If you have problems running + pg_dump, make sure you are able to + select information from the database using, for example, psql. Also, any default connection settings and environment + variables used by the libpq front-end + library will apply. +

The database activity of pg_dump is + normally collected by the statistics collector. If this is + undesirable, you can set parameter track_counts + to false via PGOPTIONS or the ALTER + USER command. +

Notes

If your database cluster has any local additions to the template1 database, + be careful to restore the output of pg_dump into a + truly empty database; otherwise you are likely to get errors due to + duplicate definitions of the added objects. To make an empty database + without any local additions, copy from template0 not template1, + for example: +

CREATE DATABASE foo WITH TEMPLATE template0;

+

When a data-only dump is chosen and the option --disable-triggers + is used, pg_dump emits commands + to disable triggers on user tables before inserting the data, + and then commands to re-enable them after the data has been + inserted. If the restore is stopped in the middle, the system + catalogs might be left in the wrong state. +

Members of tar archives are limited to a size less than 8 GB. + (This is an inherent limitation of the tar file format.) Therefore + this format cannot be used if the textual representation of any one table + exceeds that size. The total size of a tar archive and any of the + other output formats is not limited, except possibly by the + operating system. +

The dump file produced by pg_dump + does not contain the statistics used by the optimizer to make + query planning decisions. Therefore, it is wise to run + ANALYZE after restoring from a dump file + to ensure optimal performance; see Section 23.1.3 + and Section 23.1.6 for more information. + The dump file also does not + contain any ALTER DATABASE ... SET commands; + these settings are dumped by pg_dumpall, + along with database users and other installation-wide settings. +

Because pg_dump is used to transfer data + to newer versions of PostgreSQL, the output of + pg_dump can be expected to load into + PostgreSQL server versions newer than + pg_dump's version. pg_dump can also + dump from PostgreSQL servers older than its own version. + (Currently, servers back to version 7.0 are supported.) + However, pg_dump cannot dump from + PostgreSQL servers newer than its own major version; + it will refuse to even try, rather than risk making an invalid dump. + Also, it is not guaranteed that pg_dump's output can + be loaded into a server of an older major version — not even if the + dump was taken from a server of that version. Loading a dump file + into an older server may require manual editing of the dump file + to remove syntax not understood by the older server. +

Examples

To dump a database called mydb into a SQL-script file: +

$ pg_dump mydb > db.sql

+

To reload such a script into a (freshly created) database named + newdb: + +

$ psql -d newdb -f db.sql

+

To dump a database into a custom-format archive file: + +

$ pg_dump -Fc mydb > db.dump

+

To dump a database into a directory-format archive: + +

$ pg_dump -Fd mydb -f dumpdir

+

To reload an archive file into a (freshly created) database named + newdb: + +

$ pg_restore -d newdb db.dump

+

To dump a single table named mytab: + +

$ pg_dump -t mytab mydb > db.sql

+

To dump all tables whose names start with emp in the + detroit schema, except for the table named + employee_log: + +

$ pg_dump -t 'detroit.emp*' -T detroit.employee_log mydb > db.sql

+

To dump all schemas whose names start with east or + west and end in gsm, excluding any schemas whose + names contain the word test: + +

$ pg_dump -n 'east*gsm' -n 'west*gsm' -N '*test*' mydb > db.sql

+

The same, using regular expression notation to consolidate the switches: + +

$ pg_dump -n '(east|west)*gsm' -N '*test*' mydb > db.sql

+

To dump all database objects except for tables whose names begin with + ts_: + +

$ pg_dump -T 'ts_*' mydb > db.sql

+

To specify an upper-case or mixed-case name in -t and related + switches, you need to double-quote the name; else it will be folded to + lower case (see Patterns). But + double quotes are special to the shell, so in turn they must be quoted. + Thus, to dump a single table with a mixed-case name, you need something + like + +

$ pg_dump -t '"MixedCaseName"' mydb > mytab.sql


PrevHomeNext
pg_configUppg_dumpall
\ No newline at end of file diff --git a/doc/src/sgml/html/app-pgreceivexlog.html b/doc/src/sgml/html/app-pgreceivexlog.html new file mode 100644 index 000000000..ae132933c --- /dev/null +++ b/doc/src/sgml/html/app-pgreceivexlog.html @@ -0,0 +1,678 @@ + +pg_receivexlog

pg_receivexlog

Name

pg_receivexlog -- streams transaction logs from a PostgreSQL cluster

Synopsis

pg_receivexlog [option...]

Description +

pg_receivexlog is used to stream transaction log + from a running PostgreSQL cluster. The transaction + log is streamed using the streaming replication protocol, and is written + to a local directory of files. This directory can be used as the archive + location for doing a restore using point-in-time recovery (see + Section 24.3). +

pg_receivexlog streams the transaction + log in real time as it's being generated on the server, and does not wait + for segments to complete like archive_command does. + For this reason, it is not necessary to set + archive_timeout when using + pg_receivexlog. +

The transaction log is streamed over a regular + PostgreSQL connection, and uses the replication + protocol. The connection must be made with a superuser or a user + having REPLICATION permissions (see + Section 20.2), and pg_hba.conf + must explicitly permit the replication connection. The server must also be + configured with max_wal_senders set high enough to + leave at least one session available for the stream. +

If the connection is lost, or if it cannot be initially established, + with a non-fatal error, pg_receivexlog will + retry the connection indefinitely, and reestablish streaming as soon + as possible. To avoid this behavior, use the -n + parameter. +

Options

The following command-line options control the location and format of the + output. + +

-D directory
--directory=directory

Directory to write the output to. +

This parameter is required. +

+

The following command-line options control the running of the program. + +

-n
--no-loop

Don't loop on connection errors. Instead, exit right away with + an error. +

-v
--verbose

Enables verbose mode. +

+

The following command-line options control the database connection parameters. + +

-h host
--host=host

Specifies the host name of the machine on which the server is + running. If the value begins with a slash, it is used as the + directory for the Unix domain socket. The default is taken + from the PGHOST environment variable, if set, + else a Unix domain socket connection is attempted. +

-p port
--port=port

Specifies the TCP port or local Unix domain socket file + extension on which the server is listening for connections. + Defaults to the PGPORT environment variable, if + set, or a compiled-in default. +

-s interval
--status-interval=interval

Specifies the number of seconds between status packets sent back to the + server. This is required if replication timeout is configured on the + server, and allows for easier monitoring. A value of zero disables the + status updates completely. The default value is 10 seconds. +

-U username
--username=username

User name to connect as. +

-w
--no-password

Never issue a password prompt. If the server requires + password authentication and a password is not available by + other means such as a .pgpass file, the + connection attempt will fail. This option can be useful in + batch jobs and scripts where no user is present to enter a + password. +

-W
--password

Force pg_receivexlog to prompt for a + password before connecting to a database. +

This option is never essential, since + pg_receivexlog will automatically prompt + for a password if the server demands password authentication. + However, pg_receivexlog will waste a + connection attempt finding out that the server wants a password. + In some cases it is worth typing -W to avoid the extra + connection attempt. +

+

Other options are also available: + +

-V
--version

Print the pg_receivexlog version and exit. +

-?
--help

Show help about pg_receivexlog command line + arguments, and exit. +

+

Environment

This utility, like most other PostgreSQL utilities, + uses the environment variables supported by libpq + (see Section 31.14). +

Notes

When using pg_receivexlog instead of + archive_command, the server will continue to + recycle transaction log files even if the backups are not properly + archived, since there is no command that fails. This can be worked + around by having an archive_command that fails + when the file has not been properly archived yet, for example: +

archive_command = 'sleep 5 && test -f /mnt/server/archivedir/%f'

+ The initial timeout is necessary because + pg_receivexlog works using asynchronous + replication and can therefore be slightly behind the master. +

Examples

To stream the transaction log from the server at + mydbserver and store it in the local directory + /usr/local/pgsql/archive: +

$ pg_receivexlog -h mydbserver -D /usr/local/pgsql/archive


PrevHomeNext
pg_dumpallUppg_restore
\ No newline at end of file diff --git a/doc/src/sgml/html/app-pgresetxlog.html b/doc/src/sgml/html/app-pgresetxlog.html new file mode 100644 index 000000000..478514991 --- /dev/null +++ b/doc/src/sgml/html/app-pgresetxlog.html @@ -0,0 +1,604 @@ + +pg_resetxlog

pg_resetxlog

Name

pg_resetxlog -- reset the write-ahead log and other control information of a PostgreSQL database cluster

Synopsis

pg_resetxlog [-f] [-n] [-o oid] [-x xid] [-e xid_epoch] [-m mxid] [-O mxoff] [-l timelineid,fileid,seg] datadir

Description

pg_resetxlog clears the write-ahead log (WAL) and + optionally resets some other control information stored in the + pg_control file. This function is sometimes needed + if these files have become corrupted. It should be used only as a + last resort, when the server will not start due to such corruption. +

After running this command, it should be possible to start the server, + but bear in mind that the database might contain inconsistent data due to + partially-committed transactions. You should immediately dump your data, + run initdb, and reload. After reload, check for + inconsistencies and repair as needed. +

This utility can only be run by the user who installed the server, because + it requires read/write access to the data directory. + For safety reasons, you must specify the data directory on the command line. + pg_resetxlog does not use the environment variable + PGDATA. +

If pg_resetxlog complains that it cannot determine + valid data for pg_control, you can force it to proceed anyway + by specifying the -f (force) option. In this case plausible + values will be substituted for the missing data. Most of the fields can be + expected to match, but manual assistance might be needed for the next OID, + next transaction ID and epoch, next multitransaction ID and offset, and + WAL starting address fields. These fields can be set using the options + discussed below. If you are not able to determine correct values for all + these fields, -f can still be used, but + the recovered database must be treated with even more suspicion than + usual: an immediate dump and reload is imperative. Do not + execute any data-modifying operations in the database before you dump, + as any such action is likely to make the corruption worse. +

The -o, -x, -e, + -m, -O, + and -l + options allow the next OID, next transaction ID, next transaction ID's + epoch, next multitransaction ID, next multitransaction offset, and WAL + starting address values to be set manually. These are only needed when + pg_resetxlog is unable to determine appropriate values + by reading pg_control. Safe values can be determined as + follows: + +

  • A safe value for the next transaction ID (-x) + can be determined by looking for the numerically largest + file name in the directory pg_clog under the data directory, + adding one, + and then multiplying by 1048576. Note that the file names are in + hexadecimal. It is usually easiest to specify the option value in + hexadecimal too. For example, if 0011 is the largest entry + in pg_clog, -x 0x1200000 will work (five + trailing zeroes provide the proper multiplier). +

  • A safe value for the next multitransaction ID (-m) + can be determined by looking for the numerically largest + file name in the directory pg_multixact/offsets under the + data directory, adding one, and then multiplying by 65536. As above, + the file names are in hexadecimal, so the easiest way to do this is to + specify the option value in hexadecimal and add four zeroes. +

  • A safe value for the next multitransaction offset (-O) + can be determined by looking for the numerically largest + file name in the directory pg_multixact/members under the + data directory, adding one, and then multiplying by 65536. As above, + the file names are in hexadecimal, so the easiest way to do this is to + specify the option value in hexadecimal and add four zeroes. +

  • The WAL starting address (-l) should be + larger than any WAL segment file name currently existing in + the directory pg_xlog under the data directory. + These names are also in hexadecimal and have three parts. The first + part is the "timeline ID" and should usually be kept the same. + Do not choose a value larger than 255 (0xFF) for the third + part; instead increment the second part and reset the third part to 0. + For example, if 00000001000000320000004A is the + largest entry in pg_xlog, -l 0x1,0x32,0x4B will + work; but if the largest entry is + 000000010000003A000000FF, choose -l 0x1,0x3B,0x0 + or more. +

    Note: pg_resetxlog itself looks at the files in + pg_xlog and chooses a default -l setting + beyond the last existing file name. Therefore, manual adjustment of + -l should only be needed if you are aware of WAL segment + files that are not currently present in pg_xlog, such as + entries in an offline archive; or if the contents of + pg_xlog have been lost entirely. +

  • There is no comparably easy way to determine a next OID that's beyond + the largest one in the database, but fortunately it is not critical to + get the next-OID setting right. +

  • The transaction ID epoch is not actually stored anywhere in the database + except in the field that is set by pg_resetxlog, + so any value will work so far as the database itself is concerned. + You might need to adjust this value to ensure that replication + systems such as Slony-I work correctly — + if so, an appropriate value should be obtainable from the state of + the downstream replicated database. +

+

The -n (no operation) option instructs + pg_resetxlog to print the values reconstructed from + pg_control and then exit without modifying anything. + This is mainly a debugging tool, but can be useful as a sanity check + before allowing pg_resetxlog to proceed for real. +

The -V and --version options print + the pg_resetxlog version and exit. The + options -? and --help show supported arguments, + and exit. +

Notes

This command must not be used when the server is + running. pg_resetxlog will refuse to start up if + it finds a server lock file in the data directory. If the + server crashed then a lock file might have been left + behind; in that case you can remove the lock file to allow + pg_resetxlog to run. But before you do + so, make doubly certain that there is no server process still alive. +


PrevHomeNext
pg_ctlUppostgres
\ No newline at end of file diff --git a/doc/src/sgml/html/app-pgrestore.html b/doc/src/sgml/html/app-pgrestore.html new file mode 100644 index 000000000..8ce189d1e --- /dev/null +++ b/doc/src/sgml/html/app-pgrestore.html @@ -0,0 +1,1747 @@ + +pg_restore

pg_restore

Name

pg_restore --  restore a PostgreSQL database from an + archive file created by pg_dump +

Synopsis

pg_restore [connection-option...] [option...] [filename]

Description

pg_restore is a utility for restoring a + PostgreSQL database from an archive + created by pg_dump in one of the non-plain-text + formats. It will issue the commands necessary to reconstruct the + database to the state it was in at the time it was saved. The + archive files also allow pg_restore to + be selective about what is restored, or even to reorder the items + prior to being restored. The archive files are designed to be + portable across architectures. +

pg_restore can operate in two modes. + If a database name is specified, pg_restore + connects to that database and restores archive contents directly into + the database. Otherwise, a script containing the SQL + commands necessary to rebuild the database is created and written + to a file or standard output. This script output is equivalent to + the plain text output format of pg_dump. + Some of the options controlling the output are therefore analogous to + pg_dump options. +

Obviously, pg_restore cannot restore information + that is not present in the archive file. For instance, if the + archive was made using the "dump data as + INSERT commands" option, + pg_restore will not be able to load the data + using COPY statements. +

Options

pg_restore accepts the following command + line arguments. + +

filename

Specifies the location of the archive file (or directory, for a + directory-format archive) to be restored. + If not specified, the standard input is used. +

-a
--data-only

Restore only the data, not the schema (data definitions). + Table data, large objects, and sequence values are restored, + if present in the archive. +

This option is similar to, but for historical reasons not identical + to, specifying --section=data. +

-c
--clean

Clean (drop) database objects before recreating them. + (This might generate some harmless error messages, if any objects + were not present in the destination database.) +

-C
--create

Create the database before restoring into it. + If --clean is also specified, drop and + recreate the target database before connecting to it. +

When this option is used, the database named with -d + is used only to issue the initial DROP DATABASE and + CREATE DATABASE commands. All data is restored into the + database name that appears in the archive. +

-d dbname
--dbname=dbname

Connect to database dbname and restore directly + into the database. +

-e
--exit-on-error

Exit if an error is encountered while sending SQL commands to + the database. The default is to continue and to display a count of + errors at the end of the restoration. +

-f filename
--file=filename

Specify output file for generated script, or for the listing + when used with -l. Default is the standard + output. +

-F format
--format=format

Specify format of the archive. It is not necessary to specify + the format, since pg_restore will + determine the format automatically. If specified, it can be + one of the following: + +

c
custom

The archive is in the custom format of + pg_dump. +

d
directory

The archive is a directory archive. +

t
tar

The archive is a tar archive. +

-i
--ignore-version

A deprecated option that is now ignored. +

-I index
--index=index

Restore definition of named index only. +

-j number-of-jobs
--jobs=number-of-jobs

Run the most time-consuming parts + of pg_restore — those which load data, + create indexes, or create constraints — using multiple + concurrent jobs. This option can dramatically reduce the time + to restore a large database to a server running on a + multiprocessor machine. +

Each job is one process or one thread, depending on the + operating system, and uses a separate connection to the + server. +

The optimal value for this option depends on the hardware + setup of the server, of the client, and of the network. + Factors include the number of CPU cores and the disk setup. A + good place to start is the number of CPU cores on the server, + but values larger than that can also lead to faster restore + times in many cases. Of course, values that are too high will + lead to decreased performance because of thrashing. +

Only the custom archive format is supported with this option. + The input file must be a regular file (not, for example, a + pipe). This option is ignored when emitting a script rather + than connecting directly to a database server. Also, multiple + jobs cannot be used together with the + option --single-transaction. +

-l
--list

List the contents of the archive. The output of this operation + can be used as input to the -L option. Note that + if filtering switches such as -n or -t are + used with -l, they will restrict the items listed. +

-L list-file
--use-list=list-file

Restore only those archive elements that are listed in list-file, and restore them in the + order they appear in the file. Note that + if filtering switches such as -n or -t are + used with -L, they will further restrict the items restored. +

list-file is normally created by + editing the output of a previous -l operation. + Lines can be moved or removed, and can also + be commented out by placing a semicolon (;) at the + start of the line. See below for examples. +

-n namespace
--schema=schema

Restore only objects that are in the named schema. This can be + combined with the -t option to restore just a + specific table. +

-O
--no-owner

Do not output commands to set + ownership of objects to match the original database. + By default, pg_restore issues + ALTER OWNER or + SET SESSION AUTHORIZATION + statements to set ownership of created schema elements. + These statements will fail unless the initial connection to the + database is made by a superuser + (or the same user that owns all of the objects in the script). + With -O, any user name can be used for the + initial connection, and this user will own all the created objects. +

-P function-name(argtype [, ...])
--function=function-name(argtype [, ...])

Restore the named function only. Be careful to spell the function + name and arguments exactly as they appear in the dump file's table + of contents. +

-R
--no-reconnect

This option is obsolete but still accepted for backwards + compatibility. +

-s
--schema-only

Restore only the schema (data definitions), not data, + to the extent that schema entries are present in the archive. +

This option is the inverse of --data-only. + It is similar to, but for historical reasons not identical to, + specifying + --section=pre-data --section=post-data. +

(Do not confuse this with the --schema option, which + uses the word "schema" in a different meaning.) +

-S username
--superuser=username

Specify the superuser user name to use when disabling triggers. + This is only relevant if --disable-triggers is used. +

-t table
--table=table

Restore definition and/or data of named table only. This can be + combined with the -n option to specify a schema. +

-T trigger
--trigger=trigger

Restore named trigger only. +

-v
--verbose

Specifies verbose mode. +

-V
--version

Print the pg_restore version and exit. +

-x
--no-privileges
--no-acl

Prevent restoration of access privileges (grant/revoke commands). +

-1
--single-transaction

Execute the restore as a single transaction (that is, wrap the + emitted commands in BEGIN/COMMIT). This + ensures that either all the commands complete successfully, or no + changes are applied. This option implies + --exit-on-error. +

--disable-triggers

This option is only relevant when performing a data-only restore. + It instructs pg_restore to execute commands + to temporarily disable triggers on the target tables while + the data is reloaded. Use this if you have referential + integrity checks or other triggers on the tables that you + do not want to invoke during data reload. +

Presently, the commands emitted for + --disable-triggers must be done as superuser. So, you + should also specify a superuser name with -S, or + preferably run pg_restore as a + PostgreSQL superuser. +

--no-data-for-failed-tables

By default, table data is restored even if the creation command + for the table failed (e.g., because it already exists). + With this option, data for such a table is skipped. + This behavior is useful if the target database already + contains the desired table contents. For example, + auxiliary tables for PostgreSQL extensions + such as PostGIS might already be loaded in + the target database; specifying this option prevents duplicate + or obsolete data from being loaded into them. +

This option is effective only when restoring directly into a + database, not when producing SQL script output. +

--no-security-labels

Do not output commands to restore security labels, + even if the archive contains them. +

--no-tablespaces

Do not output commands to select tablespaces. + With this option, all objects will be created in whichever + tablespace is the default during restore. +

--section=sectionname

Only restore the named section. The section name can be + pre-data, data, or post-data. + This option can be specified more than once to select multiple + sections. The default is to restore all sections. +

The data section contains actual table data as well as large-object + definitions. + Post-data items consist of definitions of indexes, triggers, rules + and constraints other than validated check constraints. + Pre-data items consist of all other data definition items. +

--use-set-session-authorization

Output SQL-standard SET SESSION AUTHORIZATION commands + instead of ALTER OWNER commands to determine object + ownership. This makes the dump more standards-compatible, but + depending on the history of the objects in the dump, might not restore + properly. +

-?
--help

Show help about pg_restore command line + arguments, and exit. +

+

pg_restore also accepts + the following command line arguments for connection parameters: + +

-h host
--host=host

Specifies the host name of the machine on which the server is + running. If the value begins with a slash, it is used as the + directory for the Unix domain socket. The default is taken + from the PGHOST environment variable, if set, + else a Unix domain socket connection is attempted. +

-p port
--port=port

Specifies the TCP port or local Unix domain socket file + extension on which the server is listening for connections. + Defaults to the PGPORT environment variable, if + set, or a compiled-in default. +

-U username
--username=username

User name to connect as. +

-w
--no-password

Never issue a password prompt. If the server requires + password authentication and a password is not available by + other means such as a .pgpass file, the + connection attempt will fail. This option can be useful in + batch jobs and scripts where no user is present to enter a + password. +

-W
--password

Force pg_restore to prompt for a + password before connecting to a database. +

This option is never essential, since + pg_restore will automatically prompt + for a password if the server demands password authentication. + However, pg_restore will waste a + connection attempt finding out that the server wants a password. + In some cases it is worth typing -W to avoid the extra + connection attempt. +

--role=rolename

Specifies a role name to be used to perform the restore. + This option causes pg_restore to issue a + SET ROLE rolename + command after connecting to the database. It is useful when the + authenticated user (specified by -U) lacks privileges + needed by pg_restore, but can switch to a role with + the required rights. Some installations have a policy against + logging in directly as a superuser, and use of this option allows + restores to be performed without violating the policy. +

+

Environment

PGHOST
PGOPTIONS
PGPORT
PGUSER

Default connection parameters +

This utility, like most other PostgreSQL utilities, + also uses the environment variables supported by libpq + (see Section 31.14). +

Diagnostics

When a direct database connection is specified using the + -d option, pg_restore + internally executes SQL statements. If you have + problems running pg_restore, make sure + you are able to select information from the database using, for + example, psql. Also, any default connection + settings and environment variables used by the + libpq front-end library will apply. +

Notes

If your installation has any local additions to the + template1 database, be careful to load the output of + pg_restore into a truly empty database; + otherwise you are likely to get errors due to duplicate definitions + of the added objects. To make an empty database without any local + additions, copy from template0 not template1, for example: +

CREATE DATABASE foo WITH TEMPLATE template0;

+

The limitations of pg_restore are detailed below. + +

  • When restoring data to a pre-existing table and the option + --disable-triggers is used, + pg_restore emits commands + to disable triggers on user tables before inserting the data, then emits commands to + re-enable them after the data has been inserted. If the restore is stopped in the + middle, the system catalogs might be left in the wrong state. +

  • pg_restore cannot restore large objects + selectively; for instance, only those for a specific table. If + an archive contains large objects, then all large objects will be + restored, or none of them if they are excluded via -L, + -t, or other options. +

+

See also the pg_dump documentation for details on + limitations of pg_dump. +

Once restored, it is wise to run ANALYZE on each + restored table so the optimizer has useful statistics; see + Section 23.1.3 and + Section 23.1.6 for more information. +

Examples

Assume we have dumped a database called mydb into a + custom-format dump file: + +

$ pg_dump -Fc mydb > db.dump

+

To drop the database and recreate it from the dump: + +

$ dropdb mydb
+$ pg_restore -C -d postgres db.dump

+ + The database named in the -d switch can be any database existing + in the cluster; pg_restore only uses it to issue the + CREATE DATABASE command for mydb. With + -C, data is always restored into the database name that appears + in the dump file. +

To reload the dump into a new database called newdb: + +

$ createdb -T template0 newdb
+$ pg_restore -d newdb db.dump

+ + Notice we don't use -C, and instead connect directly to the + database to be restored into. Also note that we clone the new database + from template0 not template1, to ensure it is + initially empty. +

To reorder database items, it is first necessary to dump the table of + contents of the archive: +

$ pg_restore -l db.dump > db.list

+ The listing file consists of a header and one line for each item, e.g.: +

;
+; Archive created at Mon Sep 14 13:55:39 2009
+;     dbname: DBDEMOS
+;     TOC Entries: 81
+;     Compression: 9
+;     Dump Version: 1.10-0
+;     Format: CUSTOM
+;     Integer: 4 bytes
+;     Offset: 8 bytes
+;     Dumped from database version: 8.3.5
+;     Dumped by pg_dump version: 8.3.8
+;
+;
+; Selected TOC Entries:
+;
+3; 2615 2200 SCHEMA - public pasha
+1861; 0 0 COMMENT - SCHEMA public pasha
+1862; 0 0 ACL - public pasha
+317; 1247 17715 TYPE public composite pasha
+319; 1247 25899 DOMAIN public domain0 pasha

+ Semicolons start a comment, and the numbers at the start of lines refer to the + internal archive ID assigned to each item. +

Lines in the file can be commented out, deleted, and reordered. For example: +

10; 145433 TABLE map_resolutions postgres
+;2; 145344 TABLE species postgres
+;4; 145359 TABLE nt_header postgres
+6; 145402 TABLE species_records postgres
+;8; 145416 TABLE ss_old postgres

+ could be used as input to pg_restore and would only restore + items 10 and 6, in that order: +

$ pg_restore -L db.list db.dump


PrevHomeNext
pg_receivexlogUppsql
\ No newline at end of file diff --git a/doc/src/sgml/html/app-postgres.html b/doc/src/sgml/html/app-postgres.html new file mode 100644 index 000000000..da83327ab --- /dev/null +++ b/doc/src/sgml/html/app-postgres.html @@ -0,0 +1,1710 @@ + +postgres

postgres

Name

postgres -- PostgreSQL database server

Synopsis

postgres [option...]

Description

postgres is the + PostgreSQL database server. In order + for a client application to access a database it connects (over a + network or locally) to a running postgres instance. + The postgres instance then starts a separate server + process to handle the connection. +

One postgres instance always manages the data of + exactly one database cluster. A database cluster is a collection + of databases that is stored at a common file system location (the + "data area"). More than one + postgres instance can run on a system at one + time, so long as they use different data areas and different + communication ports (see below). When + postgres starts it needs to know the location + of the data area. The location must be specified by the + -D option or the PGDATA environment + variable; there is no default. Typically, -D or + PGDATA points directly to the data area directory + created by initdb. Other possible file layouts are + discussed in Section 18.2. +

By default postgres starts in the + foreground and prints log messages to the standard error stream. In + practical applications postgres + should be started as a background process, perhaps at boot time. +

The postgres command can also be called in + single-user mode. The primary use for this mode is during + bootstrapping by initdb. Sometimes it is used + for debugging or disaster recovery; note that running a single-user + server is not truly suitable for debugging the server, since no + realistic interprocess communication and locking will happen. + When invoked in single-user + mode from the shell, the user can enter queries and the results + will be printed to the screen, but in a form that is more useful + for developers than end users. In the single-user mode, + the session user will be set to the user with ID 1, and implicit + superuser powers are granted to this user. + This user does not actually have to exist, so the single-user mode + can be used to manually recover from certain + kinds of accidental damage to the system catalogs. +

Options

postgres accepts the following command-line + arguments. For a detailed discussion of the options consult Chapter 18. You can save typing most of these + options by setting up a configuration file. Some (safe) options + can also be set from the connecting client in an + application-dependent way to apply only for that session. For + example, if the environment variable PGOPTIONS is + set, then libpq-based clients will pass that + string to the server, which will interpret it as + postgres command-line options. +

General Purpose

-A 0|1

Enables run-time assertion checks, which is a debugging aid to + detect programming mistakes. This option is only available if + assertions were enabled when PostgreSQL was + compiled. If so, the default is on. +

-B nbuffers

Sets the number of shared buffers for use by the server + processes. The default value of this parameter is chosen + automatically by initdb. + Specifying this option is equivalent to setting the + shared_buffers configuration parameter. +

-c name=value

Sets a named run-time parameter. The configuration parameters + supported by PostgreSQL are + described in Chapter 18. Most of the + other command line options are in fact short forms of such a + parameter assignment. -c can appear multiple times + to set multiple parameters. +

-C name

Prints the value of the named run-time parameter, and exits. + (See the -c option above for details.) This can + be used on a running server, and returns values from + postgresql.conf, modified by any parameters + supplied in this invocation. It does not reflect parameters + supplied when the cluster was started. +

This option is meant for other programs that interact with a server + instance, such as pg_ctl, to query configuration + parameter values. User-facing applications should instead use SHOW or the pg_settings view. +

-d debug-level

Sets the debug level. The higher this value is set, the more + debugging output is written to the server log. Values are + from 1 to 5. It is also possible to pass -d + 0 for a specific session, which will prevent the + server log level of the parent postgres process from being + propagated to this session. +

-D datadir

Specifies the file system location of the data directory or + configuration file(s). See + Section 18.2 for details. +

-e

Sets the default date style to "European", that is + DMY ordering of input date fields. This also causes + the day to be printed before the month in certain date output formats. + See Section 8.5 for more information. +

-F

Disables fsync calls for improved + performance, at the risk of data corruption in the event of a + system crash. Specifying this option is equivalent to + disabling the fsync configuration + parameter. Read the detailed documentation before using this! +

-h hostname

Specifies the IP host name or address on which + postgres is to listen for TCP/IP + connections from client applications. The value can also be a + comma-separated list of addresses, or * to specify + listening on all available interfaces. An empty value + specifies not listening on any IP addresses, in which case + only Unix-domain sockets can be used to connect to the + server. Defaults to listening only on + localhost. + Specifying this option is equivalent to setting the listen_addresses configuration parameter. +

-i

Allows remote clients to connect via TCP/IP (Internet domain) + connections. Without this option, only local connections are + accepted. This option is equivalent to setting + listen_addresses to * in + postgresql.conf or via -h. +

This option is deprecated since it does not allow access to the + full functionality of listen_addresses. + It's usually better to set listen_addresses directly. +

-k directory

Specifies the directory of the Unix-domain socket on which + postgres is to listen for + connections from client applications. The default is normally + /tmp, but can be changed at build time. +

-l

Enables secure connections using SSL. + PostgreSQL must have been compiled with + support for SSL for this option to be + available. For more information on using SSL, + refer to Section 17.9. +

-N max-connections

Sets the maximum number of client connections that this + server will accept. The default value of this parameter is chosen + automatically by initdb. + Specifying this option is equivalent to setting the + max_connections configuration parameter. +

-o extra-options

The command-line-style options specified in extra-options are passed to + all server processes started by this + postgres process. If the option string contains + any spaces, the entire string must be quoted. +

The use of this option is obsolete; all command-line options + for server processes can be specified directly on the + postgres command line. +

-p port

Specifies the TCP/IP port or local Unix domain socket file + extension on which postgres + is to listen for connections from client applications. + Defaults to the value of the PGPORT environment + variable, or if PGPORT is not set, then + defaults to the value established during compilation (normally + 5432). If you specify a port other than the default port, + then all client applications must specify the same port using + either command-line options or PGPORT. +

-s

Print time information and other statistics at the end of each command. + This is useful for benchmarking or for use in tuning the number of + buffers. +

-S work-mem

Specifies the amount of memory to be used by internal sorts and hashes + before resorting to temporary disk files. See the description of the + work_mem configuration parameter in Section 18.4.1. +

-V
--version

Print the postgres version and exit. +

--name=value

Sets a named run-time parameter; a shorter form of + -c. +

--describe-config

This option dumps out the server's internal configuration variables, + descriptions, and defaults in tab-delimited COPY format. + It is designed primarily for use by administration tools. +

-?
--help

Show help about postgres command line + arguments, and exit. +

Semi-internal Options

The options described here are used + mainly for debugging purposes, and in some cases to assist with + recovery of severely damaged databases. There should be no reason + to use them in a production database setup. They are listed + here only for use by PostgreSQL + system developers. Furthermore, these options might + change or be removed in a future release without notice. +

-f { s | i | o | b | t | n | m | h }

Forbids the use of particular scan and join methods: + s and i + disable sequential and index scans respectively, + o, b and t + disable index-only scans, bitmap index scans, and TID scans + respectively, while + n, m, and h + disable nested-loop, merge and hash joins respectively. +

Neither sequential scans nor nested-loop joins can be disabled + completely; the -fs and + -fn options simply discourage the optimizer + from using those plan types if it has any other alternative. +

-n

This option is for debugging problems that cause a server + process to die abnormally. The ordinary strategy in this + situation is to notify all other server processes that they + must terminate and then reinitialize the shared memory and + semaphores. This is because an errant server process could + have corrupted some shared state before terminating. This + option specifies that postgres will + not reinitialize shared data structures. A knowledgeable + system programmer can then use a debugger to examine shared + memory and semaphore state. +

-O

Allows the structure of system tables to be modified. This is + used by initdb. +

-P

Ignore system indexes when reading system tables, but still update + the indexes when modifying the tables. This is useful when + recovering from damaged system indexes. +

-t pa[rser] | pl[anner] | e[xecutor]

Print timing statistics for each query relating to each of the + major system modules. This option cannot be used together + with the -s option. +

-T

This option is for debugging problems that cause a server + process to die abnormally. The ordinary strategy in this + situation is to notify all other server processes that they + must terminate and then reinitialize the shared memory and + semaphores. This is because an errant server process could + have corrupted some shared state before terminating. This + option specifies that postgres will + stop all other server processes by sending the signal + SIGSTOP, but will not cause them to + terminate. This permits system programmers to collect core + dumps from all server processes by hand. +

-v protocol

Specifies the version number of the frontend/backend protocol + to be used for a particular session. This option is for + internal use only. +

-W seconds

A delay of this many seconds occurs when a new server process + is started, after it conducts the authentication procedure. + This is intended to give an opportunity to attach to the + server process with a debugger. +

Options for Single-User Mode

The following options only apply to the single-user mode. +

--single

Selects the single-user mode. This must be the first argument + on the command line. +

database

Specifies the name of the database to be accessed. This must be + the last argument on the command line. If it is + omitted it defaults to the user name. +

-E

Echo all commands. +

-j

Disables use of newline as a statement delimiter. +

-r filename

Send all server log output to filename. In normal multiuser + mode, this option is ignored, and stderr is + used by all processes. +

Environment

PGCLIENTENCODING

Default character encoding used by clients. (The clients can + override this individually.) This value can also be set in the + configuration file. +

PGDATA

Default data directory location +

PGDATESTYLE

Default value of the DateStyle run-time + parameter. (The use of this environment variable is deprecated.) +

PGPORT

Default port number (preferably set in the configuration file) +

TZ

Server time zone +

Diagnostics

A failure message mentioning semget or + shmget probably indicates you need to configure your + kernel to provide adequate shared memory and semaphores. For more + discussion see Section 17.4. You might be able + to postpone reconfiguring your kernel by decreasing shared_buffers to reduce the shared memory + consumption of PostgreSQL, and/or by reducing + max_connections to reduce the semaphore + consumption. +

A failure message suggesting that another server is already running + should be checked carefully, for example by using the command +

$ ps ax | grep postgres

+ or +

$ ps -ef | grep postgres

+ depending on your system. If you are certain that no conflicting + server is running, you can remove the lock file mentioned in the + message and try again. +

A failure message indicating inability to bind to a port might + indicate that that port is already in use by some + non-PostgreSQL process. You might also + get this error if you terminate postgres + and immediately restart it using the same port; in this case, you + must simply wait a few seconds until the operating system closes + the port before trying again. Finally, you might get this error if + you specify a port number that your operating system considers to + be reserved. For example, many versions of Unix consider port + numbers under 1024 to be "trusted" and only permit + the Unix superuser to access them. +

Notes

The utility command pg_ctl can be used to + start and shut down the postgres server + safely and comfortably. +

If at all possible, do not use + SIGKILL to kill the main + postgres server. Doing so will prevent + postgres from freeing the system + resources (e.g., shared memory and semaphores) that it holds before + terminating. This might cause problems for starting a fresh + postgres run. +

To terminate the postgres server normally, the + signals SIGTERM, SIGINT, or + SIGQUIT can be used. The first will wait for + all clients to terminate before quitting, the second will + forcefully disconnect all clients, and the third will quit + immediately without proper shutdown, resulting in a recovery run + during restart. +

The SIGHUP signal will reload + the server configuration files. It is also possible to send + SIGHUP to an individual server process, but that + is usually not sensible. +

To cancel a running query, send the SIGINT signal + to the process running that command. +

The postgres server uses SIGTERM + to tell subordinate server processes to quit normally and + SIGQUIT to terminate without the normal cleanup. + These signals should not be used by users. It + is also unwise to send SIGKILL to a server + process — the main postgres process will + interpret this as a crash and will force all the sibling processes + to quit as part of its standard crash-recovery procedure. +

Bugs

The -- options will not work on FreeBSD or OpenBSD. + Use -c instead. This is a bug in the affected operating + systems; a future release of PostgreSQL + will provide a workaround if this is not fixed. +

Usage

To start a single-user mode server, use a command like +

postgres --single -D /usr/local/pgsql/data other-options my_database

+ Provide the correct path to the database directory with -D, or + make sure that the environment variable PGDATA is set. + Also specify the name of the particular database you want to work in. +

Normally, the single-user mode server treats newline as the command + entry terminator; there is no intelligence about semicolons, + as there is in psql. To continue a command + across multiple lines, you must type backslash just before each + newline except the last one. +

But if you use the -j command line switch, then newline does + not terminate command entry. In this case, the server will read the standard input + until the end-of-file (EOF) marker, then + process the input as a single command string. Backslash-newline is not + treated specially in this case. +

To quit the session, type EOF + (Control+D, usually). + If you've + used -j, two consecutive EOFs are needed to exit. +

Note that the single-user mode server does not provide sophisticated + line-editing features (no command history, for example). + Single-User mode also does not do any background processing, like + automatic checkpoints. + +

Examples

To start postgres in the background + using default values, type: + +

$ nohup postgres >logfile 2>&1 </dev/null &

+

To start postgres with a specific + port, e.g. 1234: +

$ postgres -p 1234

+ To connect to this server using psql, specify this port with the -p option: +

$ psql -p 1234

+ or set the environment variable PGPORT: +

$ export PGPORT=1234
+$ psql

+

Named run-time parameters can be set in either of these styles: +

$ postgres -c work_mem=1234
+$ postgres --work-mem=1234

+ Either form overrides whatever setting might exist for + work_mem in postgresql.conf. Notice that + underscores in parameter names can be written as either underscore + or dash on the command line. Except for short-term experiments, + it's probably better practice to edit the setting in + postgresql.conf than to rely on a command-line switch + to set a parameter. +

See Also

initdb, + pg_ctl +


PrevHomeNext
pg_resetxlogUppostmaster
\ No newline at end of file diff --git a/doc/src/sgml/html/app-postmaster.html b/doc/src/sgml/html/app-postmaster.html new file mode 100644 index 000000000..6a65d9b3b --- /dev/null +++ b/doc/src/sgml/html/app-postmaster.html @@ -0,0 +1,228 @@ + +postmaster

postmaster

Name

postmaster -- PostgreSQL database server

Synopsis

postmaster [option...]

Description

postmaster is a deprecated alias of postgres. +

See Also

postgres +


PrevHomeNext
postgresUpInternals
\ No newline at end of file diff --git a/doc/src/sgml/html/app-psql.html b/doc/src/sgml/html/app-psql.html new file mode 100644 index 000000000..a5669da90 --- /dev/null +++ b/doc/src/sgml/html/app-psql.html @@ -0,0 +1,7539 @@ + +psql

psql

Name

psql --  PostgreSQL interactive terminal +

Synopsis

psql [option...] [dbname + [username]]

Description

psql is a terminal-based front-end to + PostgreSQL. It enables you to type in + queries interactively, issue them to + PostgreSQL, and see the query results. + Alternatively, input can be from a file. In addition, it provides a + number of meta-commands and various shell-like features to + facilitate writing scripts and automating a wide variety of tasks. +

Options

-a
--echo-all

Print all input lines to standard output as they are read. This is more + useful for script processing than interactive mode. This is + equivalent to setting the variable ECHO to + all. +

-A
--no-align

Switches to unaligned output mode. (The default output mode is + otherwise aligned.) +

-c command
--command=command

Specifies that psql is to execute one + command string, command, + and then exit. This is useful in shell scripts. Start-up files + (psqlrc and ~/.psqlrc) are + ignored with this option. +

command must be either + a command string that is completely parsable by the server (i.e., + it contains no psql-specific features), + or a single backslash command. Thus you cannot mix + SQL and psql + meta-commands with this option. To achieve that, you could + pipe the string into psql, like + this: echo '\x \\ SELECT * FROM foo;' | psql. + (\\ is the separator meta-command.) +

If the command string contains multiple SQL commands, they are + processed in a single transaction, unless there are explicit + BEGIN/COMMIT commands included in the + string to divide it into multiple transactions. This is + different from the behavior when the same string is fed to + psql's standard input. Also, only + the result of the last SQL command is returned. +

-d dbname
--dbname=dbname

Specifies the name of the database to connect to. This is + equivalent to specifying dbname as the first non-option + argument on the command line. +

If this parameter contains an = sign or starts + with a valid URI prefix + (postgresql:// + or postgres://), it is treated as a + conninfo string. See Section 31.1 for more information. +

-e
--echo-queries

Copy all SQL commands sent to the server to standard output as well. + This is equivalent + to setting the variable ECHO to + queries. +

-E
--echo-hidden

Echo the actual queries generated by \d and other backslash + commands. You can use this to study psql's + internal operations. This is equivalent to + setting the variable ECHO_HIDDEN from within + psql. +

-f filename
--file=filename

Use the file filename + as the source of commands instead of reading commands interactively. + After the file is processed, psql + terminates. This is in many ways equivalent to the meta-command + \i. +

If filename is - + (hyphen), then standard input is read. +

Using this option is subtly different from writing psql + < filename. In general, + both will do what you expect, but using -f + enables some nice features such as error messages with line + numbers. There is also a slight chance that using this option will + reduce the start-up overhead. On the other hand, the variant using + the shell's input redirection is (in theory) guaranteed to yield + exactly the same output you would have received had you entered + everything by hand. +

-F separator
--field-separator=separator

Use separator as the + field separator for unaligned output. This is equivalent to + \pset fieldsep or \f. +

-h hostname
--host=hostname

Specifies the host name of the machine on which the + server is running. If the value begins + with a slash, it is used as the directory for the Unix-domain + socket. +

-H
--html

Turn on HTML tabular output. This is + equivalent to \pset format html or the + \H command. +

-l
--list

List all available databases, then exit. Other non-connection + options are ignored. This is similar to the meta-command + \list. +

-L filename
--log-file=filename

Write all query output into file filename, in addition to the + normal output destination. +

-n
--no-readline

Do not use readline for line editing and do not use the history. + This can be useful to turn off tab expansion when cutting and pasting. +

-o filename
--output=filename

Put all query output into file filename. This is equivalent to + the command \o. +

-p port
--port=port

Specifies the TCP port or the local Unix-domain + socket file extension on which the server is listening for + connections. Defaults to the value of the PGPORT + environment variable or, if not set, to the port specified at + compile time, usually 5432. +

-P assignment
--pset=assignment

Specifies printing options, in the style of + \pset. Note that here you + have to separate name and value with an equal sign instead of a + space. For example, to set the output format to LaTeX, you could write + -P format=latex. +

-q
--quiet

Specifies that psql should do its work + quietly. By default, it prints welcome messages and various + informational output. If this option is used, none of this + happens. This is useful with the -c option. + Within psql you can also set the + QUIET variable to achieve the same effect. +

-R separator
--record-separator=separator

Use separator as the + record separator for unaligned output. This is equivalent to the + \pset recordsep command. +

-s
--single-step

Run in single-step mode. That means the user is prompted before + each command is sent to the server, with the option to cancel + execution as well. Use this to debug scripts. +

-S
--single-line

Runs in single-line mode where a newline terminates an SQL command, as a + semicolon does. +

Note: This mode is provided for those who insist on it, but you are not + necessarily encouraged to use it. In particular, if you mix + SQL and meta-commands on a line the order of + execution might not always be clear to the inexperienced user. +

-t
--tuples-only

Turn off printing of column names and result row count footers, + etc. This is equivalent to the \t command. +

-T table_options
--table-attr=table_options

Specifies options to be placed within the + HTML table tag. See + \pset for details. +

-U username
--username=username

Connect to the database as the user username instead of the default. + (You must have permission to do so, of course.) +

-v assignment
--set=assignment
--variable=assignment

Perform a variable assignment, like the \set + meta-command. Note that you must separate name and value, if + any, by an equal sign on the command line. To unset a variable, + leave off the equal sign. To set a variable with an empty value, + use the equal sign but leave off the value. These assignments are + done during a very early stage of start-up, so variables reserved + for internal purposes might get overwritten later. +

-V
--version

Print the psql version and exit. +

-w
--no-password

Never issue a password prompt. If the server requires password + authentication and a password is not available by other means + such as a .pgpass file, the connection + attempt will fail. This option can be useful in batch jobs and + scripts where no user is present to enter a password. +

Note that this option will remain set for the entire session, + and so it affects uses of the meta-command + \connect as well as the initial connection attempt. +

-W
--password

Force psql to prompt for a + password before connecting to a database. +

This option is never essential, since psql + will automatically prompt for a password if the server demands + password authentication. However, psql + will waste a connection attempt finding out that the server wants a + password. In some cases it is worth typing -W to avoid + the extra connection attempt. +

Note that this option will remain set for the entire session, + and so it affects uses of the meta-command + \connect as well as the initial connection attempt. +

-x
--expanded

Turn on the expanded table formatting mode. This is equivalent to the + \x command. +

-X,
--no-psqlrc

Do not read the start-up file (neither the system-wide + psqlrc file nor the user's + ~/.psqlrc file). +

-z
--field-separator-zero

Set the field separator for unaligned output to a zero byte. +

-0
--record-separator-zero

Set the record separator for unaligned output to a zero byte. This is + useful for interfacing, for example, with xargs -0. +

-1
--single-transaction

When psql executes a script with the + -f option, adding this option wraps + BEGIN/COMMIT around the script to execute it + as a single transaction. This ensures that either all the commands + complete successfully, or no changes are applied. +

If the script itself uses BEGIN, COMMIT, + or ROLLBACK, this option will not have the desired + effects. + Also, if the script contains any command that cannot be executed + inside a transaction block, specifying this option will cause that + command (and hence the whole transaction) to fail. +

-?
--help

Show help about psql command line + arguments, and exit. +

Exit Status

psql returns 0 to the shell if it + finished normally, 1 if a fatal error of its own occurs (e.g. out of memory, + file not found), 2 if the connection to the server went bad + and the session was not interactive, and 3 if an error occurred in a + script and the variable ON_ERROR_STOP was set. +

Usage

Connecting to a Database

psql is a regular + PostgreSQL client application. In order + to connect to a database you need to know the name of your target + database, the host name and port number of the server, and what user + name you want to connect as. psql can be + told about those parameters via command line options, namely + -d, -h, -p, and + -U respectively. If an argument is found that does + not belong to any option it will be interpreted as the database name + (or the user name, if the database name is already given). Not all + of these options are required; there are useful defaults. If you omit the host + name, psql will connect via a Unix-domain socket + to a server on the local host, or via TCP/IP to localhost on + machines that don't have Unix-domain sockets. The default port number is + determined at compile time. + Since the database server uses the same default, you will not have + to specify the port in most cases. The default user name is your + Unix user name, as is the default database name. Note that you cannot + just connect to any database under any user name. Your database + administrator should have informed you about your access rights. +

When the defaults aren't quite right, you can save yourself + some typing by setting the environment variables + PGDATABASE, PGHOST, + PGPORT and/or PGUSER to appropriate + values. (For additional environment variables, see Section 31.14.) It is also convenient to have a + ~/.pgpass file to avoid regularly having to type in + passwords. See Section 31.15 for more information. +

An alternative way to specify connection parameters is in a + conninfo string or + a URI, which is used instead of a database + name. This mechanism give you very wide control over the + connection. For example: +

$ psql "service=myservice sslmode=require"
+$ psql postgresql://dbmaster:5433/mydb?sslmode=require

+ This way you can also use LDAP for connection parameter lookup as + described in Section 31.17. + See Section 31.1 for more information on all the + available connection options. +

If the connection could not be made for any reason (e.g., insufficient + privileges, server is not running on the targeted host, etc.), + psql will return an error and terminate. +

If at least one of standard input or standard output are a + terminal, then psql sets the client + encoding to "auto", which will detect the + appropriate client encoding from the locale settings + (LC_CTYPE environment variable on Unix systems). + If this doesn't work out as expected, the client encoding can be + overridden using the environment + variable PGCLIENTENCODING. +

Entering SQL Commands

In normal operation, psql provides a + prompt with the name of the database to which + psql is currently connected, followed by + the string =>. For example: +

$ psql testdb
+psql (9.2.2)
+Type "help" for help.
+
+testdb=>

+

At the prompt, the user can type in SQL commands. + Ordinarily, input lines are sent to the server when a + command-terminating semicolon is reached. An end of line does not + terminate a command. Thus commands can be spread over several lines for + clarity. If the command was sent and executed without error, the results + of the command are displayed on the screen. +

Whenever a command is executed, psql also polls + for asynchronous notification events generated by + LISTEN and + NOTIFY. +

Meta-Commands

Anything you enter in psql that begins + with an unquoted backslash is a psql + meta-command that is processed by psql + itself. These commands make + psql more useful for administration or + scripting. Meta-commands are often called slash or backslash commands. +

The format of a psql command is the backslash, + followed immediately by a command verb, then any arguments. The arguments + are separated from the command verb and each other by any number of + whitespace characters. +

To include whitespace in an argument you can quote it with + single quotes. To include a single quote in an argument, + write two single quotes within single-quoted text. + Anything contained in single quotes is + furthermore subject to C-like substitutions for + \n (new line), \t (tab), + \b (backspace), \r (carriage return), + \f (form feed), + \digits (octal), and + \xdigits (hexadecimal). + A backslash preceding any other character within single-quoted text + quotes that single character, whatever it is. +

Within an argument, text that is enclosed in backquotes + (`) is taken as a command line that is passed to the + shell. The output of the command (with any trailing newline removed) + replaces the backquoted text. +

If an unquoted colon (:) followed by a + psql variable name appears within an argument, it is + replaced by the variable's value, as described in SQL Interpolation. +

Some commands take an SQL identifier (such as a + table name) as argument. These arguments follow the syntax rules + of SQL: Unquoted letters are forced to + lowercase, while double quotes (") protect letters + from case conversion and allow incorporation of whitespace into + the identifier. Within double quotes, paired double quotes reduce + to a single double quote in the resulting name. For example, + FOO"BAR"BAZ is interpreted as fooBARbaz, + and "A weird"" name" becomes A weird" + name. +

Parsing for arguments stops at the end of the line, or when another + unquoted backslash is found. An unquoted backslash + is taken as the beginning of a new meta-command. The special + sequence \\ (two backslashes) marks the end of + arguments and continues parsing SQL commands, if + any. That way SQL and + psql commands can be freely mixed on a + line. But in any case, the arguments of a meta-command cannot + continue beyond the end of the line. +

The following meta-commands are defined: + +

\a

If the current table output format is unaligned, it is switched to aligned. + If it is not unaligned, it is set to unaligned. This command is + kept for backwards compatibility. See \pset for a + more general solution. +

\c or \connect [ dbname [ username ] [ host ] [ port ] ]

Establishes a new connection to a PostgreSQL + server. If the new connection is successfully made, the + previous connection is closed. If any of dbname, username, host or port are omitted or specified + as -, the value of that parameter from the + previous connection is used. If there is no previous + connection, the libpq default for + the parameter's value is used. +

If the connection attempt failed (wrong user name, access + denied, etc.), the previous connection will only be kept if + psql is in interactive mode. When + executing a non-interactive script, processing will + immediately stop with an error. This distinction was chosen as + a user convenience against typos on the one hand, and a safety + mechanism that scripts are not accidentally acting on the + wrong database on the other hand. +

\C [ title ]

Sets the title of any tables being printed as the result of a + query or unset any such title. This command is equivalent to + \pset title title. (The name of + this command derives from "caption", as it was + previously only used to set the caption in an + HTML table.) +

\cd [ directory ]

Changes the current working directory to + directory. Without argument, changes + to the current user's home directory. +

Tip: To print your current working directory, use \! pwd. +

\conninfo

Outputs information about the current database connection. +

\copy { table [ ( column_list ) ] | ( query ) } + { from | to } + { filename | stdin | stdout | pstdin | pstdout } + [ with ] + [ binary ] + [ oids ] + [ delimiter [ as ] 'character' ] + [ null [ as ] 'string' ] + [ csv + [ header ] + [ quote [ as ] 'character' ] + [ escape [ as ] 'character' ] + [ force quote column_list | * ] + [ force not null column_list ] ]

Performs a frontend (client) copy. This is an operation that + runs an SQL COPY + command, but instead of the server + reading or writing the specified file, + psql reads or writes the file and + routes the data between the server and the local file system. + This means that file accessibility and privileges are those of + the local user, not the server, and no SQL superuser + privileges are required. +

The syntax of the command is similar to that of the + SQL COPY + command. Note that, because of this, + special parsing rules apply to the \copy + command. In particular, the variable substitution rules and + backslash escapes do not apply. +

\copy ... from stdin | to stdout + reads/writes based on the command input and output respectively. + All rows are read from the same source that issued the command, + continuing until \. is read or the stream + reaches EOF. Output is sent to the same place as + command output. To read/write from + psql's standard input or output, use + pstdin or pstdout. This option is useful + for populating tables in-line within a SQL script file. +

Tip: This operation is not as efficient as the SQL + COPY command because all data must pass + through the client/server connection. For large + amounts of data the SQL command might be preferable. +

\copyright

Shows the copyright and distribution terms of + PostgreSQL. +

\d[S+] [ pattern ]

For each relation (table, view, index, sequence, or foreign table) + or composite type matching the + pattern, show all + columns, their types, the tablespace (if not the default) and any + special attributes such as NOT NULL or defaults. + Associated indexes, constraints, rules, and triggers are + also shown. For foreign tables, the associated foreign + server is shown as well. + ("Matching the pattern" is defined in + Patterns + below.) +

For some types of relation, \d shows additional information + for each column: column values for sequences, indexed expression for + indexes and foreign data wrapper options for foreign tables. +

The command form \d+ is identical, except that + more information is displayed: any comments associated with the + columns of the table are shown, as is the presence of OIDs in the + table, the view definition if the relation is a view. +

By default, only user-created objects are shown; supply a + pattern or the S modifier to include system + objects. +

Note: If \d is used without a + pattern argument, it is + equivalent to \dtvsE which will show a list of + all visible tables, views, sequences and foreign tables. + This is purely a convenience measure. +

\da[S] [ pattern ]

Lists aggregate functions, together with their + return type and the data types they operate on. If pattern + is specified, only aggregates whose names match the pattern are shown. + By default, only user-created objects are shown; supply a + pattern or the S modifier to include system + objects. +

\db[+] [ pattern ]

Lists tablespaces. If pattern + is specified, only tablespaces whose names match the pattern are shown. + If + is appended to the command name, each object + is listed with its associated permissions. +

\dc[S+] [ pattern ]

Lists conversions between character-set encodings. + If pattern + is specified, only conversions whose names match the pattern are + listed. + By default, only user-created objects are shown; supply a + pattern or the S modifier to include system + objects. + If + is appended to the command name, each object + is listed with its associated description. +

\dC[+] [ pattern ]

Lists type casts. + If pattern + is specified, only casts whose source or target types match the + pattern are listed. + If + is appended to the command name, each object + is listed with its associated description. +

\dd[S] [ pattern ]

Shows the descriptions of objects of type constraint, + operator class, operator family, + rule, and trigger. All + other comments may be viewed by the respective backslash commands for + those object types. +

\dd displays descriptions for objects matching the + pattern, or of visible + objects of the appropriate type if no argument is given. But in either + case, only objects that have a description are listed. + By default, only user-created objects are shown; supply a + pattern or the S modifier to include system + objects. +

Descriptions for objects can be created with the COMMENT + SQL command. +

\ddp [ pattern ]

Lists default access privilege settings. An entry is shown for + each role (and schema, if applicable) for which the default + privilege settings have been changed from the built-in defaults. + If pattern is + specified, only entries whose role name or schema name matches + the pattern are listed. +

The ALTER DEFAULT PRIVILEGES command is used to set + default access privileges. The meaning of the + privilege display is explained under + GRANT. +

\dD[S+] [ pattern ]

Lists domains. If pattern + is specified, only domains whose names match the pattern are shown. + By default, only user-created objects are shown; supply a + pattern or the S modifier to include system + objects. + If + is appended to the command name, each object + is listed with its associated permissions and description. +

\dE[S+] [ pattern ]
\di[S+] [ pattern ]
\ds[S+] [ pattern ]
\dt[S+] [ pattern ]
\dv[S+] [ pattern ]

In this group of commands, the letters E, + i, s, + t, and v + stand for foreign table, index, sequence, table, and view, + respectively. + You can specify any or all of + these letters, in any order, to obtain a listing of objects + of these types. For example, \dit lists indexes + and tables. If + is + appended to the command name, each object is listed with its + physical size on disk and its associated description, if any. + If pattern is + specified, only objects whose names match the pattern are listed. + By default, only user-created objects are shown; supply a + pattern or the S modifier to include system + objects. +

\des[+] [ pattern ]

Lists foreign servers (mnemonic: "external + servers"). + If pattern is + specified, only those servers whose name matches the pattern + are listed. If the form \des+ is used, a + full description of each server is shown, including the + server's ACL, type, version, options, and description. +

\det[+] [ pattern ]

Lists foreign tables (mnemonic: "external tables"). + If pattern is + specified, only entries whose table name or schema name matches + the pattern are listed. If the form \det+ + is used, generic options and the foreign table description + are also displayed. +

\deu[+] [ pattern ]

Lists user mappings (mnemonic: "external + users"). + If pattern is + specified, only those mappings whose user names match the + pattern are listed. If the form \deu+ is + used, additional information about each mapping is shown. +

Caution

\deu+ might also display the user name and + password of the remote user, so care should be taken not to + disclose them. +

\dew[+] [ pattern ]

Lists foreign-data wrappers (mnemonic: "external + wrappers"). + If pattern is + specified, only those foreign-data wrappers whose name matches + the pattern are listed. If the form \dew+ + is used, the ACL, options, and description of the foreign-data + wrapper are also shown. +

\df[antwS+] [ pattern ]

Lists functions, together with their arguments, return types, and + function types, which are classified as "agg" (aggregate), + "normal", "trigger", or "window". + To display only functions + of specific type(s), add the corresponding letters a, + n, t, or w to the command. + If pattern is specified, only + functions whose names match the pattern are shown. If the + form \df+ is used, additional information + about each function, including volatility, language, source + code and description, is shown. By default, only user-created + objects are shown; supply a pattern or the S + modifier to include system objects. +

Tip: To look up functions taking arguments or returning values of a specific + type, use your pager's search capability to scroll through the + \df output. +

\dF[+] [ pattern ]

Lists text search configurations. + If pattern is specified, + only configurations whose names match the pattern are shown. + If the form \dF+ is used, a full description of + each configuration is shown, including the underlying text search + parser and the dictionary list for each parser token type. +

\dFd[+] [ pattern ]

Lists text search dictionaries. + If pattern is specified, + only dictionaries whose names match the pattern are shown. + If the form \dFd+ is used, additional information + is shown about each selected dictionary, including the underlying + text search template and the option values. +

\dFp[+] [ pattern ]

Lists text search parsers. + If pattern is specified, + only parsers whose names match the pattern are shown. + If the form \dFp+ is used, a full description of + each parser is shown, including the underlying functions and the + list of recognized token types. +

\dFt[+] [ pattern ]

Lists text search templates. + If pattern is specified, + only templates whose names match the pattern are shown. + If the form \dFt+ is used, additional information + is shown about each template, including the underlying function names. +

\dg[+] [ pattern ]

Lists database roles. + (Since the concepts of "users" and "groups" have been + unified into "roles", this command is now equivalent to + \du.) + If pattern is specified, + only those roles whose names match the pattern are listed. + If the form \dg+ is used, additional information + is shown about each role; currently this adds the comment for each + role. +

\dl

This is an alias for \lo_list, which shows a + list of large objects. +

\dL[S+] [ pattern ]

Lists procedural languages. If pattern + is specified, only languages whose names match the pattern are listed. + By default, only user-created languages + are shown; supply the S modifier to include system + objects. If + is appended to the command name, each + language is listed with its call handler, validator, access privileges, + and whether it is a system object. +

\dn[S+] [ pattern ]

Lists schemas (namespaces). If pattern + is specified, only schemas whose names match the pattern are listed. + By default, only user-created objects are shown; supply a + pattern or the S modifier to include system objects. + If + is appended to the command name, each object + is listed with its associated permissions and description, if any. +

\do[S] [ pattern ]

Lists operators with their operand and return types. + If pattern is + specified, only operators whose names match the pattern are listed. + By default, only user-created objects are shown; supply a + pattern or the S modifier to include system + objects. +

\dO[S+] [ pattern ]

Lists collations. + If pattern is + specified, only collations whose names match the pattern are + listed. By default, only user-created objects are shown; + supply a pattern or the S modifier to + include system objects. If + is appended + to the command name, each collation is listed with its associated + description, if any. + Note that only collations usable with the current database's encoding + are shown, so the results may vary in different databases of the + same installation. +

\dp [ pattern ]

Lists tables, views and sequences with their + associated access privileges. + If pattern is + specified, only tables, views and sequences whose names match the + pattern are listed. +

The GRANT and + REVOKE + commands are used to set access privileges. The meaning of the + privilege display is explained under + GRANT. +

\drds [ role-pattern [ database-pattern ] ]

Lists defined configuration settings. These settings can be + role-specific, database-specific, or both. + role-pattern and + database-pattern are used to select + specific roles and databases to list, respectively. If omitted, or if + * is specified, all settings are listed, including those + not role-specific or database-specific, respectively. +

The ALTER ROLE and + ALTER DATABASE + commands are used to define per-role and per-database configuration + settings. +

\dT[S+] [ pattern ]

Lists data types. + If pattern is + specified, only types whose names match the pattern are listed. + If + is appended to the command name, each type is + listed with its internal name and size, its allowed values + if it is an enum type, and its associated permissions. + By default, only user-created objects are shown; supply a + pattern or the S modifier to include system + objects. +

\du[+] [ pattern ]

Lists database roles. + (Since the concepts of "users" and "groups" have been + unified into "roles", this command is now equivalent to + \dg.) + If pattern is specified, + only those roles whose names match the pattern are listed. + If the form \du+ is used, additional information + is shown about each role; currently this adds the comment for each + role. +

\dx[+] [ pattern ]

Lists installed extensions. + If pattern + is specified, only those extensions whose names match the pattern + are listed. + If the form \dx+ is used, all the objects belonging + to each matching extension are listed. +

\e or \edit [ filename ] [ line_number ]

If filename is + specified, the file is edited; after the editor exits, its + content is copied back to the query buffer. If no filename is given, the current query + buffer is copied to a temporary file which is then edited in the same + fashion. +

The new query buffer is then re-parsed according to the normal + rules of psql, where the whole buffer + is treated as a single line. (Thus you cannot make scripts this + way. Use \i for that.) This means that + if the query ends with (or contains) a semicolon, it is + immediately executed. Otherwise it will merely wait in the + query buffer; type semicolon or \g to send it, or + \r to cancel. +

If a line number is specified, psql will + position the cursor on the specified line of the file or query buffer. + Note that if a single all-digits argument is given, + psql assumes it is a line number, + not a file name. +

Tip: See under Environment for how to configure and + customize your editor. +

\echo text [ ... ]

Prints the arguments to the standard output, separated by one + space and followed by a newline. This can be useful to + intersperse information in the output of scripts. For example: +

=> \echo `date`
+Tue Oct 26 21:40:57 CEST 1999

+ If the first argument is an unquoted -n the trailing + newline is not written. +

Tip: If you use the \o command to redirect your + query output you might wish to use \qecho + instead of this command. +

\ef [ function_description [ line_number ] ]

This command fetches and edits the definition of the named function, + in the form of a CREATE OR REPLACE FUNCTION command. + Editing is done in the same way as for \edit. + After the editor exits, the updated command waits in the query buffer; + type semicolon or \g to send it, or \r + to cancel. +

The target function can be specified by name alone, or by name + and arguments, for example foo(integer, text). + The argument types must be given if there is more + than one function of the same name. +

If no function is specified, a blank CREATE FUNCTION + template is presented for editing. +

If a line number is specified, psql will + position the cursor on the specified line of the function body. + (Note that the function body typically does not begin on the first + line of the file.) +

Tip: See under Environment for how to configure and + customize your editor. +

\encoding [ encoding ]

Sets the client character set encoding. Without an argument, this command + shows the current encoding. +

\f [ string ]

Sets the field separator for unaligned query output. The default + is the vertical bar (|). See also + \pset for a generic way of setting output + options. +

\g [ { filename | |command } ]

Sends the current query input buffer to the server and + optionally stores the query's output in filename or pipes the output + into a separate Unix shell executing command. A bare + \g is virtually equivalent to a semicolon. A + \g with argument is a "one-shot" + alternative to the \o command. +

\h or \help [ command ]

Gives syntax help on the specified SQL + command. If command + is not specified, then psql will list + all the commands for which syntax help is available. If + command is an + asterisk (*), then syntax help on all + SQL commands is shown. +

Note: To simplify typing, commands that consists of several words do + not have to be quoted. Thus it is fine to type \help + alter table. +

\H

Turns on HTML query output format. If the + HTML format is already on, it is switched + back to the default aligned text format. This command is for + compatibility and convenience, but see \pset + about setting other output options. +

\i filename

Reads input from the file filename and executes it as + though it had been typed on the keyboard. +

Note: If you want to see the lines on the screen as they are read you + must set the variable ECHO to + all. +

\ir filename

The \ir command is similar to \i, but resolves + relative file names differently. When executing in interactive mode, + the two commands behave identically. However, when invoked from a + script, \ir interprets file names relative to the + directory in which the script is located, rather than the current + working directory. +

\l (or \list)
\l+ (or \list+)

List the names, owners, character set encodings, and access privileges + of all the databases in the server. + If + is appended to the command name, database + sizes, default tablespaces, and descriptions are also displayed. + (Size information is only available for databases that the current + user can connect to.) +

\lo_export loid filename

Reads the large object with OID loid from the database and + writes it to filename. Note that this is + subtly different from the server function + lo_export, which acts with the permissions + of the user that the database server runs as and on the server's + file system. +

Tip: Use \lo_list to find out the large object's + OID. +

\lo_import filename [ comment ]

Stores the file into a PostgreSQL + large object. Optionally, it associates the given + comment with the object. Example: +

foo=> \lo_import '/home/peter/pictures/photo.xcf' 'a picture of me'
+lo_import 152801

+ The response indicates that the large object received object + ID 152801, which can be used to access the newly-created large + object in the future. For the sake of readability, it is + recommended to always associate a human-readable comment with + every object. Both OIDs and comments can be viewed with the + \lo_list command. +

Note that this command is subtly different from the server-side + lo_import because it acts as the local user + on the local file system, rather than the server's user and file + system. +

\lo_list

Shows a list of all PostgreSQL + large objects currently stored in the database, + along with any comments provided for them. +

\lo_unlink loid

Deletes the large object with OID + loid from the + database. +

Tip: Use \lo_list to find out the large object's + OID. +

\o [ {filename | |command} ]

Saves future query results to the file filename or pipes future results + into a separate Unix shell to execute command. If no arguments are + specified, the query output will be reset to the standard output. +

"Query results" includes all tables, command + responses, and notices obtained from the database server, as + well as output of various backslash commands that query the + database (such as \d), but not error + messages. +

Tip: To intersperse text output in between query results, use + \qecho. +

\p

Print the current query buffer to the standard output. +

\password [ username ]

Changes the password of the specified user (by default, the current + user). This command prompts for the new password, encrypts it, and + sends it to the server as an ALTER ROLE command. This + makes sure that the new password does not appear in cleartext in the + command history, the server log, or elsewhere. +

\prompt [ text ] name

Prompts the user to supply text, which is assigned to the variable + name. + An optional prompt string, text, can be specified. (For multiword + prompts, surround the text with single quotes.) +

By default, \prompt uses the terminal for input and + output. However, if the -f command line switch was + used, \prompt uses standard input and standard output. +

\pset option [ value ]

This command sets options affecting the output of query result tables. + option + indicates which option is to be set. The semantics of + value vary depending + on the selected option. For some options, omitting value causes the option to be toggled + or unset, as described under the particular option. If no such + behavior is mentioned, then omitting + value just results in + the current setting being displayed. +

Adjustable printing options are: +

border

The value must be a + number. In general, the higher + the number the more borders and lines the tables will have, + but this depends on the particular format. In + HTML format, this will translate directly + into the border=... attribute; in the + other formats only values 0 (no border), 1 (internal dividing lines), + and 2 (table frame) make sense. +

columns

Sets the target width for the wrapped format, and also + the width limit for determining whether output is wide enough to + require the pager or switch to the vertical display in expanded auto + mode. + Zero (the default) causes the target width to be controlled by the + environment variable COLUMNS, or the detected screen width + if COLUMNS is not set. + In addition, if columns is zero then the + wrapped format only affects screen output. + If columns is nonzero then file and pipe output is + wrapped to that width as well. +

expanded (or x)

If value is specified it + must be either on or off, which + will enable or disable expanded mode, or auto. + If value is omitted the + command toggles between the on and off settings. When expanded mode + is enabled, query results are displayed in two columns, with the + column name on the left and the data on the right. This mode is + useful if the data wouldn't fit on the screen in the + normal "horizontal" mode. In the auto setting, the + expanded mode is used whenever the query output is wider than the + screen, otherwise the regular mode is used. The auto setting is only + effective in the aligned and wrapped formats. In other formats, it + always behaves as if the expanded mode is off. +

fieldsep

Specifies the field separator to be used in unaligned output + format. That way one can create, for example, tab- or + comma-separated output, which other programs might prefer. To + set a tab as field separator, type \pset fieldsep + '\t'. The default field separator is + '|' (a vertical bar). +

fieldsep_zero

Sets the field separator to use in unaligned output format to a zero + byte. +

footer

If value is specified + it must be either on or off + which will enable or disable display of the table footer + (the (n rows) count). + If value is omitted the + command toggles footer display on or off. +

format

Sets the output format to one of unaligned, + aligned, wrapped, + html, + latex, or troff-ms. + Unique abbreviations are allowed. (That would mean one letter + is enough.) +

unaligned format writes all columns of a row on one + line, separated by the currently active field separator. This + is useful for creating output that might be intended to be read + in by other programs (for example, tab-separated or comma-separated + format). +

aligned format is the standard, human-readable, + nicely formatted text output; this is the default. +

wrapped format is like aligned but wraps + wide data values across lines to make the output fit in the target + column width. The target width is determined as described under + the columns option. Note that psql will + not attempt to wrap column header titles; therefore, + wrapped format behaves the same as aligned + if the total width needed for column headers exceeds the target. +

The html, latex, and troff-ms + formats put out tables that are intended to + be included in documents using the respective mark-up + language. They are not complete documents! (This might not be + so dramatic in HTML, but in LaTeX you must + have a complete document wrapper.) +

linestyle

Sets the border line drawing style to one + of ascii, old-ascii + or unicode. + Unique abbreviations are allowed. (That would mean one + letter is enough.) + The default setting is ascii. + This option only affects the aligned and + wrapped output formats. +

ascii style uses plain ASCII + characters. Newlines in data are shown using + a + symbol in the right-hand margin. + When the wrapped format wraps data from + one line to the next without a newline character, a dot + (.) is shown in the right-hand margin of the first line, + and again in the left-hand margin of the following line. +

old-ascii style uses plain ASCII + characters, using the formatting style used + in PostgreSQL 8.4 and earlier. + Newlines in data are shown using a : + symbol in place of the left-hand column separator. + When the data is wrapped from one line + to the next without a newline character, a ; + symbol is used in place of the left-hand column separator. +

unicode style uses Unicode box-drawing characters. + Newlines in data are shown using a carriage return symbol + in the right-hand margin. When the data is wrapped from one line + to the next without a newline character, an ellipsis symbol + is shown in the right-hand margin of the first line, and + again in the left-hand margin of the following line. +

When the border setting is greater than zero, + this option also determines the characters + with which the border lines are drawn. + Plain ASCII characters work everywhere, but + Unicode characters look nicer on displays that recognize them. +

null

Sets the string to be printed in place of a null value. + The default is to print nothing, which can easily be mistaken for + an empty string. For example, one might prefer \pset null + '(null)'. +

numericlocale

If value is specified + it must be either on or off + which will enable or disable display of a locale-specific character + to separate groups of digits to the left of the decimal marker. + If value is omitted the + command toggles between regular and locale-specific numeric output. +

pager

Controls use of a pager program for query and psql + help output. If the environment variable PAGER + is set, the output is piped to the specified program. + Otherwise a platform-dependent default (such as + more) is used. +

When the pager option is off, the pager + program is not used. When the pager option is + on, the pager is used when appropriate, i.e., when the + output is to a terminal and will not fit on the screen. + The pager option can also be set to always, + which causes the pager to be used for all terminal output regardless + of whether it fits on the screen. \pset pager + without a value + toggles pager use on and off. +

recordsep

Specifies the record (line) separator to use in unaligned + output format. The default is a newline character. +

recordsep_zero

Sets the record separator to use in unaligned output format to a zero + byte. +

tableattr (or T)

Specifies attributes to be placed inside the + HTML table tag in + html output format. This + could for example be cellpadding or + bgcolor. Note that you probably don't want + to specify border here, as that is already + taken care of by \pset border. + If no + value is given, + the table attributes are unset. +

title

Sets the table title for any subsequently printed tables. This + can be used to give your output descriptive tags. If no + value is given, + the title is unset. +

tuples_only (or t)

If value is specified + it must be either on or off + which will enable or disable tuples-only mode. + If value is omitted the + command toggles between regular and tuples-only output. + Regular output includes extra information such + as column headers, titles, and various footers. In tuples-only + mode, only actual table data is shown. +

+

Illustrations of how these different formats look can be seen in + the Examples section. +

Tip: There are various shortcut commands for \pset. See + \a, \C, \H, + \t, \T, and \x. +

Note: It is an error to call \pset without any + arguments. In the future this case might show the current status + of all printing options. +

\q or \quit

Quits the psql program. + In a script file, only execution of that script is terminated. +

\qecho text [ ... ]

This command is identical to \echo except + that the output will be written to the query output channel, as + set by \o. +

\r

Resets (clears) the query buffer. +

\s [ filename ]

Print or save the command line history to filename. If filename is omitted, the history + is written to the standard output. This option is only available + if psql is configured to use the + GNU Readline library. +

\set [ name [ value [ ... ] ] ]

Sets the psql variable name to value, or if more than one value + is given, to the concatenation of all of them. If only one + argument is given, the variable is set with an empty value. To + unset a variable, use the \unset command. +

\set without any arguments displays the names and values + of all currently-set psql variables. +

Valid variable names can contain letters, digits, and + underscores. See the section Variables below for details. + Variable names are case-sensitive. +

Although you are welcome to set any variable to anything you + want, psql treats several variables + as special. They are documented in the section about variables. +

Note: This command is unrelated to the SQL + command SET. +

\setenv [ name [ value ] ]

Sets the environment variable name to value, or if the + value is + not supplied, unsets the environment variable. Example: +

testdb=> \setenv PAGER less
+testdb=> \setenv LESS -imx4F

\sf[+] function_description

This command fetches and shows the definition of the named function, + in the form of a CREATE OR REPLACE FUNCTION command. + The definition is printed to the current query output channel, + as set by \o. +

The target function can be specified by name alone, or by name + and arguments, for example foo(integer, text). + The argument types must be given if there is more + than one function of the same name. +

If + is appended to the command name, then the + output lines are numbered, with the first line of the function body + being line 1. +

\t

Toggles the display of output column name headings and row count + footer. This command is equivalent to \pset + tuples_only and is provided for convenience. +

\T table_options

Specifies attributes to be placed within the + table tag in HTML + output format. This command is equivalent to \pset + tableattr table_options. +

\timing [ on | off ]

Without parameter, toggles a display of how long each SQL statement + takes, in milliseconds. With parameter, sets same. +

\unset name

Unsets (deletes) the psql variable name. +

\w filename
\w |command

Outputs the current query buffer to the file filename or pipes it to the Unix + command command. +

\x [ on | off | auto ]

Sets or toggles expanded table formatting mode. As such it is equivalent to + \pset expanded. +

\z [ pattern ]

Lists tables, views and sequences with their + associated access privileges. + If a pattern is + specified, only tables, views and sequences whose names match the + pattern are listed. +

This is an alias for \dp ("display + privileges"). +

\! [ command ]

Escapes to a separate Unix shell or executes the Unix command + command. The + arguments are not further interpreted; the shell will see them + as-is. +

\?

Shows help information about the backslash commands. +

+

Patterns

The various \d commands accept a pattern parameter to specify the + object name(s) to be displayed. In the simplest case, a pattern + is just the exact name of the object. The characters within a + pattern are normally folded to lower case, just as in SQL names; + for example, \dt FOO will display the table named + foo. As in SQL names, placing double quotes around + a pattern stops folding to lower case. Should you need to include + an actual double quote character in a pattern, write it as a pair + of double quotes within a double-quote sequence; again this is in + accord with the rules for SQL quoted identifiers. For example, + \dt "FOO""BAR" will display the table named + FOO"BAR (not foo"bar). Unlike the normal + rules for SQL names, you can put double quotes around just part + of a pattern, for instance \dt FOO"FOO"BAR will display + the table named fooFOObar. +

Whenever the pattern parameter + is omitted completely, the \d commands display all objects + that are visible in the current schema search path — this is + equivalent to using * as the pattern. + (An object is said to be visible if its + containing schema is in the search path and no object of the same + kind and name appears earlier in the search path. This is equivalent to the + statement that the object can be referenced by name without explicit + schema qualification.) + To see all objects in the database regardless of visibility, + use *.* as the pattern. +

Within a pattern, * matches any sequence of characters + (including no characters) and ? matches any single character. + (This notation is comparable to Unix shell file name patterns.) + For example, \dt int* displays tables whose names + begin with int. But within double quotes, * + and ? lose these special meanings and are just matched + literally. +

A pattern that contains a dot (.) is interpreted as a schema + name pattern followed by an object name pattern. For example, + \dt foo*.*bar* displays all tables whose table name + includes bar that are in schemas whose schema name + starts with foo. When no dot appears, then the pattern + matches only objects that are visible in the current schema search path. + Again, a dot within double quotes loses its special meaning and is matched + literally. +

Advanced users can use regular-expression notations such as character + classes, for example [0-9] to match any digit. All regular + expression special characters work as specified in + Section 9.7.3, except for . which + is taken as a separator as mentioned above, * which is + translated to the regular-expression notation .*, + ? which is translated to ., and + $ which is matched literally. You can emulate + these pattern characters at need by writing + ? for ., + (R+|) for + R*, or + (R|) for + R?. + $ is not needed as a regular-expression character since + the pattern must match the whole name, unlike the usual + interpretation of regular expressions (in other words, $ + is automatically appended to your pattern). Write * at the + beginning and/or end if you don't wish the pattern to be anchored. + Note that within double quotes, all regular expression special characters + lose their special meanings and are matched literally. Also, the regular + expression special characters are matched literally in operator name + patterns (i.e., the argument of \do). +

Advanced Features

Variables

psql provides variable substitution + features similar to common Unix command shells. + Variables are simply name/value pairs, where the value + can be any string of any length. The name must consist of letters + (including non-Latin letters), digits, and underscores. +

To set a variable, use the psql meta-command + \set. For example, +

testdb=> \set foo bar

+ sets the variable foo to the value + bar. To retrieve the content of the variable, precede + the name with a colon, for example: +

testdb=> \echo :foo
+bar

+ This works in both regular SQL commands and meta-commands; there is + more detail in SQL Interpolation, below. +

If you call \set without a second argument, the + variable is set, with an empty string as value. To unset (i.e., delete) + a variable, use the command \unset. To show the + values of all variables, call \set without any argument. +

Note: The arguments of \set are subject to the same + substitution rules as with other commands. Thus you can construct + interesting references such as \set :foo + 'something' and get "soft links" or + "variable variables" of Perl + or PHP fame, + respectively. Unfortunately (or fortunately?), there is no way to do + anything useful with these constructs. On the other hand, + \set bar :foo is a perfectly valid way to copy a + variable. +

A number of these variables are treated specially + by psql. They represent certain option + settings that can be changed at run time by altering the value of + the variable, or in some cases represent changeable state of + psql. Although + you can use these variables for other purposes, this is not + recommended, as the program behavior might grow really strange + really quickly. By convention, all specially treated variables' names + consist of all upper-case ASCII letters (and possibly digits and + underscores). To ensure maximum compatibility in the future, avoid + using such variable names for your own purposes. A list of all specially + treated variables follows. +

AUTOCOMMIT

When on (the default), each SQL command is automatically + committed upon successful completion. To postpone commit in this + mode, you must enter a BEGIN or START + TRANSACTION SQL command. When off or unset, SQL + commands are not committed until you explicitly issue + COMMIT or END. The autocommit-off + mode works by issuing an implicit BEGIN for you, just + before any command that is not already in a transaction block and + is not itself a BEGIN or other transaction-control + command, nor a command that cannot be executed inside a transaction + block (such as VACUUM). +

Note: In autocommit-off mode, you must explicitly abandon any failed + transaction by entering ABORT or ROLLBACK. + Also keep in mind that if you exit the session + without committing, your work will be lost. +

Note: The autocommit-on mode is PostgreSQL's traditional + behavior, but autocommit-off is closer to the SQL spec. If you + prefer autocommit-off, you might wish to set it in the system-wide + psqlrc file or your + ~/.psqlrc file. +

COMP_KEYWORD_CASE

Determines which letter case to use when completing an SQL key word. + If set to lower or upper, the + completed word will be in lower or upper case, respectively. If set + to preserve-lower + or preserve-upper (the default), the completed word + will be in the case of the word already entered, but words being + completed without anything entered will be in lower or upper case, + respectively. +

DBNAME

The name of the database you are currently connected to. This is + set every time you connect to a database (including program + start-up), but can be unset. +

ECHO

If set to all, all lines + entered from the keyboard or from a script are written to the standard output + before they are parsed or executed. To select this behavior on program + start-up, use the switch -a. If set to + queries, + psql merely prints all queries as + they are sent to the server. The switch for this is + -e. +

ECHO_HIDDEN

When this variable is set and a backslash command queries the + database, the query is first shown. This way you can study the + PostgreSQL internals and provide + similar functionality in your own programs. (To select this behavior + on program start-up, use the switch -E.) If you set + the variable to the value noexec, the queries are + just shown but are not actually sent to the server and executed. +

ENCODING

The current client character set encoding. +

FETCH_COUNT

If this variable is set to an integer value > 0, + the results of SELECT queries are fetched + and displayed in groups of that many rows, rather than the + default behavior of collecting the entire result set before + display. Therefore only a + limited amount of memory is used, regardless of the size of + the result set. Settings of 100 to 1000 are commonly used + when enabling this feature. + Keep in mind that when using this feature, a query might + fail after having already displayed some rows. +

Tip: Although you can use any output format with this feature, + the default aligned format tends to look bad + because each group of FETCH_COUNT rows + will be formatted separately, leading to varying column + widths across the row groups. The other output formats work better. +

HISTCONTROL

If this variable is set to ignorespace, + lines which begin with a space are not entered into the history + list. If set to a value of ignoredups, lines + matching the previous history line are not entered. A value of + ignoreboth combines the two options. If + unset, or if set to any other value than those above, all lines + read in interactive mode are saved on the history list. +

Note: This feature was shamelessly plagiarized from + Bash. +

HISTFILE

The file name that will be used to store the history list. The default + value is ~/.psql_history. For example, putting: +

\set HISTFILE ~/.psql_history- :DBNAME

+ in ~/.psqlrc will cause + psql to maintain a separate history for + each database. +

Note: This feature was shamelessly plagiarized from + Bash. +

HISTSIZE

The number of commands to store in the command history. The + default value is 500. +

Note: This feature was shamelessly plagiarized from + Bash. +

HOST

The database server host you are currently connected to. This is + set every time you connect to a database (including program + start-up), but can be unset. +

IGNOREEOF

If unset, sending an EOF character (usually + Control+D) + to an interactive session of psql + will terminate the application. If set to a numeric value, + that many EOF characters are ignored before the + application terminates. If the variable is set but has no + numeric value, the default is 10. +

Note: This feature was shamelessly plagiarized from + Bash. +

LASTOID

The value of the last affected OID, as returned from an + INSERT or \lo_import + command. This variable is only guaranteed to be valid until + after the result of the next SQL command has + been displayed. +

ON_ERROR_ROLLBACK

When on, if a statement in a transaction block + generates an error, the error is ignored and the transaction + continues. When interactive, such errors are only + ignored in interactive sessions, and not when reading script + files. When off (the default), a statement in a + transaction block that generates an error aborts the entire + transaction. The on_error_rollback-on mode works by issuing an + implicit SAVEPOINT for you, just before each command + that is in a transaction block, and rolls back to the savepoint + on error. +

ON_ERROR_STOP

By default, command processing continues after an error. When this + variable is set, it will instead stop immediately. In interactive mode, + psql will return to the command prompt; + otherwise, psql will exit, returning + error code 3 to distinguish this case from fatal error + conditions, which are reported using error code 1. In either case, + any currently running scripts (the top-level script, if any, and any + other scripts which it may have in invoked) will be terminated + immediately. If the top-level command string contained multiple SQL + commands, processing will stop with the current command. +

PORT

The database server port to which you are currently connected. + This is set every time you connect to a database (including + program start-up), but can be unset. +

PROMPT1
PROMPT2
PROMPT3

These specify what the prompts psql + issues should look like. See Prompting below. +

QUIET

This variable is equivalent to the command line option + -q. It is probably not too useful in + interactive mode. +

SINGLELINE

This variable is equivalent to the command line option + -S. +

SINGLESTEP

This variable is equivalent to the command line option + -s. +

USER

The database user you are currently connected as. This is set + every time you connect to a database (including program + start-up), but can be unset. +

VERBOSITY

This variable can be set to the values default, + verbose, or terse to control the verbosity + of error reports. +

SQL Interpolation

A key feature of psql + variables is that you can substitute ("interpolate") + them into regular SQL statements, as well as the + arguments of meta-commands. Furthermore, + psql provides facilities for + ensuring that variable values used as SQL literals and identifiers are + properly quoted. The syntax for interpolating a value without + any quoting is to prepend the variable name with a colon + (:). For example, +

testdb=> \set foo 'my_table'
+testdb=> SELECT * FROM :foo;

+ would query the table my_table. Note that this + may be unsafe: the value of the variable is copied literally, so it can + contain unbalanced quotes, or even backslash commands. You must make sure + that it makes sense where you put it. +

When a value is to be used as an SQL literal or identifier, it is + safest to arrange for it to be quoted. To quote the value of + a variable as an SQL literal, write a colon followed by the variable + name in single quotes. To quote the value as an SQL identifier, write + a colon followed by the variable name in double quotes. + These constructs deal correctly with quotes and other special + characters embedded within the variable value. + The previous example would be more safely written this way: +

testdb=> \set foo 'my_table'
+testdb=> SELECT * FROM :"foo";

+

Variable interpolation will not be performed within quoted + SQL literals and identifiers. Therefore, a + construction such as ':foo' doesn't work to produce a quoted + literal from a variable's value (and it would be unsafe if it did work, + since it wouldn't correctly handle quotes embedded in the value). +

One example use of this mechanism is to + copy the contents of a file into a table column. + First load the file into a variable and then interpolate the variable's + value as a quoted string: +

testdb=> \set content `cat my_file.txt`
+testdb=> INSERT INTO my_table VALUES (:'content');

+ (Note that this still won't work if my_file.txt contains NUL bytes. + psql does not support embedded NUL bytes in variable values.) +

Since colons can legally appear in SQL commands, an apparent attempt + at interpolation (that is, :name, + :'name', or :"name") is not + replaced unless the named variable is currently set. In any case, you + can escape a colon with a backslash to protect it from substitution. +

The colon syntax for variables is standard SQL for + embedded query languages, such as ECPG. + The colon syntaxes for array slices and type casts are + PostgreSQL extensions, which can sometimes + conflict with the standard usage. The colon-quote syntax for escaping a + variable's value as an SQL literal or identifier is a + psql extension. +

Prompting

The prompts psql issues can be customized + to your preference. The three variables PROMPT1, + PROMPT2, and PROMPT3 contain strings + and special escape sequences that describe the appearance of the + prompt. Prompt 1 is the normal prompt that is issued when + psql requests a new command. Prompt 2 is + issued when more input is expected during command input because the + command was not terminated with a semicolon or a quote was not closed. + Prompt 3 is issued when you run an SQL + COPY command and you are expected to type in the + row values on the terminal. +

The value of the selected prompt variable is printed literally, + except where a percent sign (%) is encountered. + Depending on the next character, certain other text is substituted + instead. Defined substitutions are: + +

%M

The full host name (with domain name) of the database server, + or [local] if the connection is over a Unix + domain socket, or + [local:/dir/name], + if the Unix domain socket is not at the compiled in default + location. +

%m

The host name of the database server, truncated at the + first dot, or [local] if the connection is + over a Unix domain socket. +

%>

The port number at which the database server is listening.

%n

The database session user name. (The expansion of this + value might change during a database session as the result + of the command SET SESSION + AUTHORIZATION.) +

%/

The name of the current database.

%~

Like %/, but the output is ~ + (tilde) if the database is your default database.

%#

If the session user is a database superuser, then a + #, otherwise a >. + (The expansion of this value might change during a database + session as the result of the command SET SESSION + AUTHORIZATION.) +

%R

In prompt 1 normally =, but ^ if + in single-line mode, and ! if the session is + disconnected from the database (which can happen if + \connect fails). In prompt 2 the sequence is + replaced by -, *, a single quote, + a double quote, or a dollar sign, depending on whether + psql expects more input because the + command wasn't terminated yet, because you are inside a + /* ... */ comment, or because you are inside + a quoted or dollar-escaped string. In prompt 3 the sequence doesn't + produce anything. +

%x

Transaction status: an empty string when not in a transaction + block, or * when in a transaction block, or + ! when in a failed transaction block, or ? + when the transaction state is indeterminate (for example, because + there is no connection). +

%digits

The character with the indicated octal code is substituted. +

%:name:

The value of the psql variable + name. See the + section Variables for details. +

%`command`

The output of command, similar to ordinary + "back-tick" substitution. +

%[ ... %]

Prompts can contain terminal control characters which, for + example, change the color, background, or style of the prompt + text, or change the title of the terminal window. In order for + the line editing features of Readline to work properly, these + non-printing control characters must be designated as invisible + by surrounding them with %[ and + %]. Multiple pairs of these can occur within + the prompt. For example: +

testdb=> \set PROMPT1 '%[%033[1;33;40m%]%n@%/%R%[%033[0m%]%# '

+ results in a boldfaced (1;) yellow-on-black + (33;40) prompt on VT100-compatible, color-capable + terminals. +

+ + To insert a percent sign into your prompt, write + %%. The default prompts are + '%/%R%# ' for prompts 1 and 2, and + '>> ' for prompt 3. +

Note: This feature was shamelessly plagiarized from + tcsh. +

Command-Line Editing

psql supports the Readline + library for convenient line editing and retrieval. The command + history is automatically saved when psql + exits and is reloaded when + psql starts up. Tab-completion is also + supported, although the completion logic makes no claim to be an + SQL parser. If for some reason you do not like the tab completion, you + can turn it off by putting this in a file named + .inputrc in your home directory: +

$if psql
+set disable-completion on
+$endif

+ (This is not a psql but a + Readline feature. Read its documentation + for further details.) +

Environment

COLUMNS

If \pset columns is zero, controls the + width for the wrapped format and width for determining + if wide output requires the pager or should be switched to the + vertical format in expanded auto mode. +

PAGER

If the query results do not fit on the screen, they are piped + through this command. Typical values are + more or less. The default + is platform-dependent. The use of the pager can be disabled by + using the \pset command. +

PGDATABASE
PGHOST
PGPORT
PGUSER

Default connection parameters (see Section 31.14). +

PSQL_EDITOR
EDITOR
VISUAL

Editor used by the \e and + \ef commands. The variables are examined in + the order listed; the first that is set is used. +

The built-in default editors are vi on Unix + systems and notepad.exe on Windows systems. +

PSQL_EDITOR_LINENUMBER_ARG

When \e or \ef is used + with a line number argument, this variable specifies the + command-line argument used to pass the starting line number to + the user's editor. For editors such as Emacs or + vi, this is a plus sign. Include a trailing + space in the value of the variable if there needs to be space + between the option name and the line number. Examples: +

PSQL_EDITOR_LINENUMBER_ARG='+'
+PSQL_EDITOR_LINENUMBER_ARG='--line '

+

The default is + on Unix systems + (corresponding to the default editor vi, + and useful for many other common editors); but there is no + default on Windows systems. +

PSQL_HISTORY

Alternative location for the command history file. Tilde (~) expansion is performed. +

PSQLRC

Alternative location of the user's .psqlrc file. Tilde (~) expansion is performed. +

SHELL

Command executed by the \! command. +

TMPDIR

Directory for storing temporary files. The default is + /tmp. +

This utility, like most other PostgreSQL utilities, + also uses the environment variables supported by libpq + (see Section 31.14). +

Files

  • Unless it is passed an -X + or -c option, + psql attempts to + read and execute commands from the system-wide + psqlrc file and the user's + ~/.psqlrc file before starting up. + (On Windows, the user's startup file is named + %APPDATA%\postgresql\psqlrc.conf.) + See PREFIX/share/psqlrc.sample + for information on setting up the system-wide file. It could be used + to set up the client or the server to taste (using the \set + and SET commands). +

    The location of the user's ~/.psqlrc file can + also be set explicitly via the PSQLRC environment + setting. +

  • Both the system-wide psqlrc file and the user's + ~/.psqlrc file can be made psql-version-specific + by appending a dash and the PostgreSQL + major or minor psql release number, + for example ~/.psqlrc-9.2 or + ~/.psqlrc-9.2.5. The most specific + version-matching file will be read in preference to a + non-version-specific file. +

  • The command-line history is stored in the file + ~/.psql_history, or + %APPDATA%\postgresql\psql_history on Windows. +

    The location of the history file can + also be set explicitly via the PSQL_HISTORY environment + setting. +

Notes

  • In an earlier life psql allowed the + first argument of a single-letter backslash command to start + directly after the command, without intervening whitespace. + As of PostgreSQL 8.4 this is no + longer allowed. +

  • psql is only guaranteed to work smoothly + with servers of the same version. That does not mean other combinations + will fail outright, but subtle and not-so-subtle problems might come + up. Backslash commands are particularly likely to fail if the + server is of a newer version than psql itself. However, + backslash commands of the \d family should work with + servers of versions back to 7.4, though not necessarily with servers + newer than psql itself. +

Notes for Windows Users

psql is built as a "console + application". Since the Windows console windows use a different + encoding than the rest of the system, you must take special care + when using 8-bit characters within psql. + If psql detects a problematic + console code page, it will warn you at startup. To change the + console code page, two things are necessary: + +

  • Set the code page by entering cmd.exe /c chcp + 1252. (1252 is a code page that is appropriate for + German; replace it with your value.) If you are using Cygwin, + you can put this command in /etc/profile. +

  • Set the console font to Lucida Console, because the + raster font does not work with the ANSI code page. +

Examples

The first example shows how to spread a command over several lines of + input. Notice the changing prompt: +

testdb=> CREATE TABLE my_table (
+testdb(>  first integer not null default 0,
+testdb(>  second text)
+testdb-> ;
+CREATE TABLE

+ Now look at the table definition again: +

testdb=> \d my_table
+             Table "my_table"
+ Attribute |  Type   |      Modifier
+-----------+---------+--------------------
+ first     | integer | not null default 0
+ second    | text    |

+ Now we change the prompt to something more interesting: +

testdb=> \set PROMPT1 '%n@%m %~%R%# '
+peter@localhost testdb=>

+ Let's assume you have filled the table with data and want to take a + look at it: +

peter@localhost testdb=> SELECT * FROM my_table;
+ first | second
+-------+--------
+     1 | one
+     2 | two
+     3 | three
+     4 | four
+(4 rows)

+ You can display tables in different ways by using the + \pset command: +

peter@localhost testdb=> \pset border 2
+Border style is 2.
+peter@localhost testdb=> SELECT * FROM my_table;
++-------+--------+
+| first | second |
++-------+--------+
+|     1 | one    |
+|     2 | two    |
+|     3 | three  |
+|     4 | four   |
++-------+--------+
+(4 rows)
+
+peter@localhost testdb=> \pset border 0
+Border style is 0.
+peter@localhost testdb=> SELECT * FROM my_table;
+first second
+----- ------
+    1 one
+    2 two
+    3 three
+    4 four
+(4 rows)
+
+peter@localhost testdb=> \pset border 1
+Border style is 1.
+peter@localhost testdb=> \pset format unaligned
+Output format is unaligned.
+peter@localhost testdb=> \pset fieldsep ","
+Field separator is ",".
+peter@localhost testdb=> \pset tuples_only
+Showing only tuples.
+peter@localhost testdb=> SELECT second, first FROM my_table;
+one,1
+two,2
+three,3
+four,4

+ Alternatively, use the short commands: +

peter@localhost testdb=> \a \t \x
+Output format is aligned.
+Tuples only is off.
+Expanded display is on.
+peter@localhost testdb=> SELECT * FROM my_table;
+-[ RECORD 1 ]-
+first  | 1
+second | one
+-[ RECORD 2 ]-
+first  | 2
+second | two
+-[ RECORD 3 ]-
+first  | 3
+second | three
+-[ RECORD 4 ]-
+first  | 4
+second | four


PrevHomeNext
pg_restoreUpreindexdb
\ No newline at end of file diff --git a/doc/src/sgml/html/app-reindexdb.html b/doc/src/sgml/html/app-reindexdb.html new file mode 100644 index 000000000..b541dc7b6 --- /dev/null +++ b/doc/src/sgml/html/app-reindexdb.html @@ -0,0 +1,832 @@ + +reindexdb

reindexdb

Name

reindexdb -- reindex a PostgreSQL database

Synopsis

reindexdb [connection-option...] [ --table | -t table] [ --index | -i index] [dbname]

reindexdb [connection-option...] --all | -a

reindexdb [connection-option...] --system | -s [dbname]

Description

reindexdb is a utility for rebuilding indexes + in a PostgreSQL database. +

reindexdb is a wrapper around the SQL + command REINDEX. + There is no effective difference between reindexing databases via + this utility and via other methods for accessing the server. +

Options

reindexdb accepts the following command-line arguments: + +

-a
--all

Reindex all databases. +

[-d] dbname
[--dbname=]dbname

Specifies the name of the database to be reindexed. + If this is not specified and -a (or + --all) is not used, the database name is read + from the environment variable PGDATABASE. If + that is not set, the user name specified for the connection is + used. +

-e
--echo

Echo the commands that reindexdb generates + and sends to the server. +

-i index
--index=index

Recreate index only. +

-q
--quiet

Do not display progress messages. +

-s
--system

Reindex database's system catalogs. +

-t table
--table=table

Reindex table only. +

-V
--version

Print the reindexdb version and exit. +

-?
--help

Show help about reindexdb command line + arguments, and exit. +

+ +

reindexdb also accepts + the following command-line arguments for connection parameters: + +

-h host
--host=host

Specifies the host name of the machine on which the server is + running. If the value begins with a slash, it is used as the + directory for the Unix domain socket. +

-p port
--port=port

Specifies the TCP port or local Unix domain socket file + extension on which the server + is listening for connections. +

-U username
--username=username

User name to connect as. +

-w
--no-password

Never issue a password prompt. If the server requires + password authentication and a password is not available by + other means such as a .pgpass file, the + connection attempt will fail. This option can be useful in + batch jobs and scripts where no user is present to enter a + password. +

-W
--password

Force reindexdb to prompt for a + password before connecting to a database. +

This option is never essential, since + reindexdb will automatically prompt + for a password if the server demands password authentication. + However, reindexdb will waste a + connection attempt finding out that the server wants a password. + In some cases it is worth typing -W to avoid the extra + connection attempt. +

--maintenance-db=dbname

Specifies the name of the database to connect to discover what other + databases should be reindexed. If not specified, the + postgres database will be used, + and if that does not exist, template1 will be used. +

+

Environment

PGDATABASE
PGHOST
PGPORT
PGUSER

Default connection parameters +

This utility, like most other PostgreSQL utilities, + also uses the environment variables supported by libpq + (see Section 31.14). +

Diagnostics

In case of difficulty, see REINDEX + and psql for + discussions of potential problems and error messages. + The database server must be running at the + targeted host. Also, any default connection settings and environment + variables used by the libpq front-end + library will apply. +

Notes

reindexdb might need to connect several + times to the PostgreSQL server, asking + for a password each time. It is convenient to have a + ~/.pgpass file in such cases. See Section 31.15 for more information. +

Examples

To reindex the database test: +

$ reindexdb test

+

To reindex the table foo and the index + bar in a database named abcd: +

$ reindexdb --table foo --index bar abcd

See Also

REINDEX

PrevHomeNext
psqlUpvacuumdb
\ No newline at end of file diff --git a/doc/src/sgml/html/app-vacuumdb.html b/doc/src/sgml/html/app-vacuumdb.html new file mode 100644 index 000000000..8b88fe591 --- /dev/null +++ b/doc/src/sgml/html/app-vacuumdb.html @@ -0,0 +1,900 @@ + +vacuumdb

vacuumdb

Name

vacuumdb -- garbage-collect and analyze a PostgreSQL database

Synopsis

vacuumdb [connection-option...] [option...] [ --table | -t + table + [( column [,...] )] + ] [dbname]

vacuumdb [connection-option...] [option...] --all | -a

Description

vacuumdb is a utility for cleaning a + PostgreSQL database. + vacuumdb will also generate internal statistics + used by the PostgreSQL query optimizer. +

vacuumdb is a wrapper around the SQL + command VACUUM. + There is no effective difference between vacuuming and analyzing + databases via this utility and via other methods for accessing the + server. +

Options

vacuumdb accepts the following command-line arguments: +

-a
--all

Vacuum all databases. +

[-d] dbname
[--dbname=]dbname

Specifies the name of the database to be cleaned or analyzed. + If this is not specified and -a (or + --all) is not used, the database name is read + from the environment variable PGDATABASE. If + that is not set, the user name specified for the connection is + used. +

-e
--echo

Echo the commands that vacuumdb generates + and sends to the server. +

-f
--full

Perform "full" vacuuming. +

-F
--freeze

Aggressively "freeze" tuples. +

-q
--quiet

Do not display progress messages. +

-t table [ (column [,...]) ]
--table=table [ (column [,...]) ]

Clean or analyze table only. + Column names can be specified only in conjunction with + the --analyze or --analyze-only options. +

Tip: If you specify columns, you probably have to escape the parentheses + from the shell. (See examples below.) +

-v
--verbose

Print detailed information during processing. +

-V
--version

Print the vacuumdb version and exit. +

-z
--analyze

Also calculate statistics for use by the optimizer. +

-Z
--analyze-only

Only calculate statistics for use by the optimizer (no vacuum). +

-?
--help

Show help about vacuumdb command line + arguments, and exit. +

+

vacuumdb also accepts + the following command-line arguments for connection parameters: +

-h host
--host=host

Specifies the host name of the machine on which the server + is running. If the value begins with a slash, it is used + as the directory for the Unix domain socket. +

-p port
--port=port

Specifies the TCP port or local Unix domain socket file + extension on which the server + is listening for connections. +

-U username
--username=username

User name to connect as. +

-w
--no-password

Never issue a password prompt. If the server requires + password authentication and a password is not available by + other means such as a .pgpass file, the + connection attempt will fail. This option can be useful in + batch jobs and scripts where no user is present to enter a + password. +

-W
--password

Force vacuumdb to prompt for a + password before connecting to a database. +

This option is never essential, since + vacuumdb will automatically prompt + for a password if the server demands password authentication. + However, vacuumdb will waste a + connection attempt finding out that the server wants a password. + In some cases it is worth typing -W to avoid the extra + connection attempt. +

--maintenance-db=dbname

Specifies the name of the database to connect to discover what other + databases should be vacuumed. If not specified, the + postgres database will be used, + and if that does not exist, template1 will be used. +

+

Environment

PGDATABASE
PGHOST
PGPORT
PGUSER

Default connection parameters +

This utility, like most other PostgreSQL utilities, + also uses the environment variables supported by libpq + (see Section 31.14). +

Diagnostics

In case of difficulty, see VACUUM + and psql for + discussions of potential problems and error messages. + The database server must be running at the + targeted host. Also, any default connection settings and environment + variables used by the libpq front-end + library will apply. +

Notes

vacuumdb might need to connect several + times to the PostgreSQL server, asking + for a password each time. It is convenient to have a + ~/.pgpass file in such cases. See Section 31.15 for more information. +

Examples

To clean the database test: +

$ vacuumdb test

+

To clean and analyze for the optimizer a database named + bigdb: +

$ vacuumdb --analyze bigdb

+

To clean a single table + foo in a database named + xyzzy, and analyze a single column + bar of the table for the optimizer: +

$ vacuumdb --analyze --verbose --table 'foo(bar)' xyzzy

See Also

VACUUM

PrevHomeNext
reindexdbUpPostgreSQL Server Applications
\ No newline at end of file diff --git a/doc/src/sgml/html/appendixes.html b/doc/src/sgml/html/appendixes.html new file mode 100644 index 000000000..8c63110a8 --- /dev/null +++ b/doc/src/sgml/html/appendixes.html @@ -0,0 +1,1716 @@ + +Appendixes

VIII. Appendixes

Table of Contents
A. PostgreSQL Error Codes
B. Date/Time Support
B.1. Date/Time Input Interpretation
B.2. Date/Time Key Words
B.3. Date/Time Configuration Files
B.4. History of Units
C. SQL Key Words
D. SQL Conformance
D.1. Supported Features
D.2. Unsupported Features
E. Release Notes
E.1. Release 9.2.2
E.2. Release 9.2.1
E.3. Release 9.2
E.4. Release 9.1.7
E.5. Release 9.1.6
E.6. Release 9.1.5
E.7. Release 9.1.4
E.8. Release 9.1.3
E.9. Release 9.1.2
E.10. Release 9.1.1
E.11. Release 9.1
E.12. Release 9.0.11
E.13. Release 9.0.10
E.14. Release 9.0.9
E.15. Release 9.0.8
E.16. Release 9.0.7
E.17. Release 9.0.6
E.18. Release 9.0.5
E.19. Release 9.0.4
E.20. Release 9.0.3
E.21. Release 9.0.2
E.22. Release 9.0.1
E.23. Release 9.0
E.24. Release 8.4.15
E.25. Release 8.4.14
E.26. Release 8.4.13
E.27. Release 8.4.12
E.28. Release 8.4.11
E.29. Release 8.4.10
E.30. Release 8.4.9
E.31. Release 8.4.8
E.32. Release 8.4.7
E.33. Release 8.4.6
E.34. Release 8.4.5
E.35. Release 8.4.4
E.36. Release 8.4.3
E.37. Release 8.4.2
E.38. Release 8.4.1
E.39. Release 8.4
E.40. Release 8.3.22
E.41. Release 8.3.21
E.42. Release 8.3.20
E.43. Release 8.3.19
E.44. Release 8.3.18
E.45. Release 8.3.17
E.46. Release 8.3.16
E.47. Release 8.3.15
E.48. Release 8.3.14
E.49. Release 8.3.13
E.50. Release 8.3.12
E.51. Release 8.3.11
E.52. Release 8.3.10
E.53. Release 8.3.9
E.54. Release 8.3.8
E.55. Release 8.3.7
E.56. Release 8.3.6
E.57. Release 8.3.5
E.58. Release 8.3.4
E.59. Release 8.3.3
E.60. Release 8.3.2
E.61. Release 8.3.1
E.62. Release 8.3
E.63. Release 8.2.23
E.64. Release 8.2.22
E.65. Release 8.2.21
E.66. Release 8.2.20
E.67. Release 8.2.19
E.68. Release 8.2.18
E.69. Release 8.2.17
E.70. Release 8.2.16
E.71. Release 8.2.15
E.72. Release 8.2.14
E.73. Release 8.2.13
E.74. Release 8.2.12
E.75. Release 8.2.11
E.76. Release 8.2.10
E.77. Release 8.2.9
E.78. Release 8.2.8
E.79. Release 8.2.7
E.80. Release 8.2.6
E.81. Release 8.2.5
E.82. Release 8.2.4
E.83. Release 8.2.3
E.84. Release 8.2.2
E.85. Release 8.2.1
E.86. Release 8.2
E.87. Release 8.1.23
E.88. Release 8.1.22
E.89. Release 8.1.21
E.90. Release 8.1.20
E.91. Release 8.1.19
E.92. Release 8.1.18
E.93. Release 8.1.17
E.94. Release 8.1.16
E.95. Release 8.1.15
E.96. Release 8.1.14
E.97. Release 8.1.13
E.98. Release 8.1.12
E.99. Release 8.1.11
E.100. Release 8.1.10
E.101. Release 8.1.9
E.102. Release 8.1.8
E.103. Release 8.1.7
E.104. Release 8.1.6
E.105. Release 8.1.5
E.106. Release 8.1.4
E.107. Release 8.1.3
E.108. Release 8.1.2
E.109. Release 8.1.1
E.110. Release 8.1
E.111. Release 8.0.26
E.112. Release 8.0.25
E.113. Release 8.0.24
E.114. Release 8.0.23
E.115. Release 8.0.22
E.116. Release 8.0.21
E.117. Release 8.0.20
E.118. Release 8.0.19
E.119. Release 8.0.18
E.120. Release 8.0.17
E.121. Release 8.0.16
E.122. Release 8.0.15
E.123. Release 8.0.14
E.124. Release 8.0.13
E.125. Release 8.0.12
E.126. Release 8.0.11
E.127. Release 8.0.10
E.128. Release 8.0.9
E.129. Release 8.0.8
E.130. Release 8.0.7
E.131. Release 8.0.6
E.132. Release 8.0.5
E.133. Release 8.0.4
E.134. Release 8.0.3
E.135. Release 8.0.2
E.136. Release 8.0.1
E.137. Release 8.0
E.138. Release 7.4.30
E.139. Release 7.4.29
E.140. Release 7.4.28
E.141. Release 7.4.27
E.142. Release 7.4.26
E.143. Release 7.4.25
E.144. Release 7.4.24
E.145. Release 7.4.23
E.146. Release 7.4.22
E.147. Release 7.4.21
E.148. Release 7.4.20
E.149. Release 7.4.19
E.150. Release 7.4.18
E.151. Release 7.4.17
E.152. Release 7.4.16
E.153. Release 7.4.15
E.154. Release 7.4.14
E.155. Release 7.4.13
E.156. Release 7.4.12
E.157. Release 7.4.11
E.158. Release 7.4.10
E.159. Release 7.4.9
E.160. Release 7.4.8
E.161. Release 7.4.7
E.162. Release 7.4.6
E.163. Release 7.4.5
E.164. Release 7.4.4
E.165. Release 7.4.3
E.166. Release 7.4.2
E.167. Release 7.4.1
E.168. Release 7.4
E.169. Release 7.3.21
E.170. Release 7.3.20
E.171. Release 7.3.19
E.172. Release 7.3.18
E.173. Release 7.3.17
E.174. Release 7.3.16
E.175. Release 7.3.15
E.176. Release 7.3.14
E.177. Release 7.3.13
E.178. Release 7.3.12
E.179. Release 7.3.11
E.180. Release 7.3.10
E.181. Release 7.3.9
E.182. Release 7.3.8
E.183. Release 7.3.7
E.184. Release 7.3.6
E.185. Release 7.3.5
E.186. Release 7.3.4
E.187. Release 7.3.3
E.188. Release 7.3.2
E.189. Release 7.3.1
E.190. Release 7.3
E.191. Release 7.2.8
E.192. Release 7.2.7
E.193. Release 7.2.6
E.194. Release 7.2.5
E.195. Release 7.2.4
E.196. Release 7.2.3
E.197. Release 7.2.2
E.198. Release 7.2.1
E.199. Release 7.2
E.200. Release 7.1.3
E.201. Release 7.1.2
E.202. Release 7.1.1
E.203. Release 7.1
E.204. Release 7.0.3
E.205. Release 7.0.2
E.206. Release 7.0.1
E.207. Release 7.0
E.208. Release 6.5.3
E.209. Release 6.5.2
E.210. Release 6.5.1
E.211. Release 6.5
E.212. Release 6.4.2
E.213. Release 6.4.1
E.214. Release 6.4
E.215. Release 6.3.2
E.216. Release 6.3.1
E.217. Release 6.3
E.218. Release 6.2.1
E.219. Release 6.2
E.220. Release 6.1.1
E.221. Release 6.1
E.222. Release 6.0
E.223. Release 1.09
E.224. Release 1.02
E.225. Release 1.01
E.226. Release 1.0
E.227. Postgres95 Release 0.03
E.228. Postgres95 Release 0.02
E.229. Postgres95 Release 0.01
F. Additional Supplied Modules
F.1. adminpack
F.2. auth_delay
F.3. auto_explain
F.4. btree_gin
F.5. btree_gist
F.6. chkpass
F.7. citext
F.8. cube
F.9. dblink
F.10. dict_int
F.11. dict_xsyn
F.12. dummy_seclabel
F.13. earthdistance
F.14. file_fdw
F.15. fuzzystrmatch
F.16. hstore
F.17. intagg
F.18. intarray
F.19. isn
F.20. lo
F.21. ltree
F.22. pageinspect
F.23. passwordcheck
F.24. pg_buffercache
F.25. pgcrypto
F.26. pg_freespacemap
F.27. pgrowlocks
F.28. pg_stat_statements
F.29. pgstattuple
F.30. pg_trgm
F.31. seg
F.32. sepgsql
F.33. spi
F.34. sslinfo
F.35. tablefunc
F.36. tcn
F.37. test_parser
F.38. tsearch2
F.39. unaccent
F.40. uuid-ossp
F.41. xml2
G. Additional Supplied Programs
G.1. Client Applications
G.2. Server Applications
H. External Projects
H.1. Client Interfaces
H.2. Administration Tools
H.3. Procedural Languages
H.4. Extensions
I. The Source Code Repository
I.1. Getting The Source via Git
J. Documentation
J.1. DocBook
J.2. Tool Sets
J.3. Building The Documentation
J.4. Documentation Authoring
J.5. Style Guide
K. Acronyms

PrevHomeNext
Row Estimation Examples PostgreSQL Error Codes
\ No newline at end of file diff --git a/doc/src/sgml/html/applevel-consistency.html b/doc/src/sgml/html/applevel-consistency.html new file mode 100644 index 000000000..c560355c8 --- /dev/null +++ b/doc/src/sgml/html/applevel-consistency.html @@ -0,0 +1,419 @@ + +Data Consistency Checks at the Application Level
PostgreSQL 9.2.2 Documentation
PrevUpChapter 13. Concurrency ControlNext

13.4. Data Consistency Checks at the Application Level

It is very difficult to enforce business rules regarding data integrity + using Read Committed transactions because the view of the data is + shifting with each statement, and even a single statement may not + restrict itself to the statement's snapshot if a write conflict occurs. +

While a Repeatable Read transaction has a stable view of the data + throughout its execution, there is a subtle issue with using + MVCC snapshots for data consistency checks, involving + something known as read/write conflicts. + If one transaction writes data and a concurrent transaction attempts + to read the same data (whether before or after the write), it cannot + see the work of the other transaction. The reader then appears to have + executed first regardless of which started first or which committed + first. If that is as far as it goes, there is no problem, but + if the reader also writes data which is read by a concurrent transaction + there is now a transaction which appears to have run before either of + the previously mentioned transactions. If the transaction which appears + to have executed last actually commits first, it is very easy for a + cycle to appear in a graph of the order of execution of the transactions. + When such a cycle appears, integrity checks will not work correctly + without some help. +

As mentioned in Section 13.2.3, Serializable + transactions are just Repeatable Read transactions which add + non-blocking monitoring for dangerous patterns of read/write conflicts. + When a pattern is detected which could cause a cycle in the apparent + order of execution, one of the transactions involved is rolled back to + break the cycle. +

13.4.1. Enforcing Consistency With Serializable Transactions

If the Serializable transaction isolation level is used for all writes + and for all reads which need a consistent view of the data, no other + effort is required to ensure consistency. Software from other + environments which is written to use serializable transactions to + ensure consistency should "just work" in this regard in + PostgreSQL. +

When using this technique, it will avoid creating an unnecessary burden + for application programmers if the application software goes through a + framework which automatically retries transactions which are rolled + back with a serialization failure. It may be a good idea to set + default_transaction_isolation to serializable. + It would also be wise to take some action to ensure that no other + transaction isolation level is used, either inadvertently or to + subvert integrity checks, through checks of the transaction isolation + level in triggers. +

See Section 13.2.3 for performance suggestions. +

Warning

This level of integrity protection using Serializable transactions + does not yet extend to hot standby mode (Section 25.5). + Because of that, those using hot standby may want to use Repeatable + Read and explicit locking.on the master. +

13.4.2. Enforcing Consistency With Explicit Blocking Locks

When non-serializable writes are possible, + to ensure the current validity of a row and protect it against + concurrent updates one must use SELECT FOR UPDATE, + SELECT FOR SHARE, or an appropriate LOCK + TABLE statement. (SELECT FOR UPDATE + and SELECT FOR SHARE lock just the + returned rows against concurrent updates, while LOCK + TABLE locks the whole table.) This should be taken into + account when porting applications to + PostgreSQL from other environments. +

Also of note to those converting from other environments is the fact + that SELECT FOR UPDATE does not ensure that a + concurrent transaction will not update or delete a selected row. + To do that in PostgreSQL you must actually + update the row, even if no values need to be changed. + SELECT FOR UPDATE temporarily blocks + other transactions from acquiring the same lock or executing an + UPDATE or DELETE which would + affect the locked row, but once the transaction holding this lock + commits or rolls back, a blocked transaction will proceed with the + conflicting operation unless an actual UPDATE of + the row was performed while the lock was held. +

Global validity checks require extra thought under + non-serializable MVCC. + For example, a banking application might wish to check that the sum of + all credits in one table equals the sum of debits in another table, + when both tables are being actively updated. Comparing the results of two + successive SELECT sum(...) commands will not work reliably in + Read Committed mode, since the second query will likely include the results + of transactions not counted by the first. Doing the two sums in a + single repeatable read transaction will give an accurate picture of only the + effects of transactions that committed before the repeatable read transaction + started — but one might legitimately wonder whether the answer is still + relevant by the time it is delivered. If the repeatable read transaction + itself applied some changes before trying to make the consistency check, + the usefulness of the check becomes even more debatable, since now it + includes some but not all post-transaction-start changes. In such cases + a careful person might wish to lock all tables needed for the check, + in order to get an indisputable picture of current reality. A + SHARE mode (or higher) lock guarantees that there are no + uncommitted changes in the locked table, other than those of the current + transaction. +

Note also that if one is relying on explicit locking to prevent concurrent + changes, one should either use Read Committed mode, or in Repeatable Read + mode be careful to obtain + locks before performing queries. A lock obtained by a + repeatable read transaction guarantees that no other transactions modifying + the table are still running, but if the snapshot seen by the + transaction predates obtaining the lock, it might predate some now-committed + changes in the table. A repeatable read transaction's snapshot is actually + frozen at the start of its first query or data-modification command + (SELECT, INSERT, + UPDATE, or DELETE), so + it is possible to obtain locks explicitly before the snapshot is + frozen. +


PrevHomeNext
Explicit LockingUpLocking and Indexes
\ No newline at end of file diff --git a/doc/src/sgml/html/archive-recovery-settings.html b/doc/src/sgml/html/archive-recovery-settings.html new file mode 100644 index 000000000..1bc387b51 --- /dev/null +++ b/doc/src/sgml/html/archive-recovery-settings.html @@ -0,0 +1,357 @@ + +Archive Recovery Settings
PostgreSQL 9.2.2 Documentation
PrevUpChapter 26. Recovery ConfigurationNext

26.1. Archive Recovery Settings

restore_command (string)

The shell command to execute to retrieve an archived segment of + the WAL file series. This parameter is required for archive recovery, + but optional for streaming replication. + Any %f in the string is + replaced by the name of the file to retrieve from the archive, + and any %p is replaced by the copy destination path name + on the server. + (The path name is relative to the current working directory, + i.e., the cluster's data directory.) + Any %r is replaced by the name of the file containing the + last valid restart point. That is the earliest file that must be kept + to allow a restore to be restartable, so this information can be used + to truncate the archive to just the minimum required to support + restarting from the current restore. %r is typically only + used by warm-standby configurations + (see Section 25.2). + Write %% to embed an actual % character. +

It is important for the command to return a zero exit status + only if it succeeds. The command will be asked for file + names that are not present in the archive; it must return nonzero + when so asked. Examples: +

restore_command = 'cp /mnt/server/archivedir/%f "%p"'
+restore_command = 'copy "C:\\server\\archivedir\\%f" "%p"'  # Windows

+

archive_cleanup_command (string)

This optional parameter specifies a shell command that will be executed + at every restartpoint. The purpose of + archive_cleanup_command is to provide a mechanism for + cleaning up old archived WAL files that are no longer needed by the + standby server. + Any %r is replaced by the name of the file containing the + last valid restart point. + That is the earliest file that must be kept to allow a + restore to be restartable, and so all files earlier than %r + may be safely removed. + This information can be used to truncate the archive to just the + minimum required to support restart from the current restore. + The pg_archivecleanup module + is often used in archive_cleanup_command for + single-standby configurations, for example: +

archive_cleanup_command = 'pg_archivecleanup /mnt/server/archivedir %r'

+ Note however that if multiple standby servers are restoring from the + same archive directory, you will need to ensure that you do not delete + WAL files until they are no longer needed by any of the servers. + archive_cleanup_command would typically be used in a + warm-standby configuration (see Section 25.2). + Write %% to embed an actual % character in the + command. +

If the command returns a non-zero exit status then a WARNING log + message will be written. +

recovery_end_command (string)

This parameter specifies a shell command that will be executed once only + at the end of recovery. This parameter is optional. The purpose of the + recovery_end_command is to provide a mechanism for cleanup + following replication or recovery. + Any %r is replaced by the name of the file containing the + last valid restart point, like in archive_cleanup_command. +

If the command returns a non-zero exit status then a WARNING log + message will be written and the database will proceed to start up + anyway. An exception is that if the command was terminated by a + signal, the database will not proceed with startup. +


PrevHomeNext
Recovery ConfigurationUpRecovery Target Settings
\ No newline at end of file diff --git a/doc/src/sgml/html/arrays.html b/doc/src/sgml/html/arrays.html new file mode 100644 index 000000000..f41987e91 --- /dev/null +++ b/doc/src/sgml/html/arrays.html @@ -0,0 +1,1221 @@ + +Arrays

8.15. Arrays

PostgreSQL allows columns of a table to be + defined as variable-length multidimensional arrays. Arrays of any + built-in or user-defined base type, enum type, or composite type + can be created. + Arrays of domains are not yet supported. +

8.15.1. Declaration of Array Types

To illustrate the use of array types, we create this table: +

CREATE TABLE sal_emp (
+    name            text,
+    pay_by_quarter  integer[],
+    schedule        text[][]
+);

+ As shown, an array data type is named by appending square brackets + ([]) to the data type name of the array elements. The + above command will create a table named + sal_emp with a column of type + text (name), a + one-dimensional array of type integer + (pay_by_quarter), which represents the + employee's salary by quarter, and a two-dimensional array of + text (schedule), which + represents the employee's weekly schedule. +

The syntax for CREATE TABLE allows the exact size of + arrays to be specified, for example: + +

CREATE TABLE tictactoe (
+    squares   integer[3][3]
+);

+ + However, the current implementation ignores any supplied array size + limits, i.e., the behavior is the same as for arrays of unspecified + length. +

The current implementation does not enforce the declared + number of dimensions either. Arrays of a particular element type are + all considered to be of the same type, regardless of size or number + of dimensions. So, declaring the array size or number of dimensions in + CREATE TABLE is simply documentation; it does not + affect run-time behavior. +

An alternative syntax, which conforms to the SQL standard by using + the keyword ARRAY, can be used for one-dimensional arrays. + pay_by_quarter could have been defined + as: +

    pay_by_quarter  integer ARRAY[4],

+ Or, if no array size is to be specified: +

    pay_by_quarter  integer ARRAY,

+ As before, however, PostgreSQL does not enforce the + size restriction in any case. +

8.15.2. Array Value Input

To write an array value as a literal constant, enclose the element + values within curly braces and separate them by commas. (If you + know C, this is not unlike the C syntax for initializing + structures.) You can put double quotes around any element value, + and must do so if it contains commas or curly braces. (More + details appear below.) Thus, the general format of an array + constant is the following: +

'{ val1 delim val2 delim ... }'

+ where delim is the delimiter character + for the type, as recorded in its pg_type entry. + Among the standard data types provided in the + PostgreSQL distribution, all use a comma + (,), except for type box which uses a semicolon + (;). Each val is + either a constant of the array element type, or a subarray. An example + of an array constant is: +

'{{1,2,3},{4,5,6},{7,8,9}}'

+ This constant is a two-dimensional, 3-by-3 array consisting of + three subarrays of integers. +

To set an element of an array constant to NULL, write NULL + for the element value. (Any upper- or lower-case variant of + NULL will do.) If you want an actual string value + "NULL", you must put double quotes around it. +

(These kinds of array constants are actually only a special case of + the generic type constants discussed in Section 4.1.2.7. The constant is initially + treated as a string and passed to the array input conversion + routine. An explicit type specification might be necessary.) +

Now we can show some INSERT statements: + +

INSERT INTO sal_emp
+    VALUES ('Bill',
+    '{10000, 10000, 10000, 10000}',
+    '{{"meeting", "lunch"}, {"training", "presentation"}}');
+
+INSERT INTO sal_emp
+    VALUES ('Carol',
+    '{20000, 25000, 25000, 25000}',
+    '{{"breakfast", "consulting"}, {"meeting", "lunch"}}');

+

The result of the previous two inserts looks like this: + +

SELECT * FROM sal_emp;
+ name  |      pay_by_quarter       |                 schedule
+-------+---------------------------+-------------------------------------------
+ Bill  | {10000,10000,10000,10000} | {{meeting,lunch},{training,presentation}}
+ Carol | {20000,25000,25000,25000} | {{breakfast,consulting},{meeting,lunch}}
+(2 rows)

+

Multidimensional arrays must have matching extents for each + dimension. A mismatch causes an error, for example: + +

INSERT INTO sal_emp
+    VALUES ('Bill',
+    '{10000, 10000, 10000, 10000}',
+    '{{"meeting", "lunch"}, {"meeting"}}');
+ERROR:  multidimensional arrays must have array expressions with matching dimensions

+

The ARRAY constructor syntax can also be used: +

INSERT INTO sal_emp
+    VALUES ('Bill',
+    ARRAY[10000, 10000, 10000, 10000],
+    ARRAY[['meeting', 'lunch'], ['training', 'presentation']]);
+
+INSERT INTO sal_emp
+    VALUES ('Carol',
+    ARRAY[20000, 25000, 25000, 25000],
+    ARRAY[['breakfast', 'consulting'], ['meeting', 'lunch']]);

+ Notice that the array elements are ordinary SQL constants or + expressions; for instance, string literals are single quoted, instead of + double quoted as they would be in an array literal. The ARRAY + constructor syntax is discussed in more detail in + Section 4.2.12. +

8.15.3. Accessing Arrays

Now, we can run some queries on the table. + First, we show how to access a single element of an array. + This query retrieves the names of the employees whose pay changed in + the second quarter: + +

SELECT name FROM sal_emp WHERE pay_by_quarter[1] <> pay_by_quarter[2];
+
+ name
+-------
+ Carol
+(1 row)

+ + The array subscript numbers are written within square brackets. + By default PostgreSQL uses a + one-based numbering convention for arrays, that is, + an array of n elements starts with array[1] and + ends with array[n]. +

This query retrieves the third quarter pay of all employees: + +

SELECT pay_by_quarter[3] FROM sal_emp;
+
+ pay_by_quarter
+----------------
+          10000
+          25000
+(2 rows)

+

We can also access arbitrary rectangular slices of an array, or + subarrays. An array slice is denoted by writing + lower-bound:upper-bound + for one or more array dimensions. For example, this query retrieves the first + item on Bill's schedule for the first two days of the week: + +

SELECT schedule[1:2][1:1] FROM sal_emp WHERE name = 'Bill';
+
+        schedule
+------------------------
+ {{meeting},{training}}
+(1 row)

+ + If any dimension is written as a slice, i.e., contains a colon, then all + dimensions are treated as slices. Any dimension that has only a single + number (no colon) is treated as being from 1 + to the number specified. For example, [2] is treated as + [1:2], as in this example: + +

SELECT schedule[1:2][2] FROM sal_emp WHERE name = 'Bill';
+
+                 schedule
+-------------------------------------------
+ {{meeting,lunch},{training,presentation}}
+(1 row)

+ + To avoid confusion with the non-slice case, it's best to use slice syntax + for all dimensions, e.g., [1:2][1:1], not [2][1:1]. +

An array subscript expression will return null if either the array itself or + any of the subscript expressions are null. Also, null is returned if a + subscript is outside the array bounds (this case does not raise an error). + For example, if schedule + currently has the dimensions [1:3][1:2] then referencing + schedule[3][3] yields NULL. Similarly, an array reference + with the wrong number of subscripts yields a null rather than an error. +

An array slice expression likewise yields null if the array itself or + any of the subscript expressions are null. However, in other + cases such as selecting an array slice that + is completely outside the current array bounds, a slice expression + yields an empty (zero-dimensional) array instead of null. (This + does not match non-slice behavior and is done for historical reasons.) + If the requested slice partially overlaps the array bounds, then it + is silently reduced to just the overlapping region instead of + returning null. +

The current dimensions of any array value can be retrieved with the + array_dims function: + +

SELECT array_dims(schedule) FROM sal_emp WHERE name = 'Carol';
+
+ array_dims
+------------
+ [1:2][1:2]
+(1 row)

+ + array_dims produces a text result, + which is convenient for people to read but perhaps inconvenient + for programs. Dimensions can also be retrieved with + array_upper and array_lower, + which return the upper and lower bound of a + specified array dimension, respectively: + +

SELECT array_upper(schedule, 1) FROM sal_emp WHERE name = 'Carol';
+
+ array_upper
+-------------
+           2
+(1 row)

+ + array_length will return the length of a specified + array dimension: + +

SELECT array_length(schedule, 1) FROM sal_emp WHERE name = 'Carol';
+
+ array_length
+--------------
+            2
+(1 row)

+

8.15.4. Modifying Arrays

An array value can be replaced completely: + +

UPDATE sal_emp SET pay_by_quarter = '{25000,25000,27000,27000}'
+    WHERE name = 'Carol';

+ + or using the ARRAY expression syntax: + +

UPDATE sal_emp SET pay_by_quarter = ARRAY[25000,25000,27000,27000]
+    WHERE name = 'Carol';

+ + An array can also be updated at a single element: + +

UPDATE sal_emp SET pay_by_quarter[4] = 15000
+    WHERE name = 'Bill';

+ + or updated in a slice: + +

UPDATE sal_emp SET pay_by_quarter[1:2] = '{27000,27000}'
+    WHERE name = 'Carol';

+ +

A stored array value can be enlarged by assigning to elements not already + present. Any positions between those previously present and the newly + assigned elements will be filled with nulls. For example, if array + myarray currently has 4 elements, it will have six + elements after an update that assigns to myarray[6]; + myarray[5] will contain null. + Currently, enlargement in this fashion is only allowed for one-dimensional + arrays, not multidimensional arrays. +

Subscripted assignment allows creation of arrays that do not use one-based + subscripts. For example one might assign to myarray[-2:7] to + create an array with subscript values from -2 to 7. +

New array values can also be constructed using the concatenation operator, + ||: +

SELECT ARRAY[1,2] || ARRAY[3,4];
+ ?column?
+-----------
+ {1,2,3,4}
+(1 row)
+
+SELECT ARRAY[5,6] || ARRAY[[1,2],[3,4]];
+      ?column?
+---------------------
+ {{5,6},{1,2},{3,4}}
+(1 row)

+

The concatenation operator allows a single element to be pushed onto the + beginning or end of a one-dimensional array. It also accepts two + N-dimensional arrays, or an N-dimensional + and an N+1-dimensional array. +

When a single element is pushed onto either the beginning or end of a + one-dimensional array, the result is an array with the same lower bound + subscript as the array operand. For example: +

SELECT array_dims(1 || '[0:1]={2,3}'::int[]);
+ array_dims
+------------
+ [0:2]
+(1 row)
+
+SELECT array_dims(ARRAY[1,2] || 3);
+ array_dims
+------------
+ [1:3]
+(1 row)

+

When two arrays with an equal number of dimensions are concatenated, the + result retains the lower bound subscript of the left-hand operand's outer + dimension. The result is an array comprising every element of the left-hand + operand followed by every element of the right-hand operand. For example: +

SELECT array_dims(ARRAY[1,2] || ARRAY[3,4,5]);
+ array_dims
+------------
+ [1:5]
+(1 row)
+
+SELECT array_dims(ARRAY[[1,2],[3,4]] || ARRAY[[5,6],[7,8],[9,0]]);
+ array_dims
+------------
+ [1:5][1:2]
+(1 row)

+

When an N-dimensional array is pushed onto the beginning + or end of an N+1-dimensional array, the result is + analogous to the element-array case above. Each N-dimensional + sub-array is essentially an element of the N+1-dimensional + array's outer dimension. For example: +

SELECT array_dims(ARRAY[1,2] || ARRAY[[3,4],[5,6]]);
+ array_dims
+------------
+ [1:3][1:2]
+(1 row)

+

An array can also be constructed by using the functions + array_prepend, array_append, + or array_cat. The first two only support one-dimensional + arrays, but array_cat supports multidimensional arrays. + + Note that the concatenation operator discussed above is preferred over + direct use of these functions. In fact, these functions primarily exist for use + in implementing the concatenation operator. However, they might be directly + useful in the creation of user-defined aggregates. Some examples: + +

SELECT array_prepend(1, ARRAY[2,3]);
+ array_prepend
+---------------
+ {1,2,3}
+(1 row)
+
+SELECT array_append(ARRAY[1,2], 3);
+ array_append
+--------------
+ {1,2,3}
+(1 row)
+
+SELECT array_cat(ARRAY[1,2], ARRAY[3,4]);
+ array_cat
+-----------
+ {1,2,3,4}
+(1 row)
+
+SELECT array_cat(ARRAY[[1,2],[3,4]], ARRAY[5,6]);
+      array_cat
+---------------------
+ {{1,2},{3,4},{5,6}}
+(1 row)
+
+SELECT array_cat(ARRAY[5,6], ARRAY[[1,2],[3,4]]);
+      array_cat
+---------------------
+ {{5,6},{1,2},{3,4}}

+

8.15.5. Searching in Arrays

To search for a value in an array, each value must be checked. + This can be done manually, if you know the size of the array. + For example: + +

SELECT * FROM sal_emp WHERE pay_by_quarter[1] = 10000 OR
+                            pay_by_quarter[2] = 10000 OR
+                            pay_by_quarter[3] = 10000 OR
+                            pay_by_quarter[4] = 10000;

+ + However, this quickly becomes tedious for large arrays, and is not + helpful if the size of the array is unknown. An alternative method is + described in Section 9.23. The above + query could be replaced by: + +

SELECT * FROM sal_emp WHERE 10000 = ANY (pay_by_quarter);

+ + In addition, you can find rows where the array has all values + equal to 10000 with: + +

SELECT * FROM sal_emp WHERE 10000 = ALL (pay_by_quarter);

+ +

Alternatively, the generate_subscripts function can be used. + For example: + +

SELECT * FROM
+   (SELECT pay_by_quarter,
+           generate_subscripts(pay_by_quarter, 1) AS s
+      FROM sal_emp) AS foo
+ WHERE pay_by_quarter[s] = 10000;

+ + This function is described in Table 9-49. +

Tip: Arrays are not sets; searching for specific array elements + can be a sign of database misdesign. Consider + using a separate table with a row for each item that would be an + array element. This will be easier to search, and is likely to + scale better for a large number of elements. +

8.15.6. Array Input and Output Syntax

The external text representation of an array value consists of items that + are interpreted according to the I/O conversion rules for the array's + element type, plus decoration that indicates the array structure. + The decoration consists of curly braces ({ and }) + around the array value plus delimiter characters between adjacent items. + The delimiter character is usually a comma (,) but can be + something else: it is determined by the typdelim setting + for the array's element type. Among the standard data types provided + in the PostgreSQL distribution, all use a comma, + except for type box, which uses a semicolon (;). + In a multidimensional array, each dimension (row, plane, + cube, etc.) gets its own level of curly braces, and delimiters + must be written between adjacent curly-braced entities of the same level. +

The array output routine will put double quotes around element values + if they are empty strings, contain curly braces, delimiter characters, + double quotes, backslashes, or white space, or match the word + NULL. Double quotes and backslashes + embedded in element values will be backslash-escaped. For numeric + data types it is safe to assume that double quotes will never appear, but + for textual data types one should be prepared to cope with either the presence + or absence of quotes. +

By default, the lower bound index value of an array's dimensions is + set to one. To represent arrays with other lower bounds, the array + subscript ranges can be specified explicitly before writing the + array contents. + This decoration consists of square brackets ([]) + around each array dimension's lower and upper bounds, with + a colon (:) delimiter character in between. The + array dimension decoration is followed by an equal sign (=). + For example: +

SELECT f1[1][-2][3] AS e1, f1[1][-1][5] AS e2
+ FROM (SELECT '[1:1][-2:-1][3:5]={{{1,2,3},{4,5,6}}}'::int[] AS f1) AS ss;
+
+ e1 | e2
+----+----
+  1 |  6
+(1 row)

+ The array output routine will include explicit dimensions in its result + only when there are one or more lower bounds different from one. +

If the value written for an element is NULL (in any case + variant), the element is taken to be NULL. The presence of any quotes + or backslashes disables this and allows the literal string value + "NULL" to be entered. Also, for backward compatibility with + pre-8.2 versions of PostgreSQL, the array_nulls configuration parameter can be turned + off to suppress recognition of NULL as a NULL. +

As shown previously, when writing an array value you can use double + quotes around any individual array element. You must do so + if the element value would otherwise confuse the array-value parser. + For example, elements containing curly braces, commas (or the data type's + delimiter character), double quotes, backslashes, or leading or trailing + whitespace must be double-quoted. Empty strings and strings matching the + word NULL must be quoted, too. To put a double quote or + backslash in a quoted array element value, use escape string syntax + and precede it with a backslash. Alternatively, you can avoid quotes and use + backslash-escaping to protect all data characters that would otherwise + be taken as array syntax. +

You can add whitespace before a left brace or after a right + brace. You can also add whitespace before or after any individual item + string. In all of these cases the whitespace will be ignored. However, + whitespace within double-quoted elements, or surrounded on both sides by + non-whitespace characters of an element, is not ignored. +

Note: Remember that what you write in an SQL command will first be interpreted + as a string literal, and then as an array. This doubles the number of + backslashes you need. For example, to insert a text array + value containing a backslash and a double quote, you'd need to write: +

INSERT ... VALUES (E'{"\\\\","\\""}');

+ The escape string processor removes one level of backslashes, so that + what arrives at the array-value parser looks like {"\\","\""}. + In turn, the strings fed to the text data type's input routine + become \ and " respectively. (If we were working + with a data type whose input routine also treated backslashes specially, + bytea for example, we might need as many as eight backslashes + in the command to get one backslash into the stored array element.) + Dollar quoting (see Section 4.1.2.4) can be + used to avoid the need to double backslashes. +

Tip: The ARRAY constructor syntax (see + Section 4.2.12) is often easier to work + with than the array-literal syntax when writing array values in SQL + commands. In ARRAY, individual element values are written the + same way they would be written when not members of an array. +


PrevHomeNext
JSON TypeUpComposite Types
\ No newline at end of file diff --git a/doc/src/sgml/html/auth-delay.html b/doc/src/sgml/html/auth-delay.html new file mode 100644 index 000000000..db579a2c9 --- /dev/null +++ b/doc/src/sgml/html/auth-delay.html @@ -0,0 +1,245 @@ + +auth_delay
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.2. auth_delay

auth_delay causes the server to pause briefly before + reporting authentication failure, to make brute-force attacks on database + passwords more difficult. Note that it does nothing to prevent + denial-of-service attacks, and may even exacerbate them, since processes + that are waiting before reporting authentication failure will still consume + connection slots. +

In order to function, this module must be loaded via + shared_preload_libraries in postgresql.conf. +

F.2.1. Configuration Parameters

auth_delay.milliseconds (int)

The number of milliseconds to wait before reporting an authentication + failure. The default is 0. +

These parameters must be set in postgresql.conf. + Typical usage might be: +

# postgresql.conf
+shared_preload_libraries = 'auth_delay'
+
+auth_delay.milliseconds = '500'

PrevHomeNext
adminpackUpauto_explain
\ No newline at end of file diff --git a/doc/src/sgml/html/auth-methods.html b/doc/src/sgml/html/auth-methods.html new file mode 100644 index 000000000..102d454fa --- /dev/null +++ b/doc/src/sgml/html/auth-methods.html @@ -0,0 +1,1748 @@ + +Authentication Methods
PostgreSQL 9.2.2 Documentation
PrevUpChapter 19. Client AuthenticationNext

19.3. Authentication Methods

The following subsections describe the authentication methods in more detail. +

19.3.1. Trust Authentication

When trust authentication is specified, + PostgreSQL assumes that anyone who can + connect to the server is authorized to access the database with + whatever database user name they specify (even superuser names). + Of course, restrictions made in the database and + user columns still apply. + This method should only be used when there is adequate + operating-system-level protection on connections to the server. +

trust authentication is appropriate and very + convenient for local connections on a single-user workstation. It + is usually not appropriate by itself on a multiuser + machine. However, you might be able to use trust even + on a multiuser machine, if you restrict access to the server's + Unix-domain socket file using file-system permissions. To do this, set the + unix_socket_permissions (and possibly + unix_socket_group) configuration parameters as + described in Section 18.3. Or you + could set the unix_socket_directory + configuration parameter to place the socket file in a suitably + restricted directory. +

Setting file-system permissions only helps for Unix-socket connections. + Local TCP/IP connections are not restricted by file-system permissions. + Therefore, if you want to use file-system permissions for local security, + remove the host ... 127.0.0.1 ... line from + pg_hba.conf, or change it to a + non-trust authentication method. +

trust authentication is only suitable for TCP/IP connections + if you trust every user on every machine that is allowed to connect + to the server by the pg_hba.conf lines that specify + trust. It is seldom reasonable to use trust + for any TCP/IP connections other than those from localhost (127.0.0.1). +

19.3.2. Password Authentication

The password-based authentication methods are md5 + and password. These methods operate + similarly except for the way that the password is sent across the + connection, namely MD5-hashed and clear-text respectively. +

If you are at all concerned about password + "sniffing" attacks then md5 is preferred. + Plain password should always be avoided if possible. + However, md5 cannot be used with the db_user_namespace feature. If the connection is + protected by SSL encryption then password can be used + safely (though SSL certificate authentication might be a better + choice if one is depending on using SSL). +

PostgreSQL database passwords are + separate from operating system user passwords. The password for + each database user is stored in the pg_authid system + catalog. Passwords can be managed with the SQL commands + CREATE USER and + ALTER ROLE, + e.g., CREATE USER foo WITH PASSWORD 'secret'. + If no password has been set up for a user, the stored password + is null and password authentication will always fail for that user. +

19.3.3. GSSAPI Authentication

GSSAPI is an industry-standard protocol + for secure authentication defined in RFC 2743. + PostgreSQL supports + GSSAPI with Kerberos + authentication according to RFC 1964. GSSAPI + provides automatic authentication (single sign-on) for systems + that support it. The authentication itself is secure, but the + data sent over the database connection will be sent unencrypted unless + SSL is used. +

When GSSAPI uses + Kerberos, it uses a standard principal + in the format + servicename/hostname@realm. For information about the parts of the principal, and + how to set up the required keys, see Section 19.3.5. +

GSSAPI support has to be enabled when PostgreSQL is built; + see Chapter 15 for more information. +

The following configuration options are supported for GSSAPI: +

include_realm

If set to 1, the realm name from the authenticated user + principal is included in the system user name that's passed through + user name mapping (Section 19.2). This is + useful for handling users from multiple realms. +

map

Allows for mapping between system and database user names. See + Section 19.2 for details. For a Kerberos + principal username/hostbased@EXAMPLE.COM, the + user name used for mapping is username/hostbased + if include_realm is disabled, and + username/hostbased@EXAMPLE.COM if + include_realm is enabled. +

krb_realm

Sets the realm to match user principal names against. If this parameter + is set, only users of that realm will be accepted. If it is not set, + users of any realm can connect, subject to whatever user name mapping + is done. +

+

19.3.4. SSPI Authentication

SSPI is a Windows + technology for secure authentication with single sign-on. + PostgreSQL will use SSPI in + negotiate mode, which will use + Kerberos when possible and automatically + fall back to NTLM in other cases. + SSPI authentication only works when both + server and client are running Windows, + or, on non-Windows platforms, when GSSAPI + is available. +

When using Kerberos authentication, + SSPI works the same way + GSSAPI does; see Section 19.3.3 + for details. +

The following configuration options are supported for SSPI: +

include_realm

If set to 1, the realm name from the authenticated user + principal is included in the system user name that's passed through + user name mapping (Section 19.2). This is + useful for handling users from multiple realms. +

map

Allows for mapping between system and database user names. See + Section 19.2 for details. +

krb_realm

Sets the realm to match user principal names against. If this parameter + is set, only users of that realm will be accepted. If it is not set, + users of any realm can connect, subject to whatever user name mapping + is done. +

+

19.3.5. Kerberos Authentication

Note: Native Kerberos authentication has been deprecated and should be used + only for backward compatibility. New and upgraded installations are + encouraged to use the industry-standard GSSAPI + authentication method (see Section 19.3.3) instead. +

Kerberos is an industry-standard secure + authentication system suitable for distributed computing over a public + network. A description of the Kerberos system + is beyond the scope of this document; in full generality it can be + quite complex (yet powerful). The + Kerberos FAQ or + MIT Kerberos page + can be good starting points for exploration. + Several sources for Kerberos distributions exist. + Kerberos provides secure authentication but + does not encrypt queries or data passed over the network; for that + use SSL. +

PostgreSQL supports Kerberos version 5. Kerberos + support has to be enabled when PostgreSQL is built; + see Chapter 15 for more information. +

PostgreSQL operates like a normal Kerberos service. + The name of the service principal is + servicename/hostname@realm. +

servicename can be set on the server side using the + krb_srvname configuration parameter, and on the + client side using the krbsrvname connection parameter. (See + also Section 31.1.) The installation default can be + changed from the default postgres at build time using + ./configure --with-krb-srvnam=whatever. + In most environments, + this parameter never needs to be changed. However, it is necessary + when supporting multiple PostgreSQL installations + on the same host. + Some Kerberos implementations might also require a different service name, + such as Microsoft Active Directory which requires the service name + to be in upper case (POSTGRES). +

hostname is the fully qualified host name of the + server machine. The service principal's realm is the preferred realm + of the server machine. +

Client principals must have their PostgreSQL database user + name as their first component, for example + pgusername@realm. Alternatively, you can use a user name + mapping to map from the first component of the principal name to the + database user name. By default, the realm of the client is + not checked by PostgreSQL. If you have cross-realm + authentication enabled and need to verify the realm, use the + krb_realm parameter, or enable include_realm + and use user name mapping to check the realm. +

Make sure that your server keytab file is readable (and preferably + only readable) by the PostgreSQL server + account. (See also Section 17.1.) The location + of the key file is specified by the krb_server_keyfile configuration + parameter. The default is + /usr/local/pgsql/etc/krb5.keytab (or whatever + directory was specified as sysconfdir at build time). +

The keytab file is generated by the Kerberos software; see the + Kerberos documentation for details. The following example is + for MIT-compatible Kerberos 5 implementations: +

kadmin% ank -randkey postgres/server.my.domain.org
+kadmin% ktadd -k krb5.keytab postgres/server.my.domain.org

+

When connecting to the database make sure you have a ticket for a + principal matching the requested database user name. For example, for + database user name fred, principal + fred@EXAMPLE.COM would be able to connect. To also allow + principal fred/users.example.com@EXAMPLE.COM, use a user name + map, as described in Section 19.2. +

If you use mod_auth_kerb + and mod_perl on your + Apache web server, you can use + AuthType KerberosV5SaveCredentials with a + mod_perl script. This gives secure + database access over the web, with no additional passwords required. +

The following configuration options are supported for + Kerberos: +

map

Allows for mapping between system and database user names. See + Section 19.2 for details. +

include_realm

If set to 1, the realm name from the authenticated user + principal is included in the system user name that's passed through + user name mapping (Section 19.2). This is + useful for handling users from multiple realms. +

krb_realm

Sets the realm to match user principal names against. If this parameter + is set, only users of that realm will be accepted. If it is not set, + users of any realm can connect, subject to whatever user name mapping + is done. +

krb_server_hostname

Sets the host name part of the service principal. + This, combined with krb_srvname, is used to generate + the complete service principal, that is + krb_srvname/krb_server_hostname@REALM. + If not set, the default is the server host name. +

+

19.3.6. Ident Authentication

The ident authentication method works by obtaining the client's + operating system user name from an ident server and using it as + the allowed database user name (with an optional user name mapping). + This is only supported on TCP/IP connections. +

Note: When ident is specified for a local (non-TCP/IP) connection, + peer authentication (see Section 19.3.7) will be + used instead. +

The following configuration options are supported for ident: +

map

Allows for mapping between system and database user names. See + Section 19.2 for details. +

+

The "Identification Protocol" is described in + RFC 1413. Virtually every Unix-like + operating system ships with an ident server that listens on TCP + port 113 by default. The basic functionality of an ident server + is to answer questions like "What user initiated the + connection that goes out of your port X + and connects to my port Y?". + Since PostgreSQL knows both X and + Y when a physical connection is established, it + can interrogate the ident server on the host of the connecting + client and can theoretically determine the operating system user + for any given connection. +

The drawback of this procedure is that it depends on the integrity + of the client: if the client machine is untrusted or compromised, + an attacker could run just about any program on port 113 and + return any user name he chooses. This authentication method is + therefore only appropriate for closed networks where each client + machine is under tight control and where the database and system + administrators operate in close contact. In other words, you must + trust the machine running the ident server. + Heed the warning: +
 

The Identification Protocol is not intended as an authorization + or access control protocol. +

 
--RFC 1413 
+

Some ident servers have a nonstandard option that causes the returned + user name to be encrypted, using a key that only the originating + machine's administrator knows. This option must not be + used when using the ident server with PostgreSQL, + since PostgreSQL does not have any way to decrypt the + returned string to determine the actual user name. +

19.3.7. Peer Authentication

The peer authentication method works by obtaining the client's + operating system user name from the kernel and using it as the + allowed database user name (with optional user name mapping). This + method is only supported on local connections. +

The following configuration options are supported for peer: +

map

Allows for mapping between system and database user names. See + Section 19.2 for details. +

+

Peer authentication is only available on operating systems providing + the getpeereid() function, the SO_PEERCRED + socket parameter, or similar mechanisms. Currently that includes + Linux, + most flavors of BSD including + Mac OS X, + and Solaris. +

19.3.8. LDAP Authentication

This authentication method operates similarly to + password except that it uses LDAP + as the password verification method. LDAP is used only to validate + the user name/password pairs. Therefore the user must already + exist in the database before LDAP can be used for + authentication. +

LDAP authentication can operate in two modes. In the first mode, + the server will bind to the distinguished name constructed as + prefix username suffix. + Typically, the prefix parameter is used to specify + cn=, or DOMAIN\ in an Active + Directory environment. suffix is used to specify the + remaining part of the DN in a non-Active Directory environment. +

In the second mode, the server first binds to the LDAP directory with + a fixed user name and password, specified with ldapbinduser + and ldapbinddn, and performs a search for the user trying + to log in to the database. If no user and password is configured, an + anonymous bind will be attempted to the directory. The search will be + performed over the subtree at ldapbasedn, and will try to + do an exact match of the attribute specified in + ldapsearchattribute. If no attribute is specified, the + uid attribute will be used. Once the user has been found in + this search, the server disconnects and re-binds to the directory as + this user, using the password specified by the client, to verify that the + login is correct. This method allows for significantly more flexibility + in where the user objects are located in the directory, but will cause + two separate connections to the LDAP server to be made. +

The following configuration options are supported for LDAP: +

ldapserver

Names or IP addresses of LDAP servers to connect to. Multiple + servers may be specified, separated by spaces. +

ldapport

Port number on LDAP server to connect to. If no port is specified, + the LDAP library's default port setting will be used. +

ldaptls

Set to 1 to make the connection between PostgreSQL and the + LDAP server use TLS encryption. Note that this only encrypts + the traffic to the LDAP server — the connection to the client + will still be unencrypted unless SSL is used. +

ldapprefix

String to prepend to the user name when forming the DN to bind as, + when doing simple bind authentication. +

ldapsuffix

String to append to the user name when forming the DN to bind as, + when doing simple bind authentication. +

ldapbasedn

Root DN to begin the search for the user in, when doing search+bind + authentication. +

ldapbinddn

DN of user to bind to the directory with to perform the search when + doing search+bind authentication. +

ldapbindpasswd

Password for user to bind to the directory with to perform the search + when doing search+bind authentication. +

ldapsearchattribute

Attribute to match against the user name in the search when doing + search+bind authentication. +

+

Note: Since LDAP often uses commas and spaces to separate the different + parts of a DN, it is often necessary to use double-quoted parameter + values when configuring LDAP options, for example: +

ldapserver=ldap.example.net ldapprefix="cn=" ldapsuffix=", dc=example, dc=net"

+

19.3.9. RADIUS Authentication

This authentication method operates similarly to + password except that it uses RADIUS + as the password verification method. RADIUS is used only to validate + the user name/password pairs. Therefore the user must already + exist in the database before RADIUS can be used for + authentication. +

When using RADIUS authentication, an Access Request message will be sent + to the configured RADIUS server. This request will be of type + Authenticate Only, and include parameters for + user name, password (encrypted) and + NAS Identifier. The request will be encrypted using + a secret shared with the server. The RADIUS server will respond to + this server with either Access Accept or + Access Reject. There is no support for RADIUS accounting. +

The following configuration options are supported for RADIUS: +

radiusserver

The name or IP address of the RADIUS server to connect to. + This parameter is required. +

radiussecret

The shared secret used when talking securely to the RADIUS + server. This must have exactly the same value on the PostgreSQL + and RADIUS servers. It is recommended that this be a string of + at least 16 characters. This parameter is required. +

Note: The encryption vector used will only be cryptographically + strong if PostgreSQL is built with support for + OpenSSL. In other cases, the transmission to the + RADIUS server should only be considered obfuscated, not secured, and + external security measures should be applied if necessary. +

+

radiusport

The port number on the RADIUS server to connect to. If no port + is specified, the default port 1812 will be used. +

radiusidentifier

The string used as NAS Identifier in the RADIUS + requests. This parameter can be used as a second parameter + identifying for example which database user the user is attempting + to authenticate as, which can be used for policy matching on + the RADIUS server. If no identifier is specified, the default + postgresql will be used. +

+

19.3.10. Certificate Authentication

This authentication method uses SSL client certificates to perform + authentication. It is therefore only available for SSL connections. + When using this authentication method, the server will require that + the client provide a valid certificate. No password prompt will be sent + to the client. The cn (Common Name) attribute of the + certificate + will be compared to the requested database user name, and if they match + the login will be allowed. User name mapping can be used to allow + cn to be different from the database user name. +

The following configuration options are supported for SSL certificate + authentication: +

map

Allows for mapping between system and database user names. See + Section 19.2 for details. +

+

19.3.11. PAM Authentication

This authentication method operates similarly to + password except that it uses PAM (Pluggable + Authentication Modules) as the authentication mechanism. The + default PAM service name is postgresql. + PAM is used only to validate user name/password pairs. + Therefore the user must already exist in the database before PAM + can be used for authentication. For more information about + PAM, please read the Linux-PAM Page + and the Solaris PAM Page. +

The following configuration options are supported for PAM: +

pamservice

PAM service name. +

+

Note: If PAM is set up to read /etc/shadow, authentication + will fail because the PostgreSQL server is started by a non-root + user. However, this is not an issue when PAM is configured to use + LDAP or other authentication methods. +


PrevHomeNext
User Name MapsUpAuthentication Problems
\ No newline at end of file diff --git a/doc/src/sgml/html/auth-pg-hba-conf.html b/doc/src/sgml/html/auth-pg-hba-conf.html new file mode 100644 index 000000000..8ecd9c4a2 --- /dev/null +++ b/doc/src/sgml/html/auth-pg-hba-conf.html @@ -0,0 +1,1396 @@ + +The pg_hba.conf File
PostgreSQL 9.2.2 Documentation
PrevUpChapter 19. Client AuthenticationNext

19.1. The pg_hba.conf File

Client authentication is controlled by a configuration file, + which traditionally is named + pg_hba.conf and is stored in the database + cluster's data directory. + (HBA stands for host-based authentication.) A default + pg_hba.conf file is installed when the data + directory is initialized by initdb. It is + possible to place the authentication configuration file elsewhere, + however; see the hba_file configuration parameter. +

The general format of the pg_hba.conf file is + a set of records, one per line. Blank lines are ignored, as is any + text after the # comment character. + Records cannot be continued across lines. + A record is made + up of a number of fields which are separated by spaces and/or tabs. + Fields can contain white space if the field value is quoted. + Quoting one of the keywords in a database, user, or address field (e.g., + all or replication) makes the word lose its special + character, and just match a database, user, or host with that name. +

Each record specifies a connection type, a client IP address range + (if relevant for the connection type), a database name, a user name, + and the authentication method to be used for connections matching + these parameters. The first record with a matching connection type, + client address, requested database, and user name is used to perform + authentication. There is no "fall-through" or + "backup": if one record is chosen and the authentication + fails, subsequent records are not considered. If no record matches, + access is denied. +

A record can have one of the seven formats +

local      database  user  auth-method  [auth-options]
+host       database  user  address  auth-method  [auth-options]
+hostssl    database  user  address  auth-method  [auth-options]
+hostnossl  database  user  address  auth-method  [auth-options]
+host       database  user  IP-address  IP-mask  auth-method  [auth-options]
+hostssl    database  user  IP-address  IP-mask  auth-method  [auth-options]
+hostnossl  database  user  IP-address  IP-mask  auth-method  [auth-options]

+ The meaning of the fields is as follows: + +

local

This record matches connection attempts using Unix-domain + sockets. Without a record of this type, Unix-domain socket + connections are disallowed. +

host

This record matches connection attempts made using TCP/IP. + host records match either + SSL or non-SSL connection + attempts. +

Note: Remote TCP/IP connections will not be possible unless + the server is started with an appropriate value for the + listen_addresses configuration parameter, + since the default behavior is to listen for TCP/IP connections + only on the local loopback address localhost. +

hostssl

This record matches connection attempts made using TCP/IP, + but only when the connection is made with SSL + encryption. +

To make use of this option the server must be built with + SSL support. Furthermore, + SSL must be enabled at server start time + by setting the ssl configuration parameter (see + Section 17.9 for more information). +

hostnossl

This record type has the opposite behavior of hostssl; + it only matches connection attempts made over + TCP/IP that do not use SSL. +

database

Specifies which database name(s) this record matches. The value + all specifies that it matches all databases. + The value sameuser specifies that the record + matches if the requested database has the same name as the + requested user. The value samerole specifies that + the requested user must be a member of the role with the same + name as the requested database. (samegroup is an + obsolete but still accepted spelling of samerole.) + Superusers are not considered to be members of a role for the + purposes of samerole unless they are explicitly + members of the role, directly or indirectly, and not just by + virtue of being a superuser. + The value replication specifies that the record + matches if a replication connection is requested (note that + replication connections do not specify any particular database). + Otherwise, this is the name of + a specific PostgreSQL database. + Multiple database names can be supplied by separating them with + commas. A separate file containing database names can be specified by + preceding the file name with @. +

user

Specifies which database user name(s) this record + matches. The value all specifies that it + matches all users. Otherwise, this is either the name of a specific + database user, or a group name preceded by +. + (Recall that there is no real distinction between users and groups + in PostgreSQL; a + mark really means + "match any of the roles that are directly or indirectly members + of this role", while a name without a + mark matches + only that specific role.) For this purpose, a superuser is only + considered to be a member of a role if they are explicitly a member + of the role, directly or indirectly, and not just by virtue of + being a superuser. + Multiple user names can be supplied by separating them with commas. + A separate file containing user names can be specified by preceding the + file name with @. +

address

Specifies the client machine addresses that this record + matches. This field can contain either a host name, an IP + address range, or one of the special key words mentioned below. +

An IP address is specified in standard dotted decimal + notation with a CIDR mask length. The mask + length indicates the number of high-order bits of the client + IP address that must match. Bits to the right of this should + be zero in the given IP address. + There must not be any white space between the IP address, the + /, and the CIDR mask length. +

Typical examples of an IP address range specified this way are + 172.20.143.89/32 for a single host, or + 172.20.143.0/24 for a small network, or + 10.6.0.0/16 for a larger one. + 0.0.0.0/0 represents all + IPv4 addresses, and ::/0 represents + all IPv6 addresses. + To specify a single host, use a CIDR mask of 32 for IPv4 or + 128 for IPv6. In a network address, do not omit trailing zeroes. +

An IP address given in IPv4 format will match IPv6 connections that + have the corresponding address, for example 127.0.0.1 + will match the IPv6 address ::ffff:127.0.0.1. An entry + given in IPv6 format will match only IPv6 connections, even if the + represented address is in the IPv4-in-IPv6 range. Note that entries + in IPv6 format will be rejected if the system's C library does not have + support for IPv6 addresses. +

You can also write all to match any IP address, + samehost to match any of the server's own IP + addresses, or samenet to match any address in any + subnet that the server is directly connected to. +

If a host name is specified (anything that is not an IP address + or a special key word is processed as a potential host name), + that name is compared with the result of a reverse name + resolution of the client's IP address (e.g., reverse DNS + lookup, if DNS is used). Host name comparisons are case + insensitive. If there is a match, then a forward name + resolution (e.g., forward DNS lookup) is performed on the host + name to check whether any of the addresses it resolves to are + equal to the client's IP address. If both directions match, + then the entry is considered to match. (The host name that is + used in pg_hba.conf should be the one that + address-to-name resolution of the client's IP address returns, + otherwise the line won't be matched. Some host name databases + allow associating an IP address with multiple host names, but + the operating system will only return one host name when asked + to resolve an IP address.) +

A host name specification that starts with a dot + (.) matches a suffix of the actual host + name. So .example.com would match + foo.example.com (but not just + example.com). +

When host names are specified + in pg_hba.conf, you should make sure that + name resolution is reasonably fast. It can be of advantage to + set up a local name resolution cache such + as nscd. Also, you may wish to enable the + configuration parameter log_hostname to see + the client's host name instead of the IP address in the log. +

Occasionally, users have wondered why host names are handled + in this seemingly complicated way with two name resolutions + and requiring reverse lookup of IP addresses, which is + sometimes not set up or points to some undesirable host name. + It is primarily for efficiency: A connection attempt requires + two resolver lookups of the current client's address. If + there is resolver problem with that address, it becomes only + that client's problem. A hypothetical alternative + implementation which only does forward lookups would have to + resolve every host name mentioned in + pg_hba.conf at every connection attempt. + That would already be slow by itself. And if there is a + resolver problem with one of the host names, it becomes + everyone's problem. +

Also, a reverse lookup is necessary to implement the suffix + matching feature, because the actual client host name needs to + be known in order to match it against the pattern. +

Note that this behavior is consistent with other popular + implementations of host name-based access control, such as the + Apache HTTP Server and TCP Wrappers. +

This field only applies to host, + hostssl, and hostnossl records. +

IP-address
IP-mask

These fields can be used as an alternative to the + CIDR-address notation. Instead of + specifying the mask length, the actual mask is specified in a + separate column. For example, 255.0.0.0 represents an IPv4 + CIDR mask length of 8, and 255.255.255.255 represents a + CIDR mask length of 32. +

These fields only apply to host, + hostssl, and hostnossl records. +

auth-method

Specifies the authentication method to use when a connection matches + this record. The possible choices are summarized here; details + are in Section 19.3. + +

trust

Allow the connection unconditionally. This method + allows anyone that can connect to the + PostgreSQL database server to login as + any PostgreSQL user they wish, + without the need for a password or any other authentication. See Section 19.3.1 for details. +

reject

Reject the connection unconditionally. This is useful for + "filtering out" certain hosts from a group, for example a + reject line could block a specific host from connecting, + while a later line allows the remaining hosts in a specific + network to connect. +

md5

Require the client to supply an MD5-encrypted password for + authentication. + See Section 19.3.2 for details. +

password

Require the client to supply an unencrypted password for + authentication. + Since the password is sent in clear text over the + network, this should not be used on untrusted networks. + See Section 19.3.2 for details. +

gss

Use GSSAPI to authenticate the user. This is only + available for TCP/IP connections. See Section 19.3.3 for details. +

sspi

Use SSPI to authenticate the user. This is only + available on Windows. See Section 19.3.4 for details. +

krb5

Use Kerberos V5 to authenticate the user. This is only + available for TCP/IP connections. See Section 19.3.5 for details. +

ident

Obtain the operating system user name of the client + by contacting the ident server on the client + and check if it matches the requested database user name. + Ident authentication can only be used on TCP/IP + connections. When specified for local connections, peer + authentication will be used instead. + See Section 19.3.6 for details. +

peer

Obtain the client's operating system user name from the operating + system and check if it matches the requested database user name. + This is only available for local connections. + See Section 19.3.7 for details. +

ldap

Authenticate using an LDAP server. See Section 19.3.8 for details. +

radius

Authenticate using a RADIUS server. See Section 19.3.9 for details. +

cert

Authenticate using SSL client certificates. See + Section 19.3.10 for details. +

pam

Authenticate using the Pluggable Authentication Modules + (PAM) service provided by the operating system. See Section 19.3.11 for details. +

+ +

auth-options

After the auth-method field, there can be field(s) of + the form name=value that + specify options for the authentication method. Details about which + options are available for which authentication methods appear below. +

+

Files included by @ constructs are read as lists of names, + which can be separated by either whitespace or commas. Comments are + introduced by #, just as in + pg_hba.conf, and nested @ constructs are + allowed. Unless the file name following @ is an absolute + path, it is taken to be relative to the directory containing the + referencing file. +

Since the pg_hba.conf records are examined + sequentially for each connection attempt, the order of the records is + significant. Typically, earlier records will have tight connection + match parameters and weaker authentication methods, while later + records will have looser match parameters and stronger authentication + methods. For example, one might wish to use trust + authentication for local TCP/IP connections but require a password for + remote TCP/IP connections. In this case a record specifying + trust authentication for connections from 127.0.0.1 would + appear before a record specifying password authentication for a wider + range of allowed client IP addresses. +

The pg_hba.conf file is read on start-up and when + the main server process receives a + SIGHUP + signal. If you edit the file on an + active system, you will need to signal the postmaster + (using pg_ctl reload or kill -HUP) to make it + re-read the file. +

Tip: To connect to a particular database, a user must not only pass the + pg_hba.conf checks, but must have the + CONNECT privilege for the database. If you wish to + restrict which users can connect to which databases, it's usually + easier to control this by granting/revoking CONNECT privilege + than to put the rules in pg_hba.conf entries. +

Some examples of pg_hba.conf entries are shown in + Example 19-1. See the next section for details on the + different authentication methods. +

Example 19-1. Example pg_hba.conf Entries

# Allow any user on the local system to connect to any database with
+# any database user name using Unix-domain sockets (the default for local
+# connections).
+#
+# TYPE  DATABASE        USER            ADDRESS                 METHOD
+local   all             all                                     trust
+
+# The same using local loopback TCP/IP connections.
+#
+# TYPE  DATABASE        USER            ADDRESS                 METHOD
+host    all             all             127.0.0.1/32            trust
+
+# The same as the previous line, but using a separate netmask column
+#
+# TYPE  DATABASE        USER            IP-ADDRESS      IP-MASK             METHOD
+host    all             all             127.0.0.1       255.255.255.255     trust
+
+# The same over IPv6.
+#
+# TYPE  DATABASE        USER            ADDRESS                 METHOD
+host    all             all             ::1/128                 trust
+
+# The same using a host name (would typically cover both IPv4 and IPv6).
+#
+# TYPE  DATABASE        USER            ADDRESS                 METHOD
+host    all             all             localhost               trust
+
+# Allow any user from any host with IP address 192.168.93.x to connect
+# to database "postgres" as the same user name that ident reports for
+# the connection (typically the operating system user name).
+#
+# TYPE  DATABASE        USER            ADDRESS                 METHOD
+host    postgres        all             192.168.93.0/24         ident
+
+# Allow any user from host 192.168.12.10 to connect to database
+# "postgres" if the user's password is correctly supplied.
+#
+# TYPE  DATABASE        USER            ADDRESS                 METHOD
+host    postgres        all             192.168.12.10/32        md5
+
+# Allow any user from hosts in the example.com domain to connect to
+# any database if the user's password is correctly supplied.
+#
+# TYPE  DATABASE        USER            ADDRESS                 METHOD
+host    all             all             .example.com            md5
+
+# In the absence of preceding "host" lines, these two lines will
+# reject all connections from 192.168.54.1 (since that entry will be
+# matched first), but allow Kerberos 5 connections from anywhere else
+# on the Internet.  The zero mask causes no bits of the host IP
+# address to be considered, so it matches any host.
+#
+# TYPE  DATABASE        USER            ADDRESS                 METHOD
+host    all             all             192.168.54.1/32         reject
+host    all             all             0.0.0.0/0               krb5
+
+# Allow users from 192.168.x.x hosts to connect to any database, if
+# they pass the ident check.  If, for example, ident says the user is
+# "bryanh" and he requests to connect as PostgreSQL user "guest1", the
+# connection is allowed if there is an entry in pg_ident.conf for map
+# "omicron" that says "bryanh" is allowed to connect as "guest1".
+#
+# TYPE  DATABASE        USER            ADDRESS                 METHOD
+host    all             all             192.168.0.0/16          ident map=omicron
+
+# If these are the only three lines for local connections, they will
+# allow local users to connect only to their own databases (databases
+# with the same name as their database user name) except for administrators
+# and members of role "support", who can connect to all databases.  The file
+# $PGDATA/admins contains a list of names of administrators.  Passwords
+# are required in all cases.
+#
+# TYPE  DATABASE        USER            ADDRESS                 METHOD
+local   sameuser        all                                     md5
+local   all             @admins                                 md5
+local   all             +support                                md5
+
+# The last two lines above can be combined into a single line:
+local   all             @admins,+support                        md5
+
+# The database column can also use lists and file names:
+local   db1,db2,@demodbs  all                                   md5

PrevHomeNext
Client AuthenticationUpUser Name Maps
\ No newline at end of file diff --git a/doc/src/sgml/html/auth-username-maps.html b/doc/src/sgml/html/auth-username-maps.html new file mode 100644 index 000000000..e09c55ce6 --- /dev/null +++ b/doc/src/sgml/html/auth-username-maps.html @@ -0,0 +1,444 @@ + +User Name Maps
PostgreSQL 9.2.2 Documentation
PrevUpChapter 19. Client AuthenticationNext

19.2. User Name Maps

When using an external authentication system like Ident or GSSAPI, + the name of the operating system user that initiated the connection + might not be the same as the database user he needs to connect as. + In this case, a user name map can be applied to map the operating system + user name to a database user. To use user name mapping, specify + map=map-name + in the options field in pg_hba.conf. This option is + supported for all authentication methods that receive external user names. + Since different mappings might be needed for different connections, + the name of the map to be used is specified in the + map-name parameter in pg_hba.conf + to indicate which map to use for each individual connection. +

User name maps are defined in the ident map file, which by default is named + pg_ident.conf + and is stored in the + cluster's data directory. (It is possible to place the map file + elsewhere, however; see the ident_file + configuration parameter.) + The ident map file contains lines of the general form: +

map-name system-username database-username

+ Comments and whitespace are handled in the same way as in + pg_hba.conf. The + map-name is an arbitrary name that will be used to + refer to this mapping in pg_hba.conf. The other + two fields specify an operating system user name and a matching + database user name. The same map-name can be + used repeatedly to specify multiple user-mappings within a single map. +

There is no restriction regarding how many database users a given + operating system user can correspond to, nor vice versa. Thus, entries + in a map should be thought of as meaning "this operating system + user is allowed to connect as this database user", rather than + implying that they are equivalent. The connection will be allowed if + there is any map entry that pairs the user name obtained from the + external authentication system with the database user name that the + user has requested to connect as. +

If the system-username field starts with a slash (/), + the remainder of the field is treated as a regular expression. + (See Section 9.7.3.1 for details of + PostgreSQL's regular expression syntax.) The regular + expression can include a single capture, or parenthesized subexpression, + which can then be referenced in the database-username + field as \1 (backslash-one). This allows the mapping of + multiple user names in a single line, which is particularly useful for + simple syntax substitutions. For example, these entries +

mymap   /^(.*)@mydomain\.com$      \1
+mymap   /^(.*)@otherdomain\.com$   guest

+ will remove the domain part for users with system user names that end with + @mydomain.com, and allow any user whose system name ends with + @otherdomain.com to log in as guest. +

Tip: Keep in mind that by default, a regular expression can match just part of + a string. It's usually wise to use ^ and $, as + shown in the above example, to force the match to be to the entire + system user name. +

The pg_ident.conf file is read on start-up and + when the main server process receives a + SIGHUP + signal. If you edit the file on an + active system, you will need to signal the postmaster + (using pg_ctl reload or kill -HUP) to make it + re-read the file. +

A pg_ident.conf file that could be used in + conjunction with the pg_hba.conf file in Example 19-1 is shown in Example 19-2. In this example, anyone + logged in to a machine on the 192.168 network that does not have the + operating system user name bryanh, ann, or + robert would not be granted access. Unix user + robert would only be allowed access when he tries to + connect as PostgreSQL user bob, not + as robert or anyone else. ann would + only be allowed to connect as ann. User + bryanh would be allowed to connect as either + bryanh or as guest1. +

Example 19-2. An Example pg_ident.conf File

# MAPNAME       SYSTEM-USERNAME         PG-USERNAME
+
+omicron         bryanh                  bryanh
+omicron         ann                     ann
+# bob has user name robert on these machines
+omicron         robert                  bob
+# bryanh can also connect as guest1
+omicron         bryanh                  guest1

PrevHomeNext
The pg_hba.conf FileUpAuthentication Methods
\ No newline at end of file diff --git a/doc/src/sgml/html/auto-explain.html b/doc/src/sgml/html/auto-explain.html new file mode 100644 index 000000000..e08c57fb2 --- /dev/null +++ b/doc/src/sgml/html/auto-explain.html @@ -0,0 +1,464 @@ + +auto_explain
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.3. auto_explain

The auto_explain module provides a means for + logging execution plans of slow statements automatically, without + having to run EXPLAIN + by hand. This is especially helpful for tracking down un-optimized queries + in large applications. +

The module provides no SQL-accessible functions. To use it, simply + load it into the server. You can load it into an individual session: + +

LOAD 'auto_explain';

+ + (You must be superuser to do that.) More typical usage is to preload + it into all sessions by including auto_explain in + shared_preload_libraries in + postgresql.conf. Then you can track unexpectedly slow queries + no matter when they happen. Of course there is a price in overhead for + that. +

F.3.1. Configuration Parameters

There are several configuration parameters that control the behavior of + auto_explain. Note that the default behavior is + to do nothing, so you must set at least + auto_explain.log_min_duration if you want any results. +

auto_explain.log_min_duration (integer)

auto_explain.log_min_duration is the minimum statement + execution time, in milliseconds, that will cause the statement's plan to + be logged. Setting this to zero logs all plans. Minus-one (the default) + disables logging of plans. For example, if you set it to + 250ms then all statements that run 250ms or longer + will be logged. Only superusers can change this setting. +

auto_explain.log_analyze (boolean)

auto_explain.log_analyze causes EXPLAIN ANALYZE + output, rather than just EXPLAIN output, to be printed + when an execution plan is logged. This parameter is off by default. + Only superusers can change this setting. +

Note: When this parameter is on, per-plan-node timing occurs for all + statements executed, whether or not they run long enough to actually + get logged. This can have an extremely negative impact on performance. +

auto_explain.log_verbose (boolean)

auto_explain.log_verbose causes EXPLAIN VERBOSE + output, rather than just EXPLAIN output, to be printed + when an execution plan is logged. This parameter is off by default. + Only superusers can change this setting. +

auto_explain.log_buffers (boolean)

auto_explain.log_buffers causes EXPLAIN + (ANALYZE, BUFFERS) output, rather than just EXPLAIN + output, to be printed when an execution plan is logged. This parameter is + off by default. Only superusers can change this setting. This + parameter has no effect unless auto_explain.log_analyze + parameter is set. +

auto_explain.log_format (enum)

auto_explain.log_format selects the + EXPLAIN output format to be used. + The allowed values are text, xml, + json, and yaml. The default is text. + Only superusers can change this setting. +

auto_explain.log_nested_statements (boolean)

auto_explain.log_nested_statements causes nested + statements (statements executed inside a function) to be considered + for logging. When it is off, only top-level query plans are logged. This + parameter is off by default. Only superusers can change this setting. +

These parameters must be set in postgresql.conf. + Typical usage might be: +

# postgresql.conf
+shared_preload_libraries = 'auto_explain'
+
+auto_explain.log_min_duration = '3s'

F.3.2. Example

postgres=# LOAD 'auto_explain';
+postgres=# SET auto_explain.log_min_duration = 0;
+postgres=# SELECT count(*)
+           FROM pg_class, pg_index
+           WHERE oid = indrelid AND indisunique;

This might produce log output such as: +

LOG:  duration: 3.651 ms  plan:
+  Query Text: SELECT count(*)
+              FROM pg_class, pg_index
+              WHERE oid = indrelid AND indisunique;
+  Aggregate  (cost=16.79..16.80 rows=1 width=0) (actual time=3.626..3.627 rows=1 loops=1)
+    ->  Hash Join  (cost=4.17..16.55 rows=92 width=0) (actual time=3.349..3.594 rows=92 loops=1)
+          Hash Cond: (pg_class.oid = pg_index.indrelid)
+          ->  Seq Scan on pg_class  (cost=0.00..9.55 rows=255 width=4) (actual time=0.016..0.140 rows=255 loops=1)
+          ->  Hash  (cost=3.02..3.02 rows=92 width=4) (actual time=3.238..3.238 rows=92 loops=1)
+                Buckets: 1024  Batches: 1  Memory Usage: 4kB
+                ->  Seq Scan on pg_index  (cost=0.00..3.02 rows=92 width=4) (actual time=0.008..3.187 rows=92 loops=1)
+                      Filter: indisunique

PrevHomeNext
auth_delayUpbtree_gin
\ No newline at end of file diff --git a/doc/src/sgml/html/backup-dump.html b/doc/src/sgml/html/backup-dump.html new file mode 100644 index 000000000..62586efa1 --- /dev/null +++ b/doc/src/sgml/html/backup-dump.html @@ -0,0 +1,858 @@ + +SQL Dump
PostgreSQL 9.2.2 Documentation
PrevUpChapter 24. Backup and RestoreNext

24.1. SQL Dump

The idea behind this dump method is to generate a text file with SQL + commands that, when fed back to the server, will recreate the + database in the same state as it was at the time of the dump. + PostgreSQL provides the utility program + pg_dump for this purpose. The basic usage of this + command is: +

pg_dump dbname > outfile

+ As you see, pg_dump writes its result to the + standard output. We will see below how this can be useful. +

pg_dump is a regular PostgreSQL + client application (albeit a particularly clever one). This means + that you can perform this backup procedure from any remote host that has + access to the database. But remember that pg_dump + does not operate with special permissions. In particular, it must + have read access to all tables that you want to back up, so in + practice you almost always have to run it as a database superuser. +

To specify which database server pg_dump should + contact, use the command line options -h + host and -p port. The + default host is the local host or whatever your + PGHOST environment variable specifies. Similarly, + the default port is indicated by the PGPORT + environment variable or, failing that, by the compiled-in default. + (Conveniently, the server will normally have the same compiled-in + default.) +

Like any other PostgreSQL client application, + pg_dump will by default connect with the database + user name that is equal to the current operating system user name. To override + this, either specify the -U option or set the + environment variable PGUSER. Remember that + pg_dump connections are subject to the normal + client authentication mechanisms (which are described in Chapter 19). +

An important advantage of pg_dump over the other backup + methods described later is that pg_dump's output can + generally be re-loaded into newer versions of PostgreSQL, + whereas file-level backups and continuous archiving are both extremely + server-version-specific. pg_dump is also the only method + that will work when transferring a database to a different machine + architecture, such as going from a 32-bit to a 64-bit server. +

Dumps created by pg_dump are internally consistent, + meaning, the dump represents a snapshot of the database at the time + pg_dump began running. pg_dump does not + block other operations on the database while it is working. + (Exceptions are those operations that need to operate with an + exclusive lock, such as most forms of ALTER TABLE.) +

Important: If your database schema relies on OIDs (for instance, as foreign + keys) you must instruct pg_dump to dump the OIDs + as well. To do this, use the -o command-line + option. +

24.1.1. Restoring the Dump

The text files created by pg_dump are intended to + be read in by the psql program. The + general command form to restore a dump is +

psql dbname < infile

+ where infile is the + file output by the pg_dump command. The database dbname will not be created by this + command, so you must create it yourself from template0 + before executing psql (e.g., with + createdb -T template0 dbname). psql + supports options similar to pg_dump for specifying + the database server to connect to and the user name to use. See + the psql reference page for more information. +

Before restoring an SQL dump, all the users who own objects or were + granted permissions on objects in the dumped database must already + exist. If they do not, the restore will fail to recreate the + objects with the original ownership and/or permissions. + (Sometimes this is what you want, but usually it is not.) +

By default, the psql script will continue to + execute after an SQL error is encountered. You might wish to run + psql with + the ON_ERROR_STOP variable set to alter that + behavior and have psql exit with an + exit status of 3 if an SQL error occurs: +

psql --set ON_ERROR_STOP=on dbname < infile

+ Either way, you will only have a partially restored database. + Alternatively, you can specify that the whole dump should be + restored as a single transaction, so the restore is either fully + completed or fully rolled back. This mode can be specified by + passing the -1 or --single-transaction + command-line options to psql. When using this + mode, be aware that even a minor error can rollback a + restore that has already run for many hours. However, that might + still be preferable to manually cleaning up a complex database + after a partially restored dump. +

The ability of pg_dump and psql to + write to or read from pipes makes it possible to dump a database + directly from one server to another, for example: +

pg_dump -h host1 dbname | psql -h host2 dbname

+

Important: The dumps produced by pg_dump are relative to + template0. This means that any languages, procedures, + etc. added via template1 will also be dumped by + pg_dump. As a result, when restoring, if you are + using a customized template1, you must create the + empty database from template0, as in the example + above. +

After restoring a backup, it is wise to run ANALYZE on each + database so the query optimizer has useful statistics; + see Section 23.1.3 + and Section 23.1.6 for more information. + For more advice on how to load large amounts of data + into PostgreSQL efficiently, refer to Section 14.4. +

24.1.2. Using pg_dumpall

pg_dump dumps only a single database at a time, + and it does not dump information about roles or tablespaces + (because those are cluster-wide rather than per-database). + To support convenient dumping of the entire contents of a database + cluster, the pg_dumpall program is provided. + pg_dumpall backs up each database in a given + cluster, and also preserves cluster-wide data such as role and + tablespace definitions. The basic usage of this command is: +

pg_dumpall > outfile

+ The resulting dump can be restored with psql: +

psql -f infile postgres

+ (Actually, you can specify any existing database name to start from, + but if you are loading into an empty cluster then postgres + should usually be used.) It is always necessary to have + database superuser access when restoring a pg_dumpall + dump, as that is required to restore the role and tablespace information. + If you use tablespaces, make sure that the tablespace paths in the + dump are appropriate for the new installation. +

pg_dumpall works by emitting commands to re-create + roles, tablespaces, and empty databases, then invoking + pg_dump for each database. This means that while + each database will be internally consistent, the snapshots of + different databases might not be exactly in-sync. +

24.1.3. Handling Large Databases

Some operating systems have maximum file size limits that cause + problems when creating large pg_dump output files. + Fortunately, pg_dump can write to the standard + output, so you can use standard Unix tools to work around this + potential problem. There are several possible methods: +

Use compressed dumps. You can use your favorite compression program, for example + gzip: + +

pg_dump dbname | gzip > filename.gz

+ + Reload with: + +

gunzip -c filename.gz | psql dbname

+ + or: + +

cat filename.gz | gunzip | psql dbname

+

Use split. The split command + allows you to split the output into smaller files that are + acceptable in size to the underlying file system. For example, to + make chunks of 1 megabyte: + +

pg_dump dbname | split -b 1m - filename

+ + Reload with: + +

cat filename* | psql dbname

+

Use pg_dump's custom dump format. If PostgreSQL was built on a system with the + zlib compression library installed, the custom dump + format will compress data as it writes it to the output file. This will + produce dump file sizes similar to using gzip, but it + has the added advantage that tables can be restored selectively. The + following command dumps a database using the custom dump format: + +

pg_dump -Fc dbname > filename

+ + A custom-format dump is not a script for psql, but + instead must be restored with pg_restore, for example: + +

pg_restore -d dbname filename

+ + See the pg_dump and pg_restore reference pages for details. +

For very large databases, you might need to combine split + with one of the other two approaches. +


PrevHomeNext
Backup and RestoreUpFile System Level Backup
\ No newline at end of file diff --git a/doc/src/sgml/html/backup-file.html b/doc/src/sgml/html/backup-file.html new file mode 100644 index 000000000..dbd2290ee --- /dev/null +++ b/doc/src/sgml/html/backup-file.html @@ -0,0 +1,347 @@ + +File System Level Backup
PostgreSQL 9.2.2 Documentation
PrevUpChapter 24. Backup and RestoreNext

24.2. File System Level Backup

An alternative backup strategy is to directly copy the files that + PostgreSQL uses to store the data in the database; + Section 17.2 explains where these files + are located. You can use whatever method you prefer + for doing file system backups; for example: + +

tar -cf backup.tar /usr/local/pgsql/data

+

There are two restrictions, however, which make this method + impractical, or at least inferior to the pg_dump + method: + +

  1. The database server must be shut down in order to + get a usable backup. Half-way measures such as disallowing all + connections will not work + (in part because tar and similar tools do not take + an atomic snapshot of the state of the file system, + but also because of internal buffering within the server). + Information about stopping the server can be found in + Section 17.5. Needless to say, you + also need to shut down the server before restoring the data. +

  2. If you have dug into the details of the file system layout of the + database, you might be tempted to try to back up or restore only certain + individual tables or databases from their respective files or + directories. This will not work because the + information contained in these files is not usable without + the commit log files, + pg_clog/*, which contain the commit status of + all transactions. A table file is only usable with this + information. Of course it is also impossible to restore only a + table and the associated pg_clog data + because that would render all other tables in the database + cluster useless. So file system backups only work for complete + backup and restoration of an entire database cluster. +

+

An alternative file-system backup approach is to make a + "consistent snapshot" of the data directory, if the + file system supports that functionality (and you are willing to + trust that it is implemented correctly). The typical procedure is + to make a "frozen snapshot" of the volume containing the + database, then copy the whole data directory (not just parts, see + above) from the snapshot to a backup device, then release the frozen + snapshot. This will work even while the database server is running. + However, a backup created in this way saves + the database files in a state as if the database server was not + properly shut down; therefore, when you start the database server + on the backed-up data, it will think the previous server instance + crashed and will replay the WAL log. This is not a problem; just + be aware of it (and be sure to include the WAL files in your backup). + You can perform a CHECKPOINT before taking the + snapshot to reduce recovery time. +

If your database is spread across multiple file systems, there might not + be any way to obtain exactly-simultaneous frozen snapshots of all + the volumes. For example, if your data files and WAL log are on different + disks, or if tablespaces are on different file systems, it might + not be possible to use snapshot backup because the snapshots + must be simultaneous. + Read your file system documentation very carefully before trusting + the consistent-snapshot technique in such situations. +

If simultaneous snapshots are not possible, one option is to shut down + the database server long enough to establish all the frozen snapshots. + Another option is to perform a continuous archiving base backup (Section 24.3.2) because such backups are immune to file + system changes during the backup. This requires enabling continuous + archiving just during the backup process; restore is done using + continuous archive recovery (Section 24.3.4). +

Another option is to use rsync to perform a file + system backup. This is done by first running rsync + while the database server is running, then shutting down the database + server just long enough to do a second rsync. The + second rsync will be much quicker than the first, + because it has relatively little data to transfer, and the end result + will be consistent because the server was down. This method + allows a file system backup to be performed with minimal downtime. +

Note that a file system backup will typically be larger + than an SQL dump. (pg_dump does not need to dump + the contents of indexes for example, just the commands to recreate + them.) However, taking a file system backup might be faster. +


PrevHomeNext
SQL DumpUpContinuous Archiving and Point-in-Time Recovery (PITR)
\ No newline at end of file diff --git a/doc/src/sgml/html/backup.html b/doc/src/sgml/html/backup.html new file mode 100644 index 000000000..f08047e24 --- /dev/null +++ b/doc/src/sgml/html/backup.html @@ -0,0 +1,291 @@ + +Backup and Restore

Chapter 24. Backup and Restore

As with everything that contains valuable data, PostgreSQL + databases should be backed up regularly. While the procedure is + essentially simple, it is important to have a clear understanding of + the underlying techniques and assumptions. +

There are three fundamentally different approaches to backing up + PostgreSQL data: +

  • SQL dump

  • File system level backup

  • Continuous archiving

+ Each has its own strengths and weaknesses; each is discussed in turn + in the following sections. +


PrevHomeNext
Log File MaintenanceUpSQL Dump
\ No newline at end of file diff --git a/doc/src/sgml/html/biblio.html b/doc/src/sgml/html/biblio.html new file mode 100644 index 000000000..68b58ef20 --- /dev/null +++ b/doc/src/sgml/html/biblio.html @@ -0,0 +1,738 @@ + +Bibliography

Bibliography

Selected references and readings for SQL + and PostgreSQL. +

Some white papers and technical reports from the original + POSTGRES development team + are available at the University of California, Berkeley, Computer Science + Department web site. +

SQL Reference Books

Judith Bowman, Sandra Emerson, and Marcy Darnovsky, The Practical SQL Handbook: Using SQL Variants, Fourth Edition, Addison-Wesley Professional, ISBN 0-201-70309-2, 2001.

C. J. Date and Hugh Darwen, A Guide to the SQL Standard: A user's guide to the standard database language SQL, Fourth Edition, Addison-Wesley, ISBN 0-201-96426-0, 1997.

C. J. Date, An Introduction to Database Systems, Eighth Edition, Addison-Wesley, ISBN 0-321-19784-4, 2003.

Ramez Elmasri and Shamkant Navathe, Fundamentals of Database Systems, Fourth Edition, Addison-Wesley, ISBN 0-321-12226-7, 2003.

Jim Melton and Alan R. Simon, Understanding the New SQL: A complete guide, Morgan Kaufmann, ISBN 1-55860-245-3, 1993.

Jeffrey D. Ullman, Principles of Database and Knowledge: Base Systems, Volume 1, Computer Science Press, 1988.

PostgreSQL-specific Documentation

Stefan Simkovics, Enhancement of the ANSI SQL Implementation of PostgreSQL, Department of Information Systems, Vienna University of Technology, November 29, 1998.

Discusses SQL history and syntax, and describes the addition of + INTERSECT and EXCEPT constructs into + PostgreSQL. Prepared as a Master's + Thesis with the support of O. Univ. Prof. Dr. Georg Gottlob and + Univ. Ass. Mag. Katrin Seyr at Vienna University of Technology. +

A. Yu and J. Chen, The POSTGRES Group, The Postgres95 User Manual, University of California, Sept. 5, 1995.

Zelaine Fong, The design and implementation of the POSTGRES query optimizer + , University of California, Berkeley, Computer Science Department.

Proceedings and Articles

Nels Olson, Partial indexing in POSTGRES: research project, University of California, UCB Engin T7.49.1993 O676, 1993.

L. Ong and J. Goh, "A Unified Framework for Version Modeling Using Production Rules in a Database System", ERL Technical Memorandum M90/33, University of California, April, 1990.

L. Rowe and M. Stonebraker, " The POSTGRES data model + ", Proc. VLDB Conference, Sept. 1987.

P. Seshadri and A. Swami, "Generalized Partial Indexes + (cached version) + + ", Proc. Eleventh International Conference on Data Engineering, 6-10 March 1995, IEEE Computer Society Press, Cat. No.95CH35724, 1995, 420-7.

M. Stonebraker and L. Rowe, " The design of POSTGRES + ", Proc. ACM-SIGMOD Conference on Management of Data, May 1986.

M. Stonebraker, E. Hanson, and C. H. Hong, "The design of the POSTGRES rules system", Proc. IEEE Conference on Data Engineering, Feb. 1987.

M. Stonebraker, " The design of the POSTGRES storage system + ", Proc. VLDB Conference, Sept. 1987.

M. Stonebraker, M. Hearst, and S. Potamianos, " A commentary on the POSTGRES rules system + ", SIGMOD Record 18(3), Sept. 1989.

M. Stonebraker, " The case for partial indexes + ", SIGMOD Record 18(4), Dec. 1989, 4-11.

M. Stonebraker, L. A. Rowe, and M. Hirohama, " The implementation of POSTGRES + ", Transactions on Knowledge and Data Engineering 2(1), IEEE, March 1990.

M. Stonebraker, A. Jhingran, J. Goh, and S. Potamianos, " On Rules, Procedures, Caching and Views in Database Systems + ", Proc. ACM-SIGMOD Conference on Management of Data, June 1990.


PrevHomeNext
Acronyms Index
\ No newline at end of file diff --git a/doc/src/sgml/html/bki-commands.html b/doc/src/sgml/html/bki-commands.html new file mode 100644 index 000000000..a75fcb32c --- /dev/null +++ b/doc/src/sgml/html/bki-commands.html @@ -0,0 +1,710 @@ + +BKI Commands
PostgreSQL 9.2.2 Documentation
PrevUpChapter 57. BKI Backend InterfaceNext

57.2. BKI Commands

create + tablename + tableoid + [bootstrap] + [shared_relation] + [without_oids] + [rowtype_oid oid] + (name1 = + type1 [, + name2 = type2, ...])

Create a table named tablename, and having the OID + tableoid, + with the columns given in parentheses. +

The following column types are supported directly by + bootstrap.c: bool, + bytea, char (1 byte), + name, int2, + int4, regproc, regclass, + regtype, text, + oid, tid, xid, + cid, int2vector, oidvector, + _int4 (array), _text (array), + _oid (array), _char (array), + _aclitem (array). Although it is possible to create + tables containing columns of other types, this cannot be done until + after pg_type has been created and filled with + appropriate entries. (That effectively means that only these + column types can be used in bootstrapped tables, but non-bootstrap + catalogs can contain any built-in type.) +

When bootstrap is specified, + the table will only be created on disk; nothing is entered into + pg_class, + pg_attribute, etc, for it. Thus the + table will not be accessible by ordinary SQL operations until + such entries are made the hard way (with insert + commands). This option is used for creating + pg_class etc themselves. +

The table is created as shared if shared_relation is + specified. + It will have OIDs unless without_oids is specified. + The table's row type OID (pg_type OID) can optionally + be specified via the rowtype_oid clause; if not specified, + an OID is automatically generated for it. (The rowtype_oid + clause is useless if bootstrap is specified, but it can be + provided anyway for documentation.) +

open tablename

Open the table named + tablename + for insertion of data. Any currently open table is closed. +

close [tablename]

Close the open table. The name of the table can be given as a + cross-check, but this is not required. +

insert [OID = oid_value] ( value1 value2 ... )

Insert a new row into the open table using value1, value2, etc., for its column + values and oid_value for its OID. If + oid_value is zero + (0) or the clause is omitted, and the table has OIDs, then the + next available OID is assigned. +

NULL values can be specified using the special key word + _null_. Values containing spaces must be + double quoted. +

declare [unique] + index indexname + indexoid + on tablename + using amname + ( opclass1 + name1 + [, ...] )

Create an index named indexname, having OID + indexoid, + on the table named + tablename, using the + amname access + method. The fields to index are called name1, name2 etc., and the operator + classes to use are opclass1, opclass2 etc., respectively. + The index file is created and appropriate catalog entries are + made for it, but the index contents are not initialized by this command. +

declare toast + toasttableoid + toastindexoid + on tablename

Create a TOAST table for the table named + tablename. + The TOAST table is assigned OID + toasttableoid + and its index is assigned OID + toastindexoid. + As with declare index, filling of the index + is postponed. +

build indices

Fill in the indices that have previously been declared. +


PrevHomeNext
BKI File FormatUpStructure of the Bootstrap BKI File
\ No newline at end of file diff --git a/doc/src/sgml/html/bki-example.html b/doc/src/sgml/html/bki-example.html new file mode 100644 index 000000000..adc6a5cf2 --- /dev/null +++ b/doc/src/sgml/html/bki-example.html @@ -0,0 +1,199 @@ + +Example
PostgreSQL 9.2.2 Documentation
PrevUpChapter 57. BKI Backend InterfaceNext

57.4. Example

The following sequence of commands will create the + table test_table with OID 420, having two columns + cola and colb of type + int4 and text, respectively, and insert + two rows into the table: +

create test_table 420 (cola = int4, colb = text)
+open test_table
+insert OID=421 ( 1 "value1" )
+insert OID=422 ( 2 _null_ )
+close test_table

+


PrevHomeNext
Structure of the Bootstrap BKI FileUpHow the Planner Uses Statistics
\ No newline at end of file diff --git a/doc/src/sgml/html/bki-format.html b/doc/src/sgml/html/bki-format.html new file mode 100644 index 000000000..d9b82c823 --- /dev/null +++ b/doc/src/sgml/html/bki-format.html @@ -0,0 +1,210 @@ + +BKI File Format
PostgreSQL 9.2.2 Documentation
PrevUpChapter 57. BKI Backend InterfaceNext

57.1. BKI File Format

This section describes how the PostgreSQL + backend interprets BKI files. This description + will be easier to understand if the postgres.bki + file is at hand as an example. +

BKI input consists of a sequence of commands. Commands are made up + of a number of tokens, depending on the syntax of the command. + Tokens are usually separated by whitespace, but need not be if + there is no ambiguity. There is no special command separator; the + next token that syntactically cannot belong to the preceding + command starts a new one. (Usually you would put a new command on + a new line, for clarity.) Tokens can be certain key words, special + characters (parentheses, commas, etc.), numbers, or double-quoted + strings. Everything is case sensitive. +

Lines starting with # are ignored. +


PrevHomeNext
BKI Backend InterfaceUpBKI Commands
\ No newline at end of file diff --git a/doc/src/sgml/html/bki-structure.html b/doc/src/sgml/html/bki-structure.html new file mode 100644 index 000000000..7605402f8 --- /dev/null +++ b/doc/src/sgml/html/bki-structure.html @@ -0,0 +1,311 @@ + +Structure of the Bootstrap BKI File
PostgreSQL 9.2.2 Documentation
PrevUpChapter 57. BKI Backend InterfaceNext

57.3. Structure of the Bootstrap BKI File

The open command cannot be used until the tables it uses + exist and have entries for the table that is to be opened. + (These minimum tables are pg_class, + pg_attribute, pg_proc, and + pg_type.) To allow those tables themselves to be filled, + create with the bootstrap option implicitly opens + the created table for data insertion. +

Also, the declare index and declare toast + commands cannot be used until the system catalogs they need have been + created and filled in. +

Thus, the structure of the postgres.bki file has to + be: +

  1. create bootstrap one of the critical tables +

  2. insert data describing at least the critical tables +

  3. close +

  4. Repeat for the other critical tables. +

  5. create (without bootstrap) a noncritical table +

  6. open +

  7. insert desired data +

  8. close +

  9. Repeat for the other noncritical tables. +

  10. Define indexes and toast tables. +

  11. build indices +

+

There are doubtless other, undocumented ordering dependencies. +


PrevHomeNext
BKI CommandsUpExample
\ No newline at end of file diff --git a/doc/src/sgml/html/bki.html b/doc/src/sgml/html/bki.html new file mode 100644 index 000000000..b94792739 --- /dev/null +++ b/doc/src/sgml/html/bki.html @@ -0,0 +1,275 @@ + +BKI Backend Interface

Chapter 57. BKI Backend Interface

Backend Interface (BKI) files are scripts in a + special language that is understood by the + PostgreSQL backend when running in the + "bootstrap" mode. The bootstrap mode allows system catalogs + to be created and filled from scratch, whereas ordinary SQL commands + require the catalogs to exist already. + BKI files can therefore be used to create the + database system in the first place. (And they are probably not + useful for anything else.) +

initdb uses a BKI file + to do part of its job when creating a new database cluster. The + input file used by initdb is created as + part of building and installing PostgreSQL + by a program named genbki.pl, which reads some + specially formatted C header files in the src/include/catalog/ + directory of the source tree. The created BKI file + is called postgres.bki and is + normally installed in the + share subdirectory of the installation tree. +

Related information can be found in the documentation for + initdb. +


PrevHomeNext
Database Page LayoutUpBKI File Format
\ No newline at end of file diff --git a/doc/src/sgml/html/bookindex.html b/doc/src/sgml/html/bookindex.html new file mode 100644 index 000000000..fe0086775 --- /dev/null +++ b/doc/src/sgml/html/bookindex.html @@ -0,0 +1,18228 @@ + +Index

Index

Symbols | A | B | C | D | E | F | G | H | I | J | K | L | M | N | O | P | Q | R | S | T | U | V | W | X | Y | Z

Symbols

$, + Positional Parameters +
$libdir, + Dynamic Loading +
$libdir/plugins, + Other Defaults, + Description +
*, + Select-List Items +
.pgpass, + The Password File +
.pg_service.conf, + The Connection Service File +
::, + Type Casts +
_PG_fini, + Dynamic Loading +
_PG_init, + Dynamic Loading +

A

abbrev, + Network Address Functions and Operators +
ABORT, + ABORT +
abs, + Mathematical Functions and Operators +
acos, + Mathematical Functions and Operators +
administration tools +
externally maintained, + Administration Tools +
adminpack, + adminpack +
advisory lock, + Advisory Locks +
age, + Date/Time Functions and Operators +
aggregate function, + Aggregate Functions +
built-in, + Aggregate Functions +
invocation, + Aggregate Expressions +
user-defined, + User-defined Aggregates +
AIX +
installation on, + AIX +
IPC configuration, + Shared Memory and Semaphores +
alias +
for table name in query, + Joins Between Tables +
in the FROM clause, + Table and Column Aliases +
in the select list, + Column Labels +
ALL, + Subquery Expressions, + Row and Array Comparisons +
allow_system_table_mods configuration parameter, + Developer Options +
ALTER AGGREGATE, + ALTER AGGREGATE +
ALTER COLLATION, + ALTER COLLATION +
ALTER CONVERSION, + ALTER CONVERSION +
ALTER DATABASE, + ALTER DATABASE +
ALTER DEFAULT PRIVILEGES, + ALTER DEFAULT PRIVILEGES +
ALTER DOMAIN, + ALTER DOMAIN +
ALTER EXTENSION, + ALTER EXTENSION +
ALTER FOREIGN DATA WRAPPER, + ALTER FOREIGN DATA WRAPPER +
ALTER FOREIGN TABLE, + ALTER FOREIGN TABLE +
ALTER FUNCTION, + ALTER FUNCTION +
ALTER GROUP, + ALTER GROUP +
ALTER INDEX, + ALTER INDEX +
ALTER LANGUAGE, + ALTER LANGUAGE +
ALTER LARGE OBJECT, + ALTER LARGE OBJECT +
ALTER OPERATOR, + ALTER OPERATOR +
ALTER OPERATOR CLASS, + ALTER OPERATOR CLASS +
ALTER OPERATOR FAMILY, + ALTER OPERATOR FAMILY +
ALTER ROLE, + Role Attributes, + ALTER ROLE +
ALTER SCHEMA, + ALTER SCHEMA +
ALTER SEQUENCE, + ALTER SEQUENCE +
ALTER SERVER, + ALTER SERVER +
ALTER TABLE, + ALTER TABLE +
ALTER TABLESPACE, + ALTER TABLESPACE +
ALTER TEXT SEARCH CONFIGURATION, + ALTER TEXT SEARCH CONFIGURATION +
ALTER TEXT SEARCH DICTIONARY, + ALTER TEXT SEARCH DICTIONARY +
ALTER TEXT SEARCH PARSER, + ALTER TEXT SEARCH PARSER +
ALTER TEXT SEARCH TEMPLATE, + ALTER TEXT SEARCH TEMPLATE +
ALTER TRIGGER, + ALTER TRIGGER +
ALTER TYPE, + ALTER TYPE +
ALTER USER, + ALTER USER +
ALTER USER MAPPING, + ALTER USER MAPPING +
ALTER VIEW, + ALTER VIEW +
ANALYZE, + Updating Planner Statistics, + ANALYZE +
AND (operator), + Logical Operators +
anonymous code blocks, + DO +
any, + Pseudo-Types, + Aggregate Functions, + Subquery Expressions, + Row and Array Comparisons +
anyarray, + Pseudo-Types +
anyelement, + Pseudo-Types +
anyenum, + Pseudo-Types +
anynonarray, + Pseudo-Types +
anyrange, + Pseudo-Types +
applicable role, + applicable_roles +
application_name configuration parameter, + What To Log +
arbitrary precision numbers, + Arbitrary Precision Numbers +
archive_cleanup_command recovery parameter, + Archive Recovery Settings +
archive_command configuration parameter, + Archiving +
archive_mode configuration parameter, + Archiving +
archive_timeout configuration parameter, + Archiving +
area, + Geometric Functions and Operators +
ARRAY, + Array Constructors, + Arrays +
accessing, + Accessing Arrays +
constant, + Array Value Input +
constructor, + Array Constructors +
declaration, + Declaration of Array Types +
determination of result type, + UNION, CASE, and Related Constructs +
I/O, + Array Input and Output Syntax +
modifying, + Modifying Arrays +
of user-defined type, + User-defined Types +
searching, + Searching in Arrays +
array_agg, + Aggregate Functions +
array_append, + Array Functions and Operators +
array_cat, + Array Functions and Operators +
array_dims, + Array Functions and Operators +
array_fill, + Array Functions and Operators +
array_length, + Array Functions and Operators +
array_lower, + Array Functions and Operators +
array_ndims, + Array Functions and Operators +
array_nulls configuration parameter, + Previous PostgreSQL Versions +
array_prepend, + Array Functions and Operators +
array_to_json, + JSON Functions +
array_to_string, + Array Functions and Operators +
array_upper, + Array Functions and Operators +
ascii, + String Functions and Operators +
asin, + Mathematical Functions and Operators +
asynchronous commit, + Asynchronous Commit +
AT TIME ZONE, + AT TIME ZONE +
atan, + Mathematical Functions and Operators +
atan2, + Mathematical Functions and Operators +
authentication_timeout configuration parameter, + Security and Authentication +
auth_delay, + auth_delay +
auth_delay.milliseconds configuration parameter, + Configuration Parameters +
auto-increment +
see serial
autocommit +
bulk-loading data, + Disable Autocommit +
psql, + Variables +
autovacuum +
configuration parameters, + Automatic Vacuuming +
general information, + The Autovacuum Daemon +
autovacuum configuration parameter, + Automatic Vacuuming +
autovacuum_analyze_scale_factor configuration parameter, + Automatic Vacuuming +
autovacuum_analyze_threshold configuration parameter, + Automatic Vacuuming +
autovacuum_freeze_max_age configuration parameter, + Automatic Vacuuming +
autovacuum_max_workers configuration parameter, + Automatic Vacuuming +
autovacuum_naptime configuration parameter, + Automatic Vacuuming +
autovacuum_vacuum_cost_delay configuration parameter, + Automatic Vacuuming +
autovacuum_vacuum_cost_limit configuration parameter, + Automatic Vacuuming +
autovacuum_vacuum_scale_factor configuration parameter, + Automatic Vacuuming +
autovacuum_vacuum_threshold configuration parameter, + Automatic Vacuuming +
auto_explain, + auto_explain +
auto_explain.log_analyze configuration parameter, + Configuration Parameters +
auto_explain.log_buffers configuration parameter, + Configuration Parameters +
auto_explain.log_format configuration parameter, + Configuration Parameters +
auto_explain.log_min_duration configuration parameter, + Configuration Parameters +
auto_explain.log_nested_statements configuration parameter, + Configuration Parameters +
auto_explain.log_verbose configuration parameter, + Configuration Parameters +
average, + Aggregate Functions +
avg, + Aggregate Functions +

B

B-tree +
see index
backslash escapes, + String Constants with C-style Escapes +
backslash_quote configuration parameter, + Previous PostgreSQL Versions +
backup, + Backup Control Functions, + Backup and Restore +
base type, + The PostgreSQL Type System +
BEGIN, + BEGIN +
BETWEEN, + Comparison Operators +
BETWEEN SYMMETRIC, + Comparison Operators +
bgwriter_delay configuration parameter, + Background Writer +
bgwriter_lru_maxpages configuration parameter, + Background Writer +
bgwriter_lru_multiplier configuration parameter, + Background Writer +
bigint, + Numeric Constants, + Integer Types +
bigserial, + Serial Types +
binary data, + Binary Data Types +
functions, + Binary String Functions and Operators +
binary string +
concatenation, + Binary String Functions and Operators +
length, + Binary String Functions and Operators +
bison, + Requirements +
bit string +
constant, + Bit-string Constants +
data type, + Bit String Types +
bit strings +
functions, + Bit String Functions and Operators +
bitmap scan, + Combining Multiple Indexes, + Planner Method Configuration +
bit_and, + Aggregate Functions +
bit_length, + String Functions and Operators +
bit_or, + Aggregate Functions +
BLOB +
see large object
block_size configuration parameter, + Preset Options +
bonjour configuration parameter, + Connection Settings +
bonjour_name configuration parameter, + Connection Settings +
Boolean +
data type, + Boolean Type +
operators +
see operators, logical
bool_and, + Aggregate Functions +
bool_or, + Aggregate Functions +
booting +
starting the server during, + Starting the Database Server +
box, + Geometric Functions and Operators +
box (data type), + Boxes +
broadcast, + Network Address Functions and Operators +
btree_gin, + btree_gin +
btree_gist, + btree_gist +
btrim, + String Functions and Operators, + Binary String Functions and Operators +
bytea, + Binary Data Types +
bytea_output configuration parameter, + Statement Behavior +

C

C, + libpq - C Library, + ECPG - Embedded SQL in C +
C++, + Using C++ for Extensibility +
canceling +
SQL command, + Canceling Queries in Progress +
CASCADE +
with DROP, + Dependency Tracking +
foreign key action, + Foreign Keys +
Cascading Replication, + High Availability, Load Balancing, and Replication +
CASE, + Conditional Expressions +
determination of result type, + UNION, CASE, and Related Constructs +
case sensitivity +
of SQL commands, + Identifiers and Key Words +
cast +
I/O conversion, + CREATE CAST +
cbrt, + Mathematical Functions and Operators +
ceil, + Mathematical Functions and Operators +
ceiling, + Mathematical Functions and Operators +
center, + Geometric Functions and Operators +
Certificate, + Certificate Authentication +
char, + Character Types +
character, + Character Types +
character set, + Locale and Formatting, + Preset Options, + Character Set Support +
character string +
concatenation, + String Functions and Operators +
constant, + String Constants +
data types, + Character Types +
length, + String Functions and Operators +
character varying, + Character Types +
char_length, + String Functions and Operators +
check constraint, + Check Constraints +
checkpoint, + WAL Configuration, + CHECKPOINT +
checkpoint_completion_target configuration parameter, + Checkpoints +
checkpoint_segments configuration parameter, + Checkpoints +
checkpoint_timeout configuration parameter, + Checkpoints +
checkpoint_warning configuration parameter, + Checkpoints +
check_function_bodies configuration parameter, + Statement Behavior +
chkpass, + chkpass +
chr, + String Functions and Operators +
cid, + Object Identifier Types +
cidr, + cidr +
circle, + Circles, + Geometric Functions and Operators +
citext, + citext +
client authentication, + Client Authentication +
timeout during, + Security and Authentication +
client_encoding configuration parameter, + Locale and Formatting +
client_min_messages configuration parameter, + When To Log +
clock_timestamp, + Date/Time Functions and Operators +
CLOSE, + CLOSE +
CLUSTER, + CLUSTER +
of databases +
see database cluster
clusterdb, + clusterdb +
clustering, + High Availability, Load Balancing, and Replication +
cmax, + System Columns +
cmin, + System Columns +
COALESCE, + COALESCE +
COLLATE, + Collation Expressions +
collation, + Collation Support +
in PL/pgSQL, + Collation of PL/pgSQL Variables +
in SQL functions, + SQL Functions with Collations +
collation for, + System Information Functions +
column, + Concepts, + Table Basics +
adding, + Adding a Column +
removing, + Removing a Column +
renaming, + Renaming a Column +
system column, + System Columns +
column data type +
changing, + Changing a Column's Data Type +
column reference, + Column References +
col_description, + System Information Functions +
COMMENT, + COMMENT +
about database objects, + System Information Functions +
in SQL, + Comments +
COMMIT, + COMMIT +
COMMIT PREPARED, + COMMIT PREPARED +
commit_delay configuration parameter, + Settings +
commit_siblings configuration parameter, + Settings +
common table expression +
see WITH
comparison +
operators, + Comparison Operators +
row-wise, + Row and Array Comparisons +
subquery result row, + Subquery Expressions +
compiling +
libpq applications, + Building libpq Programs +
composite type, + Composite Types, + The PostgreSQL Type System +
constant, + Composite Value Input +
constructor, + Row Constructors +
computed field, + SQL Functions on Composite Types +
concat, + String Functions and Operators +
concat_ws, + String Functions and Operators +
concurrency, + Concurrency Control +
conditional expression, + Conditional Expressions +
configuration +
of recovery +
of a standby server, + Recovery Configuration +
of the server, + Server Configuration +
of the server +
functions, + Configuration Settings Functions +
configure, + Installation Procedure +
config_file configuration parameter, + File Locations +
conjunction, + Logical Operators +
connection service file, + The Connection Service File +
conninfo, + Connection Strings +
constant, + Constants +
constraint, + Constraints +
adding, + Adding a Constraint +
check, + Check Constraints +
exclusion, + Exclusion Constraints +
foreign key, + Foreign Keys +
name, + Check Constraints +
NOT NULL, + Not-Null Constraints +
primary key, + Primary Keys +
removing, + Removing a Constraint +
unique, + Unique Constraints +
constraint exclusion, + Partitioning and Constraint Exclusion, + Other Planner Options +
constraint_exclusion configuration parameter, + Other Planner Options +
CONTINUE +
in PL/pgSQL, + CONTINUE +
continuous archiving, + Backup and Restore +
control file, + Extension Files +
convert, + String Functions and Operators +
convert_from, + String Functions and Operators +
convert_to, + String Functions and Operators +
COPY, + Populating a Table With Rows, + COPY +
with libpq, + Functions Associated with the COPY Command +
corr, + Aggregate Functions +
correlation, + Aggregate Functions +
cos, + Mathematical Functions and Operators +
cot, + Mathematical Functions and Operators +
count, + Aggregate Functions +
covariance +
population, + Aggregate Functions +
sample, + Aggregate Functions +
covar_pop, + Aggregate Functions +
covar_samp, + Aggregate Functions +
cpu_index_tuple_cost configuration parameter, + Planner Cost Constants +
cpu_operator_cost configuration parameter, + Planner Cost Constants +
cpu_tuple_cost configuration parameter, + Planner Cost Constants +
CREATE AGGREGATE, + CREATE AGGREGATE +
CREATE CAST, + CREATE CAST +
CREATE COLLATION, + CREATE COLLATION +
CREATE CONVERSION, + CREATE CONVERSION +
CREATE DATABASE, + Creating a Database, + CREATE DATABASE +
CREATE DOMAIN, + CREATE DOMAIN +
CREATE EXTENSION, + CREATE EXTENSION +
CREATE FOREIGN DATA WRAPPER, + CREATE FOREIGN DATA WRAPPER +
CREATE FOREIGN TABLE, + CREATE FOREIGN TABLE +
CREATE FUNCTION, + CREATE FUNCTION +
CREATE GROUP, + CREATE GROUP +
CREATE INDEX, + CREATE INDEX +
CREATE LANGUAGE, + CREATE LANGUAGE +
CREATE OPERATOR, + CREATE OPERATOR +
CREATE OPERATOR CLASS, + CREATE OPERATOR CLASS +
CREATE OPERATOR FAMILY, + CREATE OPERATOR FAMILY +
CREATE ROLE, + Database Roles, + CREATE ROLE +
CREATE RULE, + CREATE RULE +
CREATE SCHEMA, + CREATE SCHEMA +
CREATE SEQUENCE, + CREATE SEQUENCE +
CREATE SERVER, + CREATE SERVER +
CREATE TABLE, + Creating a New Table, + CREATE TABLE +
CREATE TABLE AS, + CREATE TABLE AS +
CREATE TABLESPACE, + Tablespaces, + CREATE TABLESPACE +
CREATE TEXT SEARCH CONFIGURATION, + CREATE TEXT SEARCH CONFIGURATION +
CREATE TEXT SEARCH DICTIONARY, + CREATE TEXT SEARCH DICTIONARY +
CREATE TEXT SEARCH PARSER, + CREATE TEXT SEARCH PARSER +
CREATE TEXT SEARCH TEMPLATE, + CREATE TEXT SEARCH TEMPLATE +
CREATE TRIGGER, + CREATE TRIGGER +
CREATE TYPE, + CREATE TYPE +
CREATE USER, + CREATE USER +
CREATE USER MAPPING, + CREATE USER MAPPING +
CREATE VIEW, + CREATE VIEW +
createdb, + Creating a Database, + Creating a Database, + createdb +
createlang, + createlang +
createuser, + Database Roles, + createuser +
cross compilation, + Installation Procedure +
cross join, + Joined Tables +
cstring, + Pseudo-Types +
ctid, + System Columns, + View Rules in Non-SELECT Statements +
cube, + cube +
cume_dist, + Window Functions +
current_catalog, + System Information Functions +
current_database, + System Information Functions +
current_date, + Date/Time Functions and Operators +
current_query, + System Information Functions +
current_schema, + System Information Functions +
current_schemas, + System Information Functions +
current_setting, + Configuration Settings Functions +
current_time, + Date/Time Functions and Operators +
current_timestamp, + Date/Time Functions and Operators +
current_user, + System Information Functions +
currval, + Sequence Manipulation Functions +
cursor +
CLOSE, + CLOSE +
DECLARE, + DECLARE +
FETCH, + FETCH +
in PL/pgSQL, + Cursors +
MOVE, + MOVE +
showing the query plan, + EXPLAIN +
cursor_tuple_fraction configuration parameter, + Other Planner Options +
Cygwin +
installation on, + Cygwin +

D

data area +
see database cluster
data partitioning, + High Availability, Load Balancing, and Replication +
data type, + Data Types +
base, + The PostgreSQL Type System +
category, + Overview +
composite, + The PostgreSQL Type System +
constant, + Constants of Other Types +
conversion, + Type Conversion +
enumerated (enum), + Enumerated Types +
internal organization, + Base Types in C-Language Functions +
numeric, + Numeric Types +
type cast, + Type Casts +
user-defined, + User-defined Types +
database, + Managing Databases +
creating, + Creating a Database +
privilege to create, + Role Attributes +
database activity +
monitoring, + Monitoring Database Activity +
database cluster, + Concepts, + Creating a Database Cluster +
data_directory configuration parameter, + File Locations +
date, + Date/Time Types, + Dates +
constants, + Special Values +
current, + Current Date/Time +
output format, + Date/Time Output +
see also formatting
DateStyle configuration parameter, + Locale and Formatting +
date_part, + Date/Time Functions and Operators, + EXTRACT, date_part +
date_trunc, + Date/Time Functions and Operators, + date_trunc +
dblink, + dblink +
db_user_namespace configuration parameter, + Security and Authentication +
deadlock, + Deadlocks +
timeout during, + Lock Management +
deadlock_timeout configuration parameter, + Lock Management +
DEALLOCATE, + DEALLOCATE +
debug_assertions configuration parameter, + Developer Options +
debug_deadlocks configuration parameter, + Developer Options +
debug_pretty_print configuration parameter, + What To Log +
debug_print_parse configuration parameter, + What To Log +
debug_print_plan configuration parameter, + What To Log +
debug_print_rewritten configuration parameter, + What To Log +
decimal +
see numeric
DECLARE, + DECLARE +
decode, + String Functions and Operators, + Binary String Functions and Operators +
decode_bytea +
in PL/Perl, + Utility Functions in PL/Perl +
default value, + Default Values +
changing, + Changing a Column's Default Value +
default_statistics_target configuration parameter, + Other Planner Options +
default_tablespace configuration parameter, + Statement Behavior +
default_text_search_config configuration parameter, + Locale and Formatting +
default_transaction_deferrable configuration parameter, + Statement Behavior +
default_transaction_isolation configuration parameter, + Statement Behavior +
default_transaction_read_only configuration parameter, + Statement Behavior +
default_with_oids configuration parameter, + Previous PostgreSQL Versions +
deferrable transaction +
setting, + SET TRANSACTION +
setting default, + Statement Behavior +
degrees, + Mathematical Functions and Operators +
delay, + Delaying Execution +
DELETE, + Deletions, + Deleting Data, + DELETE +
deleting, + Deleting Data +
dense_rank, + Window Functions +
diameter, + Geometric Functions and Operators +
dict_int, + dict_int +
dict_xsyn, + dict_xsyn +
Digital UNIX +
see Tru64 UNIX
dirty read, + Transaction Isolation +
DISCARD, + DISCARD +
disjunction, + Logical Operators +
disk drive, + WAL Internals +
disk space, + Recovering Disk Space +
disk usage, + Determining Disk Usage +
DISTINCT, + Querying a Table, + DISTINCT +
div, + Mathematical Functions and Operators +
DO, + DO +
document +
text search, + What Is a Document? +
dollar quoting, + Dollar-quoted String Constants +
double precision, + Floating-Point Types +
DROP AGGREGATE, + DROP AGGREGATE +
DROP CAST, + DROP CAST +
DROP COLLATION, + DROP COLLATION +
DROP CONVERSION, + DROP CONVERSION +
DROP DATABASE, + Destroying a Database, + DROP DATABASE +
DROP DOMAIN, + DROP DOMAIN +
DROP EXTENSION, + DROP EXTENSION +
DROP FOREIGN DATA WRAPPER, + DROP FOREIGN DATA WRAPPER +
DROP FOREIGN TABLE, + DROP FOREIGN TABLE +
DROP FUNCTION, + DROP FUNCTION +
DROP GROUP, + DROP GROUP +
DROP INDEX, + DROP INDEX +
DROP LANGUAGE, + DROP LANGUAGE +
DROP OPERATOR, + DROP OPERATOR +
DROP OPERATOR CLASS, + DROP OPERATOR CLASS +
DROP OPERATOR FAMILY, + DROP OPERATOR FAMILY +
DROP OWNED, + DROP OWNED +
DROP ROLE, + Database Roles, + DROP ROLE +
DROP RULE, + DROP RULE +
DROP SCHEMA, + DROP SCHEMA +
DROP SEQUENCE, + DROP SEQUENCE +
DROP SERVER, + DROP SERVER +
DROP TABLE, + Creating a New Table, + DROP TABLE +
DROP TABLESPACE, + DROP TABLESPACE +
DROP TEXT SEARCH CONFIGURATION, + DROP TEXT SEARCH CONFIGURATION +
DROP TEXT SEARCH DICTIONARY, + DROP TEXT SEARCH DICTIONARY +
DROP TEXT SEARCH PARSER, + DROP TEXT SEARCH PARSER +
DROP TEXT SEARCH TEMPLATE, + DROP TEXT SEARCH TEMPLATE +
DROP TRIGGER, + DROP TRIGGER +
DROP TYPE, + DROP TYPE +
DROP USER, + DROP USER +
DROP USER MAPPING, + DROP USER MAPPING +
DROP VIEW, + DROP VIEW +
dropdb, + Destroying a Database, + dropdb +
droplang, + droplang +
dropuser, + Database Roles, + dropuser +
DTD, + Creating XML Values +
DTrace, + Installation Procedure, + Dynamic Tracing +
dummy_seclabel, + dummy_seclabel +
duplicate, + Querying a Table +
duplicates, + DISTINCT +
dynamic loading, + Other Defaults, + Dynamic Loading +
dynamic_library_path, + Dynamic Loading +
dynamic_library_path configuration parameter, + Other Defaults +

E

earthdistance, + earthdistance +
ECPG, + ECPG - Embedded SQL in C, + ecpg +
effective_cache_size configuration parameter, + Planner Cost Constants +
effective_io_concurrency configuration parameter, + Asynchronous Behavior +
elog, + Reporting Errors Within the Server +
in PL/Perl, + Utility Functions in PL/Perl +
in PL/Python, + Utility Functions +
in PL/Tcl, + Database Access from PL/Tcl +
embedded SQL +
in C, + ECPG - Embedded SQL in C +
enabled role, + enabled_roles +
enable_bitmapscan configuration parameter, + Planner Method Configuration +
enable_hashagg configuration parameter, + Planner Method Configuration +
enable_hashjoin configuration parameter, + Planner Method Configuration +
enable_indexonlyscan configuration parameter, + Planner Method Configuration +
enable_indexscan configuration parameter, + Planner Method Configuration +
enable_material configuration parameter, + Planner Method Configuration +
enable_mergejoin configuration parameter, + Planner Method Configuration +
enable_nestloop configuration parameter, + Planner Method Configuration +
enable_seqscan configuration parameter, + Planner Method Configuration +
enable_sort configuration parameter, + Planner Method Configuration +
enable_tidscan configuration parameter, + Planner Method Configuration +
encode, + String Functions and Operators, + Binary String Functions and Operators +
encode_array_constructor +
in PL/Perl, + Utility Functions in PL/Perl +
encode_array_literal +
in PL/Perl, + Utility Functions in PL/Perl +
encode_bytea +
in PL/Perl, + Utility Functions in PL/Perl +
encode_typed_literal +
in PL/Perl, + Utility Functions in PL/Perl +
encryption, + Encryption Options +
for specific columns, + pgcrypto +
END, + END +
enumerated types, + Enumerated Types +
enum_first, + Enum Support Functions +
enum_last, + Enum Support Functions +
enum_range, + Enum Support Functions +
environment variable, + Environment Variables +
ereport, + Reporting Errors Within the Server +
error codes +
libpq, + Main Functions +
list of, + PostgreSQL Error Codes +
error message, + Connection Status Functions +
escape string syntax, + String Constants with C-style Escapes +
escape_string_warning configuration parameter, + Previous PostgreSQL Versions +
escaping strings +
in libpq, + Escaping Strings for Inclusion in SQL Commands +
event log +
event log, + Registering Event Log on Windows +
event_source configuration parameter, + Where To Log +
every, + Aggregate Functions +
EXCEPT, + Combining Queries +
exceptions +
in PL/pgSQL, + Trapping Errors +
exclusion constraint, + Exclusion Constraints +
EXECUTE, + EXECUTE +
EXISTS, + Subquery Expressions +
EXIT +
in PL/pgSQL, + EXIT +
exit_on_error configuration parameter, + Error Handling +
exp, + Mathematical Functions and Operators +
EXPLAIN, + Using EXPLAIN, + EXPLAIN +
expression +
order of evaluation, + Expression Evaluation Rules +
syntax, + Value Expressions +
extending SQL, + Extending SQL +
extension, + Packaging Related Objects into an Extension +
externally maintained, + Extensions +
external_pid_file configuration parameter, + File Locations +
extract, + Date/Time Functions and Operators, + EXTRACT, date_part +
extra_float_digits configuration parameter, + Locale and Formatting +

F

failover, + High Availability, Load Balancing, and Replication +
false, + Boolean Type +
family, + Network Address Functions and Operators +
fast path, + The Fast-Path Interface +
fdw_handler, + Pseudo-Types +
FETCH, + FETCH +
field +
computed, + SQL Functions on Composite Types +
field selection, + Field Selection +
file_fdw, + file_fdw +
first_value, + Window Functions +
flex, + Requirements +
float4 +
see real
float8 +
see double precision
floating point, + Floating-Point Types +
floating-point +
display, + Locale and Formatting +
floor, + Mathematical Functions and Operators +
foreign data, + Foreign Data +
foreign data wrapper +
handler for, + Writing A Foreign Data Wrapper +
foreign key, + Foreign Keys, + Foreign Keys +
foreign table, + Foreign Data +
format, + String Functions and Operators +
use in PL/pgSQL, + Executing Dynamic Commands +
formatting, + Data Type Formatting Functions +
format_type, + System Information Functions +
Free Space Map, + Free Space Map +
FreeBSD +
IPC configuration, + Shared Memory and Semaphores +
shared library, + Compiling and Linking Dynamically-loaded Functions +
start script, + Starting the Database Server +
from_collapse_limit configuration parameter, + Other Planner Options +
FSM +
see Free Space Map
fsync configuration parameter, + Settings +
full text search, + Full Text Search +
data types, + Text Search Types +
functions and operators, + Text Search Types +
full_page_writes configuration parameter, + Settings +
function, + Functions and Operators +
default values for arguments, + SQL Functions with Default Values for Arguments +
in the FROM clause, + Table Functions +
internal, + Internal Functions +
invocation, + Function Calls +
mixed notation, + Using Mixed Notation +
named argument, + Arguments for SQL Functions +
named notation, + Using Named Notation +
output parameter, + SQL Functions with Output Parameters +
polymorphic, + Polymorphic Types +
positional notation, + Using Positional Notation +
RETURNS TABLE, + SQL Functions Returning TABLE +
type resolution in an invocation, + Functions +
user-defined, + User-defined Functions +
in C, + C-Language Functions +
in SQL, + Query Language (SQL) Functions +
variadic, + SQL Functions with Variable Numbers of Arguments +
with SETOF, + SQL Functions Returning Sets +
functional dependency, + The GROUP BY and HAVING Clauses +
fuzzystrmatch, + fuzzystrmatch +

G

generate_series, + Set Returning Functions +
generate_subscripts, + Set Returning Functions +
genetic query optimization, + Genetic Query Optimizer +
GEQO +
see genetic query optimization
geqo configuration parameter, + Genetic Query Optimizer +
geqo_effort configuration parameter, + Genetic Query Optimizer +
geqo_generations configuration parameter, + Genetic Query Optimizer +
geqo_pool_size configuration parameter, + Genetic Query Optimizer +
geqo_seed configuration parameter, + Genetic Query Optimizer +
geqo_selection_bias configuration parameter, + Genetic Query Optimizer +
geqo_threshold configuration parameter, + Genetic Query Optimizer +
get_bit, + Binary String Functions and Operators +
get_byte, + Binary String Functions and Operators +
get_current_ts_config, + Text Search Functions and Operators +
GIN +
see index
gin_fuzzy_search_limit configuration parameter, + Other Defaults +
GiST +
see index
global data +
in PL/Python, + Sharing Data +
in PL/Tcl, + Global Data in PL/Tcl +
GRANT, + Privileges, + GRANT +
GREATEST, + GREATEST and LEAST +
determination of result type, + UNION, CASE, and Related Constructs +
Gregorian calendar, + History of Units +
GROUP BY, + Aggregate Functions, + The GROUP BY and HAVING Clauses +
grouping, + The GROUP BY and HAVING Clauses +
GSSAPI, + GSSAPI Authentication +
GUID, + UUID Type +

H

hash +
see index
has_any_column_privilege, + System Information Functions +
has_column_privilege, + System Information Functions +
has_database_privilege, + System Information Functions +
has_foreign_data_wrapper_privilege, + System Information Functions +
has_function_privilege, + System Information Functions +
has_language_privilege, + System Information Functions +
has_schema_privilege, + System Information Functions +
has_sequence_privilege, + System Information Functions +
has_server_privilege, + System Information Functions +
has_tablespace_privilege, + System Information Functions +
has_table_privilege, + System Information Functions +
HAVING, + Aggregate Functions, + The GROUP BY and HAVING Clauses +
hba_file configuration parameter, + File Locations +
height, + Geometric Functions and Operators +
hierarchical database, + Concepts +
high availability, + High Availability, Load Balancing, and Replication +
history +
of PostgreSQL, + A Brief History of PostgreSQL +
host, + Network Address Functions and Operators +
host name, + Parameter Key Words +
hostmask, + Network Address Functions and Operators +
Hot Standby, + High Availability, Load Balancing, and Replication +
hot_standby configuration parameter, + Standby Servers +
hot_standby_feedback configuration parameter, + Standby Servers +
HP-UX +
installation on, + HP-UX +
IPC configuration, + Shared Memory and Semaphores +
shared library, + Compiling and Linking Dynamically-loaded Functions +
hstore, + hstore +

I

ident, + Ident Authentication +
identifier +
length, + Identifiers and Key Words +
syntax of, + Identifiers and Key Words +
ident_file configuration parameter, + File Locations +
IFNULL, + COALESCE +
ignore_system_indexes configuration parameter, + Developer Options +
IMMUTABLE, + Function Volatility Categories +
IN, + Subquery Expressions, + Row and Array Comparisons +
include +
in configuration file, + Setting Parameters via the Configuration File +
include_if_exists +
in configuration file, + Setting Parameters via the Configuration File +
index, + Indexes +
and ORDER BY, + Indexes and ORDER BY +
B-tree, + Index Types +
building concurrently, + Building Indexes Concurrently +
combining multiple indexes, + Combining Multiple Indexes +
examining usage, + Examining Index Usage +
on expressions, + Indexes on Expressions +
for user-defined data type, + Interfacing Extensions To Indexes +
GIN, + Index Types, + GIN Indexes +
text search, + GiST and GIN Index Types +
GiST, + Index Types, + GiST Indexes +
text search, + GiST and GIN Index Types +
hash, + Index Types +
locks, + Locking and Indexes +
multicolumn, + Multicolumn Indexes +
partial, + Partial Indexes +
SP-GiST, + Index Types, + SP-GiST Indexes +
unique, + Unique Indexes +
index scan, + Planner Method Configuration +
index-only scan, + Planner Method Configuration +
inet (data type), + inet +
inet_client_addr, + System Information Functions +
inet_client_port, + System Information Functions +
inet_server_addr, + System Information Functions +
inet_server_port, + System Information Functions +
information schema, + The Information Schema +
inheritance, + Inheritance, + Inheritance, + Previous PostgreSQL Versions +
initcap, + String Functions and Operators +
initdb, + Creating a Database Cluster, + initdb +
Initialization Fork, + The Initialization Fork +
input function, + User-defined Types +
INSERT, + Populating a Table With Rows, + Inserting Data, + INSERT +
inserting, + Inserting Data +
installation, + Installation from Source Code +
on Windows, + Installation from Source Code on Windows +
instr, + Porting Examples +
int2 +
see smallint
int4 +
see integer
int8 +
see bigint
intagg, + intagg +
intarray, + intarray +
integer, + Numeric Constants, + Integer Types +
integer_datetimes configuration parameter, + Preset Options +
interfaces +
externally maintained, + Client Interfaces +
internal, + Pseudo-Types +
INTERSECT, + Combining Queries +
interval, + Date/Time Types, + Interval Input +
output format, + Interval Output +
see also formatting
IntervalStyle configuration parameter, + Locale and Formatting +
IRIX +
installation on, + IRIX +
shared library, + Compiling and Linking Dynamically-loaded Functions +
IS DISTINCT FROM, + Comparison Operators, + Row and Array Comparisons +
IS DOCUMENT, + IS DOCUMENT +
IS FALSE, + Comparison Operators +
IS NOT DISTINCT FROM, + Comparison Operators, + Row and Array Comparisons +
IS NOT FALSE, + Comparison Operators +
IS NOT NULL, + Comparison Operators +
IS NOT TRUE, + Comparison Operators +
IS NOT UNKNOWN, + Comparison Operators +
IS NULL, + Comparison Operators, + Platform and Client Compatibility +
IS TRUE, + Comparison Operators +
IS UNKNOWN, + Comparison Operators +
isclosed, + Geometric Functions and Operators +
isempty, + Range Functions and Operators +
isfinite, + Date/Time Functions and Operators +
isn, + isn +
ISNULL, + Comparison Operators +
isopen, + Geometric Functions and Operators +
is_array_ref +
in PL/Perl, + Utility Functions in PL/Perl +

J

join, + Joins Between Tables, + Joined Tables +
controlling the order, + Controlling the Planner with Explicit JOIN Clauses +
cross, + Joined Tables +
left, + Joined Tables +
natural, + Joined Tables +
outer, + Joins Between Tables, + Joined Tables +
right, + Joined Tables +
self, + Joins Between Tables +
join_collapse_limit configuration parameter, + Other Planner Options +
JSON, + JSON Type +
Functions and operators, + JSON Functions +
Julian date, + History of Units +
justify_days, + Date/Time Functions and Operators +
justify_hours, + Date/Time Functions and Operators +
justify_interval, + Date/Time Functions and Operators +

K

Kerberos, + Kerberos Authentication +
key word +
list of, + SQL Key Words +
syntax of, + Identifiers and Key Words +
krb_caseins_users configuration parameter, + Security and Authentication +
krb_server_keyfile configuration parameter, + Security and Authentication +
krb_srvname configuration parameter, + Security and Authentication +

L

label +
see alias
lag, + Window Functions +
language_handler, + Pseudo-Types +
large object, + Large Objects +
lastval, + Sequence Manipulation Functions +
last_value, + Window Functions +
lc_collate configuration parameter, + Preset Options +
lc_ctype configuration parameter, + Preset Options +
lc_messages configuration parameter, + Locale and Formatting +
lc_monetary configuration parameter, + Locale and Formatting +
lc_numeric configuration parameter, + Locale and Formatting +
lc_time configuration parameter, + Locale and Formatting +
LDAP, + Installation Procedure, + LDAP Authentication +
LDAP connection parameter lookup, + LDAP Lookup of Connection Parameters +
ldconfig, + Shared Libraries +
lead, + Window Functions +
LEAST, + GREATEST and LEAST +
determination of result type, + UNION, CASE, and Related Constructs +
left, + String Functions and Operators +
left join, + Joined Tables +
length, + String Functions and Operators, + Binary String Functions and Operators, + Geometric Functions and Operators, + Text Search Functions and Operators +
of a binary string +
see binary strings, length
of a character string +
see character string, length
length(tsvector), + Manipulating Documents +
lex, + Requirements +
libedit, + Requirements +
libperl, + Requirements +
libpq, + libpq - C Library +
single-row mode, + Retrieving Query Results Row-By-Row +
libpq-fe.h, + libpq - C Library, + Connection Status Functions +
libpq-int.h, + Connection Status Functions +
libpython, + Requirements +
library finalization function, + Dynamic Loading +
library initialization function, + Dynamic Loading +
LIKE, + LIKE +
and locales, + Behavior +
LIMIT, + LIMIT and OFFSET +
line segment, + Line Segments +
linear regression, + Aggregate Functions +
Linux +
IPC configuration, + Shared Memory and Semaphores +
shared library, + Compiling and Linking Dynamically-loaded Functions +
start script, + Starting the Database Server +
LISTEN, + LISTEN +
listen_addresses configuration parameter, + Connection Settings +
ln, + Mathematical Functions and Operators +
lo, + lo +
LOAD, + LOAD +
load balancing, + High Availability, Load Balancing, and Replication +
locale, + Creating a Database Cluster, + Locale Support +
localtime, + Date/Time Functions and Operators +
localtimestamp, + Date/Time Functions and Operators +
local_preload_libraries configuration parameter, + Other Defaults +
lock, + Explicit Locking, + Table-level Locks, + LOCK +
advisory, + Advisory Locks +
monitoring, + Viewing Locks +
log, + Mathematical Functions and Operators +
log shipping, + High Availability, Load Balancing, and Replication +
logging_collector configuration parameter, + Where To Log +
login privilege, + Role Attributes +
log_autovacuum_min_duration configuration parameter, + Automatic Vacuuming +
log_btree_build_stats configuration parameter, + Developer Options +
log_checkpoints configuration parameter, + What To Log +
log_connections configuration parameter, + What To Log +
log_destination configuration parameter, + Where To Log +
log_directory configuration parameter, + Where To Log +
log_disconnections configuration parameter, + What To Log +
log_duration configuration parameter, + What To Log +
log_error_verbosity configuration parameter, + What To Log +
log_executor_stats configuration parameter, + Statistics Monitoring +
log_filename configuration parameter, + Where To Log +
log_file_mode configuration parameter, + Where To Log +
log_hostname configuration parameter, + What To Log +
log_line_prefix configuration parameter, + What To Log +
log_lock_waits configuration parameter, + What To Log +
log_min_duration_statement configuration parameter, + When To Log +
log_min_error_statement configuration parameter, + When To Log +
log_min_messages configuration parameter, + When To Log +
log_parser_stats configuration parameter, + Statistics Monitoring +
log_planner_stats configuration parameter, + Statistics Monitoring +
log_rotation_age configuration parameter, + Where To Log +
log_rotation_size configuration parameter, + Where To Log +
log_statement configuration parameter, + What To Log +
log_statement_stats configuration parameter, + Statistics Monitoring +
log_temp_files configuration parameter, + What To Log +
log_timezone configuration parameter, + What To Log +
log_truncate_on_rotation configuration parameter, + Where To Log +
looks_like_number +
in PL/Perl, + Utility Functions in PL/Perl +
loop +
in PL/pgSQL, + Simple Loops +
lower, + String Functions and Operators, + Range Functions and Operators +
and locales, + Behavior +
lower_inc, + Range Functions and Operators +
lower_inf, + Range Functions and Operators +
lo_close, + Closing a Large Object Descriptor +
lo_compat_privileges configuration parameter, + Previous PostgreSQL Versions +
lo_creat, + Creating a Large Object, + Server-side Functions +
lo_create, + Creating a Large Object, + Server-side Functions +
lo_export, + Exporting a Large Object, + Server-side Functions +
lo_import, + Importing a Large Object, + Server-side Functions +
lo_import_with_oid, + Importing a Large Object +
lo_lseek, + Seeking in a Large Object +
lo_open, + Opening an Existing Large Object +
lo_read, + Reading Data from a Large Object +
lo_tell, + Obtaining the Seek Position of a Large Object +
lo_truncate, + Truncating a Large Object +
lo_unlink, + Removing a Large Object, + Server-side Functions +
lo_write, + Writing Data to a Large Object +
lpad, + String Functions and Operators +
lseg, + Line Segments, + Geometric Functions and Operators +
ltree, + ltree +
ltrim, + String Functions and Operators +

M

MAC address +
see macaddr
Mac OS X +
IPC configuration, + Shared Memory and Semaphores +
shared library, + Compiling and Linking Dynamically-loaded Functions +
macaddr (data type), + macaddr +
magic block, + Dynamic Loading +
maintenance, + Routine Database Maintenance Tasks +
maintenance_work_mem configuration parameter, + Memory +
make, + Requirements +
MANPATH, + Environment Variables +
masklen, + Network Address Functions and Operators +
max, + Aggregate Functions +
max_connections configuration parameter, + Connection Settings +
max_files_per_process configuration parameter, + Kernel Resource Usage +
max_function_args configuration parameter, + Preset Options +
max_identifier_length configuration parameter, + Preset Options +
max_index_keys configuration parameter, + Preset Options +
max_locks_per_transaction configuration parameter, + Lock Management +
max_pred_locks_per_transaction configuration parameter, + Lock Management +
max_prepared_transactions configuration parameter, + Memory +
max_stack_depth configuration parameter, + Memory +
max_standby_archive_delay configuration parameter, + Standby Servers +
max_standby_streaming_delay configuration parameter, + Standby Servers +
max_wal_senders configuration parameter, + Sending Server(s) +
md5, + String Functions and Operators, + Binary String Functions and Operators, + Password Authentication +
memory context +
in SPI, + Memory Management +
min, + Aggregate Functions +
MinGW +
installation on, + MinGW/Native Windows +
mod, + Mathematical Functions and Operators +
monitoring +
database activity, + Monitoring Database Activity +
MOVE, + MOVE +
Multiversion Concurrency Control, + Introduction +
MVCC, + Introduction +

N

name +
qualified, + Creating a Schema +
syntax of, + Identifiers and Key Words +
unqualified, + The Schema Search Path +
NaN +
see not a number
natural join, + Joined Tables +
negation, + Logical Operators +
NetBSD +
IPC configuration, + Shared Memory and Semaphores +
shared library, + Compiling and Linking Dynamically-loaded Functions +
start script, + Starting the Database Server +
netmask, + Network Address Functions and Operators +
network, + Network Address Functions and Operators +
data types, + Network Address Types +
Network Attached Storage (NAS) +
see Network File Systems
Network File Systems, + Network File Systems +
nextval, + Sequence Manipulation Functions +
NFS +
see Network File Systems
non-durable, + Non-Durable Settings +
nonblocking connection, + Database Connection Control Functions, + Asynchronous Command Processing +
nonrepeatable read, + Transaction Isolation +
NOT (operator), + Logical Operators +
not a number +
double precision, + Floating-Point Types +
numeric (data type), + Arbitrary Precision Numbers +
NOT IN, + Subquery Expressions, + Row and Array Comparisons +
not-null constraint, + Not-Null Constraints +
notation +
functions, + Calling Functions +
notice processing +
in libpq, + Notice Processing +
notice processor, + Notice Processing +
notice receiver, + Notice Processing +
NOTIFY, + NOTIFY +
in libpq, + Asynchronous Notification +
NOTNULL, + Comparison Operators +
now, + Date/Time Functions and Operators +
npoints, + Geometric Functions and Operators +
nth_value, + Window Functions +
ntile, + Window Functions +
null value +
with check constraints, + Check Constraints +
comparing, + Comparison Operators +
default value, + Default Values +
in DISTINCT, + DISTINCT +
in libpq, + Retrieving Query Result Information +
in PL/Perl, + PL/Perl Functions and Arguments +
in PL/Python, + Null, None +
with unique constraints, + Unique Constraints +
NULLIF, + NULLIF +
number +
constant, + Numeric Constants +
numeric, + Numeric Constants +
numeric (data type), + Arbitrary Precision Numbers +
numnode, + Text Search Functions and Operators, + Manipulating Queries +
NVL, + COALESCE +

O

object identifier +
data type, + Object Identifier Types +
object-oriented database, + Concepts +
obj_description, + System Information Functions +
octet_length, + String Functions and Operators, + Binary String Functions and Operators +
OFFSET, + LIMIT and OFFSET +
oid, + Object Identifier Types +
column, + System Columns +
in libpq, + Retrieving Other Result Information +
oid2name, + oid2name +
ONLY, + The FROM Clause +
opaque, + Pseudo-Types +
OpenBSD +
IPC configuration, + Shared Memory and Semaphores +
shared library, + Compiling and Linking Dynamically-loaded Functions +
start script, + Starting the Database Server +
OpenSSL, + Installation Procedure +
see also SSL
operator, + Functions and Operators +
invocation, + Operator Invocations +
logical, + Logical Operators +
precedence, + Operator Precedence +
syntax, + Operators +
type resolution in an invocation, + Operators +
user-defined, + User-defined Operators +
operator class, + Operator Classes and Operator Families, + Index Methods and Operator Classes +
operator family, + Operator Classes and Operator Families, + Operator Classes and Operator Families +
OR (operator), + Logical Operators +
Oracle +
porting from PL/SQL to PL/pgSQL, + Porting from Oracle PL/SQL +
ORDER BY, + Querying a Table, + Sorting Rows +
and locales, + Behavior +
ordering operator, + System Dependencies on Operator Classes +
outer join, + Joined Tables +
output function, + User-defined Types +
OVER clause, + Window Function Calls +
overlay, + String Functions and Operators, + Binary String Functions and Operators +
overloading +
functions, + Function Overloading +
operators, + User-defined Operators +
owner, + Privileges +

P

pageinspect, + pageinspect +
palloc, + Writing Code +
PAM, + Installation Procedure, + PAM Authentication +
parameter +
syntax, + Positional Parameters +
parenthesis, + Value Expressions +
partitioning, + Partitioning +
password, + Role Attributes +
authentication, + Password Authentication +
of the superuser, + Creating a Database Cluster +
password file, + The Password File +
passwordcheck, + passwordcheck +
password_encryption configuration parameter, + Security and Authentication +
path, + Geometric Functions and Operators, + Environment Variables +
for schemas, + Statement Behavior +
path (data type), + Paths +
pattern matching, + Pattern Matching +
patterns +
in psql and pg_dump, + Patterns +
pause_at_recovery_target recovery parameter, + Recovery Target Settings +
pclose, + Geometric Functions and Operators +
peer, + Peer Authentication +
percent_rank, + Window Functions +
performance, + Performance Tips +
perl, + Requirements, + PL/Perl - Perl Procedural Language +
permission +
see privilege
pfree, + Writing Code +
PGAPPNAME, + Environment Variables +
pgbench, + pgbench +
PGcancel, + Canceling Queries in Progress +
PGCLIENTENCODING, + Environment Variables +
PGconn, + Database Connection Control Functions +
PGCONNECT_TIMEOUT, + Environment Variables +
pgcrypto, + pgcrypto +
PGDATA, + Creating a Database Cluster +
PGDATABASE, + Environment Variables +
PGDATESTYLE, + Environment Variables +
PGEventProc, + Event Callback Procedure +
PGGEQO, + Environment Variables +
PGGSSLIB, + Environment Variables +
PGHOST, + Environment Variables +
PGHOSTADDR, + Environment Variables +
PGKRBSRVNAME, + Environment Variables +
PGLOCALEDIR, + Environment Variables +
PGOPTIONS, + Environment Variables +
PGPASSFILE, + Environment Variables +
PGPASSWORD, + Environment Variables +
PGPORT, + Environment Variables +
PGREALM, + Environment Variables +
PGREQUIREPEER, + Environment Variables +
PGREQUIRESSL, + Environment Variables +
PGresult, + Main Functions +
pgrowlocks, + pgrowlocks +
PGSERVICE, + Environment Variables +
PGSERVICEFILE, + Environment Variables +
PGSSLCERT, + Environment Variables +
PGSSLCOMPRESSION, + Environment Variables +
PGSSLCRL, + Environment Variables +
PGSSLKEY, + Environment Variables +
PGSSLMODE, + Environment Variables +
PGSSLROOTCERT, + Environment Variables +
pgstattuple, + pgstattuple +
PGSYSCONFDIR, + Environment Variables +
PGTZ, + Environment Variables +
PGUSER, + Environment Variables +
pgxs, + Extension Building Infrastructure +
pg_advisory_lock, + Advisory Lock Functions +
pg_advisory_lock_shared, + Advisory Lock Functions +
pg_advisory_unlock, + Advisory Lock Functions +
pg_advisory_unlock_all, + Advisory Lock Functions +
pg_advisory_unlock_shared, + Advisory Lock Functions +
pg_advisory_xact_lock, + Advisory Lock Functions +
pg_advisory_xact_lock_shared, + Advisory Lock Functions +
pg_aggregate, + pg_aggregate +
pg_am, + pg_am +
pg_amop, + pg_amop +
pg_amproc, + pg_amproc +
pg_archivecleanup, + pg_archivecleanup +
pg_attrdef, + pg_attrdef +
pg_attribute, + pg_attribute +
pg_authid, + pg_authid +
pg_auth_members, + pg_auth_members +
pg_available_extensions, + pg_available_extensions +
pg_available_extension_versions, + pg_available_extension_versions +
pg_backend_pid, + System Information Functions +
pg_basebackup, + pg_basebackup +
pg_buffercache, + pg_buffercache +
pg_cancel_backend, + Server Signalling Functions +
pg_cast, + pg_cast +
pg_class, + pg_class +
pg_client_encoding, + String Functions and Operators +
pg_collation, + pg_collation +
pg_collation_is_visible, + System Information Functions +
pg_column_size, + Database Object Management Functions +
pg_config, + pg_config +
with libpq, + Building libpq Programs +
with user-defined C functions, + Writing Code +
pg_conf_load_time, + System Information Functions +
pg_constraint, + pg_constraint +
pg_controldata, + pg_controldata +
pg_conversion, + pg_conversion +
pg_conversion_is_visible, + System Information Functions +
pg_create_restore_point, + Backup Control Functions +
pg_ctl, + Creating a Database Cluster, + Starting the Database Server, + pg_ctl +
pg_current_xlog_insert_location, + Backup Control Functions +
pg_current_xlog_location, + Backup Control Functions +
pg_cursors, + pg_cursors +
pg_database, + Template Databases, + pg_database +
pg_database_size, + Database Object Management Functions +
pg_db_role_setting, + pg_db_role_setting +
pg_default_acl, + pg_default_acl +
pg_depend, + pg_depend +
pg_describe_object, + System Information Functions +
pg_description, + pg_description +
pg_dump, + pg_dump +
pg_dumpall, + pg_dumpall +
use during upgrade, + Upgrading Data via pg_dump +
pg_enum, + pg_enum +
pg_export_snapshot, + Snapshot Synchronization Functions +
pg_extension, + pg_extension +
pg_foreign_data_wrapper, + pg_foreign_data_wrapper +
pg_foreign_server, + pg_foreign_server +
pg_foreign_table, + pg_foreign_table +
pg_freespacemap, + pg_freespacemap +
pg_function_is_visible, + System Information Functions +
pg_get_constraintdef, + System Information Functions +
pg_get_expr, + System Information Functions +
pg_get_functiondef, + System Information Functions +
pg_get_function_arguments, + System Information Functions +
pg_get_function_identity_arguments, + System Information Functions +
pg_get_function_result, + System Information Functions +
pg_get_indexdef, + System Information Functions +
pg_get_keywords, + System Information Functions +
pg_get_ruledef, + System Information Functions +
pg_get_serial_sequence, + System Information Functions +
pg_get_triggerdef, + System Information Functions +
pg_get_userbyid, + System Information Functions +
pg_get_viewdef, + System Information Functions +
pg_group, + pg_group +
pg_has_role, + System Information Functions +
pg_hba.conf, + The pg_hba.conf File +
pg_ident.conf, + User Name Maps +
pg_index, + pg_index +
pg_indexes, + pg_indexes +
pg_indexes_size, + Database Object Management Functions +
pg_inherits, + pg_inherits +
pg_is_in_recovery, + Recovery Control Functions +
pg_is_other_temp_schema, + System Information Functions +
pg_is_xlog_replay_paused, + Recovery Control Functions +
pg_language, + pg_language +
pg_largeobject, + pg_largeobject +
pg_largeobject_metadata, + pg_largeobject_metadata +
pg_last_xact_replay_timestamp, + Recovery Control Functions +
pg_last_xlog_receive_location, + Recovery Control Functions +
pg_last_xlog_replay_location, + Recovery Control Functions +
pg_listening_channels, + System Information Functions +
pg_locks, + pg_locks +
pg_ls_dir, + Generic File Access Functions +
pg_my_temp_schema, + System Information Functions +
pg_namespace, + pg_namespace +
pg_notify, + pg_notify +
pg_opclass, + pg_opclass +
pg_opclass_is_visible, + System Information Functions +
pg_operator, + pg_operator +
pg_operator_is_visible, + System Information Functions +
pg_opfamily, + pg_opfamily +
pg_opfamily_is_visible, + System Information Functions +
pg_options_to_table, + System Information Functions +
pg_pltemplate, + pg_pltemplate +
pg_postmaster_start_time, + System Information Functions +
pg_prepared_statements, + pg_prepared_statements +
pg_prepared_xacts, + pg_prepared_xacts +
pg_proc, + pg_proc +
pg_range, + pg_range +
pg_read_binary_file, + Generic File Access Functions +
pg_read_file, + Generic File Access Functions +
pg_receivexlog, + pg_receivexlog +
pg_relation_filenode, + Database Object Management Functions +
pg_relation_filepath, + Database Object Management Functions +
pg_relation_size, + Database Object Management Functions +
pg_reload_conf, + Server Signalling Functions +
pg_resetxlog, + pg_resetxlog +
pg_restore, + pg_restore +
pg_rewrite, + pg_rewrite +
pg_roles, + pg_roles +
pg_rotate_logfile, + Server Signalling Functions +
pg_rules, + pg_rules +
pg_seclabel, + pg_seclabel +
pg_seclabels, + pg_seclabels +
pg_service.conf, + The Connection Service File +
pg_settings, + pg_settings +
pg_shadow, + pg_shadow +
pg_shdepend, + pg_shdepend +
pg_shdescription, + pg_shdescription +
pg_shseclabel, + pg_shseclabel +
pg_size_pretty, + Database Object Management Functions +
pg_sleep, + Delaying Execution +
pg_standby, + pg_standby +
pg_start_backup, + Backup Control Functions +
pg_statio_all_indexes, + Viewing Collected Statistics +
pg_statio_all_sequences, + Viewing Collected Statistics +
pg_statio_all_tables, + Viewing Collected Statistics +
pg_statio_sys_indexes, + Viewing Collected Statistics +
pg_statio_sys_sequences, + Viewing Collected Statistics +
pg_statio_sys_tables, + Viewing Collected Statistics +
pg_statio_user_indexes, + Viewing Collected Statistics +
pg_statio_user_sequences, + Viewing Collected Statistics +
pg_statio_user_tables, + Viewing Collected Statistics +
pg_statistic, + Statistics Used by the Planner, + pg_statistic +
pg_stats, + Statistics Used by the Planner, + pg_stats +
pg_stat_activity, + Viewing Collected Statistics +
pg_stat_all_indexes, + Viewing Collected Statistics +
pg_stat_all_tables, + Viewing Collected Statistics +
pg_stat_bgwriter, + Viewing Collected Statistics +
pg_stat_database, + Viewing Collected Statistics +
pg_stat_database_conflicts, + Viewing Collected Statistics +
pg_stat_file, + Generic File Access Functions +
pg_stat_replication, + Viewing Collected Statistics +
pg_stat_statements, + pg_stat_statements +
pg_stat_sys_indexes, + Viewing Collected Statistics +
pg_stat_sys_tables, + Viewing Collected Statistics +
pg_stat_user_functions, + Viewing Collected Statistics +
pg_stat_user_indexes, + Viewing Collected Statistics +
pg_stat_user_tables, + Viewing Collected Statistics +
pg_stat_xact_all_tables, + Viewing Collected Statistics +
pg_stat_xact_sys_tables, + Viewing Collected Statistics +
pg_stat_xact_user_functions, + Viewing Collected Statistics +
pg_stat_xact_user_tables, + Viewing Collected Statistics +
pg_stop_backup, + Backup Control Functions +
pg_switch_xlog, + Backup Control Functions +
pg_tables, + pg_tables +
pg_tablespace, + pg_tablespace +
pg_tablespace_databases, + System Information Functions +
pg_tablespace_location, + System Information Functions +
pg_tablespace_size, + Database Object Management Functions +
pg_table_is_visible, + System Information Functions +
pg_table_size, + Database Object Management Functions +
pg_terminate_backend, + Server Signalling Functions +
pg_test_fsync, + pg_test_fsync +
pg_test_timing, + pg_test_timing +
pg_timezone_abbrevs, + pg_timezone_abbrevs +
pg_timezone_names, + pg_timezone_names +
pg_total_relation_size, + Database Object Management Functions +
pg_trgm, + pg_trgm +
pg_trigger, + pg_trigger +
pg_try_advisory_lock, + Advisory Lock Functions +
pg_try_advisory_lock_shared, + Advisory Lock Functions +
pg_try_advisory_xact_lock, + Advisory Lock Functions +
pg_try_advisory_xact_lock_shared, + Advisory Lock Functions +
pg_ts_config, + pg_ts_config +
pg_ts_config_is_visible, + System Information Functions +
pg_ts_config_map, + pg_ts_config_map +
pg_ts_dict, + pg_ts_dict +
pg_ts_dict_is_visible, + System Information Functions +
pg_ts_parser, + pg_ts_parser +
pg_ts_parser_is_visible, + System Information Functions +
pg_ts_template, + pg_ts_template +
pg_ts_template_is_visible, + System Information Functions +
pg_type, + pg_type +
pg_typeof, + System Information Functions +
pg_type_is_visible, + System Information Functions +
pg_upgrade, + pg_upgrade +
pg_user, + pg_user +
pg_user_mapping, + pg_user_mapping +
pg_user_mappings, + pg_user_mappings +
pg_views, + pg_views +
pg_xlogfile_name, + Backup Control Functions +
pg_xlogfile_name_offset, + Backup Control Functions +
pg_xlog_location_diff, + Backup Control Functions +
pg_xlog_replay_pause, + Recovery Control Functions +
pg_xlog_replay_resume, + Recovery Control Functions +
phantom read, + Transaction Isolation +
pi, + Mathematical Functions and Operators +
PIC, + Compiling and Linking Dynamically-loaded Functions +
PID +
determining PID of server process +
in libpq, + Connection Status Functions +
PITR, + Backup and Restore +
PITR standby, + High Availability, Load Balancing, and Replication +
PL/Perl, + PL/Perl - Perl Procedural Language +
PL/PerlU, + Trusted and Untrusted PL/Perl +
PL/pgSQL, + PL/pgSQL - SQL Procedural Language +
PL/Python, + PL/Python - Python Procedural Language +
PL/SQL (Oracle) +
porting to PL/pgSQL, + Porting from Oracle PL/SQL +
PL/Tcl, + PL/Tcl - Tcl Procedural Language +
plainto_tsquery, + Text Search Functions and Operators, + Parsing Queries +
plperl.on_init configuration parameter, + Configuration +
plperl.on_plperlu_init configuration parameter, + Configuration +
plperl.on_plperl_init configuration parameter, + Configuration +
plperl.use_strict configuration parameter, + Configuration +
plpgsql.variable_conflict configuration parameter, + Variable Substitution +
point, + Points, + Geometric Functions and Operators +
point-in-time recovery, + Backup and Restore +
polygon, + Polygons, + Geometric Functions and Operators +
polymorphic function, + Polymorphic Types +
polymorphic type, + Polymorphic Types +
popen, + Geometric Functions and Operators +
port, + Parameter Key Words +
port configuration parameter, + Connection Settings +
position, + String Functions and Operators, + Binary String Functions and Operators +
POSTGRES, + The Berkeley POSTGRES Project, + Architectural Fundamentals, + Starting the Database Server, + Creating a Database, + postgres +
postgres user, + The PostgreSQL User Account +
Postgres95, + Postgres95 +
postgresql.conf, + Setting Parameters via the Configuration File +
postmaster, + postmaster +
post_auth_delay configuration parameter, + Developer Options +
power, + Mathematical Functions and Operators +
PQbackendPID, + Connection Status Functions +
PQbinaryTuples, + Retrieving Query Result Information +
with COPY, + Functions Associated with the COPY Command +
PQcancel, + Canceling Queries in Progress +
PQclear, + Main Functions +
PQclientEncoding, + Control Functions +
PQcmdStatus, + Retrieving Other Result Information +
PQcmdTuples, + Retrieving Other Result Information +
PQconndefaults, + Database Connection Control Functions +
PQconnectdb, + Database Connection Control Functions +
PQconnectdbParams, + Database Connection Control Functions +
PQconnectionNeedsPassword, + Connection Status Functions +
PQconnectionUsedPassword, + Connection Status Functions +
PQconnectPoll, + Database Connection Control Functions +
PQconnectStart, + Database Connection Control Functions +
PQconnectStartParams, + Database Connection Control Functions +
PQconninfoFree, + Miscellaneous Functions +
PQconninfoParse, + Database Connection Control Functions +
PQconsumeInput, + Asynchronous Command Processing +
PQcopyResult, + Miscellaneous Functions +
PQdb, + Connection Status Functions +
PQdescribePortal, + Main Functions +
PQdescribePrepared, + Main Functions +
PQencryptPassword, + Miscellaneous Functions +
PQendcopy, + Obsolete Functions for COPY +
PQerrorMessage, + Connection Status Functions +
PQescapeBytea, + Escaping Strings for Inclusion in SQL Commands +
PQescapeByteaConn, + Escaping Strings for Inclusion in SQL Commands +
PQescapeIdentifier, + Escaping Strings for Inclusion in SQL Commands +
PQescapeLiteral, + Escaping Strings for Inclusion in SQL Commands +
PQescapeString, + Escaping Strings for Inclusion in SQL Commands +
PQescapeStringConn, + Escaping Strings for Inclusion in SQL Commands +
PQexec, + Main Functions +
PQexecParams, + Main Functions +
PQexecPrepared, + Main Functions +
PQfformat, + Retrieving Query Result Information +
with COPY, + Functions Associated with the COPY Command +
PQfinish, + Database Connection Control Functions +
PQfireResultCreateEvents, + Miscellaneous Functions +
PQflush, + Asynchronous Command Processing +
PQfmod, + Retrieving Query Result Information +
PQfn, + The Fast-Path Interface +
PQfname, + Retrieving Query Result Information +
PQfnumber, + Retrieving Query Result Information +
PQfreeCancel, + Canceling Queries in Progress +
PQfreemem, + Miscellaneous Functions +
PQfsize, + Retrieving Query Result Information +
PQftable, + Retrieving Query Result Information +
PQftablecol, + Retrieving Query Result Information +
PQftype, + Retrieving Query Result Information +
PQgetCancel, + Canceling Queries in Progress +
PQgetCopyData, + Functions for Receiving COPY Data +
PQgetisnull, + Retrieving Query Result Information +
PQgetlength, + Retrieving Query Result Information +
PQgetline, + Obsolete Functions for COPY +
PQgetlineAsync, + Obsolete Functions for COPY +
PQgetResult, + Asynchronous Command Processing +
PQgetssl, + Connection Status Functions +
PQgetvalue, + Retrieving Query Result Information +
PQhost, + Connection Status Functions +
PQinitOpenSSL, + SSL Library Initialization +
PQinitSSL, + SSL Library Initialization +
PQinstanceData, + Event Support Functions +
PQisBusy, + Asynchronous Command Processing +
PQisnonblocking, + Asynchronous Command Processing +
PQisthreadsafe, + Behavior in Threaded Programs +
PQlibVersion, + Miscellaneous Functions +
see also PQserverVersion
PQmakeEmptyPGresult, + Miscellaneous Functions +
PQnfields, + Retrieving Query Result Information +
with COPY, + Functions Associated with the COPY Command +
PQnotifies, + Asynchronous Notification +
PQnparams, + Retrieving Query Result Information +
PQntuples, + Retrieving Query Result Information +
PQoidStatus, + Retrieving Other Result Information +
PQoidValue, + Retrieving Other Result Information +
PQoptions, + Connection Status Functions +
PQparameterStatus, + Connection Status Functions +
PQparamtype, + Retrieving Query Result Information +
PQpass, + Connection Status Functions +
PQping, + Database Connection Control Functions +
PQpingParams, + Database Connection Control Functions +
PQport, + Connection Status Functions +
PQprepare, + Main Functions +
PQprint, + Retrieving Query Result Information +
PQprotocolVersion, + Connection Status Functions +
PQputCopyData, + Functions for Sending COPY Data +
PQputCopyEnd, + Functions for Sending COPY Data +
PQputline, + Obsolete Functions for COPY +
PQputnbytes, + Obsolete Functions for COPY +
PQregisterEventProc, + Event Support Functions +
PQrequestCancel, + Canceling Queries in Progress +
PQreset, + Database Connection Control Functions +
PQresetPoll, + Database Connection Control Functions +
PQresetStart, + Database Connection Control Functions +
PQresStatus, + Main Functions +
PQresultAlloc, + Miscellaneous Functions +
PQresultErrorField, + Main Functions +
PQresultErrorMessage, + Main Functions +
PQresultInstanceData, + Event Support Functions +
PQresultSetInstanceData, + Event Support Functions +
PQresultStatus, + Main Functions +
PQsendDescribePortal, + Asynchronous Command Processing +
PQsendDescribePrepared, + Asynchronous Command Processing +
PQsendPrepare, + Asynchronous Command Processing +
PQsendQuery, + Asynchronous Command Processing +
PQsendQueryParams, + Asynchronous Command Processing +
PQsendQueryPrepared, + Asynchronous Command Processing +
PQserverVersion, + Connection Status Functions +
PQsetClientEncoding, + Control Functions +
PQsetdb, + Database Connection Control Functions +
PQsetdbLogin, + Database Connection Control Functions +
PQsetErrorVerbosity, + Control Functions +
PQsetInstanceData, + Event Support Functions +
PQsetnonblocking, + Asynchronous Command Processing +
PQsetNoticeProcessor, + Notice Processing +
PQsetNoticeReceiver, + Notice Processing +
PQsetResultAttrs, + Miscellaneous Functions +
PQsetSingleRowMode, + Retrieving Query Results Row-By-Row +
PQsetvalue, + Miscellaneous Functions +
PQsocket, + Connection Status Functions +
PQstatus, + Connection Status Functions +
PQtrace, + Control Functions +
PQtransactionStatus, + Connection Status Functions +
PQtty, + Connection Status Functions +
PQunescapeBytea, + Escaping Strings for Inclusion in SQL Commands +
PQuntrace, + Control Functions +
PQuser, + Connection Status Functions +
predicate locking, + Serializable Isolation Level +
PREPARE, + PREPARE +
PREPARE TRANSACTION, + PREPARE TRANSACTION +
prepared statements +
creating, + PREPARE +
executing, + EXECUTE +
removing, + DEALLOCATE +
showing the query plan, + EXPLAIN +
preparing a query +
in PL/pgSQL, + Plan Caching +
in PL/Python, + Database Access Functions +
in PL/Tcl, + Database Access from PL/Tcl +
pre_auth_delay configuration parameter, + Developer Options +
primary key, + Primary Keys +
primary_conninfo recovery parameter, + Standby Server Settings +
privilege, + Privileges +
querying, + System Information Functions +
with rules, + Rules and Privileges +
for schemas, + Schemas and Privileges +
with views, + Rules and Privileges +
procedural language, + Procedural Languages +
externally maintained, + Procedural Languages +
handler for, + Writing A Procedural Language Handler +
protocol +
frontend-backend, + Frontend/Backend Protocol +
ps +
to monitor activity, + Standard Unix Tools +
psql, + Accessing a Database, + psql +
Python, + PL/Python - Python Procedural Language +

Q

qualified name, + Creating a Schema +
query, + Querying a Table, + Queries +
query plan, + Using EXPLAIN +
query tree, + The Query Tree +
querytree, + Text Search Functions and Operators, + Manipulating Queries +
quotation marks +
and identifiers, + Identifiers and Key Words +
escaping, + String Constants +
quote_all_identifiers configuration parameter, + Previous PostgreSQL Versions +
quote_ident, + String Functions and Operators +
in PL/Perl, + Utility Functions in PL/Perl +
use in PL/pgSQL, + Executing Dynamic Commands +
quote_literal, + String Functions and Operators +
in PL/Perl, + Utility Functions in PL/Perl +
use in PL/pgSQL, + Executing Dynamic Commands +
quote_nullable, + String Functions and Operators +
in PL/Perl, + Utility Functions in PL/Perl +
use in PL/pgSQL, + Executing Dynamic Commands +

R

radians, + Mathematical Functions and Operators +
radius, + Geometric Functions and Operators, + RADIUS Authentication +
RAISE, + Errors and Messages +
random, + Mathematical Functions and Operators +
random_page_cost configuration parameter, + Planner Cost Constants +
range table, + The Query Tree +
range type, + Range Types +
exclude, + Constraints on Ranges +
indexes on, + Indexing +
rank, + Window Functions +
read committed, + Read Committed Isolation Level +
read-only transaction +
setting, + SET TRANSACTION +
setting default, + Statement Behavior +
readline, + Requirements +
real, + Floating-Point Types +
REASSIGN OWNED, + REASSIGN OWNED +
record, + Pseudo-Types +
recovery.conf, + Recovery Configuration +
recovery_end_command recovery parameter, + Archive Recovery Settings +
recovery_target_inclusive recovery parameter, + Recovery Target Settings +
recovery_target_name recovery parameter, + Recovery Target Settings +
recovery_target_time recovery parameter, + Recovery Target Settings +
recovery_target_timeline recovery parameter, + Recovery Target Settings +
recovery_target_xid recovery parameter, + Recovery Target Settings +
rectangle, + Boxes +
referential integrity, + Foreign Keys, + Foreign Keys +
regclass, + Object Identifier Types +
regconfig, + Object Identifier Types +
regdictionary, + Object Identifier Types +
regexp_matches, + String Functions and Operators, + POSIX Regular Expressions +
regexp_replace, + String Functions and Operators, + POSIX Regular Expressions +
regexp_split_to_array, + String Functions and Operators, + POSIX Regular Expressions +
regexp_split_to_table, + String Functions and Operators, + POSIX Regular Expressions +
regoper, + Object Identifier Types +
regoperator, + Object Identifier Types +
regproc, + Object Identifier Types +
regprocedure, + Object Identifier Types +
regression intercept, + Aggregate Functions +
regression slope, + Aggregate Functions +
regression test, + Installation Procedure +
regression tests, + Regression Tests +
regr_avgx, + Aggregate Functions +
regr_avgy, + Aggregate Functions +
regr_count, + Aggregate Functions +
regr_intercept, + Aggregate Functions +
regr_r2, + Aggregate Functions +
regr_slope, + Aggregate Functions +
regr_sxx, + Aggregate Functions +
regr_sxy, + Aggregate Functions +
regr_syy, + Aggregate Functions +
regtype, + Object Identifier Types +
regular expression, + SIMILAR TO Regular Expressions, + POSIX Regular Expressions +
see also pattern matching
regular expressions +
and locales, + Behavior +
reindex, + Routine Reindexing, + REINDEX +
reindexdb, + reindexdb +
relation, + Concepts +
relational database, + Concepts +
RELEASE SAVEPOINT, + RELEASE SAVEPOINT +
repeat, + String Functions and Operators +
repeatable read, + Repeatable Read Isolation Level +
replace, + String Functions and Operators +
replication, + High Availability, Load Balancing, and Replication +
replication_timeout configuration parameter, + Sending Server(s) +
reporting errors +
in PL/pgSQL, + Errors and Messages +
RESET, + RESET +
restartpoint, + WAL Configuration +
restart_after_crash configuration parameter, + Error Handling +
restore_command recovery parameter, + Archive Recovery Settings +
RESTRICT +
with DROP, + Dependency Tracking +
foreign key action, + Foreign Keys +
RETURN NEXT +
in PL/pgSQL, + RETURN NEXT and RETURN QUERY +
RETURN QUERY +
in PL/pgSQL, + RETURN NEXT and RETURN QUERY +
RETURNING INTO +
in PL/pgSQL, + Executing a Query with a Single-row Result +
reverse, + String Functions and Operators +
REVOKE, + Privileges, + REVOKE +
right, + String Functions and Operators +
right join, + Joined Tables +
role, + Database Roles +
applicable, + applicable_roles +
enabled, + enabled_roles +
membership in, + Role Membership +
privilege to create, + Role Attributes +
privilege to initiate replication, + Role Attributes +
ROLLBACK, + ROLLBACK +
psql, + Variables +
ROLLBACK PREPARED, + ROLLBACK PREPARED +
ROLLBACK TO SAVEPOINT, + ROLLBACK TO SAVEPOINT +
round, + Mathematical Functions and Operators +
routine maintenance, + Routine Database Maintenance Tasks +
row, + Concepts, + Row Constructors, + Table Basics +
row estimation +
planner, + Row Estimation Examples +
row type, + Composite Types +
constructor, + Row Constructors +
row-wise comparison, + Row and Array Comparisons +
row_number, + Window Functions +
row_to_json, + JSON Functions +
rpad, + String Functions and Operators +
rtrim, + String Functions and Operators +
rule, + The Rule System +
and views, + Views and the Rule System +
for DELETE, + Rules on INSERT, UPDATE, and DELETE +
for INSERT, + Rules on INSERT, UPDATE, and DELETE +
for SELECT, + How SELECT Rules Work +
compared with triggers, + Rules Versus Triggers +
for UPDATE, + Rules on INSERT, UPDATE, and DELETE +

S

SAVEPOINT, + SAVEPOINT +
savepoints +
defining, + SAVEPOINT +
releasing, + RELEASE SAVEPOINT +
rolling back, + ROLLBACK TO SAVEPOINT +
scalar +
see expression
schema, + Schemas, + Overview +
creating, + Creating a Schema +
current, + The Schema Search Path, + System Information Functions +
public, + The Public Schema +
removing, + Creating a Schema +
SCO +
installation on, + SCO OpenServer and SCO UnixWare +
SCO OpenServer +
IPC configuration, + Shared Memory and Semaphores +
search path, + The Schema Search Path +
current, + System Information Functions +
search_path, + The Schema Search Path +
search_path configuration parameter, + Statement Behavior +
SECURITY LABEL, + SECURITY LABEL +
seg, + seg +
segment_size configuration parameter, + Preset Options +
SELECT, + Querying a Table, + Queries, + SELECT +
select list, + Select Lists +
SELECT INTO, + SELECT INTO +
in PL/pgSQL, + Executing a Query with a Single-row Result +
semaphores, + Shared Memory and Semaphores +
sepgsql, + sepgsql +
sepgsql.debug_audit configuration parameter, + GUC Parameters +
sepgsql.permissive configuration parameter, + GUC Parameters +
sequence, + Sequence Manipulation Functions +
and serial type, + Serial Types +
sequential scan, + Planner Method Configuration +
seq_page_cost configuration parameter, + Planner Cost Constants +
serial, + Serial Types +
serial2, + Serial Types +
serial4, + Serial Types +
serial8, + Serial Types +
serializable, + Serializable Isolation Level +
Serializable Snapshot Isolation, + Introduction +
serialization anomaly, + Serializable Isolation Level +
server log, + Error Reporting and Logging +
log file maintenance, + Log File Maintenance +
server spoofing, + Preventing Server Spoofing +
server_encoding configuration parameter, + Preset Options +
server_version configuration parameter, + Preset Options +
server_version_num configuration parameter, + Preset Options +
session_replication_role configuration parameter, + Statement Behavior +
session_user, + System Information Functions +
SET, + Configuration Settings Functions, + SET +
SET CONSTRAINTS, + SET CONSTRAINTS +
set difference, + Combining Queries +
set intersection, + Combining Queries +
set operation, + Combining Queries +
set returning functions +
functions, + Set Returning Functions +
SET ROLE, + SET ROLE +
SET SESSION AUTHORIZATION, + SET SESSION AUTHORIZATION +
SET TRANSACTION, + SET TRANSACTION +
set union, + Combining Queries +
SET XML OPTION, + Statement Behavior +
setseed, + Mathematical Functions and Operators +
setval, + Sequence Manipulation Functions +
setweight, + Text Search Functions and Operators, + Manipulating Documents +
set_bit, + Binary String Functions and Operators +
set_byte, + Binary String Functions and Operators +
set_config, + Configuration Settings Functions +
set_masklen, + Network Address Functions and Operators +
shared library, + Shared Libraries, + Compiling and Linking Dynamically-loaded Functions +
shared memory, + Shared Memory and Semaphores +
shared_buffers configuration parameter, + Memory +
shared_preload_libraries, + Shared Memory and LWLocks +
shared_preload_libraries configuration parameter, + Kernel Resource Usage +
SHMMAX, + Shared Memory and Semaphores +
shobj_description, + System Information Functions +
SHOW, + Configuration Settings Functions, + SHOW +
shutdown, + Shutting Down the Server +
SIGHUP, + Setting Parameters via the Configuration File, + The pg_hba.conf File, + User Name Maps +
SIGINT, + Shutting Down the Server +
sign, + Mathematical Functions and Operators +
signal +
backend processes, + Server Signalling Functions +
significant digits, + Locale and Formatting +
SIGQUIT, + Shutting Down the Server +
SIGTERM, + Shutting Down the Server +
SIMILAR TO, + SIMILAR TO Regular Expressions +
sin, + Mathematical Functions and Operators +
sleep, + Delaying Execution +
sliced bread +
see TOAST
smallint, + Integer Types +
smallserial, + Serial Types +
Solaris +
installation on, + Solaris +
IPC configuration, + Shared Memory and Semaphores +
shared library, + Compiling and Linking Dynamically-loaded Functions +
start script, + Starting the Database Server +
SOME, + Aggregate Functions, + Subquery Expressions, + Row and Array Comparisons +
sorting, + Sorting Rows +
SP-GiST +
see index
SPI, + Server Programming Interface +
examples, + spi +
SPI_connect, + SPI_connect +
SPI_copytuple, + SPI_copytuple +
SPI_cursor_close, + SPI_cursor_close +
in PL/Perl, + Database Access from PL/Perl +
SPI_cursor_fetch, + SPI_cursor_fetch +
SPI_cursor_find, + SPI_cursor_find +
SPI_cursor_move, + SPI_cursor_move +
SPI_cursor_open, + SPI_cursor_open +
SPI_cursor_open_with_args, + SPI_cursor_open_with_args +
SPI_cursor_open_with_paramlist, + SPI_cursor_open_with_paramlist +
SPI_exec, + SPI_exec +
SPI_execp, + SPI_execp +
SPI_execute, + SPI_execute +
SPI_execute_plan, + SPI_execute_plan +
SPI_execute_plan_with_paramlist, + SPI_execute_plan_with_paramlist +
SPI_execute_with_args, + SPI_execute_with_args +
spi_exec_prepared +
in PL/Perl, + Database Access from PL/Perl +
spi_exec_query +
in PL/Perl, + Database Access from PL/Perl +
spi_fetchrow +
in PL/Perl, + Database Access from PL/Perl +
SPI_finish, + SPI_finish +
SPI_fname, + SPI_fname +
SPI_fnumber, + SPI_fnumber +
SPI_freeplan, + SPI_freeplan +
in PL/Perl, + Database Access from PL/Perl +
SPI_freetuple, + SPI_freetuple +
SPI_freetuptable, + SPI_freetuptable +
SPI_getargcount, + SPI_getargcount +
SPI_getargtypeid, + SPI_getargtypeid +
SPI_getbinval, + SPI_getbinval +
SPI_getnspname, + SPI_getnspname +
SPI_getrelname, + SPI_getrelname +
SPI_gettype, + SPI_gettype +
SPI_gettypeid, + SPI_gettypeid +
SPI_getvalue, + SPI_getvalue +
SPI_is_cursor_plan, + SPI_is_cursor_plan +
SPI_keepplan, + SPI_keepplan +
spi_lastoid, + Database Access from PL/Tcl +
SPI_modifytuple, + SPI_modifytuple +
SPI_palloc, + SPI_palloc +
SPI_pfree, + SPI_pfree +
SPI_pop, + SPI_pop +
SPI_prepare, + SPI_prepare +
in PL/Perl, + Database Access from PL/Perl +
SPI_prepare_cursor, + SPI_prepare_cursor +
SPI_prepare_params, + SPI_prepare_params +
SPI_push, + SPI_push +
spi_query +
in PL/Perl, + Database Access from PL/Perl +
spi_query_prepared +
in PL/Perl, + Database Access from PL/Perl +
SPI_repalloc, + SPI_repalloc +
SPI_returntuple, + SPI_returntuple +
SPI_saveplan, + SPI_saveplan +
SPI_scroll_cursor_fetch, + SPI_scroll_cursor_fetch +
SPI_scroll_cursor_move, + SPI_scroll_cursor_move +
split_part, + String Functions and Operators +
SQL/CLI, + SQL Conformance +
SQL/Foundation, + SQL Conformance +
SQL/Framework, + SQL Conformance +
SQL/JRT, + SQL Conformance +
SQL/MED, + SQL Conformance +
SQL/OLB, + SQL Conformance +
SQL/PSM, + SQL Conformance +
SQL/Schemata, + SQL Conformance +
SQL/XML, + SQL Conformance +
sql_inheritance configuration parameter, + Previous PostgreSQL Versions +
sqrt, + Mathematical Functions and Operators +
ssh, + Secure TCP/IP Connections with SSH Tunnels +
SSI, + Introduction +
SSL, + Secure TCP/IP Connections with SSL, + SSL Support +
with libpq, + Parameter Key Words, + Connection Status Functions +
ssl configuration parameter, + Security and Authentication +
sslinfo, + sslinfo +
ssl_ca_file configuration parameter, + Security and Authentication +
ssl_cert_file configuration parameter, + Security and Authentication +
ssl_ciphers configuration parameter, + Security and Authentication +
ssl_crl_file configuration parameter, + Security and Authentication +
ssl_key_file configuration parameter, + Security and Authentication +
ssl_renegotiation_limit configuration parameter, + Security and Authentication +
SSPI, + SSPI Authentication +
STABLE, + Function Volatility Categories +
standard deviation, + Aggregate Functions +
population, + Aggregate Functions +
sample, + Aggregate Functions +
standard_conforming_strings configuration parameter, + Previous PostgreSQL Versions +
standby server, + High Availability, Load Balancing, and Replication +
standby_mode recovery parameter, + Standby Server Settings +
START TRANSACTION, + START TRANSACTION +
statement_timeout configuration parameter, + Statement Behavior +
statement_timestamp, + Date/Time Functions and Operators +
statistics, + Aggregate Functions, + The Statistics Collector +
of the planner, + Statistics Used by the Planner, + Updating Planner Statistics +
stats_temp_directory configuration parameter, + Query and Index Statistics Collector +
stddev, + Aggregate Functions +
stddev_pop, + Aggregate Functions +
stddev_samp, + Aggregate Functions +
STONITH, + High Availability, Load Balancing, and Replication +
storage parameters, + Storage Parameters +
Streaming Replication, + High Availability, Load Balancing, and Replication +
string +
see character string
strings +
backslash quotes, + Previous PostgreSQL Versions +
escape warning, + Previous PostgreSQL Versions +
standard conforming, + Previous PostgreSQL Versions +
string_agg, + Aggregate Functions +
string_to_array, + Array Functions and Operators +
strip, + Text Search Functions and Operators, + Manipulating Documents +
strpos, + String Functions and Operators +
subquery, + Aggregate Functions, + Scalar Subqueries, + Subqueries, + Subquery Expressions +
subscript, + Subscripts +
substr, + String Functions and Operators +
substring, + String Functions and Operators, + Binary String Functions and Operators, + SIMILAR TO Regular Expressions, + POSIX Regular Expressions +
sum, + Aggregate Functions +
superuser, + Accessing a Database, + Role Attributes +
superuser_reserved_connections configuration parameter, + Connection Settings +
suppress_redundant_updates_trigger, + Trigger Functions +
synchronize_seqscans configuration parameter, + Previous PostgreSQL Versions +
synchronous commit, + Asynchronous Commit +
Synchronous Replication, + High Availability, Load Balancing, and Replication +
synchronous_commit configuration parameter, + Settings +
synchronous_standby_names configuration parameter, + Master Server +
syntax +
SQL, + SQL Syntax +
syslog_facility configuration parameter, + Where To Log +
syslog_identity configuration parameter, + Where To Log +
system catalog +
schema, + The System Catalog Schema +

T

table, + Concepts, + Table Basics +
creating, + Table Basics +
inheritance, + Inheritance +
modifying, + Modifying Tables +
partitioning, + Partitioning +
removing, + Table Basics +
renaming, + Renaming a Table +
TABLE command, + SELECT +
table expression, + Table Expressions +
table function, + Table Functions +
tablefunc, + tablefunc +
tableoid, + System Columns +
tablespace, + Tablespaces +
default, + Statement Behavior +
temporary, + Statement Behavior +
tan, + Mathematical Functions and Operators +
target list, + The Query Tree +
Tcl, + PL/Tcl - Tcl Procedural Language +
tcn, + tcn +
tcp_keepalives_count configuration parameter, + Connection Settings +
tcp_keepalives_idle configuration parameter, + Connection Settings +
tcp_keepalives_interval configuration parameter, + Connection Settings +
template0, + Template Databases +
template1, + Creating a Database, + Template Databases +
temp_buffers configuration parameter, + Memory +
temp_file_limit configuration parameter, + Disk +
temp_tablespaces configuration parameter, + Statement Behavior +
test, + Regression Tests +
test_parser, + test_parser +
text, + Character Types, + Network Address Functions and Operators +
text search, + Full Text Search +
data types, + Text Search Types +
functions and operators, + Text Search Types +
indexes, + GiST and GIN Index Types +
threads +
with libpq, + Behavior in Threaded Programs +
tid, + Object Identifier Types +
time, + Date/Time Types, + Times +
constants, + Special Values +
current, + Current Date/Time +
output format, + Date/Time Output +
see also formatting
time span, + Date/Time Types +
time with time zone, + Date/Time Types, + Times +
time without time zone, + Date/Time Types, + Times +
time zone, + Time Zones, + Locale and Formatting +
conversion, + AT TIME ZONE +
input abbreviations, + Date/Time Configuration Files +
time zone data, + Installation Procedure +
time zone names, + Locale and Formatting +
timelines, + Backup and Restore +
timeofday, + Date/Time Functions and Operators +
timeout +
client authentication, + Security and Authentication +
deadlock, + Lock Management +
timestamp, + Date/Time Types, + Time Stamps +
timestamp with time zone, + Date/Time Types, + Time Stamps +
timestamp without time zone, + Date/Time Types, + Time Stamps +
timestamptz, + Date/Time Types +
TimeZone configuration parameter, + Locale and Formatting +
timezone_abbreviations configuration parameter, + Locale and Formatting +
TOAST, + TOAST +
and user-defined types, + User-defined Types +
per-column storage settings, + Description +
versus large objects, + Introduction +
token, + Lexical Structure +
to_ascii, + String Functions and Operators +
to_char, + Data Type Formatting Functions +
and locales, + Behavior +
to_date, + Data Type Formatting Functions +
to_hex, + String Functions and Operators +
to_number, + Data Type Formatting Functions +
to_timestamp, + Data Type Formatting Functions +
to_tsquery, + Text Search Functions and Operators, + Parsing Queries +
to_tsvector, + Text Search Functions and Operators, + Parsing Documents +
trace_locks configuration parameter, + Developer Options +
trace_lock_oidmin configuration parameter, + Developer Options +
trace_lock_table configuration parameter, + Developer Options +
trace_lwlocks configuration parameter, + Developer Options +
trace_notify configuration parameter, + Developer Options +
trace_recovery_messages configuration parameter, + Developer Options +
trace_sort configuration parameter, + Developer Options +
trace_userlocks configuration parameter, + Developer Options +
track_activities configuration parameter, + Query and Index Statistics Collector +
track_activity_query_size configuration parameter, + Query and Index Statistics Collector +
track_counts configuration parameter, + Query and Index Statistics Collector +
track_functions configuration parameter, + Query and Index Statistics Collector +
track_io_timing configuration parameter, + Query and Index Statistics Collector +
transaction, + Transactions +
transaction ID +
wraparound, + Preventing Transaction ID Wraparound Failures +
transaction isolation, + Transaction Isolation +
transaction isolation level, + Transaction Isolation +
read committed, + Read Committed Isolation Level +
repeatable read, + Repeatable Read Isolation Level +
serializable, + Serializable Isolation Level +
setting, + SET TRANSACTION +
setting default, + Statement Behavior +
transaction log +
see WAL
transaction_timestamp, + Date/Time Functions and Operators +
transform_null_equals configuration parameter, + Platform and Client Compatibility +
translate, + String Functions and Operators +
trigger, + Pseudo-Types, + Triggers +
arguments for trigger functions, + Overview of Trigger Behavior +
for updating a derived tsvector column, + Triggers for Automatic Updates +
in C, + Writing Trigger Functions in C +
in PL/pgSQL, + Trigger Procedures +
in PL/Python, + Trigger Functions +
in PL/Tcl, + Trigger Procedures in PL/Tcl +
compared with rules, + Rules Versus Triggers +
triggered_change_notification, + tcn +
trigger_file recovery parameter, + Standby Server Settings +
trim, + String Functions and Operators, + Binary String Functions and Operators +
Tru64 UNIX +
shared library, + Compiling and Linking Dynamically-loaded Functions +
true, + Boolean Type +
trunc, + Mathematical Functions and Operators, + Network Address Functions and Operators +
TRUNCATE, + TRUNCATE +
trusted +
PL/Perl, + Trusted and Untrusted PL/Perl +
tsearch2, + tsearch2 +
tsquery (data type), + tsquery +
tsvector (data type), + tsvector +
tsvector concatenation, + Manipulating Documents +
tsvector_update_trigger, + Text Search Functions and Operators +
tsvector_update_trigger_column, + Text Search Functions and Operators +
ts_debug, + Text Search Functions and Operators, + Configuration Testing +
ts_headline, + Text Search Functions and Operators, + Highlighting Results +
ts_lexize, + Text Search Functions and Operators, + Dictionary Testing +
ts_parse, + Text Search Functions and Operators, + Parser Testing +
ts_rank, + Text Search Functions and Operators, + Ranking Search Results +
ts_rank_cd, + Text Search Functions and Operators, + Ranking Search Results +
ts_rewrite, + Text Search Functions and Operators, + Query Rewriting +
ts_stat, + Text Search Functions and Operators, + Gathering Document Statistics +
ts_token_type, + Text Search Functions and Operators, + Parser Testing +
txid_current, + System Information Functions +
txid_current_snapshot, + System Information Functions +
txid_snapshot_xip, + System Information Functions +
txid_snapshot_xmax, + System Information Functions +
txid_snapshot_xmin, + System Information Functions +
txid_visible_in_snapshot, + System Information Functions +
type +
see data type
polymorphic, + Polymorphic Types +
type cast, + Numeric Constants, + Type Casts +

U

UESCAPE, + Identifiers and Key Words, + String Constants with Unicode Escapes +
unaccent, + unaccent, + Functions +
Unicode escape +
in identifiers, + Identifiers and Key Words +
in string constants, + String Constants with Unicode Escapes +
UNION, + Combining Queries +
determination of result type, + UNION, CASE, and Related Constructs +
unique constraint, + Unique Constraints +
Unix domain socket, + Parameter Key Words +
UnixWare +
installation on, + SCO OpenServer and SCO UnixWare +
IPC configuration, + Shared Memory and Semaphores +
shared library, + Compiling and Linking Dynamically-loaded Functions +
unix_socket_directory configuration parameter, + Connection Settings +
unix_socket_group configuration parameter, + Connection Settings +
unix_socket_permissions configuration parameter, + Connection Settings +
UNLISTEN, + UNLISTEN +
unnest, + Array Functions and Operators +
unqualified name, + The Schema Search Path +
UPDATE, + Updates, + Updating Data, + UPDATE +
update_process_title configuration parameter, + Query and Index Statistics Collector +
updating, + Updating Data +
upgrading, + Upgrading a PostgreSQL Cluster +
upper, + String Functions and Operators, + Range Functions and Operators +
and locales, + Behavior +
upper_inc, + Range Functions and Operators +
upper_inf, + Range Functions and Operators +
URI, + Connection Strings +
user, + System Information Functions, + Database Roles +
current, + System Information Functions +
user mapping, + Foreign Data +
User name maps, + User Name Maps +
UUID, + UUID Type, + Installation Procedure +
uuid-ossp, + uuid-ossp +

V

vacuum, + Routine Vacuuming, + VACUUM +
vacuumdb, + vacuumdb +
vacuumlo, + vacuumlo +
vacuum_cost_delay configuration parameter, + Cost-based Vacuum Delay +
vacuum_cost_limit configuration parameter, + Cost-based Vacuum Delay +
vacuum_cost_page_dirty configuration parameter, + Cost-based Vacuum Delay +
vacuum_cost_page_hit configuration parameter, + Cost-based Vacuum Delay +
vacuum_cost_page_miss configuration parameter, + Cost-based Vacuum Delay +
vacuum_defer_cleanup_age configuration parameter, + Master Server +
vacuum_freeze_min_age configuration parameter, + Statement Behavior +
vacuum_freeze_table_age configuration parameter, + Statement Behavior +
value expression, + Value Expressions +
VALUES, + VALUES Lists, + VALUES +
determination of result type, + UNION, CASE, and Related Constructs +
varchar, + Character Types +
variadic function, + SQL Functions with Variable Numbers of Arguments +
variance, + Aggregate Functions +
population, + Aggregate Functions +
sample, + Aggregate Functions +
var_pop, + Aggregate Functions +
var_samp, + Aggregate Functions +
version, + Accessing a Database, + System Information Functions +
compatibility, + Upgrading a PostgreSQL Cluster +
view, + Views +
implementation through rules, + Views and the Rule System +
updating, + Cooperation with Views +
Visibility Map, + Visibility Map +
VM +
see Visibility Map
void, + Pseudo-Types +
VOLATILE, + Function Volatility Categories +
volatility +
functions, + Function Volatility Categories +
VPATH, + Installation Procedure +

W

WAL, + Reliability and the Write-Ahead Log +
wal_block_size configuration parameter, + Preset Options +
wal_buffers configuration parameter, + Settings +
wal_debug configuration parameter, + Developer Options +
wal_keep_segments configuration parameter, + Sending Server(s) +
wal_level configuration parameter, + Settings +
wal_receiver_status_interval configuration parameter, + Standby Servers +
wal_segment_size configuration parameter, + Preset Options +
wal_sync_method configuration parameter, + Settings +
wal_writer_delay configuration parameter, + Settings +
warm standby, + High Availability, Load Balancing, and Replication +
WHERE, + The WHERE Clause +
where to log, + Where To Log +
WHILE +
in PL/pgSQL, + WHILE +
width, + Geometric Functions and Operators +
width_bucket, + Mathematical Functions and Operators +
window function, + Window Functions +
built-in, + Window Functions +
invocation, + Window Function Calls +
order of execution, + Window Function Processing +
WITH +
in SELECT, + WITH Queries (Common Table Expressions), + SELECT +
witness server, + High Availability, Load Balancing, and Replication +
work_mem configuration parameter, + Memory +

X

xid, + Object Identifier Types +
xmax, + System Columns +
xmin, + System Columns +
XML, + XML Type +
XML export, + Mapping Tables to XML +
XML option, + Creating XML Values, + Statement Behavior +
xml2, + xml2 +
xmlagg, + xmlagg, + Aggregate Functions +
xmlbinary configuration parameter, + Statement Behavior +
xmlcomment, + xmlcomment +
xmlconcat, + xmlconcat +
xmlelement, + xmlelement +
XMLEXISTS, + XMLEXISTS +
xmlforest, + xmlforest +
xmloption configuration parameter, + Statement Behavior +
xmlparse, + Creating XML Values +
xmlpi, + xmlpi +
xmlroot, + xmlroot +
xmlserialize, + Creating XML Values +
xml_is_well_formed, + xml_is_well_formed +
xml_is_well_formed_content, + xml_is_well_formed +
xml_is_well_formed_document, + xml_is_well_formed +
XPath, + Processing XML +
xpath_exists, + Processing XML +

Y

yacc, + Requirements +

Z

zero_damaged_pages configuration parameter, + Developer Options +
zlib, + Requirements, + Installation Procedure +

PrevHome 
Bibliography  
\ No newline at end of file diff --git a/doc/src/sgml/html/btree-gin.html b/doc/src/sgml/html/btree-gin.html new file mode 100644 index 000000000..66e40da7d --- /dev/null +++ b/doc/src/sgml/html/btree-gin.html @@ -0,0 +1,300 @@ + +btree_gin
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.4. btree_gin

btree_gin provides sample GIN operator classes that + implement B-tree equivalent behavior for the data types + int2, int4, int8, float4, + float8, timestamp with time zone, + timestamp without time zone, time with time zone, + time without time zone, date, interval, + oid, money, "char", + varchar, text, bytea, bit, + varbit, macaddr, inet, and cidr. +

In general, these operator classes will not outperform the equivalent + standard B-tree index methods, and they lack one major feature of the + standard B-tree code: the ability to enforce uniqueness. However, + they are useful for GIN testing and as a base for developing other + GIN operator classes. Also, for queries that test both a GIN-indexable + column and a B-tree-indexable column, it might be more efficient to create + a multicolumn GIN index that uses one of these operator classes than to create + two separate indexes that would have to be combined via bitmap ANDing. +

F.4.1. Example Usage

CREATE TABLE test (a int4);
+-- create index
+CREATE INDEX testidx ON test USING gin (a);
+-- query
+SELECT * FROM test WHERE a < 10;

F.4.2. Authors

Teodor Sigaev (<teodor@stack.net>) and + Oleg Bartunov (<oleg@sai.msu.su>). See + http://www.sai.msu.su/~megera/oddmuse/index.cgi/Gin + for additional information. +


PrevHomeNext
auto_explainUpbtree_gist
\ No newline at end of file diff --git a/doc/src/sgml/html/btree-gist.html b/doc/src/sgml/html/btree-gist.html new file mode 100644 index 000000000..eb290fcd6 --- /dev/null +++ b/doc/src/sgml/html/btree-gist.html @@ -0,0 +1,419 @@ + +btree_gist
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.5. btree_gist

btree_gist provides GiST index operator classes that + implement B-tree equivalent behavior for the data types + int2, int4, int8, float4, + float8, numeric, timestamp with time zone, + timestamp without time zone, time with time zone, + time without time zone, date, interval, + oid, money, char, + varchar, text, bytea, bit, + varbit, macaddr, inet, and cidr. +

In general, these operator classes will not outperform the equivalent + standard B-tree index methods, and they lack one major feature of the + standard B-tree code: the ability to enforce uniqueness. However, + they provide some other features that are not available with a B-tree + index, as described below. Also, these operator classes are useful + when a multicolumn GiST index is needed, wherein some of the columns + are of data types that are only indexable with GiST but other columns + are just simple data types. Lastly, these operator classes are useful for + GiST testing and as a base for developing other GiST operator classes. +

In addition to the typical B-tree search operators, btree_gist + also provides index support for <> ("not + equals"). This may be useful in combination with an + exclusion constraint, + as described below. +

Also, for data types for which there is a natural distance metric, + btree_gist defines a distance operator <->, + and provides GiST index support for nearest-neighbor searches using + this operator. Distance operators are provided for + int2, int4, int8, float4, + float8, timestamp with time zone, + timestamp without time zone, + time without time zone, date, interval, + oid, and money. +

F.5.1. Example Usage

Simple example using btree_gist instead of btree: +

CREATE TABLE test (a int4);
+-- create index
+CREATE INDEX testidx ON test USING gist (a);
+-- query
+SELECT * FROM test WHERE a < 10;
+-- nearest-neighbor search: find the ten entries closest to "42"
+SELECT *, a <-> 42 AS dist FROM test ORDER BY a <-> 42 LIMIT 10;

Use an exclusion + constraint to enforce the rule that a cage at a zoo + can contain only one kind of animal: +

=> CREATE TABLE zoo (
+  cage   INTEGER,
+  animal TEXT,
+  EXCLUDE USING gist (cage WITH =, animal WITH <>)
+);
+
+=> INSERT INTO zoo VALUES(123, 'zebra');
+INSERT 0 1
+=> INSERT INTO zoo VALUES(123, 'zebra');
+INSERT 0 1
+=> INSERT INTO zoo VALUES(123, 'lion');
+ERROR:  conflicting key value violates exclusion constraint "zoo_cage_animal_excl"
+DETAIL:  Key (cage, animal)=(123, lion) conflicts with existing key (cage, animal)=(123, zebra).
+=> INSERT INTO zoo VALUES(124, 'lion');
+INSERT 0 1

F.5.2. Authors

Teodor Sigaev (<teodor@stack.net>) , + Oleg Bartunov (<oleg@sai.msu.su>), and + Janko Richter (<jankorichter@yahoo.de>). See + http://www.sai.msu.su/~megera/postgres/gist/ + for additional information. +


PrevHomeNext
btree_ginUpchkpass
\ No newline at end of file diff --git a/doc/src/sgml/html/bug-reporting.html b/doc/src/sgml/html/bug-reporting.html new file mode 100644 index 000000000..67a056efd --- /dev/null +++ b/doc/src/sgml/html/bug-reporting.html @@ -0,0 +1,753 @@ + +Bug Reporting Guidelines

Bug Reporting Guidelines

When you find a bug in PostgreSQL we want to + hear about it. Your bug reports play an important part in making + PostgreSQL more reliable because even the utmost + care cannot guarantee that every part of + PostgreSQL + will work on every platform under every circumstance. +

The following suggestions are intended to assist you in forming bug reports + that can be handled in an effective fashion. No one is required to follow + them but doing so tends to be to everyone's advantage. +

We cannot promise to fix every bug right away. If the bug is obvious, critical, + or affects a lot of users, chances are good that someone will look into it. It + could also happen that we tell you to update to a newer version to see if the + bug happens there. Or we might decide that the bug + cannot be fixed before some major rewrite we might be planning is done. Or + perhaps it is simply too hard and there are more important things on the agenda. + If you need help immediately, consider obtaining a commercial support contract. +

Identifying Bugs

Before you report a bug, please read and re-read the + documentation to verify that you can really do whatever it is you are + trying. If it is not clear from the documentation whether you can do + something or not, please report that too; it is a bug in the documentation. + If it turns out that a program does something different from what the + documentation says, that is a bug. That might include, but is not limited to, + the following circumstances: + +

  • A program terminates with a fatal signal or an operating system + error message that would point to a problem in the program. (A + counterexample might be a "disk full" message, + since you have to fix that yourself.) +

  • A program produces the wrong output for any given input. +

  • A program refuses to accept valid input (as defined in the documentation). +

  • A program accepts invalid input without a notice or error message. + But keep in mind that your idea of invalid input might be our idea of + an extension or compatibility with traditional practice. +

  • PostgreSQL fails to compile, build, or + install according to the instructions on supported platforms. +

+ + Here "program" refers to any executable, not only the backend process. +

Being slow or resource-hogging is not necessarily a bug. Read the + documentation or ask on one of the mailing lists for help in tuning your + applications. Failing to comply to the SQL standard is + not necessarily a bug either, unless compliance for the + specific feature is explicitly claimed. +

Before you continue, check on the TODO list and in the FAQ to see if your bug is + already known. If you cannot decode the information on the TODO list, report your + problem. The least we can do is make the TODO list clearer. +

What to Report

The most important thing to remember about bug reporting is to state all + the facts and only facts. Do not speculate what you think went wrong, what + "it seemed to do", or which part of the program has a fault. + If you are not familiar with the implementation you would probably guess + wrong and not help us a bit. And even if you are, educated explanations are + a great supplement to but no substitute for facts. If we are going to fix + the bug we still have to see it happen for ourselves first. + Reporting the bare facts + is relatively straightforward (you can probably copy and paste them from the + screen) but all too often important details are left out because someone + thought it does not matter or the report would be understood + anyway. +

The following items should be contained in every bug report: + +

  • The exact sequence of steps from program + start-up necessary to reproduce the problem. This + should be self-contained; it is not enough to send in a bare + SELECT statement without the preceding + CREATE TABLE and INSERT + statements, if the output should depend on the data in the + tables. We do not have the time to reverse-engineer your + database schema, and if we are supposed to make up our own data + we would probably miss the problem. +

    The best format for a test case for SQL-related problems is a + file that can be run through the psql + frontend that shows the problem. (Be sure to not have anything + in your ~/.psqlrc start-up file.) An easy + way to create this file is to use pg_dump + to dump out the table declarations and data needed to set the + scene, then add the problem query. You are encouraged to + minimize the size of your example, but this is not absolutely + necessary. If the bug is reproducible, we will find it either + way. +

    If your application uses some other client interface, such as PHP, then + please try to isolate the offending queries. We will probably not set up a + web server to reproduce your problem. In any case remember to provide + the exact input files; do not guess that the problem happens for + "large files" or "midsize databases", etc. since this + information is too inexact to be of use. +

  • The output you got. Please do not say that it "didn't work" or + "crashed". If there is an error message, + show it, even if you do not understand it. If the program terminates with + an operating system error, say which. If nothing at all happens, say so. + Even if the result of your test case is a program crash or otherwise obvious + it might not happen on our platform. The easiest thing is to copy the output + from the terminal, if possible. +

    Note: If you are reporting an error message, please obtain the most verbose + form of the message. In psql, say \set + VERBOSITY verbose beforehand. If you are extracting the message + from the server log, set the run-time parameter + log_error_verbosity to verbose so that all + details are logged. +

    Note: In case of fatal errors, the error message reported by the client might + not contain all the information available. Please also look at the + log output of the database server. If you do not keep your server's log + output, this would be a good time to start doing so. +

  • The output you expected is very important to state. If you just write + "This command gives me that output." or "This is not + what I expected.", we might run it ourselves, scan the output, and + think it looks OK and is exactly what we expected. We should not have to + spend the time to decode the exact semantics behind your commands. + Especially refrain from merely saying that "This is not what SQL says/Oracle + does." Digging out the correct behavior from SQL + is not a fun undertaking, nor do we all know how all the other relational + databases out there behave. (If your problem is a program crash, you can + obviously omit this item.) +

  • Any command line options and other start-up options, including + any relevant environment variables or configuration files that + you changed from the default. Again, please provide exact + information. If you are using a prepackaged distribution that + starts the database server at boot time, you should try to find + out how that is done. +

  • Anything you did at all differently from the installation + instructions. +

  • The PostgreSQL version. You can run the command + SELECT version(); to + find out the version of the server you are connected to. Most executable + programs also support a --version option; at least + postgres --version and psql --version + should work. + If the function or the options do not exist then your version is + more than old enough to warrant an upgrade. + If you run a prepackaged version, such as RPMs, say so, including any + subversion the package might have. If you are talking about a Git + snapshot, mention that, including the commit hash. +

    If your version is older than 9.2.2 we will almost certainly + tell you to upgrade. There are many bug fixes and improvements + in each new release, so it is quite possible that a bug you have + encountered in an older release of PostgreSQL + has already been fixed. We can only provide limited support for + sites using older releases of PostgreSQL; if you + require more than we can provide, consider acquiring a + commercial support contract. +

  • Platform information. This includes the kernel name and version, + C library, processor, memory information, and so on. In most + cases it is sufficient to report the vendor and version, but do + not assume everyone knows what exactly "Debian" + contains or that everyone runs on i386s. If you have + installation problems then information about the toolchain on + your machine (compiler, make, and so + on) is also necessary. +

+ + Do not be afraid if your bug report becomes rather lengthy. That is a fact of life. + It is better to report everything the first time than us having to squeeze the + facts out of you. On the other hand, if your input files are huge, it is + fair to ask first whether somebody is interested in looking into it. Here is + an article + that outlines some more tips on reporting bugs. +

Do not spend all your time to figure out which changes in the input make + the problem go away. This will probably not help solving it. If it turns + out that the bug cannot be fixed right away, you will still have time to + find and share your work-around. Also, once again, do not waste your time + guessing why the bug exists. We will find that out soon enough. +

When writing a bug report, please avoid confusing terminology. + The software package in total is called "PostgreSQL", + sometimes "Postgres" for short. If you + are specifically talking about the backend process, mention that, do not + just say "PostgreSQL crashes". A crash of a single + backend process is quite different from crash of the parent + "postgres" process; please don't say "the server + crashed" when you mean a single backend process went down, nor vice versa. + Also, client programs such as the interactive frontend "psql" + are completely separate from the backend. Please try to be specific + about whether the problem is on the client or server side. +

Where to Report Bugs

In general, send bug reports to the bug report mailing list at + <pgsql-bugs@postgresql.org>. + You are requested to use a descriptive subject for your email + message, perhaps parts of the error message. +

Another method is to fill in the bug report web-form available + at the project's + web site. + Entering a bug report this way causes it to be mailed to the + <pgsql-bugs@postgresql.org> mailing list. +

If your bug report has security implications and you'd prefer that it + not become immediately visible in public archives, don't send it to + pgsql-bugs. Security issues can be + reported privately to <security@postgresql.org>. +

Do not send bug reports to any of the user mailing lists, such as + <pgsql-sql@postgresql.org> or + <pgsql-general@postgresql.org>. + These mailing lists are for answering + user questions, and their subscribers normally do not wish to receive + bug reports. More importantly, they are unlikely to fix them. +

Also, please do not send reports to + the developers' mailing list <pgsql-hackers@postgresql.org>. + This list is for discussing the + development of PostgreSQL, and it would be nice + if we could keep the bug reports separate. We might choose to take up a + discussion about your bug report on pgsql-hackers, + if the problem needs more review. +

If you have a problem with the documentation, the best place to report it + is the documentation mailing list <pgsql-docs@postgresql.org>. + Please be specific about what part of the documentation you are unhappy + with. +

If your bug is a portability problem on a non-supported platform, + send mail to <pgsql-hackers@postgresql.org>, + so we (and you) can work on + porting PostgreSQL to your platform. +

Note: Due to the unfortunate amount of spam going around, all of the above + email addresses are closed mailing lists. That is, you need to be + subscribed to a list to be allowed to post on it. (You need not be + subscribed to use the bug-report web form, however.) + If you would like to send mail but do not want to receive list traffic, + you can subscribe and set your subscription option to nomail. + For more information send mail to + <majordomo@postgresql.org> + with the single word help in the body of the message. +


PrevHomeNext
Further InformationUpTutorial
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-aggregate.html b/doc/src/sgml/html/catalog-pg-aggregate.html new file mode 100644 index 000000000..d2bf07c6a --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-aggregate.html @@ -0,0 +1,394 @@ + +pg_aggregate
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.2. pg_aggregate

The catalog pg_aggregate stores information about + aggregate functions. An aggregate function is a function that + operates on a set of values (typically one column from each row + that matches a query condition) and returns a single value computed + from all these values. Typical aggregate functions are + sum, count, and + max. Each entry in + pg_aggregate is an extension of an entry + in pg_proc. The pg_proc + entry carries the aggregate's name, input and output data types, and + other information that is similar to ordinary functions. +

Table 45-2. pg_aggregate Columns

NameTypeReferencesDescription
aggfnoidregprocpg_proc.oidpg_proc OID of the aggregate function
aggtransfnregprocpg_proc.oidTransition function
aggfinalfnregprocpg_proc.oidFinal function (zero if none)
aggsortopoidpg_operator.oidAssociated sort operator (zero if none)
aggtranstypeoidpg_type.oidData type of the aggregate function's internal transition (state) data
agginitvaltext  The initial value of the transition state. This is a text + field containing the initial value in its external string + representation. If this field is null, the transition state + value starts out null. +

New aggregate functions are registered with the CREATE AGGREGATE + command. See Section 35.10 for more information about + writing aggregate functions and the meaning of the transition + functions, etc. +


PrevHomeNext
OverviewUppg_am
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-am.html b/doc/src/sgml/html/catalog-pg-am.html new file mode 100644 index 000000000..db1aed5fa --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-am.html @@ -0,0 +1,890 @@ + +pg_am
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.3. pg_am

The catalog pg_am stores information about index + access methods. There is one row for each index access method supported by + the system. The contents of this catalog are discussed in detail in + Chapter 52. +

Table 45-3. pg_am Columns

NameTypeReferencesDescription
amnamename Name of the access method
amstrategiesint2 Number of operator strategies for this access method, + or zero if access method does not have a fixed set of operator + strategies
amsupportint2 Number of support routines for this access method
amcanorderbool Does the access method support ordered scans sorted by the + indexed column's value?
amcanorderbyopbool Does the access method support ordered scans sorted by the result + of an operator on the indexed column?
amcanbackwardbool Does the access method support backward scanning?
amcanuniquebool Does the access method support unique indexes?
amcanmulticolbool Does the access method support multicolumn indexes?
amoptionalkeybool Does the access method support a scan without any constraint + for the first index column?
amsearcharraybool Does the access method support ScalarArrayOpExpr searches?
amsearchnullsbool Does the access method support IS NULL/NOT NULL searches?
amstoragebool Can index storage data type differ from column data type?
amclusterablebool Can an index of this type be clustered on?
ampredlocksbool Does an index of this type manage fine-grained predicate locks?
amkeytypeoidpg_type.oidType of data stored in index, or zero if not a fixed type
aminsertregprocpg_proc.oid"Insert this tuple" function
ambeginscanregprocpg_proc.oid"Prepare for index scan" function
amgettupleregprocpg_proc.oid"Next valid tuple" function, or zero if none
amgetbitmapregprocpg_proc.oid"Fetch all valid tuples" function, or zero if none
amrescanregprocpg_proc.oid"(Re)start index scan" function
amendscanregprocpg_proc.oid"Clean up after index scan" function
ammarkposregprocpg_proc.oid"Mark current scan position" function
amrestrposregprocpg_proc.oid"Restore marked scan position" function
ambuildregprocpg_proc.oid"Build new index" function
ambuildemptyregprocpg_proc.oid"Build empty index" function
ambulkdeleteregprocpg_proc.oidBulk-delete function
amvacuumcleanupregprocpg_proc.oidPost-VACUUM cleanup function
amcanreturnregprocpg_proc.oidFunction to check whether index supports index-only scans, + or zero if none
amcostestimateregprocpg_proc.oidFunction to estimate cost of an index scan
amoptionsregprocpg_proc.oidFunction to parse and validate reloptions for an index

PrevHomeNext
pg_aggregateUppg_amop
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-amop.html b/doc/src/sgml/html/catalog-pg-amop.html new file mode 100644 index 000000000..c54adb9a1 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-amop.html @@ -0,0 +1,534 @@ + +pg_amop
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.4. pg_amop

The catalog pg_amop stores information about + operators associated with access method operator families. There is one + row for each operator that is a member of an operator family. A family + member can be either a search operator or an + ordering operator. An operator + can appear in more than one family, but cannot appear in more than one + search position nor more than one ordering position within a family. + (It is allowed, though unlikely, for an operator to be used for both + search and ordering purposes.) +

Table 45-4. pg_amop Columns

NameTypeReferencesDescription
amopfamilyoidpg_opfamily.oidThe operator family this entry is for
amoplefttypeoidpg_type.oidLeft-hand input data type of operator
amoprighttypeoidpg_type.oidRight-hand input data type of operator
amopstrategyint2 Operator strategy number
amoppurposechar Operator purpose, either s for search or + o for ordering
amopoproidpg_operator.oidOID of the operator
amopmethodoidpg_am.oidIndex access method operator family is for
amopsortfamilyoidpg_opfamily.oidThe btree operator family this entry sorts according to, if an + ordering operator; zero if a search operator

A "search" operator entry indicates that an index of this operator + family can be searched to find all rows satisfying + WHERE + indexed_column + operator + constant. + Obviously, such an operator must return boolean, and its left-hand input + type must match the index's column data type. +

An "ordering" operator entry indicates that an index of this + operator family can be scanned to return rows in the order represented by + ORDER BY + indexed_column + operator + constant. + Such an operator could return any sortable data type, though again + its left-hand input type must match the index's column data type. + The exact semantics of the ORDER BY are specified by the + amopsortfamily column, which must reference + a btree operator family for the operator's result type. +

Note: At present, it's assumed that the sort order for an ordering operator + is the default for the referenced opfamily, i.e., ASC NULLS + LAST. This might someday be relaxed by adding additional columns + to specify sort options explicitly. +

An entry's amopmethod must match the + opfmethod of its containing operator family (including + amopmethod here is an intentional denormalization of the + catalog structure for performance reasons). Also, + amoplefttype and amoprighttype must match + the oprleft and oprright fields of the + referenced pg_operator entry. +


PrevHomeNext
pg_amUppg_amproc
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-amproc.html b/doc/src/sgml/html/catalog-pg-amproc.html new file mode 100644 index 000000000..c6d4e111d --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-amproc.html @@ -0,0 +1,356 @@ + +pg_amproc
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.5. pg_amproc

The catalog pg_amproc stores information about + support procedures associated with access method operator families. There + is one row for each support procedure belonging to an operator family. +

Table 45-5. pg_amproc Columns

NameTypeReferencesDescription
amprocfamilyoidpg_opfamily.oidThe operator family this entry is for
amproclefttypeoidpg_type.oidLeft-hand input data type of associated operator
amprocrighttypeoidpg_type.oidRight-hand input data type of associated operator
amprocnumint2 Support procedure number
amprocregprocpg_proc.oidOID of the procedure

The usual interpretation of the + amproclefttype and amprocrighttype fields + is that they identify the left and right input types of the operator(s) + that a particular support procedure supports. For some access methods + these match the input data type(s) of the support procedure itself, for + others not. There is a notion of "default" support procedures for + an index, which are those with amproclefttype and + amprocrighttype both equal to the index opclass's + opcintype. +


PrevHomeNext
pg_amopUppg_attrdef
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-attrdef.html b/doc/src/sgml/html/catalog-pg-attrdef.html new file mode 100644 index 000000000..a5ee1c2d7 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-attrdef.html @@ -0,0 +1,314 @@ + +pg_attrdef
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.6. pg_attrdef

The catalog pg_attrdef stores column default values. The main information + about columns is stored in pg_attribute + (see below). Only columns that explicitly specify a default value + (when the table is created or the column is added) will have an + entry here. +

Table 45-6. pg_attrdef Columns

NameTypeReferencesDescription
adrelidoidpg_class.oidThe table this column belongs to
adnumint2pg_attribute.attnumThe number of the column
adbinpg_node_tree The internal representation of the column default value
adsrctext A human-readable representation of the default value

The adsrc field is historical, and is best + not used, because it does not track outside changes that might affect + the representation of the default value. Reverse-compiling the + adbin field (with pg_get_expr for + example) is a better way to display the default value. +


PrevHomeNext
pg_amprocUppg_attribute
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-attribute.html b/doc/src/sgml/html/catalog-pg-attribute.html new file mode 100644 index 000000000..1eabe243a --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-attribute.html @@ -0,0 +1,711 @@ + +pg_attribute
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.7. pg_attribute

The catalog pg_attribute stores information about + table columns. There will be exactly one + pg_attribute row for every column in every + table in the database. (There will also be attribute entries for + indexes, and indeed all objects that have pg_class + entries.) +

The term attribute is equivalent to column and is used for + historical reasons. +

Table 45-7. pg_attribute Columns

NameTypeReferencesDescription
attrelidoidpg_class.oidThe table this column belongs to
attnamename The column name
atttypidoidpg_type.oidThe data type of this column
attstattargetint4  attstattarget controls the level of detail + of statistics accumulated for this column by + ANALYZE. + A zero value indicates that no statistics should be collected. + A negative value says to use the system default statistics target. + The exact meaning of positive values is data type-dependent. + For scalar data types, attstattarget + is both the target number of "most common values" + to collect, and the target number of histogram bins to create. +
attlenint2  A copy of pg_type.typlen of this column's + type +
attnumint2  The number of the column. Ordinary columns are numbered from 1 + up. System columns, such as oid, + have (arbitrary) negative numbers. +
attndimsint4  Number of dimensions, if the column is an array type; otherwise 0. + (Presently, the number of dimensions of an array is not enforced, + so any nonzero value effectively means "it's an array".) +
attcacheoffint4  Always -1 in storage, but when loaded into a row descriptor + in memory this might be updated to cache the offset of the attribute + within the row +
atttypmodint4  atttypmod records type-specific data + supplied at table creation time (for example, the maximum + length of a varchar column). It is passed to + type-specific input functions and length coercion functions. + The value will generally be -1 for types that do not need atttypmod. +
attbyvalbool  A copy of pg_type.typbyval of this column's type +
attstoragechar  Normally a copy of pg_type.typstorage of this + column's type. For TOAST-able data types, this can be altered + after column creation to control storage policy. +
attalignchar  A copy of pg_type.typalign of this column's type +
attnotnullbool  This represents a not-null constraint. It is possible to + change this column to enable or disable the constraint. +
atthasdefbool  This column has a default value, in which case there will be a + corresponding entry in the pg_attrdef + catalog that actually defines the value. +
attisdroppedbool  This column has been dropped and is no longer valid. A dropped + column is still physically present in the table, but is + ignored by the parser and so cannot be accessed via SQL. +
attislocalbool  This column is defined locally in the relation. Note that a column can + be locally defined and inherited simultaneously. +
attinhcountint4  The number of direct ancestors this column has. A column with a + nonzero number of ancestors cannot be dropped nor renamed. +
attcollationoidpg_collation.oid The defined collation of the column, or zero if the column is + not of a collatable data type. +
attaclaclitem[]  Column-level access privileges, if any have been granted specifically + on this column +
attoptionstext[]  Attribute-level options, as "keyword=value" strings +
attfdwoptionstext[]  Attribute-level foreign data wrapper options, as "keyword=value" strings +

In a dropped column's pg_attribute entry, + atttypid is reset to zero, but + attlen and the other fields copied from + pg_type are still valid. This arrangement is needed + to cope with the situation where the dropped column's data type was + later dropped, and so there is no pg_type row anymore. + attlen and the other fields can be used + to interpret the contents of a row of the table. +


PrevHomeNext
pg_attrdefUppg_authid
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-auth-members.html b/doc/src/sgml/html/catalog-pg-auth-members.html new file mode 100644 index 000000000..fa26cc2fd --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-auth-members.html @@ -0,0 +1,324 @@ + +pg_auth_members
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.9. pg_auth_members

The catalog pg_auth_members shows the membership + relations between roles. Any non-circular set of relationships is allowed. +

Because user identities are cluster-wide, + pg_auth_members + is shared across all databases of a cluster: there is only one + copy of pg_auth_members per cluster, not + one per database. +

Table 45-9. pg_auth_members Columns

NameTypeReferencesDescription
roleidoidpg_authid.oidID of a role that has a member
memberoidpg_authid.oidID of a role that is a member of roleid
grantoroidpg_authid.oidID of the role that granted this membership
admin_optionbool True if member can grant membership in + roleid to others

PrevHomeNext
pg_authidUppg_cast
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-authid.html b/doc/src/sgml/html/catalog-pg-authid.html new file mode 100644 index 000000000..5aa46dc14 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-authid.html @@ -0,0 +1,463 @@ + +pg_authid
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.8. pg_authid

The catalog pg_authid contains information about + database authorization identifiers (roles). A role subsumes the concepts + of "users" and "groups". A user is essentially just a + role with the rolcanlogin flag set. Any role (with or + without rolcanlogin) can have other roles as members; see + pg_auth_members. +

Since this catalog contains passwords, it must not be publicly readable. + pg_roles + is a publicly readable view on + pg_authid that blanks out the password field. +

Chapter 20 contains detailed information about user and + privilege management. +

Because user identities are cluster-wide, + pg_authid + is shared across all databases of a cluster: there is only one + copy of pg_authid per cluster, not + one per database. +

Table 45-8. pg_authid Columns

NameTypeDescription
rolnamenameRole name
rolsuperboolRole has superuser privileges
rolinheritboolRole automatically inherits privileges of roles it is a + member of
rolcreateroleboolRole can create more roles
rolcreatedbboolRole can create databases
rolcatupdatebool Role can update system catalogs directly. (Even a superuser cannot do + this unless this column is true) +
rolcanloginbool Role can log in. That is, this role can be given as the initial + session authorization identifier +
rolreplicationbool Role is a replication role. That is, this role can initiate streaming + replication (see Section 25.2.5) and set/unset + the system backup mode using pg_start_backup and + pg_stop_backup +
rolconnlimitint4 For roles that can log in, this sets maximum number of concurrent + connections this role can make. -1 means no limit. +
rolpasswordtext Password (possibly encrypted); null if none. If the password + is encrypted, this column will begin with the string md5 + followed by a 32-character hexadecimal MD5 hash. The MD5 hash + will be of the user's password concatenated to their user name. + For example, if user joe has password xyzzy, + PostgreSQL will store the md5 hash of + xyzzyjoe. A password that does not follow that + format is assumed to be unencrypted. +
rolvaliduntiltimestamptzPassword expiry time (only used for password authentication); + null if no expiration

PrevHomeNext
pg_attributeUppg_auth_members
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-cast.html b/doc/src/sgml/html/catalog-pg-cast.html new file mode 100644 index 000000000..869f21ebc --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-cast.html @@ -0,0 +1,433 @@ + +pg_cast
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.10. pg_cast

The catalog pg_cast stores data type conversion + paths, both built-in and user-defined. +

It should be noted that pg_cast does not represent + every type conversion that the system knows how to perform; only those that + cannot be deduced from some generic rule. For example, casting between a + domain and its base type is not explicitly represented in + pg_cast. Another important exception is that + "automatic I/O conversion casts", those performed using a data + type's own I/O functions to convert to or from text or other + string types, are not explicitly represented in + pg_cast. +

Table 45-10. pg_cast Columns

NameTypeReferencesDescription
castsourceoidpg_type.oidOID of the source data type
casttargetoidpg_type.oidOID of the target data type
castfuncoidpg_proc.oid The OID of the function to use to perform this cast. Zero is + stored if the cast method doesn't require a function. +
castcontextchar  Indicates what contexts the cast can be invoked in. + e means only as an explicit cast (using + CAST or :: syntax). + a means implicitly in assignment + to a target column, as well as explicitly. + i means implicitly in expressions, as well as the + other cases. +
castmethodchar  Indicates how the cast is performed. + f means that the function specified in the castfunc field is used. + i means that the input/output functions are used. + b means that the types are binary-coercible, thus no conversion is required. +

The cast functions listed in pg_cast must + always take the cast source type as their first argument type, and + return the cast destination type as their result type. A cast + function can have up to three arguments. The second argument, + if present, must be type integer; it receives the type + modifier associated with the destination type, or -1 + if there is none. The third argument, + if present, must be type boolean; it receives true + if the cast is an explicit cast, false otherwise. +

It is legitimate to create a pg_cast entry + in which the source and target types are the same, if the associated + function takes more than one argument. Such entries represent + "length coercion functions" that coerce values of the type + to be legal for a particular type modifier value. +

When a pg_cast entry has different source and + target types and a function that takes more than one argument, it + represents converting from one type to another and applying a length + coercion in a single step. When no such entry is available, coercion + to a type that uses a type modifier involves two steps, one to + convert between data types and a second to apply the modifier. +


PrevHomeNext
pg_auth_membersUppg_class
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-class.html b/doc/src/sgml/html/catalog-pg-class.html new file mode 100644 index 000000000..dd573d4c8 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-class.html @@ -0,0 +1,934 @@ + +pg_class
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.11. pg_class

The catalog pg_class catalogs tables and most + everything else that has columns or is otherwise similar to a + table. This includes indexes (but see also + pg_index), sequences, views, composite types, + and TOAST tables; see relkind. + Below, when we mean all of these + kinds of objects we speak of "relations". Not all + columns are meaningful for all relation types. +

Table 45-11. pg_class Columns

NameTypeReferencesDescription
relnamename Name of the table, index, view, etc.
relnamespaceoidpg_namespace.oid The OID of the namespace that contains this relation +
reltypeoidpg_type.oid The OID of the data type that corresponds to this table's row type, + if any (zero for indexes, which have no pg_type entry) +
reloftypeoidpg_type.oid For typed tables, the OID of the underlying composite type, + zero for all other relations +
relowneroidpg_authid.oidOwner of the relation
relamoidpg_am.oidIf this is an index, the access method used (B-tree, hash, etc.)
relfilenodeoid Name of the on-disk file of this relation; zero means this + is a "mapped" relation whose disk file name is determined + by low-level state
reltablespaceoidpg_tablespace.oid The tablespace in which this relation is stored. If zero, + the database's default tablespace is implied. (Not meaningful + if the relation has no on-disk file.) +
relpagesint4  Size of the on-disk representation of this table in pages (of size + BLCKSZ). This is only an estimate used by the + planner. It is updated by VACUUM, + ANALYZE, and a few DDL commands such as + CREATE INDEX. +
reltuplesfloat4  Number of rows in the table. This is only an estimate used by the + planner. It is updated by VACUUM, + ANALYZE, and a few DDL commands such as + CREATE INDEX. +
relallvisibleint4  Number of pages that are marked all-visible in the table's + visibility map. This is only an estimate used by the + planner. It is updated by VACUUM, + ANALYZE, and a few DDL commands such as + CREATE INDEX. +
reltoastrelidoidpg_class.oid OID of the TOAST table associated with this table, 0 if none. The + TOAST table stores large attributes "out of line" in a + secondary table. +
reltoastidxidoidpg_class.oid For a TOAST table, the OID of its index. 0 if not a TOAST table. +
relhasindexbool  True if this is a table and it has (or recently had) any indexes +
relissharedbool  True if this table is shared across all databases in the cluster. Only + certain system catalogs (such as pg_database) + are shared. +
relpersistencechar  p = permanent table, u = unlogged table, + t = temporary table +
relkindchar  r = ordinary table, i = index, + S = sequence, v = view, c = + composite type, t = TOAST table, + f = foreign table +
relnattsint2  Number of user columns in the relation (system columns not + counted). There must be this many corresponding entries in + pg_attribute. See also + pg_attribute.attnum. +
relchecksint2  Number of CHECK constraints on the table; see + pg_constraint catalog +
relhasoidsbool  True if we generate an OID for each row of the relation +
relhaspkeybool  True if the table has (or once had) a primary key +
relhasrulesbool  True if table has (or once had) rules; see + pg_rewrite catalog +
relhastriggersbool  True if table has (or once had) triggers; see + pg_trigger catalog +
relhassubclassbool True if table has (or once had) any inheritance children
relfrozenxidxid  All transaction IDs before this one have been replaced with a permanent + ("frozen") transaction ID in this table. This is used to track + whether the table needs to be vacuumed in order to prevent transaction + ID wraparound or to allow pg_clog to be shrunk. Zero + (InvalidTransactionId) if the relation is not a table. +
relaclaclitem[]  Access privileges; see + GRANT and + REVOKE + for details +
reloptionstext[]  Access-method-specific options, as "keyword=value" strings +

Several of the Boolean flags in pg_class are maintained + lazily: they are guaranteed to be true if that's the correct state, but + may not be reset to false immediately when the condition is no longer + true. For example, relhasindex is set by + CREATE INDEX, but it is never cleared by + DROP INDEX. Instead, VACUUM clears + relhasindex if it finds the table has no indexes. This + arrangement avoids race conditions and improves concurrency. +


PrevHomeNext
pg_castUppg_constraint
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-collation.html b/doc/src/sgml/html/catalog-pg-collation.html new file mode 100644 index 000000000..1642fa2f2 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-collation.html @@ -0,0 +1,402 @@ + +pg_collation
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.13. pg_collation

The catalog pg_collation describes the + available collations, which are essentially mappings from an SQL + name to operating system locale categories. + See Section 22.2 for more information. +

Table 45-13. pg_collation Columns

NameTypeReferencesDescription
collnamename Collation name (unique per namespace and encoding)
collnamespaceoidpg_namespace.oid The OID of the namespace that contains this collation +
collowneroidpg_authid.oidOwner of the collation
collencodingint4 Encoding in which the collation is applicable, or -1 if it + works for any encoding
collcollatename LC_COLLATE for this collation object
collctypename LC_CTYPE for this collation object

Note that the unique key on this catalog is (collname, + collencoding, collnamespace) not just + (collname, collnamespace). + PostgreSQL generally ignores all + collations that do not have collencoding equal to + either the current database's encoding or -1, and creation of new entries + with the same name as an entry with collencoding = -1 + is forbidden. Therefore it is sufficient to use a qualified SQL name + (schema.name) to identify a collation, + even though this is not unique according to the catalog definition. + The reason for defining the catalog this way is that + initdb fills it in at cluster initialization time with + entries for all locales available on the system, so it must be able to + hold entries for all encodings that might ever be used in the cluster. +

In the template0 database, it could be useful to create + collations whose encoding does not match the database encoding, + since they could match the encodings of databases later cloned from + template0. This would currently have to be done manually. +


PrevHomeNext
pg_constraintUppg_conversion
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-constraint.html b/doc/src/sgml/html/catalog-pg-constraint.html new file mode 100644 index 000000000..fb9ce7a82 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-constraint.html @@ -0,0 +1,860 @@ + +pg_constraint
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.12. pg_constraint

The catalog pg_constraint stores check, primary + key, unique, foreign key, and exclusion constraints on tables. + (Column constraints are not treated specially. Every column constraint is + equivalent to some table constraint.) + Not-null constraints are represented in the pg_attribute + catalog, not here. +

User-defined constraint triggers (created with CREATE CONSTRAINT + TRIGGER) also give rise to an entry in this table. +

Check constraints on domains are stored here, too. +

Table 45-12. pg_constraint Columns

NameTypeReferencesDescription
connamename Constraint name (not necessarily unique!)
connamespaceoidpg_namespace.oid The OID of the namespace that contains this constraint +
contypechar  c = check constraint, + f = foreign key constraint, + p = primary key constraint, + u = unique constraint, + t = constraint trigger, + x = exclusion constraint +
condeferrablebool Is the constraint deferrable?
condeferredbool Is the constraint deferred by default?
convalidatedbool Has the constraint been validated? + Currently, can only be false for foreign keys and CHECK constraints
conrelidoidpg_class.oidThe table this constraint is on; 0 if not a table constraint
contypidoidpg_type.oidThe domain this constraint is on; 0 if not a domain constraint
conindidoidpg_class.oidThe index supporting this constraint, if it's a unique, primary + key, foreign key, or exclusion constraint; else 0
confrelidoidpg_class.oidIf a foreign key, the referenced table; else 0
confupdtypechar Foreign key update action code: + a = no action, + r = restrict, + c = cascade, + n = set null, + d = set default +
confdeltypechar Foreign key deletion action code: + a = no action, + r = restrict, + c = cascade, + n = set null, + d = set default +
confmatchtypechar Foreign key match type: + f = full, + p = partial, + u = simple (unspecified) +
conislocalbool  This constraint is defined locally for the relation. Note that a + constraint can be locally defined and inherited simultaneously. +
coninhcountint4  The number of direct inheritance ancestors this constraint has. + A constraint with + a nonzero number of ancestors cannot be dropped nor renamed. +
connoinheritbool  This constraint is defined locally for the relation. It is a + non-inheritable constraint. +
conkeyint2[]pg_attribute.attnumIf a table constraint (including foreign keys, but not constraint + triggers), list of the constrained columns
confkeyint2[]pg_attribute.attnumIf a foreign key, list of the referenced columns
conpfeqopoid[]pg_operator.oidIf a foreign key, list of the equality operators for PK = FK comparisons
conppeqopoid[]pg_operator.oidIf a foreign key, list of the equality operators for PK = PK comparisons
conffeqopoid[]pg_operator.oidIf a foreign key, list of the equality operators for FK = FK comparisons
conexclopoid[]pg_operator.oidIf an exclusion constraint, list of the per-column exclusion operators
conbinpg_node_tree If a check constraint, an internal representation of the expression
consrctext If a check constraint, a human-readable representation of the expression

In the case of an exclusion constraint, conkey + is only useful for constraint elements that are simple column references. + For other cases, a zero appears in conkey + and the associated index must be consulted to discover the expression + that is constrained. (conkey thus has the + same contents as pg_index.indkey for the + index.) +

Note: consrc is not updated when referenced objects + change; for example, it won't track renaming of columns. Rather than + relying on this field, it's best to use pg_get_constraintdef() + to extract the definition of a check constraint. +

Note: pg_class.relchecks needs to agree with the + number of check-constraint entries found in this table for each + relation. +


PrevHomeNext
pg_classUppg_collation
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-conversion.html b/doc/src/sgml/html/catalog-pg-conversion.html new file mode 100644 index 000000000..185a95def --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-conversion.html @@ -0,0 +1,354 @@ + +pg_conversion
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.14. pg_conversion

The catalog pg_conversion describes + encoding conversion procedures. See CREATE CONVERSION + for more information. +

Table 45-14. pg_conversion Columns

NameTypeReferencesDescription
connamename Conversion name (unique within a namespace)
connamespaceoidpg_namespace.oid The OID of the namespace that contains this conversion +
conowneroidpg_authid.oidOwner of the conversion
conforencodingint4 Source encoding ID
contoencodingint4 Destination encoding ID
conprocregprocpg_proc.oidConversion procedure
condefaultbool True if this is the default conversion

PrevHomeNext
pg_collationUppg_database
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-database.html b/doc/src/sgml/html/catalog-pg-database.html new file mode 100644 index 000000000..19dc43d2d --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-database.html @@ -0,0 +1,506 @@ + +pg_database
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.15. pg_database

The catalog pg_database stores information about + the available databases. Databases are created with the CREATE DATABASE command. + Consult Chapter 21 for details about the meaning + of some of the parameters. +

Unlike most system catalogs, pg_database + is shared across all databases of a cluster: there is only one + copy of pg_database per cluster, not + one per database. +

Table 45-15. pg_database Columns

NameTypeReferencesDescription
datnamename Database name
datdbaoidpg_authid.oidOwner of the database, usually the user who created it
encodingint4 Character encoding for this database + (pg_encoding_to_char() can translate + this number to the encoding name)
datcollatename LC_COLLATE for this database
datctypename LC_CTYPE for this database
datistemplatebool  If true then this database can be used in the + TEMPLATE clause of CREATE + DATABASE to create a new database as a clone of + this one +
datallowconnbool  If false then no one can connect to this database. This is + used to protect the template0 database from being altered. +
datconnlimitint4  Sets maximum number of concurrent connections that can be made + to this database. -1 means no limit. +
datlastsysoidoid  Last system OID in the database; useful + particularly to pg_dump +
datfrozenxidxid  All transaction IDs before this one have been replaced with a permanent + ("frozen") transaction ID in this database. This is used to + track whether the database needs to be vacuumed in order to prevent + transaction ID wraparound or to allow pg_clog to be shrunk. + It is the minimum of the per-table + pg_class.relfrozenxid values. +
dattablespaceoidpg_tablespace.oid The default tablespace for the database. + Within this database, all tables for which + pg_class.reltablespace is zero + will be stored in this tablespace; in particular, all the non-shared + system catalogs will be there. +
dataclaclitem[]  Access privileges; see + GRANT and + REVOKE + for details +

PrevHomeNext
pg_conversionUppg_db_role_setting
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-db-role-setting.html b/doc/src/sgml/html/catalog-pg-db-role-setting.html new file mode 100644 index 000000000..3e256469e --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-db-role-setting.html @@ -0,0 +1,289 @@ + +pg_db_role_setting
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.16. pg_db_role_setting

The catalog pg_db_role_setting records the default + values that have been set for run-time configuration variables, + for each role and database combination. +

Unlike most system catalogs, pg_db_role_setting + is shared across all databases of a cluster: there is only one + copy of pg_db_role_setting per cluster, not + one per database. +

Table 45-16. pg_db_role_setting Columns

NameTypeReferencesDescription
setdatabaseoidpg_database.oidThe OID of the database the setting is applicable to, or zero if not database-specific
setroleoidpg_authid.oidThe OID of the role the setting is applicable to, or zero if not role-specific
setconfigtext[] Defaults for run-time configuration variables

PrevHomeNext
pg_databaseUppg_default_acl
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-default-acl.html b/doc/src/sgml/html/catalog-pg-default-acl.html new file mode 100644 index 000000000..019f482ab --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-default-acl.html @@ -0,0 +1,360 @@ + +pg_default_acl
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.17. pg_default_acl

The catalog pg_default_acl stores initial + privileges to be assigned to newly created objects. +

Table 45-17. pg_default_acl Columns

NameTypeReferencesDescription
defaclroleoidpg_authid.oidThe OID of the role associated with this entry
defaclnamespaceoidpg_namespace.oidThe OID of the namespace associated with this entry, + or 0 if none
defaclobjtypechar  Type of object this entry is for: + r = relation (table, view), + S = sequence, + f = function +
defaclaclaclitem[]  Access privileges that this type of object should have on creation +

A pg_default_acl entry shows the initial privileges to + be assigned to an object belonging to the indicated user. There are + currently two types of entry: "global" entries with + defaclnamespace = 0, and "per-schema" entries + that reference a particular schema. If a global entry is present then + it overrides the normal hard-wired default privileges + for the object type. A per-schema entry, if present, represents privileges + to be added to the global or hard-wired default privileges. +

Note that when an ACL entry in another catalog is null, it is taken + to represent the hard-wired default privileges for its object, + not whatever might be in pg_default_acl + at the moment. pg_default_acl is only consulted during + object creation. +


PrevHomeNext
pg_db_role_settingUppg_depend
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-depend.html b/doc/src/sgml/html/catalog-pg-depend.html new file mode 100644 index 000000000..a86b3a424 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-depend.html @@ -0,0 +1,544 @@ + +pg_depend
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.18. pg_depend

The catalog pg_depend records the dependency + relationships between database objects. This information allows + DROP commands to find which other objects must be dropped + by DROP CASCADE or prevent dropping in the DROP + RESTRICT case. +

See also pg_shdepend, + which performs a similar function for dependencies involving objects + that are shared across a database cluster. +

Table 45-18. pg_depend Columns

NameTypeReferencesDescription
classidoidpg_class.oidThe OID of the system catalog the dependent object is in
objidoidany OID columnThe OID of the specific dependent object
objsubidint4  For a table column, this is the column number (the + objid and classid refer to the + table itself). For all other object types, this column is + zero. +
refclassidoidpg_class.oidThe OID of the system catalog the referenced object is in
refobjidoidany OID columnThe OID of the specific referenced object
refobjsubidint4  For a table column, this is the column number (the + refobjid and refclassid refer + to the table itself). For all other object types, this column + is zero. +
deptypechar  A code defining the specific semantics of this dependency relationship; see text +

In all cases, a pg_depend entry indicates that the + referenced object cannot be dropped without also dropping the dependent + object. However, there are several subflavors identified by + deptype: + +

DEPENDENCY_NORMAL (n)

A normal relationship between separately-created objects. The + dependent object can be dropped without affecting the + referenced object. The referenced object can only be dropped + by specifying CASCADE, in which case the dependent + object is dropped, too. Example: a table column has a normal + dependency on its data type. +

DEPENDENCY_AUTO (a)

The dependent object can be dropped separately from the + referenced object, and should be automatically dropped + (regardless of RESTRICT or CASCADE + mode) if the referenced object is dropped. Example: a named + constraint on a table is made autodependent on the table, so + that it will go away if the table is dropped. +

DEPENDENCY_INTERNAL (i)

The dependent object was created as part of creation of the + referenced object, and is really just a part of its internal + implementation. A DROP of the dependent object + will be disallowed outright (we'll tell the user to issue a + DROP against the referenced object, instead). A + DROP of the referenced object will be propagated + through to drop the dependent object whether + CASCADE is specified or not. Example: a trigger + that's created to enforce a foreign-key constraint is made + internally dependent on the constraint's + pg_constraint entry. +

DEPENDENCY_EXTENSION (e)

The dependent object is a member of the extension that is + the referenced object (see + pg_extension). + The dependent object can be dropped only via + DROP EXTENSION on the referenced object. Functionally + this dependency type acts the same as an internal dependency, but + it's kept separate for clarity and to simplify pg_dump. +

DEPENDENCY_PIN (p)

There is no dependent object; this type of entry is a signal + that the system itself depends on the referenced object, and so + that object must never be deleted. Entries of this type are + created only by initdb. The columns for the + dependent object contain zeroes. +

+ + Other dependency flavors might be needed in future. +


PrevHomeNext
pg_default_aclUppg_description
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-description.html b/doc/src/sgml/html/catalog-pg-description.html new file mode 100644 index 000000000..a863517df --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-description.html @@ -0,0 +1,320 @@ + +pg_description
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.19. pg_description

The catalog pg_description stores optional descriptions + (comments) for each database object. Descriptions can be manipulated + with the COMMENT command and viewed with + psql's \d commands. + Descriptions of many built-in system objects are provided in the initial + contents of pg_description. +

See also pg_shdescription, + which performs a similar function for descriptions involving objects that + are shared across a database cluster. +

Table 45-19. pg_description Columns

NameTypeReferencesDescription
objoidoidany OID columnThe OID of the object this description pertains to
classoidoidpg_class.oidThe OID of the system catalog this object appears in
objsubidint4  For a comment on a table column, this is the column number (the + objoid and classoid refer to + the table itself). For all other object types, this column is + zero. +
descriptiontext Arbitrary text that serves as the description of this object

PrevHomeNext
pg_dependUppg_enum
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-enum.html b/doc/src/sgml/html/catalog-pg-enum.html new file mode 100644 index 000000000..459efb8cb --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-enum.html @@ -0,0 +1,307 @@ + +pg_enum
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.20. pg_enum

The pg_enum catalog contains entries + showing the values and labels for each enum type. The + internal representation of a given enum value is actually the OID + of its associated row in pg_enum. +

Table 45-20. pg_enum Columns

NameTypeReferencesDescription
enumtypidoidpg_type.oidThe OID of the pg_type entry owning this enum value
enumsortorderfloat4 The sort position of this enum value within its enum type
enumlabelname The textual label for this enum value

The OIDs for pg_enum rows follow a special + rule: even-numbered OIDs are guaranteed to be ordered in the same way + as the sort ordering of their enum type. That is, if two even OIDs + belong to the same enum type, the smaller OID must have the smaller + enumsortorder value. Odd-numbered OID values + need bear no relationship to the sort order. This rule allows the + enum comparison routines to avoid catalog lookups in many common cases. + The routines that create and alter enum types attempt to assign even + OIDs to enum values whenever possible. +

When an enum type is created, its members are assigned sort-order + positions 1..n. But members added later might be given + negative or fractional values of enumsortorder. + The only requirement on these values is that they be correctly + ordered and unique within each enum type. +


PrevHomeNext
pg_descriptionUppg_extension
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-extension.html b/doc/src/sgml/html/catalog-pg-extension.html new file mode 100644 index 000000000..6e99c979a --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-extension.html @@ -0,0 +1,389 @@ + +pg_extension
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.21. pg_extension

The catalog pg_extension stores information + about the installed extensions. See Section 35.15 + for details about extensions. +

Table 45-21. pg_extension Columns

NameTypeReferencesDescription
extnamename Name of the extension
extowneroidpg_authid.oidOwner of the extension
extnamespaceoidpg_namespace.oidSchema containing the extension's exported objects
extrelocatablebool True if extension can be relocated to another schema
extversiontext Version name for the extension
extconfigoid[]pg_class.oidArray of regclass OIDs for the extension's configuration + table(s), or NULL if none
extconditiontext[] Array of WHERE-clause filter conditions for the + extension's configuration table(s), or NULL if none

Note that unlike most catalogs with a "namespace" column, + extnamespace is not meant to imply + that the extension belongs to that schema. Extension names are never + schema-qualified. Rather, extnamespace + indicates the schema that contains most or all of the extension's + objects. If extrelocatable is true, then + this schema must in fact contain all schema-qualifiable objects + belonging to the extension. +


PrevHomeNext
pg_enumUppg_foreign_data_wrapper
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-foreign-data-wrapper.html b/doc/src/sgml/html/catalog-pg-foreign-data-wrapper.html new file mode 100644 index 000000000..82dc7459a --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-foreign-data-wrapper.html @@ -0,0 +1,357 @@ + +pg_foreign_data_wrapper
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.22. pg_foreign_data_wrapper

The catalog pg_foreign_data_wrapper stores + foreign-data wrapper definitions. A foreign-data wrapper is the + mechanism by which external data, residing on foreign servers, is + accessed. +

Table 45-22. pg_foreign_data_wrapper Columns

NameTypeReferencesDescription
fdwnamename Name of the foreign-data wrapper
fdwowneroidpg_authid.oidOwner of the foreign-data wrapper
fdwhandleroidpg_proc.oid References a handler function that is responsible for + supplying execution routines for the foreign-data wrapper. + Zero if no handler is provided +
fdwvalidatoroidpg_proc.oid References a validator function that is responsible for + checking the validity of the options given to the + foreign-data wrapper, as well as options for foreign servers and user + mappings using the foreign-data wrapper. Zero if no validator + is provided +
fdwaclaclitem[]  Access privileges; see + GRANT and + REVOKE + for details +
fdwoptionstext[]  Foreign-data wrapper specific options, as "keyword=value" strings +

PrevHomeNext
pg_extensionUppg_foreign_server
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-foreign-server.html b/doc/src/sgml/html/catalog-pg-foreign-server.html new file mode 100644 index 000000000..9f917073d --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-foreign-server.html @@ -0,0 +1,356 @@ + +pg_foreign_server
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.23. pg_foreign_server

The catalog pg_foreign_server stores + foreign server definitions. A foreign server describes a source + of external data, such as a remote server. Foreign + servers are accessed via foreign-data wrappers. +

Table 45-23. pg_foreign_server Columns

NameTypeReferencesDescription
srvnamename Name of the foreign server
srvowneroidpg_authid.oidOwner of the foreign server
srvfdwoidpg_foreign_data_wrapper.oidOID of the foreign-data wrapper of this foreign server
srvtypetext Type of the server (optional)
srvversiontext Version of the server (optional)
srvaclaclitem[]  Access privileges; see + GRANT and + REVOKE + for details +
srvoptionstext[]  Foreign server specific options, as "keyword=value" strings +

PrevHomeNext
pg_foreign_data_wrapperUppg_foreign_table
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-foreign-table.html b/doc/src/sgml/html/catalog-pg-foreign-table.html new file mode 100644 index 000000000..6d142e1c7 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-foreign-table.html @@ -0,0 +1,293 @@ + +pg_foreign_table
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.24. pg_foreign_table

The catalog pg_foreign_table contains + auxiliary information about foreign tables. A foreign table is + primarily represented by a pg_class entry, + just like a regular table. Its pg_foreign_table + entry contains the information that is pertinent only to foreign tables + and not any other kind of relation. +

Table 45-24. pg_foreign_table Columns

NameTypeReferencesDescription
ftrelidoidpg_class.oidOID of the pg_class entry for this foreign table
ftserveroidpg_foreign_server.oidOID of the foreign server for this foreign table
ftoptionstext[]  Foreign table options, as "keyword=value" strings +

PrevHomeNext
pg_foreign_serverUppg_index
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-index.html b/doc/src/sgml/html/catalog-pg-index.html new file mode 100644 index 000000000..a4f63d8a7 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-index.html @@ -0,0 +1,633 @@ + +pg_index
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.25. pg_index

The catalog pg_index contains part of the information + about indexes. The rest is mostly in + pg_class. +

Table 45-25. pg_index Columns

NameTypeReferencesDescription
indexrelidoidpg_class.oidThe OID of the pg_class entry for this index
indrelidoidpg_class.oidThe OID of the pg_class entry for the table this index is for
indnattsint2 The number of columns in the index (duplicates + pg_class.relnatts)
indisuniquebool If true, this is a unique index
indisprimarybool If true, this index represents the primary key of the table + (indisunique should always be true when this is true)
indisexclusionbool If true, this index supports an exclusion constraint
indimmediatebool If true, the uniqueness check is enforced immediately on + insertion + (irrelevant if indisunique is not true)
indisclusteredbool If true, the table was last clustered on this index
indisvalidbool  If both this flag and indisready are + true, the index is currently valid for queries. False means the + index is possibly incomplete: it must still be modified by + INSERT/UPDATE operations, but it cannot safely + be used for queries. If it is unique, the uniqueness property is not + guaranteed true either. +
indcheckxminbool  If true, queries must not use the index until the xmin + of this pg_index row is below their TransactionXmin + event horizon, because the table may contain broken HOT chains with + incompatible rows that they can see +
indisreadybool  If true, the index is currently ready for inserts. False means the + index must be ignored by INSERT/UPDATE + operations. +
indkeyint2vectorpg_attribute.attnum This is an array of indnatts values that + indicate which table columns this index indexes. For example a value + of 1 3 would mean that the first and the third table + columns make up the index key. A zero in this array indicates that the + corresponding index attribute is an expression over the table columns, + rather than a simple column reference. +
indcollationoidvectorpg_collation.oid For each column in the index key, this contains the OID of the + collation to use for the index. +
indclassoidvectorpg_opclass.oid For each column in the index key, this contains the OID of + the operator class to use. See + pg_opclass for details. +
indoptionint2vector  This is an array of indnatts values that + store per-column flag bits. The meaning of the bits is defined by + the index's access method. +
indexprspg_node_tree  Expression trees (in nodeToString() + representation) for index attributes that are not simple column + references. This is a list with one element for each zero + entry in indkey. Null if all index attributes + are simple references. +
indpredpg_node_tree  Expression tree (in nodeToString() + representation) for partial index predicate. Null if not a + partial index. +

PrevHomeNext
pg_foreign_tableUppg_inherits
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-inherits.html b/doc/src/sgml/html/catalog-pg-inherits.html new file mode 100644 index 000000000..06ead233a --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-inherits.html @@ -0,0 +1,283 @@ + +pg_inherits
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.26. pg_inherits

The catalog pg_inherits records information about + table inheritance hierarchies. There is one entry for each direct + child table in the database. (Indirect inheritance can be determined + by following chains of entries.) +

Table 45-26. pg_inherits Columns

NameTypeReferencesDescription
inhrelidoidpg_class.oid The OID of the child table +
inhparentoidpg_class.oid The OID of the parent table +
inhseqnoint4  If there is more than one direct parent for a child table (multiple + inheritance), this number tells the order in which the + inherited columns are to be arranged. The count starts at 1. +

PrevHomeNext
pg_indexUppg_language
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-language.html b/doc/src/sgml/html/catalog-pg-language.html new file mode 100644 index 000000000..1990e13e1 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-language.html @@ -0,0 +1,424 @@ + +pg_language
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.27. pg_language

The catalog pg_language registers + languages in which you can write functions or stored procedures. + See CREATE LANGUAGE + and Chapter 38 for more information about language handlers. +

Table 45-27. pg_language Columns

NameTypeReferencesDescription
lannamename Name of the language
lanowneroidpg_authid.oidOwner of the language
lanisplbool  This is false for internal languages (such as + SQL) and true for user-defined languages. + Currently, pg_dump still uses this + to determine which languages need to be dumped, but this might be + replaced by a different mechanism in the future. +
lanpltrustedbool  True if this is a trusted language, which means that it is believed + not to grant access to anything outside the normal SQL execution + environment. Only superusers can create functions in untrusted + languages. +
lanplcallfoidoidpg_proc.oid For noninternal languages this references the language + handler, which is a special function that is responsible for + executing all functions that are written in the particular + language +
laninlineoidpg_proc.oid This references a function that is responsible for executing + "inline" anonymous code blocks + (DO blocks). + Zero if inline blocks are not supported. +
lanvalidatoroidpg_proc.oid This references a language validator function that is responsible + for checking the syntax and validity of new functions when they + are created. Zero if no validator is provided. +
lanaclaclitem[]  Access privileges; see + GRANT and + REVOKE + for details +

PrevHomeNext
pg_inheritsUppg_largeobject
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-largeobject-metadata.html b/doc/src/sgml/html/catalog-pg-largeobject-metadata.html new file mode 100644 index 000000000..188036c41 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-largeobject-metadata.html @@ -0,0 +1,269 @@ + +pg_largeobject_metadata
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.29. pg_largeobject_metadata

The catalog pg_largeobject_metadata + holds metadata associated with large objects. The actual large object + data is stored in + pg_largeobject. +

Table 45-29. pg_largeobject_metadata Columns

NameTypeReferencesDescription
lomowneroidpg_authid.oidOwner of the large object
lomaclaclitem[]  Access privileges; see + GRANT and + REVOKE + for details +

PrevHomeNext
pg_largeobjectUppg_namespace
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-largeobject.html b/doc/src/sgml/html/catalog-pg-largeobject.html new file mode 100644 index 000000000..88d861757 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-largeobject.html @@ -0,0 +1,331 @@ + +pg_largeobject
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.28. pg_largeobject

The catalog pg_largeobject holds the data making up + "large objects". A large object is identified by an OID + assigned when it is created. Each large object is broken into + segments or "pages" small enough to be conveniently stored as rows + in pg_largeobject. + The amount of data per page is defined to be LOBLKSIZE (which is currently + BLCKSZ/4, or typically 2 kB). +

Prior to PostgreSQL 9.0, there was no permission structure + associated with large objects. As a result, + pg_largeobject was publicly readable and could be + used to obtain the OIDs (and contents) of all large objects in the system. + This is no longer the case; use + pg_largeobject_metadata + to obtain a list of large object OIDs. +

Table 45-28. pg_largeobject Columns

NameTypeReferencesDescription
loidoidpg_largeobject_metadata.oidIdentifier of the large object that includes this page
pagenoint4 Page number of this page within its large object + (counting from zero)
databytea  Actual data stored in the large object. + This will never be more than LOBLKSIZE bytes and might be less. +

Each row of pg_largeobject holds data + for one page of a large object, beginning at + byte offset (pageno * LOBLKSIZE) within the object. The implementation + allows sparse storage: pages might be missing, and might be shorter than + LOBLKSIZE bytes even if they are not the last page of the object. + Missing regions within a large object read as zeroes. +


PrevHomeNext
pg_languageUppg_largeobject_metadata
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-namespace.html b/doc/src/sgml/html/catalog-pg-namespace.html new file mode 100644 index 000000000..329bace13 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-namespace.html @@ -0,0 +1,279 @@ + +pg_namespace
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.30. pg_namespace

The catalog pg_namespace stores namespaces. + A namespace is the structure underlying SQL schemas: each namespace + can have a separate collection of relations, types, etc. without name + conflicts. +

Table 45-30. pg_namespace Columns

NameTypeReferencesDescription
nspnamename Name of the namespace
nspowneroidpg_authid.oidOwner of the namespace
nspaclaclitem[]  Access privileges; see + GRANT and + REVOKE + for details +

PrevHomeNext
pg_largeobject_metadataUppg_opclass
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-opclass.html b/doc/src/sgml/html/catalog-pg-opclass.html new file mode 100644 index 000000000..e218e6ab5 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-opclass.html @@ -0,0 +1,435 @@ + +pg_opclass
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.31. pg_opclass

The catalog pg_opclass defines + index access method operator classes. Each operator class defines + semantics for index columns of a particular data type and a particular + index access method. An operator class essentially specifies that a + particular operator family is applicable to a particular indexable column + data type. The set of operators from the family that are actually usable + with the indexed column are whichever ones accept the column's data type + as their left-hand input. +

Operator classes are described at length in Section 35.14. +

Table 45-31. pg_opclass Columns

NameTypeReferencesDescription
opcmethodoidpg_am.oidIndex access method operator class is for
opcnamename Name of this operator class
opcnamespaceoidpg_namespace.oidNamespace of this operator class
opcowneroidpg_authid.oidOwner of the operator class
opcfamilyoidpg_opfamily.oidOperator family containing the operator class
opcintypeoidpg_type.oidData type that the operator class indexes
opcdefaultbool True if this operator class is the default for opcintype
opckeytypeoidpg_type.oidType of data stored in index, or zero if same as opcintype

An operator class's opcmethod must match the + opfmethod of its containing operator family. + Also, there must be no more than one pg_opclass + row having opcdefault true for any given combination of + opcmethod and opcintype. +


PrevHomeNext
pg_namespaceUppg_operator
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-operator.html b/doc/src/sgml/html/catalog-pg-operator.html new file mode 100644 index 000000000..986e11f6f --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-operator.html @@ -0,0 +1,559 @@ + +pg_operator
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.32. pg_operator

The catalog pg_operator stores information about operators. + See CREATE OPERATOR + and Section 35.12 for more information. +

Table 45-32. pg_operator Columns

NameTypeReferencesDescription
oprnamename Name of the operator
oprnamespaceoidpg_namespace.oid The OID of the namespace that contains this operator +
oprowneroidpg_authid.oidOwner of the operator
oprkindchar  b = infix ("both"), l = prefix + ("left"), r = postfix ("right") +
oprcanmergebool This operator supports merge joins
oprcanhashbool This operator supports hash joins
oprleftoidpg_type.oidType of the left operand
oprrightoidpg_type.oidType of the right operand
oprresultoidpg_type.oidType of the result
oprcomoidpg_operator.oidCommutator of this operator, if any
oprnegateoidpg_operator.oidNegator of this operator, if any
oprcoderegprocpg_proc.oidFunction that implements this operator
oprrestregprocpg_proc.oidRestriction selectivity estimation function for this operator
oprjoinregprocpg_proc.oidJoin selectivity estimation function for this operator

Unused column contain zeroes. For example, oprleft + is zero for a prefix operator. +


PrevHomeNext
pg_opclassUppg_opfamily
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-opfamily.html b/doc/src/sgml/html/catalog-pg-opfamily.html new file mode 100644 index 000000000..dc921bc3b --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-opfamily.html @@ -0,0 +1,345 @@ + +pg_opfamily
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.33. pg_opfamily

The catalog pg_opfamily defines operator families. + Each operator family is a collection of operators and associated + support routines that implement the semantics specified for a particular + index access method. Furthermore, the operators in a family are all + "compatible", in a way that is specified by the access method. + The operator family concept allows cross-data-type operators to be used + with indexes and to be reasoned about using knowledge of access method + semantics. +

Operator families are described at length in Section 35.14. +

Table 45-33. pg_opfamily Columns

NameTypeReferencesDescription
opfmethodoidpg_am.oidIndex access method operator family is for
opfnamename Name of this operator family
opfnamespaceoidpg_namespace.oidNamespace of this operator family
opfowneroidpg_authid.oidOwner of the operator family

The majority of the information defining an operator family is not in its + pg_opfamily row, but in the associated rows in + pg_amop, + pg_amproc, + and + pg_opclass. +


PrevHomeNext
pg_operatorUppg_pltemplate
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-pltemplate.html b/doc/src/sgml/html/catalog-pg-pltemplate.html new file mode 100644 index 000000000..9c40d27f0 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-pltemplate.html @@ -0,0 +1,377 @@ + +pg_pltemplate
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.34. pg_pltemplate

The catalog pg_pltemplate stores + "template" information for procedural languages. + A template for a language allows the language to be created in a + particular database by a simple CREATE LANGUAGE command, + with no need to specify implementation details. +

Unlike most system catalogs, pg_pltemplate + is shared across all databases of a cluster: there is only one + copy of pg_pltemplate per cluster, not + one per database. This allows the information to be accessible in + each database as it is needed. +

Table 45-34. pg_pltemplate Columns

NameTypeDescription
tmplnamenameName of the language this template is for
tmpltrustedbooleanTrue if language is considered trusted
tmpldbacreatebooleanTrue if language may be created by a database owner
tmplhandlertextName of call handler function
tmplinlinetextName of anonymous-block handler function, or null if none
tmplvalidatortextName of validator function, or null if none
tmpllibrarytextPath of shared library that implements language
tmplaclaclitem[]Access privileges for template (not actually used)

There are not currently any commands that manipulate procedural language + templates; to change the built-in information, a superuser must modify + the table using ordinary INSERT, DELETE, + or UPDATE commands. +

Note: It is likely that pg_pltemplate will be removed in some + future release of PostgreSQL, in favor of + keeping this knowledge about procedural languages in their respective + extension installation scripts. +


PrevHomeNext
pg_opfamilyUppg_proc
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-proc.html b/doc/src/sgml/html/catalog-pg-proc.html new file mode 100644 index 000000000..bec1ce3d9 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-proc.html @@ -0,0 +1,953 @@ + +pg_proc
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.35. pg_proc

The catalog pg_proc stores information about functions (or procedures). + See CREATE FUNCTION + and Section 35.3 for more information. +

The table contains data for aggregate functions as well as plain functions. + If proisagg is true, there should be a matching + row in pg_aggregate. +

Table 45-35. pg_proc Columns

NameTypeReferencesDescription
pronamename Name of the function
pronamespaceoidpg_namespace.oid The OID of the namespace that contains this function +
proowneroidpg_authid.oidOwner of the function
prolangoidpg_language.oidImplementation language or call interface of this function
procostfloat4 Estimated execution cost (in units of + cpu_operator_cost); if proretset, + this is cost per row returned
prorowsfloat4 Estimated number of result rows (zero if not proretset)
provariadicoidpg_type.oidData type of the variadic array parameter's elements, + or zero if the function does not have a variadic parameter
protransformregprocpg_proc.oidCalls to this function can be simplified by this other function + (see Section 35.9.11)
proisaggbool Function is an aggregate function
proiswindowbool Function is a window function
prosecdefbool Function is a security definer (i.e., a "setuid" + function)
proleakproofbool  The function has no side effects. No information about the + arguments is conveyed except via the return value. Any function + that might throw an error depending on the values of its arguments + is not leak-proof. +
proisstrictbool  Function returns null if any call argument is null. In that + case the function won't actually be called at all. Functions + that are not "strict" must be prepared to handle + null inputs. +
proretsetbool Function returns a set (i.e., multiple values of the specified + data type)
provolatilechar  provolatile tells whether the function's + result depends only on its input arguments, or is affected by outside + factors. + It is i for "immutable" functions, + which always deliver the same result for the same inputs. + It is s for "stable" functions, + whose results (for fixed inputs) do not change within a scan. + It is v for "volatile" functions, + whose results might change at any time. (Use v also + for functions with side-effects, so that calls to them cannot get + optimized away.) +
pronargsint2 Number of input arguments
pronargdefaultsint2 Number of arguments that have defaults
prorettypeoidpg_type.oidData type of the return value
proargtypesoidvectorpg_type.oid An array with the data types of the function arguments. This includes + only input arguments (including INOUT and + VARIADIC arguments), and thus represents + the call signature of the function. +
proallargtypesoid[]pg_type.oid An array with the data types of the function arguments. This includes + all arguments (including OUT and + INOUT arguments); however, if all the + arguments are IN arguments, this field will be null. + Note that subscripting is 1-based, whereas for historical reasons + proargtypes is subscripted from 0. +
proargmodeschar[]  An array with the modes of the function arguments, encoded as + i for IN arguments, + o for OUT arguments, + b for INOUT arguments, + v for VARIADIC arguments, + t for TABLE arguments. + If all the arguments are IN arguments, + this field will be null. + Note that subscripts correspond to positions of + proallargtypes not proargtypes. +
proargnamestext[]  An array with the names of the function arguments. + Arguments without a name are set to empty strings in the array. + If none of the arguments have a name, this field will be null. + Note that subscripts correspond to positions of + proallargtypes not proargtypes. +
proargdefaultspg_node_tree  Expression trees (in nodeToString() representation) + for default values. This is a list with + pronargdefaults elements, corresponding to the last + N input arguments (i.e., the last + N proargtypes positions). + If none of the arguments have defaults, this field will be null. +
prosrctext  This tells the function handler how to invoke the function. It + might be the actual source code of the function for interpreted + languages, a link symbol, a file name, or just about anything + else, depending on the implementation language/call convention. +
probintext  Additional information about how to invoke the function. + Again, the interpretation is language-specific. +
proconfigtext[] Function's local settings for run-time configuration variables
proaclaclitem[]  Access privileges; see + GRANT and + REVOKE + for details +

For compiled functions, both built-in and dynamically loaded, + prosrc contains the function's C-language + name (link symbol). For all other currently-known language types, + prosrc contains the function's source + text. probin is unused except for + dynamically-loaded C functions, for which it gives the name of the + shared library file containing the function. +


PrevHomeNext
pg_pltemplateUppg_range
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-range.html b/doc/src/sgml/html/catalog-pg-range.html new file mode 100644 index 000000000..2170bc84c --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-range.html @@ -0,0 +1,391 @@ + +pg_range
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.36. pg_range

The catalog pg_range stores information about + range types. This is in addition to the types' entries in + pg_type. +

Table 45-36. pg_range Columns

NameTypeReferencesDescription
rngtypidoidpg_type.oidOID of the range type
rngsubtypeoidpg_type.oidOID of the element type (subtype) of this range type
rngcollationoidpg_collation.oidOID of the collation used for range comparisons, or 0 if none
rngsubopcoidpg_opclass.oidOID of the subtype's operator class used for range comparisons
rngcanonicalregprocpg_proc.oidOID of the function to convert a range value into canonical form, + or 0 if none
rngsubdiffregprocpg_proc.oidOID of the function to return the difference between two element + values as double precision, or 0 if none

rngsubopc (plus rngcollation, if the + element type is collatable) determines the sort ordering used by the range + type. rngcanonical is used when the element type is + discrete. rngsubdiff is optional but should be supplied to + improve performance of GiST indexes on the range type. +


PrevHomeNext
pg_procUppg_rewrite
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-rewrite.html b/doc/src/sgml/html/catalog-pg-rewrite.html new file mode 100644 index 000000000..ac3f4a0bc --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-rewrite.html @@ -0,0 +1,422 @@ + +pg_rewrite
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.37. pg_rewrite

The catalog pg_rewrite stores rewrite rules for tables and views. +

Table 45-37. pg_rewrite Columns

NameTypeReferencesDescription
rulenamename Rule name
ev_classoidpg_class.oidThe table this rule is for
ev_attrint2 The column this rule is for (currently, always zero to + indicate the whole table)
ev_typechar  Event type that the rule is for: 1 = SELECT, 2 = + UPDATE, 3 = INSERT, 4 = + DELETE +
ev_enabledchar  Controls in which session_replication_role modes + the rule fires. + O = rule fires in "origin" and "local" modes, + D = rule is disabled, + R = rule fires in "replica" mode, + A = rule fires always. +
is_insteadbool True if the rule is an INSTEAD rule
ev_qualpg_node_tree  Expression tree (in the form of a + nodeToString() representation) for the + rule's qualifying condition +
ev_actionpg_node_tree  Query tree (in the form of a + nodeToString() representation) for the + rule's action +

Note: pg_class.relhasrules + must be true if a table has any rules in this catalog. +


PrevHomeNext
pg_rangeUppg_seclabel
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-seclabel.html b/doc/src/sgml/html/catalog-pg-seclabel.html new file mode 100644 index 000000000..3865fa162 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-seclabel.html @@ -0,0 +1,328 @@ + +pg_seclabel
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.38. pg_seclabel

The catalog pg_seclabel stores security + labels on database objects. Security labels can be manipulated + with the SECURITY LABEL command. For an easier + way to view security labels, see Section 45.63. +

See also pg_shseclabel, + which performs a similar function for security labels of database objects + that are shared across a database cluster. +

Table 45-38. pg_seclabel Columns

NameTypeReferencesDescription
objoidoidany OID columnThe OID of the object this security label pertains to
classoidoidpg_class.oidThe OID of the system catalog this object appears in
objsubidint4  For a security label on a table column, this is the column number (the + objoid and classoid refer to + the table itself). For all other object types, this column is + zero. +
providertext The label provider associated with this label.
labeltext The security label applied to this object.

PrevHomeNext
pg_rewriteUppg_shdepend
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-shdepend.html b/doc/src/sgml/html/catalog-pg-shdepend.html new file mode 100644 index 000000000..fd1ac2f0a --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-shdepend.html @@ -0,0 +1,471 @@ + +pg_shdepend
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.39. pg_shdepend

The catalog pg_shdepend records the + dependency relationships between database objects and shared objects, + such as roles. This information allows + PostgreSQL to ensure that those objects are + unreferenced before attempting to delete them. +

See also pg_depend, + which performs a similar function for dependencies involving objects + within a single database. +

Unlike most system catalogs, pg_shdepend + is shared across all databases of a cluster: there is only one + copy of pg_shdepend per cluster, not + one per database. +

Table 45-39. pg_shdepend Columns

NameTypeReferencesDescription
dbidoidpg_database.oidThe OID of the database the dependent object is in, + or zero for a shared object
classidoidpg_class.oidThe OID of the system catalog the dependent object is in
objidoidany OID columnThe OID of the specific dependent object
objsubidint4  For a table column, this is the column number (the + objid and classid refer to the + table itself). For all other object types, this column is zero. +
refclassidoidpg_class.oidThe OID of the system catalog the referenced object is in + (must be a shared catalog)
refobjidoidany OID columnThe OID of the specific referenced object
deptypechar  A code defining the specific semantics of this dependency relationship; see text +

In all cases, a pg_shdepend entry indicates that + the referenced object cannot be dropped without also dropping the dependent + object. However, there are several subflavors identified by + deptype: + +

SHARED_DEPENDENCY_OWNER (o)

The referenced object (which must be a role) is the owner of the + dependent object. +

SHARED_DEPENDENCY_ACL (a)

The referenced object (which must be a role) is mentioned in the + ACL (access control list, i.e., privileges list) of the + dependent object. (A SHARED_DEPENDENCY_ACL entry is + not made for the owner of the object, since the owner will have + a SHARED_DEPENDENCY_OWNER entry anyway.) +

SHARED_DEPENDENCY_PIN (p)

There is no dependent object; this type of entry is a signal + that the system itself depends on the referenced object, and so + that object must never be deleted. Entries of this type are + created only by initdb. The columns for the + dependent object contain zeroes. +

+ + Other dependency flavors might be needed in future. Note in particular + that the current definition only supports roles as referenced objects. +


PrevHomeNext
pg_seclabelUppg_shdescription
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-shdescription.html b/doc/src/sgml/html/catalog-pg-shdescription.html new file mode 100644 index 000000000..b1923ef83 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-shdescription.html @@ -0,0 +1,301 @@ + +pg_shdescription
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.40. pg_shdescription

The catalog pg_shdescription stores optional + descriptions (comments) for shared database objects. Descriptions can be + manipulated with the COMMENT command and viewed with + psql's \d commands. +

See also pg_description, + which performs a similar function for descriptions involving objects + within a single database. +

Unlike most system catalogs, pg_shdescription + is shared across all databases of a cluster: there is only one + copy of pg_shdescription per cluster, not + one per database. +

Table 45-40. pg_shdescription Columns

NameTypeReferencesDescription
objoidoidany OID columnThe OID of the object this description pertains to
classoidoidpg_class.oidThe OID of the system catalog this object appears in
descriptiontext Arbitrary text that serves as the description of this object

PrevHomeNext
pg_shdependUppg_shseclabel
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-shseclabel.html b/doc/src/sgml/html/catalog-pg-shseclabel.html new file mode 100644 index 000000000..1e43c5c62 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-shseclabel.html @@ -0,0 +1,314 @@ + +pg_shseclabel
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.41. pg_shseclabel

The catalog pg_shseclabel stores security + labels on shared database objects. Security labels can be manipulated + with the SECURITY LABEL command. For an easier + way to view security labels, see Section 45.63. +

See also pg_seclabel, + which performs a similar function for security labels involving objects + within a single database. +

Unlike most system catalogs, pg_shseclabel + is shared across all databases of a cluster: there is only one + copy of pg_shseclabel per cluster, not + one per database. +

Table 45-41. pg_shseclabel Columns

NameTypeReferencesDescription
objoidoidany OID columnThe OID of the object this security label pertains to
classoidoidpg_class.oidThe OID of the system catalog this object appears in
providertext The label provider associated with this label.
labeltext The security label applied to this object.

PrevHomeNext
pg_shdescriptionUppg_statistic
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-statistic.html b/doc/src/sgml/html/catalog-pg-statistic.html new file mode 100644 index 000000000..c5ab2e7f6 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-statistic.html @@ -0,0 +1,614 @@ + +pg_statistic
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.42. pg_statistic

The catalog pg_statistic stores + statistical data about the contents of the database. Entries are + created by ANALYZE + and subsequently used by the query planner. Note that all the + statistical data is inherently approximate, even assuming that it + is up-to-date. +

Normally there is one entry, with stainherit = + false, for each table column that has been analyzed. + If the table has inheritance children, a second entry with + stainherit = true is also created. This row + represents the column's statistics over the inheritance tree, i.e., + statistics for the data you'd see with + SELECT column FROM table*, + whereas the stainherit = false row represents + the results of + SELECT column FROM ONLY table. +

pg_statistic also stores statistical data about + the values of index expressions. These are described as if they were + actual data columns; in particular, starelid + references the index. No entry is made for an ordinary non-expression + index column, however, since it would be redundant with the entry + for the underlying table column. Currently, entries for index expressions + always have stainherit = false. +

Since different kinds of statistics might be appropriate for different + kinds of data, pg_statistic is designed not + to assume very much about what sort of statistics it stores. Only + extremely general statistics (such as nullness) are given dedicated + columns in pg_statistic. Everything else + is stored in "slots", which are groups of associated columns + whose content is identified by a code number in one of the slot's columns. + For more information see + src/include/catalog/pg_statistic.h. +

pg_statistic should not be readable by the + public, since even statistical information about a table's contents + might be considered sensitive. (Example: minimum and maximum values + of a salary column might be quite interesting.) + pg_stats + is a publicly readable view on + pg_statistic that only exposes information + about those tables that are readable by the current user. +

Table 45-42. pg_statistic Columns

NameTypeReferencesDescription
starelidoidpg_class.oidThe table or index that the described column belongs to
staattnumint2pg_attribute.attnumThe number of the described column
stainheritbool If true, the stats include inheritance child columns, not just the + values in the specified relation
stanullfracfloat4 The fraction of the column's entries that are null
stawidthint4 The average stored width, in bytes, of nonnull entries
stadistinctfloat4 The number of distinct nonnull data values in the column. + A value greater than zero is the actual number of distinct values. + A value less than zero is the negative of a multiplier for the number + of rows in the table; for example, a column in which values appear about + twice on the average could be represented by + stadistinct = -0.5. + A zero value means the number of distinct values is unknown. +
stakindNint2  A code number indicating the kind of statistics stored in the + Nth "slot" of the + pg_statistic row. +
staopNoidpg_operator.oid An operator used to derive the statistics stored in the + Nth "slot". For example, a + histogram slot would show the < operator + that defines the sort order of the data. +
stanumbersNfloat4[]  Numerical statistics of the appropriate kind for the + Nth "slot", or null if the slot + kind does not involve numerical values +
stavaluesNanyarray  Column data values of the appropriate kind for the + Nth "slot", or null if the slot + kind does not store any data values. Each array's element + values are actually of the specific column's data type, or a related + type such as an array's element type, so there is no way to define + these columns' type more specifically than anyarray. +

PrevHomeNext
pg_shseclabelUppg_tablespace
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-tablespace.html b/doc/src/sgml/html/catalog-pg-tablespace.html new file mode 100644 index 000000000..e4ecf2e58 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-tablespace.html @@ -0,0 +1,310 @@ + +pg_tablespace
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.43. pg_tablespace

The catalog pg_tablespace stores information + about the available tablespaces. Tables can be placed in particular + tablespaces to aid administration of disk layout. +

Unlike most system catalogs, pg_tablespace + is shared across all databases of a cluster: there is only one + copy of pg_tablespace per cluster, not + one per database. +

Table 45-43. pg_tablespace Columns

NameTypeReferencesDescription
spcnamename Tablespace name
spcowneroidpg_authid.oidOwner of the tablespace, usually the user who created it
spcaclaclitem[]  Access privileges; see + GRANT and + REVOKE + for details +
spcoptionstext[]  Tablespace-level options, as "keyword=value" strings +

PrevHomeNext
pg_statisticUppg_trigger
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-trigger.html b/doc/src/sgml/html/catalog-pg-trigger.html new file mode 100644 index 000000000..763fda697 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-trigger.html @@ -0,0 +1,624 @@ + +pg_trigger
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.44. pg_trigger

The catalog pg_trigger stores triggers on tables + and views. + See CREATE TRIGGER + for more information. +

Table 45-44. pg_trigger Columns

NameTypeReferencesDescription
tgrelidoidpg_class.oidThe table this trigger is on
tgnamename Trigger name (must be unique among triggers of same table)
tgfoidoidpg_proc.oidThe function to be called
tgtypeint2 Bit mask identifying trigger firing conditions
tgenabledchar  Controls in which session_replication_role modes + the trigger fires. + O = trigger fires in "origin" and "local" modes, + D = trigger is disabled, + R = trigger fires in "replica" mode, + A = trigger fires always. +
tgisinternalbool True if trigger is internally generated (usually, to enforce + the constraint identified by tgconstraint)
tgconstrrelidoidpg_class.oidThe table referenced by a referential integrity constraint
tgconstrindidoidpg_class.oidThe index supporting a unique, primary key, or referential integrity constraint
tgconstraintoidpg_constraint.oidThe pg_constraint entry associated with the trigger, if any
tgdeferrablebool True if constraint trigger is deferrable
tginitdeferredbool True if constraint trigger is initially deferred
tgnargsint2 Number of argument strings passed to trigger function
tgattrint2vectorpg_attribute.attnumColumn numbers, if trigger is column-specific; otherwise an + empty array
tgargsbytea Argument strings to pass to trigger, each NULL-terminated
tgqualpg_node_tree Expression tree (in nodeToString() + representation) for the trigger's WHEN condition, or null + if none

Currently, column-specific triggering is supported only for + UPDATE events, and so tgattr is relevant + only for that event type. tgtype might + contain bits for other event types as well, but those are presumed + to be table-wide regardless of what is in tgattr. +

Note: When tgconstraint is nonzero, + tgconstrrelid, tgconstrindid, + tgdeferrable, and tginitdeferred are + largely redundant with the referenced pg_constraint entry. + However, it is possible for a non-deferrable trigger to be associated + with a deferrable constraint: foreign key constraints can have some + deferrable and some non-deferrable triggers. +

Note: pg_class.relhastriggers + must be true if a relation has any triggers in this catalog. +


PrevHomeNext
pg_tablespaceUppg_ts_config
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-ts-config-map.html b/doc/src/sgml/html/catalog-pg-ts-config-map.html new file mode 100644 index 000000000..1c90b6b79 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-ts-config-map.html @@ -0,0 +1,311 @@ + +pg_ts_config_map
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.46. pg_ts_config_map

The pg_ts_config_map catalog contains entries + showing which text search dictionaries should be consulted, and in + what order, for each output token type of each text search configuration's + parser. +

PostgreSQL's text search features are + described at length in Chapter 12. +

Table 45-46. pg_ts_config_map Columns

NameTypeReferencesDescription
mapcfgoidpg_ts_config.oidThe OID of the pg_ts_config entry owning this map entry
maptokentypeinteger A token type emitted by the configuration's parser
mapseqnointeger Order in which to consult this entry (lower + mapseqnos first)
mapdictoidpg_ts_dict.oidThe OID of the text search dictionary to consult

PrevHomeNext
pg_ts_configUppg_ts_dict
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-ts-config.html b/doc/src/sgml/html/catalog-pg-ts-config.html new file mode 100644 index 000000000..db33da446 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-ts-config.html @@ -0,0 +1,325 @@ + +pg_ts_config
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.45. pg_ts_config

The pg_ts_config catalog contains entries + representing text search configurations. A configuration specifies + a particular text search parser and a list of dictionaries to use + for each of the parser's output token types. The parser is shown + in the pg_ts_config entry, but the + token-to-dictionary mapping is defined by subsidiary entries in pg_ts_config_map. +

PostgreSQL's text search features are + described at length in Chapter 12. +

Table 45-45. pg_ts_config Columns

NameTypeReferencesDescription
cfgnamename Text search configuration name
cfgnamespaceoidpg_namespace.oid The OID of the namespace that contains this configuration +
cfgowneroidpg_authid.oidOwner of the configuration
cfgparseroidpg_ts_parser.oidThe OID of the text search parser for this configuration

PrevHomeNext
pg_triggerUppg_ts_config_map
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-ts-dict.html b/doc/src/sgml/html/catalog-pg-ts-dict.html new file mode 100644 index 000000000..0fdcaf10b --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-ts-dict.html @@ -0,0 +1,337 @@ + +pg_ts_dict
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.47. pg_ts_dict

The pg_ts_dict catalog contains entries + defining text search dictionaries. A dictionary depends on a text + search template, which specifies all the implementation functions + needed; the dictionary itself provides values for the user-settable + parameters supported by the template. This division of labor allows + dictionaries to be created by unprivileged users. The parameters + are specified by a text string dictinitoption, + whose format and meaning vary depending on the template. +

PostgreSQL's text search features are + described at length in Chapter 12. +

Table 45-47. pg_ts_dict Columns

NameTypeReferencesDescription
dictnamename Text search dictionary name
dictnamespaceoidpg_namespace.oid The OID of the namespace that contains this dictionary +
dictowneroidpg_authid.oidOwner of the dictionary
dicttemplateoidpg_ts_template.oidThe OID of the text search template for this dictionary
dictinitoptiontext Initialization option string for the template

PrevHomeNext
pg_ts_config_mapUppg_ts_parser
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-ts-parser.html b/doc/src/sgml/html/catalog-pg-ts-parser.html new file mode 100644 index 000000000..dcee847eb --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-ts-parser.html @@ -0,0 +1,390 @@ + +pg_ts_parser
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.48. pg_ts_parser

The pg_ts_parser catalog contains entries + defining text search parsers. A parser is responsible for splitting + input text into lexemes and assigning a token type to each lexeme. + Since a parser must be implemented by C-language-level functions, + creation of new parsers is restricted to database superusers. +

PostgreSQL's text search features are + described at length in Chapter 12. +

Table 45-48. pg_ts_parser Columns

NameTypeReferencesDescription
prsnamename Text search parser name
prsnamespaceoidpg_namespace.oid The OID of the namespace that contains this parser +
prsstartregprocpg_proc.oidOID of the parser's startup function
prstokenregprocpg_proc.oidOID of the parser's next-token function
prsendregprocpg_proc.oidOID of the parser's shutdown function
prsheadlineregprocpg_proc.oidOID of the parser's headline function
prslextyperegprocpg_proc.oidOID of the parser's lextype function

PrevHomeNext
pg_ts_dictUppg_ts_template
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-ts-template.html b/doc/src/sgml/html/catalog-pg-ts-template.html new file mode 100644 index 000000000..ca6a88fc8 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-ts-template.html @@ -0,0 +1,315 @@ + +pg_ts_template
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.49. pg_ts_template

The pg_ts_template catalog contains entries + defining text search templates. A template is the implementation + skeleton for a class of text search dictionaries. + Since a template must be implemented by C-language-level functions, + creation of new templates is restricted to database superusers. +

PostgreSQL's text search features are + described at length in Chapter 12. +

Table 45-49. pg_ts_template Columns

NameTypeReferencesDescription
tmplnamename Text search template name
tmplnamespaceoidpg_namespace.oid The OID of the namespace that contains this template +
tmplinitregprocpg_proc.oidOID of the template's initialization function
tmpllexizeregprocpg_proc.oidOID of the template's lexize function

PrevHomeNext
pg_ts_parserUppg_type
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-type.html b/doc/src/sgml/html/catalog-pg-type.html new file mode 100644 index 000000000..4f26f100e --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-type.html @@ -0,0 +1,1454 @@ + +pg_type
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.50. pg_type

The catalog pg_type stores information about data + types. Base types and enum types (scalar types) are created with + CREATE TYPE, and + domains with + CREATE DOMAIN. + A composite type is automatically created for each table in the database, to + represent the row structure of the table. It is also possible to create + composite types with CREATE TYPE AS. +

Table 45-50. pg_type Columns

NameTypeReferencesDescription
typnamename Data type name
typnamespaceoidpg_namespace.oid The OID of the namespace that contains this type +
typowneroidpg_authid.oidOwner of the type
typlenint2  For a fixed-size type, typlen is the number + of bytes in the internal representation of the type. But for a + variable-length type, typlen is negative. + -1 indicates a "varlena" type (one that has a length word), + -2 indicates a null-terminated C string. +
typbyvalbool  typbyval determines whether internal + routines pass a value of this type by value or by reference. + typbyval had better be false if + typlen is not 1, 2, or 4 (or 8 on machines + where Datum is 8 bytes). + Variable-length types are always passed by reference. Note that + typbyval can be false even if the + length would allow pass-by-value. +
typtypechar  typtype is + b for a base type, + c for a composite type (e.g., a table's row type), + d for a domain, + e for an enum type, + p for a pseudo-type, or + r for a range type. + See also typrelid and + typbasetype. +
typcategorychar  typcategory is an arbitrary classification + of data types that is used by the parser to determine which implicit + casts should be "preferred". + See Table 45-51. +
typispreferredbool  True if the type is a preferred cast target within its + typcategory +
typisdefinedbool  True if the type is defined, false if this is a placeholder + entry for a not-yet-defined type. When + typisdefined is false, nothing + except the type name, namespace, and OID can be relied on. +
typdelimchar  Character that separates two values of this type when parsing + array input. Note that the delimiter is associated with the array + element data type, not the array data type. +
typrelidoidpg_class.oid If this is a composite type (see + typtype), then this column points to + the pg_class entry that defines the + corresponding table. (For a free-standing composite type, the + pg_class entry doesn't really represent + a table, but it is needed anyway for the type's + pg_attribute entries to link to.) + Zero for non-composite types. +
typelemoidpg_type.oid If typelem is not 0 then it + identifies another row in pg_type. + The current type can then be subscripted like an array yielding + values of type typelem. A + "true" array type is variable length + (typlen = -1), + but some fixed-length (typlen > 0) types + also have nonzero typelem, for example + name and point. + If a fixed-length type has a typelem then + its internal representation must be some number of values of the + typelem data type with no other data. + Variable-length array types have a header defined by the array + subroutines. +
typarrayoidpg_type.oid If typarray is not 0 then it + identifies another row in pg_type, which + is the "true" array type having this type as element +
typinputregprocpg_proc.oidInput conversion function (text format)
typoutputregprocpg_proc.oidOutput conversion function (text format)
typreceiveregprocpg_proc.oidInput conversion function (binary format), or 0 if none
typsendregprocpg_proc.oidOutput conversion function (binary format), or 0 if none
typmodinregprocpg_proc.oidType modifier input function, or 0 if type does not support modifiers
typmodoutregprocpg_proc.oidType modifier output function, or 0 to use the standard format
typanalyzeregprocpg_proc.oidCustom ANALYZE function, or 0 to use the standard function
typalignchar 

typalign is the alignment required + when storing a value of this type. It applies to storage on + disk as well as most representations of the value inside + PostgreSQL. + When multiple values are stored consecutively, such + as in the representation of a complete row on disk, padding is + inserted before a datum of this type so that it begins on the + specified boundary. The alignment reference is the beginning + of the first datum in the sequence. +

+ +

Possible values are: +

  • c = char alignment, i.e., no alignment needed.

  • s = short alignment (2 bytes on most machines).

  • i = int alignment (4 bytes on most machines).

  • d = double alignment (8 bytes on many machines, but by no means all).

+

Note: For types used in system tables, it is critical that the size + and alignment defined in pg_type + agree with the way that the compiler will lay out the column in + a structure representing a table row. +

typstoragechar 

typstorage tells for varlena + types (those with typlen = -1) if + the type is prepared for toasting and what the default strategy + for attributes of this type should be. + Possible values are +

  • p: Value must always be stored plain.

  • e: Value can be stored in a "secondary" + relation (if relation has one, see + pg_class.reltoastrelid). +

  • m: Value can be stored compressed inline.

  • x: Value can be stored compressed inline or stored in "secondary" storage.

+ Note that m columns can also be moved out to secondary + storage, but only as a last resort (e and x columns are + moved first). +

typnotnullbool 

typnotnull represents a not-null + constraint on a type. Used for domains only. +

typbasetypeoidpg_type.oid

If this is a domain (see typtype), then + typbasetype identifies the type that this + one is based on. Zero if this type is not a domain. +

typtypmodint4 

Domains use typtypmod to record the typmod + to be applied to their base type (-1 if base type does not use a + typmod). -1 if this type is not a domain. +

typndimsint4 

typndims is the number of array dimensions + for a domain over an array (that is, typbasetype is + an array type). + Zero for types other than domains over array types. +

typcollationoidpg_collation.oid

typcollation specifies the collation + of the type. If the type does not support collations, this will + be zero. A base type that supports collations will have + DEFAULT_COLLATION_OID here. A domain over a + collatable type can have some other collation OID, if one was + specified for the domain. +

typdefaultbinpg_node_tree 

If typdefaultbin is not null, it is the + nodeToString() + representation of a default expression for the type. This is + only used for domains. +

typdefaulttext 

typdefault is null if the type has no associated + default value. If typdefaultbin is not null, + typdefault must contain a human-readable version of the + default expression represented by typdefaultbin. If + typdefaultbin is null and typdefault is + not, then typdefault is the external representation of + the type's default value, which can be fed to the type's input + converter to produce a constant. +

typaclaclitem[]  Access privileges; see + GRANT and + REVOKE + for details +

Table 45-51 lists the system-defined values + of typcategory. Any future additions to this list will + also be upper-case ASCII letters. All other ASCII characters are reserved + for user-defined categories. +

Table 45-51. typcategory Codes

CodeCategory
AArray types
BBoolean types
CComposite types
DDate/time types
EEnum types
GGeometric types
INetwork address types
NNumeric types
PPseudo-types
RRange types
SString types
TTimespan types
UUser-defined types
VBit-string types
Xunknown type

PrevHomeNext
pg_ts_templateUppg_user_mapping
\ No newline at end of file diff --git a/doc/src/sgml/html/catalog-pg-user-mapping.html b/doc/src/sgml/html/catalog-pg-user-mapping.html new file mode 100644 index 000000000..ec9fa5577 --- /dev/null +++ b/doc/src/sgml/html/catalog-pg-user-mapping.html @@ -0,0 +1,287 @@ + +pg_user_mapping
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.51. pg_user_mapping

The catalog pg_user_mapping stores + the mappings from local user to remote. Access to this catalog is + restricted from normal users, use the view + pg_user_mappings + instead. +

Table 45-52. pg_user_mapping Columns

NameTypeReferencesDescription
umuseroidpg_authid.oidOID of the local role being mapped, 0 if the user mapping is public
umserveroidpg_foreign_server.oid The OID of the foreign server that contains this mapping +
umoptionstext[]  User mapping specific options, as "keyword=value" strings +

PrevHomeNext
pg_typeUpSystem Views
\ No newline at end of file diff --git a/doc/src/sgml/html/catalogs-overview.html b/doc/src/sgml/html/catalogs-overview.html new file mode 100644 index 000000000..1423b2a4f --- /dev/null +++ b/doc/src/sgml/html/catalogs-overview.html @@ -0,0 +1,809 @@ + +Overview
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.1. Overview

Table 45-1 lists the system catalogs. + More detailed documentation of each catalog follows below. +

Most system catalogs are copied from the template database during + database creation and are thereafter database-specific. A few + catalogs are physically shared across all databases in a cluster; + these are noted in the descriptions of the individual catalogs. +

Table 45-1. System Catalogs

Catalog NamePurpose
pg_aggregateaggregate functions
pg_amindex access methods
pg_amopaccess method operators
pg_amprocaccess method support procedures
pg_attrdefcolumn default values
pg_attributetable columns ("attributes")
pg_authidauthorization identifiers (roles)
pg_auth_membersauthorization identifier membership relationships
pg_castcasts (data type conversions)
pg_classtables, indexes, sequences, views ("relations")
pg_constraintcheck constraints, unique constraints, primary key constraints, foreign key constraints
pg_collationcollations (locale information)
pg_conversionencoding conversion information
pg_databasedatabases within this database cluster
pg_db_role_settingper-role and per-database settings
pg_default_acldefault privileges for object types
pg_dependdependencies between database objects
pg_descriptiondescriptions or comments on database objects
pg_enumenum label and value definitions
pg_extensioninstalled extensions
pg_foreign_data_wrapperforeign-data wrapper definitions
pg_foreign_serverforeign server definitions
pg_foreign_tableadditional foreign table information
pg_indexadditional index information
pg_inheritstable inheritance hierarchy
pg_languagelanguages for writing functions
pg_largeobjectdata pages for large objects
pg_largeobject_metadatametadata for large objects
pg_namespaceschemas
pg_opclassaccess method operator classes
pg_operatoroperators
pg_opfamilyaccess method operator families
pg_pltemplatetemplate data for procedural languages
pg_procfunctions and procedures
pg_rangeinformation about range types
pg_rewritequery rewrite rules
pg_seclabelsecurity labels on database objects
pg_shdependdependencies on shared objects
pg_shdescriptioncomments on shared objects
pg_shseclabelsecurity labels on shared database objects
pg_statisticplanner statistics
pg_tablespacetablespaces within this database cluster
pg_triggertriggers
pg_ts_configtext search configurations
pg_ts_config_maptext search configurations' token mappings
pg_ts_dicttext search dictionaries
pg_ts_parsertext search parsers
pg_ts_templatetext search templates
pg_typedata types
pg_user_mappingmappings of users to foreign servers

PrevHomeNext
System CatalogsUppg_aggregate
\ No newline at end of file diff --git a/doc/src/sgml/html/catalogs.html b/doc/src/sgml/html/catalogs.html new file mode 100644 index 000000000..7efd41317 --- /dev/null +++ b/doc/src/sgml/html/catalogs.html @@ -0,0 +1,764 @@ + +System Catalogs

Chapter 45. System Catalogs

Table of Contents
45.1. Overview
45.2. pg_aggregate
45.3. pg_am
45.4. pg_amop
45.5. pg_amproc
45.6. pg_attrdef
45.7. pg_attribute
45.8. pg_authid
45.9. pg_auth_members
45.10. pg_cast
45.11. pg_class
45.12. pg_constraint
45.13. pg_collation
45.14. pg_conversion
45.15. pg_database
45.16. pg_db_role_setting
45.17. pg_default_acl
45.18. pg_depend
45.19. pg_description
45.20. pg_enum
45.21. pg_extension
45.22. pg_foreign_data_wrapper
45.23. pg_foreign_server
45.24. pg_foreign_table
45.25. pg_index
45.26. pg_inherits
45.27. pg_language
45.28. pg_largeobject
45.29. pg_largeobject_metadata
45.30. pg_namespace
45.31. pg_opclass
45.32. pg_operator
45.33. pg_opfamily
45.34. pg_pltemplate
45.35. pg_proc
45.36. pg_range
45.37. pg_rewrite
45.38. pg_seclabel
45.39. pg_shdepend
45.40. pg_shdescription
45.41. pg_shseclabel
45.42. pg_statistic
45.43. pg_tablespace
45.44. pg_trigger
45.45. pg_ts_config
45.46. pg_ts_config_map
45.47. pg_ts_dict
45.48. pg_ts_parser
45.49. pg_ts_template
45.50. pg_type
45.51. pg_user_mapping
45.52. System Views
45.53. pg_available_extensions
45.54. pg_available_extension_versions
45.55. pg_cursors
45.56. pg_group
45.57. pg_indexes
45.58. pg_locks
45.59. pg_prepared_statements
45.60. pg_prepared_xacts
45.61. pg_roles
45.62. pg_rules
45.63. pg_seclabels
45.64. pg_settings
45.65. pg_shadow
45.66. pg_stats
45.67. pg_tables
45.68. pg_timezone_abbrevs
45.69. pg_timezone_names
45.70. pg_user
45.71. pg_user_mappings
45.72. pg_views

The system catalogs are the place where a relational database + management system stores schema metadata, such as information about + tables and columns, and internal bookkeeping information. + PostgreSQL's system catalogs are regular + tables. You can drop and recreate the tables, add columns, insert + and update values, and severely mess up your system that way. + Normally, one should not change the system catalogs by hand, there + are always SQL commands to do that. (For example, CREATE + DATABASE inserts a row into the + pg_database catalog — and actually + creates the database on disk.) There are some exceptions for + particularly esoteric operations, such as adding index access methods. +


PrevHomeNext
ExecutorUpOverview
\ No newline at end of file diff --git a/doc/src/sgml/html/charset.html b/doc/src/sgml/html/charset.html new file mode 100644 index 000000000..3a5c15e49 --- /dev/null +++ b/doc/src/sgml/html/charset.html @@ -0,0 +1,284 @@ + +Localization

Chapter 22. Localization

This chapter describes the available localization features from the + point of view of the administrator. + PostgreSQL supports two localization + facilities: + +

  • Using the locale features of the operating system to provide + locale-specific collation order, number formatting, translated + messages, and other aspects. + This is covered in Section 22.1 and + Section 22.2. +

  • Providing a number of different character sets to support storing text + in all kinds of languages, and providing character set translation + between client and server. + This is covered in Section 22.3. +

+


PrevHomeNext
TablespacesUpLocale Support
\ No newline at end of file diff --git a/doc/src/sgml/html/chkpass.html b/doc/src/sgml/html/chkpass.html new file mode 100644 index 000000000..19f618676 --- /dev/null +++ b/doc/src/sgml/html/chkpass.html @@ -0,0 +1,262 @@ + +chkpass
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.6. chkpass

This module implements a data type chkpass that is + designed for storing encrypted passwords. + Each password is automatically converted to encrypted form upon entry, + and is always stored encrypted. To compare, simply compare against a clear + text password and the comparison function will encrypt it before comparing. +

There are provisions in the code to report an error if the password is + determined to be easily crackable. However, this is currently just + a stub that does nothing. +

If you precede an input string with a colon, it is assumed to be an + already-encrypted password, and is stored without further encryption. + This allows entry of previously-encrypted passwords. +

On output, a colon is prepended. This makes it possible to dump and reload + passwords without re-encrypting them. If you want the encrypted password + without the colon then use the raw() function. + This allows you to use the + type with things like Apache's Auth_PostgreSQL module. +

The encryption uses the standard Unix function crypt(), + and so it suffers + from all the usual limitations of that function; notably that only the + first eight characters of a password are considered. +

Note that the chkpass data type is not indexable. + +

Sample usage: +

test=# create table test (p chkpass);
+CREATE TABLE
+test=# insert into test values ('hello');
+INSERT 0 1
+test=# select * from test;
+       p
+----------------
+ :dVGkpXdOrE3ko
+(1 row)
+
+test=# select raw(p) from test;
+      raw
+---------------
+ dVGkpXdOrE3ko
+(1 row)
+
+test=# select p = 'hello' from test;
+ ?column?
+----------
+ t
+(1 row)
+
+test=# select p = 'goodbye' from test;
+ ?column?
+----------
+ f
+(1 row)

F.6.1. Author

D'Arcy J.M. Cain (<darcy@druid.net>) +


PrevHomeNext
btree_gistUpcitext
\ No newline at end of file diff --git a/doc/src/sgml/html/citext.html b/doc/src/sgml/html/citext.html new file mode 100644 index 000000000..fd43daab0 --- /dev/null +++ b/doc/src/sgml/html/citext.html @@ -0,0 +1,633 @@ + +citext
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.7. citext

The citext module provides a case-insensitive + character string type, citext. Essentially, it internally calls + lower when comparing values. Otherwise, it behaves almost + exactly like text. +

F.7.1. Rationale

The standard approach to doing case-insensitive matches + in PostgreSQL has been to use the lower + function when comparing values, for example + +

SELECT * FROM tab WHERE lower(col) = LOWER(?);

+

This works reasonably well, but has a number of drawbacks: +

  • It makes your SQL statements verbose, and you always have to remember to + use lower on both the column and the query value. +

  • It won't use an index, unless you create a functional index using + lower. +

  • If you declare a column as UNIQUE or PRIMARY + KEY, the implicitly generated index is case-sensitive. So it's + useless for case-insensitive searches, and it won't enforce + uniqueness case-insensitively. +

The citext data type allows you to eliminate calls + to lower in SQL queries, and allows a primary key to + be case-insensitive. citext is locale-aware, just + like text, which means that the matching of upper case and + lower case characters is dependent on the rules of + the database's LC_CTYPE setting. Again, this behavior is + identical to the use of lower in queries. But because it's + done transparently by the data type, you don't have to remember to do + anything special in your queries. +

F.7.2. How to Use It

Here's a simple example of usage: + +

CREATE TABLE users (
+    nick CITEXT PRIMARY KEY,
+    pass TEXT   NOT NULL
+);
+
+INSERT INTO users VALUES ( 'larry',  md5(random()::text) );
+INSERT INTO users VALUES ( 'Tom',    md5(random()::text) );
+INSERT INTO users VALUES ( 'Damian', md5(random()::text) );
+INSERT INTO users VALUES ( 'NEAL',   md5(random()::text) );
+INSERT INTO users VALUES ( 'Bjørn',  md5(random()::text) );
+
+SELECT * FROM users WHERE nick = 'Larry';

+ + The SELECT statement will return one tuple, even though + the nick column was set to larry and the query + was for Larry. +

F.7.3. String Comparison Behavior

citext performs comparisons by converting each string to lower + case (as though lower were called) and then comparing the + results normally. Thus, for example, two strings are considered equal + if lower would produce identical results for them. +

In order to emulate a case-insensitive collation as closely as possible, + there are citext-specific versions of a number of string-processing + operators and functions. So, for example, the regular expression + operators ~ and ~* exhibit the same behavior when + applied to citext: they both match case-insensitively. + The same is true + for !~ and !~*, as well as for the + LIKE operators ~~ and ~~*, and + !~~ and !~~*. If you'd like to match + case-sensitively, you can cast the operator's arguments to text. +

Similarly, all of the following functions perform matching + case-insensitively if their arguments are citext: +

  • regexp_replace() +

  • regexp_split_to_array() +

  • regexp_split_to_table() +

  • replace() +

  • split_part() +

  • strpos() +

  • translate() +

For the regexp functions, if you want to match case-sensitively, you can + specify the "c" flag to force a case-sensitive match. Otherwise, + you must cast to text before using one of these functions if + you want case-sensitive behavior. +

F.7.4. Limitations

  • citext's case-folding behavior depends on + the LC_CTYPE setting of your database. How it compares + values is therefore determined when the database is created. + It is not truly + case-insensitive in the terms defined by the Unicode standard. + Effectively, what this means is that, as long as you're happy with your + collation, you should be happy with citext's comparisons. But + if you have data in different languages stored in your database, users + of one language may find their query results are not as expected if the + collation is for another language. +

  • As of PostgreSQL 9.1, you can attach a + COLLATE specification to citext columns or data + values. Currently, citext operators will honor a non-default + COLLATE specification while comparing case-folded strings, + but the initial folding to lower case is always done according to the + database's LC_CTYPE setting (that is, as though + COLLATE "default" were given). This may be changed in a + future release so that both steps follow the input COLLATE + specification. +

  • citext is not as efficient as text because the + operator functions and the B-tree comparison functions must make copies + of the data and convert it to lower case for comparisons. It is, + however, slightly more efficient than using lower to get + case-insensitive matching. +

  • citext doesn't help much if you need data to compare + case-sensitively in some contexts and case-insensitively in other + contexts. The standard answer is to use the text type and + manually use the lower function when you need to compare + case-insensitively; this works all right if case-insensitive comparison + is needed only infrequently. If you need case-insensitive behavior most + of the time and case-sensitive infrequently, consider storing the data + as citext and explicitly casting the column to text + when you want case-sensitive comparison. In either situation, you will + need two indexes if you want both types of searches to be fast. +

  • The schema containing the citext operators must be + in the current search_path (typically public); + if it is not, the normal case-sensitive text operators + will be invoked instead. +

F.7.5. Author

David E. Wheeler <david@kineticode.com> +

Inspired by the original citext module by Donald Fraser. +


PrevHomeNext
chkpassUpcube
\ No newline at end of file diff --git a/doc/src/sgml/html/client-authentication-problems.html b/doc/src/sgml/html/client-authentication-problems.html new file mode 100644 index 000000000..90d343c2a --- /dev/null +++ b/doc/src/sgml/html/client-authentication-problems.html @@ -0,0 +1,225 @@ + +Authentication Problems
PostgreSQL 9.2.2 Documentation
PrevUpChapter 19. Client AuthenticationNext

19.4. Authentication Problems

Authentication failures and related problems generally + manifest themselves through error messages like the following: +

FATAL:  no pg_hba.conf entry for host "123.123.123.123", user "andym", database "testdb"

+ This is what you are most likely to get if you succeed in contacting + the server, but it does not want to talk to you. As the message + suggests, the server refused the connection request because it found + no matching entry in its pg_hba.conf + configuration file. +

FATAL:  password authentication failed for user "andym"

+ Messages like this indicate that you contacted the server, and it is + willing to talk to you, but not until you pass the authorization + method specified in the pg_hba.conf file. Check + the password you are providing, or check your Kerberos or ident + software if the complaint mentions one of those authentication + types. +

FATAL:  user "andym" does not exist

+ The indicated database user name was not found. +

FATAL:  database "testdb" does not exist

+ The database you are trying to connect to does not exist. Note that + if you do not specify a database name, it defaults to the database + user name, which might or might not be the right thing. +

Tip: The server log might contain more information about an + authentication failure than is reported to the client. If you are + confused about the reason for a failure, check the server log. +


PrevHomeNext
Authentication MethodsUpDatabase Roles
\ No newline at end of file diff --git a/doc/src/sgml/html/client-authentication.html b/doc/src/sgml/html/client-authentication.html new file mode 100644 index 000000000..a2c19dc87 --- /dev/null +++ b/doc/src/sgml/html/client-authentication.html @@ -0,0 +1,337 @@ + +Client Authentication

Chapter 19. Client Authentication

When a client application connects to the database server, it + specifies which PostgreSQL database user name it + wants to connect as, much the same way one logs into a Unix computer + as a particular user. Within the SQL environment the active database + user name determines access privileges to database objects — see + Chapter 20 for more information. Therefore, it is + essential to restrict which database users can connect. +

Note: As explained in Chapter 20, + PostgreSQL actually does privilege + management in terms of "roles". In this chapter, we + consistently use database user to mean "role with the + LOGIN privilege". +

Authentication is the process by which the + database server establishes the identity of the client, and by + extension determines whether the client application (or the user + who runs the client application) is permitted to connect with the + database user name that was requested. +

PostgreSQL offers a number of different + client authentication methods. The method used to authenticate a + particular client connection can be selected on the basis of + (client) host address, database, and user. +

PostgreSQL database user names are logically + separate from user names of the operating system in which the server + runs. If all the users of a particular server also have accounts on + the server's machine, it makes sense to assign database user names + that match their operating system user names. However, a server that + accepts remote connections might have many database users who have no local + operating system + account, and in such cases there need be no connection between + database user names and OS user names. +


PrevHomeNext
Short OptionsUpThe pg_hba.conf File
\ No newline at end of file diff --git a/doc/src/sgml/html/client-interfaces.html b/doc/src/sgml/html/client-interfaces.html new file mode 100644 index 000000000..54f6e66b1 --- /dev/null +++ b/doc/src/sgml/html/client-interfaces.html @@ -0,0 +1,965 @@ + +Client Interfaces

IV. Client Interfaces

This part describes the client programming interfaces distributed + with PostgreSQL. Each of these chapters can be + read independently. Note that there are many other programming + interfaces for client programs that are distributed separately and + contain their own documentation (Appendix H + lists some of the more popular ones). Readers of this part should be + familiar with using SQL commands to manipulate + and query the database (see Part II) and of course + with the programming language that the interface uses. +

Table of Contents
31. libpq - C Library
31.1. Database Connection Control Functions
31.2. Connection Status Functions
31.3. Command Execution Functions
31.4. Asynchronous Command Processing
31.5. Retrieving Query Results Row-By-Row
31.6. Canceling Queries in Progress
31.7. The Fast-Path Interface
31.8. Asynchronous Notification
31.9. Functions Associated with the COPY Command
31.10. Control Functions
31.11. Miscellaneous Functions
31.12. Notice Processing
31.13. Event System
31.14. Environment Variables
31.15. The Password File
31.16. The Connection Service File
31.17. LDAP Lookup of Connection Parameters
31.18. SSL Support
31.19. Behavior in Threaded Programs
31.20. Building libpq Programs
31.21. Example Programs
32. Large Objects
32.1. Introduction
32.2. Implementation Features
32.3. Client Interfaces
32.4. Server-side Functions
32.5. Example Program
33. ECPG - Embedded SQL in C
33.1. The Concept
33.2. Managing Database Connections
33.3. Running SQL Commands
33.4. Using Host Variables
33.5. Dynamic SQL
33.6. pgtypes Library
33.7. Using Descriptor Areas
33.8. Error Handling
33.9. Preprocessor Directives
33.10. Processing Embedded SQL Programs
33.11. Library Functions
33.12. Large Objects
33.13. C++ Applications
33.14. Embedded SQL Commands
33.15. Informix Compatibility Mode
33.16. Internals
34. The Information Schema
34.1. The Schema
34.2. Data Types
34.3. information_schema_catalog_name
34.4. administrable_role_authorizations
34.5. applicable_roles
34.6. attributes
34.7. character_sets
34.8. check_constraint_routine_usage
34.9. check_constraints
34.10. collations
34.11. collation_character_set_applicability
34.12. column_domain_usage
34.13. column_options
34.14. column_privileges
34.15. column_udt_usage
34.16. columns
34.17. constraint_column_usage
34.18. constraint_table_usage
34.19. data_type_privileges
34.20. domain_constraints
34.21. domain_udt_usage
34.22. domains
34.23. element_types
34.24. enabled_roles
34.25. foreign_data_wrapper_options
34.26. foreign_data_wrappers
34.27. foreign_server_options
34.28. foreign_servers
34.29. foreign_table_options
34.30. foreign_tables
34.31. key_column_usage
34.32. parameters
34.33. referential_constraints
34.34. role_column_grants
34.35. role_routine_grants
34.36. role_table_grants
34.37. role_udt_grants
34.38. role_usage_grants
34.39. routine_privileges
34.40. routines
34.41. schemata
34.42. sequences
34.43. sql_features
34.44. sql_implementation_info
34.45. sql_languages
34.46. sql_packages
34.47. sql_parts
34.48. sql_sizing
34.49. sql_sizing_profiles
34.50. table_constraints
34.51. table_privileges
34.52. tables
34.53. triggered_update_columns
34.54. triggers
34.55. udt_privileges
34.56. usage_privileges
34.57. user_defined_types
34.58. user_mapping_options
34.59. user_mappings
34.60. view_column_usage
34.61. view_routine_usage
34.62. view_table_usage
34.63. views

PrevHomeNext
Test Coverage Examination libpq - C Library
\ No newline at end of file diff --git a/doc/src/sgml/html/collation.html b/doc/src/sgml/html/collation.html new file mode 100644 index 000000000..cb5b463f7 --- /dev/null +++ b/doc/src/sgml/html/collation.html @@ -0,0 +1,632 @@ + +Collation Support

22.2. Collation Support

The collation feature allows specifying the sort order and character + classification behavior of data per-column, or even per-operation. + This alleviates the restriction that the + LC_COLLATE and LC_CTYPE settings + of a database cannot be changed after its creation. +

22.2.1. Concepts

Conceptually, every expression of a collatable data type has a + collation. (The built-in collatable data types are + text, varchar, and char. + User-defined base types can also be marked collatable, and of course + a domain over a collatable data type is collatable.) If the + expression is a column reference, the collation of the expression is the + defined collation of the column. If the expression is a constant, the + collation is the default collation of the data type of the + constant. The collation of a more complex expression is derived + from the collations of its inputs, as described below. +

The collation of an expression can be the "default" + collation, which means the locale settings defined for the + database. It is also possible for an expression's collation to be + indeterminate. In such cases, ordering operations and other + operations that need to know the collation will fail. +

When the database system has to perform an ordering or a character + classification, it uses the collation of the input expression. This + happens, for example, with ORDER BY clauses + and function or operator calls such as <. + The collation to apply for an ORDER BY clause + is simply the collation of the sort key. The collation to apply for a + function or operator call is derived from the arguments, as described + below. In addition to comparison operators, collations are taken into + account by functions that convert between lower and upper case + letters, such as lower, upper, and + initcap; by pattern matching operators; and by + to_char and related functions. +

For a function or operator call, the collation that is derived by + examining the argument collations is used at run time for performing + the specified operation. If the result of the function or operator + call is of a collatable data type, the collation is also used at parse + time as the defined collation of the function or operator expression, + in case there is a surrounding expression that requires knowledge of + its collation. +

The collation derivation of an expression can be + implicit or explicit. This distinction affects how collations are + combined when multiple different collations appear in an + expression. An explicit collation derivation occurs when a + COLLATE clause is used; all other collation + derivations are implicit. When multiple collations need to be + combined, for example in a function call, the following rules are + used: + +

  1. If any input expression has an explicit collation derivation, then + all explicitly derived collations among the input expressions must be + the same, otherwise an error is raised. If any explicitly + derived collation is present, that is the result of the + collation combination. +

  2. Otherwise, all input expressions must have the same implicit + collation derivation or the default collation. If any non-default + collation is present, that is the result of the collation combination. + Otherwise, the result is the default collation. +

  3. If there are conflicting non-default implicit collations among the + input expressions, then the combination is deemed to have indeterminate + collation. This is not an error condition unless the particular + function being invoked requires knowledge of the collation it should + apply. If it does, an error will be raised at run-time. +

+ + For example, consider this table definition: +

CREATE TABLE test1 (
+    a text COLLATE "de_DE",
+    b text COLLATE "es_ES",
+    ...
+);

+ + Then in +

SELECT a < 'foo' FROM test1;

+ the < comparison is performed according to + de_DE rules, because the expression combines an + implicitly derived collation with the default collation. But in +

SELECT a < ('foo' COLLATE "fr_FR") FROM test1;

+ the comparison is performed using fr_FR rules, + because the explicit collation derivation overrides the implicit one. + Furthermore, given +

SELECT a < b FROM test1;

+ the parser cannot determine which collation to apply, since the + a and b columns have conflicting + implicit collations. Since the < operator + does need to know which collation to use, this will result in an + error. The error can be resolved by attaching an explicit collation + specifier to either input expression, thus: +

SELECT a < b COLLATE "de_DE" FROM test1;

+ or equivalently +

SELECT a COLLATE "de_DE" < b FROM test1;

+ On the other hand, the structurally similar case +

SELECT a || b FROM test1;

+ does not result in an error, because the || operator + does not care about collations: its result is the same regardless + of the collation. +

The collation assigned to a function or operator's combined input + expressions is also considered to apply to the function or operator's + result, if the function or operator delivers a result of a collatable + data type. So, in +

SELECT * FROM test1 ORDER BY a || 'foo';

+ the ordering will be done according to de_DE rules. + But this query: +

SELECT * FROM test1 ORDER BY a || b;

+ results in an error, because even though the || operator + doesn't need to know a collation, the ORDER BY clause does. + As before, the conflict can be resolved with an explicit collation + specifier: +

SELECT * FROM test1 ORDER BY a || b COLLATE "fr_FR";

+

22.2.2. Managing Collations

A collation is an SQL schema object that maps an SQL name to + operating system locales. In particular, it maps to a combination + of LC_COLLATE and LC_CTYPE. (As + the name would suggest, the main purpose of a collation is to set + LC_COLLATE, which controls the sort order. But + it is rarely necessary in practice to have an + LC_CTYPE setting that is different from + LC_COLLATE, so it is more convenient to collect + these under one concept than to create another infrastructure for + setting LC_CTYPE per expression.) Also, a collation + is tied to a character set encoding (see Section 22.3). + The same collation name may exist for different encodings. +

On all platforms, the collations named default, + C, and POSIX are available. Additional + collations may be available depending on operating system support. + The default collation selects the LC_COLLATE + and LC_CTYPE values specified at database creation time. + The C and POSIX collations both specify + "traditional C" behavior, in which only the ASCII letters + "A" through "Z" + are treated as letters, and sorting is done strictly by character + code byte values. +

If the operating system provides support for using multiple locales + within a single program (newlocale and related functions), + then when a database cluster is initialized, initdb + populates the system catalog pg_collation with + collations based on all the locales it finds on the operating + system at the time. For example, the operating system might + provide a locale named de_DE.utf8. + initdb would then create a collation named + de_DE.utf8 for encoding UTF8 + that has both LC_COLLATE and + LC_CTYPE set to de_DE.utf8. + It will also create a collation with the .utf8 + tag stripped off the name. So you could also use the collation + under the name de_DE, which is less cumbersome + to write and makes the name less encoding-dependent. Note that, + nevertheless, the initial set of collation names is + platform-dependent. +

In case a collation is needed that has different values for + LC_COLLATE and LC_CTYPE, a new + collation may be created using + the CREATE COLLATION command. That command + can also be used to create a new collation from an existing + collation, which can be useful to be able to use + operating-system-independent collation names in applications. +

Within any particular database, only collations that use that + database's encoding are of interest. Other entries in + pg_collation are ignored. Thus, a stripped collation + name such as de_DE can be considered unique + within a given database even though it would not be unique globally. + Use of the stripped collation names is recommended, since it will + make one less thing you need to change if you decide to change to + another database encoding. Note however that the default, + C, and POSIX collations can be used + regardless of the database encoding. +

PostgreSQL considers distinct collation + objects to be incompatible even when they have identical properties. + Thus for example, +

SELECT a COLLATE "C" < b COLLATE "POSIX" FROM test1;

+ will draw an error even though the C and POSIX + collations have identical behaviors. Mixing stripped and non-stripped + collation names is therefore not recommended. +


PrevHomeNext
Locale SupportUpCharacter Set Support
\ No newline at end of file diff --git a/doc/src/sgml/html/config-setting.html b/doc/src/sgml/html/config-setting.html new file mode 100644 index 000000000..14b14f1f6 --- /dev/null +++ b/doc/src/sgml/html/config-setting.html @@ -0,0 +1,528 @@ + +Setting Parameters
PostgreSQL 9.2.2 Documentation
PrevUpChapter 18. Server ConfigurationNext

18.1. Setting Parameters

18.1.1. Parameter Names and Values

All parameter names are case-insensitive. Every parameter takes a + value of one of five types: Boolean, integer, floating point, + string or enum. Boolean values can be written as on, + off, true, + false, yes, + no, 1, 0 + (all case-insensitive) or any unambiguous prefix of these. +

Some settings specify a memory or time value. Each of these has an + implicit unit, which is either kilobytes, blocks (typically eight + kilobytes), milliseconds, seconds, or minutes. Default units can be + found by referencing pg_settings.unit. + For convenience, + a different unit can also be specified explicitly. Valid memory units + are kB (kilobytes), MB + (megabytes), and GB (gigabytes); valid time units + are ms (milliseconds), s + (seconds), min (minutes), h + (hours), and d (days). Note that the multiplier + for memory units is 1024, not 1000. +

Parameters of type "enum" are specified in the same way as string + parameters, but are restricted to a limited set of values. The allowed + values can be found + from pg_settings.enumvals. + Enum parameter values are case-insensitive. +

18.1.2. Setting Parameters via the Configuration File

One way to set these parameters is to edit the file + postgresql.conf, + which is normally kept in the data directory. (A default copy is + installed there when the database cluster directory is + initialized.) An example of what this file might look like is: +

# This is a comment
+log_connections = yes
+log_destination = 'syslog'
+search_path = '"$user", public'
+shared_buffers = 128MB

+ One parameter is specified per line. The equal sign between name and + value is optional. Whitespace is insignificant and blank lines are + ignored. Hash marks (#) designate the remainder of the + line as a comment. Parameter values that are not simple identifiers or + numbers must be single-quoted. To embed a single quote in a parameter + value, write either two quotes (preferred) or backslash-quote. +

+ In addition to parameter settings, the postgresql.conf + file can contain include directives, which specify + another file to read and process as if it were inserted into the + configuration file at this point. This feature allows a configuration + file to be divided into physically separate parts. + Include directives simply look like: +

include 'filename'

+ If the file name is not an absolute path, it is taken as relative to + the directory containing the referencing configuration file. + Inclusions can be nested. +

+ There is also an include_if_exists directive, which acts + the same as the include directive, except for the behavior + when the referenced file does not exist or cannot be read. A regular + include will consider this an error condition, but + include_if_exists merely logs a message and continues + processing the referencing configuration file. +

+ The configuration file is reread whenever the main server process + receives a + SIGHUP signal (which is most easily sent by means + of pg_ctl reload). The main server process + also propagates this signal to all currently running server + processes so that existing sessions also get the new + value. Alternatively, you can send the signal to a single server + process directly. Some parameters can only be set at server start; + any changes to their entries in the configuration file will be ignored + until the server is restarted. Invalid parameter settings in the + configuration file are likewise ignored (but logged) during + SIGHUP processing. +

18.1.3. Other Ways to Set Parameters

A second way to set these configuration parameters is to give them + as a command-line option to the postgres command, + such as: +

postgres -c log_connections=yes -c log_destination='syslog'

+ Command-line options override any conflicting settings in + postgresql.conf. Note that this means you won't + be able to change the value on-the-fly by editing + postgresql.conf, so while the command-line + method might be convenient, it can cost you flexibility later. +

Occasionally it is useful to give a command line option to + one particular session only. The environment variable + PGOPTIONS can be used for this purpose on the + client side: +

env PGOPTIONS='-c geqo=off' psql

+ (This works for any libpq-based client application, not + just psql.) Note that this won't work for + parameters that are fixed when the server is started or that must be + specified in postgresql.conf. +

Furthermore, it is possible to assign a set of parameter settings to + a user or a database. Whenever a session is started, the default + settings for the user and database involved are loaded. The + commands ALTER ROLE + and ALTER DATABASE, + respectively, are used to configure these settings. Per-database + settings override anything received from the + postgres command-line or the configuration + file, and in turn are overridden by per-user settings; both are + overridden by per-session settings. +

Some parameters can be changed in individual SQL + sessions with the SET + command, for example: +

SET ENABLE_SEQSCAN TO OFF;

+ If SET is allowed, it overrides all other sources of + values for the parameter. Some parameters cannot be changed via + SET: for example, if they control behavior that + cannot be changed without restarting the entire + PostgreSQL server. Also, some parameters + require superuser permission to change via SET or + ALTER. +

18.1.4. Examining Parameter Settings

The SHOW + command allows inspection of the current values of all parameters. +

The virtual table pg_settings also allows + displaying and updating session run-time parameters; see Section 45.64 for details and a description of the + different variable types and when they can be changed. + pg_settings is equivalent to SHOW + and SET, but can be more convenient + to use because it can be joined with other tables, or selected from using + any desired selection condition. It also contains more information about + each parameter than is available from SHOW. +


PrevHomeNext
Server ConfigurationUpFile Locations
\ No newline at end of file diff --git a/doc/src/sgml/html/connect-estab.html b/doc/src/sgml/html/connect-estab.html new file mode 100644 index 000000000..1c33e2f48 --- /dev/null +++ b/doc/src/sgml/html/connect-estab.html @@ -0,0 +1,243 @@ + +How Connections are Established
PostgreSQL 9.2.2 Documentation
PrevUpChapter 44. Overview of PostgreSQL InternalsNext

44.2. How Connections are Established

PostgreSQL is implemented using a + simple "process per user" client/server model. In this model + there is one client process connected to + exactly one server process. As we do not + know ahead of time how many connections will be made, we have to + use a master process that spawns a new + server process every time a connection is requested. This master + process is called postgres and listens at a + specified TCP/IP port for incoming connections. Whenever a request + for a connection is detected the postgres + process spawns a new server process. The server tasks + communicate with each other using semaphores and + shared memory to ensure data integrity + throughout concurrent data access. +

The client process can be any program that understands the + PostgreSQL protocol described in + Chapter 46. Many clients are based on the + C-language library libpq, but several independent + implementations of the protocol exist, such as the Java + JDBC driver. +

Once a connection is established the client process can send a query + to the backend (server). The query is transmitted using plain text, + i.e., there is no parsing done in the frontend (client). The + server parses the query, creates an execution plan, + executes the plan and returns the retrieved rows to the client + by transmitting them over the established connection. +


PrevHomeNext
The Path of a QueryUpThe Parser Stage
\ No newline at end of file diff --git a/doc/src/sgml/html/continuous-archiving.html b/doc/src/sgml/html/continuous-archiving.html new file mode 100644 index 000000000..b3788cba0 --- /dev/null +++ b/doc/src/sgml/html/continuous-archiving.html @@ -0,0 +1,1772 @@ + +Continuous Archiving and Point-in-Time Recovery (PITR)
PostgreSQL 9.2.2 Documentation
PrevUpChapter 24. Backup and RestoreNext

24.3. Continuous Archiving and Point-in-Time Recovery (PITR)

At all times, PostgreSQL maintains a + write ahead log (WAL) in the pg_xlog/ + subdirectory of the cluster's data directory. The log records + every change made to the database's data files. This log exists + primarily for crash-safety purposes: if the system crashes, the + database can be restored to consistency by "replaying" the + log entries made since the last checkpoint. However, the existence + of the log makes it possible to use a third strategy for backing up + databases: we can combine a file-system-level backup with backup of + the WAL files. If recovery is needed, we restore the file system backup and + then replay from the backed-up WAL files to bring the system to a + current state. This approach is more complex to administer than + either of the previous approaches, but it has some significant + benefits: +

  • We do not need a perfectly consistent file system backup as the starting point. + Any internal inconsistency in the backup will be corrected by log + replay (this is not significantly different from what happens during + crash recovery). So we do not need a file system snapshot capability, + just tar or a similar archiving tool. +

  • Since we can combine an indefinitely long sequence of WAL files + for replay, continuous backup can be achieved simply by continuing to archive + the WAL files. This is particularly valuable for large databases, where + it might not be convenient to take a full backup frequently. +

  • It is not necessary to replay the WAL entries all the + way to the end. We could stop the replay at any point and have a + consistent snapshot of the database as it was at that time. Thus, + this technique supports point-in-time recovery: it is + possible to restore the database to its state at any time since your base + backup was taken. +

  • If we continuously feed the series of WAL files to another + machine that has been loaded with the same base backup file, we + have a warm standby system: at any point we can bring up + the second machine and it will have a nearly-current copy of the + database. +

+

Note: pg_dump and + pg_dumpall do not produce file-system-level + backups and cannot be used as part of a continuous-archiving solution. + Such dumps are logical and do not contain enough + information to be used by WAL replay. +

As with the plain file-system-backup technique, this method can only + support restoration of an entire database cluster, not a subset. + Also, it requires a lot of archival storage: the base backup might be bulky, + and a busy system will generate many megabytes of WAL traffic that + have to be archived. Still, it is the preferred backup technique in + many situations where high reliability is needed. +

To recover successfully using continuous archiving (also called + "online backup" by many database vendors), you need a continuous + sequence of archived WAL files that extends back at least as far as the + start time of your backup. So to get started, you should set up and test + your procedure for archiving WAL files before you take your + first base backup. Accordingly, we first discuss the mechanics of + archiving WAL files. +

24.3.1. Setting Up WAL Archiving

In an abstract sense, a running PostgreSQL system + produces an indefinitely long sequence of WAL records. The system + physically divides this sequence into WAL segment + files, which are normally 16MB apiece (although the segment size + can be altered when building PostgreSQL). The segment + files are given numeric names that reflect their position in the + abstract WAL sequence. When not using WAL archiving, the system + normally creates just a few segment files and then + "recycles" them by renaming no-longer-needed segment files + to higher segment numbers. It's assumed that segment files whose + contents precede the checkpoint-before-last are no longer of + interest and can be recycled. +

When archiving WAL data, we need to capture the contents of each segment + file once it is filled, and save that data somewhere before the segment + file is recycled for reuse. Depending on the application and the + available hardware, there could be many different ways of "saving + the data somewhere": we could copy the segment files to an NFS-mounted + directory on another machine, write them onto a tape drive (ensuring that + you have a way of identifying the original name of each file), or batch + them together and burn them onto CDs, or something else entirely. To + provide the database administrator with flexibility, + PostgreSQL tries not to make any assumptions about how + the archiving will be done. Instead, PostgreSQL lets + the administrator specify a shell command to be executed to copy a + completed segment file to wherever it needs to go. The command could be + as simple as a cp, or it could invoke a complex shell + script — it's all up to you. +

To enable WAL archiving, set the wal_level + configuration parameter to archive (or hot_standby), + archive_mode to on, + and specify the shell command to use in the archive_command configuration parameter. In practice + these settings will always be placed in the + postgresql.conf file. + In archive_command, + %p is replaced by the path name of the file to + archive, while %f is replaced by only the file name. + (The path name is relative to the current working directory, + i.e., the cluster's data directory.) + Use %% if you need to embed an actual % + character in the command. The simplest useful command is something + like: +

archive_command = 'test ! -f /mnt/server/archivedir/%f && cp %p /mnt/server/archivedir/%f'  # Unix
+archive_command = 'copy "%p" "C:\\server\\archivedir\\%f"'  # Windows

+ which will copy archivable WAL segments to the directory + /mnt/server/archivedir. (This is an example, not a + recommendation, and might not work on all platforms.) After the + %p and %f parameters have been replaced, + the actual command executed might look like this: +

test ! -f /mnt/server/archivedir/00000001000000A900000065 && cp pg_xlog/00000001000000A900000065 /mnt/server/archivedir/00000001000000A900000065

+ A similar command will be generated for each new file to be archived. +

The archive command will be executed under the ownership of the same + user that the PostgreSQL server is running as. Since + the series of WAL files being archived contains effectively everything + in your database, you will want to be sure that the archived data is + protected from prying eyes; for example, archive into a directory that + does not have group or world read access. +

It is important that the archive command return zero exit status if and + only if it succeeds. Upon getting a zero result, + PostgreSQL will assume that the file has been + successfully archived, and will remove or recycle it. However, a nonzero + status tells PostgreSQL that the file was not archived; + it will try again periodically until it succeeds. +

The archive command should generally be designed to refuse to overwrite + any pre-existing archive file. This is an important safety feature to + preserve the integrity of your archive in case of administrator error + (such as sending the output of two different servers to the same archive + directory). +

It is advisable to test your proposed archive command to ensure that it + indeed does not overwrite an existing file, and that it returns + nonzero status in this case. + The example command above for Unix ensures this by including a separate + test step. On some Unix platforms, cp has + switches such as -i that can be used to do the same thing + less verbosely, but you should not rely on these without verifying that + the right exit status is returned. (In particular, GNU cp + will return status zero when -i is used and the target file + already exists, which is not the desired behavior.) +

While designing your archiving setup, consider what will happen if + the archive command fails repeatedly because some aspect requires + operator intervention or the archive runs out of space. For example, this + could occur if you write to tape without an autochanger; when the tape + fills, nothing further can be archived until the tape is swapped. + You should ensure that any error condition or request to a human operator + is reported appropriately so that the situation can be + resolved reasonably quickly. The pg_xlog/ directory will + continue to fill with WAL segment files until the situation is resolved. + (If the file system containing pg_xlog/ fills up, + PostgreSQL will do a PANIC shutdown. No committed + transactions will be lost, but the database will remain offline until + you free some space.) +

The speed of the archiving command is unimportant as long as it can keep up + with the average rate at which your server generates WAL data. Normal + operation continues even if the archiving process falls a little behind. + If archiving falls significantly behind, this will increase the amount of + data that would be lost in the event of a disaster. It will also mean that + the pg_xlog/ directory will contain large numbers of + not-yet-archived segment files, which could eventually exceed available + disk space. You are advised to monitor the archiving process to ensure that + it is working as you intend. +

In writing your archive command, you should assume that the file names to + be archived can be up to 64 characters long and can contain any + combination of ASCII letters, digits, and dots. It is not necessary to + preserve the original relative path (%p) but it is necessary to + preserve the file name (%f). +

Note that although WAL archiving will allow you to restore any + modifications made to the data in your PostgreSQL database, + it will not restore changes made to configuration files (that is, + postgresql.conf, pg_hba.conf and + pg_ident.conf), since those are edited manually rather + than through SQL operations. + You might wish to keep the configuration files in a location that will + be backed up by your regular file system backup procedures. See + Section 18.2 for how to relocate the + configuration files. +

The archive command is only invoked on completed WAL segments. Hence, + if your server generates only little WAL traffic (or has slack periods + where it does so), there could be a long delay between the completion + of a transaction and its safe recording in archive storage. To put + a limit on how old unarchived data can be, you can set + archive_timeout to force the server to switch + to a new WAL segment file at least that often. Note that archived + files that are archived early due to a forced switch are still the same + length as completely full files. It is therefore unwise to set a very + short archive_timeout — it will bloat your archive + storage. archive_timeout settings of a minute or so are + usually reasonable. +

Also, you can force a segment switch manually with + pg_switch_xlog if you want to ensure that a + just-finished transaction is archived as soon as possible. Other utility + functions related to WAL management are listed in Table 9-59. +

When wal_level is minimal some SQL commands + are optimized to avoid WAL logging, as described in Section 14.4.7. If archiving or streaming replication were + turned on during execution of one of these statements, WAL would not + contain enough information for archive recovery. (Crash recovery is + unaffected.) For this reason, wal_level can only be changed at + server start. However, archive_command can be changed with a + configuration file reload. If you wish to temporarily stop archiving, + one way to do it is to set archive_command to the empty + string (''). + This will cause WAL files to accumulate in pg_xlog/ until a + working archive_command is re-established. +

24.3.2. Making a Base Backup

The easiest way to perform a base backup is to use the + pg_basebackup tool. It can create + a base backup either as regular files or as a tar archive. If more + flexibility than pg_basebackup can provide is + required, you can also make a base backup using the low level API + (see Section 24.3.3). +

It is not necessary to be concerned about the amount of time it takes + to make a base backup. However, if you normally run the + server with full_page_writes disabled, you might notice a drop + in performance while the backup runs since full_page_writes is + effectively forced on during backup mode. +

To make use of the backup, you will need to keep all the WAL + segment files generated during and after the file system backup. + To aid you in doing this, the base backup process + creates a backup history file that is immediately + stored into the WAL archive area. This file is named after the first + WAL segment file that you need for the file system backup. + For example, if the starting WAL file is + 0000000100001234000055CD the backup history file will be + named something like + 0000000100001234000055CD.007C9330.backup. (The second + part of the file name stands for an exact position within the WAL + file, and can ordinarily be ignored.) Once you have safely archived + the file system backup and the WAL segment files used during the + backup (as specified in the backup history file), all archived WAL + segments with names numerically less are no longer needed to recover + the file system backup and can be deleted. However, you should + consider keeping several backup sets to be absolutely certain that + you can recover your data. +

The backup history file is just a small text file. It contains the + label string you gave to pg_basebackup, as well as + the starting and ending times and WAL segments of the backup. + If you used the label to identify the associated dump file, + then the archived history file is enough to tell you which dump file to + restore. +

Since you have to keep around all the archived WAL files back to your + last base backup, the interval between base backups should usually be + chosen based on how much storage you want to expend on archived WAL + files. You should also consider how long you are prepared to spend + recovering, if recovery should be necessary — the system will have to + replay all those WAL segments, and that could take awhile if it has + been a long time since the last base backup. +

24.3.3. Making a Base Backup Using the Low Level API

The procedure for making a base backup using the low level + APIs contains a few more steps than + the pg_basebackup method, but is relatively + simple. It is very important that these steps are executed in + sequence, and that the success of a step is verified before + proceeding to the next step. +

  1. Ensure that WAL archiving is enabled and working. +

  2. Connect to the database as a superuser and issue the command: +

    SELECT pg_start_backup('label');

    + where label is any string you want to use to uniquely + identify this backup operation. (One good practice is to use the + full path where you intend to put the backup dump file.) + pg_start_backup creates a backup label file, + called backup_label, in the cluster directory with + information about your backup, including the start time and label + string. +

    It does not matter which database within the cluster you connect to to + issue this command. You can ignore the result returned by the function; + but if it reports an error, deal with that before proceeding. +

    By default, pg_start_backup can take a long time to finish. + This is because it performs a checkpoint, and the I/O + required for the checkpoint will be spread out over a significant + period of time, by default half your inter-checkpoint interval + (see the configuration parameter + checkpoint_completion_target). This is + usually what you want, because it minimizes the impact on query + processing. If you want to start the backup as soon as + possible, use: +

    SELECT pg_start_backup('label', true);

    + This forces the checkpoint to be done as quickly as possible. +

  3. Perform the backup, using any convenient file-system-backup tool + such as tar or cpio (not + pg_dump or + pg_dumpall). It is neither + necessary nor desirable to stop normal operation of the database + while you do this. +

  4. Again connect to the database as a superuser, and issue the command: +

    SELECT pg_stop_backup();

    + This terminates the backup mode and performs an automatic switch to + the next WAL segment. The reason for the switch is to arrange for + the last WAL segment file written during the backup interval to be + ready to archive. +

  5. Once the WAL segment files active during the backup are archived, you are + done. The file identified by pg_stop_backup's result is + the last segment that is required to form a complete set of backup files. + If archive_mode is enabled, + pg_stop_backup does not return until the last segment has + been archived. + Archiving of these files happens automatically since you have + already configured archive_command. In most cases this + happens quickly, but you are advised to monitor your archive + system to ensure there are no delays. + If the archive process has fallen behind + because of failures of the archive command, it will keep retrying + until the archive succeeds and the backup is complete. + If you wish to place a time limit on the execution of + pg_stop_backup, set an appropriate + statement_timeout value. +

+

Some file system backup tools emit warnings or errors + if the files they are trying to copy change while the copy proceeds. + When taking a base backup of an active database, this situation is normal + and not an error. However, you need to ensure that you can distinguish + complaints of this sort from real errors. For example, some versions + of rsync return a separate exit code for + "vanished source files", and you can write a driver script to + accept this exit code as a non-error case. Also, some versions of + GNU tar return an error code indistinguishable from + a fatal error if a file was truncated while tar was + copying it. Fortunately, GNU tar versions 1.16 and + later exit with 1 if a file was changed during the backup, + and 2 for other errors. With GNU tar version 1.23 and + later, you can use the warning options --warning=no-file-changed + --warning=no-file-removed to hide the related warning messages. +

Be certain that your backup dump includes all of the files under + the database cluster directory (e.g., /usr/local/pgsql/data). + If you are using tablespaces that do not reside underneath this directory, + be careful to include them as well (and be sure that your backup dump + archives symbolic links as links, otherwise the restore will corrupt + your tablespaces). +

You can, however, omit from the backup dump the files within the + cluster's pg_xlog/ subdirectory. This + slight adjustment is worthwhile because it reduces the risk + of mistakes when restoring. This is easy to arrange if + pg_xlog/ is a symbolic link pointing to someplace outside + the cluster directory, which is a common setup anyway for performance + reasons. You might also want to exclude postmaster.pid + and postmaster.opts, which record information + about the running postmaster, not about the + postmaster which will eventually use this backup. + (These files can confuse pg_ctl.) +

It's also worth noting that the pg_start_backup function + makes a file named backup_label in the database cluster + directory, which is removed by pg_stop_backup. + This file will of course be archived as a part of your backup dump file. + The backup label file includes the label string you gave to + pg_start_backup, as well as the time at which + pg_start_backup was run, and the name of the starting WAL + file. In case of confusion it is + therefore possible to look inside a backup dump file and determine + exactly which backup session the dump file came from. +

It is also possible to make a backup dump while the server is + stopped. In this case, you obviously cannot use + pg_start_backup or pg_stop_backup, and + you will therefore be left to your own devices to keep track of which + backup dump is which and how far back the associated WAL files go. + It is generally better to follow the continuous archiving procedure above. +

24.3.4. Recovering Using a Continuous Archive Backup

Okay, the worst has happened and you need to recover from your backup. + Here is the procedure: +

  1. Stop the server, if it's running. +

  2. If you have the space to do so, + copy the whole cluster data directory and any tablespaces to a temporary + location in case you need them later. Note that this precaution will + require that you have enough free space on your system to hold two + copies of your existing database. If you do not have enough space, + you should at least save the contents of the cluster's pg_xlog + subdirectory, as it might contain logs which + were not archived before the system went down. +

  3. Remove all existing files and subdirectories under the cluster data + directory and under the root directories of any tablespaces you are using. +

  4. Restore the database files from your file system backup. Be sure that they + are restored with the right ownership (the database system user, not + root!) and with the right permissions. If you are using + tablespaces, + you should verify that the symbolic links in pg_tblspc/ + were correctly restored. +

  5. Remove any files present in pg_xlog/; these came from the + file system backup and are therefore probably obsolete rather than current. + If you didn't archive pg_xlog/ at all, then recreate + it with proper permissions, + being careful to ensure that you re-establish it as a symbolic link + if you had it set up that way before. +

  6. If you have unarchived WAL segment files that you saved in step 2, + copy them into pg_xlog/. (It is best to copy them, + not move them, so you still have the unmodified files if a + problem occurs and you have to start over.) +

  7. Create a recovery command file recovery.conf in the cluster + data directory (see Chapter 26). You might + also want to temporarily modify pg_hba.conf to prevent + ordinary users from connecting until you are sure the recovery was successful. +

  8. Start the server. The server will go into recovery mode and + proceed to read through the archived WAL files it needs. Should the + recovery be terminated because of an external error, the server can + simply be restarted and it will continue recovery. Upon completion + of the recovery process, the server will rename + recovery.conf to recovery.done (to prevent + accidentally re-entering recovery mode later) and then + commence normal database operations. +

  9. Inspect the contents of the database to ensure you have recovered to + the desired state. If not, return to step 1. If all is well, + allow your users to connect by restoring pg_hba.conf to normal. +

+

The key part of all this is to set up a recovery configuration file that + describes how you want to recover and how far the recovery should + run. You can use recovery.conf.sample (normally + located in the installation's share/ directory) as a + prototype. The one thing that you absolutely must specify in + recovery.conf is the restore_command, + which tells PostgreSQL how to retrieve archived + WAL file segments. Like the archive_command, this is + a shell command string. It can contain %f, which is + replaced by the name of the desired log file, and %p, + which is replaced by the path name to copy the log file to. + (The path name is relative to the current working directory, + i.e., the cluster's data directory.) + Write %% if you need to embed an actual % + character in the command. The simplest useful command is + something like: +

restore_command = 'cp /mnt/server/archivedir/%f %p'

+ which will copy previously archived WAL segments from the directory + /mnt/server/archivedir. Of course, you can use something + much more complicated, perhaps even a shell script that requests the + operator to mount an appropriate tape. +

It is important that the command return nonzero exit status on failure. + The command will be called requesting files that are not present + in the archive; it must return nonzero when so asked. This is not an + error condition. Not all of the requested files will be WAL segment + files; you should also expect requests for files with a suffix of + .backup or .history. Also be aware that + the base name of the %p path will be different from + %f; do not expect them to be interchangeable. +

WAL segments that cannot be found in the archive will be sought in + pg_xlog/; this allows use of recent un-archived segments. + However, segments that are available from the archive will be used in + preference to files in pg_xlog/. +

Normally, recovery will proceed through all available WAL segments, + thereby restoring the database to the current point in time (or as + close as possible given the available WAL segments). Therefore, a normal + recovery will end with a "file not found" message, the exact text + of the error message depending upon your choice of + restore_command. You may also see an error message + at the start of recovery for a file named something like + 00000001.history. This is also normal and does not + indicate a problem in simple recovery situations; see + Section 24.3.5 for discussion. +

If you want to recover to some previous point in time (say, right before + the junior DBA dropped your main transaction table), just specify the + required stopping point in recovery.conf. You can specify + the stop point, known as the "recovery target", either by + date/time, named restore point or by completion of a specific transaction + ID. As of this writing only the date/time and named restore point options + are very usable, since there are no tools to help you identify with any + accuracy which transaction ID to use. +

Note: The stop point must be after the ending time of the base backup, i.e., + the end time of pg_stop_backup. You cannot use a base backup + to recover to a time when that backup was in progress. (To + recover to such a time, you must go back to your previous base backup + and roll forward from there.) +

If recovery finds corrupted WAL data, recovery will + halt at that point and the server will not start. In such a case the + recovery process could be re-run from the beginning, specifying a + "recovery target" before the point of corruption so that recovery + can complete normally. + If recovery fails for an external reason, such as a system crash or + if the WAL archive has become inaccessible, then the recovery can simply + be restarted and it will restart almost from where it failed. + Recovery restart works much like checkpointing in normal operation: + the server periodically forces all its state to disk, and then updates + the pg_control file to indicate that the already-processed + WAL data need not be scanned again. +

24.3.5. Timelines

The ability to restore the database to a previous point in time creates + some complexities that are akin to science-fiction stories about time + travel and parallel universes. For example, in the original history of the database, + suppose you dropped a critical table at 5:15PM on Tuesday evening, but + didn't realize your mistake until Wednesday noon. + Unfazed, you get out your backup, restore to the point-in-time 5:14PM + Tuesday evening, and are up and running. In this history of + the database universe, you never dropped the table. But suppose + you later realize this wasn't such a great idea, and would like + to return to sometime Wednesday morning in the original history. + You won't be able + to if, while your database was up-and-running, it overwrote some of the + WAL segment files that led up to the time you now wish you + could get back to. Thus, to avoid this, you need to distinguish the series of + WAL records generated after you've done a point-in-time recovery from + those that were generated in the original database history. +

To deal with this problem, PostgreSQL has a notion + of timelines. Whenever an archive recovery completes, + a new timeline is created to identify the series of WAL records + generated after that recovery. The timeline + ID number is part of WAL segment file names so a new timeline does + not overwrite the WAL data generated by previous timelines. It is + in fact possible to archive many different timelines. While that might + seem like a useless feature, it's often a lifesaver. Consider the + situation where you aren't quite sure what point-in-time to recover to, + and so have to do several point-in-time recoveries by trial and error + until you find the best place to branch off from the old history. Without + timelines this process would soon generate an unmanageable mess. With + timelines, you can recover to any prior state, including + states in timeline branches that you abandoned earlier. +

Every time a new timeline is created, PostgreSQL creates + a "timeline history" file that shows which timeline it branched + off from and when. These history files are necessary to allow the system + to pick the right WAL segment files when recovering from an archive that + contains multiple timelines. Therefore, they are archived into the WAL + archive area just like WAL segment files. The history files are just + small text files, so it's cheap and appropriate to keep them around + indefinitely (unlike the segment files which are large). You can, if + you like, add comments to a history file to record your own notes about + how and why this particular timeline was created. Such comments will be + especially valuable when you have a thicket of different timelines as + a result of experimentation. +

The default behavior of recovery is to recover along the same timeline + that was current when the base backup was taken. If you wish to recover + into some child timeline (that is, you want to return to some state that + was itself generated after a recovery attempt), you need to specify the + target timeline ID in recovery.conf. You cannot recover into + timelines that branched off earlier than the base backup. +

24.3.6. Tips and Examples

Some tips for configuring continuous archiving are given here. +

24.3.6.1. Standalone Hot Backups

It is possible to use PostgreSQL's backup facilities to + produce standalone hot backups. These are backups that cannot be used + for point-in-time recovery, yet are typically much faster to backup and + restore than pg_dump dumps. (They are also much larger + than pg_dump dumps, so in some cases the speed advantage + might be negated.) +

As with base backups, the easiest way to produce a standalone + hot backup is to use the pg_basebackup + tool. If you include the -X parameter when calling + it, all the transaction log required to use the backup will be + included in the backup automatically, and no special action is + required to restore the backup. +

If more flexibility in copying the backup files is needed, a lower + level process can be used for standalone hot backups as well. + To prepare for low level standalone hot backups, set wal_level to + archive (or hot_standby), archive_mode to + on, and set up an archive_command that performs + archiving only when a switch file exists. For example: +

archive_command = 'test ! -f /var/lib/pgsql/backup_in_progress || (test ! -f /var/lib/pgsql/archive/%f && cp %p /var/lib/pgsql/archive/%f)'

+ This command will perform archiving when + /var/lib/pgsql/backup_in_progress exists, and otherwise + silently return zero exit status (allowing PostgreSQL + to recycle the unwanted WAL file). +

With this preparation, a backup can be taken using a script like the + following: +

touch /var/lib/pgsql/backup_in_progress
+psql -c "select pg_start_backup('hot_backup');"
+tar -cf /var/lib/pgsql/backup.tar /var/lib/pgsql/data/
+psql -c "select pg_stop_backup();"
+rm /var/lib/pgsql/backup_in_progress
+tar -rf /var/lib/pgsql/backup.tar /var/lib/pgsql/archive/

+ The switch file /var/lib/pgsql/backup_in_progress is + created first, enabling archiving of completed WAL files to occur. + After the backup the switch file is removed. Archived WAL files are + then added to the backup so that both base backup and all required + WAL files are part of the same tar file. + Please remember to add error handling to your backup scripts. +

24.3.6.2. Compressed Archive Logs

If archive storage size is a concern, you can use + gzip to compress the archive files: +

archive_command = 'gzip < %p > /var/lib/pgsql/archive/%f'

+ You will then need to use gunzip during recovery: +

restore_command = 'gunzip < /mnt/server/archivedir/%f > %p'

+

24.3.6.3. archive_command Scripts

Many people choose to use scripts to define their + archive_command, so that their + postgresql.conf entry looks very simple: +

archive_command = 'local_backup_script.sh "%p" "%f"'

+ Using a separate script file is advisable any time you want to use + more than a single command in the archiving process. + This allows all complexity to be managed within the script, which + can be written in a popular scripting language such as + bash or perl. +

Examples of requirements that might be solved within a script include: +

  • Copying data to secure off-site data storage +

  • Batching WAL files so that they are transferred every three hours, + rather than one at a time +

  • Interfacing with other backup and recovery software +

  • Interfacing with monitoring software to report errors +

+

Tip: When using an archive_command script, it's desirable + to enable logging_collector. + Any messages written to stderr from the script will then + appear in the database server log, allowing complex configurations to + be diagnosed easily if they fail. +

24.3.7. Caveats

At this writing, there are several limitations of the continuous archiving + technique. These will probably be fixed in future releases: + +

  • Operations on hash indexes are not presently WAL-logged, so + replay will not update these indexes. This will mean that any new inserts + will be ignored by the index, updated rows will apparently disappear and + deleted rows will still retain pointers. In other words, if you modify a + table with a hash index on it then you will get incorrect query results + on a standby server. When recovery completes it is recommended that you + manually REINDEX + each such index after completing a recovery operation. +

  • If a CREATE DATABASE + command is executed while a base backup is being taken, and then + the template database that the CREATE DATABASE copied + is modified while the base backup is still in progress, it is + possible that recovery will cause those modifications to be + propagated into the created database as well. This is of course + undesirable. To avoid this risk, it is best not to modify any + template databases while taking a base backup. +

  • CREATE TABLESPACE + commands are WAL-logged with the literal absolute path, and will + therefore be replayed as tablespace creations with the same + absolute path. This might be undesirable if the log is being + replayed on a different machine. It can be dangerous even if the + log is being replayed on the same machine, but into a new data + directory: the replay will still overwrite the contents of the + original tablespace. To avoid potential gotchas of this sort, + the best practice is to take a new base backup after creating or + dropping tablespaces. +

+

It should also be noted that the default WAL + format is fairly bulky since it includes many disk page snapshots. + These page snapshots are designed to support crash recovery, since + we might need to fix partially-written disk pages. Depending on + your system hardware and software, the risk of partial writes might + be small enough to ignore, in which case you can significantly + reduce the total volume of archived logs by turning off page + snapshots using the full_page_writes + parameter. (Read the notes and warnings in Chapter 29 + before you do so.) Turning off page snapshots does not prevent + use of the logs for PITR operations. An area for future + development is to compress archived WAL data by removing + unnecessary page copies even when full_page_writes is + on. In the meantime, administrators might wish to reduce the number + of page snapshots included in WAL by increasing the checkpoint + interval parameters as much as feasible. +


PrevHomeNext
File System Level BackupUpHigh Availability, Load Balancing, and Replication
\ No newline at end of file diff --git a/doc/src/sgml/html/contrib-dblink-build-sql-delete.html b/doc/src/sgml/html/contrib-dblink-build-sql-delete.html new file mode 100644 index 000000000..8a9a06b8e --- /dev/null +++ b/doc/src/sgml/html/contrib-dblink-build-sql-delete.html @@ -0,0 +1,330 @@ + +dblink_build_sql_delete

dblink_build_sql_delete

Name

dblink_build_sql_delete -- builds a DELETE statement using supplied values for primary + key field values +

Synopsis

dblink_build_sql_delete(text relname,
+                        int2vector primary_key_attnums,
+                        integer num_primary_key_atts,
+                        text[] tgt_pk_att_vals_array) returns text

Description

dblink_build_sql_delete can be useful in doing selective + replication of a local table to a remote database. It builds a SQL + DELETE command that will delete the row with the given + primary key values. +

Arguments

relname

Name of a local relation, for example foo or + myschema.mytab. Include double quotes if the + name is mixed-case or contains special characters, for + example "FooBar"; without quotes, the string + will be folded to lower case. +

primary_key_attnums

Attribute numbers (1-based) of the primary key fields, + for example 1 2. +

num_primary_key_atts

The number of primary key fields. +

tgt_pk_att_vals_array

Values of the primary key fields to be used in the resulting + DELETE command. Each field is represented in text form. +

Return Value

Returns the requested SQL statement as text.

Notes

As of PostgreSQL 9.0, the attribute numbers in + primary_key_attnums are interpreted as logical + column numbers, corresponding to the column's position in + SELECT * FROM relname. Previous versions interpreted the + numbers as physical column positions. There is a difference if any + column(s) to the left of the indicated column have been dropped during + the lifetime of the table. +

Examples

SELECT dblink_build_sql_delete('"MyFoo"', '1 2', 2, '{"1", "b"}');
+           dblink_build_sql_delete
+---------------------------------------------
+ DELETE FROM "MyFoo" WHERE f1='1' AND f2='b'
+(1 row)

PrevHomeNext
dblink_build_sql_insertUpdblink_build_sql_update
\ No newline at end of file diff --git a/doc/src/sgml/html/contrib-dblink-build-sql-insert.html b/doc/src/sgml/html/contrib-dblink-build-sql-insert.html new file mode 100644 index 000000000..0441d7018 --- /dev/null +++ b/doc/src/sgml/html/contrib-dblink-build-sql-insert.html @@ -0,0 +1,347 @@ + +dblink_build_sql_insert

dblink_build_sql_insert

Name

dblink_build_sql_insert --  builds an INSERT statement using a local tuple, replacing the + primary key field values with alternative supplied values +

Synopsis

dblink_build_sql_insert(text relname,
+                        int2vector primary_key_attnums,
+                        integer num_primary_key_atts,
+                        text[] src_pk_att_vals_array,
+                        text[] tgt_pk_att_vals_array) returns text

Description

dblink_build_sql_insert can be useful in doing selective + replication of a local table to a remote database. It selects a row + from the local table based on primary key, and then builds a SQL + INSERT command that will duplicate that row, but with + the primary key values replaced by the values in the last argument. + (To make an exact copy of the row, just specify the same values for + the last two arguments.) +

Arguments

relname

Name of a local relation, for example foo or + myschema.mytab. Include double quotes if the + name is mixed-case or contains special characters, for + example "FooBar"; without quotes, the string + will be folded to lower case. +

primary_key_attnums

Attribute numbers (1-based) of the primary key fields, + for example 1 2. +

num_primary_key_atts

The number of primary key fields. +

src_pk_att_vals_array

Values of the primary key fields to be used to look up the + local tuple. Each field is represented in text form. + An error is thrown if there is no local row with these + primary key values. +

tgt_pk_att_vals_array

Values of the primary key fields to be placed in the resulting + INSERT command. Each field is represented in text form. +

Return Value

Returns the requested SQL statement as text.

Notes

As of PostgreSQL 9.0, the attribute numbers in + primary_key_attnums are interpreted as logical + column numbers, corresponding to the column's position in + SELECT * FROM relname. Previous versions interpreted the + numbers as physical column positions. There is a difference if any + column(s) to the left of the indicated column have been dropped during + the lifetime of the table. +

Examples

SELECT dblink_build_sql_insert('foo', '1 2', 2, '{"1", "a"}', '{"1", "b''a"}');
+             dblink_build_sql_insert
+--------------------------------------------------
+ INSERT INTO foo(f1,f2,f3) VALUES('1','b''a','1')
+(1 row)

PrevHomeNext
dblink_get_pkeyUpdblink_build_sql_delete
\ No newline at end of file diff --git a/doc/src/sgml/html/contrib-dblink-build-sql-update.html b/doc/src/sgml/html/contrib-dblink-build-sql-update.html new file mode 100644 index 000000000..6d64a46cb --- /dev/null +++ b/doc/src/sgml/html/contrib-dblink-build-sql-update.html @@ -0,0 +1,356 @@ + +dblink_build_sql_update

dblink_build_sql_update

Name

dblink_build_sql_update -- builds an UPDATE statement using a local tuple, replacing + the primary key field values with alternative supplied values +

Synopsis

dblink_build_sql_update(text relname,
+                        int2vector primary_key_attnums,
+                        integer num_primary_key_atts,
+                        text[] src_pk_att_vals_array,
+                        text[] tgt_pk_att_vals_array) returns text

Description

dblink_build_sql_update can be useful in doing selective + replication of a local table to a remote database. It selects a row + from the local table based on primary key, and then builds a SQL + UPDATE command that will duplicate that row, but with + the primary key values replaced by the values in the last argument. + (To make an exact copy of the row, just specify the same values for + the last two arguments.) The UPDATE command always assigns + all fields of the row — the main difference between this and + dblink_build_sql_insert is that it's assumed that + the target row already exists in the remote table. +

Arguments

relname

Name of a local relation, for example foo or + myschema.mytab. Include double quotes if the + name is mixed-case or contains special characters, for + example "FooBar"; without quotes, the string + will be folded to lower case. +

primary_key_attnums

Attribute numbers (1-based) of the primary key fields, + for example 1 2. +

num_primary_key_atts

The number of primary key fields. +

src_pk_att_vals_array

Values of the primary key fields to be used to look up the + local tuple. Each field is represented in text form. + An error is thrown if there is no local row with these + primary key values. +

tgt_pk_att_vals_array

Values of the primary key fields to be placed in the resulting + UPDATE command. Each field is represented in text form. +

Return Value

Returns the requested SQL statement as text.

Notes

As of PostgreSQL 9.0, the attribute numbers in + primary_key_attnums are interpreted as logical + column numbers, corresponding to the column's position in + SELECT * FROM relname. Previous versions interpreted the + numbers as physical column positions. There is a difference if any + column(s) to the left of the indicated column have been dropped during + the lifetime of the table. +

Examples

SELECT dblink_build_sql_update('foo', '1 2', 2, '{"1", "a"}', '{"1", "b"}');
+                   dblink_build_sql_update
+-------------------------------------------------------------
+ UPDATE foo SET f1='1',f2='b',f3='1' WHERE f1='1' AND f2='b'
+(1 row)

PrevHomeNext
dblink_build_sql_deleteUpdict_int
\ No newline at end of file diff --git a/doc/src/sgml/html/contrib-dblink-cancel-query.html b/doc/src/sgml/html/contrib-dblink-cancel-query.html new file mode 100644 index 000000000..fa57e23c9 --- /dev/null +++ b/doc/src/sgml/html/contrib-dblink-cancel-query.html @@ -0,0 +1,252 @@ + +dblink_cancel_query

dblink_cancel_query

Name

dblink_cancel_query -- cancels any active query on the named connection

Synopsis

dblink_cancel_query(text connname) returns text

Description

dblink_cancel_query attempts to cancel any query that + is in progress on the named connection. Note that this is not + certain to succeed (since, for example, the remote query might + already have finished). A cancel request simply improves the + odds that the query will fail soon. You must still complete the + normal query protocol, for example by calling + dblink_get_result. +

Arguments

conname

Name of the connection to use. +

Return Value

Returns OK if the cancel request has been sent, or + the text of an error message on failure. +

Examples

SELECT dblink_cancel_query('dtest1');

PrevHomeNext
dblink_get_resultUpdblink_get_pkey
\ No newline at end of file diff --git a/doc/src/sgml/html/contrib-dblink-close.html b/doc/src/sgml/html/contrib-dblink-close.html new file mode 100644 index 000000000..0bd4eb950 --- /dev/null +++ b/doc/src/sgml/html/contrib-dblink-close.html @@ -0,0 +1,315 @@ + +dblink_close

dblink_close

Name

dblink_close -- closes a cursor in a remote database

Synopsis

dblink_close(text cursorname [, bool fail_on_error]) returns text
+dblink_close(text connname, text cursorname [, bool fail_on_error]) returns text

Description

dblink_close closes a cursor previously opened with + dblink_open. +

Arguments

conname

Name of the connection to use; omit this parameter to use the + unnamed connection. +

cursorname

The name of the cursor to close. +

fail_on_error

If true (the default when omitted) then an error thrown on the + remote side of the connection causes an error to also be thrown + locally. If false, the remote error is locally reported as a NOTICE, + and the function's return value is set to ERROR. +

Return Value

Returns status, either OK or ERROR. +

Notes

If dblink_open started an explicit transaction block, + and this is the last remaining open cursor in this connection, + dblink_close will issue the matching COMMIT. +

Examples

SELECT dblink_connect('dbname=postgres');
+ dblink_connect
+----------------
+ OK
+(1 row)
+
+SELECT dblink_open('foo', 'select proname, prosrc from pg_proc');
+ dblink_open
+-------------
+ OK
+(1 row)
+
+SELECT dblink_close('foo');
+ dblink_close
+--------------
+ OK
+(1 row)

PrevHomeNext
dblink_fetchUpdblink_get_connections
\ No newline at end of file diff --git a/doc/src/sgml/html/contrib-dblink-connect-u.html b/doc/src/sgml/html/contrib-dblink-connect-u.html new file mode 100644 index 000000000..409fc83d3 --- /dev/null +++ b/doc/src/sgml/html/contrib-dblink-connect-u.html @@ -0,0 +1,250 @@ + +dblink_connect_u

dblink_connect_u

Name

dblink_connect_u -- opens a persistent connection to a remote database, insecurely

Synopsis

dblink_connect_u(text connstr) returns text
+dblink_connect_u(text connname, text connstr) returns text

Description

dblink_connect_u() is identical to + dblink_connect(), except that it will allow non-superusers + to connect using any authentication method. +

If the remote server selects an authentication method that does not + involve a password, then impersonation and subsequent escalation of + privileges can occur, because the session will appear to have + originated from the user as which the local PostgreSQL + server runs. Also, even if the remote server does demand a password, + it is possible for the password to be supplied from the server + environment, such as a ~/.pgpass file belonging to the + server's user. This opens not only a risk of impersonation, but the + possibility of exposing a password to an untrustworthy remote server. + Therefore, dblink_connect_u() is initially + installed with all privileges revoked from PUBLIC, + making it un-callable except by superusers. In some situations + it may be appropriate to grant EXECUTE permission for + dblink_connect_u() to specific users who are considered + trustworthy, but this should be done with care. It is also recommended + that any ~/.pgpass file belonging to the server's user + not contain any records specifying a wildcard host name. +

For further details see dblink_connect(). +


PrevHomeNext
dblink_connectUpdblink_disconnect
\ No newline at end of file diff --git a/doc/src/sgml/html/contrib-dblink-connect.html b/doc/src/sgml/html/contrib-dblink-connect.html new file mode 100644 index 000000000..4b845fb60 --- /dev/null +++ b/doc/src/sgml/html/contrib-dblink-connect.html @@ -0,0 +1,387 @@ + +dblink_connect

dblink_connect

Name

dblink_connect -- opens a persistent connection to a remote database

Synopsis

dblink_connect(text connstr) returns text
+dblink_connect(text connname, text connstr) returns text

Description

dblink_connect() establishes a connection to a remote + PostgreSQL database. The server and database to + be contacted are identified through a standard libpq + connection string. Optionally, a name can be assigned to the + connection. Multiple named connections can be open at once, but + only one unnamed connection is permitted at a time. The connection + will persist until closed or until the database session is ended. +

The connection string may also be the name of an existing foreign + server. It is recommended to use + the postgresql_fdw_validator when defining + the corresponding foreign-data wrapper. See the example below, as + well as the following: + CREATE FOREIGN DATA WRAPPER, CREATE SERVER, CREATE USER MAPPING +

Arguments

conname

The name to use for this connection; if omitted, an unnamed + connection is opened, replacing any existing unnamed connection. +

connstr

libpq-style connection info string, for example + hostaddr=127.0.0.1 port=5432 dbname=mydb user=postgres + password=mypasswd. + For details see PQconnectdb in + Section 31.1. +

Return Value

Returns status, which is always OK (since any error + causes the function to throw an error instead of returning). +

Notes

Only superusers may use dblink_connect to create + non-password-authenticated connections. If non-superusers need this + capability, use dblink_connect_u instead. +

It is unwise to choose connection names that contain equal signs, + as this opens a risk of confusion with connection info strings + in other dblink functions. +

Examples

SELECT dblink_connect('dbname=postgres');
+ dblink_connect
+----------------
+ OK
+(1 row)
+
+SELECT dblink_connect('myconn', 'dbname=postgres');
+ dblink_connect
+----------------
+ OK
+(1 row)
+
+-- FOREIGN DATA WRAPPER functionality
+-- Note: local connection must require password authentication for this to work properly
+--       Otherwise, you will receive the following error from dblink_connect():
+--       ----------------------------------------------------------------------
+--       ERROR:  password is required
+--       DETAIL:  Non-superuser cannot connect if the server does not request a password.
+--       HINT:  Target server's authentication method must be changed.
+CREATE USER dblink_regression_test WITH PASSWORD 'secret';
+CREATE FOREIGN DATA WRAPPER postgresql VALIDATOR postgresql_fdw_validator;
+CREATE SERVER fdtest FOREIGN DATA WRAPPER postgresql OPTIONS (hostaddr '127.0.0.1', dbname 'contrib_regression');
+
+CREATE USER MAPPING FOR dblink_regression_test SERVER fdtest OPTIONS (user 'dblink_regression_test', password 'secret');
+GRANT USAGE ON FOREIGN SERVER fdtest TO dblink_regression_test;
+GRANT SELECT ON TABLE foo TO dblink_regression_test;
+
+\set ORIGINAL_USER :USER
+\c - dblink_regression_test
+SELECT dblink_connect('myconn', 'fdtest');
+ dblink_connect 
+----------------
+ OK
+(1 row)
+
+SELECT * FROM dblink('myconn','SELECT * FROM foo') AS t(a int, b text, c text[]);
+ a  | b |       c       
+----+---+---------------
+  0 | a | {a0,b0,c0}
+  1 | b | {a1,b1,c1}
+  2 | c | {a2,b2,c2}
+  3 | d | {a3,b3,c3}
+  4 | e | {a4,b4,c4}
+  5 | f | {a5,b5,c5}
+  6 | g | {a6,b6,c6}
+  7 | h | {a7,b7,c7}
+  8 | i | {a8,b8,c8}
+  9 | j | {a9,b9,c9}
+ 10 | k | {a10,b10,c10}
+(11 rows)
+
+\c - :ORIGINAL_USER
+REVOKE USAGE ON FOREIGN SERVER fdtest FROM dblink_regression_test;
+REVOKE SELECT ON TABLE foo FROM  dblink_regression_test;
+DROP USER MAPPING FOR dblink_regression_test SERVER fdtest;
+DROP USER dblink_regression_test;
+DROP SERVER fdtest;
+DROP FOREIGN DATA WRAPPER postgresql;

PrevHomeNext
dblinkUpdblink_connect_u
\ No newline at end of file diff --git a/doc/src/sgml/html/contrib-dblink-disconnect.html b/doc/src/sgml/html/contrib-dblink-disconnect.html new file mode 100644 index 000000000..4af5ddd19 --- /dev/null +++ b/doc/src/sgml/html/contrib-dblink-disconnect.html @@ -0,0 +1,259 @@ + +dblink_disconnect

dblink_disconnect

Name

dblink_disconnect -- closes a persistent connection to a remote database

Synopsis

dblink_disconnect() returns text
+dblink_disconnect(text connname) returns text

Description

dblink_disconnect() closes a connection previously opened + by dblink_connect(). The form with no arguments closes + an unnamed connection. +

Arguments

conname

The name of a named connection to be closed. +

Return Value

Returns status, which is always OK (since any error + causes the function to throw an error instead of returning). +

Examples

SELECT dblink_disconnect();
+ dblink_disconnect
+-------------------
+ OK
+(1 row)
+
+SELECT dblink_disconnect('myconn');
+ dblink_disconnect
+-------------------
+ OK
+(1 row)

PrevHomeNext
dblink_connect_uUpdblink
\ No newline at end of file diff --git a/doc/src/sgml/html/contrib-dblink-error-message.html b/doc/src/sgml/html/contrib-dblink-error-message.html new file mode 100644 index 000000000..39105711b --- /dev/null +++ b/doc/src/sgml/html/contrib-dblink-error-message.html @@ -0,0 +1,241 @@ + +dblink_error_message

dblink_error_message

Name

dblink_error_message -- gets last error message on the named connection

Synopsis

dblink_error_message(text connname) returns text

Description

dblink_error_message fetches the most recent remote + error message for a given connection. +

Arguments

conname

Name of the connection to use. +

Return Value

Returns last error message, or an empty string if there has been + no error in this connection. +

Examples

SELECT dblink_error_message('dtest1');

PrevHomeNext
dblink_get_connectionsUpdblink_send_query
\ No newline at end of file diff --git a/doc/src/sgml/html/contrib-dblink-exec.html b/doc/src/sgml/html/contrib-dblink-exec.html new file mode 100644 index 000000000..5349a9c07 --- /dev/null +++ b/doc/src/sgml/html/contrib-dblink-exec.html @@ -0,0 +1,335 @@ + +dblink_exec

dblink_exec

Name

dblink_exec -- executes a command in a remote database

Synopsis

dblink_exec(text connname, text sql [, bool fail_on_error]) returns text
+dblink_exec(text connstr, text sql [, bool fail_on_error]) returns text
+dblink_exec(text sql [, bool fail_on_error]) returns text

Description

dblink_exec executes a command (that is, any SQL statement + that doesn't return rows) in a remote database. +

When two text arguments are given, the first one is first + looked up as a persistent connection's name; if found, the command + is executed on that connection. If not found, the first argument + is treated as a connection info string as for dblink_connect, + and the indicated connection is made just for the duration of this command. +

Arguments

conname

Name of the connection to use; omit this parameter to use the + unnamed connection. +

connstr

A connection info string, as previously described for + dblink_connect. +

sql

The SQL command that you wish to execute in the remote database, + for example + insert into foo values(0,'a','{"a0","b0","c0"}'). +

fail_on_error

If true (the default when omitted) then an error thrown on the + remote side of the connection causes an error to also be thrown + locally. If false, the remote error is locally reported as a NOTICE, + and the function's return value is set to ERROR. +

Return Value

Returns status, either the command's status string or ERROR. +

Examples

SELECT dblink_connect('dbname=dblink_test_standby');
+ dblink_connect
+----------------
+ OK
+(1 row)
+
+SELECT dblink_exec('insert into foo values(21,''z'',''{"a0","b0","c0"}'');');
+   dblink_exec
+-----------------
+ INSERT 943366 1
+(1 row)
+
+SELECT dblink_connect('myconn', 'dbname=regression');
+ dblink_connect
+----------------
+ OK
+(1 row)
+
+SELECT dblink_exec('myconn', 'insert into foo values(21,''z'',''{"a0","b0","c0"}'');');
+   dblink_exec
+------------------
+ INSERT 6432584 1
+(1 row)
+
+SELECT dblink_exec('myconn', 'insert into pg_class values (''foo'')',false);
+NOTICE:  sql error
+DETAIL:  ERROR:  null value in column "relnamespace" violates not-null constraint
+
+ dblink_exec
+-------------
+ ERROR
+(1 row)

PrevHomeNext
dblinkUpdblink_open
\ No newline at end of file diff --git a/doc/src/sgml/html/contrib-dblink-fetch.html b/doc/src/sgml/html/contrib-dblink-fetch.html new file mode 100644 index 000000000..34cef1694 --- /dev/null +++ b/doc/src/sgml/html/contrib-dblink-fetch.html @@ -0,0 +1,352 @@ + +dblink_fetch

dblink_fetch

Name

dblink_fetch -- returns rows from an open cursor in a remote database

Synopsis

dblink_fetch(text cursorname, int howmany [, bool fail_on_error]) returns setof record
+dblink_fetch(text connname, text cursorname, int howmany [, bool fail_on_error]) returns setof record

Description

dblink_fetch fetches rows from a cursor previously + established by dblink_open. +

Arguments

conname

Name of the connection to use; omit this parameter to use the + unnamed connection. +

cursorname

The name of the cursor to fetch from. +

howmany

The maximum number of rows to retrieve. The next howmany + rows are fetched, starting at the current cursor position, moving + forward. Once the cursor has reached its end, no more rows are produced. +

fail_on_error

If true (the default when omitted) then an error thrown on the + remote side of the connection causes an error to also be thrown + locally. If false, the remote error is locally reported as a NOTICE, + and the function returns no rows. +

Return Value

The function returns the row(s) fetched from the cursor. To use this + function, you will need to specify the expected set of columns, + as previously discussed for dblink. +

Notes

On a mismatch between the number of return columns specified in the + FROM clause, and the actual number of columns returned by the + remote cursor, an error will be thrown. In this event, the remote cursor + is still advanced by as many rows as it would have been if the error had + not occurred. The same is true for any other error occurring in the local + query after the remote FETCH has been done. +

Examples

SELECT dblink_connect('dbname=postgres');
+ dblink_connect
+----------------
+ OK
+(1 row)
+
+SELECT dblink_open('foo', 'select proname, prosrc from pg_proc where proname like ''bytea%''');
+ dblink_open
+-------------
+ OK
+(1 row)
+
+SELECT * FROM dblink_fetch('foo', 5) AS (funcname name, source text);
+ funcname |  source
+----------+----------
+ byteacat | byteacat
+ byteacmp | byteacmp
+ byteaeq  | byteaeq
+ byteage  | byteage
+ byteagt  | byteagt
+(5 rows)
+
+SELECT * FROM dblink_fetch('foo', 5) AS (funcname name, source text);
+ funcname  |  source
+-----------+-----------
+ byteain   | byteain
+ byteale   | byteale
+ bytealike | bytealike
+ bytealt   | bytealt
+ byteane   | byteane
+(5 rows)
+
+SELECT * FROM dblink_fetch('foo', 5) AS (funcname name, source text);
+  funcname  |   source
+------------+------------
+ byteanlike | byteanlike
+ byteaout   | byteaout
+(2 rows)
+
+SELECT * FROM dblink_fetch('foo', 5) AS (funcname name, source text);
+ funcname | source
+----------+--------
+(0 rows)

PrevHomeNext
dblink_openUpdblink_close
\ No newline at end of file diff --git a/doc/src/sgml/html/contrib-dblink-function.html b/doc/src/sgml/html/contrib-dblink-function.html new file mode 100644 index 000000000..17c5a182a --- /dev/null +++ b/doc/src/sgml/html/contrib-dblink-function.html @@ -0,0 +1,457 @@ + +dblink

dblink

Name

dblink -- executes a query in a remote database

Synopsis

dblink(text connname, text sql [, bool fail_on_error]) returns setof record
+dblink(text connstr, text sql [, bool fail_on_error]) returns setof record
+dblink(text sql [, bool fail_on_error]) returns setof record

Description

dblink executes a query (usually a SELECT, + but it can be any SQL statement that returns rows) in a remote database. +

When two text arguments are given, the first one is first + looked up as a persistent connection's name; if found, the command + is executed on that connection. If not found, the first argument + is treated as a connection info string as for dblink_connect, + and the indicated connection is made just for the duration of this command. +

Arguments

conname

Name of the connection to use; omit this parameter to use the + unnamed connection. +

connstr

A connection info string, as previously described for + dblink_connect. +

sql

The SQL query that you wish to execute in the remote database, + for example select * from foo. +

fail_on_error

If true (the default when omitted) then an error thrown on the + remote side of the connection causes an error to also be thrown + locally. If false, the remote error is locally reported as a NOTICE, + and the function returns no rows. +

Return Value

The function returns the row(s) produced by the query. Since + dblink can be used with any query, it is declared + to return record, rather than specifying any particular + set of columns. This means that you must specify the expected + set of columns in the calling query — otherwise + PostgreSQL would not know what to expect. + Here is an example: + +

SELECT *
+    FROM dblink('dbname=mydb', 'select proname, prosrc from pg_proc')
+      AS t1(proname name, prosrc text)
+    WHERE proname LIKE 'bytea%';

+ + The "alias" part of the FROM clause must + specify the column names and types that the function will return. + (Specifying column names in an alias is actually standard SQL + syntax, but specifying column types is a PostgreSQL + extension.) This allows the system to understand what + * should expand to, and what proname + in the WHERE clause refers to, in advance of trying + to execute the function. At run time, an error will be thrown + if the actual query result from the remote database does not + have the same number of columns shown in the FROM clause. + The column names need not match, however, and dblink + does not insist on exact type matches either. It will succeed + so long as the returned data strings are valid input for the + column type declared in the FROM clause. +

Notes

A convenient way to use dblink with predetermined + queries is to create a view. + This allows the column type information to be buried in the view, + instead of having to spell it out in every query. For example, + +

CREATE VIEW myremote_pg_proc AS
+  SELECT *
+    FROM dblink('dbname=postgres', 'select proname, prosrc from pg_proc')
+    AS t1(proname name, prosrc text);
+
+SELECT * FROM myremote_pg_proc WHERE proname LIKE 'bytea%';

Examples

SELECT * FROM dblink('dbname=postgres', 'select proname, prosrc from pg_proc')
+  AS t1(proname name, prosrc text) WHERE proname LIKE 'bytea%';
+  proname   |   prosrc
+------------+------------
+ byteacat   | byteacat
+ byteaeq    | byteaeq
+ bytealt    | bytealt
+ byteale    | byteale
+ byteagt    | byteagt
+ byteage    | byteage
+ byteane    | byteane
+ byteacmp   | byteacmp
+ bytealike  | bytealike
+ byteanlike | byteanlike
+ byteain    | byteain
+ byteaout   | byteaout
+(12 rows)
+
+SELECT dblink_connect('dbname=postgres');
+ dblink_connect
+----------------
+ OK
+(1 row)
+
+SELECT * FROM dblink('select proname, prosrc from pg_proc')
+  AS t1(proname name, prosrc text) WHERE proname LIKE 'bytea%';
+  proname   |   prosrc
+------------+------------
+ byteacat   | byteacat
+ byteaeq    | byteaeq
+ bytealt    | bytealt
+ byteale    | byteale
+ byteagt    | byteagt
+ byteage    | byteage
+ byteane    | byteane
+ byteacmp   | byteacmp
+ bytealike  | bytealike
+ byteanlike | byteanlike
+ byteain    | byteain
+ byteaout   | byteaout
+(12 rows)
+
+SELECT dblink_connect('myconn', 'dbname=regression');
+ dblink_connect
+----------------
+ OK
+(1 row)
+
+SELECT * FROM dblink('myconn', 'select proname, prosrc from pg_proc')
+  AS t1(proname name, prosrc text) WHERE proname LIKE 'bytea%';
+  proname   |   prosrc
+------------+------------
+ bytearecv  | bytearecv
+ byteasend  | byteasend
+ byteale    | byteale
+ byteagt    | byteagt
+ byteage    | byteage
+ byteane    | byteane
+ byteacmp   | byteacmp
+ bytealike  | bytealike
+ byteanlike | byteanlike
+ byteacat   | byteacat
+ byteaeq    | byteaeq
+ bytealt    | bytealt
+ byteain    | byteain
+ byteaout   | byteaout
+(14 rows)

PrevHomeNext
dblink_disconnectUpdblink_exec
\ No newline at end of file diff --git a/doc/src/sgml/html/contrib-dblink-get-connections.html b/doc/src/sgml/html/contrib-dblink-get-connections.html new file mode 100644 index 000000000..41c887251 --- /dev/null +++ b/doc/src/sgml/html/contrib-dblink-get-connections.html @@ -0,0 +1,217 @@ + +dblink_get_connections

dblink_get_connections

Name

dblink_get_connections -- returns the names of all open named dblink connections

Synopsis

dblink_get_connections() returns text[]

Description

dblink_get_connections returns an array of the names + of all open named dblink connections. +

Return Value

Returns a text array of connection names, or NULL if none.

Examples

SELECT dblink_get_connections();

PrevHomeNext
dblink_closeUpdblink_error_message
\ No newline at end of file diff --git a/doc/src/sgml/html/contrib-dblink-get-notify.html b/doc/src/sgml/html/contrib-dblink-get-notify.html new file mode 100644 index 000000000..45f2ccd8c --- /dev/null +++ b/doc/src/sgml/html/contrib-dblink-get-notify.html @@ -0,0 +1,276 @@ + +dblink_get_notify

dblink_get_notify

Name

dblink_get_notify -- retrieve async notifications on a connection

Synopsis

dblink_get_notify() returns setof (notify_name text, be_pid int, extra text)
+dblink_get_notify(text connname) returns setof (notify_name text, be_pid int, extra text)

Description

dblink_get_notify retrieves notifications on either + the unnamed connection, or on a named connection if specified. + To receive notifications via dblink, LISTEN must + first be issued, using dblink_exec. + For details see LISTEN and NOTIFY. +

Arguments

conname

The name of a named connection to get notifications on. +

Return Value

Returns setof (notify_name text, be_pid int, extra text), or an empty set if none.

Examples

SELECT dblink_exec('LISTEN virtual');
+ dblink_exec 
+-------------
+ LISTEN
+(1 row)
+
+SELECT * FROM dblink_get_notify();
+ notify_name | be_pid | extra
+-------------+--------+-------
+(0 rows)
+
+NOTIFY virtual;
+NOTIFY
+
+SELECT * FROM dblink_get_notify();
+ notify_name | be_pid | extra
+-------------+--------+-------
+ virtual     |   1229 |
+(1 row)

PrevHomeNext
dblink_is_busyUpdblink_get_result
\ No newline at end of file diff --git a/doc/src/sgml/html/contrib-dblink-get-pkey.html b/doc/src/sgml/html/contrib-dblink-get-pkey.html new file mode 100644 index 000000000..28530e431 --- /dev/null +++ b/doc/src/sgml/html/contrib-dblink-get-pkey.html @@ -0,0 +1,288 @@ + +dblink_get_pkey

dblink_get_pkey

Name

dblink_get_pkey -- returns the positions and field names of a relation's + primary key fields +

Synopsis

dblink_get_pkey(text relname) returns setof dblink_pkey_results

Description

dblink_get_pkey provides information about the primary + key of a relation in the local database. This is sometimes useful + in generating queries to be sent to remote databases. +

Arguments

relname

Name of a local relation, for example foo or + myschema.mytab. Include double quotes if the + name is mixed-case or contains special characters, for + example "FooBar"; without quotes, the string + will be folded to lower case. +

Return Value

Returns one row for each primary key field, or no rows if the relation + has no primary key. The result row type is defined as + +

CREATE TYPE dblink_pkey_results AS (position int, colname text);

+ + The position column simply runs from 1 to N; + it is the number of the field within the primary key, not the number + within the table's columns. +

Examples

CREATE TABLE foobar (
+    f1 int,
+    f2 int,
+    f3 int,
+    PRIMARY KEY (f1, f2, f3)
+);
+CREATE TABLE
+
+SELECT * FROM dblink_get_pkey('foobar');
+ position | colname
+----------+---------
+        1 | f1
+        2 | f2
+        3 | f3
+(3 rows)

PrevHomeNext
dblink_cancel_queryUpdblink_build_sql_insert
\ No newline at end of file diff --git a/doc/src/sgml/html/contrib-dblink-get-result.html b/doc/src/sgml/html/contrib-dblink-get-result.html new file mode 100644 index 000000000..18632913d --- /dev/null +++ b/doc/src/sgml/html/contrib-dblink-get-result.html @@ -0,0 +1,380 @@ + +dblink_get_result

dblink_get_result

Name

dblink_get_result -- gets an async query result

Synopsis

dblink_get_result(text connname [, bool fail_on_error]) returns setof record

Description

dblink_get_result collects the results of an + asynchronous query previously sent with dblink_send_query. + If the query is not already completed, dblink_get_result + will wait until it is. +

Arguments

conname

Name of the connection to use. +

fail_on_error

If true (the default when omitted) then an error thrown on the + remote side of the connection causes an error to also be thrown + locally. If false, the remote error is locally reported as a NOTICE, + and the function returns no rows. +

Return Value

For an async query (that is, a SQL statement returning rows), + the function returns the row(s) produced by the query. To use this + function, you will need to specify the expected set of columns, + as previously discussed for dblink. +

For an async command (that is, a SQL statement not returning rows), + the function returns a single row with a single text column containing + the command's status string. It is still necessary to specify that + the result will have a single text column in the calling FROM + clause. +

Notes

This function must be called if + dblink_send_query returned 1. + It must be called once for each query + sent, and one additional time to obtain an empty set result, + before the connection can be used again. +

When using dblink_send_query and + dblink_get_result, dblink fetches the entire + remote query result before returning any of it to the local query + processor. If the query returns a large number of rows, this can result + in transient memory bloat in the local session. It may be better to open + such a query as a cursor with dblink_open and then fetch a + manageable number of rows at a time. Alternatively, use plain + dblink(), which avoids memory bloat by spooling large result + sets to disk. +

Examples

contrib_regression=# SELECT dblink_connect('dtest1', 'dbname=contrib_regression');
+ dblink_connect
+----------------
+ OK
+(1 row)
+
+contrib_regression=# SELECT * FROM
+contrib_regression-# dblink_send_query('dtest1', 'select * from foo where f1 < 3') AS t1;
+ t1
+----
+  1
+(1 row)
+
+contrib_regression=# SELECT * FROM dblink_get_result('dtest1') AS t1(f1 int, f2 text, f3 text[]);
+ f1 | f2 |     f3
+----+----+------------
+  0 | a  | {a0,b0,c0}
+  1 | b  | {a1,b1,c1}
+  2 | c  | {a2,b2,c2}
+(3 rows)
+
+contrib_regression=# SELECT * FROM dblink_get_result('dtest1') AS t1(f1 int, f2 text, f3 text[]);
+ f1 | f2 | f3
+----+----+----
+(0 rows)
+
+contrib_regression=# SELECT * FROM
+contrib_regression-# dblink_send_query('dtest1', 'select * from foo where f1 < 3; select * from foo where f1 > 6') AS t1;
+ t1
+----
+  1
+(1 row)
+
+contrib_regression=# SELECT * FROM dblink_get_result('dtest1') AS t1(f1 int, f2 text, f3 text[]);
+ f1 | f2 |     f3
+----+----+------------
+  0 | a  | {a0,b0,c0}
+  1 | b  | {a1,b1,c1}
+  2 | c  | {a2,b2,c2}
+(3 rows)
+
+contrib_regression=# SELECT * FROM dblink_get_result('dtest1') AS t1(f1 int, f2 text, f3 text[]);
+ f1 | f2 |      f3
+----+----+---------------
+  7 | h  | {a7,b7,c7}
+  8 | i  | {a8,b8,c8}
+  9 | j  | {a9,b9,c9}
+ 10 | k  | {a10,b10,c10}
+(4 rows)
+
+contrib_regression=# SELECT * FROM dblink_get_result('dtest1') AS t1(f1 int, f2 text, f3 text[]);
+ f1 | f2 | f3
+----+----+----
+(0 rows)

PrevHomeNext
dblink_get_notifyUpdblink_cancel_query
\ No newline at end of file diff --git a/doc/src/sgml/html/contrib-dblink-is-busy.html b/doc/src/sgml/html/contrib-dblink-is-busy.html new file mode 100644 index 000000000..7dba9cf8b --- /dev/null +++ b/doc/src/sgml/html/contrib-dblink-is-busy.html @@ -0,0 +1,244 @@ + +dblink_is_busy

dblink_is_busy

Name

dblink_is_busy -- checks if connection is busy with an async query

Synopsis

dblink_is_busy(text connname) returns int

Description

dblink_is_busy tests whether an async query is in progress. +

Arguments

conname

Name of the connection to check. +

Return Value

Returns 1 if connection is busy, 0 if it is not busy. + If this function returns 0, it is guaranteed that + dblink_get_result will not block. +

Examples

SELECT dblink_is_busy('dtest1');

PrevHomeNext
dblink_send_queryUpdblink_get_notify
\ No newline at end of file diff --git a/doc/src/sgml/html/contrib-dblink-open.html b/doc/src/sgml/html/contrib-dblink-open.html new file mode 100644 index 000000000..443c15f78 --- /dev/null +++ b/doc/src/sgml/html/contrib-dblink-open.html @@ -0,0 +1,359 @@ + +dblink_open

dblink_open

Name

dblink_open -- opens a cursor in a remote database

Synopsis

dblink_open(text cursorname, text sql [, bool fail_on_error]) returns text
+dblink_open(text connname, text cursorname, text sql [, bool fail_on_error]) returns text

Description

dblink_open() opens a cursor in a remote database. + The cursor can subsequently be manipulated with + dblink_fetch() and dblink_close(). +

Arguments

conname

Name of the connection to use; omit this parameter to use the + unnamed connection. +

cursorname

The name to assign to this cursor. +

sql

The SELECT statement that you wish to execute in the remote + database, for example select * from pg_class. +

fail_on_error

If true (the default when omitted) then an error thrown on the + remote side of the connection causes an error to also be thrown + locally. If false, the remote error is locally reported as a NOTICE, + and the function's return value is set to ERROR. +

Return Value

Returns status, either OK or ERROR. +

Notes

Since a cursor can only persist within a transaction, + dblink_open starts an explicit transaction block + (BEGIN) on the remote side, if the remote side was + not already within a transaction. This transaction will be + closed again when the matching dblink_close is + executed. Note that if + you use dblink_exec to change data between + dblink_open and dblink_close, + and then an error occurs or you use dblink_disconnect before + dblink_close, your change will be + lost because the transaction will be aborted. +

Examples

SELECT dblink_connect('dbname=postgres');
+ dblink_connect
+----------------
+ OK
+(1 row)
+
+SELECT dblink_open('foo', 'select proname, prosrc from pg_proc');
+ dblink_open
+-------------
+ OK
+(1 row)

PrevHomeNext
dblink_execUpdblink_fetch
\ No newline at end of file diff --git a/doc/src/sgml/html/contrib-dblink-send-query.html b/doc/src/sgml/html/contrib-dblink-send-query.html new file mode 100644 index 000000000..c92847cab --- /dev/null +++ b/doc/src/sgml/html/contrib-dblink-send-query.html @@ -0,0 +1,272 @@ + +dblink_send_query

dblink_send_query

Name

dblink_send_query -- sends an async query to a remote database

Synopsis

dblink_send_query(text connname, text sql) returns int

Description

dblink_send_query sends a query to be executed + asynchronously, that is, without immediately waiting for the result. + There must not be an async query already in progress on the + connection. +

After successfully dispatching an async query, completion status + can be checked with dblink_is_busy, and the results + are ultimately collected with dblink_get_result. + It is also possible to attempt to cancel an active async query + using dblink_cancel_query. +

Arguments

conname

Name of the connection to use. +

sql

The SQL statement that you wish to execute in the remote database, + for example select * from pg_class. +

Return Value

Returns 1 if the query was successfully dispatched, 0 otherwise. +

Examples

SELECT dblink_send_query('dtest1', 'SELECT * FROM foo WHERE f1 < 3');

PrevHomeNext
dblink_error_messageUpdblink_is_busy
\ No newline at end of file diff --git a/doc/src/sgml/html/contrib-prog-client.html b/doc/src/sgml/html/contrib-prog-client.html new file mode 100644 index 000000000..8db8b524d --- /dev/null +++ b/doc/src/sgml/html/contrib-prog-client.html @@ -0,0 +1,224 @@ + +Client Applications
PostgreSQL 9.2.2 Documentation
PrevUpAppendix G. Additional Supplied ProgramsNext

G.1. Client Applications

Table of Contents
oid2name -- resolve OIDs and file nodes in a PostgreSQL data directory
pgbench -- run a benchmark test on PostgreSQL
vacuumlo -- remove orphaned large objects from a PostgreSQL database

This section covers PostgreSQL client + applications in contrib. They can be run from anywhere, + independent of where the database server resides. See + also Reference II, PostgreSQL Client Applications for information about client + applications that part of the core PostgreSQL + distribution. +


PrevHomeNext
Additional Supplied ProgramsUpoid2name
\ No newline at end of file diff --git a/doc/src/sgml/html/contrib-prog-server.html b/doc/src/sgml/html/contrib-prog-server.html new file mode 100644 index 000000000..112b6ffef --- /dev/null +++ b/doc/src/sgml/html/contrib-prog-server.html @@ -0,0 +1,250 @@ + +Server Applications
PostgreSQL 9.2.2 Documentation
PrevUpAppendix G. Additional Supplied ProgramsNext

G.2. Server Applications

Table of Contents
pg_archivecleanup -- clean up PostgreSQL WAL archive files
pg_standby -- supports the creation of a PostgreSQL warm standby server
pg_test_fsync -- determine fastest wal_sync_method for PostgreSQL
pg_test_timing -- measure timing overhead
pg_upgrade -- upgrade a PostgreSQL server instance

This section covers PostgreSQL server-related + applications in contrib. They are typically run on the + host where the database server resides. See also Reference III, PostgreSQL Server Applications for information about server applications that + part of the core PostgreSQL distribution. +


PrevHomeNext
vacuumloUppg_archivecleanup
\ No newline at end of file diff --git a/doc/src/sgml/html/contrib-prog.html b/doc/src/sgml/html/contrib-prog.html new file mode 100644 index 000000000..ddcc44adb --- /dev/null +++ b/doc/src/sgml/html/contrib-prog.html @@ -0,0 +1,220 @@ + +Additional Supplied Programs

Appendix G. Additional Supplied Programs

Table of Contents
G.1. Client Applications
G.2. Server Applications

This appendix and the previous one contain information regarding the modules that + can be found in the contrib directory of the + PostgreSQL distribution. See Appendix F for + more information about the contrib section in general and + server extensions and plug-ins found in contrib + specifically. +

This appendix covers utility programs found in contrib. + Once installed, either from source or a packaging system, they are found in + the bin directory of the + PostgreSQL installation and can be used like any + other program. +


PrevHomeNext
xml2UpClient Applications
\ No newline at end of file diff --git a/doc/src/sgml/html/contrib-spi.html b/doc/src/sgml/html/contrib-spi.html new file mode 100644 index 000000000..4242450b2 --- /dev/null +++ b/doc/src/sgml/html/contrib-spi.html @@ -0,0 +1,515 @@ + +spi
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.33. spi

The spi module provides several workable examples + of using SPI and triggers. While these functions are of some value in + their own right, they are even more useful as examples to modify for + your own purposes. The functions are general enough to be used + with any table, but you have to specify table and field names (as described + below) while creating a trigger. +

Each of the groups of functions described below is provided as a + separately-installable extension. +

F.33.1. refint — Functions for Implementing Referential Integrity

check_primary_key() and + check_foreign_key() are used to check foreign key constraints. + (This functionality is long since superseded by the built-in foreign + key mechanism, of course, but the module is still useful as an example.) +

check_primary_key() checks the referencing table. + To use, create a BEFORE INSERT OR UPDATE trigger using this + function on a table referencing another table. Specify as the trigger + arguments: the referencing table's column name(s) which form the foreign + key, the referenced table name, and the column names in the referenced table + which form the primary/unique key. To handle multiple foreign + keys, create a trigger for each reference. +

check_foreign_key() checks the referenced table. + To use, create a BEFORE DELETE OR UPDATE trigger using this + function on a table referenced by other table(s). Specify as the trigger + arguments: the number of referencing tables for which the function has to + perform checking, the action if a referencing key is found + (cascade — to delete the referencing row, + restrict — to abort transaction if referencing keys + exist, setnull — to set referencing key fields to null), + the triggered table's column names which form the primary/unique key, then + the referencing table name and column names (repeated for as many + referencing tables as were specified by first argument). Note that the + primary/unique key columns should be marked NOT NULL and should have a + unique index. +

There are examples in refint.example. +

F.33.2. timetravel — Functions for Implementing Time Travel

Long ago, PostgreSQL had a built-in time travel feature + that kept the insert and delete times for each tuple. This can be + emulated using these functions. To use these functions, + you must add to a table two columns of abstime type to store + the date when a tuple was inserted (start_date) and changed/deleted + (stop_date): + +

CREATE TABLE mytab (
+        ...             ...
+        start_date      abstime,
+        stop_date       abstime
+        ...             ...
+);

+ + The columns can be named whatever you like, but in this discussion + we'll call them start_date and stop_date. +

When a new row is inserted, start_date should normally be set to + current time, and stop_date to infinity. The trigger + will automatically substitute these values if the inserted data + contains nulls in these columns. Generally, inserting explicit + non-null data in these columns should only be done when re-loading + dumped data. +

Tuples with stop_date equal to infinity are "valid + now", and can be modified. Tuples with a finite stop_date cannot + be modified anymore — the trigger will prevent it. (If you need + to do that, you can turn off time travel as shown below.) +

For a modifiable row, on update only the stop_date in the tuple being + updated will be changed (to current time) and a new tuple with the modified + data will be inserted. Start_date in this new tuple will be set to current + time and stop_date to infinity. +

A delete does not actually remove the tuple but only sets its stop_date + to current time. +

To query for tuples "valid now", include + stop_date = 'infinity' in the query's WHERE condition. + (You might wish to incorporate that in a view.) Similarly, you can + query for tuples valid at any past time with suitable conditions on + start_date and stop_date. +

timetravel() is the general trigger function that supports + this behavior. Create a BEFORE INSERT OR UPDATE OR DELETE + trigger using this function on each time-traveled table. Specify two + trigger arguments: the actual + names of the start_date and stop_date columns. + Optionally, you can specify one to three more arguments, which must refer + to columns of type text. The trigger will store the name of + the current user into the first of these columns during INSERT, the + second column during UPDATE, and the third during DELETE. +

set_timetravel() allows you to turn time-travel on or off for + a table. + set_timetravel('mytab', 1) will turn TT ON for table mytab. + set_timetravel('mytab', 0) will turn TT OFF for table mytab. + In both cases the old status is reported. While TT is off, you can modify + the start_date and stop_date columns freely. Note that the on/off status + is local to the current database session — fresh sessions will + always start out with TT ON for all tables. +

get_timetravel() returns the TT state for a table without + changing it. +

There is an example in timetravel.example. +

F.33.3. autoinc — Functions for Autoincrementing Fields

autoinc() is a trigger that stores the next value of + a sequence into an integer field. This has some overlap with the + built-in "serial column" feature, but it is not the same: + autoinc() will override attempts to substitute a + different field value during inserts, and optionally it can be + used to increment the field during updates, too. +

To use, create a BEFORE INSERT (or optionally BEFORE + INSERT OR UPDATE) trigger using this function. Specify two + trigger arguments: the name of the integer column to be modified, + and the name of the sequence object that will supply values. + (Actually, you can specify any number of pairs of such names, if + you'd like to update more than one autoincrementing column.) +

There is an example in autoinc.example. +

F.33.4. insert_username — Functions for Tracking Who Changed a Table

insert_username() is a trigger that stores the current + user's name into a text field. This can be useful for tracking + who last modified a particular row within a table. +

To use, create a BEFORE INSERT and/or UPDATE + trigger using this function. Specify a single trigger + argument: the name of the text column to be modified. +

There is an example in insert_username.example. +

F.33.5. moddatetime — Functions for Tracking Last Modification Time

moddatetime() is a trigger that stores the current + time into a timestamp field. This can be useful for tracking + the last modification time of a particular row within a table. +

To use, create a BEFORE UPDATE + trigger using this function. Specify a single trigger + argument: the name of the column to be modified. + The column must be of type timestamp or timestamp with + time zone. +

There is an example in moddatetime.example. +


PrevHomeNext
sepgsqlUpsslinfo
\ No newline at end of file diff --git a/doc/src/sgml/html/contrib.html b/doc/src/sgml/html/contrib.html new file mode 100644 index 000000000..67b305864 --- /dev/null +++ b/doc/src/sgml/html/contrib.html @@ -0,0 +1,565 @@ + +Additional Supplied Modules

Appendix F. Additional Supplied Modules

Table of Contents
F.1. adminpack
F.2. auth_delay
F.3. auto_explain
F.4. btree_gin
F.5. btree_gist
F.6. chkpass
F.7. citext
F.8. cube
F.9. dblink
F.10. dict_int
F.11. dict_xsyn
F.12. dummy_seclabel
F.13. earthdistance
F.14. file_fdw
F.15. fuzzystrmatch
F.16. hstore
F.17. intagg
F.18. intarray
F.19. isn
F.20. lo
F.21. ltree
F.22. pageinspect
F.23. passwordcheck
F.24. pg_buffercache
F.25. pgcrypto
F.26. pg_freespacemap
F.27. pgrowlocks
F.28. pg_stat_statements
F.29. pgstattuple
F.30. pg_trgm
F.31. seg
F.32. sepgsql
F.33. spi
F.34. sslinfo
F.35. tablefunc
F.36. tcn
F.37. test_parser
F.38. tsearch2
F.39. unaccent
F.40. uuid-ossp
F.41. xml2

This appendix and the next one contain information regarding the modules that + can be found in the contrib directory of the + PostgreSQL distribution. + These include porting tools, analysis utilities, + and plug-in features that are not part of the core PostgreSQL system, + mainly because they address a limited audience or are too experimental + to be part of the main source tree. This does not preclude their + usefulness. +

This appendix covers extensions and other server plug-in modules found in + contrib. Appendix G covers utility + programs. +

When building from the source distribution, these components are not built + automatically, unless you build the "world" target + (see step 2). + You can build and install all of them by running: +

gmake
+gmake install

+ in the contrib directory of a configured source tree; + or to build and install + just one selected module, do the same in that module's subdirectory. + Many of the modules have regression tests, which can be executed by + running: +

gmake check

+ before installation or +

gmake installcheck

+ once you have a PostgreSQL server running. +

If you are using a pre-packaged version of PostgreSQL, + these modules are typically made available as a separate subpackage, + such as postgresql-contrib. +

Many modules supply new user-defined functions, operators, or types. + To make use of one of these modules, after you have installed the code + you need to register the new SQL objects in the database system. + In PostgreSQL 9.1 and later, this is done by executing + a CREATE EXTENSION command. In a fresh database, + you can simply do + +

CREATE EXTENSION module_name;

+ + This command must be run by a database superuser. This registers the + new SQL objects in the current database only, so you need to run this + command in each database that you want + the module's facilities to be available in. Alternatively, run it in + database template1 so that the extension will be copied into + subsequently-created databases by default. +

Many modules allow you to install their objects in a schema of your + choice. To do that, add SCHEMA + schema_name to the CREATE EXTENSION + command. By default, the objects will be placed in your current creation + target schema, typically public. +

If your database was brought forward by dump and reload from a pre-9.1 + version of PostgreSQL, and you had been using the pre-9.1 + version of the module in it, you should instead do + +

CREATE EXTENSION module_name FROM unpackaged;

+ + This will update the pre-9.1 objects of the module into a proper + extension object. Future updates to the module will be + managed by ALTER EXTENSION. + For more information about extension updates, see + Section 35.15. +

Note, however, that some of these modules are not "extensions" + in this sense, but are loaded into the server in some other way, for instance + by way of + shared_preload_libraries. See the documentation of each + module for details. +


PrevHomeNext
Postgres95 Release 0.01Upadminpack
\ No newline at end of file diff --git a/doc/src/sgml/html/creating-cluster.html b/doc/src/sgml/html/creating-cluster.html new file mode 100644 index 000000000..891ab5378 --- /dev/null +++ b/doc/src/sgml/html/creating-cluster.html @@ -0,0 +1,526 @@ + +Creating a Database Cluster
PostgreSQL 9.2.2 Documentation
PrevUpChapter 17. Server Setup and OperationNext

17.2. Creating a Database Cluster

Before you can do anything, you must initialize a database storage + area on disk. We call this a database cluster. + (SQL uses the term catalog cluster.) A + database cluster is a collection of databases that is managed by a + single instance of a running database server. After initialization, a + database cluster will contain a database named postgres, + which is meant as a default database for use by utilities, users and third + party applications. The database server itself does not require the + postgres database to exist, but many external utility + programs assume it exists. Another database created within each cluster + during initialization is called + template1. As the name suggests, this will be used + as a template for subsequently created databases; it should not be + used for actual work. (See Chapter 21 for + information about creating new databases within a cluster.) +

In file system terms, a database cluster will be a single directory + under which all data will be stored. We call this the data + directory or data area. It is + completely up to you where you choose to store your data. There is no + default, although locations such as + /usr/local/pgsql/data or + /var/lib/pgsql/data are popular. To initialize a + database cluster, use the command initdb, which is + installed with PostgreSQL. The desired + file system location of your database cluster is indicated by the + -D option, for example: +

$ initdb -D /usr/local/pgsql/data

+ Note that you must execute this command while logged into the + PostgreSQL user account, which is + described in the previous section. +

Tip: As an alternative to the -D option, you can set + the environment variable PGDATA. + +

Alternatively, you can run initdb via + the pg_ctl + program like so: +

$ pg_ctl -D /usr/local/pgsql/data initdb

+ This may be more intuitive if you are + using pg_ctl for starting and stopping the + server (see Section 17.3), so + that pg_ctl would be the sole command you use + for managing the database server instance. +

initdb will attempt to create the directory you + specify if it does not already exist. It is likely that it will not + have the permission to do so (if you followed our advice and created + an unprivileged account). In that case you should create the + directory yourself (as root) and change the owner to be the + PostgreSQL user. Here is how this might + be done: +

root# mkdir /usr/local/pgsql/data
+root# chown postgres /usr/local/pgsql/data
+root# su postgres
+postgres$ initdb -D /usr/local/pgsql/data

+

initdb will refuse to run if the data directory + looks like it has already been initialized.

Because the data directory contains all the data stored in the + database, it is essential that it be secured from unauthorized + access. initdb therefore revokes access + permissions from everyone but the + PostgreSQL user. +

However, while the directory contents are secure, the default + client authentication setup allows any local user to connect to the + database and even become the database superuser. If you do not + trust other local users, we recommend you use one of + initdb's -W, --pwprompt + or --pwfile options to assign a password to the + database superuser. + Also, specify -A md5 or + -A password so that the default trust authentication + mode is not used; or modify the generated pg_hba.conf + file after running initdb, but + before you start the server for the first time. (Other + reasonable approaches include using peer authentication + or file system permissions to restrict connections. See Chapter 19 for more information.) +

initdb also initializes the default + locale for the database cluster. + Normally, it will just take the locale settings in the environment + and apply them to the initialized database. It is possible to + specify a different locale for the database; more information about + that can be found in Section 22.1. The default sort order used + within the particular database cluster is set by + initdb, and while you can create new databases using + different sort order, the order used in the template databases that initdb + creates cannot be changed without dropping and recreating them. + There is also a performance impact for using locales + other than C or POSIX. Therefore, it is + important to make this choice correctly the first time. +

initdb also sets the default character set encoding + for the database cluster. Normally this should be chosen to match the + locale setting. For details see Section 22.3. +

17.2.1. Network File Systems

Many installations create database clusters on network file systems. + Sometimes this is done directly via NFS, or by using a + Network Attached Storage (NAS) device that uses + NFS internally. PostgreSQL does nothing + special for NFS file systems, meaning it assumes + NFS behaves exactly like locally-connected drives + (DAS, Direct Attached Storage). If client and server + NFS implementations have non-standard semantics, this can + cause reliability problems (see http://www.time-travellers.org/shane/papers/NFS_considered_harmful.html). + Specifically, delayed (asynchronous) writes to the NFS + server can cause reliability problems; if possible, mount + NFS file systems synchronously (without caching) to avoid + this. Also, soft-mounting NFS is not recommended. + (Storage Area Networks (SAN) use a low-level + communication protocol rather than NFS.) +


PrevHomeNext
The PostgreSQL User AccountUpStarting the Database Server
\ No newline at end of file diff --git a/doc/src/sgml/html/cube.html b/doc/src/sgml/html/cube.html new file mode 100644 index 000000000..2c58f8d85 --- /dev/null +++ b/doc/src/sgml/html/cube.html @@ -0,0 +1,996 @@ + +cube
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.8. cube

This module implements a data type cube for + representing multidimensional cubes. +

F.8.1. Syntax

Table F-1 shows the valid external + representations for the cube + type. x, y, etc. denote + floating-point numbers. +

Table F-1. Cube External Representations

xA one-dimensional point + (or, zero-length one-dimensional interval) +
(x)Same as above
x1,x2,...,xnA point in n-dimensional space, represented internally as a + zero-volume cube +
(x1,x2,...,xn)Same as above
(x),(y)A one-dimensional interval starting at x and ending at y or vice versa; the + order does not matter +
[(x),(y)]Same as above
(x1,...,xn),(y1,...,yn)An n-dimensional cube represented by a pair of its diagonally + opposite corners +
[(x1,...,xn),(y1,...,yn)]Same as above

It does not matter which order the opposite corners of a cube are + entered in. The cube functions + automatically swap values if needed to create a uniform + "lower left — upper right" internal representation. +

White space is ignored, so [(x),(y)] is the same as + [ ( x ), ( y ) ]. +

F.8.2. Precision

Values are stored internally as 64-bit floating point numbers. This means + that numbers with more than about 16 significant digits will be truncated. +

F.8.3. Usage

The cube module includes a GiST index operator class for + cube values. + The operators supported by the GiST operator class are shown in Table F-2. +

Table F-2. Cube GiST Operators

OperatorDescription
a = bThe cubes a and b are identical.
a && bThe cubes a and b overlap.
a @> bThe cube a contains the cube b.
a <@ bThe cube a is contained in the cube b.

(Before PostgreSQL 8.2, the containment operators @> and <@ were + respectively called @ and ~. These names are still available, but are + deprecated and will eventually be retired. Notice that the old names + are reversed from the convention formerly followed by the core geometric + data types!) +

The standard B-tree operators are also provided, for example + +

OperatorDescription
[a, b] < [c, d]Less than
[a, b] > [c, d]Greater than

+ + These operators do not make a lot of sense for any practical + purpose but sorting. These operators first compare (a) to (c), + and if these are equal, compare (b) to (d). That results in + reasonably good sorting in most cases, which is useful if + you want to use ORDER BY with this type. +

Table F-3 shows the available functions. +

Table F-3. Cube Functions

cube(float8) returns cubeMakes a one dimensional cube with both coordinates the same. + cube(1) == '(1)' +
cube(float8, float8) returns cubeMakes a one dimensional cube. + cube(1,2) == '(1),(2)' +
cube(float8[]) returns cubeMakes a zero-volume cube using the coordinates + defined by the array. + cube(ARRAY[1,2]) == '(1,2)' +
cube(float8[], float8[]) returns cubeMakes a cube with upper right and lower left + coordinates as defined by the two arrays, which must be of the + same length. + cube('{1,2}'::float[], '{3,4}'::float[]) == '(1,2),(3,4)' + +
cube(cube, float8) returns cubeMakes a new cube by adding a dimension on to an + existing cube with the same values for both parts of the new coordinate. + This is useful for building cubes piece by piece from calculated values. + cube('(1)',2) == '(1,2),(1,2)' +
cube(cube, float8, float8) returns cubeMakes a new cube by adding a dimension on to an + existing cube. This is useful for building cubes piece by piece from + calculated values. cube('(1,2)',3,4) == '(1,3),(2,4)' +
cube_dim(cube) returns intReturns the number of dimensions of the cube +
cube_ll_coord(cube, int) returns double Returns the n'th coordinate value for the lower left + corner of a cube +
cube_ur_coord(cube, int) returns double + Returns the n'th coordinate value for the + upper right corner of a cube +
cube_is_point(cube) returns boolReturns true if a cube is a point, that is, + the two defining corners are the same.
cube_distance(cube, cube) returns doubleReturns the distance between two cubes. If both + cubes are points, this is the normal distance function. +
cube_subset(cube, int[]) returns cube + Makes a new cube from an existing cube, using a list of + dimension indexes from an array. Can be used to find both the LL and UR + coordinates of a single dimension, e.g. + cube_subset(cube('(1,3,5),(6,7,8)'), ARRAY[2]) = '(3),(7)'. + Or can be used to drop dimensions, or reorder them as desired, e.g. + cube_subset(cube('(1,3,5),(6,7,8)'), ARRAY[3,2,1,1]) = '(5, 3, + 1, 1),(8, 7, 6, 6)'. +
cube_union(cube, cube) returns cubeProduces the union of two cubes +
cube_inter(cube, cube) returns cubeProduces the intersection of two cubes +
cube_enlarge(cube c, double r, int n) returns cubeIncreases the size of a cube by a specified radius in at least + n dimensions. If the radius is negative the cube is shrunk instead. This + is useful for creating bounding boxes around a point for searching for + nearby points. All defined dimensions are changed by the radius r. + LL coordinates are decreased by r and UR coordinates are increased by r. + If a LL coordinate is increased to larger than the corresponding UR + coordinate (this can only happen when r < 0) than both coordinates + are set to their average. If n is greater than the number of defined + dimensions and the cube is being increased (r >= 0) then 0 is used + as the base for the extra coordinates. +

F.8.4. Defaults

I believe this union: +

select cube_union('(0,5,2),(2,3,1)', '0');
+cube_union
+-------------------
+(0, 0, 0),(2, 5, 2)
+(1 row)

does not contradict common sense, neither does the intersection +

select cube_inter('(0,-1),(1,1)', '(-2),(2)');
+cube_inter
+-------------
+(0, 0),(1, 0)
+(1 row)

In all binary operations on differently-dimensioned cubes, I assume the + lower-dimensional one to be a Cartesian projection, i. e., having zeroes + in place of coordinates omitted in the string representation. The above + examples are equivalent to: +

cube_union('(0,5,2),(2,3,1)','(0,0,0),(0,0,0)');
+cube_inter('(0,-1),(1,1)','(-2,0),(2,0)');

The following containment predicate uses the point syntax, + while in fact the second argument is internally represented by a box. + This syntax makes it unnecessary to define a separate point type + and functions for (box,point) predicates. +

select cube_contains('(0,0),(1,1)', '0.5,0.5');
+cube_contains
+--------------
+t
+(1 row)

F.8.5. Notes

For examples of usage, see the regression test sql/cube.sql. +

To make it harder for people to break things, there + is a limit of 100 on the number of dimensions of cubes. This is set + in cubedata.h if you need something bigger. +

F.8.6. Credits

Original author: Gene Selkov, Jr. <selkovjr@mcs.anl.gov>, + Mathematics and Computer Science Division, Argonne National Laboratory. +

My thanks are primarily to Prof. Joe Hellerstein + (http://db.cs.berkeley.edu/jmh/) for elucidating the + gist of the GiST (http://gist.cs.berkeley.edu/), and + to his former student, Andy Dong (http://best.me.berkeley.edu/~adong/), for his example + written for Illustra, + http://best.berkeley.edu/~adong/rtree/index.html. + I am also grateful to all Postgres developers, present and past, for + enabling myself to create my own world and live undisturbed in it. And I + would like to acknowledge my gratitude to Argonne Lab and to the + U.S. Department of Energy for the years of faithful support of my database + research. +

Minor updates to this package were made by Bruno Wolff III + <bruno@wolff.to> in August/September of 2002. These include + changing the precision from single precision to double precision and adding + some new functions. +

Additional updates were made by Joshua Reich <josh@root.net> in + July 2006. These include cube(float8[], float8[]) and + cleaning up the code to use the V1 call protocol instead of the deprecated + V0 protocol. +


PrevHomeNext
citextUpdblink
\ No newline at end of file diff --git a/doc/src/sgml/html/database-roles.html b/doc/src/sgml/html/database-roles.html new file mode 100644 index 000000000..da9aeaa0c --- /dev/null +++ b/doc/src/sgml/html/database-roles.html @@ -0,0 +1,323 @@ + +Database Roles

20.1. Database Roles

Database roles are conceptually completely separate from + operating system users. In practice it might be convenient to + maintain a correspondence, but this is not required. Database roles + are global across a database cluster installation (and not + per individual database). To create a role use the CREATE ROLE SQL command: +

CREATE ROLE name;

+ name follows the rules for SQL + identifiers: either unadorned without special characters, or + double-quoted. (In practice, you will usually want to add additional + options, such as LOGIN, to the command. More details appear + below.) To remove an existing role, use the analogous + DROP ROLE command: +

DROP ROLE name;

+

For convenience, the programs createuser + and dropuser are provided as wrappers + around these SQL commands that can be called from the shell command + line: +

createuser name
+dropuser name

+

To determine the set of existing roles, examine the pg_roles + system catalog, for example +

SELECT rolname FROM pg_roles;

+ The psql program's \du meta-command + is also useful for listing the existing roles. +

In order to bootstrap the database system, a freshly initialized + system always contains one predefined role. This role is always + a "superuser", and by default (unless altered when running + initdb) it will have the same name as the + operating system user that initialized the database + cluster. Customarily, this role will be named + postgres. In order to create more roles you + first have to connect as this initial role. +

Every connection to the database server is made using the name of some + particular role, and this role determines the initial access privileges for + commands issued in that connection. + The role name to use for a particular database + connection is indicated by the client that is initiating the + connection request in an application-specific fashion. For example, + the psql program uses the + -U command line option to indicate the role to + connect as. Many applications assume the name of the current + operating system user by default (including + createuser and psql). Therefore it + is often convenient to maintain a naming correspondence between + roles and operating system users. +

The set of database roles a given client connection can connect as + is determined by the client authentication setup, as explained in + Chapter 19. (Thus, a client is not + limited to connect as the role matching + its operating system user, just as a person's login name + need not match her real name.) Since the role + identity determines the set of privileges available to a connected + client, it is important to carefully configure privileges when setting up + a multiuser environment. +


PrevHomeNext
Database RolesUpRole Attributes
\ No newline at end of file diff --git a/doc/src/sgml/html/datatype-binary.html b/doc/src/sgml/html/datatype-binary.html new file mode 100644 index 000000000..278fcfc0c --- /dev/null +++ b/doc/src/sgml/html/datatype-binary.html @@ -0,0 +1,724 @@ + +Binary Data Types

8.4. Binary Data Types

The bytea data type allows storage of binary strings; + see Table 8-6. +

Table 8-6. Binary Data Types

NameStorage SizeDescription
bytea1 or 4 bytes plus the actual binary stringvariable-length binary string

A binary string is a sequence of octets (or bytes). Binary + strings are distinguished from character strings in two + ways. First, binary strings specifically allow storing + octets of value zero and other "non-printable" + octets (usually, octets outside the range 32 to 126). + Character strings disallow zero octets, and also disallow any + other octet values and sequences of octet values that are invalid + according to the database's selected character set encoding. + Second, operations on binary strings process the actual bytes, + whereas the processing of character strings depends on locale settings. + In short, binary strings are appropriate for storing data that the + programmer thinks of as "raw bytes", whereas character + strings are appropriate for storing text. +

The bytea type supports two external formats for + input and output: PostgreSQL's historical + "escape" format, and "hex" format. Both + of these are always accepted on input. The output format depends + on the configuration parameter bytea_output; + the default is hex. (Note that the hex format was introduced in + PostgreSQL 9.0; earlier versions and some + tools don't understand it.) +

The SQL standard defines a different binary + string type, called BLOB or BINARY LARGE + OBJECT. The input format is different from + bytea, but the provided functions and operators are + mostly the same. +

8.4.1. bytea Hex Format

The "hex" format encodes binary data as 2 hexadecimal digits + per byte, most significant nibble first. The entire string is + preceded by the sequence \x (to distinguish it + from the escape format). In some contexts, the initial backslash may + need to be escaped by doubling it, in the same cases in which backslashes + have to be doubled in escape format; details appear below. + The hexadecimal digits can + be either upper or lower case, and whitespace is permitted between + digit pairs (but not within a digit pair nor in the starting + \x sequence). + The hex format is compatible with a wide + range of external applications and protocols, and it tends to be + faster to convert than the escape format, so its use is preferred. +

Example: +

SELECT E'\\xDEADBEEF';

+

8.4.2. bytea Escape Format

The "escape" format is the traditional + PostgreSQL format for the bytea + type. It + takes the approach of representing a binary string as a sequence + of ASCII characters, while converting those bytes that cannot be + represented as an ASCII character into special escape sequences. + If, from the point of view of the application, representing bytes + as characters makes sense, then this representation can be + convenient. But in practice it is usually confusing because it + fuzzes up the distinction between binary strings and character + strings, and also the particular escape mechanism that was chosen is + somewhat unwieldy. So this format should probably be avoided + for most new applications. +

When entering bytea values in escape format, + octets of certain + values must be escaped, while all octet + values can be escaped. In + general, to escape an octet, convert it into its three-digit + octal value and precede it + by a backslash (or two backslashes, if writing the value as a + literal using escape string syntax). + Backslash itself (octet value 92) can alternatively be represented by + double backslashes. + Table 8-7 + shows the characters that must be escaped, and gives the alternative + escape sequences where applicable. +

Table 8-7. bytea Literal Escaped Octets

Decimal Octet ValueDescriptionEscaped Input RepresentationExampleOutput Representation
0zero octetE'\\000'SELECT E'\\000'::bytea;\000
39single quote'''' or E'\\047'SELECT E'\''::bytea;'
92backslashE'\\\\' or E'\\134'SELECT E'\\\\'::bytea;\\
0 to 31 and 127 to 255"non-printable" octetsE'\\xxx' (octal value)SELECT E'\\001'::bytea;\001

The requirement to escape non-printable octets + varies depending on locale settings. In some instances you can get away + with leaving them unescaped. Note that the result in each of the examples + in Table 8-7 was exactly one octet in + length, even though the output representation is sometimes + more than one character. +

The reason multiple backslashes are required, as shown + in Table 8-7, is that an input + string written as a string literal must pass through two parse + phases in the PostgreSQL server. + The first backslash of each pair is interpreted as an escape + character by the string-literal parser (assuming escape string + syntax is used) and is therefore consumed, leaving the second backslash of the + pair. (Dollar-quoted strings can be used to avoid this level + of escaping.) The remaining backslash is then recognized by the + bytea input function as starting either a three + digit octal value or escaping another backslash. For example, + a string literal passed to the server as E'\\001' + becomes \001 after passing through the + escape string parser. The \001 is then sent + to the bytea input function, where it is converted + to a single octet with a decimal value of 1. Note that the + single-quote character is not treated specially by bytea, + so it follows the normal rules for string literals. (See also + Section 4.1.2.1.) +

Bytea octets are sometimes escaped when output. In general, each + "non-printable" octet is converted into + its equivalent three-digit octal value and preceded by one backslash. + Most "printable" octets are represented by their standard + representation in the client character set. The octet with decimal + value 92 (backslash) is doubled in the output. + Details are in Table 8-8. +

Table 8-8. bytea Output Escaped Octets

Decimal Octet ValueDescriptionEscaped Output RepresentationExampleOutput Result
92backslash\\SELECT E'\\134'::bytea;\\
0 to 31 and 127 to 255"non-printable" octets\xxx (octal value)SELECT E'\\001'::bytea;\001
32 to 126"printable" octetsclient character set representationSELECT E'\\176'::bytea;~

Depending on the front end to PostgreSQL you use, + you might have additional work to do in terms of escaping and + unescaping bytea strings. For example, you might also + have to escape line feeds and carriage returns if your interface + automatically translates these. +


PrevHomeNext
Character TypesUpDate/Time Types
\ No newline at end of file diff --git a/doc/src/sgml/html/datatype-bit.html b/doc/src/sgml/html/datatype-bit.html new file mode 100644 index 000000000..7b57f69d2 --- /dev/null +++ b/doc/src/sgml/html/datatype-bit.html @@ -0,0 +1,317 @@ + +Bit String Types

8.10. Bit String Types

Bit strings are strings of 1's and 0's. They can be used to store + or visualize bit masks. There are two SQL bit types: + bit(n) and bit + varying(n), where + n is a positive integer. +

bit type data must match the length + n exactly; it is an error to attempt to + store shorter or longer bit strings. bit varying data is + of variable length up to the maximum length + n; longer strings will be rejected. + Writing bit without a length is equivalent to + bit(1), while bit varying without a length + specification means unlimited length. +

Note: If one explicitly casts a bit-string value to + bit(n), it will be truncated or + zero-padded on the right to be exactly n bits, + without raising an error. Similarly, + if one explicitly casts a bit-string value to + bit varying(n), it will be truncated + on the right if it is more than n bits. +

Refer to Section 4.1.2.5 for information about the syntax + of bit string constants. Bit-logical operators and string + manipulation functions are available; see Section 9.6. +

Example 8-3. Using the Bit String Types

CREATE TABLE test (a BIT(3), b BIT VARYING(5));
+INSERT INTO test VALUES (B'101', B'00');
+INSERT INTO test VALUES (B'10', B'101');
+ERROR:  bit string length 2 does not match type bit(3)
+INSERT INTO test VALUES (B'10'::bit(3), B'101');
+SELECT * FROM test;
+  a  |  b
+-----+-----
+ 101 | 00
+ 100 | 101

A bit string value requires 1 byte for each group of 8 bits, plus + 5 or 8 bytes overhead depending on the length of the string + (but long values may be compressed or moved out-of-line, as explained + in Section 8.3 for character strings). +


PrevHomeNext
Network Address TypesUpText Search Types
\ No newline at end of file diff --git a/doc/src/sgml/html/datatype-boolean.html b/doc/src/sgml/html/datatype-boolean.html new file mode 100644 index 000000000..bda258f02 --- /dev/null +++ b/doc/src/sgml/html/datatype-boolean.html @@ -0,0 +1,423 @@ + +Boolean Type

8.6. Boolean Type

PostgreSQL provides the + standard SQL type boolean; + see Table 8-19. + The boolean type can have several states: + "true", "false", and a third state, + "unknown", which is represented by the + SQL null value. +

Table 8-19. Boolean Data Type

NameStorage SizeDescription
boolean1 bytestate of true or false

Valid literal values for the "true" state are: +

TRUE
't'
'true'
'y'
'yes'
'on'
'1'

+ For the "false" state, the following values can be + used: +

FALSE
'f'
'false'
'n'
'no'
'off'
'0'

+ Leading or trailing whitespace is ignored, and case does not matter. + The key words + TRUE and FALSE are the preferred + (SQL-compliant) usage. +

Example 8-2 shows that + boolean values are output using the letters + t and f. +

Example 8-2. Using the boolean Type

CREATE TABLE test1 (a boolean, b text);
+INSERT INTO test1 VALUES (TRUE, 'sic est');
+INSERT INTO test1 VALUES (FALSE, 'non est');
+SELECT * FROM test1;
+ a |    b
+---+---------
+ t | sic est
+ f | non est
+
+SELECT * FROM test1 WHERE a;
+ a |    b
+---+---------
+ t | sic est

PrevHomeNext
Date/Time TypesUpEnumerated Types
\ No newline at end of file diff --git a/doc/src/sgml/html/datatype-character.html b/doc/src/sgml/html/datatype-character.html new file mode 100644 index 000000000..241f9797b --- /dev/null +++ b/doc/src/sgml/html/datatype-character.html @@ -0,0 +1,704 @@ + +Character Types

8.3. Character Types

Table 8-4. Character Types

NameDescription
character varying(n), varchar(n)variable-length with limit
character(n), char(n)fixed-length, blank padded
textvariable unlimited length

Table 8-4 shows the + general-purpose character types available in + PostgreSQL. +

SQL defines two primary character types: + character varying(n) and + character(n), where n + is a positive integer. Both of these types can store strings up to + n characters (not bytes) in length. An attempt to store a + longer string into a column of these types will result in an + error, unless the excess characters are all spaces, in which case + the string will be truncated to the maximum length. (This somewhat + bizarre exception is required by the SQL + standard.) If the string to be stored is shorter than the declared + length, values of type character will be space-padded; + values of type character varying will simply store the + shorter + string. +

If one explicitly casts a value to character + varying(n) or + character(n), then an over-length + value will be truncated to n characters without + raising an error. (This too is required by the + SQL standard.) +

The notations varchar(n) and + char(n) are aliases for character + varying(n) and + character(n), respectively. + character without length specifier is equivalent to + character(1). If character varying is used + without length specifier, the type accepts strings of any size. The + latter is a PostgreSQL extension. +

In addition, PostgreSQL provides the + text type, which stores strings of any length. + Although the type text is not in the + SQL standard, several other SQL database + management systems have it as well. +

Values of type character are physically padded + with spaces to the specified width n, and are + stored and displayed that way. However, the padding spaces are + treated as semantically insignificant. Trailing spaces are + disregarded when comparing two values of type character, + and they will be removed when converting a character value + to one of the other string types. Note that trailing spaces + are semantically significant in + character varying and text values, and + when using pattern matching, e.g. LIKE, + regular expressions. +

The storage requirement for a short string (up to 126 bytes) is 1 byte + plus the actual string, which includes the space padding in the case of + character. Longer strings have 4 bytes of overhead instead + of 1. Long strings are compressed by the system automatically, so + the physical requirement on disk might be less. Very long values are also + stored in background tables so that they do not interfere with rapid + access to shorter column values. In any case, the longest + possible character string that can be stored is about 1 GB. (The + maximum value that will be allowed for n in the data + type declaration is less than that. It wouldn't be useful to + change this because with multibyte character encodings the number of + characters and bytes can be quite different. If you desire to + store long strings with no specific upper limit, use + text or character varying without a length + specifier, rather than making up an arbitrary length limit.) +

Tip: There is no performance difference among these three types, + apart from increased storage space when using the blank-padded + type, and a few extra CPU cycles to check the length when storing into + a length-constrained column. While + character(n) has performance + advantages in some other database systems, there is no such advantage in + PostgreSQL; in fact + character(n) is usually the slowest of + the three because of its additional storage costs. In most situations + text or character varying should be used + instead. +

Refer to Section 4.1.2.1 for information about + the syntax of string literals, and to Chapter 9 + for information about available operators and functions. The + database character set determines the character set used to store + textual values; for more information on character set support, + refer to Section 22.3. +

Example 8-1. Using the Character Types

CREATE TABLE test1 (a character(4));
+INSERT INTO test1 VALUES ('ok');
+SELECT a, char_length(a) FROM test1; -- (1)
+  a   | char_length
+------+-------------
+ ok   |           2
+
+CREATE TABLE test2 (b varchar(5));
+INSERT INTO test2 VALUES ('ok');
+INSERT INTO test2 VALUES ('good      ');
+INSERT INTO test2 VALUES ('too long');
+ERROR:  value too long for type character varying(5)
+INSERT INTO test2 VALUES ('too long'::varchar(5)); -- explicit truncation
+SELECT b, char_length(b) FROM test2;
+   b   | char_length
+-------+-------------
+ ok    |           2
+ good  |           5
+ too l |           5
(1)
The char_length function is discussed in + Section 9.4. +

There are two other fixed-length character types in + PostgreSQL, shown in Table 8-5. The name + type exists only for the storage of identifiers + in the internal system catalogs and is not intended for use by the general user. Its + length is currently defined as 64 bytes (63 usable characters plus + terminator) but should be referenced using the constant + NAMEDATALEN in C source code. + The length is set at compile time (and + is therefore adjustable for special uses); the default maximum + length might change in a future release. The type "char" + (note the quotes) is different from char(1) in that it + only uses one byte of storage. It is internally used in the system + catalogs as a simplistic enumeration type. +

Table 8-5. Special Character Types

NameStorage SizeDescription
"char"1 bytesingle-byte internal type
name64 bytesinternal type for object names

PrevHomeNext
Monetary TypesUpBinary Data Types
\ No newline at end of file diff --git a/doc/src/sgml/html/datatype-datetime.html b/doc/src/sgml/html/datatype-datetime.html new file mode 100644 index 000000000..db902203e --- /dev/null +++ b/doc/src/sgml/html/datatype-datetime.html @@ -0,0 +1,3023 @@ + +Date/Time Types

8.5. Date/Time Types

PostgreSQL supports the full set of + SQL date and time types, shown in Table 8-9. The operations available + on these data types are described in + Section 9.9. + Dates are counted according to the Gregorian calendar, even in + years before that calendar was introduced (see Section B.4 for more information). +

Table 8-9. Date/Time Types

NameStorage SizeDescriptionLow ValueHigh ValueResolution
timestamp [ (p) ] [ without time zone ]8 bytesboth date and time (no time zone)4713 BC294276 AD1 microsecond / 14 digits
timestamp [ (p) ] with time zone8 bytesboth date and time, with time zone4713 BC294276 AD1 microsecond / 14 digits
date4 bytesdate (no time of day)4713 BC5874897 AD1 day
time [ (p) ] [ without time zone ]8 bytestime of day (no date)00:00:0024:00:001 microsecond / 14 digits
time [ (p) ] with time zone12 bytestimes of day only, with time zone00:00:00+145924:00:00-14591 microsecond / 14 digits
interval [ fields ] [ (p) ]12 bytestime interval-178000000 years178000000 years1 microsecond / 14 digits

Note: The SQL standard requires that writing just timestamp + be equivalent to timestamp without time + zone, and PostgreSQL honors that + behavior. (Releases prior to 7.3 treated it as timestamp + with time zone.) timestamptz is accepted as an + abbreviation for timestamp with time zone; this is a + PostgreSQL extension. +

time, timestamp, and + interval accept an optional precision value + p which specifies the number of + fractional digits retained in the seconds field. By default, there + is no explicit bound on precision. The allowed range of + p is from 0 to 6 for the + timestamp and interval types. +

Note: When timestamp values are stored as eight-byte integers + (currently the default), microsecond precision is available over + the full range of values. When timestamp values are + stored as double precision floating-point numbers instead (a + deprecated compile-time option), the effective limit of precision + might be less than 6. timestamp values are stored as + seconds before or after midnight 2000-01-01. When + timestamp values are implemented using floating-point + numbers, microsecond precision is achieved for dates within a few + years of 2000-01-01, but the precision degrades for dates further + away. Note that using floating-point datetimes allows a larger + range of timestamp values to be represented than + shown above: from 4713 BC up to 5874897 AD. +

The same compile-time option also determines whether + time and interval values are stored as + floating-point numbers or eight-byte integers. In the + floating-point case, large interval values degrade in + precision as the size of the interval increases. +

For the time types, the allowed range of + p is from 0 to 6 when eight-byte integer + storage is used, or from 0 to 10 when floating-point storage is used. +

The interval type has an additional option, which is + to restrict the set of stored fields by writing one of these phrases: +

YEAR
+MONTH
+DAY
+HOUR
+MINUTE
+SECOND
+YEAR TO MONTH
+DAY TO HOUR
+DAY TO MINUTE
+DAY TO SECOND
+HOUR TO MINUTE
+HOUR TO SECOND
+MINUTE TO SECOND

+ Note that if both fields and + p are specified, the + fields must include SECOND, + since the precision applies only to the seconds. +

The type time with time zone is defined by the SQL + standard, but the definition exhibits properties which lead to + questionable usefulness. In most cases, a combination of + date, time, timestamp without time + zone, and timestamp with time zone should + provide a complete range of date/time functionality required by + any application. +

The types abstime + and reltime are lower precision types which are used internally. + You are discouraged from using these types in + applications; these internal types + might disappear in a future release. +

8.5.1. Date/Time Input

Date and time input is accepted in almost any reasonable format, including + ISO 8601, SQL-compatible, + traditional POSTGRES, and others. + For some formats, ordering of day, month, and year in date input is + ambiguous and there is support for specifying the expected + ordering of these fields. Set the DateStyle parameter + to MDY to select month-day-year interpretation, + DMY to select day-month-year interpretation, or + YMD to select year-month-day interpretation. +

PostgreSQL is more flexible in + handling date/time input than the + SQL standard requires. + See Appendix B + for the exact parsing rules of date/time input and for the + recognized text fields including months, days of the week, and + time zones. +

Remember that any date or time literal input needs to be enclosed + in single quotes, like text strings. Refer to + Section 4.1.2.7 for more + information. + SQL requires the following syntax +

type [ (p) ] 'value'

+ where p is an optional precision + specification giving the number of + fractional digits in the seconds field. Precision can be + specified for time, timestamp, and + interval types. The allowed values are mentioned + above. If no precision is specified in a constant specification, + it defaults to the precision of the literal value. +

8.5.1.1. Dates

Table 8-10 shows some possible + inputs for the date type. +

Table 8-10. Date Input

ExampleDescription
1999-01-08ISO 8601; January 8 in any mode + (recommended format)
January 8, 1999unambiguous in any datestyle input mode
1/8/1999January 8 in MDY mode; + August 1 in DMY mode
1/18/1999January 18 in MDY mode; + rejected in other modes
01/02/03January 2, 2003 in MDY mode; + February 1, 2003 in DMY mode; + February 3, 2001 in YMD mode +
1999-Jan-08January 8 in any mode
Jan-08-1999January 8 in any mode
08-Jan-1999January 8 in any mode
99-Jan-08January 8 in YMD mode, else error
08-Jan-99January 8, except error in YMD mode
Jan-08-99January 8, except error in YMD mode
19990108ISO 8601; January 8, 1999 in any mode
990108ISO 8601; January 8, 1999 in any mode
1999.008year and day of year
J2451187Julian date
January 8, 99 BCyear 99 BC

8.5.1.2. Times

The time-of-day types are time [ + (p) ] without time zone and + time [ (p) ] with time + zone. time alone is equivalent to + time without time zone. +

Valid input for these types consists of a time of day followed + by an optional time zone. (See Table 8-11 + and Table 8-12.) If a time zone is + specified in the input for time without time zone, + it is silently ignored. You can also specify a date but it will + be ignored, except when you use a time zone name that involves a + daylight-savings rule, such as + America/New_York. In this case specifying the date + is required in order to determine whether standard or daylight-savings + time applies. The appropriate time zone offset is recorded in the + time with time zone value. +

Table 8-11. Time Input

ExampleDescription
04:05:06.789ISO 8601
04:05:06ISO 8601
04:05ISO 8601
040506ISO 8601
04:05 AMsame as 04:05; AM does not affect value
04:05 PMsame as 16:05; input hour must be <= 12
04:05:06.789-8ISO 8601
04:05:06-08:00ISO 8601
04:05-08:00ISO 8601
040506-08ISO 8601
04:05:06 PSTtime zone specified by abbreviation
2003-04-12 04:05:06 America/New_Yorktime zone specified by full name

Table 8-12. Time Zone Input

ExampleDescription
PSTAbbreviation (for Pacific Standard Time)
America/New_YorkFull time zone name
PST8PDTPOSIX-style time zone specification
-8:00ISO-8601 offset for PST
-800ISO-8601 offset for PST
-8ISO-8601 offset for PST
zuluMilitary abbreviation for UTC
zShort form of zulu

Refer to Section 8.5.3 for more information on how + to specify time zones. +

8.5.1.3. Time Stamps

Valid input for the time stamp types consists of the concatenation + of a date and a time, followed by an optional time zone, + followed by an optional AD or BC. + (Alternatively, AD/BC can appear + before the time zone, but this is not the preferred ordering.) + Thus: + +

1999-01-08 04:05:06

+ and: +

1999-01-08 04:05:06 -8:00

+ + are valid values, which follow the ISO 8601 + standard. In addition, the common format: +

January 8 04:05:06 1999 PST

+ is supported. +

The SQL standard differentiates + timestamp without time zone + and timestamp with time zone literals by the presence of a + "+" or "-" symbol and time zone offset after + the time. Hence, according to the standard, + +

TIMESTAMP '2004-10-19 10:23:54'

+ + is a timestamp without time zone, while + +

TIMESTAMP '2004-10-19 10:23:54+02'

+ + is a timestamp with time zone. + PostgreSQL never examines the content of a + literal string before determining its type, and therefore will treat + both of the above as timestamp without time zone. To + ensure that a literal is treated as timestamp with time + zone, give it the correct explicit type: + +

TIMESTAMP WITH TIME ZONE '2004-10-19 10:23:54+02'

+ + In a literal that has been determined to be timestamp without time + zone, PostgreSQL will silently ignore + any time zone indication. + That is, the resulting value is derived from the date/time + fields in the input value, and is not adjusted for time zone. +

For timestamp with time zone, the internally stored + value is always in UTC (Universal + Coordinated Time, traditionally known as Greenwich Mean Time, + GMT). An input value that has an explicit + time zone specified is converted to UTC using the appropriate offset + for that time zone. If no time zone is stated in the input string, + then it is assumed to be in the time zone indicated by the system's + TimeZone parameter, and is converted to UTC using the + offset for the timezone zone. +

When a timestamp with time + zone value is output, it is always converted from UTC to the + current timezone zone, and displayed as local time in that + zone. To see the time in another time zone, either change + timezone or use the AT TIME ZONE construct + (see Section 9.9.3). +

Conversions between timestamp without time zone and + timestamp with time zone normally assume that the + timestamp without time zone value should be taken or given + as timezone local time. A different time zone can + be specified for the conversion using AT TIME ZONE. +

8.5.1.4. Special Values

PostgreSQL supports several + special date/time input values for convenience, as shown in Table 8-13. The values + infinity and -infinity + are specially represented inside the system and will be displayed + unchanged; but the others are simply notational shorthands + that will be converted to ordinary date/time values when read. + (In particular, now and related strings are converted + to a specific time value as soon as they are read.) + All of these values need to be enclosed in single quotes when used + as constants in SQL commands. +

Table 8-13. Special Date/Time Inputs

Input StringValid TypesDescription
epochdate, timestamp1970-01-01 00:00:00+00 (Unix system time zero)
infinitydate, timestamplater than all other time stamps
-infinitydate, timestampearlier than all other time stamps
nowdate, time, timestampcurrent transaction's start time
todaydate, timestampmidnight today
tomorrowdate, timestampmidnight tomorrow
yesterdaydate, timestampmidnight yesterday
allballstime00:00:00.00 UTC

The following SQL-compatible functions can also + be used to obtain the current time value for the corresponding data + type: + CURRENT_DATE, CURRENT_TIME, + CURRENT_TIMESTAMP, LOCALTIME, + LOCALTIMESTAMP. The latter four accept an + optional subsecond precision specification. (See Section 9.9.4.) Note that these are + SQL functions and are not recognized in data input strings. +

8.5.2. Date/Time Output

The output format of the date/time types can be set to one of the four + styles ISO 8601, + SQL (Ingres), traditional POSTGRES + (Unix date format), or + German. The default + is the ISO format. (The + SQL standard requires the use of the ISO 8601 + format. The name of the "SQL" output format is a + historical accident.) Table 8-14 shows examples of each + output style. The output of the date and + time types is of course only the date or time part + in accordance with the given examples. +

Table 8-14. Date/Time Output Styles

Style SpecificationDescriptionExample
ISOISO 8601, SQL standard1997-12-17 07:37:16-08
SQLtraditional style12/17/1997 07:37:16.00 PST
Postgresoriginal styleWed Dec 17 07:37:16 1997 PST
Germanregional style17.12.1997 07:37:16.00 PST

Note: ISO 8601 specifies the use of uppercase letter T to separate + the date and time. PostgreSQL accepts that format on + input, but on output it uses a space rather than T, as shown + above. This is for readability and for consistency with RFC 3339 as + well as some other database systems. +

In the SQL and POSTGRES styles, day appears before + month if DMY field ordering has been specified, otherwise month appears + before day. + (See Section 8.5.1 + for how this setting also affects interpretation of input values.) + Table 8-15 shows examples. +

Table 8-15. Date Order Conventions

datestyle SettingInput OrderingExample Output
SQL, DMYday/month/year17/12/1997 15:37:16.00 CET
SQL, MDYmonth/day/year12/17/1997 07:37:16.00 PST
Postgres, DMYday/month/yearWed 17 Dec 07:37:16 1997 PST

The date/time style can be selected by the user using the + SET datestyle command, the DateStyle parameter in the + postgresql.conf configuration file, or the + PGDATESTYLE environment variable on the server or + client. +

The formatting function to_char + (see Section 9.8) is also available as + a more flexible way to format date/time output. +

8.5.3. Time Zones

Time zones, and time-zone conventions, are influenced by + political decisions, not just earth geometry. Time zones around the + world became somewhat standardized during the 1900's, + but continue to be prone to arbitrary changes, particularly with + respect to daylight-savings rules. + PostgreSQL uses the widely-used + zoneinfo (Olson) time zone database for information about + historical time zone rules. For times in the future, the assumption + is that the latest known rules for a given time zone will + continue to be observed indefinitely far into the future. +

PostgreSQL endeavors to be compatible with + the SQL standard definitions for typical usage. + However, the SQL standard has an odd mix of date and + time types and capabilities. Two obvious problems are: + +

  • Although the date type + cannot have an associated time zone, the + time type can. + Time zones in the real world have little meaning unless + associated with a date as well as a time, + since the offset can vary through the year with daylight-saving + time boundaries. +

  • The default time zone is specified as a constant numeric offset + from UTC. It is therefore impossible to adapt to + daylight-saving time when doing date/time arithmetic across + DST boundaries. +

+

To address these difficulties, we recommend using date/time types + that contain both date and time when using time zones. We + do not recommend using the type time with + time zone (though it is supported by + PostgreSQL for legacy applications and + for compliance with the SQL standard). + PostgreSQL assumes + your local time zone for any type containing only date or time. +

All timezone-aware dates and times are stored internally in + UTC. They are converted to local time + in the zone specified by the TimeZone configuration + parameter before being displayed to the client. +

PostgreSQL allows you to specify time zones in + three different forms: +

  • A full time zone name, for example America/New_York. + The recognized time zone names are listed in the + pg_timezone_names view (see Section 45.69). + PostgreSQL uses the widely-used + zoneinfo time zone data for this purpose, so the same + names are also recognized by much other software. +

  • A time zone abbreviation, for example PST. Such a + specification merely defines a particular offset from UTC, in + contrast to full time zone names which can imply a set of daylight + savings transition-date rules as well. The recognized abbreviations + are listed in the pg_timezone_abbrevs view (see Section 45.68). You cannot set the + configuration parameters TimeZone or + log_timezone to a time + zone abbreviation, but you can use abbreviations in + date/time input values and with the AT TIME ZONE + operator. +

  • In addition to the timezone names and abbreviations, + PostgreSQL will accept POSIX-style time zone + specifications of the form STDoffset or + STDoffsetDST, where + STD is a zone abbreviation, offset is a + numeric offset in hours west from UTC, and DST is an + optional daylight-savings zone abbreviation, assumed to stand for one + hour ahead of the given offset. For example, if EST5EDT + were not already a recognized zone name, it would be accepted and would + be functionally equivalent to United States East Coast time. When a + daylight-savings zone name is present, it is assumed to be used + according to the same daylight-savings transition rules used in the + zoneinfo time zone database's posixrules entry. + In a standard PostgreSQL installation, + posixrules is the same as US/Eastern, so + that POSIX-style time zone specifications follow USA daylight-savings + rules. If needed, you can adjust this behavior by replacing the + posixrules file. +

+ + In short, this is the difference between abbreviations + and full names: abbreviations always represent a fixed offset from + UTC, whereas most of the full names imply a local daylight-savings time + rule, and so have two possible UTC offsets. +

One should be wary that the POSIX-style time zone feature can + lead to silently accepting bogus input, since there is no check on the + reasonableness of the zone abbreviations. For example, SET + TIMEZONE TO FOOBAR0 will work, leaving the system effectively using + a rather peculiar abbreviation for UTC. + Another issue to keep in mind is that in POSIX time zone names, + positive offsets are used for locations west of Greenwich. + Everywhere else, PostgreSQL follows the + ISO-8601 convention that positive timezone offsets are east + of Greenwich. +

In all cases, timezone names are recognized case-insensitively. + (This is a change from PostgreSQL versions + prior to 8.2, which were case-sensitive in some contexts but not others.) +

Neither full names nor abbreviations are hard-wired into the server; + they are obtained from configuration files stored under + .../share/timezone/ and .../share/timezonesets/ + of the installation directory + (see Section B.3). +

The TimeZone configuration parameter can + be set in the file postgresql.conf, or in any of the + other standard ways described in Chapter 18. + There are also some special ways to set it: + +

  • The SQL command SET TIME ZONE + sets the time zone for the session. This is an alternative spelling + of SET TIMEZONE TO with a more SQL-spec-compatible syntax. +

  • The PGTZ environment variable is used by + libpq clients + to send a SET TIME ZONE + command to the server upon connection. +

+

8.5.4. Interval Input

interval values can be written using the following + verbose syntax: + +

[@] quantity unit [quantity unit...] [direction]

+ + where quantity is a number (possibly signed); + unit is microsecond, + millisecond, second, + minute, hour, day, + week, month, year, + decade, century, millennium, + or abbreviations or plurals of these units; + direction can be ago or + empty. The at sign (@) is optional noise. The amounts + of the different units are implicitly added with appropriate + sign accounting. ago negates all the fields. + This syntax is also used for interval output, if + IntervalStyle is set to + postgres_verbose. +

Quantities of days, hours, minutes, and seconds can be specified without + explicit unit markings. For example, '1 12:59:10' is read + the same as '1 day 12 hours 59 min 10 sec'. Also, + a combination of years and months can be specified with a dash; + for example '200-10' is read the same as '200 years + 10 months'. (These shorter forms are in fact the only ones allowed + by the SQL standard, and are used for output when + IntervalStyle is set to sql_standard.) +

Interval values can also be written as ISO 8601 time intervals, using + either the "format with designators" of the standard's section + 4.4.3.2 or the "alternative format" of section 4.4.3.3. The + format with designators looks like this: +

P quantity unit [ quantity unit ...] [ T [ quantity unit ...]]

+ The string must start with a P, and may include a + T that introduces the time-of-day units. The + available unit abbreviations are given in Table 8-16. Units may be + omitted, and may be specified in any order, but units smaller than + a day must appear after T. In particular, the meaning of + M depends on whether it is before or after + T. +

Table 8-16. ISO 8601 Interval Unit Abbreviations

AbbreviationMeaning
YYears
MMonths (in the date part)
WWeeks
DDays
HHours
MMinutes (in the time part)
SSeconds

In the alternative format: +

P [ years-months-days ] [ T hours:minutes:seconds ]

+ the string must begin with P, and a + T separates the date and time parts of the interval. + The values are given as numbers similar to ISO 8601 dates. +

When writing an interval constant with a fields + specification, or when assigning a string to an interval column that was + defined with a fields specification, the interpretation of + unmarked quantities depends on the fields. For + example INTERVAL '1' YEAR is read as 1 year, whereas + INTERVAL '1' means 1 second. Also, field values + "to the right" of the least significant field allowed by the + fields specification are silently discarded. For + example, writing INTERVAL '1 day 2:03:04' HOUR TO MINUTE + results in dropping the seconds field, but not the day field. +

According to the SQL standard all fields of an interval + value must have the same sign, so a leading negative sign applies to all + fields; for example the negative sign in the interval literal + '-1 2:03:04' applies to both the days and hour/minute/second + parts. PostgreSQL allows the fields to have different + signs, and traditionally treats each field in the textual representation + as independently signed, so that the hour/minute/second part is + considered positive in this example. If IntervalStyle is + set to sql_standard then a leading sign is considered + to apply to all fields (but only if no additional signs appear). + Otherwise the traditional PostgreSQL interpretation is + used. To avoid ambiguity, it's recommended to attach an explicit sign + to each field if any field is negative. +

Internally interval values are stored as months, days, + and seconds. This is done because the number of days in a month + varies, and a day can have 23 or 25 hours if a daylight savings + time adjustment is involved. The months and days fields are integers + while the seconds field can store fractions. Because intervals are + usually created from constant strings or timestamp subtraction, + this storage method works well in most cases. Functions + justify_days and justify_hours are + available for adjusting days and hours that overflow their normal + ranges. +

In the verbose input format, and in some fields of the more compact + input formats, field values can have fractional parts; for example + '1.5 week' or '01:02:03.45'. Such input is + converted to the appropriate number of months, days, and seconds + for storage. When this would result in a fractional number of + months or days, the fraction is added to the lower-order fields + using the conversion factors 1 month = 30 days and 1 day = 24 hours. + For example, '1.5 month' becomes 1 month and 15 days. + Only seconds will ever be shown as fractional on output. +

Table 8-17 shows some examples + of valid interval input. +

Table 8-17. Interval Input

ExampleDescription
1-2SQL standard format: 1 year 2 months
3 4:05:06SQL standard format: 3 days 4 hours 5 minutes 6 seconds
1 year 2 months 3 days 4 hours 5 minutes 6 secondsTraditional Postgres format: 1 year 2 months 3 days 4 hours 5 minutes 6 seconds
P1Y2M3DT4H5M6SISO 8601 "format with designators": same meaning as above
P0001-02-03T04:05:06ISO 8601 "alternative format": same meaning as above

8.5.5. Interval Output

The output format of the interval type can be set to one of the + four styles sql_standard, postgres, + postgres_verbose, or iso_8601, + using the command SET intervalstyle. + The default is the postgres format. + Table 8-18 shows examples of each + output style. +

The sql_standard style produces output that conforms to + the SQL standard's specification for interval literal strings, if + the interval value meets the standard's restrictions (either year-month + only or day-time only, with no mixing of positive + and negative components). Otherwise the output looks like a standard + year-month literal string followed by a day-time literal string, + with explicit signs added to disambiguate mixed-sign intervals. +

The output of the postgres style matches the output of + PostgreSQL releases prior to 8.4 when the + DateStyle parameter was set to ISO. +

The output of the postgres_verbose style matches the output of + PostgreSQL releases prior to 8.4 when the + DateStyle parameter was set to non-ISO output. +

The output of the iso_8601 style matches the "format + with designators" described in section 4.4.3.2 of the + ISO 8601 standard. +

Table 8-18. Interval Output Style Examples

Style SpecificationYear-Month IntervalDay-Time IntervalMixed Interval
sql_standard1-23 4:05:06-1-2 +3 -4:05:06
postgres1 year 2 mons3 days 04:05:06-1 year -2 mons +3 days -04:05:06
postgres_verbose@ 1 year 2 mons@ 3 days 4 hours 5 mins 6 secs@ 1 year 2 mons -3 days 4 hours 5 mins 6 secs ago
iso_8601P1Y2MP3DT4H5M6SP-1Y-2M3DT-4H-5M-6S

PrevHomeNext
Binary Data TypesUpBoolean Type
\ No newline at end of file diff --git a/doc/src/sgml/html/datatype-enum.html b/doc/src/sgml/html/datatype-enum.html new file mode 100644 index 000000000..0ff906183 --- /dev/null +++ b/doc/src/sgml/html/datatype-enum.html @@ -0,0 +1,342 @@ + +Enumerated Types

8.7. Enumerated Types

Enumerated (enum) types are data types that + comprise a static, ordered set of values. + They are equivalent to the enum + types supported in a number of programming languages. An example of an enum + type might be the days of the week, or a set of status values for + a piece of data. +

8.7.1. Declaration of Enumerated Types

Enum types are created using the CREATE TYPE command, + for example: + +

CREATE TYPE mood AS ENUM ('sad', 'ok', 'happy');

+ + Once created, the enum type can be used in table and function + definitions much like any other type: +

CREATE TYPE mood AS ENUM ('sad', 'ok', 'happy');
+CREATE TABLE person (
+    name text,
+    current_mood mood
+);
+INSERT INTO person VALUES ('Moe', 'happy');
+SELECT * FROM person WHERE current_mood = 'happy';
+ name | current_mood 
+------+--------------
+ Moe  | happy
+(1 row)

+

8.7.2. Ordering

The ordering of the values in an enum type is the + order in which the values were listed when the type was created. + All standard comparison operators and related + aggregate functions are supported for enums. For example: + +

INSERT INTO person VALUES ('Larry', 'sad');
+INSERT INTO person VALUES ('Curly', 'ok');
+SELECT * FROM person WHERE current_mood > 'sad';
+ name  | current_mood 
+-------+--------------
+ Moe   | happy
+ Curly | ok
+(2 rows)
+
+SELECT * FROM person WHERE current_mood > 'sad' ORDER BY current_mood;
+ name  | current_mood 
+-------+--------------
+ Curly | ok
+ Moe   | happy
+(2 rows)
+
+SELECT name
+FROM person
+WHERE current_mood = (SELECT MIN(current_mood) FROM person);
+ name  
+-------
+ Larry
+(1 row)

+

8.7.3. Type Safety

Each enumerated data type is separate and cannot + be compared with other enumerated types. See this example: + +

CREATE TYPE happiness AS ENUM ('happy', 'very happy', 'ecstatic');
+CREATE TABLE holidays (
+    num_weeks integer,
+    happiness happiness
+);
+INSERT INTO holidays(num_weeks,happiness) VALUES (4, 'happy');
+INSERT INTO holidays(num_weeks,happiness) VALUES (6, 'very happy');
+INSERT INTO holidays(num_weeks,happiness) VALUES (8, 'ecstatic');
+INSERT INTO holidays(num_weeks,happiness) VALUES (2, 'sad');
+ERROR:  invalid input value for enum happiness: "sad"
+SELECT person.name, holidays.num_weeks FROM person, holidays
+  WHERE person.current_mood = holidays.happiness;
+ERROR:  operator does not exist: mood = happiness

+

If you really need to do something like that, you can either + write a custom operator or add explicit casts to your query: + +

SELECT person.name, holidays.num_weeks FROM person, holidays
+  WHERE person.current_mood::text = holidays.happiness::text;
+ name | num_weeks 
+------+-----------
+ Moe  |         4
+(1 row)

+

8.7.4. Implementation Details

An enum value occupies four bytes on disk. The length of an enum + value's textual label is limited by the NAMEDATALEN + setting compiled into PostgreSQL; in standard + builds this means at most 63 bytes. +

Enum labels are case sensitive, so + 'happy' is not the same as 'HAPPY'. + White space in the labels is significant too. +

The translations from internal enum values to textual labels are + kept in the system catalog + pg_enum. + Querying this catalog directly can be useful. +


PrevHomeNext
Boolean TypeUpGeometric Types
\ No newline at end of file diff --git a/doc/src/sgml/html/datatype-geometric.html b/doc/src/sgml/html/datatype-geometric.html new file mode 100644 index 000000000..d737e320f --- /dev/null +++ b/doc/src/sgml/html/datatype-geometric.html @@ -0,0 +1,1022 @@ + +Geometric Types

8.8. Geometric Types

Geometric data types represent two-dimensional spatial + objects. Table 8-20 shows the geometric + types available in PostgreSQL. The + most fundamental type, the point, forms the basis for all of the + other types. +

Table 8-20. Geometric Types

NameStorage SizeRepresentationDescription
point16 bytesPoint on a plane(x,y)
line32 bytesInfinite line (not fully implemented)((x1,y1),(x2,y2))
lseg32 bytesFinite line segment((x1,y1),(x2,y2))
box32 bytesRectangular box((x1,y1),(x2,y2))
path16+16n bytesClosed path (similar to polygon)((x1,y1),...)
path16+16n bytesOpen path[(x1,y1),...]
polygon40+16n bytesPolygon (similar to closed path)((x1,y1),...)
circle24 bytesCircle<(x,y),r> (center point and radius)

A rich set of functions and operators is available to perform various geometric + operations such as scaling, translation, rotation, and determining + intersections. They are explained in Section 9.11. +

8.8.1. Points

Points are the fundamental two-dimensional building block for geometric + types. Values of type point are specified using either of + the following syntaxes: + +

( x , y )
+  x , y

+ + where x and y are the respective + coordinates, as floating-point numbers. +

Points are output using the first syntax. +

8.8.2. Line Segments

Line segments (lseg) are represented by pairs of points. + Values of type lseg are specified using any of the following + syntaxes: + +

[ ( x1 , y1 ) , ( x2 , y2 ) ]
+( ( x1 , y1 ) , ( x2 , y2 ) )
+  ( x1 , y1 ) , ( x2 , y2 )
+    x1 , y1   ,   x2 , y2

+ + where + (x1,y1) + and + (x2,y2) + are the end points of the line segment. +

Line segments are output using the first syntax. +

8.8.3. Boxes

Boxes are represented by pairs of points that are opposite + corners of the box. + Values of type box are specified using any of the following + syntaxes: + +

( ( x1 , y1 ) , ( x2 , y2 ) )
+  ( x1 , y1 ) , ( x2 , y2 )
+    x1 , y1   ,   x2 , y2

+ + where + (x1,y1) + and + (x2,y2) + are any two opposite corners of the box. +

Boxes are output using the second syntax. +

Any two opposite corners can be supplied on input, but the values + will be reordered as needed to store the + upper right and lower left corners, in that order. +

8.8.4. Paths

Paths are represented by lists of connected points. Paths can be + open, where + the first and last points in the list are considered not connected, or + closed, + where the first and last points are considered connected. +

Values of type path are specified using any of the following + syntaxes: + +

[ ( x1 , y1 ) , ... , ( xn , yn ) ]
+( ( x1 , y1 ) , ... , ( xn , yn ) )
+  ( x1 , y1 ) , ... , ( xn , yn )
+  ( x1 , y1   , ... ,   xn , yn )
+    x1 , y1   , ... ,   xn , yn

+ + where the points are the end points of the line segments + comprising the path. Square brackets ([]) indicate + an open path, while parentheses (()) indicate a + closed path. When the outermost parentheses are omitted, as + in the third through fifth syntaxes, a closed path is assumed. +

Paths are output using the first or second syntax, as appropriate. +

8.8.5. Polygons

Polygons are represented by lists of points (the vertexes of the + polygon). Polygons are very similar to closed paths, but are + stored differently and have their own set of support routines. +

Values of type polygon are specified using any of the + following syntaxes: + +

( ( x1 , y1 ) , ... , ( xn , yn ) )
+  ( x1 , y1 ) , ... , ( xn , yn )
+  ( x1 , y1   , ... ,   xn , yn )
+    x1 , y1   , ... ,   xn , yn

+ + where the points are the end points of the line segments + comprising the boundary of the polygon. +

Polygons are output using the first syntax. +

8.8.6. Circles

Circles are represented by a center point and radius. + Values of type circle are specified using any of the + following syntaxes: + +

< ( x , y ) , r >
+( ( x , y ) , r )
+  ( x , y ) , r
+    x , y   , r

+ + where + (x,y) + is the center point and r is the radius of the + circle. +

Circles are output using the first syntax. +


PrevHomeNext
Enumerated TypesUpNetwork Address Types
\ No newline at end of file diff --git a/doc/src/sgml/html/datatype-json.html b/doc/src/sgml/html/datatype-json.html new file mode 100644 index 000000000..2163ddbb4 --- /dev/null +++ b/doc/src/sgml/html/datatype-json.html @@ -0,0 +1,209 @@ + +JSON Type

8.14. JSON Type

The json data type can be used to store JSON (JavaScript + Object Notation) data, as specified in RFC 4627. Such + data can also be stored as text, but the + json data type has the advantage of checking that each + stored value is a valid JSON value. There are also related support + functions available; see Section 9.15. +

PostgreSQL allows only one server encoding + per database. It is therefore not possible for JSON to conform rigidly + to the specification unless the server encoding is UTF-8. Attempts to + directly include characters which cannot be represented in the server + encoding will fail; conversely, characters which can be represented in + the server encoding but not in UTF-8 will be allowed. + \uXXXX escapes are allowed regardless of the server + encoding, and are checked only for syntactic correctness. +


PrevHomeNext
XML TypeUpArrays
\ No newline at end of file diff --git a/doc/src/sgml/html/datatype-money.html b/doc/src/sgml/html/datatype-money.html new file mode 100644 index 000000000..97b374c56 --- /dev/null +++ b/doc/src/sgml/html/datatype-money.html @@ -0,0 +1,302 @@ + +Monetary Types

8.2. Monetary Types

The money type stores a currency amount with a fixed + fractional precision; see Table 8-3. The fractional precision is + determined by the database's lc_monetary setting. + The range shown in the table assumes there are two fractional digits. + Input is accepted in a variety of formats, including integer and + floating-point literals, as well as typical + currency formatting, such as '$1,000.00'. + Output is generally in the latter form but depends on the locale. +

Table 8-3. Monetary Types

NameStorage SizeDescriptionRange
money8 bytescurrency amount-92233720368547758.08 to +92233720368547758.07

Since the output of this data type is locale-sensitive, it might not + work to load money data into a database that has a different + setting of lc_monetary. To avoid problems, before + restoring a dump into a new database make sure lc_monetary has + the same or equivalent value as in the database that was dumped. +

Values of the numeric, int, and + bigint data types can be cast to money. + Conversion from the real and double precision + data types can be done by casting to numeric first, for + example: +

SELECT '12.34'::float8::numeric::money;

+ However, this is not recommended. Floating point numbers should not be + used to handle money due to the potential for rounding errors. +

A money value can be cast to numeric without + loss of precision. Conversion to other types could potentially lose + precision, and must also be done in two stages: +

SELECT '52093.89'::money::numeric::float8;

+

When a money value is divided by another money + value, the result is double precision (i.e., a pure number, + not money); the currency units cancel each other out in the division. +


PrevHomeNext
Numeric TypesUpCharacter Types
\ No newline at end of file diff --git a/doc/src/sgml/html/datatype-net-types.html b/doc/src/sgml/html/datatype-net-types.html new file mode 100644 index 000000000..3547d174e --- /dev/null +++ b/doc/src/sgml/html/datatype-net-types.html @@ -0,0 +1,710 @@ + +Network Address Types

8.9. Network Address Types

PostgreSQL offers data types to store IPv4, IPv6, and MAC + addresses, as shown in Table 8-21. It + is better to use these types instead of plain text types to store + network addresses, because + these types offer input error checking and specialized + operators and functions (see Section 9.12). +

Table 8-21. Network Address Types

NameStorage SizeDescription
cidr7 or 19 bytesIPv4 and IPv6 networks
inet7 or 19 bytesIPv4 and IPv6 hosts and networks
macaddr6 bytesMAC addresses

When sorting inet or cidr data types, + IPv4 addresses will always sort before IPv6 addresses, including + IPv4 addresses encapsulated or mapped to IPv6 addresses, such as + ::10.2.3.4 or ::ffff:10.4.3.2. +

8.9.1. inet

The inet type holds an IPv4 or IPv6 host address, and + optionally its subnet, all in one field. + The subnet is represented by the number of network address bits + present in the host address (the + "netmask"). If the netmask is 32 and the address is IPv4, + then the value does not indicate a subnet, only a single host. + In IPv6, the address length is 128 bits, so 128 bits specify a + unique host address. Note that if you + want to accept only networks, you should use the + cidr type rather than inet. +

The input format for this type is + address/y + where + address + is an IPv4 or IPv6 address and + y + is the number of bits in the netmask. If the + /y + portion is missing, the + netmask is 32 for IPv4 and 128 for IPv6, so the value represents + just a single host. On display, the + /y + portion is suppressed if the netmask specifies a single host. +

8.9.2. cidr

The cidr type holds an IPv4 or IPv6 network specification. + Input and output formats follow Classless Internet Domain Routing + conventions. + The format for specifying networks is address/y where address is the network represented as an + IPv4 or IPv6 address, and y is the number of bits in the netmask. If + y is omitted, it is calculated + using assumptions from the older classful network numbering system, except + it will be at least large enough to include all of the octets + written in the input. It is an error to specify a network address + that has bits set to the right of the specified netmask. +

Table 8-22 shows some examples. +

Table 8-22. cidr Type Input Examples

cidr Inputcidr Outputabbrev(cidr)
192.168.100.128/25192.168.100.128/25192.168.100.128/25
192.168/24192.168.0.0/24192.168.0/24
192.168/25192.168.0.0/25192.168.0.0/25
192.168.1192.168.1.0/24192.168.1/24
192.168192.168.0.0/24192.168.0/24
128.1128.1.0.0/16128.1/16
128128.0.0.0/16128.0/16
128.1.2128.1.2.0/24128.1.2/24
10.1.210.1.2.0/2410.1.2/24
10.110.1.0.0/1610.1/16
1010.0.0.0/810/8
10.1.2.3/3210.1.2.3/3210.1.2.3/32
2001:4f8:3:ba::/642001:4f8:3:ba::/642001:4f8:3:ba::/64
2001:4f8:3:ba:2e0:81ff:fe22:d1f1/1282001:4f8:3:ba:2e0:81ff:fe22:d1f1/1282001:4f8:3:ba:2e0:81ff:fe22:d1f1
::ffff:1.2.3.0/120::ffff:1.2.3.0/120::ffff:1.2.3/120
::ffff:1.2.3.0/128::ffff:1.2.3.0/128::ffff:1.2.3.0/128

8.9.3. inet vs. cidr

The essential difference between inet and cidr + data types is that inet accepts values with nonzero bits to + the right of the netmask, whereas cidr does not. +

Tip: If you do not like the output format for inet or + cidr values, try the functions host, + text, and abbrev. +

8.9.4. macaddr

The macaddr type stores MAC addresses, known for example + from Ethernet card hardware addresses (although MAC addresses are + used for other purposes as well). Input is accepted in the + following formats: + +

'08:00:2b:01:02:03'
'08-00-2b-01-02-03'
'08002b:010203'
'08002b-010203'
'0800.2b01.0203'
'08002b010203'

+ + These examples would all specify the same address. Upper and + lower case is accepted for the digits + a through f. Output is always in the + first of the forms shown. +

IEEE Std 802-2001 specifies the second shown form (with hyphens) + as the canonical form for MAC addresses, and specifies the first + form (with colons) as the bit-reversed notation, so that + 08-00-2b-01-02-03 = 01:00:4D:08:04:0C. This convention is widely + ignored nowadays, and it is only relevant for obsolete network + protocols (such as Token Ring). PostgreSQL makes no provisions + for bit reversal, and all accepted formats use the canonical LSB + order. +

The remaining four input formats are not part of any standard. +


PrevHomeNext
Geometric TypesUpBit String Types
\ No newline at end of file diff --git a/doc/src/sgml/html/datatype-numeric.html b/doc/src/sgml/html/datatype-numeric.html new file mode 100644 index 000000000..c999f389b --- /dev/null +++ b/doc/src/sgml/html/datatype-numeric.html @@ -0,0 +1,1207 @@ + +Numeric Types

8.1. Numeric Types

Numeric types consist of two-, four-, and eight-byte integers, + four- and eight-byte floating-point numbers, and selectable-precision + decimals. Table 8-2 lists the + available types. +

Table 8-2. Numeric Types

NameStorage SizeDescriptionRange
smallint2 bytessmall-range integer-32768 to +32767
integer4 bytestypical choice for integer-2147483648 to +2147483647
bigint8 byteslarge-range integer-9223372036854775808 to 9223372036854775807
decimalvariableuser-specified precision, exactup to 131072 digits before the decimal point; up to 16383 digits after the decimal point
numericvariableuser-specified precision, exactup to 131072 digits before the decimal point; up to 16383 digits after the decimal point
real4 bytesvariable-precision, inexact6 decimal digits precision
double precision8 bytesvariable-precision, inexact15 decimal digits precision
smallserial2 bytessmall autoincrementing integer1 to 32767
serial4 bytesautoincrementing integer1 to 2147483647
bigserial8 byteslarge autoincrementing integer1 to 9223372036854775807

The syntax of constants for the numeric types is described in + Section 4.1.2. The numeric types have a + full set of corresponding arithmetic operators and + functions. Refer to Chapter 9 for more + information. The following sections describe the types in detail. +

8.1.1. Integer Types

The types smallint, integer, and + bigint store whole numbers, that is, numbers without + fractional components, of various ranges. Attempts to store + values outside of the allowed range will result in an error. +

The type integer is the common choice, as it offers + the best balance between range, storage size, and performance. + The smallint type is generally only used if disk + space is at a premium. The bigint type should only + be used if the range of the integer type is insufficient, + because the latter is definitely faster. +

On very minimal operating systems the bigint type + might not function correctly, because it relies on compiler support + for eight-byte integers. On such machines, bigint + acts the same as integer, but still takes up eight + bytes of storage. (We are not aware of any modern + platform where this is the case.) +

SQL only specifies the integer types + integer (or int), + smallint, and bigint. The + type names int2, int4, and + int8 are extensions, which are also used by some + other SQL database systems. +

8.1.2. Arbitrary Precision Numbers

The type numeric can store numbers with a + very large number of digits and perform calculations exactly. It is + especially recommended for storing monetary amounts and other + quantities where exactness is required. However, arithmetic on + numeric values is very slow compared to the integer + types, or to the floating-point types described in the next section. +

We use the following terms below: The + scale of a numeric is the + count of decimal digits in the fractional part, to the right of + the decimal point. The precision of a + numeric is the total count of significant digits in + the whole number, that is, the number of digits to both sides of + the decimal point. So the number 23.5141 has a precision of 6 + and a scale of 4. Integers can be considered to have a scale of + zero. +

Both the maximum precision and the maximum scale of a + numeric column can be + configured. To declare a column of type numeric use + the syntax: +

NUMERIC(precision, scale)

+ The precision must be positive, the scale zero or positive. + Alternatively: +

NUMERIC(precision)

+ selects a scale of 0. Specifying: +

NUMERIC

+ without any precision or scale creates a column in which numeric + values of any precision and scale can be stored, up to the + implementation limit on precision. A column of this kind will + not coerce input values to any particular scale, whereas + numeric columns with a declared scale will coerce + input values to that scale. (The SQL standard + requires a default scale of 0, i.e., coercion to integer + precision. We find this a bit useless. If you're concerned + about portability, always specify the precision and scale + explicitly.) +

Note: The maximum allowed precision when explicitly specified in the + type declaration is 1000; NUMERIC without a specified + precision is subject to the limits described in Table 8-2. +

If the scale of a value to be stored is greater than the declared + scale of the column, the system will round the value to the specified + number of fractional digits. Then, if the number of digits to the + left of the decimal point exceeds the declared precision minus the + declared scale, an error is raised. +

Numeric values are physically stored without any extra leading or + trailing zeroes. Thus, the declared precision and scale of a column + are maximums, not fixed allocations. (In this sense the numeric + type is more akin to varchar(n) + than to char(n).) The actual storage + requirement is two bytes for each group of four decimal digits, + plus three to eight bytes overhead. +

In addition to ordinary numeric values, the numeric + type allows the special value NaN, meaning + "not-a-number". Any operation on NaN + yields another NaN. When writing this value + as a constant in an SQL command, you must put quotes around it, + for example UPDATE table SET x = 'NaN'. On input, + the string NaN is recognized in a case-insensitive manner. +

Note: In most implementations of the "not-a-number" concept, + NaN is not considered equal to any other numeric + value (including NaN). In order to allow + numeric values to be sorted and used in tree-based + indexes, PostgreSQL treats NaN + values as equal, and greater than all non-NaN + values. +

The types decimal and numeric are + equivalent. Both types are part of the SQL + standard. +

8.1.3. Floating-Point Types

The data types real and double + precision are inexact, variable-precision numeric types. + In practice, these types are usually implementations of + IEEE Standard 754 for Binary Floating-Point + Arithmetic (single and double precision, respectively), to the + extent that the underlying processor, operating system, and + compiler support it. +

Inexact means that some values cannot be converted exactly to the + internal format and are stored as approximations, so that storing + and retrieving a value might show slight discrepancies. + Managing these errors and how they propagate through calculations + is the subject of an entire branch of mathematics and computer + science and will not be discussed here, except for the + following points: +

  • If you require exact storage and calculations (such as for + monetary amounts), use the numeric type instead. +

  • If you want to do complicated calculations with these types + for anything important, especially if you rely on certain + behavior in boundary cases (infinity, underflow), you should + evaluate the implementation carefully. +

  • Comparing two floating-point values for equality might not + always work as expected. +

+

On most platforms, the real type has a range of at least + 1E-37 to 1E+37 with a precision of at least 6 decimal digits. The + double precision type typically has a range of around + 1E-307 to 1E+308 with a precision of at least 15 digits. Values that + are too large or too small will cause an error. Rounding might + take place if the precision of an input number is too high. + Numbers too close to zero that are not representable as distinct + from zero will cause an underflow error. +

In addition to ordinary numeric values, the floating-point types + have several special values: +

Infinity
+-Infinity
+NaN

+ These represent the IEEE 754 special values + "infinity", "negative infinity", and + "not-a-number", respectively. (On a machine whose + floating-point arithmetic does not follow IEEE 754, these values + will probably not work as expected.) When writing these values + as constants in an SQL command, you must put quotes around them, + for example UPDATE table SET x = 'Infinity'. On input, + these strings are recognized in a case-insensitive manner. +

Note: IEEE754 specifies that NaN should not compare equal + to any other floating-point value (including NaN). + In order to allow floating-point values to be sorted and used + in tree-based indexes, PostgreSQL treats + NaN values as equal, and greater than all + non-NaN values. +

PostgreSQL also supports the SQL-standard + notations float and + float(p) for specifying + inexact numeric types. Here, p specifies + the minimum acceptable precision in binary digits. + PostgreSQL accepts + float(1) to float(24) as selecting the + real type, while + float(25) to float(53) select + double precision. Values of p + outside the allowed range draw an error. + float with no precision specified is taken to mean + double precision. +

Note: Prior to PostgreSQL 7.4, the precision in + float(p) was taken to mean + so many decimal digits. This has been corrected to match the SQL + standard, which specifies that the precision is measured in binary + digits. The assumption that real and + double precision have exactly 24 and 53 bits in the + mantissa respectively is correct for IEEE-standard floating point + implementations. On non-IEEE platforms it might be off a little, but + for simplicity the same ranges of p are used + on all platforms. +

8.1.4. Serial Types

The data types smallserial, serial and + bigserial are not true types, but merely + a notational convenience for creating unique identifier columns + (similar to the AUTO_INCREMENT property + supported by some other databases). In the current + implementation, specifying: + +

CREATE TABLE tablename (
+    colname SERIAL
+);

+ + is equivalent to specifying: + +

CREATE SEQUENCE tablename_colname_seq;
+CREATE TABLE tablename (
+    colname integer NOT NULL DEFAULT nextval('tablename_colname_seq')
+);
+ALTER SEQUENCE tablename_colname_seq OWNED BY tablename.colname;

+ + Thus, we have created an integer column and arranged for its default + values to be assigned from a sequence generator. A NOT NULL + constraint is applied to ensure that a null value cannot be + inserted. (In most cases you would also want to attach a + UNIQUE or PRIMARY KEY constraint to prevent + duplicate values from being inserted by accident, but this is + not automatic.) Lastly, the sequence is marked as "owned by" + the column, so that it will be dropped if the column or table is dropped. +

Note: Because smallserial, serial and + bigserial are implemented using sequences, there may + be "holes" or gaps in the sequence of values which appears in the + column, even if no rows are ever deleted. A value allocated + from the sequence is still "used up" even if a row containing that + value is never successfully inserted into the table column. This + may happen, for example, if the inserting transaction rolls back. + See nextval() in Section 9.16 + for details. +

Note: Prior to PostgreSQL 7.3, serial + implied UNIQUE. This is no longer automatic. If + you wish a serial column to have a unique constraint or be a + primary key, it must now be specified, just like + any other data type. +

To insert the next value of the sequence into the serial + column, specify that the serial + column should be assigned its default value. This can be done + either by excluding the column from the list of columns in + the INSERT statement, or through the use of + the DEFAULT key word. +

The type names serial and serial4 are + equivalent: both create integer columns. The type + names bigserial and serial8 work + the same way, except that they create a bigint + column. bigserial should be used if you anticipate + the use of more than 231 identifiers over the + lifetime of the table. The type names smallserial and + serial2 also work the same way, except that they + create a smallint column. +

The sequence created for a serial column is + automatically dropped when the owning column is dropped. + You can drop the sequence without dropping the column, but this + will force removal of the column default expression. +


PrevHomeNext
Data TypesUpMonetary Types
\ No newline at end of file diff --git a/doc/src/sgml/html/datatype-oid.html b/doc/src/sgml/html/datatype-oid.html new file mode 100644 index 000000000..50cf70155 --- /dev/null +++ b/doc/src/sgml/html/datatype-oid.html @@ -0,0 +1,585 @@ + +Object Identifier Types

8.18. Object Identifier Types

Object identifiers (OIDs) are used internally by + PostgreSQL as primary keys for various + system tables. OIDs are not added to user-created tables, unless + WITH OIDS is specified when the table is + created, or the default_with_oids + configuration variable is enabled. Type oid represents + an object identifier. There are also several alias types for + oid: regproc, regprocedure, + regoper, regoperator, regclass, + regtype, regconfig, and regdictionary. + Table 8-23 shows an overview. +

The oid type is currently implemented as an unsigned + four-byte integer. Therefore, it is not large enough to provide + database-wide uniqueness in large databases, or even in large + individual tables. So, using a user-created table's OID column as + a primary key is discouraged. OIDs are best used only for + references to system tables. +

The oid type itself has few operations beyond comparison. + It can be cast to integer, however, and then manipulated using the + standard integer operators. (Beware of possible + signed-versus-unsigned confusion if you do this.) +

The OID alias types have no operations of their own except + for specialized input and output routines. These routines are able + to accept and display symbolic names for system objects, rather than + the raw numeric value that type oid would use. The alias + types allow simplified lookup of OID values for objects. For example, + to examine the pg_attribute rows related to a table + mytable, one could write: +

SELECT * FROM pg_attribute WHERE attrelid = 'mytable'::regclass;

+ rather than: +

SELECT * FROM pg_attribute
+  WHERE attrelid = (SELECT oid FROM pg_class WHERE relname = 'mytable');

+ While that doesn't look all that bad by itself, it's still oversimplified. + A far more complicated sub-select would be needed to + select the right OID if there are multiple tables named + mytable in different schemas. + The regclass input converter handles the table lookup according + to the schema path setting, and so it does the "right thing" + automatically. Similarly, casting a table's OID to + regclass is handy for symbolic display of a numeric OID. +

Table 8-23. Object Identifier Types

NameReferencesDescriptionValue Example
oidanynumeric object identifier564182
regprocpg_procfunction namesum
regprocedurepg_procfunction with argument typessum(int4)
regoperpg_operatoroperator name+
regoperatorpg_operatoroperator with argument types*(integer,integer) or -(NONE,integer)
regclasspg_classrelation namepg_type
regtypepg_typedata type nameinteger
regconfigpg_ts_configtext search configurationenglish
regdictionarypg_ts_dicttext search dictionarysimple

All of the OID alias types accept schema-qualified names, and will + display schema-qualified names on output if the object would not + be found in the current search path without being qualified. + The regproc and regoper alias types will only + accept input names that are unique (not overloaded), so they are + of limited use; for most uses regprocedure or + regoperator are more appropriate. For regoperator, + unary operators are identified by writing NONE for the unused + operand. +

An additional property of the OID alias types is the creation of + dependencies. If a + constant of one of these types appears in a stored expression + (such as a column default expression or view), it creates a dependency + on the referenced object. For example, if a column has a default + expression nextval('my_seq'::regclass), + PostgreSQL + understands that the default expression depends on the sequence + my_seq; the system will not let the sequence be dropped + without first removing the default expression. +

Another identifier type used by the system is xid, or transaction + (abbreviated xact) identifier. This is the data type of the system columns + xmin and xmax. Transaction identifiers are 32-bit quantities. +

A third identifier type used by the system is cid, or + command identifier. This is the data type of the system columns + cmin and cmax. Command identifiers are also 32-bit quantities. +

A final identifier type used by the system is tid, or tuple + identifier (row identifier). This is the data type of the system column + ctid. A tuple ID is a pair + (block number, tuple index within block) that identifies the + physical location of the row within its table. +

(The system columns are further explained in Section 5.4.) +


PrevHomeNext
Range TypesUpPseudo-Types
\ No newline at end of file diff --git a/doc/src/sgml/html/datatype-pseudo.html b/doc/src/sgml/html/datatype-pseudo.html new file mode 100644 index 000000000..f706d3d2b --- /dev/null +++ b/doc/src/sgml/html/datatype-pseudo.html @@ -0,0 +1,443 @@ + +Pseudo-Types

8.19. Pseudo-Types

The PostgreSQL type system contains a + number of special-purpose entries that are collectively called + pseudo-types. A pseudo-type cannot be used as a + column data type, but it can be used to declare a function's + argument or result type. Each of the available pseudo-types is + useful in situations where a function's behavior does not + correspond to simply taking or returning a value of a specific + SQL data type. Table 8-24 lists the existing + pseudo-types. +

Table 8-24. Pseudo-Types

NameDescription
anyIndicates that a function accepts any input data type.
anyelementIndicates that a function accepts any data type + (see Section 35.2.5).
anyarrayIndicates that a function accepts any array data type + (see Section 35.2.5).
anynonarrayIndicates that a function accepts any non-array data type + (see Section 35.2.5).
anyenumIndicates that a function accepts any enum data type + (see Section 35.2.5 and + Section 8.7).
anyrangeIndicates that a function accepts any range data type + (see Section 35.2.5 and + Section 8.17).
cstringIndicates that a function accepts or returns a null-terminated C string.
internalIndicates that a function accepts or returns a server-internal + data type.
language_handlerA procedural language call handler is declared to return language_handler.
fdw_handlerA foreign-data wrapper handler is declared to return fdw_handler.
recordIdentifies a function returning an unspecified row type.
triggerA trigger function is declared to return trigger.
voidIndicates that a function returns no value.
opaqueAn obsolete type name that formerly served all the above purposes.

Functions coded in C (whether built-in or dynamically loaded) can be + declared to accept or return any of these pseudo data types. It is up to + the function author to ensure that the function will behave safely + when a pseudo-type is used as an argument type. +

Functions coded in procedural languages can use pseudo-types only as + allowed by their implementation languages. At present the procedural + languages all forbid use of a pseudo-type as argument type, and allow + only void and record as a result type (plus + trigger when the function is used as a trigger). Some also + support polymorphic functions using the types anyelement, + anyarray, anynonarray, anyenum, and + anyrange. +

The internal pseudo-type is used to declare functions + that are meant only to be called internally by the database + system, and not by direct invocation in an SQL + query. If a function has at least one internal-type + argument then it cannot be called from SQL. To + preserve the type safety of this restriction it is important to + follow this coding rule: do not create any function that is + declared to return internal unless it has at least one + internal argument. +


PrevHomeNext
Object Identifier TypesUpFunctions and Operators
\ No newline at end of file diff --git a/doc/src/sgml/html/datatype-textsearch.html b/doc/src/sgml/html/datatype-textsearch.html new file mode 100644 index 000000000..a852d2602 --- /dev/null +++ b/doc/src/sgml/html/datatype-textsearch.html @@ -0,0 +1,526 @@ + +Text Search Types

8.11. Text Search Types

PostgreSQL provides two data types that + are designed to support full text search, which is the activity of + searching through a collection of natural-language documents + to locate those that best match a query. + The tsvector type represents a document in a form optimized + for text search; the tsquery type similarly represents + a text query. + Chapter 12 provides a detailed explanation of this + facility, and Section 9.13 summarizes the + related functions and operators. +

8.11.1. tsvector

A tsvector value is a sorted list of distinct + lexemes, which are words that have been + normalized to merge different variants of the same word + (see Chapter 12 for details). Sorting and + duplicate-elimination are done automatically during input, as shown in + this example: + +

SELECT 'a fat cat sat on a mat and ate a fat rat'::tsvector;
+                      tsvector
+----------------------------------------------------
+ 'a' 'and' 'ate' 'cat' 'fat' 'mat' 'on' 'rat' 'sat'

+ + To represent + lexemes containing whitespace or punctuation, surround them with quotes: + +

SELECT $$the lexeme '    ' contains spaces$$::tsvector;
+                 tsvector                  
+-------------------------------------------
+ '    ' 'contains' 'lexeme' 'spaces' 'the'

+ + (We use dollar-quoted string literals in this example and the next one + to avoid the confusion of having to double quote marks within the + literals.) Embedded quotes and backslashes must be doubled: + +

SELECT $$the lexeme 'Joe''s' contains a quote$$::tsvector;
+                    tsvector                    
+------------------------------------------------
+ 'Joe''s' 'a' 'contains' 'lexeme' 'quote' 'the'

+ + Optionally, integer positions + can be attached to lexemes: + +

SELECT 'a:1 fat:2 cat:3 sat:4 on:5 a:6 mat:7 and:8 ate:9 a:10 fat:11 rat:12'::tsvector;
+                                  tsvector
+-------------------------------------------------------------------------------
+ 'a':1,6,10 'and':8 'ate':9 'cat':3 'fat':2,11 'mat':7 'on':5 'rat':12 'sat':4

+ + A position normally indicates the source word's location in the + document. Positional information can be used for + proximity ranking. Position values can + range from 1 to 16383; larger numbers are silently set to 16383. + Duplicate positions for the same lexeme are discarded. +

Lexemes that have positions can further be labeled with a + weight, which can be A, + B, C, or D. + D is the default and hence is not shown on output: + +

SELECT 'a:1A fat:2B,4C cat:5D'::tsvector;
+          tsvector          
+----------------------------
+ 'a':1A 'cat':5 'fat':2B,4C

+ + Weights are typically used to reflect document structure, for example + by marking title words differently from body words. Text search + ranking functions can assign different priorities to the different + weight markers. +

It is important to understand that the + tsvector type itself does not perform any normalization; + it assumes the words it is given are normalized appropriately + for the application. For example, + +

select 'The Fat Rats'::tsvector;
+      tsvector      
+--------------------
+ 'Fat' 'Rats' 'The'

+ + For most English-text-searching applications the above words would + be considered non-normalized, but tsvector doesn't care. + Raw document text should usually be passed through + to_tsvector to normalize the words appropriately + for searching: + +

SELECT to_tsvector('english', 'The Fat Rats');
+   to_tsvector   
+-----------------
+ 'fat':2 'rat':3

+ + Again, see Chapter 12 for more detail. +

8.11.2. tsquery

A tsquery value stores lexemes that are to be + searched for, and combines them honoring the Boolean operators + & (AND), | (OR), and + ! (NOT). Parentheses can be used to enforce grouping + of the operators: + +

SELECT 'fat & rat'::tsquery;
+    tsquery    
+---------------
+ 'fat' & 'rat'
+
+SELECT 'fat & (rat | cat)'::tsquery;
+          tsquery          
+---------------------------
+ 'fat' & ( 'rat' | 'cat' )
+
+SELECT 'fat & rat & ! cat'::tsquery;
+        tsquery         
+------------------------
+ 'fat' & 'rat' & !'cat'

+ + In the absence of parentheses, ! (NOT) binds most tightly, + and & (AND) binds more tightly than + | (OR). +

Optionally, lexemes in a tsquery can be labeled with + one or more weight letters, which restricts them to match only + tsvector lexemes with matching weights: + +

SELECT 'fat:ab & cat'::tsquery;
+    tsquery
+------------------
+ 'fat':AB & 'cat'

+

Also, lexemes in a tsquery can be labeled with * + to specify prefix matching: +

SELECT 'super:*'::tsquery;
+  tsquery  
+-----------
+ 'super':*

+ This query will match any word in a tsvector that begins + with "super". Note that prefixes are first processed by + text search configurations, which means this comparison returns + true: +

SELECT to_tsvector( 'postgraduate' ) @@ to_tsquery( 'postgres:*' );
+ ?column? 
+----------
+ t
+(1 row)

+ because postgres gets stemmed to postgr: +

SELECT to_tsquery('postgres:*');
+ to_tsquery 
+------------
+ 'postgr':*
+(1 row)

+ which then matches postgraduate. +

Quoting rules for lexemes are the same as described previously for + lexemes in tsvector; and, as with tsvector, + any required normalization of words must be done before converting + to the tsquery type. The to_tsquery + function is convenient for performing such normalization: + +

SELECT to_tsquery('Fat:ab & Cats');
+    to_tsquery    
+------------------
+ 'fat':AB & 'cat'

+


PrevHomeNext
Bit String TypesUpUUID Type
\ No newline at end of file diff --git a/doc/src/sgml/html/datatype-uuid.html b/doc/src/sgml/html/datatype-uuid.html new file mode 100644 index 000000000..9c4be255e --- /dev/null +++ b/doc/src/sgml/html/datatype-uuid.html @@ -0,0 +1,227 @@ + +UUID Type

8.12. UUID Type

The data type uuid stores Universally Unique Identifiers + (UUID) as defined by RFC 4122, ISO/IEC 9834-8:2005, and related standards. + (Some systems refer to this data type as a globally unique identifier, or + GUID, instead.) This + identifier is a 128-bit quantity that is generated by an algorithm chosen + to make it very unlikely that the same identifier will be generated by + anyone else in the known universe using the same algorithm. Therefore, + for distributed systems, these identifiers provide a better uniqueness + guarantee than sequence generators, which + are only unique within a single database. +

A UUID is written as a sequence of lower-case hexadecimal digits, + in several groups separated by hyphens, specifically a group of 8 + digits followed by three groups of 4 digits followed by a group of + 12 digits, for a total of 32 digits representing the 128 bits. An + example of a UUID in this standard form is: +

a0eebc99-9c0b-4ef8-bb6d-6bb9bd380a11

+ PostgreSQL also accepts the following + alternative forms for input: + use of upper-case digits, the standard format surrounded by + braces, omitting some or all hyphens, adding a hyphen after any + group of four digits. Examples are: +

A0EEBC99-9C0B-4EF8-BB6D-6BB9BD380A11
+{a0eebc99-9c0b-4ef8-bb6d-6bb9bd380a11}
+a0eebc999c0b4ef8bb6d6bb9bd380a11
+a0ee-bc99-9c0b-4ef8-bb6d-6bb9-bd38-0a11
+{a0eebc99-9c0b4ef8-bb6d6bb9-bd380a11}

+ Output is always in the standard form. +

PostgreSQL provides storage and comparison + functions for UUIDs, but the core database does not include any + function for generating UUIDs, because no single algorithm is well + suited for every application. The uuid-ossp module + provides functions that implement several standard algorithms. + Alternatively, UUIDs could be generated by client applications or + other libraries invoked through a server-side function. +


PrevHomeNext
Text Search TypesUpXML Type
\ No newline at end of file diff --git a/doc/src/sgml/html/datatype-xml.html b/doc/src/sgml/html/datatype-xml.html new file mode 100644 index 000000000..09e3b895d --- /dev/null +++ b/doc/src/sgml/html/datatype-xml.html @@ -0,0 +1,535 @@ + +XML Type

8.13. XML Type

The xml data type can be used to store XML data. Its + advantage over storing XML data in a text field is that it + checks the input values for well-formedness, and there are support + functions to perform type-safe operations on it; see Section 9.14. Use of this data type requires the + installation to have been built with configure + --with-libxml. +

The xml type can store well-formed + "documents", as defined by the XML standard, as well + as "content" fragments, which are defined by the + production XMLDecl? content in the XML + standard. Roughly, this means that content fragments can have + more than one top-level element or character node. The expression + xmlvalue IS DOCUMENT + can be used to evaluate whether a particular xml + value is a full document or only a content fragment. +

8.13.1. Creating XML Values

To produce a value of type xml from character data, + use the function + xmlparse: +

XMLPARSE ( { DOCUMENT | CONTENT } value)

+ Examples: +

XMLPARSE (DOCUMENT '<?xml version="1.0"?><book><title>Manual</title><chapter>...</chapter></book>')
+XMLPARSE (CONTENT 'abc<foo>bar</foo><bar>foo</bar>')

+ While this is the only way to convert character strings into XML + values according to the SQL standard, the PostgreSQL-specific + syntaxes: +

xml '<foo>bar</foo>'
+'<foo>bar</foo>'::xml

+ can also be used. +

The xml type does not validate input values + against a document type declaration + (DTD), + even when the input value specifies a DTD. + There is also currently no built-in support for validating against + other XML schema languages such as XML Schema. +

The inverse operation, producing a character string value from + xml, uses the function + xmlserialize: +

XMLSERIALIZE ( { DOCUMENT | CONTENT } value AS type )

+ type can be + character, character varying, or + text (or an alias for one of those). Again, according + to the SQL standard, this is the only way to convert between type + xml and character types, but PostgreSQL also allows + you to simply cast the value. +

When a character string value is cast to or from type + xml without going through XMLPARSE or + XMLSERIALIZE, respectively, the choice of + DOCUMENT versus CONTENT is + determined by the "XML option" + + session configuration parameter, which can be set using the + standard command: +

SET XML OPTION { DOCUMENT | CONTENT };

+ or the more PostgreSQL-like syntax +

SET xmloption TO { DOCUMENT | CONTENT };

+ The default is CONTENT, so all forms of XML + data are allowed. +

Note: With the default XML option setting, you cannot directly cast + character strings to type xml if they contain a + document type declaration, because the definition of XML content + fragment does not accept them. If you need to do that, either + use XMLPARSE or change the XML option. +

8.13.2. Encoding Handling

Care must be taken when dealing with multiple character encodings + on the client, server, and in the XML data passed through them. + When using the text mode to pass queries to the server and query + results to the client (which is the normal mode), PostgreSQL + converts all character data passed between the client and the + server and vice versa to the character encoding of the respective + end; see Section 22.3. This includes string + representations of XML values, such as in the above examples. + This would ordinarily mean that encoding declarations contained in + XML data can become invalid as the character data is converted + to other encodings while travelling between client and server, + because the embedded encoding declaration is not changed. To cope + with this behavior, encoding declarations contained in + character strings presented for input to the xml type + are ignored, and content is assumed + to be in the current server encoding. Consequently, for correct + processing, character strings of XML data must be sent + from the client in the current client encoding. It is the + responsibility of the client to either convert documents to the + current client encoding before sending them to the server, or to + adjust the client encoding appropriately. On output, values of + type xml will not have an encoding declaration, and + clients should assume all data is in the current client + encoding. +

When using binary mode to pass query parameters to the server + and query results back to the client, no character set conversion + is performed, so the situation is different. In this case, an + encoding declaration in the XML data will be observed, and if it + is absent, the data will be assumed to be in UTF-8 (as required by + the XML standard; note that PostgreSQL does not support UTF-16). + On output, data will have an encoding declaration + specifying the client encoding, unless the client encoding is + UTF-8, in which case it will be omitted. +

Needless to say, processing XML data with PostgreSQL will be less + error-prone and more efficient if the XML data encoding, client encoding, + and server encoding are the same. Since XML data is internally + processed in UTF-8, computations will be most efficient if the + server encoding is also UTF-8. +

Caution

Some XML-related functions may not work at all on non-ASCII data + when the server encoding is not UTF-8. This is known to be an + issue for xpath() in particular. +

8.13.3. Accessing XML Values

The xml data type is unusual in that it does not + provide any comparison operators. This is because there is no + well-defined and universally useful comparison algorithm for XML + data. One consequence of this is that you cannot retrieve rows by + comparing an xml column against a search value. XML + values should therefore typically be accompanied by a separate key + field such as an ID. An alternative solution for comparing XML + values is to convert them to character strings first, but note + that character string comparison has little to do with a useful + XML comparison method. +

Since there are no comparison operators for the xml + data type, it is not possible to create an index directly on a + column of this type. If speedy searches in XML data are desired, + possible workarounds include casting the expression to a + character string type and indexing that, or indexing an XPath + expression. Of course, the actual query would have to be adjusted + to search by the indexed expression. +

The text-search functionality in PostgreSQL can also be used to speed + up full-document searches of XML data. The necessary + preprocessing support is, however, not yet available in the PostgreSQL + distribution. +


PrevHomeNext
UUID TypeUpJSON Type
\ No newline at end of file diff --git a/doc/src/sgml/html/datatype.html b/doc/src/sgml/html/datatype.html new file mode 100644 index 000000000..c4a46f418 --- /dev/null +++ b/doc/src/sgml/html/datatype.html @@ -0,0 +1,1317 @@ + +Data Types

Chapter 8. Data Types

Table of Contents
8.1. Numeric Types
8.1.1. Integer Types
8.1.2. Arbitrary Precision Numbers
8.1.3. Floating-Point Types
8.1.4. Serial Types
8.2. Monetary Types
8.3. Character Types
8.4. Binary Data Types
8.4.1. bytea Hex Format
8.4.2. bytea Escape Format
8.5. Date/Time Types
8.5.1. Date/Time Input
8.5.2. Date/Time Output
8.5.3. Time Zones
8.5.4. Interval Input
8.5.5. Interval Output
8.6. Boolean Type
8.7. Enumerated Types
8.7.1. Declaration of Enumerated Types
8.7.2. Ordering
8.7.3. Type Safety
8.7.4. Implementation Details
8.8. Geometric Types
8.8.1. Points
8.8.2. Line Segments
8.8.3. Boxes
8.8.4. Paths
8.8.5. Polygons
8.8.6. Circles
8.9. Network Address Types
8.9.1. inet
8.9.2. cidr
8.9.3. inet vs. cidr
8.9.4. macaddr
8.10. Bit String Types
8.11. Text Search Types
8.11.1. tsvector
8.11.2. tsquery
8.12. UUID Type
8.13. XML Type
8.13.1. Creating XML Values
8.13.2. Encoding Handling
8.13.3. Accessing XML Values
8.14. JSON Type
8.15. Arrays
8.15.1. Declaration of Array Types
8.15.2. Array Value Input
8.15.3. Accessing Arrays
8.15.4. Modifying Arrays
8.15.5. Searching in Arrays
8.15.6. Array Input and Output Syntax
8.16. Composite Types
8.16.1. Declaration of Composite Types
8.16.2. Composite Value Input
8.16.3. Accessing Composite Types
8.16.4. Modifying Composite Types
8.16.5. Composite Type Input and Output Syntax
8.17. Range Types
8.17.1. Built-in Range Types
8.17.2. Examples
8.17.3. Inclusive and Exclusive Bounds
8.17.4. Infinite (Unbounded) Ranges
8.17.5. Range Input/Output
8.17.6. Constructing Ranges
8.17.7. Discrete Range Types
8.17.8. Defining New Range Types
8.17.9. Indexing
8.17.10. Constraints on Ranges
8.18. Object Identifier Types
8.19. Pseudo-Types

PostgreSQL has a rich set of native data + types available to users. Users can add new types to + PostgreSQL using the CREATE TYPE command. +

Table 8-1 shows all the built-in general-purpose data + types. Most of the alternative names listed in the + "Aliases" column are the names used internally by + PostgreSQL for historical reasons. In + addition, some internally used or deprecated types are available, + but are not listed here. +

Table 8-1. Data Types

NameAliasesDescription
bigintint8signed eight-byte integer
bigserialserial8autoincrementing eight-byte integer
bit [ (n) ] fixed-length bit string
bit varying [ (n) ]varbitvariable-length bit string
booleanboollogical Boolean (true/false)
box rectangular box on a plane
bytea binary data ("byte array")
character varying [ (n) ]varchar [ (n) ]variable-length character string
character [ (n) ]char [ (n) ]fixed-length character string
cidr IPv4 or IPv6 network address
circle circle on a plane
date calendar date (year, month, day)
double precisionfloat8double precision floating-point number (8 bytes)
inet IPv4 or IPv6 host address
integerint, int4signed four-byte integer
interval [ fields ] [ (p) ] time span
line infinite line on a plane
lseg line segment on a plane
macaddr MAC (Media Access Control) address
money currency amount
numeric [ (p, + s) ]decimal [ (p, + s) ]exact numeric of selectable precision
path geometric path on a plane
point geometric point on a plane
polygon closed geometric path on a plane
realfloat4single precision floating-point number (4 bytes)
smallintint2signed two-byte integer
smallserialserial2autoincrementing two-byte integer
serialserial4autoincrementing four-byte integer
text variable-length character string
time [ (p) ] [ without time zone ] time of day (no time zone)
time [ (p) ] with time zonetimetztime of day, including time zone
timestamp [ (p) ] [ without time zone ] date and time (no time zone)
timestamp [ (p) ] with time zonetimestamptzdate and time, including time zone
tsquery text search query
tsvector text search document
txid_snapshot user-level transaction ID snapshot
uuid universally unique identifier
xml XML data
json JSON data

Compatibility: The following types (or spellings thereof) are specified by + SQL: bigint, bit, bit + varying, boolean, char, + character varying, character, + varchar, date, double + precision, integer, interval, + numeric, decimal, real, + smallint, time (with or without time zone), + timestamp (with or without time zone), + xml. +

Each data type has an external representation determined by its input + and output functions. Many of the built-in types have + obvious external formats. However, several types are either unique + to PostgreSQL, such as geometric + paths, or have several possible formats, such as the date + and time types. + Some of the input and output functions are not invertible, i.e., + the result of an output function might lose accuracy when compared to + the original input. +


PrevHomeNext
WITH Queries (Common Table Expressions)UpNumeric Types
\ No newline at end of file diff --git a/doc/src/sgml/html/datetime-appendix.html b/doc/src/sgml/html/datetime-appendix.html new file mode 100644 index 000000000..6e15beb3f --- /dev/null +++ b/doc/src/sgml/html/datetime-appendix.html @@ -0,0 +1,212 @@ + +Date/Time Support

Appendix B. Date/Time Support

PostgreSQL uses an internal heuristic + parser for all date/time input support. Dates and times are input as + strings, and are broken up into distinct fields with a preliminary + determination of what kind of information can be in the + field. Each field is interpreted and either assigned a numeric + value, ignored, or rejected. + The parser contains internal lookup tables for all textual fields, + including months, days of the week, and time zones. +

This appendix includes information on the content of these + lookup tables and describes the steps used by the parser to decode + dates and times. +


PrevHomeNext
PostgreSQL Error CodesUpDate/Time Input Interpretation
\ No newline at end of file diff --git a/doc/src/sgml/html/datetime-config-files.html b/doc/src/sgml/html/datetime-config-files.html new file mode 100644 index 000000000..2aa1708d9 --- /dev/null +++ b/doc/src/sgml/html/datetime-config-files.html @@ -0,0 +1,412 @@ + +Date/Time Configuration Files
PostgreSQL 9.2.2 Documentation
PrevUpAppendix B. Date/Time SupportNext

B.3. Date/Time Configuration Files

Since timezone abbreviations are not well standardized, + PostgreSQL provides a means to customize + the set of abbreviations accepted by the server. The + timezone_abbreviations run-time parameter + determines the active set of abbreviations. While this parameter + can be altered by any database user, the possible values for it + are under the control of the database administrator — they + are in fact names of configuration files stored in + .../share/timezonesets/ of the installation directory. + By adding or altering files in that directory, the administrator + can set local policy for timezone abbreviations. +

timezone_abbreviations can be set to any file name + found in .../share/timezonesets/, if the file's name + is entirely alphabetic. (The prohibition against non-alphabetic + characters in timezone_abbreviations prevents reading + files outside the intended directory, as well as reading editor + backup files and other extraneous files.) +

A timezone abbreviation file can contain blank lines and comments + beginning with #. Non-comment lines must have one of + these formats: + +

time_zone_name offset
+time_zone_name offset D
+@INCLUDE file_name
+@OVERRIDE

+

A time_zone_name is just the abbreviation + being defined. The offset is the zone's + offset in seconds from UTC, positive being east from Greenwich and + negative being west. For example, -18000 would be five hours west + of Greenwich, or North American east coast standard time. D + indicates that the zone name represents local daylight-savings time + rather than standard time. Since all known time zone offsets are on + 15 minute boundaries, the number of seconds has to be a multiple of 900. +

The @INCLUDE syntax allows inclusion of another file in the + .../share/timezonesets/ directory. Inclusion can be nested, + to a limited depth. +

The @OVERRIDE syntax indicates that subsequent entries in the + file can override previous entries (i.e., entries obtained from included + files). Without this, conflicting definitions of the same timezone + abbreviation are considered an error. +

In an unmodified installation, the file Default contains + all the non-conflicting time zone abbreviations for most of the world. + Additional files Australia and India are + provided for those regions: these files first include the + Default file and then add or modify timezones as needed. +

For reference purposes, a standard installation also contains files + Africa.txt, America.txt, etc, containing + information about every time zone abbreviation known to be in use + according to the zoneinfo timezone database. The zone name + definitions found in these files can be copied and pasted into a custom + configuration file as needed. Note that these files cannot be directly + referenced as timezone_abbreviations settings, because of + the dot embedded in their names. +

Note: If an error occurs while reading the time zone data sets, no new value is + applied but the old set is kept. If the error occurs while starting the + database, startup fails. +

Caution

Time zone abbreviations defined in the configuration file override + non-timezone meanings built into PostgreSQL. + For example, the Australia configuration file defines + SAT (for South Australian Standard Time). When this + file is active, SAT will not be recognized as an abbreviation + for Saturday. +

Caution

If you modify files in .../share/timezonesets/, + it is up to you to make backups — a normal database dump + will not include this directory. +


PrevHomeNext
Date/Time Key WordsUpHistory of Units
\ No newline at end of file diff --git a/doc/src/sgml/html/datetime-input-rules.html b/doc/src/sgml/html/datetime-input-rules.html new file mode 100644 index 000000000..5496ebc41 --- /dev/null +++ b/doc/src/sgml/html/datetime-input-rules.html @@ -0,0 +1,399 @@ + +Date/Time Input Interpretation
PostgreSQL 9.2.2 Documentation
PrevUpAppendix B. Date/Time SupportNext

B.1. Date/Time Input Interpretation

The date/time type inputs are all decoded using the following procedure. +

  1. Break the input string into tokens and categorize each token as + a string, time, time zone, or number. +

    1. If the numeric token contains a colon (:), this is + a time string. Include all subsequent digits and colons. +

    2. If the numeric token contains a dash (-), slash + (/), or two or more dots (.), this is + a date string which might have a text month. If a date token has + already been seen, it is instead interpreted as a time zone + name (e.g., America/New_York). +

    3. If the token is numeric only, then it is either a single field + or an ISO 8601 concatenated date (e.g., + 19990113 for January 13, 1999) or time + (e.g., 141516 for 14:15:16). +

    4. If the token starts with a plus (+) or minus + (-), then it is either a numeric time zone or a special + field. +

  2. If the token is a text string, match up with possible strings: +

    1. Do a binary-search table lookup for the token as a time zone + abbreviation. +

    2. If not found, do a similar binary-search table lookup to match + the token as either a special string (e.g., today), + day (e.g., Thursday), + month (e.g., January), + or noise word (e.g., at, on). +

    3. If still not found, throw an error. +

  3. When the token is a number or number field: +

    1. If there are eight or six digits, + and if no other date fields have been previously read, then interpret + as a "concatenated date" (e.g., + 19990118 or 990118). + The interpretation is YYYYMMDD or YYMMDD. +

    2. If the token is three digits + and a year has already been read, then interpret as day of year. +

    3. If four or six digits and a year has already been read, then + interpret as a time (HHMM or HHMMSS). +

    4. If three or more digits and no date fields have yet been found, + interpret as a year (this forces yy-mm-dd ordering of the remaining + date fields). +

    5. Otherwise the date field ordering is assumed to follow the + DateStyle setting: mm-dd-yy, dd-mm-yy, or yy-mm-dd. + Throw an error if a month or day field is found to be out of range. +

  4. If BC has been specified, negate the year and add one for + internal storage. (There is no year zero in the Gregorian + calendar, so numerically 1 BC becomes year zero.) +

  5. If BC was not specified, and if the year field was two digits in length, + then adjust the year to four digits. If the field is less than 70, then + add 2000, otherwise add 1900. + +

    Tip: Gregorian years AD 1-99 can be entered by using 4 digits with leading + zeros (e.g., 0099 is AD 99). +

    +


PrevHomeNext
Date/Time SupportUpDate/Time Key Words
\ No newline at end of file diff --git a/doc/src/sgml/html/datetime-keywords.html b/doc/src/sgml/html/datetime-keywords.html new file mode 100644 index 000000000..445fd3f30 --- /dev/null +++ b/doc/src/sgml/html/datetime-keywords.html @@ -0,0 +1,430 @@ + +Date/Time Key Words
PostgreSQL 9.2.2 Documentation
PrevUpAppendix B. Date/Time SupportNext

B.2. Date/Time Key Words

Table B-1 shows the tokens that are + recognized as names of months. +

Table B-1. Month Names

MonthAbbreviations
JanuaryJan
FebruaryFeb
MarchMar
AprilApr
May 
JuneJun
JulyJul
AugustAug
SeptemberSep, Sept
OctoberOct
NovemberNov
DecemberDec

Table B-2 shows the tokens that are + recognized as names of days of the week. +

Table B-2. Day of the Week Names

DayAbbreviations
SundaySun
MondayMon
TuesdayTue, Tues
WednesdayWed, Weds
ThursdayThu, Thur, Thurs
FridayFri
SaturdaySat

Table B-3 shows the tokens that serve + various modifier purposes. +

Table B-3. Date/Time Field Modifiers

IdentifierDescription
AMTime is before 12:00
ATIgnored
JULIAN, JD, JNext field is Julian Date
ONIgnored
PMTime is on or after 12:00
TNext field is time

PrevHomeNext
Date/Time Input InterpretationUpDate/Time Configuration Files
\ No newline at end of file diff --git a/doc/src/sgml/html/datetime-units-history.html b/doc/src/sgml/html/datetime-units-history.html new file mode 100644 index 000000000..ce52015f2 --- /dev/null +++ b/doc/src/sgml/html/datetime-units-history.html @@ -0,0 +1,339 @@ + +History of Units
PostgreSQL 9.2.2 Documentation
PrevUpAppendix B. Date/Time SupportNext

B.4. History of Units

The SQL standard states that "Within the definition of a + 'datetime literal', the 'datetime + values' are constrained by the natural rules for dates and + times according to the Gregorian calendar". + PostgreSQL follows the SQL + standard's lead by counting dates exclusively in the Gregorian + calendar, even for years before that calendar was in use. + This rule is known as the proleptic Gregorian calendar. +

The Julian calendar was introduced by Julius Caesar in 45 BC. + It was in common use in the Western world + until the year 1582, when countries started changing to the Gregorian + calendar. In the Julian calendar, the tropical year is + approximated as 365 1/4 days = 365.25 days. This gives an error of + about 1 day in 128 years. +

The accumulating calendar error prompted + Pope Gregory XIII to reform the calendar in accordance with + instructions from the Council of Trent. + In the Gregorian calendar, the tropical year is approximated as + 365 + 97 / 400 days = 365.2425 days. Thus it takes approximately 3300 + years for the tropical year to shift one day with respect to the + Gregorian calendar. +

The approximation 365+97/400 is achieved by having 97 leap years + every 400 years, using the following rules: + +

Every year divisible by 4 is a leap year. +
However, every year divisible by 100 is not a leap year. +
However, every year divisible by 400 is a leap year after all. +

+ + So, 1700, 1800, 1900, 2100, and 2200 are not leap years. But 1600, + 2000, and 2400 are leap years. + + By contrast, in the older Julian calendar all years divisible by 4 are leap + years. +

The papal bull of February 1582 decreed that 10 days should be dropped + from October 1582 so that 15 October should follow immediately after + 4 October. + This was observed in Italy, Poland, Portugal, and Spain. Other Catholic + countries followed shortly after, but Protestant countries were + reluctant to change, and the Greek Orthodox countries didn't change + until the start of the 20th century. + + The reform was observed by Great Britain and its dominions (including what + is now the USA) in 1752. + Thus 2 September 1752 was followed by 14 September 1752. + + This is why Unix systems have the cal program + produce the following: + +

$ cal 9 1752
+   September 1752
+ S  M Tu  W Th  F  S
+       1  2 14 15 16
+17 18 19 20 21 22 23
+24 25 26 27 28 29 30

+ + But, of course, this calendar is only valid for Great Britain and + dominions, not other places. + Since it would be difficult and confusing to try to track the actual + calendars that were in use in various places at various times, + PostgreSQL does not try, but rather follows the Gregorian + calendar rules for all dates, even though this method is not historically + accurate. +

Different calendars have been developed in various parts of the + world, many predating the Gregorian system. + + For example, + the beginnings of the Chinese calendar can be traced back to the 14th + century BC. Legend has it that the Emperor Huangdi invented that + calendar in 2637 BC. + + The People's Republic of China uses the Gregorian calendar + for civil purposes. The Chinese calendar is used for determining + festivals. +

The Julian Date system is another type of + calendar, unrelated to the Julian calendar though it is confusingly + named similarly to that calendar. + The Julian Date system was invented by the French scholar + Joseph Justus Scaliger (1540-1609) + and probably takes its name from Scaliger's father, + the Italian scholar Julius Caesar Scaliger (1484-1558). + In the Julian Date system, each day has a sequential number, starting + from JD 0 (which is sometimes called the Julian Date). + JD 0 corresponds to 1 January 4713 BC in the Julian calendar, or + 24 November 4714 BC in the Gregorian calendar. Julian Date counting + is most often used by astronomers for labeling their nightly observations, + and therefore a date runs from noon UTC to the next noon UTC, rather than + from midnight to midnight: JD 0 designates the 24 hours from noon UTC on + 24 November 4714 BC to noon UTC on 25 November 4714 BC. +

Although PostgreSQL supports Julian Date notation for + input and output of dates (and also uses Julian dates for some internal + datetime calculations), it does not observe the nicety of having dates + run from noon to noon. PostgreSQL treats a Julian Date + as running from midnight to midnight. +


PrevHomeNext
Date/Time Configuration FilesUpSQL Key Words
\ No newline at end of file diff --git a/doc/src/sgml/html/dblink.html b/doc/src/sgml/html/dblink.html new file mode 100644 index 000000000..e2107881d --- /dev/null +++ b/doc/src/sgml/html/dblink.html @@ -0,0 +1,286 @@ + +dblink
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.9. dblink

Table of Contents
dblink_connect -- opens a persistent connection to a remote database
dblink_connect_u -- opens a persistent connection to a remote database, insecurely
dblink_disconnect -- closes a persistent connection to a remote database
dblink -- executes a query in a remote database
dblink_exec -- executes a command in a remote database
dblink_open -- opens a cursor in a remote database
dblink_fetch -- returns rows from an open cursor in a remote database
dblink_close -- closes a cursor in a remote database
dblink_get_connections -- returns the names of all open named dblink connections
dblink_error_message -- gets last error message on the named connection
dblink_send_query -- sends an async query to a remote database
dblink_is_busy -- checks if connection is busy with an async query
dblink_get_notify -- retrieve async notifications on a connection
dblink_get_result -- gets an async query result
dblink_cancel_query -- cancels any active query on the named connection
dblink_get_pkey -- returns the positions and field names of a relation's + primary key fields +
dblink_build_sql_insert --  builds an INSERT statement using a local tuple, replacing the + primary key field values with alternative supplied values +
dblink_build_sql_delete -- builds a DELETE statement using supplied values for primary + key field values +
dblink_build_sql_update -- builds an UPDATE statement using a local tuple, replacing + the primary key field values with alternative supplied values +

dblink is a module which supports connections to + other PostgreSQL databases from within a database + session. +


PrevHomeNext
cubeUpdblink_connect
\ No newline at end of file diff --git a/doc/src/sgml/html/ddl-alter.html b/doc/src/sgml/html/ddl-alter.html new file mode 100644 index 000000000..59c6c4e11 --- /dev/null +++ b/doc/src/sgml/html/ddl-alter.html @@ -0,0 +1,511 @@ + +Modifying Tables

5.5. Modifying Tables

When you create a table and you realize that you made a mistake, or + the requirements of the application change, you can drop the + table and create it again. But this is not a convenient option if + the table is already filled with data, or if the table is + referenced by other database objects (for instance a foreign key + constraint). Therefore PostgreSQL + provides a family of commands to make modifications to existing + tables. Note that this is conceptually distinct from altering + the data contained in the table: here we are interested in altering + the definition, or structure, of the table. +

You can: +

  • Add columns

  • Remove columns

  • Add constraints

  • Remove constraints

  • Change default values

  • Change column data types

  • Rename columns

  • Rename tables

+ + All these actions are performed using the + ALTER TABLE + command, whose reference page contains details beyond those given + here. +

5.5.1. Adding a Column

To add a column, use a command like: +

ALTER TABLE products ADD COLUMN description text;

+ The new column is initially filled with whatever default + value is given (null if you don't specify a DEFAULT clause). +

You can also define constraints on the column at the same time, + using the usual syntax: +

ALTER TABLE products ADD COLUMN description text CHECK (description <> '');

+ In fact all the options that can be applied to a column description + in CREATE TABLE can be used here. Keep in mind however + that the default value must satisfy the given constraints, or the + ADD will fail. Alternatively, you can add + constraints later (see below) after you've filled in the new column + correctly. +

Tip: Adding a column with a default requires updating each row of the + table (to store the new column value). However, if no default is + specified, PostgreSQL is able to avoid + the physical update. So if you intend to fill the column with + mostly nondefault values, it's best to add the column with no default, + insert the correct values using UPDATE, and then add any + desired default as described below. +

5.5.2. Removing a Column

To remove a column, use a command like: +

ALTER TABLE products DROP COLUMN description;

+ Whatever data was in the column disappears. Table constraints involving + the column are dropped, too. However, if the column is referenced by a + foreign key constraint of another table, + PostgreSQL will not silently drop that + constraint. You can authorize dropping everything that depends on + the column by adding CASCADE: +

ALTER TABLE products DROP COLUMN description CASCADE;

+ See Section 5.12 for a description of the general + mechanism behind this. +

5.5.3. Adding a Constraint

To add a constraint, the table constraint syntax is used. For example: +

ALTER TABLE products ADD CHECK (name <> '');
+ALTER TABLE products ADD CONSTRAINT some_name UNIQUE (product_no);
+ALTER TABLE products ADD FOREIGN KEY (product_group_id) REFERENCES product_groups;

+ To add a not-null constraint, which cannot be written as a table + constraint, use this syntax: +

ALTER TABLE products ALTER COLUMN product_no SET NOT NULL;

+

The constraint will be checked immediately, so the table data must + satisfy the constraint before it can be added. +

5.5.4. Removing a Constraint

To remove a constraint you need to know its name. If you gave it + a name then that's easy. Otherwise the system assigned a + generated name, which you need to find out. The + psql command \d + tablename can be helpful + here; other interfaces might also provide a way to inspect table + details. Then the command is: +

ALTER TABLE products DROP CONSTRAINT some_name;

+ (If you are dealing with a generated constraint name like $2, + don't forget that you'll need to double-quote it to make it a valid + identifier.) +

As with dropping a column, you need to add CASCADE if you + want to drop a constraint that something else depends on. An example + is that a foreign key constraint depends on a unique or primary key + constraint on the referenced column(s). +

This works the same for all constraint types except not-null + constraints. To drop a not null constraint use: +

ALTER TABLE products ALTER COLUMN product_no DROP NOT NULL;

+ (Recall that not-null constraints do not have names.) +

5.5.5. Changing a Column's Default Value

To set a new default for a column, use a command like: +

ALTER TABLE products ALTER COLUMN price SET DEFAULT 7.77;

+ Note that this doesn't affect any existing rows in the table, it + just changes the default for future INSERT commands. +

To remove any default value, use: +

ALTER TABLE products ALTER COLUMN price DROP DEFAULT;

+ This is effectively the same as setting the default to null. + As a consequence, it is not an error + to drop a default where one hadn't been defined, because the + default is implicitly the null value. +

5.5.6. Changing a Column's Data Type

To convert a column to a different data type, use a command like: +

ALTER TABLE products ALTER COLUMN price TYPE numeric(10,2);

+ This will succeed only if each existing entry in the column can be + converted to the new type by an implicit cast. If a more complex + conversion is needed, you can add a USING clause that + specifies how to compute the new values from the old. +

PostgreSQL will attempt to convert the column's + default value (if any) to the new type, as well as any constraints + that involve the column. But these conversions might fail, or might + produce surprising results. It's often best to drop any constraints + on the column before altering its type, and then add back suitably + modified constraints afterwards. +

5.5.7. Renaming a Column

To rename a column: +

ALTER TABLE products RENAME COLUMN product_no TO product_number;

+

5.5.8. Renaming a Table

To rename a table: +

ALTER TABLE products RENAME TO items;

+


PrevHomeNext
System ColumnsUpPrivileges
\ No newline at end of file diff --git a/doc/src/sgml/html/ddl-basics.html b/doc/src/sgml/html/ddl-basics.html new file mode 100644 index 000000000..6bba67188 --- /dev/null +++ b/doc/src/sgml/html/ddl-basics.html @@ -0,0 +1,346 @@ + +Table Basics

5.1. Table Basics

A table in a relational database is much like a table on paper: It + consists of rows and columns. The number and order of the columns + is fixed, and each column has a name. The number of rows is + variable — it reflects how much data is stored at a given moment. + SQL does not make any guarantees about the order of the rows in a + table. When a table is read, the rows will appear in an unspecified order, + unless sorting is explicitly requested. This is covered in Chapter 7. Furthermore, SQL does not assign unique + identifiers to rows, so it is possible to have several completely + identical rows in a table. This is a consequence of the + mathematical model that underlies SQL but is usually not desirable. + Later in this chapter we will see how to deal with this issue. +

Each column has a data type. The data type constrains the set of + possible values that can be assigned to a column and assigns + semantics to the data stored in the column so that it can be used + for computations. For instance, a column declared to be of a + numerical type will not accept arbitrary text strings, and the data + stored in such a column can be used for mathematical computations. + By contrast, a column declared to be of a character string type + will accept almost any kind of data but it does not lend itself to + mathematical calculations, although other operations such as string + concatenation are available. +

PostgreSQL includes a sizable set of + built-in data types that fit many applications. Users can also + define their own data types. Most built-in data types have obvious + names and semantics, so we defer a detailed explanation to Chapter 8. Some of the frequently used data types are + integer for whole numbers, numeric for + possibly fractional numbers, text for character + strings, date for dates, time for + time-of-day values, and timestamp for values + containing both date and time. +

To create a table, you use the aptly named CREATE TABLE command. + In this command you specify at least a name for the new table, the + names of the columns and the data type of each column. For + example: +

CREATE TABLE my_first_table (
+    first_column text,
+    second_column integer
+);

+ This creates a table named my_first_table with + two columns. The first column is named + first_column and has a data type of + text; the second column has the name + second_column and the type integer. + The table and column names follow the identifier syntax explained + in Section 4.1.1. The type names are + usually also identifiers, but there are some exceptions. Note that the + column list is comma-separated and surrounded by parentheses. +

Of course, the previous example was heavily contrived. Normally, + you would give names to your tables and columns that convey what + kind of data they store. So let's look at a more realistic + example: +

CREATE TABLE products (
+    product_no integer,
+    name text,
+    price numeric
+);

+ (The numeric type can store fractional components, as + would be typical of monetary amounts.) +

Tip: When you create many interrelated tables it is wise to choose a + consistent naming pattern for the tables and columns. For + instance, there is a choice of using singular or plural nouns for + table names, both of which are favored by some theorist or other. +

There is a limit on how many columns a table can contain. + Depending on the column types, it is between 250 and 1600. + However, defining a table with anywhere near this many columns is + highly unusual and often a questionable design. +

If you no longer need a table, you can remove it using the DROP TABLE command. + For example: +

DROP TABLE my_first_table;
+DROP TABLE products;

+ Attempting to drop a table that does not exist is an error. + Nevertheless, it is common in SQL script files to unconditionally + try to drop each table before creating it, ignoring any error + messages, so that the script works whether or not the table exists. + (If you like, you can use the DROP TABLE IF EXISTS variant + to avoid the error messages, but this is not standard SQL.) +

If you need to modify a table that already exists, see Section 5.5 later in this chapter. +

With the tools discussed so far you can create fully functional + tables. The remainder of this chapter is concerned with adding + features to the table definition to ensure data integrity, + security, or convenience. If you are eager to fill your tables with + data now you can skip ahead to Chapter 6 and read the + rest of this chapter later. +


PrevHomeNext
Data DefinitionUpDefault Values
\ No newline at end of file diff --git a/doc/src/sgml/html/ddl-constraints.html b/doc/src/sgml/html/ddl-constraints.html new file mode 100644 index 000000000..ec0cd19f6 --- /dev/null +++ b/doc/src/sgml/html/ddl-constraints.html @@ -0,0 +1,924 @@ + +Constraints

5.3. Constraints

Data types are a way to limit the kind of data that can be stored + in a table. For many applications, however, the constraint they + provide is too coarse. For example, a column containing a product + price should probably only accept positive values. But there is no + standard data type that accepts only positive numbers. Another issue is + that you might want to constrain column data with respect to other + columns or rows. For example, in a table containing product + information, there should be only one row for each product number. +

To that end, SQL allows you to define constraints on columns and + tables. Constraints give you as much control over the data in your + tables as you wish. If a user attempts to store data in a column + that would violate a constraint, an error is raised. This applies + even if the value came from the default value definition. +

5.3.1. Check Constraints

A check constraint is the most generic constraint type. It allows + you to specify that the value in a certain column must satisfy a + Boolean (truth-value) expression. For instance, to require positive + product prices, you could use: +

CREATE TABLE products (
+    product_no integer,
+    name text,
+    price numeric CHECK (price > 0)
+);

+

As you see, the constraint definition comes after the data type, + just like default value definitions. Default values and + constraints can be listed in any order. A check constraint + consists of the key word CHECK followed by an + expression in parentheses. The check constraint expression should + involve the column thus constrained, otherwise the constraint + would not make too much sense. +

You can also give the constraint a separate name. This clarifies + error messages and allows you to refer to the constraint when you + need to change it. The syntax is: +

CREATE TABLE products (
+    product_no integer,
+    name text,
+    price numeric CONSTRAINT positive_price CHECK (price > 0)
+);

+ So, to specify a named constraint, use the key word + CONSTRAINT followed by an identifier followed + by the constraint definition. (If you don't specify a constraint + name in this way, the system chooses a name for you.) +

A check constraint can also refer to several columns. Say you + store a regular price and a discounted price, and you want to + ensure that the discounted price is lower than the regular price: +

CREATE TABLE products (
+    product_no integer,
+    name text,
+    price numeric CHECK (price > 0),
+    discounted_price numeric CHECK (discounted_price > 0),
+    CHECK (price > discounted_price)
+);

+

The first two constraints should look familiar. The third one + uses a new syntax. It is not attached to a particular column, + instead it appears as a separate item in the comma-separated + column list. Column definitions and these constraint + definitions can be listed in mixed order. +

We say that the first two constraints are column constraints, whereas the + third one is a table constraint because it is written separately + from any one column definition. Column constraints can also be + written as table constraints, while the reverse is not necessarily + possible, since a column constraint is supposed to refer to only the + column it is attached to. (PostgreSQL doesn't + enforce that rule, but you should follow it if you want your table + definitions to work with other database systems.) The above example could + also be written as: +

CREATE TABLE products (
+    product_no integer,
+    name text,
+    price numeric,
+    CHECK (price > 0),
+    discounted_price numeric,
+    CHECK (discounted_price > 0),
+    CHECK (price > discounted_price)
+);

+ or even: +

CREATE TABLE products (
+    product_no integer,
+    name text,
+    price numeric CHECK (price > 0),
+    discounted_price numeric,
+    CHECK (discounted_price > 0 AND price > discounted_price)
+);

+ It's a matter of taste. +

Names can be assigned to table constraints in the same way as + column constraints: +

CREATE TABLE products (
+    product_no integer,
+    name text,
+    price numeric,
+    CHECK (price > 0),
+    discounted_price numeric,
+    CHECK (discounted_price > 0),
+    CONSTRAINT valid_discount CHECK (price > discounted_price)
+);

+

It should be noted that a check constraint is satisfied if the + check expression evaluates to true or the null value. Since most + expressions will evaluate to the null value if any operand is null, + they will not prevent null values in the constrained columns. To + ensure that a column does not contain null values, the not-null + constraint described in the next section can be used. +

5.3.2. Not-Null Constraints

A not-null constraint simply specifies that a column must not + assume the null value. A syntax example: +

CREATE TABLE products (
+    product_no integer NOT NULL,
+    name text NOT NULL,
+    price numeric
+);

+

A not-null constraint is always written as a column constraint. A + not-null constraint is functionally equivalent to creating a check + constraint CHECK (column_name + IS NOT NULL), but in + PostgreSQL creating an explicit + not-null constraint is more efficient. The drawback is that you + cannot give explicit names to not-null constraints created this + way. +

Of course, a column can have more than one constraint. Just write + the constraints one after another: +

CREATE TABLE products (
+    product_no integer NOT NULL,
+    name text NOT NULL,
+    price numeric NOT NULL CHECK (price > 0)
+);

+ The order doesn't matter. It does not necessarily determine in which + order the constraints are checked. +

The NOT NULL constraint has an inverse: the + NULL constraint. This does not mean that the + column must be null, which would surely be useless. Instead, this + simply selects the default behavior that the column might be null. + The NULL constraint is not present in the SQL + standard and should not be used in portable applications. (It was + only added to PostgreSQL to be + compatible with some other database systems.) Some users, however, + like it because it makes it easy to toggle the constraint in a + script file. For example, you could start with: +

CREATE TABLE products (
+    product_no integer NULL,
+    name text NULL,
+    price numeric NULL
+);

+ and then insert the NOT key word where desired. +

Tip: In most database designs the majority of columns should be marked + not null. +

5.3.3. Unique Constraints

Unique constraints ensure that the data contained in a column or a + group of columns is unique with respect to all the rows in the + table. The syntax is: +

CREATE TABLE products (
+    product_no integer UNIQUE,
+    name text,
+    price numeric
+);

+ when written as a column constraint, and: +

CREATE TABLE products (
+    product_no integer,
+    name text,
+    price numeric,
+    UNIQUE (product_no)
+);

+ when written as a table constraint. +

If a unique constraint refers to a group of columns, the columns + are listed separated by commas: +

CREATE TABLE example (
+    a integer,
+    b integer,
+    c integer,
+    UNIQUE (a, c)
+);

+ This specifies that the combination of values in the indicated columns + is unique across the whole table, though any one of the columns + need not be (and ordinarily isn't) unique. +

You can assign your own name for a unique constraint, in the usual way: +

CREATE TABLE products (
+    product_no integer CONSTRAINT must_be_different UNIQUE,
+    name text,
+    price numeric
+);

+

Adding a unique constraint will automatically create a unique btree + index on the column or group of columns used in the constraint. +

In general, a unique constraint is violated when there is more than + one row in the table where the values of all of the + columns included in the constraint are equal. + However, two null values are not considered equal in this + comparison. That means even in the presence of a + unique constraint it is possible to store duplicate + rows that contain a null value in at least one of the constrained + columns. This behavior conforms to the SQL standard, but we have + heard that other SQL databases might not follow this rule. So be + careful when developing applications that are intended to be + portable. +

5.3.4. Primary Keys

Technically, a primary key constraint is simply a combination of a + unique constraint and a not-null constraint. So, the following + two table definitions accept the same data: +

CREATE TABLE products (
+    product_no integer UNIQUE NOT NULL,
+    name text,
+    price numeric
+);

+ +

CREATE TABLE products (
+    product_no integer PRIMARY KEY,
+    name text,
+    price numeric
+);

+

Primary keys can also constrain more than one column; the syntax + is similar to unique constraints: +

CREATE TABLE example (
+    a integer,
+    b integer,
+    c integer,
+    PRIMARY KEY (a, c)
+);

+

A primary key indicates that a column or group of columns can be + used as a unique identifier for rows in the table. (This is a + direct consequence of the definition of a primary key. Note that + a unique constraint does not, by itself, provide a unique identifier + because it does not exclude null values.) This is useful both for + documentation purposes and for client applications. For example, + a GUI application that allows modifying row values probably needs + to know the primary key of a table to be able to identify rows + uniquely. +

Adding a primary key will automatically create a unique btree index + on the column or group of columns used in the primary key. +

A table can have at most one primary key. (There can be any number + of unique and not-null constraints, which are functionally the same + thing, but only one can be identified as the primary key.) + Relational database theory + dictates that every table must have a primary key. This rule is + not enforced by PostgreSQL, but it is + usually best to follow it. +

5.3.5. Foreign Keys

A foreign key constraint specifies that the values in a column (or + a group of columns) must match the values appearing in some row + of another table. + We say this maintains the referential + integrity between two related tables. +

Say you have the product table that we have used several times already: +

CREATE TABLE products (
+    product_no integer PRIMARY KEY,
+    name text,
+    price numeric
+);

+ Let's also assume you have a table storing orders of those + products. We want to ensure that the orders table only contains + orders of products that actually exist. So we define a foreign + key constraint in the orders table that references the products + table: +

CREATE TABLE orders (
+    order_id integer PRIMARY KEY,
+    product_no integer REFERENCES products (product_no),
+    quantity integer
+);

+ Now it is impossible to create orders with non-NULL + product_no entries that do not appear in the + products table. +

We say that in this situation the orders table is the + referencing table and the products table is + the referenced table. Similarly, there are + referencing and referenced columns. +

You can also shorten the above command to: +

CREATE TABLE orders (
+    order_id integer PRIMARY KEY,
+    product_no integer REFERENCES products,
+    quantity integer
+);

+ because in absence of a column list the primary key of the + referenced table is used as the referenced column(s). +

A foreign key can also constrain and reference a group of columns. + As usual, it then needs to be written in table constraint form. + Here is a contrived syntax example: +

CREATE TABLE t1 (
+  a integer PRIMARY KEY,
+  b integer,
+  c integer,
+  FOREIGN KEY (b, c) REFERENCES other_table (c1, c2)
+);

+ Of course, the number and type of the constrained columns need to + match the number and type of the referenced columns. +

You can assign your own name for a foreign key constraint, + in the usual way. +

A table can contain more than one foreign key constraint. This is + used to implement many-to-many relationships between tables. Say + you have tables about products and orders, but now you want to + allow one order to contain possibly many products (which the + structure above did not allow). You could use this table structure: +

CREATE TABLE products (
+    product_no integer PRIMARY KEY,
+    name text,
+    price numeric
+);
+
+CREATE TABLE orders (
+    order_id integer PRIMARY KEY,
+    shipping_address text,
+    ...
+);
+
+CREATE TABLE order_items (
+    product_no integer REFERENCES products,
+    order_id integer REFERENCES orders,
+    quantity integer,
+    PRIMARY KEY (product_no, order_id)
+);

+ Notice that the primary key overlaps with the foreign keys in + the last table. +

We know that the foreign keys disallow creation of orders that + do not relate to any products. But what if a product is removed + after an order is created that references it? SQL allows you to + handle that as well. Intuitively, we have a few options: +

  • Disallow deleting a referenced product

  • Delete the orders as well

  • Something else?

+

To illustrate this, let's implement the following policy on the + many-to-many relationship example above: when someone wants to + remove a product that is still referenced by an order (via + order_items), we disallow it. If someone + removes an order, the order items are removed as well: +

CREATE TABLE products (
+    product_no integer PRIMARY KEY,
+    name text,
+    price numeric
+);
+
+CREATE TABLE orders (
+    order_id integer PRIMARY KEY,
+    shipping_address text,
+    ...
+);
+
+CREATE TABLE order_items (
+    product_no integer REFERENCES products ON DELETE RESTRICT,
+    order_id integer REFERENCES orders ON DELETE CASCADE,
+    quantity integer,
+    PRIMARY KEY (product_no, order_id)
+);

+

Restricting and cascading deletes are the two most common options. + RESTRICT prevents deletion of a + referenced row. NO ACTION means that if any + referencing rows still exist when the constraint is checked, an error + is raised; this is the default behavior if you do not specify anything. + (The essential difference between these two choices is that + NO ACTION allows the check to be deferred until + later in the transaction, whereas RESTRICT does not.) + CASCADE specifies that when a referenced row is deleted, + row(s) referencing it should be automatically deleted as well. + There are two other options: + SET NULL and SET DEFAULT. + These cause the referencing columns to be set to nulls or default + values, respectively, when the referenced row is deleted. + Note that these do not excuse you from observing any constraints. + For example, if an action specifies SET DEFAULT + but the default value would not satisfy the foreign key, the + operation will fail. +

Analogous to ON DELETE there is also + ON UPDATE which is invoked when a referenced + column is changed (updated). The possible actions are the same. +

Since a DELETE of a row from the referenced table + or an UPDATE of a referenced column will require + a scan of the referencing table for rows matching the old value, it + is often a good idea to index the referencing columns. Because this + is not always needed, and there are many choices available on how + to index, declaration of a foreign key constraint does not + automatically create an index on the referencing columns. +

More information about updating and deleting data is in Chapter 6. +

Finally, we should mention that a foreign key must reference + columns that either are a primary key or form a unique constraint. + If the foreign key references a unique constraint, there are some + additional possibilities regarding how null values are matched. + These are explained in the reference documentation for + CREATE TABLE. +

5.3.6. Exclusion Constraints

Exclusion constraints ensure that if any two rows are compared on + the specified columns or expressions using the specified operators, + at least one of these operator comparisons will return false or null. + The syntax is: +

CREATE TABLE circles (
+    c circle,
+    EXCLUDE USING gist (c WITH &&)
+);

+

See also CREATE + TABLE ... CONSTRAINT ... EXCLUDE for details. +

Adding an exclusion constraint will automatically create an index + of the type specified in the constraint declaration. +


PrevHomeNext
Default ValuesUpSystem Columns
\ No newline at end of file diff --git a/doc/src/sgml/html/ddl-default.html b/doc/src/sgml/html/ddl-default.html new file mode 100644 index 000000000..4280ccbfc --- /dev/null +++ b/doc/src/sgml/html/ddl-default.html @@ -0,0 +1,262 @@ + +Default Values

5.2. Default Values

A column can be assigned a default value. When a new row is + created and no values are specified for some of the columns, those + columns will be filled with their respective default values. A + data manipulation command can also request explicitly that a column + be set to its default value, without having to know what that value is. + (Details about data manipulation commands are in Chapter 6.) +

+ If no default value is declared explicitly, the default value is the + null value. This usually makes sense because a null value can + be considered to represent unknown data. +

In a table definition, default values are listed after the column + data type. For example: +

CREATE TABLE products (
+    product_no integer,
+    name text,
+    price numeric DEFAULT 9.99
+);

+

The default value can be an expression, which will be + evaluated whenever the default value is inserted + (not when the table is created). A common example + is for a timestamp column to have a default of CURRENT_TIMESTAMP, + so that it gets set to the time of row insertion. Another common + example is generating a "serial number" for each row. + In PostgreSQL this is typically done by + something like: +

CREATE TABLE products (
+    product_no integer DEFAULT nextval('products_product_no_seq'),
+    ...
+);

+ where the nextval() function supplies successive values + from a sequence object (see Section 9.16). This arrangement is sufficiently common + that there's a special shorthand for it: +

CREATE TABLE products (
+    product_no SERIAL,
+    ...
+);

+ The SERIAL shorthand is discussed further in Section 8.1.4. +


PrevHomeNext
Table BasicsUpConstraints
\ No newline at end of file diff --git a/doc/src/sgml/html/ddl-depend.html b/doc/src/sgml/html/ddl-depend.html new file mode 100644 index 000000000..c2700b586 --- /dev/null +++ b/doc/src/sgml/html/ddl-depend.html @@ -0,0 +1,284 @@ + +Dependency Tracking

5.12. Dependency Tracking

When you create complex database structures involving many tables + with foreign key constraints, views, triggers, functions, etc. you + implicitly create a net of dependencies between the objects. + For instance, a table with a foreign key constraint depends on the + table it references. +

To ensure the integrity of the entire database structure, + PostgreSQL makes sure that you cannot + drop objects that other objects still depend on. For example, + attempting to drop the products table we had considered in Section 5.3.5, with the orders table depending on + it, would result in an error message such as this: +

DROP TABLE products;
+
+NOTICE:  constraint orders_product_no_fkey on table orders depends on table products
+ERROR:  cannot drop table products because other objects depend on it
+HINT:  Use DROP ... CASCADE to drop the dependent objects too.

+ The error message contains a useful hint: if you do not want to + bother deleting all the dependent objects individually, you can run: +

DROP TABLE products CASCADE;

+ and all the dependent objects will be removed. In this case, it + doesn't remove the orders table, it only removes the foreign key + constraint. (If you want to check what DROP ... CASCADE will do, + run DROP without CASCADE and read the NOTICE messages.) +

All drop commands in PostgreSQL support + specifying CASCADE. Of course, the nature of + the possible dependencies varies with the type of the object. You + can also write RESTRICT instead of + CASCADE to get the default behavior, which is to + prevent the dropping of objects that other objects depend on. +

Note: According to the SQL standard, specifying either + RESTRICT or CASCADE is + required. No database system actually enforces that rule, but + whether the default behavior is RESTRICT or + CASCADE varies across systems. +

Note: Foreign key constraint dependencies and serial column dependencies + from PostgreSQL versions prior to 7.3 + are not maintained or created during the + upgrade process. All other dependency types will be properly + created during an upgrade from a pre-7.3 database. +


PrevHomeNext
Other Database ObjectsUpData Manipulation
\ No newline at end of file diff --git a/doc/src/sgml/html/ddl-foreign-data.html b/doc/src/sgml/html/ddl-foreign-data.html new file mode 100644 index 000000000..c17e9d1c8 --- /dev/null +++ b/doc/src/sgml/html/ddl-foreign-data.html @@ -0,0 +1,232 @@ + +Foreign Data

5.10. Foreign Data

PostgreSQL implements portions of the SQL/MED + specification, allowing you to access data that resides outside + PostgreSQL using regular SQL queries. Such data is referred to as + foreign data. (Note that this usage is not to be confused + with foreign keys, which are a type of constraint within the database.) +

Foreign data is accessed with help from a + foreign data wrapper. A foreign data wrapper is a + library that can communicate with an external data source, hiding the + details of connecting to the data source and fetching data from it. There + is a foreign data wrapper available as a contrib module, + which can read plain data files residing on the server. Other kind of + foreign data wrappers might be found as third party products. If none of + the existing foreign data wrappers suit your needs, you can write your + own; see Chapter 50. +

To access foreign data, you need to create a foreign server + object, which defines how to connect to a particular external data source, + according to the set of options used by a particular foreign data + wrapper. Then you need to create one or more foreign + tables, which define the structure of the remote data. A + foreign table can be used in queries just like a normal table, but a + foreign table has no storage in the PostgreSQL server. Whenever it is + used, PostgreSQL asks the foreign data wrapper + to fetch the data from the external source. +

Accessing remote data may require authentication at the external + data source. This information can be provided by a + user mapping, which can provide additional options based + on the current PostgreSQL role. +

Currently, foreign tables are read-only. This limitation may be fixed + in a future release. +


PrevHomeNext
PartitioningUpOther Database Objects
\ No newline at end of file diff --git a/doc/src/sgml/html/ddl-inherit.html b/doc/src/sgml/html/ddl-inherit.html new file mode 100644 index 000000000..d4bfdbd1b --- /dev/null +++ b/doc/src/sgml/html/ddl-inherit.html @@ -0,0 +1,705 @@ + +Inheritance

5.8. Inheritance

PostgreSQL implements table inheritance, + which can be a useful tool for database designers. (SQL:1999 and + later define a type inheritance feature, which differs in many + respects from the features described here.) +

Let's start with an example: suppose we are trying to build a data + model for cities. Each state has many cities, but only one + capital. We want to be able to quickly retrieve the capital city + for any particular state. This can be done by creating two tables, + one for state capitals and one for cities that are not + capitals. However, what happens when we want to ask for data about + a city, regardless of whether it is a capital or not? The + inheritance feature can help to resolve this problem. We define the + capitals table so that it inherits from + cities: + +

CREATE TABLE cities (
+    name            text,
+    population      float,
+    altitude        int     -- in feet
+);
+
+CREATE TABLE capitals (
+    state           char(2)
+) INHERITS (cities);

+ + In this case, the capitals table inherits + all the columns of its parent table, cities. State + capitals also have an extra column, state, that shows + their state. +

In PostgreSQL, a table can inherit from + zero or more other tables, and a query can reference either all + rows of a table or all rows of a table plus all of its descendant tables. + The latter behavior is the default. + For example, the following query finds the names of all cities, + including state capitals, that are located at an altitude over + 500 feet: + +

SELECT name, altitude
+    FROM cities
+    WHERE altitude > 500;

+ + Given the sample data from the PostgreSQL + tutorial (see Section 2.1), this returns: + +

   name    | altitude
+-----------+----------
+ Las Vegas |     2174
+ Mariposa  |     1953
+ Madison   |      845

+

On the other hand, the following query finds all the cities that + are not state capitals and are situated at an altitude over 500 feet: + +

SELECT name, altitude
+    FROM ONLY cities
+    WHERE altitude > 500;
+
+   name    | altitude
+-----------+----------
+ Las Vegas |     2174
+ Mariposa  |     1953

+

Here the ONLY keyword indicates that the query + should apply only to cities, and not any tables + below cities in the inheritance hierarchy. Many + of the commands that we have already discussed — + SELECT, UPDATE and + DELETE — support the + ONLY keyword. +

You can also write the table name with a trailing * + to explicitly specify that descendant tables are included: + +

SELECT name, altitude
+    FROM cities*
+    WHERE altitude > 500;

+ + Writing * is not necessary, since this behavior is + the default (unless you have changed the setting of the + sql_inheritance configuration option). + However writing * might be useful to emphasize that + additional tables will be searched. +

In some cases you might wish to know which table a particular row + originated from. There is a system column called + tableoid in each table which can tell you the + originating table: + +

SELECT c.tableoid, c.name, c.altitude
+FROM cities c
+WHERE c.altitude > 500;

+ + which returns: + +

 tableoid |   name    | altitude
+----------+-----------+----------
+   139793 | Las Vegas |     2174
+   139793 | Mariposa  |     1953
+   139798 | Madison   |      845

+ + (If you try to reproduce this example, you will probably get + different numeric OIDs.) By doing a join with + pg_class you can see the actual table names: + +

SELECT p.relname, c.name, c.altitude
+FROM cities c, pg_class p
+WHERE c.altitude > 500 AND c.tableoid = p.oid;

+ + which returns: + +

 relname  |   name    | altitude
+----------+-----------+----------
+ cities   | Las Vegas |     2174
+ cities   | Mariposa  |     1953
+ capitals | Madison   |      845

+

Inheritance does not automatically propagate data from + INSERT or COPY commands to + other tables in the inheritance hierarchy. In our example, the + following INSERT statement will fail: +

INSERT INTO cities (name, population, altitude, state)
+VALUES ('New York', NULL, NULL, 'NY');

+ We might hope that the data would somehow be routed to the + capitals table, but this does not happen: + INSERT always inserts into exactly the table + specified. In some cases it is possible to redirect the insertion + using a rule (see Chapter 37). However that does not + help for the above case because the cities table + does not contain the column state, and so the + command will be rejected before the rule can be applied. +

All check constraints and not-null constraints on a parent table are + automatically inherited by its children. Other types of constraints + (unique, primary key, and foreign key constraints) are not inherited. +

A table can inherit from more than one parent table, in which case it has + the union of the columns defined by the parent tables. Any columns + declared in the child table's definition are added to these. If the + same column name appears in multiple parent tables, or in both a parent + table and the child's definition, then these columns are "merged" + so that there is only one such column in the child table. To be merged, + columns must have the same data types, else an error is raised. The + merged column will have copies of all the check constraints coming from + any one of the column definitions it came from, and will be marked not-null + if any of them are. +

Table inheritance is typically established when the child table is + created, using the INHERITS clause of the + CREATE TABLE + statement. + Alternatively, a table which is already defined in a compatible way can + have a new parent relationship added, using the INHERIT + variant of ALTER TABLE. + To do this the new child table must already include columns with + the same names and types as the columns of the parent. It must also include + check constraints with the same names and check expressions as those of the + parent. Similarly an inheritance link can be removed from a child using the + NO INHERIT variant of ALTER TABLE. + Dynamically adding and removing inheritance links like this can be useful + when the inheritance relationship is being used for table + partitioning (see Section 5.9). +

One convenient way to create a compatible table that will later be made + a new child is to use the LIKE clause in CREATE + TABLE. This creates a new table with the same columns as + the source table. If there are any CHECK + constraints defined on the source table, the INCLUDING + CONSTRAINTS option to LIKE should be + specified, as the new child must have constraints matching the parent + to be considered compatible. +

A parent table cannot be dropped while any of its children remain. Neither + can columns or check constraints of child tables be dropped or altered + if they are inherited + from any parent tables. If you wish to remove a table and all of its + descendants, one easy way is to drop the parent table with the + CASCADE option. +

ALTER TABLE will + propagate any changes in column data definitions and check + constraints down the inheritance hierarchy. Again, dropping + columns that are depended on by other tables is only possible when using + the CASCADE option. ALTER + TABLE follows the same rules for duplicate column merging + and rejection that apply during CREATE TABLE. +

Note how table access permissions are handled. Querying a parent + table can automatically access data in child tables without further + access privilege checking. This preserves the appearance that the + data is (also) in the parent table. Accessing the child tables + directly is, however, not automatically allowed and would require + further privileges to be granted. +

5.8.1. Caveats

Note that not all SQL commands are able to work on + inheritance hierarchies. Commands that are used for data querying, + data modification, or schema modification + (e.g., SELECT, UPDATE, DELETE, + most variants of ALTER TABLE, but + not INSERT or ALTER TABLE ... + RENAME) typically default to including child tables and + support the ONLY notation to exclude them. + Commands that do database maintenance and tuning + (e.g., REINDEX, VACUUM) + typically only work on individual, physical tables and do not + support recursing over inheritance hierarchies. The respective + behavior of each individual command is documented in its reference + page (Reference I, SQL Commands). +

A serious limitation of the inheritance feature is that indexes (including + unique constraints) and foreign key constraints only apply to single + tables, not to their inheritance children. This is true on both the + referencing and referenced sides of a foreign key constraint. Thus, + in the terms of the above example: + +

  • If we declared cities.name to be + UNIQUE or a PRIMARY KEY, this would not stop the + capitals table from having rows with names duplicating + rows in cities. And those duplicate rows would by + default show up in queries from cities. In fact, by + default capitals would have no unique constraint at all, + and so could contain multiple rows with the same name. + You could add a unique constraint to capitals, but this + would not prevent duplication compared to cities. +

  • Similarly, if we were to specify that + cities.name REFERENCES some + other table, this constraint would not automatically propagate to + capitals. In this case you could work around it by + manually adding the same REFERENCES constraint to + capitals. +

  • Specifying that another table's column REFERENCES + cities(name) would allow the other table to contain city names, but + not capital names. There is no good workaround for this case. +

+ + These deficiencies will probably be fixed in some future release, + but in the meantime considerable care is needed in deciding whether + inheritance is useful for your application. +


PrevHomeNext
SchemasUpPartitioning
\ No newline at end of file diff --git a/doc/src/sgml/html/ddl-others.html b/doc/src/sgml/html/ddl-others.html new file mode 100644 index 000000000..71e771bfc --- /dev/null +++ b/doc/src/sgml/html/ddl-others.html @@ -0,0 +1,202 @@ + +Other Database Objects

5.11. Other Database Objects

Tables are the central objects in a relational database structure, + because they hold your data. But they are not the only objects + that exist in a database. Many other kinds of objects can be + created to make the use and management of the data more efficient + or convenient. They are not discussed in this chapter, but we give + you a list here so that you are aware of what is possible: +

  • Views +

  • Functions and operators +

  • Data types and domains +

  • Triggers and rewrite rules +

Detailed information on + these topics appears in Part V. +


PrevHomeNext
Foreign DataUpDependency Tracking
\ No newline at end of file diff --git a/doc/src/sgml/html/ddl-partitioning.html b/doc/src/sgml/html/ddl-partitioning.html new file mode 100644 index 000000000..2b90afd61 --- /dev/null +++ b/doc/src/sgml/html/ddl-partitioning.html @@ -0,0 +1,1021 @@ + +Partitioning

5.9. Partitioning

PostgreSQL supports basic table + partitioning. This section describes why and how to implement + partitioning as part of your database design. +

5.9.1. Overview

Partitioning refers to splitting what is logically one large table + into smaller physical pieces. + Partitioning can provide several benefits: +

  • Query performance can be improved dramatically in certain situations, + particularly when most of the heavily accessed rows of the table are in a + single partition or a small number of partitions. The partitioning + substitutes for leading columns of indexes, reducing index size and + making it more likely that the heavily-used parts of the indexes + fit in memory. +

  • When queries or updates access a large percentage of a single + partition, performance can be improved by taking advantage + of sequential scan of that partition instead of using an + index and random access reads scattered across the whole table. +

  • Bulk loads and deletes can be accomplished by adding or removing + partitions, if that requirement is planned into the partitioning design. + ALTER TABLE NO INHERIT and DROP TABLE are + both far faster than a bulk operation. + These commands also entirely avoid the VACUUM + overhead caused by a bulk DELETE. +

  • Seldom-used data can be migrated to cheaper and slower storage media. +

+ + The benefits will normally be worthwhile only when a table would + otherwise be very large. The exact point at which a table will + benefit from partitioning depends on the application, although a + rule of thumb is that the size of the table should exceed the physical + memory of the database server. +

Currently, PostgreSQL supports partitioning + via table inheritance. Each partition must be created as a child + table of a single parent table. The parent table itself is normally + empty; it exists just to represent the entire data set. You should be + familiar with inheritance (see Section 5.8) before + attempting to set up partitioning. +

The following forms of partitioning can be implemented in + PostgreSQL: + +

Range Partitioning

The table is partitioned into "ranges" defined + by a key column or set of columns, with no overlap between + the ranges of values assigned to different partitions. For + example one might partition by date ranges, or by ranges of + identifiers for particular business objects. +

List Partitioning

The table is partitioned by explicitly listing which key values + appear in each partition. +

+

5.9.2. Implementing Partitioning

To set up a partitioned table, do the following: +

  1. Create the "master" table, from which all of the + partitions will inherit. +

    This table will contain no data. Do not define any check + constraints on this table, unless you intend them to + be applied equally to all partitions. There is no point + in defining any indexes or unique constraints on it, either. +

  2. Create several "child" tables that each inherit from + the master table. Normally, these tables will not add any columns + to the set inherited from the master. +

    We will refer to the child tables as partitions, though they + are in every way normal PostgreSQL tables. +

  3. Add table constraints to the partition tables to define the + allowed key values in each partition. +

    Typical examples would be: +

    CHECK ( x = 1 )
    +CHECK ( county IN ( 'Oxfordshire', 'Buckinghamshire', 'Warwickshire' ))
    +CHECK ( outletID >= 100 AND outletID < 200 )

    + Ensure that the constraints guarantee that there is no overlap + between the key values permitted in different partitions. A common + mistake is to set up range constraints like: +

    CHECK ( outletID BETWEEN 100 AND 200 )
    +CHECK ( outletID BETWEEN 200 AND 300 )

    + This is wrong since it is not clear which partition the key value + 200 belongs in. +

    Note that there is no difference in + syntax between range and list partitioning; those terms are + descriptive only. +

  4. For each partition, create an index on the key column(s), + as well as any other indexes you might want. (The key index is + not strictly necessary, but in most scenarios it is helpful. + If you intend the key values to be unique then you should + always create a unique or primary-key constraint for each + partition.) +

  5. Optionally, define a trigger or rule to redirect data inserted into + the master table to the appropriate partition. +

  6. Ensure that the constraint_exclusion + configuration parameter is not disabled in + postgresql.conf. + If it is, queries will not be optimized as desired. +

+

For example, suppose we are constructing a database for a large + ice cream company. The company measures peak temperatures every + day as well as ice cream sales in each region. Conceptually, + we want a table like: + +

CREATE TABLE measurement (
+    city_id         int not null,
+    logdate         date not null,
+    peaktemp        int,
+    unitsales       int
+);

+ + We know that most queries will access just the last week's, month's or + quarter's data, since the main use of this table will be to prepare + online reports for management. + To reduce the amount of old data that needs to be stored, we + decide to only keep the most recent 3 years worth of data. At the + beginning of each month we will remove the oldest month's data. +

In this situation we can use partitioning to help us meet all of our + different requirements for the measurements table. Following the + steps outlined above, partitioning can be set up as follows: +

  1. The master table is the measurement table, declared + exactly as above. +

  2. Next we create one partition for each active month: + +

    CREATE TABLE measurement_y2006m02 ( ) INHERITS (measurement);
    +CREATE TABLE measurement_y2006m03 ( ) INHERITS (measurement);
    +...
    +CREATE TABLE measurement_y2007m11 ( ) INHERITS (measurement);
    +CREATE TABLE measurement_y2007m12 ( ) INHERITS (measurement);
    +CREATE TABLE measurement_y2008m01 ( ) INHERITS (measurement);

    + + Each of the partitions are complete tables in their own right, + but they inherit their definitions from the + measurement table. +

    This solves one of our problems: deleting old data. Each + month, all we will need to do is perform a DROP + TABLE on the oldest child table and create a new + child table for the new month's data. +

  3. We must provide non-overlapping table constraints. Rather than + just creating the partition tables as above, the table creation + script should really be: + +

    CREATE TABLE measurement_y2006m02 (
    +    CHECK ( logdate >= DATE '2006-02-01' AND logdate < DATE '2006-03-01' )
    +) INHERITS (measurement);
    +CREATE TABLE measurement_y2006m03 (
    +    CHECK ( logdate >= DATE '2006-03-01' AND logdate < DATE '2006-04-01' )
    +) INHERITS (measurement);
    +...
    +CREATE TABLE measurement_y2007m11 (
    +    CHECK ( logdate >= DATE '2007-11-01' AND logdate < DATE '2007-12-01' )
    +) INHERITS (measurement);
    +CREATE TABLE measurement_y2007m12 (
    +    CHECK ( logdate >= DATE '2007-12-01' AND logdate < DATE '2008-01-01' )
    +) INHERITS (measurement);
    +CREATE TABLE measurement_y2008m01 (
    +    CHECK ( logdate >= DATE '2008-01-01' AND logdate < DATE '2008-02-01' )
    +) INHERITS (measurement);

    +

  4. We probably need indexes on the key columns too: + +

    CREATE INDEX measurement_y2006m02_logdate ON measurement_y2006m02 (logdate);
    +CREATE INDEX measurement_y2006m03_logdate ON measurement_y2006m03 (logdate);
    +...
    +CREATE INDEX measurement_y2007m11_logdate ON measurement_y2007m11 (logdate);
    +CREATE INDEX measurement_y2007m12_logdate ON measurement_y2007m12 (logdate);
    +CREATE INDEX measurement_y2008m01_logdate ON measurement_y2008m01 (logdate);

    + + We choose not to add further indexes at this time. +

  5. We want our application to be able to say INSERT INTO + measurement ... and have the data be redirected into the + appropriate partition table. We can arrange that by attaching + a suitable trigger function to the master table. + If data will be added only to the latest partition, we can + use a very simple trigger function: + +

    CREATE OR REPLACE FUNCTION measurement_insert_trigger()
    +RETURNS TRIGGER AS $$
    +BEGIN
    +    INSERT INTO measurement_y2008m01 VALUES (NEW.*);
    +    RETURN NULL;
    +END;
    +$$
    +LANGUAGE plpgsql;

    + + After creating the function, we create a trigger which + calls the trigger function: + +

    CREATE TRIGGER insert_measurement_trigger
    +    BEFORE INSERT ON measurement
    +    FOR EACH ROW EXECUTE PROCEDURE measurement_insert_trigger();

    + + We must redefine the trigger function each month so that it always + points to the current partition. The trigger definition does + not need to be updated, however. +

    We might want to insert data and have the server automatically + locate the partition into which the row should be added. We + could do this with a more complex trigger function, for example: + +

    CREATE OR REPLACE FUNCTION measurement_insert_trigger()
    +RETURNS TRIGGER AS $$
    +BEGIN
    +    IF ( NEW.logdate >= DATE '2006-02-01' AND
    +         NEW.logdate < DATE '2006-03-01' ) THEN
    +        INSERT INTO measurement_y2006m02 VALUES (NEW.*);
    +    ELSIF ( NEW.logdate >= DATE '2006-03-01' AND
    +            NEW.logdate < DATE '2006-04-01' ) THEN
    +        INSERT INTO measurement_y2006m03 VALUES (NEW.*);
    +    ...
    +    ELSIF ( NEW.logdate >= DATE '2008-01-01' AND
    +            NEW.logdate < DATE '2008-02-01' ) THEN
    +        INSERT INTO measurement_y2008m01 VALUES (NEW.*);
    +    ELSE
    +        RAISE EXCEPTION 'Date out of range.  Fix the measurement_insert_trigger() function!';
    +    END IF;
    +    RETURN NULL;
    +END;
    +$$
    +LANGUAGE plpgsql;

    + + The trigger definition is the same as before. + Note that each IF test must exactly match the + CHECK constraint for its partition. +

    While this function is more complex than the single-month case, + it doesn't need to be updated as often, since branches can be + added in advance of being needed. +

    Note: In practice it might be best to check the newest partition first, + if most inserts go into that partition. For simplicity we have + shown the trigger's tests in the same order as in other parts + of this example. +

+

As we can see, a complex partitioning scheme could require a + substantial amount of DDL. In the above example we would be + creating a new partition each month, so it might be wise to write a + script that generates the required DDL automatically. +

5.9.3. Managing Partitions

Normally the set of partitions established when initially + defining the table are not intended to remain static. It is + common to want to remove old partitions of data and periodically + add new partitions for new data. One of the most important + advantages of partitioning is precisely that it allows this + otherwise painful task to be executed nearly instantaneously by + manipulating the partition structure, rather than physically moving large + amounts of data around. +

The simplest option for removing old data is simply to drop the partition + that is no longer necessary: +

DROP TABLE measurement_y2006m02;

+ This can very quickly delete millions of records because it doesn't have + to individually delete every record. +

Another option that is often preferable is to remove the partition from + the partitioned table but retain access to it as a table in its own + right: +

ALTER TABLE measurement_y2006m02 NO INHERIT measurement;

+ This allows further operations to be performed on the data before + it is dropped. For example, this is often a useful time to back up + the data using COPY, pg_dump, or + similar tools. It might also be a useful time to aggregate data + into smaller formats, perform other data manipulations, or run + reports. +

Similarly we can add a new partition to handle new data. We can create an + empty partition in the partitioned table just as the original partitions + were created above: + +

CREATE TABLE measurement_y2008m02 (
+    CHECK ( logdate >= DATE '2008-02-01' AND logdate < DATE '2008-03-01' )
+) INHERITS (measurement);

+ + As an alternative, it is sometimes more convenient to create the + new table outside the partition structure, and make it a proper + partition later. This allows the data to be loaded, checked, and + transformed prior to it appearing in the partitioned table: + +

CREATE TABLE measurement_y2008m02
+  (LIKE measurement INCLUDING DEFAULTS INCLUDING CONSTRAINTS);
+ALTER TABLE measurement_y2008m02 ADD CONSTRAINT y2008m02
+   CHECK ( logdate >= DATE '2008-02-01' AND logdate < DATE '2008-03-01' );
+\copy measurement_y2008m02 from 'measurement_y2008m02'
+-- possibly some other data preparation work
+ALTER TABLE measurement_y2008m02 INHERIT measurement;

+

5.9.4. Partitioning and Constraint Exclusion

Constraint exclusion is a query optimization technique + that improves performance for partitioned tables defined in the + fashion described above. As an example: + +

SET constraint_exclusion = on;
+SELECT count(*) FROM measurement WHERE logdate >= DATE '2008-01-01';

+ + Without constraint exclusion, the above query would scan each of + the partitions of the measurement table. With constraint + exclusion enabled, the planner will examine the constraints of each + partition and try to prove that the partition need not + be scanned because it could not contain any rows meeting the query's + WHERE clause. When the planner can prove this, it + excludes the partition from the query plan. +

You can use the EXPLAIN command to show the difference + between a plan with constraint_exclusion on and a plan + with it off. A typical unoptimized plan for this type of table setup is: + +

SET constraint_exclusion = off;
+EXPLAIN SELECT count(*) FROM measurement WHERE logdate >= DATE '2008-01-01';
+
+                                          QUERY PLAN
+-----------------------------------------------------------------------------------------------
+ Aggregate  (cost=158.66..158.68 rows=1 width=0)
+   ->  Append  (cost=0.00..151.88 rows=2715 width=0)
+         ->  Seq Scan on measurement  (cost=0.00..30.38 rows=543 width=0)
+               Filter: (logdate >= '2008-01-01'::date)
+         ->  Seq Scan on measurement_y2006m02 measurement  (cost=0.00..30.38 rows=543 width=0)
+               Filter: (logdate >= '2008-01-01'::date)
+         ->  Seq Scan on measurement_y2006m03 measurement  (cost=0.00..30.38 rows=543 width=0)
+               Filter: (logdate >= '2008-01-01'::date)
+...
+         ->  Seq Scan on measurement_y2007m12 measurement  (cost=0.00..30.38 rows=543 width=0)
+               Filter: (logdate >= '2008-01-01'::date)
+         ->  Seq Scan on measurement_y2008m01 measurement  (cost=0.00..30.38 rows=543 width=0)
+               Filter: (logdate >= '2008-01-01'::date)

+ + Some or all of the partitions might use index scans instead of + full-table sequential scans, but the point here is that there + is no need to scan the older partitions at all to answer this query. + When we enable constraint exclusion, we get a significantly + cheaper plan that will deliver the same answer: + +

SET constraint_exclusion = on;
+EXPLAIN SELECT count(*) FROM measurement WHERE logdate >= DATE '2008-01-01';
+                                          QUERY PLAN
+-----------------------------------------------------------------------------------------------
+ Aggregate  (cost=63.47..63.48 rows=1 width=0)
+   ->  Append  (cost=0.00..60.75 rows=1086 width=0)
+         ->  Seq Scan on measurement  (cost=0.00..30.38 rows=543 width=0)
+               Filter: (logdate >= '2008-01-01'::date)
+         ->  Seq Scan on measurement_y2008m01 measurement  (cost=0.00..30.38 rows=543 width=0)
+               Filter: (logdate >= '2008-01-01'::date)

+

Note that constraint exclusion is driven only by CHECK + constraints, not by the presence of indexes. Therefore it isn't + necessary to define indexes on the key columns. Whether an index + needs to be created for a given partition depends on whether you + expect that queries that scan the partition will generally scan + a large part of the partition or just a small part. An index will + be helpful in the latter case but not the former. +

The default (and recommended) setting of + constraint_exclusion is actually neither + on nor off, but an intermediate setting + called partition, which causes the technique to be + applied only to queries that are likely to be working on partitioned + tables. The on setting causes the planner to examine + CHECK constraints in all queries, even simple ones that + are unlikely to benefit. +

5.9.5. Alternative Partitioning Methods

A different approach to redirecting inserts into the appropriate + partition table is to set up rules, instead of a trigger, on the + master table. For example: + +

CREATE RULE measurement_insert_y2006m02 AS
+ON INSERT TO measurement WHERE
+    ( logdate >= DATE '2006-02-01' AND logdate < DATE '2006-03-01' )
+DO INSTEAD
+    INSERT INTO measurement_y2006m02 VALUES (NEW.*);
+...
+CREATE RULE measurement_insert_y2008m01 AS
+ON INSERT TO measurement WHERE
+    ( logdate >= DATE '2008-01-01' AND logdate < DATE '2008-02-01' )
+DO INSTEAD
+    INSERT INTO measurement_y2008m01 VALUES (NEW.*);

+ + A rule has significantly more overhead than a trigger, but the overhead + is paid once per query rather than once per row, so this method might be + advantageous for bulk-insert situations. In most cases, however, the + trigger method will offer better performance. +

Be aware that COPY ignores rules. If you want to + use COPY to insert data, you'll need to copy into the correct + partition table rather than into the master. COPY does fire + triggers, so you can use it normally if you use the trigger approach. +

Another disadvantage of the rule approach is that there is no simple + way to force an error if the set of rules doesn't cover the insertion + date; the data will silently go into the master table instead. +

Partitioning can also be arranged using a UNION ALL + view, instead of table inheritance. For example, + +

CREATE VIEW measurement AS
+          SELECT * FROM measurement_y2006m02
+UNION ALL SELECT * FROM measurement_y2006m03
+...
+UNION ALL SELECT * FROM measurement_y2007m11
+UNION ALL SELECT * FROM measurement_y2007m12
+UNION ALL SELECT * FROM measurement_y2008m01;

+ + However, the need to recreate the view adds an extra step to adding and + dropping individual partitions of the data set. In practice this + method has little to recommend it compared to using inheritance. +

5.9.6. Caveats

The following caveats apply to partitioned tables: +

  • There is no automatic way to verify that all of the + CHECK constraints are mutually + exclusive. It is safer to create code that generates + partitions and creates and/or modifies associated objects than + to write each by hand. +

  • The schemes shown here assume that the partition key column(s) + of a row never change, or at least do not change enough to require + it to move to another partition. An UPDATE that attempts + to do that will fail because of the CHECK constraints. + If you need to handle such cases, you can put suitable update triggers + on the partition tables, but it makes management of the structure + much more complicated. +

  • If you are using manual VACUUM or + ANALYZE commands, don't forget that + you need to run them on each partition individually. A command like: +

    ANALYZE measurement;

    + will only process the master table. +

+

The following caveats apply to constraint exclusion: + +

  • Constraint exclusion only works when the query's WHERE + clause contains constants (or externally supplied parameters). + For example, a comparison against a non-immutable function such as + CURRENT_TIMESTAMP cannot be optimized, since the + planner cannot know which partition the function value might fall + into at run time. +

  • Keep the partitioning constraints simple, else the planner may not be + able to prove that partitions don't need to be visited. Use simple + equality conditions for list partitioning, or simple + range tests for range partitioning, as illustrated in the preceding + examples. A good rule of thumb is that partitioning constraints should + contain only comparisons of the partitioning column(s) to constants + using B-tree-indexable operators. +

  • All constraints on all partitions of the master table are examined + during constraint exclusion, so large numbers of partitions are likely + to increase query planning time considerably. Partitioning using + these techniques will work well with up to perhaps a hundred partitions; + don't try to use many thousands of partitions. +

+


PrevHomeNext
InheritanceUpForeign Data
\ No newline at end of file diff --git a/doc/src/sgml/html/ddl-priv.html b/doc/src/sgml/html/ddl-priv.html new file mode 100644 index 000000000..c17e650c7 --- /dev/null +++ b/doc/src/sgml/html/ddl-priv.html @@ -0,0 +1,335 @@ + +Privileges

5.6. Privileges

When an object is created, it is assigned an owner. The + owner is normally the role that executed the creation statement. + For most kinds of objects, the initial state is that only the owner + (or a superuser) can do anything with the object. To allow + other roles to use it, privileges must be + granted. +

There are different kinds of privileges: SELECT, + INSERT, UPDATE, DELETE, + TRUNCATE, REFERENCES, TRIGGER, + CREATE, CONNECT, TEMPORARY, + EXECUTE, and USAGE. + The privileges applicable to a particular + object vary depending on the object's type (table, function, etc). + For complete information on the different types of privileges + supported by PostgreSQL, refer to the + GRANT reference + page. The following sections and chapters will also show you how + those privileges are used. +

The right to modify or destroy an object is always the privilege of + the owner only. +

An object can be assigned to a new owner with an ALTER + command of the appropriate kind for the object, e.g. ALTER TABLE. Superusers can always do + this; ordinary roles can only do it if they are both the current owner + of the object (or a member of the owning role) and a member of the new + owning role. +

To assign privileges, the GRANT command is + used. For example, if joe is an existing user, and + accounts is an existing table, the privilege to + update the table can be granted with: +

GRANT UPDATE ON accounts TO joe;

+ Writing ALL in place of a specific privilege grants all + privileges that are relevant for the object type. +

The special "user" name PUBLIC can + be used to grant a privilege to every user on the system. Also, + "group" roles can be set up to help manage privileges when + there are many users of a database — for details see + Chapter 20. +

To revoke a privilege, use the fittingly named + REVOKE command: +

REVOKE ALL ON accounts FROM PUBLIC;

+ The special privileges of the object owner (i.e., the right to do + DROP, GRANT, REVOKE, etc.) + are always implicit in being the owner, + and cannot be granted or revoked. But the object owner can choose + to revoke his own ordinary privileges, for example to make a + table read-only for himself as well as others. +

Ordinarily, only the object's owner (or a superuser) can grant or + revoke privileges on an object. However, it is possible to grant a + privilege "with grant option", which gives the recipient + the right to grant it in turn to others. If the grant option is + subsequently revoked then all who received the privilege from that + recipient (directly or through a chain of grants) will lose the + privilege. For details see the GRANT and + REVOKE reference pages. +


PrevHomeNext
Modifying TablesUpSchemas
\ No newline at end of file diff --git a/doc/src/sgml/html/ddl-schemas.html b/doc/src/sgml/html/ddl-schemas.html new file mode 100644 index 000000000..aef01946b --- /dev/null +++ b/doc/src/sgml/html/ddl-schemas.html @@ -0,0 +1,801 @@ + +Schemas

5.7. Schemas

A PostgreSQL database cluster + contains one or more named databases. Users and groups of users are + shared across the entire cluster, but no other data is shared across + databases. Any given client connection to the server can access + only the data in a single database, the one specified in the connection + request. +

Note: Users of a cluster do not necessarily have the privilege to access every + database in the cluster. Sharing of user names means that there + cannot be different users named, say, joe in two databases + in the same cluster; but the system can be configured to allow + joe access to only some of the databases. +

A database contains one or more named schemas, which + in turn contain tables. Schemas also contain other kinds of named + objects, including data types, functions, and operators. The same + object name can be used in different schemas without conflict; for + example, both schema1 and myschema can + contain tables named mytable. Unlike databases, + schemas are not rigidly separated: a user can access objects in any + of the schemas in the database he is connected to, if he has + privileges to do so. +

There are several reasons why one might want to use schemas: + +

  • To allow many users to use one database without interfering with + each other. +

  • To organize database objects into logical groups to make them + more manageable. +

  • Third-party applications can be put into separate schemas so + they do not collide with the names of other objects. +

+ + Schemas are analogous to directories at the operating system level, + except that schemas cannot be nested. +

5.7.1. Creating a Schema

To create a schema, use the CREATE SCHEMA + command. Give the schema a name + of your choice. For example: +

CREATE SCHEMA myschema;

+

To create or access objects in a schema, write a + qualified name consisting of the schema name and + table name separated by a dot: +

schema.table

+ This works anywhere a table name is expected, including the table + modification commands and the data access commands discussed in + the following chapters. + (For brevity we will speak of tables only, but the same ideas apply + to other kinds of named objects, such as types and functions.) +

Actually, the even more general syntax +

database.schema.table

+ can be used too, but at present this is just for pro + forma compliance with the SQL standard. If you write a database name, + it must be the same as the database you are connected to. +

So to create a table in the new schema, use: +

CREATE TABLE myschema.mytable (
+ ...
+);

+

To drop a schema if it's empty (all objects in it have been + dropped), use: +

DROP SCHEMA myschema;

+ To drop a schema including all contained objects, use: +

DROP SCHEMA myschema CASCADE;

+ See Section 5.12 for a description of the general + mechanism behind this. +

Often you will want to create a schema owned by someone else + (since this is one of the ways to restrict the activities of your + users to well-defined namespaces). The syntax for that is: +

CREATE SCHEMA schemaname AUTHORIZATION username;

+ You can even omit the schema name, in which case the schema name + will be the same as the user name. See Section 5.7.6 for how this can be useful. +

Schema names beginning with pg_ are reserved for + system purposes and cannot be created by users. +

5.7.2. The Public Schema

In the previous sections we created tables without specifying any + schema names. By default such tables (and other objects) are + automatically put into a schema named "public". Every new + database contains such a schema. Thus, the following are equivalent: +

CREATE TABLE products ( ... );

+ and: +

CREATE TABLE public.products ( ... );

+

5.7.3. The Schema Search Path

Qualified names are tedious to write, and it's often best not to + wire a particular schema name into applications anyway. Therefore + tables are often referred to by unqualified names, + which consist of just the table name. The system determines which table + is meant by following a search path, which is a list + of schemas to look in. The first matching table in the search path + is taken to be the one wanted. If there is no match in the search + path, an error is reported, even if matching table names exist + in other schemas in the database. +

The first schema named in the search path is called the current schema. + Aside from being the first schema searched, it is also the schema in + which new tables will be created if the CREATE TABLE + command does not specify a schema name. +

To show the current search path, use the following command: +

SHOW search_path;

+ In the default setup this returns: +

 search_path
+--------------
+ "$user",public

+ The first element specifies that a schema with the same name as + the current user is to be searched. If no such schema exists, + the entry is ignored. The second element refers to the + public schema that we have seen already. +

The first schema in the search path that exists is the default + location for creating new objects. That is the reason that by + default objects are created in the public schema. When objects + are referenced in any other context without schema qualification + (table modification, data modification, or query commands) the + search path is traversed until a matching object is found. + Therefore, in the default configuration, any unqualified access + again can only refer to the public schema. +

To put our new schema in the path, we use: +

SET search_path TO myschema,public;

+ (We omit the $user here because we have no + immediate need for it.) And then we can access the table without + schema qualification: +

DROP TABLE mytable;

+ Also, since myschema is the first element in + the path, new objects would by default be created in it. +

We could also have written: +

SET search_path TO myschema;

+ Then we no longer have access to the public schema without + explicit qualification. There is nothing special about the public + schema except that it exists by default. It can be dropped, too. +

See also Section 9.25 for other ways to manipulate + the schema search path. +

The search path works in the same way for data type names, function names, + and operator names as it does for table names. Data type and function + names can be qualified in exactly the same way as table names. If you + need to write a qualified operator name in an expression, there is a + special provision: you must write +

OPERATOR(schema.operator)

+ This is needed to avoid syntactic ambiguity. An example is: +

SELECT 3 OPERATOR(pg_catalog.+) 4;

+ In practice one usually relies on the search path for operators, + so as not to have to write anything so ugly as that. +

5.7.4. Schemas and Privileges

By default, users cannot access any objects in schemas they do not + own. To allow that, the owner of the schema must grant the + USAGE privilege on the schema. To allow users + to make use of the objects in the schema, additional privileges + might need to be granted, as appropriate for the object. +

A user can also be allowed to create objects in someone else's + schema. To allow that, the CREATE privilege on + the schema needs to be granted. Note that by default, everyone + has CREATE and USAGE privileges on + the schema + public. This allows all users that are able to + connect to a given database to create objects in its + public schema. If you do + not want to allow that, you can revoke that privilege: +

REVOKE CREATE ON SCHEMA public FROM PUBLIC;

+ (The first "public" is the schema, the second + "public" means "every user". In the + first sense it is an identifier, in the second sense it is a + key word, hence the different capitalization; recall the + guidelines from Section 4.1.1.) +

5.7.5. The System Catalog Schema

In addition to public and user-created schemas, each + database contains a pg_catalog schema, which contains + the system tables and all the built-in data types, functions, and + operators. pg_catalog is always effectively part of + the search path. If it is not named explicitly in the path then + it is implicitly searched before searching the path's + schemas. This ensures that built-in names will always be + findable. However, you can explicitly place + pg_catalog at the end of your search path if you + prefer to have user-defined names override built-in names. +

In PostgreSQL versions before 7.3, + table names beginning with pg_ were reserved. This is + no longer true: you can create such a table name if you wish, in + any non-system schema. However, it's best to continue to avoid + such names, to ensure that you won't suffer a conflict if some + future version defines a system table named the same as your + table. (With the default search path, an unqualified reference to + your table name would then be resolved as the system table instead.) + System tables will continue to follow the convention of having + names beginning with pg_, so that they will not + conflict with unqualified user-table names so long as users avoid + the pg_ prefix. +

5.7.6. Usage Patterns

Schemas can be used to organize your data in many ways. There are + a few usage patterns that are recommended and are easily supported by + the default configuration: +

  • If you do not create any schemas then all users access the + public schema implicitly. This simulates the situation where + schemas are not available at all. This setup is mainly + recommended when there is only a single user or a few cooperating + users in a database. This setup also allows smooth transition + from the non-schema-aware world. +

  • You can create a schema for each user with the same name as + that user. Recall that the default search path starts with + $user, which resolves to the user name. + Therefore, if each user has a separate schema, they access their + own schemas by default. +

    If you use this setup then you might also want to revoke access + to the public schema (or drop it altogether), so users are + truly constrained to their own schemas. +

  • To install shared applications (tables to be used by everyone, + additional functions provided by third parties, etc.), put them + into separate schemas. Remember to grant appropriate + privileges to allow the other users to access them. Users can + then refer to these additional objects by qualifying the names + with a schema name, or they can put the additional schemas into + their search path, as they choose. +

+

5.7.7. Portability

In the SQL standard, the notion of objects in the same schema + being owned by different users does not exist. Moreover, some + implementations do not allow you to create schemas that have a + different name than their owner. In fact, the concepts of schema + and user are nearly equivalent in a database system that + implements only the basic schema support specified in the + standard. Therefore, many users consider qualified names to + really consist of + username.tablename. + This is how PostgreSQL will effectively + behave if you create a per-user schema for every user. +

Also, there is no concept of a public schema in the + SQL standard. For maximum conformance to the standard, you should + not use (perhaps even remove) the public schema. +

Of course, some SQL database systems might not implement schemas + at all, or provide namespace support by allowing (possibly + limited) cross-database access. If you need to work with those + systems, then maximum portability would be achieved by not using + schemas at all. +


PrevHomeNext
PrivilegesUpInheritance
\ No newline at end of file diff --git a/doc/src/sgml/html/ddl-system-columns.html b/doc/src/sgml/html/ddl-system-columns.html new file mode 100644 index 000000000..2491bda77 --- /dev/null +++ b/doc/src/sgml/html/ddl-system-columns.html @@ -0,0 +1,402 @@ + +System Columns

5.4. System Columns

Every table has several system columns that are + implicitly defined by the system. Therefore, these names cannot be + used as names of user-defined columns. (Note that these + restrictions are separate from whether the name is a key word or + not; quoting a name will not allow you to escape these + restrictions.) You do not really need to be concerned about these + columns; just know they exist. +

oid

+ The object identifier (object ID) of a row. This column is only + present if the table was created using WITH + OIDS, or if the default_with_oids + configuration variable was set at the time. This column is of type + oid (same name as the column); see Section 8.18 for more information about the type. +

tableoid

The OID of the table containing this row. This column is + particularly handy for queries that select from inheritance + hierarchies (see Section 5.8), since without it, + it's difficult to tell which individual table a row came from. The + tableoid can be joined against the + oid column of + pg_class to obtain the table name. +

xmin

The identity (transaction ID) of the inserting transaction for + this row version. (A row version is an individual state of a + row; each update of a row creates a new row version for the same + logical row.) +

cmin

The command identifier (starting at zero) within the inserting + transaction. +

xmax

The identity (transaction ID) of the deleting transaction, or + zero for an undeleted row version. It is possible for this column to + be nonzero in a visible row version. That usually indicates that the + deleting transaction hasn't committed yet, or that an attempted + deletion was rolled back. +

cmax

The command identifier within the deleting transaction, or zero. +

ctid

The physical location of the row version within its table. Note that + although the ctid can be used to + locate the row version very quickly, a row's + ctid will change if it is + updated or moved by VACUUM FULL. Therefore + ctid is useless as a long-term row + identifier. The OID, or even better a user-defined serial + number, should be used to identify logical rows. +

OIDs are 32-bit quantities and are assigned from a single + cluster-wide counter. In a large or long-lived database, it is + possible for the counter to wrap around. Hence, it is bad + practice to assume that OIDs are unique, unless you take steps to + ensure that this is the case. If you need to identify the rows in + a table, using a sequence generator is strongly recommended. + However, OIDs can be used as well, provided that a few additional + precautions are taken: + +

  • A unique constraint should be created on the OID column of each + table for which the OID will be used to identify rows. When such + a unique constraint (or unique index) exists, the system takes + care not to generate an OID matching an already-existing row. + (Of course, this is only possible if the table contains fewer + than 232 (4 billion) rows, and in practice the + table size had better be much less than that, or performance + might suffer.) +

  • OIDs should never be assumed to be unique across tables; use + the combination of tableoid and row OID if you + need a database-wide identifier. +

  • Of course, the tables in question must be created WITH + OIDS. As of PostgreSQL 8.1, + WITHOUT OIDS is the default. +

+

Transaction identifiers are also 32-bit quantities. In a + long-lived database it is possible for transaction IDs to wrap + around. This is not a fatal problem given appropriate maintenance + procedures; see Chapter 23 for details. It is + unwise, however, to depend on the uniqueness of transaction IDs + over the long term (more than one billion transactions). +

Command identifiers are also 32-bit quantities. This creates a hard limit + of 232 (4 billion) SQL commands + within a single transaction. In practice this limit is not a + problem — note that the limit is on the number of + SQL commands, not the number of rows processed. + Also, as of PostgreSQL 8.3, only commands + that actually modify the database contents will consume a command + identifier. +


PrevHomeNext
ConstraintsUpModifying Tables
\ No newline at end of file diff --git a/doc/src/sgml/html/ddl.html b/doc/src/sgml/html/ddl.html new file mode 100644 index 000000000..342c46649 --- /dev/null +++ b/doc/src/sgml/html/ddl.html @@ -0,0 +1,393 @@ + +Data Definition

Chapter 5. Data Definition

Table of Contents
5.1. Table Basics
5.2. Default Values
5.3. Constraints
5.3.1. Check Constraints
5.3.2. Not-Null Constraints
5.3.3. Unique Constraints
5.3.4. Primary Keys
5.3.5. Foreign Keys
5.3.6. Exclusion Constraints
5.4. System Columns
5.5. Modifying Tables
5.5.1. Adding a Column
5.5.2. Removing a Column
5.5.3. Adding a Constraint
5.5.4. Removing a Constraint
5.5.5. Changing a Column's Default Value
5.5.6. Changing a Column's Data Type
5.5.7. Renaming a Column
5.5.8. Renaming a Table
5.6. Privileges
5.7. Schemas
5.7.1. Creating a Schema
5.7.2. The Public Schema
5.7.3. The Schema Search Path
5.7.4. Schemas and Privileges
5.7.5. The System Catalog Schema
5.7.6. Usage Patterns
5.7.7. Portability
5.8. Inheritance
5.9. Partitioning
5.9.1. Overview
5.9.2. Implementing Partitioning
5.9.3. Managing Partitions
5.9.4. Partitioning and Constraint Exclusion
5.9.5. Alternative Partitioning Methods
5.9.6. Caveats
5.10. Foreign Data
5.11. Other Database Objects
5.12. Dependency Tracking

This chapter covers how one creates the database structures that + will hold one's data. In a relational database, the raw data is + stored in tables, so the majority of this chapter is devoted to + explaining how tables are created and modified and what features are + available to control what data is stored in the tables. + Subsequently, we discuss how tables can be organized into + schemas, and how privileges can be assigned to tables. Finally, + we will briefly look at other features that affect the data storage, + such as inheritance, views, functions, and triggers. +


PrevHomeNext
Calling FunctionsUpTable Basics
\ No newline at end of file diff --git a/doc/src/sgml/html/dict-int.html b/doc/src/sgml/html/dict-int.html new file mode 100644 index 000000000..3067e624a --- /dev/null +++ b/doc/src/sgml/html/dict-int.html @@ -0,0 +1,284 @@ + +dict_int
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.10. dict_int

dict_int is an example of an add-on dictionary template + for full-text search. The motivation for this example dictionary is to + control the indexing of integers (signed and unsigned), allowing such + numbers to be indexed while preventing excessive growth in the number of + unique words, which greatly affects the performance of searching. +

F.10.1. Configuration

The dictionary accepts two options: +

  • The maxlen parameter specifies the maximum number of + digits allowed in an integer word. The default value is 6. +

  • The rejectlong parameter specifies whether an overlength + integer should be truncated or ignored. If rejectlong is + false (the default), the dictionary returns the first + maxlen digits of the integer. If rejectlong is + true, the dictionary treats an overlength integer as a stop + word, so that it will not be indexed. Note that this also means that + such an integer cannot be searched for. +

F.10.2. Usage

Installing the dict_int extension creates a text search + template intdict_template and a dictionary intdict + based on it, with the default parameters. You can alter the + parameters, for example + +

mydb# ALTER TEXT SEARCH DICTIONARY intdict (MAXLEN = 4, REJECTLONG = true);
+ALTER TEXT SEARCH DICTIONARY

+ + or create new dictionaries based on the template. +

To test the dictionary, you can try + +

mydb# select ts_lexize('intdict', '12345678');
+ ts_lexize
+-----------
+ {123456}

+ + but real-world usage will involve including it in a text search + configuration as described in Chapter 12. + That might look like this: + +

ALTER TEXT SEARCH CONFIGURATION english
+    ALTER MAPPING FOR int, uint WITH intdict;

+ +


PrevHomeNext
dblink_build_sql_updateUpdict_xsyn
\ No newline at end of file diff --git a/doc/src/sgml/html/dict-xsyn.html b/doc/src/sgml/html/dict-xsyn.html new file mode 100644 index 000000000..b43bce451 --- /dev/null +++ b/doc/src/sgml/html/dict-xsyn.html @@ -0,0 +1,384 @@ + +dict_xsyn
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.11. dict_xsyn

dict_xsyn (Extended Synonym Dictionary) is an example of an + add-on dictionary template for full-text search. This dictionary type + replaces words with groups of their synonyms, and so makes it possible to + search for a word using any of its synonyms. +

F.11.1. Configuration

A dict_xsyn dictionary accepts the following options: +

  • matchorig controls whether the original word is accepted by + the dictionary. Default is true. +

  • matchsynonyms controls whether the synonyms are + accepted by the dictionary. Default is false. +

  • keeporig controls whether the original word is included in + the dictionary's output. Default is true. +

  • keepsynonyms controls whether the synonyms are included in + the dictionary's output. Default is true. +

  • rules is the base name of the file containing the list of + synonyms. This file must be stored in + $SHAREDIR/tsearch_data/ (where $SHAREDIR means + the PostgreSQL installation's shared-data directory). + Its name must end in .rules (which is not to be included in + the rules parameter). +

The rules file has the following format: +

  • Each line represents a group of synonyms for a single word, which is + given first on the line. Synonyms are separated by whitespace, thus: +

    word syn1 syn2 syn3

    +

  • The sharp (#) sign is a comment delimiter. It may appear at + any position in a line. The rest of the line will be skipped. +

Look at xsyn_sample.rules, which is installed in + $SHAREDIR/tsearch_data/, for an example. +

F.11.2. Usage

Installing the dict_xsyn extension creates a text search + template xsyn_template and a dictionary xsyn + based on it, with default parameters. You can alter the + parameters, for example + +

mydb# ALTER TEXT SEARCH DICTIONARY xsyn (RULES='my_rules', KEEPORIG=false);
+ALTER TEXT SEARCH DICTIONARY

+ + or create new dictionaries based on the template. +

To test the dictionary, you can try + +

mydb=# SELECT ts_lexize('xsyn', 'word');
+      ts_lexize
+-----------------------
+ {syn1,syn2,syn3}
+
+mydb# ALTER TEXT SEARCH DICTIONARY xsyn (RULES='my_rules', KEEPORIG=true);
+ALTER TEXT SEARCH DICTIONARY
+
+mydb=# SELECT ts_lexize('xsyn', 'word');
+      ts_lexize
+-----------------------
+ {word,syn1,syn2,syn3}
+
+mydb# ALTER TEXT SEARCH DICTIONARY xsyn (RULES='my_rules', KEEPORIG=false, MATCHSYNONYMS=true);
+ALTER TEXT SEARCH DICTIONARY
+
+mydb=# SELECT ts_lexize('xsyn', 'syn1');
+      ts_lexize
+-----------------------
+ {syn1,syn2,syn3}
+
+mydb# ALTER TEXT SEARCH DICTIONARY xsyn (RULES='my_rules', KEEPORIG=true, MATCHORIG=false, KEEPSYNONYMS=false);
+ALTER TEXT SEARCH DICTIONARY
+
+mydb=# SELECT ts_lexize('xsyn', 'syn1');
+      ts_lexize
+-----------------------
+ {word}

+ + Real-world usage will involve including it in a text search + configuration as described in Chapter 12. + That might look like this: + +

ALTER TEXT SEARCH CONFIGURATION english
+    ALTER MAPPING FOR word, asciiword WITH xsyn, english_stem;

+ +


PrevHomeNext
dict_intUpdummy_seclabel
\ No newline at end of file diff --git a/doc/src/sgml/html/different-replication-solutions.html b/doc/src/sgml/html/different-replication-solutions.html new file mode 100644 index 000000000..96703aa02 --- /dev/null +++ b/doc/src/sgml/html/different-replication-solutions.html @@ -0,0 +1,718 @@ + +Comparison of Different Solutions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 25. High Availability, Load Balancing, and ReplicationNext

25.1. Comparison of Different Solutions

Shared Disk Failover

Shared disk failover avoids synchronization overhead by having only one + copy of the database. It uses a single disk array that is shared by + multiple servers. If the main database server fails, the standby server + is able to mount and start the database as though it were recovering from + a database crash. This allows rapid failover with no data loss. +

Shared hardware functionality is common in network storage devices. + Using a network file system is also possible, though care must be + taken that the file system has full POSIX behavior (see Section 17.2.1). One significant limitation of this + method is that if the shared disk array fails or becomes corrupt, the + primary and standby servers are both nonfunctional. Another issue is + that the standby server should never access the shared storage while + the primary server is running. +

File System (Block-Device) Replication

A modified version of shared hardware functionality is file system + replication, where all changes to a file system are mirrored to a file + system residing on another computer. The only restriction is that + the mirroring must be done in a way that ensures the standby server + has a consistent copy of the file system — specifically, writes + to the standby must be done in the same order as those on the master. + DRBD is a popular file system replication solution + for Linux. +

Transaction Log Shipping

Warm and hot standby servers can be kept current by reading a + stream of write-ahead log (WAL) + records. If the main server fails, the standby contains + almost all of the data of the main server, and can be quickly + made the new master database server. This can be synchronous or + asynchronous and can only be done for the entire database server. +

A standby server can be implemented using file-based log shipping + (Section 25.2) or streaming replication (see + Section 25.2.5), or a combination of both. For + information on hot standby, see Section 25.5. +

Trigger-Based Master-Standby Replication

A master-standby replication setup sends all data modification + queries to the master server. The master server asynchronously + sends data changes to the standby server. The standby can answer + read-only queries while the master server is running. The + standby server is ideal for data warehouse queries. +

Slony-I is an example of this type of replication, with per-table + granularity, and support for multiple standby servers. Because it + updates the standby server asynchronously (in batches), there is + possible data loss during fail over. +

Statement-Based Replication Middleware

With statement-based replication middleware, a program intercepts + every SQL query and sends it to one or all servers. Each server + operates independently. Read-write queries must be sent to all servers, + so that every server receives any changes. But read-only queries can be + sent to just one server, allowing the read workload to be distributed + among them. +

If queries are simply broadcast unmodified, functions like + random(), CURRENT_TIMESTAMP, and + sequences can have different values on different servers. + This is because each server operates independently, and because + SQL queries are broadcast (and not actual modified rows). If + this is unacceptable, either the middleware or the application + must query such values from a single server and then use those + values in write queries. Another option is to use this replication + option with a traditional master-standby setup, i.e. data modification + queries are sent only to the master and are propagated to the + standby servers via master-standby replication, not by the replication + middleware. Care must also be taken that all + transactions either commit or abort on all servers, perhaps + using two-phase commit (PREPARE TRANSACTION + and COMMIT PREPARED. + Pgpool-II and Continuent Tungsten + are examples of this type of replication. +

Asynchronous Multimaster Replication

For servers that are not regularly connected, like laptops or + remote servers, keeping data consistent among servers is a + challenge. Using asynchronous multimaster replication, each + server works independently, and periodically communicates with + the other servers to identify conflicting transactions. The + conflicts can be resolved by users or conflict resolution rules. + Bucardo is an example of this type of replication. +

Synchronous Multimaster Replication

In synchronous multimaster replication, each server can accept + write requests, and modified data is transmitted from the + original server to every other server before each transaction + commits. Heavy write activity can cause excessive locking, + leading to poor performance. In fact, write performance is + often worse than that of a single server. Read requests can + be sent to any server. Some implementations use shared disk + to reduce the communication overhead. Synchronous multimaster + replication is best for mostly read workloads, though its big + advantage is that any server can accept write requests — + there is no need to partition workloads between master and + standby servers, and because the data changes are sent from one + server to another, there is no problem with non-deterministic + functions like random(). +

PostgreSQL does not offer this type of replication, + though PostgreSQL two-phase commit (PREPARE TRANSACTION and COMMIT PREPARED) + can be used to implement this in application code or middleware. +

Commercial Solutions

Because PostgreSQL is open source and easily + extended, a number of companies have taken PostgreSQL + and created commercial closed-source solutions with unique + failover, replication, and load balancing capabilities. +

Table 25-1 summarizes + the capabilities of the various solutions listed above. +

Table 25-1. High Availability, Load Balancing, and Replication Feature Matrix

FeatureShared Disk FailoverFile System ReplicationTransaction Log ShippingTrigger-Based Master-Standby ReplicationStatement-Based Replication MiddlewareAsynchronous Multimaster ReplicationSynchronous Multimaster Replication
Most Common ImplementationNASDRBDStreaming Repl.Slonypgpool-IIBucardo 
Communication Methodshared diskdisk blocksWALtable rowsSQLtable rowstable rows and row locks
No special hardware required 
Allows multiple master servers    
No master server overhead    
No waiting for multiple servers with sync off  
Master failure will never lose datawith sync on  
Standby accept read-only queries  with hot
Per-table granularity    
No conflict resolution necessary  

There are a few solutions that do not fit into the above categories: +

Data Partitioning

Data partitioning splits tables into data sets. Each set can + be modified by only one server. For example, data can be + partitioned by offices, e.g., London and Paris, with a server + in each office. If queries combining London and Paris data + are necessary, an application can query both servers, or + master/standby replication can be used to keep a read-only copy + of the other office's data on each server. +

Multiple-Server Parallel Query Execution

Many of the above solutions allow multiple servers to handle multiple + queries, but none allow a single query to use multiple servers to + complete faster. This solution allows multiple servers to work + concurrently on a single query. It is usually accomplished by + splitting the data among servers and having each server execute its + part of the query and return results to a central server where they + are combined and returned to the user. Pgpool-II + has this capability. Also, this can be implemented using the + PL/Proxy tool set. +


PrevHomeNext
High Availability, Load Balancing, and ReplicationUpLog-Shipping Standby Servers
\ No newline at end of file diff --git a/doc/src/sgml/html/disk-full.html b/doc/src/sgml/html/disk-full.html new file mode 100644 index 000000000..5abb536f7 --- /dev/null +++ b/doc/src/sgml/html/disk-full.html @@ -0,0 +1,196 @@ + +Disk Full Failure
PostgreSQL 9.2.2 Documentation
PrevUpChapter 28. Monitoring Disk UsageNext

28.2. Disk Full Failure

The most important disk monitoring task of a database administrator + is to make sure the disk doesn't become full. A filled data disk will + not result in data corruption, but it might prevent useful activity + from occurring. If the disk holding the WAL files grows full, database + server panic and consequent shutdown might occur. +

If you cannot free up additional space on the disk by deleting + other things, you can move some of the database files to other file + systems by making use of tablespaces. See Section 21.6 for more information about that. +

Tip: Some file systems perform badly when they are almost full, so do + not wait until the disk is completely full to take action. +

If your system supports per-user disk quotas, then the database + will naturally be subject to whatever quota is placed on the user + the server runs as. Exceeding the quota will have the same bad + effects as running out of disk space entirely. +


PrevHomeNext
Determining Disk UsageUpReliability and the Write-Ahead Log
\ No newline at end of file diff --git a/doc/src/sgml/html/disk-usage.html b/doc/src/sgml/html/disk-usage.html new file mode 100644 index 000000000..98bdee574 --- /dev/null +++ b/doc/src/sgml/html/disk-usage.html @@ -0,0 +1,289 @@ + +Determining Disk Usage
PostgreSQL 9.2.2 Documentation
PrevUpChapter 28. Monitoring Disk UsageNext

28.1. Determining Disk Usage

Each table has a primary heap disk file where most of the data is + stored. If the table has any columns with potentially-wide values, + there also might be a TOAST file associated with the table, + which is used to store values too wide to fit comfortably in the main + table (see Section 56.2). There will be one index on the + TOAST table, if present. There also might be indexes associated + with the base table. Each table and index is stored in a separate disk + file — possibly more than one file, if the file would exceed one + gigabyte. Naming conventions for these files are described in Section 56.1. +

You can monitor disk space in three ways: + using the SQL functions listed in Table 9-63, + using the oid2name module, or + using manual inspection of the system catalogs. + The SQL functions are the easiest to use and are generally recommended. + The remainder of this section shows how to do it by inspection of the + system catalogs. +

Using psql on a recently vacuumed or analyzed database, + you can issue queries to see the disk usage of any table: +

SELECT pg_relation_filepath(oid), relpages FROM pg_class WHERE relname = 'customer';
+
+ pg_relation_filepath | relpages 
+----------------------+----------
+ base/16384/16806     |       60
+(1 row)

+ Each page is typically 8 kilobytes. (Remember, relpages + is only updated by VACUUM, ANALYZE, and + a few DDL commands such as CREATE INDEX.) The file path name + is of interest if you want to examine the table's disk file directly. +

To show the space used by TOAST tables, use a query + like the following: +

SELECT relname, relpages
+FROM pg_class,
+     (SELECT reltoastrelid
+      FROM pg_class
+      WHERE relname = 'customer') AS ss
+WHERE oid = ss.reltoastrelid OR
+      oid = (SELECT reltoastidxid
+             FROM pg_class
+             WHERE oid = ss.reltoastrelid)
+ORDER BY relname;
+
+       relname        | relpages 
+----------------------+----------
+ pg_toast_16806       |        0
+ pg_toast_16806_index |        1

+

You can easily display index sizes, too: +

SELECT c2.relname, c2.relpages
+FROM pg_class c, pg_class c2, pg_index i
+WHERE c.relname = 'customer' AND
+      c.oid = i.indrelid AND
+      c2.oid = i.indexrelid
+ORDER BY c2.relname;
+
+       relname        | relpages 
+----------------------+----------
+ customer_id_indexdex |       26

+

It is easy to find your largest tables and indexes using this + information: +

SELECT relname, relpages
+FROM pg_class
+ORDER BY relpages DESC;
+
+       relname        | relpages 
+----------------------+----------
+ bigtable             |     3290
+ customer             |     3144

+


PrevHomeNext
Monitoring Disk UsageUpDisk Full Failure
\ No newline at end of file diff --git a/doc/src/sgml/html/diskusage.html b/doc/src/sgml/html/diskusage.html new file mode 100644 index 000000000..02642c7de --- /dev/null +++ b/doc/src/sgml/html/diskusage.html @@ -0,0 +1,188 @@ + +Monitoring Disk Usage

Chapter 28. Monitoring Disk Usage

Table of Contents
28.1. Determining Disk Usage
28.2. Disk Full Failure

This chapter discusses how to monitor the disk usage of a + PostgreSQL database system. +


PrevHomeNext
Dynamic TracingUpDetermining Disk Usage
\ No newline at end of file diff --git a/doc/src/sgml/html/dml-delete.html b/doc/src/sgml/html/dml-delete.html new file mode 100644 index 000000000..a9b3b0670 --- /dev/null +++ b/doc/src/sgml/html/dml-delete.html @@ -0,0 +1,200 @@ + +Deleting Data
PostgreSQL 9.2.2 Documentation
PrevUpChapter 6. Data ManipulationNext

6.3. Deleting Data

So far we have explained how to add data to tables and how to + change data. What remains is to discuss how to remove data that is + no longer needed. Just as adding data is only possible in whole + rows, you can only remove entire rows from a table. In the + previous section we explained that SQL does not provide a way to + directly address individual rows. Therefore, removing rows can + only be done by specifying conditions that the rows to be removed + have to match. If you have a primary key in the table then you can + specify the exact row. But you can also remove groups of rows + matching a condition, or you can remove all rows in the table at + once. +

You use the DELETE + command to remove rows; the syntax is very similar to the + UPDATE command. For instance, to remove all + rows from the products table that have a price of 10, use: +

DELETE FROM products WHERE price = 10;

+

If you simply write: +

DELETE FROM products;

+ then all rows in the table will be deleted! Caveat programmer. +


PrevHomeNext
Updating DataUpQueries
\ No newline at end of file diff --git a/doc/src/sgml/html/dml-insert.html b/doc/src/sgml/html/dml-insert.html new file mode 100644 index 000000000..658581b72 --- /dev/null +++ b/doc/src/sgml/html/dml-insert.html @@ -0,0 +1,272 @@ + +Inserting Data
PostgreSQL 9.2.2 Documentation
PrevUpChapter 6. Data ManipulationNext

6.1. Inserting Data

When a table is created, it contains no data. The first thing to + do before a database can be of much use is to insert data. Data is + conceptually inserted one row at a time. Of course you can also + insert more than one row, but there is no way to insert less than + one row. Even if you know only some column values, a + complete row must be created. +

To create a new row, use the INSERT + command. The command requires the + table name and column values. For + example, consider the products table from Chapter 5: +

CREATE TABLE products (
+    product_no integer,
+    name text,
+    price numeric
+);

+ An example command to insert a row would be: +

INSERT INTO products VALUES (1, 'Cheese', 9.99);

+ The data values are listed in the order in which the columns appear + in the table, separated by commas. Usually, the data values will + be literals (constants), but scalar expressions are also allowed. +

The above syntax has the drawback that you need to know the order + of the columns in the table. To avoid this you can also list the + columns explicitly. For example, both of the following commands + have the same effect as the one above: +

INSERT INTO products (product_no, name, price) VALUES (1, 'Cheese', 9.99);
+INSERT INTO products (name, price, product_no) VALUES ('Cheese', 9.99, 1);

+ Many users consider it good practice to always list the column + names. +

If you don't have values for all the columns, you can omit some of + them. In that case, the columns will be filled with their default + values. For example: +

INSERT INTO products (product_no, name) VALUES (1, 'Cheese');
+INSERT INTO products VALUES (1, 'Cheese');

+ The second form is a PostgreSQL + extension. It fills the columns from the left with as many values + as are given, and the rest will be defaulted. +

For clarity, you can also request default values explicitly, for + individual columns or for the entire row: +

INSERT INTO products (product_no, name, price) VALUES (1, 'Cheese', DEFAULT);
+INSERT INTO products DEFAULT VALUES;

+

You can insert multiple rows in a single command: +

INSERT INTO products (product_no, name, price) VALUES
+    (1, 'Cheese', 9.99),
+    (2, 'Bread', 1.99),
+    (3, 'Milk', 2.99);

+

Tip: When inserting a lot of data at the same time, considering using + the COPY command. + It is not as flexible as the INSERT + command, but is more efficient. Refer + to Section 14.4 for more information on improving + bulk loading performance. +


PrevHomeNext
Data ManipulationUpUpdating Data
\ No newline at end of file diff --git a/doc/src/sgml/html/dml-update.html b/doc/src/sgml/html/dml-update.html new file mode 100644 index 000000000..c33e9cc13 --- /dev/null +++ b/doc/src/sgml/html/dml-update.html @@ -0,0 +1,285 @@ + +Updating Data
PostgreSQL 9.2.2 Documentation
PrevUpChapter 6. Data ManipulationNext

6.2. Updating Data

The modification of data that is already in the database is + referred to as updating. You can update individual rows, all the + rows in a table, or a subset of all rows. Each column can be + updated separately; the other columns are not affected. +

To update existing rows, use the UPDATE + command. This requires + three pieces of information: +

  1. The name of the table and column to update

  2. The new value of the column

  3. Which row(s) to update

+

Recall from Chapter 5 that SQL does not, in general, + provide a unique identifier for rows. Therefore it is not + always possible to directly specify which row to update. + Instead, you specify which conditions a row must meet in order to + be updated. Only if you have a primary key in the table (independent of + whether you declared it or not) can you reliably address individual rows + by choosing a condition that matches the primary key. + Graphical database access tools rely on this fact to allow you to + update rows individually. +

For example, this command updates all products that have a price of + 5 to have a price of 10: +

UPDATE products SET price = 10 WHERE price = 5;

+ This might cause zero, one, or many rows to be updated. It is not + an error to attempt an update that does not match any rows. +

Let's look at that command in detail. First is the key word + UPDATE followed by the table name. As usual, + the table name can be schema-qualified, otherwise it is looked up + in the path. Next is the key word SET followed + by the column name, an equal sign, and the new column value. The + new column value can be any scalar expression, not just a constant. + For example, if you want to raise the price of all products by 10% + you could use: +

UPDATE products SET price = price * 1.10;

+ As you see, the expression for the new value can refer to the existing + value(s) in the row. We also left out the WHERE clause. + If it is omitted, it means that all rows in the table are updated. + If it is present, only those rows that match the + WHERE condition are updated. Note that the equals + sign in the SET clause is an assignment while + the one in the WHERE clause is a comparison, but + this does not create any ambiguity. Of course, the + WHERE condition does + not have to be an equality test. Many other operators are + available (see Chapter 9). But the expression + needs to evaluate to a Boolean result. +

You can update more than one column in an + UPDATE command by listing more than one + assignment in the SET clause. For example: +

UPDATE mytable SET a = 5, b = 3, c = 1 WHERE a > 0;

+


PrevHomeNext
Inserting DataUpDeleting Data
\ No newline at end of file diff --git a/doc/src/sgml/html/dml.html b/doc/src/sgml/html/dml.html new file mode 100644 index 000000000..d4a285211 --- /dev/null +++ b/doc/src/sgml/html/dml.html @@ -0,0 +1,194 @@ + +Data Manipulation

Chapter 6. Data Manipulation

Table of Contents
6.1. Inserting Data
6.2. Updating Data
6.3. Deleting Data

The previous chapter discussed how to create tables and other + structures to hold your data. Now it is time to fill the tables + with data. This chapter covers how to insert, update, and delete + table data. The chapter + after this will finally explain how to extract your long-lost data + from the database. +


PrevHomeNext
Dependency TrackingUpInserting Data
\ No newline at end of file diff --git a/doc/src/sgml/html/docguide-authoring.html b/doc/src/sgml/html/docguide-authoring.html new file mode 100644 index 000000000..6d7846048 --- /dev/null +++ b/doc/src/sgml/html/docguide-authoring.html @@ -0,0 +1,367 @@ + +Documentation Authoring

J.4. Documentation Authoring

SGML and DocBook do + not suffer from an oversupply of open-source authoring tools. The + most common tool set is the + Emacs/XEmacs + editor with appropriate editing mode. On some systems + these tools are provided in a typical full installation. +

J.4.1. Emacs/PSGML

PSGML is the most common and most + powerful mode for editing SGML documents. + When properly configured, it will allow you to use + Emacs to insert tags and check markup + consistency. You could use it for HTML as + well. Check the PSGML web site for downloads, installation instructions, and + detailed documentation. +

There is one important thing to note with + PSGML: its author assumed that your + main SGML DTD directory + would be /usr/local/lib/sgml. If, as in the + examples in this chapter, you use + /usr/local/share/sgml, you have to + compensate for this, either by setting + SGML_CATALOG_FILES environment variable, or you + can customize your PSGML installation + (its manual tells you how). +

Put the following in your ~/.emacs + environment file (adjusting the path names to be appropriate for + your system): + +

; ********** for SGML mode (psgml)
+
+(setq sgml-omittag t)
+(setq sgml-shorttag t)
+(setq sgml-minimize-attributes nil)
+(setq sgml-always-quote-attributes t)
+(setq sgml-indent-step 1)
+(setq sgml-indent-data t)
+(setq sgml-parent-document nil)
+(setq sgml-exposed-tags nil)
+(setq sgml-catalog-files '("/usr/local/share/sgml/catalog"))
+
+(autoload 'sgml-mode "psgml" "Major mode to edit SGML files." t )

+ + and in the same file add an entry for SGML + into the (existing) definition for + auto-mode-alist: +

(setq
+  auto-mode-alist
+  '(("\\.sgml$" . sgml-mode)
+   ))

+

You might find that when using PSGML, a + comfortable way of working with these separate files of book + parts is to insert a proper DOCTYPE + declaration while you're editing them. If you are working on + this source, for instance, it is an appendix chapter, so you + would specify the document as an "appendix" instance + of a DocBook document by making the first line look like this: + +

<!DOCTYPE appendix PUBLIC "-//OASIS//DTD DocBook V4.2//EN">

+ + This means that anything and everything that reads + SGML will get it right, and I can verify the + document with nsgmls -s docguide.sgml. (But + you need to take out that line before building the entire + documentation set.) +

J.4.2. Other Emacs Modes

GNU Emacs ships with a different + SGML mode, which is not quite as powerful as + PSGML, but it's less confusing and + lighter weight. Also, it offers syntax highlighting (font lock), + which can be very helpful. + src/tools/editors/emacs.samples contains + sample settings for this mode. +

Norm Walsh offers a + major mode + specifically for DocBook which also has font-lock and a number of features to + reduce typing. +


PrevHomeNext
Building The DocumentationUpStyle Guide
\ No newline at end of file diff --git a/doc/src/sgml/html/docguide-build.html b/doc/src/sgml/html/docguide-build.html new file mode 100644 index 000000000..23e117372 --- /dev/null +++ b/doc/src/sgml/html/docguide-build.html @@ -0,0 +1,953 @@ + +Building The Documentation

J.3. Building The Documentation

Once you have everything set up, change to the directory + doc/src/sgml and run one of the commands + described in the following subsections to build the + documentation. (Remember to use GNU make.) +

J.3.1. HTML

To build the HTML version of the documentation: +

doc/src/sgml$ gmake html

+ This is also the default target. The output appears in the + subdirectory html. +

To create a proper index, the build might process several identical + stages. If you do not care about the index, and just want to + proof-read the output, use draft: +

doc/src/sgml$ gmake draft

+

To build the documentation as a single HTML page, use: +

doc/src/sgml$ gmake postgres.html

+

J.3.2. Manpages

We use the DocBook XSL stylesheets to + convert DocBook + refentry pages to *roff output suitable for man + pages. The man pages are also distributed as a tar archive, + similar to the HTML version. To create the man + pages, use the commands: +

cd doc/src/sgml
+gmake man

+

J.3.3. Print Output via JadeTeX

If you want to use JadeTex to produce a + printable rendition of the documentation, you can use one of the + following commands: + +

  • To generate PostScript via DVI in A4 format: +

    doc/src/sgml$ gmake postgres-A4.ps

    + In U.S. letter format: +

    doc/src/sgml$ gmake postgres-US.ps

    +

  • To make a PDF: +

    doc/src/sgml$ gmake postgres-A4.pdf

    + or: +

    doc/src/sgml$ gmake postgres-US.pdf

    + (Of course you can also make a PDF version + from the PostScript, but if you generate PDF + directly, it will have hyperlinks and other enhanced features.) +

+

When using JadeTeX to build the PostgreSQL documentation, you will + probably need to increase some of TeX's internal parameters. These + can be set in the file texmf.cnf. The following + settings worked at the time of this writing: +

hash_extra.jadetex  = 200000
+hash_extra.pdfjadetex  = 200000
+pool_size.jadetex = 2000000
+pool_size.pdfjadetex = 2000000
+string_vacancies.jadetex = 150000
+string_vacancies.pdfjadetex = 150000
+max_strings.jadetex = 300000
+max_strings.pdfjadetex = 300000
+save_size.jadetex = 15000
+save_size.pdfjadetex = 15000

+

J.3.4. Overflow Text

Occasionally text is too wide for the printed margins, and in + extreme cases, too wide for the printed page, e.g. non-wrapped + text, wide tables. Overly wide text generates "Overfull + hbox" messages in the TeX log output file, e.g. + postgres-US.log or postgres-A4.log. + There are 72 points in an inch so anything reported as over 72 + points too wide will probably not fit on the printed page (assuming + one inch margins). To find the SGML text + causing the overflow, find the first page number mentioned above + the overflow message, e.g. [50 ###] (page 50), and + look at the page after that (e.g. page 51) in the PDF + file to see the overflow text and adjust the SGML + accordingly. +

J.3.5. Print Output via RTF

You can also create a printable version of the PostgreSQL + documentation by converting it to RTF and + applying minor formatting corrections using an office suite. + Depending on the capabilities of the particular office suite, you + can then convert the documentation to PostScript of + PDF. The procedure below illustrates this + process using Applixware. +

Note: It appears that current versions of the PostgreSQL documentation + trigger some bug in or exceed the size limit of OpenJade. If the + build process of the RTF version hangs for a + long time and the output file still has size 0, then you might have + hit that problem. (But keep in mind that a normal build takes 5 + to 10 minutes, so don't abort too soon.) +

Applixware RTF Cleanup

OpenJade omits specifying a default + style for body text. In the past, this undiagnosed problem led to + a long process of table of contents generation. However, with + great help from the Applixware folks + the symptom was diagnosed and a workaround is available. +

  1. Generate the RTF version by typing: +

    doc/src/sgml$ gmake postgres.rtf

    +

  2. Repair the RTF file to correctly specify all styles, in + particular the default style. If the document contains + refentry sections, one must also replace + formatting hints which tie a preceding paragraph to the current + paragraph, and instead tie the current paragraph to the + following one. A utility, fixrtf, is + available in doc/src/sgml to accomplish + these repairs: +

    doc/src/sgml$ ./fixrtf --refentry postgres.rtf

    +

    The script adds {\s0 Normal;} as the zeroth + style in the document. According to + Applixware, the RTF standard would + prohibit adding an implicit zeroth style, though Microsoft Word + happens to handle this case. For repairing + refentry sections, the script replaces + \keepn tags with \keep. +

  3. Open a new document in Applixware Words and + then import the RTF file. +

  4. Generate a new table of contents (ToC) using + Applixware. +

    1. Select the existing ToC lines, from the beginning of the first + character on the first line to the last character of the last + line. +

    2. Build a new ToC using + Tools->Book + Building->Create Table of + Contents. Select the first three + levels of headers for inclusion in the ToC. This will replace + the existing lines imported in the RTF with a native + Applixware ToC. +

    3. Adjust the ToC formatting by using + Format->Style, + selecting each of the three ToC styles, and adjusting the + indents for First and + Left. Use the following values: + +

      StyleFirst Indent (inches)Left Indent (inches)
      TOC-Heading 10.40.4
      TOC-Heading 20.80.8
      TOC-Heading 31.21.2

      +

  5. Work through the document to: + +

    • Adjust page breaks. +

    • Adjust table column widths. +

    +

  6. Replace the right-justified page numbers in the Examples and + Figures portions of the ToC with correct values. This only takes + a few minutes. +

  7. Delete the index section from the document if it is empty. +

  8. Regenerate and adjust the table of contents. +

    1. Select the ToC field. +

    2. Select Tools->Book + Building->Create Table of + Contents. +

    3. Unbind the ToC by selecting + Tools->Field + Editing->Unprotect. +

    4. Delete the first line in the ToC, which is an entry for the + ToC itself. +

  9. Save the document as native Applixware + Words format to allow easier last minute editing + later. +

  10. "Print" the document + to a file in PostScript format. +

J.3.6. Plain Text Files

Several files are distributed as plain text, for reading during + the installation process. The INSTALL file + corresponds to Chapter 15, with some minor + changes to account for the different context. To recreate the + file, change to the directory doc/src/sgml + and enter gmake INSTALL. This will create + a file INSTALL.html that can be saved as text + with Netscape Navigator and put into + the place of the existing file. + Netscape seems to offer the best + quality for HTML to text conversions (over + lynx and + w3m). +

The file HISTORY can be created similarly, + using the command gmake HISTORY. For the + file src/test/regress/README the command is + gmake regress_README. +

J.3.7. Syntax Check

Building the documentation can take very long. But there is a + method to just check the correct syntax of the documentation + files, which only takes a few seconds: +

doc/src/sgml$ gmake check

+


PrevHomeNext
Tool SetsUpDocumentation Authoring
\ No newline at end of file diff --git a/doc/src/sgml/html/docguide-docbook.html b/doc/src/sgml/html/docguide-docbook.html new file mode 100644 index 000000000..cfcf2df94 --- /dev/null +++ b/doc/src/sgml/html/docguide-docbook.html @@ -0,0 +1,219 @@ + +DocBook

J.1. DocBook

The documentation sources are written in + DocBook, which is a markup language + superficially similar to HTML. Both of these + languages are applications of the Standard Generalized + Markup Language, SGML, which is + essentially a language for describing other languages. In what + follows, the terms DocBook and SGML are both + used, but technically they are not interchangeable. +

DocBook allows an author to specify the + structure and content of a technical document without worrying + about presentation details. A document style defines how that + content is rendered into one of several final forms. DocBook is + maintained by the OASIS group. The official DocBook site has good introductory and reference documentation and + a complete O'Reilly book for your online reading pleasure. The + NewbieDoc Docbook Guide is very helpful for beginners. + The FreeBSD Documentation Project also uses DocBook and has some good + information, including a number of style guidelines that might be + worth considering. +


PrevHomeNext
DocumentationUpTool Sets
\ No newline at end of file diff --git a/doc/src/sgml/html/docguide-style.html b/doc/src/sgml/html/docguide-style.html new file mode 100644 index 000000000..b9c1e4cd5 --- /dev/null +++ b/doc/src/sgml/html/docguide-style.html @@ -0,0 +1,357 @@ + +Style Guide

J.5. Style Guide

J.5.1. Reference Pages

Reference pages should follow a standard layout. This allows + users to find the desired information more quickly, and it also + encourages writers to document all relevant aspects of a command. + Consistency is not only desired among + PostgreSQL reference pages, but also + with reference pages provided by the operating system and other + packages. Hence the following guidelines have been developed. + They are for the most part consistent with similar guidelines + established by various operating systems. +

Reference pages that describe executable commands should contain + the following sections, in this order. Sections that do not apply + can be omitted. Additional top-level sections should only be used + in special circumstances; often that information belongs in the + "Usage" section. + +

Name

This section is generated automatically. It contains the + command name and a half-sentence summary of its functionality. +

Synopsis

This section contains the syntax diagram of the command. The + synopsis should normally not list each command-line option; + that is done below. Instead, list the major components of the + command line, such as where input and output files go. +

Description

Several paragraphs explaining what the command does. +

Options

A list describing each command-line option. If there are a + lot of options, subsections can be used. +

Exit Status

If the program uses 0 for success and non-zero for failure, + then you do not need to document it. If there is a meaning + behind the different non-zero exit codes, list them here. +

Usage

Describe any sublanguage or run-time interface of the program. + If the program is not interactive, this section can usually be + omitted. Otherwise, this section is a catch-all for + describing run-time features. Use subsections if appropriate. +

Environment

List all environment variables that the program might use. + Try to be complete; even seemingly trivial variables like + SHELL might be of interest to the user. +

Files

List any files that the program might access implicitly. That + is, do not list input and output files that were specified on + the command line, but list configuration files, etc. +

Diagnostics

Explain any unusual output that the program might create. + Refrain from listing every possible error message. This is a + lot of work and has little use in practice. But if, say, the + error messages have a standard format that the user can parse, + this would be the place to explain it. +

Notes

Anything that doesn't fit elsewhere, but in particular bugs, + implementation flaws, security considerations, compatibility + issues. +

Examples

Examples +

History

If there were some major milestones in the history of the + program, they might be listed here. Usually, this section can + be omitted. +

Author

Author (only used in the contrib section) +

See Also

Cross-references, listed in the following order: other + PostgreSQL command reference pages, + PostgreSQL SQL command reference + pages, citation of PostgreSQL + manuals, other reference pages (e.g., operating system, other + packages), other documentation. Items in the same group are + listed alphabetically. +

+

Reference pages describing SQL commands should contain the + following sections: Name, Synopsis, Description, Parameters, + Outputs, Notes, Examples, Compatibility, History, See + Also. The Parameters section is like the Options section, but + there is more freedom about which clauses of the command can be + listed. The Outputs section is only needed if the command returns + something other than a default command-completion tag. The Compatibility + section should explain to what extent + this command conforms to the SQL standard(s), or to which other + database system it is compatible. The See Also section of SQL + commands should list SQL commands before cross-references to + programs. +


PrevHomeNext
Documentation AuthoringUpAcronyms
\ No newline at end of file diff --git a/doc/src/sgml/html/docguide-toolsets.html b/doc/src/sgml/html/docguide-toolsets.html new file mode 100644 index 000000000..ed3d9f24b --- /dev/null +++ b/doc/src/sgml/html/docguide-toolsets.html @@ -0,0 +1,1138 @@ + +Tool Sets

J.2. Tool Sets

The following tools are used to process the documentation. Some + might be optional, as noted. + +

DocBook DTD

This is the definition of DocBook itself. We currently use + version 4.2; you cannot use later or earlier versions. You + need the SGML variant of the DocBook DTD, + but to build man pages you also need the XML + variant of the same version. +

ISO 8879 character entities

These are required by DocBook but are distributed separately + because they are maintained by ISO. +

DocBook DSSSL Stylesheets

These contain the processing instructions for converting the + DocBook sources to other formats, such as + HTML. +

DocBook XSL Stylesheets

This is another stylesheet for converting DocBook to other + formats. We currently use this to produce man pages and + optionally HTMLHelp. You can also use this toolchain to + produce HTML or PDF output, but official PostgreSQL releases + use the DSSSL stylesheets for that. +

The minimum required version is currently 1.74.0. +

OpenJade

This is the base package of SGML processing. + It contains an SGML parser, a + DSSSL processor (that is, a program to + convert SGML to other formats using + DSSSL stylesheets), as well as a number of + related tools. Jade is now being + maintained by the OpenJade group, no longer by James Clark. +

Libxslt for xsltproc

This is the processing tool to use with the XSLT stylesheets + (like jade is the processing tool for DSSSL + stylesheets). +

JadeTeX

If you want to, you can also install + JadeTeX to use + TeX as a formatting backend for + Jade. + JadeTeX can create PostScript or + PDF files (the latter with bookmarks). +

However, the output from JadeTeX is + inferior to what you get from the RTF + backend. Particular problem areas are tables and various + artifacts of vertical and horizontal spacing. Also, there is + no opportunity to manually polish the results. +

+

We have documented experience with several installation methods for + the various tools that are needed to process the documentation. + These will be described below. There might be some other packaged + distributions for these tools. Please report package status to the + documentation mailing list, and we will include that information + here. +

J.2.1. Linux RPM Installation

Most vendors provide a complete RPM set for DocBook processing in + their distribution. Look for an "SGML" option while + installing, or the following packages: + sgml-common, docbook, + stylesheets, openjade + (or jade). Possibly + sgml-tools will be needed as well. If your + distributor does not provide these then you should be able to make + use of the packages from some other, reasonably compatible vendor. +

J.2.2. FreeBSD Installation

The FreeBSD Documentation Project is itself a heavy user of + DocBook, so it comes as no surprise that there is a full set of + "ports" of the documentation tools available on + FreeBSD. The following ports need to be installed to build the + documentation on FreeBSD. +

  • textproc/sp

  • textproc/openjade

  • textproc/iso8879

  • textproc/dsssl-docbook-modular

  • textproc/docbook-420

+

A number of things from /usr/ports/print + (tex, jadetex) might + also be of interest. +

It's possible that the ports do not update the main catalog file + in /usr/local/share/sgml/catalog.ports or order + isn't proper . Be sure to have the following lines in beginning of file: +

CATALOG "openjade/catalog"
+CATALOG "iso8879/catalog"
+CATALOG "docbook/dsssl/modular/catalog"
+CATALOG "docbook/4.2/catalog"

+ If you do not want to edit the file you can also set the + environment variable SGML_CATALOG_FILES to a + colon-separated list of catalog files (such as the one above). +

More information about the FreeBSD documentation tools can be + found in the FreeBSD Documentation Project's instructions. +

J.2.3. Debian Packages

There is a full set of packages of the documentation tools + available for Debian GNU/Linux. + To install, simply use: +

apt-get install docbook docbook-dsssl docbook-xsl openjade1.3 opensp xsltproc

+

J.2.4. Manual Installation from Source

The manual installation process of the DocBook tools is somewhat + complex, so if you have pre-built packages available, use them. + We describe here only a standard setup, with reasonably standard + installation paths, and no "fancy" features. For + details, you should study the documentation of the respective + package, and read SGML introductory material. +

J.2.4.1. Installing OpenJade

  1. The installation of OpenJade offers a GNU-style + ./configure; make; make install build + process. Details can be found in the OpenJade source + distribution. In a nutshell: +

    ./configure --enable-default-catalog=/usr/local/share/sgml/catalog
    +make
    +make install

    + Be sure to remember where you put the "default + catalog"; you will need it below. You can also leave + it off, but then you will have to set the environment variable + SGML_CATALOG_FILES to point to the file + whenever you use jade later on. + (This method is also an option if OpenJade is already + installed and you want to install the rest of the toolchain + locally.) +

    Note: Some users have reported encountering a segmentation fault using + OpenJade 1.4devel to build the PDFs, with a message like: +

    openjade:./stylesheet.dsl:664:2:E: flow object not accepted by port; only display flow objects accepted
    +make: *** [postgres-A4.tex-pdf] Segmentation fault

    + Downgrading to OpenJade 1.3 should get rid of this error. +

  2. Additionally, you should install the files + dsssl.dtd, fot.dtd, + style-sheet.dtd, and + catalog from the + dsssl directory somewhere, perhaps into + /usr/local/share/sgml/dsssl. It's + probably easiest to copy the entire directory: +

    cp -R dsssl /usr/local/share/sgml

    +

  3. Finally, create the file + /usr/local/share/sgml/catalog and add + this line to it: +

    CATALOG "dsssl/catalog"

    + (This is a relative path reference to the file installed in + step 2. Be sure to adjust it + if you chose your installation layout differently.) +

J.2.4.2. Installing the DocBook DTD Kit

  1. Obtain the DocBook V4.2 distribution. +

  2. Create the directory + /usr/local/share/sgml/docbook-4.2 and change + to it. (The exact location is irrelevant, but this one is + reasonable within the layout we are following here.) +

    $ mkdir /usr/local/share/sgml/docbook-4.2
    +$ cd /usr/local/share/sgml/docbook-4.2

    +

  3. Unpack the archive: +

    $ unzip -a ...../docbook-4.2.zip

    + (The archive will unpack its files into the current directory.) +

  4. Edit the file + /usr/local/share/sgml/catalog (or whatever + you told jade during installation) and put a line like this + into it: +

    CATALOG "docbook-4.2/docbook.cat"

    +

  5. Download the ISO 8879 character entities archive, unpack it, and put the + files in the same directory you put the DocBook files in: +

    $ cd /usr/local/share/sgml/docbook-4.2
    +$ unzip ...../ISOEnts.zip

    +

  6. Run the following command in the directory with the DocBook and ISO files: +

    perl -pi -e 's/iso-(.*).gml/ISO\1/g' docbook.cat

    + (This fixes a mixup between the names used in the DocBook + catalog file and the actual names of the ISO character entity + files.) +

J.2.4.3. Installing the DocBook DSSSL Style Sheets

To install the style sheets, unzip and untar the distribution and + move it to a suitable place, for example + /usr/local/share/sgml. (The archive will + automatically create a subdirectory.) +

$ gunzip docbook-dsssl-1.xx.tar.gz
+$ tar -C /usr/local/share/sgml -xf docbook-dsssl-1.xx.tar

+

The usual catalog entry in + /usr/local/share/sgml/catalog can also be + made: +

CATALOG "docbook-dsssl-1.xx/catalog"

+ Because stylesheets change rather often, and it's sometimes + beneficial to try out alternative versions, + PostgreSQL doesn't use this catalog + entry. See Section J.2.5 for + information about how to select the stylesheets instead. +

J.2.4.4. Installing JadeTeX

To install and use JadeTeX, you will + need a working installation of TeX and + LaTeX2e, including the supported + tools and + graphics packages, + Babel, + AMS fonts and + AMS-LaTeX, the + PSNFSS extension + and companion kit of "the 35 fonts", the + dvips program for generating + PostScript, the macro packages + fancyhdr, + hyperref, + minitoc, + url and + ot2enc. All of these can be found on + your friendly neighborhood CTAN site. + The installation of the TeX base + system is far beyond the scope of this introduction. Binary + packages should be available for any system that can run + TeX. +

Before you can use JadeTeX with the + PostgreSQL documentation sources, you + will need to increase the size of + TeX's internal data structures. + Details on this can be found in the JadeTeX + installation instructions. +

Once that is finished you can install JadeTeX: +

$ gunzip jadetex-xxx.tar.gz
+$ tar xf jadetex-xxx.tar
+$ cd jadetex
+$ make install
+$ mktexlsr

+ The last two need to be done as root. +

J.2.5. Detection by configure

Before you can build the documentation you need to run the + configure script as you would when building + the PostgreSQL programs themselves. + Check the output near the end of the run, it should look something + like this: +

checking for onsgmls... onsgmls
+checking for openjade... openjade
+checking for DocBook V4.2... yes
+checking for DocBook stylesheets... /usr/share/sgml/docbook/stylesheet/dsssl/modular
+checking for collateindex.pl... /usr/bin/collateindex.pl
+checking for xsltproc... xsltproc
+checking for osx... osx

+ If neither onsgmls nor + nsgmls were found then some of the following tests + will be skipped. nsgmls is part of the Jade + package. You can pass the environment variables + JADE and NSGMLS to configure to point + to the programs if they are not found automatically. If + "DocBook V4.2" was not found then you did not install + the DocBook DTD kit in a place where Jade can find it, or you have + not set up the catalog files correctly. See the installation hints + above. The DocBook stylesheets are looked for in a number of + relatively standard places, but if you have them some other place + then you should set the environment variable + DOCBOOKSTYLE to the location and rerun + configure afterwards. +


PrevHomeNext
DocBookUpBuilding The Documentation
\ No newline at end of file diff --git a/doc/src/sgml/html/docguide.html b/doc/src/sgml/html/docguide.html new file mode 100644 index 000000000..887047381 --- /dev/null +++ b/doc/src/sgml/html/docguide.html @@ -0,0 +1,254 @@ + +Documentation

Appendix J. Documentation

PostgreSQL has four primary documentation + formats: + +

  • Plain text, for pre-installation information +

  • HTML, for on-line browsing and reference +

  • PDF or PostScript, for printing +

  • man pages, for quick reference. +

+ + Additionally, a number of plain-text README files can + be found throughout the PostgreSQL source tree, + documenting various implementation issues. +

HTML documentation and man pages are part of a + standard distribution and are installed by default. PDF and + PostScript format documentation is available separately for + download. +


PrevHomeNext
Getting The Source via GitUpDocBook
\ No newline at end of file diff --git a/doc/src/sgml/html/dummy-seclabel.html b/doc/src/sgml/html/dummy-seclabel.html new file mode 100644 index 000000000..b9154555e --- /dev/null +++ b/doc/src/sgml/html/dummy-seclabel.html @@ -0,0 +1,270 @@ + +dummy_seclabel
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.12. dummy_seclabel

The dummy_seclabel module exists only to support regression + testing of the SECURITY LABEL statement. It is not intended + to be used in production. +

F.12.1. Rationale

The SECURITY LABEL statement allows the user to assign security + labels to database objects; however, security labels can only be assigned + when specifically allowed by a loadable module, so this module is provided + to allow proper regression testing. +

Security label providers intended to be used in production will typically be + dependent on a platform-specific feature such as + SE-Linux. This module is platform-independent, + and therefore better-suited to regression testing. +

F.12.2. Usage

Here's a simple example of usage: +

# postgresql.conf
+shared_preload_libraries = 'dummy_seclabel'
postgres=# CREATE TABLE t (a int, b text);
+CREATE TABLE
+postgres=# SECURITY LABEL ON TABLE t IS 'classified';
+SECURITY LABEL

The dummy_seclabel module provides only four hardcoded + labels: unclassified, classified, + secret, and top secret. + It does not allow any other strings as security labels. +

These labels are not used to enforce access controls. They are only used + to check whether the SECURITY LABEL statement works as expected, + or not. +


PrevHomeNext
dict_xsynUpearthdistance
\ No newline at end of file diff --git a/doc/src/sgml/html/dynamic-trace.html b/doc/src/sgml/html/dynamic-trace.html new file mode 100644 index 000000000..4d4701031 --- /dev/null +++ b/doc/src/sgml/html/dynamic-trace.html @@ -0,0 +1,1220 @@ + +Dynamic Tracing
PostgreSQL 9.2.2 Documentation
PrevUpChapter 27. Monitoring Database ActivityNext

27.4. Dynamic Tracing

PostgreSQL provides facilities to support + dynamic tracing of the database server. This allows an external + utility to be called at specific points in the code and thereby trace + execution. +

A number of probes or trace points are already inserted into the source + code. These probes are intended to be used by database developers and + administrators. By default the probes are not compiled into + PostgreSQL; the user needs to explicitly tell + the configure script to make the probes available. +

Currently, only the + DTrace + utility is supported, which is available + on OpenSolaris, Solaris 10, and Mac OS X Leopard. It is expected that + DTrace will be available in the future on FreeBSD and possibly other + operating systems. The + SystemTap project + for Linux also provides a DTrace equivalent. Supporting other dynamic + tracing utilities is theoretically possible by changing the definitions for + the macros in src/include/utils/probes.h. +

27.4.1. Compiling for Dynamic Tracing

By default, probes are not available, so you will need to + explicitly tell the configure script to make the probes available + in PostgreSQL. To include DTrace support + specify --enable-dtrace to configure. See Section 15.4 for further information. +

27.4.2. Built-in Probes

A number of standard probes are provided in the source code, + as shown in Table 27-15; + Table 27-16 + shows the types used in the probes. More probes can certainly be + added to enhance PostgreSQL's observability. +

Table 27-15. Built-in DTrace Probes

NameParametersDescription
transaction-start(LocalTransactionId)Probe that fires at the start of a new transaction. + arg0 is the transaction ID.
transaction-commit(LocalTransactionId)Probe that fires when a transaction completes successfully. + arg0 is the transaction ID.
transaction-abort(LocalTransactionId)Probe that fires when a transaction completes unsuccessfully. + arg0 is the transaction ID.
query-start(const char *)Probe that fires when the processing of a query is started. + arg0 is the query string.
query-done(const char *)Probe that fires when the processing of a query is complete. + arg0 is the query string.
query-parse-start(const char *)Probe that fires when the parsing of a query is started. + arg0 is the query string.
query-parse-done(const char *)Probe that fires when the parsing of a query is complete. + arg0 is the query string.
query-rewrite-start(const char *)Probe that fires when the rewriting of a query is started. + arg0 is the query string.
query-rewrite-done(const char *)Probe that fires when the rewriting of a query is complete. + arg0 is the query string.
query-plan-start()Probe that fires when the planning of a query is started.
query-plan-done()Probe that fires when the planning of a query is complete.
query-execute-start()Probe that fires when the execution of a query is started.
query-execute-done()Probe that fires when the execution of a query is complete.
statement-status(const char *)Probe that fires anytime the server process updates its + pg_stat_activity.status. + arg0 is the new status string.
checkpoint-start(int)Probe that fires when a checkpoint is started. + arg0 holds the bitwise flags used to distinguish different checkpoint + types, such as shutdown, immediate or force.
checkpoint-done(int, int, int, int, int)Probe that fires when a checkpoint is complete. + (The probes listed next fire in sequence during checkpoint processing.) + arg0 is the number of buffers written. arg1 is the total number of + buffers. arg2, arg3 and arg4 contain the number of xlog file(s) added, + removed and recycled respectively.
clog-checkpoint-start(bool)Probe that fires when the CLOG portion of a checkpoint is started. + arg0 is true for normal checkpoint, false for shutdown + checkpoint.
clog-checkpoint-done(bool)Probe that fires when the CLOG portion of a checkpoint is + complete. arg0 has the same meaning as for clog-checkpoint-start.
subtrans-checkpoint-start(bool)Probe that fires when the SUBTRANS portion of a checkpoint is + started. + arg0 is true for normal checkpoint, false for shutdown + checkpoint.
subtrans-checkpoint-done(bool)Probe that fires when the SUBTRANS portion of a checkpoint is + complete. arg0 has the same meaning as for + subtrans-checkpoint-start.
multixact-checkpoint-start(bool)Probe that fires when the MultiXact portion of a checkpoint is + started. + arg0 is true for normal checkpoint, false for shutdown + checkpoint.
multixact-checkpoint-done(bool)Probe that fires when the MultiXact portion of a checkpoint is + complete. arg0 has the same meaning as for + multixact-checkpoint-start.
buffer-checkpoint-start(int)Probe that fires when the buffer-writing portion of a checkpoint + is started. + arg0 holds the bitwise flags used to distinguish different checkpoint + types, such as shutdown, immediate or force.
buffer-sync-start(int, int)Probe that fires when we begin to write dirty buffers during + checkpoint (after identifying which buffers must be written). + arg0 is the total number of buffers. + arg1 is the number that are currently dirty and need to be written.
buffer-sync-written(int)Probe that fires after each buffer is written during checkpoint. + arg0 is the ID number of the buffer.
buffer-sync-done(int, int, int)Probe that fires when all dirty buffers have been written. + arg0 is the total number of buffers. + arg1 is the number of buffers actually written by the checkpoint process. + arg2 is the number that were expected to be written (arg1 of + buffer-sync-start); any difference reflects other processes flushing + buffers during the checkpoint.
buffer-checkpoint-sync-start()Probe that fires after dirty buffers have been written to the + kernel, and before starting to issue fsync requests.
buffer-checkpoint-done()Probe that fires when syncing of buffers to disk is + complete.
twophase-checkpoint-start()Probe that fires when the two-phase portion of a checkpoint is + started.
twophase-checkpoint-done()Probe that fires when the two-phase portion of a checkpoint is + complete.
buffer-read-start(ForkNumber, BlockNumber, Oid, Oid, Oid, int, bool)Probe that fires when a buffer read is started. + arg0 and arg1 contain the fork and block numbers of the page (but + arg1 will be -1 if this is a relation extension request). + arg2, arg3, and arg4 contain the tablespace, database, and relation OIDs + identifying the relation. + arg5 is the ID of the backend which created the temporary relation for a + local buffer, or InvalidBackendId (-1) for a shared buffer. + arg6 is true for a relation extension request, false for normal + read.
buffer-read-done(ForkNumber, BlockNumber, Oid, Oid, Oid, int, bool, bool)Probe that fires when a buffer read is complete. + arg0 and arg1 contain the fork and block numbers of the page (if this + is a relation extension request, arg1 now contains the block number + of the newly added block). + arg2, arg3, and arg4 contain the tablespace, database, and relation OIDs + identifying the relation. + arg5 is the ID of the backend which created the temporary relation for a + local buffer, or InvalidBackendId (-1) for a shared buffer. + arg6 is true for a relation extension request, false for normal + read. + arg7 is true if the buffer was found in the pool, false if not.
buffer-flush-start(ForkNumber, BlockNumber, Oid, Oid, Oid)Probe that fires before issuing any write request for a shared + buffer. + arg0 and arg1 contain the fork and block numbers of the page. + arg2, arg3, and arg4 contain the tablespace, database, and relation OIDs + identifying the relation.
buffer-flush-done(ForkNumber, BlockNumber, Oid, Oid, Oid)Probe that fires when a write request is complete. (Note + that this just reflects the time to pass the data to the kernel; + it's typically not actually been written to disk yet.) + The arguments are the same as for buffer-flush-start.
buffer-write-dirty-start(ForkNumber, BlockNumber, Oid, Oid, Oid)Probe that fires when a server process begins to write a dirty + buffer. (If this happens often, it implies that + shared_buffers is too + small or the bgwriter control parameters need adjustment.) + arg0 and arg1 contain the fork and block numbers of the page. + arg2, arg3, and arg4 contain the tablespace, database, and relation OIDs + identifying the relation.
buffer-write-dirty-done(ForkNumber, BlockNumber, Oid, Oid, Oid)Probe that fires when a dirty-buffer write is complete. + The arguments are the same as for buffer-write-dirty-start.
wal-buffer-write-dirty-start()Probe that fires when a server process begins to write a + dirty WAL buffer because no more WAL buffer space is available. + (If this happens often, it implies that + wal_buffers is too small.)
wal-buffer-write-dirty-done()Probe that fires when a dirty WAL buffer write is complete.
xlog-insert(unsigned char, unsigned char)Probe that fires when a WAL record is inserted. + arg0 is the resource manager (rmid) for the record. + arg1 contains the info flags.
xlog-switch()Probe that fires when a WAL segment switch is requested.
smgr-md-read-start(ForkNumber, BlockNumber, Oid, Oid, Oid, int)Probe that fires when beginning to read a block from a relation. + arg0 and arg1 contain the fork and block numbers of the page. + arg2, arg3, and arg4 contain the tablespace, database, and relation OIDs + identifying the relation. + arg5 is the ID of the backend which created the temporary relation for a + local buffer, or InvalidBackendId (-1) for a shared buffer.
smgr-md-read-done(ForkNumber, BlockNumber, Oid, Oid, Oid, int, int, int)Probe that fires when a block read is complete. + arg0 and arg1 contain the fork and block numbers of the page. + arg2, arg3, and arg4 contain the tablespace, database, and relation OIDs + identifying the relation. + arg5 is the ID of the backend which created the temporary relation for a + local buffer, or InvalidBackendId (-1) for a shared buffer. + arg6 is the number of bytes actually read, while arg7 is the number + requested (if these are different it indicates trouble).
smgr-md-write-start(ForkNumber, BlockNumber, Oid, Oid, Oid, int)Probe that fires when beginning to write a block to a relation. + arg0 and arg1 contain the fork and block numbers of the page. + arg2, arg3, and arg4 contain the tablespace, database, and relation OIDs + identifying the relation. + arg5 is the ID of the backend which created the temporary relation for a + local buffer, or InvalidBackendId (-1) for a shared buffer.
smgr-md-write-done(ForkNumber, BlockNumber, Oid, Oid, Oid, int, int, int)Probe that fires when a block write is complete. + arg0 and arg1 contain the fork and block numbers of the page. + arg2, arg3, and arg4 contain the tablespace, database, and relation OIDs + identifying the relation. + arg5 is the ID of the backend which created the temporary relation for a + local buffer, or InvalidBackendId (-1) for a shared buffer. + arg6 is the number of bytes actually written, while arg7 is the number + requested (if these are different it indicates trouble).
sort-start(int, bool, int, int, bool)Probe that fires when a sort operation is started. + arg0 indicates heap, index or datum sort. + arg1 is true for unique-value enforcement. + arg2 is the number of key columns. + arg3 is the number of kilobytes of work memory allowed. + arg4 is true if random access to the sort result is required.
sort-done(bool, long)Probe that fires when a sort is complete. + arg0 is true for external sort, false for internal sort. + arg1 is the number of disk blocks used for an external sort, + or kilobytes of memory used for an internal sort.
lwlock-acquire(LWLockId, LWLockMode)Probe that fires when an LWLock has been acquired. + arg0 is the LWLock's ID. + arg1 is the requested lock mode, either exclusive or shared.
lwlock-release(LWLockId)Probe that fires when an LWLock has been released (but note + that any released waiters have not yet been awakened). + arg0 is the LWLock's ID.
lwlock-wait-start(LWLockId, LWLockMode)Probe that fires when an LWLock was not immediately available and + a server process has begun to wait for the lock to become available. + arg0 is the LWLock's ID. + arg1 is the requested lock mode, either exclusive or shared.
lwlock-wait-done(LWLockId, LWLockMode)Probe that fires when a server process has been released from its + wait for an LWLock (it does not actually have the lock yet). + arg0 is the LWLock's ID. + arg1 is the requested lock mode, either exclusive or shared.
lwlock-condacquire(LWLockId, LWLockMode)Probe that fires when an LWLock was successfully acquired when the + caller specified no waiting. + arg0 is the LWLock's ID. + arg1 is the requested lock mode, either exclusive or shared.
lwlock-condacquire-fail(LWLockId, LWLockMode)Probe that fires when an LWLock was not successfully acquired when + the caller specified no waiting. + arg0 is the LWLock's ID. + arg1 is the requested lock mode, either exclusive or shared.
lock-wait-start(unsigned int, unsigned int, unsigned int, unsigned int, unsigned int, LOCKMODE)Probe that fires when a request for a heavyweight lock (lmgr lock) + has begun to wait because the lock is not available. + arg0 through arg3 are the tag fields identifying the object being + locked. arg4 indicates the type of object being locked. + arg5 indicates the lock type being requested.
lock-wait-done(unsigned int, unsigned int, unsigned int, unsigned int, unsigned int, LOCKMODE)Probe that fires when a request for a heavyweight lock (lmgr lock) + has finished waiting (i.e., has acquired the lock). + The arguments are the same as for lock-wait-start.
deadlock-found()Probe that fires when a deadlock is found by the deadlock + detector.

Table 27-16. Defined Types Used in Probe Parameters

TypeDefinition
LocalTransactionIdunsigned int
LWLockIdint
LWLockModeint
LOCKMODEint
BlockNumberunsigned int
Oidunsigned int
ForkNumberint
boolchar

27.4.3. Using Probes

The example below shows a DTrace script for analyzing transaction + counts in the system, as an alternative to snapshotting + pg_stat_database before and after a performance test: +

#!/usr/sbin/dtrace -qs
+
+postgresql$1:::transaction-start
+{
+      @start["Start"] = count();
+      self->ts  = timestamp;
+}
+
+postgresql$1:::transaction-abort
+{
+      @abort["Abort"] = count();
+}
+
+postgresql$1:::transaction-commit
+/self->ts/
+{
+      @commit["Commit"] = count();
+      @time["Total time (ns)"] = sum(timestamp - self->ts);
+      self->ts=0;
+}

+ When executed, the example D script gives output such as: +

# ./txn_count.d `pgrep -n postgres` or ./txn_count.d <PID>
+^C
+
+Start                                          71
+Commit                                         70
+Total time (ns)                        2312105013

+

Note: SystemTap uses a different notation for trace scripts than DTrace does, + even though the underlying trace points are compatible. One point worth + noting is that at this writing, SystemTap scripts must reference probe + names using double underscores in place of hyphens. This is expected to + be fixed in future SystemTap releases. +

You should remember that DTrace scripts need to be carefully written and + debugged, otherwise the trace information collected might + be meaningless. In most cases where problems are found it is the + instrumentation that is at fault, not the underlying system. When + discussing information found using dynamic tracing, be sure to enclose + the script used to allow that too to be checked and discussed. +

More example scripts can be found in the PgFoundry + dtrace project. +

27.4.4. Defining New Probes

New probes can be defined within the code wherever the developer + desires, though this will require a recompilation. Below are the steps + for inserting new probes: +

  1. Decide on probe names and data to be made available through the probes +

  2. Add the probe definitions to src/backend/utils/probes.d +

  3. Include pg_trace.h if it is not already present in the + module(s) containing the probe points, and insert + TRACE_POSTGRESQL probe macros at the desired locations + in the source code +

  4. Recompile and verify that the new probes are available +

Example: Here is an example of how you would add a probe to trace all new + transactions by transaction ID. +

  1. Decide that the probe will be named transaction-start and + requires a parameter of type LocalTransactionId +

  2. Add the probe definition to src/backend/utils/probes.d: +

    probe transaction__start(LocalTransactionId);

    + Note the use of the double underline in the probe name. In a DTrace + script using the probe, the double underline needs to be replaced with a + hyphen, so transaction-start is the name to document for + users. +

  3. At compile time, transaction__start is converted to a macro + called TRACE_POSTGRESQL_TRANSACTION_START (notice the + underscores are single here), which is available by including + pg_trace.h. Add the macro call to the appropriate location + in the source code. In this case, it looks like the following: + +

    TRACE_POSTGRESQL_TRANSACTION_START(vxid.localTransactionId);

    +

  4. After recompiling and running the new binary, check that your newly added + probe is available by executing the following DTrace command. You + should see similar output: +

    # dtrace -ln transaction-start
    +   ID    PROVIDER          MODULE           FUNCTION NAME
    +18705 postgresql49878     postgres     StartTransactionCommand transaction-start
    +18755 postgresql49877     postgres     StartTransactionCommand transaction-start
    +18805 postgresql49876     postgres     StartTransactionCommand transaction-start
    +18855 postgresql49875     postgres     StartTransactionCommand transaction-start
    +18986 postgresql49873     postgres     StartTransactionCommand transaction-start

    +

There are a few things to be careful about when adding trace macros + to the C code: + +

  • You should take care that the data types specified for a probe's + parameters match the data types of the variables used in the macro. + Otherwise, you will get compilation errors. +

  • On most platforms, if PostgreSQL is + built with --enable-dtrace, the arguments to a trace + macro will be evaluated whenever control passes through the + macro, even if no tracing is being done. This is + usually not worth worrying about if you are just reporting the + values of a few local variables. But beware of putting expensive + function calls into the arguments. If you need to do that, + consider protecting the macro with a check to see if the trace + is actually enabled: + +

    if (TRACE_POSTGRESQL_TRANSACTION_START_ENABLED())
    +    TRACE_POSTGRESQL_TRANSACTION_START(some_function(...));

    + + Each trace macro has a corresponding ENABLED macro. +

+ +


PrevHomeNext
Viewing LocksUpMonitoring Disk Usage
\ No newline at end of file diff --git a/doc/src/sgml/html/earthdistance.html b/doc/src/sgml/html/earthdistance.html new file mode 100644 index 000000000..831dc84af --- /dev/null +++ b/doc/src/sgml/html/earthdistance.html @@ -0,0 +1,516 @@ + +earthdistance
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.13. earthdistance

The earthdistance module provides two different approaches to + calculating great circle distances on the surface of the Earth. The one + described first depends on the cube module (which + must be installed before earthdistance can be + installed). The second one is based on the built-in point data type, + using longitude and latitude for the coordinates. +

In this module, the Earth is assumed to be perfectly spherical. + (If that's too inaccurate for you, you might want to look at the + PostGIS + project.) +

F.13.1. Cube-based Earth Distances

Data is stored in cubes that are points (both corners are the same) using 3 + coordinates representing the x, y, and z distance from the center of the + Earth. A domain earth over cube is provided, which + includes constraint checks that the value meets these restrictions and + is reasonably close to the actual surface of the Earth. +

The radius of the Earth is obtained from the earth() + function. It is given in meters. But by changing this one function you can + change the module to use some other units, or to use a different value of + the radius that you feel is more appropriate. +

This package has applications to astronomical databases as well. + Astronomers will probably want to change earth() to return a + radius of 180/pi() so that distances are in degrees. +

Functions are provided to support input in latitude and longitude (in + degrees), to support output of latitude and longitude, to calculate + the great circle distance between two points and to easily specify a + bounding box usable for index searches. +

The provided functions are shown + in Table F-4. +

Table F-4. Cube-based Earthdistance Functions

FunctionReturnsDescription
earth()float8Returns the assumed radius of the Earth.
sec_to_gc(float8)float8Converts the normal straight line + (secant) distance between two points on the surface of the Earth + to the great circle distance between them. +
gc_to_sec(float8)float8Converts the great circle distance between two points on the + surface of the Earth to the normal straight line (secant) distance + between them. +
ll_to_earth(float8, float8)earthReturns the location of a point on the surface of the Earth given + its latitude (argument 1) and longitude (argument 2) in degrees. +
latitude(earth)float8Returns the latitude in degrees of a point on the surface of the + Earth. +
longitude(earth)float8Returns the longitude in degrees of a point on the surface of the + Earth. +
earth_distance(earth, earth)float8Returns the great circle distance between two points on the + surface of the Earth. +
earth_box(earth, float8)cubeReturns a box suitable for an indexed search using the cube + @> + operator for points within a given great circle distance of a location. + Some points in this box are further than the specified great circle + distance from the location, so a second check using + earth_distance should be included in the query. +

F.13.2. Point-based Earth Distances

The second part of the module relies on representing Earth locations as + values of type point, in which the first component is taken to + represent longitude in degrees, and the second component is taken to + represent latitude in degrees. Points are taken as (longitude, latitude) + and not vice versa because longitude is closer to the intuitive idea of + x-axis and latitude to y-axis. +

A single operator is provided, shown + in Table F-5. +

Table F-5. Point-based Earthdistance Operators

OperatorReturnsDescription
point <@> pointfloat8Gives the distance in statute miles between + two points on the Earth's surface. +

Note that unlike the cube-based part of the module, units + are hardwired here: changing the earth() function will + not affect the results of this operator. +

One disadvantage of the longitude/latitude representation is that + you need to be careful about the edge conditions near the poles + and near +/- 180 degrees of longitude. The cube-based + representation avoids these discontinuities. +


PrevHomeNext
dummy_seclabelUpfile_fdw
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-commands.html b/doc/src/sgml/html/ecpg-commands.html new file mode 100644 index 000000000..8c5c20d02 --- /dev/null +++ b/doc/src/sgml/html/ecpg-commands.html @@ -0,0 +1,547 @@ + +Running SQL Commands
PostgreSQL 9.2.2 Documentation
PrevUpChapter 33. ECPG - Embedded SQL in CNext

33.3. Running SQL Commands

Any SQL command can be run from within an embedded SQL application. + Below are some examples of how to do that. +

33.3.1. Executing SQL Statements

Creating a table: +

EXEC SQL CREATE TABLE foo (number integer, ascii char(16));
+EXEC SQL CREATE UNIQUE INDEX num1 ON foo(number);
+EXEC SQL COMMIT;

+

Inserting rows: +

EXEC SQL INSERT INTO foo (number, ascii) VALUES (9999, 'doodad');
+EXEC SQL COMMIT;

+

Deleting rows: +

EXEC SQL DELETE FROM foo WHERE number = 9999;
+EXEC SQL COMMIT;

+

Updates: +

EXEC SQL UPDATE foo
+    SET ascii = 'foobar'
+    WHERE number = 9999;
+EXEC SQL COMMIT;

+

SELECT statements that return a single result + row can also be executed using + EXEC SQL directly. To handle result sets with + multiple rows, an application has to use a cursor; + see Section 33.3.2 below. (As a special case, an + application can fetch multiple rows at once into an array host + variable; see Section 33.4.4.3.1.) +

Single-row select: +

EXEC SQL SELECT foo INTO :FooBar FROM table1 WHERE ascii = 'doodad';

+

Also, a configuration parameter can be retrieved with the + SHOW command: +

EXEC SQL SHOW search_path INTO :var;

+

The tokens of the form + :something are + host variables, that is, they refer to + variables in the C program. They are explained in Section 33.4. +

33.3.2. Using Cursors

To retrieve a result set holding multiple rows, an application has + to declare a cursor and fetch each row from the cursor. The steps + to use a cursor are the following: declare a cursor, open it, fetch + a row from the cursor, repeat, and finally close it. +

Select using cursors: +

EXEC SQL DECLARE foo_bar CURSOR FOR
+    SELECT number, ascii FROM foo
+    ORDER BY ascii;
+EXEC SQL OPEN foo_bar;
+EXEC SQL FETCH foo_bar INTO :FooBar, DooDad;
+...
+EXEC SQL CLOSE foo_bar;
+EXEC SQL COMMIT;

+

For more details about declaration of the cursor, + see DECLARE, and + see FETCH for FETCH command + details. +

Note: The ECPG DECLARE command does not actually + cause a statement to be sent to the PostgreSQL backend. The + cursor is opened in the backend (using the + backend's DECLARE command) at the point when + the OPEN command is executed. +

33.3.3. Managing Transactions

In the default mode, statements are committed only when + EXEC SQL COMMIT is issued. The embedded SQL + interface also supports autocommit of transactions (similar to + libpq behavior) via the -t + command-line option to ecpg (see ecpg) or via the EXEC SQL SET AUTOCOMMIT TO + ON statement. In autocommit mode, each command is + automatically committed unless it is inside an explicit transaction + block. This mode can be explicitly turned off using EXEC + SQL SET AUTOCOMMIT TO OFF. +

The following transaction management commands are available: + +

EXEC SQL COMMIT

Commit an in-progress transaction. +

EXEC SQL ROLLBACK

Roll back an in-progress transaction. +

EXEC SQL SET AUTOCOMMIT TO ON

Enable autocommit mode. +

SET AUTOCOMMIT TO OFF

Disable autocommit mode. This is the default. +

+

33.3.4. Prepared Statements

When the values to be passed to an SQL statement are not known at + compile time, or the same statement is going to be used many + times, then prepared statements can be useful. +

The statement is prepared using the + command PREPARE. For the values that are not + known yet, use the + placeholder "?": +

EXEC SQL PREPARE stmt1 FROM "SELECT oid, datname FROM pg_database WHERE oid = ?";

+

If a statement returns a single row, the application can + call EXECUTE after + PREPARE to execute the statement, supplying the + actual values for the placeholders with a USING + clause: +

EXEC SQL EXECUTE stmt1 INTO :dboid, :dbname USING 1;

+

If a statement returns multiple rows, the application can use a + cursor declared based on the prepared statement. To bind input + parameters, the cursor must be opened with + a USING clause: +

EXEC SQL PREPARE stmt1 FROM "SELECT oid,datname FROM pg_database WHERE oid > ?";
+EXEC SQL DECLARE foo_bar CURSOR FOR stmt1;
+
+/* when end of result set reached, break out of while loop */
+EXEC SQL WHENEVER NOT FOUND DO BREAK;
+
+EXEC SQL OPEN foo_bar USING 100;
+...
+while (1)
+{
+    EXEC SQL FETCH NEXT FROM foo_bar INTO :dboid, :dbname;
+    ...
+}
+EXEC SQL CLOSE foo_bar;

+

When you don't need the prepared statement anymore, you should + deallocate it: +

EXEC SQL DEALLOCATE PREPARE name;

+

For more details about PREPARE, + see PREPARE. Also + see Section 33.5 for more details about using + placeholders and input parameters. +


PrevHomeNext
Managing Database ConnectionsUpUsing Host Variables
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-concept.html b/doc/src/sgml/html/ecpg-concept.html new file mode 100644 index 000000000..6fe8024ca --- /dev/null +++ b/doc/src/sgml/html/ecpg-concept.html @@ -0,0 +1,264 @@ + +The Concept
PostgreSQL 9.2.2 Documentation
PrevUpChapter 33. ECPG - Embedded SQL in CNext

33.1. The Concept

An embedded SQL program consists of code written in an ordinary + programming language, in this case C, mixed with SQL commands in + specially marked sections. To build the program, the source code (*.pgc) + is first passed through the embedded SQL preprocessor, which converts it + to an ordinary C program (*.c), and afterwards it can be processed by a C + compiler. (For details about the compiling and linking see Section 33.10). + Converted ECPG applications call functions in the libpq library + through the embedded SQL library (ecpglib), and communicate with + the PostgreSQL server using the normal frontend-backend protocol. +

Embedded SQL has advantages over other methods + for handling SQL commands from C code. First, it + takes care of the tedious passing of information to and from + variables in your C program. Second, the SQL + code in the program is checked at build time for syntactical + correctness. Third, embedded SQL in C is + specified in the SQL standard and supported by + many other SQL database systems. The + PostgreSQL implementation is designed to match this + standard as much as possible, and it is usually possible to port + embedded SQL programs written for other SQL + databases to PostgreSQL with relative + ease. +

As already stated, programs written for the embedded + SQL interface are normal C programs with special + code inserted to perform database-related actions. This special + code always has the form: +

EXEC SQL ...;

+ These statements syntactically take the place of a C statement. + Depending on the particular statement, they can appear at the + global level or within a function. Embedded + SQL statements follow the case-sensitivity rules + of normal SQL code, and not those of C. +

The following sections explain all the embedded SQL statements. +


PrevHomeNext
ECPG - Embedded SQL in CUpManaging Database Connections
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-connect.html b/doc/src/sgml/html/ecpg-connect.html new file mode 100644 index 000000000..fd0c83bbc --- /dev/null +++ b/doc/src/sgml/html/ecpg-connect.html @@ -0,0 +1,666 @@ + +Managing Database Connections
PostgreSQL 9.2.2 Documentation
PrevUpChapter 33. ECPG - Embedded SQL in CNext

33.2. Managing Database Connections

This section describes how to open, close, and switch database + connections. +

33.2.1. Connecting to the Database Server

One connects to a database using the following statement: +

EXEC SQL CONNECT TO target [AS connection-name] [USER user-name];

+ The target can be specified in the + following ways: + +

  • dbname[@hostname][:port] +

  • tcp:postgresql://hostname[:port][/dbname][?options] +

  • unix:postgresql://hostname[:port][/dbname][?options] +

  • an SQL string literal containing one of the above forms +

  • a reference to a character variable containing one of the above forms (see examples) +

  • DEFAULT +

+ + If you specify the connection target literally (that is, not + through a variable reference) and you don't quote the value, then + the case-insensitivity rules of normal SQL are applied. In that + case you can also double-quote the individual parameters separately + as needed. In practice, it is probably less error-prone to use a + (single-quoted) string literal or a variable reference. The + connection target DEFAULT initiates a connection + to the default database under the default user name. No separate + user name or connection name can be specified in that case. +

There are also different ways to specify the user name: + +

  • username +

  • username/password +

  • username IDENTIFIED BY password +

  • username USING password +

+ + As above, the parameters username and + password can be an SQL identifier, an + SQL string literal, or a reference to a character variable. +

The connection-name is used to handle + multiple connections in one program. It can be omitted if a + program uses only one connection. The most recently opened + connection becomes the current connection, which is used by default + when an SQL statement is to be executed (see later in this + chapter). +

Here are some examples of CONNECT statements: +

EXEC SQL CONNECT TO mydb@sql.mydomain.com;
+
+EXEC SQL CONNECT TO unix:postgresql://sql.mydomain.com/mydb AS myconnection USER john;
+
+EXEC SQL BEGIN DECLARE SECTION;
+const char *target = "mydb@sql.mydomain.com";
+const char *user = "john";
+EXEC SQL END DECLARE SECTION;
+ ...
+EXEC SQL CONNECT TO :target USER :user;

+ The last form makes use of the variant referred to above as + character variable reference. You will see in later sections how C + variables can be used in SQL statements when you prefix them with a + colon. +

Be advised that the format of the connection target is not + specified in the SQL standard. So if you want to develop portable + applications, you might want to use something based on the last + example above to encapsulate the connection target string + somewhere. +

33.2.2. Choosing a Connection

SQL statements in embedded SQL programs are by default executed on + the current connection, that is, the most recently opened one. If + an application needs to manage multiple connections, then there are + two ways to handle this. +

The first option is to explicitly choose a connection for each SQL + statement, for example: +

EXEC SQL AT connection-name SELECT ...;

+ This option is particularly suitable if the application needs to + use several connections in mixed order. +

If your application uses multiple threads of execution, they cannot share a + connection concurrently. You must either explicitly control access to the connection + (using mutexes) or use a connection for each thread. If each thread uses its own connection, + you will need to use the AT clause to specify which connection the thread will use. +

The second option is to execute a statement to switch the current + connection. That statement is: +

EXEC SQL SET CONNECTION connection-name;

+ This option is particularly convenient if many statements are to be + executed on the same connection. It is not thread-aware. +

Here is an example program managing multiple database connections: +

#include <stdio.h>
+
+EXEC SQL BEGIN DECLARE SECTION;
+    char dbname[1024];
+EXEC SQL END DECLARE SECTION;
+
+int
+main()
+{
+    EXEC SQL CONNECT TO testdb1 AS con1 USER testuser;
+    EXEC SQL CONNECT TO testdb2 AS con2 USER testuser;
+    EXEC SQL CONNECT TO testdb3 AS con3 USER testuser;
+
+    /* This query would be executed in the last opened database "testdb3". */
+    EXEC SQL SELECT current_database() INTO :dbname;
+    printf("current=%s (should be testdb3)\n", dbname);
+
+    /* Using "AT" to run a query in "testdb2" */
+    EXEC SQL AT con2 SELECT current_database() INTO :dbname;
+    printf("current=%s (should be testdb2)\n", dbname);
+
+    /* Switch the current connection to "testdb1". */
+    EXEC SQL SET CONNECTION con1;
+
+    EXEC SQL SELECT current_database() INTO :dbname;
+    printf("current=%s (should be testdb1)\n", dbname);
+
+    EXEC SQL DISCONNECT ALL;
+    return 0;
+}

+ + This example would produce this output: +

current=testdb3 (should be testdb3)
+current=testdb2 (should be testdb2)
+current=testdb1 (should be testdb1)

+

33.2.3. Closing a Connection

To close a connection, use the following statement: +

EXEC SQL DISCONNECT [connection];

+ The connection can be specified + in the following ways: + +

  • connection-name +

  • DEFAULT +

  • CURRENT +

  • ALL +

+ + If no connection name is specified, the current connection is + closed. +

It is good style that an application always explicitly disconnect + from every connection it opened. +


PrevHomeNext
The ConceptUpRunning SQL Commands
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-cpp.html b/doc/src/sgml/html/ecpg-cpp.html new file mode 100644 index 000000000..8c107d648 --- /dev/null +++ b/doc/src/sgml/html/ecpg-cpp.html @@ -0,0 +1,553 @@ + +C++ Applications
PostgreSQL 9.2.2 Documentation
PrevUpChapter 33. ECPG - Embedded SQL in CNext

33.13. C++ Applications

ECPG has some limited support for C++ applications. This section + describes some caveats. +

The ecpg preprocessor takes an input file + written in C (or something like C) and embedded SQL commands, + converts the embedded SQL commands into C language chunks, and + finally generates a .c file. The header file + declarations of the library functions used by the C language chunks + that ecpg generates are wrapped + in extern "C" { ... } blocks when used under + C++, so they should work seamlessly in C++. +

In general, however, the ecpg preprocessor only + understands C; it does not handle the special syntax and reserved + words of the C++ language. So, some embedded SQL code written in + C++ application code that uses complicated features specific to C++ + might fail to be preprocessed correctly or might not work as + expected. +

A safe way to use the embedded SQL code in a C++ application is + hiding the ECPG calls in a C module, which the C++ application code + calls into to access the database, and linking that together with + the rest of the C++ code. See Section 33.13.2 + about that. +

33.13.1. Scope for Host Variables

The ecpg preprocessor understands the scope of + variables in C. In the C language, this is rather simple because + the scopes of variables is based on their code blocks. In C++, + however, the class member variables are referenced in a different + code block from the declared position, so + the ecpg preprocessor will not understand the + scope of the class member variables. +

For example, in the following case, the ecpg + preprocessor cannot find any declaration for the + variable dbname in the test + method, so an error will occur. + +

class TestCpp
+{
+    EXEC SQL BEGIN DECLARE SECTION;
+    char dbname[1024];
+    EXEC SQL END DECLARE SECTION;
+
+  public:
+    TestCpp();
+    void test();
+    ~TestCpp();
+};
+
+TestCpp::TestCpp()
+{
+    EXEC SQL CONNECT TO testdb1;
+}
+
+void Test::test()
+{
+    EXEC SQL SELECT current_database() INTO :dbname;
+    printf("current_database = %s\n", dbname);
+}
+
+TestCpp::~TestCpp()
+{
+    EXEC SQL DISCONNECT ALL;
+}

+ + This code will result in an error like this: +

ecpg test_cpp.pgc
+test_cpp.pgc:28: ERROR: variable "dbname" is not declared

+

To avoid this scope issue, the test method + could be modified to use a local variable as intermediate storage. + But this approach is only a poor workaround, because it uglifies + the code and reduces performance. + +

void TestCpp::test()
+{
+    EXEC SQL BEGIN DECLARE SECTION;
+    char tmp[1024];
+    EXEC SQL END DECLARE SECTION;
+
+    EXEC SQL SELECT current_database() INTO :tmp;
+    strlcpy(dbname, tmp, sizeof(tmp));
+
+    printf("current_database = %s\n", dbname);
+}

+

33.13.2. C++ Application Development with External C Module

If you understand these technical limitations of + the ecpg preprocessor in C++, you might come to + the conclusion that linking C objects and C++ objects at the link + stage to enable C++ applications to use ECPG features could be + better than writing some embedded SQL commands in C++ code + directly. This section describes a way to separate some embedded + SQL commands from C++ application code with a simple example. In + this example, the application is implemented in C++, while C and + ECPG is used to connect to the PostgreSQL server. +

Three kinds of files have to be created: a C file + (*.pgc), a header file, and a C++ file: + +

test_mod.pgc

A sub-routine module to execute SQL commands embedded in C. + It is going to be converted + into test_mod.c by the preprocessor. + +

#include "test_mod.h"
+#include <stdio.h>
+
+void
+db_connect()
+{
+    EXEC SQL CONNECT TO testdb1;
+}
+
+void
+db_test()
+{
+    EXEC SQL BEGIN DECLARE SECTION;
+    char dbname[1024];
+    EXEC SQL END DECLARE SECTION;
+
+    EXEC SQL SELECT current_database() INTO :dbname;
+    printf("current_database = %s\n", dbname);
+}
+
+void
+db_disconnect()
+{
+    EXEC SQL DISCONNECT ALL;
+}

+

test_mod.h

A header file with declarations of the functions in the C + module (test_mod.pgc). It is included by + test_cpp.cpp. This file has to have an + extern "C" block around the declarations, + because it will be linked from the C++ module. + +

#ifdef __cplusplus
+extern "C" {
+#endif
+
+void db_connect();
+void db_test();
+void db_disconnect();
+
+#ifdef __cplusplus
+}
+#endif

+

test_cpp.cpp

The main code for the application, including + the main routine, and in this example a + C++ class. + +

#include "test_mod.h"
+
+class TestCpp
+{
+  public:
+    TestCpp();
+    void test();
+    ~TestCpp();
+};
+
+TestCpp::TestCpp()
+{
+    db_connect();
+}
+
+void
+TestCpp::test()
+{
+    db_test();
+}
+
+TestCpp::~TestCpp()
+{
+    db_disconnect();
+}
+
+int
+main(void)
+{
+    TestCpp *t = new TestCpp();
+
+    t->test();
+    return 0;
+}

+

+

To build the application, proceed as follows. Convert + test_mod.pgc into test_mod.c by + running ecpg, and generate + test_mod.o by compiling + test_mod.c with the C compiler: +

ecpg -o test_mod.c test_mod.pgc
+cc -c test_mod.c -o test_mod.o

+

Next, generate test_cpp.o by compiling + test_cpp.cpp with the C++ compiler:. +

c++ -c test_cpp.cpp -o test_cpp.o

+

Finally, link these object files, test_cpp.o + and test_mod.o, into one executable, using the C++ + compiler driver: +

c++ test_cpp.o test_mod.o -lecpg -o test_cpp

+


PrevHomeNext
Large ObjectsUpEmbedded SQL Commands
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-descriptors.html b/doc/src/sgml/html/ecpg-descriptors.html new file mode 100644 index 000000000..97cf9c184 --- /dev/null +++ b/doc/src/sgml/html/ecpg-descriptors.html @@ -0,0 +1,1824 @@ + +Using Descriptor Areas
PostgreSQL 9.2.2 Documentation
PrevUpChapter 33. ECPG - Embedded SQL in CNext

33.7. Using Descriptor Areas

An SQL descriptor area is a more sophisticated method for processing + the result of a SELECT, FETCH or + a DESCRIBE statement. An SQL descriptor area groups + the data of one row of data together with metadata items into one + data structure. The metadata is particularly useful when executing + dynamic SQL statements, where the nature of the result columns might + not be known ahead of time. PostgreSQL provides two ways to use + Descriptor Areas: the named SQL Descriptor Areas and the C-structure + SQLDAs. +

33.7.1. Named SQL Descriptor Areas

A named SQL descriptor area consists of a header, which contains + information concerning the entire descriptor, and one or more item + descriptor areas, which basically each describe one column in the + result row. +

Before you can use an SQL descriptor area, you need to allocate one: +

EXEC SQL ALLOCATE DESCRIPTOR identifier;

+ The identifier serves as the "variable name" of the + descriptor area. + When you don't need the descriptor anymore, you should deallocate + it: +

EXEC SQL DEALLOCATE DESCRIPTOR identifier;

+

To use a descriptor area, specify it as the storage target in an + INTO clause, instead of listing host variables: +

EXEC SQL FETCH NEXT FROM mycursor INTO SQL DESCRIPTOR mydesc;

+ If the result set is empty, the Descriptor Area will still contain + the metadata from the query, i.e. the field names. +

For not yet executed prepared queries, the DESCRIBE + statement can be used to get the metadata of the result set: +

EXEC SQL BEGIN DECLARE SECTION;
+char *sql_stmt = "SELECT * FROM table1";
+EXEC SQL END DECLARE SECTION;
+
+EXEC SQL PREPARE stmt1 FROM :sql_stmt;
+EXEC SQL DESCRIBE stmt1 INTO SQL DESCRIPTOR mydesc;

+

Before PostgreSQL 9.0, the SQL keyword was optional, + so using DESCRIPTOR and SQL DESCRIPTOR + produced named SQL Descriptor Areas. Now it is mandatory, omitting + the SQL keyword produces SQLDA Descriptor Areas, + see Section 33.7.2. +

In DESCRIBE and FETCH statements, + the INTO and USING keywords can be + used to similarly: they produce the result set and the metadata in a + Descriptor Area. +

Now how do you get the data out of the descriptor area? You can + think of the descriptor area as a structure with named fields. To + retrieve the value of a field from the header and store it into a + host variable, use the following command: +

EXEC SQL GET DESCRIPTOR name :hostvar = field;

+ Currently, there is only one header field defined: + COUNT, which tells how many item + descriptor areas exist (that is, how many columns are contained in + the result). The host variable needs to be of an integer type. To + get a field from the item descriptor area, use the following + command: +

EXEC SQL GET DESCRIPTOR name VALUE num :hostvar = field;

+ num can be a literal integer or a host + variable containing an integer. Possible fields are: + +

CARDINALITY (integer)

number of rows in the result set +

DATA

actual data item (therefore, the data type of this field + depends on the query) +

DATETIME_INTERVAL_CODE (integer)

When TYPE is 9, + DATETIME_INTERVAL_CODE will have a value of + 1 for DATE, + 2 for TIME, + 3 for TIMESTAMP, + 4 for TIME WITH TIME ZONE, or + 5 for TIMESTAMP WITH TIME ZONE. +

DATETIME_INTERVAL_PRECISION (integer)

not implemented +

INDICATOR (integer)

the indicator (indicating a null value or a value truncation) +

KEY_MEMBER (integer)

not implemented +

LENGTH (integer)

length of the datum in characters +

NAME (string)

name of the column +

NULLABLE (integer)

not implemented +

OCTET_LENGTH (integer)

length of the character representation of the datum in bytes +

PRECISION (integer)

precision (for type numeric) +

RETURNED_LENGTH (integer)

length of the datum in characters +

RETURNED_OCTET_LENGTH (integer)

length of the character representation of the datum in bytes +

SCALE (integer)

scale (for type numeric) +

TYPE (integer)

numeric code of the data type of the column +

+

In EXECUTE, DECLARE and OPEN + statements, the effect of the INTO and USING + keywords are different. A Descriptor Area can also be manually built to + provide the input parameters for a query or a cursor and + USING SQL DESCRIPTOR name + is the way to pass the input parameters into a parametrized query. The statement + to build a named SQL Descriptor Area is below: +

EXEC SQL SET DESCRIPTOR name VALUE num field = :hostvar;

+

PostgreSQL supports retrieving more that one record in one FETCH + statement and storing the data in host variables in this case assumes that the + variable is an array. E.g.: +

EXEC SQL BEGIN DECLARE SECTION;
+int id[5];
+EXEC SQL END DECLARE SECTION;
+
+EXEC SQL FETCH 5 FROM mycursor INTO SQL DESCRIPTOR mydesc;
+
+EXEC SQL GET DESCRIPTOR mydesc VALUE 1 :id = DATA;

+ +

33.7.2. SQLDA Descriptor Areas

An SQLDA Descriptor Area is a C language structure which can be also used + to get the result set and the metadata of a query. One structure stores one + record from the result set. +

EXEC SQL include sqlda.h;
+sqlda_t         *mysqlda;
+
+EXEC SQL FETCH 3 FROM mycursor INTO DESCRIPTOR mysqlda;

+ Note that the SQL keyword is omitted. The paragraphs about + the use cases of the INTO and USING + keywords in Section 33.7.1 also apply here with an addition. + In a DESCRIBE statement the DESCRIPTOR + keyword can be completely omitted if the INTO keyword is used: +

EXEC SQL DESCRIBE prepared_statement INTO mysqlda;

+

The general flow of a program that uses SQLDA is: +

  1. Prepare a query, and declare a cursor for it.

  2. Declare an SQLDA for the result rows.

  3. Declare an SQLDA for the input parameters, and initialize them (memory allocation, parameter settings).

  4. Open a cursor with the input SQLDA.

  5. Fetch rows from the cursor, and store them into an output SQLDA.

  6. Read values from the output SQLDA into the host variables (with conversion if necessary).

  7. Close the cursor.

  8. Free the memory area allocated for the input SQLDA.

33.7.2.1. SQLDA Data Structure

SQLDA uses three data structure + types: sqlda_t, sqlvar_t, + and struct sqlname. +

Tip: PostgreSQL's SQLDA has a similar data structure to the one in + IBM DB2 Universal Database, so some technical information on + DB2's SQLDA could help understanding PostgreSQL's one better. +

33.7.2.1.1. sqlda_t Structure

The structure type sqlda_t is the type of the + actual SQLDA. It holds one record. And two or + more sqlda_t structures can be connected in a + linked list with the pointer in + the desc_next field, thus + representing an ordered collection of rows. So, when two or + more rows are fetched, the application can read them by + following the desc_next pointer in + each sqlda_t node. +

The definition of sqlda_t is: +

struct sqlda_struct
+{
+    char            sqldaid[8];
+    long            sqldabc;
+    short           sqln;
+    short           sqld;
+    struct sqlda_struct *desc_next;
+    struct sqlvar_struct sqlvar[1];
+};
+
+typedef struct sqlda_struct sqlda_t;

+ + The meaning of the fields is: + +

sqldaid

It contains the literal string "SQLDA ". +

sqldabc

It contains the size of the allocated space in bytes. +

sqln

It contains the number of input parameters for a parametrized query + case it's passed into OPEN, DECLARE or + EXECUTE statements using the USING + keyword. In case it's used as output of SELECT, + EXECUTE or FETCH statements, + its value is the same as sqld + statement +

sqld

It contains the number of fields in a result set. +

desc_next

If the query returns more than one record, multiple linked + SQLDA structures are returned, and desc_next holds + a pointer to the next entry in the list. +

sqlvar

This is the array of the columns in the result set. +

+

33.7.2.1.2. sqlvar_t Structure

The structure type sqlvar_t holds a column value + and metadata such as type and length. The definition of the type + is: + +

struct sqlvar_struct
+{
+    short          sqltype;
+    short          sqllen;
+    char          *sqldata;
+    short         *sqlind;
+    struct sqlname sqlname;
+};
+
+typedef struct sqlvar_struct sqlvar_t;

+ + The meaning of the fields is: + +

sqltype

Contains the type identifier of the field. For values, + see enum ECPGttype in ecpgtype.h. +

sqllen

Contains the binary length of the field. e.g. 4 bytes for ECPGt_int. +

sqldata

Points to the data. The format of the data is described + in Section 33.4.4. +

sqlind

Points to the null indicator. 0 means not null, -1 means + null. +

sqlname

The name of the field. +

+

33.7.2.1.3. struct sqlname Structure

A struct sqlname structure holds a column name. It + is used as a member of the sqlvar_t structure. The + definition of the structure is: +

#define NAMEDATALEN 64
+
+struct sqlname
+{
+        short           length;
+        char            data[NAMEDATALEN];
+};

+ The meaning of the fields is: +

length

Contains the length of the field name. +

data

Contains the actual field name. +

+

33.7.2.2. Retrieving a Result Set Using an SQLDA

The general steps to retrieve a query result set through an + SQLDA are: +

  1. Declare an sqlda_t structure to receive the result set.

  2. Execute FETCH/EXECUTE/DESCRIBE commands to process a query specifying the declared SQLDA.

  3. Check the number of records in the result set by looking at sqln, a member of the sqlda_t structure.

  4. Get the values of each column from sqlvar[0], sqlvar[1], etc., members of the sqlda_t structure.

  5. Go to next row (sqlda_t structure) by following the desc_next pointer, a member of the sqlda_t structure.

  6. Repeat above as you need.

Here is an example retrieving a result set through an SQLDA. +

First, declare a sqlda_t structure to receive the result set. +

sqlda_t *sqlda1;

+

Next, specify the SQLDA in a command. This is + a FETCH command example. +

EXEC SQL FETCH NEXT FROM cur1 INTO DESCRIPTOR sqlda1;

+

Run a loop following the linked list to retrieve the rows. +

sqlda_t *cur_sqlda;
+
+for (cur_sqlda = sqlda1;
+     cur_sqlda != NULL;
+     cur_sqlda = cur_sqlda->desc_next)
+{
+    ...
+}

+

Inside the loop, run another loop to retrieve each column data + (sqlvar_t structure) of the row. +

for (i = 0; i < cur_sqlda->sqld; i++)
+{
+    sqlvar_t v = cur_sqlda->sqlvar[i];
+    char *sqldata = v.sqldata;
+    short sqllen  = v.sqllen;
+    ...
+}

+

To get a column value, check the sqltype value, + a member of the sqlvar_t structure. Then, switch + to an appropriate way, depending on the column type, to copy + data from the sqlvar field to a host variable. +

char var_buf[1024];
+
+switch (v.sqltype)
+{
+    case ECPGt_char:
+        memset(&var_buf, 0, sizeof(var_buf));
+        memcpy(&var_buf, sqldata, (sizeof(var_buf) <= sqllen ? sizeof(var_buf) - 1 : sqllen));
+        break;
+
+    case ECPGt_int: /* integer */
+        memcpy(&intval, sqldata, sqllen);
+        snprintf(var_buf, sizeof(var_buf), "%d", intval);
+        break;
+
+    ...
+}

+

33.7.2.3. Passing Query Parameters Using an SQLDA

The general steps to use an SQLDA to pass input + parameters to a prepared query are: +

  1. Create a prepared query (prepared statement)

  2. Declare a sqlda_t structure as an input SQLDA.

  3. Allocate memory area (as sqlda_t structure) for the input SQLDA.

  4. Set (copy) input values in the allocated memory.

  5. Open a cursor with specifying the input SQLDA.

Here is an example. +

First, create a prepared statement. +

EXEC SQL BEGIN DECLARE SECTION;
+char query[1024] = "SELECT d.oid, * FROM pg_database d, pg_stat_database s WHERE d.oid = s.datid AND (d.datname = ? OR d.oid = ?)";
+EXEC SQL END DECLARE SECTION;
+
+EXEC SQL PREPARE stmt1 FROM :query;

+

Next, allocate memory for an SQLDA, and set the number of input + parameters in sqln, a member variable of + the sqlda_t structure. When two or more input + parameters are required for the prepared query, the application + has to allocate additional memory space which is calculated by + (nr. of params - 1) * sizeof(sqlvar_t). The example shown here + allocates memory space for two input parameters. +

sqlda_t *sqlda2;
+
+sqlda2 = (sqlda_t *) malloc(sizeof(sqlda_t) + sizeof(sqlvar_t));
+memset(sqlda2, 0, sizeof(sqlda_t) + sizeof(sqlvar_t));
+
+sqlda2->sqln = 2; /* number of input variables */

+

After memory allocation, store the parameter values into the + sqlvar[] array. (This is same array used for + retrieving column values when the SQLDA is receiving a result + set.) In this example, the input parameters + are "postgres", having a string type, + and 1, having an integer type. +

sqlda2->sqlvar[0].sqltype = ECPGt_char;
+sqlda2->sqlvar[0].sqldata = "postgres";
+sqlda2->sqlvar[0].sqllen  = 8;
+
+int intval = 1;
+sqlda2->sqlvar[1].sqltype = ECPGt_int;
+sqlda2->sqlvar[1].sqldata = (char *) &intval;
+sqlda2->sqlvar[1].sqllen  = sizeof(intval);

+

By opening a cursor and specifying the SQLDA that was set up + beforehand, the input parameters are passed to the prepared + statement. +

EXEC SQL OPEN cur1 USING DESCRIPTOR sqlda2;

+

Finally, after using input SQLDAs, the allocated memory space + must be freed explicitly, unlike SQLDAs used for receiving query + results. +

free(sqlda2);

+

33.7.2.4. A Sample Application Using SQLDA

Here is an example program, which describes how to fetch access + statistics of the databases, specified by the input parameters, + from the system catalogs. +

This application joins two system tables, pg_database and + pg_stat_database on the database OID, and also fetches and shows + the database statistics which are retrieved by two input + parameters (a database postgres, and OID 1). +

First, declare an SQLDA for input and an SQLDA for output. +

EXEC SQL include sqlda.h;
+
+sqlda_t *sqlda1; /* an output descriptor */
+sqlda_t *sqlda2; /* an input descriptor  */

+

Next, connect to the database, prepare a statement, and declare a + cursor for the prepared statement. +

int
+main(void)
+{
+    EXEC SQL BEGIN DECLARE SECTION;
+    char query[1024] = "SELECT d.oid,* FROM pg_database d, pg_stat_database s WHERE d.oid=s.datid AND ( d.datname=? OR d.oid=? )";
+    EXEC SQL END DECLARE SECTION;
+
+    EXEC SQL CONNECT TO testdb AS con1 USER testuser;
+
+    EXEC SQL PREPARE stmt1 FROM :query;
+    EXEC SQL DECLARE cur1 CURSOR FOR stmt1;

+

Next, put some values in the input SQLDA for the input + parameters. Allocate memory for the input SQLDA, and set the + number of input parameters to sqln. Store + type, value, and value length into sqltype, + sqldata, and sqllen in the + sqlvar structure. + +

    /* Create SQLDA structure for input parameters. */
+    sqlda2 = (sqlda_t *) malloc(sizeof(sqlda_t) + sizeof(sqlvar_t));
+    memset(sqlda2, 0, sizeof(sqlda_t) + sizeof(sqlvar_t));
+    sqlda2->sqln = 2; /* number of input variables */
+
+    sqlda2->sqlvar[0].sqltype = ECPGt_char;
+    sqlda2->sqlvar[0].sqldata = "postgres";
+    sqlda2->sqlvar[0].sqllen  = 8;
+
+    intval = 1;
+    sqlda2->sqlvar[1].sqltype = ECPGt_int;
+    sqlda2->sqlvar[1].sqldata = (char *)&intval;
+    sqlda2->sqlvar[1].sqllen  = sizeof(intval);

+

After setting up the input SQLDA, open a cursor with the input + SQLDA. + +

    /* Open a cursor with input parameters. */
+    EXEC SQL OPEN cur1 USING DESCRIPTOR sqlda2;

+

Fetch rows into the output SQLDA from the opened cursor. + (Generally, you have to call FETCH repeatedly + in the loop, to fetch all rows in the result set.) +

    while (1)
+    {
+        sqlda_t *cur_sqlda;
+
+        /* Assign descriptor to the cursor  */
+        EXEC SQL FETCH NEXT FROM cur1 INTO DESCRIPTOR sqlda1;

+

Next, retrieve the fetched records from the SQLDA, by following + the linked list of the sqlda_t structure. +

    for (cur_sqlda = sqlda1 ;
+         cur_sqlda != NULL ;
+         cur_sqlda = cur_sqlda->desc_next)
+    {
+        ...

+

Read each columns in the first record. The number of columns is + stored in sqld, the actual data of the first + column is stored in sqlvar[0], both members of + the sqlda_t structure. + +

        /* Print every column in a row. */
+        for (i = 0; i < sqlda1->sqld; i++)
+        {
+            sqlvar_t v = sqlda1->sqlvar[i];
+            char *sqldata = v.sqldata;
+            short sqllen  = v.sqllen;
+
+            strncpy(name_buf, v.sqlname.data, v.sqlname.length);
+            name_buf[v.sqlname.length] = '\0';

+

Now, the column data is stored in the variable v. + Copy every datum into host variables, looking + at v.sqltype for the type of the column. +

            switch (v.sqltype) {
+                int intval;
+                double doubleval;
+                unsigned long long int longlongval;
+
+                case ECPGt_char:
+                    memset(&var_buf, 0, sizeof(var_buf));
+                    memcpy(&var_buf, sqldata, (sizeof(var_buf) <= sqllen ? sizeof(var_buf)-1 : sqllen));
+                    break;
+
+                case ECPGt_int: /* integer */
+                    memcpy(&intval, sqldata, sqllen);
+                    snprintf(var_buf, sizeof(var_buf), "%d", intval);
+                    break;
+
+                ...
+
+                default:
+                    ...
+            }
+
+            printf("%s = %s (type: %d)\n", name_buf, var_buf, v.sqltype);
+        }

+

Close the cursor after processing all of records, and disconnect + from the database. +

    EXEC SQL CLOSE cur1;
+    EXEC SQL COMMIT;
+
+    EXEC SQL DISCONNECT ALL;

+

The whole program is shown + in Example 33-1. +

Example 33-1. Example SQLDA Program

#include <stdlib.h>
+#include <string.h>
+#include <stdlib.h>
+#include <stdio.h>
+#include <unistd.h>
+
+EXEC SQL include sqlda.h;
+
+sqlda_t *sqlda1; /* descriptor for output */
+sqlda_t *sqlda2; /* descriptor for input */
+
+EXEC SQL WHENEVER NOT FOUND DO BREAK;
+EXEC SQL WHENEVER SQLERROR STOP;
+
+int
+main(void)
+{
+    EXEC SQL BEGIN DECLARE SECTION;
+    char query[1024] = "SELECT d.oid,* FROM pg_database d, pg_stat_database s WHERE d.oid=s.datid AND ( d.datname=? OR d.oid=? )";
+
+    int intval;
+    unsigned long long int longlongval;
+    EXEC SQL END DECLARE SECTION;
+
+    EXEC SQL CONNECT TO uptimedb AS con1 USER uptime;
+
+    EXEC SQL PREPARE stmt1 FROM :query;
+    EXEC SQL DECLARE cur1 CURSOR FOR stmt1;
+
+    /* Create a SQLDA structure for an input parameter */
+    sqlda2 = (sqlda_t *)malloc(sizeof(sqlda_t) + sizeof(sqlvar_t));
+    memset(sqlda2, 0, sizeof(sqlda_t) + sizeof(sqlvar_t));
+    sqlda2->sqln = 2; /* a number of input variables */
+
+    sqlda2->sqlvar[0].sqltype = ECPGt_char;
+    sqlda2->sqlvar[0].sqldata = "postgres";
+    sqlda2->sqlvar[0].sqllen  = 8;
+
+    intval = 1;
+    sqlda2->sqlvar[1].sqltype = ECPGt_int;
+    sqlda2->sqlvar[1].sqldata = (char *) &intval;
+    sqlda2->sqlvar[1].sqllen  = sizeof(intval);
+
+    /* Open a cursor with input parameters. */
+    EXEC SQL OPEN cur1 USING DESCRIPTOR sqlda2;
+
+    while (1)
+    {
+        sqlda_t *cur_sqlda;
+
+        /* Assign descriptor to the cursor  */
+        EXEC SQL FETCH NEXT FROM cur1 INTO DESCRIPTOR sqlda1;
+
+        for (cur_sqlda = sqlda1 ;
+             cur_sqlda != NULL ;
+             cur_sqlda = cur_sqlda->desc_next)
+        {
+            int i;
+            char name_buf[1024];
+            char var_buf[1024];
+
+            /* Print every column in a row. */
+            for (i=0 ; i<cur_sqlda->sqld ; i++)
+            {
+                sqlvar_t v = cur_sqlda->sqlvar[i];
+                char *sqldata = v.sqldata;
+                short sqllen  = v.sqllen;
+
+                strncpy(name_buf, v.sqlname.data, v.sqlname.length);
+                name_buf[v.sqlname.length] = '\0';
+
+                switch (v.sqltype)
+                {
+                    case ECPGt_char:
+                        memset(&var_buf, 0, sizeof(var_buf));
+                        memcpy(&var_buf, sqldata, (sizeof(var_buf)<=sqllen ? sizeof(var_buf)-1 : sqllen) );
+                        break;
+
+                    case ECPGt_int: /* integer */
+                        memcpy(&intval, sqldata, sqllen);
+                        snprintf(var_buf, sizeof(var_buf), "%d", intval);
+                        break;
+
+                    case ECPGt_long_long: /* bigint */
+                        memcpy(&longlongval, sqldata, sqllen);
+                        snprintf(var_buf, sizeof(var_buf), "%lld", longlongval);
+                        break;
+
+                    default:
+                    {
+                        int i;
+                        memset(var_buf, 0, sizeof(var_buf));
+                        for (i = 0; i < sqllen; i++)
+                        {
+                            char tmpbuf[16];
+                            snprintf(tmpbuf, sizeof(tmpbuf), "%02x ", (unsigned char) sqldata[i]);
+                            strncat(var_buf, tmpbuf, sizeof(var_buf));
+                        }
+                    }
+                        break;
+                }
+
+                printf("%s = %s (type: %d)\n", name_buf, var_buf, v.sqltype);
+            }
+
+            printf("\n");
+        }
+    }
+
+    EXEC SQL CLOSE cur1;
+    EXEC SQL COMMIT;
+
+    EXEC SQL DISCONNECT ALL;
+
+    return 0;
+}

The output of this example should look something like the + following (some numbers will vary). +

oid = 1 (type: 1)
+datname = template1 (type: 1)
+datdba = 10 (type: 1)
+encoding = 0 (type: 5)
+datistemplate = t (type: 1)
+datallowconn = t (type: 1)
+datconnlimit = -1 (type: 5)
+datlastsysoid = 11510 (type: 1)
+datfrozenxid = 379 (type: 1)
+dattablespace = 1663 (type: 1)
+datconfig =  (type: 1)
+datacl = {=c/uptime,uptime=CTc/uptime} (type: 1)
+datid = 1 (type: 1)
+datname = template1 (type: 1)
+numbackends = 0 (type: 5)
+xact_commit = 113606 (type: 9)
+xact_rollback = 0 (type: 9)
+blks_read = 130 (type: 9)
+blks_hit = 7341714 (type: 9)
+tup_returned = 38262679 (type: 9)
+tup_fetched = 1836281 (type: 9)
+tup_inserted = 0 (type: 9)
+tup_updated = 0 (type: 9)
+tup_deleted = 0 (type: 9)
+
+oid = 11511 (type: 1)
+datname = postgres (type: 1)
+datdba = 10 (type: 1)
+encoding = 0 (type: 5)
+datistemplate = f (type: 1)
+datallowconn = t (type: 1)
+datconnlimit = -1 (type: 5)
+datlastsysoid = 11510 (type: 1)
+datfrozenxid = 379 (type: 1)
+dattablespace = 1663 (type: 1)
+datconfig =  (type: 1)
+datacl =  (type: 1)
+datid = 11511 (type: 1)
+datname = postgres (type: 1)
+numbackends = 0 (type: 5)
+xact_commit = 221069 (type: 9)
+xact_rollback = 18 (type: 9)
+blks_read = 1176 (type: 9)
+blks_hit = 13943750 (type: 9)
+tup_returned = 77410091 (type: 9)
+tup_fetched = 3253694 (type: 9)
+tup_inserted = 0 (type: 9)
+tup_updated = 0 (type: 9)
+tup_deleted = 0 (type: 9)

PrevHomeNext
pgtypes LibraryUpError Handling
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-develop.html b/doc/src/sgml/html/ecpg-develop.html new file mode 100644 index 000000000..22d8957cc --- /dev/null +++ b/doc/src/sgml/html/ecpg-develop.html @@ -0,0 +1,448 @@ + +Internals
PostgreSQL 9.2.2 Documentation
PrevUpChapter 33. ECPG - Embedded SQL in CNext

33.16. Internals

This section explains how ECPG works + internally. This information can occasionally be useful to help + users understand how to use ECPG. +

The first four lines written by ecpg to the + output are fixed lines. Two are comments and two are include + lines necessary to interface to the library. Then the + preprocessor reads through the file and writes output. Normally + it just echoes everything to the output. +

When it sees an EXEC SQL statement, it + intervenes and changes it. The command starts with EXEC + SQL and ends with ;. Everything in + between is treated as an SQL statement and + parsed for variable substitution. +

Variable substitution occurs when a symbol starts with a colon + (:). The variable with that name is looked up + among the variables that were previously declared within a + EXEC SQL DECLARE section. +

The most important function in the library is + ECPGdo, which takes care of executing most + commands. It takes a variable number of arguments. This can easily + add up to 50 or so arguments, and we hope this will not be a + problem on any platform. +

The arguments are: + +

A line number

This is the line number of the original line; used in error + messages only. +

A string

This is the SQL command that is to be issued. + It is modified by the input variables, i.e., the variables that + where not known at compile time but are to be entered in the + command. Where the variables should go the string contains + ?. +

Input variables

Every input variable causes ten arguments to be created. (See below.) +

ECPGt_EOIT

An enum telling that there are no more input + variables. +

Output variables

Every output variable causes ten arguments to be created. + (See below.) These variables are filled by the function. +

ECPGt_EORT

An enum telling that there are no more variables. +

+

For every variable that is part of the SQL + command, the function gets ten arguments: + +

  1. The type as a special symbol. +

  2. A pointer to the value or a pointer to the pointer. +

  3. The size of the variable if it is a char or varchar. +

  4. The number of elements in the array (for array fetches). +

  5. The offset to the next element in the array (for array fetches). +

  6. The type of the indicator variable as a special symbol. +

  7. A pointer to the indicator variable. +

  8. 0 +

  9. The number of elements in the indicator array (for array fetches). +

  10. The offset to the next element in the indicator array (for + array fetches). +

+

Note that not all SQL commands are treated in this way. For + instance, an open cursor statement like: +

EXEC SQL OPEN cursor;

+ is not copied to the output. Instead, the cursor's + DECLARE command is used at the position of the OPEN command + because it indeed opens the cursor. +

Here is a complete example describing the output of the + preprocessor of a file foo.pgc (details might + change with each particular version of the preprocessor): +

EXEC SQL BEGIN DECLARE SECTION;
+int index;
+int result;
+EXEC SQL END DECLARE SECTION;
+...
+EXEC SQL SELECT res INTO :result FROM mytable WHERE index = :index;

+ is translated into: +

/* Processed by ecpg (2.6.0) */
+/* These two include files are added by the preprocessor */
+#include <ecpgtype.h>;
+#include <ecpglib.h>;
+
+/* exec sql begin declare section */
+
+#line 1 "foo.pgc"
+
+ int index;
+ int result;
+/* exec sql end declare section */
+...
+ECPGdo(__LINE__, NULL, "SELECT res FROM mytable WHERE index = ?     ",
+        ECPGt_int,&(index),1L,1L,sizeof(int),
+        ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L, ECPGt_EOIT,
+        ECPGt_int,&(result),1L,1L,sizeof(int),
+        ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L, ECPGt_EORT);
+#line 147 "foo.pgc"

+ (The indentation here is added for readability and not + something the preprocessor does.) +


PrevHomeNext
Informix Compatibility ModeUpThe Information Schema
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-dynamic.html b/doc/src/sgml/html/ecpg-dynamic.html new file mode 100644 index 000000000..7b427367e --- /dev/null +++ b/doc/src/sgml/html/ecpg-dynamic.html @@ -0,0 +1,347 @@ + +Dynamic SQL
PostgreSQL 9.2.2 Documentation
PrevUpChapter 33. ECPG - Embedded SQL in CNext

33.5. Dynamic SQL

In many cases, the particular SQL statements that an application + has to execute are known at the time the application is written. + In some cases, however, the SQL statements are composed at run time + or provided by an external source. In these cases you cannot embed + the SQL statements directly into the C source code, but there is a + facility that allows you to call arbitrary SQL statements that you + provide in a string variable. +

33.5.1. Executing Statements without a Result Set

The simplest way to execute an arbitrary SQL statement is to use + the command EXECUTE IMMEDIATE. For example: +

EXEC SQL BEGIN DECLARE SECTION;
+const char *stmt = "CREATE TABLE test1 (...);";
+EXEC SQL END DECLARE SECTION;
+
+EXEC SQL EXECUTE IMMEDIATE :stmt;

+ EXECUTE IMMEDIATE can be used for SQL + statements that do not return a result set (e.g., + DDL, INSERT, UPDATE, + DELETE). You cannot execute statements that + retrieve data (e.g., SELECT) this way. The + next section describes how to do that. +

33.5.2. Executing a Statement with Input Parameters

A more powerful way to execute arbitrary SQL statements is to + prepare them once and execute the prepared statement as often as + you like. It is also possible to prepare a generalized version of + a statement and then execute specific versions of it by + substituting parameters. When preparing the statement, write + question marks where you want to substitute parameters later. For + example: +

EXEC SQL BEGIN DECLARE SECTION;
+const char *stmt = "INSERT INTO test1 VALUES(?, ?);";
+EXEC SQL END DECLARE SECTION;
+
+EXEC SQL PREPARE mystmt FROM :stmt;
+ ...
+EXEC SQL EXECUTE mystmt USING 42, 'foobar';

+

When you don't need the prepared statement anymore, you should + deallocate it: +

EXEC SQL DEALLOCATE PREPARE name;

+

33.5.3. Executing a Statement with a Result Set

To execute an SQL statement with a single result row, + EXECUTE can be used. To save the result, add + an INTO clause. +

EXEC SQL BEGIN DECLARE SECTION;
+const char *stmt = "SELECT a, b, c FROM test1 WHERE a > ?";
+int v1, v2;
+VARCHAR v3[50];
+EXEC SQL END DECLARE SECTION;
+
+EXEC SQL PREPARE mystmt FROM :stmt;
+ ...
+EXEC SQL EXECUTE mystmt INTO :v1, :v2, :v3 USING 37;

+ An EXECUTE command can have an + INTO clause, a USING clause, + both, or neither. +

If a query is expected to return more than one result row, a + cursor should be used, as in the following example. + (See Section 33.3.2 for more details about the + cursor.) +

EXEC SQL BEGIN DECLARE SECTION;
+char dbaname[128];
+char datname[128];
+char *stmt = "SELECT u.usename as dbaname, d.datname "
+             "  FROM pg_database d, pg_user u "
+             "  WHERE d.datdba = u.usesysid";
+EXEC SQL END DECLARE SECTION;
+
+EXEC SQL CONNECT TO testdb AS con1 USER testuser;
+
+EXEC SQL PREPARE stmt1 FROM :stmt;
+
+EXEC SQL DECLARE cursor1 CURSOR FOR stmt1;
+EXEC SQL OPEN cursor1;
+
+EXEC SQL WHENEVER NOT FOUND DO BREAK;
+
+while (1)
+{
+    EXEC SQL FETCH cursor1 INTO :dbaname,:datname;
+    printf("dbaname=%s, datname=%s\n", dbaname, datname);
+}
+
+EXEC SQL CLOSE cursor1;
+
+EXEC SQL COMMIT;
+EXEC SQL DISCONNECT ALL;

+


PrevHomeNext
Using Host VariablesUppgtypes Library
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-errors.html b/doc/src/sgml/html/ecpg-errors.html new file mode 100644 index 000000000..4e6cbe396 --- /dev/null +++ b/doc/src/sgml/html/ecpg-errors.html @@ -0,0 +1,1408 @@ + +Error Handling
PostgreSQL 9.2.2 Documentation
PrevUpChapter 33. ECPG - Embedded SQL in CNext

33.8. Error Handling

This section describes how you can handle exceptional conditions + and warnings in an embedded SQL program. There are two + nonexclusive facilities for this. + +

  • Callbacks can be configured to handle warning and error + conditions using the WHENEVER command. +

  • Detailed information about the error or warning can be obtained + from the sqlca variable. +

+

33.8.1. Setting Callbacks

One simple method to catch errors and warnings is to set a + specific action to be executed whenever a particular condition + occurs. In general: +

EXEC SQL WHENEVER condition action;

+

condition can be one of the following: + +

SQLERROR

The specified action is called whenever an error occurs during + the execution of an SQL statement. +

SQLWARNING

The specified action is called whenever a warning occurs + during the execution of an SQL statement. +

NOT FOUND

The specified action is called whenever an SQL statement + retrieves or affects zero rows. (This condition is not an + error, but you might be interested in handling it specially.) +

+

action can be one of the following: + +

CONTINUE

This effectively means that the condition is ignored. This is + the default. +

GOTO label
GO TO label

Jump to the specified label (using a C goto + statement). +

SQLPRINT

Print a message to standard error. This is useful for simple + programs or during prototyping. The details of the message + cannot be configured. +

STOP

Call exit(1), which will terminate the + program. +

DO BREAK

Execute the C statement break. This should + only be used in loops or switch statements. +

CALL name (args)
DO name (args)

Call the specified C functions with the specified arguments. +

+ + The SQL standard only provides for the actions + CONTINUE and GOTO (and + GO TO). +

Here is an example that you might want to use in a simple program. + It prints a simple message when a warning occurs and aborts the + program when an error happens: +

EXEC SQL WHENEVER SQLWARNING SQLPRINT;
+EXEC SQL WHENEVER SQLERROR STOP;

+

The statement EXEC SQL WHENEVER is a directive + of the SQL preprocessor, not a C statement. The error or warning + actions that it sets apply to all embedded SQL statements that + appear below the point where the handler is set, unless a + different action was set for the same condition between the first + EXEC SQL WHENEVER and the SQL statement causing + the condition, regardless of the flow of control in the C program. + So neither of the two following C program excerpts will have the + desired effect: +

/*
+ * WRONG
+ */
+int main(int argc, char *argv[])
+{
+    ...
+    if (verbose) {
+        EXEC SQL WHENEVER SQLWARNING SQLPRINT;
+    }
+    ...
+    EXEC SQL SELECT ...;
+    ...
+}

+ +

/*
+ * WRONG
+ */
+int main(int argc, char *argv[])
+{
+    ...
+    set_error_handler();
+    ...
+    EXEC SQL SELECT ...;
+    ...
+}
+
+static void set_error_handler(void)
+{
+    EXEC SQL WHENEVER SQLERROR STOP;
+}

+

33.8.2. sqlca

For more powerful error handling, the embedded SQL interface + provides a global variable with the name sqlca + (SQL communication area) + that has the following structure: +

struct
+{
+    char sqlcaid[8];
+    long sqlabc;
+    long sqlcode;
+    struct
+    {
+        int sqlerrml;
+        char sqlerrmc[SQLERRMC_LEN];
+    } sqlerrm;
+    char sqlerrp[8];
+    long sqlerrd[6];
+    char sqlwarn[8];
+    char sqlstate[5];
+} sqlca;

+ (In a multithreaded program, every thread automatically gets its + own copy of sqlca. This works similarly to the + handling of the standard C global variable + errno.) +

sqlca covers both warnings and errors. If + multiple warnings or errors occur during the execution of a + statement, then sqlca will only contain + information about the last one. +

If no error occurred in the last SQL statement, + sqlca.sqlcode will be 0 and + sqlca.sqlstate will be + "00000". If a warning or error occurred, then + sqlca.sqlcode will be negative and + sqlca.sqlstate will be different from + "00000". A positive + sqlca.sqlcode indicates a harmless condition, + such as that the last query returned zero rows. + sqlcode and sqlstate are two + different error code schemes; details appear below. +

If the last SQL statement was successful, then + sqlca.sqlerrd[1] contains the OID of the + processed row, if applicable, and + sqlca.sqlerrd[2] contains the number of + processed or returned rows, if applicable to the command. +

In case of an error or warning, + sqlca.sqlerrm.sqlerrmc will contain a string + that describes the error. The field + sqlca.sqlerrm.sqlerrml contains the length of + the error message that is stored in + sqlca.sqlerrm.sqlerrmc (the result of + strlen(), not really interesting for a C + programmer). Note that some messages are too long to fit in the + fixed-size sqlerrmc array; they will be truncated. +

In case of a warning, sqlca.sqlwarn[2] is set + to W. (In all other cases, it is set to + something different from W.) If + sqlca.sqlwarn[1] is set to + W, then a value was truncated when it was + stored in a host variable. sqlca.sqlwarn[0] is + set to W if any of the other elements are set + to indicate a warning. +

The fields sqlcaid, + sqlcabc, + sqlerrp, and the remaining elements of + sqlerrd and + sqlwarn currently contain no useful + information. +

The structure sqlca is not defined in the SQL + standard, but is implemented in several other SQL database + systems. The definitions are similar at the core, but if you want + to write portable applications, then you should investigate the + different implementations carefully. +

Here is one example that combines the use of WHENEVER + and sqlca, printing out the contents + of sqlca when an error occurs. This is perhaps + useful for debugging or prototyping applications, before + installing a more "user-friendly" error handler. + +

EXEC SQL WHENEVER SQLERROR CALL print_sqlca();
+
+void
+print_sqlca()
+{
+    fprintf(stderr, "==== sqlca ====\n");
+    fprintf(stderr, "sqlcode: %ld\n", sqlca.sqlcode);
+    fprintf(stderr, "sqlerrm.sqlerrml: %d\n", sqlca.sqlerrm.sqlerrml);
+    fprintf(stderr, "sqlerrm.sqlerrmc: %s\n", sqlca.sqlerrm.sqlerrmc);
+    fprintf(stderr, "sqlerrd: %ld %ld %ld %ld %ld %ld\n", sqlca.sqlerrd[0],sqlca.sqlerrd[1],sqlca.sqlerrd[2],
+                                                          sqlca.sqlerrd[3],sqlca.sqlerrd[4],sqlca.sqlerrd[5]);
+    fprintf(stderr, "sqlwarn: %d %d %d %d %d %d %d %d\n", sqlca.sqlwarn[0], sqlca.sqlwarn[1], sqlca.sqlwarn[2],
+                                                          sqlca.sqlwarn[3], sqlca.sqlwarn[4], sqlca.sqlwarn[5],
+                                                          sqlca.sqlwarn[6], sqlca.sqlwarn[7]);
+    fprintf(stderr, "sqlstate: %5s\n", sqlca.sqlstate);
+    fprintf(stderr, "===============\n");
+}

+ + The result could look as follows (here an error due to a + misspelled table name): + +

==== sqlca ====
+sqlcode: -400
+sqlerrm.sqlerrml: 49
+sqlerrm.sqlerrmc: relation "pg_databasep" does not exist on line 38
+sqlerrd: 0 0 0 0 0 0
+sqlwarn: 0 0 0 0 0 0 0 0
+sqlstate: 42P01
+===============

+

33.8.3. SQLSTATE vs. SQLCODE

The fields sqlca.sqlstate and + sqlca.sqlcode are two different schemes that + provide error codes. Both are derived from the SQL standard, but + SQLCODE has been marked deprecated in the SQL-92 + edition of the standard and has been dropped in later editions. + Therefore, new applications are strongly encouraged to use + SQLSTATE. +

SQLSTATE is a five-character array. The five + characters contain digits or upper-case letters that represent + codes of various error and warning conditions. + SQLSTATE has a hierarchical scheme: the first + two characters indicate the general class of the condition, the + last three characters indicate a subclass of the general + condition. A successful state is indicated by the code + 00000. The SQLSTATE codes are for + the most part defined in the SQL standard. The + PostgreSQL server natively supports + SQLSTATE error codes; therefore a high degree + of consistency can be achieved by using this error code scheme + throughout all applications. For further information see + Appendix A. +

SQLCODE, the deprecated error code scheme, is a + simple integer. A value of 0 indicates success, a positive value + indicates success with additional information, a negative value + indicates an error. The SQL standard only defines the positive + value +100, which indicates that the last command returned or + affected zero rows, and no specific negative values. Therefore, + this scheme can only achieve poor portability and does not have a + hierarchical code assignment. Historically, the embedded SQL + processor for PostgreSQL has assigned + some specific SQLCODE values for its use, which + are listed below with their numeric value and their symbolic name. + Remember that these are not portable to other SQL implementations. + To simplify the porting of applications to the + SQLSTATE scheme, the corresponding + SQLSTATE is also listed. There is, however, no + one-to-one or one-to-many mapping between the two schemes (indeed + it is many-to-many), so you should consult the global + SQLSTATE listing in Appendix A + in each case. +

These are the assigned SQLCODE values: + +

0 (ECPG_NO_ERROR)

Indicates no error. (SQLSTATE 00000) +

100 (ECPG_NOT_FOUND)

This is a harmless condition indicating that the last command + retrieved or processed zero rows, or that you are at the end of + the cursor. (SQLSTATE 02000) +

When processing a cursor in a loop, you could use this code as + a way to detect when to abort the loop, like this: +

while (1)
+{
+    EXEC SQL FETCH ... ;
+    if (sqlca.sqlcode == ECPG_NOT_FOUND)
+        break;
+}

+ But WHENEVER NOT FOUND DO BREAK effectively + does this internally, so there is usually no advantage in + writing this out explicitly. +

-12 (ECPG_OUT_OF_MEMORY)

Indicates that your virtual memory is exhausted. The numeric + value is defined as -ENOMEM. (SQLSTATE + YE001) +

-200 (ECPG_UNSUPPORTED)

Indicates the preprocessor has generated something that the + library does not know about. Perhaps you are running + incompatible versions of the preprocessor and the + library. (SQLSTATE YE002) +

-201 (ECPG_TOO_MANY_ARGUMENTS)

This means that the command specified more host variables than + the command expected. (SQLSTATE 07001 or 07002) +

-202 (ECPG_TOO_FEW_ARGUMENTS)

This means that the command specified fewer host variables than + the command expected. (SQLSTATE 07001 or 07002) +

-203 (ECPG_TOO_MANY_MATCHES)

This means a query has returned multiple rows but the statement + was only prepared to store one result row (for example, because + the specified variables are not arrays). (SQLSTATE 21000) +

-204 (ECPG_INT_FORMAT)

The host variable is of type int and the datum in + the database is of a different type and contains a value that + cannot be interpreted as an int. The library uses + strtol() for this conversion. (SQLSTATE + 42804) +

-205 (ECPG_UINT_FORMAT)

The host variable is of type unsigned int and the + datum in the database is of a different type and contains a + value that cannot be interpreted as an unsigned + int. The library uses strtoul() + for this conversion. (SQLSTATE 42804) +

-206 (ECPG_FLOAT_FORMAT)

The host variable is of type float and the datum + in the database is of another type and contains a value that + cannot be interpreted as a float. The library + uses strtod() for this conversion. + (SQLSTATE 42804) +

-207 (ECPG_NUMERIC_FORMAT)

The host variable is of type numeric and the datum + in the database is of another type and contains a value that + cannot be interpreted as a numeric value. + (SQLSTATE 42804) +

-208 (ECPG_INTERVAL_FORMAT)

The host variable is of type interval and the datum + in the database is of another type and contains a value that + cannot be interpreted as an interval value. + (SQLSTATE 42804) +

-209 (ECPG_DATE_FORMAT)

The host variable is of type date and the datum in + the database is of another type and contains a value that + cannot be interpreted as a date value. + (SQLSTATE 42804) +

-210 (ECPG_TIMESTAMP_FORMAT)

The host variable is of type timestamp and the + datum in the database is of another type and contains a value + that cannot be interpreted as a timestamp value. + (SQLSTATE 42804) +

-211 (ECPG_CONVERT_BOOL)

This means the host variable is of type bool and + the datum in the database is neither 't' nor + 'f'. (SQLSTATE 42804) +

-212 (ECPG_EMPTY)

The statement sent to the PostgreSQL + server was empty. (This cannot normally happen in an embedded + SQL program, so it might point to an internal error.) (SQLSTATE + YE002) +

-213 (ECPG_MISSING_INDICATOR)

A null value was returned and no null indicator variable was + supplied. (SQLSTATE 22002) +

-214 (ECPG_NO_ARRAY)

An ordinary variable was used in a place that requires an + array. (SQLSTATE 42804) +

-215 (ECPG_DATA_NOT_ARRAY)

The database returned an ordinary variable in a place that + requires array value. (SQLSTATE 42804) +

-220 (ECPG_NO_CONN)

The program tried to access a connection that does not exist. + (SQLSTATE 08003) +

-221 (ECPG_NOT_CONN)

The program tried to access a connection that does exist but is + not open. (This is an internal error.) (SQLSTATE YE002) +

-230 (ECPG_INVALID_STMT)

The statement you are trying to use has not been prepared. + (SQLSTATE 26000) +

-239 (ECPG_INFORMIX_DUPLICATE_KEY)

Duplicate key error, violation of unique constraint (Informix + compatibility mode). (SQLSTATE 23505) +

-240 (ECPG_UNKNOWN_DESCRIPTOR)

The descriptor specified was not found. The statement you are + trying to use has not been prepared. (SQLSTATE 33000) +

-241 (ECPG_INVALID_DESCRIPTOR_INDEX)

The descriptor index specified was out of range. (SQLSTATE + 07009) +

-242 (ECPG_UNKNOWN_DESCRIPTOR_ITEM)

An invalid descriptor item was requested. (This is an internal + error.) (SQLSTATE YE002) +

-243 (ECPG_VAR_NOT_NUMERIC)

During the execution of a dynamic statement, the database + returned a numeric value and the host variable was not numeric. + (SQLSTATE 07006) +

-244 (ECPG_VAR_NOT_CHAR)

During the execution of a dynamic statement, the database + returned a non-numeric value and the host variable was numeric. + (SQLSTATE 07006) +

-284 (ECPG_INFORMIX_SUBSELECT_NOT_ONE)

A result of the subquery is not single row (Informix + compatibility mode). (SQLSTATE 21000) +

-400 (ECPG_PGSQL)

Some error caused by the PostgreSQL + server. The message contains the error message from the + PostgreSQL server. +

-401 (ECPG_TRANS)

The PostgreSQL server signaled that + we cannot start, commit, or rollback the transaction. + (SQLSTATE 08007) +

-402 (ECPG_CONNECT)

The connection attempt to the database did not succeed. + (SQLSTATE 08001) +

-403 (ECPG_DUPLICATE_KEY)

Duplicate key error, violation of unique constraint. (SQLSTATE + 23505) +

-404 (ECPG_SUBSELECT_NOT_ONE)

A result for the subquery is not single row. (SQLSTATE 21000) +

-602 (ECPG_WARNING_UNKNOWN_PORTAL)

An invalid cursor name was specified. (SQLSTATE 34000) +

-603 (ECPG_WARNING_IN_TRANSACTION)

Transaction is in progress. (SQLSTATE 25001) +

-604 (ECPG_WARNING_NO_TRANSACTION)

There is no active (in-progress) transaction. (SQLSTATE 25P01) +

-605 (ECPG_WARNING_PORTAL_EXISTS)

An existing cursor name was specified. (SQLSTATE 42P03) +

+


PrevHomeNext
Using Descriptor AreasUpPreprocessor Directives
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-informix-compat.html b/doc/src/sgml/html/ecpg-informix-compat.html new file mode 100644 index 000000000..d463a4963 --- /dev/null +++ b/doc/src/sgml/html/ecpg-informix-compat.html @@ -0,0 +1,2782 @@ + +Informix Compatibility Mode
PostgreSQL 9.2.2 Documentation
PrevUpChapter 33. ECPG - Embedded SQL in CNext

33.15. Informix Compatibility Mode

ecpg can be run in a so-called Informix compatibility mode. If + this mode is active, it tries to behave as if it were the Informix + precompiler for Informix E/SQL. Generally spoken this will allow you to use + the dollar sign instead of the EXEC SQL primitive to introduce + embedded SQL commands.: +

$int j = 3;
+$CONNECT TO :dbname;
+$CREATE TABLE test(i INT PRIMARY KEY, j INT);
+$INSERT INTO test(i, j) VALUES (7, :j);
+$COMMIT;

+

Note: There must not be any white space between the $ + and a following preprocessor directive, that is, + include, define, ifdef, + etc. Otherwise, the preprocessor will parse the token as a host + variable. +

There are two compatibility modes: INFORMIX, INFORMIX_SE +

When linking programs that use this compatibility mode, remember to link + against libcompat that is shipped with ECPG. +

Besides the previously explained syntactic sugar, the Informix compatibility + mode ports some functions for input, output and transformation of data as + well as embedded SQL statements known from E/SQL to ECPG. +

Informix compatibility mode is closely connected to the pgtypeslib library + of ECPG. pgtypeslib maps SQL data types to data types within the C host + program and most of the additional functions of the Informix compatibility + mode allow you to operate on those C host program types. Note however that + the extent of the compatibility is limited. It does not try to copy Informix + behavior; it allows you to do more or less the same operations and gives + you functions that have the same name and the same basic behavior but it is + no drop-in replacement if you are using Informix at the moment. Moreover, + some of the data types are different. For example, + PostgreSQL's datetime and interval types do not + know about ranges like for example YEAR TO MINUTE so you won't + find support in ECPG for that either. +

33.15.1. Additional Types

The Informix-special "string" pseudo-type for storing right-trimmed character string data is now + supported in Informix-mode without using typedef. In fact, in Informix-mode, + ECPG refuses to process source files that contain typedef sometype string; +

EXEC SQL BEGIN DECLARE SECTION;
+string userid; /* this variable will contain trimmed data */
+EXEC SQL END DECLARE SECTION;
+
+EXEC SQL FETCH MYCUR INTO :userid;

+

33.15.2. Additional/Missing Embedded SQL Statements

CLOSE DATABASE

This statement closes the current connection. In fact, this is a + synonym for ECPG's DISCONNECT CURRENT.: +

$CLOSE DATABASE;                /* close the current connection */
+EXEC SQL CLOSE DATABASE;

+

FREE cursor_name

Due to the differences how ECPG works compared to Informix's ESQL/C (i.e. which steps + are purely grammar transformations and which steps rely on the underlying run-time library) + there is no FREE cursor_name statement in ECPG. This is because in ECPG, + DECLARE CURSOR doesn't translate to a function call into + the run-time library that uses to the cursor name. This means that there's no run-time + bookkeeping of SQL cursors in the ECPG run-time library, only in the PostgreSQL server. +

FREE statement_name

FREE statement_name is a synonym for DEALLOCATE PREPARE statement_name. +

+

33.15.3. Informix-compatible SQLDA Descriptor Areas

Informix-compatible mode supports a different structure than the one described in + Section 33.7.2. See below: +

struct sqlvar_compat
+{
+    short   sqltype;
+    int     sqllen;
+    char   *sqldata;
+    short  *sqlind;
+    char   *sqlname;
+    char   *sqlformat;
+    short   sqlitype;
+    short   sqlilen;
+    char   *sqlidata;
+    int     sqlxid;
+    char   *sqltypename;
+    short   sqltypelen;
+    short   sqlownerlen;
+    short   sqlsourcetype;
+    char   *sqlownername;
+    int     sqlsourceid;
+    char   *sqlilongdata;
+    int     sqlflags;
+    void   *sqlreserved;
+};
+
+struct sqlda_compat
+{
+    short  sqld;
+    struct sqlvar_compat *sqlvar;
+    char   desc_name[19];
+    short  desc_occ;
+    struct sqlda_compat *desc_next;
+    void  *reserved;
+};
+
+typedef struct sqlvar_compat    sqlvar_t;
+typedef struct sqlda_compat     sqlda_t;

+

The global properties are: +

sqld

The number of fields in the SQLDA descriptor. +

sqlvar

Pointer to the per-field properties. +

desc_name

Unused, filled with zero-bytes. +

desc_occ

Size of the allocated structure. +

desc_next

Pointer to the next SQLDA structure if the result set contains more than one record. +

reserved

Unused pointer, contains NULL. Kept for Informix-compatibility. +

+ + The per-field properties are below, they are stored in the sqlvar array: + +

sqltype

Type of the field. Constants are in sqltypes.h +

sqllen

Length of the field data. +

sqldata

Pointer to the field data. The pointer is of char * type, + the data pointed by it is in a binary format. Example: +

int intval;
+
+switch (sqldata->sqlvar[i].sqltype)
+{
+    case SQLINTEGER:
+        intval = *(int *)sqldata->sqlvar[i].sqldata;
+        break;
+  ...
+}

+

sqlind

Pointer to the NULL indicator. If returned by DESCRIBE or FETCH then it's always a valid pointer. + If used as input for EXECUTE ... USING sqlda; then NULL-pointer value means + that the value for this field is non-NULL. Otherwise a valid pointer and sqlitype + has to be properly set. Example: +

if (*(int2 *)sqldata->sqlvar[i].sqlind != 0)
+    printf("value is NULL\n");

+

sqlname

Name of the field. 0-terminated string. +

sqlformat

Reserved in Informix, value of PQfformat() for the field. +

sqlitype

Type of the NULL indicator data. It's always SQLSMINT when returning data from the server. + When the SQLDA is used for a parametrized query, the data is treated + according to the set type. +

sqlilen

Length of the NULL indicator data. +

sqlxid

Extended type of the field, result of PQftype(). +

sqltypename
sqltypelen
sqlownerlen
sqlsourcetype
sqlownername
sqlsourceid
sqlflags
sqlreserved

Unused. +

sqlilongdata

It equals to sqldata if sqllen is larger than 32KB. +

+ + Example: +

EXEC SQL INCLUDE sqlda.h;
+
+    sqlda_t        *sqlda; /* This doesn't need to be under embedded DECLARE SECTION */
+
+    EXEC SQL BEGIN DECLARE SECTION;
+    char *prep_stmt = "select * from table1";
+    int i;
+    EXEC SQL END DECLARE SECTION;
+
+    ...
+
+    EXEC SQL PREPARE mystmt FROM :prep_stmt;
+
+    EXEC SQL DESCRIBE mystmt INTO sqlda;
+
+    printf("# of fields: %d\n", sqlda->sqld);
+    for (i = 0; i < sqlda->sqld; i++)
+      printf("field %d: \"%s\"\n", sqlda->sqlvar[i]->sqlname);
+
+    EXEC SQL DECLARE mycursor CURSOR FOR mystmt;
+    EXEC SQL OPEN mycursor;
+    EXEC SQL WHENEVER NOT FOUND GOTO out;
+
+    while (1)
+    {
+      EXEC SQL FETCH mycursor USING sqlda;
+    }
+
+    EXEC SQL CLOSE mycursor;
+
+    free(sqlda); /* The main structure is all to be free(),
+                  * sqlda and sqlda->sqlvar is in one allocated area */

+ For more information, see the sqlda.h header and the + src/interfaces/ecpg/test/compat_informix/sqlda.pgc regression test. +

33.15.4. Additional Functions

decadd

Add two decimal type values. +

int decadd(decimal *arg1, decimal *arg2, decimal *sum);

+ The function receives a pointer to the first operand of type decimal + (arg1), a pointer to the second operand of type decimal + (arg2) and a pointer to a value of type decimal that will + contain the sum (sum). On success, the function returns 0. + ECPG_INFORMIX_NUM_OVERFLOW is returned in case of overflow and + ECPG_INFORMIX_NUM_UNDERFLOW in case of underflow. -1 is returned for + other failures and errno is set to the respective errno number of the + pgtypeslib. +

deccmp

Compare two variables of type decimal. +

int deccmp(decimal *arg1, decimal *arg2);

+ The function receives a pointer to the first decimal value + (arg1), a pointer to the second decimal value + (arg2) and returns an integer value that indicates which is + the bigger value. +

  • 1, if the value that arg1 points to is bigger than the + value that var2 points to +

  • -1, if the value that arg1 points to is smaller than the + value that arg2 points to

  • 0, if the value that arg1 points to and the value that + arg2 points to are equal +

+

deccopy

Copy a decimal value. +

void deccopy(decimal *src, decimal *target);

+ The function receives a pointer to the decimal value that should be + copied as the first argument (src) and a pointer to the + target structure of type decimal (target) as the second + argument. +

deccvasc

Convert a value from its ASCII representation into a decimal type. +

int deccvasc(char *cp, int len, decimal *np);

+ The function receives a pointer to string that contains the string + representation of the number to be converted (cp) as well + as its length len. np is a pointer to the + decimal value that saves the result of the operation. +

Valid formats are for example: + -2, + .794, + +3.44, + 592.49E07 or + -32.84e-4. +

The function returns 0 on success. If overflow or underflow occurred, + ECPG_INFORMIX_NUM_OVERFLOW or + ECPG_INFORMIX_NUM_UNDERFLOW is returned. If the ASCII + representation could not be parsed, + ECPG_INFORMIX_BAD_NUMERIC is returned or + ECPG_INFORMIX_BAD_EXPONENT if this problem occurred while + parsing the exponent. +

deccvdbl

Convert a value of type double to a value of type decimal. +

int deccvdbl(double dbl, decimal *np);

+ The function receives the variable of type double that should be + converted as its first argument (dbl). As the second + argument (np), the function receives a pointer to the + decimal variable that should hold the result of the operation. +

The function returns 0 on success and a negative value if the + conversion failed. +

deccvint

Convert a value of type int to a value of type decimal. +

int deccvint(int in, decimal *np);

+ The function receives the variable of type int that should be + converted as its first argument (in). As the second + argument (np), the function receives a pointer to the + decimal variable that should hold the result of the operation. +

The function returns 0 on success and a negative value if the + conversion failed. +

deccvlong

Convert a value of type long to a value of type decimal. +

int deccvlong(long lng, decimal *np);

+ The function receives the variable of type long that should be + converted as its first argument (lng). As the second + argument (np), the function receives a pointer to the + decimal variable that should hold the result of the operation. +

The function returns 0 on success and a negative value if the + conversion failed. +

decdiv

Divide two variables of type decimal. +

int decdiv(decimal *n1, decimal *n2, decimal *result);

+ The function receives pointers to the variables that are the first + (n1) and the second (n2) operands and + calculates n1/n2. result is a + pointer to the variable that should hold the result of the operation. +

On success, 0 is returned and a negative value if the division fails. + If overflow or underflow occurred, the function returns + ECPG_INFORMIX_NUM_OVERFLOW or + ECPG_INFORMIX_NUM_UNDERFLOW respectively. If an attempt to + divide by zero is observed, the function returns + ECPG_INFORMIX_DIVIDE_ZERO. +

decmul

Multiply two decimal values. +

int decmul(decimal *n1, decimal *n2, decimal *result);

+ The function receives pointers to the variables that are the first + (n1) and the second (n2) operands and + calculates n1*n2. result is a + pointer to the variable that should hold the result of the operation. +

On success, 0 is returned and a negative value if the multiplication + fails. If overflow or underflow occurred, the function returns + ECPG_INFORMIX_NUM_OVERFLOW or + ECPG_INFORMIX_NUM_UNDERFLOW respectively. +

decsub

Subtract one decimal value from another. +

int decsub(decimal *n1, decimal *n2, decimal *result);

+ The function receives pointers to the variables that are the first + (n1) and the second (n2) operands and + calculates n1-n2. result is a + pointer to the variable that should hold the result of the operation. +

On success, 0 is returned and a negative value if the subtraction + fails. If overflow or underflow occurred, the function returns + ECPG_INFORMIX_NUM_OVERFLOW or + ECPG_INFORMIX_NUM_UNDERFLOW respectively. +

dectoasc

Convert a variable of type decimal to its ASCII representation in a C + char* string. +

int dectoasc(decimal *np, char *cp, int len, int right)

+ The function receives a pointer to a variable of type decimal + (np) that it converts to its textual representation. + cp is the buffer that should hold the result of the + operation. The parameter right specifies, how many digits + right of the decimal point should be included in the output. The result + will be rounded to this number of decimal digits. Setting + right to -1 indicates that all available decimal digits + should be included in the output. If the length of the output buffer, + which is indicated by len is not sufficient to hold the + textual representation including the trailing zero byte, only a + single * character is stored in the result and -1 is + returned. +

The function returns either -1 if the buffer cp was too + small or ECPG_INFORMIX_OUT_OF_MEMORY if memory was + exhausted. +

dectodbl

Convert a variable of type decimal to a double. +

int dectodbl(decimal *np, double *dblp);

+ The function receives a pointer to the decimal value to convert + (np) and a pointer to the double variable that + should hold the result of the operation (dblp). +

On success, 0 is returned and a negative value if the conversion + failed. +

dectoint

Convert a variable to type decimal to an integer. +

int dectoint(decimal *np, int *ip);

+ The function receives a pointer to the decimal value to convert + (np) and a pointer to the integer variable that + should hold the result of the operation (ip). +

On success, 0 is returned and a negative value if the conversion + failed. If an overflow occurred, ECPG_INFORMIX_NUM_OVERFLOW + is returned. +

Note that the ECPG implementation differs from the Informix + implementation. Informix limits an integer to the range from -32767 to + 32767, while the limits in the ECPG implementation depend on the + architecture (-INT_MAX .. INT_MAX). +

dectolong

Convert a variable to type decimal to a long integer. +

int dectolong(decimal *np, long *lngp);

+ The function receives a pointer to the decimal value to convert + (np) and a pointer to the long variable that + should hold the result of the operation (lngp). +

On success, 0 is returned and a negative value if the conversion + failed. If an overflow occurred, ECPG_INFORMIX_NUM_OVERFLOW + is returned. +

Note that the ECPG implementation differs from the Informix + implementation. Informix limits a long integer to the range from + -2,147,483,647 to 2,147,483,647, while the limits in the ECPG + implementation depend on the architecture (-LONG_MAX .. + LONG_MAX). +

rdatestr

Converts a date to a C char* string. +

int rdatestr(date d, char *str);

+ The function receives two arguments, the first one is the date to + convert (d and the second one is a pointer to the target + string. The output format is always yyyy-mm-dd, so you need + to allocate at least 11 bytes (including the zero-byte terminator) for the + string. +

The function returns 0 on success and a negative value in case of + error. +

Note that ECPG's implementation differs from the Informix + implementation. In Informix the format can be influenced by setting + environment variables. In ECPG however, you cannot change the output + format. +

rstrdate

Parse the textual representation of a date. +

int rstrdate(char *str, date *d);

+ The function receives the textual representation of the date to convert + (str) and a pointer to a variable of type date + (d). This function does not allow you to specify a format + mask. It uses the default format mask of Informix which is + mm/dd/yyyy. Internally, this function is implemented by + means of rdefmtdate. Therefore, rstrdate is + not faster and if you have the choice you should opt for + rdefmtdate which allows you to specify the format mask + explicitly. +

The function returns the same values as rdefmtdate. +

rtoday

Get the current date. +

void rtoday(date *d);

+ The function receives a pointer to a date variable (d) + that it sets to the current date. +

Internally this function uses the PGTYPESdate_today + function. +

rjulmdy

Extract the values for the day, the month and the year from a variable + of type date. +

int rjulmdy(date d, short mdy[3]);

+ The function receives the date d and a pointer to an array + of 3 short integer values mdy. The variable name indicates + the sequential order: mdy[0] will be set to contain the + number of the month, mdy[1] will be set to the value of the + day and mdy[2] will contain the year. +

The function always returns 0 at the moment. +

Internally the function uses the PGTYPESdate_julmdy + function. +

rdefmtdate

Use a format mask to convert a character string to a value of type + date. +

int rdefmtdate(date *d, char *fmt, char *str);

+ The function receives a pointer to the date value that should hold the + result of the operation (d), the format mask to use for + parsing the date (fmt) and the C char* string containing + the textual representation of the date (str). The textual + representation is expected to match the format mask. However you do not + need to have a 1:1 mapping of the string to the format mask. The + function only analyzes the sequential order and looks for the literals + yy or yyyy that indicate the + position of the year, mm to indicate the position of + the month and dd to indicate the position of the + day. +

The function returns the following values: +

  • 0 - The function terminated successfully. +

  • ECPG_INFORMIX_ENOSHORTDATE - The date does not contain + delimiters between day, month and year. In this case the input + string must be exactly 6 or 8 bytes long but isn't. +

  • ECPG_INFORMIX_ENOTDMY - The format string did not + correctly indicate the sequential order of year, month and day. +

  • ECPG_INFORMIX_BAD_DAY - The input string does not + contain a valid day. +

  • ECPG_INFORMIX_BAD_MONTH - The input string does not + contain a valid month. +

  • ECPG_INFORMIX_BAD_YEAR - The input string does not + contain a valid year. +

+

Internally this function is implemented to use the PGTYPESdate_defmt_asc function. See the reference there for a + table of example input. +

rfmtdate

Convert a variable of type date to its textual representation using a + format mask. +

int rfmtdate(date d, char *fmt, char *str);

+ The function receives the date to convert (d), the format + mask (fmt) and the string that will hold the textual + representation of the date (str). +

On success, 0 is returned and a negative value if an error occurred. +

Internally this function uses the PGTYPESdate_fmt_asc + function, see the reference there for examples. +

rmdyjul

Create a date value from an array of 3 short integers that specify the + day, the month and the year of the date. +

int rmdyjul(short mdy[3], date *d);

+ The function receives the array of the 3 short integers + (mdy) and a pointer to a variable of type date that should + hold the result of the operation. +

Currently the function returns always 0. +

Internally the function is implemented to use the function PGTYPESdate_mdyjul. +

rdayofweek

Return a number representing the day of the week for a date value. +

int rdayofweek(date d);

+ The function receives the date variable d as its only + argument and returns an integer that indicates the day of the week for + this date. +

  • 0 - Sunday +

  • 1 - Monday +

  • 2 - Tuesday +

  • 3 - Wednesday +

  • 4 - Thursday +

  • 5 - Friday +

  • 6 - Saturday +

+

Internally the function is implemented to use the function PGTYPESdate_dayofweek. +

dtcurrent

Retrieve the current timestamp. +

void dtcurrent(timestamp *ts);

+ The function retrieves the current timestamp and saves it into the + timestamp variable that ts points to. +

dtcvasc

Parses a timestamp from its textual representation + into a timestamp variable. +

int dtcvasc(char *str, timestamp *ts);

+ The function receives the string to parse (str) and a + pointer to the timestamp variable that should hold the result of the + operation (ts). +

The function returns 0 on success and a negative value in case of + error. +

Internally this function uses the PGTYPEStimestamp_from_asc function. See the reference there + for a table with example inputs. +

dtcvfmtasc

Parses a timestamp from its textual representation + using a format mask into a timestamp variable. +

dtcvfmtasc(char *inbuf, char *fmtstr, timestamp *dtvalue)

+ The function receives the string to parse (inbuf), the + format mask to use (fmtstr) and a pointer to the timestamp + variable that should hold the result of the operation + (dtvalue). +

This function is implemented by means of the PGTYPEStimestamp_defmt_asc function. See the documentation + there for a list of format specifiers that can be used. +

The function returns 0 on success and a negative value in case of + error. +

dtsub

Subtract one timestamp from another and return a variable of type + interval. +

int dtsub(timestamp *ts1, timestamp *ts2, interval *iv);

+ The function will subtract the timestamp variable that ts2 + points to from the timestamp variable that ts1 points to + and will store the result in the interval variable that iv + points to. +

Upon success, the function returns 0 and a negative value if an + error occurred. +

dttoasc

Convert a timestamp variable to a C char* string. +

int dttoasc(timestamp *ts, char *output);

+ The function receives a pointer to the timestamp variable to convert + (ts) and the string that should hold the result of the + operation output). It converts ts to its + textual representation according to the SQL standard, which is + be YYYY-MM-DD HH:MM:SS. +

Upon success, the function returns 0 and a negative value if an + error occurred. +

dttofmtasc

Convert a timestamp variable to a C char* using a format mask. +

int dttofmtasc(timestamp *ts, char *output, int str_len, char *fmtstr);

+ The function receives a pointer to the timestamp to convert as its + first argument (ts), a pointer to the output buffer + (output), the maximal length that has been allocated for + the output buffer (str_len) and the format mask to + use for the conversion (fmtstr). +

Upon success, the function returns 0 and a negative value if an + error occurred. +

Internally, this function uses the PGTYPEStimestamp_fmt_asc function. See the reference there for + information on what format mask specifiers can be used. +

intoasc

Convert an interval variable to a C char* string. +

int intoasc(interval *i, char *str);

+ The function receives a pointer to the interval variable to convert + (i) and the string that should hold the result of the + operation str). It converts i to its + textual representation according to the SQL standard, which is + be YYYY-MM-DD HH:MM:SS. +

Upon success, the function returns 0 and a negative value if an + error occurred. +

rfmtlong

Convert a long integer value to its textual representation using a + format mask. +

int rfmtlong(long lng_val, char *fmt, char *outbuf);

+ The function receives the long value lng_val, the format + mask fmt and a pointer to the output buffer + outbuf. It converts the long value according to the format + mask to its textual representation. +

The format mask can be composed of the following format specifying + characters: +

  • * (asterisk) - if this position would be blank + otherwise, fill it with an asterisk. +

  • & (ampersand) - if this position would be + blank otherwise, fill it with a zero. +

  • # - turn leading zeroes into blanks. +

  • < - left-justify the number in the string. +

  • , (comma) - group numbers of four or more digits + into groups of three digits separated by a comma. +

  • . (period) - this character separates the + whole-number part of the number from the fractional part. +

  • - (minus) - the minus sign appears if the number + is a negative value. +

  • + (plus) - the plus sign appears if the number is + a positive value. +

  • ( - this replaces the minus sign in front of the + negative number. The minus sign will not appear. +

  • ) - this character replaces the minus and is + printed behind the negative value. +

  • $ - the currency symbol. +

+

rupshift

Convert a string to upper case. +

void rupshift(char *str);

+ The function receives a pointer to the string and transforms every + lower case character to upper case. +

byleng

Return the number of characters in a string without counting trailing + blanks. +

int byleng(char *str, int len);

+ The function expects a fixed-length string as its first argument + (str) and its length as its second argument + (len). It returns the number of significant characters, + that is the length of the string without trailing blanks. +

ldchar

Copy a fixed-length string into a null-terminated string. +

void ldchar(char *src, int len, char *dest);

+ The function receives the fixed-length string to copy + (src), its length (len) and a pointer to the + destination memory (dest). Note that you need to reserve at + least len+1 bytes for the string that dest + points to. The function copies at most len bytes to the new + location (less if the source string has trailing blanks) and adds the + null-terminator. +

rgetmsg

int rgetmsg(int msgnum, char *s, int maxsize);

+ This function exists but is not implemented at the moment! +

rtypalign

int rtypalign(int offset, int type);

+ This function exists but is not implemented at the moment! +

rtypmsize

int rtypmsize(int type, int len);

+ This function exists but is not implemented at the moment! +

rtypwidth

int rtypwidth(int sqltype, int sqllen);

+ This function exists but is not implemented at the moment! +

rsetnull

Set a variable to NULL. +

int rsetnull(int t, char *ptr);

+ The function receives an integer that indicates the type of the + variable and a pointer to the variable itself that is cast to a C + char* pointer. +

The following types exist: +

  • CCHARTYPE - For a variable of type char or char* +

  • CSHORTTYPE - For a variable of type short int +

  • CINTTYPE - For a variable of type int +

  • CBOOLTYPE - For a variable of type boolean +

  • CFLOATTYPE - For a variable of type float +

  • CLONGTYPE - For a variable of type long +

  • CDOUBLETYPE - For a variable of type double +

  • CDECIMALTYPE - For a variable of type decimal +

  • CDATETYPE - For a variable of type date +

  • CDTIMETYPE - For a variable of type timestamp +

+

Here is an example of a call to this function: +

$char c[] = "abc       ";
+$short s = 17;
+$int i = -74874;
+
+rsetnull(CCHARTYPE, (char *) c);
+rsetnull(CSHORTTYPE, (char *) &s);
+rsetnull(CINTTYPE, (char *) &i);

+

risnull

Test if a variable is NULL. +

int risnull(int t, char *ptr);

+ The function receives the type of the variable to test (t) + as well a pointer to this variable (ptr). Note that the + latter needs to be cast to a char*. See the function rsetnull for a list of possible variable types. +

Here is an example of how to use this function: +

$char c[] = "abc       ";
+$short s = 17;
+$int i = -74874;
+
+risnull(CCHARTYPE, (char *) c);
+risnull(CSHORTTYPE, (char *) &s);
+risnull(CINTTYPE, (char *) &i);

+

+

33.15.5. Additional Constants

Note that all constants here describe errors and all of them are defined + to represent negative values. In the descriptions of the different + constants you can also find the value that the constants represent in the + current implementation. However you should not rely on this number. You can + however rely on the fact all of them are defined to represent negative + values. +

ECPG_INFORMIX_NUM_OVERFLOW

Functions return this value if an overflow occurred in a + calculation. Internally it is defined as -1200 (the Informix + definition). +

ECPG_INFORMIX_NUM_UNDERFLOW

Functions return this value if an underflow occurred in a calculation. + Internally it is defined as -1201 (the Informix definition). +

ECPG_INFORMIX_DIVIDE_ZERO

Functions return this value if an attempt to divide by zero is + observed. Internally it is defined as -1202 (the Informix definition). +

ECPG_INFORMIX_BAD_YEAR

Functions return this value if a bad value for a year was found while + parsing a date. Internally it is defined as -1204 (the Informix + definition). +

ECPG_INFORMIX_BAD_MONTH

Functions return this value if a bad value for a month was found while + parsing a date. Internally it is defined as -1205 (the Informix + definition). +

ECPG_INFORMIX_BAD_DAY

Functions return this value if a bad value for a day was found while + parsing a date. Internally it is defined as -1206 (the Informix + definition). +

ECPG_INFORMIX_ENOSHORTDATE

Functions return this value if a parsing routine needs a short date + representation but did not get the date string in the right length. + Internally it is defined as -1209 (the Informix definition). +

ECPG_INFORMIX_DATE_CONVERT

Functions return this value if an error occurred during date + formatting. Internally it is defined as -1210 (the + Informix definition). +

ECPG_INFORMIX_OUT_OF_MEMORY

Functions return this value if memory was exhausted during + their operation. Internally it is defined as -1211 (the + Informix definition). +

ECPG_INFORMIX_ENOTDMY

Functions return this value if a parsing routine was supposed to get a + format mask (like mmddyy) but not all fields were listed + correctly. Internally it is defined as -1212 (the Informix definition). +

ECPG_INFORMIX_BAD_NUMERIC

Functions return this value either if a parsing routine cannot parse + the textual representation for a numeric value because it contains + errors or if a routine cannot complete a calculation involving numeric + variables because at least one of the numeric variables is invalid. + Internally it is defined as -1213 (the Informix definition). +

ECPG_INFORMIX_BAD_EXPONENT

Functions return this value if a parsing routine cannot parse + an exponent. Internally it is defined as -1216 (the + Informix definition). +

ECPG_INFORMIX_BAD_DATE

Functions return this value if a parsing routine cannot parse + a date. Internally it is defined as -1218 (the + Informix definition). +

ECPG_INFORMIX_EXTRA_CHARS

Functions return this value if a parsing routine is passed extra + characters it cannot parse. Internally it is defined as -1264 (the + Informix definition). +

+


PrevHomeNext
WHENEVERUpInternals
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-library.html b/doc/src/sgml/html/ecpg-library.html new file mode 100644 index 000000000..31955d167 --- /dev/null +++ b/doc/src/sgml/html/ecpg-library.html @@ -0,0 +1,355 @@ + +Library Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 33. ECPG - Embedded SQL in CNext

33.11. Library Functions

The libecpg library primarily contains + "hidden" functions that are used to implement the + functionality expressed by the embedded SQL commands. But there + are some functions that can usefully be called directly. Note that + this makes your code unportable. +

  • ECPGdebug(int on, FILE + *stream) turns on debug + logging if called with the first argument non-zero. Debug logging + is done on stream. The log contains + all SQL statements with all the input + variables inserted, and the results from the + PostgreSQL server. This can be very + useful when searching for errors in your SQL + statements. +

    Note: On Windows, if the ecpg libraries and an application are + compiled with different flags, this function call will crash the + application because the internal representation of the + FILE pointers differ. Specifically, + multithreaded/single-threaded, release/debug, and static/dynamic + flags should be the same for the library and all applications using + that library. +

  • ECPGget_PGconn(const char *connection_name) + returns the library database connection handle identified by the given name. + If connection_name is set to NULL, the current + connection handle is returned. If no connection handle can be identified, the function returns + NULL. The returned connection handle can be used to call any other functions + from libpq, if necessary. +

    Note: It is a bad idea to manipulate database connection handles made from ecpg directly + with libpq routines. +

  • ECPGtransactionStatus(const char *connection_name) + returns the current transaction status of the given connection identified by connection_name. + See Section 31.2 and libpq's PQtransactionStatus() for details about the returned status codes. +

  • ECPGstatus(int lineno, + const char* connection_name) + returns true if you are connected to a database and false if not. + connection_name can be NULL + if a single connection is being used. +


PrevHomeNext
Processing Embedded SQL ProgramsUpLarge Objects
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-lo.html b/doc/src/sgml/html/ecpg-lo.html new file mode 100644 index 000000000..b700205c1 --- /dev/null +++ b/doc/src/sgml/html/ecpg-lo.html @@ -0,0 +1,311 @@ + +Large Objects
PostgreSQL 9.2.2 Documentation
PrevUpChapter 33. ECPG - Embedded SQL in CNext

33.12. Large Objects

Large objects are not directly supported by ECPG, but ECPG + application can manipulate large objects through the libpq large + object functions, obtaining the necessary PGconn + object by calling the ECPGget_PGconn() + function. (However, use of + the ECPGget_PGconn() function and touching + PGconn objects directly should be done very carefully + and ideally not mixed with other ECPG database access calls.) +

For more details about the ECPGget_PGconn(), see + Section 33.11. For information about the large + object function interface, see Chapter 32. +

Large object functions have to be called in a transaction block, so + when autocommit is off, BEGIN commands have to + be issued explicitly. +

Example 33-2 shows an example program that + illustrates how to create, write, and read a large object in an + ECPG application. +

Example 33-2. ECPG Program Accessing Large Objects

#include <stdio.h>
+#include <stdlib.h>
+#include <libpq-fe.h>
+#include <libpq/libpq-fs.h>
+
+EXEC SQL WHENEVER SQLERROR STOP;
+
+int
+main(void)
+{
+    PGconn     *conn;
+    Oid         loid;
+    int         fd;
+    char        buf[256];
+    int         buflen = 256;
+    char        buf2[256];
+    int         rc;
+
+    memset(buf, 1, buflen);
+
+    EXEC SQL CONNECT TO testdb AS con1;
+
+    conn = ECPGget_PGconn("con1");
+    printf("conn = %p\n", conn);
+
+    /* create */
+    loid = lo_create(conn, 0);
+    if (loid &lt; 0)
+        printf("lo_create() failed: %s", PQerrorMessage(conn));
+
+    printf("loid = %d\n", loid);
+
+    /* write test */
+    fd = lo_open(conn, loid, INV_READ|INV_WRITE);
+    if (fd &lt; 0)
+        printf("lo_open() failed: %s", PQerrorMessage(conn));
+
+    printf("fd = %d\n", fd);
+
+    rc = lo_write(conn, fd, buf, buflen);
+    if (rc &lt; 0)
+        printf("lo_write() failed\n");
+
+    rc = lo_close(conn, fd);
+    if (rc &lt; 0)
+        printf("lo_close() failed: %s", PQerrorMessage(conn));
+
+    /* read test */
+    fd = lo_open(conn, loid, INV_READ);
+    if (fd &lt; 0)
+        printf("lo_open() failed: %s", PQerrorMessage(conn));
+
+    printf("fd = %d\n", fd);
+
+    rc = lo_read(conn, fd, buf2, buflen);
+    if (rc &lt; 0)
+        printf("lo_read() failed\n");
+
+    rc = lo_close(conn, fd);
+    if (rc &lt; 0)
+        printf("lo_close() failed: %s", PQerrorMessage(conn));
+
+    /* check */
+    rc = memcmp(buf, buf2, buflen);
+    printf("memcmp() = %d\n", rc);
+
+    /* cleanup */
+    rc = lo_unlink(conn, loid);
+    if (rc &lt; 0)
+        printf("lo_unlink() failed: %s", PQerrorMessage(conn));
+
+    EXEC SQL COMMIT;
+    EXEC SQL DISCONNECT ALL;
+    return 0;
+}

PrevHomeNext
Library FunctionsUpC++ Applications
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-pgtypes.html b/doc/src/sgml/html/ecpg-pgtypes.html new file mode 100644 index 000000000..8eefd2d41 --- /dev/null +++ b/doc/src/sgml/html/ecpg-pgtypes.html @@ -0,0 +1,3286 @@ + +pgtypes Library
PostgreSQL 9.2.2 Documentation
PrevUpChapter 33. ECPG - Embedded SQL in CNext

33.6. pgtypes Library

The pgtypes library maps PostgreSQL database + types to C equivalents that can be used in C programs. It also offers + functions to do basic calculations with those types within C, i.e., without + the help of the PostgreSQL server. See the + following example: +

EXEC SQL BEGIN DECLARE SECTION;
+   date date1;
+   timestamp ts1, tsout;
+   interval iv1;
+   char *out;
+EXEC SQL END DECLARE SECTION;
+
+PGTYPESdate_today(&date1);
+EXEC SQL SELECT started, duration INTO :ts1, :iv1 FROM datetbl WHERE d=:date1;
+PGTYPEStimestamp_add_interval(&ts1, &iv1, &tsout);
+out = PGTYPEStimestamp_to_asc(&tsout);
+printf("Started + duration: %s\n", out);
+free(out);

+

33.6.1. The numeric Type

The numeric type offers to do calculations with arbitrary precision. See + Section 8.1 for the equivalent type in the + PostgreSQL server. Because of the arbitrary precision this + variable needs to be able to expand and shrink dynamically. That's why you + can only create numeric variables on the heap, by means of the + PGTYPESnumeric_new and PGTYPESnumeric_free + functions. The decimal type, which is similar but limited in precision, + can be created on the stack as well as on the heap. +

The following functions can be used to work with the numeric type: +

PGTYPESnumeric_new

Request a pointer to a newly allocated numeric variable. +

numeric *PGTYPESnumeric_new(void);

+

PGTYPESnumeric_free

Free a numeric type, release all of its memory. +

void PGTYPESnumeric_free(numeric *var);

+

PGTYPESnumeric_from_asc

Parse a numeric type from its string notation. +

numeric *PGTYPESnumeric_from_asc(char *str, char **endptr);

+ Valid formats are for example: + -2, + .794, + +3.44, + 592.49E07 or + -32.84e-4. + If the value could be parsed successfully, a valid pointer is returned, + else the NULL pointer. At the moment ECPG always parses the complete + string and so it currently does not support to store the address of the + first invalid character in *endptr. You can safely + set endptr to NULL. +

PGTYPESnumeric_to_asc

Returns a pointer to a string allocated by malloc that contains the string + representation of the numeric type num. +

char *PGTYPESnumeric_to_asc(numeric *num, int dscale);

+ The numeric value will be printed with dscale decimal + digits, with rounding applied if necessary. +

PGTYPESnumeric_add

Add two numeric variables into a third one. +

int PGTYPESnumeric_add(numeric *var1, numeric *var2, numeric *result);

+ The function adds the variables var1 and + var2 into the result variable + result. + The function returns 0 on success and -1 in case of error. +

PGTYPESnumeric_sub

Subtract two numeric variables and return the result in a third one. +

int PGTYPESnumeric_sub(numeric *var1, numeric *var2, numeric *result);

+ The function subtracts the variable var2 from + the variable var1. The result of the operation is + stored in the variable result. + The function returns 0 on success and -1 in case of error. +

PGTYPESnumeric_mul

Multiply two numeric variables and return the result in a third one. +

int PGTYPESnumeric_mul(numeric *var1, numeric *var2, numeric *result);

+ The function multiplies the variables var1 and + var2. The result of the operation is stored in the + variable result. + The function returns 0 on success and -1 in case of error. +

PGTYPESnumeric_div

Divide two numeric variables and return the result in a third one. +

int PGTYPESnumeric_div(numeric *var1, numeric *var2, numeric *result);

+ The function divides the variables var1 by + var2. The result of the operation is stored in the + variable result. + The function returns 0 on success and -1 in case of error. +

PGTYPESnumeric_cmp

Compare two numeric variables. +

int PGTYPESnumeric_cmp(numeric *var1, numeric *var2)

+ This function compares two numeric variables. In case of error, + INT_MAX is returned. On success, the function + returns one of three possible results: +

  • 1, if var1 is bigger than var2 +

  • -1, if var1 is smaller than var2 +

  • 0, if var1 and var2 are equal +

+

PGTYPESnumeric_from_int

Convert an int variable to a numeric variable. +

int PGTYPESnumeric_from_int(signed int int_val, numeric *var);

+ This function accepts a variable of type signed int and stores it + in the numeric variable var. Upon success, 0 is returned and + -1 in case of a failure. +

PGTYPESnumeric_from_long

Convert a long int variable to a numeric variable. +

int PGTYPESnumeric_from_long(signed long int long_val, numeric *var);

+ This function accepts a variable of type signed long int and stores it + in the numeric variable var. Upon success, 0 is returned and + -1 in case of a failure. +

PGTYPESnumeric_copy

Copy over one numeric variable into another one. +

int PGTYPESnumeric_copy(numeric *src, numeric *dst);

+ This function copies over the value of the variable that + src points to into the variable that dst + points to. It returns 0 on success and -1 if an error occurs. +

PGTYPESnumeric_from_double

Convert a variable of type double to a numeric. +

int  PGTYPESnumeric_from_double(double d, numeric *dst);

+ This function accepts a variable of type double and stores the result + in the variable that dst points to. It returns 0 on success + and -1 if an error occurs. +

PGTYPESnumeric_to_double

Convert a variable of type numeric to double. +

int PGTYPESnumeric_to_double(numeric *nv, double *dp)

+ The function converts the numeric value from the variable that + nv points to into the double variable that dp points + to. It returns 0 on success and -1 if an error occurs, including + overflow. On overflow, the global variable errno will be set + to PGTYPES_NUM_OVERFLOW additionally. +

PGTYPESnumeric_to_int

Convert a variable of type numeric to int. +

int PGTYPESnumeric_to_int(numeric *nv, int *ip);

+ The function converts the numeric value from the variable that + nv points to into the integer variable that ip + points to. It returns 0 on success and -1 if an error occurs, including + overflow. On overflow, the global variable errno will be set + to PGTYPES_NUM_OVERFLOW additionally. +

PGTYPESnumeric_to_long

Convert a variable of type numeric to long. +

int PGTYPESnumeric_to_long(numeric *nv, long *lp);

+ The function converts the numeric value from the variable that + nv points to into the long integer variable that + lp points to. It returns 0 on success and -1 if an error + occurs, including overflow. On overflow, the global variable + errno will be set to PGTYPES_NUM_OVERFLOW + additionally. +

PGTYPESnumeric_to_decimal

Convert a variable of type numeric to decimal. +

int PGTYPESnumeric_to_decimal(numeric *src, decimal *dst);

+ The function converts the numeric value from the variable that + src points to into the decimal variable that + dst points to. It returns 0 on success and -1 if an error + occurs, including overflow. On overflow, the global variable + errno will be set to PGTYPES_NUM_OVERFLOW + additionally. +

PGTYPESnumeric_from_decimal

Convert a variable of type decimal to numeric. +

int PGTYPESnumeric_from_decimal(decimal *src, numeric *dst);

+ The function converts the decimal value from the variable that + src points to into the numeric variable that + dst points to. It returns 0 on success and -1 if an error + occurs. Since the decimal type is implemented as a limited version of + the numeric type, overflow cannot occur with this conversion. +

+

33.6.2. The date Type

The date type in C enables your programs to deal with data of the SQL type + date. See Section 8.5 for the equivalent type in the + PostgreSQL server. +

The following functions can be used to work with the date type: +

PGTYPESdate_from_timestamp

Extract the date part from a timestamp. +

date PGTYPESdate_from_timestamp(timestamp dt);

+ The function receives a timestamp as its only argument and returns the + extracted date part from this timestamp. +

PGTYPESdate_from_asc

Parse a date from its textual representation. +

date PGTYPESdate_from_asc(char *str, char **endptr);

+ The function receives a C char* string str and a pointer to + a C char* string endptr. At the moment ECPG always parses + the complete string and so it currently does not support to store the + address of the first invalid character in *endptr. + You can safely set endptr to NULL. +

Note that the function always assumes MDY-formatted dates and there is + currently no variable to change that within ECPG. +

Table 33-2 shows the allowed input formats. +

Table 33-2. Valid Input Formats for PGTYPESdate_from_asc

InputResult
January 8, 1999January 8, 1999
1999-01-08January 8, 1999
1/8/1999January 8, 1999
1/18/1999January 18, 1999
01/02/03February 1, 2003
1999-Jan-08January 8, 1999
Jan-08-1999January 8, 1999
08-Jan-1999January 8, 1999
99-Jan-08January 8, 1999
08-Jan-99January 8, 1999
08-Jan-06January 8, 2006
Jan-08-99January 8, 1999
19990108ISO 8601; January 8, 1999
990108ISO 8601; January 8, 1999
1999.008year and day of year
J2451187Julian day
January 8, 99 BCyear 99 before the Common Era
PGTYPESdate_to_asc

Return the textual representation of a date variable. +

char *PGTYPESdate_to_asc(date dDate);

+ The function receives the date dDate as its only parameter. + It will output the date in the form 1999-01-18, i.e., in the + YYYY-MM-DD format. +

PGTYPESdate_julmdy

Extract the values for the day, the month and the year from a variable + of type date. +

void PGTYPESdate_julmdy(date d, int *mdy);

+ + The function receives the date d and a pointer to an array + of 3 integer values mdy. The variable name indicates + the sequential order: mdy[0] will be set to contain the + number of the month, mdy[1] will be set to the value of the + day and mdy[2] will contain the year. +

PGTYPESdate_mdyjul

Create a date value from an array of 3 integers that specify the + day, the month and the year of the date. +

void PGTYPESdate_mdyjul(int *mdy, date *jdate);

+ The function receives the array of the 3 integers (mdy) as + its first argument and as its second argument a pointer to a variable + of type date that should hold the result of the operation. +

PGTYPESdate_dayofweek

Return a number representing the day of the week for a date value. +

int PGTYPESdate_dayofweek(date d);

+ The function receives the date variable d as its only + argument and returns an integer that indicates the day of the week for + this date. +

  • 0 - Sunday +

  • 1 - Monday +

  • 2 - Tuesday +

  • 3 - Wednesday +

  • 4 - Thursday +

  • 5 - Friday +

  • 6 - Saturday +

+

PGTYPESdate_today

Get the current date. +

void PGTYPESdate_today(date *d);

+ The function receives a pointer to a date variable (d) + that it sets to the current date. +

PGTYPESdate_fmt_asc

Convert a variable of type date to its textual representation using a + format mask. +

int PGTYPESdate_fmt_asc(date dDate, char *fmtstring, char *outbuf);

+ The function receives the date to convert (dDate), the + format mask (fmtstring) and the string that will hold the + textual representation of the date (outbuf). +

On success, 0 is returned and a negative value if an error occurred. +

The following literals are the field specifiers you can use: +

  • dd - The number of the day of the month. +

  • mm - The number of the month of the year. +

  • yy - The number of the year as a two digit number. +

  • yyyy - The number of the year as a four digit number. +

  • ddd - The name of the day (abbreviated). +

  • mmm - The name of the month (abbreviated). +

+ All other characters are copied 1:1 to the output string. +

Table 33-3 indicates a few possible formats. This will give + you an idea of how to use this function. All output lines are based on + the same date: November 23, 1959. +

Table 33-3. Valid Input Formats for PGTYPESdate_fmt_asc

FormatResult
mmddyy112359
ddmmyy231159
yymmdd591123
yy/mm/dd59/11/23
yy mm dd59 11 23
yy.mm.dd59.11.23
.mm.yyyy.dd..11.1959.23.
mmm. dd, yyyyNov. 23, 1959
mmm dd yyyyNov 23 1959
yyyy dd mm1959 23 11
ddd, mmm. dd, yyyyMon, Nov. 23, 1959
(ddd) mmm. dd, yyyy(Mon) Nov. 23, 1959
PGTYPESdate_defmt_asc

Use a format mask to convert a C char* string to a value of type + date. +

int PGTYPESdate_defmt_asc(date *d, char *fmt, char *str);

+ + The function receives a pointer to the date value that should hold the + result of the operation (d), the format mask to use for + parsing the date (fmt) and the C char* string containing + the textual representation of the date (str). The textual + representation is expected to match the format mask. However you do not + need to have a 1:1 mapping of the string to the format mask. The + function only analyzes the sequential order and looks for the literals + yy or yyyy that indicate the + position of the year, mm to indicate the position of + the month and dd to indicate the position of the + day. +

Table 33-4 indicates a few possible formats. This will give + you an idea of how to use this function. +

Table 33-4. Valid Input Formats for rdefmtdate

FormatStringResult
ddmmyy21-2-541954-02-21
ddmmyy2-12-541954-12-02
ddmmyy201119541954-11-20
ddmmyy1304641964-04-13
mmm.dd.yyyyMAR-12-19671967-03-12
yy/mm/dd1954, February 3rd1954-02-03
mmm.dd.yyyy0412691969-04-12
yy/mm/ddIn the year 2525, in the month of July, mankind will be alive on the 28th day2525-07-28
dd-mm-yyI said on the 28th of July in the year 25252525-07-28
mmm.dd.yyyy9/14/581958-09-14
yy/mm/dd47/03/291947-03-29
mmm.dd.yyyyoct 28 19751975-10-28
mmddyyNov 14th, 19851985-11-14

+

33.6.3. The timestamp Type

The timestamp type in C enables your programs to deal with data of the SQL + type timestamp. See Section 8.5 for the equivalent + type in the PostgreSQL server. +

The following functions can be used to work with the timestamp type: +

PGTYPEStimestamp_from_asc

Parse a timestamp from its textual representation into a timestamp + variable. +

timestamp PGTYPEStimestamp_from_asc(char *str, char **endptr);

+ The function receives the string to parse (str) and a + pointer to a C char* (endptr). + At the moment ECPG always parses + the complete string and so it currently does not support to store the + address of the first invalid character in *endptr. + You can safely set endptr to NULL. +

The function returns the parsed timestamp on success. On error, + PGTYPESInvalidTimestamp is returned and errno is + set to PGTYPES_TS_BAD_TIMESTAMP. See PGTYPESInvalidTimestamp for important notes on this value. +

In general, the input string can contain any combination of an allowed + date specification, a whitespace character and an allowed time + specification. Note that time zones are not supported by ECPG. It can + parse them but does not apply any calculation as the + PostgreSQL server does for example. Timezone + specifiers are silently discarded. +

Table 33-5 contains a few examples for input strings. +

Table 33-5. Valid Input Formats for PGTYPEStimestamp_from_asc

InputResult
1999-01-08 04:05:061999-01-08 04:05:06
January 8 04:05:06 1999 PST1999-01-08 04:05:06
1999-Jan-08 04:05:06.789-81999-01-08 04:05:06.789 (time zone specifier ignored)
J2451187 04:05-08:001999-01-08 04:05:00 (time zone specifier ignored)
PGTYPEStimestamp_to_asc

Converts a date to a C char* string. +

char *PGTYPEStimestamp_to_asc(timestamp tstamp);

+ The function receives the timestamp tstamp as + its only argument and returns an allocated string that contains the + textual representation of the timestamp. +

PGTYPEStimestamp_current

Retrieve the current timestamp. +

void PGTYPEStimestamp_current(timestamp *ts);

+ The function retrieves the current timestamp and saves it into the + timestamp variable that ts points to. +

PGTYPEStimestamp_fmt_asc

Convert a timestamp variable to a C char* using a format mask. +

int PGTYPEStimestamp_fmt_asc(timestamp *ts, char *output, int str_len, char *fmtstr);

+ The function receives a pointer to the timestamp to convert as its + first argument (ts), a pointer to the output buffer + (output), the maximal length that has been allocated for + the output buffer (str_len) and the format mask to + use for the conversion (fmtstr). +

Upon success, the function returns 0 and a negative value if an + error occurred. +

You can use the following format specifiers for the format mask. The + format specifiers are the same ones that are used in the + strftime function in libc. Any + non-format specifier will be copied into the output buffer. + +

  • %A - is replaced by national representation of + the full weekday name. +

  • %a - is replaced by national representation of + the abbreviated weekday name. +

  • %B - is replaced by national representation of + the full month name. +

  • %b - is replaced by national representation of + the abbreviated month name. +

  • %C - is replaced by (year / 100) as decimal + number; single digits are preceded by a zero. +

  • %c - is replaced by national representation of + time and date. +

  • %D - is equivalent to + %m/%d/%y. +

  • %d - is replaced by the day of the month as a + decimal number (01-31). +

  • %E* %O* - POSIX locale + extensions. The sequences + %Ec + %EC + %Ex + %EX + %Ey + %EY + %Od + %Oe + %OH + %OI + %Om + %OM + %OS + %Ou + %OU + %OV + %Ow + %OW + %Oy + are supposed to provide alternative representations. +

    Additionally %OB implemented to represent + alternative months names (used standalone, without day mentioned). +

  • %e - is replaced by the day of month as a decimal + number (1-31); single digits are preceded by a blank. +

  • %F - is equivalent to %Y-%m-%d. +

  • %G - is replaced by a year as a decimal number + with century. This year is the one that contains the greater part of + the week (Monday as the first day of the week). +

  • %g - is replaced by the same year as in + %G, but as a decimal number without century + (00-99). +

  • %H - is replaced by the hour (24-hour clock) as a + decimal number (00-23). +

  • %h - the same as %b. +

  • %I - is replaced by the hour (12-hour clock) as a + decimal number (01-12). +

  • %j - is replaced by the day of the year as a + decimal number (001-366). +

  • %k - is replaced by the hour (24-hour clock) as a + decimal number (0-23); single digits are preceded by a blank. +

  • %l - is replaced by the hour (12-hour clock) as a + decimal number (1-12); single digits are preceded by a blank. +

  • %M - is replaced by the minute as a decimal + number (00-59). +

  • %m - is replaced by the month as a decimal number + (01-12). +

  • %n - is replaced by a newline. +

  • %O* - the same as %E*. +

  • %p - is replaced by national representation of + either "ante meridiem" or "post meridiem" as appropriate. +

  • %R - is equivalent to %H:%M. +

  • %r - is equivalent to %I:%M:%S + %p. +

  • %S - is replaced by the second as a decimal + number (00-60). +

  • %s - is replaced by the number of seconds since + the Epoch, UTC. +

  • %T - is equivalent to %H:%M:%S +

  • %t - is replaced by a tab. +

  • %U - is replaced by the week number of the year + (Sunday as the first day of the week) as a decimal number (00-53). +

  • %u - is replaced by the weekday (Monday as the + first day of the week) as a decimal number (1-7). +

  • %V - is replaced by the week number of the year + (Monday as the first day of the week) as a decimal number (01-53). + If the week containing January 1 has four or more days in the new + year, then it is week 1; otherwise it is the last week of the + previous year, and the next week is week 1. +

  • %v - is equivalent to + %e-%b-%Y. +

  • %W - is replaced by the week number of the year + (Monday as the first day of the week) as a decimal number (00-53). +

  • %w - is replaced by the weekday (Sunday as the + first day of the week) as a decimal number (0-6). +

  • %X - is replaced by national representation of + the time. +

  • %x - is replaced by national representation of + the date. +

  • %Y - is replaced by the year with century as a + decimal number. +

  • %y - is replaced by the year without century as a + decimal number (00-99). +

  • %Z - is replaced by the time zone name. +

  • %z - is replaced by the time zone offset from + UTC; a leading plus sign stands for east of UTC, a minus sign for + west of UTC, hours and minutes follow with two digits each and no + delimiter between them (common form for RFC 822 date headers). +

  • %+ - is replaced by national representation of + the date and time. +

  • %-* - GNU libc extension. Do not do any padding + when performing numerical outputs. +

  • $_* - GNU libc extension. Explicitly specify space for padding. +

  • %0* - GNU libc extension. Explicitly specify zero + for padding. +

  • %% - is replaced by %. +

+

PGTYPEStimestamp_sub

Subtract one timestamp from another one and save the result in a + variable of type interval. +

int PGTYPEStimestamp_sub(timestamp *ts1, timestamp *ts2, interval *iv);

+ The function will subtract the timestamp variable that ts2 + points to from the timestamp variable that ts1 points to + and will store the result in the interval variable that iv + points to. +

Upon success, the function returns 0 and a negative value if an + error occurred. +

PGTYPEStimestamp_defmt_asc

Parse a timestamp value from its textual representation using a + formatting mask. +

int PGTYPEStimestamp_defmt_asc(char *str, char *fmt, timestamp *d);

+ The function receives the textual representation of a timestamp in the + variable str as well as the formatting mask to use in the + variable fmt. The result will be stored in the variable + that d points to. +

If the formatting mask fmt is NULL, the function will fall + back to the default formatting mask which is %Y-%m-%d + %H:%M:%S. +

This is the reverse function to PGTYPEStimestamp_fmt_asc. See the documentation there in + order to find out about the possible formatting mask entries. +

PGTYPEStimestamp_add_interval

Add an interval variable to a timestamp variable. +

int PGTYPEStimestamp_add_interval(timestamp *tin, interval *span, timestamp *tout);

+ The function receives a pointer to a timestamp variable tin + and a pointer to an interval variable span. It adds the + interval to the timestamp and saves the resulting timestamp in the + variable that tout points to. +

Upon success, the function returns 0 and a negative value if an + error occurred. +

PGTYPEStimestamp_sub_interval

Subtract an interval variable from a timestamp variable. +

int PGTYPEStimestamp_sub_interval(timestamp *tin, interval *span, timestamp *tout);

+ The function subtracts the interval variable that span + points to from the timestamp variable that tin points to + and saves the result into the variable that tout points + to. +

Upon success, the function returns 0 and a negative value if an + error occurred. +

+

33.6.4. The interval Type

The interval type in C enables your programs to deal with data of the SQL + type interval. See Section 8.5 for the equivalent + type in the PostgreSQL server. +

The following functions can be used to work with the interval type: +

PGTYPESinterval_new

Return a pointer to a newly allocated interval variable. +

interval *PGTYPESinterval_new(void);

+

PGTYPESinterval_free

Release the memory of a previously allocated interval variable. +

void PGTYPESinterval_new(interval *intvl);

+

PGTYPESinterval_from_asc

Parse an interval from its textual representation. +

interval *PGTYPESinterval_from_asc(char *str, char **endptr);

+ The function parses the input string str and returns a + pointer to an allocated interval variable. + At the moment ECPG always parses + the complete string and so it currently does not support to store the + address of the first invalid character in *endptr. + You can safely set endptr to NULL. +

PGTYPESinterval_to_asc

Convert a variable of type interval to its textual representation. +

char *PGTYPESinterval_to_asc(interval *span);

+ The function converts the interval variable that span + points to into a C char*. The output looks like this example: + @ 1 day 12 hours 59 mins 10 secs. +

PGTYPESinterval_copy

Copy a variable of type interval. +

int PGTYPESinterval_copy(interval *intvlsrc, interval *intvldest);

+ The function copies the interval variable that intvlsrc + points to into the variable that intvldest points to. Note + that you need to allocate the memory for the destination variable + before. +

+

33.6.5. The decimal Type

The decimal type is similar to the numeric type. However it is limited to + a maximum precision of 30 significant digits. In contrast to the numeric + type which can be created on the heap only, the decimal type can be + created either on the stack or on the heap (by means of the functions + PGTYPESdecimal_new and + PGTYPESdecimal_free). + There are a lot of other functions that deal with the decimal type in the + Informix compatibility mode described in Section 33.15. +

The following functions can be used to work with the decimal type and are + not only contained in the libcompat library. +

PGTYPESdecimal_new

Request a pointer to a newly allocated decimal variable. +

decimal *PGTYPESdecimal_new(void);

+

PGTYPESdecimal_free

Free a decimal type, release all of its memory. +

void PGTYPESdecimal_free(decimal *var);

+

+

33.6.6. errno Values of pgtypeslib

PGTYPES_NUM_BAD_NUMERIC

An argument should contain a numeric variable (or point to a numeric + variable) but in fact its in-memory representation was invalid. +

PGTYPES_NUM_OVERFLOW

An overflow occurred. Since the numeric type can deal with almost + arbitrary precision, converting a numeric variable into other types + might cause overflow. +

PGTYPES_NUM_UNDERFLOW

An underflow occurred. Since the numeric type can deal with almost + arbitrary precision, converting a numeric variable into other types + might cause underflow. +

PGTYPES_NUM_DIVIDE_ZERO

A division by zero has been attempted. +

PGTYPES_DATE_BAD_DATE

An invalid date string was passed to + the PGTYPESdate_from_asc function. +

PGTYPES_DATE_ERR_EARGS

Invalid arguments were passed to the + PGTYPESdate_defmt_asc function. +

PGTYPES_DATE_ERR_ENOSHORTDATE

An invalid token in the input string was found by the + PGTYPESdate_defmt_asc function. +

PGTYPES_INTVL_BAD_INTERVAL

An invalid interval string was passed to the + PGTYPESinterval_from_asc function, or an + invalid interval value was passed to the + PGTYPESinterval_to_asc function. +

PGTYPES_DATE_ERR_ENOTDMY

There was a mismatch in the day/month/year assignment in the + PGTYPESdate_defmt_asc function. +

PGTYPES_DATE_BAD_DAY

An invalid day of the month value was found by + the PGTYPESdate_defmt_asc function. +

PGTYPES_DATE_BAD_MONTH

An invalid month value was found by + the PGTYPESdate_defmt_asc function. +

PGTYPES_TS_BAD_TIMESTAMP

An invalid timestamp string pass passed to + the PGTYPEStimestamp_from_asc function, + or an invalid timestamp value was passed to + the PGTYPEStimestamp_to_asc function. +

PGTYPES_TS_ERR_EINFTIME

An infinite timestamp value was encountered in a context that + cannot handle it. +

+

33.6.7. Special Constants of pgtypeslib

PGTYPESInvalidTimestamp

A value of type timestamp representing an invalid time stamp. This is + returned by the function PGTYPEStimestamp_from_asc on + parse error. + Note that due to the internal representation of the timestamp data type, + PGTYPESInvalidTimestamp is also a valid timestamp at + the same time. It is set to 1899-12-31 23:59:59. In order + to detect errors, make sure that your application does not only test + for PGTYPESInvalidTimestamp but also for + errno != 0 after each call to + PGTYPEStimestamp_from_asc. +

+


PrevHomeNext
Dynamic SQLUpUsing Descriptor Areas
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-preproc.html b/doc/src/sgml/html/ecpg-preproc.html new file mode 100644 index 000000000..0524f06a8 --- /dev/null +++ b/doc/src/sgml/html/ecpg-preproc.html @@ -0,0 +1,602 @@ + +Preprocessor Directives
PostgreSQL 9.2.2 Documentation
PrevUpChapter 33. ECPG - Embedded SQL in CNext

33.9. Preprocessor Directives

Several preprocessor directives are available that modify how + the ecpg preprocessor parses and processes a + file. +

33.9.1. Including Files

To include an external file into your embedded SQL program, use: +

EXEC SQL INCLUDE filename;
+EXEC SQL INCLUDE <filename>;
+EXEC SQL INCLUDE "filename";

+ The embedded SQL preprocessor will look for a file named + filename.h, + preprocess it, and include it in the resulting C output. Thus, + embedded SQL statements in the included file are handled correctly. +

The ecpg preprocessor will search a file at + several directories in following order: + +

  • current directory

  • /usr/local/include

  • PostgreSQL include directory, defined at build time (e.g., /usr/local/pgsql/include)

  • /usr/include

+ + But when EXEC SQL INCLUDE + "filename" is used, only the + current directory is searched. +

In each directory, the preprocessor will first look for the file + name as given, and if not found will append .h + to the file name and try again (unless the specified file name + already has that suffix). +

Note that EXEC SQL INCLUDE is not the same as: +

#include <filename.h>

+ because this file would not be subject to SQL command preprocessing. + Naturally, you can continue to use the C + #include directive to include other header + files. +

Note: The include file name is case-sensitive, even though the rest of + the EXEC SQL INCLUDE command follows the normal + SQL case-sensitivity rules. +

33.9.2. The define and undef Directives

Similar to the directive #define that is known from C, + embedded SQL has a similar concept: +

EXEC SQL DEFINE name;
+EXEC SQL DEFINE name value;

+ So you can define a name: +

EXEC SQL DEFINE HAVE_FEATURE;

+ And you can also define constants: +

EXEC SQL DEFINE MYNUMBER 12;
+EXEC SQL DEFINE MYSTRING 'abc';

+ Use undef to remove a previous definition: +

EXEC SQL UNDEF MYNUMBER;

+

Of course you can continue to use the C versions #define + and #undef in your embedded SQL program. The difference + is where your defined values get evaluated. If you use EXEC SQL + DEFINE then the ecpg preprocessor evaluates the defines and substitutes + the values. For example if you write: +

EXEC SQL DEFINE MYNUMBER 12;
+...
+EXEC SQL UPDATE Tbl SET col = MYNUMBER;

+ then ecpg will already do the substitution and your C compiler will never + see any name or identifier MYNUMBER. Note that you cannot use + #define for a constant that you are going to use in an + embedded SQL query because in this case the embedded SQL precompiler is not + able to see this declaration. +

33.9.3. ifdef, ifndef, else, elif, and endif Directives

You can use the following directives to compile code sections conditionally: + +

EXEC SQL ifdef name;

Checks a name and processes subsequent lines if + name has been created with EXEC SQL define + name. +

EXEC SQL ifndef name;

Checks a name and processes subsequent lines if + name has not been created with + EXEC SQL define name. +

EXEC SQL else;

Starts processing an alternative section to a section introduced by + either EXEC SQL ifdef name or + EXEC SQL ifndef name. +

EXEC SQL elif name;

Checks name and starts an alternative section if + name has been created with EXEC SQL define + name. +

EXEC SQL endif;

Ends an alternative section. +

+

Example: +

EXEC SQL ifndef TZVAR;
+EXEC SQL SET TIMEZONE TO 'GMT';
+EXEC SQL elif TZNAME;
+EXEC SQL SET TIMEZONE TO TZNAME;
+EXEC SQL else;
+EXEC SQL SET TIMEZONE TO TZVAR;
+EXEC SQL endif;

+


PrevHomeNext
Error HandlingUpProcessing Embedded SQL Programs
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-process.html b/doc/src/sgml/html/ecpg-process.html new file mode 100644 index 000000000..c9e574beb --- /dev/null +++ b/doc/src/sgml/html/ecpg-process.html @@ -0,0 +1,304 @@ + +Processing Embedded SQL Programs
PostgreSQL 9.2.2 Documentation
PrevUpChapter 33. ECPG - Embedded SQL in CNext

33.10. Processing Embedded SQL Programs

Now that you have an idea how to form embedded SQL C programs, you + probably want to know how to compile them. Before compiling you + run the file through the embedded SQL + C preprocessor, which converts the + SQL statements you used to special function + calls. After compiling, you must link with a special library that + contains the needed functions. These functions fetch information + from the arguments, perform the SQL command using + the libpq interface, and put the result + in the arguments specified for output. +

The preprocessor program is called ecpg and is + included in a normal PostgreSQL installation. + Embedded SQL programs are typically named with an extension + .pgc. If you have a program file called + prog1.pgc, you can preprocess it by simply + calling: +

ecpg prog1.pgc

+ This will create a file called prog1.c. If + your input files do not follow the suggested naming pattern, you + can specify the output file explicitly using the + -o option. +

The preprocessed file can be compiled normally, for example: +

cc -c prog1.c

+ The generated C source files include header files from the + PostgreSQL installation, so if you installed + PostgreSQL in a location that is not searched by + default, you have to add an option such as + -I/usr/local/pgsql/include to the compilation + command line. +

To link an embedded SQL program, you need to include the + libecpg library, like so: +

cc -o myprog prog1.o prog2.o ... -lecpg

+ Again, you might have to add an option like + -L/usr/local/pgsql/lib to that command line. +

If you manage the build process of a larger project using + make, it might be convenient to include + the following implicit rule to your makefiles: +

ECPG = ecpg
+
+%.c: %.pgc
+        $(ECPG) $<

+

The complete syntax of the ecpg command is + detailed in ecpg. +

The ecpg library is thread-safe by + default. However, you might need to use some threading + command-line options to compile your client code. +


PrevHomeNext
Preprocessor DirectivesUpLibrary Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-sql-allocate-descriptor.html b/doc/src/sgml/html/ecpg-sql-allocate-descriptor.html new file mode 100644 index 000000000..a1f770153 --- /dev/null +++ b/doc/src/sgml/html/ecpg-sql-allocate-descriptor.html @@ -0,0 +1,277 @@ + +ALLOCATE DESCRIPTOR

ALLOCATE DESCRIPTOR

Name

ALLOCATE DESCRIPTOR -- allocate an SQL descriptor area

Synopsis

ALLOCATE DESCRIPTOR name

Description

ALLOCATE DESCRIPTOR allocates a new named SQL + descriptor area, which can be used to exchange data between the + PostgreSQL server and the host program. +

Descriptor areas should be freed after use using + the DEALLOCATE DESCRIPTOR command. +

Parameters

name

A name of SQL descriptor, case sensitive. This can be an SQL + identifier or a host variable. +

Examples

EXEC SQL ALLOCATE DESCRIPTOR mydesc;

Compatibility

ALLOCATE DESCRIPTOR is specified in the SQL + standard. +


PrevHomeNext
Embedded SQL CommandsUpCONNECT
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-sql-commands.html b/doc/src/sgml/html/ecpg-sql-commands.html new file mode 100644 index 000000000..417e4e398 --- /dev/null +++ b/doc/src/sgml/html/ecpg-sql-commands.html @@ -0,0 +1,272 @@ + +Embedded SQL Commands
PostgreSQL 9.2.2 Documentation
PrevUpChapter 33. ECPG - Embedded SQL in CNext

33.14. Embedded SQL Commands

Table of Contents
ALLOCATE DESCRIPTOR -- allocate an SQL descriptor area
CONNECT -- establish a database connection
DEALLOCATE DESCRIPTOR -- deallocate an SQL descriptor area
DECLARE -- define a cursor
DESCRIBE -- obtain information about a prepared statement or result set
DISCONNECT -- terminate a database connection
EXECUTE IMMEDIATE -- dynamically prepare and execute a statement
GET DESCRIPTOR -- get information from an SQL descriptor area
OPEN -- open a dynamic cursor
PREPARE -- prepare a statement for execution
SET AUTOCOMMIT -- set the autocommit behavior of the current session
SET CONNECTION -- select a database connection
SET DESCRIPTOR -- set information in an SQL descriptor area
TYPE -- define a new data type
VAR -- define a variable
WHENEVER -- specify the action to be taken when an SQL statement causes a specific class condition to be raised

This section describes all SQL commands that are specific to + embedded SQL. Also refer to the SQL commands listed + in Reference I, SQL Commands, which can also be used in + embedded SQL, unless stated otherwise. +


PrevHomeNext
C++ ApplicationsUpALLOCATE DESCRIPTOR
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-sql-connect.html b/doc/src/sgml/html/ecpg-sql-connect.html new file mode 100644 index 000000000..1f0d8475b --- /dev/null +++ b/doc/src/sgml/html/ecpg-sql-connect.html @@ -0,0 +1,578 @@ + +CONNECT

CONNECT

Name

CONNECT -- establish a database connection

Synopsis

CONNECT TO connection_target [ AS connection_name ] [ USER connection_user_name ]
+CONNECT TO DEFAULT
+CONNECT connection_user_name
+DATABASE connection_target

Description

The CONNECT command establishes a connection + between the client and the PostgreSQL server. +

Parameters

connection_target

connection_target + specifies the target server of the connection on one of + several forms. + +

[ database_name ] [ @host ] [ :port ]

Connect over TCP/IP +

unix:postgresql://host [ :port ] / [ database_name ] [ ?connection_option ]

Connect over Unix-domain sockets +

tcp:postgresql://host [ :port ] / [ database_name ] [ ?connection_option ]

Connect over TCP/IP +

SQL string constant

containing a value in one of the above forms +

host variable

host variable of type char[] + or VARCHAR[] containing a value in one of the + above forms +

+

connection_object

An optional identifier for the connection, so that it can be + referred to in other commands. This can be an SQL identifier + or a host variable. +

connection_user

The user name for the database connection. +

This parameter can also specify user name and password, using one the forms + user_name/password, + user_name IDENTIFIED BY password, or + user_name USING password. +

User name and password can be SQL identifiers, string + constants, or host variables. +

DEFAULT

Use all default connection parameters, as defined by libpq. +

Examples

Here a several variants for specifying connection parameters: +

EXEC SQL CONNECT TO "connectdb" AS main;
+EXEC SQL CONNECT TO "connectdb" AS second;
+EXEC SQL CONNECT TO "unix:postgresql://200.46.204.71/connectdb" AS main USER connectuser;
+EXEC SQL CONNECT TO "unix:postgresql://localhost/connectdb" AS main USER connectuser;
+EXEC SQL CONNECT TO 'connectdb' AS main;
+EXEC SQL CONNECT TO 'unix:postgresql://localhost/connectdb' AS main USER :user;
+EXEC SQL CONNECT TO :db AS :id;
+EXEC SQL CONNECT TO :db USER connectuser USING :pw;
+EXEC SQL CONNECT TO @localhost AS main USER connectdb;
+EXEC SQL CONNECT TO REGRESSDB1 as main;
+EXEC SQL CONNECT TO AS main USER connectdb;
+EXEC SQL CONNECT TO connectdb AS :id;
+EXEC SQL CONNECT TO connectdb AS main USER connectuser/connectdb;
+EXEC SQL CONNECT TO connectdb AS main;
+EXEC SQL CONNECT TO connectdb@localhost AS main;
+EXEC SQL CONNECT TO tcp:postgresql://localhost/ USER connectdb;
+EXEC SQL CONNECT TO tcp:postgresql://localhost/connectdb USER connectuser IDENTIFIED BY connectpw;
+EXEC SQL CONNECT TO tcp:postgresql://localhost:20/connectdb USER connectuser IDENTIFIED BY connectpw;
+EXEC SQL CONNECT TO unix:postgresql://localhost/ AS main USER connectdb;
+EXEC SQL CONNECT TO unix:postgresql://localhost/connectdb AS main USER connectuser;
+EXEC SQL CONNECT TO unix:postgresql://localhost/connectdb USER connectuser IDENTIFIED BY "connectpw";
+EXEC SQL CONNECT TO unix:postgresql://localhost/connectdb USER connectuser USING "connectpw";
+EXEC SQL CONNECT TO unix:postgresql://localhost/connectdb?connect_timeout=14 USER connectuser;

+

Here is an example program that illustrates the use of host + variables to specify connection parameters: +

int
+main(void)
+{
+EXEC SQL BEGIN DECLARE SECTION;
+    char *dbname     = "testdb";    /* database name */
+    char *user       = "testuser";  /* connection user name */
+    char *connection = "tcp:postgresql://localhost:5432/testdb";
+                                    /* connection string */
+    char ver[256];                  /* buffer to store the version string */
+EXEC SQL END DECLARE SECTION;
+
+    ECPGdebug(1, stderr);
+
+    EXEC SQL CONNECT TO :dbname USER :user;
+    EXEC SQL SELECT version() INTO :ver;
+    EXEC SQL DISCONNECT;
+
+    printf("version: %s\n", ver);
+
+    EXEC SQL CONNECT TO :connection USER :user;
+    EXEC SQL SELECT version() INTO :ver;
+    EXEC SQL DISCONNECT;
+
+    printf("version: %s\n", ver);
+
+    return 0;
+}

+

Compatibility

CONNECT is specified in the SQL standard, but + the format of the connection parameters is + implementation-specific. +


PrevHomeNext
ALLOCATE DESCRIPTORUpDEALLOCATE DESCRIPTOR
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-sql-deallocate-descriptor.html b/doc/src/sgml/html/ecpg-sql-deallocate-descriptor.html new file mode 100644 index 000000000..c68e4c0df --- /dev/null +++ b/doc/src/sgml/html/ecpg-sql-deallocate-descriptor.html @@ -0,0 +1,270 @@ + +DEALLOCATE DESCRIPTOR

DEALLOCATE DESCRIPTOR

Name

DEALLOCATE DESCRIPTOR -- deallocate an SQL descriptor area

Synopsis

DEALLOCATE DESCRIPTOR name

Description

DEALLOCATE DESCRIPTOR deallocates a named SQL + descriptor area. +

Parameters

name

The name of the descriptor which is going to be deallocated. + It is case sensitive. This can be an SQL identifier or a host + variable. +

Examples

EXEC SQL DEALLOCATE DESCRIPTOR mydesc;

Compatibility

DEALLOCATE DESCRIPTOR is specified in the SQL + standard. +


PrevHomeNext
CONNECTUpDECLARE
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-sql-declare.html b/doc/src/sgml/html/ecpg-sql-declare.html new file mode 100644 index 000000000..f28bcf829 --- /dev/null +++ b/doc/src/sgml/html/ecpg-sql-declare.html @@ -0,0 +1,354 @@ + +DECLARE

DECLARE

Name

DECLARE -- define a cursor

Synopsis

DECLARE cursor_name [ BINARY ] [ INSENSITIVE ] [ [ NO ] SCROLL ] CURSOR [ { WITH | WITHOUT } HOLD ] FOR prepared_name
+DECLARE cursor_name [ BINARY ] [ INSENSITIVE ] [ [ NO ] SCROLL ] CURSOR [ { WITH | WITHOUT } HOLD ] FOR query

Description

DECLARE declares a cursor for iterating over + the result set of a prepared statement. This command has + slightly different semantics from the direct SQL + command DECLARE: Whereas the latter executes a + query and prepares the result set for retrieval, this embedded + SQL command merely declares a name as a "loop + variable" for iterating over the result set of a query; + the actual execution happens when the cursor is opened with + the OPEN command. +

Parameters

cursor_name

A cursor name, case sensitive. This can be an SQL identifier + or a host variable. +

prepared_name

The name of a prepared query, either as an SQL identifier or a + host variable. +

query

A SELECT or + VALUES command which will provide the + rows to be returned by the cursor. +

For the meaning of the cursor options, + see DECLARE. +

Examples

Examples declaring a cursor for a query: +

EXEC SQL DECLARE C CURSOR FOR SELECT * FROM My_Table;
+EXEC SQL DECLARE C CURSOR FOR SELECT Item1 FROM T;
+EXEC SQL DECLARE cur1 CURSOR FOR SELECT version();

+

An example declaring a cursor for a prepared statement: +

EXEC SQL PREPARE stmt1 AS SELECT version();
+EXEC SQL DECLARE cur1 CURSOR FOR stmt1;

+

Compatibility

DECLARE is specified in the SQL standard. +

See Also

OPEN, CLOSE, DECLARE

PrevHomeNext
DEALLOCATE DESCRIPTORUpDESCRIBE
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-sql-describe.html b/doc/src/sgml/html/ecpg-sql-describe.html new file mode 100644 index 000000000..3fe3c396e --- /dev/null +++ b/doc/src/sgml/html/ecpg-sql-describe.html @@ -0,0 +1,322 @@ + +DESCRIBE

DESCRIBE

Name

DESCRIBE -- obtain information about a prepared statement or result set

Synopsis

DESCRIBE [ OUTPUT ] prepared_name USING [ SQL ] DESCRIPTOR descriptor_name
+DESCRIBE [ OUTPUT ] prepared_name INTO [ SQL ] DESCRIPTOR descriptor_name
+DESCRIBE [ OUTPUT ] prepared_name INTO sqlda_name

Description

DESCRIBE retrieves metadata information about + the result columns contained in a prepared statement, without + actually fetching a row. +

Parameters

prepared_name

The name of a prepared statement. This can be an SQL + identifier or a host variable. +

descriptor_name

A descriptor name. It is case sensitive. It can be an SQL + identifier or a host variable. +

sqlda_name

The name of an SQLDA variable. +

Examples

EXEC SQL ALLOCATE DESCRIPTOR mydesc;
+EXEC SQL PREPARE stmt1 FROM :sql_stmt;
+EXEC SQL DESCRIBE stmt1 INTO SQL DESCRIPTOR mydesc;
+EXEC SQL GET DESCRIPTOR mydesc VALUE 1 :charvar = NAME;
+EXEC SQL DEALLOCATE DESCRIPTOR mydesc;

Compatibility

DESCRIBE is specified in the SQL standard. +


PrevHomeNext
DECLAREUpDISCONNECT
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-sql-disconnect.html b/doc/src/sgml/html/ecpg-sql-disconnect.html new file mode 100644 index 000000000..abbeb4c1e --- /dev/null +++ b/doc/src/sgml/html/ecpg-sql-disconnect.html @@ -0,0 +1,327 @@ + +DISCONNECT

DISCONNECT

Name

DISCONNECT -- terminate a database connection

Synopsis

DISCONNECT connection_name
+DISCONNECT [ CURRENT ]
+DISCONNECT DEFAULT
+DISCONNECT ALL

Description

DISCONNECT closes a connection (or all + connections) to the database. +

Parameters

connection_name

A database connection name established by + the CONNECT command. +

CURRENT

Close the "current" connection, which is either + the most recently opened connection, or the connection set by + the SET CONNECTION command. This is also + the default if no argument is given to + the DISCONNECT command. +

DEFAULT

Close the default connection. +

ALL

Close all open connections. +

Examples

int
+main(void)
+{
+    EXEC SQL CONNECT TO testdb AS DEFAULT USER testuser;
+    EXEC SQL CONNECT TO testdb AS con1 USER testuser;
+    EXEC SQL CONNECT TO testdb AS con2 USER testuser;
+    EXEC SQL CONNECT TO testdb AS con3 USER testuser;
+
+    EXEC SQL DISCONNECT CURRENT;  /* close con3          */
+    EXEC SQL DISCONNECT DEFAULT;  /* close DEFAULT       */
+    EXEC SQL DISCONNECT ALL;      /* close con2 and con1 */
+
+    return 0;
+}

Compatibility

DISCONNECT is specified in the SQL standard. +


PrevHomeNext
DESCRIBEUpEXECUTE IMMEDIATE
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-sql-execute-immediate.html b/doc/src/sgml/html/ecpg-sql-execute-immediate.html new file mode 100644 index 000000000..ccae24128 --- /dev/null +++ b/doc/src/sgml/html/ecpg-sql-execute-immediate.html @@ -0,0 +1,268 @@ + +EXECUTE IMMEDIATE

EXECUTE IMMEDIATE

Name

EXECUTE IMMEDIATE -- dynamically prepare and execute a statement

Synopsis

EXECUTE IMMEDIATE string

Description

EXECUTE IMMEDIATE immediately prepares and + executes a dynamically specified SQL statement, without + retrieving result rows. +

Parameters

string

A literal C string or a host variable containing the SQL + statement to be executed. +

Examples

Here is an example that executes an INSERT + statement using EXECUTE IMMEDIATE and a host + variable named command: +

sprintf(command, "INSERT INTO test (name, amount, letter) VALUES ('db: ''r1''', 1, 'f')");
+EXEC SQL EXECUTE IMMEDIATE :command;

+

Compatibility

EXECUTE IMMEDIATE is specified in the SQL standard. +


PrevHomeNext
DISCONNECTUpGET DESCRIPTOR
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-sql-get-descriptor.html b/doc/src/sgml/html/ecpg-sql-get-descriptor.html new file mode 100644 index 000000000..fc3c7f7fa --- /dev/null +++ b/doc/src/sgml/html/ecpg-sql-get-descriptor.html @@ -0,0 +1,451 @@ + +GET DESCRIPTOR

GET DESCRIPTOR

Name

GET DESCRIPTOR -- get information from an SQL descriptor area

Synopsis

GET DESCRIPTOR descriptor_name :cvariable = descriptor_header_item [, ... ]
+GET DESCRIPTOR descriptor_name VALUE column_number :cvariable = descriptor_item [, ... ]

Description

GET DESCRIPTOR retrieves information about a + query result set from an SQL descriptor area and stores it into + host variables. A descriptor area is typically populated + using FETCH or SELECT + before using this command to transfer the information into host + language variables. +

This command has two forms: The first form retrieves + descriptor "header" items, which apply to the result + set in its entirety. One example is the row count. The second + form, which requires the column number as additional parameter, + retrieves information about a particular column. Examples are + the column name and the actual column value. +

Parameters

descriptor_name

A descriptor name. +

descriptor_header_item

A token identifying which header information item to retrieve. + Only COUNT, to get the number of columns in the + result set, is currently supported. +

column_number

The number of the column about which information is to be + retrieved. The count starts at 1. +

descriptor_item

A token identifying which item of information about a column + to retrieve. See Section 33.7.1 for + a list of supported items. +

cvariable

A host variable that will receive the data retrieved from the + descriptor area. +

Examples

An example to retrieve the number of columns in a result set: +

EXEC SQL GET DESCRIPTOR d :d_count = COUNT;

+

An example to retrieve a data length in the first column: +

EXEC SQL GET DESCRIPTOR d VALUE 1 :d_returned_octet_length = RETURNED_OCTET_LENGTH;

+

An example to retrieve the data body of the second column as a + string: +

EXEC SQL GET DESCRIPTOR d VALUE 2 :d_data = DATA;

+

Here is an example for a whole procedure of + executing SELECT current_database(); and showing the number of + columns, the column data length, and the column data: +

int
+main(void)
+{
+EXEC SQL BEGIN DECLARE SECTION;
+    int  d_count;
+    char d_data[1024];
+    int  d_returned_octet_length;
+EXEC SQL END DECLARE SECTION;
+
+    EXEC SQL CONNECT TO testdb AS con1 USER testuser;
+    EXEC SQL ALLOCATE DESCRIPTOR d;
+
+    /* Declare, open a cursor, and assign a descriptor to the cursor  */
+    EXEC SQL DECLARE cur CURSOR FOR SELECT current_database();
+    EXEC SQL OPEN cur;
+    EXEC SQL FETCH NEXT FROM cur INTO SQL DESCRIPTOR d;
+
+    /* Get a number of total columns */
+    EXEC SQL GET DESCRIPTOR d :d_count = COUNT;
+    printf("d_count                 = %d\n", d_count);
+
+    /* Get length of a returned column */
+    EXEC SQL GET DESCRIPTOR d VALUE 1 :d_returned_octet_length = RETURNED_OCTET_LENGTH;
+    printf("d_returned_octet_length = %d\n", d_returned_octet_length);
+
+    /* Fetch the returned column as a string */
+    EXEC SQL GET DESCRIPTOR d VALUE 1 :d_data = DATA;
+    printf("d_data                  = %s\n", d_data);
+
+    /* Closing */
+    EXEC SQL CLOSE cur;
+    EXEC SQL COMMIT;
+
+    EXEC SQL DEALLOCATE DESCRIPTOR d;
+    EXEC SQL DISCONNECT ALL;
+
+    return 0;
+}

+ When the example is executed, the result will look like this: +

d_count                 = 1
+d_returned_octet_length = 6
+d_data                  = testdb

+

Compatibility

GET DESCRIPTOR is specified in the SQL standard. +


PrevHomeNext
EXECUTE IMMEDIATEUpOPEN
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-sql-open.html b/doc/src/sgml/html/ecpg-sql-open.html new file mode 100644 index 000000000..bdb3f4c14 --- /dev/null +++ b/doc/src/sgml/html/ecpg-sql-open.html @@ -0,0 +1,328 @@ + +OPEN

OPEN

Name

OPEN -- open a dynamic cursor

Synopsis

OPEN cursor_name
+OPEN cursor_name USING value [, ... ]
+OPEN cursor_name USING SQL DESCRIPTOR descriptor_name

Description

OPEN opens a cursor and optionally binds + actual values to the placeholders in the cursor's declaration. + The cursor must previously have been declared with + the DECLARE command. The execution + of OPEN causes the query to start executing on + the server. +

Parameters

cursor_name

The name of the cursor to be opened. This can be an SQL + identifier or a host variable. +

value

A value to be bound to a placeholder in the cursor. This can + be an SQL constant, a host variable, or a host variable with + indicator. +

descriptor_name

The name of a descriptor containing values to be bound to the + placeholders in the cursor. This can be an SQL identifier or + a host variable. +

Examples

EXEC SQL OPEN a;
+EXEC SQL OPEN d USING 1, 'test';
+EXEC SQL OPEN c1 USING SQL DESCRIPTOR mydesc;
+EXEC SQL OPEN :curname1;

Compatibility

OPEN is specified in the SQL standard. +

See Also

DECLARE, CLOSE

PrevHomeNext
GET DESCRIPTORUpPREPARE
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-sql-prepare.html b/doc/src/sgml/html/ecpg-sql-prepare.html new file mode 100644 index 000000000..a599463e6 --- /dev/null +++ b/doc/src/sgml/html/ecpg-sql-prepare.html @@ -0,0 +1,294 @@ + +PREPARE

PREPARE

Name

PREPARE -- prepare a statement for execution

Synopsis

PREPARE name FROM string

Description

PREPARE prepares a statement dynamically + specified as a string for execution. This is different from the + direct SQL statement PREPARE, which can also + be used in embedded programs. The EXECUTE + command is used to execute either kind of prepared statement. +

Parameters

prepared_name

An identifier for the prepared query. +

string

A literal C string or a host variable containing a preparable + statement, one of the SELECT, INSERT, UPDATE, or + DELETE. +

Examples

char *stmt = "SELECT * FROM test1 WHERE a = ? AND b = ?";
+
+EXEC SQL ALLOCATE DESCRIPTOR outdesc;
+EXEC SQL PREPARE foo FROM :stmt;
+
+EXEC SQL EXECUTE foo USING SQL DESCRIPTOR indesc INTO SQL DESCRIPTOR outdesc;

Compatibility

PREPARE is specified in the SQL standard. +

See Also

EXECUTE

PrevHomeNext
OPENUpSET AUTOCOMMIT
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-sql-set-autocommit.html b/doc/src/sgml/html/ecpg-sql-set-autocommit.html new file mode 100644 index 000000000..6c1beb4b0 --- /dev/null +++ b/doc/src/sgml/html/ecpg-sql-set-autocommit.html @@ -0,0 +1,220 @@ + +SET AUTOCOMMIT

SET AUTOCOMMIT

Name

SET AUTOCOMMIT -- set the autocommit behavior of the current session

Synopsis

SET AUTOCOMMIT { = | TO } { ON | OFF }

Description

SET AUTOCOMMIT sets the autocommit behavior of + the current database session. By default, embedded SQL programs + are not in autocommit mode, + so COMMIT needs to be issued explicitly when + desired. This command can change the session to autocommit mode, + where each individual statement is committed implicitly. +

Compatibility

SET AUTOCOMMIT is an extension of PostgreSQL ECPG. +


PrevHomeNext
PREPAREUpSET CONNECTION
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-sql-set-connection.html b/doc/src/sgml/html/ecpg-sql-set-connection.html new file mode 100644 index 000000000..5ce126612 --- /dev/null +++ b/doc/src/sgml/html/ecpg-sql-set-connection.html @@ -0,0 +1,283 @@ + +SET CONNECTION

SET CONNECTION

Name

SET CONNECTION -- select a database connection

Synopsis

SET CONNECTION [ TO | = ] connection_name

Description

SET CONNECTION sets the "current" + database connection, which is the one that all commands use + unless overridden. +

Parameters

connection_name

A database connection name established by + the CONNECT command. +

DEFAULT

Set the connection to the default connection. +

Examples

EXEC SQL SET CONNECTION TO con2;
+EXEC SQL SET CONNECTION = con1;

Compatibility

SET CONNECTION is specified in the SQL standard. +


PrevHomeNext
SET AUTOCOMMITUpSET DESCRIPTOR
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-sql-set-descriptor.html b/doc/src/sgml/html/ecpg-sql-set-descriptor.html new file mode 100644 index 000000000..c56ace049 --- /dev/null +++ b/doc/src/sgml/html/ecpg-sql-set-descriptor.html @@ -0,0 +1,369 @@ + +SET DESCRIPTOR

SET DESCRIPTOR

Name

SET DESCRIPTOR -- set information in an SQL descriptor area

Synopsis

SET DESCRIPTOR descriptor_name descriptor_header_item = value [, ... ]
+SET DESCRIPTOR descriptor_name VALUE number descriptor_item = value [, ...]

Description

SET DESCRIPTOR populates an SQL descriptor + area with values. The descriptor area is then typically used to + bind parameters in a prepared query execution. +

This command has two forms: The first form applies to the + descriptor "header", which is independent of a + particular datum. The second form assigns values to particular + datums, identified by number. +

Parameters

descriptor_name

A descriptor name. +

descriptor_header_item

A token identifying which header information item to set. + Only COUNT, to set the number of descriptor + items, is currently supported. +

number

The number of the descriptor item to set. The count starts at + 1. +

descriptor_item

A token identifying which item of information to set in the + descriptor. See Section 33.7.1 for a + list of supported items. +

value

A value to store into the descriptor item. This can be an SQL + constant or a host variable. +

Examples

EXEC SQL SET DESCRIPTOR indesc COUNT = 1;
+EXEC SQL SET DESCRIPTOR indesc VALUE 1 DATA = 2;
+EXEC SQL SET DESCRIPTOR indesc VALUE 1 DATA = :val1;
+EXEC SQL SET DESCRIPTOR indesc VALUE 2 INDICATOR = :val1, DATA = 'some string';
+EXEC SQL SET DESCRIPTOR indesc VALUE 2 INDICATOR = :val2null, DATA = :val2;

Compatibility

SET DESCRIPTOR is specified in the SQL standard. +


PrevHomeNext
SET CONNECTIONUpTYPE
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-sql-type.html b/doc/src/sgml/html/ecpg-sql-type.html new file mode 100644 index 000000000..6d0bdee1b --- /dev/null +++ b/doc/src/sgml/html/ecpg-sql-type.html @@ -0,0 +1,355 @@ + +TYPE

TYPE

Name

TYPE -- define a new data type

Synopsis

TYPE type_name IS ctype

Description

The TYPE command defines a new C type. It is + equivalent to putting a typedef into a declare + section. +

This command is only recognized when ecpg is + run with the -c option. +

Parameters

type_name

The name for the new type. It must be a valid C type name. +

ctype

A C type specification. +

Examples

EXEC SQL TYPE customer IS
+    struct
+    {
+        varchar name[50];
+        int     phone;
+    };
+
+EXEC SQL TYPE cust_ind IS
+    struct ind
+    {
+        short   name_ind;
+        short   phone_ind;
+    };
+
+EXEC SQL TYPE c IS char reference;
+EXEC SQL TYPE ind IS union { int integer; short smallint; };
+EXEC SQL TYPE intarray IS int[AMOUNT];
+EXEC SQL TYPE str IS varchar[BUFFERSIZ];
+EXEC SQL TYPE string IS char[11];

Here is an example program that uses EXEC SQL + TYPE: +

EXEC SQL WHENEVER SQLERROR SQLPRINT;
+
+EXEC SQL TYPE tt IS
+    struct
+    {
+        varchar v[256];
+        int     i;
+    };
+
+EXEC SQL TYPE tt_ind IS
+    struct ind {
+        short   v_ind;
+        short   i_ind;
+    };
+
+int
+main(void)
+{
+EXEC SQL BEGIN DECLARE SECTION;
+    tt t;
+    tt_ind t_ind;
+EXEC SQL END DECLARE SECTION;
+
+    EXEC SQL CONNECT TO testdb AS con1;
+
+    EXEC SQL SELECT current_database(), 256 INTO :t:t_ind LIMIT 1;
+
+    printf("t.v = %s\n", t.v.arr);
+    printf("t.i = %d\n", t.i);
+
+    printf("t_ind.v_ind = %d\n", t_ind.v_ind);
+    printf("t_ind.i_ind = %d\n", t_ind.i_ind);
+
+    EXEC SQL DISCONNECT con1;
+
+    return 0;
+}

+ + The output from this program looks like this: +

t.v = testdb
+t.i = 256
+t_ind.v_ind = 0
+t_ind.i_ind = 0

+

Compatibility

The TYPE command is a PostgreSQL extension. +


PrevHomeNext
SET DESCRIPTORUpVAR
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-sql-var.html b/doc/src/sgml/html/ecpg-sql-var.html new file mode 100644 index 000000000..ccd1ef801 --- /dev/null +++ b/doc/src/sgml/html/ecpg-sql-var.html @@ -0,0 +1,269 @@ + +VAR

VAR

Name

VAR -- define a variable

Synopsis

VAR varname IS ctype

Description

The VAR command defines a host variable. It + is equivalent to an ordinary C variable definition inside a + declare section. +

Parameters

varname

A C variable name. +

ctype

A C type specification. +

Examples

EXEC SQL VAR vc IS VARCHAR[10];
+EXEC SQL VAR boolvar IS bool;

Compatibility

The VAR command is a PostgreSQL extension. +


PrevHomeNext
TYPEUpWHENEVER
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-sql-whenever.html b/doc/src/sgml/html/ecpg-sql-whenever.html new file mode 100644 index 000000000..2de971971 --- /dev/null +++ b/doc/src/sgml/html/ecpg-sql-whenever.html @@ -0,0 +1,284 @@ + +WHENEVER

WHENEVER

Name

WHENEVER -- specify the action to be taken when an SQL statement causes a specific class condition to be raised

Synopsis

WHENEVER { NOT FOUND | SQLERROR | SQLWARNING } action

Description

Define a behavior which is called on the special cases (Rows not + found, SQL warnings or errors) in the result of SQL execution. +

Parameters

See Section 33.8.1 for a description of the + parameters. +

Examples

EXEC SQL WHENEVER NOT FOUND CONTINUE;
+EXEC SQL WHENEVER NOT FOUND DO BREAK;
+EXEC SQL WHENEVER SQLWARNING SQLPRINT;
+EXEC SQL WHENEVER SQLWARNING DO warn();
+EXEC SQL WHENEVER SQLERROR sqlprint;
+EXEC SQL WHENEVER SQLERROR CALL print2();
+EXEC SQL WHENEVER SQLERROR DO handle_error("select");
+EXEC SQL WHENEVER SQLERROR DO sqlnotice(NULL, NONO);
+EXEC SQL WHENEVER SQLERROR DO sqlprint();
+EXEC SQL WHENEVER SQLERROR GOTO error_label;
+EXEC SQL WHENEVER SQLERROR STOP;

A typical application is the use of WHENEVER NOT FOUND + BREAK to handle looping through result sets: +

int
+main(void)
+{
+    EXEC SQL CONNECT TO testdb AS con1;
+    EXEC SQL ALLOCATE DESCRIPTOR d;
+    EXEC SQL DECLARE cur CURSOR FOR SELECT current_database(), 'hoge', 256;
+    EXEC SQL OPEN cur;
+
+    /* when end of result set reached, break out of while loop */
+    EXEC SQL WHENEVER NOT FOUND DO BREAK;
+
+    while (1)
+    {
+        EXEC SQL FETCH NEXT FROM cur INTO SQL DESCRIPTOR d;
+        ...
+    }
+
+    EXEC SQL CLOSE cur;
+    EXEC SQL COMMIT;
+
+    EXEC SQL DEALLOCATE DESCRIPTOR d;
+    EXEC SQL DISCONNECT ALL;
+
+    return 0;
+}

+

Compatibility

WHENEVER is specified in the SQL standard, but + most of the actions are PostgreSQL extensions. +


PrevHomeNext
VARUpInformix Compatibility Mode
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg-variables.html b/doc/src/sgml/html/ecpg-variables.html new file mode 100644 index 000000000..35b1d57de --- /dev/null +++ b/doc/src/sgml/html/ecpg-variables.html @@ -0,0 +1,2020 @@ + +Using Host Variables
PostgreSQL 9.2.2 Documentation
PrevUpChapter 33. ECPG - Embedded SQL in CNext

33.4. Using Host Variables

In Section 33.3 you saw how you can execute SQL + statements from an embedded SQL program. Some of those statements + only used fixed values and did not provide a way to insert + user-supplied values into statements or have the program process + the values returned by the query. Those kinds of statements are + not really useful in real applications. This section explains in + detail how you can pass data between your C program and the + embedded SQL statements using a simple mechanism called + host variables. In an embedded SQL program we + consider the SQL statements to be guests in the C + program code which is the host language. Therefore + the variables of the C program are called host + variables. +

Another way to exchange values between PostgreSQL backends and ECPG + applications is the use of SQL descriptors, described + in Section 33.7. +

33.4.1. Overview

Passing data between the C program and the SQL statements is + particularly simple in embedded SQL. Instead of having the + program paste the data into the statement, which entails various + complications, such as properly quoting the value, you can simply + write the name of a C variable into the SQL statement, prefixed by + a colon. For example: +

EXEC SQL INSERT INTO sometable VALUES (:v1, 'foo', :v2);

+ This statements refers to two C variables named + v1 and v2 and also uses a + regular SQL string literal, to illustrate that you are not + restricted to use one kind of data or the other. +

This style of inserting C variables in SQL statements works + anywhere a value expression is expected in an SQL statement. +

33.4.2. Declare Sections

To pass data from the program to the database, for example as + parameters in a query, or to pass data from the database back to + the program, the C variables that are intended to contain this + data need to be declared in specially marked sections, so the + embedded SQL preprocessor is made aware of them. +

This section starts with: +

EXEC SQL BEGIN DECLARE SECTION;

+ and ends with: +

EXEC SQL END DECLARE SECTION;

+ Between those lines, there must be normal C variable declarations, + such as: +

int   x = 4;
+char  foo[16], bar[16];

+ As you can see, you can optionally assign an initial value to the variable. + The variable's scope is determined by the location of its declaring + section within the program. + You can also declare variables with the following syntax which implicitly + creates a declare section: +

EXEC SQL int i = 4;

+ You can have as many declare sections in a program as you like. +

The declarations are also echoed to the output file as normal C + variables, so there's no need to declare them again. Variables + that are not intended to be used in SQL commands can be declared + normally outside these special sections. +

The definition of a structure or union also must be listed inside + a DECLARE section. Otherwise the preprocessor cannot + handle these types since it does not know the definition. +

33.4.3. Retrieving Query Results

Now you should be able to pass data generated by your program into + an SQL command. But how do you retrieve the results of a query? + For that purpose, embedded SQL provides special variants of the + usual commands SELECT and + FETCH. These commands have a special + INTO clause that specifies which host variables + the retrieved values are to be stored in. + SELECT is used for a query that returns only + single row, and FETCH is used for a query that + returns multiple rows, using a cursor. +

Here is an example: +

/*
+ * assume this table:
+ * CREATE TABLE test1 (a int, b varchar(50));
+ */
+
+EXEC SQL BEGIN DECLARE SECTION;
+int v1;
+VARCHAR v2;
+EXEC SQL END DECLARE SECTION;
+
+ ...
+
+EXEC SQL SELECT a, b INTO :v1, :v2 FROM test;

+ So the INTO clause appears between the select + list and the FROM clause. The number of + elements in the select list and the list after + INTO (also called the target list) must be + equal. +

Here is an example using the command FETCH: +

EXEC SQL BEGIN DECLARE SECTION;
+int v1;
+VARCHAR v2;
+EXEC SQL END DECLARE SECTION;
+
+ ...
+
+EXEC SQL DECLARE foo CURSOR FOR SELECT a, b FROM test;
+
+ ...
+
+do
+{
+    ...
+    EXEC SQL FETCH NEXT FROM foo INTO :v1, :v2;
+    ...
+} while (...);

+ Here the INTO clause appears after all the + normal clauses. +

33.4.4. Type Mapping

When ECPG applications exchange values between the PostgreSQL + server and the C application, such as when retrieving query + results from the server or executing SQL statements with input + parameters, the values need to be converted between PostgreSQL + data types and host language variable types (C language data + types, concretely). One of the main points of ECPG is that it + takes care of this automatically in most cases. +

In this respect, there are two kinds of data types: Some simple + PostgreSQL data types, such as integer + and text, can be read and written by the application + directly. Other PostgreSQL data types, such + as timestamp and numeric can only be + accessed through special library functions; see + Section 33.4.4.2. +

Table 33-1 shows which PostgreSQL + data types correspond to which C data types. When you wish to + send or receive a value of a given PostgreSQL data type, you + should declare a C variable of the corresponding C data type in + the declare section. +

Table 33-1. Mapping Between PostgreSQL Data Types and C Variable Types

PostgreSQL data typeHost variable type
smallintshort
integerint
bigintlong long int
decimaldecimal[a]
numericnumeric[a]
realfloat
double precisiondouble
smallserialshort
serialint
bigseriallong long int
oidunsigned int
character(n), varchar(n), textchar[n+1], VARCHAR[n+1][b]
namechar[NAMEDATALEN]
timestamptimestamp[a]
intervalinterval[a]
datedate[a]
booleanbool[c]
Notes:
a. This type can only be accessed through special library functions; see Section 33.4.4.2.
b. declared in ecpglib.h
c. declared in ecpglib.h if not native

33.4.4.1. Handling Character Strings

To handle SQL character string data types, such + as varchar and text, there are two + possible ways to declare the host variables. +

One way is using char[], an array + of char, which is the most common way to handle + character data in C. +

EXEC SQL BEGIN DECLARE SECTION;
+    char str[50];
+EXEC SQL END DECLARE SECTION;

+ Note that you have to take care of the length yourself. If you + use this host variable as the target variable of a query which + returns a string with more than 49 characters, a buffer overflow + occurs. +

The other way is using the VARCHAR type, which is a + special type provided by ECPG. The definition on an array of + type VARCHAR is converted into a + named struct for every variable. A declaration like: +

VARCHAR var[180];

+ is converted into: +

struct varchar_var { int len; char arr[180]; } var;

+ The member arr hosts the string + including a terminating zero byte. Thus, to store a string in + a VARCHAR host variable, the host variable has to be + declared with the length including the zero byte terminator. The + member len holds the length of the + string stored in the arr without the + terminating zero byte. When a host variable is used as input for + a query, if strlen(arr) + and len are different, the shorter one + is used. +

Two or more VARCHAR host variables cannot be defined + in single line statement. The following code will confuse + the ecpg preprocessor: +

VARCHAR v1[128], v2[128];   /* WRONG */

+ Two variables should be defined in separate statements like this: +

VARCHAR v1[128];
+VARCHAR v2[128];

+

VARCHAR can be written in upper or lower case, but + not in mixed case. +

char and VARCHAR host variables can + also hold values of other SQL types, which will be stored in + their string forms. +

33.4.4.2. Accessing Special Data Types

ECPG contains some special types that help you to interact easily + with some special data types from the PostgreSQL server. In + particular, it has implemented support for the + numeric, decimal, date, timestamp, + and interval types. These data types cannot usefully be + mapped to primitive host variable types (such + as int, long long int, + or char[]), because they have a complex internal + structure. Applications deal with these types by declaring host + variables in special types and accessing them using functions in + the pgtypes library. The pgtypes library, described in detail + in Section 33.6 contains basic functions to deal + with those types, such that you do not need to send a query to + the SQL server just for adding an interval to a time stamp for + example. +

The follow subsections describe these special data types. For + more details about pgtypes library functions, + see Section 33.6. +

33.4.4.2.1. timestamp, date

Here is a pattern for handling timestamp variables + in the ECPG host application. +

First, the program has to include the header file for the + timestamp type: +

#include <pgtypes_timestamp.h>

+

Next, declare a host variable as type timestamp in + the declare section: +

EXEC SQL BEGIN DECLARE SECTION;
+timestamp ts;
+EXEC SQL END DECLARE SECTION;

+

And after reading a value into the host variable, process it + using pgtypes library functions. In following example, the + timestamp value is converted into text (ASCII) form + with the PGTYPEStimestamp_to_asc() + function: +

EXEC SQL SELECT now()::timestamp INTO :ts;
+
+printf("ts = %s\n", PGTYPEStimestamp_to_asc(ts));

+ This example will show some result like following: +

ts = 2010-06-27 18:03:56.949343

+

In addition, the DATE type can be handled in the same way. The + program has to include pgtypes_date.h, declare a host variable + as the date type and convert a DATE value into a text form using + PGTYPESdate_to_asc() function. For more details about the + pgtypes library functions, see Section 33.6. +

33.4.4.2.2. interval

The handling of the interval type is also similar + to the timestamp and date types. It + is required, however, to allocate memory for + an interval type value explicitly. In other words, + the memory space for the variable has to be allocated in the + heap memory, not in the stack memory. +

Here is an example program: +

#include <stdio.h>
+#include <stdlib.h>
+#include <pgtypes_interval.h>
+
+int
+main(void)
+{
+EXEC SQL BEGIN DECLARE SECTION;
+    interval *in;
+EXEC SQL END DECLARE SECTION;
+
+    EXEC SQL CONNECT TO testdb;
+
+    in = PGTYPESinterval_new();
+    EXEC SQL SELECT '1 min'::interval INTO :in;
+    printf("interval = %s\n", PGTYPESinterval_to_asc(in));
+    PGTYPESinterval_free(in);
+
+    EXEC SQL COMMIT;
+    EXEC SQL DISCONNECT ALL;
+    return 0;
+}

+

33.4.4.2.3. numeric, decimal

The handling of the numeric + and decimal types is similar to the + interval type: It requires defining a pointer, + allocating some memory space on the heap, and accessing the + variable using the pgtypes library functions. For more details + about the pgtypes library functions, + see Section 33.6. +

No functions are provided specifically for + the decimal type. An application has to convert it + to a numeric variable using a pgtypes library + function to do further processing. +

Here is an example program handling numeric + and decimal type variables. +

#include <stdio.h>
+#include <stdlib.h>
+#include <pgtypes_numeric.h>
+
+EXEC SQL WHENEVER SQLERROR STOP;
+
+int
+main(void)
+{
+EXEC SQL BEGIN DECLARE SECTION;
+    numeric *num;
+    numeric *num2;
+    decimal *dec;
+EXEC SQL END DECLARE SECTION;
+
+    EXEC SQL CONNECT TO testdb;
+
+    num = PGTYPESnumeric_new();
+    dec = PGTYPESdecimal_new();
+
+    EXEC SQL SELECT 12.345::numeric(4,2), 23.456::decimal(4,2) INTO :num, :dec;
+
+    printf("numeric = %s\n", PGTYPESnumeric_to_asc(num, 0));
+    printf("numeric = %s\n", PGTYPESnumeric_to_asc(num, 1));
+    printf("numeric = %s\n", PGTYPESnumeric_to_asc(num, 2));
+
+    /* Convert decimal to numeric to show a decimal value. */
+    num2 = PGTYPESnumeric_new();
+    PGTYPESnumeric_from_decimal(dec, num2);
+
+    printf("decimal = %s\n", PGTYPESnumeric_to_asc(num2, 0));
+    printf("decimal = %s\n", PGTYPESnumeric_to_asc(num2, 1));
+    printf("decimal = %s\n", PGTYPESnumeric_to_asc(num2, 2));
+
+    PGTYPESnumeric_free(num2);
+    PGTYPESdecimal_free(dec);
+    PGTYPESnumeric_free(num);
+
+    EXEC SQL COMMIT;
+    EXEC SQL DISCONNECT ALL;
+    return 0;
+}

+

33.4.4.3. Host Variables with Nonprimitive Types

As a host variable you can also use arrays, typedefs, structs, and + pointers. +

33.4.4.3.1. Arrays

There are two use cases for arrays as host variables. The first + is a way to store some text string in char[] + or VARCHAR[], as + explained Section 33.4.4.1. The second use case is to + retrieve multiple rows from a query result without using a + cursor. Without an array, to process a query result consisting + of multiple rows, it is required to use a cursor and + the FETCH command. But with array host + variables, multiple rows can be received at once. The length of + the array has to be defined to be able to accommodate all rows, + otherwise a buffer overflow will likely occur. +

Following example scans the pg_database + system table and shows all OIDs and names of the available + databases: +

int
+main(void)
+{
+EXEC SQL BEGIN DECLARE SECTION;
+    int dbid[8];
+    char dbname[8][16];
+    int i;
+EXEC SQL END DECLARE SECTION;
+
+    memset(dbname, 0, sizeof(char)* 16 * 8);
+    memset(dbid, 0, sizeof(int) * 8);
+
+    EXEC SQL CONNECT TO testdb;
+
+    /* Retrieve multiple rows into arrays at once. */
+    EXEC SQL SELECT oid,datname INTO :dbid, :dbname FROM pg_database;
+
+    for (i = 0; i < 8; i++)
+        printf("oid=%d, dbname=%s\n", dbid[i], dbname[i]);
+
+    EXEC SQL COMMIT;
+    EXEC SQL DISCONNECT ALL;
+    return 0;
+}

+ + This example shows following result. (The exact values depend on + local circumstances.) +

oid=1, dbname=template1
+oid=11510, dbname=template0
+oid=11511, dbname=postgres
+oid=313780, dbname=testdb
+oid=0, dbname=
+oid=0, dbname=
+oid=0, dbname=

+

33.4.4.3.2. Structures

A structure whose member names match the column names of a query + result, can be used to retrieve multiple columns at once. The + structure enables handling multiple column values in a single + host variable. +

The following example retrieves OIDs, names, and sizes of the + available databases from the pg_database + system table and using + the pg_database_size() function. In this + example, a structure variable dbinfo_t with + members whose names match each column in + the SELECT result is used to retrieve one + result row without putting multiple host variables in + the FETCH statement. +

EXEC SQL BEGIN DECLARE SECTION;
+    typedef struct
+    {
+       int oid;
+       char datname[65];
+       long long int size;
+    } dbinfo_t;
+
+    dbinfo_t dbval;
+EXEC SQL END DECLARE SECTION;
+
+    memset(&dbval, 0, sizeof(dbinfo_t));
+
+    EXEC SQL DECLARE cur1 CURSOR FOR SELECT oid, datname, pg_database_size(oid) AS size FROM pg_database;
+    EXEC SQL OPEN cur1;
+
+    /* when end of result set reached, break out of while loop */
+    EXEC SQL WHENEVER NOT FOUND DO BREAK;
+
+    while (1)
+    {
+        /* Fetch multiple columns into one structure. */
+        EXEC SQL FETCH FROM cur1 INTO :dbval;
+
+        /* Print members of the structure. */
+        printf("oid=%d, datname=%s, size=%lld\n", dbval.oid, dbval.datname, dbval.size);
+    }
+
+    EXEC SQL CLOSE cur1;

+

This example shows following result. (The exact values depend on + local circumstances.) +

oid=1, datname=template1, size=4324580
+oid=11510, datname=template0, size=4243460
+oid=11511, datname=postgres, size=4324580
+oid=313780, datname=testdb, size=8183012

+

Structure host variables "absorb" as many columns + as the structure as fields. Additional columns can be assigned + to other host variables. For example, the above program could + also be restructured like this, with the size + variable outside the structure: +

EXEC SQL BEGIN DECLARE SECTION;
+    typedef struct
+    {
+       int oid;
+       char datname[65];
+    } dbinfo_t;
+
+    dbinfo_t dbval;
+    long long int size;
+EXEC SQL END DECLARE SECTION;
+
+    memset(&dbval, 0, sizeof(dbinfo_t));
+
+    EXEC SQL DECLARE cur1 CURSOR FOR SELECT oid, datname, pg_database_size(oid) AS size FROM pg_database;
+    EXEC SQL OPEN cur1;
+
+    /* when end of result set reached, break out of while loop */
+    EXEC SQL WHENEVER NOT FOUND DO BREAK;
+
+    while (1)
+    {
+        /* Fetch multiple columns into one structure. */
+        EXEC SQL FETCH FROM cur1 INTO :dbval, :size;
+
+        /* Print members of the structure. */
+        printf("oid=%d, datname=%s, size=%lld\n", dbval.oid, dbval.datname, size);
+    }
+
+    EXEC SQL CLOSE cur1;

+

33.4.4.3.3. Typedefs

Use the typedef keyword to map new types to already + existing types. +

EXEC SQL BEGIN DECLARE SECTION;
+    typedef char mychartype[40];
+    typedef long serial_t;
+EXEC SQL END DECLARE SECTION;

+ Note that you could also use: +

EXEC SQL TYPE serial_t IS long;

+ This declaration does not need to be part of a declare section. +

33.4.4.3.4. Pointers

You can declare pointers to the most common types. Note however + that you cannot use pointers as target variables of queries + without auto-allocation. See Section 33.7 + for more information on auto-allocation. +

EXEC SQL BEGIN DECLARE SECTION;
+    int   *intp;
+    char **charp;
+EXEC SQL END DECLARE SECTION;

+

33.4.5. Handling Nonprimitive SQL Data Types

This section contains information on how to handle nonscalar and + user-defined SQL-level data types in ECPG applications. Note that + this is distinct from the handling of host variables of + nonprimitive types, described in the previous section. +

33.4.5.1. Arrays

SQL-level arrays are not directly supported in ECPG. It is not + possible to simply map an SQL array into a C array host variable. + This will result in undefined behavior. Some workarounds exist, + however. +

If a query accesses elements of an array + separately, then this avoids the use of arrays in ECPG. Then, a + host variable with a type that can be mapped to the element type + should be used. For example, if a column type is array of + integer, a host variable of type int + can be used. Also if the element type is varchar + or text, a host variable of type char[] + or VARCHAR[] can be used. +

Here is an example. Assume the following table: +

CREATE TABLE t3 (
+    ii integer[]
+);
+
+testdb=> SELECT * FROM t3;
+     ii
+-------------
+ {1,2,3,4,5}
+(1 row)

+ + The following example program retrieves the 4th element of the + array and stores it into a host variable of + type int: +

EXEC SQL BEGIN DECLARE SECTION;
+int ii;
+EXEC SQL END DECLARE SECTION;
+
+EXEC SQL DECLARE cur1 CURSOR FOR SELECT ii[4] FROM t3;
+EXEC SQL OPEN cur1;
+
+EXEC SQL WHENEVER NOT FOUND DO BREAK;
+
+while (1)
+{
+    EXEC SQL FETCH FROM cur1 INTO :ii ;
+    printf("ii=%d\n", ii);
+}
+
+EXEC SQL CLOSE cur1;

+ + This example shows the following result: +

ii=4

+

To map multiple array elements to the multiple elements in an + array type host variables each element of array column and each + element of the host variable array have to be managed separately, + for example: +

EXEC SQL BEGIN DECLARE SECTION;
+int ii_a[8];
+EXEC SQL END DECLARE SECTION;
+
+EXEC SQL DECLARE cur1 CURSOR FOR SELECT ii[1], ii[2], ii[3], ii[4] FROM t3;
+EXEC SQL OPEN cur1;
+
+EXEC SQL WHENEVER NOT FOUND DO BREAK;
+
+while (1)
+{
+    EXEC SQL FETCH FROM cur1 INTO :ii_a[0], :ii_a[1], :ii_a[2], :ii_a[3];
+    ...
+}

+

Note again that +

EXEC SQL BEGIN DECLARE SECTION;
+int ii_a[8];
+EXEC SQL END DECLARE SECTION;
+
+EXEC SQL DECLARE cur1 CURSOR FOR SELECT ii FROM t3;
+EXEC SQL OPEN cur1;
+
+EXEC SQL WHENEVER NOT FOUND DO BREAK;
+
+while (1)
+{
+    /* WRONG */
+    EXEC SQL FETCH FROM cur1 INTO :ii_a;
+    ...
+}

+ would not work correctly in this case, because you cannot map an + array type column to an array host variable directly. +

Another workaround is to store arrays in their external string + representation in host variables of type char[] + or VARCHAR[]. For more details about this + representation, see Section 8.15.2. Note that + this means that the array cannot be accessed naturally as an + array in the host program (without further processing that parses + the text representation). +

33.4.5.2. Composite Types

Composite types are not directly supported in ECPG, but an easy workaround is possible. + The + available workarounds are similar to the ones described for + arrays above: Either access each attribute separately or use the + external string representation. +

For the following examples, assume the following type and table: +

CREATE TYPE comp_t AS (intval integer, textval varchar(32));
+CREATE TABLE t4 (compval comp_t);
+INSERT INTO t4 VALUES ( (256, 'PostgreSQL') );

+ + The most obvious solution is to access each attribute separately. + The following program retrieves data from the example table by + selecting each attribute of the type comp_t + separately: +

EXEC SQL BEGIN DECLARE SECTION;
+int intval;
+varchar textval[33];
+EXEC SQL END DECLARE SECTION;
+
+/* Put each element of the composite type column in the SELECT list. */
+EXEC SQL DECLARE cur1 CURSOR FOR SELECT (compval).intval, (compval).textval FROM t4;
+EXEC SQL OPEN cur1;
+
+EXEC SQL WHENEVER NOT FOUND DO BREAK;
+
+while (1)
+{
+    /* Fetch each element of the composite type column into host variables. */
+    EXEC SQL FETCH FROM cur1 INTO :intval, :textval;
+
+    printf("intval=%d, textval=%s\n", intval, textval.arr);
+}
+
+EXEC SQL CLOSE cur1;

+

To enhance this example, the host variables to store values in + the FETCH command can be gathered into one + structure. For more details about the host variable in the + structure form, see Section 33.4.4.3.2. + To switch to the structure, the example can be modified as below. + The two host variables, intval + and textval, become members of + the comp_t structure, and the structure + is specified on the FETCH command. +

EXEC SQL BEGIN DECLARE SECTION;
+typedef struct
+{
+    int intval;
+    varchar textval[33];
+} comp_t;
+
+comp_t compval;
+EXEC SQL END DECLARE SECTION;
+
+/* Put each element of the composite type column in the SELECT list. */
+EXEC SQL DECLARE cur1 CURSOR FOR SELECT (compval).intval, (compval).textval FROM t4;
+EXEC SQL OPEN cur1;
+
+EXEC SQL WHENEVER NOT FOUND DO BREAK;
+
+while (1)
+{
+    /* Put all values in the SELECT list into one structure. */
+    EXEC SQL FETCH FROM cur1 INTO :compval;
+
+    printf("intval=%d, textval=%s\n", compval.intval, compval.textval.arr);
+}
+
+EXEC SQL CLOSE cur1;

+ + Although a structure is used in the FETCH + command, the attribute names in the SELECT + clause are specified one by one. This can be enhanced by using + a * to ask for all attributes of the composite + type value. +

...
+EXEC SQL DECLARE cur1 CURSOR FOR SELECT (compval).* FROM t4;
+EXEC SQL OPEN cur1;
+
+EXEC SQL WHENEVER NOT FOUND DO BREAK;
+
+while (1)
+{
+    /* Put all values in the SELECT list into one structure. */
+    EXEC SQL FETCH FROM cur1 INTO :compval;
+
+    printf("intval=%d, textval=%s\n", compval.intval, compval.textval.arr);
+}
+...

+ This way, composite types can be mapped into structures almost + seamlessly, even though ECPG does not understand the composite + type itself. +

Finally, it is also possible to store composite type values in + their external string representation in host variables of + type char[] or VARCHAR[]. But that + way, it is not easily possible to access the fields of the value + from the host program. +

33.4.5.3. User-defined Base Types

New user-defined base types are not directly supported by ECPG. + You can use the external string representation and host variables + of type char[] or VARCHAR[], and this + solution is indeed appropriate and sufficient for many types. +

Here is an example using the data type complex from + the example in Section 35.11. The external string + representation of that type is (%lf,%lf), + which is defined in the + functions complex_in() + and complex_out() functions + in Section 35.11. The following example inserts the + complex type values (1,1) + and (3,3) into the + columns a and b, and select + them from the table after that. + +

EXEC SQL BEGIN DECLARE SECTION;
+    varchar a[64];
+    varchar b[64];
+EXEC SQL END DECLARE SECTION;
+
+    EXEC SQL INSERT INTO test_complex VALUES ('(1,1)', '(3,3)');
+
+    EXEC SQL DECLARE cur1 CURSOR FOR SELECT a, b FROM test_complex;
+    EXEC SQL OPEN cur1;
+
+    EXEC SQL WHENEVER NOT FOUND DO BREAK;
+
+    while (1)
+    {
+        EXEC SQL FETCH FROM cur1 INTO :a, :b;
+        printf("a=%s, b=%s\n", a.arr, b.arr);
+    }
+
+    EXEC SQL CLOSE cur1;

+ + This example shows following result: +

a=(1,1), b=(3,3)

+

Another workaround is avoiding the direct use of the user-defined + types in ECPG and instead create a function or cast that converts + between the user-defined type and a primitive type that ECPG can + handle. Note, however, that type casts, especially implicit + ones, should be introduced into the type system very carefully. +

For example, +

CREATE FUNCTION create_complex(r double, i double) RETURNS complex
+LANGUAGE SQL
+IMMUTABLE
+AS $$ SELECT $1 * complex '(1,0')' + $2 * complex '(0,1)' $$;

+ After this definition, the following +

EXEC SQL BEGIN DECLARE SECTION;
+double a, b, c, d;
+EXEC SQL END DECLARE SECTION;
+
+a = 1;
+b = 2;
+c = 3;
+d = 4;
+
+EXEC SQL INSERT INTO test_complex VALUES (create_complex(:a, :b), create_complex(:c, :d));

+ has the same effect as +

EXEC SQL INSERT INTO test_complex VALUES ('(1,2)', '(3,4)');

+

33.4.6. Indicators

The examples above do not handle null values. In fact, the + retrieval examples will raise an error if they fetch a null value + from the database. To be able to pass null values to the database + or retrieve null values from the database, you need to append a + second host variable specification to each host variable that + contains data. This second host variable is called the + indicator and contains a flag that tells + whether the datum is null, in which case the value of the real + host variable is ignored. Here is an example that handles the + retrieval of null values correctly: +

EXEC SQL BEGIN DECLARE SECTION;
+VARCHAR val;
+int val_ind;
+EXEC SQL END DECLARE SECTION:
+
+ ...
+
+EXEC SQL SELECT b INTO :val :val_ind FROM test1;

+ The indicator variable val_ind will be zero if + the value was not null, and it will be negative if the value was + null. +

The indicator has another function: if the indicator value is + positive, it means that the value is not null, but it was + truncated when it was stored in the host variable. +

If the argument -r no_indicator is passed to + the preprocessor ecpg, it works in + "no-indicator" mode. In no-indicator mode, if no + indicator variable is specified, null values are signaled (on + input and output) for character string types as empty string and + for integer types as the lowest possible value for type (for + example, INT_MIN for int). +


PrevHomeNext
Running SQL CommandsUpDynamic SQL
\ No newline at end of file diff --git a/doc/src/sgml/html/ecpg.html b/doc/src/sgml/html/ecpg.html new file mode 100644 index 000000000..e3112a82b --- /dev/null +++ b/doc/src/sgml/html/ecpg.html @@ -0,0 +1,623 @@ + +ECPG - Embedded SQL in C

Chapter 33. ECPG - Embedded SQL in C

Table of Contents
33.1. The Concept
33.2. Managing Database Connections
33.2.1. Connecting to the Database Server
33.2.2. Choosing a Connection
33.2.3. Closing a Connection
33.3. Running SQL Commands
33.3.1. Executing SQL Statements
33.3.2. Using Cursors
33.3.3. Managing Transactions
33.3.4. Prepared Statements
33.4. Using Host Variables
33.4.1. Overview
33.4.2. Declare Sections
33.4.3. Retrieving Query Results
33.4.4. Type Mapping
33.4.5. Handling Nonprimitive SQL Data Types
33.4.6. Indicators
33.5. Dynamic SQL
33.5.1. Executing Statements without a Result Set
33.5.2. Executing a Statement with Input Parameters
33.5.3. Executing a Statement with a Result Set
33.6. pgtypes Library
33.6.1. The numeric Type
33.6.2. The date Type
33.6.3. The timestamp Type
33.6.4. The interval Type
33.6.5. The decimal Type
33.6.6. errno Values of pgtypeslib
33.6.7. Special Constants of pgtypeslib
33.7. Using Descriptor Areas
33.7.1. Named SQL Descriptor Areas
33.7.2. SQLDA Descriptor Areas
33.8. Error Handling
33.8.1. Setting Callbacks
33.8.2. sqlca
33.8.3. SQLSTATE vs. SQLCODE
33.9. Preprocessor Directives
33.9.1. Including Files
33.9.2. The define and undef Directives
33.9.3. ifdef, ifndef, else, elif, and endif Directives
33.10. Processing Embedded SQL Programs
33.11. Library Functions
33.12. Large Objects
33.13. C++ Applications
33.13.1. Scope for Host Variables
33.13.2. C++ Application Development with External C Module
33.14. Embedded SQL Commands
ALLOCATE DESCRIPTOR -- allocate an SQL descriptor area
CONNECT -- establish a database connection
DEALLOCATE DESCRIPTOR -- deallocate an SQL descriptor area
DECLARE -- define a cursor
DESCRIBE -- obtain information about a prepared statement or result set
DISCONNECT -- terminate a database connection
EXECUTE IMMEDIATE -- dynamically prepare and execute a statement
GET DESCRIPTOR -- get information from an SQL descriptor area
OPEN -- open a dynamic cursor
PREPARE -- prepare a statement for execution
SET AUTOCOMMIT -- set the autocommit behavior of the current session
SET CONNECTION -- select a database connection
SET DESCRIPTOR -- set information in an SQL descriptor area
TYPE -- define a new data type
VAR -- define a variable
WHENEVER -- specify the action to be taken when an SQL statement causes a specific class condition to be raised
33.15. Informix Compatibility Mode
33.15.1. Additional Types
33.15.2. Additional/Missing Embedded SQL Statements
33.15.3. Informix-compatible SQLDA Descriptor Areas
33.15.4. Additional Functions
33.15.5. Additional Constants
33.16. Internals

This chapter describes the embedded SQL package + for PostgreSQL. It was written by + Linus Tolke (<linus@epact.se>) and Michael Meskes + (<meskes@postgresql.org>). Originally it was written to work with + C. It also works with C++, but + it does not recognize all C++ constructs yet. +

This documentation is quite incomplete. But since this + interface is standardized, additional information can be found in + many resources about SQL. +


PrevHomeNext
Example ProgramUpThe Concept
\ No newline at end of file diff --git a/doc/src/sgml/html/encryption-options.html b/doc/src/sgml/html/encryption-options.html new file mode 100644 index 000000000..1d8565a28 --- /dev/null +++ b/doc/src/sgml/html/encryption-options.html @@ -0,0 +1,319 @@ + +Encryption Options
PostgreSQL 9.2.2 Documentation
PrevUpChapter 17. Server Setup and OperationNext

17.8. Encryption Options

PostgreSQL offers encryption at several + levels, and provides flexibility in protecting data from disclosure + due to database server theft, unscrupulous administrators, and + insecure networks. Encryption might also be required to secure + sensitive data such as medical records or financial transactions. +

Password Storage Encryption

By default, database user passwords are stored as MD5 hashes, so + the administrator cannot determine the actual password assigned + to the user. If MD5 encryption is used for client authentication, + the unencrypted password is never even temporarily present on the + server because the client MD5-encrypts it before being sent + across the network. +

Encryption For Specific Columns

The pgcrypto module allows certain fields to be + stored encrypted. + This is useful if only some of the data is sensitive. + The client supplies the decryption key and the data is decrypted + on the server and then sent to the client. +

The decrypted data and the decryption key are present on the + server for a brief time while it is being decrypted and + communicated between the client and server. This presents a brief + moment where the data and keys can be intercepted by someone with + complete access to the database server, such as the system + administrator. +

Data Partition Encryption

On Linux, encryption can be layered on top of a file system + using a "loopback device". This allows an entire + file system partition to be encrypted on disk, and decrypted by the + operating system. On FreeBSD, the equivalent facility is called + GEOM Based Disk Encryption (gbde), and many + other operating systems support this functionality, including Windows. +

This mechanism prevents unencrypted data from being read from the + drives if the drives or the entire computer is stolen. This does + not protect against attacks while the file system is mounted, + because when mounted, the operating system provides an unencrypted + view of the data. However, to mount the file system, you need some + way for the encryption key to be passed to the operating system, + and sometimes the key is stored somewhere on the host that mounts + the disk. +

Encrypting Passwords Across A Network

The MD5 authentication method double-encrypts the + password on the client before sending it to the server. It first + MD5-encrypts it based on the user name, and then encrypts it + based on a random salt sent by the server when the database + connection was made. It is this double-encrypted value that is + sent over the network to the server. Double-encryption not only + prevents the password from being discovered, it also prevents + another connection from using the same encrypted password to + connect to the database server at a later time. +

Encrypting Data Across A Network

SSL connections encrypt all data sent across the network: the + password, the queries, and the data returned. The + pg_hba.conf file allows administrators to specify + which hosts can use non-encrypted connections (host) + and which require SSL-encrypted connections + (hostssl). Also, clients can specify that they + connect to servers only via SSL. Stunnel or + SSH can also be used to encrypt transmissions. +

SSL Host Authentication

It is possible for both the client and server to provide SSL + certificates to each other. It takes some extra configuration + on each side, but this provides stronger verification of identity + than the mere use of passwords. It prevents a computer from + pretending to be the server just long enough to read the password + sent by the client. It also helps prevent "man in the middle" + attacks where a computer between the client and server pretends to + be the server and reads and passes all data between the client and + server. +

Client-Side Encryption

If the system administrator for the server's machine cannot be trusted, + it is necessary + for the client to encrypt the data; this way, unencrypted data + never appears on the database server. Data is encrypted on the + client before being sent to the server, and database results have + to be decrypted on the client before being used. +


PrevHomeNext
Preventing Server SpoofingUpSecure TCP/IP Connections with SSL
\ No newline at end of file diff --git a/doc/src/sgml/html/errcodes-appendix.html b/doc/src/sgml/html/errcodes-appendix.html new file mode 100644 index 000000000..675577877 --- /dev/null +++ b/doc/src/sgml/html/errcodes-appendix.html @@ -0,0 +1,3515 @@ + +PostgreSQL Error Codes

Appendix A. PostgreSQL Error Codes

All messages emitted by the PostgreSQL + server are assigned five-character error codes that follow the SQL + standard's conventions for "SQLSTATE" codes. Applications + that need to know which error condition has occurred should usually + test the error code, rather than looking at the textual error + message. The error codes are less likely to change across + PostgreSQL releases, and also are not subject to + change due to localization of error messages. Note that some, but + not all, of the error codes produced by PostgreSQL + are defined by the SQL standard; some additional error codes for + conditions not defined by the standard have been invented or + borrowed from other databases. +

According to the standard, the first two characters of an error code + denote a class of errors, while the last three characters indicate + a specific condition within that class. Thus, an application that + does not recognize the specific error code can still be able to infer + what to do from the error class. +

Table A-1 lists all the error codes defined in + PostgreSQL 9.2.2. (Some are not actually + used at present, but are defined by the SQL standard.) + The error classes are also shown. For each error class there is a + "standard" error code having the last three characters + 000. This code is used only for error conditions that fall + within the class but do not have any more-specific code assigned. +

The symbol shown in the column "Condition Name" is also + the condition name to use in PL/pgSQL. Condition + names can be written in either upper or lower case. (Note that + PL/pgSQL does not recognize warning, as opposed to error, + condition names; those are classes 00, 01, and 02.) +

Table A-1. PostgreSQL Error Codes

Error CodeCondition Name
Class 00 — Successful Completion
00000successful_completion
Class 01 — Warning
01000warning
0100Cdynamic_result_sets_returned
01008implicit_zero_bit_padding
01003null_value_eliminated_in_set_function
01007privilege_not_granted
01006privilege_not_revoked
01004string_data_right_truncation
01P01deprecated_feature
Class 02 — No Data (this is also a warning class per the SQL standard)
02000no_data
02001no_additional_dynamic_result_sets_returned
Class 03 — SQL Statement Not Yet Complete
03000sql_statement_not_yet_complete
Class 08 — Connection Exception
08000connection_exception
08003connection_does_not_exist
08006connection_failure
08001sqlclient_unable_to_establish_sqlconnection
08004sqlserver_rejected_establishment_of_sqlconnection
08007transaction_resolution_unknown
08P01protocol_violation
Class 09 — Triggered Action Exception
09000triggered_action_exception
Class 0A — Feature Not Supported
0A000feature_not_supported
Class 0B — Invalid Transaction Initiation
0B000invalid_transaction_initiation
Class 0F — Locator Exception
0F000locator_exception
0F001invalid_locator_specification
Class 0L — Invalid Grantor
0L000invalid_grantor
0LP01invalid_grant_operation
Class 0P — Invalid Role Specification
0P000invalid_role_specification
Class 0Z — Diagnostics Exception
0Z000diagnostics_exception
0Z002stacked_diagnostics_accessed_without_active_handler
Class 20 — Case Not Found
20000case_not_found
Class 21 — Cardinality Violation
21000cardinality_violation
Class 22 — Data Exception
22000data_exception
2202Earray_subscript_error
22021character_not_in_repertoire
22008datetime_field_overflow
22012division_by_zero
22005error_in_assignment
2200Bescape_character_conflict
22022indicator_overflow
22015interval_field_overflow
2201Einvalid_argument_for_logarithm
22014invalid_argument_for_ntile_function
22016invalid_argument_for_nth_value_function
2201Finvalid_argument_for_power_function
2201Ginvalid_argument_for_width_bucket_function
22018invalid_character_value_for_cast
22007invalid_datetime_format
22019invalid_escape_character
2200Dinvalid_escape_octet
22025invalid_escape_sequence
22P06nonstandard_use_of_escape_character
22010invalid_indicator_parameter_value
22023invalid_parameter_value
2201Binvalid_regular_expression
2201Winvalid_row_count_in_limit_clause
2201Xinvalid_row_count_in_result_offset_clause
22009invalid_time_zone_displacement_value
2200Cinvalid_use_of_escape_character
2200Gmost_specific_type_mismatch
22004null_value_not_allowed
22002null_value_no_indicator_parameter
22003numeric_value_out_of_range
22026string_data_length_mismatch
22001string_data_right_truncation
22011substring_error
22027trim_error
22024unterminated_c_string
2200Fzero_length_character_string
22P01floating_point_exception
22P02invalid_text_representation
22P03invalid_binary_representation
22P04bad_copy_file_format
22P05untranslatable_character
2200Lnot_an_xml_document
2200Minvalid_xml_document
2200Ninvalid_xml_content
2200Sinvalid_xml_comment
2200Tinvalid_xml_processing_instruction
Class 23 — Integrity Constraint Violation
23000integrity_constraint_violation
23001restrict_violation
23502not_null_violation
23503foreign_key_violation
23505unique_violation
23514check_violation
23P01exclusion_violation
Class 24 — Invalid Cursor State
24000invalid_cursor_state
Class 25 — Invalid Transaction State
25000invalid_transaction_state
25001active_sql_transaction
25002branch_transaction_already_active
25008held_cursor_requires_same_isolation_level
25003inappropriate_access_mode_for_branch_transaction
25004inappropriate_isolation_level_for_branch_transaction
25005no_active_sql_transaction_for_branch_transaction
25006read_only_sql_transaction
25007schema_and_data_statement_mixing_not_supported
25P01no_active_sql_transaction
25P02in_failed_sql_transaction
Class 26 — Invalid SQL Statement Name
26000invalid_sql_statement_name
Class 27 — Triggered Data Change Violation
27000triggered_data_change_violation
Class 28 — Invalid Authorization Specification
28000invalid_authorization_specification
28P01invalid_password
Class 2B — Dependent Privilege Descriptors Still Exist
2B000dependent_privilege_descriptors_still_exist
2BP01dependent_objects_still_exist
Class 2D — Invalid Transaction Termination
2D000invalid_transaction_termination
Class 2F — SQL Routine Exception
2F000sql_routine_exception
2F005function_executed_no_return_statement
2F002modifying_sql_data_not_permitted
2F003prohibited_sql_statement_attempted
2F004reading_sql_data_not_permitted
Class 34 — Invalid Cursor Name
34000invalid_cursor_name
Class 38 — External Routine Exception
38000external_routine_exception
38001containing_sql_not_permitted
38002modifying_sql_data_not_permitted
38003prohibited_sql_statement_attempted
38004reading_sql_data_not_permitted
Class 39 — External Routine Invocation Exception
39000external_routine_invocation_exception
39001invalid_sqlstate_returned
39004null_value_not_allowed
39P01trigger_protocol_violated
39P02srf_protocol_violated
Class 3B — Savepoint Exception
3B000savepoint_exception
3B001invalid_savepoint_specification
Class 3D — Invalid Catalog Name
3D000invalid_catalog_name
Class 3F — Invalid Schema Name
3F000invalid_schema_name
Class 40 — Transaction Rollback
40000transaction_rollback
40002transaction_integrity_constraint_violation
40001serialization_failure
40003statement_completion_unknown
40P01deadlock_detected
Class 42 — Syntax Error or Access Rule Violation
42000syntax_error_or_access_rule_violation
42601syntax_error
42501insufficient_privilege
42846cannot_coerce
42803grouping_error
42P20windowing_error
42P19invalid_recursion
42830invalid_foreign_key
42602invalid_name
42622name_too_long
42939reserved_name
42804datatype_mismatch
42P18indeterminate_datatype
42P21collation_mismatch
42P22indeterminate_collation
42809wrong_object_type
42703undefined_column
42883undefined_function
42P01undefined_table
42P02undefined_parameter
42704undefined_object
42701duplicate_column
42P03duplicate_cursor
42P04duplicate_database
42723duplicate_function
42P05duplicate_prepared_statement
42P06duplicate_schema
42P07duplicate_table
42712duplicate_alias
42710duplicate_object
42702ambiguous_column
42725ambiguous_function
42P08ambiguous_parameter
42P09ambiguous_alias
42P10invalid_column_reference
42611invalid_column_definition
42P11invalid_cursor_definition
42P12invalid_database_definition
42P13invalid_function_definition
42P14invalid_prepared_statement_definition
42P15invalid_schema_definition
42P16invalid_table_definition
42P17invalid_object_definition
Class 44 — WITH CHECK OPTION Violation
44000with_check_option_violation
Class 53 — Insufficient Resources
53000insufficient_resources
53100disk_full
53200out_of_memory
53300too_many_connections
53400configuration_limit_exceeded
Class 54 — Program Limit Exceeded
54000program_limit_exceeded
54001statement_too_complex
54011too_many_columns
54023too_many_arguments
Class 55 — Object Not In Prerequisite State
55000object_not_in_prerequisite_state
55006object_in_use
55P02cant_change_runtime_param
55P03lock_not_available
Class 57 — Operator Intervention
57000operator_intervention
57014query_canceled
57P01admin_shutdown
57P02crash_shutdown
57P03cannot_connect_now
57P04database_dropped
Class 58 — System Error (errors external to PostgreSQL itself)
58000system_error
58030io_error
58P01undefined_file
58P02duplicate_file
Class F0 — Configuration File Error
F0000config_file_error
F0001lock_file_exists
Class HV — Foreign Data Wrapper Error (SQL/MED)
HV000fdw_error
HV005fdw_column_name_not_found
HV002fdw_dynamic_parameter_value_needed
HV010fdw_function_sequence_error
HV021fdw_inconsistent_descriptor_information
HV024fdw_invalid_attribute_value
HV007fdw_invalid_column_name
HV008fdw_invalid_column_number
HV004fdw_invalid_data_type
HV006fdw_invalid_data_type_descriptors
HV091fdw_invalid_descriptor_field_identifier
HV00Bfdw_invalid_handle
HV00Cfdw_invalid_option_index
HV00Dfdw_invalid_option_name
HV090fdw_invalid_string_length_or_buffer_length
HV00Afdw_invalid_string_format
HV009fdw_invalid_use_of_null_pointer
HV014fdw_too_many_handles
HV001fdw_out_of_memory
HV00Pfdw_no_schemas
HV00Jfdw_option_name_not_found
HV00Kfdw_reply_handle
HV00Qfdw_schema_not_found
HV00Rfdw_table_not_found
HV00Lfdw_unable_to_create_execution
HV00Mfdw_unable_to_create_reply
HV00Nfdw_unable_to_establish_connection
Class P0 — PL/pgSQL Error
P0000plpgsql_error
P0001raise_exception
P0002no_data_found
P0003too_many_rows
Class XX — Internal Error
XX000internal_error
XX001data_corrupted
XX002index_corrupted

PrevHomeNext
AppendixesUpDate/Time Support
\ No newline at end of file diff --git a/doc/src/sgml/html/error-message-reporting.html b/doc/src/sgml/html/error-message-reporting.html new file mode 100644 index 000000000..632020d17 --- /dev/null +++ b/doc/src/sgml/html/error-message-reporting.html @@ -0,0 +1,675 @@ + +Reporting Errors Within the Server
PostgreSQL 9.2.2 Documentation
PrevUpChapter 47. PostgreSQL Coding ConventionsNext

47.2. Reporting Errors Within the Server

Error, warning, and log messages generated within the server code + should be created using ereport, or its older cousin + elog. The use of this function is complex enough to + require some explanation. +

There are two required elements for every message: a severity level + (ranging from DEBUG to PANIC) and a primary + message text. In addition there are optional elements, the most + common of which is an error identifier code that follows the SQL spec's + SQLSTATE conventions. + ereport itself is just a shell function, that exists + mainly for the syntactic convenience of making message generation + look like a function call in the C source code. The only parameter + accepted directly by ereport is the severity level. + The primary message text and any optional message elements are + generated by calling auxiliary functions, such as errmsg, + within the ereport call. +

A typical call to ereport might look like this: +

ereport(ERROR,
+        (errcode(ERRCODE_DIVISION_BY_ZERO),
+         errmsg("division by zero")));

+ This specifies error severity level ERROR (a run-of-the-mill + error). The errcode call specifies the SQLSTATE error code + using a macro defined in src/include/utils/errcodes.h. The + errmsg call provides the primary message text. Notice the + extra set of parentheses surrounding the auxiliary function calls — + these are annoying but syntactically necessary. +

Here is a more complex example: +

ereport(ERROR,
+        (errcode(ERRCODE_AMBIGUOUS_FUNCTION),
+         errmsg("function %s is not unique",
+                func_signature_string(funcname, nargs,
+                                      NIL, actual_arg_types)),
+         errhint("Unable to choose a best candidate function. "
+                 "You might need to add explicit typecasts.")));

+ This illustrates the use of format codes to embed run-time values into + a message text. Also, an optional "hint" message is provided. +

The available auxiliary routines for ereport are: +

  • errcode(sqlerrcode) specifies the SQLSTATE error identifier + code for the condition. If this routine is not called, the error + identifier defaults to + ERRCODE_INTERNAL_ERROR when the error severity level is + ERROR or higher, ERRCODE_WARNING when the + error level is WARNING, otherwise (for NOTICE + and below) ERRCODE_SUCCESSFUL_COMPLETION. + While these defaults are often convenient, always think whether they + are appropriate before omitting the errcode() call. +

  • errmsg(const char *msg, ...) specifies the primary error + message text, and possibly run-time values to insert into it. Insertions + are specified by sprintf-style format codes. In addition to + the standard format codes accepted by sprintf, the format + code %m can be used to insert the error message returned + by strerror for the current value of errno. + [1] + %m does not require any + corresponding entry in the parameter list for errmsg. + Note that the message string will be run through gettext + for possible localization before format codes are processed. +

  • errmsg_internal(const char *msg, ...) is the same as + errmsg, except that the message string will not be + translated nor included in the internationalization message dictionary. + This should be used for "cannot happen" cases that are probably + not worth expending translation effort on. +

  • errmsg_plural(const char *fmt_singular, const char *fmt_plural, + unsigned long n, ...) is like errmsg, but with + support for various plural forms of the message. + fmt_singular is the English singular format, + fmt_plural is the English plural format, + n is the integer value that determines which plural + form is needed, and the remaining arguments are formatted according + to the selected format string. For more information see + Section 48.2.2. +

  • errdetail(const char *msg, ...) supplies an optional + "detail" message; this is to be used when there is additional + information that seems inappropriate to put in the primary message. + The message string is processed in just the same way as for + errmsg. +

  • errdetail_internal(const char *msg, ...) is the same + as errdetail, except that the message string will not be + translated nor included in the internationalization message dictionary. + This should be used for detail messages that are not worth expending + translation effort on, for instance because they are too technical to be + useful to most users. +

  • errdetail_plural(const char *fmt_singular, const char *fmt_plural, + unsigned long n, ...) is like errdetail, but with + support for various plural forms of the message. + For more information see Section 48.2.2. +

  • errdetail_log(const char *msg, ...) is the same as + errdetail except that this string goes only to the server + log, never to the client. If both errdetail (or one of + its equivalents above) and + errdetail_log are used then one string goes to the client + and the other to the log. This is useful for error details that are + too security-sensitive or too bulky to include in the report + sent to the client. +

  • errhint(const char *msg, ...) supplies an optional + "hint" message; this is to be used when offering suggestions + about how to fix the problem, as opposed to factual details about + what went wrong. + The message string is processed in just the same way as for + errmsg. +

  • errcontext(const char *msg, ...) is not normally called + directly from an ereport message site; rather it is used + in error_context_stack callback functions to provide + information about the context in which an error occurred, such as the + current location in a PL function. + The message string is processed in just the same way as for + errmsg. Unlike the other auxiliary functions, this can + be called more than once per ereport call; the successive + strings thus supplied are concatenated with separating newlines. +

  • errposition(int cursorpos) specifies the textual location + of an error within a query string. Currently it is only useful for + errors detected in the lexical and syntactic analysis phases of + query processing. +

  • errcode_for_file_access() is a convenience function that + selects an appropriate SQLSTATE error identifier for a failure in a + file-access-related system call. It uses the saved + errno to determine which error code to generate. + Usually this should be used in combination with %m in the + primary error message text. +

  • errcode_for_socket_access() is a convenience function that + selects an appropriate SQLSTATE error identifier for a failure in a + socket-related system call. +

  • errhidestmt(bool hide_stmt) can be called to specify + suppression of the STATEMENT: portion of a message in the + postmaster log. Generally this is appropriate if the message text + includes the current statement already. +

+

There is an older function elog that is still heavily used. + An elog call: +

elog(level, "format string", ...);

+ is exactly equivalent to: +

ereport(level, (errmsg_internal("format string", ...)));

+ Notice that the SQLSTATE error code is always defaulted, and the message + string is not subject to translation. + Therefore, elog should be used only for internal errors and + low-level debug logging. Any message that is likely to be of interest to + ordinary users should go through ereport. Nonetheless, + there are enough internal "cannot happen" error checks in the + system that elog is still widely used; it is preferred for + those messages for its notational simplicity. +

Advice about writing good error messages can be found in + Section 47.3. +

Notes

[1]

That is, the value that was current when the ereport call + was reached; changes of errno within the auxiliary reporting + routines will not affect it. That would not be true if you were to + write strerror(errno) explicitly in errmsg's + parameter list; accordingly, do not do so. +


PrevHomeNext
FormattingUpError Message Style Guide
\ No newline at end of file diff --git a/doc/src/sgml/html/error-style-guide.html b/doc/src/sgml/html/error-style-guide.html new file mode 100644 index 000000000..464cebf42 --- /dev/null +++ b/doc/src/sgml/html/error-style-guide.html @@ -0,0 +1,744 @@ + +Error Message Style Guide
PostgreSQL 9.2.2 Documentation
PrevUpChapter 47. PostgreSQL Coding ConventionsNext

47.3. Error Message Style Guide

This style guide is offered in the hope of maintaining a consistent, + user-friendly style throughout all the messages generated by + PostgreSQL. +

47.3.1. What Goes Where

The primary message should be short, factual, and avoid reference to + implementation details such as specific function names. + "Short" means "should fit on one line under normal + conditions". Use a detail message if needed to keep the primary + message short, or if you feel a need to mention implementation details + such as the particular system call that failed. Both primary and detail + messages should be factual. Use a hint message for suggestions about what + to do to fix the problem, especially if the suggestion might not always be + applicable. +

For example, instead of: +

IpcMemoryCreate: shmget(key=%d, size=%u, 0%o) failed: %m
+(plus a long addendum that is basically a hint)

+ write: +

Primary:    could not create shared memory segment: %m
+Detail:     Failed syscall was shmget(key=%d, size=%u, 0%o).
+Hint:       the addendum

+

Rationale: keeping the primary message short helps keep it to the point, + and lets clients lay out screen space on the assumption that one line is + enough for error messages. Detail and hint messages can be relegated to a + verbose mode, or perhaps a pop-up error-details window. Also, details and + hints would normally be suppressed from the server log to save + space. Reference to implementation details is best avoided since users + don't know the details anyway. +

47.3.2. Formatting

Don't put any specific assumptions about formatting into the message + texts. Expect clients and the server log to wrap lines to fit their own + needs. In long messages, newline characters (\n) can be used to indicate + suggested paragraph breaks. Don't end a message with a newline. Don't + use tabs or other formatting characters. (In error context displays, + newlines are automatically added to separate levels of context such as + function calls.) +

Rationale: Messages are not necessarily displayed on terminal-type + displays. In GUI displays or browsers these formatting instructions are + at best ignored. +

47.3.3. Quotation Marks

English text should use double quotes when quoting is appropriate. + Text in other languages should consistently use one kind of quotes that is + consistent with publishing customs and computer output of other programs. +

Rationale: The choice of double quotes over single quotes is somewhat + arbitrary, but tends to be the preferred use. Some have suggested + choosing the kind of quotes depending on the type of object according to + SQL conventions (namely, strings single quoted, identifiers double + quoted). But this is a language-internal technical issue that many users + aren't even familiar with, it won't scale to other kinds of quoted terms, + it doesn't translate to other languages, and it's pretty pointless, too. +

47.3.4. Use of Quotes

Use quotes always to delimit file names, user-supplied identifiers, and + other variables that might contain words. Do not use them to mark up + variables that will not contain words (for example, operator names). +

There are functions in the backend that will double-quote their own output + at need (for example, format_type_be()). Do not put + additional quotes around the output of such functions. +

Rationale: Objects can have names that create ambiguity when embedded in a + message. Be consistent about denoting where a plugged-in name starts and + ends. But don't clutter messages with unnecessary or duplicate quote + marks. +

47.3.5. Grammar and Punctuation

The rules are different for primary error messages and for detail/hint + messages: +

Primary error messages: Do not capitalize the first letter. Do not end a + message with a period. Do not even think about ending a message with an + exclamation point. +

Detail and hint messages: Use complete sentences, and end each with + a period. Capitalize the first word of sentences. Put two spaces after + the period if another sentence follows (for English text; might be + inappropriate in other languages). +

Error context strings: Do not capitalize the first letter and do + not end the string with a period. Context strings should normally + not be complete sentences. +

Rationale: Avoiding punctuation makes it easier for client applications to + embed the message into a variety of grammatical contexts. Often, primary + messages are not grammatically complete sentences anyway. (And if they're + long enough to be more than one sentence, they should be split into + primary and detail parts.) However, detail and hint messages are longer + and might need to include multiple sentences. For consistency, they should + follow complete-sentence style even when there's only one sentence. +

47.3.6. Upper Case vs. Lower Case

Use lower case for message wording, including the first letter of a + primary error message. Use upper case for SQL commands and key words if + they appear in the message. +

Rationale: It's easier to make everything look more consistent this + way, since some messages are complete sentences and some not. +

47.3.7. Avoid Passive Voice

Use the active voice. Use complete sentences when there is an acting + subject ("A could not do B"). Use telegram style without + subject if the subject would be the program itself; do not use + "I" for the program. +

Rationale: The program is not human. Don't pretend otherwise. +

47.3.8. Present vs. Past Tense

Use past tense if an attempt to do something failed, but could perhaps + succeed next time (perhaps after fixing some problem). Use present tense + if the failure is certainly permanent. +

There is a nontrivial semantic difference between sentences of the form: +

could not open file "%s": %m

+and: +

cannot open file "%s"

+ The first one means that the attempt to open the file failed. The + message should give a reason, such as "disk full" or + "file doesn't exist". The past tense is appropriate because + next time the disk might not be full anymore or the file in question might + exist. +

The second form indicates that the functionality of opening the named file + does not exist at all in the program, or that it's conceptually + impossible. The present tense is appropriate because the condition will + persist indefinitely. +

Rationale: Granted, the average user will not be able to draw great + conclusions merely from the tense of the message, but since the language + provides us with a grammar we should use it correctly. +

47.3.9. Type of the Object

When citing the name of an object, state what kind of object it is. +

Rationale: Otherwise no one will know what "foo.bar.baz" + refers to. +

47.3.10. Brackets

Square brackets are only to be used (1) in command synopses to denote + optional arguments, or (2) to denote an array subscript. +

Rationale: Anything else does not correspond to widely-known customary + usage and will confuse people. +

47.3.11. Assembling Error Messages

When a message includes text that is generated elsewhere, embed it in + this style: +

could not open file %s: %m

+

Rationale: It would be difficult to account for all possible error codes + to paste this into a single smooth sentence, so some sort of punctuation + is needed. Putting the embedded text in parentheses has also been + suggested, but it's unnatural if the embedded text is likely to be the + most important part of the message, as is often the case. +

47.3.12. Reasons for Errors

Messages should always state the reason why an error occurred. + For example: +

BAD:    could not open file %s
+BETTER: could not open file %s (I/O failure)

+ If no reason is known you better fix the code. +

47.3.13. Function Names

Don't include the name of the reporting routine in the error text. We have + other mechanisms for finding that out when needed, and for most users it's + not helpful information. If the error text doesn't make as much sense + without the function name, reword it. +

BAD:    pg_atoi: error in "z": cannot parse "z"
+BETTER: invalid input syntax for integer: "z"

+

Avoid mentioning called function names, either; instead say what the code + was trying to do: +

BAD:    open() failed: %m
+BETTER: could not open file %s: %m

+ If it really seems necessary, mention the system call in the detail + message. (In some cases, providing the actual values passed to the + system call might be appropriate information for the detail message.) +

Rationale: Users don't know what all those functions do. +

47.3.14. Tricky Words to Avoid

Unable. "Unable" is nearly the passive voice. Better use + "cannot" or "could not", as appropriate. +

Bad. Error messages like "bad result" are really hard to interpret + intelligently. It's better to write why the result is "bad", + e.g., "invalid format". +

Illegal. "Illegal" stands for a violation of the law, the rest is + "invalid". Better yet, say why it's invalid. +

Unknown. Try to avoid "unknown". Consider "error: unknown + response". If you don't know what the response is, how do you know + it's erroneous? "Unrecognized" is often a better choice. + Also, be sure to include the value being complained of. +

BAD:    unknown node type
+BETTER: unrecognized node type: 42

+

Find vs. Exists. If the program uses a nontrivial algorithm to locate a resource (e.g., a + path search) and that algorithm fails, it is fair to say that the program + couldn't "find" the resource. If, on the other hand, the + expected location of the resource is known but the program cannot access + it there then say that the resource doesn't "exist". Using + "find" in this case sounds weak and confuses the issue. +

May vs. Can vs. Might. "May" suggests permission (e.g., "You may borrow my rake."), + and has little use in documentation or error messages. + "Can" suggests ability (e.g., "I can lift that log."), + and "might" suggests possibility (e.g., "It might rain + today."). Using the proper word clarifies meaning and assists + translation. +

Contractions. Avoid contractions, like "can't"; use + "cannot" instead. +

47.3.15. Proper Spelling

Spell out words in full. For instance, avoid: +

  • spec +

  • stats +

  • parens +

  • auth +

  • xact +

+

Rationale: This will improve consistency. +

47.3.16. Localization

Keep in mind that error message texts need to be translated into other + languages. Follow the guidelines in Section 48.2.2 + to avoid making life difficult for translators. +


PrevHomeNext
Reporting Errors Within the ServerUpNative Language Support
\ No newline at end of file diff --git a/doc/src/sgml/html/event-log-registration.html b/doc/src/sgml/html/event-log-registration.html new file mode 100644 index 000000000..24f590fd7 --- /dev/null +++ b/doc/src/sgml/html/event-log-registration.html @@ -0,0 +1,277 @@ + +Registering Event Log on Windows
PostgreSQL 9.2.2 Documentation
PrevUpChapter 17. Server Setup and OperationNext

17.11. Registering Event Log on Windows

To register a Windows + event log library with the operating system, + issue this command: +

regsvr32 pgsql_library_directory/pgevent.dll

+ This creates registry entries used by the event viewer, under the default + event source named PostgreSQL. +

To specify a different event source name (see + event_source), use the /n + and /i options: +

regsvr32 /n /i:event_source_name pgsql_library_directory/pgevent.dll

+

To unregister the event log library from + the operating system, issue this command: +

regsvr32 /u [/i:event_source_name] pgsql_library_directory/pgevent.dll

+

Note: To enable event logging in the database server, modify + log_destination to include + eventlog in postgresql.conf. +


PrevHomeNext
Secure TCP/IP Connections with SSH TunnelsUpServer Configuration
\ No newline at end of file diff --git a/doc/src/sgml/html/executor.html b/doc/src/sgml/html/executor.html new file mode 100644 index 000000000..2ec76a45f --- /dev/null +++ b/doc/src/sgml/html/executor.html @@ -0,0 +1,311 @@ + +Executor
PostgreSQL 9.2.2 Documentation
PrevUpChapter 44. Overview of PostgreSQL InternalsNext

44.6. Executor

The executor takes the plan created by the + planner/optimizer and recursively processes it to extract the required set + of rows. This is essentially a demand-pull pipeline mechanism. + Each time a plan node is called, it must deliver one more row, or + report that it is done delivering rows. +

To provide a concrete example, assume that the top + node is a MergeJoin node. + Before any merge can be done two rows have to be fetched (one from + each subplan). So the executor recursively calls itself to + process the subplans (it starts with the subplan attached to + lefttree). The new top node (the top node of the left + subplan) is, let's say, a + Sort node and again recursion is needed to obtain + an input row. The child node of the Sort might + be a SeqScan node, representing actual reading of a table. + Execution of this node causes the executor to fetch a row from the + table and return it up to the calling node. The Sort + node will repeatedly call its child to obtain all the rows to be sorted. + When the input is exhausted (as indicated by the child node returning + a NULL instead of a row), the Sort code performs + the sort, and finally is able to return its first output row, namely + the first one in sorted order. It keeps the remaining rows stored so + that it can deliver them in sorted order in response to later demands. +

The MergeJoin node similarly demands the first row + from its right subplan. Then it compares the two rows to see if they + can be joined; if so, it returns a join row to its caller. On the next + call, or immediately if it cannot join the current pair of inputs, + it advances to the next row of one table + or the other (depending on how the comparison came out), and again + checks for a match. Eventually, one subplan or the other is exhausted, + and the MergeJoin node returns NULL to indicate that + no more join rows can be formed. +

Complex queries can involve many levels of plan nodes, but the general + approach is the same: each node computes and returns its next output + row each time it is called. Each node is also responsible for applying + any selection or projection expressions that were assigned to it by + the planner. +

The executor mechanism is used to evaluate all four basic SQL query types: + SELECT, INSERT, UPDATE, and + DELETE. For SELECT, the top-level executor + code only needs to send each row returned by the query plan tree off + to the client. For INSERT, each returned row is inserted + into the target table specified for the INSERT. This is + done in a special top-level plan node called ModifyTable. + (A simple + INSERT ... VALUES command creates a trivial plan tree + consisting of a single Result node, which computes just one + result row, and ModifyTable above it to perform the insertion. + But INSERT ... SELECT can demand the full power + of the executor mechanism.) For UPDATE, the planner arranges + that each computed row includes all the updated column values, plus + the TID (tuple ID, or row ID) of the original target row; + this data is fed into a ModifyTable node, which uses the + information to create a new updated row and mark the old row deleted. + For DELETE, the only column that is actually returned by the + plan is the TID, and the ModifyTable node simply uses the TID + to visit each target row and mark it deleted. +


PrevHomeNext
Planner/OptimizerUpSystem Catalogs
\ No newline at end of file diff --git a/doc/src/sgml/html/explicit-joins.html b/doc/src/sgml/html/explicit-joins.html new file mode 100644 index 000000000..4fc2c77ba --- /dev/null +++ b/doc/src/sgml/html/explicit-joins.html @@ -0,0 +1,434 @@ + +Controlling the Planner with Explicit JOIN Clauses
PostgreSQL 9.2.2 Documentation
PrevUpChapter 14. Performance TipsNext

14.3. Controlling the Planner with Explicit JOIN Clauses

It is possible + to control the query planner to some extent by using the explicit JOIN + syntax. To see why this matters, we first need some background. +

In a simple join query, such as: +

SELECT * FROM a, b, c WHERE a.id = b.id AND b.ref = c.id;

+ the planner is free to join the given tables in any order. For + example, it could generate a query plan that joins A to B, using + the WHERE condition a.id = b.id, and then + joins C to this joined table, using the other WHERE + condition. Or it could join B to C and then join A to that result. + Or it could join A to C and then join them with B — but that + would be inefficient, since the full Cartesian product of A and C + would have to be formed, there being no applicable condition in the + WHERE clause to allow optimization of the join. (All + joins in the PostgreSQL executor happen + between two input tables, so it's necessary to build up the result + in one or another of these fashions.) The important point is that + these different join possibilities give semantically equivalent + results but might have hugely different execution costs. Therefore, + the planner will explore all of them to try to find the most + efficient query plan. +

When a query only involves two or three tables, there aren't many join + orders to worry about. But the number of possible join orders grows + exponentially as the number of tables expands. Beyond ten or so input + tables it's no longer practical to do an exhaustive search of all the + possibilities, and even for six or seven tables planning might take an + annoyingly long time. When there are too many input tables, the + PostgreSQL planner will switch from exhaustive + search to a genetic probabilistic search + through a limited number of possibilities. (The switch-over threshold is + set by the geqo_threshold run-time + parameter.) + The genetic search takes less time, but it won't + necessarily find the best possible plan. +

When the query involves outer joins, the planner has less freedom + than it does for plain (inner) joins. For example, consider: +

SELECT * FROM a LEFT JOIN (b JOIN c ON (b.ref = c.id)) ON (a.id = b.id);

+ Although this query's restrictions are superficially similar to the + previous example, the semantics are different because a row must be + emitted for each row of A that has no matching row in the join of B and C. + Therefore the planner has no choice of join order here: it must join + B to C and then join A to that result. Accordingly, this query takes + less time to plan than the previous query. In other cases, the planner + might be able to determine that more than one join order is safe. + For example, given: +

SELECT * FROM a LEFT JOIN b ON (a.bid = b.id) LEFT JOIN c ON (a.cid = c.id);

+ it is valid to join A to either B or C first. Currently, only + FULL JOIN completely constrains the join order. Most + practical cases involving LEFT JOIN or RIGHT JOIN + can be rearranged to some extent. +

Explicit inner join syntax (INNER JOIN, CROSS + JOIN, or unadorned JOIN) is semantically the same as + listing the input relations in FROM, so it does not + constrain the join order. +

Even though most kinds of JOIN don't completely constrain + the join order, it is possible to instruct the + PostgreSQL query planner to treat all + JOIN clauses as constraining the join order anyway. + For example, these three queries are logically equivalent: +

SELECT * FROM a, b, c WHERE a.id = b.id AND b.ref = c.id;
+SELECT * FROM a CROSS JOIN b CROSS JOIN c WHERE a.id = b.id AND b.ref = c.id;
+SELECT * FROM a JOIN (b JOIN c ON (b.ref = c.id)) ON (a.id = b.id);

+ But if we tell the planner to honor the JOIN order, + the second and third take less time to plan than the first. This effect + is not worth worrying about for only three tables, but it can be a + lifesaver with many tables. +

To force the planner to follow the join order laid out by explicit + JOINs, + set the join_collapse_limit run-time parameter to 1. + (Other possible values are discussed below.) +

You do not need to constrain the join order completely in order to + cut search time, because it's OK to use JOIN operators + within items of a plain FROM list. For example, consider: +

SELECT * FROM a CROSS JOIN b, c, d, e WHERE ...;

+ With join_collapse_limit = 1, this + forces the planner to join A to B before joining them to other tables, + but doesn't constrain its choices otherwise. In this example, the + number of possible join orders is reduced by a factor of 5. +

Constraining the planner's search in this way is a useful technique + both for reducing planning time and for directing the planner to a + good query plan. If the planner chooses a bad join order by default, + you can force it to choose a better order via JOIN syntax + — assuming that you know of a better order, that is. Experimentation + is recommended. +

A closely related issue that affects planning time is collapsing of + subqueries into their parent query. For example, consider: +

SELECT *
+FROM x, y,
+    (SELECT * FROM a, b, c WHERE something) AS ss
+WHERE somethingelse;

+ This situation might arise from use of a view that contains a join; + the view's SELECT rule will be inserted in place of the view + reference, yielding a query much like the above. Normally, the planner + will try to collapse the subquery into the parent, yielding: +

SELECT * FROM x, y, a, b, c WHERE something AND somethingelse;

+ This usually results in a better plan than planning the subquery + separately. (For example, the outer WHERE conditions might be such that + joining X to A first eliminates many rows of A, thus avoiding the need to + form the full logical output of the subquery.) But at the same time, + we have increased the planning time; here, we have a five-way join + problem replacing two separate three-way join problems. Because of the + exponential growth of the number of possibilities, this makes a big + difference. The planner tries to avoid getting stuck in huge join search + problems by not collapsing a subquery if more than from_collapse_limit + FROM items would result in the parent + query. You can trade off planning time against quality of plan by + adjusting this run-time parameter up or down. +

from_collapse_limit and join_collapse_limit + are similarly named because they do almost the same thing: one controls + when the planner will "flatten out" subqueries, and the + other controls when it will flatten out explicit joins. Typically + you would either set join_collapse_limit equal to + from_collapse_limit (so that explicit joins and subqueries + act similarly) or set join_collapse_limit to 1 (if you want + to control join order with explicit joins). But you might set them + differently if you are trying to fine-tune the trade-off between planning + time and run time. +


PrevHomeNext
Statistics Used by the PlannerUpPopulating a Database
\ No newline at end of file diff --git a/doc/src/sgml/html/explicit-locking.html b/doc/src/sgml/html/explicit-locking.html new file mode 100644 index 000000000..33464886c --- /dev/null +++ b/doc/src/sgml/html/explicit-locking.html @@ -0,0 +1,1240 @@ + +Explicit Locking
PostgreSQL 9.2.2 Documentation
PrevUpChapter 13. Concurrency ControlNext

13.3. Explicit Locking

PostgreSQL provides various lock modes + to control concurrent access to data in tables. These modes can + be used for application-controlled locking in situations where + MVCC does not give the desired behavior. Also, + most PostgreSQL commands automatically + acquire locks of appropriate modes to ensure that referenced + tables are not dropped or modified in incompatible ways while the + command executes. (For example, TRUNCATE cannot safely be + executed concurrently with other operations on the same table, so it + obtains an exclusive lock on the table to enforce that.) +

To examine a list of the currently outstanding locks in a database + server, use the + pg_locks + system view. For more information on monitoring the status of the lock + manager subsystem, refer to Chapter 27. +

13.3.1. Table-level Locks

The list below shows the available lock modes and the contexts in + which they are used automatically by + PostgreSQL. You can also acquire any + of these locks explicitly with the command LOCK. + Remember that all of these lock modes are table-level locks, + even if the name contains the word + "row"; the names of the lock modes are historical. + To some extent the names reflect the typical usage of each lock + mode — but the semantics are all the same. The only real difference + between one lock mode and another is the set of lock modes with + which each conflicts (see Table 13-2). + Two transactions cannot hold locks of conflicting + modes on the same table at the same time. (However, a transaction + never conflicts with itself. For example, it might acquire + ACCESS EXCLUSIVE lock and later acquire + ACCESS SHARE lock on the same table.) Non-conflicting + lock modes can be held concurrently by many transactions. Notice in + particular that some lock modes are self-conflicting (for example, + an ACCESS EXCLUSIVE lock cannot be held by more than one + transaction at a time) while others are not self-conflicting (for example, + an ACCESS SHARE lock can be held by multiple transactions). +

Table-level Lock Modes

ACCESS SHARE

Conflicts with the ACCESS EXCLUSIVE lock + mode only. +

The SELECT command acquires a lock of this mode on + referenced tables. In general, any query that only reads a table + and does not modify it will acquire this lock mode. +

ROW SHARE

Conflicts with the EXCLUSIVE and + ACCESS EXCLUSIVE lock modes. +

The SELECT FOR UPDATE and + SELECT FOR SHARE commands acquire a + lock of this mode on the target table(s) (in addition to + ACCESS SHARE locks on any other tables + that are referenced but not selected + FOR UPDATE/FOR SHARE). +

ROW EXCLUSIVE

Conflicts with the SHARE, SHARE ROW + EXCLUSIVE, EXCLUSIVE, and + ACCESS EXCLUSIVE lock modes. +

The commands UPDATE, + DELETE, and INSERT + acquire this lock mode on the target table (in addition to + ACCESS SHARE locks on any other referenced + tables). In general, this lock mode will be acquired by any + command that modifies data in a table. +

SHARE UPDATE EXCLUSIVE

Conflicts with the SHARE UPDATE EXCLUSIVE, + SHARE, SHARE ROW + EXCLUSIVE, EXCLUSIVE, and + ACCESS EXCLUSIVE lock modes. + This mode protects a table against + concurrent schema changes and VACUUM runs. +

Acquired by VACUUM (without FULL), + ANALYZE, CREATE INDEX CONCURRENTLY, and + some forms of ALTER TABLE. +

SHARE

Conflicts with the ROW EXCLUSIVE, + SHARE UPDATE EXCLUSIVE, SHARE ROW + EXCLUSIVE, EXCLUSIVE, and + ACCESS EXCLUSIVE lock modes. + This mode protects a table against concurrent data changes. +

Acquired by CREATE INDEX + (without CONCURRENTLY). +

SHARE ROW EXCLUSIVE

Conflicts with the ROW EXCLUSIVE, + SHARE UPDATE EXCLUSIVE, + SHARE, SHARE ROW + EXCLUSIVE, EXCLUSIVE, and + ACCESS EXCLUSIVE lock modes. + This mode protects a table against concurrent data changes, and + is self-exclusive so that only one session can hold it at a time. +

This lock mode is not automatically acquired by any + PostgreSQL command. +

EXCLUSIVE

Conflicts with the ROW SHARE, ROW + EXCLUSIVE, SHARE UPDATE + EXCLUSIVE, SHARE, SHARE + ROW EXCLUSIVE, EXCLUSIVE, and + ACCESS EXCLUSIVE lock modes. + This mode allows only concurrent ACCESS SHARE locks, + i.e., only reads from the table can proceed in parallel with a + transaction holding this lock mode. +

This lock mode is not automatically acquired on tables by any + PostgreSQL command. +

ACCESS EXCLUSIVE

Conflicts with locks of all modes (ACCESS + SHARE, ROW SHARE, ROW + EXCLUSIVE, SHARE UPDATE + EXCLUSIVE, SHARE, SHARE + ROW EXCLUSIVE, EXCLUSIVE, and + ACCESS EXCLUSIVE). + This mode guarantees that the + holder is the only transaction accessing the table in any way. +

Acquired by the ALTER TABLE, DROP TABLE, + TRUNCATE, REINDEX, + CLUSTER, and VACUUM FULL + commands. + This is also the default lock mode for LOCK TABLE + statements that do not specify a mode explicitly. +

Tip: Only an ACCESS EXCLUSIVE lock blocks a + SELECT (without FOR UPDATE/SHARE) + statement. +

Once acquired, a lock is normally held till end of transaction. But if a + lock is acquired after establishing a savepoint, the lock is released + immediately if the savepoint is rolled back to. This is consistent with + the principle that ROLLBACK cancels all effects of the + commands since the savepoint. The same holds for locks acquired within a + PL/pgSQL exception block: an error escape from the block + releases locks acquired within it. +

Table 13-2. Conflicting Lock Modes

Requested Lock ModeCurrent Lock Mode
ACCESS SHAREROW SHAREROW EXCLUSIVESHARE UPDATE EXCLUSIVESHARESHARE ROW EXCLUSIVEEXCLUSIVEACCESS EXCLUSIVE
ACCESS SHARE       X
ROW SHARE      XX
ROW EXCLUSIVE    XXXX
SHARE UPDATE EXCLUSIVE   XXXXX
SHARE  XX XXX
SHARE ROW EXCLUSIVE  XXXXXX
EXCLUSIVE XXXXXXX
ACCESS EXCLUSIVEXXXXXXXX

13.3.2. Row-level Locks

In addition to table-level locks, there are row-level locks, which + can be exclusive or shared locks. An exclusive row-level lock on a + specific row is automatically acquired when the row is updated or + deleted. The lock is held until the transaction commits or rolls + back, just like table-level locks. Row-level locks do + not affect data querying; they block only writers to the same + row. +

To acquire an exclusive row-level lock on a row without actually + modifying the row, select the row with SELECT FOR + UPDATE. Note that once the row-level lock is acquired, + the transaction can update the row multiple times without + fear of conflicts. +

To acquire a shared row-level lock on a row, select the row with + SELECT FOR SHARE. A shared lock does not prevent + other transactions from acquiring the same shared lock. However, + no transaction is allowed to update, delete, or exclusively lock a + row on which any other transaction holds a shared lock. Any attempt + to do so will block until the shared lock(s) have been released. +

PostgreSQL doesn't remember any + information about modified rows in memory, so there is no limit on + the number of rows locked at one time. However, locking a row + might cause a disk write, e.g., SELECT FOR + UPDATE modifies selected rows to mark them locked, and so + will result in disk writes. +

In addition to table and row locks, page-level share/exclusive locks are + used to control read/write access to table pages in the shared buffer + pool. These locks are released immediately after a row is fetched or + updated. Application developers normally need not be concerned with + page-level locks, but they are mentioned here for completeness. +

13.3.3. Deadlocks

The use of explicit locking can increase the likelihood of + deadlocks, wherein two (or more) transactions each + hold locks that the other wants. For example, if transaction 1 + acquires an exclusive lock on table A and then tries to acquire + an exclusive lock on table B, while transaction 2 has already + exclusive-locked table B and now wants an exclusive lock on table + A, then neither one can proceed. + PostgreSQL automatically detects + deadlock situations and resolves them by aborting one of the + transactions involved, allowing the other(s) to complete. + (Exactly which transaction will be aborted is difficult to + predict and should not be relied upon.) +

Note that deadlocks can also occur as the result of row-level + locks (and thus, they can occur even if explicit locking is not + used). Consider the case in which two concurrent + transactions modify a table. The first transaction executes: + +

UPDATE accounts SET balance = balance + 100.00 WHERE acctnum = 11111;

+ + This acquires a row-level lock on the row with the specified + account number. Then, the second transaction executes: + +

UPDATE accounts SET balance = balance + 100.00 WHERE acctnum = 22222;
+UPDATE accounts SET balance = balance - 100.00 WHERE acctnum = 11111;

+ + The first UPDATE statement successfully + acquires a row-level lock on the specified row, so it succeeds in + updating that row. However, the second UPDATE + statement finds that the row it is attempting to update has + already been locked, so it waits for the transaction that + acquired the lock to complete. Transaction two is now waiting on + transaction one to complete before it continues execution. Now, + transaction one executes: + +

UPDATE accounts SET balance = balance - 100.00 WHERE acctnum = 22222;

+ + Transaction one attempts to acquire a row-level lock on the + specified row, but it cannot: transaction two already holds such + a lock. So it waits for transaction two to complete. Thus, + transaction one is blocked on transaction two, and transaction + two is blocked on transaction one: a deadlock + condition. PostgreSQL will detect this + situation and abort one of the transactions. +

The best defense against deadlocks is generally to avoid them by + being certain that all applications using a database acquire + locks on multiple objects in a consistent order. In the example + above, if both transactions + had updated the rows in the same order, no deadlock would have + occurred. One should also ensure that the first lock acquired on + an object in a transaction is the most restrictive mode that will be + needed for that object. If it is not feasible to verify this in + advance, then deadlocks can be handled on-the-fly by retrying + transactions that abort due to deadlocks. +

So long as no deadlock situation is detected, a transaction seeking + either a table-level or row-level lock will wait indefinitely for + conflicting locks to be released. This means it is a bad idea for + applications to hold transactions open for long periods of time + (e.g., while waiting for user input). +

13.3.4. Advisory Locks

PostgreSQL provides a means for + creating locks that have application-defined meanings. These are + called advisory locks, because the system does not + enforce their use — it is up to the application to use them + correctly. Advisory locks can be useful for locking strategies + that are an awkward fit for the MVCC model. + For example, a common use of advisory locks is to emulate pessimistic + locking strategies typical of so called "flat file" data + management systems. + While a flag stored in a table could be used for the same purpose, + advisory locks are faster, avoid table bloat, and are automatically + cleaned up by the server at the end of the session. +

There are two ways to acquire an advisory lock in + PostgreSQL: at session level or at + transaction level. + Once acquired at session level, an advisory lock is held until + explicitly released or the session ends. Unlike standard lock requests, + session-level advisory lock requests do not honor transaction semantics: + a lock acquired during a transaction that is later rolled back will still + be held following the rollback, and likewise an unlock is effective even + if the calling transaction fails later. A lock can be acquired multiple + times by its owning process; for each completed lock request there must + be a corresponding unlock request before the lock is actually released. + Transaction-level lock requests, on the other hand, behave more like + regular lock requests: they are automatically released at the end of the + transaction, and there is no explicit unlock operation. This behavior + is often more convenient than the session-level behavior for short-term + usage of an advisory lock. + Session-level and transaction-level lock requests for the same advisory + lock identifier will block each other in the expected way. + If a session already holds a given advisory lock, additional requests by + it will always succeed, even if other sessions are awaiting the lock; this + statement is true regardless of whether the existing lock hold and new + request are at session level or transaction level. +

Like all locks in + PostgreSQL, a complete list of advisory locks + currently held by any session can be found in the pg_locks system + view. +

Both advisory locks and regular locks are stored in a shared memory + pool whose size is defined by the configuration variables + max_locks_per_transaction and + max_connections. + Care must be taken not to exhaust this + memory or the server will be unable to grant any locks at all. + This imposes an upper limit on the number of advisory locks + grantable by the server, typically in the tens to hundreds of thousands + depending on how the server is configured. +

In certain cases using advisory locking methods, especially in queries + involving explicit ordering and LIMIT clauses, care must be + taken to control the locks acquired because of the order in which SQL + expressions are evaluated. For example: +

SELECT pg_advisory_lock(id) FROM foo WHERE id = 12345; -- ok
+SELECT pg_advisory_lock(id) FROM foo WHERE id > 12345 LIMIT 100; -- danger!
+SELECT pg_advisory_lock(q.id) FROM
+(
+  SELECT id FROM foo WHERE id > 12345 LIMIT 100
+) q; -- ok

+ In the above queries, the second form is dangerous because the + LIMIT is not guaranteed to be applied before the locking + function is executed. This might cause some locks to be acquired + that the application was not expecting, and hence would fail to release + (until it ends the session). + From the point of view of the application, such locks + would be dangling, although still viewable in + pg_locks. +

The functions provided to manipulate advisory locks are described in + Section 9.26.8. +


PrevHomeNext
Transaction IsolationUpData Consistency Checks at the Application Level
\ No newline at end of file diff --git a/doc/src/sgml/html/extend-extensions.html b/doc/src/sgml/html/extend-extensions.html new file mode 100644 index 000000000..568264089 --- /dev/null +++ b/doc/src/sgml/html/extend-extensions.html @@ -0,0 +1,1308 @@ + +Packaging Related Objects into an Extension

35.15. Packaging Related Objects into an Extension

A useful extension to PostgreSQL typically includes + multiple SQL objects; for example, a new data type will require new + functions, new operators, and probably new index operator classes. + It is helpful to collect all these objects into a single package + to simplify database management. PostgreSQL calls + such a package an extension. To define an extension, + you need at least a script file that contains the + SQL commands to create the extension's objects, and a + control file that specifies a few basic properties + of the extension itself. If the extension includes C code, there + will typically also be a shared library file into which the C code + has been built. Once you have these files, a simple + CREATE EXTENSION command loads the objects into + your database. +

The main advantage of using an extension, rather than just running the + SQL script to load a bunch of "loose" objects + into your database, is that PostgreSQL will then + understand that the objects of the extension go together. You can + drop all the objects with a single DROP EXTENSION + command (no need to maintain a separate "uninstall" script). + Even more useful, pg_dump knows that it should not + dump the individual member objects of the extension — it will + just include a CREATE EXTENSION command in dumps, instead. + This vastly simplifies migration to a new version of the extension + that might contain more or different objects than the old version. + Note however that you must have the extension's control, script, and + other files available when loading such a dump into a new database. +

PostgreSQL will not let you drop an individual object + contained in an extension, except by dropping the whole extension. + Also, while you can change the definition of an extension member object + (for example, via CREATE OR REPLACE FUNCTION for a + function), bear in mind that the modified definition will not be dumped + by pg_dump. Such a change is usually only sensible if + you concurrently make the same change in the extension's script file. + (But there are special provisions for tables containing configuration + data; see below.) +

The extension mechanism also has provisions for packaging modification + scripts that adjust the definitions of the SQL objects contained in an + extension. For example, if version 1.1 of an extension adds one function + and changes the body of another function compared to 1.0, the extension + author can provide an update script that makes just those + two changes. The ALTER EXTENSION UPDATE command can then + be used to apply these changes and track which version of the extension + is actually installed in a given database. +

The kinds of SQL objects that can be members of an extension are shown in + the description of ALTER EXTENSION. Notably, objects + that are database-cluster-wide, such as databases, roles, and tablespaces, + cannot be extension members since an extension is only known within one + database. (Although an extension script is not prohibited from creating + such objects, if it does so they will not be tracked as part of the + extension.) Also notice that while a table can be a member of an + extension, its subsidiary objects such as indexes are not directly + considered members of the extension. +

35.15.1. Extension Files

The CREATE EXTENSION command relies on a control + file for each extension, which must be named the same as the extension + with a suffix of .control, and must be placed in the + installation's SHAREDIR/extension directory. There + must also be at least one SQL script file, which follows the + naming pattern + extension--version.sql + (for example, foo--1.0.sql for version 1.0 of + extension foo). By default, the script file(s) are also + placed in the SHAREDIR/extension directory; but the + control file can specify a different directory for the script file(s). +

The file format for an extension control file is the same as for the + postgresql.conf file, namely a list of + parameter_name = value + assignments, one per line. Blank lines and comments introduced by + # are allowed. Be sure to quote any value that is not + a single word or number. +

A control file can set the following parameters: +

directory (string)

The directory containing the extension's SQL script + file(s). Unless an absolute path is given, the name is relative to + the installation's SHAREDIR directory. The + default behavior is equivalent to specifying + directory = 'extension'. +

default_version (string)

The default version of the extension (the one that will be installed + if no version is specified in CREATE EXTENSION). Although + this can be omitted, that will result in CREATE EXTENSION + failing if no VERSION option appears, so you generally + don't want to do that. +

comment (string)

A comment (any string) about the extension. Alternatively, + the comment can be set by means of the COMMENT + command in the script file. +

encoding (string)

The character set encoding used by the script file(s). This should + be specified if the script files contain any non-ASCII characters. + Otherwise the files will be assumed to be in the database encoding. +

module_pathname (string)

The value of this parameter will be substituted for each occurrence + of MODULE_PATHNAME in the script file(s). If it is not + set, no substitution is made. Typically, this is set to + $libdir/shared_library_name and + then MODULE_PATHNAME is used in CREATE + FUNCTION commands for C-language functions, so that the script + files do not need to hard-wire the name of the shared library. +

requires (string)

A list of names of extensions that this extension depends on, + for example requires = 'foo, bar'. Those + extensions must be installed before this one can be installed. +

superuser (boolean)

If this parameter is true (which is the default), + only superusers can create the extension or update it to a new + version. If it is set to false, just the privileges + required to execute the commands in the installation or update script + are required. +

relocatable (boolean)

An extension is relocatable if it is possible to move + its contained objects into a different schema after initial creation + of the extension. The default is false, i.e. the + extension is not relocatable. + See below for more information. +

schema (string)

This parameter can only be set for non-relocatable extensions. + It forces the extension to be loaded into exactly the named schema + and not any other. See below for more information. +

In addition to the primary control file + extension.control, + an extension can have secondary control files named in the style + extension--version.control. + If supplied, these must be located in the script file directory. + Secondary control files follow the same format as the primary control + file. Any parameters set in a secondary control file override the + primary control file when installing or updating to that version of + the extension. However, the parameters directory and + default_version cannot be set in a secondary control file. +

An extension's SQL script files can contain any SQL commands, + except for transaction control commands (BEGIN, + COMMIT, etc) and commands that cannot be executed inside a + transaction block (such as VACUUM). This is because the + script files are implicitly executed within a transaction block. +

An extension's SQL script files can also contain lines + beginning with \echo, which will be ignored (treated as + comments) by the extension mechanism. This provision is commonly used + to throw an error if the script file is fed to psql + rather than being loaded via CREATE EXTENSION (see example + script below). Without that, users might accidentally load the + extension's contents as "loose" objects rather than as an + extension, a state of affairs that's a bit tedious to recover from. +

While the script files can contain any characters allowed by the specified + encoding, control files should contain only plain ASCII, because there + is no way for PostgreSQL to know what encoding a + control file is in. In practice this is only an issue if you want to + use non-ASCII characters in the extension's comment. Recommended + practice in that case is to not use the control file comment + parameter, but instead use COMMENT ON EXTENSION + within a script file to set the comment. +

35.15.2. Extension Relocatability

Users often wish to load the objects contained in an extension into a + different schema than the extension's author had in mind. There are + three supported levels of relocatability: +

  • A fully relocatable extension can be moved into another schema + at any time, even after it's been loaded into a database. + This is done with the ALTER EXTENSION SET SCHEMA + command, which automatically renames all the member objects into + the new schema. Normally, this is only possible if the extension + contains no internal assumptions about what schema any of its + objects are in. Also, the extension's objects must all be in one + schema to begin with (ignoring objects that do not belong to any + schema, such as procedural languages). Mark a fully relocatable + extension by setting relocatable = true in its control + file. +

  • An extension might be relocatable during installation but not + afterwards. This is typically the case if the extension's script + file needs to reference the target schema explicitly, for example + in setting search_path properties for SQL functions. + For such an extension, set relocatable = false in its + control file, and use @extschema@ to refer to the target + schema in the script file. All occurrences of this string will be + replaced by the actual target schema's name before the script is + executed. The user can set the target schema using the + SCHEMA option of CREATE EXTENSION. +

  • If the extension does not support relocation at all, set + relocatable = false in its control file, and also set + schema to the name of the intended target schema. This + will prevent use of the SCHEMA option of CREATE + EXTENSION, unless it specifies the same schema named in the control + file. This choice is typically necessary if the extension contains + internal assumptions about schema names that can't be replaced by + uses of @extschema@. The @extschema@ + substitution mechanism is available in this case too, although it is + of limited use since the schema name is determined by the control file. +

In all cases, the script file will be executed with + search_path initially set to point to the target + schema; that is, CREATE EXTENSION does the equivalent of + this: +

SET LOCAL search_path TO @extschema@;

+ This allows the objects created by the script file to go into the target + schema. The script file can change search_path if it wishes, + but that is generally undesirable. search_path is restored + to its previous setting upon completion of CREATE EXTENSION. +

The target schema is determined by the schema parameter in + the control file if that is given, otherwise by the SCHEMA + option of CREATE EXTENSION if that is given, otherwise the + current default object creation schema (the first one in the caller's + search_path). When the control file schema + parameter is used, the target schema will be created if it doesn't + already exist, but in the other two cases it must already exist. +

If any prerequisite extensions are listed in requires + in the control file, their target schemas are appended to the initial + setting of search_path. This allows their objects to be + visible to the new extension's script file. +

Although a non-relocatable extension can contain objects spread across + multiple schemas, it is usually desirable to place all the objects meant + for external use into a single schema, which is considered the extension's + target schema. Such an arrangement works conveniently with the default + setting of search_path during creation of dependent + extensions. +

35.15.3. Extension Configuration Tables

Some extensions include configuration tables, which contain data that + might be added or changed by the user after installation of the + extension. Ordinarily, if a table is part of an extension, neither + the table's definition nor its content will be dumped by + pg_dump. But that behavior is undesirable for a + configuration table; any data changes made by the user need to be + included in dumps, or the extension will behave differently after a dump + and reload. +

To solve this problem, an extension's script file can mark a table + it has created as a configuration table, which will cause + pg_dump to include the table's contents (not its + definition) in dumps. To do that, call the function + pg_extension_config_dump(regclass, text) after creating the + table, for example +

CREATE TABLE my_config (key text, value text);
+
+SELECT pg_catalog.pg_extension_config_dump('my_config', '');

+ Any number of tables can be marked this way. +

When the second argument of pg_extension_config_dump is + an empty string, the entire contents of the table are dumped by + pg_dump. This is usually only correct if the table + is initially empty as created by the extension script. If there is + a mixture of initial data and user-provided data in the table, + the second argument of pg_extension_config_dump provides + a WHERE condition that selects the data to be dumped. + For example, you might do +

CREATE TABLE my_config (key text, value text, standard_entry boolean);
+
+SELECT pg_catalog.pg_extension_config_dump('my_config', 'WHERE NOT standard_entry');

+ and then make sure that standard_entry is true only + in the rows created by the extension's script. +

More complicated situations, such as initially-provided rows that might + be modified by users, can be handled by creating triggers on the + configuration table to ensure that modified rows are marked correctly. +

35.15.4. Extension Updates

One advantage of the extension mechanism is that it provides convenient + ways to manage updates to the SQL commands that define an extension's + objects. This is done by associating a version name or number with + each released version of the extension's installation script. + In addition, if you want users to be able to update their databases + dynamically from one version to the next, you should provide + update scripts that make the necessary changes to go from + one version to the next. Update scripts have names following the pattern + extension--oldversion--newversion.sql + (for example, foo--1.0--1.1.sql contains the commands to modify + version 1.0 of extension foo into version + 1.1). +

Given that a suitable update script is available, the command + ALTER EXTENSION UPDATE will update an installed extension + to the specified new version. The update script is run in the same + environment that CREATE EXTENSION provides for installation + scripts: in particular, search_path is set up in the same + way, and any new objects created by the script are automatically added + to the extension. +

If an extension has secondary control files, the control parameters + that are used for an update script are those associated with the script's + target (new) version. +

The update mechanism can be used to solve an important special case: + converting a "loose" collection of objects into an extension. + Before the extension mechanism was added to + PostgreSQL (in 9.1), many people wrote + extension modules that simply created assorted unpackaged objects. + Given an existing database containing such objects, how can we convert + the objects into a properly packaged extension? Dropping them and then + doing a plain CREATE EXTENSION is one way, but it's not + desirable if the objects have dependencies (for example, if there are + table columns of a data type created by the extension). The way to fix + this situation is to create an empty extension, then use ALTER + EXTENSION ADD to attach each pre-existing object to the extension, + then finally create any new objects that are in the current extension + version but were not in the unpackaged release. CREATE + EXTENSION supports this case with its FROM old_version option, which causes it to not run the + normal installation script for the target version, but instead the update + script named + extension--old_version--target_version.sql. + The choice of the dummy version name to use as old_version is up to the extension author, though + unpackaged is a common convention. If you have multiple + prior versions you need to be able to update into extension style, use + multiple dummy version names to identify them. +

ALTER EXTENSION is able to execute sequences of update + script files to achieve a requested update. For example, if only + foo--1.0--1.1.sql and foo--1.1--2.0.sql are + available, ALTER EXTENSION will apply them in sequence if an + update to version 2.0 is requested when 1.0 is + currently installed. +

PostgreSQL doesn't assume anything about the properties + of version names: for example, it does not know whether 1.1 + follows 1.0. It just matches up the available version names + and follows the path that requires applying the fewest update scripts. + (A version name can actually be any string that doesn't contain + -- or leading or trailing -.) +

Sometimes it is useful to provide "downgrade" scripts, for + example foo--1.1--1.0.sql to allow reverting the changes + associated with version 1.1. If you do that, be careful + of the possibility that a downgrade script might unexpectedly + get applied because it yields a shorter path. The risky case is where + there is a "fast path" update script that jumps ahead several + versions as well as a downgrade script to the fast path's start point. + It might take fewer steps to apply the downgrade and then the fast + path than to move ahead one version at a time. If the downgrade script + drops any irreplaceable objects, this will yield undesirable results. +

To check for unexpected update paths, use this command: +

SELECT * FROM pg_extension_update_paths('extension_name');

+ This shows each pair of distinct known version names for the specified + extension, together with the update path sequence that would be taken to + get from the source version to the target version, or NULL if + there is no available update path. The path is shown in textual form + with -- separators. You can use + regexp_split_to_array(path,'--') if you prefer an array + format. +

35.15.5. Extension Example

Here is a complete example of an SQL-only + extension, a two-element composite type that can store any type of value + in its slots, which are named "k" and "v". Non-text + values are automatically coerced to text for storage. +

The script file pair--1.0.sql looks like this: + +

-- complain if script is sourced in psql, rather than via CREATE EXTENSION
+\echo Use "CREATE EXTENSION pair" to load this file. \quit
+
+CREATE TYPE pair AS ( k text, v text );
+
+CREATE OR REPLACE FUNCTION pair(anyelement, text)
+RETURNS pair LANGUAGE SQL AS 'SELECT ROW($1, $2)::pair';
+
+CREATE OR REPLACE FUNCTION pair(text, anyelement)
+RETURNS pair LANGUAGE SQL AS 'SELECT ROW($1, $2)::pair';
+
+CREATE OR REPLACE FUNCTION pair(anyelement, anyelement)
+RETURNS pair LANGUAGE SQL AS 'SELECT ROW($1, $2)::pair';
+
+CREATE OR REPLACE FUNCTION pair(text, text)
+RETURNS pair LANGUAGE SQL AS 'SELECT ROW($1, $2)::pair;';
+
+CREATE OPERATOR ~> (LEFTARG = text, RIGHTARG = anyelement, PROCEDURE = pair);
+CREATE OPERATOR ~> (LEFTARG = anyelement, RIGHTARG = text, PROCEDURE = pair);
+CREATE OPERATOR ~> (LEFTARG = anyelement, RIGHTARG = anyelement, PROCEDURE = pair);
+CREATE OPERATOR ~> (LEFTARG = text, RIGHTARG = text, PROCEDURE = pair);

+

The control file pair.control looks like this: + +

# pair extension
+comment = 'A key/value pair data type'
+default_version = '1.0'
+relocatable = true

+

While you hardly need a makefile to install these two files into the + correct directory, you could use a Makefile containing this: + +

EXTENSION = pair
+DATA = pair--1.0.sql
+
+PG_CONFIG = pg_config
+PGXS := $(shell $(PG_CONFIG) --pgxs)
+include $(PGXS)

+ + This makefile relies on PGXS, which is described + in Section 35.16. The command make install + will install the control and script files into the correct + directory as reported by pg_config. +

Once the files are installed, use the + CREATE EXTENSION command to load the objects into + any particular database. +


PrevHomeNext
Interfacing Extensions To IndexesUpExtension Building Infrastructure
\ No newline at end of file diff --git a/doc/src/sgml/html/extend-how.html b/doc/src/sgml/html/extend-how.html new file mode 100644 index 000000000..2e8247dbb --- /dev/null +++ b/doc/src/sgml/html/extend-how.html @@ -0,0 +1,241 @@ + +How Extensibility Works

35.1. How Extensibility Works

PostgreSQL is extensible because its operation is + catalog-driven. If you are familiar with standard + relational database systems, you know that they store information + about databases, tables, columns, etc., in what are + commonly known as system catalogs. (Some systems call + this the data dictionary.) The catalogs appear to the + user as tables like any other, but the DBMS stores + its internal bookkeeping in them. One key difference + between PostgreSQL and standard relational database systems is + that PostgreSQL stores much more information in its + catalogs: not only information about tables and columns, + but also information about data types, functions, access + methods, and so on. These tables can be modified by + the user, and since PostgreSQL bases its operation + on these tables, this means that PostgreSQL can be + extended by users. By comparison, conventional + database systems can only be extended by changing hardcoded + procedures in the source code or by loading modules + specially written by the DBMS vendor. +

The PostgreSQL server can moreover + incorporate user-written code into itself through dynamic loading. + That is, the user can specify an object code file (e.g., a shared + library) that implements a new type or function, and + PostgreSQL will load it as required. + Code written in SQL is even more trivial to add + to the server. This ability to modify its operation "on the + fly" makes PostgreSQL uniquely + suited for rapid prototyping of new applications and storage + structures. +


PrevHomeNext
Extending SQLUpThe PostgreSQL Type System
\ No newline at end of file diff --git a/doc/src/sgml/html/extend-pgxs.html b/doc/src/sgml/html/extend-pgxs.html new file mode 100644 index 000000000..bf1aed23c --- /dev/null +++ b/doc/src/sgml/html/extend-pgxs.html @@ -0,0 +1,739 @@ + +Extension Building Infrastructure

35.16. Extension Building Infrastructure

If you are thinking about distributing your + PostgreSQL extension modules, setting up a + portable build system for them can be fairly difficult. Therefore + the PostgreSQL installation provides a build + infrastructure for extensions, called PGXS, so + that simple extension modules can be built simply against an + already installed server. PGXS is mainly intended + for extensions that include C code, although it can be used for + pure-SQL extensions too. Note that PGXS is not + intended to be a universal build system framework that can be used + to build any software interfacing to PostgreSQL; + it simply automates common build rules for simple server extension + modules. For more complicated packages, you might need to write your + own build system. +

To use the PGXS infrastructure for your extension, + you must write a simple makefile. + In the makefile, you need to set some variables + and finally include the global PGXS makefile. + Here is an example that builds an extension module named + isbn_issn, consisting of a shared library containing + some C code, an extension control file, a SQL script, and a documentation + text file: +

MODULES = isbn_issn
+EXTENSION = isbn_issn
+DATA = isbn_issn--1.0.sql
+DOCS = README.isbn_issn
+
+PG_CONFIG = pg_config
+PGXS := $(shell $(PG_CONFIG) --pgxs)
+include $(PGXS)

+ The last three lines should always be the same. Earlier in the + file, you assign variables or add custom + make rules. +

Set one of these three variables to specify what is built: + +

MODULES

list of shared-library objects to be built from source files with same + stem (do not include library suffixes in this list) +

MODULE_big

a shared library to build from multiple source files + (list object files in OBJS) +

PROGRAM

an executable program to build + (list object files in OBJS) +

+ + The following variables can also be set: + +

EXTENSION

extension name(s); for each name you must provide an + extension.control file, + which will be installed into + prefix/share/extension +

MODULEDIR

subdirectory of prefix/share + into which DATA and DOCS files should be installed + (if not set, default is extension if + EXTENSION is set, + or contrib if not) +

DATA

random files to install into prefix/share/$MODULEDIR +

DATA_built

random files to install into + prefix/share/$MODULEDIR, + which need to be built first +

DATA_TSEARCH

random files to install under + prefix/share/tsearch_data +

DOCS

random files to install under + prefix/doc/$MODULEDIR +

SCRIPTS

script files (not binaries) to install into + prefix/bin +

SCRIPTS_built

script files (not binaries) to install into + prefix/bin, + which need to be built first +

REGRESS

list of regression test cases (without suffix), see below +

REGRESS_OPTS

additional switches to pass to pg_regress +

EXTRA_CLEAN

extra files to remove in make clean +

PG_CPPFLAGS

will be added to CPPFLAGS +

PG_LIBS

will be added to PROGRAM link line +

SHLIB_LINK

will be added to MODULE_big link line +

PG_CONFIG

path to pg_config program for the + PostgreSQL installation to build against + (typically just pg_config to use the first one in your + PATH) +

+

Put this makefile as Makefile in the directory + which holds your extension. Then you can do + make to compile, and then make + install to install your module. By default, the extension is + compiled and installed for the + PostgreSQL installation that + corresponds to the first pg_config program + found in your PATH. You can use a different installation by + setting PG_CONFIG to point to its + pg_config program, either within the makefile + or on the make command line. +

Caution

Changing PG_CONFIG only works when building + against PostgreSQL 8.3 or later. + With older releases it does not work to set it to anything except + pg_config; you must alter your PATH + to select the installation to build against. +

The scripts listed in the REGRESS variable are used for + regression testing of your module, which can be invoked by make + installcheck after doing make install. For this to + work you must have a running PostgreSQL server. + The script files listed in REGRESS must appear in a + subdirectory named sql/ in your extension's directory. + These files must have extension .sql, which must not be + included in the REGRESS list in the makefile. For each + test there should also be a file containing the expected output in a + subdirectory named expected/, with the same stem and + extension .out. make installcheck + executes each test script with psql, and compares the + resulting output to the matching expected file. Any differences will be + written to the file regression.diffs in diff + -c format. Note that trying to run a test that is missing its + expected file will be reported as "trouble", so make sure you + have all expected files. +

Tip: The easiest way to create the expected files is to create empty files, + then do a test run (which will of course report differences). Inspect + the actual result files found in the results/ + directory, then copy them to expected/ if they match + what you expect from the test. +


PrevHomeNext
Packaging Related Objects into an ExtensionUpTriggers
\ No newline at end of file diff --git a/doc/src/sgml/html/extend-type-system.html b/doc/src/sgml/html/extend-type-system.html new file mode 100644 index 000000000..80f5c2579 --- /dev/null +++ b/doc/src/sgml/html/extend-type-system.html @@ -0,0 +1,478 @@ + +The PostgreSQL Type System

35.2. The PostgreSQL Type System

PostgreSQL data types are divided into base + types, composite types, domains, and pseudo-types. +

35.2.1. Base Types

Base types are those, like int4, that are + implemented below the level of the SQL language + (typically in a low-level language such as C). They generally + correspond to what are often known as abstract data types. + PostgreSQL can only operate on such + types through functions provided by the user and only understands + the behavior of such types to the extent that the user describes + them. Base types are further subdivided into scalar and array + types. For each scalar type, a corresponding array type is + automatically created that can hold variable-size arrays of that + scalar type. +

35.2.2. Composite Types

Composite types, or row types, are created whenever the user + creates a table. It is also possible to use CREATE TYPE to + define a "stand-alone" composite type with no associated + table. A composite type is simply a list of types with + associated field names. A value of a composite type is a row or + record of field values. The user can access the component fields + from SQL queries. Refer to Section 8.16 + for more information on composite types. +

35.2.3. Domains

A domain is based on a particular base type and for many purposes + is interchangeable with its base type. However, a domain can + have constraints that restrict its valid values to a subset of + what the underlying base type would allow. +

Domains can be created using the SQL command + CREATE DOMAIN. + Their creation and use is not discussed in this chapter. +

35.2.4. Pseudo-Types

There are a few "pseudo-types" for special purposes. + Pseudo-types cannot appear as columns of tables or attributes of + composite types, but they can be used to declare the argument and + result types of functions. This provides a mechanism within the + type system to identify special classes of functions. Table 8-24 lists the existing + pseudo-types. +

35.2.5. Polymorphic Types

Five pseudo-types of special interest are anyelement, + anyarray, anynonarray, anyenum, + and anyrange, + which are collectively called polymorphic types. + Any function declared using these types is said to be + a polymorphic function. A polymorphic function can + operate on many different data types, with the specific data type(s) + being determined by the data types actually passed to it in a particular + call. +

Polymorphic arguments and results are tied to each other and are resolved + to a specific data type when a query calling a polymorphic function is + parsed. Each position (either argument or return value) declared as + anyelement is allowed to have any specific actual + data type, but in any given call they must all be the + same actual type. Each + position declared as anyarray can have any array data type, + but similarly they must all be the same type. And similarly, + positions declared as anyrange must all be the same range + type. Furthermore, if there are + positions declared anyarray and others declared + anyelement, the actual array type in the + anyarray positions must be an array whose elements are + the same type appearing in the anyelement positions. + Similarly, if there are positions declared anyrange + and others declared anyelement, the actual range type in + the anyrange positions must be a range whose subtype is + the same type appearing in the anyelement positions. + anynonarray is treated exactly the same as anyelement, + but adds the additional constraint that the actual type must not be + an array type. + anyenum is treated exactly the same as anyelement, + but adds the additional constraint that the actual type must + be an enum type. +

Thus, when more than one argument position is declared with a polymorphic + type, the net effect is that only certain combinations of actual argument + types are allowed. For example, a function declared as + equal(anyelement, anyelement) will take any two input values, + so long as they are of the same data type. +

When the return value of a function is declared as a polymorphic type, + there must be at least one argument position that is also polymorphic, + and the actual data type supplied as the argument determines the actual + result type for that call. For example, if there were not already + an array subscripting mechanism, one could define a function that + implements subscripting as subscript(anyarray, integer) + returns anyelement. This declaration constrains the actual first + argument to be an array type, and allows the parser to infer the correct + result type from the actual first argument's type. Another example + is that a function declared as f(anyarray) returns anyenum + will only accept arrays of enum types. +

Note that anynonarray and anyenum do not represent + separate type variables; they are the same type as + anyelement, just with an additional constraint. For + example, declaring a function as f(anyelement, anyenum) + is equivalent to declaring it as f(anyenum, anyenum): + both actual arguments have to be the same enum type. +

A variadic function (one taking a variable number of arguments, as in + Section 35.4.5) can be + polymorphic: this is accomplished by declaring its last parameter as + VARIADIC anyarray. For purposes of argument + matching and determining the actual result type, such a function behaves + the same as if you had written the appropriate number of + anynonarray parameters. +


PrevHomeNext
How Extensibility WorksUpUser-defined Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/extend.html b/doc/src/sgml/html/extend.html new file mode 100644 index 000000000..369325c4f --- /dev/null +++ b/doc/src/sgml/html/extend.html @@ -0,0 +1,650 @@ + +Extending SQL

Chapter 35. Extending SQL

Table of Contents
35.1. How Extensibility Works
35.2. The PostgreSQL Type System
35.2.1. Base Types
35.2.2. Composite Types
35.2.3. Domains
35.2.4. Pseudo-Types
35.2.5. Polymorphic Types
35.3. User-defined Functions
35.4. Query Language (SQL) Functions
35.4.1. Arguments for SQL Functions
35.4.2. SQL Functions on Base Types
35.4.3. SQL Functions on Composite Types
35.4.4. SQL Functions with Output Parameters
35.4.5. SQL Functions with Variable Numbers of Arguments
35.4.6. SQL Functions with Default Values for Arguments
35.4.7. SQL Functions as Table Sources
35.4.8. SQL Functions Returning Sets
35.4.9. SQL Functions Returning TABLE
35.4.10. Polymorphic SQL Functions
35.4.11. SQL Functions with Collations
35.5. Function Overloading
35.6. Function Volatility Categories
35.7. Procedural Language Functions
35.8. Internal Functions
35.9. C-Language Functions
35.9.1. Dynamic Loading
35.9.2. Base Types in C-Language Functions
35.9.3. Version 0 Calling Conventions
35.9.4. Version 1 Calling Conventions
35.9.5. Writing Code
35.9.6. Compiling and Linking Dynamically-loaded Functions
35.9.7. Composite-type Arguments
35.9.8. Returning Rows (Composite Types)
35.9.9. Returning Sets
35.9.10. Polymorphic Arguments and Return Types
35.9.11. Transform Functions
35.9.12. Shared Memory and LWLocks
35.9.13. Using C++ for Extensibility
35.10. User-defined Aggregates
35.11. User-defined Types
35.12. User-defined Operators
35.13. Operator Optimization Information
35.13.1. COMMUTATOR
35.13.2. NEGATOR
35.13.3. RESTRICT
35.13.4. JOIN
35.13.5. HASHES
35.13.6. MERGES
35.14. Interfacing Extensions To Indexes
35.14.1. Index Methods and Operator Classes
35.14.2. Index Method Strategies
35.14.3. Index Method Support Routines
35.14.4. An Example
35.14.5. Operator Classes and Operator Families
35.14.6. System Dependencies on Operator Classes
35.14.7. Ordering Operators
35.14.8. Special Features of Operator Classes
35.15. Packaging Related Objects into an Extension
35.15.1. Extension Files
35.15.2. Extension Relocatability
35.15.3. Extension Configuration Tables
35.15.4. Extension Updates
35.15.5. Extension Example
35.16. Extension Building Infrastructure

In the sections that follow, we will discuss how you + can extend the PostgreSQL + SQL query language by adding: + +

+


PrevHomeNext
Server ProgrammingUpHow Extensibility Works
\ No newline at end of file diff --git a/doc/src/sgml/html/external-admin-tools.html b/doc/src/sgml/html/external-admin-tools.html new file mode 100644 index 000000000..07a74c39b --- /dev/null +++ b/doc/src/sgml/html/external-admin-tools.html @@ -0,0 +1,179 @@ + +Administration Tools
PostgreSQL 9.2.2 Documentation
PrevUpAppendix H. External ProjectsNext

H.2. Administration Tools

There are several administration tools available for + PostgreSQL. The most popular is + pgAdmin III, + and there are several commercially available ones as well. +


PrevHomeNext
Client InterfacesUpProcedural Languages
\ No newline at end of file diff --git a/doc/src/sgml/html/external-extensions.html b/doc/src/sgml/html/external-extensions.html new file mode 100644 index 000000000..27001c937 --- /dev/null +++ b/doc/src/sgml/html/external-extensions.html @@ -0,0 +1,202 @@ + +Extensions
PostgreSQL 9.2.2 Documentation
PrevUpAppendix H. External ProjectsNext

H.4. Extensions

PostgreSQL is designed to be easily extensible. For + this reason, extensions loaded into the database can function + just like features that are built in. The + contrib/ directory shipped with the source code + contains several extensions, which are described in + Appendix F. Other extensions are developed + independently, like PostGIS. Even + PostgreSQL replication solutions can be developed + externally. For example, Slony-I is a popular + master/standby replication solution that is developed independently + from the core project. +


PrevHomeNext
Procedural LanguagesUpThe Source Code Repository
\ No newline at end of file diff --git a/doc/src/sgml/html/external-interfaces.html b/doc/src/sgml/html/external-interfaces.html new file mode 100644 index 000000000..06d745844 --- /dev/null +++ b/doc/src/sgml/html/external-interfaces.html @@ -0,0 +1,337 @@ + +Client Interfaces
PostgreSQL 9.2.2 Documentation
PrevUpAppendix H. External ProjectsNext

H.1. Client Interfaces

There are only two client interfaces included in the base + PostgreSQL distribution: +

  • libpq is included because it is the + primary C language interface, and because many other client interfaces + are built on top of it. +

  • ECPG is included because it depends on the + server-side SQL grammar, and is therefore sensitive to changes in + PostgreSQL itself. +

+ + All other language interfaces are external projects and are distributed + separately. Table H-1 includes a list of + some of these projects. Note that some of these packages might not be + released under the same license as PostgreSQL. For more + information on each language interface, including licensing terms, refer to + its website and documentation. +

Table H-1. Externally Maintained Client Interfaces

NameLanguageCommentsWebsite
DBD::PgPerlPerl DBI driverhttp://search.cpan.org/dist/DBD-Pg/
JDBCJDBCType 4 JDBC driverhttp://jdbc.postgresql.org/
libpqxxC++New-style C++ interfacehttp://pqxx.org/
Npgsql.NET.NET data providerhttp://npgsql.projects.postgresql.org/
pgtclngTcl http://sourceforge.net/projects/pgtclng/
psqlODBCODBCODBC driverhttp://psqlodbc.projects.postgresql.org/
psycopgPythonDB API 2.0-complianthttp://www.initd.org/

PrevHomeNext
External ProjectsUpAdministration Tools
\ No newline at end of file diff --git a/doc/src/sgml/html/external-pl.html b/doc/src/sgml/html/external-pl.html new file mode 100644 index 000000000..1dcd3cc08 --- /dev/null +++ b/doc/src/sgml/html/external-pl.html @@ -0,0 +1,311 @@ + +Procedural Languages
PostgreSQL 9.2.2 Documentation
PrevUpAppendix H. External ProjectsNext

H.3. Procedural Languages

PostgreSQL includes several procedural + languages with the base distribution: PL/pgSQL, PL/Tcl, + PL/Perl, and PL/Python. +

In addition, there are a number of procedural languages that are developed + and maintained outside the core PostgreSQL + distribution. Table H-2 lists some of these + packages. Note that some of these projects might not be released under the same + license as PostgreSQL. For more information on each + procedural language, including licensing information, refer to its website + and documentation. +


PrevHomeNext
Administration ToolsUpExtensions
\ No newline at end of file diff --git a/doc/src/sgml/html/external-projects.html b/doc/src/sgml/html/external-projects.html new file mode 100644 index 000000000..e3df349a8 --- /dev/null +++ b/doc/src/sgml/html/external-projects.html @@ -0,0 +1,206 @@ + +External Projects

Appendix H. External Projects

PostgreSQL is a complex software project, + and managing the project is difficult. We have found that many + enhancements to PostgreSQL can be more + efficiently developed separately from the core project. +


PrevHomeNext
pg_upgradeUpClient Interfaces
\ No newline at end of file diff --git a/doc/src/sgml/html/fdw-callbacks.html b/doc/src/sgml/html/fdw-callbacks.html new file mode 100644 index 000000000..671502d6b --- /dev/null +++ b/doc/src/sgml/html/fdw-callbacks.html @@ -0,0 +1,579 @@ + +Foreign Data Wrapper Callback Routines
PostgreSQL 9.2.2 Documentation
PrevUpChapter 50. Writing A Foreign Data WrapperNext

50.2. Foreign Data Wrapper Callback Routines

The FDW handler function returns a palloc'd FdwRoutine + struct containing pointers to the following callback functions: +

void
+GetForeignRelSize (PlannerInfo *root,
+                   RelOptInfo *baserel,
+                   Oid foreigntableid);

+ + Obtain relation size estimates for a foreign table. This is called + at the beginning of planning for a query involving a foreign table. + root is the planner's global information about the query; + baserel is the planner's information about this table; and + foreigntableid is the pg_class OID of the + foreign table. (foreigntableid could be obtained from the + planner data structures, but it's passed explicitly to save effort.) +

This function should update baserel->rows to be the + expected number of rows returned by the table scan, after accounting for + the filtering done by the restriction quals. The initial value of + baserel->rows is just a constant default estimate, which + should be replaced if at all possible. The function may also choose to + update baserel->width if it can compute a better estimate + of the average result row width. +

See Section 50.4 for additional information. +

void
+GetForeignPaths (PlannerInfo *root,
+                 RelOptInfo *baserel,
+                 Oid foreigntableid);

+ + Create possible access paths for a scan on a foreign table. + This is called during query planning. + The parameters are the same as for GetForeignRelSize, + which has already been called. +

This function must generate at least one access path + (ForeignPath node) for a scan on the foreign table and + must call add_path to add each such path to + baserel->pathlist. It's recommended to use + create_foreignscan_path to build the + ForeignPath nodes. The function can generate multiple + access paths, e.g., a path which has valid pathkeys to + represent a pre-sorted result. Each access path must contain cost + estimates, and can contain any FDW-private information that is needed to + identify the specific scan method intended. +

See Section 50.4 for additional information. +

ForeignScan *
+GetForeignPlan (PlannerInfo *root,
+                RelOptInfo *baserel,
+                Oid foreigntableid,
+                ForeignPath *best_path,
+                List *tlist,
+                List *scan_clauses);

+ + Create a ForeignScan plan node from the selected foreign + access path. This is called at the end of query planning. + The parameters are as for GetForeignRelSize, plus + the selected ForeignPath (previously produced by + GetForeignPaths), the target list to be emitted by the + plan node, and the restriction clauses to be enforced by the plan node. +

This function must create and return a ForeignScan plan + node; it's recommended to use make_foreignscan to build the + ForeignScan node. +

See Section 50.4 for additional information. +

void
+ExplainForeignScan (ForeignScanState *node,
+                    ExplainState *es);

+ + Print additional EXPLAIN output for a foreign table scan. + This can just return if there is no need to print anything. + Otherwise, it should call ExplainPropertyText and + related functions to add fields to the EXPLAIN output. + The flag fields in es can be used to determine what to + print, and the state of the ForeignScanState node + can be inspected to provide run-time statistics in the EXPLAIN + ANALYZE case. +

void
+BeginForeignScan (ForeignScanState *node,
+                  int eflags);

+ + Begin executing a foreign scan. This is called during executor startup. + It should perform any initialization needed before the scan can start, + but not start executing the actual scan (that should be done upon the + first call to IterateForeignScan). + The ForeignScanState node has already been created, but + its fdw_state field is still NULL. Information about + the table to scan is accessible through the + ForeignScanState node (in particular, from the underlying + ForeignScan plan node, which contains any FDW-private + information provided by GetForeignPlan). +

Note that when (eflags & EXEC_FLAG_EXPLAIN_ONLY) is + true, this function should not perform any externally-visible actions; + it should only do the minimum required to make the node state valid + for ExplainForeignScan and EndForeignScan. +

TupleTableSlot *
+IterateForeignScan (ForeignScanState *node);

+ + Fetch one row from the foreign source, returning it in a tuple table slot + (the node's ScanTupleSlot should be used for this + purpose). Return NULL if no more rows are available. The tuple table + slot infrastructure allows either a physical or virtual tuple to be + returned; in most cases the latter choice is preferable from a + performance standpoint. Note that this is called in a short-lived memory + context that will be reset between invocations. Create a memory context + in BeginForeignScan if you need longer-lived storage, or use + the es_query_cxt of the node's EState. +

The rows returned must match the column signature of the foreign table + being scanned. If you choose to optimize away fetching columns that + are not needed, you should insert nulls in those column positions. +

Note that PostgreSQL's executor doesn't care + whether the rows returned violate the NOT NULL + constraints which were defined on the foreign table columns - but the + planner does care, and may optimize queries incorrectly if + NULL values are present in a column declared not to contain + them. If a NULL value is encountered when the user has + declared that none should be present, it may be appropriate to raise an + error (just as you would need to do in the case of a data type mismatch). +

void
+ReScanForeignScan (ForeignScanState *node);

+ + Restart the scan from the beginning. Note that any parameters the + scan depends on may have changed value, so the new scan does not + necessarily return exactly the same rows. +

void
+EndForeignScan (ForeignScanState *node);

+ + End the scan and release resources. It is normally not important + to release palloc'd memory, but for example open files and connections + to remote servers should be cleaned up. +

bool
+AnalyzeForeignTable (Relation relation,
+                     AcquireSampleRowsFunc *func,
+                     BlockNumber *totalpages);

+ + This function is called when ANALYZE is executed on + a foreign table. If the FDW can collect statistics for this + foreign table, it should return true, and provide a pointer + to a function that will collect sample rows from the table in + func, plus the estimated size of the table in pages in + totalpages. Otherwise, return false. + If the FDW does not support collecting statistics for any tables, the + AnalyzeForeignTable pointer can be set to NULL. +

If provided, the sample collection function must have the signature +

int
+AcquireSampleRowsFunc (Relation relation, int elevel,
+                       HeapTuple *rows, int targrows,
+                       double *totalrows,
+                       double *totaldeadrows);

+ + A random sample of up to targrows rows should be collected + from the table and stored into the caller-provided rows + array. The actual number of rows collected must be returned. In + addition, store estimates of the total numbers of live and dead rows in + the table into the output parameters totalrows and + totaldeadrows. (Set totaldeadrows to zero + if the FDW does not have any concept of dead rows.) +

The FdwRoutine struct type is declared in + src/include/foreign/fdwapi.h, which see for additional + details. +


PrevHomeNext
Foreign Data Wrapper FunctionsUpForeign Data Wrapper Helper Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/fdw-functions.html b/doc/src/sgml/html/fdw-functions.html new file mode 100644 index 000000000..1e206953e --- /dev/null +++ b/doc/src/sgml/html/fdw-functions.html @@ -0,0 +1,230 @@ + +Foreign Data Wrapper Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 50. Writing A Foreign Data WrapperNext

50.1. Foreign Data Wrapper Functions

The FDW author needs to implement a handler function, and optionally + a validator function. Both functions must be written in a compiled + language such as C, using the version-1 interface. + For details on C language calling conventions and dynamic loading, + see Section 35.9. +

The handler function simply returns a struct of function pointers to + callback functions that will be called by the planner, executor, and + various maintenance commands. + Most of the effort in writing an FDW is in implementing these callback + functions. + The handler function must be registered with + PostgreSQL as taking no arguments and + returning the special pseudo-type fdw_handler. The + callback functions are plain C functions and are not visible or + callable at the SQL level. The callback functions are described in + Section 50.2. +

The validator function is responsible for validating options given in + CREATE and ALTER commands for its + foreign data wrapper, as well as foreign servers, user mappings, and + foreign tables using the wrapper. + The validator function must be registered as taking two arguments, a + text array containing the options to be validated, and an OID + representing the type of object the options are associated with (in + the form of the OID of the system catalog the object would be stored + in, either + ForeignDataWrapperRelationId, + ForeignServerRelationId, + UserMappingRelationId, + or ForeignTableRelationId). + If no validator function is supplied, options are not checked at object + creation time or object alteration time. +


PrevHomeNext
Writing A Foreign Data WrapperUpForeign Data Wrapper Callback Routines
\ No newline at end of file diff --git a/doc/src/sgml/html/fdw-helpers.html b/doc/src/sgml/html/fdw-helpers.html new file mode 100644 index 000000000..ec6530e8a --- /dev/null +++ b/doc/src/sgml/html/fdw-helpers.html @@ -0,0 +1,312 @@ + +Foreign Data Wrapper Helper Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 50. Writing A Foreign Data WrapperNext

50.3. Foreign Data Wrapper Helper Functions

Several helper functions are exported from the core server so that + authors of foreign data wrappers can get easy access to attributes of + FDW-related objects, such as FDW options. + To use any of these functions, you need to include the header file + foreign/foreign.h in your source file. + That header also defines the struct types that are returned by + these functions. +

ForeignDataWrapper *
+GetForeignDataWrapper(Oid fdwid);

+ + This function returns a ForeignDataWrapper + object for the foreign-data wrapper with the given OID. A + ForeignDataWrapper object contains properties + of the FDW (see foreign/foreign.h for details). +

ForeignServer *
+GetForeignServer(Oid serverid);

+ + This function returns a ForeignServer object + for the foreign server with the given OID. A + ForeignServer object contains properties + of the server (see foreign/foreign.h for details). +

UserMapping *
+GetUserMapping(Oid userid, Oid serverid);

+ + This function returns a UserMapping object for + the user mapping of the given role on the given server. (If there is no + mapping for the specific user, it will return the mapping for + PUBLIC, or throw error if there is none.) A + UserMapping object contains properties of the + user mapping (see foreign/foreign.h for details). +

ForeignTable *
+GetForeignTable(Oid relid);

+ + This function returns a ForeignTable object for + the foreign table with the given OID. A + ForeignTable object contains properties of the + foreign table (see foreign/foreign.h for details). +

List *
+GetForeignTableColumnOptions(Oid relid, AttrNumber attnum);

+ + This function returns the per-column FDW options for the column with the + given foreign table OID and attribute number, in the form of a list of + DefElem. NIL is returned if the column has no + options. +

Some object types have name-based lookup functions in addition to the + OID-based ones: +

ForeignDataWrapper *
+GetForeignDataWrapperByName(const char *name, bool missing_ok);

+ + This function returns a ForeignDataWrapper + object for the foreign-data wrapper with the given name. If the wrapper + is not found, return NULL if missing_ok is true, otherwise raise an + error. +

ForeignServer *
+GetForeignServerByName(const char *name, bool missing_ok);

+ + This function returns a ForeignServer object + for the foreign server with the given name. If the server is not found, + return NULL if missing_ok is true, otherwise raise an error. +


PrevHomeNext
Foreign Data Wrapper Callback RoutinesUpForeign Data Wrapper Query Planning
\ No newline at end of file diff --git a/doc/src/sgml/html/fdw-planning.html b/doc/src/sgml/html/fdw-planning.html new file mode 100644 index 000000000..45cafc7be --- /dev/null +++ b/doc/src/sgml/html/fdw-planning.html @@ -0,0 +1,466 @@ + +Foreign Data Wrapper Query Planning
PostgreSQL 9.2.2 Documentation
PrevUpChapter 50. Writing A Foreign Data WrapperNext

50.4. Foreign Data Wrapper Query Planning

The FDW callback functions GetForeignRelSize, + GetForeignPaths, and GetForeignPlan must fit + into the workings of the PostgreSQL planner. Here are + some notes about what they must do. +

The information in root and baserel can be used + to reduce the amount of information that has to be fetched from the + foreign table (and therefore reduce the cost). + baserel->baserestrictinfo is particularly interesting, as + it contains restriction quals (WHERE clauses) that should be + used to filter the rows to be fetched. (The FDW itself is not required + to enforce these quals, as the core executor can check them instead.) + baserel->reltargetlist can be used to determine which + columns need to be fetched; but note that it only lists columns that + have to be emitted by the ForeignScan plan node, not + columns that are used in qual evaluation but not output by the query. +

Various private fields are available for the FDW planning functions to + keep information in. Generally, whatever you store in FDW private fields + should be palloc'd, so that it will be reclaimed at the end of planning. +

baserel->fdw_private is a void pointer that is + available for FDW planning functions to store information relevant to + the particular foreign table. The core planner does not touch it except + to initialize it to NULL when the baserel node is created. + It is useful for passing information forward from + GetForeignRelSize to GetForeignPaths and/or + GetForeignPaths to GetForeignPlan, thereby + avoiding recalculation. +

GetForeignPaths can identify the meaning of different + access paths by storing private information in the + fdw_private field of ForeignPath nodes. + fdw_private is declared as a List pointer, but + could actually contain anything since the core planner does not touch + it. However, best practice is to use a representation that's dumpable + by nodeToString, for use with debugging support available + in the backend. +

GetForeignPlan can examine the fdw_private + field of the selected ForeignPath node, and can generate + fdw_exprs and fdw_private lists to be + placed in the ForeignScan plan node, where they will be + available at execution time. Both of these lists must be + represented in a form that copyObject knows how to copy. + The fdw_private list has no other restrictions and is + not interpreted by the core backend in any way. The + fdw_exprs list, if not NIL, is expected to contain + expression trees that are intended to be executed at run time. These + trees will undergo post-processing by the planner to make them fully + executable. +

In GetForeignPlan, generally the passed-in target list can + be copied into the plan node as-is. The passed scan_clauses list + contains the same clauses as baserel->baserestrictinfo, + but may be re-ordered for better execution efficiency. In simple cases + the FDW can just strip RestrictInfo nodes from the + scan_clauses list (using extract_actual_clauses) and put + all the clauses into the plan node's qual list, which means that all the + clauses will be checked by the executor at run time. More complex FDWs + may be able to check some of the clauses internally, in which case those + clauses can be removed from the plan node's qual list so that the + executor doesn't waste time rechecking them. +

As an example, the FDW might identify some restriction clauses of the + form foreign_variable = + sub_expression, which it determines can be executed on + the remote server given the locally-evaluated value of the + sub_expression. The actual identification of such a + clause should happen during GetForeignPaths, since it would + affect the cost estimate for the path. The path's + fdw_private field would probably include a pointer to + the identified clause's RestrictInfo node. Then + GetForeignPlan would remove that clause from scan_clauses, + but add the sub_expression to fdw_exprs + to ensure that it gets massaged into executable form. It would probably + also put control information into the plan node's + fdw_private field to tell the execution functions what + to do at run time. The query transmitted to the remote server would + involve something like WHERE foreign_variable = + $1, with the parameter value obtained at run time from + evaluation of the fdw_exprs expression tree. +

The FDW should always construct at least one path that depends only on + the table's restriction clauses. In join queries, it might also choose + to construct path(s) that depend on join clauses, for example + foreign_variable = + local_variable. Such clauses will not be found in + baserel->baserestrictinfo but must be sought in the + relation's join lists. A path using such a clause is called a + "parameterized path". It must identify the other relations + used in the selected join clause(s) with a suitable value of + param_info; use get_baserel_parampathinfo + to compute that value. In GetForeignPlan, the + local_variable portion of the join clause would be added + to fdw_exprs, and then at run time the case works the + same as for an ordinary restriction clause. +


PrevHomeNext
Foreign Data Wrapper Helper FunctionsUpGenetic Query Optimizer
\ No newline at end of file diff --git a/doc/src/sgml/html/fdwhandler.html b/doc/src/sgml/html/fdwhandler.html new file mode 100644 index 000000000..ed890f798 --- /dev/null +++ b/doc/src/sgml/html/fdwhandler.html @@ -0,0 +1,229 @@ + +Writing A Foreign Data Wrapper

Chapter 50. Writing A Foreign Data Wrapper

All operations on a foreign table are handled through its foreign data + wrapper, which consists of a set of functions that the core server + calls. The foreign data wrapper is responsible for fetching + data from the remote data source and returning it to the + PostgreSQL executor. This chapter outlines how + to write a new foreign data wrapper. +

The foreign data wrappers included in the standard distribution are good + references when trying to write your own. Look into the + contrib/file_fdw subdirectory of the source tree. + The CREATE FOREIGN DATA WRAPPER reference page also has + some useful details. +

Note: The SQL standard specifies an interface for writing foreign data wrappers. + However, PostgreSQL does not implement that API, because the effort to + accommodate it into PostgreSQL would be large, and the standard API hasn't + gained wide adoption anyway. +


PrevHomeNext
Writing A Procedural Language HandlerUpForeign Data Wrapper Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/features-sql-standard.html b/doc/src/sgml/html/features-sql-standard.html new file mode 100644 index 000000000..b1836255e --- /dev/null +++ b/doc/src/sgml/html/features-sql-standard.html @@ -0,0 +1,3764 @@ + +Supported Features
PostgreSQL 9.2.2 Documentation
PrevUpAppendix D. SQL ConformanceNext

D.1. Supported Features

IdentifierPackageDescriptionComment
B012 Embedded C 
B021 Direct SQL 
E011CoreNumeric data types 
E011-01CoreINTEGER and SMALLINT data types 
E011-02CoreREAL, DOUBLE PRECISION, and FLOAT data types 
E011-03CoreDECIMAL and NUMERIC data types 
E011-04CoreArithmetic operators 
E011-05CoreNumeric comparison 
E011-06CoreImplicit casting among the numeric data types 
E021CoreCharacter data types 
E021-01CoreCHARACTER data type 
E021-02CoreCHARACTER VARYING data type 
E021-03CoreCharacter literals 
E021-04CoreCHARACTER_LENGTH functiontrims trailing spaces from CHARACTER values before counting
E021-05CoreOCTET_LENGTH function 
E021-06CoreSUBSTRING function 
E021-07CoreCharacter concatenation 
E021-08CoreUPPER and LOWER functions 
E021-09CoreTRIM function 
E021-10CoreImplicit casting among the character string types 
E021-11CorePOSITION function 
E021-12CoreCharacter comparison 
E031CoreIdentifiers 
E031-01CoreDelimited identifiers 
E031-02CoreLower case identifiers 
E031-03CoreTrailing underscore 
E051CoreBasic query specification 
E051-01CoreSELECT DISTINCT 
E051-02CoreGROUP BY clause 
E051-04CoreGROUP BY can contain columns not in <select list> 
E051-05CoreSelect list items can be renamed 
E051-06CoreHAVING clause 
E051-07CoreQualified * in select list 
E051-08CoreCorrelation names in the FROM clause 
E051-09CoreRename columns in the FROM clause 
E061CoreBasic predicates and search conditions 
E061-01CoreComparison predicate 
E061-02CoreBETWEEN predicate 
E061-03CoreIN predicate with list of values 
E061-04CoreLIKE predicate 
E061-05CoreLIKE predicate ESCAPE clause 
E061-06CoreNULL predicate 
E061-07CoreQuantified comparison predicate 
E061-08CoreEXISTS predicate 
E061-09CoreSubqueries in comparison predicate 
E061-11CoreSubqueries in IN predicate 
E061-12CoreSubqueries in quantified comparison predicate 
E061-13CoreCorrelated subqueries 
E061-14CoreSearch condition 
E071CoreBasic query expressions 
E071-01CoreUNION DISTINCT table operator 
E071-02CoreUNION ALL table operator 
E071-03CoreEXCEPT DISTINCT table operator 
E071-05CoreColumns combined via table operators need not have exactly the same data type 
E071-06CoreTable operators in subqueries 
E081CoreBasic Privileges 
E081-01CoreSELECT privilege 
E081-02CoreDELETE privilege 
E081-03CoreINSERT privilege at the table level 
E081-04CoreUPDATE privilege at the table level 
E081-05CoreUPDATE privilege at the column level 
E081-06CoreREFERENCES privilege at the table level 
E081-07CoreREFERENCES privilege at the column level 
E081-08CoreWITH GRANT OPTION 
E081-09CoreUSAGE privilege 
E081-10CoreEXECUTE privilege 
E091CoreSet functions 
E091-01CoreAVG 
E091-02CoreCOUNT 
E091-03CoreMAX 
E091-04CoreMIN 
E091-05CoreSUM 
E091-06CoreALL quantifier 
E091-07CoreDISTINCT quantifier 
E101CoreBasic data manipulation 
E101-01CoreINSERT statement 
E101-03CoreSearched UPDATE statement 
E101-04CoreSearched DELETE statement 
E111CoreSingle row SELECT statement 
E121CoreBasic cursor support 
E121-01CoreDECLARE CURSOR 
E121-02CoreORDER BY columns need not be in select list 
E121-03CoreValue expressions in ORDER BY clause 
E121-04CoreOPEN statement 
E121-06CorePositioned UPDATE statement 
E121-07CorePositioned DELETE statement 
E121-08CoreCLOSE statement 
E121-10CoreFETCH statement implicit NEXT 
E121-17CoreWITH HOLD cursors 
E131CoreNull value support (nulls in lieu of values) 
E141CoreBasic integrity constraints 
E141-01CoreNOT NULL constraints 
E141-02CoreUNIQUE constraints of NOT NULL columns 
E141-03CorePRIMARY KEY constraints 
E141-04CoreBasic FOREIGN KEY constraint with the NO ACTION default for both referential delete action and referential update action 
E141-06CoreCHECK constraints 
E141-07CoreColumn defaults 
E141-08CoreNOT NULL inferred on PRIMARY KEY 
E141-10CoreNames in a foreign key can be specified in any order 
E151CoreTransaction support 
E151-01CoreCOMMIT statement 
E151-02CoreROLLBACK statement 
E152CoreBasic SET TRANSACTION statement 
E152-01CoreSET TRANSACTION statement: ISOLATION LEVEL SERIALIZABLE clause 
E152-02CoreSET TRANSACTION statement: READ ONLY and READ WRITE clauses 
E161CoreSQL comments using leading double minus 
E171CoreSQLSTATE support 
F021CoreBasic information schema 
F021-01CoreCOLUMNS view 
F021-02CoreTABLES view 
F021-03CoreVIEWS view 
F021-04CoreTABLE_CONSTRAINTS view 
F021-05CoreREFERENTIAL_CONSTRAINTS view 
F021-06CoreCHECK_CONSTRAINTS view 
F031CoreBasic schema manipulation 
F031-01CoreCREATE TABLE statement to create persistent base tables 
F031-02CoreCREATE VIEW statement 
F031-03CoreGRANT statement 
F031-04CoreALTER TABLE statement: ADD COLUMN clause 
F031-13CoreDROP TABLE statement: RESTRICT clause 
F031-16CoreDROP VIEW statement: RESTRICT clause 
F031-19CoreREVOKE statement: RESTRICT clause 
F032 CASCADE drop behavior 
F033 ALTER TABLE statement: DROP COLUMN clause 
F034 Extended REVOKE statement 
F034-01 REVOKE statement performed by other than the owner of a schema object 
F034-02 REVOKE statement: GRANT OPTION FOR clause 
F034-03 REVOKE statement to revoke a privilege that the grantee has WITH GRANT OPTION 
F041CoreBasic joined table 
F041-01CoreInner join (but not necessarily the INNER keyword) 
F041-02CoreINNER keyword 
F041-03CoreLEFT OUTER JOIN 
F041-04CoreRIGHT OUTER JOIN 
F041-05CoreOuter joins can be nested 
F041-07CoreThe inner table in a left or right outer join can also be used in an inner join 
F041-08CoreAll comparison operators are supported (rather than just =) 
F051CoreBasic date and time 
F051-01CoreDATE data type (including support of DATE literal) 
F051-02CoreTIME data type (including support of TIME literal) with fractional seconds precision of at least 0 
F051-03CoreTIMESTAMP data type (including support of TIMESTAMP literal) with fractional seconds precision of at least 0 and 6 
F051-04CoreComparison predicate on DATE, TIME, and TIMESTAMP data types 
F051-05CoreExplicit CAST between datetime types and character string types 
F051-06CoreCURRENT_DATE 
F051-07CoreLOCALTIME 
F051-08CoreLOCALTIMESTAMP 
F052Enhanced datetime facilitiesIntervals and datetime arithmetic 
F053 OVERLAPS predicate 
F081CoreUNION and EXCEPT in views 
F111 Isolation levels other than SERIALIZABLE 
F111-01 READ UNCOMMITTED isolation level 
F111-02 READ COMMITTED isolation level 
F111-03 REPEATABLE READ isolation level 
F131CoreGrouped operations 
F131-01CoreWHERE, GROUP BY, and HAVING clauses supported in queries with grouped views 
F131-02CoreMultiple tables supported in queries with grouped views 
F131-03CoreSet functions supported in queries with grouped views 
F131-04CoreSubqueries with GROUP BY and HAVING clauses and grouped views 
F131-05CoreSingle row SELECT with GROUP BY and HAVING clauses and grouped views 
F171 Multiple schemas per user 
F191Enhanced integrity managementReferential delete actions 
F200 TRUNCATE TABLE statement 
F201CoreCAST function 
F221CoreExplicit defaults 
F222 INSERT statement: DEFAULT VALUES clause 
F231 Privilege tables 
F231-01 TABLE_PRIVILEGES view 
F231-02 COLUMN_PRIVILEGES view 
F231-03 USAGE_PRIVILEGES view 
F251 Domain support 
F261CoreCASE expression 
F261-01CoreSimple CASE 
F261-02CoreSearched CASE 
F261-03CoreNULLIF 
F261-04CoreCOALESCE 
F262 Extended CASE expression 
F271 Compound character literals 
F281 LIKE enhancements 
F302 INTERSECT table operator 
F302-01 INTERSECT DISTINCT table operator 
F302-02 INTERSECT ALL table operator 
F304 EXCEPT ALL table operator 
F311-01CoreCREATE SCHEMA 
F311-02CoreCREATE TABLE for persistent base tables 
F311-03CoreCREATE VIEW 
F311-05CoreGRANT statement 
F321 User authorization 
F361 Subprogram support 
F381 Extended schema manipulation 
F381-01 ALTER TABLE statement: ALTER COLUMN clause 
F381-02 ALTER TABLE statement: ADD CONSTRAINT clause 
F381-03 ALTER TABLE statement: DROP CONSTRAINT clause 
F382 Alter column data type 
F383 Set column not null clause 
F391 Long identifiers 
F392 Unicode escapes in identifiers 
F393 Unicode escapes in literals 
F401 Extended joined table 
F401-01 NATURAL JOIN 
F401-02 FULL OUTER JOIN 
F401-04 CROSS JOIN 
F402 Named column joins for LOBs, arrays, and multisets 
F411Enhanced datetime facilitiesTime zone specificationdifferences regarding literal interpretation
F421 National character 
F431 Read-only scrollable cursors 
F431-01 FETCH with explicit NEXT 
F431-02 FETCH FIRST 
F431-03 FETCH LAST 
F431-04 FETCH PRIOR 
F431-05 FETCH ABSOLUTE 
F431-06 FETCH RELATIVE 
F441 Extended set function support 
F442 Mixed column references in set functions 
F471CoreScalar subquery values 
F481CoreExpanded NULL predicate 
F491Enhanced integrity managementConstraint management 
F501CoreFeatures and conformance views 
F501-01CoreSQL_FEATURES view 
F501-02CoreSQL_SIZING view 
F501-03CoreSQL_LANGUAGES view 
F502 Enhanced documentation tables 
F502-01 SQL_SIZING_PROFILES view 
F502-02 SQL_IMPLEMENTATION_INFO view 
F502-03 SQL_PACKAGES view 
F531 Temporary tables 
F555Enhanced datetime facilitiesEnhanced seconds precision 
F561 Full value expressions 
F571 Truth value tests 
F591 Derived tables 
F611 Indicator data types 
F641 Row and table constructors 
F651 Catalog name qualifiers 
F661 Simple tables 
F672 Retrospective check constraints 
F690 Collation supportbut no character set support
F692 Extended collation support 
F701Enhanced integrity managementReferential update actions 
F711 ALTER domain 
F731 INSERT column privileges 
F761 Session management 
F762 CURRENT_CATALOG 
F763 CURRENT_SCHEMA 
F771 Connection management 
F781 Self-referencing operations 
F791 Insensitive cursors 
F801 Full set function 
F850 Top-level <order by clause> in <query expression> 
F851 <order by clause> in subqueries 
F852 Top-level <order by clause> in views 
F855 Nested <order by clause> in <query expression> 
F856 Nested <fetch first clause> in <query expression> 
F857 Top-level <fetch first clause> in <query expression> 
F858 <fetch first clause> in subqueries 
F859 Top-level <fetch first clause> in views 
F860 <fetch first row count> in <fetch first clause> 
F861 Top-level <result offset clause> in <query expression> 
F862 <result offset clause> in subqueries 
F863 Nested <result offset clause> in <query expression> 
F864 Top-level <result offset clause> in views 
F865 <offset row count> in <result offset clause> 
S071Enhanced object supportSQL paths in function and type name resolution 
S092 Arrays of user-defined types 
S095 Array constructors by query 
S096 Optional array bounds 
S098 ARRAY_AGG 
S111Enhanced object supportONLY in query expressions 
S201 SQL-invoked routines on arrays 
S201-01 Array parameters 
S201-02 Array as result type of functions 
S211Enhanced object supportUser-defined cast functions 
T031 BOOLEAN data type 
T071 BIGINT data type 
T121 WITH (excluding RECURSIVE) in query expression 
T122 WITH (excluding RECURSIVE) in subquery 
T131 Recursive query 
T132 Recursive query in subquery 
T141 SIMILAR predicate 
T151 DISTINCT predicate 
T152 DISTINCT predicate with negation 
T171 LIKE clause in table definition 
T172 AS subquery clause in table definition 
T173 Extended LIKE clause in table definition 
T191Enhanced integrity managementReferential action RESTRICT 
T201Enhanced integrity managementComparable data types for referential constraints 
T211-01Active database, Enhanced integrity managementTriggers activated on UPDATE, INSERT, or DELETE of one base table 
T211-02Active database, Enhanced integrity managementBEFORE triggers 
T211-03Active database, Enhanced integrity managementAFTER triggers 
T211-04Active database, Enhanced integrity managementFOR EACH ROW triggers 
T211-05Active database, Enhanced integrity managementAbility to specify a search condition that must be true before the trigger is invoked 
T211-07Active database, Enhanced integrity managementTRIGGER privilege 
T212Enhanced integrity managementEnhanced trigger capability 
T213 INSTEAD OF triggers 
T231 Sensitive cursors 
T241 START TRANSACTION statement 
T271 Savepoints 
T281 SELECT privilege with column granularity 
T312 OVERLAY function 
T321-01CoreUser-defined functions with no overloading 
T321-03CoreFunction invocation 
T321-06CoreROUTINES view 
T321-07CorePARAMETERS view 
T323 Explicit security for external routines 
T331 Basic roles 
T341 Overloading of SQL-invoked functions and procedures 
T351 Bracketed SQL comments (/*...*/ comments) 
T441 ABS and MOD functions 
T461 Symmetric BETWEEN predicate 
T501 Enhanced EXISTS predicate 
T551 Optional key words for default syntax 
T581 Regular expression substring function 
T591 UNIQUE constraints of possibly null columns 
T614 NTILE function 
T615 LEAD and LAG functions 
T617 FIRST_VALUE and LAST_VALUE function 
T621 Enhanced numeric functions 
T631CoreIN predicate with one list element 
T651 SQL-schema statements in SQL routines 
T655 Cyclically dependent routines 
X010 XML type 
X011 Arrays of XML type 
X016 Persistent XML values 
X020 XMLConcat 
X031 XMLElement 
X032 XMLForest 
X034 XMLAgg 
X035 XMLAgg: ORDER BY option 
X036 XMLComment 
X037 XMLPI 
X040 Basic table mapping 
X041 Basic table mapping: nulls absent 
X042 Basic table mapping: null as nil 
X043 Basic table mapping: table as forest 
X044 Basic table mapping: table as element 
X045 Basic table mapping: with target namespace 
X046 Basic table mapping: data mapping 
X047 Basic table mapping: metadata mapping 
X048 Basic table mapping: base64 encoding of binary strings 
X049 Basic table mapping: hex encoding of binary strings 
X050 Advanced table mapping 
X051 Advanced table mapping: nulls absent 
X052 Advanced table mapping: null as nil 
X053 Advanced table mapping: table as forest 
X054 Advanced table mapping: table as element 
X055 Advanced table mapping: target namespace 
X056 Advanced table mapping: data mapping 
X057 Advanced table mapping: metadata mapping 
X058 Advanced table mapping: base64 encoding of binary strings 
X059 Advanced table mapping: hex encoding of binary strings 
X060 XMLParse: Character string input and CONTENT option 
X061 XMLParse: Character string input and DOCUMENT option 
X070 XMLSerialize: Character string serialization and CONTENT option 
X071 XMLSerialize: Character string serialization and DOCUMENT option 
X072 XMLSerialize: Character string serialization 
X090 XML document predicate 
X120 XML parameters in SQL routines 
X121 XML parameters in external routines 
X400 Name and identifier mapping 
X410 Alter column data type: XML type 

+


PrevHomeNext
SQL ConformanceUpUnsupported Features
\ No newline at end of file diff --git a/doc/src/sgml/html/features.html b/doc/src/sgml/html/features.html new file mode 100644 index 000000000..8d4813195 --- /dev/null +++ b/doc/src/sgml/html/features.html @@ -0,0 +1,359 @@ + +SQL Conformance

Appendix D. SQL Conformance

Table of Contents
D.1. Supported Features
D.2. Unsupported Features

This section attempts to outline to what extent + PostgreSQL conforms to the current SQL + standard. The following information is not a full statement of + conformance, but it presents the main topics in as much detail as is + both reasonable and useful for users. +

The formal name of the SQL standard is ISO/IEC 9075 "Database + Language SQL". A revised version of the standard is released + from time to time; the most recent update appearing in 2011. + The 2011 version is referred to as ISO/IEC 9075:2011, or simply as SQL:2011. + The versions prior to that were SQL:2008, SQL:2003, SQL:1999, and SQL-92. Each version + replaces the previous one, so claims of conformance to earlier + versions have no official merit. + PostgreSQL development aims for + conformance with the latest official version of the standard where + such conformance does not contradict traditional features or common + sense. Many of the features required by the SQL + standard are supported, though sometimes with slightly differing + syntax or function. Further moves towards conformance can be + expected over time. +

SQL-92 defined three feature sets for + conformance: Entry, Intermediate, and Full. Most database + management systems claiming SQL standard + conformance were conforming at only the Entry level, since the + entire set of features in the Intermediate and Full levels was + either too voluminous or in conflict with legacy behaviors. +

Starting with SQL:1999, the SQL standard defines + a large set of individual features rather than the ineffectively + broad three levels found in SQL-92. A large + subset of these features represents the "Core" + features, which every conforming SQL implementation must supply. + The rest of the features are purely optional. Some optional + features are grouped together to form "packages", which + SQL implementations can claim conformance to, thus claiming + conformance to particular groups of features. +

The standard versions beginning with SQL:2003 + are also split into a number + of parts. Each is known by a shorthand name. Note that these parts + are not consecutively numbered. + +

  • ISO/IEC 9075-1 Framework (SQL/Framework)

  • ISO/IEC 9075-2 Foundation (SQL/Foundation)

  • ISO/IEC 9075-3 Call Level Interface (SQL/CLI)

  • ISO/IEC 9075-4 Persistent Stored Modules (SQL/PSM)

  • ISO/IEC 9075-9 Management of External Data (SQL/MED)

  • ISO/IEC 9075-10 Object Language Bindings (SQL/OLB)

  • ISO/IEC 9075-11 Information and Definition Schemas (SQL/Schemata)

  • ISO/IEC 9075-13 Routines and Types using the Java Language (SQL/JRT)

  • ISO/IEC 9075-14 XML-related specifications (SQL/XML)

+

The PostgreSQL core covers parts 1, 2, 9, + 11, and 14. Part 3 is covered by the ODBC driver, and part 13 is + covered by the PL/Java plug-in, but exact conformance is currently + not being verified for these components. There are currently no + implementations of parts 4 and 10 + for PostgreSQL. +

PostgreSQL supports most of the major features of SQL:2011. Out of + 179 mandatory features required for full Core conformance, + PostgreSQL conforms to at least 160. In addition, there is a long + list of supported optional features. It might be worth noting that at + the time of writing, no current version of any database management + system claims full conformance to Core SQL:2011. +

In the following two sections, we provide a list of those features + that PostgreSQL supports, followed by a + list of the features defined in SQL:2011 which + are not yet supported in PostgreSQL. + Both of these lists are approximate: There might be minor details that + are nonconforming for a feature that is listed as supported, and + large parts of an unsupported feature might in fact be implemented. + The main body of the documentation always contains the most accurate + information about what does and does not work. +

Note: Feature codes containing a hyphen are subfeatures. Therefore, if a + particular subfeature is not supported, the main feature is listed + as unsupported even if some other subfeatures are supported. +


PrevHomeNext
SQL Key WordsUpSupported Features
\ No newline at end of file diff --git a/doc/src/sgml/html/file-fdw.html b/doc/src/sgml/html/file-fdw.html new file mode 100644 index 000000000..0ca0667fc --- /dev/null +++ b/doc/src/sgml/html/file-fdw.html @@ -0,0 +1,479 @@ + +file_fdw
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.14. file_fdw

The file_fdw module provides the foreign-data wrapper + file_fdw, which can be used to access data + files in the server's file system. Data files must be in a format + that can be read by COPY FROM; + see COPY for details. +

A foreign table created using this wrapper can have the following options: +

filename

Specifies the file to be read. Required. Must be an absolute path name. +

format

Specifies the file's format, + the same as COPY's FORMAT option. +

header

Specifies whether the file has a header line, + the same as COPY's HEADER option. +

delimiter

Specifies the file's delimiter character, + the same as COPY's DELIMITER option. +

quote

Specifies the file's quote character, + the same as COPY's QUOTE option. +

escape

Specifies the file's escape character, + the same as COPY's ESCAPE option. +

null

Specifies the file's null string, + the same as COPY's NULL option. +

encoding

Specifies the file's encoding, + the same as COPY's ENCODING option. +

A column of a foreign table created using this wrapper can have the + following options: +

force_not_null

This is a Boolean option. If true, it specifies that values of the + column should not be matched against the null string (that is, the + file-level null option). This has the same effect + as listing the column in COPY's + FORCE_NOT_NULL option. +

COPY's OIDS and + FORCE_QUOTE options are currently not supported by + file_fdw. +

These options can only be specified for a foreign table or its columns, not + in the options of the file_fdw foreign-data wrapper, nor in the + options of a server or user mapping using the wrapper. +

Changing table-level options requires superuser privileges, for security + reasons: only a superuser should be able to determine which file is read. + In principle non-superusers could be allowed to change the other options, + but that's not supported at present. +

For a foreign table using file_fdw, EXPLAIN shows + the name of the file to be read. Unless COSTS OFF is + specified, the file size (in bytes) is shown as well. +

Example F-1. Create a Foreign Table for PostgreSQL CSV Logs

One of the obvious uses for the file_fdw is to make + the PostgreSQL activity log available as a table for querying. To + do this, first you must be logging to a CSV file, which here we + will call pglog.csv. First, install file_fdw + as an extension: +

CREATE EXTENSION file_fdw;

Then create a foreign data server: + +

CREATE SERVER pglog FOREIGN DATA WRAPPER file_fdw;

+

Now you are ready to create the foreign data table. Using the + CREATE FOREIGN TABLE command, you will need to define + the columns for the table, the CSV file name, and its format: + +

CREATE FOREIGN TABLE pglog (
+  log_time timestamp(3) with time zone,
+  user_name text,
+  database_name text,
+  process_id integer,
+  connection_from text,
+  session_id text,
+  session_line_num bigint,
+  command_tag text,
+  session_start_time timestamp with time zone,
+  virtual_transaction_id text,
+  transaction_id bigint,
+  error_severity text,
+  sql_state_code text,
+  message text,
+  detail text,
+  hint text,
+  internal_query text,
+  internal_query_pos integer,
+  context text,
+  query text,
+  query_pos integer,
+  location text,
+  application_name text
+) SERVER pglog
+OPTIONS ( filename '/home/josh/9.1/data/pg_log/pglog.csv', format 'csv' );

+

That's it — now you can query your log directly. In production, of course, + you would need to define some way to adjust to log rotation. +


PrevHomeNext
earthdistanceUpfuzzystrmatch
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-admin.html b/doc/src/sgml/html/functions-admin.html new file mode 100644 index 000000000..d1a5a823c --- /dev/null +++ b/doc/src/sgml/html/functions-admin.html @@ -0,0 +1,2927 @@ + +System Administration Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.26. System Administration Functions

The functions described in this section are used to control and + monitor a PostgreSQL installation. +

9.26.1. Configuration Settings Functions

Table 9-57 shows the functions + available to query and alter run-time configuration parameters. +

Table 9-57. Configuration Settings Functions

NameReturn TypeDescription
+ current_setting(setting_name) + textget current value of setting
+ set_config(setting_name, + new_value, + is_local) + textset parameter and return new value

The function current_setting yields the + current value of the setting setting_name. + It corresponds to the SQL command + SHOW. An example: +

SELECT current_setting('datestyle');
+
+ current_setting
+-----------------
+ ISO, MDY
+(1 row)

+

set_config sets the parameter + setting_name to + new_value. If + is_local is true, the + new value will only apply to the current transaction. If you want + the new value to apply for the current session, use + false instead. The function corresponds to the + SQL command SET. An example: +

SELECT set_config('log_statement_stats', 'off', false);
+
+ set_config
+------------
+ off
+(1 row)

+

9.26.2. Server Signalling Functions

The functions shown in Table 9-58 send control signals to + other server processes. Use of these functions is usually restricted + to superusers, with noted exceptions. +

Table 9-58. Server Signalling Functions

NameReturn TypeDescription
pg_cancel_backend(pid int) + booleanCancel a backend's current query. You can execute this against + another backend that has exactly the same role as the user calling the + function. In all other cases, you must be a superuser. +
pg_reload_conf() + booleanCause server processes to reload their configuration files
pg_rotate_logfile() + booleanRotate server's log file
pg_terminate_backend(pid int) + booleanTerminate a backend. You can execute this against + another backend that has exactly the same role as the user + calling the function. In all other cases, you must be a + superuser. +

Each of these functions returns true if + successful and false otherwise. +

pg_cancel_backend and pg_terminate_backend + send signals (SIGINT or SIGTERM + respectively) to backend processes identified by process ID. + The process ID of an active backend can be found from + the pid column of the + pg_stat_activity view, or by listing the + postgres processes on the server (using + ps on Unix or the Task + Manager on Windows). + The role of an active backend can be found from the + usename column of the + pg_stat_activity view. +

pg_reload_conf sends a SIGHUP signal + to the server, causing configuration files + to be reloaded by all server processes. +

pg_rotate_logfile signals the log-file manager to switch + to a new output file immediately. This works only when the built-in + log collector is running, since otherwise there is no log-file manager + subprocess. +

9.26.3. Backup Control Functions

The functions shown in Table 9-59 assist in making on-line backups. + These functions cannot be executed during recovery (except + pg_xlog_location_diff). +

Table 9-59. Backup Control Functions

NameReturn TypeDescription
pg_create_restore_point(name text) + textCreate a named point for performing restore (restricted to superusers)
pg_current_xlog_insert_location() + textGet current transaction log insert location
pg_current_xlog_location() + textGet current transaction log write location
pg_start_backup(label text [, fast boolean ]) + textPrepare for performing on-line backup (restricted to superusers or replication roles)
pg_stop_backup() + textFinish performing on-line backup (restricted to superusers or replication roles)
pg_switch_xlog() + textForce switch to a new transaction log file (restricted to superusers)
pg_xlogfile_name(location text) + textConvert transaction log location string to file name
pg_xlogfile_name_offset(location text) + text, integerConvert transaction log location string to file name and decimal byte offset within file
pg_xlog_location_diff(location text, location text) + numericCalculate the difference between two transaction log locations

pg_start_backup accepts an + arbitrary user-defined label for the backup. (Typically this would be + the name under which the backup dump file will be stored.) The function + writes a backup label file (backup_label) into the + database cluster's data directory, performs a checkpoint, + and then returns the backup's starting transaction log location as text. + The user can ignore this result value, but it is + provided in case it is useful. +

postgres=# select pg_start_backup('label_goes_here');
+ pg_start_backup
+-----------------
+ 0/D4445B8
+(1 row)

+ There is an optional second parameter of type boolean. If true, + it specifies executing pg_start_backup as quickly as + possible. This forces an immediate checkpoint which will cause a + spike in I/O operations, slowing any concurrently executing queries. +

pg_stop_backup removes the label file created by + pg_start_backup, and creates a backup history file in + the transaction log archive area. The history file includes the label given to + pg_start_backup, the starting and ending transaction log locations for + the backup, and the starting and ending times of the backup. The return + value is the backup's ending transaction log location (which again + can be ignored). After recording the ending location, the current + transaction log insertion + point is automatically advanced to the next transaction log file, so that the + ending transaction log file can be archived immediately to complete the backup. +

pg_switch_xlog moves to the next transaction log file, allowing the + current file to be archived (assuming you are using continuous archiving). + The return value is the ending transaction log location + 1 within the just-completed transaction log file. + If there has been no transaction log activity since the last transaction log switch, + pg_switch_xlog does nothing and returns the start location + of the transaction log file currently in use. +

pg_create_restore_point creates a named transaction log + record that can be used as recovery target, and returns the corresponding + transaction log location. The given name can then be used with + recovery_target_name to specify the point up to which + recovery will proceed. Avoid creating multiple restore points with the + same name, since recovery will stop at the first one whose name matches + the recovery target. +

pg_current_xlog_location displays the current transaction log write + location in the same format used by the above functions. Similarly, + pg_current_xlog_insert_location displays the current transaction log + insertion point. The insertion point is the "logical" end + of the transaction log + at any instant, while the write location is the end of what has actually + been written out from the server's internal buffers. The write location + is the end of what can be examined from outside the server, and is usually + what you want if you are interested in archiving partially-complete transaction log + files. The insertion point is made available primarily for server + debugging purposes. These are both read-only operations and do not + require superuser permissions. +

You can use pg_xlogfile_name_offset to extract the + corresponding transaction log file name and byte offset from the results of any of the + above functions. For example: +

postgres=# SELECT * FROM pg_xlogfile_name_offset(pg_stop_backup());
+        file_name         | file_offset 
+--------------------------+-------------
+ 00000001000000000000000D |     4039624
+(1 row)

+ Similarly, pg_xlogfile_name extracts just the transaction log file name. + When the given transaction log location is exactly at a transaction log file boundary, both + these functions return the name of the preceding transaction log file. + This is usually the desired behavior for managing transaction log archiving + behavior, since the preceding file is the last one that currently + needs to be archived. +

pg_xlog_location_diff calculates the difference in bytes + between two transaction log locations. It can be used with + pg_stat_replication or some functions shown in + Table 9-59 to get the replication lag. +

For details about proper usage of these functions, see + Section 24.3. +

9.26.4. Recovery Control Functions

The functions shown in Table 9-60 provide information + about the current status of the standby. + These functions may be executed both during recovery and in normal running. +

Table 9-60. Recovery Information Functions

NameReturn TypeDescription
pg_is_in_recovery() + boolTrue if recovery is still in progress. +
pg_last_xlog_receive_location() + textGet last transaction log location received and synced to disk by + streaming replication. While streaming replication is in progress + this will increase monotonically. If recovery has completed this will + remain static at + the value of the last WAL record received and synced to disk during + recovery. If streaming replication is disabled, or if it has not yet + started, the function returns NULL. +
pg_last_xlog_replay_location() + textGet last transaction log location replayed during recovery. + If recovery is still in progress this will increase monotonically. + If recovery has completed then this value will remain static at + the value of the last WAL record applied during that recovery. + When the server has been started normally without recovery + the function returns NULL. +
pg_last_xact_replay_timestamp() + timestamp with time zoneGet time stamp of last transaction replayed during recovery. + This is the time at which the commit or abort WAL record for that + transaction was generated on the primary. + If no transactions have been replayed during recovery, this function + returns NULL. Otherwise, if recovery is still in progress this will + increase monotonically. If recovery has completed then this value will + remain static at the value of the last transaction applied during that + recovery. When the server has been started normally without recovery + the function returns NULL. +

The functions shown in Table 9-61 control the progress of recovery. + These functions may be executed only during recovery. +

Table 9-61. Recovery Control Functions

NameReturn TypeDescription
pg_is_xlog_replay_paused() + boolTrue if recovery is paused. +
pg_xlog_replay_pause() + voidPauses recovery immediately. +
pg_xlog_replay_resume() + voidRestarts recovery if it was paused. +

While recovery is paused no further database changes are applied. + If in hot standby, all new queries will see the same consistent snapshot + of the database, and no further query conflicts will be generated until + recovery is resumed. +

If streaming replication is disabled, the paused state may continue + indefinitely without problem. While streaming replication is in + progress WAL records will continue to be received, which will + eventually fill available disk space, depending upon the duration of + the pause, the rate of WAL generation and available disk space. +

9.26.5. Snapshot Synchronization Functions

PostgreSQL allows database sessions to synchronize their + snapshots. A snapshot determines which data is visible to the + transaction that is using the snapshot. Synchronized snapshots are + necessary when two or more sessions need to see identical content in the + database. If two sessions just start their transactions independently, + there is always a possibility that some third transaction commits + between the executions of the two START TRANSACTION commands, + so that one session sees the effects of that transaction and the other + does not. +

To solve this problem, PostgreSQL allows a transaction to + export the snapshot it is using. As long as the exporting + transaction remains open, other transactions can import its + snapshot, and thereby be guaranteed that they see exactly the same view + of the database that the first transaction sees. But note that any + database changes made by any one of these transactions remain invisible + to the other transactions, as is usual for changes made by uncommitted + transactions. So the transactions are synchronized with respect to + pre-existing data, but act normally for changes they make themselves. +

Snapshots are exported with the pg_export_snapshot function, + shown in Table 9-62, and + imported with the SET TRANSACTION command. +

Table 9-62. Snapshot Synchronization Functions

NameReturn TypeDescription
pg_export_snapshot() + textSave the current snapshot and return its identifier

The function pg_export_snapshot saves the current snapshot + and returns a text string identifying the snapshot. This string + must be passed (outside the database) to clients that want to import the + snapshot. The snapshot is available for import only until the end of the + transaction that exported it. A transaction can export more than one + snapshot, if needed. Note that doing so is only useful in READ + COMMITTED transactions, since in REPEATABLE READ and + higher isolation levels, transactions use the same snapshot throughout + their lifetime. Once a transaction has exported any snapshots, it cannot + be prepared with PREPARE TRANSACTION. +

See SET TRANSACTION for details of how to use an + exported snapshot. +

9.26.6. Database Object Management Functions

The functions shown in Table 9-63 calculate + the disk space usage of database objects. +

Table 9-63. Database Object Size Functions

NameReturn TypeDescription
pg_column_size(any)intNumber of bytes used to store a particular value (possibly compressed)
pg_database_size(oid) + bigintDisk space used by the database with the specified OID
pg_database_size(name) + bigintDisk space used by the database with the specified name
pg_indexes_size(regclass) + bigint Total disk space used by indexes attached to the specified table +
pg_relation_size(relation regclass, fork text) + bigint Disk space used by the specified fork ('main', + 'fsm' or 'vm') + of the specified table or index +
pg_relation_size(relation regclass) + bigint Shorthand for pg_relation_size(..., 'main') +
pg_size_pretty(bigint) + text Converts a size in bytes expressed as a 64-bit integer into a + human-readable format with size units +
pg_size_pretty(numeric) + text Converts a size in bytes expressed as a numeric value into a + human-readable format with size units +
pg_table_size(regclass) + bigint Disk space used by the specified table, excluding indexes + (but including TOAST, free space map, and visibility map) +
pg_tablespace_size(oid) + bigintDisk space used by the tablespace with the specified OID
pg_tablespace_size(name) + bigintDisk space used by the tablespace with the specified name
pg_total_relation_size(regclass) + bigint Total disk space used by the specified table, + including all indexes and TOAST data +

pg_column_size shows the space used to store any individual + data value. +

pg_total_relation_size accepts the OID or name of a + table or toast table, and returns the total on-disk space used for + that table, including all associated indexes. This function is + equivalent to pg_table_size + + pg_indexes_size. +

pg_table_size accepts the OID or name of a table and + returns the disk space needed for that table, exclusive of indexes. + (TOAST space, free space map, and visibility map are included.) +

pg_indexes_size accepts the OID or name of a table and + returns the total disk space used by all the indexes attached to that + table. +

pg_database_size and pg_tablespace_size + accept the OID or name of a database or tablespace, and return the total + disk space used therein. +

pg_relation_size accepts the OID or name of a table, index or + toast table, and returns the on-disk size in bytes. Specifying + 'main' or leaving out the second argument returns the + size of the main data fork of the relation. Specifying + 'fsm' returns the size of the + Free Space Map (see Section 56.3) associated with the + relation. Specifying 'vm' returns the size of the + Visibility Map (see Section 56.4) associated with the + relation. Note that this function shows the size of only one fork; + for most purposes it is more convenient to use the higher-level + functions pg_total_relation_size or + pg_table_size. +

pg_size_pretty can be used to format the result of one of + the other functions in a human-readable way, using kB, MB, GB or TB as + appropriate. +

The functions above that operate on tables or indexes accept a + regclass argument, which is simply the OID of the table or index + in the pg_class system catalog. You do not have to look up + the OID by hand, however, since the regclass data type's input + converter will do the work for you. Just write the table name enclosed in + single quotes so that it looks like a literal constant. For compatibility + with the handling of ordinary SQL names, the string + will be converted to lower case unless it contains double quotes around + the table name. +

If an OID that does not represent an existing object is passed as + argument to one of the above functions, NULL is returned. +

The functions shown in Table 9-64 assist + in identifying the specific disk files associated with database objects. +

Table 9-64. Database Object Location Functions

NameReturn TypeDescription
pg_relation_filenode(relation regclass) + oid Filenode number of the specified relation +
pg_relation_filepath(relation regclass) + text File path name of the specified relation +

pg_relation_filenode accepts the OID or name of a table, + index, sequence, or toast table, and returns the "filenode" number + currently assigned to it. The filenode is the base component of the file + name(s) used for the relation (see Section 56.1 + for more information). For most tables the result is the same as + pg_class.relfilenode, but for certain + system catalogs relfilenode is zero and this function must + be used to get the correct value. The function returns NULL if passed + a relation that does not have storage, such as a view. +

pg_relation_filepath is similar to + pg_relation_filenode, but it returns the entire file path name + (relative to the database cluster's data directory PGDATA) of + the relation. +

9.26.7. Generic File Access Functions

The functions shown in Table 9-65 provide native access to + files on the machine hosting the server. Only files within the + database cluster directory and the log_directory can be + accessed. Use a relative path for files in the cluster directory, + and a path matching the log_directory configuration setting + for log files. Use of these functions is restricted to superusers. +

Table 9-65. Generic File Access Functions

NameReturn TypeDescription
pg_ls_dir(dirname text) + setof textList the contents of a directory
pg_read_file(filename text [, offset bigint, length bigint]) + textReturn the contents of a text file
pg_read_binary_file(filename text [, offset bigint, length bigint]) + byteaReturn the contents of a file
pg_stat_file(filename text) + recordReturn information about a file

pg_ls_dir returns all the names in the specified + directory, except the special entries "." and + "..". +

pg_read_file returns part of a text file, starting + at the given offset, returning at most length + bytes (less if the end of file is reached first). If offset + is negative, it is relative to the end of the file. + If offset and length are omitted, the entire + file is returned. The bytes read from the file are interpreted as a string + in the server encoding; an error is thrown if they are not valid in that + encoding. +

pg_read_binary_file is similar to + pg_read_file, except that the result is a bytea value; + accordingly, no encoding checks are performed. + In combination with the convert_from function, this function + can be used to read a file in a specified encoding: +

SELECT convert_from(pg_read_binary_file('file_in_utf8.txt'), 'UTF8');

+

pg_stat_file returns a record containing the file + size, last accessed time stamp, last modified time stamp, + last file status change time stamp (Unix platforms only), + file creation time stamp (Windows only), and a boolean + indicating if it is a directory. Typical usages include: +

SELECT * FROM pg_stat_file('filename');
+SELECT (pg_stat_file('filename')).modification;

+

9.26.8. Advisory Lock Functions

The functions shown in Table 9-66 + manage advisory locks. For details about proper use of these functions, + see Section 13.3.4. +

Table 9-66. Advisory Lock Functions

NameReturn TypeDescription
pg_advisory_lock(key bigint) + voidObtain exclusive session level advisory lock
pg_advisory_lock(key1 int, key2 int) + voidObtain exclusive session level advisory lock
pg_advisory_lock_shared(key bigint) + voidObtain shared session level advisory lock
pg_advisory_lock_shared(key1 int, key2 int) + voidObtain shared session level advisory lock
pg_advisory_unlock(key bigint) + booleanRelease an exclusive session level advisory lock
pg_advisory_unlock(key1 int, key2 int) + booleanRelease an exclusive session level advisory lock
pg_advisory_unlock_all() + voidRelease all session level advisory locks held by the current session
pg_advisory_unlock_shared(key bigint) + booleanRelease a shared session level advisory lock
pg_advisory_unlock_shared(key1 int, key2 int) + booleanRelease a shared session level advisory lock
pg_advisory_xact_lock(key bigint) + voidObtain exclusive transaction level advisory lock
pg_advisory_xact_lock(key1 int, key2 int) + voidObtain exclusive transaction level advisory lock
pg_advisory_xact_lock_shared(key bigint) + voidObtain shared transaction level advisory lock
pg_advisory_xact_lock_shared(key1 int, key2 int) + voidObtain shared transaction level advisory lock
pg_try_advisory_lock(key bigint) + booleanObtain exclusive session level advisory lock if available
pg_try_advisory_lock(key1 int, key2 int) + booleanObtain exclusive session level advisory lock if available
pg_try_advisory_lock_shared(key bigint) + booleanObtain shared session level advisory lock if available
pg_try_advisory_lock_shared(key1 int, key2 int) + booleanObtain shared session level advisory lock if available
pg_try_advisory_xact_lock(key bigint) + booleanObtain exclusive transaction level advisory lock if available
pg_try_advisory_xact_lock(key1 int, key2 int) + booleanObtain exclusive transaction level advisory lock if available
pg_try_advisory_xact_lock_shared(key bigint) + booleanObtain shared transaction level advisory lock if available
pg_try_advisory_xact_lock_shared(key1 int, key2 int) + booleanObtain shared transaction level advisory lock if available

pg_advisory_lock locks an application-defined resource, + which can be identified either by a single 64-bit key value or two + 32-bit key values (note that these two key spaces do not overlap). + If another session already holds a lock on the same resource identifier, + this function will wait until the resource becomes available. The lock + is exclusive. Multiple lock requests stack, so that if the same resource + is locked three times it must then be unlocked three times to be + released for other sessions' use. +

pg_advisory_lock_shared works the same as + pg_advisory_lock, + except the lock can be shared with other sessions requesting shared locks. + Only would-be exclusive lockers are locked out. +

pg_try_advisory_lock is similar to + pg_advisory_lock, except the function will not wait for the + lock to become available. It will either obtain the lock immediately and + return true, or return false if the lock cannot be + acquired immediately. +

pg_try_advisory_lock_shared works the same as + pg_try_advisory_lock, except it attempts to acquire + a shared rather than an exclusive lock. +

pg_advisory_unlock will release a previously-acquired + exclusive session level advisory lock. It + returns true if the lock is successfully released. + If the lock was not held, it will return false, + and in addition, an SQL warning will be reported by the server. +

pg_advisory_unlock_shared works the same as + pg_advisory_unlock, + except it releases a shared session level advisory lock. +

pg_advisory_unlock_all will release all session level advisory + locks held by the current session. (This function is implicitly invoked + at session end, even if the client disconnects ungracefully.) +

pg_advisory_xact_lock works the same as + pg_advisory_lock, except the lock is automatically released + at the end of the current transaction and cannot be released explicitly. +

pg_advisory_xact_lock_shared works the same as + pg_advisory_lock_shared, except the lock is automatically released + at the end of the current transaction and cannot be released explicitly. +

pg_try_advisory_xact_lock works the same as + pg_try_advisory_lock, except the lock, if acquired, + is automatically released at the end of the current transaction and + cannot be released explicitly. +

pg_try_advisory_xact_lock_shared works the same as + pg_try_advisory_lock_shared, except the lock, if acquired, + is automatically released at the end of the current transaction and + cannot be released explicitly. +


PrevHomeNext
System Information FunctionsUpTrigger Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-aggregate.html b/doc/src/sgml/html/functions-aggregate.html new file mode 100644 index 000000000..97a10089b --- /dev/null +++ b/doc/src/sgml/html/functions-aggregate.html @@ -0,0 +1,1711 @@ + +Aggregate Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.20. Aggregate Functions

Aggregate functions compute a single result + from a set of input values. The built-in aggregate functions + are listed in + Table 9-45 and + Table 9-46. + The special syntax considerations for aggregate + functions are explained in Section 4.2.7. + Consult Section 2.7 for additional introductory + information. +

Table 9-45. General-Purpose Aggregate Functions

FunctionArgument Type(s)Return TypeDescription
+ array_agg(expression) + any + array of the argument type + input values, including nulls, concatenated into an array
+ + avg(expression) + smallint, int, + bigint, real, double + precision, numeric, or interval + numeric for any integer-type argument, + double precision for a floating-point argument, + otherwise the same as the argument data type + the average (arithmetic mean) of all input values
+ bit_and(expression) + smallint, int, bigint, or + bit + same as argument data type + the bitwise AND of all non-null input values, or null if none
+ bit_or(expression) + smallint, int, bigint, or + bit + same as argument data type + the bitwise OR of all non-null input values, or null if none
+ bool_and(expression) + bool + bool + true if all input values are true, otherwise false
+ bool_or(expression) + bool + bool + true if at least one input value is true, otherwise false
+ count(*) +  bigintnumber of input rows
count(expression)anybigint number of input rows for which the value of expression is not null +
+ every(expression) + bool + bool + equivalent to bool_and
+ max(expression) + any array, numeric, string, or date/time typesame as argument type maximum value of expression across all input + values +
+ min(expression) + any array, numeric, string, or date/time typesame as argument type minimum value of expression across all input + values +
+ string_agg(expression, + delimiter) + + (text, text) or (bytea, bytea) + same as argument types + input values concatenated into a string, separated by delimiter
+ sum(expression) + smallint, int, + bigint, real, double + precision, numeric, or + interval + bigint for smallint or + int arguments, numeric for + bigint arguments, double precision + for floating-point arguments, otherwise the same as the + argument data type + sum of expression across all input values
+ xmlagg(expression) + xml + xml + concatenation of XML values (see also Section 9.14.1.7)

It should be noted that except for count, + these functions return a null value when no rows are selected. In + particular, sum of no rows returns null, not + zero as one might expect, and array_agg + returns null rather than an empty array when there are no input + rows. The coalesce function can be used to + substitute zero or an empty array for null when necessary. +

Note: Boolean aggregates bool_and and + bool_or correspond to standard SQL aggregates + every and any or + some. + As for any and some, + it seems that there is an ambiguity built into the standard syntax: +

SELECT b1 = ANY((SELECT b2 FROM t2 ...)) FROM t1 ...;

+ Here ANY can be considered either as introducing + a subquery, or as being an aggregate function, if the subquery + returns one row with a Boolean value. + Thus the standard name cannot be given to these aggregates. +

Note: Users accustomed to working with other SQL database management + systems might be disappointed by the performance of the + count aggregate when it is applied to the + entire table. A query like: +

SELECT count(*) FROM sometable;

+ will require effort proportional to the size of the table: + PostgreSQL will need to scan either the + entire table or the entirety of an index which includes all rows in + the table. +

The aggregate functions array_agg, + string_agg, + and xmlagg, as well as similar user-defined + aggregate functions, produce meaningfully different result values + depending on the order of the input values. This ordering is + unspecified by default, but can be controlled by writing an + ORDER BY clause within the aggregate call, as shown in + Section 4.2.7. + Alternatively, supplying the input values from a sorted subquery + will usually work. For example: + +

SELECT xmlagg(x) FROM (SELECT x FROM test ORDER BY y DESC) AS tab;

+ + But this syntax is not allowed in the SQL standard, and is + not portable to other database systems. +

Table 9-46 shows + aggregate functions typically used in statistical analysis. + (These are separated out merely to avoid cluttering the listing + of more-commonly-used aggregates.) Where the description mentions + N, it means the + number of input rows for which all the input expressions are non-null. + In all cases, null is returned if the computation is meaningless, + for example when N is zero. +

Table 9-46. Aggregate Functions for Statistics

FunctionArgument TypeReturn TypeDescription
+ + corr(Y, X) + double precision + double precision + correlation coefficient
+ + covar_pop(Y, X) + double precision + double precision + population covariance
+ + covar_samp(Y, X) + double precision + double precision + sample covariance
+ regr_avgx(Y, X) + double precision + double precision + average of the independent variable + (sum(X)/N)
+ regr_avgy(Y, X) + double precision + double precision + average of the dependent variable + (sum(Y)/N)
+ regr_count(Y, X) + double precision + bigint + number of input rows in which both expressions are nonnull
+ + regr_intercept(Y, X) + double precision + double precision + y-intercept of the least-squares-fit linear equation + determined by the (X, Y) pairs
+ regr_r2(Y, X) + double precision + double precision + square of the correlation coefficient
+ + regr_slope(Y, X) + double precision + double precision + slope of the least-squares-fit linear equation determined + by the (X, + Y) pairs
+ regr_sxx(Y, X) + double precision + double precision + sum(X^2) - sum(X)^2/N ("sum of + squares" of the independent variable)
+ regr_sxy(Y, X) + double precision + double precision + sum(X*Y) - sum(X) * sum(Y)/N ("sum of + products" of independent times dependent + variable)
+ regr_syy(Y, X) + double precision + double precision + sum(Y^2) - sum(Y)^2/N ("sum of + squares" of the dependent variable)
+ + stddev(expression) + smallint, int, + bigint, real, double + precision, or numeric + double precision for floating-point arguments, + otherwise numeric + historical alias for stddev_samp
+ + stddev_pop(expression) + smallint, int, + bigint, real, double + precision, or numeric + double precision for floating-point arguments, + otherwise numeric + population standard deviation of the input values
+ + stddev_samp(expression) + smallint, int, + bigint, real, double + precision, or numeric + double precision for floating-point arguments, + otherwise numeric + sample standard deviation of the input values
+ variance(expression) + smallint, int, + bigint, real, double + precision, or numeric + double precision for floating-point arguments, + otherwise numeric + historical alias for var_samp
+ + var_pop(expression) + smallint, int, + bigint, real, double + precision, or numeric + double precision for floating-point arguments, + otherwise numeric + population variance of the input values (square of the population standard deviation)
+ + var_samp(expression) + smallint, int, + bigint, real, double + precision, or numeric + double precision for floating-point arguments, + otherwise numeric + sample variance of the input values (square of the sample standard deviation)

PrevHomeNext
Range Functions and OperatorsUpWindow Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-array.html b/doc/src/sgml/html/functions-array.html new file mode 100644 index 000000000..ab9d3e11a --- /dev/null +++ b/doc/src/sgml/html/functions-array.html @@ -0,0 +1,998 @@ + +Array Functions and Operators
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.18. Array Functions and Operators

Table 9-41 shows the operators + available for array types. +

Table 9-41. Array Operators

OperatorDescriptionExampleResult
= equalARRAY[1.1,2.1,3.1]::int[] = ARRAY[1,2,3]t
<> not equalARRAY[1,2,3] <> ARRAY[1,2,4]t
< less thanARRAY[1,2,3] < ARRAY[1,2,4]t
> greater thanARRAY[1,4,3] > ARRAY[1,2,4]t
<= less than or equalARRAY[1,2,3] <= ARRAY[1,2,3]t
>= greater than or equalARRAY[1,4,3] >= ARRAY[1,4,3]t
@> containsARRAY[1,4,3] @> ARRAY[3,1]t
<@ is contained byARRAY[2,7] <@ ARRAY[1,7,4,2,6]t
&& overlap (have elements in common)ARRAY[1,4,3] && ARRAY[2,1]t
|| array-to-array concatenationARRAY[1,2,3] || ARRAY[4,5,6]{1,2,3,4,5,6}
|| array-to-array concatenationARRAY[1,2,3] || ARRAY[[4,5,6],[7,8,9]]{{1,2,3},{4,5,6},{7,8,9}}
|| element-to-array concatenation3 || ARRAY[4,5,6]{3,4,5,6}
|| array-to-element concatenationARRAY[4,5,6] || 7{4,5,6,7}

Array comparisons compare the array contents element-by-element, + using the default B-tree comparison function for the element data type. + In multidimensional arrays the elements are visited in row-major order + (last subscript varies most rapidly). + If the contents of two arrays are equal but the dimensionality is + different, the first difference in the dimensionality information + determines the sort order. (This is a change from versions of + PostgreSQL prior to 8.2: older versions would claim + that two arrays with the same contents were equal, even if the + number of dimensions or subscript ranges were different.) +

See Section 8.15 for more details about array operator + behavior. +

Table 9-42 shows the functions + available for use with array types. See Section 8.15 + for more information and examples of the use of these functions. +

Table 9-42. Array Functions

FunctionReturn TypeDescriptionExampleResult
array_append(anyarray, anyelement) + + anyarrayappend an element to the end of an arrayarray_append(ARRAY[1,2], 3){1,2,3}
array_cat(anyarray, anyarray) + + anyarrayconcatenate two arraysarray_cat(ARRAY[1,2,3], ARRAY[4,5]){1,2,3,4,5}
array_ndims(anyarray) + + intreturns the number of dimensions of the arrayarray_ndims(ARRAY[[1,2,3], [4,5,6]])2
array_dims(anyarray) + + textreturns a text representation of array's dimensionsarray_dims(ARRAY[[1,2,3], [4,5,6]])[1:2][1:3]
array_fill(anyelement, int[], + [, int[]]) + + anyarrayreturns an array initialized with supplied value and + dimensions, optionally with lower bounds other than 1array_fill(7, ARRAY[3], ARRAY[2])[2:4]={7,7,7}
array_length(anyarray, int) + + intreturns the length of the requested array dimensionarray_length(array[1,2,3], 1)3
array_lower(anyarray, int) + + intreturns lower bound of the requested array dimensionarray_lower('[0:2]={1,2,3}'::int[], 1)0
array_prepend(anyelement, anyarray) + + anyarrayappend an element to the beginning of an arrayarray_prepend(1, ARRAY[2,3]){1,2,3}
array_to_string(anyarray, text [, text]) + + textconcatenates array elements using supplied delimiter and + optional null stringarray_to_string(ARRAY[1, 2, 3, NULL, 5], ',', '*')1,2,3,*,5
array_upper(anyarray, int) + + intreturns upper bound of the requested array dimensionarray_upper(ARRAY[1,8,3,7], 1)4
string_to_array(text, text [, text]) + + text[]splits string into array elements using supplied delimiter and + optional null stringstring_to_array('xx~^~yy~^~zz', '~^~', 'yy'){xx,NULL,zz}
unnest(anyarray) + + setof anyelementexpand an array to a set of rowsunnest(ARRAY[1,2])
1
+2
(2 rows)

In string_to_array, if the delimiter parameter is + NULL, each character in the input string will become a separate element in + the resulting array. If the delimiter is an empty string, then the entire + input string is returned as a one-element array. Otherwise the input + string is split at each occurrence of the delimiter string. +

In string_to_array, if the null-string parameter + is omitted or NULL, none of the substrings of the input will be replaced + by NULL. + In array_to_string, if the null-string parameter + is omitted or NULL, any null elements in the array are simply skipped + and not represented in the output string. +

Note: There are two differences in the behavior of string_to_array + from pre-9.1 versions of PostgreSQL. + First, it will return an empty (zero-element) array rather than NULL when + the input string is of zero length. Second, if the delimiter string is + NULL, the function splits the input into individual characters, rather + than returning NULL as before. +

See also Section 9.20 about the aggregate + function array_agg for use with arrays. +


PrevHomeNext
Conditional ExpressionsUpRange Functions and Operators
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-binarystring.html b/doc/src/sgml/html/functions-binarystring.html new file mode 100644 index 000000000..8257b3c2e --- /dev/null +++ b/doc/src/sgml/html/functions-binarystring.html @@ -0,0 +1,946 @@ + +Binary String Functions and Operators
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.5. Binary String Functions and Operators

This section describes functions and operators for examining and + manipulating values of type bytea. +

SQL defines some string functions that use + key words, rather than commas, to separate + arguments. Details are in + Table 9-8. + PostgreSQL also provides versions of these functions + that use the regular function invocation syntax + (see Table 9-9). +

Note: The sample results shown on this page assume that the server parameter + bytea_output is set + to escape (the traditional PostgreSQL format). +

Table 9-8. SQL Binary String Functions and Operators

FunctionReturn TypeDescriptionExampleResult
string || + string bytea String concatenation + + E'\\\\Post'::bytea || E'\\047gres\\000'::bytea\\Post'gres\000
+ octet_length(string) + intNumber of bytes in binary stringoctet_length(E'jo\\000se'::bytea)5
+ overlay(string placing string from int [for int]) + bytea Replace substring + overlay(E'Th\\000omas'::bytea placing E'\\002\\003'::bytea from 2 for 3)T\\002\\003mas
+ position(substring in string) + intLocation of specified substringposition(E'\\000om'::bytea in E'Th\\000omas'::bytea)3
+ substring(string [from int] [for int]) + bytea Extract substring + substring(E'Th\\000omas'::bytea from 2 for 3)h\000o
+ trim([both] + bytes from + string) + bytea Remove the longest string containing only the bytes in + bytes from the start + and end of string + trim(E'\\000'::bytea from E'\\000Tom\\000'::bytea)Tom

Additional binary string manipulation functions are available and + are listed in Table 9-9. Some + of them are used internally to implement the + SQL-standard string functions listed in Table 9-8. +

Table 9-9. Other Binary String Functions

FunctionReturn TypeDescriptionExampleResult
+ btrim(string + bytea, bytes bytea) + bytea Remove the longest string consisting only of bytes + in bytes from the start and end of + string + btrim(E'\\000trim\\000'::bytea, E'\\000'::bytea)trim
+ decode(string text, + type text) + bytea Decode binary string from string previously + encoded with encode. Parameter type is same as in encode. + decode(E'123\\000456', 'escape')123\000456
+ encode(string bytea, + type text) + text Encode binary string to ASCII-only representation. Supported + types are: base64, hex, escape. + encode(E'123\\000456'::bytea, 'escape')123\000456
+ get_bit(string, offset) + int Extract bit from string + get_bit(E'Th\\000omas'::bytea, 45)1
+ get_byte(string, offset) + int Extract byte from string + get_byte(E'Th\\000omas'::bytea, 4)109
+ length(string) + int Length of binary string + + + length(E'jo\\000se'::bytea)5
+ md5(string) + text Calculates the MD5 hash of string, + returning the result in hexadecimal + md5(E'Th\\000omas'::bytea)8ab2d3c9689aaf18 b4958c334c82d8b1
+ set_bit(string, + offset, newvalue) + bytea Set bit in string + set_bit(E'Th\\000omas'::bytea, 45, 0)Th\000omAs
+ set_byte(string, + offset, newvalue) + bytea Set byte in string + set_byte(E'Th\\000omas'::bytea, 4, 64)Th\000o@as

get_byte and set_byte number the first byte + of a binary string as byte 0. + get_bit and set_bit number bits from the + right within each byte; for example bit 0 is the least significant bit of + the first byte, and bit 15 is the most significant bit of the second byte. +

See also the aggregate function string_agg in + Section 9.20. +


PrevHomeNext
String Functions and OperatorsUpBit String Functions and Operators
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-bitstring.html b/doc/src/sgml/html/functions-bitstring.html new file mode 100644 index 000000000..4f1f539b4 --- /dev/null +++ b/doc/src/sgml/html/functions-bitstring.html @@ -0,0 +1,485 @@ + +Bit String Functions and Operators
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.6. Bit String Functions and Operators

This section describes functions and operators for examining and + manipulating bit strings, that is values of the types + bit and bit varying. Aside from the + usual comparison operators, the operators + shown in Table 9-10 can be used. + Bit string operands of &, |, + and # must be of equal length. When bit + shifting, the original length of the string is preserved, as shown + in the examples. +

Table 9-10. Bit String Operators

OperatorDescriptionExampleResult
|| concatenationB'10001' || B'011'10001011
& bitwise ANDB'10001' & B'01101'00001
| bitwise ORB'10001' | B'01101'11101
# bitwise XORB'10001' # B'01101'11100
~ bitwise NOT~ B'10001'01110
<< bitwise shift leftB'10001' << 301000
>> bitwise shift rightB'10001' >> 200100

The following SQL-standard functions work on bit + strings as well as character strings: + length, + bit_length, + octet_length, + position, + substring, + overlay. +

The following functions work on bit strings as well as binary + strings: + get_bit, + set_bit. + When working with a bit string, these functions number the first + (leftmost) bit of the string as bit 0. +

In addition, it is possible to cast integral values to and from type + bit. + Some examples: +

44::bit(10)                    0000101100
+44::bit(3)                     100
+cast(-44 as bit(12))           111111010100
+'1110'::bit(4)::integer        14

+ Note that casting to just "bit" means casting to + bit(1), and so will deliver only the least significant + bit of the integer. +

Note: Prior to PostgreSQL 8.0, casting an + integer to bit(n) would copy the leftmost n + bits of the integer, whereas now it copies the rightmost n + bits. Also, casting an integer to a bit string width wider than + the integer itself will sign-extend on the left. +


PrevHomeNext
Binary String Functions and OperatorsUpPattern Matching
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-comparison.html b/doc/src/sgml/html/functions-comparison.html new file mode 100644 index 000000000..49a4092b8 --- /dev/null +++ b/doc/src/sgml/html/functions-comparison.html @@ -0,0 +1,714 @@ + +Comparison Operators
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.2. Comparison Operators

The usual comparison operators are available, shown in Table 9-1. +

Table 9-1. Comparison Operators

OperatorDescription
< less than
> greater than
<= less than or equal to
>= greater than or equal to
= equal
<> or != not equal

Note: The != operator is converted to + <> in the parser stage. It is not + possible to implement != and + <> operators that do different things. +

Comparison operators are available for all relevant data types. + All comparison operators are binary operators that + return values of type boolean; expressions like + 1 < 2 < 3 are not valid (because there is + no < operator to compare a Boolean value with + 3). +

+ In addition to the comparison operators, the special + BETWEEN construct is available: +

a BETWEEN x AND y

+ is equivalent to +

a >= x AND a <= y

+ Notice that BETWEEN treats the endpoint values as included + in the range. + NOT BETWEEN does the opposite comparison: +

a NOT BETWEEN x AND y

+ is equivalent to +

a < x OR a > y

+ + BETWEEN SYMMETRIC is the same as BETWEEN + except there is no requirement that the argument to the left of + AND be less than or equal to the argument on the right. + If it is not, those two arguments are automatically swapped, so that + a nonempty range is always implied. +

+ + + + To check whether a value is or is not null, use the constructs: +

expression IS NULL
+expression IS NOT NULL

+ or the equivalent, but nonstandard, constructs: +

expression ISNULL
+expression NOTNULL

+ +

Do not write + expression = NULL + because NULL is not "equal to" + NULL. (The null value represents an unknown value, + and it is not known whether two unknown values are equal.) This + behavior conforms to the SQL standard. +

Tip: Some applications might expect that + expression = NULL + returns true if expression evaluates to + the null value. It is highly recommended that these applications + be modified to comply with the SQL standard. However, if that + cannot be done the transform_null_equals + configuration variable is available. If it is enabled, + PostgreSQL will convert x = + NULL clauses to x IS NULL. +

Note: If the expression is row-valued, then + IS NULL is true when the row expression itself is null + or when all the row's fields are null, while + IS NOT NULL is true when the row expression itself is non-null + and all the row's fields are non-null. Because of this behavior, + IS NULL and IS NOT NULL do not always return + inverse results for row-valued expressions, i.e., a row-valued + expression that contains both NULL and non-null values will return false + for both tests. + This definition conforms to the SQL standard, and is a change from the + inconsistent behavior exhibited by PostgreSQL + versions prior to 8.2. +

+ + Ordinary comparison operators yield null (signifying "unknown"), + not true or false, when either input is null. For example, + 7 = NULL yields null, as does 7 <> NULL. When + this behavior is not suitable, use the + IS [ NOT ] DISTINCT FROM constructs: +

expression IS DISTINCT FROM expression
+expression IS NOT DISTINCT FROM expression

+ For non-null inputs, IS DISTINCT FROM is + the same as the <> operator. However, if both + inputs are null it returns false, and if only one input is + null it returns true. Similarly, IS NOT DISTINCT + FROM is identical to = for non-null + inputs, but it returns true when both inputs are null, and false when only + one input is null. Thus, these constructs effectively act as though null + were a normal data value, rather than "unknown". +

+ + + + + + Boolean values can also be tested using the constructs +

expression IS TRUE
+expression IS NOT TRUE
+expression IS FALSE
+expression IS NOT FALSE
+expression IS UNKNOWN
+expression IS NOT UNKNOWN

+ These will always return true or false, never a null value, even when the + operand is null. + A null input is treated as the logical value "unknown". + Notice that IS UNKNOWN and IS NOT UNKNOWN are + effectively the same as IS NULL and + IS NOT NULL, respectively, except that the input + expression must be of Boolean type. +


PrevHomeNext
Logical OperatorsUpMathematical Functions and Operators
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-comparisons.html b/doc/src/sgml/html/functions-comparisons.html new file mode 100644 index 000000000..9c9e820a8 --- /dev/null +++ b/doc/src/sgml/html/functions-comparisons.html @@ -0,0 +1,762 @@ + +Row and Array Comparisons
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.23. Row and Array Comparisons

This section describes several specialized constructs for making + multiple comparisons between groups of values. These forms are + syntactically related to the subquery forms of the previous section, + but do not involve subqueries. + The forms involving array subexpressions are + PostgreSQL extensions; the rest are + SQL-compliant. + All of the expression forms documented in this section return + Boolean (true/false) results. +

9.23.1. IN

expression IN (value [, ...])

The right-hand side is a parenthesized list + of scalar expressions. The result is "true" if the left-hand expression's + result is equal to any of the right-hand expressions. This is a shorthand + notation for + +

expression = value1
+OR
+expression = value2
+OR
+...

+

Note that if the left-hand expression yields null, or if there are + no equal right-hand values and at least one right-hand expression yields + null, the result of the IN construct will be null, not false. + This is in accordance with SQL's normal rules for Boolean combinations + of null values. +

9.23.2. NOT IN

expression NOT IN (value [, ...])

The right-hand side is a parenthesized list + of scalar expressions. The result is "true" if the left-hand expression's + result is unequal to all of the right-hand expressions. This is a shorthand + notation for + +

expression <> value1
+AND
+expression <> value2
+AND
+...

+

Note that if the left-hand expression yields null, or if there are + no equal right-hand values and at least one right-hand expression yields + null, the result of the NOT IN construct will be null, not true + as one might naively expect. + This is in accordance with SQL's normal rules for Boolean combinations + of null values. +

Tip: x NOT IN y is equivalent to NOT (x IN y) in all + cases. However, null values are much more likely to trip up the novice when + working with NOT IN than when working with IN. + It is best to express your condition positively if possible. +

9.23.3. ANY/SOME (array)

expression operator ANY (array expression)
+expression operator SOME (array expression)

The right-hand side is a parenthesized expression, which must yield an + array value. + The left-hand expression + is evaluated and compared to each element of the array using the + given operator, which must yield a Boolean + result. + The result of ANY is "true" if any true result is obtained. + The result is "false" if no true result is found (including the + case where the array has zero elements). +

If the array expression yields a null array, the result of + ANY will be null. If the left-hand expression yields null, + the result of ANY is ordinarily null (though a non-strict + comparison operator could possibly yield a different result). + Also, if the right-hand array contains any null elements and no true + comparison result is obtained, the result of ANY + will be null, not false (again, assuming a strict comparison operator). + This is in accordance with SQL's normal rules for Boolean combinations + of null values. +

SOME is a synonym for ANY. +

9.23.4. ALL (array)

expression operator ALL (array expression)

The right-hand side is a parenthesized expression, which must yield an + array value. + The left-hand expression + is evaluated and compared to each element of the array using the + given operator, which must yield a Boolean + result. + The result of ALL is "true" if all comparisons yield true + (including the case where the array has zero elements). + The result is "false" if any false result is found. +

If the array expression yields a null array, the result of + ALL will be null. If the left-hand expression yields null, + the result of ALL is ordinarily null (though a non-strict + comparison operator could possibly yield a different result). + Also, if the right-hand array contains any null elements and no false + comparison result is obtained, the result of ALL + will be null, not true (again, assuming a strict comparison operator). + This is in accordance with SQL's normal rules for Boolean combinations + of null values. +

9.23.5. Row-wise Comparison

row_constructor operator row_constructor

Each side is a row constructor, + as described in Section 4.2.13. + The two row values must have the same number of fields. + Each side is evaluated and they are compared row-wise. Row comparisons + are allowed when the operator is + =, + <>, + <, + <=, + > or + >=, + or has semantics similar to one of these. (To be specific, an operator + can be a row comparison operator if it is a member of a B-tree operator + class, or is the negator of the = member of a B-tree operator + class.) +

The = and <> cases work slightly differently + from the others. Two rows are considered + equal if all their corresponding members are non-null and equal; the rows + are unequal if any corresponding members are non-null and unequal; + otherwise the result of the row comparison is unknown (null). +

For the <, <=, > and + >= cases, the row elements are compared left-to-right, + stopping as soon as an unequal or null pair of elements is found. + If either of this pair of elements is null, the result of the + row comparison is unknown (null); otherwise comparison of this pair + of elements determines the result. For example, + ROW(1,2,NULL) < ROW(1,3,0) + yields true, not null, because the third pair of elements are not + considered. +

Note: Prior to PostgreSQL 8.2, the + <, <=, > and >= + cases were not handled per SQL specification. A comparison like + ROW(a,b) < ROW(c,d) + was implemented as + a < c AND b < d + whereas the correct behavior is equivalent to + a < c OR (a = c AND b < d). +

row_constructor IS DISTINCT FROM row_constructor

This construct is similar to a <> row comparison, + but it does not yield null for null inputs. Instead, any null value is + considered unequal to (distinct from) any non-null value, and any two + nulls are considered equal (not distinct). Thus the result will + either be true or false, never null. +

row_constructor IS NOT DISTINCT FROM row_constructor

This construct is similar to a = row comparison, + but it does not yield null for null inputs. Instead, any null value is + considered unequal to (distinct from) any non-null value, and any two + nulls are considered equal (not distinct). Thus the result will always + be either true or false, never null. +

Note: The SQL specification requires row-wise comparison to return NULL if the + result depends on comparing two NULL values or a NULL and a non-NULL. + PostgreSQL does this only when comparing the + results of two row constructors or comparing a row constructor to the + output of a subquery (as in Section 9.22). + In other contexts where two composite-type values are compared, two + NULL field values are considered equal, and a NULL is considered larger + than a non-NULL. This is necessary in order to have consistent sorting + and indexing behavior for composite types. +


PrevHomeNext
Subquery ExpressionsUpSet Returning Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-conditional.html b/doc/src/sgml/html/functions-conditional.html new file mode 100644 index 000000000..92a33cc8a --- /dev/null +++ b/doc/src/sgml/html/functions-conditional.html @@ -0,0 +1,666 @@ + +Conditional Expressions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.17. Conditional Expressions

This section describes the SQL-compliant conditional expressions + available in PostgreSQL. +

Tip: If your needs go beyond the capabilities of these conditional + expressions, you might want to consider writing a stored procedure + in a more expressive programming language. +

9.17.1. CASE

The SQL CASE expression is a + generic conditional expression, similar to if/else statements in + other programming languages: + +

CASE WHEN condition THEN result
+     [WHEN ...]
+     [ELSE result]
+END

+ + CASE clauses can be used wherever + an expression is valid. Each condition is an + expression that returns a boolean result. If the condition's + result is true, the value of the CASE expression is the + result that follows the condition, and the + remainder of the CASE expression is not processed. If the + condition's result is not true, any subsequent WHEN clauses + are examined in the same manner. If no WHEN + condition yields true, the value of the + CASE expression is the result of the + ELSE clause. If the ELSE clause is + omitted and no condition is true, the result is null. +

An example: +

SELECT * FROM test;
+
+ a
+---
+ 1
+ 2
+ 3
+
+
+SELECT a,
+       CASE WHEN a=1 THEN 'one'
+            WHEN a=2 THEN 'two'
+            ELSE 'other'
+       END
+    FROM test;
+
+ a | case
+---+-------
+ 1 | one
+ 2 | two
+ 3 | other

+

The data types of all the result + expressions must be convertible to a single output type. + See Section 10.5 for more details. +

There is a "simple" form of CASE expression + that is a variant of the general form above: + +

CASE expression
+    WHEN value THEN result
+    [WHEN ...]
+    [ELSE result]
+END

+ + The first + expression is computed, then compared to + each of the value expressions in the + WHEN clauses until one is found that is equal to it. If + no match is found, the result of the + ELSE clause (or a null value) is returned. This is similar + to the switch statement in C. +

The example above can be written using the simple + CASE syntax: +

SELECT a,
+       CASE a WHEN 1 THEN 'one'
+              WHEN 2 THEN 'two'
+              ELSE 'other'
+       END
+    FROM test;
+
+ a | case
+---+-------
+ 1 | one
+ 2 | two
+ 3 | other

+

A CASE expression does not evaluate any subexpressions + that are not needed to determine the result. For example, this is a + possible way of avoiding a division-by-zero failure: +

SELECT ... WHERE CASE WHEN x <> 0 THEN y/x > 1.5 ELSE false END;

+

9.17.2. COALESCE

COALESCE(value [, ...])

The COALESCE function returns the first of its + arguments that is not null. Null is returned only if all arguments + are null. It is often used to substitute a default value for + null values when data is retrieved for display, for example: +

SELECT COALESCE(description, short_description, '(none)') ...

+ This returns description if it is not null, otherwise + short_description if it is not null, otherwise (none). +

Like a CASE expression, COALESCE only + evaluates the arguments that are needed to determine the result; + that is, arguments to the right of the first non-null argument are + not evaluated. This SQL-standard function provides capabilities similar + to NVL and IFNULL, which are used in some other + database systems. +

9.17.3. NULLIF

NULLIF(value1, value2)

The NULLIF function returns a null value if + value1 equals value2; + otherwise it returns value1. + This can be used to perform the inverse operation of the + COALESCE example given above: +

SELECT NULLIF(value, '(none)') ...

+

In this example, if value is (none), + null is returned, otherwise the value of value + is returned. +

9.17.4. GREATEST and LEAST

GREATEST(value [, ...])
LEAST(value [, ...])

The GREATEST and LEAST functions select the + largest or smallest value from a list of any number of expressions. + The expressions must all be convertible to a common data type, which + will be the type of the result + (see Section 10.5 for details). NULL values + in the list are ignored. The result will be NULL only if all the + expressions evaluate to NULL. +

Note that GREATEST and LEAST are not in + the SQL standard, but are a common extension. Some other databases + make them return NULL if any argument is NULL, rather than only when + all are NULL. +


PrevHomeNext
Sequence Manipulation FunctionsUpArray Functions and Operators
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-datetime.html b/doc/src/sgml/html/functions-datetime.html new file mode 100644 index 000000000..21ca2436e --- /dev/null +++ b/doc/src/sgml/html/functions-datetime.html @@ -0,0 +1,3217 @@ + +Date/Time Functions and Operators
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.9. Date/Time Functions and Operators

Table 9-27 shows the available + functions for date/time value processing, with details appearing in + the following subsections. Table 9-26 illustrates the behaviors of + the basic arithmetic operators (+, + *, etc.). For formatting functions, refer to + Section 9.8. You should be familiar with + the background information on date/time data types from Section 8.5. +

All the functions and operators described below that take time or timestamp + inputs actually come in two variants: one that takes time with time zone or timestamp + with time zone, and one that takes time without time zone or timestamp without time zone. + For brevity, these variants are not shown separately. Also, the + + and * operators come in commutative pairs (for + example both date + integer and integer + date); we show only one of each + such pair. +

Table 9-26. Date/Time Operators

OperatorExampleResult
+ date '2001-09-28' + integer '7'date '2001-10-05'
+ date '2001-09-28' + interval '1 hour'timestamp '2001-09-28 01:00:00'
+ date '2001-09-28' + time '03:00'timestamp '2001-09-28 03:00:00'
+ interval '1 day' + interval '1 hour'interval '1 day 01:00:00'
+ timestamp '2001-09-28 01:00' + interval '23 hours'timestamp '2001-09-29 00:00:00'
+ time '01:00' + interval '3 hours'time '04:00:00'
- - interval '23 hours'interval '-23:00:00'
- date '2001-10-01' - date '2001-09-28'integer '3' (days)
- date '2001-10-01' - integer '7'date '2001-09-24'
- date '2001-09-28' - interval '1 hour'timestamp '2001-09-27 23:00:00'
- time '05:00' - time '03:00'interval '02:00:00'
- time '05:00' - interval '2 hours'time '03:00:00'
- timestamp '2001-09-28 23:00' - interval '23 hours'timestamp '2001-09-28 00:00:00'
- interval '1 day' - interval '1 hour'interval '1 day -01:00:00'
- timestamp '2001-09-29 03:00' - timestamp '2001-09-27 12:00'interval '1 day 15:00:00'
* 900 * interval '1 second'interval '00:15:00'
* 21 * interval '1 day'interval '21 days'
* double precision '3.5' * interval '1 hour'interval '03:30:00'
/ interval '1 hour' / double precision '1.5'interval '00:40:00'

Table 9-27. Date/Time Functions

FunctionReturn TypeDescriptionExampleResult
+ age(timestamp, timestamp) + intervalSubtract arguments, producing a "symbolic" result that + uses years and monthsage(timestamp '2001-04-10', timestamp '1957-06-13')43 years 9 mons 27 days
age(timestamp)intervalSubtract from current_date (at midnight)age(timestamp '1957-06-13')43 years 8 mons 3 days
+ clock_timestamp() + timestamp with time zoneCurrent date and time (changes during statement execution); + see Section 9.9.4 +   
+ current_date + dateCurrent date; + see Section 9.9.4 +   
+ current_time + time with time zoneCurrent time of day; + see Section 9.9.4 +   
+ current_timestamp + timestamp with time zoneCurrent date and time (start of current transaction); + see Section 9.9.4 +   
+ date_part(text, timestamp) + double precisionGet subfield (equivalent to extract); + see Section 9.9.1 + date_part('hour', timestamp '2001-02-16 20:38:40')20
date_part(text, interval)double precisionGet subfield (equivalent to + extract); see Section 9.9.1 + date_part('month', interval '2 years 3 months')3
+ date_trunc(text, timestamp) + timestampTruncate to specified precision; see also Section 9.9.2 + date_trunc('hour', timestamp '2001-02-16 20:38:40')2001-02-16 20:00:00
+ extract(field from + timestamp) + double precisionGet subfield; see Section 9.9.1 + extract(hour from timestamp '2001-02-16 20:38:40')20
extract(field from + interval)double precisionGet subfield; see Section 9.9.1 + extract(month from interval '2 years 3 months')3
+ isfinite(date) + booleanTest for finite date (not +/-infinity)isfinite(date '2001-02-16')true
isfinite(timestamp)booleanTest for finite time stamp (not +/-infinity)isfinite(timestamp '2001-02-16 21:28:30')true
isfinite(interval)booleanTest for finite intervalisfinite(interval '4 hours')true
+ justify_days(interval) + intervalAdjust interval so 30-day time periods are represented as monthsjustify_days(interval '35 days')1 mon 5 days
+ justify_hours(interval) + intervalAdjust interval so 24-hour time periods are represented as daysjustify_hours(interval '27 hours')1 day 03:00:00
+ justify_interval(interval) + intervalAdjust interval using justify_days and justify_hours, with additional sign adjustmentsjustify_interval(interval '1 mon -1 hour')29 days 23:00:00
+ localtime + timeCurrent time of day; + see Section 9.9.4 +   
+ localtimestamp + timestampCurrent date and time (start of current transaction); + see Section 9.9.4 +   
+ now() + timestamp with time zoneCurrent date and time (start of current transaction); + see Section 9.9.4 +   
+ statement_timestamp() + timestamp with time zoneCurrent date and time (start of current statement); + see Section 9.9.4 +   
+ timeofday() + textCurrent date and time + (like clock_timestamp, but as a text string); + see Section 9.9.4 +   
+ transaction_timestamp() + timestamp with time zoneCurrent date and time (start of current transaction); + see Section 9.9.4 +   

In addition to these functions, the SQL OVERLAPS operator is + supported: +

(start1, end1) OVERLAPS (start2, end2)
+(start1, length1) OVERLAPS (start2, length2)

+ This expression yields true when two time periods (defined by their + endpoints) overlap, false when they do not overlap. The endpoints + can be specified as pairs of dates, times, or time stamps; or as + a date, time, or time stamp followed by an interval. When a pair + of values is provided, either the start or the end can be written + first; OVERLAPS automatically takes the earlier value + of the pair as the start. Each time period is considered to + represent the half-open interval start <= + time < end, unless + start and end are equal in which case it + represents that single time instant. This means for instance that two + time periods with only an endpoint in common do not overlap. +

SELECT (DATE '2001-02-16', DATE '2001-12-21') OVERLAPS
+       (DATE '2001-10-30', DATE '2002-10-30');
+Result: true
+SELECT (DATE '2001-02-16', INTERVAL '100 days') OVERLAPS
+       (DATE '2001-10-30', DATE '2002-10-30');
+Result: false
+SELECT (DATE '2001-10-29', DATE '2001-10-30') OVERLAPS
+       (DATE '2001-10-30', DATE '2001-10-31');
+Result: false
+SELECT (DATE '2001-10-30', DATE '2001-10-30') OVERLAPS
+       (DATE '2001-10-30', DATE '2001-10-31');
+Result: true

When adding an interval value to (or subtracting an + interval value from) a timestamp with time zone + value, the days component advances (or decrements) the date of the + timestamp with time zone by the indicated number of days. + Across daylight saving time changes (with the session time zone set to a + time zone that recognizes DST), this means interval '1 day' + does not necessarily equal interval '24 hours'. + For example, with the session time zone set to CST7CDT, + timestamp with time zone '2005-04-02 12:00-07' + interval '1 day' + will produce timestamp with time zone '2005-04-03 12:00-06', + while adding interval '24 hours' to the same initial + timestamp with time zone produces + timestamp with time zone '2005-04-03 13:00-06', as there is + a change in daylight saving time at 2005-04-03 02:00 in time zone + CST7CDT. +

Note there can be ambiguity in the months returned by + age because different months have a different number of + days. PostgreSQL's approach uses the month from the + earlier of the two dates when calculating partial months. For example, + age('2004-06-01', '2004-04-30') uses April to yield + 1 mon 1 day, while using May would yield 1 mon 2 + days because May has 31 days, while April has only 30. +

9.9.1. EXTRACT, date_part

EXTRACT(field FROM source)

The extract function retrieves subfields + such as year or hour from date/time values. + source must be a value expression of + type timestamp, time, or interval. + (Expressions of type date are + cast to timestamp and can therefore be used as + well.) field is an identifier or + string that selects what field to extract from the source value. + The extract function returns values of type + double precision. + The following are valid field names: + + +

century

The century +

SELECT EXTRACT(CENTURY FROM TIMESTAMP '2000-12-16 12:21:13');
+Result: 20
+SELECT EXTRACT(CENTURY FROM TIMESTAMP '2001-02-16 20:38:40');
+Result: 21

The first century starts at 0001-01-01 00:00:00 AD, although + they did not know it at the time. This definition applies to all + Gregorian calendar countries. There is no century number 0, + you go from -1 century to 1 century. + + If you disagree with this, please write your complaint to: + Pope, Cathedral Saint-Peter of Roma, Vatican. +

PostgreSQL releases before 8.0 did not + follow the conventional numbering of centuries, but just returned + the year field divided by 100. +

day

For timestamp values, the day (of the month) field + (1 - 31) ; for interval values, the number of days +

SELECT EXTRACT(DAY FROM TIMESTAMP '2001-02-16 20:38:40');
+Result: 16
+
+SELECT EXTRACT(DAY FROM INTERVAL '40 days 1 minute');
+Result: 40
decade

The year field divided by 10 +

SELECT EXTRACT(DECADE FROM TIMESTAMP '2001-02-16 20:38:40');
+Result: 200
dow

The day of the week as Sunday(0) to + Saturday(6) +

SELECT EXTRACT(DOW FROM TIMESTAMP '2001-02-16 20:38:40');
+Result: 5

Note that extract's day of the week numbering + differs from that of the to_char(..., + 'D') function. +

doy

The day of the year (1 - 365/366) +

SELECT EXTRACT(DOY FROM TIMESTAMP '2001-02-16 20:38:40');
+Result: 47
epoch

For timestamp with time zone values, the + number of seconds since 1970-01-01 00:00:00 UTC (can be negative); + for date and timestamp values, the + number of seconds since 1970-01-01 00:00:00 local time; + for interval values, the total number + of seconds in the interval +

SELECT EXTRACT(EPOCH FROM TIMESTAMP WITH TIME ZONE '2001-02-16 20:38:40.12-08');
+Result: 982384720.12
+
+SELECT EXTRACT(EPOCH FROM INTERVAL '5 days 3 hours');
+Result: 442800

Here is how you can convert an epoch value back to a time + stamp: +

SELECT TIMESTAMP WITH TIME ZONE 'epoch' + 982384720.12 * INTERVAL '1 second';

(The to_timestamp function encapsulates the above + conversion.) +

hour

The hour field (0 - 23) +

SELECT EXTRACT(HOUR FROM TIMESTAMP '2001-02-16 20:38:40');
+Result: 20
isodow

The day of the week as Monday(1) to + Sunday(7) +

SELECT EXTRACT(ISODOW FROM TIMESTAMP '2001-02-18 20:38:40');
+Result: 7

This is identical to dow except for Sunday. This + matches the ISO 8601 day of the week numbering. +

isoyear

The ISO 8601 year that the date falls in (not applicable to intervals) +

SELECT EXTRACT(ISOYEAR FROM DATE '2006-01-01');
+Result: 2005
+SELECT EXTRACT(ISOYEAR FROM DATE '2006-01-02');
+Result: 2006

Each ISO year begins with the Monday of the week containing the 4th of January, so in early January or late December the ISO year may be different from the Gregorian year. See the week field for more information. +

This field is not available in PostgreSQL releases prior to 8.3. +

microseconds

The seconds field, including fractional parts, multiplied by 1 + 000 000; note that this includes full seconds +

SELECT EXTRACT(MICROSECONDS FROM TIME '17:12:28.5');
+Result: 28500000
millennium

The millennium +

SELECT EXTRACT(MILLENNIUM FROM TIMESTAMP '2001-02-16 20:38:40');
+Result: 3

Years in the 1900s are in the second millennium. + The third millennium started January 1, 2001. +

PostgreSQL releases before 8.0 did not + follow the conventional numbering of millennia, but just returned + the year field divided by 1000. +

milliseconds

The seconds field, including fractional parts, multiplied by + 1000. Note that this includes full seconds. +

SELECT EXTRACT(MILLISECONDS FROM TIME '17:12:28.5');
+Result: 28500
minute

The minutes field (0 - 59) +

SELECT EXTRACT(MINUTE FROM TIMESTAMP '2001-02-16 20:38:40');
+Result: 38
month

For timestamp values, the number of the month + within the year (1 - 12) ; for interval values, + the number of months, modulo 12 (0 - 11) +

SELECT EXTRACT(MONTH FROM TIMESTAMP '2001-02-16 20:38:40');
+Result: 2
+
+SELECT EXTRACT(MONTH FROM INTERVAL '2 years 3 months');
+Result: 3
+
+SELECT EXTRACT(MONTH FROM INTERVAL '2 years 13 months');
+Result: 1
quarter

The quarter of the year (1 - 4) that the date is in +

SELECT EXTRACT(QUARTER FROM TIMESTAMP '2001-02-16 20:38:40');
+Result: 1
second

The seconds field, including fractional parts (0 - + 59[1]) +

SELECT EXTRACT(SECOND FROM TIMESTAMP '2001-02-16 20:38:40');
+Result: 40
+
+SELECT EXTRACT(SECOND FROM TIME '17:12:28.5');
+Result: 28.5
timezone

The time zone offset from UTC, measured in seconds. Positive values + correspond to time zones east of UTC, negative values to + zones west of UTC. (Technically, + PostgreSQL uses UT1 because + leap seconds are not handled.) +

timezone_hour

The hour component of the time zone offset +

timezone_minute

The minute component of the time zone offset +

week

The number of the week of the year that the day is in. By definition + (ISO 8601), the first week of a year + contains January 4 of that year. (The ISO-8601 + week starts on Monday.) In other words, the first Thursday of + a year is in week 1 of that year. +

Because of this, it is possible for early January dates to be part of the + 52nd or 53rd week of the previous year. For example, 2005-01-01 + is part of the 53rd week of year 2004, and 2006-01-01 is part of + the 52nd week of year 2005. +

SELECT EXTRACT(WEEK FROM TIMESTAMP '2001-02-16 20:38:40');
+Result: 7
year

The year field. Keep in mind there is no 0 AD, so subtracting + BC years from AD years should be done with care. +

SELECT EXTRACT(YEAR FROM TIMESTAMP '2001-02-16 20:38:40');
+Result: 2001

+

The extract function is primarily intended + for computational processing. For formatting date/time values for + display, see Section 9.8. +

The date_part function is modeled on the traditional + Ingres equivalent to the + SQL-standard function extract: +

date_part('field', source)

+ Note that here the field parameter needs to + be a string value, not a name. The valid field names for + date_part are the same as for + extract. +

SELECT date_part('day', TIMESTAMP '2001-02-16 20:38:40');
+Result: 16
+
+SELECT date_part('hour', INTERVAL '4 hours 3 minutes');
+Result: 4

9.9.2. date_trunc

The function date_trunc is conceptually + similar to the trunc function for numbers. +

date_trunc('field', source)

+ source is a value expression of type + timestamp or interval. + (Values of type date and + time are cast automatically to timestamp or + interval, respectively.) + field selects to which precision to + truncate the input value. The return value is of type + timestamp or interval + with all fields that are less significant than the + selected one set to zero (or one, for day and month). +

Valid values for field are: +

microseconds
milliseconds
second
minute
hour
day
week
month
quarter
year
decade
century
millennium

+

Examples: +

SELECT date_trunc('hour', TIMESTAMP '2001-02-16 20:38:40');
+Result: 2001-02-16 20:00:00
+
+SELECT date_trunc('year', TIMESTAMP '2001-02-16 20:38:40');
+Result: 2001-01-01 00:00:00

+

9.9.3. AT TIME ZONE

The AT TIME ZONE construct allows conversions + of time stamps to different time zones. Table 9-28 shows its + variants. +

Table 9-28. AT TIME ZONE Variants

ExpressionReturn TypeDescription
timestamp without time zone AT TIME ZONE zone + timestamp with time zoneTreat given time stamp without time zone as located in the specified time zone
timestamp with time zone AT TIME ZONE zone + timestamp without time zoneConvert given time stamp with time zone to the new time + zone, with no time zone designation
time with time zone AT TIME ZONE zone + time with time zoneConvert given time with time zone to the new time zone

In these expressions, the desired time zone zone can be + specified either as a text string (e.g., 'PST') + or as an interval (e.g., INTERVAL '-08:00'). + In the text case, a time zone name can be specified in any of the ways + described in Section 8.5.3. +

Examples (assuming the local time zone is PST8PDT): +

SELECT TIMESTAMP '2001-02-16 20:38:40' AT TIME ZONE 'MST';
+Result: 2001-02-16 19:38:40-08
+
+SELECT TIMESTAMP WITH TIME ZONE '2001-02-16 20:38:40-05' AT TIME ZONE 'MST';
+Result: 2001-02-16 18:38:40

+ The first example takes a time stamp without time zone and interprets it as MST time + (UTC-7), which is then converted to PST (UTC-8) for display. The second example takes + a time stamp specified in EST (UTC-5) and converts it to local time in MST (UTC-7). +

The function timezone(zone, + timestamp) is equivalent to the SQL-conforming construct + timestamp AT TIME ZONE + zone. +

9.9.4. Current Date/Time

PostgreSQL provides a number of functions + that return values related to the current date and time. These + SQL-standard functions all return values based on the start time of + the current transaction: +

CURRENT_DATE
+CURRENT_TIME
+CURRENT_TIMESTAMP
+CURRENT_TIME(precision)
+CURRENT_TIMESTAMP(precision)
+LOCALTIME
+LOCALTIMESTAMP
+LOCALTIME(precision)
+LOCALTIMESTAMP(precision)

+

CURRENT_TIME and + CURRENT_TIMESTAMP deliver values with time zone; + LOCALTIME and + LOCALTIMESTAMP deliver values without time zone. +

CURRENT_TIME, + CURRENT_TIMESTAMP, + LOCALTIME, and + LOCALTIMESTAMP + can optionally take + a precision parameter, which causes the result to be rounded + to that many fractional digits in the seconds field. Without a precision parameter, + the result is given to the full available precision. +

Some examples: +

SELECT CURRENT_TIME;
+Result: 14:39:53.662522-05
+
+SELECT CURRENT_DATE;
+Result: 2001-12-23
+
+SELECT CURRENT_TIMESTAMP;
+Result: 2001-12-23 14:39:53.662522-05
+
+SELECT CURRENT_TIMESTAMP(2);
+Result: 2001-12-23 14:39:53.66-05
+
+SELECT LOCALTIMESTAMP;
+Result: 2001-12-23 14:39:53.662522

+

Since these functions return + the start time of the current transaction, their values do not + change during the transaction. This is considered a feature: + the intent is to allow a single transaction to have a consistent + notion of the "current" time, so that multiple + modifications within the same transaction bear the same + time stamp. +

Note: Other database systems might advance these values more + frequently. +

PostgreSQL also provides functions that + return the start time of the current statement, as well as the actual + current time at the instant the function is called. The complete list + of non-SQL-standard time functions is: +

transaction_timestamp()
+statement_timestamp()
+clock_timestamp()
+timeofday()
+now()

+

transaction_timestamp() is equivalent to + CURRENT_TIMESTAMP, but is named to clearly reflect + what it returns. + statement_timestamp() returns the start time of the current + statement (more specifically, the time of receipt of the latest command + message from the client). + statement_timestamp() and transaction_timestamp() + return the same value during the first command of a transaction, but might + differ during subsequent commands. + clock_timestamp() returns the actual current time, and + therefore its value changes even within a single SQL command. + timeofday() is a historical + PostgreSQL function. Like + clock_timestamp(), it returns the actual current time, + but as a formatted text string rather than a timestamp + with time zone value. + now() is a traditional PostgreSQL + equivalent to transaction_timestamp(). +

All the date/time data types also accept the special literal value + now to specify the current date and time (again, + interpreted as the transaction start time). Thus, + the following three all return the same result: +

SELECT CURRENT_TIMESTAMP;
+SELECT now();
+SELECT TIMESTAMP 'now';  -- incorrect for use with DEFAULT

+

Tip: You do not want to use the third form when specifying a DEFAULT + clause while creating a table. The system will convert now + to a timestamp as soon as the constant is parsed, so that when + the default value is needed, + the time of the table creation would be used! The first two + forms will not be evaluated until the default value is used, + because they are function calls. Thus they will give the desired + behavior of defaulting to the time of row insertion. +

9.9.5. Delaying Execution

The following function is available to delay execution of the server + process: +

pg_sleep(seconds)

+ + pg_sleep makes the current session's process + sleep until seconds seconds have + elapsed. seconds is a value of type + double precision, so fractional-second delays can be specified. + For example: + +

SELECT pg_sleep(1.5);

+

Note: The effective resolution of the sleep interval is platform-specific; + 0.01 seconds is a common value. The sleep delay will be at least as long + as specified. It might be longer depending on factors such as server load. +

Warning

Make sure that your session does not hold more locks than necessary + when calling pg_sleep. Otherwise other sessions + might have to wait for your sleeping process, slowing down the entire + system. +

Notes

[1]

60 if leap seconds are + implemented by the operating system


PrevHomeNext
Data Type Formatting FunctionsUpEnum Support Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-enum.html b/doc/src/sgml/html/functions-enum.html new file mode 100644 index 000000000..1f44e4413 --- /dev/null +++ b/doc/src/sgml/html/functions-enum.html @@ -0,0 +1,335 @@ + +Enum Support Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.10. Enum Support Functions

For enum types (described in Section 8.7), + there are several functions that allow cleaner programming without + hard-coding particular values of an enum type. + These are listed in Table 9-29. The examples + assume an enum type created as: + +

CREATE TYPE rainbow AS ENUM ('red', 'orange', 'yellow', 'green', 'blue', 'purple');

+ +

Table 9-29. Enum Support Functions

FunctionDescriptionExampleExample Result
+ enum_first(anyenum) + Returns the first value of the input enum typeenum_first(null::rainbow)red
+ enum_last(anyenum) + Returns the last value of the input enum typeenum_last(null::rainbow)purple
+ enum_range(anyenum) + Returns all values of the input enum type in an ordered arrayenum_range(null::rainbow){red,orange,yellow,green,blue,purple}
enum_range(anyenum, anyenum) Returns the range between the two given enum values, as an ordered + array. The values must be from the same enum type. If the first + parameter is null, the result will start with the first value of + the enum type. + If the second parameter is null, the result will end with the last + value of the enum type. + enum_range('orange'::rainbow, 'green'::rainbow){orange,yellow,green}
enum_range(NULL, 'green'::rainbow){red,orange,yellow,green}
enum_range('orange'::rainbow, NULL){orange,yellow,green,blue,purple}

Notice that except for the two-argument form of enum_range, + these functions disregard the specific value passed to them; they care + only about its declared data type. Either null or a specific value of + the type can be passed, with the same result. It is more common to + apply these functions to a table column or function argument than to + a hardwired type name as suggested by the examples. +


PrevHomeNext
Date/Time Functions and OperatorsUpGeometric Functions and Operators
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-formatting.html b/doc/src/sgml/html/functions-formatting.html new file mode 100644 index 000000000..b3710936f --- /dev/null +++ b/doc/src/sgml/html/functions-formatting.html @@ -0,0 +1,2436 @@ + +Data Type Formatting Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.8. Data Type Formatting Functions

The PostgreSQL formatting functions + provide a powerful set of tools for converting various data types + (date/time, integer, floating point, numeric) to formatted strings + and for converting from formatted strings to specific data types. + Table 9-20 lists them. + These functions all follow a common calling convention: the first + argument is the value to be formatted and the second argument is a + template that defines the output or input format. +

A single-argument to_timestamp function is also + available; it accepts a + double precision argument and converts from Unix epoch + (seconds since 1970-01-01 00:00:00+00) to + timestamp with time zone. + (Integer Unix epochs are implicitly cast to + double precision.) +

Table 9-20. Formatting Functions

FunctionReturn TypeDescriptionExample
+ to_char(timestamp, text) + textconvert time stamp to stringto_char(current_timestamp, 'HH12:MI:SS')
to_char(interval, text)textconvert interval to stringto_char(interval '15h 2m 12s', 'HH24:MI:SS')
to_char(int, text)textconvert integer to stringto_char(125, '999')
to_char(double precision, + text)textconvert real/double precision to stringto_char(125.8::real, '999D9')
to_char(numeric, text)textconvert numeric to stringto_char(-125.8, '999D99S')
+ to_date(text, text) + dateconvert string to dateto_date('05 Dec 2000', 'DD Mon YYYY')
+ to_number(text, text) + numericconvert string to numericto_number('12,454.8-', '99G999D9S')
+ to_timestamp(text, text) + timestamp with time zoneconvert string to time stampto_timestamp('05 Dec 2000', 'DD Mon YYYY')
to_timestamp(double precision)timestamp with time zoneconvert Unix epoch to time stampto_timestamp(1284352323)

In a to_char output template string, there are certain + patterns that are recognized and replaced with appropriately-formatted + data based on the given value. Any text that is not a template pattern is + simply copied verbatim. Similarly, in an input template string (for the + other functions), template patterns identify the values to be supplied by + the input data string. +

Table 9-21 shows the + template patterns available for formatting date and time values. +

Table 9-21. Template Patterns for Date/Time Formatting

PatternDescription
HHhour of day (01-12)
HH12hour of day (01-12)
HH24hour of day (00-23)
MIminute (00-59)
SSsecond (00-59)
MSmillisecond (000-999)
USmicrosecond (000000-999999)
SSSSseconds past midnight (0-86399)
AM, am, + PM or pmmeridiem indicator (without periods)
A.M., a.m., + P.M. or p.m.meridiem indicator (with periods)
Y,YYYyear (4 and more digits) with comma
YYYYyear (4 and more digits)
YYYlast 3 digits of year
YYlast 2 digits of year
Ylast digit of year
IYYYISO year (4 and more digits)
IYYlast 3 digits of ISO year
IYlast 2 digits of ISO year
Ilast digit of ISO year
BC, bc, + AD or adera indicator (without periods)
B.C., b.c., + A.D. or a.d.era indicator (with periods)
MONTHfull upper case month name (blank-padded to 9 chars)
Monthfull capitalized month name (blank-padded to 9 chars)
monthfull lower case month name (blank-padded to 9 chars)
MONabbreviated upper case month name (3 chars in English, localized lengths vary)
Monabbreviated capitalized month name (3 chars in English, localized lengths vary)
monabbreviated lower case month name (3 chars in English, localized lengths vary)
MMmonth number (01-12)
DAYfull upper case day name (blank-padded to 9 chars)
Dayfull capitalized day name (blank-padded to 9 chars)
dayfull lower case day name (blank-padded to 9 chars)
DYabbreviated upper case day name (3 chars in English, localized lengths vary)
Dyabbreviated capitalized day name (3 chars in English, localized lengths vary)
dyabbreviated lower case day name (3 chars in English, localized lengths vary)
DDDday of year (001-366)
IDDDISO day of year (001-371; day 1 of the year is Monday of the first ISO week.)
DDday of month (01-31)
Dday of the week, Sunday(1) to Saturday(7)
IDISO day of the week, Monday(1) to Sunday(7)
Wweek of month (1-5) (The first week starts on the first day of the month.)
WWweek number of year (1-53) (The first week starts on the first day of the year.)
IWISO week number of year (01 - 53; the first Thursday of the new year is in week 1.)
CCcentury (2 digits) (The twenty-first century starts on 2001-01-01.)
JJulian Day (days since November 24, 4714 BC at midnight)
Qquarter (ignored by to_date and to_timestamp)
RMmonth in upper case Roman numerals (I-XII; I=January)
rmmonth in lower case Roman numerals (i-xii; i=January)
TZupper case time-zone name
tzlower case time-zone name

Modifiers can be applied to any template pattern to alter its + behavior. For example, FMMonth + is the Month pattern with the + FM modifier. + Table 9-22 shows the + modifier patterns for date/time formatting. +

Table 9-22. Template Pattern Modifiers for Date/Time Formatting

ModifierDescriptionExample
FM prefixfill mode (suppress padding blanks and trailing zeroes)FMMonth
TH suffixupper case ordinal number suffixDDTH, e.g., 12TH
th suffixlower case ordinal number suffixDDth, e.g., 12th
FX prefixfixed format global option (see usage notes)FX Month DD Day
TM prefixtranslation mode (print localized day and month names based on + lc_time)TMMonth
SP suffixspell mode (not implemented)DDSP

Usage notes for date/time formatting: + +

  • FM suppresses leading zeroes and trailing blanks + that would otherwise be added to make the output of a pattern be + fixed-width. In PostgreSQL, + FM modifies only the next specification, while in + Oracle FM affects all subsequent + specifications, and repeated FM modifiers + toggle fill mode on and off. +

  • TM does not include trailing blanks. +

  • to_timestamp and to_date + skip multiple blank spaces in the input string unless the + FX option is used. For example, + to_timestamp('2000    JUN', 'YYYY MON') works, but + to_timestamp('2000    JUN', 'FXYYYY MON') returns an error + because to_timestamp expects one space only. + FX must be specified as the first item in + the template. +

  • Ordinary text is allowed in to_char + templates and will be output literally. You can put a substring + in double quotes to force it to be interpreted as literal text + even if it contains pattern key words. For example, in + '"Hello Year "YYYY', the YYYY + will be replaced by the year data, but the single Y in Year + will not be. In to_date, to_number, + and to_timestamp, double-quoted strings skip the number of + input characters contained in the string, e.g. "XX" + skips two input characters. +

  • If you want to have a double quote in the output you must + precede it with a backslash, for example '\"YYYY + Month\"'. +

  • If the year format specification is less than four digits, e.g. + YYY, and the supplied year is less than four digits, + the year will be adjusted to be nearest to the year 2020, e.g. + 95 becomes 1995. +

  • The YYYY conversion from string to timestamp or + date has a restriction when processing years with more than 4 digits. You must + use some non-digit character or template after YYYY, + otherwise the year is always interpreted as 4 digits. For example + (with the year 20000): + to_date('200001131', 'YYYYMMDD') will be + interpreted as a 4-digit year; instead use a non-digit + separator after the year, like + to_date('20000-1131', 'YYYY-MMDD') or + to_date('20000Nov31', 'YYYYMonDD'). +

  • In conversions from string to timestamp or + date, the CC (century) field is ignored + if there is a YYY, YYYY or + Y,YYY field. If CC is used with + YY or Y then the year is computed + as (CC-1)*100+YY. +

  • An ISO week date (as distinct from a Gregorian date) can be + specified to to_timestamp and + to_date in one of two ways: +

    • Year, week, and weekday: for example to_date('2006-42-4', + 'IYYY-IW-ID') returns the date + 2006-10-19. If you omit the weekday it + is assumed to be 1 (Monday). +

    • Year and day of year: for example to_date('2006-291', + 'IYYY-IDDD') also returns 2006-10-19. +

    +

    Attempting to construct a date using a mixture of ISO week and + Gregorian date fields is nonsensical, and will cause an error. In the + context of an ISO year, the concept of a "month" or "day + of month" has no meaning. In the context of a Gregorian year, the + ISO week has no meaning. Users should avoid mixing Gregorian and + ISO date specifications. +

  • In a conversion from string to timestamp, millisecond + (MS) or microsecond (US) + values are used as the + seconds digits after the decimal point. For example + to_timestamp('12:3', 'SS:MS') is not 3 milliseconds, + but 300, because the conversion counts it as 12 + 0.3 seconds. + This means for the format SS:MS, the input values + 12:3, 12:30, and 12:300 specify the + same number of milliseconds. To get three milliseconds, one must use + 12:003, which the conversion counts as + 12 + 0.003 = 12.003 seconds. +

    Here is a more + complex example: + to_timestamp('15:12:02.020.001230', 'HH:MI:SS.MS.US') + is 15 hours, 12 minutes, and 2 seconds + 20 milliseconds + + 1230 microseconds = 2.021230 seconds. +

  • to_char(..., 'ID')'s day of the week numbering + matches the extract(isodow from ...) function, but + to_char(..., 'D')'s does not match + extract(dow from ...)'s day numbering. +

  • to_char(interval) formats HH and + HH12 as shown on a 12-hour clock, i.e. zero hours + and 36 hours output as 12, while HH24 + outputs the full hour value, which can exceed 23 for intervals. +

+

Table 9-23 shows the + template patterns available for formatting numeric values. +

Table 9-23. Template Patterns for Numeric Formatting

PatternDescription
9value with the specified number of digits
0value with leading zeros
. (period)decimal point
, (comma)group (thousand) separator
PRnegative value in angle brackets
Ssign anchored to number (uses locale)
Lcurrency symbol (uses locale)
Ddecimal point (uses locale)
Ggroup separator (uses locale)
MIminus sign in specified position (if number < 0)
PLplus sign in specified position (if number > 0)
SGplus/minus sign in specified position
RNRoman numeral (input between 1 and 3999)
TH or thordinal number suffix
Vshift specified number of digits (see notes)
EEEEexponent for scientific notation

Usage notes for numeric formatting: + +

  • A sign formatted using SG, PL, or + MI is not anchored to + the number; for example, + to_char(-12, 'MI9999') produces '-  12' + but to_char(-12, 'S9999') produces '  -12'. + The Oracle implementation does not allow the use of + MI before 9, but rather + requires that 9 precede + MI. +

  • 9 results in a value with the same number of + digits as there are 9s. If a digit is + not available it outputs a space. +

  • TH does not convert values less than zero + and does not convert fractional numbers. +

  • PL, SG, and + TH are PostgreSQL + extensions. +

  • V effectively + multiplies the input values by + 10^n, where + n is the number of digits following + V. + to_char does not support the use of + V combined with a decimal point + (e.g., 99.9V99 is not allowed). +

  • EEEE (scientific notation) cannot be used in + combination with any of the other formatting patterns or + modifiers other than digit and decimal point patterns, and must be at the end of the format string + (e.g., 9.99EEEE is a valid pattern). +

+

Certain modifiers can be applied to any template pattern to alter its + behavior. For example, FM9999 + is the 9999 pattern with the + FM modifier. + Table 9-24 shows the + modifier patterns for numeric formatting. +

Table 9-24. Template Pattern Modifiers for Numeric Formatting

ModifierDescriptionExample
FM prefixfill mode (suppress padding blanks and trailing zeroes)FM9999
TH suffixupper case ordinal number suffix999TH
th suffixlower case ordinal number suffix999th

Table 9-25 shows some + examples of the use of the to_char function. +

Table 9-25. to_char Examples

ExpressionResult
to_char(current_timestamp, 'Day, DD  HH12:MI:SS')'Tuesday  , 06  05:39:18'
to_char(current_timestamp, 'FMDay, FMDD  HH12:MI:SS')'Tuesday, 6  05:39:18'
to_char(-0.1, '99.99')'  -.10'
to_char(-0.1, 'FM9.99')'-.1'
to_char(0.1, '0.9')' 0.1'
to_char(12, '9990999.9')'    0012.0'
to_char(12, 'FM9990999.9')'0012.'
to_char(485, '999')' 485'
to_char(-485, '999')'-485'
to_char(485, '9 9 9')' 4 8 5'
to_char(1485, '9,999')' 1,485'
to_char(1485, '9G999')' 1 485'
to_char(148.5, '999.999')' 148.500'
to_char(148.5, 'FM999.999')'148.5'
to_char(148.5, 'FM999.990')'148.500'
to_char(148.5, '999D999')' 148,500'
to_char(3148.5, '9G999D999')' 3 148,500'
to_char(-485, '999S')'485-'
to_char(-485, '999MI')'485-'
to_char(485, '999MI')'485 '
to_char(485, 'FM999MI')'485'
to_char(485, 'PL999')'+485'
to_char(485, 'SG999')'+485'
to_char(-485, 'SG999')'-485'
to_char(-485, '9SG99')'4-85'
to_char(-485, '999PR')'<485>'
to_char(485, 'L999')'DM 485
to_char(485, 'RN')'        CDLXXXV'
to_char(485, 'FMRN')'CDLXXXV'
to_char(5.2, 'FMRN')'V'
to_char(482, '999th')' 482nd'
to_char(485, '"Good number:"999')'Good number: 485'
to_char(485.8, '"Pre:"999" Post:" .999')'Pre: 485 Post: .800'
to_char(12, '99V999')' 12000'
to_char(12.4, '99V999')' 12400'
to_char(12.45, '99V9')' 125'
to_char(0.0004859, '9.99EEEE')' 4.86e-04'

PrevHomeNext
Pattern MatchingUpDate/Time Functions and Operators
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-geometry.html b/doc/src/sgml/html/functions-geometry.html new file mode 100644 index 000000000..9ddc6e91b --- /dev/null +++ b/doc/src/sgml/html/functions-geometry.html @@ -0,0 +1,1711 @@ + +Geometric Functions and Operators
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.11. Geometric Functions and Operators

The geometric types point, box, + lseg, line, path, + polygon, and circle have a large set of + native support functions and operators, shown in Table 9-30, Table 9-31, and Table 9-32. +

Caution

Note that the "same as" operator, ~=, represents + the usual notion of equality for the point, + box, polygon, and circle types. + Some of these types also have an = operator, but + = compares + for equal areas only. The other scalar comparison operators + (<= and so on) likewise compare areas for these types. +

Table 9-30. Geometric Operators

OperatorDescriptionExample
+ Translationbox '((0,0),(1,1))' + point '(2.0,0)'
- Translationbox '((0,0),(1,1))' - point '(2.0,0)'
* Scaling/rotationbox '((0,0),(1,1))' * point '(2.0,0)'
/ Scaling/rotationbox '((0,0),(2,2))' / point '(2.0,0)'
# Point or box of intersection'((1,-1),(-1,1))' # '((1,1),(-1,-1))'
# Number of points in path or polygon# '((1,0),(0,1),(-1,0))'
@-@ Length or circumference@-@ path '((0,0),(1,0))'
@@ Center@@ circle '((0,0),10)'
## Closest point to first operand on second operandpoint '(0,0)' ## lseg '((2,0),(0,2))'
<-> Distance betweencircle '((0,0),1)' <-> circle '((5,0),1)'
&& Overlaps? (One point in common makes this true.)box '((0,0),(1,1))' && box '((0,0),(2,2))'
<< Is strictly left of?circle '((0,0),1)' << circle '((5,0),1)'
>> Is strictly right of?circle '((5,0),1)' >> circle '((0,0),1)'
&< Does not extend to the right of?box '((0,0),(1,1))' &< box '((0,0),(2,2))'
&> Does not extend to the left of?box '((0,0),(3,3))' &> box '((0,0),(2,2))'
<<| Is strictly below?box '((0,0),(3,3))' <<| box '((3,4),(5,5))'
|>> Is strictly above?box '((3,4),(5,5))' |>> box '((0,0),(3,3))'
&<| Does not extend above?box '((0,0),(1,1))' &<| box '((0,0),(2,2))'
|&> Does not extend below?box '((0,0),(3,3))' |&> box '((0,0),(2,2))'
<^ Is below (allows touching)?circle '((0,0),1)' <^ circle '((0,5),1)'
>^ Is above (allows touching)?circle '((0,5),1)' >^ circle '((0,0),1)'
?# Intersects?lseg '((-1,0),(1,0))' ?# box '((-2,-2),(2,2))'
?- Is horizontal??- lseg '((-1,0),(1,0))'
?- Are horizontally aligned?point '(1,0)' ?- point '(0,0)'
?| Is vertical??| lseg '((-1,0),(1,0))'
?| Are vertically aligned?point '(0,1)' ?| point '(0,0)'
?-| Is perpendicular?lseg '((0,0),(0,1))' ?-| lseg '((0,0),(1,0))'
?|| Are parallel?lseg '((-1,0),(1,0))' ?|| lseg '((-1,2),(1,2))'
@> Contains?circle '((0,0),2)' @> point '(1,1)'
<@ Contained in or on?point '(1,1)' <@ circle '((0,0),2)'
~= Same as?polygon '((0,0),(1,1))' ~= polygon '((1,1),(0,0))'

Note: Before PostgreSQL 8.2, the containment + operators @> and <@ were respectively + called ~ and @. These names are still + available, but are deprecated and will eventually be removed. +

Table 9-31. Geometric Functions

FunctionReturn TypeDescriptionExample
area(object)double precisionareaarea(box '((0,0),(1,1))')
center(object)pointcentercenter(box '((0,0),(1,2))')
diameter(circle)double precisiondiameter of circlediameter(circle '((0,0),2.0)')
height(box)double precisionvertical size of boxheight(box '((0,0),(1,1))')
isclosed(path)booleana closed path?isclosed(path '((0,0),(1,1),(2,0))')
isopen(path)booleanan open path?isopen(path '[(0,0),(1,1),(2,0)]')
length(object)double precisionlengthlength(path '((-1,0),(1,0))')
npoints(path)intnumber of pointsnpoints(path '[(0,0),(1,1),(2,0)]')
npoints(polygon)intnumber of pointsnpoints(polygon '((1,1),(0,0))')
pclose(path)pathconvert path to closedpclose(path '[(0,0),(1,1),(2,0)]')
popen(path)pathconvert path to openpopen(path '((0,0),(1,1),(2,0))')
radius(circle)double precisionradius of circleradius(circle '((0,0),2.0)')
width(box)double precisionhorizontal size of boxwidth(box '((0,0),(1,1))')

Table 9-32. Geometric Type Conversion Functions

FunctionReturn TypeDescriptionExample
+ box(circle) + boxcircle to boxbox(circle '((0,0),2.0)')
box(point, point)boxpoints to boxbox(point '(0,0)', point '(1,1)')
box(polygon)boxpolygon to boxbox(polygon '((0,0),(1,1),(2,0))')
+ circle(box) + circlebox to circlecircle(box '((0,0),(1,1))')
circle(point, double precision)circlecenter and radius to circlecircle(point '(0,0)', 2.0)
circle(polygon)circlepolygon to circlecircle(polygon '((0,0),(1,1),(2,0))')
+ lseg(box) + lsegbox diagonal to line segmentlseg(box '((-1,0),(1,0))')
lseg(point, point)lsegpoints to line segmentlseg(point '(-1,0)', point '(1,0)')
+ path(polygon) + pathpolygon to pathpath(polygon '((0,0),(1,1),(2,0))')
+ point(double + precision, double precision) + pointconstruct pointpoint(23.4, -44.5)
point(box)pointcenter of boxpoint(box '((-1,0),(1,0))')
point(circle)pointcenter of circlepoint(circle '((0,0),2.0)')
point(lseg)pointcenter of line segmentpoint(lseg '((-1,0),(1,0))')
point(polygon)pointcenter of polygonpoint(polygon '((0,0),(1,1),(2,0))')
+ polygon(box) + polygonbox to 4-point polygonpolygon(box '((0,0),(1,1))')
polygon(circle)polygoncircle to 12-point polygonpolygon(circle '((0,0),2.0)')
polygon(npts, circle)polygoncircle to npts-point polygonpolygon(12, circle '((0,0),2.0)')
polygon(path)polygonpath to polygonpolygon(path '((0,0),(1,1),(2,0))')

It is possible to access the two component numbers of a point + as though the point were an array with indexes 0 and 1. For example, if + t.p is a point column then + SELECT p[0] FROM t retrieves the X coordinate and + UPDATE t SET p[1] = ... changes the Y coordinate. + In the same way, a value of type box or lseg can be treated + as an array of two point values. +

The area function works for the types + box, circle, and path. + The area function only works on the + path data type if the points in the + path are non-intersecting. For example, the + path + '((0,0),(0,1),(2,1),(2,2),(1,2),(1,0),(0,0))'::PATH + will not work; however, the following visually identical + path + '((0,0),(0,1),(1,1),(1,2),(2,2),(2,1),(1,1),(1,0),(0,0))'::PATH + will work. If the concept of an intersecting versus + non-intersecting path is confusing, draw both of the + above paths side by side on a piece of graph paper. +


PrevHomeNext
Enum Support FunctionsUpNetwork Address Functions and Operators
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-info.html b/doc/src/sgml/html/functions-info.html new file mode 100644 index 000000000..938e7f7af --- /dev/null +++ b/doc/src/sgml/html/functions-info.html @@ -0,0 +1,3653 @@ + +System Information Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.25. System Information Functions

Table 9-50 shows several + functions that extract session and system information. +

In addition to the functions listed in this section, there are a number of + functions related to the statistics system that also provide system + information. See Section 27.2.2 for more + information. +

Table 9-50. Session Information Functions

NameReturn TypeDescription
current_catalognamename of current database (called "catalog" in the SQL standard)
current_database()namename of current database
current_query()texttext of the currently executing query, as submitted + by the client (might contain more than one statement)
current_schema[()]namename of current schema
current_schemas(boolean)name[]names of schemas in search path, optionally including implicit schemas
current_usernameuser name of current execution context
inet_client_addr()inetaddress of the remote connection
inet_client_port()intport of the remote connection
inet_server_addr()inetaddress of the local connection
inet_server_port()intport of the local connection
pg_backend_pid()int Process ID of the server process attached to the current session +
pg_conf_load_time()timestamp with time zoneconfiguration load time
pg_is_other_temp_schema(oid)booleanis schema another session's temporary schema?
pg_listening_channels()setof textchannel names that the session is currently listening on
pg_my_temp_schema()oidOID of session's temporary schema, or 0 if none
pg_postmaster_start_time()timestamp with time zoneserver start time
pg_trigger_depth()intcurrent nesting level of PostgreSQL triggers + (0 if not called, directly or indirectly, from inside a trigger)
session_usernamesession user name
usernameequivalent to current_user
version()textPostgreSQL version information

Note: current_catalog, current_schema, + current_user, session_user, + and user have special syntactic status + in SQL: they must be called without trailing + parentheses. (In PostgreSQL, parentheses can optionally be used with + current_schema, but not with the others.) +

The session_user is normally the user who initiated + the current database connection; but superusers can change this setting + with SET SESSION AUTHORIZATION. + The current_user is the user identifier + that is applicable for permission checking. Normally it is equal + to the session user, but it can be changed with + SET ROLE. + It also changes during the execution of + functions with the attribute SECURITY DEFINER. + In Unix parlance, the session user is the "real user" and + the current user is the "effective user". +

current_schema returns the name of the schema that is + first in the search path (or a null value if the search path is + empty). This is the schema that will be used for any tables or + other named objects that are created without specifying a target schema. + current_schemas(boolean) returns an array of the names of all + schemas presently in the search path. The Boolean option determines whether or not + implicitly included system schemas such as pg_catalog are included in the + returned search path. +

Note: The search path can be altered at run time. The command is: +

SET search_path TO schema [, schema, ...]

+

pg_listening_channels returns a set of names of + channels that the current session is listening to. See LISTEN for more information. +

inet_client_addr returns the IP address of the + current client, and inet_client_port returns the + port number. + inet_server_addr returns the IP address on which + the server accepted the current connection, and + inet_server_port returns the port number. + All these functions return NULL if the current connection is via a + Unix-domain socket. +

pg_my_temp_schema returns the OID of the current + session's temporary schema, or zero if it has none (because it has not + created any temporary tables). + pg_is_other_temp_schema returns true if the + given OID is the OID of another session's temporary schema. + (This can be useful, for example, to exclude other sessions' temporary + tables from a catalog display.) +

pg_postmaster_start_time returns the + timestamp with time zone when the + server started. +

pg_conf_load_time returns the + timestamp with time zone when the + server configuration files were last loaded. + (If the current session was alive at the time, this will be the time + when the session itself re-read the configuration files, so the + reading will vary a little in different sessions. Otherwise it is + the time when the postmaster process re-read the configuration files.) +

version returns a string describing the + PostgreSQL server's version. +

Table 9-51 lists functions that + allow the user to query object access privileges programmatically. + See Section 5.6 for more information about + privileges. +

Table 9-51. Access Privilege Inquiry Functions

NameReturn TypeDescription
has_any_column_privilege(user, + table, + privilege) + booleandoes user have privilege for any column of table
has_any_column_privilege(table, + privilege) + booleandoes current user have privilege for any column of table
has_column_privilege(user, + table, + column, + privilege) + booleandoes user have privilege for column
has_column_privilege(table, + column, + privilege) + booleandoes current user have privilege for column
has_database_privilege(user, + database, + privilege) + booleandoes user have privilege for database
has_database_privilege(database, + privilege) + booleandoes current user have privilege for database
has_foreign_data_wrapper_privilege(user, + fdw, + privilege) + booleandoes user have privilege for foreign-data wrapper
has_foreign_data_wrapper_privilege(fdw, + privilege) + booleandoes current user have privilege for foreign-data wrapper
has_function_privilege(user, + function, + privilege) + booleandoes user have privilege for function
has_function_privilege(function, + privilege) + booleandoes current user have privilege for function
has_language_privilege(user, + language, + privilege) + booleandoes user have privilege for language
has_language_privilege(language, + privilege) + booleandoes current user have privilege for language
has_schema_privilege(user, + schema, + privilege) + booleandoes user have privilege for schema
has_schema_privilege(schema, + privilege) + booleandoes current user have privilege for schema
has_sequence_privilege(user, + sequence, + privilege) + booleandoes user have privilege for sequence
has_sequence_privilege(sequence, + privilege) + booleandoes current user have privilege for sequence
has_server_privilege(user, + server, + privilege) + booleandoes user have privilege for foreign server
has_server_privilege(server, + privilege) + booleandoes current user have privilege for foreign server
has_table_privilege(user, + table, + privilege) + booleandoes user have privilege for table
has_table_privilege(table, + privilege) + booleandoes current user have privilege for table
has_tablespace_privilege(user, + tablespace, + privilege) + booleandoes user have privilege for tablespace
has_tablespace_privilege(tablespace, + privilege) + booleandoes current user have privilege for tablespace
pg_has_role(user, + role, + privilege) + booleandoes user have privilege for role
pg_has_role(role, + privilege) + booleandoes current user have privilege for role

has_table_privilege checks whether a user + can access a table in a particular way. The user can be + specified by name, by OID (pg_authid.oid), + public to indicate the PUBLIC pseudo-role, or if the argument is + omitted + current_user is assumed. The table can be specified + by name or by OID. (Thus, there are actually six variants of + has_table_privilege, which can be distinguished by + the number and types of their arguments.) When specifying by name, + the name can be schema-qualified if necessary. + The desired access privilege type + is specified by a text string, which must evaluate to one of the + values SELECT, INSERT, + UPDATE, DELETE, TRUNCATE, + REFERENCES, or TRIGGER. Optionally, + WITH GRANT OPTION can be added to a privilege type to test + whether the privilege is held with grant option. Also, multiple privilege + types can be listed separated by commas, in which case the result will + be true if any of the listed privileges is held. + (Case of the privilege string is not significant, and extra whitespace + is allowed between but not within privilege names.) + Some examples: +

SELECT has_table_privilege('myschema.mytable', 'select');
+SELECT has_table_privilege('joe', 'mytable', 'INSERT, SELECT WITH GRANT OPTION');

+

has_sequence_privilege checks whether a user + can access a sequence in a particular way. The possibilities for its + arguments are analogous to has_table_privilege. + The desired access privilege type must evaluate to one of + USAGE, + SELECT, or + UPDATE. +

has_any_column_privilege checks whether a user can + access any column of a table in a particular way. + Its argument possibilities + are analogous to has_table_privilege, + except that the desired access privilege type must evaluate to some + combination of + SELECT, + INSERT, + UPDATE, or + REFERENCES. Note that having any of these privileges + at the table level implicitly grants it for each column of the table, + so has_any_column_privilege will always return + true if has_table_privilege does for the same + arguments. But has_any_column_privilege also succeeds if + there is a column-level grant of the privilege for at least one column. +

has_column_privilege checks whether a user + can access a column in a particular way. + Its argument possibilities + are analogous to has_table_privilege, + with the addition that the column can be specified either by name + or attribute number. + The desired access privilege type must evaluate to some combination of + SELECT, + INSERT, + UPDATE, or + REFERENCES. Note that having any of these privileges + at the table level implicitly grants it for each column of the table. +

has_database_privilege checks whether a user + can access a database in a particular way. + Its argument possibilities + are analogous to has_table_privilege. + The desired access privilege type must evaluate to some combination of + CREATE, + CONNECT, + TEMPORARY, or + TEMP (which is equivalent to + TEMPORARY). +

has_function_privilege checks whether a user + can access a function in a particular way. + Its argument possibilities + are analogous to has_table_privilege. + When specifying a function by a text string rather than by OID, + the allowed input is the same as for the regprocedure data type + (see Section 8.18). + The desired access privilege type must evaluate to + EXECUTE. + An example is: +

SELECT has_function_privilege('joeuser', 'myfunc(int, text)', 'execute');

+

has_foreign_data_wrapper_privilege checks whether a user + can access a foreign-data wrapper in a particular way. + Its argument possibilities + are analogous to has_table_privilege. + The desired access privilege type must evaluate to + USAGE. +

has_language_privilege checks whether a user + can access a procedural language in a particular way. + Its argument possibilities + are analogous to has_table_privilege. + The desired access privilege type must evaluate to + USAGE. +

has_schema_privilege checks whether a user + can access a schema in a particular way. + Its argument possibilities + are analogous to has_table_privilege. + The desired access privilege type must evaluate to some combination of + CREATE or + USAGE. +

has_server_privilege checks whether a user + can access a foreign server in a particular way. + Its argument possibilities + are analogous to has_table_privilege. + The desired access privilege type must evaluate to + USAGE. +

has_tablespace_privilege checks whether a user + can access a tablespace in a particular way. + Its argument possibilities + are analogous to has_table_privilege. + The desired access privilege type must evaluate to + CREATE. +

pg_has_role checks whether a user + can access a role in a particular way. + Its argument possibilities + are analogous to has_table_privilege, + except that public is not allowed as a user name. + The desired access privilege type must evaluate to some combination of + MEMBER or + USAGE. + MEMBER denotes direct or indirect membership in + the role (that is, the right to do SET ROLE), while + USAGE denotes whether the privileges of the role + are immediately available without doing SET ROLE. +

Table 9-52 shows functions that + determine whether a certain object is visible in the + current schema search path. + For example, a table is said to be visible if its + containing schema is in the search path and no table of the same + name appears earlier in the search path. This is equivalent to the + statement that the table can be referenced by name without explicit + schema qualification. To list the names of all visible tables: +

SELECT relname FROM pg_class WHERE pg_table_is_visible(oid);

+

Table 9-52. Schema Visibility Inquiry Functions

NameReturn TypeDescription
pg_collation_is_visible(collation_oid) + booleanis collation visible in search path
pg_conversion_is_visible(conversion_oid) + booleanis conversion visible in search path
pg_function_is_visible(function_oid) + booleanis function visible in search path
pg_opclass_is_visible(opclass_oid) + booleanis operator class visible in search path
pg_operator_is_visible(operator_oid) + booleanis operator visible in search path
pg_opfamily_is_visible(opclass_oid) + booleanis operator family visible in search path
pg_table_is_visible(table_oid) + booleanis table visible in search path
pg_ts_config_is_visible(config_oid) + booleanis text search configuration visible in search path
pg_ts_dict_is_visible(dict_oid) + booleanis text search dictionary visible in search path
pg_ts_parser_is_visible(parser_oid) + booleanis text search parser visible in search path
pg_ts_template_is_visible(template_oid) + booleanis text search template visible in search path
pg_type_is_visible(type_oid) + booleanis type (or domain) visible in search path

Each function performs the visibility check for one type of database + object. Note that pg_table_is_visible can also be used + with views, indexes and sequences; pg_type_is_visible + can also be used with domains. For functions and operators, an object in + the search path is visible if there is no object of the same name + and argument data type(s) earlier in the path. For operator + classes, both name and associated index access method are considered. +

All these functions require object OIDs to identify the object to be + checked. If you want to test an object by name, it is convenient to use + the OID alias types (regclass, regtype, + regprocedure, regoperator, regconfig, + or regdictionary), + for example: +

SELECT pg_type_is_visible('myschema.widget'::regtype);

+ Note that it would not make much sense to test a non-schema-qualified + type name in this way — if the name can be recognized at all, it must be visible. +

Table 9-53 lists functions that + extract information from the system catalogs. +

Table 9-53. System Catalog Information Functions

NameReturn TypeDescription
format_type(type_oid, typemod)textget SQL name of a data type
pg_describe_object(catalog_id, object_id, object_sub_id)textget description of a database object
pg_get_constraintdef(constraint_oid)textget definition of a constraint
pg_get_constraintdef(constraint_oid, pretty_bool)textget definition of a constraint
pg_get_expr(pg_node_tree, relation_oid)textdecompile internal form of an expression, assuming that any Vars + in it refer to the relation indicated by the second parameter
pg_get_expr(pg_node_tree, relation_oid, pretty_bool)textdecompile internal form of an expression, assuming that any Vars + in it refer to the relation indicated by the second parameter
pg_get_functiondef(func_oid)textget definition of a function
pg_get_function_arguments(func_oid)textget argument list of function's definition (with default values)
pg_get_function_identity_arguments(func_oid)textget argument list to identify a function (without default values)
pg_get_function_result(func_oid)textget RETURNS clause for function
pg_get_indexdef(index_oid)textget CREATE INDEX command for index
pg_get_indexdef(index_oid, column_no, pretty_bool)textget CREATE INDEX command for index, + or definition of just one index column when + column_no is not zero
pg_get_keywords()setof recordget list of SQL keywords and their categories
pg_get_ruledef(rule_oid)textget CREATE RULE command for rule
pg_get_ruledef(rule_oid, pretty_bool)textget CREATE RULE command for rule
pg_get_serial_sequence(table_name, column_name)textget name of the sequence that a serial, smallserial or bigserial column + uses
pg_get_triggerdef(trigger_oid)textget CREATE [ CONSTRAINT ] TRIGGER command for trigger
pg_get_triggerdef(trigger_oid, pretty_bool)textget CREATE [ CONSTRAINT ] TRIGGER command for trigger
pg_get_userbyid(role_oid)nameget role name with given OID
pg_get_viewdef(view_name)textget underlying SELECT command for view (deprecated)
pg_get_viewdef(view_name, pretty_bool)textget underlying SELECT command for view, + lines with fields are wrapped to 80 columns if pretty_bool is true (deprecated)
pg_get_viewdef(view_oid)textget underlying SELECT command for view
pg_get_viewdef(view_oid, pretty_bool)textget underlying SELECT command for view, + lines with fields are wrapped to 80 columns if pretty_bool is true
pg_get_viewdef(view_oid, wrap_int)textget underlying SELECT command for view, + wrapping lines with fields as specified, pretty printing is implied
pg_options_to_table(reloptions)setof recordget the set of storage option name/value pairs
pg_tablespace_databases(tablespace_oid)setof oidget the set of database OIDs that have objects in the tablespace
pg_tablespace_location(tablespace_oid)textget the path in the file system that this tablespace is located in
pg_typeof(any)regtypeget the data type of any value
collation for (any)textget the collation of the argument

format_type returns the SQL name of a data type that + is identified by its type OID and possibly a type modifier. Pass NULL + for the type modifier if no specific modifier is known. +

pg_get_keywords returns a set of records describing + the SQL keywords recognized by the server. The word column + contains the keyword. The catcode column contains a + category code: U for unreserved, C for column name, + T for type or function name, or R for reserved. + The catdesc column contains a possibly-localized string + describing the category. +

pg_get_constraintdef, + pg_get_indexdef, pg_get_ruledef, + and pg_get_triggerdef, respectively reconstruct the + creating command for a constraint, index, rule, or trigger. (Note that this + is a decompiled reconstruction, not the original text of the command.) + pg_get_expr decompiles the internal form of an + individual expression, such as the default value for a column. It can be + useful when examining the contents of system catalogs. If the expression + might contain Vars, specify the OID of the relation they refer to as the + second parameter; if no Vars are expected, zero is sufficient. + pg_get_viewdef reconstructs the SELECT + query that defines a view. Most of these functions come in two variants, + one of which can optionally "pretty-print" the result. The + pretty-printed format is more readable, but the default format is more + likely to be interpreted the same way by future versions of + PostgreSQL; avoid using pretty-printed output for dump + purposes. Passing false for the pretty-print parameter yields + the same result as the variant that does not have the parameter at all. +

pg_get_functiondef returns a complete + CREATE OR REPLACE FUNCTION statement for a function. + pg_get_function_arguments returns the argument list + of a function, in the form it would need to appear in within + CREATE FUNCTION. + pg_get_function_result similarly returns the + appropriate RETURNS clause for the function. + pg_get_function_identity_arguments returns the + argument list necessary to identify a function, in the form it + would need to appear in within ALTER FUNCTION, for + instance. This form omits default values. +

pg_get_serial_sequence returns the name of the + sequence associated with a column, or NULL if no sequence is associated + with the column. The first input parameter is a table name with + optional schema, and the second parameter is a column name. Because + the first parameter is potentially a schema and table, it is not treated + as a double-quoted identifier, meaning it is lower cased by default, + while the second parameter, being just a column name, is treated as + double-quoted and has its case preserved. The function returns a value + suitably formatted for passing to sequence functions (see Section 9.16). This association can be modified or + removed with ALTER SEQUENCE OWNED BY. (The function + probably should have been called + pg_get_owned_sequence; its current name reflects the fact + that it's typically used with serial or bigserial + columns.) +

pg_get_userbyid extracts a role's name given + its OID. +

pg_options_to_table returns the set of storage + option name/value pairs + (option_name/option_value) when passed + pg_class.reloptions or + pg_attribute.attoptions. +

pg_tablespace_databases allows a tablespace to be + examined. It returns the set of OIDs of databases that have objects stored + in the tablespace. If this function returns any rows, the tablespace is not + empty and cannot be dropped. To display the specific objects populating the + tablespace, you will need to connect to the databases identified by + pg_tablespace_databases and query their + pg_class catalogs. +

pg_describe_object returns a description of a database + object specified by catalog OID, object OID and a (possibly zero) sub-object ID. + This is useful to determine the identity of an object as stored in the + pg_depend catalog. +

pg_typeof returns the OID of the data type of the + value that is passed to it. This can be helpful for troubleshooting or + dynamically constructing SQL queries. The function is declared as + returning regtype, which is an OID alias type (see + Section 8.18); this means that it is the same as an + OID for comparison purposes but displays as a type name. For example: +

SELECT pg_typeof(33);
+
+ pg_typeof 
+-----------
+ integer
+(1 row)
+
+SELECT typlen FROM pg_type WHERE oid = pg_typeof(33);
+ typlen 
+--------
+      4
+(1 row)

+

The expression collation for returns the collation of the + value that is passed to it. Example: +

SELECT collation for (description) FROM pg_description LIMIT 1;
+ pg_collation_for 
+------------------
+ "default"
+(1 row)
+
+SELECT collation for ('foo' COLLATE "de_DE");
+ pg_collation_for 
+------------------
+ "de_DE"
+(1 row)

+ The value might be quoted and schema-qualified. If no collation is derived + for the argument expression, then a null value is returned. If the argument + is not of a collatable data type, then an error is raised. +

The functions shown in Table 9-54 + extract comments previously stored with the COMMENT + command. A null value is returned if no + comment could be found for the specified parameters. +

Table 9-54. Comment Information Functions

NameReturn TypeDescription
col_description(table_oid, column_number)textget comment for a table column
obj_description(object_oid, catalog_name)textget comment for a database object
obj_description(object_oid)textget comment for a database object (deprecated)
shobj_description(object_oid, catalog_name)textget comment for a shared database object

col_description returns the comment for a table + column, which is specified by the OID of its table and its column number. + (obj_description cannot be used for table columns + since columns do not have OIDs of their own.) +

The two-parameter form of obj_description returns the + comment for a database object specified by its OID and the name of the + containing system catalog. For example, + obj_description(123456,'pg_class') + would retrieve the comment for the table with OID 123456. + The one-parameter form of obj_description requires only + the object OID. It is deprecated since there is no guarantee that + OIDs are unique across different system catalogs; therefore, the wrong + comment might be returned. +

shobj_description is used just like + obj_description except it is used for retrieving + comments on shared objects. Some system catalogs are global to all + databases within each cluster, and the descriptions for objects in them + are stored globally as well. +

The functions shown in Table 9-55 + provide server transaction information in an exportable form. The main + use of these functions is to determine which transactions were committed + between two snapshots. +

Table 9-55. Transaction IDs and Snapshots

NameReturn TypeDescription
txid_current()bigintget current transaction ID
txid_current_snapshot()txid_snapshotget current snapshot
txid_snapshot_xip(txid_snapshot)setof bigintget in-progress transaction IDs in snapshot
txid_snapshot_xmax(txid_snapshot)bigintget xmax of snapshot
txid_snapshot_xmin(txid_snapshot)bigintget xmin of snapshot
txid_visible_in_snapshot(bigint, txid_snapshot)booleanis transaction ID visible in snapshot? (do not use with subtransaction ids)

The internal transaction ID type (xid) is 32 bits wide and + wraps around every 4 billion transactions. However, these functions + export a 64-bit format that is extended with an "epoch" counter + so it will not wrap around during the life of an installation. + The data type used by these functions, txid_snapshot, + stores information about transaction ID + visibility at a particular moment in time. Its components are + described in Table 9-56. +

Table 9-56. Snapshot Components

NameDescription
xmin Earliest transaction ID (txid) that is still active. All earlier + transactions will either be committed and visible, or rolled + back and dead. +
xmax First as-yet-unassigned txid. All txids greater than or equal to this + are not yet started as of the time of the snapshot, and thus invisible. +
xip_list Active txids at the time of the snapshot. The list + includes only those active txids between xmin + and xmax; there might be active txids higher + than xmax. A txid that is xmin <= txid < + xmax and not in this list was already completed + at the time of the snapshot, and thus either visible or + dead according to its commit status. The list does not + include txids of subtransactions. +

txid_snapshot's textual representation is + xmin:xmax:xip_list. + For example 10:20:10,14,15 means + xmin=10, xmax=20, xip_list=10, 14, 15. +


PrevHomeNext
Set Returning FunctionsUpSystem Administration Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-json.html b/doc/src/sgml/html/functions-json.html new file mode 100644 index 000000000..80771c08b --- /dev/null +++ b/doc/src/sgml/html/functions-json.html @@ -0,0 +1,254 @@ + +JSON Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.15. JSON Functions

Table 9-39 shows the functions that are available + for creating JSON (see Section 8.14) data. +

Table 9-39. JSON Support Functions

FunctionDescriptionExampleExample Result
+ array_to_json(anyarray [, pretty_bool]) + Returns the array as JSON. A PostgreSQL multidimensional array + becomes a JSON array of arrays. Line feeds will be added between + dimension 1 elements if pretty_bool is true. + array_to_json('{{1,5},{99,100}}'::int[])[[1,5],[99,100]]
+ row_to_json(record [, pretty_bool]) + Returns the row as JSON. Line feeds will be added between level + 1 elements if pretty_bool is true. + row_to_json(row(1,'foo')){"f1":1,"f2":"foo"}

PrevHomeNext
XML FunctionsUpSequence Manipulation Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-logical.html b/doc/src/sgml/html/functions-logical.html new file mode 100644 index 000000000..56dd2285a --- /dev/null +++ b/doc/src/sgml/html/functions-logical.html @@ -0,0 +1,412 @@ + +Logical Operators
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.1. Logical Operators

The usual logical operators are available: + + + + + + + + + + + + + +

AND
OR
NOT

+ + SQL uses a three-valued logic system with true, + false, and null, which represents "unknown". + Observe the following truth tables: + +

aba AND ba OR b
TRUETRUETRUETRUE
TRUEFALSEFALSETRUE
TRUENULLNULLTRUE
FALSEFALSEFALSEFALSE
FALSENULLFALSENULL
NULLNULLNULLNULL

+ +

aNOT a
TRUEFALSE
FALSETRUE
NULLNULL

+

The operators AND and OR are + commutative, that is, you can switch the left and right operand + without affecting the result. But see Section 4.2.14 for more information about the + order of evaluation of subexpressions. +


PrevHomeNext
Functions and OperatorsUpComparison Operators
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-matching.html b/doc/src/sgml/html/functions-matching.html new file mode 100644 index 000000000..aa4d29fa6 --- /dev/null +++ b/doc/src/sgml/html/functions-matching.html @@ -0,0 +1,4381 @@ + +Pattern Matching
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.7. Pattern Matching

There are three separate approaches to pattern matching provided + by PostgreSQL: the traditional + SQL LIKE operator, the + more recent SIMILAR TO operator (added in + SQL:1999), and POSIX-style regular + expressions. Aside from the basic "does this string match + this pattern?" operators, functions are available to extract + or replace matching substrings and to split a string at matching + locations. +

Tip: If you have pattern matching needs that go beyond this, + consider writing a user-defined function in Perl or Tcl. +

9.7.1. LIKE

string LIKE pattern [ESCAPE escape-character]
+string NOT LIKE pattern [ESCAPE escape-character]

The LIKE expression returns true if the + string matches the supplied + pattern. (As + expected, the NOT LIKE expression returns + false if LIKE returns true, and vice versa. + An equivalent expression is + NOT (string LIKE + pattern).) +

If pattern does not contain percent + signs or underscores, then the pattern only represents the string + itself; in that case LIKE acts like the + equals operator. An underscore (_) in + pattern stands for (matches) any single + character; a percent sign (%) matches any sequence + of zero or more characters. +

Some examples: +

'abc' LIKE 'abc'    true
+'abc' LIKE 'a%'     true
+'abc' LIKE '_b_'    true
+'abc' LIKE 'c'      false

+

LIKE pattern matching always covers the entire + string. Therefore, if it's desired to match a sequence anywhere within + a string, the pattern must start and end with a percent sign. +

To match a literal underscore or percent sign without matching + other characters, the respective character in + pattern must be + preceded by the escape character. The default escape + character is the backslash but a different one can be selected by + using the ESCAPE clause. To match the escape + character itself, write two escape characters. +

Note: If you have standard_conforming_strings turned off, + any backslashes you write in literal string constants will need to be + doubled. See Section 4.1.2.1 for more information. +

It's also possible to select no escape character by writing + ESCAPE ''. This effectively disables the + escape mechanism, which makes it impossible to turn off the + special meaning of underscore and percent signs in the pattern. +

The key word ILIKE can be used instead of + LIKE to make the match case-insensitive according + to the active locale. This is not in the SQL standard but is a + PostgreSQL extension. +

The operator ~~ is equivalent to + LIKE, and ~~* corresponds to + ILIKE. There are also + !~~ and !~~* operators that + represent NOT LIKE and NOT + ILIKE, respectively. All of these operators are + PostgreSQL-specific. +

9.7.2. SIMILAR TO Regular Expressions

string SIMILAR TO pattern [ESCAPE escape-character]
+string NOT SIMILAR TO pattern [ESCAPE escape-character]

The SIMILAR TO operator returns true or + false depending on whether its pattern matches the given string. + It is similar to LIKE, except that it + interprets the pattern using the SQL standard's definition of a + regular expression. SQL regular expressions are a curious cross + between LIKE notation and common regular + expression notation. +

Like LIKE, the SIMILAR TO + operator succeeds only if its pattern matches the entire string; + this is unlike common regular expression behavior where the pattern + can match any part of the string. + Also like + LIKE, SIMILAR TO uses + _ and % as wildcard characters denoting + any single character and any string, respectively (these are + comparable to . and .* in POSIX regular + expressions). +

In addition to these facilities borrowed from LIKE, + SIMILAR TO supports these pattern-matching + metacharacters borrowed from POSIX regular expressions: + +

  • | denotes alternation (either of two alternatives). +

  • * denotes repetition of the previous item zero + or more times. +

  • + denotes repetition of the previous item one + or more times. +

  • ? denotes repetition of the previous item zero + or one time. +

  • {m} denotes repetition + of the previous item exactly m times. +

  • {m,} denotes repetition + of the previous item m or more times. +

  • {m,n} + denotes repetition of the previous item at least m and + not more than n times. +

  • Parentheses () can be used to group items into + a single logical item. +

  • A bracket expression [...] specifies a character + class, just as in POSIX regular expressions. +

+ + Notice that the period (.) is not a metacharacter + for SIMILAR TO. +

As with LIKE, a backslash disables the special meaning + of any of these metacharacters; or a different escape character can + be specified with ESCAPE. +

Some examples: +

'abc' SIMILAR TO 'abc'      true
+'abc' SIMILAR TO 'a'        false
+'abc' SIMILAR TO '%(b|d)%'  true
+'abc' SIMILAR TO '(b|c)%'   false

+

The substring function with three parameters, + substring(string from + pattern for + escape-character), provides + extraction of a substring that matches an SQL + regular expression pattern. As with SIMILAR TO, the + specified pattern must match the entire data string, or else the + function fails and returns null. To indicate the part of the + pattern that should be returned on success, the pattern must contain + two occurrences of the escape character followed by a double quote + ("). + The text matching the portion of the pattern + between these markers is returned. +

Some examples, with #" delimiting the return string: +

substring('foobar' from '%#"o_b#"%' for '#')   oob
+substring('foobar' from '#"o_b#"%' for '#')    NULL

+

9.7.3. POSIX Regular Expressions

Table 9-11 lists the available + operators for pattern matching using POSIX regular expressions. +

Table 9-11. Regular Expression Match Operators

OperatorDescriptionExample
~ Matches regular expression, case sensitive'thomas' ~ '.*thomas.*'
~* Matches regular expression, case insensitive'thomas' ~* '.*Thomas.*'
!~ Does not match regular expression, case sensitive'thomas' !~ '.*Thomas.*'
!~* Does not match regular expression, case insensitive'thomas' !~* '.*vadim.*'

POSIX regular expressions provide a more + powerful means for pattern matching than the LIKE and + SIMILAR TO operators. + Many Unix tools such as egrep, + sed, or awk use a pattern + matching language that is similar to the one described here. +

A regular expression is a character sequence that is an + abbreviated definition of a set of strings (a regular + set). A string is said to match a regular expression + if it is a member of the regular set described by the regular + expression. As with LIKE, pattern characters + match string characters exactly unless they are special characters + in the regular expression language — but regular expressions use + different special characters than LIKE does. + Unlike LIKE patterns, a + regular expression is allowed to match anywhere within a string, unless + the regular expression is explicitly anchored to the beginning or + end of the string. +

Some examples: +

'abc' ~ 'abc'    true
+'abc' ~ '^a'     true
+'abc' ~ '(b|d)'  true
+'abc' ~ '^(b|c)' false

+

The POSIX pattern language is described in much + greater detail below. +

The substring function with two parameters, + substring(string from + pattern), provides extraction of a + substring + that matches a POSIX regular expression pattern. It returns null if + there is no match, otherwise the portion of the text that matched the + pattern. But if the pattern contains any parentheses, the portion + of the text that matched the first parenthesized subexpression (the + one whose left parenthesis comes first) is + returned. You can put parentheses around the whole expression + if you want to use parentheses within it without triggering this + exception. If you need parentheses in the pattern before the + subexpression you want to extract, see the non-capturing parentheses + described below. +

Some examples: +

substring('foobar' from 'o.b')     oob
+substring('foobar' from 'o(.)b')   o

+

The regexp_replace function provides substitution of + new text for substrings that match POSIX regular expression patterns. + It has the syntax + regexp_replace(source, + pattern, replacement + [, flags ]). + The source string is returned unchanged if + there is no match to the pattern. If there is a + match, the source string is returned with the + replacement string substituted for the matching + substring. The replacement string can contain + \n, where n is 1 + through 9, to indicate that the source substring matching the + n'th parenthesized subexpression of the pattern should be + inserted, and it can contain \& to indicate that the + substring matching the entire pattern should be inserted. Write + \\ if you need to put a literal backslash in the replacement + text. + The flags parameter is an optional text + string containing zero or more single-letter flags that change the + function's behavior. Flag i specifies case-insensitive + matching, while flag g specifies replacement of each matching + substring rather than only the first one. Other supported flags are + described in Table 9-19. +

Some examples: +

regexp_replace('foobarbaz', 'b..', 'X')
+                                   fooXbaz
+regexp_replace('foobarbaz', 'b..', 'X', 'g')
+                                   fooXX
+regexp_replace('foobarbaz', 'b(..)', E'X\\1Y', 'g')
+                                   fooXarYXazY

+

The regexp_matches function returns a text array of + all of the captured substrings resulting from matching a POSIX + regular expression pattern. It has the syntax + regexp_matches(string, pattern + [, flags ]). + The function can return no rows, one row, or multiple rows (see + the g flag below). If the pattern + does not match, the function returns no rows. If the pattern + contains no parenthesized subexpressions, then each row + returned is a single-element text array containing the substring + matching the whole pattern. If the pattern contains parenthesized + subexpressions, the function returns a text array whose + n'th element is the substring matching the + n'th parenthesized subexpression of the pattern + (not counting "non-capturing" parentheses; see below for + details). + The flags parameter is an optional text + string containing zero or more single-letter flags that change the + function's behavior. Flag g causes the function to find + each match in the string, not only the first one, and return a row for + each such match. Other supported + flags are described in Table 9-19. +

Some examples: +

SELECT regexp_matches('foobarbequebaz', '(bar)(beque)');
+ regexp_matches 
+----------------
+ {bar,beque}
+(1 row)
+
+SELECT regexp_matches('foobarbequebazilbarfbonk', '(b[^b]+)(b[^b]+)', 'g');
+ regexp_matches 
+----------------
+ {bar,beque}
+ {bazil,barf}
+(2 rows)
+
+SELECT regexp_matches('foobarbequebaz', 'barbeque');
+ regexp_matches 
+----------------
+ {barbeque}
+(1 row)

+

It is possible to force regexp_matches() to always + return one row by using a sub-select; this is particularly useful + in a SELECT target list when you want all rows + returned, even non-matching ones: +

SELECT col1, (SELECT regexp_matches(col2, '(bar)(beque)')) FROM tab;

+

The regexp_split_to_table function splits a string using a POSIX + regular expression pattern as a delimiter. It has the syntax + regexp_split_to_table(string, pattern + [, flags ]). + If there is no match to the pattern, the function returns the + string. If there is at least one match, for each match it returns + the text from the end of the last match (or the beginning of the string) + to the beginning of the match. When there are no more matches, it + returns the text from the end of the last match to the end of the string. + The flags parameter is an optional text string containing + zero or more single-letter flags that change the function's behavior. + regexp_split_to_table supports the flags described in + Table 9-19. +

The regexp_split_to_array function behaves the same as + regexp_split_to_table, except that regexp_split_to_array + returns its result as an array of text. It has the syntax + regexp_split_to_array(string, pattern + [, flags ]). + The parameters are the same as for regexp_split_to_table. +

Some examples: +


SELECT foo FROM regexp_split_to_table('the quick brown fox jumped over the lazy dog', E'\\s+') AS foo;
+  foo   
+--------
+ the    
+ quick  
+ brown  
+ fox    
+ jumped 
+ over   
+ the    
+ lazy   
+ dog    
+(9 rows)
+
+SELECT regexp_split_to_array('the quick brown fox jumped over the lazy dog', E'\\s+');
+              regexp_split_to_array             
+------------------------------------------------
+ {the,quick,brown,fox,jumped,over,the,lazy,dog}
+(1 row)
+
+SELECT foo FROM regexp_split_to_table('the quick brown fox', E'\\s*') AS foo;
+ foo 
+-----
+ t         
+ h         
+ e         
+ q         
+ u         
+ i         
+ c         
+ k         
+ b         
+ r         
+ o         
+ w         
+ n         
+ f         
+ o         
+ x         
+(16 rows)

+

As the last example demonstrates, the regexp split functions ignore + zero-length matches that occur at the start or end of the string + or immediately after a previous match. This is contrary to the strict + definition of regexp matching that is implemented by + regexp_matches, but is usually the most convenient behavior + in practice. Other software systems such as Perl use similar definitions. +

9.7.3.1. Regular Expression Details

PostgreSQL's regular expressions are implemented + using a software package written by Henry Spencer. Much of + the description of regular expressions below is copied verbatim from his + manual. +

Regular expressions (REs), as defined in + POSIX 1003.2, come in two forms: + extended REs or EREs + (roughly those of egrep), and + basic REs or BREs + (roughly those of ed). + PostgreSQL supports both forms, and + also implements some extensions + that are not in the POSIX standard, but have become widely used + due to their availability in programming languages such as Perl and Tcl. + REs using these non-POSIX extensions are called + advanced REs or AREs + in this documentation. AREs are almost an exact superset of EREs, + but BREs have several notational incompatibilities (as well as being + much more limited). + We first describe the ARE and ERE forms, noting features that apply + only to AREs, and then describe how BREs differ. +

Note: PostgreSQL always initially presumes that a regular + expression follows the ARE rules. However, the more limited ERE or + BRE rules can be chosen by prepending an embedded option + to the RE pattern, as described in Section 9.7.3.4. + This can be useful for compatibility with applications that expect + exactly the POSIX 1003.2 rules. +

A regular expression is defined as one or more + branches, separated by + |. It matches anything that matches one of the + branches. +

A branch is zero or more quantified atoms or + constraints, concatenated. + It matches a match for the first, followed by a match for the second, etc; + an empty branch matches the empty string. +

A quantified atom is an atom possibly followed + by a single quantifier. + Without a quantifier, it matches a match for the atom. + With a quantifier, it can match some number of matches of the atom. + An atom can be any of the possibilities + shown in Table 9-12. + The possible quantifiers and their meanings are shown in + Table 9-13. +

A constraint matches an empty string, but matches only when + specific conditions are met. A constraint can be used where an atom + could be used, except it cannot be followed by a quantifier. + The simple constraints are shown in + Table 9-14; + some more constraints are described later. +

Table 9-12. Regular Expression Atoms

AtomDescription
(re) (where re is any regular expression) + matches a match for + re, with the match noted for possible reporting
(?:re) as above, but the match is not noted for reporting + (a "non-capturing" set of parentheses) + (AREs only)
. matches any single character
[chars] a bracket expression, + matching any one of the chars (see + Section 9.7.3.2 for more detail)
\k (where k is a non-alphanumeric character) + matches that character taken as an ordinary character, + e.g., \\ matches a backslash character
\c where c is alphanumeric + (possibly followed by other characters) + is an escape, see Section 9.7.3.3 + (AREs only; in EREs and BREs, this matches c)
{ when followed by a character other than a digit, + matches the left-brace character {; + when followed by a digit, it is the beginning of a + bound (see below)
x where x is a single character with no other + significance, matches that character

An RE cannot end with a backslash (\). +

Note: If you have standard_conforming_strings turned off, + any backslashes you write in literal string constants will need to be + doubled. See Section 4.1.2.1 for more information. +

Table 9-13. Regular Expression Quantifiers

QuantifierMatches
* a sequence of 0 or more matches of the atom
+ a sequence of 1 or more matches of the atom
? a sequence of 0 or 1 matches of the atom
{m} a sequence of exactly m matches of the atom
{m,} a sequence of m or more matches of the atom
{m,n} a sequence of m through n + (inclusive) matches of the atom; m cannot exceed + n
*? non-greedy version of *
+? non-greedy version of +
?? non-greedy version of ?
{m}? non-greedy version of {m}
{m,}? non-greedy version of {m,}
{m,n}? non-greedy version of {m,n}

The forms using {...} + are known as bounds. + The numbers m and n within a bound are + unsigned decimal integers with permissible values from 0 to 255 inclusive. +

Non-greedy quantifiers (available in AREs only) match the + same possibilities as their corresponding normal (greedy) + counterparts, but prefer the smallest number rather than the largest + number of matches. + See Section 9.7.3.5 for more detail. +

Note: A quantifier cannot immediately follow another quantifier, e.g., + ** is invalid. + A quantifier cannot + begin an expression or subexpression or follow + ^ or |. +

Table 9-14. Regular Expression Constraints

ConstraintDescription
^ matches at the beginning of the string
$ matches at the end of the string
(?=re) positive lookahead matches at any point + where a substring matching re begins + (AREs only)
(?!re) negative lookahead matches at any point + where no substring matching re begins + (AREs only)

Lookahead constraints cannot contain back references + (see Section 9.7.3.3), + and all parentheses within them are considered non-capturing. +

9.7.3.2. Bracket Expressions

A bracket expression is a list of + characters enclosed in []. It normally matches + any single character from the list (but see below). If the list + begins with ^, it matches any single character + not from the rest of the list. + If two characters + in the list are separated by -, this is + shorthand for the full range of characters between those two + (inclusive) in the collating sequence, + e.g., [0-9] in ASCII matches + any decimal digit. It is illegal for two ranges to share an + endpoint, e.g., a-c-e. Ranges are very + collating-sequence-dependent, so portable programs should avoid + relying on them. +

To include a literal ] in the list, make it the + first character (after ^, if that is used). To + include a literal -, make it the first or last + character, or the second endpoint of a range. To use a literal + - as the first endpoint of a range, enclose it + in [. and .] to make it a + collating element (see below). With the exception of these characters, + some combinations using [ + (see next paragraphs), and escapes (AREs only), all other special + characters lose their special significance within a bracket expression. + In particular, \ is not special when following + ERE or BRE rules, though it is special (as introducing an escape) + in AREs. +

Within a bracket expression, a collating element (a character, a + multiple-character sequence that collates as if it were a single + character, or a collating-sequence name for either) enclosed in + [. and .] stands for the + sequence of characters of that collating element. The sequence is + treated as a single element of the bracket expression's list. This + allows a bracket + expression containing a multiple-character collating element to + match more than one character, e.g., if the collating sequence + includes a ch collating element, then the RE + [[.ch.]]*c matches the first five characters of + chchcc. +

Note: PostgreSQL currently does not support multi-character collating + elements. This information describes possible future behavior. +

Within a bracket expression, a collating element enclosed in + [= and =] is an equivalence + class, standing for the sequences of characters of all collating + elements equivalent to that one, including itself. (If there are + no other equivalent collating elements, the treatment is as if the + enclosing delimiters were [. and + .].) For example, if o and + ^ are the members of an equivalence class, then + [[=o=]], [[=^=]], and + [o^] are all synonymous. An equivalence class + cannot be an endpoint of a range. +

Within a bracket expression, the name of a character class + enclosed in [: and :] stands + for the list of all characters belonging to that class. Standard + character class names are: alnum, + alpha, blank, + cntrl, digit, + graph, lower, + print, punct, + space, upper, + xdigit. These stand for the character classes + defined in + ctype. + A locale can provide others. A character class cannot be used as + an endpoint of a range. +

There are two special cases of bracket expressions: the bracket + expressions [[:<:]] and + [[:>:]] are constraints, + matching empty strings at the beginning + and end of a word respectively. A word is defined as a sequence + of word characters that is neither preceded nor followed by word + characters. A word character is an alnum character (as + defined by + ctype) + or an underscore. This is an extension, compatible with but not + specified by POSIX 1003.2, and should be used with + caution in software intended to be portable to other systems. + The constraint escapes described below are usually preferable; they + are no more standard, but are easier to type. +

9.7.3.3. Regular Expression Escapes

Escapes are special sequences beginning with \ + followed by an alphanumeric character. Escapes come in several varieties: + character entry, class shorthands, constraint escapes, and back references. + A \ followed by an alphanumeric character but not constituting + a valid escape is illegal in AREs. + In EREs, there are no escapes: outside a bracket expression, + a \ followed by an alphanumeric character merely stands for + that character as an ordinary character, and inside a bracket expression, + \ is an ordinary character. + (The latter is the one actual incompatibility between EREs and AREs.) +

Character-entry escapes exist to make it easier to specify + non-printing and other inconvenient characters in REs. They are + shown in Table 9-15. +

Class-shorthand escapes provide shorthands for certain + commonly-used character classes. They are + shown in Table 9-16. +

A constraint escape is a constraint, + matching the empty string if specific conditions are met, + written as an escape. They are + shown in Table 9-17. +

A back reference (\n) matches the + same string matched by the previous parenthesized subexpression specified + by the number n + (see Table 9-18). For example, + ([bc])\1 matches bb or cc + but not bc or cb. + The subexpression must entirely precede the back reference in the RE. + Subexpressions are numbered in the order of their leading parentheses. + Non-capturing parentheses do not define subexpressions. +

Note: Keep in mind that an escape's leading \ will need to be + doubled when entering the pattern as an SQL string constant. For example: +

'123' ~ E'^\\d{3}' true

+

Table 9-15. Regular Expression Character-entry Escapes

EscapeDescription
\a alert (bell) character, as in C
\b backspace, as in C
\B synonym for backslash (\) to help reduce the need for backslash + doubling
\cX (where X is any character) the character whose + low-order 5 bits are the same as those of + X, and whose other bits are all zero
\e the character whose collating-sequence name + is ESC, + or failing that, the character with octal value 033
\f form feed, as in C
\n newline, as in C
\r carriage return, as in C
\t horizontal tab, as in C
\uwxyz (where wxyz is exactly four hexadecimal digits) + the UTF16 (Unicode, 16-bit) character U+wxyz + in the local byte ordering
\Ustuvwxyz (where stuvwxyz is exactly eight hexadecimal + digits) + reserved for a hypothetical Unicode extension to 32 bits +
\v vertical tab, as in C
\xhhh (where hhh is any sequence of hexadecimal + digits) + the character whose hexadecimal value is + 0xhhh + (a single character no matter how many hexadecimal digits are used) +
\0 the character whose value is 0 (the null byte)
\xy (where xy is exactly two octal digits, + and is not a back reference) + the character whose octal value is + 0xy
\xyz (where xyz is exactly three octal digits, + and is not a back reference) + the character whose octal value is + 0xyz

Hexadecimal digits are 0-9, + a-f, and A-F. + Octal digits are 0-7. +

The character-entry escapes are always taken as ordinary characters. + For example, \135 is ] in ASCII, but + \135 does not terminate a bracket expression. +

Table 9-16. Regular Expression Class-shorthand Escapes

EscapeDescription
\d [[:digit:]]
\s [[:space:]]
\w [[:alnum:]_] + (note underscore is included)
\D [^[:digit:]]
\S [^[:space:]]
\W [^[:alnum:]_] + (note underscore is included)

Within bracket expressions, \d, \s, + and \w lose their outer brackets, + and \D, \S, and \W are illegal. + (So, for example, [a-c\d] is equivalent to + [a-c[:digit:]]. + Also, [a-c\D], which is equivalent to + [a-c^[:digit:]], is illegal.) +

Table 9-17. Regular Expression Constraint Escapes

EscapeDescription
\A matches only at the beginning of the string + (see Section 9.7.3.5 for how this differs from + ^)
\m matches only at the beginning of a word
\M matches only at the end of a word
\y matches only at the beginning or end of a word
\Y matches only at a point that is not the beginning or end of a + word
\Z matches only at the end of the string + (see Section 9.7.3.5 for how this differs from + $)

A word is defined as in the specification of + [[:<:]] and [[:>:]] above. + Constraint escapes are illegal within bracket expressions. +

Table 9-18. Regular Expression Back References

EscapeDescription
\m (where m is a nonzero digit) + a back reference to the m'th subexpression
\mnn (where m is a nonzero digit, and + nn is some more digits, and the decimal value + mnn is not greater than the number of closing capturing + parentheses seen so far) + a back reference to the mnn'th subexpression

Note: There is an inherent ambiguity between octal character-entry + escapes and back references, which is resolved by the following heuristics, + as hinted at above. + A leading zero always indicates an octal escape. + A single non-zero digit, not followed by another digit, + is always taken as a back reference. + A multi-digit sequence not starting with a zero is taken as a back + reference if it comes after a suitable subexpression + (i.e., the number is in the legal range for a back reference), + and otherwise is taken as octal. +

9.7.3.4. Regular Expression Metasyntax

In addition to the main syntax described above, there are some special + forms and miscellaneous syntactic facilities available. +

An RE can begin with one of two special director prefixes. + If an RE begins with ***:, + the rest of the RE is taken as an ARE. (This normally has no effect in + PostgreSQL, since REs are assumed to be AREs; + but it does have an effect if ERE or BRE mode had been specified by + the flags parameter to a regex function.) + If an RE begins with ***=, + the rest of the RE is taken to be a literal string, + with all characters considered ordinary characters. +

An ARE can begin with embedded options: + a sequence (?xyz) + (where xyz is one or more alphabetic characters) + specifies options affecting the rest of the RE. + These options override any previously determined options — + in particular, they can override the case-sensitivity behavior implied by + a regex operator, or the flags parameter to a regex + function. + The available option letters are + shown in Table 9-19. + Note that these same option letters are used in the flags + parameters of regex functions. +

Table 9-19. ARE Embedded-option Letters

OptionDescription
b rest of RE is a BRE
c case-sensitive matching (overrides operator type)
e rest of RE is an ERE
i case-insensitive matching (see + Section 9.7.3.5) (overrides operator type)
m historical synonym for n
n newline-sensitive matching (see + Section 9.7.3.5)
p partial newline-sensitive matching (see + Section 9.7.3.5)
q rest of RE is a literal ("quoted") string, all ordinary + characters
s non-newline-sensitive matching (default)
t tight syntax (default; see below)
w inverse partial newline-sensitive ("weird") matching + (see Section 9.7.3.5)
x expanded syntax (see below)

Embedded options take effect at the ) terminating the sequence. + They can appear only at the start of an ARE (after the + ***: director if any). +

In addition to the usual (tight) RE syntax, in which all + characters are significant, there is an expanded syntax, + available by specifying the embedded x option. + In the expanded syntax, + white-space characters in the RE are ignored, as are + all characters between a # + and the following newline (or the end of the RE). This + permits paragraphing and commenting a complex RE. + There are three exceptions to that basic rule: + +

  • a white-space character or # preceded by \ is + retained +

  • white space or # within a bracket expression is retained +

  • white space and comments cannot appear within multi-character symbols, + such as (?: +

+ + For this purpose, white-space characters are blank, tab, newline, and + any character that belongs to the space character class. +

Finally, in an ARE, outside bracket expressions, the sequence + (?#ttt) + (where ttt is any text not containing a )) + is a comment, completely ignored. + Again, this is not allowed between the characters of + multi-character symbols, like (?:. + Such comments are more a historical artifact than a useful facility, + and their use is deprecated; use the expanded syntax instead. +

None of these metasyntax extensions is available if + an initial ***= director + has specified that the user's input be treated as a literal string + rather than as an RE. +

9.7.3.5. Regular Expression Matching Rules

In the event that an RE could match more than one substring of a given + string, the RE matches the one starting earliest in the string. + If the RE could match more than one substring starting at that point, + either the longest possible match or the shortest possible match will + be taken, depending on whether the RE is greedy or + non-greedy. +

Whether an RE is greedy or not is determined by the following rules: +

  • Most atoms, and all constraints, have no greediness attribute (because + they cannot match variable amounts of text anyway). +

  • Adding parentheses around an RE does not change its greediness. +

  • A quantified atom with a fixed-repetition quantifier + ({m} + or + {m}?) + has the same greediness (possibly none) as the atom itself. +

  • A quantified atom with other normal quantifiers (including + {m,n} + with m equal to n) + is greedy (prefers longest match). +

  • A quantified atom with a non-greedy quantifier (including + {m,n}? + with m equal to n) + is non-greedy (prefers shortest match). +

  • A branch — that is, an RE that has no top-level + | operator — has the same greediness as the first + quantified atom in it that has a greediness attribute. +

  • An RE consisting of two or more branches connected by the + | operator is always greedy. +

+

The above rules associate greediness attributes not only with individual + quantified atoms, but with branches and entire REs that contain quantified + atoms. What that means is that the matching is done in such a way that + the branch, or whole RE, matches the longest or shortest possible + substring as a whole. Once the length of the entire match + is determined, the part of it that matches any particular subexpression + is determined on the basis of the greediness attribute of that + subexpression, with subexpressions starting earlier in the RE taking + priority over ones starting later. +

An example of what this means: +

SELECT SUBSTRING('XY1234Z', 'Y*([0-9]{1,3})');
+Result: 123
+SELECT SUBSTRING('XY1234Z', 'Y*?([0-9]{1,3})');
+Result: 1

+ In the first case, the RE as a whole is greedy because Y* + is greedy. It can match beginning at the Y, and it matches + the longest possible string starting there, i.e., Y123. + The output is the parenthesized part of that, or 123. + In the second case, the RE as a whole is non-greedy because Y*? + is non-greedy. It can match beginning at the Y, and it matches + the shortest possible string starting there, i.e., Y1. + The subexpression [0-9]{1,3} is greedy but it cannot change + the decision as to the overall match length; so it is forced to match + just 1. +

In short, when an RE contains both greedy and non-greedy subexpressions, + the total match length is either as long as possible or as short as + possible, according to the attribute assigned to the whole RE. The + attributes assigned to the subexpressions only affect how much of that + match they are allowed to "eat" relative to each other. +

The quantifiers {1,1} and {1,1}? + can be used to force greediness or non-greediness, respectively, + on a subexpression or a whole RE. +

Match lengths are measured in characters, not collating elements. + An empty string is considered longer than no match at all. + For example: + bb* + matches the three middle characters of abbbc; + (week|wee)(night|knights) + matches all ten characters of weeknights; + when (.*).* + is matched against abc the parenthesized subexpression + matches all three characters; and when + (a*)* is matched against bc + both the whole RE and the parenthesized + subexpression match an empty string. +

If case-independent matching is specified, + the effect is much as if all case distinctions had vanished from the + alphabet. + When an alphabetic that exists in multiple cases appears as an + ordinary character outside a bracket expression, it is effectively + transformed into a bracket expression containing both cases, + e.g., x becomes [xX]. + When it appears inside a bracket expression, all case counterparts + of it are added to the bracket expression, e.g., + [x] becomes [xX] + and [^x] becomes [^xX]. +

If newline-sensitive matching is specified, . + and bracket expressions using ^ + will never match the newline character + (so that matches will never cross newlines unless the RE + explicitly arranges it) + and ^and $ + will match the empty string after and before a newline + respectively, in addition to matching at beginning and end of string + respectively. + But the ARE escapes \A and \Z + continue to match beginning or end of string only. +

If partial newline-sensitive matching is specified, + this affects . and bracket expressions + as with newline-sensitive matching, but not ^ + and $. +

If inverse partial newline-sensitive matching is specified, + this affects ^ and $ + as with newline-sensitive matching, but not . + and bracket expressions. + This isn't very useful but is provided for symmetry. +

9.7.3.6. Limits and Compatibility

No particular limit is imposed on the length of REs in this + implementation. However, + programs intended to be highly portable should not employ REs longer + than 256 bytes, + as a POSIX-compliant implementation can refuse to accept such REs. +

The only feature of AREs that is actually incompatible with + POSIX EREs is that \ does not lose its special + significance inside bracket expressions. + All other ARE features use syntax which is illegal or has + undefined or unspecified effects in POSIX EREs; + the *** syntax of directors likewise is outside the POSIX + syntax for both BREs and EREs. +

Many of the ARE extensions are borrowed from Perl, but some have + been changed to clean them up, and a few Perl extensions are not present. + Incompatibilities of note include \b, \B, + the lack of special treatment for a trailing newline, + the addition of complemented bracket expressions to the things + affected by newline-sensitive matching, + the restrictions on parentheses and back references in lookahead + constraints, and the longest/shortest-match (rather than first-match) + matching semantics. +

Two significant incompatibilities exist between AREs and the ERE syntax + recognized by pre-7.4 releases of PostgreSQL: + +

  • In AREs, \ followed by an alphanumeric character is either + an escape or an error, while in previous releases, it was just another + way of writing the alphanumeric. + This should not be much of a problem because there was no reason to + write such a sequence in earlier releases. +

  • In AREs, \ remains a special character within + [], so a literal \ within a bracket + expression must be written \\. +

+

9.7.3.7. Basic Regular Expressions

BREs differ from EREs in several respects. + In BREs, |, +, and ? + are ordinary characters and there is no equivalent + for their functionality. + The delimiters for bounds are + \{ and \}, + with { and } + by themselves ordinary characters. + The parentheses for nested subexpressions are + \( and \), + with ( and ) by themselves ordinary characters. + ^ is an ordinary character except at the beginning of the + RE or the beginning of a parenthesized subexpression, + $ is an ordinary character except at the end of the + RE or the end of a parenthesized subexpression, + and * is an ordinary character if it appears at the beginning + of the RE or the beginning of a parenthesized subexpression + (after a possible leading ^). + Finally, single-digit back references are available, and + \< and \> + are synonyms for + [[:<:]] and [[:>:]] + respectively; no other escapes are available in BREs. +


PrevHomeNext
Bit String Functions and OperatorsUpData Type Formatting Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-math.html b/doc/src/sgml/html/functions-math.html new file mode 100644 index 000000000..bcf264010 --- /dev/null +++ b/doc/src/sgml/html/functions-math.html @@ -0,0 +1,1803 @@ + +Mathematical Functions and Operators
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.3. Mathematical Functions and Operators

Mathematical operators are provided for many + PostgreSQL types. For types without + standard mathematical conventions + (e.g., date/time types) we + describe the actual behavior in subsequent sections. +

Table 9-2 shows the available mathematical operators. +

Table 9-2. Mathematical Operators

OperatorDescriptionExampleResult
+ addition2 + 35
- subtraction2 - 3-1
* multiplication2 * 36
/ division (integer division truncates the result)4 / 22
% modulo (remainder)5 % 41
^ exponentiation2.0 ^ 3.08
|/ square root|/ 25.05
||/ cube root||/ 27.03
! factorial5 !120
!! factorial (prefix operator)!! 5120
@ absolute value@ -5.05
& bitwise AND91 & 1511
| bitwise OR32 | 335
# bitwise XOR17 # 520
~ bitwise NOT~1-2
<< bitwise shift left1 << 416
>> bitwise shift right8 >> 22

The bitwise operators work only on integral data types, whereas + the others are available for all numeric data types. The bitwise + operators are also available for the bit + string types bit and bit varying, as + shown in Table 9-10. +

Table 9-3 shows the available + mathematical functions. In the table, dp + indicates double precision. Many of these functions + are provided in multiple forms with different argument types. + Except where noted, any given form of a function returns the same + data type as its argument. + The functions working with double precision data are mostly + implemented on top of the host system's C library; accuracy and behavior in + boundary cases can therefore vary depending on the host system. +

Table 9-3. Mathematical Functions

FunctionReturn TypeDescriptionExampleResult
+ abs(x) + (same as input)absolute valueabs(-17.4)17.4
+ cbrt(dp) + dpcube rootcbrt(27.0)3
+ ceil(dp or numeric) + (same as input)smallest integer not less than argumentceil(-42.8)-42
+ ceiling(dp or numeric) + (same as input)smallest integer not less than argument (alias for ceil)ceiling(-95.3)-95
+ degrees(dp) + dpradians to degreesdegrees(0.5)28.6478897565412
+ div(y numeric, + x numeric) + numericinteger quotient of y/xdiv(9,4)2
+ exp(dp or numeric) + (same as input)exponentialexp(1.0)2.71828182845905
+ floor(dp or numeric) + (same as input)largest integer not greater than argumentfloor(-42.8)-43
+ ln(dp or numeric) + (same as input)natural logarithmln(2.0)0.693147180559945
+ log(dp or numeric) + (same as input)base 10 logarithmlog(100.0)2
log(b numeric, + x numeric)numericlogarithm to base blog(2.0, 64.0)6.0000000000
+ mod(y, + x) + (same as argument types)remainder of y/xmod(9,4)1
+ pi() + dp"π" constantpi()3.14159265358979
+ power(a dp, + b dp) + dpa raised to the power of bpower(9.0, 3.0)729
power(a numeric, + b numeric)numerica raised to the power of bpower(9.0, 3.0)729
+ radians(dp) + dpdegrees to radiansradians(45.0)0.785398163397448
+ random() + dprandom value in the range 0.0 <= x < 1.0random() 
+ round(dp or numeric) + (same as input)round to nearest integerround(42.4)42
round(v numeric, s int)numericround to s decimal placesround(42.4382, 2)42.44
+ setseed(dp) + voidset seed for subsequent random() calls (value between -1.0 and + 1.0, inclusive)setseed(0.54823) 
+ sign(dp or numeric) + (same as input)sign of the argument (-1, 0, +1)sign(-8.4)-1
+ sqrt(dp or numeric) + (same as input)square rootsqrt(2.0)1.4142135623731
+ trunc(dp or numeric) + (same as input)truncate toward zerotrunc(42.8)42
trunc(v numeric, s int)numerictruncate to s decimal placestrunc(42.4382, 2)42.43
+ width_bucket(op numeric, b1 numeric, b2 numeric, count int) + intreturn the bucket to which operand would + be assigned in an equidepth histogram with count + buckets, in the range b1 to b2width_bucket(5.35, 0.024, 10.06, 5)3
width_bucket(op dp, b1 dp, b2 dp, count int)intreturn the bucket to which operand would + be assigned in an equidepth histogram with count + buckets, in the range b1 to b2width_bucket(5.35, 0.024, 10.06, 5)3

Finally, Table 9-4 shows the + available trigonometric functions. All trigonometric functions + take arguments and return values of type double + precision. Trigonometric functions arguments are expressed + in radians. Inverse functions return values are expressed in + radians. See unit transformation functions + radians() and + degrees() above. +

Table 9-4. Trigonometric Functions

FunctionDescription
acos(x) + inverse cosine
+ asin(x) + inverse sine
+ atan(x) + inverse tangent
+ atan2(y, + x) + inverse tangent of + y/x
+ cos(x) + cosine
+ cot(x) + cotangent
+ sin(x) + sine
+ tan(x) + tangent

PrevHomeNext
Comparison OperatorsUpString Functions and Operators
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-net.html b/doc/src/sgml/html/functions-net.html new file mode 100644 index 000000000..4be35f5cc --- /dev/null +++ b/doc/src/sgml/html/functions-net.html @@ -0,0 +1,1087 @@ + +Network Address Functions and Operators
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.12. Network Address Functions and Operators

Table 9-33 shows the operators + available for the cidr and inet types. + The operators <<, + <<=, >>, and + >>= test for subnet inclusion. They + consider only the network parts of the two addresses (ignoring any + host part) and determine whether one network is identical to + or a subnet of the other. +

Table 9-33. cidr and inet Operators

OperatorDescriptionExample
< is less thaninet '192.168.1.5' < inet '192.168.1.6'
<= is less than or equalinet '192.168.1.5' <= inet '192.168.1.5'
= equalsinet '192.168.1.5' = inet '192.168.1.5'
>= is greater or equalinet '192.168.1.5' >= inet '192.168.1.5'
> is greater thaninet '192.168.1.5' > inet '192.168.1.4'
<> is not equalinet '192.168.1.5' <> inet '192.168.1.4'
<< is contained withininet '192.168.1.5' << inet '192.168.1/24'
<<= is contained within or equalsinet '192.168.1/24' <<= inet '192.168.1/24'
>> containsinet '192.168.1/24' >> inet '192.168.1.5'
>>= contains or equalsinet '192.168.1/24' >>= inet '192.168.1/24'
~ bitwise NOT~ inet '192.168.1.6'
& bitwise ANDinet '192.168.1.6' & inet '0.0.0.255'
| bitwise ORinet '192.168.1.6' | inet '0.0.0.255'
+ additioninet '192.168.1.6' + 25
- subtractioninet '192.168.1.43' - 36
- subtractioninet '192.168.1.43' - inet '192.168.1.19'

Table 9-34 shows the functions + available for use with the cidr and inet + types. The abbrev, host, + and text + functions are primarily intended to offer alternative display + formats. +

Table 9-34. cidr and inet Functions

FunctionReturn TypeDescriptionExampleResult
+ abbrev(inet) + textabbreviated display format as textabbrev(inet '10.1.0.0/16')10.1.0.0/16
abbrev(cidr)textabbreviated display format as textabbrev(cidr '10.1.0.0/16')10.1/16
+ broadcast(inet) + inetbroadcast address for networkbroadcast('192.168.1.5/24')192.168.1.255/24
+ family(inet) + intextract family of address; 4 for IPv4, + 6 for IPv6family('::1')6
+ host(inet) + textextract IP address as texthost('192.168.1.5/24')192.168.1.5
+ hostmask(inet) + inetconstruct host mask for networkhostmask('192.168.23.20/30')0.0.0.3
+ masklen(inet) + intextract netmask lengthmasklen('192.168.1.5/24')24
+ netmask(inet) + inetconstruct netmask for networknetmask('192.168.1.5/24')255.255.255.0
+ network(inet) + cidrextract network part of addressnetwork('192.168.1.5/24')192.168.1.0/24
+ set_masklen(inet, int) + inetset netmask length for inet valueset_masklen('192.168.1.5/24', 16)192.168.1.5/16
set_masklen(cidr, int)cidrset netmask length for cidr valueset_masklen('192.168.1.0/24'::cidr, 16)192.168.0.0/16
+ text(inet) + textextract IP address and netmask length as texttext(inet '192.168.1.5')192.168.1.5/32

Any cidr value can be cast to inet implicitly + or explicitly; therefore, the functions shown above as operating on + inet also work on cidr values. (Where there are + separate functions for inet and cidr, it is because + the behavior should be different for the two cases.) + Also, it is permitted to cast an inet value to cidr. + When this is done, any bits to the right of the netmask are silently zeroed + to create a valid cidr value. + In addition, + you can cast a text value to inet or cidr + using normal casting syntax: for example, + inet(expression) or + colname::cidr. +

Table 9-35 shows the functions + available for use with the macaddr type. The function + trunc(macaddr) returns a MAC + address with the last 3 bytes set to zero. This can be used to + associate the remaining prefix with a manufacturer. +

Table 9-35. macaddr Functions

FunctionReturn TypeDescriptionExampleResult
+ trunc(macaddr) + macaddrset last 3 bytes to zerotrunc(macaddr '12:34:56:78:90:ab')12:34:56:00:00:00

The macaddr type also supports the standard relational + operators (>, <=, etc.) for + lexicographical ordering, and the bitwise arithmetic operators + (~, & and |) + for NOT, AND and OR. +


PrevHomeNext
Geometric Functions and OperatorsUpText Search Functions and Operators
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-range.html b/doc/src/sgml/html/functions-range.html new file mode 100644 index 000000000..a95aff595 --- /dev/null +++ b/doc/src/sgml/html/functions-range.html @@ -0,0 +1,875 @@ + +Range Functions and Operators
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.19. Range Functions and Operators

See Section 8.17 for an overview of range types. +

Table 9-43 shows the operators + available for range types. +

Table 9-43. Range Operators

OperatorDescriptionExampleResult
= equalint4range(1,5) = '[1,4]'::int4ranget
<> not equalnumrange(1.1,2.2) <> numrange(1.1,2.3)t
< less thanint4range(1,10) < int4range(2,3)t
> greater thanint4range(1,10) > int4range(1,5)t
<= less than or equalnumrange(1.1,2.2) <= numrange(1.1,2.2)t
>= greater than or equalnumrange(1.1,2.2) >= numrange(1.1,2.0)t
@> contains rangeint4range(2,4) @> int4range(2,3)t
@> contains element'[2011-01-01,2011-03-01)'::tsrange @> '2011-01-10'::timestampt
<@ range is contained byint4range(2,4) <@ int4range(1,7)t
<@ element is contained by42 <@ int4range(1,7)f
&& overlap (have points in common)int8range(3,7) && int8range(4,12)t
<< strictly left ofint8range(1,10) << int8range(100,110)t
>> strictly right ofint8range(50,60) >> int8range(20,30)t
&< does not extend to the right ofint8range(1,20) &< int8range(18,20)t
&> does not extend to the left ofint8range(7,20) &> int8range(5,10)t
-|- is adjacent tonumrange(1.1,2.2) -|- numrange(2.2,3.3)t
+ unionnumrange(5,15) + numrange(10,20)[5,20)
* intersectionint8range(5,15) * int8range(10,20)[10,15)
- differenceint8range(5,15) - int8range(10,20)[5,10)

The simple comparison operators <, + >, <=, and + >= compare the lower bounds first, and only if those + are equal, compare the upper bounds. These comparisons are not usually + very useful for ranges, but are provided to allow B-tree indexes to be + constructed on ranges. +

The left-of/right-of/adjacent operators always return false when an empty + range is involved; that is, an empty range is not considered to be either + before or after any other range. +

The union and difference operators will fail if the resulting range would + need to contain two disjoint sub-ranges, as such a range cannot be + represented. +

Table 9-44 shows the functions + available for use with range types. +

Table 9-44. Range Functions

FunctionReturn TypeDescriptionExampleResult
lower(anyrange) + + range's element typelower bound of rangelower(numrange(1.1,2.2))1.1
upper(anyrange) + + range's element typeupper bound of rangeupper(numrange(1.1,2.2))2.2
isempty(anyrange) + + booleanis the range empty?isempty(numrange(1.1,2.2))false
lower_inc(anyrange) + + booleanis the lower bound inclusive?lower_inc(numrange(1.1,2.2))true
upper_inc(anyrange) + + booleanis the upper bound inclusive?upper_inc(numrange(1.1,2.2))false
lower_inf(anyrange) + + booleanis the lower bound infinite?lower_inf('(,)'::daterange)true
upper_inf(anyrange) + + booleanis the upper bound infinite?upper_inf('(,)'::daterange)true

The lower and upper functions return null + if the range is empty or the requested bound is infinite. + The lower_inc, upper_inc, + lower_inf, and upper_inf + functions all return false for an empty range. +


PrevHomeNext
Array Functions and OperatorsUpAggregate Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-sequence.html b/doc/src/sgml/html/functions-sequence.html new file mode 100644 index 000000000..60fec9c1a --- /dev/null +++ b/doc/src/sgml/html/functions-sequence.html @@ -0,0 +1,715 @@ + +Sequence Manipulation Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.16. Sequence Manipulation Functions

This section describes PostgreSQL's + functions for operating on sequence objects. + Sequence objects (also called sequence generators or just + sequences) are special single-row tables created with CREATE SEQUENCE. + A sequence object is usually used to generate unique identifiers + for rows of a table. The sequence functions, listed in Table 9-40, provide simple, multiuser-safe + methods for obtaining successive sequence values from sequence + objects. +

Table 9-40. Sequence Functions

FunctionReturn TypeDescription
currval(regclass)bigintReturn value most recently obtained with + nextval for specified sequence
lastval()bigintReturn value most recently obtained with + nextval for any sequence
nextval(regclass)bigintAdvance sequence and return new value
setval(regclass, bigint)bigintSet sequence's current value
setval(regclass, bigint, boolean)bigintSet sequence's current value and is_called flag

The sequence to be operated on by a sequence function is specified by + a regclass argument, which is simply the OID of the sequence in the + pg_class system catalog. You do not have to look up the + OID by hand, however, since the regclass data type's input + converter will do the work for you. Just write the sequence name enclosed + in single quotes so that it looks like a literal constant. For + compatibility with the handling of ordinary + SQL names, the string will be converted to lower case + unless it contains double quotes around the sequence name. Thus: +

nextval('foo')      operates on sequence foo
+nextval('FOO')      operates on sequence foo
+nextval('"Foo"')    operates on sequence Foo

+ The sequence name can be schema-qualified if necessary: +

nextval('myschema.foo')     operates on myschema.foo
+nextval('"myschema".foo')   same as above
+nextval('foo')              searches search path for foo

+ See Section 8.18 for more information about + regclass. +

Note: Before PostgreSQL 8.1, the arguments of the + sequence functions were of type text, not regclass, and + the above-described conversion from a text string to an OID value would + happen at run time during each call. For backward compatibility, this + facility still exists, but internally it is now handled as an implicit + coercion from text to regclass before the function is + invoked. +

When you write the argument of a sequence function as an unadorned + literal string, it becomes a constant of type regclass. + Since this is really just an OID, it will track the originally + identified sequence despite later renaming, schema reassignment, + etc. This "early binding" behavior is usually desirable for + sequence references in column defaults and views. But sometimes you might + want "late binding" where the sequence reference is resolved + at run time. To get late-binding behavior, force the constant to be + stored as a text constant instead of regclass: +

nextval('foo'::text)      foo is looked up at runtime

+ Note that late binding was the only behavior supported in + PostgreSQL releases before 8.1, so you + might need to do this to preserve the semantics of old applications. +

Of course, the argument of a sequence function can be an expression + as well as a constant. If it is a text expression then the implicit + coercion will result in a run-time lookup. +

The available sequence functions are: + +

nextval

Advance the sequence object to its next value and return that + value. This is done atomically: even if multiple sessions + execute nextval concurrently, each will safely receive + a distinct sequence value. +

If a sequence object has been created with default parameters, + successive nextval calls will return successive + values beginning with 1. Other behaviors can be obtained by using + special parameters in the CREATE SEQUENCE command; + see its command reference page for more information. +

Important: To avoid blocking concurrent transactions that obtain numbers from the + same sequence, a nextval operation is never + rolled back; that is, once a value has been fetched it is considered + used, even if the transaction that did the + nextval later aborts. This means that aborted + transactions might leave unused "holes" in the sequence + of assigned values. +

currval

Return the value most recently obtained by nextval + for this sequence in the current session. (An error is + reported if nextval has never been called for this + sequence in this session.) Because this is returning + a session-local value, it gives a predictable answer whether or not + other sessions have executed nextval since the + current session did. +

lastval

Return the value most recently returned by + nextval in the current session. This function is + identical to currval, except that instead + of taking the sequence name as an argument it fetches the + value of the last sequence used by nextval + in the current session. It is an error to call + lastval if nextval + has not yet been called in the current session. +

setval

Reset the sequence object's counter value. The two-parameter + form sets the sequence's last_value field to the + specified value and sets its is_called field to + true, meaning that the next + nextval will advance the sequence before + returning a value. The value reported by currval is + also set to the specified value. In the three-parameter form, + is_called can be set to either true + or false. true has the same effect as + the two-parameter form. If it is set to false, the + next nextval will return exactly the specified + value, and sequence advancement commences with the following + nextval. Furthermore, the value reported by + currval is not changed in this case (this is a change + from pre-8.3 behavior). For example, + +

SELECT setval('foo', 42);           Next nextval will return 43
+SELECT setval('foo', 42, true);     Same as above
+SELECT setval('foo', 42, false);    Next nextval will return 42

+ + The result returned by setval is just the value of its + second argument. +

Important: Because sequences are non-transactional, changes made by + setval are not undone if the transaction rolls + back. +

+


PrevHomeNext
JSON FunctionsUpConditional Expressions
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-srf.html b/doc/src/sgml/html/functions-srf.html new file mode 100644 index 000000000..75a5a32ea --- /dev/null +++ b/doc/src/sgml/html/functions-srf.html @@ -0,0 +1,565 @@ + +Set Returning Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.24. Set Returning Functions

This section describes functions that possibly return more than one row. + Currently the only functions in this class are series generating functions, + as detailed in Table 9-48 and + Table 9-49. +

Table 9-48. Series Generating Functions

FunctionArgument TypeReturn TypeDescription
generate_series(start, stop)int or bigintsetof int or setof bigint (same as argument type) Generate a series of values, from start to stop + with a step size of one +
generate_series(start, stop, step)int or bigintsetof int or setof bigint (same as argument type) Generate a series of values, from start to stop + with a step size of step +
generate_series(start, stop, step interval)timestamp or timestamp with time zonesetof timestamp or setof timestamp with time zone (same as argument type) Generate a series of values, from start to stop + with a step size of step +

When step is positive, zero rows are returned if + start is greater than stop. + Conversely, when step is negative, zero rows are + returned if start is less than stop. + Zero rows are also returned for NULL inputs. It is an error + for step to be zero. Some examples follow: +

SELECT * FROM generate_series(2,4);
+ generate_series
+-----------------
+               2
+               3
+               4
+(3 rows)
+
+SELECT * FROM generate_series(5,1,-2);
+ generate_series
+-----------------
+               5
+               3
+               1
+(3 rows)
+
+SELECT * FROM generate_series(4,3);
+ generate_series
+-----------------
+(0 rows)
+
+-- this example relies on the date-plus-integer operator
+SELECT current_date + s.a AS dates FROM generate_series(0,14,7) AS s(a);
+   dates
+------------
+ 2004-02-05
+ 2004-02-12
+ 2004-02-19
+(3 rows)
+
+SELECT * FROM generate_series('2008-03-01 00:00'::timestamp,
+                              '2008-03-04 12:00', '10 hours');
+   generate_series   
+---------------------
+ 2008-03-01 00:00:00
+ 2008-03-01 10:00:00
+ 2008-03-01 20:00:00
+ 2008-03-02 06:00:00
+ 2008-03-02 16:00:00
+ 2008-03-03 02:00:00
+ 2008-03-03 12:00:00
+ 2008-03-03 22:00:00
+ 2008-03-04 08:00:00
+(9 rows)

+

Table 9-49. Subscript Generating Functions

FunctionReturn TypeDescription
generate_subscripts(array anyarray, dim int)setof int Generate a series comprising the given array's subscripts. +
generate_subscripts(array anyarray, dim int, reverse boolean)setof int Generate a series comprising the given array's subscripts. When + reverse is true, the series is returned in + reverse order. +

generate_subscripts is a convenience function that generates + the set of valid subscripts for the specified dimension of the given + array. + Zero rows are returned for arrays that do not have the requested dimension, + or for NULL arrays (but valid subscripts are returned for NULL array + elements). Some examples follow: +

-- basic usage
+SELECT generate_subscripts('{NULL,1,NULL,2}'::int[], 1) AS s;
+ s 
+---
+ 1
+ 2
+ 3
+ 4
+(4 rows)
+
+-- presenting an array, the subscript and the subscripted
+-- value requires a subquery
+SELECT * FROM arrays;
+         a          
+--------------------
+ {-1,-2}
+ {100,200,300}
+(2 rows)
+
+SELECT a AS array, s AS subscript, a[s] AS value
+FROM (SELECT generate_subscripts(a, 1) AS s, a FROM arrays) foo;
+     array     | subscript | value
+---------------+-----------+-------
+ {-1,-2}       |         1 |    -1
+ {-1,-2}       |         2 |    -2
+ {100,200,300} |         1 |   100
+ {100,200,300} |         2 |   200
+ {100,200,300} |         3 |   300
+(5 rows)
+
+-- unnest a 2D array
+CREATE OR REPLACE FUNCTION unnest2(anyarray)
+RETURNS SETOF anyelement AS $$
+select $1[i][j]
+   from generate_subscripts($1,1) g1(i),
+        generate_subscripts($1,2) g2(j);
+$$ LANGUAGE sql IMMUTABLE;
+CREATE FUNCTION
+postgres=# SELECT * FROM unnest2(ARRAY[[1,2],[3,4]]);
+ unnest2 
+---------
+       1
+       2
+       3
+       4
+(4 rows)

+


PrevHomeNext
Row and Array ComparisonsUpSystem Information Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-string.html b/doc/src/sgml/html/functions-string.html new file mode 100644 index 000000000..35d4b685f --- /dev/null +++ b/doc/src/sgml/html/functions-string.html @@ -0,0 +1,5187 @@ + +String Functions and Operators
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.4. String Functions and Operators

This section describes functions and operators for examining and + manipulating string values. Strings in this context include values + of the types character, character varying, + and text. Unless otherwise noted, all + of the functions listed below work on all of these types, but be + wary of potential effects of automatic space-padding when using the + character type. Some functions also exist + natively for the bit-string types. +

SQL defines some string functions that use + key words, rather than commas, to separate + arguments. Details are in + Table 9-5. + PostgreSQL also provides versions of these functions + that use the regular function invocation syntax + (see Table 9-6). +

Note: Before PostgreSQL 8.3, these functions would + silently accept values of several non-string data types as well, due to + the presence of implicit coercions from those data types to + text. Those coercions have been removed because they frequently + caused surprising behaviors. However, the string concatenation operator + (||) still accepts non-string input, so long as at least one + input is of a string type, as shown in Table 9-5. For other cases, insert an explicit + coercion to text if you need to duplicate the previous behavior. +

Table 9-5. SQL String Functions and Operators

FunctionReturn TypeDescriptionExampleResult
string || + string text String concatenation + + 'Post' || 'greSQL'PostgreSQL
string || + non-string + or + non-string || + string + text String concatenation with one non-string input + 'Value: ' || 42Value: 42
+ bit_length(string) + intNumber of bits in stringbit_length('jose')32
+ char_length(string) or character_length(string) + int Number of characters in string + + + char_length('jose')4
+ lower(string) + textConvert string to lower caselower('TOM')tom
+ octet_length(string) + intNumber of bytes in stringoctet_length('jose')4
+ overlay(string placing string from int [for int]) + text Replace substring + overlay('Txxxxas' placing 'hom' from 2 for 4)Thomas
+ position(substring in string) + intLocation of specified substringposition('om' in 'Thomas')3
+ substring(string [from int] [for int]) + text Extract substring + substring('Thomas' from 2 for 3)hom
substring(string from pattern)text Extract substring matching POSIX regular expression. See + Section 9.7 for more information on pattern + matching. + substring('Thomas' from '...$')mas
substring(string from pattern for escape)text Extract substring matching SQL regular expression. + See Section 9.7 for more information on + pattern matching. + substring('Thomas' from '%#"o_a#"_' for '#')oma
+ trim([leading | trailing | both] + [characters] from + string) + text Remove the longest string containing only the + characters (a space by default) from the + start/end/both ends of the string + trim(both 'x' from 'xTomxx')Tom
+ upper(string) + textConvert string to upper caseupper('tom')TOM

Additional string manipulation functions are available and are + listed in Table 9-6. Some of them are used internally to implement the + SQL-standard string functions listed in Table 9-5. +

Table 9-6. Other String Functions

FunctionReturn TypeDescriptionExampleResult
+ ascii(string) + int ASCII code of the first character of the + argument. For UTF8 returns the Unicode code + point of the character. For other multibyte encodings, the + argument must be an ASCII character. + ascii('x')120
+ btrim(string text + [, characters text]) + text Remove the longest string consisting only of characters + in characters (a space by default) + from the start and end of string + btrim('xyxtrimyyx', 'xy')trim
+ chr(int) + text Character with the given code. For UTF8 the + argument is treated as a Unicode code point. For other multibyte + encodings the argument must designate an + ASCII character. The NULL (0) character is not + allowed because text data types cannot store such bytes. + chr(65)A
+ concat(str "any" + [, str "any" [, ...] ]) + text Concatenate all arguments. NULL arguments are ignored. + concat('abcde', 2, NULL, 22)abcde222
+ concat_ws(sep text, + str "any" + [, str "any" [, ...] ]) + text Concatenate all but first arguments with separators. The first + parameter is used as a separator. NULL arguments are ignored. + concat_ws(',', 'abcde', 2, NULL, 22)abcde,2,22
+ convert(string bytea, + src_encoding name, + dest_encoding name) + bytea Convert string to dest_encoding. The + original encoding is specified by + src_encoding. The + string must be valid in this encoding. + Conversions can be defined by CREATE CONVERSION. + Also there are some predefined conversions. See Table 9-7 for available conversions. + convert('text_in_utf8', 'UTF8', 'LATIN1')text_in_utf8 represented in Latin-1 + encoding (ISO 8859-1)
+ convert_from(string bytea, + src_encoding name) + text Convert string to the database encoding. The original encoding + is specified by src_encoding. The + string must be valid in this encoding. + convert_from('text_in_utf8', 'UTF8')text_in_utf8 represented in the current database encoding
+ convert_to(string text, + dest_encoding name) + bytea Convert string to dest_encoding. + convert_to('some text', 'UTF8')some text represented in the UTF8 encoding
+ decode(string text, + format text) + bytea Decode binary data from textual representation in string. + Options for format are same as in encode. + decode('MTIzAAE=', 'base64')\x3132330001
+ encode(data bytea, + format text) + text Encode binary data into a textual representation. Supported + formats are: base64, hex, escape. + escape merely outputs null bytes as \000 and + doubles backslashes. + encode(E'123\\000\\001', 'base64')MTIzAAE=
+ format(formatstr text + [, str "any" [, ...] ]) + text Format a string. This function is similar to the C function + sprintf; but only the following conversion specifications + are recognized: %s interpolates the corresponding + argument as a string; %I escapes its argument as + an SQL identifier; %L escapes its argument as an + SQL literal; %% outputs a literal %. + A conversion can reference an explicit parameter position by preceding + the conversion specifier with n$, where + n is the argument position. + See also Example 39-1. + format('Hello %s, %1$s', 'World')Hello World, World
+ initcap(string) + text Convert the first letter of each word to upper case and the + rest to lower case. Words are sequences of alphanumeric + characters separated by non-alphanumeric characters. + initcap('hi THOMAS')Hi Thomas
+ left(str text, + n int) + text Return first n characters in the string. When n + is negative, return all but last |n| characters. + left('abcde', 2)ab
+ length(string) + int Number of characters in string + length('jose')4
length(string bytea, + encoding name )int Number of characters in string in the given + encoding. The string + must be valid in this encoding. + length('jose', 'UTF8')4
+ lpad(string text, + length int + [, fill text]) + text Fill up the string to length + length by prepending the characters + fill (a space by default). If the + string is already longer than + length then it is truncated (on the + right). + lpad('hi', 5, 'xy')xyxhi
+ ltrim(string text + [, characters text]) + text Remove the longest string containing only characters from + characters (a space by default) from the start of + string + ltrim('zzzytrim', 'xyz')trim
+ md5(string) + text Calculates the MD5 hash of string, + returning the result in hexadecimal + md5('abc')900150983cd24fb0 d6963f7d28e17f72
+ pg_client_encoding() + name Current client encoding name + pg_client_encoding()SQL_ASCII
+ quote_ident(string text) + text Return the given string suitably quoted to be used as an identifier + in an SQL statement string. + Quotes are added only if necessary (i.e., if the string contains + non-identifier characters or would be case-folded). + Embedded quotes are properly doubled. + See also Example 39-1. + quote_ident('Foo bar')"Foo bar"
+ quote_literal(string text) + text Return the given string suitably quoted to be used as a string literal + in an SQL statement string. + Embedded single-quotes and backslashes are properly doubled. + Note that quote_literal returns null on null + input; if the argument might be null, + quote_nullable is often more suitable. + See also Example 39-1. + quote_literal(E'O\'Reilly')'O''Reilly'
quote_literal(value anyelement)text Coerce the given value to text and then quote it as a literal. + Embedded single-quotes and backslashes are properly doubled. + quote_literal(42.5)'42.5'
+ quote_nullable(string text) + text Return the given string suitably quoted to be used as a string literal + in an SQL statement string; or, if the argument + is null, return NULL. + Embedded single-quotes and backslashes are properly doubled. + See also Example 39-1. + quote_nullable(NULL)NULL
quote_nullable(value anyelement)text Coerce the given value to text and then quote it as a literal; + or, if the argument is null, return NULL. + Embedded single-quotes and backslashes are properly doubled. + quote_nullable(42.5)'42.5'
+ regexp_matches(string text, pattern text [, flags text]) + setof text[] Return all captured substrings resulting from matching a POSIX regular + expression against the string. See + Section 9.7.3 for more information. + regexp_matches('foobarbequebaz', '(bar)(beque)'){bar,beque}
+ regexp_replace(string text, pattern text, replacement text [, flags text]) + text Replace substring(s) matching a POSIX regular expression. See + Section 9.7.3 for more information. + regexp_replace('Thomas', '.[mN]a.', 'M')ThM
+ regexp_split_to_array(string text, pattern text [, flags text ]) + text[] Split string using a POSIX regular expression as + the delimiter. See Section 9.7.3 for more + information. + regexp_split_to_array('hello world', E'\\s+'){hello,world}
+ regexp_split_to_table(string text, pattern text [, flags text]) + setof text Split string using a POSIX regular expression as + the delimiter. See Section 9.7.3 for more + information. + regexp_split_to_table('hello world', E'\\s+')hello

world

(2 rows)
+ repeat(string text, number int) + textRepeat string the specified + number of timesrepeat('Pg', 4)PgPgPgPg
+ replace(string text, + from text, + to text) + textReplace all occurrences in string of substring + from with substring to + replace('abcdefabcdef', 'cd', 'XX')abXXefabXXef
+ reverse(str) + text Return reversed string. + reverse('abcde')edcba
+ right(str text, + n int) + text Return last n characters in the string. When n + is negative, return all but first |n| characters. + right('abcde', 2)de
+ rpad(string text, + length int + [, fill text]) + text Fill up the string to length + length by appending the characters + fill (a space by default). If the + string is already longer than + length then it is truncated. + rpad('hi', 5, 'xy')hixyx
+ rtrim(string text + [, characters text]) + text Remove the longest string containing only characters from + characters (a space by default) from the end of + string + rtrim('trimxxxx', 'x')trim
+ split_part(string text, + delimiter text, + field int) + textSplit string on delimiter + and return the given field (counting from one) + split_part('abc~@~def~@~ghi', '~@~', 2)def
+ strpos(string, substring) + int Location of specified substring (same as + position(substring in + string), but note the reversed + argument order) + strpos('high', 'ig')2
+ substr(string, from [, count]) + text Extract substring (same as + substring(string from from for count)) + substr('alphabet', 3, 2)ph
+ to_ascii(string text + [, encoding text]) + text Convert string to ASCII from another encoding + (only supports conversion from LATIN1, LATIN2, LATIN9, + and WIN1250 encodings) + to_ascii('Karel')Karel
+ to_hex(number int + or bigint) + textConvert number to its equivalent hexadecimal + representation + to_hex(2147483647)7fffffff
+ translate(string text, + from text, + to text) + text Any character in string that matches a + character in the from set is replaced by + the corresponding character in the to + set. If from is longer than + to, occurrences of the extra characters in + from are removed. + translate('12345', '143', 'ax')a2x5

See also the aggregate function string_agg in + Section 9.20. +

Table 9-7. Built-in Conversions

Conversion Name + [a] + Source EncodingDestination Encoding
ascii_to_micSQL_ASCIIMULE_INTERNAL
ascii_to_utf8SQL_ASCIIUTF8
big5_to_euc_twBIG5EUC_TW
big5_to_micBIG5MULE_INTERNAL
big5_to_utf8BIG5UTF8
euc_cn_to_micEUC_CNMULE_INTERNAL
euc_cn_to_utf8EUC_CNUTF8
euc_jp_to_micEUC_JPMULE_INTERNAL
euc_jp_to_sjisEUC_JPSJIS
euc_jp_to_utf8EUC_JPUTF8
euc_kr_to_micEUC_KRMULE_INTERNAL
euc_kr_to_utf8EUC_KRUTF8
euc_tw_to_big5EUC_TWBIG5
euc_tw_to_micEUC_TWMULE_INTERNAL
euc_tw_to_utf8EUC_TWUTF8
gb18030_to_utf8GB18030UTF8
gbk_to_utf8GBKUTF8
iso_8859_10_to_utf8LATIN6UTF8
iso_8859_13_to_utf8LATIN7UTF8
iso_8859_14_to_utf8LATIN8UTF8
iso_8859_15_to_utf8LATIN9UTF8
iso_8859_16_to_utf8LATIN10UTF8
iso_8859_1_to_micLATIN1MULE_INTERNAL
iso_8859_1_to_utf8LATIN1UTF8
iso_8859_2_to_micLATIN2MULE_INTERNAL
iso_8859_2_to_utf8LATIN2UTF8
iso_8859_2_to_windows_1250LATIN2WIN1250
iso_8859_3_to_micLATIN3MULE_INTERNAL
iso_8859_3_to_utf8LATIN3UTF8
iso_8859_4_to_micLATIN4MULE_INTERNAL
iso_8859_4_to_utf8LATIN4UTF8
iso_8859_5_to_koi8_rISO_8859_5KOI8R
iso_8859_5_to_micISO_8859_5MULE_INTERNAL
iso_8859_5_to_utf8ISO_8859_5UTF8
iso_8859_5_to_windows_1251ISO_8859_5WIN1251
iso_8859_5_to_windows_866ISO_8859_5WIN866
iso_8859_6_to_utf8ISO_8859_6UTF8
iso_8859_7_to_utf8ISO_8859_7UTF8
iso_8859_8_to_utf8ISO_8859_8UTF8
iso_8859_9_to_utf8LATIN5UTF8
johab_to_utf8JOHABUTF8
koi8_r_to_iso_8859_5KOI8RISO_8859_5
koi8_r_to_micKOI8RMULE_INTERNAL
koi8_r_to_utf8KOI8RUTF8
koi8_r_to_windows_1251KOI8RWIN1251
koi8_r_to_windows_866KOI8RWIN866
koi8_u_to_utf8KOI8UUTF8
mic_to_asciiMULE_INTERNALSQL_ASCII
mic_to_big5MULE_INTERNALBIG5
mic_to_euc_cnMULE_INTERNALEUC_CN
mic_to_euc_jpMULE_INTERNALEUC_JP
mic_to_euc_krMULE_INTERNALEUC_KR
mic_to_euc_twMULE_INTERNALEUC_TW
mic_to_iso_8859_1MULE_INTERNALLATIN1
mic_to_iso_8859_2MULE_INTERNALLATIN2
mic_to_iso_8859_3MULE_INTERNALLATIN3
mic_to_iso_8859_4MULE_INTERNALLATIN4
mic_to_iso_8859_5MULE_INTERNALISO_8859_5
mic_to_koi8_rMULE_INTERNALKOI8R
mic_to_sjisMULE_INTERNALSJIS
mic_to_windows_1250MULE_INTERNALWIN1250
mic_to_windows_1251MULE_INTERNALWIN1251
mic_to_windows_866MULE_INTERNALWIN866
sjis_to_euc_jpSJISEUC_JP
sjis_to_micSJISMULE_INTERNAL
sjis_to_utf8SJISUTF8
tcvn_to_utf8WIN1258UTF8
uhc_to_utf8UHCUTF8
utf8_to_asciiUTF8SQL_ASCII
utf8_to_big5UTF8BIG5
utf8_to_euc_cnUTF8EUC_CN
utf8_to_euc_jpUTF8EUC_JP
utf8_to_euc_krUTF8EUC_KR
utf8_to_euc_twUTF8EUC_TW
utf8_to_gb18030UTF8GB18030
utf8_to_gbkUTF8GBK
utf8_to_iso_8859_1UTF8LATIN1
utf8_to_iso_8859_10UTF8LATIN6
utf8_to_iso_8859_13UTF8LATIN7
utf8_to_iso_8859_14UTF8LATIN8
utf8_to_iso_8859_15UTF8LATIN9
utf8_to_iso_8859_16UTF8LATIN10
utf8_to_iso_8859_2UTF8LATIN2
utf8_to_iso_8859_3UTF8LATIN3
utf8_to_iso_8859_4UTF8LATIN4
utf8_to_iso_8859_5UTF8ISO_8859_5
utf8_to_iso_8859_6UTF8ISO_8859_6
utf8_to_iso_8859_7UTF8ISO_8859_7
utf8_to_iso_8859_8UTF8ISO_8859_8
utf8_to_iso_8859_9UTF8LATIN5
utf8_to_johabUTF8JOHAB
utf8_to_koi8_rUTF8KOI8R
utf8_to_koi8_uUTF8KOI8U
utf8_to_sjisUTF8SJIS
utf8_to_tcvnUTF8WIN1258
utf8_to_uhcUTF8UHC
utf8_to_windows_1250UTF8WIN1250
utf8_to_windows_1251UTF8WIN1251
utf8_to_windows_1252UTF8WIN1252
utf8_to_windows_1253UTF8WIN1253
utf8_to_windows_1254UTF8WIN1254
utf8_to_windows_1255UTF8WIN1255
utf8_to_windows_1256UTF8WIN1256
utf8_to_windows_1257UTF8WIN1257
utf8_to_windows_866UTF8WIN866
utf8_to_windows_874UTF8WIN874
windows_1250_to_iso_8859_2WIN1250LATIN2
windows_1250_to_micWIN1250MULE_INTERNAL
windows_1250_to_utf8WIN1250UTF8
windows_1251_to_iso_8859_5WIN1251ISO_8859_5
windows_1251_to_koi8_rWIN1251KOI8R
windows_1251_to_micWIN1251MULE_INTERNAL
windows_1251_to_utf8WIN1251UTF8
windows_1251_to_windows_866WIN1251WIN866
windows_1252_to_utf8WIN1252UTF8
windows_1256_to_utf8WIN1256UTF8
windows_866_to_iso_8859_5WIN866ISO_8859_5
windows_866_to_koi8_rWIN866KOI8R
windows_866_to_micWIN866MULE_INTERNAL
windows_866_to_utf8WIN866UTF8
windows_866_to_windows_1251WIN866WIN
windows_874_to_utf8WIN874UTF8
euc_jis_2004_to_utf8EUC_JIS_2004UTF8
ut8_to_euc_jis_2004UTF8EUC_JIS_2004
shift_jis_2004_to_utf8SHIFT_JIS_2004UTF8
ut8_to_shift_jis_2004UTF8SHIFT_JIS_2004
euc_jis_2004_to_shift_jis_2004EUC_JIS_2004SHIFT_JIS_2004
shift_jis_2004_to_euc_jis_2004SHIFT_JIS_2004EUC_JIS_2004
Notes:
a. The conversion names follow a standard naming scheme: The + official name of the source encoding with all + non-alphanumeric characters replaced by underscores, followed + by _to_, followed by the similarly processed + destination encoding name. Therefore, the names might deviate + from the customary encoding names. +

PrevHomeNext
Mathematical Functions and OperatorsUpBinary String Functions and Operators
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-subquery.html b/doc/src/sgml/html/functions-subquery.html new file mode 100644 index 000000000..6695dedb8 --- /dev/null +++ b/doc/src/sgml/html/functions-subquery.html @@ -0,0 +1,854 @@ + +Subquery Expressions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.22. Subquery Expressions

This section describes the SQL-compliant subquery + expressions available in PostgreSQL. + All of the expression forms documented in this section return + Boolean (true/false) results. +

9.22.1. EXISTS

EXISTS (subquery)

The argument of EXISTS is an arbitrary SELECT statement, + or subquery. The + subquery is evaluated to determine whether it returns any rows. + If it returns at least one row, the result of EXISTS is + "true"; if the subquery returns no rows, the result of EXISTS + is "false". +

The subquery can refer to variables from the surrounding query, + which will act as constants during any one evaluation of the subquery. +

The subquery will generally only be executed long enough to determine + whether at least one row is returned, not all the way to completion. + It is unwise to write a subquery that has side effects (such as + calling sequence functions); whether the side effects occur + might be unpredictable. +

Since the result depends only on whether any rows are returned, + and not on the contents of those rows, the output list of the + subquery is normally unimportant. A common coding convention is + to write all EXISTS tests in the form + EXISTS(SELECT 1 WHERE ...). There are exceptions to + this rule however, such as subqueries that use INTERSECT. +

This simple example is like an inner join on col2, but + it produces at most one output row for each tab1 row, + even if there are several matching tab2 rows: +

SELECT col1
+FROM tab1
+WHERE EXISTS (SELECT 1 FROM tab2 WHERE col2 = tab1.col2);

+

9.22.2. IN

expression IN (subquery)

The right-hand side is a parenthesized + subquery, which must return exactly one column. The left-hand expression + is evaluated and compared to each row of the subquery result. + The result of IN is "true" if any equal subquery row is found. + The result is "false" if no equal row is found (including the + case where the subquery returns no rows). +

Note that if the left-hand expression yields null, or if there are + no equal right-hand values and at least one right-hand row yields + null, the result of the IN construct will be null, not false. + This is in accordance with SQL's normal rules for Boolean combinations + of null values. +

As with EXISTS, it's unwise to assume that the subquery will + be evaluated completely. +

row_constructor IN (subquery)

The left-hand side of this form of IN is a row constructor, + as described in Section 4.2.13. + The right-hand side is a parenthesized + subquery, which must return exactly as many columns as there are + expressions in the left-hand row. The left-hand expressions are + evaluated and compared row-wise to each row of the subquery result. + The result of IN is "true" if any equal subquery row is found. + The result is "false" if no equal row is found (including the + case where the subquery returns no rows). +

As usual, null values in the rows are combined per + the normal rules of SQL Boolean expressions. Two rows are considered + equal if all their corresponding members are non-null and equal; the rows + are unequal if any corresponding members are non-null and unequal; + otherwise the result of that row comparison is unknown (null). + If all the per-row results are either unequal or null, with at least one + null, then the result of IN is null. +

9.22.3. NOT IN

expression NOT IN (subquery)

The right-hand side is a parenthesized + subquery, which must return exactly one column. The left-hand expression + is evaluated and compared to each row of the subquery result. + The result of NOT IN is "true" if only unequal subquery rows + are found (including the case where the subquery returns no rows). + The result is "false" if any equal row is found. +

Note that if the left-hand expression yields null, or if there are + no equal right-hand values and at least one right-hand row yields + null, the result of the NOT IN construct will be null, not true. + This is in accordance with SQL's normal rules for Boolean combinations + of null values. +

As with EXISTS, it's unwise to assume that the subquery will + be evaluated completely. +

row_constructor NOT IN (subquery)

The left-hand side of this form of NOT IN is a row constructor, + as described in Section 4.2.13. + The right-hand side is a parenthesized + subquery, which must return exactly as many columns as there are + expressions in the left-hand row. The left-hand expressions are + evaluated and compared row-wise to each row of the subquery result. + The result of NOT IN is "true" if only unequal subquery rows + are found (including the case where the subquery returns no rows). + The result is "false" if any equal row is found. +

As usual, null values in the rows are combined per + the normal rules of SQL Boolean expressions. Two rows are considered + equal if all their corresponding members are non-null and equal; the rows + are unequal if any corresponding members are non-null and unequal; + otherwise the result of that row comparison is unknown (null). + If all the per-row results are either unequal or null, with at least one + null, then the result of NOT IN is null. +

9.22.4. ANY/SOME

expression operator ANY (subquery)
+expression operator SOME (subquery)

The right-hand side is a parenthesized + subquery, which must return exactly one column. The left-hand expression + is evaluated and compared to each row of the subquery result using the + given operator, which must yield a Boolean + result. + The result of ANY is "true" if any true result is obtained. + The result is "false" if no true result is found (including the + case where the subquery returns no rows). +

SOME is a synonym for ANY. + IN is equivalent to = ANY. +

Note that if there are no successes and at least one right-hand row yields + null for the operator's result, the result of the ANY construct + will be null, not false. + This is in accordance with SQL's normal rules for Boolean combinations + of null values. +

As with EXISTS, it's unwise to assume that the subquery will + be evaluated completely. +

row_constructor operator ANY (subquery)
+row_constructor operator SOME (subquery)

The left-hand side of this form of ANY is a row constructor, + as described in Section 4.2.13. + The right-hand side is a parenthesized + subquery, which must return exactly as many columns as there are + expressions in the left-hand row. The left-hand expressions are + evaluated and compared row-wise to each row of the subquery result, + using the given operator. + The result of ANY is "true" if the comparison + returns true for any subquery row. + The result is "false" if the comparison returns false for every + subquery row (including the case where the subquery returns no + rows). + The result is NULL if the comparison does not return true for any row, + and it returns NULL for at least one row. +

See Section 9.23.5 for details about the meaning + of a row-wise comparison. +

9.22.5. ALL

expression operator ALL (subquery)

The right-hand side is a parenthesized + subquery, which must return exactly one column. The left-hand expression + is evaluated and compared to each row of the subquery result using the + given operator, which must yield a Boolean + result. + The result of ALL is "true" if all rows yield true + (including the case where the subquery returns no rows). + The result is "false" if any false result is found. + The result is NULL if the comparison does not return false for any row, + and it returns NULL for at least one row. +

NOT IN is equivalent to <> ALL. +

As with EXISTS, it's unwise to assume that the subquery will + be evaluated completely. +

row_constructor operator ALL (subquery)

The left-hand side of this form of ALL is a row constructor, + as described in Section 4.2.13. + The right-hand side is a parenthesized + subquery, which must return exactly as many columns as there are + expressions in the left-hand row. The left-hand expressions are + evaluated and compared row-wise to each row of the subquery result, + using the given operator. + The result of ALL is "true" if the comparison + returns true for all subquery rows (including the + case where the subquery returns no rows). + The result is "false" if the comparison returns false for any + subquery row. + The result is NULL if the comparison does not return false for any + subquery row, and it returns NULL for at least one row. +

See Section 9.23.5 for details about the meaning + of a row-wise comparison. +

9.22.6. Row-wise Comparison

row_constructor operator (subquery)

The left-hand side is a row constructor, + as described in Section 4.2.13. + The right-hand side is a parenthesized subquery, which must return exactly + as many columns as there are expressions in the left-hand row. Furthermore, + the subquery cannot return more than one row. (If it returns zero rows, + the result is taken to be null.) The left-hand side is evaluated and + compared row-wise to the single subquery result row. +

See Section 9.23.5 for details about the meaning + of a row-wise comparison. +


PrevHomeNext
Window FunctionsUpRow and Array Comparisons
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-textsearch.html b/doc/src/sgml/html/functions-textsearch.html new file mode 100644 index 000000000..6b4c456ba --- /dev/null +++ b/doc/src/sgml/html/functions-textsearch.html @@ -0,0 +1,1703 @@ + +Text Search Functions and Operators
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.13. Text Search Functions and Operators

Table 9-36, + Table 9-37 and + Table 9-38 + summarize the functions and operators that are provided + for full text searching. See Chapter 12 for a detailed + explanation of PostgreSQL's text search + facility. +

Table 9-36. Text Search Operators

OperatorDescriptionExampleResult
@@ tsvector matches tsquery ?to_tsvector('fat cats ate rats') @@ to_tsquery('cat & rat')t
@@@ deprecated synonym for @@to_tsvector('fat cats ate rats') @@@ to_tsquery('cat & rat')t
|| concatenate tsvectors'a:1 b:2'::tsvector || 'c:1 d:2 b:3'::tsvector'a':1 'b':2,5 'c':3 'd':4
&& AND tsquerys together'fat | rat'::tsquery && 'cat'::tsquery( 'fat' | 'rat' ) & 'cat'
|| OR tsquerys together'fat | rat'::tsquery || 'cat'::tsquery( 'fat' | 'rat' ) | 'cat'
!! negate a tsquery!! 'cat'::tsquery!'cat'
@> tsquery contains another ?'cat'::tsquery @> 'cat & rat'::tsqueryf
<@ tsquery is contained in ?'cat'::tsquery <@ 'cat & rat'::tsqueryt

Note: The tsquery containment operators consider only the lexemes + listed in the two queries, ignoring the combining operators. +

In addition to the operators shown in the table, the ordinary B-tree + comparison operators (=, <, etc) are defined + for types tsvector and tsquery. These are not very + useful for text searching but allow, for example, unique indexes to be + built on columns of these types. +

Table 9-37. Text Search Functions

FunctionReturn TypeDescriptionExampleResult
+ get_current_ts_config() + regconfigget default text search configurationget_current_ts_config()english
+ length(tsvector) + integernumber of lexemes in tsvectorlength('fat:2,4 cat:3 rat:5A'::tsvector)3
+ numnode(tsquery) + integernumber of lexemes plus operators in tsquery numnode('(fat & rat) | cat'::tsquery)5
+ plainto_tsquery([ config regconfig , ] query text) + tsqueryproduce tsquery ignoring punctuationplainto_tsquery('english', 'The Fat Rats')'fat' & 'rat'
+ querytree(query tsquery) + textget indexable part of a tsqueryquerytree('foo & ! bar'::tsquery)'foo'
+ setweight(tsvector, "char") + tsvectorassign weight to each element of tsvectorsetweight('fat:2,4 cat:3 rat:5B'::tsvector, 'A')'cat':3A 'fat':2A,4A 'rat':5A
+ strip(tsvector) + tsvectorremove positions and weights from tsvectorstrip('fat:2,4 cat:3 rat:5A'::tsvector)'cat' 'fat' 'rat'
+ to_tsquery([ config regconfig , ] query text) + tsquerynormalize words and convert to tsqueryto_tsquery('english', 'The & Fat & Rats')'fat' & 'rat'
+ to_tsvector([ config regconfig , ] document text) + tsvectorreduce document text to tsvectorto_tsvector('english', 'The Fat Rats')'fat':2 'rat':3
+ ts_headline([ config regconfig, ] document text, query tsquery [, options text ]) + textdisplay a query matchts_headline('x y z', 'z'::tsquery)x y <b>z</b>
+ ts_rank([ weights float4[], ] vector tsvector, query tsquery [, normalization integer ]) + float4rank document for queryts_rank(textsearch, query)0.818
+ ts_rank_cd([ weights float4[], ] vector tsvector, query tsquery [, normalization integer ]) + float4rank document for query using cover densityts_rank_cd('{0.1, 0.2, 0.4, 1.0}', textsearch, query)2.01317
+ ts_rewrite(query tsquery, target tsquery, substitute tsquery) + tsqueryreplace target with substitute within queryts_rewrite('a & b'::tsquery, 'a'::tsquery, 'foo|bar'::tsquery)'b' & ( 'foo' | 'bar' )
ts_rewrite(query tsquery, select text)tsqueryreplace using targets and substitutes from a SELECT commandSELECT ts_rewrite('a & b'::tsquery, 'SELECT t,s FROM aliases')'b' & ( 'foo' | 'bar' )
+ tsvector_update_trigger() + triggertrigger function for automatic tsvector column updateCREATE TRIGGER ... tsvector_update_trigger(tsvcol, 'pg_catalog.swedish', title, body)
+ tsvector_update_trigger_column() + triggertrigger function for automatic tsvector column updateCREATE TRIGGER ... tsvector_update_trigger_column(tsvcol, configcol, title, body)

Note: All the text search functions that accept an optional regconfig + argument will use the configuration specified by + default_text_search_config + when that argument is omitted. +

The functions in + Table 9-38 + are listed separately because they are not usually used in everyday text + searching operations. They are helpful for development and debugging + of new text search configurations. +

Table 9-38. Text Search Debugging Functions

FunctionReturn TypeDescriptionExampleResult
+ ts_debug([ config regconfig, ] document text, OUT alias text, OUT description text, OUT token text, OUT dictionaries regdictionary[], OUT dictionary regdictionary, OUT lexemes text[]) + setof recordtest a configurationts_debug('english', 'The Brightest supernovaes')(asciiword,"Word, all ASCII",The,{english_stem},english_stem,{}) ...
+ ts_lexize(dict regdictionary, token text) + text[]test a dictionaryts_lexize('english_stem', 'stars'){star}
+ ts_parse(parser_name text, document text, OUT tokid integer, OUT token text) + setof recordtest a parserts_parse('default', 'foo - bar')(1,foo) ...
ts_parse(parser_oid oid, document text, OUT tokid integer, OUT token text)setof recordtest a parserts_parse(3722, 'foo - bar')(1,foo) ...
+ ts_token_type(parser_name text, OUT tokid integer, OUT alias text, OUT description text) + setof recordget token types defined by parserts_token_type('default')(1,asciiword,"Word, all ASCII") ...
ts_token_type(parser_oid oid, OUT tokid integer, OUT alias text, OUT description text)setof recordget token types defined by parserts_token_type(3722)(1,asciiword,"Word, all ASCII") ...
+ ts_stat(sqlquery text, [ weights text, ] OUT word text, OUT ndoc integer, OUT nentry integer) + setof recordget statistics of a tsvector columnts_stat('SELECT vector from apod')(foo,10,15) ...

PrevHomeNext
Network Address Functions and OperatorsUpXML Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-trigger.html b/doc/src/sgml/html/functions-trigger.html new file mode 100644 index 000000000..602280eeb --- /dev/null +++ b/doc/src/sgml/html/functions-trigger.html @@ -0,0 +1,220 @@ + +Trigger Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.27. Trigger Functions

Currently PostgreSQL provides one built in trigger + function, suppress_redundant_updates_trigger, + which will prevent any update + that does not actually change the data in the row from taking place, in + contrast to the normal behavior which always performs the update + regardless of whether or not the data has changed. (This normal behavior + makes updates run faster, since no checking is required, and is also + useful in certain cases.) +

Ideally, you should normally avoid running updates that don't actually + change the data in the record. Redundant updates can cost considerable + unnecessary time, especially if there are lots of indexes to alter, + and space in dead rows that will eventually have to be vacuumed. + However, detecting such situations in client code is not + always easy, or even possible, and writing expressions to detect + them can be error-prone. An alternative is to use + suppress_redundant_updates_trigger, which will skip + updates that don't change the data. You should use this with care, + however. The trigger takes a small but non-trivial time for each record, + so if most of the records affected by an update are actually changed, + use of this trigger will actually make the update run slower. +

The suppress_redundant_updates_trigger function can be + added to a table like this: +

CREATE TRIGGER z_min_update
+BEFORE UPDATE ON tablename
+FOR EACH ROW EXECUTE PROCEDURE suppress_redundant_updates_trigger();

+ In most cases, you would want to fire this trigger last for each row. + Bearing in mind that triggers fire in name order, you would then + choose a trigger name that comes after the name of any other trigger + you might have on the table. +

For more information about creating triggers, see + CREATE TRIGGER. +


PrevHomeNext
System Administration FunctionsUpType Conversion
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-window.html b/doc/src/sgml/html/functions-window.html new file mode 100644 index 000000000..d91885288 --- /dev/null +++ b/doc/src/sgml/html/functions-window.html @@ -0,0 +1,811 @@ + +Window Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.21. Window Functions

Window functions provide the ability to perform + calculations across sets of rows that are related to the current query + row. See Section 3.5 for an introduction to this + feature. +

The built-in window functions are listed in + Table 9-47. Note that these functions + must be invoked using window function syntax; that is an + OVER clause is required. +

In addition to these functions, any built-in or user-defined aggregate + function can be used as a window function (see + Section 9.20 for a list of the built-in aggregates). + Aggregate functions act as window functions only when an OVER + clause follows the call; otherwise they act as regular aggregates. +

Table 9-47. General-Purpose Window Functions

FunctionReturn TypeDescription
+ row_number() + bigint + number of the current row within its partition, counting from 1
+ rank() + bigint + rank of the current row with gaps; same as row_number of its first peer
+ dense_rank() + bigint + rank of the current row without gaps; this function counts peer groups
+ percent_rank() + double precision + relative rank of the current row: (rank - 1) / (total rows - 1)
+ cume_dist() + double precision + relative rank of the current row: (number of rows preceding or peer with current row) / (total rows)
+ ntile(num_buckets integer) + integer + integer ranging from 1 to the argument value, dividing the + partition as equally as possible
+ lag(value any + [, offset integer + [, default any ]]) + + same type as value + returns value evaluated at + the row that is offset + rows before the current row within the partition; if there is no such + row, instead return default. + Both offset and + default are evaluated + with respect to the current row. If omitted, + offset defaults to 1 and + default to null +
+ lead(value any + [, offset integer + [, default any ]]) + + same type as value + returns value evaluated at + the row that is offset + rows after the current row within the partition; if there is no such + row, instead return default. + Both offset and + default are evaluated + with respect to the current row. If omitted, + offset defaults to 1 and + default to null +
+ first_value(value any) + same type as value + returns value evaluated + at the row that is the first row of the window frame +
+ last_value(value any) + same type as value + returns value evaluated + at the row that is the last row of the window frame +
+ nth_value(value any, nth integer) + + same type as value + returns value evaluated + at the row that is the nth + row of the window frame (counting from 1); null if no such row +

All of the functions listed in + Table 9-47 depend on the sort ordering + specified by the ORDER BY clause of the associated window + definition. Rows that are not distinct in the ORDER BY + ordering are said to be peers; the four ranking functions + are defined so that they give the same answer for any two peer rows. +

Note that first_value, last_value, and + nth_value consider only the rows within the "window + frame", which by default contains the rows from the start of the + partition through the last peer of the current row. This is + likely to give unhelpful results for last_value and + sometimes also nth_value. You can redefine the frame by + adding a suitable frame specification (RANGE or + ROWS) to the OVER clause. + See Section 4.2.8 for more information + about frame specifications. +

When an aggregate function is used as a window function, it aggregates + over the rows within the current row's window frame. + An aggregate used with ORDER BY and the default window frame + definition produces a "running sum" type of behavior, which may or + may not be what's wanted. To obtain + aggregation over the whole partition, omit ORDER BY or use + ROWS BETWEEN UNBOUNDED PRECEDING AND UNBOUNDED FOLLOWING. + Other frame specifications can be used to obtain other effects. +

Note: The SQL standard defines a RESPECT NULLS or + IGNORE NULLS option for lead, lag, + first_value, last_value, and + nth_value. This is not implemented in + PostgreSQL: the behavior is always the + same as the standard's default, namely RESPECT NULLS. + Likewise, the standard's FROM FIRST or FROM LAST + option for nth_value is not implemented: only the + default FROM FIRST behavior is supported. (You can achieve + the result of FROM LAST by reversing the ORDER BY + ordering.) +


PrevHomeNext
Aggregate FunctionsUpSubquery Expressions
\ No newline at end of file diff --git a/doc/src/sgml/html/functions-xml.html b/doc/src/sgml/html/functions-xml.html new file mode 100644 index 000000000..ca63a4304 --- /dev/null +++ b/doc/src/sgml/html/functions-xml.html @@ -0,0 +1,1533 @@ + +XML Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 9. Functions and OperatorsNext

9.14. XML Functions

The functions and function-like expressions described in this + section operate on values of type xml. Check Section 8.13 for information about the xml + type. The function-like expressions xmlparse + and xmlserialize for converting to and from + type xml are not repeated here. Use of most of these + functions requires the installation to have been built + with configure --with-libxml. +

9.14.1. Producing XML Content

A set of functions and function-like expressions are available for + producing XML content from SQL data. As such, they are + particularly suitable for formatting query results into XML + documents for processing in client applications. +

9.14.1.1. xmlcomment

xmlcomment(text)

The function xmlcomment creates an XML value + containing an XML comment with the specified text as content. + The text cannot contain "--" or end with a + "-" so that the resulting construct is a valid + XML comment. If the argument is null, the result is null. +

Example: +

SELECT xmlcomment('hello');
+
+  xmlcomment
+--------------
+ <!--hello-->

+

9.14.1.2. xmlconcat

xmlconcat(xml[, ...])

The function xmlconcat concatenates a list + of individual XML values to create a single value containing an + XML content fragment. Null values are omitted; the result is + only null if there are no nonnull arguments. +

Example: +

SELECT xmlconcat('<abc/>', '<bar>foo</bar>');
+
+      xmlconcat
+----------------------
+ <abc/><bar>foo</bar>

+

XML declarations, if present, are combined as follows. If all + argument values have the same XML version declaration, that + version is used in the result, else no version is used. If all + argument values have the standalone declaration value + "yes", then that value is used in the result. If + all argument values have a standalone declaration value and at + least one is "no", then that is used in the result. + Else the result will have no standalone declaration. If the + result is determined to require a standalone declaration but no + version declaration, a version declaration with version 1.0 will + be used because XML requires an XML declaration to contain a + version declaration. Encoding declarations are ignored and + removed in all cases. +

Example: +

SELECT xmlconcat('<?xml version="1.1"?><foo/>', '<?xml version="1.1" standalone="no"?><bar/>');
+
+             xmlconcat
+-----------------------------------
+ <?xml version="1.1"?><foo/><bar/>

+

9.14.1.3. xmlelement

xmlelement(name name [, xmlattributes(value [AS attname] [, ... ])] [, content, ...])

The xmlelement expression produces an XML + element with the given name, attributes, and content. +

Examples: +

SELECT xmlelement(name foo);
+
+ xmlelement
+------------
+ <foo/>
+
+SELECT xmlelement(name foo, xmlattributes('xyz' as bar));
+
+    xmlelement
+------------------
+ <foo bar="xyz"/>
+
+SELECT xmlelement(name foo, xmlattributes(current_date as bar), 'cont', 'ent');
+
+             xmlelement
+-------------------------------------
+ <foo bar="2007-01-26">content</foo>

+

Element and attribute names that are not valid XML names are + escaped by replacing the offending characters by the sequence + _xHHHH_, where + HHHH is the character's Unicode + codepoint in hexadecimal notation. For example: +

SELECT xmlelement(name "foo$bar", xmlattributes('xyz' as "a&b"));
+
+            xmlelement
+----------------------------------
+ <foo_x0024_bar a_x0026_b="xyz"/>

+

An explicit attribute name need not be specified if the attribute + value is a column reference, in which case the column's name will + be used as the attribute name by default. In other cases, the + attribute must be given an explicit name. So this example is + valid: +

CREATE TABLE test (a xml, b xml);
+SELECT xmlelement(name test, xmlattributes(a, b)) FROM test;

+ But these are not: +

SELECT xmlelement(name test, xmlattributes('constant'), a, b) FROM test;
+SELECT xmlelement(name test, xmlattributes(func(a, b))) FROM test;

+

Element content, if specified, will be formatted according to + its data type. If the content is itself of type xml, + complex XML documents can be constructed. For example: +

SELECT xmlelement(name foo, xmlattributes('xyz' as bar),
+                            xmlelement(name abc),
+                            xmlcomment('test'),
+                            xmlelement(name xyz));
+
+                  xmlelement
+----------------------------------------------
+ <foo bar="xyz"><abc/><!--test--><xyz/></foo>

+ + Content of other types will be formatted into valid XML character + data. This means in particular that the characters <, >, + and & will be converted to entities. Binary data (data type + bytea) will be represented in base64 or hex + encoding, depending on the setting of the configuration parameter + xmlbinary. The particular behavior for + individual data types is expected to evolve in order to align the + SQL and PostgreSQL data types with the XML Schema specification, + at which point a more precise description will appear. +

9.14.1.4. xmlforest

xmlforest(content [AS name] [, ...])

The xmlforest expression produces an XML + forest (sequence) of elements using the given names and content. +

Examples: +

SELECT xmlforest('abc' AS foo, 123 AS bar);
+
+          xmlforest
+------------------------------
+ <foo>abc</foo><bar>123</bar>
+
+
+SELECT xmlforest(table_name, column_name)
+FROM information_schema.columns
+WHERE table_schema = 'pg_catalog';
+
+                                         xmlforest
+-------------------------------------------------------------------------------------------
+ <table_name>pg_authid</table_name><column_name>rolname</column_name>
+ <table_name>pg_authid</table_name><column_name>rolsuper</column_name>
+ ...

+ + As seen in the second example, the element name can be omitted if + the content value is a column reference, in which case the column + name is used by default. Otherwise, a name must be specified. +

Element names that are not valid XML names are escaped as shown + for xmlelement above. Similarly, content + data is escaped to make valid XML content, unless it is already + of type xml. +

Note that XML forests are not valid XML documents if they consist + of more than one element, so it might be useful to wrap + xmlforest expressions in + xmlelement. +

9.14.1.5. xmlpi

xmlpi(name target [, content])

The xmlpi expression creates an XML + processing instruction. The content, if present, must not + contain the character sequence ?>. +

Example: +

SELECT xmlpi(name php, 'echo "hello world";');
+
+            xmlpi
+-----------------------------
+ <?php echo "hello world";?>

+

9.14.1.6. xmlroot

xmlroot(xml, version text | no value [, standalone yes|no|no value])

The xmlroot expression alters the properties + of the root node of an XML value. If a version is specified, + it replaces the value in the root node's version declaration; if a + standalone setting is specified, it replaces the value in the + root node's standalone declaration. +

SELECT xmlroot(xmlparse(document '<?xml version="1.1"?><content>abc</content>'),
+               version '1.0', standalone yes);
+
+                xmlroot
+----------------------------------------
+ <?xml version="1.0" standalone="yes"?>
+ <content>abc</content>

+

9.14.1.7. xmlagg

xmlagg(xml)

The function xmlagg is, unlike the other + functions described here, an aggregate function. It concatenates the + input values to the aggregate function call, + much like xmlconcat does, except that concatenation + occurs across rows rather than across expressions in a single row. + See Section 9.20 for additional information + about aggregate functions. +

Example: +

CREATE TABLE test (y int, x xml);
+INSERT INTO test VALUES (1, '<foo>abc</foo>');
+INSERT INTO test VALUES (2, '<bar/>');
+SELECT xmlagg(x) FROM test;
+        xmlagg
+----------------------
+ <foo>abc</foo><bar/>

+

To determine the order of the concatenation, an ORDER BY + clause may be added to the aggregate call as described in + Section 4.2.7. For example: + +

SELECT xmlagg(x ORDER BY y DESC) FROM test;
+        xmlagg
+----------------------
+ <bar/><foo>abc</foo>

+

The following non-standard approach used to be recommended + in previous versions, and may still be useful in specific + cases: + +

SELECT xmlagg(x) FROM (SELECT * FROM test ORDER BY y DESC) AS tab;
+        xmlagg
+----------------------
+ <bar/><foo>abc</foo>

+

9.14.2. XML Predicates

The expressions described in this section check properties + of xml values. +

9.14.2.1. IS DOCUMENT

xml IS DOCUMENT

The expression IS DOCUMENT returns true if the + argument XML value is a proper XML document, false if it is not + (that is, it is a content fragment), or null if the argument is + null. See Section 8.13 about the difference + between documents and content fragments. +

9.14.2.2. XMLEXISTS

XMLEXISTS(text PASSING [BY REF] xml [BY REF])

The function xmlexists returns true if the + XPath expression in the first argument returns any nodes, and + false otherwise. (If either argument is null, the result is + null.) +

Example: +

SELECT xmlexists('//town[text() = ''Toronto'']' PASSING BY REF '<towns><town>Toronto</town><town>Ottawa</town></towns>');
+
+ xmlexists
+------------
+ t
+(1 row)

+

The BY REF clauses have no effect in + PostgreSQL, but are allowed for SQL conformance and compatibility + with other implementations. Per SQL standard, the + first BY REF is required, the second is + optional. Also note that the SQL standard specifies + the xmlexists construct to take an XQuery + expression as first argument, but PostgreSQL currently only + supports XPath, which is a subset of XQuery. +

9.14.2.3. xml_is_well_formed

xml_is_well_formed(text)
+xml_is_well_formed_document(text)
+xml_is_well_formed_content(text)

These functions check whether a text string is well-formed XML, + returning a Boolean result. + xml_is_well_formed_document checks for a well-formed + document, while xml_is_well_formed_content checks + for well-formed content. xml_is_well_formed does + the former if the xmloption configuration + parameter is set to DOCUMENT, or the latter if it is set to + CONTENT. This means that + xml_is_well_formed is useful for seeing whether + a simple cast to type xml will succeed, whereas the other two + functions are useful for seeing whether the corresponding variants of + XMLPARSE will succeed. +

Examples: + +

SET xmloption TO DOCUMENT;
+SELECT xml_is_well_formed('<>');
+ xml_is_well_formed 
+--------------------
+ f
+(1 row)
+
+SELECT xml_is_well_formed('<abc/>');
+ xml_is_well_formed 
+--------------------
+ t
+(1 row)
+
+SET xmloption TO CONTENT;
+SELECT xml_is_well_formed('abc');
+ xml_is_well_formed 
+--------------------
+ t
+(1 row)
+
+SELECT xml_is_well_formed_document('<pg:foo xmlns:pg="http://postgresql.org/stuff">bar</pg:foo>');
+ xml_is_well_formed_document 
+-----------------------------
+ t
+(1 row)
+
+SELECT xml_is_well_formed_document('<pg:foo xmlns:pg="http://postgresql.org/stuff">bar</my:foo>');
+ xml_is_well_formed_document 
+-----------------------------
+ f
+(1 row)

+ + The last example shows that the checks include whether + namespaces are correctly matched. +

9.14.3. Processing XML

To process values of data type xml, PostgreSQL offers + the functions xpath and + xpath_exists, which evaluate XPath 1.0 + expressions. +

xpath(xpath, xml [, nsarray])

The function xpath evaluates the XPath + expression xpath (a text value) + against the XML value + xml. It returns an array of XML values + corresponding to the node set produced by the XPath expression. + If the XPath expression returns a scalar value rather than a node set, + a single-element array is returned. +

The second argument must be a well formed XML document. In particular, + it must have a single root node element. +

The optional third argument of the function is an array of namespace + mappings. This array should be a two-dimensional text array with + the length of the second axis being equal to 2 (i.e., it should be an + array of arrays, each of which consists of exactly 2 elements). + The first element of each array entry is the namespace name (alias), the + second the namespace URI. It is not required that aliases provided in + this array be the same as those being used in the XML document itself (in + other words, both in the XML document and in the xpath + function context, aliases are local). +

Example: +

SELECT xpath('/my:a/text()', '<my:a xmlns:my="http://example.com">test</my:a>',
+             ARRAY[ARRAY['my', 'http://example.com']]);
+
+ xpath  
+--------
+ {test}
+(1 row)

+

To deal with default (anonymous) namespaces, do something like this: +

SELECT xpath('//mydefns:b/text()', '<a xmlns="http://example.com"><b>test</b></a>',
+             ARRAY[ARRAY['mydefns', 'http://example.com']]);
+
+ xpath
+--------
+ {test}
+(1 row)

+

xpath_exists(xpath, xml [, nsarray])

The function xpath_exists is a specialized form + of the xpath function. Instead of returning the + individual XML values that satisfy the XPath, this function returns a + Boolean indicating whether the query was satisfied or not. This + function is equivalent to the standard XMLEXISTS predicate, + except that it also offers support for a namespace mapping argument. +

Example: +

SELECT xpath_exists('/my:a/text()', '<my:a xmlns:my="http://example.com">test</my:a>',
+                     ARRAY[ARRAY['my', 'http://example.com']]);
+
+ xpath_exists  
+--------------
+ t
+(1 row)

+

9.14.4. Mapping Tables to XML

The following functions map the contents of relational tables to + XML values. They can be thought of as XML export functionality: +

table_to_xml(tbl regclass, nulls boolean, tableforest boolean, targetns text)
+query_to_xml(query text, nulls boolean, tableforest boolean, targetns text)
+cursor_to_xml(cursor refcursor, count int, nulls boolean,
+              tableforest boolean, targetns text)

+ The return type of each function is xml. +

table_to_xml maps the content of the named + table, passed as parameter tbl. The + regclass type accepts strings identifying tables using the + usual notation, including optional schema qualifications and + double quotes. query_to_xml executes the + query whose text is passed as parameter + query and maps the result set. + cursor_to_xml fetches the indicated number of + rows from the cursor specified by the parameter + cursor. This variant is recommended if + large tables have to be mapped, because the result value is built + up in memory by each function. +

If tableforest is false, then the resulting + XML document looks like this: +

<tablename>
+  <row>
+    <columnname1>data</columnname1>
+    <columnname2>data</columnname2>
+  </row>
+
+  <row>
+    ...
+  </row>
+
+  ...
+</tablename>

+ + If tableforest is true, the result is an + XML content fragment that looks like this: +

<tablename>
+  <columnname1>data</columnname1>
+  <columnname2>data</columnname2>
+</tablename>
+
+<tablename>
+  ...
+</tablename>
+
+...

+ + If no table name is available, that is, when mapping a query or a + cursor, the string table is used in the first + format, row in the second format. +

The choice between these formats is up to the user. The first + format is a proper XML document, which will be important in many + applications. The second format tends to be more useful in the + cursor_to_xml function if the result values are to be + reassembled into one document later on. The functions for + producing XML content discussed above, in particular + xmlelement, can be used to alter the results + to taste. +

The data values are mapped in the same way as described for the + function xmlelement above. +

The parameter nulls determines whether null + values should be included in the output. If true, null values in + columns are represented as: +

<columnname xsi:nil="true"/>

+ where xsi is the XML namespace prefix for XML + Schema Instance. An appropriate namespace declaration will be + added to the result value. If false, columns containing null + values are simply omitted from the output. +

The parameter targetns specifies the + desired XML namespace of the result. If no particular namespace + is wanted, an empty string should be passed. +

The following functions return XML Schema documents describing the + mappings performed by the corresponding functions above: +

table_to_xmlschema(tbl regclass, nulls boolean, tableforest boolean, targetns text)
+query_to_xmlschema(query text, nulls boolean, tableforest boolean, targetns text)
+cursor_to_xmlschema(cursor refcursor, nulls boolean, tableforest boolean, targetns text)

+ It is essential that the same parameters are passed in order to + obtain matching XML data mappings and XML Schema documents. +

The following functions produce XML data mappings and the + corresponding XML Schema in one document (or forest), linked + together. They can be useful where self-contained and + self-describing results are wanted: +

table_to_xml_and_xmlschema(tbl regclass, nulls boolean, tableforest boolean, targetns text)
+query_to_xml_and_xmlschema(query text, nulls boolean, tableforest boolean, targetns text)

+

In addition, the following functions are available to produce + analogous mappings of entire schemas or the entire current + database: +

schema_to_xml(schema name, nulls boolean, tableforest boolean, targetns text)
+schema_to_xmlschema(schema name, nulls boolean, tableforest boolean, targetns text)
+schema_to_xml_and_xmlschema(schema name, nulls boolean, tableforest boolean, targetns text)
+
+database_to_xml(nulls boolean, tableforest boolean, targetns text)
+database_to_xmlschema(nulls boolean, tableforest boolean, targetns text)
+database_to_xml_and_xmlschema(nulls boolean, tableforest boolean, targetns text)

+ + Note that these potentially produce a lot of data, which needs to + be built up in memory. When requesting content mappings of large + schemas or databases, it might be worthwhile to consider mapping the + tables separately instead, possibly even through a cursor. +

The result of a schema content mapping looks like this: + +

<schemaname>
+
+table1-mapping
+
+table2-mapping
+
+...
+
+</schemaname>

+ + where the format of a table mapping depends on the + tableforest parameter as explained above. +

The result of a database content mapping looks like this: + +

<dbname>
+
+<schema1name>
+  ...
+</schema1name>
+
+<schema2name>
+  ...
+</schema2name>
+
+...
+
+</dbname>

+ + where the schema mapping is as above. +

As an example of using the output produced by these functions, + Figure 9-1 shows an XSLT stylesheet that + converts the output of + table_to_xml_and_xmlschema to an HTML + document containing a tabular rendition of the table data. In a + similar manner, the results from these functions can be + converted into other XML-based formats. +

Figure 9-1. XSLT Stylesheet for Converting SQL/XML Output to HTML

<?xml version="1.0"?>
+<xsl:stylesheet version="1.0"
+    xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+    xmlns="http://www.w3.org/1999/xhtml"
+>
+
+  <xsl:output method="xml"
+      doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"
+      doctype-public="-//W3C/DTD XHTML 1.0 Strict//EN"
+      indent="yes"/>
+
+  <xsl:template match="/*">
+    <xsl:variable name="schema" select="//xsd:schema"/>
+    <xsl:variable name="tabletypename"
+                  select="$schema/xsd:element[@name=name(current())]/@type"/>
+    <xsl:variable name="rowtypename"
+                  select="$schema/xsd:complexType[@name=$tabletypename]/xsd:sequence/xsd:element[@name='row']/@type"/>
+
+    <html>
+      <head>
+        <title><xsl:value-of select="name(current())"/></title>
+      </head>
+      <body>
+        <table>
+          <tr>
+            <xsl:for-each select="$schema/xsd:complexType[@name=$rowtypename]/xsd:sequence/xsd:element/@name">
+              <th><xsl:value-of select="."/></th>
+            </xsl:for-each>
+          </tr>
+
+          <xsl:for-each select="row">
+            <tr>
+              <xsl:for-each select="*">
+                <td><xsl:value-of select="."/></td>
+              </xsl:for-each>
+            </tr>
+          </xsl:for-each>
+        </table>
+      </body>
+    </html>
+  </xsl:template>
+
+</xsl:stylesheet>

PrevHomeNext
Text Search Functions and OperatorsUpJSON Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/functions.html b/doc/src/sgml/html/functions.html new file mode 100644 index 000000000..1aea56db4 --- /dev/null +++ b/doc/src/sgml/html/functions.html @@ -0,0 +1,620 @@ + +Functions and Operators

Chapter 9. Functions and Operators

Table of Contents
9.1. Logical Operators
9.2. Comparison Operators
9.3. Mathematical Functions and Operators
9.4. String Functions and Operators
9.5. Binary String Functions and Operators
9.6. Bit String Functions and Operators
9.7. Pattern Matching
9.7.1. LIKE
9.7.2. SIMILAR TO Regular Expressions
9.7.3. POSIX Regular Expressions
9.8. Data Type Formatting Functions
9.9. Date/Time Functions and Operators
9.9.1. EXTRACT, date_part
9.9.2. date_trunc
9.9.3. AT TIME ZONE
9.9.4. Current Date/Time
9.9.5. Delaying Execution
9.10. Enum Support Functions
9.11. Geometric Functions and Operators
9.12. Network Address Functions and Operators
9.13. Text Search Functions and Operators
9.14. XML Functions
9.14.1. Producing XML Content
9.14.2. XML Predicates
9.14.3. Processing XML
9.14.4. Mapping Tables to XML
9.15. JSON Functions
9.16. Sequence Manipulation Functions
9.17. Conditional Expressions
9.17.1. CASE
9.17.2. COALESCE
9.17.3. NULLIF
9.17.4. GREATEST and LEAST
9.18. Array Functions and Operators
9.19. Range Functions and Operators
9.20. Aggregate Functions
9.21. Window Functions
9.22. Subquery Expressions
9.22.1. EXISTS
9.22.2. IN
9.22.3. NOT IN
9.22.4. ANY/SOME
9.22.5. ALL
9.22.6. Row-wise Comparison
9.23. Row and Array Comparisons
9.23.1. IN
9.23.2. NOT IN
9.23.3. ANY/SOME (array)
9.23.4. ALL (array)
9.23.5. Row-wise Comparison
9.24. Set Returning Functions
9.25. System Information Functions
9.26. System Administration Functions
9.26.1. Configuration Settings Functions
9.26.2. Server Signalling Functions
9.26.3. Backup Control Functions
9.26.4. Recovery Control Functions
9.26.5. Snapshot Synchronization Functions
9.26.6. Database Object Management Functions
9.26.7. Generic File Access Functions
9.26.8. Advisory Lock Functions
9.27. Trigger Functions

PostgreSQL provides a large number of + functions and operators for the built-in data types. Users can also + define their own functions and operators, as described in + Part V. The + psql commands \df and + \do can be used to list all + available functions and operators, respectively. +

If you are concerned about portability then note that most of + the functions and operators described in this chapter, with the + exception of the most trivial arithmetic and comparison operators + and some explicitly marked functions, are not specified by the + SQL standard. Some of this extended functionality + is present in other SQL database management + systems, and in many cases this functionality is compatible and + consistent between the various implementations. This chapter is also + not exhaustive; additional functions appear in relevant sections of + the manual. +


PrevHomeNext
Pseudo-TypesUpLogical Operators
\ No newline at end of file diff --git a/doc/src/sgml/html/fuzzystrmatch.html b/doc/src/sgml/html/fuzzystrmatch.html new file mode 100644 index 000000000..4f7aa57c3 --- /dev/null +++ b/doc/src/sgml/html/fuzzystrmatch.html @@ -0,0 +1,428 @@ + +fuzzystrmatch
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.15. fuzzystrmatch

The fuzzystrmatch module provides several + functions to determine similarities and distance between strings. +

Caution

At present, the soundex, metaphone, + dmetaphone, and dmetaphone_alt functions do + not work well with multibyte encodings (such as UTF-8). +

F.15.1. Soundex

The Soundex system is a method of matching similar-sounding names + by converting them to the same code. It was initially used by the + United States Census in 1880, 1900, and 1910. Note that Soundex + is not very useful for non-English names. +

The fuzzystrmatch module provides two functions + for working with Soundex codes: +

soundex(text) returns text
+difference(text, text) returns int

The soundex function converts a string to its Soundex code. + The difference function converts two strings to their Soundex + codes and then reports the number of matching code positions. Since + Soundex codes have four characters, the result ranges from zero to four, + with zero being no match and four being an exact match. (Thus, the + function is misnamed — similarity would have been + a better name.) +

Here are some usage examples: +

SELECT soundex('hello world!');
+
+SELECT soundex('Anne'), soundex('Ann'), difference('Anne', 'Ann');
+SELECT soundex('Anne'), soundex('Andrew'), difference('Anne', 'Andrew');
+SELECT soundex('Anne'), soundex('Margaret'), difference('Anne', 'Margaret');
+
+CREATE TABLE s (nm text);
+
+INSERT INTO s VALUES ('john');
+INSERT INTO s VALUES ('joan');
+INSERT INTO s VALUES ('wobbly');
+INSERT INTO s VALUES ('jack');
+
+SELECT * FROM s WHERE soundex(nm) = soundex('john');
+
+SELECT * FROM s WHERE difference(s.nm, 'john') > 2;

F.15.2. Levenshtein

This function calculates the Levenshtein distance between two strings: +

levenshtein(text source, text target, int ins_cost, int del_cost, int sub_cost) returns int
+levenshtein(text source, text target) returns int
+levenshtein_less_equal(text source, text target, int ins_cost, int del_cost, int sub_cost, int max_d) returns int
+levenshtein_less_equal(text source, text target, int max_d) returns int

Both source and target can be any + non-null string, with a maximum of 255 bytes. The cost parameters + specify how much to charge for a character insertion, deletion, or + substitution, respectively. You can omit the cost parameters, as in + the second version of the function; in that case they all default to 1. + levenshtein_less_equal is accelerated version of + levenshtein function for low values of distance. If actual distance + is less or equal then max_d, then levenshtein_less_equal + returns accurate value of it. Otherwise this function returns value + which is greater than max_d. +

Examples: +

test=# SELECT levenshtein('GUMBO', 'GAMBOL');
+ levenshtein
+-------------
+           2
+(1 row)
+
+test=# SELECT levenshtein('GUMBO', 'GAMBOL', 2,1,1);
+ levenshtein
+-------------
+           3
+(1 row)
+
+test=# SELECT levenshtein_less_equal('extensive', 'exhaustive',2);
+ levenshtein_less_equal
+------------------------
+                      3
+(1 row)
+
+test=# SELECT levenshtein_less_equal('extensive', 'exhaustive',4);
+ levenshtein_less_equal
+------------------------
+                      4
+(1 row)

F.15.3. Metaphone

Metaphone, like Soundex, is based on the idea of constructing a + representative code for an input string. Two strings are then + deemed similar if they have the same codes. +

This function calculates the metaphone code of an input string: +

metaphone(text source, int max_output_length) returns text

source has to be a non-null string with a maximum of + 255 characters. max_output_length sets the maximum + length of the output metaphone code; if longer, the output is truncated + to this length. +

Example: +

test=# SELECT metaphone('GUMBO', 4);
+ metaphone
+-----------
+ KM
+(1 row)

F.15.4. Double Metaphone

The Double Metaphone system computes two "sounds like" strings + for a given input string — a "primary" and an + "alternate". In most cases they are the same, but for non-English + names especially they can be a bit different, depending on pronunciation. + These functions compute the primary and alternate codes: +

dmetaphone(text source) returns text
+dmetaphone_alt(text source) returns text

There is no length limit on the input strings. +

Example: +

test=# select dmetaphone('gumbo');
+ dmetaphone
+------------
+ KMP
+(1 row)

PrevHomeNext
file_fdwUphstore
\ No newline at end of file diff --git a/doc/src/sgml/html/geqo-biblio.html b/doc/src/sgml/html/geqo-biblio.html new file mode 100644 index 000000000..f60d681d3 --- /dev/null +++ b/doc/src/sgml/html/geqo-biblio.html @@ -0,0 +1,227 @@ + +Further Reading
PostgreSQL 9.2.2 Documentation
PrevUpChapter 51. Genetic Query OptimizerNext


PrevHomeNext
Genetic Query Optimization (GEQO) in PostgreSQLUpIndex Access Method Interface Definition
\ No newline at end of file diff --git a/doc/src/sgml/html/geqo-intro.html b/doc/src/sgml/html/geqo-intro.html new file mode 100644 index 000000000..b092a448c --- /dev/null +++ b/doc/src/sgml/html/geqo-intro.html @@ -0,0 +1,231 @@ + +Query Handling as a Complex Optimization Problem
PostgreSQL 9.2.2 Documentation
PrevUpChapter 51. Genetic Query OptimizerNext

51.1. Query Handling as a Complex Optimization Problem

Among all relational operators the most difficult one to process + and optimize is the join. The number of + possible query plans grows exponentially with the + number of joins in the query. Further optimization effort is + caused by the support of a variety of join + methods (e.g., nested loop, hash join, merge join in + PostgreSQL) to process individual joins + and a diversity of indexes (e.g., + B-tree, hash, GiST and GIN in PostgreSQL) as + access paths for relations. +

The normal PostgreSQL query optimizer + performs a near-exhaustive search over the + space of alternative strategies. This algorithm, first introduced + in IBM's System R database, produces a near-optimal join order, + but can take an enormous amount of time and memory space when the + number of joins in the query grows large. This makes the ordinary + PostgreSQL query optimizer + inappropriate for queries that join a large number of tables. +

The Institute of Automatic Control at the University of Mining and + Technology, in Freiberg, Germany, encountered some problems when + it wanted to use PostgreSQL as the + backend for a decision support knowledge based system for the + maintenance of an electrical power grid. The DBMS needed to handle + large join queries for the inference machine of the knowledge + based system. The number of joins in these queries made using the + normal query optimizer infeasible. +

In the following we describe the implementation of a + genetic algorithm to solve the join + ordering problem in a manner that is efficient for queries + involving large numbers of joins. +


PrevHomeNext
Genetic Query OptimizerUpGenetic Algorithms
\ No newline at end of file diff --git a/doc/src/sgml/html/geqo-intro2.html b/doc/src/sgml/html/geqo-intro2.html new file mode 100644 index 000000000..71c95b856 --- /dev/null +++ b/doc/src/sgml/html/geqo-intro2.html @@ -0,0 +1,301 @@ + +Genetic Algorithms
PostgreSQL 9.2.2 Documentation
PrevUpChapter 51. Genetic Query OptimizerNext

51.2. Genetic Algorithms

The genetic algorithm (GA) is a heuristic optimization method which + operates through randomized search. The set of possible solutions for the + optimization problem is considered as a + population of individuals. + The degree of adaptation of an individual to its environment is specified + by its fitness. +

The coordinates of an individual in the search space are represented + by chromosomes, in essence a set of character + strings. A gene is a + subsection of a chromosome which encodes the value of a single parameter + being optimized. Typical encodings for a gene could be binary or + integer. +

Through simulation of the evolutionary operations recombination, + mutation, and + selection new generations of search points are found + that show a higher average fitness than their ancestors. +

According to the comp.ai.genetic FAQ it cannot be stressed too + strongly that a GA is not a pure random search for a solution to a + problem. A GA uses stochastic processes, but the result is distinctly + non-random (better than random). +

Figure 51-1. Structured Diagram of a Genetic Algorithm

P(t)generation of ancestors at a time t
P''(t)generation of descendants at a time t

+=========================================+
+|>>>>>>>>>>>  Algorithm GA  <<<<<<<<<<<<<<|
++=========================================+
+| INITIALIZE t := 0                       |
++=========================================+
+| INITIALIZE P(t)                         |
++=========================================+
+| evaluate FITNESS of P(t)                |
++=========================================+
+| while not STOPPING CRITERION do         |
+|   +-------------------------------------+
+|   | P'(t)  := RECOMBINATION{P(t)}       |
+|   +-------------------------------------+
+|   | P''(t) := MUTATION{P'(t)}           |
+|   +-------------------------------------+
+|   | P(t+1) := SELECTION{P''(t) + P(t)}  |
+|   +-------------------------------------+
+|   | evaluate FITNESS of P''(t)          |
+|   +-------------------------------------+
+|   | t := t + 1                          |
++===+=====================================+

PrevHomeNext
Query Handling as a Complex Optimization ProblemUpGenetic Query Optimization (GEQO) in PostgreSQL
\ No newline at end of file diff --git a/doc/src/sgml/html/geqo-pg-intro.html b/doc/src/sgml/html/geqo-pg-intro.html new file mode 100644 index 000000000..5c7c8e660 --- /dev/null +++ b/doc/src/sgml/html/geqo-pg-intro.html @@ -0,0 +1,407 @@ + +Genetic Query Optimization (GEQO) in PostgreSQL
PostgreSQL 9.2.2 Documentation
PrevUpChapter 51. Genetic Query OptimizerNext

51.3. Genetic Query Optimization (GEQO) in PostgreSQL

The GEQO module approaches the query + optimization problem as though it were the well-known traveling salesman + problem (TSP). + Possible query plans are encoded as integer strings. Each string + represents the join order from one relation of the query to the next. + For example, the join tree +

   /\
+  /\ 2
+ /\ 3
+4  1

+ is encoded by the integer string '4-1-3-2', + which means, first join relation '4' and '1', then '3', and + then '2', where 1, 2, 3, 4 are relation IDs within the + PostgreSQL optimizer. +

Specific characteristics of the GEQO + implementation in PostgreSQL + are: + +

  • Usage of a steady state GA (replacement of the least fit + individuals in a population, not whole-generational replacement) + allows fast convergence towards improved query plans. This is + essential for query handling with reasonable time; +

  • Usage of edge recombination crossover + which is especially suited to keep edge losses low for the + solution of the TSP by means of a + GA; +

  • Mutation as genetic operator is deprecated so that no repair + mechanisms are needed to generate legal TSP tours. +

+

Parts of the GEQO module are adapted from D. Whitley's + Genitor algorithm. +

The GEQO module allows + the PostgreSQL query optimizer to + support large join queries effectively through + non-exhaustive search. +

51.3.1. Generating Possible Plans with GEQO

The GEQO planning process uses the standard planner + code to generate plans for scans of individual relations. Then join + plans are developed using the genetic approach. As shown above, each + candidate join plan is represented by a sequence in which to join + the base relations. In the initial stage, the GEQO + code simply generates some possible join sequences at random. For each + join sequence considered, the standard planner code is invoked to + estimate the cost of performing the query using that join sequence. + (For each step of the join sequence, all three possible join strategies + are considered; and all the initially-determined relation scan plans + are available. The estimated cost is the cheapest of these + possibilities.) Join sequences with lower estimated cost are considered + "more fit" than those with higher cost. The genetic algorithm + discards the least fit candidates. Then new candidates are generated + by combining genes of more-fit candidates — that is, by using + randomly-chosen portions of known low-cost join sequences to create + new sequences for consideration. This process is repeated until a + preset number of join sequences have been considered; then the best + one found at any time during the search is used to generate the finished + plan. +

This process is inherently nondeterministic, because of the randomized + choices made during both the initial population selection and subsequent + "mutation" of the best candidates. To avoid surprising changes + of the selected plan, each run of the GEQO algorithm restarts its + random number generator with the current geqo_seed + parameter setting. As long as geqo_seed and the other + GEQO parameters are kept fixed, the same plan will be generated for a + given query (and other planner inputs such as statistics). To experiment + with different search paths, try changing geqo_seed. +

51.3.2. Future Implementation Tasks for + PostgreSQL GEQO

Work is still needed to improve the genetic algorithm parameter + settings. + In file src/backend/optimizer/geqo/geqo_main.c, + routines + gimme_pool_size and gimme_number_generations, + we have to find a compromise for the parameter settings + to satisfy two competing demands: +

  • Optimality of the query plan +

  • Computing time +

+

In the current implementation, the fitness of each candidate join + sequence is estimated by running the standard planner's join selection + and cost estimation code from scratch. To the extent that different + candidates use similar sub-sequences of joins, a great deal of work + will be repeated. This could be made significantly faster by retaining + cost estimates for sub-joins. The problem is to avoid expending + unreasonable amounts of memory on retaining that state. +

At a more basic level, it is not clear that solving query optimization + with a GA algorithm designed for TSP is appropriate. In the TSP case, + the cost associated with any substring (partial tour) is independent + of the rest of the tour, but this is certainly not true for query + optimization. Thus it is questionable whether edge recombination + crossover is the most effective mutation procedure. +


PrevHomeNext
Genetic AlgorithmsUpFurther Reading
\ No newline at end of file diff --git a/doc/src/sgml/html/geqo.html b/doc/src/sgml/html/geqo.html new file mode 100644 index 000000000..921c7b2d6 --- /dev/null +++ b/doc/src/sgml/html/geqo.html @@ -0,0 +1,239 @@ + +Genetic Query Optimizer

Chapter 51. Genetic Query Optimizer

Author: Written by Martin Utesch (<utesch@aut.tu-freiberg.de>) + for the Institute of Automatic Control at the University of Mining and Technology in Freiberg, Germany. +

+


PrevHomeNext
Foreign Data Wrapper Query PlanningUpQuery Handling as a Complex Optimization Problem
\ No newline at end of file diff --git a/doc/src/sgml/html/gin-examples.html b/doc/src/sgml/html/gin-examples.html new file mode 100644 index 000000000..3b1cf2f53 --- /dev/null +++ b/doc/src/sgml/html/gin-examples.html @@ -0,0 +1,241 @@ + +Examples

55.6. Examples

The PostgreSQL source distribution includes + GIN operator classes for tsvector and + for one-dimensional arrays of all internal types. Prefix searching in + tsvector is implemented using the GIN partial match + feature. + The following contrib modules also contain + GIN operator classes: + +

btree_gin

B-tree equivalent functionality for several data types

hstore

Module for storing (key, value) pairs

intarray

Enhanced support for int[]

pg_trgm

Text similarity using trigram matching

+


PrevHomeNext
LimitationsUpDatabase Physical Storage
\ No newline at end of file diff --git a/doc/src/sgml/html/gin-extensibility.html b/doc/src/sgml/html/gin-extensibility.html new file mode 100644 index 000000000..4746274f3 --- /dev/null +++ b/doc/src/sgml/html/gin-extensibility.html @@ -0,0 +1,653 @@ + +Extensibility

55.2. Extensibility

The GIN interface has a high level of abstraction, + requiring the access method implementer only to implement the semantics of + the data type being accessed. The GIN layer itself + takes care of concurrency, logging and searching the tree structure. +

All it takes to get a GIN access method working is to + implement four (or five) user-defined methods, which define the behavior of + keys in the tree and the relationships between keys, indexed items, + and indexable queries. In short, GIN combines + extensibility with generality, code reuse, and a clean interface. +

The four methods that an operator class for + GIN must provide are: + +

int compare(Datum a, Datum b)

Compares two keys (not indexed items!) and returns an integer less than + zero, zero, or greater than zero, indicating whether the first key is + less than, equal to, or greater than the second. Null keys are never + passed to this function. +

Datum *extractValue(Datum itemValue, int32 *nkeys, + bool **nullFlags)

Returns a palloc'd array of keys given an item to be indexed. The + number of returned keys must be stored into *nkeys. + If any of the keys can be null, also palloc an array of + *nkeys booleans, store its address at + *nullFlags, and set these null flags as needed. + *nullFlags can be left NULL (its initial value) + if all keys are non-null. + The return value can be NULL if the item contains no keys. +

Datum *extractQuery(Datum query, int32 *nkeys, + StrategyNumber n, bool **pmatch, Pointer **extra_data, + bool **nullFlags, int32 *searchMode)

Returns a palloc'd array of keys given a value to be queried; that is, + query is the value on the right-hand side of an + indexable operator whose left-hand side is the indexed column. + n is the strategy number of the operator within the + operator class (see Section 35.14.2). + Often, extractQuery will need + to consult n to determine the data type of + query and the method it should use to extract key values. + The number of returned keys must be stored into *nkeys. + If any of the keys can be null, also palloc an array of + *nkeys booleans, store its address at + *nullFlags, and set these null flags as needed. + *nullFlags can be left NULL (its initial value) + if all keys are non-null. + The return value can be NULL if the query contains no keys. +

searchMode is an output argument that allows + extractQuery to specify details about how the search + will be done. + If *searchMode is set to + GIN_SEARCH_MODE_DEFAULT (which is the value it is + initialized to before call), only items that match at least one of + the returned keys are considered candidate matches. + If *searchMode is set to + GIN_SEARCH_MODE_INCLUDE_EMPTY, then in addition to items + containing at least one matching key, items that contain no keys at + all are considered candidate matches. (This mode is useful for + implementing is-subset-of operators, for example.) + If *searchMode is set to GIN_SEARCH_MODE_ALL, + then all non-null items in the index are considered candidate + matches, whether they match any of the returned keys or not. (This + mode is much slower than the other two choices, since it requires + scanning essentially the entire index, but it may be necessary to + implement corner cases correctly. An operator that needs this mode + in most cases is probably not a good candidate for a GIN operator + class.) + The symbols to use for setting this mode are defined in + access/gin.h. +

pmatch is an output argument for use when partial match + is supported. To use it, extractQuery must allocate + an array of *nkeys booleans and store its address at + *pmatch. Each element of the array should be set to TRUE + if the corresponding key requires partial match, FALSE if not. + If *pmatch is set to NULL then GIN assumes partial match + is not required. The variable is initialized to NULL before call, + so this argument can simply be ignored by operator classes that do + not support partial match. +

extra_data is an output argument that allows + extractQuery to pass additional data to the + consistent and comparePartial methods. + To use it, extractQuery must allocate + an array of *nkeys Pointers and store its address at + *extra_data, then store whatever it wants to into the + individual pointers. The variable is initialized to NULL before + call, so this argument can simply be ignored by operator classes that + do not require extra data. If *extra_data is set, the + whole array is passed to the consistent method, and + the appropriate element to the comparePartial method. +

bool consistent(bool check[], StrategyNumber n, Datum query, + int32 nkeys, Pointer extra_data[], bool *recheck, + Datum queryKeys[], bool nullFlags[])

Returns TRUE if an indexed item satisfies the query operator with + strategy number n (or might satisfy it, if the recheck + indication is returned). This function does not have direct access + to the indexed item's value, since GIN does not + store items explicitly. Rather, what is available is knowledge + about which key values extracted from the query appear in a given + indexed item. The check array has length + nkeys, which is the same as the number of keys previously + returned by extractQuery for this query datum. + Each element of the + check array is TRUE if the indexed item contains the + corresponding query key, ie, if (check[i] == TRUE) the i-th key of the + extractQuery result array is present in the indexed item. + The original query datum is + passed in case the consistent method needs to consult it, + and so are the queryKeys[] and nullFlags[] + arrays previously returned by extractQuery. + extra_data is the extra-data array returned by + extractQuery, or NULL if none. +

When extractQuery returns a null key in + queryKeys[], the corresponding check[] element + is TRUE if the indexed item contains a null key; that is, the + semantics of check[] are like IS NOT DISTINCT + FROM. The consistent function can examine the + corresponding nullFlags[] element if it needs to tell + the difference between a regular value match and a null match. +

On success, *recheck should be set to TRUE if the heap + tuple needs to be rechecked against the query operator, or FALSE if + the index test is exact. That is, a FALSE return value guarantees + that the heap tuple does not match the query; a TRUE return value with + *recheck set to FALSE guarantees that the heap tuple does + match the query; and a TRUE return value with + *recheck set to TRUE means that the heap tuple might match + the query, so it needs to be fetched and rechecked by evaluating the + query operator directly against the originally indexed item. +

+ + Optionally, an operator class for + GIN can supply a fifth method: + +

int comparePartial(Datum partial_key, Datum key, StrategyNumber n, + Pointer extra_data)

Compare a partial-match query key to an index key. Returns an integer + whose sign indicates the result: less than zero means the index key + does not match the query, but the index scan should continue; zero + means that the index key does match the query; greater than zero + indicates that the index scan should stop because no more matches + are possible. The strategy number n of the operator + that generated the partial match query is provided, in case its + semantics are needed to determine when to end the scan. Also, + extra_data is the corresponding element of the extra-data + array made by extractQuery, or NULL if none. + Null keys are never passed to this function. +

+

To support "partial match" queries, an operator class must + provide the comparePartial method, and its + extractQuery method must set the pmatch + parameter when a partial-match query is encountered. See + Section 55.3.2 for details. +

The actual data types of the various Datum values mentioned + above vary depending on the operator class. The item values passed to + extractValue are always of the operator class's input type, and + all key values must be of the class's STORAGE type. The type of + the query argument passed to extractQuery and + consistent is whatever is specified as the right-hand input + type of the class member operator identified by the strategy number. + This need not be the same as the item type, so long as key values of the + correct type can be extracted from it. +


PrevHomeNext
IntroductionUpImplementation
\ No newline at end of file diff --git a/doc/src/sgml/html/gin-implementation.html b/doc/src/sgml/html/gin-implementation.html new file mode 100644 index 000000000..1f0dc5ac2 --- /dev/null +++ b/doc/src/sgml/html/gin-implementation.html @@ -0,0 +1,313 @@ + +Implementation

55.3. Implementation

Internally, a GIN index contains a B-tree index + constructed over keys, where each key is an element of one or more indexed + items (a member of an array, for example) and where each tuple in a leaf + page contains either a pointer to a B-tree of heap pointers (a + "posting tree"), or a simple list of heap pointers (a "posting + list") when the list is small enough to fit into a single index tuple along + with the key value. +

As of PostgreSQL 9.1, NULL key values can be + included in the index. Also, placeholder NULLs are included in the index + for indexed items that are NULL or contain no keys according to + extractValue. This allows searches that should find empty + items to do so. +

Multicolumn GIN indexes are implemented by building + a single B-tree over composite values (column number, key value). The + key values for different columns can be of different types. +

55.3.1. GIN Fast Update Technique

Updating a GIN index tends to be slow because of the + intrinsic nature of inverted indexes: inserting or updating one heap row + can cause many inserts into the index (one for each key extracted + from the indexed item). As of PostgreSQL 8.4, + GIN is capable of postponing much of this work by inserting + new tuples into a temporary, unsorted list of pending entries. + When the table is vacuumed, or if the pending list becomes too large + (larger than work_mem), the entries are moved to the + main GIN data structure using the same bulk insert + techniques used during initial index creation. This greatly improves + GIN index update speed, even counting the additional + vacuum overhead. Moreover the overhead work can be done by a background + process instead of in foreground query processing. +

The main disadvantage of this approach is that searches must scan the list + of pending entries in addition to searching the regular index, and so + a large list of pending entries will slow searches significantly. + Another disadvantage is that, while most updates are fast, an update + that causes the pending list to become "too large" will incur an + immediate cleanup cycle and thus be much slower than other updates. + Proper use of autovacuum can minimize both of these problems. +

If consistent response time is more important than update speed, + use of pending entries can be disabled by turning off the + FASTUPDATE storage parameter for a + GIN index. See CREATE INDEX + for details. +

55.3.2. Partial Match Algorithm

GIN can support "partial match" queries, in which the query + does not determine an exact match for one or more keys, but the possible + matches fall within a reasonably narrow range of key values (within the + key sorting order determined by the compare support method). + The extractQuery method, instead of returning a key value + to be matched exactly, returns a key value that is the lower bound of + the range to be searched, and sets the pmatch flag true. + The key range is then scanned using the comparePartial + method. comparePartial must return zero for a matching + index key, less than zero for a non-match that is still within the range + to be searched, or greater than zero if the index key is past the range + that could match. +


PrevHomeNext
ExtensibilityUpGIN Tips and Tricks
\ No newline at end of file diff --git a/doc/src/sgml/html/gin-intro.html b/doc/src/sgml/html/gin-intro.html new file mode 100644 index 000000000..98711e575 --- /dev/null +++ b/doc/src/sgml/html/gin-intro.html @@ -0,0 +1,256 @@ + +Introduction

55.1. Introduction

GIN stands for Generalized Inverted Index. + GIN is designed for handling cases where the items + to be indexed are composite values, and the queries to be handled by + the index need to search for element values that appear within + the composite items. For example, the items could be documents, + and the queries could be searches for documents containing specific words. +

We use the word item to refer to a composite value that + is to be indexed, and the word key to refer to an element + value. GIN always stores and searches for keys, + not item values per se. +

A GIN index stores a set of (key, posting list) pairs, + where a posting list is a set of row IDs in which the key + occurs. The same row ID can appear in multiple posting lists, since + an item can contain more than one key. Each key value is stored only + once, so a GIN index is very compact for cases + where the same key appears many times. +

GIN is generalized in the sense that the + GIN access method code does not need to know the + specific operations that it accelerates. + Instead, it uses custom strategies defined for particular data types. + The strategy defines how keys are extracted from indexed items and + query conditions, and how to determine whether a row that contains + some of the key values in a query actually satisfies the query. +

One advantage of GIN is that it allows the development + of custom data types with the appropriate access methods, by + an expert in the domain of the data type, rather than a database expert. + This is much the same advantage as using GiST. +

The GIN + implementation in PostgreSQL is primarily + maintained by Teodor Sigaev and Oleg Bartunov. There is more + information about GIN on their + website. +


PrevHomeNext
GIN IndexesUpExtensibility
\ No newline at end of file diff --git a/doc/src/sgml/html/gin-limit.html b/doc/src/sgml/html/gin-limit.html new file mode 100644 index 000000000..cd9a972df --- /dev/null +++ b/doc/src/sgml/html/gin-limit.html @@ -0,0 +1,181 @@ + +Limitations

55.5. Limitations

GIN assumes that indexable operators are strict. This + means that extractValue will not be called at all on a NULL + item value (instead, a placeholder index entry is created automatically), + and extractQuery will not be called on a NULL query + value either (instead, the query is presumed to be unsatisfiable). Note + however that NULL key values contained within a non-null composite item + or query value are supported. +


PrevHomeNext
GIN Tips and TricksUpExamples
\ No newline at end of file diff --git a/doc/src/sgml/html/gin-tips.html b/doc/src/sgml/html/gin-tips.html new file mode 100644 index 000000000..a4ad4fc02 --- /dev/null +++ b/doc/src/sgml/html/gin-tips.html @@ -0,0 +1,296 @@ + +GIN Tips and Tricks

55.4. GIN Tips and Tricks

Create vs. insert

Insertion into a GIN index can be slow + due to the likelihood of many keys being inserted for each item. + So, for bulk insertions into a table it is advisable to drop the GIN + index and recreate it after finishing bulk insertion. +

As of PostgreSQL 8.4, this advice is less + necessary since delayed indexing is used (see Section 55.3.1 for details). But for very large updates + it may still be best to drop and recreate the index. +

maintenance_work_mem

Build time for a GIN index is very sensitive to + the maintenance_work_mem setting; it doesn't pay to + skimp on work memory during index creation. +

work_mem

During a series of insertions into an existing GIN + index that has FASTUPDATE enabled, the system will clean up + the pending-entry list whenever the list grows larger than + work_mem. To avoid fluctuations in observed response time, + it's desirable to have pending-list cleanup occur in the background + (i.e., via autovacuum). Foreground cleanup operations can be avoided by + increasing work_mem or making autovacuum more aggressive. + However, enlarging work_mem means that if a foreground + cleanup does occur, it will take even longer. +

gin_fuzzy_search_limit

The primary goal of developing GIN indexes was + to create support for highly scalable full-text search in + PostgreSQL, and there are often situations when + a full-text search returns a very large set of results. Moreover, this + often happens when the query contains very frequent words, so that the + large result set is not even useful. Since reading many + tuples from the disk and sorting them could take a lot of time, this is + unacceptable for production. (Note that the index search itself is very + fast.) +

To facilitate controlled execution of such queries, + GIN has a configurable soft upper limit on the + number of rows returned: the + gin_fuzzy_search_limit configuration parameter. + It is set to 0 (meaning no limit) by default. + If a non-zero limit is set, then the returned set is a subset of + the whole result set, chosen at random. +

"Soft" means that the actual number of returned results + could differ somewhat from the specified limit, depending on the query + and the quality of the system's random number generator. +

From experience, values in the thousands (e.g., 5000 — 20000) + work well. +


PrevHomeNext
ImplementationUpLimitations
\ No newline at end of file diff --git a/doc/src/sgml/html/gin.html b/doc/src/sgml/html/gin.html new file mode 100644 index 000000000..61ddc079f --- /dev/null +++ b/doc/src/sgml/html/gin.html @@ -0,0 +1,215 @@ + +GIN Indexes

Chapter 55. GIN Indexes


PrevHomeNext
ExamplesUpIntroduction
\ No newline at end of file diff --git a/doc/src/sgml/html/gist-examples.html b/doc/src/sgml/html/gist-examples.html new file mode 100644 index 000000000..32840a1d4 --- /dev/null +++ b/doc/src/sgml/html/gist-examples.html @@ -0,0 +1,269 @@ + +Examples

53.4. Examples

The PostgreSQL source distribution includes + several examples of index methods implemented using + GiST. The core system currently provides text search + support (indexing for tsvector and tsquery) as well as + R-Tree equivalent functionality for some of the built-in geometric data types + (see src/backend/access/gist/gistproc.c). The following + contrib modules also contain GiST + operator classes: + +

btree_gist

B-tree equivalent functionality for several data types

cube

Indexing for multidimensional cubes

hstore

Module for storing (key, value) pairs

intarray

RD-Tree for one-dimensional array of int4 values

ltree

Indexing for tree-like structures

pg_trgm

Text similarity using trigram matching

seg

Indexing for "float ranges"

+


PrevHomeNext
ImplementationUpSP-GiST Indexes
\ No newline at end of file diff --git a/doc/src/sgml/html/gist-extensibility.html b/doc/src/sgml/html/gist-extensibility.html new file mode 100644 index 000000000..2767e67b2 --- /dev/null +++ b/doc/src/sgml/html/gist-extensibility.html @@ -0,0 +1,1058 @@ + +Extensibility

53.2. Extensibility

Traditionally, implementing a new index access method meant a lot of + difficult work. It was necessary to understand the inner workings of the + database, such as the lock manager and Write-Ahead Log. The + GiST interface has a high level of abstraction, + requiring the access method implementer only to implement the semantics of + the data type being accessed. The GiST layer itself + takes care of concurrency, logging and searching the tree structure. +

This extensibility should not be confused with the extensibility of the + other standard search trees in terms of the data they can handle. For + example, PostgreSQL supports extensible B-trees + and hash indexes. That means that you can use + PostgreSQL to build a B-tree or hash over any + data type you want. But B-trees only support range predicates + (<, =, >), + and hash indexes only support equality queries. +

So if you index, say, an image collection with a + PostgreSQL B-tree, you can only issue queries + such as "is imagex equal to imagey", "is imagex less + than imagey" and "is imagex greater than imagey". + Depending on how you define "equals", "less than" + and "greater than" in this context, this could be useful. + However, by using a GiST based index, you could create + ways to ask domain-specific questions, perhaps "find all images of + horses" or "find all over-exposed images". +

All it takes to get a GiST access method up and running + is to implement several user-defined methods, which define the behavior of + keys in the tree. Of course these methods have to be pretty fancy to + support fancy queries, but for all the standard queries (B-trees, + R-trees, etc.) they're relatively straightforward. In short, + GiST combines extensibility along with generality, code + reuse, and a clean interface. +

There are seven methods that an index operator class for + GiST must provide, and an eighth that is optional. + Correctness of the index is ensured + by proper implementation of the same, consistent + and union methods, while efficiency (size and speed) of the + index will depend on the penalty and picksplit + methods. + The remaining two basic methods are compress and + decompress, which allow an index to have internal tree data of + a different type than the data it indexes. The leaves are to be of the + indexed data type, while the other tree nodes can be of any C struct (but + you still have to follow PostgreSQL data type rules here, + see about varlena for variable sized data). If the tree's + internal data type exists at the SQL level, the STORAGE option + of the CREATE OPERATOR CLASS command can be used. + The optional eighth method is distance, which is needed + if the operator class wishes to support ordered scans (nearest-neighbor + searches). +

consistent

Given an index entry p and a query value q, + this function determines whether the index entry is + "consistent" with the query; that is, could the predicate + "indexed_column + indexable_operator q" be true for + any row represented by the index entry? For a leaf index entry this is + equivalent to testing the indexable condition, while for an internal + tree node this determines whether it is necessary to scan the subtree + of the index represented by the tree node. When the result is + true, a recheck flag must also be returned. + This indicates whether the predicate is certainly true or only possibly + true. If recheck = false then the index has + tested the predicate condition exactly, whereas if recheck + = true the row is only a candidate match. In that case the + system will automatically evaluate the + indexable_operator against the actual row value to see + if it is really a match. This convention allows + GiST to support both lossless and lossy index + structures. +

The SQL declaration of the function must look like this: + +

CREATE OR REPLACE FUNCTION my_consistent(internal, data_type, smallint, oid, internal)
+RETURNS bool
+AS 'MODULE_PATHNAME'
+LANGUAGE C STRICT;

+ + And the matching code in the C module could then follow this skeleton: + +

Datum       my_consistent(PG_FUNCTION_ARGS);
+PG_FUNCTION_INFO_V1(my_consistent);
+
+Datum
+my_consistent(PG_FUNCTION_ARGS)
+{
+    GISTENTRY  *entry = (GISTENTRY *) PG_GETARG_POINTER(0);
+    data_type  *query = PG_GETARG_DATA_TYPE_P(1);
+    StrategyNumber strategy = (StrategyNumber) PG_GETARG_UINT16(2);
+    /* Oid subtype = PG_GETARG_OID(3); */
+    bool       *recheck = (bool *) PG_GETARG_POINTER(4);
+    data_type  *key = DatumGetDataType(entry->key);
+    bool        retval;
+
+    /*
+     * determine return value as a function of strategy, key and query.
+     *
+     * Use GIST_LEAF(entry) to know where you're called in the index tree,
+     * which comes handy when supporting the = operator for example (you could
+     * check for non empty union() in non-leaf nodes and equality in leaf
+     * nodes).
+     */
+
+    *recheck = true;        /* or false if check is exact */
+
+    PG_RETURN_BOOL(retval);
+}

+ + Here, key is an element in the index and query + the value being looked up in the index. The StrategyNumber + parameter indicates which operator of your operator class is being + applied — it matches one of the operator numbers in the + CREATE OPERATOR CLASS command. Depending on what operators + you have included in the class, the data type of query could + vary with the operator, but the above skeleton assumes it doesn't. +

union

This method consolidates information in the tree. Given a set of + entries, this function generates a new index entry that represents + all the given entries. +

The SQL declaration of the function must look like this: + +

CREATE OR REPLACE FUNCTION my_union(internal, internal)
+RETURNS internal
+AS 'MODULE_PATHNAME'
+LANGUAGE C STRICT;

+ + And the matching code in the C module could then follow this skeleton: + +

Datum       my_union(PG_FUNCTION_ARGS);
+PG_FUNCTION_INFO_V1(my_union);
+
+Datum
+my_union(PG_FUNCTION_ARGS)
+{
+    GistEntryVector *entryvec = (GistEntryVector *) PG_GETARG_POINTER(0);
+    GISTENTRY  *ent = entryvec->vector;
+    data_type  *out,
+               *tmp,
+               *old;
+    int         numranges,
+                i = 0;
+
+    numranges = entryvec->n;
+    tmp = DatumGetDataType(ent[0].key);
+    out = tmp;
+
+    if (numranges == 1)
+    {
+        out = data_type_deep_copy(tmp);
+
+        PG_RETURN_DATA_TYPE_P(out);
+    }
+
+    for (i = 1; i < numranges; i++)
+    {
+        old = out;
+        tmp = DatumGetDataType(ent[i].key);
+        out = my_union_implementation(out, tmp);
+    }
+
+    PG_RETURN_DATA_TYPE_P(out);
+}

+

As you can see, in this skeleton we're dealing with a data type + where union(X, Y, Z) = union(union(X, Y), Z). It's easy + enough to support data types where this is not the case, by + implementing the proper union algorithm in this + GiST support method. +

The union implementation function should return a + pointer to newly palloc()ed memory. You can't just + return whatever the input is. +

compress

Converts the data item into a format suitable for physical storage in + an index page. +

The SQL declaration of the function must look like this: + +

CREATE OR REPLACE FUNCTION my_compress(internal)
+RETURNS internal
+AS 'MODULE_PATHNAME'
+LANGUAGE C STRICT;

+ + And the matching code in the C module could then follow this skeleton: + +

Datum       my_compress(PG_FUNCTION_ARGS);
+PG_FUNCTION_INFO_V1(my_compress);
+
+Datum
+my_compress(PG_FUNCTION_ARGS)
+{
+    GISTENTRY  *entry = (GISTENTRY *) PG_GETARG_POINTER(0);
+    GISTENTRY  *retval;
+
+    if (entry->leafkey)
+    {
+        /* replace entry->key with a compressed version */
+        compressed_data_type *compressed_data = palloc(sizeof(compressed_data_type));
+
+        /* fill *compressed_data from entry->key ... */
+
+        retval = palloc(sizeof(GISTENTRY));
+        gistentryinit(*retval, PointerGetDatum(compressed_data),
+                      entry->rel, entry->page, entry->offset, FALSE);
+    }
+    else
+    {
+        /* typically we needn't do anything with non-leaf entries */
+        retval = entry;
+    }
+
+    PG_RETURN_POINTER(retval);
+}

+

You have to adapt compressed_data_type to the specific + type you're converting to in order to compress your leaf nodes, of + course. +

Depending on your needs, you could also need to care about + compressing NULL values in there, storing for example + (Datum) 0 like gist_circle_compress does. +

decompress

The reverse of the compress method. Converts the + index representation of the data item into a format that can be + manipulated by the database. +

The SQL declaration of the function must look like this: + +

CREATE OR REPLACE FUNCTION my_decompress(internal)
+RETURNS internal
+AS 'MODULE_PATHNAME'
+LANGUAGE C STRICT;

+ + And the matching code in the C module could then follow this skeleton: + +

Datum       my_decompress(PG_FUNCTION_ARGS);
+PG_FUNCTION_INFO_V1(my_decompress);
+
+Datum
+my_decompress(PG_FUNCTION_ARGS)
+{
+    PG_RETURN_POINTER(PG_GETARG_POINTER(0));
+}

+ + The above skeleton is suitable for the case where no decompression + is needed. +

penalty

Returns a value indicating the "cost" of inserting the new + entry into a particular branch of the tree. Items will be inserted + down the path of least penalty in the tree. + Values returned by penalty should be non-negative. + If a negative value is returned, it will be treated as zero. +

The SQL declaration of the function must look like this: + +

CREATE OR REPLACE FUNCTION my_penalty(internal, internal, internal)
+RETURNS internal
+AS 'MODULE_PATHNAME'
+LANGUAGE C STRICT;  -- in some cases penalty functions need not be strict

+ + And the matching code in the C module could then follow this skeleton: + +

Datum       my_penalty(PG_FUNCTION_ARGS);
+PG_FUNCTION_INFO_V1(my_penalty);
+
+Datum
+my_penalty(PG_FUNCTION_ARGS)
+{
+    GISTENTRY  *origentry = (GISTENTRY *) PG_GETARG_POINTER(0);
+    GISTENTRY  *newentry = (GISTENTRY *) PG_GETARG_POINTER(1);
+    float      *penalty = (float *) PG_GETARG_POINTER(2);
+    data_type  *orig = DatumGetDataType(origentry->key);
+    data_type  *new = DatumGetDataType(newentry->key);
+
+    *penalty = my_penalty_implementation(orig, new);
+    PG_RETURN_POINTER(penalty);
+}

+

The penalty function is crucial to good performance of + the index. It'll get used at insertion time to determine which branch + to follow when choosing where to add the new entry in the tree. At + query time, the more balanced the index, the quicker the lookup. +

picksplit

When an index page split is necessary, this function decides which + entries on the page are to stay on the old page, and which are to move + to the new page. +

The SQL declaration of the function must look like this: + +

CREATE OR REPLACE FUNCTION my_picksplit(internal, internal)
+RETURNS internal
+AS 'MODULE_PATHNAME'
+LANGUAGE C STRICT;

+ + And the matching code in the C module could then follow this skeleton: + +

Datum       my_picksplit(PG_FUNCTION_ARGS);
+PG_FUNCTION_INFO_V1(my_picksplit);
+
+Datum
+my_picksplit(PG_FUNCTION_ARGS)
+{
+    GistEntryVector *entryvec = (GistEntryVector *) PG_GETARG_POINTER(0);
+    OffsetNumber maxoff = entryvec->n - 1;
+    GISTENTRY  *ent = entryvec->vector;
+    GIST_SPLITVEC *v = (GIST_SPLITVEC *) PG_GETARG_POINTER(1);
+    int         i,
+                nbytes;
+    OffsetNumber *left,
+               *right;
+    data_type  *tmp_union;
+    data_type  *unionL;
+    data_type  *unionR;
+    GISTENTRY **raw_entryvec;
+
+    maxoff = entryvec->n - 1;
+    nbytes = (maxoff + 1) * sizeof(OffsetNumber);
+
+    v->spl_left = (OffsetNumber *) palloc(nbytes);
+    left = v->spl_left;
+    v->spl_nleft = 0;
+
+    v->spl_right = (OffsetNumber *) palloc(nbytes);
+    right = v->spl_right;
+    v->spl_nright = 0;
+
+    unionL = NULL;
+    unionR = NULL;
+
+    /* Initialize the raw entry vector. */
+    raw_entryvec = (GISTENTRY **) malloc(entryvec->n * sizeof(void *));
+    for (i = FirstOffsetNumber; i <= maxoff; i = OffsetNumberNext(i))
+        raw_entryvec[i] = &(entryvec->vector[i]);
+
+    for (i = FirstOffsetNumber; i <= maxoff; i = OffsetNumberNext(i))
+    {
+        int         real_index = raw_entryvec[i] - entryvec->vector;
+
+        tmp_union = DatumGetDataType(entryvec->vector[real_index].key);
+        Assert(tmp_union != NULL);
+
+        /*
+         * Choose where to put the index entries and update unionL and unionR
+         * accordingly. Append the entries to either v_spl_left or
+         * v_spl_right, and care about the counters.
+         */
+
+        if (my_choice_is_left(unionL, curl, unionR, curr))
+        {
+            if (unionL == NULL)
+                unionL = tmp_union;
+            else
+                unionL = my_union_implementation(unionL, tmp_union);
+
+            *left = real_index;
+            ++left;
+            ++(v->spl_nleft);
+        }
+        else
+        {
+            /*
+             * Same on the right
+             */
+        }
+    }
+
+    v->spl_ldatum = DataTypeGetDatum(unionL);
+    v->spl_rdatum = DataTypeGetDatum(unionR);
+    PG_RETURN_POINTER(v);
+}

+

Like penalty, the picksplit function + is crucial to good performance of the index. Designing suitable + penalty and picksplit implementations + is where the challenge of implementing well-performing + GiST indexes lies. +

same

Returns true if two index entries are identical, false otherwise. +

The SQL declaration of the function must look like this: + +

CREATE OR REPLACE FUNCTION my_same(internal, internal, internal)
+RETURNS internal
+AS 'MODULE_PATHNAME'
+LANGUAGE C STRICT;

+ + And the matching code in the C module could then follow this skeleton: + +

Datum       my_same(PG_FUNCTION_ARGS);
+PG_FUNCTION_INFO_V1(my_same);
+
+Datum
+my_same(PG_FUNCTION_ARGS)
+{
+    prefix_range *v1 = PG_GETARG_PREFIX_RANGE_P(0);
+    prefix_range *v2 = PG_GETARG_PREFIX_RANGE_P(1);
+    bool       *result = (bool *) PG_GETARG_POINTER(2);
+
+    *result = my_eq(v1, v2);
+    PG_RETURN_POINTER(result);
+}

+ + For historical reasons, the same function doesn't + just return a Boolean result; instead it has to store the flag + at the location indicated by the third argument. +

distance

Given an index entry p and a query value q, + this function determines the index entry's + "distance" from the query value. This function must be + supplied if the operator class contains any ordering operators. + A query using the ordering operator will be implemented by returning + index entries with the smallest "distance" values first, + so the results must be consistent with the operator's semantics. + For a leaf index entry the result just represents the distance to + the index entry; for an internal tree node, the result must be the + smallest distance that any child entry could have. +

The SQL declaration of the function must look like this: + +

CREATE OR REPLACE FUNCTION my_distance(internal, data_type, smallint, oid)
+RETURNS float8
+AS 'MODULE_PATHNAME'
+LANGUAGE C STRICT;

+ + And the matching code in the C module could then follow this skeleton: + +

Datum       my_distance(PG_FUNCTION_ARGS);
+PG_FUNCTION_INFO_V1(my_distance);
+
+Datum
+my_distance(PG_FUNCTION_ARGS)
+{
+    GISTENTRY  *entry = (GISTENTRY *) PG_GETARG_POINTER(0);
+    data_type  *query = PG_GETARG_DATA_TYPE_P(1);
+    StrategyNumber strategy = (StrategyNumber) PG_GETARG_UINT16(2);
+    /* Oid subtype = PG_GETARG_OID(3); */
+    data_type  *key = DatumGetDataType(entry->key);
+    double      retval;
+
+    /*
+     * determine return value as a function of strategy, key and query.
+     */
+
+    PG_RETURN_FLOAT8(retval);
+}

+ + The arguments to the distance function are identical to + the arguments of the consistent function, except that no + recheck flag is used. The distance to a leaf index entry must always + be determined exactly, since there is no way to re-order the tuples + once they are returned. Some approximation is allowed when determining + the distance to an internal tree node, so long as the result is never + greater than any child's actual distance. Thus, for example, distance + to a bounding box is usually sufficient in geometric applications. The + result value can be any finite float8 value. (Infinity and + minus infinity are used internally to handle cases such as nulls, so it + is not recommended that distance functions return these + values.) +

All the GiST support methods are normally called in short-lived memory + contexts; that is, CurrentMemoryContext will get reset after + each tuple is processed. It is therefore not very important to worry about + pfree'ing everything you palloc. However, in some cases it's useful for a + support method to cache data across repeated calls. To do that, allocate + the longer-lived data in fcinfo->flinfo->fn_mcxt, and + keep a pointer to it in fcinfo->flinfo->fn_extra. Such + data will survive for the life of the index operation (e.g., a single GiST + index scan, index build, or index tuple insertion). Be careful to pfree + the previous value when replacing a fn_extra value, or the leak + will accumulate for the duration of the operation. +


PrevHomeNext
IntroductionUpImplementation
\ No newline at end of file diff --git a/doc/src/sgml/html/gist-implementation.html b/doc/src/sgml/html/gist-implementation.html new file mode 100644 index 000000000..8f89b8840 --- /dev/null +++ b/doc/src/sgml/html/gist-implementation.html @@ -0,0 +1,209 @@ + +Implementation

53.3. Implementation

53.3.1. GiST buffering build

Building large GiST indexes by simply inserting all the tuples tends to be + slow, because if the index tuples are scattered across the index and the + index is large enough to not fit in cache, the insertions need to perform + a lot of random I/O. Beginning in version 9.2, PostgreSQL supports a more + efficient method to build GiST indexes based on buffering, which can + dramatically reduce the number of random I/Os needed for non-ordered data + sets. For well-ordered data sets the benefit is smaller or non-existent, + because only a small number of pages receive new tuples at a time, and + those pages fit in cache even if the index as whole does not. +

However, buffering index build needs to call the penalty + function more often, which consumes some extra CPU resources. Also, the + buffers used in the buffering build need temporary disk space, up to + the size of the resulting index. Buffering can also influence the quality + of the resulting index, in both positive and negative directions. That + influence depends on various factors, like the distribution of the input + data and the operator class implementation. +

By default, a GiST index build switches to the buffering method when the + index size reaches effective_cache_size. It can + be manually turned on or off by the BUFFERING parameter + to the CREATE INDEX command. The default behavior is good for most cases, + but turning buffering off might speed up the build somewhat if the input + data is ordered. +


PrevHomeNext
ExtensibilityUpExamples
\ No newline at end of file diff --git a/doc/src/sgml/html/gist-intro.html b/doc/src/sgml/html/gist-intro.html new file mode 100644 index 000000000..e3008464e --- /dev/null +++ b/doc/src/sgml/html/gist-intro.html @@ -0,0 +1,213 @@ + +Introduction

53.1. Introduction

GiST stands for Generalized Search Tree. It is a + balanced, tree-structured access method, that acts as a base template in + which to implement arbitrary indexing schemes. B-trees, R-trees and many + other indexing schemes can be implemented in GiST. +

One advantage of GiST is that it allows the development + of custom data types with the appropriate access methods, by + an expert in the domain of the data type, rather than a database expert. +

Some of the information here is derived from the University of California + at Berkeley's GiST Indexing Project + web site and + Marcel Kornacker's thesis, + Access Methods for Next-Generation Database Systems. + The GiST + implementation in PostgreSQL is primarily + maintained by Teodor Sigaev and Oleg Bartunov, and there is more + information on their + web site. +


PrevHomeNext
GiST IndexesUpExtensibility
\ No newline at end of file diff --git a/doc/src/sgml/html/gist.html b/doc/src/sgml/html/gist.html new file mode 100644 index 000000000..4e8ae7fbb --- /dev/null +++ b/doc/src/sgml/html/gist.html @@ -0,0 +1,191 @@ + +GiST Indexes

Chapter 53. GiST Indexes

Table of Contents
53.1. Introduction
53.2. Extensibility
53.3. Implementation
53.4. Examples

PrevHomeNext
Index Cost Estimation FunctionsUpIntroduction
\ No newline at end of file diff --git a/doc/src/sgml/html/git.html b/doc/src/sgml/html/git.html new file mode 100644 index 000000000..94bd59628 --- /dev/null +++ b/doc/src/sgml/html/git.html @@ -0,0 +1,269 @@ + +Getting The Source via Git
PostgreSQL 9.2.2 Documentation
PrevUpAppendix I. The Source Code RepositoryNext

I.1. Getting The Source via Git

With Git you will make a copy of the entire code repository + on your local machine, so you will have access to all history and branches + offline. This is the fastest and most flexible way to develop or test + patches. +

Git

  1. You will need an installed version of Git, which you can + get from http://git-scm.com. Many systems already + have a recent version of Git installed by default, or + available in their package distribution system. +

  2. To begin using the Git repository, make a clone of the official mirror: + +

    git clone git://git.postgresql.org/git/postgresql.git

    + + This will copy the full repository to your local machine, so it may take + a while to complete, especially if you have a slow Internet connection. + The files will be placed in a new subdirectory postgresql of + your current directory. +

    The Git mirror can also be reached via the HTTP protocol, if for example + a firewall is blocking access to the Git protocol. Just change the URL + prefix to http, as in: + +

    git clone http://git.postgresql.org/git/postgresql.git

    + + The HTTP protocol is less efficient than the Git protocol, so it will be + slower to use. +

  3. Whenever you want to get the latest updates in the system, cd + into the repository, and run: + +

    git fetch

    +

Git can do a lot more things than just fetch the source. For + more information, consult the Git man pages, or see the + website at http://git-scm.com. +


PrevHomeNext
The Source Code RepositoryUpDocumentation
\ No newline at end of file diff --git a/doc/src/sgml/html/high-availability.html b/doc/src/sgml/html/high-availability.html new file mode 100644 index 000000000..0966f70fe --- /dev/null +++ b/doc/src/sgml/html/high-availability.html @@ -0,0 +1,363 @@ + +High Availability, Load Balancing, and Replication

Chapter 25. High Availability, Load Balancing, and Replication

Database servers can work together to allow a second server to + take over quickly if the primary server fails (high + availability), or to allow several computers to serve the same + data (load balancing). Ideally, database servers could work + together seamlessly. Web servers serving static web pages can + be combined quite easily by merely load-balancing web requests + to multiple machines. In fact, read-only database servers can + be combined relatively easily too. Unfortunately, most database + servers have a read/write mix of requests, and read/write servers + are much harder to combine. This is because though read-only + data needs to be placed on each server only once, a write to any + server has to be propagated to all servers so that future read + requests to those servers return consistent results. +

This synchronization problem is the fundamental difficulty for + servers working together. Because there is no single solution + that eliminates the impact of the sync problem for all use cases, + there are multiple solutions. Each solution addresses this + problem in a different way, and minimizes its impact for a specific + workload. +

Some solutions deal with synchronization by allowing only one + server to modify the data. Servers that can modify data are + called read/write, master or primary servers. + Servers that track changes in the master are called standby + or slave servers. A standby server that cannot be connected + to until it is promoted to a master server is called a warm + standby server, and one that can accept connections and serves read-only + queries is called a hot standby server. +

Some solutions are synchronous, + meaning that a data-modifying transaction is not considered + committed until all servers have committed the transaction. This + guarantees that a failover will not lose any data and that all + load-balanced servers will return consistent results no matter + which server is queried. In contrast, asynchronous solutions allow some + delay between the time of a commit and its propagation to the other servers, + opening the possibility that some transactions might be lost in + the switch to a backup server, and that load balanced servers + might return slightly stale results. Asynchronous communication + is used when synchronous would be too slow. +

Solutions can also be categorized by their granularity. Some solutions + can deal only with an entire database server, while others allow control + at the per-table or per-database level. +

Performance must be considered in any choice. There is usually a + trade-off between functionality and + performance. For example, a fully synchronous solution over a slow + network might cut performance by more than half, while an asynchronous + one might have a minimal performance impact. +

The remainder of this section outlines various failover, replication, + and load balancing solutions. A glossary is + also available. +


PrevHomeNext
Continuous Archiving and Point-in-Time Recovery (PITR)UpComparison of Different Solutions
\ No newline at end of file diff --git a/doc/src/sgml/html/history.html b/doc/src/sgml/html/history.html new file mode 100644 index 000000000..edede4c19 --- /dev/null +++ b/doc/src/sgml/html/history.html @@ -0,0 +1,633 @@ + +A Brief History of PostgreSQL

A Brief History of PostgreSQL

The object-relational database management system now known as + PostgreSQL is derived from the + POSTGRES package written at the + University of California at Berkeley. With over two decades of + development behind it, PostgreSQL is now + the most advanced open-source database available anywhere. +

The Berkeley POSTGRES Project

The POSTGRES project, led by Professor + Michael Stonebraker, was sponsored by the Defense Advanced Research + Projects Agency (DARPA), the Army Research + Office (ARO), the National Science Foundation + (NSF), and ESL, Inc. The implementation of + POSTGRES began in 1986. The initial + concepts for the system were presented in The design of POSTGRES + , + and the definition of the initial data model appeared in The POSTGRES data model + . The design of the rule system at that time was + described in The design of the POSTGRES rules system. The rationale and + architecture of the storage manager were detailed in The design of the POSTGRES storage system + . +

POSTGRES has undergone several major + releases since then. The first "demoware" system + became operational in 1987 and was shown at the 1988 + ACM-SIGMOD Conference. Version 1, described in + The implementation of POSTGRES + , was released to a few external users in + June 1989. In response to a critique of the first rule system + ( A commentary on the POSTGRES rules system + ), the rule system was redesigned ( On Rules, Procedures, Caching and Views in Database Systems + ), and Version 2 was released in June 1990 with + the new rule system. Version 3 appeared in 1991 and added support + for multiple storage managers, an improved query executor, and a + rewritten rule system. For the most part, subsequent releases + until Postgres95 (see below) focused on + portability and reliability. +

POSTGRES has been used to implement many + different research and production applications. These include: a + financial data analysis system, a jet engine performance monitoring + package, an asteroid tracking database, a medical information + database, and several geographic information systems. + POSTGRES has also been used as an + educational tool at several universities. Finally, Illustra + Information Technologies (later merged into + Informix, + which is now owned by IBM) picked up the code and + commercialized it. In late 1992, + POSTGRES became the primary data manager + for the + Sequoia 2000 scientific computing project. +

The size of the external user community nearly doubled during 1993. + It became increasingly obvious that maintenance of the prototype + code and support was taking up large amounts of time that should + have been devoted to database research. In an effort to reduce + this support burden, the Berkeley + POSTGRES project officially ended with + Version 4.2. +

Postgres95

In 1994, Andrew Yu and Jolly Chen added an SQL language interpreter + to POSTGRES. Under a new name, + Postgres95 was subsequently released to + the web to find its own way in the world as an open-source + descendant of the original POSTGRES + Berkeley code. +

Postgres95 code was completely ANSI C + and trimmed in size by 25%. Many internal changes improved + performance and + maintainability. Postgres95 release + 1.0.x ran about 30-50% faster on the Wisconsin Benchmark compared + to POSTGRES, Version 4.2. Apart from + bug fixes, the following were the major enhancements: + +

  • The query language PostQUEL was replaced with + SQL (implemented in the server). Subqueries + were not supported until PostgreSQL + (see below), but they could be imitated in + Postgres95 with user-defined + SQL functions. Aggregate functions were + re-implemented. Support for the GROUP BY + query clause was also added. +

  • A new program + (psql) was provided for interactive + SQL queries, which used GNU + Readline. This largely superseded + the old monitor program. +

  • A new front-end library, libpgtcl, + supported Tcl-based clients. A sample shell, + pgtclsh, provided new Tcl commands to + interface Tcl programs with the + Postgres95 server. +

  • The large-object interface was overhauled. The inversion large + objects were the only mechanism for storing large objects. (The + inversion file system was removed.) +

  • The instance-level rule system was removed. Rules were still + available as rewrite rules. +

  • A short tutorial introducing regular SQL + features as well as those of + Postgres95 was distributed with the + source code +

  • GNU make (instead of BSD + make) was used for the build. Also, + Postgres95 could be compiled with an + unpatched GCC (data alignment of + doubles was fixed). +

+

PostgreSQL

By 1996, it became clear that the name "Postgres95" + would not stand the test of time. We chose a new name, + PostgreSQL, to reflect the relationship + between the original POSTGRES and the + more recent versions with SQL capability. At + the same time, we set the version numbering to start at 6.0, + putting the numbers back into the sequence originally begun by the + Berkeley POSTGRES project. +

Many people continue to refer to + PostgreSQL as "Postgres" + (now rarely in all capital letters) because of tradition or because + it is easier to pronounce. This usage is widely accepted as a + nickname or alias. +

The emphasis during development of + Postgres95 was on identifying and + understanding existing problems in the server code. With + PostgreSQL, the emphasis has shifted to + augmenting features and capabilities, although work continues in + all areas. +

Details about what has happened in PostgreSQL since + then can be found in Appendix E. +


PrevHomeNext
What is PostgreSQL?UpConventions
\ No newline at end of file diff --git a/doc/src/sgml/html/hot-standby.html b/doc/src/sgml/html/hot-standby.html new file mode 100644 index 000000000..7137d1216 --- /dev/null +++ b/doc/src/sgml/html/hot-standby.html @@ -0,0 +1,1424 @@ + +Hot Standby
PostgreSQL 9.2.2 Documentation
PrevUpChapter 25. High Availability, Load Balancing, and ReplicationNext

25.5. Hot Standby

Hot Standby is the term used to describe the ability to connect to + the server and run read-only queries while the server is in archive + recovery or standby mode. This + is useful both for replication purposes and for restoring a backup + to a desired state with great precision. + The term Hot Standby also refers to the ability of the server to move + from recovery through to normal operation while users continue running + queries and/or keep their connections open. +

Running queries in hot standby mode is similar to normal query operation, + though there are several usage and administrative differences + explained below. +

25.5.1. User's Overview

When the hot_standby parameter is set to true on a + standby server, it will begin accepting connections once the recovery has + brought the system to a consistent state. All such connections are + strictly read-only; not even temporary tables may be written. +

The data on the standby takes some time to arrive from the primary server + so there will be a measurable delay between primary and standby. Running the + same query nearly simultaneously on both primary and standby might therefore + return differing results. We say that data on the standby is + eventually consistent with the primary. Once the + commit record for a transaction is replayed on the standby, the changes + made by that transaction will be visible to any new snapshots taken on + the standby. Snapshots may be taken at the start of each query or at the + start of each transaction, depending on the current transaction isolation + level. For more details, see Section 13.2. +

Transactions started during hot standby may issue the following commands: + +

  • Query access - SELECT, COPY TO +

  • Cursor commands - DECLARE, FETCH, CLOSE +

  • Parameters - SHOW, SET, RESET +

  • Transaction management commands +

    • BEGIN, END, ABORT, START TRANSACTION +

    • SAVEPOINT, RELEASE, ROLLBACK TO SAVEPOINT +

    • EXCEPTION blocks and other internal subtransactions +

    +

  • LOCK TABLE, though only when explicitly in one of these modes: + ACCESS SHARE, ROW SHARE or ROW EXCLUSIVE. +

  • Plans and resources - PREPARE, EXECUTE, + DEALLOCATE, DISCARD +

  • Plugins and extensions - LOAD +

+

Transactions started during hot standby will never be assigned a + transaction ID and cannot write to the system write-ahead log. + Therefore, the following actions will produce error messages: + +

  • Data Manipulation Language (DML) - INSERT, + UPDATE, DELETE, COPY FROM, + TRUNCATE. + Note that there are no allowed actions that result in a trigger + being executed during recovery. This restriction applies even to + temporary tables, because table rows cannot be read or written without + assigning a transaction ID, which is currently not possible in a + Hot Standby environment. +

  • Data Definition Language (DDL) - CREATE, + DROP, ALTER, COMMENT. + This restriction applies even to temporary tables, because carrying + out these operations would require updating the system catalog tables. +

  • SELECT ... FOR SHARE | UPDATE, because row locks cannot be + taken without updating the underlying data files. +

  • Rules on SELECT statements that generate DML commands. +

  • LOCK that explicitly requests a mode higher than ROW EXCLUSIVE MODE. +

  • LOCK in short default form, since it requests ACCESS EXCLUSIVE MODE. +

  • Transaction management commands that explicitly set non-read-only state: +

    • BEGIN READ WRITE, + START TRANSACTION READ WRITE +

    • SET TRANSACTION READ WRITE, + SET SESSION CHARACTERISTICS AS TRANSACTION READ WRITE +

    • SET transaction_read_only = off +

    +

  • Two-phase commit commands - PREPARE TRANSACTION, + COMMIT PREPARED, ROLLBACK PREPARED + because even read-only transactions need to write WAL in the + prepare phase (the first phase of two phase commit). +

  • Sequence updates - nextval(), setval() +

  • LISTEN, UNLISTEN, NOTIFY +

+

In normal operation, "read-only" transactions are allowed to + update sequences and to use LISTEN, UNLISTEN, and + NOTIFY, so Hot Standby sessions operate under slightly tighter + restrictions than ordinary read-only sessions. It is possible that some + of these restrictions might be loosened in a future release. +

During hot standby, the parameter transaction_read_only is always + true and may not be changed. But as long as no attempt is made to modify + the database, connections during hot standby will act much like any other + database connection. If failover or switchover occurs, the database will + switch to normal processing mode. Sessions will remain connected while the + server changes mode. Once hot standby finishes, it will be possible to + initiate read-write transactions (even from a session begun during + hot standby). +

Users will be able to tell whether their session is read-only by + issuing SHOW transaction_read_only. In addition, a set of + functions (Table 9-60) allow users to + access information about the standby server. These allow you to write + programs that are aware of the current state of the database. These + can be used to monitor the progress of recovery, or to allow you to + write complex programs that restore the database to particular states. +

25.5.2. Handling Query Conflicts

The primary and standby servers are in many ways loosely connected. Actions + on the primary will have an effect on the standby. As a result, there is + potential for negative interactions or conflicts between them. The easiest + conflict to understand is performance: if a huge data load is taking place + on the primary then this will generate a similar stream of WAL records on the + standby, so standby queries may contend for system resources, such as I/O. +

There are also additional types of conflict that can occur with Hot Standby. + These conflicts are hard conflicts in the sense that queries + might need to be canceled and, in some cases, sessions disconnected to resolve them. + The user is provided with several ways to handle these + conflicts. Conflict cases include: + +

  • Access Exclusive locks taken on the primary server, including both + explicit LOCK commands and various DDL + actions, conflict with table accesses in standby queries. +

  • Dropping a tablespace on the primary conflicts with standby queries + using that tablespace for temporary work files. +

  • Dropping a database on the primary conflicts with sessions connected + to that database on the standby. +

  • Application of a vacuum cleanup record from WAL conflicts with + standby transactions whose snapshots can still "see" any of + the rows to be removed. +

  • Application of a vacuum cleanup record from WAL conflicts with + queries accessing the target page on the standby, whether or not + the data to be removed is visible. +

+

On the primary server, these cases simply result in waiting; and the + user might choose to cancel either of the conflicting actions. However, + on the standby there is no choice: the WAL-logged action already occurred + on the primary so the standby must not fail to apply it. Furthermore, + allowing WAL application to wait indefinitely may be very undesirable, + because the standby's state will become increasingly far behind the + primary's. Therefore, a mechanism is provided to forcibly cancel standby + queries that conflict with to-be-applied WAL records. +

An example of the problem situation is an administrator on the primary + server running DROP TABLE on a table that is currently being + queried on the standby server. Clearly the standby query cannot continue + if the DROP TABLE is applied on the standby. If this situation + occurred on the primary, the DROP TABLE would wait until the + other query had finished. But when DROP TABLE is run on the + primary, the primary doesn't have information about what queries are + running on the standby, so it will not wait for any such standby + queries. The WAL change records come through to the standby while the + standby query is still running, causing a conflict. The standby server + must either delay application of the WAL records (and everything after + them, too) or else cancel the conflicting query so that the DROP + TABLE can be applied. +

When a conflicting query is short, it's typically desirable to allow it to + complete by delaying WAL application for a little bit; but a long delay in + WAL application is usually not desirable. So the cancel mechanism has + parameters, max_standby_archive_delay and max_standby_streaming_delay, that define the maximum + allowed delay in WAL application. Conflicting queries will be canceled + once it has taken longer than the relevant delay setting to apply any + newly-received WAL data. There are two parameters so that different delay + values can be specified for the case of reading WAL data from an archive + (i.e., initial recovery from a base backup or "catching up" a + standby server that has fallen far behind) versus reading WAL data via + streaming replication. +

In a standby server that exists primarily for high availability, it's + best to set the delay parameters relatively short, so that the server + cannot fall far behind the primary due to delays caused by standby + queries. However, if the standby server is meant for executing + long-running queries, then a high or even infinite delay value may be + preferable. Keep in mind however that a long-running query could + cause other sessions on the standby server to not see recent changes + on the primary, if it delays application of WAL records. +

Once the delay specified by max_standby_archive_delay or + max_standby_streaming_delay has been exceeded, conflicting + queries will be canceled. This usually results just in a cancellation + error, although in the case of replaying a DROP DATABASE + the entire conflicting session will be terminated. Also, if the conflict + is over a lock held by an idle transaction, the conflicting session is + terminated (this behavior might change in the future). +

Canceled queries may be retried immediately (after beginning a new + transaction, of course). Since query cancellation depends on + the nature of the WAL records being replayed, a query that was + canceled may well succeed if it is executed again. +

Keep in mind that the delay parameters are compared to the elapsed time + since the WAL data was received by the standby server. Thus, the grace + period allowed to any one query on the standby is never more than the + delay parameter, and could be considerably less if the standby has already + fallen behind as a result of waiting for previous queries to complete, or + as a result of being unable to keep up with a heavy update load. +

The most common reason for conflict between standby queries and WAL replay + is "early cleanup". Normally, PostgreSQL allows + cleanup of old row versions when there are no transactions that need to + see them to ensure correct visibility of data according to MVCC rules. + However, this rule can only be applied for transactions executing on the + master. So it is possible that cleanup on the master will remove row + versions that are still visible to a transaction on the standby. +

Experienced users should note that both row version cleanup and row version + freezing will potentially conflict with standby queries. Running a manual + VACUUM FREEZE is likely to cause conflicts even on tables with + no updated or deleted rows. +

Users should be clear that tables that are regularly and heavily updated + on the primary server will quickly cause cancellation of longer running + queries on the standby. In such cases the setting of a finite value for + max_standby_archive_delay or + max_standby_streaming_delay can be considered similar to + setting statement_timeout. +

Remedial possibilities exist if the number of standby-query cancellations + is found to be unacceptable. The first option is to set the parameter + hot_standby_feedback, which prevents VACUUM from + removing recently-dead rows and so cleanup conflicts do not occur. + If you do this, you + should note that this will delay cleanup of dead rows on the primary, + which may result in undesirable table bloat. However, the cleanup + situation will be no worse than if the standby queries were running + directly on the primary server, and you are still getting the benefit of + off-loading execution onto the standby. + max_standby_archive_delay must be kept large in this case, + because delayed WAL files might already contain entries that conflict with + the desired standby queries. +

Another option is to increase vacuum_defer_cleanup_age + on the primary server, so that dead rows will not be cleaned up as quickly + as they normally would be. This will allow more time for queries to + execute before they are canceled on the standby, without having to set + a high max_standby_streaming_delay. However it is + difficult to guarantee any specific execution-time window with this + approach, since vacuum_defer_cleanup_age is measured in + transactions executed on the primary server. +

The number of query cancels and the reason for them can be viewed using + the pg_stat_database_conflicts system view on the standby + server. The pg_stat_database system view also contains + summary information. +

25.5.3. Administrator's Overview

If hot_standby is turned on in + postgresql.conf and there is a recovery.conf + file present, the server will run in Hot Standby mode. + However, it may take some time for Hot Standby connections to be allowed, + because the server will not accept connections until it has completed + sufficient recovery to provide a consistent state against which queries + can run. During this period, + clients that attempt to connect will be refused with an error message. + To confirm the server has come up, either loop trying to connect from + the application, or look for these messages in the server logs: + +

LOG:  entering standby mode
+
+... then some time later ...
+
+LOG:  consistent recovery state reached
+LOG:  database system is ready to accept read only connections

+ + Consistency information is recorded once per checkpoint on the primary. + It is not possible to enable hot standby when reading WAL + written during a period when wal_level was not set to + hot_standby on the primary. Reaching a consistent state can + also be delayed in the presence of both of these conditions: + +

  • A write transaction has more than 64 subtransactions +

  • Very long-lived write transactions +

+ + If you are running file-based log shipping ("warm standby"), you might need + to wait until the next WAL file arrives, which could be as long as the + archive_timeout setting on the primary. +

The setting of some parameters on the standby will need reconfiguration + if they have been changed on the primary. For these parameters, + the value on the standby must + be equal to or greater than the value on the primary. If these parameters + are not set high enough then the standby will refuse to start. + Higher values can then be supplied and the server + restarted to begin recovery again. These parameters are: + +

  • max_connections +

  • max_prepared_transactions +

  • max_locks_per_transaction +

+

It is important that the administrator select appropriate settings for + max_standby_archive_delay and max_standby_streaming_delay. The best choices vary + depending on business priorities. For example if the server is primarily + tasked as a High Availability server, then you will want low delay + settings, perhaps even zero, though that is a very aggressive setting. If + the standby server is tasked as an additional server for decision support + queries then it might be acceptable to set the maximum delay values to + many hours, or even -1 which means wait forever for queries to complete. +

Transaction status "hint bits" written on the primary are not WAL-logged, + so data on the standby will likely re-write the hints again on the standby. + Thus, the standby server will still perform disk writes even though + all users are read-only; no changes occur to the data values + themselves. Users will still write large sort temporary files and + re-generate relcache info files, so no part of the database + is truly read-only during hot standby mode. + Note also that writes to remote databases using + dblink module, and other operations outside the + database using PL functions will still be possible, even though the + transaction is read-only locally. +

The following types of administration commands are not accepted + during recovery mode: + +

  • Data Definition Language (DDL) - e.g. CREATE INDEX +

  • Privilege and Ownership - GRANT, REVOKE, + REASSIGN +

  • Maintenance commands - ANALYZE, VACUUM, + CLUSTER, REINDEX +

+

Again, note that some of these commands are actually allowed during + "read only" mode transactions on the primary. +

As a result, you cannot create additional indexes that exist solely + on the standby, nor statistics that exist solely on the standby. + If these administration commands are needed, they should be executed + on the primary, and eventually those changes will propagate to the + standby. +

pg_cancel_backend() + and pg_terminate_backend() will work on user backends, + but not the Startup process, which performs + recovery. pg_stat_activity does not show an + entry for the Startup process, nor do recovering transactions show + as active. As a result, pg_prepared_xacts + is always empty during recovery. If you wish to resolve in-doubt + prepared transactions, view pg_prepared_xacts on the + primary and issue commands to resolve transactions there. +

pg_locks will show locks held by backends, + as normal. pg_locks also shows + a virtual transaction managed by the Startup process that owns all + AccessExclusiveLocks held by transactions being replayed by recovery. + Note that the Startup process does not acquire locks to + make database changes, and thus locks other than AccessExclusiveLocks + do not show in pg_locks for the Startup + process; they are just presumed to exist. +

The Nagios plugin check_pgsql will + work, because the simple information it checks for exists. + The check_postgres monitoring script will also work, + though some reported values could give different or confusing results. + For example, last vacuum time will not be maintained, since no + vacuum occurs on the standby. Vacuums running on the primary + do still send their changes to the standby. +

WAL file control commands will not work during recovery, + e.g. pg_start_backup, pg_switch_xlog etc. +

Dynamically loadable modules work, including pg_stat_statements. +

Advisory locks work normally in recovery, including deadlock detection. + Note that advisory locks are never WAL logged, so it is impossible for + an advisory lock on either the primary or the standby to conflict with WAL + replay. Nor is it possible to acquire an advisory lock on the primary + and have it initiate a similar advisory lock on the standby. Advisory + locks relate only to the server on which they are acquired. +

Trigger-based replication systems such as Slony, + Londiste and Bucardo won't run on the + standby at all, though they will run happily on the primary server as + long as the changes are not sent to standby servers to be applied. + WAL replay is not trigger-based so you cannot relay from the + standby to any system that requires additional database writes or + relies on the use of triggers. +

New OIDs cannot be assigned, though some UUID generators may still + work as long as they do not rely on writing new status to the database. +

Currently, temporary table creation is not allowed during read only + transactions, so in some cases existing scripts will not run correctly. + This restriction might be relaxed in a later release. This is + both a SQL Standard compliance issue and a technical issue. +

DROP TABLESPACE can only succeed if the tablespace is empty. + Some standby users may be actively using the tablespace via their + temp_tablespaces parameter. If there are temporary files in the + tablespace, all active queries are canceled to ensure that temporary + files are removed, so the tablespace can be removed and WAL replay + can continue. +

Running DROP DATABASE or ALTER DATABASE ... SET + TABLESPACE on the primary + will generate a WAL entry that will cause all users connected to that + database on the standby to be forcibly disconnected. This action occurs + immediately, whatever the setting of + max_standby_streaming_delay. Note that + ALTER DATABASE ... RENAME does not disconnect users, which + in most cases will go unnoticed, though might in some cases cause a + program confusion if it depends in some way upon database name. +

In normal (non-recovery) mode, if you issue DROP USER or DROP ROLE + for a role with login capability while that user is still connected then + nothing happens to the connected user - they remain connected. The user cannot + reconnect however. This behavior applies in recovery also, so a + DROP USER on the primary does not disconnect that user on the standby. +

The statistics collector is active during recovery. All scans, reads, blocks, + index usage, etc., will be recorded normally on the standby. Replayed + actions will not duplicate their effects on primary, so replaying an + insert will not increment the Inserts column of pg_stat_user_tables. + The stats file is deleted at the start of recovery, so stats from primary + and standby will differ; this is considered a feature, not a bug. +

Autovacuum is not active during recovery. It will start normally at the + end of recovery. +

The background writer is active during recovery and will perform + restartpoints (similar to checkpoints on the primary) and normal block + cleaning activities. This can include updates of the hint bit + information stored on the standby server. + The CHECKPOINT command is accepted during recovery, + though it performs a restartpoint rather than a new checkpoint. +

25.5.4. Hot Standby Parameter Reference

Various parameters have been mentioned above in + Section 25.5.2 and + Section 25.5.3. +

On the primary, parameters wal_level and + vacuum_defer_cleanup_age can be used. + max_standby_archive_delay and + max_standby_streaming_delay have no effect if set on + the primary. +

On the standby, parameters hot_standby, + max_standby_archive_delay and + max_standby_streaming_delay can be used. + vacuum_defer_cleanup_age has no effect + as long as the server remains in standby mode, though it will + become relevant if the standby becomes primary. +

25.5.5. Caveats

There are several limitations of Hot Standby. + These can and probably will be fixed in future releases: + +

  • Operations on hash indexes are not presently WAL-logged, so + replay will not update these indexes. +

  • Full knowledge of running transactions is required before snapshots + can be taken. Transactions that use large numbers of subtransactions + (currently greater than 64) will delay the start of read only + connections until the completion of the longest running write transaction. + If this situation occurs, explanatory messages will be sent to the server log. +

  • Valid starting points for standby queries are generated at each + checkpoint on the master. If the standby is shut down while the master + is in a shutdown state, it might not be possible to re-enter Hot Standby + until the primary is started up, so that it generates further starting + points in the WAL logs. This situation isn't a problem in the most + common situations where it might happen. Generally, if the primary is + shut down and not available anymore, that's likely due to a serious + failure that requires the standby being converted to operate as + the new primary anyway. And in situations where the primary is + being intentionally taken down, coordinating to make sure the standby + becomes the new primary smoothly is also standard procedure. +

  • At the end of recovery, AccessExclusiveLocks held by prepared transactions + will require twice the normal number of lock table entries. If you plan + on running either a large number of concurrent prepared transactions + that normally take AccessExclusiveLocks, or you plan on having one + large transaction that takes many AccessExclusiveLocks, you are + advised to select a larger value of max_locks_per_transaction, + perhaps as much as twice the value of the parameter on + the primary server. You need not consider this at all if + your setting of max_prepared_transactions is 0. +

  • The Serializable transaction isolation level is not yet available in hot + standby. (See Section 13.2.3 and + Section 13.4.1 for details.) + An attempt to set a transaction to the serializable isolation level in + hot standby mode will generate an error. +

+ +


PrevHomeNext
Alternative Method for Log ShippingUpRecovery Configuration
\ No newline at end of file diff --git a/doc/src/sgml/html/hstore.html b/doc/src/sgml/html/hstore.html new file mode 100644 index 000000000..2d2f1afeb --- /dev/null +++ b/doc/src/sgml/html/hstore.html @@ -0,0 +1,1603 @@ + +hstore
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.16. hstore

This module implements the hstore data type for storing sets of + key/value pairs within a single PostgreSQL value. + This can be useful in various scenarios, such as rows with many attributes + that are rarely examined, or semi-structured data. Keys and values are + simply text strings. +

F.16.1. hstore External Representation

The text representation of an hstore, used for input and output, + includes zero or more key => + value pairs separated by commas. Some examples: + +

k => v
+foo => bar, baz => whatever
+"1-a" => "anything at all"

+ + The order of the pairs is not significant (and may not be reproduced on + output). Whitespace between pairs or around the => sign is + ignored. Double-quote keys and values that include whitespace, commas, + =s or >s. To include a double quote or a + backslash in a key or value, escape it with a backslash. +

Each key in an hstore is unique. If you declare an hstore + with duplicate keys, only one will be stored in the hstore and + there is no guarantee as to which will be kept: + +

SELECT 'a=>1,a=>2'::hstore;
+  hstore
+----------
+ "a"=>"1"

+

A value (but not a key) can be an SQL NULL. For example: + +

key => NULL

+ + The NULL keyword is case-insensitive. Double-quote the + NULL to treat it as the ordinary string "NULL". +

Note: Keep in mind that the hstore text format, when used for input, + applies before any required quoting or escaping. If you are + passing an hstore literal via a parameter, then no additional + processing is needed. But if you're passing it as a quoted literal + constant, then any single-quote characters and (depending on the setting of + the standard_conforming_strings configuration parameter) + backslash characters need to be escaped correctly. See + Section 4.1.2.1 for more on the handling of string + constants. +

On output, double quotes always surround keys and values, even when it's + not strictly necessary. +

F.16.2. hstore Operators and Functions

The operators provided by the hstore module are + shown in Table F-6, the functions + in Table F-7. +

Table F-6. hstore Operators

OperatorDescriptionExampleResult
hstore -> textget value for key (NULL if not present)'a=>x, b=>y'::hstore -> 'a'x
hstore -> text[]get values for keys (NULL if not present)'a=>x, b=>y, c=>z'::hstore -> ARRAY['c','a']{"z","x"}
hstore || hstoreconcatenate hstores'a=>b, c=>d'::hstore || 'c=>x, d=>q'::hstore"a"=>"b", "c"=>"x", "d"=>"q"
hstore ? textdoes hstore contain key?'a=>1'::hstore ? 'a't
hstore ?& text[]does hstore contain all specified keys?'a=>1,b=>2'::hstore ?& ARRAY['a','b']t
hstore ?| text[]does hstore contain any of the specified keys?'a=>1,b=>2'::hstore ?| ARRAY['b','c']t
hstore @> hstoredoes left operand contain right?'a=>b, b=>1, c=>NULL'::hstore @> 'b=>1't
hstore <@ hstoreis left operand contained in right?'a=>c'::hstore <@ 'a=>b, b=>1, c=>NULL'f
hstore - textdelete key from left operand'a=>1, b=>2, c=>3'::hstore - 'b'::text"a"=>"1", "c"=>"3"
hstore - text[]delete keys from left operand'a=>1, b=>2, c=>3'::hstore - ARRAY['a','b']"c"=>"3"
hstore - hstoredelete matching pairs from left operand'a=>1, b=>2, c=>3'::hstore - 'a=>4, b=>2'::hstore"a"=>"1", "c"=>"3"
record #= hstorereplace fields in record with matching values from hstoresee Examples section 
%% hstoreconvert hstore to array of alternating keys and values%% 'a=>foo, b=>bar'::hstore{a,foo,b,bar}
%# hstoreconvert hstore to two-dimensional key/value array%# 'a=>foo, b=>bar'::hstore{{a,foo},{b,bar}}

Note: Prior to PostgreSQL 8.2, the containment operators @> + and <@ were called @ and ~, + respectively. These names are still available, but are deprecated and will + eventually be removed. Notice that the old names are reversed from the + convention formerly followed by the core geometric data types! +

Table F-7. hstore Functions

FunctionReturn TypeDescriptionExampleResult
hstore(record)hstoreconstruct an hstore from a record or rowhstore(ROW(1,2))f1=>1,f2=>2
hstore(text[])hstoreconstruct an hstore from an array, which may be either + a key/value array, or a two-dimensional arrayhstore(ARRAY['a','1','b','2']) || hstore(ARRAY[['c','3'],['d','4']])a=>1, b=>2, c=>3, d=>4
hstore(text[], text[])hstoreconstruct an hstore from separate key and value arrayshstore(ARRAY['a','b'], ARRAY['1','2'])"a"=>"1","b"=>"2"
hstore(text, text)hstoremake single-item hstorehstore('a', 'b')"a"=>"b"
akeys(hstore)text[]get hstore's keys as an arrayakeys('a=>1,b=>2'){a,b}
skeys(hstore)setof textget hstore's keys as a setskeys('a=>1,b=>2')
a
+b
avals(hstore)text[]get hstore's values as an arrayavals('a=>1,b=>2'){1,2}
svals(hstore)setof textget hstore's values as a setsvals('a=>1,b=>2')
1
+2
hstore_to_array(hstore)text[]get hstore's keys and values as an array of alternating + keys and valueshstore_to_array('a=>1,b=>2'){a,1,b,2}
hstore_to_matrix(hstore)text[]get hstore's keys and values as a two-dimensional arrayhstore_to_matrix('a=>1,b=>2'){{a,1},{b,2}}
slice(hstore, text[])hstoreextract a subset of an hstoreslice('a=>1,b=>2,c=>3'::hstore, ARRAY['b','c','x'])"b"=>"2", "c"=>"3"
each(hstore)setof(key text, value text)get hstore's keys and values as a setselect * from each('a=>1,b=>2')
 key | value
+-----+-------
+ a   | 1
+ b   | 2
exist(hstore,text)booleandoes hstore contain key?exist('a=>1','a')t
defined(hstore,text)booleandoes hstore contain non-NULL value for key?defined('a=>NULL','a')f
delete(hstore,text)hstoredelete pair with matching keydelete('a=>1,b=>2','b')"a"=>"1"
delete(hstore,text[])hstoredelete pairs with matching keysdelete('a=>1,b=>2,c=>3',ARRAY['a','b'])"c"=>"3"
delete(hstore,hstore)hstoredelete pairs matching those in the second argumentdelete('a=>1,b=>2','a=>4,b=>2'::hstore)"a"=>"1"
populate_record(record,hstore)recordreplace fields in record with matching values from hstoresee Examples section 

Note: The function populate_record is actually declared + with anyelement, not record, as its first argument, + but it will reject non-record types with a run-time error. +

F.16.3. Indexes

hstore has GiST and GIN index support for the @>, + ?, ?& and ?| operators. For example: +

CREATE INDEX hidx ON testhstore USING GIST (h);
+
+CREATE INDEX hidx ON testhstore USING GIN (h);

hstore also supports btree or hash indexes for + the = operator. This allows hstore columns to be + declared UNIQUE, or to be used in GROUP BY, + ORDER BY or DISTINCT expressions. The sort ordering + for hstore values is not particularly useful, but these indexes + may be useful for equivalence lookups. Create indexes for = + comparisons as follows: +

CREATE INDEX hidx ON testhstore USING BTREE (h);
+
+CREATE INDEX hidx ON testhstore USING HASH (h);

F.16.4. Examples

Add a key, or update an existing key with a new value: +

UPDATE tab SET h = h || hstore('c', '3');

+

Delete a key: +

UPDATE tab SET h = delete(h, 'k1');

+

Convert a record to an hstore: +

CREATE TABLE test (col1 integer, col2 text, col3 text);
+INSERT INTO test VALUES (123, 'foo', 'bar');
+
+SELECT hstore(t) FROM test AS t;
+                   hstore                    
+---------------------------------------------
+ "col1"=>"123", "col2"=>"foo", "col3"=>"bar"
+(1 row)

+

Convert an hstore to a predefined record type: +

CREATE TABLE test (col1 integer, col2 text, col3 text);
+
+SELECT * FROM populate_record(null::test,
+                              '"col1"=>"456", "col2"=>"zzz"');
+ col1 | col2 | col3 
+------+------+------
+  456 | zzz  | 
+(1 row)

+

Modify an existing record using the values from an hstore: +

CREATE TABLE test (col1 integer, col2 text, col3 text);
+INSERT INTO test VALUES (123, 'foo', 'bar');
+
+SELECT (r).* FROM (SELECT t #= '"col3"=>"baz"' AS r FROM test t) s;
+ col1 | col2 | col3 
+------+------+------
+  123 | foo  | baz
+(1 row)

+

F.16.5. Statistics

The hstore type, because of its intrinsic liberality, could + contain a lot of different keys. Checking for valid keys is the task of the + application. The following examples demonstrate several techniques for + checking keys and obtaining statistics. +

Simple example: +

SELECT * FROM each('aaa=>bq, b=>NULL, ""=>1');

+

Using a table: +

SELECT (each(h)).key, (each(h)).value INTO stat FROM testhstore;

+

Online statistics: +

SELECT key, count(*) FROM
+  (SELECT (each(h)).key FROM testhstore) AS stat
+  GROUP BY key
+  ORDER BY count DESC, key;
+    key    | count
+-----------+-------
+ line      |   883
+ query     |   207
+ pos       |   203
+ node      |   202
+ space     |   197
+ status    |   195
+ public    |   194
+ title     |   190
+ org       |   189
+...................

+

F.16.6. Compatibility

As of PostgreSQL 9.0, hstore uses a different internal + representation than previous versions. This presents no obstacle for + dump/restore upgrades since the text representation (used in the dump) is + unchanged. +

In the event of a binary upgrade, upward compatibility is maintained by + having the new code recognize old-format data. This will entail a slight + performance penalty when processing data that has not yet been modified by + the new code. It is possible to force an upgrade of all values in a table + column by doing an UPDATE statement as follows: +

UPDATE tablename SET hstorecol = hstorecol || '';

+

Another way to do it is: +

ALTER TABLE tablename ALTER hstorecol TYPE hstore USING hstorecol || '';

+ The ALTER TABLE method requires an exclusive lock on the table, + but does not result in bloating the table with old row versions. +

F.16.7. Authors

Oleg Bartunov <oleg@sai.msu.su>, Moscow, Moscow University, Russia +

Teodor Sigaev <teodor@sigaev.ru>, Moscow, Delta-Soft Ltd., Russia +

Additional enhancements by Andrew Gierth <andrew@tao11.riddles.org.uk>, + United Kingdom +


PrevHomeNext
fuzzystrmatchUpintagg
\ No newline at end of file diff --git a/doc/src/sgml/html/index-catalog.html b/doc/src/sgml/html/index-catalog.html new file mode 100644 index 000000000..d516a8503 --- /dev/null +++ b/doc/src/sgml/html/index-catalog.html @@ -0,0 +1,381 @@ + +Catalog Entries for Indexes
PostgreSQL 9.2.2 Documentation
PrevUpChapter 52. Index Access Method Interface DefinitionNext

52.1. Catalog Entries for Indexes

Each index access method is described by a row in the + pg_am system catalog (see + Section 45.3). The principal contents of a + pg_am row are references to + pg_proc + entries that identify the index access + functions supplied by the access method. The APIs for these functions + are defined later in this chapter. In addition, the + pg_am row specifies a few fixed properties of + the access method, such as whether it can support multicolumn indexes. + There is not currently any special support + for creating or deleting pg_am entries; + anyone able to write a new access method is expected to be competent + to insert an appropriate row for themselves. +

To be useful, an index access method must also have one or more + operator families and + operator classes defined in + pg_opfamily, + pg_opclass, + pg_amop, and + pg_amproc. + These entries allow the planner + to determine what kinds of query qualifications can be used with + indexes of this access method. Operator families and classes are described + in Section 35.14, which is prerequisite material for reading + this chapter. +

An individual index is defined by a + pg_class + entry that describes it as a physical relation, plus a + pg_index + entry that shows the logical content of the index — that is, the set + of index columns it has and the semantics of those columns, as captured by + the associated operator classes. The index columns (key values) can be + either simple columns of the underlying table or expressions over the table + rows. The index access method normally has no interest in where the index + key values come from (it is always handed precomputed key values) but it + will be very interested in the operator class information in + pg_index. Both of these catalog entries can be + accessed as part of the Relation data structure that is + passed to all operations on the index. +

Some of the flag columns of pg_am have nonobvious + implications. The requirements of amcanunique + are discussed in Section 52.5. + The amcanmulticol flag asserts that the + access method supports multicolumn indexes, while + amoptionalkey asserts that it allows scans + where no indexable restriction clause is given for the first index column. + When amcanmulticol is false, + amoptionalkey essentially says whether the + access method supports full-index scans without any restriction clause. + Access methods that support multiple index columns must + support scans that omit restrictions on any or all of the columns after + the first; however they are permitted to require some restriction to + appear for the first index column, and this is signaled by setting + amoptionalkey false. + One reason that an index AM might set + amoptionalkey false is if it doesn't index + NULLs. Since most indexable operators are + strict and hence cannot return TRUE for NULL inputs, + it is at first sight attractive to not store index entries for null values: + they could never be returned by an index scan anyway. However, this + argument fails when an index scan has no restriction clause for a given + index column. In practice this means that + indexes that have amoptionalkey true must + index nulls, since the planner might decide to use such an index + with no scan keys at all. A related restriction is that an index + access method that supports multiple index columns must + support indexing null values in columns after the first, because the planner + will assume the index can be used for queries that do not restrict + these columns. For example, consider an index on (a,b) and a query with + WHERE a = 4. The system will assume the index can be + used to scan for rows with a = 4, which is wrong if the + index omits rows where b is null. + It is, however, OK to omit rows where the first indexed column is null. + An index access method that does index nulls may also set + amsearchnulls, indicating that it supports + IS NULL and IS NOT NULL clauses as search + conditions. +


PrevHomeNext
Index Access Method Interface DefinitionUpIndex Access Method Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/index-cost-estimation.html b/doc/src/sgml/html/index-cost-estimation.html new file mode 100644 index 000000000..f86e50720 --- /dev/null +++ b/doc/src/sgml/html/index-cost-estimation.html @@ -0,0 +1,472 @@ + +Index Cost Estimation Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 52. Index Access Method Interface DefinitionNext

52.6. Index Cost Estimation Functions

The amcostestimate function is given information describing + a possible index scan, including lists of WHERE and ORDER BY clauses that + have been determined to be usable with the index. It must return estimates + of the cost of accessing the index and the selectivity of the WHERE + clauses (that is, the fraction of parent-table rows that will be + retrieved during the index scan). For simple cases, nearly all the + work of the cost estimator can be done by calling standard routines + in the optimizer; the point of having an amcostestimate function is + to allow index access methods to provide index-type-specific knowledge, + in case it is possible to improve on the standard estimates. +

Each amcostestimate function must have the signature: + +

void
+amcostestimate (PlannerInfo *root,
+                IndexPath *path,
+                double loop_count,
+                Cost *indexStartupCost,
+                Cost *indexTotalCost,
+                Selectivity *indexSelectivity,
+                double *indexCorrelation);

+ + The first three parameters are inputs: + +

root

The planner's information about the query being processed. +

path

The index access path being considered. All fields except cost and + selectivity values are valid. +

loop_count

The number of repetitions of the index scan that should be factored + into the cost estimates. This will typically be greater than one when + considering a parameterized scan for use in the inside of a nestloop + join. Note that the cost estimates should still be for just one scan; + a larger loop_count means that it may be appropriate + to allow for some caching effects across multiple scans. +

+

The last four parameters are pass-by-reference outputs: + +

*indexStartupCost

Set to cost of index start-up processing +

*indexTotalCost

Set to total cost of index processing +

*indexSelectivity

Set to index selectivity +

*indexCorrelation

Set to correlation coefficient between index scan order and + underlying table's order +

+

Note that cost estimate functions must be written in C, not in SQL or + any available procedural language, because they must access internal + data structures of the planner/optimizer. +

The index access costs should be computed using the parameters used by + src/backend/optimizer/path/costsize.c: a sequential + disk block fetch has cost seq_page_cost, a nonsequential fetch + has cost random_page_cost, and the cost of processing one index + row should usually be taken as cpu_index_tuple_cost. In + addition, an appropriate multiple of cpu_operator_cost should + be charged for any comparison operators invoked during index processing + (especially evaluation of the indexquals themselves). +

The access costs should include all disk and CPU costs associated with + scanning the index itself, but not the costs of retrieving or + processing the parent-table rows that are identified by the index. +

The "start-up cost" is the part of the total scan cost that + must be expended before we can begin to fetch the first row. For most + indexes this can be taken as zero, but an index type with a high start-up + cost might want to set it nonzero. +

The indexSelectivity should be set to the estimated fraction of the parent + table rows that will be retrieved during the index scan. In the case + of a lossy query, this will typically be higher than the fraction of + rows that actually pass the given qual conditions. +

The indexCorrelation should be set to the correlation (ranging between + -1.0 and 1.0) between the index order and the table order. This is used + to adjust the estimate for the cost of fetching rows from the parent + table. +

When loop_count is greater than one, the returned numbers + should be averages expected for any one scan of the index. +

Cost Estimation

A typical cost estimator will proceed as follows: +

  1. Estimate and return the fraction of parent-table rows that will be visited + based on the given qual conditions. In the absence of any index-type-specific + knowledge, use the standard optimizer function clauselist_selectivity(): + +

    *indexSelectivity = clauselist_selectivity(root, path->indexquals,
    +                                           path->indexinfo->rel->relid,
    +                                           JOIN_INNER, NULL);

    +

  2. Estimate the number of index rows that will be visited during the + scan. For many index types this is the same as indexSelectivity times + the number of rows in the index, but it might be more. (Note that the + index's size in pages and rows is available from the + path->indexinfo struct.) +

  3. Estimate the number of index pages that will be retrieved during the scan. + This might be just indexSelectivity times the index's size in pages. +

  4. Compute the index access cost. A generic estimator might do this: + +

    /*
    + * Our generic assumption is that the index pages will be read
    + * sequentially, so they cost seq_page_cost each, not random_page_cost.
    + * Also, we charge for evaluation of the indexquals at each index row.
    + * All the costs are assumed to be paid incrementally during the scan.
    + */
    +cost_qual_eval(&index_qual_cost, path->indexquals, root);
    +*indexStartupCost = index_qual_cost.startup;
    +*indexTotalCost = seq_page_cost * numIndexPages +
    +    (cpu_index_tuple_cost + index_qual_cost.per_tuple) * numIndexTuples;

    + + However, the above does not account for amortization of index reads + across repeated index scans. +

  5. Estimate the index correlation. For a simple ordered index on a single + field, this can be retrieved from pg_statistic. If the correlation + is not known, the conservative estimate is zero (no correlation). +

Examples of cost estimator functions can be found in + src/backend/utils/adt/selfuncs.c. +


PrevHomeNext
Index Uniqueness ChecksUpGiST Indexes
\ No newline at end of file diff --git a/doc/src/sgml/html/index-functions.html b/doc/src/sgml/html/index-functions.html new file mode 100644 index 000000000..579bd656a --- /dev/null +++ b/doc/src/sgml/html/index-functions.html @@ -0,0 +1,842 @@ + +Index Access Method Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 52. Index Access Method Interface DefinitionNext

52.2. Index Access Method Functions

The index construction and maintenance functions that an index access + method must provide are: +

IndexBuildResult *
+ambuild (Relation heapRelation,
+         Relation indexRelation,
+         IndexInfo *indexInfo);

+ Build a new index. The index relation has been physically created, + but is empty. It must be filled in with whatever fixed data the + access method requires, plus entries for all tuples already existing + in the table. Ordinarily the ambuild function will call + IndexBuildHeapScan() to scan the table for existing tuples + and compute the keys that need to be inserted into the index. + The function must return a palloc'd struct containing statistics about + the new index. +

void
+ambuildempty (Relation indexRelation);

+ Build an empty index, and write it to the initialization fork (INIT_FORKNUM) + of the given relation. This method is called only for unlogged tables; the + empty index written to the initialization fork will be copied over the main + relation fork on each server restart. +

bool
+aminsert (Relation indexRelation,
+          Datum *values,
+          bool *isnull,
+          ItemPointer heap_tid,
+          Relation heapRelation,
+          IndexUniqueCheck checkUnique);

+ Insert a new tuple into an existing index. The values and + isnull arrays give the key values to be indexed, and + heap_tid is the TID to be indexed. + If the access method supports unique indexes (its + pg_am.amcanunique flag is true) then + checkUnique indicates the type of uniqueness check to + perform. This varies depending on whether the unique constraint is + deferrable; see Section 52.5 for details. + Normally the access method only needs the heapRelation + parameter when performing uniqueness checking (since then it will have to + look into the heap to verify tuple liveness). +

The function's Boolean result value is significant only when + checkUnique is UNIQUE_CHECK_PARTIAL. + In this case a TRUE result means the new entry is known unique, whereas + FALSE means it might be non-unique (and a deferred uniqueness check must + be scheduled). For other cases a constant FALSE result is recommended. +

Some indexes might not index all tuples. If the tuple is not to be + indexed, aminsert should just return without doing anything. +

IndexBulkDeleteResult *
+ambulkdelete (IndexVacuumInfo *info,
+              IndexBulkDeleteResult *stats,
+              IndexBulkDeleteCallback callback,
+              void *callback_state);

+ Delete tuple(s) from the index. This is a "bulk delete" operation + that is intended to be implemented by scanning the whole index and checking + each entry to see if it should be deleted. + The passed-in callback function must be called, in the style + callback(TID, callback_state) returns bool, + to determine whether any particular index entry, as identified by its + referenced TID, is to be deleted. Must return either NULL or a palloc'd + struct containing statistics about the effects of the deletion operation. + It is OK to return NULL if no information needs to be passed on to + amvacuumcleanup. +

Because of limited maintenance_work_mem, + ambulkdelete might need to be called more than once when many + tuples are to be deleted. The stats argument is the result + of the previous call for this index (it is NULL for the first call within a + VACUUM operation). This allows the AM to accumulate statistics + across the whole operation. Typically, ambulkdelete will + modify and return the same struct if the passed stats is not + null. +

IndexBulkDeleteResult *
+amvacuumcleanup (IndexVacuumInfo *info,
+                 IndexBulkDeleteResult *stats);

+ Clean up after a VACUUM operation (zero or more + ambulkdelete calls). This does not have to do anything + beyond returning index statistics, but it might perform bulk cleanup + such as reclaiming empty index pages. stats is whatever the + last ambulkdelete call returned, or NULL if + ambulkdelete was not called because no tuples needed to be + deleted. If the result is not NULL it must be a palloc'd struct. + The statistics it contains will be used to update pg_class, + and will be reported by VACUUM if VERBOSE is given. + It is OK to return NULL if the index was not changed at all during the + VACUUM operation, but otherwise correct stats should + be returned. +

As of PostgreSQL 8.4, + amvacuumcleanup will also be called at completion of an + ANALYZE operation. In this case stats is always + NULL and any return value will be ignored. This case can be distinguished + by checking info->analyze_only. It is recommended + that the access method do nothing except post-insert cleanup in such a + call, and that only in an autovacuum worker process. +

bool
+amcanreturn (Relation indexRelation);

+ Check whether the index can support index-only scans by + returning the indexed column values for an index entry in the form of an + IndexTuple. Return TRUE if so, else FALSE. If the index AM can never + support index-only scans (an example is hash, which stores only + the hash values not the original data), it is sufficient to set its + amcanreturn field to zero in pg_am. +

void
+amcostestimate (PlannerInfo *root,
+                IndexPath *path,
+                double loop_count,
+                Cost *indexStartupCost,
+                Cost *indexTotalCost,
+                Selectivity *indexSelectivity,
+                double *indexCorrelation);

+ Estimate the costs of an index scan. This function is described fully + in Section 52.6, below. +

bytea *
+amoptions (ArrayType *reloptions,
+           bool validate);

+ Parse and validate the reloptions array for an index. This is called only + when a non-null reloptions array exists for the index. + reloptions is a text array containing entries of the + form name=value. + The function should construct a bytea value, which will be copied + into the rd_options field of the index's relcache entry. + The data contents of the bytea value are open for the access + method to define; most of the standard access methods use struct + StdRdOptions. + When validate is true, the function should report a suitable + error message if any of the options are unrecognized or have invalid + values; when validate is false, invalid entries should be + silently ignored. (validate is false when loading options + already stored in pg_catalog; an invalid entry could only + be found if the access method has changed its rules for options, and in + that case ignoring obsolete entries is appropriate.) + It is OK to return NULL if default behavior is wanted. +

The purpose of an index, of course, is to support scans for tuples matching + an indexable WHERE condition, often called a + qualifier or scan key. The semantics of + index scanning are described more fully in Section 52.3, + below. An index access method can support "plain" index scans, + "bitmap" index scans, or both. The scan-related functions that an + index access method must or may provide are: +

IndexScanDesc
+ambeginscan (Relation indexRelation,
+             int nkeys,
+             int norderbys);

+ Prepare for an index scan. The nkeys and norderbys + parameters indicate the number of quals and ordering operators that will be + used in the scan; these may be useful for space allocation purposes. + Note that the actual values of the scan keys aren't provided yet. + The result must be a palloc'd struct. + For implementation reasons the index access method + must create this struct by calling + RelationGetIndexScan(). In most cases + ambeginscan does little beyond making that call and perhaps + acquiring locks; + the interesting parts of index-scan startup are in amrescan. +

void
+amrescan (IndexScanDesc scan,
+          ScanKey keys,
+          int nkeys,
+          ScanKey orderbys,
+          int norderbys);

+ Start or restart an index scan, possibly with new scan keys. (To restart + using previously-passed keys, NULL is passed for keys and/or + orderbys.) Note that it is not allowed for + the number of keys or order-by operators to be larger than + what was passed to ambeginscan. In practice the restart + feature is used when a new outer tuple is selected by a nested-loop join + and so a new key comparison value is needed, but the scan key structure + remains the same. +

boolean
+amgettuple (IndexScanDesc scan,
+            ScanDirection direction);

+ Fetch the next tuple in the given scan, moving in the given + direction (forward or backward in the index). Returns TRUE if a tuple was + obtained, FALSE if no matching tuples remain. In the TRUE case the tuple + TID is stored into the scan structure. Note that + "success" means only that the index contains an entry that matches + the scan keys, not that the tuple necessarily still exists in the heap or + will pass the caller's snapshot test. On success, amgettuple + must also set scan->xs_recheck to TRUE or FALSE. + FALSE means it is certain that the index entry matches the scan keys. + TRUE means this is not certain, and the conditions represented by the + scan keys must be rechecked against the heap tuple after fetching it. + This provision supports "lossy" index operators. + Note that rechecking will extend only to the scan conditions; a partial + index predicate (if any) is never rechecked by amgettuple + callers. +

If the index supports index-only scans (i.e., + amcanreturn returns TRUE for it), + then on success the AM must also check + scan->xs_want_itup, and if that is true it must return + the original indexed data for the index entry, in the form of an + IndexTuple pointer stored at scan->xs_itup, + with tuple descriptor scan->xs_itupdesc. + (Management of the data referenced by the pointer is the access method's + responsibility. The data must remain good at least until the next + amgettuple, amrescan, or amendscan + call for the scan.) +

The amgettuple function need only be provided if the access + method supports "plain" index scans. If it doesn't, the + amgettuple field in its pg_am row must + be set to zero. +

int64
+amgetbitmap (IndexScanDesc scan,
+             TIDBitmap *tbm);

+ Fetch all tuples in the given scan and add them to the caller-supplied + TIDBitmap (that is, OR the set of tuple IDs into whatever set is already + in the bitmap). The number of tuples fetched is returned (this might be + just an approximate count, for instance some AMs do not detect duplicates). + While inserting tuple IDs into the bitmap, amgetbitmap can + indicate that rechecking of the scan conditions is required for specific + tuple IDs. This is analogous to the xs_recheck output parameter + of amgettuple. Note: in the current implementation, support + for this feature is conflated with support for lossy storage of the bitmap + itself, and therefore callers recheck both the scan conditions and the + partial index predicate (if any) for recheckable tuples. That might not + always be true, however. + amgetbitmap and + amgettuple cannot be used in the same index scan; there + are other restrictions too when using amgetbitmap, as explained + in Section 52.3. +

The amgetbitmap function need only be provided if the access + method supports "bitmap" index scans. If it doesn't, the + amgetbitmap field in its pg_am row must + be set to zero. +

void
+amendscan (IndexScanDesc scan);

+ End a scan and release resources. The scan struct itself + should not be freed, but any locks or pins taken internally by the + access method must be released. +

void
+ammarkpos (IndexScanDesc scan);

+ Mark current scan position. The access method need only support one + remembered scan position per scan. +

void
+amrestrpos (IndexScanDesc scan);

+ Restore the scan to the most recently marked position. +

By convention, the pg_proc entry for an index + access method function should show the correct number of arguments, + but declare them all as type internal (since most of the arguments + have types that are not known to SQL, and we don't want users calling + the functions directly anyway). The return type is declared as + void, internal, or boolean as appropriate. + The only exception is amoptions, which should be correctly + declared as taking text[] and bool and returning + bytea. This provision allows client code to execute + amoptions to test validity of options settings. +


PrevHomeNext
Catalog Entries for IndexesUpIndex Scanning
\ No newline at end of file diff --git a/doc/src/sgml/html/index-locking.html b/doc/src/sgml/html/index-locking.html new file mode 100644 index 000000000..bd44f8373 --- /dev/null +++ b/doc/src/sgml/html/index-locking.html @@ -0,0 +1,341 @@ + +Index Locking Considerations
PostgreSQL 9.2.2 Documentation
PrevUpChapter 52. Index Access Method Interface DefinitionNext

52.4. Index Locking Considerations

Index access methods must handle concurrent updates + of the index by multiple processes. + The core PostgreSQL system obtains + AccessShareLock on the index during an index scan, and + RowExclusiveLock when updating the index (including plain + VACUUM). Since these lock types do not conflict, the access + method is responsible for handling any fine-grained locking it might need. + An exclusive lock on the index as a whole will be taken only during index + creation, destruction, or REINDEX. +

Building an index type that supports concurrent updates usually requires + extensive and subtle analysis of the required behavior. For the b-tree + and hash index types, you can read about the design decisions involved in + src/backend/access/nbtree/README and + src/backend/access/hash/README. +

Aside from the index's own internal consistency requirements, concurrent + updates create issues about consistency between the parent table (the + heap) and the index. Because + PostgreSQL separates accesses + and updates of the heap from those of the index, there are windows in + which the index might be inconsistent with the heap. We handle this problem + with the following rules: + +

  • A new heap entry is made before making its index entries. (Therefore + a concurrent index scan is likely to fail to see the heap entry. + This is okay because the index reader would be uninterested in an + uncommitted row anyway. But see Section 52.5.) +

  • When a heap entry is to be deleted (by VACUUM), all its + index entries must be removed first. +

  • An index scan must maintain a pin + on the index page holding the item last returned by + amgettuple, and ambulkdelete cannot delete + entries from pages that are pinned by other backends. The need + for this rule is explained below. +

+ + Without the third rule, it is possible for an index reader to + see an index entry just before it is removed by VACUUM, and + then to arrive at the corresponding heap entry after that was removed by + VACUUM. + This creates no serious problems if that item + number is still unused when the reader reaches it, since an empty + item slot will be ignored by heap_fetch(). But what if a + third backend has already re-used the item slot for something else? + When using an MVCC-compliant snapshot, there is no problem because + the new occupant of the slot is certain to be too new to pass the + snapshot test. However, with a non-MVCC-compliant snapshot (such as + SnapshotNow), it would be possible to accept and return + a row that does not in fact match the scan keys. We could defend + against this scenario by requiring the scan keys to be rechecked + against the heap row in all cases, but that is too expensive. Instead, + we use a pin on an index page as a proxy to indicate that the reader + might still be "in flight" from the index entry to the matching + heap entry. Making ambulkdelete block on such a pin ensures + that VACUUM cannot delete the heap entry before the reader + is done with it. This solution costs little in run time, and adds blocking + overhead only in the rare cases where there actually is a conflict. +

This solution requires that index scans be "synchronous": we have + to fetch each heap tuple immediately after scanning the corresponding index + entry. This is expensive for a number of reasons. An + "asynchronous" scan in which we collect many TIDs from the index, + and only visit the heap tuples sometime later, requires much less index + locking overhead and can allow a more efficient heap access pattern. + Per the above analysis, we must use the synchronous approach for + non-MVCC-compliant snapshots, but an asynchronous scan is workable + for a query using an MVCC snapshot. +

In an amgetbitmap index scan, the access method does not + keep an index pin on any of the returned tuples. Therefore + it is only safe to use such scans with MVCC-compliant snapshots. +

When the ampredlocks flag is not set, any scan using that + index access method within a serializable transaction will acquire a + non-blocking predicate lock on the full index. This will generate a + read-write conflict with the insert of any tuple into that index by a + concurrent serializable transaction. If certain patterns of read-write + conflicts are detected among a set of concurrent serializable + transactions, one of those transactions may be canceled to protect data + integrity. When the flag is set, it indicates that the index access + method implements finer-grained predicate locking, which will tend to + reduce the frequency of such transaction cancellations. +


PrevHomeNext
Index ScanningUpIndex Uniqueness Checks
\ No newline at end of file diff --git a/doc/src/sgml/html/index-scanning.html b/doc/src/sgml/html/index-scanning.html new file mode 100644 index 000000000..50041c924 --- /dev/null +++ b/doc/src/sgml/html/index-scanning.html @@ -0,0 +1,466 @@ + +Index Scanning
PostgreSQL 9.2.2 Documentation
PrevUpChapter 52. Index Access Method Interface DefinitionNext

52.3. Index Scanning

In an index scan, the index access method is responsible for regurgitating + the TIDs of all the tuples it has been told about that match the + scan keys. The access method is not involved in + actually fetching those tuples from the index's parent table, nor in + determining whether they pass the scan's time qualification test or other + conditions. +

A scan key is the internal representation of a WHERE clause of + the form index_key operator + constant, where the index key is one of the columns of the + index and the operator is one of the members of the operator family + associated with that index column. An index scan has zero or more scan + keys, which are implicitly ANDed — the returned tuples are expected + to satisfy all the indicated conditions. +

The access method can report that the index is lossy, or + requires rechecks, for a particular query. This implies that the index + scan will return all the entries that pass the scan key, plus possibly + additional entries that do not. The core system's index-scan machinery + will then apply the index conditions again to the heap tuple to verify + whether or not it really should be selected. If the recheck option is not + specified, the index scan must return exactly the set of matching entries. +

Note that it is entirely up to the access method to ensure that it + correctly finds all and only the entries passing all the given scan keys. + Also, the core system will simply hand off all the WHERE + clauses that match the index keys and operator families, without any + semantic analysis to determine whether they are redundant or + contradictory. As an example, given + WHERE x > 4 AND x > 14 where x is a b-tree + indexed column, it is left to the b-tree amrescan function + to realize that the first scan key is redundant and can be discarded. + The extent of preprocessing needed during amrescan will + depend on the extent to which the index access method needs to reduce + the scan keys to a "normalized" form. +

Some access methods return index entries in a well-defined order, others + do not. There are actually two different ways that an access method can + support sorted output: + +

  • Access methods that always return entries in the natural ordering + of their data (such as btree) should set + pg_am.amcanorder to true. + Currently, such access methods must use btree-compatible strategy + numbers for their equality and ordering operators. +

  • Access methods that support ordering operators should set + pg_am.amcanorderbyop to true. + This indicates that the index is capable of returning entries in + an order satisfying ORDER BY index_key + operator constant. Scan modifiers + of that form can be passed to amrescan as described + previously. +

+

The amgettuple function has a direction argument, + which can be either ForwardScanDirection (the normal case) + or BackwardScanDirection. If the first call after + amrescan specifies BackwardScanDirection, then the + set of matching index entries is to be scanned back-to-front rather than in + the normal front-to-back direction, so amgettuple must return + the last matching tuple in the index, rather than the first one as it + normally would. (This will only occur for access + methods that set amcanorder to true.) After the + first call, amgettuple must be prepared to advance the scan in + either direction from the most recently returned entry. (But if + pg_am.amcanbackward is false, all subsequent + calls will have the same direction as the first one.) +

Access methods that support ordered scans must support "marking" a + position in a scan and later returning to the marked position. The same + position might be restored multiple times. However, only one position need + be remembered per scan; a new ammarkpos call overrides the + previously marked position. An access method that does not support + ordered scans should still provide mark and restore functions in + pg_am, but it is sufficient to have them throw errors if + called. +

Both the scan position and the mark position (if any) must be maintained + consistently in the face of concurrent insertions or deletions in the + index. It is OK if a freshly-inserted entry is not returned by a scan that + would have found the entry if it had existed when the scan started, or for + the scan to return such an entry upon rescanning or backing + up even though it had not been returned the first time through. Similarly, + a concurrent delete might or might not be reflected in the results of a scan. + What is important is that insertions or deletions not cause the scan to + miss or multiply return entries that were not themselves being inserted or + deleted. +

If the index stores the original indexed data values (and not some lossy + representation of them), it is useful to support index-only scans, in + which the index returns the actual data not just the TID of the heap tuple. + This will only work if the visibility map shows that the TID is on an + all-visible page; else the heap tuple must be visited anyway to check + MVCC visibility. But that is no concern of the access method's. +

Instead of using amgettuple, an index scan can be done with + amgetbitmap to fetch all tuples in one call. This can be + noticeably more efficient than amgettuple because it allows + avoiding lock/unlock cycles within the access method. In principle + amgetbitmap should have the same effects as repeated + amgettuple calls, but we impose several restrictions to + simplify matters. First of all, amgetbitmap returns all + tuples at once and marking or restoring scan positions isn't + supported. Secondly, the tuples are returned in a bitmap which doesn't + have any specific ordering, which is why amgetbitmap doesn't + take a direction argument. (Ordering operators will never be + supplied for such a scan, either.) + Also, there is no provision for index-only scans with + amgetbitmap, since there is no way to return the contents of + index tuples. + Finally, amgetbitmap + does not guarantee any locking of the returned tuples, with implications + spelled out in Section 52.4. +

Note that it is permitted for an access method to implement only + amgetbitmap and not amgettuple, or vice versa, + if its internal implementation is unsuited to one API or the other. +


PrevHomeNext
Index Access Method FunctionsUpIndex Locking Considerations
\ No newline at end of file diff --git a/doc/src/sgml/html/index-unique-checks.html b/doc/src/sgml/html/index-unique-checks.html new file mode 100644 index 000000000..9d7ec0c3d --- /dev/null +++ b/doc/src/sgml/html/index-unique-checks.html @@ -0,0 +1,364 @@ + +Index Uniqueness Checks
PostgreSQL 9.2.2 Documentation
PrevUpChapter 52. Index Access Method Interface DefinitionNext

52.5. Index Uniqueness Checks

PostgreSQL enforces SQL uniqueness constraints + using unique indexes, which are indexes that disallow + multiple entries with identical keys. An access method that supports this + feature sets pg_am.amcanunique true. + (At present, only b-tree supports it.) +

Because of MVCC, it is always necessary to allow duplicate entries to + exist physically in an index: the entries might refer to successive + versions of a single logical row. The behavior we actually want to + enforce is that no MVCC snapshot could include two rows with equal + index keys. This breaks down into the following cases that must be + checked when inserting a new row into a unique index: + +

  • If a conflicting valid row has been deleted by the current transaction, + it's okay. (In particular, since an UPDATE always deletes the old row + version before inserting the new version, this will allow an UPDATE on + a row without changing the key.) +

  • If a conflicting row has been inserted by an as-yet-uncommitted + transaction, the would-be inserter must wait to see if that transaction + commits. If it rolls back then there is no conflict. If it commits + without deleting the conflicting row again, there is a uniqueness + violation. (In practice we just wait for the other transaction to + end and then redo the visibility check in toto.) +

  • Similarly, if a conflicting valid row has been deleted by an + as-yet-uncommitted transaction, the would-be inserter must wait + for that transaction to commit or abort, and then repeat the test. +

+

Furthermore, immediately before reporting a uniqueness violation + according to the above rules, the access method must recheck the + liveness of the row being inserted. If it is committed dead then + no violation should be reported. (This case cannot occur during the + ordinary scenario of inserting a row that's just been created by + the current transaction. It can happen during + CREATE UNIQUE INDEX CONCURRENTLY, however.) +

We require the index access method to apply these tests itself, which + means that it must reach into the heap to check the commit status of + any row that is shown to have a duplicate key according to the index + contents. This is without a doubt ugly and non-modular, but it saves + redundant work: if we did a separate probe then the index lookup for + a conflicting row would be essentially repeated while finding the place to + insert the new row's index entry. What's more, there is no obvious way + to avoid race conditions unless the conflict check is an integral part + of insertion of the new index entry. +

If the unique constraint is deferrable, there is additional complexity: + we need to be able to insert an index entry for a new row, but defer any + uniqueness-violation error until end of statement or even later. To + avoid unnecessary repeat searches of the index, the index access method + should do a preliminary uniqueness check during the initial insertion. + If this shows that there is definitely no conflicting live tuple, we + are done. Otherwise, we schedule a recheck to occur when it is time to + enforce the constraint. If, at the time of the recheck, both the inserted + tuple and some other tuple with the same key are live, then the error + must be reported. (Note that for this purpose, "live" actually + means "any tuple in the index entry's HOT chain is live".) + To implement this, the aminsert function is passed a + checkUnique parameter having one of the following values: + +

  • UNIQUE_CHECK_NO indicates that no uniqueness checking + should be done (this is not a unique index). +

  • UNIQUE_CHECK_YES indicates that this is a non-deferrable + unique index, and the uniqueness check must be done immediately, as + described above. +

  • UNIQUE_CHECK_PARTIAL indicates that the unique + constraint is deferrable. PostgreSQL + will use this mode to insert each row's index entry. The access + method must allow duplicate entries into the index, and report any + potential duplicates by returning FALSE from aminsert. + For each row for which FALSE is returned, a deferred recheck will + be scheduled. +

    The access method must identify any rows which might violate the + unique constraint, but it is not an error for it to report false + positives. This allows the check to be done without waiting for other + transactions to finish; conflicts reported here are not treated as + errors and will be rechecked later, by which time they may no longer + be conflicts. +

  • UNIQUE_CHECK_EXISTING indicates that this is a deferred + recheck of a row that was reported as a potential uniqueness violation. + Although this is implemented by calling aminsert, the + access method must not insert a new index entry in this + case. The index entry is already present. Rather, the access method + must check to see if there is another live index entry. If so, and + if the target row is also still live, report error. +

    It is recommended that in a UNIQUE_CHECK_EXISTING call, + the access method further verify that the target row actually does + have an existing entry in the index, and report error if not. This + is a good idea because the index tuple values passed to + aminsert will have been recomputed. If the index + definition involves functions that are not really immutable, we + might be checking the wrong area of the index. Checking that the + target row is found in the recheck verifies that we are scanning + for the same tuple values as were used in the original insertion. +

+


PrevHomeNext
Index Locking ConsiderationsUpIndex Cost Estimation Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/index.html b/doc/src/sgml/html/index.html new file mode 100644 index 000000000..71cfd5dda --- /dev/null +++ b/doc/src/sgml/html/index.html @@ -0,0 +1,623 @@ + +PostgreSQL 9.2.2 Documentation

PostgreSQL 9.2.2 Documentation

The PostgreSQL Global Development Group

Copyright © 1996-2012 The PostgreSQL Global Development Group


Table of Contents
Preface
What is PostgreSQL?
A Brief History of PostgreSQL
Conventions
Further Information
Bug Reporting Guidelines
I. Tutorial
1. Getting Started
2. The SQL Language
3. Advanced Features
II. The SQL Language
4. SQL Syntax
5. Data Definition
6. Data Manipulation
7. Queries
8. Data Types
9. Functions and Operators
10. Type Conversion
11. Indexes
12. Full Text Search
13. Concurrency Control
14. Performance Tips
III. Server Administration
15. Installation from Source Code
16. Installation from Source Code on Windows
17. Server Setup and Operation
18. Server Configuration
19. Client Authentication
20. Database Roles
21. Managing Databases
22. Localization
23. Routine Database Maintenance Tasks
24. Backup and Restore
25. High Availability, Load Balancing, and Replication
26. Recovery Configuration
27. Monitoring Database Activity
28. Monitoring Disk Usage
29. Reliability and the Write-Ahead Log
30. Regression Tests
IV. Client Interfaces
31. libpq - C Library
32. Large Objects
33. ECPG - Embedded SQL in C
34. The Information Schema
V. Server Programming
35. Extending SQL
36. Triggers
37. The Rule System
38. Procedural Languages
39. PL/pgSQL - SQL Procedural Language
40. PL/Tcl - Tcl Procedural Language
41. PL/Perl - Perl Procedural Language
42. PL/Python - Python Procedural Language
43. Server Programming Interface
VI. Reference
I. SQL Commands
II. PostgreSQL Client Applications
III. PostgreSQL Server Applications
VII. Internals
44. Overview of PostgreSQL Internals
45. System Catalogs
46. Frontend/Backend Protocol
47. PostgreSQL Coding Conventions
48. Native Language Support
49. Writing A Procedural Language Handler
50. Writing A Foreign Data Wrapper
51. Genetic Query Optimizer
52. Index Access Method Interface Definition
53. GiST Indexes
54. SP-GiST Indexes
55. GIN Indexes
56. Database Physical Storage
57. BKI Backend Interface
58. How the Planner Uses Statistics
VIII. Appendixes
A. PostgreSQL Error Codes
B. Date/Time Support
C. SQL Key Words
D. SQL Conformance
E. Release Notes
F. Additional Supplied Modules
G. Additional Supplied Programs
H. External Projects
I. The Source Code Repository
J. Documentation
K. Acronyms
Bibliography
Index

  Next
  Preface
\ No newline at end of file diff --git a/doc/src/sgml/html/indexam.html b/doc/src/sgml/html/indexam.html new file mode 100644 index 000000000..48a680773 --- /dev/null +++ b/doc/src/sgml/html/indexam.html @@ -0,0 +1,266 @@ + +Index Access Method Interface Definition

Chapter 52. Index Access Method Interface Definition

This chapter defines the interface between the core + PostgreSQL system and index access + methods, which manage individual index types. The core system + knows nothing about indexes beyond what is specified here, so it is + possible to develop entirely new index types by writing add-on code. +

All indexes in PostgreSQL are what are known + technically as secondary indexes; that is, the index is + physically separate from the table file that it describes. Each index + is stored as its own physical relation and so is described + by an entry in the pg_class catalog. The contents of an + index are entirely under the control of its index access method. In + practice, all index access methods divide indexes into standard-size + pages so that they can use the regular storage manager and buffer manager + to access the index contents. (All the existing index access methods + furthermore use the standard page layout described in Section 56.6, and they all use the same format for index + tuple headers; but these decisions are not forced on an access method.) +

An index is effectively a mapping from some data key values to + tuple identifiers, or TIDs, of row versions + (tuples) in the index's parent table. A TID consists of a + block number and an item number within that block (see Section 56.6). This is sufficient + information to fetch a particular row version from the table. + Indexes are not directly aware that under MVCC, there might be multiple + extant versions of the same logical row; to an index, each tuple is + an independent object that needs its own index entry. Thus, an + update of a row always creates all-new index entries for the row, even if + the key values did not change. (HOT tuples are an exception to this + statement; but indexes do not deal with those, either.) Index entries for + dead tuples are reclaimed (by vacuuming) when the dead tuples themselves + are reclaimed. +


PrevHomeNext
Further ReadingUpCatalog Entries for Indexes
\ No newline at end of file diff --git a/doc/src/sgml/html/indexes-bitmap-scans.html b/doc/src/sgml/html/indexes-bitmap-scans.html new file mode 100644 index 000000000..f49215260 --- /dev/null +++ b/doc/src/sgml/html/indexes-bitmap-scans.html @@ -0,0 +1,301 @@ + +Combining Multiple Indexes

11.5. Combining Multiple Indexes

A single index scan can only use query clauses that use the index's + columns with operators of its operator class and are joined with + AND. For example, given an index on (a, b) + a query condition like WHERE a = 5 AND b = 6 could + use the index, but a query like WHERE a = 5 OR b = 6 could not + directly use the index. +

Fortunately, + PostgreSQL has the ability to combine multiple indexes + (including multiple uses of the same index) to handle cases that cannot + be implemented by single index scans. The system can form AND + and OR conditions across several index scans. For example, + a query like WHERE x = 42 OR x = 47 OR x = 53 OR x = 99 + could be broken down into four separate scans of an index on x, + each scan using one of the query clauses. The results of these scans are + then ORed together to produce the result. Another example is that if we + have separate indexes on x and y, one possible + implementation of a query like WHERE x = 5 AND y = 6 is to + use each index with the appropriate query clause and then AND together + the index results to identify the result rows. +

To combine multiple indexes, the system scans each needed index and + prepares a bitmap in memory giving the locations of + table rows that are reported as matching that index's conditions. + The bitmaps are then ANDed and ORed together as needed by the query. + Finally, the actual table rows are visited and returned. The table rows + are visited in physical order, because that is how the bitmap is laid + out; this means that any ordering of the original indexes is lost, and + so a separate sort step will be needed if the query has an ORDER + BY clause. For this reason, and because each additional index scan + adds extra time, the planner will sometimes choose to use a simple index + scan even though additional indexes are available that could have been + used as well. +

In all but the simplest applications, there are various combinations of + indexes that might be useful, and the database developer must make + trade-offs to decide which indexes to provide. Sometimes multicolumn + indexes are best, but sometimes it's better to create separate indexes + and rely on the index-combination feature. For example, if your + workload includes a mix of queries that sometimes involve only column + x, sometimes only column y, and sometimes both + columns, you might choose to create two separate indexes on + x and y, relying on index combination to + process the queries that use both columns. You could also create a + multicolumn index on (x, y). This index would typically be + more efficient than index combination for queries involving both + columns, but as discussed in Section 11.3, it + would be almost useless for queries involving only y, so it + should not be the only index. A combination of the multicolumn index + and a separate index on y would serve reasonably well. For + queries involving only x, the multicolumn index could be + used, though it would be larger and hence slower than an index on + x alone. The last alternative is to create all three + indexes, but this is probably only reasonable if the table is searched + much more often than it is updated and all three types of query are + common. If one of the types of query is much less common than the + others, you'd probably settle for creating just the two indexes that + best match the common types. +


PrevHomeNext
Indexes and ORDER BYUpUnique Indexes
\ No newline at end of file diff --git a/doc/src/sgml/html/indexes-collations.html b/doc/src/sgml/html/indexes-collations.html new file mode 100644 index 000000000..248f30821 --- /dev/null +++ b/doc/src/sgml/html/indexes-collations.html @@ -0,0 +1,211 @@ + +Indexes and Collations

11.10. Indexes and Collations

An index can support only one collation per index column. + If multiple collations are of interest, multiple indexes may be needed. +

Consider these statements: +

CREATE TABLE test1c (
+    id integer,
+    content varchar COLLATE "x"
+);
+
+CREATE INDEX test1c_content_index ON test1c (content);

+ The index automatically uses the collation of the + underlying column. So a query of the form +

SELECT * FROM test1c WHERE content > constant;

+ could use the index, because the comparison will by default use the + collation of the column. However, this index cannot accelerate queries + that involve some other collation. So if queries of the form, say, +

SELECT * FROM test1c WHERE content > constant COLLATE "y";

+ are also of interest, an additional index could be created that supports + the "y" collation, like this: +

CREATE INDEX test1c_content_y_index ON test1c (content COLLATE "y");

+


PrevHomeNext
Operator Classes and Operator FamiliesUpExamining Index Usage
\ No newline at end of file diff --git a/doc/src/sgml/html/indexes-examine.html b/doc/src/sgml/html/indexes-examine.html new file mode 100644 index 000000000..f5996f63a --- /dev/null +++ b/doc/src/sgml/html/indexes-examine.html @@ -0,0 +1,312 @@ + +Examining Index Usage

11.11. Examining Index Usage

Although indexes in PostgreSQL do not need + maintenance or tuning, it is still important to check + which indexes are actually used by the real-life query workload. + Examining index usage for an individual query is done with the + EXPLAIN + command; its application for this purpose is + illustrated in Section 14.1. + It is also possible to gather overall statistics about index usage + in a running server, as described in Section 27.2. +

It is difficult to formulate a general procedure for determining + which indexes to create. There are a number of typical cases that + have been shown in the examples throughout the previous sections. + A good deal of experimentation is often necessary. + The rest of this section gives some tips for that: +

  • Always run ANALYZE + first. This command + collects statistics about the distribution of the values in the + table. This information is required to estimate the number of rows + returned by a query, which is needed by the planner to assign + realistic costs to each possible query plan. In absence of any + real statistics, some default values are assumed, which are + almost certain to be inaccurate. Examining an application's + index usage without having run ANALYZE is + therefore a lost cause. + See Section 23.1.3 + and Section 23.1.6 for more information. +

  • Use real data for experimentation. Using test data for setting + up indexes will tell you what indexes you need for the test data, + but that is all. +

    It is especially fatal to use very small test data sets. + While selecting 1000 out of 100000 rows could be a candidate for + an index, selecting 1 out of 100 rows will hardly be, because the + 100 rows probably fit within a single disk page, and there + is no plan that can beat sequentially fetching 1 disk page. +

    Also be careful when making up test data, which is often + unavoidable when the application is not yet in production. + Values that are very similar, completely random, or inserted in + sorted order will skew the statistics away from the distribution + that real data would have. +

  • When indexes are not used, it can be useful for testing to force + their use. There are run-time parameters that can turn off + various plan types (see Section 18.7.1). + For instance, turning off sequential scans + (enable_seqscan) and nested-loop joins + (enable_nestloop), which are the most basic plans, + will force the system to use a different plan. If the system + still chooses a sequential scan or nested-loop join then there is + probably a more fundamental reason why the index is not being + used; for example, the query condition does not match the index. + (What kind of query can use what kind of index is explained in + the previous sections.) +

  • If forcing index usage does use the index, then there are two + possibilities: Either the system is right and using the index is + indeed not appropriate, or the cost estimates of the query plans + are not reflecting reality. So you should time your query with + and without indexes. The EXPLAIN ANALYZE + command can be useful here. +

  • If it turns out that the cost estimates are wrong, there are, + again, two possibilities. The total cost is computed from the + per-row costs of each plan node times the selectivity estimate of + the plan node. The costs estimated for the plan nodes can be adjusted + via run-time parameters (described in Section 18.7.2). + An inaccurate selectivity estimate is due to + insufficient statistics. It might be possible to improve this by + tuning the statistics-gathering parameters (see + ALTER TABLE). +

    If you do not succeed in adjusting the costs to be more + appropriate, then you might have to resort to forcing index usage + explicitly. You might also want to contact the + PostgreSQL developers to examine the issue. +


PrevHomeNext
Indexes and CollationsUpFull Text Search
\ No newline at end of file diff --git a/doc/src/sgml/html/indexes-expressional.html b/doc/src/sgml/html/indexes-expressional.html new file mode 100644 index 000000000..a885ec9da --- /dev/null +++ b/doc/src/sgml/html/indexes-expressional.html @@ -0,0 +1,247 @@ + +Indexes on Expressions

11.7. Indexes on Expressions

An index column need not be just a column of the underlying table, + but can be a function or scalar expression computed from one or + more columns of the table. This feature is useful to obtain fast + access to tables based on the results of computations. +

For example, a common way to do case-insensitive comparisons is to + use the lower function: +

SELECT * FROM test1 WHERE lower(col1) = 'value';

+ This query can use an index if one has been + defined on the result of the lower(col1) + function: +

CREATE INDEX test1_lower_col1_idx ON test1 (lower(col1));

+

If we were to declare this index UNIQUE, it would prevent + creation of rows whose col1 values differ only in case, + as well as rows whose col1 values are actually identical. + Thus, indexes on expressions can be used to enforce constraints that + are not definable as simple unique constraints. +

As another example, if one often does queries like: +

SELECT * FROM people WHERE (first_name || ' ' || last_name) = 'John Smith';

+ then it might be worth creating an index like this: +

CREATE INDEX people_names ON people ((first_name || ' ' || last_name));

+

The syntax of the CREATE INDEX command normally requires + writing parentheses around index expressions, as shown in the second + example. The parentheses can be omitted when the expression is just + a function call, as in the first example. +

Index expressions are relatively expensive to maintain, because the + derived expression(s) must be computed for each row upon insertion + and whenever it is updated. However, the index expressions are + not recomputed during an indexed search, since they are + already stored in the index. In both examples above, the system + sees the query as just WHERE indexedcolumn = 'constant' + and so the speed of the search is equivalent to any other simple index + query. Thus, indexes on expressions are useful when retrieval speed + is more important than insertion and update speed. +


PrevHomeNext
Unique IndexesUpPartial Indexes
\ No newline at end of file diff --git a/doc/src/sgml/html/indexes-intro.html b/doc/src/sgml/html/indexes-intro.html new file mode 100644 index 000000000..d13d0d8fc --- /dev/null +++ b/doc/src/sgml/html/indexes-intro.html @@ -0,0 +1,308 @@ + +Introduction

11.1. Introduction

Suppose we have a table similar to this: +

CREATE TABLE test1 (
+    id integer,
+    content varchar
+);

+ and the application issues many queries of the form: +

SELECT content FROM test1 WHERE id = constant;

+ With no advance preparation, the system would have to scan the entire + test1 table, row by row, to find all + matching entries. If there are many rows in + test1 and only a few rows (perhaps zero + or one) that would be returned by such a query, this is clearly an + inefficient method. But if the system has been instructed to maintain an + index on the id column, it can use a more + efficient method for locating matching rows. For instance, it + might only have to walk a few levels deep into a search tree. +

A similar approach is used in most non-fiction books: terms and + concepts that are frequently looked up by readers are collected in + an alphabetic index at the end of the book. The interested reader + can scan the index relatively quickly and flip to the appropriate + page(s), rather than having to read the entire book to find the + material of interest. Just as it is the task of the author to + anticipate the items that readers are likely to look up, + it is the task of the database programmer to foresee which indexes + will be useful. +

The following command can be used to create an index on the + id column, as discussed: +

CREATE INDEX test1_id_index ON test1 (id);

+ The name test1_id_index can be chosen + freely, but you should pick something that enables you to remember + later what the index was for. +

To remove an index, use the DROP INDEX command. + Indexes can be added to and removed from tables at any time. +

Once an index is created, no further intervention is required: the + system will update the index when the table is modified, and it will + use the index in queries when it thinks doing so would be more efficient + than a sequential table scan. But you might have to run the + ANALYZE command regularly to update + statistics to allow the query planner to make educated decisions. + See Chapter 14 for information about + how to find out whether an index is used and when and why the + planner might choose not to use an index. +

Indexes can also benefit UPDATE and + DELETE commands with search conditions. + Indexes can moreover be used in join searches. Thus, + an index defined on a column that is part of a join condition can + also significantly speed up queries with joins. +

Creating an index on a large table can take a long time. By default, + PostgreSQL allows reads (SELECT statements) to occur + on the table in parallel with index creation, but writes (INSERT, + UPDATE, DELETE) are blocked until the index build is finished. + In production environments this is often unacceptable. + It is possible to allow writes to occur in parallel with index + creation, but there are several caveats to be aware of — + for more information see Building Indexes Concurrently. +

After an index is created, the system has to keep it synchronized with the + table. This adds overhead to data manipulation operations. + Therefore indexes that are seldom or never used in queries + should be removed. +


PrevHomeNext
IndexesUpIndex Types
\ No newline at end of file diff --git a/doc/src/sgml/html/indexes-multicolumn.html b/doc/src/sgml/html/indexes-multicolumn.html new file mode 100644 index 000000000..d1a3bc5db --- /dev/null +++ b/doc/src/sgml/html/indexes-multicolumn.html @@ -0,0 +1,300 @@ + +Multicolumn Indexes

11.3. Multicolumn Indexes

An index can be defined on more than one column of a table. For example, if + you have a table of this form: +

CREATE TABLE test2 (
+  major int,
+  minor int,
+  name varchar
+);

+ (say, you keep your /dev + directory in a database...) and you frequently issue queries like: +

SELECT name FROM test2 WHERE major = constant AND minor = constant;

+ then it might be appropriate to define an index on the columns + major and + minor together, e.g.: +

CREATE INDEX test2_mm_idx ON test2 (major, minor);

+

Currently, only the B-tree, GiST and GIN index types support multicolumn + indexes. Up to 32 columns can be specified. (This limit can be + altered when building PostgreSQL; see the + file pg_config_manual.h.) +

A multicolumn B-tree index can be used with query conditions that + involve any subset of the index's columns, but the index is most + efficient when there are constraints on the leading (leftmost) columns. + The exact rule is that equality constraints on leading columns, plus + any inequality constraints on the first column that does not have an + equality constraint, will be used to limit the portion of the index + that is scanned. Constraints on columns to the right of these columns + are checked in the index, so they save visits to the table proper, but + they do not reduce the portion of the index that has to be scanned. + For example, given an index on (a, b, c) and a + query condition WHERE a = 5 AND b >= 42 AND c < 77, + the index would have to be scanned from the first entry with + a = 5 and b = 42 up through the last entry with + a = 5. Index entries with c >= 77 would be + skipped, but they'd still have to be scanned through. + This index could in principle be used for queries that have constraints + on b and/or c with no constraint on a + — but the entire index would have to be scanned, so in most cases + the planner would prefer a sequential table scan over using the index. +

A multicolumn GiST index can be used with query conditions that + involve any subset of the index's columns. Conditions on additional + columns restrict the entries returned by the index, but the condition on + the first column is the most important one for determining how much of + the index needs to be scanned. A GiST index will be relatively + ineffective if its first column has only a few distinct values, even if + there are many distinct values in additional columns. +

A multicolumn GIN index can be used with query conditions that + involve any subset of the index's columns. Unlike B-tree or GiST, + index search effectiveness is the same regardless of which index column(s) + the query conditions use. +

Of course, each column must be used with operators appropriate to the index + type; clauses that involve other operators will not be considered. +

Multicolumn indexes should be used sparingly. In most situations, + an index on a single column is sufficient and saves space and time. + Indexes with more than three columns are unlikely to be helpful + unless the usage of the table is extremely stylized. See also + Section 11.5 for some discussion of the + merits of different index configurations. +


PrevHomeNext
Index TypesUpIndexes and ORDER BY
\ No newline at end of file diff --git a/doc/src/sgml/html/indexes-opclass.html b/doc/src/sgml/html/indexes-opclass.html new file mode 100644 index 000000000..0e6c9c479 --- /dev/null +++ b/doc/src/sgml/html/indexes-opclass.html @@ -0,0 +1,379 @@ + +Operator Classes and Operator Families

11.9. Operator Classes and Operator Families

An index definition can specify an operator + class for each column of an index. +

CREATE INDEX name ON table (column opclass [sort options] [, ...]);

+ The operator class identifies the operators to be used by the index + for that column. For example, a B-tree index on the type int4 + would use the int4_ops class; this operator + class includes comparison functions for values of type int4. + In practice the default operator class for the column's data type is + usually sufficient. The main reason for having operator classes is + that for some data types, there could be more than one meaningful + index behavior. For example, we might want to sort a complex-number data + type either by absolute value or by real part. We could do this by + defining two operator classes for the data type and then selecting + the proper class when making an index. The operator class determines + the basic sort ordering (which can then be modified by adding sort options + COLLATE, + ASC/DESC and/or + NULLS FIRST/NULLS LAST). +

There are also some built-in operator classes besides the default ones: + +

  • The operator classes text_pattern_ops, + varchar_pattern_ops, and + bpchar_pattern_ops support B-tree indexes on + the types text, varchar, and + char respectively. The + difference from the default operator classes is that the values + are compared strictly character by character rather than + according to the locale-specific collation rules. This makes + these operator classes suitable for use by queries involving + pattern matching expressions (LIKE or POSIX + regular expressions) when the database does not use the standard + "C" locale. As an example, you might index a + varchar column like this: +

    CREATE INDEX test_index ON test_table (col varchar_pattern_ops);

    + Note that you should also create an index with the default operator + class if you want queries involving ordinary <, + <=, >, or >= comparisons + to use an index. Such queries cannot use the + xxx_pattern_ops + operator classes. (Ordinary equality comparisons can use these + operator classes, however.) It is possible to create multiple + indexes on the same column with different operator classes. + If you do use the C locale, you do not need the + xxx_pattern_ops + operator classes, because an index with the default operator class + is usable for pattern-matching queries in the C locale. +

+

The following query shows all defined operator classes: + +

SELECT am.amname AS index_method,
+       opc.opcname AS opclass_name
+    FROM pg_am am, pg_opclass opc
+    WHERE opc.opcmethod = am.oid
+    ORDER BY index_method, opclass_name;

+

An operator class is actually just a subset of a larger structure called an + operator family. In cases where several data types have + similar behaviors, it is frequently useful to define cross-data-type + operators and allow these to work with indexes. To do this, the operator + classes for each of the types must be grouped into the same operator + family. The cross-type operators are members of the family, but are not + associated with any single class within the family. +

This query shows all defined operator families and all + the operators included in each family: +

SELECT am.amname AS index_method,
+       opf.opfname AS opfamily_name,
+       amop.amopopr::regoperator AS opfamily_operator
+    FROM pg_am am, pg_opfamily opf, pg_amop amop
+    WHERE opf.opfmethod = am.oid AND
+          amop.amopfamily = opf.oid
+    ORDER BY index_method, opfamily_name, opfamily_operator;

+


PrevHomeNext
Partial IndexesUpIndexes and Collations
\ No newline at end of file diff --git a/doc/src/sgml/html/indexes-ordering.html b/doc/src/sgml/html/indexes-ordering.html new file mode 100644 index 000000000..aea386ad0 --- /dev/null +++ b/doc/src/sgml/html/indexes-ordering.html @@ -0,0 +1,327 @@ + +Indexes and ORDER BY

11.4. Indexes and ORDER BY

In addition to simply finding the rows to be returned by a query, + an index may be able to deliver them in a specific sorted order. + This allows a query's ORDER BY specification to be honored + without a separate sorting step. Of the index types currently + supported by PostgreSQL, only B-tree + can produce sorted output — the other index types return + matching rows in an unspecified, implementation-dependent order. +

The planner will consider satisfying an ORDER BY specification + either by scanning an available index that matches the specification, + or by scanning the table in physical order and doing an explicit + sort. For a query that requires scanning a large fraction of the + table, an explicit sort is likely to be faster than using an index + because it requires + less disk I/O due to following a sequential access pattern. Indexes are + more useful when only a few rows need be fetched. An important + special case is ORDER BY in combination with + LIMIT n: an explicit sort will have to process + all the data to identify the first n rows, but if there is + an index matching the ORDER BY, the first n + rows can be retrieved directly, without scanning the remainder at all. +

By default, B-tree indexes store their entries in ascending order + with nulls last. This means that a forward scan of an index on + column x produces output satisfying ORDER BY x + (or more verbosely, ORDER BY x ASC NULLS LAST). The + index can also be scanned backward, producing output satisfying + ORDER BY x DESC + (or more verbosely, ORDER BY x DESC NULLS FIRST, since + NULLS FIRST is the default for ORDER BY DESC). +

You can adjust the ordering of a B-tree index by including the + options ASC, DESC, NULLS FIRST, + and/or NULLS LAST when creating the index; for example: +

CREATE INDEX test2_info_nulls_low ON test2 (info NULLS FIRST);
+CREATE INDEX test3_desc_index ON test3 (id DESC NULLS LAST);

+ An index stored in ascending order with nulls first can satisfy + either ORDER BY x ASC NULLS FIRST or + ORDER BY x DESC NULLS LAST depending on which direction + it is scanned in. +

You might wonder why bother providing all four options, when two + options together with the possibility of backward scan would cover + all the variants of ORDER BY. In single-column indexes + the options are indeed redundant, but in multicolumn indexes they can be + useful. Consider a two-column index on (x, y): this can + satisfy ORDER BY x, y if we scan forward, or + ORDER BY x DESC, y DESC if we scan backward. + But it might be that the application frequently needs to use + ORDER BY x ASC, y DESC. There is no way to get that + ordering from a plain index, but it is possible if the index is defined + as (x ASC, y DESC) or (x DESC, y ASC). +

Obviously, indexes with non-default sort orderings are a fairly + specialized feature, but sometimes they can produce tremendous + speedups for certain queries. Whether it's worth maintaining such an + index depends on how often you use queries that require a special + sort ordering. +


PrevHomeNext
Multicolumn IndexesUpCombining Multiple Indexes
\ No newline at end of file diff --git a/doc/src/sgml/html/indexes-partial.html b/doc/src/sgml/html/indexes-partial.html new file mode 100644 index 000000000..0427034aa --- /dev/null +++ b/doc/src/sgml/html/indexes-partial.html @@ -0,0 +1,479 @@ + +Partial Indexes

11.8. Partial Indexes

A partial index is an index built over a + subset of a table; the subset is defined by a conditional + expression (called the predicate of the + partial index). The index contains entries only for those table + rows that satisfy the predicate. Partial indexes are a specialized + feature, but there are several situations in which they are useful. +

One major reason for using a partial index is to avoid indexing common + values. Since a query searching for a common value (one that + accounts for more than a few percent of all the table rows) will not + use the index anyway, there is no point in keeping those rows in the + index at all. This reduces the size of the index, which will speed + up those queries that do use the index. It will also speed up many table + update operations because the index does not need to be + updated in all cases. Example 11-1 shows a + possible application of this idea. +

Example 11-1. Setting up a Partial Index to Exclude Common Values

Suppose you are storing web server access logs in a database. + Most accesses originate from the IP address range of your organization but + some are from elsewhere (say, employees on dial-up connections). + If your searches by IP are primarily for outside accesses, + you probably do not need to index the IP range that corresponds to your + organization's subnet. +

Assume a table like this: +

CREATE TABLE access_log (
+    url varchar,
+    client_ip inet,
+    ...
+);

+

To create a partial index that suits our example, use a command + such as this: +

CREATE INDEX access_log_client_ip_ix ON access_log (client_ip)
+WHERE NOT (client_ip > inet '192.168.100.0' AND
+           client_ip < inet '192.168.100.255');

+

A typical query that can use this index would be: +

SELECT *
+FROM access_log
+WHERE url = '/index.html' AND client_ip = inet '212.78.10.32';

+ A query that cannot use this index is: +

SELECT *
+FROM access_log
+WHERE client_ip = inet '192.168.100.23';

+

Observe that this kind of partial index requires that the common + values be predetermined, so such partial indexes are best used for + data distributions that do not change. The indexes can be recreated + occasionally to adjust for new data distributions, but this adds + maintenance effort. +

Another possible use for a partial index is to exclude values from the + index that the + typical query workload is not interested in; this is shown in Example 11-2. This results in the same + advantages as listed above, but it prevents the + "uninteresting" values from being accessed via that + index, even if an index scan might be profitable in that + case. Obviously, setting up partial indexes for this kind of + scenario will require a lot of care and experimentation. +

Example 11-2. Setting up a Partial Index to Exclude Uninteresting Values

If you have a table that contains both billed and unbilled orders, + where the unbilled orders take up a small fraction of the total + table and yet those are the most-accessed rows, you can improve + performance by creating an index on just the unbilled rows. The + command to create the index would look like this: +

CREATE INDEX orders_unbilled_index ON orders (order_nr)
+    WHERE billed is not true;

+

A possible query to use this index would be: +

SELECT * FROM orders WHERE billed is not true AND order_nr < 10000;

+ However, the index can also be used in queries that do not involve + order_nr at all, e.g.: +

SELECT * FROM orders WHERE billed is not true AND amount > 5000.00;

+ This is not as efficient as a partial index on the + amount column would be, since the system has to + scan the entire index. Yet, if there are relatively few unbilled + orders, using this partial index just to find the unbilled orders + could be a win. +

Note that this query cannot use this index: +

SELECT * FROM orders WHERE order_nr = 3501;

+ The order 3501 might be among the billed or unbilled + orders. +

Example 11-2 also illustrates that the + indexed column and the column used in the predicate do not need to + match. PostgreSQL supports partial + indexes with arbitrary predicates, so long as only columns of the + table being indexed are involved. However, keep in mind that the + predicate must match the conditions used in the queries that + are supposed to benefit from the index. To be precise, a partial + index can be used in a query only if the system can recognize that + the WHERE condition of the query mathematically implies + the predicate of the index. + PostgreSQL does not have a sophisticated + theorem prover that can recognize mathematically equivalent + expressions that are written in different forms. (Not + only is such a general theorem prover extremely difficult to + create, it would probably be too slow to be of any real use.) + The system can recognize simple inequality implications, for example + "x < 1" implies "x < 2"; otherwise + the predicate condition must exactly match part of the query's + WHERE condition + or the index will not be recognized as usable. Matching takes + place at query planning time, not at run time. As a result, + parameterized query clauses do not work with a partial index. For + example a prepared query with a parameter might specify + "x < ?" which will never imply + "x < 2" for all possible values of the parameter. +

A third possible use for partial indexes does not require the + index to be used in queries at all. The idea here is to create + a unique index over a subset of a table, as in Example 11-3. This enforces uniqueness + among the rows that satisfy the index predicate, without constraining + those that do not. +

Example 11-3. Setting up a Partial Unique Index

Suppose that we have a table describing test outcomes. We wish + to ensure that there is only one "successful" entry for + a given subject and target combination, but there might be any number of + "unsuccessful" entries. Here is one way to do it: +

CREATE TABLE tests (
+    subject text,
+    target text,
+    success boolean,
+    ...
+);
+
+CREATE UNIQUE INDEX tests_success_constraint ON tests (subject, target)
+    WHERE success;

+ This is a particularly efficient approach when there are few + successful tests and many unsuccessful ones. +

Finally, a partial index can also be used to override the system's + query plan choices. Also, data sets with peculiar + distributions might cause the system to use an index when it really + should not. In that case the index can be set up so that it is not + available for the offending query. Normally, + PostgreSQL makes reasonable choices about index + usage (e.g., it avoids them when retrieving common values, so the + earlier example really only saves index size, it is not required to + avoid index usage), and grossly incorrect plan choices are cause + for a bug report. +

Keep in mind that setting up a partial index indicates that you + know at least as much as the query planner knows, in particular you + know when an index might be profitable. Forming this knowledge + requires experience and understanding of how indexes in + PostgreSQL work. In most cases, the advantage of a + partial index over a regular index will be minimal. +

More information about partial indexes can be found in The case for partial indexes + , Partial indexing in POSTGRES: research project, and Generalized Partial Indexes + (cached version) + . +


PrevHomeNext
Indexes on ExpressionsUpOperator Classes and Operator Families
\ No newline at end of file diff --git a/doc/src/sgml/html/indexes-types.html b/doc/src/sgml/html/indexes-types.html new file mode 100644 index 000000000..9d8ce0679 --- /dev/null +++ b/doc/src/sgml/html/indexes-types.html @@ -0,0 +1,654 @@ + +Index Types

11.2. Index Types

PostgreSQL provides several index types: + B-tree, Hash, GiST, SP-GiST and GIN. Each index type uses a different + algorithm that is best suited to different types of queries. + By default, the CREATE INDEX command creates + B-tree indexes, which fit the most common situations. +

+ + B-trees can handle equality and range queries on data that can be sorted + into some ordering. + In particular, the PostgreSQL query planner + will consider using a B-tree index whenever an indexed column is + involved in a comparison using one of these operators: + +

<
<=
=
>=
>

+ + Constructs equivalent to combinations of these operators, such as + BETWEEN and IN, can also be implemented with + a B-tree index search. Also, an IS NULL or IS NOT + NULL condition on an index column can be used with a B-tree index. +

The optimizer can also use a B-tree index for queries involving the + pattern matching operators LIKE and ~ + if the pattern is a constant and is anchored to + the beginning of the string — for example, col LIKE + 'foo%' or col ~ '^foo', but not + col LIKE '%bar'. However, if your database does not + use the C locale you will need to create the index with a special + operator class to support indexing of pattern-matching queries; see + Section 11.9 below. It is also possible to use + B-tree indexes for ILIKE and + ~*, but only if the pattern starts with + non-alphabetic characters, i.e., characters that are not affected by + upper/lower case conversion. +

B-tree indexes can also be used to retrieve data in sorted order. + This is not always faster than a simple scan and sort, but it is + often helpful. +

+ + Hash indexes can only handle simple equality comparisons. + The query planner will consider using a hash index whenever an + indexed column is involved in a comparison using the + = operator. + The following command is used to create a hash index: +

CREATE INDEX name ON table USING hash (column);

+

Caution

Hash index operations are not presently WAL-logged, + so hash indexes might need to be rebuilt with REINDEX + after a database crash if there were unwritten changes. + Also, changes to hash indexes are not replicated over streaming or + file-based replication after the initial base backup, so they + give wrong answers to queries that subsequently use them. + For these reasons, hash index use is presently discouraged. +

+ + GiST indexes are not a single kind of index, but rather an infrastructure + within which many different indexing strategies can be implemented. + Accordingly, the particular operators with which a GiST index can be + used vary depending on the indexing strategy (the operator + class). As an example, the standard distribution of + PostgreSQL includes GiST operator classes + for several two-dimensional geometric data types, which support indexed + queries using these operators: + +

<<
&<
&>
>>
<<|
&<|
|&>
|>>
@>
<@
~=
&&

+ + (See Section 9.11 for the meaning of + these operators.) + Many other GiST operator + classes are available in the contrib collection or as separate + projects. For more information see Chapter 53. +

GiST indexes are also capable of optimizing "nearest-neighbor" + searches, such as +

SELECT * FROM places ORDER BY location <-> point '(101,456)' LIMIT 10;

+ which finds the ten places closest to a given target point. The ability + to do this is again dependent on the particular operator class being used. +

+ + SP-GiST indexes, like GiST indexes, offer an infrastructure that supports + various kinds of searches. SP-GiST permits implementation of a wide range + of different non-balanced disk-based data structures, such as quadtrees, + k-d trees, and suffix trees (tries). As an example, the standard distribution of + PostgreSQL includes SP-GiST operator classes + for two-dimensional points, which support indexed + queries using these operators: + +

<<
>>
~=
<@
<^
>^

+ + (See Section 9.11 for the meaning of + these operators.) + For more information see Chapter 54. +

+ + GIN indexes are inverted indexes which can handle values that contain more + than one key, arrays for example. Like GiST and SP-GiST, GIN can support + many different user-defined indexing strategies and the particular + operators with which a GIN index can be used vary depending on the + indexing strategy. + As an example, the standard distribution of + PostgreSQL includes GIN operator classes + for one-dimensional arrays, which support indexed + queries using these operators: + +

<@
@>
=
&&

+ + (See Section 9.18 for the meaning of + these operators.) + Many other GIN operator + classes are available in the contrib collection or as separate + projects. For more information see Chapter 55. +


PrevHomeNext
IntroductionUpMulticolumn Indexes
\ No newline at end of file diff --git a/doc/src/sgml/html/indexes-unique.html b/doc/src/sgml/html/indexes-unique.html new file mode 100644 index 000000000..146893742 --- /dev/null +++ b/doc/src/sgml/html/indexes-unique.html @@ -0,0 +1,226 @@ + +Unique Indexes

11.6. Unique Indexes

Indexes can also be used to enforce uniqueness of a column's value, + or the uniqueness of the combined values of more than one column. +

CREATE UNIQUE INDEX name ON table (column [, ...]);

+ Currently, only B-tree indexes can be declared unique. +

When an index is declared unique, multiple table rows with equal + indexed values are not allowed. Null values are not considered + equal. A multicolumn unique index will only reject cases where all + indexed columns are equal in multiple rows. +

PostgreSQL automatically creates a unique + index when a unique constraint or primary key is defined for a table. + The index covers the columns that make up the primary key or unique + constraint (a multicolumn index, if appropriate), and is the mechanism + that enforces the constraint. +

Note: The preferred way to add a unique constraint to a table is + ALTER TABLE ... ADD CONSTRAINT. The use of + indexes to enforce unique constraints could be considered an + implementation detail that should not be accessed directly. + One should, however, be aware that there's no need to manually + create indexes on unique columns; doing so would just duplicate + the automatically-created index. +


PrevHomeNext
Combining Multiple IndexesUpIndexes on Expressions
\ No newline at end of file diff --git a/doc/src/sgml/html/indexes.html b/doc/src/sgml/html/indexes.html new file mode 100644 index 000000000..293bcd850 --- /dev/null +++ b/doc/src/sgml/html/indexes.html @@ -0,0 +1,242 @@ + +Indexes

Chapter 11. Indexes

Indexes are a common way to enhance database performance. An index + allows the database server to find and retrieve specific rows much + faster than it could do without an index. But indexes also add + overhead to the database system as a whole, so they should be used + sensibly. +


PrevHomeNext
UNION, CASE, and Related ConstructsUpIntroduction
\ No newline at end of file diff --git a/doc/src/sgml/html/information-schema.html b/doc/src/sgml/html/information-schema.html new file mode 100644 index 000000000..6ae9037a5 --- /dev/null +++ b/doc/src/sgml/html/information-schema.html @@ -0,0 +1,745 @@ + +The Information Schema

Chapter 34. The Information Schema

Table of Contents
34.1. The Schema
34.2. Data Types
34.3. information_schema_catalog_name
34.4. administrable_role_authorizations
34.5. applicable_roles
34.6. attributes
34.7. character_sets
34.8. check_constraint_routine_usage
34.9. check_constraints
34.10. collations
34.11. collation_character_set_applicability
34.12. column_domain_usage
34.13. column_options
34.14. column_privileges
34.15. column_udt_usage
34.16. columns
34.17. constraint_column_usage
34.18. constraint_table_usage
34.19. data_type_privileges
34.20. domain_constraints
34.21. domain_udt_usage
34.22. domains
34.23. element_types
34.24. enabled_roles
34.25. foreign_data_wrapper_options
34.26. foreign_data_wrappers
34.27. foreign_server_options
34.28. foreign_servers
34.29. foreign_table_options
34.30. foreign_tables
34.31. key_column_usage
34.32. parameters
34.33. referential_constraints
34.34. role_column_grants
34.35. role_routine_grants
34.36. role_table_grants
34.37. role_udt_grants
34.38. role_usage_grants
34.39. routine_privileges
34.40. routines
34.41. schemata
34.42. sequences
34.43. sql_features
34.44. sql_implementation_info
34.45. sql_languages
34.46. sql_packages
34.47. sql_parts
34.48. sql_sizing
34.49. sql_sizing_profiles
34.50. table_constraints
34.51. table_privileges
34.52. tables
34.53. triggered_update_columns
34.54. triggers
34.55. udt_privileges
34.56. usage_privileges
34.57. user_defined_types
34.58. user_mapping_options
34.59. user_mappings
34.60. view_column_usage
34.61. view_routine_usage
34.62. view_table_usage
34.63. views

The information schema consists of a set of views that contain + information about the objects defined in the current database. The + information schema is defined in the SQL standard and can therefore + be expected to be portable and remain stable — unlike the system + catalogs, which are specific to + PostgreSQL and are modelled after + implementation concerns. The information schema views do not, + however, contain information about + PostgreSQL-specific features; to inquire + about those you need to query the system catalogs or other + PostgreSQL-specific views. +

Note: When querying the database for constraint information, it is possible + for a standard-compliant query that expects to return one row to + return several. This is because the SQL standard requires constraint + names to be unique within a schema, but + PostgreSQL does not enforce this + restriction. PostgreSQL + automatically-generated constraint names avoid duplicates in the + same schema, but users can specify such duplicate names. +

This problem can appear when querying information schema views such + as check_constraint_routine_usage, + check_constraints, domain_constraints, and + referential_constraints. Some other views have similar + issues but contain the table name to help distinguish duplicate + rows, e.g., constraint_column_usage, + constraint_table_usage, table_constraints. +


PrevHomeNext
InternalsUpThe Schema
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-administrable-role-authorizations.html b/doc/src/sgml/html/infoschema-administrable-role-authorizations.html new file mode 100644 index 000000000..4ec0abb21 --- /dev/null +++ b/doc/src/sgml/html/infoschema-administrable-role-authorizations.html @@ -0,0 +1,257 @@ + +administrable_role_authorizations
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.4. administrable_role_authorizations

The view administrable_role_authorizations + identifies all roles that the current user has the admin option + for. +

Table 34-2. administrable_role_authorizations Columns

NameData TypeDescription
granteesql_identifier Name of the role to which this role membership was granted (can + be the current user, or a different role in case of nested role + memberships) +
role_namesql_identifierName of a role
is_grantableyes_or_noAlways YES

PrevHomeNext
information_schema_catalog_nameUpapplicable_roles
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-applicable-roles.html b/doc/src/sgml/html/infoschema-applicable-roles.html new file mode 100644 index 000000000..5baafafa4 --- /dev/null +++ b/doc/src/sgml/html/infoschema-applicable-roles.html @@ -0,0 +1,266 @@ + +applicable_roles
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.5. applicable_roles

The view applicable_roles identifies all roles + whose privileges the current user can use. This means there is + some chain of role grants from the current user to the role in + question. The current user itself is also an applicable role. The + set of applicable roles is generally used for permission checking. + + +

Table 34-3. applicable_roles Columns

NameData TypeDescription
granteesql_identifier Name of the role to which this role membership was granted (can + be the current user, or a different role in case of nested role + memberships) +
role_namesql_identifierName of a role
is_grantableyes_or_no YES if the grantee has the admin option on + the role, NO if not +

PrevHomeNext
administrable_role_authorizationsUpattributes
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-attributes.html b/doc/src/sgml/html/infoschema-attributes.html new file mode 100644 index 000000000..55c959d63 --- /dev/null +++ b/doc/src/sgml/html/infoschema-attributes.html @@ -0,0 +1,811 @@ + +attributes
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.6. attributes

The view attributes contains information about + the attributes of composite data types defined in the database. + (Note that the view does not give information about table columns, + which are sometimes called attributes in PostgreSQL contexts.) + Only those attributes are shown that the current user has access to (by way + of being the owner of or having some privilege on the type). +

Table 34-4. attributes Columns

NameData TypeDescription
udt_catalogsql_identifierName of the database containing the data type (always the current database)
udt_schemasql_identifierName of the schema containing the data type
udt_namesql_identifierName of the data type
attribute_namesql_identifierName of the attribute
ordinal_positioncardinal_numberOrdinal position of the attribute within the data type (count starts at 1)
attribute_defaultcharacter_dataDefault expression of the attribute
is_nullableyes_or_no YES if the attribute is possibly nullable, + NO if it is known not nullable. +
data_typecharacter_data Data type of the attribute, if it is a built-in type, or + ARRAY if it is some array (in that case, see + the view element_types), else + USER-DEFINED (in that case, the type is + identified in attribute_udt_name and + associated columns). +
character_maximum_lengthcardinal_number If data_type identifies a character or bit + string type, the declared maximum length; null for all other + data types or if no maximum length was declared. +
character_octet_lengthcardinal_number If data_type identifies a character type, + the maximum possible length in octets (bytes) of a datum; null + for all other data types. The maximum octet length depends on + the declared character maximum length (see above) and the + server encoding. +
character_set_catalogsql_identifierApplies to a feature not available in PostgreSQL
character_set_schemasql_identifierApplies to a feature not available in PostgreSQL
character_set_namesql_identifierApplies to a feature not available in PostgreSQL
collation_catalogsql_identifier Name of the database containing the collation of the attribute + (always the current database), null if default or the data type + of the attribute is not collatable +
collation_schemasql_identifier Name of the schema containing the collation of the attribute, + null if default or the data type of the attribute is not + collatable +
collation_namesql_identifier Name of the collation of the attribute, null if default or the + data type of the attribute is not collatable +
numeric_precisioncardinal_number If data_type identifies a numeric type, this + column contains the (declared or implicit) precision of the + type for this attribute. The precision indicates the number of + significant digits. It can be expressed in decimal (base 10) + or binary (base 2) terms, as specified in the column + numeric_precision_radix. For all other data + types, this column is null. +
numeric_precision_radixcardinal_number If data_type identifies a numeric type, this + column indicates in which base the values in the columns + numeric_precision and + numeric_scale are expressed. The value is + either 2 or 10. For all other data types, this column is null. +
numeric_scalecardinal_number If data_type identifies an exact numeric + type, this column contains the (declared or implicit) scale of + the type for this attribute. The scale indicates the number of + significant digits to the right of the decimal point. It can + be expressed in decimal (base 10) or binary (base 2) terms, as + specified in the column + numeric_precision_radix. For all other data + types, this column is null. +
datetime_precisioncardinal_number If data_type identifies a date, time, + timestamp, or interval type, this column contains the (declared + or implicit) fractional seconds precision of the type for this + attribute, that is, the number of decimal digits maintained + following the decimal point in the seconds value. For all + other data types, this column is null. +
interval_typecharacter_data If data_type identifies an interval type, + this column contains the specification which fields the + intervals include for this attribute, e.g., YEAR TO + MONTH, DAY TO SECOND, etc. If no + field restrictions were specified (that is, the interval + accepts all fields), and for all other data types, this field + is null. +
interval_precisioncardinal_number Applies to a feature not available + in PostgreSQL + (see datetime_precision for the fractional + seconds precision of interval type attributes) +
attribute_udt_catalogsql_identifier Name of the database that the attribute data type is defined in + (always the current database) +
attribute_udt_schemasql_identifier Name of the schema that the attribute data type is defined in +
attribute_udt_namesql_identifier Name of the attribute data type +
scope_catalogsql_identifierApplies to a feature not available in PostgreSQL
scope_schemasql_identifierApplies to a feature not available in PostgreSQL
scope_namesql_identifierApplies to a feature not available in PostgreSQL
maximum_cardinalitycardinal_numberAlways null, because arrays always have unlimited maximum cardinality in PostgreSQL
dtd_identifiersql_identifier An identifier of the data type descriptor of the column, unique + among the data type descriptors pertaining to the table. This + is mainly useful for joining with other instances of such + identifiers. (The specific format of the identifier is not + defined and not guaranteed to remain the same in future + versions.) +
is_derived_reference_attributeyes_or_noApplies to a feature not available in PostgreSQL

See also under Section 34.16, a similarly + structured view, for further information on some of the columns. +


PrevHomeNext
applicable_rolesUpcharacter_sets
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-character-sets.html b/doc/src/sgml/html/infoschema-character-sets.html new file mode 100644 index 000000000..ff1793dad --- /dev/null +++ b/doc/src/sgml/html/infoschema-character-sets.html @@ -0,0 +1,425 @@ + +character_sets
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.7. character_sets

The view character_sets identifies the character + sets available in the current database. Since PostgreSQL does not + support multiple character sets within one database, this view only + shows one, which is the database encoding. +

Take note of how the following terms are used in the SQL standard: +

character repertoire

An abstract collection of characters, for + example UNICODE, UCS, or + LATIN1. Not exposed as an SQL object, but + visible in this view. +

character encoding form

An encoding of some character repertoire. Most older character + repertoires only use one encoding form, and so there are no + separate names for them (e.g., LATIN1 is an + encoding form applicable to the LATIN1 + repertoire). But for example Unicode has the encoding forms + UTF8, UTF16, etc. (not + all supported by PostgreSQL). Encoding forms are not exposed + as an SQL object, but are visible in this view. +

character set

A named SQL object that identifies a character repertoire, a + character encoding, and a default collation. A predefined + character set would typically have the same name as an encoding + form, but users could define other names. For example, the + character set UTF8 would typically identify + the character repertoire UCS, encoding + form UTF8, and some default collation. +

+ + You can think of an "encoding" in PostgreSQL either as + a character set or a character encoding form. They will have the + same name, and there can only be one in one database. +

Table 34-5. character_sets Columns

NameData TypeDescription
character_set_catalogsql_identifierCharacter sets are currently not implemented as schema objects, so this column is null.
character_set_schemasql_identifierCharacter sets are currently not implemented as schema objects, so this column is null.
character_set_namesql_identifierName of the character set, currently implemented as showing the name of the database encoding
character_repertoiresql_identifierCharacter repertoire, showing UCS if the encoding is UTF8, else just the encoding name
form_of_usesql_identifierCharacter encoding form, same as the database encoding
default_collate_catalogsql_identifierName of the database containing the default collation (always the current database, if any collation is identified)
default_collate_schemasql_identifierName of the schema containing the default collation
default_collate_namesql_identifier Name of the default collation. The default collation is + identified as the collation that matches + the COLLATE and CTYPE + settings of the current database. If there is no such + collation, then this column and the associated schema and + catalog columns are null. +

PrevHomeNext
attributesUpcheck_constraint_routine_usage
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-check-constraint-routine-usage.html b/doc/src/sgml/html/infoschema-check-constraint-routine-usage.html new file mode 100644 index 000000000..6de0762b1 --- /dev/null +++ b/doc/src/sgml/html/infoschema-check-constraint-routine-usage.html @@ -0,0 +1,301 @@ + +check_constraint_routine_usage
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.8. check_constraint_routine_usage

The view check_constraint_routine_usage + identifies routines (functions and procedures) that are used by a + check constraint. Only those routines are shown that are owned by + a currently enabled role. +

Table 34-6. check_constraint_routine_usage Columns

NameData TypeDescription
constraint_catalogsql_identifierName of the database containing the constraint (always the current database)
constraint_schemasql_identifierName of the schema containing the constraint
constraint_namesql_identifierName of the constraint
specific_catalogsql_identifierName of the database containing the function (always the current database)
specific_schemasql_identifierName of the schema containing the function
specific_namesql_identifier The "specific name" of the function. See Section 34.40 for more information. +

PrevHomeNext
character_setsUpcheck_constraints
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-check-constraints.html b/doc/src/sgml/html/infoschema-check-constraints.html new file mode 100644 index 000000000..f5bf4ccda --- /dev/null +++ b/doc/src/sgml/html/infoschema-check-constraints.html @@ -0,0 +1,266 @@ + +check_constraints
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.9. check_constraints

The view check_constraints contains all check + constraints, either defined on a table or on a domain, that are + owned by a currently enabled role. (The owner of the table or + domain is the owner of the constraint.) +

Table 34-7. check_constraints Columns

NameData TypeDescription
constraint_catalogsql_identifierName of the database containing the constraint (always the current database)
constraint_schemasql_identifierName of the schema containing the constraint
constraint_namesql_identifierName of the constraint
check_clausecharacter_dataThe check expression of the check constraint

PrevHomeNext
check_constraint_routine_usageUpcollations
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-collation-character-set-applicab.html b/doc/src/sgml/html/infoschema-collation-character-set-applicab.html new file mode 100644 index 000000000..0e77309a4 --- /dev/null +++ b/doc/src/sgml/html/infoschema-collation-character-set-applicab.html @@ -0,0 +1,299 @@ + +collation_character_set_applicability
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.11. collation_character_set_applicability

The view collation_character_set_applicability + identifies which character set the available collations are + applicable to. In PostgreSQL, there is only one character set per + database (see explanation + in Section 34.7), so this view does + not provide much useful information. +

Table 34-9. collation_character_set_applicability Columns

NameData TypeDescription
collation_catalogsql_identifierName of the database containing the collation (always the current database)
collation_schemasql_identifierName of the schema containing the collation
collation_namesql_identifierName of the default collation
character_set_catalogsql_identifierCharacter sets are currently not implemented as schema objects, so this column is null
character_set_schemasql_identifierCharacter sets are currently not implemented as schema objects, so this column is null
character_set_namesql_identifierName of the character set

PrevHomeNext
collationsUpcolumn_domain_usage
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-collations.html b/doc/src/sgml/html/infoschema-collations.html new file mode 100644 index 000000000..aae67de3a --- /dev/null +++ b/doc/src/sgml/html/infoschema-collations.html @@ -0,0 +1,272 @@ + +collations
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.10. collations

The view collations contains the collations + available in the current database. +

Table 34-8. collations Columns

NameData TypeDescription
collation_catalogsql_identifierName of the database containing the collation (always the current database)
collation_schemasql_identifierName of the schema containing the collation
collation_namesql_identifierName of the default collation
pad_attributecharacter_data Always NO PAD (The alternative PAD + SPACE is not supported by PostgreSQL.) +

PrevHomeNext
check_constraintsUpcollation_character_set_applicability
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-column-domain-usage.html b/doc/src/sgml/html/infoschema-column-domain-usage.html new file mode 100644 index 000000000..1880be32b --- /dev/null +++ b/doc/src/sgml/html/infoschema-column-domain-usage.html @@ -0,0 +1,307 @@ + +column_domain_usage
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.12. column_domain_usage

The view column_domain_usage identifies all + columns (of a table or a view) that make use of some domain defined + in the current database and owned by a currently enabled role. +

Table 34-10. column_domain_usage Columns

NameData TypeDescription
domain_catalogsql_identifierName of the database containing the domain (always the current database)
domain_schemasql_identifierName of the schema containing the domain
domain_namesql_identifierName of the domain
table_catalogsql_identifierName of the database containing the table (always the current database)
table_schemasql_identifierName of the schema containing the table
table_namesql_identifierName of the table
column_namesql_identifierName of the column

PrevHomeNext
collation_character_set_applicabilityUpcolumn_options
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-column-options.html b/doc/src/sgml/html/infoschema-column-options.html new file mode 100644 index 000000000..616e5fd1c --- /dev/null +++ b/doc/src/sgml/html/infoschema-column-options.html @@ -0,0 +1,294 @@ + +column_options
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.13. column_options

The view column_options contains all the + options defined for foreign table columns in the current database. Only + those foreign table columns are shown that the current user has access to + (by way of being the owner or having some privilege). +

Table 34-11. column_options Columns

NameData TypeDescription
table_catalogsql_identifierName of the database that contains the foreign table (always the current database)
table_schemasql_identifierName of the schema that contains the foreign table
table_namesql_identifierName of the foreign table
column_namesql_identifierName of the column
option_namesql_identifierName of an option
option_valuecharacter_dataValue of the option

PrevHomeNext
column_domain_usageUpcolumn_privileges
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-column-privileges.html b/doc/src/sgml/html/infoschema-column-privileges.html new file mode 100644 index 000000000..552c0f935 --- /dev/null +++ b/doc/src/sgml/html/infoschema-column-privileges.html @@ -0,0 +1,362 @@ + +column_privileges
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.14. column_privileges

The view column_privileges identifies all + privileges granted on columns to a currently enabled role or by a + currently enabled role. There is one row for each combination of + column, grantor, and grantee. +

If a privilege has been granted on an entire table, it will show up in + this view as a grant for each column, but only for the + privilege types where column granularity is possible: + SELECT, INSERT, + UPDATE, REFERENCES. +

Table 34-12. column_privileges Columns

NameData TypeDescription
grantorsql_identifierName of the role that granted the privilege
granteesql_identifierName of the role that the privilege was granted to
table_catalogsql_identifierName of the database that contains the table that contains the column (always the current database)
table_schemasql_identifierName of the schema that contains the table that contains the column
table_namesql_identifierName of the table that contains the column
column_namesql_identifierName of the column
privilege_typecharacter_data Type of the privilege: SELECT, + INSERT, UPDATE, or + REFERENCES +
is_grantableyes_or_noYES if the privilege is grantable, NO if not

PrevHomeNext
column_optionsUpcolumn_udt_usage
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-column-udt-usage.html b/doc/src/sgml/html/infoschema-column-udt-usage.html new file mode 100644 index 000000000..67b2e7b36 --- /dev/null +++ b/doc/src/sgml/html/infoschema-column-udt-usage.html @@ -0,0 +1,322 @@ + +column_udt_usage
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.15. column_udt_usage

The view column_udt_usage identifies all columns + that use data types owned by a currently enabled role. Note that in + PostgreSQL, built-in data types behave + like user-defined types, so they are included here as well. See + also Section 34.16 for details. +

Table 34-13. column_udt_usage Columns

NameData TypeDescription
udt_catalogsql_identifier Name of the database that the column data type (the underlying + type of the domain, if applicable) is defined in (always the + current database) +
udt_schemasql_identifier Name of the schema that the column data type (the underlying + type of the domain, if applicable) is defined in +
udt_namesql_identifier Name of the column data type (the underlying type of the + domain, if applicable) +
table_catalogsql_identifierName of the database containing the table (always the current database)
table_schemasql_identifierName of the schema containing the table
table_namesql_identifierName of the table
column_namesql_identifierName of the column

PrevHomeNext
column_privilegesUpcolumns
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-columns.html b/doc/src/sgml/html/infoschema-columns.html new file mode 100644 index 000000000..3caeb2f34 --- /dev/null +++ b/doc/src/sgml/html/infoschema-columns.html @@ -0,0 +1,1103 @@ + +columns
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.16. columns

The view columns contains information about all + table columns (or view columns) in the database. System columns + (oid, etc.) are not included. Only those columns are + shown that the current user has access to (by way of being the + owner or having some privilege). +

Table 34-14. columns Columns

NameData TypeDescription
table_catalogsql_identifierName of the database containing the table (always the current database)
table_schemasql_identifierName of the schema containing the table
table_namesql_identifierName of the table
column_namesql_identifierName of the column
ordinal_positioncardinal_numberOrdinal position of the column within the table (count starts at 1)
column_defaultcharacter_dataDefault expression of the column
is_nullableyes_or_no YES if the column is possibly nullable, + NO if it is known not nullable. A not-null + constraint is one way a column can be known not nullable, but + there can be others. +
data_typecharacter_data Data type of the column, if it is a built-in type, or + ARRAY if it is some array (in that case, see + the view element_types), else + USER-DEFINED (in that case, the type is + identified in udt_name and associated + columns). If the column is based on a domain, this column + refers to the type underlying the domain (and the domain is + identified in domain_name and associated + columns). +
character_maximum_lengthcardinal_number If data_type identifies a character or bit + string type, the declared maximum length; null for all other + data types or if no maximum length was declared. +
character_octet_lengthcardinal_number If data_type identifies a character type, + the maximum possible length in octets (bytes) of a datum; null + for all other data types. The maximum octet length depends on + the declared character maximum length (see above) and the + server encoding. +
numeric_precisioncardinal_number If data_type identifies a numeric type, this + column contains the (declared or implicit) precision of the + type for this column. The precision indicates the number of + significant digits. It can be expressed in decimal (base 10) + or binary (base 2) terms, as specified in the column + numeric_precision_radix. For all other data + types, this column is null. +
numeric_precision_radixcardinal_number If data_type identifies a numeric type, this + column indicates in which base the values in the columns + numeric_precision and + numeric_scale are expressed. The value is + either 2 or 10. For all other data types, this column is null. +
numeric_scalecardinal_number If data_type identifies an exact numeric + type, this column contains the (declared or implicit) scale of + the type for this column. The scale indicates the number of + significant digits to the right of the decimal point. It can + be expressed in decimal (base 10) or binary (base 2) terms, as + specified in the column + numeric_precision_radix. For all other data + types, this column is null. +
datetime_precisioncardinal_number If data_type identifies a date, time, + timestamp, or interval type, this column contains the (declared + or implicit) fractional seconds precision of the type for this + column, that is, the number of decimal digits maintained + following the decimal point in the seconds value. For all + other data types, this column is null. +
interval_typecharacter_data If data_type identifies an interval type, + this column contains the specification which fields the + intervals include for this column, e.g., YEAR TO + MONTH, DAY TO SECOND, etc. If no + field restrictions were specified (that is, the interval + accepts all fields), and for all other data types, this field + is null. +
interval_precisioncardinal_number Applies to a feature not available + in PostgreSQL + (see datetime_precision for the fractional + seconds precision of interval type columns) +
character_set_catalogsql_identifierApplies to a feature not available in PostgreSQL
character_set_schemasql_identifierApplies to a feature not available in PostgreSQL
character_set_namesql_identifierApplies to a feature not available in PostgreSQL
collation_catalogsql_identifier Name of the database containing the collation of the column + (always the current database), null if default or the data type + of the column is not collatable +
collation_schemasql_identifier Name of the schema containing the collation of the column, null + if default or the data type of the column is not collatable +
collation_namesql_identifier Name of the collation of the column, null if default or the + data type of the column is not collatable +
domain_catalogsql_identifier If the column has a domain type, the name of the database that + the domain is defined in (always the current database), else + null. +
domain_schemasql_identifier If the column has a domain type, the name of the schema that + the domain is defined in, else null. +
domain_namesql_identifierIf the column has a domain type, the name of the domain, else null.
udt_catalogsql_identifier Name of the database that the column data type (the underlying + type of the domain, if applicable) is defined in (always the + current database) +
udt_schemasql_identifier Name of the schema that the column data type (the underlying + type of the domain, if applicable) is defined in +
udt_namesql_identifier Name of the column data type (the underlying type of the + domain, if applicable) +
scope_catalogsql_identifierApplies to a feature not available in PostgreSQL
scope_schemasql_identifierApplies to a feature not available in PostgreSQL
scope_namesql_identifierApplies to a feature not available in PostgreSQL
maximum_cardinalitycardinal_numberAlways null, because arrays always have unlimited maximum cardinality in PostgreSQL
dtd_identifiersql_identifier An identifier of the data type descriptor of the column, unique + among the data type descriptors pertaining to the table. This + is mainly useful for joining with other instances of such + identifiers. (The specific format of the identifier is not + defined and not guaranteed to remain the same in future + versions.) +
is_self_referencingyes_or_noApplies to a feature not available in PostgreSQL
is_identityyes_or_noApplies to a feature not available in PostgreSQL
identity_generationcharacter_dataApplies to a feature not available in PostgreSQL
identity_startcharacter_dataApplies to a feature not available in PostgreSQL
identity_incrementcharacter_dataApplies to a feature not available in PostgreSQL
identity_maximumcharacter_dataApplies to a feature not available in PostgreSQL
identity_minimumcharacter_dataApplies to a feature not available in PostgreSQL
identity_cycleyes_or_noApplies to a feature not available in PostgreSQL
is_generatedcharacter_dataApplies to a feature not available in PostgreSQL
generation_expressioncharacter_dataApplies to a feature not available in PostgreSQL
is_updatableyes_or_no YES if the column is updatable, + NO if not (Columns in base tables are always + updatable, columns in views not necessarily) +

Since data types can be defined in a variety of ways in SQL, and + PostgreSQL contains additional ways to + define data types, their representation in the information schema + can be somewhat difficult. The column data_type + is supposed to identify the underlying built-in type of the column. + In PostgreSQL, this means that the type + is defined in the system catalog schema + pg_catalog. This column might be useful if the + application can handle the well-known built-in types specially (for + example, format the numeric types differently or use the data in + the precision columns). The columns udt_name, + udt_schema, and udt_catalog + always identify the underlying data type of the column, even if the + column is based on a domain. (Since + PostgreSQL treats built-in types like + user-defined types, built-in types appear here as well. This is an + extension of the SQL standard.) These columns should be used if an + application wants to process data differently according to the + type, because in that case it wouldn't matter if the column is + really based on a domain. If the column is based on a domain, the + identity of the domain is stored in the columns + domain_name, domain_schema, + and domain_catalog. If you want to pair up + columns with their associated data types and treat domains as + separate types, you could write coalesce(domain_name, + udt_name), etc. +


PrevHomeNext
column_udt_usageUpconstraint_column_usage
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-constraint-column-usage.html b/doc/src/sgml/html/infoschema-constraint-column-usage.html new file mode 100644 index 000000000..7822e4d84 --- /dev/null +++ b/doc/src/sgml/html/infoschema-constraint-column-usage.html @@ -0,0 +1,320 @@ + +constraint_column_usage
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.17. constraint_column_usage

The view constraint_column_usage identifies all + columns in the current database that are used by some constraint. + Only those columns are shown that are contained in a table owned by + a currently enabled role. For a check constraint, this view + identifies the columns that are used in the check expression. For + a foreign key constraint, this view identifies the columns that the + foreign key references. For a unique or primary key constraint, + this view identifies the constrained columns. +

Table 34-15. constraint_column_usage Columns

NameData TypeDescription
table_catalogsql_identifier Name of the database that contains the table that contains the + column that is used by some constraint (always the current + database) +
table_schemasql_identifier Name of the schema that contains the table that contains the + column that is used by some constraint +
table_namesql_identifier Name of the table that contains the column that is used by some + constraint +
column_namesql_identifier Name of the column that is used by some constraint +
constraint_catalogsql_identifierName of the database that contains the constraint (always the current database)
constraint_schemasql_identifierName of the schema that contains the constraint
constraint_namesql_identifierName of the constraint

PrevHomeNext
columnsUpconstraint_table_usage
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-constraint-table-usage.html b/doc/src/sgml/html/infoschema-constraint-table-usage.html new file mode 100644 index 000000000..b0efce2f8 --- /dev/null +++ b/doc/src/sgml/html/infoschema-constraint-table-usage.html @@ -0,0 +1,307 @@ + +constraint_table_usage
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.18. constraint_table_usage

The view constraint_table_usage identifies all + tables in the current database that are used by some constraint and + are owned by a currently enabled role. (This is different from the + view table_constraints, which identifies all + table constraints along with the table they are defined on.) For a + foreign key constraint, this view identifies the table that the + foreign key references. For a unique or primary key constraint, + this view simply identifies the table the constraint belongs to. + Check constraints and not-null constraints are not included in this + view. +

Table 34-16. constraint_table_usage Columns

NameData TypeDescription
table_catalogsql_identifier Name of the database that contains the table that is used by + some constraint (always the current database) +
table_schemasql_identifier Name of the schema that contains the table that is used by some + constraint +
table_namesql_identifierName of the table that is used by some constraint
constraint_catalogsql_identifierName of the database that contains the constraint (always the current database)
constraint_schemasql_identifierName of the schema that contains the constraint
constraint_namesql_identifierName of the constraint

PrevHomeNext
constraint_column_usageUpdata_type_privileges
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-data-type-privileges.html b/doc/src/sgml/html/infoschema-data-type-privileges.html new file mode 100644 index 000000000..a4afa69e3 --- /dev/null +++ b/doc/src/sgml/html/infoschema-data-type-privileges.html @@ -0,0 +1,306 @@ + +data_type_privileges
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.19. data_type_privileges

The view data_type_privileges identifies all + data type descriptors that the current user has access to, by way + of being the owner of the described object or having some privilege + for it. A data type descriptor is generated whenever a data type + is used in the definition of a table column, a domain, or a + function (as parameter or return type) and stores some information + about how the data type is used in that instance (for example, the + declared maximum length, if applicable). Each data type + descriptor is assigned an arbitrary identifier that is unique + among the data type descriptor identifiers assigned for one object + (table, domain, function). This view is probably not useful for + applications, but it is used to define some other views in the + information schema. +

Table 34-17. data_type_privileges Columns

NameData TypeDescription
object_catalogsql_identifierName of the database that contains the described object (always the current database)
object_schemasql_identifierName of the schema that contains the described object
object_namesql_identifierName of the described object
object_typecharacter_data The type of the described object: one of + TABLE (the data type descriptor pertains to + a column of that table), DOMAIN (the data + type descriptors pertains to that domain), + ROUTINE (the data type descriptor pertains + to a parameter or the return data type of that function). +
dtd_identifiersql_identifier The identifier of the data type descriptor, which is unique + among the data type descriptors for that same object. +

PrevHomeNext
constraint_table_usageUpdomain_constraints
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-datatypes.html b/doc/src/sgml/html/infoschema-datatypes.html new file mode 100644 index 000000000..611cec92f --- /dev/null +++ b/doc/src/sgml/html/infoschema-datatypes.html @@ -0,0 +1,261 @@ + +Data Types
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.2. Data Types

The columns of the information schema views use special data types + that are defined in the information schema. These are defined as + simple domains over ordinary built-in types. You should not use + these types for work outside the information schema, but your + applications must be prepared for them if they select from the + information schema. +

These types are: + +

cardinal_number

A nonnegative integer. +

character_data

A character string (without specific maximum length). +

sql_identifier

A character string. This type is used for SQL identifiers, the + type character_data is used for any other kind of + text data. +

time_stamp

A domain over the type timestamp with time zone +

yes_or_no

A character string domain that contains + either YES or NO. This + is used to represent Boolean (true/false) data in the + information schema. (The information schema was invented + before the type boolean was added to the SQL + standard, so this convention is necessary to keep the + information schema backward compatible.) +

+ + Every column in the information schema has one of these five types. +


PrevHomeNext
The SchemaUpinformation_schema_catalog_name
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-domain-constraints.html b/doc/src/sgml/html/infoschema-domain-constraints.html new file mode 100644 index 000000000..7e1f181f6 --- /dev/null +++ b/doc/src/sgml/html/infoschema-domain-constraints.html @@ -0,0 +1,334 @@ + +domain_constraints
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.20. domain_constraints

The view domain_constraints contains all constraints + belonging to domains defined in the current database. Only those domains + are shown that the current user has access to (by way of being the owner or + having some privilege). +

Table 34-18. domain_constraints Columns

NameData TypeDescription
constraint_catalogsql_identifierName of the database that contains the constraint (always the current database)
constraint_schemasql_identifierName of the schema that contains the constraint
constraint_namesql_identifierName of the constraint
domain_catalogsql_identifierName of the database that contains the domain (always the current database)
domain_schemasql_identifierName of the schema that contains the domain
domain_namesql_identifierName of the domain
is_deferrableyes_or_noYES if the constraint is deferrable, NO if not
initially_deferredyes_or_noYES if the constraint is deferrable and initially deferred, NO if not

PrevHomeNext
data_type_privilegesUpdomain_udt_usage
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-domain-udt-usage.html b/doc/src/sgml/html/infoschema-domain-udt-usage.html new file mode 100644 index 000000000..baec66c55 --- /dev/null +++ b/doc/src/sgml/html/infoschema-domain-udt-usage.html @@ -0,0 +1,298 @@ + +domain_udt_usage
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.21. domain_udt_usage

The view domain_udt_usage identifies all domains + that are based on data types owned by a currently enabled role. + Note that in PostgreSQL, built-in data + types behave like user-defined types, so they are included here as + well. +

Table 34-19. domain_udt_usage Columns

NameData TypeDescription
udt_catalogsql_identifierName of the database that the domain data type is defined in (always the current database)
udt_schemasql_identifierName of the schema that the domain data type is defined in
udt_namesql_identifierName of the domain data type
domain_catalogsql_identifierName of the database that contains the domain (always the current database)
domain_schemasql_identifierName of the schema that contains the domain
domain_namesql_identifierName of the domain

PrevHomeNext
domain_constraintsUpdomains
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-domains.html b/doc/src/sgml/html/infoschema-domains.html new file mode 100644 index 000000000..cf9d43f67 --- /dev/null +++ b/doc/src/sgml/html/infoschema-domains.html @@ -0,0 +1,713 @@ + +domains
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.22. domains

The view domains contains all domains defined in the + current database. Only those domains are shown that the current user has + access to (by way of being the owner or having some privilege). +

Table 34-20. domains Columns

NameData TypeDescription
domain_catalogsql_identifierName of the database that contains the domain (always the current database)
domain_schemasql_identifierName of the schema that contains the domain
domain_namesql_identifierName of the domain
data_typecharacter_data Data type of the domain, if it is a built-in type, or + ARRAY if it is some array (in that case, see + the view element_types), else + USER-DEFINED (in that case, the type is + identified in udt_name and associated + columns). +
character_maximum_lengthcardinal_number If the domain has a character or bit string type, the declared + maximum length; null for all other data types or if no maximum + length was declared. +
character_octet_lengthcardinal_number If the domain has a character type, the maximum possible length + in octets (bytes) of a datum; null for all other data types. + The maximum octet length depends on the declared character + maximum length (see above) and the server encoding. +
character_set_catalogsql_identifierApplies to a feature not available in PostgreSQL
character_set_schemasql_identifierApplies to a feature not available in PostgreSQL
character_set_namesql_identifierApplies to a feature not available in PostgreSQL
collation_catalogsql_identifier Name of the database containing the collation of the domain + (always the current database), null if default or the data type + of the domain is not collatable +
collation_schemasql_identifier Name of the schema containing the collation of the domain, null + if default or the data type of the domain is not collatable +
collation_namesql_identifier Name of the collation of the domain, null if default or the + data type of the domain is not collatable +
numeric_precisioncardinal_number If the domain has a numeric type, this column contains the + (declared or implicit) precision of the type for this domain. + The precision indicates the number of significant digits. It + can be expressed in decimal (base 10) or binary (base 2) terms, + as specified in the column + numeric_precision_radix. For all other data + types, this column is null. +
numeric_precision_radixcardinal_number If the domain has a numeric type, this column indicates in + which base the values in the columns + numeric_precision and + numeric_scale are expressed. The value is + either 2 or 10. For all other data types, this column is null. +
numeric_scalecardinal_number If the domain has an exact numeric type, this column contains + the (declared or implicit) scale of the type for this domain. + The scale indicates the number of significant digits to the + right of the decimal point. It can be expressed in decimal + (base 10) or binary (base 2) terms, as specified in the column + numeric_precision_radix. For all other data + types, this column is null. +
datetime_precisioncardinal_number If data_type identifies a date, time, + timestamp, or interval type, this column contains the (declared + or implicit) fractional seconds precision of the type for this + domain, that is, the number of decimal digits maintained + following the decimal point in the seconds value. For all + other data types, this column is null. +
interval_typecharacter_data If data_type identifies an interval type, + this column contains the specification which fields the + intervals include for this domain, e.g., YEAR TO + MONTH, DAY TO SECOND, etc. If no + field restrictions were specified (that is, the interval + accepts all fields), and for all other data types, this field + is null. +
interval_precisioncardinal_number Applies to a feature not available + in PostgreSQL + (see datetime_precision for the fractional + seconds precision of interval type domains) +
domain_defaultcharacter_dataDefault expression of the domain
udt_catalogsql_identifierName of the database that the domain data type is defined in (always the current database)
udt_schemasql_identifierName of the schema that the domain data type is defined in
udt_namesql_identifierName of the domain data type
scope_catalogsql_identifierApplies to a feature not available in PostgreSQL
scope_schemasql_identifierApplies to a feature not available in PostgreSQL
scope_namesql_identifierApplies to a feature not available in PostgreSQL
maximum_cardinalitycardinal_numberAlways null, because arrays always have unlimited maximum cardinality in PostgreSQL
dtd_identifiersql_identifier An identifier of the data type descriptor of the domain, unique + among the data type descriptors pertaining to the domain (which + is trivial, because a domain only contains one data type + descriptor). This is mainly useful for joining with other + instances of such identifiers. (The specific format of the + identifier is not defined and not guaranteed to remain the same + in future versions.) +

PrevHomeNext
domain_udt_usageUpelement_types
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-element-types.html b/doc/src/sgml/html/infoschema-element-types.html new file mode 100644 index 000000000..aa30f3e09 --- /dev/null +++ b/doc/src/sgml/html/infoschema-element-types.html @@ -0,0 +1,739 @@ + +element_types
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.23. element_types

The view element_types contains the data type + descriptors of the elements of arrays. When a table column, composite-type attribute, + domain, function parameter, or function return value is defined to + be of an array type, the respective information schema view only + contains ARRAY in the column + data_type. To obtain information on the element + type of the array, you can join the respective view with this view. + For example, to show the columns of a table with data types and + array element types, if applicable, you could do: +

SELECT c.column_name, c.data_type, e.data_type AS element_type
+FROM information_schema.columns c LEFT JOIN information_schema.element_types e
+     ON ((c.table_catalog, c.table_schema, c.table_name, 'TABLE', c.dtd_identifier)
+       = (e.object_catalog, e.object_schema, e.object_name, e.object_type, e.collection_type_identifier))
+WHERE c.table_schema = '...' AND c.table_name = '...'
+ORDER BY c.ordinal_position;

+ This view only includes objects that the current user has access + to, by way of being the owner or having some privilege. +

Table 34-21. element_types Columns

NameData TypeDescription
object_catalogsql_identifier Name of the database that contains the object that uses the + array being described (always the current database) +
object_schemasql_identifier Name of the schema that contains the object that uses the array + being described +
object_namesql_identifier Name of the object that uses the array being described +
object_typecharacter_data The type of the object that uses the array being described: one + of TABLE (the array is used by a column of + that table), USER-DEFINED TYPE (the array is + used by an attribute of that composite type), + DOMAIN (the array is used by that domain), + ROUTINE (the array is used by a parameter or + the return data type of that function). +
collection_type_identifiersql_identifier The identifier of the data type descriptor of the array being + described. Use this to join with the + dtd_identifier columns of other information + schema views. +
data_typecharacter_data Data type of the array elements, if it is a built-in type, else + USER-DEFINED (in that case, the type is + identified in udt_name and associated + columns). +
character_maximum_lengthcardinal_numberAlways null, since this information is not applied to array element data types in PostgreSQL
character_octet_lengthcardinal_numberAlways null, since this information is not applied to array element data types in PostgreSQL
character_set_catalogsql_identifierApplies to a feature not available in PostgreSQL
character_set_schemasql_identifierApplies to a feature not available in PostgreSQL
character_set_namesql_identifierApplies to a feature not available in PostgreSQL
collation_catalogsql_identifier Name of the database containing the collation of the element + type (always the current database), null if default or the data + type of the element is not collatable +
collation_schemasql_identifier Name of the schema containing the collation of the element + type, null if default or the data type of the element is not + collatable +
collation_namesql_identifier Name of the collation of the element type, null if default or + the data type of the element is not collatable +
numeric_precisioncardinal_numberAlways null, since this information is not applied to array element data types in PostgreSQL
numeric_precision_radixcardinal_numberAlways null, since this information is not applied to array element data types in PostgreSQL
numeric_scalecardinal_numberAlways null, since this information is not applied to array element data types in PostgreSQL
datetime_precisioncardinal_numberAlways null, since this information is not applied to array element data types in PostgreSQL
interval_typecharacter_dataAlways null, since this information is not applied to array element data types in PostgreSQL
interval_precisioncardinal_numberAlways null, since this information is not applied to array element data types in PostgreSQL
domain_defaultcharacter_dataNot yet implemented
udt_catalogsql_identifier Name of the database that the data type of the elements is + defined in (always the current database) +
udt_schemasql_identifier Name of the schema that the data type of the elements is + defined in +
udt_namesql_identifier Name of the data type of the elements +
scope_catalogsql_identifierApplies to a feature not available in PostgreSQL
scope_schemasql_identifierApplies to a feature not available in PostgreSQL
scope_namesql_identifierApplies to a feature not available in PostgreSQL
maximum_cardinalitycardinal_numberAlways null, because arrays always have unlimited maximum cardinality in PostgreSQL
dtd_identifiersql_identifier An identifier of the data type descriptor of the element. This + is currently not useful. +

PrevHomeNext
domainsUpenabled_roles
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-enabled-roles.html b/doc/src/sgml/html/infoschema-enabled-roles.html new file mode 100644 index 000000000..76cf3c729 --- /dev/null +++ b/doc/src/sgml/html/infoschema-enabled-roles.html @@ -0,0 +1,244 @@ + +enabled_roles
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.24. enabled_roles

The view enabled_roles identifies the currently + "enabled roles". The enabled roles are recursively + defined as the current user together with all roles that have been + granted to the enabled roles with automatic inheritance. In other + words, these are all roles that the current user has direct or + indirect, automatically inheriting membership in. + + +

For permission checking, the set of "applicable roles" + is applied, which can be broader than the set of enabled roles. So + generally, it is better to use the view + applicable_roles instead of this one; see also + there. +

Table 34-22. enabled_roles Columns

NameData TypeDescription
role_namesql_identifierName of a role

PrevHomeNext
element_typesUpforeign_data_wrapper_options
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-foreign-data-wrapper-options.html b/doc/src/sgml/html/infoschema-foreign-data-wrapper-options.html new file mode 100644 index 000000000..39118e910 --- /dev/null +++ b/doc/src/sgml/html/infoschema-foreign-data-wrapper-options.html @@ -0,0 +1,267 @@ + +foreign_data_wrapper_options
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.25. foreign_data_wrapper_options

The view foreign_data_wrapper_options contains + all the options defined for foreign-data wrappers in the current + database. Only those foreign-data wrappers are shown that the + current user has access to (by way of being the owner or having + some privilege). +

Table 34-23. foreign_data_wrapper_options Columns

NameData TypeDescription
foreign_data_wrapper_catalogsql_identifierName of the database that the foreign-data wrapper is defined in (always the current database)
foreign_data_wrapper_namesql_identifierName of the foreign-data wrapper
option_namesql_identifierName of an option
option_valuecharacter_dataValue of the option

PrevHomeNext
enabled_rolesUpforeign_data_wrappers
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-foreign-data-wrappers.html b/doc/src/sgml/html/infoschema-foreign-data-wrappers.html new file mode 100644 index 000000000..34e25d8f4 --- /dev/null +++ b/doc/src/sgml/html/infoschema-foreign-data-wrappers.html @@ -0,0 +1,281 @@ + +foreign_data_wrappers
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.26. foreign_data_wrappers

The view foreign_data_wrappers contains all + foreign-data wrappers defined in the current database. Only those + foreign-data wrappers are shown that the current user has access to + (by way of being the owner or having some privilege). +

Table 34-24. foreign_data_wrappers Columns

NameData TypeDescription
foreign_data_wrapper_catalogsql_identifierName of the database that contains the foreign-data + wrapper (always the current database)
foreign_data_wrapper_namesql_identifierName of the foreign-data wrapper
authorization_identifiersql_identifierName of the owner of the foreign server
library_namecharacter_dataFile name of the library that implementing this foreign-data wrapper
foreign_data_wrapper_languagecharacter_dataLanguage used to implement this foreign-data wrapper

PrevHomeNext
foreign_data_wrapper_optionsUpforeign_server_options
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-foreign-server-options.html b/doc/src/sgml/html/infoschema-foreign-server-options.html new file mode 100644 index 000000000..3ac02cafa --- /dev/null +++ b/doc/src/sgml/html/infoschema-foreign-server-options.html @@ -0,0 +1,266 @@ + +foreign_server_options
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.27. foreign_server_options

The view foreign_server_options contains all the + options defined for foreign servers in the current database. Only + those foreign servers are shown that the current user has access to + (by way of being the owner or having some privilege). +

Table 34-25. foreign_server_options Columns

NameData TypeDescription
foreign_server_catalogsql_identifierName of the database that the foreign server is defined in (always the current database)
foreign_server_namesql_identifierName of the foreign server
option_namesql_identifierName of an option
option_valuecharacter_dataValue of the option

PrevHomeNext
foreign_data_wrappersUpforeign_servers
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-foreign-servers.html b/doc/src/sgml/html/infoschema-foreign-servers.html new file mode 100644 index 000000000..226d9185d --- /dev/null +++ b/doc/src/sgml/html/infoschema-foreign-servers.html @@ -0,0 +1,309 @@ + +foreign_servers
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.28. foreign_servers

The view foreign_servers contains all foreign + servers defined in the current database. Only those foreign + servers are shown that the current user has access to (by way of + being the owner or having some privilege). +

Table 34-26. foreign_servers Columns

NameData TypeDescription
foreign_server_catalogsql_identifierName of the database that the foreign server is defined in (always the current database)
foreign_server_namesql_identifierName of the foreign server
foreign_data_wrapper_catalogsql_identifierName of the database that contains the foreign-data + wrapper used by the foreign server (always the current database)
foreign_data_wrapper_namesql_identifierName of the foreign-data wrapper used by the foreign server
foreign_server_typecharacter_dataForeign server type information, if specified upon creation
foreign_server_versioncharacter_dataForeign server version information, if specified upon creation
authorization_identifiersql_identifierName of the owner of the foreign server

PrevHomeNext
foreign_server_optionsUpforeign_table_options
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-foreign-table-options.html b/doc/src/sgml/html/infoschema-foreign-table-options.html new file mode 100644 index 000000000..a4712ea2e --- /dev/null +++ b/doc/src/sgml/html/infoschema-foreign-table-options.html @@ -0,0 +1,308 @@ + +foreign_table_options
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.29. foreign_table_options

The view foreign_table_options contains all the + options defined for foreign tables in the current database. Only + those foreign tables are shown that the current user has access to + (by way of being the owner or having some privilege). +

Table 34-27. foreign_table_options Columns

NameData TypeDescription
foreign_table_catalogsql_identifierName of the database that contains the foreign table (always the current database)
foreign_table_schemasql_identifierName of the schema that contains the foreign table
foreign_table_namesql_identifierName of the foreign table
foreign_server_catalogsql_identifierName of the database that the foreign server is defined in (always the current database)
foreign_server_namesql_identifierName of the foreign server
option_namesql_identifierName of an option
option_valuecharacter_dataValue of the option

PrevHomeNext
foreign_serversUpforeign_tables
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-foreign-tables.html b/doc/src/sgml/html/infoschema-foreign-tables.html new file mode 100644 index 000000000..ee48e8aa6 --- /dev/null +++ b/doc/src/sgml/html/infoschema-foreign-tables.html @@ -0,0 +1,280 @@ + +foreign_tables
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.30. foreign_tables

The view foreign_tables contains all foreign + tables defined in the current database. Only those foreign + tables are shown that the current user has access to (by way of + being the owner or having some privilege). +

Table 34-28. foreign_tables Columns

NameData TypeDescription
foreign_table_catalogsql_identifierName of the database that the foreign table is defined in (always the current database)
foreign_table_schemasql_identifierName of the schema that contains the foreign table
foreign_table_namesql_identifierName of the foreign table
foreign_server_catalogsql_identifierName of the database that the foreign server is defined in (always the current database)
foreign_server_namesql_identifierName of the foreign server

PrevHomeNext
foreign_table_optionsUpkey_column_usage
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-information-schema-catalog-name.html b/doc/src/sgml/html/infoschema-information-schema-catalog-name.html new file mode 100644 index 000000000..8ae8c17e4 --- /dev/null +++ b/doc/src/sgml/html/infoschema-information-schema-catalog-name.html @@ -0,0 +1,220 @@ + +information_schema_catalog_name
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.3. information_schema_catalog_name

information_schema_catalog_name is a table that + always contains one row and one column containing the name of the + current database (current catalog, in SQL terminology). +

Table 34-1. information_schema_catalog_name Columns

NameData TypeDescription
catalog_namesql_identifierName of the database that contains this information schema

PrevHomeNext
Data TypesUpadministrable_role_authorizations
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-key-column-usage.html b/doc/src/sgml/html/infoschema-key-column-usage.html new file mode 100644 index 000000000..5716f4e71 --- /dev/null +++ b/doc/src/sgml/html/infoschema-key-column-usage.html @@ -0,0 +1,350 @@ + +key_column_usage
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.31. key_column_usage

The view key_column_usage identifies all columns + in the current database that are restricted by some unique, primary + key, or foreign key constraint. Check constraints are not included + in this view. Only those columns are shown that the current user + has access to, by way of being the owner or having some privilege. +

Table 34-29. key_column_usage Columns

NameData TypeDescription
constraint_catalogsql_identifierName of the database that contains the constraint (always the current database)
constraint_schemasql_identifierName of the schema that contains the constraint
constraint_namesql_identifierName of the constraint
table_catalogsql_identifier Name of the database that contains the table that contains the + column that is restricted by this constraint (always the + current database) +
table_schemasql_identifier Name of the schema that contains the table that contains the + column that is restricted by this constraint +
table_namesql_identifier Name of the table that contains the column that is restricted + by this constraint +
column_namesql_identifier Name of the column that is restricted by this constraint +
ordinal_positioncardinal_number Ordinal position of the column within the constraint key (count + starts at 1) +
position_in_unique_constraintcardinal_number For a foreign-key constraint, ordinal position of the referenced + column within its unique constraint (count starts at 1); + otherwise null +

PrevHomeNext
foreign_tablesUpparameters
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-parameters.html b/doc/src/sgml/html/infoschema-parameters.html new file mode 100644 index 000000000..acb0f4495 --- /dev/null +++ b/doc/src/sgml/html/infoschema-parameters.html @@ -0,0 +1,754 @@ + +parameters
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.32. parameters

The view parameters contains information about + the parameters (arguments) of all functions in the current database. + Only those functions are shown that the current user has access to + (by way of being the owner or having some privilege). +

Table 34-30. parameters Columns

NameData TypeDescription
specific_catalogsql_identifierName of the database containing the function (always the current database)
specific_schemasql_identifierName of the schema containing the function
specific_namesql_identifier The "specific name" of the function. See Section 34.40 for more information. +
ordinal_positioncardinal_number Ordinal position of the parameter in the argument list of the + function (count starts at 1) +
parameter_modecharacter_data IN for input parameter, + OUT for output parameter, + and INOUT for input/output parameter. +
is_resultyes_or_noApplies to a feature not available in PostgreSQL
as_locatoryes_or_noApplies to a feature not available in PostgreSQL
parameter_namesql_identifierName of the parameter, or null if the parameter has no name
data_typecharacter_data Data type of the parameter, if it is a built-in type, or + ARRAY if it is some array (in that case, see + the view element_types), else + USER-DEFINED (in that case, the type is + identified in udt_name and associated + columns). +
character_maximum_lengthcardinal_numberAlways null, since this information is not applied to parameter data types in PostgreSQL
character_octet_lengthcardinal_numberAlways null, since this information is not applied to parameter data types in PostgreSQL
character_set_catalogsql_identifierApplies to a feature not available in PostgreSQL
character_set_schemasql_identifierApplies to a feature not available in PostgreSQL
character_set_namesql_identifierApplies to a feature not available in PostgreSQL
collation_catalogsql_identifierAlways null, since this information is not applied to parameter data types in PostgreSQL
collation_schemasql_identifierAlways null, since this information is not applied to parameter data types in PostgreSQL
collation_namesql_identifierAlways null, since this information is not applied to parameter data types in PostgreSQL
numeric_precisioncardinal_numberAlways null, since this information is not applied to parameter data types in PostgreSQL
numeric_precision_radixcardinal_numberAlways null, since this information is not applied to parameter data types in PostgreSQL
numeric_scalecardinal_numberAlways null, since this information is not applied to parameter data types in PostgreSQL
datetime_precisioncardinal_numberAlways null, since this information is not applied to parameter data types in PostgreSQL
interval_typecharacter_dataAlways null, since this information is not applied to parameter data types in PostgreSQL
interval_precisioncardinal_numberAlways null, since this information is not applied to parameter data types in PostgreSQL
udt_catalogsql_identifier Name of the database that the data type of the parameter is + defined in (always the current database) +
udt_schemasql_identifier Name of the schema that the data type of the parameter is + defined in +
udt_namesql_identifier Name of the data type of the parameter +
scope_catalogsql_identifierApplies to a feature not available in PostgreSQL
scope_schemasql_identifierApplies to a feature not available in PostgreSQL
scope_namesql_identifierApplies to a feature not available in PostgreSQL
maximum_cardinalitycardinal_numberAlways null, because arrays always have unlimited maximum cardinality in PostgreSQL
dtd_identifiersql_identifier An identifier of the data type descriptor of the parameter, + unique among the data type descriptors pertaining to the + function. This is mainly useful for joining with other + instances of such identifiers. (The specific format of the + identifier is not defined and not guaranteed to remain the same + in future versions.) +

PrevHomeNext
key_column_usageUpreferential_constraints
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-referential-constraints.html b/doc/src/sgml/html/infoschema-referential-constraints.html new file mode 100644 index 000000000..e15a8e479 --- /dev/null +++ b/doc/src/sgml/html/infoschema-referential-constraints.html @@ -0,0 +1,397 @@ + +referential_constraints
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.33. referential_constraints

The view referential_constraints contains all + referential (foreign key) constraints in the current database. + Only those constraints are shown for which the current user has + write access to the referencing table (by way of being the + owner or having some privilege other than SELECT). +

Table 34-31. referential_constraints Columns

NameData TypeDescription
constraint_catalogsql_identifierName of the database containing the constraint (always the current database)
constraint_schemasql_identifierName of the schema containing the constraint
constraint_namesql_identifierName of the constraint
unique_constraint_catalogsql_identifier Name of the database that contains the unique or primary key + constraint that the foreign key constraint references (always + the current database) +
unique_constraint_schemasql_identifier Name of the schema that contains the unique or primary key + constraint that the foreign key constraint references +
unique_constraint_namesql_identifier Name of the unique or primary key constraint that the foreign + key constraint references +
match_optioncharacter_data Match option of the foreign key constraint: + FULL, PARTIAL, or + NONE. +
update_rulecharacter_data Update rule of the foreign key constraint: + CASCADE, SET NULL, + SET DEFAULT, RESTRICT, or + NO ACTION. +
delete_rulecharacter_data Delete rule of the foreign key constraint: + CASCADE, SET NULL, + SET DEFAULT, RESTRICT, or + NO ACTION. +

PrevHomeNext
parametersUprole_column_grants
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-role-column-grants.html b/doc/src/sgml/html/infoschema-role-column-grants.html new file mode 100644 index 000000000..45053ea02 --- /dev/null +++ b/doc/src/sgml/html/infoschema-role-column-grants.html @@ -0,0 +1,356 @@ + +role_column_grants
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.34. role_column_grants

The view role_column_grants identifies all + privileges granted on columns where the grantor or grantee is a + currently enabled role. Further information can be found under + column_privileges. The only effective + difference between this view + and column_privileges is that this view omits + columns that have been made accessible to the current user by way + of a grant to PUBLIC. +

Table 34-32. role_column_grants Columns

NameData TypeDescription
grantorsql_identifierName of the role that granted the privilege
granteesql_identifierName of the role that the privilege was granted to
table_catalogsql_identifierName of the database that contains the table that contains the column (always the current database)
table_schemasql_identifierName of the schema that contains the table that contains the column
table_namesql_identifierName of the table that contains the column
column_namesql_identifierName of the column
privilege_typecharacter_data Type of the privilege: SELECT, + INSERT, UPDATE, or + REFERENCES +
is_grantableyes_or_noYES if the privilege is grantable, NO if not

PrevHomeNext
referential_constraintsUprole_routine_grants
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-role-routine-grants.html b/doc/src/sgml/html/infoschema-role-routine-grants.html new file mode 100644 index 000000000..56a77edc9 --- /dev/null +++ b/doc/src/sgml/html/infoschema-role-routine-grants.html @@ -0,0 +1,379 @@ + +role_routine_grants
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.35. role_routine_grants

The view role_routine_grants identifies all + privileges granted on functions where the grantor or grantee is a + currently enabled role. Further information can be found under + routine_privileges. The only effective + difference between this view + and routine_privileges is that this view omits + functions that have been made accessible to the current user by way + of a grant to PUBLIC. +

Table 34-33. role_routine_grants Columns

NameData TypeDescription
grantorsql_identifierName of the role that granted the privilege
granteesql_identifierName of the role that the privilege was granted to
specific_catalogsql_identifierName of the database containing the function (always the current database)
specific_schemasql_identifierName of the schema containing the function
specific_namesql_identifier The "specific name" of the function. See Section 34.40 for more information. +
routine_catalogsql_identifierName of the database containing the function (always the current database)
routine_schemasql_identifierName of the schema containing the function
routine_namesql_identifierName of the function (might be duplicated in case of overloading)
privilege_typecharacter_dataAlways EXECUTE (the only privilege type for functions)
is_grantableyes_or_noYES if the privilege is grantable, NO if not

PrevHomeNext
role_column_grantsUprole_table_grants
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-role-table-grants.html b/doc/src/sgml/html/infoschema-role-table-grants.html new file mode 100644 index 000000000..7aa1576d8 --- /dev/null +++ b/doc/src/sgml/html/infoschema-role-table-grants.html @@ -0,0 +1,387 @@ + +role_table_grants
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.36. role_table_grants

The view role_table_grants identifies all + privileges granted on tables or views where the grantor or grantee + is a currently enabled role. Further information can be found + under table_privileges. The only effective + difference between this view + and table_privileges is that this view omits + tables that have been made accessible to the current user by way of + a grant to PUBLIC. +

Table 34-34. role_table_grants Columns

NameData TypeDescription
grantorsql_identifierName of the role that granted the privilege
granteesql_identifierName of the role that the privilege was granted to
table_catalogsql_identifierName of the database that contains the table (always the current database)
table_schemasql_identifierName of the schema that contains the table
table_namesql_identifierName of the table
privilege_typecharacter_data Type of the privilege: SELECT, + INSERT, UPDATE, + DELETE, TRUNCATE, + REFERENCES, or TRIGGER +
is_grantableyes_or_noYES if the privilege is grantable, NO if not
with_hierarchyyes_or_no In the SQL standard, WITH HIERARCHY OPTION + is a separate (sub-)privilege allowing certain operations on + table inheritance hierarchies. In PostgreSQL, this is included + in the SELECT privilege, so this column + shows YES if the privilege + is SELECT, else NO. +

PrevHomeNext
role_routine_grantsUprole_udt_grants
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-role-udt-grants.html b/doc/src/sgml/html/infoschema-role-udt-grants.html new file mode 100644 index 000000000..d6e8489f7 --- /dev/null +++ b/doc/src/sgml/html/infoschema-role-udt-grants.html @@ -0,0 +1,338 @@ + +role_udt_grants
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.37. role_udt_grants

The view role_udt_grants is intended to identify + USAGE privileges granted on user-defined types + where the grantor or grantee is a currently enabled role. Further + information can be found under + udt_privileges. The only effective difference + between this view and udt_privileges is that + this view omits objects that have been made accessible to the + current user by way of a grant to PUBLIC. Since + data types do not have real privileges in PostgreSQL, but only an + implicit grant to PUBLIC, this view is empty. +

Table 34-35. role_udt_grants Columns

NameData TypeDescription
grantorsql_identifierThe name of the role that granted the privilege
granteesql_identifierThe name of the role that the privilege was granted to
udt_catalogsql_identifierName of the database containing the type (always the current database)
udt_schemasql_identifierName of the schema containing the type
udt_namesql_identifierName of the type
privilege_typecharacter_dataAlways TYPE USAGE
is_grantableyes_or_noYES if the privilege is grantable, NO if not

PrevHomeNext
role_table_grantsUprole_usage_grants
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-role-usage-grants.html b/doc/src/sgml/html/infoschema-role-usage-grants.html new file mode 100644 index 000000000..58a7869e6 --- /dev/null +++ b/doc/src/sgml/html/infoschema-role-usage-grants.html @@ -0,0 +1,363 @@ + +role_usage_grants
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.38. role_usage_grants

The view role_usage_grants identifies + USAGE privileges granted on various kinds of + objects where the grantor or grantee is a currently enabled role. + Further information can be found under + usage_privileges. The only effective difference + between this view and usage_privileges is that + this view omits objects that have been made accessible to the + current user by way of a grant to PUBLIC. +

Table 34-36. role_usage_grants Columns

NameData TypeDescription
grantorsql_identifierThe name of the role that granted the privilege
granteesql_identifierThe name of the role that the privilege was granted to
object_catalogsql_identifierName of the database containing the object (always the current database)
object_schemasql_identifierName of the schema containing the object, if applicable, + else an empty string
object_namesql_identifierName of the object
object_typecharacter_dataCOLLATION or DOMAIN or FOREIGN DATA WRAPPER or FOREIGN SERVER or SEQUENCE
privilege_typecharacter_dataAlways USAGE
is_grantableyes_or_noYES if the privilege is grantable, NO if not

PrevHomeNext
role_udt_grantsUproutine_privileges
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-routine-privileges.html b/doc/src/sgml/html/infoschema-routine-privileges.html new file mode 100644 index 000000000..5e8f0910b --- /dev/null +++ b/doc/src/sgml/html/infoschema-routine-privileges.html @@ -0,0 +1,366 @@ + +routine_privileges
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.39. routine_privileges

The view routine_privileges identifies all + privileges granted on functions to a currently enabled role or by a + currently enabled role. There is one row for each combination of function, + grantor, and grantee. +

Table 34-37. routine_privileges Columns

NameData TypeDescription
grantorsql_identifierName of the role that granted the privilege
granteesql_identifierName of the role that the privilege was granted to
specific_catalogsql_identifierName of the database containing the function (always the current database)
specific_schemasql_identifierName of the schema containing the function
specific_namesql_identifier The "specific name" of the function. See Section 34.40 for more information. +
routine_catalogsql_identifierName of the database containing the function (always the current database)
routine_schemasql_identifierName of the schema containing the function
routine_namesql_identifierName of the function (might be duplicated in case of overloading)
privilege_typecharacter_dataAlways EXECUTE (the only privilege type for functions)
is_grantableyes_or_noYES if the privilege is grantable, NO if not

PrevHomeNext
role_usage_grantsUproutines
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-routines.html b/doc/src/sgml/html/infoschema-routines.html new file mode 100644 index 000000000..82f3bac18 --- /dev/null +++ b/doc/src/sgml/html/infoschema-routines.html @@ -0,0 +1,1678 @@ + +routines
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.40. routines

The view routines contains all functions in the + current database. Only those functions are shown that the current + user has access to (by way of being the owner or having some + privilege). +

Table 34-38. routines Columns

NameData TypeDescription
specific_catalogsql_identifierName of the database containing the function (always the current database)
specific_schemasql_identifierName of the schema containing the function
specific_namesql_identifier The "specific name" of the function. This is a + name that uniquely identifies the function in the schema, even + if the real name of the function is overloaded. The format of + the specific name is not defined, it should only be used to + compare it to other instances of specific routine names. +
routine_catalogsql_identifierName of the database containing the function (always the current database)
routine_schemasql_identifierName of the schema containing the function
routine_namesql_identifierName of the function (might be duplicated in case of overloading)
routine_typecharacter_data Always FUNCTION (In the future there might + be other types of routines.) +
module_catalogsql_identifierApplies to a feature not available in PostgreSQL
module_schemasql_identifierApplies to a feature not available in PostgreSQL
module_namesql_identifierApplies to a feature not available in PostgreSQL
udt_catalogsql_identifierApplies to a feature not available in PostgreSQL
udt_schemasql_identifierApplies to a feature not available in PostgreSQL
udt_namesql_identifierApplies to a feature not available in PostgreSQL
data_typecharacter_data Return data type of the function, if it is a built-in type, or + ARRAY if it is some array (in that case, see + the view element_types), else + USER-DEFINED (in that case, the type is + identified in type_udt_name and associated + columns). +
character_maximum_lengthcardinal_numberAlways null, since this information is not applied to return data types in PostgreSQL
character_octet_lengthcardinal_numberAlways null, since this information is not applied to return data types in PostgreSQL
character_set_catalogsql_identifierApplies to a feature not available in PostgreSQL
character_set_schemasql_identifierApplies to a feature not available in PostgreSQL
character_set_namesql_identifierApplies to a feature not available in PostgreSQL
collation_catalogsql_identifierAlways null, since this information is not applied to return data types in PostgreSQL
collation_schemasql_identifierAlways null, since this information is not applied to return data types in PostgreSQL
collation_namesql_identifierAlways null, since this information is not applied to return data types in PostgreSQL
numeric_precisioncardinal_numberAlways null, since this information is not applied to return data types in PostgreSQL
numeric_precision_radixcardinal_numberAlways null, since this information is not applied to return data types in PostgreSQL
numeric_scalecardinal_numberAlways null, since this information is not applied to return data types in PostgreSQL
datetime_precisioncardinal_numberAlways null, since this information is not applied to return data types in PostgreSQL
interval_typecharacter_dataAlways null, since this information is not applied to return data types in PostgreSQL
interval_precisioncardinal_numberAlways null, since this information is not applied to return data types in PostgreSQL
type_udt_catalogsql_identifier Name of the database that the return data type of the function + is defined in (always the current database) +
type_udt_schemasql_identifier Name of the schema that the return data type of the function is + defined in +
type_udt_namesql_identifier Name of the return data type of the function +
scope_catalogsql_identifierApplies to a feature not available in PostgreSQL
scope_schemasql_identifierApplies to a feature not available in PostgreSQL
scope_namesql_identifierApplies to a feature not available in PostgreSQL
maximum_cardinalitycardinal_numberAlways null, because arrays always have unlimited maximum cardinality in PostgreSQL
dtd_identifiersql_identifier An identifier of the data type descriptor of the return data + type of this function, unique among the data type descriptors + pertaining to the function. This is mainly useful for joining + with other instances of such identifiers. (The specific format + of the identifier is not defined and not guaranteed to remain + the same in future versions.) +
routine_bodycharacter_data If the function is an SQL function, then + SQL, else EXTERNAL. +
routine_definitioncharacter_data The source text of the function (null if the function is not + owned by a currently enabled role). (According to the SQL + standard, this column is only applicable if + routine_body is SQL, but + in PostgreSQL it will contain + whatever source text was specified when the function was + created.) +
external_namecharacter_data If this function is a C function, then the external name (link + symbol) of the function; else null. (This works out to be the + same value that is shown in + routine_definition.) +
external_languagecharacter_dataThe language the function is written in
parameter_stylecharacter_data Always GENERAL (The SQL standard defines + other parameter styles, which are not available in PostgreSQL.) +
is_deterministicyes_or_no If the function is declared immutable (called deterministic in + the SQL standard), then YES, else + NO. (You cannot query the other volatility + levels available in PostgreSQL through the information schema.) +
sql_data_accesscharacter_data Always MODIFIES, meaning that the function + possibly modifies SQL data. This information is not useful for + PostgreSQL. +
is_null_callyes_or_no If the function automatically returns null if any of its + arguments are null, then YES, else + NO. +
sql_pathcharacter_dataApplies to a feature not available in PostgreSQL
schema_level_routineyes_or_no Always YES (The opposite would be a method + of a user-defined type, which is a feature not available in + PostgreSQL.) +
max_dynamic_result_setscardinal_numberApplies to a feature not available in PostgreSQL
is_user_defined_castyes_or_noApplies to a feature not available in PostgreSQL
is_implicitly_invocableyes_or_noApplies to a feature not available in PostgreSQL
security_typecharacter_data If the function runs with the privileges of the current user, + then INVOKER, if the function runs with the + privileges of the user who defined it, then + DEFINER. +
to_sql_specific_catalogsql_identifierApplies to a feature not available in PostgreSQL
to_sql_specific_schemasql_identifierApplies to a feature not available in PostgreSQL
to_sql_specific_namesql_identifierApplies to a feature not available in PostgreSQL
as_locatoryes_or_noApplies to a feature not available in PostgreSQL
createdtime_stampApplies to a feature not available in PostgreSQL
last_alteredtime_stampApplies to a feature not available in PostgreSQL
new_savepoint_levelyes_or_noApplies to a feature not available in PostgreSQL
is_udt_dependentyes_or_no Currently always NO. The alternative + YES applies to a feature not available in + PostgreSQL. +
result_cast_from_data_typecharacter_dataApplies to a feature not available in PostgreSQL
result_cast_as_locatoryes_or_noApplies to a feature not available in PostgreSQL
result_cast_char_max_lengthcardinal_numberApplies to a feature not available in PostgreSQL
result_cast_char_octet_lengthcharacter_dataApplies to a feature not available in PostgreSQL
result_cast_char_set_catalogsql_identifierApplies to a feature not available in PostgreSQL
result_cast_char_set_schemasql_identifierApplies to a feature not available in PostgreSQL
result_cast_char_set_namesql_identifierApplies to a feature not available in PostgreSQL
result_cast_collation_catalogsql_identifierApplies to a feature not available in PostgreSQL
result_cast_collation_schemasql_identifierApplies to a feature not available in PostgreSQL
result_cast_collation_namesql_identifierApplies to a feature not available in PostgreSQL
result_cast_numeric_precisioncardinal_numberApplies to a feature not available in PostgreSQL
result_cast_numeric_precision_radixcardinal_numberApplies to a feature not available in PostgreSQL
result_cast_numeric_scalecardinal_numberApplies to a feature not available in PostgreSQL
result_cast_datetime_precisioncharacter_dataApplies to a feature not available in PostgreSQL
result_cast_interval_typecharacter_dataApplies to a feature not available in PostgreSQL
result_cast_interval_precisioncardinal_numberApplies to a feature not available in PostgreSQL
result_cast_type_udt_catalogsql_identifierApplies to a feature not available in PostgreSQL
result_cast_type_udt_schemasql_identifierApplies to a feature not available in PostgreSQL
result_cast_type_udt_namesql_identifierApplies to a feature not available in PostgreSQL
result_cast_scope_catalogsql_identifierApplies to a feature not available in PostgreSQL
result_cast_scope_schemasql_identifierApplies to a feature not available in PostgreSQL
result_cast_scope_namesql_identifierApplies to a feature not available in PostgreSQL
result_cast_maximum_cardinalitycardinal_numberApplies to a feature not available in PostgreSQL
result_cast_dtd_identifiersql_identifierApplies to a feature not available in PostgreSQL

PrevHomeNext
routine_privilegesUpschemata
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-schema.html b/doc/src/sgml/html/infoschema-schema.html new file mode 100644 index 000000000..96be4bdc0 --- /dev/null +++ b/doc/src/sgml/html/infoschema-schema.html @@ -0,0 +1,182 @@ + +The Schema
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.1. The Schema

The information schema itself is a schema named + information_schema. This schema automatically + exists in all databases. The owner of this schema is the initial + database user in the cluster, and that user naturally has all the + privileges on this schema, including the ability to drop it (but + the space savings achieved by that are minuscule). +

By default, the information schema is not in the schema search + path, so you need to access all objects in it through qualified + names. Since the names of some of the objects in the information + schema are generic names that might occur in user applications, you + should be careful if you want to put the information schema in the + path. +


PrevHomeNext
The Information SchemaUpData Types
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-schemata.html b/doc/src/sgml/html/infoschema-schemata.html new file mode 100644 index 000000000..97dc0c777 --- /dev/null +++ b/doc/src/sgml/html/infoschema-schemata.html @@ -0,0 +1,318 @@ + +schemata
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.41. schemata

The view schemata contains all schemas in the + current database that are owned by a currently enabled role. +

Table 34-39. schemata Columns

NameData TypeDescription
catalog_namesql_identifierName of the database that the schema is contained in (always the current database)
schema_namesql_identifierName of the schema
schema_ownersql_identifierName of the owner of the schema
default_character_set_catalogsql_identifierApplies to a feature not available in PostgreSQL
default_character_set_schemasql_identifierApplies to a feature not available in PostgreSQL
default_character_set_namesql_identifierApplies to a feature not available in PostgreSQL
sql_pathcharacter_dataApplies to a feature not available in PostgreSQL

PrevHomeNext
routinesUpsequences
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-sequences.html b/doc/src/sgml/html/infoschema-sequences.html new file mode 100644 index 000000000..9f78e0c99 --- /dev/null +++ b/doc/src/sgml/html/infoschema-sequences.html @@ -0,0 +1,424 @@ + +sequences
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.42. sequences

The view sequences contains all sequences + defined in the current database. Only those sequences are shown + that the current user has access to (by way of being the owner or + having some privilege). +

Table 34-40. sequences Columns

NameData TypeDescription
sequence_catalogsql_identifierName of the database that contains the sequence (always the current database)
sequence_schemasql_identifierName of the schema that contains the sequence
sequence_namesql_identifierName of the sequence
data_typecharacter_data The data type of the sequence. In + PostgreSQL, this is currently always + bigint. +
numeric_precisioncardinal_number This column contains the (declared or implicit) precision of + the sequence data type (see above). The precision indicates + the number of significant digits. It can be expressed in + decimal (base 10) or binary (base 2) terms, as specified in the + column numeric_precision_radix. +
numeric_precision_radixcardinal_number This column indicates in which base the values in the columns + numeric_precision and + numeric_scale are expressed. The value is + either 2 or 10. +
numeric_scalecardinal_number This column contains the (declared or implicit) scale of the + sequence data type (see above). The scale indicates the number + of significant digits to the right of the decimal point. It + can be expressed in decimal (base 10) or binary (base 2) terms, + as specified in the column + numeric_precision_radix. +
start_valuecharacter_dataThe start value of the sequence
minimum_valuecharacter_dataThe minimum value of the sequence
maximum_valuecharacter_dataThe maximum value of the sequence
incrementcharacter_dataThe increment of the sequence
cycle_optionyes_or_noYES if the sequence cycles, else NO

Note that in accordance with the SQL standard, the start, minimum, + maximum, and increment values are returned as character strings. +


PrevHomeNext
schemataUpsql_features
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-sql-features.html b/doc/src/sgml/html/infoschema-sql-features.html new file mode 100644 index 000000000..d604637a5 --- /dev/null +++ b/doc/src/sgml/html/infoschema-sql-features.html @@ -0,0 +1,331 @@ + +sql_features
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.43. sql_features

The table sql_features contains information + about which formal features defined in the SQL standard are + supported by PostgreSQL. This is the + same information that is presented in Appendix D. + There you can also find some additional background information. +

Table 34-41. sql_features Columns

NameData TypeDescription
feature_idcharacter_dataIdentifier string of the feature
feature_namecharacter_dataDescriptive name of the feature
sub_feature_idcharacter_dataIdentifier string of the subfeature, or a zero-length string if not a subfeature
sub_feature_namecharacter_dataDescriptive name of the subfeature, or a zero-length string if not a subfeature
is_supportedyes_or_no YES if the feature is fully supported by the + current version of PostgreSQL, NO if not +
is_verified_bycharacter_data Always null, since the PostgreSQL development group does not + perform formal testing of feature conformance +
commentscharacter_dataPossibly a comment about the supported status of the feature

PrevHomeNext
sequencesUpsql_implementation_info
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-sql-implementation-info.html b/doc/src/sgml/html/infoschema-sql-implementation-info.html new file mode 100644 index 000000000..22a363497 --- /dev/null +++ b/doc/src/sgml/html/infoschema-sql-implementation-info.html @@ -0,0 +1,296 @@ + +sql_implementation_info
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.44. sql_implementation_info

The table sql_implementation_info contains + information about various aspects that are left + implementation-defined by the SQL standard. This information is + primarily intended for use in the context of the ODBC interface; + users of other interfaces will probably find this information to be + of little use. For this reason, the individual implementation + information items are not described here; you will find them in the + description of the ODBC interface. +

Table 34-42. sql_implementation_info Columns

NameData TypeDescription
implementation_info_idcharacter_dataIdentifier string of the implementation information item
implementation_info_namecharacter_dataDescriptive name of the implementation information item
integer_valuecardinal_number Value of the implementation information item, or null if the + value is contained in the column + character_value +
character_valuecharacter_data Value of the implementation information item, or null if the + value is contained in the column + integer_value +
commentscharacter_dataPossibly a comment pertaining to the implementation information item

PrevHomeNext
sql_featuresUpsql_languages
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-sql-languages.html b/doc/src/sgml/html/infoschema-sql-languages.html new file mode 100644 index 000000000..41990e31f --- /dev/null +++ b/doc/src/sgml/html/infoschema-sql-languages.html @@ -0,0 +1,351 @@ + +sql_languages
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.45. sql_languages

The table sql_languages contains one row for + each SQL language binding that is supported by + PostgreSQL. + PostgreSQL supports direct SQL and + embedded SQL in C; that is all you will learn from this table. +

This table was removed from the SQL standard in SQL:2008, so there + are no entries referring to standards later than SQL:2003. +

Table 34-43. sql_languages Columns

NameData TypeDescription
sql_language_sourcecharacter_data The name of the source of the language definition; always + ISO 9075, that is, the SQL standard +
sql_language_yearcharacter_data The year the standard referenced in + sql_language_source was approved. +
sql_language_conformancecharacter_data The standard conformance level for the language binding. For + ISO 9075:2003 this is always CORE. +
sql_language_integritycharacter_dataAlways null (This value is relevant to an earlier version of the SQL standard.)
sql_language_implementationcharacter_dataAlways null
sql_language_binding_stylecharacter_data The language binding style, either DIRECT or + EMBEDDED +
sql_language_programming_languagecharacter_data The programming language, if the binding style is + EMBEDDED, else null. PostgreSQL only + supports the language C. +

PrevHomeNext
sql_implementation_infoUpsql_packages
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-sql-packages.html b/doc/src/sgml/html/infoschema-sql-packages.html new file mode 100644 index 000000000..3262b0864 --- /dev/null +++ b/doc/src/sgml/html/infoschema-sql-packages.html @@ -0,0 +1,301 @@ + +sql_packages
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.46. sql_packages

The table sql_packages contains information + about which feature packages defined in the SQL standard are + supported by PostgreSQL. Refer to Appendix D for background information on feature packages. +

Table 34-44. sql_packages Columns

NameData TypeDescription
feature_idcharacter_dataIdentifier string of the package
feature_namecharacter_dataDescriptive name of the package
is_supportedyes_or_no YES if the package is fully supported by the + current version of PostgreSQL, NO if not +
is_verified_bycharacter_data Always null, since the PostgreSQL development group does not + perform formal testing of feature conformance +
commentscharacter_dataPossibly a comment about the supported status of the package

PrevHomeNext
sql_languagesUpsql_parts
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-sql-parts.html b/doc/src/sgml/html/infoschema-sql-parts.html new file mode 100644 index 000000000..c105dee0d --- /dev/null +++ b/doc/src/sgml/html/infoschema-sql-parts.html @@ -0,0 +1,299 @@ + +sql_parts
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.47. sql_parts

The table sql_parts contains information about + which of the several parts of the SQL standard are supported by + PostgreSQL. +

Table 34-45. sql_parts Columns

NameData TypeDescription
feature_idcharacter_dataAn identifier string containing the number of the part
feature_namecharacter_dataDescriptive name of the part
is_supportedyes_or_no YES if the part is fully supported by the + current version of PostgreSQL, + NO if not +
is_verified_bycharacter_data Always null, since the PostgreSQL development group does not + perform formal testing of feature conformance +
commentscharacter_dataPossibly a comment about the supported status of the part

PrevHomeNext
sql_packagesUpsql_sizing
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-sql-sizing-profiles.html b/doc/src/sgml/html/infoschema-sql-sizing-profiles.html new file mode 100644 index 000000000..90d5b356c --- /dev/null +++ b/doc/src/sgml/html/infoschema-sql-sizing-profiles.html @@ -0,0 +1,290 @@ + +sql_sizing_profiles
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.49. sql_sizing_profiles

The table sql_sizing_profiles contains + information about the sql_sizing values that are + required by various profiles of the SQL standard. PostgreSQL does + not track any SQL profiles, so this table is empty. +

Table 34-47. sql_sizing_profiles Columns

NameData TypeDescription
sizing_idcardinal_numberIdentifier of the sizing item
sizing_namecharacter_dataDescriptive name of the sizing item
profile_idcharacter_dataIdentifier string of a profile
required_valuecardinal_number The value required by the SQL profile for the sizing item, or 0 + if the profile places no limit on the sizing item, or null if + the profile does not require any of the features for which the + sizing item is applicable +
commentscharacter_dataPossibly a comment pertaining to the sizing item within the profile

PrevHomeNext
sql_sizingUptable_constraints
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-sql-sizing.html b/doc/src/sgml/html/infoschema-sql-sizing.html new file mode 100644 index 000000000..e65574914 --- /dev/null +++ b/doc/src/sgml/html/infoschema-sql-sizing.html @@ -0,0 +1,276 @@ + +sql_sizing
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.48. sql_sizing

The table sql_sizing contains information about + various size limits and maximum values in + PostgreSQL. This information is + primarily intended for use in the context of the ODBC interface; + users of other interfaces will probably find this information to be + of little use. For this reason, the individual sizing items are + not described here; you will find them in the description of the + ODBC interface. +

Table 34-46. sql_sizing Columns

NameData TypeDescription
sizing_idcardinal_numberIdentifier of the sizing item
sizing_namecharacter_dataDescriptive name of the sizing item
supported_valuecardinal_number Value of the sizing item, or 0 if the size is unlimited or + cannot be determined, or null if the features for which the + sizing item is applicable are not supported +
commentscharacter_dataPossibly a comment pertaining to the sizing item

PrevHomeNext
sql_partsUpsql_sizing_profiles
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-table-constraints.html b/doc/src/sgml/html/infoschema-table-constraints.html new file mode 100644 index 000000000..1a54dd497 --- /dev/null +++ b/doc/src/sgml/html/infoschema-table-constraints.html @@ -0,0 +1,365 @@ + +table_constraints
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.50. table_constraints

The view table_constraints contains all + constraints belonging to tables that the current user owns or has + some privilege other than SELECT on. +

Table 34-48. table_constraints Columns

NameData TypeDescription
constraint_catalogsql_identifierName of the database that contains the constraint (always the current database)
constraint_schemasql_identifierName of the schema that contains the constraint
constraint_namesql_identifierName of the constraint
table_catalogsql_identifierName of the database that contains the table (always the current database)
table_schemasql_identifierName of the schema that contains the table
table_namesql_identifierName of the table
constraint_typecharacter_data Type of the constraint: CHECK, + FOREIGN KEY, PRIMARY KEY, + or UNIQUE +
is_deferrableyes_or_noYES if the constraint is deferrable, NO if not
initially_deferredyes_or_noYES if the constraint is deferrable and initially deferred, NO if not

PrevHomeNext
sql_sizing_profilesUptable_privileges
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-table-privileges.html b/doc/src/sgml/html/infoschema-table-privileges.html new file mode 100644 index 000000000..0eed50c2d --- /dev/null +++ b/doc/src/sgml/html/infoschema-table-privileges.html @@ -0,0 +1,374 @@ + +table_privileges
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.51. table_privileges

The view table_privileges identifies all + privileges granted on tables or views to a currently enabled role + or by a currently enabled role. There is one row for each + combination of table, grantor, and grantee. +

Table 34-49. table_privileges Columns

NameData TypeDescription
grantorsql_identifierName of the role that granted the privilege
granteesql_identifierName of the role that the privilege was granted to
table_catalogsql_identifierName of the database that contains the table (always the current database)
table_schemasql_identifierName of the schema that contains the table
table_namesql_identifierName of the table
privilege_typecharacter_data Type of the privilege: SELECT, + INSERT, UPDATE, + DELETE, TRUNCATE, + REFERENCES, or TRIGGER +
is_grantableyes_or_noYES if the privilege is grantable, NO if not
with_hierarchyyes_or_no In the SQL standard, WITH HIERARCHY OPTION + is a separate (sub-)privilege allowing certain operations on + table inheritance hierarchies. In PostgreSQL, this is included + in the SELECT privilege, so this column + shows YES if the privilege + is SELECT, else NO. +

PrevHomeNext
table_constraintsUptables
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-tables.html b/doc/src/sgml/html/infoschema-tables.html new file mode 100644 index 000000000..8d8f300e8 --- /dev/null +++ b/doc/src/sgml/html/infoschema-tables.html @@ -0,0 +1,423 @@ + +tables
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.52. tables

The view tables contains all tables and views + defined in the current database. Only those tables and views are + shown that the current user has access to (by way of being the + owner or having some privilege). +

Table 34-50. tables Columns

NameData TypeDescription
table_catalogsql_identifierName of the database that contains the table (always the current database)
table_schemasql_identifierName of the schema that contains the table
table_namesql_identifierName of the table
table_typecharacter_data Type of the table: BASE TABLE for a + persistent base table (the normal table type), + VIEW for a view, FOREIGN TABLE + for a foreign table, or + LOCAL TEMPORARY for a temporary table +
self_referencing_column_namesql_identifierApplies to a feature not available in PostgreSQL
reference_generationcharacter_dataApplies to a feature not available in PostgreSQL
user_defined_type_catalogsql_identifier If the table is a typed table, the name of the database that + contains the underlying data type (always the current + database), else null. +
user_defined_type_schemasql_identifier If the table is a typed table, the name of the schema that + contains the underlying data type, else null. +
user_defined_type_namesql_identifier If the table is a typed table, the name of the underlying data + type, else null. +
is_insertable_intoyes_or_no YES if the table is insertable into, + NO if not (Base tables are always insertable + into, views not necessarily.) +
is_typedyes_or_noYES if the table is a typed table, NO if not
commit_actioncharacter_dataNot yet implemented

PrevHomeNext
table_privilegesUptriggered_update_columns
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-triggered-update-columns.html b/doc/src/sgml/html/infoschema-triggered-update-columns.html new file mode 100644 index 000000000..4e390308e --- /dev/null +++ b/doc/src/sgml/html/infoschema-triggered-update-columns.html @@ -0,0 +1,319 @@ + +triggered_update_columns
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.53. triggered_update_columns

For triggers in the current database that specify a column list + (like UPDATE OF column1, column2), the + view triggered_update_columns identifies these + columns. Triggers that do not specify a column list are not + included in this view. Only those columns are shown that the + current user owns or has some privilege other than + SELECT on. +

Table 34-51. triggered_update_columns Columns

NameData TypeDescription
trigger_catalogsql_identifierName of the database that contains the trigger (always the current database)
trigger_schemasql_identifierName of the schema that contains the trigger
trigger_namesql_identifierName of the trigger
event_object_catalogsql_identifier Name of the database that contains the table that the trigger + is defined on (always the current database) +
event_object_schemasql_identifierName of the schema that contains the table that the trigger is defined on
event_object_tablesql_identifierName of the table that the trigger is defined on
event_object_columnsql_identifierName of the column that the trigger is defined on

PrevHomeNext
tablesUptriggers
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-triggers.html b/doc/src/sgml/html/infoschema-triggers.html new file mode 100644 index 000000000..db341fdaf --- /dev/null +++ b/doc/src/sgml/html/infoschema-triggers.html @@ -0,0 +1,625 @@ + +triggers
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.54. triggers

The view triggers contains all triggers defined + in the current database on tables and views that the current user owns + or has some privilege other than SELECT on. +

Table 34-52. triggers Columns

NameData TypeDescription
trigger_catalogsql_identifierName of the database that contains the trigger (always the current database)
trigger_schemasql_identifierName of the schema that contains the trigger
trigger_namesql_identifierName of the trigger
event_manipulationcharacter_data Event that fires the trigger (INSERT, + UPDATE, or DELETE) +
event_object_catalogsql_identifier Name of the database that contains the table that the trigger + is defined on (always the current database) +
event_object_schemasql_identifierName of the schema that contains the table that the trigger is defined on
event_object_tablesql_identifierName of the table that the trigger is defined on
action_ordercardinal_numberNot yet implemented
action_conditioncharacter_data WHEN condition of the trigger, null if none + (also null if the table is not owned by a currently enabled + role) +
action_statementcharacter_data Statement that is executed by the trigger (currently always + EXECUTE PROCEDURE + function(...)) +
action_orientationcharacter_data Identifies whether the trigger fires once for each processed + row or once for each statement (ROW or + STATEMENT) +
action_timingcharacter_data Time at which the trigger fires (BEFORE, + AFTER, or INSTEAD OF) +
action_reference_old_tablesql_identifierApplies to a feature not available in PostgreSQL
action_reference_new_tablesql_identifierApplies to a feature not available in PostgreSQL
action_reference_old_rowsql_identifierApplies to a feature not available in PostgreSQL
action_reference_new_rowsql_identifierApplies to a feature not available in PostgreSQL
createdtime_stampApplies to a feature not available in PostgreSQL

Triggers in PostgreSQL have two + incompatibilities with the SQL standard that affect the + representation in the information schema. First, trigger names are + local to each table in PostgreSQL, rather + than being independent schema objects. Therefore there can be duplicate + trigger names defined in one schema, so long as they belong to + different tables. (trigger_catalog and + trigger_schema are really the values pertaining + to the table that the trigger is defined on.) Second, triggers can + be defined to fire on multiple events in + PostgreSQL (e.g., ON INSERT OR + UPDATE), whereas the SQL standard only allows one. If a + trigger is defined to fire on multiple events, it is represented as + multiple rows in the information schema, one for each type of + event. As a consequence of these two issues, the primary key of + the view triggers is really + (trigger_catalog, trigger_schema, event_object_table, + trigger_name, event_manipulation) instead of + (trigger_catalog, trigger_schema, trigger_name), + which is what the SQL standard specifies. Nonetheless, if you + define your triggers in a manner that conforms with the SQL + standard (trigger names unique in the schema and only one event + type per trigger), this will not affect you. +

Note: Prior to PostgreSQL 9.1, this view's columns + action_timing, + action_reference_old_table, + action_reference_new_table, + action_reference_old_row, and + action_reference_new_row + were named + condition_timing, + condition_reference_old_table, + condition_reference_new_table, + condition_reference_old_row, and + condition_reference_new_row + respectively. + That was how they were named in the SQL:1999 standard. + The new naming conforms to SQL:2003 and later. +


PrevHomeNext
triggered_update_columnsUpudt_privileges
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-udt-privileges.html b/doc/src/sgml/html/infoschema-udt-privileges.html new file mode 100644 index 000000000..5b14ea3fc --- /dev/null +++ b/doc/src/sgml/html/infoschema-udt-privileges.html @@ -0,0 +1,329 @@ + +udt_privileges
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.55. udt_privileges

The view udt_privileges identifies + USAGE privileges granted on user-defined types to a + currently enabled role or by a currently enabled role. There is one row for + each combination of column, grantor, and grantee. This view shows only + composite types (see under Section 34.57 + for why); see + Section 34.56 for domain privileges. +

Table 34-53. udt_privileges Columns

NameData TypeDescription
grantorsql_identifierName of the role that granted the privilege
granteesql_identifierName of the role that the privilege was granted to
udt_catalogsql_identifierName of the database containing the type (always the current database)
udt_schemasql_identifierName of the schema containing the type
udt_namesql_identifierName of the type
privilege_typecharacter_dataAlways TYPE USAGE
is_grantableyes_or_noYES if the privilege is grantable, NO if not

PrevHomeNext
triggersUpusage_privileges
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-usage-privileges.html b/doc/src/sgml/html/infoschema-usage-privileges.html new file mode 100644 index 000000000..ae4bdf1fb --- /dev/null +++ b/doc/src/sgml/html/infoschema-usage-privileges.html @@ -0,0 +1,386 @@ + +usage_privileges
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.56. usage_privileges

The view usage_privileges identifies + USAGE privileges granted on various kinds of + objects to a currently enabled role or by a currently enabled role. + In PostgreSQL, this currently applies to + collations, domains, foreign-data wrappers, foreign servers, and sequences. There is one + row for each combination of object, grantor, and grantee. +

Since collations do not have real privileges + in PostgreSQL, this view shows implicit + non-grantable USAGE privileges granted by the + owner to PUBLIC for all collations. The other + object types, however, show real privileges. +

In PostgreSQL, sequences also support SELECT + and UPDATE privileges in addition to + the USAGE privilege. These are nonstandard and therefore + not visible in the information schema. +

Table 34-54. usage_privileges Columns

NameData TypeDescription
grantorsql_identifierName of the role that granted the privilege
granteesql_identifierName of the role that the privilege was granted to
object_catalogsql_identifierName of the database containing the object (always the current database)
object_schemasql_identifierName of the schema containing the object, if applicable, + else an empty string
object_namesql_identifierName of the object
object_typecharacter_dataCOLLATION or DOMAIN or FOREIGN DATA WRAPPER or FOREIGN SERVER or SEQUENCE
privilege_typecharacter_dataAlways USAGE
is_grantableyes_or_noYES if the privilege is grantable, NO if not

PrevHomeNext
udt_privilegesUpuser_defined_types
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-user-defined-types.html b/doc/src/sgml/html/infoschema-user-defined-types.html new file mode 100644 index 000000000..24423e477 --- /dev/null +++ b/doc/src/sgml/html/infoschema-user-defined-types.html @@ -0,0 +1,722 @@ + +user_defined_types
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.57. user_defined_types

The view user_defined_types currently contains + all composite types defined in the current database. + Only those types are shown that the current user has access to (by way + of being the owner or having some privilege). +

SQL knows about two kinds of user-defined types: structured types + (also known as composite types + in PostgreSQL) and distinct types (not + implemented in PostgreSQL). To be + future-proof, use the + column user_defined_type_category to + differentiate between these. Other user-defined types such as base + types and enums, which are PostgreSQL + extensions, are not shown here. For domains, + see Section 34.22 instead. +

Table 34-55. user_defined_types Columns

NameData TypeDescription
user_defined_type_catalogsql_identifierName of the database that contains the type (always the current database)
user_defined_type_schemasql_identifierName of the schema that contains the type
user_defined_type_namesql_identifierName of the type
user_defined_type_categorycharacter_data Currently always STRUCTURED +
is_instantiableyes_or_noApplies to a feature not available in PostgreSQL
is_finalyes_or_noApplies to a feature not available in PostgreSQL
ordering_formcharacter_dataApplies to a feature not available in PostgreSQL
ordering_categorycharacter_dataApplies to a feature not available in PostgreSQL
ordering_routine_catalogsql_identifierApplies to a feature not available in PostgreSQL
ordering_routine_schemasql_identifierApplies to a feature not available in PostgreSQL
ordering_routine_namesql_identifierApplies to a feature not available in PostgreSQL
reference_typecharacter_dataApplies to a feature not available in PostgreSQL
data_typecharacter_dataApplies to a feature not available in PostgreSQL
character_maximum_lengthcardinal_numberApplies to a feature not available in PostgreSQL
character_octet_lengthcardinal_numberApplies to a feature not available in PostgreSQL
character_set_catalogsql_identifierApplies to a feature not available in PostgreSQL
character_set_schemasql_identifierApplies to a feature not available in PostgreSQL
character_set_namesql_identifierApplies to a feature not available in PostgreSQL
collation_catalogsql_identifierApplies to a feature not available in PostgreSQL
collation_schemasql_identifierApplies to a feature not available in PostgreSQL
collation_namesql_identifierApplies to a feature not available in PostgreSQL
numeric_precisioncardinal_numberApplies to a feature not available in PostgreSQL
numeric_precision_radixcardinal_numberApplies to a feature not available in PostgreSQL
numeric_scalecardinal_numberApplies to a feature not available in PostgreSQL
datetime_precisioncardinal_numberApplies to a feature not available in PostgreSQL
interval_typecharacter_dataApplies to a feature not available in PostgreSQL
interval_precisioncardinal_numberApplies to a feature not available in PostgreSQL
source_dtd_identifiersql_identifierApplies to a feature not available in PostgreSQL
ref_dtd_identifiersql_identifierApplies to a feature not available in PostgreSQL

PrevHomeNext
usage_privilegesUpuser_mapping_options
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-user-mapping-options.html b/doc/src/sgml/html/infoschema-user-mapping-options.html new file mode 100644 index 000000000..bb4fa3e8b --- /dev/null +++ b/doc/src/sgml/html/infoschema-user-mapping-options.html @@ -0,0 +1,294 @@ + +user_mapping_options
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.58. user_mapping_options

The view user_mapping_options contains all the + options defined for user mappings in the current database. Only + those user mappings are shown where the current user has access to + the corresponding foreign server (by way of being the owner or + having some privilege). +

Table 34-56. user_mapping_options Columns

NameData TypeDescription
authorization_identifiersql_identifierName of the user being mapped, + or PUBLIC if the mapping is public
foreign_server_catalogsql_identifierName of the database that the foreign server used by this + mapping is defined in (always the current database)
foreign_server_namesql_identifierName of the foreign server used by this mapping
option_namesql_identifierName of an option
option_valuecharacter_dataValue of the option. This column will show as null + unless the current user is the user being mapped, or the mapping + is for PUBLIC and the current user is the + server owner, or the current user is a superuser. The intent is + to protect password information stored as user mapping + option.

PrevHomeNext
user_defined_typesUpuser_mappings
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-user-mappings.html b/doc/src/sgml/html/infoschema-user-mappings.html new file mode 100644 index 000000000..8b48ee031 --- /dev/null +++ b/doc/src/sgml/html/infoschema-user-mappings.html @@ -0,0 +1,258 @@ + +user_mappings
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.59. user_mappings

The view user_mappings contains all user + mappings defined in the current database. Only those user mappings + are shown where the current user has access to the corresponding + foreign server (by way of being the owner or having some + privilege). +

Table 34-57. user_mappings Columns

NameData TypeDescription
authorization_identifiersql_identifierName of the user being mapped, + or PUBLIC if the mapping is public
foreign_server_catalogsql_identifierName of the database that the foreign server used by this + mapping is defined in (always the current database)
foreign_server_namesql_identifierName of the foreign server used by this mapping

PrevHomeNext
user_mapping_optionsUpview_column_usage
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-view-column-usage.html b/doc/src/sgml/html/infoschema-view-column-usage.html new file mode 100644 index 000000000..20f5bc6d2 --- /dev/null +++ b/doc/src/sgml/html/infoschema-view-column-usage.html @@ -0,0 +1,330 @@ + +view_column_usage
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.60. view_column_usage

The view view_column_usage identifies all + columns that are used in the query expression of a view (the + SELECT statement that defines the view). A + column is only included if the table that contains the column is + owned by a currently enabled role. +

Note: Columns of system tables are not included. This should be fixed + sometime. +

Table 34-58. view_column_usage Columns

NameData TypeDescription
view_catalogsql_identifierName of the database that contains the view (always the current database)
view_schemasql_identifierName of the schema that contains the view
view_namesql_identifierName of the view
table_catalogsql_identifier Name of the database that contains the table that contains the + column that is used by the view (always the current database) +
table_schemasql_identifier Name of the schema that contains the table that contains the + column that is used by the view +
table_namesql_identifier Name of the table that contains the column that is used by the + view +
column_namesql_identifierName of the column that is used by the view

PrevHomeNext
user_mappingsUpview_routine_usage
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-view-routine-usage.html b/doc/src/sgml/html/infoschema-view-routine-usage.html new file mode 100644 index 000000000..2bae51a95 --- /dev/null +++ b/doc/src/sgml/html/infoschema-view-routine-usage.html @@ -0,0 +1,305 @@ + +view_routine_usage
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.61. view_routine_usage

The view view_routine_usage identifies all + routines (functions and procedures) that are used in the query + expression of a view (the SELECT statement that + defines the view). A routine is only included if that routine is + owned by a currently enabled role. +

Table 34-59. view_routine_usage Columns

NameData TypeDescription
table_catalogsql_identifierName of the database containing the view (always the current database)
table_schemasql_identifierName of the schema containing the view
table_namesql_identifierName of the view
specific_catalogsql_identifierName of the database containing the function (always the current database)
specific_schemasql_identifierName of the schema containing the function
specific_namesql_identifier The "specific name" of the function. See Section 34.40 for more information. +

PrevHomeNext
view_column_usageUpview_table_usage
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-view-table-usage.html b/doc/src/sgml/html/infoschema-view-table-usage.html new file mode 100644 index 000000000..243d9c7e8 --- /dev/null +++ b/doc/src/sgml/html/infoschema-view-table-usage.html @@ -0,0 +1,314 @@ + +view_table_usage
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.62. view_table_usage

The view view_table_usage identifies all tables + that are used in the query expression of a view (the + SELECT statement that defines the view). A + table is only included if that table is owned by a currently + enabled role. +

Note: System tables are not included. This should be fixed sometime. +

Table 34-60. view_table_usage Columns

NameData TypeDescription
view_catalogsql_identifierName of the database that contains the view (always the current database)
view_schemasql_identifierName of the schema that contains the view
view_namesql_identifierName of the view
table_catalogsql_identifier Name of the database that contains the table that is + used by the view (always the current database) +
table_schemasql_identifier Name of the schema that contains the table that is used by the + view +
table_namesql_identifier Name of the table that is used by the view +

PrevHomeNext
view_routine_usageUpviews
\ No newline at end of file diff --git a/doc/src/sgml/html/infoschema-views.html b/doc/src/sgml/html/infoschema-views.html new file mode 100644 index 000000000..c8d437f19 --- /dev/null +++ b/doc/src/sgml/html/infoschema-views.html @@ -0,0 +1,419 @@ + +views
PostgreSQL 9.2.2 Documentation
PrevUpChapter 34. The Information SchemaNext

34.63. views

The view views contains all views defined in the + current database. Only those views are shown that the current user + has access to (by way of being the owner or having some privilege). +

Table 34-61. views Columns

NameData TypeDescription
table_catalogsql_identifierName of the database that contains the view (always the current database)
table_schemasql_identifierName of the schema that contains the view
table_namesql_identifierName of the view
view_definitioncharacter_data Query expression defining the view (null if the view is not + owned by a currently enabled role) +
check_optioncharacter_dataApplies to a feature not available in PostgreSQL
is_updatableyes_or_no YES if the view is updatable (allows + UPDATE and DELETE), + NO if not +
is_insertable_intoyes_or_no YES if the view is insertable into (allows + INSERT), NO if not +
is_trigger_updatableyes_or_no YES if the view has an INSTEAD OF + UPDATE trigger defined on it, NO if not +
is_trigger_deletableyes_or_no YES if the view has an INSTEAD OF + DELETE trigger defined on it, NO if not +
is_trigger_insertable_intoyes_or_no YES if the view has an INSTEAD OF + INSERT trigger defined on it, NO if not +

PrevHomeNext
view_table_usageUpServer Programming
\ No newline at end of file diff --git a/doc/src/sgml/html/install-getsource.html b/doc/src/sgml/html/install-getsource.html new file mode 100644 index 000000000..271f7dd9b --- /dev/null +++ b/doc/src/sgml/html/install-getsource.html @@ -0,0 +1,210 @@ + +Getting The Source
PostgreSQL 9.2.2 Documentation
PrevUpChapter 15. Installation from Source CodeNext

15.3. Getting The Source

The PostgreSQL 9.2.2 sources can be obtained by + anonymous FTP from ftp://ftp.postgresql.org/pub/source/v9.2.2/postgresql-9.2.2.tar.gz. + Other download options can be found on our website: + http://www.postgresql.org/download/. After you + have obtained the file, unpack it: +

gunzip postgresql-9.2.2.tar.gz
+tar xf postgresql-9.2.2.tar

+ This will create a directory + postgresql-9.2.2 under the current directory + with the PostgreSQL sources. + Change into that directory for the rest + of the installation procedure. +

You can also get the source directly from the version control repository, see + Appendix I. +


PrevHomeNext
RequirementsUpInstallation Procedure
\ No newline at end of file diff --git a/doc/src/sgml/html/install-post.html b/doc/src/sgml/html/install-post.html new file mode 100644 index 000000000..4f177f8e6 --- /dev/null +++ b/doc/src/sgml/html/install-post.html @@ -0,0 +1,463 @@ + +Post-Installation Setup
PostgreSQL 9.2.2 Documentation
PrevUpChapter 15. Installation from Source CodeNext

15.5. Post-Installation Setup

15.5.1. Shared Libraries

On some systems with shared libraries + you need to tell the system how to find the newly installed + shared libraries. The systems on which this is + not necessary include + FreeBSD, + HP-UX, IRIX, Linux, + NetBSD, OpenBSD, Tru64 + UNIX (formerly Digital UNIX), and + Solaris. +

The method to set the shared library search path varies between + platforms, but the most widely-used method is to set the + environment variable LD_LIBRARY_PATH like so: In Bourne + shells (sh, ksh, bash, zsh): +

LD_LIBRARY_PATH=/usr/local/pgsql/lib
+export LD_LIBRARY_PATH

+ or in csh or tcsh: +

setenv LD_LIBRARY_PATH /usr/local/pgsql/lib

+ Replace /usr/local/pgsql/lib with whatever you set + --libdir to in step 1. + You should put these commands into a shell start-up file such as + /etc/profile or ~/.bash_profile. Some + good information about the caveats associated with this method can + be found at http://xahlee.org/UnixResource_dir/_/ldpath.html. +

On some systems it might be preferable to set the environment + variable LD_RUN_PATH before + building. +

On Cygwin, put the library + directory in the PATH or move the + .dll files into the bin + directory. +

If in doubt, refer to the manual pages of your system (perhaps + ld.so or rld). If you later + get a message like: +

psql: error in loading shared libraries
+libpq.so.2.1: cannot open shared object file: No such file or directory

+ then this step was necessary. Simply take care of it then. +

+ If you are on Linux and you have root + access, you can run: +

/sbin/ldconfig /usr/local/pgsql/lib

+ (or equivalent directory) after installation to enable the + run-time linker to find the shared libraries faster. Refer to the + manual page of ldconfig for more information. On + FreeBSD, NetBSD, and OpenBSD the command is: +

/sbin/ldconfig -m /usr/local/pgsql/lib

+ instead. Other systems are not known to have an equivalent + command. +

15.5.2. Environment Variables

If you installed into /usr/local/pgsql or some other + location that is not searched for programs by default, you should + add /usr/local/pgsql/bin (or whatever you set + --bindir to in step 1) + into your PATH. Strictly speaking, this is not + necessary, but it will make the use of PostgreSQL + much more convenient. +

To do this, add the following to your shell start-up file, such as + ~/.bash_profile (or /etc/profile, if you + want it to affect all users): +

PATH=/usr/local/pgsql/bin:$PATH
+export PATH

+ If you are using csh or tcsh, then use this command: +

set path = ( /usr/local/pgsql/bin $path )

+

+ To enable your system to find the man + documentation, you need to add lines like the following to a + shell start-up file unless you installed into a location that is + searched by default: +

MANPATH=/usr/local/pgsql/man:$MANPATH
+export MANPATH

+

The environment variables PGHOST and PGPORT + specify to client applications the host and port of the database + server, overriding the compiled-in defaults. If you are going to + run client applications remotely then it is convenient if every + user that plans to use the database sets PGHOST. This + is not required, however; the settings can be communicated via command + line options to most client programs. +


PrevHomeNext
Installation ProcedureUpSupported Platforms
\ No newline at end of file diff --git a/doc/src/sgml/html/install-procedure.html b/doc/src/sgml/html/install-procedure.html new file mode 100644 index 000000000..38d8053b2 --- /dev/null +++ b/doc/src/sgml/html/install-procedure.html @@ -0,0 +1,2307 @@ + +Installation Procedure
PostgreSQL 9.2.2 Documentation
PrevUpChapter 15. Installation from Source CodeNext

15.4. Installation Procedure

  1. Configuration

    The first step of the installation procedure is to configure the + source tree for your system and choose the options you would like. + This is done by running the configure script. For a + default installation simply enter: +

    ./configure

    + This script will run a number of tests to determine values for various + system dependent variables and detect any quirks of your + operating system, and finally will create several files in the + build tree to record what it found. You can also run + configure in a directory outside the source + tree, if you want to keep the build directory separate. This + procedure is also called a + VPATH + build. Here's how: +

    mkdir build_dir
    +cd build_dir
    +/path/to/source/tree/configure [options go here]
    +gmake

    +

    The default configuration will build the server and utilities, as + well as all client applications and interfaces that require only a + C compiler. All files will be installed under + /usr/local/pgsql by default. +

    You can customize the build and installation process by supplying one + or more of the following command line options to + configure: + +

    --prefix=PREFIX

    Install all files under the directory PREFIX + instead of /usr/local/pgsql. The actual + files will be installed into various subdirectories; no files + will ever be installed directly into the + PREFIX directory. +

    If you have special needs, you can also customize the + individual subdirectories with the following options. However, + if you leave these with their defaults, the installation will be + relocatable, meaning you can move the directory after + installation. (The man and doc + locations are not affected by this.) +

    For relocatable installs, you might want to use + configure's --disable-rpath + option. Also, you will need to tell the operating system how + to find the shared libraries. +

    --exec-prefix=EXEC-PREFIX

    You can install architecture-dependent files under a + different prefix, EXEC-PREFIX, than what + PREFIX was set to. This can be useful to + share architecture-independent files between hosts. If you + omit this, then EXEC-PREFIX is set equal to + PREFIX and both architecture-dependent and + independent files will be installed under the same tree, + which is probably what you want. +

    --bindir=DIRECTORY

    Specifies the directory for executable programs. The default + is EXEC-PREFIX/bin, which + normally means /usr/local/pgsql/bin. +

    --sysconfdir=DIRECTORY

    Sets the directory for various configuration files, + PREFIX/etc by default. +

    --libdir=DIRECTORY

    Sets the location to install libraries and dynamically loadable + modules. The default is + EXEC-PREFIX/lib. +

    --includedir=DIRECTORY

    Sets the directory for installing C and C++ header files. The + default is PREFIX/include. +

    --datarootdir=DIRECTORY

    Sets the root directory for various types of read-only data + files. This only sets the default for some of the following + options. The default is + PREFIX/share. +

    --datadir=DIRECTORY

    Sets the directory for read-only data files used by the + installed programs. The default is + DATAROOTDIR. Note that this has + nothing to do with where your database files will be placed. +

    --localedir=DIRECTORY

    Sets the directory for installing locale data, in particular + message translation catalog files. The default is + DATAROOTDIR/locale. +

    --mandir=DIRECTORY

    The man pages that come with PostgreSQL will be installed under + this directory, in their respective + manx subdirectories. + The default is DATAROOTDIR/man. +

    --docdir=DIRECTORY

    Sets the root directory for installing documentation files, + except "man" pages. This only sets the default for + the following options. The default value for this option is + DATAROOTDIR/doc/postgresql. +

    --htmldir=DIRECTORY

    The HTML-formatted documentation for + PostgreSQL will be installed under + this directory. The default is + DATAROOTDIR. +

    + +

    Note: Care has been taken to make it possible to install + PostgreSQL into shared installation locations + (such as /usr/local/include) without + interfering with the namespace of the rest of the system. First, + the string "/postgresql" is + automatically appended to datadir, + sysconfdir, and docdir, + unless the fully expanded directory name already contains the + string "postgres" or + "pgsql". For example, if you choose + /usr/local as prefix, the documentation will + be installed in /usr/local/doc/postgresql, + but if the prefix is /opt/postgres, then it + will be in /opt/postgres/doc. The public C + header files of the client interfaces are installed into + includedir and are namespace-clean. The + internal header files and the server header files are installed + into private directories under includedir. See + the documentation of each interface for information about how to + access its header files. Finally, a private subdirectory will + also be created, if appropriate, under libdir + for dynamically loadable modules. +

    +

    --with-includes=DIRECTORIES

    DIRECTORIES is a colon-separated list of + directories that will be added to the list the compiler + searches for header files. If you have optional packages + (such as GNU Readline) installed in a non-standard + location, + you have to use this option and probably also the corresponding + --with-libraries option. +

    Example: --with-includes=/opt/gnu/include:/usr/sup/include. +

    --with-libraries=DIRECTORIES

    DIRECTORIES is a colon-separated list of + directories to search for libraries. You will probably have + to use this option (and the corresponding + --with-includes option) if you have packages + installed in non-standard locations. +

    Example: --with-libraries=/opt/gnu/lib:/usr/sup/lib. +

    --enable-nls[=LANGUAGES]

    Enables Native Language Support (NLS), + that is, the ability to display a program's messages in a + language other than English. + LANGUAGES is an optional space-separated + list of codes of the languages that you want supported, for + example --enable-nls='de fr'. (The intersection + between your list and the set of actually provided + translations will be computed automatically.) If you do not + specify a list, then all available translations are + installed. +

    To use this option, you will need an implementation of the + Gettext API; see above. +

    --with-pgport=NUMBER

    Set NUMBER as the default port number for + server and clients. The default is 5432. The port can always + be changed later on, but if you specify it here then both + server and clients will have the same default compiled in, + which can be very convenient. Usually the only good reason + to select a non-default value is if you intend to run multiple + PostgreSQL servers on the same machine. +

    --with-perl

    Build the PL/Perl server-side language. +

    --with-python

    Build the PL/Python server-side language. +

    --with-tcl

    Build the PL/Tcl server-side language. +

    --with-tclconfig=DIRECTORY

    Tcl installs the file tclConfig.sh, which + contains configuration information needed to build modules + interfacing to Tcl. This file is normally found automatically + at a well-known location, but if you want to use a different + version of Tcl you can specify the directory in which to look + for it. +

    --with-gssapi

    Build with support for GSSAPI authentication. On many + systems, the GSSAPI (usually a part of the Kerberos installation) + system is not installed in a location + that is searched by default (e.g., /usr/include, + /usr/lib), so you must use the options + --with-includes and --with-libraries in + addition to this option. configure will check + for the required header files and libraries to make sure that + your GSSAPI installation is sufficient before proceeding. +

    --with-krb5

    Build with support for Kerberos 5 authentication. On many + systems, the Kerberos system is not installed in a location + that is searched by default (e.g., /usr/include, + /usr/lib), so you must use the options + --with-includes and --with-libraries in + addition to this option. configure will check + for the required header files and libraries to make sure that + your Kerberos installation is sufficient before proceeding. +

    --with-krb-srvnam=NAME

    The default name of the Kerberos service principal (also used + by GSSAPI). + postgres is the default. There's usually no + reason to change this unless you have a Windows environment, + in which case it must be set to upper case + POSTGRES. +

    --with-openssl

    Build with support for SSL (encrypted) + connections. This requires the OpenSSL + package to be installed. configure will check + for the required header files and libraries to make sure that + your OpenSSL installation is sufficient + before proceeding. +

    --with-pam

    Build with PAM + (Pluggable Authentication Modules) support. +

    --with-ldap

    Build with LDAP + support for authentication and connection parameter lookup (see + Section 31.17 and + Section 19.3.8 for more information). On Unix, + this requires the OpenLDAP package to be + installed. On Windows, the default WinLDAP + library is used. configure will check for the required + header files and libraries to make sure that your + OpenLDAP installation is sufficient before + proceeding. +

    --without-readline

    Prevents use of the Readline library + (and libedit as well). This option disables + command-line editing and history in + psql, so it is not recommended. +

    --with-libedit-preferred

    Favors the use of the BSD-licensed libedit library + rather than GPL-licensed Readline. This option + is significant only if you have both libraries installed; the + default in that case is to use Readline. +

    --with-bonjour

    Build with Bonjour support. This requires Bonjour support + in your operating system. Recommended on Mac OS X. +

    --with-ossp-uuid

    Build components using the OSSP UUID + library. Specifically, build the + + uuid-ossp module, + which provides functions to generate + UUIDs. +

    --with-libxml

    Build with libxml (enables SQL/XML support). Libxml version 2.6.23 or + later is required for this feature. +

    Libxml installs a program xml2-config that + can be used to detect the required compiler and linker + options. PostgreSQL will use it automatically if found. To + specify a libxml installation at an unusual location, you can + either set the environment variable + XML2_CONFIG to point to the + xml2-config program belonging to the + installation, or use the options + --with-includes and + --with-libraries. +

    --with-libxslt

    Use libxslt when building the + + xml2 + module. xml2 relies on this library + to perform XSL transformations of XML. +

    --disable-integer-datetimes

    Disable support for 64-bit integer storage for timestamps and + intervals, and store datetime values as floating-point + numbers instead. Floating-point datetime storage was the + default in PostgreSQL releases + prior to 8.4, but it is now deprecated, because it does not + support microsecond precision for the full range of + timestamp values. However, integer-based + datetime storage requires a 64-bit integer type. Therefore, + this option can be used when no such type is available, or + for compatibility with applications written for prior + versions of PostgreSQL. See + + Section 8.5 + for more information. +

    --disable-float4-byval

    Disable passing float4 values "by value", causing them + to be passed "by reference" instead. This option costs + performance, but may be needed for compatibility with old + user-defined functions that are written in C and use the + "version 0" calling convention. A better long-term + solution is to update any such functions to use the + "version 1" calling convention. +

    --disable-float8-byval

    Disable passing float8 values "by value", causing them + to be passed "by reference" instead. This option costs + performance, but may be needed for compatibility with old + user-defined functions that are written in C and use the + "version 0" calling convention. A better long-term + solution is to update any such functions to use the + "version 1" calling convention. + Note that this option affects not only float8, but also int8 and some + related types such as timestamp. + On 32-bit platforms, --disable-float8-byval is the default + and it is not allowed to select --enable-float8-byval. +

    --with-segsize=SEGSIZE

    Set the segment size, in gigabytes. Large tables are + divided into multiple operating-system files, each of size equal + to the segment size. This avoids problems with file size limits + that exist on many platforms. The default segment size, 1 gigabyte, + is safe on all supported platforms. If your operating system has + "largefile" support (which most do, nowadays), you can use + a larger segment size. This can be helpful to reduce the number of + file descriptors consumed when working with very large tables. + But be careful not to select a value larger than is supported + by your platform and the file systems you intend to use. Other + tools you might wish to use, such as tar, could + also set limits on the usable file size. + It is recommended, though not absolutely required, that this value + be a power of 2. + Note that changing this value requires an initdb. +

    --with-blocksize=BLOCKSIZE

    Set the block size, in kilobytes. This is the unit + of storage and I/O within tables. The default, 8 kilobytes, + is suitable for most situations; but other values may be useful + in special cases. + The value must be a power of 2 between 1 and 32 (kilobytes). + Note that changing this value requires an initdb. +

    --with-wal-segsize=SEGSIZE

    Set the WAL segment size, in megabytes. This is + the size of each individual file in the WAL log. It may be useful + to adjust this size to control the granularity of WAL log shipping. + The default size is 16 megabytes. + The value must be a power of 2 between 1 and 64 (megabytes). + Note that changing this value requires an initdb. +

    --with-wal-blocksize=BLOCKSIZE

    Set the WAL block size, in kilobytes. This is the unit + of storage and I/O within the WAL log. The default, 8 kilobytes, + is suitable for most situations; but other values may be useful + in special cases. + The value must be a power of 2 between 1 and 64 (kilobytes). + Note that changing this value requires an initdb. +

    --disable-spinlocks

    Allow the build to succeed even if PostgreSQL + has no CPU spinlock support for the platform. The lack of + spinlock support will result in poor performance; therefore, + this option should only be used if the build aborts and + informs you that the platform lacks spinlock support. If this + option is required to build PostgreSQL on + your platform, please report the problem to the + PostgreSQL developers. +

    --disable-thread-safety

    Disable the thread-safety of client libraries. This prevents + concurrent threads in libpq and + ECPG programs from safely controlling + their private connection handles. +

    --with-system-tzdata=DIRECTORY

    PostgreSQL includes its own time zone database, + which it requires for date and time operations. This time zone + database is in fact compatible with the "zoneinfo" time zone + database provided by many operating systems such as FreeBSD, + Linux, and Solaris, so it would be redundant to install it again. + When this option is used, the system-supplied time zone database + in DIRECTORY is used instead of the one + included in the PostgreSQL source distribution. + DIRECTORY must be specified as an + absolute path. /usr/share/zoneinfo is a + likely directory on some operating systems. Note that the + installation routine will not detect mismatching or erroneous time + zone data. If you use this option, you are advised to run the + regression tests to verify that the time zone data you have + pointed to works correctly with PostgreSQL. +

    This option is mainly aimed at binary package distributors + who know their target operating system well. The main + advantage of using this option is that the PostgreSQL package + won't need to be upgraded whenever any of the many local + daylight-saving time rules change. Another advantage is that + PostgreSQL can be cross-compiled more straightforwardly if the + time zone database files do not need to be built during the + installation. +

    --without-zlib

    + Prevents use of the Zlib library. This disables + support for compressed archives in pg_dump + and pg_restore. + This option is only intended for those rare systems where this + library is not available. +

    --enable-debug

    Compiles all programs and libraries with debugging symbols. + This means that you can run the programs in a debugger + to analyze problems. This enlarges the size of the installed + executables considerably, and on non-GCC compilers it usually + also disables compiler optimization, causing slowdowns. However, + having the symbols available is extremely helpful for dealing + with any problems that might arise. Currently, this option is + recommended for production installations only if you use GCC. + But you should always have it on if you are doing development work + or running a beta version. +

    --enable-coverage

    If using GCC, all programs and libraries are compiled with + code coverage testing instrumentation. When run, they + generate files in the build directory with code coverage + metrics. + See Section 30.4 + for more information. This option is for use only with GCC + and when doing development work. +

    --enable-profiling

    If using GCC, all programs and libraries are compiled so they + can be profiled. On backend exit, a subdirectory will be created + that contains the gmon.out file for use in profiling. + This option is for use only with GCC and when doing development work. +

    --enable-cassert

    Enables assertion checks in the server, which test for + many "cannot happen" conditions. This is invaluable for + code development purposes, but the tests can slow down the + server significantly. + Also, having the tests turned on won't necessarily enhance the + stability of your server! The assertion checks are not categorized + for severity, and so what might be a relatively harmless bug will + still lead to server restarts if it triggers an assertion + failure. This option is not recommended for production use, but + you should have it on for development work or when running a beta + version. +

    --enable-depend

    Enables automatic dependency tracking. With this option, the + makefiles are set up so that all affected object files will + be rebuilt when any header file is changed. This is useful + if you are doing development work, but is just wasted overhead + if you intend only to compile once and install. At present, + this option only works with GCC. +

    --enable-dtrace

    + Compiles PostgreSQL with support for the + dynamic tracing tool DTrace. + See Section 27.4 + for more information. +

    To point to the dtrace program, the + environment variable DTRACE can be set. This + will often be necessary because dtrace is + typically installed under /usr/sbin, + which might not be in the path. +

    Extra command-line options for the dtrace program + can be specified in the environment variable + DTRACEFLAGS. On Solaris, + to include DTrace support in a 64-bit binary, you must specify + DTRACEFLAGS="-64" to configure. For example, + using the GCC compiler: +

    ./configure CC='gcc -m64' --enable-dtrace DTRACEFLAGS='-64' ...

    + Using Sun's compiler: +

    ./configure CC='/opt/SUNWspro/bin/cc -xtarget=native64' --enable-dtrace DTRACEFLAGS='-64' ...

    +

    +

    If you prefer a C compiler different from the one + configure picks, you can set the + environment variable CC to the program of your choice. + By default, configure will pick + gcc if available, else the platform's + default (usually cc). Similarly, you can override the + default compiler flags if needed with the CFLAGS variable. +

    You can specify environment variables on the + configure command line, for example: +

    ./configure CC=/opt/bin/gcc CFLAGS='-O2 -pipe'

    +

    Here is a list of the significant variables that can be set in + this manner: + +

    BISON

    Bison program +

    CC

    C compiler +

    CFLAGS

    options to pass to the C compiler +

    CPP

    C preprocessor +

    CPPFLAGS

    options to pass to the C preprocessor +

    DTRACE

    location of the dtrace program +

    DTRACEFLAGS

    options to pass to the dtrace program +

    FLEX

    Flex program +

    LDFLAGS

    options to use when linking either executables or shared libraries +

    LDFLAGS_EX

    additional options for linking executables only +

    LDFLAGS_SL

    additional options for linking shared libraries only +

    MSGFMT

    msgfmt program for native language support +

    PERL

    Full path to the Perl interpreter. This will be used to + determine the dependencies for building PL/Perl. +

    PYTHON

    Full path to the Python interpreter. This will be used to + determine the dependencies for building PL/Python. Also, + whether Python 2 or 3 is specified here (or otherwise + implicitly chosen) determines which variant of the PL/Python + language becomes available. See + + Section 42.1 + for more information. +

    TCLSH

    Full path to the Tcl interpreter. This will be used to + determine the dependencies for building PL/Tcl, and it will + be substituted into Tcl scripts. +

    XML2_CONFIG

    xml2-config program used to locate the + libxml installation. +

    +

    Note: When developing code inside the server, it is recommended to + use the configure options --enable-cassert (which + turns on many run-time error checks) and --enable-debug + (which improves the usefulness of debugging tools). +

    If using GCC, it is best to build with an optimization level of + at least -O1, because using no optimization + (-O0) disables some important compiler warnings (such + as the use of uninitialized variables). However, non-zero + optimization levels can complicate debugging because stepping + through compiled code will usually not match up one-to-one with + source code lines. If you get confused while trying to debug + optimized code, recompile the specific files of interest with + -O0. An easy way to do this is by passing an option + to make: gmake PROFILE=-O0 file.o. +

  2. Build

    To start the build, type: +

    gmake

    + (Remember to use GNU make.) The build + will take a few minutes depending on your + hardware. The last line displayed should be: +

    All of PostgreSQL is successfully made. Ready to install.

    +

    If you want to build everything that can be built, including the + documentation (HTML and man pages), and the additional modules + (contrib), type instead: +

    gmake world

    + The last line displayed should be: +

    PostgreSQL, contrib and HTML documentation successfully made. Ready to install.

    +

  3. Regression Tests

    If you want to test the newly built server before you install it, + you can run the regression tests at this point. The regression + tests are a test suite to verify that PostgreSQL + runs on your machine in the way the developers expected it + to. Type: +

    gmake check

    + (This won't work as root; do it as an unprivileged user.) + + Chapter 30 contains + detailed information about interpreting the test results. You can + repeat this test at any later time by issuing the same command. +

  4. Installing the Files

    Note: If you are upgrading an existing system be sure to read + + Section 17.6 + which has instructions about upgrading a + cluster. +

    To install PostgreSQL enter: +

    gmake install

    + This will install files into the directories that were specified + in step 1. Make sure that you have appropriate + permissions to write into that area. Normally you need to do this + step as root. Alternatively, you can create the target + directories in advance and arrange for appropriate permissions to + be granted. +

    To install the documentation (HTML and man pages), enter: +

    gmake install-docs

    +

    If you built the world above, type instead: +

    gmake install-world

    + This also installs the documentation. +

    You can use gmake install-strip instead of + gmake install to strip the executable files and + libraries as they are installed. This will save some space. If + you built with debugging support, stripping will effectively + remove the debugging support, so it should only be done if + debugging is no longer needed. install-strip + tries to do a reasonable job saving space, but it does not have + perfect knowledge of how to strip every unneeded byte from an + executable file, so if you want to save all the disk space you + possibly can, you will have to do manual work. +

    The standard installation provides all the header files needed for client + application development as well as for server-side program + development, such as custom functions or data types written in C. + (Prior to PostgreSQL 8.0, a separate gmake + install-all-headers command was needed for the latter, but this + step has been folded into the standard install.) +

    Client-only installation: If you want to install only the client applications and + interface libraries, then you can use these commands: +

    gmake -C src/bin install
    +gmake -C src/include install
    +gmake -C src/interfaces install
    +gmake -C doc install

    + src/bin has a few binaries for server-only use, + but they are small. +

Uninstallation: To undo the installation use the command gmake + uninstall. However, this will not remove any created directories. +

Cleaning: After the installation you can free disk space by removing the built + files from the source tree with the command gmake + clean. This will preserve the files made by the configure + program, so that you can rebuild everything with gmake + later on. To reset the source tree to the state in which it was + distributed, use gmake distclean. If you are going to + build for several platforms within the same source tree you must do + this and re-configure for each platform. (Alternatively, use + a separate build tree for each platform, so that the source tree + remains unmodified.) +

If you perform a build and then discover that your configure + options were wrong, or if you change anything that configure + investigates (for example, software upgrades), then it's a good + idea to do gmake distclean before reconfiguring and + rebuilding. Without this, your changes in configuration choices + might not propagate everywhere they need to. +


PrevHomeNext
Getting The SourceUpPost-Installation Setup
\ No newline at end of file diff --git a/doc/src/sgml/html/install-requirements.html b/doc/src/sgml/html/install-requirements.html new file mode 100644 index 000000000..7befb3e1e --- /dev/null +++ b/doc/src/sgml/html/install-requirements.html @@ -0,0 +1,765 @@ + +Requirements
PostgreSQL 9.2.2 Documentation
PrevUpChapter 15. Installation from Source CodeNext

15.2. Requirements

In general, a modern Unix-compatible platform should be able to run + PostgreSQL. + The platforms that had received specific testing at the + time of release are listed in Section 15.6 + below. In the doc subdirectory of the distribution + there are several platform-specific FAQ documents you + might wish to consult if you are having trouble. +

The following software packages are required for building + PostgreSQL: + +

  • + + GNU make version 3.80 or newer is required; other + make programs or older GNU make versions will not work. + GNU make is often installed under + the name gmake; this document will always + refer to it by that name. (On some systems + GNU make is the default tool with the name + make.) To test for GNU + make enter: +

    gmake --version

    +

  • You need an ISO/ANSI C compiler (at least + C89-compliant). Recent + versions of GCC are recommended, but + PostgreSQL is known to build using a wide variety + of compilers from different vendors. +

  • tar is required to unpack the source + distribution, in addition to either + gzip or bzip2. +

  • + + + The GNU Readline library is used by + default. It allows psql (the + PostgreSQL command line SQL interpreter) to remember each + command you type, and allows you to use arrow keys to recall and + edit previous commands. This is very helpful and is strongly + recommended. If you don't want to use it then you must specify + the --without-readline option to + configure. As an alternative, you can often use the + BSD-licensed libedit library, originally + developed on NetBSD. The + libedit library is + GNU Readline-compatible and is used if + libreadline is not found, or if + --with-libedit-preferred is used as an + option to configure. If you are using a package-based + Linux distribution, be aware that you need both the + readline and readline-devel packages, if + those are separate in your distribution. +

  • + + The zlib compression library is + used by default. If you don't want to use it then you must + specify the --without-zlib option to + configure. Using this option disables + support for compressed archives in pg_dump and + pg_restore. +

+

The following packages are optional. They are not required in the + default configuration, but they are needed when certain build + options are enabled, as explained below: + +

  • To build the server programming language + PL/Perl you need a full + Perl installation, including the + libperl library and the header files. + Since PL/Perl will be a shared + library, the + libperl library must be a shared library + also on most platforms. This appears to be the default in + recent Perl versions, but it was not + in earlier versions, and in any case it is the choice of whomever + installed Perl at your site. + If you intend to make more than incidental use of + PL/Perl, you should ensure that the + Perl installation was built with the + usemultiplicity option enabled (perl -V + will show whether this is the case). +

    If you don't have the shared library but you need one, a message + like this will appear during the PostgreSQL + build to point out this fact: +

    *** Cannot build PL/Perl because libperl is not a shared library.
    +*** You might have to rebuild your Perl installation.  Refer to
    +*** the documentation for details.

    + (If you don't follow the on-screen output you will merely notice + that the PL/Perl library object, + plperl.so or similar, will not be + installed.) If you see this, you will have to rebuild and + install Perl manually to be able to + build PL/Perl. During the + configuration process for Perl, + request a shared library. +

  • To build the PL/Python server programming + language, you need a Python + installation with the header files and + the distutils module. The minimum + required version is Python + 2.3. Python 3 is supported if it's + version 3.1 or later; but see + + Section 42.1 + when using Python 3. +

    Since PL/Python will be a shared + library, the + libpython library must be a shared library + also on most platforms. This is not the case in a default + Python installation. If after + building and installing PostgreSQL you have a file called + plpython.so (possibly a different + extension), then everything went well. Otherwise you should + have seen a notice like this flying by: +

    *** Cannot build PL/Python because libpython is not a shared library.
    +*** You might have to rebuild your Python installation.  Refer to
    +*** the documentation for details.

    + That means you have to rebuild (part of) your + Python installation to create this + shared library. +

    If you have problems, run Python 2.3 or later's + configure using the --enable-shared flag. On some + operating systems you don't have to build a shared library, but + you will have to convince the PostgreSQL build + system of this. Consult the Makefile in + the src/pl/plpython directory for details. +

  • To build the PL/Tcl + procedural language, you of course need a Tcl + installation. If you are using a pre-8.4 release of + Tcl, ensure that it was built without multithreading + support. +

  • To enable Native Language Support (NLS), that + is, the ability to display a program's messages in a language + other than English, you need an implementation of the + Gettext API. Some operating + systems have this built-in (e.g., Linux, NetBSD, + Solaris), for other systems you + can download an add-on package from http://www.gnu.org/software/gettext/. + If you are using the Gettext implementation in + the GNU C library then you will additionally + need the GNU Gettext package for some + utility programs. For any of the other implementations you will + not need it. +

  • You need Kerberos, OpenSSL, + OpenLDAP, and/or + PAM, if you want to support authentication or + encryption using those services. +

+

If you are building from a Git tree instead of + using a released source package, or if you want to do server development, + you also need the following packages: + +

  • + + + + + GNU Flex and Bison + are needed to build from a Git checkout, or if you changed the actual + scanner and parser definition files. If you need them, be sure + to get Flex 2.5.31 or later and + Bison 1.875 or later. Other lex + and yacc programs cannot be used. +

  • + + Perl 5.8 or later is needed to build from a Git checkout, + or if you changed the input files for any of the build steps that + use Perl scripts. If building on Windows you will need + Perl in any case. +

+

If you need to get a GNU package, you can find + it at your local GNU mirror site (see http://www.gnu.org/order/ftp.html + for a list) or at ftp://ftp.gnu.org/gnu/. +

Also check that you have sufficient disk space. You will need about + 100 MB for the source tree during compilation and about 20 MB for + the installation directory. An empty database cluster takes about + 35 MB; databases take about five times the amount of space that a + flat text file with the same data would take. If you are going to + run the regression tests you will temporarily need up to an extra + 150 MB. Use the df command to check free disk + space. +


PrevHomeNext
Short VersionUpGetting The Source
\ No newline at end of file diff --git a/doc/src/sgml/html/install-short.html b/doc/src/sgml/html/install-short.html new file mode 100644 index 000000000..4a8de5b41 --- /dev/null +++ b/doc/src/sgml/html/install-short.html @@ -0,0 +1,183 @@ + +Short Version
PostgreSQL 9.2.2 Documentation
PrevUpChapter 15. Installation from Source CodeNext

15.1. Short Version

./configure
+gmake
+su
+gmake install
+adduser postgres
+mkdir /usr/local/pgsql/data
+chown postgres /usr/local/pgsql/data
+su - postgres
+/usr/local/pgsql/bin/initdb -D /usr/local/pgsql/data
+/usr/local/pgsql/bin/postgres -D /usr/local/pgsql/data >logfile 2>&1 &
+/usr/local/pgsql/bin/createdb test
+/usr/local/pgsql/bin/psql test

+ The long version is the rest of this + + chapter. +


PrevHomeNext
Installation from Source CodeUpRequirements
\ No newline at end of file diff --git a/doc/src/sgml/html/install-windows-full.html b/doc/src/sgml/html/install-windows-full.html new file mode 100644 index 000000000..035e66bd1 --- /dev/null +++ b/doc/src/sgml/html/install-windows-full.html @@ -0,0 +1,975 @@ + +Building with Visual C++ or the + Microsoft Windows SDK
PostgreSQL 9.2.2 Documentation
PrevUpChapter 16. Installation from Source Code on WindowsNext

16.1. Building with Visual C++ or the + Microsoft Windows SDK

PostgreSQL can be built using the Visual C++ compiler suite from Microsoft. + These compilers can be either from Visual Studio, + Visual Studio Express or some versions of the + Microsoft Windows SDK. If you do not already have a + Visual Studio environment set up, the easiest + way is to use the compilers in the Windows SDK, + which is a free download from Microsoft. +

PostgreSQL is known to support compilation using the compilers shipped with + Visual Studio 2005 to + Visual Studio 2010 (including Express editions), + as well as standalone Windows SDK releases 6.0 to 7.1. + 64-bit PostgreSQL builds are only supported with + Microsoft Windows SDK version 6.0a and above or + Visual Studio 2008 and above. +

The tools for building using Visual C++, + are in the src/tools/msvc directory. When building, + make sure there are no tools from MinGW or + Cygwin present in your system PATH. Also, make + sure you have all the required Visual C++ tools available in the PATH. In + Visual Studio, start the + Visual Studio Command Prompt. + If you wish to build a 64-bit version, you must use the 64-bit version of + the command, and vice versa. + In the Microsoft Windows SDK, start the + CMD shell listed under the SDK on the Start Menu. + In recent SDK versions you can change the targeted CPU architecture by using + the setenv command. + All commands should be run from the src\tools\msvc + directory. +

Before you build, you may need to edit the file config.pl + to reflect any configuration options you want to change, or the paths to + any third party libraries to use. The complete configuration is determined + by first reading and parsing the file config_default.pl, + and then apply any changes from config.pl. For example, + to specify the location of your Python installation, + put the following in config.pl: +

$config->{python} = 'c:\python26';

+ You only need to specify those parameters that are different from what's in + config_default.pl. +

If you need to set any other environment variables, create a file called + buildenv.pl and put the required commands there. For + example, to add the path for bison when it's not in the PATH, create a file + containing: +

$ENV{PATH}=$ENV{PATH} . ';c:\some\where\bison\bin';

+

16.1.1. Requirements

The following additional products are required to build + PostgreSQL. Use the + config.pl file to specify which directories the libraries + are available in. + +

Microsoft Windows SDK

It is recommended that you upgrade to the latest supported version + of the Microsoft Windows SDK (currently + version 7.1), available for download from + http://www.microsoft.com/downloads/. +

You must always include the + Windows Headers and Libraries part of the SDK. + If you install the Windows SDK + including the Visual C++ Compilers, + you don't need Visual Studio to build. +

ActiveState Perl

ActiveState Perl is required to run the build generation scripts. MinGW + or Cygwin Perl will not work. It must also be present in the PATH. + Binaries can be downloaded from + http://www.activestate.com (Note: version 5.8 or later is required, + the free Standard Distribution is sufficient). +

+

The following additional products are not required to get started, + but are required to build the complete package. Use the + config.pl file to specify which directories the libraries + are available in. + +

ActiveState TCL

Required for building PL/TCL (Note: version + 8.4 is required, the free Standard Distribution is sufficient). +

Bison and + Flex

Bison and Flex are required to build from Git, but not required when + building from a release file. Note that only Bison 1.875 or versions + 2.2 and later will work. Also, Flex version 2.5.31 or later is required. + Bison can be downloaded from http://gnuwin32.sourceforge.net. + Flex can be downloaded from + http://www.postgresql.org/ftp/misc/winflex/. + If you are using msysGit for accessing the + PostgreSQL Git repository you probably already + have recent versions of bison and flex in your Git + binary directory. +

Note: The Bison distribution from GnuWin32 appears to have a bug that + causes Bison to malfunction when installed in a directory with + spaces in the name, such as the default location on English + installations C:\Program Files\GnuWin32. + Consider installing into C:\GnuWin32 instead. +

Diff

Diff is required to run the regression tests, and can be downloaded + from http://gnuwin32.sourceforge.net. +

Gettext

Gettext is required to build with NLS support, and can be downloaded + from http://gnuwin32.sourceforge.net. Note that binaries, + dependencies and developer files are all needed. +

MIT Kerberos

Required for Kerberos authentication support. MIT Kerberos can be + downloaded from + http://web.mit.edu/Kerberos/dist/index.html. +

libxml2 and + libxslt

Required for XML support. Binaries can be downloaded from + http://zlatkovic.com/pub/libxml or source from + http://xmlsoft.org. Note that libxml2 requires iconv, + which is available from the same download location. +

openssl

Required for SSL support. Binaries can be downloaded from + http://www.slproweb.com/products/Win32OpenSSL.html + or source from http://www.openssl.org. +

ossp-uuid

Required for UUID-OSSP support (contrib only). Source can be + downloaded from + http://www.ossp.org/pkg/lib/uuid/. +

Python

Required for building PL/Python. Binaries can + be downloaded from http://www.python.org. +

zlib

Required for compression support in pg_dump + and pg_restore. Binaries can be downloaded + from http://www.zlib.net. +

+

16.1.2. Special Considerations for 64-bit Windows

PostgreSQL will only build for the x64 architecture on 64-bit Windows, there + is no support for Itanium processors. +

Mixing 32- and 64-bit versions in the same build tree is not supported. + The build system will automatically detect if it's running in a 32- or + 64-bit environment, and build PostgreSQL accordingly. For this reason, it + is important to start the correct command prompt before building. +

To use a server-side third party library such as python or + openssl, this library must also be + 64-bit. There is no support for loading a 32-bit library in a 64-bit + server. Several of the third party libraries that PostgreSQL supports may + only be available in 32-bit versions, in which case they cannot be used with + 64-bit PostgreSQL. +

16.1.3. Building

To build all of PostgreSQL in release configuration (the default), run the + command: +

build

+ To build all of PostgreSQL in debug configuration, run the command: +

build DEBUG

+ To build just a single project, for example psql, run the commands: +

build psql
+build DEBUG psql

+ To change the default build configuration to debug, put the following + in the buildenv.pl file: +

$ENV{CONFIG}="Debug";

+

It is also possible to build from inside the Visual Studio GUI. In this + case, you need to run: +

perl mkvcbuild.pl

+ from the command prompt, and then open the generated + pgsql.sln (in the root directory of the source tree) + in Visual Studio. +

16.1.4. Cleaning and Installing

Most of the time, the automatic dependency tracking in Visual Studio will + handle changed files. But if there have been large changes, you may need + to clean the installation. To do this, simply run the + clean.bat command, which will automatically clean out + all generated files. You can also run it with the + dist parameter, in which case it will behave like + make distclean and remove the flex/bison output files + as well. +

By default, all files are written into a subdirectory of the + debug or release directories. To + install these files using the standard layout, and also generate the files + required to initialize and use the database, run the command: +

install c:\destination\directory

+

16.1.5. Running the Regression Tests

To run the regression tests, make sure you have completed the build of all + required parts first. Also, make sure that the DLLs required to load all + parts of the system (such as the Perl and Python DLLs for the procedural + languages) are present in the system path. If they are not, set it through + the buildenv.pl file. To run the tests, run one of + the following commands from the src\tools\msvc + directory: +

vcregress check
+vcregress installcheck
+vcregress plcheck
+vcregress contribcheck

+ + To change the schedule used (default is parallel), append it to the + command line like: +

vcregress check serial

+ + For more information about the regression tests, see + Chapter 30. +

16.1.6. Building the Documentation

Building the PostgreSQL documentation in HTML format requires several tools + and files. Create a root directory for all these files, and store them + in the subdirectories in the list below. +

OpenJade 1.3.1-2

Download from + http://sourceforge.net/projects/openjade/files/openjade/1.3.1/openjade-1_3_1-2-bin.zip/download + and uncompress in the subdirectory openjade-1.3.1. +

DocBook DTD 4.2

Download from + http://www.oasis-open.org/docbook/sgml/4.2/docbook-4.2.zip + and uncompress in the subdirectory docbook. +

DocBook DSSSL 1.79

Download from + http://sourceforge.net/projects/docbook/files/docbook-dsssl/1.79/docbook-dsssl-1.79.zip/download + and uncompress in the subdirectory + docbook-dsssl-1.79. +

ISO character entities

Download from + http://www.oasis-open.org/cover/ISOEnts.zip and + uncompress in the subdirectory docbook. +

+ Edit the buildenv.pl file, and add a variable for the + location of the root directory, for example: +

$ENV{DOCROOT}='c:\docbook';

+ To build the documentation, run the command + builddoc.bat. Note that this will actually run the + build twice, in order to generate the indexes. The generated HTML files + will be in doc\src\sgml. +


PrevHomeNext
Installation from Source Code on WindowsUpBuilding libpq with + Visual C++ or + Borland C++
\ No newline at end of file diff --git a/doc/src/sgml/html/install-windows-libpq.html b/doc/src/sgml/html/install-windows-libpq.html new file mode 100644 index 000000000..832a2e3b8 --- /dev/null +++ b/doc/src/sgml/html/install-windows-libpq.html @@ -0,0 +1,389 @@ + +Building libpq with + Visual C++ or + Borland C++
PostgreSQL 9.2.2 Documentation
PrevUpChapter 16. Installation from Source Code on WindowsNext

16.2. Building libpq with + Visual C++ or + Borland C++

Using Visual C++ 7.1-9.0 or + Borland C++ to build libpq is only recommended + if you need a version with different debug/release flags, or if you need a + static library to link into an application. For normal use the + MinGW or + Visual Studio or + Windows SDK method is recommended. +

To build the libpq client library using + Visual Studio 7.1 or later, change into the + src directory and type the command: +

nmake /f win32.mak

+

To build a 64-bit version of the libpq + client library using Visual Studio 8.0 or + later, change into the src + directory and type in the command: +

nmake /f win32.mak CPU=AMD64

+ See the win32.mak file for further details + about supported variables. +

To build the libpq client library using + Borland C++, change into the + src directory and type the command: +

make -N -DCFG=Release /f bcc32.mak

+

16.2.1. Generated Files

The following files will be built: + +

interfaces\libpq\Release\libpq.dll

The dynamically linkable frontend library +

interfaces\libpq\Release\libpqdll.lib

Import library to link your programs to libpq.dll +

interfaces\libpq\Release\libpq.lib

Static version of the frontend library +

+

Normally you do not need to install any of the client files. You should + place the libpq.dll file in the same directory + as your applications executable file. Do not install + libpq.dll into your Windows, + System or System32 directory unless + absolutely necessary. + If this file is installed using a setup program, then it should + be installed with version checking using the + VERSIONINFO resource included in the file, to + ensure that a newer version of the library is not overwritten. +

If you are planning to do development using libpq + on this machine, you will have to add the + src\include and + src\interfaces\libpq subdirectories of the source + tree to the include path in your compiler's settings. +

To use the library, you must add the + libpqdll.lib file to your project. (In Visual + C++, just right-click on the project and choose to add it.) +


PrevHomeNext
Building with Visual C++ or the + Microsoft Windows SDKUpServer Setup and Operation
\ No newline at end of file diff --git a/doc/src/sgml/html/install-windows.html b/doc/src/sgml/html/install-windows.html new file mode 100644 index 000000000..91ed633d4 --- /dev/null +++ b/doc/src/sgml/html/install-windows.html @@ -0,0 +1,382 @@ + +Installation from Source Code on Windows

Chapter 16. Installation from Source Code on Windows

It is recommended that most users download the binary distribution for + Windows, available as a one-click installer package + from the PostgreSQL website. Building from source + is only intended for people developing PostgreSQL + or extensions. +

There are several different ways of building PostgreSQL on + Windows. The simplest way to build with + Microsoft tools is to install a supported version of the + Microsoft Windows SDK and use the included + compiler. It is also possible to build with the full + Microsoft Visual C++ 2005, 2008 or 2010. In some cases + that requires the installation of the Windows SDK + in addition to the compiler. +

It is also possible to build PostgreSQL using the GNU compiler tools + provided by MinGW, or using + Cygwin for older versions of + Windows. +

Finally, the client access library + (libpq) can be built using + Visual C++ 7.1 or + Borland C++ for compatibility with statically + linked applications built using these tools. +

Building using MinGW or + Cygwin uses the normal build system, see + Chapter 15 and the specific notes in + Section 15.7.5 and Section 15.7.2. + To produce native 64 bit binaries in these environments, use the tools from + MinGW-w64. These tools can also be used to + cross-compile for 32 bit and 64 bit Windows + targets on other hosts, such as Linux and + Darwin. + Cygwin is not recommended for running a + production server, and it should only be used for running on + older versions of Windows where + the native build does not work, such as + Windows 98. The official + binaries are built using Visual Studio. +

Native builds of psql don't support command + line editing. The Cygwin build does support + command line editing, so it should be used where psql is needed for + interactive use on Windows. +


PrevHomeNext
Platform-specific NotesUpBuilding with Visual C++ or the + Microsoft Windows SDK
\ No newline at end of file diff --git a/doc/src/sgml/html/installation-platform-notes.html b/doc/src/sgml/html/installation-platform-notes.html new file mode 100644 index 000000000..12fa3852f --- /dev/null +++ b/doc/src/sgml/html/installation-platform-notes.html @@ -0,0 +1,1756 @@ + +Platform-specific Notes
PostgreSQL 9.2.2 Documentation
PrevUpChapter 15. Installation from Source CodeNext

15.7. Platform-specific Notes

This section documents additional platform-specific issues + regarding the installation and setup of PostgreSQL. Be sure to + read the installation instructions, and in + particular Section 15.2 as well. Also, + check + Chapter 30 regarding the + interpretation of regression test results. +

Platforms that are not covered here have no known platform-specific + installation issues. +

15.7.1. AIX

PostgreSQL works on AIX, but getting it installed properly can be + challenging. AIX versions from 4.3.3 to 6.1 are considered supported. + You can use GCC or the native IBM compiler xlc. In + general, using recent versions of AIX and PostgreSQL helps. Check + the build farm for up to date information about which versions of + AIX are known to work. +

The minimum recommended fix levels for supported AIX versions are: +

AIX 4.3.3

Maintenance Level 11 + post ML11 bundle

AIX 5.1

Maintenance Level 9 + post ML9 bundle

AIX 5.2

Technology Level 10 Service Pack 3

AIX 5.3

Technology Level 7

AIX 6.1

Base Level

To check your current fix level, use + oslevel -r in AIX 4.3.3 to AIX 5.2 ML 7, or + oslevel -s in later versions. +

Use the following configure flags in addition + to your own if you have installed Readline or libz in + /usr/local: + --with-includes=/usr/local/include + --with-libraries=/usr/local/lib. +

15.7.1.1. GCC Issues

On AIX 5.3, there have been some problems getting PostgreSQL to + compile and run using GCC. +

You will want to use a version of GCC subsequent to 3.3.2, + particularly if you use a prepackaged version. We had good + success with 4.0.1. Problems with earlier versions seem to have + more to do with the way IBM packaged GCC than with actual issues + with GCC, so that if you compile GCC yourself, you might well + have success with an earlier version of GCC. +

15.7.1.2. Unix-Domain Sockets Broken

AIX 5.3 has a problem + where sockaddr_storage is not defined to + be large enough. In version 5.3, IBM increased the size of + sockaddr_un, the address structure for + Unix-domain sockets, but did not correspondingly increase the + size of sockaddr_storage. The result of + this is that attempts to use Unix-domain sockets with PostgreSQL + lead to libpq overflowing the data structure. TCP/IP connections + work OK, but not Unix-domain sockets, which prevents the + regression tests from working. +

The problem was reported to IBM, and is recorded as bug report + PMR29657. If you upgrade to maintenance level 5300-03 or later, + that will include this fix. A quick workaround + is to alter _SS_MAXSIZE to 1025 in + /usr/include/sys/socket.h. In either case, + recompile PostgreSQL once you have the corrected header file. +

15.7.1.3. Internet Address Issues

PostgreSQL relies on the system's getaddrinfo function + to parse IP addresses in listen_addresses, + pg_hba.conf, etc. Older versions of AIX have assorted + bugs in this function. If you have problems related to these settings, + updating to the appropriate AIX fix level shown above + should take care of it. +

One user reports: +

When implementing PostgreSQL version 8.1 on AIX 5.3, we + periodically ran into problems where the statistics collector + would "mysteriously" not come up successfully. This + appears to be the result of unexpected behavior in the IPv6 + implementation. It looks like PostgreSQL and IPv6 do not play + very well together on AIX 5.3. +

Any of the following actions "fix" the problem. +

  • Delete the IPv6 address for localhost: +

    (as root)
    +# ifconfig lo0 inet6 ::1/0 delete

    +

  • Remove IPv6 from net services. The + file /etc/netsvc.conf on AIX is roughly + equivalent to /etc/nsswitch.conf on + Solaris/Linux. The default, on AIX, is thus: +

    hosts=local,bind

    + Replace this with: +

    hosts=local4,bind4

    + to deactivate searching for IPv6 addresses. +

+

Warning

This is really a workaround for problems relating + to immaturity of IPv6 support, which improved visibly during the + course of AIX 5.3 releases. It has worked with AIX version 5.3, + but does not represent an elegant solution to the problem. It has + been reported that this workaround is not only unnecessary, but + causes problems on AIX 6.1, where IPv6 support has become more mature. +

15.7.1.4. Memory Management

AIX can be somewhat peculiar with regards to the way it does + memory management. You can have a server with many multiples of + gigabytes of RAM free, but still get out of memory or address + space errors when running applications. One example + is createlang failing with unusual errors. + For example, running as the owner of the PostgreSQL installation: +

-bash-3.00$ createlang plperl template1
+createlang: language installation failed: ERROR:  could not load library "/opt/dbs/pgsql748/lib/plperl.so": A memory address is not in the address space for the process.

+ Running as a non-owner in the group possessing the PostgreSQL + installation: +

-bash-3.00$ createlang plperl template1
+createlang: language installation failed: ERROR:  could not load library "/opt/dbs/pgsql748/lib/plperl.so": Bad address

+ Another example is out of memory errors in the PostgreSQL server + logs, with every memory allocation near or greater than 256 MB + failing. +

The overall cause of all these problems is the default bittedness + and memory model used by the server process. By default, all + binaries built on AIX are 32-bit. This does not depend upon + hardware type or kernel in use. These 32-bit processes are + limited to 4 GB of memory laid out in 256 MB segments using one + of a few models. The default allows for less than 256 MB in the + heap as it shares a single segment with the stack. +

In the case of the createlang example, above, + check your umask and the permissions of the binaries in your + PostgreSQL installation. The binaries involved in that example + were 32-bit and installed as mode 750 instead of 755. Due to the + permissions being set in this fashion, only the owner or a member + of the possessing group can load the library. Since it isn't + world-readable, the loader places the object into the process' + heap instead of the shared library segments where it would + otherwise be placed. +

The "ideal" solution for this is to use a 64-bit + build of PostgreSQL, but that is not always practical, because + systems with 32-bit processors can build, but not run, 64-bit + binaries. +

If a 32-bit binary is desired, set LDR_CNTRL to + MAXDATA=0xn0000000, + where 1 <= n <= 8, before starting the PostgreSQL server, + and try different values and postgresql.conf + settings to find a configuration that works satisfactorily. This + use of LDR_CNTRL tells AIX that you want the + server to have MAXDATA bytes set aside for the + heap, allocated in 256 MB segments. When you find a workable + configuration, + ldedit can be used to modify the binaries so + that they default to using the desired heap size. PostgreSQL can + also be rebuilt, passing configure + LDFLAGS="-Wl,-bmaxdata:0xn0000000" + to achieve the same effect. +

For a 64-bit build, set OBJECT_MODE to 64 and + pass CC="gcc -maix64" + and LDFLAGS="-Wl,-bbigtoc" + to configure. (Options for + xlc might differ.) If you omit the export of + OBJECT_MODE, your build may fail with linker errors. When + OBJECT_MODE is set, it tells AIX's build utilities + such as ar, as, and ld what + type of objects to default to handling. +

By default, overcommit of paging space can happen. While we have + not seen this occur, AIX will kill processes when it runs out of + memory and the overcommit is accessed. The closest to this that + we have seen is fork failing because the system decided that + there was not enough memory for another process. Like many other + parts of AIX, the paging space allocation method and + out-of-memory kill is configurable on a system- or process-wide + basis if this becomes a problem. +

References and Resources

"Large Program Support", AIX Documentation: General Programming Concepts: Writing and Debugging Programs.

"Program Address Space Overview", AIX Documentation: General Programming Concepts: Writing and Debugging Programs.

"Performance Overview of the Virtual Memory Manager (VMM)", AIX Documentation: Performance Management Guide.

"Page Space Allocation", AIX Documentation: Performance Management Guide.

"Paging-space thresholds tuning", AIX Documentation: Performance Management Guide.

15.7.2. Cygwin

PostgreSQL can be built using Cygwin, a Linux-like environment for + Windows, but that method is inferior to the native Windows build + (see Chapter 16) and + running a server under Cygwin is no longer recommended. +

When building from source, proceed according to the normal + installation procedure (i.e., ./configure; + make; etc.), noting the following-Cygwin specific + differences: + +

  • Set your path to use the Cygwin bin directory before the + Windows utilities. This will help prevent problems with + compilation. +

  • The GNU make command is called make, not gmake. +

  • The adduser command is not supported; use + the appropriate user management application on Windows NT, + 2000, or XP. Otherwise, skip this step. +

  • The su command is not supported; use ssh to + simulate su on Windows NT, 2000, or XP. Otherwise, skip this + step. +

  • OpenSSL is not supported. +

  • Start cygserver for shared memory support. + To do this, enter the command /usr/sbin/cygserver + &. This program needs to be running anytime you + start the PostgreSQL server or initialize a database cluster + (initdb). The + default cygserver configuration may need to + be changed (e.g., increase SEMMNS) to prevent + PostgreSQL from failing due to a lack of system resources. +

  • Building might fail on some systems where a locale other than + C is in use. To fix this, set the locale to C by doing + export LANG=C.utf8 before building, and then + setting it back to the previous setting, after you have installed + PostgreSQL. +

  • The parallel regression tests (make check) + can generate spurious regression test failures due to + overflowing the listen() backlog queue + which causes connection refused errors or hangs. You can limit + the number of connections using the make + variable MAX_CONNECTIONS thus: +

    make MAX_CONNECTIONS=5 check

    + (On some systems you can have up to about 10 simultaneous + connections). +

+

It is possible to install cygserver and the + PostgreSQL server as Windows NT services. For information on how + to do this, please refer to the README + document included with the PostgreSQL binary package on Cygwin. + It is installed in the + directory /usr/share/doc/Cygwin. +

15.7.3. HP-UX

PostgreSQL 7.3+ should work on Series 700/800 PA-RISC machines + running HP-UX 10.X or 11.X, given appropriate system patch levels + and build tools. At least one developer routinely tests on HP-UX + 10.20, and we have reports of successful installations on HP-UX + 11.00 and 11.11. +

Aside from the PostgreSQL source distribution, you will need GNU + make (HP's make will not do), and either GCC or HP's full ANSI C + compiler. If you intend to build from Git sources rather than a + distribution tarball, you will also need Flex (GNU lex) and Bison + (GNU yacc). We also recommend making sure you are fairly + up-to-date on HP patches. At a minimum, if you are building 64 + bit binaries on HP-UX 11.11 you may need PHSS_30966 (11.11) or a + successor patch otherwise initdb may hang: +

PHSS_30966  s700_800 ld(1) and linker tools cumulative patch

+ + On general principles you should be current on libc and ld/dld + patches, as well as compiler patches if you are using HP's C + compiler. See HP's support sites such + as http://itrc.hp.com and + ftp://us-ffs.external.hp.com/ for free + copies of their latest patches. +

If you are building on a PA-RISC 2.0 machine and want to have + 64-bit binaries using GCC, you must use GCC 64-bit version. GCC + binaries for HP-UX PA-RISC and Itanium are available from + http://www.hp.com/go/gcc. Don't forget to + get and install binutils at the same time. +

If you are building on a PA-RISC 2.0 machine and want the compiled + binaries to run on PA-RISC 1.1 machines you will need to specify + +DAportable in CFLAGS. +

If you are building on a HP-UX Itanium machine, you will need the + latest HP ANSI C compiler with its dependent patch or successor + patches: +

PHSS_30848  s700_800 HP C Compiler (A.05.57)
+PHSS_30849  s700_800 u2comp/be/plugin library Patch

+

If you have both HP's C compiler and GCC's, then you might want to + explicitly select the compiler to use when you + run configure: +

./configure CC=cc

+ for HP's C compiler, or +

./configure CC=gcc

+ for GCC. If you omit this setting, then configure will + pick gcc if it has a choice. +

The default install target location + is /usr/local/pgsql, which you might want to + change to something under /opt. If so, use + the + --prefix switch to configure. +

In the regression tests, there might be some low-order-digit + differences in the geometry tests, which vary depending on which + compiler and math library versions you use. Any other error is + cause for suspicion. +

15.7.4. IRIX

PostgreSQL has been reported to run successfully on MIPS r8000, + r10000 (both ip25 and ip27) and r12000(ip35) processors, running + IRIX 6.5.5m, 6.5.12, 6.5.13, and 6.5.26 with MIPSPro compilers + version 7.30, 7.3.1.2m, 7.3, and 7.4.4m. +

You will need the MIPSPro full ANSI C compiler. There are + problems trying to build with GCC. It is a known GCC bug (not + fixed as of version 3.0) related to using functions that return + certain kinds of structures. This bug affects functions like + inet_ntoa, inet_lnaof, inet_netof, inet_makeaddr, + and semctl. It is supposed to be fixed by forcing + code to link those functions with libgcc, but this has not been + tested yet. +

It is known that version 7.4.1m of the MIPSPro compiler generates + incorrect code. The symptom is "invalid primary checkpoint + record" when trying to start the database.) Version 7.4.4m + is OK; the status of intermediate versions is uncertain. +

There may be a compilation problem like the following: +

cc-1020 cc: ERROR File = pqcomm.c, Line = 427
+  The identifier "TCP_NODELAY" is undefined.
+
+                if (setsockopt(port->sock, IPPROTO_TCP, TCP_NODELAY,

+ Some versions include TCP definitions + in sys/xti.h, so it is necessary to + add #include <sys/xti.h> + in src/backend/libpq/pqcomm.c and in + src/interfaces/libpq/fe-connect.c. If you encounter + this, please let us know so we can develop a proper fix. +

In the regression tests, there might be some low-order-digit + differences in the geometry tests, depending on which FPU are you + using. Any other error is cause for suspicion. +

15.7.5. MinGW/Native Windows

PostgreSQL for Windows can be built using MinGW, a Unix-like build + environment for Microsoft operating systems, or using + Microsoft's Visual C++ compiler suite. + The MinGW build variant uses the normal build system described in + this chapter; the Visual C++ build works completely differently + and is described in Chapter 16. + It is a fully native build and uses no additional software like + MinGW. A ready-made installer is available on the main + PostgreSQL web site. +

The native Windows port requires a 32 or 64-bit version of Windows + 2000 or later. Earlier operating systems do + not have sufficient infrastructure (but Cygwin may be used on + those). MinGW, the Unix-like build tools, and MSYS, a collection + of Unix tools required to run shell scripts + like configure, can be downloaded + from http://www.mingw.org/. Neither is + required to run the resulting binaries; they are needed only for + creating the binaries. +

To build 64 bit binaries using MinGW, install the 64 bit tool set + from http://mingw-w64.sourceforge.net/, put its bin + directory in the PATH, and run + configure with the + --host=x86_64-w64-mingw option. +

After you have everything installed, it is suggested that you + run psql + under CMD.EXE, as the MSYS console has + buffering issues. +

15.7.5.1. Collecting Crash Dumps on Windows

If PostgreSQL on Windows crashes, it has the ability to generate + minidumps that can be used to track down the cause + for the crash, similar to core dumps on Unix. These dumps can be + read using the Windows Debugger Tools or using + Visual Studio. To enable the generation of dumps + on Windows, create a subdirectory named crashdumps + inside the cluster data directory. The dumps will then be written + into this directory with a unique name based on the identifier of + the crashing process and the current time of the crash. +

15.7.6. SCO OpenServer and SCO UnixWare

PostgreSQL can be built on SCO UnixWare 7 and SCO OpenServer 5. + On OpenServer, you can use either the OpenServer Development Kit + or the Universal Development Kit. However, some tweaking may be + needed, as described below. +

15.7.6.1. Skunkware

You should locate your copy of the SCO Skunkware CD. The + Skunkware CD is included with UnixWare 7 and current versions of + OpenServer 5. Skunkware includes ready-to-install versions of + many popular programs that are available on the Internet. For + example, gzip, gunzip, GNU Make, Flex, and Bison are all + included. For UnixWare 7.1, this CD is now labeled "Open License + Software Supplement". If you do not have this CD, the software + on it is available + from http://www.sco.com/skunkware/. +

Skunkware has different versions for UnixWare and OpenServer. + Make sure you install the correct version for your operating + system, except as noted below. +

On UnixWare 7.1.3 and beyond, the GCC compiler is included on the + UDK CD as is GNU Make. +

15.7.6.2. GNU Make

You need to use the GNU Make program, which is on the Skunkware + CD. By default, it installs + as /usr/local/bin/make. To avoid confusion + with the SCO make program, you may want to rename GNU make to + gmake. +

As of UnixWare 7.1.3 and above, the GNU Make program is the + OSTK portion of the UDK CD, and is + in /usr/gnu/bin/gmake. +

15.7.6.3. Readline

The Readline library is on the Skunkware CD. But it is not + included on the UnixWare 7.1 Skunkware CD. If you have the + UnixWare 7.0.0 or 7.0.1 Skunkware CDs, you can install it from + there. Otherwise, + try http://www.sco.com/skunkware/. +

By default, Readline installs into /usr/local/lib and + /usr/local/include. However, the + PostgreSQL configure program will not find it + there without help. If you installed Readline, then use the + following options to configure: +

./configure --with-libraries=/usr/local/lib --with-includes=/usr/local/include

+

15.7.6.4. Using the UDK on OpenServer

If you are using the new Universal Development Kit (UDK) compiler + on OpenServer, you need to specify the locations of the UDK + libraries: +

./configure --with-libraries=/udk/usr/lib --with-includes=/udk/usr/include

+ Putting these together with the Readline options from above: +

./configure --with-libraries="/udk/usr/lib /usr/local/lib" --with-includes="/udk/usr/include /usr/local/include"

+

15.7.6.5. Reading the PostgreSQL Man Pages

By default, the PostgreSQL man pages are installed into + /usr/local/pgsql/man. By default, UnixWare + does not look there for man pages. To be able to read them you + need to modify the + MANPATH variable + in /etc/default/man, for example: +

MANPATH=/usr/lib/scohelp/%L/man:/usr/dt/man:/usr/man:/usr/share/man:scohelp:/usr/local/man:/usr/local/pgsql/man

+

On OpenServer, some extra research needs to be invested to make + the man pages usable, because the man system is a bit different + from other platforms. Currently, PostgreSQL will not install + them at all. +

15.7.6.6. C99 Issues with the 7.1.1b Feature Supplement

For compilers earlier than the one released with OpenUNIX 8.0.0 + (UnixWare 7.1.2), including the 7.1.1b Feature Supplement, you + may need to specify -Xb + in CFLAGS or the CC + environment variable. The indication of this is an error in + compiling tuplesort.c referencing inline + functions. Apparently there was a change in the 7.1.2(8.0.0) + compiler and beyond. +

15.7.6.7. Threading on UnixWare

For threading, youmust use -Kpthread + on all libpq-using programs. libpq + uses pthread_* calls, which are only + available with the + -Kpthread/-Kthread flag. +

15.7.7. Solaris

PostgreSQL is well-supported on Solaris. The more up to date your + operating system, the fewer issues you will experience; details + below. +

15.7.7.1. Required Tools

You can build with either GCC or Sun's compiler suite. For + better code optimization, Sun's compiler is strongly recommended + on the SPARC architecture. We have heard reports of problems + when using GCC 2.95.1; GCC 2.95.3 or later is recommended. If + you are using Sun's compiler, be careful not to select + /usr/ucb/cc; + use /opt/SUNWspro/bin/cc. +

You can download Sun Studio + from http://developers.sun.com/sunstudio/downloads/. + Many of GNU tools are integrated into Solaris 10, or they are + present on the Solaris companion CD. If you like packages for + older version of Solaris, you can find these tools + at http://www.sunfreeware.com + or http://www.blastwave.org. If you prefer + sources, look + at http://www.gnu.org/order/ftp.html. +

15.7.7.2. Problems with OpenSSL

When you build PostgreSQL with OpenSSL support you might get + compilation errors in the following files: +

  • src/backend/libpq/crypt.c

  • src/backend/libpq/password.c

  • src/interfaces/libpq/fe-auth.c

  • src/interfaces/libpq/fe-connect.c

+ + This is because of a namespace conflict between the standard + /usr/include/crypt.h header and the header + files provided by OpenSSL. +

Upgrading your OpenSSL installation to version 0.9.6a fixes this + problem. Solaris 9 and above has a newer version of OpenSSL. +

15.7.7.3. configure Complains About a Failed Test Program

If configure complains about a failed test + program, this is probably a case of the run-time linker being + unable to find some library, probably libz, libreadline or some + other non-standard library such as libssl. To point it to the + right location, set the LDFLAGS environment + variable on the configure command line, e.g., +

configure ... LDFLAGS="-R /usr/sfw/lib:/opt/sfw/lib:/usr/local/lib"

+ See + the ld + man page for more information. +

15.7.7.4. 64-bit Build Sometimes Crashes

On Solaris 7 and older, the 64-bit version of libc has a buggy + vsnprintf routine, which leads to erratic + core dumps in PostgreSQL. The simplest known workaround is to + force PostgreSQL to use its own version of vsnprintf rather than + the library copy. To do this, after you + run configure edit a file produced by + configure: + In src/Makefile.global, change the line +

LIBOBJS =

+ to read +

LIBOBJS = snprintf.o

+ (There might be other files already listed in this variable. + Order does not matter.) Then build as usual. +

15.7.7.5. Compiling for Optimal Performance

On the SPARC architecture, Sun Studio is strongly recommended for + compilation. Try using the -xO5 optimization + flag to generate significantly faster binaries. Do not use any + flags that modify behavior of floating-point operations + and errno processing (e.g., + -fast). These flags could raise some + nonstandard PostgreSQL behavior for example in the date/time + computing. +

If you do not have a reason to use 64-bit binaries on SPARC, + prefer the 32-bit version. The 64-bit operations are slower and + 64-bit binaries are slower than the 32-bit variants. And on + other hand, 32-bit code on the AMD64 CPU family is not native, + and that is why 32-bit code is significant slower on this CPU + family. +

Some tricks for tuning PostgreSQL and Solaris for performance can + be found + at http://www.sun.com/servers/coolthreads/tnb/applications_postgresql.jsp. + This article is primary focused on T2000 platform, but many of + the recommendations are also useful on other hardware with + Solaris. +

15.7.7.6. Using DTrace for Tracing PostgreSQL

Yes, using DTrace is possible. See + Section 27.4 for further + information. You can also find more information in this + article: http://blogs.sun.com/robertlor/entry/user_level_dtrace_probes_in. +

If you see the linking of the postgres executable abort with an + error message like: +

Undefined                       first referenced
+ symbol                             in file
+AbortTransaction                    utils/probes.o
+CommitTransaction                   utils/probes.o
+ld: fatal: Symbol referencing errors. No output written to postgres
+collect2: ld returned 1 exit status
+gmake: *** [postgres] Error 1

+ your DTrace installation is too old to handle probes in static + functions. You need Solaris 10u4 or newer. +


PrevHomeNext
Supported PlatformsUpInstallation from Source Code on Windows
\ No newline at end of file diff --git a/doc/src/sgml/html/installation.html b/doc/src/sgml/html/installation.html new file mode 100644 index 000000000..df0bb678a --- /dev/null +++ b/doc/src/sgml/html/installation.html @@ -0,0 +1,272 @@ + + Installation from Source Code

Chapter 15. Installation from Source Code

This + chapter describes the installation of + PostgreSQL using the source code + distribution. (If you are installing a pre-packaged distribution, + such as an RPM or Debian package, ignore this + + chapter + and read the packager's instructions instead.) +


PrevHomeNext
Server AdministrationUpShort Version
\ No newline at end of file diff --git a/doc/src/sgml/html/intagg.html b/doc/src/sgml/html/intagg.html new file mode 100644 index 000000000..80e75a827 --- /dev/null +++ b/doc/src/sgml/html/intagg.html @@ -0,0 +1,336 @@ + +intagg
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.17. intagg

The intagg module provides an integer aggregator and an + enumerator. intagg is now obsolete, because there + are built-in functions that provide a superset of its capabilities. + However, the module is still provided as a compatibility wrapper around + the built-in functions. +

F.17.1. Functions

The aggregator is an aggregate function + int_array_aggregate(integer) + that produces an integer array + containing exactly the integers it is fed. + This is a wrapper around array_agg, + which does the same thing for any array type. +

The enumerator is a function + int_array_enum(integer[]) + that returns setof integer. It is essentially the reverse + operation of the aggregator: given an array of integers, expand it + into a set of rows. This is a wrapper around unnest, + which does the same thing for any array type. +

F.17.2. Sample Uses

Many database systems have the notion of a one to many table. Such a table + usually sits between two indexed tables, for example: + +

CREATE TABLE left (id INT PRIMARY KEY, ...);
+CREATE TABLE right (id INT PRIMARY KEY, ...);
+CREATE TABLE one_to_many(left INT REFERENCES left, right INT REFERENCES right);

+ + It is typically used like this: + +

SELECT right.* from right JOIN one_to_many ON (right.id = one_to_many.right)
+  WHERE one_to_many.left = item;

+ + This will return all the items in the right hand table for an entry + in the left hand table. This is a very common construct in SQL. +

Now, this methodology can be cumbersome with a very large number of + entries in the one_to_many table. Often, + a join like this would result in an index scan + and a fetch for each right hand entry in the table for a particular + left hand entry. If you have a very dynamic system, there is not much you + can do. However, if you have some data which is fairly static, you can + create a summary table with the aggregator. + +

CREATE TABLE summary AS
+  SELECT left, int_array_aggregate(right) AS right
+  FROM one_to_many
+  GROUP BY left;

+ + This will create a table with one row per left item, and an array + of right items. Now this is pretty useless without some way of using + the array; that's why there is an array enumerator. You can do + +

SELECT left, int_array_enum(right) FROM summary WHERE left = item;

+ + The above query using int_array_enum produces the same results + as + +

SELECT left, right FROM one_to_many WHERE left = item;

+ + The difference is that the query against the summary table has to get + only one row from the table, whereas the direct query against + one_to_many must index scan and fetch a row for each entry. +

On one system, an EXPLAIN showed a query with a cost of 8488 was + reduced to a cost of 329. The original query was a join involving the + one_to_many table, which was replaced by: + +

SELECT right, count(right) FROM
+  ( SELECT left, int_array_enum(right) AS right
+    FROM summary JOIN (SELECT left FROM left_table WHERE left = item) AS lefts
+         ON (summary.left = lefts.left)
+  ) AS list
+  GROUP BY right
+  ORDER BY count DESC;

+


PrevHomeNext
hstoreUpintarray
\ No newline at end of file diff --git a/doc/src/sgml/html/intarray.html b/doc/src/sgml/html/intarray.html new file mode 100644 index 000000000..5768993bd --- /dev/null +++ b/doc/src/sgml/html/intarray.html @@ -0,0 +1,972 @@ + +intarray
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.18. intarray

The intarray module provides a number of useful functions + and operators for manipulating null-free arrays of integers. + There is also support for indexed searches using some of the operators. +

All of these operations will throw an error if a supplied array contains any + NULL elements. +

Many of these operations are only sensible for one-dimensional arrays. + Although they will accept input arrays of more dimensions, the data is + treated as though it were a linear array in storage order. +

F.18.1. intarray Functions and Operators

The functions provided by the intarray module + are shown in Table F-8, the operators + in Table F-9. +

Table F-8. intarray Functions

FunctionReturn TypeDescriptionExampleResult
icount(int[])intnumber of elements in arrayicount('{1,2,3}'::int[])3
sort(int[], text dir)int[]sort array — dir must be asc or descsort('{1,2,3}'::int[], 'desc'){3,2,1}
sort(int[])int[]sort in ascending ordersort(array[11,77,44]){11,44,77}
sort_asc(int[])int[]sort in ascending order
sort_desc(int[])int[]sort in descending order
uniq(int[])int[]remove adjacent duplicatesuniq(sort('{1,2,3,2,1}'::int[])){1,2,3}
idx(int[], int item)intindex of first element matching item (0 if none)idx(array[11,22,33,22,11], 22)2
subarray(int[], int start, int len)int[]portion of array starting at position start, len elementssubarray('{1,2,3,2,1}'::int[], 2, 3){2,3,2}
subarray(int[], int start)int[]portion of array starting at position startsubarray('{1,2,3,2,1}'::int[], 2){2,3,2,1}
intset(int)int[]make single-element arrayintset(42){42}

Table F-9. intarray Operators

OperatorReturnsDescription
int[] && int[]booleanoverlap — true if arrays have at least one common element
int[] @> int[]booleancontains — true if left array contains right array
int[] <@ int[]booleancontained — true if left array is contained in right array
# int[]intnumber of elements in array
int[] # intintindex (same as idx function)
int[] + intint[]push element onto array (add it to end of array)
int[] + int[] int[]array concatenation (right array added to the end of left one)
int[] - intint[]remove entries matching right argument from array
int[] - int[]int[]remove elements of right array from left
int[] | intint[]union of arguments
int[] | int[]int[]union of arrays
int[] & int[]int[]intersection of arrays
int[] @@ query_intbooleantrue if array satisfies query (see below)
query_int ~~ int[]booleantrue if array satisfies query (commutator of @@)

(Before PostgreSQL 8.2, the containment operators @> and + <@ were respectively called @ and ~. + These names are still available, but are deprecated and will eventually be + retired. Notice that the old names are reversed from the convention + formerly followed by the core geometric data types!) +

The operators &&, @> and + <@ are equivalent to PostgreSQL's built-in + operators of the same names, except that they work only on integer arrays + that do not contain nulls, while the built-in operators work for any array + type. This restriction makes them faster than the built-in operators + in many cases. +

The @@ and ~~ operators test whether an array + satisfies a query, which is expressed as a value of a + specialized data type query_int. A query + consists of integer values that are checked against the elements of + the array, possibly combined using the operators & + (AND), | (OR), and ! (NOT). Parentheses + can be used as needed. For example, + the query 1&(2|3) matches arrays that contain 1 + and also contain either 2 or 3. +

F.18.2. Index Support

intarray provides index support for the + &&, @>, <@, + and @@ operators, as well as regular array equality. +

Two GiST index operator classes are provided: + gist__int_ops (used by default) is suitable for + small- to medium-size data sets, while + gist__intbig_ops uses a larger signature and is more + suitable for indexing large data sets (i.e., columns containing + a large number of distinct array values). + The implementation uses an RD-tree data structure with + built-in lossy compression. +

There is also a non-default GIN operator class + gin__int_ops supporting the same operators. +

The choice between GiST and GIN indexing depends on the relative + performance characteristics of GiST and GIN, which are discussed elsewhere. + As a rule of thumb, a GIN index is faster to search than a GiST index, but + slower to build or update; so GIN is better suited for static data and GiST + for often-updated data. +

F.18.3. Example

-- a message can be in one or more "sections"
+CREATE TABLE message (mid INT PRIMARY KEY, sections INT[], ...);
+
+-- create specialized index
+CREATE INDEX message_rdtree_idx ON message USING GIST (sections gist__int_ops);
+
+-- select messages in section 1 OR 2 - OVERLAP operator
+SELECT message.mid FROM message WHERE message.sections && '{1,2}';
+
+-- select messages in sections 1 AND 2 - CONTAINS operator
+SELECT message.mid FROM message WHERE message.sections @> '{1,2}';
+
+-- the same, using QUERY operator
+SELECT message.mid FROM message WHERE message.sections @@ '1&2'::query_int;

F.18.4. Benchmark

The source directory contrib/intarray/bench contains a + benchmark test suite. To run: +

cd .../bench
+createdb TEST
+psql TEST < ../_int.sql
+./create_test.pl | psql TEST
+./bench.pl

The bench.pl script has numerous options, which + are displayed when it is run without any arguments. +

F.18.5. Authors

All work was done by Teodor Sigaev (<teodor@sigaev.ru>) and + Oleg Bartunov (<oleg@sai.msu.su>). See + http://www.sai.msu.su/~megera/postgres/gist/ for + additional information. Andrey Oktyabrski did a great work on adding new + functions and operations. +

\ No newline at end of file diff --git a/doc/src/sgml/html/internals.html b/doc/src/sgml/html/internals.html new file mode 100644 index 000000000..007f41a87 --- /dev/null +++ b/doc/src/sgml/html/internals.html @@ -0,0 +1,1188 @@ + +Internals

VII. Internals

This part contains assorted information that might be of use to + PostgreSQL developers. +

Table of Contents
44. Overview of PostgreSQL Internals
44.1. The Path of a Query
44.2. How Connections are Established
44.3. The Parser Stage
44.4. The PostgreSQL Rule System
44.5. Planner/Optimizer
44.6. Executor
45. System Catalogs
45.1. Overview
45.2. pg_aggregate
45.3. pg_am
45.4. pg_amop
45.5. pg_amproc
45.6. pg_attrdef
45.7. pg_attribute
45.8. pg_authid
45.9. pg_auth_members
45.10. pg_cast
45.11. pg_class
45.12. pg_constraint
45.13. pg_collation
45.14. pg_conversion
45.15. pg_database
45.16. pg_db_role_setting
45.17. pg_default_acl
45.18. pg_depend
45.19. pg_description
45.20. pg_enum
45.21. pg_extension
45.22. pg_foreign_data_wrapper
45.23. pg_foreign_server
45.24. pg_foreign_table
45.25. pg_index
45.26. pg_inherits
45.27. pg_language
45.28. pg_largeobject
45.29. pg_largeobject_metadata
45.30. pg_namespace
45.31. pg_opclass
45.32. pg_operator
45.33. pg_opfamily
45.34. pg_pltemplate
45.35. pg_proc
45.36. pg_range
45.37. pg_rewrite
45.38. pg_seclabel
45.39. pg_shdepend
45.40. pg_shdescription
45.41. pg_shseclabel
45.42. pg_statistic
45.43. pg_tablespace
45.44. pg_trigger
45.45. pg_ts_config
45.46. pg_ts_config_map
45.47. pg_ts_dict
45.48. pg_ts_parser
45.49. pg_ts_template
45.50. pg_type
45.51. pg_user_mapping
45.52. System Views
45.53. pg_available_extensions
45.54. pg_available_extension_versions
45.55. pg_cursors
45.56. pg_group
45.57. pg_indexes
45.58. pg_locks
45.59. pg_prepared_statements
45.60. pg_prepared_xacts
45.61. pg_roles
45.62. pg_rules
45.63. pg_seclabels
45.64. pg_settings
45.65. pg_shadow
45.66. pg_stats
45.67. pg_tables
45.68. pg_timezone_abbrevs
45.69. pg_timezone_names
45.70. pg_user
45.71. pg_user_mappings
45.72. pg_views
46. Frontend/Backend Protocol
46.1. Overview
46.2. Message Flow
46.3. Streaming Replication Protocol
46.4. Message Data Types
46.5. Message Formats
46.6. Error and Notice Message Fields
46.7. Summary of Changes since Protocol 2.0
47. PostgreSQL Coding Conventions
47.1. Formatting
47.2. Reporting Errors Within the Server
47.3. Error Message Style Guide
48. Native Language Support
48.1. For the Translator
48.2. For the Programmer
49. Writing A Procedural Language Handler
50. Writing A Foreign Data Wrapper
50.1. Foreign Data Wrapper Functions
50.2. Foreign Data Wrapper Callback Routines
50.3. Foreign Data Wrapper Helper Functions
50.4. Foreign Data Wrapper Query Planning
51. Genetic Query Optimizer
51.1. Query Handling as a Complex Optimization Problem
51.2. Genetic Algorithms
51.3. Genetic Query Optimization (GEQO) in PostgreSQL
51.4. Further Reading
52. Index Access Method Interface Definition
52.1. Catalog Entries for Indexes
52.2. Index Access Method Functions
52.3. Index Scanning
52.4. Index Locking Considerations
52.5. Index Uniqueness Checks
52.6. Index Cost Estimation Functions
53. GiST Indexes
53.1. Introduction
53.2. Extensibility
53.3. Implementation
53.4. Examples
54. SP-GiST Indexes
54.1. Introduction
54.2. Extensibility
54.3. Implementation
54.4. Examples
55. GIN Indexes
55.1. Introduction
55.2. Extensibility
55.3. Implementation
55.4. GIN Tips and Tricks
55.5. Limitations
55.6. Examples
56. Database Physical Storage
56.1. Database File Layout
56.2. TOAST
56.3. Free Space Map
56.4. Visibility Map
56.5. The Initialization Fork
56.6. Database Page Layout
57. BKI Backend Interface
57.1. BKI File Format
57.2. BKI Commands
57.3. Structure of the Bootstrap BKI File
57.4. Example
58. How the Planner Uses Statistics
58.1. Row Estimation Examples

PrevHomeNext
postmaster Overview of PostgreSQL Internals
\ No newline at end of file diff --git a/doc/src/sgml/html/intro-whatis.html b/doc/src/sgml/html/intro-whatis.html new file mode 100644 index 000000000..a12284ffa --- /dev/null +++ b/doc/src/sgml/html/intro-whatis.html @@ -0,0 +1,275 @@ + + What is PostgreSQL?

What is PostgreSQL?

PostgreSQL is an object-relational + database management system (ORDBMS) based on + POSTGRES, Version 4.2, + developed at the University of California at Berkeley Computer Science + Department. POSTGRES pioneered many concepts that only became + available in some commercial database systems much later. +

PostgreSQL is an open-source descendant + of this original Berkeley code. It supports a large part of the SQL + standard and offers many modern features: + +

  • complex queries
  • foreign keys
  • triggers
  • views
  • transactional integrity
  • multiversion concurrency control

+ + Also, PostgreSQL can be extended by the + user in many ways, for example by adding new + +

  • data types
  • functions
  • operators
  • aggregate functions
  • index methods
  • procedural languages

+

And because of the liberal license, + PostgreSQL can be used, modified, and + distributed by anyone free of charge for any purpose, be it + private, commercial, or academic. +


PrevHomeNext
PrefaceUpA Brief History of PostgreSQL
\ No newline at end of file diff --git a/doc/src/sgml/html/isn.html b/doc/src/sgml/html/isn.html new file mode 100644 index 000000000..a4cada459 --- /dev/null +++ b/doc/src/sgml/html/isn.html @@ -0,0 +1,784 @@ + +isn
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.19. isn

The isn module provides data types for the following + international product numbering standards: EAN13, UPC, ISBN (books), ISMN + (music), and ISSN (serials). Numbers are validated on input according to a + hard-coded list of prefixes; this list of prefixes is also used to hyphenate + numbers on output. Since new prefixes are assigned from time to time, the + list of prefixes may be out of date. It is hoped that a future version of + this module will obtained the prefix list from one or more tables that + can be easily updated by users as needed; however, at present, the + list can only be updated by modifying the source code and recompiling. + Alternatively, prefix validation and hyphenation support may be + dropped from a future version of this module. +

F.19.1. Data Types

Table F-10 shows the data types provided by + the isn module. +

Table F-10. isn Data Types

Data TypeDescription
EAN13 European Article Numbers, always displayed in the EAN13 display format +
ISBN13 International Standard Book Numbers to be displayed in + the new EAN13 display format +
ISMN13 International Standard Music Numbers to be displayed in + the new EAN13 display format +
ISSN13 International Standard Serial Numbers to be displayed in the new + EAN13 display format +
ISBN International Standard Book Numbers to be displayed in the old + short display format +
ISMN International Standard Music Numbers to be displayed in the + old short display format +
ISSN International Standard Serial Numbers to be displayed in the + old short display format +
UPC Universal Product Codes +

Some notes: +

  1. ISBN13, ISMN13, ISSN13 numbers are all EAN13 numbers.

  2. EAN13 numbers aren't always ISBN13, ISMN13 or ISSN13 (some + are).

  3. Some ISBN13 numbers can be displayed as ISBN.

  4. Some ISMN13 numbers can be displayed as ISMN.

  5. Some ISSN13 numbers can be displayed as ISSN.

  6. UPC numbers are a subset of the EAN13 numbers (they are basically + EAN13 without the first 0 digit).

  7. All UPC, ISBN, ISMN and ISSN numbers can be represented as EAN13 + numbers.

Internally, all these types use the same representation (a 64-bit + integer), and all are interchangeable. Multiple types are provided + to control display formatting and to permit tighter validity checking + of input that is supposed to denote one particular type of number. +

The ISBN, ISMN, and ISSN types will display the + short version of the number (ISxN 10) whenever it's possible, and will show + ISxN 13 format for numbers that do not fit in the short version. + The EAN13, ISBN13, ISMN13 and + ISSN13 types will always display the long version of the ISxN + (EAN13). +

F.19.2. Casts

The isn module provides the following pairs of type casts: +

  • ISBN13 <=> EAN13 +

  • ISMN13 <=> EAN13 +

  • ISSN13 <=> EAN13 +

  • ISBN <=> EAN13 +

  • ISMN <=> EAN13 +

  • ISSN <=> EAN13 +

  • UPC <=> EAN13 +

  • ISBN <=> ISBN13 +

  • ISMN <=> ISMN13 +

  • ISSN <=> ISSN13 +

When casting from EAN13 to another type, there is a run-time + check that the value is within the domain of the other type, and an error + is thrown if not. The other casts are simply relabelings that will + always succeed. +

F.19.3. Functions and Operators

The isn module provides the standard comparison operators, + plus B-tree and hash indexing support for all these data types. In + addition there are several specialized functions; shown in Table F-11. + In this table, + isn means any one of the module's data types. +

Table F-11. isn Functions

FunctionReturnsDescription
isn_weak(boolean)booleanSets the weak input mode (returns new setting)
isn_weak()booleanGets the current status of the weak mode
make_valid(isn)isnValidates an invalid number (clears the invalid flag)
is_valid(isn)booleanChecks for the presence of the invalid flag

Weak mode is used to be able to insert invalid data + into a table. Invalid means the check digit is wrong, not that there are + missing numbers. +

Why would you want to use the weak mode? Well, it could be that + you have a huge collection of ISBN numbers, and that there are so many of + them that for weird reasons some have the wrong check digit (perhaps the + numbers were scanned from a printed list and the OCR got the numbers wrong, + perhaps the numbers were manually captured... who knows). Anyway, the point + is you might want to clean the mess up, but you still want to be able to + have all the numbers in your database and maybe use an external tool to + locate the invalid numbers in the database so you can verify the + information and validate it more easily; so for example you'd want to + select all the invalid numbers in the table. +

When you insert invalid numbers in a table using the weak mode, the number + will be inserted with the corrected check digit, but it will be displayed + with an exclamation mark (!) at the end, for example + 0-11-000322-5!. This invalid marker can be checked with + the is_valid function and cleared with the + make_valid function. +

You can also force the insertion of invalid numbers even when not in the + weak mode, by appending the ! character at the end of the + number. +

Another special feature is that during input, you can write + ? in place of the check digit, and the correct check digit + will be inserted automatically. +

F.19.4. Examples

--Using the types directly:
+SELECT isbn('978-0-393-04002-9');
+SELECT isbn13('0901690546');
+SELECT issn('1436-4522');
+
+--Casting types:
+-- note that you can only cast from ean13 to another type when the
+-- number would be valid in the realm of the target type;
+-- thus, the following will NOT work: select isbn(ean13('0220356483481'));
+-- but these will:
+SELECT upc(ean13('0220356483481'));
+SELECT ean13(upc('220356483481'));
+
+--Create a table with a single column to hold ISBN numbers:
+CREATE TABLE test (id isbn);
+INSERT INTO test VALUES('9780393040029');
+
+--Automatically calculate check digits (observe the '?'):
+INSERT INTO test VALUES('220500896?');
+INSERT INTO test VALUES('978055215372?');
+
+SELECT issn('3251231?');
+SELECT ismn('979047213542?');
+
+--Using the weak mode:
+SELECT isn_weak(true);
+INSERT INTO test VALUES('978-0-11-000533-4');
+INSERT INTO test VALUES('9780141219307');
+INSERT INTO test VALUES('2-205-00876-X');
+SELECT isn_weak(false);
+
+SELECT id FROM test WHERE NOT is_valid(id);
+UPDATE test SET id = make_valid(id) WHERE id = '2-205-00876-X!';
+
+SELECT * FROM test;
+
+SELECT isbn13(id) FROM test;

F.19.5. Bibliography

The information to implement this module was collected from + several sites, including: +

+ + The prefixes used for hyphenation were also compiled from: +

+ + Care was taken during the creation of the algorithms and they + were meticulously verified against the suggested algorithms + in the official ISBN, ISMN, ISSN User Manuals. +

F.19.6. Author

Germán Méndez Bravo (Kronuz), 2004 - 2006 +

This module was inspired by Garrett A. Wollman's + isbn_issn code. +


PrevHomeNext
intarrayUplo
\ No newline at end of file diff --git a/doc/src/sgml/html/kernel-resources.html b/doc/src/sgml/html/kernel-resources.html new file mode 100644 index 000000000..ae84f634e --- /dev/null +++ b/doc/src/sgml/html/kernel-resources.html @@ -0,0 +1,1819 @@ + +Managing Kernel Resources
PostgreSQL 9.2.2 Documentation
PrevUpChapter 17. Server Setup and OperationNext

17.4. Managing Kernel Resources

A large PostgreSQL installation can quickly exhaust + various operating system resource limits. (On some systems, the + factory defaults are so low that you don't even need a really + "large" installation.) If you have encountered this kind of + problem, keep reading. +

17.4.1. Shared Memory and Semaphores

Shared memory and semaphores are collectively referred to as + "System V + IPC" (together with message queues, which are not + relevant for PostgreSQL). Almost all modern + operating systems provide these features, but many of them don't have + them turned on or sufficiently sized by default, especially as + available RAM and the demands of database applications grow. + (On Windows, + PostgreSQL provides its own replacement + implementation of these facilities, so most of this section + can be disregarded.) +

The complete lack of these facilities is usually manifested by an + Illegal system call error upon server start. In + that case there is no alternative but to reconfigure your + kernel. PostgreSQL won't work without them. + This situation is rare, however, among modern operating systems. +

When PostgreSQL exceeds one of the various hard + IPC limits, the server will refuse to start and + should leave an instructive error message describing the problem + and what to do about it. (See also Section 17.3.1.) The relevant kernel + parameters are named consistently across different systems; Table 17-1 gives an overview. The methods to set + them, however, vary. Suggestions for some platforms are given below. +

Table 17-1. System V IPC Parameters

NameDescriptionReasonable values
SHMMAXMaximum size of shared memory segment (bytes)at least several megabytes (see text)
SHMMINMinimum size of shared memory segment (bytes)1
SHMALLTotal amount of shared memory available (bytes or pages)if bytes, same as SHMMAX; if pages, ceil(SHMMAX/PAGE_SIZE)
SHMSEGMaximum number of shared memory segments per processonly 1 segment is needed, but the default is much higher
SHMMNIMaximum number of shared memory segments system-widelike SHMSEG plus room for other applications
SEMMNIMaximum number of semaphore identifiers (i.e., sets)at least ceil((max_connections + autovacuum_max_workers + 4) / 16)
SEMMNSMaximum number of semaphores system-wideceil((max_connections + autovacuum_max_workers + 4) / 16) * 17 plus room for other applications
SEMMSLMaximum number of semaphores per setat least 17
SEMMAPNumber of entries in semaphore mapsee text
SEMVMXMaximum value of semaphoreat least 1000 (The default is often 32767; do not change unless necessary)

The most important + shared memory parameter is SHMMAX, the maximum size, in + bytes, of a shared memory segment. If you get an error message from + shmget like "Invalid argument", it is + likely that this limit has been exceeded. The size of the required + shared memory segment varies depending on several + PostgreSQL configuration parameters, as shown in + Table 17-2. (Any error message you might + get will include the exact size of the failed allocation request.) + You can, as a temporary solution, lower some of those settings to + avoid the failure. While it is possible to get + PostgreSQL to run with SHMMAX as small as + 2 MB, you need considerably more for acceptable performance. Desirable + settings are in the hundreds of megabytes to a few gigabytes. +

Some systems also have a limit on the total amount of shared memory in + the system (SHMALL). Make sure this is large enough + for PostgreSQL plus any other applications that + are using shared memory segments. Note that SHMALL + is measured in pages rather than bytes on many systems. +

Less likely to cause problems is the minimum size for shared + memory segments (SHMMIN), which should be at most + approximately 500 kB for PostgreSQL (it is + usually just 1). The maximum number of segments system-wide + (SHMMNI) or per-process (SHMSEG) are unlikely + to cause a problem unless your system has them set to zero. +

PostgreSQL uses one semaphore per allowed connection + (max_connections) and allowed autovacuum worker + process (autovacuum_max_workers), in sets of 16. + Each such set will + also contain a 17th semaphore which contains a "magic + number", to detect collision with semaphore sets used by + other applications. The maximum number of semaphores in the system + is set by SEMMNS, which consequently must be at least + as high as max_connections plus + autovacuum_max_workers, plus one extra for each 16 + allowed connections plus workers (see the formula in Table 17-1). The parameter SEMMNI + determines the limit on the number of semaphore sets that can + exist on the system at one time. Hence this parameter must be at + least ceil((max_connections + autovacuum_max_workers + 4) / 16). + Lowering the number + of allowed connections is a temporary workaround for failures, + which are usually confusingly worded "No space + left on device", from the function semget. +

In some cases it might also be necessary to increase + SEMMAP to be at least on the order of + SEMMNS. This parameter defines the size of the semaphore + resource map, in which each contiguous block of available semaphores + needs an entry. When a semaphore set is freed it is either added to + an existing entry that is adjacent to the freed block or it is + registered under a new map entry. If the map is full, the freed + semaphores get lost (until reboot). Fragmentation of the semaphore + space could over time lead to fewer available semaphores than there + should be. +

The SEMMSL parameter, which determines how many + semaphores can be in a set, must be at least 17 for + PostgreSQL. +

Various other settings related to "semaphore undo", such as + SEMMNU and SEMUME, do not affect + PostgreSQL. +

AIX

At least as of version 5.1, it should not be necessary to do + any special configuration for such parameters as + SHMMAX, as it appears this is configured to + allow all memory to be used as shared memory. That is the + sort of configuration commonly used for other databases such + as DB/2.

It might, however, be necessary to modify the global + ulimit information in + /etc/security/limits, as the default hard + limits for file sizes (fsize) and numbers of + files (nofiles) might be too low. +

FreeBSD

The default settings are only suitable for small installations + (for example, default SHMMAX is 32 + MB). Changes can be made via the sysctl or + loader interfaces. The following + parameters can be set using sysctl: +

$ sysctl -w kern.ipc.shmall=32768
+$ sysctl -w kern.ipc.shmmax=134217728
+$ sysctl -w kern.ipc.semmap=256

+ To have these settings persist over reboots, modify + /etc/sysctl.conf. +

The remaining semaphore settings are read-only as far as + sysctl is concerned, but can be changed + before boot using the loader prompt: +

(loader) set kern.ipc.semmni=256
+(loader) set kern.ipc.semmns=512
+(loader) set kern.ipc.semmnu=256

+ Similarly these can be saved between reboots in + /boot/loader.conf. +

You might also want to configure your kernel to lock shared + memory into RAM and prevent it from being paged out to swap. + This can be accomplished using the sysctl + setting kern.ipc.shm_use_phys. +

If running in FreeBSD jails by enabling sysctl's + security.jail.sysvipc_allowed, postmasters + running in different jails should be run by different operating system + users. This improves security because it prevents non-root users + from interfering with shared memory or semaphores in different jails, + and it allows the PostgreSQL IPC cleanup code to function properly. + (In FreeBSD 6.0 and later the IPC cleanup code does not properly detect + processes in other jails, preventing the running of postmasters on the + same port in different jails.) +

FreeBSD versions before 4.0 work like + OpenBSD (see below). +

NetBSD

In NetBSD 5.0 and later, + IPC parameters can be adjusted using sysctl, + for example: +

$ sysctl -w kern.ipc.shmmax=16777216

+ To have these settings persist over reboots, modify + /etc/sysctl.conf. +

You might also want to configure your kernel to lock shared + memory into RAM and prevent it from being paged out to swap. + This can be accomplished using the sysctl + setting kern.ipc.shm_use_phys. +

NetBSD versions before 5.0 work like + OpenBSD (see below), except that + parameters should be set with the keyword options not + option. +

OpenBSD

The options SYSVSHM and SYSVSEM need + to be enabled when the kernel is compiled. (They are by + default.) The maximum size of shared memory is determined by + the option SHMMAXPGS (in pages). The following + shows an example of how to set the various parameters: +

option        SYSVSHM
+option        SHMMAXPGS=4096
+option        SHMSEG=256
+
+option        SYSVSEM
+option        SEMMNI=256
+option        SEMMNS=512
+option        SEMMNU=256
+option        SEMMAP=256

+

You might also want to configure your kernel to lock shared + memory into RAM and prevent it from being paged out to swap. + This can be accomplished using the sysctl + setting kern.ipc.shm_use_phys. +

HP-UX

The default settings tend to suffice for normal installations. + On HP-UX 10, the factory default for + SEMMNS is 128, which might be too low for larger + database sites. +

IPC parameters can be set in the System + Administration Manager (SAM) under + Kernel + Configuration->Configurable Parameters. Choose + Create A New Kernel when you're done. +

Linux

The default maximum segment size is 32 MB, which is only adequate + for very small PostgreSQL + installations. The default maximum total size is 2097152 + pages. A page is almost always 4096 bytes except in unusual + kernel configurations with "huge pages" + (use getconf PAGE_SIZE to verify). That + makes a default limit of 8 GB, which is often enough, but not + always. +

The shared memory size settings can be changed via the + sysctl interface. For example, to allow 16 GB: +

$ sysctl -w kernel.shmmax=17179869184
+$ sysctl -w kernel.shmall=4194304

+ In addition these settings can be preserved between reboots in + the file /etc/sysctl.conf. Doing that is + highly recommended. +

Ancient distributions might not have the sysctl program, + but equivalent changes can be made by manipulating the + /proc file system: +

$ echo 17179869184 >/proc/sys/kernel/shmmax
+$ echo 4194304 >/proc/sys/kernel/shmall

+

The remaining defaults are quite generously sized, and usually + do not require changes. +

Mac OS X

The recommended method for configuring shared memory in OS X + is to create a file named /etc/sysctl.conf, + containing variable assignments such as: +

kern.sysv.shmmax=4194304
+kern.sysv.shmmin=1
+kern.sysv.shmmni=32
+kern.sysv.shmseg=8
+kern.sysv.shmall=1024

+ Note that in some OS X versions, + all five shared-memory parameters must be set in + /etc/sysctl.conf, else the values will be ignored. +

Beware that recent releases of OS X ignore attempts to set + SHMMAX to a value that isn't an exact multiple of 4096. +

SHMALL is measured in 4 kB pages on this platform. +

In older OS X versions, you will need to reboot to have changes in the + shared memory parameters take effect. As of 10.5 it is possible to + change all but SHMMNI on the fly, using + sysctl. But it's still best to set up your preferred + values via /etc/sysctl.conf, so that the values will be + kept across reboots. +

The file /etc/sysctl.conf is only honored in OS X + 10.3.9 and later. If you are running a previous 10.3.x release, + you must edit the file /etc/rc + and change the values in the following commands: +

sysctl -w kern.sysv.shmmax
+sysctl -w kern.sysv.shmmin
+sysctl -w kern.sysv.shmmni
+sysctl -w kern.sysv.shmseg
+sysctl -w kern.sysv.shmall

+ Note that + /etc/rc is usually overwritten by OS X system updates, + so you should expect to have to redo these edits after each update. +

In OS X 10.2 and earlier, instead edit these commands in the file + /System/Library/StartupItems/SystemTuning/SystemTuning. +

SCO OpenServer

In the default configuration, only 512 kB of shared memory per + segment is allowed. To increase the setting, first change to the + directory /etc/conf/cf.d. To display the current value of + SHMMAX, run: +

./configure -y SHMMAX

+ To set a new value for SHMMAX, run: +

./configure SHMMAX=value

+ where value is the new value you want to use + (in bytes). After setting SHMMAX, rebuild the kernel: +

./link_unix

+ and reboot. +

Solaris 2.6 to 2.9 (Solaris + 6 to Solaris 9)

The default maximum size of a shared memory segment is too low for + PostgreSQL. The relevant settings can be changed in + /etc/system, for example: +

set shmsys:shminfo_shmmax=0x2000000
+set shmsys:shminfo_shmmin=1
+set shmsys:shminfo_shmmni=256
+set shmsys:shminfo_shmseg=256
+
+set semsys:seminfo_semmap=256
+set semsys:seminfo_semmni=512
+set semsys:seminfo_semmns=512
+set semsys:seminfo_semmsl=32

+ You need to reboot for the changes to take effect. See also + http://sunsite.uakom.sk/sunworldonline/swol-09-1997/swol-09-insidesolaris.html + for information on shared memory under older versions of Solaris. +

Solaris 2.10 (Solaris + 10)
OpenSolaris

In Solaris 10 and OpenSolaris, the default shared memory and + semaphore settings are good enough for most + PostgreSQL applications. Solaris now defaults + to a SHMMAX of one-quarter of system RAM. If + you need to increase this in order to set shared memory settings + slightly higher, you should use a project setting associated + with the postgres user. For example, run the + following as root: +

projadd -c "PostgreSQL DB User" -K "project.max-shm-memory=(privileged,8GB,deny)" -U postgres -G postgres user.postgres

+

This command adds the user.postgres project and + raises the shared memory maximum for the postgres + user to 8GB, and takes effect the next time that user logs + in, or when you restart PostgreSQL (not reload). + The above assumes that PostgreSQL is run by + the postgres user in the postgres + group. No server reboot is required. +

Other recommended kernel setting changes for database servers which will + have a large number of connections are: +

project.max-shm-ids=(priv,32768,deny)
+project.max-sem-ids=(priv,4096,deny)
+project.max-msg-ids=(priv,4096,deny)

+

Additionally, if you are running PostgreSQL + inside a zone, you may need to raise the zone resource usage + limits as well. See "Chapter2: Projects and Tasks" in the + Solaris 10 System Administrator's Guide for more + information on projects and prctl. +

UnixWare

On UnixWare 7, the maximum size for shared + memory segments is only 512 kB in the default configuration. + To display the current value of SHMMAX, run: +

/etc/conf/bin/idtune -g SHMMAX

+ which displays the current, default, minimum, and maximum + values. To set a new value for SHMMAX, + run: +

/etc/conf/bin/idtune SHMMAX value

+ where value is the new value you want to use + (in bytes). After setting SHMMAX, rebuild the + kernel: +

/etc/conf/bin/idbuild -B

+ and reboot. +

Table 17-2. PostgreSQL Shared Memory Usage

UsageApproximate shared memory bytes required (as of 8.3)
Connections(1800 + 270 * max_locks_per_transaction) * max_connections
Autovacuum workers(1800 + 270 * max_locks_per_transaction) * autovacuum_max_workers
Prepared transactions(770 + 270 * max_locks_per_transaction) * max_prepared_transactions
Shared disk buffers(block_size + 208) * shared_buffers
WAL buffers(wal_block_size + 8) * wal_buffers
Fixed space requirements770 kB

17.4.2. Resource Limits

Unix-like operating systems enforce various kinds of resource limits + that might interfere with the operation of your + PostgreSQL server. Of particular + importance are limits on the number of processes per user, the + number of open files per process, and the amount of memory available + to each process. Each of these have a "hard" and a + "soft" limit. The soft limit is what actually counts + but it can be changed by the user up to the hard limit. The hard + limit can only be changed by the root user. The system call + setrlimit is responsible for setting these + parameters. The shell's built-in command ulimit + (Bourne shells) or limit (csh) is + used to control the resource limits from the command line. On + BSD-derived systems the file /etc/login.conf + controls the various resource limits set during login. See the + operating system documentation for details. The relevant + parameters are maxproc, + openfiles, and datasize. For + example: +

default:\
+...
+        :datasize-cur=256M:\
+        :maxproc-cur=256:\
+        :openfiles-cur=256:\
+...

+ (-cur is the soft limit. Append + -max to set the hard limit.) +

Kernels can also have system-wide limits on some resources. +

  • On Linux + /proc/sys/fs/file-max determines the + maximum number of open files that the kernel will support. It can + be changed by writing a different number into the file or by + adding an assignment in /etc/sysctl.conf. + The maximum limit of files per process is fixed at the time the + kernel is compiled; see + /usr/src/linux/Documentation/proc.txt for + more information. +

+

The PostgreSQL server uses one process + per connection so you should provide for at least as many processes + as allowed connections, in addition to what you need for the rest + of your system. This is usually not a problem but if you run + several servers on one machine things might get tight. +

The factory default limit on open files is often set to + "socially friendly" values that allow many users to + coexist on a machine without using an inappropriate fraction of + the system resources. If you run many servers on a machine this + is perhaps what you want, but on dedicated servers you might want to + raise this limit. +

On the other side of the coin, some systems allow individual + processes to open large numbers of files; if more than a few + processes do so then the system-wide limit can easily be exceeded. + If you find this happening, and you do not want to alter the + system-wide limit, you can set PostgreSQL's max_files_per_process configuration parameter to + limit the consumption of open files. +

17.4.3. Linux Memory Overcommit

In Linux 2.4 and later, the default virtual memory behavior is not + optimal for PostgreSQL. Because of the + way that the kernel implements memory overcommit, the kernel might + terminate the PostgreSQL postmaster (the + master server process) if the memory demands of either + PostgreSQL or another process cause the + system to run out of virtual memory. +

If this happens, you will see a kernel message that looks like + this (consult your system documentation and configuration on where + to look for such a message): +

Out of Memory: Killed process 12345 (postgres).

+ This indicates that the postgres process + has been terminated due to memory pressure. + Although existing database connections will continue to function + normally, no new connections will be accepted. To recover, + PostgreSQL will need to be restarted. +

One way to avoid this problem is to run + PostgreSQL on a machine where you can + be sure that other processes will not run the machine out of + memory. If memory is tight, increasing the swap space of the + operating system can help avoid the problem, because the + out-of-memory (OOM) killer is invoked only when physical memory and + swap space are exhausted. +

If PostgreSQL itself is the cause of the + system running out of memory, you can avoid the problem by changing + your configuration. In some cases, it may help to lower memory-related + configuration parameters, particularly + shared_buffers + and work_mem. In + other cases, the problem may be caused by allowing too many connections + to the database server itself. In many cases, it may be better to reduce + max_connections + and instead make use of external connection-pooling software. +

On Linux 2.6 and later, it is possible to modify the + kernel's behavior so that it will not "overcommit" memory. + Although this setting will not prevent the OOM killer from being invoked + altogether, it will lower the chances significantly and will therefore + lead to more robust system behavior. This is done by selecting strict + overcommit mode via sysctl: +

sysctl -w vm.overcommit_memory=2

+ or placing an equivalent entry in /etc/sysctl.conf. + You might also wish to modify the related setting + vm.overcommit_ratio. For details see the kernel documentation + file Documentation/vm/overcommit-accounting. +

Another approach, which can be used with or without altering + vm.overcommit_memory, is to set the process-specific + oom_score_adj value for the postmaster process to + -1000, thereby guaranteeing it will not be targeted by the OOM + killer. The simplest way to do this is to execute +

echo -1000 > /proc/self/oom_score_adj

+ in the postmaster's startup script just before invoking the postmaster. + Note that this action must be done as root, or it will have no effect; + so a root-owned startup script is the easiest place to do it. If you + do this, you may also wish to build PostgreSQL + with -DLINUX_OOM_SCORE_ADJ=0 added to CPPFLAGS. + That will cause postmaster child processes to run with the normal + oom_score_adj value of zero, so that the OOM killer can still + target them at need. +

Older Linux kernels do not offer /proc/self/oom_score_adj, + but may have a previous version of the same functionality called + /proc/self/oom_adj. This works the same except the disable + value is -17 not -1000. The corresponding + build flag for PostgreSQL is + -DLINUX_OOM_ADJ=0. +

Note: Some vendors' Linux 2.4 kernels are reported to have early versions + of the 2.6 overcommit sysctl parameter. However, setting + vm.overcommit_memory to 2 + on a 2.4 kernel that does not have the relevant code will make + things worse, not better. It is recommended that you inspect + the actual kernel source code (see the function + vm_enough_memory in the file mm/mmap.c) + to verify what is supported in your kernel before you try this in a 2.4 + installation. The presence of the overcommit-accounting + documentation file should not be taken as evidence that the + feature is there. If in any doubt, consult a kernel expert or your + kernel vendor. +


PrevHomeNext
Starting the Database ServerUpShutting Down the Server
\ No newline at end of file diff --git a/doc/src/sgml/html/largeobjects.html b/doc/src/sgml/html/largeobjects.html new file mode 100644 index 000000000..fee08dd9c --- /dev/null +++ b/doc/src/sgml/html/largeobjects.html @@ -0,0 +1,287 @@ + +Large Objects

Chapter 32. Large Objects

PostgreSQL has a large object + facility, which provides stream-style access to user data that is stored + in a special large-object structure. Streaming access is useful + when working with data values that are too large to manipulate + conveniently as a whole. +

This chapter describes the implementation and the programming and + query language interfaces to PostgreSQL + large object data. We use the libpq C + library for the examples in this chapter, but most programming + interfaces native to PostgreSQL support + equivalent functionality. Other interfaces might use the large + object interface internally to provide generic support for large + values. This is not described here. +


PrevHomeNext
Example ProgramsUpIntroduction
\ No newline at end of file diff --git a/doc/src/sgml/html/libpq-async.html b/doc/src/sgml/html/libpq-async.html new file mode 100644 index 000000000..245e0120a --- /dev/null +++ b/doc/src/sgml/html/libpq-async.html @@ -0,0 +1,1030 @@ + +Asynchronous Command Processing
PostgreSQL 9.2.2 Documentation
PrevUpChapter 31. libpq - C LibraryNext

31.4. Asynchronous Command Processing

The PQexec function is adequate for submitting + commands in normal, synchronous applications. It has a few + deficiencies, however, that can be of importance to some users: + +

  • PQexec waits for the command to be completed. + The application might have other work to do (such as maintaining a + user interface), in which case it won't want to block waiting for + the response. +

  • Since the execution of the client application is suspended while it + waits for the result, it is hard for the application to decide that + it would like to try to cancel the ongoing command. (It can be done + from a signal handler, but not otherwise.) +

  • PQexec can return only one + PGresult structure. If the submitted command + string contains multiple SQL commands, all but + the last PGresult are discarded by + PQexec. +

  • PQexec always collects the command's entire result, + buffering it in a single PGresult. While + this simplifies error-handling logic for the application, it can be + impractical for results containing many rows. +

+

Applications that do not like these limitations can instead use the + underlying functions that PQexec is built from: + PQsendQuery and PQgetResult. + There are also + PQsendQueryParams, + PQsendPrepare, + PQsendQueryPrepared, + PQsendDescribePrepared, and + PQsendDescribePortal, + which can be used with PQgetResult to duplicate + the functionality of + PQexecParams, + PQprepare, + PQexecPrepared, + PQdescribePrepared, and + PQdescribePortal + respectively. + +

PQsendQuery +

Submits a command to the server without waiting for the result(s). + 1 is returned if the command was successfully dispatched and 0 if + not (in which case, use PQerrorMessage to get more + information about the failure). +

int PQsendQuery(PGconn *conn, const char *command);

+ + After successfully calling PQsendQuery, call + PQgetResult one or more times to obtain the + results. PQsendQuery cannot be called again + (on the same connection) until PQgetResult + has returned a null pointer, indicating that the command is done. +

PQsendQueryParams +

Submits a command and separate parameters to the server without + waiting for the result(s). +

int PQsendQueryParams(PGconn *conn,
+                      const char *command,
+                      int nParams,
+                      const Oid *paramTypes,
+                      const char * const *paramValues,
+                      const int *paramLengths,
+                      const int *paramFormats,
+                      int resultFormat);

+ + This is equivalent to PQsendQuery except that + query parameters can be specified separately from the query string. + The function's parameters are handled identically to + PQexecParams. Like + PQexecParams, it will not work on 2.0-protocol + connections, and it allows only one command in the query string. +

PQsendPrepare +

Sends a request to create a prepared statement with the given + parameters, without waiting for completion. +

int PQsendPrepare(PGconn *conn,
+                  const char *stmtName,
+                  const char *query,
+                  int nParams,
+                  const Oid *paramTypes);

+ + This is an asynchronous version of PQprepare: it + returns 1 if it was able to dispatch the request, and 0 if not. + After a successful call, call PQgetResult to + determine whether the server successfully created the prepared + statement. The function's parameters are handled identically to + PQprepare. Like + PQprepare, it will not work on 2.0-protocol + connections. +

PQsendQueryPrepared +

Sends a request to execute a prepared statement with given + parameters, without waiting for the result(s). +

int PQsendQueryPrepared(PGconn *conn,
+                        const char *stmtName,
+                        int nParams,
+                        const char * const *paramValues,
+                        const int *paramLengths,
+                        const int *paramFormats,
+                        int resultFormat);

+ + This is similar to PQsendQueryParams, but + the command to be executed is specified by naming a + previously-prepared statement, instead of giving a query string. + The function's parameters are handled identically to + PQexecPrepared. Like + PQexecPrepared, it will not work on + 2.0-protocol connections. +

PQsendDescribePrepared +

Submits a request to obtain information about the specified + prepared statement, without waiting for completion. +

int PQsendDescribePrepared(PGconn *conn, const char *stmtName);

+ + This is an asynchronous version of PQdescribePrepared: + it returns 1 if it was able to dispatch the request, and 0 if not. + After a successful call, call PQgetResult to + obtain the results. The function's parameters are handled + identically to PQdescribePrepared. Like + PQdescribePrepared, it will not work on + 2.0-protocol connections. +

PQsendDescribePortal +

Submits a request to obtain information about the specified + portal, without waiting for completion. +

int PQsendDescribePortal(PGconn *conn, const char *portalName);

+ + This is an asynchronous version of PQdescribePortal: + it returns 1 if it was able to dispatch the request, and 0 if not. + After a successful call, call PQgetResult to + obtain the results. The function's parameters are handled + identically to PQdescribePortal. Like + PQdescribePortal, it will not work on + 2.0-protocol connections. +

PQgetResult +

Waits for the next result from a prior + PQsendQuery, + PQsendQueryParams, + PQsendPrepare, + PQsendQueryPrepared, + PQsendDescribePrepared, or + PQsendDescribePortal + call, and returns it. + A null pointer is returned when the command is complete and there + will be no more results. +

PGresult *PQgetResult(PGconn *conn);

+

PQgetResult must be called repeatedly until + it returns a null pointer, indicating that the command is done. + (If called when no command is active, + PQgetResult will just return a null pointer + at once.) Each non-null result from + PQgetResult should be processed using the + same PGresult accessor functions previously + described. Don't forget to free each result object with + PQclear when done with it. Note that + PQgetResult will block only if a command is + active and the necessary response data has not yet been read by + PQconsumeInput. +

Note: Even when PQresultStatus indicates a fatal + error, PQgetResult should be called until it + returns a null pointer, to allow libpq to + process the error information completely. +

+

Using PQsendQuery and + PQgetResult solves one of + PQexec's problems: If a command string contains + multiple SQL commands, the results of those commands + can be obtained individually. (This allows a simple form of overlapped + processing, by the way: the client can be handling the results of one + command while the server is still working on later queries in the same + command string.) +

Another frequently-desired feature that can be obtained with + PQsendQuery and PQgetResult + is retrieving large query results a row at a time. This is discussed + in Section 31.5. +

By itself, calling PQgetResult + will still cause the client to block until the server completes the + next SQL command. This can be avoided by proper + use of two more functions: + +

PQconsumeInput +

If input is available from the server, consume it. +

int PQconsumeInput(PGconn *conn);

+

PQconsumeInput normally returns 1 indicating + "no error", but returns 0 if there was some kind of + trouble (in which case PQerrorMessage can be + consulted). Note that the result does not say whether any input + data was actually collected. After calling + PQconsumeInput, the application can check + PQisBusy and/or + PQnotifies to see if their state has changed. +

PQconsumeInput can be called even if the + application is not prepared to deal with a result or notification + just yet. The function will read available data and save it in + a buffer, thereby causing a select() + read-ready indication to go away. The application can thus use + PQconsumeInput to clear the + select() condition immediately, and then + examine the results at leisure. +

PQisBusy +

Returns 1 if a command is busy, that is, + PQgetResult would block waiting for input. + A 0 return indicates that PQgetResult can be + called with assurance of not blocking. +

int PQisBusy(PGconn *conn);

+

PQisBusy will not itself attempt to read data + from the server; therefore PQconsumeInput + must be invoked first, or the busy state will never end. +

+

A typical application using these functions will have a main loop that + uses select() or poll() to wait for + all the conditions that it must respond to. One of the conditions + will be input available from the server, which in terms of + select() means readable data on the file + descriptor identified by PQsocket. When the main + loop detects input ready, it should call + PQconsumeInput to read the input. It can then + call PQisBusy, followed by + PQgetResult if PQisBusy + returns false (0). It can also call PQnotifies + to detect NOTIFY messages (see Section 31.8). +

A client that uses + PQsendQuery/PQgetResult + can also attempt to cancel a command that is still being processed + by the server; see Section 31.6. But regardless of + the return value of PQcancel, the application + must continue with the normal result-reading sequence using + PQgetResult. A successful cancellation will + simply cause the command to terminate sooner than it would have + otherwise. +

By using the functions described above, it is possible to avoid + blocking while waiting for input from the database server. However, + it is still possible that the application will block waiting to send + output to the server. This is relatively uncommon but can happen if + very long SQL commands or data values are sent. (It is much more + probable if the application sends data via COPY IN, + however.) To prevent this possibility and achieve completely + nonblocking database operation, the following additional functions + can be used. + +

PQsetnonblocking +

Sets the nonblocking status of the connection. +

int PQsetnonblocking(PGconn *conn, int arg);

+

Sets the state of the connection to nonblocking if + arg is 1, or blocking if + arg is 0. Returns 0 if OK, -1 if error. +

In the nonblocking state, calls to + PQsendQuery, PQputline, + PQputnbytes, and + PQendcopy will not block but instead return + an error if they need to be called again. +

Note that PQexec does not honor nonblocking + mode; if it is called, it will act in blocking fashion anyway. +

PQisnonblocking +

Returns the blocking status of the database connection. +

int PQisnonblocking(const PGconn *conn);

+

Returns 1 if the connection is set to nonblocking mode and 0 if + blocking. +

PQflush +

Attempts to flush any queued output data to the server. Returns + 0 if successful (or if the send queue is empty), -1 if it failed + for some reason, or 1 if it was unable to send all the data in + the send queue yet (this case can only occur if the connection + is nonblocking). +

int PQflush(PGconn *conn);

+

+

After sending any command or data on a nonblocking connection, call + PQflush. If it returns 1, wait for the socket + to be write-ready and call it again; repeat until it returns 0. Once + PQflush returns 0, wait for the socket to be + read-ready and then read the response as described above. +


PrevHomeNext
Command Execution FunctionsUpRetrieving Query Results Row-By-Row
\ No newline at end of file diff --git a/doc/src/sgml/html/libpq-build.html b/doc/src/sgml/html/libpq-build.html new file mode 100644 index 000000000..92de37bc3 --- /dev/null +++ b/doc/src/sgml/html/libpq-build.html @@ -0,0 +1,352 @@ + +Building libpq Programs
PostgreSQL 9.2.2 Documentation
PrevUpChapter 31. libpq - C LibraryNext

31.20. Building libpq Programs

To build (i.e., compile and link) a program using + libpq you need to do all of the following + things: + +

  • Include the libpq-fe.h header file: +

    #include <libpq-fe.h>

    + If you failed to do that then you will normally get error messages + from your compiler similar to: +

    foo.c: In function `main':
    +foo.c:34: `PGconn' undeclared (first use in this function)
    +foo.c:35: `PGresult' undeclared (first use in this function)
    +foo.c:54: `CONNECTION_BAD' undeclared (first use in this function)
    +foo.c:68: `PGRES_COMMAND_OK' undeclared (first use in this function)
    +foo.c:95: `PGRES_TUPLES_OK' undeclared (first use in this function)

    +

  • Point your compiler to the directory where the PostgreSQL header + files were installed, by supplying the + -Idirectory option + to your compiler. (In some cases the compiler will look into + the directory in question by default, so you can omit this + option.) For instance, your compile command line could look + like: +

    cc -c -I/usr/local/pgsql/include testprog.c

    + If you are using makefiles then add the option to the + CPPFLAGS variable: +

    CPPFLAGS += -I/usr/local/pgsql/include

    +

    If there is any chance that your program might be compiled by + other users then you should not hardcode the directory location + like that. Instead, you can run the utility + pg_config to find out where the header + files are on the local system: +

    $ pg_config --includedir
    +/usr/local/include

    +

    Failure to specify the correct option to the compiler will + result in an error message such as: +

    testlibpq.c:8:22: libpq-fe.h: No such file or directory

    +

  • When linking the final program, specify the option + -lpq so that the libpq + library gets pulled in, as well as the option + -Ldirectory to point + the compiler to the directory where the + libpq library resides. (Again, the + compiler will search some directories by default.) For maximum + portability, put the -L option before the + -lpq option. For example: +

    cc -o testprog testprog1.o testprog2.o -L/usr/local/pgsql/lib -lpq

    +

    You can find out the library directory using + pg_config as well: +

    $ pg_config --libdir
    +/usr/local/pgsql/lib

    +

    Error messages that point to problems in this area could look like + the following: +

    testlibpq.o: In function `main':
    +testlibpq.o(.text+0x60): undefined reference to `PQsetdbLogin'
    +testlibpq.o(.text+0x71): undefined reference to `PQstatus'
    +testlibpq.o(.text+0xa4): undefined reference to `PQerrorMessage'

    + This means you forgot -lpq. +

    /usr/bin/ld: cannot find -lpq

    + This means you forgot the -L option or did not + specify the right directory. +

+


PrevHomeNext
Behavior in Threaded ProgramsUpExample Programs
\ No newline at end of file diff --git a/doc/src/sgml/html/libpq-cancel.html b/doc/src/sgml/html/libpq-cancel.html new file mode 100644 index 000000000..dca9897cc --- /dev/null +++ b/doc/src/sgml/html/libpq-cancel.html @@ -0,0 +1,389 @@ + +Canceling Queries in Progress
PostgreSQL 9.2.2 Documentation
PrevUpChapter 31. libpq - C LibraryNext

31.6. Canceling Queries in Progress

A client application can request cancellation of a command that is + still being processed by the server, using the functions described in + this section. + +

PQgetCancel +

Creates a data structure containing the information needed to cancel + a command issued through a particular database connection. +

PGcancel *PQgetCancel(PGconn *conn);

+

PQgetCancel creates a + PGcancel object + given a PGconn connection object. It will return + NULL if the given conn is NULL or an invalid + connection. The PGcancel object is an opaque + structure that is not meant to be accessed directly by the + application; it can only be passed to PQcancel + or PQfreeCancel. +

PQfreeCancel +

Frees a data structure created by PQgetCancel. +

void PQfreeCancel(PGcancel *cancel);

+

PQfreeCancel frees a data object previously created + by PQgetCancel. +

PQcancel +

Requests that the server abandon processing of the current command. +

int PQcancel(PGcancel *cancel, char *errbuf, int errbufsize);

+

The return value is 1 if the cancel request was successfully + dispatched and 0 if not. If not, errbuf is filled + with an explanatory error message. errbuf + must be a char array of size errbufsize (the + recommended size is 256 bytes). +

Successful dispatch is no guarantee that the request will have + any effect, however. If the cancellation is effective, the current + command will terminate early and return an error result. If the + cancellation fails (say, because the server was already done + processing the command), then there will be no visible result at + all. +

PQcancel can safely be invoked from a signal + handler, if the errbuf is a local variable in the + signal handler. The PGcancel object is read-only + as far as PQcancel is concerned, so it can + also be invoked from a thread that is separate from the one + manipulating the PGconn object. +

+ +

PQrequestCancel +

PQrequestCancel is a deprecated variant of + PQcancel. +

int PQrequestCancel(PGconn *conn);

+

Requests that the server abandon processing of the current + command. It operates directly on the + PGconn object, and in case of failure stores the + error message in the PGconn object (whence it can + be retrieved by PQerrorMessage). Although + the functionality is the same, this approach creates hazards for + multiple-thread programs and signal handlers, since it is possible + that overwriting the PGconn's error message will + mess up the operation currently in progress on the connection. +

+


PrevHomeNext
Retrieving Query Results Row-By-RowUpThe Fast-Path Interface
\ No newline at end of file diff --git a/doc/src/sgml/html/libpq-connect.html b/doc/src/sgml/html/libpq-connect.html new file mode 100644 index 000000000..f5c413367 --- /dev/null +++ b/doc/src/sgml/html/libpq-connect.html @@ -0,0 +1,2489 @@ + +Database Connection Control Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 31. libpq - C LibraryNext

31.1. Database Connection Control Functions

The following functions deal with making a connection to a + PostgreSQL backend server. An + application program can have several backend connections open at + one time. (One reason to do that is to access more than one + database.) Each connection is represented by a + PGconn object, which + is obtained from the function PQconnectdb, + PQconnectdbParams, or + PQsetdbLogin. Note that these functions will always + return a non-null object pointer, unless perhaps there is too + little memory even to allocate the PGconn object. + The PQstatus function should be called to check + the return value for a successful connection before queries are sent + via the connection object. + +

Warning

On Unix, forking a process with open libpq connections can lead to + unpredictable results because the parent and child processes share + the same sockets and operating system resources. For this reason, + such usage is not recommended, though doing an exec from + the child process to load a new executable is safe. +

+ +

Note: On Windows, there is a way to improve performance if a single + database connection is repeatedly started and shutdown. Internally, + libpq calls WSAStartup() and WSACleanup() for connection startup + and shutdown, respectively. WSAStartup() increments an internal + Windows library reference count which is decremented by WSACleanup(). + When the reference count is just one, calling WSACleanup() frees + all resources and all DLLs are unloaded. This is an expensive + operation. To avoid this, an application can manually call + WSAStartup() so resources will not be freed when the last database + connection is closed. +

+ +

PQconnectdbParams

Makes a new connection to the database server. + +

PGconn *PQconnectdbParams(const char * const *keywords,
+                          const char * const *values,
+                          int expand_dbname);

+

This function opens a new database connection using the parameters taken + from two NULL-terminated arrays. The first, + keywords, is defined as an array of strings, each one + being a key word. The second, values, gives the value + for each key word. Unlike PQsetdbLogin below, the parameter + set can be extended without changing the function signature, so use of + this function (or its nonblocking analogs PQconnectStartParams + and PQconnectPoll) is preferred for new application + programming. +

The currently recognized parameter key words are listed in + Section 31.1.2. +

When expand_dbname is non-zero, the + dbname key word value is allowed to be recognized + as a connection string. More details on the possible formats appear in + Section 31.1.1. +

The passed arrays can be empty to use all default parameters, or can + contain one or more parameter settings. They should be matched in length. + Processing will stop with the last non-NULL element + of the keywords array. +

If any parameter is unspecified, then the corresponding + environment variable (see Section 31.14) + is checked. If the environment variable is not set either, + then the indicated built-in defaults are used. +

In general key words are processed from the beginning of these arrays in index + order. The effect of this is that when key words are repeated, the last processed + value is retained. Therefore, through careful placement of the + dbname key word, it is possible to determine what may + be overridden by a conninfo string, and what may not. +

PQconnectdb

Makes a new connection to the database server. + +

PGconn *PQconnectdb(const char *conninfo);

+

This function opens a new database connection using the parameters taken + from the string conninfo. +

The passed string can be empty to use all default parameters, or it can + contain one or more parameter settings separated by whitespace, + or it can contain a URI. + See Section 31.1.1 for details. +

PQsetdbLogin

Makes a new connection to the database server. +

PGconn *PQsetdbLogin(const char *pghost,
+                     const char *pgport,
+                     const char *pgoptions,
+                     const char *pgtty,
+                     const char *dbName,
+                     const char *login,
+                     const char *pwd);

+

This is the predecessor of PQconnectdb with a fixed + set of parameters. It has the same functionality except that the + missing parameters will always take on default values. Write NULL or an + empty string for any one of the fixed parameters that is to be defaulted. +

If the dbName contains + an = sign or has a valid connection URI prefix, it + is taken as a conninfo string in exactly the same way as + if it had been passed to PQconnectdb, and the remaining + parameters are then applied as specified for PQconnectdbParams. +

PQsetdb

Makes a new connection to the database server. +

PGconn *PQsetdb(char *pghost,
+                char *pgport,
+                char *pgoptions,
+                char *pgtty,
+                char *dbName);

+

This is a macro that calls PQsetdbLogin with null pointers + for the login and pwd parameters. It is provided + for backward compatibility with very old programs. +

PQconnectStartParams
PQconnectStart
PQconnectPoll

+ Make a connection to the database server in a nonblocking manner. + +

PGconn *PQconnectStartParams(const char * const *keywords,
+                             const char * const *values,
+                             int expand_dbname);
+
+PGconn *PQconnectStart(const char *conninfo);
+
+PostgresPollingStatusType PQconnectPoll(PGconn *conn);

+

These three functions are used to open a connection to a database server such + that your application's thread of execution is not blocked on remote I/O + whilst doing so. The point of this approach is that the waits for I/O to + complete can occur in the application's main loop, rather than down inside + PQconnectdbParams or PQconnectdb, and so the + application can manage this operation in parallel with other activities. +

With PQconnectStartParams, the database connection is made + using the parameters taken from the keywords and + values arrays, and controlled by expand_dbname, + as described above for PQconnectdbParams. +

With PQconnectStart, the database connection is made + using the parameters taken from the string conninfo as + described above for PQconnectdb. +

Neither PQconnectStartParams nor PQconnectStart + nor PQconnectPoll will block, so long as a number of + restrictions are met: +

  • The hostaddr and host parameters are used appropriately to ensure that + name and reverse name queries are not made. See the documentation of + these parameters in Section 31.1.2 for details. +

  • If you call PQtrace, ensure that the stream object + into which you trace will not block. +

  • You ensure that the socket is in the appropriate state + before calling PQconnectPoll, as described below. +

+

Note: use of PQconnectStartParams is analogous to + PQconnectStart shown below. +

To begin a nonblocking connection request, call conn = PQconnectStart("connection_info_string"). + If conn is null, then libpq has been unable to allocate a new PGconn + structure. Otherwise, a valid PGconn pointer is returned (though not yet + representing a valid connection to the database). On return from + PQconnectStart, call status = PQstatus(conn). If status equals + CONNECTION_BAD, PQconnectStart has failed. +

If PQconnectStart succeeds, the next stage is to poll + libpq so that it can proceed with the connection sequence. + Use PQsocket(conn) to obtain the descriptor of the + socket underlying the database connection. + Loop thus: If PQconnectPoll(conn) last returned + PGRES_POLLING_READING, wait until the socket is ready to + read (as indicated by select(), poll(), or + similar system function). + Then call PQconnectPoll(conn) again. + Conversely, if PQconnectPoll(conn) last returned + PGRES_POLLING_WRITING, wait until the socket is ready + to write, then call PQconnectPoll(conn) again. + If you have yet to call + PQconnectPoll, i.e., just after the call to + PQconnectStart, behave as if it last returned + PGRES_POLLING_WRITING. Continue this loop until + PQconnectPoll(conn) returns + PGRES_POLLING_FAILED, indicating the connection procedure + has failed, or PGRES_POLLING_OK, indicating the connection + has been successfully made. +

At any time during connection, the status of the connection can be + checked by calling PQstatus. If this call returns CONNECTION_BAD, then the + connection procedure has failed; if the call returns CONNECTION_OK, then the + connection is ready. Both of these states are equally detectable + from the return value of PQconnectPoll, described above. Other states might also occur + during (and only during) an asynchronous connection procedure. These + indicate the current stage of the connection procedure and might be useful + to provide feedback to the user for example. These statuses are: + +

CONNECTION_STARTED

Waiting for connection to be made. +

CONNECTION_MADE

Connection OK; waiting to send. +

CONNECTION_AWAITING_RESPONSE

Waiting for a response from the server. +

CONNECTION_AUTH_OK

Received authentication; waiting for backend start-up to finish. +

CONNECTION_SSL_STARTUP

Negotiating SSL encryption. +

CONNECTION_SETENV

Negotiating environment-driven parameter settings. +

+ + Note that, although these constants will remain (in order to maintain + compatibility), an application should never rely upon these occurring in a + particular order, or at all, or on the status always being one of these + documented values. An application might do something like this: +

switch(PQstatus(conn))
+{
+        case CONNECTION_STARTED:
+            feedback = "Connecting...";
+            break;
+
+        case CONNECTION_MADE:
+            feedback = "Connected to server...";
+            break;
+.
+.
+.
+        default:
+            feedback = "Connecting...";
+}

+

The connect_timeout connection parameter is ignored + when using PQconnectPoll; it is the application's + responsibility to decide whether an excessive amount of time has elapsed. + Otherwise, PQconnectStart followed by a + PQconnectPoll loop is equivalent to + PQconnectdb. +

Note that if PQconnectStart returns a non-null pointer, you must call + PQfinish when you are finished with it, in order to dispose of + the structure and any associated memory blocks. This must be done even if + the connection attempt fails or is abandoned. +

PQconndefaults

Returns the default connection options. +

PQconninfoOption *PQconndefaults(void);
+
+typedef struct
+{
+    char   *keyword;   /* The keyword of the option */
+    char   *envvar;    /* Fallback environment variable name */
+    char   *compiled;  /* Fallback compiled in default value */
+    char   *val;       /* Option's current value, or NULL */
+    char   *label;     /* Label for field in connect dialog */
+    char   *dispchar;  /* Indicates how to display this field
+                          in a connect dialog. Values are:
+                          ""        Display entered value as is
+                          "*"       Password field - hide value
+                          "D"       Debug option - don't show by default */
+    int     dispsize;  /* Field size in characters for dialog */
+} PQconninfoOption;

+

Returns a connection options array. This can be used to determine + all possible PQconnectdb options and their + current default values. The return value points to an array of + PQconninfoOption structures, which ends + with an entry having a null keyword pointer. The + null pointer is returned if memory could not be allocated. Note that + the current default values (val fields) + will depend on environment variables and other context. Callers + must treat the connection options data as read-only. +

After processing the options array, free it by passing it to + PQconninfoFree. If this is not done, a small amount of memory + is leaked for each call to PQconndefaults. +

PQconninfoParse

Returns parsed connection options from the provided connection string. + +

PQconninfoOption *PQconninfoParse(const char *conninfo, char **errmsg);

+

Parses a connection string and returns the resulting options as an + array; or returns NULL if there is a problem with the connection + string. This function can be used to extract + the PQconnectdb options in the provided + connection string. The return value points to an array of + PQconninfoOption structures, which ends + with an entry having a null keyword pointer. +

All legal options will be present in the result array, but the + PQconninfoOption for any option not present + in the connection string will have val set to + NULL; default values are not inserted. +

If errmsg is not NULL, then *errmsg is set + to NULL on success, else to a malloc'd error string explaining + the problem. (It is also possible for *errmsg to be + set to NULL and the function to return NULL; + this indicates an out-of-memory condition.) +

After processing the options array, free it by passing it to + PQconninfoFree. If this is not done, some memory + is leaked for each call to PQconninfoParse. + Conversely, if an error occurs and errmsg is not NULL, + be sure to free the error string using PQfreemem. +

PQfinish

Closes the connection to the server. Also frees + memory used by the PGconn object. +

void PQfinish(PGconn *conn);

+

Note that even if the server connection attempt fails (as + indicated by PQstatus), the application should call PQfinish + to free the memory used by the PGconn object. + The PGconn pointer must not be used again after + PQfinish has been called. +

PQreset

Resets the communication channel to the server. +

void PQreset(PGconn *conn);

+

This function will close the connection + to the server and attempt to reestablish a new + connection to the same server, using all the same + parameters previously used. This might be useful for + error recovery if a working connection is lost. +

PQresetStart
PQresetPoll

Reset the communication channel to the server, in a nonblocking manner. + +

int PQresetStart(PGconn *conn);
+
+PostgresPollingStatusType PQresetPoll(PGconn *conn);

+

These functions will close the connection to the server and attempt to + reestablish a new connection to the same server, using all the same + parameters previously used. This can be useful for error recovery if a + working connection is lost. They differ from PQreset (above) in that they + act in a nonblocking manner. These functions suffer from the same + restrictions as PQconnectStartParams, PQconnectStart + and PQconnectPoll. +

To initiate a connection reset, call + PQresetStart. If it returns 0, the reset has + failed. If it returns 1, poll the reset using + PQresetPoll in exactly the same way as you + would create the connection using PQconnectPoll. +

PQpingParams

PQpingParams reports the status of the + server. It accepts connection parameters identical to those of + PQconnectdbParams, described above. It is not, however, + necessary to supply correct user name, password, or database name + values to obtain the server status. + +

PGPing PQpingParams(const char * const *keywords,
+                    const char * const *values,
+                    int expand_dbname);

+ + The function returns one of the following values: + +

PQPING_OK

The server is running and appears to be accepting connections. +

PQPING_REJECT

The server is running but is in a state that disallows connections + (startup, shutdown, or crash recovery). +

PQPING_NO_RESPONSE

The server could not be contacted. This might indicate that the + server is not running, or that there is something wrong with the + given connection parameters (for example, wrong port number), or + that there is a network connectivity problem (for example, a + firewall blocking the connection request). +

PQPING_NO_ATTEMPT

No attempt was made to contact the server, because the supplied + parameters were obviously incorrect or there was some client-side + problem (for example, out of memory). +

+ +

PQping

PQping reports the status of the + server. It accepts connection parameters identical to those of + PQconnectdb, described above. It is not, however, + necessary to supply correct user name, password, or database name + values to obtain the server status. + +

PGPing PQping(const char *conninfo);

+

The return values are the same as for PQpingParams. +

+

31.1.1. Connection Strings

Several libpq functions parse a user-specified string to obtain + connection parameters. There are two accepted formats for these strings: + plain keyword = value strings + and RFC + 3986 URIs. +

31.1.1.1. Keyword/Value Connection Strings

In the first format, each parameter setting is in the form + keyword = value. Spaces around the equal sign are + optional. To write an empty value, or a value containing spaces, surround it + with single quotes, e.g., keyword = 'a value'. Single + quotes and backslashes within + the value must be escaped with a backslash, i.e., \' and + \\. +

Example: +

host=localhost port=5432 dbname=mydb connect_timeout=10

+

The recognized parameter key words are listed in Section 31.1.2. +

31.1.1.2. Connection URIs

The general form for a connection URI is: +

postgresql://[user[:password]@][netloc][:port][/dbname][?param1=value1&...]

+

The URI scheme designator can be either + postgresql:// or postgres://. Each + of the URI parts is optional. The following examples + illustrate valid URI syntax uses: +

postgresql://
+postgresql://localhost
+postgresql://localhost:5433
+postgresql://localhost/mydb
+postgresql://user@localhost
+postgresql://user:secret@localhost
+postgresql://other@localhost/otherdb?connect_timeout=10&application_name=myapp

+ Components of the hierarchical part of the URI can also + be given as parameters. For example: +

postgresql:///mydb?host=localhost&port=5433

+

Percent-encoding may be used to include symbols with special meaning in any + of the URI parts. +

Any connection parameters not corresponding to key words listed in Section 31.1.2 are ignored and a warning message about them + is sent to stderr. +

For improved compatibility with JDBC connection URIs, + instances of parameter ssl=true are translated into + sslmode=require. +

The host part may be either host name or an IP address. To specify an + IPv6 host address, enclose it in square brackets: +

postgresql://[2001:db8::1234]/database

+

The host component is interpreted as described for the parameter host. In particular, a Unix-domain socket + connection is chosen if the host part is either empty or starts with a + slash, otherwise a TCP/IP connection is initiated. Note, however, that the + slash is a reserved character in the hierarchical part of the URI. So, to + specify a non-standard Unix-domain socket directory, either omit the host + specification in the URI and specify the host as a parameter, or + percent-encode the path in the host component of the URI: +

postgresql:///dbname?host=/var/lib/postgresql
+postgresql://%2Fvar%2Flib%2Fpostgresql/dbname

+

31.1.2. Parameter Key Words

The currently recognized parameter key words are: + +

host

Name of host to connect to. + If this begins with a slash, it specifies Unix-domain + communication rather than TCP/IP communication; the value is the + name of the directory in which the socket file is stored. The + default behavior when host is not specified + is to connect to a Unix-domain + socket in + /tmp (or whatever socket directory was specified + when PostgreSQL was built). On machines without + Unix-domain sockets, the default is to connect to localhost. +

hostaddr

Numeric IP address of host to connect to. This should be in the + standard IPv4 address format, e.g., 172.28.40.9. If + your machine supports IPv6, you can also use those addresses. + TCP/IP communication is + always used when a nonempty string is specified for this parameter. +

Using hostaddr instead of host allows the + application to avoid a host name look-up, which might be important + in applications with time constraints. However, a host name is + required for Kerberos, GSSAPI, or SSPI authentication + methods, as well as for verify-full SSL + certificate verification. The following rules are used: +

  • If host is specified without hostaddr, + a host name lookup occurs. +

  • If hostaddr is specified without host, + the value for hostaddr gives the server network address. + The connection attempt will fail if the authentication + method requires a host name. +

  • If both host and hostaddr are specified, + the value for hostaddr gives the server network address. + The value for host is ignored unless the + authentication method requires it, in which case it will be + used as the host name. +

+ Note that authentication is likely to fail if host + is not the name of the server at network address hostaddr. + Also, note that host rather than hostaddr + is used to identify the connection in ~/.pgpass (see + Section 31.15). +

Without either a host name or host address, + libpq will connect using a + local Unix-domain socket; or on machines without Unix-domain + sockets, it will attempt to connect to localhost. +

port

Port number to connect to at the server host, or socket file + name extension for Unix-domain + connections. +

dbname

The database name. Defaults to be the same as the user name. + In certain contexts, the value is checked for extended + formats; see Section 31.1.1 for more details on + those. +

user

PostgreSQL user name to connect as. + Defaults to be the same as the operating system name of the user + running the application. +

password

Password to be used if the server demands password authentication. +

connect_timeout

Maximum wait for connection, in seconds (write as a decimal integer + string). Zero or not specified means wait indefinitely. It is not + recommended to use a timeout of less than 2 seconds. +

client_encoding

This sets the client_encoding + configuration parameter for this connection. In addition to + the values accepted by the corresponding server option, you + can use auto to determine the right + encoding from the current locale in the client + (LC_CTYPE environment variable on Unix + systems). +

options

Adds command-line options to send to the server at run-time. + For example, setting this to -c geqo=off sets the + session's value of the geqo parameter to + off. For a detailed discussion of the available + options, consult Chapter 18. +

application_name

Specifies a value for the application_name + configuration parameter. +

fallback_application_name

Specifies a fallback value for the application_name configuration parameter. + This value will be used if no value has been given for + application_name via a connection parameter or the + PGAPPNAME environment variable. Specifying + a fallback name is useful in generic utility programs that + wish to set a default application name but allow it to be + overridden by the user. +

keepalives

Controls whether client-side TCP keepalives are used. The default + value is 1, meaning on, but you can change this to 0, meaning off, + if keepalives are not wanted. This parameter is ignored for + connections made via a Unix-domain socket. +

keepalives_idle

Controls the number of seconds of inactivity after which TCP should + send a keepalive message to the server. A value of zero uses the + system default. This parameter is ignored for connections made via a + Unix-domain socket, or if keepalives are disabled. It is only supported + on systems where the TCP_KEEPIDLE or TCP_KEEPALIVE + socket option is available, and on Windows; on other systems, it has no + effect. +

keepalives_interval

Controls the number of seconds after which a TCP keepalive message + that is not acknowledged by the server should be retransmitted. A + value of zero uses the system default. This parameter is ignored for + connections made via a Unix-domain socket, or if keepalives are disabled. + It is only supported on systems where the TCP_KEEPINTVL + socket option is available, and on Windows; on other systems, it has no + effect. +

keepalives_count

Controls the number of TCP keepalives that can be lost before the + client's connection to the server is considered dead. A value of + zero uses the system default. This parameter is ignored for + connections made via a Unix-domain socket, or if keepalives are disabled. + It is only supported on systems where the TCP_KEEPCNT + socket option is available; on other systems, it has no effect. +

tty

Ignored (formerly, this specified where to send server debug output). +

sslmode

This option determines whether or with what priority a secure + SSL TCP/IP connection will be negotiated with the + server. There are six modes: + +

disable

only try a non-SSL connection +

allow

first try a non-SSL connection; if that + fails, try an SSL connection +

prefer (default)

first try an SSL connection; if that fails, + try a non-SSL connection +

require

only try an SSL connection. If a root CA + file is present, verify the certificate in the same way as + if verify-ca was specified +

verify-ca

only try an SSL connection, and verify that + the server certificate is issued by a trusted + certificate authority (CA) +

verify-full

only try an SSL connection, verify that the + server certificate is issued by a + trusted CA and that the server host name + matches that in the certificate +

+ + See Section 31.18 for a detailed description of how + these options work. +

sslmode is ignored for Unix domain socket + communication. + If PostgreSQL is compiled without SSL support, + using options require, verify-ca, or + verify-full will cause an error, while + options allow and prefer will be + accepted but libpq will not actually attempt + an SSL + connection. +

requiressl

This option is deprecated in favor of the sslmode + setting. +

If set to 1, an SSL connection to the server + is required (this is equivalent to sslmode + require). libpq will then refuse + to connect if the server does not accept an + SSL connection. If set to 0 (default), + libpq will negotiate the connection type with + the server (equivalent to sslmode + prefer). This option is only available if + PostgreSQL is compiled with SSL support. +

sslcompression

If set to 1 (default), data sent over SSL connections will be + compressed (this requires OpenSSL version + 0.9.8 or later). + If set to 0, compression will be disabled (this requires + OpenSSL 1.0.0 or later). + This parameter is ignored if a connection without SSL is made, + or if the version of OpenSSL used does not support + it. +

Compression uses CPU time, but can improve throughput if + the network is the bottleneck. + Disabling compression can improve response time and throughput + if CPU performance is the limiting factor. +

sslcert

This parameter specifies the file name of the client SSL + certificate, replacing the default + ~/.postgresql/postgresql.crt. + This parameter is ignored if an SSL connection is not made. +

sslkey

This parameter specifies the location for the secret key used for + the client certificate. It can either specify a file name that will + be used instead of the default + ~/.postgresql/postgresql.key, or it can specify a key + obtained from an external "engine" (engines are + OpenSSL loadable modules). An external engine + specification should consist of a colon-separated engine name and + an engine-specific key identifier. This parameter is ignored if an + SSL connection is not made. +

sslrootcert

This parameter specifies the name of a file containing SSL + certificate authority (CA) certificate(s). + If the file exists, the server's certificate will be verified + to be signed by one of these authorities. The default is + ~/.postgresql/root.crt. +

sslcrl

This parameter specifies the file name of the SSL certificate + revocation list (CRL). Certificates listed in this file, if it + exists, will be rejected while attempting to authenticate the + server's certificate. The default is + ~/.postgresql/root.crl. +

requirepeer

This parameter specifies the operating-system user name of the + server, for example requirepeer=postgres. + When making a Unix-domain socket connection, if this + parameter is set, the client checks at the beginning of the + connection that the server process is running under the specified + user name; if it is not, the connection is aborted with an error. + This parameter can be used to provide server authentication similar + to that available with SSL certificates on TCP/IP connections. + (Note that if the Unix-domain socket is in + /tmp or another publicly writable location, + any user could start a server listening there. Use this parameter + to ensure that you are connected to a server run by a trusted user.) + This option is only supported on platforms for which the + peer authentication method is implemented; see + Section 19.3.7. +

krbsrvname

Kerberos service name to use when authenticating with Kerberos 5 + or GSSAPI. + This must match the service name specified in the server + configuration for Kerberos authentication to succeed. (See also + Section 19.3.5 and Section 19.3.3.) +

gsslib

GSS library to use for GSSAPI authentication. Only used on Windows. + Set to gssapi to force libpq to use the GSSAPI + library for authentication instead of the default SSPI. +

service

Service name to use for additional parameters. It specifies a service + name in pg_service.conf that holds additional connection parameters. + This allows applications to specify only a service name so connection parameters + can be centrally maintained. See Section 31.16. +

+


PrevHomeNext
libpq - C LibraryUpConnection Status Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/libpq-control.html b/doc/src/sgml/html/libpq-control.html new file mode 100644 index 000000000..2a726bb72 --- /dev/null +++ b/doc/src/sgml/html/libpq-control.html @@ -0,0 +1,385 @@ + +Control Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 31. libpq - C LibraryNext

31.10. Control Functions

These functions control miscellaneous details of libpq's + behavior. +

PQclientEncoding +

Returns the client encoding. +

int PQclientEncoding(const PGconn *conn);

+ + Note that it returns the encoding ID, not a symbolic string + such as EUC_JP. To convert an encoding ID to an encoding name, you + can use: + +

char *pg_encoding_to_char(int encoding_id);

+

PQsetClientEncoding +

Sets the client encoding. +

int PQsetClientEncoding(PGconn *conn, const char *encoding);

+ + conn is a connection to the server, + and encoding is the encoding you want to + use. If the function successfully sets the encoding, it returns 0, + otherwise -1. The current encoding for this connection can be + determined by using PQclientEncoding. +

PQsetErrorVerbosity +

Determines the verbosity of messages returned by + PQerrorMessage and PQresultErrorMessage. +

typedef enum
+{
+    PQERRORS_TERSE,
+    PQERRORS_DEFAULT,
+    PQERRORS_VERBOSE
+} PGVerbosity;
+
+PGVerbosity PQsetErrorVerbosity(PGconn *conn, PGVerbosity verbosity);

+ + PQsetErrorVerbosity sets the verbosity mode, returning + the connection's previous setting. In TERSE mode, + returned messages include severity, primary text, and position only; + this will normally fit on a single line. The default mode produces + messages that include the above plus any detail, hint, or context + fields (these might span multiple lines). The VERBOSE + mode includes all available fields. Changing the verbosity does not + affect the messages available from already-existing + PGresult objects, only subsequently-created ones. +

PQtrace +

Enables tracing of the client/server communication to a debugging file stream. +

void PQtrace(PGconn *conn, FILE *stream);

+

Note: On Windows, if the libpq library and an application are + compiled with different flags, this function call will crash the + application because the internal representation of the FILE + pointers differ. Specifically, multithreaded/single-threaded, + release/debug, and static/dynamic flags should be the same for the + library and all applications using that library. +

PQuntrace +

Disables tracing started by PQtrace. +

void PQuntrace(PGconn *conn);

+


PrevHomeNext
Functions Associated with the COPY CommandUpMiscellaneous Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/libpq-copy.html b/doc/src/sgml/html/libpq-copy.html new file mode 100644 index 000000000..18795f585 --- /dev/null +++ b/doc/src/sgml/html/libpq-copy.html @@ -0,0 +1,1113 @@ + +Functions Associated with the COPY Command
PostgreSQL 9.2.2 Documentation
PrevUpChapter 31. libpq - C LibraryNext

31.9. Functions Associated with the COPY Command

The COPY command in + PostgreSQL has options to read from or write + to the network connection used by libpq. + The functions described in this section allow applications to take + advantage of this capability by supplying or consuming copied data. +

The overall process is that the application first issues the SQL + COPY command via PQexec or one + of the equivalent functions. The response to this (if there is no + error in the command) will be a PGresult object bearing + a status code of PGRES_COPY_OUT or + PGRES_COPY_IN (depending on the specified copy + direction). The application should then use the functions of this + section to receive or transmit data rows. When the data transfer is + complete, another PGresult object is returned to indicate + success or failure of the transfer. Its status will be + PGRES_COMMAND_OK for success or + PGRES_FATAL_ERROR if some problem was encountered. + At this point further SQL commands can be issued via + PQexec. (It is not possible to execute other SQL + commands using the same connection while the COPY + operation is in progress.) +

If a COPY command is issued via + PQexec in a string that could contain additional + commands, the application must continue fetching results via + PQgetResult after completing the COPY + sequence. Only when PQgetResult returns + NULL is it certain that the PQexec + command string is done and it is safe to issue more commands. +

The functions of this section should be executed only after obtaining + a result status of PGRES_COPY_OUT or + PGRES_COPY_IN from PQexec or + PQgetResult. +

A PGresult object bearing one of these status values + carries some additional data about the COPY operation + that is starting. This additional data is available using functions + that are also used in connection with query results: + +

PQnfields +

Returns the number of columns (fields) to be copied. +

PQbinaryTuples +

0 indicates the overall copy format is textual (rows separated by + newlines, columns separated by separator characters, etc). 1 + indicates the overall copy format is binary. See COPY for more information. +

PQfformat +

Returns the format code (0 for text, 1 for binary) associated with + each column of the copy operation. The per-column format codes + will always be zero when the overall copy format is textual, but + the binary format can support both text and binary columns. + (However, as of the current implementation of COPY, + only binary columns appear in a binary copy; so the per-column + formats always match the overall format at present.) +

+

Note: These additional data values are only available when using protocol + 3.0. When using protocol 2.0, all these functions will return 0. +

31.9.1. Functions for Sending COPY Data

These functions are used to send data during COPY FROM + STDIN. They will fail if called when the connection is not in + COPY_IN state. +

PQputCopyData +

Sends data to the server during COPY_IN state. +

int PQputCopyData(PGconn *conn,
+                  const char *buffer,
+                  int nbytes);

+

Transmits the COPY data in the specified + buffer, of length nbytes, to the server. + The result is 1 if the data was sent, zero if it was not sent + because the attempt would block (this case is only possible if the + connection is in nonblocking mode), or -1 if an error occurred. + (Use PQerrorMessage to retrieve details if + the return value is -1. If the value is zero, wait for write-ready + and try again.) +

The application can divide the COPY data stream + into buffer loads of any convenient size. Buffer-load boundaries + have no semantic significance when sending. The contents of the + data stream must match the data format expected by the + COPY command; see COPY for details. +

PQputCopyEnd +

Sends end-of-data indication to the server during COPY_IN state. +

int PQputCopyEnd(PGconn *conn,
+                 const char *errormsg);

+

Ends the COPY_IN operation successfully if + errormsg is NULL. If + errormsg is not NULL then the + COPY is forced to fail, with the string pointed to by + errormsg used as the error message. (One should not + assume that this exact error message will come back from the server, + however, as the server might have already failed the + COPY for its own reasons. Also note that the option + to force failure does not work when using pre-3.0-protocol + connections.) +

The result is 1 if the termination data was sent, zero if it was + not sent because the attempt would block (this case is only possible + if the connection is in nonblocking mode), or -1 if an error + occurred. (Use PQerrorMessage to retrieve + details if the return value is -1. If the value is zero, wait for + write-ready and try again.) +

After successfully calling PQputCopyEnd, call + PQgetResult to obtain the final result status of the + COPY command. One can wait for this result to be + available in the usual way. Then return to normal operation. +

31.9.2. Functions for Receiving COPY Data

These functions are used to receive data during COPY TO + STDOUT. They will fail if called when the connection is not in + COPY_OUT state. +

PQgetCopyData +

Receives data from the server during COPY_OUT state. +

int PQgetCopyData(PGconn *conn,
+                  char **buffer,
+                  int async);

+

Attempts to obtain another row of data from the server during a + COPY. Data is always returned one data row at + a time; if only a partial row is available, it is not returned. + Successful return of a data row involves allocating a chunk of + memory to hold the data. The buffer parameter must + be non-NULL. *buffer is set to + point to the allocated memory, or to NULL in cases + where no buffer is returned. A non-NULL result + buffer should be freed using PQfreemem when no longer + needed. +

When a row is successfully returned, the return value is the number + of data bytes in the row (this will always be greater than zero). + The returned string is always null-terminated, though this is + probably only useful for textual COPY. A result + of zero indicates that the COPY is still in + progress, but no row is yet available (this is only possible when + async is true). A result of -1 indicates that the + COPY is done. A result of -2 indicates that an + error occurred (consult PQerrorMessage for the reason). +

When async is true (not zero), + PQgetCopyData will not block waiting for input; it + will return zero if the COPY is still in progress + but no complete row is available. (In this case wait for read-ready + and then call PQconsumeInput before calling + PQgetCopyData again.) When async is + false (zero), PQgetCopyData will block until data is + available or the operation completes. +

After PQgetCopyData returns -1, call + PQgetResult to obtain the final result status of the + COPY command. One can wait for this result to be + available in the usual way. Then return to normal operation. +

31.9.3. Obsolete Functions for COPY

These functions represent older methods of handling COPY. + Although they still work, they are deprecated due to poor error handling, + inconvenient methods of detecting end-of-data, and lack of support for binary + or nonblocking transfers. +

PQgetline +

Reads a newline-terminated line of characters (transmitted + by the server) into a buffer string of size length. +

int PQgetline(PGconn *conn,
+              char *buffer,
+              int length);

+

This function copies up to length-1 characters into + the buffer and converts the terminating newline into a zero byte. + PQgetline returns EOF at the + end of input, 0 if the entire line has been read, and 1 if the + buffer is full but the terminating newline has not yet been read. +

Note that the application must check to see if a new line consists + of the two characters \., which indicates + that the server has finished sending the results of the + COPY command. If the application might receive + lines that are more than length-1 characters long, + care is needed to be sure it recognizes the \. + line correctly (and does not, for example, mistake the end of a + long data line for a terminator line). +

PQgetlineAsync +

Reads a row of COPY data (transmitted by the + server) into a buffer without blocking. +

int PQgetlineAsync(PGconn *conn,
+                   char *buffer,
+                   int bufsize);

+

This function is similar to PQgetline, but it can be used + by applications + that must read COPY data asynchronously, that is, without blocking. + Having issued the COPY command and gotten a PGRES_COPY_OUT + response, the + application should call PQconsumeInput and + PQgetlineAsync until the + end-of-data signal is detected. +

Unlike PQgetline, this function takes + responsibility for detecting end-of-data. +

On each call, PQgetlineAsync will return data if a + complete data row is available in libpq's input buffer. + Otherwise, no data is returned until the rest of the row arrives. + The function returns -1 if the end-of-copy-data marker has been recognized, + or 0 if no data is available, or a positive number giving the number of + bytes of data returned. If -1 is returned, the caller must next call + PQendcopy, and then return to normal processing. +

The data returned will not extend beyond a data-row boundary. If possible + a whole row will be returned at one time. But if the buffer offered by + the caller is too small to hold a row sent by the server, then a partial + data row will be returned. With textual data this can be detected by testing + whether the last returned byte is \n or not. (In a binary + COPY, actual parsing of the COPY data format will be needed to make the + equivalent determination.) + The returned string is not null-terminated. (If you want to add a + terminating null, be sure to pass a bufsize one smaller + than the room actually available.) +

PQputline +

Sends a null-terminated string to the server. Returns 0 if + OK and EOF if unable to send the string. +

int PQputline(PGconn *conn,
+              const char *string);

+

The COPY data stream sent by a series of calls + to PQputline has the same format as that + returned by PQgetlineAsync, except that + applications are not obliged to send exactly one data row per + PQputline call; it is okay to send a partial + line or multiple lines per call. +

Note: Before PostgreSQL protocol 3.0, it was necessary + for the application to explicitly send the two characters + \. as a final line to indicate to the server that it had + finished sending COPY data. While this still works, it is deprecated and the + special meaning of \. can be expected to be removed in a + future release. It is sufficient to call PQendcopy after + having sent the actual data. +

PQputnbytes +

Sends a non-null-terminated string to the server. Returns + 0 if OK and EOF if unable to send the string. +

int PQputnbytes(PGconn *conn,
+                const char *buffer,
+                int nbytes);

+

This is exactly like PQputline, except that the data + buffer need not be null-terminated since the number of bytes to send is + specified directly. Use this procedure when sending binary data. +

PQendcopy +

Synchronizes with the server. +

int PQendcopy(PGconn *conn);

+ This function waits until the server has finished the copying. + It should either be issued when the last string has been sent + to the server using PQputline or when the + last string has been received from the server using + PGgetline. It must be issued or the server + will get "out of sync" with the client. Upon return + from this function, the server is ready to receive the next SQL + command. The return value is 0 on successful completion, + nonzero otherwise. (Use PQerrorMessage to + retrieve details if the return value is nonzero.) +

When using PQgetResult, the application should + respond to a PGRES_COPY_OUT result by executing + PQgetline repeatedly, followed by + PQendcopy after the terminator line is seen. + It should then return to the PQgetResult loop + until PQgetResult returns a null pointer. + Similarly a PGRES_COPY_IN result is processed + by a series of PQputline calls followed by + PQendcopy, then return to the + PQgetResult loop. This arrangement will + ensure that a COPY command embedded in a series + of SQL commands will be executed correctly. +

Older applications are likely to submit a COPY + via PQexec and assume that the transaction + is done after PQendcopy. This will work + correctly only if the COPY is the only + SQL command in the command string. +


PrevHomeNext
Asynchronous NotificationUpControl Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/libpq-envars.html b/doc/src/sgml/html/libpq-envars.html new file mode 100644 index 000000000..a2a92baae --- /dev/null +++ b/doc/src/sgml/html/libpq-envars.html @@ -0,0 +1,633 @@ + +Environment Variables
PostgreSQL 9.2.2 Documentation
PrevUpChapter 31. libpq - C LibraryNext

31.14. Environment Variables

The following environment variables can be used to select default + connection parameter values, which will be used by + PQconnectdb, PQsetdbLogin and + PQsetdb if no value is directly specified by the calling + code. These are useful to avoid hard-coding database connection + information into simple client applications, for example. + +

  • + PGHOST behaves the same as the host connection parameter. +

  • + PGHOSTADDR behaves the same as the hostaddr connection parameter. + This can be set instead of or in addition to PGHOST + to avoid DNS lookup overhead. +

  • + PGPORT behaves the same as the port connection parameter. +

  • + PGDATABASE behaves the same as the dbname connection parameter. +

  • + PGUSER behaves the same as the user connection parameter. +

  • + PGPASSWORD behaves the same as the password connection parameter. + Use of this environment variable + is not recommended for security reasons, as some operating systems + allow non-root users to see process environment variables via + ps; instead consider using the + ~/.pgpass file (see Section 31.15). +

  • + PGPASSFILE specifies the name of the password file to + use for lookups. If not set, it defaults to ~/.pgpass + (see Section 31.15). +

  • + PGSERVICE behaves the same as the service connection parameter. +

  • + PGSERVICEFILE specifies the name of the per-user + connection service file. If not set, it defaults + to ~/.pg_service.conf + (see Section 31.16). +

  • + PGREALM sets the Kerberos realm to use with + PostgreSQL, if it is different from the + local realm. If PGREALM is set, + libpq applications will attempt + authentication with servers for this realm and use separate ticket + files to avoid conflicts with local ticket files. This + environment variable is only used if Kerberos authentication is + selected by the server. +

  • + PGOPTIONS behaves the same as the options connection parameter. +

  • + PGAPPNAME behaves the same as the application_name connection parameter. +

  • + PGSSLMODE behaves the same as the sslmode connection parameter. +

  • + PGREQUIRESSL behaves the same as the requiressl connection parameter. +

  • + PGSSLCOMPRESSION behaves the same as the sslcompression connection parameter. +

  • + PGSSLCERT behaves the same as the sslcert connection parameter. +

  • + PGSSLKEY behaves the same as the sslkey connection parameter. +

  • + PGSSLROOTCERT behaves the same as the sslrootcert connection parameter. +

  • + PGSSLCRL behaves the same as the sslcrl connection parameter. +

  • + PGREQUIREPEER behaves the same as the requirepeer connection parameter. +

  • + PGKRBSRVNAME behaves the same as the krbsrvname connection parameter. +

  • + PGGSSLIB behaves the same as the gsslib connection parameter. +

  • + PGCONNECT_TIMEOUT behaves the same as the connect_timeout connection parameter. +

  • + PGCLIENTENCODING behaves the same as the client_encoding connection parameter. +

+

The following environment variables can be used to specify default + behavior for each PostgreSQL session. (See + also the ALTER ROLE + and ALTER DATABASE + commands for ways to set default behavior on a per-user or per-database + basis.) + +

  • + PGDATESTYLE sets the default style of date/time + representation. (Equivalent to SET datestyle TO + ....) +

  • + PGTZ sets the default time zone. (Equivalent to + SET timezone TO ....) +

  • + PGGEQO sets the default mode for the genetic query + optimizer. (Equivalent to SET geqo TO ....) +

+ + Refer to the SQL command SET + for information on correct values for these + environment variables. +

The following environment variables determine internal behavior of + libpq; they override compiled-in defaults. + +

  • + PGSYSCONFDIR sets the directory containing the + pg_service.conf file and in a future version + possibly other system-wide configuration files. +

  • + PGLOCALEDIR sets the directory containing the + locale files for message internationalization. +

+


PrevHomeNext
Event SystemUpThe Password File
\ No newline at end of file diff --git a/doc/src/sgml/html/libpq-events.html b/doc/src/sgml/html/libpq-events.html new file mode 100644 index 000000000..6f5726efc --- /dev/null +++ b/doc/src/sgml/html/libpq-events.html @@ -0,0 +1,1167 @@ + +Event System
PostgreSQL 9.2.2 Documentation
PrevUpChapter 31. libpq - C LibraryNext

31.13. Event System

libpq's event system is designed to notify + registered event handlers about interesting + libpq events, such as the creation or + destruction of PGconn and + PGresult objects. A principal use case is that + this allows applications to associate their own data with a + PGconn or PGresult + and ensure that that data is freed at an appropriate time. +

Each registered event handler is associated with two pieces of data, + known to libpq only as opaque void * + pointers. There is a passthrough pointer that is provided + by the application when the event handler is registered with a + PGconn. The passthrough pointer never changes for the + life of the PGconn and all PGresults + generated from it; so if used, it must point to long-lived data. + In addition there is an instance data pointer, which starts + out NULL in every PGconn and PGresult. + This pointer can be manipulated using the + PQinstanceData, + PQsetInstanceData, + PQresultInstanceData and + PQsetResultInstanceData functions. Note that + unlike the passthrough pointer, instance data of a PGconn + is not automatically inherited by PGresults created from + it. libpq does not know what passthrough + and instance data pointers point to (if anything) and will never attempt + to free them — that is the responsibility of the event handler. +

31.13.1. Event Types

The enum PGEventId names the types of events handled by + the event system. All its values have names beginning with + PGEVT. For each event type, there is a corresponding + event info structure that carries the parameters passed to the event + handlers. The event types are: +

PGEVT_REGISTER

The register event occurs when PQregisterEventProc + is called. It is the ideal time to initialize any + instanceData an event procedure may need. Only one + register event will be fired per event handler per connection. If the + event procedure fails, the registration is aborted. + +

typedef struct
+{
+    PGconn *conn;
+} PGEventRegister;

+ + When a PGEVT_REGISTER event is received, the + evtInfo pointer should be cast to a + PGEventRegister *. This structure contains a + PGconn that should be in the + CONNECTION_OK status; guaranteed if one calls + PQregisterEventProc right after obtaining a good + PGconn. When returning a failure code, all + cleanup must be performed as no PGEVT_CONNDESTROY + event will be sent. +

PGEVT_CONNRESET

The connection reset event is fired on completion of + PQreset or PQresetPoll. In + both cases, the event is only fired if the reset was successful. If + the event procedure fails, the entire connection reset will fail; the + PGconn is put into + CONNECTION_BAD status and + PQresetPoll will return + PGRES_POLLING_FAILED. + +

typedef struct
+{
+    PGconn *conn;
+} PGEventConnReset;

+ + When a PGEVT_CONNRESET event is received, the + evtInfo pointer should be cast to a + PGEventConnReset *. Although the contained + PGconn was just reset, all event data remains + unchanged. This event should be used to reset/reload/requery any + associated instanceData. Note that even if the + event procedure fails to process PGEVT_CONNRESET, it will + still receive a PGEVT_CONNDESTROY event when the connection + is closed. +

PGEVT_CONNDESTROY

The connection destroy event is fired in response to + PQfinish. It is the event procedure's + responsibility to properly clean up its event data as libpq has no + ability to manage this memory. Failure to clean up will lead + to memory leaks. + +

typedef struct
+{
+    PGconn *conn;
+} PGEventConnDestroy;

+ + When a PGEVT_CONNDESTROY event is received, the + evtInfo pointer should be cast to a + PGEventConnDestroy *. This event is fired + prior to PQfinish performing any other cleanup. + The return value of the event procedure is ignored since there is no + way of indicating a failure from PQfinish. Also, + an event procedure failure should not abort the process of cleaning up + unwanted memory. +

PGEVT_RESULTCREATE

The result creation event is fired in response to any query execution + function that generates a result, including + PQgetResult. This event will only be fired after + the result has been created successfully. + +

typedef struct
+{
+    PGconn *conn;
+    PGresult *result;
+} PGEventResultCreate;

+ + When a PGEVT_RESULTCREATE event is received, the + evtInfo pointer should be cast to a + PGEventResultCreate *. The + conn is the connection used to generate the + result. This is the ideal place to initialize any + instanceData that needs to be associated with the + result. If the event procedure fails, the result will be cleared and + the failure will be propagated. The event procedure must not try to + PQclear the result object for itself. When returning a + failure code, all cleanup must be performed as no + PGEVT_RESULTDESTROY event will be sent. +

PGEVT_RESULTCOPY

The result copy event is fired in response to + PQcopyResult. This event will only be fired after + the copy is complete. Only event procedures that have + successfully handled the PGEVT_RESULTCREATE + or PGEVT_RESULTCOPY event for the source result + will receive PGEVT_RESULTCOPY events. + +

typedef struct
+{
+    const PGresult *src;
+    PGresult *dest;
+} PGEventResultCopy;

+ + When a PGEVT_RESULTCOPY event is received, the + evtInfo pointer should be cast to a + PGEventResultCopy *. The + src result is what was copied while the + dest result is the copy destination. This event + can be used to provide a deep copy of instanceData, + since PQcopyResult cannot do that. If the event + procedure fails, the entire copy operation will fail and the + dest result will be cleared. When returning a + failure code, all cleanup must be performed as no + PGEVT_RESULTDESTROY event will be sent for the + destination result. +

PGEVT_RESULTDESTROY

The result destroy event is fired in response to a + PQclear. It is the event procedure's + responsibility to properly clean up its event data as libpq has no + ability to manage this memory. Failure to clean up will lead + to memory leaks. + +

typedef struct
+{
+    PGresult *result;
+} PGEventResultDestroy;

+ + When a PGEVT_RESULTDESTROY event is received, the + evtInfo pointer should be cast to a + PGEventResultDestroy *. This event is fired + prior to PQclear performing any other cleanup. + The return value of the event procedure is ignored since there is no + way of indicating a failure from PQclear. Also, + an event procedure failure should not abort the process of cleaning up + unwanted memory. +

31.13.2. Event Callback Procedure

PGEventProc +

PGEventProc is a typedef for a pointer to an + event procedure, that is, the user callback function that receives + events from libpq. The signature of an event procedure must be + +

int eventproc(PGEventId evtId, void *evtInfo, void *passThrough)

+ + The evtId parameter indicates which + PGEVT event occurred. The + evtInfo pointer must be cast to the appropriate + structure type to obtain further information about the event. + The passThrough parameter is the pointer + provided to PQregisterEventProc when the event + procedure was registered. The function should return a non-zero value + if it succeeds and zero if it fails. +

A particular event procedure can be registered only once in any + PGconn. This is because the address of the procedure + is used as a lookup key to identify the associated instance data. +

Caution

On Windows, functions can have two different addresses: one visible + from outside a DLL and another visible from inside the DLL. One + should be careful that only one of these addresses is used with + libpq's event-procedure functions, else confusion will + result. The simplest rule for writing code that will work is to + ensure that event procedures are declared static. If the + procedure's address must be available outside its own source file, + expose a separate function to return the address. +

31.13.3. Event Support Functions

PQregisterEventProc +

Registers an event callback procedure with libpq. + +

int PQregisterEventProc(PGconn *conn, PGEventProc proc,
+                        const char *name, void *passThrough);

+

An event procedure must be registered once on each + PGconn you want to receive events about. There is no + limit, other than memory, on the number of event procedures that + can be registered with a connection. The function returns a non-zero + value if it succeeds and zero if it fails. +

The proc argument will be called when a libpq + event is fired. Its memory address is also used to lookup + instanceData. The name + argument is used to refer to the event procedure in error messages. + This value cannot be NULL or a zero-length string. The name string is + copied into the PGconn, so what is passed need not be + long-lived. The passThrough pointer is passed + to the proc whenever an event occurs. This + argument can be NULL. +

PQsetInstanceData +

Sets the connection conn's instanceData + for procedure proc to data. This + returns non-zero for success and zero for failure. (Failure is + only possible if proc has not been properly + registered in conn.) + +

int PQsetInstanceData(PGconn *conn, PGEventProc proc, void *data);

+

PQinstanceData +

Returns the + connection conn's instanceData + associated with procedure proc, + or NULL if there is none. + +

void *PQinstanceData(const PGconn *conn, PGEventProc proc);

+

PQresultSetInstanceData +

Sets the result's instanceData + for proc to data. This returns + non-zero for success and zero for failure. (Failure is only + possible if proc has not been properly registered + in the result.) + +

int PQresultSetInstanceData(PGresult *res, PGEventProc proc, void *data);

+

PQresultInstanceData +

Returns the result's instanceData associated with proc, or NULL + if there is none. + +

void *PQresultInstanceData(const PGresult *res, PGEventProc proc);

+

31.13.4. Event Example

Here is a skeleton example of managing private data associated with + libpq connections and results. +

/* required header for libpq events (note: includes libpq-fe.h) */
+#include <libpq-events.h>
+
+/* The instanceData */
+typedef struct
+{
+    int n;
+    char *str;
+} mydata;
+
+/* PGEventProc */
+static int myEventProc(PGEventId evtId, void *evtInfo, void *passThrough);
+
+int
+main(void)
+{
+    mydata *data;
+    PGresult *res;
+    PGconn *conn = PQconnectdb("dbname = postgres");
+
+    if (PQstatus(conn) != CONNECTION_OK)
+    {
+        fprintf(stderr, "Connection to database failed: %s",
+                PQerrorMessage(conn));
+        PQfinish(conn);
+        return 1;
+    }
+
+    /* called once on any connection that should receive events.
+     * Sends a PGEVT_REGISTER to myEventProc.
+     */
+    if (!PQregisterEventProc(conn, myEventProc, "mydata_proc", NULL))
+    {
+        fprintf(stderr, "Cannot register PGEventProc\n");
+        PQfinish(conn);
+        return 1;
+    }
+
+    /* conn instanceData is available */
+    data = PQinstanceData(conn, myEventProc);
+
+    /* Sends a PGEVT_RESULTCREATE to myEventProc */
+    res = PQexec(conn, "SELECT 1 + 1");
+
+    /* result instanceData is available */
+    data = PQresultInstanceData(res, myEventProc);
+
+    /* If PG_COPYRES_EVENTS is used, sends a PGEVT_RESULTCOPY to myEventProc */
+    res_copy = PQcopyResult(res, PG_COPYRES_TUPLES | PG_COPYRES_EVENTS);
+
+    /* result instanceData is available if PG_COPYRES_EVENTS was
+     * used during the PQcopyResult call.
+     */
+    data = PQresultInstanceData(res_copy, myEventProc);
+
+    /* Both clears send a PGEVT_RESULTDESTROY to myEventProc */
+    PQclear(res);
+    PQclear(res_copy);
+
+    /* Sends a PGEVT_CONNDESTROY to myEventProc */
+    PQfinish(conn);
+
+    return 0;
+}
+
+static int
+myEventProc(PGEventId evtId, void *evtInfo, void *passThrough)
+{
+    switch (evtId)
+    {
+        case PGEVT_REGISTER:
+        {
+            PGEventRegister *e = (PGEventRegister *)evtInfo;
+            mydata *data = get_mydata(e->conn);
+
+            /* associate app specific data with connection */
+            PQsetInstanceData(e->conn, myEventProc, data);
+            break;
+        }
+
+        case PGEVT_CONNRESET:
+        {
+            PGEventConnReset *e = (PGEventConnReset *)evtInfo;
+            mydata *data = PQinstanceData(e->conn, myEventProc);
+
+            if (data)
+              memset(data, 0, sizeof(mydata));
+            break;
+        }
+
+        case PGEVT_CONNDESTROY:
+        {
+            PGEventConnDestroy *e = (PGEventConnDestroy *)evtInfo;
+            mydata *data = PQinstanceData(e->conn, myEventProc);
+
+            /* free instance data because the conn is being destroyed */
+            if (data)
+              free_mydata(data);
+            break;
+        }
+
+        case PGEVT_RESULTCREATE:
+        {
+            PGEventResultCreate *e = (PGEventResultCreate *)evtInfo;
+            mydata *conn_data = PQinstanceData(e->conn, myEventProc);
+            mydata *res_data = dup_mydata(conn_data);
+
+            /* associate app specific data with result (copy it from conn) */
+            PQsetResultInstanceData(e->result, myEventProc, res_data);
+            break;
+        }
+
+        case PGEVT_RESULTCOPY:
+        {
+            PGEventResultCopy *e = (PGEventResultCopy *)evtInfo;
+            mydata *src_data = PQresultInstanceData(e->src, myEventProc);
+            mydata *dest_data = dup_mydata(src_data);
+
+            /* associate app specific data with result (copy it from a result) */
+            PQsetResultInstanceData(e->dest, myEventProc, dest_data);
+            break;
+        }
+
+        case PGEVT_RESULTDESTROY:
+        {
+            PGEventResultDestroy *e = (PGEventResultDestroy *)evtInfo;
+            mydata *data = PQresultInstanceData(e->result, myEventProc);
+
+            /* free instance data because the result is being destroyed */
+            if (data)
+              free_mydata(data);
+            break;
+        }
+
+        /* unknown event ID, just return TRUE. */
+        default:
+            break;
+    }
+
+    return TRUE; /* event processing succeeded */
+}

PrevHomeNext
Notice ProcessingUpEnvironment Variables
\ No newline at end of file diff --git a/doc/src/sgml/html/libpq-example.html b/doc/src/sgml/html/libpq-example.html new file mode 100644 index 000000000..59b7d3140 --- /dev/null +++ b/doc/src/sgml/html/libpq-example.html @@ -0,0 +1,680 @@ + +Example Programs
PostgreSQL 9.2.2 Documentation
PrevUpChapter 31. libpq - C LibraryNext

31.21. Example Programs

These examples and others can be found in the + directory src/test/examples in the source code + distribution. +

Example 31-1. libpq Example Program 1

/*
+ * testlibpq.c
+ *
+ *      Test the C version of libpq, the PostgreSQL frontend library.
+ */
+#include <stdio.h>
+#include <stdlib.h>
+#include <libpq-fe.h>
+
+static void
+exit_nicely(PGconn *conn)
+{
+    PQfinish(conn);
+    exit(1);
+}
+
+int
+main(int argc, char **argv)
+{
+    const char *conninfo;
+    PGconn     *conn;
+    PGresult   *res;
+    int         nFields;
+    int         i,
+                j;
+
+    /*
+     * If the user supplies a parameter on the command line, use it as the
+     * conninfo string; otherwise default to setting dbname=postgres and using
+     * environment variables or defaults for all other connection parameters.
+     */
+    if (argc > 1)
+        conninfo = argv[1];
+    else
+        conninfo = "dbname = postgres";
+
+    /* Make a connection to the database */
+    conn = PQconnectdb(conninfo);
+
+    /* Check to see that the backend connection was successfully made */
+    if (PQstatus(conn) != CONNECTION_OK)
+    {
+        fprintf(stderr, "Connection to database failed: %s",
+                PQerrorMessage(conn));
+        exit_nicely(conn);
+    }
+
+    /*
+     * Our test case here involves using a cursor, for which we must be inside
+     * a transaction block.  We could do the whole thing with a single
+     * PQexec() of "select * from pg_database", but that's too trivial to make
+     * a good example.
+     */
+
+    /* Start a transaction block */
+    res = PQexec(conn, "BEGIN");
+    if (PQresultStatus(res) != PGRES_COMMAND_OK)
+    {
+        fprintf(stderr, "BEGIN command failed: %s", PQerrorMessage(conn));
+        PQclear(res);
+        exit_nicely(conn);
+    }
+
+    /*
+     * Should PQclear PGresult whenever it is no longer needed to avoid memory
+     * leaks
+     */
+    PQclear(res);
+
+    /*
+     * Fetch rows from pg_database, the system catalog of databases
+     */
+    res = PQexec(conn, "DECLARE myportal CURSOR FOR select * from pg_database");
+    if (PQresultStatus(res) != PGRES_COMMAND_OK)
+    {
+        fprintf(stderr, "DECLARE CURSOR failed: %s", PQerrorMessage(conn));
+        PQclear(res);
+        exit_nicely(conn);
+    }
+    PQclear(res);
+
+    res = PQexec(conn, "FETCH ALL in myportal");
+    if (PQresultStatus(res) != PGRES_TUPLES_OK)
+    {
+        fprintf(stderr, "FETCH ALL failed: %s", PQerrorMessage(conn));
+        PQclear(res);
+        exit_nicely(conn);
+    }
+
+    /* first, print out the attribute names */
+    nFields = PQnfields(res);
+    for (i = 0; i < nFields; i++)
+        printf("%-15s", PQfname(res, i));
+    printf("\n\n");
+
+    /* next, print out the rows */
+    for (i = 0; i < PQntuples(res); i++)
+    {
+        for (j = 0; j < nFields; j++)
+            printf("%-15s", PQgetvalue(res, i, j));
+        printf("\n");
+    }
+
+    PQclear(res);
+
+    /* close the portal ... we don't bother to check for errors ... */
+    res = PQexec(conn, "CLOSE myportal");
+    PQclear(res);
+
+    /* end the transaction */
+    res = PQexec(conn, "END");
+    PQclear(res);
+
+    /* close the connection to the database and cleanup */
+    PQfinish(conn);
+
+    return 0;
+}

Example 31-2. libpq Example Program 2

/*
+ * testlibpq2.c
+ *      Test of the asynchronous notification interface
+ *
+ * Start this program, then from psql in another window do
+ *   NOTIFY TBL2;
+ * Repeat four times to get this program to exit.
+ *
+ * Or, if you want to get fancy, try this:
+ * populate a database with the following commands
+ * (provided in src/test/examples/testlibpq2.sql):
+ *
+ *   CREATE TABLE TBL1 (i int4);
+ *
+ *   CREATE TABLE TBL2 (i int4);
+ *
+ *   CREATE RULE r1 AS ON INSERT TO TBL1 DO
+ *     (INSERT INTO TBL2 VALUES (new.i); NOTIFY TBL2);
+ *
+ * and do this four times:
+ *
+ *   INSERT INTO TBL1 VALUES (10);
+ */
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <errno.h>
+#include <sys/time.h>
+#include <libpq-fe.h>
+
+static void
+exit_nicely(PGconn *conn)
+{
+    PQfinish(conn);
+    exit(1);
+}
+
+int
+main(int argc, char **argv)
+{
+    const char *conninfo;
+    PGconn     *conn;
+    PGresult   *res;
+    PGnotify   *notify;
+    int         nnotifies;
+
+    /*
+     * If the user supplies a parameter on the command line, use it as the
+     * conninfo string; otherwise default to setting dbname=postgres and using
+     * environment variables or defaults for all other connection parameters.
+     */
+    if (argc > 1)
+        conninfo = argv[1];
+    else
+        conninfo = "dbname = postgres";
+
+    /* Make a connection to the database */
+    conn = PQconnectdb(conninfo);
+
+    /* Check to see that the backend connection was successfully made */
+    if (PQstatus(conn) != CONNECTION_OK)
+    {
+        fprintf(stderr, "Connection to database failed: %s",
+                PQerrorMessage(conn));
+        exit_nicely(conn);
+    }
+
+    /*
+     * Issue LISTEN command to enable notifications from the rule's NOTIFY.
+     */
+    res = PQexec(conn, "LISTEN TBL2");
+    if (PQresultStatus(res) != PGRES_COMMAND_OK)
+    {
+        fprintf(stderr, "LISTEN command failed: %s", PQerrorMessage(conn));
+        PQclear(res);
+        exit_nicely(conn);
+    }
+
+    /*
+     * should PQclear PGresult whenever it is no longer needed to avoid memory
+     * leaks
+     */
+    PQclear(res);
+
+    /* Quit after four notifies are received. */
+    nnotifies = 0;
+    while (nnotifies < 4)
+    {
+        /*
+         * Sleep until something happens on the connection.  We use select(2)
+         * to wait for input, but you could also use poll() or similar
+         * facilities.
+         */
+        int         sock;
+        fd_set      input_mask;
+
+        sock = PQsocket(conn);
+
+        if (sock < 0)
+            break;              /* shouldn't happen */
+
+        FD_ZERO(&input_mask);
+        FD_SET(sock, &input_mask);
+
+        if (select(sock + 1, &input_mask, NULL, NULL, NULL) < 0)
+        {
+            fprintf(stderr, "select() failed: %s\n", strerror(errno));
+            exit_nicely(conn);
+        }
+
+        /* Now check for input */
+        PQconsumeInput(conn);
+        while ((notify = PQnotifies(conn)) != NULL)
+        {
+            fprintf(stderr,
+                    "ASYNC NOTIFY of '%s' received from backend PID %d\n",
+                    notify->relname, notify->be_pid);
+            PQfreemem(notify);
+            nnotifies++;
+        }
+    }
+
+    fprintf(stderr, "Done.\n");
+
+    /* close the connection to the database and cleanup */
+    PQfinish(conn);
+
+    return 0;
+}

Example 31-3. libpq Example Program 3

/*
+ * testlibpq3.c
+ *      Test out-of-line parameters and binary I/O.
+ *
+ * Before running this, populate a database with the following commands
+ * (provided in src/test/examples/testlibpq3.sql):
+ *
+ * CREATE TABLE test1 (i int4, t text, b bytea);
+ *
+ * INSERT INTO test1 values (1, 'joe''s place', '\\000\\001\\002\\003\\004');
+ * INSERT INTO test1 values (2, 'ho there', '\\004\\003\\002\\001\\000');
+ *
+ * The expected output is:
+ *
+ * tuple 0: got
+ *  i = (4 bytes) 1
+ *  t = (11 bytes) 'joe's place'
+ *  b = (5 bytes) \000\001\002\003\004
+ *
+ * tuple 0: got
+ *  i = (4 bytes) 2
+ *  t = (8 bytes) 'ho there'
+ *  b = (5 bytes) \004\003\002\001\000
+ */
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <sys/types.h>
+#include <libpq-fe.h>
+
+/* for ntohl/htonl */
+#include <netinet/in.h>
+#include <arpa/inet.h>
+
+
+static void
+exit_nicely(PGconn *conn)
+{
+    PQfinish(conn);
+    exit(1);
+}
+
+/*
+ * This function prints a query result that is a binary-format fetch from
+ * a table defined as in the comment above.  We split it out because the
+ * main() function uses it twice.
+ */
+static void
+show_binary_results(PGresult *res)
+{
+    int         i,
+                j;
+    int         i_fnum,
+                t_fnum,
+                b_fnum;
+
+    /* Use PQfnumber to avoid assumptions about field order in result */
+    i_fnum = PQfnumber(res, "i");
+    t_fnum = PQfnumber(res, "t");
+    b_fnum = PQfnumber(res, "b");
+
+    for (i = 0; i < PQntuples(res); i++)
+    {
+        char       *iptr;
+        char       *tptr;
+        char       *bptr;
+        int         blen;
+        int         ival;
+
+        /* Get the field values (we ignore possibility they are null!) */
+        iptr = PQgetvalue(res, i, i_fnum);
+        tptr = PQgetvalue(res, i, t_fnum);
+        bptr = PQgetvalue(res, i, b_fnum);
+
+        /*
+         * The binary representation of INT4 is in network byte order, which
+         * we'd better coerce to the local byte order.
+         */
+        ival = ntohl(*((uint32_t *) iptr));
+
+        /*
+         * The binary representation of TEXT is, well, text, and since libpq
+         * was nice enough to append a zero byte to it, it'll work just fine
+         * as a C string.
+         *
+         * The binary representation of BYTEA is a bunch of bytes, which could
+         * include embedded nulls so we have to pay attention to field length.
+         */
+        blen = PQgetlength(res, i, b_fnum);
+
+        printf("tuple %d: got\n", i);
+        printf(" i = (%d bytes) %d\n",
+               PQgetlength(res, i, i_fnum), ival);
+        printf(" t = (%d bytes) '%s'\n",
+               PQgetlength(res, i, t_fnum), tptr);
+        printf(" b = (%d bytes) ", blen);
+        for (j = 0; j < blen; j++)
+            printf("\\%03o", bptr[j]);
+        printf("\n\n");
+    }
+}
+
+int
+main(int argc, char **argv)
+{
+    const char *conninfo;
+    PGconn     *conn;
+    PGresult   *res;
+    const char *paramValues[1];
+    int         paramLengths[1];
+    int         paramFormats[1];
+    uint32_t    binaryIntVal;
+
+    /*
+     * If the user supplies a parameter on the command line, use it as the
+     * conninfo string; otherwise default to setting dbname=postgres and using
+     * environment variables or defaults for all other connection parameters.
+     */
+    if (argc > 1)
+        conninfo = argv[1];
+    else
+        conninfo = "dbname = postgres";
+
+    /* Make a connection to the database */
+    conn = PQconnectdb(conninfo);
+
+    /* Check to see that the backend connection was successfully made */
+    if (PQstatus(conn) != CONNECTION_OK)
+    {
+        fprintf(stderr, "Connection to database failed: %s",
+                PQerrorMessage(conn));
+        exit_nicely(conn);
+    }
+
+    /*
+     * The point of this program is to illustrate use of PQexecParams() with
+     * out-of-line parameters, as well as binary transmission of data.
+     *
+     * This first example transmits the parameters as text, but receives the
+     * results in binary format.  By using out-of-line parameters we can
+     * avoid a lot of tedious mucking about with quoting and escaping, even
+     * though the data is text.  Notice how we don't have to do anything
+     * special with the quote mark in the parameter value.
+     */
+
+    /* Here is our out-of-line parameter value */
+    paramValues[0] = "joe's place";
+
+    res = PQexecParams(conn,
+                       "SELECT * FROM test1 WHERE t = $1",
+                       1,       /* one param */
+                       NULL,    /* let the backend deduce param type */
+                       paramValues,
+                       NULL,    /* don't need param lengths since text */
+                       NULL,    /* default to all text params */
+                       1);      /* ask for binary results */
+
+    if (PQresultStatus(res) != PGRES_TUPLES_OK)
+    {
+        fprintf(stderr, "SELECT failed: %s", PQerrorMessage(conn));
+        PQclear(res);
+        exit_nicely(conn);
+    }
+
+    show_binary_results(res);
+
+    PQclear(res);
+
+    /*
+     * In this second example we transmit an integer parameter in binary
+     * form, and again retrieve the results in binary form.
+     *
+     * Although we tell PQexecParams we are letting the backend deduce
+     * parameter type, we really force the decision by casting the parameter
+     * symbol in the query text.  This is a good safety measure when sending
+     * binary parameters.
+     */
+
+    /* Convert integer value "2" to network byte order */
+    binaryIntVal = htonl((uint32_t) 2);
+
+    /* Set up parameter arrays for PQexecParams */
+    paramValues[0] = (char *) &binaryIntVal;
+    paramLengths[0] = sizeof(binaryIntVal);
+    paramFormats[0] = 1;        /* binary */
+
+    res = PQexecParams(conn,
+                       "SELECT * FROM test1 WHERE i = $1::int4",
+                       1,       /* one param */
+                       NULL,    /* let the backend deduce param type */
+                       paramValues,
+                       paramLengths,
+                       paramFormats,
+                       1);      /* ask for binary results */
+
+    if (PQresultStatus(res) != PGRES_TUPLES_OK)
+    {
+        fprintf(stderr, "SELECT failed: %s", PQerrorMessage(conn));
+        PQclear(res);
+        exit_nicely(conn);
+    }
+
+    show_binary_results(res);
+
+    PQclear(res);
+
+    /* close the connection to the database and cleanup */
+    PQfinish(conn);
+
+    return 0;
+}

PrevHomeNext
Building libpq ProgramsUpLarge Objects
\ No newline at end of file diff --git a/doc/src/sgml/html/libpq-exec.html b/doc/src/sgml/html/libpq-exec.html new file mode 100644 index 000000000..16ffe4a17 --- /dev/null +++ b/doc/src/sgml/html/libpq-exec.html @@ -0,0 +1,3151 @@ + +Command Execution Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 31. libpq - C LibraryNext

31.3. Command Execution Functions

Once a connection to a database server has been successfully + established, the functions described here are used to perform + SQL queries and commands. +

31.3.1. Main Functions

PQexec +

Submits a command to the server and waits for the result. + +

PGresult *PQexec(PGconn *conn, const char *command);

+

Returns a PGresult pointer or possibly a null + pointer. A non-null pointer will generally be returned except in + out-of-memory conditions or serious errors such as inability to send + the command to the server. The PQresultStatus function + should be called to check the return value for any errors (including + the value of a null pointer, in which case it will return + PGRES_FATAL_ERROR). Use + PQerrorMessage to get more information about such + errors. +

+ + The command string can include multiple SQL commands + (separated by semicolons). Multiple queries sent in a single + PQexec call are processed in a single transaction, unless + there are explicit BEGIN/COMMIT + commands included in the query string to divide it into multiple + transactions. Note however that the returned + PGresult structure describes only the result + of the last command executed from the string. Should one of the + commands fail, processing of the string stops with it and the returned + PGresult describes the error condition. +

PQexecParams +

Submits a command to the server and waits for the result, + with the ability to pass parameters separately from the SQL + command text. + +

PGresult *PQexecParams(PGconn *conn,
+                       const char *command,
+                       int nParams,
+                       const Oid *paramTypes,
+                       const char * const *paramValues,
+                       const int *paramLengths,
+                       const int *paramFormats,
+                       int resultFormat);

+

PQexecParams is like PQexec, but offers additional + functionality: parameter values can be specified separately from the command + string proper, and query results can be requested in either text or binary + format. PQexecParams is supported only in protocol 3.0 and later + connections; it will fail when using protocol 2.0. +

The function arguments are: + +

conn

The connection object to send the command through. +

command

The SQL command string to be executed. If parameters are used, + they are referred to in the command string as $1, + $2, etc. +

nParams

The number of parameters supplied; it is the length of the arrays + paramTypes[], paramValues[], + paramLengths[], and paramFormats[]. (The + array pointers can be NULL when nParams + is zero.) +

paramTypes[]

Specifies, by OID, the data types to be assigned to the + parameter symbols. If paramTypes is + NULL, or any particular element in the array + is zero, the server infers a data type for the parameter symbol + in the same way it would do for an untyped literal string. +

paramValues[]

Specifies the actual values of the parameters. A null pointer + in this array means the corresponding parameter is null; + otherwise the pointer points to a zero-terminated text string + (for text format) or binary data in the format expected by the + server (for binary format). +

paramLengths[]

Specifies the actual data lengths of binary-format parameters. + It is ignored for null parameters and text-format parameters. + The array pointer can be null when there are no binary parameters. +

paramFormats[]

Specifies whether parameters are text (put a zero in the + array entry for the corresponding parameter) or binary (put + a one in the array entry for the corresponding parameter). + If the array pointer is null then all parameters are presumed + to be text strings. +

Values passed in binary format require knowledge of + the internal representation expected by the backend. + For example, integers must be passed in network byte + order. Passing numeric values requires + knowledge of the server storage format, as implemented + in + src/backend/utils/adt/numeric.c::numeric_send() and + src/backend/utils/adt/numeric.c::numeric_recv(). +

resultFormat

Specify zero to obtain results in text format, or one to obtain + results in binary format. (There is not currently a provision + to obtain different result columns in different formats, + although that is possible in the underlying protocol.) +

+

+

The primary advantage of PQexecParams over + PQexec is that parameter values can be separated from the + command string, thus avoiding the need for tedious and error-prone + quoting and escaping. +

Unlike PQexec, PQexecParams allows at most + one SQL command in the given string. (There can be semicolons in it, + but not more than one nonempty command.) This is a limitation of the + underlying protocol, but has some usefulness as an extra defense against + SQL-injection attacks. +

Tip: Specifying parameter types via OIDs is tedious, particularly if you prefer + not to hard-wire particular OID values into your program. However, you can + avoid doing so even in cases where the server by itself cannot determine the + type of the parameter, or chooses a different type than you want. In the + SQL command text, attach an explicit cast to the parameter symbol to show what + data type you will send. For example: +

SELECT * FROM mytable WHERE x = $1::bigint;

+ This forces parameter $1 to be treated as bigint, whereas + by default it would be assigned the same type as x. Forcing the + parameter type decision, either this way or by specifying a numeric type OID, + is strongly recommended when sending parameter values in binary format, because + binary format has less redundancy than text format and so there is less chance + that the server will detect a type mismatch mistake for you. +

PQprepare +

Submits a request to create a prepared statement with the + given parameters, and waits for completion. +

PGresult *PQprepare(PGconn *conn,
+                    const char *stmtName,
+                    const char *query,
+                    int nParams,
+                    const Oid *paramTypes);

+

PQprepare creates a prepared statement for later + execution with PQexecPrepared. This feature allows + commands that will be used repeatedly to be parsed and planned just + once, rather than each time they are executed. + PQprepare is supported only in protocol 3.0 and later + connections; it will fail when using protocol 2.0. +

The function creates a prepared statement named + stmtName from the query string, which + must contain a single SQL command. stmtName can be + "" to create an unnamed statement, in which case any + pre-existing unnamed statement is automatically replaced; otherwise + it is an error if the statement name is already defined in the + current session. If any parameters are used, they are referred + to in the query as $1, $2, etc. + nParams is the number of parameters for which types + are pre-specified in the array paramTypes[]. (The + array pointer can be NULL when + nParams is zero.) paramTypes[] + specifies, by OID, the data types to be assigned to the parameter + symbols. If paramTypes is NULL, + or any particular element in the array is zero, the server assigns + a data type to the parameter symbol in the same way it would do + for an untyped literal string. Also, the query can use parameter + symbols with numbers higher than nParams; data types + will be inferred for these symbols as well. (See + PQdescribePrepared for a means to find out + what data types were inferred.) +

As with PQexec, the result is normally a + PGresult object whose contents indicate + server-side success or failure. A null result indicates + out-of-memory or inability to send the command at all. Use + PQerrorMessage to get more information about + such errors. +

+ + Prepared statements for use with PQexecPrepared can also + be created by executing SQL PREPARE + statements. Also, although there is no libpq + function for deleting a prepared statement, the SQL DEALLOCATE statement + can be used for that purpose. +

PQexecPrepared +

Sends a request to execute a prepared statement with given + parameters, and waits for the result. +

PGresult *PQexecPrepared(PGconn *conn,
+                         const char *stmtName,
+                         int nParams,
+                         const char * const *paramValues,
+                         const int *paramLengths,
+                         const int *paramFormats,
+                         int resultFormat);

+

PQexecPrepared is like PQexecParams, + but the command to be executed is specified by naming a + previously-prepared statement, instead of giving a query string. + This feature allows commands that will be used repeatedly to be + parsed and planned just once, rather than each time they are + executed. The statement must have been prepared previously in + the current session. PQexecPrepared is supported + only in protocol 3.0 and later connections; it will fail when + using protocol 2.0. +

The parameters are identical to PQexecParams, except that the + name of a prepared statement is given instead of a query string, and the + paramTypes[] parameter is not present (it is not needed since + the prepared statement's parameter types were determined when it was created). +

PQdescribePrepared +

Submits a request to obtain information about the specified + prepared statement, and waits for completion. +

PGresult *PQdescribePrepared(PGconn *conn, const char *stmtName);

+

PQdescribePrepared allows an application to obtain + information about a previously prepared statement. + PQdescribePrepared is supported only in protocol 3.0 + and later connections; it will fail when using protocol 2.0. +

stmtName can be "" or NULL to reference + the unnamed statement, otherwise it must be the name of an existing + prepared statement. On success, a PGresult with + status PGRES_COMMAND_OK is returned. The + functions PQnparams and + PQparamtype can be applied to this + PGresult to obtain information about the parameters + of the prepared statement, and the functions + PQnfields, PQfname, + PQftype, etc provide information about the + result columns (if any) of the statement. +

PQdescribePortal +

Submits a request to obtain information about the specified + portal, and waits for completion. +

PGresult *PQdescribePortal(PGconn *conn, const char *portalName);

+

PQdescribePortal allows an application to obtain + information about a previously created portal. + (libpq does not provide any direct access to + portals, but you can use this function to inspect the properties + of a cursor created with a DECLARE CURSOR SQL command.) + PQdescribePortal is supported only in protocol 3.0 + and later connections; it will fail when using protocol 2.0. +

portalName can be "" or NULL to reference + the unnamed portal, otherwise it must be the name of an existing + portal. On success, a PGresult with status + PGRES_COMMAND_OK is returned. The functions + PQnfields, PQfname, + PQftype, etc can be applied to the + PGresult to obtain information about the result + columns (if any) of the portal. +

+

The PGresult + structure encapsulates the result returned by the server. + libpq application programmers should be + careful to maintain the PGresult abstraction. + Use the accessor functions below to get at the contents of + PGresult. Avoid directly referencing the + fields of the PGresult structure because they + are subject to change in the future. + +

PQresultStatus +

Returns the result status of the command. +

ExecStatusType PQresultStatus(const PGresult *res);

+

PQresultStatus can return one of the following values: + +

PGRES_EMPTY_QUERY

The string sent to the server was empty. +

PGRES_COMMAND_OK

Successful completion of a command returning no data. +

PGRES_TUPLES_OK

Successful completion of a command returning data (such as + a SELECT or SHOW). +

PGRES_COPY_OUT

Copy Out (from server) data transfer started. +

PGRES_COPY_IN

Copy In (to server) data transfer started. +

PGRES_BAD_RESPONSE

The server's response was not understood. +

PGRES_NONFATAL_ERROR

A nonfatal error (a notice or warning) occurred. +

PGRES_FATAL_ERROR

A fatal error occurred. +

PGRES_COPY_BOTH

Copy In/Out (to and from server) data transfer started. This + feature is currently used only for streaming replication, + so this status should not occur in ordinary applications. +

PGRES_SINGLE_TUPLE

The PGresult contains a single result tuple + from the current command. This status occurs only when + single-row mode has been selected for the query + (see Section 31.5). +

+ + If the result status is PGRES_TUPLES_OK or + PGRES_SINGLE_TUPLE, then + the functions described below can be used to retrieve the rows + returned by the query. Note that a SELECT + command that happens to retrieve zero rows still shows + PGRES_TUPLES_OK. + PGRES_COMMAND_OK is for commands that can never + return rows (INSERT, UPDATE, + etc.). A response of PGRES_EMPTY_QUERY might + indicate a bug in the client software. +

A result of status PGRES_NONFATAL_ERROR will + never be returned directly by PQexec or other + query execution functions; results of this kind are instead passed + to the notice processor (see Section 31.12). +

PQresStatus +

Converts the enumerated type returned by + PQresultStatus into a string constant describing the + status code. The caller should not free the result. + +

char *PQresStatus(ExecStatusType status);

+

PQresultErrorMessage +

Returns the error message associated with the command, or an empty string + if there was no error. +

char *PQresultErrorMessage(const PGresult *res);

+ If there was an error, the returned string will include a trailing + newline. The caller should not free the result directly. It will + be freed when the associated PGresult handle is + passed to PQclear. +

Immediately following a PQexec or + PQgetResult call, + PQerrorMessage (on the connection) will return + the same string as PQresultErrorMessage (on + the result). However, a PGresult will + retain its error message until destroyed, whereas the connection's + error message will change when subsequent operations are done. + Use PQresultErrorMessage when you want to + know the status associated with a particular + PGresult; use + PQerrorMessage when you want to know the + status from the latest operation on the connection. +

PQresultErrorField

Returns an individual field of an error report. +

char *PQresultErrorField(const PGresult *res, int fieldcode);

+ fieldcode is an error field identifier; see the symbols + listed below. NULL is returned if the + PGresult is not an error or warning result, + or does not include the specified field. Field values will normally + not include a trailing newline. The caller should not free the + result directly. It will be freed when the + associated PGresult handle is passed to + PQclear. +

The following field codes are available: +

PG_DIAG_SEVERITY

The severity; the field contents are ERROR, + FATAL, or PANIC (in an error message), + or WARNING, NOTICE, DEBUG, + INFO, or LOG (in a notice message), or + a localized translation of one of these. Always present. +

PG_DIAG_SQLSTATE

The SQLSTATE code for the error. The SQLSTATE code identifies + the type of error that has occurred; it can be used by + front-end applications to perform specific operations (such + as error handling) in response to a particular database error. + For a list of the possible SQLSTATE codes, see Appendix A. This field is not localizable, + and is always present. +

PG_DIAG_MESSAGE_PRIMARY

The primary human-readable error message (typically one line). + Always present. +

PG_DIAG_MESSAGE_DETAIL

Detail: an optional secondary error message carrying more + detail about the problem. Might run to multiple lines. +

PG_DIAG_MESSAGE_HINT

Hint: an optional suggestion what to do about the problem. + This is intended to differ from detail in that it offers advice + (potentially inappropriate) rather than hard facts. Might + run to multiple lines. +

PG_DIAG_STATEMENT_POSITION

A string containing a decimal integer indicating an error cursor + position as an index into the original statement string. The + first character has index 1, and positions are measured in + characters not bytes. +

PG_DIAG_INTERNAL_POSITION

This is defined the same as the + PG_DIAG_STATEMENT_POSITION field, but it is used + when the cursor position refers to an internally generated + command rather than the one submitted by the client. The + PG_DIAG_INTERNAL_QUERY field will always appear when + this field appears. +

PG_DIAG_INTERNAL_QUERY

The text of a failed internally-generated command. This could + be, for example, a SQL query issued by a PL/pgSQL function. +

PG_DIAG_CONTEXT

An indication of the context in which the error occurred. + Presently this includes a call stack traceback of active + procedural language functions and internally-generated queries. + The trace is one entry per line, most recent first. +

PG_DIAG_SOURCE_FILE

The file name of the source-code location where the error was + reported. +

PG_DIAG_SOURCE_LINE

The line number of the source-code location where the error + was reported. +

PG_DIAG_SOURCE_FUNCTION

The name of the source-code function reporting the error. +

+

The client is responsible for formatting displayed information to meet + its needs; in particular it should break long lines as needed. + Newline characters appearing in the error message fields should be + treated as paragraph breaks, not line breaks. +

Errors generated internally by libpq will + have severity and primary message, but typically no other fields. + Errors returned by a pre-3.0-protocol server will include severity and + primary message, and sometimes a detail message, but no other fields. +

Note that error fields are only available from + PGresult objects, not + PGconn objects; there is no + PQerrorField function. +

PQclear

Frees the storage associated with a + PGresult. Every command result should be + freed via PQclear when it is no longer + needed. + +

void PQclear(PGresult *res);

+

You can keep a PGresult object around for + as long as you need it; it does not go away when you issue a new + command, nor even if you close the connection. To get rid of it, + you must call PQclear. Failure to do this + will result in memory leaks in your application. +

+

31.3.2. Retrieving Query Result Information

These functions are used to extract information from a + PGresult object that represents a successful + query result (that is, one that has status + PGRES_TUPLES_OK or PGRES_SINGLE_TUPLE). + They can also be used to extract + information from a successful Describe operation: a Describe's result + has all the same column information that actual execution of the query + would provide, but it has zero rows. For objects with other status values, + these functions will act as though the result has zero rows and zero columns. +

PQntuples +

Returns the number of rows (tuples) in the query result. Because + it returns an integer result, large result sets might overflow the + return value on 32-bit operating systems. + +

int PQntuples(const PGresult *res);

+ +

PQnfields +

Returns the number of columns (fields) in each row of the query + result. + +

int PQnfields(const PGresult *res);

+

PQfname +

Returns the column name associated with the given column number. + Column numbers start at 0. The caller should not free the result + directly. It will be freed when the associated + PGresult handle is passed to + PQclear. +

char *PQfname(const PGresult *res,
+              int column_number);

+

NULL is returned if the column number is out of range. +

PQfnumber +

Returns the column number associated with the given column name. +

int PQfnumber(const PGresult *res,
+              const char *column_name);

+

-1 is returned if the given name does not match any column. +

The given name is treated like an identifier in an SQL command, + that is, it is downcased unless double-quoted. For example, given + a query result generated from the SQL command: +

SELECT 1 AS FOO, 2 AS "BAR";

+ we would have the results: +

PQfname(res, 0)              foo
+PQfname(res, 1)              BAR
+PQfnumber(res, "FOO")        0
+PQfnumber(res, "foo")        0
+PQfnumber(res, "BAR")        -1
+PQfnumber(res, "\"BAR\"")    1

+

PQftable +

Returns the OID of the table from which the given column was + fetched. Column numbers start at 0. +

Oid PQftable(const PGresult *res,
+             int column_number);

+

InvalidOid is returned if the column number is out of range, + or if the specified column is not a simple reference to a table column, + or when using pre-3.0 protocol. + You can query the system table pg_class to determine + exactly which table is referenced. +

The type Oid and the constant + InvalidOid will be defined when you include + the libpq header file. They will both + be some integer type. +

PQftablecol +

Returns the column number (within its table) of the column making + up the specified query result column. Query-result column numbers + start at 0, but table columns have nonzero numbers. +

int PQftablecol(const PGresult *res,
+                int column_number);

+

Zero is returned if the column number is out of range, or if the + specified column is not a simple reference to a table column, or + when using pre-3.0 protocol. +

PQfformat +

Returns the format code indicating the format of the given + column. Column numbers start at 0. +

int PQfformat(const PGresult *res,
+              int column_number);

+

Format code zero indicates textual data representation, while format + code one indicates binary representation. (Other codes are reserved + for future definition.) +

PQftype +

Returns the data type associated with the given column number. + The integer returned is the internal OID number of the type. + Column numbers start at 0. +

Oid PQftype(const PGresult *res,
+            int column_number);

+

You can query the system table pg_type to + obtain the names and properties of the various data types. The + OIDs of the built-in data types are defined + in the file src/include/catalog/pg_type.h + in the source tree. +

PQfmod +

Returns the type modifier of the column associated with the + given column number. Column numbers start at 0. +

int PQfmod(const PGresult *res,
+           int column_number);

+

The interpretation of modifier values is type-specific; they + typically indicate precision or size limits. The value -1 is + used to indicate "no information available". Most data + types do not use modifiers, in which case the value is always + -1. +

PQfsize +

Returns the size in bytes of the column associated with the + given column number. Column numbers start at 0. +

int PQfsize(const PGresult *res,
+            int column_number);

+

PQfsize returns the space allocated for this column + in a database row, in other words the size of the server's + internal representation of the data type. (Accordingly, it is + not really very useful to clients.) A negative value indicates + the data type is variable-length. +

PQbinaryTuples +

Returns 1 if the PGresult contains binary data + and 0 if it contains text data. +

int PQbinaryTuples(const PGresult *res);

+

This function is deprecated (except for its use in connection with + COPY), because it is possible for a single + PGresult to contain text data in some columns and + binary data in others. PQfformat is preferred. + PQbinaryTuples returns 1 only if all columns of the + result are binary (format 1). +

PQgetvalue +

Returns a single field value of one row of a + PGresult. Row and column numbers start + at 0. The caller should not free the result directly. It will + be freed when the associated PGresult handle is + passed to PQclear. +

char *PQgetvalue(const PGresult *res,
+                 int row_number,
+                 int column_number);

+

For data in text format, the value returned by + PQgetvalue is a null-terminated character + string representation of the field value. For data in binary + format, the value is in the binary representation determined by + the data type's typsend and typreceive + functions. (The value is actually followed by a zero byte in + this case too, but that is not ordinarily useful, since the + value is likely to contain embedded nulls.) +

An empty string is returned if the field value is null. See + PQgetisnull to distinguish null values from + empty-string values. +

The pointer returned by PQgetvalue points + to storage that is part of the PGresult + structure. One should not modify the data it points to, and one + must explicitly copy the data into other storage if it is to be + used past the lifetime of the PGresult + structure itself. +

PQgetisnull + +

Tests a field for a null value. Row and column numbers start + at 0. +

int PQgetisnull(const PGresult *res,
+                int row_number,
+                int column_number);

+

This function returns 1 if the field is null and 0 if it + contains a non-null value. (Note that + PQgetvalue will return an empty string, + not a null pointer, for a null field.) +

PQgetlength +

Returns the actual length of a field value in bytes. Row and + column numbers start at 0. +

int PQgetlength(const PGresult *res,
+                int row_number,
+                int column_number);

+

This is the actual data length for the particular data value, + that is, the size of the object pointed to by + PQgetvalue. For text data format this is + the same as strlen(). For binary format this is + essential information. Note that one should not + rely on PQfsize to obtain the actual data + length. +

PQnparams +

Returns the number of parameters of a prepared statement. +

int PQnparams(const PGresult *res);

+

This function is only useful when inspecting the result of + PQdescribePrepared. For other types of queries it + will return zero. +

PQparamtype +

Returns the data type of the indicated statement parameter. + Parameter numbers start at 0. +

Oid PQparamtype(const PGresult *res, int param_number);

+

This function is only useful when inspecting the result of + PQdescribePrepared. For other types of queries it + will return zero. +

PQprint +

Prints out all the rows and, optionally, the column names to + the specified output stream. +

void PQprint(FILE *fout,      /* output stream */
+             const PGresult *res,
+             const PQprintOpt *po);
+typedef struct
+{
+    pqbool  header;      /* print output field headings and row count */
+    pqbool  align;       /* fill align the fields */
+    pqbool  standard;    /* old brain dead format */
+    pqbool  html3;       /* output HTML tables */
+    pqbool  expanded;    /* expand tables */
+    pqbool  pager;       /* use pager for output if needed */
+    char    *fieldSep;   /* field separator */
+    char    *tableOpt;   /* attributes for HTML table element */
+    char    *caption;    /* HTML table caption */
+    char    **fieldName; /* null-terminated array of replacement field names */
+} PQprintOpt;

+

This function was formerly used by psql + to print query results, but this is no longer the case. Note + that it assumes all the data is in text format. +

31.3.3. Retrieving Other Result Information

These functions are used to extract other information from + PGresult objects. +

PQcmdStatus +

Returns the command status tag from the SQL command that generated + the PGresult. +

char *PQcmdStatus(PGresult *res);

+

Commonly this is just the name of the command, but it might include + additional data such as the number of rows processed. The caller + should not free the result directly. It will be freed when the + associated PGresult handle is passed to + PQclear. +

PQcmdTuples +

Returns the number of rows affected by the SQL command. +

char *PQcmdTuples(PGresult *res);

+

This function returns a string containing the number of rows + affected by the SQL statement that generated the + PGresult. This function can only be used following + the execution of a SELECT, CREATE TABLE AS, + INSERT, UPDATE, DELETE, + MOVE, FETCH, or COPY statement, + or an EXECUTE of a prepared query that contains an + INSERT, UPDATE, or DELETE statement. + If the command that generated the PGresult was anything + else, PQcmdTuples returns an empty string. The caller + should not free the return value directly. It will be freed when + the associated PGresult handle is passed to + PQclear. +

PQoidValue +

Returns the OID + of the inserted row, if the SQL command was an + INSERT that inserted exactly one row into a table that + has OIDs, or a EXECUTE of a prepared query containing + a suitable INSERT statement. Otherwise, this function + returns InvalidOid. This function will also + return InvalidOid if the table affected by the + INSERT statement does not contain OIDs. +

Oid PQoidValue(const PGresult *res);

+

PQoidStatus +

This function is deprecated in favor of + PQoidValue and is not thread-safe. + It returns a string with the OID of the inserted row, while + PQoidValue returns the OID value. +

char *PQoidStatus(const PGresult *res);

+

31.3.4. Escaping Strings for Inclusion in SQL Commands

PQescapeLiteral +

char *PQescapeLiteral(PGconn *conn, const char *str, size_t length);

+

PQescapeLiteral escapes a string for + use within an SQL command. This is useful when inserting data + values as literal constants in SQL commands. Certain characters + (such as quotes and backslashes) must be escaped to prevent them + from being interpreted specially by the SQL parser. + PQescapeLiteral performs this operation. +

PQescapeLiteral returns an escaped version of the + str parameter in memory allocated with + malloc(). This memory should be freed using + PQfreemem() when the result is no longer needed. + A terminating zero byte is not required, and should not be + counted in length. (If a terminating zero byte is found + before length bytes are processed, + PQescapeLiteral stops at the zero; the behavior is + thus rather like strncpy.) The + return string has all special characters replaced so that they can + be properly processed by the PostgreSQL + string literal parser. A terminating zero byte is also added. The + single quotes that must surround PostgreSQL + string literals are included in the result string. +

On error, PQescapeLiteral returns NULL and a suitable + message is stored in the conn object. +

Tip: It is especially important to do proper escaping when handling + strings that were received from an untrustworthy source. + Otherwise there is a security risk: you are vulnerable to + "SQL injection" attacks wherein unwanted SQL commands are + fed to your database. +

Note that it is not necessary nor correct to do escaping when a data + value is passed as a separate parameter in PQexecParams or + its sibling routines. +

PQescapeIdentifier +

char *PQescapeIdentifier(PGconn *conn, const char *str, size_t length);

+

PQescapeIdentifier escapes a string for + use as an SQL identifier, such as a table, column, or function name. + This is useful when a user-supplied identifier might contain + special characters that would otherwise not be interpreted as part + of the identifier by the SQL parser, or when the identifier might + contain upper case characters whose case should be preserved. +

PQescapeIdentifier returns a version of the + str parameter escaped as an SQL identifier + in memory allocated with malloc(). This memory must be + freed using PQfreemem() when the result is no longer + needed. A terminating zero byte is not required, and should not be + counted in length. (If a terminating zero byte is found + before length bytes are processed, + PQescapeIdentifier stops at the zero; the behavior is + thus rather like strncpy.) The + return string has all special characters replaced so that it + will be properly processed as an SQL identifier. A terminating zero byte + is also added. The return string will also be surrounded by double + quotes. +

On error, PQescapeIdentifier returns NULL and a suitable + message is stored in the conn object. +

Tip: As with string literals, to prevent SQL injection attacks, + SQL identifiers must be escaped when they are received from an + untrustworthy source. +

PQescapeStringConn +

size_t PQescapeStringConn(PGconn *conn,
+                          char *to, const char *from, size_t length,
+                          int *error);

+

PQescapeStringConn escapes string literals, much like + PQescapeLiteral. Unlike PQescapeLiteral, + the caller is responsible for providing an appropriately sized buffer. + Furthermore, PQescapeStringConn does not generate the + single quotes that must surround PostgreSQL string + literals; they should be provided in the SQL command that the + result is inserted into. The parameter from points to + the first character of the string that is to be escaped, and the + length parameter gives the number of bytes in this + string. A terminating zero byte is not required, and should not be + counted in length. (If a terminating zero byte is found + before length bytes are processed, + PQescapeStringConn stops at the zero; the behavior is + thus rather like strncpy.) to shall point + to a buffer that is able to hold at least one more byte than twice + the value of length, otherwise the behavior is undefined. + Behavior is likewise undefined if the to and + from strings overlap. +

If the error parameter is not NULL, then + *error is set to zero on success, nonzero on error. + Presently the only possible error conditions involve invalid multibyte + encoding in the source string. The output string is still generated + on error, but it can be expected that the server will reject it as + malformed. On error, a suitable message is stored in the + conn object, whether or not error is NULL. +

PQescapeStringConn returns the number of bytes written + to to, not including the terminating zero byte. +

PQescapeString +

PQescapeString is an older, deprecated version of + PQescapeStringConn. +

size_t PQescapeString (char *to, const char *from, size_t length);

+

The only difference from PQescapeStringConn is that + PQescapeString does not take PGconn + or error parameters. + Because of this, it cannot adjust its behavior depending on the + connection properties (such as character encoding) and therefore + it might give the wrong results. Also, it has no way + to report error conditions. +

PQescapeString can be used safely in + client programs that work with only one PostgreSQL + connection at a time (in this case it can find out what it needs to + know "behind the scenes"). In other contexts it is a security + hazard and should be avoided in favor of + PQescapeStringConn. +

PQescapeByteaConn +

Escapes binary data for use within an SQL command with the type + bytea. As with PQescapeStringConn, + this is only used when inserting data directly into an SQL command string. +

unsigned char *PQescapeByteaConn(PGconn *conn,
+                                 const unsigned char *from,
+                                 size_t from_length,
+                                 size_t *to_length);

+

Certain byte values must be escaped when used as part of a + bytea literal in an SQL statement. + PQescapeByteaConn escapes bytes using + either hex encoding or backslash escaping. See Section 8.4 for more information. +

The from parameter points to the first + byte of the string that is to be escaped, and the + from_length parameter gives the number of + bytes in this binary string. (A terminating zero byte is + neither necessary nor counted.) The to_length + parameter points to a variable that will hold the resultant + escaped string length. This result string length includes the terminating + zero byte of the result. +

PQescapeByteaConn returns an escaped version of the + from parameter binary string in memory + allocated with malloc(). This memory should be freed using + PQfreemem() when the result is no longer needed. The + return string has all special characters replaced so that they can + be properly processed by the PostgreSQL + string literal parser, and the bytea input function. A + terminating zero byte is also added. The single quotes that must + surround PostgreSQL string literals are + not part of the result string. +

On error, a null pointer is returned, and a suitable error message + is stored in the conn object. Currently, the only + possible error is insufficient memory for the result string. +

PQescapeBytea +

PQescapeBytea is an older, deprecated version of + PQescapeByteaConn. +

unsigned char *PQescapeBytea(const unsigned char *from,
+                             size_t from_length,
+                             size_t *to_length);

+

The only difference from PQescapeByteaConn is that + PQescapeBytea does not take a PGconn + parameter. Because of this, PQescapeBytea can + only be used safely in client programs that use a single + PostgreSQL connection at a time (in this case + it can find out what it needs to know "behind the + scenes"). It might give the wrong results if + used in programs that use multiple database connections (use + PQescapeByteaConn in such cases). +

PQunescapeBytea +

Converts a string representation of binary data into binary data + — the reverse of PQescapeBytea. This + is needed when retrieving bytea data in text format, + but not when retrieving it in binary format. + +

unsigned char *PQunescapeBytea(const unsigned char *from, size_t *to_length);

+

The from parameter points to a string + such as might be returned by PQgetvalue when applied + to a bytea column. PQunescapeBytea + converts this string representation into its binary representation. + It returns a pointer to a buffer allocated with + malloc(), or NULL on error, and puts the size of + the buffer in to_length. The result must be + freed using PQfreemem when it is no longer needed. +

This conversion is not exactly the inverse of + PQescapeBytea, because the string is not expected + to be "escaped" when received from PQgetvalue. + In particular this means there is no need for string quoting considerations, + and so no need for a PGconn parameter. +


PrevHomeNext
Connection Status FunctionsUpAsynchronous Command Processing
\ No newline at end of file diff --git a/doc/src/sgml/html/libpq-fastpath.html b/doc/src/sgml/html/libpq-fastpath.html new file mode 100644 index 000000000..515f1600d --- /dev/null +++ b/doc/src/sgml/html/libpq-fastpath.html @@ -0,0 +1,304 @@ + +The Fast-Path Interface
PostgreSQL 9.2.2 Documentation
PrevUpChapter 31. libpq - C LibraryNext

31.7. The Fast-Path Interface

PostgreSQL provides a fast-path interface + to send simple function calls to the server. +

Tip: This interface is somewhat obsolete, as one can achieve similar + performance and greater functionality by setting up a prepared + statement to define the function call. Then, executing the statement + with binary transmission of parameters and results substitutes for a + fast-path function call. +

The function PQfn + requests execution of a server function via the fast-path interface: +

PGresult *PQfn(PGconn *conn,
+               int fnid,
+               int *result_buf,
+               int *result_len,
+               int result_is_int,
+               const PQArgBlock *args,
+               int nargs);
+
+typedef struct
+{
+    int len;
+    int isint;
+    union
+    {
+        int *ptr;
+        int integer;
+    } u;
+} PQArgBlock;

+

The fnid argument is the OID of the function to be + executed. args and nargs define the + parameters to be passed to the function; they must match the declared + function argument list. When the isint field of a + parameter structure is true, the u.integer value is sent + to the server as an integer of the indicated length (this must be 1, + 2, or 4 bytes); proper byte-swapping occurs. When isint + is false, the indicated number of bytes at *u.ptr are + sent with no processing; the data must be in the format expected by + the server for binary transmission of the function's argument data + type. result_buf is the buffer in which to + place the return value. The caller must have allocated sufficient + space to store the return value. (There is no check!) The actual result + length will be returned in the integer pointed to by + result_len. If a 1, 2, or 4-byte integer result + is expected, set result_is_int to 1, otherwise + set it to 0. Setting result_is_int to 1 causes + libpq to byte-swap the value if necessary, so that it + is delivered as a proper int value for the client machine. + When result_is_int is 0, the binary-format byte string + sent by the server is returned unmodified. +

PQfn always returns a valid + PGresult pointer. The result status should be + checked before the result is used. The caller is responsible for + freeing the PGresult with + PQclear when it is no longer needed. +

Note that it is not possible to handle null arguments, null results, + nor set-valued results when using this interface. +


PrevHomeNext
Canceling Queries in ProgressUpAsynchronous Notification
\ No newline at end of file diff --git a/doc/src/sgml/html/libpq-ldap.html b/doc/src/sgml/html/libpq-ldap.html new file mode 100644 index 000000000..0b94000cb --- /dev/null +++ b/doc/src/sgml/html/libpq-ldap.html @@ -0,0 +1,320 @@ + +LDAP Lookup of Connection Parameters
PostgreSQL 9.2.2 Documentation
PrevUpChapter 31. libpq - C LibraryNext

31.17. LDAP Lookup of Connection Parameters

If libpq has been compiled with LDAP support (option + --with-ldap for configure) + it is possible to retrieve connection options like host + or dbname via LDAP from a central server. + The advantage is that if the connection parameters for a database change, + the connection information doesn't have to be updated on all client machines. +

LDAP connection parameter lookup uses the connection service file + pg_service.conf (see Section 31.16). A line in a + pg_service.conf stanza that starts with + ldap:// will be recognized as an LDAP URL and an + LDAP query will be performed. The result must be a list of + keyword = value pairs which will be used to set + connection options. The URL must conform to RFC 1959 and be of the + form +

ldap://[hostname[:port]]/search_base?attribute?search_scope?filter

+ where hostname defaults to + localhost and port + defaults to 389. +

Processing of pg_service.conf is terminated after + a successful LDAP lookup, but is continued if the LDAP server cannot + be contacted. This is to provide a fallback with further LDAP URL + lines that point to different LDAP servers, classical keyword + = value pairs, or default connection options. If you would + rather get an error message in this case, add a syntactically incorrect + line after the LDAP URL. +

A sample LDAP entry that has been created with the LDIF file +

version:1
+dn:cn=mydatabase,dc=mycompany,dc=com
+changetype:add
+objectclass:top
+objectclass:groupOfUniqueNames
+cn:mydatabase
+uniqueMember:host=dbserver.mycompany.com
+uniqueMember:port=5439
+uniqueMember:dbname=mydb
+uniqueMember:user=mydb_user
+uniqueMember:sslmode=require

+ might be queried with the following LDAP URL: +

ldap://ldap.mycompany.com/dc=mycompany,dc=com?uniqueMember?one?(cn=mydatabase)

+

You can also mix regular service file entries with LDAP lookups. + A complete example for a stanza in pg_service.conf + would be: +

# only host and port are stored in LDAP, specify dbname and user explicitly
+[customerdb]
+dbname=customer
+user=appuser
+ldap://ldap.acme.com/cn=dbserver,cn=hosts?pgconnectinfo?base?(objectclass=*)

+


PrevHomeNext
The Connection Service FileUpSSL Support
\ No newline at end of file diff --git a/doc/src/sgml/html/libpq-misc.html b/doc/src/sgml/html/libpq-misc.html new file mode 100644 index 000000000..674544460 --- /dev/null +++ b/doc/src/sgml/html/libpq-misc.html @@ -0,0 +1,716 @@ + +Miscellaneous Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 31. libpq - C LibraryNext

31.11. Miscellaneous Functions

As always, there are some functions that just don't fit anywhere. +

PQfreemem +

Frees memory allocated by libpq. +

void PQfreemem(void *ptr);

+

Frees memory allocated by libpq, particularly + PQescapeByteaConn, + PQescapeBytea, + PQunescapeBytea, + and PQnotifies. + It is particularly important that this function, rather than + free(), be used on Microsoft Windows. This is because + allocating memory in a DLL and releasing it in the application works + only if multithreaded/single-threaded, release/debug, and static/dynamic + flags are the same for the DLL and the application. On non-Microsoft + Windows platforms, this function is the same as the standard library + function free(). +

PQconninfoFree +

Frees the data structures allocated by + PQconndefaults or PQconninfoParse. +

void PQconninfoFree(PQconninfoOption *connOptions);

+

A simple PQfreemem will not do for this, since + the array contains references to subsidiary strings. +

PQencryptPassword +

Prepares the encrypted form of a PostgreSQL password. +

char * PQencryptPassword(const char *passwd, const char *user);

+ This function is intended to be used by client applications that + wish to send commands like ALTER USER joe PASSWORD + 'pwd'. It is good practice not to send the original cleartext + password in such a command, because it might be exposed in command + logs, activity displays, and so on. Instead, use this function to + convert the password to encrypted form before it is sent. The + arguments are the cleartext password, and the SQL name of the user + it is for. The return value is a string allocated by + malloc, or NULL if out of + memory. The caller can assume the string doesn't contain any + special characters that would require escaping. Use + PQfreemem to free the result when done with it. +

PQmakeEmptyPGresult +

Constructs an empty PGresult object with the given status. +

PGresult *PQmakeEmptyPGresult(PGconn *conn, ExecStatusType status);

+

This is libpq's internal function to allocate and + initialize an empty PGresult object. This + function returns NULL if memory could not be allocated. It is + exported because some applications find it useful to generate result + objects (particularly objects with error status) themselves. If + conn is not null and status + indicates an error, the current error message of the specified + connection is copied into the PGresult. + Also, if conn is not null, any event procedures + registered in the connection are copied into the + PGresult. (They do not get + PGEVT_RESULTCREATE calls, but see + PQfireResultCreateEvents.) + Note that PQclear should eventually be called + on the object, just as with a PGresult + returned by libpq itself. +

PQfireResultCreateEvents +

Fires a PGEVT_RESULTCREATE event (see Section 31.13) for each event procedure registered in the + PGresult object. Returns non-zero for success, + zero if any event procedure fails. + +

int PQfireResultCreateEvents(PGconn *conn, PGresult *res);

+

The conn argument is passed through to event procedures + but not used directly. It can be NULL if the event + procedures won't use it. +

Event procedures that have already received a + PGEVT_RESULTCREATE or PGEVT_RESULTCOPY event + for this object are not fired again. +

The main reason that this function is separate from + PQmakeEmptyPGResult is that it is often appropriate + to create a PGresult and fill it with data + before invoking the event procedures. +

PQcopyResult +

Makes a copy of a PGresult object. The copy is + not linked to the source result in any way and + PQclear must be called when the copy is no longer + needed. If the function fails, NULL is returned. + +

PGresult *PQcopyResult(const PGresult *src, int flags);

+

This is not intended to make an exact copy. The returned result is + always put into PGRES_TUPLES_OK status, and does not + copy any error message in the source. (It does copy the command status + string, however.) The flags argument determines + what else is copied. It is a bitwise OR of several flags. + PG_COPYRES_ATTRS specifies copying the source + result's attributes (column definitions). + PG_COPYRES_TUPLES specifies copying the source + result's tuples. (This implies copying the attributes, too.) + PG_COPYRES_NOTICEHOOKS specifies + copying the source result's notify hooks. + PG_COPYRES_EVENTS specifies copying the source + result's events. (But any instance data associated with the source + is not copied.) +

PQsetResultAttrs +

Sets the attributes of a PGresult object. +

int PQsetResultAttrs(PGresult *res, int numAttributes, PGresAttDesc *attDescs);

+

The provided attDescs are copied into the result. + If the attDescs pointer is NULL or + numAttributes is less than one, the request is + ignored and the function succeeds. If res + already contains attributes, the function will fail. If the function + fails, the return value is zero. If the function succeeds, the return + value is non-zero. +

PQsetvalue +

Sets a tuple field value of a PGresult object. +

int PQsetvalue(PGresult *res, int tup_num, int field_num, char *value, int len);

+

The function will automatically grow the result's internal tuples array + as needed. However, the tup_num argument must be + less than or equal to PQntuples, meaning this + function can only grow the tuples array one tuple at a time. But any + field of any existing tuple can be modified in any order. If a value at + field_num already exists, it will be overwritten. + If len is -1 or + value is NULL, the field value + will be set to an SQL null value. The + value is copied into the result's private storage, + thus is no longer needed after the function + returns. If the function fails, the return value is zero. If the + function succeeds, the return value is non-zero. +

PQresultAlloc +

Allocate subsidiary storage for a PGresult object. +

void *PQresultAlloc(PGresult *res, size_t nBytes);

+

Any memory allocated with this function will be freed when + res is cleared. If the function fails, + the return value is NULL. The result is + guaranteed to be adequately aligned for any type of data, + just as for malloc. +

PQlibVersion +

Return the version of libpq that is being used. +

int PQlibVersion(void);

+

The result of this function can be used to determine, at + run time, if specific functionality is available in the currently + loaded version of libpq. The function can be used, for example, + to determine which connection options are available for + PQconnectdb or if the hex bytea + output added in PostgreSQL 9.0 is supported. +

The number is formed by converting the major, minor, and revision + numbers into two-decimal-digit numbers and appending them together. + For example, version 9.1 will be returned as 90100, and version + 9.1.2 will be returned as 90102 (leading zeroes are not shown). +

Note: This function appeared in PostgreSQL version 9.1, so + it cannot be used to detect required functionality in earlier + versions, since linking to it will create a link dependency + on version 9.1. +


PrevHomeNext
Control FunctionsUpNotice Processing
\ No newline at end of file diff --git a/doc/src/sgml/html/libpq-notice-processing.html b/doc/src/sgml/html/libpq-notice-processing.html new file mode 100644 index 000000000..15e66feff --- /dev/null +++ b/doc/src/sgml/html/libpq-notice-processing.html @@ -0,0 +1,310 @@ + +Notice Processing
PostgreSQL 9.2.2 Documentation
PrevUpChapter 31. libpq - C LibraryNext

31.12. Notice Processing

Notice and warning messages generated by the server are not returned + by the query execution functions, since they do not imply failure of + the query. Instead they are passed to a notice handling function, and + execution continues normally after the handler returns. The default + notice handling function prints the message on + stderr, but the application can override this + behavior by supplying its own handling function. +

For historical reasons, there are two levels of notice handling, called + the notice receiver and notice processor. The default behavior is for + the notice receiver to format the notice and pass a string to the notice + processor for printing. However, an application that chooses to provide + its own notice receiver will typically ignore the notice processor + layer and just do all the work in the notice receiver. +

The function PQsetNoticeReceiver + + sets or + examines the current notice receiver for a connection object. + Similarly, PQsetNoticeProcessor + + sets or + examines the current notice processor. + +

typedef void (*PQnoticeReceiver) (void *arg, const PGresult *res);
+
+PQnoticeReceiver
+PQsetNoticeReceiver(PGconn *conn,
+                    PQnoticeReceiver proc,
+                    void *arg);
+
+typedef void (*PQnoticeProcessor) (void *arg, const char *message);
+
+PQnoticeProcessor
+PQsetNoticeProcessor(PGconn *conn,
+                     PQnoticeProcessor proc,
+                     void *arg);

+ + Each of these functions returns the previous notice receiver or + processor function pointer, and sets the new value. If you supply a + null function pointer, no action is taken, but the current pointer is + returned. +

When a notice or warning message is received from the server, or + generated internally by libpq, the notice + receiver function is called. It is passed the message in the form of + a PGRES_NONFATAL_ERROR + PGresult. (This allows the receiver to extract + individual fields using PQresultErrorField, or the complete + preformatted message using PQresultErrorMessage.) The same + void pointer passed to PQsetNoticeReceiver is also + passed. (This pointer can be used to access application-specific state + if needed.) +

The default notice receiver simply extracts the message (using + PQresultErrorMessage) and passes it to the notice + processor. +

The notice processor is responsible for handling a notice or warning + message given in text form. It is passed the string text of the message + (including a trailing newline), plus a void pointer that is the same + one passed to PQsetNoticeProcessor. (This pointer + can be used to access application-specific state if needed.) +

The default notice processor is simply: +

static void
+defaultNoticeProcessor(void *arg, const char *message)
+{
+    fprintf(stderr, "%s", message);
+}

+

Once you have set a notice receiver or processor, you should expect + that that function could be called as long as either the + PGconn object or PGresult objects made + from it exist. At creation of a PGresult, the + PGconn's current notice handling pointers are copied + into the PGresult for possible use by functions like + PQgetvalue. +


PrevHomeNext
Miscellaneous FunctionsUpEvent System
\ No newline at end of file diff --git a/doc/src/sgml/html/libpq-notify.html b/doc/src/sgml/html/libpq-notify.html new file mode 100644 index 000000000..0e3a402c7 --- /dev/null +++ b/doc/src/sgml/html/libpq-notify.html @@ -0,0 +1,369 @@ + +Asynchronous Notification
PostgreSQL 9.2.2 Documentation
PrevUpChapter 31. libpq - C LibraryNext

31.8. Asynchronous Notification

PostgreSQL offers asynchronous notification + via the LISTEN and NOTIFY + commands. A client session registers its interest in a particular + notification channel with the LISTEN command (and + can stop listening with the UNLISTEN command). All + sessions listening on a particular channel will be notified + asynchronously when a NOTIFY command with that + channel name is executed by any session. A "payload" string can + be passed to communicate additional data to the listeners. +

libpq applications submit + LISTEN, UNLISTEN, + and NOTIFY commands as + ordinary SQL commands. The arrival of NOTIFY + messages can subsequently be detected by calling + PQnotifies. +

The function PQnotifies returns the next notification + from a list of unhandled notification messages received from the server. + It returns a null pointer if there are no pending notifications. Once a + notification is returned from PQnotifies, it is considered + handled and will be removed from the list of notifications. + +

PGnotify *PQnotifies(PGconn *conn);
+
+typedef struct pgNotify
+{
+    char *relname;              /* notification channel name */
+    int  be_pid;                /* process ID of notifying server process */
+    char *extra;                /* notification payload string */
+} PGnotify;

+ + After processing a PGnotify object returned + by PQnotifies, be sure to free it with + PQfreemem. It is sufficient to free the + PGnotify pointer; the + relname and extra + fields do not represent separate allocations. (The names of these fields + are historical; in particular, channel names need not have anything to + do with relation names.) +

Example 31-2 gives a sample program that illustrates + the use of asynchronous notification. +

PQnotifies does not actually read data from the + server; it just returns messages previously absorbed by another + libpq function. In prior releases of + libpq, the only way to ensure timely receipt + of NOTIFY messages was to constantly submit commands, even + empty ones, and then check PQnotifies after each + PQexec. While this still works, it is deprecated + as a waste of processing power. +

A better way to check for NOTIFY messages when you have no + useful commands to execute is to call + PQconsumeInput, then check + PQnotifies. You can use + select() to wait for data to arrive from the + server, thereby using no CPU power unless there is + something to do. (See PQsocket to obtain the file + descriptor number to use with select().) Note that + this will work OK whether you submit commands with + PQsendQuery/PQgetResult or + simply use PQexec. You should, however, remember + to check PQnotifies after each + PQgetResult or PQexec, to + see if any notifications came in during the processing of the command. +


PrevHomeNext
The Fast-Path InterfaceUpFunctions Associated with the COPY Command
\ No newline at end of file diff --git a/doc/src/sgml/html/libpq-pgpass.html b/doc/src/sgml/html/libpq-pgpass.html new file mode 100644 index 000000000..de7e15602 --- /dev/null +++ b/doc/src/sgml/html/libpq-pgpass.html @@ -0,0 +1,278 @@ + +The Password File
PostgreSQL 9.2.2 Documentation
PrevUpChapter 31. libpq - C LibraryNext

31.15. The Password File

The file .pgpass in a user's home directory or the + file referenced by PGPASSFILE can contain passwords to + be used if the connection requires a password (and no password has been + specified otherwise). On Microsoft Windows the file is named + %APPDATA%\postgresql\pgpass.conf (where + %APPDATA% refers to the Application Data subdirectory in + the user's profile). +

This file should contain lines of the following format: +

hostname:port:database:username:password

+ (You can add a reminder comment to the file by copying the line above and + preceding it with #.) + Each of the first four fields can be a literal value, or + *, which matches anything. The password field from + the first line that matches the current connection parameters will be + used. (Therefore, put more-specific entries first when you are using + wildcards.) If an entry needs to contain : or + \, escape this character with \. + A host name of localhost matches both TCP (host name + localhost) and Unix domain socket (pghost empty + or the default socket directory) connections coming from the local + machine. In a standby server, a database name of replication + matches streaming replication connections made to the master server. + The database field is of limited usefulness because + users have the same password for all databases in the same cluster. +

On Unix systems, the permissions on .pgpass must + disallow any access to world or group; achieve this by the command + chmod 0600 ~/.pgpass. If the permissions are less + strict than this, the file will be ignored. On Microsoft Windows, it + is assumed that the file is stored in a directory that is secure, so + no special permissions check is made. +


PrevHomeNext
Environment VariablesUpThe Connection Service File
\ No newline at end of file diff --git a/doc/src/sgml/html/libpq-pgservice.html b/doc/src/sgml/html/libpq-pgservice.html new file mode 100644 index 000000000..9eccd3f61 --- /dev/null +++ b/doc/src/sgml/html/libpq-pgservice.html @@ -0,0 +1,225 @@ + +The Connection Service File
PostgreSQL 9.2.2 Documentation
PrevUpChapter 31. libpq - C LibraryNext

31.16. The Connection Service File

The connection service file allows libpq connection parameters to be + associated with a single service name. That service name can then be + specified by a libpq connection, and the associated settings will be + used. This allows connection parameters to be modified without requiring + a recompile of the libpq application. The service name can also be + specified using the PGSERVICE environment variable. +

The connection service file can be a per-user service file + at ~/.pg_service.conf or the location + specified by the environment variable PGSERVICEFILE, + or it can be a system-wide file + at etc/pg_service.conf or in the directory + specified by the environment variable + PGSYSCONFDIR. If service definitions with the same + name exist in the user and the system file, the user file takes + precedence. +

The file uses an "INI file" format where the section + name is the service name and the parameters are connection + parameters; see Section 31.1 for a list. For + example: +

# comment
+[mydb]
+host=somehost
+port=5433
+user=admin

+ An example file is provided at + share/pg_service.conf.sample. +


PrevHomeNext
The Password FileUpLDAP Lookup of Connection Parameters
\ No newline at end of file diff --git a/doc/src/sgml/html/libpq-single-row-mode.html b/doc/src/sgml/html/libpq-single-row-mode.html new file mode 100644 index 000000000..f00573557 --- /dev/null +++ b/doc/src/sgml/html/libpq-single-row-mode.html @@ -0,0 +1,341 @@ + +Retrieving Query Results Row-By-Row
PostgreSQL 9.2.2 Documentation
PrevUpChapter 31. libpq - C LibraryNext

31.5. Retrieving Query Results Row-By-Row

Ordinarily, libpq collects a SQL command's + entire result and returns it to the application as a single + PGresult. This can be unworkable for commands + that return a large number of rows. For such cases, applications can use + PQsendQuery and PQgetResult in + single-row mode. In this mode, the result row(s) are + returned to the application one at a time, as they are received from the + server. +

To enter single-row mode, call PQsetSingleRowMode + immediately after a successful call of PQsendQuery + (or a sibling function). This mode selection is effective only for the + currently executing query. Then call PQgetResult + repeatedly, until it returns null, as documented in Section 31.4. If the query returns any rows, they are returned + as individual PGresult objects, which look like + normal query results except for having status code + PGRES_SINGLE_TUPLE instead of + PGRES_TUPLES_OK. After the last row, or immediately if + the query returns zero rows, a zero-row object with status + PGRES_TUPLES_OK is returned; this is the signal that no + more rows will arrive. (But note that it is still necessary to continue + calling PQgetResult until it returns null.) All of + these PGresult objects will contain the same row + description data (column names, types, etc) that an ordinary + PGresult object for the query would have. + Each object should be freed with PQclear as usual. +

PQsetSingleRowMode +

Select single-row mode for the currently-executing query. + +

int PQsetSingleRowMode(PGconn *conn);

+

This function can only be called immediately after + PQsendQuery or one of its sibling functions, + before any other operation on the connection such as + PQconsumeInput or + PQgetResult. If called at the correct time, + the function activates single-row mode for the current query and + returns 1. Otherwise the mode stays unchanged and the function + returns 0. In any case, the mode reverts to normal after + completion of the current query. +

+

Caution

While processing a query, the server may return some rows and then + encounter an error, causing the query to be aborted. Ordinarily, + libpq discards any such rows and reports only the + error. But in single-row mode, those rows will have already been + returned to the application. Hence, the application will see some + PGRES_SINGLE_TUPLE PGresult + objects followed by a PGRES_FATAL_ERROR object. For + proper transactional behavior, the application must be designed to + discard or undo whatever has been done with the previously-processed + rows, if the query ultimately fails. +


PrevHomeNext
Asynchronous Command ProcessingUpCanceling Queries in Progress
\ No newline at end of file diff --git a/doc/src/sgml/html/libpq-ssl.html b/doc/src/sgml/html/libpq-ssl.html new file mode 100644 index 000000000..7623dd4a9 --- /dev/null +++ b/doc/src/sgml/html/libpq-ssl.html @@ -0,0 +1,1052 @@ + +SSL Support
PostgreSQL 9.2.2 Documentation
PrevUpChapter 31. libpq - C LibraryNext

31.18. SSL Support

PostgreSQL has native support for using SSL + connections to encrypt client/server communications for increased + security. See Section 17.9 for details about the server-side + SSL functionality. +

libpq reads the system-wide + OpenSSL configuration file. By default, this + file is named openssl.cnf and is located in the + directory reported by openssl version -d. This default + can be overridden by setting environment variable + OPENSSL_CONF to the name of the desired configuration + file. +

31.18.1. Client Verification of Server Certificates

By default, PostgreSQL will not perform any verification of + the server certificate. This means that it is possible to spoof the server + identity (for example by modifying a DNS record or by taking over the server + IP address) without the client knowing. In order to prevent spoofing, + SSL certificate verification must be used. +

If the parameter sslmode is set to verify-ca, + libpq will verify that the server is trustworthy by checking the + certificate chain up to a trusted certificate authority + (CA). If sslmode is set to verify-full, + libpq will also verify that the server host name matches its + certificate. The SSL connection will fail if the server certificate cannot + be verified. verify-full is recommended in most + security-sensitive environments. +

In verify-full mode, the cn (Common Name) attribute + of the certificate is matched against the host name. If the cn + attribute starts with an asterisk (*), it will be treated as + a wildcard, and will match all characters except a dot + (.). This means the certificate will not match subdomains. + If the connection is made using an IP address instead of a host name, the + IP address will be matched (without doing any DNS lookups). +

To allow server certificate verification, the certificate(s) of one or more + trusted CAs must be + placed in the file ~/.postgresql/root.crt in the user's home + directory. (On Microsoft Windows the file is named + %APPDATA%\postgresql\root.crt.) +

Certificate Revocation List (CRL) entries are also checked + if the file ~/.postgresql/root.crl exists + (%APPDATA%\postgresql\root.crl on Microsoft + Windows). +

The location of the root certificate file and the CRL can be changed by + setting + the connection parameters sslrootcert and sslcrl + or the environment variables PGSSLROOTCERT and PGSSLCRL. +

Note: For backwards compatibility with earlier versions of PostgreSQL, if a + root CA file exists, the behavior of + sslmode=require will be the same + as that of verify-ca, meaning the sever certificate + is validated against the CA. Relying on this behavior is discouraged, + and applications that need certificate validation should always use + verify-ca or verify-full. +

31.18.2. Client Certificates

If the server requests a trusted client certificate, + libpq will send the certificate stored in + file ~/.postgresql/postgresql.crt in the user's home + directory. The certificate must be signed by one of the certificate + authorities (CA) trusted by the server. A matching + private key file ~/.postgresql/postgresql.key must also + be present. The private + key file must not allow any access to world or group; achieve this by the + command chmod 0600 ~/.postgresql/postgresql.key. + On Microsoft Windows these files are named + %APPDATA%\postgresql\postgresql.crt and + %APPDATA%\postgresql\postgresql.key, and there + is no special permissions check since the directory is presumed secure. + The location of the certificate and key files can be overridden by the + connection parameters sslcert and sslkey or the + environment variables PGSSLCERT and PGSSLKEY. +

In some cases, the client certificate might be signed by an + "intermediate" certificate authority, rather than one that is + directly trusted by the server. To use such a certificate, append the + certificate of the signing authority to the postgresql.crt + file, then its parent authority's certificate, and so on up to a + "root" authority that is trusted by the server. The root + certificate should be included in every case where + postgresql.crt contains more than one certificate. +

Note that root.crt lists the top-level CAs that are + considered trusted for signing server certificates. In principle it need + not list the CA that signed the client's certificate, though in most cases + that CA would also be trusted for server certificates. +

31.18.3. Protection Provided in Different Modes

The different values for the sslmode parameter provide different + levels of protection. SSL can provide + protection against three types of attacks: + +

Eavesdropping

If a third party can examine the network traffic between the + client and the server, it can read both connection information (including + the user name and password) and the data that is passed. SSL + uses encryption to prevent this. +

Man in the middle (MITM)

If a third party can modify the data while passing between the + client and server, it can pretend to be the server and therefore see and + modify data even if it is encrypted. The third party can then + forward the connection information and data to the original server, + making it impossible to detect this attack. Common vectors to do this + include DNS poisoning and address hijacking, whereby the client is directed + to a different server than intended. There are also several other + attack methods that can accomplish this. SSL uses certificate + verification to prevent this, by authenticating the server to the client. +

Impersonation

If a third party can pretend to be an authorized client, it can + simply access data it should not have access to. Typically this can + happen through insecure password management. SSL uses + client certificates to prevent this, by making sure that only holders + of valid certificates can access the server. +

+

For a connection to be known secure, SSL usage must be configured + on both the client and the server before the connection + is made. If it is only configured on the server, the client may end up + sending sensitive information (e.g. passwords) before + it knows that the server requires high security. In libpq, secure + connections can be ensured + by setting the sslmode parameter to verify-full or + verify-ca, and providing the system with a root certificate to + verify against. This is analogous to using an https + URL for encrypted web browsing. +

Once the server has been authenticated, the client can pass sensitive data. + This means that up until this point, the client does not need to know if + certificates will be used for authentication, making it safe to specify that + only in the server configuration. +

All SSL options carry overhead in the form of encryption and + key-exchange, so there is a tradeoff that has to be made between performance + and security. Table 31-1 + illustrates the risks the different sslmode values + protect against, and what statement they make about security and overhead. +

Table 31-1. SSL Mode Descriptions

sslmodeEavesdropping protectionMITM protectionStatement
disableNoNoI don't care about security, and I don't want to pay the overhead + of encryption. +
allowMaybeNoI don't care about security, but I will pay the overhead of + encryption if the server insists on it. +
preferMaybeNoI don't care about encryption, but I wish to pay the overhead of + encryption if the server supports it. +
requireYesNoI want my data to be encrypted, and I accept the overhead. I trust + that the network will make sure I always connect to the server I want. +
verify-caYesDepends on CA-policyI want my data encrypted, and I accept the overhead. I want to be + sure that I connect to a server that I trust. +
verify-fullYesYesI want my data encrypted, and I accept the overhead. I want to be + sure that I connect to a server I trust, and that it's the one I + specify. +

The difference between verify-ca and verify-full + depends on the policy of the root CA. If a public + CA is used, verify-ca allows connections to a server + that somebody else may have registered with the CA. + In this case, verify-full should always be used. If + a local CA is used, or even a self-signed certificate, using + verify-ca often provides enough protection. +

The default value for sslmode is prefer. As is shown + in the table, this makes no sense from a security point of view, and it only + promises performance overhead if possible. It is only provided as the default + for backward compatibility, and is not recommended in secure deployments. +

31.18.4. SSL Client File Usage

Table 31-2 summarizes the files that are + relevant to the SSL setup on the client. +

Table 31-2. Libpq/Client SSL File Usage

FileContentsEffect
~/.postgresql/postgresql.crtclient certificaterequested by server
~/.postgresql/postgresql.keyclient private keyproves client certificate sent by owner; does not indicate + certificate owner is trustworthy
~/.postgresql/root.crttrusted certificate authoritieschecks that server certificate is signed by a trusted certificate + authority
~/.postgresql/root.crlcertificates revoked by certificate authoritiesserver certificate must not be on this list

31.18.5. SSL Library Initialization

If your application initializes libssl and/or + libcrypto libraries and libpq + is built with SSL support, you should call + PQinitOpenSSL to tell libpq + that the libssl and/or libcrypto libraries + have been initialized by your application, so that + libpq will not also initialize those libraries. + + See http://h71000.www7.hp.com/doc/83final/BA554_90007/ch04.html + for details on the SSL API. +

PQinitOpenSSL +

Allows applications to select which security libraries to initialize. +

void PQinitOpenSSL(int do_ssl, int do_crypto);

+

When do_ssl is non-zero, libpq + will initialize the OpenSSL library before first + opening a database connection. When do_crypto is + non-zero, the libcrypto library will be initialized. By + default (if PQinitOpenSSL is not called), both libraries + are initialized. When SSL support is not compiled in, this function is + present but does nothing. +

If your application uses and initializes either OpenSSL + or its underlying libcrypto library, you must + call this function with zeroes for the appropriate parameter(s) + before first opening a database connection. Also be sure that you + have done that initialization before opening a database connection. +

PQinitSSL +

Allows applications to select which security libraries to initialize. +

void PQinitSSL(int do_ssl);

+

This function is equivalent to + PQinitOpenSSL(do_ssl, do_ssl). + It is sufficient for applications that initialize both or neither + of OpenSSL and libcrypto. +

PQinitSSL has been present since + PostgreSQL 8.0, while PQinitOpenSSL + was added in PostgreSQL 8.4, so PQinitSSL + might be preferable for applications that need to work with older + versions of libpq. +

+


PrevHomeNext
LDAP Lookup of Connection ParametersUpBehavior in Threaded Programs
\ No newline at end of file diff --git a/doc/src/sgml/html/libpq-status.html b/doc/src/sgml/html/libpq-status.html new file mode 100644 index 000000000..12270dd44 --- /dev/null +++ b/doc/src/sgml/html/libpq-status.html @@ -0,0 +1,975 @@ + +Connection Status Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 31. libpq - C LibraryNext

31.2. Connection Status Functions

These functions can be used to interrogate the status + of an existing database connection object. +

Tip: + + libpq application programmers should be careful to + maintain the PGconn abstraction. Use the accessor + functions described below to get at the contents of PGconn. + Reference to internal PGconn fields using + libpq-int.h is not recommended because they are subject to change + in the future. +

The following functions return parameter values established at connection. + These values are fixed for the life of the PGconn object. + +

PQdb +

Returns the database name of the connection. +

char *PQdb(const PGconn *conn);

+

PQuser +

Returns the user name of the connection. +

char *PQuser(const PGconn *conn);

+

PQpass +

Returns the password of the connection. +

char *PQpass(const PGconn *conn);

+

PQhost +

Returns the server host name of the connection. +

char *PQhost(const PGconn *conn);

+

PQport +

Returns the port of the connection. + +

char *PQport(const PGconn *conn);

+

PQtty +

Returns the debug TTY of the connection. + (This is obsolete, since the server no longer pays attention + to the TTY setting, but the function remains + for backward compatibility.) + +

char *PQtty(const PGconn *conn);

+

PQoptions +

Returns the command-line options passed in the connection request. +

char *PQoptions(const PGconn *conn);

+

+

The following functions return status data that can change as operations + are executed on the PGconn object. + +

PQstatus +

Returns the status of the connection. +

ConnStatusType PQstatus(const PGconn *conn);

+

The status can be one of a number of values. However, only two of + these are seen outside of an asynchronous connection procedure: + CONNECTION_OK and + CONNECTION_BAD. A good connection to the database + has the status CONNECTION_OK. A failed + connection attempt is signaled by status + CONNECTION_BAD. Ordinarily, an OK status will + remain so until PQfinish, but a communications + failure might result in the status changing to + CONNECTION_BAD prematurely. In that case the + application could try to recover by calling + PQreset. +

See the entry for PQconnectStartParams, PQconnectStart + and PQconnectPoll with regards to other status codes that + might be returned. +

PQtransactionStatus +

Returns the current in-transaction status of the server. + +

PGTransactionStatusType PQtransactionStatus(const PGconn *conn);

+ + The status can be PQTRANS_IDLE (currently idle), + PQTRANS_ACTIVE (a command is in progress), + PQTRANS_INTRANS (idle, in a valid transaction block), + or PQTRANS_INERROR (idle, in a failed transaction block). + PQTRANS_UNKNOWN is reported if the connection is bad. + PQTRANS_ACTIVE is reported only when a query + has been sent to the server and not yet completed. +

Caution

PQtransactionStatus will give incorrect results when using + a PostgreSQL 7.3 server that has the parameter autocommit + set to off. The server-side autocommit feature has been + deprecated and does not exist in later server versions. +

PQparameterStatus +

Looks up a current parameter setting of the server. + +

const char *PQparameterStatus(const PGconn *conn, const char *paramName);

+ + Certain parameter values are reported by the server automatically at + connection startup or whenever their values change. + PQparameterStatus can be used to interrogate these settings. + It returns the current value of a parameter if known, or NULL + if the parameter is not known. +

Parameters reported as of the current release include + server_version, + server_encoding, + client_encoding, + application_name, + is_superuser, + session_authorization, + DateStyle, + IntervalStyle, + TimeZone, + integer_datetimes, and + standard_conforming_strings. + (server_encoding, TimeZone, and + integer_datetimes were not reported by releases before 8.0; + standard_conforming_strings was not reported by releases + before 8.1; + IntervalStyle was not reported by releases before 8.4; + application_name was not reported by releases before 9.0.) + Note that + server_version, + server_encoding and + integer_datetimes + cannot change after startup. +

Pre-3.0-protocol servers do not report parameter settings, but + libpq includes logic to obtain values for + server_version and client_encoding anyway. + Applications are encouraged to use PQparameterStatus + rather than ad hoc code to determine these values. + (Beware however that on a pre-3.0 connection, changing + client_encoding via SET after connection + startup will not be reflected by PQparameterStatus.) + For server_version, see also + PQserverVersion, which returns the information in a + numeric form that is much easier to compare against. +

If no value for standard_conforming_strings is reported, + applications can assume it is off, that is, backslashes + are treated as escapes in string literals. Also, the presence of + this parameter can be taken as an indication that the escape string + syntax (E'...') is accepted. +

Although the returned pointer is declared const, it in fact + points to mutable storage associated with the PGconn structure. + It is unwise to assume the pointer will remain valid across queries. +

PQprotocolVersion +

Interrogates the frontend/backend protocol being used. +

int PQprotocolVersion(const PGconn *conn);

+ Applications might wish to use this function to determine whether certain + features are supported. Currently, the possible values are 2 (2.0 + protocol), 3 (3.0 protocol), or zero (connection bad). The + protocol version will + not change after connection startup is complete, but it could + theoretically change during a connection reset. The 3.0 protocol + will normally be used when communicating with + PostgreSQL 7.4 or later servers; pre-7.4 servers + support only protocol 2.0. (Protocol 1.0 is obsolete and not + supported by libpq.) +

PQserverVersion +

Returns an integer representing the backend version. +

int PQserverVersion(const PGconn *conn);

+ Applications might use this function to determine the version of the database + server they are connected to. The number is formed by converting + the major, minor, and revision numbers into two-decimal-digit + numbers and appending them together. For example, version 8.1.5 + will be returned as 80105, and version 8.2 will be returned as + 80200 (leading zeroes are not shown). Zero is returned if the + connection is bad. +

PQerrorMessage +

Returns the error message + most recently generated by an operation on the connection. + +

char *PQerrorMessage(const PGconn *conn);

+ +

Nearly all libpq functions will set a message for + PQerrorMessage if they fail. Note that by + libpq convention, a nonempty + PQerrorMessage result can consist of multiple lines, + and will include a trailing newline. The caller should not free + the result directly. It will be freed when the associated + PGconn handle is passed to + PQfinish. The result string should not be + expected to remain the same across operations on the + PGconn structure. +

PQsocket

Obtains the file descriptor number of the connection socket to + the server. A valid descriptor will be greater than or equal + to 0; a result of -1 indicates that no server connection is + currently open. (This will not change during normal operation, + but could change during connection setup or reset.) + +

int PQsocket(const PGconn *conn);

+ +

PQbackendPID

Returns the process ID (PID) + of the backend process handling this connection. + +

int PQbackendPID(const PGconn *conn);

+

The backend PID is useful for debugging + purposes and for comparison to NOTIFY + messages (which include the PID of the + notifying backend process). Note that the + PID belongs to a process executing on the + database server host, not the local host! +

PQconnectionNeedsPassword

Returns true (1) if the connection authentication method + required a password, but none was available. + Returns false (0) if not. + +

int PQconnectionNeedsPassword(const PGconn *conn);

+

This function can be applied after a failed connection attempt + to decide whether to prompt the user for a password. +

PQconnectionUsedPassword

Returns true (1) if the connection authentication method + used a password. Returns false (0) if not. + +

int PQconnectionUsedPassword(const PGconn *conn);

+

This function can be applied after either a failed or successful + connection attempt to detect whether the server demanded a password. +

PQgetssl

+ Returns the SSL structure used in the connection, or null + if SSL is not in use. + +

SSL *PQgetssl(const PGconn *conn);

+

This structure can be used to verify encryption levels, check server + certificates, and more. Refer to the OpenSSL + documentation for information about this structure. +

You must define USE_SSL in order to get the + correct prototype for this function. Doing so will also + automatically include ssl.h from + OpenSSL. +

+


PrevHomeNext
Database Connection Control FunctionsUpCommand Execution Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/libpq-threading.html b/doc/src/sgml/html/libpq-threading.html new file mode 100644 index 000000000..35e2b0941 --- /dev/null +++ b/doc/src/sgml/html/libpq-threading.html @@ -0,0 +1,322 @@ + +Behavior in Threaded Programs
PostgreSQL 9.2.2 Documentation
PrevUpChapter 31. libpq - C LibraryNext

31.19. Behavior in Threaded Programs

libpq is reentrant and thread-safe by default. + You might need to use special compiler command-line + options when you compile your application code. Refer to your + system's documentation for information about how to build + thread-enabled applications, or look in + src/Makefile.global for PTHREAD_CFLAGS + and PTHREAD_LIBS. This function allows the querying of + libpq's thread-safe status: +

PQisthreadsafe +

Returns the thread safety status of the + libpq library. +

int PQisthreadsafe();

+

Returns 1 if the libpq is thread-safe + and 0 if it is not. +

One thread restriction is that no two threads attempt to manipulate + the same PGconn object at the same time. In particular, + you cannot issue concurrent commands from different threads through + the same connection object. (If you need to run concurrent commands, + use multiple connections.) +

PGresult objects are normally read-only after creation, + and so can be passed around freely between threads. However, if you use + any of the PGresult-modifying functions described in + Section 31.11 or Section 31.13, it's up + to you to avoid concurrent operations on the same PGresult, + too. +

The deprecated functions PQrequestCancel and + PQoidStatus are not thread-safe and should not be + used in multithread programs. PQrequestCancel + can be replaced by PQcancel. + PQoidStatus can be replaced by + PQoidValue. +

If you are using Kerberos inside your application (in addition to inside + libpq), you will need to do locking around + Kerberos calls because Kerberos functions are not thread-safe. See + function PQregisterThreadLock in the + libpq source code for a way to do cooperative + locking between libpq and your application. +

If you experience problems with threaded applications, run the program + in src/tools/thread to see if your platform has + thread-unsafe functions. This program is run by + configure, but for binary distributions your + library might not match the library used to build the binaries. +


PrevHomeNext
SSL SupportUpBuilding libpq Programs
\ No newline at end of file diff --git a/doc/src/sgml/html/libpq.html b/doc/src/sgml/html/libpq.html new file mode 100644 index 000000000..77675136a --- /dev/null +++ b/doc/src/sgml/html/libpq.html @@ -0,0 +1,495 @@ + +libpq - C Library

Chapter 31. libpq - C Library

Table of Contents
31.1. Database Connection Control Functions
31.1.1. Connection Strings
31.1.2. Parameter Key Words
31.2. Connection Status Functions
31.3. Command Execution Functions
31.3.1. Main Functions
31.3.2. Retrieving Query Result Information
31.3.3. Retrieving Other Result Information
31.3.4. Escaping Strings for Inclusion in SQL Commands
31.4. Asynchronous Command Processing
31.5. Retrieving Query Results Row-By-Row
31.6. Canceling Queries in Progress
31.7. The Fast-Path Interface
31.8. Asynchronous Notification
31.9. Functions Associated with the COPY Command
31.9.1. Functions for Sending COPY Data
31.9.2. Functions for Receiving COPY Data
31.9.3. Obsolete Functions for COPY
31.10. Control Functions
31.11. Miscellaneous Functions
31.12. Notice Processing
31.13. Event System
31.13.1. Event Types
31.13.2. Event Callback Procedure
31.13.3. Event Support Functions
31.13.4. Event Example
31.14. Environment Variables
31.15. The Password File
31.16. The Connection Service File
31.17. LDAP Lookup of Connection Parameters
31.18. SSL Support
31.18.1. Client Verification of Server Certificates
31.18.2. Client Certificates
31.18.3. Protection Provided in Different Modes
31.18.4. SSL Client File Usage
31.18.5. SSL Library Initialization
31.19. Behavior in Threaded Programs
31.20. Building libpq Programs
31.21. Example Programs

libpq is the C + application programmer's interface to PostgreSQL. + libpq is a set of library functions that allow + client programs to pass queries to the PostgreSQL + backend server and to receive the results of these queries. +

libpq is also the underlying engine for several + other PostgreSQL application interfaces, including + those written for C++, Perl, Python, Tcl and ECPG. + So some aspects of libpq's behavior will be + important to you if you use one of those packages. In particular, + Section 31.14, + Section 31.15 and + Section 31.18 + describe behavior that is visible to the user of any application + that uses libpq. +

Some short programs are included at the end of this chapter (Section 31.21) to show how + to write programs that use libpq. There are also several + complete examples of libpq applications in the + directory src/test/examples in the source code distribution. +

Client programs that use libpq must + include the header file + libpq-fe.h + and must link with the libpq library. +


PrevHomeNext
Client InterfacesUpDatabase Connection Control Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/lo-examplesect.html b/doc/src/sgml/html/lo-examplesect.html new file mode 100644 index 000000000..70197063d --- /dev/null +++ b/doc/src/sgml/html/lo-examplesect.html @@ -0,0 +1,448 @@ + +Example Program

32.5. Example Program

Example 32-1 is a sample program which shows how the large object + interface + in libpq can be used. Parts of the program are + commented out but are left in the source for the reader's + benefit. This program can also be found in + src/test/examples/testlo.c in the source distribution.

Example 32-1. Large Objects with libpq Example Program

/*--------------------------------------------------------------
+ *
+ * testlo.c--
+ *    test using large objects with libpq
+ *
+ * Copyright (c) 1994, Regents of the University of California
+ *
+ *--------------------------------------------------------------
+ */
+#include <stdio.h>
+#include "libpq-fe.h"
+#include "libpq/libpq-fs.h"
+
+#define BUFSIZE          1024
+
+/*
+ * importFile
+ *    import file "in_filename" into database as large object "lobjOid"
+ *
+ */
+Oid
+importFile(PGconn *conn, char *filename)
+{
+    Oid         lobjId;
+    int         lobj_fd;
+    char        buf[BUFSIZE];
+    int         nbytes,
+                tmp;
+    int         fd;
+
+    /*
+     * open the file to be read in
+     */
+    fd = open(filename, O_RDONLY, 0666);
+    if (fd < 0)
+    {                           /* error */
+        fprintf(stderr, "cannot open unix file %s\n", filename);
+    }
+
+    /*
+     * create the large object
+     */
+    lobjId = lo_creat(conn, INV_READ | INV_WRITE);
+    if (lobjId == 0)
+        fprintf(stderr, "cannot create large object\n");
+
+    lobj_fd = lo_open(conn, lobjId, INV_WRITE);
+
+    /*
+     * read in from the Unix file and write to the inversion file
+     */
+    while ((nbytes = read(fd, buf, BUFSIZE)) > 0)
+    {
+        tmp = lo_write(conn, lobj_fd, buf, nbytes);
+        if (tmp < nbytes)
+            fprintf(stderr, "error while reading large object\n");
+    }
+
+    (void) close(fd);
+    (void) lo_close(conn, lobj_fd);
+
+    return lobjId;
+}
+
+void
+pickout(PGconn *conn, Oid lobjId, int start, int len)
+{
+    int         lobj_fd;
+    char       *buf;
+    int         nbytes;
+    int         nread;
+
+    lobj_fd = lo_open(conn, lobjId, INV_READ);
+    if (lobj_fd < 0)
+    {
+        fprintf(stderr, "cannot open large object %d\n",
+                lobjId);
+    }
+
+    lo_lseek(conn, lobj_fd, start, SEEK_SET);
+    buf = malloc(len + 1);
+
+    nread = 0;
+    while (len - nread > 0)
+    {
+        nbytes = lo_read(conn, lobj_fd, buf, len - nread);
+        buf[nbytes] = ' ';
+        fprintf(stderr, ">>> %s", buf);
+        nread += nbytes;
+    }
+    free(buf);
+    fprintf(stderr, "\n");
+    lo_close(conn, lobj_fd);
+}
+
+void
+overwrite(PGconn *conn, Oid lobjId, int start, int len)
+{
+    int         lobj_fd;
+    char       *buf;
+    int         nbytes;
+    int         nwritten;
+    int         i;
+
+    lobj_fd = lo_open(conn, lobjId, INV_WRITE);
+    if (lobj_fd < 0)
+    {
+        fprintf(stderr, "cannot open large object %d\n",
+                lobjId);
+    }
+
+    lo_lseek(conn, lobj_fd, start, SEEK_SET);
+    buf = malloc(len + 1);
+
+    for (i = 0; i < len; i++)
+        buf[i] = 'X';
+    buf[i] = ' ';
+
+    nwritten = 0;
+    while (len - nwritten > 0)
+    {
+        nbytes = lo_write(conn, lobj_fd, buf + nwritten, len - nwritten);
+        nwritten += nbytes;
+    }
+    free(buf);
+    fprintf(stderr, "\n");
+    lo_close(conn, lobj_fd);
+}
+
+/*
+ * exportFile
+ *    export large object "lobjOid" to file "out_filename"
+ *
+ */
+void
+exportFile(PGconn *conn, Oid lobjId, char *filename)
+{
+    int         lobj_fd;
+    char        buf[BUFSIZE];
+    int         nbytes,
+                tmp;
+    int         fd;
+
+    /*
+     * open the large object
+     */
+    lobj_fd = lo_open(conn, lobjId, INV_READ);
+    if (lobj_fd < 0)
+    {
+        fprintf(stderr, "cannot open large object %d\n",
+                lobjId);
+    }
+
+    /*
+     * open the file to be written to
+     */
+    fd = open(filename, O_CREAT | O_WRONLY, 0666);
+    if (fd < 0)
+    {                           /* error */
+        fprintf(stderr, "cannot open unix file %s\n",
+                filename);
+    }
+
+    /*
+     * read in from the inversion file and write to the Unix file
+     */
+    while ((nbytes = lo_read(conn, lobj_fd, buf, BUFSIZE)) > 0)
+    {
+        tmp = write(fd, buf, nbytes);
+        if (tmp < nbytes)
+        {
+            fprintf(stderr, "error while writing %s\n",
+                    filename);
+        }
+    }
+
+    (void) lo_close(conn, lobj_fd);
+    (void) close(fd);
+
+    return;
+}
+
+void
+exit_nicely(PGconn *conn)
+{
+    PQfinish(conn);
+    exit(1);
+}
+
+int
+main(int argc, char **argv)
+{
+    char       *in_filename,
+               *out_filename;
+    char       *database;
+    Oid         lobjOid;
+    PGconn     *conn;
+    PGresult   *res;
+
+    if (argc != 4)
+    {
+        fprintf(stderr, "Usage: %s database_name in_filename out_filename\n",
+                argv[0]);
+        exit(1);
+    }
+
+    database = argv[1];
+    in_filename = argv[2];
+    out_filename = argv[3];
+
+    /*
+     * set up the connection
+     */
+    conn = PQsetdb(NULL, NULL, NULL, NULL, database);
+
+    /* check to see that the backend connection was successfully made */
+    if (PQstatus(conn) == CONNECTION_BAD)
+    {
+        fprintf(stderr, "Connection to database '%s' failed.\n", database);
+        fprintf(stderr, "%s", PQerrorMessage(conn));
+        exit_nicely(conn);
+    }
+
+    res = PQexec(conn, "begin");
+    PQclear(res);
+
+    printf("importing file %s\n", in_filename);
+/*  lobjOid = importFile(conn, in_filename); */
+    lobjOid = lo_import(conn, in_filename);
+/*
+    printf("as large object %d.\n", lobjOid);
+
+    printf("picking out bytes 1000-2000 of the large object\n");
+    pickout(conn, lobjOid, 1000, 1000);
+
+    printf("overwriting bytes 1000-2000 of the large object with X's\n");
+    overwrite(conn, lobjOid, 1000, 1000);
+*/
+
+    printf("exporting large object to file %s\n", out_filename);
+/*    exportFile(conn, lobjOid, out_filename); */
+    lo_export(conn, lobjOid, out_filename);
+
+    res = PQexec(conn, "end");
+    PQclear(res);
+    PQfinish(conn);
+    exit(0);
+}

PrevHomeNext
Server-side FunctionsUpECPG - Embedded SQL in C
\ No newline at end of file diff --git a/doc/src/sgml/html/lo-funcs.html b/doc/src/sgml/html/lo-funcs.html new file mode 100644 index 000000000..129482f4c --- /dev/null +++ b/doc/src/sgml/html/lo-funcs.html @@ -0,0 +1,230 @@ + +Server-side Functions

32.4. Server-side Functions

There are server-side functions callable from SQL that correspond to + each of the client-side functions described above; indeed, for the + most part the client-side functions are simply interfaces to the + equivalent server-side functions. The ones that are actually useful + to call via SQL commands are + lo_creat, + lo_create, + lo_unlink, + lo_import, and + lo_export. + Here are examples of their use: + +

CREATE TABLE image (
+    name            text,
+    raster          oid
+);
+
+SELECT lo_creat(-1);       -- returns OID of new, empty large object
+
+SELECT lo_create(43213);   -- attempts to create large object with OID 43213
+
+SELECT lo_unlink(173454);  -- deletes large object with OID 173454
+
+INSERT INTO image (name, raster)
+    VALUES ('beautiful image', lo_import('/etc/motd'));
+
+INSERT INTO image (name, raster)  -- same as above, but specify OID to use
+    VALUES ('beautiful image', lo_import('/etc/motd', 68583));
+
+SELECT lo_export(image.raster, '/tmp/motd') FROM image
+    WHERE name = 'beautiful image';

+

The server-side lo_import and + lo_export functions behave considerably differently + from their client-side analogs. These two functions read and write files + in the server's file system, using the permissions of the database's + owning user. Therefore, their use is restricted to superusers. In + contrast, the client-side import and export functions read and write files + in the client's file system, using the permissions of the client program. + The client-side functions do not require superuser privilege. +


PrevHomeNext
Client InterfacesUpExample Program
\ No newline at end of file diff --git a/doc/src/sgml/html/lo-implementation.html b/doc/src/sgml/html/lo-implementation.html new file mode 100644 index 000000000..79c3dbed9 --- /dev/null +++ b/doc/src/sgml/html/lo-implementation.html @@ -0,0 +1,205 @@ + +Implementation Features

32.2. Implementation Features

The large object implementation breaks large + objects up into "chunks" and stores the chunks in + rows in the database. A B-tree index guarantees fast + searches for the correct chunk number when doing random + access reads and writes. +

As of PostgreSQL 9.0, large objects have an owner + and a set of access permissions, which can be managed using + GRANT and + REVOKE. + For compatibility with prior releases, see + lo_compat_privileges. + SELECT privileges are required to read a large + object, and + UPDATE privileges are required to write to or + truncate it. + Only the large object owner (or the database superuser) can unlink, comment + on, or change the owner of a large object. +


PrevHomeNext
IntroductionUpClient Interfaces
\ No newline at end of file diff --git a/doc/src/sgml/html/lo-interfaces.html b/doc/src/sgml/html/lo-interfaces.html new file mode 100644 index 000000000..d2ae5dc5f --- /dev/null +++ b/doc/src/sgml/html/lo-interfaces.html @@ -0,0 +1,818 @@ + +Client Interfaces

32.3. Client Interfaces

This section describes the facilities that + PostgreSQL client interface libraries + provide for accessing large objects. All large object + manipulation using these functions must take + place within an SQL transaction block. + The PostgreSQL large object interface is modeled after + the Unix file-system interface, with analogues of + open, read, + write, + lseek, etc. +

Client applications which use the large object interface in + libpq should include the header file + libpq/libpq-fs.h and link with the + libpq library. +

32.3.1. Creating a Large Object

The function +

Oid lo_creat(PGconn *conn, int mode);

+ + creates a new large object. + The return value is the OID that was assigned to the new large object, + or InvalidOid (zero) on failure. + + mode is unused and + ignored as of PostgreSQL 8.1; however, for + backward compatibility with earlier releases it is best to + set it to INV_READ, INV_WRITE, + or INV_READ | INV_WRITE. + (These symbolic constants are defined + in the header file libpq/libpq-fs.h.) +

An example: +

inv_oid = lo_creat(conn, INV_READ|INV_WRITE);

+

The function +

Oid lo_create(PGconn *conn, Oid lobjId);

+ + also creates a new large object. The OID to be assigned can be + specified by lobjId; + if so, failure occurs if that OID is already in use for some large + object. If lobjId + is InvalidOid (zero) then lo_create assigns an unused + OID (this is the same behavior as lo_creat). + The return value is the OID that was assigned to the new large object, + or InvalidOid (zero) on failure. +

lo_create is new as of PostgreSQL + 8.1; if this function is run against an older server version, it will + fail and return InvalidOid. +

An example: +

inv_oid = lo_create(conn, desired_oid);

+

32.3.2. Importing a Large Object

To import an operating system file as a large object, call +

Oid lo_import(PGconn *conn, const char *filename);

+ + filename + specifies the operating system name of + the file to be imported as a large object. + The return value is the OID that was assigned to the new large object, + or InvalidOid (zero) on failure. + Note that the file is read by the client interface library, not by + the server; so it must exist in the client file system and be readable + by the client application. +

The function +

Oid lo_import_with_oid(PGconn *conn, const char *filename, Oid lobjId);

+ + also imports a new large object. The OID to be assigned can be + specified by lobjId; + if so, failure occurs if that OID is already in use for some large + object. If lobjId + is InvalidOid (zero) then lo_import_with_oid assigns an unused + OID (this is the same behavior as lo_import). + The return value is the OID that was assigned to the new large object, + or InvalidOid (zero) on failure. +

lo_import_with_oid is new as of PostgreSQL + 8.4 and uses lo_create internally which is new in 8.1; if this function is run against 8.0 or before, it will + fail and return InvalidOid. +

32.3.3. Exporting a Large Object

To export a large object + into an operating system file, call +

int lo_export(PGconn *conn, Oid lobjId, const char *filename);

+ + The lobjId argument specifies the OID of the large + object to export and the filename argument + specifies the operating system name of the file. Note that the file is + written by the client interface library, not by the server. Returns 1 + on success, -1 on failure. +

32.3.4. Opening an Existing Large Object

To open an existing large object for reading or writing, call +

int lo_open(PGconn *conn, Oid lobjId, int mode);

+ + The lobjId argument specifies the OID of the large + object to open. The mode bits control whether the + object is opened for reading (INV_READ), writing + (INV_WRITE), or both. + (These symbolic constants are defined + in the header file libpq/libpq-fs.h.) + A large object cannot be opened before it is created. + lo_open returns a (non-negative) large object + descriptor for later use in lo_read, + lo_write, lo_lseek, + lo_tell, and lo_close. + The descriptor is only valid for + the duration of the current transaction. + On failure, -1 is returned. +

The server currently does not distinguish between modes + INV_WRITE and INV_READ | + INV_WRITE: you are allowed to read from the descriptor + in either case. However there is a significant difference between + these modes and INV_READ alone: with INV_READ + you cannot write on the descriptor, and the data read from it will + reflect the contents of the large object at the time of the transaction + snapshot that was active when lo_open was executed, + regardless of later writes by this or other transactions. Reading + from a descriptor opened with INV_WRITE returns + data that reflects all writes of other committed transactions as well + as writes of the current transaction. This is similar to the behavior + of REPEATABLE READ versus READ COMMITTED transaction + modes for ordinary SQL SELECT commands. +

An example: +

inv_fd = lo_open(conn, inv_oid, INV_READ|INV_WRITE);

+

32.3.5. Writing Data to a Large Object

The function +

int lo_write(PGconn *conn, int fd, const char *buf, size_t len);

+ writes + len bytes from buf + to large object descriptor fd. The fd + argument must have been returned by a previous + lo_open. The number of bytes actually + written is returned. In the event of an error, the return value + is negative.

32.3.6. Reading Data from a Large Object

The function +

int lo_read(PGconn *conn, int fd, char *buf, size_t len);

+ reads + len bytes from large object descriptor + fd into buf. The + fd argument must have been returned by a + previous lo_open. The number of bytes + actually read is returned. In the event of an error, the return + value is negative.

32.3.7. Seeking in a Large Object

To change the current read or write location associated with a + large object descriptor, call +

int lo_lseek(PGconn *conn, int fd, int offset, int whence);

+ This function moves the + current location pointer for the large object descriptor identified by + fd to the new location specified by + offset. The valid values for whence + are SEEK_SET (seek from object start), + SEEK_CUR (seek from current position), and + SEEK_END (seek from object end). The return value is + the new location pointer, or -1 on error.

32.3.8. Obtaining the Seek Position of a Large Object

To obtain the current read or write location of a large object descriptor, + call +

int lo_tell(PGconn *conn, int fd);

+ If there is an error, the + return value is negative.

32.3.9. Truncating a Large Object

To truncate a large object to a given length, call +

int lo_truncate(PGcon *conn, int fd, size_t len);

+ truncates the large object + descriptor fd to length len. The + fd argument must have been returned by a + previous lo_open. If len is + greater than the current large object length, the large object + is extended with null bytes ('\0').

The file offset is not changed.

On success lo_truncate returns + zero. On error, the return value is negative.

lo_truncate is new as of PostgreSQL + 8.3; if this function is run against an older server version, it will + fail and return a negative value.

32.3.10. Closing a Large Object Descriptor

A large object descriptor can be closed by calling +

int lo_close(PGconn *conn, int fd);

+ where fd is a + large object descriptor returned by lo_open. + On success, lo_close returns zero. On + error, the return value is negative.

Any large object descriptors that remain open at the end of a + transaction will be closed automatically.

32.3.11. Removing a Large Object

To remove a large object from the database, call +

int lo_unlink(PGconn *conn, Oid lobjId);

+ The + lobjId argument specifies the OID of the + large object to remove. Returns 1 if successful, -1 on failure. +


PrevHomeNext
Implementation FeaturesUpServer-side Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/lo-intro.html b/doc/src/sgml/html/lo-intro.html new file mode 100644 index 000000000..cd61e3922 --- /dev/null +++ b/doc/src/sgml/html/lo-intro.html @@ -0,0 +1,194 @@ + +Introduction

32.1. Introduction

All large objects are placed in a single system table called + pg_largeobject. + PostgreSQL also supports a storage system called + "TOAST" that automatically stores values + larger than a single database page into a secondary storage area per table. + This makes the large object facility partially obsolete. One + remaining advantage of the large object facility is that it allows values + up to 2 GB in size, whereas TOASTed fields can be at + most 1 GB. Also, large objects can be randomly modified using a read/write + API that is more efficient than performing such operations using + TOAST. +


PrevHomeNext
Large ObjectsUpImplementation Features
\ No newline at end of file diff --git a/doc/src/sgml/html/lo.html b/doc/src/sgml/html/lo.html new file mode 100644 index 000000000..149459db3 --- /dev/null +++ b/doc/src/sgml/html/lo.html @@ -0,0 +1,358 @@ + +lo
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.20. lo

The lo module provides support for managing Large Objects + (also called LOs or BLOBs). This includes a data type lo + and a trigger lo_manage. +

F.20.1. Rationale

One of the problems with the JDBC driver (and this affects the ODBC driver + also), is that the specification assumes that references to BLOBs (Binary + Large OBjects) are stored within a table, and if that entry is changed, the + associated BLOB is deleted from the database. +

As PostgreSQL stands, this doesn't occur. Large objects + are treated as objects in their own right; a table entry can reference a + large object by OID, but there can be multiple table entries referencing + the same large object OID, so the system doesn't delete the large object + just because you change or remove one such entry. +

Now this is fine for PostgreSQL-specific applications, but + standard code using JDBC or ODBC won't delete the objects, resulting in + orphan objects — objects that are not referenced by anything, and + simply occupy disk space. +

The lo module allows fixing this by attaching a trigger + to tables that contain LO reference columns. The trigger essentially just + does a lo_unlink whenever you delete or modify a value + referencing a large object. When you use this trigger, you are assuming + that there is only one database reference to any large object that is + referenced in a trigger-controlled column! +

The module also provides a data type lo, which is really just + a domain of the oid type. This is useful for differentiating + database columns that hold large object references from those that are + OIDs of other things. You don't have to use the lo type to + use the trigger, but it may be convenient to use it to keep track of which + columns in your database represent large objects that you are managing with + the trigger. It is also rumored that the ODBC driver gets confused if you + don't use lo for BLOB columns. +

F.20.2. How to Use It

Here's a simple example of usage: +

CREATE TABLE image (title TEXT, raster lo);
+
+CREATE TRIGGER t_raster BEFORE UPDATE OR DELETE ON image
+    FOR EACH ROW EXECUTE PROCEDURE lo_manage(raster);

For each column that will contain unique references to large objects, + create a BEFORE UPDATE OR DELETE trigger, and give the column + name as the sole trigger argument. If you need multiple lo + columns in the same table, create a separate trigger for each one, + remembering to give a different name to each trigger on the same table. +

F.20.3. Limitations

  • Dropping a table will still orphan any objects it contains, as the trigger + is not executed. You can avoid this by preceding the DROP + TABLE with DELETE FROM table. +

    TRUNCATE has the same hazard. +

    If you already have, or suspect you have, orphaned large objects, see the + vacuumlo module to help + you clean them up. It's a good idea to run vacuumlo + occasionally as a back-stop to the lo_manage trigger. +

  • Some frontends may create their own tables, and will not create the + associated trigger(s). Also, users may not remember (or know) to create + the triggers. +

\ No newline at end of file diff --git a/doc/src/sgml/html/locale.html b/doc/src/sgml/html/locale.html new file mode 100644 index 000000000..ad8b6040c --- /dev/null +++ b/doc/src/sgml/html/locale.html @@ -0,0 +1,688 @@ + +Locale Support

22.1. Locale Support

Locale support refers to an application respecting + cultural preferences regarding alphabets, sorting, number + formatting, etc. PostgreSQL uses the standard ISO + C and POSIX locale facilities provided by the server operating + system. For additional information refer to the documentation of your + system. +

22.1.1. Overview

Locale support is automatically initialized when a database + cluster is created using initdb. + initdb will initialize the database cluster + with the locale setting of its execution environment by default, + so if your system is already set to use the locale that you want + in your database cluster then there is nothing else you need to + do. If you want to use a different locale (or you are not sure + which locale your system is set to), you can instruct + initdb exactly which locale to use by + specifying the --locale option. For example: +

initdb --locale=sv_SE

+

This example for Unix systems sets the locale to Swedish + (sv) as spoken + in Sweden (SE). Other possibilities might include + en_US (U.S. English) and fr_CA (French + Canadian). If more than one character set can be used for a + locale then the specifications can take the form + language_territory.codeset. For example, + fr_BE.UTF-8 represents the French language (fr) as + spoken in Belgium (BE), with a UTF-8 character set + encoding. +

What locales are available on your + system under what names depends on what was provided by the operating + system vendor and what was installed. On most Unix systems, the command + locale -a will provide a list of available locales. + Windows uses more verbose locale names, such as German_Germany + or Swedish_Sweden.1252, but the principles are the same. +

Occasionally it is useful to mix rules from several locales, e.g., + use English collation rules but Spanish messages. To support that, a + set of locale subcategories exist that control only certain + aspects of the localization rules: + +

LC_COLLATEString sort order
LC_CTYPECharacter classification (What is a letter? Its upper-case equivalent?)
LC_MESSAGESLanguage of messages
LC_MONETARYFormatting of currency amounts
LC_NUMERICFormatting of numbers
LC_TIMEFormatting of dates and times

+ + The category names translate into names of + initdb options to override the locale choice + for a specific category. For instance, to set the locale to + French Canadian, but use U.S. rules for formatting currency, use + initdb --locale=fr_CA --lc-monetary=en_US. +

If you want the system to behave as if it had no locale support, + use the special locale name C, or equivalently + POSIX. +

Some locale categories must have their values + fixed when the database is created. You can use different settings + for different databases, but once a database is created, you cannot + change them for that database anymore. LC_COLLATE + and LC_CTYPE are these categories. They affect + the sort order of indexes, so they must be kept fixed, or indexes on + text columns would become corrupt. + (But you can alleviate this restriction using collations, as discussed + in Section 22.2.) + The default values for these + categories are determined when initdb is run, and + those values are used when new databases are created, unless + specified otherwise in the CREATE DATABASE command. +

The other locale categories can be changed whenever desired + by setting the server configuration parameters + that have the same name as the locale categories (see Section 18.11.2 for details). The values + that are chosen by initdb are actually only written + into the configuration file postgresql.conf to + serve as defaults when the server is started. If you remove these + assignments from postgresql.conf then the + server will inherit the settings from its execution environment. +

Note that the locale behavior of the server is determined by the + environment variables seen by the server, not by the environment + of any client. Therefore, be careful to configure the correct locale settings + before starting the server. A consequence of this is that if + client and server are set up in different locales, messages might + appear in different languages depending on where they originated. +

Note: When we speak of inheriting the locale from the execution + environment, this means the following on most operating systems: + For a given locale category, say the collation, the following + environment variables are consulted in this order until one is + found to be set: LC_ALL, LC_COLLATE + (or the variable corresponding to the respective category), + LANG. If none of these environment variables are + set then the locale defaults to C. +

Some message localization libraries also look at the environment + variable LANGUAGE which overrides all other locale + settings for the purpose of setting the language of messages. If + in doubt, please refer to the documentation of your operating + system, in particular the documentation about + gettext. +

To enable messages to be translated to the user's preferred language, + NLS must have been selected at build time + (configure --enable-nls). All other locale support is + built in automatically. +

22.1.2. Behavior

The locale settings influence the following SQL features: + +

  • Sort order in queries using ORDER BY or the standard + comparison operators on textual data + +

  • The upper, lower, and initcap + functions + + +

  • Pattern matching operators (LIKE, SIMILAR TO, + and POSIX-style regular expressions); locales affect both case + insensitive matching and the classification of characters by + character-class regular expressions + + +

  • The to_char family of functions + +

  • The ability to use indexes with LIKE clauses +

+

The drawback of using locales other than C or + POSIX in PostgreSQL is its performance + impact. It slows character handling and prevents ordinary indexes + from being used by LIKE. For this reason use locales + only if you actually need them. +

As a workaround to allow PostgreSQL to use indexes + with LIKE clauses under a non-C locale, several custom + operator classes exist. These allow the creation of an index that + performs a strict character-by-character comparison, ignoring + locale comparison rules. Refer to Section 11.9 + for more information. Another approach is to create indexes using + the C collation, as discussed in + Section 22.2. +

22.1.3. Problems

If locale support doesn't work according to the explanation above, + check that the locale support in your operating system is + correctly configured. To check what locales are installed on your + system, you can use the command locale -a if + your operating system provides it. +

Check that PostgreSQL is actually using the locale + that you think it is. The LC_COLLATE and LC_CTYPE + settings are determined when a database is created, and cannot be + changed except by creating a new database. Other locale + settings including LC_MESSAGES and LC_MONETARY + are initially determined by the environment the server is started + in, but can be changed on-the-fly. You can check the active locale + settings using the SHOW command. +

The directory src/test/locale in the source + distribution contains a test suite for + PostgreSQL's locale support. +

Client applications that handle server-side errors by parsing the + text of the error message will obviously have problems when the + server's messages are in a different language. Authors of such + applications are advised to make use of the error code scheme + instead. +

Maintaining catalogs of message translations requires the on-going + efforts of many volunteers that want to see + PostgreSQL speak their preferred language well. + If messages in your language are currently not available or not fully + translated, your assistance would be appreciated. If you want to + help, refer to Chapter 48 or write to the developers' + mailing list. +


PrevHomeNext
LocalizationUpCollation Support
\ No newline at end of file diff --git a/doc/src/sgml/html/locking-indexes.html b/doc/src/sgml/html/locking-indexes.html new file mode 100644 index 000000000..8f8aeb78f --- /dev/null +++ b/doc/src/sgml/html/locking-indexes.html @@ -0,0 +1,236 @@ + +Locking and Indexes
PostgreSQL 9.2.2 Documentation
PrevUpChapter 13. Concurrency ControlNext

13.5. Locking and Indexes

Though PostgreSQL + provides nonblocking read/write access to table + data, nonblocking read/write access is not currently offered for every + index access method implemented + in PostgreSQL. + The various index types are handled as follows: + +

B-tree, GiST and SP-GiST indexes

Short-term share/exclusive page-level locks are used for + read/write access. Locks are released immediately after each + index row is fetched or inserted. These index types provide + the highest concurrency without deadlock conditions. +

Hash indexes

Share/exclusive hash-bucket-level locks are used for read/write + access. Locks are released after the whole bucket is processed. + Bucket-level locks provide better concurrency than index-level + ones, but deadlock is possible since the locks are held longer + than one index operation. +

GIN indexes

Short-term share/exclusive page-level locks are used for + read/write access. Locks are released immediately after each + index row is fetched or inserted. But note that insertion of a + GIN-indexed value usually produces several index key insertions + per row, so GIN might do substantial work for a single value's + insertion. +

+

Currently, B-tree indexes offer the best performance for concurrent + applications; since they also have more features than hash + indexes, they are the recommended index type for concurrent + applications that need to index scalar data. When dealing with + non-scalar data, B-trees are not useful, and GiST, SP-GiST or GIN + indexes should be used instead. +


PrevHomeNext
Data Consistency Checks at the Application LevelUpPerformance Tips
\ No newline at end of file diff --git a/doc/src/sgml/html/log-shipping-alternative.html b/doc/src/sgml/html/log-shipping-alternative.html new file mode 100644 index 000000000..6f8786d2c --- /dev/null +++ b/doc/src/sgml/html/log-shipping-alternative.html @@ -0,0 +1,452 @@ + +Alternative Method for Log Shipping
PostgreSQL 9.2.2 Documentation
PrevUpChapter 25. High Availability, Load Balancing, and ReplicationNext

25.4. Alternative Method for Log Shipping

An alternative to the built-in standby mode described in the previous + sections is to use a restore_command that polls the archive location. + This was the only option available in versions 8.4 and below. In this + setup, set standby_mode off, because you are implementing + the polling required for standby operation yourself. See the + pg_standby module for a reference + implementation of this. +

Note that in this mode, the server will apply WAL one file at a + time, so if you use the standby server for queries (see Hot Standby), + there is a delay between an action in the master and when the + action becomes visible in the standby, corresponding the time it takes + to fill up the WAL file. archive_timeout can be used to make that delay + shorter. Also note that you can't combine streaming replication with + this method. +

The operations that occur on both primary and standby servers are + normal continuous archiving and recovery tasks. The only point of + contact between the two database servers is the archive of WAL files + that both share: primary writing to the archive, standby reading from + the archive. Care must be taken to ensure that WAL archives from separate + primary servers do not become mixed together or confused. The archive + need not be large if it is only required for standby operation. +

The magic that makes the two loosely coupled servers work together is + simply a restore_command used on the standby that, + when asked for the next WAL file, waits for it to become available from + the primary. The restore_command is specified in the + recovery.conf file on the standby server. Normal recovery + processing would request a file from the WAL archive, reporting failure + if the file was unavailable. For standby processing it is normal for + the next WAL file to be unavailable, so the standby must wait for + it to appear. For files ending in .backup or + .history there is no need to wait, and a non-zero return + code must be returned. A waiting restore_command can be + written as a custom script that loops after polling for the existence of + the next WAL file. There must also be some way to trigger failover, which + should interrupt the restore_command, break the loop and + return a file-not-found error to the standby server. This ends recovery + and the standby will then come up as a normal server. +

Pseudocode for a suitable restore_command is: +

triggered = false;
+while (!NextWALFileReady() && !triggered)
+{
+    sleep(100000L);         /* wait for ~0.1 sec */
+    if (CheckForExternalTrigger())
+        triggered = true;
+}
+if (!triggered)
+        CopyWALFileForRecovery();

+

A working example of a waiting restore_command is provided + in the pg_standby module. It + should be used as a reference on how to correctly implement the logic + described above. It can also be extended as needed to support specific + configurations and environments. +

The method for triggering failover is an important part of planning + and design. One potential option is the restore_command + command. It is executed once for each WAL file, but the process + running the restore_command is created and dies for + each file, so there is no daemon or server process, and + signals or a signal handler cannot be used. Therefore, the + restore_command is not suitable to trigger failover. + It is possible to use a simple timeout facility, especially if + used in conjunction with a known archive_timeout + setting on the primary. However, this is somewhat error prone + since a network problem or busy primary server might be sufficient + to initiate failover. A notification mechanism such as the explicit + creation of a trigger file is ideal, if this can be arranged. +

25.4.1. Implementation

The short procedure for configuring a standby server using this alternative + method is as follows. For + full details of each step, refer to previous sections as noted. +

  1. Set up primary and standby systems as nearly identical as + possible, including two identical copies of + PostgreSQL at the same release level. +

  2. Set up continuous archiving from the primary to a WAL archive + directory on the standby server. Ensure that + archive_mode, + archive_command and + archive_timeout + are set appropriately on the primary + (see Section 24.3.1). +

  3. Make a base backup of the primary server (see Section 24.3.2), and load this data onto the standby. +

  4. Begin recovery on the standby server from the local WAL + archive, using a recovery.conf that specifies a + restore_command that waits as described + previously (see Section 24.3.4). +

+

Recovery treats the WAL archive as read-only, so once a WAL file has + been copied to the standby system it can be copied to tape at the same + time as it is being read by the standby database server. + Thus, running a standby server for high availability can be performed at + the same time as files are stored for longer term disaster recovery + purposes. +

For testing purposes, it is possible to run both primary and standby + servers on the same system. This does not provide any worthwhile + improvement in server robustness, nor would it be described as HA. +

25.4.2. Record-based Log Shipping

It is also possible to implement record-based log shipping using this + alternative method, though this requires custom development, and changes + will still only become visible to hot standby queries after a full WAL + file has been shipped. +

An external program can call the pg_xlogfile_name_offset() + function (see Section 9.26) + to find out the file name and the exact byte offset within it of + the current end of WAL. It can then access the WAL file directly + and copy the data from the last known end of WAL through the current end + over to the standby servers. With this approach, the window for data + loss is the polling cycle time of the copying program, which can be very + small, and there is no wasted bandwidth from forcing partially-used + segment files to be archived. Note that the standby servers' + restore_command scripts can only deal with whole WAL files, + so the incrementally copied data is not ordinarily made available to + the standby servers. It is of use only when the primary dies — + then the last partial WAL file is fed to the standby before allowing + it to come up. The correct implementation of this process requires + cooperation of the restore_command script with the data + copying program. +

Starting with PostgreSQL version 9.0, you can use + streaming replication (see Section 25.2.5) to + achieve the same benefits with less effort. +


PrevHomeNext
FailoverUpHot Standby
\ No newline at end of file diff --git a/doc/src/sgml/html/logfile-maintenance.html b/doc/src/sgml/html/logfile-maintenance.html new file mode 100644 index 000000000..9e22620b8 --- /dev/null +++ b/doc/src/sgml/html/logfile-maintenance.html @@ -0,0 +1,365 @@ + +Log File Maintenance
PostgreSQL 9.2.2 Documentation
PrevUpChapter 23. Routine Database Maintenance TasksNext

23.3. Log File Maintenance

It is a good idea to save the database server's log output + somewhere, rather than just discarding it via /dev/null. + The log output is invaluable when diagnosing + problems. However, the log output tends to be voluminous + (especially at higher debug levels) so you won't want to save it + indefinitely. You need to rotate the log files so that + new log files are started and old ones removed after a reasonable + period of time. +

If you simply direct the stderr of + postgres into a + file, you will have log output, but + the only way to truncate the log file is to stop and restart + the server. This might be acceptable if you are using + PostgreSQL in a development environment, + but few production servers would find this behavior acceptable. +

A better approach is to send the server's + stderr output to some type of log rotation program. + There is a built-in log rotation facility, which you can use by + setting the configuration parameter logging_collector to + true in postgresql.conf. The control + parameters for this program are described in Section 18.8.1. You can also use this approach + to capture the log data in machine readable CSV + (comma-separated values) format. +

Alternatively, you might prefer to use an external log rotation + program if you have one that you are already using with other + server software. For example, the rotatelogs + tool included in the Apache distribution + can be used with PostgreSQL. To do this, + just pipe the server's + stderr output to the desired program. + If you start the server with + pg_ctl, then stderr + is already redirected to stdout, so you just need a + pipe command, for example: + +

pg_ctl start | rotatelogs /var/log/pgsql_log 86400

+

Another production-grade approach to managing log output is to + send it to syslog and let + syslog deal with file rotation. To do this, set the + configuration parameter log_destination to syslog + (to log to syslog only) in + postgresql.conf. Then you can send a SIGHUP + signal to the syslog daemon whenever you want to force it + to start writing a new log file. If you want to automate log + rotation, the logrotate program can be + configured to work with log files from + syslog. +

On many systems, however, syslog is not very reliable, + particularly with large log messages; it might truncate or drop messages + just when you need them the most. Also, on Linux, + syslog will flush each message to disk, yielding poor + performance. (You can use a "-" at the start of the file name + in the syslog configuration file to disable syncing.) +

Note that all the solutions described above take care of starting new + log files at configurable intervals, but they do not handle deletion + of old, no-longer-useful log files. You will probably want to set + up a batch job to periodically delete old log files. Another possibility + is to configure the rotation program so that old log files are overwritten + cyclically. +

pgFouine + is an external project that does sophisticated log file analysis. + check_postgres + provides Nagios alerts when important messages appear in the log + files, as well as detection of many other extraordinary conditions. +


PrevHomeNext
Routine ReindexingUpBackup and Restore
\ No newline at end of file diff --git a/doc/src/sgml/html/ltree.html b/doc/src/sgml/html/ltree.html new file mode 100644 index 000000000..fde04d61b --- /dev/null +++ b/doc/src/sgml/html/ltree.html @@ -0,0 +1,1947 @@ + +ltree
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.21. ltree

This module implements a data type ltree for representing + labels of data stored in a hierarchical tree-like structure. + Extensive facilities for searching through label trees are provided. +

F.21.1. Definitions

A label is a sequence of alphanumeric characters + and underscores (for example, in C locale the characters + A-Za-z0-9_ are allowed). Labels must be less than 256 bytes + long. +

Examples: 42, Personal_Services +

A label path is a sequence of zero or more + labels separated by dots, for example L1.L2.L3, representing + a path from the root of a hierarchical tree to a particular node. The + length of a label path must be less than 65Kb, but keeping it under 2Kb is + preferable. In practice this is not a major limitation; for example, + the longest label path in the DMOZ catalogue (http://www.dmoz.org) is about 240 bytes. +

Example: Top.Countries.Europe.Russia +

The ltree module provides several data types: +

  • ltree stores a label path. +

  • lquery represents a regular-expression-like pattern + for matching ltree values. A simple word matches that + label within a path. A star symbol (*) matches zero + or more labels. For example: +

    foo         Match the exact label path foo
    +*.foo.*     Match any label path containing the label foo
    +*.foo       Match any label path whose last label is foo

    +

    Star symbols can also be quantified to restrict how many labels + they can match: +

    *{n}        Match exactly n labels
    +*{n,}       Match at least n labels
    +*{n,m}      Match at least n but not more than m labels
    +*{,m}       Match at most m labels — same as  *{0,m}

    +

    There are several modifiers that can be put at the end of a non-star + label in lquery to make it match more than just the exact match: +

    @           Match case-insensitively, for example a@ matches A
    +*           Match any label with this prefix, for example foo* matches foobar
    +%           Match initial underscore-separated words

    + The behavior of % is a bit complicated. It tries to match + words rather than the entire label. For example + foo_bar% matches foo_bar_baz but not + foo_barbaz. If combined with *, prefix + matching applies to each word separately, for example + foo_bar%* matches foo1_bar2_baz but + not foo1_br2_baz. +

    Also, you can write several possibly-modified labels separated with + | (OR) to match any of those labels, and you can put + ! (NOT) at the start to match any label that doesn't + match any of the alternatives. +

    Here's an annotated example of lquery: +

    Top.*{0,2}.sport*@.!football|tennis.Russ*|Spain
    +a.  b.     c.      d.               e.

    + This query will match any label path that: +

    1. begins with the label Top +

    2. and next has zero to two labels before +

    3. a label beginning with the case-insensitive prefix sport +

    4. then a label not matching football nor + tennis +

    5. and then ends with a label beginning with Russ or + exactly matching Spain. +

  • ltxtquery represents a full-text-search-like + pattern for matching ltree values. An + ltxtquery value contains words, possibly with the + modifiers @, *, % at the end; + the modifiers have the same meanings as in lquery. + Words can be combined with & (AND), + | (OR), ! (NOT), and parentheses. + The key difference from + lquery is that ltxtquery matches words without + regard to their position in the label path. +

    Here's an example ltxtquery: +

    Europe & Russia*@ & !Transportation

    + This will match paths that contain the label Europe and + any label beginning with Russia (case-insensitive), + but not paths containing the label Transportation. + The location of these words within the path is not important. + Also, when % is used, the word can be matched to any + underscore-separated word within a label, regardless of position. +

Note: ltxtquery allows whitespace between symbols, but + ltree and lquery do not. +

F.21.2. Operators and Functions

Type ltree has the usual comparison operators + =, <>, + <, >, <=, >=. + Comparison sorts in the order of a tree traversal, with the children + of a node sorted by label text. In addition, the specialized + operators shown in Table F-12 are available. +

Table F-12. ltree Operators

OperatorReturnsDescription
ltree @> ltreebooleanis left argument an ancestor of right (or equal)?
ltree <@ ltreebooleanis left argument a descendant of right (or equal)?
ltree ~ lquerybooleandoes ltree match lquery?
lquery ~ ltreebooleandoes ltree match lquery?
ltree ? lquery[]booleandoes ltree match any lquery in array?
lquery[] ? ltreebooleandoes ltree match any lquery in array?
ltree @ ltxtquerybooleandoes ltree match ltxtquery?
ltxtquery @ ltreebooleandoes ltree match ltxtquery?
ltree || ltreeltreeconcatenate ltree paths
ltree || textltreeconvert text to ltree and concatenate
text || ltreeltreeconvert text to ltree and concatenate
ltree[] @> ltreebooleandoes array contain an ancestor of ltree?
ltree <@ ltree[]booleandoes array contain an ancestor of ltree?
ltree[] <@ ltreebooleandoes array contain a descendant of ltree?
ltree @> ltree[]booleandoes array contain a descendant of ltree?
ltree[] ~ lquerybooleandoes array contain any path matching lquery?
lquery ~ ltree[]booleandoes array contain any path matching lquery?
ltree[] ? lquery[]booleandoes ltree array contain any path matching any lquery?
lquery[] ? ltree[]booleandoes ltree array contain any path matching any lquery?
ltree[] @ ltxtquerybooleandoes array contain any path matching ltxtquery?
ltxtquery @ ltree[]booleandoes array contain any path matching ltxtquery?
ltree[] ?@> ltreeltreefirst array entry that is an ancestor of ltree; NULL if none
ltree[] ?<@ ltreeltreefirst array entry that is a descendant of ltree; NULL if none
ltree[] ?~ lqueryltreefirst array entry that matches lquery; NULL if none
ltree[] ?@ ltxtqueryltreefirst array entry that matches ltxtquery; NULL if none

The operators <@, @>, + @ and ~ have analogues + ^<@, ^@>, ^@, + ^~, which are the same except they do not use + indexes. These are useful only for testing purposes. +

The available functions are shown in Table F-13. +

Table F-13. ltree Functions

FunctionReturn TypeDescriptionExampleResult
subltree(ltree, int start, int end)ltreesubpath of ltree from position start to + position end-1 (counting from 0)subltree('Top.Child1.Child2',1,2)Child1
subpath(ltree, int offset, int len)ltreesubpath of ltree starting at position + offset, length len. + If offset is negative, subpath starts that far from the + end of the path. If len is negative, leaves that many + labels off the end of the path.subpath('Top.Child1.Child2',0,2)Top.Child1
subpath(ltree, int offset)ltreesubpath of ltree starting at position + offset, extending to end of path. + If offset is negative, subpath starts that far from the + end of the path.subpath('Top.Child1.Child2',1)Child1.Child2
nlevel(ltree)integernumber of labels in pathnlevel('Top.Child1.Child2')3
index(ltree a, ltree b)integerposition of first occurrence of b in + a; -1 if not foundindex('0.1.2.3.5.4.5.6.8.5.6.8','5.6')6
index(ltree a, ltree b, int offset)integerposition of first occurrence of b in + a, searching starting at offset; + negative offset means start -offset + labels from the end of the pathindex('0.1.2.3.5.4.5.6.8.5.6.8','5.6',-4)9
text2ltree(text)ltreecast text to ltree
ltree2text(ltree)textcast ltree to text
lca(ltree, ltree, ...)ltreelowest common ancestor, i.e., longest common prefix of paths + (up to 8 arguments supported)lca('1.2.2.3','1.2.3.4.5.6')1.2
lca(ltree[])ltreelowest common ancestor, i.e., longest common prefix of pathslca(array['1.2.2.3'::ltree,'1.2.3'])1.2

F.21.3. Indexes

ltree supports several types of indexes that can speed + up the indicated operators: +

  • B-tree index over ltree: + <, <=, =, + >=, > +

  • GiST index over ltree: + <, <=, =, + >=, >, + @>, <@, + @, ~, ? +

    Example of creating such an index: +

    CREATE INDEX path_gist_idx ON test USING GIST (path);
  • GiST index over ltree[]: + ltree[] <@ ltree, ltree @> ltree[], + @, ~, ? +

    Example of creating such an index: +

    CREATE INDEX path_gist_idx ON test USING GIST (array_path);

    Note: This index type is lossy. +

F.21.4. Example

This example uses the following data (also available in file + contrib/ltree/ltreetest.sql in the source distribution): +

CREATE TABLE test (path ltree);
+INSERT INTO test VALUES ('Top');
+INSERT INTO test VALUES ('Top.Science');
+INSERT INTO test VALUES ('Top.Science.Astronomy');
+INSERT INTO test VALUES ('Top.Science.Astronomy.Astrophysics');
+INSERT INTO test VALUES ('Top.Science.Astronomy.Cosmology');
+INSERT INTO test VALUES ('Top.Hobbies');
+INSERT INTO test VALUES ('Top.Hobbies.Amateurs_Astronomy');
+INSERT INTO test VALUES ('Top.Collections');
+INSERT INTO test VALUES ('Top.Collections.Pictures');
+INSERT INTO test VALUES ('Top.Collections.Pictures.Astronomy');
+INSERT INTO test VALUES ('Top.Collections.Pictures.Astronomy.Stars');
+INSERT INTO test VALUES ('Top.Collections.Pictures.Astronomy.Galaxies');
+INSERT INTO test VALUES ('Top.Collections.Pictures.Astronomy.Astronauts');
+CREATE INDEX path_gist_idx ON test USING gist(path);
+CREATE INDEX path_idx ON test USING btree(path);

Now, we have a table test populated with data describing + the hierarchy shown below: +

                        Top
+                     /   |  \
+             Science Hobbies Collections
+                 /       |              \
+        Astronomy   Amateurs_Astronomy Pictures
+           /  \                            |
+Astrophysics  Cosmology                Astronomy
+                                        /  |    \
+                                 Galaxies Stars Astronauts

We can do inheritance: +

ltreetest=> SELECT path FROM test WHERE path <@ 'Top.Science';
+                path
+------------------------------------
+ Top.Science
+ Top.Science.Astronomy
+ Top.Science.Astronomy.Astrophysics
+ Top.Science.Astronomy.Cosmology
+(4 rows)

+

Here are some examples of path matching: +

ltreetest=> SELECT path FROM test WHERE path ~ '*.Astronomy.*';
+                     path
+-----------------------------------------------
+ Top.Science.Astronomy
+ Top.Science.Astronomy.Astrophysics
+ Top.Science.Astronomy.Cosmology
+ Top.Collections.Pictures.Astronomy
+ Top.Collections.Pictures.Astronomy.Stars
+ Top.Collections.Pictures.Astronomy.Galaxies
+ Top.Collections.Pictures.Astronomy.Astronauts
+(7 rows)
+
+ltreetest=> SELECT path FROM test WHERE path ~ '*.!pictures@.*.Astronomy.*';
+                path
+------------------------------------
+ Top.Science.Astronomy
+ Top.Science.Astronomy.Astrophysics
+ Top.Science.Astronomy.Cosmology
+(3 rows)

+

Here are some examples of full text search: +

ltreetest=> SELECT path FROM test WHERE path @ 'Astro*% & !pictures@';
+                path
+------------------------------------
+ Top.Science.Astronomy
+ Top.Science.Astronomy.Astrophysics
+ Top.Science.Astronomy.Cosmology
+ Top.Hobbies.Amateurs_Astronomy
+(4 rows)
+
+ltreetest=> SELECT path FROM test WHERE path @ 'Astro* & !pictures@';
+                path
+------------------------------------
+ Top.Science.Astronomy
+ Top.Science.Astronomy.Astrophysics
+ Top.Science.Astronomy.Cosmology
+(3 rows)

+

Path construction using functions: +

ltreetest=> SELECT subpath(path,0,2)||'Space'||subpath(path,2) FROM test WHERE path <@ 'Top.Science.Astronomy';
+                 ?column?
+------------------------------------------
+ Top.Science.Space.Astronomy
+ Top.Science.Space.Astronomy.Astrophysics
+ Top.Science.Space.Astronomy.Cosmology
+(3 rows)

+

We could simplify this by creating a SQL function that inserts a label + at a specified position in a path: +

CREATE FUNCTION ins_label(ltree, int, text) RETURNS ltree
+    AS 'select subpath($1,0,$2) || $3 || subpath($1,$2);'
+    LANGUAGE SQL IMMUTABLE;
+
+ltreetest=> SELECT ins_label(path,2,'Space') FROM test WHERE path <@ 'Top.Science.Astronomy';
+                ins_label
+------------------------------------------
+ Top.Science.Space.Astronomy
+ Top.Science.Space.Astronomy.Astrophysics
+ Top.Science.Space.Astronomy.Cosmology
+(3 rows)

+

F.21.5. Authors

All work was done by Teodor Sigaev (<teodor@stack.net>) and + Oleg Bartunov (<oleg@sai.msu.su>). See + http://www.sai.msu.su/~megera/postgres/gist/ for + additional information. Authors would like to thank Eugeny Rodichev for + helpful discussions. Comments and bug reports are welcome. +


PrevHomeNext
loUppageinspect
\ No newline at end of file diff --git a/doc/src/sgml/html/maintenance.html b/doc/src/sgml/html/maintenance.html new file mode 100644 index 000000000..3bdbb95c9 --- /dev/null +++ b/doc/src/sgml/html/maintenance.html @@ -0,0 +1,307 @@ + +Routine Database Maintenance Tasks

Chapter 23. Routine Database Maintenance Tasks

PostgreSQL, like any database software, requires that certain tasks + be performed regularly to achieve optimum performance. The tasks + discussed here are required, but they + are repetitive in nature and can easily be automated using standard + tools such as cron scripts or + Windows' Task Scheduler. It is the database + administrator's responsibility to set up appropriate scripts, and to + check that they execute successfully. +

One obvious maintenance task is the creation of backup copies of the data on a + regular schedule. Without a recent backup, you have no chance of recovery + after a catastrophe (disk failure, fire, mistakenly dropping a critical + table, etc.). The backup and recovery mechanisms available in + PostgreSQL are discussed at length in + Chapter 24. +

The other main category of maintenance task is periodic "vacuuming" + of the database. This activity is discussed in + Section 23.1. Closely related to this is updating + the statistics that will be used by the query planner, as discussed in + Section 23.1.3. +

Another task that might need periodic attention is log file management. + This is discussed in Section 23.3. +

check_postgres + is available for monitoring database health and reporting unusual + conditions. check_postgres integrates with + Nagios and MRTG, but can be run standalone too. +

PostgreSQL is low-maintenance compared + to some other database management systems. Nonetheless, + appropriate attention to these tasks will go far towards ensuring a + pleasant and productive experience with the system. +


PrevHomeNext
Character Set SupportUpRoutine Vacuuming
\ No newline at end of file diff --git a/doc/src/sgml/html/manage-ag-config.html b/doc/src/sgml/html/manage-ag-config.html new file mode 100644 index 000000000..e0cbdd093 --- /dev/null +++ b/doc/src/sgml/html/manage-ag-config.html @@ -0,0 +1,217 @@ + +Database Configuration
PostgreSQL 9.2.2 Documentation
PrevUpChapter 21. Managing DatabasesNext

21.4. Database Configuration

Recall from Chapter 18 that the + PostgreSQL server provides a large number of + run-time configuration variables. You can set database-specific + default values for many of these settings. +

For example, if for some reason you want to disable the + GEQO optimizer for a given database, you'd + ordinarily have to either disable it for all databases or make sure + that every connecting client is careful to issue SET geqo + TO off. To make this setting the default within a particular + database, you can execute the command: +

ALTER DATABASE mydb SET geqo TO off;

+ This will save the setting (but not set it immediately). In + subsequent connections to this database it will appear as though + SET geqo TO off; had been executed just before the + session started. + Note that users can still alter this setting during their sessions; it + will only be the default. To undo any such setting, use + ALTER DATABASE dbname RESET + varname. +


PrevHomeNext
Template DatabasesUpDestroying a Database
\ No newline at end of file diff --git a/doc/src/sgml/html/manage-ag-createdb.html b/doc/src/sgml/html/manage-ag-createdb.html new file mode 100644 index 000000000..3431759a7 --- /dev/null +++ b/doc/src/sgml/html/manage-ag-createdb.html @@ -0,0 +1,367 @@ + +Creating a Database
PostgreSQL 9.2.2 Documentation
PrevUpChapter 21. Managing DatabasesNext

21.2. Creating a Database

In order to create a database, the PostgreSQL + server must be up and running (see Section 17.3). +

Databases are created with the SQL command + CREATE DATABASE: +

CREATE DATABASE name;

+ where name follows the usual rules for + SQL identifiers. The current role automatically + becomes the owner of the new database. It is the privilege of the + owner of a database to remove it later (which also removes all + the objects in it, even if they have a different owner). +

The creation of databases is a restricted operation. See Section 20.2 for how to grant permission. +

Since you need to be connected to the database server in order to + execute the CREATE DATABASE command, the + question remains how the first database at any given + site can be created. The first database is always created by the + initdb command when the data storage area is + initialized. (See Section 17.2.) This + database is called + postgres. So to + create the first "ordinary" database you can connect to + postgres. +

A second database, + template1, + is also created during database cluster initialization. Whenever a + new database is created within the + cluster, template1 is essentially cloned. + This means that any changes you make in template1 are + propagated to all subsequently created databases. Because of this, + avoid creating objects in template1 unless you want them + propagated to every newly created database. More details + appear in Section 21.3. +

As a convenience, there is a program you can + execute from the shell to create new databases, + createdb. + +

createdb dbname

+ + createdb does no magic. It connects to the postgres + database and issues the CREATE DATABASE command, + exactly as described above. + The createdb reference page contains the invocation + details. Note that createdb without any arguments will create + a database with the current user name. +

Note: Chapter 19 contains information about + how to restrict who can connect to a given database. +

Sometimes you want to create a database for someone else, and have him + become the owner of the new database, so he can + configure and manage it himself. To achieve that, use one of the + following commands: +

CREATE DATABASE dbname OWNER rolename;

+ from the SQL environment, or: +

createdb -O rolename dbname

+ from the shell. + Only the superuser is allowed to create a database for + someone else (that is, for a role you are not a member of). +


PrevHomeNext
OverviewUpTemplate Databases
\ No newline at end of file diff --git a/doc/src/sgml/html/manage-ag-dropdb.html b/doc/src/sgml/html/manage-ag-dropdb.html new file mode 100644 index 000000000..4838f63ee --- /dev/null +++ b/doc/src/sgml/html/manage-ag-dropdb.html @@ -0,0 +1,225 @@ + +Destroying a Database
PostgreSQL 9.2.2 Documentation
PrevUpChapter 21. Managing DatabasesNext

21.5. Destroying a Database

Databases are destroyed with the command + DROP DATABASE: +

DROP DATABASE name;

+ Only the owner of the database, or + a superuser, can drop a database. Dropping a database removes all objects + that were + contained within the database. The destruction of a database cannot + be undone. +

You cannot execute the DROP DATABASE command + while connected to the victim database. You can, however, be + connected to any other database, including the template1 + database. + template1 would be the only option for dropping the last user database of a + given cluster. +

For convenience, there is also a shell program to drop + databases, dropdb: +

dropdb dbname

+ (Unlike createdb, it is not the default action to drop + the database with the current user name.) +


PrevHomeNext
Database ConfigurationUpTablespaces
\ No newline at end of file diff --git a/doc/src/sgml/html/manage-ag-overview.html b/doc/src/sgml/html/manage-ag-overview.html new file mode 100644 index 000000000..260e54a1d --- /dev/null +++ b/doc/src/sgml/html/manage-ag-overview.html @@ -0,0 +1,267 @@ + +Overview
PostgreSQL 9.2.2 Documentation
PrevUpChapter 21. Managing DatabasesNext

21.1. Overview

A database is a named collection of SQL objects + ("database objects"). Generally, every database + object (tables, functions, etc.) belongs to one and only one + database. (However there are a few system catalogs, for example + pg_database, that belong to a whole cluster and + are accessible from each database within the cluster.) More + accurately, a database is a collection of schemas and the schemas + contain the tables, functions, etc. So the full hierarchy is: + server, database, schema, table (or some other kind of object, + such as a function). +

When connecting to the database server, a client must specify in + its connection request the name of the database it wants to connect + to. It is not possible to access more than one database per + connection. However, an application is not restricted in the number of + connections it opens to the same or other databases. Databases are + physically separated and access control is managed at the + connection level. If one PostgreSQL server + instance is to house projects or users that should be separate and + for the most part unaware of each other, it is therefore + recommended to put them into separate databases. If the projects + or users are interrelated and should be able to use each other's + resources, they should be put in the same database but possibly + into separate schemas. Schemas are a purely logical structure and who can + access what is managed by the privilege system. More information about + managing schemas is in Section 5.7. +

Databases are created with the CREATE DATABASE command + (see Section 21.2) and destroyed with the + DROP DATABASE command + (see Section 21.5). + To determine the set of existing databases, examine the + pg_database system catalog, for example +

SELECT datname FROM pg_database;

+ The psql program's \l meta-command + and -l command-line option are also useful for listing the + existing databases. +

Note: The SQL standard calls databases "catalogs", but there + is no difference in practice. +


PrevHomeNext
Managing DatabasesUpCreating a Database
\ No newline at end of file diff --git a/doc/src/sgml/html/manage-ag-tablespaces.html b/doc/src/sgml/html/manage-ag-tablespaces.html new file mode 100644 index 000000000..32d8d2c32 --- /dev/null +++ b/doc/src/sgml/html/manage-ag-tablespaces.html @@ -0,0 +1,409 @@ + +Tablespaces
PostgreSQL 9.2.2 Documentation
PrevUpChapter 21. Managing DatabasesNext

21.6. Tablespaces

Tablespaces in PostgreSQL allow database administrators to + define locations in the file system where the files representing + database objects can be stored. Once created, a tablespace can be referred + to by name when creating database objects. +

By using tablespaces, an administrator can control the disk layout + of a PostgreSQL installation. This is useful in at + least two ways. First, if the partition or volume on which the + cluster was initialized runs out of space and cannot be extended, + a tablespace can be created on a different partition and used + until the system can be reconfigured. +

Second, tablespaces allow an administrator to use knowledge of the + usage pattern of database objects to optimize performance. For + example, an index which is very heavily used can be placed on a + very fast, highly available disk, such as an expensive solid state + device. At the same time a table storing archived data which is + rarely used or not performance critical could be stored on a less + expensive, slower disk system. +

To define a tablespace, use the CREATE TABLESPACE + command, for example:: +

CREATE TABLESPACE fastspace LOCATION '/mnt/sda1/postgresql/data';

+ The location must be an existing, empty directory that is owned by + the PostgreSQL operating system user. All objects subsequently + created within the tablespace will be stored in files underneath this + directory. +

Note: There is usually not much point in making more than one + tablespace per logical file system, since you cannot control the location + of individual files within a logical file system. However, + PostgreSQL does not enforce any such limitation, and + indeed it is not directly aware of the file system boundaries on your + system. It just stores files in the directories you tell it to use. +

Creation of the tablespace itself must be done as a database superuser, + but after that you can allow ordinary database users to use it. + To do that, grant them the CREATE privilege on it. +

Tables, indexes, and entire databases can be assigned to + particular tablespaces. To do so, a user with the CREATE + privilege on a given tablespace must pass the tablespace name as a + parameter to the relevant command. For example, the following creates + a table in the tablespace space1: +

CREATE TABLE foo(i int) TABLESPACE space1;

+

Alternatively, use the default_tablespace parameter: +

SET default_tablespace = space1;
+CREATE TABLE foo(i int);

+ When default_tablespace is set to anything but an empty + string, it supplies an implicit TABLESPACE clause for + CREATE TABLE and CREATE INDEX commands that + do not have an explicit one. +

There is also a temp_tablespaces parameter, which + determines the placement of temporary tables and indexes, as well as + temporary files that are used for purposes such as sorting large data + sets. This can be a list of tablespace names, rather than only one, + so that the load associated with temporary objects can be spread over + multiple tablespaces. A random member of the list is picked each time + a temporary object is to be created. +

The tablespace associated with a database is used to store the system + catalogs of that database. Furthermore, it is the default tablespace + used for tables, indexes, and temporary files created within the database, + if no TABLESPACE clause is given and no other selection is + specified by default_tablespace or + temp_tablespaces (as appropriate). + If a database is created without specifying a tablespace for it, + it uses the same tablespace as the template database it is copied from. +

Two tablespaces are automatically created when the database cluster + is initialized. The + pg_global tablespace is used for shared system catalogs. The + pg_default tablespace is the default tablespace of the + template1 and template0 databases (and, therefore, + will be the default tablespace for other databases as well, unless + overridden by a TABLESPACE clause in CREATE + DATABASE). +

Once created, a tablespace can be used from any database, provided + the requesting user has sufficient privilege. This means that a tablespace + cannot be dropped until all objects in all databases using the tablespace + have been removed. +

To remove an empty tablespace, use the DROP TABLESPACE + command. +

To determine the set of existing tablespaces, examine the + pg_tablespace system catalog, for example +

SELECT spcname FROM pg_tablespace;

+ The psql program's \db meta-command + is also useful for listing the existing tablespaces. +

PostgreSQL makes use of symbolic links + to simplify the implementation of tablespaces. This + means that tablespaces can be used only on systems + that support symbolic links. +

The directory $PGDATA/pg_tblspc contains symbolic links that + point to each of the non-built-in tablespaces defined in the cluster. + Although not recommended, it is possible to adjust the tablespace + layout by hand by redefining these links. Two warnings: do not do so + while the server is running; and after you restart the server, + update the pg_tablespace catalog with the new + locations. (If you do not, pg_dump will continue to output + the old tablespace locations.) +


PrevHomeNext
Destroying a DatabaseUpLocalization
\ No newline at end of file diff --git a/doc/src/sgml/html/manage-ag-templatedbs.html b/doc/src/sgml/html/manage-ag-templatedbs.html new file mode 100644 index 000000000..0ca5ced7e --- /dev/null +++ b/doc/src/sgml/html/manage-ag-templatedbs.html @@ -0,0 +1,429 @@ + +Template Databases
PostgreSQL 9.2.2 Documentation
PrevUpChapter 21. Managing DatabasesNext

21.3. Template Databases

CREATE DATABASE actually works by copying an existing + database. By default, it copies the standard system database named + template1. Thus that + database is the "template" from which new databases are + made. If you add objects to template1, these objects + will be copied into subsequently created user databases. This + behavior allows site-local modifications to the standard set of + objects in databases. For example, if you install the procedural + language PL/Perl in template1, it will + automatically be available in user databases without any extra + action being taken when those databases are created. +

There is a second standard system database named + template0. This + database contains the same data as the initial contents of + template1, that is, only the standard objects + predefined by your version of + PostgreSQL. template0 + should never be changed after the database cluster has been + initialized. By instructing + CREATE DATABASE to copy template0 instead + of template1, you can create a "virgin" user + database that contains none of the site-local additions in + template1. This is particularly handy when restoring a + pg_dump dump: the dump script should be restored in a + virgin database to ensure that one recreates the correct contents + of the dumped database, without conflicting with objects that + might have been added to template1 later on. +

Another common reason for copying template0 instead + of template1 is that new encoding and locale settings + can be specified when copying template0, whereas a copy + of template1 must use the same settings it does. + This is because template1 might contain encoding-specific + or locale-specific data, while template0 is known not to. +

To create a database by copying template0, use: +

CREATE DATABASE dbname TEMPLATE template0;

+ from the SQL environment, or: +

createdb -T template0 dbname

+ from the shell. +

It is possible to create additional template databases, and indeed + one can copy any database in a cluster by specifying its name + as the template for CREATE DATABASE. It is important to + understand, however, that this is not (yet) intended as + a general-purpose "COPY DATABASE" facility. + The principal limitation is that no other sessions can be connected to + the source database while it is being copied. CREATE + DATABASE will fail if any other connection exists when it starts; + during the copy operation, new connections to the source database + are prevented. +

Two useful flags exist in pg_database for each + database: the columns datistemplate and + datallowconn. datistemplate + can be set to indicate that a database is intended as a template for + CREATE DATABASE. If this flag is set, the database can be + cloned by any user with CREATEDB privileges; if it is not set, + only superusers and the owner of the database can clone it. + If datallowconn is false, then no new connections + to that database will be allowed (but existing sessions are not terminated + simply by setting the flag false). The template0 + database is normally marked datallowconn = false to prevent its modification. + Both template0 and template1 + should always be marked with datistemplate = true. +

Note: template1 and template0 do not have any special + status beyond the fact that the name template1 is the default + source database name for CREATE DATABASE. + For example, one could drop template1 and recreate it from + template0 without any ill effects. This course of action + might be advisable if one has carelessly added a bunch of junk in + template1. (To delete template1, + it must have pg_database.datistemplate = false.) +

The postgres database is also created when a database + cluster is initialized. This database is meant as a default database for + users and applications to connect to. It is simply a copy of + template1 and can be dropped and recreated if necessary. +


PrevHomeNext
Creating a DatabaseUpDatabase Configuration
\ No newline at end of file diff --git a/doc/src/sgml/html/managing-databases.html b/doc/src/sgml/html/managing-databases.html new file mode 100644 index 000000000..e5a42eeaf --- /dev/null +++ b/doc/src/sgml/html/managing-databases.html @@ -0,0 +1,218 @@ + +Managing Databases

Chapter 21. Managing Databases

Every instance of a running PostgreSQL + server manages one or more databases. Databases are therefore the + topmost hierarchical level for organizing SQL + objects ("database objects"). This chapter describes + the properties of databases, and how to create, manage, and destroy + them. +


PrevHomeNext
Function and Trigger SecurityUpOverview
\ No newline at end of file diff --git a/doc/src/sgml/html/monitoring-locks.html b/doc/src/sgml/html/monitoring-locks.html new file mode 100644 index 000000000..54cbdb22c --- /dev/null +++ b/doc/src/sgml/html/monitoring-locks.html @@ -0,0 +1,221 @@ + +Viewing Locks
PostgreSQL 9.2.2 Documentation
PrevUpChapter 27. Monitoring Database ActivityNext

27.3. Viewing Locks

Another useful tool for monitoring database activity is the + pg_locks system table. It allows the + database administrator to view information about the outstanding + locks in the lock manager. For example, this capability can be used + to: + +

  • View all the locks currently outstanding, all the locks on + relations in a particular database, all the locks on a + particular relation, or all the locks held by a particular + PostgreSQL session. +

  • Determine the relation in the current database with the most + ungranted locks (which might be a source of contention among + database clients). +

  • Determine the effect of lock contention on overall database + performance, as well as the extent to which contention varies + with overall database traffic. +

+ + Details of the pg_locks view appear in + Section 45.58. + For more information on locking and managing concurrency with + PostgreSQL, refer to Chapter 13. +


PrevHomeNext
The Statistics CollectorUpDynamic Tracing
\ No newline at end of file diff --git a/doc/src/sgml/html/monitoring-ps.html b/doc/src/sgml/html/monitoring-ps.html new file mode 100644 index 000000000..df09cb250 --- /dev/null +++ b/doc/src/sgml/html/monitoring-ps.html @@ -0,0 +1,322 @@ + +Standard Unix Tools
PostgreSQL 9.2.2 Documentation
PrevUpChapter 27. Monitoring Database ActivityNext

27.1. Standard Unix Tools

On most Unix platforms, PostgreSQL modifies its + command title as reported by ps, so that individual server + processes can readily be identified. A sample display is + +

$ ps auxww | grep ^postgres
+postgres  15551  0.0  0.1  57536  7132 pts/0    S    18:02   0:00 postgres -i
+postgres  15554  0.0  0.0  57536  1184 ?        Ss   18:02   0:00 postgres: writer process
+postgres  15555  0.0  0.0  57536   916 ?        Ss   18:02   0:00 postgres: checkpointer process
+postgres  15556  0.0  0.0  57536   916 ?        Ss   18:02   0:00 postgres: wal writer process
+postgres  15557  0.0  0.0  58504  2244 ?        Ss   18:02   0:00 postgres: autovacuum launcher process
+postgres  15558  0.0  0.0  17512  1068 ?        Ss   18:02   0:00 postgres: stats collector process
+postgres  15582  0.0  0.0  58772  3080 ?        Ss   18:04   0:00 postgres: joe runbug 127.0.0.1 idle
+postgres  15606  0.0  0.0  58772  3052 ?        Ss   18:07   0:00 postgres: tgl regression [local] SELECT waiting
+postgres  15610  0.0  0.0  58772  3056 ?        Ss   18:07   0:00 postgres: tgl regression [local] idle in transaction

+ + (The appropriate invocation of ps varies across different + platforms, as do the details of what is shown. This example is from a + recent Linux system.) The first process listed here is the + master server process. The command arguments + shown for it are the same ones used when it was launched. The next five + processes are background worker processes automatically launched by the + master process. (The "stats collector" process will not be present + if you have set the system not to start the statistics collector; likewise + the "autovacuum launcher" process can be disabled.) + Each of the remaining + processes is a server process handling one client connection. Each such + process sets its command line display in the form + +

postgres: user database host activity

+ + The user, database, and (client) host items remain the same for + the life of the client connection, but the activity indicator changes. + The activity can be idle (i.e., waiting for a client command), + idle in transaction (waiting for client inside a BEGIN block), + or a command type name such as SELECT. Also, + waiting is appended if the server process is presently waiting + on a lock held by another session. In the above example we can infer + that process 15606 is waiting for process 15610 to complete its transaction + and thereby release some lock. (Process 15610 must be the blocker, because + there is no other active session. In more complicated cases it would be + necessary to look into the + pg_locks + system view to determine who is blocking whom.) +

If you have turned off update_process_title then the + activity indicator is not updated; the process title is set only once + when a new process is launched. On some platforms this saves a measurable + amount of per-command overhead; on others it's insignificant. +

Tip: Solaris requires special handling. You must + use /usr/ucb/ps, rather than + /bin/ps. You also must use two w + flags, not just one. In addition, your original invocation of the + postgres command must have a shorter + ps status display than that provided by each + server process. If you fail to do all three things, the ps + output for each server process will be the original postgres + command line. +


PrevHomeNext
Monitoring Database ActivityUpThe Statistics Collector
\ No newline at end of file diff --git a/doc/src/sgml/html/monitoring-stats.html b/doc/src/sgml/html/monitoring-stats.html new file mode 100644 index 000000000..3bcd1db65 --- /dev/null +++ b/doc/src/sgml/html/monitoring-stats.html @@ -0,0 +1,3765 @@ + +The Statistics Collector
PostgreSQL 9.2.2 Documentation
PrevUpChapter 27. Monitoring Database ActivityNext

27.2. The Statistics Collector

PostgreSQL's statistics collector + is a subsystem that supports collection and reporting of information about + server activity. Presently, the collector can count accesses to tables + and indexes in both disk-block and individual-row terms. It also tracks + the total number of rows in each table, and information about vacuum and + analyze actions for each table. It can also count calls to user-defined + functions and the total time spent in each one. +

PostgreSQL also supports reporting of the exact + command currently being executed by other server processes. This + facility is independent of the collector process. +

27.2.1. Statistics Collection Configuration

Since collection of statistics adds some overhead to query execution, + the system can be configured to collect or not collect information. + This is controlled by configuration parameters that are normally set in + postgresql.conf. (See Chapter 18 for + details about setting configuration parameters.) +

The parameter track_activities enables monitoring + of the current command being executed by any server process. +

The parameter track_counts controls whether + statistics are collected about table and index accesses. +

The parameter track_functions enables tracking of + usage of user-defined functions. +

The parameter track_io_timing enables monitoring + of block read and write times. +

Normally these parameters are set in postgresql.conf so + that they apply to all server processes, but it is possible to turn + them on or off in individual sessions using the SET command. (To prevent + ordinary users from hiding their activity from the administrator, + only superusers are allowed to change these parameters with + SET.) +

The statistics collector transmits the collected information to other + PostgreSQL processes through temporary files. + These files are stored in the directory named by the + stats_temp_directory parameter, + pg_stat_tmp by default. + For better performance, stats_temp_directory can be + pointed at a RAM-based file system, decreasing physical I/O requirements. + When the server shuts down, a permanent copy of the statistics + data is stored in the global subdirectory, so that + statistics can be retained across server restarts. +

27.2.2. Viewing Collected Statistics

Several predefined views, listed in Table 27-1, are available to show the results + of statistics collection. Alternatively, one can + build custom views using the underlying statistics functions, as discussed + in Section 27.2.3. +

When using the statistics to monitor current activity, it is important + to realize that the information does not update instantaneously. + Each individual server process transmits new statistical counts to + the collector just before going idle; so a query or transaction still in + progress does not affect the displayed totals. Also, the collector itself + emits a new report at most once per PGSTAT_STAT_INTERVAL + milliseconds (500 ms unless altered while building the server). So the + displayed information lags behind actual activity. However, current-query + information collected by track_activities is + always up-to-date. +

Another important point is that when a server process is asked to display + any of these statistics, it first fetches the most recent report emitted by + the collector process and then continues to use this snapshot for all + statistical views and functions until the end of its current transaction. + So the statistics will show static information as long as you continue the + current transaction. Similarly, information about the current queries of + all sessions is collected when any such information is first requested + within a transaction, and the same information will be displayed throughout + the transaction. + This is a feature, not a bug, because it allows you to perform several + queries on the statistics and correlate the results without worrying that + the numbers are changing underneath you. But if you want to see new + results with each query, be sure to do the queries outside any transaction + block. Alternatively, you can invoke + pg_stat_clear_snapshot(), which will discard the + current transaction's statistics snapshot (if any). The next use of + statistical information will cause a new snapshot to be fetched. +

A transaction can also see its own statistics (as yet untransmitted to the + collector) in the views pg_stat_xact_all_tables, + pg_stat_xact_sys_tables, + pg_stat_xact_user_tables, and + pg_stat_xact_user_functions. These numbers do not act as + stated above; instead they update continuously throughout the transaction. +

Table 27-1. Standard Statistics Views

View NameDescription
pg_stat_activity + + One row per server process, showing information related to + the current activity of that process, such as state and current query. + See pg_stat_activity for details. +
pg_stat_bgwriterOne row only, showing statistics about the + background writer process's activity. See + pg_stat_bgwriter for details. +
pg_stat_databaseOne row per database, showing database-wide statistics. See + pg_stat_database for details. +
pg_stat_all_tables One row for each table in the current database, showing statistics + about accesses to that specific table. + See pg_stat_all_tables for details. +
pg_stat_sys_tablesSame as pg_stat_all_tables, except that only + system tables are shown.
pg_stat_user_tablesSame as pg_stat_all_tables, except that only user + tables are shown.
pg_stat_xact_all_tablesSimilar to pg_stat_all_tables, but counts actions + taken so far within the current transaction (which are not + yet included in pg_stat_all_tables and related views). + The columns for numbers of live and dead rows and vacuum and + analyze actions are not present in this view.
pg_stat_xact_sys_tablesSame as pg_stat_xact_all_tables, except that only + system tables are shown.
pg_stat_xact_user_tablesSame as pg_stat_xact_all_tables, except that only + user tables are shown.
pg_stat_all_indexes One row for each index in the current database, showing statistics + about accesses to that specific index. + See pg_stat_all_indexes for details. +
pg_stat_sys_indexesSame as pg_stat_all_indexes, except that only + indexes on system tables are shown.
pg_stat_user_indexesSame as pg_stat_all_indexes, except that only + indexes on user tables are shown.
pg_statio_all_tables One row for each table in the current database, showing statistics + about I/O on that specific table. + See pg_statio_all_tables for details. +
pg_statio_sys_tablesSame as pg_statio_all_tables, except that only + system tables are shown.
pg_statio_user_tablesSame as pg_statio_all_tables, except that only + user tables are shown.
pg_statio_all_indexes One row for each index in the current database, + showing statistics about I/O on that specific index. + See pg_statio_all_indexes for details. +
pg_statio_sys_indexesSame as pg_statio_all_indexes, except that only + indexes on system tables are shown.
pg_statio_user_indexesSame as pg_statio_all_indexes, except that only + indexes on user tables are shown.
pg_statio_all_sequences One row for each sequence in the current database, + showing statistics about I/O on that specific sequence. + See pg_statio_all_sequences for details. +
pg_statio_sys_sequencesSame as pg_statio_all_sequences, except that only + system sequences are shown. (Presently, no system sequences are defined, + so this view is always empty.)
pg_statio_user_sequencesSame as pg_statio_all_sequences, except that only + user sequences are shown.
pg_stat_user_functions One row for each tracked function, showing statistics + about executions of that function. See + pg_stat_user_functions for details. +
pg_stat_xact_user_functionsSimilar to pg_stat_user_functions, but counts only + calls during the current transaction (which are not + yet included in pg_stat_user_functions).
pg_stat_replicationOne row per WAL sender process, showing statistics about + replication to that sender's connected standby server. + See pg_stat_replication for details. +
pg_stat_database_conflicts One row per database, showing database-wide statistics about + query cancels due to conflict with recovery on standby servers. + See pg_stat_database_conflicts for details. +

The per-index statistics are particularly useful to determine which + indexes are being used and how effective they are. +

The pg_statio_ views are primarily useful to + determine the effectiveness of the buffer cache. When the number + of actual disk reads is much smaller than the number of buffer + hits, then the cache is satisfying most read requests without + invoking a kernel call. However, these statistics do not give the + entire story: due to the way in which PostgreSQL + handles disk I/O, data that is not in the + PostgreSQL buffer cache might still reside in the + kernel's I/O cache, and might therefore still be fetched without + requiring a physical read. Users interested in obtaining more + detailed information on PostgreSQL I/O behavior are + advised to use the PostgreSQL statistics collector + in combination with operating system utilities that allow insight + into the kernel's handling of I/O. +

Table 27-2. pg_stat_activity View

ColumnTypeDescription
datidoidOID of the database this backend is connected to
datnamenameName of the database this backend is connected to
pidintegerProcess ID of this backend
usesysidoidOID of the user logged into this backend
usenamenameName of the user logged into this backend
application_nametextName of the application that is connected + to this backend
client_addrinetIP address of the client connected to this backend. + If this field is null, it indicates either that the client is + connected via a Unix socket on the server machine or that this is an + internal process such as autovacuum. +
client_hostnametextHost name of the connected client, as reported by a + reverse DNS lookup of client_addr. This field will + only be non-null for IP connections, and only when log_hostname is enabled. +
client_portintegerTCP port number that the client is using for communication + with this backend, or -1 if a Unix socket is used +
backend_starttimestamp with time zoneTime when this process was started, i.e., when the + client connected to the server +
xact_starttimestamp with time zoneTime when this process' current transaction was started, or null + if no transaction is active. If the current + query is the first of its transaction, this column is equal to the + query_start column. +
query_starttimestamp with time zoneTime when the currently active query was started, or if + state is not active, when the last query + was started +
state_changetimestamp with time zoneTime when the state was last changed
waitingbooleanTrue if this backend is currently waiting on a lock
statetextCurrent overall state of this backend. + Possible values are: +

  • active: The backend is executing a query. +

  • idle: The backend is waiting for a new client command. +

  • idle in transaction: The backend is in a transaction, + but is not currently executing a query. +

  • idle in transaction (aborted): This state is similar to + idle in transaction, except one of the statements in + the transaction caused an error. +

  • fastpath function call: The backend is executing a + fast-path function. +

  • disabled: This state is reported if track_activities is disabled in this backend. +

+
querytextText of this backend's most recent query. If + state is active this field shows the + currently executing query. In all other states, it shows the last query + that was executed. +

The pg_stat_activity view will have one row + per server process, showing information related to + the current activity of that process. +

Note: The waiting and state columns are + independent. If a backend is in the active state, + it may or may not be waiting. If the state is + active and waiting is true, it means + that a query is being executed, but is being blocked by a lock + somewhere in the system. +

Table 27-3. pg_stat_bgwriter View

ColumnTypeDescription
checkpoints_timedbigintNumber of scheduled checkpoints that have been performed
checkpoints_reqbigintNumber of requested checkpoints that have been performed
checkpoint_write_timedouble precision Total amount of time that has been spent in the portion of + checkpoint processing where files are written to disk, in milliseconds +
checkpoint_sync_timedouble precision Total amount of time that has been spent in the portion of + checkpoint processing where files are synchronized to disk, in + milliseconds +
buffers_checkpointbigintNumber of buffers written during checkpoints
buffers_cleanbigintNumber of buffers written by the background writer
maxwritten_cleanbigintNumber of times the background writer stopped a cleaning + scan because it had written too many buffers
buffers_backendbigintNumber of buffers written directly by a backend
buffers_backend_fsyncbigintNumber of times a backend had to execute its own + fsync call (normally the background writer handles those + even when the backend does its own write)
buffers_allocbigintNumber of buffers allocated
stats_resettimestamp with time zoneTime at which these statistics were last reset

The pg_stat_bgwriter view will always have a + single row, containing global data for the cluster. +

Table 27-4. pg_stat_database View

ColumnTypeDescription
datidoidOID of a database
datnamenameName of this database
numbackendsintegerNumber of backends currently connected to this database. + This is the only column in this view that returns a value reflecting + current state; all other columns return the accumulated values since + the last reset.
xact_commitbigintNumber of transactions in this database that have been + committed
xact_rollbackbigintNumber of transactions in this database that have been + rolled back
blks_readbigintNumber of disk blocks read in this database
blks_hitbigintNumber of times disk blocks were found already in the buffer + cache, so that a read was not necessary (this only includes hits in the + PostgreSQL buffer cache, not the operating system's file system cache) +
tup_returnedbigintNumber of rows returned by queries in this database
tup_fetchedbigintNumber of rows fetched by queries in this database
tup_insertedbigintNumber of rows inserted by queries in this database
tup_updatedbigintNumber of rows updated by queries in this database
tup_deletedbigintNumber of rows deleted by queries in this database
conflictsbigintNumber of queries canceled due to conflicts with recovery + in this database. (Conflicts occur only on standby servers; see + pg_stat_database_conflicts for details.) +
temp_filesbigintNumber of temporary files created by queries in this database. + All temporary files are counted, regardless of why the temporary file + was created (e.g., sorting or hashing), and regardless of the + log_temp_files setting. +
temp_bytesbigintTotal amount of data written to temporary files by queries in + this database. All temporary files are counted, regardless of why + the temporary file was created, and + regardless of the log_temp_files setting. +
deadlocksbigintNumber of deadlocks detected in this database
blk_read_timedouble precisionTime spent reading data file blocks by backends in this database, + in milliseconds
blk_write_timedouble precisionTime spent writing data file blocks by backends in this database, + in milliseconds
stats_resettimestamp with time zoneTime at which these statistics were last reset

The pg_stat_database view will contain one row + for each database in the cluster, showing database-wide statistics. +

Table 27-5. pg_stat_all_tables View

ColumnTypeDescription
relidoidOID of a table
schemanamenameName of the schema that this table is in
relnamenameName of this table
seq_scanbigintNumber of sequential scans initiated on this table
seq_tup_readbigintNumber of live rows fetched by sequential scans
idx_scanbigintNumber of index scans initiated on this table
idx_tup_fetchbigintNumber of live rows fetched by index scans
n_tup_insbigintNumber of rows inserted
n_tup_updbigintNumber of rows updated
n_tup_delbigintNumber of rows deleted
n_tup_hot_updbigintNumber of rows HOT updated (i.e., with no separate index + update required)
n_live_tupbigintEstimated number of live rows
n_dead_tupbigintEstimated number of dead rows
last_vacuumtimestamp with time zoneLast time at which this table was manually vacuumed + (not counting VACUUM FULL)
last_autovacuumtimestamp with time zoneLast time at which this table was vacuumed by the autovacuum + daemon
last_analyzetimestamp with time zoneLast time at which this table was manually analyzed
last_autoanalyzetimestamp with time zoneLast time at which this table was analyzed by the autovacuum + daemon
vacuum_countbigintNumber of times this table has been manually vacuumed + (not counting VACUUM FULL)
autovacuum_countbigintNumber of times this table has been vacuumed by the autovacuum + daemon
analyze_countbigintNumber of times this table has been manually analyzed
autoanalyze_countbigintNumber of times this table has been analyzed by the autovacuum + daemon

The pg_stat_all_tables view will contain + one row for each table in the current database (including TOAST + tables), showing statistics about accesses to that specific table. The + pg_stat_user_tables and + pg_stat_sys_tables views + contain the same information, + but filtered to only show user and system tables respectively. +

Table 27-6. pg_stat_all_indexes View

ColumnTypeDescription
relidoidOID of the table for this index
indexrelidoidOID of this index
schemanamenameName of the schema this index is in
relnamenameName of the table for this index
indexrelnamenameName of this index
idx_scanbigintNumber of index scans initiated on this index
idx_tup_readbigintNumber of index entries returned by scans on this index
idx_tup_fetchbigintNumber of live table rows fetched by simple index scans using this + index

The pg_stat_all_indexes view will contain + one row for each index in the current database, + showing statistics about accesses to that specific index. The + pg_stat_user_indexes and + pg_stat_sys_indexes views + contain the same information, + but filtered to only show user and system indexes respectively. +

Indexes can be used via either simple index scans or "bitmap" + index scans. In a bitmap scan + the output of several indexes can be combined via AND or OR rules, + so it is difficult to associate individual heap row fetches + with specific indexes when a bitmap scan is used. Therefore, a bitmap + scan increments the + pg_stat_all_indexes.idx_tup_read + count(s) for the index(es) it uses, and it increments the + pg_stat_all_tables.idx_tup_fetch + count for the table, but it does not affect + pg_stat_all_indexes.idx_tup_fetch. +

Note: The idx_tup_read and idx_tup_fetch counts + can be different even without any use of bitmap scans, + because idx_tup_read counts + index entries retrieved from the index while idx_tup_fetch + counts live rows fetched from the table. The latter will be less if any + dead or not-yet-committed rows are fetched using the index, or if any + heap fetches are avoided by means of an index-only scan. +

Table 27-7. pg_statio_all_tables View

ColumnTypeDescription
relidoidOID of a table
schemanamenameName of the schema that this table is in
relnamenameName of this table
heap_blks_readbigintNumber of disk blocks read from this table
heap_blks_hitbigintNumber of buffer hits in this table
idx_blks_readbigintNumber of disk blocks read from all indexes on this table
idx_blks_hitbigintNumber of buffer hits in all indexes on this table
toast_blks_readbigintNumber of disk blocks read from this table's TOAST table (if any)
toast_blks_hitbigintNumber of buffer hits in this table's TOAST table (if any)
tidx_blks_readbigintNumber of disk blocks read from this table's TOAST table index (if any)
tidx_blks_hitbigintNumber of buffer hits in this table's TOAST table index (if any)

The pg_statio_all_tables view will contain + one row for each table in the current database (including TOAST + tables), showing statistics about I/O on that specific table. The + pg_statio_user_tables and + pg_statio_sys_tables views + contain the same information, + but filtered to only show user and system tables respectively. +

Table 27-8. pg_statio_all_indexes View

ColumnTypeDescription
relidoidOID of the table for this index
indexrelidoidOID of this index
schemanamenameName of the schema this index is in
relnamenameName of the table for this index
indexrelnamenameName of this index
idx_blks_readbigintNumber of disk blocks read from this index
idx_blks_hitbigintNumber of buffer hits in this index

The pg_statio_all_indexes view will contain + one row for each index in the current database, + showing statistics about I/O on that specific index. The + pg_statio_user_indexes and + pg_statio_sys_indexes views + contain the same information, + but filtered to only show user and system indexes respectively. +

Table 27-9. pg_statio_all_sequences View

ColumnTypeDescription
relidoidOID of a sequence
schemanamenameName of the schema this sequence is in
relnamenameName of this sequence
blks_readbigintNumber of disk blocks read from this sequence
blks_hitbigintNumber of buffer hits in this sequence

The pg_statio_all_sequences view will contain + one row for each sequence in the current database, + showing statistics about I/O on that specific sequence. +

Table 27-10. pg_stat_user_functions View

ColumnTypeDescription
funcidoidOID of a function
schemanamenameName of the schema this function is in
funcnamenameName of this function
callsbigintNumber of times this function has been called
total_timedouble precisionTotal time spent in this function and all other functions + called by it, in milliseconds
self_timedouble precisionTotal time spent in this function itself, not including + other functions called by it, in milliseconds

The pg_stat_user_functions view will contain + one row for each tracked function, showing statistics about executions of + that function. The track_functions parameter + controls exactly which functions are tracked. +

Table 27-11. pg_stat_replication View

ColumnTypeDescription
pidintegerProcess ID of a WAL sender process
usesysidoidOID of the user logged into this WAL sender process
usenamenameName of the user logged into this WAL sender process
application_nametextName of the application that is connected + to this WAL sender
client_addrinetIP address of the client connected to this WAL sender. + If this field is null, it indicates that the client is + connected via a Unix socket on the server machine. +
client_hostnametextHost name of the connected client, as reported by a + reverse DNS lookup of client_addr. This field will + only be non-null for IP connections, and only when log_hostname is enabled. +
client_portintegerTCP port number that the client is using for communication + with this WAL sender, or -1 if a Unix socket is used +
backend_starttimestamp with time zoneTime when this process was started, i.e., when the + client connected to this WAL sender +
statetextCurrent WAL sender state
sent_locationtextLast transaction log position sent on this connection
write_locationtextLast transaction log position written to disk by this standby + server
flush_locationtextLast transaction log position flushed to disk by this standby + server
replay_locationtextLast transaction log position replayed into the database on this + standby server
sync_priorityintegerPriority of this standby server for being chosen as the + synchronous standby
sync_statetextSynchronous state of this standby server

The pg_stat_replication view will contain one row + per WAL sender process, showing statistics about replication to that + sender's connected standby server. Only directly connected standbys are + listed; no information is available about downstream standby servers. +

Table 27-12. pg_stat_database_conflicts View

ColumnTypeDescription
datidoidOID of a database
datnamenameName of this database
confl_tablespacebigintNumber of queries in this database that have been canceled due to + dropped tablespaces
confl_lockbigintNumber of queries in this database that have been canceled due to + lock timeouts
confl_snapshotbigintNumber of queries in this database that have been canceled due to + old snapshots
confl_bufferpinbigintNumber of queries in this database that have been canceled due to + pinned buffers
confl_deadlockbigintNumber of queries in this database that have been canceled due to + deadlocks

The pg_stat_database_conflicts view will contain + one row per database, showing database-wide statistics about + query cancels occurring due to conflicts with recovery on standby servers. + This view will only contain information on standby servers, since + conflicts do not occur on master servers. +

27.2.3. Statistics Functions

Other ways of looking at the statistics can be set up by writing + queries that use the same underlying statistics access functions used by + the standard views shown above. For details such as the functions' names, + consult the definitions of the standard views. (For example, in + psql you could issue \d+ pg_stat_activity.) + The access functions for per-database statistics take a database OID as an + argument to identify which database to report on. + The per-table and per-index functions take a table or index OID. + The functions for per-function statistics take a function OID. + Note that only tables, indexes, and functions in the current database + can be seen with these functions. +

Additional functions related to statistics collection are listed in Table 27-13. +

Table 27-13. Additional Statistics Functions

FunctionReturn TypeDescription
pg_backend_pid()integer Process ID of the server process handling the current session +
pg_stat_get_activity(integer)setof record Returns a record of information about the backend with the specified PID, or + one record for each active backend in the system if NULL is + specified. The fields returned are a subset of those in the + pg_stat_activity view. +
pg_stat_clear_snapshot()void Discard the current statistics snapshot +
pg_stat_reset()void Reset all statistics counters for the current database to zero + (requires superuser privileges) +
pg_stat_reset_shared(text)void Reset some cluster-wide statistics counters to zero, depending on the + argument (requires superuser privileges). + Calling pg_stat_reset_shared('bgwriter') will zero all the + counters shown in the pg_stat_bgwriter view. +
pg_stat_reset_single_table_counters(oid)void Reset statistics for a single table or index in the current database to + zero (requires superuser privileges) +
pg_stat_reset_single_function_counters(oid)void Reset statistics for a single function in the current database to + zero (requires superuser privileges) +

pg_stat_get_activity, the underlying function of + the pg_stat_activity view, returns a set of records + containing all the available information about each backend process. + Sometimes it may be more convenient to obtain just a subset of this + information. In such cases, an older set of per-backend statistics + access functions can be used; these are shown in Table 27-14. + These access functions use a backend ID number, which ranges from one + to the number of currently active backends. + The function pg_stat_get_backend_idset provides a + convenient way to generate one row for each active backend for + invoking these functions. For example, to show the PIDs and + current queries of all backends: + +

SELECT pg_stat_get_backend_pid(s.backendid) AS pid,
+       pg_stat_get_backend_activity(s.backendid) AS query
+    FROM (SELECT pg_stat_get_backend_idset() AS backendid) AS s;

+

Table 27-14. Per-Backend Statistics Functions

FunctionReturn TypeDescription
pg_stat_get_backend_idset()setof integerSet of currently active backend ID numbers (from 1 to the + number of active backends)
pg_stat_get_backend_activity(integer)textText of this backend's most recent query
pg_stat_get_backend_activity_start(integer)timestamp with time zoneTime when the most recent query was started
pg_stat_get_backend_client_addr(integer)inetIP address of the client connected to this backend
pg_stat_get_backend_client_port(integer)integerTCP port number that the client is using for communication
pg_stat_get_backend_dbid(integer)oidOID of the database this backend is connected to
pg_stat_get_backend_pid(integer)integerProcess ID of this backend
pg_stat_get_backend_start(integer)timestamp with time zoneTime when this process was started
pg_stat_get_backend_userid(integer)oidOID of the user logged into this backend
pg_stat_get_backend_waiting(integer)booleanTrue if this backend is currently waiting on a lock
pg_stat_get_backend_xact_start(integer)timestamp with time zoneTime when the current transaction was started

PrevHomeNext
Standard Unix ToolsUpViewing Locks
\ No newline at end of file diff --git a/doc/src/sgml/html/monitoring.html b/doc/src/sgml/html/monitoring.html new file mode 100644 index 000000000..3c9da3a8e --- /dev/null +++ b/doc/src/sgml/html/monitoring.html @@ -0,0 +1,282 @@ + +Monitoring Database Activity

Chapter 27. Monitoring Database Activity

A database administrator frequently wonders, "What is the system + doing right now?" + This chapter discusses how to find that out. +

Several tools are available for monitoring database activity and + analyzing performance. Most of this chapter is devoted to describing + PostgreSQL's statistics collector, + but one should not neglect regular Unix monitoring programs such as + ps, top, iostat, and vmstat. + Also, once one has identified a + poorly-performing query, further investigation might be needed using + PostgreSQL's EXPLAIN command. + Section 14.1 discusses EXPLAIN + and other methods for understanding the behavior of an individual + query. +


PrevHomeNext
Standby Server SettingsUpStandard Unix Tools
\ No newline at end of file diff --git a/doc/src/sgml/html/multibyte.html b/doc/src/sgml/html/multibyte.html new file mode 100644 index 000000000..1c14f2d19 --- /dev/null +++ b/doc/src/sgml/html/multibyte.html @@ -0,0 +1,2578 @@ + +Character Set Support

22.3. Character Set Support

The character set support in PostgreSQL + allows you to store text in a variety of character sets (also called + encodings), including + single-byte character sets such as the ISO 8859 series and + multiple-byte character sets such as EUC (Extended Unix + Code), UTF-8, and Mule internal code. All supported character sets + can be used transparently by clients, but a few are not supported + for use within the server (that is, as a server-side encoding). + The default character set is selected while + initializing your PostgreSQL database + cluster using initdb. It can be overridden when you + create a database, so you can have multiple + databases each with a different character set. +

An important restriction, however, is that each database's character set + must be compatible with the database's LC_CTYPE (character + classification) and LC_COLLATE (string sort order) locale + settings. For C or + POSIX locale, any character set is allowed, but for other + locales there is only one character set that will work correctly. + (On Windows, however, UTF-8 encoding can be used with any locale.) +

22.3.1. Supported Character Sets

Table 22-1 shows the character sets available + for use in PostgreSQL. +

Table 22-1. PostgreSQL Character Sets

NameDescriptionLanguageServer?Bytes/CharAliases
BIG5Big FiveTraditional ChineseNo1-2WIN950, Windows950
EUC_CNExtended UNIX Code-CNSimplified ChineseYes1-3 
EUC_JPExtended UNIX Code-JPJapaneseYes1-3 
EUC_JIS_2004Extended UNIX Code-JP, JIS X 0213JapaneseYes1-3 
EUC_KRExtended UNIX Code-KRKoreanYes1-3 
EUC_TWExtended UNIX Code-TWTraditional Chinese, TaiwaneseYes1-3 
GB18030National StandardChineseNo1-2 
GBKExtended National StandardSimplified ChineseNo1-2WIN936, Windows936
ISO_8859_5ISO 8859-5, ECMA 113Latin/CyrillicYes1 
ISO_8859_6ISO 8859-6, ECMA 114Latin/ArabicYes1 
ISO_8859_7ISO 8859-7, ECMA 118Latin/GreekYes1 
ISO_8859_8ISO 8859-8, ECMA 121Latin/HebrewYes1 
JOHABJOHABKorean (Hangul)No1-3 
KOI8RKOI8-RCyrillic (Russian)Yes1KOI8
KOI8UKOI8-UCyrillic (Ukrainian)Yes1 
LATIN1ISO 8859-1, ECMA 94Western EuropeanYes1ISO88591
LATIN2ISO 8859-2, ECMA 94Central EuropeanYes1ISO88592
LATIN3ISO 8859-3, ECMA 94South EuropeanYes1ISO88593
LATIN4ISO 8859-4, ECMA 94North EuropeanYes1ISO88594
LATIN5ISO 8859-9, ECMA 128TurkishYes1ISO88599
LATIN6ISO 8859-10, ECMA 144NordicYes1ISO885910
LATIN7ISO 8859-13BalticYes1ISO885913
LATIN8ISO 8859-14CelticYes1ISO885914
LATIN9ISO 8859-15LATIN1 with Euro and accentsYes1ISO885915
LATIN10ISO 8859-16, ASRO SR 14111RomanianYes1ISO885916
MULE_INTERNALMule internal codeMultilingual EmacsYes1-4 
SJISShift JISJapaneseNo1-2Mskanji, ShiftJIS, WIN932, Windows932
SHIFT_JIS_2004Shift JIS, JIS X 0213JapaneseNo1-2 
SQL_ASCIIunspecified (see text)anyYes1 
UHCUnified Hangul CodeKoreanNo1-2WIN949, Windows949
UTF8Unicode, 8-bitallYes1-4Unicode
WIN866Windows CP866CyrillicYes1ALT
WIN874Windows CP874ThaiYes1 
WIN1250Windows CP1250Central EuropeanYes1 
WIN1251Windows CP1251CyrillicYes1WIN
WIN1252Windows CP1252Western EuropeanYes1 
WIN1253Windows CP1253GreekYes1 
WIN1254Windows CP1254TurkishYes1 
WIN1255Windows CP1255HebrewYes1 
WIN1256Windows CP1256ArabicYes1 
WIN1257Windows CP1257BalticYes1 
WIN1258Windows CP1258VietnameseYes1ABC, TCVN, TCVN5712, VSCII

Not all client APIs support all the listed character sets. For example, the + PostgreSQL + JDBC driver does not support MULE_INTERNAL, LATIN6, + LATIN8, and LATIN10. +

The SQL_ASCII setting behaves considerably differently + from the other settings. When the server character set is + SQL_ASCII, the server interprets byte values 0-127 + according to the ASCII standard, while byte values 128-255 are taken + as uninterpreted characters. No encoding conversion will be done when + the setting is SQL_ASCII. Thus, this setting is not so + much a declaration that a specific encoding is in use, as a declaration + of ignorance about the encoding. In most cases, if you are + working with any non-ASCII data, it is unwise to use the + SQL_ASCII setting because + PostgreSQL will be unable to help you by + converting or validating non-ASCII characters. +

22.3.2. Setting the Character Set

initdb defines the default character set (encoding) + for a PostgreSQL cluster. For example, + +

initdb -E EUC_JP

+ + sets the default character set to + EUC_JP (Extended Unix Code for Japanese). You + can use --encoding instead of + -E if you prefer longer option strings. + If no -E or --encoding option is + given, initdb attempts to determine the appropriate + encoding to use based on the specified or default locale. +

You can specify a non-default encoding at database creation time, + provided that the encoding is compatible with the selected locale: + +

createdb -E EUC_KR -T template0 --lc-collate=ko_KR.euckr --lc-ctype=ko_KR.euckr korean

+ + This will create a database named korean that + uses the character set EUC_KR, and locale ko_KR. + Another way to accomplish this is to use this SQL command: + +

CREATE DATABASE korean WITH ENCODING 'EUC_KR' LC_COLLATE='ko_KR.euckr' LC_CTYPE='ko_KR.euckr' TEMPLATE=template0;

+ + Notice that the above commands specify copying the template0 + database. When copying any other database, the encoding and locale + settings cannot be changed from those of the source database, because + that might result in corrupt data. For more information see + Section 21.3. +

The encoding for a database is stored in the system catalog + pg_database. You can see it by using the + psql -l option or the + \l command. + +

$ psql -l
+                                         List of databases
+   Name    |  Owner   | Encoding  |  Collation  |    Ctype    |          Access Privileges          
+-----------+----------+-----------+-------------+-------------+-------------------------------------
+ clocaledb | hlinnaka | SQL_ASCII | C           | C           | 
+ englishdb | hlinnaka | UTF8      | en_GB.UTF8  | en_GB.UTF8  | 
+ japanese  | hlinnaka | UTF8      | ja_JP.UTF8  | ja_JP.UTF8  | 
+ korean    | hlinnaka | EUC_KR    | ko_KR.euckr | ko_KR.euckr | 
+ postgres  | hlinnaka | UTF8      | fi_FI.UTF8  | fi_FI.UTF8  | 
+ template0 | hlinnaka | UTF8      | fi_FI.UTF8  | fi_FI.UTF8  | {=c/hlinnaka,hlinnaka=CTc/hlinnaka}
+ template1 | hlinnaka | UTF8      | fi_FI.UTF8  | fi_FI.UTF8  | {=c/hlinnaka,hlinnaka=CTc/hlinnaka}
+(7 rows)

+

Important: On most modern operating systems, PostgreSQL + can determine which character set is implied by the LC_CTYPE + setting, and it will enforce that only the matching database encoding is + used. On older systems it is your responsibility to ensure that you use + the encoding expected by the locale you have selected. A mistake in + this area is likely to lead to strange behavior of locale-dependent + operations such as sorting. +

PostgreSQL will allow superusers to create + databases with SQL_ASCII encoding even when + LC_CTYPE is not C or POSIX. As noted + above, SQL_ASCII does not enforce that the data stored in + the database has any particular encoding, and so this choice poses risks + of locale-dependent misbehavior. Using this combination of settings is + deprecated and may someday be forbidden altogether. +

22.3.3. Automatic Character Set Conversion Between Server and Client

PostgreSQL supports automatic + character set conversion between server and client for certain + character set combinations. The conversion information is stored in the + pg_conversion system catalog. PostgreSQL + comes with some predefined conversions, as shown in Table 22-2. You can create a new + conversion using the SQL command CREATE CONVERSION. +

Table 22-2. Client/Server Character Set Conversions

Server Character SetAvailable Client Character Sets
BIG5not supported as a server encoding +
EUC_CNEUC_CN, + MULE_INTERNAL, + UTF8 +
EUC_JPEUC_JP, + MULE_INTERNAL, + SJIS, + UTF8 +
EUC_KREUC_KR, + MULE_INTERNAL, + UTF8 +
EUC_TWEUC_TW, + BIG5, + MULE_INTERNAL, + UTF8 +
GB18030not supported as a server encoding +
GBKnot supported as a server encoding +
ISO_8859_5ISO_8859_5, + KOI8R, + MULE_INTERNAL, + UTF8, + WIN866, + WIN1251 +
ISO_8859_6ISO_8859_6, + UTF8 +
ISO_8859_7ISO_8859_7, + UTF8 +
ISO_8859_8ISO_8859_8, + UTF8 +
JOHABJOHAB, + UTF8 +
KOI8RKOI8R, + ISO_8859_5, + MULE_INTERNAL, + UTF8, + WIN866, + WIN1251 +
KOI8UKOI8U, + UTF8 +
LATIN1LATIN1, + MULE_INTERNAL, + UTF8 +
LATIN2LATIN2, + MULE_INTERNAL, + UTF8, + WIN1250 +
LATIN3LATIN3, + MULE_INTERNAL, + UTF8 +
LATIN4LATIN4, + MULE_INTERNAL, + UTF8 +
LATIN5LATIN5, + UTF8 +
LATIN6LATIN6, + UTF8 +
LATIN7LATIN7, + UTF8 +
LATIN8LATIN8, + UTF8 +
LATIN9LATIN9, + UTF8 +
LATIN10LATIN10, + UTF8 +
MULE_INTERNALMULE_INTERNAL, + BIG5, + EUC_CN, + EUC_JP, + EUC_KR, + EUC_TW, + ISO_8859_5, + KOI8R, + LATIN1 to LATIN4, + SJIS, + WIN866, + WIN1250, + WIN1251 +
SJISnot supported as a server encoding +
SQL_ASCIIany (no conversion will be performed) +
UHCnot supported as a server encoding +
UTF8all supported encodings +
WIN866WIN866, + ISO_8859_5, + KOI8R, + MULE_INTERNAL, + UTF8, + WIN1251 +
WIN874WIN874, + UTF8 +
WIN1250WIN1250, + LATIN2, + MULE_INTERNAL, + UTF8 +
WIN1251WIN1251, + ISO_8859_5, + KOI8R, + MULE_INTERNAL, + UTF8, + WIN866 +
WIN1252WIN1252, + UTF8 +
WIN1253WIN1253, + UTF8 +
WIN1254WIN1254, + UTF8 +
WIN1255WIN1255, + UTF8 +
WIN1256WIN1256, + UTF8 +
WIN1257WIN1257, + UTF8 +
WIN1258WIN1258, + UTF8 +

To enable automatic character set conversion, you have to + tell PostgreSQL the character set + (encoding) you would like to use in the client. There are several + ways to accomplish this: + +

  • Using the \encoding command in + psql. + \encoding allows you to change client + encoding on the fly. For + example, to change the encoding to SJIS, type: + +

    \encoding SJIS

    +

  • libpq (Section 31.10) has functions to control the client encoding. +

  • Using SET client_encoding TO. + + Setting the client encoding can be done with this SQL command: + +

    SET CLIENT_ENCODING TO 'value';

    + + Also you can use the standard SQL syntax SET NAMES + for this purpose: + +

    SET NAMES 'value';

    + + To query the current client encoding: + +

    SHOW client_encoding;

    + + To return to the default encoding: + +

    RESET client_encoding;

    +

  • Using PGCLIENTENCODING. If the environment variable + PGCLIENTENCODING is defined in the client's + environment, that client encoding is automatically selected + when a connection to the server is made. (This can + subsequently be overridden using any of the other methods + mentioned above.) +

  • Using the configuration variable client_encoding. If the + client_encoding variable is set, that client + encoding is automatically selected when a connection to the + server is made. (This can subsequently be overridden using any + of the other methods mentioned above.) +

+

If the conversion of a particular character is not possible + — suppose you chose EUC_JP for the + server and LATIN1 for the client, and some + Japanese characters are returned that do not have a representation in + LATIN1 — an error is reported. +

If the client character set is defined as SQL_ASCII, + encoding conversion is disabled, regardless of the server's character + set. Just as for the server, use of SQL_ASCII is unwise + unless you are working with all-ASCII data. +

22.3.4. Further Reading

These are good sources to start learning about various kinds of encoding + systems. + +

http://www.i18ngurus.com/docs/984813247.html

An extensive collection of documents about character sets, encodings, + and code pages. +

CJKV Information Processing: Chinese, Japanese, Korean & Vietnamese Computing

Contains detailed explanations of EUC_JP, + EUC_CN, EUC_KR, + EUC_TW. +

http://www.unicode.org/

The web site of the Unicode Consortium. +

RFC 3629

UTF-8 (8-bit UCS/Unicode Transformation + Format) is defined here. +

+


PrevHomeNext
Collation SupportUpRoutine Database Maintenance Tasks
\ No newline at end of file diff --git a/doc/src/sgml/html/mvcc-intro.html b/doc/src/sgml/html/mvcc-intro.html new file mode 100644 index 000000000..b4200ac67 --- /dev/null +++ b/doc/src/sgml/html/mvcc-intro.html @@ -0,0 +1,237 @@ + +Introduction
PostgreSQL 9.2.2 Documentation
PrevUpChapter 13. Concurrency ControlNext

13.1. Introduction

PostgreSQL provides a rich set of tools + for developers to manage concurrent access to data. Internally, + data consistency is maintained by using a multiversion + model (Multiversion Concurrency Control, MVCC). + This means that while querying a database each transaction sees + a snapshot of data (a database version) + as it was some + time ago, regardless of the current state of the underlying data. + This protects the transaction from viewing inconsistent data that + could be caused by (other) concurrent transaction updates on the same + data rows, providing transaction isolation + for each database session. MVCC, by eschewing + the locking methodologies of traditional database systems, + minimizes lock contention in order to allow for reasonable + performance in multiuser environments. +

The main advantage of using the MVCC model of + concurrency control rather than locking is that in + MVCC locks acquired for querying (reading) data + do not conflict with locks acquired for writing data, and so + reading never blocks writing and writing never blocks reading. + PostgreSQL maintains this guarantee + even when providing the strictest level of transaction + isolation through the use of an innovative Serializable + Snapshot Isolation (SSI) level. +

Table- and row-level locking facilities are also available in + PostgreSQL for applications which don't + generally need full transaction isolation and prefer to explicitly + manage particular points of conflict. However, proper + use of MVCC will generally provide better + performance than locks. In addition, application-defined advisory + locks provide a mechanism for acquiring locks that are not tied + to a single transaction. +


PrevHomeNext
Concurrency ControlUpTransaction Isolation
\ No newline at end of file diff --git a/doc/src/sgml/html/mvcc.html b/doc/src/sgml/html/mvcc.html new file mode 100644 index 000000000..43607c132 --- /dev/null +++ b/doc/src/sgml/html/mvcc.html @@ -0,0 +1,265 @@ + +Concurrency Control

Chapter 13. Concurrency Control

This chapter describes the behavior of the + PostgreSQL database system when two or + more sessions try to access the same data at the same time. The + goals in that situation are to allow efficient access for all + sessions while maintaining strict data integrity. Every developer + of database applications should be familiar with the topics covered + in this chapter. +


PrevHomeNext
Migration from Pre-8.3 Text SearchUpIntroduction
\ No newline at end of file diff --git a/doc/src/sgml/html/nls-programmer.html b/doc/src/sgml/html/nls-programmer.html new file mode 100644 index 000000000..8e4095928 --- /dev/null +++ b/doc/src/sgml/html/nls-programmer.html @@ -0,0 +1,508 @@ + +For the Programmer
PostgreSQL 9.2.2 Documentation
PrevUpChapter 48. Native Language SupportNext

48.2. For the Programmer

48.2.1. Mechanics

This section describes how to implement native language support in a + program or library that is part of the + PostgreSQL distribution. + Currently, it only applies to C programs. +

Adding NLS Support to a Program

  1. Insert this code into the start-up sequence of the program: +

    #ifdef ENABLE_NLS
    +#include <locale.h>
    +#endif
    +
    +...
    +
    +#ifdef ENABLE_NLS
    +setlocale(LC_ALL, "");
    +bindtextdomain("progname", LOCALEDIR);
    +textdomain("progname");
    +#endif

    + (The progname can actually be chosen + freely.) +

  2. Wherever a message that is a candidate for translation is found, + a call to gettext() needs to be inserted. E.g.: +

    fprintf(stderr, "panic level %d\n", lvl);

    + would be changed to: +

    fprintf(stderr, gettext("panic level %d\n"), lvl);

    + (gettext is defined as a no-op if NLS support is + not configured.) +

    This tends to add a lot of clutter. One common shortcut is to use: +

    #define _(x) gettext(x)

    + Another solution is feasible if the program does much of its + communication through one or a few functions, such as + ereport() in the backend. Then you make this + function call gettext internally on all + input strings. +

  3. Add a file nls.mk in the directory with the + program sources. This file will be read as a makefile. The + following variable assignments need to be made here: + +

    CATALOG_NAME

    The program name, as provided in the + textdomain() call. +

    AVAIL_LANGUAGES

    List of provided translations — initially empty. +

    GETTEXT_FILES

    List of files that contain translatable strings, i.e., those + marked with gettext or an alternative + solution. Eventually, this will include nearly all source + files of the program. If this list gets too long you can + make the first "file" be a + + and the second word be a file that contains one file name per + line. +

    GETTEXT_TRIGGERS

    The tools that generate message catalogs for the translators + to work on need to know what function calls contain + translatable strings. By default, only + gettext() calls are known. If you used + _ or other identifiers you need to list + them here. If the translatable string is not the first + argument, the item needs to be of the form + func:2 (for the second argument). + If you have a function that supports pluralized messages, + the item should look like func:1,2 + (identifying the singular and plural message arguments). +

    +

The build system will automatically take care of building and + installing the message catalogs. +

48.2.2. Message-writing Guidelines

Here are some guidelines for writing messages that are easily + translatable. + +

  • Do not construct sentences at run-time, like: +

    printf("Files were %s.\n", flag ? "copied" : "removed");

    + The word order within the sentence might be different in other + languages. Also, even if you remember to call gettext() on + each fragment, the fragments might not translate well separately. It's + better to duplicate a little code so that each message to be + translated is a coherent whole. Only numbers, file names, and + such-like run-time variables should be inserted at run time into + a message text. +

  • For similar reasons, this won't work: +

    printf("copied %d file%s", n, n!=1 ? "s" : "");

    + because it assumes how the plural is formed. If you figured you + could solve it like this: +

    if (n==1)
    +    printf("copied 1 file");
    +else
    +    printf("copied %d files", n):

    + then be disappointed. Some languages have more than two forms, + with some peculiar rules. It's often best to design the message + to avoid the issue altogether, for instance like this: +

    printf("number of copied files: %d", n);

    +

    If you really want to construct a properly pluralized message, + there is support for this, but it's a bit awkward. When generating + a primary or detail error message in ereport(), you can + write something like this: +

    errmsg_plural("copied %d file",
    +              "copied %d files",
    +              n,
    +              n)

    + The first argument is the format string appropriate for English + singular form, the second is the format string appropriate for + English plural form, and the third is the integer control value + that determines which plural form to use. Subsequent arguments + are formatted per the format string as usual. (Normally, the + pluralization control value will also be one of the values to be + formatted, so it has to be written twice.) In English it only + matters whether n is 1 or not 1, but in other + languages there can be many different plural forms. The translator + sees the two English forms as a group and has the opportunity to + supply multiple substitute strings, with the appropriate one being + selected based on the run-time value of n. +

    If you need to pluralize a message that isn't going directly to an + errmsg or errdetail report, you have to use + the underlying function ngettext. See the gettext + documentation. +

  • If you want to communicate something to the translator, such as + about how a message is intended to line up with other output, + precede the occurrence of the string with a comment that starts + with translator, e.g.: +

    /* translator: This message is not what it seems to be. */

    + These comments are copied to the message catalog files so that + the translators can see them. +

+


PrevHomeNext
For the TranslatorUpWriting A Procedural Language Handler
\ No newline at end of file diff --git a/doc/src/sgml/html/nls-translator.html b/doc/src/sgml/html/nls-translator.html new file mode 100644 index 000000000..8a22270ce --- /dev/null +++ b/doc/src/sgml/html/nls-translator.html @@ -0,0 +1,621 @@ + +For the Translator
PostgreSQL 9.2.2 Documentation
PrevUpChapter 48. Native Language SupportNext

48.1. For the Translator

PostgreSQL + programs (server and client) can issue their messages in + your favorite language — if the messages have been translated. + Creating and maintaining translated message sets needs the help of + people who speak their own language well and want to contribute to + the PostgreSQL effort. You do not have to be a + programmer at all + to do this. This section explains how to help. +

48.1.1. Requirements

We won't judge your language skills — this section is about + software tools. Theoretically, you only need a text editor. But + this is only in the unlikely event that you do not want to try out + your translated messages. When you configure your source tree, be + sure to use the --enable-nls option. This will + also check for the libintl library and the + msgfmt program, which all end users will need + anyway. To try out your work, follow the applicable portions of + the installation instructions. +

If you want to start a new translation effort or want to do a + message catalog merge (described later), you will need the + programs xgettext and + msgmerge, respectively, in a GNU-compatible + implementation. Later, we will try to arrange it so that if you + use a packaged source distribution, you won't need + xgettext. (If working from Git, you will still need + it.) GNU Gettext 0.10.36 or later is currently recommended. +

Your local gettext implementation should come with its own + documentation. Some of that is probably duplicated in what + follows, but for additional details you should look there. +

48.1.2. Concepts

The pairs of original (English) messages and their (possibly) + translated equivalents are kept in message + catalogs, one for each program (although related + programs can share a message catalog) and for each target + language. There are two file formats for message catalogs: The + first is the "PO" file (for Portable Object), which + is a plain text file with special syntax that translators edit. + The second is the "MO" file (for Machine Object), + which is a binary file generated from the respective PO file and + is used while the internationalized program is run. Translators + do not deal with MO files; in fact hardly anyone does. +

The extension of the message catalog file is to no surprise either + .po or .mo. The base + name is either the name of the program it accompanies, or the + language the file is for, depending on the situation. This is a + bit confusing. Examples are psql.po (PO file + for psql) or fr.mo (MO file in French). +

The file format of the PO files is illustrated here: +

# comment
+
+msgid "original string"
+msgstr "translated string"
+
+msgid "more original"
+msgstr "another translated"
+"string can be broken up like this"
+
+...

+ The msgid's are extracted from the program source. (They need not + be, but this is the most common way.) The msgstr lines are + initially empty and are filled in with useful strings by the + translator. The strings can contain C-style escape characters and + can be continued across lines as illustrated. (The next line must + start at the beginning of the line.) +

The # character introduces a comment. If whitespace immediately + follows the # character, then this is a comment maintained by the + translator. There can also be automatic comments, which have a + non-whitespace character immediately following the #. These are + maintained by the various tools that operate on the PO files and + are intended to aid the translator. +

#. automatic comment
+#: filename.c:1023
+#, flags, flags

+ The #. style comments are extracted from the source file where the + message is used. Possibly the programmer has inserted information + for the translator, such as about expected alignment. The #: + comment indicates the exact location(s) where the message is used + in the source. The translator need not look at the program + source, but he can if there is doubt about the correct + translation. The #, comments contain flags that describe the + message in some way. There are currently two flags: + fuzzy is set if the message has possibly been + outdated because of changes in the program source. The translator + can then verify this and possibly remove the fuzzy flag. Note + that fuzzy messages are not made available to the end user. The + other flag is c-format, which indicates that + the message is a printf-style format + template. This means that the translation should also be a format + string with the same number and type of placeholders. There are + tools that can verify this, which key off the c-format flag. +

48.1.3. Creating and Maintaining Message Catalogs

OK, so how does one create a "blank" message + catalog? First, go into the directory that contains the program + whose messages you want to translate. If there is a file + nls.mk, then this program has been prepared + for translation. +

If there are already some .po files, then + someone has already done some translation work. The files are + named language.po, + where language is the + ISO 639-1 two-letter language code (in lower case), e.g., + fr.po for French. If there is really a need + for more than one translation effort per language then the files + can also be named + language_region.po + where region is the + ISO 3166-1 two-letter country code (in upper case), + e.g., + pt_BR.po for Portuguese in Brazil. If you + find the language you wanted you can just start working on that + file. +

If you need to start a new translation effort, then first run the + command: +

gmake init-po

+ This will create a file + progname.pot. + (.pot to distinguish it from PO files that + are "in production". The T stands for + "template".) + Copy this file to + language.po and + edit it. To make it known that the new language is available, + also edit the file nls.mk and add the + language (or language and country) code to the line that looks like: +

AVAIL_LANGUAGES := de fr

+ (Other languages can appear, of course.) +

As the underlying program or library changes, messages might be + changed or added by the programmers. In this case you do not need + to start from scratch. Instead, run the command: +

gmake update-po

+ which will create a new blank message catalog file (the pot file + you started with) and will merge it with the existing PO files. + If the merge algorithm is not sure about a particular message it + marks it "fuzzy" as explained above. The new PO file + is saved with a .po.new extension. +

48.1.4. Editing the PO Files

The PO files can be edited with a regular text editor. The + translator should only change the area between the quotes after + the msgstr directive, add comments, and alter the fuzzy flag. + There is (unsurprisingly) a PO mode for Emacs, which I find quite + useful. +

The PO files need not be completely filled in. The software will + automatically fall back to the original string if no translation + (or an empty translation) is available. It is no problem to + submit incomplete translations for inclusions in the source tree; + that gives room for other people to pick up your work. However, + you are encouraged to give priority to removing fuzzy entries + after doing a merge. Remember that fuzzy entries will not be + installed; they only serve as reference for what might be the right + translation. +

Here are some things to keep in mind while editing the + translations: +

  • Make sure that if the original ends with a newline, the + translation does, too. Similarly for tabs, etc. +

  • If the original is a printf format string, the translation + also needs to be. The translation also needs to have the same + format specifiers in the same order. Sometimes the natural + rules of the language make this impossible or at least awkward. + In that case you can modify the format specifiers like this: +

    msgstr "Die Datei %2$s hat %1$u Zeichen."

    + Then the first placeholder will actually use the second + argument from the list. The + digits$ needs to + follow the % immediately, before any other format manipulators. + (This feature really exists in the printf + family of functions. You might not have heard of it before because + there is little use for it outside of message + internationalization.) +

  • If the original string contains a linguistic mistake, report + that (or fix it yourself in the program source) and translate + normally. The corrected string can be merged in when the + program sources have been updated. If the original string + contains a factual mistake, report that (or fix it yourself) + and do not translate it. Instead, you can mark the string with + a comment in the PO file. +

  • Maintain the style and tone of the original string. + Specifically, messages that are not sentences (cannot + open file %s) should probably not start with a + capital letter (if your language distinguishes letter case) or + end with a period (if your language uses punctuation marks). + It might help to read Section 47.3. +

  • If you don't know what a message means, or if it is ambiguous, + ask on the developers' mailing list. Chances are that English + speaking end users might also not understand it or find it + ambiguous, so it's best to improve the message. +

+


PrevHomeNext
Native Language SupportUpFor the Programmer
\ No newline at end of file diff --git a/doc/src/sgml/html/nls.html b/doc/src/sgml/html/nls.html new file mode 100644 index 000000000..cdd1dc368 --- /dev/null +++ b/doc/src/sgml/html/nls.html @@ -0,0 +1,219 @@ + +Native Language Support

Chapter 48. Native Language Support


PrevHomeNext
Error Message Style GuideUpFor the Translator
\ No newline at end of file diff --git a/doc/src/sgml/html/non-durability.html b/doc/src/sgml/html/non-durability.html new file mode 100644 index 000000000..4d28cbe26 --- /dev/null +++ b/doc/src/sgml/html/non-durability.html @@ -0,0 +1,249 @@ + +Non-Durable Settings
PostgreSQL 9.2.2 Documentation
PrevUpChapter 14. Performance TipsNext

14.5. Non-Durable Settings

Durability is a database feature that guarantees the recording of + committed transactions even if the server crashes or loses + power. However, durability adds significant database overhead, + so if your site does not require such a guarantee, + PostgreSQL can be configured to run + much faster. The following are configuration changes you can make + to improve performance in such cases. Except as noted below, durability + is still guaranteed in case of a crash of the database software; + only abrupt operating system stoppage creates a risk of data loss + or corruption when these settings are used. + +

  • Place the database cluster's data directory in a memory-backed + file system (i.e. RAM disk). This eliminates all + database disk I/O, but limits data storage to the amount of + available memory (and perhaps swap). +

  • Turn off fsync; there is no need to flush + data to disk. +

  • Turn off full_page_writes; there is no need + to guard against partial page writes. +

  • Increase checkpoint_segments and checkpoint_timeout ; this reduces the frequency + of checkpoints, but increases the storage requirements of + /pg_xlog. +

  • Turn off synchronous_commit; there might be no + need to write the WAL to disk on every + commit. This setting does risk transaction loss (though not data + corruption) in case of a crash of the database alone. +

+


PrevHomeNext
Populating a DatabaseUpServer Administration
\ No newline at end of file diff --git a/doc/src/sgml/html/notation.html b/doc/src/sgml/html/notation.html new file mode 100644 index 000000000..b0044ca7c --- /dev/null +++ b/doc/src/sgml/html/notation.html @@ -0,0 +1,261 @@ + +Conventions

Conventions

This book uses the following typographical conventions to mark + certain portions of text: new terms, foreign phrases, and other + important passages are emphasized in italics. + Everything that represents input or output of the computer, in + particular commands, program code, and screen output, is shown in a + monospaced font (example). Within such + passages, italics (example) indicate + placeholders; you must insert an actual value instead of the placeholder. + On occasion, parts of program code are emphasized in bold face + (example), if they have been + added or changed since the preceding example. +

The following conventions are used in the synopsis of a command: + brackets ([ and ]) indicate + optional parts. (In the synopsis of a Tcl command, question marks + (?) are used instead, as is usual in Tcl.) Braces + ({ and }) and vertical lines + (|) indicate that you must choose one + alternative. Dots (...) mean that the preceding element + can be repeated. +

Where it enhances the clarity, SQL commands are preceded by the + prompt =>, and shell commands are preceded by the + prompt $. Normally, prompts are not shown, though. +

An administrator is generally a person who is + in charge of installing and running the server. A user + could be anyone who is using, or wants to use, any part of the + PostgreSQL system. These terms should not + be interpreted too narrowly; this book does not have fixed + presumptions about system administration procedures. +


PrevHomeNext
A Brief History of PostgreSQLUpFurther Information
\ No newline at end of file diff --git a/doc/src/sgml/html/oid2name.html b/doc/src/sgml/html/oid2name.html new file mode 100644 index 000000000..5060c56dc --- /dev/null +++ b/doc/src/sgml/html/oid2name.html @@ -0,0 +1,732 @@ + +oid2name

oid2name

Name

oid2name -- resolve OIDs and file nodes in a PostgreSQL data directory

Synopsis

oid2name [option...]

Description

oid2name is a utility program that helps administrators to + examine the file structure used by PostgreSQL. To make use of it, you need + to be familiar with the database file structure, which is described in + Chapter 56. +

Note: The name "oid2name" is historical, and is actually rather + misleading, since most of the time when you use it, you will really + be concerned with tables' filenode numbers (which are the file names + visible in the database directories). Be sure you understand the + difference between table OIDs and table filenodes! +

oid2name connects to a target database and + extracts OID, filenode, and/or table name information. You can also have + it show database OIDs or tablespace OIDs. +

Options

oid2name accepts the following command-line arguments: + +

-f filenode

show info for table with filenode filenode

-i

include indexes and sequences in the listing

-o oid

show info for table with OID oid

-q

omit headers (useful for scripting)

-s

show tablespace OIDs

-S

include system objects (those in + information_schema, pg_toast + and pg_catalog schemas) +

-t tablename_pattern

show info for table(s) matching tablename_pattern

-V
--version

Print the oid2name version and exit. +

-x

display more information about each object shown: tablespace name, + schema name, and OID +

-?
--help

Show help about oid2name command line + arguments, and exit. +

+

oid2name also accepts the following command-line + arguments for connection parameters: + +

-d database

database to connect to

-H host

database server's host

-p port

database server's port

-U username

user name to connect as

-P password

password (deprecated — putting this on the command line + is a security hazard)

+

To display specific tables, select which tables to show by + using -o, -f and/or -t. + -o takes an OID, + -f takes a filenode, + and -t takes a table name (actually, it's a LIKE + pattern, so you can use things like foo%). + You can use as many + of these options as you like, and the listing will include all objects + matched by any of the options. But note that these options can only + show objects in the database given by -d. +

If you don't give any of -o, -f or -t, + but do give -d, it will list all tables in the database + named by -d. In this mode, the -S and + -i options control what gets listed. +

If you don't give -d either, it will show a listing of database + OIDs. Alternatively you can give -s to get a tablespace + listing. +

Notes

oid2name requires a running database server with + non-corrupt system catalogs. It is therefore of only limited use + for recovering from catastrophic database corruption situations. +

Examples

$ # what's in this database server, anyway?
+$ oid2name
+All databases:
+    Oid  Database Name  Tablespace
+----------------------------------
+  17228       alvherre  pg_default
+  17255     regression  pg_default
+  17227      template0  pg_default
+      1      template1  pg_default
+
+$ oid2name -s
+All tablespaces:
+     Oid  Tablespace Name
+-------------------------
+    1663       pg_default
+    1664        pg_global
+  155151         fastdisk
+  155152          bigdisk
+
+$ # OK, let's look into database alvherre
+$ cd $PGDATA/base/17228
+
+$ # get top 10 db objects in the default tablespace, ordered by size
+$ ls -lS * | head -10
+-rw-------  1 alvherre alvherre 136536064 sep 14 09:51 155173
+-rw-------  1 alvherre alvherre  17965056 sep 14 09:51 1155291
+-rw-------  1 alvherre alvherre   1204224 sep 14 09:51 16717
+-rw-------  1 alvherre alvherre    581632 sep  6 17:51 1255
+-rw-------  1 alvherre alvherre    237568 sep 14 09:50 16674
+-rw-------  1 alvherre alvherre    212992 sep 14 09:51 1249
+-rw-------  1 alvherre alvherre    204800 sep 14 09:51 16684
+-rw-------  1 alvherre alvherre    196608 sep 14 09:50 16700
+-rw-------  1 alvherre alvherre    163840 sep 14 09:50 16699
+-rw-------  1 alvherre alvherre    122880 sep  6 17:51 16751
+
+$ # I wonder what file 155173 is ...
+$ oid2name -d alvherre -f 155173
+From database "alvherre":
+  Filenode  Table Name
+----------------------
+    155173    accounts
+
+$ # you can ask for more than one object
+$ oid2name -d alvherre -f 155173 -f 1155291
+From database "alvherre":
+  Filenode     Table Name
+-------------------------
+    155173       accounts
+   1155291  accounts_pkey
+
+$ # you can mix the options, and get more details with -x
+$ oid2name -d alvherre -t accounts -f 1155291 -x
+From database "alvherre":
+  Filenode     Table Name      Oid  Schema  Tablespace
+------------------------------------------------------
+    155173       accounts   155173  public  pg_default
+   1155291  accounts_pkey  1155291  public  pg_default
+
+$ # show disk space for every db object
+$ du [0-9]* |
+> while read SIZE FILENODE
+> do
+>   echo "$SIZE       `oid2name -q -d alvherre -i -f $FILENODE`"
+> done
+16            1155287  branches_pkey
+16            1155289  tellers_pkey
+17561            1155291  accounts_pkey
+...
+
+$ # same, but sort by size
+$ du [0-9]* | sort -rn | while read SIZE FN
+> do
+>   echo "$SIZE   `oid2name -q -d alvherre -f $FN`"
+> done
+133466             155173    accounts
+17561            1155291  accounts_pkey
+1177              16717  pg_proc_proname_args_nsp_index
+...
+
+$ # If you want to see what's in tablespaces, use the pg_tblspc directory
+$ cd $PGDATA/pg_tblspc
+$ oid2name -s
+All tablespaces:
+     Oid  Tablespace Name
+-------------------------
+    1663       pg_default
+    1664        pg_global
+  155151         fastdisk
+  155152          bigdisk
+
+$ # what databases have objects in tablespace "fastdisk"?
+$ ls -d 155151/*
+155151/17228/  155151/PG_VERSION
+
+$ # Oh, what was database 17228 again?
+$ oid2name
+All databases:
+    Oid  Database Name  Tablespace
+----------------------------------
+  17228       alvherre  pg_default
+  17255     regression  pg_default
+  17227      template0  pg_default
+      1      template1  pg_default
+
+$ # Let's see what objects does this database have in the tablespace.
+$ cd 155151/17228
+$ ls -l
+total 0
+-rw-------  1 postgres postgres 0 sep 13 23:20 155156
+
+$ # OK, this is a pretty small table ... but which one is it?
+$ oid2name -d alvherre -f 155156
+From database "alvherre":
+  Filenode  Table Name
+----------------------
+    155156         foo

Author

B. Palmer <bpalmer@crimelabs.net> +


PrevHomeNext
Client ApplicationsUppgbench
\ No newline at end of file diff --git a/doc/src/sgml/html/overview.html b/doc/src/sgml/html/overview.html new file mode 100644 index 000000000..b6915b57a --- /dev/null +++ b/doc/src/sgml/html/overview.html @@ -0,0 +1,255 @@ + +Overview of PostgreSQL Internals

Chapter 44. Overview of PostgreSQL Internals

Author: This chapter originated as part of + Enhancement of the ANSI SQL Implementation of PostgreSQL, Stefan Simkovics' + Master's Thesis prepared at Vienna University of Technology under the direction + of O.Univ.Prof.Dr. Georg Gottlob and Univ.Ass. Mag. Katrin Seyr. +

This chapter gives an overview of the internal structure of the + backend of PostgreSQL. After having + read the following sections you should have an idea of how a query + is processed. This chapter does not aim to provide a detailed + description of the internal operation of + PostgreSQL, as such a document would be + very extensive. Rather, this chapter is intended to help the reader + understand the general sequence of operations that occur within the + backend from the point at which a query is received, to the point + at which the results are returned to the client. +


PrevHomeNext
InternalsUpThe Path of a Query
\ No newline at end of file diff --git a/doc/src/sgml/html/pageinspect.html b/doc/src/sgml/html/pageinspect.html new file mode 100644 index 000000000..090e6438c --- /dev/null +++ b/doc/src/sgml/html/pageinspect.html @@ -0,0 +1,423 @@ + +pageinspect
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.22. pageinspect

The pageinspect module provides functions that allow you to + inspect the contents of database pages at a low level, which is useful for + debugging purposes. All of these functions may be used only by superusers. +

F.22.1. Functions

get_raw_page(relname text, fork text, blkno int) returns bytea

get_raw_page reads the specified block of the named + table and returns a copy as a bytea value. This allows a + single time-consistent copy of the block to be obtained. + fork should be 'main' for + the main data fork, or 'fsm' for the free space map, + or 'vm' for the visibility map. +

get_raw_page(relname text, blkno int) returns bytea

A shorthand version of get_raw_page, for reading + from the main fork. Equivalent to + get_raw_page(relname, 'main', blkno) +

page_header(page bytea) returns record

page_header shows fields that are common to all + PostgreSQL heap and index pages. +

A page image obtained with get_raw_page should be + passed as argument. For example: +

test=# SELECT * FROM page_header(get_raw_page('pg_class', 0));
+    lsn    | tli | flags | lower | upper | special | pagesize | version | prune_xid
+-----------+-----+-------+-------+-------+---------+----------+---------+-----------
+ 0/24A1B50 |   1 |     1 |   232 |   368 |    8192 |     8192 |       4 |         0

+ The returned columns correspond to the fields in the + PageHeaderData struct. + See src/include/storage/bufpage.h for details. +

heap_page_items(page bytea) returns setof record

heap_page_items shows all line pointers on a heap + page. For those line pointers that are in use, tuple headers are also + shown. All tuples are shown, whether or not the tuples were visible to + an MVCC snapshot at the time the raw page was copied. +

A heap page image obtained with get_raw_page should + be passed as argument. For example: +

test=# SELECT * FROM heap_page_items(get_raw_page('pg_class', 0));

+ See src/include/storage/itemid.h and + src/include/access/htup.h for explanations of the fields + returned. +

bt_metap(relname text) returns record

bt_metap returns information about a B-tree + index's metapage. For example: +

test=# SELECT * FROM bt_metap('pg_cast_oid_index');
+-[ RECORD 1 ]-----
+magic     | 340322
+version   | 2
+root      | 1
+level     | 0
+fastroot  | 1
+fastlevel | 0

+

bt_page_stats(relname text, blkno int) returns record

bt_page_stats returns summary information about + single pages of B-tree indexes. For example: +

test=# SELECT * FROM bt_page_stats('pg_cast_oid_index', 1);
+-[ RECORD 1 ]-+-----
+blkno         | 1
+type          | l
+live_items    | 256
+dead_items    | 0
+avg_item_size | 12
+page_size     | 8192
+free_size     | 4056
+btpo_prev     | 0
+btpo_next     | 0
+btpo          | 0
+btpo_flags    | 3

+

bt_page_items(relname text, blkno int) returns setof record

bt_page_items returns detailed information about + all of the items on a B-tree index page. For example: +

test=# SELECT * FROM bt_page_items('pg_cast_oid_index', 1);
+ itemoffset |  ctid   | itemlen | nulls | vars |    data
+------------+---------+---------+-------+------+-------------
+          1 | (0,1)   |      12 | f     | f    | 23 27 00 00
+          2 | (0,2)   |      12 | f     | f    | 24 27 00 00
+          3 | (0,3)   |      12 | f     | f    | 25 27 00 00
+          4 | (0,4)   |      12 | f     | f    | 26 27 00 00
+          5 | (0,5)   |      12 | f     | f    | 27 27 00 00
+          6 | (0,6)   |      12 | f     | f    | 28 27 00 00
+          7 | (0,7)   |      12 | f     | f    | 29 27 00 00
+          8 | (0,8)   |      12 | f     | f    | 2a 27 00 00

+

fsm_page_contents(page bytea) returns text

fsm_page_contents shows the internal node structure + of a FSM page. The output is a multiline string, with one line per + node in the binary tree within the page. Only those nodes that are not + zero are printed. The so-called "next" pointer, which points to the + next slot to be returned from the page, is also printed. +

See src/backend/storage/freespace/README for more + information on the structure of an FSM page. +


PrevHomeNext
ltreeUppasswordcheck
\ No newline at end of file diff --git a/doc/src/sgml/html/parser-stage.html b/doc/src/sgml/html/parser-stage.html new file mode 100644 index 000000000..1f382033e --- /dev/null +++ b/doc/src/sgml/html/parser-stage.html @@ -0,0 +1,430 @@ + +The Parser Stage
PostgreSQL 9.2.2 Documentation
PrevUpChapter 44. Overview of PostgreSQL InternalsNext

44.3. The Parser Stage

The parser stage consists of two parts: + +

  • The parser defined in + gram.y and scan.l is + built using the Unix tools bison + and flex. +

  • The transformation process does + modifications and augmentations to the data structures returned by the parser. +

+

44.3.1. Parser

The parser has to check the query string (which arrives as plain + ASCII text) for valid syntax. If the syntax is correct a + parse tree is built up and handed back; + otherwise an error is returned. The parser and lexer are + implemented using the well-known Unix tools bison + and flex. +

The lexer is defined in the file + scan.l and is responsible + for recognizing identifiers, + the SQL key words etc. For + every key word or identifier that is found, a token + is generated and handed to the parser. +

The parser is defined in the file gram.y and + consists of a set of grammar rules and + actions that are executed whenever a rule + is fired. The code of the actions (which is actually C code) is + used to build up the parse tree. +

The file scan.l is transformed to the C + source file scan.c using the program + flex and gram.y is + transformed to gram.c using + bison. After these transformations + have taken place a normal C compiler can be used to create the + parser. Never make any changes to the generated C files as they + will be overwritten the next time flex + or bison is called. + +

Note: The mentioned transformations and compilations are normally done + automatically using the makefiles + shipped with the PostgreSQL + source distribution. +

+

A detailed description of bison or + the grammar rules given in gram.y would be + beyond the scope of this paper. There are many books and + documents dealing with flex and + bison. You should be familiar with + bison before you start to study the + grammar given in gram.y otherwise you won't + understand what happens there. +

44.3.2. Transformation Process

The parser stage creates a parse tree using only fixed rules about + the syntactic structure of SQL. It does not make any lookups in the + system catalogs, so there is no possibility to understand the detailed + semantics of the requested operations. After the parser completes, + the transformation process takes the tree handed + back by the parser as input and does the semantic interpretation needed + to understand which tables, functions, and operators are referenced by + the query. The data structure that is built to represent this + information is called the query tree. +

The reason for separating raw parsing from semantic analysis is that + system catalog lookups can only be done within a transaction, and we + do not wish to start a transaction immediately upon receiving a query + string. The raw parsing stage is sufficient to identify the transaction + control commands (BEGIN, ROLLBACK, etc), and + these can then be correctly executed without any further analysis. + Once we know that we are dealing with an actual query (such as + SELECT or UPDATE), it is okay to + start a transaction if we're not already in one. Only then can the + transformation process be invoked. +

The query tree created by the transformation process is structurally + similar to the raw parse tree in most places, but it has many differences + in detail. For example, a FuncCall node in the + parse tree represents something that looks syntactically like a function + call. This might be transformed to either a FuncExpr + or Aggref node depending on whether the referenced + name turns out to be an ordinary function or an aggregate function. + Also, information about the actual data types of columns and expression + results is added to the query tree. +


PrevHomeNext
How Connections are EstablishedUpThe PostgreSQL Rule System
\ No newline at end of file diff --git a/doc/src/sgml/html/passwordcheck.html b/doc/src/sgml/html/passwordcheck.html new file mode 100644 index 000000000..8cb870473 --- /dev/null +++ b/doc/src/sgml/html/passwordcheck.html @@ -0,0 +1,277 @@ + +passwordcheck
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.23. passwordcheck

The passwordcheck module checks users' passwords + whenever they are set with + CREATE ROLE or + ALTER ROLE. + If a password is considered too weak, it will be rejected and + the command will terminate with an error. +

To enable this module, add '$libdir/passwordcheck' + to shared_preload_libraries in + postgresql.conf, then restart the server. +

You can adapt this module to your needs by changing the source code. + For example, you can use + CrackLib + to check passwords — this only requires uncommenting + two lines in the Makefile and rebuilding the + module. (We cannot include CrackLib + by default for license reasons.) + Without CrackLib, the module enforces a few + simple rules for password strength, which you can modify or extend + as you see fit. +

Caution

To prevent unencrypted passwords from being sent across the network, + written to the server log or otherwise stolen by a database administrator, + PostgreSQL allows the user to supply + pre-encrypted passwords. Many client programs make use of this + functionality and encrypt the password before sending it to the server. +

This limits the usefulness of the passwordcheck + module, because in that case it can only try to guess the password. + For this reason, passwordcheck is not + recommended if your security requirements are high. + It is more secure to use an external authentication method such as Kerberos + (see Chapter 19) than to rely on + passwords within the database. +

Alternatively, you could modify passwordcheck + to reject pre-encrypted passwords, but forcing users to set their + passwords in clear text carries its own security risks. +


PrevHomeNext
pageinspectUppg_buffercache
\ No newline at end of file diff --git a/doc/src/sgml/html/performance-tips.html b/doc/src/sgml/html/performance-tips.html new file mode 100644 index 000000000..210750ae1 --- /dev/null +++ b/doc/src/sgml/html/performance-tips.html @@ -0,0 +1,303 @@ + +Performance Tips

Chapter 14. Performance Tips

Query performance can be affected by many things. Some of these can + be controlled by the user, while others are fundamental to the underlying + design of the system. This chapter provides some hints about understanding + and tuning PostgreSQL performance. +


PrevHomeNext
Locking and IndexesUpUsing EXPLAIN
\ No newline at end of file diff --git a/doc/src/sgml/html/perm-functions.html b/doc/src/sgml/html/perm-functions.html new file mode 100644 index 000000000..e20e92194 --- /dev/null +++ b/doc/src/sgml/html/perm-functions.html @@ -0,0 +1,191 @@ + +Function and Trigger Security

20.4. Function and Trigger Security

Functions and triggers allow users to insert code into the backend + server that other users might execute unintentionally. Hence, both + mechanisms permit users to "Trojan horse" + others with relative ease. The only real protection is tight + control over who can define functions. +

Functions run inside the backend + server process with the operating system permissions of the + database server daemon. If the programming language + used for the function allows unchecked memory accesses, it is + possible to change the server's internal data structures. + Hence, among many other things, such functions can circumvent any + system access controls. Function languages that allow such access + are considered "untrusted", and + PostgreSQL allows only superusers to + create functions written in those languages. +


PrevHomeNext
Role MembershipUpManaging Databases
\ No newline at end of file diff --git a/doc/src/sgml/html/pgarchivecleanup.html b/doc/src/sgml/html/pgarchivecleanup.html new file mode 100644 index 000000000..73400c4ae --- /dev/null +++ b/doc/src/sgml/html/pgarchivecleanup.html @@ -0,0 +1,561 @@ + +pg_archivecleanup

pg_archivecleanup

Name

pg_archivecleanup -- clean up PostgreSQL WAL archive files

Synopsis

pg_archivecleanup [option...] archivelocation oldestkeptwalfile

Description

pg_archivecleanup is designed to be used as an + archive_cleanup_command to clean up WAL file archives when + running as a standby server (see Section 25.2). + pg_archivecleanup can also be used as a standalone program to + clean WAL file archives. +

To configure a standby + server to use pg_archivecleanup, put this into its + recovery.conf configuration file: +

archive_cleanup_command = 'pg_archivecleanup archivelocation %r'

+ where archivelocation is the directory from which WAL segment + files should be removed. +

When used within archive_cleanup_command, all WAL files + logically preceding the value of the %r argument will be removed + from archivelocation. This minimizes the number of files + that need to be retained, while preserving crash-restart capability. Use of + this parameter is appropriate if the archivelocation is a + transient staging area for this particular standby server, but + not when the archivelocation is intended as a + long-term WAL archive area, or when multiple standby servers are recovering + from the same archive location. +

When used as a standalone program all WAL files logically preceding the + oldestkeptwalfile will be removed from archivelocation. + In this mode, if you specify a .backup file name, then only the file prefix + will be used as the oldestkeptwalfile. This allows you to remove + all WAL files archived prior to a specific base backup without error. + For example, the following example will remove all files older than + WAL file name 000000010000003700000010: +

pg_archivecleanup -d archive 000000010000003700000010.00000020.backup
+
+pg_archivecleanup:  keep WAL file "archive/000000010000003700000010" and later
+pg_archivecleanup:  removing file "archive/00000001000000370000000F"
+pg_archivecleanup:  removing file "archive/00000001000000370000000E"

+

pg_archivecleanup assumes that + archivelocation is a directory readable and writable by the + server-owning user. +

Options

pg_archivecleanup accepts the following command-line arguments: + +

-d

Print lots of debug logging output on stderr. +

-n

Print the names of the files that would have been removed on stdout (performs a dry run). +

-V
--version

Print the pg_archivecleanup version and exit. +

-x extension

When using the program as a standalone utility, provide an extension + that will be stripped from all file names before deciding if they + should be deleted. This is typically useful for cleaning up archives + that have been compressed during storage, and therefore have had an + extension added by the compression program. For example: -x + .gz. +

Note that the + .backup file name passed to the program should not + include the extension. +

-?
--help

Show help about pg_archivecleanup command line + arguments, and exit. +

+

Notes

pg_archivecleanup is designed to work with + PostgreSQL 8.0 and later when used as a standalone utility, + or with PostgreSQL 9.0 and later when used as an + archive cleanup command. +

pg_archivecleanup is written in C and has an + easy-to-modify source code, with specifically designated sections to modify + for your own needs +

Examples

On Linux or Unix systems, you might use: +

archive_cleanup_command = 'pg_archivecleanup -d /mnt/standby/archive %r 2>>cleanup.log'

+ where the archive directory is physically located on the standby server, + so that the archive_command is accessing it across NFS, + but the files are local to the standby. + This will: +

  • produce debugging output in cleanup.log +

  • remove no-longer-needed files from the archive directory +

Author

Simon Riggs <simon@2ndquadrant.com> +

See Also

pg_standby

PrevHomeNext
Server ApplicationsUppg_standby
\ No newline at end of file diff --git a/doc/src/sgml/html/pgbench.html b/doc/src/sgml/html/pgbench.html new file mode 100644 index 000000000..8af60063c --- /dev/null +++ b/doc/src/sgml/html/pgbench.html @@ -0,0 +1,1838 @@ + +pgbench

pgbench

Name

pgbench -- run a benchmark test on PostgreSQL

Synopsis

pgbench -i [option...] [dbname]

pgbench [option...] [dbname]

Description

pgbench is a simple program for running benchmark + tests on PostgreSQL. It runs the same sequence of SQL + commands over and over, possibly in multiple concurrent database sessions, + and then calculates the average transaction rate (transactions per second). + By default, pgbench tests a scenario that is + loosely based on TPC-B, involving five SELECT, + UPDATE, and INSERT commands per transaction. + However, it is easy to test other cases by writing your own transaction + script files. +

Typical output from pgbench looks like: + +

transaction type: TPC-B (sort of)
+scaling factor: 10
+query mode: simple
+number of clients: 10
+number of threads: 1
+number of transactions per client: 1000
+number of transactions actually processed: 10000/10000
+tps = 85.184871 (including connections establishing)
+tps = 85.296346 (excluding connections establishing)

+ + The first six lines report some of the most important parameter + settings. The next line reports the number of transactions completed + and intended (the latter being just the product of number of clients + and number of transactions per client); these will be equal unless the run + failed before completion. (In -T mode, only the actual + number of transactions is printed.) + The last two lines report the number of transactions per second, + figured with and without counting the time to start database sessions. +

The default TPC-B-like transaction test requires specific tables to be + set up beforehand. pgbench should be invoked with + the -i (initialize) option to create and populate these + tables. (When you are testing a custom script, you don't need this + step, but will instead need to do whatever setup your test needs.) + Initialization looks like: + +

pgbench -i [ other-options ] dbname

+ + where dbname is the name of the already-created + database to test in. (You may also need -h, + -p, and/or -U options to specify how to + connect to the database server.) +

Caution

pgbench -i creates four tables pgbench_accounts, + pgbench_branches, pgbench_history, and + pgbench_tellers, + destroying any existing tables of these names. + Be very careful to use another database if you have tables having these + names! +

At the default "scale factor" of 1, the tables initially + contain this many rows: +

table                   # of rows
+---------------------------------
+pgbench_branches        1
+pgbench_tellers         10
+pgbench_accounts        100000
+pgbench_history         0

+ You can (and, for most purposes, probably should) increase the number + of rows by using the -s (scale factor) option. The + -F (fillfactor) option might also be used at this point. +

Once you have done the necessary setup, you can run your benchmark + with a command that doesn't include -i, that is + +

pgbench [ options ] dbname

+ + In nearly all cases, you'll need some options to make a useful test. + The most important options are -c (number of clients), + -t (number of transactions), -T (time limit), + and -f (specify a custom script file). + See below for a full list. +

Options

The following is divided into three subsections: Different options are used + during database initialization and while running benchmarks, some options + are useful in both cases. +

Initialization Options

pgbench accepts the following command-line + initialization arguments: + +

-i

Required to invoke initialization mode. +

-F fillfactor

Create the pgbench_accounts, + pgbench_tellers and + pgbench_branches tables with the given fillfactor. + Default is 100. +

-s scale_factor

Multiply the number of rows generated by the scale factor. + For example, -s 100 will create 10,000,000 rows + in the pgbench_accounts table. Default is 1. +

--index-tablespace=index_tablespace

Create indexes in the specified tablespace, rather than the default + tablespace. +

--tablespace=tablespace

Create tables in the specified tablespace, rather than the default + tablespace. +

--unlogged-tables

Create all tables as unlogged tables, rather than permanent tables. +

+

Benchmarking Options

pgbench accepts the following command-line + benchmarking arguments: + +

-c clients

Number of clients simulated, that is, number of concurrent database + sessions. Default is 1. +

-C

Establish a new connection for each transaction, rather than + doing it just once per client session. + This is useful to measure the connection overhead. +

-d

Print debugging output. +

-D varname=value

Define a variable for use by a custom script (see below). + Multiple -D options are allowed. +

-f filename

Read transaction script from filename. + See below for details. + -N, -S, and -f + are mutually exclusive. +

-j threads

Number of worker threads within pgbench. + Using more than one thread can be helpful on multi-CPU machines. + The number of clients must be a multiple of the number of threads, + since each thread is given the same number of client sessions to manage. + Default is 1. +

-l

Write the time taken by each transaction to a log file. + See below for details. +

-M querymode

Protocol to use for submitting queries to the server: +

  • simple: use simple query protocol.

  • extended: use extended query protocol.

  • prepared: use extended query protocol with prepared statements.

+ The default is simple query protocol. (See Chapter 46 + for more information.) +

-n

Perform no vacuuming before running the test. + This option is necessary + if you are running a custom test scenario that does not include + the standard tables pgbench_accounts, + pgbench_branches, pgbench_history, and + pgbench_tellers. +

-N

Do not update pgbench_tellers and + pgbench_branches. + This will avoid update contention on these tables, but + it makes the test case even less like TPC-B. +

-r

Report the average per-statement latency (execution time from the + perspective of the client) of each command after the benchmark + finishes. See below for details. +

-s scale_factor

Report the specified scale factor in pgbench's + output. With the built-in tests, this is not necessary; the + correct scale factor will be detected by counting the number of + rows in the pgbench_branches table. However, when testing + custom benchmarks (-f option), the scale factor + will be reported as 1 unless this option is used. +

-S

Perform select-only transactions instead of TPC-B-like test. +

-t transactions

Number of transactions each client runs. Default is 10. +

-T seconds

Run the test for this many seconds, rather than a fixed number of + transactions per client. -t and + -T are mutually exclusive. +

-v

Vacuum all four standard tables before running the test. + With neither -n nor -v, pgbench will vacuum the + pgbench_tellers and pgbench_branches + tables, and will truncate pgbench_history. +

+

Common Options

pgbench accepts the following command-line + common arguments: + +

-h hostname

The database server's host name +

-p port

The database server's port number +

-U login

The user name to connect as +

-V
--version

Print the pgbench version and exit. +

-?
--help

Show help about pgbench command line + arguments, and exit. +

+

Notes

What is the "Transaction" Actually Performed in pgbench?

The default transaction script issues seven commands per transaction: +

  1. BEGIN;

  2. UPDATE pgbench_accounts SET abalance = abalance + :delta WHERE aid = :aid;

  3. SELECT abalance FROM pgbench_accounts WHERE aid = :aid;

  4. UPDATE pgbench_tellers SET tbalance = tbalance + :delta WHERE tid = :tid;

  5. UPDATE pgbench_branches SET bbalance = bbalance + :delta WHERE bid = :bid;

  6. INSERT INTO pgbench_history (tid, bid, aid, delta, mtime) VALUES (:tid, :bid, :aid, :delta, CURRENT_TIMESTAMP);

  7. END;

If you specify -N, steps 4 and 5 aren't included in the + transaction. If you specify -S, only the SELECT is + issued. +

Custom Scripts

pgbench has support for running custom + benchmark scenarios by replacing the default transaction script + (described above) with a transaction script read from a file + (-f option). In this case a "transaction" + counts as one execution of a script file. You can even specify + multiple scripts (multiple -f options), in which + case a random one of the scripts is chosen each time a client session + starts a new transaction. +

The format of a script file is one SQL command per line; multiline + SQL commands are not supported. Empty lines and lines beginning with + -- are ignored. Script file lines can also be + "meta commands", which are interpreted by pgbench + itself, as described below. +

There is a simple variable-substitution facility for script files. + Variables can be set by the command-line -D option, + explained above, or by the meta commands explained below. + In addition to any variables preset by -D command-line options, + the variable scale is preset to the current scale factor. + Once set, a variable's + value can be inserted into a SQL command by writing + :variablename. When running more than + one client session, each session has its own set of variables. +

Script file meta commands begin with a backslash (\). + Arguments to a meta command are separated by white space. + These meta commands are supported: +

\set varname operand1 [ operator operand2 ]

Sets variable varname to a calculated integer value. + Each operand is either an integer constant or a + :variablename reference to a variable + having an integer value. The operator can be + +, -, *, or /. +

Example: +

\set ntellers 10 * :scale

\setrandom varname min max

Sets variable varname to a random integer value + between the limits min and max inclusive. + Each limit can be either an integer constant or a + :variablename reference to a variable + having an integer value. +

Example: +

\setrandom aid 1 :naccounts

\sleep number [ us | ms | s ]

Causes script execution to sleep for the specified duration in + microseconds (us), milliseconds (ms) or seconds + (s). If the unit is omitted then seconds are the default. + number can be either an integer constant or a + :variablename reference to a variable + having an integer value. +

Example: +

\sleep 10 ms

\setshell varname command [ argument ... ]

Sets variable varname to the result of the shell command + command. The command must return an integer value + through its standard output. +

argument can be either a text constant or a + :variablename reference to a variable of + any types. If you want to use argument starting with + colons, you need to add an additional colon at the beginning of + argument. +

Example: +

\setshell variable_to_be_assigned command literal_argument :variable ::literal_starting_with_colon

\shell command [ argument ... ]

Same as \setshell, but the result is ignored. +

Example: +

\shell command literal_argument :variable ::literal_starting_with_colon

As an example, the full definition of the built-in TPC-B-like + transaction is: + +

\set nbranches :scale
+\set ntellers 10 * :scale
+\set naccounts 100000 * :scale
+\setrandom aid 1 :naccounts
+\setrandom bid 1 :nbranches
+\setrandom tid 1 :ntellers
+\setrandom delta -5000 5000
+BEGIN;
+UPDATE pgbench_accounts SET abalance = abalance + :delta WHERE aid = :aid;
+SELECT abalance FROM pgbench_accounts WHERE aid = :aid;
+UPDATE pgbench_tellers SET tbalance = tbalance + :delta WHERE tid = :tid;
+UPDATE pgbench_branches SET bbalance = bbalance + :delta WHERE bid = :bid;
+INSERT INTO pgbench_history (tid, bid, aid, delta, mtime) VALUES (:tid, :bid, :aid, :delta, CURRENT_TIMESTAMP);
+END;

+ + This script allows each iteration of the transaction to reference + different, randomly-chosen rows. (This example also shows why it's + important for each client session to have its own variables — + otherwise they'd not be independently touching different rows.) +

Per-Transaction Logging

With the -l option, pgbench writes the time + taken by each transaction to a log file. The log file will be named + pgbench_log.nnn, where + nnn is the PID of the pgbench process. + If the -j option is 2 or higher, creating multiple worker + threads, each will have its own log file. The first worker will use the + same name for its log file as in the standard single worker case. + The additional log files for the other workers will be named + pgbench_log.nnn.mmm, + where mmm is a sequential number for each worker starting + with 1. +

The format of the log is: + +

client_id transaction_no time file_no time_epoch time_us

+ + where time is the total elapsed transaction time in microseconds, + file_no identifies which script file was used + (useful when multiple scripts were specified with -f), + and time_epoch/time_us are a + UNIX epoch format timestamp and an offset + in microseconds (suitable for creating a ISO 8601 + timestamp with fractional seconds) showing when + the transaction completed. +

Here are example outputs: +

 0 199 2241 0 1175850568 995598
+ 0 200 2465 0 1175850568 998079
+ 0 201 2513 0 1175850569 608
+ 0 202 2038 0 1175850569 2663

Per-Statement Latencies

With the -r option, pgbench collects + the elapsed transaction time of each statement executed by every + client. It then reports an average of those values, referred to + as the latency for each statement, after the benchmark has finished. +

For the default script, the output will look similar to this: +

starting vacuum...end.
+transaction type: TPC-B (sort of)
+scaling factor: 1
+query mode: simple
+number of clients: 10
+number of threads: 1
+number of transactions per client: 1000
+number of transactions actually processed: 10000/10000
+tps = 618.764555 (including connections establishing)
+tps = 622.977698 (excluding connections establishing)
+statement latencies in milliseconds:
+        0.004386        \set nbranches 1 * :scale
+        0.001343        \set ntellers 10 * :scale
+        0.001212        \set naccounts 100000 * :scale
+        0.001310        \setrandom aid 1 :naccounts
+        0.001073        \setrandom bid 1 :nbranches
+        0.001005        \setrandom tid 1 :ntellers
+        0.001078        \setrandom delta -5000 5000
+        0.326152        BEGIN;
+        0.603376        UPDATE pgbench_accounts SET abalance = abalance + :delta WHERE aid = :aid;
+        0.454643        SELECT abalance FROM pgbench_accounts WHERE aid = :aid;
+        5.528491        UPDATE pgbench_tellers SET tbalance = tbalance + :delta WHERE tid = :tid;
+        7.335435        UPDATE pgbench_branches SET bbalance = bbalance + :delta WHERE bid = :bid;
+        0.371851        INSERT INTO pgbench_history (tid, bid, aid, delta, mtime) VALUES (:tid, :bid, :aid, :delta, CURRENT_TIMESTAMP);
+        1.212976        END;

+

If multiple script files are specified, the averages are reported + separately for each script file. +

Note that collecting the additional timing information needed for + per-statement latency computation adds some overhead. This will slow + average execution speed and lower the computed TPS. The amount + of slowdown varies significantly depending on platform and hardware. + Comparing average TPS values with and without latency reporting enabled + is a good way to measure if the timing overhead is significant. +

Good Practices

It is very easy to use pgbench to produce completely + meaningless numbers. Here are some guidelines to help you get useful + results. +

In the first place, never believe any test that runs + for only a few seconds. Use the -t or -T option + to make the run last at least a few minutes, so as to average out noise. + In some cases you could need hours to get numbers that are reproducible. + It's a good idea to try the test run a few times, to find out if your + numbers are reproducible or not. +

For the default TPC-B-like test scenario, the initialization scale factor + (-s) should be at least as large as the largest number of + clients you intend to test (-c); else you'll mostly be + measuring update contention. There are only -s rows in + the pgbench_branches table, and every transaction wants to + update one of them, so -c values in excess of -s + will undoubtedly result in lots of transactions blocked waiting for + other transactions. +

The default test scenario is also quite sensitive to how long it's been + since the tables were initialized: accumulation of dead rows and dead space + in the tables changes the results. To understand the results you must keep + track of the total number of updates and when vacuuming happens. If + autovacuum is enabled it can result in unpredictable changes in measured + performance. +

A limitation of pgbench is that it can itself become + the bottleneck when trying to test a large number of client sessions. + This can be alleviated by running pgbench on a different + machine from the database server, although low network latency will be + essential. It might even be useful to run several pgbench + instances concurrently, on several client machines, against the same + database server. +


PrevHomeNext
oid2nameUpvacuumlo
\ No newline at end of file diff --git a/doc/src/sgml/html/pgbuffercache.html b/doc/src/sgml/html/pgbuffercache.html new file mode 100644 index 000000000..eb2cc6d7e --- /dev/null +++ b/doc/src/sgml/html/pgbuffercache.html @@ -0,0 +1,481 @@ + +pg_buffercache
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.24. pg_buffercache

The pg_buffercache module provides a means for + examining what's happening in the shared buffer cache in real time. +

The module provides a C function pg_buffercache_pages + that returns a set of records, plus a view + pg_buffercache that wraps the function for + convenient use. +

By default public access is revoked from both of these, just in case there + are security issues lurking. +

F.24.1. The pg_buffercache View

The definitions of the columns exposed by the view are shown in Table F-14. +

Table F-14. pg_buffercache Columns

NameTypeReferencesDescription
bufferidinteger ID, in the range 1..shared_buffers
relfilenodeoidpg_class.relfilenodeFilenode number of the relation
reltablespaceoidpg_tablespace.oidTablespace OID of the relation
reldatabaseoidpg_database.oidDatabase OID of the relation
relblocknumberbigint Page number within the relation
relforknumbersmallint Fork number within the relation
isdirtyboolean Is the page dirty?
usagecountsmallint Page LRU count

There is one row for each buffer in the shared cache. Unused buffers are + shown with all fields null except bufferid. Shared system + catalogs are shown as belonging to database zero. +

Because the cache is shared by all the databases, there will normally be + pages from relations not belonging to the current database. This means + that there may not be matching join rows in pg_class for + some rows, or that there could even be incorrect joins. If you are + trying to join against pg_class, it's a good idea to + restrict the join to rows having reldatabase equal to + the current database's OID or zero. +

When the pg_buffercache view is accessed, internal buffer + manager locks are taken for long enough to copy all the buffer state + data that the view will display. + This ensures that the view produces a consistent set of results, while not + blocking normal buffer activity longer than necessary. Nonetheless there + could be some impact on database performance if this view is read often. +

F.24.2. Sample Output

regression=# SELECT c.relname, count(*) AS buffers
+             FROM pg_buffercache b INNER JOIN pg_class c
+             ON b.relfilenode = pg_relation_filenode(c.oid) AND
+                b.reldatabase IN (0, (SELECT oid FROM pg_database
+                                      WHERE datname = current_database()))
+             GROUP BY c.relname
+             ORDER BY 2 DESC
+             LIMIT 10;
+
+             relname             | buffers
+---------------------------------+---------
+ tenk2                           |     345
+ tenk1                           |     141
+ pg_proc                         |      46
+ pg_class                        |      45
+ pg_attribute                    |      43
+ pg_class_relname_nsp_index      |      30
+ pg_proc_proname_args_nsp_index  |      28
+ pg_attribute_relid_attnam_index |      26
+ pg_depend                       |      22
+ pg_depend_reference_index       |      20
+(10 rows)

F.24.3. Authors

Mark Kirkwood <markir@paradise.net.nz> +

Design suggestions: Neil Conway <neilc@samurai.com> +

Debugging advice: Tom Lane <tgl@sss.pgh.pa.us> +


PrevHomeNext
passwordcheckUppgcrypto
\ No newline at end of file diff --git a/doc/src/sgml/html/pgcrypto.html b/doc/src/sgml/html/pgcrypto.html new file mode 100644 index 000000000..a6dbfc3a2 --- /dev/null +++ b/doc/src/sgml/html/pgcrypto.html @@ -0,0 +1,2352 @@ + +pgcrypto
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.25. pgcrypto

The pgcrypto module provides cryptographic functions for + PostgreSQL. +

F.25.1. General Hashing Functions

F.25.1.1. digest()

digest(data text, type text) returns bytea
+digest(data bytea, type text) returns bytea

Computes a binary hash of the given data. + type is the algorithm to use. + Standard algorithms are md5, sha1, + sha224, sha256, + sha384 and sha512. + If pgcrypto was built with + OpenSSL, more algorithms are available, as detailed in + Table F-18. +

If you want the digest as a hexadecimal string, use + encode() on the result. For example: +

CREATE OR REPLACE FUNCTION sha1(bytea) returns text AS $$
+    SELECT encode(digest($1, 'sha1'), 'hex')
+$$ LANGUAGE SQL STRICT IMMUTABLE;

+

F.25.1.2. hmac()

hmac(data text, key text, type text) returns bytea
+hmac(data bytea, key text, type text) returns bytea

Calculates hashed MAC for data with key key. + type is the same as in digest(). +

This is similar to digest() but the hash can only be + recalculated knowing the key. This prevents the scenario of someone + altering data and also changing the hash to match. +

If the key is larger than the hash block size it will first be hashed and + the result will be used as key. +

F.25.2. Password Hashing Functions

The functions crypt() and gen_salt() + are specifically designed for hashing passwords. + crypt() does the hashing and gen_salt() + prepares algorithm parameters for it. +

The algorithms in crypt() differ from usual hashing algorithms + like MD5 or SHA1 in the following respects: +

  1. They are slow. As the amount of data is so small, this is the only + way to make brute-forcing passwords hard. +

  2. They use a random value, called the salt, so that users + having the same password will have different encrypted passwords. + This is also an additional defense against reversing the algorithm. +

  3. They include the algorithm type in the result, so passwords hashed with + different algorithms can co-exist. +

  4. Some of them are adaptive — that means when computers get + faster, you can tune the algorithm to be slower, without + introducing incompatibility with existing passwords. +

Table F-15 lists the algorithms + supported by the crypt() function. +

Table F-15. Supported Algorithms for crypt()

AlgorithmMax Password LengthAdaptive?Salt BitsDescription
bf72yes128Blowfish-based, variant 2a
md5unlimitedno48MD5-based crypt
xdes8yes24Extended DES
des8no12Original UNIX crypt

F.25.2.1. crypt()

crypt(password text, salt text) returns text

Calculates a crypt(3)-style hash of password. + When storing a new password, you need to use + gen_salt() to generate a new salt value. + To check a password, pass the stored hash value as salt, + and test whether the result matches the stored value. +

Example of setting a new password: +

UPDATE ... SET pswhash = crypt('new password', gen_salt('md5'));

+

Example of authentication: +

SELECT pswhash = crypt('entered password', pswhash) FROM ... ;

+ This returns true if the entered password is correct. +

F.25.2.2. gen_salt()

gen_salt(type text [, iter_count integer ]) returns text

Generates a new random salt string for use in crypt(). + The salt string also tells crypt() which algorithm to use. +

The type parameter specifies the hashing algorithm. + The accepted types are: des, xdes, + md5 and bf. +

The iter_count parameter lets the user specify the iteration + count, for algorithms that have one. + The higher the count, the more time it takes to hash + the password and therefore the more time to break it. Although with + too high a count the time to calculate a hash may be several years + — which is somewhat impractical. If the iter_count + parameter is omitted, the default iteration count is used. + Allowed values for iter_count depend on the algorithm and + are shown in Table F-16. +

Table F-16. Iteration Counts for crypt()

AlgorithmDefaultMinMax
xdes725116777215
bf6431

For xdes there is an additional limitation that the + iteration count must be an odd number. +

To pick an appropriate iteration count, consider that + the original DES crypt was designed to have the speed of 4 hashes per + second on the hardware of that time. + Slower than 4 hashes per second would probably dampen usability. + Faster than 100 hashes per second is probably too fast. +

Table F-17 gives an overview of the relative slowness + of different hashing algorithms. + The table shows how much time it would take to try all + combinations of characters in an 8-character password, assuming + that the password contains either only lower case letters, or + upper- and lower-case letters and numbers. + In the crypt-bf entries, the number after a slash is + the iter_count parameter of + gen_salt. +

Table F-17. Hash Algorithm Speeds

AlgorithmHashes/secFor [a-z]For [A-Za-z0-9]
crypt-bf/828246 years251322 years
crypt-bf/757121 years123457 years
crypt-bf/611262 years62831 years
crypt-bf/521133 years33351 years
crypt-md526812.6 years2625 years
crypt-des3628377 days19 years
sha15902234 days12 years
md523450861 day3 years

Notes: +

  • The machine used is a 1.5GHz Pentium 4. +

  • crypt-des and crypt-md5 algorithm numbers are + taken from John the Ripper v1.6.38 -test output. +

  • md5 numbers are from mdcrack 1.2. +

  • sha1 numbers are from lcrack-20031130-beta. +

  • crypt-bf numbers are taken using a simple program that + loops over 1000 8-character passwords. That way I can show the speed + with different numbers of iterations. For reference: john + -test shows 213 loops/sec for crypt-bf/5. + (The very small + difference in results is in accordance with the fact that the + crypt-bf implementation in pgcrypto + is the same one used in John the Ripper.) +

Note that "try all combinations" is not a realistic exercise. + Usually password cracking is done with the help of dictionaries, which + contain both regular words and various mutations of them. So, even + somewhat word-like passwords could be cracked much faster than the above + numbers suggest, while a 6-character non-word-like password may escape + cracking. Or not. +

F.25.3. PGP Encryption Functions

The functions here implement the encryption part of the OpenPGP (RFC 4880) + standard. Supported are both symmetric-key and public-key encryption. +

An encrypted PGP message consists of 2 parts, or packets: +

  • Packet containing a session key — either symmetric-key or public-key + encrypted. +

  • Packet containing data encrypted with the session key. +

When encrypting with a symmetric key (i.e., a password): +

  1. The given password is hashed using a String2Key (S2K) algorithm. This is + rather similar to crypt() algorithms — purposefully + slow and with random salt — but it produces a full-length binary + key. +

  2. If a separate session key is requested, a new random key will be + generated. Otherwise the S2K key will be used directly as the session + key. +

  3. If the S2K key is to be used directly, then only S2K settings will be put + into the session key packet. Otherwise the session key will be encrypted + with the S2K key and put into the session key packet. +

When encrypting with a public key: +

  1. A new random session key is generated. +

  2. It is encrypted using the public key and put into the session key packet. +

In either case the data to be encrypted is processed as follows: +

  1. Optional data-manipulation: compression, conversion to UTF-8, + and/or conversion of line-endings. +

  2. The data is prefixed with a block of random bytes. This is equivalent + to using a random IV. +

  3. An SHA1 hash of the random prefix and data is appended. +

  4. All this is encrypted with the session key and placed in the data packet. +

F.25.3.1. pgp_sym_encrypt()

pgp_sym_encrypt(data text, psw text [, options text ]) returns bytea
+pgp_sym_encrypt_bytea(data bytea, psw text [, options text ]) returns bytea

Encrypt data with a symmetric PGP key psw. + The options parameter can contain option settings, + as described below. +

F.25.3.2. pgp_sym_decrypt()

pgp_sym_decrypt(msg bytea, psw text [, options text ]) returns text
+pgp_sym_decrypt_bytea(msg bytea, psw text [, options text ]) returns bytea

Decrypt a symmetric-key-encrypted PGP message. +

Decrypting bytea data with pgp_sym_decrypt is disallowed. + This is to avoid outputting invalid character data. Decrypting + originally textual data with pgp_sym_decrypt_bytea is fine. +

The options parameter can contain option settings, + as described below. +

F.25.3.3. pgp_pub_encrypt()

pgp_pub_encrypt(data text, key bytea [, options text ]) returns bytea
+pgp_pub_encrypt_bytea(data bytea, key bytea [, options text ]) returns bytea

Encrypt data with a public PGP key key. + Giving this function a secret key will produce a error. +

The options parameter can contain option settings, + as described below. +

F.25.3.4. pgp_pub_decrypt()

pgp_pub_decrypt(msg bytea, key bytea [, psw text [, options text ]]) returns text
+pgp_pub_decrypt_bytea(msg bytea, key bytea [, psw text [, options text ]]) returns bytea

Decrypt a public-key-encrypted message. key must be the + secret key corresponding to the public key that was used to encrypt. + If the secret key is password-protected, you must give the password in + psw. If there is no password, but you want to specify + options, you need to give an empty password. +

Decrypting bytea data with pgp_pub_decrypt is disallowed. + This is to avoid outputting invalid character data. Decrypting + originally textual data with pgp_pub_decrypt_bytea is fine. +

The options parameter can contain option settings, + as described below. +

F.25.3.5. pgp_key_id()

pgp_key_id(bytea) returns text

pgp_key_id extracts the key ID of a PGP public or secret key. + Or it gives the key ID that was used for encrypting the data, if given + an encrypted message. +

It can return 2 special key IDs: +

  • SYMKEY +

    The message is encrypted with a symmetric key. +

  • ANYKEY +

    The message is public-key encrypted, but the key ID has been removed. + That means you will need to try all your secret keys on it to see + which one decrypts it. pgcrypto itself does not produce + such messages. +

Note that different keys may have the same ID. This is rare but a normal + event. The client application should then try to decrypt with each one, + to see which fits — like handling ANYKEY. +

F.25.3.6. armor(), dearmor()

armor(data bytea) returns text
+dearmor(data text) returns bytea

These functions wrap/unwrap binary data into PGP ASCII-armor format, + which is basically Base64 with CRC and additional formatting. +

F.25.3.7. Options for PGP Functions

Options are named to be similar to GnuPG. An option's value should be + given after an equal sign; separate options from each other with commas. + For example: +

pgp_sym_encrypt(data, psw, 'compress-algo=1, cipher-algo=aes256')

+

All of the options except convert-crlf apply only to + encrypt functions. Decrypt functions get the parameters from the PGP + data. +

The most interesting options are probably + compress-algo and unicode-mode. + The rest should have reasonable defaults. +

F.25.3.7.1. cipher-algo

Which cipher algorithm to use. +

Values: bf, aes128, aes192, aes256 (OpenSSL-only: 3descast5)
+Default: aes128
+Applies to: pgp_sym_encrypt, pgp_pub_encrypt

F.25.3.7.2. compress-algo

Which compression algorithm to use. Only available if + PostgreSQL was built with zlib. +

Values:
+  0 - no compression
+  1 - ZIP compression
+  2 - ZLIB compression (= ZIP plus meta-data and block CRCs)
+Default: 0
+Applies to: pgp_sym_encrypt, pgp_pub_encrypt

F.25.3.7.3. compress-level

How much to compress. Higher levels compress smaller but are slower. + 0 disables compression. +

Values: 0, 1-9
+Default: 6
+Applies to: pgp_sym_encrypt, pgp_pub_encrypt

F.25.3.7.4. convert-crlf

Whether to convert \n into \r\n when + encrypting and \r\n to \n when + decrypting. RFC 4880 specifies that text data should be stored using + \r\n line-feeds. Use this to get fully RFC-compliant + behavior. +

Values: 0, 1
+Default: 0
+Applies to: pgp_sym_encrypt, pgp_pub_encrypt, pgp_sym_decrypt, pgp_pub_decrypt

F.25.3.7.5. disable-mdc

Do not protect data with SHA-1. The only good reason to use this + option is to achieve compatibility with ancient PGP products, predating + the addition of SHA-1 protected packets to RFC 4880. + Recent gnupg.org and pgp.com software supports it fine. +

Values: 0, 1
+Default: 0
+Applies to: pgp_sym_encrypt, pgp_pub_encrypt

F.25.3.7.6. enable-session-key

Use separate session key. Public-key encryption always uses a separate + session key; this is for symmetric-key encryption, which by default + uses the S2K key directly. +

Values: 0, 1
+Default: 0
+Applies to: pgp_sym_encrypt

F.25.3.7.7. s2k-mode

Which S2K algorithm to use. +

Values:
+  0 - Without salt.  Dangerous!
+  1 - With salt but with fixed iteration count.
+  3 - Variable iteration count.
+Default: 3
+Applies to: pgp_sym_encrypt

F.25.3.7.8. s2k-digest-algo

Which digest algorithm to use in S2K calculation. +

Values: md5, sha1
+Default: sha1
+Applies to: pgp_sym_encrypt

F.25.3.7.9. s2k-cipher-algo

Which cipher to use for encrypting separate session key. +

Values: bf, aes, aes128, aes192, aes256
+Default: use cipher-algo
+Applies to: pgp_sym_encrypt

F.25.3.7.10. unicode-mode

Whether to convert textual data from database internal encoding to + UTF-8 and back. If your database already is UTF-8, no conversion will + be done, but the message will be tagged as UTF-8. Without this option + it will not be. +

Values: 0, 1
+Default: 0
+Applies to: pgp_sym_encrypt, pgp_pub_encrypt

F.25.3.8. Generating PGP Keys with GnuPG

To generate a new key: +

gpg --gen-key

+

The preferred key type is "DSA and Elgamal". +

For RSA encryption you must create either DSA or RSA sign-only key + as master and then add an RSA encryption subkey with + gpg --edit-key. +

To list keys: +

gpg --list-secret-keys

+

To export a public key in ASCII-armor format: +

gpg -a --export KEYID > public.key

+

To export a secret key in ASCII-armor format: +

gpg -a --export-secret-keys KEYID > secret.key

+

You need to use dearmor() on these keys before giving them to + the PGP functions. Or if you can handle binary data, you can drop + -a from the command. +

For more details see man gpg, + The GNU + Privacy Handbook and other documentation on + http://www.gnupg.org. +

F.25.3.9. Limitations of PGP Code

  • No support for signing. That also means that it is not checked + whether the encryption subkey belongs to the master key. +

  • No support for encryption key as master key. As such practice + is generally discouraged, this should not be a problem. +

  • No support for several subkeys. This may seem like a problem, as this + is common practice. On the other hand, you should not use your regular + GPG/PGP keys with pgcrypto, but create new ones, + as the usage scenario is rather different. +

F.25.4. Raw Encryption Functions

These functions only run a cipher over data; they don't have any advanced + features of PGP encryption. Therefore they have some major problems: +

  1. They use user key directly as cipher key. +

  2. They don't provide any integrity checking, to see + if the encrypted data was modified. +

  3. They expect that users manage all encryption parameters + themselves, even IV. +

  4. They don't handle text. +

So, with the introduction of PGP encryption, usage of raw + encryption functions is discouraged. +

encrypt(data bytea, key bytea, type text) returns bytea
+decrypt(data bytea, key bytea, type text) returns bytea
+
+encrypt_iv(data bytea, key bytea, iv bytea, type text) returns bytea
+decrypt_iv(data bytea, key bytea, iv bytea, type text) returns bytea

Encrypt/decrypt data using the cipher method specified by + type. The syntax of the + type string is: + +

algorithm [ - mode ] [ /pad: padding ]

+ where algorithm is one of: + +

  • bf — Blowfish

  • aes — AES (Rijndael-128)

+ and mode is one of: +

  • cbc — next block depends on previous (default) +

  • ecb — each block is encrypted separately (for + testing only) +

+ and padding is one of: +

  • pkcs — data may be any length (default) +

  • none — data must be multiple of cipher block size +

+

So, for example, these are equivalent: +

encrypt(data, 'fooz', 'bf')
+encrypt(data, 'fooz', 'bf-cbc/pad:pkcs')

+

In encrypt_iv and decrypt_iv, the + iv parameter is the initial value for the CBC mode; + it is ignored for ECB. + It is clipped or padded with zeroes if not exactly block size. + It defaults to all zeroes in the functions without this parameter. +

F.25.5. Random-Data Functions

gen_random_bytes(count integer) returns bytea

Returns count cryptographically strong random bytes. + At most 1024 bytes can be extracted at a time. This is to avoid + draining the randomness generator pool. +

F.25.6. Notes

F.25.6.1. Configuration

pgcrypto configures itself according to the findings of the + main PostgreSQL configure script. The options that + affect it are --with-zlib and + --with-openssl. +

When compiled with zlib, PGP encryption functions are able to + compress data before encrypting. +

When compiled with OpenSSL, there will be more algorithms available. + Also public-key encryption functions will be faster as OpenSSL + has more optimized BIGNUM functions. +

Table F-18. Summary of Functionality with and without OpenSSL

FunctionalityBuilt-inWith OpenSSL
MD5yesyes
SHA1yesyes
SHA224/256/384/512yesyes (Note 1)
Other digest algorithmsnoyes (Note 2)
Blowfishyesyes
AESyesyes (Note 3)
DES/3DES/CAST5noyes
Raw encryptionyesyes
PGP Symmetric encryptionyesyes
PGP Public-Key encryptionyesyes

Notes: +

  1. SHA2 algorithms were added to OpenSSL in version 0.9.8. For + older versions, pgcrypto will use built-in code. +

  2. Any digest algorithm OpenSSL supports is automatically picked up. + This is not possible with ciphers, which need to be supported + explicitly. +

  3. AES is included in OpenSSL since version 0.9.7. For + older versions, pgcrypto will use built-in code. +

F.25.6.2. NULL Handling

As is standard in SQL, all functions return NULL, if any of the arguments + are NULL. This may create security risks on careless usage. +

F.25.6.3. Security Limitations

All pgcrypto functions run inside the database server. + That means that all + the data and passwords move between pgcrypto and client + applications in clear text. Thus you must: +

  1. Connect locally or use SSL connections.

  2. Trust both system and database administrator.

If you cannot, then better do crypto inside client application. +

F.25.6.4. Useful Reading

F.25.6.5. Technical References

F.25.7. Author

Marko Kreen <markokr@gmail.com> +

pgcrypto uses code from the following sources: +

AlgorithmAuthorSource origin
DES cryptDavid Burren and othersFreeBSD libcrypt
MD5 cryptPoul-Henning KampFreeBSD libcrypt
Blowfish cryptSolar Designerwww.openwall.com
Blowfish cipherSimon TathamPuTTY
Rijndael cipherBrian GladmanOpenBSD sys/crypto
MD5 and SHA1WIDE ProjectKAME kame/sys/crypto
SHA256/384/512 Aaron D. GiffordOpenBSD sys/crypto
BIGNUM mathMichael J. Frombergerdartmouth.edu/~sting/sw/imath


PrevHomeNext
pg_buffercacheUppg_freespacemap
\ No newline at end of file diff --git a/doc/src/sgml/html/pgfreespacemap.html b/doc/src/sgml/html/pgfreespacemap.html new file mode 100644 index 000000000..4829bc334 --- /dev/null +++ b/doc/src/sgml/html/pgfreespacemap.html @@ -0,0 +1,312 @@ + +pg_freespacemap
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.26. pg_freespacemap

The pg_freespacemap module provides a means for examining the + free space map (FSM). It provides a function called + pg_freespace, or two overloaded functions, to be + precise. The functions show the value recorded in the free space map for + a given page, or for all pages in the relation. +

By default public access is revoked from the functions, just in case + there are security issues lurking. +

F.26.1. Functions

pg_freespace(rel regclass IN, blkno bigint IN) returns int2

Returns the amount of free space on the page of the relation, specified + by blkno, according to the FSM. +

pg_freespace(rel regclass IN, blkno OUT bigint, avail OUT int2)

Displays the amount of free space on each page of the relation, + according to the FSM. A set of (blkno bigint, avail int2) + tuples is returned, one tuple for each page in the relation. +

The values stored in the free space map are not exact. They're rounded + to precision of 1/256th of BLCKSZ (32 bytes with default BLCKSZ), and + they're not kept fully up-to-date as tuples are inserted and updated. +

For indexes, what is tracked is entirely-unused pages, rather than free + space within pages. Therefore, the values are not meaningful, just + whether a page is full or empty. +

NOTE: The interface was changed in version 8.4, to reflect the new FSM + implementation introduced in the same version. +

F.26.2. Sample Output

postgres=# SELECT * FROM pg_freespace('foo');
+ blkno | avail 
+-------+-------
+     0 |     0
+     1 |     0
+     2 |     0
+     3 |    32
+     4 |   704
+     5 |   704
+     6 |   704
+     7 |  1216
+     8 |   704
+     9 |   704
+    10 |   704
+    11 |   704
+    12 |   704
+    13 |   704
+    14 |   704
+    15 |   704
+    16 |   704
+    17 |   704
+    18 |   704
+    19 |  3648
+(20 rows)
+
+postgres=# SELECT * FROM pg_freespace('foo', 7);
+ pg_freespace 
+--------------
+         1216
+(1 row)

F.26.3. Author

Original version by Mark Kirkwood <markir@paradise.net.nz>. + Rewritten in version 8.4 to suit new FSM implementation by Heikki + Linnakangas <heikki@enterprisedb.com> +


PrevHomeNext
pgcryptoUppgrowlocks
\ No newline at end of file diff --git a/doc/src/sgml/html/pgrowlocks.html b/doc/src/sgml/html/pgrowlocks.html new file mode 100644 index 000000000..cef3d2716 --- /dev/null +++ b/doc/src/sgml/html/pgrowlocks.html @@ -0,0 +1,396 @@ + +pgrowlocks
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.27. pgrowlocks

The pgrowlocks module provides a function to show row + locking information for a specified table. +

F.27.1. Overview

pgrowlocks(text) returns setof record

The parameter is the name of a table. The result is a set of records, + with one row for each locked row within the table. The output columns + are shown in Table F-19. +

Table F-19. pgrowlocks Output Columns

NameTypeDescription
locked_rowtidTuple ID (TID) of locked row
lock_typetextShared for shared lock, or + Exclusive for exclusive lock
lockerxidTransaction ID of locker, or multixact ID if multitransaction
multibooleanTrue if locker is a multitransaction
xidsxid[]Transaction IDs of lockers (more than one if multitransaction)
pidsinteger[]Process IDs of locking backends (more than one if multitransaction)

pgrowlocks takes AccessShareLock for the + target table and reads each row one by one to collect the row locking + information. This is not very speedy for a large table. Note that: +

  1. If the table as a whole is exclusive-locked by someone else, + pgrowlocks will be blocked. +

  2. pgrowlocks is not guaranteed to produce a + self-consistent snapshot. It is possible that a new row lock is taken, + or an old lock is freed, during its execution. +

pgrowlocks does not show the contents of locked + rows. If you want to take a look at the row contents at the same time, you + could do something like this: + +

SELECT * FROM accounts AS a, pgrowlocks('accounts') AS p
+  WHERE p.locked_row = a.ctid;

+ + Be aware however that (as of PostgreSQL 8.3) such a + query will be very inefficient. +

F.27.2. Sample Output

test=# SELECT * FROM pgrowlocks('t1');
+ locked_row | lock_type | locker | multi |   xids    |     pids
+------------+-----------+--------+-------+-----------+---------------
+      (0,1) | Shared    |     19 | t     | {804,805} | {29066,29068}
+      (0,2) | Shared    |     19 | t     | {804,805} | {29066,29068}
+      (0,3) | Exclusive |    804 | f     | {804}     | {29066}
+      (0,4) | Exclusive |    804 | f     | {804}     | {29066}
+(4 rows)

F.27.3. Author

Tatsuo Ishii +


PrevHomeNext
pg_freespacemapUppg_stat_statements
\ No newline at end of file diff --git a/doc/src/sgml/html/pgstandby.html b/doc/src/sgml/html/pgstandby.html new file mode 100644 index 000000000..66e2046bf --- /dev/null +++ b/doc/src/sgml/html/pgstandby.html @@ -0,0 +1,897 @@ + +pg_standby

pg_standby

Name

pg_standby -- supports the creation of a PostgreSQL warm standby server

Synopsis

pg_standby [option...] archivelocation nextwalfile xlogfilepath [restartwalfile]

Description

pg_standby supports creation of a "warm standby" + database server. It is designed to be a production-ready program, as well + as a customizable template should you require specific modifications. +

pg_standby is designed to be a waiting + restore_command, which is needed to turn a standard + archive recovery into a warm standby operation. Other + configuration is required as well, all of which is described in the main + server manual (see Section 25.2). +

To configure a standby + server to use pg_standby, put this into its + recovery.conf configuration file: +

restore_command = 'pg_standby archiveDir %f %p %r'

+ where archiveDir is the directory from which WAL segment + files should be restored. +

If restartwalfile is specified, normally by using the + %r macro, then all WAL files logically preceding this + file will be removed from archivelocation. This minimizes + the number of files that need to be retained, while preserving + crash-restart capability. Use of this parameter is appropriate if the + archivelocation is a transient staging area for this + particular standby server, but not when the + archivelocation is intended as a long-term WAL archive area. +

pg_standby assumes that + archivelocation is a directory readable by the + server-owning user. If restartwalfile (or -k) + is specified, + the archivelocation directory must be writable too. +

There are two ways to fail over to a "warm standby" database server + when the master server fails: + +

Smart Failover

In smart failover, the server is brought up after applying all WAL + files available in the archive. This results in zero data loss, even if + the standby server has fallen behind, but if there is a lot of + unapplied WAL it can be a long time before the standby server becomes + ready. To trigger a smart failover, create a trigger file containing + the word smart, or just create it and leave it empty. +

Fast Failover

In fast failover, the server is brought up immediately. Any WAL files + in the archive that have not yet been applied will be ignored, and + all transactions in those files are lost. To trigger a fast failover, + create a trigger file and write the word fast into it. + pg_standby can also be configured to execute a fast + failover automatically if no new WAL file appears within a defined + interval. +

+

Options

pg_standby accepts the following command-line arguments: + +

-c

Use cp or copy command to restore WAL files + from archive. This is the only supported behavior so this option is useless. +

-d

Print lots of debug logging output on stderr. +

-k

Remove files from archivelocation so that + no more than this many WAL files before the current one are kept in the + archive. Zero (the default) means not to remove any files from + archivelocation. + This parameter will be silently ignored if + restartwalfile is specified, since that + specification method is more accurate in determining the correct + archive cut-off point. + Use of this parameter is deprecated as of + PostgreSQL 8.3; it is safer and more efficient to + specify a restartwalfile parameter. A too + small setting could result in removal of files that are still needed + for a restart of the standby server, while a too large setting wastes + archive space. +

-r maxretries

Set the maximum number of times to retry the copy command if + it fails (default 3). After each failure, we wait for + sleeptime * num_retries + so that the wait time increases progressively. So by default, + we will wait 5 secs, 10 secs, then 15 secs before reporting + the failure back to the standby server. This will be + interpreted as end of recovery and the standby will come + up fully as a result. +

-s sleeptime

Set the number of seconds (up to 60, default 5) to sleep between + tests to see if the WAL file to be restored is available in + the archive yet. The default setting is not necessarily + recommended; consult Section 25.2 for discussion. +

-t triggerfile

Specify a trigger file whose presence should cause failover. + It is recommended that you use a structured file name to + avoid confusion as to which server is being triggered + when multiple servers exist on the same system; for example + /tmp/pgsql.trigger.5432. +

-V
--version

Print the pg_standby version and exit. +

-w maxwaittime

Set the maximum number of seconds to wait for the next WAL file, + after which a fast failover will be performed. + A setting of zero (the default) means wait forever. + The default setting is not necessarily recommended; + consult Section 25.2 for discussion. +

-?
--help

Show help about pg_standby command line + arguments, and exit. +

+

Notes

pg_standby is designed to work with + PostgreSQL 8.2 and later. +

PostgreSQL 8.3 provides the %r macro, + which is designed to let pg_standby know the + last file it needs to keep. With PostgreSQL 8.2, the + -k option must be used if archive cleanup is + required. This option remains available in 8.3, but its use is deprecated. +

PostgreSQL 8.4 provides the + recovery_end_command option. Without this option + a leftover trigger file can be hazardous. +

pg_standby is written in C and has an + easy-to-modify source code, with specifically designated sections to modify + for your own needs +

Examples

On Linux or Unix systems, you might use: + +

archive_command = 'cp %p .../archive/%f'
+
+restore_command = 'pg_standby -d -s 2 -t /tmp/pgsql.trigger.5442 .../archive %f %p %r 2>>standby.log'
+
+recovery_end_command = 'rm -f /tmp/pgsql.trigger.5442'

+ where the archive directory is physically located on the standby server, + so that the archive_command is accessing it across NFS, + but the files are local to the standby (enabling use of ln). + This will: +

  • produce debugging output in standby.log +

  • sleep for 2 seconds between checks for next WAL file availability +

  • stop waiting only when a trigger file called + /tmp/pgsql.trigger.5442 appears, + and perform failover according to its content +

  • remove the trigger file when recovery ends +

  • remove no-longer-needed files from the archive directory +

+

On Windows, you might use: + +

archive_command = 'copy %p ...\\archive\\%f'
+
+restore_command = 'pg_standby -d -s 5 -t C:\pgsql.trigger.5442 ...\archive %f %p %r 2>>standby.log'
+
+recovery_end_command = 'del C:\pgsql.trigger.5442'

+ Note that backslashes need to be doubled in the + archive_command, but not in the + restore_command or recovery_end_command. + This will: +

  • use the copy command to restore WAL files from archive +

  • produce debugging output in standby.log +

  • sleep for 5 seconds between checks for next WAL file availability +

  • stop waiting only when a trigger file called + C:\pgsql.trigger.5442 appears, + and perform failover according to its content +

  • remove the trigger file when recovery ends +

  • remove no-longer-needed files from the archive directory +

+

The copy command on Windows sets the final file size + before the file is completely copied, which would ordinarily confuse + pg_standby. Therefore + pg_standby waits sleeptime + seconds once it sees the proper file size. GNUWin32's cp + sets the file size only after the file copy is complete. +

Since the Windows example uses copy at both ends, either + or both servers might be accessing the archive directory across the + network. +

Author

Simon Riggs <simon@2ndquadrant.com> +


PrevHomeNext
pg_archivecleanupUppg_test_fsync
\ No newline at end of file diff --git a/doc/src/sgml/html/pgstatstatements.html b/doc/src/sgml/html/pgstatstatements.html new file mode 100644 index 000000000..53452ecbb --- /dev/null +++ b/doc/src/sgml/html/pgstatstatements.html @@ -0,0 +1,933 @@ + +pg_stat_statements
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.28. pg_stat_statements

The pg_stat_statements module provides a means for + tracking execution statistics of all SQL statements executed by a server. +

The module must be loaded by adding pg_stat_statements to + shared_preload_libraries in + postgresql.conf, because it requires additional shared memory. + This means that a server restart is needed to add or remove the module. +

F.28.1. The pg_stat_statements View

The statistics gathered by the module are made available via a system view + named pg_stat_statements. This view contains one row for + each distinct query, database ID, and user ID (up to the maximum + number of distinct statements that the module can track). The columns + of the view are shown in Table F-20. +

Table F-20. pg_stat_statements Columns

NameTypeReferencesDescription
useridoidpg_authid.oidOID of user who executed the statement
dbidoidpg_database.oidOID of database in which the statement was executed
querytext Text of a representative statement (up to track_activity_query_size bytes)
callsbigint Number of times executed
total_timedouble precision Total time spent in the statement, in milliseconds
rowsbigint Total number of rows retrieved or affected by the statement
shared_blks_hitbigint Total number of shared block cache hits by the statement
shared_blks_readbigint Total number of shared blocks read by the statement
shared_blks_dirtiedbigint Total number of shared blocks dirtied by the statement
shared_blks_writtenbigint Total number of shared blocks written by the statement
local_blks_hitbigint Total number of local block cache hits by the statement
local_blks_readbigint Total number of local blocks read by the statement
local_blks_dirtiedbigint Total number of local blocks dirtied by the statement
local_blks_writtenbigint Total number of local blocks written by the statement
temp_blks_readbigint Total number of temp blocks read by the statement
temp_blks_writtenbigint Total number of temp blocks written by the statement
blk_read_timedouble precision  Total time the statement spent reading blocks, in milliseconds + (if track_io_timing is enabled, otherwise zero) +
blk_write_timedouble precision  Total time the statement spent writing blocks, in milliseconds + (if track_io_timing is enabled, otherwise zero) +

This view, and the function pg_stat_statements_reset, + are available only in databases they have been specifically installed into + by installing the pg_stat_statements extension. + However, statistics are tracked across all databases of the server + whenever the pg_stat_statements module is loaded + into the server, regardless of presence of the view. +

For security reasons, non-superusers are not allowed to see the text of + queries executed by other users. They can see the statistics, however, + if the view has been installed in their database. +

Plannable queries (that is, SELECT, INSERT, + UPDATE, and DELETE) are combined into a single + pg_stat_statements entry whenever they have identical query + structures according to an internal hash calculation. Typically, two + queries will be considered the same for this purpose if they are + semantically equivalent except for the values of literal constants + appearing in the query. Utility commands (that is, all other commands) + are compared strictly on the basis of their textual query strings, however. +

When a constant's value has been ignored for purposes of matching the + query to other queries, the constant is replaced by ? + in the pg_stat_statements display. The rest of the query + text is that of the first query that had the particular hash value + associated with the pg_stat_statements entry. +

In some cases, queries with visibly different texts might get merged into a + single pg_stat_statements entry. Normally this will happen + only for semantically equivalent queries, but there is a small chance of + hash collisions causing unrelated queries to be merged into one entry. + (This cannot happen for queries belonging to different users or databases, + however.) +

Since the hash value is computed on the post-parse-analysis representation + of the queries, the opposite is also possible: queries with identical texts + might appear as separate entries, if they have different meanings as a + result of factors such as different search_path settings. +

F.28.2. Functions

pg_stat_statements_reset() returns void

pg_stat_statements_reset discards all statistics + gathered so far by pg_stat_statements. + By default, this function can only be executed by superusers. +

F.28.3. Configuration Parameters

pg_stat_statements.max (integer)

pg_stat_statements.max is the maximum number of + statements tracked by the module (i.e., the maximum number of rows + in the pg_stat_statements view). If more distinct + statements than that are observed, information about the least-executed + statements is discarded. + The default value is 1000. + This parameter can only be set at server start. +

pg_stat_statements.track (enum)

pg_stat_statements.track controls which statements + are counted by the module. + Specify top to track top-level statements (those issued + directly by clients), all to also track nested statements + (such as statements invoked within functions), or none to + disable statement statistics collection. + The default value is top. + Only superusers can change this setting. +

pg_stat_statements.track_utility (boolean)

pg_stat_statements.track_utility controls whether + utility commands are tracked by the module. Utility commands are + all those other than SELECT, INSERT, + UPDATE and DELETE. + The default value is on. + Only superusers can change this setting. +

pg_stat_statements.save (boolean)

pg_stat_statements.save specifies whether to + save statement statistics across server shutdowns. + If it is off then statistics are not saved at + shutdown nor reloaded at server start. + The default value is on. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

The module requires additional shared memory amounting to about + pg_stat_statements.max * + track_activity_query_size bytes. Note that this + memory is consumed whenever the module is loaded, even if + pg_stat_statements.track is set to none. +

These parameters must be set in postgresql.conf. + Typical usage might be: + +

# postgresql.conf
+shared_preload_libraries = 'pg_stat_statements'
+
+pg_stat_statements.max = 10000
+pg_stat_statements.track = all

+

F.28.4. Sample Output

bench=# SELECT pg_stat_statements_reset();
+
+$ pgbench -i bench
+$ pgbench -c10 -t300 bench
+
+bench=# \x
+bench=# SELECT query, calls, total_time, rows, 100.0 * shared_blks_hit /
+               nullif(shared_blks_hit + shared_blks_read, 0) AS hit_percent
+          FROM pg_stat_statements ORDER BY total_time DESC LIMIT 5;
+-[ RECORD 1 ]---------------------------------------------------------------------
+query       | UPDATE pgbench_branches SET bbalance = bbalance + ? WHERE bid = ?;
+calls       | 3000
+total_time  | 9609.00100000002
+rows        | 2836
+hit_percent | 99.9778970000200936
+-[ RECORD 2 ]---------------------------------------------------------------------
+query       | UPDATE pgbench_tellers SET tbalance = tbalance + ? WHERE tid = ?;
+calls       | 3000
+total_time  | 8015.156
+rows        | 2990
+hit_percent | 99.9731126579631345
+-[ RECORD 3 ]---------------------------------------------------------------------
+query       | copy pgbench_accounts from stdin
+calls       | 1
+total_time  | 310.624
+rows        | 100000
+hit_percent | 0.30395136778115501520
+-[ RECORD 4 ]---------------------------------------------------------------------
+query       | UPDATE pgbench_accounts SET abalance = abalance + ? WHERE aid = ?;
+calls       | 3000
+total_time  | 271.741999999997
+rows        | 3000
+hit_percent | 93.7968855088209426
+-[ RECORD 5 ]---------------------------------------------------------------------
+query       | alter table pgbench_accounts add primary key (aid)
+calls       | 1
+total_time  | 81.42
+rows        | 0
+hit_percent | 34.4947735191637631

F.28.5. Authors

Takahiro Itagaki <itagaki.takahiro@oss.ntt.co.jp>. + Query normalization added by Peter Geoghegan <peter@2ndquadrant.com>. +


PrevHomeNext
pgrowlocksUppgstattuple
\ No newline at end of file diff --git a/doc/src/sgml/html/pgstattuple.html b/doc/src/sgml/html/pgstattuple.html new file mode 100644 index 000000000..2dcf6b9fd --- /dev/null +++ b/doc/src/sgml/html/pgstattuple.html @@ -0,0 +1,651 @@ + +pgstattuple
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.29. pgstattuple

The pgstattuple module provides various functions to + obtain tuple-level statistics. +

F.29.1. Functions

pgstattuple(text) returns record

pgstattuple returns a relation's physical length, + percentage of "dead" tuples, and other info. This may help users + to determine whether vacuum is necessary or not. The argument is the + target relation's name (optionally schema-qualified). + For example: +

test=> SELECT * FROM pgstattuple('pg_catalog.pg_proc');
+-[ RECORD 1 ]------+-------
+table_len          | 458752
+tuple_count        | 1470
+tuple_len          | 438896
+tuple_percent      | 95.67
+dead_tuple_count   | 11
+dead_tuple_len     | 3157
+dead_tuple_percent | 0.69
+free_space         | 8932
+free_percent       | 1.95

+ The output columns are described in Table F-21. +

Table F-21. pgstattuple Output Columns

ColumnTypeDescription
table_lenbigintPhysical relation length in bytes
tuple_countbigintNumber of live tuples
tuple_lenbigintTotal length of live tuples in bytes
tuple_percentfloat8Percentage of live tuples
dead_tuple_countbigintNumber of dead tuples
dead_tuple_lenbigintTotal length of dead tuples in bytes
dead_tuple_percentfloat8Percentage of dead tuples
free_spacebigintTotal free space in bytes
free_percentfloat8Percentage of free space

pgstattuple acquires only a read lock on the + relation. So the results do not reflect an instantaneous snapshot; + concurrent updates will affect them. +

pgstattuple judges a tuple is "dead" if + HeapTupleSatisfiesNow returns false. +

pgstattuple(oid) returns record

This is the same as pgstattuple(text), except + that the target relation is specified by OID. +

pgstatindex(text) returns record

pgstatindex returns a record showing information + about a B-tree index. For example: +

test=> SELECT * FROM pgstatindex('pg_cast_oid_index');
+-[ RECORD 1 ]------+------
+version            | 2
+tree_level         | 0
+index_size         | 8192
+root_block_no      | 1
+internal_pages     | 0
+leaf_pages         | 1
+empty_pages        | 0
+deleted_pages      | 0
+avg_leaf_density   | 50.27
+leaf_fragmentation | 0

+

The output columns are: + +

ColumnTypeDescription
versionintegerB-tree version number
tree_levelintegerTree level of the root page
index_sizebigintTotal number of pages in index
root_block_nobigintLocation of root block
internal_pagesbigintNumber of "internal" (upper-level) pages
leaf_pagesbigintNumber of leaf pages
empty_pagesbigintNumber of empty pages
deleted_pagesbigintNumber of deleted pages
avg_leaf_densityfloat8Average density of leaf pages
leaf_fragmentationfloat8Leaf page fragmentation

+

As with pgstattuple, the results are accumulated + page-by-page, and should not be expected to represent an + instantaneous snapshot of the whole index. +

pg_relpages(text) returns bigint

pg_relpages returns the number of pages in the + relation. +

F.29.2. Authors

Tatsuo Ishii and Satoshi Nagayasu +


PrevHomeNext
pg_stat_statementsUppg_trgm
\ No newline at end of file diff --git a/doc/src/sgml/html/pgtestfsync.html b/doc/src/sgml/html/pgtestfsync.html new file mode 100644 index 000000000..5f2ee565a --- /dev/null +++ b/doc/src/sgml/html/pgtestfsync.html @@ -0,0 +1,358 @@ + +pg_test_fsync

pg_test_fsync

Name

pg_test_fsync -- determine fastest wal_sync_method for PostgreSQL

Synopsis

pg_test_fsync [option...]

Description

pg_test_fsync is intended to give you a reasonable + idea of what the fastest wal_sync_method is on your + specific system, + as well as supplying diagnostic information in the event of an + identified I/O problem. However, differences shown by pg_test_fsync + might not make any difference in real database throughput, especially + since many database servers are not speed-limited by their transaction + logs. +

Options

pg_test_fsync accepts the following + command-line options: + +

-f
--filename

Specifies the file name to write test data in. + This file should be in the same file system that the + pg_xlog directory is or will be placed in. + (pg_xlog contains the WAL files.) + The default is pg_test_fsync.out in the current + directory. +

-s
--secs-per-test

Specifies the number of seconds for each test. The more time + per test, the greater the test's accuracy, but the longer it takes + to run. The default is 2 seconds, which allows the program to + complete in about 30 seconds. +

-V
--version

Print the pg_test_fsync version and exit. +

-?
--help

Show help about pg_test_fsync command line + arguments, and exit. +

+

Author

Bruce Momjian <bruce@momjian.us> +

See Also

postgres

PrevHomeNext
pg_standbyUppg_test_timing
\ No newline at end of file diff --git a/doc/src/sgml/html/pgtesttiming.html b/doc/src/sgml/html/pgtesttiming.html new file mode 100644 index 000000000..941c54bd2 --- /dev/null +++ b/doc/src/sgml/html/pgtesttiming.html @@ -0,0 +1,552 @@ + +pg_test_timing

pg_test_timing

Name

pg_test_timing -- measure timing overhead

Synopsis

pg_test_timing [option...]

Description

pg_test_timing is a tool to measure the timing overhead + on your system and confirm that the system time never moves backwards. + Systems that are slow to collect timing data can give less accurate + EXPLAIN ANALYZE results. +

Options

pg_test_timing accepts the following + command-line options: + +

-d duration
--duration=duration

Specifies the test duration, in seconds. Longer durations + give slightly better accuracy, and are more likely to discover + problems with the system clock moving backwards. The default + test duration is 3 seconds. +

-V
--version

Print the pg_test_timing version and exit. +

-?
--help

Show help about pg_test_timing command line + arguments, and exit. +

+

Usage

Interpreting results

Good results will show most (>90%) individual timing calls take less than + one microsecond. Average per loop overhead will be even lower, below 100 + nanoseconds. This example from an Intel i7-860 system using a TSC clock + source shows excellent performance: + +

Testing timing overhead for 3 seconds.
+Per loop time including overhead: 35.96 nsec
+Histogram of timing durations:
+   < usec:      count   percent
+       16:          2  0.00000%
+        8:         13  0.00002%
+        4:        126  0.00015%
+        2:    2999652  3.59518%
+        1:   80435604 96.40465%

+

Note that different units are used for the per loop time than the + histogram. The loop can have resolution within a few nanoseconds (nsec), + while the individual timing calls can only resolve down to one microsecond + (usec). +

Measuring executor timing overhead

When the query executor is running a statement using + EXPLAIN ANALYZE, individual operations are timed as well + as showing a summary. The overhead of your system can be checked by + counting rows with the psql program: + +

CREATE TABLE t AS SELECT * FROM generate_series(1,100000);
+\timing
+SELECT COUNT(*) FROM t;
+EXPLAIN ANALYZE SELECT COUNT(*) FROM t;

+

The i7-860 system measured runs the count query in 9.8 ms while + the EXPLAIN ANALYZE version takes 16.6 ms, each + processing just over 100,000 rows. That 6.8 ms difference means the timing + overhead per row is 68 ns, about twice what pg_test_timing estimated it + would be. Even that relatively small amount of overhead is making the fully + timed count statement take almost 70% longer. On more substantial queries, + the timing overhead would be less problematic. +

Changing time sources

On some newer Linux systems, it's possible to change the clock source used + to collect timing data at any time. A second example shows the slowdown + possible from switching to the slower acpi_pm time source, on the same + system used for the fast results above: + +

# cat /sys/devices/system/clocksource/clocksource0/available_clocksource
+tsc hpet acpi_pm
+# echo acpi_pm > /sys/devices/system/clocksource/clocksource0/current_clocksource
+# pg_test_timing
+Per loop time including overhead: 722.92 nsec
+Histogram of timing durations:
+   < usec:      count   percent
+       16:          3  0.00007%
+        8:        563  0.01357%
+        4:       3241  0.07810%
+        2:    2990371 72.05956%
+        1:    1155682 27.84870%

+

In this configuration, the sample EXPLAIN ANALYZE above + takes 115.9 ms. That's 1061 nsec of timing overhead, again a small multiple + of what's measured directly by this utility. That much timing overhead + means the actual query itself is only taking a tiny fraction of the + accounted for time, most of it is being consumed in overhead instead. In + this configuration, any EXPLAIN ANALYZE totals involving + many timed operations would be inflated significantly by timing overhead. +

FreeBSD also allows changing the time source on the fly, and it logs + information about the timer selected during boot: + +

dmesg | grep "Timecounter"
+sysctl kern.timecounter.hardware=TSC

+

Other systems may only allow setting the time source on boot. On older + Linux systems the "clock" kernel setting is the only way to make this sort + of change. And even on some more recent ones, the only option you'll see + for a clock source is "jiffies". Jiffies are the older Linux software clock + implementation, which can have good resolution when it's backed by fast + enough timing hardware, as in this example: + +

$ cat /sys/devices/system/clocksource/clocksource0/available_clocksource
+jiffies
+$ dmesg | grep time.c
+time.c: Using 3.579545 MHz WALL PM GTOD PIT/TSC timer.
+time.c: Detected 2400.153 MHz processor.
+$ pg_test_timing
+Testing timing overhead for 3 seconds.
+Per timing duration including loop overhead: 97.75 ns
+Histogram of timing durations:
+   < usec:      count   percent
+       32:          1  0.00000%
+       16:          1  0.00000%
+        8:         22  0.00007%
+        4:       3010  0.00981%
+        2:    2993204  9.75277%
+        1:   27694571 90.23734%

Clock hardware and timing accuracy

Collecting accurate timing information is normally done on computers using + hardware clocks with various levels of accuracy. With some hardware the + operating systems can pass the system clock time almost directly to + programs. A system clock can also be derived from a chip that simply + provides timing interrupts, periodic ticks at some known time interval. In + either case, operating system kernels provide a clock source that hides + these details. But the accuracy of that clock source and how quickly it can + return results varies based on the underlying hardware. +

Inaccurate time keeping can result in system instability. Test any change + to the clock source very carefully. Operating system defaults are sometimes + made to favor reliability over best accuracy. And if you are using a virtual + machine, look into the recommended time sources compatible with it. Virtual + hardware faces additional difficulties when emulating timers, and there are + often per operating system settings suggested by vendors. +

The Time Stamp Counter (TSC) clock source is the most accurate one available + on current generation CPUs. It's the preferred way to track the system time + when it's supported by the operating system and the TSC clock is + reliable. There are several ways that TSC can fail to provide an accurate + timing source, making it unreliable. Older systems can have a TSC clock that + varies based on the CPU temperature, making it unusable for timing. Trying + to use TSC on some older multicore CPUs can give a reported time that's + inconsistent among multiple cores. This can result in the time going + backwards, a problem this program checks for. And even the newest systems + can fail to provide accurate TSC timing with very aggressive power saving + configurations. +

Newer operating systems may check for the known TSC problems and switch to a + slower, more stable clock source when they are seen. If your system + supports TSC time but doesn't default to that, it may be disabled for a good + reason. And some operating systems may not detect all the possible problems + correctly, or will allow using TSC even in situations where it's known to be + inaccurate. +

The High Precision Event Timer (HPET) is the preferred timer on systems + where it's available and TSC is not accurate. The timer chip itself is + programmable to allow up to 100 nanosecond resolution, but you may not see + that much accuracy in your system clock. +

Advanced Configuration and Power Interface (ACPI) provides a Power + Management (PM) Timer, which Linux refers to as the acpi_pm. The clock + derived from acpi_pm will at best provide 300 nanosecond resolution. +

Timers used on older PC hardware including the 8254 Programmable Interval + Timer (PIT), the real-time clock (RTC), the Advanced Programmable Interrupt + Controller (APIC) timer, and the Cyclone timer. These timers aim for + millisecond resolution. +

Author

Ants Aasma <ants.aasma@eesti.ee> +

See Also

EXPLAIN

PrevHomeNext
pg_test_fsyncUppg_upgrade
\ No newline at end of file diff --git a/doc/src/sgml/html/pgtrgm.html b/doc/src/sgml/html/pgtrgm.html new file mode 100644 index 000000000..892e013de --- /dev/null +++ b/doc/src/sgml/html/pgtrgm.html @@ -0,0 +1,707 @@ + +pg_trgm
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.30. pg_trgm

The pg_trgm module provides functions and operators + for determining the similarity of ASCII + alphanumeric text based on trigram matching, as + well as index operator classes that support fast searching for similar + strings. +

F.30.1. Trigram (or Trigraph) Concepts

A trigram is a group of three consecutive characters taken + from a string. We can measure the similarity of two strings by + counting the number of trigrams they share. This simple idea + turns out to be very effective for measuring the similarity of + words in many natural languages. +

Note: A string is considered to have two spaces + prefixed and one space suffixed when determining the set + of trigrams contained in the string. + For example, the set of trigrams in the string + "cat" is + " c", + " ca", + "cat", and + "at ". +

F.30.2. Functions and Operators

The functions provided by the pg_trgm module + are shown in Table F-22, the operators + in Table F-23. +

Table F-22. pg_trgm Functions

FunctionReturnsDescription
similarity(text, text)real Returns a number that indicates how similar the two arguments are. + The range of the result is zero (indicating that the two strings are + completely dissimilar) to one (indicating that the two strings are + identical). +
show_trgm(text)text[] Returns an array of all the trigrams in the given string. + (In practice this is seldom useful except for debugging.) +
show_limit()real Returns the current similarity threshold used by the % + operator. This sets the minimum similarity between + two words for them to be considered similar enough to + be misspellings of each other, for example. +
set_limit(real)real Sets the current similarity threshold that is used by the % + operator. The threshold must be between 0 and 1 (default is 0.3). + Returns the same value passed in. +

Table F-23. pg_trgm Operators

OperatorReturnsDescription
text % textboolean Returns true if its arguments have a similarity that is + greater than the current similarity threshold set by + set_limit. +
text <-> textreal Returns the "distance" between the arguments, that is + one minus the similarity() value. +

F.30.3. Index Support

The pg_trgm module provides GiST and GIN index + operator classes that allow you to create an index over a text column for + the purpose of very fast similarity searches. These index types support + the above-described similarity operators, and additionally support + trigram-based index searches for LIKE and ILIKE + queries. (These indexes do not support equality nor simple comparison + operators, so you may need a regular B-tree index too.) +

Example: + +

CREATE TABLE test_trgm (t text);
+CREATE INDEX trgm_idx ON test_trgm USING gist (t gist_trgm_ops);

+or +

CREATE INDEX trgm_idx ON test_trgm USING gin (t gin_trgm_ops);

+

At this point, you will have an index on the t column that + you can use for similarity searching. A typical query is +

SELECT t, similarity(t, 'word') AS sml
+  FROM test_trgm
+  WHERE t % 'word'
+  ORDER BY sml DESC, t;

+ This will return all values in the text column that are sufficiently + similar to word, sorted from best match to worst. The + index will be used to make this a fast operation even over very large data + sets. +

A variant of the above query is +

SELECT t, t <-> 'word' AS dist
+  FROM test_trgm
+  ORDER BY dist LIMIT 10;

+ This can be implemented quite efficiently by GiST indexes, but not + by GIN indexes. It will usually beat the first formulation when only + a small number of the closest matches is wanted. +

Beginning in PostgreSQL 9.1, these index types also support + index searches for LIKE and ILIKE, for example +

SELECT * FROM test_trgm WHERE t LIKE '%foo%bar';

+ The index search works by extracting trigrams from the search string + and then looking these up in the index. The more trigrams in the search + string, the more effective the index search is. Unlike B-tree based + searches, the search string need not be left-anchored. +

The choice between GiST and GIN indexing depends on the relative + performance characteristics of GiST and GIN, which are discussed elsewhere. + As a rule of thumb, a GIN index is faster to search than a GiST index, but + slower to build or update; so GIN is better suited for static data and GiST + for often-updated data. +

F.30.4. Text Search Integration

Trigram matching is a very useful tool when used in conjunction + with a full text index. In particular it can help to recognize + misspelled input words that will not be matched directly by the + full text search mechanism. +

The first step is to generate an auxiliary table containing all + the unique words in the documents: + +

CREATE TABLE words AS SELECT word FROM
+        ts_stat('SELECT to_tsvector(''simple'', bodytext) FROM documents');

+ + where documents is a table that has a text field + bodytext that we wish to search. The reason for using + the simple configuration with the to_tsvector + function, instead of using a language-specific configuration, + is that we want a list of the original (unstemmed) words. +

Next, create a trigram index on the word column: + +

CREATE INDEX words_idx ON words USING gin(word gin_trgm_ops);

+ + Now, a SELECT query similar to the previous example can + be used to suggest spellings for misspelled words in user search terms. + A useful extra test is to require that the selected words are also of + similar length to the misspelled word. +

Note: Since the words table has been generated as a separate, + static table, it will need to be periodically regenerated so that + it remains reasonably up-to-date with the document collection. + Keeping it exactly current is usually unnecessary. +

F.30.6. Authors

Oleg Bartunov <oleg@sai.msu.su>, Moscow, Moscow University, Russia +

Teodor Sigaev <teodor@sigaev.ru>, Moscow, Delta-Soft Ltd.,Russia +

Documentation: Christopher Kings-Lynne +

This module is sponsored by Delta-Soft Ltd., Moscow, Russia. +


PrevHomeNext
pgstattupleUpseg
\ No newline at end of file diff --git a/doc/src/sgml/html/pgupgrade.html b/doc/src/sgml/html/pgupgrade.html new file mode 100644 index 000000000..6251b7cc3 --- /dev/null +++ b/doc/src/sgml/html/pgupgrade.html @@ -0,0 +1,1422 @@ + +pg_upgrade

pg_upgrade

Name

pg_upgrade -- upgrade a PostgreSQL server instance

Synopsis

pg_upgrade -b oldbindir -B newbindir -d olddatadir -D newdatadir [option...]

Description

pg_upgrade (formerly called pg_migrator) allows data + stored in PostgreSQL data files to be upgraded to a later PostgreSQL + major version without the data dump/reload typically required for + major version upgrades, e.g. from 8.4.7 to the current major release + of PostgreSQL. It is not required for minor version upgrades, e.g. from + 9.0.1 to 9.0.4. +

Major PostgreSQL releases regularly add new features that often + change the layout of the system tables, but the internal data storage + format rarely changes. pg_upgrade uses this fact + to perform rapid upgrades by creating new system tables and simply + reusing the old user data files. If a future major release ever + changes the data storage format in a way that makes the old data + format unreadable, pg_upgrade will not be usable + for such upgrades. (The community will attempt to avoid such + situations.) +

pg_upgrade does its best to + make sure the old and new clusters are binary-compatible, e.g. by + checking for compatible compile-time settings, including 32/64-bit + binaries. It is important that + any external modules are also binary compatible, though this cannot + be checked by pg_upgrade. +

pg_upgrade supports upgrades from 8.3.X and later to the current + major release of PostgreSQL, including snapshot and alpha releases. +

Options

pg_upgrade accepts the following command-line arguments: + +

-b old_bindir
--old-bindir=old_bindir

the old cluster executable directory; + environment variable PGBINOLD

-B new_bindir
--new-bindir=new_bindir

the new cluster executable directory; + environment variable PGBINNEW

-c
--check

check clusters only, don't change any data

-d old_datadir
--old-datadir=old_datadir

the old cluster data directory; environment + variable PGDATAOLD

-D new_datadir
--new-datadir=new_datadir

the new cluster data directory; environment + variable PGDATANEW

-k
--link

use hard links instead of copying files to the new cluster

-o options
--old-options options

options to be passed directly to the + old postgres command

-O options
--new-options options

options to be passed directly to the + new postgres command

-p old_port_number
--old-port=old_portnum

the old cluster port number; environment + variable PGPORTOLD

-P new_port_number
--new-port=new_portnum

the new cluster port number; environment + variable PGPORTNEW

-r
--retain

retain SQL and log files even after successful completion +

-u user_name
--user=user_name

cluster's super user name; environment + variable PGUSER

-v
--verbose

enable verbose internal logging

-V
--version

display version information, then exit

-?
-h
--help

show help, then exit

+

Usage

These are the steps to perform an upgrade + with pg_upgrade: +

  1. Optionally move the old cluster

    If you are using a version-specific installation directory, e.g. + /opt/PostgreSQL/9.1, you do not need to move the old cluster. The + one-click installers all use version-specific installation directories. +

    If your installation directory is not version-specific, e.g. + /usr/local/pgsql, it is necessary to move the current PostgreSQL install + directory so it does not interfere with the new PostgreSQL installation. + Once the current PostgreSQL server is shut down, it is safe to rename the + PostgreSQL installation directory; assuming the old directory is + /usr/local/pgsql, you can do: + +

    mv /usr/local/pgsql /usr/local/pgsql.old

    + to rename the directory. +

  2. For source installs, build the new version

    Build the new PostgreSQL source with configure flags that are compatible + with the old cluster. pg_upgrade will check pg_controldata to make + sure all settings are compatible before starting the upgrade. +

  3. Install the new PostgreSQL binaries

    Install the new server's binaries and support files. +

    For source installs, if you wish to install the new server in a custom + location, use the prefix variable: + +

    gmake prefix=/usr/local/pgsql.new install

  4. Install pg_upgrade and pg_upgrade_support

    Install the pg_upgrade binary and + pg_upgrade_support library in the new PostgreSQL cluster. +

  5. Initialize the new PostgreSQL cluster

    Initialize the new cluster using initdb. + Again, use compatible initdb + flags that match the old cluster. Many + prebuilt installers do this step automatically. There is no need to + start the new cluster. +

  6. Install custom shared object files

    Install any custom shared object files (or DLLs) used by the old cluster + into the new cluster, e.g. pgcrypto.so, + whether they are from contrib + or some other source. Do not install the schema definitions, e.g. + pgcrypto.sql, because these will be upgraded from the old cluster. +

  7. Adjust authentication

    pg_upgrade will connect to the old and new servers several times, + so you might want to set authentication to trust in + pg_hba.conf, or if using md5 authentication, + use a ~/.pgpass file (see Section 31.15) + to avoid being prompted repeatedly for a password. +

  8. Stop both servers

    Make sure both database servers are stopped using, on Unix, e.g.: + +

    pg_ctl -D /opt/PostgreSQL/8.4 stop
    +pg_ctl -D /opt/PostgreSQL/9.0 stop

    + + or on Windows, using the proper service names: + +

    NET STOP postgresql-8.4
    +NET STOP postgresql-9.0

    + + or + +

    NET STOP pgsql-8.3  (PostgreSQL 8.3 and older used a different service name)

  9. Run pg_upgrade

    Always run the pg_upgrade binary of the new server, not the old one. + pg_upgrade requires the specification of the old and new cluster's + data and executable (bin) directories. You can also specify + user and port values, and whether you want the data linked instead of + copied (the default). +

    If you use link mode, the upgrade will be much faster (no file + copying), but you will not be able to access your old cluster + once you start the new cluster after the upgrade. Link mode also + requires that the old and new cluster data directories be in the + same file system. See pg_upgrade --help for a full + list of options. +

    For Windows users, you must be logged into an administrative account, and + then start a shell as the postgres user and set the proper path: + +

    RUNAS /USER:postgres "CMD.EXE"
    +SET PATH=%PATH%;C:\Program Files\PostgreSQL\9.0\bin;

    + + and then run pg_upgrade with quoted directories, e.g.: + +

    pg_upgrade.exe
    +        --old-datadir "C:/Program Files/PostgreSQL/8.4/data"
    +        --new-datadir "C:/Program Files/PostgreSQL/9.0/data"
    +        --old-bindir "C:/Program Files/PostgreSQL/8.4/bin"
    +        --new-bindir "C:/Program Files/PostgreSQL/9.0/bin"

    + + Once started, pg_upgrade will verify the two clusters are compatible + and then do the upgrade. You can use pg_upgrade --check + to perform only the checks, even if the old server is still + running. pg_upgrade --check will also outline any + manual adjustments you will need to make after the upgrade. + pg_upgrade requires write permission in the current directory. +

    Obviously, no one should be accessing the clusters during the + upgrade. pg_upgrade defaults to running servers + on port 50432 to avoid unintended client connections. + You can use the same port number for both clusters when doing an + upgrade because the old and new clusters will not be running at the + same time. However, when checking an old running server, the old + and new port numbers must be different. +

    If an error occurs while restoring the database schema, pg_upgrade will + exit and you will have to revert to the old cluster as outlined in step 14 + below. To try pg_upgrade again, you will need to modify the old + cluster so the pg_upgrade schema restore succeeds. If the problem is a + contrib module, you might need to uninstall the contrib module from + the old cluster and install it in the new cluster after the upgrade, + assuming the module is not being used to store user data. +

  10. Restore pg_hba.conf

    If you modified pg_hba.conf to use trust, + restore its original authentication settings. +

  11. Post-Upgrade processing

    If any post-upgrade processing is required, pg_upgrade will issue + warnings as it completes. It will also generate script files that must + be run by the administrator. The script files will connect to each + database that needs post-upgrade processing. Each script should be + run using: + +

    psql --username postgres --file script.sql postgres

    + + The scripts can be run in any order and can be deleted once they have + been run. +

    Caution

    In general it is unsafe to access tables referenced in rebuild scripts + until the rebuild scripts have run to completion; doing so could yield + incorrect results or poor performance. Tables not referenced in rebuild + scripts can be accessed immediately. +

  12. Statistics

    Because optimizer statistics are not transferred by pg_upgrade, you will + be instructed to run a command to regenerate that information at the end + of the upgrade. +

  13. Delete old cluster

    Once you are satisfied with the upgrade, you can delete the old + cluster's data directories by running the script mentioned when + pg_upgrade completes. You can also delete the + old installation directories + (e.g. bin, share). +

  14. Reverting to old cluster

    If, after running pg_upgrade, you wish to revert to the old cluster, + there are several options: + +

    • If you ran pg_upgrade + with --check, no modifications were made to the old + cluster and you can re-use it anytime. +

    • If you ran pg_upgrade + with --link, the data files are shared between the + old and new cluster. If you started the new cluster, the new + server has written to those shared files and it is unsafe to + use the old cluster. +

    • If you ran pg_upgrade without + --link or did not start the new server, the + old cluster was not modified except that, if linking + started, a .old suffix was appended to + $PGDATA/global/pg_control. To reuse the old + cluster, possibly remove the .old suffix from + $PGDATA/global/pg_control; you can then restart the + old cluster. +

    +

Notes

pg_upgrade does not support upgrading of databases + containing these reg* OID-referencing system data types: + regproc, regprocedure, regoper, + regoperator, regconfig, and + regdictionary. (regtype can be upgraded.) +

All failure, rebuild, and reindex cases will be reported by + pg_upgrade if they affect your installation; + post-upgrade scripts to rebuild tables and indexes will be + generated automatically. +

For deployment testing, create a schema-only copy of the old cluster, + insert dummy data, and upgrade that. +

If you are upgrading a pre-PostgreSQL 9.2 cluster + that uses a configuration-file-only directory, you must pass the + real data directory location to pg_upgrade, and + pass the configuration directory location to the server, e.g. + -d /real-data-directory -o '-D /configuration-directory'. +

If using a pre-9.1 old server that is using a non-default Unix-domain + socket directory or a default that differs from the default of the + new cluster, set PGHOST to point to the old server's socket + location. (This is not relevant on Windows.) +

A Log-Shipping Standby Server (Section 25.2) cannot + be upgraded because the server must allow writes. The simplest way + is to upgrade the primary and use rsync to rebuild the + standbys. You can run rsync while the primary is down, + or as part of a base backup (Section 24.3.2) + which overwrites the old standby cluster. +

If you want to use link mode and you do not want your old cluster + to be modified when the new cluster is started, make a copy of the + old cluster and upgrade that in link mode. To make a valid copy + of the old cluster, use rsync to create a dirty + copy of the old cluster while the server is running, then shut down + the old server and run rsync again to update the copy with any + changes to make it consistent. You might want to exclude some + files, e.g. postmaster.pid, as documented in Section 24.3.3. +

Limitations in Upgrading from PostgreSQL 8.3

Upgrading from PostgreSQL 8.3 has additional restrictions not present + when upgrading from later PostgreSQL releases. For example, + pg_upgrade will not work for upgrading from 8.3 if a user column + is defined as: +

  • a tsquery data type +

  • data type name and is not the first column +

+

You must drop any such columns and upgrade them manually. +

pg_upgrade will not work if the ltree + contrib module is installed in a database. +

pg_upgrade will require a table rebuild if: +

  • a user column is of data type tsvector +

+

pg_upgrade will require a reindex if: +

  • an index is of type hash or GIN +

  • an index uses bpchar_pattern_ops +

+

Also, the default datetime storage format changed to integer after + PostgreSQL 8.3. pg_upgrade will check that the datetime storage format + used by the old and new clusters match. Make sure your new cluster is + built with the configure flag --disable-integer-datetimes. +

For Windows users, note that due to different integer datetimes settings + used by the one-click installer and the MSI installer, it is only + possible to upgrade from version 8.3 of the one-click distribution to + version 8.4 or later of the one-click distribution. It is not + possible to upgrade from the MSI installer to the one-click installer. +


PrevHomeNext
pg_test_timingUpExternal Projects
\ No newline at end of file diff --git a/doc/src/sgml/html/planner-optimizer.html b/doc/src/sgml/html/planner-optimizer.html new file mode 100644 index 000000000..8fd0d9dae --- /dev/null +++ b/doc/src/sgml/html/planner-optimizer.html @@ -0,0 +1,383 @@ + +Planner/Optimizer
PostgreSQL 9.2.2 Documentation
PrevUpChapter 44. Overview of PostgreSQL InternalsNext

44.5. Planner/Optimizer

The task of the planner/optimizer is to + create an optimal execution plan. A given SQL query (and hence, a + query tree) can be actually executed in a wide variety of + different ways, each of which will produce the same set of + results. If it is computationally feasible, the query optimizer + will examine each of these possible execution plans, ultimately + selecting the execution plan that is expected to run the fastest. +

Note: In some situations, examining each possible way in which a query + can be executed would take an excessive amount of time and memory + space. In particular, this occurs when executing queries + involving large numbers of join operations. In order to determine + a reasonable (not necessarily optimal) query plan in a reasonable amount + of time, PostgreSQL uses a Genetic + Query Optimizer (see Chapter 51) when the number of joins + exceeds a threshold (see geqo_threshold). +

The planner's search procedure actually works with data structures + called paths, which are simply cut-down representations of + plans containing only as much information as the planner needs to make + its decisions. After the cheapest path is determined, a full-fledged + plan tree is built to pass to the executor. This represents + the desired execution plan in sufficient detail for the executor to run it. + In the rest of this section we'll ignore the distinction between paths + and plans. +

44.5.1. Generating Possible Plans

The planner/optimizer starts by generating plans for scanning each + individual relation (table) used in the query. The possible plans + are determined by the available indexes on each relation. + There is always the possibility of performing a + sequential scan on a relation, so a sequential scan plan is always + created. Assume an index is defined on a + relation (for example a B-tree index) and a query contains the + restriction + relation.attribute OPR constant. If + relation.attribute happens to match the key of the B-tree + index and OPR is one of the operators listed in + the index's operator class, another plan is created using + the B-tree index to scan the relation. If there are further indexes + present and the restrictions in the query happen to match a key of an + index, further plans will be considered. Index scan plans are also + generated for indexes that have a sort ordering that can match the + query's ORDER BY clause (if any), or a sort ordering that + might be useful for merge joining (see below). +

If the query requires joining two or more relations, + plans for joining relations are considered + after all feasible plans have been found for scanning single relations. + The three available join strategies are: + +

  • nested loop join: The right relation is scanned + once for every row found in the left relation. This strategy + is easy to implement but can be very time consuming. (However, + if the right relation can be scanned with an index scan, this can + be a good strategy. It is possible to use values from the current + row of the left relation as keys for the index scan of the right.) +

  • merge join: Each relation is sorted on the join + attributes before the join starts. Then the two relations are + scanned in parallel, and matching rows are combined to form + join rows. This kind of join is more + attractive because each relation has to be scanned only once. + The required sorting might be achieved either by an explicit sort + step, or by scanning the relation in the proper order using an + index on the join key. +

  • hash join: the right relation is first scanned + and loaded into a hash table, using its join attributes as hash keys. + Next the left relation is scanned and the + appropriate values of every row found are used as hash keys to + locate the matching rows in the table. +

+

When the query involves more than two relations, the final result + must be built up by a tree of join steps, each with two inputs. + The planner examines different possible join sequences to find the + cheapest one. +

If the query uses fewer than geqo_threshold + relations, a near-exhaustive search is conducted to find the best + join sequence. The planner preferentially considers joins between any + two relations for which there exist a corresponding join clause in the + WHERE qualification (i.e., for + which a restriction like where rel1.attr1=rel2.attr2 + exists). Join pairs with no join clause are considered only when there + is no other choice, that is, a particular relation has no available + join clauses to any other relation. All possible plans are generated for + every join pair considered by the planner, and the one that is + (estimated to be) the cheapest is chosen. +

When geqo_threshold is exceeded, the join + sequences considered are determined by heuristics, as described + in Chapter 51. Otherwise the process is the same. +

The finished plan tree consists of sequential or index scans of + the base relations, plus nested-loop, merge, or hash join nodes as + needed, plus any auxiliary steps needed, such as sort nodes or + aggregate-function calculation nodes. Most of these plan node + types have the additional ability to do selection + (discarding rows that do not meet a specified Boolean condition) + and projection (computation of a derived column set + based on given column values, that is, evaluation of scalar + expressions where needed). One of the responsibilities of the + planner is to attach selection conditions from the + WHERE clause and computation of required + output expressions to the most appropriate nodes of the plan + tree. +


PrevHomeNext
The PostgreSQL Rule SystemUpExecutor
\ No newline at end of file diff --git a/doc/src/sgml/html/planner-stats-details.html b/doc/src/sgml/html/planner-stats-details.html new file mode 100644 index 000000000..d5c9bc50e --- /dev/null +++ b/doc/src/sgml/html/planner-stats-details.html @@ -0,0 +1,181 @@ + +How the Planner Uses Statistics

Chapter 58. How the Planner Uses Statistics

This chapter builds on the material covered in Section 14.1 and Section 14.2 to show some + additional details about how the planner uses the + system statistics to estimate the number of rows each part of a query might + return. This is a significant part of the planning process, + providing much of the raw material for cost calculation. +

The intent of this chapter is not to document the code in detail, + but to present an overview of how it works. + This will perhaps ease the learning curve for someone who subsequently + wishes to read the code. +


PrevHomeNext
ExampleUpRow Estimation Examples
\ No newline at end of file diff --git a/doc/src/sgml/html/planner-stats.html b/doc/src/sgml/html/planner-stats.html new file mode 100644 index 000000000..3b0962709 --- /dev/null +++ b/doc/src/sgml/html/planner-stats.html @@ -0,0 +1,426 @@ + +Statistics Used by the Planner
PostgreSQL 9.2.2 Documentation
PrevUpChapter 14. Performance TipsNext

14.2. Statistics Used by the Planner

As we saw in the previous section, the query planner needs to estimate + the number of rows retrieved by a query in order to make good choices + of query plans. This section provides a quick look at the statistics + that the system uses for these estimates. +

One component of the statistics is the total number of entries in + each table and index, as well as the number of disk blocks occupied + by each table and index. This information is kept in the table + pg_class, + in the columns reltuples and + relpages. We can look at it with + queries similar to this one: + +

SELECT relname, relkind, reltuples, relpages
+FROM pg_class
+WHERE relname LIKE 'tenk1%';
+
+       relname        | relkind | reltuples | relpages
+----------------------+---------+-----------+----------
+ tenk1                | r       |     10000 |      358
+ tenk1_hundred        | i       |     10000 |       30
+ tenk1_thous_tenthous | i       |     10000 |       30
+ tenk1_unique1        | i       |     10000 |       30
+ tenk1_unique2        | i       |     10000 |       30
+(5 rows)

+ + Here we can see that tenk1 contains 10000 + rows, as do its indexes, but the indexes are (unsurprisingly) much + smaller than the table. +

For efficiency reasons, reltuples + and relpages are not updated on-the-fly, + and so they usually contain somewhat out-of-date values. + They are updated by VACUUM, ANALYZE, and a + few DDL commands such as CREATE INDEX. A VACUUM + or ANALYZE operation that does not scan the entire table + (which is commonly the case) will incrementally update the + reltuples count on the basis of the part + of the table it did scan, resulting in an approximate value. + In any case, the planner + will scale the values it finds in pg_class + to match the current physical table size, thus obtaining a closer + approximation. +

Most queries retrieve only a fraction of the rows in a table, due + to WHERE clauses that restrict the rows to be + examined. The planner thus needs to make an estimate of the + selectivity of WHERE clauses, that is, + the fraction of rows that match each condition in the + WHERE clause. The information used for this task is + stored in the + pg_statistic + system catalog. Entries in pg_statistic + are updated by the ANALYZE and VACUUM + ANALYZE commands, and are always approximate even when freshly + updated. +

Rather than look at pg_statistic directly, + it's better to look at its view + pg_stats + when examining the statistics manually. pg_stats + is designed to be more easily readable. Furthermore, + pg_stats is readable by all, whereas + pg_statistic is only readable by a superuser. + (This prevents unprivileged users from learning something about + the contents of other people's tables from the statistics. The + pg_stats view is restricted to show only + rows about tables that the current user can read.) + For example, we might do: + +

SELECT attname, inherited, n_distinct,
+       array_to_string(most_common_vals, E'\n') as most_common_vals
+FROM pg_stats
+WHERE tablename = 'road';
+
+ attname | inherited | n_distinct |          most_common_vals
+---------+-----------+------------+------------------------------------
+ name    | f         |  -0.363388 | I- 580                        Ramp+
+         |           |            | I- 880                        Ramp+
+         |           |            | Sp Railroad                       +
+         |           |            | I- 580                            +
+         |           |            | I- 680                        Ramp
+ name    | t         |  -0.284859 | I- 880                        Ramp+
+         |           |            | I- 580                        Ramp+
+         |           |            | I- 680                        Ramp+
+         |           |            | I- 580                            +
+         |           |            | State Hwy 13                  Ramp
+(2 rows)

+ + Note that two rows are displayed for the same column, one corresponding + to the complete inheritance hierarchy starting at the + road table (inherited=t), + and another one including only the road table itself + (inherited=f). +

The amount of information stored in pg_statistic + by ANALYZE, in particular the maximum number of entries in the + most_common_vals and histogram_bounds + arrays for each column, can be set on a + column-by-column basis using the ALTER TABLE SET STATISTICS + command, or globally by setting the + default_statistics_target configuration variable. + The default limit is presently 100 entries. Raising the limit + might allow more accurate planner estimates to be made, particularly for + columns with irregular data distributions, at the price of consuming + more space in pg_statistic and slightly more + time to compute the estimates. Conversely, a lower limit might be + sufficient for columns with simple data distributions. +

Further details about the planner's use of statistics can be found in + Chapter 58. +


PrevHomeNext
Using EXPLAINUpControlling the Planner with Explicit JOIN Clauses
\ No newline at end of file diff --git a/doc/src/sgml/html/plhandler.html b/doc/src/sgml/html/plhandler.html new file mode 100644 index 000000000..373dffe15 --- /dev/null +++ b/doc/src/sgml/html/plhandler.html @@ -0,0 +1,540 @@ + +Writing A Procedural Language Handler

Chapter 49. Writing A Procedural Language Handler

All calls to functions that are written in a language other than + the current "version 1" interface for compiled + languages (this includes functions in user-defined procedural languages, + functions written in SQL, and functions using the version 0 compiled + language interface) go through a call handler + function for the specific language. It is the responsibility of + the call handler to execute the function in a meaningful way, such + as by interpreting the supplied source text. This chapter outlines + how a new procedural language's call handler can be written. +

The call handler for a procedural language is a + "normal" function that must be written in a compiled + language such as C, using the version-1 interface, and registered + with PostgreSQL as taking no arguments + and returning the type language_handler. This + special pseudotype identifies the function as a call handler and + prevents it from being called directly in SQL commands. + For more details on C language calling conventions and dynamic loading, + see Section 35.9. +

The call handler is called in the same way as any other function: + It receives a pointer to a + FunctionCallInfoData struct containing + argument values and information about the called function, and it + is expected to return a Datum result (and possibly + set the isnull field of the + FunctionCallInfoData structure, if it wishes + to return an SQL null result). The difference between a call + handler and an ordinary callee function is that the + flinfo->fn_oid field of the + FunctionCallInfoData structure will contain + the OID of the actual function to be called, not of the call + handler itself. The call handler must use this field to determine + which function to execute. Also, the passed argument list has + been set up according to the declaration of the target function, + not of the call handler. +

It's up to the call handler to fetch the entry of the function from the + pg_proc system catalog and to analyze the argument + and return types of the called function. The AS clause from the + CREATE FUNCTION command for the function will be found + in the prosrc column of the + pg_proc row. This is commonly source + text in the procedural language, but in theory it could be something else, + such as a path name to a file, or anything else that tells the call handler + what to do in detail. +

Often, the same function is called many times per SQL statement. + A call handler can avoid repeated lookups of information about the + called function by using the + flinfo->fn_extra field. This will + initially be NULL, but can be set by the call handler to point at + information about the called function. On subsequent calls, if + flinfo->fn_extra is already non-NULL + then it can be used and the information lookup step skipped. The + call handler must make sure that + flinfo->fn_extra is made to point at + memory that will live at least until the end of the current query, + since an FmgrInfo data structure could be + kept that long. One way to do this is to allocate the extra data + in the memory context specified by + flinfo->fn_mcxt; such data will + normally have the same lifespan as the + FmgrInfo itself. But the handler could + also choose to use a longer-lived memory context so that it can cache + function definition information across queries. +

When a procedural-language function is invoked as a trigger, no arguments + are passed in the usual way, but the + FunctionCallInfoData's + context field points at a + TriggerData structure, rather than being NULL + as it is in a plain function call. A language handler should + provide mechanisms for procedural-language functions to get at the trigger + information. +

This is a template for a procedural-language handler written in C: +

#include "postgres.h"
+#include "executor/spi.h"
+#include "commands/trigger.h"
+#include "fmgr.h"
+#include "access/heapam.h"
+#include "utils/syscache.h"
+#include "catalog/pg_proc.h"
+#include "catalog/pg_type.h"
+
+#ifdef PG_MODULE_MAGIC
+PG_MODULE_MAGIC;
+#endif
+
+PG_FUNCTION_INFO_V1(plsample_call_handler);
+
+Datum
+plsample_call_handler(PG_FUNCTION_ARGS)
+{
+    Datum          retval;
+
+    if (CALLED_AS_TRIGGER(fcinfo))
+    {
+        /*
+         * Called as a trigger procedure
+         */
+        TriggerData    *trigdata = (TriggerData *) fcinfo->context;
+
+        retval = ...
+    }
+    else
+    {
+        /*
+         * Called as a function
+         */
+
+        retval = ...
+    }
+
+    return retval;
+}

+ Only a few thousand lines of code have to be added instead of the + dots to complete the call handler. +

After having compiled the handler function into a loadable module + (see Section 35.9.6), the following commands then + register the sample procedural language: +

CREATE FUNCTION plsample_call_handler() RETURNS language_handler
+    AS 'filename'
+    LANGUAGE C;
+CREATE LANGUAGE plsample
+    HANDLER plsample_call_handler;

+

Although providing a call handler is sufficient to create a minimal + procedural language, there are two other functions that can optionally + be provided to make the language more convenient to use. These + are a validator and an + inline handler. A validator can be provided + to allow language-specific checking to be done during + CREATE FUNCTION. + An inline handler can be provided to allow the language to support + anonymous code blocks executed via the DO command. +

If a validator is provided by a procedural language, it + must be declared as a function taking a single parameter of type + oid. The validator's result is ignored, so it is customarily + declared to return void. The validator will be called at + the end of a CREATE FUNCTION command that has created + or updated a function written in the procedural language. + The passed-in OID is the OID of the function's pg_proc + row. The validator must fetch this row in the usual way, and do + whatever checking is appropriate. Typical checks include verifying + that the function's argument and result types are supported by the + language, and that the function's body is syntactically correct + in the language. If the validator finds the function to be okay, + it should just return. If it finds an error, it should report that + via the normal ereport() error reporting mechanism. + Throwing an error will force a transaction rollback and thus prevent + the incorrect function definition from being committed. +

Validator functions should typically honor the check_function_bodies parameter: if it is turned off then + any expensive or context-sensitive checking should be skipped. + In particular, this parameter is turned off by pg_dump + so that it can load procedural language functions without worrying + about possible dependencies of the function bodies on other database + objects. (Because of this requirement, the call handler should avoid + assuming that the validator has fully checked the function. The point + of having a validator is not to let the call handler omit checks, but + to notify the user immediately if there are obvious errors in a + CREATE FUNCTION command.) +

If an inline handler is provided by a procedural language, it + must be declared as a function taking a single parameter of type + internal. The inline handler's result is ignored, so it is + customarily declared to return void. The inline handler + will be called when a DO statement is executed specifying + the procedural language. The parameter actually passed is a pointer + to an InlineCodeBlock struct, which contains information + about the DO statement's parameters, in particular the + text of the anonymous code block to be executed. The inline handler + should execute this code and return. +

It's recommended that you wrap all these function declarations, + as well as the CREATE LANGUAGE command itself, into + an extension so that a simple CREATE EXTENSION + command is sufficient to install the language. See + Section 35.15 for information about writing + extensions. +

The procedural languages included in the standard distribution + are good references when trying to write your own language handler. + Look into the src/pl subdirectory of the source tree. + The CREATE LANGUAGE + reference page also has some useful details. +


PrevHomeNext
For the ProgrammerUpWriting A Foreign Data Wrapper
\ No newline at end of file diff --git a/doc/src/sgml/html/plperl-builtins.html b/doc/src/sgml/html/plperl-builtins.html new file mode 100644 index 000000000..bdfc8ba80 --- /dev/null +++ b/doc/src/sgml/html/plperl-builtins.html @@ -0,0 +1,985 @@ + +Built-in Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 41. PL/Perl - Perl Procedural LanguageNext

41.3. Built-in Functions

41.3.1. Database Access from PL/Perl

Access to the database itself from your Perl function can be done + via the following functions: +

spi_exec_query(query [, max-rows])

spi_exec_query executes an SQL command and +returns the entire row set as a reference to an array of hash +references. You should only use this command when you know +that the result set will be relatively small. Here is an +example of a query (SELECT command) with the +optional maximum number of rows: + +

$rv = spi_exec_query('SELECT * FROM my_table', 5);

+ This returns up to 5 rows from the table + my_table. If my_table + has a column my_column, you can get that + value from row $i of the result like this: +

$foo = $rv->{rows}[$i]->{my_column};

+ The total number of rows returned from a SELECT + query can be accessed like this: +

$nrows = $rv->{processed}

+

Here is an example using a different command type: +

$query = "INSERT INTO my_table VALUES (1, 'test')";
+$rv = spi_exec_query($query);

+ You can then access the command status (e.g., + SPI_OK_INSERT) like this: +

$res = $rv->{status};

+ To get the number of rows affected, do: +

$nrows = $rv->{processed};

+

Here is a complete example: +

CREATE TABLE test (
+    i int,
+    v varchar
+);
+
+INSERT INTO test (i, v) VALUES (1, 'first line');
+INSERT INTO test (i, v) VALUES (2, 'second line');
+INSERT INTO test (i, v) VALUES (3, 'third line');
+INSERT INTO test (i, v) VALUES (4, 'immortal');
+
+CREATE OR REPLACE FUNCTION test_munge() RETURNS SETOF test AS $$
+    my $rv = spi_exec_query('select i, v from test;');
+    my $status = $rv->{status};
+    my $nrows = $rv->{processed};
+    foreach my $rn (0 .. $nrows - 1) {
+        my $row = $rv->{rows}[$rn];
+        $row->{i} += 200 if defined($row->{i});
+        $row->{v} =~ tr/A-Za-z/a-zA-Z/ if (defined($row->{v}));
+        return_next($row);
+    }
+    return undef;
+$$ LANGUAGE plperl;
+
+SELECT * FROM test_munge();

+

spi_query(command)
spi_fetchrow(cursor)
spi_cursor_close(cursor)

spi_query and spi_fetchrow + work together as a pair for row sets which might be large, or for cases + where you wish to return rows as they arrive. + spi_fetchrow works only with + spi_query. The following example illustrates how + you use them together: + +

CREATE TYPE foo_type AS (the_num INTEGER, the_text TEXT);
+
+CREATE OR REPLACE FUNCTION lotsa_md5 (INTEGER) RETURNS SETOF foo_type AS $$
+    use Digest::MD5 qw(md5_hex);
+    my $file = '/usr/share/dict/words';
+    my $t = localtime;
+    elog(NOTICE, "opening file $file at $t" );
+    open my $fh, '<', $file # ooh, it's a file access!
+        or elog(ERROR, "cannot open $file for reading: $!");
+    my @words = <$fh>;
+    close $fh;
+    $t = localtime;
+    elog(NOTICE, "closed file $file at $t");
+    chomp(@words);
+    my $row;
+    my $sth = spi_query("SELECT * FROM generate_series(1,$_[0]) AS b(a)");
+    while (defined ($row = spi_fetchrow($sth))) {
+        return_next({
+            the_num => $row->{a},
+            the_text => md5_hex($words[rand @words])
+        });
+    }
+    return;
+$$ LANGUAGE plperlu;
+
+SELECT * from lotsa_md5(500);

+

Normally, spi_fetchrow should be repeated until it + returns undef, indicating that there are no more + rows to read. The cursor returned by spi_query + is automatically freed when + spi_fetchrow returns undef. + If you do not wish to read all the rows, instead call + spi_cursor_close to free the cursor. + Failure to do so will result in memory leaks. +

spi_prepare(command, argument types)
spi_query_prepared(plan, arguments)
spi_exec_prepared(plan [, attributes], arguments)
spi_freeplan(plan)

spi_prepare, spi_query_prepared, spi_exec_prepared, + and spi_freeplan implement the same functionality but for prepared queries. + spi_prepare accepts a query string with numbered argument placeholders ($1, $2, etc) + and a string list of argument types: +

$plan = spi_prepare('SELECT * FROM test WHERE id > $1 AND name = $2',
+                                                     'INTEGER', 'TEXT');

+ Once a query plan is prepared by a call to spi_prepare, the plan can be used instead + of the string query, either in spi_exec_prepared, where the result is the same as returned + by spi_exec_query, or in spi_query_prepared which returns a cursor + exactly as spi_query does, which can be later passed to spi_fetchrow. + The optional second parameter to spi_exec_prepared is a hash reference of attributes; + the only attribute currently supported is limit, which sets the maximum number of rows returned by a query. +

The advantage of prepared queries is that is it possible to use one prepared plan for more + than one query execution. After the plan is not needed anymore, it can be freed with + spi_freeplan: +

CREATE OR REPLACE FUNCTION init() RETURNS VOID AS $$
+        $_SHARED{my_plan} = spi_prepare('SELECT (now() + $1)::date AS now',
+                                        'INTERVAL');
+$$ LANGUAGE plperl;
+
+CREATE OR REPLACE FUNCTION add_time( INTERVAL ) RETURNS TEXT AS $$
+        return spi_exec_prepared(
+                $_SHARED{my_plan},
+                $_[0]
+        )->{rows}->[0]->{now};
+$$ LANGUAGE plperl;
+
+CREATE OR REPLACE FUNCTION done() RETURNS VOID AS $$
+        spi_freeplan( $_SHARED{my_plan});
+        undef $_SHARED{my_plan};
+$$ LANGUAGE plperl;
+
+SELECT init();
+SELECT add_time('1 day'), add_time('2 days'), add_time('3 days');
+SELECT done();
+
+  add_time  |  add_time  |  add_time
+------------+------------+------------
+ 2005-12-10 | 2005-12-11 | 2005-12-12

+ Note that the parameter subscript in spi_prepare is defined via + $1, $2, $3, etc, so avoid declaring query strings in double quotes that might easily + lead to hard-to-catch bugs. +

Another example illustrates usage of an optional parameter in spi_exec_prepared: +

CREATE TABLE hosts AS SELECT id, ('192.168.1.'||id)::inet AS address
+                      FROM generate_series(1,3) AS id;
+
+CREATE OR REPLACE FUNCTION init_hosts_query() RETURNS VOID AS $$
+        $_SHARED{plan} = spi_prepare('SELECT * FROM hosts
+                                      WHERE address << $1', 'inet');
+$$ LANGUAGE plperl;
+
+CREATE OR REPLACE FUNCTION query_hosts(inet) RETURNS SETOF hosts AS $$
+        return spi_exec_prepared(
+                $_SHARED{plan},
+                {limit => 2},
+                $_[0]
+        )->{rows};
+$$ LANGUAGE plperl;
+
+CREATE OR REPLACE FUNCTION release_hosts_query() RETURNS VOID AS $$
+        spi_freeplan($_SHARED{plan});
+        undef $_SHARED{plan};
+$$ LANGUAGE plperl;
+
+SELECT init_hosts_query();
+SELECT query_hosts('192.168.1.0/30');
+SELECT release_hosts_query();
+
+    query_hosts    
+-----------------
+ (1,192.168.1.1)
+ (2,192.168.1.2)
+(2 rows)

+

41.3.2. Utility Functions in PL/Perl

elog(level, msg)

Emit a log or error message. Possible levels are + DEBUG, LOG, INFO, + NOTICE, WARNING, and ERROR. + ERROR + raises an error condition; if this is not trapped by the surrounding + Perl code, the error propagates out to the calling query, causing + the current transaction or subtransaction to be aborted. This + is effectively the same as the Perl die command. + The other levels only generate messages of different + priority levels. + Whether messages of a particular priority are reported to the client, + written to the server log, or both is controlled by the + log_min_messages and + client_min_messages configuration + variables. See Chapter 18 for more + information. +

quote_literal(string)

Return the given string suitably quoted to be used as a string literal in an SQL + statement string. Embedded single-quotes and backslashes are properly doubled. + Note that quote_literal returns undef on undef input; if the argument + might be undef, quote_nullable is often more suitable. +

quote_nullable(string)

Return the given string suitably quoted to be used as a string literal in an SQL + statement string; or, if the argument is undef, return the unquoted string "NULL". + Embedded single-quotes and backslashes are properly doubled. +

quote_ident(string)

Return the given string suitably quoted to be used as an identifier in + an SQL statement string. Quotes are added only if necessary (i.e., if + the string contains non-identifier characters or would be case-folded). + Embedded quotes are properly doubled. +

decode_bytea(string)

Return the unescaped binary data represented by the contents of the given string, + which should be bytea encoded. +

encode_bytea(string)

Return the bytea encoded form of the binary data contents of the given string. +

encode_array_literal(array)
encode_array_literal(array, delimiter)

Returns the contents of the referenced array as a string in array literal format + (see Section 8.15.2). + Returns the argument value unaltered if it's not a reference to an array. + The delimiter used between elements of the array literal defaults to ", " + if a delimiter is not specified or is undef. +

encode_typed_literal(value, typename)

Converts a Perl variable to the value of the data type passed as a + second argument and returns a string representation of this value. + Correctly handles nested arrays and values of composite types. +

encode_array_constructor(array)

Returns the contents of the referenced array as a string in array constructor format + (see Section 4.2.12). + Individual values are quoted using quote_nullable. + Returns the argument value, quoted using quote_nullable, + if it's not a reference to an array. +

looks_like_number(string)

Returns a true value if the content of the given string looks like a + number, according to Perl, returns false otherwise. + Returns undef if the argument is undef. Leading and trailing space is + ignored. Inf and Infinity are regarded as numbers. +

is_array_ref(argument)

Returns a true value if the given argument may be treated as an + array reference, that is, if ref of the argument is ARRAY or + PostgreSQL::InServer::ARRAY. Returns false otherwise. +


PrevHomeNext
Data Values in PL/PerlUpGlobal Values in PL/Perl
\ No newline at end of file diff --git a/doc/src/sgml/html/plperl-data.html b/doc/src/sgml/html/plperl-data.html new file mode 100644 index 000000000..9c261341b --- /dev/null +++ b/doc/src/sgml/html/plperl-data.html @@ -0,0 +1,180 @@ + +Data Values in PL/Perl
PostgreSQL 9.2.2 Documentation
PrevUpChapter 41. PL/Perl - Perl Procedural LanguageNext

41.2. Data Values in PL/Perl

The argument values supplied to a PL/Perl function's code are + simply the input arguments converted to text form (just as if they + had been displayed by a SELECT statement). + Conversely, the return and return_next + commands will accept any string that is acceptable input format + for the function's declared return type. +


PrevHomeNext
PL/Perl Functions and ArgumentsUpBuilt-in Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/plperl-funcs.html b/doc/src/sgml/html/plperl-funcs.html new file mode 100644 index 000000000..7eaea4e51 --- /dev/null +++ b/doc/src/sgml/html/plperl-funcs.html @@ -0,0 +1,610 @@ + +PL/Perl Functions and Arguments
PostgreSQL 9.2.2 Documentation
PrevUpChapter 41. PL/Perl - Perl Procedural LanguageNext

41.1. PL/Perl Functions and Arguments

To create a function in the PL/Perl language, use the standard + CREATE FUNCTION + syntax: + +

CREATE FUNCTION funcname (argument-types) RETURNS return-type AS $$
+    # PL/Perl function body
+$$ LANGUAGE plperl;

+ + The body of the function is ordinary Perl code. In fact, the PL/Perl + glue code wraps it inside a Perl subroutine. A PL/Perl function is + called in a scalar context, so it can't return a list. You can return + non-scalar values (arrays, records, and sets) by returning a reference, + as discussed below. +

PL/Perl also supports anonymous code blocks called with the + DO statement: + +

DO $$
+    # PL/Perl code
+$$ LANGUAGE plperl;

+ + An anonymous code block receives no arguments, and whatever value it + might return is discarded. Otherwise it behaves just like a function. +

Note: The use of named nested subroutines is dangerous in Perl, especially if + they refer to lexical variables in the enclosing scope. Because a PL/Perl + function is wrapped in a subroutine, any named subroutine you place inside + one will be nested. In general, it is far safer to create anonymous + subroutines which you call via a coderef. For more information, see the + entries for Variable "%s" will not stay shared and + Variable "%s" is not available in the + perldiag man page, or + search the Internet for "perl nested named subroutine". +

The syntax of the CREATE FUNCTION command requires + the function body to be written as a string constant. It is usually + most convenient to use dollar quoting (see Section 4.1.2.4) for the string constant. + If you choose to use escape string syntax E'', + you must double any single quote marks (') and backslashes + (\) used in the body of the function + (see Section 4.1.2.1). +

Arguments and results are handled as in any other Perl subroutine: + arguments are passed in @_, and a result value + is returned with return or as the last expression + evaluated in the function. +

For example, a function returning the greater of two integer values + could be defined as: + +

CREATE FUNCTION perl_max (integer, integer) RETURNS integer AS $$
+    if ($_[0] > $_[1]) { return $_[0]; }
+    return $_[1];
+$$ LANGUAGE plperl;

+

Note: Arguments will be converted from the database's encoding to UTF-8 + for use inside PL/Perl, and then converted from UTF-8 back to the + database encoding upon return. +

If an SQL null value is passed to a function, + the argument value will appear as "undefined" in Perl. The + above function definition will not behave very nicely with null + inputs (in fact, it will act as though they are zeroes). We could + add STRICT to the function definition to make + PostgreSQL do something more reasonable: + if a null value is passed, the function will not be called at all, + but will just return a null result automatically. Alternatively, + we could check for undefined inputs in the function body. For + example, suppose that we wanted perl_max with + one null and one nonnull argument to return the nonnull argument, + rather than a null value: + +

CREATE FUNCTION perl_max (integer, integer) RETURNS integer AS $$
+    my ($x, $y) = @_;
+    if (not defined $x) {
+        return undef if not defined $y;
+        return $y;
+    }
+    return $x if not defined $y;
+    return $x if $x > $y;
+    return $y;
+$$ LANGUAGE plperl;

+ As shown above, to return an SQL null value from a PL/Perl + function, return an undefined value. This can be done whether the + function is strict or not. +

Anything in a function argument that is not a reference is + a string, which is in the standard PostgreSQL + external text representation for the relevant data type. In the case of + ordinary numeric or text types, Perl will just do the right thing and + the programmer will normally not have to worry about it. However, in + other cases the argument will need to be converted into a form that is + more usable in Perl. For example, the decode_bytea + function can be used to convert an argument of + type bytea into unescaped binary. +

Similarly, values passed back to PostgreSQL + must be in the external text representation format. For example, the + encode_bytea function can be used to + escape binary data for a return value of type bytea. +

Perl can return PostgreSQL arrays as + references to Perl arrays. Here is an example: + +

CREATE OR REPLACE function returns_array()
+RETURNS text[][] AS $$
+    return [['a"b','c,d'],['e\\f','g']];
+$$ LANGUAGE plperl;
+
+select returns_array();

+

Perl passes PostgreSQL arrays as a blessed + PostgreSQL::InServer::ARRAY object. This object may be treated as an array + reference or a string, allowing for backward compatibility with Perl + code written for PostgreSQL versions below 9.1 to + run. For example: + +

CREATE OR REPLACE FUNCTION concat_array_elements(text[]) RETURNS TEXT AS $$
+    my $arg = shift;
+    my $result = "";
+    return undef if (!defined $arg);
+
+    # as an array reference
+    for (@$arg) {
+        $result .= $_;
+    }
+
+    # also works as a string
+    $result .= $arg;
+
+    return $result;
+$$ LANGUAGE plperl;
+
+SELECT concat_array_elements(ARRAY['PL','/','Perl']);

+ +

Note: Multi-dimensional arrays are represented as references to + lower-dimensional arrays of references in a way common to every Perl + programmer. +

+

Composite-type arguments are passed to the function as references + to hashes. The keys of the hash are the attribute names of the + composite type. Here is an example: + +

CREATE TABLE employee (
+    name text,
+    basesalary integer,
+    bonus integer
+);
+
+CREATE FUNCTION empcomp(employee) RETURNS integer AS $$
+    my ($emp) = @_;
+    return $emp->{basesalary} + $emp->{bonus};
+$$ LANGUAGE plperl;
+
+SELECT name, empcomp(employee.*) FROM employee;

+

A PL/Perl function can return a composite-type result using the same + approach: return a reference to a hash that has the required attributes. + For example: + +

CREATE TYPE testrowperl AS (f1 integer, f2 text, f3 text);
+
+CREATE OR REPLACE FUNCTION perl_row() RETURNS testrowperl AS $$
+    return {f2 => 'hello', f1 => 1, f3 => 'world'};
+$$ LANGUAGE plperl;
+
+SELECT * FROM perl_row();

+ + Any columns in the declared result data type that are not present in the + hash will be returned as null values. +

PL/Perl functions can also return sets of either scalar or + composite types. Usually you'll want to return rows one at a + time, both to speed up startup time and to keep from queueing up + the entire result set in memory. You can do this with + return_next as illustrated below. Note that + after the last return_next, you must put + either return or (better) return + undef. + +

CREATE OR REPLACE FUNCTION perl_set_int(int)
+RETURNS SETOF INTEGER AS $$
+    foreach (0..$_[0]) {
+        return_next($_);
+    }
+    return undef;
+$$ LANGUAGE plperl;
+
+SELECT * FROM perl_set_int(5);
+
+CREATE OR REPLACE FUNCTION perl_set()
+RETURNS SETOF testrowperl AS $$
+    return_next({ f1 => 1, f2 => 'Hello', f3 => 'World' });
+    return_next({ f1 => 2, f2 => 'Hello', f3 => 'PostgreSQL' });
+    return_next({ f1 => 3, f2 => 'Hello', f3 => 'PL/Perl' });
+    return undef;
+$$ LANGUAGE plperl;

+ + For small result sets, you can return a reference to an array that + contains either scalars, references to arrays, or references to + hashes for simple types, array types, and composite types, + respectively. Here are some simple examples of returning the entire + result set as an array reference: + +

CREATE OR REPLACE FUNCTION perl_set_int(int) RETURNS SETOF INTEGER AS $$
+    return [0..$_[0]];
+$$ LANGUAGE plperl;
+
+SELECT * FROM perl_set_int(5);
+
+CREATE OR REPLACE FUNCTION perl_set() RETURNS SETOF testrowperl AS $$
+    return [
+        { f1 => 1, f2 => 'Hello', f3 => 'World' },
+        { f1 => 2, f2 => 'Hello', f3 => 'PostgreSQL' },
+        { f1 => 3, f2 => 'Hello', f3 => 'PL/Perl' }
+    ];
+$$ LANGUAGE plperl;
+
+SELECT * FROM perl_set();

+

If you wish to use the strict pragma with your code you + have a few options. For temporary global use you can SET + plperl.use_strict to true. + This will affect subsequent compilations of PL/Perl + functions, but not functions already compiled in the current session. + For permanent global use you can set plperl.use_strict + to true in the postgresql.conf file. +

For permanent use in specific functions you can simply put: +

use strict;

+ at the top of the function body. +

The feature pragma is also available to use if your Perl is version 5.10.0 or higher. +


PrevHomeNext
PL/Perl - Perl Procedural LanguageUpData Values in PL/Perl
\ No newline at end of file diff --git a/doc/src/sgml/html/plperl-global.html b/doc/src/sgml/html/plperl-global.html new file mode 100644 index 000000000..6f9f2c7f2 --- /dev/null +++ b/doc/src/sgml/html/plperl-global.html @@ -0,0 +1,256 @@ + +Global Values in PL/Perl
PostgreSQL 9.2.2 Documentation
PrevUpChapter 41. PL/Perl - Perl Procedural LanguageNext

41.4. Global Values in PL/Perl

You can use the global hash %_SHARED to store + data, including code references, between function calls for the + lifetime of the current session. +

Here is a simple example for shared data: +

CREATE OR REPLACE FUNCTION set_var(name text, val text) RETURNS text AS $$
+    if ($_SHARED{$_[0]} = $_[1]) {
+        return 'ok';
+    } else {
+        return "cannot set shared variable $_[0] to $_[1]";
+    }
+$$ LANGUAGE plperl;
+
+CREATE OR REPLACE FUNCTION get_var(name text) RETURNS text AS $$
+    return $_SHARED{$_[0]};
+$$ LANGUAGE plperl;
+
+SELECT set_var('sample', 'Hello, PL/Perl!  How''s tricks?');
+SELECT get_var('sample');

+

Here is a slightly more complicated example using a code reference: + +

CREATE OR REPLACE FUNCTION myfuncs() RETURNS void AS $$
+    $_SHARED{myquote} = sub {
+        my $arg = shift;
+        $arg =~ s/(['\\])/\\$1/g;
+        return "'$arg'";
+    };
+$$ LANGUAGE plperl;
+
+SELECT myfuncs(); /* initializes the function */
+
+/* Set up a function that uses the quote function */
+
+CREATE OR REPLACE FUNCTION use_quote(TEXT) RETURNS text AS $$
+    my $text_to_quote = shift;
+    my $qfunc = $_SHARED{myquote};
+    return &$qfunc($text_to_quote);
+$$ LANGUAGE plperl;

+ + (You could have replaced the above with the one-liner + return $_SHARED{myquote}->($_[0]); + at the expense of readability.) +

For security reasons, PL/Perl executes functions called by any one SQL role + in a separate Perl interpreter for that role. This prevents accidental or + malicious interference by one user with the behavior of another user's + PL/Perl functions. Each such interpreter has its own value of the + %_SHARED variable and other global state. Thus, two + PL/Perl functions will share the same value of %_SHARED + if and only if they are executed by the same SQL role. In an application + wherein a single session executes code under multiple SQL roles (via + SECURITY DEFINER functions, use of SET ROLE, etc) + you may need to take explicit steps to ensure that PL/Perl functions can + share data via %_SHARED. To do that, make sure that + functions that should communicate are owned by the same user, and mark + them SECURITY DEFINER. You must of course take care that + such functions can't be used to do anything unintended. +


PrevHomeNext
Built-in FunctionsUpTrusted and Untrusted PL/Perl
\ No newline at end of file diff --git a/doc/src/sgml/html/plperl-triggers.html b/doc/src/sgml/html/plperl-triggers.html new file mode 100644 index 000000000..36e3d5853 --- /dev/null +++ b/doc/src/sgml/html/plperl-triggers.html @@ -0,0 +1,436 @@ + +PL/Perl Triggers
PostgreSQL 9.2.2 Documentation
PrevUpChapter 41. PL/Perl - Perl Procedural LanguageNext

41.6. PL/Perl Triggers

PL/Perl can be used to write trigger functions. In a trigger function, + the hash reference $_TD contains information about the + current trigger event. $_TD is a global variable, + which gets a separate local value for each invocation of the trigger. + The fields of the $_TD hash reference are: + +

$_TD->{new}{foo}

NEW value of column foo +

$_TD->{old}{foo}

OLD value of column foo +

$_TD->{name}

Name of the trigger being called +

$_TD->{event}

Trigger event: INSERT, UPDATE, + DELETE, TRUNCATE, or UNKNOWN +

$_TD->{when}

When the trigger was called: BEFORE, + AFTER, INSTEAD OF, or + UNKNOWN +

$_TD->{level}

The trigger level: ROW, STATEMENT, or UNKNOWN +

$_TD->{relid}

OID of the table on which the trigger fired +

$_TD->{table_name}

Name of the table on which the trigger fired +

$_TD->{relname}

Name of the table on which the trigger fired. This has been deprecated, + and could be removed in a future release. + Please use $_TD->{table_name} instead. +

$_TD->{table_schema}

Name of the schema in which the table on which the trigger fired, is +

$_TD->{argc}

Number of arguments of the trigger function +

@{$_TD->{args}}

Arguments of the trigger function. Does not exist if $_TD->{argc} is 0. +

+

Row-level triggers can return one of the following: + +

return;

Execute the operation +

"SKIP"

Don't execute the operation +

"MODIFY"

Indicates that the NEW row was modified by + the trigger function +

+

Here is an example of a trigger function, illustrating some of the + above: +

CREATE TABLE test (
+    i int,
+    v varchar
+);
+
+CREATE OR REPLACE FUNCTION valid_id() RETURNS trigger AS $$
+    if (($_TD->{new}{i} >= 100) || ($_TD->{new}{i} <= 0)) {
+        return "SKIP";    # skip INSERT/UPDATE command
+    } elsif ($_TD->{new}{v} ne "immortal") {
+        $_TD->{new}{v} .= "(modified by trigger)";
+        return "MODIFY";  # modify row and execute INSERT/UPDATE command
+    } else {
+        return;           # execute INSERT/UPDATE command
+    }
+$$ LANGUAGE plperl;
+
+CREATE TRIGGER test_valid_id_trig
+    BEFORE INSERT OR UPDATE ON test
+    FOR EACH ROW EXECUTE PROCEDURE valid_id();

+


PrevHomeNext
Trusted and Untrusted PL/PerlUpPL/Perl Under the Hood
\ No newline at end of file diff --git a/doc/src/sgml/html/plperl-trusted.html b/doc/src/sgml/html/plperl-trusted.html new file mode 100644 index 000000000..0a99c8296 --- /dev/null +++ b/doc/src/sgml/html/plperl-trusted.html @@ -0,0 +1,333 @@ + +Trusted and Untrusted PL/Perl
PostgreSQL 9.2.2 Documentation
PrevUpChapter 41. PL/Perl - Perl Procedural LanguageNext

41.5. Trusted and Untrusted PL/Perl

Normally, PL/Perl is installed as a "trusted" programming + language named plperl. In this setup, certain Perl + operations are disabled to preserve security. In general, the + operations that are restricted are those that interact with the + environment. This includes file handle operations, + require, and use (for + external modules). There is no way to access internals of the + database server process or to gain OS-level access with the + permissions of the server process, + as a C function can do. Thus, any unprivileged database user can + be permitted to use this language. +

Here is an example of a function that will not work because file + system operations are not allowed for security reasons: +

CREATE FUNCTION badfunc() RETURNS integer AS $$
+    my $tmpfile = "/tmp/badfile";
+    open my $fh, '>', $tmpfile
+        or elog(ERROR, qq{could not open the file "$tmpfile": $!});
+    print $fh "Testing writing to a file\n";
+    close $fh or elog(ERROR, qq{could not close the file "$tmpfile": $!});
+    return 1;
+$$ LANGUAGE plperl;

+ The creation of this function will fail as its use of a forbidden + operation will be caught by the validator. +

Sometimes it is desirable to write Perl functions that are not + restricted. For example, one might want a Perl function that sends + mail. To handle these cases, PL/Perl can also be installed as an + "untrusted" language (usually called + PL/PerlU). + In this case the full Perl language is available. When installing the + language, the language name plperlu will select + the untrusted PL/Perl variant. +

The writer of a PL/PerlU function must take care that the function + cannot be used to do anything unwanted, since it will be able to do + anything that could be done by a user logged in as the database + administrator. Note that the database system allows only database + superusers to create functions in untrusted languages. +

If the above function was created by a superuser using the language + plperlu, execution would succeed. +

In the same way, anonymous code blocks written in Perl can use + restricted operations if the language is specified as + plperlu rather than plperl, but the caller + must be a superuser. +

Note: While PL/Perl functions run in a separate Perl + interpreter for each SQL role, all PL/PerlU functions + executed in a given session run in a single Perl interpreter (which is + not any of the ones used for PL/Perl functions). + This allows PL/PerlU functions to share data freely, + but no communication can occur between PL/Perl and + PL/PerlU functions. +

Note: Perl cannot support multiple interpreters within one process unless + it was built with the appropriate flags, namely either + usemultiplicity or useithreads. + (usemultiplicity is preferred unless you actually need + to use threads. For more details, see the + perlembed man page.) + If PL/Perl is used with a copy of Perl that was not built + this way, then it is only possible to have one Perl interpreter per + session, and so any one session can only execute either + PL/PerlU functions, or PL/Perl functions + that are all called by the same SQL role. +


PrevHomeNext
Global Values in PL/PerlUpPL/Perl Triggers
\ No newline at end of file diff --git a/doc/src/sgml/html/plperl-under-the-hood.html b/doc/src/sgml/html/plperl-under-the-hood.html new file mode 100644 index 000000000..307bd056a --- /dev/null +++ b/doc/src/sgml/html/plperl-under-the-hood.html @@ -0,0 +1,426 @@ + +PL/Perl Under the Hood
PostgreSQL 9.2.2 Documentation
PrevUpChapter 41. PL/Perl - Perl Procedural LanguageNext

41.7. PL/Perl Under the Hood

41.7.1. Configuration

This section lists configuration parameters that affect PL/Perl. +

plperl.on_init (string)

Specifies Perl code to be executed when a Perl interpreter is first + initialized, before it is specialized for use by plperl or + plperlu. + The SPI functions are not available when this code is executed. + If the code fails with an error it will abort the initialization of + the interpreter and propagate out to the calling query, causing the + current transaction or subtransaction to be aborted. +

The Perl code is limited to a single string. Longer code can be placed + into a module and loaded by the on_init string. + Examples: +

plperl.on_init = 'require "plperlinit.pl"'
+plperl.on_init = 'use lib "/my/app"; use MyApp::PgInit;'

+

Any modules loaded by plperl.on_init, either directly or + indirectly, will be available for use by plperl. This may + create a security risk. To see what modules have been loaded you can use: +

DO 'elog(WARNING, join ", ", sort keys %INC)' LANGUAGE plperl;

+

Initialization will happen in the postmaster if the plperl library is + included in shared_preload_libraries, in which + case extra consideration should be given to the risk of destabilizing + the postmaster. The principal reason for making use of this feature + is that Perl modules loaded by plperl.on_init need be + loaded only at postmaster start, and will be instantly available + without loading overhead in individual database sessions. However, + keep in mind that the overhead is avoided only for the first Perl + interpreter used by a database session — either PL/PerlU, or + PL/Perl for the first SQL role that calls a PL/Perl function. Any + additional Perl interpreters created in a database session will have + to execute plperl.on_init afresh. Also, on Windows there + will be no savings whatsoever from preloading, since the Perl + interpreter created in the postmaster process does not propagate to + child processes. +

This parameter can only be set in the postgresql.conf file or on the server command line. +

plperl.on_plperl_init (string)
plperl.on_plperlu_init (string)

These parameters specify Perl code to be executed when a Perl + interpreter is specialized for plperl or + plperlu respectively. This will happen when a PL/Perl or + PL/PerlU function is first executed in a database session, or when + an additional interpreter has to be created because the other language + is called or a PL/Perl function is called by a new SQL role. This + follows any initialization done by plperl.on_init. + The SPI functions are not available when this code is executed. + The Perl code in plperl.on_plperl_init is executed after + "locking down" the interpreter, and thus it can only perform + trusted operations. +

If the code fails with an error it will abort the initialization and + propagate out to the calling query, causing the current transaction or + subtransaction to be aborted. Any actions already done within Perl + won't be undone; however, that interpreter won't be used again. + If the language is used again the initialization will be attempted + again within a fresh Perl interpreter. +

Only superusers can change these settings. Although these settings + can be changed within a session, such changes will not affect Perl + interpreters that have already been used to execute functions. +

plperl.use_strict (boolean)

When set true subsequent compilations of PL/Perl functions will have + the strict pragma enabled. This parameter does not affect + functions already compiled in the current session. +

41.7.2. Limitations and Missing Features

The following features are currently missing from PL/Perl, but they + would make welcome contributions. + +

  • PL/Perl functions cannot call each other directly. +

  • SPI is not yet fully implemented. +

  • If you are fetching very large data sets using + spi_exec_query, you should be aware that + these will all go into memory. You can avoid this by using + spi_query/spi_fetchrow as + illustrated earlier. +

    A similar problem occurs if a set-returning function passes a + large set of rows back to PostgreSQL via return. You + can avoid this problem too by instead using + return_next for each row returned, as shown + previously. +

  • When a session ends normally, not due to a fatal error, any + END blocks that have been defined are executed. + Currently no other actions are performed. Specifically, + file handles are not automatically flushed and objects are + not automatically destroyed. +

+


PrevHomeNext
PL/Perl TriggersUpPL/Python - Python Procedural Language
\ No newline at end of file diff --git a/doc/src/sgml/html/plperl.html b/doc/src/sgml/html/plperl.html new file mode 100644 index 000000000..efc569a14 --- /dev/null +++ b/doc/src/sgml/html/plperl.html @@ -0,0 +1,303 @@ + +PL/Perl - Perl Procedural Language

Chapter 41. PL/Perl - Perl Procedural Language

PL/Perl is a loadable procedural language that enables you to write + PostgreSQL functions in the + Perl programming language. +

The main advantage to using PL/Perl is that this allows use, + within stored functions, of the manyfold "string + munging" operators and functions available for Perl. Parsing + complex strings might be easier using Perl than it is with the + string functions and control structures provided in PL/pgSQL. +

To install PL/Perl in a particular database, use + CREATE EXTENSION plperl, or from the shell command line use + createlang plperl dbname. +

Tip: If a language is installed into template1, all subsequently + created databases will have the language installed automatically. +

Note: Users of source packages must specially enable the build of + PL/Perl during the installation process. (Refer to Chapter 15 for more information.) Users of + binary packages might find PL/Perl in a separate subpackage. +


PrevHomeNext
Tcl Procedure NamesUpPL/Perl Functions and Arguments
\ No newline at end of file diff --git a/doc/src/sgml/html/plpgsql-control-structures.html b/doc/src/sgml/html/plpgsql-control-structures.html new file mode 100644 index 000000000..ece96a3a9 --- /dev/null +++ b/doc/src/sgml/html/plpgsql-control-structures.html @@ -0,0 +1,2703 @@ + +Control Structures
PostgreSQL 9.2.2 Documentation
PrevUpChapter 39. PL/pgSQL - SQL Procedural LanguageNext

39.6. Control Structures

Control structures are probably the most useful (and + important) part of PL/pgSQL. With + PL/pgSQL's control structures, + you can manipulate PostgreSQL data in a very + flexible and powerful way. +

39.6.1. Returning From a Function

There are two commands available that allow you to return data + from a function: RETURN and RETURN + NEXT. +

39.6.1.1. RETURN

RETURN expression;

RETURN with an expression terminates the + function and returns the value of + expression to the caller. This form + is used for PL/pgSQL functions that do + not return a set. +

When returning a scalar type, any expression can be used. The + expression's result will be automatically cast into the + function's return type as described for assignments. To return a + composite (row) value, you must write a record or row variable + as the expression. +

If you declared the function with output parameters, write just + RETURN with no expression. The current values + of the output parameter variables will be returned. +

If you declared the function to return void, a + RETURN statement can be used to exit the function + early; but do not write an expression following + RETURN. +

The return value of a function cannot be left undefined. If + control reaches the end of the top-level block of the function + without hitting a RETURN statement, a run-time + error will occur. This restriction does not apply to functions + with output parameters and functions returning void, + however. In those cases a RETURN statement is + automatically executed if the top-level block finishes. +

39.6.1.2. RETURN NEXT and RETURN QUERY

RETURN NEXT expression;
+RETURN QUERY query;
+RETURN QUERY EXECUTE command-string [ USING expression [, ... ] ];

When a PL/pgSQL function is declared to return + SETOF sometype, the procedure + to follow is slightly different. In that case, the individual + items to return are specified by a sequence of RETURN + NEXT or RETURN QUERY commands, and + then a final RETURN command with no argument + is used to indicate that the function has finished executing. + RETURN NEXT can be used with both scalar and + composite data types; with a composite result type, an entire + "table" of results will be returned. + RETURN QUERY appends the results of executing + a query to the function's result set. RETURN + NEXT and RETURN QUERY can be freely + intermixed in a single set-returning function, in which case + their results will be concatenated. +

RETURN NEXT and RETURN + QUERY do not actually return from the function — + they simply append zero or more rows to the function's result + set. Execution then continues with the next statement in the + PL/pgSQL function. As successive + RETURN NEXT or RETURN + QUERY commands are executed, the result set is built + up. A final RETURN, which should have no + argument, causes control to exit the function (or you can just + let control reach the end of the function). +

RETURN QUERY has a variant + RETURN QUERY EXECUTE, which specifies the + query to be executed dynamically. Parameter expressions can + be inserted into the computed query string via USING, + in just the same way as in the EXECUTE command. +

If you declared the function with output parameters, write just + RETURN NEXT with no expression. On each + execution, the current values of the output parameter + variable(s) will be saved for eventual return as a row of the + result. Note that you must declare the function as returning + SETOF record when there are multiple output + parameters, or SETOF sometype + when there is just one output parameter of type + sometype, in order to create a set-returning + function with output parameters. +

Here is an example of a function using RETURN + NEXT: + +

CREATE TABLE foo (fooid INT, foosubid INT, fooname TEXT);
+INSERT INTO foo VALUES (1, 2, 'three');
+INSERT INTO foo VALUES (4, 5, 'six');
+
+CREATE OR REPLACE FUNCTION getAllFoo() RETURNS SETOF foo AS
+$BODY$
+DECLARE
+    r foo%rowtype;
+BEGIN
+    FOR r IN SELECT * FROM foo
+    WHERE fooid > 0
+    LOOP
+        -- can do some processing here
+        RETURN NEXT r; -- return current row of SELECT
+    END LOOP;
+    RETURN;
+END
+$BODY$
+LANGUAGE 'plpgsql' ;
+
+SELECT * FROM getallfoo();

+

Note: The current implementation of RETURN NEXT + and RETURN QUERY stores the entire result set + before returning from the function, as discussed above. That + means that if a PL/pgSQL function produces a + very large result set, performance might be poor: data will be + written to disk to avoid memory exhaustion, but the function + itself will not return until the entire result set has been + generated. A future version of PL/pgSQL might + allow users to define set-returning functions + that do not have this limitation. Currently, the point at + which data begins being written to disk is controlled by the + work_mem + configuration variable. Administrators who have sufficient + memory to store larger result sets in memory should consider + increasing this parameter. +

39.6.2. Conditionals

IF and CASE statements let you execute + alternative commands based on certain conditions. + PL/pgSQL has three forms of IF: +

  • IF ... THEN

  • IF ... THEN ... ELSE

  • IF ... THEN ... ELSIF ... THEN ... ELSE

+ + and two forms of CASE: +

  • CASE ... WHEN ... THEN ... ELSE ... END CASE

  • CASE WHEN ... THEN ... ELSE ... END CASE

+

39.6.2.1. IF-THEN

IF boolean-expression THEN
+    statements
+END IF;

IF-THEN statements are the simplest form of + IF. The statements between + THEN and END IF will be + executed if the condition is true. Otherwise, they are + skipped. +

Example: +

IF v_user_id <> 0 THEN
+    UPDATE users SET email = v_email WHERE user_id = v_user_id;
+END IF;

+

39.6.2.2. IF-THEN-ELSE

IF boolean-expression THEN
+    statements
+ELSE
+    statements
+END IF;

IF-THEN-ELSE statements add to + IF-THEN by letting you specify an + alternative set of statements that should be executed if the + condition is not true. (Note this includes the case where the + condition evaluates to NULL.) +

Examples: +

IF parentid IS NULL OR parentid = ''
+THEN
+    RETURN fullname;
+ELSE
+    RETURN hp_true_filename(parentid) || '/' || fullname;
+END IF;

+ +

IF v_count > 0 THEN
+    INSERT INTO users_count (count) VALUES (v_count);
+    RETURN 't';
+ELSE
+    RETURN 'f';
+END IF;

+

39.6.2.3. IF-THEN-ELSIF

IF boolean-expression THEN
+    statements
+[ ELSIF boolean-expression THEN
+    statements
+[ ELSIF boolean-expression THEN
+    statements
+    ...]]
+[ ELSE
+    statements ]
+END IF;

Sometimes there are more than just two alternatives. + IF-THEN-ELSIF provides a convenient + method of checking several alternatives in turn. + The IF conditions are tested successively + until the first one that is true is found. Then the + associated statement(s) are executed, after which control + passes to the next statement after END IF. + (Any subsequent IF conditions are not + tested.) If none of the IF conditions is true, + then the ELSE block (if any) is executed. +

Here is an example: + +

IF number = 0 THEN
+    result := 'zero';
+ELSIF number > 0 THEN
+    result := 'positive';
+ELSIF number < 0 THEN
+    result := 'negative';
+ELSE
+    -- hmm, the only other possibility is that number is null
+    result := 'NULL';
+END IF;

+

The key word ELSIF can also be spelled + ELSEIF. +

An alternative way of accomplishing the same task is to nest + IF-THEN-ELSE statements, as in the + following example: + +

IF demo_row.sex = 'm' THEN
+    pretty_sex := 'man';
+ELSE
+    IF demo_row.sex = 'f' THEN
+        pretty_sex := 'woman';
+    END IF;
+END IF;

+

However, this method requires writing a matching END IF + for each IF, so it is much more cumbersome than + using ELSIF when there are many alternatives. +

39.6.2.4. Simple CASE

CASE search-expression
+    WHEN expression [, expression [ ... ]] THEN
+      statements
+  [ WHEN expression [, expression [ ... ]] THEN
+      statements
+    ... ]
+  [ ELSE
+      statements ]
+END CASE;

The simple form of CASE provides conditional execution + based on equality of operands. The search-expression + is evaluated (once) and successively compared to each + expression in the WHEN clauses. + If a match is found, then the corresponding + statements are executed, and then control + passes to the next statement after END CASE. (Subsequent + WHEN expressions are not evaluated.) If no match is + found, the ELSE statements are + executed; but if ELSE is not present, then a + CASE_NOT_FOUND exception is raised. +

Here is a simple example: + +

CASE x
+    WHEN 1, 2 THEN
+        msg := 'one or two';
+    ELSE
+        msg := 'other value than one or two';
+END CASE;

+

39.6.2.5. Searched CASE

CASE
+    WHEN boolean-expression THEN
+      statements
+  [ WHEN boolean-expression THEN
+      statements
+    ... ]
+  [ ELSE
+      statements ]
+END CASE;

The searched form of CASE provides conditional execution + based on truth of Boolean expressions. Each WHEN clause's + boolean-expression is evaluated in turn, + until one is found that yields true. Then the + corresponding statements are executed, and + then control passes to the next statement after END CASE. + (Subsequent WHEN expressions are not evaluated.) + If no true result is found, the ELSE + statements are executed; + but if ELSE is not present, then a + CASE_NOT_FOUND exception is raised. +

Here is an example: + +

CASE
+    WHEN x BETWEEN 0 AND 10 THEN
+        msg := 'value is between zero and ten';
+    WHEN x BETWEEN 11 AND 20 THEN
+        msg := 'value is between eleven and twenty';
+END CASE;

+

This form of CASE is entirely equivalent to + IF-THEN-ELSIF, except for the rule that reaching + an omitted ELSE clause results in an error rather + than doing nothing. +

39.6.3. Simple Loops

With the LOOP, EXIT, + CONTINUE, WHILE, FOR, + and FOREACH statements, you can arrange for your + PL/pgSQL function to repeat a series of commands. +

39.6.3.1. LOOP

[ <<label>> ]
+LOOP
+    statements
+END LOOP [ label ];

LOOP defines an unconditional loop that is repeated + indefinitely until terminated by an EXIT or + RETURN statement. The optional + label can be used by EXIT + and CONTINUE statements within nested loops to + specify which loop those statements refer to. +

39.6.3.2. EXIT

EXIT [ label ] [ WHEN boolean-expression ];

If no label is given, the innermost + loop is terminated and the statement following END + LOOP is executed next. If label + is given, it must be the label of the current or some outer + level of nested loop or block. Then the named loop or block is + terminated and control continues with the statement after the + loop's/block's corresponding END. +

If WHEN is specified, the loop exit occurs only if + boolean-expression is true. Otherwise, control passes + to the statement after EXIT. +

EXIT can be used with all types of loops; it is + not limited to use with unconditional loops. +

When used with a + BEGIN block, EXIT passes + control to the next statement after the end of the block. + Note that a label must be used for this purpose; an unlabelled + EXIT is never considered to match a + BEGIN block. (This is a change from + pre-8.4 releases of PostgreSQL, which + would allow an unlabelled EXIT to match + a BEGIN block.) +

Examples: +

LOOP
+    -- some computations
+    IF count > 0 THEN
+        EXIT;  -- exit loop
+    END IF;
+END LOOP;
+
+LOOP
+    -- some computations
+    EXIT WHEN count > 0;  -- same result as previous example
+END LOOP;
+
+<<ablock>>
+BEGIN
+    -- some computations
+    IF stocks > 100000 THEN
+        EXIT ablock;  -- causes exit from the BEGIN block
+    END IF;
+    -- computations here will be skipped when stocks > 100000
+END;

+

39.6.3.3. CONTINUE

CONTINUE [ label ] [ WHEN boolean-expression ];

If no label is given, the next iteration of + the innermost loop is begun. That is, all statements remaining + in the loop body are skipped, and control returns + to the loop control expression (if any) to determine whether + another loop iteration is needed. + If label is present, it + specifies the label of the loop whose execution will be + continued. +

If WHEN is specified, the next iteration of the + loop is begun only if boolean-expression is + true. Otherwise, control passes to the statement after + CONTINUE. +

CONTINUE can be used with all types of loops; it + is not limited to use with unconditional loops. +

Examples: +

LOOP
+    -- some computations
+    EXIT WHEN count > 100;
+    CONTINUE WHEN count < 50;
+    -- some computations for count IN [50 .. 100]
+END LOOP;

+

39.6.3.4. WHILE

[ <<label>> ]
+WHILE boolean-expression LOOP
+    statements
+END LOOP [ label ];

The WHILE statement repeats a + sequence of statements so long as the + boolean-expression + evaluates to true. The expression is checked just before + each entry to the loop body. +

For example: +

WHILE amount_owed > 0 AND gift_certificate_balance > 0 LOOP
+    -- some computations here
+END LOOP;
+
+WHILE NOT done LOOP
+    -- some computations here
+END LOOP;

+

39.6.3.5. FOR (Integer Variant)

[ <<label>> ]
+FOR name IN [ REVERSE ] expression .. expression [ BY expression ] LOOP
+    statements
+END LOOP [ label ];

This form of FOR creates a loop that iterates over a range + of integer values. The variable + name is automatically defined as type + integer and exists only inside the loop (any existing + definition of the variable name is ignored within the loop). + The two expressions giving + the lower and upper bound of the range are evaluated once when entering + the loop. If the BY clause isn't specified the iteration + step is 1, otherwise it's the value specified in the BY + clause, which again is evaluated once on loop entry. + If REVERSE is specified then the step value is + subtracted, rather than added, after each iteration. +

Some examples of integer FOR loops: +

FOR i IN 1..10 LOOP
+    -- i will take on the values 1,2,3,4,5,6,7,8,9,10 within the loop
+END LOOP;
+
+FOR i IN REVERSE 10..1 LOOP
+    -- i will take on the values 10,9,8,7,6,5,4,3,2,1 within the loop
+END LOOP;
+
+FOR i IN REVERSE 10..1 BY 2 LOOP
+    -- i will take on the values 10,8,6,4,2 within the loop
+END LOOP;

+

If the lower bound is greater than the upper bound (or less than, + in the REVERSE case), the loop body is not + executed at all. No error is raised. +

If a label is attached to the + FOR loop then the integer loop variable can be + referenced with a qualified name, using that + label. +

39.6.4. Looping Through Query Results

Using a different type of FOR loop, you can iterate through + the results of a query and manipulate that data + accordingly. The syntax is: +

[ <<label>> ]
+FOR target IN query LOOP
+    statements
+END LOOP [ label ];

+ The target is a record variable, row variable, + or comma-separated list of scalar variables. + The target is successively assigned each row + resulting from the query and the loop body is + executed for each row. Here is an example: +

CREATE FUNCTION cs_refresh_mviews() RETURNS integer AS $$
+DECLARE
+    mviews RECORD;
+BEGIN
+    RAISE NOTICE 'Refreshing materialized views...';
+
+    FOR mviews IN SELECT * FROM cs_materialized_views ORDER BY sort_key LOOP
+
+        -- Now "mviews" has one record from cs_materialized_views
+
+        RAISE NOTICE 'Refreshing materialized view %s ...', quote_ident(mviews.mv_name);
+        EXECUTE 'TRUNCATE TABLE ' || quote_ident(mviews.mv_name);
+        EXECUTE 'INSERT INTO '
+                   || quote_ident(mviews.mv_name) || ' '
+                   || mviews.mv_query;
+    END LOOP;
+
+    RAISE NOTICE 'Done refreshing materialized views.';
+    RETURN 1;
+END;
+$$ LANGUAGE plpgsql;

+ + If the loop is terminated by an EXIT statement, the last + assigned row value is still accessible after the loop. +

The query used in this type of FOR + statement can be any SQL command that returns rows to the caller: + SELECT is the most common case, + but you can also use INSERT, UPDATE, or + DELETE with a RETURNING clause. Some utility + commands such as EXPLAIN will work too. +

PL/pgSQL variables are substituted into the query text, + and the query plan is cached for possible re-use, as discussed in + detail in Section 39.10.1 and + Section 39.10.2. +

The FOR-IN-EXECUTE statement is another way to iterate over + rows: +

[ <<label>> ]
+FOR target IN EXECUTE text_expression [ USING expression [, ... ] ] LOOP
+    statements
+END LOOP [ label ];

+ This is like the previous form, except that the source query + is specified as a string expression, which is evaluated and replanned + on each entry to the FOR loop. This allows the programmer to + choose the speed of a preplanned query or the flexibility of a dynamic + query, just as with a plain EXECUTE statement. + As with EXECUTE, parameter values can be inserted + into the dynamic command via USING. +

Another way to specify the query whose results should be iterated + through is to declare it as a cursor. This is described in + Section 39.7.4. +

39.6.5. Looping Through Arrays

The FOREACH loop is much like a FOR loop, + but instead of iterating through the rows returned by a SQL query, + it iterates through the elements of an array value. + (In general, FOREACH is meant for looping through + components of a composite-valued expression; variants for looping + through composites besides arrays may be added in future.) + The FOREACH statement to loop over an array is: + +

[ <<label>> ]
+FOREACH target [ SLICE number ] IN ARRAY expression LOOP
+    statements
+END LOOP [ label ];

+

Without SLICE, or if SLICE 0 is specified, + the loop iterates through individual elements of the array produced + by evaluating the expression. + The target variable is assigned each + element value in sequence, and the loop body is executed for each element. + Here is an example of looping through the elements of an integer + array: + +

CREATE FUNCTION sum(int[]) RETURNS int8 AS $$
+DECLARE
+  s int8 := 0;
+  x int;
+BEGIN
+  FOREACH x IN ARRAY $1
+  LOOP
+    s := s + x;
+  END LOOP;
+  RETURN s;
+END;
+$$ LANGUAGE plpgsql;

+ + The elements are visited in storage order, regardless of the number of + array dimensions. Although the target is + usually just a single variable, it can be a list of variables when + looping through an array of composite values (records). In that case, + for each array element, the variables are assigned from successive + columns of the composite value. +

With a positive SLICE value, FOREACH + iterates through slices of the array rather than single elements. + The SLICE value must be an integer constant not larger + than the number of dimensions of the array. The + target variable must be an array, + and it receives successive slices of the array value, where each slice + is of the number of dimensions specified by SLICE. + Here is an example of iterating through one-dimensional slices: + +

CREATE FUNCTION scan_rows(int[]) RETURNS void AS $$
+DECLARE
+  x int[];
+BEGIN
+  FOREACH x SLICE 1 IN ARRAY $1
+  LOOP
+    RAISE NOTICE 'row = %', x;
+  END LOOP;
+END;
+$$ LANGUAGE plpgsql;
+
+SELECT scan_rows(ARRAY[[1,2,3],[4,5,6],[7,8,9],[10,11,12]]);
+
+NOTICE:  row = {1,2,3}
+NOTICE:  row = {4,5,6}
+NOTICE:  row = {7,8,9}
+NOTICE:  row = {10,11,12}

+

39.6.6. Trapping Errors

By default, any error occurring in a PL/pgSQL + function aborts execution of the function, and indeed of the + surrounding transaction as well. You can trap errors and recover + from them by using a BEGIN block with an + EXCEPTION clause. The syntax is an extension of the + normal syntax for a BEGIN block: + +

[ <<label>> ]
+[ DECLARE
+    declarations ]
+BEGIN
+    statements
+EXCEPTION
+    WHEN condition [ OR condition ... ] THEN
+        handler_statements
+    [ WHEN condition [ OR condition ... ] THEN
+          handler_statements
+      ... ]
+END;

+

If no error occurs, this form of block simply executes all the + statements, and then control passes + to the next statement after END. But if an error + occurs within the statements, further + processing of the statements is + abandoned, and control passes to the EXCEPTION list. + The list is searched for the first condition + matching the error that occurred. If a match is found, the + corresponding handler_statements are + executed, and then control passes to the next statement after + END. If no match is found, the error propagates out + as though the EXCEPTION clause were not there at all: + the error can be caught by an enclosing block with + EXCEPTION, or if there is none it aborts processing + of the function. +

The condition names can be any of + those shown in Appendix A. A category + name matches any error within its category. The special + condition name OTHERS matches every error type except + QUERY_CANCELED. (It is possible, but often unwise, + to trap QUERY_CANCELED by name.) Condition names are + not case-sensitive. Also, an error condition can be specified + by SQLSTATE code; for example these are equivalent: +

WHEN division_by_zero THEN ...
+WHEN SQLSTATE '22012' THEN ...

+

If a new error occurs within the selected + handler_statements, it cannot be caught + by this EXCEPTION clause, but is propagated out. + A surrounding EXCEPTION clause could catch it. +

When an error is caught by an EXCEPTION clause, + the local variables of the PL/pgSQL function + remain as they were when the error occurred, but all changes + to persistent database state within the block are rolled back. + As an example, consider this fragment: + +

INSERT INTO mytab(firstname, lastname) VALUES('Tom', 'Jones');
+BEGIN
+    UPDATE mytab SET firstname = 'Joe' WHERE lastname = 'Jones';
+    x := x + 1;
+    y := x / 0;
+EXCEPTION
+    WHEN division_by_zero THEN
+        RAISE NOTICE 'caught division_by_zero';
+        RETURN x;
+END;

+ + When control reaches the assignment to y, it will + fail with a division_by_zero error. This will be caught by + the EXCEPTION clause. The value returned in the + RETURN statement will be the incremented value of + x, but the effects of the UPDATE command will + have been rolled back. The INSERT command preceding the + block is not rolled back, however, so the end result is that the database + contains Tom Jones not Joe Jones. +

Tip: A block containing an EXCEPTION clause is significantly + more expensive to enter and exit than a block without one. Therefore, + don't use EXCEPTION without need. +

Example 39-2. Exceptions with UPDATE/INSERT

This example uses exception handling to perform either + UPDATE or INSERT, as appropriate: + +

CREATE TABLE db (a INT PRIMARY KEY, b TEXT);
+
+CREATE FUNCTION merge_db(key INT, data TEXT) RETURNS VOID AS
+$$
+BEGIN
+    LOOP
+        -- first try to update the key
+        UPDATE db SET b = data WHERE a = key;
+        IF found THEN
+            RETURN;
+        END IF;
+        -- not there, so try to insert the key
+        -- if someone else inserts the same key concurrently,
+        -- we could get a unique-key failure
+        BEGIN
+            INSERT INTO db(a,b) VALUES (key, data);
+            RETURN;
+        EXCEPTION WHEN unique_violation THEN
+            -- Do nothing, and loop to try the UPDATE again.
+        END;
+    END LOOP;
+END;
+$$
+LANGUAGE plpgsql;
+
+SELECT merge_db(1, 'david');
+SELECT merge_db(1, 'dennis');

+ + This coding assumes the unique_violation error is caused by + the INSERT, and not by, say, an INSERT in a + trigger function on the table. It might also misbehave if there is + more than one unique index on the table, since it will retry the + operation regardless of which index caused the error. + More safety could be had by using the + features discussed next to check that the trapped error was the one + expected. +

39.6.6.1. Obtaining information about an error

Exception handlers frequently need to identify the specific error that + occurred. There are two ways to get information about the current + exception in PL/pgSQL: special variables and the + GET STACKED DIAGNOSTICS command. +

Within an exception handler, the special variable + SQLSTATE contains the error code that corresponds to + the exception that was raised (refer to Table A-1 + for a list of possible error codes). The special variable + SQLERRM contains the error message associated with the + exception. These variables are undefined outside exception handlers. +

Within an exception handler, one may also retrieve + information about the current exception by using the + GET STACKED DIAGNOSTICS command, which has the form: + +

GET STACKED DIAGNOSTICS variable = item [ , ... ];

+ + Each item is a key word identifying a status + value to be assigned to the specified variable (which should be + of the right data type to receive it). The currently available + status items are shown in Table 39-1. +

Table 39-1. Error diagnostics values

NameTypeDescription
RETURNED_SQLSTATEtextthe SQLSTATE error code of the exception
MESSAGE_TEXTtextthe text of the exception's primary message
PG_EXCEPTION_DETAILtextthe text of the exception's detail message, if any
PG_EXCEPTION_HINTtextthe text of the exception's hint message, if any
PG_EXCEPTION_CONTEXTtextline(s) of text describing the call stack

If the exception did not set a value for an item, an empty string + will be returned. +

Here is an example: +

DECLARE
+  text_var1 text;
+  text_var2 text;
+  text_var3 text;
+BEGIN
+  -- some processing which might cause an exception
+  ...
+EXCEPTION WHEN OTHERS THEN
+  GET STACKED DIAGNOSTICS text_var1 = MESSAGE_TEXT,
+                          text_var2 = PG_EXCEPTION_DETAIL,
+                          text_var3 = PG_EXCEPTION_HINT;
+END;

+


PrevHomeNext
Basic StatementsUpCursors
\ No newline at end of file diff --git a/doc/src/sgml/html/plpgsql-cursors.html b/doc/src/sgml/html/plpgsql-cursors.html new file mode 100644 index 000000000..83d0341c6 --- /dev/null +++ b/doc/src/sgml/html/plpgsql-cursors.html @@ -0,0 +1,1385 @@ + +Cursors
PostgreSQL 9.2.2 Documentation
PrevUpChapter 39. PL/pgSQL - SQL Procedural LanguageNext

39.7. Cursors

Rather than executing a whole query at once, it is possible to set + up a cursor that encapsulates the query, and then read + the query result a few rows at a time. One reason for doing this is + to avoid memory overrun when the result contains a large number of + rows. (However, PL/pgSQL users do not normally need + to worry about that, since FOR loops automatically use a cursor + internally to avoid memory problems.) A more interesting usage is to + return a reference to a cursor that a function has created, allowing the + caller to read the rows. This provides an efficient way to return + large row sets from functions. +

39.7.1. Declaring Cursor Variables

All access to cursors in PL/pgSQL goes through + cursor variables, which are always of the special data type + refcursor. One way to create a cursor variable + is just to declare it as a variable of type refcursor. + Another way is to use the cursor declaration syntax, + which in general is: +

name [ [ NO ] SCROLL ] CURSOR [ ( arguments ) ] FOR query;

+ (FOR can be replaced by IS for + Oracle compatibility.) + If SCROLL is specified, the cursor will be capable of + scrolling backward; if NO SCROLL is specified, backward + fetches will be rejected; if neither specification appears, it is + query-dependent whether backward fetches will be allowed. + arguments, if specified, is a + comma-separated list of pairs name + datatype that define names to be + replaced by parameter values in the given query. The actual + values to substitute for these names will be specified later, + when the cursor is opened. +

Some examples: +

DECLARE
+    curs1 refcursor;
+    curs2 CURSOR FOR SELECT * FROM tenk1;
+    curs3 CURSOR (key integer) FOR SELECT * FROM tenk1 WHERE unique1 = key;

+ All three of these variables have the data type refcursor, + but the first can be used with any query, while the second has + a fully specified query already bound to it, and the last + has a parameterized query bound to it. (key will be + replaced by an integer parameter value when the cursor is opened.) + The variable curs1 + is said to be unbound since it is not bound to + any particular query. +

39.7.2. Opening Cursors

Before a cursor can be used to retrieve rows, it must be + opened. (This is the equivalent action to the SQL + command DECLARE CURSOR.) PL/pgSQL has + three forms of the OPEN statement, two of which use unbound + cursor variables while the third uses a bound cursor variable. +

Note: Bound cursor variables can also be used without explicitly opening the cursor, + via the FOR statement described in + Section 39.7.4. +

39.7.2.1. OPEN FOR query

OPEN unbound_cursorvar [ [ NO ] SCROLL ] FOR query;

The cursor variable is opened and given the specified query to + execute. The cursor cannot be open already, and it must have been + declared as an unbound cursor variable (that is, as a simple + refcursor variable). The query must be a + SELECT, or something else that returns rows + (such as EXPLAIN). The query + is treated in the same way as other SQL commands in + PL/pgSQL: PL/pgSQL + variable names are substituted, and the query plan is cached for + possible reuse. When a PL/pgSQL + variable is substituted into the cursor query, the value that is + substituted is the one it has at the time of the OPEN; + subsequent changes to the variable will not affect the cursor's + behavior. + The SCROLL and NO SCROLL + options have the same meanings as for a bound cursor. +

An example: +

OPEN curs1 FOR SELECT * FROM foo WHERE key = mykey;

+

39.7.2.2. OPEN FOR EXECUTE

OPEN unbound_cursorvar [ [ NO ] SCROLL ] FOR EXECUTE query_string
+                                     [ USING expression [, ... ] ];

The cursor variable is opened and given the specified query to + execute. The cursor cannot be open already, and it must have been + declared as an unbound cursor variable (that is, as a simple + refcursor variable). The query is specified as a string + expression, in the same way as in the EXECUTE + command. As usual, this gives flexibility so the query plan can vary + from one run to the next (see Section 39.10.2), + and it also means that variable substitution is not done on the + command string. As with EXECUTE, parameter values + can be inserted into the dynamic command via USING. + The SCROLL and + NO SCROLL options have the same meanings as for a bound + cursor. +

An example: +

OPEN curs1 FOR EXECUTE 'SELECT * FROM ' || quote_ident(tabname)
+                                        || ' WHERE col1 = $1' USING keyvalue;

+ In this example, the table name is inserted into the query textually, + so use of quote_ident() is recommended to guard against + SQL injection. The comparison value for col1 is inserted + via a USING parameter, so it needs no quoting. +

39.7.2.3. Opening a Bound Cursor

OPEN bound_cursorvar [ ( [ argument_name := ] argument_value [, ...] ) ];

This form of OPEN is used to open a cursor + variable whose query was bound to it when it was declared. The + cursor cannot be open already. A list of actual argument value + expressions must appear if and only if the cursor was declared to + take arguments. These values will be substituted in the query. +

The query plan for a bound cursor is always considered cacheable; + there is no equivalent of EXECUTE in this case. + Notice that SCROLL and NO SCROLL cannot be + specified in OPEN, as the cursor's scrolling + behavior was already determined. +

Argument values can be passed using either positional + or named notation. In positional + notation, all arguments are specified in order. In named notation, + each argument's name is specified using := to + separate it from the argument expression. Similar to calling + functions, described in Section 4.3, it + is also allowed to mix positional and named notation. +

Examples (these use the cursor declaration examples above): +

OPEN curs2;
+OPEN curs3(42);
+OPEN curs3(key := 42);

+

Because variable substitution is done on a bound cursor's query, + there are really two ways to pass values into the cursor: either + with an explicit argument to OPEN, or implicitly by + referencing a PL/pgSQL variable in the query. + However, only variables declared before the bound cursor was + declared will be substituted into it. In either case the value to + be passed is determined at the time of the OPEN. + For example, another way to get the same effect as the + curs3 example above is +

DECLARE
+    key integer;
+    curs4 CURSOR FOR SELECT * FROM tenk1 WHERE unique1 = key;
+BEGIN
+    key := 42;
+    OPEN curs4;

+

39.7.3. Using Cursors

Once a cursor has been opened, it can be manipulated with the + statements described here. +

These manipulations need not occur in the same function that + opened the cursor to begin with. You can return a refcursor + value out of a function and let the caller operate on the cursor. + (Internally, a refcursor value is simply the string name + of a so-called portal containing the active query for the cursor. This name + can be passed around, assigned to other refcursor variables, + and so on, without disturbing the portal.) +

All portals are implicitly closed at transaction end. Therefore + a refcursor value is usable to reference an open cursor + only until the end of the transaction. +

39.7.3.1. FETCH

FETCH [ direction { FROM | IN } ] cursor INTO target;

FETCH retrieves the next row from the + cursor into a target, which might be a row variable, a record + variable, or a comma-separated list of simple variables, just like + SELECT INTO. If there is no next row, the + target is set to NULL(s). As with SELECT + INTO, the special variable FOUND can + be checked to see whether a row was obtained or not. +

The direction clause can be any of the + variants allowed in the SQL FETCH + command except the ones that can fetch + more than one row; namely, it can be + NEXT, + PRIOR, + FIRST, + LAST, + ABSOLUTE count, + RELATIVE count, + FORWARD, or + BACKWARD. + Omitting direction is the same + as specifying NEXT. + direction values that require moving + backward are likely to fail unless the cursor was declared or opened + with the SCROLL option. +

cursor must be the name of a refcursor + variable that references an open cursor portal. +

Examples: +

FETCH curs1 INTO rowvar;
+FETCH curs2 INTO foo, bar, baz;
+FETCH LAST FROM curs3 INTO x, y;
+FETCH RELATIVE -2 FROM curs4 INTO x;

+

39.7.3.2. MOVE

MOVE [ direction { FROM | IN } ] cursor;

MOVE repositions a cursor without retrieving + any data. MOVE works exactly like the + FETCH command, except it only repositions the + cursor and does not return the row moved to. As with SELECT + INTO, the special variable FOUND can + be checked to see whether there was a next row to move to. +

The direction clause can be any of the + variants allowed in the SQL FETCH + command, namely + NEXT, + PRIOR, + FIRST, + LAST, + ABSOLUTE count, + RELATIVE count, + ALL, + FORWARD [ count | ALL ], or + BACKWARD [ count | ALL ]. + Omitting direction is the same + as specifying NEXT. + direction values that require moving + backward are likely to fail unless the cursor was declared or opened + with the SCROLL option. +

Examples: +

MOVE curs1;
+MOVE LAST FROM curs3;
+MOVE RELATIVE -2 FROM curs4;
+MOVE FORWARD 2 FROM curs4;

+

39.7.3.3. UPDATE/DELETE WHERE CURRENT OF

UPDATE table SET ... WHERE CURRENT OF cursor;
+DELETE FROM table WHERE CURRENT OF cursor;

When a cursor is positioned on a table row, that row can be updated + or deleted using the cursor to identify the row. There are + restrictions on what the cursor's query can be (in particular, + no grouping) and it's best to use FOR UPDATE in the + cursor. For more information see the + DECLARE + reference page. +

An example: +

UPDATE foo SET dataval = myval WHERE CURRENT OF curs1;

+

39.7.3.4. CLOSE

CLOSE cursor;

CLOSE closes the portal underlying an open + cursor. This can be used to release resources earlier than end of + transaction, or to free up the cursor variable to be opened again. +

An example: +

CLOSE curs1;

+

39.7.3.5. Returning Cursors

PL/pgSQL functions can return cursors to the + caller. This is useful to return multiple rows or columns, + especially with very large result sets. To do this, the function + opens the cursor and returns the cursor name to the caller (or simply + opens the cursor using a portal name specified by or otherwise known + to the caller). The caller can then fetch rows from the cursor. The + cursor can be closed by the caller, or it will be closed automatically + when the transaction closes. +

The portal name used for a cursor can be specified by the + programmer or automatically generated. To specify a portal name, + simply assign a string to the refcursor variable before + opening it. The string value of the refcursor variable + will be used by OPEN as the name of the underlying portal. + However, if the refcursor variable is null, + OPEN automatically generates a name that does not + conflict with any existing portal, and assigns it to the + refcursor variable. +

Note: A bound cursor variable is initialized to the string value + representing its name, so that the portal name is the same as + the cursor variable name, unless the programmer overrides it + by assignment before opening the cursor. But an unbound cursor + variable defaults to the null value initially, so it will receive + an automatically-generated unique name, unless overridden. +

The following example shows one way a cursor name can be supplied by + the caller: + +

CREATE TABLE test (col text);
+INSERT INTO test VALUES ('123');
+
+CREATE FUNCTION reffunc(refcursor) RETURNS refcursor AS '
+BEGIN
+    OPEN $1 FOR SELECT col FROM test;
+    RETURN $1;
+END;
+' LANGUAGE plpgsql;
+
+BEGIN;
+SELECT reffunc('funccursor');
+FETCH ALL IN funccursor;
+COMMIT;

+

The following example uses automatic cursor name generation: + +

CREATE FUNCTION reffunc2() RETURNS refcursor AS '
+DECLARE
+    ref refcursor;
+BEGIN
+    OPEN ref FOR SELECT col FROM test;
+    RETURN ref;
+END;
+' LANGUAGE plpgsql;
+
+-- need to be in a transaction to use cursors.
+BEGIN;
+SELECT reffunc2();
+
+      reffunc2
+--------------------
+ <unnamed cursor 1>
+(1 row)
+
+FETCH ALL IN "<unnamed cursor 1>";
+COMMIT;

+

The following example shows one way to return multiple cursors + from a single function: + +

CREATE FUNCTION myfunc(refcursor, refcursor) RETURNS SETOF refcursor AS $$
+BEGIN
+    OPEN $1 FOR SELECT * FROM table_1;
+    RETURN NEXT $1;
+    OPEN $2 FOR SELECT * FROM table_2;
+    RETURN NEXT $2;
+END;
+$$ LANGUAGE plpgsql;
+
+-- need to be in a transaction to use cursors.
+BEGIN;
+
+SELECT * FROM myfunc('a', 'b');
+
+FETCH ALL FROM a;
+FETCH ALL FROM b;
+COMMIT;

+

39.7.4. Looping Through a Cursor's Result

There is a variant of the FOR statement that allows + iterating through the rows returned by a cursor. The syntax is: + +

[ <<label>> ]
+FOR recordvar IN bound_cursorvar [ ( [ argument_name := ] argument_value [, ...] ) ] LOOP
+    statements
+END LOOP [ label ];

+ + The cursor variable must have been bound to some query when it was + declared, and it cannot be open already. The + FOR statement automatically opens the cursor, and it closes + the cursor again when the loop exits. A list of actual argument value + expressions must appear if and only if the cursor was declared to take + arguments. These values will be substituted in the query, in just + the same way as during an OPEN (see Section 39.7.2.3). +

The variable recordvar is automatically + defined as type record and exists only inside the loop (any + existing definition of the variable name is ignored within the loop). + Each row returned by the cursor is successively assigned to this + record variable and the loop body is executed. +


PrevHomeNext
Control StructuresUpErrors and Messages
\ No newline at end of file diff --git a/doc/src/sgml/html/plpgsql-declarations.html b/doc/src/sgml/html/plpgsql-declarations.html new file mode 100644 index 000000000..489869dce --- /dev/null +++ b/doc/src/sgml/html/plpgsql-declarations.html @@ -0,0 +1,1076 @@ + +Declarations
PostgreSQL 9.2.2 Documentation
PrevUpChapter 39. PL/pgSQL - SQL Procedural LanguageNext

39.3. Declarations

All variables used in a block must be declared in the + declarations section of the block. + (The only exceptions are that the loop variable of a FOR loop + iterating over a range of integer values is automatically declared as an + integer variable, and likewise the loop variable of a FOR loop + iterating over a cursor's result is automatically declared as a + record variable.) +

PL/pgSQL variables can have any SQL data type, such as + integer, varchar, and + char. +

Here are some examples of variable declarations: +

user_id integer;
+quantity numeric(5);
+url varchar;
+myrow tablename%ROWTYPE;
+myfield tablename.columnname%TYPE;
+arow RECORD;

+

The general syntax of a variable declaration is: +

name [ CONSTANT ] type [ COLLATE collation_name ] [ NOT NULL ] [ { DEFAULT | := } expression ];

+ The DEFAULT clause, if given, specifies the initial value assigned + to the variable when the block is entered. If the DEFAULT clause + is not given then the variable is initialized to the + SQL null value. + The CONSTANT option prevents the variable from being + assigned to after initialization, so that its value will remain constant + for the duration of the block. + The COLLATE option specifies a collation to use for the + variable (see Section 39.3.6). + If NOT NULL + is specified, an assignment of a null value results in a run-time + error. All variables declared as NOT NULL + must have a nonnull default value specified. +

A variable's default value is evaluated and assigned to the variable + each time the block is entered (not just once per function call). + So, for example, assigning now() to a variable of type + timestamp causes the variable to have the + time of the current function call, not the time when the function was + precompiled. +

Examples: +

quantity integer DEFAULT 32;
+url varchar := 'http://mysite.com';
+user_id CONSTANT integer := 10;

+

39.3.1. Declaring Function Parameters

Parameters passed to functions are named with the identifiers + $1, $2, + etc. Optionally, aliases can be declared for + $n + parameter names for increased readability. Either the alias or the + numeric identifier can then be used to refer to the parameter value. +

There are two ways to create an alias. The preferred way is to give a + name to the parameter in the CREATE FUNCTION command, + for example: +

CREATE FUNCTION sales_tax(subtotal real) RETURNS real AS $$
+BEGIN
+    RETURN subtotal * 0.06;
+END;
+$$ LANGUAGE plpgsql;

+ The other way, which was the only way available before + PostgreSQL 8.0, is to explicitly + declare an alias, using the declaration syntax + +

name ALIAS FOR $n;

+ + The same example in this style looks like: +

CREATE FUNCTION sales_tax(real) RETURNS real AS $$
+DECLARE
+    subtotal ALIAS FOR $1;
+BEGIN
+    RETURN subtotal * 0.06;
+END;
+$$ LANGUAGE plpgsql;

+

Note: These two examples are not perfectly equivalent. In the first case, + subtotal could be referenced as + sales_tax.subtotal, but in the second case it could not. + (Had we attached a label to the inner block, subtotal could + be qualified with that label, instead.) +

Some more examples: +

CREATE FUNCTION instr(varchar, integer) RETURNS integer AS $$
+DECLARE
+    v_string ALIAS FOR $1;
+    index ALIAS FOR $2;
+BEGIN
+    -- some computations using v_string and index here
+END;
+$$ LANGUAGE plpgsql;
+
+
+CREATE FUNCTION concat_selected_fields(in_t sometablename) RETURNS text AS $$
+BEGIN
+    RETURN in_t.f1 || in_t.f3 || in_t.f5 || in_t.f7;
+END;
+$$ LANGUAGE plpgsql;

+

When a PL/pgSQL function is declared + with output parameters, the output parameters are given + $n names and optional + aliases in just the same way as the normal input parameters. An + output parameter is effectively a variable that starts out NULL; + it should be assigned to during the execution of the function. + The final value of the parameter is what is returned. For instance, + the sales-tax example could also be done this way: + +

CREATE FUNCTION sales_tax(subtotal real, OUT tax real) AS $$
+BEGIN
+    tax := subtotal * 0.06;
+END;
+$$ LANGUAGE plpgsql;

+ + Notice that we omitted RETURNS real — we could have + included it, but it would be redundant. +

Output parameters are most useful when returning multiple values. + A trivial example is: + +

CREATE FUNCTION sum_n_product(x int, y int, OUT sum int, OUT prod int) AS $$
+BEGIN
+    sum := x + y;
+    prod := x * y;
+END;
+$$ LANGUAGE plpgsql;

+ + As discussed in Section 35.4.4, this + effectively creates an anonymous record type for the function's + results. If a RETURNS clause is given, it must say + RETURNS record. +

Another way to declare a PL/pgSQL function + is with RETURNS TABLE, for example: + +

CREATE FUNCTION extended_sales(p_itemno int)
+RETURNS TABLE(quantity int, total numeric) AS $$
+BEGIN
+    RETURN QUERY SELECT quantity, quantity * price FROM sales
+                 WHERE itemno = p_itemno;
+END;
+$$ LANGUAGE plpgsql;

+ + This is exactly equivalent to declaring one or more OUT + parameters and specifying RETURNS SETOF + sometype. +

When the return type of a PL/pgSQL + function is declared as a polymorphic type (anyelement, + anyarray, anynonarray, anyenum, + or anyrange), a special parameter $0 + is created. Its data type is the actual return type of the function, + as deduced from the actual input types (see Section 35.2.5). + This allows the function to access its actual return type + as shown in Section 39.3.3. + $0 is initialized to null and can be modified by + the function, so it can be used to hold the return value if desired, + though that is not required. $0 can also be + given an alias. For example, this function works on any data type + that has a + operator: + +

CREATE FUNCTION add_three_values(v1 anyelement, v2 anyelement, v3 anyelement)
+RETURNS anyelement AS $$
+DECLARE
+    result ALIAS FOR $0;
+BEGIN
+    result := v1 + v2 + v3;
+    RETURN result;
+END;
+$$ LANGUAGE plpgsql;

+

The same effect can be had by declaring one or more output parameters as + polymorphic types. In this case the + special $0 parameter is not used; the output + parameters themselves serve the same purpose. For example: + +

CREATE FUNCTION add_three_values(v1 anyelement, v2 anyelement, v3 anyelement,
+                                 OUT sum anyelement)
+AS $$
+BEGIN
+    sum := v1 + v2 + v3;
+END;
+$$ LANGUAGE plpgsql;

+

39.3.2. ALIAS

newname ALIAS FOR oldname;

The ALIAS syntax is more general than is suggested in the + previous section: you can declare an alias for any variable, not just + function parameters. The main practical use for this is to assign + a different name for variables with predetermined names, such as + NEW or OLD within + a trigger procedure. +

Examples: +

DECLARE
+  prior ALIAS FOR old;
+  updated ALIAS FOR new;

+

Since ALIAS creates two different ways to name the same + object, unrestricted use can be confusing. It's best to use it only + for the purpose of overriding predetermined names. +

39.3.3. Copying Types

variable%TYPE

%TYPE provides the data type of a variable or + table column. You can use this to declare variables that will hold + database values. For example, let's say you have a column named + user_id in your users + table. To declare a variable with the same data type as + users.user_id you write: +

user_id users.user_id%TYPE;

+

By using %TYPE you don't need to know the data + type of the structure you are referencing, and most importantly, + if the data type of the referenced item changes in the future (for + instance: you change the type of user_id + from integer to real), you might not need + to change your function definition. +

%TYPE is particularly valuable in polymorphic + functions, since the data types needed for internal variables can + change from one call to the next. Appropriate variables can be + created by applying %TYPE to the function's + arguments or result placeholders. +

39.3.4. Row Types

name table_name%ROWTYPE;
+name composite_type_name;

A variable of a composite type is called a row + variable (or row-type variable). Such a variable + can hold a whole row of a SELECT or FOR + query result, so long as that query's column set matches the + declared type of the variable. + The individual fields of the row value + are accessed using the usual dot notation, for example + rowvar.field. +

A row variable can be declared to have the same type as the rows of + an existing table or view, by using the + table_name%ROWTYPE + notation; or it can be declared by giving a composite type's name. + (Since every table has an associated composite type of the same name, + it actually does not matter in PostgreSQL whether you + write %ROWTYPE or not. But the form with + %ROWTYPE is more portable.) +

Parameters to a function can be + composite types (complete table rows). In that case, the + corresponding identifier $n will be a row variable, and fields can + be selected from it, for example $1.user_id. +

Only the user-defined columns of a table row are accessible in a + row-type variable, not the OID or other system columns (because the + row could be from a view). The fields of the row type inherit the + table's field size or precision for data types such as + char(n). +

Here is an example of using composite types. table1 + and table2 are existing tables having at least the + mentioned fields: + +

CREATE FUNCTION merge_fields(t_row table1) RETURNS text AS $$
+DECLARE
+    t2_row table2%ROWTYPE;
+BEGIN
+    SELECT * INTO t2_row FROM table2 WHERE ... ;
+    RETURN t_row.f1 || t2_row.f3 || t_row.f5 || t2_row.f7;
+END;
+$$ LANGUAGE plpgsql;
+
+SELECT merge_fields(t.*) FROM table1 t WHERE ... ;

+

39.3.5. Record Types

name RECORD;

Record variables are similar to row-type variables, but they have no + predefined structure. They take on the actual row structure of the + row they are assigned during a SELECT or FOR command. The substructure + of a record variable can change each time it is assigned to. + A consequence of this is that until a record variable is first assigned + to, it has no substructure, and any attempt to access a + field in it will draw a run-time error. +

Note that RECORD is not a true data type, only a placeholder. + One should also realize that when a PL/pgSQL + function is declared to return type record, this is not quite the + same concept as a record variable, even though such a function might + use a record variable to hold its result. In both cases the actual row + structure is unknown when the function is written, but for a function + returning record the actual structure is determined when the + calling query is parsed, whereas a record variable can change its row + structure on-the-fly. +

39.3.6. Collation of PL/pgSQL Variables

When a PL/pgSQL function has one or more + parameters of collatable data types, a collation is identified for each + function call depending on the collations assigned to the actual + arguments, as described in Section 22.2. If a collation is + successfully identified (i.e., there are no conflicts of implicit + collations among the arguments) then all the collatable parameters are + treated as having that collation implicitly. This will affect the + behavior of collation-sensitive operations within the function. + For example, consider + +

CREATE FUNCTION less_than(a text, b text) RETURNS boolean AS $$
+BEGIN
+    RETURN a < b;
+END;
+$$ LANGUAGE plpgsql;
+
+SELECT less_than(text_field_1, text_field_2) FROM table1;
+SELECT less_than(text_field_1, text_field_2 COLLATE "C") FROM table1;

+ + The first use of less_than will use the common collation + of text_field_1 and text_field_2 for + the comparison, while the second use will use C collation. +

Furthermore, the identified collation is also assumed as the collation of + any local variables that are of collatable types. Thus this function + would not work any differently if it were written as + +

CREATE FUNCTION less_than(a text, b text) RETURNS boolean AS $$
+DECLARE
+    local_a text := a;
+    local_b text := b;
+BEGIN
+    RETURN local_a < local_b;
+END;
+$$ LANGUAGE plpgsql;

+

If there are no parameters of collatable data types, or no common + collation can be identified for them, then parameters and local variables + use the default collation of their data type (which is usually the + database's default collation, but could be different for variables of + domain types). +

A local variable of a collatable data type can have a different collation + associated with it by including the COLLATE option in its + declaration, for example + +

DECLARE
+    local_a text COLLATE "en_US";

+ + This option overrides the collation that would otherwise be + given to the variable according to the rules above. +

Also, of course explicit COLLATE clauses can be written inside + a function if it is desired to force a particular collation to be used in + a particular operation. For example, + +

CREATE FUNCTION less_than_c(a text, b text) RETURNS boolean AS $$
+BEGIN
+    RETURN a < b COLLATE "C";
+END;
+$$ LANGUAGE plpgsql;

+ + This overrides the collations associated with the table columns, + parameters, or local variables used in the expression, just as would + happen in a plain SQL command. +


PrevHomeNext
Structure of PL/pgSQLUpExpressions
\ No newline at end of file diff --git a/doc/src/sgml/html/plpgsql-development-tips.html b/doc/src/sgml/html/plpgsql-development-tips.html new file mode 100644 index 000000000..2276748f9 --- /dev/null +++ b/doc/src/sgml/html/plpgsql-development-tips.html @@ -0,0 +1,450 @@ + +Tips for Developing in PL/pgSQL
PostgreSQL 9.2.2 Documentation
PrevUpChapter 39. PL/pgSQL - SQL Procedural LanguageNext

39.11. Tips for Developing in PL/pgSQL

One good way to develop in + PL/pgSQL is to use the text editor of your + choice to create your functions, and in another window, use + psql to load and test those functions. + If you are doing it this way, it + is a good idea to write the function using CREATE OR + REPLACE FUNCTION. That way you can just reload the file to update + the function definition. For example: +

CREATE OR REPLACE FUNCTION testfunc(integer) RETURNS integer AS $$
+          ....
+$$ LANGUAGE plpgsql;

+

While running psql, you can load or reload such + a function definition file with: +

\i filename.sql

+ and then immediately issue SQL commands to test the function. +

Another good way to develop in PL/pgSQL is with a + GUI database access tool that facilitates development in a + procedural language. One example of such a tool is + pgAdmin, although others exist. These tools often + provide convenient features such as escaping single quotes and + making it easier to recreate and debug functions. +

39.11.1. Handling of Quotation Marks

The code of a PL/pgSQL function is specified in + CREATE FUNCTION as a string literal. If you + write the string literal in the ordinary way with surrounding + single quotes, then any single quotes inside the function body + must be doubled; likewise any backslashes must be doubled (assuming + escape string syntax is used). + Doubling quotes is at best tedious, and in more complicated cases + the code can become downright incomprehensible, because you can + easily find yourself needing half a dozen or more adjacent quote marks. + It's recommended that you instead write the function body as a + "dollar-quoted" string literal (see Section 4.1.2.4). In the dollar-quoting + approach, you never double any quote marks, but instead take care to + choose a different dollar-quoting delimiter for each level of + nesting you need. For example, you might write the CREATE + FUNCTION command as: +

CREATE OR REPLACE FUNCTION testfunc(integer) RETURNS integer AS $PROC$
+          ....
+$PROC$ LANGUAGE plpgsql;

+ Within this, you might use quote marks for simple literal strings in + SQL commands and $$ to delimit fragments of SQL commands + that you are assembling as strings. If you need to quote text that + includes $$, you could use $Q$, and so on. +

The following chart shows what you have to do when writing quote + marks without dollar quoting. It might be useful when translating + pre-dollar quoting code into something more comprehensible. +

1 quotation mark

To begin and end the function body, for example: +

CREATE FUNCTION foo() RETURNS integer AS '
+          ....
+' LANGUAGE plpgsql;

+ Anywhere within a single-quoted function body, quote marks + must appear in pairs. +

2 quotation marks

For string literals inside the function body, for example: +

a_output := ''Blah'';
+SELECT * FROM users WHERE f_name=''foobar'';

+ In the dollar-quoting approach, you'd just write: +

a_output := 'Blah';
+SELECT * FROM users WHERE f_name='foobar';

+ which is exactly what the PL/pgSQL parser would see + in either case. +

4 quotation marks

When you need a single quotation mark in a string constant inside the + function body, for example: +

a_output := a_output || '' AND name LIKE ''''foobar'''' AND xyz''

+ The value actually appended to a_output would be: + AND name LIKE 'foobar' AND xyz. +

In the dollar-quoting approach, you'd write: +

a_output := a_output || $$ AND name LIKE 'foobar' AND xyz$$

+ being careful that any dollar-quote delimiters around this are not + just $$. +

6 quotation marks

When a single quotation mark in a string inside the function body is + adjacent to the end of that string constant, for example: +

a_output := a_output || '' AND name LIKE ''''foobar''''''

+ The value appended to a_output would then be: + AND name LIKE 'foobar'. +

In the dollar-quoting approach, this becomes: +

a_output := a_output || $$ AND name LIKE 'foobar'$$

+

10 quotation marks

When you want two single quotation marks in a string constant (which + accounts for 8 quotation marks) and this is adjacent to the end of that + string constant (2 more). You will probably only need that if + you are writing a function that generates other functions, as in + Example 39-8. + For example: +

a_output := a_output || '' if v_'' ||
+    referrer_keys.kind || '' like ''''''''''
+    || referrer_keys.key_string || ''''''''''
+    then return ''''''  || referrer_keys.referrer_type
+    || ''''''; end if;'';

+ The value of a_output would then be: +

if v_... like ''...'' then return ''...''; end if;

+

In the dollar-quoting approach, this becomes: +

a_output := a_output || $$ if v_$$ || referrer_keys.kind || $$ like '$$
+    || referrer_keys.key_string || $$'
+    then return '$$  || referrer_keys.referrer_type
+    || $$'; end if;$$;

+ where we assume we only need to put single quote marks into + a_output, because it will be re-quoted before use. +


PrevHomeNext
PL/pgSQL Under the HoodUpPorting from Oracle PL/SQL
\ No newline at end of file diff --git a/doc/src/sgml/html/plpgsql-errors-and-messages.html b/doc/src/sgml/html/plpgsql-errors-and-messages.html new file mode 100644 index 000000000..a913c6a38 --- /dev/null +++ b/doc/src/sgml/html/plpgsql-errors-and-messages.html @@ -0,0 +1,615 @@ + +Errors and Messages
PostgreSQL 9.2.2 Documentation
PrevUpChapter 39. PL/pgSQL - SQL Procedural LanguageNext

39.8. Errors and Messages

Use the RAISE statement to report messages and + raise errors. + +

RAISE [ level ] 'format' [, expression [, ... ]] [ USING option = expression [, ... ] ];
+RAISE [ level ] condition_name [ USING option = expression [, ... ] ];
+RAISE [ level ] SQLSTATE 'sqlstate' [ USING option = expression [, ... ] ];
+RAISE [ level ] USING option = expression [, ... ];
+RAISE ;

+ + The level option specifies + the error severity. Allowed levels are DEBUG, + LOG, INFO, + NOTICE, WARNING, + and EXCEPTION, with EXCEPTION + being the default. + EXCEPTION raises an error (which normally aborts the + current transaction); the other levels only generate messages of different + priority levels. + Whether messages of a particular priority are reported to the client, + written to the server log, or both is controlled by the + log_min_messages and + client_min_messages configuration + variables. See Chapter 18 for more + information. +

After level if any, + you can write a format + (which must be a simple string literal, not an expression). The + format string specifies the error message text to be reported. + The format string can be followed + by optional argument expressions to be inserted into the message. + Inside the format string, % is replaced by the + string representation of the next optional argument's value. Write + %% to emit a literal %. +

In this example, the value of v_job_id will replace the + % in the string: +

RAISE NOTICE 'Calling cs_create_job(%)', v_job_id;

+

You can attach additional information to the error report by writing + USING followed by option = expression items. The allowed + option keywords are + MESSAGE, DETAIL, HINT, and + ERRCODE, while each expression can be any string-valued + expression. + MESSAGE sets the error message text (this option can't + be used in the form of RAISE that includes a format + string before USING). + DETAIL supplies an error detail message, while + HINT supplies a hint message. + ERRCODE specifies the error code (SQLSTATE) to report, + either by condition name as shown in Appendix A, + or directly as a five-character SQLSTATE code. +

This example will abort the transaction with the given error message + and hint: +

RAISE EXCEPTION 'Nonexistent ID --> %', user_id
+      USING HINT = 'Please check your user ID';

+

These two examples show equivalent ways of setting the SQLSTATE: +

RAISE 'Duplicate user ID: %', user_id USING ERRCODE = 'unique_violation';
+RAISE 'Duplicate user ID: %', user_id USING ERRCODE = '23505';

+

There is a second RAISE syntax in which the main argument + is the condition name or SQLSTATE to be reported, for example: +

RAISE division_by_zero;
+RAISE SQLSTATE '22012';

+ In this syntax, USING can be used to supply a custom + error message, detail, or hint. Another way to do the earlier + example is +

RAISE unique_violation USING MESSAGE = 'Duplicate user ID: ' || user_id;

+

Still another variant is to write RAISE USING or RAISE + level USING and put + everything else into the USING list. +

The last variant of RAISE has no parameters at all. + This form can only be used inside a BEGIN block's + EXCEPTION clause; + it causes the error currently being handled to be re-thrown. +

Note: Before PostgreSQL 9.1, RAISE without + parameters was interpreted as re-throwing the error from the block + containing the active exception handler. Thus an EXCEPTION + clause nested within that handler could not catch it, even if the + RAISE was within the nested EXCEPTION clause's + block. This was deemed surprising as well as being incompatible with + Oracle's PL/SQL. +

If no condition name nor SQLSTATE is specified in a + RAISE EXCEPTION command, the default is to use + RAISE_EXCEPTION (P0001). If no message + text is specified, the default is to use the condition name or + SQLSTATE as message text. +

Note: When specifying an error code by SQLSTATE code, you are not + limited to the predefined error codes, but can select any + error code consisting of five digits and/or upper-case ASCII + letters, other than 00000. It is recommended that + you avoid throwing error codes that end in three zeroes, because + these are category codes and can only be trapped by trapping + the whole category. +


PrevHomeNext
CursorsUpTrigger Procedures
\ No newline at end of file diff --git a/doc/src/sgml/html/plpgsql-expressions.html b/doc/src/sgml/html/plpgsql-expressions.html new file mode 100644 index 000000000..5eecaac07 --- /dev/null +++ b/doc/src/sgml/html/plpgsql-expressions.html @@ -0,0 +1,274 @@ + +Expressions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 39. PL/pgSQL - SQL Procedural LanguageNext

39.4. Expressions

All expressions used in PL/pgSQL + statements are processed using the server's main + SQL executor. For example, when you write + a PL/pgSQL statement like +

IF expression THEN ...

+ PL/pgSQL will evaluate the expression by + feeding a query like +

SELECT expression

+ to the main SQL engine. While forming the SELECT command, + any occurrences of PL/pgSQL variable names + are replaced by parameters, as discussed in detail in + Section 39.10.1. + This allows the query plan for the SELECT to + be prepared just once and then reused for subsequent + evaluations with different values of the variables. Thus, what + really happens on first use of an expression is essentially a + PREPARE command. For example, if we have declared + two integer variables x and y, and we write +

IF x < y THEN ...

+ what happens behind the scenes is equivalent to +

PREPARE statement_name(integer, integer) AS SELECT $1 < $2;

+ and then this prepared statement is EXECUTEd for each + execution of the IF statement, with the current values + of the PL/pgSQL variables supplied as + parameter values. Normally these details are + not important to a PL/pgSQL user, but + they are useful to know when trying to diagnose a problem. + More information appears in Section 39.10.2. +


PrevHomeNext
DeclarationsUpBasic Statements
\ No newline at end of file diff --git a/doc/src/sgml/html/plpgsql-implementation.html b/doc/src/sgml/html/plpgsql-implementation.html new file mode 100644 index 000000000..b2dabc74a --- /dev/null +++ b/doc/src/sgml/html/plpgsql-implementation.html @@ -0,0 +1,795 @@ + +PL/pgSQL Under the Hood
PostgreSQL 9.2.2 Documentation
PrevUpChapter 39. PL/pgSQL - SQL Procedural LanguageNext

39.10. PL/pgSQL Under the Hood

This section discusses some implementation details that are + frequently important for PL/pgSQL users to know. +

39.10.1. Variable Substitution

SQL statements and expressions within a PL/pgSQL function + can refer to variables and parameters of the function. Behind the scenes, + PL/pgSQL substitutes query parameters for such references. + Parameters will only be substituted in places where a parameter or + column reference is syntactically allowed. As an extreme case, consider + this example of poor programming style: +

INSERT INTO foo (foo) VALUES (foo);

+ The first occurrence of foo must syntactically be a table + name, so it will not be substituted, even if the function has a variable + named foo. The second occurrence must be the name of a + column of the table, so it will not be substituted either. Only the + third occurrence is a candidate to be a reference to the function's + variable. +

Note: PostgreSQL versions before 9.0 would try + to substitute the variable in all three cases, leading to syntax errors. +

Since the names of variables are syntactically no different from the names + of table columns, there can be ambiguity in statements that also refer to + tables: is a given name meant to refer to a table column, or a variable? + Let's change the previous example to +

INSERT INTO dest (col) SELECT foo + bar FROM src;

+ Here, dest and src must be table names, and + col must be a column of dest, but foo + and bar might reasonably be either variables of the function + or columns of src. +

By default, PL/pgSQL will report an error if a name + in a SQL statement could refer to either a variable or a table column. + You can fix such a problem by renaming the variable or column, + or by qualifying the ambiguous reference, or by telling + PL/pgSQL which interpretation to prefer. +

The simplest solution is to rename the variable or column. + A common coding rule is to use a + different naming convention for PL/pgSQL + variables than you use for column names. For example, + if you consistently name function variables + v_something while none of your + column names start with v_, no conflicts will occur. +

Alternatively you can qualify ambiguous references to make them clear. + In the above example, src.foo would be an unambiguous reference + to the table column. To create an unambiguous reference to a variable, + declare it in a labeled block and use the block's label + (see Section 39.2). For example, +

<<block>>
+DECLARE
+    foo int;
+BEGIN
+    foo := ...;
+    INSERT INTO dest (col) SELECT block.foo + bar FROM src;

+ Here block.foo means the variable even if there is a column + foo in src. Function parameters, as well as + special variables such as FOUND, can be qualified by the + function's name, because they are implicitly declared in an outer block + labeled with the function's name. +

Sometimes it is impractical to fix all the ambiguous references in a + large body of PL/pgSQL code. In such cases you can + specify that PL/pgSQL should resolve ambiguous references + as the variable (which is compatible with PL/pgSQL's + behavior before PostgreSQL 9.0), or as the + table column (which is compatible with some other systems such as + Oracle). +

To change this behavior on a system-wide basis, set the configuration + parameter plpgsql.variable_conflict to one of + error, use_variable, or + use_column (where error is the factory default). + This parameter affects subsequent compilations + of statements in PL/pgSQL functions, but not statements + already compiled in the current session. + Because changing this setting + can cause unexpected changes in the behavior of PL/pgSQL + functions, it can only be changed by a superuser. +

You can also set the behavior on a function-by-function basis, by + inserting one of these special commands at the start of the function + text: +

#variable_conflict error
+#variable_conflict use_variable
+#variable_conflict use_column

+ These commands affect only the function they are written in, and override + the setting of plpgsql.variable_conflict. An example is +

CREATE FUNCTION stamp_user(id int, comment text) RETURNS void AS $$
+    #variable_conflict use_variable
+    DECLARE
+        curtime timestamp := now();
+    BEGIN
+        UPDATE users SET last_modified = curtime, comment = comment
+          WHERE users.id = id;
+    END;
+$$ LANGUAGE plpgsql;

+ In the UPDATE command, curtime, comment, + and id will refer to the function's variable and parameters + whether or not users has columns of those names. Notice + that we had to qualify the reference to users.id in the + WHERE clause to make it refer to the table column. + But we did not have to qualify the reference to comment + as a target in the UPDATE list, because syntactically + that must be a column of users. We could write the same + function without depending on the variable_conflict setting + in this way: +

CREATE FUNCTION stamp_user(id int, comment text) RETURNS void AS $$
+    <<fn>>
+    DECLARE
+        curtime timestamp := now();
+    BEGIN
+        UPDATE users SET last_modified = fn.curtime, comment = stamp_user.comment
+          WHERE users.id = stamp_user.id;
+    END;
+$$ LANGUAGE plpgsql;

+

Variable substitution does not happen in the command string given + to EXECUTE or one of its variants. If you need to + insert a varying value into such a command, do so as part of + constructing the string value, or use USING, as illustrated in + Section 39.5.4. +

Variable substitution currently works only in SELECT, + INSERT, UPDATE, and DELETE commands, + because the main SQL engine allows query parameters only in these + commands. To use a non-constant name or value in other statement + types (generically called utility statements), you must construct + the utility statement as a string and EXECUTE it. +

39.10.2. Plan Caching

The PL/pgSQL interpreter parses the function's source + text and produces an internal binary instruction tree the first time the + function is called (within each session). The instruction tree + fully translates the + PL/pgSQL statement structure, but individual + SQL expressions and SQL commands + used in the function are not translated immediately. +

+ As each expression and SQL command is first + executed in the function, the PL/pgSQL interpreter + parses and analyzes the command to create a prepared statement, + using the SPI manager's + SPI_prepare function. + Subsequent visits to that expression or command + reuse the prepared statement. Thus, a function with conditional code + paths that are seldom visited will never incur the overhead of + analyzing those commands that are never executed within the current + session. A disadvantage is that errors + in a specific expression or command cannot be detected until that + part of the function is reached in execution. (Trivial syntax + errors will be detected during the initial parsing pass, but + anything deeper will not be detected until execution.) +

PL/pgSQL (or more precisely, the SPI manager) can + furthermore attempt to cache the execution plan associated with any + particular prepared statement. If a cached plan is not used, then + a fresh execution plan is generated on each visit to the statement, + and the current parameter values (that is, PL/pgSQL + variable values) can be used to optimize the selected plan. If the + statement has no parameters, or is executed many times, the SPI manager + will consider creating a generic plan that is not dependent + on specific parameter values, and caching that for re-use. Typically + this will happen only if the execution plan is not very sensitive to + the values of the PL/pgSQL variables referenced in it. + If it is, generating a plan each time is a net win. +

Because PL/pgSQL saves prepared statements + and sometimes execution plans in this way, + SQL commands that appear directly in a + PL/pgSQL function must refer to the + same tables and columns on every execution; that is, you cannot use + a parameter as the name of a table or column in an SQL command. To get + around this restriction, you can construct dynamic commands using + the PL/pgSQL EXECUTE + statement — at the price of performing new parse analysis and + constructing a new execution plan on every execution. +

The mutable nature of record variables presents another problem in this + connection. When fields of a record variable are used in + expressions or statements, the data types of the fields must not + change from one call of the function to the next, since each + expression will be analyzed using the data type that is present + when the expression is first reached. EXECUTE can be + used to get around this problem when necessary. +

If the same function is used as a trigger for more than one table, + PL/pgSQL prepares and caches statements + independently for each such table — that is, there is a cache + for each trigger function and table combination, not just for each + function. This alleviates some of the problems with varying + data types; for instance, a trigger function will be able to work + successfully with a column named key even if it happens + to have different types in different tables. +

Likewise, functions having polymorphic argument types have a separate + statement cache for each combination of actual argument types they have + been invoked for, so that data type differences do not cause unexpected + failures. +

Statement caching can sometimes have surprising effects on the + interpretation of time-sensitive values. For example there + is a difference between what these two functions do: + +

CREATE FUNCTION logfunc1(logtxt text) RETURNS void AS $$
+    BEGIN
+        INSERT INTO logtable VALUES (logtxt, 'now');
+    END;
+$$ LANGUAGE plpgsql;

+ + and: + +

CREATE FUNCTION logfunc2(logtxt text) RETURNS void AS $$
+    DECLARE
+        curtime timestamp;
+    BEGIN
+        curtime := 'now';
+        INSERT INTO logtable VALUES (logtxt, curtime);
+    END;
+$$ LANGUAGE plpgsql;

+

In the case of logfunc1, the + PostgreSQL main parser knows when + analyzing the INSERT that the + string 'now' should be interpreted as + timestamp, because the target column of + logtable is of that type. Thus, + 'now' will be converted to a timestamp + constant when the + INSERT is analyzed, and then used in all + invocations of logfunc1 during the lifetime + of the session. Needless to say, this isn't what the programmer + wanted. A better idea is to use the now() or + current_timestamp function. +

In the case of logfunc2, the + PostgreSQL main parser does not know + what type 'now' should become and therefore + it returns a data value of type text containing the string + now. During the ensuing assignment + to the local variable curtime, the + PL/pgSQL interpreter casts this + string to the timestamp type by calling the + text_out and timestamp_in + functions for the conversion. So, the computed time stamp is updated + on each execution as the programmer expects. Even though this + happens to work as expected, it's not terribly efficient, so + use of the now() function would still be a better idea. +


PrevHomeNext
Trigger ProceduresUpTips for Developing in PL/pgSQL
\ No newline at end of file diff --git a/doc/src/sgml/html/plpgsql-overview.html b/doc/src/sgml/html/plpgsql-overview.html new file mode 100644 index 000000000..b43f3ef4d --- /dev/null +++ b/doc/src/sgml/html/plpgsql-overview.html @@ -0,0 +1,473 @@ + +Overview
PostgreSQL 9.2.2 Documentation
PrevUpChapter 39. PL/pgSQL - SQL Procedural LanguageNext

39.1. Overview

PL/pgSQL is a loadable procedural + language for the PostgreSQL database + system. The design goals of PL/pgSQL were to create + a loadable procedural language that + +

  • can be used to create functions and trigger procedures, +

  • adds control structures to the SQL language, +

  • can perform complex computations, +

  • inherits all user-defined types, functions, and operators, +

  • can be defined to be trusted by the server, +

  • is easy to use. +

+

Functions created with PL/pgSQL can be + used anywhere that built-in functions could be used. + For example, it is possible to + create complex conditional computation functions and later use + them to define operators or use them in index expressions. +

In PostgreSQL 9.0 and later, + PL/pgSQL is installed by default. + However it is still a loadable module, so especially security-conscious + administrators could choose to remove it. +

39.1.1. Advantages of Using PL/pgSQL

SQL is the language PostgreSQL + and most other relational databases use as query language. It's + portable and easy to learn. But every SQL + statement must be executed individually by the database server. +

That means that your client application must send each query to + the database server, wait for it to be processed, receive and + process the results, do some computation, then send further + queries to the server. All this incurs interprocess + communication and will also incur network overhead if your client + is on a different machine than the database server. +

With PL/pgSQL you can group a block of + computation and a series of queries inside + the database server, thus having the power of a procedural + language and the ease of use of SQL, but with considerable + savings of client/server communication overhead. +

  • Extra round trips between + client and server are eliminated

  • Intermediate results that the client does not + need do not have to be marshaled or transferred between server + and client

  • Multiple rounds of query + parsing can be avoided

This can result in a considerable performance increase as + compared to an application that does not use stored functions. +

Also, with PL/pgSQL you can use all + the data types, operators and functions of SQL. +

39.1.2. Supported Argument and Result Data Types

Functions written in PL/pgSQL can accept + as arguments any scalar or array data type supported by the server, + and they can return a result of any of these types. They can also + accept or return any composite type (row type) specified by name. + It is also possible to declare a PL/pgSQL + function as returning record, which means that the result + is a row type whose columns are determined by specification in the + calling query, as discussed in Section 7.2.1.4. +

PL/pgSQL functions can be declared to accept a variable + number of arguments by using the VARIADIC marker. This + works exactly the same way as for SQL functions, as discussed in + Section 35.4.5. +

PL/pgSQL functions can also be declared to accept + and return the polymorphic types + anyelement, anyarray, anynonarray, + anyenum, and anyrange. The actual + data types handled by a polymorphic function can vary from call to + call, as discussed in Section 35.2.5. + An example is shown in Section 39.3.1. +

PL/pgSQL functions can also be declared to return + a "set" (or table) of any data type that can be returned as + a single instance. Such a function generates its output by executing + RETURN NEXT for each desired element of the result + set, or by using RETURN QUERY to output the result of + evaluating a query. +

Finally, a PL/pgSQL function can be declared to return + void if it has no useful return value. +

PL/pgSQL functions can also be declared with output + parameters in place of an explicit specification of the return type. + This does not add any fundamental capability to the language, but + it is often convenient, especially for returning multiple values. + The RETURNS TABLE notation can also be used in place + of RETURNS SETOF. +

Specific examples appear in + Section 39.3.1 and + Section 39.6.1. +


PrevHomeNext
PL/pgSQL - SQL Procedural LanguageUpStructure of PL/pgSQL
\ No newline at end of file diff --git a/doc/src/sgml/html/plpgsql-porting.html b/doc/src/sgml/html/plpgsql-porting.html new file mode 100644 index 000000000..6cbc46f7c --- /dev/null +++ b/doc/src/sgml/html/plpgsql-porting.html @@ -0,0 +1,1342 @@ + +Porting from Oracle PL/SQL
PostgreSQL 9.2.2 Documentation
PrevUpChapter 39. PL/pgSQL - SQL Procedural LanguageNext

39.12. Porting from Oracle PL/SQL

This section explains differences between + PostgreSQL's PL/pgSQL + language and Oracle's PL/SQL language, + to help developers who port applications from + Oracle® to PostgreSQL. +

PL/pgSQL is similar to PL/SQL in many + aspects. It is a block-structured, imperative language, and all + variables have to be declared. Assignments, loops, conditionals + are similar. The main differences you should keep in mind when + porting from PL/SQL to + PL/pgSQL are: + +

  • If a name used in a SQL command could be either a column name of a + table or a reference to a variable of the function, + PL/SQL treats it as a column name. This corresponds + to PL/pgSQL's + plpgsql.variable_conflict = use_column + behavior, which is not the default, + as explained in Section 39.10.1. + It's often best to avoid such ambiguities in the first place, + but if you have to port a large amount of code that depends on + this behavior, setting variable_conflict may be the + best solution. +

  • In PostgreSQL the function body must be written as + a string literal. Therefore you need to use dollar quoting or escape + single quotes in the function body. (See Section 39.11.1.) +

  • Instead of packages, use schemas to organize your functions + into groups. +

  • Since there are no packages, there are no package-level variables + either. This is somewhat annoying. You can keep per-session state + in temporary tables instead. +

  • Integer FOR loops with REVERSE work + differently: PL/SQL counts down from the second + number to the first, while PL/pgSQL counts down + from the first number to the second, requiring the loop bounds + to be swapped when porting. This incompatibility is unfortunate + but is unlikely to be changed. (See Section 39.6.3.5.) +

  • FOR loops over queries (other than cursors) also work + differently: the target variable(s) must have been declared, + whereas PL/SQL always declares them implicitly. + An advantage of this is that the variable values are still accessible + after the loop exits. +

  • There are various notational differences for the use of cursor + variables. +

+

39.12.1. Porting Examples

Example 39-7 shows how to port a simple + function from PL/SQL to PL/pgSQL. +

Example 39-7. Porting a Simple Function from PL/SQL to PL/pgSQL

Here is an Oracle PL/SQL function: +

CREATE OR REPLACE FUNCTION cs_fmt_browser_version(v_name varchar,
+                                                  v_version varchar)
+RETURN varchar IS
+BEGIN
+    IF v_version IS NULL THEN
+        RETURN v_name;
+    END IF;
+    RETURN v_name || '/' || v_version;
+END;
+/
+show errors;

+

Let's go through this function and see the differences compared to + PL/pgSQL: + +

  • The RETURN key word in the function + prototype (not the function body) becomes + RETURNS in + PostgreSQL. + Also, IS becomes AS, and you need to + add a LANGUAGE clause because PL/pgSQL + is not the only possible function language. +

  • In PostgreSQL, the function body is considered + to be a string literal, so you need to use quote marks or dollar + quotes around it. This substitutes for the terminating / + in the Oracle approach. +

  • The show errors command does not exist in + PostgreSQL, and is not needed since errors are + reported automatically. +

+

This is how this function would look when ported to + PostgreSQL: + +

CREATE OR REPLACE FUNCTION cs_fmt_browser_version(v_name varchar,
+                                                  v_version varchar)
+RETURNS varchar AS $$
+BEGIN
+    IF v_version IS NULL THEN
+        RETURN v_name;
+    END IF;
+    RETURN v_name || '/' || v_version;
+END;
+$$ LANGUAGE plpgsql;

+

Example 39-8 shows how to port a + function that creates another function and how to handle the + ensuing quoting problems. +

Example 39-8. Porting a Function that Creates Another Function from PL/SQL to PL/pgSQL

The following procedure grabs rows from a + SELECT statement and builds a large function + with the results in IF statements, for the + sake of efficiency. +

This is the Oracle version: +

CREATE OR REPLACE PROCEDURE cs_update_referrer_type_proc IS
+    CURSOR referrer_keys IS
+        SELECT * FROM cs_referrer_keys
+        ORDER BY try_order;
+    func_cmd VARCHAR(4000);
+BEGIN
+    func_cmd := 'CREATE OR REPLACE FUNCTION cs_find_referrer_type(v_host IN VARCHAR,
+                 v_domain IN VARCHAR, v_url IN VARCHAR) RETURN VARCHAR IS BEGIN';
+
+    FOR referrer_key IN referrer_keys LOOP
+        func_cmd := func_cmd ||
+          ' IF v_' || referrer_key.kind
+          || ' LIKE ''' || referrer_key.key_string
+          || ''' THEN RETURN ''' || referrer_key.referrer_type
+          || '''; END IF;';
+    END LOOP;
+
+    func_cmd := func_cmd || ' RETURN NULL; END;';
+
+    EXECUTE IMMEDIATE func_cmd;
+END;
+/
+show errors;

+

Here is how this function would end up in PostgreSQL: +

CREATE OR REPLACE FUNCTION cs_update_referrer_type_proc() RETURNS void AS $func$
+DECLARE
+    referrer_keys CURSOR IS
+        SELECT * FROM cs_referrer_keys
+        ORDER BY try_order;
+    func_body text;
+    func_cmd text;
+BEGIN
+    func_body := 'BEGIN';
+
+    FOR referrer_key IN referrer_keys LOOP
+        func_body := func_body ||
+          ' IF v_' || referrer_key.kind
+          || ' LIKE ' || quote_literal(referrer_key.key_string)
+          || ' THEN RETURN ' || quote_literal(referrer_key.referrer_type)
+          || '; END IF;' ;
+    END LOOP;
+
+    func_body := func_body || ' RETURN NULL; END;';
+
+    func_cmd :=
+      'CREATE OR REPLACE FUNCTION cs_find_referrer_type(v_host varchar,
+                                                        v_domain varchar,
+                                                        v_url varchar)
+        RETURNS varchar AS '
+      || quote_literal(func_body)
+      || ' LANGUAGE plpgsql;' ;
+
+    EXECUTE func_cmd;
+END;
+$func$ LANGUAGE plpgsql;

+ Notice how the body of the function is built separately and passed + through quote_literal to double any quote marks in it. This + technique is needed because we cannot safely use dollar quoting for + defining the new function: we do not know for sure what strings will + be interpolated from the referrer_key.key_string field. + (We are assuming here that referrer_key.kind can be + trusted to always be host, domain, or + url, but referrer_key.key_string might be + anything, in particular it might contain dollar signs.) This function + is actually an improvement on the Oracle original, because it will + not generate broken code when referrer_key.key_string or + referrer_key.referrer_type contain quote marks. +

Example 39-9 shows how to port a function + with OUT parameters and string manipulation. + PostgreSQL does not have a built-in + instr function, but you can create one + using a combination of other + functions. In Section 39.12.3 there is a + PL/pgSQL implementation of + instr that you can use to make your porting + easier. +

Example 39-9. Porting a Procedure With String Manipulation and + OUT Parameters from PL/SQL to + PL/pgSQL

The following Oracle PL/SQL procedure is used + to parse a URL and return several elements (host, path, and query). +

This is the Oracle version: +

CREATE OR REPLACE PROCEDURE cs_parse_url(
+    v_url IN VARCHAR,
+    v_host OUT VARCHAR,  -- This will be passed back
+    v_path OUT VARCHAR,  -- This one too
+    v_query OUT VARCHAR) -- And this one
+IS
+    a_pos1 INTEGER;
+    a_pos2 INTEGER;
+BEGIN
+    v_host := NULL;
+    v_path := NULL;
+    v_query := NULL;
+    a_pos1 := instr(v_url, '//');
+
+    IF a_pos1 = 0 THEN
+        RETURN;
+    END IF;
+    a_pos2 := instr(v_url, '/', a_pos1 + 2);
+    IF a_pos2 = 0 THEN
+        v_host := substr(v_url, a_pos1 + 2);
+        v_path := '/';
+        RETURN;
+    END IF;
+
+    v_host := substr(v_url, a_pos1 + 2, a_pos2 - a_pos1 - 2);
+    a_pos1 := instr(v_url, '?', a_pos2 + 1);
+
+    IF a_pos1 = 0 THEN
+        v_path := substr(v_url, a_pos2);
+        RETURN;
+    END IF;
+
+    v_path := substr(v_url, a_pos2, a_pos1 - a_pos2);
+    v_query := substr(v_url, a_pos1 + 1);
+END;
+/
+show errors;

+

Here is a possible translation into PL/pgSQL: +

CREATE OR REPLACE FUNCTION cs_parse_url(
+    v_url IN VARCHAR,
+    v_host OUT VARCHAR,  -- This will be passed back
+    v_path OUT VARCHAR,  -- This one too
+    v_query OUT VARCHAR) -- And this one
+AS $$
+DECLARE
+    a_pos1 INTEGER;
+    a_pos2 INTEGER;
+BEGIN
+    v_host := NULL;
+    v_path := NULL;
+    v_query := NULL;
+    a_pos1 := instr(v_url, '//');
+
+    IF a_pos1 = 0 THEN
+        RETURN;
+    END IF;
+    a_pos2 := instr(v_url, '/', a_pos1 + 2);
+    IF a_pos2 = 0 THEN
+        v_host := substr(v_url, a_pos1 + 2);
+        v_path := '/';
+        RETURN;
+    END IF;
+
+    v_host := substr(v_url, a_pos1 + 2, a_pos2 - a_pos1 - 2);
+    a_pos1 := instr(v_url, '?', a_pos2 + 1);
+
+    IF a_pos1 = 0 THEN
+        v_path := substr(v_url, a_pos2);
+        RETURN;
+    END IF;
+
+    v_path := substr(v_url, a_pos2, a_pos1 - a_pos2);
+    v_query := substr(v_url, a_pos1 + 1);
+END;
+$$ LANGUAGE plpgsql;

+ + This function could be used like this: +

SELECT * FROM cs_parse_url('http://foobar.com/query.cgi?baz');

+

Example 39-10 shows how to port a procedure + that uses numerous features that are specific to Oracle. +

Example 39-10. Porting a Procedure from PL/SQL to PL/pgSQL

The Oracle version: + +

CREATE OR REPLACE PROCEDURE cs_create_job(v_job_id IN INTEGER) IS
+    a_running_job_count INTEGER;
+    PRAGMA AUTONOMOUS_TRANSACTION;(1)
+BEGIN
+    LOCK TABLE cs_jobs IN EXCLUSIVE MODE;(2)
+
+    SELECT count(*) INTO a_running_job_count FROM cs_jobs WHERE end_stamp IS NULL;
+
+    IF a_running_job_count > 0 THEN
+        COMMIT; -- free lock(3)
+        raise_application_error(-20000,
+                 'Unable to create a new job: a job is currently running.');
+    END IF;
+
+    DELETE FROM cs_active_job;
+    INSERT INTO cs_active_job(job_id) VALUES (v_job_id);
+
+    BEGIN
+        INSERT INTO cs_jobs (job_id, start_stamp) VALUES (v_job_id, sysdate);
+    EXCEPTION
+        WHEN dup_val_on_index THEN NULL; -- don't worry if it already exists
+    END;
+    COMMIT;
+END;
+/
+show errors

+

Procedures like this can easily be converted into PostgreSQL + functions returning void. This procedure in + particular is interesting because it can teach us some things: + +

(1)
There is no PRAGMA statement in PostgreSQL. +
(2)
If you do a LOCK TABLE in PL/pgSQL, + the lock will not be released until the calling transaction is + finished. +
(3)
You cannot issue COMMIT in a + PL/pgSQL function. The function is + running within some outer transaction and so COMMIT + would imply terminating the function's execution. However, in + this particular case it is not necessary anyway, because the lock + obtained by the LOCK TABLE will be released when + we raise an error. +
+

This is how we could port this procedure to PL/pgSQL: + +

CREATE OR REPLACE FUNCTION cs_create_job(v_job_id integer) RETURNS void AS $$
+DECLARE
+    a_running_job_count integer;
+BEGIN
+    LOCK TABLE cs_jobs IN EXCLUSIVE MODE;
+
+    SELECT count(*) INTO a_running_job_count FROM cs_jobs WHERE end_stamp IS NULL;
+
+    IF a_running_job_count > 0 THEN
+        RAISE EXCEPTION 'Unable to create a new job: a job is currently running';(1)
+    END IF;
+
+    DELETE FROM cs_active_job;
+    INSERT INTO cs_active_job(job_id) VALUES (v_job_id);
+
+    BEGIN
+        INSERT INTO cs_jobs (job_id, start_stamp) VALUES (v_job_id, now());
+    EXCEPTION
+        WHEN unique_violation THEN (2)
+            -- don't worry if it already exists
+    END;
+END;
+$$ LANGUAGE plpgsql;

+ +

(1)
The syntax of RAISE is considerably different from + Oracle's statement, although the basic case RAISE + exception_name works + similarly. +
(2)
The exception names supported by PL/pgSQL are + different from Oracle's. The set of built-in exception names + is much larger (see Appendix A). There + is not currently a way to declare user-defined exception names, + although you can throw user-chosen SQLSTATE values instead. +
+ + The main functional difference between this procedure and the + Oracle equivalent is that the exclusive lock on the cs_jobs + table will be held until the calling transaction completes. Also, if + the caller later aborts (for example due to an error), the effects of + this procedure will be rolled back. +

39.12.2. Other Things to Watch For

This section explains a few other things to watch for when porting + Oracle PL/SQL functions to + PostgreSQL. +

39.12.2.1. Implicit Rollback after Exceptions

In PL/pgSQL, when an exception is caught by an + EXCEPTION clause, all database changes since the block's + BEGIN are automatically rolled back. That is, the behavior + is equivalent to what you'd get in Oracle with: + +

BEGIN
+    SAVEPOINT s1;
+    ... code here ...
+EXCEPTION
+    WHEN ... THEN
+        ROLLBACK TO s1;
+        ... code here ...
+    WHEN ... THEN
+        ROLLBACK TO s1;
+        ... code here ...
+END;

+ + If you are translating an Oracle procedure that uses + SAVEPOINT and ROLLBACK TO in this style, + your task is easy: just omit the SAVEPOINT and + ROLLBACK TO. If you have a procedure that uses + SAVEPOINT and ROLLBACK TO in a different way + then some actual thought will be required. +

39.12.2.2. EXECUTE

The PL/pgSQL version of + EXECUTE works similarly to the + PL/SQL version, but you have to remember to use + quote_literal and + quote_ident as described in Section 39.5.4. Constructs of the + type EXECUTE 'SELECT * FROM $1'; will not work + reliably unless you use these functions. +

39.12.2.3. Optimizing PL/pgSQL Functions

PostgreSQL gives you two function creation + modifiers to optimize execution: "volatility" (whether + the function always returns the same result when given the same + arguments) and "strictness" (whether the function + returns null if any argument is null). Consult the CREATE FUNCTION + reference page for details. +

When making use of these optimization attributes, your + CREATE FUNCTION statement might look something + like this: + +

CREATE FUNCTION foo(...) RETURNS integer AS $$
+...
+$$ LANGUAGE plpgsql STRICT IMMUTABLE;

+

39.12.3. Appendix

This section contains the code for a set of Oracle-compatible + instr functions that you can use to simplify + your porting efforts. +

--
+-- instr functions that mimic Oracle's counterpart
+-- Syntax: instr(string1, string2, [n], [m]) where [] denotes optional parameters.
+--
+-- Searches string1 beginning at the nth character for the mth occurrence
+-- of string2.  If n is negative, search backwards.  If m is not passed,
+-- assume 1 (search starts at first character).
+--
+
+CREATE FUNCTION instr(varchar, varchar) RETURNS integer AS $$
+DECLARE
+    pos integer;
+BEGIN
+    pos:= instr($1, $2, 1);
+    RETURN pos;
+END;
+$$ LANGUAGE plpgsql STRICT IMMUTABLE;
+
+
+CREATE FUNCTION instr(string varchar, string_to_search varchar, beg_index integer)
+RETURNS integer AS $$
+DECLARE
+    pos integer NOT NULL DEFAULT 0;
+    temp_str varchar;
+    beg integer;
+    length integer;
+    ss_length integer;
+BEGIN
+    IF beg_index > 0 THEN
+        temp_str := substring(string FROM beg_index);
+        pos := position(string_to_search IN temp_str);
+
+        IF pos = 0 THEN
+            RETURN 0;
+        ELSE
+            RETURN pos + beg_index - 1;
+        END IF;
+    ELSE
+        ss_length := char_length(string_to_search);
+        length := char_length(string);
+        beg := length + beg_index - ss_length + 2;
+
+        WHILE beg > 0 LOOP
+            temp_str := substring(string FROM beg FOR ss_length);
+            pos := position(string_to_search IN temp_str);
+
+            IF pos > 0 THEN
+                RETURN beg;
+            END IF;
+
+            beg := beg - 1;
+        END LOOP;
+
+        RETURN 0;
+    END IF;
+END;
+$$ LANGUAGE plpgsql STRICT IMMUTABLE;
+
+
+CREATE FUNCTION instr(string varchar, string_to_search varchar,
+                      beg_index integer, occur_index integer)
+RETURNS integer AS $$
+DECLARE
+    pos integer NOT NULL DEFAULT 0;
+    occur_number integer NOT NULL DEFAULT 0;
+    temp_str varchar;
+    beg integer;
+    i integer;
+    length integer;
+    ss_length integer;
+BEGIN
+    IF beg_index > 0 THEN
+        beg := beg_index;
+        temp_str := substring(string FROM beg_index);
+
+        FOR i IN 1..occur_index LOOP
+            pos := position(string_to_search IN temp_str);
+
+            IF i = 1 THEN
+                beg := beg + pos - 1;
+            ELSE
+                beg := beg + pos;
+            END IF;
+
+            temp_str := substring(string FROM beg + 1);
+        END LOOP;
+
+        IF pos = 0 THEN
+            RETURN 0;
+        ELSE
+            RETURN beg;
+        END IF;
+    ELSE
+        ss_length := char_length(string_to_search);
+        length := char_length(string);
+        beg := length + beg_index - ss_length + 2;
+
+        WHILE beg > 0 LOOP
+            temp_str := substring(string FROM beg FOR ss_length);
+            pos := position(string_to_search IN temp_str);
+
+            IF pos > 0 THEN
+                occur_number := occur_number + 1;
+
+                IF occur_number = occur_index THEN
+                    RETURN beg;
+                END IF;
+            END IF;
+
+            beg := beg - 1;
+        END LOOP;
+
+        RETURN 0;
+    END IF;
+END;
+$$ LANGUAGE plpgsql STRICT IMMUTABLE;

PrevHomeNext
Tips for Developing in PL/pgSQLUpPL/Tcl - Tcl Procedural Language
\ No newline at end of file diff --git a/doc/src/sgml/html/plpgsql-statements.html b/doc/src/sgml/html/plpgsql-statements.html new file mode 100644 index 000000000..26287556e --- /dev/null +++ b/doc/src/sgml/html/plpgsql-statements.html @@ -0,0 +1,1592 @@ + +Basic Statements
PostgreSQL 9.2.2 Documentation
PrevUpChapter 39. PL/pgSQL - SQL Procedural LanguageNext

39.5. Basic Statements

In this section and the following ones, we describe all the statement + types that are explicitly understood by + PL/pgSQL. + Anything not recognized as one of these statement types is presumed + to be an SQL command and is sent to the main database engine to execute, + as described in Section 39.5.2 + and Section 39.5.3. +

39.5.1. Assignment

An assignment of a value to a PL/pgSQL + variable is written as: +

variable := expression;

+ As explained previously, the expression in such a statement is evaluated + by means of an SQL SELECT command sent to the main + database engine. The expression must yield a single value (possibly + a row value, if the variable is a row or record variable). The target + variable can be a simple variable (optionally qualified with a block + name), a field of a row or record variable, or an element of an array + that is a simple variable or field. +

If the expression's result data type doesn't match the variable's + data type, or the variable has a specific size/precision + (like char(20)), the result value will be implicitly + converted by the PL/pgSQL interpreter using + the result type's output-function and + the variable type's input-function. Note that this could potentially + result in run-time errors generated by the input function, if the + string form of the result value is not acceptable to the input function. +

Examples: +

tax := subtotal * 0.06;
+my_record.user_id := 20;

+

39.5.2. Executing a Command With No Result

For any SQL command that does not return rows, for example + INSERT without a RETURNING clause, you can + execute the command within a PL/pgSQL function + just by writing the command. +

Any PL/pgSQL variable name appearing + in the command text is treated as a parameter, and then the + current value of the variable is provided as the parameter value + at run time. This is exactly like the processing described earlier + for expressions; for details see Section 39.10.1. +

When executing a SQL command in this way, + PL/pgSQL may cache and re-use the execution + plan for the command, as discussed in + Section 39.10.2. +

Sometimes it is useful to evaluate an expression or SELECT + query but discard the result, for example when calling a function + that has side-effects but no useful result value. To do + this in PL/pgSQL, use the + PERFORM statement: + +

PERFORM query;

+ + This executes query and discards the + result. Write the query the same + way you would write an SQL SELECT command, but replace the + initial keyword SELECT with PERFORM. + For WITH queries, use PERFORM and then + place the query in parentheses. (In this case, the query can only + return one row.) + PL/pgSQL variables will be + substituted into the query just as for commands that return no result, + and the plan is cached in the same way. Also, the special variable + FOUND is set to true if the query produced at + least one row, or false if it produced no rows (see + Section 39.5.5). +

Note: One might expect that writing SELECT directly + would accomplish this result, but at + present the only accepted way to do it is + PERFORM. A SQL command that can return rows, + such as SELECT, will be rejected as an error + unless it has an INTO clause as discussed in the + next section. +

An example: +

PERFORM create_mv('cs_session_page_requests_mv', my_query);

+

39.5.3. Executing a Query with a Single-row Result

The result of a SQL command yielding a single row (possibly of multiple + columns) can be assigned to a record variable, row-type variable, or list + of scalar variables. This is done by writing the base SQL command and + adding an INTO clause. For example, + +

SELECT select_expressions INTO [STRICT] target FROM ...;
+INSERT ... RETURNING expressions INTO [STRICT] target;
+UPDATE ... RETURNING expressions INTO [STRICT] target;
+DELETE ... RETURNING expressions INTO [STRICT] target;

+ + where target can be a record variable, a row + variable, or a comma-separated list of simple variables and + record/row fields. + PL/pgSQL variables will be + substituted into the rest of the query, and the plan is cached, + just as described above for commands that do not return rows. + This works for SELECT, + INSERT/UPDATE/DELETE with + RETURNING, and utility commands that return row-set + results (such as EXPLAIN). + Except for the INTO clause, the SQL command is the same + as it would be written outside PL/pgSQL. +

Tip: Note that this interpretation of SELECT with INTO + is quite different from PostgreSQL's regular + SELECT INTO command, wherein the INTO + target is a newly created table. If you want to create a table from a + SELECT result inside a + PL/pgSQL function, use the syntax + CREATE TABLE ... AS SELECT. +

If a row or a variable list is used as target, the query's result columns + must exactly match the structure of the target as to number and data + types, or else a run-time error + occurs. When a record variable is the target, it automatically + configures itself to the row type of the query result columns. +

The INTO clause can appear almost anywhere in the SQL + command. Customarily it is written either just before or just after + the list of select_expressions in a + SELECT command, or at the end of the command for other + command types. It is recommended that you follow this convention + in case the PL/pgSQL parser becomes + stricter in future versions. +

If STRICT is not specified in the INTO + clause, then target will be set to the first + row returned by the query, or to nulls if the query returned no rows. + (Note that "the first row" is not + well-defined unless you've used ORDER BY.) Any result rows + after the first row are discarded. + You can check the special FOUND variable (see + Section 39.5.5) to + determine whether a row was returned: + +

SELECT * INTO myrec FROM emp WHERE empname = myname;
+IF NOT FOUND THEN
+    RAISE EXCEPTION 'employee % not found', myname;
+END IF;

+ + If the STRICT option is specified, the query must + return exactly one row or a run-time error will be reported, either + NO_DATA_FOUND (no rows) or TOO_MANY_ROWS + (more than one row). You can use an exception block if you wish + to catch the error, for example: + +

BEGIN
+    SELECT * INTO STRICT myrec FROM emp WHERE empname = myname;
+    EXCEPTION
+        WHEN NO_DATA_FOUND THEN
+            RAISE EXCEPTION 'employee % not found', myname;
+        WHEN TOO_MANY_ROWS THEN
+            RAISE EXCEPTION 'employee % not unique', myname;
+END;

+ Successful execution of a command with STRICT + always sets FOUND to true. +

For INSERT/UPDATE/DELETE with + RETURNING, PL/pgSQL reports + an error for more than one returned row, even when + STRICT is not specified. This is because there + is no option such as ORDER BY with which to determine + which affected row should be returned. +

Note: The STRICT option matches the behavior of + Oracle PL/SQL's SELECT INTO and related statements. +

To handle cases where you need to process multiple result rows + from a SQL query, see Section 39.6.4. +

39.5.4. Executing Dynamic Commands

Oftentimes you will want to generate dynamic commands inside your + PL/pgSQL functions, that is, commands + that will involve different tables or different data types each + time they are executed. PL/pgSQL's + normal attempts to cache plans for commands (as discussed in + Section 39.10.2) will not work in such + scenarios. To handle this sort of problem, the + EXECUTE statement is provided: + +

EXECUTE command-string [ INTO [STRICT] target ] [ USING expression [, ... ] ];

+ + where command-string is an expression + yielding a string (of type text) containing the + command to be executed. The optional target + is a record variable, a row variable, or a comma-separated list of + simple variables and record/row fields, into which the results of + the command will be stored. The optional USING expressions + supply values to be inserted into the command. +

No substitution of PL/pgSQL variables is done on the + computed command string. Any required variable values must be inserted + in the command string as it is constructed; or you can use parameters + as described below. +

Also, there is no plan caching for commands executed via + EXECUTE. Instead, the command is always planned + each time the statement is run. Thus the command + string can be dynamically created within the function to perform + actions on different tables and columns. +

The INTO clause specifies where the results of + a SQL command returning rows should be assigned. If a row + or variable list is provided, it must exactly match the structure + of the query's results (when a + record variable is used, it will configure itself to match the + result structure automatically). If multiple rows are returned, + only the first will be assigned to the INTO + variable. If no rows are returned, NULL is assigned to the + INTO variable(s). If no INTO + clause is specified, the query results are discarded. +

If the STRICT option is given, an error is reported + unless the query produces exactly one row. +

The command string can use parameter values, which are referenced + in the command as $1, $2, etc. + These symbols refer to values supplied in the USING + clause. This method is often preferable to inserting data values + into the command string as text: it avoids run-time overhead of + converting the values to text and back, and it is much less prone + to SQL-injection attacks since there is no need for quoting or escaping. + An example is: +

EXECUTE 'SELECT count(*) FROM mytable WHERE inserted_by = $1 AND inserted <= $2'
+   INTO c
+   USING checked_user, checked_date;

+

Note that parameter symbols can only be used for data values + — if you want to use dynamically determined table or column + names, you must insert them into the command string textually. + For example, if the preceding query needed to be done against a + dynamically selected table, you could do this: +

EXECUTE 'SELECT count(*) FROM '
+    || tabname::regclass
+    || ' WHERE inserted_by = $1 AND inserted <= $2'
+   INTO c
+   USING checked_user, checked_date;

+ Another restriction on parameter symbols is that they only work in + SELECT, INSERT, UPDATE, and + DELETE commands. In other statement + types (generically called utility statements), you must insert + values textually even if they are just data values. +

An EXECUTE with a simple constant command string and some + USING parameters, as in the first example above, is + functionally equivalent to just writing the command directly in + PL/pgSQL and allowing replacement of + PL/pgSQL variables to happen automatically. + The important difference is that EXECUTE will re-plan + the command on each execution, generating a plan that is specific + to the current parameter values; whereas + PL/pgSQL may otherwise create a generic plan + and cache it for re-use. In situations where the best plan depends + strongly on the parameter values, it can be helpful to use + EXECUTE to positively ensure that a generic plan is not + selected. +

SELECT INTO is not currently supported within + EXECUTE; instead, execute a plain SELECT + command and specify INTO as part of the EXECUTE + itself. +

Note: The PL/pgSQL + EXECUTE statement is not related to the + EXECUTE SQL + statement supported by the + PostgreSQL server. The server's + EXECUTE statement cannot be used directly within + PL/pgSQL functions (and is not needed). +

Example 39-1. Quoting Values In Dynamic Queries

When working with dynamic commands you will often have to handle escaping + of single quotes. The recommended method for quoting fixed text in your + function body is dollar quoting. (If you have legacy code that does + not use dollar quoting, please refer to the + overview in Section 39.11.1, which can save you + some effort when translating said code to a more reasonable scheme.) +

Dynamic values that are to be inserted into the constructed + query require careful handling since they might themselves contain + quote characters. + An example (this assumes that you are using dollar quoting for the + function as a whole, so the quote marks need not be doubled): +

EXECUTE 'UPDATE tbl SET '
+        || quote_ident(colname)
+        || ' = '
+        || quote_literal(newvalue)
+        || ' WHERE key = '
+        || quote_literal(keyvalue);

+

This example demonstrates the use of the + quote_ident and + quote_literal functions (see Section 9.4). For safety, expressions containing column + or table identifiers should be passed through + quote_ident before insertion in a dynamic query. + Expressions containing values that should be literal strings in the + constructed command should be passed through quote_literal. + These functions take the appropriate steps to return the input text + enclosed in double or single quotes respectively, with any embedded + special characters properly escaped. +

Because quote_literal is labelled + STRICT, it will always return null when called with a + null argument. In the above example, if newvalue or + keyvalue were null, the entire dynamic query string would + become null, leading to an error from EXECUTE. + You can avoid this problem by using the quote_nullable + function, which works the same as quote_literal except that + when called with a null argument it returns the string NULL. + For example, +

EXECUTE 'UPDATE tbl SET '
+        || quote_ident(colname)
+        || ' = '
+        || quote_nullable(newvalue)
+        || ' WHERE key = '
+        || quote_nullable(keyvalue);

+ If you are dealing with values that might be null, you should usually + use quote_nullable in place of quote_literal. +

As always, care must be taken to ensure that null values in a query do + not deliver unintended results. For example the WHERE clause +

'WHERE key = ' || quote_nullable(keyvalue)

+ will never succeed if keyvalue is null, because the + result of using the equality operator = with a null operand + is always null. If you wish null to work like an ordinary key value, + you would need to rewrite the above as +

'WHERE key IS NOT DISTINCT FROM ' || quote_nullable(keyvalue)

+ (At present, IS NOT DISTINCT FROM is handled much less + efficiently than =, so don't do this unless you must. + See Section 9.2 for + more information on nulls and IS DISTINCT.) +

Note that dollar quoting is only useful for quoting fixed text. + It would be a very bad idea to try to write this example as: +

EXECUTE 'UPDATE tbl SET '
+        || quote_ident(colname)
+        || ' = $$'
+        || newvalue
+        || '$$ WHERE key = '
+        || quote_literal(keyvalue);

+ because it would break if the contents of newvalue + happened to contain $$. The same objection would + apply to any other dollar-quoting delimiter you might pick. + So, to safely quote text that is not known in advance, you + must use quote_literal, + quote_nullable, or quote_ident, as appropriate. +

Dynamic SQL statements can also be safely constructed using the + format function (see Section 9.4). For example: +

EXECUTE format('UPDATE tbl SET %I = %L WHERE key = %L', colname, newvalue, keyvalue);

+ The format function can be used in conjunction with + the USING clause: +

EXECUTE format('UPDATE tbl SET %I = $1 WHERE key = $2', colname)
+   USING newvalue, keyvalue;

+ This form is more efficient, because the parameters + newvalue and keyvalue are not + converted to text. +

A much larger example of a dynamic command and + EXECUTE can be seen in Example 39-8, which builds and executes a + CREATE FUNCTION command to define a new function. +

39.5.5. Obtaining the Result Status

There are several ways to determine the effect of a command. The + first method is to use the GET DIAGNOSTICS + command, which has the form: + +

GET [ CURRENT ] DIAGNOSTICS variable = item [ , ... ];

+ + This command allows retrieval of system status indicators. Each + item is a key word identifying a status + value to be assigned to the specified variable (which should be + of the right data type to receive it). The currently available + status items are ROW_COUNT, the number of rows + processed by the last SQL command sent to + the SQL engine, and RESULT_OID, + the OID of the last row inserted by the most recent + SQL command. Note that RESULT_OID + is only useful after an INSERT command into a + table containing OIDs. +

An example: +

GET DIAGNOSTICS integer_var = ROW_COUNT;

+

The second method to determine the effects of a command is to check the + special variable named FOUND, which is of + type boolean. FOUND starts out + false within each PL/pgSQL function call. + It is set by each of the following types of statements: + +

  • A SELECT INTO statement sets + FOUND true if a row is assigned, false if no + row is returned. +

  • A PERFORM statement sets FOUND + true if it produces (and discards) one or more rows, false if + no row is produced. +

  • UPDATE, INSERT, and DELETE + statements set FOUND true if at least one + row is affected, false if no row is affected. +

  • A FETCH statement sets FOUND + true if it returns a row, false if no row is returned. +

  • A MOVE statement sets FOUND + true if it successfully repositions the cursor, false otherwise. +

  • A FOR or FOREACH statement sets + FOUND true + if it iterates one or more times, else false. + FOUND is set this way when the + loop exits; inside the execution of the loop, + FOUND is not modified by the + loop statement, although it might be changed by the + execution of other statements within the loop body. +

  • RETURN QUERY and RETURN QUERY + EXECUTE statements set FOUND + true if the query returns at least one row, false if no row + is returned. +

+ + Other PL/pgSQL statements do not change + the state of FOUND. + Note in particular that EXECUTE + changes the output of GET DIAGNOSTICS, but + does not change FOUND. +

FOUND is a local variable within each + PL/pgSQL function; any changes to it + affect only the current function. +

39.5.6. Doing Nothing At All

Sometimes a placeholder statement that does nothing is useful. + For example, it can indicate that one arm of an if/then/else + chain is deliberately empty. For this purpose, use the + NULL statement: + +

NULL;

+

For example, the following two fragments of code are equivalent: +

BEGIN
+    y := x / 0;
+EXCEPTION
+    WHEN division_by_zero THEN
+        NULL;  -- ignore the error
+END;

+ +

BEGIN
+    y := x / 0;
+EXCEPTION
+    WHEN division_by_zero THEN  -- ignore the error
+END;

+ Which is preferable is a matter of taste. +

Note: In Oracle's PL/SQL, empty statement lists are not allowed, and so + NULL statements are required for situations + such as this. PL/pgSQL allows you to + just write nothing, instead. +


PrevHomeNext
ExpressionsUpControl Structures
\ No newline at end of file diff --git a/doc/src/sgml/html/plpgsql-structure.html b/doc/src/sgml/html/plpgsql-structure.html new file mode 100644 index 000000000..a291a9d3c --- /dev/null +++ b/doc/src/sgml/html/plpgsql-structure.html @@ -0,0 +1,396 @@ + +Structure of PL/pgSQL
PostgreSQL 9.2.2 Documentation
PrevUpChapter 39. PL/pgSQL - SQL Procedural LanguageNext

39.2. Structure of PL/pgSQL

PL/pgSQL is a block-structured language. + The complete text of a function definition must be a + block. A block is defined as: + +

[ <<label>> ]
+[ DECLARE
+    declarations ]
+BEGIN
+    statements
+END [ label ];

+

Each declaration and each statement within a block is terminated + by a semicolon. A block that appears within another block must + have a semicolon after END, as shown above; + however the final END that + concludes a function body does not require a semicolon. +

Tip: A common mistake is to write a semicolon immediately after + BEGIN. This is incorrect and will result in a syntax error. +

A label is only needed if you want to + identify the block for use + in an EXIT statement, or to qualify the names of the + variables declared in the block. If a label is given after + END, it must match the label at the block's beginning. +

All key words are case-insensitive. + Identifiers are implicitly converted to lower case + unless double-quoted, just as they are in ordinary SQL commands. +

Comments work the same way in PL/pgSQL code as in + ordinary SQL. A double dash (--) starts a comment + that extends to the end of the line. A /* starts a + block comment that extends to the matching occurrence of + */. Block comments nest. +

Any statement in the statement section of a block + can be a subblock. Subblocks can be used for + logical grouping or to localize variables to a small group + of statements. Variables declared in a subblock mask any + similarly-named variables of outer blocks for the duration + of the subblock; but you can access the outer variables anyway + if you qualify their names with their block's label. For example: +

CREATE FUNCTION somefunc() RETURNS integer AS $$
+<< outerblock >>
+DECLARE
+    quantity integer := 30;
+BEGIN
+    RAISE NOTICE 'Quantity here is %', quantity;  -- Prints 30
+    quantity := 50;
+    --
+    -- Create a subblock
+    --
+    DECLARE
+        quantity integer := 80;
+    BEGIN
+        RAISE NOTICE 'Quantity here is %', quantity;  -- Prints 80
+        RAISE NOTICE 'Outer quantity here is %', outerblock.quantity;  -- Prints 50
+    END;
+
+    RAISE NOTICE 'Quantity here is %', quantity;  -- Prints 50
+
+    RETURN quantity;
+END;
+$$ LANGUAGE plpgsql;

+

Note: There is actually a hidden "outer block" surrounding the body + of any PL/pgSQL function. This block provides the + declarations of the function's parameters (if any), as well as some + special variables such as FOUND (see + Section 39.5.5). The outer block is + labeled with the function's name, meaning that parameters and special + variables can be qualified with the function's name. +

It is important not to confuse the use of + BEGIN/END for grouping statements in + PL/pgSQL with the similarly-named SQL commands + for transaction + control. PL/pgSQL's BEGIN/END + are only for grouping; they do not start or end a transaction. + Functions and trigger procedures are always executed within a transaction + established by an outer query — they cannot start or commit that + transaction, since there would be no context for them to execute in. + However, a block containing an EXCEPTION clause effectively + forms a subtransaction that can be rolled back without affecting the + outer transaction. For more about that see Section 39.6.6. +


PrevHomeNext
OverviewUpDeclarations
\ No newline at end of file diff --git a/doc/src/sgml/html/plpgsql-trigger.html b/doc/src/sgml/html/plpgsql-trigger.html new file mode 100644 index 000000000..94bf4cf3c --- /dev/null +++ b/doc/src/sgml/html/plpgsql-trigger.html @@ -0,0 +1,1002 @@ + +Trigger Procedures
PostgreSQL 9.2.2 Documentation
PrevUpChapter 39. PL/pgSQL - SQL Procedural LanguageNext

39.9. Trigger Procedures

PL/pgSQL can be used to define trigger + procedures. A trigger procedure is created with the + CREATE FUNCTION command, declaring it as a function with + no arguments and a return type of trigger. Note that + the function must be declared with no arguments even if it expects + to receive arguments specified in CREATE TRIGGER — + trigger arguments are passed via TG_ARGV, as described + below. +

When a PL/pgSQL function is called as a + trigger, several special variables are created automatically in the + top-level block. They are: + +

NEW

Data type RECORD; variable holding the new + database row for INSERT/UPDATE operations in row-level + triggers. This variable is NULL in statement-level triggers + and for DELETE operations. +

OLD

Data type RECORD; variable holding the old + database row for UPDATE/DELETE operations in row-level + triggers. This variable is NULL in statement-level triggers + and for INSERT operations. +

TG_NAME

Data type name; variable that contains the name of the trigger actually + fired. +

TG_WHEN

Data type text; a string of + BEFORE, AFTER, or + INSTEAD OF, depending on the trigger's definition. +

TG_LEVEL

Data type text; a string of either + ROW or STATEMENT + depending on the trigger's definition. +

TG_OP

Data type text; a string of + INSERT, UPDATE, + DELETE, or TRUNCATE + telling for which operation the trigger was fired. +

TG_RELID

Data type oid; the object ID of the table that caused the + trigger invocation. +

TG_RELNAME

Data type name; the name of the table that caused the trigger + invocation. This is now deprecated, and could disappear in a future + release. Use TG_TABLE_NAME instead. +

TG_TABLE_NAME

Data type name; the name of the table that + caused the trigger invocation. +

TG_TABLE_SCHEMA

Data type name; the name of the schema of the + table that caused the trigger invocation. +

TG_NARGS

Data type integer; the number of arguments given to the trigger + procedure in the CREATE TRIGGER statement. +

TG_ARGV[]

Data type array of text; the arguments from + the CREATE TRIGGER statement. + The index counts from 0. Invalid + indexes (less than 0 or greater than or equal to tg_nargs) + result in a null value. +

+

A trigger function must return either NULL or a + record/row value having exactly the structure of the table the + trigger was fired for. +

Row-level triggers fired BEFORE can return null to signal the + trigger manager to skip the rest of the operation for this row + (i.e., subsequent triggers are not fired, and the + INSERT/UPDATE/DELETE does not occur + for this row). If a nonnull + value is returned then the operation proceeds with that row value. + Returning a row value different from the original value + of NEW alters the row that will be inserted or + updated. Thus, if the trigger function wants the triggering + action to succeed normally without altering the row + value, NEW (or a value equal thereto) has to be + returned. To alter the row to be stored, it is possible to + replace single values directly in NEW and return the + modified NEW, or to build a complete new record/row to + return. In the case of a before-trigger + on DELETE, the returned value has no direct + effect, but it has to be nonnull to allow the trigger action to + proceed. Note that NEW is null + in DELETE triggers, so returning that is + usually not sensible. The usual idiom in DELETE + triggers is to return OLD. +

INSTEAD OF triggers (which are always row-level triggers, + and may only be used on views) can return null to signal that they did + not perform any updates, and that the rest of the operation for this + row should be skipped (i.e., subsequent triggers are not fired, and the + row is not counted in the rows-affected status for the surrounding + INSERT/UPDATE/DELETE). + Otherwise a nonnull value should be returned, to signal + that the trigger performed the requested operation. For + INSERT and UPDATE operations, the return value + should be NEW, which the trigger function may modify to + support INSERT RETURNING and UPDATE RETURNING + (this will also affect the row value passed to any subsequent triggers). + For DELETE operations, the return value should be + OLD. +

The return value of a row-level trigger + fired AFTER or a statement-level trigger + fired BEFORE or AFTER is + always ignored; it might as well be null. However, any of these types of + triggers might still abort the entire operation by raising an error. +

Example 39-3 shows an example of a + trigger procedure in PL/pgSQL. +

Example 39-3. A PL/pgSQL Trigger Procedure

This example trigger ensures that any time a row is inserted or updated + in the table, the current user name and time are stamped into the + row. And it checks that an employee's name is given and that the + salary is a positive value. +

CREATE TABLE emp (
+    empname text,
+    salary integer,
+    last_date timestamp,
+    last_user text
+);
+
+CREATE FUNCTION emp_stamp() RETURNS trigger AS $emp_stamp$
+    BEGIN
+        -- Check that empname and salary are given
+        IF NEW.empname IS NULL THEN
+            RAISE EXCEPTION 'empname cannot be null';
+        END IF;
+        IF NEW.salary IS NULL THEN
+            RAISE EXCEPTION '% cannot have null salary', NEW.empname;
+        END IF;
+
+        -- Who works for us when she must pay for it?
+        IF NEW.salary < 0 THEN
+            RAISE EXCEPTION '% cannot have a negative salary', NEW.empname;
+        END IF;
+
+        -- Remember who changed the payroll when
+        NEW.last_date := current_timestamp;
+        NEW.last_user := current_user;
+        RETURN NEW;
+    END;
+$emp_stamp$ LANGUAGE plpgsql;
+
+CREATE TRIGGER emp_stamp BEFORE INSERT OR UPDATE ON emp
+    FOR EACH ROW EXECUTE PROCEDURE emp_stamp();

Another way to log changes to a table involves creating a new table that + holds a row for each insert, update, or delete that occurs. This approach + can be thought of as auditing changes to a table. + Example 39-4 shows an example of an + audit trigger procedure in PL/pgSQL. +

Example 39-4. A PL/pgSQL Trigger Procedure For Auditing

This example trigger ensures that any insert, update or delete of a row + in the emp table is recorded (i.e., audited) in the emp_audit table. + The current time and user name are stamped into the row, together with + the type of operation performed on it. +

CREATE TABLE emp (
+    empname           text NOT NULL,
+    salary            integer
+);
+
+CREATE TABLE emp_audit(
+    operation         char(1)   NOT NULL,
+    stamp             timestamp NOT NULL,
+    userid            text      NOT NULL,
+    empname           text      NOT NULL,
+    salary integer
+);
+
+CREATE OR REPLACE FUNCTION process_emp_audit() RETURNS TRIGGER AS $emp_audit$
+    BEGIN
+        --
+        -- Create a row in emp_audit to reflect the operation performed on emp,
+        -- make use of the special variable TG_OP to work out the operation.
+        --
+        IF (TG_OP = 'DELETE') THEN
+            INSERT INTO emp_audit SELECT 'D', now(), user, OLD.*;
+            RETURN OLD;
+        ELSIF (TG_OP = 'UPDATE') THEN
+            INSERT INTO emp_audit SELECT 'U', now(), user, NEW.*;
+            RETURN NEW;
+        ELSIF (TG_OP = 'INSERT') THEN
+            INSERT INTO emp_audit SELECT 'I', now(), user, NEW.*;
+            RETURN NEW;
+        END IF;
+        RETURN NULL; -- result is ignored since this is an AFTER trigger
+    END;
+$emp_audit$ LANGUAGE plpgsql;
+
+CREATE TRIGGER emp_audit
+AFTER INSERT OR UPDATE OR DELETE ON emp
+    FOR EACH ROW EXECUTE PROCEDURE process_emp_audit();

A variation of the previous example uses a view joining the main table + to the audit table, to show when each entry was last modified. This + approach still records the full audit trail of changes to the table, + but also presents a simplified view of the audit trail, showing just + the last modified timestamp derived from the audit trail for each entry. + Example 39-5 shows an example + of an audit trigger on a view in PL/pgSQL. +

Example 39-5. A PL/pgSQL View Trigger Procedure For Auditing

This example uses a trigger on the view to make it updatable, and + ensure that any insert, update or delete of a row in the view is + recorded (i.e., audited) in the emp_audit table. The current time + and user name are recorded, together with the type of operation + performed, and the view displays the last modified time of each row. +

CREATE TABLE emp (
+    empname           text PRIMARY KEY,
+    salary            integer
+);
+
+CREATE TABLE emp_audit(
+    operation         char(1)   NOT NULL,
+    userid            text      NOT NULL,
+    empname           text      NOT NULL,
+    salary            integer,
+    stamp             timestamp NOT NULL
+);
+
+CREATE VIEW emp_view AS
+    SELECT e.empname,
+           e.salary,
+           max(ea.stamp) AS last_updated
+      FROM emp e
+      LEFT JOIN emp_audit ea ON ea.empname = e.empname
+     GROUP BY 1, 2;
+
+CREATE OR REPLACE FUNCTION update_emp_view() RETURNS TRIGGER AS $$
+    BEGIN
+        --
+        -- Perform the required operation on emp, and create a row in emp_audit
+        -- to reflect the change made to emp.
+        --
+        IF (TG_OP = 'DELETE') THEN
+            DELETE FROM emp WHERE empname = OLD.empname;
+            IF NOT FOUND THEN RETURN NULL; END IF;
+
+            OLD.last_updated = now();
+            INSERT INTO emp_audit VALUES('D', user, OLD.*);
+            RETURN OLD;
+        ELSIF (TG_OP = 'UPDATE') THEN
+            UPDATE emp SET salary = NEW.salary WHERE empname = OLD.empname;
+            IF NOT FOUND THEN RETURN NULL; END IF;
+
+            NEW.last_updated = now();
+            INSERT INTO emp_audit VALUES('U', user, NEW.*);
+            RETURN NEW;
+        ELSIF (TG_OP = 'INSERT') THEN
+            INSERT INTO emp VALUES(NEW.empname, NEW.salary);
+
+            NEW.last_updated = now();
+            INSERT INTO emp_audit VALUES('I', user, NEW.*);
+            RETURN NEW;
+        END IF;
+    END;
+$$ LANGUAGE plpgsql;
+
+CREATE TRIGGER emp_audit
+INSTEAD OF INSERT OR UPDATE OR DELETE ON emp_view
+    FOR EACH ROW EXECUTE PROCEDURE update_emp_view();

One use of triggers is to maintain a summary table + of another table. The resulting summary can be used in place of the + original table for certain queries — often with vastly reduced run + times. + This technique is commonly used in Data Warehousing, where the tables + of measured or observed data (called fact tables) might be extremely large. + Example 39-6 shows an example of a + trigger procedure in PL/pgSQL that maintains + a summary table for a fact table in a data warehouse. +

Example 39-6. A PL/pgSQL Trigger Procedure For Maintaining A Summary Table

The schema detailed here is partly based on the Grocery Store + example from The Data Warehouse Toolkit + by Ralph Kimball. +

--
+-- Main tables - time dimension and sales fact.
+--
+CREATE TABLE time_dimension (
+    time_key                    integer NOT NULL,
+    day_of_week                 integer NOT NULL,
+    day_of_month                integer NOT NULL,
+    month                       integer NOT NULL,
+    quarter                     integer NOT NULL,
+    year                        integer NOT NULL
+);
+CREATE UNIQUE INDEX time_dimension_key ON time_dimension(time_key);
+
+CREATE TABLE sales_fact (
+    time_key                    integer NOT NULL,
+    product_key                 integer NOT NULL,
+    store_key                   integer NOT NULL,
+    amount_sold                 numeric(12,2) NOT NULL,
+    units_sold                  integer NOT NULL,
+    amount_cost                 numeric(12,2) NOT NULL
+);
+CREATE INDEX sales_fact_time ON sales_fact(time_key);
+
+--
+-- Summary table - sales by time.
+--
+CREATE TABLE sales_summary_bytime (
+    time_key                    integer NOT NULL,
+    amount_sold                 numeric(15,2) NOT NULL,
+    units_sold                  numeric(12) NOT NULL,
+    amount_cost                 numeric(15,2) NOT NULL
+);
+CREATE UNIQUE INDEX sales_summary_bytime_key ON sales_summary_bytime(time_key);
+
+--
+-- Function and trigger to amend summarized column(s) on UPDATE, INSERT, DELETE.
+--
+CREATE OR REPLACE FUNCTION maint_sales_summary_bytime() RETURNS TRIGGER
+AS $maint_sales_summary_bytime$
+    DECLARE
+        delta_time_key          integer;
+        delta_amount_sold       numeric(15,2);
+        delta_units_sold        numeric(12);
+        delta_amount_cost       numeric(15,2);
+    BEGIN
+
+        -- Work out the increment/decrement amount(s).
+        IF (TG_OP = 'DELETE') THEN
+
+            delta_time_key = OLD.time_key;
+            delta_amount_sold = -1 * OLD.amount_sold;
+            delta_units_sold = -1 * OLD.units_sold;
+            delta_amount_cost = -1 * OLD.amount_cost;
+
+        ELSIF (TG_OP = 'UPDATE') THEN
+
+            -- forbid updates that change the time_key -
+            -- (probably not too onerous, as DELETE + INSERT is how most
+            -- changes will be made).
+            IF ( OLD.time_key != NEW.time_key) THEN
+                RAISE EXCEPTION 'Update of time_key : % -> % not allowed',
+                                                      OLD.time_key, NEW.time_key;
+            END IF;
+
+            delta_time_key = OLD.time_key;
+            delta_amount_sold = NEW.amount_sold - OLD.amount_sold;
+            delta_units_sold = NEW.units_sold - OLD.units_sold;
+            delta_amount_cost = NEW.amount_cost - OLD.amount_cost;
+
+        ELSIF (TG_OP = 'INSERT') THEN
+
+            delta_time_key = NEW.time_key;
+            delta_amount_sold = NEW.amount_sold;
+            delta_units_sold = NEW.units_sold;
+            delta_amount_cost = NEW.amount_cost;
+
+        END IF;
+
+
+        -- Insert or update the summary row with the new values.
+        <<insert_update>>
+        LOOP
+            UPDATE sales_summary_bytime
+                SET amount_sold = amount_sold + delta_amount_sold,
+                    units_sold = units_sold + delta_units_sold,
+                    amount_cost = amount_cost + delta_amount_cost
+                WHERE time_key = delta_time_key;
+
+            EXIT insert_update WHEN found;
+
+            BEGIN
+                INSERT INTO sales_summary_bytime (
+                            time_key,
+                            amount_sold,
+                            units_sold,
+                            amount_cost)
+                    VALUES (
+                            delta_time_key,
+                            delta_amount_sold,
+                            delta_units_sold,
+                            delta_amount_cost
+                           );
+
+                EXIT insert_update;
+
+            EXCEPTION
+                WHEN UNIQUE_VIOLATION THEN
+                    -- do nothing
+            END;
+        END LOOP insert_update;
+
+        RETURN NULL;
+
+    END;
+$maint_sales_summary_bytime$ LANGUAGE plpgsql;
+
+CREATE TRIGGER maint_sales_summary_bytime
+AFTER INSERT OR UPDATE OR DELETE ON sales_fact
+    FOR EACH ROW EXECUTE PROCEDURE maint_sales_summary_bytime();
+
+INSERT INTO sales_fact VALUES(1,1,1,10,3,15);
+INSERT INTO sales_fact VALUES(1,2,1,20,5,35);
+INSERT INTO sales_fact VALUES(2,2,1,40,15,135);
+INSERT INTO sales_fact VALUES(2,3,1,10,1,13);
+SELECT * FROM sales_summary_bytime;
+DELETE FROM sales_fact WHERE product_key = 1;
+SELECT * FROM sales_summary_bytime;
+UPDATE sales_fact SET units_sold = units_sold * 2;
+SELECT * FROM sales_summary_bytime;

PrevHomeNext
Errors and MessagesUpPL/pgSQL Under the Hood
\ No newline at end of file diff --git a/doc/src/sgml/html/plpgsql.html b/doc/src/sgml/html/plpgsql.html new file mode 100644 index 000000000..ebfb4d657 --- /dev/null +++ b/doc/src/sgml/html/plpgsql.html @@ -0,0 +1,431 @@ + +PL/pgSQL - SQL Procedural Language

Chapter 39. PL/pgSQL - SQL Procedural Language

Table of Contents
39.1. Overview
39.1.1. Advantages of Using PL/pgSQL
39.1.2. Supported Argument and Result Data Types
39.2. Structure of PL/pgSQL
39.3. Declarations
39.3.1. Declaring Function Parameters
39.3.2. ALIAS
39.3.3. Copying Types
39.3.4. Row Types
39.3.5. Record Types
39.3.6. Collation of PL/pgSQL Variables
39.4. Expressions
39.5. Basic Statements
39.5.1. Assignment
39.5.2. Executing a Command With No Result
39.5.3. Executing a Query with a Single-row Result
39.5.4. Executing Dynamic Commands
39.5.5. Obtaining the Result Status
39.5.6. Doing Nothing At All
39.6. Control Structures
39.6.1. Returning From a Function
39.6.2. Conditionals
39.6.3. Simple Loops
39.6.4. Looping Through Query Results
39.6.5. Looping Through Arrays
39.6.6. Trapping Errors
39.7. Cursors
39.7.1. Declaring Cursor Variables
39.7.2. Opening Cursors
39.7.3. Using Cursors
39.7.4. Looping Through a Cursor's Result
39.8. Errors and Messages
39.9. Trigger Procedures
39.10. PL/pgSQL Under the Hood
39.10.1. Variable Substitution
39.10.2. Plan Caching
39.11. Tips for Developing in PL/pgSQL
39.12. Porting from Oracle PL/SQL
39.12.1. Porting Examples
39.12.2. Other Things to Watch For
39.12.3. Appendix

PrevHomeNext
Installing Procedural LanguagesUpOverview
\ No newline at end of file diff --git a/doc/src/sgml/html/plpython-data.html b/doc/src/sgml/html/plpython-data.html new file mode 100644 index 000000000..e125560d5 --- /dev/null +++ b/doc/src/sgml/html/plpython-data.html @@ -0,0 +1,788 @@ + +Data Values
PostgreSQL 9.2.2 Documentation
PrevUpChapter 42. PL/Python - Python Procedural LanguageNext

42.3. Data Values

Generally speaking, the aim of PL/Python is to provide + a "natural" mapping between the PostgreSQL and the + Python worlds. This informs the data mapping rules described + below. +

42.3.1. Data Type Mapping

Function arguments are converted from their PostgreSQL type to a + corresponding Python type: +

  • PostgreSQL boolean is converted to Python bool. +

  • PostgreSQL smallint and int are + converted to Python int. + PostgreSQL bigint is converted + to long in Python 2 and to int in + Python 3. +

  • PostgreSQL real, double, + and numeric are converted to + Python float. Note that for + the numeric this loses information and can lead to + incorrect results. This might be fixed in a future + release. +

  • PostgreSQL bytea is converted to + Python str in Python 2 and to bytes + in Python 3. In Python 2, the string should be treated as a + byte sequence without any character encoding. +

  • All other data types, including the PostgreSQL character string + types, are converted to a Python str. In Python + 2, this string will be in the PostgreSQL server encoding; in + Python 3, it will be a Unicode string like all strings. +

  • For nonscalar data types, see below. +

+

Function return values are converted to the declared PostgreSQL + return data type as follows: +

  • When the PostgreSQL return type is boolean, the + return value will be evaluated for truth according to the + Python rules. That is, 0 and empty string + are false, but notably 'f' is true. +

  • When the PostgreSQL return type is bytea, the + return value will be converted to a string (Python 2) or bytes + (Python 3) using the respective Python built-ins, with the + result being converted bytea. +

  • For all other PostgreSQL return types, the returned Python + value is converted to a string using the Python + built-in str, and the result is passed to the + input function of the PostgreSQL data type. +

    Strings in Python 2 are required to be in the PostgreSQL server + encoding when they are passed to PostgreSQL. Strings that are + not valid in the current server encoding will raise an error, + but not all encoding mismatches can be detected, so garbage + data can still result when this is not done correctly. Unicode + strings are converted to the correct encoding automatically, so + it can be safer and more convenient to use those. In Python 3, + all strings are Unicode strings. +

  • For nonscalar data types, see below. +

+ + Note that logical mismatches between the declared PostgreSQL + return type and the Python data type of the actual return object + are not flagged; the value will be converted in any case. +

42.3.2. Null, None

If an SQL null value is passed to a + function, the argument value will appear as None in + Python. For example, the function definition of pymax + shown in Section 42.2 will return the wrong answer for null + inputs. We could add STRICT to the function definition + to make PostgreSQL do something more reasonable: + if a null value is passed, the function will not be called at all, + but will just return a null result automatically. Alternatively, + we could check for null inputs in the function body: + +

CREATE FUNCTION pymax (a integer, b integer)
+  RETURNS integer
+AS $$
+  if (a is None) or (b is None):
+    return None
+  if a > b:
+    return a
+  return b
+$$ LANGUAGE plpythonu;

+ + As shown above, to return an SQL null value from a PL/Python + function, return the value None. This can be done whether the + function is strict or not. +

42.3.3. Arrays, Lists

SQL array values are passed into PL/Python as a Python list. To + return an SQL array value out of a PL/Python function, return a + Python sequence, for example a list or tuple: + +

CREATE FUNCTION return_arr()
+  RETURNS int[]
+AS $$
+return (1, 2, 3, 4, 5)
+$$ LANGUAGE plpythonu;
+
+SELECT return_arr();
+ return_arr  
+-------------
+ {1,2,3,4,5}
+(1 row)

+ + Note that in Python, strings are sequences, which can have + undesirable effects that might be familiar to Python programmers: + +

CREATE FUNCTION return_str_arr()
+  RETURNS varchar[]
+AS $$
+return "hello"
+$$ LANGUAGE plpythonu;
+
+SELECT return_str_arr();
+ return_str_arr
+----------------
+ {h,e,l,l,o}
+(1 row)

+

42.3.4. Composite Types

Composite-type arguments are passed to the function as Python mappings. The + element names of the mapping are the attribute names of the composite type. + If an attribute in the passed row has the null value, it has the value + None in the mapping. Here is an example: + +

CREATE TABLE employee (
+  name text,
+  salary integer,
+  age integer
+);
+
+CREATE FUNCTION overpaid (e employee)
+  RETURNS boolean
+AS $$
+  if e["salary"] > 200000:
+    return True
+  if (e["age"] < 30) and (e["salary"] > 100000):
+    return True
+  return False
+$$ LANGUAGE plpythonu;

+

There are multiple ways to return row or composite types from a Python + function. The following examples assume we have: + +

CREATE TYPE named_value AS (
+  name   text,
+  value  integer
+);

+ + A composite result can be returned as a: + +

Sequence type (a tuple or list, but not a set because + it is not indexable)

Returned sequence objects must have the same number of items as the + composite result type has fields. The item with index 0 is assigned to + the first field of the composite type, 1 to the second and so on. For + example: + +

CREATE FUNCTION make_pair (name text, value integer)
+  RETURNS named_value
+AS $$
+  return [ name, value ]
+  # or alternatively, as tuple: return ( name, value )
+$$ LANGUAGE plpythonu;

+ + To return a SQL null for any column, insert None at + the corresponding position. +

Mapping (dictionary)

The value for each result type column is retrieved from the mapping + with the column name as key. Example: + +

CREATE FUNCTION make_pair (name text, value integer)
+  RETURNS named_value
+AS $$
+  return { "name": name, "value": value }
+$$ LANGUAGE plpythonu;

+ + Any extra dictionary key/value pairs are ignored. Missing keys are + treated as errors. + To return a SQL null value for any column, insert + None with the corresponding column name as the key. +

Object (any object providing method __getattr__)

This works the same as a mapping. + Example: + +

CREATE FUNCTION make_pair (name text, value integer)
+  RETURNS named_value
+AS $$
+  class named_value:
+    def __init__ (self, n, v):
+      self.name = n
+      self.value = v
+  return named_value(name, value)
+
+  # or simply
+  class nv: pass
+  nv.name = name
+  nv.value = value
+  return nv
+$$ LANGUAGE plpythonu;

+

+

Functions with OUT parameters are also supported. For example: +

CREATE FUNCTION multiout_simple(OUT i integer, OUT j integer) AS $$
+return (1, 2)
+$$ LANGUAGE plpythonu;
+
+SELECT * FROM multiout_simple();

+

42.3.5. Set-returning Functions

A PL/Python function can also return sets of + scalar or composite types. There are several ways to achieve this because + the returned object is internally turned into an iterator. The following + examples assume we have composite type: + +

CREATE TYPE greeting AS (
+  how text,
+  who text
+);

+ + A set result can be returned from a: + +

Sequence type (tuple, list, set)

CREATE FUNCTION greet (how text)
+  RETURNS SETOF greeting
+AS $$
+  # return tuple containing lists as composite types
+  # all other combinations work also
+  return ( [ how, "World" ], [ how, "PostgreSQL" ], [ how, "PL/Python" ] )
+$$ LANGUAGE plpythonu;

+

Iterator (any object providing __iter__ and + next methods)

CREATE FUNCTION greet (how text)
+  RETURNS SETOF greeting
+AS $$
+  class producer:
+    def __init__ (self, how, who):
+      self.how = how
+      self.who = who
+      self.ndx = -1
+
+    def __iter__ (self):
+      return self
+
+    def next (self):
+      self.ndx += 1
+      if self.ndx == len(self.who):
+        raise StopIteration
+      return ( self.how, self.who[self.ndx] )
+
+  return producer(how, [ "World", "PostgreSQL", "PL/Python" ])
+$$ LANGUAGE plpythonu;

+

Generator (yield)

CREATE FUNCTION greet (how text)
+  RETURNS SETOF greeting
+AS $$
+  for who in [ "World", "PostgreSQL", "PL/Python" ]:
+    yield ( how, who )
+$$ LANGUAGE plpythonu;

+ +

Warning

Due to Python + bug #1483133, + some debug versions of Python 2.4 + (configured and compiled with option --with-pydebug) + are known to crash the PostgreSQL server + when using an iterator to return a set result. + Unpatched versions of Fedora 4 contain this bug. + It does not happen in production versions of Python or on patched + versions of Fedora 4. +

+

+

Set-returning functions with OUT parameters + (using RETURNS SETOF record) are also + supported. For example: +

CREATE FUNCTION multiout_simple_setof(n integer, OUT integer, OUT integer) RETURNS SETOF record AS $$
+return [(1, 2)] * n
+$$ LANGUAGE plpythonu;
+
+SELECT * FROM multiout_simple_setof(3);

+


PrevHomeNext
PL/Python FunctionsUpSharing Data
\ No newline at end of file diff --git a/doc/src/sgml/html/plpython-database.html b/doc/src/sgml/html/plpython-database.html new file mode 100644 index 000000000..208817b7c --- /dev/null +++ b/doc/src/sgml/html/plpython-database.html @@ -0,0 +1,766 @@ + +Database Access
PostgreSQL 9.2.2 Documentation
PrevUpChapter 42. PL/Python - Python Procedural LanguageNext

42.7. Database Access

The PL/Python language module automatically imports a Python module + called plpy. The functions and constants in + this module are available to you in the Python code as + plpy.foo. +

42.7.1. Database Access Functions

The plpy module provides several functions to execute + database commands: +

plpy.execute(query [, max-rows])

Calling plpy.execute with a query string and an + optional row limit argument causes that query to be run and the result to + be returned in a result object. +

The result object emulates a list or dictionary object. The result + object can be accessed by row number and column name. For example: +

rv = plpy.execute("SELECT * FROM my_table", 5)

+ returns up to 5 rows from my_table. If + my_table has a column + my_column, it would be accessed as: +

foo = rv[i]["my_column"]

+ The number of rows returned can be obtained using the built-in + len function. +

The result object has these additional methods: +

nrows()

Returns the number of rows processed by the command. Note that this + is not necessarily the same as the number of rows returned. For + example, an UPDATE command will set this value but + won't return any rows (unless RETURNING is used). +

status()

The SPI_execute() return value. +

colnames()
coltypes()
coltypmods()

Return a list of column names, list of column type OIDs, and list of + type-specific type modifiers for the columns, respectively. +

These methods raise an exception when called on a result object from + a command that did not produce a result set, e.g., + UPDATE without RETURNING, or + DROP TABLE. But it is OK to use these methods on + a result set containing zero rows. +

+

The result object can be modified. +

Note that calling plpy.execute will cause the entire + result set to be read into memory. Only use that function when you are + sure that the result set will be relatively small. If you don't want to + risk excessive memory usage when fetching large results, + use plpy.cursor rather + than plpy.execute. +

plpy.prepare(query [, argtypes])
plpy.execute(plan [, arguments [, max-rows]])

+ plpy.prepare prepares the execution plan for a + query. It is called with a query string and a list of parameter types, + if you have parameter references in the query. For example: +

plan = plpy.prepare("SELECT last_name FROM my_users WHERE first_name = $1", ["text"])

+ text is the type of the variable you will be passing + for $1. The second argument is optional if you don't + want to pass any parameters to the query. +

After preparing a statement, you use a variant of the + function plpy.execute to run it: +

rv = plpy.execute(plan, ["name"], 5)

+ Pass the plan as the first argument (instead of the query string), and a + list of values to substitute into the query as the second argument. The + second argument is optional if the query does not expect any parameters. + The third argument is the optional row limit as before. +

Query parameters and result row fields are converted between PostgreSQL + and Python data types as described in Section 42.3. + The exception is that composite types are currently not supported: They + will be rejected as query parameters and are converted to strings when + appearing in a query result. As a workaround for the latter problem, the + query can sometimes be rewritten so that the composite type result + appears as a result row rather than as a field of the result row. + Alternatively, the resulting string could be parsed apart by hand, but + this approach is not recommended because it is not future-proof. +

When you prepare a plan using the PL/Python module it is automatically + saved. Read the SPI documentation (Chapter 43) for a + description of what this means. In order to make effective use of this + across function calls one needs to use one of the persistent storage + dictionaries SD or GD (see + Section 42.4). For example: +

CREATE FUNCTION usesavedplan() RETURNS trigger AS $$
+    plan = SD.setdefault("plan", plpy.prepare("SELECT 1"))
+    # rest of function
+$$ LANGUAGE plpythonu;

+

plpy.cursor(query)
plpy.cursor(plan [, arguments])

The plpy.cursor function accepts the same arguments + as plpy.execute (except for the row limit) and returns + a cursor object, which allows you to process large result sets in smaller + chunks. As with plpy.execute, either a query string + or a plan object along with a list of arguments can be used. +

The cursor object provides a fetch method that accepts + an integer parameter and returns a result object. Each time you + call fetch, the returned object will contain the next + batch of rows, never larger than the parameter value. Once all rows are + exhausted, fetch starts returning an empty result + object. Cursor objects also provide an + iterator + interface, yielding one row at a time until all rows are + exhausted. Data fetched that way is not returned as result objects, but + rather as dictionaries, each dictionary corresponding to a single result + row. +

An example of two ways of processing data from a large table is: +

CREATE FUNCTION count_odd_iterator() RETURNS integer AS $$
+odd = 0
+for row in plpy.cursor("select num from largetable"):
+    if row['num'] % 2:
+         odd += 1
+return odd
+$$ LANGUAGE plpythonu;
+
+CREATE FUNCTION count_odd_fetch(batch_size integer) RETURNS integer AS $$
+odd = 0
+cursor = plpy.cursor("select num from largetable")
+while True:
+    rows = cursor.fetch(batch_size)
+    if not rows:
+        break
+    for row in rows:
+        if row['num'] % 2:
+            odd += 1
+return odd
+$$ LANGUAGE plpythonu;
+
+CREATE FUNCTION count_odd_prepared() RETURNS integer AS $$
+odd = 0
+plan = plpy.prepare("select num from largetable where num % $1 <> 0", ["integer"])
+rows = list(plpy.cursor(plan, [2]))
+
+return len(rows)
+$$ LANGUAGE plpythonu;

+

Cursors are automatically disposed of. But if you want to explicitly + release all resources held by a cursor, use the close + method. Once closed, a cursor cannot be fetched from anymore. +

Tip: Do not confuse objects created by plpy.cursor with + DB-API cursors as defined by + the Python + Database API specification. They don't have anything in common + except for the name. +

42.7.2. Trapping Errors

Functions accessing the database might encounter errors, which + will cause them to abort and raise an exception. Both + plpy.execute and + plpy.prepare can raise an instance of a subclass of + plpy.SPIError, which by default will terminate + the function. This error can be handled just like any other + Python exception, by using the try/except + construct. For example: +

CREATE FUNCTION try_adding_joe() RETURNS text AS $$
+    try:
+        plpy.execute("INSERT INTO users(username) VALUES ('joe')")
+    except plpy.SPIError:
+        return "something went wrong"
+    else:
+        return "Joe added"
+$$ LANGUAGE plpythonu;

+

The actual class of the exception being raised corresponds to the + specific condition that caused the error. Refer + to Table A-1 for a list of possible + conditions. The module + plpy.spiexceptions defines an exception class + for each PostgreSQL condition, deriving + their names from the condition name. For + instance, division_by_zero + becomes DivisionByZero, unique_violation + becomes UniqueViolation, fdw_error + becomes FdwError, and so on. Each of these + exception classes inherits from SPIError. This + separation makes it easier to handle specific errors, for + instance: +

CREATE FUNCTION insert_fraction(numerator int, denominator int) RETURNS text AS $$
+from plpy import spiexceptions
+try:
+    plan = plpy.prepare("INSERT INTO fractions (frac) VALUES ($1 / $2)", ["int", "int"])
+    plpy.execute(plan, [numerator, denominator])
+except spiexceptions.DivisionByZero:
+    return "denominator cannot equal zero"
+except spiexceptions.UniqueViolation:
+    return "already have that fraction"
+except plpy.SPIError, e:
+    return "other error, SQLSTATE %s" % e.sqlstate
+else:
+    return "fraction inserted"
+$$ LANGUAGE plpythonu;

+ Note that because all exceptions from + the plpy.spiexceptions module inherit + from SPIError, an except + clause handling it will catch any database access error. +

As an alternative way of handling different error conditions, you + can catch the SPIError exception and determine + the specific error condition inside the except + block by looking at the sqlstate attribute of + the exception object. This attribute is a string value containing + the "SQLSTATE" error code. This approach provides + approximately the same functionality +


PrevHomeNext
Trigger FunctionsUpExplicit Subtransactions
\ No newline at end of file diff --git a/doc/src/sgml/html/plpython-do.html b/doc/src/sgml/html/plpython-do.html new file mode 100644 index 000000000..9ad51a6d2 --- /dev/null +++ b/doc/src/sgml/html/plpython-do.html @@ -0,0 +1,180 @@ + +Anonymous Code Blocks
PostgreSQL 9.2.2 Documentation
PrevUpChapter 42. PL/Python - Python Procedural LanguageNext

42.5. Anonymous Code Blocks

PL/Python also supports anonymous code blocks called with the + DO statement: + +

DO $$
+    # PL/Python code
+$$ LANGUAGE plpythonu;

+ + An anonymous code block receives no arguments, and whatever value it + might return is discarded. Otherwise it behaves just like a function. +


PrevHomeNext
Sharing DataUpTrigger Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/plpython-envar.html b/doc/src/sgml/html/plpython-envar.html new file mode 100644 index 000000000..6c85e018d --- /dev/null +++ b/doc/src/sgml/html/plpython-envar.html @@ -0,0 +1,263 @@ + +Environment Variables
PostgreSQL 9.2.2 Documentation
PrevUpChapter 42. PL/Python - Python Procedural LanguageNext

42.10. Environment Variables

Some of the environment variables that are accepted by the Python + interpreter can also be used to affect PL/Python behavior. They + would need to be set in the environment of the main PostgreSQL + server process, for example in a start script. The available + environment variables depend on the version of Python; see the + Python documentation for details. At the time of this writing, the + following environment variables have an affect on PL/Python, + assuming an adequate Python version: +

  • PYTHONHOME

  • PYTHONPATH

  • PYTHONY2K

  • PYTHONOPTIMIZE

  • PYTHONDEBUG

  • PYTHONVERBOSE

  • PYTHONCASEOK

  • PYTHONDONTWRITEBYTECODE

  • PYTHONIOENCODING

  • PYTHONUSERBASE

  • PYTHONHASHSEED

+ + (It appears to be a Python implementation detail beyond the control + of PL/Python that some of the environment variables listed on + the python man page are only effective in a + command-line interpreter and not an embedded Python interpreter.) +


PrevHomeNext
Utility FunctionsUpServer Programming Interface
\ No newline at end of file diff --git a/doc/src/sgml/html/plpython-funcs.html b/doc/src/sgml/html/plpython-funcs.html new file mode 100644 index 000000000..f08f5e7eb --- /dev/null +++ b/doc/src/sgml/html/plpython-funcs.html @@ -0,0 +1,308 @@ + +PL/Python Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 42. PL/Python - Python Procedural LanguageNext

42.2. PL/Python Functions

Functions in PL/Python are declared via the + standard CREATE FUNCTION syntax: + +

CREATE FUNCTION funcname (argument-list)
+  RETURNS return-type
+AS $$
+  # PL/Python function body
+$$ LANGUAGE plpythonu;

+

The body of a function is simply a Python script. When the function + is called, its arguments are passed as elements of the list + args; named arguments are also passed as + ordinary variables to the Python script. Use of named arguments is + usually more readable. The result is returned from the Python code + in the usual way, with return or + yield (in case of a result-set statement). If + you do not provide a return value, Python returns the default + None. PL/Python translates + Python's None into the SQL null value. +

For example, a function to return the greater of two integers can be + defined as: + +

CREATE FUNCTION pymax (a integer, b integer)
+  RETURNS integer
+AS $$
+  if a > b:
+    return a
+  return b
+$$ LANGUAGE plpythonu;

+ + The Python code that is given as the body of the function definition + is transformed into a Python function. For example, the above results in: + +

def __plpython_procedure_pymax_23456():
+  if a > b:
+    return a
+  return b

+ + assuming that 23456 is the OID assigned to the function by + PostgreSQL. +

The arguments are set as global variables. Because of the scoping + rules of Python, this has the subtle consequence that an argument + variable cannot be reassigned inside the function to the value of + an expression that involves the variable name itself, unless the + variable is redeclared as global in the block. For example, the + following won't work: +

CREATE FUNCTION pystrip(x text)
+  RETURNS text
+AS $$
+  x = x.strip()  # error
+  return x
+$$ LANGUAGE plpythonu;

+ because assigning to x + makes x a local variable for the entire block, + and so the x on the right-hand side of the + assignment refers to a not-yet-assigned local + variable x, not the PL/Python function + parameter. Using the global statement, this can + be made to work: +

CREATE FUNCTION pystrip(x text)
+  RETURNS text
+AS $$
+  global x
+  x = x.strip()  # ok now
+  return x
+$$ LANGUAGE plpythonu;

+ But it is advisable not to rely on this implementation detail of + PL/Python. It is better to treat the function parameters as + read-only. +


PrevHomeNext
Python 2 vs. Python 3UpData Values
\ No newline at end of file diff --git a/doc/src/sgml/html/plpython-python23.html b/doc/src/sgml/html/plpython-python23.html new file mode 100644 index 000000000..b145dea41 --- /dev/null +++ b/doc/src/sgml/html/plpython-python23.html @@ -0,0 +1,351 @@ + +Python 2 vs. Python 3
PostgreSQL 9.2.2 Documentation
PrevUpChapter 42. PL/Python - Python Procedural LanguageNext

42.1. Python 2 vs. Python 3

PL/Python supports both the Python 2 and Python 3 language + variants. (The PostgreSQL installation instructions might contain + more precise information about the exact supported minor versions + of Python.) Because the Python 2 and Python 3 language variants + are incompatible in some important aspects, the following naming + and transitioning scheme is used by PL/Python to avoid mixing them: + +

  • The PostgreSQL language named plpython2u + implements PL/Python based on the Python 2 language variant. +

  • The PostgreSQL language named plpython3u + implements PL/Python based on the Python 3 language variant. +

  • The language named plpythonu implements + PL/Python based on the default Python language variant, which is + currently Python 2. (This default is independent of what any + local Python installations might consider to be + their "default", for example, + what /usr/bin/python might be.) The + default will probably be changed to Python 3 in a distant future + release of PostgreSQL, depending on the progress of the + migration to Python 3 in the Python community. +

+ + This scheme is analogous to the recommendations in PEP 394 regarding the + naming and transitioning of the python command. +

It depends on the build configuration or the installed packages + whether PL/Python for Python 2 or Python 3 or both are available. +

Tip: The built variant depends on which Python version was found during + the installation or which version was explicitly set using + the PYTHON environment variable; + see Section 15.4. To make both variants of + PL/Python available in one installation, the source tree has to be + configured and built twice. +

This results in the following usage and migration strategy: + +

  • Existing users and users who are currently not interested in + Python 3 use the language name plpythonu and + don't have to change anything for the foreseeable future. It is + recommended to gradually "future-proof" the code + via migration to Python 2.6/2.7 to simplify the eventual + migration to Python 3. +

    In practice, many PL/Python functions will migrate to Python 3 + with few or no changes. +

  • Users who know that they have heavily Python 2 dependent code + and don't plan to ever change it can make use of + the plpython2u language name. This will + continue to work into the very distant future, until Python 2 + support might be completely dropped by PostgreSQL. +

  • Users who want to dive into Python 3 can use + the plpython3u language name, which will keep + working forever by today's standards. In the distant future, + when Python 3 might become the default, they might like to + remove the "3" for aesthetic reasons. +

  • Daredevils, who want to build a Python-3-only operating system + environment, can change the contents of + pg_pltemplate + to make plpythonu be equivalent + to plpython3u, keeping in mind that this + would make their installation incompatible with most of the rest + of the world. +

+

See also the + document What's + New In Python 3.0 for more information about porting to + Python 3. +

It is not allowed to use PL/Python based on Python 2 and PL/Python + based on Python 3 in the same session, because the symbols in the + dynamic modules would clash, which could result in crashes of the + PostgreSQL server process. There is a check that prevents mixing + Python major versions in a session, which will abort the session if + a mismatch is detected. It is possible, however, to use both + PL/Python variants in the same database, from separate sessions. +


PrevHomeNext
PL/Python - Python Procedural LanguageUpPL/Python Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/plpython-sharing.html b/doc/src/sgml/html/plpython-sharing.html new file mode 100644 index 000000000..fd98cc828 --- /dev/null +++ b/doc/src/sgml/html/plpython-sharing.html @@ -0,0 +1,192 @@ + +Sharing Data
PostgreSQL 9.2.2 Documentation
PrevUpChapter 42. PL/Python - Python Procedural LanguageNext

42.4. Sharing Data

The global dictionary SD is available to store + data between function calls. This variable is private static data. + The global dictionary GD is public data, + available to all Python functions within a session. Use with + care. +

Each function gets its own execution environment in the + Python interpreter, so that global data and function arguments from + myfunc are not available to + myfunc2. The exception is the data in the + GD dictionary, as mentioned above. +


PrevHomeNext
Data ValuesUpAnonymous Code Blocks
\ No newline at end of file diff --git a/doc/src/sgml/html/plpython-subtransaction.html b/doc/src/sgml/html/plpython-subtransaction.html new file mode 100644 index 000000000..f6148f841 --- /dev/null +++ b/doc/src/sgml/html/plpython-subtransaction.html @@ -0,0 +1,354 @@ + +Explicit Subtransactions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 42. PL/Python - Python Procedural LanguageNext

42.8. Explicit Subtransactions

Recovering from errors caused by database access as described in + Section 42.7.2 can lead to an undesirable + situation where some operations succeed before one of them fails, + and after recovering from that error the data is left in an + inconsistent state. PL/Python offers a solution to this problem in + the form of explicit subtransactions. +

42.8.1. Subtransaction Context Managers

Consider a function that implements a transfer between two + accounts: +

CREATE FUNCTION transfer_funds() RETURNS void AS $$
+try:
+    plpy.execute("UPDATE accounts SET balance = balance - 100 WHERE account_name = 'joe'")
+    plpy.execute("UPDATE accounts SET balance = balance + 100 WHERE account_name = 'mary'")
+except plpy.SPIError, e:
+    result = "error transferring funds: %s" % e.args
+else:
+    result = "funds transferred correctly"
+plan = plpy.prepare("INSERT INTO operations (result) VALUES ($1)", ["text"])
+plpy.execute(plan, [result])
+$$ LANGUAGE plpythonu;

+ If the second UPDATE statement results in an + exception being raised, this function will report the error, but + the result of the first UPDATE will + nevertheless be committed. In other words, the funds will be + withdrawn from Joe's account, but will not be transferred to + Mary's account. +

To avoid such issues, you can wrap your + plpy.execute calls in an explicit + subtransaction. The plpy module provides a + helper object to manage explicit subtransactions that gets created + with the plpy.subtransaction() function. + Objects created by this function implement the + context manager interface. Using explicit subtransactions + we can rewrite our function as: +

CREATE FUNCTION transfer_funds2() RETURNS void AS $$
+try:
+    with plpy.subtransaction():
+        plpy.execute("UPDATE accounts SET balance = balance - 100 WHERE account_name = 'joe'")
+        plpy.execute("UPDATE accounts SET balance = balance + 100 WHERE account_name = 'mary'")
+except plpy.SPIError, e:
+    result = "error transferring funds: %s" % e.args
+else:
+    result = "funds transferred correctly"
+plan = plpy.prepare("INSERT INTO operations (result) VALUES ($1)", ["text"])
+plpy.execute(plan, [result])
+$$ LANGUAGE plpythonu;

+ Note that the use of try/catch is still + required. Otherwise the exception would propagate to the top of + the Python stack and would cause the whole function to abort with + a PostgreSQL error, so that the + operations table would not have any row + inserted into it. The subtransaction context manager does not + trap errors, it only assures that all database operations executed + inside its scope will be atomically committed or rolled back. A + rollback of the subtransaction block occurs on any kind of + exception exit, not only ones caused by errors originating from + database access. A regular Python exception raised inside an + explicit subtransaction block would also cause the subtransaction + to be rolled back. +

42.8.2. Older Python Versions

Context managers syntax using the with keyword + is available by default in Python 2.6. If using PL/Python with an + older Python version, it is still possible to use explicit + subtransactions, although not as transparently. You can call the + subtransaction manager's __enter__ and + __exit__ functions using the + enter and exit convenience + aliases. The example function that transfers funds could be + written as: +

CREATE FUNCTION transfer_funds_old() RETURNS void AS $$
+try:
+    subxact = plpy.subtransaction()
+    subxact.enter()
+    try:
+        plpy.execute("UPDATE accounts SET balance = balance - 100 WHERE account_name = 'joe'")
+        plpy.execute("UPDATE accounts SET balance = balance + 100 WHERE account_name = 'mary'")
+    except:
+        import sys
+        subxact.exit(*sys.exc_info())
+        raise
+    else:
+        subxact.exit(None, None, None)
+except plpy.SPIError, e:
+    result = "error transferring funds: %s" % e.args
+else:
+    result = "funds transferred correctly"
+
+plan = plpy.prepare("INSERT INTO operations (result) VALUES ($1)", ["text"])
+plpy.execute(plan, [result])
+$$ LANGUAGE plpythonu;

+

Note: Although context managers were implemented in Python 2.5, to use + the with syntax in that version you need to + use a future + statement. Because of implementation details, however, + you cannot use future statements in PL/Python functions. +


PrevHomeNext
Database AccessUpUtility Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/plpython-trigger.html b/doc/src/sgml/html/plpython-trigger.html new file mode 100644 index 000000000..040e856a2 --- /dev/null +++ b/doc/src/sgml/html/plpython-trigger.html @@ -0,0 +1,365 @@ + +Trigger Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 42. PL/Python - Python Procedural LanguageNext

42.6. Trigger Functions

When a function is used as a trigger, the dictionary + TD contains trigger-related values: +

TD["event"]

contains the event as a string: + INSERT, UPDATE, + DELETE, or TRUNCATE. +

TD["when"]

contains one of BEFORE, AFTER, or + INSTEAD OF. +

TD["level"]

contains ROW or STATEMENT. +

TD["new"]
TD["old"]

For a row-level trigger, one or both of these fields contain + the respective trigger rows, depending on the trigger event. +

TD["name"]

contains the trigger name. +

TD["table_name"]

contains the name of the table on which the trigger occurred. +

TD["table_schema"]

contains the schema of the table on which the trigger occurred. +

TD["relid"]

contains the OID of the table on which the trigger occurred. +

TD["args"]

If the CREATE TRIGGER command + included arguments, they are available in TD["args"][0] to + TD["args"][n-1]. +

+

If TD["when"] is BEFORE or + INSTEAD OF and + TD["level"] is ROW, you can + return None or "OK" from the + Python function to indicate the row is unmodified, + "SKIP" to abort the event, or if TD["event"] + is INSERT or UPDATE you can return + "MODIFY" to indicate you've modified the new row. + Otherwise the return value is ignored. +


PrevHomeNext
Anonymous Code BlocksUpDatabase Access
\ No newline at end of file diff --git a/doc/src/sgml/html/plpython-util.html b/doc/src/sgml/html/plpython-util.html new file mode 100644 index 000000000..9b40a31aa --- /dev/null +++ b/doc/src/sgml/html/plpython-util.html @@ -0,0 +1,330 @@ + +Utility Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 42. PL/Python - Python Procedural LanguageNext

42.9. Utility Functions

The plpy module also provides the functions + plpy.debug(msg), + plpy.log(msg), + plpy.info(msg), + plpy.notice(msg), + plpy.warning(msg), + plpy.error(msg), and + plpy.fatal(msg). + plpy.error and + plpy.fatal actually raise a Python exception + which, if uncaught, propagates out to the calling query, causing + the current transaction or subtransaction to be aborted. + raise plpy.Error(msg) and + raise plpy.Fatal(msg) are + equivalent to calling + plpy.error and + plpy.fatal, respectively. + The other functions only generate messages of different + priority levels. + Whether messages of a particular priority are reported to the client, + written to the server log, or both is controlled by the + log_min_messages and + client_min_messages configuration + variables. See Chapter 18 for more information. +

Another set of utility functions are + plpy.quote_literal(string), + plpy.quote_nullable(string), and + plpy.quote_ident(string). They + are equivalent to the built-in quoting functions described in Section 9.4. They are useful when constructing + ad-hoc queries. A PL/Python equivalent of dynamic SQL from Example 39-1 would be: +

plpy.execute("UPDATE tbl SET %s = %s WHERE key = %s" % (
+    plpy.quote_ident(colname),
+    plpy.quote_nullable(newvalue),
+    plpy.quote_literal(keyvalue)))

+


PrevHomeNext
Explicit SubtransactionsUpEnvironment Variables
\ No newline at end of file diff --git a/doc/src/sgml/html/plpython.html b/doc/src/sgml/html/plpython.html new file mode 100644 index 000000000..c8e827187 --- /dev/null +++ b/doc/src/sgml/html/plpython.html @@ -0,0 +1,370 @@ + +PL/Python - Python Procedural Language

Chapter 42. PL/Python - Python Procedural Language

The PL/Python procedural language allows + PostgreSQL functions to be written in the + Python language. +

To install PL/Python in a particular database, use + CREATE EXTENSION plpythonu, or from the shell command line use + createlang plpythonu dbname (but + see also Section 42.1). +

Tip: If a language is installed into template1, all subsequently + created databases will have the language installed automatically. +

As of PostgreSQL 7.4, PL/Python is only + available as an "untrusted" language, meaning it does not + offer any way of restricting what users can do in it. It has + therefore been renamed to plpythonu. The trusted + variant plpython might become available again in future, + if a new secure execution mechanism is developed in Python. The + writer of a function in untrusted PL/Python must take care that the + function cannot be used to do anything unwanted, since it will be + able to do anything that could be done by a user logged in as the + database administrator. Only superusers can create functions in + untrusted languages such as plpythonu. +

Note: Users of source packages must specially enable the build of + PL/Python during the installation process. (Refer to the + installation instructions for more information.) Users of binary + packages might find PL/Python in a separate subpackage. +


PrevHomeNext
PL/Perl Under the HoodUpPython 2 vs. Python 3
\ No newline at end of file diff --git a/doc/src/sgml/html/pltcl-data.html b/doc/src/sgml/html/pltcl-data.html new file mode 100644 index 000000000..ce79820b1 --- /dev/null +++ b/doc/src/sgml/html/pltcl-data.html @@ -0,0 +1,178 @@ + +Data Values in PL/Tcl
PostgreSQL 9.2.2 Documentation
PrevUpChapter 40. PL/Tcl - Tcl Procedural LanguageNext

40.3. Data Values in PL/Tcl

The argument values supplied to a PL/Tcl function's code are simply + the input arguments converted to text form (just as if they had been + displayed by a SELECT statement). Conversely, the + return + command will accept any string that is acceptable input format for + the function's declared return type. So, within the PL/Tcl function, + all values are just text strings. +


PrevHomeNext
PL/Tcl Functions and ArgumentsUpGlobal Data in PL/Tcl
\ No newline at end of file diff --git a/doc/src/sgml/html/pltcl-dbaccess.html b/doc/src/sgml/html/pltcl-dbaccess.html new file mode 100644 index 000000000..063f4b01e --- /dev/null +++ b/doc/src/sgml/html/pltcl-dbaccess.html @@ -0,0 +1,751 @@ + +Database Access from PL/Tcl
PostgreSQL 9.2.2 Documentation
PrevUpChapter 40. PL/Tcl - Tcl Procedural LanguageNext

40.5. Database Access from PL/Tcl

The following commands are available to access the database from + the body of a PL/Tcl function: + +

spi_exec ?-count n? ?-array name? command ?loop-body?

Executes an SQL command given as a string. An error in the command + causes an error to be raised. Otherwise, the return value of spi_exec + is the number of rows processed (selected, inserted, updated, or + deleted) by the command, or zero if the command is a utility + statement. In addition, if the command is a SELECT statement, the + values of the selected columns are placed in Tcl variables as + described below. +

The optional -count value tells + spi_exec the maximum number of rows + to process in the command. The effect of this is comparable to + setting up a query as a cursor and then saying FETCH n. +

If the command is a SELECT statement, the values of the + result columns are placed into Tcl variables named after the columns. + If the -array option is given, the column values are + instead stored into the named associative array, with the + column names used as array indexes. +

If the command is a SELECT statement and no loop-body + script is given, then only the first row of results are stored into + Tcl variables; remaining rows, if any, are ignored. No storing occurs + if the + query returns no rows. (This case can be detected by checking the + result of spi_exec.) For example: +

spi_exec "SELECT count(*) AS cnt FROM pg_proc"

+ + will set the Tcl variable $cnt to the number of rows in + the pg_proc system catalog. +

If the optional loop-body argument is given, it is + a piece of Tcl script that is executed once for each row in the + query result. (loop-body is ignored if the given + command is not a SELECT.) The values of the current row's columns + are stored into Tcl variables before each iteration. For example: + +

spi_exec -array C "SELECT * FROM pg_class" {
+    elog DEBUG "have table $C(relname)"
+}

+ + will print a log message for every row of pg_class. This + feature works similarly to other Tcl looping constructs; in + particular continue and break work in the + usual way inside the loop body. +

If a column of a query result is null, the target + variable for it is "unset" rather than being set. +

spi_prepare query typelist

Prepares and saves a query plan for later execution. The + saved plan will be retained for the life of the current + session. +

The query can use parameters, that is, placeholders for + values to be supplied whenever the plan is actually executed. + In the query string, refer to parameters + by the symbols $1 ... $n. + If the query uses parameters, the names of the parameter types + must be given as a Tcl list. (Write an empty list for + typelist if no parameters are used.) +

The return value from spi_prepare is a query ID + to be used in subsequent calls to spi_execp. See + spi_execp for an example. +

spi_execp ?-count n? ?-array name? ?-nulls string? queryid ?value-list? ?loop-body?

Executes a query previously prepared with spi_prepare. + queryid is the ID returned by + spi_prepare. If the query references parameters, + a value-list must be supplied. This + is a Tcl list of actual values for the parameters. The list must be + the same length as the parameter type list previously given to + spi_prepare. Omit value-list + if the query has no parameters. +

The optional value for -nulls is a string of spaces and + 'n' characters telling spi_execp + which of the parameters are null values. If given, it must have exactly the + same length as the value-list. If it + is not given, all the parameter values are nonnull. +

Except for the way in which the query and its parameters are specified, + spi_execp works just like spi_exec. + The -count, -array, and + loop-body options are the same, + and so is the result value. +

Here's an example of a PL/Tcl function using a prepared plan: + +

CREATE FUNCTION t1_count(integer, integer) RETURNS integer AS $$
+    if {![ info exists GD(plan) ]} {
+        # prepare the saved plan on the first call
+        set GD(plan) [ spi_prepare \
+                "SELECT count(*) AS cnt FROM t1 WHERE num >= \$1 AND num <= \$2" \
+                [ list int4 int4 ] ]
+    }
+    spi_execp -count 1 $GD(plan) [ list $1 $2 ]
+    return $cnt
+$$ LANGUAGE pltcl;

+ + We need backslashes inside the query string given to + spi_prepare to ensure that the + $n markers will be passed + through to spi_prepare as-is, and not replaced by Tcl + variable substitution. + +

spi_lastoid

Returns the OID of the row inserted by the last + spi_exec or spi_execp, if the + command was a single-row INSERT and the modified + table contained OIDs. (If not, you get zero.) +

quote string

Doubles all occurrences of single quote and backslash characters + in the given string. This can be used to safely quote strings + that are to be inserted into SQL commands given + to spi_exec or + spi_prepare. + For example, think about an SQL command string like: + +

"SELECT '$val' AS ret"

+ + where the Tcl variable val actually contains + doesn't. This would result + in the final command string: + +

SELECT 'doesn't' AS ret

+ + which would cause a parse error during + spi_exec or + spi_prepare. + To work properly, the submitted command should contain: + +

SELECT 'doesn''t' AS ret

+ + which can be formed in PL/Tcl using: + +

"SELECT '[ quote $val ]' AS ret"

+ + One advantage of spi_execp is that you don't + have to quote parameter values like this, since the parameters are never + parsed as part of an SQL command string. +

elog level msg

Emits a log or error message. Possible levels are + DEBUG, LOG, INFO, + NOTICE, WARNING, ERROR, and + FATAL. ERROR + raises an error condition; if this is not trapped by the surrounding + Tcl code, the error propagates out to the calling query, causing + the current transaction or subtransaction to be aborted. This + is effectively the same as the Tcl error command. + FATAL aborts the transaction and causes the current + session to shut down. (There is probably no good reason to use + this error level in PL/Tcl functions, but it's provided for + completeness.) The other levels only generate messages of different + priority levels. + Whether messages of a particular priority are reported to the client, + written to the server log, or both is controlled by the + log_min_messages and + client_min_messages configuration + variables. See Chapter 18 for more + information. +

+


PrevHomeNext
Global Data in PL/TclUpTrigger Procedures in PL/Tcl
\ No newline at end of file diff --git a/doc/src/sgml/html/pltcl-functions.html b/doc/src/sgml/html/pltcl-functions.html new file mode 100644 index 000000000..571fa87ce --- /dev/null +++ b/doc/src/sgml/html/pltcl-functions.html @@ -0,0 +1,334 @@ + +PL/Tcl Functions and Arguments
PostgreSQL 9.2.2 Documentation
PrevUpChapter 40. PL/Tcl - Tcl Procedural LanguageNext

40.2. PL/Tcl Functions and Arguments

To create a function in the PL/Tcl language, use + the standard CREATE FUNCTION syntax: + +

CREATE FUNCTION funcname (argument-types) RETURNS return-type AS $$
+    # PL/Tcl function body
+$$ LANGUAGE pltcl;

+ + PL/TclU is the same, except that the language has to be specified as + pltclu. +

The body of the function is simply a piece of Tcl script. + When the function is called, the argument values are passed as + variables $1 ... $n to the + Tcl script. The result is returned + from the Tcl code in the usual way, with a return + statement. +

For example, a function + returning the greater of two integer values could be defined as: + +

CREATE FUNCTION tcl_max(integer, integer) RETURNS integer AS $$
+    if {$1 > $2} {return $1}
+    return $2
+$$ LANGUAGE pltcl STRICT;

+ + Note the clause STRICT, which saves us from + having to think about null input values: if a null value is passed, the + function will not be called at all, but will just return a null + result automatically. +

In a nonstrict function, + if the actual value of an argument is null, the corresponding + $n variable will be set to an empty string. + To detect whether a particular argument is null, use the function + argisnull. For example, suppose that we wanted tcl_max + with one null and one nonnull argument to return the nonnull + argument, rather than null: + +

CREATE FUNCTION tcl_max(integer, integer) RETURNS integer AS $$
+    if {[argisnull 1]} {
+        if {[argisnull 2]} { return_null }
+        return $2
+    }
+    if {[argisnull 2]} { return $1 }
+    if {$1 > $2} {return $1}
+    return $2
+$$ LANGUAGE pltcl;

+

As shown above, + to return a null value from a PL/Tcl function, execute + return_null. This can be done whether the + function is strict or not. +

Composite-type arguments are passed to the function as Tcl + arrays. The element names of the array are the attribute names + of the composite type. If an attribute in the passed row has the + null value, it will not appear in the array. Here is an example: + +

CREATE TABLE employee (
+    name text,
+    salary integer,
+    age integer
+);
+
+CREATE FUNCTION overpaid(employee) RETURNS boolean AS $$
+    if {200000.0 < $1(salary)} {
+        return "t"
+    }
+    if {$1(age) < 30 && 100000.0 < $1(salary)} {
+        return "t"
+    }
+    return "f"
+$$ LANGUAGE pltcl;

+

There is currently no support for returning a composite-type + result value, nor for returning sets. +

PL/Tcl does not currently have full support for + domain types: it treats a domain the same as the underlying scalar + type. This means that constraints associated with the domain will + not be enforced. This is not an issue for function arguments, but + it is a hazard if you declare a PL/Tcl function + as returning a domain type. +


PrevHomeNext
OverviewUpData Values in PL/Tcl
\ No newline at end of file diff --git a/doc/src/sgml/html/pltcl-global.html b/doc/src/sgml/html/pltcl-global.html new file mode 100644 index 000000000..470e799ee --- /dev/null +++ b/doc/src/sgml/html/pltcl-global.html @@ -0,0 +1,241 @@ + +Global Data in PL/Tcl
PostgreSQL 9.2.2 Documentation
PrevUpChapter 40. PL/Tcl - Tcl Procedural LanguageNext

40.4. Global Data in PL/Tcl

Sometimes it + is useful to have some global data that is held between two + calls to a function or is shared between different functions. + This is easily done in PL/Tcl, but there are some restrictions that + must be understood. +

For security reasons, PL/Tcl executes functions called by any one SQL + role in a separate Tcl interpreter for that role. This prevents + accidental or malicious interference by one user with the behavior of + another user's PL/Tcl functions. Each such interpreter will have its own + values for any "global" Tcl variables. Thus, two PL/Tcl + functions will share the same global variables if and only if they are + executed by the same SQL role. In an application wherein a single + session executes code under multiple SQL roles (via SECURITY + DEFINER functions, use of SET ROLE, etc) you may need to + take explicit steps to ensure that PL/Tcl functions can share data. To + do that, make sure that functions that should communicate are owned by + the same user, and mark them SECURITY DEFINER. You must of + course take care that such functions can't be used to do anything + unintended. +

All PL/TclU functions used in a session execute in the same Tcl + interpreter, which of course is distinct from the interpreter(s) + used for PL/Tcl functions. So global data is automatically shared + between PL/TclU functions. This is not considered a security risk + because all PL/TclU functions execute at the same trust level, + namely that of a database superuser. +

To help protect PL/Tcl functions from unintentionally interfering + with each other, a global + array is made available to each function via the upvar + command. The global name of this variable is the function's internal + name, and the local name is GD. It is recommended that + GD be used + for persistent private data of a function. Use regular Tcl global + variables only for values that you specifically intend to be shared among + multiple functions. (Note that the GD arrays are only + global within a particular interpreter, so they do not bypass the + security restrictions mentioned above.) +

An example of using GD appears in the + spi_execp example below. +


PrevHomeNext
Data Values in PL/TclUpDatabase Access from PL/Tcl
\ No newline at end of file diff --git a/doc/src/sgml/html/pltcl-overview.html b/doc/src/sgml/html/pltcl-overview.html new file mode 100644 index 000000000..9ca4d5bbf --- /dev/null +++ b/doc/src/sgml/html/pltcl-overview.html @@ -0,0 +1,277 @@ + +Overview
PostgreSQL 9.2.2 Documentation
PrevUpChapter 40. PL/Tcl - Tcl Procedural LanguageNext

40.1. Overview

PL/Tcl offers most of the capabilities a function writer has in + the C language, with a few restrictions, and with the addition of + the powerful string processing libraries that are available for + Tcl. +

One compelling good restriction is that + everything is executed from within the safety of the context of a + Tcl interpreter. In addition to the limited command set of safe + Tcl, only a few commands are available to access the database via + SPI and to raise messages via elog(). PL/Tcl + provides no way to access internals of the database server or to + gain OS-level access under the permissions of the + PostgreSQL server process, as a C + function can do. Thus, unprivileged database users can be trusted + to use this language; it does not give them unlimited authority. +

The other notable implementation restriction is that Tcl functions + cannot be used to create input/output functions for new data + types. +

Sometimes it is desirable to write Tcl functions that are not restricted + to safe Tcl. For example, one might want a Tcl function that sends + email. To handle these cases, there is a variant of PL/Tcl called PL/TclU + (for untrusted Tcl). This is the exact same language except that a full + Tcl interpreter is used. If PL/TclU is used, it must be + installed as an untrusted procedural language so that only + database superusers can create functions in it. The writer of a PL/TclU + function must take care that the function cannot be used to do anything + unwanted, since it will be able to do anything that could be done by + a user logged in as the database administrator. +

The shared object code for the PL/Tcl and + PL/TclU call handlers is automatically built and + installed in the PostgreSQL library + directory if Tcl support is specified in the configuration step of + the installation procedure. To install PL/Tcl + and/or PL/TclU in a particular database, use the + CREATE EXTENSION command or the + createlang program, for example + createlang pltcl dbname or + createlang pltclu dbname. +


PrevHomeNext
PL/Tcl - Tcl Procedural LanguageUpPL/Tcl Functions and Arguments
\ No newline at end of file diff --git a/doc/src/sgml/html/pltcl-procnames.html b/doc/src/sgml/html/pltcl-procnames.html new file mode 100644 index 000000000..1f4b4a667 --- /dev/null +++ b/doc/src/sgml/html/pltcl-procnames.html @@ -0,0 +1,187 @@ + +Tcl Procedure Names
PostgreSQL 9.2.2 Documentation
PrevUpChapter 40. PL/Tcl - Tcl Procedural LanguageNext

40.8. Tcl Procedure Names

In PostgreSQL, the same function name can be used for + different function definitions as long as the number of arguments or their types + differ. Tcl, however, requires all procedure names to be distinct. + PL/Tcl deals with this by making the internal Tcl procedure names contain + the object + ID of the function from the system table pg_proc as part of their name. Thus, + PostgreSQL functions with the same name + and different argument types will be different Tcl procedures, too. This + is not normally a concern for a PL/Tcl programmer, but it might be visible + when debugging. +


PrevHomeNext
Modules and the unknown CommandUpPL/Perl - Perl Procedural Language
\ No newline at end of file diff --git a/doc/src/sgml/html/pltcl-trigger.html b/doc/src/sgml/html/pltcl-trigger.html new file mode 100644 index 000000000..13d215362 --- /dev/null +++ b/doc/src/sgml/html/pltcl-trigger.html @@ -0,0 +1,497 @@ + +Trigger Procedures in PL/Tcl
PostgreSQL 9.2.2 Documentation
PrevUpChapter 40. PL/Tcl - Tcl Procedural LanguageNext

40.6. Trigger Procedures in PL/Tcl

Trigger procedures can be written in PL/Tcl. + PostgreSQL requires that a procedure that is to be called + as a trigger must be declared as a function with no arguments + and a return type of trigger. +

The information from the trigger manager is passed to the procedure body + in the following variables: + +

$TG_name

The name of the trigger from the CREATE TRIGGER statement. +

$TG_relid

The object ID of the table that caused the trigger procedure + to be invoked. +

$TG_table_name

The name of the table that caused the trigger procedure + to be invoked. +

$TG_table_schema

The schema of the table that caused the trigger procedure + to be invoked. +

$TG_relatts

A Tcl list of the table column names, prefixed with an empty list + element. So looking up a column name in the list with Tcl's + lsearch command returns the element's number starting + with 1 for the first column, the same way the columns are customarily + numbered in PostgreSQL. (Empty list + elements also appear in the positions of columns that have been + dropped, so that the attribute numbering is correct for columns + to their right.) +

$TG_when

The string BEFORE, AFTER, or + INSTEAD OF, depending on the type of trigger event. +

$TG_level

The string ROW or STATEMENT depending on the + type of trigger event. +

$TG_op

The string INSERT, UPDATE, + DELETE, or TRUNCATE depending on the type of + trigger event. +

$NEW

An associative array containing the values of the new table + row for INSERT or UPDATE actions, or + empty for DELETE. The array is indexed by column + name. Columns that are null will not appear in the array. + This is not set for statement-level triggers. +

$OLD

An associative array containing the values of the old table + row for UPDATE or DELETE actions, or + empty for INSERT. The array is indexed by column + name. Columns that are null will not appear in the array. + This is not set for statement-level triggers. +

$args

A Tcl list of the arguments to the procedure as given in the + CREATE TRIGGER statement. These arguments are also accessible as + $1 ... $n in the procedure body. +

+

The return value from a trigger procedure can be one of the strings + OK or SKIP, or a list as returned by the + array get Tcl command. If the return value is OK, + the operation (INSERT/UPDATE/DELETE) that fired the trigger will proceed + normally. SKIP tells the trigger manager to silently suppress + the operation for this row. If a list is returned, it tells PL/Tcl to + return a modified row to the trigger manager. This is only meaningful + for row-level BEFORE INSERT or UPDATE + triggers for which the modified row will be inserted instead of the one + given in $NEW; or for row-level INSTEAD OF + INSERT or UPDATE triggers where the returned row + is used to support INSERT RETURNING and + UPDATE RETURNING commands. The return value is ignored for + other types of triggers. +

Here's a little example trigger procedure that forces an integer value + in a table to keep track of the number of updates that are performed on the + row. For new rows inserted, the value is initialized to 0 and then + incremented on every update operation. + +

CREATE FUNCTION trigfunc_modcount() RETURNS trigger AS $$
+    switch $TG_op {
+        INSERT {
+            set NEW($1) 0
+        }
+        UPDATE {
+            set NEW($1) $OLD($1)
+            incr NEW($1)
+        }
+        default {
+            return OK
+        }
+    }
+    return [array get NEW]
+$$ LANGUAGE pltcl;
+
+CREATE TABLE mytab (num integer, description text, modcnt integer);
+
+CREATE TRIGGER trig_mytab_modcount BEFORE INSERT OR UPDATE ON mytab
+    FOR EACH ROW EXECUTE PROCEDURE trigfunc_modcount('modcnt');

+ + Notice that the trigger procedure itself does not know the column + name; that's supplied from the trigger arguments. This lets the + trigger procedure be reused with different tables. +


PrevHomeNext
Database Access from PL/TclUpModules and the unknown Command
\ No newline at end of file diff --git a/doc/src/sgml/html/pltcl-unknown.html b/doc/src/sgml/html/pltcl-unknown.html new file mode 100644 index 000000000..afcc3ba95 --- /dev/null +++ b/doc/src/sgml/html/pltcl-unknown.html @@ -0,0 +1,261 @@ + +Modules and the unknown Command
PostgreSQL 9.2.2 Documentation
PrevUpChapter 40. PL/Tcl - Tcl Procedural LanguageNext

40.7. Modules and the unknown Command

PL/Tcl has support for autoloading Tcl code when used. + It recognizes a special table, pltcl_modules, which + is presumed to contain modules of Tcl code. If this table + exists, the module unknown is fetched from the table + and loaded into the Tcl interpreter immediately before the first + execution of a PL/Tcl function in a database session. (This + happens separately for each Tcl interpreter, if more than one is + used in a session; see Section 40.4.) +

While the unknown module could actually contain any + initialization script you need, it normally defines a Tcl + unknown procedure that is invoked whenever Tcl does + not recognize an invoked procedure name. PL/Tcl's standard version + of this procedure tries to find a module in pltcl_modules + that will define the required procedure. If one is found, it is + loaded into the interpreter, and then execution is allowed to + proceed with the originally attempted procedure call. A + secondary table pltcl_modfuncs provides an index of + which functions are defined by which modules, so that the lookup + is reasonably quick. +

The PostgreSQL distribution includes + support scripts to maintain these tables: + pltcl_loadmod, pltcl_listmod, + pltcl_delmod, as well as source for the standard + unknown module in share/unknown.pltcl. This module + must be loaded + into each database initially to support the autoloading mechanism. +

The tables pltcl_modules and pltcl_modfuncs + must be readable by all, but it is wise to make them owned and + writable only by the database administrator. As a security + precaution, PL/Tcl will ignore pltcl_modules (and thus, + not attempt to load the unknown module) unless it is + owned by a superuser. But update privileges on this table can be + granted to other users, if you trust them sufficiently. +


PrevHomeNext
Trigger Procedures in PL/TclUpTcl Procedure Names
\ No newline at end of file diff --git a/doc/src/sgml/html/pltcl.html b/doc/src/sgml/html/pltcl.html new file mode 100644 index 000000000..49cfa1b14 --- /dev/null +++ b/doc/src/sgml/html/pltcl.html @@ -0,0 +1,230 @@ + +PL/Tcl - Tcl Procedural Language

Chapter 40. PL/Tcl - Tcl Procedural Language

PL/Tcl is a loadable procedural language for the + PostgreSQL database system + that enables the Tcl language to be used to write functions and + trigger procedures. +


PrevHomeNext
Porting from Oracle PL/SQLUpOverview
\ No newline at end of file diff --git a/doc/src/sgml/html/populate.html b/doc/src/sgml/html/populate.html new file mode 100644 index 000000000..44e21d962 --- /dev/null +++ b/doc/src/sgml/html/populate.html @@ -0,0 +1,825 @@ + +Populating a Database
PostgreSQL 9.2.2 Documentation
PrevUpChapter 14. Performance TipsNext

14.4. Populating a Database

One might need to insert a large amount of data when first populating + a database. This section contains some suggestions on how to make + this process as efficient as possible. +

14.4.1. Disable Autocommit

When using multiple INSERTs, turn off autocommit and just do + one commit at the end. (In plain + SQL, this means issuing BEGIN at the start and + COMMIT at the end. Some client libraries might + do this behind your back, in which case you need to make sure the + library does it when you want it done.) If you allow each + insertion to be committed separately, + PostgreSQL is doing a lot of work for + each row that is added. An additional benefit of doing all + insertions in one transaction is that if the insertion of one row + were to fail then the insertion of all rows inserted up to that + point would be rolled back, so you won't be stuck with partially + loaded data. +

14.4.2. Use COPY

Use COPY to load + all the rows in one command, instead of using a series of + INSERT commands. The COPY + command is optimized for loading large numbers of rows; it is less + flexible than INSERT, but incurs significantly + less overhead for large data loads. Since COPY + is a single command, there is no need to disable autocommit if you + use this method to populate a table. +

If you cannot use COPY, it might help to use PREPARE to create a + prepared INSERT statement, and then use + EXECUTE as many times as required. This avoids + some of the overhead of repeatedly parsing and planning + INSERT. Different interfaces provide this facility + in different ways; look for "prepared statements" in the interface + documentation. +

Note that loading a large number of rows using + COPY is almost always faster than using + INSERT, even if PREPARE is used and + multiple insertions are batched into a single transaction. +

COPY is fastest when used within the same + transaction as an earlier CREATE TABLE or + TRUNCATE command. In such cases no WAL + needs to be written, because in case of an error, the files + containing the newly loaded data will be removed anyway. + However, this consideration only applies when + wal_level is minimal as all commands + must write WAL otherwise. +

14.4.3. Remove Indexes

If you are loading a freshly created table, the fastest method is to + create the table, bulk load the table's data using + COPY, then create any indexes needed for the + table. Creating an index on pre-existing data is quicker than + updating it incrementally as each row is loaded. +

If you are adding large amounts of data to an existing table, + it might be a win to drop the indexes, + load the table, and then recreate the indexes. Of course, the + database performance for other users might suffer + during the time the indexes are missing. One should also think + twice before dropping a unique index, since the error checking + afforded by the unique constraint will be lost while the index is + missing. +

14.4.4. Remove Foreign Key Constraints

Just as with indexes, a foreign key constraint can be checked + "in bulk" more efficiently than row-by-row. So it might be + useful to drop foreign key constraints, load data, and re-create + the constraints. Again, there is a trade-off between data load + speed and loss of error checking while the constraint is missing. +

What's more, when you load data into a table with existing foreign key + constraints, each new row requires an entry in the server's list of + pending trigger events (since it is the firing of a trigger that checks + the row's foreign key constraint). Loading many millions of rows can + cause the trigger event queue to overflow available memory, leading to + intolerable swapping or even outright failure of the command. Therefore + it may be necessary, not just desirable, to drop and re-apply + foreign keys when loading large amounts of data. If temporarily removing + the constraint isn't acceptable, the only other recourse may be to split + up the load operation into smaller transactions. +

14.4.5. Increase maintenance_work_mem

Temporarily increasing the maintenance_work_mem + configuration variable when loading large amounts of data can + lead to improved performance. This will help to speed up CREATE + INDEX commands and ALTER TABLE ADD FOREIGN KEY commands. + It won't do much for COPY itself, so this advice is + only useful when you are using one or both of the above techniques. +

14.4.6. Increase checkpoint_segments

Temporarily increasing the checkpoint_segments configuration variable can also + make large data loads faster. This is because loading a large + amount of data into PostgreSQL will + cause checkpoints to occur more often than the normal checkpoint + frequency (specified by the checkpoint_timeout + configuration variable). Whenever a checkpoint occurs, all dirty + pages must be flushed to disk. By increasing + checkpoint_segments temporarily during bulk + data loads, the number of checkpoints that are required can be + reduced. +

14.4.7. Disable WAL Archival and Streaming Replication

When loading large amounts of data into an installation that uses + WAL archiving or streaming replication, it might be faster to take a + new base backup after the load has completed than to process a large + amount of incremental WAL data. To prevent incremental WAL logging + while loading, disable archiving and streaming replication, by setting + wal_level to minimal, + archive_mode to off, and + max_wal_senders to zero. + But note that changing these settings requires a server restart. +

Aside from avoiding the time for the archiver or WAL sender to + process the WAL data, + doing this will actually make certain commands faster, because they + are designed not to write WAL at all if wal_level + is minimal. (They can guarantee crash safety more cheaply + by doing an fsync at the end than by writing WAL.) + This applies to the following commands: +

  • CREATE TABLE AS SELECT +

  • CREATE INDEX (and variants such as + ALTER TABLE ADD PRIMARY KEY) +

  • ALTER TABLE SET TABLESPACE +

  • CLUSTER +

  • COPY FROM, when the target table has been + created or truncated earlier in the same transaction +

+

14.4.8. Run ANALYZE Afterwards

Whenever you have significantly altered the distribution of data + within a table, running ANALYZE is strongly recommended. This + includes bulk loading large amounts of data into the table. Running + ANALYZE (or VACUUM ANALYZE) + ensures that the planner has up-to-date statistics about the + table. With no statistics or obsolete statistics, the planner might + make poor decisions during query planning, leading to poor + performance on any tables with inaccurate or nonexistent + statistics. Note that if the autovacuum daemon is enabled, it might + run ANALYZE automatically; see + Section 23.1.3 + and Section 23.1.6 for more information. +

14.4.9. Some Notes About pg_dump

Dump scripts generated by pg_dump automatically apply + several, but not all, of the above guidelines. To reload a + pg_dump dump as quickly as possible, you need to + do a few extra things manually. (Note that these points apply while + restoring a dump, not while creating it. + The same points apply whether loading a text dump with + psql or using pg_restore to load + from a pg_dump archive file.) +

By default, pg_dump uses COPY, and when + it is generating a complete schema-and-data dump, it is careful to + load data before creating indexes and foreign keys. So in this case + several guidelines are handled automatically. What is left + for you to do is to: +

  • Set appropriate (i.e., larger than normal) values for + maintenance_work_mem and + checkpoint_segments. +

  • If using WAL archiving or streaming replication, consider disabling + them during the restore. To do that, set archive_mode + to off, + wal_level to minimal, and + max_wal_senders to zero before loading the dump. + Afterwards, set them back to the right values and take a fresh + base backup. +

  • Consider whether the whole dump should be restored as a single + transaction. To do that, pass the -1 or + --single-transaction command-line option to + psql or pg_restore. When using this + mode, even the smallest of errors will rollback the entire restore, + possibly discarding many hours of processing. Depending on how + interrelated the data is, that might seem preferable to manual cleanup, + or not. COPY commands will run fastest if you use a single + transaction and have WAL archiving turned off. +

  • If multiple CPUs are available in the database server, consider using + pg_restore's --jobs option. This + allows concurrent data loading and index creation. +

  • Run ANALYZE afterwards. +

+

A data-only dump will still use COPY, but it does not + drop or recreate indexes, and it does not normally touch foreign + keys. + + [1] + + So when loading a data-only dump, it is up to you to drop and recreate + indexes and foreign keys if you wish to use those techniques. + It's still useful to increase checkpoint_segments + while loading the data, but don't bother increasing + maintenance_work_mem; rather, you'd do that while + manually recreating indexes and foreign keys afterwards. + And don't forget to ANALYZE when you're done; see + Section 23.1.3 + and Section 23.1.6 for more information. +

Notes

[1]

You can get the effect of disabling foreign keys by using + the --disable-triggers option — but realize that + that eliminates, rather than just postpones, foreign key + validation, and so it is possible to insert bad data if you use it. +


PrevHomeNext
Controlling the Planner with Explicit JOIN ClausesUpNon-Durable Settings
\ No newline at end of file diff --git a/doc/src/sgml/html/postgres-user.html b/doc/src/sgml/html/postgres-user.html new file mode 100644 index 000000000..778606e17 --- /dev/null +++ b/doc/src/sgml/html/postgres-user.html @@ -0,0 +1,197 @@ + +The PostgreSQL User Account
PostgreSQL 9.2.2 Documentation
PrevUpChapter 17. Server Setup and OperationNext

17.1. The PostgreSQL User Account

As with any server daemon that is accessible to the outside world, + it is advisable to run PostgreSQL under a + separate user account. This user account should only own the data + that is managed by the server, and should not be shared with other + daemons. (For example, using the user nobody is a bad + idea.) It is not advisable to install executables owned by this + user because compromised systems could then modify their own + binaries. +

To add a Unix user account to your system, look for a command + useradd or adduser. The user + name postgres is often used, and is assumed + throughout this book, but you can use another name if you like. +


PrevHomeNext
Server Setup and OperationUpCreating a Database Cluster
\ No newline at end of file diff --git a/doc/src/sgml/html/preface.html b/doc/src/sgml/html/preface.html new file mode 100644 index 000000000..84db6e828 --- /dev/null +++ b/doc/src/sgml/html/preface.html @@ -0,0 +1,324 @@ + +Preface

Preface

This book is the official documentation of + PostgreSQL. It has been written by the + PostgreSQL developers and other + volunteers in parallel to the development of the + PostgreSQL software. It describes all + the functionality that the current version of + PostgreSQL officially supports. +

To make the large amount of information about + PostgreSQL manageable, this book has been + organized in several parts. Each part is targeted at a different + class of users, or at users in different stages of their + PostgreSQL experience: + +

  • Part I is an informal introduction for new users. +

  • Part II documents the SQL query + language environment, including data types and functions, as well + as user-level performance tuning. Every + PostgreSQL user should read this. +

  • Part III describes the installation and + administration of the server. Everyone who runs a + PostgreSQL server, be it for private + use or for others, should read this part. +

  • Part IV describes the programming + interfaces for PostgreSQL client + programs. +

  • Part V contains information for + advanced users about the extensibility capabilities of the + server. Topics include user-defined data types and + functions. +

  • Part VI contains reference information about + SQL commands, client and server programs. This part supports + the other parts with structured information sorted by command or + program. +

  • Part VII contains assorted information that might be of + use to PostgreSQL developers. +

+


PrevHomeNext
PostgreSQL 9.2.2 Documentation What is PostgreSQL?
\ No newline at end of file diff --git a/doc/src/sgml/html/preventing-server-spoofing.html b/doc/src/sgml/html/preventing-server-spoofing.html new file mode 100644 index 000000000..166c6ba13 --- /dev/null +++ b/doc/src/sgml/html/preventing-server-spoofing.html @@ -0,0 +1,234 @@ + +Preventing Server Spoofing
PostgreSQL 9.2.2 Documentation
PrevUpChapter 17. Server Setup and OperationNext

17.7. Preventing Server Spoofing

While the server is running, it is not possible for a malicious user + to take the place of the normal database server. However, when the + server is down, it is possible for a local user to spoof the normal + server by starting their own server. The spoof server could read + passwords and queries sent by clients, but could not return any data + because the PGDATA directory would still be secure because + of directory permissions. Spoofing is possible because any user can + start a database server; a client cannot identify an invalid server + unless it is specially configured. +

The simplest way to prevent spoofing for local + connections is to use a Unix domain socket directory (unix_socket_directory) that has write permission only + for a trusted local user. This prevents a malicious user from creating + their own socket file in that directory. If you are concerned that + some applications might still reference /tmp for the + socket file and hence be vulnerable to spoofing, during operating system + startup create a symbolic link /tmp/.s.PGSQL.5432 that points + to the relocated socket file. You also might need to modify your + /tmp cleanup script to prevent removal of the symbolic link. +

To prevent spoofing on TCP connections, the best solution is to use + SSL certificates and make sure that clients check the server's certificate. + To do that, the server + must be configured to accept only hostssl connections (Section 19.1) and have SSL key and certificate files + (Section 17.9). The TCP client must connect using + sslmode=verify-ca or + verify-full and have the appropriate root certificate + file installed (Section 31.1). +


PrevHomeNext
Upgrading a PostgreSQL ClusterUpEncryption Options
\ No newline at end of file diff --git a/doc/src/sgml/html/protocol-changes.html b/doc/src/sgml/html/protocol-changes.html new file mode 100644 index 000000000..5e99bbaa9 --- /dev/null +++ b/doc/src/sgml/html/protocol-changes.html @@ -0,0 +1,294 @@ + +Summary of Changes since Protocol 2.0
PostgreSQL 9.2.2 Documentation
PrevUpChapter 46. Frontend/Backend ProtocolNext

46.7. Summary of Changes since Protocol 2.0

This section provides a quick checklist of changes, for the benefit of +developers trying to update existing client libraries to protocol 3.0.

The initial startup packet uses a flexible list-of-strings format +instead of a fixed format. Notice that session default values for run-time +parameters can now be specified directly in the startup packet. (Actually, +you could do that before using the options field, but given the +limited width of options and the lack of any way to quote +whitespace in the values, it wasn't a very safe technique.)

All messages now have a length count immediately following the message type +byte (except for startup packets, which have no type byte). Also note that +PasswordMessage now has a type byte.

ErrorResponse and NoticeResponse ('E' and 'N') +messages now contain multiple fields, from which the client code can +assemble an error message of the desired level of verbosity. Note that +individual fields will typically not end with a newline, whereas the single +string sent in the older protocol always did.

The ReadyForQuery ('Z') message includes a transaction status +indicator.

The distinction between BinaryRow and DataRow message types is gone; the +single DataRow message type serves for returning data in all formats. +Note that the layout of DataRow has changed to make it easier to parse. +Also, the representation of binary values has changed: it is no longer +directly tied to the server's internal representation.

There is a new "extended query" sub-protocol, which adds the frontend +message types Parse, Bind, Execute, Describe, Close, Flush, and Sync, and the +backend message types ParseComplete, BindComplete, PortalSuspended, +ParameterDescription, NoData, and CloseComplete. Existing clients do not +have to concern themselves with this sub-protocol, but making use of it +might allow improvements in performance or functionality.

COPY data is now encapsulated into CopyData and CopyDone messages. There +is a well-defined way to recover from errors during COPY. The special +"\." last line is not needed anymore, and is not sent +during COPY OUT. +(It is still recognized as a terminator during COPY IN, but its use is +deprecated and will eventually be removed.) Binary COPY is supported. +The CopyInResponse and CopyOutResponse messages include fields indicating +the number of columns and the format of each column.

The layout of FunctionCall and FunctionCallResponse messages has changed. +FunctionCall can now support passing NULL arguments to functions. It also +can handle passing parameters and retrieving results in either text or +binary format. There is no longer any reason to consider FunctionCall a +potential security hole, since it does not offer direct access to internal +server data representations.

The backend sends ParameterStatus ('S') messages during connection +startup for all parameters it considers interesting to the client library. +Subsequently, a ParameterStatus message is sent whenever the active value +changes for any of these parameters.

The RowDescription ('T') message carries new table OID and column +number fields for each column of the described row. It also shows the format +code for each column.

The CursorResponse ('P') message is no longer generated by +the backend.

The NotificationResponse ('A') message has an additional string +field, which can carry a "payload" string passed +from the NOTIFY event sender.

The EmptyQueryResponse ('I') message used to include an empty +string parameter; this has been removed.


PrevHomeNext
Error and Notice Message FieldsUpPostgreSQL Coding Conventions
\ No newline at end of file diff --git a/doc/src/sgml/html/protocol-error-fields.html b/doc/src/sgml/html/protocol-error-fields.html new file mode 100644 index 000000000..8039a5357 --- /dev/null +++ b/doc/src/sgml/html/protocol-error-fields.html @@ -0,0 +1,344 @@ + +Error and Notice Message Fields
PostgreSQL 9.2.2 Documentation
PrevUpChapter 46. Frontend/Backend ProtocolNext

46.6. Error and Notice Message Fields

This section describes the fields that can appear in ErrorResponse and +NoticeResponse messages. Each field type has a single-byte identification +token. Note that any given field type should appear at most once per +message.

S

Severity: the field contents are + ERROR, FATAL, or + PANIC (in an error message), or + WARNING, NOTICE, DEBUG, + INFO, or LOG (in a notice message), + or a localized translation of one of these. Always present.

C

Code: the SQLSTATE code for the error (see Appendix A). Not localizable. Always present.

M

Message: the primary human-readable error message. + This should be accurate but terse (typically one line). + Always present.

D

Detail: an optional secondary error message carrying more + detail about the problem. Might run to multiple lines.

H

Hint: an optional suggestion what to do about the problem. + This is intended to differ from Detail in that it offers advice + (potentially inappropriate) rather than hard facts. + Might run to multiple lines.

P

Position: the field value is a decimal ASCII integer, indicating + an error cursor position as an index into the original query string. + The first character has index 1, and positions are measured in + characters not bytes.

p

Internal position: this is defined the same as the P + field, but it is used when the cursor position refers to an internally + generated command rather than the one submitted by the client. + The q field will always appear when this field appears.

q

Internal query: the text of a failed internally-generated command. + This could be, for example, a SQL query issued by a PL/pgSQL function.

W

Where: an indication of the context in which the error occurred. + Presently this includes a call stack traceback of active + procedural language functions and internally-generated queries. + The trace is one entry per line, most recent first.

F

File: the file name of the source-code location where the error + was reported.

L

Line: the line number of the source-code location where the error + was reported.

R

Routine: the name of the source-code routine reporting the error.

The client is responsible for formatting displayed information to meet its +needs; in particular it should break long lines as needed. Newline characters +appearing in the error message fields should be treated as paragraph breaks, +not line breaks.


PrevHomeNext
Message FormatsUpSummary of Changes since Protocol 2.0
\ No newline at end of file diff --git a/doc/src/sgml/html/protocol-flow.html b/doc/src/sgml/html/protocol-flow.html new file mode 100644 index 000000000..6b2bd0627 --- /dev/null +++ b/doc/src/sgml/html/protocol-flow.html @@ -0,0 +1,1571 @@ + +Message Flow
PostgreSQL 9.2.2 Documentation
PrevUpChapter 46. Frontend/Backend ProtocolNext

46.2. Message Flow

This section describes the message flow and the semantics of each + message type. (Details of the exact representation of each message + appear in Section 46.5.) There are + several different sub-protocols depending on the state of the + connection: start-up, query, function call, + COPY, and termination. There are also special + provisions for asynchronous operations (including notification + responses and command cancellation), which can occur at any time + after the start-up phase. +

46.2.1. Start-up

To begin a session, a frontend opens a connection to the server and sends + a startup message. This message includes the names of the user and of the + database the user wants to connect to; it also identifies the particular + protocol version to be used. (Optionally, the startup message can include + additional settings for run-time parameters.) + The server then uses this information and + the contents of its configuration files (such as + pg_hba.conf) to determine + whether the connection is provisionally acceptable, and what additional + authentication is required (if any). +

The server then sends an appropriate authentication request message, + to which the frontend must reply with an appropriate authentication + response message (such as a password). + For all authentication methods except GSSAPI and SSPI, there is at most + one request and one response. In some methods, no response + at all is needed from the frontend, and so no authentication request + occurs. For GSSAPI and SSPI, multiple exchanges of packets may be needed + to complete the authentication. +

The authentication cycle ends with the server either rejecting the + connection attempt (ErrorResponse), or sending AuthenticationOk. +

The possible messages from the server in this phase are: + +

ErrorResponse

The connection attempt has been rejected. + The server then immediately closes the connection. +

AuthenticationOk

The authentication exchange is successfully completed. +

AuthenticationKerberosV5

The frontend must now take part in a Kerberos V5 + authentication dialog (not described here, part of the + Kerberos specification) with the server. If this is + successful, the server responds with an AuthenticationOk, + otherwise it responds with an ErrorResponse. +

AuthenticationCleartextPassword

The frontend must now send a PasswordMessage containing the + password in clear-text form. If + this is the correct password, the server responds with an + AuthenticationOk, otherwise it responds with an ErrorResponse. +

AuthenticationMD5Password

The frontend must now send a PasswordMessage containing the + password (with username) encrypted via MD5, then encrypted + again using the 4-byte random salt specified in the + AuthenticationMD5Password message. If this is the correct + password, the server responds with an AuthenticationOk, + otherwise it responds with an ErrorResponse. The actual + PasswordMessage can be computed in SQL as concat('md5', + md5(concat(md5(concat(password, username)), random-salt))). + (Keep in mind the md5() function returns its + result as a hex string.) +

AuthenticationSCMCredential

This response is only possible for local Unix-domain connections + on platforms that support SCM credential messages. The frontend + must issue an SCM credential message and then send a single data + byte. (The contents of the data byte are uninteresting; it's + only used to ensure that the server waits long enough to receive + the credential message.) If the credential is acceptable, + the server responds with an + AuthenticationOk, otherwise it responds with an ErrorResponse. + (This message type is only issued by pre-9.1 servers. It may + eventually be removed from the protocol specification.) +

AuthenticationGSS

The frontend must now initiate a GSSAPI negotiation. The frontend + will send a PasswordMessage with the first part of the GSSAPI + data stream in response to this. If further messages are needed, + the server will respond with AuthenticationGSSContinue. +

AuthenticationSSPI

The frontend must now initiate a SSPI negotiation. The frontend + will send a PasswordMessage with the first part of the SSPI + data stream in response to this. If further messages are needed, + the server will respond with AuthenticationGSSContinue. +

AuthenticationGSSContinue

This message contains the response data from the previous step + of GSSAPI or SSPI negotiation (AuthenticationGSS, AuthenticationSSPI + or a previous AuthenticationGSSContinue). If the GSSAPI + or SSPI data in this message + indicates more data is needed to complete the authentication, + the frontend must send that data as another PasswordMessage. If + GSSAPI or SSPI authentication is completed by this message, the server + will next send AuthenticationOk to indicate successful authentication + or ErrorResponse to indicate failure. +

+

If the frontend does not support the authentication method + requested by the server, then it should immediately close the + connection. +

After having received AuthenticationOk, the frontend must wait + for further messages from the server. In this phase a backend process + is being started, and the frontend is just an interested bystander. + It is still possible for the startup attempt + to fail (ErrorResponse), but in the normal case the backend will send + some ParameterStatus messages, BackendKeyData, and finally ReadyForQuery. +

During this phase the backend will attempt to apply any additional + run-time parameter settings that were given in the startup message. + If successful, these values become session defaults. An error causes + ErrorResponse and exit. +

The possible messages from the backend in this phase are: + +

BackendKeyData

This message provides secret-key data that the frontend must + save if it wants to be able to issue cancel requests later. + The frontend should not respond to this message, but should + continue listening for a ReadyForQuery message. +

ParameterStatus

This message informs the frontend about the current (initial) + setting of backend parameters, such as client_encoding or DateStyle. + The frontend can ignore this message, or record the settings + for its future use; see Section 46.2.6 for + more details. The frontend should not respond to this + message, but should continue listening for a ReadyForQuery + message. +

ReadyForQuery

Start-up is completed. The frontend can now issue commands. +

ErrorResponse

Start-up failed. The connection is closed after sending this + message. +

NoticeResponse

A warning message has been issued. The frontend should + display the message but continue listening for ReadyForQuery + or ErrorResponse. +

+

The ReadyForQuery message is the same one that the backend will + issue after each command cycle. Depending on the coding needs of + the frontend, it is reasonable to consider ReadyForQuery as + starting a command cycle, or to consider ReadyForQuery as ending the + start-up phase and each subsequent command cycle. +

46.2.2. Simple Query

A simple query cycle is initiated by the frontend sending a Query message + to the backend. The message includes an SQL command (or commands) + expressed as a text string. + The backend then sends one or more response + messages depending on the contents of the query command string, + and finally a ReadyForQuery response message. ReadyForQuery + informs the frontend that it can safely send a new command. + (It is not actually necessary for the frontend to wait for + ReadyForQuery before issuing another command, but the frontend must + then take responsibility for figuring out what happens if the earlier + command fails and already-issued later commands succeed.) +

The possible response messages from the backend are: + +

CommandComplete

An SQL command completed normally. +

CopyInResponse

The backend is ready to copy data from the frontend to a + table; see Section 46.2.5. +

CopyOutResponse

The backend is ready to copy data from a table to the + frontend; see Section 46.2.5. +

RowDescription

Indicates that rows are about to be returned in response to + a SELECT, FETCH, etc query. + The contents of this message describe the column layout of the rows. + This will be followed by a DataRow message for each row being returned + to the frontend. +

DataRow

One of the set of rows returned by + a SELECT, FETCH, etc query. +

EmptyQueryResponse

An empty query string was recognized. +

ErrorResponse

An error has occurred. +

ReadyForQuery

Processing of the query string is complete. A separate + message is sent to indicate this because the query string might + contain multiple SQL commands. (CommandComplete marks the + end of processing one SQL command, not the whole string.) + ReadyForQuery will always be sent, whether processing + terminates successfully or with an error. +

NoticeResponse

A warning message has been issued in relation to the query. + Notices are in addition to other responses, i.e., the backend + will continue processing the command. +

+

The response to a SELECT query (or other queries that + return row sets, such as EXPLAIN or SHOW) + normally consists of RowDescription, zero or more + DataRow messages, and then CommandComplete. + COPY to or from the frontend invokes special protocol + as described in Section 46.2.5. + All other query types normally produce only + a CommandComplete message. +

Since a query string could contain several queries (separated by + semicolons), there might be several such response sequences before the + backend finishes processing the query string. ReadyForQuery is issued + when the entire string has been processed and the backend is ready to + accept a new query string. +

If a completely empty (no contents other than whitespace) query string + is received, the response is EmptyQueryResponse followed by ReadyForQuery. +

In the event of an error, ErrorResponse is issued followed by + ReadyForQuery. All further processing of the query string is aborted by + ErrorResponse (even if more queries remained in it). Note that this + might occur partway through the sequence of messages generated by an + individual query. +

In simple Query mode, the format of retrieved values is always text, + except when the given command is a FETCH from a cursor + declared with the BINARY option. In that case, the + retrieved values are in binary format. The format codes given in + the RowDescription message tell which format is being used. +

A frontend must be prepared to accept ErrorResponse and + NoticeResponse messages whenever it is expecting any other type of + message. See also Section 46.2.6 concerning messages + that the backend might generate due to outside events. +

Recommended practice is to code frontends in a state-machine style + that will accept any message type at any time that it could make sense, + rather than wiring in assumptions about the exact sequence of messages. +

46.2.3. Extended Query

The extended query protocol breaks down the above-described simple + query protocol into multiple steps. The results of preparatory + steps can be re-used multiple times for improved efficiency. + Furthermore, additional features are available, such as the possibility + of supplying data values as separate parameters instead of having to + insert them directly into a query string. +

In the extended protocol, the frontend first sends a Parse message, + which contains a textual query string, optionally some information + about data types of parameter placeholders, and the + name of a destination prepared-statement object (an empty string + selects the unnamed prepared statement). The response is + either ParseComplete or ErrorResponse. Parameter data types can be + specified by OID; if not given, the parser attempts to infer the + data types in the same way as it would do for untyped literal string + constants. +

Note: A parameter data type can be left unspecified by setting it to zero, + or by making the array of parameter type OIDs shorter than the + number of parameter symbols ($n) + used in the query string. Another special case is that a parameter's + type can be specified as void (that is, the OID of the + void pseudotype). This is meant to allow parameter symbols + to be used for function parameters that are actually OUT parameters. + Ordinarily there is no context in which a void parameter + could be used, but if such a parameter symbol appears in a function's + parameter list, it is effectively ignored. For example, a function + call such as foo($1,$2,$3,$4) could match a function with + two IN and two OUT arguments, if $3 and $4 + are specified as having type void. +

Note: The query string contained in a Parse message cannot include more + than one SQL statement; else a syntax error is reported. This + restriction does not exist in the simple-query protocol, but it + does exist in the extended protocol, because allowing prepared + statements or portals to contain multiple commands would complicate + the protocol unduly. +

If successfully created, a named prepared-statement object lasts till + the end of the current session, unless explicitly destroyed. An unnamed + prepared statement lasts only until the next Parse statement specifying + the unnamed statement as destination is issued. (Note that a simple + Query message also destroys the unnamed statement.) Named prepared + statements must be explicitly closed before they can be redefined by + another Parse message, but this is not required for the unnamed statement. + Named prepared statements can also be created and accessed at the SQL + command level, using PREPARE and EXECUTE. +

Once a prepared statement exists, it can be readied for execution using a + Bind message. The Bind message gives the name of the source prepared + statement (empty string denotes the unnamed prepared statement), the name + of the destination portal (empty string denotes the unnamed portal), and + the values to use for any parameter placeholders present in the prepared + statement. The + supplied parameter set must match those needed by the prepared statement. + (If you declared any void parameters in the Parse message, + pass NULL values for them in the Bind message.) + Bind also specifies the format to use for any data returned + by the query; the format can be specified overall, or per-column. + The response is either BindComplete or ErrorResponse. +

Note: The choice between text and binary output is determined by the format + codes given in Bind, regardless of the SQL command involved. The + BINARY attribute in cursor declarations is irrelevant when + using extended query protocol. +

Query planning typically occurs when the Bind message is processed. + If the prepared statement has no parameters, or is executed repeatedly, + the server might save the created plan and re-use it during subsequent + Bind messages for the same prepared statement. However, it will do so + only if it finds that a generic plan can be created that is not much + less efficient than a plan that depends on the specific parameter values + supplied. This happens transparently so far as the protocol is concerned. +

If successfully created, a named portal object lasts till the end of the + current transaction, unless explicitly destroyed. An unnamed portal is + destroyed at the end of the transaction, or as soon as the next Bind + statement specifying the unnamed portal as destination is issued. (Note + that a simple Query message also destroys the unnamed portal.) Named + portals must be explicitly closed before they can be redefined by another + Bind message, but this is not required for the unnamed portal. + Named portals can also be created and accessed at the SQL + command level, using DECLARE CURSOR and FETCH. +

Once a portal exists, it can be executed using an Execute message. + The Execute message specifies the portal name (empty string denotes the + unnamed portal) and + a maximum result-row count (zero meaning "fetch all rows"). + The result-row count is only meaningful for portals + containing commands that return row sets; in other cases the command is + always executed to completion, and the row count is ignored. + The possible + responses to Execute are the same as those described above for queries + issued via simple query protocol, except that Execute doesn't cause + ReadyForQuery or RowDescription to be issued. +

If Execute terminates before completing the execution of a portal + (due to reaching a nonzero result-row count), it will send a + PortalSuspended message; the appearance of this message tells the frontend + that another Execute should be issued against the same portal to + complete the operation. The CommandComplete message indicating + completion of the source SQL command is not sent until + the portal's execution is completed. Therefore, an Execute phase is + always terminated by the appearance of exactly one of these messages: + CommandComplete, EmptyQueryResponse (if the portal was created from + an empty query string), ErrorResponse, or PortalSuspended. +

At completion of each series of extended-query messages, the frontend + should issue a Sync message. This parameterless message causes the + backend to close the current transaction if it's not inside a + BEGIN/COMMIT transaction block ("close" + meaning to commit if no error, or roll back if error). Then a + ReadyForQuery response is issued. The purpose of Sync is to provide + a resynchronization point for error recovery. When an error is detected + while processing any extended-query message, the backend issues + ErrorResponse, then reads and discards messages until a Sync is reached, + then issues ReadyForQuery and returns to normal message processing. + (But note that no skipping occurs if an error is detected + while processing Sync — this ensures that there is one + and only one ReadyForQuery sent for each Sync.) +

Note: Sync does not cause a transaction block opened with BEGIN + to be closed. It is possible to detect this situation since the + ReadyForQuery message includes transaction status information. +

In addition to these fundamental, required operations, there are several + optional operations that can be used with extended-query protocol. +

The Describe message (portal variant) specifies the name of an existing + portal (or an empty string for the unnamed portal). The response is a + RowDescription message describing the rows that will be returned by + executing the portal; or a NoData message if the portal does not contain a + query that will return rows; or ErrorResponse if there is no such portal. +

The Describe message (statement variant) specifies the name of an existing + prepared statement (or an empty string for the unnamed prepared + statement). The response is a ParameterDescription message describing the + parameters needed by the statement, followed by a RowDescription message + describing the rows that will be returned when the statement is eventually + executed (or a NoData message if the statement will not return rows). + ErrorResponse is issued if there is no such prepared statement. Note that + since Bind has not yet been issued, the formats to be used for returned + columns are not yet known to the backend; the format code fields in the + RowDescription message will be zeroes in this case. +

Tip: In most scenarios the frontend should issue one or the other variant + of Describe before issuing Execute, to ensure that it knows how to + interpret the results it will get back. +

The Close message closes an existing prepared statement or portal + and releases resources. It is not an error to issue Close against + a nonexistent statement or portal name. The response is normally + CloseComplete, but could be ErrorResponse if some difficulty is + encountered while releasing resources. Note that closing a prepared + statement implicitly closes any open portals that were constructed + from that statement. +

The Flush message does not cause any specific output to be generated, + but forces the backend to deliver any data pending in its output + buffers. A Flush must be sent after any extended-query command except + Sync, if the frontend wishes to examine the results of that command before + issuing more commands. Without Flush, messages returned by the backend + will be combined into the minimum possible number of packets to minimize + network overhead. +

Note: The simple Query message is approximately equivalent to the series Parse, + Bind, portal Describe, Execute, Close, Sync, using the unnamed prepared + statement and portal objects and no parameters. One difference is that + it will accept multiple SQL statements in the query string, automatically + performing the bind/describe/execute sequence for each one in succession. + Another difference is that it will not return ParseComplete, BindComplete, + CloseComplete, or NoData messages. +

46.2.4. Function Call

The Function Call sub-protocol allows the client to request a direct + call of any function that exists in the database's + pg_proc system catalog. The client must have + execute permission for the function. +

Note: The Function Call sub-protocol is a legacy feature that is probably best + avoided in new code. Similar results can be accomplished by setting up + a prepared statement that does SELECT function($1, ...). + The Function Call cycle can then be replaced with Bind/Execute. +

A Function Call cycle is initiated by the frontend sending a + FunctionCall message to the backend. The backend then sends one + or more response messages depending on the results of the function + call, and finally a ReadyForQuery response message. ReadyForQuery + informs the frontend that it can safely send a new query or + function call. +

The possible response messages from the backend are: + +

ErrorResponse

An error has occurred. +

FunctionCallResponse

The function call was completed and returned the result given + in the message. + (Note that the Function Call protocol can only handle a single + scalar result, not a row type or set of results.) +

ReadyForQuery

Processing of the function call is complete. ReadyForQuery + will always be sent, whether processing terminates + successfully or with an error. +

NoticeResponse

A warning message has been issued in relation to the function + call. Notices are in addition to other responses, i.e., the + backend will continue processing the command. +

+

46.2.5. COPY Operations

The COPY command allows high-speed bulk data transfer + to or from the server. Copy-in and copy-out operations each switch + the connection into a distinct sub-protocol, which lasts until the + operation is completed. +

Copy-in mode (data transfer to the server) is initiated when the + backend executes a COPY FROM STDIN SQL statement. The backend + sends a CopyInResponse message to the frontend. The frontend should + then send zero or more CopyData messages, forming a stream of input + data. (The message boundaries are not required to have anything to do + with row boundaries, although that is often a reasonable choice.) + The frontend can terminate the copy-in mode by sending either a CopyDone + message (allowing successful termination) or a CopyFail message (which + will cause the COPY SQL statement to fail with an + error). The backend then reverts to the command-processing mode it was + in before the COPY started, which will be either simple or + extended query protocol. It will next send either CommandComplete + (if successful) or ErrorResponse (if not). +

In the event of a backend-detected error during copy-in mode (including + receipt of a CopyFail message), the backend will issue an ErrorResponse + message. If the COPY command was issued via an extended-query + message, the backend will now discard frontend messages until a Sync + message is received, then it will issue ReadyForQuery and return to normal + processing. If the COPY command was issued in a simple + Query message, the rest of that message is discarded and ReadyForQuery + is issued. In either case, any subsequent CopyData, CopyDone, or CopyFail + messages issued by the frontend will simply be dropped. +

The backend will ignore Flush and Sync messages received during copy-in + mode. Receipt of any other non-copy message type constitutes an error + that will abort the copy-in state as described above. (The exception for + Flush and Sync is for the convenience of client libraries that always + send Flush or Sync after an Execute message, without checking whether + the command to be executed is a COPY FROM STDIN.) +

Copy-out mode (data transfer from the server) is initiated when the + backend executes a COPY TO STDOUT SQL statement. The backend + sends a CopyOutResponse message to the frontend, followed by + zero or more CopyData messages (always one per row), followed by CopyDone. + The backend then reverts to the command-processing mode it was + in before the COPY started, and sends CommandComplete. + The frontend cannot abort the transfer (except by closing the connection + or issuing a Cancel request), + but it can discard unwanted CopyData and CopyDone messages. +

In the event of a backend-detected error during copy-out mode, + the backend will issue an ErrorResponse message and revert to normal + processing. The frontend should treat receipt of ErrorResponse as + terminating the copy-out mode. +

It is possible for NoticeResponse and ParameterStatus messages to be + interspersed between CopyData messages; frontends must handle these cases, + and should be prepared for other asynchronous message types as well (see + Section 46.2.6). Otherwise, any message type other than + CopyData or CopyDone may be treated as terminating copy-out mode. +

There is another Copy-related mode called Copy-both, which allows + high-speed bulk data transfer to and from the server. + Copy-both mode is initiated when a backend in walsender mode + executes a START_REPLICATION statement. The + backend sends a CopyBothResponse message to the frontend. Both + the backend and the frontend may then send CopyData messages + until the connection is terminated. See Section 46.3. +

The CopyInResponse, CopyOutResponse and CopyBothResponse messages + include fields that inform the frontend of the number of columns + per row and the format codes being used for each column. (As of + the present implementation, all columns in a given COPY + operation will use the same format, but the message design does not + assume this.) +

46.2.6. Asynchronous Operations

There are several cases in which the backend will send messages that + are not specifically prompted by the frontend's command stream. + Frontends must be prepared to deal with these messages at any time, + even when not engaged in a query. + At minimum, one should check for these cases before beginning to + read a query response. +

It is possible for NoticeResponse messages to be generated due to + outside activity; for example, if the database administrator commands + a "fast" database shutdown, the backend will send a NoticeResponse + indicating this fact before closing the connection. Accordingly, + frontends should always be prepared to accept and display NoticeResponse + messages, even when the connection is nominally idle. +

ParameterStatus messages will be generated whenever the active + value changes for any of the parameters the backend believes the + frontend should know about. Most commonly this occurs in response + to a SET SQL command executed by the frontend, and + this case is effectively synchronous — but it is also possible + for parameter status changes to occur because the administrator + changed a configuration file and then sent the + SIGHUP signal to the server. Also, + if a SET command is rolled back, an appropriate + ParameterStatus message will be generated to report the current + effective value. +

At present there is a hard-wired set of parameters for which + ParameterStatus will be generated: they are + server_version, + server_encoding, + client_encoding, + application_name, + is_superuser, + session_authorization, + DateStyle, + IntervalStyle, + TimeZone, + integer_datetimes, and + standard_conforming_strings. + (server_encoding, TimeZone, and + integer_datetimes were not reported by releases before 8.0; + standard_conforming_strings was not reported by releases + before 8.1; + IntervalStyle was not reported by releases before 8.4; + application_name was not reported by releases before 9.0.) + Note that + server_version, + server_encoding and + integer_datetimes + are pseudo-parameters that cannot change after startup. + This set might change in the future, or even become configurable. + Accordingly, a frontend should simply ignore ParameterStatus for + parameters that it does not understand or care about. +

If a frontend issues a LISTEN command, then the + backend will send a NotificationResponse message (not to be + confused with NoticeResponse!) whenever a + NOTIFY command is executed for the same + channel name. +

Note: At present, NotificationResponse can only be sent outside a + transaction, and thus it will not occur in the middle of a + command-response series, though it might occur just before ReadyForQuery. + It is unwise to design frontend logic that assumes that, however. + Good practice is to be able to accept NotificationResponse at any + point in the protocol. +

46.2.7. Canceling Requests in Progress

During the processing of a query, the frontend might request + cancellation of the query. The cancel request is not sent + directly on the open connection to the backend for reasons of + implementation efficiency: we don't want to have the backend + constantly checking for new input from the frontend during query + processing. Cancel requests should be relatively infrequent, so + we make them slightly cumbersome in order to avoid a penalty in + the normal case. +

To issue a cancel request, the frontend opens a new connection to + the server and sends a CancelRequest message, rather than the + StartupMessage message that would ordinarily be sent across a new + connection. The server will process this request and then close + the connection. For security reasons, no direct reply is made to + the cancel request message. +

A CancelRequest message will be ignored unless it contains the + same key data (PID and secret key) passed to the frontend during + connection start-up. If the request matches the PID and secret + key for a currently executing backend, the processing of the + current query is aborted. (In the existing implementation, this is + done by sending a special signal to the backend process that is + processing the query.) +

The cancellation signal might or might not have any effect — for + example, if it arrives after the backend has finished processing + the query, then it will have no effect. If the cancellation is + effective, it results in the current command being terminated + early with an error message. +

The upshot of all this is that for reasons of both security and + efficiency, the frontend has no direct way to tell whether a + cancel request has succeeded. It must continue to wait for the + backend to respond to the query. Issuing a cancel simply improves + the odds that the current query will finish soon, and improves the + odds that it will fail with an error message instead of + succeeding. +

Since the cancel request is sent across a new connection to the + server and not across the regular frontend/backend communication + link, it is possible for the cancel request to be issued by any + process, not just the frontend whose query is to be canceled. + This might provide additional flexibility when building + multiple-process applications. It also introduces a security + risk, in that unauthorized persons might try to cancel queries. + The security risk is addressed by requiring a dynamically + generated secret key to be supplied in cancel requests. +

46.2.8. Termination

The normal, graceful termination procedure is that the frontend + sends a Terminate message and immediately closes the connection. + On receipt of this message, the backend closes the connection and + terminates. +

In rare cases (such as an administrator-commanded database shutdown) + the backend might disconnect without any frontend request to do so. + In such cases the backend will attempt to send an error or notice message + giving the reason for the disconnection before it closes the connection. +

Other termination scenarios arise from various failure cases, such as core + dump at one end or the other, loss of the communications link, loss of + message-boundary synchronization, etc. If either frontend or backend sees + an unexpected closure of the connection, it should clean + up and terminate. The frontend has the option of launching a new backend + by recontacting the server if it doesn't want to terminate itself. + Closing the connection is also advisable if an unrecognizable message type + is received, since this probably indicates loss of message-boundary sync. +

For either normal or abnormal termination, any open transaction is + rolled back, not committed. One should note however that if a + frontend disconnects while a non-SELECT query + is being processed, the backend will probably finish the query + before noticing the disconnection. If the query is outside any + transaction block (BEGIN ... COMMIT + sequence) then its results might be committed before the + disconnection is recognized. +

46.2.9. SSL Session Encryption

If PostgreSQL was built with + SSL support, frontend/backend communications + can be encrypted using SSL. This provides + communication security in environments where attackers might be + able to capture the session traffic. For more information on + encrypting PostgreSQL sessions with + SSL, see Section 17.9. +

To initiate an SSL-encrypted connection, the + frontend initially sends an SSLRequest message rather than a + StartupMessage. The server then responds with a single byte + containing S or N, indicating that it is + willing or unwilling to perform SSL, + respectively. The frontend might close the connection at this point + if it is dissatisfied with the response. To continue after + S, perform an SSL startup handshake + (not described here, part of the SSL + specification) with the server. If this is successful, continue + with sending the usual StartupMessage. In this case the + StartupMessage and all subsequent data will be + SSL-encrypted. To continue after + N, send the usual StartupMessage and proceed without + encryption. +

The frontend should also be prepared to handle an ErrorMessage + response to SSLRequest from the server. This would only occur if + the server predates the addition of SSL support + to PostgreSQL. (Such servers are now very ancient, + and likely do not exist in the wild anymore.) + In this case the connection must + be closed, but the frontend might choose to open a fresh connection + and proceed without requesting SSL. +

An initial SSLRequest can also be used in a connection that is being + opened to send a CancelRequest message. +

While the protocol itself does not provide a way for the server to + force SSL encryption, the administrator can + configure the server to reject unencrypted sessions as a byproduct + of authentication checking. +


PrevHomeNext
OverviewUpStreaming Replication Protocol
\ No newline at end of file diff --git a/doc/src/sgml/html/protocol-message-formats.html b/doc/src/sgml/html/protocol-message-formats.html new file mode 100644 index 000000000..7655eec7a --- /dev/null +++ b/doc/src/sgml/html/protocol-message-formats.html @@ -0,0 +1,2460 @@ + +Message Formats
PostgreSQL 9.2.2 Documentation
PrevUpChapter 46. Frontend/Backend ProtocolNext

46.5. Message Formats

This section describes the detailed format of each message. Each is marked to +indicate that it can be sent by a frontend (F), a backend (B), or both +(F & B). +Notice that although each message includes a byte count at the beginning, +the message format is defined so that the message end can be found without +reference to the byte count. This aids validity checking. (The CopyData +message is an exception, because it forms part of a data stream; the contents +of any individual CopyData message cannot be interpretable on their own.)

AuthenticationOk (B)

Byte1('R')

Identifies the message as an authentication request.

Int32(8)

Length of message contents in bytes, including self.

Int32(0)

Specifies that the authentication was successful.

AuthenticationKerberosV5 (B)

Byte1('R')

Identifies the message as an authentication request.

Int32(8)

Length of message contents in bytes, including self.

Int32(2)

Specifies that Kerberos V5 authentication is required.

AuthenticationCleartextPassword (B)

Byte1('R')

Identifies the message as an authentication request.

Int32(8)

Length of message contents in bytes, including self.

Int32(3)

Specifies that a clear-text password is required.

AuthenticationMD5Password (B)

Byte1('R')

Identifies the message as an authentication request.

Int32(12)

Length of message contents in bytes, including self.

Int32(5)

Specifies that an MD5-encrypted password is required.

Byte4

The salt to use when encrypting the password.

AuthenticationSCMCredential (B)

Byte1('R')

Identifies the message as an authentication request.

Int32(8)

Length of message contents in bytes, including self.

Int32(6)

Specifies that an SCM credentials message is required.

AuthenticationGSS (B)

Byte1('R')

Identifies the message as an authentication request.

Int32(8)

Length of message contents in bytes, including self.

Int32(7)

Specifies that GSSAPI authentication is required.

AuthenticationSSPI (B)

Byte1('R')

Identifies the message as an authentication request.

Int32(8)

Length of message contents in bytes, including self.

Int32(9)

Specifies that SSPI authentication is required.

AuthenticationGSSContinue (B)

Byte1('R')

Identifies the message as an authentication request.

Int32

Length of message contents in bytes, including self.

Int32(8)

Specifies that this message contains GSSAPI or SSPI data.

Byten

GSSAPI or SSPI authentication data.

BackendKeyData (B)

Byte1('K')

Identifies the message as cancellation key data. + The frontend must save these values if it wishes to be + able to issue CancelRequest messages later.

Int32(12)

Length of message contents in bytes, including self.

Int32

The process ID of this backend.

Int32

The secret key of this backend.

Bind (F)

Byte1('B')

Identifies the message as a Bind command.

Int32

Length of message contents in bytes, including self.

String

The name of the destination portal + (an empty string selects the unnamed portal).

String

The name of the source prepared statement + (an empty string selects the unnamed prepared statement).

Int16

The number of parameter format codes that follow + (denoted C below). + This can be zero to indicate that there are no parameters + or that the parameters all use the default format (text); + or one, in which case the specified format code is applied + to all parameters; or it can equal the actual number of + parameters.

Int16[C]

The parameter format codes. Each must presently be + zero (text) or one (binary).

Int16

The number of parameter values that follow (possibly zero). + This must match the number of parameters needed by the query.

+ Next, the following pair of fields appear for each parameter: +

Int32

The length of the parameter value, in bytes (this count + does not include itself). Can be zero. + As a special case, -1 indicates a NULL parameter value. + No value bytes follow in the NULL case.

Byten

The value of the parameter, in the format indicated by the + associated format code. + n is the above length.

+ After the last parameter, the following fields appear: +

Int16

The number of result-column format codes that follow + (denoted R below). + This can be zero to indicate that there are no result columns + or that the result columns should all use the default format + (text); + or one, in which case the specified format code is applied + to all result columns (if any); or it can equal the actual + number of result columns of the query.

Int16[R]

The result-column format codes. Each must presently be + zero (text) or one (binary).

BindComplete (B)

Byte1('2')

Identifies the message as a Bind-complete indicator.

Int32(4)

Length of message contents in bytes, including self.

CancelRequest (F)

Int32(16)

Length of message contents in bytes, including self.

Int32(80877102)

The cancel request code. The value is chosen to contain + 1234 in the most significant 16 bits, and 5678 in the + least 16 significant bits. (To avoid confusion, this code + must not be the same as any protocol version number.)

Int32

The process ID of the target backend.

Int32

The secret key for the target backend.

Close (F)

Byte1('C')

Identifies the message as a Close command.

Int32

Length of message contents in bytes, including self.

Byte1

'S' to close a prepared statement; or + 'P' to close a portal.

String

The name of the prepared statement or portal to close + (an empty string selects the unnamed prepared statement + or portal).

CloseComplete (B)

Byte1('3')

Identifies the message as a Close-complete indicator.

Int32(4)

Length of message contents in bytes, including self.

CommandComplete (B)

Byte1('C')

Identifies the message as a command-completed response.

Int32

Length of message contents in bytes, including self.

String

The command tag. This is usually a single + word that identifies which SQL command was completed. +

For an INSERT command, the tag is + INSERT oid + rows, where + rows is the number of rows + inserted. oid is the object ID + of the inserted row if rows is 1 + and the target table has OIDs; + otherwise oid is 0. +

For a DELETE command, the tag is + DELETE rows where + rows is the number of rows deleted. +

For an UPDATE command, the tag is + UPDATE rows where + rows is the number of rows updated. +

For a SELECT or CREATE TABLE AS + command, the tag is SELECT rows + where rows is the number of rows retrieved. +

For a MOVE command, the tag is + MOVE rows where + rows is the number of rows the + cursor's position has been changed by. +

For a FETCH command, the tag is + FETCH rows where + rows is the number of rows that + have been retrieved from the cursor. +

For a COPY command, the tag is + COPY rows where + rows is the number of rows copied. + (Note: the row count appears only in + PostgreSQL 8.2 and later.) +

CopyData (F & B)

Byte1('d')

Identifies the message as COPY data.

Int32

Length of message contents in bytes, including self.

Byten

Data that forms part of a COPY data stream. Messages sent + from the backend will always correspond to single data rows, + but messages sent by frontends might divide the data stream + arbitrarily.

CopyDone (F & B)

Byte1('c')

Identifies the message as a COPY-complete indicator.

Int32(4)

Length of message contents in bytes, including self.

CopyFail (F)

Byte1('f')

Identifies the message as a COPY-failure indicator.

Int32

Length of message contents in bytes, including self.

String

An error message to report as the cause of failure.

CopyInResponse (B)

Byte1('G')

Identifies the message as a Start Copy In response. + The frontend must now send copy-in data (if not + prepared to do so, send a CopyFail message).

Int32

Length of message contents in bytes, including self.

Int8

0 indicates the overall COPY format is textual (rows + separated by newlines, columns separated by separator + characters, etc). + 1 indicates the overall copy format is binary (similar + to DataRow format). + See COPY + for more information.

Int16

The number of columns in the data to be copied + (denoted N below).

Int16[N]

The format codes to be used for each column. + Each must presently be zero (text) or one (binary). + All must be zero if the overall copy format is textual.

CopyOutResponse (B)

Byte1('H')

Identifies the message as a Start Copy Out response. + This message will be followed by copy-out data.

Int32

Length of message contents in bytes, including self.

Int8

0 indicates the overall COPY format + is textual (rows separated by newlines, columns + separated by separator characters, etc). 1 indicates + the overall copy format is binary (similar to DataRow + format). See COPY for more information.

Int16

The number of columns in the data to be copied + (denoted N below).

Int16[N]

The format codes to be used for each column. + Each must presently be zero (text) or one (binary). + All must be zero if the overall copy format is textual.

CopyBothResponse (B)

Byte1('W')

Identifies the message as a Start Copy Both response. + This message is used only for Streaming Replication.

Int32

Length of message contents in bytes, including self.

Int8

0 indicates the overall COPY format + is textual (rows separated by newlines, columns + separated by separator characters, etc). 1 indicates + the overall copy format is binary (similar to DataRow + format). See COPY for more information.

Int16

The number of columns in the data to be copied + (denoted N below).

Int16[N]

The format codes to be used for each column. + Each must presently be zero (text) or one (binary). + All must be zero if the overall copy format is textual.

DataRow (B)

Byte1('D')

Identifies the message as a data row.

Int32

Length of message contents in bytes, including self.

Int16

The number of column values that follow (possibly zero).

+ Next, the following pair of fields appear for each column: +

Int32

The length of the column value, in bytes (this count + does not include itself). Can be zero. + As a special case, -1 indicates a NULL column value. + No value bytes follow in the NULL case.

Byten

The value of the column, in the format indicated by the + associated format code. + n is the above length.

Describe (F)

Byte1('D')

Identifies the message as a Describe command.

Int32

Length of message contents in bytes, including self.

Byte1

'S' to describe a prepared statement; or + 'P' to describe a portal.

String

The name of the prepared statement or portal to describe + (an empty string selects the unnamed prepared statement + or portal).

EmptyQueryResponse (B)

Byte1('I')

Identifies the message as a response to an empty query string. + (This substitutes for CommandComplete.)

Int32(4)

Length of message contents in bytes, including self.

ErrorResponse (B)

Byte1('E')

Identifies the message as an error.

Int32

Length of message contents in bytes, including self.

+ The message body consists of one or more identified fields, + followed by a zero byte as a terminator. Fields can appear in + any order. For each field there is the following: +

Byte1

A code identifying the field type; if zero, this is + the message terminator and no string follows. + The presently defined field types are listed in + Section 46.6. + Since more field types might be added in future, + frontends should silently ignore fields of unrecognized + type.

String

The field value.

Execute (F)

Byte1('E')

Identifies the message as an Execute command.

Int32

Length of message contents in bytes, including self.

String

The name of the portal to execute + (an empty string selects the unnamed portal).

Int32

Maximum number of rows to return, if portal contains + a query that returns rows (ignored otherwise). Zero + denotes "no limit".

Flush (F)

Byte1('H')

Identifies the message as a Flush command.

Int32(4)

Length of message contents in bytes, including self.

FunctionCall (F)

Byte1('F')

Identifies the message as a function call.

Int32

Length of message contents in bytes, including self.

Int32

Specifies the object ID of the function to call.

Int16

The number of argument format codes that follow + (denoted C below). + This can be zero to indicate that there are no arguments + or that the arguments all use the default format (text); + or one, in which case the specified format code is applied + to all arguments; or it can equal the actual number of + arguments.

Int16[C]

The argument format codes. Each must presently be + zero (text) or one (binary).

Int16

Specifies the number of arguments being supplied to the + function.

+ Next, the following pair of fields appear for each argument: +

Int32

The length of the argument value, in bytes (this count + does not include itself). Can be zero. + As a special case, -1 indicates a NULL argument value. + No value bytes follow in the NULL case.

Byten

The value of the argument, in the format indicated by the + associated format code. + n is the above length.

+ After the last argument, the following field appears: +

Int16

The format code for the function result. Must presently be + zero (text) or one (binary).

FunctionCallResponse (B)

Byte1('V')

Identifies the message as a function call result.

Int32

Length of message contents in bytes, including self.

Int32

The length of the function result value, in bytes (this count + does not include itself). Can be zero. + As a special case, -1 indicates a NULL function result. + No value bytes follow in the NULL case.

Byten

The value of the function result, in the format indicated by + the associated format code. + n is the above length.

NoData (B)

Byte1('n')

Identifies the message as a no-data indicator.

Int32(4)

Length of message contents in bytes, including self.

NoticeResponse (B)

Byte1('N')

Identifies the message as a notice.

Int32

Length of message contents in bytes, including self.

+ The message body consists of one or more identified fields, + followed by a zero byte as a terminator. Fields can appear in + any order. For each field there is the following: +

Byte1

A code identifying the field type; if zero, this is + the message terminator and no string follows. + The presently defined field types are listed in + Section 46.6. + Since more field types might be added in future, + frontends should silently ignore fields of unrecognized + type.

String

The field value.

NotificationResponse (B)

Byte1('A')

Identifies the message as a notification response.

Int32

Length of message contents in bytes, including self.

Int32

The process ID of the notifying backend process.

String

The name of the channel that the notify has been raised on.

String

The "payload" string passed from the notifying process.

ParameterDescription (B)

Byte1('t')

Identifies the message as a parameter description.

Int32

Length of message contents in bytes, including self.

Int16

The number of parameters used by the statement + (can be zero).

+ Then, for each parameter, there is the following: +

Int32

Specifies the object ID of the parameter data type.

ParameterStatus (B)

Byte1('S')

Identifies the message as a run-time parameter status report.

Int32

Length of message contents in bytes, including self.

String

The name of the run-time parameter being reported.

String

The current value of the parameter.

Parse (F)

Byte1('P')

Identifies the message as a Parse command.

Int32

Length of message contents in bytes, including self.

String

The name of the destination prepared statement + (an empty string selects the unnamed prepared statement).

String

The query string to be parsed.

Int16

The number of parameter data types specified + (can be zero). Note that this is not an indication of + the number of parameters that might appear in the + query string, only the number that the frontend wants to + prespecify types for.

+ Then, for each parameter, there is the following: +

Int32

Specifies the object ID of the parameter data type. + Placing a zero here is equivalent to leaving the type + unspecified.

ParseComplete (B)

Byte1('1')

Identifies the message as a Parse-complete indicator.

Int32(4)

Length of message contents in bytes, including self.

PasswordMessage (F)

Byte1('p')

Identifies the message as a password response. Note that + this is also used for GSSAPI and SSPI response messages + (which is really a design error, since the contained data + is not a null-terminated string in that case, but can be + arbitrary binary data).

Int32

Length of message contents in bytes, including self.

String

The password (encrypted, if requested).

PortalSuspended (B)

Byte1('s')

Identifies the message as a portal-suspended indicator. + Note this only appears if an Execute message's row-count limit + was reached.

Int32(4)

Length of message contents in bytes, including self.

Query (F)

Byte1('Q')

Identifies the message as a simple query.

Int32

Length of message contents in bytes, including self.

String

The query string itself.

ReadyForQuery (B)

Byte1('Z')

Identifies the message type. ReadyForQuery is sent + whenever the backend is ready for a new query cycle.

Int32(5)

Length of message contents in bytes, including self.

Byte1

Current backend transaction status indicator. + Possible values are 'I' if idle (not in + a transaction block); 'T' if in a transaction + block; or 'E' if in a failed transaction + block (queries will be rejected until block is ended).

RowDescription (B)

Byte1('T')

Identifies the message as a row description.

Int32

Length of message contents in bytes, including self.

Int16

Specifies the number of fields in a row (can be zero).

+ Then, for each field, there is the following: +

String

The field name.

Int32

If the field can be identified as a column of a specific + table, the object ID of the table; otherwise zero.

Int16

If the field can be identified as a column of a specific + table, the attribute number of the column; otherwise zero.

Int32

The object ID of the field's data type.

Int16

The data type size (see pg_type.typlen). + Note that negative values denote variable-width types.

Int32

The type modifier (see pg_attribute.atttypmod). + The meaning of the modifier is type-specific.

Int16

The format code being used for the field. Currently will + be zero (text) or one (binary). In a RowDescription + returned from the statement variant of Describe, the + format code is not yet known and will always be zero.

SSLRequest (F)

Int32(8)

Length of message contents in bytes, including self.

Int32(80877103)

The SSL request code. The value is chosen to contain + 1234 in the most significant 16 bits, and 5679 in the + least 16 significant bits. (To avoid confusion, this code + must not be the same as any protocol version number.)

StartupMessage (F)

Int32

Length of message contents in bytes, including self.

Int32(196608)

The protocol version number. The most significant 16 bits are + the major version number (3 for the protocol described here). + The least significant 16 bits are the minor version number + (0 for the protocol described here).

+ The protocol version number is followed by one or more pairs of + parameter name and value strings. A zero byte is required as a + terminator after the last name/value pair. + Parameters can appear in any + order. user is required, others are optional. + Each parameter is specified as: +

String

The parameter name. Currently recognized names are: + +

user

The database user name to connect as. Required; + there is no default.

database

The database to connect to. Defaults to the user name.

options

Command-line arguments for the backend. (This is + deprecated in favor of setting individual run-time + parameters.)

+ + In addition to the above, any run-time parameter that can be + set at backend start time might be listed. Such settings + will be applied during backend start (after parsing the + command-line options if any). The values will act as + session defaults.

String

The parameter value.

Sync (F)

Byte1('S')

Identifies the message as a Sync command.

Int32(4)

Length of message contents in bytes, including self.

Terminate (F)

Byte1('X')

Identifies the message as a termination.

Int32(4)

Length of message contents in bytes, including self.


PrevHomeNext
Message Data TypesUpError and Notice Message Fields
\ No newline at end of file diff --git a/doc/src/sgml/html/protocol-message-types.html b/doc/src/sgml/html/protocol-message-types.html new file mode 100644 index 000000000..880aadabf --- /dev/null +++ b/doc/src/sgml/html/protocol-message-types.html @@ -0,0 +1,314 @@ + +Message Data Types
PostgreSQL 9.2.2 Documentation
PrevUpChapter 46. Frontend/Backend ProtocolNext

46.4. Message Data Types

This section describes the base data types used in messages. + +

Intn(i)

An n-bit integer in network byte + order (most significant byte first). + If i is specified it + is the exact value that will appear, otherwise the value + is variable. Eg. Int16, Int32(42).

Intn[k]

An array of k + n-bit integers, each in network + byte order. The array length k + is always determined by an earlier field in the message. + Eg. Int16[M].

String(s)

A null-terminated string (C-style string). There is no + specific length limitation on strings. + If s is specified it is the exact + value that will appear, otherwise the value is variable. + Eg. String, String("user").

Note: There is no predefined limit on the length of a string +that can be returned by the backend. Good coding strategy for a frontend +is to use an expandable buffer so that anything that fits in memory can be +accepted. If that's not feasible, read the full string and discard trailing +characters that don't fit into your fixed-size buffer.

Byten(c)

Exactly n bytes. If the field + width n is not a constant, it is + always determinable from an earlier field in the message. + If c is specified it is the exact + value. Eg. Byte2, Byte1('\n').


PrevHomeNext
Streaming Replication ProtocolUpMessage Formats
\ No newline at end of file diff --git a/doc/src/sgml/html/protocol-overview.html b/doc/src/sgml/html/protocol-overview.html new file mode 100644 index 000000000..74bc31148 --- /dev/null +++ b/doc/src/sgml/html/protocol-overview.html @@ -0,0 +1,374 @@ + +Overview
PostgreSQL 9.2.2 Documentation
PrevUpChapter 46. Frontend/Backend ProtocolNext

46.1. Overview

The protocol has separate phases for startup and normal operation. + In the startup phase, the frontend opens a connection to the server + and authenticates itself to the satisfaction of the server. (This might + involve a single message, or multiple messages depending on the + authentication method being used.) If all goes well, the server then sends + status information to the frontend, and finally enters normal operation. + Except for the initial startup-request message, this part of the + protocol is driven by the server. +

During normal operation, the frontend sends queries and + other commands to the backend, and the backend sends back query results + and other responses. There are a few cases (such as NOTIFY) + wherein the + backend will send unsolicited messages, but for the most part this portion + of a session is driven by frontend requests. +

Termination of the session is normally by frontend choice, but can be + forced by the backend in certain cases. In any case, when the backend + closes the connection, it will roll back any open (incomplete) transaction + before exiting. +

Within normal operation, SQL commands can be executed through either of + two sub-protocols. In the "simple query" protocol, the frontend + just sends a textual query string, which is parsed and immediately + executed by the backend. In the "extended query" protocol, + processing of queries is separated into multiple steps: parsing, + binding of parameter values, and execution. This offers flexibility + and performance benefits, at the cost of extra complexity. +

Normal operation has additional sub-protocols for special operations + such as COPY. +

46.1.1. Messaging Overview

All communication is through a stream of messages. The first byte of a + message identifies the message type, and the next four bytes specify the + length of the rest of the message (this length count includes itself, but + not the message-type byte). The remaining contents of the message are + determined by the message type. For historical reasons, the very first + message sent by the client (the startup message) has no initial + message-type byte. +

To avoid losing synchronization with the message stream, both servers and + clients typically read an entire message into a buffer (using the byte + count) before attempting to process its contents. This allows easy + recovery if an error is detected while processing the contents. In + extreme situations (such as not having enough memory to buffer the + message), the receiver can use the byte count to determine how much + input to skip before it resumes reading messages. +

Conversely, both servers and clients must take care never to send an + incomplete message. This is commonly done by marshaling the entire message + in a buffer before beginning to send it. If a communications failure + occurs partway through sending or receiving a message, the only sensible + response is to abandon the connection, since there is little hope of + recovering message-boundary synchronization. +

46.1.2. Extended Query Overview

In the extended-query protocol, execution of SQL commands is divided + into multiple steps. The state retained between steps is represented + by two types of objects: prepared statements and + portals. A prepared statement represents the result of + parsing and semantic analysis of a textual query string. + A prepared statement is not in itself ready to execute, because it might + lack specific values for parameters. A portal represents + a ready-to-execute or already-partially-executed statement, with any + missing parameter values filled in. (For SELECT statements, + a portal is equivalent to an open cursor, but we choose to use a different + term since cursors don't handle non-SELECT statements.) +

The overall execution cycle consists of a parse step, + which creates a prepared statement from a textual query string; a + bind step, which creates a portal given a prepared + statement and values for any needed parameters; and an + execute step that runs a portal's query. In the case of + a query that returns rows (SELECT, SHOW, etc), + the execute step can be told to fetch only + a limited number of rows, so that multiple execute steps might be needed + to complete the operation. +

The backend can keep track of multiple prepared statements and portals + (but note that these exist only within a session, and are never shared + across sessions). Existing prepared statements and portals are + referenced by names assigned when they were created. In addition, + an "unnamed" prepared statement and portal exist. Although these + behave largely the same as named objects, operations on them are optimized + for the case of executing a query only once and then discarding it, + whereas operations on named objects are optimized on the expectation + of multiple uses. +

46.1.3. Formats and Format Codes

Data of a particular data type might be transmitted in any of several + different formats. As of PostgreSQL 7.4 + the only supported formats are "text" and "binary", + but the protocol makes provision for future extensions. The desired + format for any value is specified by a format code. + Clients can specify a format code for each transmitted parameter value + and for each column of a query result. Text has format code zero, + binary has format code one, and all other format codes are reserved + for future definition. +

The text representation of values is whatever strings are produced + and accepted by the input/output conversion functions for the + particular data type. In the transmitted representation, there is + no trailing null character; the frontend must add one to received + values if it wants to process them as C strings. + (The text format does not allow embedded nulls, by the way.) +

Binary representations for integers use network byte order (most + significant byte first). For other data types consult the documentation + or source code to learn about the binary representation. Keep in mind + that binary representations for complex data types might change across + server versions; the text format is usually the more portable choice. +


PrevHomeNext
Frontend/Backend ProtocolUpMessage Flow
\ No newline at end of file diff --git a/doc/src/sgml/html/protocol-replication.html b/doc/src/sgml/html/protocol-replication.html new file mode 100644 index 000000000..2dcfede16 --- /dev/null +++ b/doc/src/sgml/html/protocol-replication.html @@ -0,0 +1,773 @@ + +Streaming Replication Protocol
PostgreSQL 9.2.2 Documentation
PrevUpChapter 46. Frontend/Backend ProtocolNext

46.3. Streaming Replication Protocol

To initiate streaming replication, the frontend sends the +replication parameter in the startup message. This tells the +backend to go into walsender mode, wherein a small set of replication commands +can be issued instead of SQL statements. Only the simple query protocol can be +used in walsender mode. + +The commands accepted in walsender mode are: + +

IDENTIFY_SYSTEM

Requests the server to identify itself. Server replies with a result + set of a single row, containing three fields: +

systemid

The unique system identifier identifying the cluster. This + can be used to check that the base backup used to initialize the + standby came from the same cluster. +

timeline

Current TimelineID. Also useful to check that the standby is + consistent with the master. +

xlogpos

Current xlog write location. Useful to get a known location in the + transaction log where streaming can start. +

+

START_REPLICATION XXX/XXX

Instructs server to start streaming WAL, starting at + WAL position XXX/XXX. + The server can reply with an error, e.g. if the requested section of WAL + has already been recycled. On success, server responds with a + CopyBothResponse message, and then starts to stream WAL to the frontend. + WAL will continue to be streamed until the connection is broken; + no further commands will be accepted. +

WAL data is sent as a series of CopyData messages. (This allows + other information to be intermixed; in particular the server can send + an ErrorResponse message if it encounters a failure after beginning + to stream.) The payload in each CopyData message follows this format: +

XLogData (B)

Byte1('w')

Identifies the message as WAL data. +

Byte8

The starting point of the WAL data in this message, given in + XLogRecPtr format. +

Byte8

The current end of WAL on the server, given in + XLogRecPtr format. +

Byte8

The server's system clock at the time of transmission, + given in TimestampTz format. +

Byten

A section of the WAL data stream. +

+

+

A single WAL record is never split across two CopyData messages. + When a WAL record crosses a WAL page boundary, and is therefore + already split using continuation records, it can be split at the page + boundary. In other words, the first main WAL record and its + continuation records can be sent in different CopyData messages. +

Note that all fields within the WAL data and the above-described header + will be in the sending server's native format. Endianness, and the + format for the timestamp, are unpredictable unless the receiver has + verified that the sender's system identifier matches its own + pg_control contents. +

If the WAL sender process is terminated normally (during postmaster + shutdown), it will send a CommandComplete message before exiting. + This might not happen during an abnormal shutdown, of course. +

The receiving process can send replies back to the sender at any time, + using one of the following message formats (also in the payload of a + CopyData message): +

Primary keepalive message (B)

Byte1('k')

Identifies the message as a sender keepalive. +

Byte8

The current end of WAL on the server, given in + XLogRecPtr format. +

Byte8

The server's system clock at the time of transmission, + given in TimestampTz format. +

+

+

Standby status update (F)

Byte1('r')

Identifies the message as a receiver status update. +

Byte8

The location of the last WAL byte + 1 received and written to disk + in the standby, in XLogRecPtr format. +

Byte8

The location of the last WAL byte + 1 flushed to disk in + the standby, in XLogRecPtr format. +

Byte8

The location of the last WAL byte + 1 applied in the standby, in + XLogRecPtr format. +

Byte8

The server's system clock at the time of transmission, + given in TimestampTz format. +

+

+

Hot Standby feedback message (F)

Byte1('h')

Identifies the message as a Hot Standby feedback message. +

Byte8

The server's system clock at the time of transmission, + given in TimestampTz format. +

Byte4

The standby's current xmin. +

Byte4

The standby's current epoch. +

+

+

BASE_BACKUP [LABEL 'label'] [PROGRESS] [FAST] [WAL] [NOWAIT]

Instructs the server to start streaming a base backup. + The system will automatically be put in backup mode before the backup + is started, and taken out of it when the backup is complete. The + following options are accepted: +

LABEL 'label'

Sets the label of the backup. If none is specified, a backup label + of base backup will be used. The quoting rules + for the label are the same as a standard SQL string with + standard_conforming_strings turned on. +

PROGRESS

Request information required to generate a progress report. This will + send back an approximate size in the header of each tablespace, which + can be used to calculate how far along the stream is done. This is + calculated by enumerating all the file sizes once before the transfer + is even started, and may as such have a negative impact on the + performance - in particular it may take longer before the first data + is streamed. Since the database files can change during the backup, + the size is only approximate and may both grow and shrink between + the time of approximation and the sending of the actual files. +

FAST

Request a fast checkpoint. +

WAL

Include the necessary WAL segments in the backup. This will include + all the files between start and stop backup in the + pg_xlog directory of the base directory tar + file. +

NOWAIT

By default, the backup will wait until the last required xlog + segment has been archived, or emit a warning if log archiving is + not enabled. Specifying NOWAIT disables both + the waiting and the warning, leaving the client responsible for + ensuring the required log is available. +

+

When the backup is started, the server will first send two + ordinary result sets, followed by one or more CopyResponse + results. +

The first ordinary result set contains the starting position of the + backup, given in XLogRecPtr format as a single column in a single row. +

The second ordinary result set has one row for each tablespace. + The fields in this row are: +

spcoid

The oid of the tablespace, or NULL if it's the base + directory. +

spclocation

The full path of the tablespace directory, or NULL + if it's the base directory. +

size

The approximate size of the tablespace, if progress report has + been requested; otherwise it's NULL. +

+

After the second regular result set, one or more CopyResponse results + will be sent, one for PGDATA and one for each additional tablespace other + than pg_default and pg_global. The data in + the CopyResponse results will be a tar format (following the + "ustar interchange format" specified in the POSIX 1003.1-2008 + standard) dump of the tablespace contents, except that the two trailing + blocks of zeroes specified in the standard are omitted. + After the tar data is complete, a final ordinary result set will be sent. +

The tar archive for the data directory and each tablespace will contain + all files in the directories, regardless of whether they are + PostgreSQL files or other files added to the same + directory. The only excluded files are: +

  • postmaster.pid +

  • postmaster.opts +

  • pg_xlog, including subdirectories. If the backup is run + with WAL files included, a synthesized version of pg_xlog will be + included, but it will only contain the files necessary for the + backup to work, not the rest of the contents. +

+ Owner, group and file mode are set if the underlying file system on + the server supports it. +

Once all tablespaces have been sent, a final regular result set will + be sent. This result set contains the end position of the + backup, given in XLogRecPtr format as a single column in a single row. +


PrevHomeNext
Message FlowUpMessage Data Types
\ No newline at end of file diff --git a/doc/src/sgml/html/protocol.html b/doc/src/sgml/html/protocol.html new file mode 100644 index 000000000..f4a024c7b --- /dev/null +++ b/doc/src/sgml/html/protocol.html @@ -0,0 +1,335 @@ + +Frontend/Backend Protocol

Chapter 46. Frontend/Backend Protocol

PostgreSQL uses a message-based protocol + for communication between frontends and backends (clients and servers). + The protocol is supported over TCP/IP and also over + Unix-domain sockets. Port number 5432 has been registered with IANA as + the customary TCP port number for servers supporting this protocol, but + in practice any non-privileged port number can be used. +

This document describes version 3.0 of the protocol, implemented in + PostgreSQL 7.4 and later. For descriptions + of the earlier protocol versions, see previous releases of the + PostgreSQL documentation. A single server + can support multiple protocol versions. The initial + startup-request message tells the server which protocol version the + client is attempting to use, and then the server follows that protocol + if it is able. +

In order to serve multiple clients efficiently, the server launches + a new "backend" process for each client. + In the current implementation, a new child + process is created immediately after an incoming connection is detected. + This is transparent to the protocol, however. For purposes of the + protocol, the terms "backend" and "server" are + interchangeable; likewise "frontend" and "client" + are interchangeable. +


PrevHomeNext
pg_viewsUpOverview
\ No newline at end of file diff --git a/doc/src/sgml/html/queries-limit.html b/doc/src/sgml/html/queries-limit.html new file mode 100644 index 000000000..d00c5bdd3 --- /dev/null +++ b/doc/src/sgml/html/queries-limit.html @@ -0,0 +1,334 @@ + +LIMIT and OFFSET

7.6. LIMIT and OFFSET

LIMIT and OFFSET allow you to retrieve just + a portion of the rows that are generated by the rest of the query: +

SELECT select_list
+    FROM table_expression
+    [ ORDER BY ... ]
+    [ LIMIT { number | ALL } ] [ OFFSET number ]

+

If a limit count is given, no more than that many rows will be + returned (but possibly less, if the query itself yields less rows). + LIMIT ALL is the same as omitting the LIMIT + clause. +

OFFSET says to skip that many rows before beginning to + return rows. OFFSET 0 is the same as omitting the + OFFSET clause, and LIMIT NULL is the same + as omitting the LIMIT clause. If both OFFSET + and LIMIT appear, then OFFSET rows are + skipped before starting to count the LIMIT rows that + are returned. +

When using LIMIT, it is important to use an + ORDER BY clause that constrains the result rows into a + unique order. Otherwise you will get an unpredictable subset of + the query's rows. You might be asking for the tenth through + twentieth rows, but tenth through twentieth in what ordering? The + ordering is unknown, unless you specified ORDER BY. +

The query optimizer takes LIMIT into account when + generating query plans, so you are very likely to get different + plans (yielding different row orders) depending on what you give + for LIMIT and OFFSET. Thus, using + different LIMIT/OFFSET values to select + different subsets of a query result will give + inconsistent results unless you enforce a predictable + result ordering with ORDER BY. This is not a bug; it + is an inherent consequence of the fact that SQL does not promise to + deliver the results of a query in any particular order unless + ORDER BY is used to constrain the order. +

The rows skipped by an OFFSET clause still have to be + computed inside the server; therefore a large OFFSET + might be inefficient. +


PrevHomeNext
Sorting RowsUpVALUES Lists
\ No newline at end of file diff --git a/doc/src/sgml/html/queries-order.html b/doc/src/sgml/html/queries-order.html new file mode 100644 index 000000000..8afe06be7 --- /dev/null +++ b/doc/src/sgml/html/queries-order.html @@ -0,0 +1,415 @@ + +Sorting Rows

7.5. Sorting Rows

After a query has produced an output table (after the select list + has been processed) it can optionally be sorted. If sorting is not + chosen, the rows will be returned in an unspecified order. The actual + order in that case will depend on the scan and join plan types and + the order on disk, but it must not be relied on. A particular + output ordering can only be guaranteed if the sort step is explicitly + chosen. +

The ORDER BY clause specifies the sort order: +

SELECT select_list
+    FROM table_expression
+    ORDER BY sort_expression1 [ASC | DESC] [NULLS { FIRST | LAST }]
+             [, sort_expression2 [ASC | DESC] [NULLS { FIRST | LAST }] ...]

+ The sort expression(s) can be any expression that would be valid in the + query's select list. An example is: +

SELECT a, b FROM table1 ORDER BY a + b, c;

+ When more than one expression is specified, + the later values are used to sort rows that are equal according to the + earlier values. Each expression can be followed by an optional + ASC or DESC keyword to set the sort direction to + ascending or descending. ASC order is the default. + Ascending order puts smaller values first, where + "smaller" is defined in terms of the + < operator. Similarly, descending order is + determined with the > operator. + [1] +

The NULLS FIRST and NULLS LAST options can be + used to determine whether nulls appear before or after non-null values + in the sort ordering. By default, null values sort as if larger than any + non-null value; that is, NULLS FIRST is the default for + DESC order, and NULLS LAST otherwise. +

Note that the ordering options are considered independently for each + sort column. For example ORDER BY x, y DESC means + ORDER BY x ASC, y DESC, which is not the same as + ORDER BY x DESC, y DESC. +

A sort_expression can also be the column label or number + of an output column, as in: +

SELECT a + b AS sum, c FROM table1 ORDER BY sum;
+SELECT a, max(b) FROM table1 GROUP BY a ORDER BY 1;

+ both of which sort by the first output column. Note that an output + column name has to stand alone, that is, it cannot be used in an expression + — for example, this is not correct: +

SELECT a + b AS sum, c FROM table1 ORDER BY sum + c;          -- wrong

+ This restriction is made to reduce ambiguity. There is still + ambiguity if an ORDER BY item is a simple name that + could match either an output column name or a column from the table + expression. The output column is used in such cases. This would + only cause confusion if you use AS to rename an output + column to match some other table column's name. +

ORDER BY can be applied to the result of a + UNION, INTERSECT, or EXCEPT + combination, but in this case it is only permitted to sort by + output column names or numbers, not by expressions. +

Notes

[1]

Actually, PostgreSQL uses the default B-tree + operator class for the expression's data type to determine the sort + ordering for ASC and DESC. Conventionally, + data types will be set up so that the < and + > operators correspond to this sort ordering, + but a user-defined data type's designer could choose to do something + different. +


PrevHomeNext
Combining QueriesUpLIMIT and OFFSET
\ No newline at end of file diff --git a/doc/src/sgml/html/queries-overview.html b/doc/src/sgml/html/queries-overview.html new file mode 100644 index 000000000..e65dc0424 --- /dev/null +++ b/doc/src/sgml/html/queries-overview.html @@ -0,0 +1,299 @@ + +Overview

7.1. Overview

The process of retrieving or the command to retrieve data from a + database is called a query. In SQL the + SELECT command is + used to specify queries. The general syntax of the + SELECT command is +

[WITH with_queries] SELECT select_list FROM table_expression [sort_specification]

+ The following sections describe the details of the select list, the + table expression, and the sort specification. WITH + queries are treated last since they are an advanced feature. +

A simple kind of query has the form: +

SELECT * FROM table1;

+ Assuming that there is a table called table1, + this command would retrieve all rows and all user-defined columns from + table1. (The method of retrieval depends on the + client application. For example, the + psql program will display an ASCII-art + table on the screen, while client libraries will offer functions to + extract individual values from the query result.) The select list + specification * means all columns that the table + expression happens to provide. A select list can also select a + subset of the available columns or make calculations using the + columns. For example, if + table1 has columns named a, + b, and c (and perhaps others) you can make + the following query: +

SELECT a, b + c FROM table1;

+ (assuming that b and c are of a numerical + data type). + See Section 7.3 for more details. +

FROM table1 is a simple kind of + table expression: it reads just one table. In general, table + expressions can be complex constructs of base tables, joins, and + subqueries. But you can also omit the table expression entirely and + use the SELECT command as a calculator: +

SELECT 3 * 4;

+ This is more useful if the expressions in the select list return + varying results. For example, you could call a function this way: +

SELECT random();

+


PrevHomeNext
QueriesUpTable Expressions
\ No newline at end of file diff --git a/doc/src/sgml/html/queries-select-lists.html b/doc/src/sgml/html/queries-select-lists.html new file mode 100644 index 000000000..9eda69584 --- /dev/null +++ b/doc/src/sgml/html/queries-select-lists.html @@ -0,0 +1,468 @@ + +Select Lists

7.3. Select Lists

As shown in the previous section, + the table expression in the SELECT command + constructs an intermediate virtual table by possibly combining + tables, views, eliminating rows, grouping, etc. This table is + finally passed on to processing by the select list. The select + list determines which columns of the + intermediate table are actually output. +

7.3.1. Select-List Items

The simplest kind of select list is * which + emits all columns that the table expression produces. Otherwise, + a select list is a comma-separated list of value expressions (as + defined in Section 4.2). For instance, it + could be a list of column names: +

SELECT a, b, c FROM ...

+ The columns names a, b, and c + are either the actual names of the columns of tables referenced + in the FROM clause, or the aliases given to them as + explained in Section 7.2.1.2. The name + space available in the select list is the same as in the + WHERE clause, unless grouping is used, in which case + it is the same as in the HAVING clause. +

If more than one table has a column of the same name, the table + name must also be given, as in: +

SELECT tbl1.a, tbl2.a, tbl1.b FROM ...

+ When working with multiple tables, it can also be useful to ask for + all the columns of a particular table: +

SELECT tbl1.*, tbl2.a FROM ...

+ (See also Section 7.2.2.) +

If an arbitrary value expression is used in the select list, it + conceptually adds a new virtual column to the returned table. The + value expression is evaluated once for each result row, with + the row's values substituted for any column references. But the + expressions in the select list do not have to reference any + columns in the table expression of the FROM clause; + they can be constant arithmetic expressions, for instance. +

7.3.2. Column Labels

The entries in the select list can be assigned names for subsequent + processing, such as for use in an ORDER BY clause + or for display by the client application. For example: +

SELECT a AS value, b + c AS sum FROM ...

+

If no output column name is specified using AS, + the system assigns a default column name. For simple column references, + this is the name of the referenced column. For function + calls, this is the name of the function. For complex expressions, + the system will generate a generic name. +

The AS keyword is optional, but only if the new column + name does not match any + PostgreSQL keyword (see Appendix C). To avoid an accidental match to + a keyword, you can double-quote the column name. For example, + VALUE is a keyword, so this does not work: +

SELECT a value, b + c AS sum FROM ...

+ but this does: +

SELECT a "value", b + c AS sum FROM ...

+ For protection against possible + future keyword additions, it is recommended that you always either + write AS or double-quote the output column name. +

Note: The naming of output columns here is different from that done in + the FROM clause (see Section 7.2.1.2). It is possible + to rename the same column twice, but the name assigned in + the select list is the one that will be passed on. +

7.3.3. DISTINCT

After the select list has been processed, the result table can + optionally be subject to the elimination of duplicate rows. The + DISTINCT key word is written directly after + SELECT to specify this: +

SELECT DISTINCT select_list ...

+ (Instead of DISTINCT the key word ALL + can be used to specify the default behavior of retaining all rows.) +

Obviously, two rows are considered distinct if they differ in at + least one column value. Null values are considered equal in this + comparison. +

Alternatively, an arbitrary expression can determine what rows are + to be considered distinct: +

SELECT DISTINCT ON (expression [, expression ...]) select_list ...

+ Here expression is an arbitrary value + expression that is evaluated for all rows. A set of rows for + which all the expressions are equal are considered duplicates, and + only the first row of the set is kept in the output. Note that + the "first row" of a set is unpredictable unless the + query is sorted on enough columns to guarantee a unique ordering + of the rows arriving at the DISTINCT filter. + (DISTINCT ON processing occurs after ORDER + BY sorting.) +

The DISTINCT ON clause is not part of the SQL standard + and is sometimes considered bad style because of the potentially + indeterminate nature of its results. With judicious use of + GROUP BY and subqueries in FROM, this + construct can be avoided, but it is often the most convenient + alternative. +


PrevHomeNext
Table ExpressionsUpCombining Queries
\ No newline at end of file diff --git a/doc/src/sgml/html/queries-table-expressions.html b/doc/src/sgml/html/queries-table-expressions.html new file mode 100644 index 000000000..980780af0 --- /dev/null +++ b/doc/src/sgml/html/queries-table-expressions.html @@ -0,0 +1,1919 @@ + +Table Expressions

7.2. Table Expressions

A table expression computes a table. The + table expression contains a FROM clause that is + optionally followed by WHERE, GROUP BY, and + HAVING clauses. Trivial table expressions simply refer + to a table on disk, a so-called base table, but more complex + expressions can be used to modify or combine base tables in various + ways. +

The optional WHERE, GROUP BY, and + HAVING clauses in the table expression specify a + pipeline of successive transformations performed on the table + derived in the FROM clause. All these transformations + produce a virtual table that provides the rows that are passed to + the select list to compute the output rows of the query. +

7.2.1. The FROM Clause

The FROM Clause derives a + table from one or more other tables given in a comma-separated + table reference list. +

FROM table_reference [, table_reference [, ...]]

+ + A table reference can be a table name (possibly schema-qualified), + or a derived table such as a subquery, a table join, or complex + combinations of these. If more than one table reference is listed + in the FROM clause they are cross-joined (see below) + to form the intermediate virtual table that can then be subject to + transformations by the WHERE, GROUP BY, + and HAVING clauses and is finally the result of the + overall table expression. +

When a table reference names a table that is the parent of a + table inheritance hierarchy, the table reference produces rows of + not only that table but all of its descendant tables, unless the + key word ONLY precedes the table name. However, the + reference produces only the columns that appear in the named table + — any columns added in subtables are ignored. +

Instead of writing ONLY before the table name, you can write + * after the table name to explicitly specify that descendant + tables are included. Writing * is not necessary since that + behavior is the default (unless you have changed the setting of the sql_inheritance configuration option). However writing + * might be useful to emphasize that additional tables will be + searched. +

7.2.1.1. Joined Tables

A joined table is a table derived from two other (real or + derived) tables according to the rules of the particular join + type. Inner, outer, and cross-joins are available. +

Join Types

Cross join
T1 CROSS JOIN T2

For every possible combination of rows from + T1 and + T2 (i.e., a Cartesian product), + the joined table will contain a + row consisting of all columns in T1 + followed by all columns in T2. If + the tables have N and M rows respectively, the joined + table will have N * M rows. +

FROM T1 CROSS JOIN + T2 is equivalent to + FROM T1, + T2. It is also equivalent to + FROM T1 INNER JOIN + T2 ON TRUE (see below). +

Qualified joins
T1 { [INNER] | { LEFT | RIGHT | FULL } [OUTER] } JOIN T2 ON boolean_expression
+T1 { [INNER] | { LEFT | RIGHT | FULL } [OUTER] } JOIN T2 USING ( join column list )
+T1 NATURAL { [INNER] | { LEFT | RIGHT | FULL } [OUTER] } JOIN T2

The words INNER and + OUTER are optional in all forms. + INNER is the default; + LEFT, RIGHT, and + FULL imply an outer join. +

The join condition is specified in the + ON or USING clause, or implicitly by + the word NATURAL. The join condition determines + which rows from the two source tables are considered to + "match", as explained in detail below. +

The ON clause is the most general kind of join + condition: it takes a Boolean value expression of the same + kind as is used in a WHERE clause. A pair of rows + from T1 and T2 match if the + ON expression evaluates to true for them. +

USING is a shorthand notation: it takes a + comma-separated list of column names, which the joined tables + must have in common, and forms a join condition specifying + equality of each of these pairs of columns. Furthermore, the + output of JOIN USING has one column for each of + the equated pairs of input columns, followed by the + remaining columns from each table. Thus, USING (a, b, + c) is equivalent to ON (t1.a = t2.a AND + t1.b = t2.b AND t1.c = t2.c) with the exception that + if ON is used there will be two columns + a, b, and c in the result, + whereas with USING there will be only one of each + (and they will appear first if SELECT * is used). +

+ + Finally, NATURAL is a shorthand form of + USING: it forms a USING list + consisting of all column names that appear in both + input tables. As with USING, these columns appear + only once in the output table. If there are no common + columns, NATURAL behaves like + CROSS JOIN. +

The possible types of qualified join are: + +

INNER JOIN

For each row R1 of T1, the joined table has a row for each + row in T2 that satisfies the join condition with R1. +

LEFT OUTER JOIN

First, an inner join is performed. Then, for each row in + T1 that does not satisfy the join condition with any row in + T2, a joined row is added with null values in columns of + T2. Thus, the joined table always has at least + one row for each row in T1. +

RIGHT OUTER JOIN

First, an inner join is performed. Then, for each row in + T2 that does not satisfy the join condition with any row in + T1, a joined row is added with null values in columns of + T1. This is the converse of a left join: the result table + will always have a row for each row in T2. +

FULL OUTER JOIN

First, an inner join is performed. Then, for each row in + T1 that does not satisfy the join condition with any row in + T2, a joined row is added with null values in columns of + T2. Also, for each row of T2 that does not satisfy the + join condition with any row in T1, a joined row with null + values in the columns of T1 is added. +

+

Joins of all types can be chained together or nested: either or + both T1 and + T2 can be joined tables. Parentheses + can be used around JOIN clauses to control the join + order. In the absence of parentheses, JOIN clauses + nest left-to-right. +

To put this together, assume we have tables t1: +

 num | name
+-----+------
+   1 | a
+   2 | b
+   3 | c

+ and t2: +

 num | value
+-----+-------
+   1 | xxx
+   3 | yyy
+   5 | zzz

+ then we get the following results for the various joins: +

=> SELECT * FROM t1 CROSS JOIN t2;
+ num | name | num | value
+-----+------+-----+-------
+   1 | a    |   1 | xxx
+   1 | a    |   3 | yyy
+   1 | a    |   5 | zzz
+   2 | b    |   1 | xxx
+   2 | b    |   3 | yyy
+   2 | b    |   5 | zzz
+   3 | c    |   1 | xxx
+   3 | c    |   3 | yyy
+   3 | c    |   5 | zzz
+(9 rows)
+
+=> SELECT * FROM t1 INNER JOIN t2 ON t1.num = t2.num;
+ num | name | num | value
+-----+------+-----+-------
+   1 | a    |   1 | xxx
+   3 | c    |   3 | yyy
+(2 rows)
+
+=> SELECT * FROM t1 INNER JOIN t2 USING (num);
+ num | name | value
+-----+------+-------
+   1 | a    | xxx
+   3 | c    | yyy
+(2 rows)
+
+=> SELECT * FROM t1 NATURAL INNER JOIN t2;
+ num | name | value
+-----+------+-------
+   1 | a    | xxx
+   3 | c    | yyy
+(2 rows)
+
+=> SELECT * FROM t1 LEFT JOIN t2 ON t1.num = t2.num;
+ num | name | num | value
+-----+------+-----+-------
+   1 | a    |   1 | xxx
+   2 | b    |     |
+   3 | c    |   3 | yyy
+(3 rows)
+
+=> SELECT * FROM t1 LEFT JOIN t2 USING (num);
+ num | name | value
+-----+------+-------
+   1 | a    | xxx
+   2 | b    |
+   3 | c    | yyy
+(3 rows)
+
+=> SELECT * FROM t1 RIGHT JOIN t2 ON t1.num = t2.num;
+ num | name | num | value
+-----+------+-----+-------
+   1 | a    |   1 | xxx
+   3 | c    |   3 | yyy
+     |      |   5 | zzz
+(3 rows)
+
+=> SELECT * FROM t1 FULL JOIN t2 ON t1.num = t2.num;
+ num | name | num | value
+-----+------+-----+-------
+   1 | a    |   1 | xxx
+   2 | b    |     |
+   3 | c    |   3 | yyy
+     |      |   5 | zzz
+(4 rows)

+

The join condition specified with ON can also contain + conditions that do not relate directly to the join. This can + prove useful for some queries but needs to be thought out + carefully. For example: +

=> SELECT * FROM t1 LEFT JOIN t2 ON t1.num = t2.num AND t2.value = 'xxx';
+ num | name | num | value
+-----+------+-----+-------
+   1 | a    |   1 | xxx
+   2 | b    |     |
+   3 | c    |     |
+(3 rows)

+ Notice that placing the restriction in the WHERE clause + produces a different result: +

=> SELECT * FROM t1 LEFT JOIN t2 ON t1.num = t2.num WHERE t2.value = 'xxx';
+ num | name | num | value
+-----+------+-----+-------
+   1 | a    |   1 | xxx
+(1 row)

+ This is because a restriction placed in the ON + clause is processed before the join, while + a restriction placed in the WHERE clause is processed + after the join. +

7.2.1.2. Table and Column Aliases

A temporary name can be given to tables and complex table + references to be used for references to the derived table in + the rest of the query. This is called a table + alias. +

To create a table alias, write +

FROM table_reference AS alias

+ or +

FROM table_reference alias

+ The AS key word is optional noise. + alias can be any identifier. +

A typical application of table aliases is to assign short + identifiers to long table names to keep the join clauses + readable. For example: +

SELECT * FROM some_very_long_table_name s JOIN another_fairly_long_name a ON s.id = a.num;

+

The alias becomes the new name of the table reference so far as the + current query is concerned — it is not allowed to refer to the + table by the original name elsewhere in the query. Thus, this is not + valid: +

SELECT * FROM my_table AS m WHERE my_table.a > 5;    -- wrong

+

Table aliases are mainly for notational convenience, but it is + necessary to use them when joining a table to itself, e.g.: +

SELECT * FROM people AS mother JOIN people AS child ON mother.id = child.mother_id;

+ Additionally, an alias is required if the table reference is a + subquery (see Section 7.2.1.3). +

Parentheses are used to resolve ambiguities. In the following example, + the first statement assigns the alias b to the second + instance of my_table, but the second statement assigns the + alias to the result of the join: +

SELECT * FROM my_table AS a CROSS JOIN my_table AS b ...
+SELECT * FROM (my_table AS a CROSS JOIN my_table) AS b ...

+

Another form of table aliasing gives temporary names to the columns of + the table, as well as the table itself: +

FROM table_reference [AS] alias ( column1 [, column2 [, ...]] )

+ If fewer column aliases are specified than the actual table has + columns, the remaining columns are not renamed. This syntax is + especially useful for self-joins or subqueries. +

When an alias is applied to the output of a JOIN + clause, the alias hides the original + name(s) within the JOIN. For example: +

SELECT a.* FROM my_table AS a JOIN your_table AS b ON ...

+ is valid SQL, but: +

SELECT a.* FROM (my_table AS a JOIN your_table AS b ON ...) AS c

+ is not valid; the table alias a is not visible + outside the alias c. +

7.2.1.3. Subqueries

Subqueries specifying a derived table must be enclosed in + parentheses and must be assigned a table + alias name. (See Section 7.2.1.2.) For + example: +

FROM (SELECT * FROM table1) AS alias_name

+

This example is equivalent to FROM table1 AS + alias_name. More interesting cases, which cannot be + reduced to a plain join, arise when the subquery involves + grouping or aggregation. +

A subquery can also be a VALUES list: +

FROM (VALUES ('anne', 'smith'), ('bob', 'jones'), ('joe', 'blow'))
+     AS names(first, last)

+ Again, a table alias is required. Assigning alias names to the columns + of the VALUES list is optional, but is good practice. + For more information see Section 7.7. +

7.2.1.4. Table Functions

Table functions are functions that produce a set of rows, made up + of either base data types (scalar types) or composite data types + (table rows). They are used like a table, view, or subquery in + the FROM clause of a query. Columns returned by table + functions can be included in SELECT, + JOIN, or WHERE clauses in the same manner + as a table, view, or subquery column. +

If a table function returns a base data type, the single result + column name matches the function name. If the function returns a + composite type, the result columns get the same names as the + individual attributes of the type. +

A table function can be aliased in the FROM clause, + but it also can be left unaliased. If a function is used in the + FROM clause with no alias, the function name is used + as the resulting table name. +

Some examples: +

CREATE TABLE foo (fooid int, foosubid int, fooname text);
+
+CREATE FUNCTION getfoo(int) RETURNS SETOF foo AS $$
+    SELECT * FROM foo WHERE fooid = $1;
+$$ LANGUAGE SQL;
+
+SELECT * FROM getfoo(1) AS t1;
+
+SELECT * FROM foo
+    WHERE foosubid IN (
+                        SELECT foosubid
+                        FROM getfoo(foo.fooid) z
+                        WHERE z.fooid = foo.fooid
+                      );
+
+CREATE VIEW vw_getfoo AS SELECT * FROM getfoo(1);
+
+SELECT * FROM vw_getfoo;

+

In some cases it is useful to define table functions that can + return different column sets depending on how they are invoked. + To support this, the table function can be declared as returning + the pseudotype record. When such a function is used in + a query, the expected row structure must be specified in the + query itself, so that the system can know how to parse and plan + the query. Consider this example: +

SELECT *
+    FROM dblink('dbname=mydb', 'SELECT proname, prosrc FROM pg_proc')
+      AS t1(proname name, prosrc text)
+    WHERE proname LIKE 'bytea%';

+ The dblink function + (part of the dblink module>) executes + a remote query. It is declared to return + record since it might be used for any kind of query. + The actual column set must be specified in the calling query so + that the parser knows, for example, what * should + expand to. +

7.2.2. The WHERE Clause

The syntax of the WHERE Clause is +

WHERE search_condition

+ where search_condition is any value + expression (see Section 4.2) that + returns a value of type boolean. +

After the processing of the FROM clause is done, each + row of the derived virtual table is checked against the search + condition. If the result of the condition is true, the row is + kept in the output table, otherwise (i.e., if the result is + false or null) it is discarded. The search condition typically + references at least one column of the table generated in the + FROM clause; this is not required, but otherwise the + WHERE clause will be fairly useless. +

Note: The join condition of an inner join can be written either in + the WHERE clause or in the JOIN clause. + For example, these table expressions are equivalent: +

FROM a, b WHERE a.id = b.id AND b.val > 5

+ and: +

FROM a INNER JOIN b ON (a.id = b.id) WHERE b.val > 5

+ or perhaps even: +

FROM a NATURAL JOIN b WHERE b.val > 5

+ Which one of these you use is mainly a matter of style. The + JOIN syntax in the FROM clause is + probably not as portable to other SQL database management systems, + even though it is in the SQL standard. For + outer joins there is no choice: they must be done in + the FROM clause. The ON or USING + clause of an outer join is not equivalent to a + WHERE condition, because it results in the addition + of rows (for unmatched input rows) as well as the removal of rows + in the final result. +

Here are some examples of WHERE clauses: +

SELECT ... FROM fdt WHERE c1 > 5
+
+SELECT ... FROM fdt WHERE c1 IN (1, 2, 3)
+
+SELECT ... FROM fdt WHERE c1 IN (SELECT c1 FROM t2)
+
+SELECT ... FROM fdt WHERE c1 IN (SELECT c3 FROM t2 WHERE c2 = fdt.c1 + 10)
+
+SELECT ... FROM fdt WHERE c1 BETWEEN (SELECT c3 FROM t2 WHERE c2 = fdt.c1 + 10) AND 100
+
+SELECT ... FROM fdt WHERE EXISTS (SELECT c1 FROM t2 WHERE c2 > fdt.c1)

+ fdt is the table derived in the + FROM clause. Rows that do not meet the search + condition of the WHERE clause are eliminated from + fdt. Notice the use of scalar subqueries as + value expressions. Just like any other query, the subqueries can + employ complex table expressions. Notice also how + fdt is referenced in the subqueries. + Qualifying c1 as fdt.c1 is only necessary + if c1 is also the name of a column in the derived + input table of the subquery. But qualifying the column name adds + clarity even when it is not needed. This example shows how the column + naming scope of an outer query extends into its inner queries. +

7.2.3. The GROUP BY and HAVING Clauses

After passing the WHERE filter, the derived input + table might be subject to grouping, using the GROUP BY + clause, and elimination of group rows using the HAVING + clause. +

SELECT select_list
+    FROM ...
+    [WHERE ...]
+    GROUP BY grouping_column_reference [, grouping_column_reference]...

The GROUP BY Clause is + used to group together those rows in a table that have the same + values in all the columns listed. The order in which the columns + are listed does not matter. The effect is to combine each set + of rows having common values into one group row that + represents all rows in the group. This is done to + eliminate redundancy in the output and/or compute aggregates that + apply to these groups. For instance: +

=> SELECT * FROM test1;
+ x | y
+---+---
+ a | 3
+ c | 2
+ b | 5
+ a | 1
+(4 rows)
+
+=> SELECT x FROM test1 GROUP BY x;
+ x
+---
+ a
+ b
+ c
+(3 rows)

+

In the second query, we could not have written SELECT * + FROM test1 GROUP BY x, because there is no single value + for the column y that could be associated with each + group. The grouped-by columns can be referenced in the select list since + they have a single value in each group. +

In general, if a table is grouped, columns that are not + listed in GROUP BY cannot be referenced except in aggregate + expressions. An example with aggregate expressions is: +

=> SELECT x, sum(y) FROM test1 GROUP BY x;
+ x | sum
+---+-----
+ a |   4
+ b |   5
+ c |   2
+(3 rows)

+ Here sum is an aggregate function that + computes a single value over the entire group. More information + about the available aggregate functions can be found in Section 9.20. +

Tip: Grouping without aggregate expressions effectively calculates the + set of distinct values in a column. This can also be achieved + using the DISTINCT clause (see Section 7.3.3). +

Here is another example: it calculates the total sales for each + product (rather than the total sales of all products): +

SELECT product_id, p.name, (sum(s.units) * p.price) AS sales
+    FROM products p LEFT JOIN sales s USING (product_id)
+    GROUP BY product_id, p.name, p.price;

+ In this example, the columns product_id, + p.name, and p.price must be + in the GROUP BY clause since they are referenced in + the query select list (but see below). The column + s.units does not have to be in the GROUP + BY list since it is only used in an aggregate expression + (sum(...)), which represents the sales + of a product. For each product, the query returns a summary row about + all sales of the product. +

If the products table is set up so that, say, + product_id is the primary key, then it would be + enough to group by product_id in the above example, + since name and price would be functionally + dependent on the product ID, and so there would be no + ambiguity about which name and price value to return for each product + ID group. +

In strict SQL, GROUP BY can only group by columns of + the source table but PostgreSQL extends + this to also allow GROUP BY to group by columns in the + select list. Grouping by value expressions instead of simple + column names is also allowed. +

If a table has been grouped using GROUP BY, + but only certain groups are of interest, the + HAVING clause can be used, much like a + WHERE clause, to eliminate groups from the result. + The syntax is: +

SELECT select_list FROM ... [WHERE ...] GROUP BY ... HAVING boolean_expression

+ Expressions in the HAVING clause can refer both to + grouped expressions and to ungrouped expressions (which necessarily + involve an aggregate function). +

Example: +

=> SELECT x, sum(y) FROM test1 GROUP BY x HAVING sum(y) > 3;
+ x | sum
+---+-----
+ a |   4
+ b |   5
+(2 rows)
+
+=> SELECT x, sum(y) FROM test1 GROUP BY x HAVING x < 'c';
+ x | sum
+---+-----
+ a |   4
+ b |   5
+(2 rows)

+

Again, a more realistic example: +

SELECT product_id, p.name, (sum(s.units) * (p.price - p.cost)) AS profit
+    FROM products p LEFT JOIN sales s USING (product_id)
+    WHERE s.date > CURRENT_DATE - INTERVAL '4 weeks'
+    GROUP BY product_id, p.name, p.price, p.cost
+    HAVING sum(p.price * s.units) > 5000;

+ In the example above, the WHERE clause is selecting + rows by a column that is not grouped (the expression is only true for + sales during the last four weeks), while the HAVING + clause restricts the output to groups with total gross sales over + 5000. Note that the aggregate expressions do not necessarily need + to be the same in all parts of the query. +

If a query contains aggregate function calls, but no GROUP BY + clause, grouping still occurs: the result is a single group row (or + perhaps no rows at all, if the single row is then eliminated by + HAVING). + The same is true if it contains a HAVING clause, even + without any aggregate function calls or GROUP BY clause. +

7.2.4. Window Function Processing

If the query contains any window functions (see + Section 3.5, + Section 9.21 and + Section 4.2.8), these functions are evaluated + after any grouping, aggregation, and HAVING filtering is + performed. That is, if the query uses any aggregates, GROUP + BY, or HAVING, then the rows seen by the window functions + are the group rows instead of the original table rows from + FROM/WHERE. +

When multiple window functions are used, all the window functions having + syntactically equivalent PARTITION BY and ORDER BY + clauses in their window definitions are guaranteed to be evaluated in a + single pass over the data. Therefore they will see the same sort ordering, + even if the ORDER BY does not uniquely determine an ordering. + However, no guarantees are made about the evaluation of functions having + different PARTITION BY or ORDER BY specifications. + (In such cases a sort step is typically required between the passes of + window function evaluations, and the sort is not guaranteed to preserve + ordering of rows that its ORDER BY sees as equivalent.) +

Currently, window functions always require presorted data, and so the + query output will be ordered according to one or another of the window + functions' PARTITION BY/ORDER BY clauses. + It is not recommended to rely on this, however. Use an explicit + top-level ORDER BY clause if you want to be sure the + results are sorted in a particular way. +


PrevHomeNext
OverviewUpSelect Lists
\ No newline at end of file diff --git a/doc/src/sgml/html/queries-union.html b/doc/src/sgml/html/queries-union.html new file mode 100644 index 000000000..9cea10cda --- /dev/null +++ b/doc/src/sgml/html/queries-union.html @@ -0,0 +1,353 @@ + +Combining Queries

7.4. Combining Queries

The results of two queries can be combined using the set operations + union, intersection, and difference. The syntax is +

query1 UNION [ALL] query2
+query1 INTERSECT [ALL] query2
+query1 EXCEPT [ALL] query2

+ query1 and + query2 are queries that can use any of + the features discussed up to this point. Set operations can also + be nested and chained, for example +

query1 UNION query2 UNION query3

+ which is executed as: +

(query1 UNION query2) UNION query3

+

UNION effectively appends the result of + query2 to the result of + query1 (although there is no guarantee + that this is the order in which the rows are actually returned). + Furthermore, it eliminates duplicate rows from its result, in the same + way as DISTINCT, unless UNION ALL is used. +

INTERSECT returns all rows that are both in the result + of query1 and in the result of + query2. Duplicate rows are eliminated + unless INTERSECT ALL is used. +

EXCEPT returns all rows that are in the result of + query1 but not in the result of + query2. (This is sometimes called the + difference between two queries.) Again, duplicates + are eliminated unless EXCEPT ALL is used. +

In order to calculate the union, intersection, or difference of two + queries, the two queries must be "union compatible", + which means that they return the same number of columns and + the corresponding columns have compatible data types, as + described in Section 10.5. +


PrevHomeNext
Select ListsUpSorting Rows
\ No newline at end of file diff --git a/doc/src/sgml/html/queries-values.html b/doc/src/sgml/html/queries-values.html new file mode 100644 index 000000000..45398fd11 --- /dev/null +++ b/doc/src/sgml/html/queries-values.html @@ -0,0 +1,303 @@ + +VALUES Lists

7.7. VALUES Lists

VALUES provides a way to generate a "constant table" + that can be used in a query without having to actually create and populate + a table on-disk. The syntax is +

VALUES ( expression [, ...] ) [, ...]

+ Each parenthesized list of expressions generates a row in the table. + The lists must all have the same number of elements (i.e., the number + of columns in the table), and corresponding entries in each list must + have compatible data types. The actual data type assigned to each column + of the result is determined using the same rules as for UNION + (see Section 10.5). +

As an example: +

VALUES (1, 'one'), (2, 'two'), (3, 'three');

+ + will return a table of two columns and three rows. It's effectively + equivalent to: +

SELECT 1 AS column1, 'one' AS column2
+UNION ALL
+SELECT 2, 'two'
+UNION ALL
+SELECT 3, 'three';

+ + By default, PostgreSQL assigns the names + column1, column2, etc. to the columns of a + VALUES table. The column names are not specified by the + SQL standard and different database systems do it differently, so + it's usually better to override the default names with a table alias + list. +

Syntactically, VALUES followed by expression lists is + treated as equivalent to: +

SELECT select_list FROM table_expression

+ and can appear anywhere a SELECT can. For example, you can + use it as part of a UNION, or attach a + sort_specification (ORDER BY, + LIMIT, and/or OFFSET) to it. VALUES + is most commonly used as the data source in an INSERT command, + and next most commonly as a subquery. +

For more information see VALUES. +


PrevHomeNext
LIMIT and OFFSETUpWITH Queries (Common Table Expressions)
\ No newline at end of file diff --git a/doc/src/sgml/html/queries-with.html b/doc/src/sgml/html/queries-with.html new file mode 100644 index 000000000..dfaad4aa8 --- /dev/null +++ b/doc/src/sgml/html/queries-with.html @@ -0,0 +1,996 @@ + +WITH Queries (Common Table Expressions)

7.8. WITH Queries (Common Table Expressions)

WITH provides a way to write auxiliary statements for use in a + larger query. These statements, which are often referred to as Common + Table Expressions or CTEs, can be thought of as defining + temporary tables that exist just for one query. Each auxiliary statement + in a WITH clause can be a SELECT, + INSERT, UPDATE, or DELETE; and the + WITH clause itself is attached to a primary statement that can + also be a SELECT, INSERT, UPDATE, or + DELETE. +

7.8.1. SELECT in WITH

The basic value of SELECT in WITH is to + break down complicated queries into simpler parts. An example is: + +

WITH regional_sales AS (
+        SELECT region, SUM(amount) AS total_sales
+        FROM orders
+        GROUP BY region
+     ), top_regions AS (
+        SELECT region
+        FROM regional_sales
+        WHERE total_sales > (SELECT SUM(total_sales)/10 FROM regional_sales)
+     )
+SELECT region,
+       product,
+       SUM(quantity) AS product_units,
+       SUM(amount) AS product_sales
+FROM orders
+WHERE region IN (SELECT region FROM top_regions)
+GROUP BY region, product;

+ + which displays per-product sales totals in only the top sales regions. + The WITH clause defines two auxiliary statements named + regional_sales and top_regions, + where the output of regional_sales is used in + top_regions and the output of top_regions + is used in the primary SELECT query. + This example could have been written without WITH, + but we'd have needed two levels of nested sub-SELECTs. It's a bit + easier to follow this way. +

The optional RECURSIVE modifier changes WITH + from a mere syntactic convenience into a feature that accomplishes + things not otherwise possible in standard SQL. Using + RECURSIVE, a WITH query can refer to its own + output. A very simple example is this query to sum the integers from 1 + through 100: + +

WITH RECURSIVE t(n) AS (
+    VALUES (1)
+  UNION ALL
+    SELECT n+1 FROM t WHERE n < 100
+)
+SELECT sum(n) FROM t;

+ + The general form of a recursive WITH query is always a + non-recursive term, then UNION (or + UNION ALL), then a + recursive term, where only the recursive term can contain + a reference to the query's own output. Such a query is executed as + follows: +

Recursive Query Evaluation

  1. Evaluate the non-recursive term. For UNION (but not + UNION ALL), discard duplicate rows. Include all remaining + rows in the result of the recursive query, and also place them in a + temporary working table. +

  2. So long as the working table is not empty, repeat these steps: +

    1. Evaluate the recursive term, substituting the current contents of + the working table for the recursive self-reference. + For UNION (but not UNION ALL), discard + duplicate rows and rows that duplicate any previous result row. + Include all remaining rows in the result of the recursive query, and + also place them in a temporary intermediate table. +

    2. Replace the contents of the working table with the contents of the + intermediate table, then empty the intermediate table. +

Note: Strictly speaking, this process is iteration not recursion, but + RECURSIVE is the terminology chosen by the SQL standards + committee. +

In the example above, the working table has just a single row in each step, + and it takes on the values from 1 through 100 in successive steps. In + the 100th step, there is no output because of the WHERE + clause, and so the query terminates. +

Recursive queries are typically used to deal with hierarchical or + tree-structured data. A useful example is this query to find all the + direct and indirect sub-parts of a product, given only a table that + shows immediate inclusions: + +

WITH RECURSIVE included_parts(sub_part, part, quantity) AS (
+    SELECT sub_part, part, quantity FROM parts WHERE part = 'our_product'
+  UNION ALL
+    SELECT p.sub_part, p.part, p.quantity
+    FROM included_parts pr, parts p
+    WHERE p.part = pr.sub_part
+  )
+SELECT sub_part, SUM(quantity) as total_quantity
+FROM included_parts
+GROUP BY sub_part

+

When working with recursive queries it is important to be sure that + the recursive part of the query will eventually return no tuples, + or else the query will loop indefinitely. Sometimes, using + UNION instead of UNION ALL can accomplish this + by discarding rows that duplicate previous output rows. However, often a + cycle does not involve output rows that are completely duplicate: it may be + necessary to check just one or a few fields to see if the same point has + been reached before. The standard method for handling such situations is + to compute an array of the already-visited values. For example, consider + the following query that searches a table graph using a + link field: + +

WITH RECURSIVE search_graph(id, link, data, depth) AS (
+        SELECT g.id, g.link, g.data, 1
+        FROM graph g
+      UNION ALL
+        SELECT g.id, g.link, g.data, sg.depth + 1
+        FROM graph g, search_graph sg
+        WHERE g.id = sg.link
+)
+SELECT * FROM search_graph;

+ + This query will loop if the link relationships contain + cycles. Because we require a "depth" output, just changing + UNION ALL to UNION would not eliminate the looping. + Instead we need to recognize whether we have reached the same row again + while following a particular path of links. We add two columns + path and cycle to the loop-prone query: + +

WITH RECURSIVE search_graph(id, link, data, depth, path, cycle) AS (
+        SELECT g.id, g.link, g.data, 1,
+          ARRAY[g.id],
+          false
+        FROM graph g
+      UNION ALL
+        SELECT g.id, g.link, g.data, sg.depth + 1,
+          path || g.id,
+          g.id = ANY(path)
+        FROM graph g, search_graph sg
+        WHERE g.id = sg.link AND NOT cycle
+)
+SELECT * FROM search_graph;

+ + Aside from preventing cycles, the array value is often useful in its own + right as representing the "path" taken to reach any particular row. +

In the general case where more than one field needs to be checked to + recognize a cycle, use an array of rows. For example, if we needed to + compare fields f1 and f2: + +

WITH RECURSIVE search_graph(id, link, data, depth, path, cycle) AS (
+        SELECT g.id, g.link, g.data, 1,
+          ARRAY[ROW(g.f1, g.f2)],
+          false
+        FROM graph g
+      UNION ALL
+        SELECT g.id, g.link, g.data, sg.depth + 1,
+          path || ROW(g.f1, g.f2),
+          ROW(g.f1, g.f2) = ANY(path)
+        FROM graph g, search_graph sg
+        WHERE g.id = sg.link AND NOT cycle
+)
+SELECT * FROM search_graph;

+

Tip: Omit the ROW() syntax in the common case where only one field + needs to be checked to recognize a cycle. This allows a simple array + rather than a composite-type array to be used, gaining efficiency. +

Tip: The recursive query evaluation algorithm produces its output in + breadth-first search order. You can display the results in depth-first + search order by making the outer query ORDER BY a + "path" column constructed in this way. +

A helpful trick for testing queries + when you are not certain if they might loop is to place a LIMIT + in the parent query. For example, this query would loop forever without + the LIMIT: + +

WITH RECURSIVE t(n) AS (
+    SELECT 1
+  UNION ALL
+    SELECT n+1 FROM t
+)
+SELECT n FROM t LIMIT 100;

+ + This works because PostgreSQL's implementation + evaluates only as many rows of a WITH query as are actually + fetched by the parent query. Using this trick in production is not + recommended, because other systems might work differently. Also, it + usually won't work if you make the outer query sort the recursive query's + results or join them to some other table, because in such cases the + outer query will usually try to fetch all of the WITH query's + output anyway. +

A useful property of WITH queries is that they are evaluated + only once per execution of the parent query, even if they are referred to + more than once by the parent query or sibling WITH queries. + Thus, expensive calculations that are needed in multiple places can be + placed within a WITH query to avoid redundant work. Another + possible application is to prevent unwanted multiple evaluations of + functions with side-effects. + However, the other side of this coin is that the optimizer is less able to + push restrictions from the parent query down into a WITH query + than an ordinary sub-query. The WITH query will generally be + evaluated as written, without suppression of rows that the parent query + might discard afterwards. (But, as mentioned above, evaluation might stop + early if the reference(s) to the query demand only a limited number of + rows.) +

The examples above only show WITH being used with + SELECT, but it can be attached in the same way to + INSERT, UPDATE, or DELETE. + In each case it effectively provides temporary table(s) that can + be referred to in the main command. +

7.8.2. Data-Modifying Statements in WITH

You can use data-modifying statements (INSERT, + UPDATE, or DELETE) in WITH. This + allows you to perform several different operations in the same query. + An example is: + +

WITH moved_rows AS (
+    DELETE FROM products
+    WHERE
+        "date" >= '2010-10-01' AND
+        "date" < '2010-11-01'
+    RETURNING *
+)
+INSERT INTO products_log
+SELECT * FROM moved_rows;

+ + This query effectively moves rows from products to + products_log. The DELETE in WITH + deletes the specified rows from products, returning their + contents by means of its RETURNING clause; and then the + primary query reads that output and inserts it into + products_log. +

A fine point of the above example is that the WITH clause is + attached to the INSERT, not the sub-SELECT within + the INSERT. This is necessary because data-modifying + statements are only allowed in WITH clauses that are attached + to the top-level statement. However, normal WITH visibility + rules apply, so it is possible to refer to the WITH + statement's output from the sub-SELECT. +

Data-modifying statements in WITH usually have + RETURNING clauses, as seen in the example above. + It is the output of the RETURNING clause, not the + target table of the data-modifying statement, that forms the temporary + table that can be referred to by the rest of the query. If a + data-modifying statement in WITH lacks a RETURNING + clause, then it forms no temporary table and cannot be referred to in + the rest of the query. Such a statement will be executed nonetheless. + A not-particularly-useful example is: + +

WITH t AS (
+    DELETE FROM foo
+)
+DELETE FROM bar;

+ + This example would remove all rows from tables foo and + bar. The number of affected rows reported to the client + would only include rows removed from bar. +

Recursive self-references in data-modifying statements are not + allowed. In some cases it is possible to work around this limitation by + referring to the output of a recursive WITH, for example: + +

WITH RECURSIVE included_parts(sub_part, part) AS (
+    SELECT sub_part, part FROM parts WHERE part = 'our_product'
+  UNION ALL
+    SELECT p.sub_part, p.part
+    FROM included_parts pr, parts p
+    WHERE p.part = pr.sub_part
+  )
+DELETE FROM parts
+  WHERE part IN (SELECT part FROM included_parts);

+ + This query would remove all direct and indirect subparts of a product. +

Data-modifying statements in WITH are executed exactly once, + and always to completion, independently of whether the primary query + reads all (or indeed any) of their output. Notice that this is different + from the rule for SELECT in WITH: as stated in the + previous section, execution of a SELECT is carried only as far + as the primary query demands its output. +

The sub-statements in WITH are executed concurrently with + each other and with the main query. Therefore, when using data-modifying + statements in WITH, the order in which the specified updates + actually happen is unpredictable. All the statements are executed with + the same snapshot (see Chapter 13), so they + cannot "see" each others' effects on the target tables. This + alleviates the effects of the unpredictability of the actual order of row + updates, and means that RETURNING data is the only way to + communicate changes between different WITH sub-statements and + the main query. An example of this is that in + +

WITH t AS (
+    UPDATE products SET price = price * 1.05
+    RETURNING *
+)
+SELECT * FROM products;

+ + the outer SELECT would return the original prices before the + action of the UPDATE, while in + +

WITH t AS (
+    UPDATE products SET price = price * 1.05
+    RETURNING *
+)
+SELECT * FROM t;

+ + the outer SELECT would return the updated data. +

Trying to update the same row twice in a single statement is not + supported. Only one of the modifications takes place, but it is not easy + (and sometimes not possible) to reliably predict which one. This also + applies to deleting a row that was already updated in the same statement: + only the update is performed. Therefore you should generally avoid trying + to modify a single row twice in a single statement. In particular avoid + writing WITH sub-statements that could affect the same rows + changed by the main statement or a sibling sub-statement. The effects + of such a statement will not be predictable. +

At present, any table used as the target of a data-modifying statement in + WITH must not have a conditional rule, nor an ALSO + rule, nor an INSTEAD rule that expands to multiple statements. +


PrevHomeNext
VALUES ListsUpData Types
\ No newline at end of file diff --git a/doc/src/sgml/html/queries.html b/doc/src/sgml/html/queries.html new file mode 100644 index 000000000..8cf2f73df --- /dev/null +++ b/doc/src/sgml/html/queries.html @@ -0,0 +1,309 @@ + +Queries

Chapter 7. Queries

The previous chapters explained how to create tables, how to fill + them with data, and how to manipulate that data. Now we finally + discuss how to retrieve the data from the database. +


PrevHomeNext
Deleting DataUpOverview
\ No newline at end of file diff --git a/doc/src/sgml/html/query-path.html b/doc/src/sgml/html/query-path.html new file mode 100644 index 000000000..e357e1b70 --- /dev/null +++ b/doc/src/sgml/html/query-path.html @@ -0,0 +1,309 @@ + +The Path of a Query
PostgreSQL 9.2.2 Documentation
PrevUpChapter 44. Overview of PostgreSQL InternalsNext

44.1. The Path of a Query

Here we give a short overview of the stages a query has to pass in + order to obtain a result. +

  1. A connection from an application program to the PostgreSQL + server has to be established. The application program transmits a + query to the server and waits to receive the results sent back by the + server. +

  2. The parser stage checks the query + transmitted by the application + program for correct syntax and creates + a query tree. +

  3. The rewrite system takes + the query tree created by the parser stage and looks for + any rules (stored in the + system catalogs) to apply to + the query tree. It performs the + transformations given in the rule bodies. +

    One application of the rewrite system is in the realization of + views. + Whenever a query against a view + (i.e., a virtual table) is made, + the rewrite system rewrites the user's query to + a query that accesses the base tables given in + the view definition instead. +

  4. The planner/optimizer takes + the (rewritten) query tree and creates a + query plan that will be the input to the + executor. +

    It does so by first creating all possible paths + leading to the same result. For example if there is an index on a + relation to be scanned, there are two paths for the + scan. One possibility is a simple sequential scan and the other + possibility is to use the index. Next the cost for the execution of + each path is estimated and the cheapest path is chosen. The cheapest + path is expanded into a complete plan that the executor can use. +

  5. The executor recursively steps through + the plan tree and + retrieves rows in the way represented by the plan. + The executor makes use of the + storage system while scanning + relations, performs sorts and joins, + evaluates qualifications and finally hands back the rows derived. +

In the following sections we will cover each of the above listed items + in more detail to give a better understanding of PostgreSQL's internal + control and data structures. +


PrevHomeNext
Overview of PostgreSQL InternalsUpHow Connections are Established
\ No newline at end of file diff --git a/doc/src/sgml/html/querytree.html b/doc/src/sgml/html/querytree.html new file mode 100644 index 000000000..fb9d5cd08 --- /dev/null +++ b/doc/src/sgml/html/querytree.html @@ -0,0 +1,517 @@ + +The Query Tree
PostgreSQL 9.2.2 Documentation
PrevUpChapter 37. The Rule SystemNext

37.1. The Query Tree

To understand how the rule system works it is necessary to know + when it is invoked and what its input and results are.

The rule system is located between the parser and the planner. + It takes the output of the parser, one query tree, and the user-defined + rewrite rules, which are also + query trees with some extra information, and creates zero or more + query trees as result. So its input and output are always things + the parser itself could have produced and thus, anything it sees + is basically representable as an SQL statement.

Now what is a query tree? It is an internal representation of an + SQL statement where the single parts that it is + built from are stored separately. These query trees can be shown + in the server log if you set the configuration parameters + debug_print_parse, + debug_print_rewritten, or + debug_print_plan. The rule actions are also + stored as query trees, in the system catalog + pg_rewrite. They are not formatted like + the log output, but they contain exactly the same information.

Reading a raw query tree requires some experience. But since + SQL representations of query trees are + sufficient to understand the rule system, this chapter will not + teach how to read them.

When reading the SQL representations of the + query trees in this chapter it is necessary to be able to identify + the parts the statement is broken into when it is in the query tree + structure. The parts of a query tree are + +

the command type

This is a simple value telling which command + (SELECT, INSERT, + UPDATE, DELETE) produced + the query tree. +

the range table

The range table is a list of relations that are used in the query. + In a SELECT statement these are the relations given after + the FROM key word. +

Every range table entry identifies a table or view and tells + by which name it is called in the other parts of the query. + In the query tree, the range table entries are referenced by + number rather than by name, so here it doesn't matter if there + are duplicate names as it would in an SQL + statement. This can happen after the range tables of rules + have been merged in. The examples in this chapter will not have + this situation. +

the result relation

This is an index into the range table that identifies the + relation where the results of the query go. +

SELECT queries don't have a result + relation. (The special case of SELECT INTO is + mostly identical to CREATE TABLE followed by + INSERT ... SELECT, and is not discussed + separately here.) +

For INSERT, UPDATE, and + DELETE commands, the result relation is the table + (or view!) where the changes are to take effect. +

the target list

The target list is a list of expressions that define the + result of the query. In the case of a + SELECT, these expressions are the ones that + build the final output of the query. They correspond to the + expressions between the key words SELECT + and FROM. (* is just an + abbreviation for all the column names of a relation. It is + expanded by the parser into the individual columns, so the + rule system never sees it.) +

DELETE commands don't need a normal target list + because they don't produce any result. Instead, the rule system + adds a special CTID entry to the empty target list, + to allow the executor to find the row to be deleted. + (CTID is added when the result relation is an ordinary + table. If it is a view, a whole-row variable is added instead, + as described in Section 37.2.4.) +

For INSERT commands, the target list describes + the new rows that should go into the result relation. It consists of the + expressions in the VALUES clause or the ones from the + SELECT clause in INSERT + ... SELECT. The first step of the rewrite process adds + target list entries for any columns that were not assigned to by + the original command but have defaults. Any remaining columns (with + neither a given value nor a default) will be filled in by the + planner with a constant null expression. +

For UPDATE commands, the target list + describes the new rows that should replace the old ones. In the + rule system, it contains just the expressions from the SET + column = expression part of the command. The planner will + handle missing columns by inserting expressions that copy the values + from the old row into the new one. Just as for DELETE, + the rule system adds a CTID or whole-row variable so that + the executor can identify the old row to be updated. +

Every entry in the target list contains an expression that can + be a constant value, a variable pointing to a column of one + of the relations in the range table, a parameter, or an expression + tree made of function calls, constants, variables, operators, etc. +

the qualification

The query's qualification is an expression much like one of + those contained in the target list entries. The result value of + this expression is a Boolean that tells whether the operation + (INSERT, UPDATE, + DELETE, or SELECT) for the + final result row should be executed or not. It corresponds to the WHERE clause + of an SQL statement. +

the join tree

The query's join tree shows the structure of the FROM clause. + For a simple query like SELECT ... FROM a, b, c, the join tree is just + a list of the FROM items, because we are allowed to join them in + any order. But when JOIN expressions, particularly outer joins, + are used, we have to join in the order shown by the joins. + In that case, the join tree shows the structure of the JOIN expressions. The + restrictions associated with particular JOIN clauses (from ON or + USING expressions) are stored as qualification expressions attached + to those join-tree nodes. It turns out to be convenient to store + the top-level WHERE expression as a qualification attached to the + top-level join-tree item, too. So really the join tree represents + both the FROM and WHERE clauses of a SELECT. +

the others

The other parts of the query tree like the ORDER BY + clause aren't of interest here. The rule system + substitutes some entries there while applying rules, but that + doesn't have much to do with the fundamentals of the rule + system. +


PrevHomeNext
The Rule SystemUpViews and the Rule System
\ No newline at end of file diff --git a/doc/src/sgml/html/rangetypes.html b/doc/src/sgml/html/rangetypes.html new file mode 100644 index 000000000..e3c77b3ae --- /dev/null +++ b/doc/src/sgml/html/rangetypes.html @@ -0,0 +1,1048 @@ + +Range Types

8.17. Range Types

Range types are data types representing a range of values of some + element type (called the range's subtype). + For instance, ranges + of timestamp might be used to represent the ranges of + time that a meeting room is reserved. In this case the data type + is tsrange (short for "timestamp range"), + and timestamp is the subtype. The subtype must have + a total order so that it is well-defined whether element values are + within, before, or after a range of values. +

Range types are useful because they represent many element values in a + single range value, and because concepts such as overlapping ranges can + be expressed clearly. The use of time and date ranges for scheduling + purposes is the clearest example; but price ranges, measurement + ranges from an instrument, and so forth can also be useful. +

8.17.1. Built-in Range Types

PostgreSQL comes with the following built-in range types: +

  • int4range — Range of integer +

  • int8range — Range of bigint +

  • numrange — Range of numeric +

  • tsrange — Range of timestamp without time zone +

  • tstzrange — Range of timestamp with time zone +

  • daterange — Range of date +

+ In addition, you can define your own range types; + see CREATE TYPE for more information. +

8.17.2. Examples

CREATE TABLE reservation (room int, during tsrange);
+INSERT INTO reservation VALUES
+    (1108, '[2010-01-01 14:30, 2010-01-01 15:30)');
+
+-- Containment
+SELECT int4range(10, 20) @> 3;
+
+-- Overlaps
+SELECT numrange(11.1, 22.2) && numrange(20.0, 30.0);
+
+-- Extract the upper bound
+SELECT upper(int8range(15, 25));
+
+-- Compute the intersection
+SELECT int4range(10, 20) * int4range(15, 25);
+
+-- Is the range empty?
+SELECT isempty(numrange(1, 5));

+ + See Table 9-43 + and Table 9-44 for complete lists of + operators and functions on range types. +

8.17.3. Inclusive and Exclusive Bounds

Every non-empty range has two bounds, the lower bound and the upper + bound. All points between these values are included in the range. An + inclusive bound means that the boundary point itself is included in + the range as well, while an exclusive bound means that the boundary + point is not included in the range. +

In the text form of a range, an inclusive lower bound is represented by + "[" while an exclusive lower bound is + represented by "(". Likewise, an inclusive upper bound is represented by + "]", while an exclusive upper bound is + represented by ")". + (See Section 8.17.5 for more details.) +

The functions lower_inc + and upper_inc test the inclusivity of the lower + and upper bounds of a range value, respectively. +

8.17.4. Infinite (Unbounded) Ranges

The lower bound of a range can be omitted, meaning that all points less + than the upper bound are included in the range. Likewise, if the upper + bound of the range is omitted, then all points greater than the lower bound + are included in the range. If both lower and upper bounds are omitted, all + values of the element type are considered to be in the range. +

This is equivalent to considering that the lower bound is "minus + infinity", or the upper bound is "plus infinity", + respectively. But note that these infinite values are never values of + the range's element type, and can never be part of the range. (So there + is no such thing as an inclusive infinite bound — if you try to + write one, it will automatically be converted to an exclusive bound.) +

Also, some element types have a notion of "infinity", but that + is just another value so far as the range type mechanisms are concerned. + For example, in timestamp ranges, [today,] means the same + thing as [today,). But [today,infinity] means + something different from [today,infinity) — the latter + excludes the special timestamp value infinity. +

The functions lower_inf + and upper_inf test for infinite lower + and upper bounds of a range, respectively. +

8.17.5. Range Input/Output

The input for a range value must follow one of the following patterns: +

(lower-bound,upper-bound)
+(lower-bound,upper-bound]
+[lower-bound,upper-bound)
+[lower-bound,upper-bound]
+empty

+ The parentheses or brackets indicate whether the lower and upper bounds + are exclusive or inclusive, as described previously. + Notice that the final pattern is empty, which + represents an empty range (a range that contains no points). +

The lower-bound may be either a string + that is valid input for the subtype, or empty to indicate no + lower bound. Likewise, upper-bound may be + either a string that is valid input for the subtype, or empty to + indicate no upper bound. +

Each bound value can be quoted using " (double quote) + characters. This is necessary if the bound value contains parentheses, + brackets, commas, double quotes, or backslashes, since these characters + would otherwise be taken as part of the range syntax. To put a double + quote or backslash in a quoted bound value, precede it with a + backslash. (Also, a pair of double quotes within a double-quoted bound + value is taken to represent a double quote character, analogously to the + rules for single quotes in SQL literal strings.) Alternatively, you can + avoid quoting and use backslash-escaping to protect all data characters + that would otherwise be taken as range syntax. Also, to write a bound + value that is an empty string, write "", since writing + nothing means an infinite bound. +

Whitespace is allowed before and after the range value, but any whitespace + between the parentheses or brackets is taken as part of the lower or upper + bound value. (Depending on the element type, it might or might not be + significant.) +

Note: These rules are very similar to those for writing field values in + composite-type literals. See Section 8.16.5 for + additional commentary. +

Examples: +

-- includes 3, does not include 7, and does include all points in between
+SELECT '[3,7)'::int4range;
+
+-- does not include either 3 or 7, but includes all points in between
+SELECT '(3,7)'::int4range;
+
+-- includes only the single point 4
+SELECT '[4,4]'::int4range;
+
+-- includes no points (and will be normalized to 'empty')
+SELECT '[4,4)'::int4range;

+

8.17.6. Constructing Ranges

Each range type has a constructor function with the same name as the range + type. Using the constructor function is frequently more convenient than + writing a range literal constant, since it avoids the need for extra + quoting of the bound values. The constructor function + accepts two or three arguments. The two-argument form constructs a range + in standard form (lower bound inclusive, upper bound exclusive), while + the three-argument form constructs a range with bounds of the form + specified by the third argument. + The third argument must be one of the strings + "()", + "(]", + "[)", or + "[]". + For example: + +

-- The full form is: lower bound, upper bound, and text argument indicating
+-- inclusivity/exclusivity of bounds.
+SELECT numrange(1.0, 14.0, '(]');
+
+-- If the third argument is omitted, '[)' is assumed.
+SELECT numrange(1.0, 14.0);
+
+-- Although '(]' is specified here, on display the value will be converted to
+-- canonical form, since int8range is a discrete range type (see below).
+SELECT int8range(1, 14, '(]');
+
+-- Using NULL for either bound causes the range to be unbounded on that side.
+SELECT numrange(NULL, 2.2);

+

8.17.7. Discrete Range Types

A discrete range is one whose element type has a well-defined + "step", such as integer or date. + In these types two elements can be said to be adjacent, when there are + no valid values between them. This contrasts with continuous ranges, + where it's always (or almost always) possible to identify other element + values between two given values. For example, a range over the + numeric type is continuous, as is a range over timestamp. + (Even though timestamp has limited precision, and so could + theoretically be treated as discrete, it's better to consider it continuous + since the step size is normally not of interest.) +

Another way to think about a discrete range type is that there is a clear + idea of a "next" or "previous" value for each element value. + Knowing that, it is possible to convert between inclusive and exclusive + representations of a range's bounds, by choosing the next or previous + element value instead of the one originally given. + For example, in an integer range type [4,8] and + (3,9) denote the same set of values; but this would not be so + for a range over numeric. +

A discrete range type should have a canonicalization + function that is aware of the desired step size for the element type. + The canonicalization function is charged with converting equivalent values + of the range type to have identical representations, in particular + consistently inclusive or exclusive bounds. + If a canonicalization function is not specified, then ranges with different + formatting will always be treated as unequal, even though they might + represent the same set of values in reality. +

The built-in range types int4range, int8range, + and daterange all use a canonical form that includes + the lower bound and excludes the upper bound; that is, + [). User-defined range types can use other conventions, + however. +

8.17.8. Defining New Range Types

Users can define their own range types. The most common reason to do + this is to use ranges over subtypes not provided among the built-in + range types. + For example, to define a new range type of subtype float8: + +

CREATE TYPE floatrange AS RANGE (
+    subtype = float8,
+    subtype_diff = float8mi
+);
+
+SELECT '[1.234, 5.678]'::floatrange;

+ + Because float8 has no meaningful + "step", we do not define a canonicalization + function in this example. +

If the subtype is considered to have discrete rather than continuous + values, the CREATE TYPE command should specify a + canonical function. + The canonicalization function takes an input range value, and must return + an equivalent range value that may have different bounds and formatting. + The canonical output for two ranges that represent the same set of values, + for example the integer ranges [1, 7] and [1, + 8), must be identical. It doesn't matter which representation + you choose to be the canonical one, so long as two equivalent values with + different formattings are always mapped to the same value with the same + formatting. In addition to adjusting the inclusive/exclusive bounds + format, a canonicalization function might round off boundary values, in + case the desired step size is larger than what the subtype is capable of + storing. For instance, a range type over timestamp could be + defined to have a step size of an hour, in which case the canonicalization + function would need to round off bounds that weren't a multiple of an hour, + or perhaps throw an error instead. +

Defining your own range type also allows you to specify a different + subtype B-tree operator class or collation to use, so as to change the sort + ordering that determines which values fall into a given range. +

In addition, any range type that is meant to be used with GiST indexes + should define a subtype difference, or subtype_diff, function. + (A GiST index will still work without subtype_diff, but it is + likely to be considerably less efficient than if a difference function is + provided.) The subtype difference function takes two input values of the + subtype, and returns their difference (i.e., X minus + Y) represented as a float8 value. In our example + above, the function that underlies the regular float8 minus + operator can be used; but for any other subtype, some type conversion would + be necessary. Some creative thought about how to represent differences as + numbers might be needed, too. To the greatest extent possible, the + subtype_diff function should agree with the sort ordering + implied by the selected operator class and collation; that is, its result + should be positive whenever its first argument is greater than its second + according to the sort ordering. +

See CREATE TYPE for more information about creating + range types. +

8.17.9. Indexing

GiST indexes can be created for table columns of range types. + For instance: +

CREATE INDEX reservation_idx ON reservation USING gist (during);

+ A GiST index can accelerate queries involving these range operators: + =, + &&, + <@, + @>, + <<, + >>, + -|-, + &<, and + &> + (see Table 9-43 for more information). +

In addition, B-tree and hash indexes can be created for table columns of + range types. For these index types, basically the only useful range + operation is equality. There is a B-tree sort ordering defined for range + values, with corresponding < and > operators, + but the ordering is rather arbitrary and not usually useful in the real + world. Range types' B-tree and hash support is primarily meant to + allow sorting and hashing internally in queries, rather than creation of + actual indexes. +

8.17.10. Constraints on Ranges

While UNIQUE is a natural constraint for scalar + values, it is usually unsuitable for range types. Instead, an + exclusion constraint is often more appropriate + (see CREATE TABLE + ... CONSTRAINT ... EXCLUDE). Exclusion constraints allow the + specification of constraints such as "non-overlapping" on a + range type. For example: + +

ALTER TABLE reservation ADD EXCLUDE USING gist (during WITH &&);

+ + That constraint will prevent any overlapping values from existing + in the table at the same time: + +

INSERT INTO reservation VALUES
+    (1108, '[2010-01-01 11:30, 2010-01-01 13:00)');
+INSERT 0 1
+
+INSERT INTO reservation VALUES
+    (1108, '[2010-01-01 14:45, 2010-01-01 15:45)');
+ERROR:  conflicting key value violates exclusion constraint "reservation_during_excl"
+DETAIL:  Key (during)=([ 2010-01-01 14:45:00, 2010-01-01 15:45:00 )) conflicts
+with existing key (during)=([ 2010-01-01 14:30:00, 2010-01-01 15:30:00 )).

+

You can use the btree_gist + extension to define exclusion constraints on plain scalar data types, which + can then be combined with range exclusions for maximum flexibility. For + example, after btree_gist is installed, the following + constraint will reject overlapping ranges only if the meeting room numbers + are equal: + +

CREATE TABLE room_reservation (
+    room text,
+    during tsrange,
+    EXCLUDE USING gist (room WITH =, during WITH &&)
+);
+
+INSERT INTO room_reservation VALUES
+    ('123A', '[2010-01-01 14:00, 2010-01-01 15:00)');
+INSERT 0 1
+
+INSERT INTO room_reservation VALUES
+    ('123A', '[2010-01-01 14:30, 2010-01-01 15:30)');
+ERROR:  conflicting key value violates exclusion constraint "room_reservation_room_during_excl"
+DETAIL:  Key (room, during)=(123A, [ 2010-01-01 14:30:00, 2010-01-01 15:30:00 )) conflicts with
+existing key (room, during)=(123A, [ 2010-01-01 14:00:00, 2010-01-01 15:00:00 )).
+
+INSERT INTO room_reservation VALUES
+    ('123B', '[2010-01-01 14:30, 2010-01-01 15:30)');
+INSERT 0 1

+


PrevHomeNext
Composite TypesUpObject Identifier Types
\ No newline at end of file diff --git a/doc/src/sgml/html/recovery-config.html b/doc/src/sgml/html/recovery-config.html new file mode 100644 index 000000000..f16a627d8 --- /dev/null +++ b/doc/src/sgml/html/recovery-config.html @@ -0,0 +1,225 @@ + +Recovery Configuration

Chapter 26. Recovery Configuration

This chapter describes the settings available in the + recovery.conf + file. They apply only for the duration of the + recovery. They must be reset for any subsequent recovery you wish to + perform. They cannot be changed once recovery has begun. +

Settings in recovery.conf are specified in the format + name = 'value'. One parameter is specified per line. + Hash marks (#) designate the rest of the + line as a comment. To embed a single quote in a parameter + value, write two quotes (''). +

A sample file, share/recovery.conf.sample, + is provided in the installation's share/ directory. +


PrevHomeNext
Hot StandbyUpArchive Recovery Settings
\ No newline at end of file diff --git a/doc/src/sgml/html/recovery-target-settings.html b/doc/src/sgml/html/recovery-target-settings.html new file mode 100644 index 000000000..0dc19b3e4 --- /dev/null +++ b/doc/src/sgml/html/recovery-target-settings.html @@ -0,0 +1,388 @@ + +Recovery Target Settings
PostgreSQL 9.2.2 Documentation
PrevUpChapter 26. Recovery ConfigurationNext

26.2. Recovery Target Settings

recovery_target_name + (string)

This parameter specifies the named restore point, created with + pg_create_restore_point() to which recovery will proceed. + At most one of recovery_target_name, + recovery_target_time or + recovery_target_xid can be specified. The default is to + recover to the end of the WAL log. +

recovery_target_time + (timestamp)

This parameter specifies the time stamp up to which recovery + will proceed. + At most one of recovery_target_time, + recovery_target_name or + recovery_target_xid can be specified. + The default is to recover to the end of the WAL log. + The precise stopping point is also influenced by + recovery_target_inclusive. +

recovery_target_xid (string)

This parameter specifies the transaction ID up to which recovery + will proceed. Keep in mind + that while transaction IDs are assigned sequentially at transaction + start, transactions can complete in a different numeric order. + The transactions that will be recovered are those that committed + before (and optionally including) the specified one. + At most one of recovery_target_xid, + recovery_target_name or + recovery_target_time can be specified. + The default is to recover to the end of the WAL log. + The precise stopping point is also influenced by + recovery_target_inclusive. +

recovery_target_inclusive + (boolean)

Specifies whether we stop just after the specified recovery target + (true), or just before the recovery target + (false). + Applies to both recovery_target_time + and recovery_target_xid, whichever one is + specified for this recovery. This indicates whether transactions + having exactly the target commit time or ID, respectively, will + be included in the recovery. Default is true. +

recovery_target_timeline + (string)

Specifies recovering into a particular timeline. The default is + to recover along the same timeline that was current when the + base backup was taken. Setting this to latest recovers + to the latest timeline found in the archive, which is useful in + a standby server. Other than that you only need to set this parameter + in complex re-recovery situations, where you need to return to + a state that itself was reached after a point-in-time recovery. + See Section 24.3.5 for discussion. +

pause_at_recovery_target + (boolean)

Specifies whether recovery should pause when the recovery target + is reached. The default is true. + This is intended to allow queries to be executed against the + database to check if this recovery target is the most desirable + point for recovery. The paused state can be resumed by using + pg_xlog_replay_resume() (See + Table 9-61), which then + causes recovery to end. If this recovery target is not the + desired stopping point, then shutdown the server, change the + recovery target settings to a later target and restart to + continue recovery. +

This setting has no effect if hot_standby is not + enabled, or if no recovery target is set. +


PrevHomeNext
Archive Recovery SettingsUpStandby Server Settings
\ No newline at end of file diff --git a/doc/src/sgml/html/reference-client.html b/doc/src/sgml/html/reference-client.html new file mode 100644 index 000000000..327aa1d28 --- /dev/null +++ b/doc/src/sgml/html/reference-client.html @@ -0,0 +1,378 @@ + +PostgreSQL Client Applications

II. PostgreSQL Client Applications

This part contains reference information for + PostgreSQL client applications and + utilities. Not all of these commands are of general utility; some + might require special privileges. The common feature of these + applications is that they can be run on any host, independent of + where the database server resides. +

When specified on the command line, user and database names have + their case preserved — the presence of spaces or special + characters might require quoting. Table names and other identifiers + do not have their case preserved, except where documented, and + might require quoting. +

Table of Contents
clusterdb -- cluster a PostgreSQL database
createdb -- create a new PostgreSQL database
createlang -- install a PostgreSQL procedural language
createuser -- define a new PostgreSQL user account
dropdb -- remove a PostgreSQL database
droplang -- remove a PostgreSQL procedural language
dropuser -- remove a PostgreSQL user account
ecpg -- embedded SQL C preprocessor
pg_basebackup -- take a base backup of a PostgreSQL cluster
pg_config -- retrieve information about the installed version of PostgreSQL
pg_dump --  extract a PostgreSQL database into a script file or other archive file +
pg_dumpall -- extract a PostgreSQL database cluster into a script file
pg_receivexlog -- streams transaction logs from a PostgreSQL cluster
pg_restore --  restore a PostgreSQL database from an + archive file created by pg_dump +
psql --  PostgreSQL interactive terminal +
reindexdb -- reindex a PostgreSQL database
vacuumdb -- garbage-collect and analyze a PostgreSQL database

PrevHomeNext
VALUESUpclusterdb
\ No newline at end of file diff --git a/doc/src/sgml/html/reference-server.html b/doc/src/sgml/html/reference-server.html new file mode 100644 index 000000000..eece1b0f7 --- /dev/null +++ b/doc/src/sgml/html/reference-server.html @@ -0,0 +1,262 @@ + +PostgreSQL Server Applications

III. PostgreSQL Server Applications

This part contains reference information for + PostgreSQL server applications and + support utilities. These commands can only be run usefully on the + host where the database server resides. Other utility programs + are listed in Reference II, PostgreSQL Client Applications. +

Table of Contents
initdb -- create a new PostgreSQL database cluster
pg_controldata -- display control information of a PostgreSQL database cluster
pg_ctl -- initialize, start, stop, or control a PostgreSQL server
pg_resetxlog -- reset the write-ahead log and other control information of a PostgreSQL database cluster
postgres -- PostgreSQL database server
postmaster -- PostgreSQL database server

PrevHomeNext
vacuumdbUpinitdb
\ No newline at end of file diff --git a/doc/src/sgml/html/reference.html b/doc/src/sgml/html/reference.html new file mode 100644 index 000000000..4ce10b8b2 --- /dev/null +++ b/doc/src/sgml/html/reference.html @@ -0,0 +1,1212 @@ + +Reference

VI. Reference

The entries in this Reference are meant to provide in reasonable + length an authoritative, complete, and formal summary about their + respective subjects. More information about the use of + PostgreSQL, in narrative, tutorial, or + example form, can be found in other parts of this book. See the + cross-references listed on each reference page. +

The reference entries are also available as traditional + "man" pages. +

Table of Contents
I. SQL Commands
ABORT -- abort the current transaction
ALTER AGGREGATE -- change the definition of an aggregate function
ALTER COLLATION -- change the definition of a collation
ALTER CONVERSION -- change the definition of a conversion
ALTER DATABASE -- change a database
ALTER DEFAULT PRIVILEGES -- define default access privileges
ALTER DOMAIN --  change the definition of a domain +
ALTER EXTENSION --  change the definition of an extension +
ALTER FOREIGN DATA WRAPPER -- change the definition of a foreign-data wrapper
ALTER FOREIGN TABLE -- change the definition of a foreign table
ALTER FUNCTION -- change the definition of a function
ALTER GROUP -- change role name or membership
ALTER INDEX -- change the definition of an index
ALTER LANGUAGE -- change the definition of a procedural language
ALTER LARGE OBJECT -- change the definition of a large object
ALTER OPERATOR -- change the definition of an operator
ALTER OPERATOR CLASS -- change the definition of an operator class
ALTER OPERATOR FAMILY -- change the definition of an operator family
ALTER ROLE -- change a database role
ALTER SCHEMA -- change the definition of a schema
ALTER SEQUENCE --  change the definition of a sequence generator +
ALTER SERVER -- change the definition of a foreign server
ALTER TABLE -- change the definition of a table
ALTER TABLESPACE -- change the definition of a tablespace
ALTER TEXT SEARCH CONFIGURATION -- change the definition of a text search configuration
ALTER TEXT SEARCH DICTIONARY -- change the definition of a text search dictionary
ALTER TEXT SEARCH PARSER -- change the definition of a text search parser
ALTER TEXT SEARCH TEMPLATE -- change the definition of a text search template
ALTER TRIGGER -- change the definition of a trigger
ALTER TYPE --  change the definition of a type +
ALTER USER -- change a database role
ALTER USER MAPPING -- change the definition of a user mapping
ALTER VIEW -- change the definition of a view
ANALYZE -- collect statistics about a database
BEGIN -- start a transaction block
CHECKPOINT -- force a transaction log checkpoint
CLOSE -- close a cursor
CLUSTER -- cluster a table according to an index
COMMENT -- define or change the comment of an object
COMMIT -- commit the current transaction
COMMIT PREPARED -- commit a transaction that was earlier prepared for two-phase commit
COPY -- copy data between a file and a table
CREATE AGGREGATE -- define a new aggregate function
CREATE CAST -- define a new cast
CREATE COLLATION -- define a new collation
CREATE CONVERSION -- define a new encoding conversion
CREATE DATABASE -- create a new database
CREATE DOMAIN -- define a new domain
CREATE EXTENSION -- install an extension
CREATE FOREIGN DATA WRAPPER -- define a new foreign-data wrapper
CREATE FOREIGN TABLE -- define a new foreign table
CREATE FUNCTION -- define a new function
CREATE GROUP -- define a new database role
CREATE INDEX -- define a new index
CREATE LANGUAGE -- define a new procedural language
CREATE OPERATOR -- define a new operator
CREATE OPERATOR CLASS -- define a new operator class
CREATE OPERATOR FAMILY -- define a new operator family
CREATE ROLE -- define a new database role
CREATE RULE -- define a new rewrite rule
CREATE SCHEMA -- define a new schema
CREATE SEQUENCE -- define a new sequence generator
CREATE SERVER -- define a new foreign server
CREATE TABLE -- define a new table
CREATE TABLE AS -- define a new table from the results of a query
CREATE TABLESPACE -- define a new tablespace
CREATE TEXT SEARCH CONFIGURATION -- define a new text search configuration
CREATE TEXT SEARCH DICTIONARY -- define a new text search dictionary
CREATE TEXT SEARCH PARSER -- define a new text search parser
CREATE TEXT SEARCH TEMPLATE -- define a new text search template
CREATE TRIGGER -- define a new trigger
CREATE TYPE -- define a new data type
CREATE USER -- define a new database role
CREATE USER MAPPING -- define a new mapping of a user to a foreign server
CREATE VIEW -- define a new view
DEALLOCATE -- deallocate a prepared statement
DECLARE -- define a cursor
DELETE -- delete rows of a table
DISCARD -- discard session state
DO -- execute an anonymous code block
DROP AGGREGATE -- remove an aggregate function
DROP CAST -- remove a cast
DROP COLLATION -- remove a collation
DROP CONVERSION -- remove a conversion
DROP DATABASE -- remove a database
DROP DOMAIN -- remove a domain
DROP EXTENSION -- remove an extension
DROP FOREIGN DATA WRAPPER -- remove a foreign-data wrapper
DROP FOREIGN TABLE -- remove a foreign table
DROP FUNCTION -- remove a function
DROP GROUP -- remove a database role
DROP INDEX -- remove an index
DROP LANGUAGE -- remove a procedural language
DROP OPERATOR -- remove an operator
DROP OPERATOR CLASS -- remove an operator class
DROP OPERATOR FAMILY -- remove an operator family
DROP OWNED -- remove database objects owned by a database role
DROP ROLE -- remove a database role
DROP RULE -- remove a rewrite rule
DROP SCHEMA -- remove a schema
DROP SEQUENCE -- remove a sequence
DROP SERVER -- remove a foreign server descriptor
DROP TABLE -- remove a table
DROP TABLESPACE -- remove a tablespace
DROP TEXT SEARCH CONFIGURATION -- remove a text search configuration
DROP TEXT SEARCH DICTIONARY -- remove a text search dictionary
DROP TEXT SEARCH PARSER -- remove a text search parser
DROP TEXT SEARCH TEMPLATE -- remove a text search template
DROP TRIGGER -- remove a trigger
DROP TYPE -- remove a data type
DROP USER -- remove a database role
DROP USER MAPPING -- remove a user mapping for a foreign server
DROP VIEW -- remove a view
END -- commit the current transaction
EXECUTE -- execute a prepared statement
EXPLAIN -- show the execution plan of a statement
FETCH -- retrieve rows from a query using a cursor
GRANT -- define access privileges
INSERT -- create new rows in a table
LISTEN -- listen for a notification
LOAD -- load a shared library file
LOCK -- lock a table
MOVE -- position a cursor
NOTIFY -- generate a notification
PREPARE -- prepare a statement for execution
PREPARE TRANSACTION -- prepare the current transaction for two-phase commit
REASSIGN OWNED -- change the ownership of database objects owned by a database role
REINDEX -- rebuild indexes
RELEASE SAVEPOINT -- destroy a previously defined savepoint
RESET -- restore the value of a run-time parameter to the default value
REVOKE -- remove access privileges
ROLLBACK -- abort the current transaction
ROLLBACK PREPARED -- cancel a transaction that was earlier prepared for two-phase commit
ROLLBACK TO SAVEPOINT -- roll back to a savepoint
SAVEPOINT -- define a new savepoint within the current transaction
SECURITY LABEL -- define or change a security label applied to an object
SELECT -- retrieve rows from a table or view
SELECT INTO -- define a new table from the results of a query
SET -- change a run-time parameter
SET CONSTRAINTS -- set constraint check timing for the current transaction
SET ROLE -- set the current user identifier of the current session
SET SESSION AUTHORIZATION -- set the session user identifier and the current user identifier of the current session
SET TRANSACTION -- set the characteristics of the current transaction
SHOW -- show the value of a run-time parameter
START TRANSACTION -- start a transaction block
TRUNCATE -- empty a table or set of tables
UNLISTEN -- stop listening for a notification
UPDATE -- update rows of a table
VACUUM -- garbage-collect and optionally analyze a database
VALUES -- compute a set of rows
II. PostgreSQL Client Applications
clusterdb -- cluster a PostgreSQL database
createdb -- create a new PostgreSQL database
createlang -- install a PostgreSQL procedural language
createuser -- define a new PostgreSQL user account
dropdb -- remove a PostgreSQL database
droplang -- remove a PostgreSQL procedural language
dropuser -- remove a PostgreSQL user account
ecpg -- embedded SQL C preprocessor
pg_basebackup -- take a base backup of a PostgreSQL cluster
pg_config -- retrieve information about the installed version of PostgreSQL
pg_dump --  extract a PostgreSQL database into a script file or other archive file +
pg_dumpall -- extract a PostgreSQL database cluster into a script file
pg_receivexlog -- streams transaction logs from a PostgreSQL cluster
pg_restore --  restore a PostgreSQL database from an + archive file created by pg_dump +
psql --  PostgreSQL interactive terminal +
reindexdb -- reindex a PostgreSQL database
vacuumdb -- garbage-collect and analyze a PostgreSQL database
III. PostgreSQL Server Applications
initdb -- create a new PostgreSQL database cluster
pg_controldata -- display control information of a PostgreSQL database cluster
pg_ctl -- initialize, start, stop, or control a PostgreSQL server
pg_resetxlog -- reset the write-ahead log and other control information of a PostgreSQL database cluster
postgres -- PostgreSQL database server
postmaster -- PostgreSQL database server

PrevHomeNext
Examples SQL Commands
\ No newline at end of file diff --git a/doc/src/sgml/html/regress-coverage.html b/doc/src/sgml/html/regress-coverage.html new file mode 100644 index 000000000..4d91e02b9 --- /dev/null +++ b/doc/src/sgml/html/regress-coverage.html @@ -0,0 +1,203 @@ + +Test Coverage Examination
PostgreSQL 9.2.2 Documentation
PrevUpChapter 30. Regression TestsNext

30.4. Test Coverage Examination

The PostgreSQL source code can be compiled with coverage testing + instrumentation, so that it becomes possible to examine which + parts of the code are covered by the regression tests or any other + test suite that is run with the code. This is currently supported + when compiling with GCC and requires the gcov + and lcov programs. +

A typical workflow would look like this: +

./configure --enable-coverage ... OTHER OPTIONS ...
+gmake
+gmake check # or other test suite
+gmake coverage-html

+ Then point your HTML browser + to coverage/index.html. + The gmake commands also work in subdirectories. +

To reset the execution counts between test runs, run: +

gmake coverage-clean

+


PrevHomeNext
Variant Comparison FilesUpClient Interfaces
\ No newline at end of file diff --git a/doc/src/sgml/html/regress-evaluation.html b/doc/src/sgml/html/regress-evaluation.html new file mode 100644 index 000000000..5fa544141 --- /dev/null +++ b/doc/src/sgml/html/regress-evaluation.html @@ -0,0 +1,521 @@ + +Test Evaluation
PostgreSQL 9.2.2 Documentation
PrevUpChapter 30. Regression TestsNext

30.2. Test Evaluation

Some properly installed and fully functional + PostgreSQL installations can + "fail" some of these regression tests due to + platform-specific artifacts such as varying floating-point representation + and message wording. The tests are currently evaluated using a simple + diff comparison against the outputs + generated on a reference system, so the results are sensitive to + small system differences. When a test is reported as + "failed", always examine the differences between + expected and actual results; you might find that the + differences are not significant. Nonetheless, we still strive to + maintain accurate reference files across all supported platforms, + so it can be expected that all tests pass. +

The actual outputs of the regression tests are in files in the + src/test/regress/results directory. The test + script uses diff to compare each output + file against the reference outputs stored in the + src/test/regress/expected directory. Any + differences are saved for your inspection in + src/test/regress/regression.diffs. (Or you + can run diff yourself, if you prefer.) +

If for some reason a particular platform generates a "failure" + for a given test, but inspection of the output convinces you that + the result is valid, you can add a new comparison file to silence + the failure report in future test runs. See + Section 30.3 for details. +

30.2.1. Error Message Differences

Some of the regression tests involve intentional invalid input + values. Error messages can come from either the + PostgreSQL code or from the host + platform system routines. In the latter case, the messages can + vary between platforms, but should reflect similar + information. These differences in messages will result in a + "failed" regression test that can be validated by + inspection. +

30.2.2. Locale Differences

If you run the tests against a server that was + initialized with a collation-order locale other than C, then + there might be differences due to sort order and subsequent + failures. The regression test suite is set up to handle this + problem by providing alternate result files that together are + known to handle a large number of locales. +

To run the tests in a different locale when using the + temporary-installation method, pass the appropriate + locale-related environment variables on + the make command line, for example: +

gmake check LANG=de_DE.utf8

+ (The regression test driver unsets LC_ALL, so it + does not work to choose the locale using that variable.) To use + no locale, either unset all locale-related environment variables + (or set them to C) or use the following + special invocation: +

gmake check NO_LOCALE=1

+ When running the tests against an existing installation, the + locale setup is determined by the existing installation. To + change it, initialize the database cluster with a different + locale by passing the appropriate options + to initdb. +

In general, it is nevertheless advisable to try to run the + regression tests in the locale setup that is wanted for + production use, as this will exercise the locale- and + encoding-related code portions that will actually be used in + production. Depending on the operating system environment, you + might get failures, but then you will at least know what + locale-specific behaviors to expect when running real + applications. +

30.2.3. Date and Time Differences

Most of the date and time results are dependent on the time zone + environment. The reference files are generated for time zone + PST8PDT (Berkeley, California), and there will be + apparent failures if the tests are not run with that time zone setting. + The regression test driver sets environment variable + PGTZ to PST8PDT, which normally + ensures proper results. +

30.2.4. Floating-Point Differences

Some of the tests involve computing 64-bit floating-point numbers (double + precision) from table columns. Differences in + results involving mathematical functions of double + precision columns have been observed. The float8 and + geometry tests are particularly prone to small differences + across platforms, or even with different compiler optimization setting. + Human eyeball comparison is needed to determine the real + significance of these differences which are usually 10 places to + the right of the decimal point. +

Some systems display minus zero as -0, while others + just show 0. +

Some systems signal errors from pow() and + exp() differently from the mechanism + expected by the current PostgreSQL + code. +

30.2.5. Row Ordering Differences

You might see differences in which the same rows are output in a +different order than what appears in the expected file. In most cases +this is not, strictly speaking, a bug. Most of the regression test +scripts are not so pedantic as to use an ORDER BY for every single +SELECT, and so their result row orderings are not well-defined +according to the SQL specification. In practice, since we are +looking at the same queries being executed on the same data by the same +software, we usually get the same result ordering on all platforms, +so the lack of ORDER BY is not a problem. Some queries do exhibit +cross-platform ordering differences, however. When testing against an +already-installed server, ordering differences can also be caused by +non-C locale settings or non-default parameter settings, such as custom values +of work_mem or the planner cost parameters. +

Therefore, if you see an ordering difference, it's not something to +worry about, unless the query does have an ORDER BY that your +result is violating. However, please report it anyway, so that we can add an +ORDER BY to that particular query to eliminate the bogus +"failure" in future releases. +

You might wonder why we don't order all the regression test queries explicitly +to get rid of this issue once and for all. The reason is that that would +make the regression tests less useful, not more, since they'd tend +to exercise query plan types that produce ordered results to the +exclusion of those that don't. +

30.2.6. Insufficient Stack Depth

If the errors test results in a server crash + at the select infinite_recurse() command, it means that + the platform's limit on process stack size is smaller than the + max_stack_depth + + parameter indicates. This + can be fixed by running the server under a higher stack + size limit (4MB is recommended with the default value of + max_stack_depth). If you are unable to do that, an + alternative is to reduce the value of max_stack_depth. +

30.2.7. The "random" Test

The random test script is intended to produce + random results. In rare cases, this causes the random regression + test to fail. Typing: +

diff results/random.out expected/random.out

+ should produce only one or a few lines of differences. You need + not worry unless the random test fails repeatedly. +


PrevHomeNext
Running the TestsUpVariant Comparison Files
\ No newline at end of file diff --git a/doc/src/sgml/html/regress-run.html b/doc/src/sgml/html/regress-run.html new file mode 100644 index 000000000..7babaf60c --- /dev/null +++ b/doc/src/sgml/html/regress-run.html @@ -0,0 +1,549 @@ + +Running the Tests
PostgreSQL 9.2.2 Documentation
PrevUpChapter 30. Regression TestsNext

30.1. Running the Tests

The regression tests can be run against an already installed and + running server, or using a temporary installation within the build + tree. Furthermore, there is a "parallel" and a + "sequential" mode for running the tests. The + sequential method runs each test script alone, while the + parallel method starts up multiple server processes to run groups + of tests in parallel. Parallel testing gives confidence that + interprocess communication and locking are working correctly. +

30.1.1. Running the Tests Against a Temporary Installation

To run the parallel regression tests after building but before installation, + type: +

gmake check

+ in the top-level directory. (Or you can change to + src/test/regress and run the command there.) + This will first build several auxiliary files, such as + sample user-defined trigger functions, and then run the test driver + script. At the end you should see something like: +

=======================
+ All 115 tests passed.
+=======================

+ or otherwise a note about which tests failed. See Section 30.2 below before assuming that a + "failure" represents a serious problem. +

Because this test method runs a temporary server, it will not work + when you are the root user (since the server will not start as root). + If you already did the build as root, you do not have to start all + over. Instead, make the regression test directory writable by + some other user, log in as that user, and restart the tests. + For example: +

root# chmod -R a+w src/test/regress
+root# su - joeuser
+joeuser$ cd top-level build directory
+joeuser$ gmake check

+ (The only possible "security risk" here is that other + users might be able to alter the regression test results behind + your back. Use common sense when managing user permissions.) +

Alternatively, run the tests after installation. +

If you have configured PostgreSQL to install + into a location where an older PostgreSQL + installation already exists, and you perform gmake check + before installing the new version, you might find that the tests fail + because the new programs try to use the already-installed shared + libraries. (Typical symptoms are complaints about undefined symbols.) + If you wish to run the tests before overwriting the old installation, + you'll need to build with configure --disable-rpath. + It is not recommended that you use this option for the final installation, + however. +

The parallel regression test starts quite a few processes under your + user ID. Presently, the maximum concurrency is twenty parallel test + scripts, which means forty processes: there's a server process and a + psql process for each test script. + So if your system enforces a per-user limit on the number of processes, + make sure this limit is at least fifty or so, else you might get + random-seeming failures in the parallel test. If you are not in + a position to raise the limit, you can cut down the degree of parallelism + by setting the MAX_CONNECTIONS parameter. For example: +

gmake MAX_CONNECTIONS=10 check

+ runs no more than ten tests concurrently. +

30.1.2. Running the Tests Against an Existing Installation

To run the tests after installation (see Chapter 15), + initialize a data area and start the + server, as explained in Chapter 17, then type: +

gmake installcheck

+or for a parallel test: +

gmake installcheck-parallel

+ The tests will expect to contact the server at the local host and the + default port number, unless directed otherwise by PGHOST and + PGPORT environment variables. +

The source distribution also contains regression tests for the optional + procedural languages and for some of the contrib modules. + At present, these tests can be used only against an already-installed + server. To run the tests for all procedural languages that have been + built and installed, change to the src/pl directory of the + build tree and type: +

gmake installcheck

+ You can also do this in any of the subdirectories of src/pl + to run tests for just one procedural language. To run the tests for all + contrib modules that have them, change to the + contrib directory of the build tree and type: +

gmake installcheck

+ The contrib modules must have been built and installed first. + You can also do this in a subdirectory of contrib to run + the tests for just one module. +

30.1.3. Testing Hot Standby

The source distribution also contains regression tests of the static + behaviour of Hot Standby. These tests require a running primary server + and a running standby server that is accepting new WAL changes from the + primary using either file-based log shipping or streaming replication. + Those servers are not automatically created for you, nor is the setup + documented here. Please check the various sections of the documentation already + devoted to the required commands and related issues. +

First create a database called "regression" on the primary. +

psql -h primary -c "CREATE DATABASE regression"

+ Next, run a preparatory script on the primary in the regression database: + src/test/regress/sql/hs_primary_setup.sql, and + allow for the changes to propagate to the standby, for example +

psql -h primary -f src/test/regress/sql/hs_primary_setup.sql regression

+ Now confirm that the default connection for the tester is the standby + server under test and then run the standbycheck target from the regression + directory: +

cd src/test/regress
+gmake standbycheck

+

Some extreme behaviours can also be generated on the primary using the + script: src/test/regress/sql/hs_primary_extremes.sql + to allow the behaviour of the standby to be tested. +

Additional automated testing may be available in later releases. +

30.1.4. Locale and Encoding

By default, the tests against a temporary installation use the + locale defined in the current environment and the corresponding + database encoding as determined by initdb. It + can be useful to test different locales by setting the appropriate + environment variables, for example: +

gmake check LANG=C
+gmake check LC_COLLATE=en_US.utf8 LC_CTYPE=fr_CA.utf8

+ For implementation reasons, setting LC_ALL does not + work for this purpose; all the other locale-related environment + variables do work. +

When testing against an existing installation, the locale is + determined by the existing database cluster and cannot be set + separately for the test run. +

You can also choose the database encoding explicitly by setting + the variable ENCODING, for example: +

gmake check LANG=C ENCODING=EUC_JP

+ Setting the database encoding this way typically only makes sense + if the locale is C; otherwise the encoding is chosen automatically + from the locale, and specifying an encoding that does not match + the locale will result in an error. +

The encoding can be set for tests against a temporary or an + existing installation. +

30.1.5. Extra Tests

The regression test suite contains a few test files that are not + run by default, because they might be platform-dependent or take a + very long time to run. You can run these or other extra test + files by setting the variable EXTRA_TESTS. For + example, to run the numeric_big test: +

gmake check EXTRA_TESTS=numeric_big

+ To run the collation tests: +

gmake check EXTRA_TESTS=collate.linux.utf8 LANG=en_US.utf8

+ The collate.linux.utf8 test works only on Linux/glibc + platforms, and only when run in a database that uses UTF-8 encoding. +


PrevHomeNext
Regression TestsUpTest Evaluation
\ No newline at end of file diff --git a/doc/src/sgml/html/regress-variant.html b/doc/src/sgml/html/regress-variant.html new file mode 100644 index 000000000..3e80e7703 --- /dev/null +++ b/doc/src/sgml/html/regress-variant.html @@ -0,0 +1,360 @@ + +Variant Comparison Files
PostgreSQL 9.2.2 Documentation
PrevUpChapter 30. Regression TestsNext

30.3. Variant Comparison Files

Since some of the tests inherently produce environment-dependent + results, we have provided ways to specify alternate "expected" + result files. Each regression test can have several comparison files + showing possible results on different platforms. There are two + independent mechanisms for determining which comparison file is used + for each test. +

The first mechanism allows comparison files to be selected for + specific platforms. There is a mapping file, + src/test/regress/resultmap, that defines + which comparison file to use for each platform. + To eliminate bogus test "failures" for a particular platform, + you first choose or make a variant result file, and then add a line to the + resultmap file. +

Each line in the mapping file is of the form +

testname:output:platformpattern=comparisonfilename

+ The test name is just the name of the particular regression test + module. The output value indicates which output file to check. For the + standard regression tests, this is always out. The + value corresponds to the file extension of the output file. + The platform pattern is a pattern in the style of the Unix + tool expr (that is, a regular expression with an implicit + ^ anchor at the start). It is matched against the + platform name as printed by config.guess. + The comparison file name is the base name of the substitute result + comparison file. +

For example: some systems interpret very small floating-point values + as zero, rather than reporting an underflow error. This causes a + few differences in the float8 regression test. + Therefore, we provide a variant comparison file, + float8-small-is-zero.out, which includes + the results to be expected on these systems. To silence the bogus + "failure" message on OpenBSD + platforms, resultmap includes: +

float8:out:i.86-.*-openbsd=float8-small-is-zero.out

+ which will trigger on any machine where the output of + config.guess matches i.86-.*-openbsd. + Other lines + in resultmap select the variant comparison file for other + platforms where it's appropriate. +

The second selection mechanism for variant comparison files is + much more automatic: it simply uses the "best match" among + several supplied comparison files. The regression test driver + script considers both the standard comparison file for a test, + testname.out, and variant files named + testname_digit.out + (where the digit is any single digit + 0-9). If any such file is an exact match, + the test is considered to pass; otherwise, the one that generates + the shortest diff is used to create the failure report. (If + resultmap includes an entry for the particular + test, then the base testname is the substitute + name given in resultmap.) +

For example, for the char test, the comparison file + char.out contains results that are expected + in the C and POSIX locales, while + the file char_1.out contains results sorted as + they appear in many other locales. +

The best-match mechanism was devised to cope with locale-dependent + results, but it can be used in any situation where the test results + cannot be predicted easily from the platform name alone. A limitation of + this mechanism is that the test driver cannot tell which variant is + actually "correct" for the current environment; it will just pick + the variant that seems to work best. Therefore it is safest to use this + mechanism only for variant results that you are willing to consider + equally valid in all contexts. +


PrevHomeNext
Test EvaluationUpTest Coverage Examination
\ No newline at end of file diff --git a/doc/src/sgml/html/regress.html b/doc/src/sgml/html/regress.html new file mode 100644 index 000000000..b6d941e9a --- /dev/null +++ b/doc/src/sgml/html/regress.html @@ -0,0 +1,274 @@ + +Regression Tests

Chapter 30. Regression Tests

The regression tests are a comprehensive set of tests for the SQL + implementation in PostgreSQL. They test + standard SQL operations as well as the extended capabilities of + PostgreSQL. +


PrevHomeNext
WAL InternalsUpRunning the Tests
\ No newline at end of file diff --git a/doc/src/sgml/html/release-0-01.html b/doc/src/sgml/html/release-0-01.html new file mode 100644 index 000000000..d9571b737 --- /dev/null +++ b/doc/src/sgml/html/release-0-01.html @@ -0,0 +1,181 @@ + +Postgres95 Release 0.01

E.229. Postgres95 Release 0.01

Release Date: 1995-05-01

Initial release.


PrevHomeNext
Postgres95 Release 0.02UpAdditional Supplied Modules
\ No newline at end of file diff --git a/doc/src/sgml/html/release-0-02.html b/doc/src/sgml/html/release-0-02.html new file mode 100644 index 000000000..b6708b206 --- /dev/null +++ b/doc/src/sgml/html/release-0-02.html @@ -0,0 +1,228 @@ + +Postgres95 Release 0.02

E.228. Postgres95 Release 0.02

Release Date: 1995-05-25

E.228.1. Changes

Incompatible changes:
+ * The SQL statement for creating a database is 'CREATE DATABASE' instead
+   of 'CREATEDB'. Similarly, dropping a database is 'DROP DATABASE' instead
+   of 'DESTROYDB'. However, the names of the executables 'createdb' and
+   'destroydb' remain the same.
+
+New tools:
+ * pgperl - a Perl (4.036) interface to Postgres95
+ * pg_dump - a utility for dumping out a postgres database into a
+        script file containing query commands. The script files are in a ASCII
+        format and can be used to reconstruct the database, even on other
+        machines and other architectures. (Also good for converting
+        a Postgres 4.2 database to Postgres95 database.)
+
+The following ports have been incorporated into postgres95-beta-0.02:
+ * the NetBSD port by Alistair Crooks
+ * the AIX port by Mike Tung
+ * the Windows NT port by Jon Forrest (more stuff but not done yet)
+ * the Linux ELF port by Brian Gallew
+
+The following bugs have been fixed in postgres95-beta-0.02:
+ * new lines not escaped in COPY OUT and problem with COPY OUT when first
+   attribute is a '.'
+ * cannot type return to use the default user id in createuser
+ * SELECT DISTINCT on big tables crashes
+ * Linux installation problems
+ * monitor doesn't allow use of 'localhost' as PGHOST
+ * psql core dumps when doing \c or \l
+ * the "pgtclsh" target missing from src/bin/pgtclsh/Makefile
+ * libpgtcl has a hard-wired default port number
+ * SELECT DISTINCT INTO TABLE hangs
+ * CREATE TYPE doesn't accept 'variable' as the internallength
+ * wrong result using more than 1 aggregate in a SELECT


PrevHomeNext
Postgres95 Release 0.03UpPostgres95 Release 0.01
\ No newline at end of file diff --git a/doc/src/sgml/html/release-0-03.html b/doc/src/sgml/html/release-0-03.html new file mode 100644 index 000000000..7ef1e9908 --- /dev/null +++ b/doc/src/sgml/html/release-0-03.html @@ -0,0 +1,297 @@ + +Postgres95 Release 0.03

E.227. Postgres95 Release 0.03

Release Date: 1995-07-21

E.227.1. Changes

Incompatible changes:
+ * BETA-0.3 IS INCOMPATIBLE WITH DATABASES CREATED WITH PREVIOUS VERSIONS
+   (due to system catalog changes and indexing structure changes).
+ * double-quote (") is deprecated as a quoting character for string literals;
+   you need to convert them to single quotes ('). 
+ * name of aggregates (eg. int4sum) are renamed in accordance with the
+   SQL standard (eg. sum).
+ * CHANGE ACL syntax is replaced by GRANT/REVOKE syntax.
+ * float literals (eg. 3.14) are now of type float4 (instead of float8 in
+   previous releases); you might have to do typecasting if you depend on it
+   being of type float8.  If you neglect to do the typecasting and you assign
+   a float literal to a field of type float8, you might get incorrect values
+   stored!
+ * LIBPQ has been totally revamped so that frontend applications
+   can connect to multiple backends
+ * the usesysid field in pg_user has been changed from int2 to int4 to
+   allow wider range of Unix user ids.
+ * the netbsd/freebsd/bsd o/s ports have been consolidated into a
+   single BSD44_derived port.  (thanks to Alistair Crooks)
+
+SQL standard-compliance (the following details changes that makes postgres95
+more compliant to the SQL-92 standard):
+ * the following SQL types are now built-in: smallint, int(eger), float, real,
+   char(N), varchar(N), date and time.
+
+   The following are aliases to existing postgres types:
+                smallint -> int2
+                integer, int -> int4
+                float, real  -> float4
+   char(N) and varchar(N) are implemented as truncated text types. In
+   addition, char(N) does blank-padding.
+ * single-quote (') is used for quoting string literals; '' (in addition to
+   \') is supported as means of inserting a single quote in a string
+ * SQL standard aggregate names (MAX, MIN, AVG, SUM, COUNT) are used
+   (Also, aggregates can now be overloaded, i.e. you can define your
+   own MAX aggregate to take in a user-defined type.)
+ * CHANGE ACL removed. GRANT/REVOKE syntax added.
+   - Privileges can be given to a group using the "GROUP" key word.
+        For example:
+                GRANT SELECT ON foobar TO GROUP my_group;
+        The key word 'PUBLIC' is also supported to mean all users.
+
+        Privileges can only be granted or revoked to one user or group
+        at a time.
+
+        "WITH GRANT OPTION" is not supported.  Only class owners can change
+        access control
+   - The default access control is to grant users readonly access.
+     You must explicitly grant insert/update access to users.  To change
+     this, modify the line in
+                src/backend/utils/acl.h
+     that defines ACL_WORLD_DEFAULT
+
+Bug fixes:
+ * the bug where aggregates of empty tables were not run has been fixed. Now,
+   aggregates run on empty tables will return the initial conditions of the
+   aggregates. Thus, COUNT of an empty  table will now properly return 0.
+   MAX/MIN of an empty table will return a row of value NULL.
+ * allow the use of \; inside the monitor
+ * the LISTEN/NOTIFY asynchronous notification mechanism now work
+ * NOTIFY in rule action bodies now work
+ * hash indexes work, and access methods in general should perform better.
+   creation of large btree indexes should be much faster.  (thanks to Paul
+   Aoki)
+
+Other changes and enhancements:
+ * addition of an EXPLAIN statement used for explaining the query execution
+   plan (eg. "EXPLAIN SELECT * FROM EMP" prints out the execution plan for
+   the query).
+ * WARN and NOTICE messages no longer have timestamps on them. To turn on
+   timestamps of error messages, uncomment the line in
+   src/backend/utils/elog.h:
+        /* define ELOG_TIMESTAMPS */
+ * On an access control violation, the message
+        "Either no such class or insufficient privilege"
+   will be given.  This is the same message that is returned when
+   a class is not found.  This dissuades non-privileged users from
+   guessing the existence of privileged classes.
+ * some additional system catalog changes have been made that are not
+   visible to the user.
+
+libpgtcl changes:
+ * The -oid option has been added to the "pg_result" tcl command.
+   pg_result -oid returns oid of the last row inserted.   If the
+   last command was not an INSERT, then pg_result -oid returns "".
+ * the large object interface is available as pg_lo* tcl commands:
+   pg_lo_open, pg_lo_close, pg_lo_creat, etc.
+
+Portability enhancements and New Ports:
+ * flex/lex problems have been cleared up.  Now, you should be able to use
+   flex instead of lex on any platforms.  We no longer make assumptions of
+   what lexer you use based on the platform you use.
+ * The Linux-ELF port is now supported.  Various configuration have been
+   tested:  The following configuration is known to work:
+        kernel 1.2.10, gcc 2.6.3, libc 4.7.2, flex 2.5.2, bison 1.24
+   with everything in ELF format,
+
+New utilities:
+ * ipcclean added to the distribution
+   ipcclean usually does not need to be run, but if your backend crashes
+   and leaves shared memory segments hanging around, ipcclean will
+   clean them up for you.
+
+New documentation:
+ * the user manual has been revised and libpq documentation added.


PrevHomeNext
Release 1.0UpPostgres95 Release 0.02
\ No newline at end of file diff --git a/doc/src/sgml/html/release-1-0.html b/doc/src/sgml/html/release-1-0.html new file mode 100644 index 000000000..37b53d6dd --- /dev/null +++ b/doc/src/sgml/html/release-1-0.html @@ -0,0 +1,231 @@ + +Release 1.0

E.226. Release 1.0

Release Date: 1995-09-05

E.226.1. Changes

Copyright change:
+ * The copyright of Postgres 1.0 has been loosened to be freely modifiable
+   and modifiable for any purpose.  Please read the COPYRIGHT file.
+   Thanks to Professor Michael Stonebraker for making this possible.
+
+Incompatibilities:
+ *  date formats have to be MM-DD-YYYY (or DD-MM-YYYY if you're using
+   EUROPEAN STYLE).  This follows SQL-92 specs.
+ *  "delimiters" is now a key word
+
+Enhancements:
+ *  sql LIKE syntax has been added
+ *  copy command now takes an optional USING DELIMITER specification.
+   delimiters can be any single-character string.
+ *  IRIX 5.3 port has been added.
+   Thanks to Paul Walmsley and others.
+ *  updated pg_dump to work with new libpq
+ *  \d has been added psql
+   Thanks to Keith Parks
+ *  regexp performance for architectures that use POSIX regex has been
+   improved due to caching of precompiled patterns.
+   Thanks to Alistair Crooks
+ *  a new version of libpq++
+   Thanks to William Wanders
+
+Bug fixes:
+ *  arbitrary userids can be specified in the createuser script
+ *  \c to connect to other databases in psql now works.
+ *  bad pg_proc entry for float4inc() is fixed
+ *  users with usecreatedb field set can now create databases without
+   having to be usesuper
+ *  remove access control entries when the entry no longer has any
+   privileges
+ *  fixed non-portable datetimes implementation
+ *  added kerberos flags to the src/backend/Makefile
+ *  libpq now works with kerberos
+ *  typographic errors in the user manual have been corrected.
+ *  btrees with multiple index never worked, now we tell you they don't
+   work when you try to use them


PrevHomeNext
Release 1.01UpPostgres95 Release 0.03
\ No newline at end of file diff --git a/doc/src/sgml/html/release-1-01.html b/doc/src/sgml/html/release-1-01.html new file mode 100644 index 000000000..87fd2b121 --- /dev/null +++ b/doc/src/sgml/html/release-1-01.html @@ -0,0 +1,424 @@ + +Release 1.01

E.225. Release 1.01

Release Date: 1996-02-23

E.225.1. Migration from version 1.0 to version 1.01

The following notes are for the benefit of users who want to migrate +databases from Postgres95 1.0 to Postgres95 1.01.

If you are starting afresh with Postgres95 1.01 and do not need +to migrate old databases, you do not need to read any further.

In order to Postgres95 version 1.01 with databases created with +Postgres95 version 1.0, the following steps are required:

  1. Set the definition of NAMEDATALEN in src/Makefile.global to 16 + and OIDNAMELEN to 20.

  2. Decide whether you want to use Host based authentication.

    1. If you do, you must create a file name pg_hba in your top-level data + directory (typically the value of your $PGDATA). src/libpq/pg_hba + shows an example syntax.

    2. If you do not want host-based authentication, you can comment out + the line: +

      HBA = 1

      + in src/Makefile.global

      Note that host-based authentication is turned on by default, and if + you do not take steps A or B above, the out-of-the-box 1.01 will + not allow you to connect to 1.0 databases.

  3. Compile and install 1.01, but DO NOT do the initdb step.

  4. Before doing anything else, terminate your 1.0 postmaster, and + backup your existing $PGDATA directory.

  5. Set your PGDATA environment variable to your 1.0 databases, but set up + path up so that 1.01 binaries are being used.

  6. Modify the file $PGDATA/PG_VERSION from 5.0 to 5.1

  7. Start up a new 1.01 postmaster

  8. Add the new built-in functions and operators of 1.01 to 1.0 + databases. This is done by running the new 1.01 server against + your own 1.0 database and applying the queries attached and saving + in the file 1.0_to_1.01.sql. This can be done easily through psql. + If your 1.0 database is name testdb: + +

    % psql testdb -f 1.0_to_1.01.sql

    + +and then execute the following commands (cut and paste from here): + +

    -- add builtin functions that are new to 1.01
    +
    +create function int4eqoid (int4, oid) returns bool as 'foo'
    +language 'internal';
    +create function oideqint4 (oid, int4) returns bool as 'foo'
    +language 'internal';
    +create function char2icregexeq (char2, text) returns bool as 'foo'
    +language 'internal';
    +create function char2icregexne (char2, text) returns bool as 'foo'
    +language 'internal';
    +create function char4icregexeq (char4, text) returns bool as 'foo'
    +language 'internal';
    +create function char4icregexne (char4, text) returns bool as 'foo'
    +language 'internal';
    +create function char8icregexeq (char8, text) returns bool as 'foo'
    +language 'internal';
    +create function char8icregexne (char8, text) returns bool as 'foo'
    +language 'internal';
    +create function char16icregexeq (char16, text) returns bool as 'foo'
    +language 'internal';
    +create function char16icregexne (char16, text) returns bool as 'foo'
    +language 'internal';
    +create function texticregexeq (text, text) returns bool as 'foo'
    +language 'internal';
    +create function texticregexne (text, text) returns bool as 'foo'
    +language 'internal';
    +
    +-- add builtin functions that are new to 1.01
    +
    +create operator = (leftarg = int4, rightarg = oid, procedure = int4eqoid);
    +create operator = (leftarg = oid, rightarg = int4, procedure = oideqint4);
    +create operator ~* (leftarg = char2, rightarg = text, procedure = char2icregexeq);
    +create operator !~* (leftarg = char2, rightarg = text, procedure = char2icregexne);
    +create operator ~* (leftarg = char4, rightarg = text, procedure = char4icregexeq);
    +create operator !~* (leftarg = char4, rightarg = text, procedure = char4icregexne);
    +create operator ~* (leftarg = char8, rightarg = text, procedure = char8icregexeq);
    +create operator !~* (leftarg = char8, rightarg = text, procedure = char8icregexne);
    +create operator ~* (leftarg = char16, rightarg = text, procedure = char16icregexeq);
    +create operator !~* (leftarg = char16, rightarg = text, procedure = char16icregexne);
    +create operator ~* (leftarg = text, rightarg = text, procedure = texticregexeq);
    +create operator !~* (leftarg = text, rightarg = text, procedure = texticregexne);

E.225.2. Changes

Incompatibilities:
+ * 1.01 is backwards compatible with 1.0 database provided the user
+   follow the steps outlined in the MIGRATION_from_1.0_to_1.01 file.
+   If those steps are not taken, 1.01 is not compatible with 1.0 database.
+
+Enhancements:
+ * added PQdisplayTuples() to libpq and changed monitor and psql to use it
+ * added NeXT port (requires SysVIPC implementation)
+ * added CAST .. AS ... syntax
+ * added ASC and DESC key words
+ * added 'internal' as a possible language for CREATE FUNCTION
+   internal functions are C functions which have been statically linked
+   into the postgres backend.
+ * a new type "name" has been added for system identifiers (table names,
+   attribute names, etc.)  This replaces the old char16 type.   The
+   of name is set by the NAMEDATALEN #define in src/Makefile.global
+ * a readable reference manual that describes the query language.
+ * added host-based access control.  A configuration file ($PGDATA/pg_hba)
+   is used to hold the configuration data.  If host-based access control
+   is not desired, comment out HBA=1 in src/Makefile.global.
+ * changed regex handling to be uniform use of Henry Spencer's regex code
+   regardless of platform.  The regex code is included in the distribution
+ * added functions and operators for case-insensitive regular expressions.
+   The operators are ~* and !~*.
+ * pg_dump uses COPY instead of SELECT loop for better performance
+
+Bug fixes:
+ * fixed an optimizer bug that was causing core dumps when
+   functions calls were used in comparisons in the WHERE clause
+ * changed all uses of getuid to geteuid so that effective uids are used
+ * psql now returns non-zero status on errors when using -c
+ * applied public patches 1-14


PrevHomeNext
Release 1.02UpRelease 1.0
\ No newline at end of file diff --git a/doc/src/sgml/html/release-1-02.html b/doc/src/sgml/html/release-1-02.html new file mode 100644 index 000000000..c61a51281 --- /dev/null +++ b/doc/src/sgml/html/release-1-02.html @@ -0,0 +1,336 @@ + +Release 1.02

E.224. Release 1.02

Release Date: 1996-08-01

E.224.1. Migration from version 1.02 to version 1.02.1

Here is a new migration file for 1.02.1. It includes the 'copy' change +and a script to convert old ASCII files.

Note: The following notes are for the benefit of users who want to migrate +databases from Postgres95 1.01 and 1.02 to Postgres95 1.02.1.

If you are starting afresh with Postgres95 1.02.1 and do not need +to migrate old databases, you do not need to read any further.

In order to upgrade older Postgres95 version 1.01 or 1.02 databases to +version 1.02.1, the following steps are required:

  1. Start up a new 1.02.1 postmaster

  2. Add the new built-in functions and operators of 1.02.1 to 1.01 or 1.02 + databases. This is done by running the new 1.02.1 server against + your own 1.01 or 1.02 database and applying the queries attached at + the end of the file. This can be done easily through psql. If your + 1.01 or 1.02 database is named testdb and you have cut the commands + from the end of this file and saved them in addfunc.sql: +

    % psql testdb -f addfunc.sql

    + +Those upgrading 1.02 databases will get a warning when executing the +last two statements in the file because they are already present in 1.02. This is +not a cause for concern.

E.224.2. Dump/Reload Procedure

If you are trying to reload a pg_dump or text-mode, copy tablename to +stdout generated with a previous version, you will need to run the +attached sed script on the ASCII file before loading it into the +database. The old format used '.' as end-of-data, while '\.' is now the +end-of-data marker. Also, empty strings are now loaded in as '' rather +than NULL. See the copy manual page for full details. + +

sed 's/^\.$/\\./g' <in_file >out_file

If you are loading an older binary copy or non-stdout copy, there is no +end-of-data character, and hence no conversion necessary. + +

-- following lines added by agc to reflect the case-insensitive
+-- regexp searching for varchar (in 1.02), and bpchar (in 1.02.1)
+create operator ~* (leftarg = bpchar, rightarg = text, procedure = texticregexeq);
+create operator !~* (leftarg = bpchar, rightarg = text, procedure = texticregexne);
+create operator ~* (leftarg = varchar, rightarg = text, procedure = texticregexeq);
+create operator !~* (leftarg = varchar, rightarg = text, procedure = texticregexne);

E.224.3. Changes

Source code maintenance and development
+ * worldwide team of volunteers
+ * the source tree now in CVS at ftp.ki.net
+
+Enhancements
+ * psql (and underlying libpq library) now has many more options for
+   formatting output, including HTML
+ * pg_dump now output the schema and/or the data, with many fixes to
+   enhance completeness.
+ * psql used in place of monitor in administration shell scripts.
+   monitor to be deprecated in next release.
+ * date/time functions enhanced
+ * NULL insert/update/comparison fixed/enhanced
+ * TCL/TK lib and shell fixed to work with both tck7.4/tk4.0 and tcl7.5/tk4.1
+
+Bug Fixes (almost too numerous to mention)
+ * indexes
+ * storage management
+ * check for NULL pointer before dereferencing
+ * Makefile fixes
+
+New Ports
+ * added SolarisX86 port
+ * added BSD/OS 2.1 port
+ * added DG/UX port


PrevHomeNext
Release 1.09UpRelease 1.01
\ No newline at end of file diff --git a/doc/src/sgml/html/release-1-09.html b/doc/src/sgml/html/release-1-09.html new file mode 100644 index 000000000..d64390cd8 --- /dev/null +++ b/doc/src/sgml/html/release-1-09.html @@ -0,0 +1,177 @@ + +Release 1.09

E.223. Release 1.09

Release Date: 1996-11-04

Sorry, we didn't keep track of changes from 1.02 to 1.09. Some of +the changes listed in 6.0 were actually included in the 1.02.1 to 1.09 +releases.


PrevHomeNext
Release 6.0UpRelease 1.02
\ No newline at end of file diff --git a/doc/src/sgml/html/release-6-0.html b/doc/src/sgml/html/release-6-0.html new file mode 100644 index 000000000..306a731e1 --- /dev/null +++ b/doc/src/sgml/html/release-6-0.html @@ -0,0 +1,319 @@ + +Release 6.0

E.222. Release 6.0

Release Date: 1997-01-29

A dump/restore is required for those wishing to migrate data from +previous releases of PostgreSQL.

E.222.1. Migration from version 1.09 to version 6.0

This migration requires a complete dump of the 1.09 database and a +restore of the database in 6.0.

E.222.2. Migration from pre-1.09 to version 6.0

Those migrating from earlier 1.* releases should first upgrade to 1.09 +because the COPY output format was improved from the 1.02 release.

E.222.3. Changes

Bug Fixes
+---------
+ALTER TABLE bug - running postgres process needs to re-read table definition
+Allow vacuum to be run on one table or entire database(Bruce)
+Array fixes
+Fix array over-runs of memory writes(Kurt)
+Fix elusive btree range/non-range bug(Dan)
+Fix for hash indexes on some types like time and date
+Fix for pg_log size explosion
+Fix permissions on lo_export()(Bruce)
+Fix uninitialized reads of memory(Kurt)
+Fixed ALTER TABLE ... char(3) bug(Bruce)
+Fixed a few small memory leaks
+Fixed EXPLAIN handling of options and changed full_path option name
+Fixed output of group acl privileges
+Memory leaks (hunt and destroy with tools like Purify(Kurt)
+Minor improvements to rules system
+NOTIFY fixes
+New asserts for run-checking
+Overhauled parser/analyze code to properly report errors and increase speed
+Pg_dump -d now handles NULL's properly(Bruce)
+Prevent SELECT NULL from crashing server (Bruce)
+Properly report errors when INSERT ... SELECT columns did not match
+Properly report errors when insert column names were not correct
+psql \g filename now works(Bruce)
+psql fixed problem with multiple statements on one line with multiple outputs
+Removed duplicate system OIDs
+SELECT * INTO TABLE . GROUP/ORDER BY gives unlink error if table exists(Bruce)
+Several fixes for queries that crashed the backend
+Starting quote in insert string errors(Bruce)
+Submitting an empty query now returns empty status, not just " " query(Bruce)
+
+Enhancements
+------------
+Add EXPLAIN manual page(Bruce)
+Add UNIQUE index capability(Dan)
+Add hostname/user level access control rather than just hostname and user
+Add synonym of != for <>(Bruce)
+Allow "select oid,* from table"
+Allow BY,ORDER BY to specify columns by number, or by non-alias table.column(Bruce)
+Allow COPY from the frontend(Bryan)
+Allow GROUP BY to use alias column name(Bruce)
+Allow actual compression, not just reuse on the same page(Vadim)
+Allow installation-configuration option to auto-add all local users(Bryan)
+Allow libpq to distinguish between text value '' and null(Bruce)
+Allow non-postgres users with createdb privs to destroydb's
+Allow restriction on who can create C functions(Bryan)
+Allow restriction on who can do backend COPY(Bryan)
+Can shrink tables, pg_time and pg_log(Vadim & Erich)
+Change debug level 2 to print queries only, changed debug heading layout(Bruce)
+Change default decimal constant representation from float4 to float8(Bruce)
+European date format now set when postmaster is started
+Execute lowercase function names if not found with exact case
+Fixes for aggregate/GROUP processing, allow 'select sum(func(x),sum(x+y) from z'
+Gist now included in the distribution(Marc)
+Idend authentication of local users(Bryan)
+Implement BETWEEN qualifier(Bruce)
+Implement IN qualifier(Bruce)
+libpq has PQgetisnull()(Bruce)
+libpq++ improvements
+New options to initdb(Bryan)
+Pg_dump allow dump of OIDs(Bruce)
+Pg_dump create indexes after tables are loaded for speed(Bruce)
+Pg_dumpall dumps all databases, and the user table
+Pginterface additions for NULL values(Bruce)
+Prevent postmaster from being run as root
+psql \h and \? is now readable(Bruce)
+psql allow backslashed, semicolons anywhere on the line(Bruce)
+psql changed command prompt for lines in query or in quotes(Bruce)
+psql char(3) now displays as (bp)char in \d output(Bruce)
+psql return code now more accurate(Bryan?)
+psql updated help syntax(Bruce)
+Re-visit and fix vacuum(Vadim)
+Reduce size of regression diffs, remove timezone name difference(Bruce)
+Remove compile-time parameters to enable binary distributions(Bryan)
+Reverse meaning of HBA masks(Bryan)
+Secure Authentication of local users(Bryan)
+Speed up vacuum(Vadim)
+Vacuum now had VERBOSE option(Bruce)
+
+Source tree changes
+-------------------
+All functions now have prototypes that are compared against the calls
+Allow asserts to be disabled easily from Makefile.global(Bruce)
+Change oid constants used in code to #define names
+Decoupled sparc and solaris defines(Kurt)
+Gcc -Wall compiles cleanly with warnings only from unfixable constructs
+Major include file reorganization/reduction(Marc)
+Make now stops on compile failure(Bryan)
+Makefile restructuring(Bryan, Marc)
+Merge bsdi_2_1 to bsdi(Bruce)
+Monitor program removed
+Name change from Postgres95 to PostgreSQL
+New config.h file(Marc, Bryan)
+PG_VERSION now set to 6.0 and used by postmaster
+Portability additions, including Ultrix, DG/UX, AIX, and Solaris
+Reduced the number of #define's, centralized #define's
+Remove duplicate OIDS in system tables(Dan)
+Remove duplicate system catalog info or report mismatches(Dan)
+Removed many os-specific #define's
+Restructured object file generation/location(Bryan, Marc)
+Restructured port-specific file locations(Bryan, Marc)
+Unused/uninitialized variables corrected


PrevHomeNext
Release 6.1UpRelease 1.09
\ No newline at end of file diff --git a/doc/src/sgml/html/release-6-1-1.html b/doc/src/sgml/html/release-6-1-1.html new file mode 100644 index 000000000..0c57fc0b8 --- /dev/null +++ b/doc/src/sgml/html/release-6-1-1.html @@ -0,0 +1,217 @@ + +Release 6.1.1

E.220. Release 6.1.1

Release Date: 1997-07-22

E.220.1. Migration from version 6.1 to version 6.1.1

This is a minor bug-fix release. A dump/reload is not required from version 6.1, +but is required from any release prior to 6.1. +Refer to the release notes for 6.1 for more details.

E.220.2. Changes

fix for SET with options (Thomas)
+allow pg_dump/pg_dumpall to preserve ownership of all tables/objects(Bruce)
+new psql \connect option allows changing usernames without changing databases
+fix for initdb --debug option(Yoshihiko Ichikawa))
+lextest cleanup(Bruce)
+hash fixes(Vadim)
+fix date/time month boundary arithmetic(Thomas)
+fix timezone daylight handling for some ports(Thomas, Bruce, Tatsuo)
+timestamp overhauled to use standard functions(Thomas)
+other code cleanup in date/time routines(Thomas)
+psql's \d now case-insensitive(Bruce)
+psql's backslash commands can now have trailing semicolon(Bruce)
+fix memory leak in psql when using \g(Bruce)
+major fix for endian handling of communication to server(Thomas, Tatsuo)
+Fix for Solaris assembler and include files(Yoshihiko Ichikawa)
+allow underscores in usernames(Bruce)
+pg_dumpall now returns proper status, portability fix(Bruce)

+


PrevHomeNext
Release 6.2UpRelease 6.1
\ No newline at end of file diff --git a/doc/src/sgml/html/release-6-1.html b/doc/src/sgml/html/release-6-1.html new file mode 100644 index 000000000..544fbc70b --- /dev/null +++ b/doc/src/sgml/html/release-6-1.html @@ -0,0 +1,381 @@ + +Release 6.1

E.221. Release 6.1

Release Date: 1997-06-08

The regression tests have been adapted and extensively modified for the + 6.1 release of PostgreSQL.

Three new data types (datetime, timespan, and circle) have been added to + the native set of PostgreSQL types. Points, boxes, paths, and polygons + have had their output formats made consistent across the data types. + The polygon output in misc.out has only been spot-checked for correctness + relative to the original regression output.

PostgreSQL 6.1 introduces a new, alternate +optimizer which uses genetic + algorithms. These algorithms introduce a random behavior in the ordering + of query results when the query contains multiple qualifiers or multiple + tables (giving the optimizer a choice on order of evaluation). Several + regression tests have been modified to explicitly order the results, and + hence are insensitive to optimizer choices. A few regression tests are + for data types which are inherently unordered (e.g. points and time + intervals) and tests involving those types are explicitly bracketed with + set geqo to 'off' and reset geqo.

The interpretation of array specifiers (the curly braces around atomic + values) appears to have changed sometime after the original regression + tests were generated. The current ./expected/*.out files reflect this + new interpretation, which might not be correct!

The float8 regression test fails on at least some platforms. This is due + to differences in implementations of pow() and exp() and the signaling + mechanisms used for overflow and underflow conditions.

The "random" results in the random test should cause the + "random" test to be "failed", since the + regression tests are evaluated using a simple diff. However, + "random" does not seem to produce random results on my test + machine (Linux/gcc/i686).

E.221.1. Migration to Version 6.1

This migration requires a complete dump of the 6.0 database and a +restore of the database in 6.1.

Those migrating from earlier 1.* releases should first upgrade to 1.09 +because the COPY output format was improved from the 1.02 release.

E.221.2. Changes

Bug Fixes
+---------
+packet length checking in library routines
+lock manager priority patch
+check for under/over flow of float8(Bruce)
+multitable join fix(Vadim)
+SIGPIPE crash fix(Darren)
+large object fixes(Sven)
+allow btree indexes to handle NULLs(Vadim)
+timezone fixes(D'Arcy)
+select SUM(x) can return NULL on no rows(Thomas)
+internal optimizer, executor bug fixes(Vadim)
+fix problem where inner loop in < or <= has no rows(Vadim)
+prevent re-commuting join index clauses(Vadim)
+fix join clauses for multiple tables(Vadim)
+fix hash, hashjoin for arrays(Vadim)
+fix btree for abstime type(Vadim)
+large object fixes(Raymond)
+fix buffer leak in hash indexes (Vadim)
+fix rtree for use in inner scan (Vadim)
+fix gist for use in inner scan, cleanups (Vadim, Andrea)
+avoid unnecessary local buffers allocation (Vadim, Massimo)
+fix local buffers leak in transaction aborts (Vadim)
+fix file manager memmory leaks, cleanups (Vadim, Massimo)
+fix storage manager memmory leaks (Vadim)
+fix btree duplicates handling (Vadim)
+fix deleted rows reincarnation caused by vacuum (Vadim)
+fix SELECT varchar()/char() INTO TABLE made zero-length fields(Bruce)
+many psql, pg_dump, and libpq memory leaks fixed using Purify (Igor)
+
+Enhancements
+------------
+attribute optimization statistics(Bruce)
+much faster new btree bulk load code(Paul)
+BTREE UNIQUE added to bulk load code(Vadim)
+new lock debug code(Massimo)
+massive changes to libpg++(Leo)
+new GEQO optimizer speeds table multitable optimization(Martin)
+new WARN message for non-unique insert into unique key(Marc)
+update x=-3, no spaces, now valid(Bruce)
+remove case-sensitive identifier handling(Bruce,Thomas,Dan)
+debug backend now pretty-prints tree(Darren)
+new Oracle character functions(Edmund)
+new plaintext password functions(Dan)
+no such class or insufficient privilege changed to distinct messages(Dan)
+new ANSI timestamp function(Dan)
+new ANSI Time and Date types (Thomas)
+move large chunks of data in backend(Martin)
+multicolumn btree indexes(Vadim)
+new SET var TO value command(Martin)
+update transaction status on reads(Dan)
+new locale settings for character types(Oleg)
+new SEQUENCE serial number generator(Vadim)
+GROUP BY function now possible(Vadim)
+re-organize regression test(Thomas,Marc)
+new optimizer operation weights(Vadim)
+new psql \z grant/permit option(Marc)
+new MONEY data type(D'Arcy,Thomas)
+tcp socket communication speed improved(Vadim)
+new VACUUM option for attribute statistics, and for certain columns (Vadim)
+many geometric type improvements(Thomas,Keith)
+additional regression tests(Thomas)
+new datestyle variable(Thomas,Vadim,Martin)
+more comparison operators for sorting types(Thomas)
+new conversion functions(Thomas)
+new more compact btree format(Vadim)
+allow pg_dumpall to preserve database ownership(Bruce)
+new SET GEQO=# and R_PLANS variable(Vadim)
+old (!GEQO) optimizer can use right-sided plans (Vadim)
+typechecking improvement in SQL parser(Bruce)
+new SET, SHOW, RESET commands(Thomas,Vadim)
+new \connect database USER option
+new destroydb -i option (Igor)
+new \dt and \di psql commands (Darren)
+SELECT "\n" now escapes newline (A. Duursma)
+new geometry conversion functions from old format (Thomas)
+
+Source tree changes
+-------------------
+new configuration script(Marc)
+readline configuration option added(Marc)
+OS-specific configuration options removed(Marc)
+new OS-specific template files(Marc)
+no more need to edit Makefile.global(Marc)
+re-arrange include files(Marc)
+nextstep patches (Gregor Hoffleit)
+removed Windows-specific code(Bruce)
+removed postmaster -e option, now only postgres -e option (Bruce)
+merge duplicate library code in front/backends(Martin)
+now works with eBones, international Kerberos(Jun)
+more shared library support
+c++ include file cleanup(Bruce)
+warn about buggy flex(Bruce)
+DG/UX, Ultrix, IRIX, AIX portability fixes


PrevHomeNext
Release 6.1.1UpRelease 6.0
\ No newline at end of file diff --git a/doc/src/sgml/html/release-6-2-1.html b/doc/src/sgml/html/release-6-2-1.html new file mode 100644 index 000000000..acbb060cc --- /dev/null +++ b/doc/src/sgml/html/release-6-2-1.html @@ -0,0 +1,253 @@ + +Release 6.2.1

E.218. Release 6.2.1

Release Date: 1997-10-17

6.2.1 is a bug-fix and usability release on 6.2.

Summary: + +

  • Allow strings to span lines, per SQL92.

  • Include example trigger function for inserting user names on table updates.

This is a minor bug-fix release on 6.2. +For upgrades from pre-6.2 systems, a full dump/reload is required. +Refer to the 6.2 release notes for instructions.

E.218.1. Migration from version 6.2 to version 6.2.1

This is a minor bug-fix release. A dump/reload is not required from version 6.2, +but is required from any release prior to 6.2.

In upgrading from version 6.2, if you choose to dump/reload you will find that +avg(money) is now calculated correctly. All other bug fixes take effect +upon updating the executables.

Another way to avoid dump/reload is to use the following SQL command +from psql to update the existing system table: + +

update pg_aggregate set aggfinalfn = 'cash_div_flt8'
+ where aggname = 'avg' and aggbasetype = 790;

This will need to be done to every existing database, including template1.

E.218.2. Changes

Allow TIME and TYPE column names(Thomas)
+Allow larger range of true/false as boolean values(Thomas)
+Support output of "now" and "current"(Thomas)
+Handle DEFAULT with INSERT of NULL properly(Vadim)
+Fix for relation reference counts problem in buffer manager(Vadim)
+Allow strings to span lines, like ANSI(Thomas)
+Fix for backward cursor with ORDER BY(Vadim)
+Fix avg(cash) computation(Thomas)
+Fix for specifying a column twice in ORDER/GROUP BY(Vadim)
+Documented new libpq function to return affected rows, PQcmdTuples(Bruce)
+Trigger function for inserting user names for INSERT/UPDATE(Brook Milligan)

+


PrevHomeNext
Release 6.3UpRelease 6.2
\ No newline at end of file diff --git a/doc/src/sgml/html/release-6-2.html b/doc/src/sgml/html/release-6-2.html new file mode 100644 index 000000000..cc9d75aff --- /dev/null +++ b/doc/src/sgml/html/release-6-2.html @@ -0,0 +1,338 @@ + +Release 6.2

E.219. Release 6.2

Release Date: 1997-10-02

A dump/restore is required for those wishing to migrate data from +previous releases of PostgreSQL.

E.219.1. Migration from version 6.1 to version 6.2

This migration requires a complete dump of the 6.1 database and a +restore of the database in 6.2.

Note that the pg_dump and pg_dumpall utility from 6.2 should be used +to dump the 6.1 database.

E.219.2. Migration from version 1.x to version 6.2

Those migrating from earlier 1.* releases should first upgrade to 1.09 +because the COPY output format was improved from the 1.02 release.

E.219.3. Changes

Bug Fixes
+---------
+Fix problems with pg_dump for inheritance, sequences, archive tables(Bruce)
+Fix compile errors on overflow due to shifts, unsigned, and bad prototypes
+        from Solaris(Diab Jerius)
+Fix bugs in geometric line arithmetic (bad intersection calculations)(Thomas)
+Check for geometric intersections at endpoints to avoid rounding ugliness(Thomas)
+Catch non-functional delete attempts(Vadim)
+Change time function names to be more consistent(Michael Reifenberg)
+Check for zero divides(Michael Reifenberg)
+Fix very old bug which made rows changed/inserted by a command
+       visible to the command itself (so we had multiple update of
+       updated rows, etc.)(Vadim)
+Fix for SELECT null, 'fail' FROM pg_am (Patrick)
+SELECT NULL as EMPTY_FIELD now allowed(Patrick)
+Remove un-needed signal stuff from contrib/pginterface
+Fix OR (where x != 1 or x isnull didn't return rows with x NULL) (Vadim)
+Fix time_cmp function (Vadim)
+Fix handling of functions with non-attribute first argument in
+       WHERE clauses (Vadim)
+Fix GROUP BY when order of entries is different from order
+       in target list (Vadim)
+Fix pg_dump for aggregates without sfunc1 (Vadim)
+
+Enhancements
+------------
+Default genetic optimizer GEQO parameter is now 8(Bruce)
+Allow use parameters in target list having aggregates in functions(Vadim)
+Added JDBC driver as an interface(Adrian & Peter)
+pg_password utility
+Return number of rows inserted/affected by INSERT/UPDATE/DELETE etc.(Vadim)
+Triggers implemented with CREATE TRIGGER (SQL3)(Vadim)
+SPI (Server Programming Interface) allows execution of queries inside
+       C-functions (Vadim)
+NOT NULL implemented (SQL92)(Robson Paniago de Miranda)
+Include reserved words for string handling, outer joins, and unions(Thomas)
+Implement extended comments ("/* ... */") using exclusive states(Thomas)
+Add "//" single-line comments(Bruce)
+Remove some restrictions on characters in operator names(Thomas)
+DEFAULT and CONSTRAINT for tables implemented (SQL92)(Vadim & Thomas)
+Add text concatenation operator and function (SQL92)(Thomas)
+Support WITH TIME ZONE syntax (SQL92)(Thomas)
+Support INTERVAL unit TO unit syntax (SQL92)(Thomas)
+Define types DOUBLE PRECISION, INTERVAL, CHARACTER,
+       and CHARACTER VARYING (SQL92)(Thomas)
+Define type FLOAT(p) and rudimentary DECIMAL(p,s), NUMERIC(p,s) (SQL92)(Thomas)
+Define EXTRACT(), POSITION(), SUBSTRING(), and TRIM() (SQL92)(Thomas)
+Define CURRENT_DATE, CURRENT_TIME, CURRENT_TIMESTAMP (SQL92)(Thomas)
+Add syntax and warnings for UNION, HAVING, INNER and OUTER JOIN (SQL92)(Thomas)
+Add more reserved words, mostly for SQL92 compliance(Thomas)
+Allow hh:mm:ss time entry for timespan/reltime types(Thomas)
+Add center() routines for lseg, path, polygon(Thomas)
+Add distance() routines for circle-polygon, polygon-polygon(Thomas)
+Check explicitly for points and polygons contained within polygons
+       using an axis-crossing algorithm(Thomas)
+Add routine to convert circle-box(Thomas)
+Merge conflicting operators for different geometric data types(Thomas)
+Replace distance operator "<===>" with "<->"(Thomas)
+Replace "above" operator "!^" with ">^" and "below" operator "!|" with "<^"(Thomas)
+Add routines for text trimming on both ends, substring, and string position(Thomas)
+Added conversion routines circle(box) and poly(circle)(Thomas)
+Allow internal sorts to be stored in memory rather than in files(Bruce & Vadim)
+Allow functions and operators on internally-identical types to succeed(Bruce)
+Speed up backend start-up after profiling analysis(Bruce)
+Inline frequently called functions for performance(Bruce)
+Reduce open() calls(Bruce)
+psql:  Add PAGER for \h and \?,\C fix
+Fix for psql pager when no tty(Bruce)
+New entab utility(Bruce)
+General trigger functions for referential integrity (Vadim)
+General trigger functions for time travel (Vadim)
+General trigger functions for AUTOINCREMENT/IDENTITY feature (Vadim)
+MOVE implementation (Vadim)
+
+Source Tree Changes
+-------------------
+HP-UX 10 patches (Vladimir Turin)
+Added SCO support, (Daniel Harris)
+MkLinux patches (Tatsuo Ishii)
+Change geometric box terminology from "length" to "width"(Thomas)
+Deprecate temporary unstored slope fields in geometric code(Thomas)
+Remove restart instructions from INSTALL(Bruce)
+Look in /usr/ucb first for install(Bruce)
+Fix c++ copy example code(Thomas)
+Add -o to psql manual page(Bruce)
+Prevent relname unallocated string length from being copied into database(Bruce)
+Cleanup for NAMEDATALEN use(Bruce)
+Fix pg_proc names over 15 chars in output(Bruce)
+Add strNcpy() function(Bruce)
+remove some (void) casts that are unnecessary(Bruce)
+new interfaces directory(Marc)
+Replace fopen() calls with calls to fd.c functions(Bruce)
+Make functions static where possible(Bruce)
+enclose unused functions in #ifdef NOT_USED(Bruce)
+Remove call to difftime() in timestamp support to fix SunOS(Bruce & Thomas)
+Changes for Digital Unix
+Portability fix for pg_dumpall(Bruce)
+Rename pg_attribute.attnvals to attdispersion(Bruce)
+"intro/unix" manual page now "pgintro"(Bruce)
+"built-in" manual page now "pgbuiltin"(Bruce)
+"drop" manual page now "drop_table"(Bruce)
+Add "create_trigger", "drop_trigger" manual pages(Thomas)
+Add constraints regression test(Vadim & Thomas)
+Add comments syntax regression test(Thomas)
+Add PGINDENT and support program(Bruce)
+Massive commit to run PGINDENT on all *.c and *.h files(Bruce)
+Files moved to /src/tools directory(Bruce)
+SPI and Trigger programming guides (Vadim & D'Arcy)


PrevHomeNext
Release 6.2.1UpRelease 6.1.1
\ No newline at end of file diff --git a/doc/src/sgml/html/release-6-3-1.html b/doc/src/sgml/html/release-6-3-1.html new file mode 100644 index 000000000..a6f9af1ff --- /dev/null +++ b/doc/src/sgml/html/release-6-3-1.html @@ -0,0 +1,258 @@ + +Release 6.3.1

E.216. Release 6.3.1

Release Date: 1998-03-23

Summary: + +

  • Additional support for multibyte character sets.

  • Repair byte ordering for mixed-endian clients and servers.

  • Minor updates to allowed SQL syntax.

  • Improvements to the configuration autodetection for installation.

A dump/restore is NOT required for those running 6.3. A +make distclean, make, and make install is all that is required. +This last step should be performed while the postmaster is not running. +You should re-link any custom applications that use PostgreSQL libraries.

For upgrades from pre-6.3 installations, +refer to the installation and migration instructions for version 6.3.

E.216.1. Changes

ecpg cleanup/fixes, now version 1.1(Michael Meskes)
+pg_user cleanup(Bruce)
+large object fix for pg_dump and tclsh (alvin)
+LIKE fix for multiple adjacent underscores
+fix for redefining builtin functions(Thomas)
+ultrix4 cleanup
+upgrade to pg_access 0.83
+updated CLUSTER manual page
+multibyte character set support, see doc/README.mb(Tatsuo)
+configure --with-pgport fix
+pg_ident fix
+big-endian fix for backend communications(Kataoka)
+SUBSTR() and substring() fix(Jan)
+several jdbc fixes(Peter)
+libpgtcl improvements, see libptcl/README(Randy Kunkee)
+Fix for "Datasize = 0" error(Vadim)
+Prevent \do from wrapping(Bruce)
+Remove duplicate Russian character set entries
+Sunos4 cleanup
+Allow optional TABLE key word in LOCK and SELECT INTO(Thomas)
+CREATE SEQUENCE options to allow a negative integer(Thomas)
+Add "PASSWORD" as an allowed column identifier(Thomas)
+Add checks for UNION target fields(Bruce)
+Fix Alpha port(Dwayne Bailey)
+Fix for text arrays containing quotes(Doug Gibson)
+Solaris compile fix(Albert Chin-A-Young)
+Better identify tcl and tk libs and includes(Bruce)

+


PrevHomeNext
Release 6.3.2UpRelease 6.3
\ No newline at end of file diff --git a/doc/src/sgml/html/release-6-3-2.html b/doc/src/sgml/html/release-6-3-2.html new file mode 100644 index 000000000..52fb30446 --- /dev/null +++ b/doc/src/sgml/html/release-6-3-2.html @@ -0,0 +1,245 @@ + +Release 6.3.2

E.215. Release 6.3.2

Release Date: 1998-04-07

This is a bug-fix release for 6.3.x. +Refer to the release notes for version 6.3 for a more complete summary of new features.

Summary: + +

  • Repairs automatic configuration support for some platforms, including Linux, +from breakage inadvertently introduced in version 6.3.1.

  • Correctly handles function calls on the left side of BETWEEN and LIKE clauses.

A dump/restore is NOT required for those running 6.3 or 6.3.1. A +make distclean, make, and make install is all that is required. +This last step should be performed while the postmaster is not running. +You should re-link any custom applications that use PostgreSQL libraries.

For upgrades from pre-6.3 installations, +refer to the installation and migration instructions for version 6.3.

E.215.1. Changes

Configure detection improvements for tcl/tk(Brook Milligan, Alvin)
+Manual page improvements(Bruce)
+BETWEEN and LIKE fix(Thomas)
+fix for psql \connect used by pg_dump(Oliver Elphick)
+New odbc driver
+pgaccess, version 0.86
+qsort removed, now uses libc version, cleanups(Jeroen)
+fix for buffer over-runs detected(Maurice Gittens)
+fix for buffer overrun in libpgtcl(Randy Kunkee)
+fix for UNION with DISTINCT or ORDER BY(Bruce)
+gettimeofday configure check(Doug Winterburn)
+Fix "indexes not used" bug(Vadim)
+docs additions(Thomas)
+Fix for backend memory leak(Bruce)
+libreadline cleanup(Erwan MAS)
+Remove DISTDIR(Bruce)
+Makefile dependency cleanup(Jeroen van Vianen)
+ASSERT fixes(Bruce)

+


PrevHomeNext
Release 6.4UpRelease 6.3.1
\ No newline at end of file diff --git a/doc/src/sgml/html/release-6-3.html b/doc/src/sgml/html/release-6-3.html new file mode 100644 index 000000000..b0f1cd793 --- /dev/null +++ b/doc/src/sgml/html/release-6-3.html @@ -0,0 +1,567 @@ + +Release 6.3

E.217. Release 6.3

Release Date: 1998-03-01

There are many new features and improvements in this release. + Here is a brief, incomplete summary: + +

  • Many new SQL features, including + full SQL92 subselect capability + (everything is here but target-list subselects). +

  • Support for client-side environment variables to specify time zone and date style. +

  • Socket interface for client/server connection. This is the default now + so you might need to start postmaster with the + -i flag. +

  • Better password authorization mechanisms. Default table privileges have changed. +

  • Old-style time travel + has been removed. Performance has been improved. +

+

Note: Bruce Momjian wrote the following notes to introduce the new release. +

There are some general 6.3 issues that I want to mention. These are + only the big items that cannot be described in one sentence. A review + of the detailed changes list is still needed. +

First, we now have subselects. Now that we have them, I would like to + mention that without subselects, SQL is a very limited language. + Subselects are a major feature, and you should review your code for + places where subselects provide a better solution for your queries. I + think you will find that there are more uses for subselects than you might + think. Vadim has put us on the big SQL map with subselects, and fully + functional ones too. The only thing you cannot do with subselects is to + use them in the target list. +

Second, 6.3 uses Unix domain sockets rather than TCP/IP by default. To + enable connections from other machines, you have to use the new + postmaster -i option, and of course edit pg_hba.conf. Also, for this + reason, the format of pg_hba.conf has changed. +

Third, char() fields will now allow faster access than varchar() or + text. Specifically, the text and varchar() have a penalty for access to + any columns after the first column of this type. char() used to also + have this access penalty, but it no longer does. This might suggest that + you redesign some of your tables, especially if you have short character + columns that you have defined as varchar() or text. This and other + changes make 6.3 even faster than earlier releases. +

We now have passwords definable independent of any Unix file. There are + new SQL USER commands. + See the Administrator's Guide for more + information. There is a new table, pg_shadow, which is used to store + user information and user passwords, and it by default only SELECT-able + by the postgres super-user. pg_user is now a view of pg_shadow, and is + SELECT-able by PUBLIC. You should keep using pg_user in your + application without changes. +

User-created tables now no longer have SELECT privilege to PUBLIC by + default. This was done because the ANSI standard requires it. You can + of course GRANT any privileges you want after the table is created. + System tables continue to be SELECT-able by PUBLIC. +

We also have real deadlock detection code. No more sixty-second + timeouts. And the new locking code implements a FIFO better, so there + should be less resource starvation during heavy use. +

Many complaints have been made about inadequate documentation in previous + releases. Thomas has put much effort into many new manuals for this + release. Check out the doc/ directory. +

For performance reasons, time travel is gone, but can be implemented + using triggers (see pgsql/contrib/spi/README). Please check out the new + \d command for types, operators, etc. Also, views have their own + privileges now, not based on the underlying tables, so privileges on + them have to be set separately. Check /pgsql/interfaces for some new + ways to talk to PostgreSQL. +

This is the first release that really required an explanation for + existing users. In many ways, this was necessary because the new + release removes many limitations, and the work-arounds people were using + are no longer needed. +

E.217.1. Migration to Version 6.3

A dump/restore using pg_dump + or pg_dumpall + is required for those wishing to migrate data from any + previous release of PostgreSQL. +

E.217.2. Changes

Bug Fixes
+---------
+Fix binary cursors broken by MOVE implementation(Vadim)
+Fix for tcl library crash(Jan)
+Fix for array handling, from Gerhard Hintermayer
+Fix acl error, and remove duplicate pqtrace(Bruce)
+Fix psql \e for empty file(Bruce)
+Fix for textcat on varchar() fields(Bruce)
+Fix for DBT Sendproc (Zeugswetter Andres)
+Fix vacuum analyze syntax problem(Bruce)
+Fix for international identifiers(Tatsuo)
+Fix aggregates on inherited tables(Bruce)
+Fix substr() for out-of-bounds data
+Fix for select 1=1 or 2=2, select 1=1 and 2=2, and select sum(2+2)(Bruce)
+Fix notty output to show status result.  -q option still turns it off(Bruce)
+Fix for count(*), aggs with views and multiple tables and sum(3)(Bruce)
+Fix cluster(Bruce)
+Fix for PQtrace start/stop several times(Bruce)
+Fix a variety of locking problems like newer lock waiters getting
+       lock before older waiters, and having readlock people not share
+       locks if a writer is waiting for a lock, and waiting writers not
+       getting priority over waiting readers(Bruce)
+Fix crashes in psql when executing queries from external files(James)
+Fix problem with multiple order by columns, with the first one having
+       NULL values(Jeroen)
+Use correct hash table support functions for float8 and int4(Thomas)
+Re-enable JOIN= option in CREATE OPERATOR statement (Thomas)
+Change precedence for boolean operators to match expected behavior(Thomas)
+Generate elog(ERROR) on over-large integer(Bruce)
+Allow multiple-argument functions in constraint clauses(Thomas)
+Check boolean input literals for 'true','false','yes','no','1','0'
+       and throw elog(ERROR) if unrecognized(Thomas)
+Major large objects fix
+Fix for GROUP BY showing duplicates(Vadim)
+Fix for index scans in MergeJoin(Vadim)
+
+Enhancements
+------------
+Subselects with EXISTS, IN, ALL, ANY key words (Vadim, Bruce, Thomas)
+New User Manual(Thomas, others)
+Speedup by inlining some frequently-called functions
+Real deadlock detection, no more timeouts(Bruce)
+Add SQL92 "constants" CURRENT_DATE, CURRENT_TIME, CURRENT_TIMESTAMP,
+       CURRENT_USER(Thomas)
+Modify constraint syntax to be SQL92-compliant(Thomas)
+Implement SQL92 PRIMARY KEY and UNIQUE clauses using indexes(Thomas)
+Recognize SQL92 syntax for FOREIGN KEY. Throw elog notice(Thomas)
+Allow NOT NULL UNIQUE constraint clause (each allowed separately before)(Thomas)
+Allow PostgreSQL-style casting ("::") of non-constants(Thomas)
+Add support for SQL3 TRUE and FALSE boolean constants(Thomas)
+Support SQL92 syntax for IS TRUE/IS FALSE/IS NOT TRUE/IS NOT FALSE(Thomas)
+Allow shorter strings for boolean literals (e.g. "t", "tr", "tru")(Thomas)
+Allow SQL92 delimited identifiers(Thomas)
+Implement SQL92 binary and hexadecimal string decoding (b'10' and x'1F')(Thomas)
+Support SQL92 syntax for type coercion of literal strings
+       (e.g. "DATETIME 'now'")(Thomas)
+Add conversions for int2, int4, and OID types to and from text(Thomas)
+Use shared lock when building indexes(Vadim)
+Free memory allocated for an user query inside transaction block after
+       this query is done, was turned off in <= 6.2.1(Vadim)
+New SQL statement CREATE PROCEDURAL LANGUAGE(Jan)
+New PostgreSQL Procedural Language (PL) backend interface(Jan)
+Rename pg_dump -H option to -h(Bruce)
+Add Java support for passwords, European dates(Peter)
+Use indexes for LIKE and ~, !~ operations(Bruce)
+Add hash functions for datetime and timespan(Thomas)
+Time Travel removed(Vadim, Bruce)
+Add paging for \d and \z, and fix \i(Bruce)
+Add Unix domain socket support to backend and to frontend library(Goran)
+Implement CREATE DATABASE/WITH LOCATION and initlocation utility(Thomas)
+Allow more SQL92 and/or PostgreSQL reserved words as column identifiers(Thomas)
+Augment support for SQL92 SET TIME ZONE...(Thomas)
+SET/SHOW/RESET TIME ZONE uses TZ backend environment variable(Thomas)
+Implement SET keyword = DEFAULT and SET TIME ZONE DEFAULT(Thomas)
+Enable SET TIME ZONE using TZ environment variable(Thomas)
+Add PGDATESTYLE environment variable to frontend and backend initialization(Thomas)
+Add PGTZ, PGCOSTHEAP, PGCOSTINDEX, PGRPLANS, PGGEQO
+       frontend library initialization environment variables(Thomas)
+Regression tests time zone automatically set with "setenv PGTZ PST8PDT"(Thomas)
+Add pg_description table for info on tables, columns, operators, types, and
+       aggregates(Bruce)
+Increase 16 char limit on system table/index names to 32 characters(Bruce)
+Rename system indexes(Bruce)
+Add 'GERMAN' option to SET DATESTYLE(Thomas)
+Define an "ISO-style" timespan output format with "hh:mm:ss" fields(Thomas)
+Allow fractional values for delta times (e.g. '2.5 days')(Thomas)
+Validate numeric input more carefully for delta times(Thomas)
+Implement day of year as possible input to date_part()(Thomas)
+Define timespan_finite() and text_timespan() functions(Thomas)
+Remove archive stuff(Bruce)
+Allow for a pg_password authentication database that is separate from
+       the system password file(Todd)
+Dump ACLs, GRANT, REVOKE privileges(Matt)
+Define text, varchar, and bpchar string length functions(Thomas)
+Fix Query handling for inheritance, and cost computations(Bruce)
+Implement CREATE TABLE/AS SELECT (alternative to SELECT/INTO)(Thomas)
+Allow NOT, IS NULL, IS NOT NULL in constraints(Thomas)
+Implement UNIONs for SELECT(Bruce)
+Add UNION, GROUP, DISTINCT to INSERT(Bruce)
+varchar() stores only necessary bytes on disk(Bruce)
+Fix for BLOBs(Peter)
+Mega-Patch for JDBC...see README_6.3 for list of changes(Peter)
+Remove unused "option" from PQconnectdb()
+New LOCK command and lock manual page describing deadlocks(Bruce)
+Add new psql \da, \dd, \df, \do, \dS, and \dT commands(Bruce)
+Enhance psql \z to show sequences(Bruce)
+Show NOT NULL and DEFAULT in psql \d table(Bruce)
+New psql .psqlrc file start-up(Andrew)
+Modify sample start-up script in contrib/linux to show syslog(Thomas)
+New types for IP and MAC addresses in contrib/ip_and_mac(TomH)
+Unix system time conversions with date/time types in contrib/unixdate(Thomas)
+Update of contrib stuff(Massimo)
+Add Unix socket support to DBD::Pg(Goran)
+New python interface (PyGreSQL 2.0)(D'Arcy)
+New frontend/backend protocol has a version number, network byte order(Phil)
+Security features in pg_hba.conf enhanced and documented, many cleanups(Phil)
+CHAR() now faster access than VARCHAR() or TEXT
+ecpg embedded SQL preprocessor
+Reduce system column overhead(Vadmin)
+Remove pg_time table(Vadim)
+Add pg_type attribute to identify types that need length (bpchar, varchar)
+Add report of offending line when COPY command fails
+Allow VIEW privileges to be set separately from the underlying tables.
+       For security, use GRANT/REVOKE on views as appropriate(Jan)
+Tables now have no default GRANT SELECT TO PUBLIC.  You must
+       explicitly grant such privileges.
+Clean up tutorial examples(Darren)
+
+Source Tree Changes
+-------------------
+Add new html development tools, and flow chart in /tools/backend
+Fix for SCO compiles
+Stratus computer port Robert Gillies
+Added support for shlib for BSD44_derived & i386_solaris
+Make configure more automated(Brook)
+Add script to check regression test results
+Break parser functions into smaller files, group together(Bruce)
+Rename heap_create to heap_create_and_catalog, rename heap_creatr
+       to heap_create()(Bruce)
+Sparc/Linux patch for locking(TomS)
+Remove PORTNAME and reorganize port-specific stuff(Marc)
+Add optimizer README file(Bruce)
+Remove some recursion in optimizer and clean up some code there(Bruce)
+Fix for NetBSD locking(Henry)
+Fix for libptcl make(Tatsuo)
+AIX patch(Darren)
+Change IS TRUE, IS FALSE, ... to expressions using "=" rather than
+       function calls to istrue() or isfalse() to allow optimization(Thomas)
+Various fixes NetBSD/Sparc related(TomH)
+Alpha linux locking(Travis,Ryan)
+Change elog(WARN) to elog(ERROR)(Bruce)
+FAQ for FreeBSD(Marc)
+Bring in the PostODBC source tree as part of our standard distribution(Marc)
+A minor patch for HP/UX 10 vs 9(Stan)
+New pg_attribute.atttypmod for type-specific info like varchar length(Bruce)
+UnixWare patches(Billy)
+New i386 'lock' for spinlock asm(Billy)
+Support for multiplexed backends is removed
+Start an OpenBSD port
+Start an AUX port
+Start a Cygnus port
+Add string functions to regression suite(Thomas)
+Expand a few function names formerly truncated to 16 characters(Thomas)
+Remove un-needed malloc() calls and replace with palloc()(Bruce)


PrevHomeNext
Release 6.3.1UpRelease 6.2.1
\ No newline at end of file diff --git a/doc/src/sgml/html/release-6-4-1.html b/doc/src/sgml/html/release-6-4-1.html new file mode 100644 index 000000000..4d012a8e8 --- /dev/null +++ b/doc/src/sgml/html/release-6-4-1.html @@ -0,0 +1,237 @@ + +Release 6.4.1

E.213. Release 6.4.1

Release Date: 1998-12-18

This is basically a cleanup release for 6.4. We have fixed a variety of +problems reported by 6.4 users.

E.213.1. Migration to Version 6.4.1

A dump/restore is not required for those running +6.4.

E.213.2. Changes

Add pg_dump -N flag to force double quotes around identifiers.  This is
+       the default(Thomas)
+Fix for NOT in where clause causing crash(Bruce)
+EXPLAIN VERBOSE coredump fix(Vadim)
+Fix shared-library problems on Linux
+Fix test for table existence to allow mixed-case and whitespace in
+       the table name(Thomas)
+Fix a couple of pg_dump bugs
+Configure matches template/.similar entries better(Tom)
+Change builtin function names from SPI_* to spi_*
+OR WHERE clause fix(Vadim)
+Fixes for mixed-case table names(Billy)
+contrib/linux/postgres.init.csh/sh fix(Thomas)
+libpq memory overrun fix
+SunOS fixes(Tom)
+Change exp() behavior to generate error on underflow(Thomas)
+pg_dump fixes for memory leak, inheritance constraints, layout change
+update pgaccess to 0.93
+Fix prototype for 64-bit platforms
+Multibyte fixes(Tatsuo)
+New ecpg man page
+Fix memory overruns(Tatsuo)
+Fix for lo_import() crash(Bruce)
+Better search for install program(Tom)
+Timezone fixes(Tom)
+HP-UX fixes(Tom)
+Use implicit type coercion for matching DEFAULT values(Thomas)
+Add routines to help with single-byte (internal) character type(Thomas)
+Compilation of libpq for Windows fixes(Magnus)
+Upgrade to PyGreSQL 2.2(D'Arcy)


PrevHomeNext
Release 6.4.2UpRelease 6.4
\ No newline at end of file diff --git a/doc/src/sgml/html/release-6-4-2.html b/doc/src/sgml/html/release-6-4-2.html new file mode 100644 index 000000000..3375b643d --- /dev/null +++ b/doc/src/sgml/html/release-6-4-2.html @@ -0,0 +1,208 @@ + +Release 6.4.2

E.212. Release 6.4.2

Release Date: 1998-12-20

The 6.4.1 release was improperly packaged. This also has one additional +bug fix.

E.212.1. Migration to Version 6.4.2

A dump/restore is not required for those running +6.4.*.

E.212.2. Changes

Fix for datetime constant problem on some platforms(Thomas)


PrevHomeNext
Release 6.5UpRelease 6.4.1
\ No newline at end of file diff --git a/doc/src/sgml/html/release-6-4.html b/doc/src/sgml/html/release-6-4.html new file mode 100644 index 000000000..65398b3fb --- /dev/null +++ b/doc/src/sgml/html/release-6-4.html @@ -0,0 +1,505 @@ + +Release 6.4

E.214. Release 6.4

Release Date: 1998-10-30

There are many new features and improvements in this release. +Thanks to our developers and maintainers, nearly every aspect of the system +has received some attention since the previous release. +Here is a brief, incomplete summary: + +

  • Views and rules are now functional thanks to extensive new code in the +rewrite rules system from Jan Wieck. He also wrote a chapter on it +for the Programmer's Guide.

  • Jan also contributed a second procedural language, PL/pgSQL, to go with the +original PL/pgTCL procedural language he contributed last release.

  • We have optional multiple-byte character set support from Tatsuo Ishii +to complement our existing locale support.

  • Client/server communications has been cleaned up, with better support for +asynchronous messages and interrupts thanks to Tom Lane.

  • The parser will now perform automatic type coercion to match arguments +to available operators and functions, and to match columns and expressions +with target columns. This uses a generic mechanism which supports +the type extensibility features of PostgreSQL. +There is a new chapter in the User's Guide +which covers this topic.

  • Three new data types have been added. +Two types, inet and cidr, support various forms +of IP network, subnet, and machine addressing. There is now an 8-byte integer +type available on some platforms. See the chapter on data types +in the User's Guide for details. +A fourth type, serial, is now supported by the parser as an +amalgam of the int4 type, a sequence, and a unique index.

  • Several more SQL92-compatible syntax features have been +added, including INSERT DEFAULT VALUES

  • The automatic configuration and installation system has received some +attention, and should be more robust for more platforms than it has ever +been.

E.214.1. Migration to Version 6.4

A dump/restore using pg_dump +or pg_dumpall +is required for those wishing to migrate data from any +previous release of PostgreSQL.

E.214.2. Changes

Bug Fixes
+---------
+Fix for a tiny memory leak in PQsetdb/PQfinish(Bryan)
+Remove char2-16 data types, use char/varchar(Darren)
+Pqfn not handles a NOTICE message(Anders)
+Reduced busywaiting overhead for spinlocks with many backends (dg)
+Stuck spinlock detection (dg)
+Fix up "ISO-style" timespan decoding and encoding(Thomas)
+Fix problem with table drop after rollback of transaction(Vadim)
+Change error message and remove non-functional update message(Vadim)
+Fix for COPY array checking
+Fix for SELECT 1 UNION SELECT NULL
+Fix for buffer leaks in large object calls(Pascal)
+Change owner from oid to int4 type(Bruce)
+Fix a bug in the oracle compatibility functions btrim() ltrim() and rtrim()
+Fix for shared invalidation cache overflow(Massimo)
+Prevent file descriptor leaks in failed COPY's(Bruce)
+Fix memory leak in libpgtcl's pg_select(Constantin)
+Fix problems with username/passwords over 8 characters(Tom)
+Fix problems with handling of asynchronous NOTIFY in backend(Tom)
+Fix of many bad system table entries(Tom)
+
+Enhancements
+------------
+Upgrade ecpg and ecpglib,see src/interfaces/ecpc/ChangeLog(Michael)
+Show the index used in an EXPLAIN(Zeugswetter)
+EXPLAIN  invokes  rule system and shows plan(s) for rewritten queries(Jan)
+Multibyte awareness of many data types and functions, via configure(Tatsuo)
+New configure --with-mb option(Tatsuo)
+New initdb --pgencoding option(Tatsuo)
+New createdb -E multibyte option(Tatsuo)
+Select version(); now returns PostgreSQL version(Jeroen)
+libpq now allows asynchronous clients(Tom)
+Allow cancel from client of backend query(Tom)
+psql now cancels query with Control-C(Tom)
+libpq users need not issue dummy queries to get NOTIFY messages(Tom)
+NOTIFY now sends sender's PID, so you can tell whether it was your own(Tom)
+PGresult struct now includes associated error message, if any(Tom)
+Define "tz_hour" and "tz_minute" arguments to date_part()(Thomas)
+Add routines to convert between varchar and bpchar(Thomas)
+Add routines to allow sizing of varchar and bpchar into target columns(Thomas)
+Add bit flags to support timezonehour and minute in data retrieval(Thomas)
+Allow more variations on valid floating point numbers (e.g. ".1", "1e6")(Thomas)
+Fixes for unary minus parsing with leading spaces(Thomas)
+Implement TIMEZONE_HOUR, TIMEZONE_MINUTE per SQL92 specs(Thomas)
+Check for and properly ignore FOREIGN KEY column constraints(Thomas)
+Define USER as synonym for CURRENT_USER per SQL92 specs(Thomas)
+Enable HAVING clause but no fixes elsewhere yet.
+Make "char" type a synonym for "char(1)" (actually implemented as bpchar)(Thomas)
+Save string type if specified for DEFAULT clause handling(Thomas)
+Coerce operations involving different data types(Thomas)
+Allow some index use for columns of different types(Thomas)
+Add capabilities for automatic type conversion(Thomas)
+Cleanups for large objects, so file is truncated on open(Peter)
+Readline cleanups(Tom)
+Allow psql  \f \ to make spaces as delimiter(Bruce)
+Pass pg_attribute.atttypmod to the frontend for column field lengths(Tom,Bruce)
+Msql compatibility library in /contrib(Aldrin)
+Remove the requirement that ORDER/GROUP BY clause identifiers be
+included in the target list(David)
+Convert columns to match columns in UNION clauses(Thomas)
+Remove fork()/exec() and only do fork()(Bruce)
+Jdbc cleanups(Peter)
+Show backend status on ps command line(only works on some platforms)(Bruce)
+Pg_hba.conf now has a sameuser option in the database field
+Make lo_unlink take oid param, not int4
+New DISABLE_COMPLEX_MACRO for compilers that cannot handle our macros(Bruce)
+Libpgtcl now handles NOTIFY as a Tcl event, need not send dummy queries(Tom)
+libpgtcl cleanups(Tom)
+Add -error option to libpgtcl's pg_result command(Tom)
+New locale patch, see docs/README/locale(Oleg)
+Fix for pg_dump so CONSTRAINT and CHECK syntax is correct(ccb)
+New contrib/lo code for large object orphan removal(Peter)
+New psql command "SET CLIENT_ENCODING TO 'encoding'" for multibytes
+feature, see /doc/README.mb(Tatsuo)
+contrib/noupdate code to revoke update permission on a column
+libpq can now be compiled on Windows(Magnus)
+Add PQsetdbLogin() in libpq
+New 8-byte integer type, checked by configure for OS support(Thomas)
+Better support for quoted table/column names(Thomas)
+Surround table and column names with double-quotes in pg_dump(Thomas)
+PQreset() now works with passwords(Tom)
+Handle case of GROUP BY target list column number out of range(David)
+Allow UNION in subselects
+Add auto-size to screen to \d? commands(Bruce)
+Use UNION to show all \d? results in one query(Bruce)
+Add \d? field search feature(Bruce)
+Pg_dump issues fewer \connect requests(Tom)
+Make pg_dump -z flag work better, document it in manual page(Tom)
+Add HAVING clause with full support for subselects and unions(Stephan)
+Full text indexing routines in contrib/fulltextindex(Maarten)
+Transaction ids now stored in shared memory(Vadim)
+New PGCLIENTENCODING when issuing COPY command(Tatsuo)
+Support for SQL92 syntax "SET NAMES"(Tatsuo)
+Support for LATIN2-5(Tatsuo)
+Add UNICODE regression test case(Tatsuo)
+Lock manager cleanup, new locking modes for LLL(Vadim)
+Allow index use with OR clauses(Bruce)
+Allows "SELECT NULL ORDER BY 1;"
+Explain VERBOSE prints the plan, and now pretty-prints the plan to
+the postmaster log file(Bruce)
+Add indexes display to \d command(Bruce)
+Allow GROUP BY on functions(David)
+New pg_class.relkind for large objects(Bruce)
+New way to send libpq NOTICE messages to a different location(Tom)
+New \w write command to psql(Bruce)
+New /contrib/findoidjoins scans oid columns to find join relationships(Bruce)
+Allow binary-compatible indexes to be considered when checking for valid
+Indexes for restriction clauses containing a constant(Thomas)
+New ISBN/ISSN code in /contrib/isbn_issn
+Allow NOT LIKE, IN, NOT IN, BETWEEN, and NOT BETWEEN constraint(Thomas)
+New rewrite system fixes many problems with rules and views(Jan)
+       * Rules on relations work
+       * Event qualifications on insert/update/delete work
+       * New OLD variable to reference CURRENT, CURRENT will be remove in future
+       * Update rules can reference NEW and OLD in rule qualifications/actions
+       * Insert/update/delete rules on views work
+       * Multiple rule actions are now supported, surrounded by parentheses
+       * Regular users can create views/rules on tables they have RULE permits
+       * Rules and views inherit the privileges of the creator
+       * No rules at the column level
+       * No UPDATE NEW/OLD rules
+       * New pg_tables, pg_indexes, pg_rules and pg_views system views
+       * Only a single action on SELECT rules
+       * Total rewrite overhaul, perhaps for 6.5
+       * handle subselects
+       * handle aggregates on views
+       * handle insert into select from view works
+System indexes are now multikey(Bruce)
+Oidint2, oidint4, and oidname types are removed(Bruce)
+Use system cache for more system table lookups(Bruce)
+New backend programming language PL/pgSQL in backend/pl(Jan)
+New SERIAL data type, auto-creates sequence/index(Thomas)
+Enable assert checking without a recompile(Massimo)
+User lock enhancements(Massimo)
+New setval() command to set sequence value(Massimo)
+Auto-remove unix socket file on start-up if no postmaster running(Massimo)
+Conditional trace package(Massimo)
+New UNLISTEN command(Massimo)
+psql and libpq now compile under Windows using win32.mak(Magnus)
+Lo_read no longer stores trailing NULL(Bruce)
+Identifiers are now truncated to 31 characters internally(Bruce)
+Createuser options now available on the command line
+Code for 64-bit integer supported added, configure tested, int8 type(Thomas)
+Prevent file descriptor leaf from failed COPY(Bruce)
+New pg_upgrade command(Bruce)
+Updated /contrib directories(Massimo)
+New CREATE TABLE DEFAULT VALUES statement available(Thomas)
+New INSERT INTO TABLE DEFAULT VALUES statement available(Thomas)
+New DECLARE and FETCH feature(Thomas)
+libpq's internal structures now not exported(Tom)
+Allow up to 8 key indexes(Bruce)
+Remove ARCHIVE key word, that is no longer used(Thomas)
+pg_dump -n flag to suppress quotes around indentifiers
+disable system columns for views(Jan)
+new INET and CIDR types for network addresses(TomH, Paul)
+no more double quotes in psql output
+pg_dump now dumps views(Terry)
+new SET QUERY_LIMIT(Tatsuo,Jan)
+
+Source Tree Changes
+-------------------
+/contrib cleanup(Jun)
+Inline some small functions called for every row(Bruce)
+Alpha/linux fixes
+HP-UX cleanups(Tom)
+Multibyte regression tests(Soonmyung.)
+Remove --disabled options from configure
+Define PGDOC to use POSTGRESDIR by default
+Make regression optional
+Remove extra braces code to pgindent(Bruce)
+Add bsdi shared library support(Bruce)
+New --without-CXX support configure option(Brook)
+New FAQ_CVS
+Update backend flowchart in tools/backend(Bruce)
+Change atttypmod from int16 to int32(Bruce, Tom)
+Getrusage() fix for platforms that do not have it(Tom)
+Add PQconnectdb, PGUSER, PGPASSWORD to libpq man page
+NS32K platform fixes(Phil Nelson, John Buller)
+SCO 7/UnixWare 2.x fixes(Billy,others)
+Sparc/Solaris 2.5 fixes(Ryan)
+Pgbuiltin.3 is obsolete, move to doc files(Thomas)
+Even more documentation(Thomas)
+Nextstep support(Jacek)
+Aix support(David)
+pginterface manual page(Bruce)
+shared libraries all have version numbers
+merged all OS-specific shared library defines into one file
+smarter TCL/TK configuration checking(Billy)
+smarter perl configuration(Brook)
+configure uses supplied install-sh if no install script found(Tom)
+new Makefile.shlib for shared library configuration(Tom)


PrevHomeNext
Release 6.4.1UpRelease 6.3.2
\ No newline at end of file diff --git a/doc/src/sgml/html/release-6-5-1.html b/doc/src/sgml/html/release-6-5-1.html new file mode 100644 index 000000000..fd17e12b1 --- /dev/null +++ b/doc/src/sgml/html/release-6-5-1.html @@ -0,0 +1,233 @@ + +Release 6.5.1

E.210. Release 6.5.1

Release Date: 1999-07-15

This is basically a cleanup release for 6.5. We have fixed a variety of + problems reported by 6.5 users. +

E.210.1. Migration to Version 6.5.1

A dump/restore is not required for those running + 6.5. +

E.210.2. Changes

Add NT README file
+Portability fixes for linux_ppc, IRIX, linux_alpha, OpenBSD, alpha
+Remove QUERY_LIMIT, use SELECT...LIMIT
+Fix for EXPLAIN on inheritance(Tom)
+Patch to allow vacuum on multisegment tables(Hiroshi)
+R-Tree optimizer selectivity fix(Tom)
+ACL file descriptor leak fix(Atsushi Ogawa)
+New expression subtree code(Tom)
+Avoid disk writes for read-only transactions(Vadim)
+Fix for removal of temp tables if last transaction was aborted(Bruce)
+Fix to prevent too large row from being created(Bruce)
+plpgsql fixes
+Allow port numbers 32k - 64k(Bruce)
+Add ^ precedence(Bruce)
+Rename sort files called pg_temp to pg_sorttemp(Bruce)
+Fix for microseconds in time values(Tom)
+Tutorial source cleanup
+New linux_m68k port
+Fix for sorting of NULL's in some cases(Tom)
+Shared library dependencies fixed (Tom)
+Fixed glitches affecting GROUP BY in subselects(Tom)
+Fix some compiler warnings (Tomoaki Nishiyama)
+Add Win1250 (Czech) support (Pavel Behal)

+


PrevHomeNext
Release 6.5.2UpRelease 6.5
\ No newline at end of file diff --git a/doc/src/sgml/html/release-6-5-2.html b/doc/src/sgml/html/release-6-5-2.html new file mode 100644 index 000000000..eb896982f --- /dev/null +++ b/doc/src/sgml/html/release-6-5-2.html @@ -0,0 +1,234 @@ + +Release 6.5.2

E.209. Release 6.5.2

Release Date: 1999-09-15

This is basically a cleanup release for 6.5.1. We have fixed a variety of + problems reported by 6.5.1 users. +

E.209.1. Migration to Version 6.5.2

A dump/restore is not required for those running + 6.5.*. +

E.209.2. Changes

subselect+CASE fixes(Tom)
+Add SHLIB_LINK setting for solaris_i386 and solaris_sparc ports(Daren Sefcik)
+Fixes for CASE in WHERE join clauses(Tom)
+Fix BTScan abort(Tom)
+Repair the check for redundant UNIQUE and PRIMARY KEY indexes(Thomas)
+Improve it so that it checks for multicolumn constraints(Thomas)
+Fix for Windows making problem with MB enabled(Hiroki Kataoka)
+Allow BSD yacc and bison to compile pl code(Bruce)
+Fix SET NAMES working
+int8 fixes(Thomas)
+Fix vacuum's memory consumption(Hiroshi,Tatsuo)
+Reduce the total memory consumption of vacuum(Tom)
+Fix for timestamp(datetime)
+Rule deparsing bugfixes(Tom)
+Fix quoting problems in mkMakefile.tcldefs.sh.in and mkMakefile.tkdefs.sh.in(Tom)
+This is to re-use space on index pages freed by vacuum(Vadim)
+document -x for pg_dump(Bruce)
+Fix for unary operators in rule deparser(Tom)
+Comment out FileUnlink of excess segments during mdtruncate()(Tom)
+IRIX linking fix from Yu Cao >yucao@falcon.kla-tencor.com<
+Repair logic error in LIKE: should not return LIKE_ABORT
+  when reach end of pattern before end of text(Tom)
+Repair incorrect cleanup of heap memory allocation during transaction abort(Tom)
+Updated version of pgaccess 0.98

+


PrevHomeNext
Release 6.5.3UpRelease 6.5.1
\ No newline at end of file diff --git a/doc/src/sgml/html/release-6-5-3.html b/doc/src/sgml/html/release-6-5-3.html new file mode 100644 index 000000000..56595306b --- /dev/null +++ b/doc/src/sgml/html/release-6-5-3.html @@ -0,0 +1,216 @@ + +Release 6.5.3

E.208. Release 6.5.3

Release Date: 1999-10-13

This is basically a cleanup release for 6.5.2. We have added a new + PgAccess that was missing in 6.5.2, and installed an NT-specific fix. +

E.208.1. Migration to Version 6.5.3

A dump/restore is not required for those running + 6.5.*. +

E.208.2. Changes

Updated version of pgaccess 0.98
+NT-specific patch
+Fix dumping rules on inherited tables

+


PrevHomeNext
Release 7.0UpRelease 6.5.2
\ No newline at end of file diff --git a/doc/src/sgml/html/release-6-5.html b/doc/src/sgml/html/release-6-5.html new file mode 100644 index 000000000..3504a565c --- /dev/null +++ b/doc/src/sgml/html/release-6-5.html @@ -0,0 +1,656 @@ + +Release 6.5

E.211. Release 6.5

Release Date: 1999-06-09

This release marks a major step in the development team's mastery of the source + code we inherited from Berkeley. You will see we are now easily adding + major features, thanks to the increasing size and experience of our + world-wide development team. +

Here is a brief summary of the more notable changes: + +

Multiversion concurrency control(MVCC)

This removes our old table-level locking, and replaces it with + a locking system that is superior to most commercial database + systems. In a traditional system, each row that is modified + is locked until committed, preventing reads by other users. + MVCC uses the natural multiversion nature of + PostgreSQL to allow readers to + continue reading consistent data during writer activity. + Writers continue to use the compact pg_log transaction system. + This is all performed without having to allocate a lock for + every row like traditional database systems. So, basically, + we no longer are restricted by simple table-level locking; we + have something better than row-level locking. +

Hot backups from pg_dump

pg_dump takes advantage of the new + MVCC features to give a consistent database dump/backup while + the database stays online and available for queries. +

Numeric data type

We now have a true numeric data type, with + user-specified precision. +

Temporary tables

Temporary tables are guaranteed to have unique names + within a database session, and are destroyed on session exit. +

New SQL features

We now have CASE, INTERSECT, and EXCEPT statement + support. We have new LIMIT/OFFSET, SET TRANSACTION ISOLATION LEVEL, + SELECT ... FOR UPDATE, and an improved LOCK TABLE command. +

Speedups

We continue to speed up PostgreSQL, + thanks to the variety of talents within our team. We have + sped up memory allocation, optimization, table joins, and row + transfer routines. +

Ports

We continue to expand our port list, this time including + Windows NT/ix86 and NetBSD/arm32. +

Interfaces

Most interfaces have new versions, and existing functionality + has been improved. +

Documentation

New and updated material is present throughout the + documentation. New FAQs have been + contributed for SGI and AIX platforms. + The Tutorial has introductory information + on SQL from Stefan Simkovics. + For the User's Guide, there are + reference pages covering the postmaster and more utility + programs, and a new appendix + contains details on date/time behavior. + The Administrator's Guide has a new + chapter on troubleshooting from Tom Lane. + And the Programmer's Guide has a + description of query processing, also from Stefan, and details + on obtaining the PostgreSQL source + tree via anonymous CVS and + CVSup. +

+

E.211.1. Migration to Version 6.5

A dump/restore using pg_dump + is required for those wishing to migrate data from any + previous release of PostgreSQL. + pg_upgrade can not + be used to upgrade to this release because the on-disk structure + of the tables has changed compared to previous releases. +

The new Multiversion Concurrency Control (MVCC) features can + give somewhat different behaviors in multiuser + environments. Read and understand the following section + to ensure that your existing applications will give you the + behavior you need. +

E.211.1.1. Multiversion Concurrency Control

Because readers in 6.5 don't lock data, regardless of transaction + isolation level, data read by one transaction can be overwritten by + another. In other words, if a row is returned by + SELECT it doesn't mean that this row really exists + at the time it is returned (i.e. sometime after the statement or + transaction began) nor that the row is protected from being deleted or + updated by concurrent transactions before the current transaction does + a commit or rollback. +

To ensure the actual existence of a row and protect it against + concurrent updates one must use SELECT FOR UPDATE or + an appropriate LOCK TABLE statement. This should be + taken into account when porting applications from previous releases of + PostgreSQL and other environments. +

Keep the above in mind if you are using + contrib/refint.* triggers for + referential integrity. Additional techniques are required now. One way is + to use LOCK parent_table IN SHARE ROW EXCLUSIVE MODE + command if a transaction is going to update/delete a primary key and + use LOCK parent_table IN SHARE MODE command if a + transaction is going to update/insert a foreign key. + +

Note: Note that if you run a transaction in SERIALIZABLE mode then you must + execute the LOCK commands above before execution of any + DML statement + (SELECT/INSERT/DELETE/UPDATE/FETCH/COPY_TO) in the + transaction. +

+

These inconveniences will disappear in the future + when the ability to read dirty + (uncommitted) data (regardless of isolation level) and true referential + integrity will be implemented. +

E.211.2. Changes

Bug Fixes
+---------
+Fix text<->float8 and text<->float4 conversion functions(Thomas)
+Fix for creating tables with mixed-case constraints(Billy)
+Change exp()/pow() behavior to generate error on underflow/overflow(Jan)
+Fix bug in pg_dump -z
+Memory overrun cleanups(Tatsuo)
+Fix for lo_import crash(Tatsuo)
+Adjust handling of data type names to suppress double quotes(Thomas)
+Use type coercion for matching columns and DEFAULT(Thomas)
+Fix deadlock so it only checks once after one second of sleep(Bruce)
+Fixes for aggregates and PL/pgsql(Hiroshi)
+Fix for subquery crash(Vadim)
+Fix for libpq function PQfnumber and case-insensitive names(Bahman Rafatjoo)
+Fix for large object write-in-middle, no extra block, memory consumption(Tatsuo)
+Fix for pg_dump -d or -D and  quote special characters in INSERT
+Repair serious problems with dynahash(Tom)
+Fix INET/CIDR portability problems
+Fix problem with selectivity error in ALTER TABLE ADD COLUMN(Bruce)
+Fix executor so mergejoin of different column types works(Tom)
+Fix for Alpha OR selectivity bug
+Fix OR index selectivity problem(Bruce)
+Fix so \d shows proper length for char()/varchar()(Ryan)
+Fix tutorial code(Clark)
+Improve destroyuser checking(Oliver)
+Fix for Kerberos(Rodney McDuff)
+Fix for dropping database while dirty buffers(Bruce)
+Fix so sequence nextval() can be case-sensitive(Bruce)
+Fix !!= operator
+Drop buffers before destroying database files(Bruce)
+Fix case where executor evaluates functions twice(Tatsuo)
+Allow sequence nextval actions to be case-sensitive(Bruce)
+Fix optimizer indexing not working for negative numbers(Bruce)
+Fix for memory leak in executor with fjIsNull
+Fix for aggregate memory leaks(Erik Riedel)
+Allow user name containing a dash to grant privileges
+Cleanup of NULL in inet types
+Clean up system table bugs(Tom)
+Fix problems of PAGER and \? command(Masaaki Sakaida)
+Reduce default multisegment file size limit to 1GB(Peter)
+Fix for dumping of CREATE OPERATOR(Tom)
+Fix for backward scanning of cursors(Hiroshi Inoue)
+Fix for COPY FROM STDIN when using \i(Tom)
+Fix for subselect is compared inside an expression(Jan)
+Fix handling of error reporting while returning rows(Tom)
+Fix problems with reference to array types(Tom,Jan)
+Prevent UPDATE SET oid(Jan)
+Fix pg_dump so -t option can handle case-sensitive tablenames
+Fixes for GROUP BY in special cases(Tom, Jan)
+Fix for memory leak in failed queries(Tom)
+DEFAULT now supports mixed-case identifiers(Tom)
+Fix for multisegment uses of DROP/RENAME table, indexes(Ole Gjerde)
+Disable use of pg_dump with both -o and -d options(Bruce)
+Allow pg_dump to properly dump group privileges(Bruce)
+Fix GROUP BY in INSERT INTO table SELECT * FROM table2(Jan)
+Fix for computations in views(Jan)
+Fix for aggregates on array indexes(Tom)
+Fix for DEFAULT handles single quotes in value requiring too many quotes
+Fix security problem with non-super users importing/exporting large objects(Tom)
+Rollback of transaction that creates table cleaned up properly(Tom)
+Fix to allow long table and column names to generate proper serial names(Tom)
+
+Enhancements
+------------
+Add "vacuumdb" utility
+Speed up libpq by allocating memory better(Tom)
+EXPLAIN all indexes used(Tom)
+Implement CASE, COALESCE, NULLIF  expression(Thomas)
+New pg_dump table output format(Constantin)
+Add string min()/max() functions(Thomas)
+Extend new type coercion techniques to aggregates(Thomas)
+New moddatetime contrib(Terry)
+Update to pgaccess 0.96(Constantin)
+Add routines for single-byte "char" type(Thomas)
+Improved substr() function(Thomas)
+Improved multibyte handling(Tatsuo)
+Multiversion concurrency control/MVCC(Vadim)
+New Serialized mode(Vadim)
+Fix for tables over 2gigs(Peter)
+New SET TRANSACTION ISOLATION LEVEL(Vadim)
+New LOCK TABLE IN ... MODE(Vadim)
+Update ODBC driver(Byron)
+New NUMERIC data type(Jan)
+New SELECT FOR UPDATE(Vadim)
+Handle "NaN" and "Infinity" for input values(Jan)
+Improved date/year handling(Thomas)
+Improved handling of backend connections(Magnus)
+New options ELOG_TIMESTAMPS and USE_SYSLOG options for log files(Massimo)
+New TCL_ARRAYS option(Massimo)
+New INTERSECT and EXCEPT(Stefan)
+New pg_index.indisprimary for primary key tracking(D'Arcy)
+New pg_dump option to allow dropping of tables before creation(Brook)
+Speedup of row output routines(Tom)
+New READ COMMITTED isolation level(Vadim)
+New TEMP tables/indexes(Bruce)
+Prevent sorting if result is already sorted(Jan)
+New memory allocation optimization(Jan)
+Allow psql to do \p\g(Bruce)
+Allow multiple rule actions(Jan)
+Added LIMIT/OFFSET functionality(Jan)
+Improve optimizer when joining a large number of tables(Bruce)
+New intro to SQL from S. Simkovics' Master's Thesis (Stefan, Thomas)
+New intro to backend processing from S. Simkovics' Master's Thesis (Stefan)
+Improved int8 support(Ryan Bradetich, Thomas, Tom)
+New routines to convert between int8 and text/varchar types(Thomas)
+New bushy plans, where meta-tables are joined(Bruce)
+Enable right-hand queries by default(Bruce)
+Allow reliable maximum number of backends to be set at configure time
+     (--with-maxbackends and postmaster switch (-N backends))(Tom)
+GEQO default now 10 tables because of optimizer speedups(Tom)
+Allow NULL=Var for MS-SQL portability(Michael, Bruce)
+Modify contrib check_primary_key() so either "automatic" or "dependent"(Anand)
+Allow psql \d on a view show query(Ryan)
+Speedup for LIKE(Bruce)
+Ecpg fixes/features, see src/interfaces/ecpg/ChangeLog file(Michael)
+JDBC fixes/features, see src/interfaces/jdbc/CHANGELOG(Peter)
+Make % operator have precedence like /(Bruce)
+Add new postgres -O option to allow system table structure changes(Bruce)
+Update contrib/pginterface/findoidjoins script(Tom)
+Major speedup in vacuum of deleted rows with indexes(Vadim)
+Allow non-SQL functions to run different versions based on arguments(Tom)
+Add -E option that shows actual queries sent by \dt and friends(Masaaki Sakaida)
+Add version number in start-up banners for psql(Masaaki Sakaida)
+New contrib/vacuumlo removes large objects not referenced(Peter)
+New initialization for table sizes so non-vacuumed tables perform better(Tom)
+Improve error messages when a connection is rejected(Tom)
+Support for arrays of char() and varchar() fields(Massimo)
+Overhaul of hash code to increase reliability and performance(Tom)
+Update to PyGreSQL 2.4(D'Arcy)
+Changed debug options so -d4 and -d5 produce different node displays(Jan)
+New pg_options: pretty_plan, pretty_parse, pretty_rewritten(Jan)
+Better optimization statistics for system table access(Tom)
+Better handling of non-default block sizes(Massimo)
+Improve GEQO optimizer memory consumption(Tom)
+UNION now supports ORDER BY of columns not in target list(Jan)
+Major libpq++ improvements(Vince Vielhaber)
+pg_dump now uses -z(ACL's) as default(Bruce)
+backend cache, memory speedups(Tom)
+have pg_dump do everything in one snapshot transaction(Vadim)
+fix for large object memory leakage, fix for pg_dumping(Tom)
+INET type now respects netmask for comparisons
+Make VACUUM ANALYZE only use a readlock(Vadim)
+Allow VIEWs on UNIONS(Jan)
+pg_dump now can generate consistent snapshots on active databases(Vadim)
+
+Source Tree Changes
+-------------------
+Improve port matching(Tom)
+Portability fixes for SunOS
+Add Windows NT backend port and enable dynamic loading(Magnus and Daniel Horak)
+New port to Cobalt Qube(Mips) running Linux(Tatsuo)
+Port to NetBSD/m68k(Mr. Mutsuki Nakajima)
+Port to NetBSD/sun3(Mr. Mutsuki Nakajima)
+Port to NetBSD/macppc(Toshimi Aoki)
+Fix for tcl/tk configuration(Vince)
+Removed CURRENT key word for rule queries(Jan)
+NT dynamic loading now works(Daniel Horak)
+Add ARM32 support(Andrew McMurry)
+Better support for HP-UX 11 and UnixWare
+Improve file handling to be more uniform, prevent file descriptor leak(Tom)
+New install commands for plpgsql(Jan)

+


PrevHomeNext
Release 6.5.1UpRelease 6.4.2
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-0-1.html b/doc/src/sgml/html/release-7-0-1.html new file mode 100644 index 000000000..81bca633c --- /dev/null +++ b/doc/src/sgml/html/release-7-0-1.html @@ -0,0 +1,233 @@ + +Release 7.0.1

E.206. Release 7.0.1

Release Date: 2000-06-01

This is a cleanup release for 7.0. +

E.206.1. Migration to Version 7.0.1

A dump/restore is not required for those running + 7.0. +

E.206.2. Changes

Fix many CLUSTER failures (Tom)
+Allow ALTER TABLE RENAME works on indexes (Tom)
+Fix plpgsql to handle datetime->timestamp and timespan->interval (Bruce)
+New configure --with-setproctitle switch to use setproctitle() (Marc, Bruce)
+Fix the off by one errors in ResultSet from 6.5.3, and more.
+jdbc ResultSet fixes (Joseph Shraibman)
+optimizer tunings (Tom)
+Fix create user for pgaccess
+Fix for UNLISTEN failure
+IRIX fixes (David Kaelbling)
+QNX fixes (Andreas Kardos)
+Reduce COPY IN lock level (Tom)
+Change libpqeasy to use PQconnectdb() style parameters (Bruce)
+Fix pg_dump to handle OID indexes (Tom)
+Fix small memory leak (Tom)
+Solaris fix for createdb/dropdb (Tatsuo)
+Fix for non-blocking connections (Alfred Perlstein)
+Fix improper recovery after RENAME TABLE failures (Tom)
+Copy pg_ident.conf.sample into /lib directory in install (Bruce)
+Add SJIS UDC (NEC selection IBM kanji) support (Eiji Tokuya)
+Fix too long syslog message (Tatsuo)
+Fix problem with quoted indexes that are too long (Tom)
+JDBC ResultSet.getTimestamp() fix (Gregory Krasnow & Floyd Marinescu)
+ecpg changes (Michael)

+


PrevHomeNext
Release 7.0.2UpRelease 7.0
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-0-2.html b/doc/src/sgml/html/release-7-0-2.html new file mode 100644 index 000000000..14919f294 --- /dev/null +++ b/doc/src/sgml/html/release-7-0-2.html @@ -0,0 +1,210 @@ + +Release 7.0.2

E.205. Release 7.0.2

Release Date: 2000-06-05

This is a repackaging of 7.0.1 with added documentation. +

E.205.1. Migration to Version 7.0.2

A dump/restore is not required for those running + 7.*. +

E.205.2. Changes

Added documentation to tarball.

+


PrevHomeNext
Release 7.0.3UpRelease 7.0.1
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-0-3.html b/doc/src/sgml/html/release-7-0-3.html new file mode 100644 index 000000000..2c311d8f4 --- /dev/null +++ b/doc/src/sgml/html/release-7-0-3.html @@ -0,0 +1,248 @@ + +Release 7.0.3

E.204. Release 7.0.3

Release Date: 2000-11-11

This has a variety of fixes from 7.0.2. +

E.204.1. Migration to Version 7.0.3

A dump/restore is not required for those running + 7.0.*. +

E.204.2. Changes

Jdbc fixes (Peter)
+Large object fix (Tom)
+Fix lean in COPY WITH OIDS leak (Tom)
+Fix backwards-index-scan (Tom)
+Fix SELECT ... FOR UPDATE so it checks for duplicate keys (Hiroshi)
+Add --enable-syslog to configure (Marc)
+Fix abort transaction at backend exit in rare cases (Tom)
+Fix for psql \l+ when multibyte enabled (Tatsuo)
+Allow PL/pgSQL to accept non ascii identifiers (Tatsuo)
+Make vacuum always flush buffers (Tom)
+Fix to allow cancel while waiting for a lock (Hiroshi)
+Fix for memory allocation problem in user authentication code (Tom)
+Remove bogus use of int4out() (Tom)
+Fixes for multiple subqueries in COALESCE or BETWEEN (Tom)
+Fix for failure of triggers on heap open in certain cases (Jeroen van
+   Vianen)
+Fix for erroneous selectivity of not-equals (Tom)
+Fix for erroneous use of strcmp() (Tom)
+Fix for bug where storage manager accesses items beyond end of file
+   (Tom)
+Fix to include kernel errno message in all smgr elog messages (Tom)
+Fix for '.' not in PATH at build time (SL Baur)
+Fix for out-of-file-descriptors error (Tom)
+Fix to make pg_dump dump 'iscachable' flag for functions (Tom)
+Fix for subselect in targetlist of Append node (Tom)
+Fix for mergejoin plans (Tom)
+Fix TRUNCATE failure on relations with indexes (Tom)
+Avoid database-wide restart on write error (Hiroshi)
+Fix nodeMaterial to honor chgParam by recomputing its output (Tom)
+Fix VACUUM problem with moving chain of update row versions when source
+   and destination of a row version lie on the same page (Tom)
+Fix user.c CommandCounterIncrement (Tom)
+Fix for AM/PM boundary problem in to_char() (Karel Zak)
+Fix TIME aggregate handling (Tom)
+Fix to_char() to avoid coredump on NULL input (Tom)
+Buffer fix (Tom)
+Fix for inserting/copying longer multibyte strings into char() data
+   types (Tatsuo)
+Fix for crash of backend, on abort (Tom)

+


PrevHomeNext
Release 7.1UpRelease 7.0.2
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-0.html b/doc/src/sgml/html/release-7-0.html new file mode 100644 index 000000000..31f7e1b1e --- /dev/null +++ b/doc/src/sgml/html/release-7-0.html @@ -0,0 +1,721 @@ + +Release 7.0

E.207. Release 7.0

Release Date: 2000-05-08

This release contains improvements in many areas, demonstrating + the continued growth of PostgreSQL. + There are more improvements and fixes in 7.0 than in any previous + release. The developers have confidence that this is the best + release yet; we do our best to put out only solid releases, and + this one is no exception. +

Major changes in this release: +

Foreign Keys

Foreign keys are now implemented, with the exception of PARTIAL MATCH + foreign keys. Many users have been asking for this feature, and we are + pleased to offer it. +

Optimizer Overhaul

Continuing on work started a year ago, the optimizer has been + improved, allowing better query plan selection and faster performance + with less memory usage. +

Updated psql

psql, our interactive terminal monitor, has been + updated with a variety of new features. See the psql manual page for details. +

Join Syntax

SQL92 join syntax is now supported, though only as + INNER JOIN for this release. JOIN, + NATURAL JOIN, JOIN/USING, + and JOIN/ON are available, as are + column correlation names. +

E.207.1. Migration to Version 7.0

A dump/restore using pg_dump + is required for those wishing to migrate data from any + previous release of PostgreSQL. + For those upgrading from 6.5.*, you can instead use + pg_upgrade to upgrade to this + release; however, a full dump/reload installation is always the + most robust method for upgrades. +

Interface and compatibility issues to consider for the new + release include: +

  • The date/time types datetime and + timespan have been superseded by the + SQL92-defined types timestamp and + interval. Although there has been some effort to + ease the transition by allowing + PostgreSQL to recognize + the deprecated type names and translate them to the new type + names, this mechanism cannot be completely transparent to + your existing application. +

  • The optimizer has been substantially improved in the area of + query cost estimation. In some cases, this will result in + decreased query times as the optimizer makes a better choice + for the preferred plan. However, in a small number of cases, + usually involving pathological distributions of data, your + query times might go up. If you are dealing with large amounts + of data, you might want to check your queries to verify + performance. +

  • The JDBC and ODBC + interfaces have been upgraded and extended. +

  • The string function CHAR_LENGTH is now a + native function. Previous versions translated this into a call + to LENGTH, which could result in + ambiguity with other types implementing + LENGTH such as the geometric types. +

E.207.2. Changes

Bug Fixes
+---------
+Prevent function calls exceeding maximum number of arguments (Tom)
+Improve CASE construct (Tom)
+Fix SELECT coalesce(f1,0) FROM int4_tbl GROUP BY f1 (Tom)
+Fix SELECT sentence.words[0] FROM sentence GROUP BY sentence.words[0] (Tom)
+Fix GROUP BY scan bug (Tom)
+Improvements in SQL grammar processing (Tom)
+Fix for views involved in INSERT ... SELECT ... (Tom)
+Fix for SELECT a/2, a/2 FROM test_missing_target GROUP BY a/2 (Tom)
+Fix for subselects in INSERT ... SELECT (Tom)
+Prevent INSERT ... SELECT ... ORDER BY (Tom)
+Fixes for relations greater than 2GB, including vacuum
+Improve propagating system table changes to other backends (Tom)
+Improve propagating user table changes to other backends (Tom)
+Fix handling of temp tables in complex situations (Bruce, Tom)
+Allow table locking at table open, improving concurrent reliability (Tom)
+Properly quote sequence names in pg_dump (Ross J. Reedstrom)
+Prevent DROP DATABASE while others accessing
+Prevent any rows from being returned by GROUP BY if no rows processed (Tom)
+Fix SELECT COUNT(1) FROM table WHERE ...' if no rows matching WHERE (Tom)
+Fix pg_upgrade so it works for MVCC (Tom)
+Fix for SELECT ... WHERE x IN (SELECT ... HAVING SUM(x) > 1) (Tom)
+Fix for "f1 datetime DEFAULT 'now'"  (Tom)
+Fix problems with CURRENT_DATE used in DEFAULT (Tom)
+Allow comment-only lines, and ;;; lines too. (Tom)
+Improve recovery after failed disk writes, disk full (Hiroshi)
+Fix cases where table is mentioned in FROM but not joined (Tom)
+Allow HAVING clause without aggregate functions (Tom)
+Fix for "--" comment and no trailing newline, as seen in perl interface
+Improve pg_dump failure error reports (Bruce)
+Allow sorts and hashes to exceed 2GB file sizes (Tom)
+Fix for pg_dump dumping of inherited rules (Tom)
+Fix for NULL handling comparisons (Tom)
+Fix inconsistent state caused by failed CREATE/DROP commands (Hiroshi)
+Fix for dbname with dash
+Prevent DROP INDEX from interfering with other backends (Tom)
+Fix file descriptor leak in verify_password()
+Fix for "Unable to identify an operator =$" problem
+Fix ODBC so no segfault if CommLog and Debug enabled (Dirk Niggemann)
+Fix for recursive exit call (Massimo)
+Fix for extra-long timezones (Jeroen van Vianen)
+Make pg_dump preserve primary key information (Peter E)
+Prevent databases with single quotes (Peter E)
+Prevent DROP DATABASE inside  transaction (Peter E)
+ecpg memory leak fixes (Stephen Birch)
+Fix for SELECT null::text, SELECT int4fac(null) and SELECT 2 + (null) (Tom)
+Y2K timestamp fix (Massimo)
+Fix for VACUUM 'HEAP_MOVED_IN was not expected' errors (Tom)
+Fix for views with tables/columns containing spaces  (Tom)
+Prevent privileges on indexes (Peter E)
+Fix for spinlock stuck problem when error is generated (Hiroshi)
+Fix ipcclean on Linux
+Fix handling of NULL constraint conditions (Tom)
+Fix memory leak in odbc driver (Nick Gorham)
+Fix for privilege check on UNION tables (Tom)
+Fix to allow SELECT 'a' LIKE 'a' (Tom)
+Fix for SELECT 1 + NULL (Tom)
+Fixes to CHAR
+Fix log() on numeric type (Tom)
+Deprecate ':' and ';' operators
+Allow vacuum of temporary tables
+Disallow inherited columns with the same name as new columns
+Recover or force failure when disk space is exhausted (Hiroshi)
+Fix INSERT INTO ... SELECT with AS columns matching result columns
+Fix INSERT ... SELECT ... GROUP BY groups by target columns not source columns (Tom)
+Fix CREATE TABLE test (a char(5) DEFAULT text '', b int4) with INSERT (Tom)
+Fix UNION with LIMIT
+Fix CREATE TABLE x AS SELECT 1 UNION SELECT 2
+Fix CREATE TABLE test(col char(2) DEFAULT user)
+Fix mismatched types in CREATE TABLE ... DEFAULT
+Fix SELECT * FROM pg_class where oid in (0,-1)
+Fix SELECT COUNT('asdf') FROM pg_class WHERE oid=12
+Prevent user who can create databases can modifying pg_database table (Peter E)
+Fix btree to give a useful elog when key > 1/2 (page - overhead) (Tom)
+Fix INSERT of 0.0 into DECIMAL(4,4) field (Tom)
+
+Enhancements
+------------
+New CLI interface include file sqlcli.h, based on SQL3/SQL98
+Remove all limits on query length, row length limit still exists (Tom)
+Update jdbc protocol to 2.0 (Jens Glaser <jens@jens.de>)
+Add TRUNCATE command to quickly truncate relation (Mike Mascari)
+Fix to give super user and createdb user proper update catalog rights (Peter E)
+Allow ecpg bool variables to have NULL values (Christof)
+Issue ecpg error if NULL value for variable with no NULL indicator (Christof)
+Allow ^C to cancel COPY command (Massimo)
+Add SET FSYNC and SHOW PG_OPTIONS commands(Massimo)
+Function name overloading for dynamically-loaded C functions (Frankpitt)
+Add CmdTuples() to libpq++(Vince)
+New CREATE CONSTRAINT TRIGGER and SET CONSTRAINTS commands(Jan)
+Allow CREATE FUNCTION/WITH clause to be used for all language types
+configure --enable-debug adds -g (Peter E)
+configure --disable-debug removes -g (Peter E)
+Allow more complex default expressions (Tom)
+First real FOREIGN KEY constraint trigger functionality (Jan)
+Add FOREIGN KEY ... MATCH FULL ... ON DELETE CASCADE (Jan)
+Add FOREIGN KEY ... MATCH <unspecified> referential actions (Don Baccus)
+Allow WHERE restriction on ctid (physical heap location) (Hiroshi)
+Move pginterface from contrib to interface directory, rename to pgeasy (Bruce)
+Change pgeasy connectdb() parameter ordering (Bruce)
+Require SELECT DISTINCT target list to have all ORDER BY columns (Tom)
+Add Oracle's COMMENT ON command (Mike Mascari <mascarim@yahoo.com>)
+libpq's PQsetNoticeProcessor function now returns previous hook(Peter E)
+Prevent PQsetNoticeProcessor from being set to NULL (Peter E)
+Make USING in COPY optional (Bruce)
+Allow subselects in the target list (Tom)
+Allow subselects on the left side of comparison operators (Tom)
+New parallel regression test (Jan)
+Change backend-side COPY to write files with permissions 644 not 666 (Tom)
+Force permissions on PGDATA directory to be secure, even if it exists (Tom)
+Added psql LASTOID variable to return last inserted oid (Peter E)
+Allow concurrent vacuum and remove pg_vlock vacuum lock file (Tom)
+Add privilege check for vacuum (Peter E)
+New libpq functions to allow asynchronous connections: PQconnectStart(),
+  PQconnectPoll(), PQresetStart(), PQresetPoll(), PQsetenvStart(),
+  PQsetenvPoll(), PQsetenvAbort (Ewan Mellor)
+New libpq PQsetenv() function (Ewan Mellor)
+create/alter user extension (Peter E)
+New postmaster.pid and postmaster.opts under $PGDATA (Tatsuo)
+New scripts for create/drop user/db (Peter E)
+Major psql overhaul (Peter E)
+Add const to libpq interface (Peter E)
+New libpq function PQoidValue (Peter E)
+Show specific non-aggregate causing problem with GROUP BY (Tom)
+Make changes to pg_shadow recreate pg_pwd file (Peter E)
+Add aggregate(DISTINCT ...) (Tom)
+Allow flag to control COPY input/output of NULLs (Peter E)
+Make postgres user have a password by default (Peter E)
+Add CREATE/ALTER/DROP GROUP (Peter E)
+All administration scripts now support --long options (Peter E, Karel)
+Vacuumdb script now supports --all option (Peter E)
+ecpg new portable FETCH syntax
+Add ecpg EXEC SQL IFDEF, EXEC SQL IFNDEF, EXEC SQL ELSE, EXEC SQL ELIF
+       and EXEC SQL ENDIF directives
+Add pg_ctl script to control backend start-up (Tatsuo)
+Add postmaster.opts.default file to store start-up flags (Tatsuo)
+Allow --with-mb=SQL_ASCII
+Increase maximum number of index keys to 16 (Bruce)
+Increase maximum number of function arguments to 16 (Bruce)
+Allow configuration of maximum number of index keys and arguments (Bruce)
+Allow unprivileged users to change their passwords (Peter E)
+Password authentication enabled; required for new users (Peter E)
+Disallow dropping a user who owns a database (Peter E)
+Change initdb option --with-mb to --enable-multibyte
+Add option for initdb to prompts for superuser password (Peter E)
+Allow complex type casts like col::numeric(9,2) and col::int2::float8 (Tom)
+Updated user interfaces on initdb, initlocation, pg_dump, ipcclean (Peter E)
+New pg_char_to_encoding() and pg_encoding_to_char() functions (Tatsuo)
+libpq non-blocking mode (Alfred Perlstein)
+Improve conversion of types in casts that don't specify a length
+New plperl internal programming language (Mark Hollomon)
+Allow COPY IN to read file that do not end with a newline (Tom)
+Indicate when long identifiers are truncated (Tom)
+Allow aggregates to use type equivalency (Peter E)
+Add Oracle's to_char(), to_date(), to_datetime(), to_timestamp(), to_number()
+       conversion functions (Karel Zak <zakkr@zf.jcu.cz>)
+Add SELECT DISTINCT ON (expr [, expr ...]) targetlist ... (Tom)
+Check to be sure ORDER BY is compatible with the DISTINCT operation (Tom)
+Add NUMERIC and int8 types to ODBC
+Improve EXPLAIN results for Append, Group, Agg, Unique (Tom)
+Add ALTER TABLE ... ADD FOREIGN KEY (Stephan Szabo)
+Allow SELECT .. FOR UPDATE in PL/pgSQL (Hiroshi)
+Enable backward sequential scan even after reaching EOF (Hiroshi)
+Add btree indexing of boolean values, >= and <= (Don Baccus)
+Print current line number when COPY FROM fails (Massimo)
+Recognize POSIX time zone e.g. "PST+8" and "GMT-8" (Thomas)
+Add DEC as synonym for DECIMAL (Thomas)
+Add SESSION_USER as SQL92 key word, same as CURRENT_USER (Thomas)
+Implement SQL92 column aliases (aka correlation names) (Thomas)
+Implement SQL92 join syntax (Thomas)
+Make INTERVAL reserved word allowed as a column identifier (Thomas)
+Implement REINDEX command (Hiroshi)
+Accept ALL in aggregate function SUM(ALL col) (Tom)
+Prevent GROUP BY from using column aliases (Tom)
+New psql \encoding option (Tatsuo)
+Allow PQrequestCancel() to terminate when in waiting-for-lock state (Hiroshi)
+Allow negation of a negative number in all cases
+Add ecpg descriptors (Christof, Michael)
+Allow CREATE VIEW v AS SELECT f1::char(8) FROM tbl
+Allow casts with length, like foo::char(8)
+New libpq functions PQsetClientEncoding(), PQclientEncoding() (Tatsuo)
+Add support for SJIS user defined characters (Tatsuo)
+Larger views/rules supported
+Make libpq's PQconndefaults() thread-safe (Tom)
+Disable // as comment to be ANSI conforming, should use -- (Tom)
+Allow column aliases on views CREATE VIEW name (collist)
+Fixes for views with subqueries (Tom)
+Allow UPDATE table SET fld = (SELECT ...) (Tom)
+SET command options no longer require quotes
+Update pgaccess to 0.98.6
+New SET SEED command
+New pg_options.sample file
+New SET FSYNC command (Massimo)
+Allow pg_descriptions when creating tables
+Allow pg_descriptions when creating types, columns, and functions
+Allow psql \copy to allow delimiters (Peter E)
+Allow psql to print nulls as distinct from "" [null] (Peter E)
+
+Types
+-----
+Many array fixes (Tom)
+Allow bare column names to be subscripted as arrays (Tom)
+Improve type casting of int and float constants (Tom)
+Cleanups for int8 inputs, range checking, and type conversion (Tom)
+Fix for SELECT timespan('21:11:26'::time) (Tom)
+netmask('x.x.x.x/0') is 255.255.255.255 instead of 0.0.0.0 (Oleg Sharoiko)
+Add btree index on NUMERIC (Jan)
+Perl fix for large objects containing NUL characters (Douglas Thomson)
+ODBC fix for large objects (free)
+Fix indexing of cidr data type
+Fix for Ethernet MAC addresses (macaddr type) comparisons
+Fix for date/time types when overflows happened in computations (Tom)
+Allow array on int8 (Peter E)
+Fix for rounding/overflow of NUMERIC type, like NUMERIC(4,4) (Tom)
+Allow NUMERIC arrays
+Fix bugs in NUMERIC ceil() and floor() functions (Tom)
+Make char_length()/octet_length including trailing blanks (Tom)
+Made abstime/reltime use int4 instead of time_t (Peter E)
+New lztext data type for compressed text fields
+Revise code to handle coercion of int and float constants (Tom)
+Start at new code to implement a BIT and BIT VARYING type (Adriaan Joubert)
+NUMERIC now accepts scientific notation (Tom)
+NUMERIC to int4 rounds (Tom)
+Convert float4/8 to NUMERIC properly (Tom)
+Allow type conversion with NUMERIC (Thomas)
+Make ISO date style (2000-02-16 09:33) the default (Thomas)
+Add NATIONAL CHAR [ VARYING ] (Thomas)
+Allow NUMERIC round and trunc to accept negative scales (Tom)
+New TIME WITH TIME ZONE type (Thomas)
+Add MAX()/MIN() on time type (Thomas)
+Add abs(), mod(), fac() for int8 (Thomas)
+Rename functions to round(), sqrt(), cbrt(), pow() for float8 (Thomas)
+Add transcendental math functions (e.g. sin(), acos()) for float8 (Thomas)
+Add exp() and ln() for NUMERIC type
+Rename NUMERIC power() to pow() (Thomas)
+Improved TRANSLATE() function (Edwin Ramirez, Tom)
+Allow X=-Y operators  (Tom)
+Allow SELECT float8(COUNT(*))/(SELECT COUNT(*) FROM t) FROM t GROUP BY f1; (Tom)
+Allow LOCALE to use indexes in regular expression searches (Tom)
+Allow creation of functional indexes to use default types
+
+Performance
+-----------
+Prevent exponential space consumption with many AND's and OR's (Tom)
+Collect attribute selectivity values for system columns (Tom)
+Reduce memory usage of aggregates (Tom)
+Fix for LIKE optimization to use indexes with multibyte encodings (Tom)
+Fix r-tree index optimizer selectivity (Thomas)
+Improve optimizer selectivity computations and functions (Tom)
+Optimize btree searching for cases where many equal keys exist (Tom)
+Enable fast LIKE index processing only if index present (Tom)
+Re-use free space on index pages with duplicates (Tom)
+Improve hash join processing (Tom)
+Prevent descending sort if result is already sorted(Hiroshi)
+Allow commuting of index scan query qualifications (Tom)
+Prefer index scans in cases where ORDER BY/GROUP BY is required (Tom)
+Allocate large memory requests in fix-sized chunks for performance (Tom)
+Fix vacuum's performance by reducing memory allocation requests (Tom)
+Implement constant-expression simplification (Bernard Frankpitt, Tom)
+Use secondary columns to be used to determine start of index scan (Hiroshi)
+Prevent quadruple use of disk space when doing internal sorting (Tom)
+Faster sorting by calling fewer functions (Tom)
+Create system indexes to match all system caches (Bruce, Hiroshi)
+Make system caches use system indexes (Bruce)
+Make all system indexes unique (Bruce)
+Improve pg_statistics management for VACUUM speed improvement (Tom)
+Flush backend cache less frequently (Tom, Hiroshi)
+COPY now reuses previous memory allocation, improving performance (Tom)
+Improve optimization cost estimation (Tom)
+Improve optimizer estimate of range queries x > lowbound AND x < highbound (Tom)
+Use DNF instead of CNF where appropriate (Tom, Taral)
+Further cleanup for OR-of-AND WHERE-clauses (Tom)
+Make use of index in OR clauses (x = 1 AND y = 2) OR (x = 2 AND y = 4) (Tom)
+Smarter optimizer computations for random index page access (Tom)
+New SET variable to control optimizer costs (Tom)
+Optimizer queries based on LIMIT, OFFSET, and EXISTS qualifications (Tom)
+Reduce optimizer internal housekeeping of join paths for speedup (Tom)
+Major subquery speedup (Tom)
+Fewer fsync writes when fsync is not disabled (Tom)
+Improved LIKE optimizer estimates (Tom)
+Prevent fsync in SELECT-only queries (Vadim)
+Make index creation use psort code, because it is now faster (Tom)
+Allow creation of sort temp tables > 1 Gig
+
+Source Tree Changes
+-------------------
+Fix for linux PPC compile
+New generic expression-tree-walker subroutine (Tom)
+Change form() to varargform() to prevent portability problems
+Improved range checking for large integers on Alphas
+Clean up #include in /include directory (Bruce)
+Add scripts for checking includes (Bruce)
+Remove un-needed #include's from *.c files (Bruce)
+Change #include's to use <> and "" as appropriate (Bruce)
+Enable Windows compilation of libpq
+Alpha spinlock fix from Uncle George <gatgul@voicenet.com>
+Overhaul of optimizer data structures (Tom)
+Fix to cygipc library (Yutaka Tanida)
+Allow pgsql to work on newer Cygwin snapshots (Dan)
+New catalog version number (Tom)
+Add Linux ARM
+Rename heap_replace to heap_update
+Update for QNX (Dr. Andreas Kardos)
+New platform-specific regression handling (Tom)
+Rename oid8 -> oidvector and int28 -> int2vector (Bruce)
+Included all yacc and lex files into the distribution (Peter E.)
+Remove lextest, no longer needed (Peter E)
+Fix for libpq and psql on Windows (Magnus)
+Internally change datetime and timespan into timestamp and interval (Thomas)
+Fix for plpgsql on BSD/OS
+Add SQL_ASCII test case to the regression test (Tatsuo)
+configure --with-mb now deprecated (Tatsuo)
+NT fixes
+NetBSD fixes (Johnny C. Lam <lamj@stat.cmu.edu>)
+Fixes for Alpha compiles
+New multibyte encodings

+


PrevHomeNext
Release 7.0.1UpRelease 6.5.3
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-1-1.html b/doc/src/sgml/html/release-7-1-1.html new file mode 100644 index 000000000..384ffbab2 --- /dev/null +++ b/doc/src/sgml/html/release-7-1-1.html @@ -0,0 +1,223 @@ + +Release 7.1.1

E.202. Release 7.1.1

Release Date: 2001-05-05

This has a variety of fixes from 7.1. +

E.202.1. Migration to Version 7.1.1

A dump/restore is not required for those running + 7.1. +

E.202.2. Changes

Fix for numeric MODULO operator (Tom)
+pg_dump fixes (Philip)
+pg_dump can dump 7.0 databases (Philip)
+readline 4.2 fixes (Peter E)
+JOIN fixes (Tom)
+AIX, MSWIN, VAX, N32K fixes (Tom)
+Multibytes fixes (Tom)
+Unicode fixes (Tatsuo)
+Optimizer improvements (Tom)
+Fix for whole rows in functions (Tom)
+Fix for pg_ctl and option strings with spaces (Peter E)
+ODBC fixes (Hiroshi)
+EXTRACT can now take string argument (Thomas)
+Python fixes (Darcy)

+


PrevHomeNext
Release 7.1.2UpRelease 7.1
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-1-2.html b/doc/src/sgml/html/release-7-1-2.html new file mode 100644 index 000000000..5bc460851 --- /dev/null +++ b/doc/src/sgml/html/release-7-1-2.html @@ -0,0 +1,214 @@ + +Release 7.1.2

E.201. Release 7.1.2

Release Date: 2001-05-11

This has one fix from 7.1.1. +

E.201.1. Migration to Version 7.1.2

A dump/restore is not required for those running + 7.1.X. +

E.201.2. Changes

Fix PL/pgSQL SELECTs when returning no rows
+Fix for psql backslash core dump
+Referential integrity privilege fix
+Optimizer fixes
+pg_dump cleanups

+


PrevHomeNext
Release 7.1.3UpRelease 7.1.1
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-1-3.html b/doc/src/sgml/html/release-7-1-3.html new file mode 100644 index 000000000..abe245507 --- /dev/null +++ b/doc/src/sgml/html/release-7-1-3.html @@ -0,0 +1,216 @@ + +Release 7.1.3

E.200. Release 7.1.3

Release Date: 2001-08-15

E.200.1. Migration to Version 7.1.3

A dump/restore is not required for those running + 7.1.X. +

E.200.2. Changes

Remove unused WAL segments of large transactions (Tom)
+Multiaction rule fix (Tom)
+PL/pgSQL memory allocation fix (Jan)
+VACUUM buffer fix (Tom)
+Regression test fixes (Tom)
+pg_dump fixes for GRANT/REVOKE/comments on views, user-defined types (Tom)
+Fix subselects with DISTINCT ON or LIMIT (Tom)
+BeOS fix
+Disable COPY TO/FROM a view (Tom)
+Cygwin build (Jason Tishler)

+


PrevHomeNext
Release 7.2UpRelease 7.1.2
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-1.html b/doc/src/sgml/html/release-7-1.html new file mode 100644 index 000000000..941c978d3 --- /dev/null +++ b/doc/src/sgml/html/release-7-1.html @@ -0,0 +1,461 @@ + +Release 7.1

E.203. Release 7.1

Release Date: 2001-04-13

This release focuses on removing limitations that have existed in the + PostgreSQL code for many years. +

Major changes in this release: +

Write-ahead Log (WAL)

To maintain database consistency in case of an operating system crash, +previous releases of PostgreSQL have forced +all data modifications to disk before each transaction commit. With +WAL, only one log file must be flushed to disk, greatly improving +performance. If you have been using -F in previous releases to +disable disk flushes, you might want to consider discontinuing its use. +

TOAST

TOAST - Previous releases had a compiled-in row length limit, +typically 8k - 32k. This limit made storage of long text fields +difficult. With TOAST, long rows of any length can be stored with good +performance. +

Outer Joins

We now support outer joins. The UNION/NOT IN +workaround for outer joins is no longer required. We use the SQL92 +outer join syntax. +

Function Manager

The previous C function manager did not +handle null values properly, nor did it support 64-bit CPU's (Alpha). The new +function manager does. You can continue using your old custom +functions, but you might want to rewrite them in the future to use the new +function manager call interface. +

Complex Queries

A large number of complex queries that were +unsupported in previous releases now work. Many combinations of views, +aggregates, UNION, LIMIT, cursors, subqueries, and inherited tables +now work properly. Inherited tables are now accessed by default. +Subqueries in FROM are now supported. +

E.203.1. Migration to Version 7.1

A dump/restore using pg_dump is required for those wishing to migrate + data from any previous release. +

E.203.2. Changes

Bug Fixes
+---------
+Many multibyte/Unicode/locale fixes (Tatsuo and others)
+More reliable ALTER TABLE RENAME (Tom)
+Kerberos V fixes (David Wragg)
+Fix for INSERT INTO...SELECT where targetlist has subqueries (Tom)
+Prompt username/password on standard error (Bruce)
+Large objects inv_read/inv_write fixes (Tom)
+Fixes for to_char(), to_date(), to_ascii(), and to_timestamp() (Karel,
+   Daniel Baldoni)
+Prevent query expressions from leaking memory (Tom)
+Allow UPDATE of arrays elements (Tom)
+Wake up lock waiters during cancel (Hiroshi)
+Fix rare cursor crash when using hash join (Tom)
+Fix for DROP TABLE/INDEX in rolled-back transaction (Hiroshi)
+Fix psql crash from \l+ if MULTIBYTE enabled (Peter E)
+Fix truncation of rule names during CREATE VIEW (Ross Reedstrom)
+Fix PL/perl (Alex Kapranoff)
+Disallow LOCK on views (Mark Hollomon)
+Disallow INSERT/UPDATE/DELETE on views (Mark Hollomon)
+Disallow DROP RULE, CREATE INDEX, TRUNCATE on views (Mark Hollomon)
+Allow PL/pgSQL accept non-ASCII identifiers (Tatsuo)
+Allow views to proper handle GROUP BY, aggregates, DISTINCT (Tom)
+Fix rare failure with TRUNCATE command (Tom)
+Allow UNION/INTERSECT/EXCEPT to be used with ALL, subqueries, views,
+   DISTINCT, ORDER BY, SELECT...INTO (Tom)
+Fix parser failures during aborted transactions (Tom)
+Allow temporary relations to properly clean up indexes (Bruce)
+Fix VACUUM problem with moving rows in same page (Tom)
+Modify pg_dump to better handle user-defined items in template1 (Philip)
+Allow LIMIT in VIEW (Tom)
+Require cursor FETCH to honor LIMIT (Tom)
+Allow PRIMARY/FOREIGN Key definitions on inherited columns (Stephan)
+Allow ORDER BY, LIMIT in subqueries (Tom)
+Allow UNION in CREATE RULE (Tom)
+Make ALTER/DROP TABLE rollback-able (Vadim, Tom)
+Store initdb collation in pg_control so collation cannot be changed (Tom)
+Fix INSERT...SELECT with rules (Tom)
+Fix FOR UPDATE inside views and subselects (Tom)
+Fix OVERLAPS operators conform to SQL92 spec regarding NULLs (Tom)
+Fix lpad() and rpad() to handle length less than input string (Tom)
+Fix use of NOTIFY in some rules (Tom)
+Overhaul btree code (Tom)
+Fix NOT NULL use in Pl/pgSQL variables (Tom)
+Overhaul GIST code (Oleg)
+Fix CLUSTER to preserve constraints and column default (Tom)
+Improved deadlock detection handling (Tom)
+Allow multiple SERIAL columns in a table (Tom)
+Prevent occasional index corruption (Vadim)
+
+Enhancements
+------------
+Add OUTER JOINs (Tom)
+Function manager overhaul (Tom)
+Allow ALTER TABLE RENAME on indexes (Tom)
+Improve CLUSTER (Tom)
+Improve ps status display for more platforms (Peter E, Marc)
+Improve CREATE FUNCTION failure message (Ross)
+JDBC improvements (Peter, Travis Bauer, Christopher Cain, William Webber,
+   Gunnar)
+Grand Unified Configuration scheme/GUC.  Many options can now be set in
+   data/postgresql.conf, postmaster/postgres flags, or SET commands (Peter E)
+Improved handling of file descriptor cache (Tom)
+New warning code about auto-created table alias entries (Bruce)
+Overhaul initdb process (Tom, Peter E)
+Overhaul of inherited tables; inherited tables now accessed by default;
+  new ONLY key word prevents it (Chris Bitmead, Tom)
+ODBC cleanups/improvements (Nick Gorham, Stephan Szabo, Zoltan Kovacs,
+   Michael Fork)
+Allow renaming of temp tables (Tom)
+Overhaul memory manager contexts (Tom)
+pg_dumpall uses CREATE USER or CREATE GROUP rather using COPY (Peter E)
+Overhaul pg_dump (Philip Warner)
+Allow pg_hba.conf secondary password file to specify only username (Peter E)
+Allow TEMPORARY or TEMP key word when creating temporary tables (Bruce)
+New memory leak checker (Karel)
+New SET SESSION CHARACTERISTICS (Thomas)
+Allow nested block comments (Thomas)
+Add WITHOUT TIME ZONE type qualifier (Thomas)
+New ALTER TABLE ADD CONSTRAINT (Stephan)
+Use NUMERIC accumulators for INTEGER aggregates (Tom)
+Overhaul aggregate code (Tom)
+New VARIANCE and STDDEV() aggregates
+Improve dependency ordering of pg_dump (Philip)
+New pg_restore command (Philip)
+New pg_dump tar output option (Philip)
+New pg_dump of large objects  (Philip)
+New ESCAPE option to LIKE (Thomas)
+New case-insensitive LIKE - ILIKE (Thomas)
+Allow functional indexes to use binary-compatible type (Tom)
+Allow SQL functions to be used in more contexts (Tom)
+New pg_config utility (Peter E)
+New PL/pgSQL EXECUTE command which allows dynamic SQL and utility statements
+   (Jan)
+New PL/pgSQL GET DIAGNOSTICS statement for SPI value access (Jan)
+New quote_identifiers() and quote_literal() functions (Jan)
+New ALTER TABLE table OWNER TO user command (Mark Hollomon)
+Allow subselects in FROM, i.e. FROM (SELECT ...) [AS] alias (Tom)
+Update PyGreSQL to version 3.1 (D'Arcy)
+Store tables as files named by OID (Vadim)
+New SQL function setval(seq,val,bool) for use in pg_dump (Philip)
+Require DROP VIEW to remove views, no DROP TABLE (Mark)
+Allow DROP VIEW view1, view2 (Mark)
+Allow multiple objects in DROP INDEX, DROP RULE, and DROP TYPE (Tom)
+Allow automatic conversion to/from Unicode (Tatsuo, Eiji)
+New /contrib/pgcrypto hashing functions (Marko Kreen)
+New pg_dumpall --globals-only option (Peter E)
+New CHECKPOINT command for WAL which creates new WAL log file (Vadim)
+New AT TIME ZONE syntax (Thomas)
+Allow location of Unix domain socket to be configurable (David J. MacKenzie)
+Allow postmaster to listen on a specific IP address (David J. MacKenzie)
+Allow socket path name to be specified in hostname by using leading slash
+   (David J. MacKenzie)
+Allow CREATE DATABASE to specify template database (Tom)
+New utility to convert MySQL schema dumps to SQL92 and PostgreSQL (Thomas)
+New /contrib/rserv replication toolkit (Vadim)
+New file format for COPY BINARY (Tom)
+New /contrib/oid2name to map numeric files to table names (B Palmer)
+New "idle in transaction" ps status message (Marc)
+Update to pgaccess 0.98.7 (Constantin Teodorescu)
+pg_ctl now defaults to -w (wait) on shutdown, new -l (log) option
+Add rudimentary dependency checking to pg_dump (Philip)
+
+Types
+-----
+Fix INET/CIDR type ordering and add new functions (Tom)
+Make OID behave as an unsigned type (Tom)
+Allow BIGINT as synonym for INT8 (Peter E)
+New int2 and int8 comparison operators (Tom)
+New BIT and BIT VARYING types (Adriaan Joubert, Tom, Peter E)
+CHAR() no longer faster than VARCHAR() because of TOAST (Tom)
+New GIST seg/cube examples (Gene Selkov)
+Improved round(numeric) handling (Tom)
+Fix CIDR output formatting (Tom)
+New CIDR abbrev() function (Tom)
+
+Performance
+-----------
+Write-Ahead Log (WAL) to provide crash recovery with less performance
+   overhead (Vadim)
+ANALYZE stage of VACUUM no longer exclusively locks table (Bruce)
+Reduced file seeks (Denis Perchine)
+Improve BTREE code for duplicate keys (Tom)
+Store all large objects in a single table (Denis Perchine, Tom)
+Improve memory allocation performance (Karel, Tom)
+
+Source Code
+-----------
+New function manager call conventions (Tom)
+SGI portability fixes (David Kaelbling)
+New configure --enable-syslog option (Peter E)
+New BSDI README (Bruce)
+configure script moved to top level, not /src (Peter E)
+Makefile/configuration/compilation overhaul (Peter E)
+New configure --with-python option (Peter E)
+Solaris cleanups (Peter E)
+Overhaul /contrib Makefiles (Karel)
+New OpenSSL configuration option (Magnus, Peter E)
+AIX fixes (Andreas)
+QNX fixes (Maurizio)
+New heap_open(), heap_openr() API (Tom)
+Remove colon and semi-colon operators (Thomas)
+New pg_class.relkind value for views (Mark Hollomon)
+Rename ichar() to chr() (Karel)
+New documentation for btrim(), ascii(), chr(), repeat() (Karel)
+Fixes for NT/Cygwin (Pete Forman)
+AIX port fixes (Andreas)
+New BeOS port (David Reid, Cyril Velter)
+Add proofreader's changes to docs (Addison-Wesley, Bruce)
+New Alpha spinlock code (Adriaan Joubert, Compaq)
+UnixWare port overhaul (Peter E)
+New Darwin/Mac OS X port (Peter Bierman, Bruce Hartzler)
+New FreeBSD Alpha port (Alfred)
+Overhaul shared memory segments (Tom)
+Add IBM S/390 support (Neale Ferguson)
+Moved macmanuf to /contrib (Larry Rosenman)
+Syslog improvements (Larry Rosenman)
+New template0 database that contains no user additions (Tom)
+New /contrib/cube and /contrib/seg GIST sample code (Gene Selkov)
+Allow NetBSD's libedit instead of readline (Peter)
+Improved assembly language source code format (Bruce)
+New contrib/pg_logger
+New --template option to createdb
+New contrib/pg_control utility (Oliver)
+New FreeBSD tools ipc_check, start-scripts/freebsd

+


PrevHomeNext
Release 7.1.1UpRelease 7.0.3
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-2-1.html b/doc/src/sgml/html/release-7-2-1.html new file mode 100644 index 000000000..adca44a06 --- /dev/null +++ b/doc/src/sgml/html/release-7-2-1.html @@ -0,0 +1,272 @@ + +Release 7.2.1

E.198. Release 7.2.1

Release Date: 2002-03-21

This release contains a variety of fixes for version 7.2. +

E.198.1. Migration to Version 7.2.1

A dump/restore is not required for those + running version 7.2. +

E.198.2. Changes

  • Ensure that sequence counters do not go backwards after a crash (Tom)

  • Fix pgaccess kanji-conversion key binding (Tatsuo)

  • Optimizer improvements (Tom)

  • Cash I/O improvements (Tom)

  • New Russian FAQ

  • Compile fix for missing AuthBlockSig (Heiko)

  • Additional time zones and time zone fixes (Thomas)

  • Allow psql \connect to handle mixed case database and user names (Tom)

  • Return proper OID on command completion even with ON INSERT rules (Tom)

  • Allow COPY FROM to use 8-bit DELIMITERS (Tatsuo)

  • Fix bug in extract/date_part for milliseconds/microseconds (Tatsuo)

  • Improve handling of multiple UNIONs with different lengths (Tom)

  • contrib/btree_gist improvements (Teodor Sigaev)

  • contrib/tsearch dictionary improvements, see README.tsearch for an additional installation step (Thomas T. Thai, Teodor Sigaev)

  • Fix for array subscripts handling (Tom)

  • Allow EXECUTE of "CREATE TABLE AS ... SELECT" in PL/pgSQL (Tom)


PrevHomeNext
Release 7.2.2UpRelease 7.2
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-2-2.html b/doc/src/sgml/html/release-7-2-2.html new file mode 100644 index 000000000..08497b17d --- /dev/null +++ b/doc/src/sgml/html/release-7-2-2.html @@ -0,0 +1,263 @@ + +Release 7.2.2

E.197. Release 7.2.2

Release Date: 2002-08-23

This release contains a variety of fixes for version 7.2.1. +

E.197.1. Migration to Version 7.2.2

A dump/restore is not required for those + running version 7.2.*. +

E.197.2. Changes

  • Allow EXECUTE of "CREATE TABLE AS ... SELECT" in PL/pgSQL (Tom)

  • Fix for compressed transaction log id wraparound (Tom)

  • Fix PQescapeBytea/PQunescapeBytea so that they handle bytes > 0x7f (Tatsuo)

  • Fix for psql and pg_dump crashing when invoked with non-existent long options (Tatsuo)

  • Fix crash when invoking geometric operators (Tom)

  • Allow OPEN cursor(args) (Tom)

  • Fix for rtree_gist index build (Teodor)

  • Fix for dumping user-defined aggregates (Tom)

  • contrib/intarray fixes (Oleg)

  • Fix for complex UNION/EXCEPT/INTERSECT queries using parens (Tom)

  • Fix to pg_convert (Tatsuo)

  • Fix for crash with long DATA strings (Thomas, Neil)

  • Fix for repeat(), lpad(), rpad() and long strings (Neil)


PrevHomeNext
Release 7.2.3UpRelease 7.2.1
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-2-3.html b/doc/src/sgml/html/release-7-2-3.html new file mode 100644 index 000000000..976a5180c --- /dev/null +++ b/doc/src/sgml/html/release-7-2-3.html @@ -0,0 +1,236 @@ + +Release 7.2.3

E.196. Release 7.2.3

Release Date: 2002-10-01

This release contains a variety of fixes for version 7.2.2, + including fixes to prevent possible data loss. +

E.196.1. Migration to Version 7.2.3

A dump/restore is not required for those + running version 7.2.*. +

E.196.2. Changes

  • Prevent possible compressed transaction log loss (Tom)

  • Prevent non-superuser from increasing most recent vacuum info (Tom)

  • Handle pre-1970 date values in newer versions of glibc (Tom)

  • Fix possible hang during server shutdown

  • Prevent spinlock hangs on SMP PPC machines (Tomoyuki Niijima)

  • Fix pg_dump to properly dump FULL JOIN USING (Tom)


PrevHomeNext
Release 7.2.4UpRelease 7.2.2
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-2-4.html b/doc/src/sgml/html/release-7-2-4.html new file mode 100644 index 000000000..ef06fe491 --- /dev/null +++ b/doc/src/sgml/html/release-7-2-4.html @@ -0,0 +1,241 @@ + +Release 7.2.4

E.195. Release 7.2.4

Release Date: 2003-01-30

This release contains a variety of fixes for version 7.2.3, + including fixes to prevent possible data loss. +

E.195.1. Migration to Version 7.2.4

A dump/restore is not required for those + running version 7.2.*. +

E.195.2. Changes

  • Fix some additional cases of VACUUM "No one parent tuple was found" error

  • Prevent VACUUM from being called inside a function (Bruce)

  • Ensure pg_clog updates are sync'd to disk before marking checkpoint complete

  • Avoid integer overflow during large hash joins

  • Make GROUP commands work when pg_group.grolist is large enough to be toasted

  • Fix errors in datetime tables; some timezone names weren't being recognized

  • Fix integer overflows in circle_poly(), path_encode(), path_add() (Neil)

  • Repair long-standing logic errors in lseg_eq(), lseg_ne(), lseg_center()


PrevHomeNext
Release 7.2.5UpRelease 7.2.3
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-2-5.html b/doc/src/sgml/html/release-7-2-5.html new file mode 100644 index 000000000..5cbca7a82 --- /dev/null +++ b/doc/src/sgml/html/release-7-2-5.html @@ -0,0 +1,247 @@ + +Release 7.2.5

E.194. Release 7.2.5

Release Date: 2004-08-16

This release contains a variety of fixes from 7.2.4. +

E.194.1. Migration to Version 7.2.5

A dump/restore is not required for those running 7.2.X. +

E.194.2. Changes

  • Prevent possible loss of committed transactions during crash

    Due to insufficient interlocking between transaction commit and checkpointing, +it was possible for transactions committed just before the most recent +checkpoint to be lost, in whole or in part, following a database crash and +restart. This is a serious bug that has existed +since PostgreSQL 7.1.

  • Fix corner case for btree search in parallel with first root page split

  • Fix buffer overrun in to_ascii (Guido Notari)

  • Fix core dump in deadlock detection on machines where char is unsigned

  • Fix failure to respond to pg_ctl stop -m fast after Async_NotifyHandler runs

  • Repair memory leaks in pg_dump

  • Avoid conflict with system definition of isblank() function or macro


PrevHomeNext
Release 7.2.6UpRelease 7.2.4
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-2-6.html b/doc/src/sgml/html/release-7-2-6.html new file mode 100644 index 000000000..da4afae42 --- /dev/null +++ b/doc/src/sgml/html/release-7-2-6.html @@ -0,0 +1,236 @@ + +Release 7.2.6

E.193. Release 7.2.6

Release Date: 2004-10-22

This release contains a variety of fixes from 7.2.5. +

E.193.1. Migration to Version 7.2.6

A dump/restore is not required for those running 7.2.X. +

E.193.2. Changes

  • Repair possible failure to update hint bits on disk

    Under rare circumstances this oversight could lead to +"could not access transaction status" failures, which qualifies +it as a potential-data-loss bug.

  • Ensure that hashed outer join does not miss tuples

    Very large left joins using a hash join plan could fail to output unmatched +left-side rows given just the right data distribution.

  • Disallow running pg_ctl as root

    This is to guard against any possible security issues.

  • Avoid using temp files in /tmp in make_oidjoins_check

    This has been reported as a security issue, though it's hardly worthy of +concern since there is no reason for non-developers to use this script anyway.

  • Update to newer versions of Bison


PrevHomeNext
Release 7.2.7UpRelease 7.2.5
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-2-7.html b/doc/src/sgml/html/release-7-2-7.html new file mode 100644 index 000000000..6462cbc32 --- /dev/null +++ b/doc/src/sgml/html/release-7-2-7.html @@ -0,0 +1,240 @@ + +Release 7.2.7

E.192. Release 7.2.7

Release Date: 2005-01-31

This release contains a variety of fixes from 7.2.6, including several + security-related issues. +

E.192.1. Migration to Version 7.2.7

A dump/restore is not required for those running 7.2.X. +

E.192.2. Changes

  • Disallow LOAD to non-superusers

    On platforms that will automatically execute initialization functions of a +shared library (this includes at least Windows and ELF-based Unixen), +LOAD can be used to make the server execute arbitrary code. +Thanks to NGS Software for reporting this.

  • Add needed STRICT marking to some contrib functions (Kris +Jurka)

  • Avoid buffer overrun when plpgsql cursor declaration has too +many parameters (Neil)

  • Fix planning error for FULL and RIGHT outer joins

    The result of the join was mistakenly supposed to be sorted the same as the +left input. This could not only deliver mis-sorted output to the user, but +in case of nested merge joins could give outright wrong answers.

  • Fix display of negative intervals in SQL and GERMAN +datestyles


PrevHomeNext
Release 7.2.8UpRelease 7.2.6
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-2-8.html b/doc/src/sgml/html/release-7-2-8.html new file mode 100644 index 000000000..1637e2e67 --- /dev/null +++ b/doc/src/sgml/html/release-7-2-8.html @@ -0,0 +1,260 @@ + +Release 7.2.8

E.191. Release 7.2.8

Release Date: 2005-05-09

This release contains a variety of fixes from 7.2.7, including one + security-related issue. +

E.191.1. Migration to Version 7.2.8

A dump/restore is not required for those running 7.2.X. +

E.191.2. Changes

  • Repair ancient race condition that allowed a transaction to be +seen as committed for some purposes (eg SELECT FOR UPDATE) slightly sooner +than for other purposes

    This is an extremely serious bug since it could lead to apparent +data inconsistencies being briefly visible to applications.

  • Repair race condition between relation extension and +VACUUM

    This could theoretically have caused loss of a page's worth of +freshly-inserted data, although the scenario seems of very low probability. +There are no known cases of it having caused more than an Assert failure.

  • Fix EXTRACT(EPOCH) for +TIME WITH TIME ZONE values

  • Additional buffer overrun checks in plpgsql +(Neil)

  • Fix pg_dump to dump index names and trigger names containing +% correctly (Neil)

  • Prevent to_char(interval) from dumping core for +month-related formats

  • Fix contrib/pgcrypto for newer OpenSSL builds +(Marko Kreen)


PrevHomeNext
Release 7.3UpRelease 7.2.7
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-2.html b/doc/src/sgml/html/release-7-2.html new file mode 100644 index 000000000..0b698a90c --- /dev/null +++ b/doc/src/sgml/html/release-7-2.html @@ -0,0 +1,1688 @@ + +Release 7.2

E.199. Release 7.2

Release Date: 2002-02-04

E.199.1. Overview

This release improves PostgreSQL for use in + high-volume applications. +

Major changes in this release: +

VACUUM

Vacuuming no longer locks tables, thus allowing normal user + access during the vacuum. A new VACUUM FULL + command does old-style vacuum by locking the table and + shrinking the on-disk copy of the table. +

Transactions

There is no longer a problem with installations that exceed + four billion transactions. +

OIDs

OIDs are now optional. Users can now create tables without + OIDs for cases where OID usage is excessive. +

Optimizer

The system now computes histogram column statistics during + ANALYZE, allowing much better optimizer choices. +

Security

A new MD5 encryption option allows more secure storage and + transfer of passwords. A new Unix-domain socket + authentication option is available on Linux and BSD systems. +

Statistics

Administrators can use the new table access statistics module + to get fine-grained information about table and index usage. +

Internationalization

Program and library messages can now be displayed in several + languages. +

E.199.2. Migration to Version 7.2

A dump/restore using pg_dump is required for + those wishing to migrate data from any previous release. +

Observe the following incompatibilities: +

  • The semantics of the VACUUM command have + changed in this release. You might wish to update your + maintenance procedures accordingly. +

  • In this release, comparisons using = NULL + will always return false (or NULL, more precisely). Previous + releases automatically transformed this syntax to IS + NULL. The old behavior can be re-enabled using a + postgresql.conf parameter. +

  • The pg_hba.conf and pg_ident.conf + configuration is now only reloaded after receiving a + SIGHUP signal, not with each connection. +

  • The function octet_length() now returns the uncompressed data length. +

  • The date/time value 'current' is no longer + available. You will need to rewrite your applications. +

  • The timestamp(), time(), + and interval() functions are no longer + available. Instead of timestamp(), use + timestamp 'string' or CAST. +

The SELECT ... LIMIT #,# syntax will be removed + in the next release. You should change your queries to use + separate LIMIT and OFFSET clauses, e.g. LIMIT 10 OFFSET + 20. +

E.199.3. Changes

E.199.3.1. Server Operation

  • Create temporary files in a separate directory (Bruce)

  • Delete orphaned temporary files on postmaster startup (Bruce)

  • Added unique indexes to some system tables (Tom)

  • System table operator reorganization (Oleg Bartunov, Teodor Sigaev, Tom)

  • Renamed pg_log to pg_clog (Tom)

  • Enable SIGTERM, SIGQUIT to kill backends (Jan)

  • Removed compile-time limit on number of backends (Tom)

  • Better cleanup for semaphore resource failure (Tatsuo, Tom)

  • Allow safe transaction ID wraparound (Tom)

  • Removed OIDs from some system tables (Tom)

  • Removed "triggered data change violation" error check (Tom)

  • SPI portal creation of prepared/saved plans (Jan)

  • Allow SPI column functions to work for system columns (Tom)

  • Long value compression improvement (Tom)

  • Statistics collector for table, index access (Jan)

  • Truncate extra-long sequence names to a reasonable value (Tom)

  • Measure transaction times in milliseconds (Thomas)

  • Fix TID sequential scans (Hiroshi)

  • Superuser ID now fixed at 1 (Peter E)

  • New pg_ctl "reload" option (Tom)

E.199.3.2. Performance

  • Optimizer improvements (Tom)

  • New histogram column statistics for optimizer (Tom)

  • Reuse write-ahead log files rather than discarding them (Tom)

  • Cache improvements (Tom)

  • IS NULL, IS NOT NULL optimizer improvement (Tom)

  • Improve lock manager to reduce lock contention (Tom)

  • Keep relcache entries for index access support functions (Tom)

  • Allow better selectivity with NaN and infinities in NUMERIC (Tom)

  • R-tree performance improvements (Kenneth Been)

  • B-tree splits more efficient (Tom)

E.199.3.3. Privileges

  • Change UPDATE, DELETE privileges to be distinct (Peter E)

  • New REFERENCES, TRIGGER privileges (Peter E)

  • Allow GRANT/REVOKE to/from more than one user at a time (Peter E)

  • New has_table_privilege() function (Joe Conway)

  • Allow non-superuser to vacuum database (Tom)

  • New SET SESSION AUTHORIZATION command (Peter E)

  • Fix bug in privilege modifications on newly created tables (Tom)

  • Disallow access to pg_statistic for non-superuser, add user-accessible views (Tom)

E.199.3.4. Client Authentication

  • Fork postmaster before doing authentication to prevent hangs (Peter E)

  • Add ident authentication over Unix domain sockets on Linux, *BSD (Helge Bahmann, Oliver Elphick, Teodor Sigaev, Bruce)

  • Add a password authentication method that uses MD5 encryption (Bruce)

  • Allow encryption of stored passwords using MD5 (Bruce)

  • PAM authentication (Dominic J. Eidson)

  • Load pg_hba.conf and pg_ident.conf only on startup and SIGHUP (Bruce)

E.199.3.5. Server Configuration

  • Interpretation of some time zone abbreviations as Australian rather than North American now settable at run time (Bruce)

  • New parameter to set default transaction isolation level (Peter E)

  • New parameter to enable conversion of "expr = NULL" into "expr IS NULL", off by default (Peter E)

  • New parameter to control memory usage by VACUUM (Tom)

  • New parameter to set client authentication timeout (Tom)

  • New parameter to set maximum number of open files (Tom)

E.199.3.6. Queries

  • Statements added by INSERT rules now execute after the INSERT (Jan)

  • Prevent unadorned relation names in target list (Bruce)

  • NULLs now sort after all normal values in ORDER BY (Tom)

  • New IS UNKNOWN, IS NOT UNKNOWN Boolean tests (Tom)

  • New SHARE UPDATE EXCLUSIVE lock mode (Tom)

  • New EXPLAIN ANALYZE command that shows run times and row counts (Martijn van Oosterhout)

  • Fix problem with LIMIT and subqueries (Tom)

  • Fix for LIMIT, DISTINCT ON pushed into subqueries (Tom)

  • Fix nested EXCEPT/INTERSECT (Tom)

E.199.3.7. Schema Manipulation

  • Fix SERIAL in temporary tables (Bruce)

  • Allow temporary sequences (Bruce)

  • Sequences now use int8 internally (Tom)

  • New SERIAL8 creates int8 columns with sequences, default still SERIAL4 (Tom)

  • Make OIDs optional using WITHOUT OIDS (Tom)

  • Add %TYPE syntax to CREATE TYPE (Ian Lance Taylor)

  • Add ALTER TABLE / DROP CONSTRAINT for CHECK constraints (Christopher Kings-Lynne)

  • New CREATE OR REPLACE FUNCTION to alter existing function (preserving the function OID) (Gavin Sherry)

  • Add ALTER TABLE / ADD [ UNIQUE | PRIMARY ] (Christopher Kings-Lynne)

  • Allow column renaming in views

  • Make ALTER TABLE / RENAME COLUMN update column names of indexes (Brent Verner)

  • Fix for ALTER TABLE / ADD CONSTRAINT ... CHECK with inherited tables (Stephan Szabo)

  • ALTER TABLE RENAME update foreign-key trigger arguments correctly (Brent Verner)

  • DROP AGGREGATE and COMMENT ON AGGREGATE now accept an aggtype (Tom)

  • Add automatic return type data casting for SQL functions (Tom)

  • Allow GiST indexes to handle NULLs and multikey indexes (Oleg Bartunov, Teodor Sigaev, Tom)

  • Enable partial indexes (Martijn van Oosterhout)

E.199.3.8. Utility Commands

  • Add RESET ALL, SHOW ALL (Marko Kreen)

  • CREATE/ALTER USER/GROUP now allow options in any order (Vince)

  • Add LOCK A, B, C functionality (Neil Padgett)

  • New ENCRYPTED/UNENCRYPTED option to CREATE/ALTER USER (Bruce)

  • New light-weight VACUUM does not lock table; old semantics are available as VACUUM FULL (Tom)

  • Disable COPY TO/FROM on views (Bruce)

  • COPY DELIMITERS string must be exactly one character (Tom)

  • VACUUM warning about index tuples fewer than heap now only appears when appropriate (Martijn van Oosterhout)

  • Fix privilege checks for CREATE INDEX (Tom)

  • Disallow inappropriate use of CREATE/DROP INDEX/TRIGGER/VIEW (Tom)

E.199.3.9. Data Types and Functions

  • SUM(), AVG(), COUNT() now uses int8 internally for speed (Tom)

  • Add convert(), convert2() (Tatsuo)

  • New function bit_length() (Peter E)

  • Make the "n" in CHAR(n)/VARCHAR(n) represents letters, not bytes (Tatsuo)

  • CHAR(), VARCHAR() now reject strings that are too long (Peter E)

  • BIT VARYING now rejects bit strings that are too long (Peter E)

  • BIT now rejects bit strings that do not match declared size (Peter E)

  • INET, CIDR text conversion functions (Alex Pilosov)

  • INET, CIDR operators << and <<= indexable (Alex Pilosov)

  • Bytea \### now requires valid three digit octal number

  • Bytea comparison improvements, now supports =, <>, >, >=, <, and <=

  • Bytea now supports B-tree indexes

  • Bytea now supports LIKE, LIKE...ESCAPE, NOT LIKE, NOT LIKE...ESCAPE

  • Bytea now supports concatenation

  • New bytea functions: position, substring, trim, btrim, and length

  • New encode() function mode, "escaped", converts minimally escaped bytea to/from text

  • Add pg_database_encoding_max_length() (Tatsuo)

  • Add pg_client_encoding() function (Tatsuo)

  • now() returns time with millisecond precision (Thomas)

  • New TIMESTAMP WITHOUT TIMEZONE data type (Thomas)

  • Add ISO date/time specification with "T", yyyy-mm-ddThh:mm:ss (Thomas)

  • New xid/int comparison functions (Hiroshi)

  • Add precision to TIME, TIMESTAMP, and INTERVAL data types (Thomas)

  • Modify type coercion logic to attempt binary-compatible functions first (Tom)

  • New encode() function installed by default (Marko Kreen)

  • Improved to_*() conversion functions (Karel Zak)

  • Optimize LIKE/ILIKE when using single-byte encodings (Tatsuo)

  • New functions in contrib/pgcrypto: crypt(), hmac(), encrypt(), gen_salt() (Marko Kreen)

  • Correct description of translate() function (Bruce)

  • Add INTERVAL argument for SET TIME ZONE (Thomas)

  • Add INTERVAL YEAR TO MONTH (etc.) syntax (Thomas)

  • Optimize length functions when using single-byte encodings (Tatsuo)

  • Fix path_inter, path_distance, path_length, dist_ppath to handle closed paths (Curtis Barrett, Tom)

  • octet_length(text) now returns non-compressed length (Tatsuo, Bruce)

  • Handle "July" full name in date/time literals (Greg Sabino Mullane)

  • Some datatype() function calls now evaluated differently

  • Add support for Julian and ISO time specifications (Thomas)

E.199.3.10. Internationalization

  • National language support in psql, pg_dump, libpq, and server (Peter E)

  • Message translations in Chinese (simplified, traditional), Czech, French, German, Hungarian, Russian, Swedish (Peter E, Serguei A. Mokhov, Karel Zak, Weiping He, Zhenbang Wei, Kovacs Zoltan)

  • Make trim, ltrim, rtrim, btrim, lpad, rpad, translate multibyte aware (Tatsuo)

  • Add LATIN5,6,7,8,9,10 support (Tatsuo)

  • Add ISO 8859-5,6,7,8 support (Tatsuo)

  • Correct LATIN5 to mean ISO-8859-9, not ISO-8859-5 (Tatsuo)

  • Make mic2ascii() non-ASCII aware (Tatsuo)

  • Reject invalid multibyte character sequences (Tatsuo)

E.199.3.11. PL/pgSQL

  • Now uses portals for SELECT loops, allowing huge result sets (Jan)

  • CURSOR and REFCURSOR support (Jan)

  • Can now return open cursors (Jan)

  • Add ELSEIF (Klaus Reger)

  • Improve PL/pgSQL error reporting, including location of error (Tom)

  • Allow IS or FOR key words in cursor declaration, for compatibility (Bruce)

  • Fix for SELECT ... FOR UPDATE (Tom)

  • Fix for PERFORM returning multiple rows (Tom)

  • Make PL/pgSQL use the server's type coercion code (Tom)

  • Memory leak fix (Jan, Tom)

  • Make trailing semicolon optional (Tom)

E.199.3.12. PL/Perl

  • New untrusted PL/Perl (Alex Pilosov)

  • PL/Perl is now built on some platforms even if libperl is not shared (Peter E)

E.199.3.13. PL/Tcl

  • Now reports errorInfo (Vsevolod Lobko)

  • Add spi_lastoid function (bob@redivi.com)

E.199.3.14. PL/Python

  • ...is new (Andrew Bosma)

E.199.3.15. psql

  • \d displays indexes in unique, primary groupings (Christopher Kings-Lynne)

  • Allow trailing semicolons in backslash commands (Greg Sabino Mullane)

  • Read password from /dev/tty if possible

  • Force new password prompt when changing user and database (Tatsuo, Tom)

  • Format the correct number of columns for Unicode (Patrice)

E.199.3.16. libpq

  • New function PQescapeString() to escape quotes in command strings (Florian Weimer)

  • New function PQescapeBytea() escapes binary strings for use as SQL string literals

E.199.3.17. JDBC

  • Return OID of INSERT (Ken K)

  • Handle more data types (Ken K)

  • Handle single quotes and newlines in strings (Ken K)

  • Handle NULL variables (Ken K)

  • Fix for time zone handling (Barry Lind)

  • Improved Druid support

  • Allow eight-bit characters with non-multibyte server (Barry Lind)

  • Support BIT, BINARY types (Ned Wolpert)

  • Reduce memory usage (Michael Stephens, Dave Cramer)

  • Update DatabaseMetaData (Peter E)

  • Add DatabaseMetaData.getCatalogs() (Peter E)

  • Encoding fixes (Anders Bengtsson)

  • Get/setCatalog methods (Jason Davies)

  • DatabaseMetaData.getColumns() now returns column defaults (Jason Davies)

  • DatabaseMetaData.getColumns() performance improvement (Jeroen van Vianen)

  • Some JDBC1 and JDBC2 merging (Anders Bengtsson)

  • Transaction performance improvements (Barry Lind)

  • Array fixes (Greg Zoller)

  • Serialize addition

  • Fix batch processing (Rene Pijlman)

  • ExecSQL method reorganization (Anders Bengtsson)

  • GetColumn() fixes (Jeroen van Vianen)

  • Fix isWriteable() function (Rene Pijlman)

  • Improved passage of JDBC2 conformance tests (Rene Pijlman)

  • Add bytea type capability (Barry Lind)

  • Add isNullable() (Rene Pijlman)

  • JDBC date/time test suite fixes (Liam Stewart)

  • Fix for SELECT 'id' AS xxx FROM table (Dave Cramer)

  • Fix DatabaseMetaData to show precision properly (Mark Lillywhite)

  • New getImported/getExported keys (Jason Davies)

  • MD5 password encryption support (Jeremy Wohl)

  • Fix to actually use type cache (Ned Wolpert)

E.199.3.18. ODBC

  • Remove query size limit (Hiroshi)

  • Remove text field size limit (Hiroshi)

  • Fix for SQLPrimaryKeys in multibyte mode (Hiroshi)

  • Allow ODBC procedure calls (Hiroshi)

  • Improve boolean handing (Aidan Mountford)

  • Most configuration options now settable via DSN (Hiroshi)

  • Multibyte, performance fixes (Hiroshi)

  • Allow driver to be used with iODBC or unixODBC (Peter E)

  • MD5 password encryption support (Bruce)

  • Add more compatibility functions to odbc.sql (Peter E)

E.199.3.19. ECPG

  • EXECUTE ... INTO implemented (Christof Petig)

  • Multiple row descriptor support (e.g. CARDINALITY) (Christof Petig)

  • Fix for GRANT parameters (Lee Kindness)

  • Fix INITIALLY DEFERRED bug

  • Various bug fixes (Michael, Christof Petig)

  • Auto allocation for indicator variable arrays (int *ind_p=NULL)

  • Auto allocation for string arrays (char **foo_pp=NULL)

  • ECPGfree_auto_mem fixed

  • All function names with external linkage are now prefixed by ECPG

  • Fixes for arrays of structures (Michael)

E.199.3.20. Misc. Interfaces

  • Python fix fetchone() (Gerhard Haring)

  • Use UTF, Unicode in Tcl where appropriate (Vsevolod Lobko, Reinhard Max)

  • Add Tcl COPY TO/FROM (ljb)

  • Prevent output of default index op class in pg_dump (Tom)

  • Fix libpgeasy memory leak (Bruce)

E.199.3.21. Build and Install

  • Configure, dynamic loader, and shared library fixes (Peter E)

  • Fixes in QNX 4 port (Bernd Tegge)

  • Fixes in Cygwin and Windows ports (Jason Tishler, Gerhard Haring, Dmitry Yurtaev, Darko Prenosil, Mikhail Terekhov)

  • Fix for Windows socket communication failures (Magnus, Mikhail Terekhov)

  • Hurd compile fix (Oliver Elphick)

  • BeOS fixes (Cyril Velter)

  • Remove configure --enable-unicode-conversion, now enabled by multibyte (Tatsuo)

  • AIX fixes (Tatsuo, Andreas)

  • Fix parallel make (Peter E)

  • Install SQL language manual pages into OS-specific directories (Peter E)

  • Rename config.h to pg_config.h (Peter E)

  • Reorganize installation layout of header files (Peter E)

E.199.3.22. Source Code

  • Remove SEP_CHAR (Bruce)

  • New GUC hooks (Tom)

  • Merge GUC and command line handling (Marko Kreen)

  • Remove EXTEND INDEX (Martijn van Oosterhout, Tom)

  • New pgjindent utility to indent java code (Bruce)

  • Remove define of true/false when compiling under C++ (Leandro Fanzone, Tom)

  • pgindent fixes (Bruce, Tom)

  • Replace strcasecmp() with strcmp() where appropriate (Peter E)

  • Dynahash portability improvements (Tom)

  • Add 'volatile' usage in spinlock structures

  • Improve signal handling logic (Tom)

E.199.3.23. Contrib

  • New contrib/rtree_gist (Oleg Bartunov, Teodor Sigaev)

  • New contrib/tsearch full-text indexing (Oleg, Teodor Sigaev)

  • Add contrib/dblink for remote database access (Joe Conway)

  • contrib/ora2pg Oracle conversion utility (Gilles Darold)

  • contrib/xml XML conversion utility (John Gray)

  • contrib/fulltextindex fixes (Christopher Kings-Lynne)

  • New contrib/fuzzystrmatch with levenshtein and metaphone, soundex merged (Joe Conway)

  • Add contrib/intarray boolean queries, binary search, fixes (Oleg Bartunov)

  • New pg_upgrade utility (Bruce)

  • Add new pg_resetxlog options (Bruce, Tom)


PrevHomeNext
Release 7.2.1UpRelease 7.1.3
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-3-1.html b/doc/src/sgml/html/release-7-3-1.html new file mode 100644 index 000000000..5d1858723 --- /dev/null +++ b/doc/src/sgml/html/release-7-3-1.html @@ -0,0 +1,281 @@ + +Release 7.3.1

E.189. Release 7.3.1

Release Date: 2002-12-18

This release contains a variety of fixes for version 7.3. +

E.189.1. Migration to Version 7.3.1

A dump/restore is not required for those + running version 7.3. However, it should be noted that the main + PostgreSQL interface library, libpq, + has a new major version number for this release, which might require + recompilation of client code in certain cases. +

E.189.2. Changes

  • Fix a core dump of COPY TO when client/server encodings don't match (Tom)

  • Allow pg_dump to work with pre-7.2 servers (Philip)

  • contrib/adddepend fixes (Tom)

  • Fix problem with deletion of per-user/per-database config settings (Tom)

  • contrib/vacuumlo fix (Tom)

  • Allow 'password' encryption even when pg_shadow contains MD5 passwords (Bruce)

  • contrib/dbmirror fix (Steven Singer)

  • Optimizer fixes (Tom)

  • contrib/tsearch fixes (Teodor Sigaev, Magnus)

  • Allow locale names to be mixed case (Nicolai Tufar)

  • Increment libpq library's major version number (Bruce)

  • pg_hba.conf error reporting fixes (Bruce, Neil)

  • Add SCO Openserver 5.0.4 as a supported platform (Bruce)

  • Prevent EXPLAIN from crashing server (Tom)

  • SSL fixes (Nathan Mueller)

  • Prevent composite column creation via ALTER TABLE (Tom)


PrevHomeNext
Release 7.3.2UpRelease 7.3
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-3-10.html b/doc/src/sgml/html/release-7-3-10.html new file mode 100644 index 000000000..d0d5dfc6f --- /dev/null +++ b/doc/src/sgml/html/release-7-3-10.html @@ -0,0 +1,393 @@ + +Release 7.3.10

E.180. Release 7.3.10

Release Date: 2005-05-09

This release contains a variety of fixes from 7.3.9, including several + security-related issues. +

E.180.1. Migration to Version 7.3.10

A dump/restore is not required for those running 7.3.X. However, + it is one possible way of handling a significant security problem + that has been found in the initial contents of 7.3.X system + catalogs. A dump/initdb/reload sequence using 7.3.10's initdb will + automatically correct this problem. +

The security problem is that the built-in character set encoding + conversion functions can be invoked from SQL commands by unprivileged + users, but the functions were not designed for such use and are not + secure against malicious choices of arguments. The fix involves changing + the declared parameter list of these functions so that they can no longer + be invoked from SQL commands. (This does not affect their normal use + by the encoding conversion machinery.) + It is strongly recommended that all installations repair this error, + either by initdb or by following the manual repair procedure given + below. The error at least allows unprivileged database users to crash + their server process, and might allow unprivileged users to gain the + privileges of a database superuser. +

If you wish not to do an initdb, perform the following procedure instead. + As the database superuser, do: + +

BEGIN;
+UPDATE pg_proc SET proargtypes[3] = 'internal'::regtype
+WHERE pronamespace = 11 AND pronargs = 5
+     AND proargtypes[2] = 'cstring'::regtype;
+-- The command should report having updated 90 rows;
+-- if not, rollback and investigate instead of committing!
+COMMIT;

+

The above procedure must be carried out in each database + of an installation, including template1, and ideally + including template0 as well. If you do not fix the + template databases then any subsequently created databases will contain + the same error. template1 can be fixed in the same way + as any other database, but fixing template0 requires + additional steps. First, from any database issue: +

UPDATE pg_database SET datallowconn = true WHERE datname = 'template0';

+ Next connect to template0 and perform the above repair + procedure. Finally, do: +

-- re-freeze template0:
+VACUUM FREEZE;
+-- and protect it against future alterations:
+UPDATE pg_database SET datallowconn = false WHERE datname = 'template0';

+

E.180.2. Changes

  • Change encoding function signature to prevent +misuse

  • Repair ancient race condition that allowed a transaction to be +seen as committed for some purposes (eg SELECT FOR UPDATE) slightly sooner +than for other purposes

    This is an extremely serious bug since it could lead to apparent +data inconsistencies being briefly visible to applications.

  • Repair race condition between relation extension and +VACUUM

    This could theoretically have caused loss of a page's worth of +freshly-inserted data, although the scenario seems of very low probability. +There are no known cases of it having caused more than an Assert failure.

  • Fix comparisons of TIME WITH TIME ZONE values

    The comparison code was wrong in the case where the +--enable-integer-datetimes configuration switch had been used. +NOTE: if you have an index on a TIME WITH TIME ZONE column, +it will need to be REINDEXed after installing this update, because +the fix corrects the sort order of column values.

  • Fix EXTRACT(EPOCH) for +TIME WITH TIME ZONE values

  • Fix mis-display of negative fractional seconds in +INTERVAL values

    This error only occurred when the +--enable-integer-datetimes configuration switch had been used.

  • Additional buffer overrun checks in plpgsql +(Neil)

  • Fix pg_dump to dump trigger names containing % +correctly (Neil)

  • Prevent to_char(interval) from dumping core for +month-related formats

  • Fix contrib/pgcrypto for newer OpenSSL builds +(Marko Kreen)

  • Still more 64-bit fixes for +contrib/intagg

  • Prevent incorrect optimization of functions returning +RECORD


PrevHomeNext
Release 7.3.11UpRelease 7.3.9
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-3-11.html b/doc/src/sgml/html/release-7-3-11.html new file mode 100644 index 000000000..d9f92125c --- /dev/null +++ b/doc/src/sgml/html/release-7-3-11.html @@ -0,0 +1,273 @@ + +Release 7.3.11

E.179. Release 7.3.11

Release Date: 2005-10-04

This release contains a variety of fixes from 7.3.10. +

E.179.1. Migration to Version 7.3.11

A dump/restore is not required for those running 7.3.X. However, + if you are upgrading from a version earlier than 7.3.10, see the release + notes for 7.3.10. +

E.179.2. Changes

  • Fix error that allowed VACUUM to remove +ctid chains too soon, and add more checking in code that follows +ctid links

    This fixes a long-standing problem that could cause crashes in very rare +circumstances.

  • Fix CHAR() to properly pad spaces to the specified +length when using a multiple-byte character set (Yoshiyuki Asaba)

    In prior releases, the padding of CHAR() was incorrect +because it only padded to the specified number of bytes without +considering how many characters were stored.

  • Fix missing rows in queries like UPDATE a=... WHERE +a... with GiST index on column a

  • Improve checking for partially-written WAL +pages

  • Improve robustness of signal handling when SSL is +enabled

  • Various memory leakage fixes

  • Various portability improvements

  • Fix PL/pgSQL to handle var := var correctly when +the variable is of pass-by-reference type


PrevHomeNext
Release 7.3.12UpRelease 7.3.10
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-3-12.html b/doc/src/sgml/html/release-7-3-12.html new file mode 100644 index 000000000..0f1df7efb --- /dev/null +++ b/doc/src/sgml/html/release-7-3-12.html @@ -0,0 +1,236 @@ + +Release 7.3.12

E.178. Release 7.3.12

Release Date: 2005-12-12

This release contains a variety of fixes from 7.3.11. +

E.178.1. Migration to Version 7.3.12

A dump/restore is not required for those running 7.3.X. However, + if you are upgrading from a version earlier than 7.3.10, see the release + notes for 7.3.10. +

E.178.2. Changes

  • Fix race condition in transaction log management

    There was a narrow window in which an I/O operation could be initiated +for the wrong page, leading to an Assert failure or data +corruption.

  • /contrib/ltree fixes (Teodor)

  • Fix longstanding planning error for outer joins

    This bug sometimes caused a bogus error "RIGHT JOIN is +only supported with merge-joinable join conditions".

  • Prevent core dump in pg_autovacuum when a +table has been dropped


PrevHomeNext
Release 7.3.13UpRelease 7.3.11
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-3-13.html b/doc/src/sgml/html/release-7-3-13.html new file mode 100644 index 000000000..ab5e2d79b --- /dev/null +++ b/doc/src/sgml/html/release-7-3-13.html @@ -0,0 +1,275 @@ + +Release 7.3.13

E.177. Release 7.3.13

Release Date: 2006-01-09

This release contains a variety of fixes from 7.3.12. +

E.177.1. Migration to Version 7.3.13

A dump/restore is not required for those running 7.3.X. However, + if you are upgrading from a version earlier than 7.3.10, see the release + notes for 7.3.10. + Also, you might need to REINDEX indexes on textual + columns after updating, if you are affected by the locale or + plperl issues described below. +

E.177.2. Changes

  • Fix character string comparison for locales that consider +different character combinations as equal, such as Hungarian (Tom)

    This might require REINDEX to fix existing indexes on +textual columns.

  • Set locale environment variables during postmaster startup +to ensure that plperl won't change the locale later

    This fixes a problem that occurred if the postmaster was +started with environment variables specifying a different locale than what +initdb had been told. Under these conditions, any use of +plperl was likely to lead to corrupt indexes. You might need +REINDEX to fix existing indexes on +textual columns if this has happened to you.

  • Fix longstanding bug in strpos() and regular expression +handling in certain rarely used Asian multi-byte character sets (Tatsuo)

  • Fix bug in /contrib/pgcrypto gen_salt, +which caused it not to use all available salt space for MD5 and +XDES algorithms (Marko Kreen, Solar Designer)

    Salts for Blowfish and standard DES are unaffected.

  • Fix /contrib/dblink to throw an error, +rather than crashing, when the number of columns specified is different from +what's actually returned by the query (Joe)


PrevHomeNext
Release 7.3.14UpRelease 7.3.12
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-3-14.html b/doc/src/sgml/html/release-7-3-14.html new file mode 100644 index 000000000..b22af7705 --- /dev/null +++ b/doc/src/sgml/html/release-7-3-14.html @@ -0,0 +1,250 @@ + +Release 7.3.14

E.176. Release 7.3.14

Release Date: 2006-02-14

This release contains a variety of fixes from 7.3.13. +

E.176.1. Migration to Version 7.3.14

A dump/restore is not required for those running 7.3.X. However, + if you are upgrading from a version earlier than 7.3.13, see the release + notes for 7.3.13. +

E.176.2. Changes

  • Fix potential crash in SET +SESSION AUTHORIZATION (CVE-2006-0553)

    An unprivileged user could crash the server process, resulting in +momentary denial of service to other users, if the server has been compiled +with Asserts enabled (which is not the default). +Thanks to Akio Ishida for reporting this problem.

  • Fix bug with row visibility logic in self-inserted +rows (Tom)

    Under rare circumstances a row inserted by the current command +could be seen as already valid, when it should not be. Repairs bug +created in 7.3.11 release.

  • Fix race condition that could lead to "file already +exists" errors during pg_clog file creation +(Tom)

  • Fix to allow restoring dumps that have cross-schema +references to custom operators (Tom)

  • Portability fix for testing presence of finite +and isinf during configure (Tom)


PrevHomeNext
Release 7.3.15UpRelease 7.3.13
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-3-15.html b/doc/src/sgml/html/release-7-3-15.html new file mode 100644 index 000000000..eb067f5a3 --- /dev/null +++ b/doc/src/sgml/html/release-7-3-15.html @@ -0,0 +1,347 @@ + +Release 7.3.15

E.175. Release 7.3.15

Release Date: 2006-05-23

This release contains a variety of fixes from 7.3.14, + including patches for extremely serious security issues. +

E.175.1. Migration to Version 7.3.15

A dump/restore is not required for those running 7.3.X. However, + if you are upgrading from a version earlier than 7.3.13, see the release + notes for 7.3.13. +

Full security against the SQL-injection attacks described in + CVE-2006-2313 and CVE-2006-2314 might require changes in application + code. If you have applications that embed untrustworthy strings + into SQL commands, you should examine them as soon as possible to + ensure that they are using recommended escaping techniques. In + most cases, applications should be using subroutines provided by + libraries or drivers (such as libpq's + PQescapeStringConn()) to perform string escaping, + rather than relying on ad hoc code to do it. +

E.175.2. Changes

  • Change the server to reject invalidly-encoded multibyte +characters in all cases (Tatsuo, Tom)

    While PostgreSQL has been moving in this direction for +some time, the checks are now applied uniformly to all encodings and all +textual input, and are now always errors not merely warnings. This change +defends against SQL-injection attacks of the type described in CVE-2006-2313.

  • Reject unsafe uses of \' in string literals

    As a server-side defense against SQL-injection attacks of the type +described in CVE-2006-2314, the server now only accepts '' and not +\' as a representation of ASCII single quote in SQL string +literals. By default, \' is rejected only when +client_encoding is set to a client-only encoding (SJIS, BIG5, GBK, +GB18030, or UHC), which is the scenario in which SQL injection is possible. +A new configuration parameter backslash_quote is available to +adjust this behavior when needed. Note that full security against +CVE-2006-2314 might require client-side changes; the purpose of +backslash_quote is in part to make it obvious that insecure +clients are insecure.

  • Modify libpq's string-escaping routines to be +aware of encoding considerations

    This fixes libpq-using applications for the security +issues described in CVE-2006-2313 and CVE-2006-2314. +Applications that use multiple PostgreSQL connections +concurrently should migrate to PQescapeStringConn() and +PQescapeByteaConn() to ensure that escaping is done correctly +for the settings in use in each database connection. Applications that +do string escaping "by hand" should be modified to rely on library +routines instead.

  • Fix some incorrect encoding conversion functions

    win1251_to_iso, alt_to_iso, +euc_tw_to_big5, euc_tw_to_mic, +mic_to_euc_tw were all broken to varying +extents.

  • Clean up stray remaining uses of \' in strings +(Bruce, Jan)

  • Fix server to use custom DH SSL parameters correctly (Michael +Fuhr)

  • Fix various minor memory leaks


PrevHomeNext
Release 7.3.16UpRelease 7.3.14
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-3-16.html b/doc/src/sgml/html/release-7-3-16.html new file mode 100644 index 000000000..9c0a1b555 --- /dev/null +++ b/doc/src/sgml/html/release-7-3-16.html @@ -0,0 +1,236 @@ + +Release 7.3.16

E.174. Release 7.3.16

Release Date: 2006-10-16

This release contains a variety of fixes from 7.3.15. +

E.174.1. Migration to Version 7.3.16

A dump/restore is not required for those running 7.3.X. However, + if you are upgrading from a version earlier than 7.3.13, see the release + notes for 7.3.13. +

E.174.2. Changes

  • Fix corner cases in pattern matching for + psql's \d commands

  • Fix index-corrupting bugs in /contrib/ltree + (Teodor)

  • Back-port 7.4 spinlock code to improve performance and support +64-bit architectures better

  • Fix SSL-related memory leak in libpq

  • Fix backslash escaping in /contrib/dbmirror

  • Adjust regression tests for recent changes in US DST laws


PrevHomeNext
Release 7.3.17UpRelease 7.3.15
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-3-17.html b/doc/src/sgml/html/release-7-3-17.html new file mode 100644 index 000000000..ecbe82b21 --- /dev/null +++ b/doc/src/sgml/html/release-7-3-17.html @@ -0,0 +1,246 @@ + +Release 7.3.17

E.173. Release 7.3.17

Release Date: 2007-01-08

This release contains a variety of fixes from 7.3.16. +

E.173.1. Migration to Version 7.3.17

A dump/restore is not required for those running 7.3.X. However, + if you are upgrading from a version earlier than 7.3.13, see the release + notes for 7.3.13. +

E.173.2. Changes

  • to_number() and to_char(numeric) + are now STABLE, not IMMUTABLE, for + new initdb installs (Tom) +

    This is because lc_numeric can potentially + change the output of these functions. +

  • Improve index usage of regular expressions that use parentheses (Tom) +

    This improves psql \d performance also. +


PrevHomeNext
Release 7.3.18UpRelease 7.3.16
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-3-18.html b/doc/src/sgml/html/release-7-3-18.html new file mode 100644 index 000000000..21f8e2f07 --- /dev/null +++ b/doc/src/sgml/html/release-7-3-18.html @@ -0,0 +1,229 @@ + +Release 7.3.18

E.172. Release 7.3.18

Release Date: 2007-02-05

This release contains a variety of fixes from 7.3.17, including + a security fix. +

E.172.1. Migration to Version 7.3.18

A dump/restore is not required for those running 7.3.X. However, + if you are upgrading from a version earlier than 7.3.13, see the release + notes for 7.3.13. +

E.172.2. Changes

  • Remove security vulnerability that allowed connected users + to read backend memory (Tom) +

    The vulnerability involves changing the + data type of a table column used in a SQL function (CVE-2007-0555). + This error can easily be exploited to cause a backend crash, and in + principle might be used to read database content that the user + should not be able to access. +

  • Fix rare bug wherein btree index page splits could fail + due to choosing an infeasible split point (Heikki Linnakangas) +

  • Tighten security of multi-byte character processing for UTF8 sequences + over three bytes long (Tom) +


PrevHomeNext
Release 7.3.19UpRelease 7.3.17
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-3-19.html b/doc/src/sgml/html/release-7-3-19.html new file mode 100644 index 000000000..693d29eec --- /dev/null +++ b/doc/src/sgml/html/release-7-3-19.html @@ -0,0 +1,239 @@ + +Release 7.3.19

E.171. Release 7.3.19

Release Date: 2007-04-23

This release contains fixes from 7.3.18, + including a security fix. +

E.171.1. Migration to Version 7.3.19

A dump/restore is not required for those running 7.3.X. However, + if you are upgrading from a version earlier than 7.3.13, see the release + notes for 7.3.13. +

E.171.2. Changes

  • Support explicit placement of the temporary-table schema within + search_path, and disable searching it for functions + and operators (Tom) +

    This is needed to allow a security-definer function to set a + truly secure value of search_path. Without it, + an unprivileged SQL user can use temporary objects to execute code + with the privileges of the security-definer function (CVE-2007-2138). + See CREATE FUNCTION for more information. +

  • Fix potential-data-corruption bug in how VACUUM FULL handles + UPDATE chains (Tom, Pavan Deolasee) +


PrevHomeNext
Release 7.3.20UpRelease 7.3.18
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-3-2.html b/doc/src/sgml/html/release-7-3-2.html new file mode 100644 index 000000000..11b681baa --- /dev/null +++ b/doc/src/sgml/html/release-7-3-2.html @@ -0,0 +1,334 @@ + +Release 7.3.2

E.188. Release 7.3.2

Release Date: 2003-02-04

This release contains a variety of fixes for version 7.3.1. +

E.188.1. Migration to Version 7.3.2

A dump/restore is not required for those + running version 7.3.*. +

E.188.2. Changes

  • Restore creation of OID column in CREATE TABLE AS / SELECT INTO

  • Fix pg_dump core dump when dumping views having comments

  • Dump DEFERRABLE/INITIALLY DEFERRED constraints properly

  • Fix UPDATE when child table's column numbering differs from parent

  • Increase default value of max_fsm_relations

  • Fix problem when fetching backwards in a cursor for a single-row query

  • Make backward fetch work properly with cursor on SELECT DISTINCT query

  • Fix problems with loading pg_dump files containing contrib/lo usage

  • Fix problem with all-numeric user names

  • Fix possible memory leak and core dump during disconnect in libpgtcl

  • Make plpython's spi_execute command handle nulls properly (Andrew Bosma)

  • Adjust plpython error reporting so that its regression test passes again

  • Work with bison 1.875

  • Handle mixed-case names properly in plpgsql's %type (Neil)

  • Fix core dump in pltcl when executing a query rewritten by a rule

  • Repair array subscript overruns (per report from Yichen Xie)

  • Reduce MAX_TIME_PRECISION from 13 to 10 in floating-point case

  • Correctly case-fold variable names in per-database and per-user settings

  • Fix coredump in plpgsql's RETURN NEXT when SELECT into record returns no rows

  • Fix outdated use of pg_type.typprtlen in python client interface

  • Correctly handle fractional seconds in timestamps in JDBC driver

  • Improve performance of getImportedKeys() in JDBC

  • Make shared-library symlinks work standardly on HPUX (Giles)

  • Repair inconsistent rounding behavior for timestamp, time, interval

  • SSL negotiation fixes (Nathan Mueller)

  • Make libpq's ~/.pgpass feature work when connecting with PQconnectDB

  • Update my2pg, ora2pg

  • Translation updates

  • Add casts between types lo and oid in contrib/lo

  • fastpath code now checks for privilege to call function


PrevHomeNext
Release 7.3.3UpRelease 7.3.1
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-3-20.html b/doc/src/sgml/html/release-7-3-20.html new file mode 100644 index 000000000..4f8a389c0 --- /dev/null +++ b/doc/src/sgml/html/release-7-3-20.html @@ -0,0 +1,239 @@ + +Release 7.3.20

E.170. Release 7.3.20

Release Date: 2007-09-17

This release contains fixes from 7.3.19. +

E.170.1. Migration to Version 7.3.20

A dump/restore is not required for those running 7.3.X. However, + if you are upgrading from a version earlier than 7.3.13, see the release + notes for 7.3.13. +

E.170.2. Changes

  • Prevent index corruption when a transaction inserts rows and + then aborts close to the end of a concurrent VACUUM + on the same table (Tom) +

  • Make CREATE DOMAIN ... DEFAULT NULL work properly (Tom) +

  • Fix crash when log_min_error_statement logging runs out + of memory (Tom) +

  • Require non-superusers who use /contrib/dblink to use only + password authentication, as a security measure (Joe) +


PrevHomeNext
Release 7.3.21UpRelease 7.3.19
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-3-21.html b/doc/src/sgml/html/release-7-3-21.html new file mode 100644 index 000000000..994d49b4b --- /dev/null +++ b/doc/src/sgml/html/release-7-3-21.html @@ -0,0 +1,339 @@ + +Release 7.3.21

E.169. Release 7.3.21

Release Date: 2008-01-07

This release contains a variety of fixes from 7.3.20, + including fixes for significant security issues. +

This is expected to be the last PostgreSQL release + in the 7.3.X series. Users are encouraged to update to a newer + release branch soon. +

E.169.1. Migration to Version 7.3.21

A dump/restore is not required for those running 7.3.X. However, + if you are upgrading from a version earlier than 7.3.13, see the release + notes for 7.3.13. +

E.169.2. Changes

  • Prevent functions in indexes from executing with the privileges of + the user running VACUUM, ANALYZE, etc (Tom) +

    Functions used in index expressions and partial-index + predicates are evaluated whenever a new table entry is made. It has + long been understood that this poses a risk of trojan-horse code + execution if one modifies a table owned by an untrustworthy user. + (Note that triggers, defaults, check constraints, etc. pose the + same type of risk.) But functions in indexes pose extra danger + because they will be executed by routine maintenance operations + such as VACUUM FULL, which are commonly performed + automatically under a superuser account. For example, a nefarious user + can execute code with superuser privileges by setting up a + trojan-horse index definition and waiting for the next routine vacuum. + The fix arranges for standard maintenance operations + (including VACUUM, ANALYZE, REINDEX, + and CLUSTER) to execute as the table owner rather than + the calling user, using the same privilege-switching mechanism already + used for SECURITY DEFINER functions. To prevent bypassing + this security measure, execution of SET SESSION + AUTHORIZATION and SET ROLE is now forbidden within a + SECURITY DEFINER context. (CVE-2007-6600) +

  • Require non-superusers who use /contrib/dblink to use only + password authentication, as a security measure (Joe) +

    The fix that appeared for this in 7.3.20 was incomplete, as it plugged + the hole for only some dblink functions. (CVE-2007-6601, + CVE-2007-3278) +

  • Fix potential crash in translate() when using a multibyte + database encoding (Tom) +

  • Make contrib/tablefunc's crosstab() handle + NULL rowid as a category in its own right, rather than crashing (Joe) +

  • Require a specific version of Autoconf to be used + when re-generating the configure script (Peter) +

    This affects developers and packagers only. The change was made + to prevent accidental use of untested combinations of + Autoconf and PostgreSQL versions. + You can remove the version check if you really want to use a + different Autoconf version, but it's + your responsibility whether the result works or not. +


PrevHomeNext
Release 7.4UpRelease 7.3.20
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-3-3.html b/doc/src/sgml/html/release-7-3-3.html new file mode 100644 index 000000000..94be8f65c --- /dev/null +++ b/doc/src/sgml/html/release-7-3-3.html @@ -0,0 +1,648 @@ + +Release 7.3.3

E.187. Release 7.3.3

Release Date: 2003-05-22

This release contains a variety of fixes for version 7.3.2. +

E.187.1. Migration to Version 7.3.3

A dump/restore is not required for those + running version 7.3.*. +

E.187.2. Changes

  • Repair sometimes-incorrect computation of StartUpID after a crash

  • Avoid slowness with lots of deferred triggers in one transaction (Stephan)

  • Don't lock referenced row when UPDATE doesn't change foreign key's value (Jan)

  • Use -fPIC not -fpic on Sparc (Tom Callaway)

  • Repair lack of schema-awareness in contrib/reindexdb

  • Fix contrib/intarray error for zero-element result array (Teodor)

  • Ensure createuser script will exit on control-C (Oliver)

  • Fix errors when the type of a dropped column has itself been dropped

  • CHECKPOINT does not cause database panic on failure in noncritical steps

  • Accept 60 in seconds fields of timestamp, time, interval input values

  • Issue notice, not error, if TIMESTAMP, + TIME, or INTERVAL precision too large

  • Fix abstime-to-time cast function (fix is + not applied unless you initdb)

  • Fix pg_proc entry for + timestampt_izone (fix is not applied unless you + initdb)

  • Make EXTRACT(EPOCH FROM timestamp without time zone) treat input as local time

  • 'now'::timestamptz gave wrong answer if timezone changed earlier in transaction

  • HAVE_INT64_TIMESTAMP code for time with timezone overwrote its input

  • Accept GLOBAL TEMP/TEMPORARY as a + synonym for TEMPORARY

  • Avoid improper schema-privilege-check failure in foreign-key triggers

  • Fix bugs in foreign-key triggers for SET DEFAULT action

  • Fix incorrect time-qual check in row fetch for + UPDATE and DELETE triggers

  • Foreign-key clauses were parsed but ignored in + ALTER TABLE ADD COLUMN

  • Fix createlang script breakage for case where handler function already exists

  • Fix misbehavior on zero-column tables in pg_dump, COPY, ANALYZE, other places

  • Fix misbehavior of func_error() on type names containing '%'

  • Fix misbehavior of replace() on strings containing '%'

  • Regular-expression patterns containing certain multibyte characters failed

  • Account correctly for NULLs in more cases in join size estimation

  • Avoid conflict with system definition of isblank() function or macro

  • Fix failure to convert large code point values in EUC_TW conversions (Tatsuo)

  • Fix error recovery for SSL_read/SSL_write calls

  • Don't do early constant-folding of type coercion expressions

  • Validate page header fields immediately after reading in any page

  • Repair incorrect check for ungrouped variables in unnamed joins

  • Fix buffer overrun in to_ascii (Guido Notari)

  • contrib/ltree fixes (Teodor)

  • Fix core dump in deadlock detection on machines where char is unsigned

  • Avoid running out of buffers in many-way indexscan (bug introduced in 7.3)

  • Fix planner's selectivity estimation functions to handle domains properly

  • Fix dbmirror memory-allocation bug (Steven Singer)

  • Prevent infinite loop in ln(numeric) due to roundoff error

  • GROUP BY got confused if there were multiple equal GROUP BY items

  • Fix bad plan when inherited UPDATE/DELETE references another inherited table

  • Prevent clustering on incomplete (partial or non-NULL-storing) indexes

  • Service shutdown request at proper time if it arrives while still starting up

  • Fix left-links in temporary indexes (could make backwards scans miss entries)

  • Fix incorrect handling of client_encoding setting in postgresql.conf (Tatsuo)

  • Fix failure to respond to pg_ctl stop -m fast after Async_NotifyHandler runs

  • Fix SPI for case where rule contains multiple statements of the same type

  • Fix problem with checking for wrong type of access privilege in rule query

  • Fix problem with EXCEPT in CREATE RULE

  • Prevent problem with dropping temp tables having serial columns

  • Fix replace_vars_with_subplan_refs failure in complex views

  • Fix regexp slowness in single-byte encodings (Tatsuo)

  • Allow qualified type names in CREATE CAST + and DROP CAST

  • Accept SETOF type[], which formerly had to + be written SETOF _type

  • Fix pg_dump core dump in some cases with procedural languages

  • Force ISO datestyle in pg_dump output, for portability (Oliver)

  • pg_dump failed to handle error return + from lo_read (Oleg Drokin)

  • pg_dumpall failed with groups having no members (Nick Eskelinen)

  • pg_dumpall failed to recognize --globals-only switch

  • pg_restore failed to restore blobs if -X disable-triggers is specified

  • Repair intrafunction memory leak in plpgsql

  • pltcl's elog command dumped core if given wrong parameters (Ian Harding)

  • plpython used wrong value of atttypmod (Brad McLean)

  • Fix improper quoting of boolean values in Python interface (D'Arcy)

  • Added addDataType() method to PGConnection interface for JDBC

  • Fixed various problems with updateable ResultSets for JDBC (Shawn Green)

  • Fixed various problems with DatabaseMetaData for JDBC (Kris Jurka, Peter Royal)

  • Fixed problem with parsing table ACLs in JDBC

  • Better error message for character set conversion problems in JDBC


PrevHomeNext
Release 7.3.4UpRelease 7.3.2
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-3-4.html b/doc/src/sgml/html/release-7-3-4.html new file mode 100644 index 000000000..c8a3f7d26 --- /dev/null +++ b/doc/src/sgml/html/release-7-3-4.html @@ -0,0 +1,244 @@ + +Release 7.3.4

E.186. Release 7.3.4

Release Date: 2003-07-24

This has a variety of fixes from 7.3.3. +

E.186.1. Migration to Version 7.3.4

A dump/restore is not required for those + running 7.3.*. +

E.186.2. Changes

  • Repair breakage in timestamp-to-date conversion for dates before 2000

  • Prevent rare possibility of server startup failure (Tom)

  • Fix bugs in interval-to-time conversion (Tom)

  • Add constraint names in a few places in pg_dump (Rod)

  • Improve performance of functions with many parameters (Tom)

  • Fix to_ascii() buffer overruns (Tom)

  • Prevent restore of database comments from throwing an error (Tom)

  • Work around buggy strxfrm() present in some Solaris releases (Tom)

  • Properly escape jdbc setObject() strings to improve security (Barry)


PrevHomeNext
Release 7.3.5UpRelease 7.3.3
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-3-5.html b/doc/src/sgml/html/release-7-3-5.html new file mode 100644 index 000000000..83437f164 --- /dev/null +++ b/doc/src/sgml/html/release-7-3-5.html @@ -0,0 +1,288 @@ + +Release 7.3.5

E.185. Release 7.3.5

Release Date: 2003-12-03

This has a variety of fixes from 7.3.4. +

E.185.1. Migration to Version 7.3.5

A dump/restore is not required for those + running 7.3.*. +

E.185.2. Changes

  • Force zero_damaged_pages to be on during recovery from WAL

  • Prevent some obscure cases of "variable not in subplan target lists"

  • Force stats processes to detach from shared memory, ensuring cleaner shutdown

  • Make PQescapeBytea and byteaout consistent with each other (Joe)

  • Added missing SPI_finish() calls to dblink's get_tuple_of_interest() (Joe)

  • Fix for possible foreign key violation when rule rewrites INSERT (Jan)

  • Support qualified type names in PL/Tcl's spi_prepare command (Jan)

  • Make pg_dump handle a procedural language handler located in pg_catalog

  • Make pg_dump handle cases where a custom opclass is in another schema

  • Make pg_dump dump binary-compatible casts correctly (Jan)

  • Fix insertion of expressions containing subqueries into rule bodies

  • Fix incorrect argument processing in clusterdb script (Anand Ranganathan)

  • Fix problems with dropped columns in plpython triggers

  • Repair problems with to_char() reading past end of its input string (Karel)

  • Fix GB18030 mapping errors (Tatsuo)

  • Fix several problems with SSL error handling and asynchronous SSL I/O

  • Remove ability to bind a list of values to a single parameter in JDBC +(prevents possible SQL-injection attacks)

  • Fix some errors in HAVE_INT64_TIMESTAMP code paths

  • Fix corner case for btree search in parallel with first root page split


PrevHomeNext
Release 7.3.6UpRelease 7.3.4
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-3-6.html b/doc/src/sgml/html/release-7-3-6.html new file mode 100644 index 000000000..37cec1398 --- /dev/null +++ b/doc/src/sgml/html/release-7-3-6.html @@ -0,0 +1,268 @@ + +Release 7.3.6

E.184. Release 7.3.6

Release Date: 2004-03-02

This release contains a variety of fixes from 7.3.5. +

E.184.1. Migration to Version 7.3.6

A dump/restore is not required for those + running 7.3.*. +

E.184.2. Changes

  • Revert erroneous changes in rule permissions checking

    A patch applied in 7.3.3 to fix a corner case in rule permissions checks +turns out to have disabled rule-related permissions checks in many +not-so-corner cases. This would for example allow users to insert into views +they weren't supposed to have permission to insert into. We have therefore +reverted the 7.3.3 patch. The original bug will be fixed in 8.0.

  • Repair incorrect order of operations in +GetNewTransactionId()

    This bug could result in failure under out-of-disk-space conditions, including +inability to restart even after disk space is freed.

  • Ensure configure selects -fno-strict-aliasing even when +an external value for CFLAGS is supplied

    On some platforms, building with -fstrict-aliasing causes bugs.

  • Make pg_restore handle 64-bit off_t correctly

    This bug prevented proper restoration from archive files exceeding 4 GB.

  • Make contrib/dblink not assume that local and remote type OIDs +match (Joe)

  • Quote connectby()'s start_with argument properly (Joe)

  • Don't crash when a rowtype argument to a plpgsql function is +NULL

  • Avoid generating invalid character encoding sequences in +corner cases when planning LIKE operations

  • Ensure text_position() cannot scan past end of source string +in multibyte cases (Korea PostgreSQL Users' Group)

  • Fix index optimization and selectivity estimates for LIKE +operations on bytea columns (Joe)


PrevHomeNext
Release 7.3.7UpRelease 7.3.5
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-3-7.html b/doc/src/sgml/html/release-7-3-7.html new file mode 100644 index 000000000..da06b1d38 --- /dev/null +++ b/doc/src/sgml/html/release-7-3-7.html @@ -0,0 +1,222 @@ + +Release 7.3.7

E.183. Release 7.3.7

Release Date: 2004-08-16

This release contains one critical fix over 7.3.6, and some minor items. +

E.183.1. Migration to Version 7.3.7

A dump/restore is not required for those running 7.3.X. +

E.183.2. Changes

  • Prevent possible loss of committed transactions during crash

    Due to insufficient interlocking between transaction commit and checkpointing, +it was possible for transactions committed just before the most recent +checkpoint to be lost, in whole or in part, following a database crash and +restart. This is a serious bug that has existed +since PostgreSQL 7.1.

  • Remove asymmetrical word processing in tsearch (Teodor)

  • Properly schema-qualify function names when pg_dump'ing a CAST


PrevHomeNext
Release 7.3.8UpRelease 7.3.6
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-3-8.html b/doc/src/sgml/html/release-7-3-8.html new file mode 100644 index 000000000..d4447af8a --- /dev/null +++ b/doc/src/sgml/html/release-7-3-8.html @@ -0,0 +1,232 @@ + +Release 7.3.8

E.182. Release 7.3.8

Release Date: 2004-10-22

This release contains a variety of fixes from 7.3.7. +

E.182.1. Migration to Version 7.3.8

A dump/restore is not required for those running 7.3.X. +

E.182.2. Changes

  • Repair possible failure to update hint bits on disk

    Under rare circumstances this oversight could lead to +"could not access transaction status" failures, which qualifies +it as a potential-data-loss bug.

  • Ensure that hashed outer join does not miss tuples

    Very large left joins using a hash join plan could fail to output unmatched +left-side rows given just the right data distribution.

  • Disallow running pg_ctl as root

    This is to guard against any possible security issues.

  • Avoid using temp files in /tmp in make_oidjoins_check

    This has been reported as a security issue, though it's hardly worthy of +concern since there is no reason for non-developers to use this script anyway.


PrevHomeNext
Release 7.3.9UpRelease 7.3.7
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-3-9.html b/doc/src/sgml/html/release-7-3-9.html new file mode 100644 index 000000000..5b6932cc9 --- /dev/null +++ b/doc/src/sgml/html/release-7-3-9.html @@ -0,0 +1,257 @@ + +Release 7.3.9

E.181. Release 7.3.9

Release Date: 2005-01-31

This release contains a variety of fixes from 7.3.8, including several + security-related issues. +

E.181.1. Migration to Version 7.3.9

A dump/restore is not required for those running 7.3.X. +

E.181.2. Changes

  • Disallow LOAD to non-superusers

    On platforms that will automatically execute initialization functions of a +shared library (this includes at least Windows and ELF-based Unixen), +LOAD can be used to make the server execute arbitrary code. +Thanks to NGS Software for reporting this.

  • Check that creator of an aggregate function has the right to +execute the specified transition functions

    This oversight made it possible to bypass denial of EXECUTE +permission on a function.

  • Fix security and 64-bit issues in +contrib/intagg

  • Add needed STRICT marking to some contrib functions (Kris +Jurka)

  • Avoid buffer overrun when plpgsql cursor declaration has too +many parameters (Neil)

  • Fix planning error for FULL and RIGHT outer joins

    The result of the join was mistakenly supposed to be sorted the same as the +left input. This could not only deliver mis-sorted output to the user, but +in case of nested merge joins could give outright wrong answers.

  • Fix plperl for quote marks in tuple fields

  • Fix display of negative intervals in SQL and GERMAN +datestyles


PrevHomeNext
Release 7.3.10UpRelease 7.3.8
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-3.html b/doc/src/sgml/html/release-7-3.html new file mode 100644 index 000000000..ca3d3a896 --- /dev/null +++ b/doc/src/sgml/html/release-7-3.html @@ -0,0 +1,1899 @@ + +Release 7.3

E.190. Release 7.3

Release Date: 2002-11-27

E.190.1. Overview

Major changes in this release: +

Schemas

Schemas allow users to create objects in separate namespaces, + so two people or applications can have tables with the same + name. There is also a public schema for shared tables. + Table/index creation can be restricted by removing privileges + on the public schema. +

Drop Column

PostgreSQL now supports the + ALTER TABLE ... DROP COLUMN functionality. +

Table Functions

Functions returning multiple rows and/or multiple columns are + now much easier to use than before. You can call such a + "table function" in the SELECT + FROM clause, treating its output like a + table. Also, PL/pgSQL functions can + now return sets. +

Prepared Queries

PostgreSQL now supports prepared + queries, for improved performance. +

Dependency Tracking

PostgreSQL now records object + dependencies, which allows improvements in many areas. + DROP statements now take either + CASCADE or RESTRICT to control whether + dependent objects are also dropped. +

Privileges

Functions and procedural languages now have privileges, and + functions can be defined to run with the privileges of their + creator. +

Internationalization

Both multibyte and locale support are now always enabled. +

Logging

A variety of logging options have been enhanced. +

Interfaces

A large number of interfaces have been moved to http://gborg.postgresql.org + where they can be developed and released independently. +

Functions/Identifiers

By default, functions can now take up to 32 parameters, and + identifiers can be up to 63 bytes long. Also, OPAQUE + is now deprecated: there are specific "pseudo-datatypes" + to represent each of the former meanings of OPAQUE + in function argument and result types. +

E.190.2. Migration to Version 7.3

A dump/restore using pg_dump is required for those + wishing to migrate data from any previous release. If your + application examines the system catalogs, additional changes will + be required due to the introduction of schemas in 7.3; for more + information, see: http://developer.postgresql.org/~momjian/upgrade_tips_7.3. +

Observe the following incompatibilities: +

  • Pre-6.3 clients are no longer supported. +

  • pg_hba.conf now has a column for the user + name and additional features. Existing files need to be + adjusted. +

  • Several postgresql.conf logging parameters + have been renamed. +

  • LIMIT #,# has been disabled; use + LIMIT # OFFSET #. +

  • INSERT statements with column lists must + specify a value for each specified column. For example, + INSERT INTO tab (col1, col2) VALUES ('val1') + is now invalid. It's still allowed to supply fewer columns than + expected if the INSERT does not have a column list. +

  • serial columns are no longer automatically + UNIQUE; thus, an index will not automatically be + created. +

  • A SET command inside an aborted transaction + is now rolled back. +

  • COPY no longer considers missing trailing + columns to be null. All columns need to be specified. + (However, one can achieve a similar effect by specifying a + column list in the COPY command.) +

  • The data type timestamp is now equivalent to + timestamp without time zone, instead of + timestamp with time zone. +

  • Pre-7.3 databases loaded into 7.3 will not have the new object + dependencies for serial columns, unique + constraints, and foreign keys. See the directory + contrib/adddepend/ for a detailed + description and a script that will add such dependencies. +

  • An empty string ('') is no longer allowed as + the input into an integer field. Formerly, it was silently + interpreted as 0. +

E.190.3. Changes

E.190.3.1. Server Operation

  • Add pg_locks view to show locks (Neil)

  • Security fixes for password negotiation memory allocation (Neil)

  • Remove support for version 0 FE/BE protocol (PostgreSQL 6.2 and earlier) (Tom)

  • Reserve the last few backend slots for superusers, add parameter superuser_reserved_connections to control this (Nigel J. Andrews)

E.190.3.2. Performance

  • Improve startup by calling localtime() only once (Tom)

  • Cache system catalog information in flat files for faster startup (Tom)

  • Improve caching of index information (Tom)

  • Optimizer improvements (Tom, Fernando Nasser)

  • Catalog caches now store failed lookups (Tom)

  • Hash function improvements (Neil)

  • Improve performance of query tokenization and network handling (Peter)

  • Speed improvement for large object restore (Mario Weilguni)

  • Mark expired index entries on first lookup, saving later heap fetches (Tom)

  • Avoid excessive NULL bitmap padding (Manfred Koizar)

  • Add BSD-licensed qsort() for Solaris, for performance (Bruce)

  • Reduce per-row overhead by four bytes (Manfred Koizar)

  • Fix GEQO optimizer bug (Neil Conway)

  • Make WITHOUT OID actually save four bytes per row (Manfred Koizar)

  • Add default_statistics_target variable to specify ANALYZE buckets (Neil)

  • Use local buffer cache for temporary tables so no WAL overhead (Tom)

  • Improve free space map performance on large tables (Stephen Marshall, Tom)

  • Improved WAL write concurrency (Tom)

E.190.3.3. Privileges

  • Add privileges on functions and procedural languages (Peter)

  • Add OWNER to CREATE DATABASE so superusers can create databases on behalf of unprivileged users (Gavin Sherry, Tom)

  • Add new object privilege bits EXECUTE and USAGE (Tom)

  • Add SET SESSION AUTHORIZATION DEFAULT and RESET SESSION AUTHORIZATION (Tom)

  • Allow functions to be executed with the privilege of the function owner (Peter)

E.190.3.4. Server Configuration

  • Server log messages now tagged with LOG, not DEBUG (Bruce)

  • Add user column to pg_hba.conf (Bruce)

  • Have log_connections output two lines in log file (Tom)

  • Remove debug_level from postgresql.conf, now server_min_messages (Bruce)

  • New ALTER DATABASE/USER ... SET command for per-user/database initialization (Peter)

  • New parameters server_min_messages and client_min_messages to control which messages are sent to the server logs or client applications (Bruce)

  • Allow pg_hba.conf to specify lists of users/databases separated by commas, group names prepended with +, and file names prepended with @ (Bruce)

  • Remove secondary password file capability and pg_password utility (Bruce)

  • Add variable db_user_namespace for database-local user names (Bruce)

  • SSL improvements (Bear Giles)

  • Make encryption of stored passwords the default (Bruce)

  • Allow pg_statistics to be reset by calling pg_stat_reset() (Christopher)

  • Add log_duration parameter (Bruce)

  • Rename debug_print_query to log_statement (Bruce)

  • Rename show_query_stats to show_statement_stats (Bruce)

  • Add param log_min_error_statement to print commands to logs on error (Gavin)

E.190.3.5. Queries

  • Make cursors insensitive, meaning their contents do not change (Tom)

  • Disable LIMIT #,# syntax; now only LIMIT # OFFSET # supported (Bruce)

  • Increase identifier length to 63 (Neil, Bruce)

  • UNION fixes for merging >= 3 columns of different lengths (Tom)

  • Add DEFAULT key word to INSERT, e.g., INSERT ... (..., DEFAULT, ...) (Rod)

  • Allow views to have default values using ALTER COLUMN ... SET DEFAULT (Neil)

  • Fail on INSERTs with column lists that don't supply all column values, e.g., INSERT INTO tab (col1, col2) VALUES ('val1'); (Rod)

  • Fix for join aliases (Tom)

  • Fix for FULL OUTER JOINs (Tom)

  • Improve reporting of invalid identifier and location (Tom, Gavin)

  • Fix OPEN cursor(args) (Tom)

  • Allow 'ctid' to be used in a view and currtid(viewname) (Hiroshi)

  • Fix for CREATE TABLE AS with UNION (Tom)

  • SQL99 syntax improvements (Thomas)

  • Add statement_timeout variable to cancel queries (Bruce)

  • Allow prepared queries with PREPARE/EXECUTE (Neil)

  • Allow FOR UPDATE to appear after LIMIT/OFFSET (Bruce)

  • Add variable autocommit (Tom, David Van Wie)

E.190.3.6. Object Manipulation

  • Make equals signs optional in CREATE DATABASE (Gavin Sherry)

  • Make ALTER TABLE OWNER change index ownership too (Neil)

  • New ALTER TABLE tabname ALTER COLUMN colname SET STORAGE controls TOAST storage, compression (John Gray)

  • Add schema support, CREATE/DROP SCHEMA (Tom)

  • Create schema for temporary tables (Tom)

  • Add variable search_path for schema search (Tom)

  • Add ALTER TABLE SET/DROP NOT NULL (Christopher)

  • New CREATE FUNCTION volatility levels (Tom)

  • Make rule names unique only per table (Tom)

  • Add 'ON tablename' clause to DROP RULE and COMMENT ON RULE (Tom)

  • Add ALTER TRIGGER RENAME (Joe)

  • New current_schema() and current_schemas() inquiry functions (Tom)

  • Allow functions to return multiple rows (table functions) (Joe)

  • Make WITH optional in CREATE DATABASE, for consistency (Bruce)

  • Add object dependency tracking (Rod, Tom)

  • Add RESTRICT/CASCADE to DROP commands (Rod)

  • Add ALTER TABLE DROP for non-CHECK CONSTRAINT (Rod)

  • Autodestroy sequence on DROP of table with SERIAL (Rod)

  • Prevent column dropping if column is used by foreign key (Rod)

  • Automatically drop constraints/functions when object is dropped (Rod)

  • Add CREATE/DROP OPERATOR CLASS (Bill Studenmund, Tom)

  • Add ALTER TABLE DROP COLUMN (Christopher, Tom, Hiroshi)

  • Prevent inherited columns from being removed or renamed (Alvaro Herrera)

  • Fix foreign key constraints to not error on intermediate database states (Stephan)

  • Propagate column or table renaming to foreign key constraints

  • Add CREATE OR REPLACE VIEW (Gavin, Neil, Tom)

  • Add CREATE OR REPLACE RULE (Gavin, Neil, Tom)

  • Have rules execute alphabetically, returning more predictable values (Tom)

  • Triggers are now fired in alphabetical order (Tom)

  • Add /contrib/adddepend to handle pre-7.3 object dependencies (Rod)

  • Allow better casting when inserting/updating values (Tom)

E.190.3.7. Utility Commands

  • Have COPY TO output embedded carriage returns and newlines as \r and \n (Tom)

  • Allow DELIMITER in COPY FROM to be 8-bit clean (Tatsuo)

  • Make pg_dump use ALTER TABLE ADD PRIMARY KEY, for performance (Neil)

  • Disable brackets in multistatement rules (Bruce)

  • Disable VACUUM from being called inside a function (Bruce)

  • Allow dropdb and other scripts to use identifiers with spaces (Bruce)

  • Restrict database comment changes to the current database

  • Allow comments on operators, independent of the underlying function (Rod)

  • Rollback SET commands in aborted transactions (Tom)

  • EXPLAIN now outputs as a query (Tom)

  • Display condition expressions and sort keys in EXPLAIN (Tom)

  • Add 'SET LOCAL var = value' to set configuration variables for a single transaction (Tom)

  • Allow ANALYZE to run in a transaction (Bruce)

  • Improve COPY syntax using new WITH clauses, keep backward compatibility (Bruce)

  • Fix pg_dump to consistently output tags in non-ASCII dumps (Bruce)

  • Make foreign key constraints clearer in dump file (Rod)

  • Add COMMENT ON CONSTRAINT (Rod)

  • Allow COPY TO/FROM to specify column names (Brent Verner)

  • Dump UNIQUE and PRIMARY KEY constraints as ALTER TABLE (Rod)

  • Have SHOW output a query result (Joe)

  • Generate failure on short COPY lines rather than pad NULLs (Neil)

  • Fix CLUSTER to preserve all table attributes (Alvaro Herrera)

  • New pg_settings table to view/modify GUC settings (Joe)

  • Add smart quoting, portability improvements to pg_dump output (Peter)

  • Dump serial columns out as SERIAL (Tom)

  • Enable large file support, >2G for pg_dump (Peter, Philip Warner, Bruce)

  • Disallow TRUNCATE on tables that are involved in referential constraints (Rod)

  • Have TRUNCATE also auto-truncate the toast table of the relation (Tom)

  • Add clusterdb utility that will auto-cluster an entire database based on previous CLUSTER operations (Alvaro Herrera)

  • Overhaul pg_dumpall (Peter)

  • Allow REINDEX of TOAST tables (Tom)

  • Implemented START TRANSACTION, per SQL99 (Neil)

  • Fix rare index corruption when a page split affects bulk delete (Tom)

  • Fix ALTER TABLE ... ADD COLUMN for inheritance (Alvaro Herrera)

E.190.3.8. Data Types and Functions

  • Fix factorial(0) to return 1 (Bruce)

  • Date/time/timezone improvements (Thomas)

  • Fix for array slice extraction (Tom)

  • Fix extract/date_part to report proper microseconds for timestamp (Tatsuo)

  • Allow text_substr() and bytea_substr() to read TOAST values more efficiently (John Gray)

  • Add domain support (Rod)

  • Make WITHOUT TIME ZONE the default for TIMESTAMP and TIME data types (Thomas)

  • Allow alternate storage scheme of 64-bit integers for date/time types using --enable-integer-datetimes in configure (Thomas)

  • Make timezone(timestamptz) return timestamp rather than a string (Thomas)

  • Allow fractional seconds in date/time types for dates prior to 1BC (Thomas)

  • Limit timestamp data types to 6 decimal places of precision (Thomas)

  • Change timezone conversion functions from timetz() to timezone() (Thomas)

  • Add configuration variables datestyle and timezone (Tom)

  • Add OVERLAY(), which allows substitution of a substring in a string (Thomas)

  • Add SIMILAR TO (Thomas, Tom)

  • Add regular expression SUBSTRING(string FROM pat FOR escape) (Thomas)

  • Add LOCALTIME and LOCALTIMESTAMP functions (Thomas)

  • Add named composite types using CREATE TYPE typename AS (column) (Joe)

  • Allow composite type definition in the table alias clause (Joe)

  • Add new API to simplify creation of C language table functions (Joe)

  • Remove ODBC-compatible empty parentheses from calls to SQL99 functions for which these parentheses do not match the standard (Thomas)

  • Allow macaddr data type to accept 12 hex digits with no separators (Mike Wyer)

  • Add CREATE/DROP CAST (Peter)

  • Add IS DISTINCT FROM operator (Thomas)

  • Add SQL99 TREAT() function, synonym for CAST() (Thomas)

  • Add pg_backend_pid() to output backend pid (Bruce)

  • Add IS OF / IS NOT OF type predicate (Thomas)

  • Allow bit string constants without fully-specified length (Thomas)

  • Allow conversion between 8-byte integers and bit strings (Thomas)

  • Implement hex literal conversion to bit string literal (Thomas)

  • Allow table functions to appear in the FROM clause (Joe)

  • Increase maximum number of function parameters to 32 (Bruce)

  • No longer automatically create index for SERIAL column (Tom)

  • Add current_database() (Rod)

  • Fix cash_words() to not overflow buffer (Tom)

  • Add functions replace(), split_part(), to_hex() (Joe)

  • Fix LIKE for bytea as a right-hand argument (Joe)

  • Prevent crashes caused by SELECT cash_out(2) (Tom)

  • Fix to_char(1,'FM999.99') to return a period (Karel)

  • Fix trigger/type/language functions returning OPAQUE to return proper type (Tom)

E.190.3.9. Internationalization

  • Add additional encodings: Korean (JOHAB), Thai (WIN874), Vietnamese (TCVN), Arabic (WIN1256), Simplified Chinese (GBK), Korean (UHC) (Eiji Tokuya)

  • Enable locale support by default (Peter)

  • Add locale variables (Peter)

  • Escape byes >= 0x7f for multibyte in PQescapeBytea/PQunescapeBytea (Tatsuo)

  • Add locale awareness to regular expression character classes

  • Enable multibyte support by default (Tatsuo)

  • Add GB18030 multibyte support (Bill Huang)

  • Add CREATE/DROP CONVERSION, allowing loadable encodings (Tatsuo, Kaori)

  • Add pg_conversion table (Tatsuo)

  • Add SQL99 CONVERT() function (Tatsuo)

  • pg_dumpall, pg_controldata, and pg_resetxlog now national-language aware (Peter)

  • New and updated translations

E.190.3.10. Server-side Languages

  • Allow recursive SQL function (Peter)

  • Change PL/Tcl build to use configured compiler and Makefile.shlib (Peter)

  • Overhaul the PL/pgSQL FOUND variable to be more Oracle-compatible (Neil, Tom)

  • Allow PL/pgSQL to handle quoted identifiers (Tom)

  • Allow set-returning PL/pgSQL functions (Neil)

  • Make PL/pgSQL schema-aware (Joe)

  • Remove some memory leaks (Nigel J. Andrews, Tom)

E.190.3.11. psql

  • Don't lowercase psql \connect database name for 7.2.0 compatibility (Tom)

  • Add psql \timing to time user queries (Greg Sabino Mullane)

  • Have psql \d show index information (Greg Sabino Mullane)

  • New psql \dD shows domains (Jonathan Eisler)

  • Allow psql to show rules on views (Paul ?)

  • Fix for psql variable substitution (Tom)

  • Allow psql \d to show temporary table structure (Tom)

  • Allow psql \d to show foreign keys (Rod)

  • Fix \? to honor \pset pager (Bruce)

  • Have psql reports its version number on startup (Tom)

  • Allow \copy to specify column names (Tom)

E.190.3.12. libpq

  • Add ~/.pgpass to store host/user password combinations (Alvaro Herrera)

  • Add PQunescapeBytea() function to libpq (Patrick Welche)

  • Fix for sending large queries over non-blocking connections (Bernhard Herzog)

  • Fix for libpq using timers on Win9X (David Ford)

  • Allow libpq notify to handle servers with different-length identifiers (Tom)

  • Add libpq PQescapeString() and PQescapeBytea() to Windows (Bruce)

  • Fix for SSL with non-blocking connections (Jack Bates)

  • Add libpq connection timeout parameter (Denis A Ustimenko)

E.190.3.13. JDBC

  • Allow JDBC to compile with JDK 1.4 (Dave)

  • Add JDBC 3 support (Barry)

  • Allows JDBC to set loglevel by adding ?loglevel=X to the connection URL (Barry)

  • Add Driver.info() message that prints out the version number (Barry)

  • Add updateable result sets (Raghu Nidagal, Dave)

  • Add support for callable statements (Paul Bethe)

  • Add query cancel capability

  • Add refresh row (Dave)

  • Fix MD5 encryption handling for multibyte servers (Jun Kawai)

  • Add support for prepared statements (Barry)

E.190.3.14. Miscellaneous Interfaces

  • Fixed ECPG bug concerning octal numbers in single quotes (Michael)

  • Move src/interfaces/libpgeasy to http://gborg.postgresql.org (Marc, Bruce)

  • Improve Python interface (Elliot Lee, Andrew Johnson, Greg Copeland)

  • Add libpgtcl connection close event (Gerhard Hintermayer)

  • Move src/interfaces/libpq++ to http://gborg.postgresql.org (Marc, Bruce)

  • Move src/interfaces/odbc to http://gborg.postgresql.org (Marc)

  • Move src/interfaces/libpgeasy to http://gborg.postgresql.org (Marc, Bruce)

  • Move src/interfaces/perl5 to http://gborg.postgresql.org (Marc, Bruce)

  • Remove src/bin/pgaccess from main tree, now at http://www.pgaccess.org (Bruce)

  • Add pg_on_connection_loss command to libpgtcl (Gerhard Hintermayer, Tom)

E.190.3.15. Source Code

  • Fix for parallel make (Peter)

  • AIX fixes for linking Tcl (Andreas Zeugswetter)

  • Allow PL/Perl to build under Cygwin (Jason Tishler)

  • Improve MIPS compiles (Peter, Oliver Elphick)

  • Require Autoconf version 2.53 (Peter)

  • Require readline and zlib by default in configure (Peter)

  • Allow Solaris to use Intimate Shared Memory (ISM), for performance (Scott Brunza, P.J. Josh Rovero)

  • Always enable syslog in compile, remove --enable-syslog option (Tatsuo)

  • Always enable multibyte in compile, remove --enable-multibyte option (Tatsuo)

  • Always enable locale in compile, remove --enable-locale option (Peter)

  • Fix for Win9x DLL creation (Magnus Naeslund)

  • Fix for link() usage by WAL code on Windows, BeOS (Jason Tishler)

  • Add sys/types.h to c.h, remove from main files (Peter, Bruce)

  • Fix AIX hang on SMP machines (Tomoyuki Niijima)

  • AIX SMP hang fix (Tomoyuki Niijima)

  • Fix pre-1970 date handling on newer glibc libraries (Tom)

  • Fix PowerPC SMP locking (Tom)

  • Prevent gcc -ffast-math from being used (Peter, Tom)

  • Bison >= 1.50 now required for developer builds

  • Kerberos 5 support now builds with Heimdal (Peter)

  • Add appendix in the User's Guide which lists SQL features (Thomas)

  • Improve loadable module linking to use RTLD_NOW (Tom)

  • New error levels WARNING, INFO, LOG, DEBUG[1-5] (Bruce)

  • New src/port directory holds replaced libc functions (Peter, Bruce)

  • New pg_namespace system catalog for schemas (Tom)

  • Add pg_class.relnamespace for schemas (Tom)

  • Add pg_type.typnamespace for schemas (Tom)

  • Add pg_proc.pronamespace for schemas (Tom)

  • Restructure aggregates to have pg_proc entries (Tom)

  • System relations now have their own namespace, pg_* test not required (Fernando Nasser)

  • Rename TOAST index names to be *_index rather than *_idx (Neil)

  • Add namespaces for operators, opclasses (Tom)

  • Add additional checks to server control file (Thomas)

  • New Polish FAQ (Marcin Mazurek)

  • Add Posix semaphore support (Tom)

  • Document need for reindex (Bruce)

  • Rename some internal identifiers to simplify Windows compile (Jan, Katherine Ward)

  • Add documentation on computing disk space (Bruce)

  • Remove KSQO from GUC (Bruce)

  • Fix memory leak in rtree (Kenneth Been)

  • Modify a few error messages for consistency (Bruce)

  • Remove unused system table columns (Peter)

  • Make system columns NOT NULL where appropriate (Tom)

  • Clean up use of sprintf in favor of snprintf() (Neil, Jukka Holappa)

  • Remove OPAQUE and create specific subtypes (Tom)

  • Cleanups in array internal handling (Joe, Tom)

  • Disallow pg_atoi('') (Bruce)

  • Remove parameter wal_files because WAL files are now recycled (Bruce)

  • Add version numbers to heap pages (Tom)

E.190.3.16. Contrib

  • Allow inet arrays in /contrib/array (Neil)

  • GiST fixes (Teodor Sigaev, Neil)

  • Upgrade /contrib/mysql

  • Add /contrib/dbsize which shows table sizes without vacuum (Peter)

  • Add /contrib/intagg, integer aggregator routines (mlw)

  • Improve /contrib/oid2name (Neil, Bruce)

  • Improve /contrib/tsearch (Oleg, Teodor Sigaev)

  • Cleanups of /contrib/rserver (Alexey V. Borzov)

  • Update /contrib/oracle conversion utility (Gilles Darold)

  • Update /contrib/dblink (Joe)

  • Improve options supported by /contrib/vacuumlo (Mario Weilguni)

  • Improvements to /contrib/intarray (Oleg, Teodor Sigaev, Andrey Oktyabrski)

  • Add /contrib/reindexdb utility (Shaun Thomas)

  • Add indexing to /contrib/isbn_issn (Dan Weston)

  • Add /contrib/dbmirror (Steven Singer)

  • Improve /contrib/pgbench (Neil)

  • Add /contrib/tablefunc table function examples (Joe)

  • Add /contrib/ltree data type for tree structures (Teodor Sigaev, Oleg Bartunov)

  • Move /contrib/pg_controldata, pg_resetxlog into main tree (Bruce)

  • Fixes to /contrib/cube (Bruno Wolff)

  • Improve /contrib/fulltextindex (Christopher)


PrevHomeNext
Release 7.3.1UpRelease 7.2.8
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-1.html b/doc/src/sgml/html/release-7-4-1.html new file mode 100644 index 000000000..4a2607356 --- /dev/null +++ b/doc/src/sgml/html/release-7-4-1.html @@ -0,0 +1,428 @@ + +Release 7.4.1

E.167. Release 7.4.1

Release Date: 2003-12-22

This release contains a variety of fixes from 7.4. + For information about new features in the 7.4 major release, see + Section E.168. +

E.167.1. Migration to Version 7.4.1

A dump/restore is not required for those + running 7.4. +

If you want to install the fixes in the information schema + you need to reload it into the database. + This is either accomplished by initializing a new cluster + by running initdb, or by running the following + sequence of SQL commands in each database (ideally including + template1) as a superuser in + psql, after installing the new release: +

DROP SCHEMA information_schema CASCADE;
+\i /usr/local/pgsql/share/information_schema.sql

+ Substitute your installation path in the second command. +

E.167.2. Changes

  • Fixed bug in CREATE SCHEMA parsing in ECPG (Michael)

  • Fix compile error when --enable-thread-safety and --with-perl are used together (Peter)

  • Fix for subqueries that used hash joins (Tom)

    Certain subqueries that used hash joins would crash because of + improperly shared structures.

  • Fix free space map compaction bug (Tom)

    This fixes a bug where compaction of the free space map could lead + to a database server shutdown.

  • Fix for Borland compiler build of libpq (Bruce)

  • Fix netmask() and hostmask() to return the maximum-length masklen (Tom)

    Fix these functions to return values consistent with pre-7.4 + releases.

  • Several contrib/pg_autovacuum fixes

    Fixes include improper variable initialization, missing vacuum after + TRUNCATE, and duration computation overflow for long vacuums.

  • Allow compile of contrib/cube under Cygwin (Jason Tishler)

  • Fix Solaris use of password file when no passwords are defined (Tom)

    Fix crash on Solaris caused by use of any type of password + authentication when no passwords were defined.

  • JDBC fix for thread problems, other fixes

  • Fix for bytea index lookups (Joe)

  • Fix information schema for bit data types (Peter)

  • Force zero_damaged_pages to be on during recovery from WAL

  • Prevent some obscure cases of "variable not in subplan target lists"

  • Make PQescapeBytea and byteaout consistent with each other (Joe)

  • Escape bytea output for bytes > 0x7e(Joe)

    If different client encodings are used for bytea output and input, it + is possible for bytea values to be corrupted by the differing + encodings. This fix escapes all bytes that might be affected.

  • Added missing SPI_finish() calls to dblink's get_tuple_of_interest() (Joe)

  • New Czech FAQ

  • Fix information schema view constraint_column_usage for foreign keys (Peter)

  • ECPG fixes (Michael)

  • Fix bug with multiple IN subqueries and joins in the subqueries (Tom)

  • Allow COUNT('x') to work (Tom)

  • Install ECPG include files for Informix compatibility into separate directory (Peter)

    Some names of ECPG include files for Informix compatibility conflicted with operating system include files. + By installing them in their own directory, name conflicts have been reduced.

  • Fix SSL memory leak (Neil)

    This release fixes a bug in 7.4 where SSL didn't free all memory it allocated.

  • Prevent pg_service.conf from using service name as default dbname (Bruce)

  • Fix local ident authentication on FreeBSD (Tom)


PrevHomeNext
Release 7.4.2UpRelease 7.4
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-10.html b/doc/src/sgml/html/release-7-4-10.html new file mode 100644 index 000000000..85e6c600d --- /dev/null +++ b/doc/src/sgml/html/release-7-4-10.html @@ -0,0 +1,250 @@ + +Release 7.4.10

E.158. Release 7.4.10

Release Date: 2005-12-12

This release contains a variety of fixes from 7.4.9. + For information about new features in the 7.4 major release, see + Section E.168. +

E.158.1. Migration to Version 7.4.10

A dump/restore is not required for those running 7.4.X. However, + if you are upgrading from a version earlier than 7.4.8, see the release + notes for 7.4.8. +

E.158.2. Changes

  • Fix race condition in transaction log management

    There was a narrow window in which an I/O operation could be initiated +for the wrong page, leading to an Assert failure or data +corruption.

  • Prevent failure if client sends Bind protocol message +when current transaction is already aborted

  • /contrib/ltree fixes (Teodor)

  • AIX and HPUX compile fixes (Tom)

  • Fix longstanding planning error for outer joins

    This bug sometimes caused a bogus error "RIGHT JOIN is +only supported with merge-joinable join conditions".

  • Prevent core dump in pg_autovacuum when a +table has been dropped


PrevHomeNext
Release 7.4.11UpRelease 7.4.9
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-11.html b/doc/src/sgml/html/release-7-4-11.html new file mode 100644 index 000000000..8a1b8dba1 --- /dev/null +++ b/doc/src/sgml/html/release-7-4-11.html @@ -0,0 +1,285 @@ + +Release 7.4.11

E.157. Release 7.4.11

Release Date: 2006-01-09

This release contains a variety of fixes from 7.4.10. + For information about new features in the 7.4 major release, see + Section E.168. +

E.157.1. Migration to Version 7.4.11

A dump/restore is not required for those running 7.4.X. However, + if you are upgrading from a version earlier than 7.4.8, see the release + notes for 7.4.8. + Also, you might need to REINDEX indexes on textual + columns after updating, if you are affected by the locale or + plperl issues described below. +

E.157.2. Changes

  • Fix for protocol-level Describe messages issued +outside a transaction or in a failed transaction (Tom)

  • Fix character string comparison for locales that consider +different character combinations as equal, such as Hungarian (Tom)

    This might require REINDEX to fix existing indexes on +textual columns.

  • Set locale environment variables during postmaster startup +to ensure that plperl won't change the locale later

    This fixes a problem that occurred if the postmaster was +started with environment variables specifying a different locale than what +initdb had been told. Under these conditions, any use of +plperl was likely to lead to corrupt indexes. You might need +REINDEX to fix existing indexes on +textual columns if this has happened to you.

  • Fix longstanding bug in strpos() and regular expression +handling in certain rarely used Asian multi-byte character sets (Tatsuo)

  • Fix bug in /contrib/pgcrypto gen_salt, +which caused it not to use all available salt space for MD5 and +XDES algorithms (Marko Kreen, Solar Designer)

    Salts for Blowfish and standard DES are unaffected.

  • Fix /contrib/dblink to throw an error, +rather than crashing, when the number of columns specified is different from +what's actually returned by the query (Joe)


PrevHomeNext
Release 7.4.12UpRelease 7.4.10
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-12.html b/doc/src/sgml/html/release-7-4-12.html new file mode 100644 index 000000000..3e5769324 --- /dev/null +++ b/doc/src/sgml/html/release-7-4-12.html @@ -0,0 +1,267 @@ + +Release 7.4.12

E.156. Release 7.4.12

Release Date: 2006-02-14

This release contains a variety of fixes from 7.4.11. + For information about new features in the 7.4 major release, see + Section E.168. +

E.156.1. Migration to Version 7.4.12

A dump/restore is not required for those running 7.4.X. However, + if you are upgrading from a version earlier than 7.4.11, see the release + notes for 7.4.11. +

E.156.2. Changes

  • Fix potential crash in SET +SESSION AUTHORIZATION (CVE-2006-0553)

    An unprivileged user could crash the server process, resulting in +momentary denial of service to other users, if the server has been compiled +with Asserts enabled (which is not the default). +Thanks to Akio Ishida for reporting this problem.

  • Fix bug with row visibility logic in self-inserted +rows (Tom)

    Under rare circumstances a row inserted by the current command +could be seen as already valid, when it should not be. Repairs bug +created in 7.4.9 and 7.3.11 releases.

  • Fix race condition that could lead to "file already +exists" errors during pg_clog file creation +(Tom)

  • Properly check DOMAIN constraints for +UNKNOWN parameters in prepared statements +(Neil)

  • Fix to allow restoring dumps that have cross-schema +references to custom operators (Tom)

  • Portability fix for testing presence of finite +and isinf during configure (Tom)


PrevHomeNext
Release 7.4.13UpRelease 7.4.11
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-13.html b/doc/src/sgml/html/release-7-4-13.html new file mode 100644 index 000000000..bbc2242c5 --- /dev/null +++ b/doc/src/sgml/html/release-7-4-13.html @@ -0,0 +1,382 @@ + +Release 7.4.13

E.155. Release 7.4.13

Release Date: 2006-05-23

This release contains a variety of fixes from 7.4.12, + including patches for extremely serious security issues. + For information about new features in the 7.4 major release, see + Section E.168. +

E.155.1. Migration to Version 7.4.13

A dump/restore is not required for those running 7.4.X. However, + if you are upgrading from a version earlier than 7.4.11, see the release + notes for 7.4.11. +

Full security against the SQL-injection attacks described in + CVE-2006-2313 and CVE-2006-2314 might require changes in application + code. If you have applications that embed untrustworthy strings + into SQL commands, you should examine them as soon as possible to + ensure that they are using recommended escaping techniques. In + most cases, applications should be using subroutines provided by + libraries or drivers (such as libpq's + PQescapeStringConn()) to perform string escaping, + rather than relying on ad hoc code to do it. +

E.155.2. Changes

  • Change the server to reject invalidly-encoded multibyte +characters in all cases (Tatsuo, Tom)

    While PostgreSQL has been moving in this direction for +some time, the checks are now applied uniformly to all encodings and all +textual input, and are now always errors not merely warnings. This change +defends against SQL-injection attacks of the type described in CVE-2006-2313.

  • Reject unsafe uses of \' in string literals

    As a server-side defense against SQL-injection attacks of the type +described in CVE-2006-2314, the server now only accepts '' and not +\' as a representation of ASCII single quote in SQL string +literals. By default, \' is rejected only when +client_encoding is set to a client-only encoding (SJIS, BIG5, GBK, +GB18030, or UHC), which is the scenario in which SQL injection is possible. +A new configuration parameter backslash_quote is available to +adjust this behavior when needed. Note that full security against +CVE-2006-2314 might require client-side changes; the purpose of +backslash_quote is in part to make it obvious that insecure +clients are insecure.

  • Modify libpq's string-escaping routines to be +aware of encoding considerations and +standard_conforming_strings

    This fixes libpq-using applications for the security +issues described in CVE-2006-2313 and CVE-2006-2314, and also future-proofs +them against the planned changeover to SQL-standard string literal syntax. +Applications that use multiple PostgreSQL connections +concurrently should migrate to PQescapeStringConn() and +PQescapeByteaConn() to ensure that escaping is done correctly +for the settings in use in each database connection. Applications that +do string escaping "by hand" should be modified to rely on library +routines instead.

  • Fix some incorrect encoding conversion functions

    win1251_to_iso, alt_to_iso, +euc_tw_to_big5, euc_tw_to_mic, +mic_to_euc_tw were all broken to varying +extents.

  • Clean up stray remaining uses of \' in strings +(Bruce, Jan)

  • Fix bug that sometimes caused OR'd index scans to +miss rows they should have returned

  • Fix WAL replay for case where a btree index has been +truncated

  • Fix SIMILAR TO for patterns involving +| (Tom)

  • Fix server to use custom DH SSL parameters correctly (Michael +Fuhr)

  • Fix for Bonjour on Intel Macs (Ashley Clark)

  • Fix various minor memory leaks


PrevHomeNext
Release 7.4.14UpRelease 7.4.12
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-14.html b/doc/src/sgml/html/release-7-4-14.html new file mode 100644 index 000000000..8c8ae3e1f --- /dev/null +++ b/doc/src/sgml/html/release-7-4-14.html @@ -0,0 +1,250 @@ + +Release 7.4.14

E.154. Release 7.4.14

Release Date: 2006-10-16

This release contains a variety of fixes from 7.4.13. + For information about new features in the 7.4 major release, see + Section E.168. +

E.154.1. Migration to Version 7.4.14

A dump/restore is not required for those running 7.4.X. However, + if you are upgrading from a version earlier than 7.4.11, see the release + notes for 7.4.11. +

E.154.2. Changes

  • Fix core dump when an untyped literal is taken as +ANYARRAY

  • Fix string_to_array() to handle overlapping + matches for the separator string

    For example, string_to_array('123xx456xxx789', 'xx').

  • Fix corner cases in pattern matching for + psql's \d commands

  • Fix index-corrupting bugs in /contrib/ltree + (Teodor)

  • Fix backslash escaping in /contrib/dbmirror

  • Adjust regression tests for recent changes in US DST laws


PrevHomeNext
Release 7.4.15UpRelease 7.4.13
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-15.html b/doc/src/sgml/html/release-7-4-15.html new file mode 100644 index 000000000..caa7e5198 --- /dev/null +++ b/doc/src/sgml/html/release-7-4-15.html @@ -0,0 +1,289 @@ + +Release 7.4.15

E.153. Release 7.4.15

Release Date: 2007-01-08

This release contains a variety of fixes from 7.4.14. + For information about new features in the 7.4 major release, see + Section E.168. +

E.153.1. Migration to Version 7.4.15

A dump/restore is not required for those running 7.4.X. However, + if you are upgrading from a version earlier than 7.4.11, see the release + notes for 7.4.11. +

E.153.2. Changes

  • Improve handling of getaddrinfo() on AIX (Tom) +

    This fixes a problem with starting the statistics collector, + among other things. +

  • Fix "failed to re-find parent key" errors in + VACUUM (Tom) +

  • Fix bugs affecting multi-gigabyte hash indexes (Tom) +

  • Fix error when constructing an ARRAY[] made up of multiple + empty elements (Tom) +

  • to_number() and to_char(numeric) + are now STABLE, not IMMUTABLE, for + new initdb installs (Tom) +

    This is because lc_numeric can potentially + change the output of these functions. +

  • Improve index usage of regular expressions that use parentheses (Tom) +

    This improves psql \d performance also. +


PrevHomeNext
Release 7.4.16UpRelease 7.4.14
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-16.html b/doc/src/sgml/html/release-7-4-16.html new file mode 100644 index 000000000..0e3a8b760 --- /dev/null +++ b/doc/src/sgml/html/release-7-4-16.html @@ -0,0 +1,243 @@ + +Release 7.4.16

E.152. Release 7.4.16

Release Date: 2007-02-05

This release contains a variety of fixes from 7.4.15, including + a security fix. + For information about new features in the 7.4 major release, see + Section E.168. +

E.152.1. Migration to Version 7.4.16

A dump/restore is not required for those running 7.4.X. However, + if you are upgrading from a version earlier than 7.4.11, see the release + notes for 7.4.11. +

E.152.2. Changes

  • Remove security vulnerability that allowed connected users + to read backend memory (Tom) +

    The vulnerability involves suppressing the normal check that a SQL + function returns the data type it's declared to, or changing the + data type of a table column used in a SQL function (CVE-2007-0555). + This error can easily be exploited to cause a backend crash, and in + principle might be used to read database content that the user + should not be able to access. +

  • Fix rare bug wherein btree index page splits could fail + due to choosing an infeasible split point (Heikki Linnakangas) +

  • Fix for rare Assert() crash triggered by UNION (Tom) +

  • Tighten security of multi-byte character processing for UTF8 sequences + over three bytes long (Tom) +


PrevHomeNext
Release 7.4.17UpRelease 7.4.15
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-17.html b/doc/src/sgml/html/release-7-4-17.html new file mode 100644 index 000000000..823349c8b --- /dev/null +++ b/doc/src/sgml/html/release-7-4-17.html @@ -0,0 +1,258 @@ + +Release 7.4.17

E.151. Release 7.4.17

Release Date: 2007-04-23

This release contains fixes from 7.4.16, + including a security fix. + For information about new features in the 7.4 major release, see + Section E.168. +

E.151.1. Migration to Version 7.4.17

A dump/restore is not required for those running 7.4.X. However, + if you are upgrading from a version earlier than 7.4.11, see the release + notes for 7.4.11. +

E.151.2. Changes

  • Support explicit placement of the temporary-table schema within + search_path, and disable searching it for functions + and operators (Tom) +

    This is needed to allow a security-definer function to set a + truly secure value of search_path. Without it, + an unprivileged SQL user can use temporary objects to execute code + with the privileges of the security-definer function (CVE-2007-2138). + See CREATE FUNCTION for more information. +

  • /contrib/tsearch2 crash fixes (Teodor) +

  • Fix potential-data-corruption bug in how VACUUM FULL handles + UPDATE chains (Tom, Pavan Deolasee) +

  • Fix PANIC during enlargement of a hash index (bug introduced in 7.4.15) + (Tom) +


PrevHomeNext
Release 7.4.18UpRelease 7.4.16
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-18.html b/doc/src/sgml/html/release-7-4-18.html new file mode 100644 index 000000000..f9a3b9270 --- /dev/null +++ b/doc/src/sgml/html/release-7-4-18.html @@ -0,0 +1,261 @@ + +Release 7.4.18

E.150. Release 7.4.18

Release Date: 2007-09-17

This release contains fixes from 7.4.17. + For information about new features in the 7.4 major release, see + Section E.168. +

E.150.1. Migration to Version 7.4.18

A dump/restore is not required for those running 7.4.X. However, + if you are upgrading from a version earlier than 7.4.11, see the release + notes for 7.4.11. +

E.150.2. Changes

  • Prevent index corruption when a transaction inserts rows and + then aborts close to the end of a concurrent VACUUM + on the same table (Tom) +

  • Make CREATE DOMAIN ... DEFAULT NULL work properly (Tom) +

  • Fix excessive logging of SSL error messages (Tom) +

  • Fix crash when log_min_error_statement logging runs out + of memory (Tom) +

  • Prevent CLUSTER from failing + due to attempting to process temporary tables of other sessions (Alvaro) +

  • Require non-superusers who use /contrib/dblink to use only + password authentication, as a security measure (Joe) +


PrevHomeNext
Release 7.4.19UpRelease 7.4.17
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-19.html b/doc/src/sgml/html/release-7-4-19.html new file mode 100644 index 000000000..32087529d --- /dev/null +++ b/doc/src/sgml/html/release-7-4-19.html @@ -0,0 +1,390 @@ + +Release 7.4.19

E.149. Release 7.4.19

Release Date: 2008-01-07

This release contains a variety of fixes from 7.4.18, + including fixes for significant security issues. + For information about new features in the 7.4 major release, see + Section E.168. +

E.149.1. Migration to Version 7.4.19

A dump/restore is not required for those running 7.4.X. However, + if you are upgrading from a version earlier than 7.4.11, see the release + notes for 7.4.11. +

E.149.2. Changes

  • Prevent functions in indexes from executing with the privileges of + the user running VACUUM, ANALYZE, etc (Tom) +

    Functions used in index expressions and partial-index + predicates are evaluated whenever a new table entry is made. It has + long been understood that this poses a risk of trojan-horse code + execution if one modifies a table owned by an untrustworthy user. + (Note that triggers, defaults, check constraints, etc. pose the + same type of risk.) But functions in indexes pose extra danger + because they will be executed by routine maintenance operations + such as VACUUM FULL, which are commonly performed + automatically under a superuser account. For example, a nefarious user + can execute code with superuser privileges by setting up a + trojan-horse index definition and waiting for the next routine vacuum. + The fix arranges for standard maintenance operations + (including VACUUM, ANALYZE, REINDEX, + and CLUSTER) to execute as the table owner rather than + the calling user, using the same privilege-switching mechanism already + used for SECURITY DEFINER functions. To prevent bypassing + this security measure, execution of SET SESSION + AUTHORIZATION and SET ROLE is now forbidden within a + SECURITY DEFINER context. (CVE-2007-6600) +

  • Repair assorted bugs in the regular-expression package (Tom, Will Drewry) +

    Suitably crafted regular-expression patterns could cause crashes, + infinite or near-infinite looping, and/or massive memory consumption, + all of which pose denial-of-service hazards for applications that + accept regex search patterns from untrustworthy sources. + (CVE-2007-4769, CVE-2007-4772, CVE-2007-6067) +

  • Require non-superusers who use /contrib/dblink to use only + password authentication, as a security measure (Joe) +

    The fix that appeared for this in 7.4.18 was incomplete, as it plugged + the hole for only some dblink functions. (CVE-2007-6601, + CVE-2007-3278) +

  • Fix planner failure in some cases of WHERE false AND var IN + (SELECT ...) (Tom) +

  • Fix potential crash in translate() when using a multibyte + database encoding (Tom) +

  • Fix PL/Python to not crash on long exception messages (Alvaro) +

  • ecpg parser fixes (Michael) +

  • Make contrib/tablefunc's crosstab() handle + NULL rowid as a category in its own right, rather than crashing (Joe) +

  • Fix tsvector and tsquery output routines to + escape backslashes correctly (Teodor, Bruce) +

  • Fix crash of to_tsvector() on huge input strings (Teodor) +

  • Require a specific version of Autoconf to be used + when re-generating the configure script (Peter) +

    This affects developers and packagers only. The change was made + to prevent accidental use of untested combinations of + Autoconf and PostgreSQL versions. + You can remove the version check if you really want to use a + different Autoconf version, but it's + your responsibility whether the result works or not. +


PrevHomeNext
Release 7.4.20UpRelease 7.4.18
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-2.html b/doc/src/sgml/html/release-7-4-2.html new file mode 100644 index 000000000..670db1eab --- /dev/null +++ b/doc/src/sgml/html/release-7-4-2.html @@ -0,0 +1,466 @@ + +Release 7.4.2

E.166. Release 7.4.2

Release Date: 2004-03-08

This release contains a variety of fixes from 7.4.1. + For information about new features in the 7.4 major release, see + Section E.168. +

E.166.1. Migration to Version 7.4.2

A dump/restore is not required for those running 7.4.X. However, + it might be advisable as the easiest method of incorporating fixes for + two errors that have been found in the initial contents of 7.4.X system + catalogs. A dump/initdb/reload sequence using 7.4.2's initdb will + automatically correct these problems. +

The more severe of the two errors is that data type anyarray + has the wrong alignment label; this is a problem because the + pg_statistic system catalog uses anyarray + columns. The mislabeling can cause planner misestimations and even + crashes when planning queries that involve WHERE clauses on + double-aligned columns (such as float8 and timestamp). + It is strongly recommended that all installations repair this error, + either by initdb or by following the manual repair procedure given + below. +

The lesser error is that the system view pg_settings + ought to be marked as having public update access, to allow + UPDATE pg_settings to be used as a substitute for + SET. This can also be fixed either by initdb or manually, + but it is not necessary to fix unless you want to use UPDATE + pg_settings. +

If you wish not to do an initdb, the following procedure will work + for fixing pg_statistic. As the database superuser, + do: + +

-- clear out old data in pg_statistic:
+DELETE FROM pg_statistic;
+VACUUM pg_statistic;
+-- this should update 1 row:
+UPDATE pg_type SET typalign = 'd' WHERE oid = 2277;
+-- this should update 6 rows:
+UPDATE pg_attribute SET attalign = 'd' WHERE atttypid = 2277;
+--
+-- At this point you MUST start a fresh backend to avoid a crash!
+--
+-- repopulate pg_statistic:
+ANALYZE;

+ + This can be done in a live database, but beware that all backends + running in the altered database must be restarted before it is safe to + repopulate pg_statistic. +

To repair the pg_settings error, simply do: +

GRANT SELECT, UPDATE ON pg_settings TO PUBLIC;

+

The above procedures must be carried out in each database + of an installation, including template1, and ideally + including template0 as well. If you do not fix the + template databases then any subsequently created databases will contain + the same errors. template1 can be fixed in the same way + as any other database, but fixing template0 requires + additional steps. First, from any database issue: +

UPDATE pg_database SET datallowconn = true WHERE datname = 'template0';

+ Next connect to template0 and perform the above repair + procedures. Finally, do: +

-- re-freeze template0:
+VACUUM FREEZE;
+-- and protect it against future alterations:
+UPDATE pg_database SET datallowconn = false WHERE datname = 'template0';

+

E.166.2. Changes

Release 7.4.2 incorporates all the fixes included in release 7.3.6, + plus the following fixes:

  • Fix pg_statistics alignment bug that could crash optimizer

    See above for details about this problem.

  • Allow non-super users to update pg_settings

  • Fix several optimizer bugs, most of which led to +"variable not found in subplan target lists" errors

  • Avoid out-of-memory failure during startup of large multiple +index scan

  • Fix multibyte problem that could lead to "out of +memory" error during COPY IN

  • Fix problems with SELECT INTO / CREATE +TABLE AS from tables without OIDs

  • Fix problems with alter_table regression test +during parallel testing

  • Fix problems with hitting open file limit, especially on OS X (Tom)

  • Partial fix for Turkish-locale issues

    initdb will succeed now in Turkish locale, but there are still some +inconveniences associated with the i/I problem.

  • Make pg_dump set client encoding on restore

  • Other minor pg_dump fixes

  • Allow ecpg to again use C keywords as column names (Michael)

  • Added ecpg WHENEVER NOT_FOUND to +SELECT/INSERT/UPDATE/DELETE (Michael)

  • Fix ecpg crash for queries calling set-returning functions (Michael)

  • Various other ecpg fixes (Michael)

  • Fixes for Borland compiler

  • Thread build improvements (Bruce)

  • Various other build fixes

  • Various JDBC fixes


PrevHomeNext
Release 7.4.3UpRelease 7.4.1
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-20.html b/doc/src/sgml/html/release-7-4-20.html new file mode 100644 index 000000000..17761f738 --- /dev/null +++ b/doc/src/sgml/html/release-7-4-20.html @@ -0,0 +1,385 @@ + +Release 7.4.20

E.148. Release 7.4.20

Release Date: never released

This release contains a variety of fixes from 7.4.19. + For information about new features in the 7.4 major release, see + Section E.168. +

E.148.1. Migration to Version 7.4.20

A dump/restore is not required for those running 7.4.X. + However, if you are upgrading from a version earlier than 7.4.11, + see the release notes for 7.4.11. +

E.148.2. Changes

  • Fix conversions between ISO-8859-5 and other encodings to handle + Cyrillic "Yo" characters (e and E with + two dots) (Sergey Burladyan) +

  • Fix a few datatype input functions + that were allowing unused bytes in their results to contain + uninitialized, unpredictable values (Tom) +

    This could lead to failures in which two apparently identical literal + values were not seen as equal, resulting in the parser complaining + about unmatched ORDER BY and DISTINCT + expressions. +

  • Fix a corner case in regular-expression substring matching + (substring(string from + pattern)) (Tom) +

    The problem occurs when there is a match to the pattern overall but + the user has specified a parenthesized subexpression and that + subexpression hasn't got a match. An example is + substring('foo' from 'foo(bar)?'). + This should return NULL, since (bar) isn't matched, but + it was mistakenly returning the whole-pattern match instead (ie, + foo). +

  • Fix incorrect result from ecpg's + PGTYPEStimestamp_sub() function (Michael) +

  • Fix DatumGetBool macro to not fail with gcc + 4.3 (Tom) +

    This problem affects "old style" (V0) C functions that + return boolean. The fix is already in 8.3, but the need to + back-patch it was not realized at the time. +

  • Fix longstanding LISTEN/NOTIFY + race condition (Tom) +

    In rare cases a session that had just executed a + LISTEN might not get a notification, even though + one would be expected because the concurrent transaction executing + NOTIFY was observed to commit later. +

    A side effect of the fix is that a transaction that has executed + a not-yet-committed LISTEN command will not see any + row in pg_listener for the LISTEN, + should it choose to look; formerly it would have. This behavior + was never documented one way or the other, but it is possible that + some applications depend on the old behavior. +

  • Fix display of constant expressions in ORDER BY + and GROUP BY (Tom) +

    An explicitly casted constant would be shown incorrectly. This could + for example lead to corruption of a view definition during + dump and reload. +

  • Fix libpq to handle NOTICE messages correctly + during COPY OUT (Tom) +

    This failure has only been observed to occur when a user-defined + datatype's output routine issues a NOTICE, but there is no + guarantee it couldn't happen due to other causes. +


PrevHomeNext
Release 7.4.21UpRelease 7.4.19
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-21.html b/doc/src/sgml/html/release-7-4-21.html new file mode 100644 index 000000000..41f48d2f5 --- /dev/null +++ b/doc/src/sgml/html/release-7-4-21.html @@ -0,0 +1,243 @@ + +Release 7.4.21

E.147. Release 7.4.21

Release Date: 2008-06-12

This release contains one serious bug fix over 7.4.20. + For information about new features in the 7.4 major release, see + Section E.168. +

E.147.1. Migration to Version 7.4.21

A dump/restore is not required for those running 7.4.X. + However, if you are upgrading from a version earlier than 7.4.11, + see the release notes for 7.4.11. +

E.147.2. Changes

  • Make pg_get_ruledef() parenthesize negative constants (Tom) +

    Before this fix, a negative constant in a view or rule might be dumped + as, say, -42::integer, which is subtly incorrect: it should + be (-42)::integer due to operator precedence rules. + Usually this would make little difference, but it could interact with + another recent patch to cause + PostgreSQL to reject what had been a valid + SELECT DISTINCT view query. Since this could result in + pg_dump output failing to reload, it is being treated + as a high-priority fix. The only released versions in which dump + output is actually incorrect are 8.3.1 and 8.2.7. +


PrevHomeNext
Release 7.4.22UpRelease 7.4.20
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-22.html b/doc/src/sgml/html/release-7-4-22.html new file mode 100644 index 000000000..9bf7b7d5c --- /dev/null +++ b/doc/src/sgml/html/release-7-4-22.html @@ -0,0 +1,266 @@ + +Release 7.4.22

E.146. Release 7.4.22

Release Date: 2008-09-22

This release contains a variety of fixes from 7.4.21. + For information about new features in the 7.4 major release, see + Section E.168. +

E.146.1. Migration to Version 7.4.22

A dump/restore is not required for those running 7.4.X. + However, if you are upgrading from a version earlier than 7.4.11, + see the release notes for 7.4.11. +

E.146.2. Changes

  • Fix datetime input functions to correctly detect integer overflow when + running on a 64-bit platform (Tom) +

  • Improve performance of writing very long log messages to syslog (Tom) +

  • Fix bug in backwards scanning of a cursor on a SELECT DISTINCT + ON query (Tom) +

  • Fix planner to estimate that GROUP BY expressions yielding + boolean results always result in two groups, regardless of the + expressions' contents (Tom) +

    This is very substantially more accurate than the regular GROUP + BY estimate for certain boolean tests like col + IS NULL. +

  • Improve pg_dump and pg_restore's + error reporting after failure to send a SQL command (Tom) +


PrevHomeNext
Release 7.4.23UpRelease 7.4.21
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-23.html b/doc/src/sgml/html/release-7-4-23.html new file mode 100644 index 000000000..8e67d2a31 --- /dev/null +++ b/doc/src/sgml/html/release-7-4-23.html @@ -0,0 +1,268 @@ + +Release 7.4.23

E.145. Release 7.4.23

Release Date: 2008-11-03

This release contains a variety of fixes from 7.4.22. + For information about new features in the 7.4 major release, see + Section E.168. +

E.145.1. Migration to Version 7.4.23

A dump/restore is not required for those running 7.4.X. + However, if you are upgrading from a version earlier than 7.4.11, + see the release notes for 7.4.11. +

E.145.2. Changes

  • Fix backend crash when the client encoding cannot represent a localized + error message (Tom) +

    We have addressed similar issues before, but it would still fail if + the "character has no equivalent" message itself couldn't + be converted. The fix is to disable localization and send the plain + ASCII error message when we detect such a situation. +

  • Fix incorrect tsearch2 headline generation when single query + item matches first word of text (Sushant Sinha) +

  • Fix improper display of fractional seconds in interval values when + using a non-ISO datestyle in an --enable-integer-datetimes + build (Ron Mayer) +

  • Ensure SPI_getvalue and SPI_getbinval + behave correctly when the passed tuple and tuple descriptor have + different numbers of columns (Tom) +

    This situation is normal when a table has had columns added or removed, + but these two functions didn't handle it properly. + The only likely consequence is an incorrect error indication. +

  • Fix ecpg's parsing of CREATE USER (Michael) +


PrevHomeNext
Release 7.4.24UpRelease 7.4.22
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-24.html b/doc/src/sgml/html/release-7-4-24.html new file mode 100644 index 000000000..d6a534473 --- /dev/null +++ b/doc/src/sgml/html/release-7-4-24.html @@ -0,0 +1,285 @@ + +Release 7.4.24

E.144. Release 7.4.24

Release Date: 2009-02-02

This release contains a variety of fixes from 7.4.23. + For information about new features in the 7.4 major release, see + Section E.168. +

E.144.1. Migration to Version 7.4.24

A dump/restore is not required for those running 7.4.X. + However, if you are upgrading from a version earlier than 7.4.11, + see the release notes for 7.4.11. +

E.144.2. Changes

  • Improve handling of URLs in headline() function (Teodor) +

  • Improve handling of overlength headlines in headline() + function (Teodor) +

  • Prevent possible Assert failure or misconversion if an encoding + conversion is created with the wrong conversion function for the + specified pair of encodings (Tom, Heikki) +

  • Avoid unnecessary locking of small tables in VACUUM + (Heikki) +

  • Fix uninitialized variables in contrib/tsearch2's + get_covers() function (Teodor) +

  • Fix bug in to_char()'s handling of TH + format codes (Andreas Scherbaum) +

  • Make all documentation reference pgsql-bugs and/or + pgsql-hackers as appropriate, instead of the + now-decommissioned pgsql-ports and pgsql-patches + mailing lists (Tom) +


PrevHomeNext
Release 7.4.25UpRelease 7.4.23
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-25.html b/doc/src/sgml/html/release-7-4-25.html new file mode 100644 index 000000000..d4f8dc9bb --- /dev/null +++ b/doc/src/sgml/html/release-7-4-25.html @@ -0,0 +1,262 @@ + +Release 7.4.25

E.143. Release 7.4.25

Release Date: 2009-03-16

This release contains a variety of fixes from 7.4.24. + For information about new features in the 7.4 major release, see + Section E.168. +

E.143.1. Migration to Version 7.4.25

A dump/restore is not required for those running 7.4.X. + However, if you are upgrading from a version earlier than 7.4.11, + see the release notes for 7.4.11. +

E.143.2. Changes

  • Prevent error recursion crashes when encoding conversion fails (Tom) +

    This change extends fixes made in the last two minor releases for + related failure scenarios. The previous fixes were narrowly tailored + for the original problem reports, but we have now recognized that + any error thrown by an encoding conversion function could + potentially lead to infinite recursion while trying to report the + error. The solution therefore is to disable translation and encoding + conversion and report the plain-ASCII form of any error message, + if we find we have gotten into a recursive error reporting situation. + (CVE-2009-0922) +

  • Disallow CREATE CONVERSION with the wrong encodings + for the specified conversion function (Heikki) +

    This prevents one possible scenario for encoding conversion failure. + The previous change is a backstop to guard against other kinds of + failures in the same area. +

  • Fix core dump when to_char() is given format codes that + are inappropriate for the type of the data argument (Tom) +

  • Add MUST (Mauritius Island Summer Time) to the default list + of known timezone abbreviations (Xavier Bugaud) +


PrevHomeNext
Release 7.4.26UpRelease 7.4.24
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-26.html b/doc/src/sgml/html/release-7-4-26.html new file mode 100644 index 000000000..e7da302b9 --- /dev/null +++ b/doc/src/sgml/html/release-7-4-26.html @@ -0,0 +1,338 @@ + +Release 7.4.26

E.142. Release 7.4.26

Release Date: 2009-09-09

This release contains a variety of fixes from 7.4.25. + For information about new features in the 7.4 major release, see + Section E.168. +

E.142.1. Migration to Version 7.4.26

A dump/restore is not required for those running 7.4.X. + However, if you have any hash indexes on interval columns, + you must REINDEX them after updating to 7.4.26. + Also, if you are upgrading from a version earlier than 7.4.11, + see the release notes for 7.4.11. +

E.142.2. Changes

  • Disallow RESET ROLE and RESET SESSION + AUTHORIZATION inside security-definer functions (Tom, Heikki) +

    This covers a case that was missed in the previous patch that + disallowed SET ROLE and SET SESSION + AUTHORIZATION inside security-definer functions. + (See CVE-2007-6600) +

  • Fix handling of sub-SELECTs appearing in the arguments of + an outer-level aggregate function (Tom) +

  • Fix hash calculation for data type interval (Tom) +

    This corrects wrong results for hash joins on interval values. + It also changes the contents of hash indexes on interval columns. + If you have any such indexes, you must REINDEX them + after updating. +

  • Fix overflow for INTERVAL 'x ms' + when x is more than 2 million and integer + datetimes are in use (Alex Hunsaker) +

  • Fix calculation of distance between a point and a line segment (Tom) +

    This led to incorrect results from a number of geometric operators. +

  • Fix money data type to work in locales where currency + amounts have no fractional digits, e.g. Japan (Itagaki Takahiro) +

  • Properly round datetime input like + 00:12:57.9999999999999999999999999999 (Tom) +

  • Fix poor choice of page split point in GiST R-tree operator classes + (Teodor) +

  • Fix portability issues in plperl initialization (Andrew Dunstan) +

  • Improve robustness of libpq's code to recover + from errors during COPY FROM STDIN (Tom) +

  • Avoid including conflicting readline and editline header files + when both libraries are installed (Zdenek Kotala) +


PrevHomeNext
Release 7.4.27UpRelease 7.4.25
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-27.html b/doc/src/sgml/html/release-7-4-27.html new file mode 100644 index 000000000..524e0b5e2 --- /dev/null +++ b/doc/src/sgml/html/release-7-4-27.html @@ -0,0 +1,301 @@ + +Release 7.4.27

E.141. Release 7.4.27

Release Date: 2009-12-14

This release contains a variety of fixes from 7.4.26. + For information about new features in the 7.4 major release, see + Section E.168. +

E.141.1. Migration to Version 7.4.27

A dump/restore is not required for those running 7.4.X. + However, if you are upgrading from a version earlier than 7.4.26, + see the release notes for 7.4.26. +

E.141.2. Changes

  • Protect against indirect security threats caused by index functions + changing session-local state (Gurjeet Singh, Tom) +

    This change prevents allegedly-immutable index functions from possibly + subverting a superuser's session (CVE-2009-4136). +

  • Reject SSL certificates containing an embedded null byte in the common + name (CN) field (Magnus) +

    This prevents unintended matching of a certificate to a server or client + name during SSL validation (CVE-2009-4034). +

  • Fix possible crash during backend-startup-time cache initialization (Tom) +

  • Prevent signals from interrupting VACUUM at unsafe times + (Alvaro) +

    This fix prevents a PANIC if a VACUUM FULL is canceled + after it's already committed its tuple movements, as well as transient + errors if a plain VACUUM is interrupted after having + truncated the table. +

  • Fix possible crash due to integer overflow in hash table size + calculation (Tom) +

    This could occur with extremely large planner estimates for the size of + a hashjoin's result. +

  • Fix very rare crash in inet/cidr comparisons (Chris + Mikkelson) +

  • Fix PAM password processing to be more robust (Tom) +

    The previous code is known to fail with the combination of the Linux + pam_krb5 PAM module with Microsoft Active Directory as the + domain controller. It might have problems elsewhere too, since it was + making unjustified assumptions about what arguments the PAM stack would + pass to it. +

  • Make the postmaster ignore any application_name parameter in + connection request packets, to improve compatibility with future libpq + versions (Tom) +


PrevHomeNext
Release 7.4.28UpRelease 7.4.26
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-28.html b/doc/src/sgml/html/release-7-4-28.html new file mode 100644 index 000000000..40ef5e277 --- /dev/null +++ b/doc/src/sgml/html/release-7-4-28.html @@ -0,0 +1,325 @@ + +Release 7.4.28

E.140. Release 7.4.28

Release Date: 2010-03-15

This release contains a variety of fixes from 7.4.27. + For information about new features in the 7.4 major release, see + Section E.168. +

The PostgreSQL community will stop releasing updates + for the 7.4.X release series in July 2010. + Users are encouraged to update to a newer release branch soon. +

E.140.1. Migration to Version 7.4.28

A dump/restore is not required for those running 7.4.X. + However, if you are upgrading from a version earlier than 7.4.26, + see the release notes for 7.4.26. +

E.140.2. Changes

  • Add new configuration parameter ssl_renegotiation_limit to + control how often we do session key renegotiation for an SSL connection + (Magnus) +

    This can be set to zero to disable renegotiation completely, which may + be required if a broken SSL library is used. In particular, some + vendors are shipping stopgap patches for CVE-2009-3555 that cause + renegotiation attempts to fail. +

  • Make substring() for bit types treat any negative + length as meaning "all the rest of the string" (Tom) +

    The previous coding treated only -1 that way, and would produce an + invalid result value for other negative values, possibly leading to + a crash (CVE-2010-0442). +

  • Fix some cases of pathologically slow regular expression matching (Tom) +

  • When reading pg_hba.conf and related files, do not treat + @something as a file inclusion request if the @ + appears inside quote marks; also, never treat @ by itself + as a file inclusion request (Tom) +

    This prevents erratic behavior if a role or database name starts with + @. If you need to include a file whose path name + contains spaces, you can still do so, but you must write + @"/path to/file" rather than putting the quotes around + the whole construct. +

  • Prevent infinite loop on some platforms if a directory is named as + an inclusion target in pg_hba.conf and related files + (Tom) +

  • Ensure PL/Tcl initializes the Tcl interpreter fully (Tom) +

    The only known symptom of this oversight is that the Tcl + clock command misbehaves if using Tcl 8.5 or later. +

  • Prevent crash in contrib/dblink when too many key + columns are specified to a dblink_build_sql_* function + (Rushabh Lathia, Joe Conway) +


PrevHomeNext
Release 7.4.29UpRelease 7.4.27
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-29.html b/doc/src/sgml/html/release-7-4-29.html new file mode 100644 index 000000000..047fc503c --- /dev/null +++ b/doc/src/sgml/html/release-7-4-29.html @@ -0,0 +1,369 @@ + +Release 7.4.29

E.139. Release 7.4.29

Release Date: 2010-05-17

This release contains a variety of fixes from 7.4.28. + For information about new features in the 7.4 major release, see + Section E.168. +

The PostgreSQL community will stop releasing updates + for the 7.4.X release series in July 2010. + Users are encouraged to update to a newer release branch soon. +

E.139.1. Migration to Version 7.4.29

A dump/restore is not required for those running 7.4.X. + However, if you are upgrading from a version earlier than 7.4.26, + see the release notes for 7.4.26. +

E.139.2. Changes

  • Enforce restrictions in plperl using an opmask applied to + the whole interpreter, instead of using Safe.pm + (Tim Bunce, Andrew Dunstan) +

    Recent developments have convinced us that Safe.pm is too + insecure to rely on for making plperl trustable. This + change removes use of Safe.pm altogether, in favor of using + a separate interpreter with an opcode mask that is always applied. + Pleasant side effects of the change include that it is now possible to + use Perl's strict pragma in a natural way in + plperl, and that Perl's $a and $b + variables work as expected in sort routines, and that function + compilation is significantly faster. (CVE-2010-1169) +

  • Prevent PL/Tcl from executing untrustworthy code from + pltcl_modules (Tom) +

    PL/Tcl's feature for autoloading Tcl code from a database table + could be exploited for trojan-horse attacks, because there was no + restriction on who could create or insert into that table. This change + disables the feature unless pltcl_modules is owned by a + superuser. (However, the permissions on the table are not checked, so + installations that really need a less-than-secure modules table can + still grant suitable privileges to trusted non-superusers.) Also, + prevent loading code into the unrestricted "normal" Tcl + interpreter unless we are really going to execute a pltclu + function. (CVE-2010-1170) +

  • Do not allow an unprivileged user to reset superuser-only parameter + settings (Alvaro) +

    Previously, if an unprivileged user ran ALTER USER ... RESET + ALL for himself, or ALTER DATABASE ... RESET ALL for + a database he owns, this would remove all special parameter settings + for the user or database, even ones that are only supposed to be + changeable by a superuser. Now, the ALTER will only + remove the parameters that the user has permission to change. +

  • Avoid possible crash during backend shutdown if shutdown occurs + when a CONTEXT addition would be made to log entries (Tom) +

    In some cases the context-printing function would fail because the + current transaction had already been rolled back when it came time + to print a log message. +

  • Update pl/perl's ppport.h for modern Perl versions + (Andrew) +

  • Fix assorted memory leaks in pl/python (Andreas Freund, Tom) +

  • Ensure that contrib/pgstattuple functions respond to cancel + interrupts promptly (Tatsuhito Kasahara) +

  • Make server startup deal properly with the case that + shmget() returns EINVAL for an existing + shared memory segment (Tom) +

    This behavior has been observed on BSD-derived kernels including OS X. + It resulted in an entirely-misleading startup failure complaining that + the shared memory request size was too large. +


PrevHomeNext
Release 7.4.30UpRelease 7.4.28
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-3.html b/doc/src/sgml/html/release-7-4-3.html new file mode 100644 index 000000000..5ce8da544 --- /dev/null +++ b/doc/src/sgml/html/release-7-4-3.html @@ -0,0 +1,293 @@ + +Release 7.4.3

E.165. Release 7.4.3

Release Date: 2004-06-14

This release contains a variety of fixes from 7.4.2. + For information about new features in the 7.4 major release, see + Section E.168. +

E.165.1. Migration to Version 7.4.3

A dump/restore is not required for those running 7.4.X. +

E.165.2. Changes

  • Fix temporary memory leak when using non-hashed aggregates (Tom)

  • ECPG fixes, including some for Informix compatibility (Michael)

  • Fixes for compiling with thread-safety, particularly Solaris (Bruce)

  • Fix error in COPY IN termination when using the old network protocol (ljb)

  • Several important fixes in pg_autovacuum, including fixes for +large tables, unsigned oids, stability, temp tables, and debug mode +(Matthew T. O'Connor)

  • Fix problem with reading tar-format dumps on NetBSD and BSD/OS (Bruce)

  • Several JDBC fixes

  • Fix ALTER SEQUENCE RESTART where last_value equals the restart value (Tom)

  • Repair failure to recalculate nested sub-selects (Tom)

  • Fix problems with non-constant expressions in LIMIT/OFFSET

  • Support FULL JOIN with no join clause, such as X FULL JOIN Y ON TRUE (Tom)

  • Fix another zero-column table bug (Tom)

  • Improve handling of non-qualified identifiers in GROUP BY clauses in sub-selects (Tom)

    Select-list aliases within the sub-select will now take precedence over +names from outer query levels.

  • Do not generate "NATURAL CROSS JOIN" when decompiling rules (Tom)

  • Add checks for invalid field length in binary COPY (Tom)

    This fixes a difficult-to-exploit security hole.

  • Avoid locking conflict between ANALYZE and LISTEN/NOTIFY

  • Numerous translation updates (various contributors)


PrevHomeNext
Release 7.4.4UpRelease 7.4.2
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-30.html b/doc/src/sgml/html/release-7-4-30.html new file mode 100644 index 000000000..d1b231760 --- /dev/null +++ b/doc/src/sgml/html/release-7-4-30.html @@ -0,0 +1,317 @@ + +Release 7.4.30

E.138. Release 7.4.30

Release Date: 2010-10-04

This release contains a variety of fixes from 7.4.29. + For information about new features in the 7.4 major release, see + Section E.168. +

This is expected to be the last PostgreSQL release + in the 7.4.X series. Users are encouraged to update to a newer + release branch soon. +

E.138.1. Migration to Version 7.4.30

A dump/restore is not required for those running 7.4.X. + However, if you are upgrading from a version earlier than 7.4.26, + see the release notes for 7.4.26. +

E.138.2. Changes

  • Use a separate interpreter for each calling SQL userid in PL/Perl and + PL/Tcl (Tom Lane) +

    This change prevents security problems that can be caused by subverting + Perl or Tcl code that will be executed later in the same session under + another SQL user identity (for example, within a SECURITY + DEFINER function). Most scripting languages offer numerous ways that + that might be done, such as redefining standard functions or operators + called by the target function. Without this change, any SQL user with + Perl or Tcl language usage rights can do essentially anything with the + SQL privileges of the target function's owner. +

    The cost of this change is that intentional communication among Perl + and Tcl functions becomes more difficult. To provide an escape hatch, + PL/PerlU and PL/TclU functions continue to use only one interpreter + per session. This is not considered a security issue since all such + functions execute at the trust level of a database superuser already. +

    It is likely that third-party procedural languages that claim to offer + trusted execution have similar security issues. We advise contacting + the authors of any PL you are depending on for security-critical + purposes. +

    Our thanks to Tim Bunce for pointing out this issue (CVE-2010-3433). +

  • Prevent possible crashes in pg_get_expr() by disallowing + it from being called with an argument that is not one of the system + catalog columns it's intended to be used with + (Heikki Linnakangas, Tom Lane) +

  • Fix "cannot handle unplanned sub-select" error (Tom Lane) +

    This occurred when a sub-select contains a join alias reference that + expands into an expression containing another sub-select. +

  • Take care to fsync the contents of lockfiles (both + postmaster.pid and the socket lockfile) while writing them + (Tom Lane) +

    This omission could result in corrupted lockfile contents if the + machine crashes shortly after postmaster start. That could in turn + prevent subsequent attempts to start the postmaster from succeeding, + until the lockfile is manually removed. +

  • Improve contrib/dblink's handling of tables containing + dropped columns (Tom Lane) +

  • Fix connection leak after "duplicate connection name" + errors in contrib/dblink (Itagaki Takahiro) +

  • Update build infrastructure and documentation to reflect the source code + repository's move from CVS to Git (Magnus Hagander and others) +


PrevHomeNext
Release 8.0UpRelease 7.4.29
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-4.html b/doc/src/sgml/html/release-7-4-4.html new file mode 100644 index 000000000..a09aabc02 --- /dev/null +++ b/doc/src/sgml/html/release-7-4-4.html @@ -0,0 +1,270 @@ + +Release 7.4.4

E.164. Release 7.4.4

Release Date: 2004-08-16

This release contains a variety of fixes from 7.4.3. + For information about new features in the 7.4 major release, see + Section E.168. +

E.164.1. Migration to Version 7.4.4

A dump/restore is not required for those running 7.4.X. +

E.164.2. Changes

  • Prevent possible loss of committed transactions during crash

    Due to insufficient interlocking between transaction commit and checkpointing, +it was possible for transactions committed just before the most recent +checkpoint to be lost, in whole or in part, following a database crash and +restart. This is a serious bug that has existed +since PostgreSQL 7.1.

  • Check HAVING restriction before evaluating result list of an +aggregate plan

  • Avoid crash when session's current user ID is deleted

  • Fix hashed crosstab for zero-rows case (Joe)

  • Force cache update after renaming a column in a foreign key

  • Pretty-print UNION queries correctly

  • Make psql handle \r\n newlines properly in COPY IN

  • pg_dump handled ACLs with grant options incorrectly

  • Fix thread support for OS X and Solaris

  • Updated JDBC driver (build 215) with various fixes

  • ECPG fixes

  • Translation updates (various contributors)


PrevHomeNext
Release 7.4.5UpRelease 7.4.3
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-5.html b/doc/src/sgml/html/release-7-4-5.html new file mode 100644 index 000000000..2dfa30906 --- /dev/null +++ b/doc/src/sgml/html/release-7-4-5.html @@ -0,0 +1,214 @@ + +Release 7.4.5

E.163. Release 7.4.5

Release Date: 2004-08-18

This release contains one serious bug fix over 7.4.4. + For information about new features in the 7.4 major release, see + Section E.168. +

E.163.1. Migration to Version 7.4.5

A dump/restore is not required for those running 7.4.X. +

E.163.2. Changes

  • Repair possible crash during concurrent B-tree index insertions

    This patch fixes a rare case in which concurrent insertions into a B-tree index +could result in a server panic. No permanent damage would result, but it's +still worth a re-release. The bug does not exist in pre-7.4 releases.


PrevHomeNext
Release 7.4.6UpRelease 7.4.4
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-6.html b/doc/src/sgml/html/release-7-4-6.html new file mode 100644 index 000000000..133acb686 --- /dev/null +++ b/doc/src/sgml/html/release-7-4-6.html @@ -0,0 +1,299 @@ + +Release 7.4.6

E.162. Release 7.4.6

Release Date: 2004-10-22

This release contains a variety of fixes from 7.4.5. + For information about new features in the 7.4 major release, see + Section E.168. +

E.162.1. Migration to Version 7.4.6

A dump/restore is not required for those running 7.4.X. +

E.162.2. Changes

  • Repair possible failure to update hint bits on disk

    Under rare circumstances this oversight could lead to +"could not access transaction status" failures, which qualifies +it as a potential-data-loss bug.

  • Ensure that hashed outer join does not miss tuples

    Very large left joins using a hash join plan could fail to output unmatched +left-side rows given just the right data distribution.

  • Disallow running pg_ctl as root

    This is to guard against any possible security issues.

  • Avoid using temp files in /tmp in make_oidjoins_check

    This has been reported as a security issue, though it's hardly worthy of +concern since there is no reason for non-developers to use this script anyway.

  • Prevent forced backend shutdown from re-emitting prior command +result

    In rare cases, a client might think that its last command had succeeded when +it really had been aborted by forced database shutdown.

  • Repair bug in pg_stat_get_backend_idset

    This could lead to misbehavior in some of the system-statistics views.

  • Fix small memory leak in postmaster

  • Fix "expected both swapped tables to have TOAST +tables" bug

    This could arise in cases such as CLUSTER after ALTER TABLE DROP COLUMN.

  • Prevent pg_ctl restart from adding -D multiple times

  • Fix problem with NULL values in GiST indexes

  • :: is no longer interpreted as a variable in an +ECPG prepare statement


PrevHomeNext
Release 7.4.7UpRelease 7.4.5
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-7.html b/doc/src/sgml/html/release-7-4-7.html new file mode 100644 index 000000000..b46504cd9 --- /dev/null +++ b/doc/src/sgml/html/release-7-4-7.html @@ -0,0 +1,267 @@ + +Release 7.4.7

E.161. Release 7.4.7

Release Date: 2005-01-31

This release contains a variety of fixes from 7.4.6, including several + security-related issues. + For information about new features in the 7.4 major release, see + Section E.168. +

E.161.1. Migration to Version 7.4.7

A dump/restore is not required for those running 7.4.X. +

E.161.2. Changes

  • Disallow LOAD to non-superusers

    On platforms that will automatically execute initialization functions of a +shared library (this includes at least Windows and ELF-based Unixen), +LOAD can be used to make the server execute arbitrary code. +Thanks to NGS Software for reporting this.

  • Check that creator of an aggregate function has the right to +execute the specified transition functions

    This oversight made it possible to bypass denial of EXECUTE +permission on a function.

  • Fix security and 64-bit issues in +contrib/intagg

  • Add needed STRICT marking to some contrib functions (Kris +Jurka)

  • Avoid buffer overrun when plpgsql cursor declaration has too +many parameters (Neil)

  • Fix planning error for FULL and RIGHT outer joins

    The result of the join was mistakenly supposed to be sorted the same as the +left input. This could not only deliver mis-sorted output to the user, but +in case of nested merge joins could give outright wrong answers.

  • Fix plperl for quote marks in tuple fields

  • Fix display of negative intervals in SQL and GERMAN +datestyles

  • Make age(timestamptz) do calculation in local timezone not +GMT


PrevHomeNext
Release 7.4.8UpRelease 7.4.6
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-8.html b/doc/src/sgml/html/release-7-4-8.html new file mode 100644 index 000000000..07ed87813 --- /dev/null +++ b/doc/src/sgml/html/release-7-4-8.html @@ -0,0 +1,532 @@ + +Release 7.4.8

E.160. Release 7.4.8

Release Date: 2005-05-09

This release contains a variety of fixes from 7.4.7, including several + security-related issues. + For information about new features in the 7.4 major release, see + Section E.168. +

E.160.1. Migration to Version 7.4.8

A dump/restore is not required for those running 7.4.X. However, + it is one possible way of handling two significant security problems + that have been found in the initial contents of 7.4.X system + catalogs. A dump/initdb/reload sequence using 7.4.8's initdb will + automatically correct these problems. +

The larger security problem is that the built-in character set encoding + conversion functions can be invoked from SQL commands by unprivileged + users, but the functions were not designed for such use and are not + secure against malicious choices of arguments. The fix involves changing + the declared parameter list of these functions so that they can no longer + be invoked from SQL commands. (This does not affect their normal use + by the encoding conversion machinery.) +

The lesser problem is that the contrib/tsearch2 module + creates several functions that are misdeclared to return + internal when they do not accept internal arguments. + This breaks type safety for all functions using internal + arguments. +

It is strongly recommended that all installations repair these errors, + either by initdb or by following the manual repair procedures given + below. The errors at least allow unprivileged database users to crash + their server process, and might allow unprivileged users to gain the + privileges of a database superuser. +

If you wish not to do an initdb, perform the following procedures instead. + As the database superuser, do: + +

BEGIN;
+UPDATE pg_proc SET proargtypes[3] = 'internal'::regtype
+WHERE pronamespace = 11 AND pronargs = 5
+     AND proargtypes[2] = 'cstring'::regtype;
+-- The command should report having updated 90 rows;
+-- if not, rollback and investigate instead of committing!
+COMMIT;

+ + Next, if you have installed contrib/tsearch2, do: + +

BEGIN;
+UPDATE pg_proc SET proargtypes[0] = 'internal'::regtype
+WHERE oid IN (
+   'dex_init(text)'::regprocedure,
+   'snb_en_init(text)'::regprocedure,
+   'snb_ru_init(text)'::regprocedure,
+   'spell_init(text)'::regprocedure,
+   'syn_init(text)'::regprocedure
+);
+-- The command should report having updated 5 rows;
+-- if not, rollback and investigate instead of committing!
+COMMIT;

+ + If this command fails with a message like "function + "dex_init(text)" does not exist", then either tsearch2 + is not installed in this database, or you already did the update. +

The above procedures must be carried out in each database + of an installation, including template1, and ideally + including template0 as well. If you do not fix the + template databases then any subsequently created databases will contain + the same errors. template1 can be fixed in the same way + as any other database, but fixing template0 requires + additional steps. First, from any database issue: +

UPDATE pg_database SET datallowconn = true WHERE datname = 'template0';

+ Next connect to template0 and perform the above repair + procedures. Finally, do: +

-- re-freeze template0:
+VACUUM FREEZE;
+-- and protect it against future alterations:
+UPDATE pg_database SET datallowconn = false WHERE datname = 'template0';

+

E.160.2. Changes

  • Change encoding function signature to prevent +misuse

  • Change contrib/tsearch2 to avoid unsafe use of +INTERNAL function results

  • Repair ancient race condition that allowed a transaction to be +seen as committed for some purposes (eg SELECT FOR UPDATE) slightly sooner +than for other purposes

    This is an extremely serious bug since it could lead to apparent +data inconsistencies being briefly visible to applications.

  • Repair race condition between relation extension and +VACUUM

    This could theoretically have caused loss of a page's worth of +freshly-inserted data, although the scenario seems of very low probability. +There are no known cases of it having caused more than an Assert failure.

  • Fix comparisons of TIME WITH TIME ZONE values

    The comparison code was wrong in the case where the +--enable-integer-datetimes configuration switch had been used. +NOTE: if you have an index on a TIME WITH TIME ZONE column, +it will need to be REINDEXed after installing this update, because +the fix corrects the sort order of column values.

  • Fix EXTRACT(EPOCH) for +TIME WITH TIME ZONE values

  • Fix mis-display of negative fractional seconds in +INTERVAL values

    This error only occurred when the +--enable-integer-datetimes configuration switch had been used.

  • Ensure operations done during backend shutdown are counted by +statistics collector

    This is expected to resolve reports of pg_autovacuum +not vacuuming the system catalogs often enough — it was not being +told about catalog deletions caused by temporary table removal during +backend exit.

  • Additional buffer overrun checks in plpgsql +(Neil)

  • Fix pg_dump to dump trigger names containing % +correctly (Neil)

  • Fix contrib/pgcrypto for newer OpenSSL builds +(Marko Kreen)

  • Still more 64-bit fixes for +contrib/intagg

  • Prevent incorrect optimization of functions returning +RECORD

  • Prevent to_char(interval) from dumping core for +month-related formats

  • Prevent crash on COALESCE(NULL,NULL)

  • Fix array_map to call PL functions correctly

  • Fix permission checking in ALTER DATABASE RENAME

  • Fix ALTER LANGUAGE RENAME

  • Make RemoveFromWaitQueue clean up after itself

    This fixes a lock management error that would only be visible if a transaction +was kicked out of a wait for a lock (typically by query cancel) and then the +holder of the lock released it within a very narrow window.

  • Fix problem with untyped parameter appearing in +INSERT ... SELECT

  • Fix CLUSTER failure after +ALTER TABLE SET WITHOUT OIDS


PrevHomeNext
Release 7.4.9UpRelease 7.4.7
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4-9.html b/doc/src/sgml/html/release-7-4-9.html new file mode 100644 index 000000000..0814aaff5 --- /dev/null +++ b/doc/src/sgml/html/release-7-4-9.html @@ -0,0 +1,339 @@ + +Release 7.4.9

E.159. Release 7.4.9

Release Date: 2005-10-04

This release contains a variety of fixes from 7.4.8. + For information about new features in the 7.4 major release, see + Section E.168. +

E.159.1. Migration to Version 7.4.9

A dump/restore is not required for those running 7.4.X. However, + if you are upgrading from a version earlier than 7.4.8, see the release + notes for 7.4.8. +

E.159.2. Changes

  • Fix error that allowed VACUUM to remove +ctid chains too soon, and add more checking in code that follows +ctid links

    This fixes a long-standing problem that could cause crashes in very rare +circumstances.

  • Fix CHAR() to properly pad spaces to the specified +length when using a multiple-byte character set (Yoshiyuki Asaba)

    In prior releases, the padding of CHAR() was incorrect +because it only padded to the specified number of bytes without +considering how many characters were stored.

  • Fix the sense of the test for read-only transaction +in COPY

    The code formerly prohibited COPY TO, where it should +prohibit COPY FROM.

  • Fix planning problem with outer-join ON clauses that reference +only the inner-side relation

  • Further fixes for x FULL JOIN y ON true corner +cases

  • Make array_in and array_recv more +paranoid about validating their OID parameter

  • Fix missing rows in queries like UPDATE a=... WHERE +a... with GiST index on column a

  • Improve robustness of datetime parsing

  • Improve checking for partially-written WAL +pages

  • Improve robustness of signal handling when SSL is +enabled

  • Don't try to open more than max_files_per_process +files during postmaster startup

  • Various memory leakage fixes

  • Various portability improvements

  • Fix PL/pgSQL to handle var := var correctly when +the variable is of pass-by-reference type

  • Update contrib/tsearch2 to use current Snowball +code


PrevHomeNext
Release 7.4.10UpRelease 7.4.8
\ No newline at end of file diff --git a/doc/src/sgml/html/release-7-4.html b/doc/src/sgml/html/release-7-4.html new file mode 100644 index 000000000..27fa9f07f --- /dev/null +++ b/doc/src/sgml/html/release-7-4.html @@ -0,0 +1,3322 @@ + +Release 7.4

E.168. Release 7.4

Release Date: 2003-11-17

E.168.1. Overview

Major changes in this release: +

IN / NOT IN subqueries are + now much more efficient

In previous releases, IN/NOT + IN subqueries were joined to the upper query by + sequentially scanning the subquery looking for a match. The + 7.4 code uses the same sophisticated techniques used by + ordinary joins and so is much faster. An + IN will now usually be as fast as or faster + than an equivalent EXISTS subquery; this + reverses the conventional wisdom that applied to previous + releases. +

Improved GROUP BY processing by using hash buckets

In previous releases, rows to be grouped had to be sorted + first. The 7.4 code can do GROUP BY + without sorting, by accumulating results into a hash table + with one entry per group. It will still use the sort + technique, however, if the hash table is estimated to be too + large to fit in sort_mem. +

New multikey hash join capability

In previous releases, hash joins could only occur on single + keys. This release allows multicolumn hash joins. +

Queries using the explicit JOIN syntax are + now better optimized

Prior releases evaluated queries using the explicit + JOIN syntax only in the order implied by + the syntax. 7.4 allows full optimization of these queries, + meaning the optimizer considers all possible join orderings + and chooses the most efficient. Outer joins, however, must + still follow the declared ordering. +

Faster and more powerful regular expression code

The entire regular expression module has been replaced with a + new version by Henry Spencer, originally written for Tcl. The + code greatly improves performance and supports several flavors + of regular expressions. +

Function-inlining for simple SQL functions

Simple SQL functions can now be inlined by including their SQL + in the main query. This improves performance by eliminating + per-call overhead. That means simple SQL functions now + behave like macros. +

Full support for IPv6 connections and IPv6 address data types

Previous releases allowed only IPv4 connections, and the IP + data types only supported IPv4 addresses. This release adds + full IPv6 support in both of these areas. +

Major improvements in SSL performance and reliability

Several people very familiar with the SSL API have overhauled + our SSL code to improve SSL key negotiation and error + recovery. +

Make free space map efficiently reuse empty index pages, + and other free space management improvements

In previous releases, B-tree index pages that were left empty + because of deleted rows could only be reused by rows with + index values similar to the rows originally indexed on that + page. In 7.4, VACUUM records empty index + pages and allows them to be reused for any future index rows. +

SQL-standard information schema

The information schema provides a standardized and stable way + to access information about the schema objects defined in a + database. +

Cursors conform more closely to the SQL standard

The commands FETCH and + MOVE have been overhauled to conform more + closely to the SQL standard. +

Cursors can exist outside transactions

These cursors are also called holdable cursors. +

New client-to-server protocol

The new protocol adds error codes, more status information, + faster startup, better support for binary data transmission, + parameter values separated from SQL commands, prepared + statements available at the protocol level, and cleaner + recovery from COPY failures. The older + protocol is still supported by both server and clients. +

libpq and + ECPG applications are now fully + thread-safe

While previous libpq releases + already supported threads, this release improves thread safety + by fixing some non-thread-safe code that was used during + database connection startup. The configure + option --enable-thread-safety must be used to + enable this feature. +

New version of full-text indexing

A new full-text indexing suite is available in + contrib/tsearch2. +

New autovacuum tool

The new autovacuum tool in + contrib/autovacuum monitors the database + statistics tables for + INSERT/UPDATE/DELETE + activity and automatically vacuums tables when needed. +

Array handling has been improved and moved into the server core

Many array limitations have been removed, and arrays behave + more like fully-supported data types. +

E.168.2. Migration to Version 7.4

A dump/restore using pg_dump is + required for those wishing to migrate data from any previous + release. +

Observe the following incompatibilities: +

  • The server-side autocommit setting was removed and + reimplemented in client applications and languages. + Server-side autocommit was causing too many problems with + languages and applications that wanted to control their own + autocommit behavior, so autocommit was removed from the server + and added to individual client APIs as appropriate. +

  • Error message wording has changed substantially in this + release. Significant effort was invested to make the messages + more consistent and user-oriented. If your applications try to + detect different error conditions by parsing the error message, + you are strongly encouraged to use the new error code facility instead. +

  • Inner joins using the explicit JOIN syntax + might behave differently because they are now better + optimized. +

  • A number of server configuration parameters have been renamed + for clarity, primarily those related to + logging. +

  • FETCH 0 or MOVE 0 now + does nothing. In prior releases, FETCH 0 + would fetch all remaining rows, and MOVE 0 + would move to the end of the cursor. +

  • FETCH and MOVE now return + the actual number of rows fetched/moved, or zero if at the + beginning/end of the cursor. Prior releases would return the + row count passed to the command, not the number of rows + actually fetched or moved. +

  • COPY now can process files that use + carriage-return or carriage-return/line-feed end-of-line + sequences. Literal carriage-returns and line-feeds are no + longer accepted in data values; use \r and + \n instead. +

  • Trailing spaces are now trimmed when converting from type + char(n) to + varchar(n) or text. + This is what most people always expected to happen anyway. +

  • The data type float(p) now + measures p in binary digits, not decimal + digits. The new behavior follows the SQL standard. +

  • Ambiguous date values now must match the ordering specified by + the datestyle setting. In prior releases, a + date specification of 10/20/03 was interpreted as a + date in October even if datestyle specified that + the day should be first. 7.4 will throw an error if a date + specification is invalid for the current setting of + datestyle. +

  • The functions oidrand, + oidsrand, and + userfntest have been removed. These + functions were determined to be no longer useful. +

  • String literals specifying time-varying date/time values, such + as 'now' or 'today' will + no longer work as expected in column default expressions; they + now cause the time of the table creation to be the default, not + the time of the insertion. Functions such as + now(), current_timestamp, or + current_date should be used instead. +

    In previous releases, there was special code so that strings + such as 'now' were interpreted at + INSERT time and not at table creation time, but + this work around didn't cover all cases. Release 7.4 now + requires that defaults be defined properly using functions such + as now() or current_timestamp. These + will work in all situations. +

  • The dollar sign ($) is no longer allowed in + operator names. It can instead be a non-first character in + identifiers. This was done to improve compatibility with other + database systems, and to avoid syntax problems when parameter + placeholders ($n) are written + adjacent to operators. +

E.168.3. Changes

Below you will find a detailed account of the changes between + release 7.4 and the previous major release. +

E.168.3.1. Server Operation Changes

  • Allow IPv6 server connections (Nigel Kukard, Johan Jordaan, + Bruce, Tom, Kurt Roeckx, Andrew Dunstan) +

  • Fix SSL to handle errors cleanly (Nathan Mueller) +

    In prior releases, certain SSL API error reports were not + handled correctly. This release fixes those problems. +

  • SSL protocol security and performance improvements (Sean Chittenden) +

    SSL key renegotiation was happening too frequently, causing poor + SSL performance. Also, initial key handling was improved. +

  • Print lock information when a deadlock is detected (Tom) +

    This allows easier debugging of deadlock situations. +

  • Update /tmp socket modification times + regularly to avoid their removal (Tom) +

    This should help prevent /tmp directory + cleaner administration scripts from removing server socket + files. +

  • Enable PAM for Mac OS X (Aaron Hillegass)

  • Make B-tree indexes fully WAL-safe (Tom)

    In prior releases, under certain rare cases, a server crash + could cause B-tree indexes to become corrupt. This release + removes those last few rare cases. +

  • Allow B-tree index compaction and empty page reuse (Tom)

  • Fix inconsistent index lookups during split of first root page (Tom) +

    In prior releases, when a single-page index split into two + pages, there was a brief period when another database session + could miss seeing an index entry. This release fixes that rare + failure case. +

  • Improve free space map allocation logic (Tom)

  • Preserve free space information between server restarts (Tom)

    In prior releases, the free space map was not saved when the + postmaster was stopped, so newly started servers had no free + space information. This release saves the free space map, and + reloads it when the server is restarted. +

  • Add start time to pg_stat_activity (Neil)

  • New code to detect corrupt disk pages; erase with zero_damaged_pages (Tom)

  • New client/server protocol: faster, no username length limit, allow clean exit from COPY (Tom)

  • Add transaction status, table ID, column ID to client/server protocol (Tom)

  • Add binary I/O to client/server protocol (Tom)

  • Remove autocommit server setting; move to client applications (Tom)

  • New error message wording, error codes, and three levels of error detail (Tom, Joe, Peter)

E.168.3.2. Performance Improvements

  • Add hashing for GROUP BY aggregates (Tom)

  • Make nested-loop joins be smarter about multicolumn indexes (Tom)

  • Allow multikey hash joins (Tom)

  • Improve constant folding (Tom)

  • Add ability to inline simple SQL functions (Tom)

  • Reduce memory usage for queries using complex functions (Tom)

    In prior releases, functions returning allocated memory would + not free it until the query completed. This release allows the + freeing of function-allocated memory when the function call + completes, reducing the total memory used by functions. +

  • Improve GEQO optimizer performance (Tom)

    This release fixes several inefficiencies in the way the GEQO optimizer + manages potential query paths. +

  • Allow IN/NOT IN to be handled via hash + tables (Tom) +

  • Improve NOT IN (subquery) + performance (Tom) +

  • Allow most IN subqueries to be processed as + joins (Tom) +

  • Pattern matching operations can use indexes regardless of + locale (Peter) +

    There is no way for non-ASCII locales to use the standard + indexes for LIKE comparisons. This release + adds a way to create a special index for + LIKE. +

  • Allow the postmaster to preload libraries using preload_libraries (Joe)

    For shared libraries that require a long time to load, this + option is available so the library can be preloaded in the + postmaster and inherited by all database sessions. +

  • Improve optimizer cost computations, particularly for subqueries (Tom) +

  • Avoid sort when subquery ORDER BY matches upper query (Tom) +

  • Deduce that WHERE a.x = b.y AND b.y = 42 also + means a.x = 42 (Tom) +

  • Allow hash/merge joins on complex joins (Tom) +

  • Allow hash joins for more data types (Tom) +

  • Allow join optimization of explicit inner joins, disable with + join_collapse_limit (Tom) +

  • Add parameter from_collapse_limit to control + conversion of subqueries to joins (Tom) +

  • Use faster and more powerful regular expression code from Tcl + (Henry Spencer, Tom) +

  • Use bit-mapped relation sets in the optimizer (Tom) +

  • Improve connection startup time (Tom)

    The new client/server protocol requires fewer network packets to + start a database session. +

  • Improve trigger/constraint performance (Stephan) +

  • Improve speed of col IN (const, const, const, ...) (Tom) +

  • Fix hash indexes which were broken in rare cases (Tom) +

  • Improve hash index concurrency and speed (Tom)

    Prior releases suffered from poor hash index performance, + particularly for high concurrency situations. This release fixes + that, and the development group is interested in reports + comparing B-tree and hash index performance. +

  • Align shared buffers on 32-byte boundary for copy speed improvement (Manfred Spraul)

    Certain CPU's perform faster data copies when addresses are + 32-byte aligned. +

  • Data type numeric reimplemented for better performance (Tom)

    numeric used to be stored in base 100. The new code + uses base 10000, for significantly better performance. +

E.168.3.3. Server Configuration Changes

  • Rename server parameter server_min_messages to log_min_messages (Bruce)

    This was done so most parameters that control the server logs + begin with log_. +

  • Rename show_*_stats to log_*_stats (Bruce)

  • Rename show_source_port to log_source_port (Bruce)

  • Rename hostname_lookup to log_hostname (Bruce)

  • Add checkpoint_warning to warn of excessive checkpointing (Bruce)

    In prior releases, it was difficult to determine if checkpoint + was happening too frequently. This feature adds a warning to the + server logs when excessive checkpointing happens. +

  • New read-only server parameters for localization (Tom)

  • Change debug server log messages to output as DEBUG + rather than LOG (Bruce) +

  • Prevent server log variables from being turned off by non-superusers (Bruce)

    This is a security feature so non-superusers cannot disable + logging that was enabled by the administrator. +

  • log_min_messages/client_min_messages now + controls debug_* output (Bruce) +

    This centralizes client debug information so all debug output + can be sent to either the client or server logs. +

  • Add Mac OS X Rendezvous server support (Chris Campbell)

    This allows Mac OS X hosts to query the network for available + PostgreSQL servers. +

  • Add ability to print only slow statements using + log_min_duration_statement + (Christopher) +

    This is an often requested debugging feature that allows + administrators to see only slow queries in their server logs. +

  • Allow pg_hba.conf to accept netmasks in CIDR format (Andrew Dunstan)

    This allows administrators to merge the host IP address and + netmask fields into a single CIDR field in pg_hba.conf. +

  • New read-only parameter is_superuser (Tom)

  • New parameter log_error_verbosity to control error detail (Tom)

    This works with the new error reporting feature to supply + additional error information like hints, file names and line + numbers. +

  • postgres --describe-config now dumps server config variables (Aizaz Ahmed, Peter)

    This option is useful for administration tools that need to know + the configuration variable names and their minimums, maximums, + defaults, and descriptions. +

  • Add new columns in pg_settings: + context, type, source, + min_val, max_val (Joe) +

  • Make default shared_buffers 1000 and + max_connections 100, if possible (Tom) +

    Prior versions defaulted to 64 shared buffers so PostgreSQL + would start on even very old systems. This release tests the + amount of shared memory allowed by the platform and selects more + reasonable default values if possible. Of course, users are + still encouraged to evaluate their resource load and size + shared_buffers accordingly. +

  • New pg_hba.conf record type + hostnossl to prevent SSL connections (Jon + Jensen) +

    In prior releases, there was no way to prevent SSL connections + if both the client and server supported SSL. This option allows + that capability. +

  • Remove parameter geqo_random_seed + (Tom) +

  • Add server parameter regex_flavor to control regular expression processing (Tom) +

  • Make pg_ctl better handle nonstandard ports (Greg) +

E.168.3.4. Query Changes

  • New SQL-standard information schema (Peter)

  • Add read-only transactions (Peter)

  • Print key name and value in foreign-key violation messages (Dmitry Tkach)

  • Allow users to see their own queries in pg_stat_activity (Kevin Brown)

    In prior releases, only the superuser could see query strings + using pg_stat_activity. Now ordinary users + can see their own query strings. +

  • Fix aggregates in subqueries to match SQL standard (Tom)

    The SQL standard says that an aggregate function appearing + within a nested subquery belongs to the outer query if its + argument contains only outer-query variables. Prior + PostgreSQL releases did not handle + this fine point correctly. +

  • Add option to prevent auto-addition of tables referenced in query (Nigel J. Andrews)

    By default, tables mentioned in the query are automatically + added to the FROM clause if they are not already + there. This is compatible with historic + POSTGRES behavior but is contrary to + the SQL standard. This option allows selecting + standard-compatible behavior. +

  • Allow UPDATE ... SET col = DEFAULT (Rod)

    This allows UPDATE to set a column to its + declared default value. +

  • Allow expressions to be used in LIMIT/OFFSET (Tom)

    In prior releases, LIMIT/OFFSET could + only use constants, not expressions. +

  • Implement CREATE TABLE AS EXECUTE (Neil, Peter)

E.168.3.5. Object Manipulation Changes

  • Make CREATE SEQUENCE grammar more conforming to SQL:2003 (Neil)

  • Add statement-level triggers (Neil)

    While this allows a trigger to fire at the end of a statement, + it does not allow the trigger to access all rows modified by the + statement. This capability is planned for a future release. +

  • Add check constraints for domains (Rod)

    This greatly increases the usefulness of domains by allowing + them to use check constraints. +

  • Add ALTER DOMAIN (Rod)

    This allows manipulation of existing domains. +

  • Fix several zero-column table bugs (Tom)

    PostgreSQL supports zero-column tables. This fixes various bugs + that occur when using such tables. +

  • Have ALTER TABLE ... ADD PRIMARY KEY add not-null constraint (Rod)

    In prior releases, ALTER TABLE ... ADD + PRIMARY would add a unique index, but not a not-null + constraint. That is fixed in this release. +

  • Add ALTER TABLE ... WITHOUT OIDS (Rod)

    This allows control over whether new and updated rows will have + an OID column. This is most useful for saving storage space. +

  • Add ALTER SEQUENCE to modify minimum, maximum, + increment, cache, cycle values (Rod) +

  • Add ALTER TABLE ... CLUSTER ON (Alvaro Herrera)

    This command is used by pg_dump to record the + cluster column for each table previously clustered. This + information is used by database-wide cluster to cluster all + previously clustered tables. +

  • Improve automatic type casting for domains (Rod, Tom)

  • Allow dollar signs in identifiers, except as first character (Tom)

  • Disallow dollar signs in operator names, so x=$1 works (Tom)

  • Allow copying table schema using LIKE + subtable, also SQL:2003 + feature INCLUDING DEFAULTS (Rod) +

  • Add WITH GRANT OPTION clause to + GRANT (Peter) +

    This enabled GRANT to give other users the + ability to grant privileges on a object. +

E.168.3.6. Utility Command Changes

  • Add ON COMMIT clause to CREATE TABLE for temporary tables (Gavin)

    This adds the ability for a table to be dropped or all rows + deleted on transaction commit. +

  • Allow cursors outside transactions using WITH HOLD (Neil)

    In previous releases, cursors were removed at the end of the + transaction that created them. Cursors can now be created with + the WITH HOLD option, which allows them to + continue to be accessed after the creating transaction has + committed. +

  • FETCH 0 and MOVE 0 now do nothing (Bruce)

    In previous releases, FETCH 0 fetched all + remaining rows, and MOVE 0 moved to the end + of the cursor. +

  • Cause FETCH and MOVE to + return the number of rows fetched/moved, or zero if at the + beginning/end of cursor, per SQL standard (Bruce) +

    In prior releases, the row count returned by + FETCH and MOVE did not + accurately reflect the number of rows processed. +

  • Properly handle SCROLL with cursors, or + report an error (Neil)

    Allowing random access (both forward and backward scrolling) to + some kinds of queries cannot be done without some additional + work. If SCROLL is specified when the cursor + is created, this additional work will be performed. Furthermore, + if the cursor has been created with NO SCROLL, + no random access is allowed. +

  • Implement SQL-compatible options FIRST, + LAST, ABSOLUTE n, + RELATIVE n for + FETCH and MOVE (Tom) +

  • Allow EXPLAIN on DECLARE CURSOR (Tom)

  • Allow CLUSTER to use index marked as pre-clustered by default (Alvaro Herrera)

  • Allow CLUSTER to cluster all tables (Alvaro Herrera)

    This allows all previously clustered tables in a database to be + reclustered with a single command. +

  • Prevent CLUSTER on partial indexes (Tom)

  • Allow DOS and Mac line-endings in COPY files (Bruce)

  • Disallow literal carriage return as a data value, + backslash-carriage-return and \r are still allowed + (Bruce) +

  • COPY changes (binary, \.) (Tom)

  • Recover from COPY failure cleanly (Tom)

  • Prevent possible memory leaks in COPY (Tom)

  • Make TRUNCATE transaction-safe (Rod)

    TRUNCATE can now be used inside a + transaction. If the transaction aborts, the changes made by the + TRUNCATE are automatically rolled back. +

  • Allow prepare/bind of utility commands like + FETCH and EXPLAIN (Tom) +

  • Add EXPLAIN EXECUTE (Neil)

  • Improve VACUUM performance on indexes by reducing WAL traffic (Tom)

  • Functional indexes have been generalized into indexes on expressions (Tom)

    In prior releases, functional indexes only supported a simple + function applied to one or more column names. This release + allows any type of scalar expression. +

  • Have SHOW TRANSACTION ISOLATION match input + to SET TRANSACTION ISOLATION + (Tom) +

  • Have COMMENT ON DATABASE on nonlocal + database generate a warning, rather than an error (Rod) +

    Database comments are stored in database-local tables so + comments on a database have to be stored in each database. +

  • Improve reliability of LISTEN/NOTIFY (Tom) +

  • Allow REINDEX to reliably reindex nonshared system catalog indexes (Tom)

    This allows system tables to be reindexed without the + requirement of a standalone session, which was necessary in + previous releases. The only tables that now require a standalone + session for reindexing are the global system tables + pg_database, pg_shadow, and + pg_group. +

E.168.3.7. Data Type and Function Changes

  • New server parameter extra_float_digits to + control precision display of floating-point numbers (Pedro + Ferreira, Tom) +

    This controls output precision which was causing regression + testing problems. +

  • Allow +1300 as a numeric time-zone specifier, for FJST (Tom)

  • Remove rarely used functions oidrand, + oidsrand, and userfntest functions + (Neil) +

  • Add md5() function to main server, already in contrib/pgcrypto (Joe)

    An MD5 function was frequently requested. For more complex + encryption capabilities, use + contrib/pgcrypto. +

  • Increase date range of timestamp (John Cochran)

  • Change EXTRACT(EPOCH FROM timestamp) so + timestamp without time zone is assumed to be in + local time, not GMT (Tom) +

  • Trap division by zero in case the operating system doesn't prevent it (Tom)

  • Change the numeric data type internally to base 10000 (Tom)

  • New hostmask() function (Greg Wickham)

  • Fixes for to_char() and to_timestamp() (Karel)

  • Allow functions that can take any argument data type and return + any data type, using anyelement and + anyarray (Joe) +

    This allows the creation of functions that can work with any + data type. +

  • Arrays can now be specified as ARRAY[1,2,3], + ARRAY[['a','b'],['c','d']], or + ARRAY[ARRAY[ARRAY[2]]] (Joe) +

  • Allow proper comparisons for arrays, including ORDER + BY and DISTINCT support + (Joe) +

  • Allow indexes on array columns (Joe)

  • Allow array concatenation with || (Joe)

  • Allow WHERE qualification + expr op ANY/SOME/ALL + (array_expr) (Joe) +

    This allows arrays to behave like a list of values, for purposes + like SELECT * FROM tab WHERE col IN + (array_val). +

  • New array functions array_append, + array_cat, array_lower, + array_prepend, array_to_string, + array_upper, string_to_array (Joe) +

  • Allow user defined aggregates to use polymorphic functions (Joe)

  • Allow assignments to empty arrays (Joe)

  • Allow 60 in seconds fields of time, + timestamp, and interval input values + (Tom) +

    Sixty-second values are needed for leap seconds. +

  • Allow cidr data type to be cast to text (Tom)

  • Disallow invalid time zone names in SET TIMEZONE

  • Trim trailing spaces when char is cast to + varchar or text (Tom) +

  • Make float(p) measure the precision + p in binary digits, not decimal digits + (Tom) +

  • Add IPv6 support to the inet and cidr data types (Michael Graff)

  • Add family() function to report whether address is IPv4 or IPv6 (Michael Graff)

  • Have SHOW datestyle generate output similar + to that used by SET datestyle (Tom) +

  • Make EXTRACT(TIMEZONE) and SET/SHOW + TIME ZONE follow the SQL convention for the sign of + time zone offsets, i.e., positive is east from UTC (Tom) +

  • Fix date_trunc('quarter', ...) (Böjthe Zoltán)

    Prior releases returned an incorrect value for this function call. +

  • Make initcap() more compatible with Oracle (Mike Nolan)

    initcap() now uppercases a letter appearing + after any non-alphanumeric character, rather than only after + whitespace. +

  • Allow only datestyle field order for date values not in ISO-8601 format (Greg)

  • Add new datestyle values MDY, + DMY, and YMD to set input field order; + honor US and European for backward + compatibility (Tom) +

  • String literals like 'now' or + 'today' will no longer work as a column + default. Use functions such as now(), + current_timestamp instead. (change + required for prepared statements) (Tom) +

  • Treat NaN as larger than any other value in min()/max() (Tom)

    NaN was already sorted after ordinary numeric values for most + purposes, but min() and max() didn't + get this right. +

  • Prevent interval from suppressing :00 + seconds display

  • New functions pg_get_triggerdef(prettyprint) + and pg_conversion_is_visible() (Christopher) +

  • Allow time to be specified as 040506 or 0405 (Tom)

  • Input date order must now be YYYY-MM-DD (with 4-digit year) or + match datestyle +

  • Make pg_get_constraintdef support + unique, primary-key, and check constraints (Christopher) +

E.168.3.8. Server-Side Language Changes

  • Prevent PL/pgSQL crash when RETURN NEXT is + used on a zero-row record variable (Tom) +

  • Make PL/Python's spi_execute interface + handle null values properly (Andrew Bosma) +

  • Allow PL/pgSQL to declare variables of composite types without %ROWTYPE (Tom)

  • Fix PL/Python's _quote() function to handle big integers

  • Make PL/Python an untrusted language, now called plpythonu (Kevin Jacobs, Tom)

    The Python language no longer supports a restricted execution + environment, so the trusted version of PL/Python was removed. If + this situation changes, a version of PL/Python that can be used + by non-superusers will be readded. +

  • Allow polymorphic PL/pgSQL functions (Joe, Tom)

  • Allow polymorphic SQL functions (Joe)

  • Improved compiled function caching mechanism in PL/pgSQL with + full support for polymorphism (Joe) +

  • Add new parameter $0 in PL/pgSQL representing the + function's actual return type (Joe) +

  • Allow PL/Tcl and PL/Python to use the same trigger on multiple tables (Tom) +

  • Fixed PL/Tcl's spi_prepare to accept fully + qualified type names in the parameter type list + (Jan) +

E.168.3.9. psql Changes

  • Add \pset pager always to always use pager (Greg)

    This forces the pager to be used even if the number of rows is + less than the screen height. This is valuable for rows that + wrap across several screen rows. +

  • Improve tab completion (Rod, Ross Reedstrom, Ian Barwick)

  • Reorder \? help into groupings (Harald Armin Massa, Bruce)

  • Add backslash commands for listing schemas, casts, and conversions (Christopher)

  • \encoding now changes based on the server parameter + client_encoding (Tom) +

    In previous versions, \encoding was not aware + of encoding changes made using SET + client_encoding. +

  • Save editor buffer into readline history (Ross)

    When \e is used to edit a query, the result is saved + in the readline history for retrieval using the up arrow. +

  • Improve \d display (Christopher)

  • Enhance HTML mode to be more standards-conforming (Greg)

  • New \set AUTOCOMMIT off capability (Tom)

    This takes the place of the removed server parameter autocommit. +

  • New \set VERBOSITY to control error detail (Tom)

    This controls the new error reporting details. +

  • New prompt escape sequence %x to show transaction status (Tom)

  • Long options for psql are now available on all platforms

E.168.3.10. pg_dump Changes

  • Multiple pg_dump fixes, including tar format and large objects

  • Allow pg_dump to dump specific schemas (Neil)

  • Make pg_dump preserve column storage characteristics (Christopher)

    This preserves ALTER TABLE ... SET STORAGE information. +

  • Make pg_dump preserve CLUSTER characteristics (Christopher)

  • Have pg_dumpall use GRANT/REVOKE to dump database-level privileges (Tom) +

  • Allow pg_dumpall to support the options -a, + -s, -x of pg_dump (Tom) +

  • Prevent pg_dump from lowercasing identifiers specified on the command line (Tom)

  • pg_dump options --use-set-session-authorization + and --no-reconnect now do nothing, all dumps + use SET SESSION AUTHORIZATION +

    pg_dump no longer reconnects to switch users, but instead always + uses SET SESSION AUTHORIZATION. This will + reduce password prompting during restores. +

  • Long options for pg_dump are now available on all platforms

    PostgreSQL now includes its own + long-option processing routines. +

E.168.3.11. libpq Changes

  • Add function PQfreemem for freeing memory on + Windows, suggested for NOTIFY (Bruce) +

    Windows requires that memory allocated in a library be freed by + a function in the same library, hence + free() doesn't work for freeing memory + allocated by libpq. PQfreemem is the proper + way to free libpq memory, especially on Windows, and is + recommended for other platforms as well. +

  • Document service capability, and add sample file (Bruce)

    This allows clients to look up connection information in a + central file on the client machine. +

  • Make PQsetdbLogin have the same defaults as + PQconnectdb (Tom) +

  • Allow libpq to cleanly fail when result sets are too large (Tom)

  • Improve performance of function PQunescapeBytea (Ben Lamb) +

  • Allow thread-safe libpq with configure + option --enable-thread-safety (Lee Kindness, + Philip Yarra) +

  • Allow function pqInternalNotice to accept a + format string and arguments instead of just a preformatted + message (Tom, Sean Chittenden) +

  • Control SSL negotiation with sslmode values + disable, allow, + prefer, and require (Jon + Jensen) +

  • Allow new error codes and levels of text (Tom)

  • Allow access to the underlying table and column of a query result (Tom)

    This is helpful for query-builder applications that want to know + the underlying table and column names associated with a specific + result set. +

  • Allow access to the current transaction status (Tom)

  • Add ability to pass binary data directly to the server (Tom)

  • Add function PQexecPrepared and + PQsendQueryPrepared functions which perform + bind/execute of previously prepared statements (Tom) +

E.168.3.12. JDBC Changes

  • Allow setNull on updateable result sets

  • Allow executeBatch on a prepared statement (Barry)

  • Support SSL connections (Barry)

  • Handle schema names in result sets (Paul Sorenson)

  • Add refcursor support (Nic Ferrier)

E.168.3.13. Miscellaneous Interface Changes

  • Prevent possible memory leak or core dump during libpgtcl shutdown (Tom)

  • Add Informix compatibility to ECPG (Michael)

    This allows ECPG to process embedded C programs that were + written using certain Informix extensions. +

  • Add type decimal to ECPG that is fixed length, for Informix (Michael)

  • Allow thread-safe embedded SQL programs with + configure option + --enable-thread-safety (Lee Kindness, Bruce) +

    This allows multiple threads to access the database at the same + time. +

  • Moved Python client PyGreSQL to http://www.pygresql.org (Marc)

E.168.3.14. Source Code Changes

  • Prevent need for separate platform geometry regression result files (Tom)

  • Improved PPC locking primitive (Reinhard Max)

  • New function palloc0 to allocate and clear memory (Bruce)

  • Fix locking code for s390x CPU (64-bit) (Tom)

  • Allow OpenBSD to use local ident credentials (William Ahern)

  • Make query plan trees read-only to executor (Tom)

  • Add Darwin startup scripts (David Wheeler)

  • Allow libpq to compile with Borland C++ compiler (Lester Godwin, Karl Waclawek)

  • Use our own version of getopt_long() if needed (Peter)

  • Convert administration scripts to C (Peter)

  • Bison >= 1.85 is now required to build the PostgreSQL grammar, if building from CVS

  • Merge documentation into one book (Peter)

  • Add Windows compatibility functions (Bruce)

  • Allow client interfaces to compile under MinGW (Bruce)

  • New ereport() function for error reporting (Tom)

  • Support Intel compiler on Linux (Peter)

  • Improve Linux startup scripts (Slawomir Sudnik, Darko Prenosil)

  • Add support for AMD Opteron and Itanium (Jeffrey W. Baker, Bruce)

  • Remove --enable-recode option from configure

    This was no longer needed now that we have CREATE CONVERSION. +

  • Generate a compile error if spinlock code is not found (Bruce)

    Platforms without spinlock code will now fail to compile, rather + than silently using semaphores. This failure can be disabled + with a new configure option. +

E.168.3.15. Contrib Changes

  • Change dbmirror license to BSD

  • Improve earthdistance (Bruno Wolff III)

  • Portability improvements to pgcrypto (Marko Kreen)

  • Prevent crash in xml (John Gray, Michael Richards)

  • Update oracle

  • Update mysql

  • Update cube (Bruno Wolff III)

  • Update earthdistance to use cube (Bruno Wolff III)

  • Update btree_gist (Oleg)

  • New tsearch2 full-text search module (Oleg, Teodor)

  • Add hash-based crosstab function to tablefuncs (Joe)

  • Add serial column to order connectby() siblings in tablefuncs (Nabil Sayegh,Joe)

  • Add named persistent connections to dblink (Shridhar Daithanka)

  • New pg_autovacuum allows automatic VACUUM (Matthew T. O'Connor)

  • Make pgbench honor environment variables PGHOST, PGPORT, PGUSER (Tatsuo)

  • Improve intarray (Teodor Sigaev)

  • Improve pgstattuple (Rod)

  • Fix bug in metaphone() in fuzzystrmatch

  • Improve adddepend (Rod)

  • Update spi/timetravel (Böjthe Zoltán)

  • Fix dbase -s option and improve non-ASCII handling (Thomas Behr, Márcio Smiderle)

  • Remove array module because features now included by default (Joe)


PrevHomeNext
Release 7.4.1UpRelease 7.3.21
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-1.html b/doc/src/sgml/html/release-8-0-1.html new file mode 100644 index 000000000..0cb55efee --- /dev/null +++ b/doc/src/sgml/html/release-8-0-1.html @@ -0,0 +1,302 @@ + +Release 8.0.1

E.136. Release 8.0.1

Release Date: 2005-01-31

This release contains a variety of fixes from 8.0.0, including several + security-related issues. + For information about new features in the 8.0 major release, see + Section E.137. +

E.136.1. Migration to Version 8.0.1

A dump/restore is not required for those running 8.0.0. +

E.136.2. Changes

  • Disallow LOAD to non-superusers

    On platforms that will automatically execute initialization functions of a +shared library (this includes at least Windows and ELF-based Unixen), +LOAD can be used to make the server execute arbitrary code. +Thanks to NGS Software for reporting this.

  • Check that creator of an aggregate function has the right to +execute the specified transition functions

    This oversight made it possible to bypass denial of EXECUTE +permission on a function.

  • Fix security and 64-bit issues in +contrib/intagg

  • Add needed STRICT marking to some contrib functions (Kris +Jurka)

  • Avoid buffer overrun when plpgsql cursor declaration has too +many parameters (Neil)

  • Make ALTER TABLE ADD COLUMN enforce domain +constraints in all cases

  • Fix planning error for FULL and RIGHT outer joins

    The result of the join was mistakenly supposed to be sorted the same as the +left input. This could not only deliver mis-sorted output to the user, but +in case of nested merge joins could give outright wrong answers.

  • Improve planning of grouped aggregate queries

  • ROLLBACK TO savepoint +closes cursors created since the savepoint

  • Fix inadequate backend stack size on Windows

  • Avoid SHGetSpecialFolderPath() on Windows +(Magnus)

  • Fix some problems in running pg_autovacuum as a Windows +service (Dave Page)

  • Multiple minor bug fixes in +pg_dump/pg_restore

  • Fix ecpg segfault with named structs used in +typedefs (Michael)


PrevHomeNext
Release 8.0.2UpRelease 8.0
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-10.html b/doc/src/sgml/html/release-8-0-10.html new file mode 100644 index 000000000..c1b7e7d27 --- /dev/null +++ b/doc/src/sgml/html/release-8-0-10.html @@ -0,0 +1,317 @@ + +Release 8.0.10

E.127. Release 8.0.10

Release Date: 2007-01-08

This release contains a variety of fixes from 8.0.9. + For information about new features in the 8.0 major release, see + Section E.137. +

E.127.1. Migration to Version 8.0.10

A dump/restore is not required for those running 8.0.X. However, + if you are upgrading from a version earlier than 8.0.6, see the release + notes for 8.0.6. +

E.127.2. Changes

  • Improve handling of getaddrinfo() on AIX (Tom) +

    This fixes a problem with starting the statistics collector, + among other things. +

  • Fix "failed to re-find parent key" errors in + VACUUM (Tom) +

  • Fix race condition for truncation of a large relation across a + gigabyte boundary by VACUUM (Tom) +

  • Fix bugs affecting multi-gigabyte hash indexes (Tom) +

  • Fix possible deadlock in Windows signal handling (Teodor) +

  • Fix error when constructing an ARRAY[] made up of multiple + empty elements (Tom) +

  • Fix ecpg memory leak during connection (Michael) +

  • to_number() and to_char(numeric) + are now STABLE, not IMMUTABLE, for + new initdb installs (Tom) +

    This is because lc_numeric can potentially + change the output of these functions. +

  • Improve index usage of regular expressions that use parentheses (Tom) +

    This improves psql \d performance also. +

  • Update timezone database +

    This affects Australian and Canadian daylight-savings rules in + particular. +


PrevHomeNext
Release 8.0.11UpRelease 8.0.9
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-11.html b/doc/src/sgml/html/release-8-0-11.html new file mode 100644 index 000000000..8498cf278 --- /dev/null +++ b/doc/src/sgml/html/release-8-0-11.html @@ -0,0 +1,243 @@ + +Release 8.0.11

E.126. Release 8.0.11

Release Date: 2007-02-05

This release contains a variety of fixes from 8.0.10, including + a security fix. + For information about new features in the 8.0 major release, see + Section E.137. +

E.126.1. Migration to Version 8.0.11

A dump/restore is not required for those running 8.0.X. However, + if you are upgrading from a version earlier than 8.0.6, see the release + notes for 8.0.6. +

E.126.2. Changes

  • Remove security vulnerabilities that allowed connected users + to read backend memory (Tom) +

    The vulnerabilities involve suppressing the normal check that a SQL + function returns the data type it's declared to, and changing the + data type of a table column (CVE-2007-0555, CVE-2007-0556). These + errors can easily be exploited to cause a backend crash, and in + principle might be used to read database content that the user + should not be able to access. +

  • Fix rare bug wherein btree index page splits could fail + due to choosing an infeasible split point (Heikki Linnakangas) +

  • Fix for rare Assert() crash triggered by UNION (Tom) +

  • Tighten security of multi-byte character processing for UTF8 sequences + over three bytes long (Tom) +


PrevHomeNext
Release 8.0.12UpRelease 8.0.10
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-12.html b/doc/src/sgml/html/release-8-0-12.html new file mode 100644 index 000000000..8dbce63fd --- /dev/null +++ b/doc/src/sgml/html/release-8-0-12.html @@ -0,0 +1,214 @@ + +Release 8.0.12

E.125. Release 8.0.12

Release Date: 2007-02-07

This release contains one fix from 8.0.11. + For information about new features in the 8.0 major release, see + Section E.137. +

E.125.1. Migration to Version 8.0.12

A dump/restore is not required for those running 8.0.X. However, + if you are upgrading from a version earlier than 8.0.6, see the release + notes for 8.0.6. +

E.125.2. Changes

  • Remove overly-restrictive check for type length in constraints and + functional indexes(Tom) +


PrevHomeNext
Release 8.0.13UpRelease 8.0.11
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-13.html b/doc/src/sgml/html/release-8-0-13.html new file mode 100644 index 000000000..2613426fe --- /dev/null +++ b/doc/src/sgml/html/release-8-0-13.html @@ -0,0 +1,263 @@ + +Release 8.0.13

E.124. Release 8.0.13

Release Date: 2007-04-23

This release contains a variety of fixes from 8.0.12, + including a security fix. + For information about new features in the 8.0 major release, see + Section E.137. +

E.124.1. Migration to Version 8.0.13

A dump/restore is not required for those running 8.0.X. However, + if you are upgrading from a version earlier than 8.0.6, see the release + notes for 8.0.6. +

E.124.2. Changes

  • Support explicit placement of the temporary-table schema within + search_path, and disable searching it for functions + and operators (Tom) +

    This is needed to allow a security-definer function to set a + truly secure value of search_path. Without it, + an unprivileged SQL user can use temporary objects to execute code + with the privileges of the security-definer function (CVE-2007-2138). + See CREATE FUNCTION for more information. +

  • /contrib/tsearch2 crash fixes (Teodor) +

  • Fix potential-data-corruption bug in how VACUUM FULL handles + UPDATE chains (Tom, Pavan Deolasee) +

  • Fix PANIC during enlargement of a hash index (bug introduced in 8.0.10) + (Tom) +

  • Fix POSIX-style timezone specs to follow new USA DST rules (Tom) +


PrevHomeNext
Release 8.0.14UpRelease 8.0.12
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-14.html b/doc/src/sgml/html/release-8-0-14.html new file mode 100644 index 000000000..bcc62c3e9 --- /dev/null +++ b/doc/src/sgml/html/release-8-0-14.html @@ -0,0 +1,291 @@ + +Release 8.0.14

E.123. Release 8.0.14

Release Date: 2007-09-17

This release contains a variety of fixes from 8.0.13. + For information about new features in the 8.0 major release, see + Section E.137. +

E.123.1. Migration to Version 8.0.14

A dump/restore is not required for those running 8.0.X. However, + if you are upgrading from a version earlier than 8.0.6, see the release + notes for 8.0.6. +

E.123.2. Changes

  • Prevent index corruption when a transaction inserts rows and + then aborts close to the end of a concurrent VACUUM + on the same table (Tom) +

  • Make CREATE DOMAIN ... DEFAULT NULL work properly (Tom) +

  • Fix excessive logging of SSL error messages (Tom) +

  • Fix logging so that log messages are never interleaved when using + the syslogger process (Andrew) +

  • Fix crash when log_min_error_statement logging runs out + of memory (Tom) +

  • Fix incorrect handling of some foreign-key corner cases (Tom) +

  • Prevent CLUSTER from failing + due to attempting to process temporary tables of other sessions (Alvaro) +

  • Update the time zone database rules, particularly New Zealand's upcoming changes (Tom) +

  • Windows socket improvements (Magnus) +

  • Suppress timezone name (%Z) in log timestamps on Windows + because of possible encoding mismatches (Tom) +

  • Require non-superusers who use /contrib/dblink to use only + password authentication, as a security measure (Joe) +


PrevHomeNext
Release 8.0.15UpRelease 8.0.13
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-15.html b/doc/src/sgml/html/release-8-0-15.html new file mode 100644 index 000000000..bfd7a9efd --- /dev/null +++ b/doc/src/sgml/html/release-8-0-15.html @@ -0,0 +1,476 @@ + +Release 8.0.15

E.122. Release 8.0.15

Release Date: 2008-01-07

This release contains a variety of fixes from 8.0.14, + including fixes for significant security issues. + For information about new features in the 8.0 major release, see + Section E.137. +

This is the last 8.0.X release for which the PostgreSQL + community will produce binary packages for Windows. + Windows users are encouraged to move to 8.2.X or later, + since there are Windows-specific fixes in 8.2.X that + are impractical to back-port. 8.0.X will continue to + be supported on other platforms. +

E.122.1. Migration to Version 8.0.15

A dump/restore is not required for those running 8.0.X. However, + if you are upgrading from a version earlier than 8.0.6, see the release + notes for 8.0.6. +

E.122.2. Changes

  • Prevent functions in indexes from executing with the privileges of + the user running VACUUM, ANALYZE, etc (Tom) +

    Functions used in index expressions and partial-index + predicates are evaluated whenever a new table entry is made. It has + long been understood that this poses a risk of trojan-horse code + execution if one modifies a table owned by an untrustworthy user. + (Note that triggers, defaults, check constraints, etc. pose the + same type of risk.) But functions in indexes pose extra danger + because they will be executed by routine maintenance operations + such as VACUUM FULL, which are commonly performed + automatically under a superuser account. For example, a nefarious user + can execute code with superuser privileges by setting up a + trojan-horse index definition and waiting for the next routine vacuum. + The fix arranges for standard maintenance operations + (including VACUUM, ANALYZE, REINDEX, + and CLUSTER) to execute as the table owner rather than + the calling user, using the same privilege-switching mechanism already + used for SECURITY DEFINER functions. To prevent bypassing + this security measure, execution of SET SESSION + AUTHORIZATION and SET ROLE is now forbidden within a + SECURITY DEFINER context. (CVE-2007-6600) +

  • Repair assorted bugs in the regular-expression package (Tom, Will Drewry) +

    Suitably crafted regular-expression patterns could cause crashes, + infinite or near-infinite looping, and/or massive memory consumption, + all of which pose denial-of-service hazards for applications that + accept regex search patterns from untrustworthy sources. + (CVE-2007-4769, CVE-2007-4772, CVE-2007-6067) +

  • Require non-superusers who use /contrib/dblink to use only + password authentication, as a security measure (Joe) +

    The fix that appeared for this in 8.0.14 was incomplete, as it plugged + the hole for only some dblink functions. (CVE-2007-6601, + CVE-2007-3278) +

  • Update time zone data files to tzdata release 2007k + (in particular, recent Argentina changes) (Tom) +

  • Fix planner failure in some cases of WHERE false AND var IN + (SELECT ...) (Tom) +

  • Preserve the tablespace of indexes that are + rebuilt by ALTER TABLE ... ALTER COLUMN TYPE (Tom) +

  • Make archive recovery always start a new WAL timeline, rather than only + when a recovery stop time was used (Simon) +

    This avoids a corner-case risk of trying to overwrite an existing + archived copy of the last WAL segment, and seems simpler and cleaner + than the original definition. +

  • Make VACUUM not use all of maintenance_work_mem + when the table is too small for it to be useful (Alvaro) +

  • Fix potential crash in translate() when using a multibyte + database encoding (Tom) +

  • Fix PL/Perl to cope when platform's Perl defines type bool + as int rather than char (Tom) +

    While this could theoretically happen anywhere, no standard build of + Perl did things this way ... until Mac OS X 10.5. +

  • Fix PL/Python to not crash on long exception messages (Alvaro) +

  • Fix pg_dump to correctly handle inheritance child tables + that have default expressions different from their parent's (Tom) +

  • ecpg parser fixes (Michael) +

  • Make contrib/tablefunc's crosstab() handle + NULL rowid as a category in its own right, rather than crashing (Joe) +

  • Fix tsvector and tsquery output routines to + escape backslashes correctly (Teodor, Bruce) +

  • Fix crash of to_tsvector() on huge input strings (Teodor) +

  • Require a specific version of Autoconf to be used + when re-generating the configure script (Peter) +

    This affects developers and packagers only. The change was made + to prevent accidental use of untested combinations of + Autoconf and PostgreSQL versions. + You can remove the version check if you really want to use a + different Autoconf version, but it's + your responsibility whether the result works or not. +


PrevHomeNext
Release 8.0.16UpRelease 8.0.14
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-16.html b/doc/src/sgml/html/release-8-0-16.html new file mode 100644 index 000000000..36b8ec4b3 --- /dev/null +++ b/doc/src/sgml/html/release-8-0-16.html @@ -0,0 +1,511 @@ + +Release 8.0.16

E.121. Release 8.0.16

Release Date: never released

This release contains a variety of fixes from 8.0.15. + For information about new features in the 8.0 major release, see + Section E.137. +

E.121.1. Migration to Version 8.0.16

A dump/restore is not required for those running 8.0.X. + However, if you are upgrading from a version earlier than 8.0.6, + see the release notes for 8.0.6. +

E.121.2. Changes

  • Fix ALTER TABLE ADD COLUMN ... PRIMARY KEY so that the new + column is correctly checked to see if it's been initialized to all + non-nulls (Brendan Jurd) +

    Previous versions neglected to check this requirement at all. +

  • Fix possible CREATE TABLE failure when inheriting the + "same" constraint from multiple parent relations that + inherited that constraint from a common ancestor (Tom) +

  • Fix conversions between ISO-8859-5 and other encodings to handle + Cyrillic "Yo" characters (e and E with + two dots) (Sergey Burladyan) +

  • Fix a few datatype input functions + that were allowing unused bytes in their results to contain + uninitialized, unpredictable values (Tom) +

    This could lead to failures in which two apparently identical literal + values were not seen as equal, resulting in the parser complaining + about unmatched ORDER BY and DISTINCT + expressions. +

  • Fix a corner case in regular-expression substring matching + (substring(string from + pattern)) (Tom) +

    The problem occurs when there is a match to the pattern overall but + the user has specified a parenthesized subexpression and that + subexpression hasn't got a match. An example is + substring('foo' from 'foo(bar)?'). + This should return NULL, since (bar) isn't matched, but + it was mistakenly returning the whole-pattern match instead (ie, + foo). +

  • Update time zone data files to tzdata release 2008c (for + DST law changes in Morocco, Iraq, Choibalsan, Pakistan, Syria, Cuba, + Argentina/San_Luis, and Chile) +

  • Fix incorrect result from ecpg's + PGTYPEStimestamp_sub() function (Michael) +

  • Fix core dump in contrib/xml2's + xpath_table() function when the input query returns a + NULL value (Tom) +

  • Fix contrib/xml2's makefile to not override + CFLAGS (Tom) +

  • Fix DatumGetBool macro to not fail with gcc + 4.3 (Tom) +

    This problem affects "old style" (V0) C functions that + return boolean. The fix is already in 8.3, but the need to + back-patch it was not realized at the time. +

  • Fix longstanding LISTEN/NOTIFY + race condition (Tom) +

    In rare cases a session that had just executed a + LISTEN might not get a notification, even though + one would be expected because the concurrent transaction executing + NOTIFY was observed to commit later. +

    A side effect of the fix is that a transaction that has executed + a not-yet-committed LISTEN command will not see any + row in pg_listener for the LISTEN, + should it choose to look; formerly it would have. This behavior + was never documented one way or the other, but it is possible that + some applications depend on the old behavior. +

  • Fix rare crash when an error occurs during a query using a hash index + (Heikki) +

  • Fix input of datetime values for February 29 in years BC (Tom) +

    The former coding was mistaken about which years were leap years. +

  • Fix "unrecognized node type" error in some variants of + ALTER OWNER (Tom) +

  • Fix pg_ctl to correctly extract the postmaster's port + number from command-line options (Itagaki Takahiro, Tom) +

    Previously, pg_ctl start -w could try to contact the + postmaster on the wrong port, leading to bogus reports of startup + failure. +

  • Use -fwrapv to defend against possible misoptimization + in recent gcc versions (Tom) +

    This is known to be necessary when building PostgreSQL + with gcc 4.3 or later. +

  • Fix display of constant expressions in ORDER BY + and GROUP BY (Tom) +

    An explicitly casted constant would be shown incorrectly. This could + for example lead to corruption of a view definition during + dump and reload. +

  • Fix libpq to handle NOTICE messages correctly + during COPY OUT (Tom) +

    This failure has only been observed to occur when a user-defined + datatype's output routine issues a NOTICE, but there is no + guarantee it couldn't happen due to other causes. +


PrevHomeNext
Release 8.0.17UpRelease 8.0.15
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-17.html b/doc/src/sgml/html/release-8-0-17.html new file mode 100644 index 000000000..639d2ab72 --- /dev/null +++ b/doc/src/sgml/html/release-8-0-17.html @@ -0,0 +1,243 @@ + +Release 8.0.17

E.120. Release 8.0.17

Release Date: 2008-06-12

This release contains one serious bug fix over 8.0.16. + For information about new features in the 8.0 major release, see + Section E.137. +

E.120.1. Migration to Version 8.0.17

A dump/restore is not required for those running 8.0.X. + However, if you are upgrading from a version earlier than 8.0.6, + see the release notes for 8.0.6. +

E.120.2. Changes

  • Make pg_get_ruledef() parenthesize negative constants (Tom) +

    Before this fix, a negative constant in a view or rule might be dumped + as, say, -42::integer, which is subtly incorrect: it should + be (-42)::integer due to operator precedence rules. + Usually this would make little difference, but it could interact with + another recent patch to cause + PostgreSQL to reject what had been a valid + SELECT DISTINCT view query. Since this could result in + pg_dump output failing to reload, it is being treated + as a high-priority fix. The only released versions in which dump + output is actually incorrect are 8.3.1 and 8.2.7. +


PrevHomeNext
Release 8.0.18UpRelease 8.0.16
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-18.html b/doc/src/sgml/html/release-8-0-18.html new file mode 100644 index 000000000..291f33889 --- /dev/null +++ b/doc/src/sgml/html/release-8-0-18.html @@ -0,0 +1,336 @@ + +Release 8.0.18

E.119. Release 8.0.18

Release Date: 2008-09-22

This release contains a variety of fixes from 8.0.17. + For information about new features in the 8.0 major release, see + Section E.137. +

E.119.1. Migration to Version 8.0.18

A dump/restore is not required for those running 8.0.X. + However, if you are upgrading from a version earlier than 8.0.6, + see the release notes for 8.0.6. +

E.119.2. Changes

  • Widen local lock counters from 32 to 64 bits (Tom) +

    This responds to reports that the counters could overflow in + sufficiently long transactions, leading to unexpected "lock is + already held" errors. +

  • Add checks in executor startup to ensure that the tuples produced by an + INSERT or UPDATE will match the target table's + current rowtype (Tom) +

    ALTER COLUMN TYPE, followed by re-use of a previously + cached plan, could produce this type of situation. The check protects + against data corruption and/or crashes that could ensue. +

  • Fix datetime input functions to correctly detect integer overflow when + running on a 64-bit platform (Tom) +

  • Improve performance of writing very long log messages to syslog (Tom) +

  • Fix bug in backwards scanning of a cursor on a SELECT DISTINCT + ON query (Tom) +

  • Fix planner to estimate that GROUP BY expressions yielding + boolean results always result in two groups, regardless of the + expressions' contents (Tom) +

    This is very substantially more accurate than the regular GROUP + BY estimate for certain boolean tests like col + IS NULL. +

  • Fix PL/Tcl to behave correctly with Tcl 8.5, and to be more careful + about the encoding of data sent to or from Tcl (Tom) +

  • Fix PL/Python to work with Python 2.5 +

    This is a back-port of fixes made during the 8.2 development cycle. +

  • Improve pg_dump and pg_restore's + error reporting after failure to send a SQL command (Tom) +

  • Fix pg_ctl to properly preserve postmaster + command-line arguments across a restart (Bruce) +

  • Update time zone data files to tzdata release 2008f (for + DST law changes in Argentina, Bahamas, Brazil, Mauritius, Morocco, + Pakistan, Palestine, and Paraguay) +


PrevHomeNext
Release 8.0.19UpRelease 8.0.17
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-19.html b/doc/src/sgml/html/release-8-0-19.html new file mode 100644 index 000000000..05585de99 --- /dev/null +++ b/doc/src/sgml/html/release-8-0-19.html @@ -0,0 +1,297 @@ + +Release 8.0.19

E.118. Release 8.0.19

Release Date: 2008-11-03

This release contains a variety of fixes from 8.0.18. + For information about new features in the 8.0 major release, see + Section E.137. +

E.118.1. Migration to Version 8.0.19

A dump/restore is not required for those running 8.0.X. + However, if you are upgrading from a version earlier than 8.0.6, + see the release notes for 8.0.6. +

E.118.2. Changes

  • Fix backend crash when the client encoding cannot represent a localized + error message (Tom) +

    We have addressed similar issues before, but it would still fail if + the "character has no equivalent" message itself couldn't + be converted. The fix is to disable localization and send the plain + ASCII error message when we detect such a situation. +

  • Fix possible crash when deeply nested functions are invoked from + a trigger (Tom) +

  • Ensure an error is reported when a newly-defined PL/pgSQL trigger + function is invoked as a normal function (Tom) +

  • Fix incorrect tsearch2 headline generation when single query + item matches first word of text (Sushant Sinha) +

  • Fix improper display of fractional seconds in interval values when + using a non-ISO datestyle in an --enable-integer-datetimes + build (Ron Mayer) +

  • Ensure SPI_getvalue and SPI_getbinval + behave correctly when the passed tuple and tuple descriptor have + different numbers of columns (Tom) +

    This situation is normal when a table has had columns added or removed, + but these two functions didn't handle it properly. + The only likely consequence is an incorrect error indication. +

  • Fix ecpg's parsing of CREATE USER (Michael) +

  • Fix recent breakage of pg_ctl restart (Tom) +

  • Update time zone data files to tzdata release 2008i (for + DST law changes in Argentina, Brazil, Mauritius, Syria) +


PrevHomeNext
Release 8.0.20UpRelease 8.0.18
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-2.html b/doc/src/sgml/html/release-8-0-2.html new file mode 100644 index 000000000..24581203b --- /dev/null +++ b/doc/src/sgml/html/release-8-0-2.html @@ -0,0 +1,581 @@ + +Release 8.0.2

E.135. Release 8.0.2

Release Date: 2005-04-07

This release contains a variety of fixes from 8.0.1. + For information about new features in the 8.0 major release, see + Section E.137. +

E.135.1. Migration to Version 8.0.2

A dump/restore is not required for those running 8.0.*. + This release updates the major version number of the + PostgreSQL libraries, so it might be + necessary to re-link some user applications if they cannot + find the properly-numbered shared library. +

E.135.2. Changes

  • Increment the major version number of all interface +libraries (Bruce)

    This should have been done in 8.0.0. It is required so 7.4.X versions +of PostgreSQL client applications, like psql, +can be used on the same machine as 8.0.X applications. This might require +re-linking user applications that use these libraries.

  • Add Windows-only wal_sync_method setting of +fsync_writethrough (Magnus, Bruce)

    This setting causes PostgreSQL to write through +any disk-drive write cache when writing to WAL. +This behavior was formerly called fsync, but was +renamed because it acts quite differently from fsync on other +platforms.

  • Enable the wal_sync_method setting of +open_datasync on Windows, and make it the default for that + platform (Magnus, Bruce)

    Because the default is no longer fsync_writethrough, +data loss is possible during a power failure if the disk drive has +write caching enabled. To turn off the write cache on Windows, +from the Device Manager, choose the drive properties, +then Policies.

  • New cache management algorithm 2Q replaces +ARC (Tom)

    This was done to avoid a pending US patent on ARC. The +2Q code might be a few percentage points slower than +ARC for some work loads. A better cache management algorithm +will appear in 8.1.

  • Planner adjustments to improve behavior on freshly-created +tables (Tom)

  • Allow plpgsql to assign to an element of an array that is +initially NULL (Tom)

    Formerly the array would remain NULL, but now it becomes a +single-element array. The main SQL engine was changed to handle +UPDATE of a null array value this way in 8.0, but the similar +case in plpgsql was overlooked.

  • Convert \r\n and \r to \n +in plpython function bodies (Michael Fuhr)

    This prevents syntax errors when plpython code is written on a Windows or + Mac client.

  • Allow SPI cursors to handle utility commands that return rows, +such as EXPLAIN (Tom)

  • Fix CLUSTER failure after ALTER TABLE +SET WITHOUT OIDS (Tom)

  • Reduce memory usage of ALTER TABLE ADD COLUMN +(Neil)

  • Fix ALTER LANGUAGE RENAME (Tom)

  • Document the Windows-only register and +unregister options of pg_ctl (Magnus)

  • Ensure operations done during backend shutdown are counted by +statistics collector

    This is expected to resolve reports of pg_autovacuum +not vacuuming the system catalogs often enough — it was not being +told about catalog deletions caused by temporary table removal during +backend exit.

  • Change the Windows default for configuration parameter +log_destination to eventlog (Magnus)

    By default, a server running on Windows will now send log output to the +Windows event logger rather than standard error.

  • Make Kerberos authentication work on Windows (Magnus)

  • Allow ALTER DATABASE RENAME by superusers +who aren't flagged as having CREATEDB privilege (Tom)

  • Modify WAL log entries for CREATE and +DROP DATABASE to not specify absolute paths (Tom)

    This allows point-in-time recovery on a different machine with possibly +different database location. Note that CREATE TABLESPACE still +poses a hazard in such situations.

  • Fix crash from a backend exiting with an open transaction +that created a table and opened a cursor on it (Tom)

  • Fix array_map() so it can call PL functions +(Tom)

  • Several contrib/tsearch2 and +contrib/btree_gist fixes (Teodor)

  • Fix crash of some contrib/pgcrypto +functions on some platforms (Marko Kreen)

  • Fix contrib/intagg for 64-bit platforms +(Tom)

  • Fix ecpg bugs in parsing of CREATE statement +(Michael)

  • Work around gcc bug on powerpc and amd64 causing problems in +ecpg (Christof Petig)

  • Do not use locale-aware versions of upper(), +lower(), and initcap() when the locale is +C (Bruce)

    This allows these functions to work on platforms that generate errors + for non-7-bit data when the locale is C.

  • Fix quote_ident() to quote names that match keywords (Tom)

  • Fix to_date() to behave reasonably when +CC and YY fields are both used (Karel)

  • Prevent to_char(interval) from failing +when given a zero-month interval (Tom)

  • Fix wrong week returned by date_trunc('week') +(Bruce)

    date_trunc('week') +returned the wrong year for the first few days of January in some years.

  • Use the correct default mask length for class D +addresses in INET data types (Tom)


PrevHomeNext
Release 8.0.3UpRelease 8.0.1
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-20.html b/doc/src/sgml/html/release-8-0-20.html new file mode 100644 index 000000000..989cc3179 --- /dev/null +++ b/doc/src/sgml/html/release-8-0-20.html @@ -0,0 +1,282 @@ + +Release 8.0.20

E.117. Release 8.0.20

Release Date: 2009-02-02

This release contains a variety of fixes from 8.0.19. + For information about new features in the 8.0 major release, see + Section E.137. +

E.117.1. Migration to Version 8.0.20

A dump/restore is not required for those running 8.0.X. + However, if you are upgrading from a version earlier than 8.0.6, + see the release notes for 8.0.6. +

E.117.2. Changes

  • Improve handling of URLs in headline() function (Teodor) +

  • Improve handling of overlength headlines in headline() + function (Teodor) +

  • Prevent possible Assert failure or misconversion if an encoding + conversion is created with the wrong conversion function for the + specified pair of encodings (Tom, Heikki) +

  • Avoid unnecessary locking of small tables in VACUUM + (Heikki) +

  • Fix uninitialized variables in contrib/tsearch2's + get_covers() function (Teodor) +

  • Make all documentation reference pgsql-bugs and/or + pgsql-hackers as appropriate, instead of the + now-decommissioned pgsql-ports and pgsql-patches + mailing lists (Tom) +

  • Update time zone data files to tzdata release 2009a (for + Kathmandu and historical DST corrections in Switzerland, Cuba) +


PrevHomeNext
Release 8.0.21UpRelease 8.0.19
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-21.html b/doc/src/sgml/html/release-8-0-21.html new file mode 100644 index 000000000..d4f6a4978 --- /dev/null +++ b/doc/src/sgml/html/release-8-0-21.html @@ -0,0 +1,262 @@ + +Release 8.0.21

E.116. Release 8.0.21

Release Date: 2009-03-16

This release contains a variety of fixes from 8.0.20. + For information about new features in the 8.0 major release, see + Section E.137. +

E.116.1. Migration to Version 8.0.21

A dump/restore is not required for those running 8.0.X. + However, if you are upgrading from a version earlier than 8.0.6, + see the release notes for 8.0.6. +

E.116.2. Changes

  • Prevent error recursion crashes when encoding conversion fails (Tom) +

    This change extends fixes made in the last two minor releases for + related failure scenarios. The previous fixes were narrowly tailored + for the original problem reports, but we have now recognized that + any error thrown by an encoding conversion function could + potentially lead to infinite recursion while trying to report the + error. The solution therefore is to disable translation and encoding + conversion and report the plain-ASCII form of any error message, + if we find we have gotten into a recursive error reporting situation. + (CVE-2009-0922) +

  • Disallow CREATE CONVERSION with the wrong encodings + for the specified conversion function (Heikki) +

    This prevents one possible scenario for encoding conversion failure. + The previous change is a backstop to guard against other kinds of + failures in the same area. +

  • Fix core dump when to_char() is given format codes that + are inappropriate for the type of the data argument (Tom) +

  • Add MUST (Mauritius Island Summer Time) to the default list + of known timezone abbreviations (Xavier Bugaud) +


PrevHomeNext
Release 8.0.22UpRelease 8.0.20
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-22.html b/doc/src/sgml/html/release-8-0-22.html new file mode 100644 index 000000000..c144ec19d --- /dev/null +++ b/doc/src/sgml/html/release-8-0-22.html @@ -0,0 +1,394 @@ + +Release 8.0.22

E.115. Release 8.0.22

Release Date: 2009-09-09

This release contains a variety of fixes from 8.0.21. + For information about new features in the 8.0 major release, see + Section E.137. +

E.115.1. Migration to Version 8.0.22

A dump/restore is not required for those running 8.0.X. + However, if you have any hash indexes on interval columns, + you must REINDEX them after updating to 8.0.22. + Also, if you are upgrading from a version earlier than 8.0.6, + see the release notes for 8.0.6. +

E.115.2. Changes

  • Disallow RESET ROLE and RESET SESSION + AUTHORIZATION inside security-definer functions (Tom, Heikki) +

    This covers a case that was missed in the previous patch that + disallowed SET ROLE and SET SESSION + AUTHORIZATION inside security-definer functions. + (See CVE-2007-6600) +

  • Fix handling of sub-SELECTs appearing in the arguments of + an outer-level aggregate function (Tom) +

  • Fix hash calculation for data type interval (Tom) +

    This corrects wrong results for hash joins on interval values. + It also changes the contents of hash indexes on interval columns. + If you have any such indexes, you must REINDEX them + after updating. +

  • Treat to_char(..., 'TH') as an uppercase ordinal + suffix with 'HH'/'HH12' (Heikki) +

    It was previously handled as 'th' (lowercase). +

  • Fix overflow for INTERVAL 'x ms' + when x is more than 2 million and integer + datetimes are in use (Alex Hunsaker) +

  • Fix calculation of distance between a point and a line segment (Tom) +

    This led to incorrect results from a number of geometric operators. +

  • Fix money data type to work in locales where currency + amounts have no fractional digits, e.g. Japan (Itagaki Takahiro) +

  • Properly round datetime input like + 00:12:57.9999999999999999999999999999 (Tom) +

  • Fix poor choice of page split point in GiST R-tree operator classes + (Teodor) +

  • Fix portability issues in plperl initialization (Andrew Dunstan) +

  • Fix pg_ctl to not go into an infinite loop if + postgresql.conf is empty (Jeff Davis) +

  • Fix contrib/xml2's xslt_process() to + properly handle the maximum number of parameters (twenty) (Tom) +

  • Improve robustness of libpq's code to recover + from errors during COPY FROM STDIN (Tom) +

  • Avoid including conflicting readline and editline header files + when both libraries are installed (Zdenek Kotala) +

  • Update time zone data files to tzdata release 2009l + for DST law changes in Bangladesh, Egypt, Jordan, Pakistan, + Argentina/San_Luis, Cuba, Jordan (historical correction only), + Mauritius, Morocco, Palestine, Syria, Tunisia. +


PrevHomeNext
Release 8.0.23UpRelease 8.0.21
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-23.html b/doc/src/sgml/html/release-8-0-23.html new file mode 100644 index 000000000..f15cf9a8b --- /dev/null +++ b/doc/src/sgml/html/release-8-0-23.html @@ -0,0 +1,340 @@ + +Release 8.0.23

E.114. Release 8.0.23

Release Date: 2009-12-14

This release contains a variety of fixes from 8.0.22. + For information about new features in the 8.0 major release, see + Section E.137. +

E.114.1. Migration to Version 8.0.23

A dump/restore is not required for those running 8.0.X. + However, if you are upgrading from a version earlier than 8.0.22, + see the release notes for 8.0.22. +

E.114.2. Changes

  • Protect against indirect security threats caused by index functions + changing session-local state (Gurjeet Singh, Tom) +

    This change prevents allegedly-immutable index functions from possibly + subverting a superuser's session (CVE-2009-4136). +

  • Reject SSL certificates containing an embedded null byte in the common + name (CN) field (Magnus) +

    This prevents unintended matching of a certificate to a server or client + name during SSL validation (CVE-2009-4034). +

  • Fix possible crash during backend-startup-time cache initialization (Tom) +

  • Prevent signals from interrupting VACUUM at unsafe times + (Alvaro) +

    This fix prevents a PANIC if a VACUUM FULL is canceled + after it's already committed its tuple movements, as well as transient + errors if a plain VACUUM is interrupted after having + truncated the table. +

  • Fix possible crash due to integer overflow in hash table size + calculation (Tom) +

    This could occur with extremely large planner estimates for the size of + a hashjoin's result. +

  • Fix very rare crash in inet/cidr comparisons (Chris + Mikkelson) +

  • Fix premature drop of temporary files used for a cursor that is accessed + within a subtransaction (Heikki) +

  • Fix PAM password processing to be more robust (Tom) +

    The previous code is known to fail with the combination of the Linux + pam_krb5 PAM module with Microsoft Active Directory as the + domain controller. It might have problems elsewhere too, since it was + making unjustified assumptions about what arguments the PAM stack would + pass to it. +

  • Fix rare crash in exception processing in PL/Python (Peter) +

  • Ensure psql's flex module is compiled with the correct + system header definitions (Tom) +

    This fixes build failures on platforms where + --enable-largefile causes incompatible changes in the + generated code. +

  • Make the postmaster ignore any application_name parameter in + connection request packets, to improve compatibility with future libpq + versions (Tom) +

  • Update time zone data files to tzdata release 2009s + for DST law changes in Antarctica, Argentina, Bangladesh, Fiji, + Novokuznetsk, Pakistan, Palestine, Samoa, Syria; also historical + corrections for Hong Kong. +


PrevHomeNext
Release 8.0.24UpRelease 8.0.22
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-24.html b/doc/src/sgml/html/release-8-0-24.html new file mode 100644 index 000000000..29eb3b84d --- /dev/null +++ b/doc/src/sgml/html/release-8-0-24.html @@ -0,0 +1,387 @@ + +Release 8.0.24

E.113. Release 8.0.24

Release Date: 2010-03-15

This release contains a variety of fixes from 8.0.23. + For information about new features in the 8.0 major release, see + Section E.137. +

The PostgreSQL community will stop releasing updates + for the 8.0.X release series in July 2010. + Users are encouraged to update to a newer release branch soon. +

E.113.1. Migration to Version 8.0.24

A dump/restore is not required for those running 8.0.X. + However, if you are upgrading from a version earlier than 8.0.22, + see the release notes for 8.0.22. +

E.113.2. Changes

  • Add new configuration parameter ssl_renegotiation_limit to + control how often we do session key renegotiation for an SSL connection + (Magnus) +

    This can be set to zero to disable renegotiation completely, which may + be required if a broken SSL library is used. In particular, some + vendors are shipping stopgap patches for CVE-2009-3555 that cause + renegotiation attempts to fail. +

  • Fix possible crashes when trying to recover from a failure in + subtransaction start (Tom) +

  • Fix server memory leak associated with use of savepoints and a client + encoding different from server's encoding (Tom) +

  • Make substring() for bit types treat any negative + length as meaning "all the rest of the string" (Tom) +

    The previous coding treated only -1 that way, and would produce an + invalid result value for other negative values, possibly leading to + a crash (CVE-2010-0442). +

  • Fix integer-to-bit-string conversions to handle the first fractional + byte correctly when the output bit width is wider than the given + integer by something other than a multiple of 8 bits (Tom) +

  • Fix some cases of pathologically slow regular expression matching (Tom) +

  • Fix the STOP WAL LOCATION entry in backup history files to + report the next WAL segment's name when the end location is exactly at a + segment boundary (Itagaki Takahiro) +

  • When reading pg_hba.conf and related files, do not treat + @something as a file inclusion request if the @ + appears inside quote marks; also, never treat @ by itself + as a file inclusion request (Tom) +

    This prevents erratic behavior if a role or database name starts with + @. If you need to include a file whose path name + contains spaces, you can still do so, but you must write + @"/path to/file" rather than putting the quotes around + the whole construct. +

  • Prevent infinite loop on some platforms if a directory is named as + an inclusion target in pg_hba.conf and related files + (Tom) +

  • Fix plpgsql failure in one case where a composite column is set to NULL + (Tom) +

  • Add volatile markings in PL/Python to avoid possible + compiler-specific misbehavior (Zdenek Kotala) +

  • Ensure PL/Tcl initializes the Tcl interpreter fully (Tom) +

    The only known symptom of this oversight is that the Tcl + clock command misbehaves if using Tcl 8.5 or later. +

  • Prevent crash in contrib/dblink when too many key + columns are specified to a dblink_build_sql_* function + (Rushabh Lathia, Joe Conway) +

  • Fix assorted crashes in contrib/xml2 caused by sloppy + memory management (Tom) +

  • Update time zone data files to tzdata release 2010e + for DST law changes in Bangladesh, Chile, Fiji, Mexico, Paraguay, Samoa. +


PrevHomeNext
Release 8.0.25UpRelease 8.0.23
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-25.html b/doc/src/sgml/html/release-8-0-25.html new file mode 100644 index 000000000..5c43302a9 --- /dev/null +++ b/doc/src/sgml/html/release-8-0-25.html @@ -0,0 +1,389 @@ + +Release 8.0.25

E.112. Release 8.0.25

Release Date: 2010-05-17

This release contains a variety of fixes from 8.0.24. + For information about new features in the 8.0 major release, see + Section E.137. +

The PostgreSQL community will stop releasing updates + for the 8.0.X release series in July 2010. + Users are encouraged to update to a newer release branch soon. +

E.112.1. Migration to Version 8.0.25

A dump/restore is not required for those running 8.0.X. + However, if you are upgrading from a version earlier than 8.0.22, + see the release notes for 8.0.22. +

E.112.2. Changes

  • Enforce restrictions in plperl using an opmask applied to + the whole interpreter, instead of using Safe.pm + (Tim Bunce, Andrew Dunstan) +

    Recent developments have convinced us that Safe.pm is too + insecure to rely on for making plperl trustable. This + change removes use of Safe.pm altogether, in favor of using + a separate interpreter with an opcode mask that is always applied. + Pleasant side effects of the change include that it is now possible to + use Perl's strict pragma in a natural way in + plperl, and that Perl's $a and $b + variables work as expected in sort routines, and that function + compilation is significantly faster. (CVE-2010-1169) +

  • Prevent PL/Tcl from executing untrustworthy code from + pltcl_modules (Tom) +

    PL/Tcl's feature for autoloading Tcl code from a database table + could be exploited for trojan-horse attacks, because there was no + restriction on who could create or insert into that table. This change + disables the feature unless pltcl_modules is owned by a + superuser. (However, the permissions on the table are not checked, so + installations that really need a less-than-secure modules table can + still grant suitable privileges to trusted non-superusers.) Also, + prevent loading code into the unrestricted "normal" Tcl + interpreter unless we are really going to execute a pltclu + function. (CVE-2010-1170) +

  • Do not allow an unprivileged user to reset superuser-only parameter + settings (Alvaro) +

    Previously, if an unprivileged user ran ALTER USER ... RESET + ALL for himself, or ALTER DATABASE ... RESET ALL for + a database he owns, this would remove all special parameter settings + for the user or database, even ones that are only supposed to be + changeable by a superuser. Now, the ALTER will only + remove the parameters that the user has permission to change. +

  • Avoid possible crash during backend shutdown if shutdown occurs + when a CONTEXT addition would be made to log entries (Tom) +

    In some cases the context-printing function would fail because the + current transaction had already been rolled back when it came time + to print a log message. +

  • Update pl/perl's ppport.h for modern Perl versions + (Andrew) +

  • Fix assorted memory leaks in pl/python (Andreas Freund, Tom) +

  • Prevent infinite recursion in psql when expanding + a variable that refers to itself (Tom) +

  • Ensure that contrib/pgstattuple functions respond to cancel + interrupts promptly (Tatsuhito Kasahara) +

  • Make server startup deal properly with the case that + shmget() returns EINVAL for an existing + shared memory segment (Tom) +

    This behavior has been observed on BSD-derived kernels including OS X. + It resulted in an entirely-misleading startup failure complaining that + the shared memory request size was too large. +

  • Update time zone data files to tzdata release 2010j + for DST law changes in Argentina, Australian Antarctic, Bangladesh, + Mexico, Morocco, Pakistan, Palestine, Russia, Syria, Tunisia; + also historical corrections for Taiwan. +


PrevHomeNext
Release 8.0.26UpRelease 8.0.24
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-26.html b/doc/src/sgml/html/release-8-0-26.html new file mode 100644 index 000000000..876ade015 --- /dev/null +++ b/doc/src/sgml/html/release-8-0-26.html @@ -0,0 +1,404 @@ + +Release 8.0.26

E.111. Release 8.0.26

Release Date: 2010-10-04

This release contains a variety of fixes from 8.0.25. + For information about new features in the 8.0 major release, see + Section E.137. +

This is expected to be the last PostgreSQL release + in the 8.0.X series. Users are encouraged to update to a newer + release branch soon. +

E.111.1. Migration to Version 8.0.26

A dump/restore is not required for those running 8.0.X. + However, if you are upgrading from a version earlier than 8.0.22, + see the release notes for 8.0.22. +

E.111.2. Changes

  • Use a separate interpreter for each calling SQL userid in PL/Perl and + PL/Tcl (Tom Lane) +

    This change prevents security problems that can be caused by subverting + Perl or Tcl code that will be executed later in the same session under + another SQL user identity (for example, within a SECURITY + DEFINER function). Most scripting languages offer numerous ways that + that might be done, such as redefining standard functions or operators + called by the target function. Without this change, any SQL user with + Perl or Tcl language usage rights can do essentially anything with the + SQL privileges of the target function's owner. +

    The cost of this change is that intentional communication among Perl + and Tcl functions becomes more difficult. To provide an escape hatch, + PL/PerlU and PL/TclU functions continue to use only one interpreter + per session. This is not considered a security issue since all such + functions execute at the trust level of a database superuser already. +

    It is likely that third-party procedural languages that claim to offer + trusted execution have similar security issues. We advise contacting + the authors of any PL you are depending on for security-critical + purposes. +

    Our thanks to Tim Bunce for pointing out this issue (CVE-2010-3433). +

  • Prevent possible crashes in pg_get_expr() by disallowing + it from being called with an argument that is not one of the system + catalog columns it's intended to be used with + (Heikki Linnakangas, Tom Lane) +

  • Fix "cannot handle unplanned sub-select" error (Tom Lane) +

    This occurred when a sub-select contains a join alias reference that + expands into an expression containing another sub-select. +

  • Defend against functions returning setof record where not all the + returned rows are actually of the same rowtype (Tom Lane) +

  • Take care to fsync the contents of lockfiles (both + postmaster.pid and the socket lockfile) while writing them + (Tom Lane) +

    This omission could result in corrupted lockfile contents if the + machine crashes shortly after postmaster start. That could in turn + prevent subsequent attempts to start the postmaster from succeeding, + until the lockfile is manually removed. +

  • Avoid recursion while assigning XIDs to heavily-nested + subtransactions (Andres Freund, Robert Haas) +

    The original coding could result in a crash if there was limited + stack space. +

  • Fix log_line_prefix's %i escape, + which could produce junk early in backend startup (Tom Lane) +

  • Fix possible data corruption in ALTER TABLE ... SET + TABLESPACE when archiving is enabled (Jeff Davis) +

  • Allow CREATE DATABASE and ALTER DATABASE ... SET + TABLESPACE to be interrupted by query-cancel (Guillaume Lelarge) +

  • In PL/Python, defend against null pointer results from + PyCObject_AsVoidPtr and PyCObject_FromVoidPtr + (Peter Eisentraut) +

  • Improve contrib/dblink's handling of tables containing + dropped columns (Tom Lane) +

  • Fix connection leak after "duplicate connection name" + errors in contrib/dblink (Itagaki Takahiro) +

  • Fix contrib/dblink to handle connection names longer than + 62 bytes correctly (Itagaki Takahiro) +

  • Update build infrastructure and documentation to reflect the source code + repository's move from CVS to Git (Magnus Hagander and others) +

  • Update time zone data files to tzdata release 2010l + for DST law changes in Egypt and Palestine; also historical corrections + for Finland. +

    This change also adds new names for two Micronesian timezones: + Pacific/Chuuk is now preferred over Pacific/Truk (and the preferred + abbreviation is CHUT not TRUT) and Pacific/Pohnpei is preferred over + Pacific/Ponape. +


PrevHomeNext
Release 8.1UpRelease 8.0.25
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-3.html b/doc/src/sgml/html/release-8-0-3.html new file mode 100644 index 000000000..d389ee1bd --- /dev/null +++ b/doc/src/sgml/html/release-8-0-3.html @@ -0,0 +1,422 @@ + +Release 8.0.3

E.134. Release 8.0.3

Release Date: 2005-05-09

This release contains a variety of fixes from 8.0.2, including several + security-related issues. + For information about new features in the 8.0 major release, see + Section E.137. +

E.134.1. Migration to Version 8.0.3

A dump/restore is not required for those running 8.0.X. However, + it is one possible way of handling two significant security problems + that have been found in the initial contents of 8.0.X system + catalogs. A dump/initdb/reload sequence using 8.0.3's initdb will + automatically correct these problems. +

The larger security problem is that the built-in character set encoding + conversion functions can be invoked from SQL commands by unprivileged + users, but the functions were not designed for such use and are not + secure against malicious choices of arguments. The fix involves changing + the declared parameter list of these functions so that they can no longer + be invoked from SQL commands. (This does not affect their normal use + by the encoding conversion machinery.) +

The lesser problem is that the contrib/tsearch2 module + creates several functions that are improperly declared to return + internal when they do not accept internal arguments. + This breaks type safety for all functions using internal + arguments. +

It is strongly recommended that all installations repair these errors, + either by initdb or by following the manual repair procedure given + below. The errors at least allow unprivileged database users to crash + their server process, and might allow unprivileged users to gain the + privileges of a database superuser. +

If you wish not to do an initdb, perform the same manual repair + procedures shown in the 7.4.8 release + notes. +

E.134.2. Changes

  • Change encoding function signature to prevent +misuse

  • Change contrib/tsearch2 to avoid unsafe use of +INTERNAL function results

  • Guard against incorrect second parameter to +record_out

  • Repair ancient race condition that allowed a transaction to be +seen as committed for some purposes (eg SELECT FOR UPDATE) slightly sooner +than for other purposes

    This is an extremely serious bug since it could lead to apparent +data inconsistencies being briefly visible to applications.

  • Repair race condition between relation extension and +VACUUM

    This could theoretically have caused loss of a page's worth of +freshly-inserted data, although the scenario seems of very low probability. +There are no known cases of it having caused more than an Assert failure.

  • Fix comparisons of TIME WITH TIME ZONE values

    The comparison code was wrong in the case where the +--enable-integer-datetimes configuration switch had been used. +NOTE: if you have an index on a TIME WITH TIME ZONE column, +it will need to be REINDEXed after installing this update, because +the fix corrects the sort order of column values.

  • Fix EXTRACT(EPOCH) for +TIME WITH TIME ZONE values

  • Fix mis-display of negative fractional seconds in +INTERVAL values

    This error only occurred when the +--enable-integer-datetimes configuration switch had been used.

  • Fix pg_dump to dump trigger names containing % +correctly (Neil)

  • Still more 64-bit fixes for +contrib/intagg

  • Prevent incorrect optimization of functions returning +RECORD

  • Prevent crash on COALESCE(NULL,NULL)

  • Fix Borland makefile for libpq

  • Fix contrib/btree_gist for timetz type +(Teodor)

  • Make pg_ctl check the PID found in +postmaster.pid to see if it is still a live +process

  • Fix pg_dump/pg_restore problems caused +by addition of dump timestamps

  • Fix interaction between materializing holdable cursors and +firing deferred triggers during transaction commit

  • Fix memory leak in SQL functions returning pass-by-reference +data types


PrevHomeNext
Release 8.0.4UpRelease 8.0.2
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-4.html b/doc/src/sgml/html/release-8-0-4.html new file mode 100644 index 000000000..0c22ccd44 --- /dev/null +++ b/doc/src/sgml/html/release-8-0-4.html @@ -0,0 +1,449 @@ + +Release 8.0.4

E.133. Release 8.0.4

Release Date: 2005-10-04

This release contains a variety of fixes from 8.0.3. + For information about new features in the 8.0 major release, see + Section E.137. +

E.133.1. Migration to Version 8.0.4

A dump/restore is not required for those running 8.0.X. However, + if you are upgrading from a version earlier than 8.0.3, see the release + notes for 8.0.3. +

E.133.2. Changes

  • Fix error that allowed VACUUM to remove +ctid chains too soon, and add more checking in code that follows +ctid links

    This fixes a long-standing problem that could cause crashes in very rare +circumstances.

  • Fix CHAR() to properly pad spaces to the specified +length when using a multiple-byte character set (Yoshiyuki Asaba)

    In prior releases, the padding of CHAR() was incorrect +because it only padded to the specified number of bytes without +considering how many characters were stored.

  • Force a checkpoint before committing CREATE +DATABASE

    This should fix recent reports of "index is not a btree" +failures when a crash occurs shortly after CREATE +DATABASE.

  • Fix the sense of the test for read-only transaction +in COPY

    The code formerly prohibited COPY TO, where it should +prohibit COPY FROM.

  • Handle consecutive embedded newlines in COPY +CSV-mode input

  • Fix date_trunc(week) for dates near year +end

  • Fix planning problem with outer-join ON clauses that reference +only the inner-side relation

  • Further fixes for x FULL JOIN y ON true corner +cases

  • Fix overenthusiastic optimization of x IN (SELECT +DISTINCT ...) and related cases

  • Fix mis-planning of queries with small LIMIT +values due to poorly thought out "fuzzy" cost +comparison

  • Make array_in and array_recv more +paranoid about validating their OID parameter

  • Fix missing rows in queries like UPDATE a=... WHERE +a... with GiST index on column a

  • Improve robustness of datetime parsing

  • Improve checking for partially-written WAL +pages

  • Improve robustness of signal handling when SSL is +enabled

  • Improve MIPS and M68K spinlock code

  • Don't try to open more than max_files_per_process +files during postmaster startup

  • Various memory leakage fixes

  • Various portability improvements

  • Update timezone data files

  • Improve handling of DLL load failures on Windows

  • Improve random-number generation on Windows

  • Make psql -f filename return a nonzero exit code +when opening the file fails

  • Change pg_dump to handle inherited check +constraints more reliably

  • Fix password prompting in pg_restore on +Windows

  • Fix PL/pgSQL to handle var := var correctly when +the variable is of pass-by-reference type

  • Fix PL/Perl %_SHARED so it's actually +shared

  • Fix contrib/pg_autovacuum to allow sleep +intervals over 2000 sec

  • Update contrib/tsearch2 to use current Snowball +code


PrevHomeNext
Release 8.0.5UpRelease 8.0.3
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-5.html b/doc/src/sgml/html/release-8-0-5.html new file mode 100644 index 000000000..51d0d5b1c --- /dev/null +++ b/doc/src/sgml/html/release-8-0-5.html @@ -0,0 +1,310 @@ + +Release 8.0.5

E.132. Release 8.0.5

Release Date: 2005-12-12

This release contains a variety of fixes from 8.0.4. + For information about new features in the 8.0 major release, see + Section E.137. +

E.132.1. Migration to Version 8.0.5

A dump/restore is not required for those running 8.0.X. However, + if you are upgrading from a version earlier than 8.0.3, see the release + notes for 8.0.3. +

E.132.2. Changes

  • Fix race condition in transaction log management

    There was a narrow window in which an I/O operation could be initiated +for the wrong page, leading to an Assert failure or data +corruption.

  • Fix bgwriter problems after recovering from errors +(Tom)

    The background writer was found to leak buffer pins after write errors. +While not fatal in itself, this might lead to mysterious blockages of +later VACUUM commands.

  • Prevent failure if client sends Bind protocol message +when current transaction is already aborted

  • /contrib/ltree fixes (Teodor)

  • AIX and HPUX compile fixes (Tom)

  • Retry file reads and writes after Windows +NO_SYSTEM_RESOURCES error (Qingqing Zhou)

  • Fix intermittent failure when log_line_prefix +includes %i

  • Fix psql performance issue with long scripts +on Windows (Merlin Moncure)

  • Fix missing updates of pg_group flat +file

  • Fix longstanding planning error for outer joins

    This bug sometimes caused a bogus error "RIGHT JOIN is +only supported with merge-joinable join conditions".

  • Postpone timezone initialization until after +postmaster.pid is created

    This avoids confusing startup scripts that expect the pid file to appear +quickly.

  • Prevent core dump in pg_autovacuum when a +table has been dropped

  • Fix problems with whole-row references (foo.*) +to subquery results


PrevHomeNext
Release 8.0.6UpRelease 8.0.4
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-6.html b/doc/src/sgml/html/release-8-0-6.html new file mode 100644 index 000000000..c668134fe --- /dev/null +++ b/doc/src/sgml/html/release-8-0-6.html @@ -0,0 +1,322 @@ + +Release 8.0.6

E.131. Release 8.0.6

Release Date: 2006-01-09

This release contains a variety of fixes from 8.0.5. + For information about new features in the 8.0 major release, see + Section E.137. +

E.131.1. Migration to Version 8.0.6

A dump/restore is not required for those running 8.0.X. However, + if you are upgrading from a version earlier than 8.0.3, see the release + notes for 8.0.3. + Also, you might need to REINDEX indexes on textual + columns after updating, if you are affected by the locale or + plperl issues described below. +

E.131.2. Changes

  • Fix Windows code so that postmaster will continue rather +than exit if there is no more room in ShmemBackendArray (Magnus)

    The previous behavior could lead to a denial-of-service situation if too +many connection requests arrive close together. This applies +only to the Windows port.

  • Fix bug introduced in 8.0 that could allow ReadBuffer +to return an already-used page as new, potentially causing loss of +recently-committed data (Tom)

  • Fix for protocol-level Describe messages issued +outside a transaction or in a failed transaction (Tom)

  • Fix character string comparison for locales that consider +different character combinations as equal, such as Hungarian (Tom)

    This might require REINDEX to fix existing indexes on +textual columns.

  • Set locale environment variables during postmaster startup +to ensure that plperl won't change the locale later

    This fixes a problem that occurred if the postmaster was +started with environment variables specifying a different locale than what +initdb had been told. Under these conditions, any use of +plperl was likely to lead to corrupt indexes. You might need +REINDEX to fix existing indexes on +textual columns if this has happened to you.

  • Allow more flexible relocation of installation +directories (Tom)

    Previous releases supported relocation only if all installation +directory paths were the same except for the last component.

  • Fix longstanding bug in strpos() and regular expression +handling in certain rarely used Asian multi-byte character sets (Tatsuo)

  • Various fixes for functions returning RECORDs +(Tom)

  • Fix bug in /contrib/pgcrypto gen_salt, +which caused it not to use all available salt space for MD5 and +XDES algorithms (Marko Kreen, Solar Designer)

    Salts for Blowfish and standard DES are unaffected.

  • Fix /contrib/dblink to throw an error, +rather than crashing, when the number of columns specified is different from +what's actually returned by the query (Joe)


PrevHomeNext
Release 8.0.7UpRelease 8.0.5
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-7.html b/doc/src/sgml/html/release-8-0-7.html new file mode 100644 index 000000000..566ae0e3b --- /dev/null +++ b/doc/src/sgml/html/release-8-0-7.html @@ -0,0 +1,376 @@ + +Release 8.0.7

E.130. Release 8.0.7

Release Date: 2006-02-14

This release contains a variety of fixes from 8.0.6. + For information about new features in the 8.0 major release, see + Section E.137. +

E.130.1. Migration to Version 8.0.7

A dump/restore is not required for those running 8.0.X. However, + if you are upgrading from a version earlier than 8.0.6, see the release + notes for 8.0.6. +

E.130.2. Changes

  • Fix potential crash in SET +SESSION AUTHORIZATION (CVE-2006-0553)

    An unprivileged user could crash the server process, resulting in +momentary denial of service to other users, if the server has been compiled +with Asserts enabled (which is not the default). +Thanks to Akio Ishida for reporting this problem.

  • Fix bug with row visibility logic in self-inserted +rows (Tom)

    Under rare circumstances a row inserted by the current command +could be seen as already valid, when it should not be. Repairs bug +created in 8.0.4, 7.4.9, and 7.3.11 releases.

  • Fix race condition that could lead to "file already +exists" errors during pg_clog and pg_subtrans file creation +(Tom)

  • Fix cases that could lead to crashes if a cache-invalidation +message arrives at just the wrong time (Tom)

  • Properly check DOMAIN constraints for +UNKNOWN parameters in prepared statements +(Neil)

  • Ensure ALTER COLUMN TYPE will process +FOREIGN KEY, UNIQUE, and PRIMARY KEY +constraints in the proper order (Nakano Yoshihisa)

  • Fixes to allow restoring dumps that have cross-schema +references to custom operators or operator classes (Tom)

  • Allow pg_restore to continue properly after a +COPY failure; formerly it tried to treat the remaining +COPY data as SQL commands (Stephen Frost)

  • Fix pg_ctl unregister crash +when the data directory is not specified (Magnus)

  • Fix ecpg crash on AMD64 and PPC +(Neil)

  • Recover properly if error occurs during argument passing +in PL/python (Neil)

  • Fix PL/perl's handling of locales on +Win32 to match the backend (Andrew)

  • Fix crash when log_min_messages is set to +DEBUG3 or above in postgresql.conf on Win32 +(Bruce)

  • Fix pgxs -L library path +specification for Win32, Cygwin, OS X, AIX (Bruce)

  • Check that SID is enabled while checking for Win32 admin +privileges (Magnus)

  • Properly reject out-of-range date inputs (Kris +Jurka)

  • Portability fix for testing presence of finite +and isinf during configure (Tom)


PrevHomeNext
Release 8.0.8UpRelease 8.0.6
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-8.html b/doc/src/sgml/html/release-8-0-8.html new file mode 100644 index 000000000..79ea49a37 --- /dev/null +++ b/doc/src/sgml/html/release-8-0-8.html @@ -0,0 +1,399 @@ + +Release 8.0.8

E.129. Release 8.0.8

Release Date: 2006-05-23

This release contains a variety of fixes from 8.0.7, + including patches for extremely serious security issues. + For information about new features in the 8.0 major release, see + Section E.137. +

E.129.1. Migration to Version 8.0.8

A dump/restore is not required for those running 8.0.X. However, + if you are upgrading from a version earlier than 8.0.6, see the release + notes for 8.0.6. +

Full security against the SQL-injection attacks described in + CVE-2006-2313 and CVE-2006-2314 might require changes in application + code. If you have applications that embed untrustworthy strings + into SQL commands, you should examine them as soon as possible to + ensure that they are using recommended escaping techniques. In + most cases, applications should be using subroutines provided by + libraries or drivers (such as libpq's + PQescapeStringConn()) to perform string escaping, + rather than relying on ad hoc code to do it. +

E.129.2. Changes

  • Change the server to reject invalidly-encoded multibyte +characters in all cases (Tatsuo, Tom)

    While PostgreSQL has been moving in this direction for +some time, the checks are now applied uniformly to all encodings and all +textual input, and are now always errors not merely warnings. This change +defends against SQL-injection attacks of the type described in CVE-2006-2313.

  • Reject unsafe uses of \' in string literals

    As a server-side defense against SQL-injection attacks of the type +described in CVE-2006-2314, the server now only accepts '' and not +\' as a representation of ASCII single quote in SQL string +literals. By default, \' is rejected only when +client_encoding is set to a client-only encoding (SJIS, BIG5, GBK, +GB18030, or UHC), which is the scenario in which SQL injection is possible. +A new configuration parameter backslash_quote is available to +adjust this behavior when needed. Note that full security against +CVE-2006-2314 might require client-side changes; the purpose of +backslash_quote is in part to make it obvious that insecure +clients are insecure.

  • Modify libpq's string-escaping routines to be +aware of encoding considerations and +standard_conforming_strings

    This fixes libpq-using applications for the security +issues described in CVE-2006-2313 and CVE-2006-2314, and also future-proofs +them against the planned changeover to SQL-standard string literal syntax. +Applications that use multiple PostgreSQL connections +concurrently should migrate to PQescapeStringConn() and +PQescapeByteaConn() to ensure that escaping is done correctly +for the settings in use in each database connection. Applications that +do string escaping "by hand" should be modified to rely on library +routines instead.

  • Fix some incorrect encoding conversion functions

    win1251_to_iso, alt_to_iso, +euc_tw_to_big5, euc_tw_to_mic, +mic_to_euc_tw were all broken to varying +extents.

  • Clean up stray remaining uses of \' in strings +(Bruce, Jan)

  • Fix bug that sometimes caused OR'd index scans to +miss rows they should have returned

  • Fix WAL replay for case where a btree index has been +truncated

  • Fix SIMILAR TO for patterns involving +| (Tom)

  • Fix SELECT INTO and CREATE TABLE AS to +create tables in the default tablespace, not the base directory (Kris +Jurka)

  • Fix server to use custom DH SSL parameters correctly (Michael +Fuhr)

  • Fix for Bonjour on Intel Macs (Ashley Clark)

  • Fix various minor memory leaks

  • Fix problem with password prompting on some Win32 systems +(Robert Kinberg)


PrevHomeNext
Release 8.0.9UpRelease 8.0.7
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0-9.html b/doc/src/sgml/html/release-8-0-9.html new file mode 100644 index 000000000..cd1c09e9a --- /dev/null +++ b/doc/src/sgml/html/release-8-0-9.html @@ -0,0 +1,296 @@ + +Release 8.0.9

E.128. Release 8.0.9

Release Date: 2006-10-16

This release contains a variety of fixes from 8.0.8. + For information about new features in the 8.0 major release, see + Section E.137. +

E.128.1. Migration to Version 8.0.9

A dump/restore is not required for those running 8.0.X. However, + if you are upgrading from a version earlier than 8.0.6, see the release + notes for 8.0.6. +

E.128.2. Changes

  • Fix crash when referencing NEW row +values in rule WHERE expressions (Tom)

  • Fix core dump when an untyped literal is taken as +ANYARRAY

  • Fix mishandling of AFTER triggers when query contains a SQL +function returning multiple rows (Tom)

  • Fix ALTER TABLE ... TYPE to recheck +NOT NULL for USING clause (Tom)

  • Fix string_to_array() to handle overlapping + matches for the separator string

    For example, string_to_array('123xx456xxx789', 'xx').

  • Fix corner cases in pattern matching for + psql's \d commands

  • Fix index-corrupting bugs in /contrib/ltree + (Teodor)

  • Numerous robustness fixes in ecpg (Joachim +Wieland)

  • Fix backslash escaping in /contrib/dbmirror

  • Fix instability of statistics collection on Win32 (Tom, Andrew)

  • Fixes for AIX and +Intel compilers (Tom)


PrevHomeNext
Release 8.0.10UpRelease 8.0.8
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-0.html b/doc/src/sgml/html/release-8-0.html new file mode 100644 index 000000000..3779d5ae2 --- /dev/null +++ b/doc/src/sgml/html/release-8-0.html @@ -0,0 +1,3536 @@ + +Release 8.0

E.137. Release 8.0

Release Date: 2005-01-19

E.137.1. Overview

Major changes in this release: +

Microsoft Windows Native Server

This is the first PostgreSQL release + to run natively on Microsoft Windows® as + a server. It can run as a Windows service. This + release supports NT-based Windows releases like + Windows 2000 SP4, Windows XP, and + Windows 2003. Older releases like + Windows 95, Windows 98, and + Windows ME are not supported because these operating + systems do not have the infrastructure to support + PostgreSQL. A separate installer + project has been created to ease installation on + Windows — see http://www.postgresql.org/ftp/win32/. +

Although tested throughout our release cycle, the Windows port + does not have the benefit of years of use in production + environments that PostgreSQL has on + Unix platforms. Therefore it should be treated with the same + level of caution as you would a new product. +

Previous releases required the Unix emulation toolkit + Cygwin in order to run the server on Windows + operating systems. PostgreSQL has + supported native clients on Windows for many years. +

Savepoints

Savepoints allow specific parts of a transaction to be aborted + without affecting the remainder of the transaction. Prior + releases had no such capability; there was no way to recover + from a statement failure within a transaction except by + aborting the whole transaction. This feature is valuable for + application writers who require error recovery within a + complex transaction. +

Point-In-Time Recovery

In previous releases there was no way to recover from disk + drive failure except to restore from a previous backup or use + a standby replication server. Point-in-time recovery allows + continuous backup of the server. You can recover either to + the point of failure or to some transaction in the past. +

Tablespaces

Tablespaces allow administrators to select different file systems + for storage of individual tables, indexes, and databases. + This improves performance and control over disk space + usage. Prior releases used initlocation and + manual symlink management for such tasks. +

Improved Buffer Management, CHECKPOINT, + VACUUM

This release has a more intelligent buffer replacement strategy, + which will make better use of available shared buffers and + improve performance. The performance impact of vacuum and + checkpoints is also lessened. +

Change Column Types

A column's data type can now be changed with ALTER + TABLE. +

New Perl Server-Side Language

A new version of the plperl server-side language now + supports a persistent shared storage area, triggers, returning records + and arrays of records, and SPI calls to access the database. +

Comma-separated-value (CSV) support in COPY

COPY can now read and write + comma-separated-value files. It has the flexibility to + interpret nonstandard quoting and separation characters too. +

E.137.2. Migration to Version 8.0

A dump/restore using pg_dump is + required for those wishing to migrate data from any previous + release. +

Observe the following incompatibilities: +

  • In READ COMMITTED serialization mode, volatile functions + now see the results of concurrent transactions committed up to the + beginning of each statement within the function, rather than up to the + beginning of the interactive command that called the function. +

  • Functions declared STABLE or IMMUTABLE always + use the snapshot of the calling query, and therefore do not see the + effects of actions taken after the calling query starts, whether in + their own transaction or other transactions. Such a function must be + read-only, too, meaning that it cannot use any SQL commands other than + SELECT. +

  • Nondeferred AFTER triggers are now fired immediately + after completion of the triggering query, rather than upon + finishing the current interactive command. This makes a + difference when the triggering query occurred within a function: + the trigger is invoked before the function proceeds to its next + operation. +

  • Server configuration parameters virtual_host and + tcpip_socket have been replaced with a more general + parameter listen_addresses. Also, the server now listens on + localhost by default, which eliminates the need for the + -i postmaster switch in many scenarios. +

  • Server configuration parameters SortMem and + VacuumMem have been renamed to work_mem + and maintenance_work_mem to better reflect their + use. The original names are still supported in + SET and SHOW. +

  • Server configuration parameters log_pid, + log_timestamp, and log_source_port have been + replaced with a more general parameter log_line_prefix. +

  • Server configuration parameter syslog has been + replaced with a more logical log_destination variable to + control the log output destination. +

  • Server configuration parameter log_statement has been + changed so it can selectively log just database modification or + data definition statements. Server configuration parameter + log_duration now prints only when log_statement + prints the query. +

  • Server configuration parameter max_expr_depth parameter has + been replaced with max_stack_depth which measures the + physical stack size rather than the expression nesting depth. This + helps prevent session termination due to stack overflow caused by + recursive functions. +

  • The length() function no longer counts trailing spaces in + CHAR(n) values. +

  • Casting an integer to BIT(N) selects the rightmost N bits of the + integer, not the leftmost N bits as before. +

  • Updating an element or slice of a NULL array value now produces + a nonnull array result, namely an array containing + just the assigned-to positions. +

  • Syntax checking of array input values has been tightened up + considerably. Junk that was previously allowed in odd places with + odd results now causes an error. Empty-string element values + must now be written as "", rather than writing nothing. + Also changed behavior with respect to whitespace surrounding + array elements: trailing whitespace is now ignored, for symmetry + with leading whitespace (which has always been ignored). +

  • Overflow in integer arithmetic operations is now detected and + reported as an error. +

  • The arithmetic operators associated with the single-byte + "char" data type have been removed. +

  • The extract() function (also called + date_part) now returns the proper year for BC dates. + It previously returned one less than the correct year. The + function now also returns the proper values for millennium and + century. +

  • CIDR values now must have their nonmasked bits be zero. + For example, we no longer allow + 204.248.199.1/31 as a CIDR value. Such + values should never have been accepted by + PostgreSQL and will now be rejected. +

  • EXECUTE now returns a completion tag that + matches the executed statement. +

  • psql's \copy command now reads or + writes to the query's stdin/stdout, rather than + psql's stdin/stdout. The previous + behavior can be accessed via new + pstdin/pstdout parameters. +

  • The JDBC client interface has been removed from the core + distribution, and is now hosted at http://jdbc.postgresql.org. +

  • The Tcl client interface has also been removed. There are several + Tcl interfaces now hosted at http://gborg.postgresql.org. +

  • The server now uses its own time zone database, rather than the + one supplied by the operating system. This will provide consistent + behavior across all platforms. In most cases, there should be + little noticeable difference in time zone behavior, except that + the time zone names used by SET/SHOW + TimeZone might be different from what your platform provides. +

  • Configure's threading option no longer requires + users to run tests or edit configuration files; threading options + are now detected automatically. +

  • Now that tablespaces have been implemented, + initlocation has been removed. +

  • The API for user-defined GiST indexes has been changed. The + Union and PickSplit methods are now passed a pointer to a + special GistEntryVector structure, + rather than a bytea. +

E.137.3. Deprecated Features

Some aspects of PostgreSQL's behavior + have been determined to be suboptimal. For the sake of backward + compatibility these have not been removed in 8.0, but they are + considered deprecated and will be removed in the next major + release. +

  • The 8.1 release will remove the to_char() function + for intervals. +

  • The server now warns of empty strings passed to + oid/float4/float8 data + types, but continues to interpret them as zeroes as before. + In the next major release, empty strings will be considered + invalid input for these data types. +

  • By default, tables in PostgreSQL 8.0 + and earlier are created with OIDs. In the next release, + this will not be the case: to create a table + that contains OIDs, the WITH OIDS clause must + be specified or the default_with_oids + configuration parameter must be set. Users are encouraged to + explicitly specify WITH OIDS if their tables + require OIDs for compatibility with future releases of + PostgreSQL. +

E.137.4. Changes

Below you will find a detailed account of the changes between + release 8.0 and the previous major release. +

E.137.4.1. Performance Improvements

  • Support cross-data-type index usage (Tom) +

    Before this change, many queries would not use an index if the data + types did not match exactly. This improvement makes index usage more + intuitive and consistent. +

  • New buffer replacement strategy that improves caching (Jan) +

    Prior releases used a least-recently-used (LRU) cache to keep + recently referenced pages in memory. The LRU algorithm + did not consider the number of times a specific cache entry was + accessed, so large table scans could force out useful cache pages. + The new cache algorithm uses four separate lists to track most + recently used and most frequently used cache pages and dynamically + optimize their replacement based on the work load. This should + lead to much more efficient use of the shared buffer cache. + Administrators who have tested shared buffer sizes in the past + should retest with this new cache replacement policy. +

  • Add subprocess to write dirty buffers periodically to reduce + checkpoint writes (Jan) +

    In previous releases, the checkpoint process, which runs every few + minutes, would write all dirty buffers to the operating system's + buffer cache then flush all dirty operating system buffers to + disk. This resulted in a periodic spike in disk usage that often + hurt performance. The new code uses a background writer to trickle + disk writes at a steady pace so checkpoints have far fewer dirty + pages to write to disk. Also, the new code does not issue a global + sync() call, but instead fsync()s just + the files written since the last checkpoint. This should improve + performance and minimize degradation during checkpoints. +

  • Add ability to prolong vacuum to reduce performance impact (Jan) +

    On busy systems, VACUUM performs many I/O + requests which can hurt performance for other users. This + release allows you to slow down VACUUM to + reduce its impact on other users, though this increases the + total duration of VACUUM. +

  • Improve B-tree index performance for duplicate keys (Dmitry Tkach, Tom) +

    This improves the way indexes are scanned when many duplicate + values exist in the index. +

  • Use dynamically-generated table size estimates while planning (Tom) +

    Formerly the planner estimated table sizes using the values seen + by the last VACUUM or ANALYZE, + both as to physical table size (number of pages) and number of rows. + Now, the current physical table size is obtained from the kernel, + and the number of rows is estimated by multiplying the table size + by the row density (rows per page) seen by the last + VACUUM or ANALYZE. This should + produce more reliable estimates in cases where the table size has + changed significantly since the last housekeeping command. +

  • Improved index usage with OR clauses (Tom) +

    This allows the optimizer to use indexes in statements with many OR + clauses that would not have been indexed in the past. It can also use + multi-column indexes where the first column is specified and the second + column is part of an OR clause. +

  • Improve matching of partial index clauses (Tom) +

    The server is now smarter about using partial indexes in queries + involving complex WHERE clauses. +

  • Improve performance of the GEQO optimizer (Tom) +

    The GEQO optimizer is used to plan queries involving many tables (by + default, twelve or more). This release speeds up the way queries are + analyzed to decrease time spent in optimization. +

  • Miscellaneous optimizer improvements +

    There is not room here to list all the minor improvements made, but + numerous special cases work better than in prior releases. +

  • Improve lookup speed for C functions (Tom) +

    This release uses a hash table to lookup information for dynamically + loaded C functions. This improves their speed so they perform nearly as + quickly as functions that are built into the server executable. +

  • Add type-specific ANALYZE statistics + capability (Mark Cave-Ayland) +

    This feature allows more flexibility in generating statistics + for nonstandard data types. +

  • ANALYZE now collects statistics for + expression indexes (Tom) +

    Expression indexes (also called functional indexes) allow users to + index not just columns but the results of expressions and function + calls. With this release, the optimizer can gather and use statistics + about the contents of expression indexes. This will greatly improve + the quality of planning for queries in which an expression index is + relevant. +

  • New two-stage sampling method for ANALYZE + (Manfred Koizar) +

    This gives better statistics when the density of valid rows is very + different in different regions of a table. +

  • Speed up TRUNCATE (Tom) +

    This buys back some of the performance loss observed in 7.4, while still + keeping TRUNCATE transaction-safe. +

E.137.4.2. Server Changes

  • Add WAL file archiving and point-in-time recovery (Simon Riggs) +

  • Add tablespaces so admins can control disk layout (Gavin) +

  • Add a built-in log rotation program (Andreas Pflug) +

    It is now possible to log server messages conveniently without + relying on either syslog or an external log + rotation program. +

  • Add new read-only server configuration parameters to show server + compile-time settings: block_size, + integer_datetimes, max_function_args, + max_identifier_length, max_index_keys (Joe) +

  • Make quoting of sameuser, samegroup, and + all remove special meaning of these terms in + pg_hba.conf (Andrew) +

  • Use clearer IPv6 name ::1/128 for + localhost in default pg_hba.conf (Andrew) +

  • Use CIDR format in pg_hba.conf examples (Andrew) +

  • Rename server configuration parameters SortMem and + VacuumMem to work_mem and + maintenance_work_mem (Old names still supported) (Tom) +

    This change was made to clarify that bulk operations such as index and + foreign key creation use maintenance_work_mem, while + work_mem is for workspaces used during query execution. +

  • Allow logging of session disconnections using server configuration + log_disconnections (Andrew) +

  • Add new server configuration parameter log_line_prefix to + allow control of information emitted in each log line (Andrew) +

    Available information includes user name, database name, remote IP + address, and session start time. +

  • Remove server configuration parameters log_pid, + log_timestamp, log_source_port; functionality + superseded by log_line_prefix (Andrew) +

  • Replace the virtual_host and tcpip_socket + parameters with a unified listen_addresses parameter + (Andrew, Tom) +

    virtual_host could only specify a single IP address to + listen on. listen_addresses allows multiple addresses + to be specified. +

  • Listen on localhost by default, which eliminates the need for the + -i postmaster switch in many scenarios (Andrew) +

    Listening on localhost (127.0.0.1) opens no new + security holes but allows configurations like Windows and JDBC, + which do not support local sockets, to work without special + adjustments. +

  • Remove syslog server configuration parameter, and add more + logical log_destination variable to control log output + location (Magnus) +

  • Change server configuration parameter log_statement to take + values all, mod, ddl, or + none to select which queries are logged (Bruce) +

    This allows administrators to log only data definition changes or + only data modification statements. +

  • Some logging-related configuration parameters could formerly be adjusted + by ordinary users, but only in the "more verbose" direction. + They are now treated more strictly: only superusers can set them. + However, a superuser can use ALTER USER to provide per-user + settings of these values for non-superusers. Also, it is now possible + for superusers to set values of superuser-only configuration parameters + via PGOPTIONS. +

  • Allow configuration files to be placed outside the data directory (mlw) +

    By default, configuration files are kept in the cluster's top directory. + With this addition, configuration files can be placed outside the + data directory, easing administration. +

  • Plan prepared queries only when first executed so constants can be + used for statistics (Oliver Jowett) +

    Prepared statements plan queries once and execute them many + times. While prepared queries avoid the overhead of re-planning + on each use, the quality of the plan suffers from not knowing the exact + parameters to be used in the query. In this release, planning of + unnamed prepared statements is delayed until the first execution, + and the actual parameter values of that execution are used as + optimization hints. This allows use of out-of-line parameter passing + without incurring a performance penalty. +

  • Allow DECLARE CURSOR to take parameters + (Oliver Jowett) +

    It is now useful to issue DECLARE CURSOR in a + Parse message with parameters. The parameter values + sent at Bind time will be substituted into the + execution of the cursor's query. +

  • Fix hash joins and aggregates of inet and + cidr data types (Tom) +

    Release 7.4 handled hashing of mixed inet and + cidr values incorrectly. (This bug did not exist + in prior releases because they wouldn't try to hash either + data type.) +

  • Make log_duration print only when log_statement + prints the query (Ed L.) +

E.137.4.3. Query Changes

  • Add savepoints (nested transactions) (Alvaro) +

  • Unsupported isolation levels are now accepted and promoted to the + nearest supported level (Peter) +

    The SQL specification states that if a database doesn't support a + specific isolation level, it should use the next more restrictive level. + This change complies with that recommendation. +

  • Allow BEGIN WORK to specify transaction + isolation levels like START TRANSACTION does + (Bruce) +

  • Fix table permission checking for cases in which rules generate + a query type different from the originally submitted query (Tom) +

  • Implement dollar quoting to simplify single-quote usage (Andrew, Tom, + David Fetter) +

    In previous releases, because single quotes had to be used to + quote a function's body, the use of single quotes inside the + function text required use of two single quotes or other error-prone + notations. With this release we add the ability to use "dollar + quoting" to quote a block of text. The ability to use different + quoting delimiters at different nesting levels greatly simplifies + the task of quoting correctly, especially in complex functions. + Dollar quoting can be used anywhere quoted text is needed. +

  • Make CASE val WHEN compval1 THEN ... evaluate val only once (Tom) +

    CASE no longer evaluates the tested expression multiple + times. This has benefits when the expression is complex or is + volatile. +

  • Test HAVING before computing target list of an + aggregate query (Tom) +

    Fixes improper failure of cases such as SELECT SUM(win)/SUM(lose) + ... GROUP BY ... HAVING SUM(lose) > 0. This should work but formerly + could fail with divide-by-zero. +

  • Replace max_expr_depth parameter with + max_stack_depth parameter, measured in kilobytes of stack + size (Tom) +

    This gives us a fairly bulletproof defense against crashing due to + runaway recursive functions. Instead of measuring the depth of expression + nesting, we now directly measure the size of the execution stack. +

  • Allow arbitrary row expressions (Tom) +

    This release allows SQL expressions to contain arbitrary composite + types, that is, row values. It also allows functions to more easily + take rows as arguments and return row values. +

  • Allow LIKE/ILIKE to be used as the operator + in row and subselect comparisons (Fabien Coelho) +

  • Avoid locale-specific case conversion of basic ASCII letters in + identifiers and keywords (Tom) +

    This solves the "Turkish problem" with mangling of words + containing I and i. Folding of characters + outside the 7-bit-ASCII set is still locale-aware. +

  • Improve syntax error reporting (Fabien, Tom) +

    Syntax error reports are more useful than before. +

  • Change EXECUTE to return a completion tag + matching the executed statement (Kris Jurka) +

    Previous releases return an EXECUTE tag for + any EXECUTE call. In this release, the tag + returned will reflect the command executed. +

  • Avoid emitting NATURAL CROSS JOIN in rule listings (Tom) +

    Such a clause makes no logical sense, but in some cases the rule + decompiler formerly produced this syntax. +

E.137.4.4. Object Manipulation Changes

  • Add COMMENT ON for casts, conversions, languages, + operator classes, and large objects (Christopher) +

  • Add new server configuration parameter default_with_oids to + control whether tables are created with OIDs by default (Neil) +

    This allows administrators to control whether CREATE + TABLE commands create tables with or without OID + columns by default. (Note: the current factory default setting for + default_with_oids is TRUE, but the default + will become FALSE in future releases.) +

  • Add WITH / WITHOUT OIDS clause to + CREATE TABLE AS (Neil) +

  • Allow ALTER TABLE DROP COLUMN to drop an OID + column (ALTER TABLE SET WITHOUT OIDS still works) + (Tom) +

  • Allow composite types as table columns (Tom) +

  • Allow ALTER ... ADD COLUMN with defaults and + NOT NULL constraints; works per SQL spec (Rod) +

    It is now possible for ADD COLUMN to create a column + that is not initially filled with NULLs, but with a specified + default value. +

  • Add ALTER COLUMN TYPE to change column's type (Rod) +

    It is now possible to alter a column's data type without dropping + and re-adding the column. +

  • Allow multiple ALTER actions in a single ALTER + TABLE command (Rod) +

    This is particularly useful for ALTER commands that + rewrite the table (which include ALTER COLUMN TYPE and + ADD COLUMN with a default). By grouping + ALTER commands together, the table need be rewritten + only once. +

  • Allow ALTER TABLE to add SERIAL + columns (Tom) +

    This falls out from the new capability of specifying defaults for new + columns. +

  • Allow changing the owners of aggregates, conversions, databases, + functions, operators, operator classes, schemas, types, and tablespaces + (Christopher, Euler Taveira de Oliveira) +

    Previously this required modifying the system tables directly. +

  • Allow temporary object creation to be limited to SECURITY + DEFINER functions (Sean Chittenden) +

  • Add ALTER TABLE ... SET WITHOUT CLUSTER (Christopher) +

    Prior to this release, there was no way to clear an auto-cluster + specification except to modify the system tables. +

  • Constraint/Index/SERIAL names are now + table_column_type + with numbers appended to guarantee uniqueness within the schema + (Tom) +

    The SQL specification states that such names should be unique + within a schema. +

  • Add pg_get_serial_sequence() to return a + SERIAL column's sequence name (Christopher) +

    This allows automated scripts to reliably find the SERIAL + sequence name. +

  • Warn when primary/foreign key data type mismatch requires costly lookup +

  • New ALTER INDEX command to allow moving of indexes + between tablespaces (Gavin) +

  • Make ALTER TABLE OWNER change dependent sequence + ownership too (Alvaro) +

E.137.4.5. Utility Command Changes

  • Allow CREATE SCHEMA to create triggers, + indexes, and sequences (Neil) +

  • Add ALSO keyword to CREATE RULE (Fabien + Coelho) +

    This allows ALSO to be added to rule creation to contrast it with + INSTEAD rules. +

  • Add NOWAIT option to LOCK (Tatsuo) +

    This allows the LOCK command to fail if it + would have to wait for the requested lock. +

  • Allow COPY to read and write + comma-separated-value (CSV) files (Andrew, Bruce) +

  • Generate error if the COPY delimiter and NULL + string conflict (Bruce) +

  • GRANT/REVOKE behavior + follows the SQL spec more closely +

  • Avoid locking conflict between CREATE INDEX + and CHECKPOINT (Tom) +

    In 7.3 and 7.4, a long-running B-tree index build could block concurrent + CHECKPOINTs from completing, thereby causing WAL bloat because the + WAL log could not be recycled. +

  • Database-wide ANALYZE does not hold locks + across tables (Tom) +

    This reduces the potential for deadlocks against other backends + that want exclusive locks on tables. To get the benefit of this + change, do not execute database-wide ANALYZE + inside a transaction block (BEGIN block); it + must be able to commit and start a new transaction for each + table. +

  • REINDEX does not exclusively lock the index's + parent table anymore +

    The index itself is still exclusively locked, but readers of the + table can continue if they are not using the particular index + being rebuilt. +

  • Erase MD5 user passwords when a user is renamed (Bruce) +

    PostgreSQL uses the user name as salt + when encrypting passwords via MD5. When a user's name is changed, + the salt will no longer match the stored MD5 password, so the + stored password becomes useless. In this release a notice is + generated and the password is cleared. A new password must then + be assigned if the user is to be able to log in with a password. +

  • New pg_ctl kill option for Windows (Andrew) +

    Windows does not have a kill command to send signals to + backends so this capability was added to pg_ctl. +

  • Information schema improvements +

  • Add --pwfile option to + initdb so the initial password can be + set by GUI tools (Magnus) +

  • Detect locale/encoding mismatch in + initdb (Peter) +

  • Add register command to pg_ctl to + register Windows operating system service (Dave Page) +

E.137.4.6. Data Type and Function Changes

  • More complete support for composite types (row types) (Tom) +

    Composite values can be used in many places where only scalar values + worked before. +

  • Reject nonrectangular array values as erroneous (Joe) +

    Formerly, array_in would silently build a + surprising result. +

  • Overflow in integer arithmetic operations is now detected (Tom) +

  • The arithmetic operators associated with the single-byte + "char" data type have been removed. +

    Formerly, the parser would select these operators in many situations + where an "unable to select an operator" error would be more + appropriate, such as null * null. If you actually want + to do arithmetic on a "char" column, you can cast it to + integer explicitly. +

  • Syntax checking of array input values considerably tightened up (Joe) +

    Junk that was previously allowed in odd places with odd results + now causes an ERROR, for example, non-whitespace + after the closing right brace. +

  • Empty-string array element values must now be written as + "", rather than writing nothing (Joe) +

    Formerly, both ways of writing an empty-string element value were + allowed, but now a quoted empty string is required. The case where + nothing at all appears will probably be considered to be a NULL + element value in some future release. +

  • Array element trailing whitespace is now ignored (Joe) +

    Formerly leading whitespace was ignored, but trailing whitespace + between an element value and the delimiter or right brace was + significant. Now trailing whitespace is also ignored. +

  • Emit array values with explicit array bounds when lower bound is not one + (Joe) +

  • Accept YYYY-monthname-DD as a date string (Tom) +

  • Make netmask and hostmask functions + return maximum-length mask length (Tom) +

  • Change factorial function to return numeric (Gavin) +

    Returning numeric allows the factorial function to + work for a wider range of input values. +

  • to_char/to_date() date conversion + improvements (Kurt Roeckx, Fabien Coelho) +

  • Make length() disregard trailing spaces in + CHAR(n) (Gavin) +

    This change was made to improve consistency: trailing spaces are + semantically insignificant in CHAR(n) data, so they + should not be counted by length(). +

  • Warn about empty string being passed to + OID/float4/float8 data types (Neil) +

    8.1 will throw an error instead. +

  • Allow leading or trailing whitespace in + int2/int4/int8/float4/float8 + input routines + (Neil) +

  • Better support for IEEE Infinity and NaN + values in float4/float8 (Neil) +

    These should now work on all platforms that support IEEE-compliant + floating point arithmetic. +

  • Add week option to date_trunc() (Robert Creager) +

  • Fix to_char for 1 BC + (previously it returned 1 AD) (Bruce) +

  • Fix date_part(year) for BC dates (previously it + returned one less than the correct year) (Bruce) +

  • Fix date_part() to return the proper millennium and + century (Fabien Coelho) +

    In previous versions, the century and millennium results had a wrong + number and started in the wrong year, as compared to standard + reckoning of such things. +

  • Add ceiling() as an alias for ceil(), + and power() as an alias for pow() for + standards compliance (Neil) +

  • Change ln(), log(), + power(), and sqrt() to emit the correct + SQLSTATE error codes for certain error conditions, as + specified by SQL:2003 (Neil) +

  • Add width_bucket() function as defined by SQL:2003 (Neil) +

  • Add generate_series() functions to simplify working + with numeric sets (Joe) +

  • Fix upper/lower/initcap() functions to work with + multibyte encodings (Tom) +

  • Add boolean and bitwise integer AND/OR + aggregates (Fabien Coelho) +

  • New session information functions to return network addresses for client + and server (Sean Chittenden) +

  • Add function to determine the area of a closed path (Sean Chittenden) +

  • Add function to send cancel request to other backends (Magnus) +

  • Add interval plus datetime operators (Tom) +

    The reverse ordering, datetime plus interval, + was already supported, but both are required by the SQL standard. +

  • Casting an integer to BIT(N) selects the rightmost N bits + of the integer + (Tom) +

    In prior releases, the leftmost N bits were selected, but this was + deemed unhelpful, not to mention inconsistent with casting from bit + to int. +

  • Require CIDR values to have all nonmasked bits be zero + (Kevin Brintnall) +

E.137.4.7. Server-Side Language Changes

  • In READ COMMITTED serialization mode, volatile functions + now see the results of concurrent transactions committed up to the + beginning of each statement within the function, rather than up to the + beginning of the interactive command that called the function. +

  • Functions declared STABLE or IMMUTABLE always + use the snapshot of the calling query, and therefore do not see the + effects of actions taken after the calling query starts, whether in + their own transaction or other transactions. Such a function must be + read-only, too, meaning that it cannot use any SQL commands other than + SELECT. There is a considerable performance gain from + declaring a function STABLE or IMMUTABLE + rather than VOLATILE. +

  • Nondeferred AFTER triggers are now fired immediately + after completion of the triggering query, rather than upon + finishing the current interactive command. This makes a difference + when the triggering query occurred within a function: the trigger + is invoked before the function proceeds to its next operation. For + example, if a function inserts a new row into a table, any + nondeferred foreign key checks occur before proceeding with the + function. +

  • Allow function parameters to be declared with names (Dennis Björklund) +

    This allows better documentation of functions. Whether the names + actually do anything depends on the specific function language + being used. +

  • Allow PL/pgSQL parameter names to be referenced in the function (Dennis Björklund) +

    This basically creates an automatic alias for each named parameter. +

  • Do minimal syntax checking of PL/pgSQL functions at creation time (Tom) +

    This allows us to catch simple syntax errors sooner. +

  • More support for composite types (row and record variables) in PL/pgSQL +

    For example, it now works to pass a rowtype variable to another function + as a single variable. +

  • Default values for PL/pgSQL variables can now reference previously + declared variables +

  • Improve parsing of PL/pgSQL FOR loops (Tom) +

    Parsing is now driven by presence of ".." rather than + data type of FOR variable. This makes no difference for + correct functions, but should result in more understandable error + messages when a mistake is made. +

  • Major overhaul of PL/Perl server-side language (Command Prompt, Andrew Dunstan) +

  • In PL/Tcl, SPI commands are now run in subtransactions. If an error + occurs, the subtransaction is cleaned up and the error is reported + as an ordinary Tcl error, which can be trapped with catch. + Formerly, it was not possible to catch such errors. +

  • Accept ELSEIF in PL/pgSQL (Neil) +

    Previously PL/pgSQL only allowed ELSIF, but many people + are accustomed to spelling this keyword ELSEIF. +

E.137.4.8. psql Changes

  • Improve psql information display about database + objects (Christopher) +

  • Allow psql to display group membership in + \du and \dg (Markus Bertheau) +

  • Prevent psql \dn from showing + temporary schemas (Bruce) +

  • Allow psql to handle tilde user expansion for file + names (Zach Irmen) +

  • Allow psql to display fancy prompts, including + color, via readline (Reece Hart, Chet Ramey) +

  • Make psql \copy match COPY command syntax + fully (Tom) +

  • Show the location of syntax errors (Fabien Coelho, Tom) +

  • Add CLUSTER information to psql + \d display + (Bruce) +

  • Change psql \copy stdin/stdout to read + from command input/output (Bruce) +

  • Add pstdin/pstdout to read from + psql's stdin/stdout (Mark + Feit) +

  • Add global psql configuration file, psqlrc.sample + (Bruce) +

    This allows a central file where global psql startup commands can + be stored. +

  • Have psql \d+ indicate if the table + has an OID column (Neil) +

  • On Windows, use binary mode in psql when reading files so control-Z + is not seen as end-of-file +

  • Have \dn+ show permissions and description for schemas (Dennis + Björklund) +

  • Improve tab completion support (Stefan Kaltenbrunn, Greg Sabino Mullane) +

  • Allow boolean settings to be set using upper or lower case (Michael Paesold) +

E.137.4.9. pg_dump Changes

  • Use dependency information to improve the reliability of + pg_dump (Tom) +

    This should solve the longstanding problems with related objects + sometimes being dumped in the wrong order. +

  • Have pg_dump output objects in alphabetical order if possible (Tom) +

    This should make it easier to identify changes between + dump files. +

  • Allow pg_restore to ignore some SQL errors (Fabien Coelho) +

    This makes pg_restore's behavior similar to the + results of feeding a pg_dump output script to + psql. In most cases, ignoring errors and plowing + ahead is the most useful thing to do. Also added was a pg_restore + option to give the old behavior of exiting on an error. +

  • pg_restore -l display now includes + objects' schema names +

  • New begin/end markers in pg_dump text output (Bruce) +

  • Add start/stop times for + pg_dump/pg_dumpall in verbose mode + (Bruce) +

  • Allow most pg_dump options in + pg_dumpall (Christopher) +

  • Have pg_dump use ALTER OWNER rather + than SET SESSION AUTHORIZATION by default + (Christopher) +

E.137.4.10. libpq Changes

  • Make libpq's SIGPIPE handling thread-safe (Bruce) +

  • Add PQmbdsplen() which returns the display length + of a character (Tatsuo) +

  • Add thread locking to SSL and + Kerberos connections (Manfred Spraul) +

  • Allow PQoidValue(), PQcmdTuples(), and + PQoidStatus() to work on EXECUTE + commands (Neil) +

  • Add PQserverVersion() to provide more convenient + access to the server version number (Greg Sabino Mullane) +

  • Add PQprepare/PQsendPrepared() functions to support + preparing statements without necessarily specifying the data types + of their parameters (Abhijit Menon-Sen) +

  • Many ECPG improvements, including SET DESCRIPTOR (Michael) +

E.137.4.11. Source Code Changes

  • Allow the database server to run natively on Windows (Claudio, Magnus, Andrew) +

  • Shell script commands converted to C versions for Windows support (Andrew) +

  • Create an extension makefile framework (Fabien Coelho, Peter) +

    This simplifies the task of building extensions outside the original + source tree. +

  • Support relocatable installations (Bruce) +

    Directory paths for installed files (such as the + /share directory) are now computed relative to the + actual location of the executables, so that an installation tree + can be moved to another place without reconfiguring and + rebuilding. +

  • Use --with-docdir to choose installation location of documentation; also + allow --infodir (Peter) +

  • Add --without-docdir to prevent installation of documentation (Peter) +

  • Upgrade to DocBook V4.2 SGML (Peter) +

  • New PostgreSQL CVS tag (Marc) +

    This was done to make it easier for organizations to manage their + own copies of the PostgreSQL + CVS repository. File version stamps from the master + repository will not get munged by checking into or out of a copied + repository. +

  • Clarify locking code (Manfred Koizar) +

  • Buffer manager cleanup (Neil) +

  • Decouple platform tests from CPU spinlock code (Bruce, Tom) +

  • Add inlined test-and-set code on PA-RISC for gcc + (ViSolve, Tom) +

  • Improve i386 spinlock code (Manfred Spraul) +

  • Clean up spinlock assembly code to avoid warnings from newer + gcc releases (Tom) +

  • Remove JDBC from source tree; now a separate project +

  • Remove the libpgtcl client interface; now a separate project +

  • More accurately estimate memory and file descriptor usage (Tom) +

  • Improvements to the Mac OS X startup scripts (Ray A.) +

  • New fsync() test program (Bruce) +

  • Major documentation improvements (Neil, Peter) +

  • Remove pg_encoding; not needed + anymore +

  • Remove pg_id; not needed anymore +

  • Remove initlocation; not needed + anymore +

  • Auto-detect thread flags (no more manual testing) (Bruce) +

  • Use Olson's public domain timezone library (Magnus) +

  • With threading enabled, use thread flags on Unixware for + backend executables too (Bruce) +

    Unixware cannot mix threaded and nonthreaded object files in the + same executable, so everything must be compiled as threaded. +

  • psql now uses a flex-generated + lexical analyzer to process command strings +

  • Reimplement the linked list data structure used throughout the + backend (Neil) +

    This improves performance by allowing list append and length + operations to be more efficient. +

  • Allow dynamically loaded modules to create their own server configuration + parameters (Thomas Hallgren) +

  • New Brazilian version of FAQ (Euler Taveira de Oliveira) +

  • Add French FAQ (Guillaume Lelarge) +

  • New pgevent for Windows logging +

  • Make libpq and ECPG build as proper shared libraries on OS X (Tom) +

E.137.4.12. Contrib Changes

  • Overhaul of contrib/dblink (Joe) +

  • contrib/dbmirror improvements (Steven Singer) +

  • New contrib/xml2 (John Gray, Torchbox) +

  • Updated contrib/mysql +

  • New version of contrib/btree_gist (Teodor) +

  • New contrib/trgm, trigram matching for + PostgreSQL (Teodor) +

  • Many contrib/tsearch2 improvements (Teodor) +

  • Add double metaphone to contrib/fuzzystrmatch (Andrew) +

  • Allow contrib/pg_autovacuum to run as a Windows service (Dave Page) +

  • Add functions to contrib/dbsize (Andreas Pflug) +

  • Removed contrib/pg_logger: obsoleted by integrated logging + subprocess +

  • Removed contrib/rserv: obsoleted by various separate projects +


PrevHomeNext
Release 8.0.1UpRelease 7.4.30
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-1-1.html b/doc/src/sgml/html/release-8-1-1.html new file mode 100644 index 000000000..fe7758803 --- /dev/null +++ b/doc/src/sgml/html/release-8-1-1.html @@ -0,0 +1,349 @@ + +Release 8.1.1

E.109. Release 8.1.1

Release Date: 2005-12-12

This release contains a variety of fixes from 8.1.0. + For information about new features in the 8.1 major release, see + Section E.110. +

E.109.1. Migration to Version 8.1.1

A dump/restore is not required for those running 8.1.X. +

E.109.2. Changes

  • Fix incorrect optimizations of outer-join conditions +(Tom)

  • Fix problems with wrong reported column names in cases +involving sub-selects flattened by the optimizer (Tom)

  • Fix update failures in scenarios involving CHECK constraints, +toasted columns, and indexes (Tom)

  • Fix bgwriter problems after recovering from errors +(Tom)

    The background writer was found to leak buffer pins after write errors. +While not fatal in itself, this might lead to mysterious blockages of +later VACUUM commands.

  • Prevent failure if client sends Bind protocol message +when current transaction is already aborted

  • /contrib/tsearch2 and /contrib/ltree +fixes (Teodor)

  • Fix problems with translated error messages in +languages that require word reordering, such as Turkish; also problems with +unexpected truncation of output strings and wrong display of the smallest +possible bigint value (Andrew, Tom)

    These problems only appeared on platforms that were using our +port/snprintf.c code, which includes BSD variants if +--enable-nls was given, and perhaps others. In addition, +a different form of the translated-error-message problem could appear +on Windows depending on which version of libintl was used.

  • Re-allow AM/PM, HH, +HH12, and D format specifiers for +to_char(time) and to_char(interval). +(to_char(interval) should probably use +HH24.) (Bruce)

  • AIX, HPUX, and MSVC compile fixes (Tom, Hiroshi +Saito)

  • Optimizer improvements (Tom)

  • Retry file reads and writes after Windows +NO_SYSTEM_RESOURCES error (Qingqing Zhou)

  • Prevent autovacuum from crashing during +ANALYZE of expression index (Alvaro)

  • Fix problems with ON COMMIT DELETE ROWS temp +tables

  • Fix problems when a trigger alters the output of a SELECT +DISTINCT query

  • Add 8.1.0 release note item on how to migrate invalid +UTF-8 byte sequences (Paul Lindner)


PrevHomeNext
Release 8.1.2UpRelease 8.1
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-1-10.html b/doc/src/sgml/html/release-8-1-10.html new file mode 100644 index 000000000..5bbeff052 --- /dev/null +++ b/doc/src/sgml/html/release-8-1-10.html @@ -0,0 +1,308 @@ + +Release 8.1.10

E.100. Release 8.1.10

Release Date: 2007-09-17

This release contains a variety of fixes from 8.1.9. + For information about new features in the 8.1 major release, see + Section E.110. +

E.100.1. Migration to Version 8.1.10

A dump/restore is not required for those running 8.1.X. + However, if you are upgrading from a version earlier than 8.1.2, + see the release notes for 8.1.2. +

E.100.2. Changes

  • Prevent index corruption when a transaction inserts rows and + then aborts close to the end of a concurrent VACUUM + on the same table (Tom) +

  • Make CREATE DOMAIN ... DEFAULT NULL work properly (Tom) +

  • Allow the interval data type to accept input consisting only of + milliseconds or microseconds (Neil) +

  • Speed up rtree index insertion (Teodor) +

  • Fix excessive logging of SSL error messages (Tom) +

  • Fix logging so that log messages are never interleaved when using + the syslogger process (Andrew) +

  • Fix crash when log_min_error_statement logging runs out + of memory (Tom) +

  • Fix incorrect handling of some foreign-key corner cases (Tom) +

  • Prevent REINDEX and CLUSTER from failing + due to attempting to process temporary tables of other sessions (Alvaro) +

  • Update the time zone database rules, particularly New Zealand's upcoming changes (Tom) +

  • Windows socket improvements (Magnus) +

  • Suppress timezone name (%Z) in log timestamps on Windows + because of possible encoding mismatches (Tom) +

  • Require non-superusers who use /contrib/dblink to use only + password authentication, as a security measure (Joe) +


PrevHomeNext
Release 8.1.11UpRelease 8.1.9
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-1-11.html b/doc/src/sgml/html/release-8-1-11.html new file mode 100644 index 000000000..586b870e6 --- /dev/null +++ b/doc/src/sgml/html/release-8-1-11.html @@ -0,0 +1,522 @@ + +Release 8.1.11

E.99. Release 8.1.11

Release Date: 2008-01-07

This release contains a variety of fixes from 8.1.10, + including fixes for significant security issues. + For information about new features in the 8.1 major release, see + Section E.110. +

This is the last 8.1.X release for which the PostgreSQL + community will produce binary packages for Windows. + Windows users are encouraged to move to 8.2.X or later, + since there are Windows-specific fixes in 8.2.X that + are impractical to back-port. 8.1.X will continue to + be supported on other platforms. +

E.99.1. Migration to Version 8.1.11

A dump/restore is not required for those running 8.1.X. + However, if you are upgrading from a version earlier than 8.1.2, + see the release notes for 8.1.2. +

E.99.2. Changes

  • Prevent functions in indexes from executing with the privileges of + the user running VACUUM, ANALYZE, etc (Tom) +

    Functions used in index expressions and partial-index + predicates are evaluated whenever a new table entry is made. It has + long been understood that this poses a risk of trojan-horse code + execution if one modifies a table owned by an untrustworthy user. + (Note that triggers, defaults, check constraints, etc. pose the + same type of risk.) But functions in indexes pose extra danger + because they will be executed by routine maintenance operations + such as VACUUM FULL, which are commonly performed + automatically under a superuser account. For example, a nefarious user + can execute code with superuser privileges by setting up a + trojan-horse index definition and waiting for the next routine vacuum. + The fix arranges for standard maintenance operations + (including VACUUM, ANALYZE, REINDEX, + and CLUSTER) to execute as the table owner rather than + the calling user, using the same privilege-switching mechanism already + used for SECURITY DEFINER functions. To prevent bypassing + this security measure, execution of SET SESSION + AUTHORIZATION and SET ROLE is now forbidden within a + SECURITY DEFINER context. (CVE-2007-6600) +

  • Repair assorted bugs in the regular-expression package (Tom, Will Drewry) +

    Suitably crafted regular-expression patterns could cause crashes, + infinite or near-infinite looping, and/or massive memory consumption, + all of which pose denial-of-service hazards for applications that + accept regex search patterns from untrustworthy sources. + (CVE-2007-4769, CVE-2007-4772, CVE-2007-6067) +

  • Require non-superusers who use /contrib/dblink to use only + password authentication, as a security measure (Joe) +

    The fix that appeared for this in 8.1.10 was incomplete, as it plugged + the hole for only some dblink functions. (CVE-2007-6601, + CVE-2007-3278) +

  • Update time zone data files to tzdata release 2007k + (in particular, recent Argentina changes) (Tom) +

  • Improve planner's handling of LIKE/regex estimation in non-C locales + (Tom) +

  • Fix planner failure in some cases of WHERE false AND var IN + (SELECT ...) (Tom) +

  • Preserve the tablespace of indexes that are + rebuilt by ALTER TABLE ... ALTER COLUMN TYPE (Tom) +

  • Make archive recovery always start a new WAL timeline, rather than only + when a recovery stop time was used (Simon) +

    This avoids a corner-case risk of trying to overwrite an existing + archived copy of the last WAL segment, and seems simpler and cleaner + than the original definition. +

  • Make VACUUM not use all of maintenance_work_mem + when the table is too small for it to be useful (Alvaro) +

  • Fix potential crash in translate() when using a multibyte + database encoding (Tom) +

  • Fix overflow in extract(epoch from interval) for intervals + exceeding 68 years (Tom) +

  • Fix PL/Perl to not fail when a UTF-8 regular expression is used + in a trusted function (Andrew) +

  • Fix PL/Perl to cope when platform's Perl defines type bool + as int rather than char (Tom) +

    While this could theoretically happen anywhere, no standard build of + Perl did things this way ... until Mac OS X 10.5. +

  • Fix PL/Python to not crash on long exception messages (Alvaro) +

  • Fix pg_dump to correctly handle inheritance child tables + that have default expressions different from their parent's (Tom) +

  • Fix libpq crash when PGPASSFILE refers + to a file that is not a plain file (Martin Pitt) +

  • ecpg parser fixes (Michael) +

  • Make contrib/pgcrypto defend against + OpenSSL libraries that fail on keys longer than 128 + bits; which is the case at least on some Solaris versions (Marko Kreen) +

  • Make contrib/tablefunc's crosstab() handle + NULL rowid as a category in its own right, rather than crashing (Joe) +

  • Fix tsvector and tsquery output routines to + escape backslashes correctly (Teodor, Bruce) +

  • Fix crash of to_tsvector() on huge input strings (Teodor) +

  • Require a specific version of Autoconf to be used + when re-generating the configure script (Peter) +

    This affects developers and packagers only. The change was made + to prevent accidental use of untested combinations of + Autoconf and PostgreSQL versions. + You can remove the version check if you really want to use a + different Autoconf version, but it's + your responsibility whether the result works or not. +


PrevHomeNext
Release 8.1.12UpRelease 8.1.10
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-1-12.html b/doc/src/sgml/html/release-8-1-12.html new file mode 100644 index 000000000..c873f906f --- /dev/null +++ b/doc/src/sgml/html/release-8-1-12.html @@ -0,0 +1,531 @@ + +Release 8.1.12

E.98. Release 8.1.12

Release Date: never released

This release contains a variety of fixes from 8.1.11. + For information about new features in the 8.1 major release, see + Section E.110. +

E.98.1. Migration to Version 8.1.12

A dump/restore is not required for those running 8.1.X. + However, if you are upgrading from a version earlier than 8.1.2, + see the release notes for 8.1.2. +

E.98.2. Changes

  • Fix ALTER TABLE ADD COLUMN ... PRIMARY KEY so that the new + column is correctly checked to see if it's been initialized to all + non-nulls (Brendan Jurd) +

    Previous versions neglected to check this requirement at all. +

  • Fix possible CREATE TABLE failure when inheriting the + "same" constraint from multiple parent relations that + inherited that constraint from a common ancestor (Tom) +

  • Fix conversions between ISO-8859-5 and other encodings to handle + Cyrillic "Yo" characters (e and E with + two dots) (Sergey Burladyan) +

  • Fix a few datatype input functions + that were allowing unused bytes in their results to contain + uninitialized, unpredictable values (Tom) +

    This could lead to failures in which two apparently identical literal + values were not seen as equal, resulting in the parser complaining + about unmatched ORDER BY and DISTINCT + expressions. +

  • Fix a corner case in regular-expression substring matching + (substring(string from + pattern)) (Tom) +

    The problem occurs when there is a match to the pattern overall but + the user has specified a parenthesized subexpression and that + subexpression hasn't got a match. An example is + substring('foo' from 'foo(bar)?'). + This should return NULL, since (bar) isn't matched, but + it was mistakenly returning the whole-pattern match instead (ie, + foo). +

  • Update time zone data files to tzdata release 2008c (for + DST law changes in Morocco, Iraq, Choibalsan, Pakistan, Syria, Cuba, + Argentina/San_Luis, and Chile) +

  • Fix incorrect result from ecpg's + PGTYPEStimestamp_sub() function (Michael) +

  • Fix core dump in contrib/xml2's + xpath_table() function when the input query returns a + NULL value (Tom) +

  • Fix contrib/xml2's makefile to not override + CFLAGS (Tom) +

  • Fix DatumGetBool macro to not fail with gcc + 4.3 (Tom) +

    This problem affects "old style" (V0) C functions that + return boolean. The fix is already in 8.3, but the need to + back-patch it was not realized at the time. +

  • Fix longstanding LISTEN/NOTIFY + race condition (Tom) +

    In rare cases a session that had just executed a + LISTEN might not get a notification, even though + one would be expected because the concurrent transaction executing + NOTIFY was observed to commit later. +

    A side effect of the fix is that a transaction that has executed + a not-yet-committed LISTEN command will not see any + row in pg_listener for the LISTEN, + should it choose to look; formerly it would have. This behavior + was never documented one way or the other, but it is possible that + some applications depend on the old behavior. +

  • Disallow LISTEN and UNLISTEN within a + prepared transaction (Tom) +

    This was formerly allowed but trying to do it had various unpleasant + consequences, notably that the originating backend could not exit + as long as an UNLISTEN remained uncommitted. +

  • Fix rare crash when an error occurs during a query using a hash index + (Heikki) +

  • Fix input of datetime values for February 29 in years BC (Tom) +

    The former coding was mistaken about which years were leap years. +

  • Fix "unrecognized node type" error in some variants of + ALTER OWNER (Tom) +

  • Fix pg_ctl to correctly extract the postmaster's port + number from command-line options (Itagaki Takahiro, Tom) +

    Previously, pg_ctl start -w could try to contact the + postmaster on the wrong port, leading to bogus reports of startup + failure. +

  • Use -fwrapv to defend against possible misoptimization + in recent gcc versions (Tom) +

    This is known to be necessary when building PostgreSQL + with gcc 4.3 or later. +

  • Fix display of constant expressions in ORDER BY + and GROUP BY (Tom) +

    An explicitly casted constant would be shown incorrectly. This could + for example lead to corruption of a view definition during + dump and reload. +

  • Fix libpq to handle NOTICE messages correctly + during COPY OUT (Tom) +

    This failure has only been observed to occur when a user-defined + datatype's output routine issues a NOTICE, but there is no + guarantee it couldn't happen due to other causes. +


PrevHomeNext
Release 8.1.13UpRelease 8.1.11
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-1-13.html b/doc/src/sgml/html/release-8-1-13.html new file mode 100644 index 000000000..827f27927 --- /dev/null +++ b/doc/src/sgml/html/release-8-1-13.html @@ -0,0 +1,266 @@ + +Release 8.1.13

E.97. Release 8.1.13

Release Date: 2008-06-12

This release contains one serious and one minor bug fix over 8.1.12. + For information about new features in the 8.1 major release, see + Section E.110. +

E.97.1. Migration to Version 8.1.13

A dump/restore is not required for those running 8.1.X. + However, if you are upgrading from a version earlier than 8.1.2, + see the release notes for 8.1.2. +

E.97.2. Changes

  • Make pg_get_ruledef() parenthesize negative constants (Tom) +

    Before this fix, a negative constant in a view or rule might be dumped + as, say, -42::integer, which is subtly incorrect: it should + be (-42)::integer due to operator precedence rules. + Usually this would make little difference, but it could interact with + another recent patch to cause + PostgreSQL to reject what had been a valid + SELECT DISTINCT view query. Since this could result in + pg_dump output failing to reload, it is being treated + as a high-priority fix. The only released versions in which dump + output is actually incorrect are 8.3.1 and 8.2.7. +

  • Make ALTER AGGREGATE ... OWNER TO update + pg_shdepend (Tom) +

    This oversight could lead to problems if the aggregate was later + involved in a DROP OWNED or REASSIGN OWNED + operation. +


PrevHomeNext
Release 8.1.14UpRelease 8.1.12
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-1-14.html b/doc/src/sgml/html/release-8-1-14.html new file mode 100644 index 000000000..5b0f50740 --- /dev/null +++ b/doc/src/sgml/html/release-8-1-14.html @@ -0,0 +1,390 @@ + +Release 8.1.14

E.96. Release 8.1.14

Release Date: 2008-09-22

This release contains a variety of fixes from 8.1.13. + For information about new features in the 8.1 major release, see + Section E.110. +

E.96.1. Migration to Version 8.1.14

A dump/restore is not required for those running 8.1.X. + However, if you are upgrading from a version earlier than 8.1.2, + see the release notes for 8.1.2. +

E.96.2. Changes

  • Widen local lock counters from 32 to 64 bits (Tom) +

    This responds to reports that the counters could overflow in + sufficiently long transactions, leading to unexpected "lock is + already held" errors. +

  • Fix possible duplicate output of tuples during a GiST index scan (Teodor) +

  • Add checks in executor startup to ensure that the tuples produced by an + INSERT or UPDATE will match the target table's + current rowtype (Tom) +

    ALTER COLUMN TYPE, followed by re-use of a previously + cached plan, could produce this type of situation. The check protects + against data corruption and/or crashes that could ensue. +

  • Fix AT TIME ZONE to first try to interpret its timezone + argument as a timezone abbreviation, and only try it as a full timezone + name if that fails, rather than the other way around as formerly (Tom) +

    The timestamp input functions have always resolved ambiguous zone names + in this order. Making AT TIME ZONE do so as well improves + consistency, and fixes a compatibility bug introduced in 8.1: + in ambiguous cases we now behave the same as 8.0 and before did, + since in the older versions AT TIME ZONE accepted + only abbreviations. +

  • Fix datetime input functions to correctly detect integer overflow when + running on a 64-bit platform (Tom) +

  • Improve performance of writing very long log messages to syslog (Tom) +

  • Fix bug in backwards scanning of a cursor on a SELECT DISTINCT + ON query (Tom) +

  • Fix planner bug with nested sub-select expressions (Tom) +

    If the outer sub-select has no direct dependency on the parent query, + but the inner one does, the outer value might not get recalculated + for new parent query rows. +

  • Fix planner to estimate that GROUP BY expressions yielding + boolean results always result in two groups, regardless of the + expressions' contents (Tom) +

    This is very substantially more accurate than the regular GROUP + BY estimate for certain boolean tests like col + IS NULL. +

  • Fix PL/pgSQL to not fail when a FOR loop's target variable + is a record containing composite-type fields (Tom) +

  • Fix PL/Tcl to behave correctly with Tcl 8.5, and to be more careful + about the encoding of data sent to or from Tcl (Tom) +

  • Fix PL/Python to work with Python 2.5 +

    This is a back-port of fixes made during the 8.2 development cycle. +

  • Improve pg_dump and pg_restore's + error reporting after failure to send a SQL command (Tom) +

  • Fix pg_ctl to properly preserve postmaster + command-line arguments across a restart (Bruce) +

  • Update time zone data files to tzdata release 2008f (for + DST law changes in Argentina, Bahamas, Brazil, Mauritius, Morocco, + Pakistan, Palestine, and Paraguay) +


PrevHomeNext
Release 8.1.15UpRelease 8.1.13
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-1-15.html b/doc/src/sgml/html/release-8-1-15.html new file mode 100644 index 000000000..22fb29cbd --- /dev/null +++ b/doc/src/sgml/html/release-8-1-15.html @@ -0,0 +1,362 @@ + +Release 8.1.15

E.95. Release 8.1.15

Release Date: 2008-11-03

This release contains a variety of fixes from 8.1.14. + For information about new features in the 8.1 major release, see + Section E.110. +

E.95.1. Migration to Version 8.1.15

A dump/restore is not required for those running 8.1.X. + However, if you are upgrading from a version earlier than 8.1.2, + see the release notes for 8.1.2. Also, if you were running a previous + 8.1.X release, it is recommended to REINDEX all GiST + indexes after the upgrade. +

E.95.2. Changes

  • Fix GiST index corruption due to marking the wrong index entry + "dead" after a deletion (Teodor) +

    This would result in index searches failing to find rows they + should have found. Corrupted indexes can be fixed with + REINDEX. +

  • Fix backend crash when the client encoding cannot represent a localized + error message (Tom) +

    We have addressed similar issues before, but it would still fail if + the "character has no equivalent" message itself couldn't + be converted. The fix is to disable localization and send the plain + ASCII error message when we detect such a situation. +

  • Fix possible crash when deeply nested functions are invoked from + a trigger (Tom) +

  • Fix mis-expansion of rule queries when a sub-SELECT appears + in a function call in FROM, a multi-row VALUES + list, or a RETURNING list (Tom) +

    The usual symptom of this problem is an "unrecognized node type" + error. +

  • Ensure an error is reported when a newly-defined PL/pgSQL trigger + function is invoked as a normal function (Tom) +

  • Prevent possible collision of relfilenode numbers + when moving a table to another tablespace with ALTER SET + TABLESPACE (Heikki) +

    The command tried to re-use the existing filename, instead of + picking one that is known unused in the destination directory. +

  • Fix incorrect tsearch2 headline generation when single query + item matches first word of text (Sushant Sinha) +

  • Fix improper display of fractional seconds in interval values when + using a non-ISO datestyle in an --enable-integer-datetimes + build (Ron Mayer) +

  • Ensure SPI_getvalue and SPI_getbinval + behave correctly when the passed tuple and tuple descriptor have + different numbers of columns (Tom) +

    This situation is normal when a table has had columns added or removed, + but these two functions didn't handle it properly. + The only likely consequence is an incorrect error indication. +

  • Fix ecpg's parsing of CREATE ROLE (Michael) +

  • Fix recent breakage of pg_ctl restart (Tom) +

  • Update time zone data files to tzdata release 2008i (for + DST law changes in Argentina, Brazil, Mauritius, Syria) +


PrevHomeNext
Release 8.1.16UpRelease 8.1.14
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-1-16.html b/doc/src/sgml/html/release-8-1-16.html new file mode 100644 index 000000000..7c34e3ea3 --- /dev/null +++ b/doc/src/sgml/html/release-8-1-16.html @@ -0,0 +1,314 @@ + +Release 8.1.16

E.94. Release 8.1.16

Release Date: 2009-02-02

This release contains a variety of fixes from 8.1.15. + For information about new features in the 8.1 major release, see + Section E.110. +

E.94.1. Migration to Version 8.1.16

A dump/restore is not required for those running 8.1.X. + However, if you are upgrading from a version earlier than 8.1.15, + see the release notes for 8.1.15. +

E.94.2. Changes

  • Fix crash in autovacuum (Alvaro) +

    The crash occurs only after vacuuming a whole database for + anti-transaction-wraparound purposes, which means that it occurs + infrequently and is hard to track down. +

  • Improve handling of URLs in headline() function (Teodor) +

  • Improve handling of overlength headlines in headline() + function (Teodor) +

  • Prevent possible Assert failure or misconversion if an encoding + conversion is created with the wrong conversion function for the + specified pair of encodings (Tom, Heikki) +

  • Avoid unnecessary locking of small tables in VACUUM + (Heikki) +

  • Ensure that the contents of a holdable cursor don't depend on the + contents of TOAST tables (Tom) +

    Previously, large field values in a cursor result might be represented + as TOAST pointers, which would fail if the referenced table got dropped + before the cursor is read, or if the large value is deleted and then + vacuumed away. This cannot happen with an ordinary cursor, + but it could with a cursor that is held past its creating transaction. +

  • Fix uninitialized variables in contrib/tsearch2's + get_covers() function (Teodor) +

  • Fix configure script to properly report failure when + unable to obtain linkage information for PL/Perl (Andrew) +

  • Make all documentation reference pgsql-bugs and/or + pgsql-hackers as appropriate, instead of the + now-decommissioned pgsql-ports and pgsql-patches + mailing lists (Tom) +

  • Update time zone data files to tzdata release 2009a (for + Kathmandu and historical DST corrections in Switzerland, Cuba) +


PrevHomeNext
Release 8.1.17UpRelease 8.1.15
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-1-17.html b/doc/src/sgml/html/release-8-1-17.html new file mode 100644 index 000000000..5b612afe6 --- /dev/null +++ b/doc/src/sgml/html/release-8-1-17.html @@ -0,0 +1,320 @@ + +Release 8.1.17

E.93. Release 8.1.17

Release Date: 2009-03-16

This release contains a variety of fixes from 8.1.16. + For information about new features in the 8.1 major release, see + Section E.110. +

E.93.1. Migration to Version 8.1.17

A dump/restore is not required for those running 8.1.X. + However, if you are upgrading from a version earlier than 8.1.15, + see the release notes for 8.1.15. +

E.93.2. Changes

  • Prevent error recursion crashes when encoding conversion fails (Tom) +

    This change extends fixes made in the last two minor releases for + related failure scenarios. The previous fixes were narrowly tailored + for the original problem reports, but we have now recognized that + any error thrown by an encoding conversion function could + potentially lead to infinite recursion while trying to report the + error. The solution therefore is to disable translation and encoding + conversion and report the plain-ASCII form of any error message, + if we find we have gotten into a recursive error reporting situation. + (CVE-2009-0922) +

  • Disallow CREATE CONVERSION with the wrong encodings + for the specified conversion function (Heikki) +

    This prevents one possible scenario for encoding conversion failure. + The previous change is a backstop to guard against other kinds of + failures in the same area. +

  • Fix core dump when to_char() is given format codes that + are inappropriate for the type of the data argument (Tom) +

  • Fix decompilation of CASE WHEN with an implicit coercion + (Tom) +

    This mistake could lead to Assert failures in an Assert-enabled build, + or an "unexpected CASE WHEN clause" error message in other + cases, when trying to examine or dump a view. +

  • Fix possible misassignment of the owner of a TOAST table's rowtype (Tom) +

    If CLUSTER or a rewriting variant of ALTER TABLE + were executed by someone other than the table owner, the + pg_type entry for the table's TOAST table would end up + marked as owned by that someone. This caused no immediate problems, + since the permissions on the TOAST rowtype aren't examined by any + ordinary database operation. However, it could lead to unexpected + failures if one later tried to drop the role that issued the command + (in 8.1 or 8.2), or "owner of data type appears to be invalid" + warnings from pg_dump after having done so (in 8.3). +

  • Clean up PL/pgSQL error status variables fully at block exit + (Ashesh Vashi and Dave Page) +

    This is not a problem for PL/pgSQL itself, but the omission could cause + the PL/pgSQL Debugger to crash while examining the state of a function. +

  • Add MUST (Mauritius Island Summer Time) to the default list + of known timezone abbreviations (Xavier Bugaud) +


PrevHomeNext
Release 8.1.18UpRelease 8.1.16
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-1-18.html b/doc/src/sgml/html/release-8-1-18.html new file mode 100644 index 000000000..3fb8a8980 --- /dev/null +++ b/doc/src/sgml/html/release-8-1-18.html @@ -0,0 +1,394 @@ + +Release 8.1.18

E.92. Release 8.1.18

Release Date: 2009-09-09

This release contains a variety of fixes from 8.1.17. + For information about new features in the 8.1 major release, see + Section E.110. +

E.92.1. Migration to Version 8.1.18

A dump/restore is not required for those running 8.1.X. + However, if you have any hash indexes on interval columns, + you must REINDEX them after updating to 8.1.18. + Also, if you are upgrading from a version earlier than 8.1.15, + see the release notes for 8.1.15. +

E.92.2. Changes

  • Disallow RESET ROLE and RESET SESSION + AUTHORIZATION inside security-definer functions (Tom, Heikki) +

    This covers a case that was missed in the previous patch that + disallowed SET ROLE and SET SESSION + AUTHORIZATION inside security-definer functions. + (See CVE-2007-6600) +

  • Fix handling of sub-SELECTs appearing in the arguments of + an outer-level aggregate function (Tom) +

  • Fix hash calculation for data type interval (Tom) +

    This corrects wrong results for hash joins on interval values. + It also changes the contents of hash indexes on interval columns. + If you have any such indexes, you must REINDEX them + after updating. +

  • Treat to_char(..., 'TH') as an uppercase ordinal + suffix with 'HH'/'HH12' (Heikki) +

    It was previously handled as 'th' (lowercase). +

  • Fix overflow for INTERVAL 'x ms' + when x is more than 2 million and integer + datetimes are in use (Alex Hunsaker) +

  • Fix calculation of distance between a point and a line segment (Tom) +

    This led to incorrect results from a number of geometric operators. +

  • Fix money data type to work in locales where currency + amounts have no fractional digits, e.g. Japan (Itagaki Takahiro) +

  • Properly round datetime input like + 00:12:57.9999999999999999999999999999 (Tom) +

  • Fix poor choice of page split point in GiST R-tree operator classes + (Teodor) +

  • Fix portability issues in plperl initialization (Andrew Dunstan) +

  • Fix pg_ctl to not go into an infinite loop if + postgresql.conf is empty (Jeff Davis) +

  • Fix contrib/xml2's xslt_process() to + properly handle the maximum number of parameters (twenty) (Tom) +

  • Improve robustness of libpq's code to recover + from errors during COPY FROM STDIN (Tom) +

  • Avoid including conflicting readline and editline header files + when both libraries are installed (Zdenek Kotala) +

  • Update time zone data files to tzdata release 2009l + for DST law changes in Bangladesh, Egypt, Jordan, Pakistan, + Argentina/San_Luis, Cuba, Jordan (historical correction only), + Mauritius, Morocco, Palestine, Syria, Tunisia. +


PrevHomeNext
Release 8.1.19UpRelease 8.1.17
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-1-19.html b/doc/src/sgml/html/release-8-1-19.html new file mode 100644 index 000000000..e8d96a458 --- /dev/null +++ b/doc/src/sgml/html/release-8-1-19.html @@ -0,0 +1,368 @@ + +Release 8.1.19

E.91. Release 8.1.19

Release Date: 2009-12-14

This release contains a variety of fixes from 8.1.18. + For information about new features in the 8.1 major release, see + Section E.110. +

E.91.1. Migration to Version 8.1.19

A dump/restore is not required for those running 8.1.X. + However, if you are upgrading from a version earlier than 8.1.18, + see the release notes for 8.1.18. +

E.91.2. Changes

  • Protect against indirect security threats caused by index functions + changing session-local state (Gurjeet Singh, Tom) +

    This change prevents allegedly-immutable index functions from possibly + subverting a superuser's session (CVE-2009-4136). +

  • Reject SSL certificates containing an embedded null byte in the common + name (CN) field (Magnus) +

    This prevents unintended matching of a certificate to a server or client + name during SSL validation (CVE-2009-4034). +

  • Fix possible crash during backend-startup-time cache initialization (Tom) +

  • Prevent signals from interrupting VACUUM at unsafe times + (Alvaro) +

    This fix prevents a PANIC if a VACUUM FULL is canceled + after it's already committed its tuple movements, as well as transient + errors if a plain VACUUM is interrupted after having + truncated the table. +

  • Fix possible crash due to integer overflow in hash table size + calculation (Tom) +

    This could occur with extremely large planner estimates for the size of + a hashjoin's result. +

  • Fix very rare crash in inet/cidr comparisons (Chris + Mikkelson) +

  • Ensure that shared tuple-level locks held by prepared transactions are + not ignored (Heikki) +

  • Fix premature drop of temporary files used for a cursor that is accessed + within a subtransaction (Heikki) +

  • Fix PAM password processing to be more robust (Tom) +

    The previous code is known to fail with the combination of the Linux + pam_krb5 PAM module with Microsoft Active Directory as the + domain controller. It might have problems elsewhere too, since it was + making unjustified assumptions about what arguments the PAM stack would + pass to it. +

  • Fix processing of ownership dependencies during CREATE OR + REPLACE FUNCTION (Tom) +

  • Ensure that Perl arrays are properly converted to + PostgreSQL arrays when returned by a set-returning + PL/Perl function (Andrew Dunstan, Abhijit Menon-Sen) +

    This worked correctly already for non-set-returning functions. +

  • Fix rare crash in exception processing in PL/Python (Peter) +

  • Ensure psql's flex module is compiled with the correct + system header definitions (Tom) +

    This fixes build failures on platforms where + --enable-largefile causes incompatible changes in the + generated code. +

  • Make the postmaster ignore any application_name parameter in + connection request packets, to improve compatibility with future libpq + versions (Tom) +

  • Update time zone data files to tzdata release 2009s + for DST law changes in Antarctica, Argentina, Bangladesh, Fiji, + Novokuznetsk, Pakistan, Palestine, Samoa, Syria; also historical + corrections for Hong Kong. +


PrevHomeNext
Release 8.1.20UpRelease 8.1.18
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-1-2.html b/doc/src/sgml/html/release-8-1-2.html new file mode 100644 index 000000000..be211415d --- /dev/null +++ b/doc/src/sgml/html/release-8-1-2.html @@ -0,0 +1,368 @@ + +Release 8.1.2

E.108. Release 8.1.2

Release Date: 2006-01-09

This release contains a variety of fixes from 8.1.1. + For information about new features in the 8.1 major release, see + Section E.110. +

E.108.1. Migration to Version 8.1.2

A dump/restore is not required for those running 8.1.X. + However, you might need to REINDEX indexes on textual + columns after updating, if you are affected by the locale or + plperl issues described below. +

E.108.2. Changes

  • Fix Windows code so that postmaster will continue rather +than exit if there is no more room in ShmemBackendArray (Magnus)

    The previous behavior could lead to a denial-of-service situation if too +many connection requests arrive close together. This applies +only to the Windows port.

  • Fix bug introduced in 8.0 that could allow ReadBuffer +to return an already-used page as new, potentially causing loss of +recently-committed data (Tom)

  • Fix for protocol-level Describe messages issued +outside a transaction or in a failed transaction (Tom)

  • Fix character string comparison for locales that consider +different character combinations as equal, such as Hungarian (Tom)

    This might require REINDEX to fix existing indexes on +textual columns.

  • Set locale environment variables during postmaster startup +to ensure that plperl won't change the locale later

    This fixes a problem that occurred if the postmaster was +started with environment variables specifying a different locale than what +initdb had been told. Under these conditions, any use of +plperl was likely to lead to corrupt indexes. You might need +REINDEX to fix existing indexes on +textual columns if this has happened to you.

  • Allow more flexible relocation of installation +directories (Tom)

    Previous releases supported relocation only if all installation +directory paths were the same except for the last component.

  • Prevent crashes caused by the use of +ISO-8859-5 and ISO-8859-9 encodings +(Tatsuo)

  • Fix longstanding bug in strpos() and regular expression +handling in certain rarely used Asian multi-byte character sets (Tatsuo)

  • Fix bug where COPY CSV mode considered any +\. to terminate the copy data

    The new code +requires \. to appear alone on a line, as per +documentation.

  • Make COPY CSV mode quote a literal data value of +\. to ensure it cannot be interpreted as the +end-of-data marker (Bruce)

  • Various fixes for functions returning RECORDs +(Tom)

  • Fix processing of postgresql.conf so a +final line with no newline is processed properly (Tom)

  • Fix bug in /contrib/pgcrypto gen_salt, +which caused it not to use all available salt space for MD5 and +XDES algorithms (Marko Kreen, Solar Designer)

    Salts for Blowfish and standard DES are unaffected.

  • Fix autovacuum crash when processing expression indexes

  • Fix /contrib/dblink to throw an error, +rather than crashing, when the number of columns specified is different from +what's actually returned by the query (Joe)


PrevHomeNext
Release 8.1.3UpRelease 8.1.1
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-1-20.html b/doc/src/sgml/html/release-8-1-20.html new file mode 100644 index 000000000..5aca41e76 --- /dev/null +++ b/doc/src/sgml/html/release-8-1-20.html @@ -0,0 +1,401 @@ + +Release 8.1.20

E.90. Release 8.1.20

Release Date: 2010-03-15

This release contains a variety of fixes from 8.1.19. + For information about new features in the 8.1 major release, see + Section E.110. +

E.90.1. Migration to Version 8.1.20

A dump/restore is not required for those running 8.1.X. + However, if you are upgrading from a version earlier than 8.1.18, + see the release notes for 8.1.18. +

E.90.2. Changes

  • Add new configuration parameter ssl_renegotiation_limit to + control how often we do session key renegotiation for an SSL connection + (Magnus) +

    This can be set to zero to disable renegotiation completely, which may + be required if a broken SSL library is used. In particular, some + vendors are shipping stopgap patches for CVE-2009-3555 that cause + renegotiation attempts to fail. +

  • Fix possible crashes when trying to recover from a failure in + subtransaction start (Tom) +

  • Fix server memory leak associated with use of savepoints and a client + encoding different from server's encoding (Tom) +

  • Make substring() for bit types treat any negative + length as meaning "all the rest of the string" (Tom) +

    The previous coding treated only -1 that way, and would produce an + invalid result value for other negative values, possibly leading to + a crash (CVE-2010-0442). +

  • Fix integer-to-bit-string conversions to handle the first fractional + byte correctly when the output bit width is wider than the given + integer by something other than a multiple of 8 bits (Tom) +

  • Fix some cases of pathologically slow regular expression matching (Tom) +

  • Fix the STOP WAL LOCATION entry in backup history files to + report the next WAL segment's name when the end location is exactly at a + segment boundary (Itagaki Takahiro) +

  • Fix some more cases of temporary-file leakage (Heikki) +

    This corrects a problem introduced in the previous minor release. + One case that failed is when a plpgsql function returning set is + called within another function's exception handler. +

  • When reading pg_hba.conf and related files, do not treat + @something as a file inclusion request if the @ + appears inside quote marks; also, never treat @ by itself + as a file inclusion request (Tom) +

    This prevents erratic behavior if a role or database name starts with + @. If you need to include a file whose path name + contains spaces, you can still do so, but you must write + @"/path to/file" rather than putting the quotes around + the whole construct. +

  • Prevent infinite loop on some platforms if a directory is named as + an inclusion target in pg_hba.conf and related files + (Tom) +

  • Fix psql's numericlocale option to not + format strings it shouldn't in latex and troff output formats (Heikki) +

  • Fix plpgsql failure in one case where a composite column is set to NULL + (Tom) +

  • Add volatile markings in PL/Python to avoid possible + compiler-specific misbehavior (Zdenek Kotala) +

  • Ensure PL/Tcl initializes the Tcl interpreter fully (Tom) +

    The only known symptom of this oversight is that the Tcl + clock command misbehaves if using Tcl 8.5 or later. +

  • Prevent crash in contrib/dblink when too many key + columns are specified to a dblink_build_sql_* function + (Rushabh Lathia, Joe Conway) +

  • Fix assorted crashes in contrib/xml2 caused by sloppy + memory management (Tom) +

  • Update time zone data files to tzdata release 2010e + for DST law changes in Bangladesh, Chile, Fiji, Mexico, Paraguay, Samoa. +


PrevHomeNext
Release 8.1.21UpRelease 8.1.19
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-1-21.html b/doc/src/sgml/html/release-8-1-21.html new file mode 100644 index 000000000..97e3608d8 --- /dev/null +++ b/doc/src/sgml/html/release-8-1-21.html @@ -0,0 +1,381 @@ + +Release 8.1.21

E.89. Release 8.1.21

Release Date: 2010-05-17

This release contains a variety of fixes from 8.1.20. + For information about new features in the 8.1 major release, see + Section E.110. +

E.89.1. Migration to Version 8.1.21

A dump/restore is not required for those running 8.1.X. + However, if you are upgrading from a version earlier than 8.1.18, + see the release notes for 8.1.18. +

E.89.2. Changes

  • Enforce restrictions in plperl using an opmask applied to + the whole interpreter, instead of using Safe.pm + (Tim Bunce, Andrew Dunstan) +

    Recent developments have convinced us that Safe.pm is too + insecure to rely on for making plperl trustable. This + change removes use of Safe.pm altogether, in favor of using + a separate interpreter with an opcode mask that is always applied. + Pleasant side effects of the change include that it is now possible to + use Perl's strict pragma in a natural way in + plperl, and that Perl's $a and $b + variables work as expected in sort routines, and that function + compilation is significantly faster. (CVE-2010-1169) +

  • Prevent PL/Tcl from executing untrustworthy code from + pltcl_modules (Tom) +

    PL/Tcl's feature for autoloading Tcl code from a database table + could be exploited for trojan-horse attacks, because there was no + restriction on who could create or insert into that table. This change + disables the feature unless pltcl_modules is owned by a + superuser. (However, the permissions on the table are not checked, so + installations that really need a less-than-secure modules table can + still grant suitable privileges to trusted non-superusers.) Also, + prevent loading code into the unrestricted "normal" Tcl + interpreter unless we are really going to execute a pltclu + function. (CVE-2010-1170) +

  • Do not allow an unprivileged user to reset superuser-only parameter + settings (Alvaro) +

    Previously, if an unprivileged user ran ALTER USER ... RESET + ALL for himself, or ALTER DATABASE ... RESET ALL for + a database he owns, this would remove all special parameter settings + for the user or database, even ones that are only supposed to be + changeable by a superuser. Now, the ALTER will only + remove the parameters that the user has permission to change. +

  • Avoid possible crash during backend shutdown if shutdown occurs + when a CONTEXT addition would be made to log entries (Tom) +

    In some cases the context-printing function would fail because the + current transaction had already been rolled back when it came time + to print a log message. +

  • Update pl/perl's ppport.h for modern Perl versions + (Andrew) +

  • Fix assorted memory leaks in pl/python (Andreas Freund, Tom) +

  • Prevent infinite recursion in psql when expanding + a variable that refers to itself (Tom) +

  • Ensure that contrib/pgstattuple functions respond to cancel + interrupts promptly (Tatsuhito Kasahara) +

  • Make server startup deal properly with the case that + shmget() returns EINVAL for an existing + shared memory segment (Tom) +

    This behavior has been observed on BSD-derived kernels including OS X. + It resulted in an entirely-misleading startup failure complaining that + the shared memory request size was too large. +

  • Update time zone data files to tzdata release 2010j + for DST law changes in Argentina, Australian Antarctic, Bangladesh, + Mexico, Morocco, Pakistan, Palestine, Russia, Syria, Tunisia; + also historical corrections for Taiwan. +


PrevHomeNext
Release 8.1.22UpRelease 8.1.20
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-1-22.html b/doc/src/sgml/html/release-8-1-22.html new file mode 100644 index 000000000..1633b3225 --- /dev/null +++ b/doc/src/sgml/html/release-8-1-22.html @@ -0,0 +1,416 @@ + +Release 8.1.22

E.88. Release 8.1.22

Release Date: 2010-10-04

This release contains a variety of fixes from 8.1.21. + For information about new features in the 8.1 major release, see + Section E.110. +

The PostgreSQL community will stop releasing updates + for the 8.1.X release series in November 2010. + Users are encouraged to update to a newer release branch soon. +

E.88.1. Migration to Version 8.1.22

A dump/restore is not required for those running 8.1.X. + However, if you are upgrading from a version earlier than 8.1.18, + see the release notes for 8.1.18. +

E.88.2. Changes

  • Use a separate interpreter for each calling SQL userid in PL/Perl and + PL/Tcl (Tom Lane) +

    This change prevents security problems that can be caused by subverting + Perl or Tcl code that will be executed later in the same session under + another SQL user identity (for example, within a SECURITY + DEFINER function). Most scripting languages offer numerous ways that + that might be done, such as redefining standard functions or operators + called by the target function. Without this change, any SQL user with + Perl or Tcl language usage rights can do essentially anything with the + SQL privileges of the target function's owner. +

    The cost of this change is that intentional communication among Perl + and Tcl functions becomes more difficult. To provide an escape hatch, + PL/PerlU and PL/TclU functions continue to use only one interpreter + per session. This is not considered a security issue since all such + functions execute at the trust level of a database superuser already. +

    It is likely that third-party procedural languages that claim to offer + trusted execution have similar security issues. We advise contacting + the authors of any PL you are depending on for security-critical + purposes. +

    Our thanks to Tim Bunce for pointing out this issue (CVE-2010-3433). +

  • Prevent possible crashes in pg_get_expr() by disallowing + it from being called with an argument that is not one of the system + catalog columns it's intended to be used with + (Heikki Linnakangas, Tom Lane) +

  • Fix "cannot handle unplanned sub-select" error (Tom Lane) +

    This occurred when a sub-select contains a join alias reference that + expands into an expression containing another sub-select. +

  • Prevent show_session_authorization() from crashing within autovacuum + processes (Tom Lane) +

  • Defend against functions returning setof record where not all the + returned rows are actually of the same rowtype (Tom Lane) +

  • Fix possible failure when hashing a pass-by-reference function result + (Tao Ma, Tom Lane) +

  • Take care to fsync the contents of lockfiles (both + postmaster.pid and the socket lockfile) while writing them + (Tom Lane) +

    This omission could result in corrupted lockfile contents if the + machine crashes shortly after postmaster start. That could in turn + prevent subsequent attempts to start the postmaster from succeeding, + until the lockfile is manually removed. +

  • Avoid recursion while assigning XIDs to heavily-nested + subtransactions (Andres Freund, Robert Haas) +

    The original coding could result in a crash if there was limited + stack space. +

  • Fix log_line_prefix's %i escape, + which could produce junk early in backend startup (Tom Lane) +

  • Fix possible data corruption in ALTER TABLE ... SET + TABLESPACE when archiving is enabled (Jeff Davis) +

  • Allow CREATE DATABASE and ALTER DATABASE ... SET + TABLESPACE to be interrupted by query-cancel (Guillaume Lelarge) +

  • In PL/Python, defend against null pointer results from + PyCObject_AsVoidPtr and PyCObject_FromVoidPtr + (Peter Eisentraut) +

  • Improve contrib/dblink's handling of tables containing + dropped columns (Tom Lane) +

  • Fix connection leak after "duplicate connection name" + errors in contrib/dblink (Itagaki Takahiro) +

  • Fix contrib/dblink to handle connection names longer than + 62 bytes correctly (Itagaki Takahiro) +

  • Update build infrastructure and documentation to reflect the source code + repository's move from CVS to Git (Magnus Hagander and others) +

  • Update time zone data files to tzdata release 2010l + for DST law changes in Egypt and Palestine; also historical corrections + for Finland. +

    This change also adds new names for two Micronesian timezones: + Pacific/Chuuk is now preferred over Pacific/Truk (and the preferred + abbreviation is CHUT not TRUT) and Pacific/Pohnpei is preferred over + Pacific/Ponape. +


PrevHomeNext
Release 8.1.23UpRelease 8.1.21
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-1-23.html b/doc/src/sgml/html/release-8-1-23.html new file mode 100644 index 000000000..8255b2f67 --- /dev/null +++ b/doc/src/sgml/html/release-8-1-23.html @@ -0,0 +1,454 @@ + +Release 8.1.23

E.87. Release 8.1.23

Release Date: 2010-12-16

This release contains a variety of fixes from 8.1.22. + For information about new features in the 8.1 major release, see + Section E.110. +

This is expected to be the last PostgreSQL release + in the 8.1.X series. Users are encouraged to update to a newer + release branch soon. +

E.87.1. Migration to Version 8.1.23

A dump/restore is not required for those running 8.1.X. + However, if you are upgrading from a version earlier than 8.1.18, + see the release notes for 8.1.18. +

E.87.2. Changes

  • Force the default + wal_sync_method + to be fdatasync on Linux (Tom Lane, Marti Raudsepp) +

    The default on Linux has actually been fdatasync for many + years, but recent kernel changes caused PostgreSQL to + choose open_datasync instead. This choice did not result + in any performance improvement, and caused outright failures on + certain filesystems, notably ext4 with the + data=journal mount option. +

  • Fix recovery from base backup when the starting checkpoint WAL record + is not in the same WAL segment as its redo point (Jeff Davis) +

  • Add support for detecting register-stack overrun on IA64 + (Tom Lane) +

    The IA64 architecture has two hardware stacks. Full + prevention of stack-overrun failures requires checking both. +

  • Add a check for stack overflow in copyObject() (Tom Lane) +

    Certain code paths could crash due to stack overflow given a + sufficiently complex query. +

  • Fix detection of page splits in temporary GiST indexes (Heikki + Linnakangas) +

    It is possible to have a "concurrent" page split in a + temporary index, if for example there is an open cursor scanning the + index when an insertion is done. GiST failed to detect this case and + hence could deliver wrong results when execution of the cursor + continued. +

  • Avoid memory leakage while ANALYZE'ing complex index + expressions (Tom Lane) +

  • Ensure an index that uses a whole-row Var still depends on its table + (Tom Lane) +

    An index declared like create index i on t (foo(t.*)) + would not automatically get dropped when its table was dropped. +

  • Do not "inline" a SQL function with multiple OUT + parameters (Tom Lane) +

    This avoids a possible crash due to loss of information about the + expected result rowtype. +

  • Fix constant-folding of COALESCE() expressions (Tom Lane) +

    The planner would sometimes attempt to evaluate sub-expressions that + in fact could never be reached, possibly leading to unexpected errors. +

  • Add print functionality for InhRelation nodes (Tom Lane) +

    This avoids a failure when debug_print_parse is enabled + and certain types of query are executed. +

  • Fix incorrect calculation of distance from a point to a horizontal + line segment (Tom Lane) +

    This bug affected several different geometric distance-measurement + operators. +

  • Fix PL/pgSQL's handling of "simple" + expressions to not fail in recursion or error-recovery cases (Tom Lane) +

  • Fix bug in contrib/cube's GiST picksplit algorithm + (Alexander Korotkov) +

    This could result in considerable inefficiency, though not actually + incorrect answers, in a GiST index on a cube column. + If you have such an index, consider REINDEXing it after + installing this update. +

  • Don't emit "identifier will be truncated" notices in + contrib/dblink except when creating new connections + (Itagaki Takahiro) +

  • Fix potential coredump on missing public key in + contrib/pgcrypto (Marti Raudsepp) +

  • Fix memory leak in contrib/xml2's XPath query functions + (Tom Lane) +

  • Update time zone data files to tzdata release 2010o + for DST law changes in Fiji and Samoa; + also historical corrections for Hong Kong. +


PrevHomeNext
Release 8.2UpRelease 8.1.22
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-1-3.html b/doc/src/sgml/html/release-8-1-3.html new file mode 100644 index 000000000..dbbe9c68d --- /dev/null +++ b/doc/src/sgml/html/release-8-1-3.html @@ -0,0 +1,438 @@ + +Release 8.1.3

E.107. Release 8.1.3

Release Date: 2006-02-14

This release contains a variety of fixes from 8.1.2, + including one very serious security issue. + For information about new features in the 8.1 major release, see + Section E.110. +

E.107.1. Migration to Version 8.1.3

A dump/restore is not required for those running 8.1.X. + However, if you are upgrading from a version earlier than 8.1.2, + see the release notes for 8.1.2. +

E.107.2. Changes

  • Fix bug that allowed any logged-in user to SET +ROLE to any other database user id (CVE-2006-0553)

    Due to inadequate validity checking, a user could exploit the special +case that SET ROLE normally uses to restore the previous role +setting after an error. This allowed ordinary users to acquire superuser +status, for example. +The escalation-of-privilege risk exists only in 8.1.0-8.1.2. +However, in all releases back to 7.3 there is a related bug in SET +SESSION AUTHORIZATION that allows unprivileged users to crash the server, +if it has been compiled with Asserts enabled (which is not the default). +Thanks to Akio Ishida for reporting this problem.

  • Fix bug with row visibility logic in self-inserted +rows (Tom)

    Under rare circumstances a row inserted by the current command +could be seen as already valid, when it should not be. Repairs bug +created in 8.0.4, 7.4.9, and 7.3.11 releases.

  • Fix race condition that could lead to "file already +exists" errors during pg_clog and pg_subtrans file creation +(Tom)

  • Fix cases that could lead to crashes if a cache-invalidation +message arrives at just the wrong time (Tom)

  • Properly check DOMAIN constraints for +UNKNOWN parameters in prepared statements +(Neil)

  • Ensure ALTER COLUMN TYPE will process +FOREIGN KEY, UNIQUE, and PRIMARY KEY +constraints in the proper order (Nakano Yoshihisa)

  • Fixes to allow restoring dumps that have cross-schema +references to custom operators or operator classes (Tom)

  • Allow pg_restore to continue properly after a +COPY failure; formerly it tried to treat the remaining +COPY data as SQL commands (Stephen Frost)

  • Fix pg_ctl unregister crash +when the data directory is not specified (Magnus)

  • Fix libpq PQprint HTML tags +(Christoph Zwerschke)

  • Fix ecpg crash on AMD64 and PPC +(Neil)

  • Allow SETOF and %TYPE to be used +together in function result type declarations

  • Recover properly if error occurs during argument passing +in PL/python (Neil)

  • Fix memory leak in plperl_return_next +(Neil)

  • Fix PL/perl's handling of locales on +Win32 to match the backend (Andrew)

  • Various optimizer fixes (Tom)

  • Fix crash when log_min_messages is set to +DEBUG3 or above in postgresql.conf on Win32 +(Bruce)

  • Fix pgxs -L library path +specification for Win32, Cygwin, OS X, AIX (Bruce)

  • Check that SID is enabled while checking for Win32 admin +privileges (Magnus)

  • Properly reject out-of-range date inputs (Kris +Jurka)

  • Portability fix for testing presence of finite +and isinf during configure (Tom)

  • Improve speed of COPY IN via libpq, by +avoiding a kernel call per data line (Alon Goldshuv)

  • Improve speed of /contrib/tsearch2 index +creation (Tom)


PrevHomeNext
Release 8.1.4UpRelease 8.1.2
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-1-4.html b/doc/src/sgml/html/release-8-1-4.html new file mode 100644 index 000000000..b452f75a9 --- /dev/null +++ b/doc/src/sgml/html/release-8-1-4.html @@ -0,0 +1,487 @@ + +Release 8.1.4

E.106. Release 8.1.4

Release Date: 2006-05-23

This release contains a variety of fixes from 8.1.3, + including patches for extremely serious security issues. + For information about new features in the 8.1 major release, see + Section E.110. +

E.106.1. Migration to Version 8.1.4

A dump/restore is not required for those running 8.1.X. + However, if you are upgrading from a version earlier than 8.1.2, + see the release notes for 8.1.2. +

Full security against the SQL-injection attacks described in + CVE-2006-2313 and CVE-2006-2314 might require changes in application + code. If you have applications that embed untrustworthy strings + into SQL commands, you should examine them as soon as possible to + ensure that they are using recommended escaping techniques. In + most cases, applications should be using subroutines provided by + libraries or drivers (such as libpq's + PQescapeStringConn()) to perform string escaping, + rather than relying on ad hoc code to do it. +

E.106.2. Changes

  • Change the server to reject invalidly-encoded multibyte +characters in all cases (Tatsuo, Tom)

    While PostgreSQL has been moving in this direction for +some time, the checks are now applied uniformly to all encodings and all +textual input, and are now always errors not merely warnings. This change +defends against SQL-injection attacks of the type described in CVE-2006-2313.

  • Reject unsafe uses of \' in string literals

    As a server-side defense against SQL-injection attacks of the type +described in CVE-2006-2314, the server now only accepts '' and not +\' as a representation of ASCII single quote in SQL string +literals. By default, \' is rejected only when +client_encoding is set to a client-only encoding (SJIS, BIG5, GBK, +GB18030, or UHC), which is the scenario in which SQL injection is possible. +A new configuration parameter backslash_quote is available to +adjust this behavior when needed. Note that full security against +CVE-2006-2314 might require client-side changes; the purpose of +backslash_quote is in part to make it obvious that insecure +clients are insecure.

  • Modify libpq's string-escaping routines to be +aware of encoding considerations and +standard_conforming_strings

    This fixes libpq-using applications for the security +issues described in CVE-2006-2313 and CVE-2006-2314, and also future-proofs +them against the planned changeover to SQL-standard string literal syntax. +Applications that use multiple PostgreSQL connections +concurrently should migrate to PQescapeStringConn() and +PQescapeByteaConn() to ensure that escaping is done correctly +for the settings in use in each database connection. Applications that +do string escaping "by hand" should be modified to rely on library +routines instead.

  • Fix weak key selection in pgcrypto (Marko Kreen)

    Errors in fortuna PRNG reseeding logic could cause a predictable +session key to be selected by pgp_sym_encrypt() in some cases. +This only affects non-OpenSSL-using builds.

  • Fix some incorrect encoding conversion functions

    win1251_to_iso, win866_to_iso, +euc_tw_to_big5, euc_tw_to_mic, +mic_to_euc_tw were all broken to varying +extents.

  • Clean up stray remaining uses of \' in strings +(Bruce, Jan)

  • Make autovacuum visible in pg_stat_activity +(Alvaro)

  • Disable full_page_writes (Tom)

    In certain cases, having full_page_writes off would cause +crash recovery to fail. A proper fix will appear in 8.2; for now it's just +disabled.

  • Various planner fixes, particularly for bitmap index scans and +MIN/MAX optimization (Tom)

  • Fix incorrect optimization in merge join (Tom)

    Outer joins could sometimes emit multiple copies of unmatched rows.

  • Fix crash from using and modifying a plpgsql function in the +same transaction

  • Fix WAL replay for case where a B-Tree index has been +truncated

  • Fix SIMILAR TO for patterns involving +| (Tom)

  • Fix SELECT INTO and CREATE TABLE AS to +create tables in the default tablespace, not the base directory (Kris +Jurka)

  • Fix server to use custom DH SSL parameters correctly (Michael +Fuhr)

  • Improve qsort performance (Dann Corbit)

    Currently this code is only used on Solaris.

  • Fix for OS/X Bonjour on x86 systems (Ashley Clark)

  • Fix various minor memory leaks

  • Fix problem with password prompting on some Win32 systems +(Robert Kinberg)

  • Improve pg_dump's handling of default values +for domains

  • Fix pg_dumpall to handle identically-named +users and groups reasonably (only possible when dumping from a pre-8.1 server) +(Tom)

    The user and group will be merged into a single role with +LOGIN permission. Formerly the merged role wouldn't have +LOGIN permission, making it unusable as a user.

  • Fix pg_restore -n to work as +documented (Tom)


PrevHomeNext
Release 8.1.5UpRelease 8.1.3
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-1-5.html b/doc/src/sgml/html/release-8-1-5.html new file mode 100644 index 000000000..9c8d05359 --- /dev/null +++ b/doc/src/sgml/html/release-8-1-5.html @@ -0,0 +1,369 @@ + +Release 8.1.5

E.105. Release 8.1.5

Release Date: 2006-10-16

This release contains a variety of fixes from 8.1.4. + For information about new features in the 8.1 major release, see + Section E.110. +

E.105.1. Migration to Version 8.1.5

A dump/restore is not required for those running 8.1.X. + However, if you are upgrading from a version earlier than 8.1.2, + see the release notes for 8.1.2. +

E.105.2. Changes

  • Disallow aggregate functions in UPDATE +commands, except within sub-SELECTs (Tom)

    The behavior of such an aggregate was unpredictable, and in 8.1.X +could cause a crash, so it has been disabled. The SQL standard does not allow +this either.

  • Fix core dump when an untyped literal is taken as +ANYARRAY

  • Fix core dump in duration logging for extended query protocol +when a COMMIT or ROLLBACK is +executed

  • Fix mishandling of AFTER triggers when query contains a SQL +function returning multiple rows (Tom)

  • Fix ALTER TABLE ... TYPE to recheck +NOT NULL for USING clause (Tom)

  • Fix string_to_array() to handle overlapping + matches for the separator string

    For example, string_to_array('123xx456xxx789', 'xx').

  • Fix to_timestamp() for +AM/PM formats (Bruce)

  • Fix autovacuum's calculation that decides whether + ANALYZE is needed (Alvaro)

  • Fix corner cases in pattern matching for + psql's \d commands

  • Fix index-corrupting bugs in /contrib/ltree + (Teodor)

  • Numerous robustness fixes in ecpg (Joachim +Wieland)

  • Fix backslash escaping in /contrib/dbmirror

  • Minor fixes in /contrib/dblink and /contrib/tsearch2

  • Efficiency improvements in hash tables and bitmap index scans +(Tom)

  • Fix instability of statistics collection on Windows (Tom, Andrew)

  • Fix statement_timeout to use the proper +units on Win32 (Bruce)

    In previous Win32 8.1.X versions, the delay was off by a factor of +100.

  • Fixes for MSVC and Borland C++ +compilers (Hiroshi Saito)

  • Fixes for AIX and +Intel compilers (Tom)

  • Fix rare bug in continuous archiving (Tom)


PrevHomeNext
Release 8.1.6UpRelease 8.1.4
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-1-6.html b/doc/src/sgml/html/release-8-1-6.html new file mode 100644 index 000000000..130e0184a --- /dev/null +++ b/doc/src/sgml/html/release-8-1-6.html @@ -0,0 +1,349 @@ + +Release 8.1.6

E.104. Release 8.1.6

Release Date: 2007-01-08

This release contains a variety of fixes from 8.1.5. + For information about new features in the 8.1 major release, see + Section E.110. +

E.104.1. Migration to Version 8.1.6

A dump/restore is not required for those running 8.1.X. + However, if you are upgrading from a version earlier than 8.1.2, + see the release notes for 8.1.2. +

E.104.2. Changes

  • Improve handling of getaddrinfo() on AIX (Tom) +

    This fixes a problem with starting the statistics collector, + among other things. +

  • Fix pg_restore to handle a tar-format backup + that contains large objects (blobs) with comments (Tom) +

  • Fix "failed to re-find parent key" errors in + VACUUM (Tom) +

  • Clean out pg_internal.init cache files during server + restart (Simon) +

    This avoids a hazard that the cache files might contain stale + data after PITR recovery. +

  • Fix race condition for truncation of a large relation across a + gigabyte boundary by VACUUM (Tom) +

  • Fix bug causing needless deadlock errors on row-level locks (Tom) +

  • Fix bugs affecting multi-gigabyte hash indexes (Tom) +

  • Fix possible deadlock in Windows signal handling (Teodor) +

  • Fix error when constructing an ARRAY[] made up of multiple + empty elements (Tom) +

  • Fix ecpg memory leak during connection (Michael) +

  • Fix for Darwin (OS X) compilation (Tom) +

  • to_number() and to_char(numeric) + are now STABLE, not IMMUTABLE, for + new initdb installs (Tom) +

    This is because lc_numeric can potentially + change the output of these functions. +

  • Improve index usage of regular expressions that use parentheses (Tom) +

    This improves psql \d performance also. +

  • Update timezone database +

    This affects Australian and Canadian daylight-savings rules in + particular. +


PrevHomeNext
Release 8.1.7UpRelease 8.1.5
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-1-7.html b/doc/src/sgml/html/release-8-1-7.html new file mode 100644 index 000000000..a4307c39b --- /dev/null +++ b/doc/src/sgml/html/release-8-1-7.html @@ -0,0 +1,275 @@ + +Release 8.1.7

E.103. Release 8.1.7

Release Date: 2007-02-05

This release contains a variety of fixes from 8.1.6, including + a security fix. + For information about new features in the 8.1 major release, see + Section E.110. +

E.103.1. Migration to Version 8.1.7

A dump/restore is not required for those running 8.1.X. + However, if you are upgrading from a version earlier than 8.1.2, + see the release notes for 8.1.2. +

E.103.2. Changes

  • Remove security vulnerabilities that allowed connected users + to read backend memory (Tom) +

    The vulnerabilities involve suppressing the normal check that a SQL + function returns the data type it's declared to, and changing the + data type of a table column (CVE-2007-0555, CVE-2007-0556). These + errors can easily be exploited to cause a backend crash, and in + principle might be used to read database content that the user + should not be able to access. +

  • Fix rare bug wherein btree index page splits could fail + due to choosing an infeasible split point (Heikki Linnakangas) +

  • Improve VACUUM performance for databases with many tables (Tom) +

  • Fix autovacuum to avoid leaving non-permanent transaction IDs in + non-connectable databases (Alvaro) +

    This bug affects the 8.1 branch only. +

  • Fix for rare Assert() crash triggered by UNION (Tom) +

  • Tighten security of multi-byte character processing for UTF8 sequences + over three bytes long (Tom) +

  • Fix bogus "permission denied" failures occurring on Windows + due to attempts to fsync already-deleted files (Magnus, Tom) +

  • Fix possible crashes when an already-in-use PL/pgSQL function is + updated (Tom) +


PrevHomeNext
Release 8.1.8UpRelease 8.1.6
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-1-8.html b/doc/src/sgml/html/release-8-1-8.html new file mode 100644 index 000000000..85fe7882f --- /dev/null +++ b/doc/src/sgml/html/release-8-1-8.html @@ -0,0 +1,214 @@ + +Release 8.1.8

E.102. Release 8.1.8

Release Date: 2007-02-07

This release contains one fix from 8.1.7. + For information about new features in the 8.1 major release, see + Section E.110. +

E.102.1. Migration to Version 8.1.8

A dump/restore is not required for those running 8.1.X. + However, if you are upgrading from a version earlier than 8.1.2, + see the release notes for 8.1.2. +

E.102.2. Changes

  • Remove overly-restrictive check for type length in constraints and + functional indexes(Tom) +


PrevHomeNext
Release 8.1.9UpRelease 8.1.7
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-1-9.html b/doc/src/sgml/html/release-8-1-9.html new file mode 100644 index 000000000..0ca88ad48 --- /dev/null +++ b/doc/src/sgml/html/release-8-1-9.html @@ -0,0 +1,278 @@ + +Release 8.1.9

E.101. Release 8.1.9

Release Date: 2007-04-23

This release contains a variety of fixes from 8.1.8, + including a security fix. + For information about new features in the 8.1 major release, see + Section E.110. +

E.101.1. Migration to Version 8.1.9

A dump/restore is not required for those running 8.1.X. + However, if you are upgrading from a version earlier than 8.1.2, + see the release notes for 8.1.2. +

E.101.2. Changes

  • Support explicit placement of the temporary-table schema within + search_path, and disable searching it for functions + and operators (Tom) +

    This is needed to allow a security-definer function to set a + truly secure value of search_path. Without it, + an unprivileged SQL user can use temporary objects to execute code + with the privileges of the security-definer function (CVE-2007-2138). + See CREATE FUNCTION for more information. +

  • /contrib/tsearch2 crash fixes (Teodor) +

  • Require COMMIT PREPARED to be executed in the same + database as the transaction was prepared in (Heikki) +

  • Fix potential-data-corruption bug in how VACUUM FULL handles + UPDATE chains (Tom, Pavan Deolasee) +

  • Planner fixes, including improving outer join and bitmap scan + selection logic (Tom) +

  • Fix PANIC during enlargement of a hash index (bug introduced in 8.1.6) + (Tom) +

  • Fix POSIX-style timezone specs to follow new USA DST rules (Tom) +


PrevHomeNext
Release 8.1.10UpRelease 8.1.8
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-1.html b/doc/src/sgml/html/release-8-1.html new file mode 100644 index 000000000..877ee6fae --- /dev/null +++ b/doc/src/sgml/html/release-8-1.html @@ -0,0 +1,3316 @@ + +Release 8.1

E.110. Release 8.1

Release Date: 2005-11-08

E.110.1. Overview

Major changes in this release: +

Improve concurrent access to the shared buffer cache (Tom)

Access to the shared buffer cache was identified as a + significant scalability problem, particularly on multi-CPU + systems. In this release, the way that locking is done in the + buffer manager has been overhauled to reduce lock contention + and improve scalability. The buffer manager has also been + changed to use a "clock sweep" replacement + policy. +

Allow index scans to use an intermediate in-memory bitmap (Tom)

In previous releases, only a single index could be used to do + lookups on a table. With this feature, if a query has + WHERE tab.col1 = 4 and tab.col2 = 9, and there is + no multicolumn index on col1 and col2, + but there is an index on col1 and another on + col2, it is possible to search both indexes and + combine the results in memory, then do heap fetches for only + the rows matching both the col1 and + col2 restrictions. This is very useful in + environments that have a lot of unstructured queries where it + is impossible to create indexes that match all possible access + conditions. Bitmap scans are useful even with a single index, + as they reduce the amount of random access needed; a bitmap + index scan is efficient for retrieving fairly large fractions + of the complete table, whereas plain index scans are not. +

Add two-phase commit (Heikki Linnakangas, Alvaro, Tom)

Two-phase commit allows transactions to be "prepared" on several + computers, and once all computers have successfully prepared + their transactions (none failed), all transactions can be + committed. Even if a machine crashes after a prepare, the + prepared transaction can be committed after the machine is + restarted. New syntax includes PREPARE TRANSACTION and + COMMIT/ROLLBACK PREPARED. A new system view + pg_prepared_xacts has also been added. +

Create a new role system that replaces users and groups + (Stephen Frost)

Roles are a combination of users and groups. Like users, they + can have login capability, and like groups, a role can have + other roles as members. Roles basically remove the distinction + between users and groups. For example, a role can: +

  • Have login capability (optionally) +

  • Own objects +

  • Hold access permissions for database objects +

  • Inherit permissions from other roles it is a member of +

Once a user logs into a role, she obtains capabilities of + the login role plus any inherited roles, and can use + SET ROLE to switch to other roles she is a member of. + This feature is a generalization of the SQL standard's concept of + roles. + This change also replaces pg_shadow and + pg_group by new role-capable catalogs + pg_authid and pg_auth_members. The old + tables are redefined as read-only views on the new role tables. +

Automatically use indexes for MIN() and + MAX() (Tom)

In previous releases, the only way to use an index for + MIN() or MAX() was to rewrite the + query as SELECT col FROM tab ORDER BY col LIMIT 1. + Index usage now happens automatically. +

Move /contrib/pg_autovacuum into the main server + (Alvaro)

Integrating autovacuum into the server allows it to be + automatically started and stopped in sync with the database + server, and allows autovacuum to be configured from + postgresql.conf. +

Add shared row level locks using SELECT ... FOR SHARE + (Alvaro)

While PostgreSQL's MVCC locking + allows SELECT to never be blocked by writers and + therefore does not need shared row locks for typical operations, + shared locks are useful for applications that require shared row + locking. In particular this reduces the locking requirements + imposed by referential integrity checks. +

Add dependencies on shared objects, specifically roles + (Alvaro)

This extension of the dependency mechanism prevents roles from + being dropped while there are still database objects they own. + Formerly it was possible to accidentally "orphan" objects by + deleting their owner. While this could be recovered from, it + was messy and unpleasant. +

Improve performance for partitioned tables (Simon)

The new constraint_exclusion configuration + parameter avoids lookups on child tables where constraints indicate + that no matching rows exist in the child table. +

This allows for a basic type of table partitioning. If child tables + store separate key ranges and this is enforced using appropriate + CHECK constraints, the optimizer will skip child + table accesses when the constraint guarantees no matching rows + exist in the child table. +

E.110.2. Migration to Version 8.1

A dump/restore using pg_dump is required + for those wishing to migrate data from any previous release. +

The 8.0 release announced that the to_char() function + for intervals would be removed in 8.1. However, since no better API + has been suggested, to_char(interval) has been enhanced in + 8.1 and will remain in the server. +

Observe the following incompatibilities: +

  • add_missing_from is now false by default (Neil) +

    By default, we now generate an error if a table is used in a query + without a FROM reference. The old behavior is still + available, but the parameter must be set to 'true' to obtain it. +

    It might be necessary to set add_missing_from to true + in order to load an existing dump file, if the dump contains any + views or rules created using the implicit-FROM syntax. + This should be a one-time annoyance, because + PostgreSQL 8.1 will convert + such views and rules to standard explicit-FROM syntax. + Subsequent dumps will therefore not have the problem. +

  • Cause input of a zero-length string ('') for + float4/float8/oid + to throw an error, rather than treating it as a zero (Neil) +

    This change is consistent with the current handling of + zero-length strings for integers. The schedule for this change + was announced in 8.0. +

  • default_with_oids is now false by default (Neil) +

    With this option set to false, user-created tables no longer + have an OID column unless WITH OIDS is specified in + CREATE TABLE. Though OIDs have existed in all + releases of PostgreSQL, their use is limited + because they are only four bytes long and the counter is shared + across all installed databases. The preferred way of uniquely + identifying rows is via sequences and the SERIAL type, + which have been supported since PostgreSQL 6.4. +

  • Add E'' syntax so eventually ordinary strings can + treat backslashes literally (Bruce) +

    Currently PostgreSQL processes a + backslash in a string literal as introducing a special escape sequence, + e.g. \n or \010. + While this allows easy entry of special values, it is + nonstandard and makes porting of applications from other + databases more difficult. For this reason, the + PostgreSQL project is planning to + remove the special meaning of backslashes in strings. For + backward compatibility and for users who want special backslash + processing, a new string syntax has been created. This new string + syntax is formed by writing an E immediately preceding the + single quote that starts the string, e.g. E'hi\n'. While + this release does not change the handling of backslashes in strings, it + does add new configuration parameters to help users migrate applications + for future releases: +

    • standard_conforming_strings — does this release + treat backslashes literally in ordinary strings? +

    • escape_string_warning — warn about backslashes in + ordinary (non-E) strings +

    The standard_conforming_strings value is read-only. + Applications can retrieve the value to know how backslashes are + processed. (Presence of the parameter can also be taken as an + indication that E'' string syntax is supported.) + In a future release, standard_conforming_strings + will be true, meaning backslashes will be treated literally in + non-E strings. To prepare for this change, use E'' + strings in places that need special backslash processing, and + turn on escape_string_warning to find additional + strings that need to be converted to use E''. + Also, use two single-quotes ('') to embed a literal + single-quote in a string, rather than the + PostgreSQL-supported syntax of + backslash single-quote (\'). The former is + standards-conforming and does not require the use of the + E'' string syntax. You can also use the + $$ string syntax, which does not treat backslashes + specially. +

  • Make REINDEX DATABASE reindex all indexes in the + database (Tom) +

    Formerly, REINDEX DATABASE reindexed only + system tables. This new behavior seems more intuitive. A new + command REINDEX SYSTEM provides the old functionality + of reindexing just the system tables. +

  • Read-only large object descriptors now obey MVCC snapshot semantics +

    When a large object is opened with INV_READ (and not + INV_WRITE), the data read from the descriptor will now + reflect a "snapshot" of the large object's state at the + time of the transaction snapshot in use by the query that called + lo_open(). To obtain the old behavior of always + returning the latest committed data, include INV_WRITE + in the mode flags for lo_open(). +

  • Add proper dependencies for arguments of sequence functions (Tom) +

    In previous releases, sequence names passed to nextval(), + currval(), and setval() were stored as + simple text strings, meaning that renaming or dropping a + sequence used in a DEFAULT clause made the clause + invalid. This release stores all newly-created sequence function + arguments as internal OIDs, allowing them to track sequence + renaming, and adding dependency information that prevents + improper sequence removal. It also makes such DEFAULT + clauses immune to schema renaming and search path changes. +

    Some applications might rely on the old behavior of + run-time lookup for sequence names. This can still be done by + explicitly casting the argument to text, for example + nextval('myseq'::text). +

    Pre-8.1 database dumps loaded into 8.1 will use the old text-based + representation and therefore will not have the features of + OID-stored arguments. However, it is possible to update a + database containing text-based DEFAULT clauses. + First, save this query into a file, such as fixseq.sql: +

    SELECT  'ALTER TABLE ' ||
    +   pg_catalog.quote_ident(n.nspname) || '.' ||
    +   pg_catalog.quote_ident(c.relname) ||
    +   ' ALTER COLUMN ' || pg_catalog.quote_ident(a.attname) ||
    +   ' SET DEFAULT ' ||
    +   regexp_replace(d.adsrc,
    +                  $$val\(\(('[^']*')::text\)::regclass$$,
    +                  $$val(\1$$,
    +                  'g') ||
    +   ';'
    +FROM    pg_namespace n, pg_class c, pg_attribute a, pg_attrdef d
    +WHERE   n.oid = c.relnamespace AND
    +   c.oid = a.attrelid AND
    +   a.attrelid = d.adrelid AND
    +   a.attnum = d.adnum AND
    +   d.adsrc ~ $$val\(\('[^']*'::text\)::regclass$$;

    + Next, run the query against a database to find what + adjustments are required, like this for database db1: +

    psql -t -f fixseq.sql db1

    + This will show the ALTER TABLE commands needed to + convert the database to the newer OID-based representation. + If the commands look reasonable, run this to update the database: +

    psql -t -f fixseq.sql db1 | psql -e db1

    + This process must be repeated in each database to be updated. +

  • In psql, treat unquoted + \{digit}+ sequences as octal (Bruce) +

    In previous releases, \{digit}+ sequences were + treated as decimal, and only \0{digit}+ were treated + as octal. This change was made for consistency. +

  • Remove grammar productions for prefix and postfix % + and ^ operators + (Tom) +

    These have never been documented and complicated the use of the + modulus operator (%) with negative numbers. +

  • Make &< and &> for polygons + consistent with the box "over" operators (Tom) +

  • CREATE LANGUAGE can ignore the provided arguments + in favor of information from pg_pltemplate + (Tom) +

    A new system catalog pg_pltemplate has been defined + to carry information about the preferred definitions of procedural + languages (such as whether they have validator functions). When + an entry exists in this catalog for the language being created, + CREATE LANGUAGE will ignore all its parameters except the + language name and instead use the catalog information. This measure + was taken because of increasing problems with obsolete language + definitions being loaded by old dump files. As of 8.1, + pg_dump will dump procedural language definitions as + just CREATE LANGUAGE name, relying + on a template entry to exist at load time. We expect this will be a + more future-proof representation. +

  • Make pg_cancel_backend(int) return a + boolean rather than an integer (Neil) +

  • Some users are having problems loading UTF-8 data into 8.1.X. + This is because previous versions allowed invalid UTF-8 byte + sequences to be entered into the database, and this release + properly accepts only valid UTF-8 sequences. One way to correct a + dumpfile is to run the command iconv -c -f UTF-8 -t + UTF-8 -o cleanfile.sql dumpfile.sql. The -c option + removes invalid character sequences. A diff of the two files will + show the sequences that are invalid. iconv reads the + entire input file into memory so it might be necessary to use + split to break up the dump into multiple smaller + files for processing. +

E.110.3. Additional Changes

Below you will find a detailed account of the additional changes + between PostgreSQL 8.1 and the + previous major release. +

E.110.3.1. Performance Improvements

  • Improve GiST and R-tree index performance (Neil) +

  • Improve the optimizer, including auto-resizing of hash joins + (Tom) +

  • Overhaul internal API in several areas +

  • Change WAL record CRCs from 64-bit to 32-bit (Tom) +

    We determined that the extra cost of computing 64-bit CRCs was + significant, and the gain in reliability too marginal to justify it. +

  • Prevent writing large empty gaps in WAL pages (Tom) +

  • Improve spinlock behavior on SMP machines, particularly Opterons (Tom) +

  • Allow nonconsecutive index columns to be used in a multicolumn + index (Tom) +

    For example, this allows an index on columns a,b,c to be used in + a query with WHERE a = 4 and c = 10. +

  • Skip WAL logging for CREATE TABLE AS / + SELECT INTO (Simon) +

    Since a crash during CREATE TABLE AS would cause the + table to be dropped during recovery, there is no reason to WAL + log as the table is loaded. (Logging still happens if WAL + archiving is enabled, however.) +

  • Allow concurrent GiST index access (Teodor, Oleg) +

  • Add configuration parameter full_page_writes to + control writing full pages to WAL (Bruce) +

    To prevent partial disk writes from corrupting the database, + PostgreSQL writes a complete copy of + each database disk page to WAL the first time it is modified + after a checkpoint. This option turns off that functionality for more + speed. This is safe to use with battery-backed disk caches where + partial page writes cannot happen. +

  • Use O_DIRECT if available when using + O_SYNC for wal_sync_method + (Itagaki Takahiro) +

    O_DIRECT causes disk writes to bypass the kernel + cache, and for WAL writes, this improves performance. +

  • Improve COPY FROM performance (Alon Goldshuv) +

    This was accomplished by reading COPY input in + larger chunks, rather than character by character. +

  • Improve the performance of COUNT(), + SUM, AVG(), + STDDEV(), and + VARIANCE() (Neil, Tom) +

E.110.3.2. Server Changes

  • Prevent problems due to transaction ID (XID) wraparound (Tom) +

    The server will now warn when the transaction counter approaches + the wraparound point. If the counter becomes too close to wraparound, + the server will stop accepting queries. This ensures that data is + not lost before needed vacuuming is performed. +

  • Fix problems with object IDs (OIDs) conflicting with existing system + objects after the OID counter has wrapped around (Tom) +

  • Add warning about the need to increase + max_fsm_relations and max_fsm_pages + during VACUUM (Ron Mayer) +

  • Add temp_buffers configuration parameter to allow + users to determine the size of the local buffer area for + temporary table access (Tom) +

  • Add session start time and client IP address to + pg_stat_activity (Magnus) +

  • Adjust pg_stat views for bitmap scans (Tom) +

    The meanings of some of the fields have changed slightly. +

  • Enhance pg_locks view (Tom) +

  • Log queries for client-side PREPARE and + EXECUTE (Simon) +

  • Allow Kerberos name and user name case sensitivity to be + specified in postgresql.conf (Magnus) +

  • Add configuration parameter krb_server_hostname so + that the server host name can be specified as part of service + principal (Todd Kover) +

    If not set, any service principal matching an entry in the + keytab can be used. This is new Kerberos matching behavior in + this release. +

  • Add log_line_prefix options for millisecond + timestamps (%m) and remote host (%h) (Ed + L.) +

  • Add WAL logging for GiST indexes (Teodor, Oleg) +

    GiST indexes are now safe for crash and point-in-time recovery. +

  • Remove old *.backup files when we do + pg_stop_backup() (Bruce) +

    This prevents a large number of *.backup files from + existing in pg_xlog/. +

  • Add configuration parameters to control TCP/IP keep-alive + times for idle, interval, and count (Oliver Jowett) +

    These values can be changed to allow more rapid detection of + lost client connections. +

  • Add per-user and per-database connection limits (Petr Jelinek) +

    Using ALTER USER and ALTER DATABASE, + limits can now be enforced on the maximum number of sessions that + can concurrently connect as a specific user or to a specific database. + Setting the limit to zero disables user or database connections. +

  • Allow more than two gigabytes of shared memory and per-backend + work memory on 64-bit machines (Koichi Suzuki) +

  • New system catalog pg_pltemplate allows overriding + obsolete procedural-language definitions in dump files (Tom) +

E.110.3.3. Query Changes

  • Add temporary views (Koju Iijima, Neil) +

  • Fix HAVING without any aggregate functions or + GROUP BY so that the query returns a single group (Tom) +

    Previously, such a case would treat the HAVING + clause the same as a WHERE clause. This was not per spec. +

  • Add USING clause to allow additional tables to be + specified to DELETE (Euler Taveira de Oliveira, Neil) +

    In prior releases, there was no clear method for specifying + additional tables to be used for joins in a DELETE + statement. UPDATE already has a FROM + clause for this purpose. +

  • Add support for \x hex escapes in backend and ecpg + strings (Bruce) +

    This is just like the standard C \x escape syntax. + Octal escapes were already supported. +

  • Add BETWEEN SYMMETRIC query syntax (Pavel Stehule) +

    This feature allows BETWEEN comparisons without + requiring the first value to be less than the second. For + example, 2 BETWEEN [ASYMMETRIC] 3 AND 1 returns + false, while 2 BETWEEN SYMMETRIC 3 AND 1 returns + true. BETWEEN ASYMMETRIC was already supported. +

  • Add NOWAIT option to SELECT ... FOR + UPDATE/SHARE (Hans-Juergen Schoenig) +

    While the statement_timeout configuration + parameter allows a query taking more than a certain amount of + time to be canceled, the NOWAIT option allows a + query to be canceled as soon as a SELECT ... FOR + UPDATE/SHARE command cannot immediately acquire a row lock. +

E.110.3.4. Object Manipulation Changes

  • Track dependencies of shared objects (Alvaro) +

    PostgreSQL allows global tables + (users, databases, tablespaces) to reference information in + multiple databases. This addition adds dependency information + for global tables, so, for example, user ownership can be + tracked across databases, so a user who owns something in any + database can no longer be removed. Dependency tracking already + existed for database-local objects. +

  • Allow limited ALTER OWNER commands to be performed + by the object owner (Stephen Frost) +

    Prior releases allowed only superusers to change object owners. + Now, ownership can be transferred if the user executing the command + owns the object and would be able to create it as the new owner + (that is, the user is a member of the new owning role and that role + has the CREATE permission that would be needed to create the object + afresh). +

  • Add ALTER object SET SCHEMA capability + for some object types (tables, functions, types) (Bernd Helmle) +

    This allows objects to be moved to different schemas. +

  • Add ALTER TABLE ENABLE/DISABLE TRIGGER to + disable triggers (Satoshi Nagayasu) +

E.110.3.5. Utility Command Changes

  • Allow TRUNCATE to truncate multiple tables in a + single command (Alvaro) +

    Because of referential integrity checks, it is not allowed to + truncate a table that is part of a referential integrity + constraint. Using this new functionality, TRUNCATE + can be used to truncate such tables, if both tables involved in + a referential integrity constraint are truncated in a single + TRUNCATE command. +

  • Properly process carriage returns and line feeds in + COPY CSV mode (Andrew) +

    In release 8.0, carriage returns and line feeds in CSV + COPY TO were processed in an inconsistent manner. (This was + documented on the TODO list.) +

  • Add COPY WITH CSV HEADER to allow a header line as + the first line in COPY (Andrew) +

    This allows handling of the common CSV usage of + placing the column names on the first line of the data file. For + COPY TO, the first line contains the column names, + and for COPY FROM, the first line is ignored. +

  • On Windows, display better sub-second precision in + EXPLAIN ANALYZE (Magnus) +

  • Add trigger duration display to EXPLAIN ANALYZE + (Tom) +

    Prior releases included trigger execution time as part of the + total execution time, but did not show it separately. It is now + possible to see how much time is spent in each trigger. +

  • Add support for \x hex escapes in COPY + (Sergey Ten) +

    Previous releases only supported octal escapes. +

  • Make SHOW ALL include variable descriptions + (Matthias Schmidt) +

    SHOW varname still only displays the variable's + value and does not include the description. +

  • Make initdb create a new standard + database called postgres, and convert utilities to + use postgres rather than template1 for + standard lookups (Dave) +

    In prior releases, template1 was used both as a + default connection for utilities like + createuser, and as a template for + new databases. This caused CREATE DATABASE to + sometimes fail, because a new database cannot be created if + anyone else is in the template database. With this change, the + default connection database is now postgres, + meaning it is much less likely someone will be using + template1 during CREATE DATABASE. +

  • Create new reindexdb command-line + utility by moving /contrib/reindexdb into the + server (Euler Taveira de Oliveira) +

E.110.3.6. Data Type and Function Changes

  • Add MAX() and MIN() aggregates for + array types (Koju Iijima) +

  • Fix to_date() and to_timestamp() to + behave reasonably when CC and YY fields + are both used (Karel Zak) +

    If the format specification contains CC and a year + specification is YYY or longer, ignore the + CC. If the year specification is YY or + shorter, interpret CC as the previous century. +

  • Add md5(bytea) (Abhijit Menon-Sen) +

    md5(text) already existed. +

  • Add support for numeric ^ numeric based on + power(numeric, numeric) +

    The function already existed, but there was no operator assigned + to it. +

  • Fix NUMERIC modulus by properly truncating the quotient + during computation (Bruce) +

    In previous releases, modulus for large values sometimes + returned negative results due to rounding of the quotient. +

  • Add a function lastval() (Dennis Björklund) +

    lastval() is a simplified version of + currval(). It automatically determines the proper + sequence name based on the most recent nextval() or + setval() call performed by the current session. +

  • Add to_timestamp(DOUBLE PRECISION) (Michael Glaesemann) +

    Converts Unix seconds since 1970 to a TIMESTAMP WITH + TIMEZONE. +

  • Add pg_postmaster_start_time() function (Euler + Taveira de Oliveira, Matthias Schmidt) +

  • Allow the full use of time zone names in AT TIME + ZONE, not just the short list previously available (Magnus) +

    Previously, only a predefined list of time zone names were + supported by AT TIME ZONE. Now any supported time + zone name can be used, e.g.: +

    SELECT CURRENT_TIMESTAMP AT TIME ZONE 'Europe/London';

    + In the above query, the time zone used is adjusted based on the + daylight saving time rules that were in effect on the supplied + date. +

  • Add GREATEST() and LEAST() variadic + functions (Pavel Stehule) +

    These functions take a variable number of arguments and return + the greatest or least value among the arguments. +

  • Add pg_column_size() (Mark Kirkwood) +

    This returns storage size of a column, which might be compressed. +

  • Add regexp_replace() (Atsushi Ogawa) +

    This allows regular expression replacement, like sed. An optional + flag argument allows selection of global (replace all) and + case-insensitive modes. +

  • Fix interval division and multiplication (Bruce) +

    Previous versions sometimes returned unjustified results, like + '4 months'::interval / 5 returning '1 mon + -6 days'. +

  • Fix roundoff behavior in timestamp, time, and interval output (Tom) +

    This fixes some cases in which the seconds field would be shown as + 60 instead of incrementing the higher-order fields. +

  • Add a separate day field to type interval so a one day + interval can be distinguished from a 24 hour interval (Michael + Glaesemann) +

    Days that contain a daylight saving time adjustment are not 24 + hours long, but typically 23 or 25 hours. This change creates a + conceptual distinction between intervals of "so many days" + and intervals of "so many hours". Adding + 1 day to a timestamp now gives the same local time on + the next day even if a daylight saving time adjustment occurs + between, whereas adding 24 hours will give a different + local time when this happens. For example, under US DST rules: +

    '2005-04-03 00:00:00-05' + '1 day' = '2005-04-04 00:00:00-04'
    +'2005-04-03 00:00:00-05' + '24 hours' = '2005-04-04 01:00:00-04'

    +

  • Add justify_days() and justify_hours() + (Michael Glaesemann) +

    These functions, respectively, adjust days to an appropriate + number of full months and days, and adjust hours to an + appropriate number of full days and hours. +

  • Move /contrib/dbsize into the backend, and rename + some of the functions (Dave Page, Andreas Pflug) +

    • pg_tablespace_size() +

    • pg_database_size() +

    • pg_relation_size() +

    • pg_total_relation_size() +

    • pg_size_pretty() +

    +

    pg_total_relation_size() includes indexes and TOAST + tables. +

  • Add functions for read-only file access to the cluster directory + (Dave Page, Andreas Pflug) +

    • pg_stat_file() +

    • pg_read_file() +

    • pg_ls_dir() +

    +

  • Add pg_reload_conf() to force reloading of the + configuration files (Dave Page, Andreas Pflug) +

  • Add pg_rotate_logfile() to force rotation of the + server log file (Dave Page, Andreas Pflug) +

  • Change pg_stat_* views to include TOAST tables (Tom) +

E.110.3.7. Encoding and Locale Changes

  • Rename some encodings to be more consistent and to follow + international standards (Bruce) +

    • UNICODE is now UTF8 +

    • ALT is now WIN866 +

    • WIN is now WIN1251 +

    • TCVN is now WIN1258 +

    +

    The original names still work. +

  • Add support for WIN1252 encoding (Roland Volkmann) +

  • Add support for four-byte UTF8 characters (John + Hansen) +

    Previously only one, two, and three-byte UTF8 characters + were supported. This is particularly important for support for + some Chinese character sets. +

  • Allow direct conversion between EUC_JP and + SJIS to improve performance (Atsushi Ogawa) +

  • Allow the UTF8 encoding to work on Windows (Magnus) +

    This is done by mapping UTF8 to the Windows-native UTF16 + implementation. +

E.110.3.8. General Server-Side Language Changes

  • Fix ALTER LANGUAGE RENAME (Sergey Yatskevich) +

  • Allow function characteristics, like strictness and volatility, + to be modified via ALTER FUNCTION (Neil) +

  • Increase the maximum number of function arguments to 100 (Tom) +

  • Allow SQL and PL/pgSQL functions to use OUT and + INOUT parameters (Tom) +

    OUT is an alternate way for a function to return + values. Instead of using RETURN, values can be + returned by assigning to parameters declared as OUT or + INOUT. This is notationally simpler in some cases, + particularly so when multiple values need to be returned. + While returning multiple values from a function + was possible in previous releases, this greatly simplifies the + process. (The feature will be extended to other server-side + languages in future releases.) +

  • Move language handler functions into the pg_catalog schema +

    This makes it easier to drop the public schema if desired. +

  • Add SPI_getnspname() to SPI (Neil) +

E.110.3.9. PL/pgSQL Server-Side Language Changes

  • Overhaul the memory management of PL/pgSQL functions (Neil) +

    The parsetree of each function is now stored in a separate + memory context. This allows this memory to be easily reclaimed + when it is no longer needed. +

  • Check function syntax at CREATE FUNCTION time, + rather than at runtime (Neil) +

    Previously, most syntax errors were reported only when the + function was executed. +

  • Allow OPEN to open non-SELECT queries + like EXPLAIN and SHOW (Tom) +

  • No longer require functions to issue a RETURN + statement (Tom) +

    This is a byproduct of the newly added OUT and + INOUT functionality. RETURN can + be omitted when it is not needed to provide the function's + return value. +

  • Add support for an optional INTO clause to + PL/pgSQL's EXECUTE statement (Pavel Stehule, Neil) +

  • Make CREATE TABLE AS set ROW_COUNT (Tom) +

  • Define SQLSTATE and SQLERRM to return + the SQLSTATE and error message of the current + exception (Pavel Stehule, Neil) +

    These variables are only defined inside exception blocks. +

  • Allow the parameters to the RAISE statement to be + expressions (Pavel Stehule, Neil) +

  • Add a loop CONTINUE statement (Pavel Stehule, Neil) +

  • Allow block and loop labels (Pavel Stehule) +

E.110.3.10. PL/Perl Server-Side Language Changes

  • Allow large result sets to be returned efficiently (Abhijit + Menon-Sen) +

    This allows functions to use return_next() to avoid + building the entire result set in memory. +

  • Allow one-row-at-a-time retrieval of query results (Abhijit Menon-Sen) +

    This allows functions to use spi_query() and + spi_fetchrow() to avoid accumulating the entire + result set in memory. +

  • Force PL/Perl to handle strings as UTF8 if the + server encoding is UTF8 (David Kamholz) +

  • Add a validator function for PL/Perl (Andrew) +

    This allows syntax errors to be reported at definition time, + rather than execution time. +

  • Allow PL/Perl to return a Perl array when the function returns + an array type (Andrew) +

    This basically maps PostgreSQL arrays + to Perl arrays. +

  • Allow Perl nonfatal warnings to generate NOTICE + messages (Andrew) +

  • Allow Perl's strict mode to be enabled (Andrew) +

E.110.3.11. psql Changes

  • Add \set ON_ERROR_ROLLBACK to allow statements in + a transaction to error without affecting the rest of the + transaction (Greg Sabino Mullane) +

    This is basically implemented by wrapping every statement in a + sub-transaction. +

  • Add support for \x hex strings in + psql variables (Bruce) +

    Octal escapes were already supported. +

  • Add support for troff -ms output format (Roger + Leigh) +

  • Allow the history file location to be controlled by + HISTFILE (Andreas Seltenreich) +

    This allows configuration of per-database history storage. +

  • Prevent \x (expanded mode) from affecting + the output of \d tablename (Neil) +

  • Add -L option to psql to + log sessions (Lorne Sunley) +

    This option was added because some operating systems do not have + simple command-line activity logging functionality. +

  • Make \d show the tablespaces of indexes (Qingqing + Zhou) +

  • Allow psql help (\h) to + make a best guess on the proper help information (Greg Sabino + Mullane) +

    This allows the user to just add \h to the front of + the syntax error query and get help on the supported syntax. + Previously any additional query text beyond the command name + had to be removed to use \h. +

  • Add \pset numericlocale to allow numbers to be + output in a locale-aware format (Eugen Nedelcu) +

    For example, using C locale 100000 would + be output as 100,000.0 while a European locale might + output this value as 100.000,0. +

  • Make startup banner show both server version number and + psql's version number, when they are different (Bruce) +

    Also, a warning will be shown if the server and psql + are from different major releases. +

E.110.3.12. pg_dump Changes

  • Add -n / --schema switch to + pg_restore (Richard van den Berg) +

    This allows just the objects in a specified schema to be restored. +

  • Allow pg_dump to dump large objects even in + text mode (Tom) +

    With this change, large objects are now always dumped; the former + -b switch is a no-op. +

  • Allow pg_dump to dump a consistent snapshot of + large objects (Tom) +

  • Dump comments for large objects (Tom) +

  • Add --encoding to pg_dump + (Magnus Hagander) +

    This allows a database to be dumped in an encoding that is + different from the server's encoding. This is valuable when + transferring the dump to a machine with a different encoding. +

  • Rely on pg_pltemplate for procedural languages (Tom) +

    If the call handler for a procedural language is in the + pg_catalog schema, pg_dump does not + dump the handler. Instead, it dumps the language using just + CREATE LANGUAGE name, + relying on the pg_pltemplate catalog to provide + the language's creation parameters at load time. +

E.110.3.13. libpq Changes

  • Add a PGPASSFILE environment variable to specify the + password file's filename (Andrew) +

  • Add lo_create(), that is similar to + lo_creat() but allows the OID of the large object + to be specified (Tom) +

  • Make libpq consistently return an error + to the client application on malloc() + failure (Neil) +

E.110.3.14. Source Code Changes

  • Fix pgxs to support building against a relocated + installation +

  • Add spinlock support for the Itanium processor using Intel + compiler (Vikram Kalsi) +

  • Add Kerberos 5 support for Windows (Magnus) +

  • Add Chinese FAQ (laser@pgsqldb.com) +

  • Rename Rendezvous to Bonjour to match OS/X feature renaming + (Bruce) +

  • Add support for fsync_writethrough on + Darwin (Chris Campbell) +

  • Streamline the passing of information within the server, the + optimizer, and the lock system (Tom) +

  • Allow pg_config to be compiled using MSVC (Andrew) +

    This is required to build DBD::Pg using MSVC. +

  • Remove support for Kerberos V4 (Magnus) +

    Kerberos 4 had security vulnerabilities and is no longer + maintained. +

  • Code cleanups (Coverity static analysis performed by + EnterpriseDB) +

  • Modify postgresql.conf to use documentation defaults + on/off rather than + true/false (Bruce) +

  • Enhance pg_config to be able to report more + build-time values (Tom) +

  • Allow libpq to be built thread-safe + on Windows (Dave Page) +

  • Allow IPv6 connections to be used on Windows (Andrew) +

  • Add Server Administration documentation about I/O subsystem + reliability (Bruce) +

  • Move private declarations from gist.h to + gist_private.h (Neil) +

    In previous releases, gist.h contained both the + public GiST API (intended for use by authors of GiST index + implementations) as well as some private declarations used by + the implementation of GiST itself. The latter have been moved + to a separate file, gist_private.h. Most GiST + index implementations should be unaffected. +

  • Overhaul GiST memory management (Neil) +

    GiST methods are now always invoked in a short-lived memory + context. Therefore, memory allocated via palloc() + will be reclaimed automatically, so GiST index implementations + do not need to manually release allocated memory via + pfree(). +

E.110.3.15. Contrib Changes

  • Add /contrib/pg_buffercache contrib module (Mark + Kirkwood) +

    This displays the contents of the buffer cache, for debugging and + performance tuning purposes. +

  • Remove /contrib/array because it is obsolete (Tom) +

  • Clean up the /contrib/lo module (Tom) +

  • Move /contrib/findoidjoins to + /src/tools (Tom) +

  • Remove the <<, >>, + &<, and &> operators from + /contrib/cube +

    These operators were not useful. +

  • Improve /contrib/btree_gist (Janko Richter) +

  • Improve /contrib/pgbench (Tomoaki Sato, Tatsuo) +

    There is now a facility for testing with SQL command scripts given + by the user, instead of only a hard-wired command sequence. +

  • Improve /contrib/pgcrypto (Marko Kreen) +

    • Implementation of OpenPGP symmetric-key and public-key encryption +

      Both RSA and Elgamal public-key algorithms are supported. +

    • Stand alone build: include SHA256/384/512 hashes, Fortuna PRNG +

    • OpenSSL build: support 3DES, use internal AES with OpenSSL < 0.9.7 +

    • Take build parameters (OpenSSL, zlib) from configure result +

      There is no need to edit the Makefile anymore. +

    • Remove support for libmhash and libmcrypt +


PrevHomeNext
Release 8.1.1UpRelease 8.0.26
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-2-1.html b/doc/src/sgml/html/release-8-2-1.html new file mode 100644 index 000000000..00560c983 --- /dev/null +++ b/doc/src/sgml/html/release-8-2-1.html @@ -0,0 +1,339 @@ + +Release 8.2.1

E.85. Release 8.2.1

Release Date: 2007-01-08

This release contains a variety of fixes from 8.2. + For information about new features in the 8.2 major release, see + Section E.86. +

E.85.1. Migration to Version 8.2.1

A dump/restore is not required for those running 8.2. +

E.85.2. Changes

  • Fix crash with SELECT ... LIMIT ALL (also + LIMIT NULL) (Tom) +

  • Several /contrib/tsearch2 fixes (Teodor) +

  • On Windows, make log messages coming from the operating system use + ASCII encoding (Hiroshi Saito) +

    This fixes a conversion problem when there is a mismatch between + the encoding of the operating system and database server. +

  • Fix Windows linking of pg_dump using + win32.mak + (Hiroshi Saito) +

  • Fix planner mistakes for outer join queries (Tom) +

  • Fix several problems in queries involving sub-SELECTs (Tom) +

  • Fix potential crash in SPI during subtransaction abort (Tom) +

    This affects all PL functions since they all use SPI. +

  • Improve build speed of PDF documentation (Peter) +

  • Re-add JST (Japan) timezone abbreviation (Tom) +

  • Improve optimization decisions related to index scans (Tom) +

  • Have psql print multi-byte combining characters as + before, rather than output as \u (Tom) +

  • Improve index usage of regular expressions that use parentheses (Tom) +

    This improves psql \d performance also. +

  • Make pg_dumpall assume that databases have public + CONNECT privilege, when dumping from a pre-8.2 server (Tom) +

    This preserves the previous behavior that anyone can connect to a + database if allowed by pg_hba.conf. +


PrevHomeNext
Release 8.2.2UpRelease 8.2
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-2-10.html b/doc/src/sgml/html/release-8-2-10.html new file mode 100644 index 000000000..a74da603b --- /dev/null +++ b/doc/src/sgml/html/release-8-2-10.html @@ -0,0 +1,458 @@ + +Release 8.2.10

E.76. Release 8.2.10

Release Date: 2008-09-22

This release contains a variety of fixes from 8.2.9. + For information about new features in the 8.2 major release, see + Section E.86. +

E.76.1. Migration to Version 8.2.10

A dump/restore is not required for those running 8.2.X. + However, if you are upgrading from a version earlier than 8.2.7, + see the release notes for 8.2.7. +

E.76.2. Changes

  • Fix bug in btree WAL recovery code (Heikki) +

    Recovery failed if the WAL ended partway through a page split operation. +

  • Fix potential miscalculation of datfrozenxid (Alvaro) +

    This error may explain some recent reports of failure to remove old + pg_clog data. +

  • Widen local lock counters from 32 to 64 bits (Tom) +

    This responds to reports that the counters could overflow in + sufficiently long transactions, leading to unexpected "lock is + already held" errors. +

  • Fix possible duplicate output of tuples during a GiST index scan (Teodor) +

  • Fix missed permissions checks when a view contains a simple + UNION ALL construct (Heikki) +

    Permissions for the referenced tables were checked properly, but not + permissions for the view itself. +

  • Add checks in executor startup to ensure that the tuples produced by an + INSERT or UPDATE will match the target table's + current rowtype (Tom) +

    ALTER COLUMN TYPE, followed by re-use of a previously + cached plan, could produce this type of situation. The check protects + against data corruption and/or crashes that could ensue. +

  • Fix possible repeated drops during DROP OWNED (Tom) +

    This would typically result in strange errors such as "cache + lookup failed for relation NNN". +

  • Fix AT TIME ZONE to first try to interpret its timezone + argument as a timezone abbreviation, and only try it as a full timezone + name if that fails, rather than the other way around as formerly (Tom) +

    The timestamp input functions have always resolved ambiguous zone names + in this order. Making AT TIME ZONE do so as well improves + consistency, and fixes a compatibility bug introduced in 8.1: + in ambiguous cases we now behave the same as 8.0 and before did, + since in the older versions AT TIME ZONE accepted + only abbreviations. +

  • Fix datetime input functions to correctly detect integer overflow when + running on a 64-bit platform (Tom) +

  • Prevent integer overflows during units conversion when displaying a + configuration parameter that has units (Tom) +

  • Improve performance of writing very long log messages to syslog (Tom) +

  • Allow spaces in the suffix part of an LDAP URL in + pg_hba.conf (Tom) +

  • Fix bug in backwards scanning of a cursor on a SELECT DISTINCT + ON query (Tom) +

  • Fix planner bug with nested sub-select expressions (Tom) +

    If the outer sub-select has no direct dependency on the parent query, + but the inner one does, the outer value might not get recalculated + for new parent query rows. +

  • Fix planner to estimate that GROUP BY expressions yielding + boolean results always result in two groups, regardless of the + expressions' contents (Tom) +

    This is very substantially more accurate than the regular GROUP + BY estimate for certain boolean tests like col + IS NULL. +

  • Fix PL/pgSQL to not fail when a FOR loop's target variable + is a record containing composite-type fields (Tom) +

  • Fix PL/Tcl to behave correctly with Tcl 8.5, and to be more careful + about the encoding of data sent to or from Tcl (Tom) +

  • On Windows, work around a Microsoft bug by preventing + libpq from trying to send more than 64kB per system call + (Magnus) +

  • Improve pg_dump and pg_restore's + error reporting after failure to send a SQL command (Tom) +

  • Fix pg_ctl to properly preserve postmaster + command-line arguments across a restart (Bruce) +

  • Update time zone data files to tzdata release 2008f (for + DST law changes in Argentina, Bahamas, Brazil, Mauritius, Morocco, + Pakistan, Palestine, and Paraguay) +


PrevHomeNext
Release 8.2.11UpRelease 8.2.9
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-2-11.html b/doc/src/sgml/html/release-8-2-11.html new file mode 100644 index 000000000..bf90243b8 --- /dev/null +++ b/doc/src/sgml/html/release-8-2-11.html @@ -0,0 +1,411 @@ + +Release 8.2.11

E.75. Release 8.2.11

Release Date: 2008-11-03

This release contains a variety of fixes from 8.2.10. + For information about new features in the 8.2 major release, see + Section E.86. +

E.75.1. Migration to Version 8.2.11

A dump/restore is not required for those running 8.2.X. + However, if you are upgrading from a version earlier than 8.2.7, + see the release notes for 8.2.7. Also, if you were running a previous + 8.2.X release, it is recommended to REINDEX all GiST + indexes after the upgrade. +

E.75.2. Changes

  • Fix GiST index corruption due to marking the wrong index entry + "dead" after a deletion (Teodor) +

    This would result in index searches failing to find rows they + should have found. Corrupted indexes can be fixed with + REINDEX. +

  • Fix backend crash when the client encoding cannot represent a localized + error message (Tom) +

    We have addressed similar issues before, but it would still fail if + the "character has no equivalent" message itself couldn't + be converted. The fix is to disable localization and send the plain + ASCII error message when we detect such a situation. +

  • Fix possible crash when deeply nested functions are invoked from + a trigger (Tom) +

  • Improve optimization of expression IN + (expression-list) queries (Tom, per an idea from Robert + Haas) +

    Cases in which there are query variables on the right-hand side had been + handled less efficiently in 8.2.x and 8.3.x than in prior versions. + The fix restores 8.1 behavior for such cases. +

  • Fix mis-expansion of rule queries when a sub-SELECT appears + in a function call in FROM, a multi-row VALUES + list, or a RETURNING list (Tom) +

    The usual symptom of this problem is an "unrecognized node type" + error. +

  • Fix memory leak during rescan of a hashed aggregation plan (Neil) +

  • Ensure an error is reported when a newly-defined PL/pgSQL trigger + function is invoked as a normal function (Tom) +

  • Prevent possible collision of relfilenode numbers + when moving a table to another tablespace with ALTER SET + TABLESPACE (Heikki) +

    The command tried to re-use the existing filename, instead of + picking one that is known unused in the destination directory. +

  • Fix incorrect tsearch2 headline generation when single query + item matches first word of text (Sushant Sinha) +

  • Fix improper display of fractional seconds in interval values when + using a non-ISO datestyle in an --enable-integer-datetimes + build (Ron Mayer) +

  • Ensure SPI_getvalue and SPI_getbinval + behave correctly when the passed tuple and tuple descriptor have + different numbers of columns (Tom) +

    This situation is normal when a table has had columns added or removed, + but these two functions didn't handle it properly. + The only likely consequence is an incorrect error indication. +

  • Fix ecpg's parsing of CREATE ROLE (Michael) +

  • Fix recent breakage of pg_ctl restart (Tom) +

  • Ensure pg_control is opened in binary mode + (Itagaki Takahiro) +

    pg_controldata and pg_resetxlog + did this incorrectly, and so could fail on Windows. +

  • Update time zone data files to tzdata release 2008i (for + DST law changes in Argentina, Brazil, Mauritius, Syria) +


PrevHomeNext
Release 8.2.12UpRelease 8.2.10
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-2-12.html b/doc/src/sgml/html/release-8-2-12.html new file mode 100644 index 000000000..cd8ca69a6 --- /dev/null +++ b/doc/src/sgml/html/release-8-2-12.html @@ -0,0 +1,385 @@ + +Release 8.2.12

E.74. Release 8.2.12

Release Date: 2009-02-02

This release contains a variety of fixes from 8.2.11. + For information about new features in the 8.2 major release, see + Section E.86. +

E.74.1. Migration to Version 8.2.12

A dump/restore is not required for those running 8.2.X. + However, if you are upgrading from a version earlier than 8.2.11, + see the release notes for 8.2.11. +

E.74.2. Changes

  • Improve handling of URLs in headline() function (Teodor) +

  • Improve handling of overlength headlines in headline() + function (Teodor) +

  • Prevent possible Assert failure or misconversion if an encoding + conversion is created with the wrong conversion function for the + specified pair of encodings (Tom, Heikki) +

  • Fix possible Assert failure if a statement executed in PL/pgSQL is + rewritten into another kind of statement, for example if an + INSERT is rewritten into an UPDATE (Heikki) +

  • Ensure that a snapshot is available to datatype input functions (Tom) +

    This primarily affects domains that are declared with CHECK + constraints involving user-defined stable or immutable functions. Such + functions typically fail if no snapshot has been set. +

  • Make it safer for SPI-using functions to be used within datatype I/O; + in particular, to be used in domain check constraints (Tom) +

  • Avoid unnecessary locking of small tables in VACUUM + (Heikki) +

  • Fix a problem that made UPDATE RETURNING tableoid + return zero instead of the correct OID (Tom) +

  • Fix planner misestimation of selectivity when transitive equality + is applied to an outer-join clause (Tom) +

    This could result in bad plans for queries like + ... from a left join b on a.a1 = b.b1 where a.a1 = 42 ... +

  • Improve optimizer's handling of long IN lists (Tom) +

    This change avoids wasting large amounts of time on such lists + when constraint exclusion is enabled. +

  • Ensure that the contents of a holdable cursor don't depend on the + contents of TOAST tables (Tom) +

    Previously, large field values in a cursor result might be represented + as TOAST pointers, which would fail if the referenced table got dropped + before the cursor is read, or if the large value is deleted and then + vacuumed away. This cannot happen with an ordinary cursor, + but it could with a cursor that is held past its creating transaction. +

  • Fix memory leak when a set-returning function is terminated without + reading its whole result (Tom) +

  • Fix contrib/dblink's + dblink_get_result(text,bool) function (Joe) +

  • Fix possible garbage output from contrib/sslinfo functions + (Tom) +

  • Fix configure script to properly report failure when + unable to obtain linkage information for PL/Perl (Andrew) +

  • Make all documentation reference pgsql-bugs and/or + pgsql-hackers as appropriate, instead of the + now-decommissioned pgsql-ports and pgsql-patches + mailing lists (Tom) +

  • Update time zone data files to tzdata release 2009a (for + Kathmandu and historical DST corrections in Switzerland, Cuba) +


PrevHomeNext
Release 8.2.13UpRelease 8.2.11
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-2-13.html b/doc/src/sgml/html/release-8-2-13.html new file mode 100644 index 000000000..7e6d3fe06 --- /dev/null +++ b/doc/src/sgml/html/release-8-2-13.html @@ -0,0 +1,393 @@ + +Release 8.2.13

E.73. Release 8.2.13

Release Date: 2009-03-16

This release contains a variety of fixes from 8.2.12. + For information about new features in the 8.2 major release, see + Section E.86. +

E.73.1. Migration to Version 8.2.13

A dump/restore is not required for those running 8.2.X. + However, if you are upgrading from a version earlier than 8.2.11, + see the release notes for 8.2.11. +

E.73.2. Changes

  • Prevent error recursion crashes when encoding conversion fails (Tom) +

    This change extends fixes made in the last two minor releases for + related failure scenarios. The previous fixes were narrowly tailored + for the original problem reports, but we have now recognized that + any error thrown by an encoding conversion function could + potentially lead to infinite recursion while trying to report the + error. The solution therefore is to disable translation and encoding + conversion and report the plain-ASCII form of any error message, + if we find we have gotten into a recursive error reporting situation. + (CVE-2009-0922) +

  • Disallow CREATE CONVERSION with the wrong encodings + for the specified conversion function (Heikki) +

    This prevents one possible scenario for encoding conversion failure. + The previous change is a backstop to guard against other kinds of + failures in the same area. +

  • Fix core dump when to_char() is given format codes that + are inappropriate for the type of the data argument (Tom) +

  • Fix possible failure in contrib/tsearch2 when C locale is + used with a multi-byte encoding (Teodor) +

    Crashes were possible on platforms where wchar_t is narrower + than int; Windows in particular. +

  • Fix extreme inefficiency in contrib/tsearch2 parser's + handling of an email-like string containing multiple @ + characters (Heikki) +

  • Fix decompilation of CASE WHEN with an implicit coercion + (Tom) +

    This mistake could lead to Assert failures in an Assert-enabled build, + or an "unexpected CASE WHEN clause" error message in other + cases, when trying to examine or dump a view. +

  • Fix possible misassignment of the owner of a TOAST table's rowtype (Tom) +

    If CLUSTER or a rewriting variant of ALTER TABLE + were executed by someone other than the table owner, the + pg_type entry for the table's TOAST table would end up + marked as owned by that someone. This caused no immediate problems, + since the permissions on the TOAST rowtype aren't examined by any + ordinary database operation. However, it could lead to unexpected + failures if one later tried to drop the role that issued the command + (in 8.1 or 8.2), or "owner of data type appears to be invalid" + warnings from pg_dump after having done so (in 8.3). +

  • Fix PL/pgSQL to not treat INTO after INSERT as + an INTO-variables clause anywhere in the string, not only at the start; + in particular, don't fail for INSERT INTO within + CREATE RULE (Tom) +

  • Clean up PL/pgSQL error status variables fully at block exit + (Ashesh Vashi and Dave Page) +

    This is not a problem for PL/pgSQL itself, but the omission could cause + the PL/pgSQL Debugger to crash while examining the state of a function. +

  • Retry failed calls to CallNamedPipe() on Windows + (Steve Marshall, Magnus) +

    It appears that this function can sometimes fail transiently; + we previously treated any failure as a hard error, which could + confuse LISTEN/NOTIFY as well as other + operations. +

  • Add MUST (Mauritius Island Summer Time) to the default list + of known timezone abbreviations (Xavier Bugaud) +


PrevHomeNext
Release 8.2.14UpRelease 8.2.12
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-2-14.html b/doc/src/sgml/html/release-8-2-14.html new file mode 100644 index 000000000..7f6b67eae --- /dev/null +++ b/doc/src/sgml/html/release-8-2-14.html @@ -0,0 +1,462 @@ + +Release 8.2.14

E.72. Release 8.2.14

Release Date: 2009-09-09

This release contains a variety of fixes from 8.2.13. + For information about new features in the 8.2 major release, see + Section E.86. +

E.72.1. Migration to Version 8.2.14

A dump/restore is not required for those running 8.2.X. + However, if you have any hash indexes on interval columns, + you must REINDEX them after updating to 8.2.14. + Also, if you are upgrading from a version earlier than 8.2.11, + see the release notes for 8.2.11. +

E.72.2. Changes

  • Force WAL segment switch during pg_start_backup() + (Heikki) +

    This avoids corner cases that could render a base backup unusable. +

  • Disallow RESET ROLE and RESET SESSION + AUTHORIZATION inside security-definer functions (Tom, Heikki) +

    This covers a case that was missed in the previous patch that + disallowed SET ROLE and SET SESSION + AUTHORIZATION inside security-definer functions. + (See CVE-2007-6600) +

  • Make LOAD of an already-loaded loadable module + into a no-op (Tom) +

    Formerly, LOAD would attempt to unload and re-load the + module, but this is unsafe and not all that useful. +

  • Disallow empty passwords during LDAP authentication (Magnus) +

  • Fix handling of sub-SELECTs appearing in the arguments of + an outer-level aggregate function (Tom) +

  • Fix bugs associated with fetching a whole-row value from the + output of a Sort or Materialize plan node (Tom) +

  • Revert planner change that disabled partial-index and constraint + exclusion optimizations when there were more than 100 clauses in + an AND or OR list (Tom) +

  • Fix hash calculation for data type interval (Tom) +

    This corrects wrong results for hash joins on interval values. + It also changes the contents of hash indexes on interval columns. + If you have any such indexes, you must REINDEX them + after updating. +

  • Treat to_char(..., 'TH') as an uppercase ordinal + suffix with 'HH'/'HH12' (Heikki) +

    It was previously handled as 'th' (lowercase). +

  • Fix overflow for INTERVAL 'x ms' + when x is more than 2 million and integer + datetimes are in use (Alex Hunsaker) +

  • Fix calculation of distance between a point and a line segment (Tom) +

    This led to incorrect results from a number of geometric operators. +

  • Fix money data type to work in locales where currency + amounts have no fractional digits, e.g. Japan (Itagaki Takahiro) +

  • Properly round datetime input like + 00:12:57.9999999999999999999999999999 (Tom) +

  • Fix poor choice of page split point in GiST R-tree operator classes + (Teodor) +

  • Avoid performance degradation in bulk inserts into GIN indexes + when the input values are (nearly) in sorted order (Tom) +

  • Correctly enforce NOT NULL domain constraints in some contexts in + PL/pgSQL (Tom) +

  • Fix portability issues in plperl initialization (Andrew Dunstan) +

  • Fix pg_ctl to not go into an infinite loop if + postgresql.conf is empty (Jeff Davis) +

  • Make contrib/hstore throw an error when a key or + value is too long to fit in its data structure, rather than + silently truncating it (Andrew Gierth) +

  • Fix contrib/xml2's xslt_process() to + properly handle the maximum number of parameters (twenty) (Tom) +

  • Improve robustness of libpq's code to recover + from errors during COPY FROM STDIN (Tom) +

  • Avoid including conflicting readline and editline header files + when both libraries are installed (Zdenek Kotala) +

  • Update time zone data files to tzdata release 2009l + for DST law changes in Bangladesh, Egypt, Jordan, Pakistan, + Argentina/San_Luis, Cuba, Jordan (historical correction only), + Mauritius, Morocco, Palestine, Syria, Tunisia. +


PrevHomeNext
Release 8.2.15UpRelease 8.2.13
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-2-15.html b/doc/src/sgml/html/release-8-2-15.html new file mode 100644 index 000000000..52c62bb6f --- /dev/null +++ b/doc/src/sgml/html/release-8-2-15.html @@ -0,0 +1,433 @@ + +Release 8.2.15

E.71. Release 8.2.15

Release Date: 2009-12-14

This release contains a variety of fixes from 8.2.14. + For information about new features in the 8.2 major release, see + Section E.86. +

E.71.1. Migration to Version 8.2.15

A dump/restore is not required for those running 8.2.X. + However, if you are upgrading from a version earlier than 8.2.14, + see the release notes for 8.2.14. +

E.71.2. Changes

  • Protect against indirect security threats caused by index functions + changing session-local state (Gurjeet Singh, Tom) +

    This change prevents allegedly-immutable index functions from possibly + subverting a superuser's session (CVE-2009-4136). +

  • Reject SSL certificates containing an embedded null byte in the common + name (CN) field (Magnus) +

    This prevents unintended matching of a certificate to a server or client + name during SSL validation (CVE-2009-4034). +

  • Fix possible crash during backend-startup-time cache initialization (Tom) +

  • Prevent signals from interrupting VACUUM at unsafe times + (Alvaro) +

    This fix prevents a PANIC if a VACUUM FULL is canceled + after it's already committed its tuple movements, as well as transient + errors if a plain VACUUM is interrupted after having + truncated the table. +

  • Fix possible crash due to integer overflow in hash table size + calculation (Tom) +

    This could occur with extremely large planner estimates for the size of + a hashjoin's result. +

  • Fix very rare crash in inet/cidr comparisons (Chris + Mikkelson) +

  • Ensure that shared tuple-level locks held by prepared transactions are + not ignored (Heikki) +

  • Fix premature drop of temporary files used for a cursor that is accessed + within a subtransaction (Heikki) +

  • Fix incorrect logic for GiST index page splits, when the split depends + on a non-first column of the index (Paul Ramsey) +

  • Don't error out if recycling or removing an old WAL file fails at the + end of checkpoint (Heikki) +

    It's better to treat the problem as non-fatal and allow the checkpoint + to complete. Future checkpoints will retry the removal. Such problems + are not expected in normal operation, but have been seen to be + caused by misdesigned Windows anti-virus and backup software. +

  • Ensure WAL files aren't repeatedly archived on Windows (Heikki) +

    This is another symptom that could happen if some other process + interfered with deletion of a no-longer-needed file. +

  • Fix PAM password processing to be more robust (Tom) +

    The previous code is known to fail with the combination of the Linux + pam_krb5 PAM module with Microsoft Active Directory as the + domain controller. It might have problems elsewhere too, since it was + making unjustified assumptions about what arguments the PAM stack would + pass to it. +

  • Fix processing of ownership dependencies during CREATE OR + REPLACE FUNCTION (Tom) +

  • Fix bug with calling plperl from plperlu or vice + versa (Tom) +

    An error exit from the inner function could result in crashes due to + failure to re-select the correct Perl interpreter for the outer function. +

  • Fix session-lifespan memory leak when a PL/Perl function is redefined + (Tom) +

  • Ensure that Perl arrays are properly converted to + PostgreSQL arrays when returned by a set-returning + PL/Perl function (Andrew Dunstan, Abhijit Menon-Sen) +

    This worked correctly already for non-set-returning functions. +

  • Fix rare crash in exception processing in PL/Python (Peter) +

  • Ensure psql's flex module is compiled with the correct + system header definitions (Tom) +

    This fixes build failures on platforms where + --enable-largefile causes incompatible changes in the + generated code. +

  • Make the postmaster ignore any application_name parameter in + connection request packets, to improve compatibility with future libpq + versions (Tom) +

  • Update the timezone abbreviation files to match current reality (Joachim + Wieland) +

    This includes adding IDT and SGT to the default + timezone abbreviation set. +

  • Update time zone data files to tzdata release 2009s + for DST law changes in Antarctica, Argentina, Bangladesh, Fiji, + Novokuznetsk, Pakistan, Palestine, Samoa, Syria; also historical + corrections for Hong Kong. +


PrevHomeNext
Release 8.2.16UpRelease 8.2.14
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-2-16.html b/doc/src/sgml/html/release-8-2-16.html new file mode 100644 index 000000000..8807d580c --- /dev/null +++ b/doc/src/sgml/html/release-8-2-16.html @@ -0,0 +1,503 @@ + +Release 8.2.16

E.70. Release 8.2.16

Release Date: 2010-03-15

This release contains a variety of fixes from 8.2.15. + For information about new features in the 8.2 major release, see + Section E.86. +

E.70.1. Migration to Version 8.2.16

A dump/restore is not required for those running 8.2.X. + However, if you are upgrading from a version earlier than 8.2.14, + see the release notes for 8.2.14. +

E.70.2. Changes

  • Add new configuration parameter ssl_renegotiation_limit to + control how often we do session key renegotiation for an SSL connection + (Magnus) +

    This can be set to zero to disable renegotiation completely, which may + be required if a broken SSL library is used. In particular, some + vendors are shipping stopgap patches for CVE-2009-3555 that cause + renegotiation attempts to fail. +

  • Fix possible deadlock during backend startup (Tom) +

  • Fix possible crashes due to not handling errors during relcache reload + cleanly (Tom) +

  • Fix possible crashes when trying to recover from a failure in + subtransaction start (Tom) +

  • Fix server memory leak associated with use of savepoints and a client + encoding different from server's encoding (Tom) +

  • Fix incorrect WAL data emitted during end-of-recovery cleanup of a GIST + index page split (Yoichi Hirai) +

    This would result in index corruption, or even more likely an error + during WAL replay, if we were unlucky enough to crash during + end-of-recovery cleanup after having completed an incomplete GIST + insertion. +

  • Make substring() for bit types treat any negative + length as meaning "all the rest of the string" (Tom) +

    The previous coding treated only -1 that way, and would produce an + invalid result value for other negative values, possibly leading to + a crash (CVE-2010-0442). +

  • Fix integer-to-bit-string conversions to handle the first fractional + byte correctly when the output bit width is wider than the given + integer by something other than a multiple of 8 bits (Tom) +

  • Fix some cases of pathologically slow regular expression matching (Tom) +

  • Fix the STOP WAL LOCATION entry in backup history files to + report the next WAL segment's name when the end location is exactly at a + segment boundary (Itagaki Takahiro) +

  • Fix some more cases of temporary-file leakage (Heikki) +

    This corrects a problem introduced in the previous minor release. + One case that failed is when a plpgsql function returning set is + called within another function's exception handler. +

  • Improve constraint exclusion processing of boolean-variable cases, + in particular make it possible to exclude a partition that has a + "bool_column = false" constraint (Tom) +

  • When reading pg_hba.conf and related files, do not treat + @something as a file inclusion request if the @ + appears inside quote marks; also, never treat @ by itself + as a file inclusion request (Tom) +

    This prevents erratic behavior if a role or database name starts with + @. If you need to include a file whose path name + contains spaces, you can still do so, but you must write + @"/path to/file" rather than putting the quotes around + the whole construct. +

  • Prevent infinite loop on some platforms if a directory is named as + an inclusion target in pg_hba.conf and related files + (Tom) +

  • Fix possible infinite loop if SSL_read or + SSL_write fails without setting errno (Tom) +

    This is reportedly possible with some Windows versions of + openssl. +

  • Fix psql's numericlocale option to not + format strings it shouldn't in latex and troff output formats (Heikki) +

  • Make psql return the correct exit status (3) when + ON_ERROR_STOP and --single-transaction are + both specified and an error occurs during the implied COMMIT + (Bruce) +

  • Fix plpgsql failure in one case where a composite column is set to NULL + (Tom) +

  • Fix possible failure when calling PL/Perl functions from PL/PerlU + or vice versa (Tim Bunce) +

  • Add volatile markings in PL/Python to avoid possible + compiler-specific misbehavior (Zdenek Kotala) +

  • Ensure PL/Tcl initializes the Tcl interpreter fully (Tom) +

    The only known symptom of this oversight is that the Tcl + clock command misbehaves if using Tcl 8.5 or later. +

  • Prevent crash in contrib/dblink when too many key + columns are specified to a dblink_build_sql_* function + (Rushabh Lathia, Joe Conway) +

  • Fix assorted crashes in contrib/xml2 caused by sloppy + memory management (Tom) +

  • Make building of contrib/xml2 more robust on Windows + (Andrew) +

  • Fix race condition in Windows signal handling (Radu Ilie) +

    One known symptom of this bug is that rows in pg_listener + could be dropped under heavy load. +

  • Update time zone data files to tzdata release 2010e + for DST law changes in Bangladesh, Chile, Fiji, Mexico, Paraguay, Samoa. +


PrevHomeNext
Release 8.2.17UpRelease 8.2.15
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-2-17.html b/doc/src/sgml/html/release-8-2-17.html new file mode 100644 index 000000000..5276dbedb --- /dev/null +++ b/doc/src/sgml/html/release-8-2-17.html @@ -0,0 +1,432 @@ + +Release 8.2.17

E.69. Release 8.2.17

Release Date: 2010-05-17

This release contains a variety of fixes from 8.2.16. + For information about new features in the 8.2 major release, see + Section E.86. +

E.69.1. Migration to Version 8.2.17

A dump/restore is not required for those running 8.2.X. + However, if you are upgrading from a version earlier than 8.2.14, + see the release notes for 8.2.14. +

E.69.2. Changes

  • Enforce restrictions in plperl using an opmask applied to + the whole interpreter, instead of using Safe.pm + (Tim Bunce, Andrew Dunstan) +

    Recent developments have convinced us that Safe.pm is too + insecure to rely on for making plperl trustable. This + change removes use of Safe.pm altogether, in favor of using + a separate interpreter with an opcode mask that is always applied. + Pleasant side effects of the change include that it is now possible to + use Perl's strict pragma in a natural way in + plperl, and that Perl's $a and $b + variables work as expected in sort routines, and that function + compilation is significantly faster. (CVE-2010-1169) +

  • Prevent PL/Tcl from executing untrustworthy code from + pltcl_modules (Tom) +

    PL/Tcl's feature for autoloading Tcl code from a database table + could be exploited for trojan-horse attacks, because there was no + restriction on who could create or insert into that table. This change + disables the feature unless pltcl_modules is owned by a + superuser. (However, the permissions on the table are not checked, so + installations that really need a less-than-secure modules table can + still grant suitable privileges to trusted non-superusers.) Also, + prevent loading code into the unrestricted "normal" Tcl + interpreter unless we are really going to execute a pltclu + function. (CVE-2010-1170) +

  • Fix possible crash if a cache reset message is received during + rebuild of a relcache entry (Heikki) +

    This error was introduced in 8.2.16 while fixing a related failure. +

  • Do not allow an unprivileged user to reset superuser-only parameter + settings (Alvaro) +

    Previously, if an unprivileged user ran ALTER USER ... RESET + ALL for himself, or ALTER DATABASE ... RESET ALL for + a database he owns, this would remove all special parameter settings + for the user or database, even ones that are only supposed to be + changeable by a superuser. Now, the ALTER will only + remove the parameters that the user has permission to change. +

  • Avoid possible crash during backend shutdown if shutdown occurs + when a CONTEXT addition would be made to log entries (Tom) +

    In some cases the context-printing function would fail because the + current transaction had already been rolled back when it came time + to print a log message. +

  • Update pl/perl's ppport.h for modern Perl versions + (Andrew) +

  • Fix assorted memory leaks in pl/python (Andreas Freund, Tom) +

  • Prevent infinite recursion in psql when expanding + a variable that refers to itself (Tom) +

  • Fix psql's \copy to not add spaces around + a dot within \copy (select ...) (Tom) +

    Addition of spaces around the decimal point in a numeric literal would + result in a syntax error. +

  • Ensure that contrib/pgstattuple functions respond to cancel + interrupts promptly (Tatsuhito Kasahara) +

  • Make server startup deal properly with the case that + shmget() returns EINVAL for an existing + shared memory segment (Tom) +

    This behavior has been observed on BSD-derived kernels including OS X. + It resulted in an entirely-misleading startup failure complaining that + the shared memory request size was too large. +

  • Avoid possible crashes in syslogger process on Windows (Heikki) +

  • Deal more robustly with incomplete time zone information in the + Windows registry (Magnus) +

  • Update the set of known Windows time zone names (Magnus) +

  • Update time zone data files to tzdata release 2010j + for DST law changes in Argentina, Australian Antarctic, Bangladesh, + Mexico, Morocco, Pakistan, Palestine, Russia, Syria, Tunisia; + also historical corrections for Taiwan. +

    Also, add PKST (Pakistan Summer Time) to the default set of + timezone abbreviations. +


PrevHomeNext
Release 8.2.18UpRelease 8.2.16
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-2-18.html b/doc/src/sgml/html/release-8-2-18.html new file mode 100644 index 000000000..887b8c7ba --- /dev/null +++ b/doc/src/sgml/html/release-8-2-18.html @@ -0,0 +1,498 @@ + +Release 8.2.18

E.68. Release 8.2.18

Release Date: 2010-10-04

This release contains a variety of fixes from 8.2.17. + For information about new features in the 8.2 major release, see + Section E.86. +

E.68.1. Migration to Version 8.2.18

A dump/restore is not required for those running 8.2.X. + However, if you are upgrading from a version earlier than 8.2.14, + see the release notes for 8.2.14. +

E.68.2. Changes

  • Use a separate interpreter for each calling SQL userid in PL/Perl and + PL/Tcl (Tom Lane) +

    This change prevents security problems that can be caused by subverting + Perl or Tcl code that will be executed later in the same session under + another SQL user identity (for example, within a SECURITY + DEFINER function). Most scripting languages offer numerous ways that + that might be done, such as redefining standard functions or operators + called by the target function. Without this change, any SQL user with + Perl or Tcl language usage rights can do essentially anything with the + SQL privileges of the target function's owner. +

    The cost of this change is that intentional communication among Perl + and Tcl functions becomes more difficult. To provide an escape hatch, + PL/PerlU and PL/TclU functions continue to use only one interpreter + per session. This is not considered a security issue since all such + functions execute at the trust level of a database superuser already. +

    It is likely that third-party procedural languages that claim to offer + trusted execution have similar security issues. We advise contacting + the authors of any PL you are depending on for security-critical + purposes. +

    Our thanks to Tim Bunce for pointing out this issue (CVE-2010-3433). +

  • Prevent possible crashes in pg_get_expr() by disallowing + it from being called with an argument that is not one of the system + catalog columns it's intended to be used with + (Heikki Linnakangas, Tom Lane) +

  • Fix Windows shared-memory allocation code + (Tsutomu Yamada, Magnus Hagander) +

    This bug led to the often-reported "could not reattach to shared + memory" error message. This is a back-patch of a fix that was + applied to newer branches some time ago. +

  • Treat exit code 128 (ERROR_WAIT_NO_CHILDREN) as non-fatal on + Windows (Magnus Hagander) +

    Under high load, Windows processes will sometimes fail at startup with + this error code. Formerly the postmaster treated this as a panic + condition and restarted the whole database, but that seems to be + an overreaction. +

  • Fix possible duplicate scans of UNION ALL member relations + (Tom Lane) +

  • Fix "cannot handle unplanned sub-select" error (Tom Lane) +

    This occurred when a sub-select contains a join alias reference that + expands into an expression containing another sub-select. +

  • Reduce PANIC to ERROR in some occasionally-reported btree failure cases, + and provide additional detail in the resulting error messages + (Tom Lane) +

    This should improve the system's robustness with corrupted indexes. +

  • Prevent show_session_authorization() from crashing within autovacuum + processes (Tom Lane) +

  • Defend against functions returning setof record where not all the + returned rows are actually of the same rowtype (Tom Lane) +

  • Fix possible failure when hashing a pass-by-reference function result + (Tao Ma, Tom Lane) +

  • Take care to fsync the contents of lockfiles (both + postmaster.pid and the socket lockfile) while writing them + (Tom Lane) +

    This omission could result in corrupted lockfile contents if the + machine crashes shortly after postmaster start. That could in turn + prevent subsequent attempts to start the postmaster from succeeding, + until the lockfile is manually removed. +

  • Avoid recursion while assigning XIDs to heavily-nested + subtransactions (Andres Freund, Robert Haas) +

    The original coding could result in a crash if there was limited + stack space. +

  • Fix log_line_prefix's %i escape, + which could produce junk early in backend startup (Tom Lane) +

  • Fix possible data corruption in ALTER TABLE ... SET + TABLESPACE when archiving is enabled (Jeff Davis) +

  • Allow CREATE DATABASE and ALTER DATABASE ... SET + TABLESPACE to be interrupted by query-cancel (Guillaume Lelarge) +

  • In PL/Python, defend against null pointer results from + PyCObject_AsVoidPtr and PyCObject_FromVoidPtr + (Peter Eisentraut) +

  • Improve contrib/dblink's handling of tables containing + dropped columns (Tom Lane) +

  • Fix connection leak after "duplicate connection name" + errors in contrib/dblink (Itagaki Takahiro) +

  • Fix contrib/dblink to handle connection names longer than + 62 bytes correctly (Itagaki Takahiro) +

  • Add hstore(text, text) + function to contrib/hstore (Robert Haas) +

    This function is the recommended substitute for the now-deprecated + => operator. It was back-patched so that future-proofed + code can be used with older server versions. Note that the patch will + be effective only after contrib/hstore is installed or + reinstalled in a particular database. Users might prefer to execute + the CREATE FUNCTION command by hand, instead. +

  • Update build infrastructure and documentation to reflect the source code + repository's move from CVS to Git (Magnus Hagander and others) +

  • Update time zone data files to tzdata release 2010l + for DST law changes in Egypt and Palestine; also historical corrections + for Finland. +

    This change also adds new names for two Micronesian timezones: + Pacific/Chuuk is now preferred over Pacific/Truk (and the preferred + abbreviation is CHUT not TRUT) and Pacific/Pohnpei is preferred over + Pacific/Ponape. +

  • Make Windows' "N. Central Asia Standard Time" timezone map to + Asia/Novosibirsk, not Asia/Almaty (Magnus Hagander) +

    Microsoft changed the DST behavior of this zone in the timezone update + from KB976098. Asia/Novosibirsk is a better match to its new behavior. +


PrevHomeNext
Release 8.2.19UpRelease 8.2.17
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-2-19.html b/doc/src/sgml/html/release-8-2-19.html new file mode 100644 index 000000000..ee8d3fc94 --- /dev/null +++ b/doc/src/sgml/html/release-8-2-19.html @@ -0,0 +1,496 @@ + +Release 8.2.19

E.67. Release 8.2.19

Release Date: 2010-12-16

This release contains a variety of fixes from 8.2.18. + For information about new features in the 8.2 major release, see + Section E.86. +

E.67.1. Migration to Version 8.2.19

A dump/restore is not required for those running 8.2.X. + However, if you are upgrading from a version earlier than 8.2.14, + see the release notes for 8.2.14. +

E.67.2. Changes

  • Force the default + wal_sync_method + to be fdatasync on Linux (Tom Lane, Marti Raudsepp) +

    The default on Linux has actually been fdatasync for many + years, but recent kernel changes caused PostgreSQL to + choose open_datasync instead. This choice did not result + in any performance improvement, and caused outright failures on + certain filesystems, notably ext4 with the + data=journal mount option. +

  • Fix assorted bugs in WAL replay logic for GIN indexes (Tom Lane) +

    This could result in "bad buffer id: 0" failures or + corruption of index contents during replication. +

  • Fix recovery from base backup when the starting checkpoint WAL record + is not in the same WAL segment as its redo point (Jeff Davis) +

  • Add support for detecting register-stack overrun on IA64 + (Tom Lane) +

    The IA64 architecture has two hardware stacks. Full + prevention of stack-overrun failures requires checking both. +

  • Add a check for stack overflow in copyObject() (Tom Lane) +

    Certain code paths could crash due to stack overflow given a + sufficiently complex query. +

  • Fix detection of page splits in temporary GiST indexes (Heikki + Linnakangas) +

    It is possible to have a "concurrent" page split in a + temporary index, if for example there is an open cursor scanning the + index when an insertion is done. GiST failed to detect this case and + hence could deliver wrong results when execution of the cursor + continued. +

  • Avoid memory leakage while ANALYZE'ing complex index + expressions (Tom Lane) +

  • Ensure an index that uses a whole-row Var still depends on its table + (Tom Lane) +

    An index declared like create index i on t (foo(t.*)) + would not automatically get dropped when its table was dropped. +

  • Do not "inline" a SQL function with multiple OUT + parameters (Tom Lane) +

    This avoids a possible crash due to loss of information about the + expected result rowtype. +

  • Behave correctly if ORDER BY, LIMIT, + FOR UPDATE, or WITH is attached to the + VALUES part of INSERT ... VALUES (Tom Lane) +

  • Fix constant-folding of COALESCE() expressions (Tom Lane) +

    The planner would sometimes attempt to evaluate sub-expressions that + in fact could never be reached, possibly leading to unexpected errors. +

  • Add print functionality for InhRelation nodes (Tom Lane) +

    This avoids a failure when debug_print_parse is enabled + and certain types of query are executed. +

  • Fix incorrect calculation of distance from a point to a horizontal + line segment (Tom Lane) +

    This bug affected several different geometric distance-measurement + operators. +

  • Fix PL/pgSQL's handling of "simple" + expressions to not fail in recursion or error-recovery cases (Tom Lane) +

  • Fix PL/Python's handling of set-returning functions + (Jan Urbanski) +

    Attempts to call SPI functions within the iterator generating a set + result would fail. +

  • Fix bug in contrib/cube's GiST picksplit algorithm + (Alexander Korotkov) +

    This could result in considerable inefficiency, though not actually + incorrect answers, in a GiST index on a cube column. + If you have such an index, consider REINDEXing it after + installing this update. +

  • Don't emit "identifier will be truncated" notices in + contrib/dblink except when creating new connections + (Itagaki Takahiro) +

  • Fix potential coredump on missing public key in + contrib/pgcrypto (Marti Raudsepp) +

  • Fix memory leak in contrib/xml2's XPath query functions + (Tom Lane) +

  • Update time zone data files to tzdata release 2010o + for DST law changes in Fiji and Samoa; + also historical corrections for Hong Kong. +


PrevHomeNext
Release 8.2.20UpRelease 8.2.18
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-2-2.html b/doc/src/sgml/html/release-8-2-2.html new file mode 100644 index 000000000..f9378b458 --- /dev/null +++ b/doc/src/sgml/html/release-8-2-2.html @@ -0,0 +1,348 @@ + +Release 8.2.2

E.84. Release 8.2.2

Release Date: 2007-02-05

This release contains a variety of fixes from 8.2.1, including + a security fix. + For information about new features in the 8.2 major release, see + Section E.86. +

E.84.1. Migration to Version 8.2.2

A dump/restore is not required for those running 8.2.X. +

E.84.2. Changes

  • Remove security vulnerabilities that allowed connected users + to read backend memory (Tom) +

    The vulnerabilities involve suppressing the normal check that a SQL + function returns the data type it's declared to, and changing the + data type of a table column (CVE-2007-0555, CVE-2007-0556). These + errors can easily be exploited to cause a backend crash, and in + principle might be used to read database content that the user + should not be able to access. +

  • Fix not-so-rare-anymore bug wherein btree index page splits could fail + due to choosing an infeasible split point (Heikki Linnakangas) +

  • Fix Borland C compile scripts (L Bayuk) +

  • Properly handle to_char('CC') for years ending in + 00 (Tom) +

    Year 2000 is in the twentieth century, not the twenty-first. +

  • /contrib/tsearch2 localization improvements (Tatsuo, Teodor) +

  • Fix incorrect permission check in + information_schema.key_column_usage view (Tom) +

    The symptom is "relation with OID nnnnn does not exist" errors. + To get this fix without using initdb, use CREATE OR + REPLACE VIEW to install the corrected definition found in + share/information_schema.sql. Note you will need to do + this in each database. +

  • Improve VACUUM performance for databases with many tables (Tom) +

  • Fix for rare Assert() crash triggered by UNION (Tom) +

  • Fix potentially incorrect results from index searches using + ROW inequality conditions (Tom) +

  • Tighten security of multi-byte character processing for UTF8 sequences + over three bytes long (Tom) +

  • Fix bogus "permission denied" failures occurring on Windows + due to attempts to fsync already-deleted files (Magnus, Tom) +

  • Fix bug that could cause the statistics collector + to hang on Windows (Magnus) +

    This would in turn lead to autovacuum not working. +

  • Fix possible crashes when an already-in-use PL/pgSQL function is + updated (Tom) +

  • Improve PL/pgSQL handling of domain types (Sergiy Vyshnevetskiy, Tom) +

  • Fix possible errors in processing PL/pgSQL exception blocks (Tom) +


PrevHomeNext
Release 8.2.3UpRelease 8.2.1
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-2-20.html b/doc/src/sgml/html/release-8-2-20.html new file mode 100644 index 000000000..634ef3210 --- /dev/null +++ b/doc/src/sgml/html/release-8-2-20.html @@ -0,0 +1,360 @@ + +Release 8.2.20

E.66. Release 8.2.20

Release Date: 2011-01-31

This release contains a variety of fixes from 8.2.19. + For information about new features in the 8.2 major release, see + Section E.86. +

E.66.1. Migration to Version 8.2.20

A dump/restore is not required for those running 8.2.X. + However, if you are upgrading from a version earlier than 8.2.14, + see the release notes for 8.2.14. +

E.66.2. Changes

  • Avoid failures when EXPLAIN tries to display a simple-form + CASE expression (Tom Lane) +

    If the CASE's test expression was a constant, the planner + could simplify the CASE into a form that confused the + expression-display code, resulting in "unexpected CASE WHEN + clause" errors. +

  • Fix assignment to an array slice that is before the existing range + of subscripts (Tom Lane) +

    If there was a gap between the newly added subscripts and the first + pre-existing subscript, the code miscalculated how many entries needed + to be copied from the old array's null bitmap, potentially leading to + data corruption or crash. +

  • Avoid unexpected conversion overflow in planner for very distant date + values (Tom Lane) +

    The date type supports a wider range of dates than can be + represented by the timestamp types, but the planner assumed it + could always convert a date to timestamp with impunity. +

  • Fix pg_restore's text output for large objects (BLOBs) + when standard_conforming_strings is on (Tom Lane) +

    Although restoring directly to a database worked correctly, string + escaping was incorrect if pg_restore was asked for + SQL text output and standard_conforming_strings had been + enabled in the source database. +

  • Fix erroneous parsing of tsquery values containing + ... & !(subexpression) | ... (Tom Lane) +

    Queries containing this combination of operators were not executed + correctly. The same error existed in contrib/intarray's + query_int type and contrib/ltree's + ltxtquery type. +

  • Fix buffer overrun in contrib/intarray's input function + for the query_int type (Apple) +

    This bug is a security risk since the function's return address could + be overwritten. Thanks to Apple Inc's security team for reporting this + issue and supplying the fix. (CVE-2010-4015) +

  • Fix bug in contrib/seg's GiST picksplit algorithm + (Alexander Korotkov) +

    This could result in considerable inefficiency, though not actually + incorrect answers, in a GiST index on a seg column. + If you have such an index, consider REINDEXing it after + installing this update. (This is identical to the bug that was fixed in + contrib/cube in the previous update.) +


PrevHomeNext
Release 8.2.21UpRelease 8.2.19
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-2-21.html b/doc/src/sgml/html/release-8-2-21.html new file mode 100644 index 000000000..bab452609 --- /dev/null +++ b/doc/src/sgml/html/release-8-2-21.html @@ -0,0 +1,318 @@ + +Release 8.2.21

E.65. Release 8.2.21

Release Date: 2011-04-18

This release contains a variety of fixes from 8.2.20. + For information about new features in the 8.2 major release, see + Section E.86. +

E.65.1. Migration to Version 8.2.21

A dump/restore is not required for those running 8.2.X. + However, if you are upgrading from a version earlier than 8.2.14, + see the release notes for 8.2.14. +

E.65.2. Changes

  • Avoid potential deadlock during catalog cache initialization + (Nikhil Sontakke) +

    In some cases the cache loading code would acquire share lock on a + system index before locking the index's catalog. This could deadlock + against processes trying to acquire exclusive locks in the other, + more standard order. +

  • Fix dangling-pointer problem in BEFORE ROW UPDATE trigger + handling when there was a concurrent update to the target tuple + (Tom Lane) +

    This bug has been observed to result in intermittent "cannot + extract system attribute from virtual tuple" failures while trying to + do UPDATE RETURNING ctid. There is a very small probability + of more serious errors, such as generating incorrect index entries for + the updated tuple. +

  • Disallow DROP TABLE when there are pending deferred trigger + events for the table (Tom Lane) +

    Formerly the DROP would go through, leading to + "could not open relation with OID nnn" errors when the + triggers were eventually fired. +

  • Fix PL/Python memory leak involving array slices (Daniel Popowich) +

  • Fix pg_restore to cope with long lines (over 1KB) in + TOC files (Tom Lane) +

  • Put in more safeguards against crashing due to division-by-zero + with overly enthusiastic compiler optimization (Aurelien Jarno) +

  • Support use of dlopen() in FreeBSD and OpenBSD on MIPS (Tom Lane) +

    There was a hard-wired assumption that this system function was not + available on MIPS hardware on these systems. Use a compile-time test + instead, since more recent versions have it. +

  • Fix compilation failures on HP-UX (Heikki Linnakangas) +

  • Fix path separator used by pg_regress on Cygwin + (Andrew Dunstan) +

  • Update time zone data files to tzdata release 2011f + for DST law changes in Chile, Cuba, Falkland Islands, Morocco, Samoa, + and Turkey; also historical corrections for South Australia, Alaska, + and Hawaii. +


PrevHomeNext
Release 8.2.22UpRelease 8.2.20
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-2-22.html b/doc/src/sgml/html/release-8-2-22.html new file mode 100644 index 000000000..ec0e89b8b --- /dev/null +++ b/doc/src/sgml/html/release-8-2-22.html @@ -0,0 +1,533 @@ + +Release 8.2.22

E.64. Release 8.2.22

Release Date: 2011-09-26

This release contains a variety of fixes from 8.2.21. + For information about new features in the 8.2 major release, see + Section E.86. +

The PostgreSQL community will stop releasing updates + for the 8.2.X release series in December 2011. + Users are encouraged to update to a newer release branch soon. +

E.64.1. Migration to Version 8.2.22

A dump/restore is not required for those running 8.2.X. + However, if you are upgrading from a version earlier than 8.2.14, + see the release notes for 8.2.14. +

E.64.2. Changes

  • Fix multiple bugs in GiST index page split processing (Heikki + Linnakangas) +

    The probability of occurrence was low, but these could lead to index + corruption. +

  • Avoid possibly accessing off the end of memory in ANALYZE + (Noah Misch) +

    This fixes a very-low-probability server crash scenario. +

  • Fix race condition in relcache init file invalidation (Tom Lane) +

    There was a window wherein a new backend process could read a stale init + file but miss the inval messages that would tell it the data is stale. + The result would be bizarre failures in catalog accesses, typically + "could not read block 0 in file ..." later during startup. +

  • Fix memory leak at end of a GiST index scan (Tom Lane) +

    Commands that perform many separate GiST index scans, such as + verification of a new GiST-based exclusion constraint on a table + already containing many rows, could transiently require large amounts of + memory due to this leak. +

  • Fix performance problem when constructing a large, lossy bitmap + (Tom Lane) +

  • Fix array- and path-creating functions to ensure padding bytes are + zeroes (Tom Lane) +

    This avoids some situations where the planner will think that + semantically-equal constants are not equal, resulting in poor + optimization. +

  • Work around gcc 4.6.0 bug that breaks WAL replay (Tom Lane) +

    This could lead to loss of committed transactions after a server crash. +

  • Fix dump bug for VALUES in a view (Tom Lane) +

  • Disallow SELECT FOR UPDATE/SHARE on sequences (Tom Lane) +

    This operation doesn't work as expected and can lead to failures. +

  • Defend against integer overflow when computing size of a hash table (Tom + Lane) +

  • Fix portability bugs in use of credentials control messages for + "peer" authentication (Tom Lane) +

  • Fix typo in pg_srand48 seed initialization (Andres Freund) +

    This led to failure to use all bits of the provided seed. This function + is not used on most platforms (only those without srandom), + and the potential security exposure from a less-random-than-expected + seed seems minimal in any case. +

  • Avoid integer overflow when the sum of LIMIT and + OFFSET values exceeds 2^63 (Heikki Linnakangas) +

  • Add overflow checks to int4 and int8 versions of + generate_series() (Robert Haas) +

  • Fix trailing-zero removal in to_char() (Marti Raudsepp) +

    In a format with FM and no digit positions + after the decimal point, zeroes to the left of the decimal point could + be removed incorrectly. +

  • Fix pg_size_pretty() to avoid overflow for inputs close to + 2^63 (Tom Lane) +

  • Fix psql's counting of script file line numbers during + COPY from a different file (Tom Lane) +

  • Fix pg_restore's direct-to-database mode for + standard_conforming_strings (Tom Lane) +

    pg_restore could emit incorrect commands when restoring + directly to a database server from an archive file that had been made + with standard_conforming_strings set to on. +

  • Fix write-past-buffer-end and memory leak in libpq's + LDAP service lookup code (Albe Laurenz) +

  • In libpq, avoid failures when using nonblocking I/O + and an SSL connection (Martin Pihlak, Tom Lane) +

  • Improve libpq's handling of failures during connection startup + (Tom Lane) +

    In particular, the response to a server report of fork() + failure during SSL connection startup is now saner. +

  • Make ecpglib write double values with 15 digits + precision (Akira Kurosawa) +

  • Apply upstream fix for blowfish signed-character bug (CVE-2011-2483) + (Tom Lane) +

    contrib/pg_crypto's blowfish encryption code could give + wrong results on platforms where char is signed (which is most), + leading to encrypted passwords being weaker than they should be. +

  • Fix memory leak in contrib/seg (Heikki Linnakangas) +

  • Fix pgstatindex() to give consistent results for empty + indexes (Tom Lane) +

  • Allow building with perl 5.14 (Alex Hunsaker) +

  • Update configure script's method for probing existence of system + functions (Tom Lane) +

    The version of autoconf we used in 8.3 and 8.2 could be fooled by + compilers that perform link-time optimization. +

  • Fix assorted issues with build and install file paths containing spaces + (Tom Lane) +

  • Update time zone data files to tzdata release 2011i + for DST law changes in Canada, Egypt, Russia, Samoa, and South Sudan. +


PrevHomeNext
Release 8.2.23UpRelease 8.2.21
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-2-23.html b/doc/src/sgml/html/release-8-2-23.html new file mode 100644 index 000000000..24188a9fc --- /dev/null +++ b/doc/src/sgml/html/release-8-2-23.html @@ -0,0 +1,483 @@ + +Release 8.2.23

E.63. Release 8.2.23

Release Date: 2011-12-05

This release contains a variety of fixes from 8.2.22. + For information about new features in the 8.2 major release, see + Section E.86. +

This is expected to be the last PostgreSQL release + in the 8.2.X series. Users are encouraged to update to a newer + release branch soon. +

E.63.1. Migration to Version 8.2.23

A dump/restore is not required for those running 8.2.X. +

However, a longstanding error was discovered in the definition of the + information_schema.referential_constraints view. If you + rely on correct results from that view, you should replace its + definition as explained in the first changelog item below. +

Also, if you are upgrading from a version earlier than 8.2.14, + see the release notes for 8.2.14. +

E.63.2. Changes

  • Fix bugs in information_schema.referential_constraints view + (Tom Lane) +

    This view was being insufficiently careful about matching the + foreign-key constraint to the depended-on primary or unique key + constraint. That could result in failure to show a foreign key + constraint at all, or showing it multiple times, or claiming that it + depends on a different constraint than the one it really does. +

    Since the view definition is installed by initdb, + merely upgrading will not fix the problem. If you need to fix this + in an existing installation, you can (as a superuser) drop the + information_schema schema then re-create it by sourcing + SHAREDIR/information_schema.sql. + (Run pg_config --sharedir if you're uncertain where + SHAREDIR is.) This must be repeated in each database + to be fixed. +

  • Fix TOAST-related data corruption during CREATE TABLE dest AS + SELECT * FROM src or INSERT INTO dest SELECT * FROM src + (Tom Lane) +

    If a table has been modified by ALTER TABLE ADD COLUMN, + attempts to copy its data verbatim to another table could produce + corrupt results in certain corner cases. + The problem can only manifest in this precise form in 8.4 and later, + but we patched earlier versions as well in case there are other code + paths that could trigger the same bug. +

  • Fix race condition during toast table access from stale syscache entries + (Tom Lane) +

    The typical symptom was transient errors like "missing chunk + number 0 for toast value NNNNN in pg_toast_2619", where the cited + toast table would always belong to a system catalog. +

  • Improve locale support in money type's input and output + (Tom Lane) +

    Aside from not supporting all standard + lc_monetary + formatting options, the input and output functions were inconsistent, + meaning there were locales in which dumped money values could + not be re-read. +

  • Don't let transform_null_equals + affect CASE foo WHEN NULL ... constructs + (Heikki Linnakangas) +

    transform_null_equals is only supposed to affect + foo = NULL expressions written directly by the user, not + equality checks generated internally by this form of CASE. +

  • Change foreign-key trigger creation order to better support + self-referential foreign keys (Tom Lane) +

    For a cascading foreign key that references its own table, a row update + will fire both the ON UPDATE trigger and the + CHECK trigger as one event. The ON UPDATE + trigger must execute first, else the CHECK will check a + non-final state of the row and possibly throw an inappropriate error. + However, the firing order of these triggers is determined by their + names, which generally sort in creation order since the triggers have + auto-generated names following the convention + "RI_ConstraintTrigger_NNNN". A proper fix would require + modifying that convention, which we will do in 9.2, but it seems risky + to change it in existing releases. So this patch just changes the + creation order of the triggers. Users encountering this type of error + should drop and re-create the foreign key constraint to get its + triggers into the right order. +

  • Preserve blank lines within commands in psql's command + history (Robert Haas) +

    The former behavior could cause problems if an empty line was removed + from within a string literal, for example. +

  • Use the preferred version of xsubpp to build PL/Perl, + not necessarily the operating system's main copy + (David Wheeler and Alex Hunsaker) +

  • Honor query cancel interrupts promptly in pgstatindex() + (Robert Haas) +

  • Ensure VPATH builds properly install all server header files + (Peter Eisentraut) +

  • Shorten file names reported in verbose error messages (Peter Eisentraut) +

    Regular builds have always reported just the name of the C file + containing the error message call, but VPATH builds formerly + reported an absolute path name. +

  • Fix interpretation of Windows timezone names for Central America + (Tom Lane) +

    Map "Central America Standard Time" to CST6, not + CST6CDT, because DST is generally not observed anywhere in + Central America. +

  • Update time zone data files to tzdata release 2011n + for DST law changes in Brazil, Cuba, Fiji, Palestine, Russia, and Samoa; + also historical corrections for Alaska and British East Africa. +


PrevHomeNext
Release 8.3UpRelease 8.2.22
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-2-3.html b/doc/src/sgml/html/release-8-2-3.html new file mode 100644 index 000000000..317ebc1c8 --- /dev/null +++ b/doc/src/sgml/html/release-8-2-3.html @@ -0,0 +1,217 @@ + +Release 8.2.3

E.83. Release 8.2.3

Release Date: 2007-02-07

This release contains two fixes from 8.2.2. + For information about new features in the 8.2 major release, see + Section E.86. +

E.83.1. Migration to Version 8.2.3

A dump/restore is not required for those running 8.2.X. +

E.83.2. Changes

  • Remove overly-restrictive check for type length in constraints and + functional indexes(Tom) +

  • Fix optimization so MIN/MAX in subqueries can again use indexes (Tom) +


PrevHomeNext
Release 8.2.4UpRelease 8.2.2
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-2-4.html b/doc/src/sgml/html/release-8-2-4.html new file mode 100644 index 000000000..85c187018 --- /dev/null +++ b/doc/src/sgml/html/release-8-2-4.html @@ -0,0 +1,346 @@ + +Release 8.2.4

E.82. Release 8.2.4

Release Date: 2007-04-23

This release contains a variety of fixes from 8.2.3, + including a security fix. + For information about new features in the 8.2 major release, see + Section E.86. +

E.82.1. Migration to Version 8.2.4

A dump/restore is not required for those running 8.2.X. +

E.82.2. Changes

  • Support explicit placement of the temporary-table schema within + search_path, and disable searching it for functions + and operators (Tom) +

    This is needed to allow a security-definer function to set a + truly secure value of search_path. Without it, + an unprivileged SQL user can use temporary objects to execute code + with the privileges of the security-definer function (CVE-2007-2138). + See CREATE FUNCTION for more information. +

  • Fix shared_preload_libraries for Windows + by forcing reload in each backend (Korry Douglas) +

  • Fix to_char() so it properly upper/lower cases localized day or month + names (Pavel Stehule) +

  • /contrib/tsearch2 crash fixes (Teodor) +

  • Require COMMIT PREPARED to be executed in the same + database as the transaction was prepared in (Heikki) +

  • Allow pg_dump to do binary backups larger than two gigabytes + on Windows (Magnus) +

  • New traditional (Taiwan) Chinese FAQ (Zhou Daojing) +

  • Prevent the statistics collector from writing to disk too frequently (Tom) +

  • Fix potential-data-corruption bug in how VACUUM FULL handles + UPDATE chains (Tom, Pavan Deolasee) +

  • Fix bug in domains that use array types (Tom) +

  • Fix pg_dump so it can dump a serial column's sequence + using -t when not also dumping the owning table + (Tom) +

  • Planner fixes, including improving outer join and bitmap scan + selection logic (Tom) +

  • Fix possible wrong answers or crash when a PL/pgSQL function tries + to RETURN from within an EXCEPTION block + (Tom) +

  • Fix PANIC during enlargement of a hash index (Tom) +

  • Fix POSIX-style timezone specs to follow new USA DST rules (Tom) +


PrevHomeNext
Release 8.2.5UpRelease 8.2.3
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-2-5.html b/doc/src/sgml/html/release-8-2-5.html new file mode 100644 index 000000000..9b56021fd --- /dev/null +++ b/doc/src/sgml/html/release-8-2-5.html @@ -0,0 +1,388 @@ + +Release 8.2.5

E.81. Release 8.2.5

Release Date: 2007-09-17

This release contains a variety of fixes from 8.2.4. + For information about new features in the 8.2 major release, see + Section E.86. +

E.81.1. Migration to Version 8.2.5

A dump/restore is not required for those running 8.2.X. +

E.81.2. Changes

  • Prevent index corruption when a transaction inserts rows and + then aborts close to the end of a concurrent VACUUM + on the same table (Tom) +

  • Fix ALTER DOMAIN ADD CONSTRAINT for cases involving + domains over domains (Tom) +

  • Make CREATE DOMAIN ... DEFAULT NULL work properly (Tom) +

  • Fix some planner problems with outer joins, notably poor + size estimation for t1 LEFT JOIN t2 WHERE t2.col IS NULL + (Tom) +

  • Allow the interval data type to accept input consisting only of + milliseconds or microseconds (Neil) +

  • Allow timezone name to appear before the year in timestamp input (Tom) +

  • Fixes for GIN indexes used by /contrib/tsearch2 (Teodor) +

  • Speed up rtree index insertion (Teodor) +

  • Fix excessive logging of SSL error messages (Tom) +

  • Fix logging so that log messages are never interleaved when using + the syslogger process (Andrew) +

  • Fix crash when log_min_error_statement logging runs out + of memory (Tom) +

  • Fix incorrect handling of some foreign-key corner cases (Tom) +

  • Fix stddev_pop(numeric) and var_pop(numeric) (Tom) +

  • Prevent REINDEX and CLUSTER from failing + due to attempting to process temporary tables of other sessions (Alvaro) +

  • Update the time zone database rules, particularly New Zealand's upcoming changes (Tom) +

  • Windows socket and semaphore improvements (Magnus) +

  • Make pg_ctl -w work properly in Windows service mode (Dave Page) +

  • Fix memory allocation bug when using MIT Kerberos on Windows (Magnus) +

  • Suppress timezone name (%Z) in log timestamps on Windows + because of possible encoding mismatches (Tom) +

  • Require non-superusers who use /contrib/dblink to use only + password authentication, as a security measure (Joe) +

  • Restrict /contrib/pgstattuple functions to superusers, for security reasons (Tom) +

  • Do not let /contrib/intarray try to make its GIN opclass + the default (this caused problems at dump/restore) (Tom) +


PrevHomeNext
Release 8.2.6UpRelease 8.2.4
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-2-6.html b/doc/src/sgml/html/release-8-2-6.html new file mode 100644 index 000000000..c3092dc32 --- /dev/null +++ b/doc/src/sgml/html/release-8-2-6.html @@ -0,0 +1,573 @@ + +Release 8.2.6

E.80. Release 8.2.6

Release Date: 2008-01-07

This release contains a variety of fixes from 8.2.5, + including fixes for significant security issues. + For information about new features in the 8.2 major release, see + Section E.86. +

E.80.1. Migration to Version 8.2.6

A dump/restore is not required for those running 8.2.X. +

E.80.2. Changes

  • Prevent functions in indexes from executing with the privileges of + the user running VACUUM, ANALYZE, etc (Tom) +

    Functions used in index expressions and partial-index + predicates are evaluated whenever a new table entry is made. It has + long been understood that this poses a risk of trojan-horse code + execution if one modifies a table owned by an untrustworthy user. + (Note that triggers, defaults, check constraints, etc. pose the + same type of risk.) But functions in indexes pose extra danger + because they will be executed by routine maintenance operations + such as VACUUM FULL, which are commonly performed + automatically under a superuser account. For example, a nefarious user + can execute code with superuser privileges by setting up a + trojan-horse index definition and waiting for the next routine vacuum. + The fix arranges for standard maintenance operations + (including VACUUM, ANALYZE, REINDEX, + and CLUSTER) to execute as the table owner rather than + the calling user, using the same privilege-switching mechanism already + used for SECURITY DEFINER functions. To prevent bypassing + this security measure, execution of SET SESSION + AUTHORIZATION and SET ROLE is now forbidden within a + SECURITY DEFINER context. (CVE-2007-6600) +

  • Repair assorted bugs in the regular-expression package (Tom, Will Drewry) +

    Suitably crafted regular-expression patterns could cause crashes, + infinite or near-infinite looping, and/or massive memory consumption, + all of which pose denial-of-service hazards for applications that + accept regex search patterns from untrustworthy sources. + (CVE-2007-4769, CVE-2007-4772, CVE-2007-6067) +

  • Require non-superusers who use /contrib/dblink to use only + password authentication, as a security measure (Joe) +

    The fix that appeared for this in 8.2.5 was incomplete, as it plugged + the hole for only some dblink functions. (CVE-2007-6601, + CVE-2007-3278) +

  • Fix bugs in WAL replay for GIN indexes (Teodor) +

  • Fix GIN index build to work properly when + maintenance_work_mem is 4GB or more (Tom) +

  • Update time zone data files to tzdata release 2007k + (in particular, recent Argentina changes) (Tom) +

  • Improve planner's handling of LIKE/regex estimation in non-C locales + (Tom) +

  • Fix planning-speed problem for deep outer-join nests, as well as + possible poor choice of join order (Tom) +

  • Fix planner failure in some cases of WHERE false AND var IN + (SELECT ...) (Tom) +

  • Make CREATE TABLE ... SERIAL and + ALTER SEQUENCE ... OWNED BY not change the + currval() state of the sequence (Tom) +

  • Preserve the tablespace and storage parameters of indexes that are + rebuilt by ALTER TABLE ... ALTER COLUMN TYPE (Tom) +

  • Make archive recovery always start a new WAL timeline, rather than only + when a recovery stop time was used (Simon) +

    This avoids a corner-case risk of trying to overwrite an existing + archived copy of the last WAL segment, and seems simpler and cleaner + than the original definition. +

  • Make VACUUM not use all of maintenance_work_mem + when the table is too small for it to be useful (Alvaro) +

  • Fix potential crash in translate() when using a multibyte + database encoding (Tom) +

  • Make corr() return the correct result for negative + correlation values (Neil) +

  • Fix overflow in extract(epoch from interval) for intervals + exceeding 68 years (Tom) +

  • Fix PL/Perl to not fail when a UTF-8 regular expression is used + in a trusted function (Andrew) +

  • Fix PL/Perl to cope when platform's Perl defines type bool + as int rather than char (Tom) +

    While this could theoretically happen anywhere, no standard build of + Perl did things this way ... until Mac OS X 10.5. +

  • Fix PL/Python to work correctly with Python 2.5 on 64-bit machines + (Marko Kreen) +

  • Fix PL/Python to not crash on long exception messages (Alvaro) +

  • Fix pg_dump to correctly handle inheritance child tables + that have default expressions different from their parent's (Tom) +

  • Fix libpq crash when PGPASSFILE refers + to a file that is not a plain file (Martin Pitt) +

  • ecpg parser fixes (Michael) +

  • Make contrib/pgcrypto defend against + OpenSSL libraries that fail on keys longer than 128 + bits; which is the case at least on some Solaris versions (Marko Kreen) +

  • Make contrib/tablefunc's crosstab() handle + NULL rowid as a category in its own right, rather than crashing (Joe) +

  • Fix tsvector and tsquery output routines to + escape backslashes correctly (Teodor, Bruce) +

  • Fix crash of to_tsvector() on huge input strings (Teodor) +

  • Require a specific version of Autoconf to be used + when re-generating the configure script (Peter) +

    This affects developers and packagers only. The change was made + to prevent accidental use of untested combinations of + Autoconf and PostgreSQL versions. + You can remove the version check if you really want to use a + different Autoconf version, but it's + your responsibility whether the result works or not. +

  • Update gettimeofday configuration check so that + PostgreSQL can be built on newer versions of + MinGW (Magnus) +


PrevHomeNext
Release 8.2.7UpRelease 8.2.5
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-2-7.html b/doc/src/sgml/html/release-8-2-7.html new file mode 100644 index 000000000..31ded3b11 --- /dev/null +++ b/doc/src/sgml/html/release-8-2-7.html @@ -0,0 +1,510 @@ + +Release 8.2.7

E.79. Release 8.2.7

Release Date: 2008-03-17

This release contains a variety of fixes from 8.2.6. + For information about new features in the 8.2 major release, see + Section E.86. +

E.79.1. Migration to Version 8.2.7

A dump/restore is not required for those running 8.2.X. + However, you might need to REINDEX indexes on textual + columns after updating, if you are affected by the Windows locale + issue described below. +

E.79.2. Changes

  • Fix character string comparison for Windows locales that consider + different character combinations as equal (Tom) +

    This fix applies only on Windows and only when using UTF-8 + database encoding. The same fix was made for all other cases + over two years ago, but Windows with UTF-8 uses a separate code + path that was not updated. If you are using a locale that + considers some non-identical strings as equal, you may need to + REINDEX to fix existing indexes on textual columns. +

  • Repair potential deadlock between concurrent VACUUM FULL + operations on different system catalogs (Tom) +

  • Fix longstanding LISTEN/NOTIFY + race condition (Tom) +

    In rare cases a session that had just executed a + LISTEN might not get a notification, even though + one would be expected because the concurrent transaction executing + NOTIFY was observed to commit later. +

    A side effect of the fix is that a transaction that has executed + a not-yet-committed LISTEN command will not see any + row in pg_listener for the LISTEN, + should it choose to look; formerly it would have. This behavior + was never documented one way or the other, but it is possible that + some applications depend on the old behavior. +

  • Disallow LISTEN and UNLISTEN within a + prepared transaction (Tom) +

    This was formerly allowed but trying to do it had various unpleasant + consequences, notably that the originating backend could not exit + as long as an UNLISTEN remained uncommitted. +

  • Disallow dropping a temporary table within a + prepared transaction (Heikki) +

    This was correctly disallowed by 8.1, but the check was inadvertently + broken in 8.2. +

  • Fix rare crash when an error occurs during a query using a hash index + (Heikki) +

  • Fix memory leaks in certain usages of set-returning functions (Neil) +

  • Fix input of datetime values for February 29 in years BC (Tom) +

    The former coding was mistaken about which years were leap years. +

  • Fix "unrecognized node type" error in some variants of + ALTER OWNER (Tom) +

  • Ensure pg_stat_activity.waiting flag + is cleared when a lock wait is aborted (Tom) +

  • Fix handling of process permissions on Windows Vista (Dave, Magnus) +

    In particular, this fix allows starting the server as the Administrator + user. +

  • Update time zone data files to tzdata release 2008a + (in particular, recent Chile changes); adjust timezone abbreviation + VET (Venezuela) to mean UTC-4:30, not UTC-4:00 (Tom) +

  • Fix pg_ctl to correctly extract the postmaster's port + number from command-line options (Itagaki Takahiro, Tom) +

    Previously, pg_ctl start -w could try to contact the + postmaster on the wrong port, leading to bogus reports of startup + failure. +

  • Use -fwrapv to defend against possible misoptimization + in recent gcc versions (Tom) +

    This is known to be necessary when building PostgreSQL + with gcc 4.3 or later. +

  • Correctly enforce statement_timeout values longer + than INT_MAX microseconds (about 35 minutes) (Tom) +

    This bug affects only builds with --enable-integer-datetimes. +

  • Fix "unexpected PARAM_SUBLINK ID" planner error when + constant-folding simplifies a sub-select (Tom) +

  • Fix logical errors in constraint-exclusion handling of IS + NULL and NOT expressions (Tom) +

    The planner would sometimes exclude partitions that should not + have been excluded because of the possibility of NULL results. +

  • Fix another cause of "failed to build any N-way joins" + planner errors (Tom) +

    This could happen in cases where a clauseless join needed to be + forced before a join clause could be exploited. +

  • Fix incorrect constant propagation in outer-join planning (Tom) +

    The planner could sometimes incorrectly conclude that a variable + could be constrained to be equal to a constant, leading + to wrong query results. +

  • Fix display of constant expressions in ORDER BY + and GROUP BY (Tom) +

    An explicitly casted constant would be shown incorrectly. This could + for example lead to corruption of a view definition during + dump and reload. +

  • Fix libpq to handle NOTICE messages correctly + during COPY OUT (Tom) +

    This failure has only been observed to occur when a user-defined + datatype's output routine issues a NOTICE, but there is no + guarantee it couldn't happen due to other causes. +


PrevHomeNext
Release 8.2.8UpRelease 8.2.6
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-2-8.html b/doc/src/sgml/html/release-8-2-8.html new file mode 100644 index 000000000..d44b776e9 --- /dev/null +++ b/doc/src/sgml/html/release-8-2-8.html @@ -0,0 +1,449 @@ + +Release 8.2.8

E.78. Release 8.2.8

Release Date: never released

This release contains a variety of fixes from 8.2.7. + For information about new features in the 8.2 major release, see + Section E.86. +

E.78.1. Migration to Version 8.2.8

A dump/restore is not required for those running 8.2.X. + However, if you are upgrading from a version earlier than 8.2.7, + see the release notes for 8.2.7. +

E.78.2. Changes

  • Fix ERRORDATA_STACK_SIZE exceeded crash that + occurred on Windows when using UTF-8 database encoding and a different + client encoding (Tom) +

  • Fix ALTER TABLE ADD COLUMN ... PRIMARY KEY so that the new + column is correctly checked to see if it's been initialized to all + non-nulls (Brendan Jurd) +

    Previous versions neglected to check this requirement at all. +

  • Fix possible CREATE TABLE failure when inheriting the + "same" constraint from multiple parent relations that + inherited that constraint from a common ancestor (Tom) +

  • Fix pg_get_ruledef() to show the alias, if any, attached + to the target table of an UPDATE or DELETE + (Tom) +

  • Fix GIN bug that could result in a too many LWLocks + taken failure (Teodor) +

  • Avoid possible crash when decompressing corrupted data + (Zdenek Kotala) +

  • Repair two places where SIGTERM exit of a backend could leave corrupted + state in shared memory (Tom) +

    Neither case is very important if SIGTERM is used to shut down the + whole database cluster together, but there was a problem if someone + tried to SIGTERM individual backends. +

  • Fix conversions between ISO-8859-5 and other encodings to handle + Cyrillic "Yo" characters (e and E with + two dots) (Sergey Burladyan) +

  • Fix several datatype input functions, notably array_in(), + that were allowing unused bytes in their results to contain + uninitialized, unpredictable values (Tom) +

    This could lead to failures in which two apparently identical literal + values were not seen as equal, resulting in the parser complaining + about unmatched ORDER BY and DISTINCT + expressions. +

  • Fix a corner case in regular-expression substring matching + (substring(string from + pattern)) (Tom) +

    The problem occurs when there is a match to the pattern overall but + the user has specified a parenthesized subexpression and that + subexpression hasn't got a match. An example is + substring('foo' from 'foo(bar)?'). + This should return NULL, since (bar) isn't matched, but + it was mistakenly returning the whole-pattern match instead (ie, + foo). +

  • Update time zone data files to tzdata release 2008c (for + DST law changes in Morocco, Iraq, Choibalsan, Pakistan, Syria, Cuba, and + Argentina/San_Luis) +

  • Fix incorrect result from ecpg's + PGTYPEStimestamp_sub() function (Michael) +

  • Fix broken GiST comparison function for contrib/tsearch2's + tsquery type (Teodor) +

  • Fix possible crashes in contrib/cube functions (Tom) +

  • Fix core dump in contrib/xml2's + xpath_table() function when the input query returns a + NULL value (Tom) +

  • Fix contrib/xml2's makefile to not override + CFLAGS (Tom) +

  • Fix DatumGetBool macro to not fail with gcc + 4.3 (Tom) +

    This problem affects "old style" (V0) C functions that + return boolean. The fix is already in 8.3, but the need to + back-patch it was not realized at the time. +


PrevHomeNext
Release 8.2.9UpRelease 8.2.7
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-2-9.html b/doc/src/sgml/html/release-8-2-9.html new file mode 100644 index 000000000..c62e46d1f --- /dev/null +++ b/doc/src/sgml/html/release-8-2-9.html @@ -0,0 +1,266 @@ + +Release 8.2.9

E.77. Release 8.2.9

Release Date: 2008-06-12

This release contains one serious and one minor bug fix over 8.2.8. + For information about new features in the 8.2 major release, see + Section E.86. +

E.77.1. Migration to Version 8.2.9

A dump/restore is not required for those running 8.2.X. + However, if you are upgrading from a version earlier than 8.2.7, + see the release notes for 8.2.7. +

E.77.2. Changes

  • Make pg_get_ruledef() parenthesize negative constants (Tom) +

    Before this fix, a negative constant in a view or rule might be dumped + as, say, -42::integer, which is subtly incorrect: it should + be (-42)::integer due to operator precedence rules. + Usually this would make little difference, but it could interact with + another recent patch to cause + PostgreSQL to reject what had been a valid + SELECT DISTINCT view query. Since this could result in + pg_dump output failing to reload, it is being treated + as a high-priority fix. The only released versions in which dump + output is actually incorrect are 8.3.1 and 8.2.7. +

  • Make ALTER AGGREGATE ... OWNER TO update + pg_shdepend (Tom) +

    This oversight could lead to problems if the aggregate was later + involved in a DROP OWNED or REASSIGN OWNED + operation. +


PrevHomeNext
Release 8.2.10UpRelease 8.2.8
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-2.html b/doc/src/sgml/html/release-8-2.html new file mode 100644 index 000000000..3fa070ffd --- /dev/null +++ b/doc/src/sgml/html/release-8-2.html @@ -0,0 +1,4106 @@ + +Release 8.2

E.86. Release 8.2

Release Date: 2006-12-05

E.86.1. Overview

This release adds many functionality and performance improvements that + were requested by users, including: + +

  • Query language enhancements including INSERT/UPDATE/DELETE + RETURNING, multirow VALUES lists, and + optional target-table alias in + UPDATE/DELETE +

  • Index creation without blocking concurrent + INSERT/UPDATE/DELETE + operations +

  • Many query optimization improvements, including support for + reordering outer joins +

  • Improved sorting performance with lower memory usage +

  • More efficient locking with better concurrency +

  • More efficient vacuuming +

  • Easier administration of warm standby servers +

  • New FILLFACTOR support for tables and indexes +

  • Monitoring, logging, and performance tuning additions +

  • More control over creating and dropping objects +

  • Table inheritance relationships can be defined + for and removed from pre-existing tables +

  • COPY TO can copy the output of an arbitrary + SELECT statement +

  • Array improvements, including nulls in arrays +

  • Aggregate-function improvements, including multiple-input + aggregates and SQL:2003 statistical functions +

  • Many contrib/ improvements +

+ +

E.86.2. Migration to Version 8.2

A dump/restore using pg_dump is + required for those wishing to migrate data from any previous + release. +

Observe the following incompatibilities: +

  • Set escape_string_warning + to on by default (Bruce) +

    This issues a warning if backslash escapes are used in + non-escape (non-E'') + strings. +

  • Change the row + constructor syntax (ROW(...)) so that + list elements foo.* will be expanded to a list + of their member fields, rather than creating a nested + row type field as formerly (Tom) +

    The new behavior is substantially more useful since it + allows, for example, triggers to check for data changes + with IF row(new.*) IS DISTINCT FROM row(old.*). + The old behavior is still available by omitting .*. +

  • Make row comparisons + follow SQL standard semantics and allow them + to be used in index scans (Tom) +

    Previously, row = and <> comparisons followed the + standard but < <= > >= did not. A row comparison + can now be used as an index constraint for a multicolumn + index matching the row value. +

  • Make row IS [NOT] NULL + tests follow SQL standard semantics (Tom) +

    The former behavior conformed to the standard for simple cases + with IS NULL, but IS NOT NULL would return + true if any row field was non-null, whereas the standard says it + should return true only when all fields are non-null. +

  • Make SET + CONSTRAINT affect only one constraint (Kris Jurka) +

    In previous releases, SET CONSTRAINT modified + all constraints with a matching name. In this release, + the schema search path is used to modify only the first + matching constraint. A schema specification is also + supported. This more nearly conforms to the SQL standard. +

  • Remove RULE permission for tables, for security reasons + (Tom) +

    As of this release, only a table's owner can create or modify + rules for the table. For backwards compatibility, + GRANT/REVOKE RULE is still accepted, + but it does nothing. +

  • Array comparison improvements (Tom) +

    Now array dimensions are also compared. +

  • Change array concatenation + to match documented behavior (Tom) +

    This changes the previous behavior where concatenation + would modify the array lower bound. +

  • Make command-line options of postmaster + and postgres + identical (Peter) +

    This allows the postmaster to pass arguments to each backend + without using -o. Note that some options are now + only available as long-form options, because there were conflicting + single-letter options. +

  • Deprecate use of postmaster symbolic link (Peter) +

    postmaster and postgres + commands now act identically, with the behavior determined + by command-line options. The postmaster symbolic link is + kept for compatibility, but is not really needed. +

  • Change log_duration + to output even if the query is not output (Tom) +

    In prior releases, log_duration only printed if + the query appeared earlier in the log. +

  • Make to_char(time) + and to_char(interval) + treat HH and HH12 as 12-hour + intervals +

    Most applications should use HH24 unless they + want a 12-hour display. +

  • Zero unmasked bits in conversion from INET to CIDR (Tom) +

    This ensures that the converted value is actually valid for + CIDR. +

  • Remove australian_timezones configuration variable + (Joachim Wieland) +

    This variable has been superseded by a more general facility + for configuring timezone abbreviations. +

  • Improve cost estimation for nested-loop index scans (Tom) +

    This might eliminate the need to set unrealistically small + values of random_page_cost. + If you have been using a very small random_page_cost, + please recheck your test cases. +

  • Change behavior of pg_dump -n and + -t options. (Greg Sabino Mullane) +

    See the pg_dump manual page for details. +

  • Change libpq + PQdsplen() to return a useful value (Martijn + van Oosterhout) +

  • Declare libpq + PQgetssl() as returning void *, + rather than SSL * (Martijn van Oosterhout) +

    This allows applications to use the function without including + the OpenSSL headers. +

  • C-language loadable modules must now include a + PG_MODULE_MAGIC + macro call for version compatibility checking + (Martijn van Oosterhout) +

  • For security's sake, modules used by a PL/PerlU function are no + longer available to PL/Perl functions (Andrew) +

    Note: This also implies that data can no longer be shared between a PL/Perl + function and a PL/PerlU function. + Some Perl installations have not been compiled with the correct flags + to allow multiple interpreters to exist within a single process. + In this situation PL/Perl and PL/PerlU cannot both be used in a + single backend. The solution is to get a Perl installation which + supports multiple interpreters. +

  • In contrib/xml2/, rename xml_valid() to + xml_is_well_formed() (Tom) +

    xml_valid() will remain for backward compatibility, + but its behavior will change to do schema checking in a future + release. +

  • Remove contrib/ora2pg/, now at http://www.samse.fr/GPL/ora2pg +

  • Remove contrib modules that have been migrated to PgFoundry: + adddepend, dbase, dbmirror, + fulltextindex, mac, userlock +

  • Remove abandoned contrib modules: + mSQL-interface, tips +

  • Remove QNX and BEOS ports (Bruce) +

    These ports no longer had active maintainers. +

E.86.3. Changes

Below you will find a detailed account of the + changes between PostgreSQL 8.2 and + the previous major release. +

E.86.3.1. Performance Improvements

  • Allow the planner to reorder outer + joins in some circumstances (Tom) +

    In previous releases, outer joins would always be evaluated in + the order written in the query. This change allows the + query optimizer to consider reordering outer joins, in cases where + it can determine that the join order can be changed without + altering the meaning of the query. This can make a + considerable performance difference for queries involving + multiple outer joins or mixed inner and outer joins. +

  • Improve efficiency of IN + (list-of-expressions) clauses (Tom) +

  • Improve sorting speed and reduce memory usage (Simon, Tom) +

  • Improve subtransaction performance (Alvaro, Itagaki Takahiro, + Tom) +

  • Add FILLFACTOR to table and index creation (ITAGAKI + Takahiro) +

    This leaves extra free space in each table or index page, + allowing improved performance as the database grows. This + is particularly valuable to maintain clustering. +

  • Increase default values for shared_buffers + and max_fsm_pages + (Andrew) +

  • Improve locking performance by breaking the lock manager tables into + sections + (Tom) +

    This allows locking to be more fine-grained, reducing + contention. +

  • Reduce locking requirements of sequential scans (Qingqing + Zhou) +

  • Reduce locking required for database creation and destruction + (Tom) +

  • Improve the optimizer's selectivity estimates for LIKE, ILIKE, and + regular expression + operations (Tom) +

  • Improve planning of joins to inherited + tables and UNION + ALL views (Tom) +

  • Allow constraint + exclusion to be applied to inherited UPDATE and + DELETE queries (Tom) +

    SELECT already honored constraint exclusion. +

  • Improve planning of constant WHERE clauses, such as + a condition that depends only on variables inherited from an + outer query level (Tom) +

  • Protocol-level unnamed prepared statements are re-planned + for each set of BIND values (Tom) +

    This improves performance because the exact parameter values + can be used in the plan. +

  • Speed up vacuuming of B-Tree indexes (Heikki Linnakangas, + Tom) +

  • Avoid extra scan of tables without indexes during VACUUM (Greg Stark) +

  • Improve multicolumn GiST + indexing (Oleg, Teodor) +

  • Remove dead index entries before B-Tree page split (Junji + Teramoto) +

E.86.3.2. Server Changes

  • Allow a forced switch to a new transaction log file (Simon, Tom) +

    This is valuable for keeping warm standby slave servers + in sync with the master. Transaction log file switching now also happens + automatically during pg_stop_backup(). + This ensures that all + transaction log files needed for recovery can be archived immediately. +

  • Add WAL informational functions (Simon) +

    Add functions for interrogating the current transaction log insertion + point and determining WAL filenames from the + hex WAL locations displayed by pg_stop_backup() + and related functions. +

  • Improve recovery from a crash during WAL replay (Simon) +

    The server now does periodic checkpoints during WAL + recovery, so if there is a crash, future WAL + recovery is shortened. This also eliminates the need for + warm standby servers to replay the entire log since the + base backup if they crash. +

  • Improve reliability of long-term WAL replay + (Heikki, Simon, Tom) +

    Formerly, trying to roll forward through more than 2 billion + transactions would not work due to XID wraparound. This meant + warm standby servers had to be reloaded + from fresh base backups periodically. +

  • Add archive_timeout + to force transaction log file switches at a given interval (Simon) +

    This enforces a maximum replication delay for warm standby servers. +

  • Add native LDAP + authentication (Magnus Hagander) +

    This is particularly useful for platforms that do not + support PAM, such as Windows. +

  • Add GRANT + CONNECT ON DATABASE (Gevik Babakhani) +

    This gives SQL-level control over database access. It works as + an additional filter on top of the existing + pg_hba.conf + controls. +

  • Add support for SSL + Certificate Revocation List (CRL) files + (Libor Hohoš) +

    The server and libpq both recognize CRL + files now. +

  • GiST indexes are + now clusterable (Teodor) +

  • Remove routine autovacuum server log entries (Bruce) +

    pg_stat_activity + now shows autovacuum activity. +

  • Track maximum XID age within individual tables, instead of whole databases (Alvaro) +

    This reduces the overhead involved in preventing transaction + ID wraparound, by avoiding unnecessary VACUUMs. +

  • Add last vacuum and analyze timestamp columns to the stats + collector (Larry Rosenman) +

    These values now appear in the pg_stat_*_tables + system views. +

  • Improve performance of statistics monitoring, especially + stats_command_string + (Tom, Bruce) +

    This release enables stats_command_string by + default, now that its overhead is minimal. This means + pg_stat_activity + will now show all active queries by default. +

  • Add a waiting column to pg_stat_activity + (Tom) +

    This allows pg_stat_activity to show all the + information included in the ps display. +

  • Add configuration parameter update_process_title + to control whether the ps display is updated + for every command (Bruce) +

    On platforms where it is expensive to update the ps + display, it might be worthwhile to turn this off and rely solely on + pg_stat_activity for status information. +

  • Allow units to be specified in configuration settings + (Peter) +

    For example, you can now set shared_buffers + to 32MB rather than mentally converting sizes. +

  • Add support for include + directives in postgresql.conf (Joachim + Wieland) +

  • Improve logging of protocol-level prepare/bind/execute + messages (Bruce, Tom) +

    Such logging now shows statement names, bind parameter + values, and the text of the query being executed. Also, + the query text is properly included in logged error messages + when enabled by log_min_error_statement. +

  • Prevent max_stack_depth + from being set to unsafe values +

    On platforms where we can determine the actual kernel stack depth + limit (which is most), make sure that the initial default value of + max_stack_depth is safe, and reject attempts to set it + to unsafely large values. +

  • Enable highlighting of error location in query in more + cases (Tom) +

    The server is now able to report a specific error location for + some semantic errors (such as unrecognized column name), rather + than just for basic syntax errors as before. +

  • Fix "failed to re-find parent key" errors in + VACUUM (Tom) +

  • Clean out pg_internal.init cache files during server + restart (Simon) +

    This avoids a hazard that the cache files might contain stale + data after PITR recovery. +

  • Fix race condition for truncation of a large relation across a + gigabyte boundary by VACUUM (Tom) +

  • Fix bug causing needless deadlock errors on row-level locks (Tom) +

  • Fix bugs affecting multi-gigabyte hash indexes (Tom) +

  • Each backend process is now its own process group leader (Tom) +

    This allows query cancel to abort subprocesses invoked from a + backend or archive/recovery process. +

E.86.3.3. Query Changes

  • Add INSERT/UPDATE/DELETE + RETURNING (Jonah Harris, Tom) +

    This allows these commands to return values, such as the + computed serial key for a new row. In the UPDATE + case, values from the updated version of the row are returned. +

  • Add support for multiple-row VALUES clauses, + per SQL standard (Joe, Tom) +

    This allows INSERT to insert multiple rows of + constants, or queries to generate result sets using constants. + For example, INSERT ... VALUES (...), (...), + ...., and SELECT * FROM (VALUES (...), (...), + ....) AS alias(f1, ...). +

  • Allow UPDATE + and DELETE + to use an alias for the target table (Atsushi Ogawa) +

    The SQL standard does not permit an alias in these commands, but + many database systems allow one anyway for notational convenience. +

  • Allow UPDATE + to set multiple columns with a list of values (Susanne + Ebrecht) +

    This is basically a short-hand for assigning the columns + and values in pairs. The syntax is UPDATE tab + SET (column, ...) = (val, ...). +

  • Make row comparisons work per standard (Tom) +

    The forms <, <=, >, >= now compare rows lexicographically, + that is, compare the first elements, if equal compare the second + elements, and so on. Formerly they expanded to an AND condition + across all the elements, which was neither standard nor very useful. +

  • Add CASCADE + option to TRUNCATE (Joachim Wieland) +

    This causes TRUNCATE to automatically include all tables + that reference the specified table(s) via foreign keys. While + convenient, this is a dangerous tool — use with caution! +

  • Support FOR UPDATE and FOR SHARE + in the same SELECT + command (Tom) +

  • Add IS NOT + DISTINCT FROM (Pavel Stehule) +

    This operator is similar to equality (=), but + evaluates to true when both left and right operands are + NULL, and to false when just one is, rather than + yielding NULL in these cases. +

  • Improve the length output used by UNION/INTERSECT/EXCEPT + (Tom) +

    When all corresponding columns are of the same defined length, that + length is used for the result, rather than a generic length. +

  • Allow ILIKE + to work for multi-byte encodings (Tom) +

    Internally, ILIKE now calls lower() + and then uses LIKE. Locale-specific regular + expression patterns still do not work in these encodings. +

  • Enable standard_conforming_strings + to be turned on (Kevin Grittner) +

    This allows backslash escaping in strings to be disabled, + making PostgreSQL more + standards-compliant. The default is off for backwards + compatibility, but future releases will default this to on. +

  • Do not flatten subqueries that contain volatile + functions in their target lists (Jaime Casanova) +

    This prevents surprising behavior due to multiple evaluation + of a volatile function (such as random() + or nextval()). It might cause performance + degradation in the presence of functions that are unnecessarily + marked as volatile. +

  • Add system views pg_prepared_statements + and pg_cursors + to show prepared statements and open cursors (Joachim Wieland, Neil) +

    These are very useful in pooled connection setups. +

  • Support portal parameters in EXPLAIN and EXECUTE (Tom) +

    This allows, for example, JDBC ? parameters to + work in these commands. +

  • If SQL-level PREPARE parameters + are unspecified, infer their types from the content of the + query (Neil) +

    Protocol-level PREPARE already did this. +

  • Allow LIMIT and OFFSET to exceed + two billion (Dhanaraj M) +

E.86.3.4. Object Manipulation Changes

  • Add TABLESPACE clause to CREATE TABLE AS + (Neil) +

    This allows a tablespace to be specified for the new table. +

  • Add ON COMMIT clause to CREATE TABLE AS + (Neil) +

    This allows temporary tables to be truncated or dropped on + transaction commit. The default behavior is for the table + to remain until the session ends. +

  • Add INCLUDING CONSTRAINTS to CREATE TABLE LIKE + (Greg Stark) +

    This allows easy copying of CHECK constraints to a new + table. +

  • Allow the creation of placeholder (shell) types (Martijn van Oosterhout) +

    A shell type declaration creates a type name, without specifying + any of the details of the type. Making a shell type is useful + because it allows cleaner declaration of the type's input/output + functions, which must exist before the type can be defined "for + real". The syntax is CREATE TYPE typename. +

  • Aggregate functions + now support multiple input parameters (Sergey Koposov, Tom) +

  • Add new aggregate creation syntax (Tom) +

    The new syntax is CREATE AGGREGATE + aggname (input_type) + (parameter_list). This more + naturally supports the new multi-parameter aggregate + functionality. The previous syntax is still supported. +

  • Add ALTER ROLE PASSWORD NULL + to remove a previously set role password (Peter) +

  • Add DROP object IF EXISTS for many + object types (Andrew) +

    This allows DROP operations on non-existent + objects without generating an error. +

  • Add DROP OWNED + to drop all objects owned by a role (Alvaro) +

  • Add REASSIGN + OWNED to reassign ownership of all objects owned + by a role (Alvaro) +

    This, and DROP OWNED above, facilitate dropping + roles. +

  • Add GRANT ON SEQUENCE + syntax (Bruce) +

    This was added for setting sequence-specific permissions. + GRANT ON TABLE for sequences is still supported + for backward compatibility. +

  • Add USAGE + permission for sequences that allows only currval() + and nextval(), not setval() + (Bruce) +

    USAGE permission allows more fine-grained + control over sequence access. Granting USAGE + allows users to increment + a sequence, but prevents them from setting the sequence to + an arbitrary value using setval(). +

  • Add ALTER TABLE + [ NO ] INHERIT (Greg Stark) +

    This allows inheritance to be adjusted dynamically, rather than + just at table creation and destruction. This is very valuable + when using inheritance to implement table partitioning. +

  • Allow comments on global + objects to be stored globally (Kris Jurka) +

    Previously, comments attached to databases were stored in individual + databases, making them ineffective, and there was no provision + at all for comments on roles or tablespaces. This change adds a new + shared catalog pg_shdescription + and stores comments on databases, roles, and tablespaces therein. +

E.86.3.5. Utility Command Changes

  • Add option to allow indexes to be created without blocking + concurrent writes to the table (Greg Stark, Tom) +

    The new syntax is CREATE + INDEX CONCURRENTLY. The default behavior is + still to block table modification while a index is being + created. +

  • Provide advisory + locking functionality (Abhijit Menon-Sen, Tom) +

    This is a new locking API designed to replace what used to be + in /contrib/userlock. The userlock code is now on pgfoundry. +

  • Allow COPY to + dump a SELECT query (Zoltan Boszormenyi, Karel + Zak) +

    This allows COPY to dump arbitrary SQL + queries. The syntax is COPY (SELECT ...) TO. +

  • Make the COPY + command return a command tag that includes the number of + rows copied (Volkan YAZICI) +

  • Allow VACUUM + to expire rows without being affected by other concurrent + VACUUM operations (Hannu Krossing, Alvaro, Tom) +

  • Make initdb + detect the operating system locale and set the default + DateStyle accordingly (Peter) +

    This makes it more likely that the installed + postgresql.conf DateStyle value will + be as desired. +

  • Reduce number of progress messages displayed by initdb (Tom) +

E.86.3.6. Date/Time Changes

  • Allow full timezone names in timestamp input values + (Joachim Wieland) +

    For example, '2006-05-24 21:11 + America/New_York'::timestamptz. +

  • Support configurable timezone abbreviations (Joachim Wieland) +

    A desired set of timezone abbreviations can be chosen via the + configuration parameter timezone_abbreviations. +

  • Add pg_timezone_abbrevs + and pg_timezone_names + views to show supported timezones (Magnus Hagander) +

  • Add clock_timestamp(), + statement_timestamp(), + and transaction_timestamp() + (Bruce) +

    clock_timestamp() is the current wall-clock time, + statement_timestamp() is the time the current + statement arrived at the server, and + transaction_timestamp() is an alias for + now(). +

  • Allow to_char() + to print localized month and day names (Euler Taveira de + Oliveira) +

  • Allow to_char(time) + and to_char(interval) + to output AM/PM specifications + (Bruce) +

    Intervals and times are treated as 24-hour periods, e.g. + 25 hours is considered AM. +

  • Add new function justify_interval() + to adjust interval units (Mark Dilger) +

  • Allow timezone offsets up to 14:59 away from GMT +

    Kiribati uses GMT+14, so we'd better accept that. +

  • Interval computation improvements (Michael Glaesemann, Bruce) +

E.86.3.7. Other Data Type and Function Changes

  • Allow arrays to contain NULL elements (Tom) +

  • Allow assignment to array elements not contiguous with the existing + entries (Tom) +

    The intervening array positions will be filled with nulls. + This is per SQL standard. +

  • New built-in operators + for array-subset comparisons (@>, + <@, &&) (Teodor, Tom) +

    These operators can be indexed for many data types using + GiST or GIN indexes. +

  • Add convenient arithmetic operations on + INET/CIDR values (Stephen R. van den + Berg) +

    The new operators are & (and), | + (or), ~ (not), inet + int8, + inet - int8, and + inet - inet. +

  • Add new aggregate functions + from SQL:2003 (Neil) +

    The new functions are var_pop(), + var_samp(), stddev_pop(), and + stddev_samp(). var_samp() and + stddev_samp() are merely renamings of the + existing aggregates variance() and + stddev(). The latter names remain available + for backward compatibility. +

  • Add SQL:2003 statistical aggregates + (Sergey Koposov) +

    New functions: regr_intercept(), + regr_slope(), regr_r2(), + corr(), covar_samp(), + covar_pop(), regr_avgx(), + regr_avgy(), regr_sxy(), + regr_sxx(), regr_syy(), + regr_count(). +

  • Allow domains to be + based on other domains (Tom) +

  • Properly enforce domain CHECK constraints + everywhere (Neil, Tom) +

    For example, the result of a user-defined function that is + declared to return a domain type is now checked against the + domain's constraints. This closes a significant hole in the domain + implementation. +

  • Fix problems with dumping renamed SERIAL columns + (Tom) +

    The fix is to dump a SERIAL column by explicitly + specifying its DEFAULT and sequence elements, + and reconstructing the SERIAL column on reload + using a new ALTER + SEQUENCE OWNED BY command. This also allows + dropping a SERIAL column specification. +

  • Add a server-side sleep function pg_sleep() + (Joachim Wieland) +

  • Add all comparison operators for the tid (tuple id) data + type (Mark Kirkwood, Greg Stark, Tom) +

E.86.3.8. PL/pgSQL Server-Side Language Changes

  • Add TG_table_name and TG_table_schema to + trigger parameters (Andrew) +

    TG_relname is now deprecated. Comparable + changes have been made in the trigger parameters for the other + PLs as well. +

  • Allow FOR statements to return values to scalars + as well as records and row types (Pavel Stehule) +

  • Add a BY clause to the FOR loop, + to control the iteration increment (Jaime Casanova) +

  • Add STRICT to SELECT + INTO (Matt Miller) +

    STRICT mode throws an exception if more or less + than one row is returned by the SELECT, for + Oracle PL/SQL compatibility. +

E.86.3.9. PL/Perl Server-Side Language Changes

  • Add table_name and table_schema to + trigger parameters (Adam Sjøgren) +

  • Add prepared queries (Dmitry Karasik) +

  • Make $_TD trigger data a global variable (Andrew) +

    Previously, it was lexical, which caused unexpected sharing + violations. +

  • Run PL/Perl and PL/PerlU in separate interpreters, for security + reasons (Andrew) +

    In consequence, they can no longer share data nor loaded modules. + Also, if Perl has not been compiled with the requisite flags to + allow multiple interpreters, only one of these languages can be used + in any given backend process. +

E.86.3.10. PL/Python Server-Side Language Changes

  • Named parameters are passed as ordinary variables, as well as in the + args[] array (Sven Suursoho) +

  • Add table_name and table_schema to + trigger parameters (Andrew) +

  • Allow returning of composite types and result sets (Sven Suursoho) +

  • Return result-set as list, iterator, + or generator (Sven Suursoho) +

  • Allow functions to return void (Neil) +

  • Python 2.5 is now supported (Tom) +

E.86.3.11. psql Changes

  • Add new command \password for changing role + password with client-side password encryption (Peter) +

  • Allow \c to connect to a new host and port + number (David, Volkan YAZICI) +

  • Add tablespace display to \l+ (Philip Yarra) +

  • Improve \df slash command to include the argument + names and modes (OUT or INOUT) of + the function (David Fetter) +

  • Support binary COPY (Andreas Pflug) +

  • Add option to run the entire session in a single transaction + (Simon) +

    Use option -1 or --single-transaction. +

  • Support for automatically retrieving SELECT + results in batches using a cursor (Chris Mair) +

    This is enabled using \set FETCH_COUNT + n. This + feature allows large result sets to be retrieved in + psql without attempting to buffer the entire + result set in memory. +

  • Make multi-line values align in the proper column + (Martijn van Oosterhout) +

    Field values containing newlines are now displayed in a more + readable fashion. +

  • Save multi-line statements as a single entry, rather than + one line at a time (Sergey E. Koposov) +

    This makes up-arrow recall of queries easier. (This is + not available on Windows, because that platform uses the native + command-line editing present in the operating system.) +

  • Make the line counter 64-bit so it can handle files with more + than two billion lines (David Fetter) +

  • Report both the returned data and the command status tag + for INSERT/UPDATE/DELETE + RETURNING (Tom) +

E.86.3.12. pg_dump Changes

  • Allow complex selection of objects to be included or excluded + by pg_dump (Greg Sabino Mullane) +

    pg_dump now supports multiple -n + (schema) and -t (table) options, and adds + -N and -T options to exclude objects. + Also, the arguments of these switches can now be wild-card expressions + rather than single object names, for example + -t 'foo*', and a schema can be part of + a -t or -T switch, for example + -t schema1.table1. +

  • Add pg_restore + --no-data-for-failed-tables option to suppress + loading data if table creation failed (i.e., the table already + exists) (Martin Pitt) +

  • Add pg_restore + option to run the entire session in a single transaction + (Simon) +

    Use option -1 or --single-transaction. +

E.86.3.13. libpq Changes

  • Add PQencryptPassword() + to encrypt passwords (Tom) +

    This allows passwords to be sent pre-encrypted for commands + like ALTER ROLE ... + PASSWORD. +

  • Add function PQisthreadsafe() + (Bruce) +

    This allows applications to query the thread-safety status + of the library. +

  • Add PQdescribePrepared(), + PQdescribePortal(), + and related functions to return information about previously + prepared statements and open cursors (Volkan YAZICI) +

  • Allow LDAP lookups + from pg_service.conf + (Laurenz Albe) +

  • Allow a hostname in ~/.pgpass + to match the default socket directory (Bruce) +

    A blank hostname continues to match any Unix-socket connection, + but this addition allows entries that are specific to one of + several postmasters on the machine. +

E.86.3.14. ecpg Changes

  • Allow SHOW to + put its result into a variable (Joachim Wieland) +

  • Add COPY TO STDOUT + (Joachim Wieland) +

  • Add regression tests (Joachim Wieland, Michael) +

  • Major source code cleanups (Joachim Wieland, Michael) +

E.86.3.15. Windows Port

  • Allow MSVC to compile the PostgreSQL + server (Magnus, Hiroshi Saito) +

  • Add MSVC support for utility commands and pg_dump (Hiroshi + Saito) +

  • Add support for Windows code pages 1253, + 1254, 1255, and 1257 + (Kris Jurka) +

  • Drop privileges on startup, so that the server can be started from + an administrative account (Magnus) +

  • Stability fixes (Qingqing Zhou, Magnus) +

  • Add native semaphore implementation (Qingqing Zhou) +

    The previous code mimicked SysV semaphores. +

E.86.3.16. Source Code Changes

  • Add GIN (Generalized + Inverted iNdex) index access method (Teodor, Oleg) +

  • Remove R-tree indexing (Tom) +

    Rtree has been re-implemented using GiST. Among other + differences, this means that rtree indexes now have support + for crash recovery via write-ahead logging (WAL). +

  • Reduce libraries needlessly linked into the backend (Martijn + van Oosterhout, Tom) +

  • Add a configure flag to allow libedit to be preferred over + GNU readline (Bruce) +

    Use configure --with-libedit-preferred. +

  • Allow installation into directories containing spaces + (Peter) +

  • Improve ability to relocate installation directories (Tom) +

  • Add support for Solaris x86_64 using the + Solaris compiler (Pierre Girard, Theo + Schlossnagle, Bruce) +

  • Add DTrace support (Robert Lor) +

  • Add PG_VERSION_NUM for use by third-party + applications wanting to test the backend version in C using > + and < comparisons (Bruce) +

  • Add XLOG_BLCKSZ as independent from BLCKSZ + (Mark Wong) +

  • Add LWLOCK_STATS define to report locking + activity (Tom) +

  • Emit warnings for unknown configure options + (Martijn van Oosterhout) +

  • Add server support for "plugin" libraries + that can be used for add-on tasks such as debugging and performance + measurement (Korry Douglas) +

    This consists of two features: a table of "rendezvous + variables" that allows separately-loaded shared libraries to + communicate, and a new configuration parameter local_preload_libraries + that allows libraries to be loaded into specific sessions without + explicit cooperation from the client application. This allows + external add-ons to implement features such as a PL/pgSQL debugger. +

  • Rename existing configuration parameter + preload_libraries to shared_preload_libraries + (Tom) +

    This was done for clarity in comparison to + local_preload_libraries. +

  • Add new configuration parameter server_version_num + (Greg Sabino Mullane) +

    This is like server_version, but is an + integer, e.g. 80200. This allows applications to + make version checks more easily. +

  • Add a configuration parameter seq_page_cost + (Tom) +

  • Re-implement the regression test script as a C program + (Magnus, Tom) +

  • Allow loadable modules to allocate shared memory and + lightweight locks (Marc Munro) +

  • Add automatic initialization and finalization of dynamically + loaded libraries (Ralf Engelschall, Tom) +

    New functions + _PG_init() and _PG_fini() are + called if the library defines such symbols. Hence we no + longer need to specify an initialization function in + shared_preload_libraries; we can assume that + the library used the _PG_init() convention + instead. +

  • Add PG_MODULE_MAGIC + header block to all shared object files (Martijn van + Oosterhout) +

    The magic block prevents version mismatches between loadable object + files and servers. +

  • Add shared library support for AIX (Laurenz Albe) +

  • New XML + documentation section (Bruce) +

E.86.3.17. Contrib Changes

  • Major tsearch2 improvements (Oleg, Teodor) +

    • multibyte encoding support, including UTF8 +

    • query rewriting support +

    • improved ranking functions +

    • thesaurus dictionary support +

    • Ispell dictionaries now recognize MySpell + format, used by OpenOffice +

    • GIN support +

  • Add adminpack module containing Pgadmin administration + functions (Dave) +

    These functions provide additional file system access + routines not present in the default PostgreSQL + server. +

  • Add sslinfo module (Victor Wagner) +

    Reports information about the current connection's SSL + certificate. +

  • Add pgrowlocks module (Tatsuo) +

    This shows row locking information for a specified table. +

  • Add hstore module (Oleg, Teodor) +

  • Add isn module, replacing isbn_issn (Jeremy Kronuz) +

    This new implementation supports EAN13, UPC, + ISBN (books), ISMN (music), and + ISSN (serials). +

  • Add index information functions to pgstattuple (ITAGAKI Takahiro, + Satoshi Nagayasu) +

  • Add pg_freespacemap module to display free space map information + (Mark Kirkwood) +

  • pgcrypto now has all planned functionality (Marko Kreen) +

    • Include iMath library in pgcrypto to have the public-key encryption + functions always available. +

    • Add SHA224 algorithm that was missing in OpenBSD code. +

    • Activate builtin code for SHA224/256/384/512 hashes on older + OpenSSL to have those algorithms always available. +

    • New function gen_random_bytes() that returns cryptographically strong + randomness. Useful for generating encryption keys. +

    • Remove digest_exists(), hmac_exists() and cipher_exists() functions. +

  • Improvements to cube module (Joshua Reich) +

    New functions are cube(float[]), + cube(float[], float[]), and + cube_subset(cube, int4[]). +

  • Add async query capability to dblink (Kai Londenberg, + Joe Conway) +

  • New operators for array-subset comparisons (@>, + <@, &&) (Tom) +

    Various contrib packages already had these operators for their + datatypes, but the naming wasn't consistent. We have now added + consistently named array-subset comparison operators to the core code + and all the contrib packages that have such functionality. + (The old names remain available, but are deprecated.) +

  • Add uninstall scripts for all contrib packages that have install + scripts (David, Josh Drake) +


PrevHomeNext
Release 8.2.1UpRelease 8.1.23
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-3-1.html b/doc/src/sgml/html/release-8-3-1.html new file mode 100644 index 000000000..b4a5ac92c --- /dev/null +++ b/doc/src/sgml/html/release-8-3-1.html @@ -0,0 +1,577 @@ + +Release 8.3.1

E.61. Release 8.3.1

Release Date: 2008-03-17

This release contains a variety of fixes from 8.3.0. + For information about new features in the 8.3 major release, see + Section E.62. +

E.61.1. Migration to Version 8.3.1

A dump/restore is not required for those running 8.3.X. + However, you might need to REINDEX indexes on textual + columns after updating, if you are affected by the Windows locale + issue described below. +

E.61.2. Changes

  • Fix character string comparison for Windows locales that consider + different character combinations as equal (Tom) +

    This fix applies only on Windows and only when using UTF-8 + database encoding. The same fix was made for all other cases + over two years ago, but Windows with UTF-8 uses a separate code + path that was not updated. If you are using a locale that + considers some non-identical strings as equal, you may need to + REINDEX to fix existing indexes on textual columns. +

  • Repair corner-case bugs in VACUUM FULL (Tom) +

    A potential deadlock between concurrent VACUUM FULL + operations on different system catalogs was introduced in 8.2. + This has now been corrected. 8.3 made this worse because the + deadlock could occur within a critical code section, making it + a PANIC rather than just ERROR condition. +

    Also, a VACUUM FULL that failed partway through + vacuuming a system catalog could result in cache corruption in + concurrent database sessions. +

    Another VACUUM FULL bug introduced in 8.3 could + result in a crash or out-of-memory report when dealing with + pages containing no live tuples. +

  • Fix misbehavior of foreign key checks involving character + or bit columns (Tom) +

    If the referencing column were of a different but compatible type + (for instance varchar), the constraint was enforced incorrectly. +

  • Avoid needless deadlock failures in no-op foreign-key checks (Stephan + Szabo, Tom) +

  • Fix possible core dump when re-planning a prepared query (Tom) +

    This bug affected only protocol-level prepare operations, not + SQL PREPARE, and so tended to be seen only with + JDBC, DBI, and other client-side drivers that use prepared + statements heavily. +

  • Fix possible failure when re-planning a query that calls an SPI-using + function (Tom) +

  • Fix failure in row-wise comparisons involving columns of different + datatypes (Tom) +

  • Fix longstanding LISTEN/NOTIFY + race condition (Tom) +

    In rare cases a session that had just executed a + LISTEN might not get a notification, even though + one would be expected because the concurrent transaction executing + NOTIFY was observed to commit later. +

    A side effect of the fix is that a transaction that has executed + a not-yet-committed LISTEN command will not see any + row in pg_listener for the LISTEN, + should it choose to look; formerly it would have. This behavior + was never documented one way or the other, but it is possible that + some applications depend on the old behavior. +

  • Disallow LISTEN and UNLISTEN within a + prepared transaction (Tom) +

    This was formerly allowed but trying to do it had various unpleasant + consequences, notably that the originating backend could not exit + as long as an UNLISTEN remained uncommitted. +

  • Disallow dropping a temporary table within a + prepared transaction (Heikki) +

    This was correctly disallowed by 8.1, but the check was inadvertently + broken in 8.2 and 8.3. +

  • Fix rare crash when an error occurs during a query using a hash index + (Heikki) +

  • Fix incorrect comparison of tsquery values (Teodor) +

  • Fix incorrect behavior of LIKE with non-ASCII characters + in single-byte encodings (Rolf Jentsch) +

  • Disable xmlvalidate (Tom) +

    This function should have been removed before 8.3 release, but + was inadvertently left in the source code. It poses a small + security risk since unprivileged users could use it to read the + first few characters of any file accessible to the server. +

  • Fix memory leaks in certain usages of set-returning functions (Neil) +

  • Make encode(bytea, 'escape') convert all + high-bit-set byte values into \nnn octal + escape sequences (Tom) +

    This is necessary to avoid encoding problems when the database + encoding is multi-byte. This change could pose compatibility issues + for applications that are expecting specific results from + encode. +

  • Fix input of datetime values for February 29 in years BC (Tom) +

    The former coding was mistaken about which years were leap years. +

  • Fix "unrecognized node type" error in some variants of + ALTER OWNER (Tom) +

  • Avoid tablespace permissions errors in CREATE TABLE LIKE + INCLUDING INDEXES (Tom) +

  • Ensure pg_stat_activity.waiting flag + is cleared when a lock wait is aborted (Tom) +

  • Fix handling of process permissions on Windows Vista (Dave, Magnus) +

    In particular, this fix allows starting the server as the Administrator + user. +

  • Update time zone data files to tzdata release 2008a + (in particular, recent Chile changes); adjust timezone abbreviation + VET (Venezuela) to mean UTC-4:30, not UTC-4:00 (Tom) +

  • Fix ecpg problems with arrays (Michael) +

  • Fix pg_ctl to correctly extract the postmaster's port + number from command-line options (Itagaki Takahiro, Tom) +

    Previously, pg_ctl start -w could try to contact the + postmaster on the wrong port, leading to bogus reports of startup + failure. +

  • Use -fwrapv to defend against possible misoptimization + in recent gcc versions (Tom) +

    This is known to be necessary when building PostgreSQL + with gcc 4.3 or later. +

  • Enable building contrib/uuid-ossp with MSVC (Hiroshi Saito) +


PrevHomeNext
Release 8.3.2UpRelease 8.3
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-3-10.html b/doc/src/sgml/html/release-8-3-10.html new file mode 100644 index 000000000..c2ea1c0aa --- /dev/null +++ b/doc/src/sgml/html/release-8-3-10.html @@ -0,0 +1,569 @@ + +Release 8.3.10

E.52. Release 8.3.10

Release Date: 2010-03-15

This release contains a variety of fixes from 8.3.9. + For information about new features in the 8.3 major release, see + Section E.62. +

E.52.1. Migration to Version 8.3.10

A dump/restore is not required for those running 8.3.X. + However, if you are upgrading from a version earlier than 8.3.8, + see the release notes for 8.3.8. +

E.52.2. Changes

  • Add new configuration parameter ssl_renegotiation_limit to + control how often we do session key renegotiation for an SSL connection + (Magnus) +

    This can be set to zero to disable renegotiation completely, which may + be required if a broken SSL library is used. In particular, some + vendors are shipping stopgap patches for CVE-2009-3555 that cause + renegotiation attempts to fail. +

  • Fix possible deadlock during backend startup (Tom) +

  • Fix possible crashes due to not handling errors during relcache reload + cleanly (Tom) +

  • Fix possible crash due to use of dangling pointer to a cached plan + (Tatsuo) +

  • Fix possible crashes when trying to recover from a failure in + subtransaction start (Tom) +

  • Fix server memory leak associated with use of savepoints and a client + encoding different from server's encoding (Tom) +

  • Fix incorrect WAL data emitted during end-of-recovery cleanup of a GIST + index page split (Yoichi Hirai) +

    This would result in index corruption, or even more likely an error + during WAL replay, if we were unlucky enough to crash during + end-of-recovery cleanup after having completed an incomplete GIST + insertion. +

  • Make substring() for bit types treat any negative + length as meaning "all the rest of the string" (Tom) +

    The previous coding treated only -1 that way, and would produce an + invalid result value for other negative values, possibly leading to + a crash (CVE-2010-0442). +

  • Fix integer-to-bit-string conversions to handle the first fractional + byte correctly when the output bit width is wider than the given + integer by something other than a multiple of 8 bits (Tom) +

  • Fix some cases of pathologically slow regular expression matching (Tom) +

  • Fix assorted crashes in xml processing caused by sloppy + memory management (Tom) +

    This is a back-patch of changes first applied in 8.4. The 8.3 code + was known buggy, but the new code was sufficiently different to not + want to back-patch it until it had gotten some field testing. +

  • Fix bug with trying to update a field of an element of a + composite-type array column (Tom) +

  • Fix the STOP WAL LOCATION entry in backup history files to + report the next WAL segment's name when the end location is exactly at a + segment boundary (Itagaki Takahiro) +

  • Fix some more cases of temporary-file leakage (Heikki) +

    This corrects a problem introduced in the previous minor release. + One case that failed is when a plpgsql function returning set is + called within another function's exception handler. +

  • Improve constraint exclusion processing of boolean-variable cases, + in particular make it possible to exclude a partition that has a + "bool_column = false" constraint (Tom) +

  • When reading pg_hba.conf and related files, do not treat + @something as a file inclusion request if the @ + appears inside quote marks; also, never treat @ by itself + as a file inclusion request (Tom) +

    This prevents erratic behavior if a role or database name starts with + @. If you need to include a file whose path name + contains spaces, you can still do so, but you must write + @"/path to/file" rather than putting the quotes around + the whole construct. +

  • Prevent infinite loop on some platforms if a directory is named as + an inclusion target in pg_hba.conf and related files + (Tom) +

  • Fix possible infinite loop if SSL_read or + SSL_write fails without setting errno (Tom) +

    This is reportedly possible with some Windows versions of + openssl. +

  • Disallow GSSAPI authentication on local connections, + since it requires a hostname to function correctly (Magnus) +

  • Make ecpg report the proper SQLSTATE if the connection + disappears (Michael) +

  • Fix psql's numericlocale option to not + format strings it shouldn't in latex and troff output formats (Heikki) +

  • Make psql return the correct exit status (3) when + ON_ERROR_STOP and --single-transaction are + both specified and an error occurs during the implied COMMIT + (Bruce) +

  • Fix plpgsql failure in one case where a composite column is set to NULL + (Tom) +

  • Fix possible failure when calling PL/Perl functions from PL/PerlU + or vice versa (Tim Bunce) +

  • Add volatile markings in PL/Python to avoid possible + compiler-specific misbehavior (Zdenek Kotala) +

  • Ensure PL/Tcl initializes the Tcl interpreter fully (Tom) +

    The only known symptom of this oversight is that the Tcl + clock command misbehaves if using Tcl 8.5 or later. +

  • Prevent crash in contrib/dblink when too many key + columns are specified to a dblink_build_sql_* function + (Rushabh Lathia, Joe Conway) +

  • Allow zero-dimensional arrays in contrib/ltree operations + (Tom) +

    This case was formerly rejected as an error, but it's more convenient to + treat it the same as a zero-element array. In particular this avoids + unnecessary failures when an ltree operation is applied to the + result of ARRAY(SELECT ...) and the sub-select returns no + rows. +

  • Fix assorted crashes in contrib/xml2 caused by sloppy + memory management (Tom) +

  • Make building of contrib/xml2 more robust on Windows + (Andrew) +

  • Fix race condition in Windows signal handling (Radu Ilie) +

    One known symptom of this bug is that rows in pg_listener + could be dropped under heavy load. +

  • Update time zone data files to tzdata release 2010e + for DST law changes in Bangladesh, Chile, Fiji, Mexico, Paraguay, Samoa. +


PrevHomeNext
Release 8.3.11UpRelease 8.3.9
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-3-11.html b/doc/src/sgml/html/release-8-3-11.html new file mode 100644 index 000000000..502c56e14 --- /dev/null +++ b/doc/src/sgml/html/release-8-3-11.html @@ -0,0 +1,468 @@ + +Release 8.3.11

E.51. Release 8.3.11

Release Date: 2010-05-17

This release contains a variety of fixes from 8.3.10. + For information about new features in the 8.3 major release, see + Section E.62. +

E.51.1. Migration to Version 8.3.11

A dump/restore is not required for those running 8.3.X. + However, if you are upgrading from a version earlier than 8.3.8, + see the release notes for 8.3.8. +

E.51.2. Changes

  • Enforce restrictions in plperl using an opmask applied to + the whole interpreter, instead of using Safe.pm + (Tim Bunce, Andrew Dunstan) +

    Recent developments have convinced us that Safe.pm is too + insecure to rely on for making plperl trustable. This + change removes use of Safe.pm altogether, in favor of using + a separate interpreter with an opcode mask that is always applied. + Pleasant side effects of the change include that it is now possible to + use Perl's strict pragma in a natural way in + plperl, and that Perl's $a and $b + variables work as expected in sort routines, and that function + compilation is significantly faster. (CVE-2010-1169) +

  • Prevent PL/Tcl from executing untrustworthy code from + pltcl_modules (Tom) +

    PL/Tcl's feature for autoloading Tcl code from a database table + could be exploited for trojan-horse attacks, because there was no + restriction on who could create or insert into that table. This change + disables the feature unless pltcl_modules is owned by a + superuser. (However, the permissions on the table are not checked, so + installations that really need a less-than-secure modules table can + still grant suitable privileges to trusted non-superusers.) Also, + prevent loading code into the unrestricted "normal" Tcl + interpreter unless we are really going to execute a pltclu + function. (CVE-2010-1170) +

  • Fix possible crash if a cache reset message is received during + rebuild of a relcache entry (Heikki) +

    This error was introduced in 8.3.10 while fixing a related failure. +

  • Apply per-function GUC settings while running the language validator + for the function (Itagaki Takahiro) +

    This avoids failures if the function's code is invalid without the + setting; an example is that SQL functions may not parse if the + search_path is not correct. +

  • Do not allow an unprivileged user to reset superuser-only parameter + settings (Alvaro) +

    Previously, if an unprivileged user ran ALTER USER ... RESET + ALL for himself, or ALTER DATABASE ... RESET ALL for + a database he owns, this would remove all special parameter settings + for the user or database, even ones that are only supposed to be + changeable by a superuser. Now, the ALTER will only + remove the parameters that the user has permission to change. +

  • Avoid possible crash during backend shutdown if shutdown occurs + when a CONTEXT addition would be made to log entries (Tom) +

    In some cases the context-printing function would fail because the + current transaction had already been rolled back when it came time + to print a log message. +

  • Ensure the archiver process responds to changes in + archive_command as soon as possible (Tom) +

  • Update pl/perl's ppport.h for modern Perl versions + (Andrew) +

  • Fix assorted memory leaks in pl/python (Andreas Freund, Tom) +

  • Prevent infinite recursion in psql when expanding + a variable that refers to itself (Tom) +

  • Fix psql's \copy to not add spaces around + a dot within \copy (select ...) (Tom) +

    Addition of spaces around the decimal point in a numeric literal would + result in a syntax error. +

  • Fix unnecessary "GIN indexes do not support whole-index scans" + errors for unsatisfiable queries using contrib/intarray + operators (Tom) +

  • Ensure that contrib/pgstattuple functions respond to cancel + interrupts promptly (Tatsuhito Kasahara) +

  • Make server startup deal properly with the case that + shmget() returns EINVAL for an existing + shared memory segment (Tom) +

    This behavior has been observed on BSD-derived kernels including OS X. + It resulted in an entirely-misleading startup failure complaining that + the shared memory request size was too large. +

  • Avoid possible crashes in syslogger process on Windows (Heikki) +

  • Deal more robustly with incomplete time zone information in the + Windows registry (Magnus) +

  • Update the set of known Windows time zone names (Magnus) +

  • Update time zone data files to tzdata release 2010j + for DST law changes in Argentina, Australian Antarctic, Bangladesh, + Mexico, Morocco, Pakistan, Palestine, Russia, Syria, Tunisia; + also historical corrections for Taiwan. +

    Also, add PKST (Pakistan Summer Time) to the default set of + timezone abbreviations. +


PrevHomeNext
Release 8.3.12UpRelease 8.3.10
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-3-12.html b/doc/src/sgml/html/release-8-3-12.html new file mode 100644 index 000000000..254376451 --- /dev/null +++ b/doc/src/sgml/html/release-8-3-12.html @@ -0,0 +1,590 @@ + +Release 8.3.12

E.50. Release 8.3.12

Release Date: 2010-10-04

This release contains a variety of fixes from 8.3.11. + For information about new features in the 8.3 major release, see + Section E.62. +

E.50.1. Migration to Version 8.3.12

A dump/restore is not required for those running 8.3.X. + However, if you are upgrading from a version earlier than 8.3.8, + see the release notes for 8.3.8. +

E.50.2. Changes

  • Use a separate interpreter for each calling SQL userid in PL/Perl and + PL/Tcl (Tom Lane) +

    This change prevents security problems that can be caused by subverting + Perl or Tcl code that will be executed later in the same session under + another SQL user identity (for example, within a SECURITY + DEFINER function). Most scripting languages offer numerous ways that + that might be done, such as redefining standard functions or operators + called by the target function. Without this change, any SQL user with + Perl or Tcl language usage rights can do essentially anything with the + SQL privileges of the target function's owner. +

    The cost of this change is that intentional communication among Perl + and Tcl functions becomes more difficult. To provide an escape hatch, + PL/PerlU and PL/TclU functions continue to use only one interpreter + per session. This is not considered a security issue since all such + functions execute at the trust level of a database superuser already. +

    It is likely that third-party procedural languages that claim to offer + trusted execution have similar security issues. We advise contacting + the authors of any PL you are depending on for security-critical + purposes. +

    Our thanks to Tim Bunce for pointing out this issue (CVE-2010-3433). +

  • Prevent possible crashes in pg_get_expr() by disallowing + it from being called with an argument that is not one of the system + catalog columns it's intended to be used with + (Heikki Linnakangas, Tom Lane) +

  • Treat exit code 128 (ERROR_WAIT_NO_CHILDREN) as non-fatal on + Windows (Magnus Hagander) +

    Under high load, Windows processes will sometimes fail at startup with + this error code. Formerly the postmaster treated this as a panic + condition and restarted the whole database, but that seems to be + an overreaction. +

  • Fix incorrect usage of non-strict OR joinclauses in Append indexscans + (Tom Lane) +

    This is a back-patch of an 8.4 fix that was missed in the 8.3 branch. + This corrects an error introduced in 8.3.8 that could cause incorrect + results for outer joins when the inner relation is an inheritance tree + or UNION ALL subquery. +

  • Fix possible duplicate scans of UNION ALL member relations + (Tom Lane) +

  • Fix "cannot handle unplanned sub-select" error (Tom Lane) +

    This occurred when a sub-select contains a join alias reference that + expands into an expression containing another sub-select. +

  • Fix failure to mark cached plans as transient (Tom Lane) +

    If a plan is prepared while CREATE INDEX CONCURRENTLY is + in progress for one of the referenced tables, it is supposed to be + re-planned once the index is ready for use. This was not happening + reliably. +

  • Reduce PANIC to ERROR in some occasionally-reported btree failure cases, + and provide additional detail in the resulting error messages + (Tom Lane) +

    This should improve the system's robustness with corrupted indexes. +

  • Prevent show_session_authorization() from crashing within autovacuum + processes (Tom Lane) +

  • Defend against functions returning setof record where not all the + returned rows are actually of the same rowtype (Tom Lane) +

  • Fix possible failure when hashing a pass-by-reference function result + (Tao Ma, Tom Lane) +

  • Improve merge join's handling of NULLs in the join columns (Tom Lane) +

    A merge join can now stop entirely upon reaching the first NULL, + if the sort order is such that NULLs sort high. +

  • Take care to fsync the contents of lockfiles (both + postmaster.pid and the socket lockfile) while writing them + (Tom Lane) +

    This omission could result in corrupted lockfile contents if the + machine crashes shortly after postmaster start. That could in turn + prevent subsequent attempts to start the postmaster from succeeding, + until the lockfile is manually removed. +

  • Avoid recursion while assigning XIDs to heavily-nested + subtransactions (Andres Freund, Robert Haas) +

    The original coding could result in a crash if there was limited + stack space. +

  • Avoid holding open old WAL segments in the walwriter process + (Magnus Hagander, Heikki Linnakangas) +

    The previous coding would prevent removal of no-longer-needed segments. +

  • Fix log_line_prefix's %i escape, + which could produce junk early in backend startup (Tom Lane) +

  • Fix possible data corruption in ALTER TABLE ... SET + TABLESPACE when archiving is enabled (Jeff Davis) +

  • Allow CREATE DATABASE and ALTER DATABASE ... SET + TABLESPACE to be interrupted by query-cancel (Guillaume Lelarge) +

  • Fix REASSIGN OWNED to handle operator classes and families + (Asko Tiidumaa) +

  • Fix possible core dump when comparing two empty tsquery values + (Tom Lane) +

  • Fix LIKE's handling of patterns containing % + followed by _ (Tom Lane) +

    We've fixed this before, but there were still some incorrectly-handled + cases. +

  • In PL/Python, defend against null pointer results from + PyCObject_AsVoidPtr and PyCObject_FromVoidPtr + (Peter Eisentraut) +

  • Make psql recognize DISCARD ALL as a command that should + not be encased in a transaction block in autocommit-off mode + (Itagaki Takahiro) +

  • Fix ecpg to process data from RETURNING + clauses correctly (Michael Meskes) +

  • Improve contrib/dblink's handling of tables containing + dropped columns (Tom Lane) +

  • Fix connection leak after "duplicate connection name" + errors in contrib/dblink (Itagaki Takahiro) +

  • Fix contrib/dblink to handle connection names longer than + 62 bytes correctly (Itagaki Takahiro) +

  • Add hstore(text, text) + function to contrib/hstore (Robert Haas) +

    This function is the recommended substitute for the now-deprecated + => operator. It was back-patched so that future-proofed + code can be used with older server versions. Note that the patch will + be effective only after contrib/hstore is installed or + reinstalled in a particular database. Users might prefer to execute + the CREATE FUNCTION command by hand, instead. +

  • Update build infrastructure and documentation to reflect the source code + repository's move from CVS to Git (Magnus Hagander and others) +

  • Update time zone data files to tzdata release 2010l + for DST law changes in Egypt and Palestine; also historical corrections + for Finland. +

    This change also adds new names for two Micronesian timezones: + Pacific/Chuuk is now preferred over Pacific/Truk (and the preferred + abbreviation is CHUT not TRUT) and Pacific/Pohnpei is preferred over + Pacific/Ponape. +

  • Make Windows' "N. Central Asia Standard Time" timezone map to + Asia/Novosibirsk, not Asia/Almaty (Magnus Hagander) +

    Microsoft changed the DST behavior of this zone in the timezone update + from KB976098. Asia/Novosibirsk is a better match to its new behavior. +


PrevHomeNext
Release 8.3.13UpRelease 8.3.11
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-3-13.html b/doc/src/sgml/html/release-8-3-13.html new file mode 100644 index 000000000..873de4b5f --- /dev/null +++ b/doc/src/sgml/html/release-8-3-13.html @@ -0,0 +1,534 @@ + +Release 8.3.13

E.49. Release 8.3.13

Release Date: 2010-12-16

This release contains a variety of fixes from 8.3.12. + For information about new features in the 8.3 major release, see + Section E.62. +

E.49.1. Migration to Version 8.3.13

A dump/restore is not required for those running 8.3.X. + However, if you are upgrading from a version earlier than 8.3.8, + see the release notes for 8.3.8. +

E.49.2. Changes

  • Force the default + wal_sync_method + to be fdatasync on Linux (Tom Lane, Marti Raudsepp) +

    The default on Linux has actually been fdatasync for many + years, but recent kernel changes caused PostgreSQL to + choose open_datasync instead. This choice did not result + in any performance improvement, and caused outright failures on + certain filesystems, notably ext4 with the + data=journal mount option. +

  • Fix assorted bugs in WAL replay logic for GIN indexes (Tom Lane) +

    This could result in "bad buffer id: 0" failures or + corruption of index contents during replication. +

  • Fix recovery from base backup when the starting checkpoint WAL record + is not in the same WAL segment as its redo point (Jeff Davis) +

  • Fix persistent slowdown of autovacuum workers when multiple workers + remain active for a long time (Tom Lane) +

    The effective vacuum_cost_limit for an autovacuum worker + could drop to nearly zero if it processed enough tables, causing it + to run extremely slowly. +

  • Add support for detecting register-stack overrun on IA64 + (Tom Lane) +

    The IA64 architecture has two hardware stacks. Full + prevention of stack-overrun failures requires checking both. +

  • Add a check for stack overflow in copyObject() (Tom Lane) +

    Certain code paths could crash due to stack overflow given a + sufficiently complex query. +

  • Fix detection of page splits in temporary GiST indexes (Heikki + Linnakangas) +

    It is possible to have a "concurrent" page split in a + temporary index, if for example there is an open cursor scanning the + index when an insertion is done. GiST failed to detect this case and + hence could deliver wrong results when execution of the cursor + continued. +

  • Avoid memory leakage while ANALYZE'ing complex index + expressions (Tom Lane) +

  • Ensure an index that uses a whole-row Var still depends on its table + (Tom Lane) +

    An index declared like create index i on t (foo(t.*)) + would not automatically get dropped when its table was dropped. +

  • Do not "inline" a SQL function with multiple OUT + parameters (Tom Lane) +

    This avoids a possible crash due to loss of information about the + expected result rowtype. +

  • Behave correctly if ORDER BY, LIMIT, + FOR UPDATE, or WITH is attached to the + VALUES part of INSERT ... VALUES (Tom Lane) +

  • Fix constant-folding of COALESCE() expressions (Tom Lane) +

    The planner would sometimes attempt to evaluate sub-expressions that + in fact could never be reached, possibly leading to unexpected errors. +

  • Fix postmaster crash when connection acceptance + (accept() or one of the calls made immediately after it) + fails, and the postmaster was compiled with GSSAPI support (Alexander + Chernikov) +

  • Fix missed unlink of temporary files when log_temp_files + is active (Tom Lane) +

    If an error occurred while attempting to emit the log message, the + unlink was not done, resulting in accumulation of temp files. +

  • Add print functionality for InhRelation nodes (Tom Lane) +

    This avoids a failure when debug_print_parse is enabled + and certain types of query are executed. +

  • Fix incorrect calculation of distance from a point to a horizontal + line segment (Tom Lane) +

    This bug affected several different geometric distance-measurement + operators. +

  • Fix PL/pgSQL's handling of "simple" + expressions to not fail in recursion or error-recovery cases (Tom Lane) +

  • Fix PL/Python's handling of set-returning functions + (Jan Urbanski) +

    Attempts to call SPI functions within the iterator generating a set + result would fail. +

  • Fix bug in contrib/cube's GiST picksplit algorithm + (Alexander Korotkov) +

    This could result in considerable inefficiency, though not actually + incorrect answers, in a GiST index on a cube column. + If you have such an index, consider REINDEXing it after + installing this update. +

  • Don't emit "identifier will be truncated" notices in + contrib/dblink except when creating new connections + (Itagaki Takahiro) +

  • Fix potential coredump on missing public key in + contrib/pgcrypto (Marti Raudsepp) +

  • Fix memory leak in contrib/xml2's XPath query functions + (Tom Lane) +

  • Update time zone data files to tzdata release 2010o + for DST law changes in Fiji and Samoa; + also historical corrections for Hong Kong. +


PrevHomeNext
Release 8.3.14UpRelease 8.3.12
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-3-14.html b/doc/src/sgml/html/release-8-3-14.html new file mode 100644 index 000000000..b31d0efa6 --- /dev/null +++ b/doc/src/sgml/html/release-8-3-14.html @@ -0,0 +1,360 @@ + +Release 8.3.14

E.48. Release 8.3.14

Release Date: 2011-01-31

This release contains a variety of fixes from 8.3.13. + For information about new features in the 8.3 major release, see + Section E.62. +

E.48.1. Migration to Version 8.3.14

A dump/restore is not required for those running 8.3.X. + However, if you are upgrading from a version earlier than 8.3.8, + see the release notes for 8.3.8. +

E.48.2. Changes

  • Avoid failures when EXPLAIN tries to display a simple-form + CASE expression (Tom Lane) +

    If the CASE's test expression was a constant, the planner + could simplify the CASE into a form that confused the + expression-display code, resulting in "unexpected CASE WHEN + clause" errors. +

  • Fix assignment to an array slice that is before the existing range + of subscripts (Tom Lane) +

    If there was a gap between the newly added subscripts and the first + pre-existing subscript, the code miscalculated how many entries needed + to be copied from the old array's null bitmap, potentially leading to + data corruption or crash. +

  • Avoid unexpected conversion overflow in planner for very distant date + values (Tom Lane) +

    The date type supports a wider range of dates than can be + represented by the timestamp types, but the planner assumed it + could always convert a date to timestamp with impunity. +

  • Fix pg_restore's text output for large objects (BLOBs) + when standard_conforming_strings is on (Tom Lane) +

    Although restoring directly to a database worked correctly, string + escaping was incorrect if pg_restore was asked for + SQL text output and standard_conforming_strings had been + enabled in the source database. +

  • Fix erroneous parsing of tsquery values containing + ... & !(subexpression) | ... (Tom Lane) +

    Queries containing this combination of operators were not executed + correctly. The same error existed in contrib/intarray's + query_int type and contrib/ltree's + ltxtquery type. +

  • Fix buffer overrun in contrib/intarray's input function + for the query_int type (Apple) +

    This bug is a security risk since the function's return address could + be overwritten. Thanks to Apple Inc's security team for reporting this + issue and supplying the fix. (CVE-2010-4015) +

  • Fix bug in contrib/seg's GiST picksplit algorithm + (Alexander Korotkov) +

    This could result in considerable inefficiency, though not actually + incorrect answers, in a GiST index on a seg column. + If you have such an index, consider REINDEXing it after + installing this update. (This is identical to the bug that was fixed in + contrib/cube in the previous update.) +


PrevHomeNext
Release 8.3.15UpRelease 8.3.13
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-3-15.html b/doc/src/sgml/html/release-8-3-15.html new file mode 100644 index 000000000..47c0e9cca --- /dev/null +++ b/doc/src/sgml/html/release-8-3-15.html @@ -0,0 +1,350 @@ + +Release 8.3.15

E.47. Release 8.3.15

Release Date: 2011-04-18

This release contains a variety of fixes from 8.3.14. + For information about new features in the 8.3 major release, see + Section E.62. +

E.47.1. Migration to Version 8.3.15

A dump/restore is not required for those running 8.3.X. + However, if you are upgrading from a version earlier than 8.3.8, + see the release notes for 8.3.8. +

E.47.2. Changes

  • Disallow including a composite type in itself (Tom Lane) +

    This prevents scenarios wherein the server could recurse infinitely + while processing the composite type. While there are some possible + uses for such a structure, they don't seem compelling enough to + justify the effort required to make sure it always works safely. +

  • Avoid potential deadlock during catalog cache initialization + (Nikhil Sontakke) +

    In some cases the cache loading code would acquire share lock on a + system index before locking the index's catalog. This could deadlock + against processes trying to acquire exclusive locks in the other, + more standard order. +

  • Fix dangling-pointer problem in BEFORE ROW UPDATE trigger + handling when there was a concurrent update to the target tuple + (Tom Lane) +

    This bug has been observed to result in intermittent "cannot + extract system attribute from virtual tuple" failures while trying to + do UPDATE RETURNING ctid. There is a very small probability + of more serious errors, such as generating incorrect index entries for + the updated tuple. +

  • Disallow DROP TABLE when there are pending deferred trigger + events for the table (Tom Lane) +

    Formerly the DROP would go through, leading to + "could not open relation with OID nnn" errors when the + triggers were eventually fired. +

  • Fix PL/Python memory leak involving array slices (Daniel Popowich) +

  • Fix pg_restore to cope with long lines (over 1KB) in + TOC files (Tom Lane) +

  • Put in more safeguards against crashing due to division-by-zero + with overly enthusiastic compiler optimization (Aurelien Jarno) +

  • Support use of dlopen() in FreeBSD and OpenBSD on MIPS (Tom Lane) +

    There was a hard-wired assumption that this system function was not + available on MIPS hardware on these systems. Use a compile-time test + instead, since more recent versions have it. +

  • Fix compilation failures on HP-UX (Heikki Linnakangas) +

  • Fix version-incompatibility problem with libintl on + Windows (Hiroshi Inoue) +

  • Fix usage of xcopy in Windows build scripts to + work correctly under Windows 7 (Andrew Dunstan) +

    This affects the build scripts only, not installation or usage. +

  • Fix path separator used by pg_regress on Cygwin + (Andrew Dunstan) +

  • Update time zone data files to tzdata release 2011f + for DST law changes in Chile, Cuba, Falkland Islands, Morocco, Samoa, + and Turkey; also historical corrections for South Australia, Alaska, + and Hawaii. +


PrevHomeNext
Release 8.3.16UpRelease 8.3.14
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-3-16.html b/doc/src/sgml/html/release-8-3-16.html new file mode 100644 index 000000000..059eb68dd --- /dev/null +++ b/doc/src/sgml/html/release-8-3-16.html @@ -0,0 +1,611 @@ + +Release 8.3.16

E.46. Release 8.3.16

Release Date: 2011-09-26

This release contains a variety of fixes from 8.3.15. + For information about new features in the 8.3 major release, see + Section E.62. +

E.46.1. Migration to Version 8.3.16

A dump/restore is not required for those running 8.3.X. + However, if you are upgrading from a version earlier than 8.3.8, + see the release notes for 8.3.8. +

E.46.2. Changes

  • Fix bugs in indexing of in-doubt HOT-updated tuples (Tom Lane) +

    These bugs could result in index corruption after reindexing a system + catalog. They are not believed to affect user indexes. +

  • Fix multiple bugs in GiST index page split processing (Heikki + Linnakangas) +

    The probability of occurrence was low, but these could lead to index + corruption. +

  • Fix possible buffer overrun in tsvector_concat() + (Tom Lane) +

    The function could underestimate the amount of memory needed for its + result, leading to server crashes. +

  • Fix crash in xml_recv when processing a + "standalone" parameter (Tom Lane) +

  • Avoid possibly accessing off the end of memory in ANALYZE + and in SJIS-2004 encoding conversion (Noah Misch) +

    This fixes some very-low-probability server crash scenarios. +

  • Fix race condition in relcache init file invalidation (Tom Lane) +

    There was a window wherein a new backend process could read a stale init + file but miss the inval messages that would tell it the data is stale. + The result would be bizarre failures in catalog accesses, typically + "could not read block 0 in file ..." later during startup. +

  • Fix memory leak at end of a GiST index scan (Tom Lane) +

    Commands that perform many separate GiST index scans, such as + verification of a new GiST-based exclusion constraint on a table + already containing many rows, could transiently require large amounts of + memory due to this leak. +

  • Fix performance problem when constructing a large, lossy bitmap + (Tom Lane) +

  • Fix array- and path-creating functions to ensure padding bytes are + zeroes (Tom Lane) +

    This avoids some situations where the planner will think that + semantically-equal constants are not equal, resulting in poor + optimization. +

  • Work around gcc 4.6.0 bug that breaks WAL replay (Tom Lane) +

    This could lead to loss of committed transactions after a server crash. +

  • Fix dump bug for VALUES in a view (Tom Lane) +

  • Disallow SELECT FOR UPDATE/SHARE on sequences (Tom Lane) +

    This operation doesn't work as expected and can lead to failures. +

  • Defend against integer overflow when computing size of a hash table (Tom + Lane) +

  • Fix cases where CLUSTER might attempt to access + already-removed TOAST data (Tom Lane) +

  • Fix portability bugs in use of credentials control messages for + "peer" authentication (Tom Lane) +

  • Fix SSPI login when multiple roundtrips are required (Ahmed Shinwari, + Magnus Hagander) +

    The typical symptom of this problem was "The function requested is + not supported" errors during SSPI login. +

  • Fix typo in pg_srand48 seed initialization (Andres Freund) +

    This led to failure to use all bits of the provided seed. This function + is not used on most platforms (only those without srandom), + and the potential security exposure from a less-random-than-expected + seed seems minimal in any case. +

  • Avoid integer overflow when the sum of LIMIT and + OFFSET values exceeds 2^63 (Heikki Linnakangas) +

  • Add overflow checks to int4 and int8 versions of + generate_series() (Robert Haas) +

  • Fix trailing-zero removal in to_char() (Marti Raudsepp) +

    In a format with FM and no digit positions + after the decimal point, zeroes to the left of the decimal point could + be removed incorrectly. +

  • Fix pg_size_pretty() to avoid overflow for inputs close to + 2^63 (Tom Lane) +

  • In pg_ctl, support silent mode for service registrations + on Windows (MauMau) +

  • Fix psql's counting of script file line numbers during + COPY from a different file (Tom Lane) +

  • Fix pg_restore's direct-to-database mode for + standard_conforming_strings (Tom Lane) +

    pg_restore could emit incorrect commands when restoring + directly to a database server from an archive file that had been made + with standard_conforming_strings set to on. +

  • Fix write-past-buffer-end and memory leak in libpq's + LDAP service lookup code (Albe Laurenz) +

  • In libpq, avoid failures when using nonblocking I/O + and an SSL connection (Martin Pihlak, Tom Lane) +

  • Improve libpq's handling of failures during connection startup + (Tom Lane) +

    In particular, the response to a server report of fork() + failure during SSL connection startup is now saner. +

  • Improve libpq's error reporting for SSL failures (Tom + Lane) +

  • Make ecpglib write double values with 15 digits + precision (Akira Kurosawa) +

  • In ecpglib, be sure LC_NUMERIC setting is + restored after an error (Michael Meskes) +

  • Apply upstream fix for blowfish signed-character bug (CVE-2011-2483) + (Tom Lane) +

    contrib/pg_crypto's blowfish encryption code could give + wrong results on platforms where char is signed (which is most), + leading to encrypted passwords being weaker than they should be. +

  • Fix memory leak in contrib/seg (Heikki Linnakangas) +

  • Fix pgstatindex() to give consistent results for empty + indexes (Tom Lane) +

  • Allow building with perl 5.14 (Alex Hunsaker) +

  • Update configure script's method for probing existence of system + functions (Tom Lane) +

    The version of autoconf we used in 8.3 and 8.2 could be fooled by + compilers that perform link-time optimization. +

  • Fix assorted issues with build and install file paths containing spaces + (Tom Lane) +

  • Update time zone data files to tzdata release 2011i + for DST law changes in Canada, Egypt, Russia, Samoa, and South Sudan. +


PrevHomeNext
Release 8.3.17UpRelease 8.3.15
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-3-17.html b/doc/src/sgml/html/release-8-3-17.html new file mode 100644 index 000000000..85d6630ce --- /dev/null +++ b/doc/src/sgml/html/release-8-3-17.html @@ -0,0 +1,534 @@ + +Release 8.3.17

E.45. Release 8.3.17

Release Date: 2011-12-05

This release contains a variety of fixes from 8.3.16. + For information about new features in the 8.3 major release, see + Section E.62. +

E.45.1. Migration to Version 8.3.17

A dump/restore is not required for those running 8.3.X. +

However, a longstanding error was discovered in the definition of the + information_schema.referential_constraints view. If you + rely on correct results from that view, you should replace its + definition as explained in the first changelog item below. +

Also, if you are upgrading from a version earlier than 8.3.8, + see the release notes for 8.3.8. +

E.45.2. Changes

  • Fix bugs in information_schema.referential_constraints view + (Tom Lane) +

    This view was being insufficiently careful about matching the + foreign-key constraint to the depended-on primary or unique key + constraint. That could result in failure to show a foreign key + constraint at all, or showing it multiple times, or claiming that it + depends on a different constraint than the one it really does. +

    Since the view definition is installed by initdb, + merely upgrading will not fix the problem. If you need to fix this + in an existing installation, you can (as a superuser) drop the + information_schema schema then re-create it by sourcing + SHAREDIR/information_schema.sql. + (Run pg_config --sharedir if you're uncertain where + SHAREDIR is.) This must be repeated in each database + to be fixed. +

  • Fix TOAST-related data corruption during CREATE TABLE dest AS + SELECT * FROM src or INSERT INTO dest SELECT * FROM src + (Tom Lane) +

    If a table has been modified by ALTER TABLE ADD COLUMN, + attempts to copy its data verbatim to another table could produce + corrupt results in certain corner cases. + The problem can only manifest in this precise form in 8.4 and later, + but we patched earlier versions as well in case there are other code + paths that could trigger the same bug. +

  • Fix race condition during toast table access from stale syscache entries + (Tom Lane) +

    The typical symptom was transient errors like "missing chunk + number 0 for toast value NNNNN in pg_toast_2619", where the cited + toast table would always belong to a system catalog. +

  • Make DatumGetInetP() unpack inet datums that have a 1-byte + header, and add a new macro, DatumGetInetPP(), that does + not (Heikki Linnakangas) +

    This change affects no core code, but might prevent crashes in add-on + code that expects DatumGetInetP() to produce an unpacked + datum as per usual convention. +

  • Improve locale support in money type's input and output + (Tom Lane) +

    Aside from not supporting all standard + lc_monetary + formatting options, the input and output functions were inconsistent, + meaning there were locales in which dumped money values could + not be re-read. +

  • Don't let transform_null_equals + affect CASE foo WHEN NULL ... constructs + (Heikki Linnakangas) +

    transform_null_equals is only supposed to affect + foo = NULL expressions written directly by the user, not + equality checks generated internally by this form of CASE. +

  • Change foreign-key trigger creation order to better support + self-referential foreign keys (Tom Lane) +

    For a cascading foreign key that references its own table, a row update + will fire both the ON UPDATE trigger and the + CHECK trigger as one event. The ON UPDATE + trigger must execute first, else the CHECK will check a + non-final state of the row and possibly throw an inappropriate error. + However, the firing order of these triggers is determined by their + names, which generally sort in creation order since the triggers have + auto-generated names following the convention + "RI_ConstraintTrigger_NNNN". A proper fix would require + modifying that convention, which we will do in 9.2, but it seems risky + to change it in existing releases. So this patch just changes the + creation order of the triggers. Users encountering this type of error + should drop and re-create the foreign key constraint to get its + triggers into the right order. +

  • Avoid floating-point underflow while tracking buffer allocation rate + (Greg Matthews) +

    While harmless in itself, on certain platforms this would result in + annoying kernel log messages. +

  • Preserve blank lines within commands in psql's command + history (Robert Haas) +

    The former behavior could cause problems if an empty line was removed + from within a string literal, for example. +

  • Fix pg_dump to dump user-defined casts between + auto-generated types, such as table rowtypes (Tom Lane) +

  • Use the preferred version of xsubpp to build PL/Perl, + not necessarily the operating system's main copy + (David Wheeler and Alex Hunsaker) +

  • Fix incorrect coding in contrib/dict_int and + contrib/dict_xsyn (Tom Lane) +

    Some functions incorrectly assumed that memory returned by + palloc() is guaranteed zeroed. +

  • Honor query cancel interrupts promptly in pgstatindex() + (Robert Haas) +

  • Ensure VPATH builds properly install all server header files + (Peter Eisentraut) +

  • Shorten file names reported in verbose error messages (Peter Eisentraut) +

    Regular builds have always reported just the name of the C file + containing the error message call, but VPATH builds formerly + reported an absolute path name. +

  • Fix interpretation of Windows timezone names for Central America + (Tom Lane) +

    Map "Central America Standard Time" to CST6, not + CST6CDT, because DST is generally not observed anywhere in + Central America. +

  • Update time zone data files to tzdata release 2011n + for DST law changes in Brazil, Cuba, Fiji, Palestine, Russia, and Samoa; + also historical corrections for Alaska and British East Africa. +


PrevHomeNext
Release 8.3.18UpRelease 8.3.16
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-3-18.html b/doc/src/sgml/html/release-8-3-18.html new file mode 100644 index 000000000..1be10f397 --- /dev/null +++ b/doc/src/sgml/html/release-8-3-18.html @@ -0,0 +1,524 @@ + +Release 8.3.18

E.44. Release 8.3.18

Release Date: 2012-02-27

This release contains a variety of fixes from 8.3.17. + For information about new features in the 8.3 major release, see + Section E.62. +

E.44.1. Migration to Version 8.3.18

A dump/restore is not required for those running 8.3.X. +

However, if you are upgrading from a version earlier than 8.3.17, + see the release notes for 8.3.17. +

E.44.2. Changes

  • Require execute permission on the trigger function for + CREATE TRIGGER (Robert Haas) +

    This missing check could allow another user to execute a trigger + function with forged input data, by installing it on a table he owns. + This is only of significance for trigger functions marked + SECURITY DEFINER, since otherwise trigger functions run + as the table owner anyway. (CVE-2012-0866) +

  • Convert newlines to spaces in names written in pg_dump + comments (Robert Haas) +

    pg_dump was incautious about sanitizing object names + that are emitted within SQL comments in its output script. A name + containing a newline would at least render the script syntactically + incorrect. Maliciously crafted object names could present a SQL + injection risk when the script is reloaded. (CVE-2012-0868) +

  • Fix btree index corruption from insertions concurrent with vacuuming + (Tom Lane) +

    An index page split caused by an insertion could sometimes cause a + concurrently-running VACUUM to miss removing index entries + that it should remove. After the corresponding table rows are removed, + the dangling index entries would cause errors (such as "could not + read block N in file ...") or worse, silently wrong query results + after unrelated rows are re-inserted at the now-free table locations. + This bug has been present since release 8.2, but occurs so infrequently + that it was not diagnosed until now. If you have reason to suspect + that it has happened in your database, reindexing the affected index + will fix things. +

  • Allow non-existent values for some settings in ALTER + USER/DATABASE SET (Heikki Linnakangas) +

    Allow default_text_search_config, + default_tablespace, and temp_tablespaces to be + set to names that are not known. This is because they might be known + in another database where the setting is intended to be used, or for the + tablespace cases because the tablespace might not be created yet. The + same issue was previously recognized for search_path, and + these settings now act like that one. +

  • Track the OID counter correctly during WAL replay, even when it wraps + around (Tom Lane) +

    Previously the OID counter would remain stuck at a high value until the + system exited replay mode. The practical consequences of that are + usually nil, but there are scenarios wherein a standby server that's + been promoted to master might take a long time to advance the OID + counter to a reasonable value once values are needed. +

  • Fix regular expression back-references with * attached + (Tom Lane) +

    Rather than enforcing an exact string match, the code would effectively + accept any string that satisfies the pattern sub-expression referenced + by the back-reference symbol. +

    A similar problem still afflicts back-references that are embedded in a + larger quantified expression, rather than being the immediate subject + of the quantifier. This will be addressed in a future + PostgreSQL release. +

  • Fix recently-introduced memory leak in processing of + inet/cidr values (Heikki Linnakangas) +

    A patch in the December 2011 releases of PostgreSQL + caused memory leakage in these operations, which could be significant + in scenarios such as building a btree index on such a column. +

  • Avoid double close of file handle in syslogger on Windows (MauMau) +

    Ordinarily this error was invisible, but it would cause an exception + when running on a debug version of Windows. +

  • Fix I/O-conversion-related memory leaks in plpgsql + (Andres Freund, Jan Urbanski, Tom Lane) +

    Certain operations would leak memory until the end of the current + function. +

  • Improve pg_dump's handling of inherited table columns + (Tom Lane) +

    pg_dump mishandled situations where a child column has + a different default expression than its parent column. If the default + is textually identical to the parent's default, but not actually the + same (for instance, because of schema search path differences) it would + not be recognized as different, so that after dump and restore the + child would be allowed to inherit the parent's default. Child columns + that are NOT NULL where their parent is not could also be + restored subtly incorrectly. +

  • Fix pg_restore's direct-to-database mode for + INSERT-style table data (Tom Lane) +

    Direct-to-database restores from archive files made with + --inserts or --column-inserts options fail when + using pg_restore from a release dated September or + December 2011, as a result of an oversight in a fix for another + problem. The archive file itself is not at fault, and text-mode + output is okay. +

  • Fix error in contrib/intarray's int[] & + int[] operator (Guillaume Lelarge) +

    If the smallest integer the two input arrays have in common is 1, + and there are smaller values in either array, then 1 would be + incorrectly omitted from the result. +

  • Fix error detection in contrib/pgcrypto's + encrypt_iv() and decrypt_iv() + (Marko Kreen) +

    These functions failed to report certain types of invalid-input errors, + and would instead return random garbage values for incorrect input. +

  • Fix one-byte buffer overrun in contrib/test_parser + (Paul Guyot) +

    The code would try to read one more byte than it should, which would + crash in corner cases. + Since contrib/test_parser is only example code, this is + not a security issue in itself, but bad example code is still bad. +

  • Use __sync_lock_test_and_set() for spinlocks on ARM, if + available (Martin Pitt) +

    This function replaces our previous use of the SWPB + instruction, which is deprecated and not available on ARMv6 and later. + Reports suggest that the old code doesn't fail in an obvious way on + recent ARM boards, but simply doesn't interlock concurrent accesses, + leading to bizarre failures in multiprocess operation. +

  • Use -fexcess-precision=standard option when building with + gcc versions that accept it (Andrew Dunstan) +

    This prevents assorted scenarios wherein recent versions of gcc will + produce creative results. +

  • Allow use of threaded Python on FreeBSD (Chris Rees) +

    Our configure script previously believed that this combination wouldn't + work; but FreeBSD fixed the problem, so remove that error check. +


PrevHomeNext
Release 8.3.19UpRelease 8.3.17
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-3-19.html b/doc/src/sgml/html/release-8-3-19.html new file mode 100644 index 000000000..10154d363 --- /dev/null +++ b/doc/src/sgml/html/release-8-3-19.html @@ -0,0 +1,445 @@ + +Release 8.3.19

E.43. Release 8.3.19

Release Date: 2012-06-04

This release contains a variety of fixes from 8.3.18. + For information about new features in the 8.3 major release, see + Section E.62. +

E.43.1. Migration to Version 8.3.19

A dump/restore is not required for those running 8.3.X. +

However, if you are upgrading from a version earlier than 8.3.17, + see the release notes for 8.3.17. +

E.43.2. Changes

  • Fix incorrect password transformation in + contrib/pgcrypto's DES crypt() function + (Solar Designer) +

    If a password string contained the byte value 0x80, the + remainder of the password was ignored, causing the password to be much + weaker than it appeared. With this fix, the rest of the string is + properly included in the DES hash. Any stored password values that are + affected by this bug will thus no longer match, so the stored values may + need to be updated. (CVE-2012-2143) +

  • Ignore SECURITY DEFINER and SET attributes for + a procedural language's call handler (Tom Lane) +

    Applying such attributes to a call handler could crash the server. + (CVE-2012-2655) +

  • Allow numeric timezone offsets in timestamp input to be up to + 16 hours away from UTC (Tom Lane) +

    Some historical time zones have offsets larger than 15 hours, the + previous limit. This could result in dumped data values being rejected + during reload. +

  • Fix timestamp conversion to cope when the given time is exactly the + last DST transition time for the current timezone (Tom Lane) +

    This oversight has been there a long time, but was not noticed + previously because most DST-using zones are presumed to have an + indefinite sequence of future DST transitions. +

  • Fix text to name and char to name + casts to perform string truncation correctly in multibyte encodings + (Karl Schnaitter) +

  • Fix memory copying bug in to_tsquery() (Heikki Linnakangas) +

  • Fix slow session startup when pg_attribute is very large + (Tom Lane) +

    If pg_attribute exceeds one-fourth of + shared_buffers, cache rebuilding code that is sometimes + needed during session start would trigger the synchronized-scan logic, + causing it to take many times longer than normal. The problem was + particularly acute if many new sessions were starting at once. +

  • Ensure sequential scans check for query cancel reasonably often (Merlin + Moncure) +

    A scan encountering many consecutive pages that contain no live tuples + would not respond to interrupts meanwhile. +

  • Ensure the Windows implementation of PGSemaphoreLock() + clears ImmediateInterruptOK before returning (Tom Lane) +

    This oversight meant that a query-cancel interrupt received later + in the same query could be accepted at an unsafe time, with + unpredictable but not good consequences. +

  • Show whole-row variables safely when printing views or rules + (Abbas Butt, Tom Lane) +

    Corner cases involving ambiguous names (that is, the name could be + either a table or column name of the query) were printed in an + ambiguous way, risking that the view or rule would be interpreted + differently after dump and reload. Avoid the ambiguous case by + attaching a no-op cast. +

  • Ensure autovacuum worker processes perform stack depth checking + properly (Heikki Linnakangas) +

    Previously, infinite recursion in a function invoked by + auto-ANALYZE could crash worker processes. +

  • Fix logging collector to not lose log coherency under high load (Andrew + Dunstan) +

    The collector previously could fail to reassemble large messages if it + got too busy. +

  • Fix logging collector to ensure it will restart file rotation + after receiving SIGHUP (Tom Lane) +

  • Fix PL/pgSQL's GET DIAGNOSTICS command when the target + is the function's first variable (Tom Lane) +

  • Fix several performance problems in pg_dump when + the database contains many objects (Jeff Janes, Tom Lane) +

    pg_dump could get very slow if the database contained + many schemas, or if many objects are in dependency loops, or if there + are many owned sequences. +

  • Fix contrib/dblink's dblink_exec() to not leak + temporary database connections upon error (Tom Lane) +

  • Update time zone data files to tzdata release 2012c + for DST law changes in Antarctica, Armenia, Chile, Cuba, Falkland + Islands, Gaza, Haiti, Hebron, Morocco, Syria, and Tokelau Islands; + also historical corrections for Canada. +


PrevHomeNext
Release 8.3.20UpRelease 8.3.18
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-3-2.html b/doc/src/sgml/html/release-8-3-2.html new file mode 100644 index 000000000..b982aed39 --- /dev/null +++ b/doc/src/sgml/html/release-8-3-2.html @@ -0,0 +1,691 @@ + +Release 8.3.2

E.60. Release 8.3.2

Release Date: never released

This release contains a variety of fixes from 8.3.1. + For information about new features in the 8.3 major release, see + Section E.62. +

E.60.1. Migration to Version 8.3.2

A dump/restore is not required for those running 8.3.X. + However, if you are upgrading from a version earlier than 8.3.1, + see the release notes for 8.3.1. +

E.60.2. Changes

  • Fix ERRORDATA_STACK_SIZE exceeded crash that + occurred on Windows when using UTF-8 database encoding and a different + client encoding (Tom) +

  • Fix incorrect archive truncation point calculation for the + %r macro in recovery_command parameters + (Simon) +

    This could lead to data loss if a warm-standby script relied on + %r to decide when to throw away WAL segment files. +

  • Fix ALTER TABLE ADD COLUMN ... PRIMARY KEY so that the new + column is correctly checked to see if it's been initialized to all + non-nulls (Brendan Jurd) +

    Previous versions neglected to check this requirement at all. +

  • Fix REASSIGN OWNED so that it works on procedural + languages too (Alvaro) +

  • Fix problems with SELECT FOR UPDATE/SHARE occurring as a + subquery in a query with a non-SELECT top-level operation + (Tom) +

  • Fix possible CREATE TABLE failure when inheriting the + "same" constraint from multiple parent relations that + inherited that constraint from a common ancestor (Tom) +

  • Fix pg_get_ruledef() to show the alias, if any, attached + to the target table of an UPDATE or DELETE + (Tom) +

  • Restore the pre-8.3 behavior that an out-of-range block number in a + TID being used in a TidScan plan results in silently not matching any + rows (Tom) +

    8.3.0 and 8.3.1 threw an error instead. +

  • Fix GIN bug that could result in a too many LWLocks + taken failure (Teodor) +

  • Fix broken GiST comparison function for tsquery (Teodor) +

  • Fix tsvector_update_trigger() and ts_stat() + to accept domains over the types they expect to work with (Tom) +

  • Fix failure to support enum data types as foreign keys (Tom) +

  • Avoid possible crash when decompressing corrupted data + (Zdenek Kotala) +

  • Fix race conditions between delayed unlinks and DROP + DATABASE (Heikki) +

    In the worst case this could result in deleting a newly created table + in a new database that happened to get the same OID as the + recently-dropped one; but of course that is an extremely + low-probability scenario. +

  • Repair two places where SIGTERM exit of a backend could leave corrupted + state in shared memory (Tom) +

    Neither case is very important if SIGTERM is used to shut down the + whole database cluster together, but there was a problem if someone + tried to SIGTERM individual backends. +

  • Fix possible crash due to incorrect plan generated for an + x IN (SELECT y + FROM ...) clause when x and y + have different data types; and make sure the behavior is semantically + correct when the conversion from y's type to + x's type is lossy (Tom) +

  • Fix oversight that prevented the planner from substituting known Param + values as if they were constants (Tom) +

    This mistake partially disabled optimization of unnamed + extended-Query statements in 8.3.0 and 8.3.1: in particular the + LIKE-to-indexscan optimization would never be applied if the LIKE + pattern was passed as a parameter, and constraint exclusion + depending on a parameter value didn't work either. +

  • Fix planner failure when an indexable MIN or + MAX aggregate is used with DISTINCT or + ORDER BY (Tom) +

  • Fix planner to ensure it never uses a "physical tlist" for a + plan node that is feeding a Sort node (Tom) +

    This led to the sort having to push around more data than it really + needed to, since unused column values were included in the sorted + data. +

  • Avoid unnecessary copying of query strings (Tom) +

    This fixes a performance problem introduced in 8.3.0 when a very large + number of commands are submitted as a single query string. +

  • Make TransactionIdIsCurrentTransactionId() use binary + search instead of linear search when checking child-transaction XIDs + (Heikki) +

    This fixes some cases in which 8.3.0 was significantly + slower than earlier releases. +

  • Fix conversions between ISO-8859-5 and other encodings to handle + Cyrillic "Yo" characters (e and E with + two dots) (Sergey Burladyan) +

  • Fix several datatype input functions, notably array_in(), + that were allowing unused bytes in their results to contain + uninitialized, unpredictable values (Tom) +

    This could lead to failures in which two apparently identical literal + values were not seen as equal, resulting in the parser complaining + about unmatched ORDER BY and DISTINCT + expressions. +

  • Fix a corner case in regular-expression substring matching + (substring(string from + pattern)) (Tom) +

    The problem occurs when there is a match to the pattern overall but + the user has specified a parenthesized subexpression and that + subexpression hasn't got a match. An example is + substring('foo' from 'foo(bar)?'). + This should return NULL, since (bar) isn't matched, but + it was mistakenly returning the whole-pattern match instead (ie, + foo). +

  • Prevent cancellation of an auto-vacuum that was launched to prevent + XID wraparound (Alvaro) +

  • Improve ANALYZE's handling of in-doubt tuples (those + inserted or deleted by a not-yet-committed transaction) so that the + counts it reports to the stats collector are more likely to be correct + (Pavan Deolasee) +

  • Fix initdb to reject a relative path for its + --xlogdir (-X) option (Tom) +

  • Make psql print tab characters as an appropriate + number of spaces, rather than \x09 as was done in + 8.3.0 and 8.3.1 (Bruce) +

  • Update time zone data files to tzdata release 2008c (for + DST law changes in Morocco, Iraq, Choibalsan, Pakistan, Syria, Cuba, and + Argentina/San_Luis) +

  • Add ECPGget_PGconn() function to + ecpglib (Michael) +

  • Fix incorrect result from ecpg's + PGTYPEStimestamp_sub() function (Michael) +

  • Fix handling of continuation line markers in ecpg + (Michael) +

  • Fix possible crashes in contrib/cube functions (Tom) +

  • Fix core dump in contrib/xml2's + xpath_table() function when the input query returns a + NULL value (Tom) +

  • Fix contrib/xml2's makefile to not override + CFLAGS, and make it auto-configure properly for + libxslt present or not (Tom) +


PrevHomeNext
Release 8.3.3UpRelease 8.3.1
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-3-20.html b/doc/src/sgml/html/release-8-3-20.html new file mode 100644 index 000000000..43de74a3b --- /dev/null +++ b/doc/src/sgml/html/release-8-3-20.html @@ -0,0 +1,466 @@ + +Release 8.3.20

E.42. Release 8.3.20

Release Date: 2012-08-17

This release contains a variety of fixes from 8.3.19. + For information about new features in the 8.3 major release, see + Section E.62. +

The PostgreSQL community will stop releasing updates + for the 8.3.X release series in February 2013. + Users are encouraged to update to a newer release branch soon. +

E.42.1. Migration to Version 8.3.20

A dump/restore is not required for those running 8.3.X. +

However, if you are upgrading from a version earlier than 8.3.17, + see the release notes for 8.3.17. +

E.42.2. Changes

  • Prevent access to external files/URLs via XML entity references + (Noah Misch, Tom Lane) +

    xml_parse() would attempt to fetch external files or + URLs as needed to resolve DTD and entity references in an XML value, + thus allowing unprivileged database users to attempt to fetch data + with the privileges of the database server. While the external data + wouldn't get returned directly to the user, portions of it could be + exposed in error messages if the data didn't parse as valid XML; and + in any case the mere ability to check existence of a file might be + useful to an attacker. (CVE-2012-3489) +

  • Prevent access to external files/URLs via contrib/xml2's + xslt_process() (Peter Eisentraut) +

    libxslt offers the ability to read and write both + files and URLs through stylesheet commands, thus allowing + unprivileged database users to both read and write data with the + privileges of the database server. Disable that through proper use + of libxslt's security options. (CVE-2012-3488) +

    Also, remove xslt_process()'s ability to fetch documents + and stylesheets from external files/URLs. While this was a + documented "feature", it was long regarded as a bad idea. + The fix for CVE-2012-3489 broke that capability, and rather than + expend effort on trying to fix it, we're just going to summarily + remove it. +

  • Prevent too-early recycling of btree index pages (Noah Misch) +

    When we allowed read-only transactions to skip assigning XIDs, we + introduced the possibility that a deleted btree page could be + recycled while a read-only transaction was still in flight to it. + This would result in incorrect index search results. The probability + of such an error occurring in the field seems very low because of the + timing requirements, but nonetheless it should be fixed. +

  • Fix crash-safety bug with newly-created-or-reset sequences (Tom Lane) +

    If ALTER SEQUENCE was executed on a freshly created or + reset sequence, and then precisely one nextval() call + was made on it, and then the server crashed, WAL replay would restore + the sequence to a state in which it appeared that no + nextval() had been done, thus allowing the first + sequence value to be returned again by the next + nextval() call. In particular this could manifest for + serial columns, since creation of a serial column's sequence + includes an ALTER SEQUENCE OWNED BY step. +

  • Ensure the backup_label file is fsync'd after + pg_start_backup() (Dave Kerr) +

  • Back-patch 9.1 improvement to compress the fsync request queue + (Robert Haas) +

    This improves performance during checkpoints. The 9.1 change + has now seen enough field testing to seem safe to back-patch. +

  • Only allow autovacuum to be auto-canceled by a directly blocked + process (Tom Lane) +

    The original coding could allow inconsistent behavior in some cases; + in particular, an autovacuum could get canceled after less than + deadlock_timeout grace period. +

  • Improve logging of autovacuum cancels (Robert Haas) +

  • Fix log collector so that log_truncate_on_rotation works + during the very first log rotation after server start (Tom Lane) +

  • Ensure that a whole-row reference to a subquery doesn't include any + extra GROUP BY or ORDER BY columns (Tom Lane) +

  • Disallow copying whole-row references in CHECK + constraints and index definitions during CREATE TABLE + (Tom Lane) +

    This situation can arise in CREATE TABLE with + LIKE or INHERITS. The copied whole-row + variable was incorrectly labeled with the row type of the original + table not the new one. Rejecting the case seems reasonable for + LIKE, since the row types might well diverge later. For + INHERITS we should ideally allow it, with an implicit + coercion to the parent table's row type; but that will require more + work than seems safe to back-patch. +

  • Fix memory leak in ARRAY(SELECT ...) subqueries (Heikki + Linnakangas, Tom Lane) +

  • Fix extraction of common prefixes from regular expressions (Tom Lane) +

    The code could get confused by quantified parenthesized + subexpressions, such as ^(foo)?bar. This would lead to + incorrect index optimization of searches for such patterns. +

  • Report errors properly in contrib/xml2's + xslt_process() (Tom Lane) +

  • Update time zone data files to tzdata release 2012e + for DST law changes in Morocco and Tokelau +


PrevHomeNext
Release 8.3.21UpRelease 8.3.19
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-3-21.html b/doc/src/sgml/html/release-8-3-21.html new file mode 100644 index 000000000..a924f2905 --- /dev/null +++ b/doc/src/sgml/html/release-8-3-21.html @@ -0,0 +1,309 @@ + +Release 8.3.21

E.41. Release 8.3.21

Release Date: 2012-09-24

This release contains a variety of fixes from 8.3.20. + For information about new features in the 8.3 major release, see + Section E.62. +

The PostgreSQL community will stop releasing updates + for the 8.3.X release series in February 2013. + Users are encouraged to update to a newer release branch soon. +

E.41.1. Migration to Version 8.3.21

A dump/restore is not required for those running 8.3.X. +

However, if you are upgrading from a version earlier than 8.3.17, + see the release notes for 8.3.17. +

E.41.2. Changes

  • Improve page-splitting decisions in GiST indexes (Alexander Korotkov, + Robert Haas, Tom Lane) +

    Multi-column GiST indexes might suffer unexpected bloat due to this + error. +

  • Fix cascading privilege revoke to stop if privileges are still held + (Tom Lane) +

    If we revoke a grant option from some role X, but + X still holds that option via a grant from someone + else, we should not recursively revoke the corresponding privilege + from role(s) Y that X had granted it + to. +

  • Fix handling of SIGFPE when PL/Perl is in use (Andres Freund) +

    Perl resets the process's SIGFPE handler to + SIG_IGN, which could result in crashes later on. Restore + the normal Postgres signal handler after initializing PL/Perl. +

  • Prevent PL/Perl from crashing if a recursive PL/Perl function is + redefined while being executed (Tom Lane) +

  • Work around possible misoptimization in PL/Perl (Tom Lane) +

    Some Linux distributions contain an incorrect version of + pthread.h that results in incorrect compiled code in + PL/Perl, leading to crashes if a PL/Perl function calls another one + that throws an error. +

  • Update time zone data files to tzdata release 2012f + for DST law changes in Fiji +


PrevHomeNext
Release 8.3.22UpRelease 8.3.20
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-3-22.html b/doc/src/sgml/html/release-8-3-22.html new file mode 100644 index 000000000..adb201e70 --- /dev/null +++ b/doc/src/sgml/html/release-8-3-22.html @@ -0,0 +1,568 @@ + +Release 8.3.22

E.40. Release 8.3.22

Release Date: 2012-12-06

This release contains a variety of fixes from 8.3.21. + For information about new features in the 8.3 major release, see + Section E.62. +

The PostgreSQL community will stop releasing updates + for the 8.3.X release series in February 2013. + Users are encouraged to update to a newer release branch soon. +

E.40.1. Migration to Version 8.3.22

A dump/restore is not required for those running 8.3.X. +

However, if you are upgrading from a version earlier than 8.3.17, + see the release notes for 8.3.17. +

E.40.2. Changes

  • Fix multiple bugs associated with CREATE INDEX + CONCURRENTLY (Andres Freund, Tom Lane) +

    Fix CREATE INDEX CONCURRENTLY to use + in-place updates when changing the state of an index's + pg_index row. This prevents race conditions that could + cause concurrent sessions to miss updating the target index, thus + resulting in corrupt concurrently-created indexes. +

    Also, fix various other operations to ensure that they ignore + invalid indexes resulting from a failed CREATE INDEX + CONCURRENTLY command. The most important of these is + VACUUM, because an auto-vacuum could easily be launched + on the table before corrective action can be taken to fix or remove + the invalid index. +

  • Avoid corruption of internal hash tables when out of memory + (Hitoshi Harada) +

  • Fix planning of non-strict equivalence clauses above outer joins + (Tom Lane) +

    The planner could derive incorrect constraints from a clause equating + a non-strict construct to something else, for example + WHERE COALESCE(foo, 0) = 0 + when foo is coming from the nullable side of an outer join. +

  • Improve planner's ability to prove exclusion constraints from + equivalence classes (Tom Lane) +

  • Fix partial-row matching in hashed subplans to handle cross-type cases + correctly (Tom Lane) +

    This affects multicolumn NOT IN subplans, such as + WHERE (a, b) NOT IN (SELECT x, y FROM ...) + when for instance b and y are int4 + and int8 respectively. This mistake led to wrong answers + or crashes depending on the specific datatypes involved. +

  • Acquire buffer lock when re-fetching the old tuple for an + AFTER ROW UPDATE/DELETE trigger (Andres Freund) +

    In very unusual circumstances, this oversight could result in passing + incorrect data to the precheck logic for a foreign-key enforcement + trigger. That could result in a crash, or in an incorrect decision + about whether to fire the trigger. +

  • Fix REASSIGN OWNED to handle grants on tablespaces + (Álvaro Herrera) +

  • Ignore incorrect pg_attribute entries for system + columns for views (Tom Lane) +

    Views do not have any system columns. However, we forgot to + remove such entries when converting a table to a view. That's fixed + properly for 9.3 and later, but in previous branches we need to defend + against existing mis-converted views. +

  • Fix rule printing to dump INSERT INTO table + DEFAULT VALUES correctly (Tom Lane) +

  • Guard against stack overflow when there are too many + UNION/INTERSECT/EXCEPT clauses + in a query (Tom Lane) +

  • Prevent platform-dependent failures when dividing the minimum possible + integer value by -1 (Xi Wang, Tom Lane) +

  • Fix possible access past end of string in date parsing + (Hitoshi Harada) +

  • Produce an understandable error message if the length of the path name + for a Unix-domain socket exceeds the platform-specific limit + (Tom Lane, Andrew Dunstan) +

    Formerly, this would result in something quite unhelpful, such as + "Non-recoverable failure in name resolution". +

  • Fix memory leaks when sending composite column values to the client + (Tom Lane) +

  • Make pg_ctl more robust about reading the + postmaster.pid file (Heikki Linnakangas) +

    Fix race conditions and possible file descriptor leakage. +

  • Fix possible crash in psql if incorrectly-encoded data + is presented and the client_encoding setting is a + client-only encoding, such as SJIS (Jiang Guiqing) +

  • Fix bugs in the restore.sql script emitted by + pg_dump in tar output format (Tom Lane) +

    The script would fail outright on tables whose names include + upper-case characters. Also, make the script capable of restoring + data in --inserts mode as well as the regular COPY mode. +

  • Fix pg_restore to accept POSIX-conformant + tar files (Brian Weaver, Tom Lane) +

    The original coding of pg_dump's tar + output mode produced files that are not fully conformant with the + POSIX standard. This has been corrected for version 9.3. This + patch updates previous branches so that they will accept both the + incorrect and the corrected formats, in hopes of avoiding + compatibility problems when 9.3 comes out. +

  • Fix pg_resetxlog to locate postmaster.pid + correctly when given a relative path to the data directory (Tom Lane) +

    This mistake could lead to pg_resetxlog not noticing + that there is an active postmaster using the data directory. +

  • Fix libpq's lo_import() and + lo_export() functions to report file I/O errors properly + (Tom Lane) +

  • Fix ecpg's processing of nested structure pointer + variables (Muhammad Usama) +

  • Make contrib/pageinspect's btree page inspection + functions take buffer locks while examining pages (Tom Lane) +

  • Fix pgxs support for building loadable modules on AIX + (Tom Lane) +

    Building modules outside the original source tree didn't work on AIX. +

  • Update time zone data files to tzdata release 2012j + for DST law changes in Cuba, Israel, Jordan, Libya, Palestine, Western + Samoa, and portions of Brazil. +


PrevHomeNext
Release 8.4UpRelease 8.3.21
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-3-3.html b/doc/src/sgml/html/release-8-3-3.html new file mode 100644 index 000000000..7bf9abccd --- /dev/null +++ b/doc/src/sgml/html/release-8-3-3.html @@ -0,0 +1,266 @@ + +Release 8.3.3

E.59. Release 8.3.3

Release Date: 2008-06-12

This release contains one serious and one minor bug fix over 8.3.2. + For information about new features in the 8.3 major release, see + Section E.62. +

E.59.1. Migration to Version 8.3.3

A dump/restore is not required for those running 8.3.X. + However, if you are upgrading from a version earlier than 8.3.1, + see the release notes for 8.3.1. +

E.59.2. Changes

  • Make pg_get_ruledef() parenthesize negative constants (Tom) +

    Before this fix, a negative constant in a view or rule might be dumped + as, say, -42::integer, which is subtly incorrect: it should + be (-42)::integer due to operator precedence rules. + Usually this would make little difference, but it could interact with + another recent patch to cause + PostgreSQL to reject what had been a valid + SELECT DISTINCT view query. Since this could result in + pg_dump output failing to reload, it is being treated + as a high-priority fix. The only released versions in which dump + output is actually incorrect are 8.3.1 and 8.2.7. +

  • Make ALTER AGGREGATE ... OWNER TO update + pg_shdepend (Tom) +

    This oversight could lead to problems if the aggregate was later + involved in a DROP OWNED or REASSIGN OWNED + operation. +


PrevHomeNext
Release 8.3.4UpRelease 8.3.2
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-3-4.html b/doc/src/sgml/html/release-8-3-4.html new file mode 100644 index 000000000..2b87ca974 --- /dev/null +++ b/doc/src/sgml/html/release-8-3-4.html @@ -0,0 +1,609 @@ + +Release 8.3.4

E.58. Release 8.3.4

Release Date: 2008-09-22

This release contains a variety of fixes from 8.3.3. + For information about new features in the 8.3 major release, see + Section E.62. +

E.58.1. Migration to Version 8.3.4

A dump/restore is not required for those running 8.3.X. + However, if you are upgrading from a version earlier than 8.3.1, + see the release notes for 8.3.1. +

E.58.2. Changes

  • Fix bug in btree WAL recovery code (Heikki) +

    Recovery failed if the WAL ended partway through a page split operation. +

  • Fix potential use of wrong cutoff XID for HOT page pruning (Alvaro) +

    This error created a risk of corruption in system + catalogs that are consulted by VACUUM: dead tuple versions + might be removed too soon. The impact of this on actual database + operations would be minimal, since the system doesn't follow MVCC + rules while examining catalogs, but it might result in transiently + wrong output from pg_dump or other client programs. +

  • Fix potential miscalculation of datfrozenxid (Alvaro) +

    This error may explain some recent reports of failure to remove old + pg_clog data. +

  • Fix incorrect HOT updates after pg_class is reindexed + (Tom) +

    Corruption of pg_class could occur if REINDEX + TABLE pg_class was followed in the same session by an ALTER + TABLE RENAME or ALTER TABLE SET SCHEMA command. +

  • Fix missed "combo cid" case (Karl Schnaitter) +

    This error made rows incorrectly invisible to a transaction in which they + had been deleted by multiple subtransactions that all aborted. +

  • Prevent autovacuum from crashing if the table it's currently + checking is deleted at just the wrong time (Alvaro) +

  • Widen local lock counters from 32 to 64 bits (Tom) +

    This responds to reports that the counters could overflow in + sufficiently long transactions, leading to unexpected "lock is + already held" errors. +

  • Fix possible duplicate output of tuples during a GiST index scan (Teodor) +

  • Regenerate foreign key checking queries from scratch when either + table is modified (Tom) +

    Previously, 8.3 would attempt to replan the query, but would work from + previously generated query text. This led to failures if a + table or column was renamed. +

  • Fix missed permissions checks when a view contains a simple + UNION ALL construct (Heikki) +

    Permissions for the referenced tables were checked properly, but not + permissions for the view itself. +

  • Add checks in executor startup to ensure that the tuples produced by an + INSERT or UPDATE will match the target table's + current rowtype (Tom) +

    This situation is believed to be impossible in 8.3, but it can happen in + prior releases, so a check seems prudent. +

  • Fix possible repeated drops during DROP OWNED (Tom) +

    This would typically result in strange errors such as "cache + lookup failed for relation NNN". +

  • Fix several memory leaks in XML operations (Kris Jurka, Tom) +

  • Fix xmlserialize() to raise error properly for + unacceptable target data type (Tom) +

  • Fix a couple of places that mis-handled multibyte characters in text + search configuration file parsing (Tom) +

    Certain characters occurring in configuration files would always cause + "invalid byte sequence for encoding" failures. +

  • Provide file name and line number location for all errors reported + in text search configuration files (Tom) +

  • Fix AT TIME ZONE to first try to interpret its timezone + argument as a timezone abbreviation, and only try it as a full timezone + name if that fails, rather than the other way around as formerly (Tom) +

    The timestamp input functions have always resolved ambiguous zone names + in this order. Making AT TIME ZONE do so as well improves + consistency, and fixes a compatibility bug introduced in 8.1: + in ambiguous cases we now behave the same as 8.0 and before did, + since in the older versions AT TIME ZONE accepted + only abbreviations. +

  • Fix datetime input functions to correctly detect integer overflow when + running on a 64-bit platform (Tom) +

  • Prevent integer overflows during units conversion when displaying a + configuration parameter that has units (Tom) +

  • Improve performance of writing very long log messages to syslog (Tom) +

  • Allow spaces in the suffix part of an LDAP URL in + pg_hba.conf (Tom) +

  • Fix bug in backwards scanning of a cursor on a SELECT DISTINCT + ON query (Tom) +

  • Fix planner bug that could improperly push down IS NULL + tests below an outer join (Tom) +

    This was triggered by occurrence of IS NULL tests for + the same relation in all arms of an upper OR clause. +

  • Fix planner bug with nested sub-select expressions (Tom) +

    If the outer sub-select has no direct dependency on the parent query, + but the inner one does, the outer value might not get recalculated + for new parent query rows. +

  • Fix planner to estimate that GROUP BY expressions yielding + boolean results always result in two groups, regardless of the + expressions' contents (Tom) +

    This is very substantially more accurate than the regular GROUP + BY estimate for certain boolean tests like col + IS NULL. +

  • Fix PL/pgSQL to not fail when a FOR loop's target variable + is a record containing composite-type fields (Tom) +

  • Fix PL/Tcl to behave correctly with Tcl 8.5, and to be more careful + about the encoding of data sent to or from Tcl (Tom) +

  • Improve performance of PQescapeBytea() (Rudolf Leitgeb) +

  • On Windows, work around a Microsoft bug by preventing + libpq from trying to send more than 64kB per system call + (Magnus) +

  • Fix ecpg to handle variables properly in SET + commands (Michael) +

  • Improve pg_dump and pg_restore's + error reporting after failure to send a SQL command (Tom) +

  • Fix pg_ctl to properly preserve postmaster + command-line arguments across a restart (Bruce) +

  • Fix erroneous WAL file cutoff point calculation in + pg_standby (Simon) +

  • Update time zone data files to tzdata release 2008f (for + DST law changes in Argentina, Bahamas, Brazil, Mauritius, Morocco, + Pakistan, Palestine, and Paraguay) +


PrevHomeNext
Release 8.3.5UpRelease 8.3.3
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-3-5.html b/doc/src/sgml/html/release-8-3-5.html new file mode 100644 index 000000000..15a26a70b --- /dev/null +++ b/doc/src/sgml/html/release-8-3-5.html @@ -0,0 +1,507 @@ + +Release 8.3.5

E.57. Release 8.3.5

Release Date: 2008-11-03

This release contains a variety of fixes from 8.3.4. + For information about new features in the 8.3 major release, see + Section E.62. +

E.57.1. Migration to Version 8.3.5

A dump/restore is not required for those running 8.3.X. + However, if you are upgrading from a version earlier than 8.3.1, + see the release notes for 8.3.1. Also, if you were running a previous + 8.3.X release, it is recommended to REINDEX all GiST + indexes after the upgrade. +

E.57.2. Changes

  • Fix GiST index corruption due to marking the wrong index entry + "dead" after a deletion (Teodor) +

    This would result in index searches failing to find rows they + should have found. Corrupted indexes can be fixed with + REINDEX. +

  • Fix backend crash when the client encoding cannot represent a localized + error message (Tom) +

    We have addressed similar issues before, but it would still fail if + the "character has no equivalent" message itself couldn't + be converted. The fix is to disable localization and send the plain + ASCII error message when we detect such a situation. +

  • Fix possible crash in bytea-to-XML mapping (Michael McMaster) +

  • Fix possible crash when deeply nested functions are invoked from + a trigger (Tom) +

  • Improve optimization of expression IN + (expression-list) queries (Tom, per an idea from Robert + Haas) +

    Cases in which there are query variables on the right-hand side had been + handled less efficiently in 8.2.x and 8.3.x than in prior versions. + The fix restores 8.1 behavior for such cases. +

  • Fix mis-expansion of rule queries when a sub-SELECT appears + in a function call in FROM, a multi-row VALUES + list, or a RETURNING list (Tom) +

    The usual symptom of this problem is an "unrecognized node type" + error. +

  • Fix Assert failure during rescan of an IS NULL + search of a GiST index (Teodor) +

  • Fix memory leak during rescan of a hashed aggregation plan (Neil) +

  • Ensure an error is reported when a newly-defined PL/pgSQL trigger + function is invoked as a normal function (Tom) +

  • Force a checkpoint before CREATE DATABASE starts to copy + files (Heikki) +

    This prevents a possible failure if files had recently been deleted + in the source database. +

  • Prevent possible collision of relfilenode numbers + when moving a table to another tablespace with ALTER SET + TABLESPACE (Heikki) +

    The command tried to re-use the existing filename, instead of + picking one that is known unused in the destination directory. +

  • Fix incorrect text search headline generation when single query + item matches first word of text (Sushant Sinha) +

  • Fix improper display of fractional seconds in interval values when + using a non-ISO datestyle in an --enable-integer-datetimes + build (Ron Mayer) +

  • Make ILIKE compare characters case-insensitively + even when they're escaped (Andrew) +

  • Ensure DISCARD is handled properly by statement logging (Tom) +

  • Fix incorrect logging of last-completed-transaction time during + PITR recovery (Tom) +

  • Ensure SPI_getvalue and SPI_getbinval + behave correctly when the passed tuple and tuple descriptor have + different numbers of columns (Tom) +

    This situation is normal when a table has had columns added or removed, + but these two functions didn't handle it properly. + The only likely consequence is an incorrect error indication. +

  • Mark SessionReplicationRole as PGDLLIMPORT + so it can be used by Slony on Windows (Magnus) +

  • Fix small memory leak when using libpq's + gsslib parameter (Magnus) +

    The space used by the parameter string was not freed at connection + close. +

  • Ensure libgssapi is linked into libpq + if needed (Markus Schaaf) +

  • Fix ecpg's parsing of CREATE ROLE (Michael) +

  • Fix recent breakage of pg_ctl restart (Tom) +

  • Ensure pg_control is opened in binary mode + (Itagaki Takahiro) +

    pg_controldata and pg_resetxlog + did this incorrectly, and so could fail on Windows. +

  • Update time zone data files to tzdata release 2008i (for + DST law changes in Argentina, Brazil, Mauritius, Syria) +


PrevHomeNext
Release 8.3.6UpRelease 8.3.4
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-3-6.html b/doc/src/sgml/html/release-8-3-6.html new file mode 100644 index 000000000..e5979d2a6 --- /dev/null +++ b/doc/src/sgml/html/release-8-3-6.html @@ -0,0 +1,508 @@ + +Release 8.3.6

E.56. Release 8.3.6

Release Date: 2009-02-02

This release contains a variety of fixes from 8.3.5. + For information about new features in the 8.3 major release, see + Section E.62. +

E.56.1. Migration to Version 8.3.6

A dump/restore is not required for those running 8.3.X. + However, if you are upgrading from a version earlier than 8.3.5, + see the release notes for 8.3.5. +

E.56.2. Changes

  • Make DISCARD ALL release advisory locks, in addition + to everything it already did (Tom) +

    This was decided to be the most appropriate behavior. This could + affect existing applications, however. +

  • Fix whole-index GiST scans to work correctly (Teodor) +

    This error could cause rows to be lost if a table is clustered + on a GiST index. +

  • Fix crash of xmlconcat(NULL) (Peter) +

  • Fix possible crash in ispell dictionary if high-bit-set + characters are used as flags (Teodor) +

    This is known to be done by one widely available Norwegian dictionary, + and the same condition may exist in others. +

  • Fix misordering of pg_dump output for composite types + (Tom) +

    The most likely problem was for user-defined operator classes to + be dumped after indexes or views that needed them. +

  • Improve handling of URLs in headline() function (Teodor) +

  • Improve handling of overlength headlines in headline() + function (Teodor) +

  • Prevent possible Assert failure or misconversion if an encoding + conversion is created with the wrong conversion function for the + specified pair of encodings (Tom, Heikki) +

  • Fix possible Assert failure if a statement executed in PL/pgSQL is + rewritten into another kind of statement, for example if an + INSERT is rewritten into an UPDATE (Heikki) +

  • Ensure that a snapshot is available to datatype input functions (Tom) +

    This primarily affects domains that are declared with CHECK + constraints involving user-defined stable or immutable functions. Such + functions typically fail if no snapshot has been set. +

  • Make it safer for SPI-using functions to be used within datatype I/O; + in particular, to be used in domain check constraints (Tom) +

  • Avoid unnecessary locking of small tables in VACUUM + (Heikki) +

  • Fix a problem that sometimes kept ALTER TABLE ENABLE/DISABLE + RULE from being recognized by active sessions (Tom) +

  • Fix a problem that made UPDATE RETURNING tableoid + return zero instead of the correct OID (Tom) +

  • Allow functions declared as taking ANYARRAY to work on + the pg_statistic columns of that type (Tom) +

    This used to work, but was unintentionally broken in 8.3. +

  • Fix planner misestimation of selectivity when transitive equality + is applied to an outer-join clause (Tom) +

    This could result in bad plans for queries like + ... from a left join b on a.a1 = b.b1 where a.a1 = 42 ... +

  • Improve optimizer's handling of long IN lists (Tom) +

    This change avoids wasting large amounts of time on such lists + when constraint exclusion is enabled. +

  • Prevent synchronous scan during GIN index build (Tom) +

    Because GIN is optimized for inserting tuples in increasing TID order, + choosing to use a synchronous scan could slow the build by a factor of + three or more. +

  • Ensure that the contents of a holdable cursor don't depend on the + contents of TOAST tables (Tom) +

    Previously, large field values in a cursor result might be represented + as TOAST pointers, which would fail if the referenced table got dropped + before the cursor is read, or if the large value is deleted and then + vacuumed away. This cannot happen with an ordinary cursor, + but it could with a cursor that is held past its creating transaction. +

  • Fix memory leak when a set-returning function is terminated without + reading its whole result (Tom) +

  • Fix encoding conversion problems in XML functions when the database + encoding isn't UTF-8 (Tom) +

  • Fix contrib/dblink's + dblink_get_result(text,bool) function (Joe) +

  • Fix possible garbage output from contrib/sslinfo functions + (Tom) +

  • Fix incorrect behavior of contrib/tsearch2 compatibility + trigger when it's fired more than once in a command (Teodor) +

  • Fix possible mis-signaling in autovacuum (Heikki) +

  • Support running as a service on Windows 7 beta (Dave and Magnus) +

  • Fix ecpg's handling of varchar structs (Michael) +

  • Fix configure script to properly report failure when + unable to obtain linkage information for PL/Perl (Andrew) +

  • Make all documentation reference pgsql-bugs and/or + pgsql-hackers as appropriate, instead of the + now-decommissioned pgsql-ports and pgsql-patches + mailing lists (Tom) +

  • Update time zone data files to tzdata release 2009a (for + Kathmandu and historical DST corrections in Switzerland, Cuba) +


PrevHomeNext
Release 8.3.7UpRelease 8.3.5
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-3-7.html b/doc/src/sgml/html/release-8-3-7.html new file mode 100644 index 000000000..4c8132c45 --- /dev/null +++ b/doc/src/sgml/html/release-8-3-7.html @@ -0,0 +1,488 @@ + +Release 8.3.7

E.55. Release 8.3.7

Release Date: 2009-03-16

This release contains a variety of fixes from 8.3.6. + For information about new features in the 8.3 major release, see + Section E.62. +

E.55.1. Migration to Version 8.3.7

A dump/restore is not required for those running 8.3.X. + However, if you are upgrading from a version earlier than 8.3.5, + see the release notes for 8.3.5. +

E.55.2. Changes

  • Prevent error recursion crashes when encoding conversion fails (Tom) +

    This change extends fixes made in the last two minor releases for + related failure scenarios. The previous fixes were narrowly tailored + for the original problem reports, but we have now recognized that + any error thrown by an encoding conversion function could + potentially lead to infinite recursion while trying to report the + error. The solution therefore is to disable translation and encoding + conversion and report the plain-ASCII form of any error message, + if we find we have gotten into a recursive error reporting situation. + (CVE-2009-0922) +

  • Disallow CREATE CONVERSION with the wrong encodings + for the specified conversion function (Heikki) +

    This prevents one possible scenario for encoding conversion failure. + The previous change is a backstop to guard against other kinds of + failures in the same area. +

  • Fix xpath() to not modify the path expression unless + necessary, and to make a saner attempt at it when necessary (Andrew) +

    The SQL standard suggests that xpath should work on data + that is a document fragment, but libxml doesn't support + that, and indeed it's not clear that this is sensible according to the + XPath standard. xpath attempted to work around this + mismatch by modifying both the data and the path expression, but the + modification was buggy and could cause valid searches to fail. Now, + xpath checks whether the data is in fact a well-formed + document, and if so invokes libxml with no change to the + data or path expression. Otherwise, a different modification method + that is somewhat less likely to fail is used. +

    Note: The new modification method is still not 100% satisfactory, and it + seems likely that no real solution is possible. This patch should + therefore be viewed as a band-aid to keep from breaking existing + applications unnecessarily. It is likely that + PostgreSQL 8.4 will simply reject use of + xpath on data that is not a well-formed document. +

  • Fix core dump when to_char() is given format codes that + are inappropriate for the type of the data argument (Tom) +

  • Fix possible failure in text search when C locale is used with + a multi-byte encoding (Teodor) +

    Crashes were possible on platforms where wchar_t is narrower + than int; Windows in particular. +

  • Fix extreme inefficiency in text search parser's handling of an + email-like string containing multiple @ characters (Heikki) +

  • Fix planner problem with sub-SELECT in the output list + of a larger subquery (Tom) +

    The known symptom of this bug is a "failed to locate grouping + columns" error that is dependent on the datatype involved; + but there could be other issues as well. +

  • Fix decompilation of CASE WHEN with an implicit coercion + (Tom) +

    This mistake could lead to Assert failures in an Assert-enabled build, + or an "unexpected CASE WHEN clause" error message in other + cases, when trying to examine or dump a view. +

  • Fix possible misassignment of the owner of a TOAST table's rowtype (Tom) +

    If CLUSTER or a rewriting variant of ALTER TABLE + were executed by someone other than the table owner, the + pg_type entry for the table's TOAST table would end up + marked as owned by that someone. This caused no immediate problems, + since the permissions on the TOAST rowtype aren't examined by any + ordinary database operation. However, it could lead to unexpected + failures if one later tried to drop the role that issued the command + (in 8.1 or 8.2), or "owner of data type appears to be invalid" + warnings from pg_dump after having done so (in 8.3). +

  • Change UNLISTEN to exit quickly if the current session has + never executed any LISTEN command (Tom) +

    Most of the time this is not a particularly useful optimization, but + since DISCARD ALL invokes UNLISTEN, the previous + coding caused a substantial performance problem for applications that + made heavy use of DISCARD ALL. +

  • Fix PL/pgSQL to not treat INTO after INSERT as + an INTO-variables clause anywhere in the string, not only at the start; + in particular, don't fail for INSERT INTO within + CREATE RULE (Tom) +

  • Clean up PL/pgSQL error status variables fully at block exit + (Ashesh Vashi and Dave Page) +

    This is not a problem for PL/pgSQL itself, but the omission could cause + the PL/pgSQL Debugger to crash while examining the state of a function. +

  • Retry failed calls to CallNamedPipe() on Windows + (Steve Marshall, Magnus) +

    It appears that this function can sometimes fail transiently; + we previously treated any failure as a hard error, which could + confuse LISTEN/NOTIFY as well as other + operations. +

  • Add MUST (Mauritius Island Summer Time) to the default list + of known timezone abbreviations (Xavier Bugaud) +


PrevHomeNext
Release 8.3.8UpRelease 8.3.6
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-3-8.html b/doc/src/sgml/html/release-8-3-8.html new file mode 100644 index 000000000..c2363de8c --- /dev/null +++ b/doc/src/sgml/html/release-8-3-8.html @@ -0,0 +1,552 @@ + +Release 8.3.8

E.54. Release 8.3.8

Release Date: 2009-09-09

This release contains a variety of fixes from 8.3.7. + For information about new features in the 8.3 major release, see + Section E.62. +

E.54.1. Migration to Version 8.3.8

A dump/restore is not required for those running 8.3.X. + However, if you have any hash indexes on interval columns, + you must REINDEX them after updating to 8.3.8. + Also, if you are upgrading from a version earlier than 8.3.5, + see the release notes for 8.3.5. +

E.54.2. Changes

  • Fix Windows shared-memory allocation code (Tsutomu Yamada, Magnus) +

    This bug led to the often-reported "could not reattach + to shared memory" error message. +

  • Force WAL segment switch during pg_start_backup() + (Heikki) +

    This avoids corner cases that could render a base backup unusable. +

  • Disallow RESET ROLE and RESET SESSION + AUTHORIZATION inside security-definer functions (Tom, Heikki) +

    This covers a case that was missed in the previous patch that + disallowed SET ROLE and SET SESSION + AUTHORIZATION inside security-definer functions. + (See CVE-2007-6600) +

  • Make LOAD of an already-loaded loadable module + into a no-op (Tom) +

    Formerly, LOAD would attempt to unload and re-load the + module, but this is unsafe and not all that useful. +

  • Disallow empty passwords during LDAP authentication (Magnus) +

  • Fix handling of sub-SELECTs appearing in the arguments of + an outer-level aggregate function (Tom) +

  • Fix bugs associated with fetching a whole-row value from the + output of a Sort or Materialize plan node (Tom) +

  • Prevent synchronize_seqscans from changing the results of + scrollable and WITH HOLD cursors (Tom) +

  • Revert planner change that disabled partial-index and constraint + exclusion optimizations when there were more than 100 clauses in + an AND or OR list (Tom) +

  • Fix hash calculation for data type interval (Tom) +

    This corrects wrong results for hash joins on interval values. + It also changes the contents of hash indexes on interval columns. + If you have any such indexes, you must REINDEX them + after updating. +

  • Treat to_char(..., 'TH') as an uppercase ordinal + suffix with 'HH'/'HH12' (Heikki) +

    It was previously handled as 'th' (lowercase). +

  • Fix overflow for INTERVAL 'x ms' + when x is more than 2 million and integer + datetimes are in use (Alex Hunsaker) +

  • Fix calculation of distance between a point and a line segment (Tom) +

    This led to incorrect results from a number of geometric operators. +

  • Fix money data type to work in locales where currency + amounts have no fractional digits, e.g. Japan (Itagaki Takahiro) +

  • Fix LIKE for case where pattern contains %_ + (Tom) +

  • Properly round datetime input like + 00:12:57.9999999999999999999999999999 (Tom) +

  • Fix memory leaks in XML operations (Tom) +

  • Fix poor choice of page split point in GiST R-tree operator classes + (Teodor) +

  • Ensure that a "fast shutdown" request will forcibly terminate + open sessions, even if a "smart shutdown" was already in progress + (Fujii Masao) +

  • Avoid performance degradation in bulk inserts into GIN indexes + when the input values are (nearly) in sorted order (Tom) +

  • Correctly enforce NOT NULL domain constraints in some contexts in + PL/pgSQL (Tom) +

  • Fix portability issues in plperl initialization (Andrew Dunstan) +

  • Fix pg_ctl to not go into an infinite loop if + postgresql.conf is empty (Jeff Davis) +

  • Improve pg_dump's efficiency when there are + many large objects (Tamas Vincze) +

  • Use SIGUSR1, not SIGQUIT, as the + failover signal for pg_standby (Heikki) +

  • Make pg_standby's maxretries option + behave as documented (Fujii Masao) +

  • Make contrib/hstore throw an error when a key or + value is too long to fit in its data structure, rather than + silently truncating it (Andrew Gierth) +

  • Fix contrib/xml2's xslt_process() to + properly handle the maximum number of parameters (twenty) (Tom) +

  • Improve robustness of libpq's code to recover + from errors during COPY FROM STDIN (Tom) +

  • Avoid including conflicting readline and editline header files + when both libraries are installed (Zdenek Kotala) +

  • Update time zone data files to tzdata release 2009l + for DST law changes in Bangladesh, Egypt, Jordan, Pakistan, + Argentina/San_Luis, Cuba, Jordan (historical correction only), + Mauritius, Morocco, Palestine, Syria, Tunisia. +


PrevHomeNext
Release 8.3.9UpRelease 8.3.7
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-3-9.html b/doc/src/sgml/html/release-8-3-9.html new file mode 100644 index 000000000..12c868bc5 --- /dev/null +++ b/doc/src/sgml/html/release-8-3-9.html @@ -0,0 +1,537 @@ + +Release 8.3.9

E.53. Release 8.3.9

Release Date: 2009-12-14

This release contains a variety of fixes from 8.3.8. + For information about new features in the 8.3 major release, see + Section E.62. +

E.53.1. Migration to Version 8.3.9

A dump/restore is not required for those running 8.3.X. + However, if you are upgrading from a version earlier than 8.3.8, + see the release notes for 8.3.8. +

E.53.2. Changes

  • Protect against indirect security threats caused by index functions + changing session-local state (Gurjeet Singh, Tom) +

    This change prevents allegedly-immutable index functions from possibly + subverting a superuser's session (CVE-2009-4136). +

  • Reject SSL certificates containing an embedded null byte in the common + name (CN) field (Magnus) +

    This prevents unintended matching of a certificate to a server or client + name during SSL validation (CVE-2009-4034). +

  • Fix possible crash during backend-startup-time cache initialization (Tom) +

  • Avoid crash on empty thesaurus dictionary (Tom) +

  • Prevent signals from interrupting VACUUM at unsafe times + (Alvaro) +

    This fix prevents a PANIC if a VACUUM FULL is canceled + after it's already committed its tuple movements, as well as transient + errors if a plain VACUUM is interrupted after having + truncated the table. +

  • Fix possible crash due to integer overflow in hash table size + calculation (Tom) +

    This could occur with extremely large planner estimates for the size of + a hashjoin's result. +

  • Fix very rare crash in inet/cidr comparisons (Chris + Mikkelson) +

  • Ensure that shared tuple-level locks held by prepared transactions are + not ignored (Heikki) +

  • Fix premature drop of temporary files used for a cursor that is accessed + within a subtransaction (Heikki) +

  • Fix memory leak in syslogger process when rotating to a new CSV logfile + (Tom) +

  • Fix Windows permission-downgrade logic (Jesse Morris) +

    This fixes some cases where the database failed to start on Windows, + often with misleading error messages such as "could not locate + matching postgres executable". +

  • Fix incorrect logic for GiST index page splits, when the split depends + on a non-first column of the index (Paul Ramsey) +

  • Don't error out if recycling or removing an old WAL file fails at the + end of checkpoint (Heikki) +

    It's better to treat the problem as non-fatal and allow the checkpoint + to complete. Future checkpoints will retry the removal. Such problems + are not expected in normal operation, but have been seen to be + caused by misdesigned Windows anti-virus and backup software. +

  • Ensure WAL files aren't repeatedly archived on Windows (Heikki) +

    This is another symptom that could happen if some other process + interfered with deletion of a no-longer-needed file. +

  • Fix PAM password processing to be more robust (Tom) +

    The previous code is known to fail with the combination of the Linux + pam_krb5 PAM module with Microsoft Active Directory as the + domain controller. It might have problems elsewhere too, since it was + making unjustified assumptions about what arguments the PAM stack would + pass to it. +

  • Raise the maximum authentication token (Kerberos ticket) size in GSSAPI + and SSPI authentication methods (Ian Turner) +

    While the old 2000-byte limit was more than enough for Unix Kerberos + implementations, tickets issued by Windows Domain Controllers can be + much larger. +

  • Re-enable collection of access statistics for sequences (Akira Kurosawa) +

    This used to work but was broken in 8.3. +

  • Fix processing of ownership dependencies during CREATE OR + REPLACE FUNCTION (Tom) +

  • Fix incorrect handling of WHERE + x=x conditions (Tom) +

    In some cases these could get ignored as redundant, but they aren't + — they're equivalent to x IS NOT NULL. +

  • Make text search parser accept underscores in XML attributes (Peter) +

  • Fix encoding handling in xml binary input (Heikki) +

    If the XML header doesn't specify an encoding, we now assume UTF-8 by + default; the previous handling was inconsistent. +

  • Fix bug with calling plperl from plperlu or vice + versa (Tom) +

    An error exit from the inner function could result in crashes due to + failure to re-select the correct Perl interpreter for the outer function. +

  • Fix session-lifespan memory leak when a PL/Perl function is redefined + (Tom) +

  • Ensure that Perl arrays are properly converted to + PostgreSQL arrays when returned by a set-returning + PL/Perl function (Andrew Dunstan, Abhijit Menon-Sen) +

    This worked correctly already for non-set-returning functions. +

  • Fix rare crash in exception processing in PL/Python (Peter) +

  • In contrib/pg_standby, disable triggering failover with a + signal on Windows (Fujii Masao) +

    This never did anything useful, because Windows doesn't have Unix-style + signals, but recent changes made it actually crash. +

  • Ensure psql's flex module is compiled with the correct + system header definitions (Tom) +

    This fixes build failures on platforms where + --enable-largefile causes incompatible changes in the + generated code. +

  • Make the postmaster ignore any application_name parameter in + connection request packets, to improve compatibility with future libpq + versions (Tom) +

  • Update the timezone abbreviation files to match current reality (Joachim + Wieland) +

    This includes adding IDT and SGT to the default + timezone abbreviation set. +

  • Update time zone data files to tzdata release 2009s + for DST law changes in Antarctica, Argentina, Bangladesh, Fiji, + Novokuznetsk, Pakistan, Palestine, Samoa, Syria; also historical + corrections for Hong Kong. +


PrevHomeNext
Release 8.3.10UpRelease 8.3.8
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-3.html b/doc/src/sgml/html/release-8-3.html new file mode 100644 index 000000000..77dde5e43 --- /dev/null +++ b/doc/src/sgml/html/release-8-3.html @@ -0,0 +1,3902 @@ + +Release 8.3

E.62. Release 8.3

Release Date: 2008-02-04

E.62.1. Overview

With significant new functionality and performance enhancements, + this release represents a major leap forward for + PostgreSQL. This was made possible by a growing + community that has dramatically accelerated the pace of + development. This release adds the following major features: +

  • Full text search is integrated into the core database system +

  • Support for the SQL/XML standard, including new operators and an + XML data type +

  • Enumerated data types (ENUM) +

  • Arrays of composite types +

  • Universally Unique Identifier (UUID) data type +

  • Add control over whether NULLs sort first or last +

  • Updatable cursors +

  • Server configuration parameters can now be set on a per-function + basis +

  • User-defined types can now have type modifiers +

  • Automatically re-plan cached queries when table + definitions change or statistics are updated +

  • Numerous improvements in logging and statistics collection +

  • Support Security Service Provider Interface (SSPI) for + authentication on Windows +

  • Support multiple concurrent autovacuum processes, and other + autovacuum improvements +

  • Allow the whole PostgreSQL distribution to be compiled + with Microsoft Visual C++ +

Major performance improvements are listed below. Most of + these enhancements are automatic and do not require user changes or + tuning: +

  • Asynchronous commit delays writes to WAL during transaction commit +

  • Checkpoint writes can be spread over a longer time period to smooth + the I/O spike during each checkpoint +

  • Heap-Only Tuples (HOT) accelerate space reuse for + most UPDATEs and DELETEs +

  • Just-in-time background writer strategy improves disk write + efficiency +

  • Using non-persistent transaction IDs for read-only transactions + reduces overhead and VACUUM requirements +

  • Per-field and per-row storage overhead has been reduced +

  • Large sequential scans no longer force out frequently used + cached pages +

  • Concurrent large sequential scans can now share disk reads +

  • ORDER BY ... LIMIT can be done without sorting +

The above items are explained in more detail in the sections below. +

E.62.2. Migration to Version 8.3

A dump/restore using pg_dump is + required for those wishing to migrate data from any previous + release. +

Observe the following incompatibilities: +

E.62.2.1. General

  • Non-character data types are no longer automatically cast to + TEXT (Peter, Tom) +

    Previously, if a non-character value was supplied to an operator or + function that requires text input, it was automatically + cast to text, for most (though not all) built-in data types. + This no longer happens: an explicit cast to text is now + required for all non-character-string types. For example, these + expressions formerly worked: + +

    substr(current_date, 1, 4)
    +23 LIKE '2%'

    + + but will now draw "function does not exist" and "operator + does not exist" errors respectively. Use an explicit cast instead: + +

    substr(current_date::text, 1, 4)
    +23::text LIKE '2%'

    + + (Of course, you can use the more verbose CAST() syntax too.) + The reason for the change is that these automatic casts too often caused + surprising behavior. An example is that in previous releases, this + expression was accepted but did not do what was expected: + +

    current_date < 2017-11-17

    + + This is actually comparing a date to an integer, which should be + (and now is) rejected — but in the presence of automatic + casts both sides were cast to text and a textual comparison + was done, because the text < text operator was able + to match the expression when no other < operator could. +

    Types char(n) and + varchar(n) still cast to text + automatically. Also, automatic casting to text still works for + inputs to the concatenation (||) operator, so long as least + one input is a character-string type. +

  • Full text search features from contrib/tsearch2 have + been moved into the core server, with some minor syntax changes +

    contrib/tsearch2 now contains a compatibility + interface. +

  • ARRAY(SELECT ...), where the SELECT + returns no rows, now returns an empty array, rather than NULL + (Tom) +

  • The array type name for a base data type is no longer always the base + type's name with an underscore prefix +

    The old naming convention is still honored when possible, but + application code should no longer depend on it. Instead + use the new pg_type.typarray column to + identify the array data type associated with a given type. +

  • ORDER BY ... USING operator must now + use a less-than or greater-than operator that is + defined in a btree operator class +

    This restriction was added to prevent inconsistent results. +

  • SET LOCAL changes now persist until + the end of the outermost transaction, unless rolled back (Tom) +

    Previously SET LOCAL's effects were lost + after subtransaction commit (RELEASE SAVEPOINT + or exit from a PL/pgSQL exception block). +

  • Commands rejected in transaction blocks are now also rejected in + multiple-statement query strings (Tom) +

    For example, "BEGIN; DROP DATABASE; COMMIT" will now be + rejected even if submitted as a single query message. +

  • ROLLBACK outside a transaction block now + issues NOTICE instead of WARNING (Bruce) +

  • Prevent NOTIFY/LISTEN/UNLISTEN + from accepting schema-qualified names (Bruce) +

    Formerly, these commands accepted schema.relation but + ignored the schema part, which was confusing. +

  • ALTER SEQUENCE no longer affects the sequence's + currval() state (Tom) +

  • Foreign keys now must match indexable conditions for + cross-data-type references (Tom) +

    This improves semantic consistency and helps avoid + performance problems. +

  • Restrict object size functions to users who have reasonable + permissions to view such information (Tom) +

    For example, pg_database_size() now requires + CONNECT permission, which is granted to everyone by + default. pg_tablespace_size() requires + CREATE permission in the tablespace, or is allowed if + the tablespace is the default tablespace for the database. +

  • Remove the undocumented !!= (not in) operator (Tom) +

    NOT IN (SELECT ...) is the proper way to + perform this operation. +

  • Internal hashing functions are now more uniformly-distributed (Tom) +

    If application code was computing and storing hash values using + internal PostgreSQL hashing functions, the hash + values must be regenerated. +

  • C-code conventions for handling variable-length data values + have changed (Greg Stark, Tom) +

    The new SET_VARSIZE() macro must be used + to set the length of generated varlena values. Also, it + might be necessary to expand ("de-TOAST") input values + in more cases. +

  • Continuous archiving no longer reports each successful archive + operation to the server logs unless DEBUG level is used + (Simon) +

E.62.2.2. Configuration Parameters

  • Numerous changes in administrative server parameters +

    bgwriter_lru_percent, + bgwriter_all_percent, + bgwriter_all_maxpages, + stats_start_collector, and + stats_reset_on_server_start are removed. + redirect_stderr is renamed to + logging_collector. + stats_command_string is renamed to + track_activities. + stats_block_level and stats_row_level + are merged into track_counts. + A new boolean configuration parameter, archive_mode, + controls archiving. Autovacuum's default settings have changed. +

  • Remove stats_start_collector parameter (Tom) +

    We now always start the collector process, unless UDP + socket creation fails. +

  • Remove stats_reset_on_server_start parameter (Tom) +

    This was removed because pg_stat_reset() + can be used for this purpose. +

  • Commenting out a parameter in postgresql.conf now + causes it to revert to its default value (Joachim Wieland) +

    Previously, commenting out an entry left the parameter's value unchanged + until the next server restart. +

E.62.2.3. Character Encodings

  • Add more checks for invalidly-encoded data (Andrew) +

    This change plugs some holes that existed in literal backslash + escape string processing and COPY escape + processing. Now the de-escaped string is rechecked to see if the + result created an invalid multi-byte character. +

  • Disallow database encodings that are inconsistent with the server's + locale setting (Tom) +

    On most platforms, C locale is the only locale that + will work with any database encoding. Other locale settings imply + a specific encoding and will misbehave if the database encoding + is something different. (Typical symptoms include bogus textual + sort order and wrong results from upper() or + lower().) The server now rejects attempts to create + databases that have an incompatible encoding. +

  • Ensure that chr() cannot create + invalidly-encoded values (Andrew) +

    In UTF8-encoded databases the argument of chr() is + now treated as a Unicode code point. In other multi-byte encodings + chr()'s argument must designate a 7-bit ASCII + character. Zero is no longer accepted. + ascii() has been adjusted to match. +

  • Adjust convert() behavior to ensure encoding + validity (Andrew) +

    The two argument form of convert() has been + removed. The three argument form now takes a bytea + first argument and returns a bytea. To cover the + loss of functionality, three new functions have been added: +

    • convert_from(bytea, name) returns + text — converts the first argument from the named + encoding to the database encoding +

    • convert_to(text, name) returns + bytea — converts the first argument from the + database encoding to the named encoding +

    • length(bytea, name) returns + integer — gives the length of the first + argument in characters in the named encoding +

  • Remove convert(argument USING conversion_name) + (Andrew) +

    Its behavior did not match the SQL standard. +

  • Make JOHAB encoding client-only (Tatsuo) +

    JOHAB is not safe as a server-side encoding. +

E.62.3. Changes

Below you will find a detailed account of the + changes between PostgreSQL 8.3 and + the previous major release. +

E.62.3.1. Performance

  • Asynchronous commit delays writes to WAL during transaction commit + (Simon) +

    This feature dramatically increases performance for short data-modifying + transactions. The disadvantage is that because disk writes are delayed, + if the database or operating system crashes before data is written to + the disk, committed data will be lost. This feature is useful for + applications that can accept some data loss. Unlike turning off + fsync, using asynchronous commit does not put + database consistency at risk; the worst case is that after a crash the + last few reportedly-committed transactions might not be committed after + all. + This feature is enabled by turning off synchronous_commit + (which can be done per-session or per-transaction, if some transactions + are critical and others are not). + wal_writer_delay can be adjusted to control the maximum + delay before transactions actually reach disk. +

  • Checkpoint writes can be spread over a longer time period to smooth + the I/O spike during each checkpoint (Itagaki Takahiro and Heikki + Linnakangas) +

    Previously all modified buffers were forced to disk as quickly as + possible during a + checkpoint, causing an I/O spike that decreased server performance. + This new approach spreads out disk writes during checkpoints, + reducing peak I/O usage. (User-requested and shutdown checkpoints + are still written as quickly as possible.) +

  • Heap-Only Tuples (HOT) accelerate space reuse for most + UPDATEs and DELETEs (Pavan Deolasee, with + ideas from many others) +

    UPDATEs and DELETEs leave dead tuples + behind, as do failed INSERTs. Previously only + VACUUM could reclaim space taken by dead tuples. With + HOT dead tuple space can be automatically reclaimed at + the time of INSERT or UPDATE if no changes + are made to indexed columns. This allows for more consistent + performance. Also, HOT avoids adding duplicate index + entries. +

  • Just-in-time background writer strategy improves disk write + efficiency (Greg Smith, Itagaki Takahiro) +

    This greatly reduces the need for manual tuning of the background + writer. +

  • Per-field and per-row storage overhead have been reduced + (Greg Stark, Heikki Linnakangas) +

    Variable-length data types with data values less than 128 bytes long + will see a storage decrease of 3 to 6 bytes. For example, two adjacent + char(1) fields now use 4 bytes instead of 16. Row headers + are also 4 bytes shorter than before. +

  • Using non-persistent transaction IDs for read-only transactions + reduces overhead and VACUUM requirements (Florian Pflug) +

    Non-persistent transaction IDs do not increment the global + transaction counter. Therefore, they reduce the load on + pg_clog and increase the time between forced + vacuums to prevent transaction ID wraparound. + Other performance + improvements were also made that should improve concurrency. +

  • Avoid incrementing the command counter after a read-only command (Tom) +

    There was formerly a hard limit of 232 + (4 billion) commands per transaction. Now only commands that + actually changed the database count, so while this limit still + exists, it should be significantly less annoying. +

  • Create a dedicated WAL writer process to off-load + work from backends (Simon) +

  • Skip unnecessary WAL writes for CLUSTER and + COPY (Simon) +

    Unless WAL archiving is enabled, the system now avoids WAL writes + for CLUSTER and just fsync()s the + table at the end of the command. It also does the same for + COPY if the table was created in the same + transaction. +

  • Large sequential scans no longer force out frequently used + cached pages (Simon, Heikki, Tom) +

  • Concurrent large sequential scans can now share disk reads (Jeff Davis) +

    This is accomplished by starting the new sequential scan in the + middle of the table (where another sequential scan is already + in-progress) and wrapping around to the beginning to finish. This + can affect the order of returned rows in a query that does not + specify ORDER BY. The synchronize_seqscans + configuration parameter can be used to disable this if necessary. +

  • ORDER BY ... LIMIT can be done without sorting + (Greg Stark) +

    This is done by sequentially scanning the table and tracking just + the "top N" candidate rows, rather than performing a + full sort of the entire table. This is useful when there is no + matching index and the LIMIT is not large. +

  • Put a rate limit on messages sent to the statistics + collector by backends + (Tom) +

    This reduces overhead for short transactions, but might sometimes + increase the delay before statistics are tallied. +

  • Improve hash join performance for cases with many NULLs (Tom) +

  • Speed up operator lookup for cases with non-exact datatype matches (Tom) +

E.62.3.2. Server

  • Autovacuum is now enabled by default (Alvaro) +

    Several changes were made to eliminate disadvantages of having + autovacuum enabled, thereby justifying the change in default. + Several other autovacuum parameter defaults were also modified. +

  • Support multiple concurrent autovacuum processes (Alvaro, Itagaki + Takahiro) +

    This allows multiple vacuums to run concurrently. This prevents + vacuuming of a large table from delaying vacuuming of smaller tables. +

  • Automatically re-plan cached queries when table + definitions change or statistics are updated (Tom) +

    Previously PL/pgSQL functions that referenced temporary tables + would fail if the temporary table was dropped and recreated + between function invocations, unless EXECUTE was + used. This improvement fixes that problem and many related issues. +

  • Add a temp_tablespaces parameter to control + the tablespaces for temporary tables and files (Jaime Casanova, + Albert Cervera, Bernd Helmle) +

    This parameter defines a list of tablespaces to be used. This + enables spreading the I/O load across multiple tablespaces. A random + tablespace is chosen each time a temporary object is created. + Temporary files are no longer stored in per-database + pgsql_tmp/ directories but in per-tablespace + directories. +

  • Place temporary tables' TOAST tables in special schemas named + pg_toast_temp_nnn (Tom) +

    This allows low-level code to recognize these tables as temporary, + which enables various optimizations such as not WAL-logging changes + and using local rather than shared buffers for access. This also + fixes a bug wherein backends unexpectedly held open file references + to temporary TOAST tables. +

  • Fix problem that a constant flow of new connection requests could + indefinitely delay the postmaster from completing a shutdown or + a crash restart (Tom) +

  • Guard against a very-low-probability data loss scenario by preventing + re-use of a deleted table's relfilenode until after the next + checkpoint (Heikki) +

  • Fix CREATE CONSTRAINT TRIGGER + to convert old-style foreign key trigger definitions into regular + foreign key constraints (Tom) +

    This will ease porting of foreign key constraints carried forward from + pre-7.3 databases, if they were never converted using + contrib/adddepend. +

  • Fix DEFAULT NULL to override inherited defaults (Tom) +

    DEFAULT NULL was formerly considered a noise phrase, but it + should (and now does) override non-null defaults that would otherwise + be inherited from a parent table or domain. +

  • Add new encodings EUC_JIS_2004 and SHIFT_JIS_2004 (Tatsuo) +

    These new encodings can be converted to and from UTF-8. +

  • Change server startup log message from "database system is + ready" to "database system is ready to accept + connections", and adjust its timing +

    The message now appears only when the postmaster is really ready + to accept connections. +

E.62.3.3. Monitoring

  • Add log_autovacuum_min_duration parameter to + support configurable logging of autovacuum activity (Simon, Alvaro) +

  • Add log_lock_waits parameter to log lock waiting + (Simon) +

  • Add log_temp_files parameter to log temporary + file usage (Bill Moran) +

  • Add log_checkpoints parameter to improve logging + of checkpoints (Greg Smith, Heikki) +

  • log_line_prefix now supports + %s and %c escapes in all + processes (Andrew) +

    Previously these escapes worked only for user sessions, not for + background database processes. +

  • Add log_restartpoints to control logging of + point-in-time recovery restart points (Simon) +

  • Last transaction end time is now logged at end of recovery and at + each logged restart point (Simon) +

  • Autovacuum now reports its activity start time in + pg_stat_activity (Tom) +

  • Allow server log output in comma-separated value (CSV) format (Arul + Shaji, Greg Smith, Andrew Dunstan) +

    CSV-format log files can easily be loaded into a database table for + subsequent analysis. +

  • Use PostgreSQL-supplied timezone support for formatting timestamps + displayed in the server log (Tom) +

    This avoids Windows-specific problems with localized time zone + names that are in the wrong encoding. There is a new + log_timezone parameter that controls the timezone + used in log messages, independently of the client-visible + timezone parameter. +

  • New system view pg_stat_bgwriter displays + statistics about background writer activity (Magnus) +

  • Add new columns for database-wide tuple statistics to + pg_stat_database (Magnus) +

  • Add an xact_start (transaction start time) column to + pg_stat_activity (Neil) +

    This makes it easier to identify long-running transactions. +

  • Add n_live_tuples and n_dead_tuples columns + to pg_stat_all_tables and related views (Glen + Parker) +

  • Merge stats_block_level and stats_row_level + parameters into a single parameter track_counts, which + controls all messages sent to the statistics collector process + (Tom) +

  • Rename stats_command_string parameter to + track_activities (Tom) +

  • Fix statistical counting of live and dead tuples to recognize that + committed and aborted transactions have different effects (Tom) +

E.62.3.4. Authentication

  • Support Security Service Provider Interface (SSPI) for + authentication on Windows (Magnus) +

  • Support GSSAPI authentication (Henry Hotz, Magnus) +

    This should be preferred to native Kerberos authentication because + GSSAPI is an industry standard. +

  • Support a global SSL configuration file (Victor Wagner) +

  • Add ssl_ciphers parameter to control accepted SSL ciphers + (Victor Wagner) +

  • Add a Kerberos realm parameter, krb_realm (Magnus) +

E.62.3.5. Write-Ahead Log (WAL) and Continuous Archiving

  • Change the timestamps recorded in transaction WAL records from + time_t to TimestampTz representation (Tom) +

    This provides sub-second resolution in WAL, which can be useful for + point-in-time recovery. +

  • Reduce WAL disk space needed by warm standby servers (Simon) +

    This change allows a warm standby server to pass the name of the earliest + still-needed WAL file to the recovery script, allowing automatic removal + of no-longer-needed WAL files. This is done using %r in + the restore_command parameter of + recovery.conf. +

  • New boolean configuration parameter, archive_mode, + controls archiving (Simon) +

    Previously setting archive_command to an empty string + turned off archiving. Now archive_mode turns archiving + on and off, independently of archive_command. This is + useful for stopping archiving temporarily. +

E.62.3.6. Queries

  • Full text search is integrated into the core database + system (Teodor, Oleg) +

    Text search has been improved, moved into the core code, and is now + installed by default. contrib/tsearch2 now contains + a compatibility interface. +

  • Add control over whether NULLs sort first or last (Teodor, Tom) +

    The syntax is ORDER BY ... NULLS FIRST/LAST. +

  • Allow per-column ascending/descending (ASC/DESC) + ordering options for indexes (Teodor, Tom) +

    Previously a query using ORDER BY with mixed + ASC/DESC specifiers could not fully use + an index. Now an index can be fully used in such cases if the + index was created with matching + ASC/DESC specifications. + NULL sort order within an index can be controlled, too. +

  • Allow col IS NULL to use an index (Teodor) +

  • Updatable cursors (Arul Shaji, Tom) +

    This eliminates the need to reference a primary key to + UPDATE or DELETE rows returned by a cursor. + The syntax is UPDATE/DELETE WHERE CURRENT OF. +

  • Allow FOR UPDATE in cursors (Arul Shaji, Tom) +

  • Create a general mechanism that supports casts to and from the + standard string types (TEXT, VARCHAR, + CHAR) for every datatype, by + invoking the datatype's I/O functions (Tom) +

    Previously, such casts were available only for types that had + specialized function(s) for the purpose. + These new casts are assignment-only in the to-string direction, + explicit-only in the other direction, and therefore should create no + surprising behavior. +

  • Allow UNION and related constructs to return a domain + type, when all inputs are of that domain type (Tom) +

    Formerly, the output would be considered to be of the domain's base + type. +

  • Allow limited hashing when using two different data types (Tom) +

    This allows hash joins, hash indexes, hashed subplans, and hash + aggregation to be used in situations involving cross-data-type + comparisons, if the data types have compatible hash functions. + Currently, cross-data-type hashing support exists for + smallint/integer/bigint, + and for float4/float8. +

  • Improve optimizer logic for detecting when variables are equal + in a WHERE clause (Tom) +

    This allows mergejoins to work with descending sort orders, and + improves recognition of redundant sort columns. +

  • Improve performance when planning large inheritance trees in + cases where most tables are excluded by constraints (Tom) +

E.62.3.7. Object Manipulation

  • Arrays of composite types (David Fetter, Andrew, Tom) +

    In addition to arrays of explicitly-declared composite types, + arrays of the rowtypes of regular tables and views are now + supported, except for rowtypes of system catalogs, sequences, and TOAST + tables. +

  • Server configuration parameters can now be set on a per-function + basis (Tom) +

    For example, functions can now set their own + search_path to prevent unexpected behavior if a + different search_path exists at run-time. Security + definer functions should set search_path to + avoid security loopholes. +

  • CREATE/ALTER FUNCTION now supports + COST and ROWS options (Tom) +

    COST allows specification of the cost of a + function call. ROWS allows specification of + the average number or rows returned by a set-returning function. + These values are used by the optimizer in choosing the best plan. +

  • Implement CREATE TABLE LIKE ... INCLUDING + INDEXES (Trevor Hardcastle, Nikhil Sontakke, Neil) +

  • Allow CREATE INDEX CONCURRENTLY to ignore + transactions in other databases (Simon) +

  • Add ALTER VIEW ... RENAME TO and ALTER + SEQUENCE ... RENAME TO (David Fetter, Neil) +

    Previously this could only be done via ALTER TABLE ... + RENAME TO. +

  • Make CREATE/DROP/RENAME DATABASE wait briefly for + conflicting backends to exit before failing (Tom) +

    This increases the likelihood that these commands will succeed. +

  • Allow triggers and rules to be deactivated in groups using a + configuration parameter, for replication purposes (Jan) +

    This allows replication systems to disable triggers and rewrite + rules as a group without modifying the system catalogs directly. + The behavior is controlled by ALTER TABLE and a new + parameter session_replication_role. +

  • User-defined types can now have type modifiers (Teodor, Tom) +

    This allows a user-defined type to take a modifier, like + ssnum(7). Previously only built-in + data types could have modifiers. +

E.62.3.8. Utility Commands

  • Non-superuser database owners now are able to add trusted procedural + languages to their databases by default (Jeremy Drake) +

    While this is reasonably safe, some administrators might wish to + revoke the privilege. It is controlled by + pg_pltemplate.tmpldbacreate. +

  • Allow a session's current parameter setting to be used as the + default for future sessions (Tom) +

    This is done with SET ... FROM CURRENT in + CREATE/ALTER FUNCTION, ALTER + DATABASE, or ALTER ROLE. +

  • Implement new commands DISCARD ALL, + DISCARD PLANS, DISCARD + TEMPORARY, CLOSE ALL, and + DEALLOCATE ALL (Marko Kreen, Neil) +

    These commands simplify resetting a database session to its initial + state, and are particularly useful for connection-pooling software. +

  • Make CLUSTER MVCC-safe (Heikki Linnakangas) +

    Formerly, CLUSTER would discard all tuples + that were committed dead, even if there were still transactions + that should be able to see them under MVCC visibility rules. +

  • Add new CLUSTER syntax: CLUSTER + table USING index + (Holger Schurig) +

    The old CLUSTER syntax is still supported, but + the new form is considered more logical. +

  • Fix EXPLAIN so it can show complex plans + more accurately (Tom) +

    References to subplan outputs are now always shown correctly, + instead of using ?columnN? + for complicated cases. +

  • Limit the amount of information reported when a user is dropped + (Alvaro) +

    Previously, dropping (or attempting to drop) a user who owned many + objects could result in large NOTICE or + ERROR messages listing all these objects; this + caused problems for some client applications. The length of the + message is now limited, although a full list is still sent to the + server log. +

E.62.3.9. Data Types

  • Support for the SQL/XML standard, including new operators and an + XML data type (Nikolay Samokhvalov, Pavel Stehule, Peter) +

  • Enumerated data types (ENUM) (Tom Dunstan) +

    This feature provides convenient support for fields that have a + small, fixed set of allowed values. An example of creating an + ENUM type is + CREATE TYPE mood AS ENUM ('sad', 'ok', 'happy'). +

  • Universally Unique Identifier (UUID) data type (Gevik + Babakhani, Neil) +

    This closely matches RFC 4122. +

  • Widen the MONEY data type to 64 bits (D'Arcy Cain) +

    This greatly increases the range of supported MONEY + values. +

  • Fix float4/float8 to handle + Infinity and NAN (Not A Number) + consistently (Bruce) +

    The code formerly was not consistent about distinguishing + Infinity from overflow conditions. +

  • Allow leading and trailing whitespace during input of + boolean values (Neil) +

  • Prevent COPY from using digits and lowercase letters as + delimiters (Tom) +

E.62.3.10. Functions

  • Add new regular expression functions + regexp_matches(), + regexp_split_to_array(), and + regexp_split_to_table() (Jeremy Drake, Neil) +

    These functions provide extraction of regular expression + subexpressions and allow splitting a string using a POSIX regular + expression. +

  • Add lo_truncate() for large object truncation + (Kris Jurka) +

  • Implement width_bucket() for the float8 + data type (Neil) +

  • Add pg_stat_clear_snapshot() to discard + statistics snapshots collected during the current transaction + (Tom) +

    The first request for statistics in a transaction takes a statistics + snapshot that does not change during the transaction. This function + allows the snapshot to be discarded and a new snapshot loaded during + the next statistics query. This is particularly useful for PL/pgSQL + functions, which are confined to a single transaction. +

  • Add isodow option to EXTRACT() and + date_part() (Bruce) +

    This returns the day of the week, with Sunday as seven. + (dow returns Sunday as zero.) +

  • Add ID (ISO day of week) and IDDD (ISO + day of year) format codes for to_char(), + to_date(), and to_timestamp() (Brendan + Jurd) +

  • Make to_timestamp() and to_date() + assume TM (trim) option for potentially + variable-width fields (Bruce) +

    This matches Oracle's behavior. +

  • Fix off-by-one conversion error in + to_date()/to_timestamp() + D (non-ISO day of week) fields (Bruce) +

  • Make setseed() return void, rather than a + useless integer value (Neil) +

  • Add a hash function for NUMERIC (Neil) +

    This allows hash indexes and hash-based plans to be used with + NUMERIC columns. +

  • Improve efficiency of + LIKE/ILIKE, especially for + multi-byte character sets like UTF-8 (Andrew, Itagaki Takahiro) +

  • Make currtid() functions require + SELECT privileges on the target table (Tom) +

  • Add several txid_*() functions to query + active transaction IDs (Jan) +

    This is useful for various replication solutions. +

E.62.3.11. PL/pgSQL Server-Side Language

  • Add scrollable cursor support, including directional control in + FETCH (Pavel Stehule) +

  • Allow IN as an alternative to + FROM in PL/pgSQL's FETCH + statement, for consistency with the backend's + FETCH command (Pavel Stehule) +

  • Add MOVE to PL/pgSQL (Magnus, Pavel Stehule, + Neil) +

  • Implement RETURN QUERY (Pavel Stehule, Neil) +

    This adds convenient syntax for PL/pgSQL set-returning functions + that want to return the result of a query. RETURN QUERY + is easier and more efficient than a loop + around RETURN NEXT. +

  • Allow function parameter names to be qualified with the + function's name (Tom) +

    For example, myfunc.myvar. This is particularly + useful for specifying variables in a query where the variable + name might match a column name. +

  • Make qualification of variables with block labels work properly (Tom) +

    Formerly, outer-level block labels could unexpectedly interfere with + recognition of inner-level record or row references. +

  • Tighten requirements for FOR loop + STEP values (Tom) +

    Prevent non-positive STEP values, and handle + loop overflows. +

  • Improve accuracy when reporting syntax error locations (Tom) +

E.62.3.12. Other Server-Side Languages

  • Allow type-name arguments to PL/Perl + spi_prepare() to be data type aliases in + addition to names found in pg_type (Andrew) +

  • Allow type-name arguments to PL/Python + plpy.prepare() to be data type aliases in + addition to names found in pg_type (Andrew) +

  • Allow type-name arguments to PL/Tcl spi_prepare to + be data type aliases in addition to names found in + pg_type (Andrew) +

  • Enable PL/PythonU to compile on Python 2.5 (Marko Kreen) +

  • Support a true PL/Python boolean type in compatible Python versions + (Python 2.3 and later) (Marko Kreen) +

  • Fix PL/Tcl problems with thread-enabled libtcl spawning + multiple threads within the backend (Steve Marshall, Paul Bayer, + Doug Knight) +

    This caused all sorts of unpleasantness. +

E.62.3.13. psql

  • List disabled triggers separately in \d output + (Brendan Jurd) +

  • In \d patterns, always match $ + literally (Tom) +

  • Show aggregate return types in \da output + (Greg Sabino Mullane) +

  • Add the function's volatility status to the output of + \df+ (Neil) +

  • Add \prompt capability (Chad Wagner) +

  • Allow \pset, \t, and + \x to specify on or off, + rather than just toggling (Chad Wagner) +

  • Add \sleep capability (Jan) +

  • Enable \timing output for \copy (Andrew) +

  • Improve \timing resolution on Windows + (Itagaki Takahiro) +

  • Flush \o output after each backslash command (Tom) +

  • Correctly detect and report errors while reading a -f + input file (Peter) +

  • Remove -u option (this option has long been deprecated) + (Tom) +

E.62.3.14. pg_dump

  • Add --tablespaces-only and --roles-only + options to pg_dumpall (Dave Page) +

  • Add an output file option to + pg_dumpall (Dave Page) +

    This is primarily useful on Windows, where output redirection of + child pg_dump processes does not work. +

  • Allow pg_dumpall to accept an initial-connection + database name rather than the default + template1 (Dave Page) +

  • In -n and -t switches, always match + $ literally (Tom) +

  • Improve performance when a database has thousands of objects (Tom) +

  • Remove -u option (this option has long been deprecated) + (Tom) +

E.62.3.15. Other Client Applications

  • In initdb, allow the location of the + pg_xlog directory to be specified + (Euler Taveira de Oliveira) +

  • Enable server core dump generation in pg_regress + on supported operating systems (Andrew) +

  • Add a -t (timeout) parameter to pg_ctl + (Bruce) +

    This controls how long pg_ctl will wait when waiting + for server startup or shutdown. Formerly the timeout was hard-wired + as 60 seconds. +

  • Add a pg_ctl option to control generation + of server core dumps (Andrew) +

  • Allow Control-C to cancel clusterdb, + reindexdb, and vacuumdb (Itagaki + Takahiro, Magnus) +

  • Suppress command tag output for createdb, + createuser, dropdb, and + dropuser (Peter) +

    The --quiet option is ignored and will be removed in 8.4. + Progress messages when acting on all databases now go to stdout + instead of stderr because they are not actually errors. +

E.62.3.16. libpq

  • Interpret the dbName parameter of + PQsetdbLogin() as a conninfo string if + it contains an equals sign (Andrew) +

    This allows use of conninfo strings in client + programs that still use PQsetdbLogin(). +

  • Support a global SSL configuration file (Victor + Wagner) +

  • Add environment variable PGSSLKEY to control + SSL hardware keys (Victor Wagner) +

  • Add lo_truncate() for large object + truncation (Kris Jurka) +

  • Add PQconnectionNeedsPassword() that returns + true if the server required a password but none was supplied + (Joe Conway, Tom) +

    If this returns true after a failed connection attempt, a client + application should prompt the user for a password. In the past + applications have had to check for a specific error message string to + decide whether a password is needed; that approach is now + deprecated. +

  • Add PQconnectionUsedPassword() that returns + true if the supplied password was actually used + (Joe Conway, Tom) +

    This is useful in some security contexts where it is important + to know whether a user-supplied password is actually valid. +

E.62.3.17. ecpg

  • Use V3 frontend/backend protocol (Michael) +

    This adds support for server-side prepared statements. +

  • Use native threads, instead of pthreads, on Windows (Magnus) +

  • Improve thread-safety of ecpglib (Itagaki Takahiro) +

  • Make the ecpg libraries export only necessary API symbols (Michael) +

E.62.3.18. Windows Port

  • Allow the whole PostgreSQL distribution to be compiled + with Microsoft Visual C++ (Magnus and others) +

    This allows Windows-based developers to use familiar development + and debugging tools. + Windows executables made with Visual C++ might also have better + stability and performance than those made with other tool sets. + The client-only Visual C++ build scripts have been removed. +

  • Drastically reduce postmaster's memory usage when it has many child + processes (Magnus) +

  • Allow regression tests to be started by an administrative + user (Magnus) +

  • Add native shared memory implementation (Magnus) +

E.62.3.19. Server Programming Interface (SPI)

  • Add cursor-related functionality in SPI (Pavel Stehule) +

    Allow access to the cursor-related planning options, and add + FETCH/MOVE routines. +

  • Allow execution of cursor commands through + SPI_execute (Tom) +

    The macro SPI_ERROR_CURSOR still exists but will + never be returned. +

  • SPI plan pointers are now declared as SPIPlanPtr instead of + void * (Tom) +

    This does not break application code, but switching is + recommended to help catch simple programming mistakes. +

E.62.3.20. Build Options

  • Add configure option --enable-profiling + to enable code profiling (works only with gcc) + (Korry Douglas and Nikhil Sontakke) +

  • Add configure option --with-system-tzdata + to use the operating system's time zone database (Peter) +

  • Fix PGXS so extensions can be built against PostgreSQL + installations whose pg_config program does not + appear first in the PATH (Tom) +

  • Support gmake draft when building the + SGML documentation (Bruce) +

    Unless draft is used, the documentation build will + now be repeated if necessary to ensure the index is up-to-date. +

E.62.3.21. Source Code

  • Rename macro DLLIMPORT to PGDLLIMPORT to + avoid conflicting with third party includes (like Tcl) that + define DLLIMPORT (Magnus) +

  • Create "operator families" to improve planning of + queries involving cross-data-type comparisons (Tom) +

  • Update GIN extractQuery() API to allow signalling + that nothing can satisfy the query (Teodor) +

  • Move NAMEDATALEN definition from + postgres_ext.h to pg_config_manual.h + (Peter) +

  • Provide strlcpy() and + strlcat() on all platforms, and replace + error-prone uses of strncpy(), + strncat(), etc (Peter) +

  • Create hooks to let an external plugin monitor (or even replace) the + planner and create plans for hypothetical situations (Gurjeet + Singh, Tom) +

  • Create a function variable join_search_hook to let plugins + override the join search order portion of the planner (Julius + Stroffek) +

  • Add tas() support for Renesas' M32R processor + (Kazuhiro Inaoka) +

  • quote_identifier() and + pg_dump no longer quote keywords that are + unreserved according to the grammar (Tom) +

  • Change the on-disk representation of the NUMERIC + data type so that the sign_dscale word comes + before the weight (Tom) +

  • Use SYSV semaphores rather than POSIX on Darwin + >= 6.0, i.e., OS X 10.2 and up (Chris Marcellino) +

  • Add acronym and NFS documentation + sections (Bruce) +

  • "Postgres" is now documented as an accepted alias for + "PostgreSQL" (Peter) +

  • Add documentation about preventing database server spoofing when + the server is down (Bruce) +

E.62.3.22. Contrib

  • Move contrib README content into the + main PostgreSQL documentation (Albert Cervera i + Areny) +

  • Add contrib/pageinspect module for low-level + page inspection (Simon, Heikki) +

  • Add contrib/pg_standby module for controlling + warm standby operation (Simon) +

  • Add contrib/uuid-ossp module for generating + UUID values using the OSSP UUID library (Peter) +

    Use configure + --with-ossp-uuid to activate. This takes + advantage of the new UUID builtin type. +

  • Add contrib/dict_int, + contrib/dict_xsyn, and + contrib/test_parser modules to provide + sample add-on text search dictionary templates and parsers + (Sergey Karpov) +

  • Allow contrib/pgbench to set the fillfactor (Pavan + Deolasee) +

  • Add timestamps to contrib/pgbench -l + (Greg Smith) +

  • Add usage count statistics to + contrib/pgbuffercache (Greg Smith) +

  • Add GIN support for contrib/hstore (Teodor) +

  • Add GIN support for contrib/pg_trgm (Guillaume Smet, Teodor) +

  • Update OS/X startup scripts in + contrib/start-scripts (Mark Cotner, David + Fetter) +

  • Restrict pgrowlocks() and + dblink_get_pkey() to users who have + SELECT privilege on the target table (Tom) +

  • Restrict contrib/pgstattuple functions to + superusers (Tom) +

  • contrib/xml2 is deprecated and planned for + removal in 8.4 (Peter) +

    The new XML support in core PostgreSQL supersedes this module. +


PrevHomeNext
Release 8.3.1UpRelease 8.2.23
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-4-1.html b/doc/src/sgml/html/release-8-4-1.html new file mode 100644 index 000000000..b88642eb6 --- /dev/null +++ b/doc/src/sgml/html/release-8-4-1.html @@ -0,0 +1,578 @@ + +Release 8.4.1

E.38. Release 8.4.1

Release Date: 2009-09-09

This release contains a variety of fixes from 8.4. + For information about new features in the 8.4 major release, see + Section E.39. +

E.38.1. Migration to Version 8.4.1

A dump/restore is not required for those running 8.4.X. +

E.38.2. Changes

  • Fix WAL page header initialization at the end of archive recovery + (Heikki) +

    This could lead to failure to process the WAL in a subsequent + archive recovery. +

  • Fix "cannot make new WAL entries during recovery" error (Tom) +

  • Fix problem that could make expired rows visible after a crash (Tom) +

    This bug involved a page status bit potentially not being set + correctly after a server crash. +

  • Disallow RESET ROLE and RESET SESSION + AUTHORIZATION inside security-definer functions (Tom, Heikki) +

    This covers a case that was missed in the previous patch that + disallowed SET ROLE and SET SESSION + AUTHORIZATION inside security-definer functions. + (See CVE-2007-6600) +

  • Make LOAD of an already-loaded loadable module + into a no-op (Tom) +

    Formerly, LOAD would attempt to unload and re-load the + module, but this is unsafe and not all that useful. +

  • Make window function PARTITION BY and ORDER BY + items always be interpreted as simple expressions (Tom) +

    In 8.4.0 these lists were parsed following the rules used for + top-level GROUP BY and ORDER BY lists. + But this was not correct per the SQL standard, and it led to possible + circularity. +

  • Fix several errors in planning of semi-joins (Tom) +

    These led to wrong query results in some cases where IN + or EXISTS was used together with another join. +

  • Fix handling of whole-row references to subqueries that are within + an outer join (Tom) +

    An example is + SELECT COUNT(ss.*) FROM ... LEFT JOIN (SELECT ...) ss ON .... + Here, ss.* would be treated as ROW(NULL,NULL,...) + for null-extended join rows, which is not the same as a simple NULL. + Now it is treated as a simple NULL. +

  • Fix Windows shared-memory allocation code (Tsutomu Yamada, Magnus) +

    This bug led to the often-reported "could not reattach + to shared memory" error message. +

  • Fix locale handling with plperl (Heikki) +

    This bug could cause the server's locale setting to change when a + plperl function is called, leading to data corruption. +

  • Fix handling of reloptions to ensure setting one option doesn't + force default values for others (Itagaki Takahiro) +

  • Ensure that a "fast shutdown" request will forcibly terminate + open sessions, even if a "smart shutdown" was already in progress + (Fujii Masao) +

  • Avoid memory leak for array_agg() in GROUP BY + queries (Tom) +

  • Treat to_char(..., 'TH') as an uppercase ordinal + suffix with 'HH'/'HH12' (Heikki) +

    It was previously handled as 'th' (lowercase). +

  • Include the fractional part in the result of + EXTRACT(second) and + EXTRACT(milliseconds) for + time and time with time zone inputs (Tom) +

    This has always worked for floating-point datetime configurations, + but was broken in the integer datetime code. +

  • Fix overflow for INTERVAL 'x ms' + when x is more than 2 million and integer + datetimes are in use (Alex Hunsaker) +

  • Improve performance when processing toasted values in index scans (Tom) +

    This is particularly useful for PostGIS. +

  • Fix a typo that disabled commit_delay (Jeff Janes) +

  • Output early-startup messages to postmaster.log if the + server is started in silent mode (Tom) +

    Previously such error messages were discarded, leading to + difficulty in debugging. +

  • Remove translated FAQs (Peter) +

    They are now on the wiki. The + main FAQ was moved to the wiki some time ago. +

  • Fix pg_ctl to not go into an infinite loop if + postgresql.conf is empty (Jeff Davis) +

  • Fix several errors in pg_dump's + --binary-upgrade mode (Bruce, Tom) +

    pg_dump --binary-upgrade is used by pg_migrator. +

  • Fix contrib/xml2's xslt_process() to + properly handle the maximum number of parameters (twenty) (Tom) +

  • Improve robustness of libpq's code to recover + from errors during COPY FROM STDIN (Tom) +

  • Avoid including conflicting readline and editline header files + when both libraries are installed (Zdenek Kotala) +

  • Work around gcc bug that causes "floating-point exception" + instead of "division by zero" on some platforms (Tom) +

  • Update time zone data files to tzdata release 2009l + for DST law changes in Bangladesh, Egypt, Mauritius. +


PrevHomeNext
Release 8.4.2UpRelease 8.4
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-4-10.html b/doc/src/sgml/html/release-8-4-10.html new file mode 100644 index 000000000..b989a6524 --- /dev/null +++ b/doc/src/sgml/html/release-8-4-10.html @@ -0,0 +1,584 @@ + +Release 8.4.10

E.29. Release 8.4.10

Release Date: 2011-12-05

This release contains a variety of fixes from 8.4.9. + For information about new features in the 8.4 major release, see + Section E.39. +

E.29.1. Migration to Version 8.4.10

A dump/restore is not required for those running 8.4.X. +

However, a longstanding error was discovered in the definition of the + information_schema.referential_constraints view. If you + rely on correct results from that view, you should replace its + definition as explained in the first changelog item below. +

Also, if you are upgrading from a version earlier than 8.4.8, + see the release notes for 8.4.8. +

E.29.2. Changes

  • Fix bugs in information_schema.referential_constraints view + (Tom Lane) +

    This view was being insufficiently careful about matching the + foreign-key constraint to the depended-on primary or unique key + constraint. That could result in failure to show a foreign key + constraint at all, or showing it multiple times, or claiming that it + depends on a different constraint than the one it really does. +

    Since the view definition is installed by initdb, + merely upgrading will not fix the problem. If you need to fix this + in an existing installation, you can (as a superuser) drop the + information_schema schema then re-create it by sourcing + SHAREDIR/information_schema.sql. + (Run pg_config --sharedir if you're uncertain where + SHAREDIR is.) This must be repeated in each database + to be fixed. +

  • Fix incorrect replay of WAL records for GIN index updates + (Tom Lane) +

    This could result in transiently failing to find index entries after + a crash, or on a hot-standby server. The problem would be repaired + by the next VACUUM of the index, however. +

  • Fix TOAST-related data corruption during CREATE TABLE dest AS + SELECT * FROM src or INSERT INTO dest SELECT * FROM src + (Tom Lane) +

    If a table has been modified by ALTER TABLE ADD COLUMN, + attempts to copy its data verbatim to another table could produce + corrupt results in certain corner cases. + The problem can only manifest in this precise form in 8.4 and later, + but we patched earlier versions as well in case there are other code + paths that could trigger the same bug. +

  • Fix race condition during toast table access from stale syscache entries + (Tom Lane) +

    The typical symptom was transient errors like "missing chunk + number 0 for toast value NNNNN in pg_toast_2619", where the cited + toast table would always belong to a system catalog. +

  • Track dependencies of functions on items used in parameter default + expressions (Tom Lane) +

    Previously, a referenced object could be dropped without having dropped + or modified the function, leading to misbehavior when the function was + used. Note that merely installing this update will not fix the missing + dependency entries; to do that, you'd need to CREATE OR + REPLACE each such function afterwards. If you have functions whose + defaults depend on non-built-in objects, doing so is recommended. +

  • Allow inlining of set-returning SQL functions with multiple OUT + parameters (Tom Lane) +

  • Make DatumGetInetP() unpack inet datums that have a 1-byte + header, and add a new macro, DatumGetInetPP(), that does + not (Heikki Linnakangas) +

    This change affects no core code, but might prevent crashes in add-on + code that expects DatumGetInetP() to produce an unpacked + datum as per usual convention. +

  • Improve locale support in money type's input and output + (Tom Lane) +

    Aside from not supporting all standard + lc_monetary + formatting options, the input and output functions were inconsistent, + meaning there were locales in which dumped money values could + not be re-read. +

  • Don't let transform_null_equals + affect CASE foo WHEN NULL ... constructs + (Heikki Linnakangas) +

    transform_null_equals is only supposed to affect + foo = NULL expressions written directly by the user, not + equality checks generated internally by this form of CASE. +

  • Change foreign-key trigger creation order to better support + self-referential foreign keys (Tom Lane) +

    For a cascading foreign key that references its own table, a row update + will fire both the ON UPDATE trigger and the + CHECK trigger as one event. The ON UPDATE + trigger must execute first, else the CHECK will check a + non-final state of the row and possibly throw an inappropriate error. + However, the firing order of these triggers is determined by their + names, which generally sort in creation order since the triggers have + auto-generated names following the convention + "RI_ConstraintTrigger_NNNN". A proper fix would require + modifying that convention, which we will do in 9.2, but it seems risky + to change it in existing releases. So this patch just changes the + creation order of the triggers. Users encountering this type of error + should drop and re-create the foreign key constraint to get its + triggers into the right order. +

  • Avoid floating-point underflow while tracking buffer allocation rate + (Greg Matthews) +

    While harmless in itself, on certain platforms this would result in + annoying kernel log messages. +

  • Preserve configuration file name and line number values when starting + child processes under Windows (Tom Lane) +

    Formerly, these would not be displayed correctly in the + pg_settings view. +

  • Preserve blank lines within commands in psql's command + history (Robert Haas) +

    The former behavior could cause problems if an empty line was removed + from within a string literal, for example. +

  • Fix pg_dump to dump user-defined casts between + auto-generated types, such as table rowtypes (Tom Lane) +

  • Use the preferred version of xsubpp to build PL/Perl, + not necessarily the operating system's main copy + (David Wheeler and Alex Hunsaker) +

  • Fix incorrect coding in contrib/dict_int and + contrib/dict_xsyn (Tom Lane) +

    Some functions incorrectly assumed that memory returned by + palloc() is guaranteed zeroed. +

  • Honor query cancel interrupts promptly in pgstatindex() + (Robert Haas) +

  • Ensure VPATH builds properly install all server header files + (Peter Eisentraut) +

  • Shorten file names reported in verbose error messages (Peter Eisentraut) +

    Regular builds have always reported just the name of the C file + containing the error message call, but VPATH builds formerly + reported an absolute path name. +

  • Fix interpretation of Windows timezone names for Central America + (Tom Lane) +

    Map "Central America Standard Time" to CST6, not + CST6CDT, because DST is generally not observed anywhere in + Central America. +

  • Update time zone data files to tzdata release 2011n + for DST law changes in Brazil, Cuba, Fiji, Palestine, Russia, and Samoa; + also historical corrections for Alaska and British East Africa. +


PrevHomeNext
Release 8.4.11UpRelease 8.4.9
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-4-11.html b/doc/src/sgml/html/release-8-4-11.html new file mode 100644 index 000000000..c9fbd71b8 --- /dev/null +++ b/doc/src/sgml/html/release-8-4-11.html @@ -0,0 +1,606 @@ + +Release 8.4.11

E.28. Release 8.4.11

Release Date: 2012-02-27

This release contains a variety of fixes from 8.4.10. + For information about new features in the 8.4 major release, see + Section E.39. +

E.28.1. Migration to Version 8.4.11

A dump/restore is not required for those running 8.4.X. +

However, if you are upgrading from a version earlier than 8.4.10, + see the release notes for 8.4.10. +

E.28.2. Changes

  • Require execute permission on the trigger function for + CREATE TRIGGER (Robert Haas) +

    This missing check could allow another user to execute a trigger + function with forged input data, by installing it on a table he owns. + This is only of significance for trigger functions marked + SECURITY DEFINER, since otherwise trigger functions run + as the table owner anyway. (CVE-2012-0866) +

  • Remove arbitrary limitation on length of common name in SSL + certificates (Heikki Linnakangas) +

    Both libpq and the server truncated the common name + extracted from an SSL certificate at 32 bytes. Normally this would + cause nothing worse than an unexpected verification failure, but there + are some rather-implausible scenarios in which it might allow one + certificate holder to impersonate another. The victim would have to + have a common name exactly 32 bytes long, and the attacker would have + to persuade a trusted CA to issue a certificate in which the common + name has that string as a prefix. Impersonating a server would also + require some additional exploit to redirect client connections. + (CVE-2012-0867) +

  • Convert newlines to spaces in names written in pg_dump + comments (Robert Haas) +

    pg_dump was incautious about sanitizing object names + that are emitted within SQL comments in its output script. A name + containing a newline would at least render the script syntactically + incorrect. Maliciously crafted object names could present a SQL + injection risk when the script is reloaded. (CVE-2012-0868) +

  • Fix btree index corruption from insertions concurrent with vacuuming + (Tom Lane) +

    An index page split caused by an insertion could sometimes cause a + concurrently-running VACUUM to miss removing index entries + that it should remove. After the corresponding table rows are removed, + the dangling index entries would cause errors (such as "could not + read block N in file ...") or worse, silently wrong query results + after unrelated rows are re-inserted at the now-free table locations. + This bug has been present since release 8.2, but occurs so infrequently + that it was not diagnosed until now. If you have reason to suspect + that it has happened in your database, reindexing the affected index + will fix things. +

  • Update per-column permissions, not only per-table permissions, when + changing table owner (Tom Lane) +

    Failure to do this meant that any previously granted column permissions + were still shown as having been granted by the old owner. This meant + that neither the new owner nor a superuser could revoke the + now-untraceable-to-table-owner permissions. +

  • Allow non-existent values for some settings in ALTER + USER/DATABASE SET (Heikki Linnakangas) +

    Allow default_text_search_config, + default_tablespace, and temp_tablespaces to be + set to names that are not known. This is because they might be known + in another database where the setting is intended to be used, or for the + tablespace cases because the tablespace might not be created yet. The + same issue was previously recognized for search_path, and + these settings now act like that one. +

  • Avoid crashing when we have problems deleting table files post-commit + (Tom Lane) +

    Dropping a table should lead to deleting the underlying disk files only + after the transaction commits. In event of failure then (for instance, + because of wrong file permissions) the code is supposed to just emit a + warning message and go on, since it's too late to abort the + transaction. This logic got broken as of release 8.4, causing such + situations to result in a PANIC and an unrestartable database. +

  • Track the OID counter correctly during WAL replay, even when it wraps + around (Tom Lane) +

    Previously the OID counter would remain stuck at a high value until the + system exited replay mode. The practical consequences of that are + usually nil, but there are scenarios wherein a standby server that's + been promoted to master might take a long time to advance the OID + counter to a reasonable value once values are needed. +

  • Fix regular expression back-references with * attached + (Tom Lane) +

    Rather than enforcing an exact string match, the code would effectively + accept any string that satisfies the pattern sub-expression referenced + by the back-reference symbol. +

    A similar problem still afflicts back-references that are embedded in a + larger quantified expression, rather than being the immediate subject + of the quantifier. This will be addressed in a future + PostgreSQL release. +

  • Fix recently-introduced memory leak in processing of + inet/cidr values (Heikki Linnakangas) +

    A patch in the December 2011 releases of PostgreSQL + caused memory leakage in these operations, which could be significant + in scenarios such as building a btree index on such a column. +

  • Fix dangling pointer after CREATE TABLE AS/SELECT + INTO in a SQL-language function (Tom Lane) +

    In most cases this only led to an assertion failure in assert-enabled + builds, but worse consequences seem possible. +

  • Avoid double close of file handle in syslogger on Windows (MauMau) +

    Ordinarily this error was invisible, but it would cause an exception + when running on a debug version of Windows. +

  • Fix I/O-conversion-related memory leaks in plpgsql + (Andres Freund, Jan Urbanski, Tom Lane) +

    Certain operations would leak memory until the end of the current + function. +

  • Improve pg_dump's handling of inherited table columns + (Tom Lane) +

    pg_dump mishandled situations where a child column has + a different default expression than its parent column. If the default + is textually identical to the parent's default, but not actually the + same (for instance, because of schema search path differences) it would + not be recognized as different, so that after dump and restore the + child would be allowed to inherit the parent's default. Child columns + that are NOT NULL where their parent is not could also be + restored subtly incorrectly. +

  • Fix pg_restore's direct-to-database mode for + INSERT-style table data (Tom Lane) +

    Direct-to-database restores from archive files made with + --inserts or --column-inserts options fail when + using pg_restore from a release dated September or + December 2011, as a result of an oversight in a fix for another + problem. The archive file itself is not at fault, and text-mode + output is okay. +

  • Allow AT option in ecpg + DEALLOCATE statements (Michael Meskes) +

    The infrastructure to support this has been there for awhile, but + through an oversight there was still an error check rejecting the case. +

  • Fix error in contrib/intarray's int[] & + int[] operator (Guillaume Lelarge) +

    If the smallest integer the two input arrays have in common is 1, + and there are smaller values in either array, then 1 would be + incorrectly omitted from the result. +

  • Fix error detection in contrib/pgcrypto's + encrypt_iv() and decrypt_iv() + (Marko Kreen) +

    These functions failed to report certain types of invalid-input errors, + and would instead return random garbage values for incorrect input. +

  • Fix one-byte buffer overrun in contrib/test_parser + (Paul Guyot) +

    The code would try to read one more byte than it should, which would + crash in corner cases. + Since contrib/test_parser is only example code, this is + not a security issue in itself, but bad example code is still bad. +

  • Use __sync_lock_test_and_set() for spinlocks on ARM, if + available (Martin Pitt) +

    This function replaces our previous use of the SWPB + instruction, which is deprecated and not available on ARMv6 and later. + Reports suggest that the old code doesn't fail in an obvious way on + recent ARM boards, but simply doesn't interlock concurrent accesses, + leading to bizarre failures in multiprocess operation. +

  • Use -fexcess-precision=standard option when building with + gcc versions that accept it (Andrew Dunstan) +

    This prevents assorted scenarios wherein recent versions of gcc will + produce creative results. +

  • Allow use of threaded Python on FreeBSD (Chris Rees) +

    Our configure script previously believed that this combination wouldn't + work; but FreeBSD fixed the problem, so remove that error check. +


PrevHomeNext
Release 8.4.12UpRelease 8.4.10
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-4-12.html b/doc/src/sgml/html/release-8-4-12.html new file mode 100644 index 000000000..254fc376f --- /dev/null +++ b/doc/src/sgml/html/release-8-4-12.html @@ -0,0 +1,514 @@ + +Release 8.4.12

E.27. Release 8.4.12

Release Date: 2012-06-04

This release contains a variety of fixes from 8.4.11. + For information about new features in the 8.4 major release, see + Section E.39. +

E.27.1. Migration to Version 8.4.12

A dump/restore is not required for those running 8.4.X. +

However, if you are upgrading from a version earlier than 8.4.10, + see the release notes for 8.4.10. +

E.27.2. Changes

  • Fix incorrect password transformation in + contrib/pgcrypto's DES crypt() function + (Solar Designer) +

    If a password string contained the byte value 0x80, the + remainder of the password was ignored, causing the password to be much + weaker than it appeared. With this fix, the rest of the string is + properly included in the DES hash. Any stored password values that are + affected by this bug will thus no longer match, so the stored values may + need to be updated. (CVE-2012-2143) +

  • Ignore SECURITY DEFINER and SET attributes for + a procedural language's call handler (Tom Lane) +

    Applying such attributes to a call handler could crash the server. + (CVE-2012-2655) +

  • Allow numeric timezone offsets in timestamp input to be up to + 16 hours away from UTC (Tom Lane) +

    Some historical time zones have offsets larger than 15 hours, the + previous limit. This could result in dumped data values being rejected + during reload. +

  • Fix timestamp conversion to cope when the given time is exactly the + last DST transition time for the current timezone (Tom Lane) +

    This oversight has been there a long time, but was not noticed + previously because most DST-using zones are presumed to have an + indefinite sequence of future DST transitions. +

  • Fix text to name and char to name + casts to perform string truncation correctly in multibyte encodings + (Karl Schnaitter) +

  • Fix memory copying bug in to_tsquery() (Heikki Linnakangas) +

  • Fix planner's handling of outer PlaceHolderVars within subqueries (Tom + Lane) +

    This bug concerns sub-SELECTs that reference variables coming from the + nullable side of an outer join of the surrounding query. + In 9.1, queries affected by this bug would fail with "ERROR: + Upper-level PlaceHolderVar found where not expected". But in 9.0 and + 8.4, you'd silently get possibly-wrong answers, since the value + transmitted into the subquery wouldn't go to null when it should. +

  • Fix slow session startup when pg_attribute is very large + (Tom Lane) +

    If pg_attribute exceeds one-fourth of + shared_buffers, cache rebuilding code that is sometimes + needed during session start would trigger the synchronized-scan logic, + causing it to take many times longer than normal. The problem was + particularly acute if many new sessions were starting at once. +

  • Ensure sequential scans check for query cancel reasonably often (Merlin + Moncure) +

    A scan encountering many consecutive pages that contain no live tuples + would not respond to interrupts meanwhile. +

  • Ensure the Windows implementation of PGSemaphoreLock() + clears ImmediateInterruptOK before returning (Tom Lane) +

    This oversight meant that a query-cancel interrupt received later + in the same query could be accepted at an unsafe time, with + unpredictable but not good consequences. +

  • Show whole-row variables safely when printing views or rules + (Abbas Butt, Tom Lane) +

    Corner cases involving ambiguous names (that is, the name could be + either a table or column name of the query) were printed in an + ambiguous way, risking that the view or rule would be interpreted + differently after dump and reload. Avoid the ambiguous case by + attaching a no-op cast. +

  • Fix COPY FROM to properly handle null marker strings that + correspond to invalid encoding (Tom Lane) +

    A null marker string such as E'\\0' should work, and did + work in the past, but the case got broken in 8.4. +

  • Ensure autovacuum worker processes perform stack depth checking + properly (Heikki Linnakangas) +

    Previously, infinite recursion in a function invoked by + auto-ANALYZE could crash worker processes. +

  • Fix logging collector to not lose log coherency under high load (Andrew + Dunstan) +

    The collector previously could fail to reassemble large messages if it + got too busy. +

  • Fix logging collector to ensure it will restart file rotation + after receiving SIGHUP (Tom Lane) +

  • Fix WAL replay logic for GIN indexes to not fail if the index was + subsequently dropped (Tom Lane) +

  • Fix memory leak in PL/pgSQL's RETURN NEXT command (Joe + Conway) +

  • Fix PL/pgSQL's GET DIAGNOSTICS command when the target + is the function's first variable (Tom Lane) +

  • Fix potential access off the end of memory in psql's + expanded display (\x) mode (Peter Eisentraut) +

  • Fix several performance problems in pg_dump when + the database contains many objects (Jeff Janes, Tom Lane) +

    pg_dump could get very slow if the database contained + many schemas, or if many objects are in dependency loops, or if there + are many owned sequences. +

  • Fix contrib/dblink's dblink_exec() to not leak + temporary database connections upon error (Tom Lane) +

  • Fix contrib/dblink to report the correct connection name in + error messages (Kyotaro Horiguchi) +

  • Update time zone data files to tzdata release 2012c + for DST law changes in Antarctica, Armenia, Chile, Cuba, Falkland + Islands, Gaza, Haiti, Hebron, Morocco, Syria, and Tokelau Islands; + also historical corrections for Canada. +


PrevHomeNext
Release 8.4.13UpRelease 8.4.11
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-4-13.html b/doc/src/sgml/html/release-8-4-13.html new file mode 100644 index 000000000..3189b2efc --- /dev/null +++ b/doc/src/sgml/html/release-8-4-13.html @@ -0,0 +1,522 @@ + +Release 8.4.13

E.26. Release 8.4.13

Release Date: 2012-08-17

This release contains a variety of fixes from 8.4.12. + For information about new features in the 8.4 major release, see + Section E.39. +

E.26.1. Migration to Version 8.4.13

A dump/restore is not required for those running 8.4.X. +

However, if you are upgrading from a version earlier than 8.4.10, + see the release notes for 8.4.10. +

E.26.2. Changes

  • Prevent access to external files/URLs via XML entity references + (Noah Misch, Tom Lane) +

    xml_parse() would attempt to fetch external files or + URLs as needed to resolve DTD and entity references in an XML value, + thus allowing unprivileged database users to attempt to fetch data + with the privileges of the database server. While the external data + wouldn't get returned directly to the user, portions of it could be + exposed in error messages if the data didn't parse as valid XML; and + in any case the mere ability to check existence of a file might be + useful to an attacker. (CVE-2012-3489) +

  • Prevent access to external files/URLs via contrib/xml2's + xslt_process() (Peter Eisentraut) +

    libxslt offers the ability to read and write both + files and URLs through stylesheet commands, thus allowing + unprivileged database users to both read and write data with the + privileges of the database server. Disable that through proper use + of libxslt's security options. (CVE-2012-3488) +

    Also, remove xslt_process()'s ability to fetch documents + and stylesheets from external files/URLs. While this was a + documented "feature", it was long regarded as a bad idea. + The fix for CVE-2012-3489 broke that capability, and rather than + expend effort on trying to fix it, we're just going to summarily + remove it. +

  • Prevent too-early recycling of btree index pages (Noah Misch) +

    When we allowed read-only transactions to skip assigning XIDs, we + introduced the possibility that a deleted btree page could be + recycled while a read-only transaction was still in flight to it. + This would result in incorrect index search results. The probability + of such an error occurring in the field seems very low because of the + timing requirements, but nonetheless it should be fixed. +

  • Fix crash-safety bug with newly-created-or-reset sequences (Tom Lane) +

    If ALTER SEQUENCE was executed on a freshly created or + reset sequence, and then precisely one nextval() call + was made on it, and then the server crashed, WAL replay would restore + the sequence to a state in which it appeared that no + nextval() had been done, thus allowing the first + sequence value to be returned again by the next + nextval() call. In particular this could manifest for + serial columns, since creation of a serial column's sequence + includes an ALTER SEQUENCE OWNED BY step. +

  • Ensure the backup_label file is fsync'd after + pg_start_backup() (Dave Kerr) +

  • Back-patch 9.1 improvement to compress the fsync request queue + (Robert Haas) +

    This improves performance during checkpoints. The 9.1 change + has now seen enough field testing to seem safe to back-patch. +

  • Only allow autovacuum to be auto-canceled by a directly blocked + process (Tom Lane) +

    The original coding could allow inconsistent behavior in some cases; + in particular, an autovacuum could get canceled after less than + deadlock_timeout grace period. +

  • Improve logging of autovacuum cancels (Robert Haas) +

  • Fix log collector so that log_truncate_on_rotation works + during the very first log rotation after server start (Tom Lane) +

  • Fix WITH attached to a nested set operation + (UNION/INTERSECT/EXCEPT) + (Tom Lane) +

  • Ensure that a whole-row reference to a subquery doesn't include any + extra GROUP BY or ORDER BY columns (Tom Lane) +

  • Disallow copying whole-row references in CHECK + constraints and index definitions during CREATE TABLE + (Tom Lane) +

    This situation can arise in CREATE TABLE with + LIKE or INHERITS. The copied whole-row + variable was incorrectly labeled with the row type of the original + table not the new one. Rejecting the case seems reasonable for + LIKE, since the row types might well diverge later. For + INHERITS we should ideally allow it, with an implicit + coercion to the parent table's row type; but that will require more + work than seems safe to back-patch. +

  • Fix memory leak in ARRAY(SELECT ...) subqueries (Heikki + Linnakangas, Tom Lane) +

  • Fix extraction of common prefixes from regular expressions (Tom Lane) +

    The code could get confused by quantified parenthesized + subexpressions, such as ^(foo)?bar. This would lead to + incorrect index optimization of searches for such patterns. +

  • Fix bugs with parsing signed + hh:mm and + hh:mm:ss + fields in interval constants (Amit Kapila, Tom Lane) +

  • Report errors properly in contrib/xml2's + xslt_process() (Tom Lane) +

  • Update time zone data files to tzdata release 2012e + for DST law changes in Morocco and Tokelau +


PrevHomeNext
Release 8.4.14UpRelease 8.4.12
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-4-14.html b/doc/src/sgml/html/release-8-4-14.html new file mode 100644 index 000000000..f59269893 --- /dev/null +++ b/doc/src/sgml/html/release-8-4-14.html @@ -0,0 +1,314 @@ + +Release 8.4.14

E.25. Release 8.4.14

Release Date: 2012-09-24

This release contains a variety of fixes from 8.4.13. + For information about new features in the 8.4 major release, see + Section E.39. +

E.25.1. Migration to Version 8.4.14

A dump/restore is not required for those running 8.4.X. +

However, if you are upgrading from a version earlier than 8.4.10, + see the release notes for 8.4.10. +

E.25.2. Changes

  • Fix planner's assignment of executor parameters, and fix executor's + rescan logic for CTE plan nodes (Tom Lane) +

    These errors could result in wrong answers from queries that scan the + same WITH subquery multiple times. +

  • Improve page-splitting decisions in GiST indexes (Alexander Korotkov, + Robert Haas, Tom Lane) +

    Multi-column GiST indexes might suffer unexpected bloat due to this + error. +

  • Fix cascading privilege revoke to stop if privileges are still held + (Tom Lane) +

    If we revoke a grant option from some role X, but + X still holds that option via a grant from someone + else, we should not recursively revoke the corresponding privilege + from role(s) Y that X had granted it + to. +

  • Fix handling of SIGFPE when PL/Perl is in use (Andres Freund) +

    Perl resets the process's SIGFPE handler to + SIG_IGN, which could result in crashes later on. Restore + the normal Postgres signal handler after initializing PL/Perl. +

  • Prevent PL/Perl from crashing if a recursive PL/Perl function is + redefined while being executed (Tom Lane) +

  • Work around possible misoptimization in PL/Perl (Tom Lane) +

    Some Linux distributions contain an incorrect version of + pthread.h that results in incorrect compiled code in + PL/Perl, leading to crashes if a PL/Perl function calls another one + that throws an error. +

  • Update time zone data files to tzdata release 2012f + for DST law changes in Fiji +


PrevHomeNext
Release 8.4.15UpRelease 8.4.13
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-4-15.html b/doc/src/sgml/html/release-8-4-15.html new file mode 100644 index 000000000..4a52e4e09 --- /dev/null +++ b/doc/src/sgml/html/release-8-4-15.html @@ -0,0 +1,573 @@ + +Release 8.4.15

E.24. Release 8.4.15

Release Date: 2012-12-06

This release contains a variety of fixes from 8.4.14. + For information about new features in the 8.4 major release, see + Section E.39. +

E.24.1. Migration to Version 8.4.15

A dump/restore is not required for those running 8.4.X. +

However, if you are upgrading from a version earlier than 8.4.10, + see the release notes for 8.4.10. +

E.24.2. Changes

  • Fix multiple bugs associated with CREATE INDEX + CONCURRENTLY (Andres Freund, Tom Lane) +

    Fix CREATE INDEX CONCURRENTLY to use + in-place updates when changing the state of an index's + pg_index row. This prevents race conditions that could + cause concurrent sessions to miss updating the target index, thus + resulting in corrupt concurrently-created indexes. +

    Also, fix various other operations to ensure that they ignore + invalid indexes resulting from a failed CREATE INDEX + CONCURRENTLY command. The most important of these is + VACUUM, because an auto-vacuum could easily be launched + on the table before corrective action can be taken to fix or remove + the invalid index. +

  • Avoid corruption of internal hash tables when out of memory + (Hitoshi Harada) +

  • Fix planning of non-strict equivalence clauses above outer joins + (Tom Lane) +

    The planner could derive incorrect constraints from a clause equating + a non-strict construct to something else, for example + WHERE COALESCE(foo, 0) = 0 + when foo is coming from the nullable side of an outer join. +

  • Improve planner's ability to prove exclusion constraints from + equivalence classes (Tom Lane) +

  • Fix partial-row matching in hashed subplans to handle cross-type cases + correctly (Tom Lane) +

    This affects multicolumn NOT IN subplans, such as + WHERE (a, b) NOT IN (SELECT x, y FROM ...) + when for instance b and y are int4 + and int8 respectively. This mistake led to wrong answers + or crashes depending on the specific datatypes involved. +

  • Acquire buffer lock when re-fetching the old tuple for an + AFTER ROW UPDATE/DELETE trigger (Andres Freund) +

    In very unusual circumstances, this oversight could result in passing + incorrect data to the precheck logic for a foreign-key enforcement + trigger. That could result in a crash, or in an incorrect decision + about whether to fire the trigger. +

  • Fix ALTER COLUMN TYPE to handle inherited check + constraints properly (Pavan Deolasee) +

    This worked correctly in pre-8.4 releases, and now works correctly + in 8.4 and later. +

  • Fix REASSIGN OWNED to handle grants on tablespaces + (Álvaro Herrera) +

  • Ignore incorrect pg_attribute entries for system + columns for views (Tom Lane) +

    Views do not have any system columns. However, we forgot to + remove such entries when converting a table to a view. That's fixed + properly for 9.3 and later, but in previous branches we need to defend + against existing mis-converted views. +

  • Fix rule printing to dump INSERT INTO table + DEFAULT VALUES correctly (Tom Lane) +

  • Guard against stack overflow when there are too many + UNION/INTERSECT/EXCEPT clauses + in a query (Tom Lane) +

  • Prevent platform-dependent failures when dividing the minimum possible + integer value by -1 (Xi Wang, Tom Lane) +

  • Fix possible access past end of string in date parsing + (Hitoshi Harada) +

  • Produce an understandable error message if the length of the path name + for a Unix-domain socket exceeds the platform-specific limit + (Tom Lane, Andrew Dunstan) +

    Formerly, this would result in something quite unhelpful, such as + "Non-recoverable failure in name resolution". +

  • Fix memory leaks when sending composite column values to the client + (Tom Lane) +

  • Make pg_ctl more robust about reading the + postmaster.pid file (Heikki Linnakangas) +

    Fix race conditions and possible file descriptor leakage. +

  • Fix possible crash in psql if incorrectly-encoded data + is presented and the client_encoding setting is a + client-only encoding, such as SJIS (Jiang Guiqing) +

  • Fix bugs in the restore.sql script emitted by + pg_dump in tar output format (Tom Lane) +

    The script would fail outright on tables whose names include + upper-case characters. Also, make the script capable of restoring + data in --inserts mode as well as the regular COPY mode. +

  • Fix pg_restore to accept POSIX-conformant + tar files (Brian Weaver, Tom Lane) +

    The original coding of pg_dump's tar + output mode produced files that are not fully conformant with the + POSIX standard. This has been corrected for version 9.3. This + patch updates previous branches so that they will accept both the + incorrect and the corrected formats, in hopes of avoiding + compatibility problems when 9.3 comes out. +

  • Fix pg_resetxlog to locate postmaster.pid + correctly when given a relative path to the data directory (Tom Lane) +

    This mistake could lead to pg_resetxlog not noticing + that there is an active postmaster using the data directory. +

  • Fix libpq's lo_import() and + lo_export() functions to report file I/O errors properly + (Tom Lane) +

  • Fix ecpg's processing of nested structure pointer + variables (Muhammad Usama) +

  • Make contrib/pageinspect's btree page inspection + functions take buffer locks while examining pages (Tom Lane) +

  • Fix pgxs support for building loadable modules on AIX + (Tom Lane) +

    Building modules outside the original source tree didn't work on AIX. +

  • Update time zone data files to tzdata release 2012j + for DST law changes in Cuba, Israel, Jordan, Libya, Palestine, Western + Samoa, and portions of Brazil. +


PrevHomeNext
Release 9.0UpRelease 8.4.14
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-4-2.html b/doc/src/sgml/html/release-8-4-2.html new file mode 100644 index 000000000..210d4f257 --- /dev/null +++ b/doc/src/sgml/html/release-8-4-2.html @@ -0,0 +1,846 @@ + +Release 8.4.2

E.37. Release 8.4.2

Release Date: 2009-12-14

This release contains a variety of fixes from 8.4.1. + For information about new features in the 8.4 major release, see + Section E.39. +

E.37.1. Migration to Version 8.4.2

A dump/restore is not required for those running 8.4.X. + However, if you have any hash indexes, + you should REINDEX them after updating to 8.4.2, + to repair possible damage. +

E.37.2. Changes

  • Protect against indirect security threats caused by index functions + changing session-local state (Gurjeet Singh, Tom) +

    This change prevents allegedly-immutable index functions from possibly + subverting a superuser's session (CVE-2009-4136). +

  • Reject SSL certificates containing an embedded null byte in the common + name (CN) field (Magnus) +

    This prevents unintended matching of a certificate to a server or client + name during SSL validation (CVE-2009-4034). +

  • Fix hash index corruption (Tom) +

    The 8.4 change that made hash indexes keep entries sorted by hash value + failed to update the bucket splitting and compaction routines to + preserve the ordering. So application of either of those operations + could lead to permanent corruption of an index, in the sense that + searches might fail to find entries that are present. To deal with + this, it is recommended to REINDEX any hash indexes you may + have after installing this update. +

  • Fix possible crash during backend-startup-time cache initialization (Tom) +

  • Avoid crash on empty thesaurus dictionary (Tom) +

  • Prevent signals from interrupting VACUUM at unsafe times + (Alvaro) +

    This fix prevents a PANIC if a VACUUM FULL is canceled + after it's already committed its tuple movements, as well as transient + errors if a plain VACUUM is interrupted after having + truncated the table. +

  • Fix possible crash due to integer overflow in hash table size + calculation (Tom) +

    This could occur with extremely large planner estimates for the size of + a hashjoin's result. +

  • Fix crash if a DROP is attempted on an internally-dependent + object (Tom) +

  • Fix very rare crash in inet/cidr comparisons (Chris + Mikkelson) +

  • Ensure that shared tuple-level locks held by prepared transactions are + not ignored (Heikki) +

  • Fix premature drop of temporary files used for a cursor that is accessed + within a subtransaction (Heikki) +

  • Fix memory leak in syslogger process when rotating to a new CSV logfile + (Tom) +

  • Fix memory leak in postmaster when re-parsing pg_hba.conf + (Tom) +

  • Fix Windows permission-downgrade logic (Jesse Morris) +

    This fixes some cases where the database failed to start on Windows, + often with misleading error messages such as "could not locate + matching postgres executable". +

  • Make FOR UPDATE/SHARE in the primary query not propagate + into WITH queries (Tom) +

    For example, in +

    WITH w AS (SELECT * FROM foo) SELECT * FROM w, bar ... FOR UPDATE

    + the FOR UPDATE will now affect bar but not + foo. This is more useful and consistent than the original + 8.4 behavior, which tried to propagate FOR UPDATE into the + WITH query but always failed due to assorted implementation + restrictions. It also follows the design rule that WITH + queries are executed as if independent of the main query. +

  • Fix bug with a WITH RECURSIVE query immediately inside + another one (Tom) +

  • Fix concurrency bug in hash indexes (Tom) +

    Concurrent insertions could cause index scans to transiently report + wrong results. +

  • Fix incorrect logic for GiST index page splits, when the split depends + on a non-first column of the index (Paul Ramsey) +

  • Fix wrong search results for a multi-column GIN index with + fastupdate enabled (Teodor) +

  • Fix bugs in WAL entry creation for GIN indexes (Tom) +

    These bugs were masked when full_page_writes was on, but + with it off a WAL replay failure was certain if a crash occurred before + the next checkpoint. +

  • Don't error out if recycling or removing an old WAL file fails at the + end of checkpoint (Heikki) +

    It's better to treat the problem as non-fatal and allow the checkpoint + to complete. Future checkpoints will retry the removal. Such problems + are not expected in normal operation, but have been seen to be + caused by misdesigned Windows anti-virus and backup software. +

  • Ensure WAL files aren't repeatedly archived on Windows (Heikki) +

    This is another symptom that could happen if some other process + interfered with deletion of a no-longer-needed file. +

  • Fix PAM password processing to be more robust (Tom) +

    The previous code is known to fail with the combination of the Linux + pam_krb5 PAM module with Microsoft Active Directory as the + domain controller. It might have problems elsewhere too, since it was + making unjustified assumptions about what arguments the PAM stack would + pass to it. +

  • Raise the maximum authentication token (Kerberos ticket) size in GSSAPI + and SSPI authentication methods (Ian Turner) +

    While the old 2000-byte limit was more than enough for Unix Kerberos + implementations, tickets issued by Windows Domain Controllers can be + much larger. +

  • Ensure that domain constraints are enforced in constructs like + ARRAY[...]::domain, where the domain is over an array type + (Heikki) +

  • Fix foreign-key logic for some cases involving composite-type columns + as foreign keys (Tom) +

  • Ensure that a cursor's snapshot is not modified after it is created + (Alvaro) +

    This could lead to a cursor delivering wrong results if later operations + in the same transaction modify the data the cursor is supposed to return. +

  • Fix CREATE TABLE to properly merge default expressions + coming from different inheritance parent tables (Tom) +

    This used to work but was broken in 8.4. +

  • Re-enable collection of access statistics for sequences (Akira Kurosawa) +

    This used to work but was broken in 8.3. +

  • Fix processing of ownership dependencies during CREATE OR + REPLACE FUNCTION (Tom) +

  • Fix incorrect handling of WHERE + x=x conditions (Tom) +

    In some cases these could get ignored as redundant, but they aren't + — they're equivalent to x IS NOT NULL. +

  • Fix incorrect plan construction when using hash aggregation to implement + DISTINCT for textually identical volatile expressions (Tom) +

  • Fix Assert failure for a volatile SELECT DISTINCT ON + expression (Tom) +

  • Fix ts_stat() to not fail on an empty tsvector + value (Tom) +

  • Make text search parser accept underscores in XML attributes (Peter) +

  • Fix encoding handling in xml binary input (Heikki) +

    If the XML header doesn't specify an encoding, we now assume UTF-8 by + default; the previous handling was inconsistent. +

  • Fix bug with calling plperl from plperlu or vice + versa (Tom) +

    An error exit from the inner function could result in crashes due to + failure to re-select the correct Perl interpreter for the outer function. +

  • Fix session-lifespan memory leak when a PL/Perl function is redefined + (Tom) +

  • Ensure that Perl arrays are properly converted to + PostgreSQL arrays when returned by a set-returning + PL/Perl function (Andrew Dunstan, Abhijit Menon-Sen) +

    This worked correctly already for non-set-returning functions. +

  • Fix rare crash in exception processing in PL/Python (Peter) +

  • Fix ecpg problem with comments in DECLARE + CURSOR statements (Michael) +

  • Fix ecpg to not treat recently-added keywords as + reserved words (Tom) +

    This affected the keywords CALLED, CATALOG, + DEFINER, ENUM, FOLLOWING, + INVOKER, OPTIONS, PARTITION, + PRECEDING, RANGE, SECURITY, + SERVER, UNBOUNDED, and WRAPPER. +

  • Re-allow regular expression special characters in psql's + \df function name parameter (Tom) +

  • In contrib/fuzzystrmatch, correct the calculation of + levenshtein distances with non-default costs (Marcin Mank) +

  • In contrib/pg_standby, disable triggering failover with a + signal on Windows (Fujii Masao) +

    This never did anything useful, because Windows doesn't have Unix-style + signals, but recent changes made it actually crash. +

  • Put FREEZE and VERBOSE options in the right + order in the VACUUM command that + contrib/vacuumdb produces (Heikki) +

  • Fix possible leak of connections when contrib/dblink + encounters an error (Tatsuhito Kasahara) +

  • Ensure psql's flex module is compiled with the correct + system header definitions (Tom) +

    This fixes build failures on platforms where + --enable-largefile causes incompatible changes in the + generated code. +

  • Make the postmaster ignore any application_name parameter in + connection request packets, to improve compatibility with future libpq + versions (Tom) +

  • Update the timezone abbreviation files to match current reality (Joachim + Wieland) +

    This includes adding IDT to the default + timezone abbreviation set. +

  • Update time zone data files to tzdata release 2009s + for DST law changes in Antarctica, Argentina, Bangladesh, Fiji, + Novokuznetsk, Pakistan, Palestine, Samoa, Syria; also historical + corrections for Hong Kong. +


PrevHomeNext
Release 8.4.3UpRelease 8.4.1
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-4-3.html b/doc/src/sgml/html/release-8-4-3.html new file mode 100644 index 000000000..4f81dab29 --- /dev/null +++ b/doc/src/sgml/html/release-8-4-3.html @@ -0,0 +1,738 @@ + +Release 8.4.3

E.36. Release 8.4.3

Release Date: 2010-03-15

This release contains a variety of fixes from 8.4.2. + For information about new features in the 8.4 major release, see + Section E.39. +

E.36.1. Migration to Version 8.4.3

A dump/restore is not required for those running 8.4.X. + However, if you are upgrading from a version earlier than 8.4.2, + see the release notes for 8.4.2. +

E.36.2. Changes

  • Add new configuration parameter ssl_renegotiation_limit to + control how often we do session key renegotiation for an SSL connection + (Magnus) +

    This can be set to zero to disable renegotiation completely, which may + be required if a broken SSL library is used. In particular, some + vendors are shipping stopgap patches for CVE-2009-3555 that cause + renegotiation attempts to fail. +

  • Fix possible deadlock during backend startup (Tom) +

  • Fix possible crashes due to not handling errors during relcache reload + cleanly (Tom) +

  • Fix possible crash due to use of dangling pointer to a cached plan + (Tatsuo) +

  • Fix possible crash due to overenthusiastic invalidation of cached + plan for ROLLBACK (Tom) +

  • Fix possible crashes when trying to recover from a failure in + subtransaction start (Tom) +

  • Fix server memory leak associated with use of savepoints and a client + encoding different from server's encoding (Tom) +

  • Fix incorrect WAL data emitted during end-of-recovery cleanup of a GIST + index page split (Yoichi Hirai) +

    This would result in index corruption, or even more likely an error + during WAL replay, if we were unlucky enough to crash during + end-of-recovery cleanup after having completed an incomplete GIST + insertion. +

  • Fix bug in WAL redo cleanup method for GIN indexes (Heikki) +

  • Fix incorrect comparison of scan key in GIN index search (Teodor) +

  • Make substring() for bit types treat any negative + length as meaning "all the rest of the string" (Tom) +

    The previous coding treated only -1 that way, and would produce an + invalid result value for other negative values, possibly leading to + a crash (CVE-2010-0442). +

  • Fix integer-to-bit-string conversions to handle the first fractional + byte correctly when the output bit width is wider than the given + integer by something other than a multiple of 8 bits (Tom) +

  • Fix some cases of pathologically slow regular expression matching (Tom) +

  • Fix bug occurring when trying to inline a SQL function that returns + a set of a composite type that contains dropped columns (Tom) +

  • Fix bug with trying to update a field of an element of a + composite-type array column (Tom) +

  • Avoid failure when EXPLAIN has to print a FieldStore or + assignment ArrayRef expression (Tom) +

    These cases can arise now that EXPLAIN VERBOSE tries to + print plan node target lists. +

  • Avoid an unnecessary coercion failure in some cases where an undecorated + literal string appears in a subquery within + UNION/INTERSECT/EXCEPT (Tom) +

    This fixes a regression for some cases that worked before 8.4. +

  • Avoid undesirable rowtype compatibility check failures in some cases + where a whole-row Var has a rowtype that contains dropped columns (Tom) +

  • Fix the STOP WAL LOCATION entry in backup history files to + report the next WAL segment's name when the end location is exactly at a + segment boundary (Itagaki Takahiro) +

  • Always pass the catalog ID to an option validator function specified in + CREATE FOREIGN DATA WRAPPER (Martin Pihlak) +

  • Fix some more cases of temporary-file leakage (Heikki) +

    This corrects a problem introduced in the previous minor release. + One case that failed is when a plpgsql function returning set is + called within another function's exception handler. +

  • Add support for doing FULL JOIN ON FALSE (Tom) +

    This prevents a regression from pre-8.4 releases for some queries that + can now be simplified to a constant-false join condition. +

  • Improve constraint exclusion processing of boolean-variable cases, + in particular make it possible to exclude a partition that has a + "bool_column = false" constraint (Tom) +

  • Prevent treating an INOUT cast as representing binary + compatibility (Heikki) +

  • Include column name in the message when warning about inability to + grant or revoke column-level privileges (Stephen Frost) +

    This is more useful than before and helps to prevent confusion when + a REVOKE generates multiple messages, which formerly + appeared to be duplicates. +

  • When reading pg_hba.conf and related files, do not treat + @something as a file inclusion request if the @ + appears inside quote marks; also, never treat @ by itself + as a file inclusion request (Tom) +

    This prevents erratic behavior if a role or database name starts with + @. If you need to include a file whose path name + contains spaces, you can still do so, but you must write + @"/path to/file" rather than putting the quotes around + the whole construct. +

  • Prevent infinite loop on some platforms if a directory is named as + an inclusion target in pg_hba.conf and related files + (Tom) +

  • Fix possible infinite loop if SSL_read or + SSL_write fails without setting errno (Tom) +

    This is reportedly possible with some Windows versions of + openssl. +

  • Disallow GSSAPI authentication on local connections, + since it requires a hostname to function correctly (Magnus) +

  • Protect ecpg against applications freeing strings + unexpectedly (Michael) +

  • Make ecpg report the proper SQLSTATE if the connection + disappears (Michael) +

  • Fix translation of cell contents in psql \d + output (Heikki) +

  • Fix psql's numericlocale option to not + format strings it shouldn't in latex and troff output formats (Heikki) +

  • Fix a small per-query memory leak in psql (Tom) +

  • Make psql return the correct exit status (3) when + ON_ERROR_STOP and --single-transaction are + both specified and an error occurs during the implied COMMIT + (Bruce) +

  • Fix pg_dump's output of permissions for foreign servers + (Heikki) +

  • Fix possible crash in parallel pg_restore due to + out-of-range dependency IDs (Tom) +

  • Fix plpgsql failure in one case where a composite column is set to NULL + (Tom) +

  • Fix possible failure when calling PL/Perl functions from PL/PerlU + or vice versa (Tim Bunce) +

  • Add volatile markings in PL/Python to avoid possible + compiler-specific misbehavior (Zdenek Kotala) +

  • Ensure PL/Tcl initializes the Tcl interpreter fully (Tom) +

    The only known symptom of this oversight is that the Tcl + clock command misbehaves if using Tcl 8.5 or later. +

  • Prevent ExecutorEnd from being run on portals created + within a failed transaction or subtransaction (Tom) +

    This is known to cause issues when using + contrib/auto_explain. +

  • Prevent crash in contrib/dblink when too many key + columns are specified to a dblink_build_sql_* function + (Rushabh Lathia, Joe Conway) +

  • Allow zero-dimensional arrays in contrib/ltree operations + (Tom) +

    This case was formerly rejected as an error, but it's more convenient to + treat it the same as a zero-element array. In particular this avoids + unnecessary failures when an ltree operation is applied to the + result of ARRAY(SELECT ...) and the sub-select returns no + rows. +

  • Fix assorted crashes in contrib/xml2 caused by sloppy + memory management (Tom) +

  • Make building of contrib/xml2 more robust on Windows + (Andrew) +

  • Fix race condition in Windows signal handling (Radu Ilie) +

    One known symptom of this bug is that rows in pg_listener + could be dropped under heavy load. +

  • Make the configure script report failure if the C compiler does + not provide a working 64-bit integer datatype (Tom) +

    This case has been broken for some time, and no longer seems worth + supporting, so just reject it at configure time instead. +

  • Update time zone data files to tzdata release 2010e + for DST law changes in Bangladesh, Chile, Fiji, Mexico, Paraguay, Samoa. +


PrevHomeNext
Release 8.4.4UpRelease 8.4.2
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-4-4.html b/doc/src/sgml/html/release-8-4-4.html new file mode 100644 index 000000000..27f13eb03 --- /dev/null +++ b/doc/src/sgml/html/release-8-4-4.html @@ -0,0 +1,563 @@ + +Release 8.4.4

E.35. Release 8.4.4

Release Date: 2010-05-17

This release contains a variety of fixes from 8.4.3. + For information about new features in the 8.4 major release, see + Section E.39. +

E.35.1. Migration to Version 8.4.4

A dump/restore is not required for those running 8.4.X. + However, if you are upgrading from a version earlier than 8.4.2, + see the release notes for 8.4.2. +

E.35.2. Changes

  • Enforce restrictions in plperl using an opmask applied to + the whole interpreter, instead of using Safe.pm + (Tim Bunce, Andrew Dunstan) +

    Recent developments have convinced us that Safe.pm is too + insecure to rely on for making plperl trustable. This + change removes use of Safe.pm altogether, in favor of using + a separate interpreter with an opcode mask that is always applied. + Pleasant side effects of the change include that it is now possible to + use Perl's strict pragma in a natural way in + plperl, and that Perl's $a and $b + variables work as expected in sort routines, and that function + compilation is significantly faster. (CVE-2010-1169) +

  • Prevent PL/Tcl from executing untrustworthy code from + pltcl_modules (Tom) +

    PL/Tcl's feature for autoloading Tcl code from a database table + could be exploited for trojan-horse attacks, because there was no + restriction on who could create or insert into that table. This change + disables the feature unless pltcl_modules is owned by a + superuser. (However, the permissions on the table are not checked, so + installations that really need a less-than-secure modules table can + still grant suitable privileges to trusted non-superusers.) Also, + prevent loading code into the unrestricted "normal" Tcl + interpreter unless we are really going to execute a pltclu + function. (CVE-2010-1170) +

  • Fix data corruption during WAL replay of + ALTER ... SET TABLESPACE (Tom) +

    When archive_mode is on, ALTER ... SET TABLESPACE + generates a WAL record whose replay logic was incorrect. It could write + the data to the wrong place, leading to possibly-unrecoverable data + corruption. Data corruption would be observed on standby slaves, and + could occur on the master as well if a database crash and recovery + occurred after committing the ALTER and before the next + checkpoint. +

  • Fix possible crash if a cache reset message is received during + rebuild of a relcache entry (Heikki) +

    This error was introduced in 8.4.3 while fixing a related failure. +

  • Apply per-function GUC settings while running the language validator + for the function (Itagaki Takahiro) +

    This avoids failures if the function's code is invalid without the + setting; an example is that SQL functions may not parse if the + search_path is not correct. +

  • Do constraint exclusion for inherited UPDATE and + DELETE target tables when + constraint_exclusion = partition (Tom) +

    Due to an oversight, this setting previously only caused constraint + exclusion to be checked in SELECT commands. +

  • Do not allow an unprivileged user to reset superuser-only parameter + settings (Alvaro) +

    Previously, if an unprivileged user ran ALTER USER ... RESET + ALL for himself, or ALTER DATABASE ... RESET ALL for + a database he owns, this would remove all special parameter settings + for the user or database, even ones that are only supposed to be + changeable by a superuser. Now, the ALTER will only + remove the parameters that the user has permission to change. +

  • Avoid possible crash during backend shutdown if shutdown occurs + when a CONTEXT addition would be made to log entries (Tom) +

    In some cases the context-printing function would fail because the + current transaction had already been rolled back when it came time + to print a log message. +

  • Fix erroneous handling of %r parameter in + recovery_end_command (Heikki) +

    The value always came out zero. +

  • Ensure the archiver process responds to changes in + archive_command as soon as possible (Tom) +

  • Fix pl/pgsql's CASE statement to not fail when the + case expression is a query that returns no rows (Tom) +

  • Update pl/perl's ppport.h for modern Perl versions + (Andrew) +

  • Fix assorted memory leaks in pl/python (Andreas Freund, Tom) +

  • Handle empty-string connect parameters properly in ecpg (Michael) +

  • Prevent infinite recursion in psql when expanding + a variable that refers to itself (Tom) +

  • Fix psql's \copy to not add spaces around + a dot within \copy (select ...) (Tom) +

    Addition of spaces around the decimal point in a numeric literal would + result in a syntax error. +

  • Avoid formatting failure in psql when running in a + locale context that doesn't match the client_encoding + (Tom) +

  • Fix unnecessary "GIN indexes do not support whole-index scans" + errors for unsatisfiable queries using contrib/intarray + operators (Tom) +

  • Ensure that contrib/pgstattuple functions respond to cancel + interrupts promptly (Tatsuhito Kasahara) +

  • Make server startup deal properly with the case that + shmget() returns EINVAL for an existing + shared memory segment (Tom) +

    This behavior has been observed on BSD-derived kernels including OS X. + It resulted in an entirely-misleading startup failure complaining that + the shared memory request size was too large. +

  • Avoid possible crashes in syslogger process on Windows (Heikki) +

  • Deal more robustly with incomplete time zone information in the + Windows registry (Magnus) +

  • Update the set of known Windows time zone names (Magnus) +

  • Update time zone data files to tzdata release 2010j + for DST law changes in Argentina, Australian Antarctic, Bangladesh, + Mexico, Morocco, Pakistan, Palestine, Russia, Syria, Tunisia; + also historical corrections for Taiwan. +

    Also, add PKST (Pakistan Summer Time) to the default set of + timezone abbreviations. +


PrevHomeNext
Release 8.4.5UpRelease 8.4.3
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-4-5.html b/doc/src/sgml/html/release-8-4-5.html new file mode 100644 index 000000000..51bf24500 --- /dev/null +++ b/doc/src/sgml/html/release-8-4-5.html @@ -0,0 +1,783 @@ + +Release 8.4.5

E.34. Release 8.4.5

Release Date: 2010-10-04

This release contains a variety of fixes from 8.4.4. + For information about new features in the 8.4 major release, see + Section E.39. +

E.34.1. Migration to Version 8.4.5

A dump/restore is not required for those running 8.4.X. + However, if you are upgrading from a version earlier than 8.4.2, + see the release notes for 8.4.2. +

E.34.2. Changes

  • Use a separate interpreter for each calling SQL userid in PL/Perl and + PL/Tcl (Tom Lane) +

    This change prevents security problems that can be caused by subverting + Perl or Tcl code that will be executed later in the same session under + another SQL user identity (for example, within a SECURITY + DEFINER function). Most scripting languages offer numerous ways that + that might be done, such as redefining standard functions or operators + called by the target function. Without this change, any SQL user with + Perl or Tcl language usage rights can do essentially anything with the + SQL privileges of the target function's owner. +

    The cost of this change is that intentional communication among Perl + and Tcl functions becomes more difficult. To provide an escape hatch, + PL/PerlU and PL/TclU functions continue to use only one interpreter + per session. This is not considered a security issue since all such + functions execute at the trust level of a database superuser already. +

    It is likely that third-party procedural languages that claim to offer + trusted execution have similar security issues. We advise contacting + the authors of any PL you are depending on for security-critical + purposes. +

    Our thanks to Tim Bunce for pointing out this issue (CVE-2010-3433). +

  • Prevent possible crashes in pg_get_expr() by disallowing + it from being called with an argument that is not one of the system + catalog columns it's intended to be used with + (Heikki Linnakangas, Tom Lane) +

  • Treat exit code 128 (ERROR_WAIT_NO_CHILDREN) as non-fatal on + Windows (Magnus Hagander) +

    Under high load, Windows processes will sometimes fail at startup with + this error code. Formerly the postmaster treated this as a panic + condition and restarted the whole database, but that seems to be + an overreaction. +

  • Fix incorrect placement of placeholder evaluation (Tom Lane) +

    This bug could result in query outputs being non-null when they + should be null, in cases where the inner side of an outer join + is a sub-select with non-strict expressions in its output list. +

  • Fix possible duplicate scans of UNION ALL member relations + (Tom Lane) +

  • Fix "cannot handle unplanned sub-select" error (Tom Lane) +

    This occurred when a sub-select contains a join alias reference that + expands into an expression containing another sub-select. +

  • Fix mishandling of whole-row Vars that reference a view or sub-select + and appear within a nested sub-select (Tom Lane) +

  • Fix mishandling of cross-type IN comparisons (Tom Lane) +

    This could result in failures if the planner tried to implement an + IN join with a sort-then-unique-then-plain-join plan. +

  • Fix computation of ANALYZE statistics for tsvector + columns (Jan Urbanski) +

    The original coding could produce incorrect statistics, leading to + poor plan choices later. +

  • Improve planner's estimate of memory used by array_agg(), + string_agg(), and similar aggregate functions + (Hitoshi Harada) +

    The previous drastic underestimate could lead to out-of-memory failures + due to inappropriate choice of a hash-aggregation plan. +

  • Fix failure to mark cached plans as transient (Tom Lane) +

    If a plan is prepared while CREATE INDEX CONCURRENTLY is + in progress for one of the referenced tables, it is supposed to be + re-planned once the index is ready for use. This was not happening + reliably. +

  • Reduce PANIC to ERROR in some occasionally-reported btree failure cases, + and provide additional detail in the resulting error messages + (Tom Lane) +

    This should improve the system's robustness with corrupted indexes. +

  • Fix incorrect search logic for partial-match queries with GIN indexes + (Tom Lane) +

    Cases involving AND/OR combination of several GIN index conditions + didn't always give the right answer, and were sometimes much slower + than necessary. +

  • Prevent show_session_authorization() from crashing within autovacuum + processes (Tom Lane) +

  • Defend against functions returning setof record where not all the + returned rows are actually of the same rowtype (Tom Lane) +

  • Fix possible corruption of pending trigger event lists during + subtransaction rollback (Tom Lane) +

    This could lead to a crash or incorrect firing of triggers. +

  • Fix possible failure when hashing a pass-by-reference function result + (Tao Ma, Tom Lane) +

  • Improve merge join's handling of NULLs in the join columns (Tom Lane) +

    A merge join can now stop entirely upon reaching the first NULL, + if the sort order is such that NULLs sort high. +

  • Take care to fsync the contents of lockfiles (both + postmaster.pid and the socket lockfile) while writing them + (Tom Lane) +

    This omission could result in corrupted lockfile contents if the + machine crashes shortly after postmaster start. That could in turn + prevent subsequent attempts to start the postmaster from succeeding, + until the lockfile is manually removed. +

  • Avoid recursion while assigning XIDs to heavily-nested + subtransactions (Andres Freund, Robert Haas) +

    The original coding could result in a crash if there was limited + stack space. +

  • Avoid holding open old WAL segments in the walwriter process + (Magnus Hagander, Heikki Linnakangas) +

    The previous coding would prevent removal of no-longer-needed segments. +

  • Fix log_line_prefix's %i escape, + which could produce junk early in backend startup (Tom Lane) +

  • Prevent misinterpretation of partially-specified relation options + for TOAST tables (Itagaki Takahiro) +

    In particular, fillfactor would be read as zero if any + other reloption had been set for the table, leading to serious bloat. +

  • Fix inheritance count tracking in ALTER TABLE ... ADD + CONSTRAINT (Robert Haas) +

  • Fix possible data corruption in ALTER TABLE ... SET + TABLESPACE when archiving is enabled (Jeff Davis) +

  • Allow CREATE DATABASE and ALTER DATABASE ... SET + TABLESPACE to be interrupted by query-cancel (Guillaume Lelarge) +

  • Improve CREATE INDEX's checking of whether proposed index + expressions are immutable (Tom Lane) +

  • Fix REASSIGN OWNED to handle operator classes and families + (Asko Tiidumaa) +

  • Fix possible core dump when comparing two empty tsquery values + (Tom Lane) +

  • Fix LIKE's handling of patterns containing % + followed by _ (Tom Lane) +

    We've fixed this before, but there were still some incorrectly-handled + cases. +

  • Re-allow input of Julian dates prior to 0001-01-01 AD (Tom Lane) +

    Input such as 'J100000'::date worked before 8.4, + but was unintentionally broken by added error-checking. +

  • Fix PL/pgSQL to throw an error, not crash, if a cursor is closed within + a FOR loop that is iterating over that cursor + (Heikki Linnakangas) +

  • In PL/Python, defend against null pointer results from + PyCObject_AsVoidPtr and PyCObject_FromVoidPtr + (Peter Eisentraut) +

  • In libpq, fix full SSL certificate verification for the + case where both host and hostaddr are specified + (Tom Lane) +

  • Make psql recognize DISCARD ALL as a command that should + not be encased in a transaction block in autocommit-off mode + (Itagaki Takahiro) +

  • Fix some issues in pg_dump's handling of SQL/MED objects + (Tom Lane) +

    Notably, pg_dump would always fail if run by a + non-superuser, which was not intended. +

  • Improve pg_dump and pg_restore's + handling of non-seekable archive files (Tom Lane, Robert Haas) +

    This is important for proper functioning of parallel restore. +

  • Improve parallel pg_restore's ability to cope with selective restore + (-L option) (Tom Lane) +

    The original code tended to fail if the -L file commanded + a non-default restore ordering. +

  • Fix ecpg to process data from RETURNING + clauses correctly (Michael Meskes) +

  • Fix some memory leaks in ecpg (Zoltan Boszormenyi) +

  • Improve contrib/dblink's handling of tables containing + dropped columns (Tom Lane) +

  • Fix connection leak after "duplicate connection name" + errors in contrib/dblink (Itagaki Takahiro) +

  • Fix contrib/dblink to handle connection names longer than + 62 bytes correctly (Itagaki Takahiro) +

  • Add hstore(text, text) + function to contrib/hstore (Robert Haas) +

    This function is the recommended substitute for the now-deprecated + => operator. It was back-patched so that future-proofed + code can be used with older server versions. Note that the patch will + be effective only after contrib/hstore is installed or + reinstalled in a particular database. Users might prefer to execute + the CREATE FUNCTION command by hand, instead. +

  • Update build infrastructure and documentation to reflect the source code + repository's move from CVS to Git (Magnus Hagander and others) +

  • Update time zone data files to tzdata release 2010l + for DST law changes in Egypt and Palestine; also historical corrections + for Finland. +

    This change also adds new names for two Micronesian timezones: + Pacific/Chuuk is now preferred over Pacific/Truk (and the preferred + abbreviation is CHUT not TRUT) and Pacific/Pohnpei is preferred over + Pacific/Ponape. +

  • Make Windows' "N. Central Asia Standard Time" timezone map to + Asia/Novosibirsk, not Asia/Almaty (Magnus Hagander) +

    Microsoft changed the DST behavior of this zone in the timezone update + from KB976098. Asia/Novosibirsk is a better match to its new behavior. +


PrevHomeNext
Release 8.4.6UpRelease 8.4.4
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-4-6.html b/doc/src/sgml/html/release-8-4-6.html new file mode 100644 index 000000000..6164d81b0 --- /dev/null +++ b/doc/src/sgml/html/release-8-4-6.html @@ -0,0 +1,577 @@ + +Release 8.4.6

E.33. Release 8.4.6

Release Date: 2010-12-16

This release contains a variety of fixes from 8.4.5. + For information about new features in the 8.4 major release, see + Section E.39. +

E.33.1. Migration to Version 8.4.6

A dump/restore is not required for those running 8.4.X. + However, if you are upgrading from a version earlier than 8.4.2, + see the release notes for 8.4.2. +

E.33.2. Changes

  • Force the default + wal_sync_method + to be fdatasync on Linux (Tom Lane, Marti Raudsepp) +

    The default on Linux has actually been fdatasync for many + years, but recent kernel changes caused PostgreSQL to + choose open_datasync instead. This choice did not result + in any performance improvement, and caused outright failures on + certain filesystems, notably ext4 with the + data=journal mount option. +

  • Fix assorted bugs in WAL replay logic for GIN indexes (Tom Lane) +

    This could result in "bad buffer id: 0" failures or + corruption of index contents during replication. +

  • Fix recovery from base backup when the starting checkpoint WAL record + is not in the same WAL segment as its redo point (Jeff Davis) +

  • Fix persistent slowdown of autovacuum workers when multiple workers + remain active for a long time (Tom Lane) +

    The effective vacuum_cost_limit for an autovacuum worker + could drop to nearly zero if it processed enough tables, causing it + to run extremely slowly. +

  • Add support for detecting register-stack overrun on IA64 + (Tom Lane) +

    The IA64 architecture has two hardware stacks. Full + prevention of stack-overrun failures requires checking both. +

  • Add a check for stack overflow in copyObject() (Tom Lane) +

    Certain code paths could crash due to stack overflow given a + sufficiently complex query. +

  • Fix detection of page splits in temporary GiST indexes (Heikki + Linnakangas) +

    It is possible to have a "concurrent" page split in a + temporary index, if for example there is an open cursor scanning the + index when an insertion is done. GiST failed to detect this case and + hence could deliver wrong results when execution of the cursor + continued. +

  • Fix error checking during early connection processing (Tom Lane) +

    The check for too many child processes was skipped in some cases, + possibly leading to postmaster crash when attempting to add the new + child process to fixed-size arrays. +

  • Improve efficiency of window functions (Tom Lane) +

    Certain cases where a large number of tuples needed to be read in + advance, but work_mem was large enough to allow them all + to be held in memory, were unexpectedly slow. + percent_rank(), cume_dist() and + ntile() in particular were subject to this problem. +

  • Avoid memory leakage while ANALYZE'ing complex index + expressions (Tom Lane) +

  • Ensure an index that uses a whole-row Var still depends on its table + (Tom Lane) +

    An index declared like create index i on t (foo(t.*)) + would not automatically get dropped when its table was dropped. +

  • Do not "inline" a SQL function with multiple OUT + parameters (Tom Lane) +

    This avoids a possible crash due to loss of information about the + expected result rowtype. +

  • Behave correctly if ORDER BY, LIMIT, + FOR UPDATE, or WITH is attached to the + VALUES part of INSERT ... VALUES (Tom Lane) +

  • Fix constant-folding of COALESCE() expressions (Tom Lane) +

    The planner would sometimes attempt to evaluate sub-expressions that + in fact could never be reached, possibly leading to unexpected errors. +

  • Fix postmaster crash when connection acceptance + (accept() or one of the calls made immediately after it) + fails, and the postmaster was compiled with GSSAPI support (Alexander + Chernikov) +

  • Fix missed unlink of temporary files when log_temp_files + is active (Tom Lane) +

    If an error occurred while attempting to emit the log message, the + unlink was not done, resulting in accumulation of temp files. +

  • Add print functionality for InhRelation nodes (Tom Lane) +

    This avoids a failure when debug_print_parse is enabled + and certain types of query are executed. +

  • Fix incorrect calculation of distance from a point to a horizontal + line segment (Tom Lane) +

    This bug affected several different geometric distance-measurement + operators. +

  • Fix incorrect calculation of transaction status in + ecpg (Itagaki Takahiro) +

  • Fix PL/pgSQL's handling of "simple" + expressions to not fail in recursion or error-recovery cases (Tom Lane) +

  • Fix PL/Python's handling of set-returning functions + (Jan Urbanski) +

    Attempts to call SPI functions within the iterator generating a set + result would fail. +

  • Fix bug in contrib/cube's GiST picksplit algorithm + (Alexander Korotkov) +

    This could result in considerable inefficiency, though not actually + incorrect answers, in a GiST index on a cube column. + If you have such an index, consider REINDEXing it after + installing this update. +

  • Don't emit "identifier will be truncated" notices in + contrib/dblink except when creating new connections + (Itagaki Takahiro) +

  • Fix potential coredump on missing public key in + contrib/pgcrypto (Marti Raudsepp) +

  • Fix memory leak in contrib/xml2's XPath query functions + (Tom Lane) +

  • Update time zone data files to tzdata release 2010o + for DST law changes in Fiji and Samoa; + also historical corrections for Hong Kong. +


PrevHomeNext
Release 8.4.7UpRelease 8.4.5
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-4-7.html b/doc/src/sgml/html/release-8-4-7.html new file mode 100644 index 000000000..92d1e3ac8 --- /dev/null +++ b/doc/src/sgml/html/release-8-4-7.html @@ -0,0 +1,360 @@ + +Release 8.4.7

E.32. Release 8.4.7

Release Date: 2011-01-31

This release contains a variety of fixes from 8.4.6. + For information about new features in the 8.4 major release, see + Section E.39. +

E.32.1. Migration to Version 8.4.7

A dump/restore is not required for those running 8.4.X. + However, if you are upgrading from a version earlier than 8.4.2, + see the release notes for 8.4.2. +

E.32.2. Changes

  • Avoid failures when EXPLAIN tries to display a simple-form + CASE expression (Tom Lane) +

    If the CASE's test expression was a constant, the planner + could simplify the CASE into a form that confused the + expression-display code, resulting in "unexpected CASE WHEN + clause" errors. +

  • Fix assignment to an array slice that is before the existing range + of subscripts (Tom Lane) +

    If there was a gap between the newly added subscripts and the first + pre-existing subscript, the code miscalculated how many entries needed + to be copied from the old array's null bitmap, potentially leading to + data corruption or crash. +

  • Avoid unexpected conversion overflow in planner for very distant date + values (Tom Lane) +

    The date type supports a wider range of dates than can be + represented by the timestamp types, but the planner assumed it + could always convert a date to timestamp with impunity. +

  • Fix pg_restore's text output for large objects (BLOBs) + when standard_conforming_strings is on (Tom Lane) +

    Although restoring directly to a database worked correctly, string + escaping was incorrect if pg_restore was asked for + SQL text output and standard_conforming_strings had been + enabled in the source database. +

  • Fix erroneous parsing of tsquery values containing + ... & !(subexpression) | ... (Tom Lane) +

    Queries containing this combination of operators were not executed + correctly. The same error existed in contrib/intarray's + query_int type and contrib/ltree's + ltxtquery type. +

  • Fix buffer overrun in contrib/intarray's input function + for the query_int type (Apple) +

    This bug is a security risk since the function's return address could + be overwritten. Thanks to Apple Inc's security team for reporting this + issue and supplying the fix. (CVE-2010-4015) +

  • Fix bug in contrib/seg's GiST picksplit algorithm + (Alexander Korotkov) +

    This could result in considerable inefficiency, though not actually + incorrect answers, in a GiST index on a seg column. + If you have such an index, consider REINDEXing it after + installing this update. (This is identical to the bug that was fixed in + contrib/cube in the previous update.) +


PrevHomeNext
Release 8.4.8UpRelease 8.4.6
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-4-8.html b/doc/src/sgml/html/release-8-4-8.html new file mode 100644 index 000000000..961dd6253 --- /dev/null +++ b/doc/src/sgml/html/release-8-4-8.html @@ -0,0 +1,466 @@ + +Release 8.4.8

E.31. Release 8.4.8

Release Date: 2011-04-18

This release contains a variety of fixes from 8.4.7. + For information about new features in the 8.4 major release, see + Section E.39. +

E.31.1. Migration to Version 8.4.8

A dump/restore is not required for those running 8.4.X. +

However, if your installation was upgraded from a previous major + release by running pg_upgrade, you should take + action to prevent possible data loss due to a now-fixed bug in + pg_upgrade. The recommended solution is to run + VACUUM FREEZE on all TOAST tables. + More information is available at http://wiki.postgresql.org/wiki/20110408pg_upgrade_fix. +

Also, if you are upgrading from a version earlier than 8.4.2, + see the release notes for 8.4.2. +

E.31.2. Changes

  • Fix pg_upgrade's handling of TOAST tables + (Bruce Momjian) +

    The pg_class.relfrozenxid value for + TOAST tables was not correctly copied into the new installation + during pg_upgrade. This could later result in + pg_clog files being discarded while they were still + needed to validate tuples in the TOAST tables, leading to + "could not access status of transaction" failures. +

    This error poses a significant risk of data loss for installations + that have been upgraded with pg_upgrade. This patch + corrects the problem for future uses of pg_upgrade, + but does not in itself cure the issue in installations that have been + processed with a buggy version of pg_upgrade. +

  • Suppress incorrect "PD_ALL_VISIBLE flag was incorrectly set" + warning (Heikki Linnakangas) +

    VACUUM would sometimes issue this warning in cases that + are actually valid. +

  • Disallow including a composite type in itself (Tom Lane) +

    This prevents scenarios wherein the server could recurse infinitely + while processing the composite type. While there are some possible + uses for such a structure, they don't seem compelling enough to + justify the effort required to make sure it always works safely. +

  • Avoid potential deadlock during catalog cache initialization + (Nikhil Sontakke) +

    In some cases the cache loading code would acquire share lock on a + system index before locking the index's catalog. This could deadlock + against processes trying to acquire exclusive locks in the other, + more standard order. +

  • Fix dangling-pointer problem in BEFORE ROW UPDATE trigger + handling when there was a concurrent update to the target tuple + (Tom Lane) +

    This bug has been observed to result in intermittent "cannot + extract system attribute from virtual tuple" failures while trying to + do UPDATE RETURNING ctid. There is a very small probability + of more serious errors, such as generating incorrect index entries for + the updated tuple. +

  • Disallow DROP TABLE when there are pending deferred trigger + events for the table (Tom Lane) +

    Formerly the DROP would go through, leading to + "could not open relation with OID nnn" errors when the + triggers were eventually fired. +

  • Prevent crash triggered by constant-false WHERE conditions during + GEQO optimization (Tom Lane) +

  • Improve planner's handling of semi-join and anti-join cases + (Tom Lane) +

  • Fix selectivity estimation for text search to account for NULLs + (Jesper Krogh) +

  • Improve PL/pgSQL's ability to handle row types with dropped columns + (Pavel Stehule) +

    This is a back-patch of fixes previously made in 9.0. +

  • Fix PL/Python memory leak involving array slices (Daniel Popowich) +

  • Fix pg_restore to cope with long lines (over 1KB) in + TOC files (Tom Lane) +

  • Put in more safeguards against crashing due to division-by-zero + with overly enthusiastic compiler optimization (Aurelien Jarno) +

  • Support use of dlopen() in FreeBSD and OpenBSD on MIPS (Tom Lane) +

    There was a hard-wired assumption that this system function was not + available on MIPS hardware on these systems. Use a compile-time test + instead, since more recent versions have it. +

  • Fix compilation failures on HP-UX (Heikki Linnakangas) +

  • Fix version-incompatibility problem with libintl on + Windows (Hiroshi Inoue) +

  • Fix usage of xcopy in Windows build scripts to + work correctly under Windows 7 (Andrew Dunstan) +

    This affects the build scripts only, not installation or usage. +

  • Fix path separator used by pg_regress on Cygwin + (Andrew Dunstan) +

  • Update time zone data files to tzdata release 2011f + for DST law changes in Chile, Cuba, Falkland Islands, Morocco, Samoa, + and Turkey; also historical corrections for South Australia, Alaska, + and Hawaii. +


PrevHomeNext
Release 8.4.9UpRelease 8.4.7
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-4-9.html b/doc/src/sgml/html/release-8-4-9.html new file mode 100644 index 000000000..29f514c96 --- /dev/null +++ b/doc/src/sgml/html/release-8-4-9.html @@ -0,0 +1,793 @@ + +Release 8.4.9

E.30. Release 8.4.9

Release Date: 2011-09-26

This release contains a variety of fixes from 8.4.8. + For information about new features in the 8.4 major release, see + Section E.39. +

E.30.1. Migration to Version 8.4.9

A dump/restore is not required for those running 8.4.X. +

However, if you are upgrading from a version earlier than 8.4.8, + see the release notes for 8.4.8. +

E.30.2. Changes

  • Fix bugs in indexing of in-doubt HOT-updated tuples (Tom Lane) +

    These bugs could result in index corruption after reindexing a system + catalog. They are not believed to affect user indexes. +

  • Fix multiple bugs in GiST index page split processing (Heikki + Linnakangas) +

    The probability of occurrence was low, but these could lead to index + corruption. +

  • Fix possible buffer overrun in tsvector_concat() + (Tom Lane) +

    The function could underestimate the amount of memory needed for its + result, leading to server crashes. +

  • Fix crash in xml_recv when processing a + "standalone" parameter (Tom Lane) +

  • Make pg_options_to_table return NULL for an option with no + value (Tom Lane) +

    Previously such cases would result in a server crash. +

  • Avoid possibly accessing off the end of memory in ANALYZE + and in SJIS-2004 encoding conversion (Noah Misch) +

    This fixes some very-low-probability server crash scenarios. +

  • Prevent intermittent hang in interactions of startup process with + bgwriter process (Simon Riggs) +

    This affected recovery in non-hot-standby cases. +

  • Fix race condition in relcache init file invalidation (Tom Lane) +

    There was a window wherein a new backend process could read a stale init + file but miss the inval messages that would tell it the data is stale. + The result would be bizarre failures in catalog accesses, typically + "could not read block 0 in file ..." later during startup. +

  • Fix memory leak at end of a GiST index scan (Tom Lane) +

    Commands that perform many separate GiST index scans, such as + verification of a new GiST-based exclusion constraint on a table + already containing many rows, could transiently require large amounts of + memory due to this leak. +

  • Fix incorrect memory accounting (leading to possible memory bloat) in + tuplestores supporting holdable cursors and plpgsql's RETURN + NEXT command (Tom Lane) +

  • Fix performance problem when constructing a large, lossy bitmap + (Tom Lane) +

  • Fix join selectivity estimation for unique columns (Tom Lane) +

    This fixes an erroneous planner heuristic that could lead to poor + estimates of the result size of a join. +

  • Fix nested PlaceHolderVar expressions that appear only in sub-select + target lists (Tom Lane) +

    This mistake could result in outputs of an outer join incorrectly + appearing as NULL. +

  • Allow nested EXISTS queries to be optimized properly (Tom + Lane) +

  • Fix array- and path-creating functions to ensure padding bytes are + zeroes (Tom Lane) +

    This avoids some situations where the planner will think that + semantically-equal constants are not equal, resulting in poor + optimization. +

  • Fix EXPLAIN to handle gating Result nodes within + inner-indexscan subplans (Tom Lane) +

    The usual symptom of this oversight was "bogus varno" errors. +

  • Work around gcc 4.6.0 bug that breaks WAL replay (Tom Lane) +

    This could lead to loss of committed transactions after a server crash. +

  • Fix dump bug for VALUES in a view (Tom Lane) +

  • Disallow SELECT FOR UPDATE/SHARE on sequences (Tom Lane) +

    This operation doesn't work as expected and can lead to failures. +

  • Fix VACUUM so that it always updates + pg_class.reltuples/relpages (Tom + Lane) +

    This fixes some scenarios where autovacuum could make increasingly poor + decisions about when to vacuum tables. +

  • Defend against integer overflow when computing size of a hash table (Tom + Lane) +

  • Fix cases where CLUSTER might attempt to access + already-removed TOAST data (Tom Lane) +

  • Fix portability bugs in use of credentials control messages for + "peer" authentication (Tom Lane) +

  • Fix SSPI login when multiple roundtrips are required (Ahmed Shinwari, + Magnus Hagander) +

    The typical symptom of this problem was "The function requested is + not supported" errors during SSPI login. +

  • Throw an error if pg_hba.conf contains hostssl + but SSL is disabled (Tom Lane) +

    This was concluded to be more user-friendly than the previous behavior + of silently ignoring such lines. +

  • Fix typo in pg_srand48 seed initialization (Andres Freund) +

    This led to failure to use all bits of the provided seed. This function + is not used on most platforms (only those without srandom), + and the potential security exposure from a less-random-than-expected + seed seems minimal in any case. +

  • Avoid integer overflow when the sum of LIMIT and + OFFSET values exceeds 2^63 (Heikki Linnakangas) +

  • Add overflow checks to int4 and int8 versions of + generate_series() (Robert Haas) +

  • Fix trailing-zero removal in to_char() (Marti Raudsepp) +

    In a format with FM and no digit positions + after the decimal point, zeroes to the left of the decimal point could + be removed incorrectly. +

  • Fix pg_size_pretty() to avoid overflow for inputs close to + 2^63 (Tom Lane) +

  • Weaken plpgsql's check for typmod matching in record values (Tom Lane) +

    An overly enthusiastic check could lead to discarding length modifiers + that should have been kept. +

  • Correctly handle quotes in locale names during initdb + (Heikki Linnakangas) +

    The case can arise with some Windows locales, such as "People's + Republic of China". +

  • Fix pg_upgrade to preserve toast tables' relfrozenxids + during an upgrade from 8.3 (Bruce Momjian) +

    Failure to do this could lead to pg_clog files being + removed too soon after the upgrade. +

  • In pg_ctl, support silent mode for service registrations + on Windows (MauMau) +

  • Fix psql's counting of script file line numbers during + COPY from a different file (Tom Lane) +

  • Fix pg_restore's direct-to-database mode for + standard_conforming_strings (Tom Lane) +

    pg_restore could emit incorrect commands when restoring + directly to a database server from an archive file that had been made + with standard_conforming_strings set to on. +

  • Be more user-friendly about unsupported cases for parallel + pg_restore (Tom Lane) +

    This change ensures that such cases are detected and reported before + any restore actions have been taken. +

  • Fix write-past-buffer-end and memory leak in libpq's + LDAP service lookup code (Albe Laurenz) +

  • In libpq, avoid failures when using nonblocking I/O + and an SSL connection (Martin Pihlak, Tom Lane) +

  • Improve libpq's handling of failures during connection startup + (Tom Lane) +

    In particular, the response to a server report of fork() + failure during SSL connection startup is now saner. +

  • Improve libpq's error reporting for SSL failures (Tom + Lane) +

  • Fix PQsetvalue() to avoid possible crash when adding a new + tuple to a PGresult originally obtained from a server + query (Andrew Chernow) +

  • Make ecpglib write double values with 15 digits + precision (Akira Kurosawa) +

  • In ecpglib, be sure LC_NUMERIC setting is + restored after an error (Michael Meskes) +

  • Apply upstream fix for blowfish signed-character bug (CVE-2011-2483) + (Tom Lane) +

    contrib/pg_crypto's blowfish encryption code could give + wrong results on platforms where char is signed (which is most), + leading to encrypted passwords being weaker than they should be. +

  • Fix memory leak in contrib/seg (Heikki Linnakangas) +

  • Fix pgstatindex() to give consistent results for empty + indexes (Tom Lane) +

  • Allow building with perl 5.14 (Alex Hunsaker) +

  • Update configure script's method for probing existence of system + functions (Tom Lane) +

    The version of autoconf we used in 8.3 and 8.2 could be fooled by + compilers that perform link-time optimization. +

  • Fix assorted issues with build and install file paths containing spaces + (Tom Lane) +

  • Update time zone data files to tzdata release 2011i + for DST law changes in Canada, Egypt, Russia, Samoa, and South Sudan. +


PrevHomeNext
Release 8.4.10UpRelease 8.4.8
\ No newline at end of file diff --git a/doc/src/sgml/html/release-8-4.html b/doc/src/sgml/html/release-8-4.html new file mode 100644 index 000000000..98b90b87c --- /dev/null +++ b/doc/src/sgml/html/release-8-4.html @@ -0,0 +1,5247 @@ + +Release 8.4

E.39. Release 8.4

Release Date: 2009-07-01

E.39.1. Overview

After many years of development, PostgreSQL has + become feature-complete in many areas. This release shows a + targeted approach to adding features (e.g., authentication, + monitoring, space reuse), and adds capabilities defined in the + later SQL standards. The major areas of enhancement are: +

  • Windowing Functions +

  • Common Table Expressions and Recursive Queries +

  • Default and variadic parameters for functions +

  • Parallel Restore +

  • Column Permissions +

  • Per-database locale settings +

  • Improved hash indexes +

  • Improved join performance for EXISTS and NOT EXISTS queries +

  • Easier-to-use Warm Standby +

  • Automatic sizing of the Free Space Map +

  • Visibility Map (greatly reduces vacuum overhead for slowly-changing tables) +

  • Version-aware psql (backslash commands work against older servers) +

  • Support SSL certificates for user authentication +

  • Per-function runtime statistics +

  • Easy editing of functions in psql +

  • New contrib modules: pg_stat_statements, auto_explain, citext, btree_gin +

The above items are explained in more detail in the sections below. +

E.39.2. Migration to Version 8.4

A dump/restore using pg_dump is + required for those wishing to migrate data from any previous + release. +

Observe the following incompatibilities: +

E.39.2.1. General

  • Use 64-bit integer datetimes by default (Neil Conway) +

    Previously this was selected by configure's + --enable-integer-datetimes option. To retain + the old behavior, build with --disable-integer-datetimes. +

  • Remove ipcclean utility command (Bruce) +

    The utility only worked on a few platforms. Users should use + their operating system tools instead. +

E.39.2.2. Server Settings

  • Change default setting for + log_min_messages to warning (previously + it was notice) to reduce log file volume (Tom) +

  • Change default setting for max_prepared_transactions to + zero (previously it was 5) (Tom) +

  • Make debug_print_parse, debug_print_rewritten, + and debug_print_plan + output appear at LOG message level, not + DEBUG1 as formerly (Tom) +

  • Make debug_pretty_print default to on (Tom) +

  • Remove explain_pretty_print parameter (no longer needed) (Tom) +

  • Make log_temp_files settable by superusers only, like other + logging options (Simon Riggs) +

  • Remove automatic appending of the epoch timestamp when no % + escapes are present in log_filename (Robert Haas) +

    This change was made because some users wanted a fixed log filename, + for use with an external log rotation tool. +

  • Remove log_restartpoints from recovery.conf; + instead use log_checkpoints (Simon) +

  • Remove krb_realm and krb_server_hostname; + these are now set in pg_hba.conf instead (Magnus) +

  • There are also significant changes in pg_hba.conf, + as described below. +

E.39.2.3. Queries

  • Change TRUNCATE and LOCK to + apply to child tables of the specified table(s) (Peter) +

    These commands now accept an ONLY option that prevents + processing child tables; this option must be used if the old + behavior is needed. +

  • SELECT DISTINCT and + UNION/INTERSECT/EXCEPT + no longer always produce sorted output (Tom) +

    Previously, these types of queries always removed duplicate rows + by means of Sort/Unique processing (i.e., sort then remove adjacent + duplicates). Now they can be implemented by hashing, which will not + produce sorted output. If an application relied on the output being + in sorted order, the recommended fix is to add an ORDER BY + clause. As a short-term workaround, the previous behavior can be + restored by disabling enable_hashagg, but that is a very + performance-expensive fix. SELECT DISTINCT ON never uses + hashing, however, so its behavior is unchanged. +

  • Force child tables to inherit CHECK constraints from parents + (Alex Hunsaker, Nikhil Sontakke, Tom) +

    Formerly it was possible to drop such a constraint from a child + table, allowing rows that violate the constraint to be visible + when scanning the parent table. This was deemed inconsistent, + as well as contrary to SQL standard. +

  • Disallow negative LIMIT or OFFSET + values, rather than treating them as zero (Simon) +

  • Disallow LOCK TABLE outside a transaction block + (Tom) +

    Such an operation is useless because the lock would be released + immediately. +

  • Sequences now contain an additional start_value column + (Zoltan Boszormenyi) +

    This supports ALTER SEQUENCE ... RESTART. +

E.39.2.4. Functions and Operators

  • Make numeric zero raised to a fractional power return + 0, rather than throwing an error, and make + numeric zero raised to the zero power return 1, + rather than error (Bruce) +

    This matches the longstanding float8 behavior. +

  • Allow unary minus of floating-point values to produce minus zero (Tom) +

    The changed behavior is more IEEE-standard + compliant. +

  • Throw an error if an escape character is the last character in + a LIKE pattern (i.e., it has nothing to escape) (Tom) +

    Previously, such an escape character was silently ignored, + thus possibly masking application logic errors. +

  • Remove ~=~ and ~<>~ operators + formerly used for LIKE index comparisons (Tom) +

    Pattern indexes now use the regular equality operator. +

  • xpath() now passes its arguments to libxml + without any changes (Andrew) +

    This means that the XML argument must be a well-formed XML document. + The previous coding attempted to allow XML fragments, but it did not + work well. +

  • Make xmlelement() format attribute values just like + content values (Peter) +

    Previously, attribute values were formatted according to the + normal SQL output behavior, which is sometimes at odds with + XML rules. +

  • Rewrite memory management for libxml-using functions + (Tom) +

    This change should avoid some compatibility problems with use of + libxml in PL/Perl and other add-on code. +

  • Adopt a faster algorithm for hash functions (Kenneth Marshall, + based on work of Bob Jenkins) +

    Many of the built-in hash functions now deliver different results on + little-endian and big-endian platforms. +

E.39.2.4.1. Temporal Functions and Operators

  • DateStyle no longer controls interval output + formatting; instead there is a new variable IntervalStyle + (Ron Mayer) +

  • Improve consistency of handling of fractional seconds in + timestamp and interval output (Ron Mayer) +

    This may result in displaying a different number of fractional + digits than before, or rounding instead of truncating. +

  • Make to_char()'s localized month/day names depend + on LC_TIME, not LC_MESSAGES (Euler + Taveira de Oliveira) +

  • Cause to_date() and to_timestamp() + to more consistently report errors for invalid input (Brendan + Jurd) +

    Previous versions would often ignore or silently misread input + that did not match the format string. Such cases will now + result in an error. +

  • Fix to_timestamp() to not require upper/lower case + matching for meridian (AM/PM) and era + (BC/AD) format designations (Brendan + Jurd) +

    For example, input value ad now matches the format + string AD. +

E.39.3. Changes

Below you will find a detailed account of the changes between + PostgreSQL 8.4 and the previous major + release. +

E.39.3.1. Performance

  • Improve optimizer statistics calculations (Jan Urbanski, Tom) +

    In particular, estimates for full-text-search operators are + greatly improved. +

  • Allow SELECT DISTINCT and + UNION/INTERSECT/EXCEPT to + use hashing (Tom) +

    This means that these types of queries no longer automatically + produce sorted output. +

  • Create explicit concepts of semi-joins and anti-joins (Tom) +

    This work formalizes our previous ad-hoc treatment of IN + (SELECT ...) clauses, and extends it to EXISTS and + NOT EXISTS clauses. It should result in significantly + better planning of EXISTS and NOT EXISTS + queries. In general, logically equivalent IN and + EXISTS clauses should now have similar performance, + whereas previously IN often won. +

  • Improve optimization of sub-selects beneath outer joins (Tom) +

    Formerly, a sub-select or view could not be optimized very well if it + appeared within the nullable side of an outer join and contained + non-strict expressions (for instance, constants) in its result list. +

  • Improve the performance of text_position() and + related functions by using Boyer-Moore-Horspool searching (David + Rowley) +

    This is particularly helpful for long search patterns. +

  • Reduce I/O load of writing the statistics collection file + by writing the file only when requested (Martin Pihlak) +

  • Improve performance for bulk inserts (Robert Haas, Simon) +

  • Increase the default value of default_statistics_target + from 10 to 100 (Greg Sabino Mullane, + Tom) +

    The maximum value was also increased from 1000 to + 10000. +

  • Perform constraint_exclusion checking by default + in queries involving inheritance or UNION ALL (Tom) +

    A new constraint_exclusion setting, + partition, was added to specify this behavior. +

  • Allow I/O read-ahead for bitmap index scans (Greg Stark) +

    The amount of read-ahead is controlled by + effective_io_concurrency. This feature is available only + if the kernel has posix_fadvise() support. +

  • Inline simple set-returning SQL functions in + FROM clauses (Richard Rowell) +

  • Improve performance of multi-batch hash joins by providing a special + case for join key values that are especially common in the outer + relation (Bryce Cutt, Ramon Lawrence) +

  • Reduce volume of temporary data in multi-batch hash joins + by suppressing "physical tlist" optimization (Michael + Henderson, Ramon Lawrence) +

  • Avoid waiting for idle-in-transaction sessions during + CREATE INDEX CONCURRENTLY (Simon) +

  • Improve performance of shared cache invalidation (Tom) +

E.39.3.2. Server

E.39.3.2.1. Settings

  • Convert many postgresql.conf settings to enumerated + values so that pg_settings can display the valid + values (Magnus) +

  • Add cursor_tuple_fraction parameter to control the + fraction of a cursor's rows that the planner assumes will be + fetched (Robert Hell) +

  • Allow underscores in the names of custom variable + classes in postgresql.conf (Tom) +

E.39.3.2.2. Authentication and security

  • Remove support for the (insecure) crypt authentication method + (Magnus) +

    This effectively obsoletes pre-PostgreSQL 7.2 client + libraries, as there is no longer any non-plaintext password method that + they can use. +

  • Support regular expressions in pg_ident.conf + (Magnus) +

  • Allow Kerberos/GSSAPI parameters + to be changed without restarting the postmaster (Magnus) +

  • Support SSL certificate chains in server certificate + file (Andrew Gierth) +

    Including the full certificate chain makes the client able + to verify the certificate without having all intermediate CA + certificates present in the local store, which is often the case for + commercial CAs. +

  • Report appropriate error message for combination of MD5 + authentication and db_user_namespace enabled (Bruce) +

E.39.3.2.3. pg_hba.conf

  • Change all authentication options to use name=value + syntax (Magnus) +

    This makes incompatible changes to the ldap, + pam and ident authentication methods. All + pg_hba.conf entries with these methods need to be + rewritten using the new format. +

  • Remove the ident sameuser option, instead making that + behavior the default if no usermap is specified (Magnus) +

  • Allow a usermap parameter for all external authentication methods + (Magnus) +

    Previously a usermap was only supported for ident + authentication. +

  • Add clientcert option to control requesting of a + client certificate (Magnus) +

    Previously this was controlled by the presence of a root + certificate file in the server's data directory. +

  • Add cert authentication method to allow + user authentication via SSL certificates + (Magnus) +

    Previously SSL certificates could only verify that + the client had access to a certificate, not authenticate a + user. +

  • Allow krb5, gssapi and sspi + realm and krb5 host settings to be specified in + pg_hba.conf (Magnus) +

    These override the settings in postgresql.conf. +

  • Add include_realm parameter for krb5, + gssapi, and sspi methods (Magnus) +

    This allows identical usernames from different realms to be + authenticated as different database users using usermaps. +

  • Parse pg_hba.conf fully when it is loaded, + so that errors are reported immediately (Magnus) +

    Previously, most errors in the file wouldn't be detected until clients + tried to connect, so an erroneous file could render the system + unusable. With the new behavior, if an error is detected during + reload then the bad file is rejected and the postmaster continues + to use its old copy. +

  • Show all parsing errors in pg_hba.conf instead of + aborting after the first one (Selena Deckelmann) +

  • Support ident authentication over Unix-domain sockets + on Solaris (Garick Hamlin) +

E.39.3.2.4. Continuous Archiving

  • Provide an option to pg_start_backup() to force its + implied checkpoint to finish as quickly as possible (Tom) +

    The default behavior avoids excess I/O consumption, but that is + pointless if no concurrent query activity is going on. +

  • Make pg_stop_backup() wait for modified WAL + files to be archived (Simon) +

    This guarantees that the backup is valid at the time + pg_stop_backup() completes. +

  • When archiving is enabled, rotate the last WAL segment at shutdown + so that all transactions can be archived immediately + (Guillaume Smet, Heikki) +

  • Delay "smart" shutdown while a continuous archiving base backup + is in progress (Laurenz Albe) +

  • Cancel a continuous archiving base backup if "fast" shutdown + is requested (Laurenz Albe) +

  • Allow recovery.conf boolean variables to take the + same range of string values as postgresql.conf + boolean variables + (Bruce) +

E.39.3.2.5. Monitoring

  • Add pg_conf_load_time() to report when + the PostgreSQL configuration files were last loaded + (George Gensure) +

  • Add pg_terminate_backend() to safely terminate a + backend (the SIGTERM signal works also) (Tom, Bruce) +

    While it's always been possible to SIGTERM a single + backend, this was previously considered unsupported; and testing + of the case found some bugs that are now fixed. +

  • Add ability to track user-defined functions' call counts and + runtimes (Martin Pihlak) +

    Function statistics appear in a new system view, + pg_stat_user_functions. Tracking is controlled + by the new parameter track_functions. +

  • Allow specification of the maximum query string size in + pg_stat_activity via new + track_activity_query_size parameter (Thomas Lee) +

  • Increase the maximum line length sent to syslog, in + hopes of improving performance (Tom) +

  • Add read-only configuration variables segment_size, + wal_block_size, and wal_segment_size + (Bernd Helmle) +

  • When reporting a deadlock, report the text of all queries involved + in the deadlock to the server log (Itagaki Takahiro) +

  • Add pg_stat_get_activity(pid) function to return + information about a specific process id (Magnus) +

  • Allow the location of the server's statistics file to be specified + via stats_temp_directory (Magnus) +

    This allows the statistics file to be placed in a + RAM-resident directory to reduce I/O requirements. + On startup/shutdown, the file is copied to its traditional location + ($PGDATA/global/) so it is preserved across restarts. +

E.39.3.3. Queries

  • Add support for WINDOW functions (Hitoshi Harada) +

  • Add support for WITH clauses (CTEs), including WITH + RECURSIVE (Yoshiyuki Asaba, Tatsuo Ishii, Tom) +

  • Add TABLE command (Peter) +

    TABLE tablename is a SQL standard short-hand for + SELECT * FROM tablename. +

  • Allow AS to be optional when specifying a + SELECT (or RETURNING) column output + label (Hiroshi Saito) +

    This works so long as the column label is not any + PostgreSQL keyword; otherwise AS is still + needed. +

  • Support set-returning functions in SELECT result lists + even for functions that return their result via a tuplestore (Tom) +

    In particular, this means that functions written in PL/pgSQL + and other PL languages can now be called this way. +

  • Support set-returning functions in the output of aggregation + and grouping queries (Tom) +

  • Allow SELECT FOR UPDATE/SHARE to work + on inheritance trees (Tom) +

  • Add infrastructure for SQL/MED (Martin Pihlak, + Peter) +

    There are no remote or external SQL/MED capabilities + yet, but this change provides a standardized and future-proof + system for managing connection information for modules like + dblink and plproxy. +

  • Invalidate cached plans when referenced schemas, functions, operators, + or operator classes are modified (Martin Pihlak, Tom) +

    This improves the system's ability to respond to on-the-fly + DDL changes. +

  • Allow comparison of composite types and allow arrays of + anonymous composite types (Tom) +

    This allows constructs such as + row(1, 1.1) = any (array[row(7, 7.7), row(1, 1.0)]). + This is particularly useful in recursive queries. +

  • Add support for Unicode string literal and identifier specifications + using code points, e.g. U&'d\0061t\+000061' + (Peter) +

  • Reject \000 in string literals and COPY data + (Tom) +

    Previously, this was accepted but had the effect of terminating + the string contents. +

  • Improve the parser's ability to report error locations (Tom) +

    An error location is now reported for many semantic errors, + such as mismatched datatypes, that previously could not be localized. +

E.39.3.3.1. TRUNCATE

  • Support statement-level ON TRUNCATE triggers (Simon) +

  • Add RESTART/CONTINUE IDENTITY options + for TRUNCATE TABLE + (Zoltan Boszormenyi) +

    The start value of a sequence can be changed by ALTER + SEQUENCE START WITH. +

  • Allow TRUNCATE tab1, tab1 to succeed (Bruce) +

  • Add a separate TRUNCATE permission (Robert Haas) +

E.39.3.3.2. EXPLAIN

  • Make EXPLAIN VERBOSE show the output columns of each + plan node (Tom) +

    Previously EXPLAIN VERBOSE output an internal + representation of the query plan. (That behavior is now + available via debug_print_plan.) +

  • Make EXPLAIN identify subplans and initplans with + individual labels (Tom) +

  • Make EXPLAIN honor debug_print_plan (Tom) +

  • Allow EXPLAIN on CREATE TABLE AS (Peter) +

E.39.3.3.3. LIMIT/OFFSET

  • Allow sub-selects in LIMIT and OFFSET (Tom) +

  • Add SQL-standard syntax for + LIMIT/OFFSET capabilities (Peter) +

    To wit, + OFFSET num {ROW|ROWS} FETCH {FIRST|NEXT} [num] {ROW|ROWS} + ONLY. +

E.39.3.4. Object Manipulation

  • Add support for column-level privileges (Stephen Frost, KaiGai + Kohei) +

  • Refactor multi-object DROP operations to reduce the + need for CASCADE (Alex Hunsaker) +

    For example, if table B has a dependency on table + A, the command DROP TABLE A, B no longer + requires the CASCADE option. +

  • Fix various problems with concurrent DROP commands + by ensuring that locks are taken before we begin to drop dependencies + of an object (Tom) +

  • Improve reporting of dependencies during DROP + commands (Tom) +

  • Add WITH [NO] DATA clause to CREATE TABLE + AS, per the SQL standard (Peter, Tom) +

  • Add support for user-defined I/O conversion casts (Heikki) +

  • Allow CREATE AGGREGATE to use an internal + transition datatype (Tom) +

  • Add LIKE clause to CREATE TYPE (Tom) +

    This simplifies creation of data types that use the same internal + representation as an existing type. +

  • Allow specification of the type category and "preferred" + status for user-defined base types (Tom) +

    This allows more control over the coercion behavior of user-defined + types. +

  • Allow CREATE OR REPLACE VIEW to add columns to the + end of a view (Robert Haas) +

E.39.3.4.1. ALTER

  • Add ALTER TYPE RENAME (Petr Jelinek) +

  • Add ALTER SEQUENCE ... RESTART (with no parameter) to + reset a sequence to its initial value (Zoltan Boszormenyi) +

  • Modify the ALTER TABLE syntax to allow all reasonable + combinations for tables, indexes, sequences, and views (Tom) +

    This change allows the following new syntaxes: + +

    • ALTER SEQUENCE OWNER TO +

    • ALTER VIEW ALTER COLUMN SET/DROP DEFAULT +

    • ALTER VIEW OWNER TO +

    • ALTER VIEW SET SCHEMA +

    + + There is no actual new functionality here, but formerly + you had to say ALTER TABLE to do these things, + which was confusing. +

  • Add support for the syntax ALTER TABLE ... ALTER COLUMN + ... SET DATA TYPE (Peter) +

    This is SQL-standard syntax for functionality that + was already supported. +

  • Make ALTER TABLE SET WITHOUT OIDS rewrite the table + to physically remove OID values (Tom) +

    Also, add ALTER TABLE SET WITH OIDS to rewrite the + table to add OIDs. +

E.39.3.4.2. Database Manipulation

  • Improve reporting of + CREATE/DROP/RENAME DATABASE + failure when uncommitted prepared transactions are the cause + (Tom) +

  • Make LC_COLLATE and LC_CTYPE into + per-database settings (Radek Strnad, Heikki) +

    This makes collation similar to encoding, which was always + configurable per database. +

  • Improve checks that the database encoding, collation + (LC_COLLATE), and character classes + (LC_CTYPE) match (Heikki, Tom) +

    Note in particular that a new database's encoding and locale + settings can be changed only when copying from template0. + This prevents possibly copying data that doesn't match the settings. +

  • Add ALTER DATABASE SET TABLESPACE to move a database + to a new tablespace (Guillaume Lelarge, Bernd Helmle) +

E.39.3.5. Utility Operations

  • Add a VERBOSE option to the CLUSTER command and + clusterdb (Jim Cox) +

  • Decrease memory requirements for recording pending trigger + events (Tom) +

E.39.3.5.1. Indexes

  • Dramatically improve the speed of building and accessing hash + indexes (Tom Raney, Shreya Bhargava) +

    This allows hash indexes to be sometimes faster than btree + indexes. However, hash indexes are still not crash-safe. +

  • Make hash indexes store only the hash code, not the full value of + the indexed column (Xiao Meng) +

    This greatly reduces the size of hash indexes for long indexed + values, improving performance. +

  • Implement fast update option for GIN indexes (Teodor, Oleg) +

    This option greatly improves update speed at a small penalty in search + speed. +

  • xxx_pattern_ops indexes can now be used for simple + equality comparisons, not only for LIKE (Tom) +

E.39.3.5.2. Full Text Indexes

  • Remove the requirement to use @@@ when doing + GIN weighted lookups on full text indexes (Tom, Teodor) +

    The normal @@ text search operator can be used + instead. +

  • Add an optimizer selectivity function for @@ text + search operations (Jan Urbanski) +

  • Allow prefix matching in full text searches (Teodor Sigaev, + Oleg Bartunov) +

  • Support multi-column GIN indexes (Teodor Sigaev) +

  • Improve support for Nepali language and Devanagari alphabet (Teodor) +

E.39.3.5.3. VACUUM

  • Track free space in separate per-relation "fork" files (Heikki) +

    Free space discovered by VACUUM is now recorded in + *_fsm files, rather than in a fixed-sized shared memory + area. The max_fsm_pages and max_fsm_relations + settings have been removed, greatly simplifying administration of + free space management. +

  • Add a visibility map to track pages that do not require + vacuuming (Heikki) +

    This allows VACUUM to avoid scanning all of + a table when only a portion of the table needs vacuuming. + The visibility map is stored in per-relation "fork" files. +

  • Add vacuum_freeze_table_age parameter to control + when VACUUM should ignore the visibility map and + do a full table scan to freeze tuples (Heikki) +

  • Track transaction snapshots more carefully (Alvaro) +

    This improves VACUUM's ability to reclaim space + in the presence of long-running transactions. +

  • Add ability to specify per-relation autovacuum and TOAST + parameters in CREATE TABLE (Alvaro, Euler Taveira de + Oliveira) +

    Autovacuum options used to be stored in a system table. +

  • Add --freeze option to vacuumdb + (Bruce) +

E.39.3.6. Data Types

  • Add a CaseSensitive option for text search synonym + dictionaries (Simon) +

  • Improve the precision of NUMERIC division (Tom) +

  • Add basic arithmetic operators for int2 with int8 + (Tom) +

    This eliminates the need for explicit casting in some situations. +

  • Allow UUID input to accept an optional hyphen after + every fourth digit (Robert Haas) +

  • Allow on/off as input for the boolean data type + (Itagaki Takahiro) +

  • Allow spaces around NaN in the input string for + type numeric (Sam Mason) +

E.39.3.6.1. Temporal Data Types

  • Reject year 0 BC and years 000 and + 0000 (Tom) +

    Previously these were interpreted as 1 BC. + (Note: years 0 and 00 are still assumed to be + the year 2000.) +

  • Include SGT (Singapore time) in the default list of + known time zone abbreviations (Tom) +

  • Support infinity and -infinity as + values of type date (Tom) +

  • Make parsing of interval literals more standard-compliant + (Tom, Ron Mayer) +

    For example, INTERVAL '1' YEAR now does what it's + supposed to. +

  • Allow interval fractional-seconds precision to be specified + after the second keyword, for SQL standard + compliance (Tom) +

    Formerly the precision had to be specified after the keyword + interval. (For backwards compatibility, this syntax is still + supported, though deprecated.) Data type definitions will now be + output using the standard format. +

  • Support the IS0 8601 interval syntax (Ron + Mayer, Kevin Grittner) +

    For example, INTERVAL 'P1Y2M3DT4H5M6.7S' is now + supported. +

  • Add IntervalStyle parameter + which controls how interval values are output (Ron Mayer) +

    Valid values are: postgres, postgres_verbose, + sql_standard, iso_8601. This setting also + controls the handling of negative interval input when only + some fields have positive/negative designations. +

  • Improve consistency of handling of fractional seconds in + timestamp and interval output (Ron Mayer) +

E.39.3.6.2. Arrays

  • Improve the handling of casts applied to ARRAY[] + constructs, such as ARRAY[...]::integer[] + (Brendan Jurd) +

    Formerly PostgreSQL attempted to determine a data type + for the ARRAY[] construct without reference to the ensuing + cast. This could fail unnecessarily in many cases, in particular when + the ARRAY[] construct was empty or contained only + ambiguous entries such as NULL. Now the cast is consulted + to determine the type that the array elements must be. +

  • Make SQL-syntax ARRAY dimensions optional + to match the SQL standard (Peter) +

  • Add array_ndims() to return the number + of dimensions of an array (Robert Haas) +

  • Add array_length() to return the length + of an array for a specified dimension (Jim Nasby, Robert + Haas, Peter Eisentraut) +

  • Add aggregate function array_agg(), which + returns all aggregated values as a single array (Robert Haas, + Jeff Davis, Peter) +

  • Add unnest(), which converts an array to + individual row values (Tom) +

    This is the opposite of array_agg(). +

  • Add array_fill() to create arrays initialized with + a value (Pavel Stehule) +

  • Add generate_subscripts() to simplify generating + the range of an array's subscripts (Pavel Stehule) +

E.39.3.6.3. Wide-Value Storage (TOAST)

  • Consider TOAST compression on values as short as + 32 bytes (previously 256 bytes) (Greg Stark) +

  • Require 25% minimum space savings before using TOAST + compression (previously 20% for small values and any-savings-at-all + for large values) (Greg) +

  • Improve TOAST heuristics for rows that have a mix of large + and small toastable fields, so that we prefer to push large values out + of line and don't compress small values unnecessarily (Greg, Tom) +

E.39.3.7. Functions

  • Document that setseed() allows values from + -1 to 1 (not just 0 to + 1), and enforce the valid range (Kris Jurka) +

  • Add server-side function lo_import(filename, oid) + (Tatsuo) +

  • Add quote_nullable(), which behaves like + quote_literal() but returns the string NULL for + a null argument (Brendan Jurd) +

  • Improve full text search headline() function to + allow extracting several fragments of text (Sushant Sinha) +

  • Add suppress_redundant_updates_trigger() trigger + function to avoid overhead for non-data-changing updates (Andrew) +

  • Add div(numeric, numeric) to perform numeric + division without rounding (Tom) +

  • Add timestamp and timestamptz versions of + generate_series() (Hitoshi Harada) +

E.39.3.7.1. Object Information Functions

  • Implement current_query() for use by functions + that need to know the currently running query (Tomas Doran) +

  • Add pg_get_keywords() to return a list of the + parser keywords (Dave Page) +

  • Add pg_get_functiondef() to see a function's + definition (Abhijit Menon-Sen) +

  • Allow the second argument of pg_get_expr() to be zero + when deparsing an expression that does not contain variables (Tom) +

  • Modify pg_relation_size() to use regclass + (Heikki) +

    pg_relation_size(data_type_name) no longer works. +

  • Add boot_val and reset_val columns to + pg_settings output (Greg Smith) +

  • Add source file name and line number columns to + pg_settings output for variables set in a configuration + file (Magnus, Alvaro) +

    For security reasons, these columns are only visible to superusers. +

  • Add support for CURRENT_CATALOG, + CURRENT_SCHEMA, SET CATALOG, SET + SCHEMA (Peter) +

    These provide SQL-standard syntax for existing features. +

  • Add pg_typeof() which returns the data type + of any value (Brendan Jurd) +

  • Make version() return information about whether + the server is a 32- or 64-bit binary (Bruce) +

  • Fix the behavior of information schema columns + is_insertable_into and is_updatable to + be consistent (Peter) +

  • Improve the behavior of information schema + datetime_precision columns (Peter) +

    These columns now show zero for date columns, and 6 + (the default precision) for time, timestamp, and + interval without a declared precision, rather than showing + null as formerly. +

  • Convert remaining builtin set-returning functions to use + OUT parameters (Jaime Casanova) +

    This makes it possible to call these functions without specifying + a column list: pg_show_all_settings(), + pg_lock_status(), pg_prepared_xact(), + pg_prepared_statement(), pg_cursor() +

  • Make pg_*_is_visible() and + has_*_privilege() functions return NULL + for invalid OIDs, rather than reporting an error (Tom) +

  • Extend has_*_privilege() functions to allow inquiring + about the OR of multiple privileges in one call (Stephen + Frost, Tom) +

  • Add has_column_privilege() and + has_any_column_privilege() functions (Stephen + Frost, Tom) +

E.39.3.7.2. Function Creation

  • Support variadic functions (functions with a variable number + of arguments) (Pavel Stehule) +

    Only trailing arguments can be optional, and they all must be + of the same data type. +

  • Support default values for function arguments (Pavel Stehule) +

  • Add CREATE FUNCTION ... RETURNS TABLE clause (Pavel + Stehule) +

  • Allow SQL-language functions to return the output + of an INSERT/UPDATE/DELETE + RETURNING clause (Tom) +

E.39.3.7.3. PL/pgSQL Server-Side Language

  • Support EXECUTE USING for easier insertion of data + values into a dynamic query string (Pavel Stehule) +

  • Allow looping over the results of a cursor using a FOR + loop (Pavel Stehule) +

  • Support RETURN QUERY EXECUTE (Pavel + Stehule) +

  • Improve the RAISE command (Pavel Stehule) + +

    • Support DETAIL and HINT fields +

    • Support specification of the SQLSTATE error code +

    • Support an exception name parameter +

    • Allow RAISE without parameters in an exception + block to re-throw the current error +

    +

  • Allow specification of SQLSTATE codes + in EXCEPTION lists (Pavel Stehule) +

    This is useful for handling custom SQLSTATE codes. +

  • Support the CASE statement (Pavel Stehule) +

  • Make RETURN QUERY set the special FOUND and + GET DIAGNOSTICS ROW_COUNT variables + (Pavel Stehule) +

  • Make FETCH and MOVE set the + GET DIAGNOSTICS ROW_COUNT variable + (Andrew Gierth) +

  • Make EXIT without a label always exit the innermost + loop (Tom) +

    Formerly, if there were a BEGIN block more closely nested + than any loop, it would exit that block instead. The new behavior + matches Oracle(TM) and is also what was previously stated by our own + documentation. +

  • Make processing of string literals and nested block comments + match the main SQL parser's processing (Tom) +

    In particular, the format string in RAISE now works + the same as any other string literal, including being subject + to standard_conforming_strings. This change also + fixes other cases in which valid commands would fail when + standard_conforming_strings is on. +

  • Avoid memory leakage when the same function is called at varying + exception-block nesting depths (Tom) +

E.39.3.8. Client Applications

  • Fix pg_ctl restart to preserve command-line arguments + (Bruce) +

  • Add -w/--no-password option that + prevents password prompting in all utilities that have a + -W/--password option (Peter) +

  • Remove -q (quiet) option of createdb, + createuser, dropdb, + dropuser (Peter) +

    These options have had no effect since PostgreSQL + 8.3. +

E.39.3.8.1. psql

  • Remove verbose startup banner; now just suggest help + (Joshua Drake) +

  • Make help show common backslash commands (Greg + Sabino Mullane) +

  • Add \pset format wrapped mode to wrap output to the + screen width, or file/pipe output too if \pset columns + is set (Bryce Nesbitt) +

  • Allow all supported spellings of boolean values in \pset, + rather than just on and off (Bruce) +

    Formerly, any string other than "off" was silently taken + to mean true. psql will now complain + about unrecognized spellings (but still take them as true). +

  • Use the pager for wide output (Bruce) +

  • Require a space between a one-letter backslash command and its first + argument (Bernd Helmle) +

    This removes a historical source of ambiguity. +

  • Improve tab completion support for schema-qualified and + quoted identifiers (Greg Sabino Mullane) +

  • Add optional on/off argument for + \timing (David Fetter) +

  • Display access control rights on multiple lines (Brendan + Jurd, Andreas Scherbaum) +

  • Make \l show database access privileges (Andrew Gilligan) +

  • Make \l+ show database sizes, if permissions + allow (Andrew Gilligan) +

  • Add the \ef command to edit function definitions + (Abhijit Menon-Sen) +

E.39.3.8.2. psql \d* commands

  • Make \d* commands that do not have a pattern argument + show system objects only if the S modifier is specified + (Greg Sabino Mullane, Bruce) +

    The former behavior was inconsistent across different variants + of \d, and in most cases it provided no easy way to see + just user objects. +

  • Improve \d* commands to work with older + PostgreSQL server versions (back to 7.4), + not only the current server version + (Guillaume Lelarge) +

  • Make \d show foreign-key constraints that reference + the selected table (Kenneth D'Souza) +

  • Make \d on a sequence show its column values + (Euler Taveira de Oliveira) +

  • Add column storage type and other relation options to the + \d+ display (Gregory Stark, Euler Taveira de + Oliveira) +

  • Show relation size in \dt+ output (Dickson S. + Guedes) +

  • Show the possible values of enum types in \dT+ + (David Fetter) +

  • Allow \dC to accept a wildcard pattern, which matches + either datatype involved in the cast (Tom) +

  • Add a function type column to \df's output, and add + options to list only selected types of functions (David Fetter) +

  • Make \df not hide functions that take or return + type cstring (Tom) +

    Previously, such functions were hidden because most of them are + datatype I/O functions, which were deemed uninteresting. The new + policy about hiding system functions by default makes this wart + unnecessary. +

E.39.3.8.3. pg_dump

  • Add a --no-tablespaces option to + pg_dump/pg_dumpall/pg_restore + so that dumps can be restored to clusters that have non-matching + tablespace layouts (Gavin Roy) +

  • Remove -d and -D options from + pg_dump and pg_dumpall (Tom) +

    These options were too frequently confused with the option to + select a database name in other PostgreSQL + client applications. The functionality is still available, + but you must now spell out the long option name + --inserts or --column-inserts. +

  • Remove -i/--ignore-version option from + pg_dump and pg_dumpall (Tom) +

    Use of this option does not throw an error, but it has no + effect. This option was removed because the version checks + are necessary for safety. +

  • Disable statement_timeout during dump and restore + (Joshua Drake) +

  • Add pg_dump/pg_dumpall option + --lock-wait-timeout (David Gould) +

    This allows dumps to fail if unable to acquire a shared lock + within the specified amount of time. +

  • Reorder pg_dump --data-only output + to dump tables referenced by foreign keys before + the referencing tables (Tom) +

    This allows data loads when foreign keys are already present. + If circular references make a safe ordering impossible, a + NOTICE is issued. +

  • Allow pg_dump, pg_dumpall, and + pg_restore to use a specified role (Benedek + László) +

  • Allow pg_restore to use multiple concurrent + connections to do the restore (Andrew) +

    The number of concurrent connections is controlled by the option + --jobs. This is supported only for custom-format archives. +

E.39.3.9. Programming Tools

E.39.3.9.1. libpq

  • Allow the OID to be specified when importing a large + object, via new function lo_import_with_oid() (Tatsuo) +

  • Add "events" support (Andrew Chernow, Merlin Moncure) +

    This adds the ability to register callbacks to manage private + data associated with PGconn and PGresult + objects. +

  • Improve error handling to allow the return of multiple + error messages as multi-line error reports (Magnus) +

  • Make PQexecParams() and related functions return + PGRES_EMPTY_QUERY for an empty query (Tom) +

    They previously returned PGRES_COMMAND_OK. +

  • Document how to avoid the overhead of WSACleanup() + on Windows (Andrew Chernow) +

  • Do not rely on Kerberos tickets to determine the default database + username (Magnus) +

    Previously, a Kerberos-capable build of libpq would use the + principal name from any available Kerberos ticket as default + database username, even if the connection wasn't using Kerberos + authentication. This was deemed inconsistent and confusing. + The default username is now determined the same way with or + without Kerberos. Note however that the database username must still + match the ticket when Kerberos authentication is used. +

E.39.3.9.2. libpq SSL (Secure Sockets Layer) + support

  • Fix certificate validation for SSL connections + (Magnus) +

    libpq now supports verifying both the certificate + and the name of the server when making SSL + connections. If a root certificate is not available to use for + verification, SSL connections will fail. The + sslmode parameter is used to enable certificate + verification and set the level of checking. + The default is still not to do any verification, allowing connections + to SSL-enabled servers without requiring a root certificate on the + client. +

  • Support wildcard server certificates (Magnus) +

    If a certificate CN starts with *, it will + be treated as a wildcard when matching the hostname, allowing the + use of the same certificate for multiple servers. +

  • Allow the file locations for client certificates to be specified + (Mark Woodward, Alvaro, Magnus) +

  • Add a PQinitOpenSSL function to allow greater control + over OpenSSL/libcrypto initialization (Andrew Chernow) +

  • Make libpq unregister its OpenSSL + callbacks when no database connections remain open + (Bruce, Magnus, Russell Smith) +

    This is required for applications that unload the libpq library, + otherwise invalid OpenSSL callbacks will remain. +

E.39.3.9.3. ecpg

  • Add localization support for messages (Euler Taveira de + Oliveira) +

  • ecpg parser is now automatically generated from the server + parser (Michael) +

    Previously the ecpg parser was hand-maintained. +

E.39.3.9.4. Server Programming Interface (SPI)

  • Add support for single-use plans with out-of-line + parameters (Tom) +

  • Add new SPI_OK_REWRITTEN return code for + SPI_execute() (Heikki) +

    This is used when a command is rewritten to another type of + command. +

  • Remove unnecessary inclusions from executor/spi.h (Tom) +

    SPI-using modules might need to add some #include + lines if they were depending on spi.h to include + things for them. +

E.39.3.10. Build Options

  • Update build system to use Autoconf 2.61 (Peter) +

  • Require GNU bison for source code builds (Peter) +

    This has effectively been required for several years, but now there + is no infrastructure claiming to support other parser tools. +

  • Add pg_config --htmldir option + (Peter) +

  • Pass float4 by value inside the server (Zoltan + Boszormenyi) +

    Add configure option + --disable-float4-byval to use the old behavior. + External C functions that use old-style (version 0) call convention + and pass or return float4 values will be broken by this + change, so you may need the configure option if you + have such functions and don't want to update them. +

  • Pass float8, int8, and related datatypes + by value inside the server on 64-bit platforms (Zoltan Boszormenyi) +

    Add configure option + --disable-float8-byval to use the old behavior. + As above, this change might break old-style external C functions. +

  • Add configure options --with-segsize, + --with-blocksize, --with-wal-blocksize, + --with-wal-segsize (Zdenek Kotala, Tom) +

    This simplifies build-time control over several constants that + previously could only be changed by editing + pg_config_manual.h. +

  • Allow threaded builds on Solaris 2.5 (Bruce) +

  • Use the system's getopt_long() on Solaris + (Zdenek Kotala, Tom) +

    This makes option processing more consistent with what Solaris users + expect. +

  • Add support for the Sun Studio compiler on + Linux (Julius Stroffek) +

  • Append the major version number to the backend gettext + domain, and the soname major version number to + libraries' gettext domain (Peter) +

    This simplifies parallel installations of multiple versions. +

  • Add support for code coverage testing with gcov + (Michelle Caisse) +

  • Allow out-of-tree builds on Mingw and + Cygwin (Richard Evans) +

  • Fix the use of Mingw as a cross-compiling source + platform (Peter) +

E.39.3.11. Source Code

  • Support 64-bit time zone data files (Heikki) +

    This adds support for daylight saving time (DST) + calculations beyond the year 2038. +

  • Deprecate use of platform's time_t data type (Tom) +

    Some platforms have migrated to 64-bit time_t, some have + not, and Windows can't make up its mind what it's doing. Define + pg_time_t to have the same meaning as time_t, + but always be 64 bits (unless the platform has no 64-bit integer type), + and use that type in all module APIs and on-disk data formats. +

  • Fix bug in handling of the time zone database when cross-compiling + (Richard Evans) +

  • Link backend object files in one step, rather than in stages + (Peter) +

  • Improve gettext support to allow better translation + of plurals (Peter) +

  • Add message translation support to the PL languages (Alvaro, Peter) +

  • Add more DTrace probes (Robert Lor) +

  • Enable DTrace support on Mac OS X + Leopard and other non-Solaris platforms (Robert Lor) +

  • Simplify and standardize conversions between C strings and + text datums, by providing common functions for the purpose + (Brendan Jurd, Tom) +

  • Clean up the include/catalog/ header files so that + frontend programs can include them without including + postgres.h + (Zdenek Kotala) +

  • Make name char-aligned, and suppress zero-padding of + name entries in indexes (Tom) +

  • Recover better if dynamically-loaded code executes exit() + (Tom) +

  • Add a hook to let plug-ins monitor the executor (Itagaki + Takahiro) +

  • Add a hook to allow the planner's statistics lookup behavior to + be overridden (Simon Riggs) +

  • Add shmem_startup_hook() for custom shared memory + requirements (Tom) +

  • Replace the index access method amgetmulti entry point + with amgetbitmap, and extend the API for + amgettuple to support run-time determination of + operator lossiness (Heikki, Tom, Teodor) +

    The API for GIN and GiST opclass consistent functions + has been extended as well. +

  • Add support for partial-match searches in GIN indexes + (Teodor Sigaev, Oleg Bartunov) +

  • Replace pg_class column reltriggers + with boolean relhastriggers (Simon) +

    Also remove unused pg_class columns + relukeys, relfkeys, and + relrefs. +

  • Add a relistemp column to pg_class + to ease identification of temporary tables (Tom) +

  • Move platform FAQs into the main documentation + (Peter) +

  • Prevent parser input files from being built with any conflicts + (Peter) +

  • Add support for the KOI8U (Ukrainian) encoding + (Peter) +

  • Add Japanese message translations (Japan PostgreSQL Users Group) +

    This used to be maintained as a separate project. +

  • Fix problem when setting LC_MESSAGES on + MSVC-built systems (Hiroshi Inoue, Hiroshi + Saito, Magnus) +

E.39.3.12. Contrib

  • Add contrib/auto_explain to automatically run + EXPLAIN on queries exceeding a specified duration + (Itagaki Takahiro, Tom) +

  • Add contrib/btree_gin to allow GIN indexes to + handle more datatypes (Oleg, Teodor) +

  • Add contrib/citext to provide a case-insensitive, + multibyte-aware text data type (David Wheeler) +

  • Add contrib/pg_stat_statements for server-wide + tracking of statement execution statistics (Itagaki Takahiro) +

  • Add duration and query mode options to contrib/pgbench + (Itagaki Takahiro) +

  • Make contrib/pgbench use table names + pgbench_accounts, pgbench_branches, + pgbench_history, and pgbench_tellers, + rather than just accounts, branches, + history, and tellers (Tom) +

    This is to reduce the risk of accidentally destroying real data + by running pgbench. +

  • Fix contrib/pgstattuple to handle tables and + indexes with over 2 billion pages (Tatsuhito Kasahara) +

  • In contrib/fuzzystrmatch, add a version of the + Levenshtein string-distance function that allows the user to + specify the costs of insertion, deletion, and substitution + (Volkan Yazici) +

  • Make contrib/ltree support multibyte encodings + (laser) +

  • Enable contrib/dblink to use connection information + stored in the SQL/MED catalogs (Joe Conway) +

  • Improve contrib/dblink's reporting of errors from + the remote server (Joe Conway) +

  • Make contrib/dblink set client_encoding + to match the local database's encoding (Joe Conway) +

    This prevents encoding problems when communicating with a remote + database that uses a different encoding. +

  • Make sure contrib/dblink uses a password supplied + by the user, and not accidentally taken from the server's + .pgpass file (Joe Conway) +

    This is a minor security enhancement. +

  • Add fsm_page_contents() + to contrib/pageinspect (Heikki) +

  • Modify get_raw_page() to support free space map + (*_fsm) files. Also update + contrib/pg_freespacemap. +

  • Add support for multibyte encodings to contrib/pg_trgm + (Teodor) +

  • Rewrite contrib/intagg to use new + functions array_agg() and unnest() + (Tom) +

  • Make contrib/pg_standby recover all available WAL before + failover (Fujii Masao, Simon, Heikki) +

    To make this work safely, you now need to set the new + recovery_end_command option in recovery.conf + to clean up the trigger file after failover. pg_standby + will no longer remove the trigger file itself. +

  • contrib/pg_standby's -l option is now a no-op, + because it is unsafe to use a symlink (Simon) +


PrevHomeNext
Release 8.4.1UpRelease 8.3.22
\ No newline at end of file diff --git a/doc/src/sgml/html/release-9-0-1.html b/doc/src/sgml/html/release-9-0-1.html new file mode 100644 index 000000000..223b498d0 --- /dev/null +++ b/doc/src/sgml/html/release-9-0-1.html @@ -0,0 +1,314 @@ + +Release 9.0.1

E.22. Release 9.0.1

Release Date: 2010-10-04

This release contains a variety of fixes from 9.0.0. + For information about new features in the 9.0 major release, see + Section E.23. +

E.22.1. Migration to Version 9.0.1

A dump/restore is not required for those running 9.0.X. +

E.22.2. Changes

  • Use a separate interpreter for each calling SQL userid in PL/Perl and + PL/Tcl (Tom Lane) +

    This change prevents security problems that can be caused by subverting + Perl or Tcl code that will be executed later in the same session under + another SQL user identity (for example, within a SECURITY + DEFINER function). Most scripting languages offer numerous ways that + that might be done, such as redefining standard functions or operators + called by the target function. Without this change, any SQL user with + Perl or Tcl language usage rights can do essentially anything with the + SQL privileges of the target function's owner. +

    The cost of this change is that intentional communication among Perl + and Tcl functions becomes more difficult. To provide an escape hatch, + PL/PerlU and PL/TclU functions continue to use only one interpreter + per session. This is not considered a security issue since all such + functions execute at the trust level of a database superuser already. +

    It is likely that third-party procedural languages that claim to offer + trusted execution have similar security issues. We advise contacting + the authors of any PL you are depending on for security-critical + purposes. +

    Our thanks to Tim Bunce for pointing out this issue (CVE-2010-3433). +

  • Improve pg_get_expr() security fix so that the function + can still be used on the output of a sub-select (Tom Lane) +

  • Fix incorrect placement of placeholder evaluation (Tom Lane) +

    This bug could result in query outputs being non-null when they + should be null, in cases where the inner side of an outer join + is a sub-select with non-strict expressions in its output list. +

  • Fix join removal's handling of placeholder expressions (Tom Lane) +

  • Fix possible duplicate scans of UNION ALL member relations + (Tom Lane) +

  • Prevent infinite loop in ProcessIncomingNotify() after unlistening + (Jeff Davis) +

  • Prevent show_session_authorization() from crashing within autovacuum + processes (Tom Lane) +

  • Re-allow input of Julian dates prior to 0001-01-01 AD (Tom Lane) +

    Input such as 'J100000'::date worked before 8.4, + but was unintentionally broken by added error-checking. +

  • Make psql recognize DISCARD ALL as a command that should + not be encased in a transaction block in autocommit-off mode + (Itagaki Takahiro) +

  • Update build infrastructure and documentation to reflect the source code + repository's move from CVS to Git (Magnus Hagander and others) +


PrevHomeNext
Release 9.0.2UpRelease 9.0
\ No newline at end of file diff --git a/doc/src/sgml/html/release-9-0-10.html b/doc/src/sgml/html/release-9-0-10.html new file mode 100644 index 000000000..f7b7cae1f --- /dev/null +++ b/doc/src/sgml/html/release-9-0-10.html @@ -0,0 +1,345 @@ + +Release 9.0.10

E.13. Release 9.0.10

Release Date: 2012-09-24

This release contains a variety of fixes from 9.0.9. + For information about new features in the 9.0 major release, see + Section E.23. +

E.13.1. Migration to Version 9.0.10

A dump/restore is not required for those running 9.0.X. +

However, if you are upgrading from a version earlier than 9.0.6, + see the release notes for 9.0.6. +

E.13.2. Changes

  • Fix planner's assignment of executor parameters, and fix executor's + rescan logic for CTE plan nodes (Tom Lane) +

    These errors could result in wrong answers from queries that scan the + same WITH subquery multiple times. +

  • Improve page-splitting decisions in GiST indexes (Alexander Korotkov, + Robert Haas, Tom Lane) +

    Multi-column GiST indexes might suffer unexpected bloat due to this + error. +

  • Fix cascading privilege revoke to stop if privileges are still held + (Tom Lane) +

    If we revoke a grant option from some role X, but + X still holds that option via a grant from someone + else, we should not recursively revoke the corresponding privilege + from role(s) Y that X had granted it + to. +

  • Improve error messages for Hot Standby misconfiguration errors + (Gurjeet Singh) +

  • Fix handling of SIGFPE when PL/Perl is in use (Andres Freund) +

    Perl resets the process's SIGFPE handler to + SIG_IGN, which could result in crashes later on. Restore + the normal Postgres signal handler after initializing PL/Perl. +

  • Prevent PL/Perl from crashing if a recursive PL/Perl function is + redefined while being executed (Tom Lane) +

  • Work around possible misoptimization in PL/Perl (Tom Lane) +

    Some Linux distributions contain an incorrect version of + pthread.h that results in incorrect compiled code in + PL/Perl, leading to crashes if a PL/Perl function calls another one + that throws an error. +

  • Fix pg_upgrade's handling of line endings on Windows + (Andrew Dunstan) +

    Previously, pg_upgrade might add or remove carriage + returns in places such as function bodies. +

  • On Windows, make pg_upgrade use backslash path + separators in the scripts it emits (Andrew Dunstan) +

  • Update time zone data files to tzdata release 2012f + for DST law changes in Fiji +


PrevHomeNext
Release 9.0.11UpRelease 9.0.9
\ No newline at end of file diff --git a/doc/src/sgml/html/release-9-0-11.html b/doc/src/sgml/html/release-9-0-11.html new file mode 100644 index 000000000..8fafdb9d2 --- /dev/null +++ b/doc/src/sgml/html/release-9-0-11.html @@ -0,0 +1,661 @@ + +Release 9.0.11

E.12. Release 9.0.11

Release Date: 2012-12-06

This release contains a variety of fixes from 9.0.10. + For information about new features in the 9.0 major release, see + Section E.23. +

E.12.1. Migration to Version 9.0.11

A dump/restore is not required for those running 9.0.X. +

However, if you are upgrading from a version earlier than 9.0.6, + see the release notes for 9.0.6. +

E.12.2. Changes

  • Fix multiple bugs associated with CREATE INDEX + CONCURRENTLY (Andres Freund, Tom Lane) +

    Fix CREATE INDEX CONCURRENTLY to use + in-place updates when changing the state of an index's + pg_index row. This prevents race conditions that could + cause concurrent sessions to miss updating the target index, thus + resulting in corrupt concurrently-created indexes. +

    Also, fix various other operations to ensure that they ignore + invalid indexes resulting from a failed CREATE INDEX + CONCURRENTLY command. The most important of these is + VACUUM, because an auto-vacuum could easily be launched + on the table before corrective action can be taken to fix or remove + the invalid index. +

  • Fix buffer locking during WAL replay (Tom Lane) +

    The WAL replay code was insufficiently careful about locking buffers + when replaying WAL records that affect more than one page. This could + result in hot standby queries transiently seeing inconsistent states, + resulting in wrong answers or unexpected failures. +

  • Fix an error in WAL generation logic for GIN indexes (Tom Lane) +

    This could result in index corruption, if a torn-page failure occurred. +

  • Properly remove startup process's virtual XID lock when promoting a + hot standby server to normal running (Simon Riggs) +

    This oversight could prevent subsequent execution of certain + operations such as CREATE INDEX CONCURRENTLY. +

  • Avoid bogus "out-of-sequence timeline ID" errors in standby + mode (Heikki Linnakangas) +

  • Prevent the postmaster from launching new child processes after it's + received a shutdown signal (Tom Lane) +

    This mistake could result in shutdown taking longer than it should, or + even never completing at all without additional user action. +

  • Avoid corruption of internal hash tables when out of memory + (Hitoshi Harada) +

  • Fix planning of non-strict equivalence clauses above outer joins + (Tom Lane) +

    The planner could derive incorrect constraints from a clause equating + a non-strict construct to something else, for example + WHERE COALESCE(foo, 0) = 0 + when foo is coming from the nullable side of an outer join. +

  • Improve planner's ability to prove exclusion constraints from + equivalence classes (Tom Lane) +

  • Fix partial-row matching in hashed subplans to handle cross-type cases + correctly (Tom Lane) +

    This affects multicolumn NOT IN subplans, such as + WHERE (a, b) NOT IN (SELECT x, y FROM ...) + when for instance b and y are int4 + and int8 respectively. This mistake led to wrong answers + or crashes depending on the specific datatypes involved. +

  • Acquire buffer lock when re-fetching the old tuple for an + AFTER ROW UPDATE/DELETE trigger (Andres Freund) +

    In very unusual circumstances, this oversight could result in passing + incorrect data to the precheck logic for a foreign-key enforcement + trigger. That could result in a crash, or in an incorrect decision + about whether to fire the trigger. +

  • Fix ALTER COLUMN TYPE to handle inherited check + constraints properly (Pavan Deolasee) +

    This worked correctly in pre-8.4 releases, and now works correctly + in 8.4 and later. +

  • Fix REASSIGN OWNED to handle grants on tablespaces + (Álvaro Herrera) +

  • Ignore incorrect pg_attribute entries for system + columns for views (Tom Lane) +

    Views do not have any system columns. However, we forgot to + remove such entries when converting a table to a view. That's fixed + properly for 9.3 and later, but in previous branches we need to defend + against existing mis-converted views. +

  • Fix rule printing to dump INSERT INTO table + DEFAULT VALUES correctly (Tom Lane) +

  • Guard against stack overflow when there are too many + UNION/INTERSECT/EXCEPT clauses + in a query (Tom Lane) +

  • Prevent platform-dependent failures when dividing the minimum possible + integer value by -1 (Xi Wang, Tom Lane) +

  • Fix possible access past end of string in date parsing + (Hitoshi Harada) +

  • Fix failure to advance XID epoch if XID wraparound happens during a + checkpoint and wal_level is hot_standby + (Tom Lane, Andres Freund) +

    While this mistake had no particular impact on + PostgreSQL itself, it was bad for + applications that rely on txid_current() and related + functions: the TXID value would appear to go backwards. +

  • Produce an understandable error message if the length of the path name + for a Unix-domain socket exceeds the platform-specific limit + (Tom Lane, Andrew Dunstan) +

    Formerly, this would result in something quite unhelpful, such as + "Non-recoverable failure in name resolution". +

  • Fix memory leaks when sending composite column values to the client + (Tom Lane) +

  • Make pg_ctl more robust about reading the + postmaster.pid file (Heikki Linnakangas) +

    Fix race conditions and possible file descriptor leakage. +

  • Fix possible crash in psql if incorrectly-encoded data + is presented and the client_encoding setting is a + client-only encoding, such as SJIS (Jiang Guiqing) +

  • Fix bugs in the restore.sql script emitted by + pg_dump in tar output format (Tom Lane) +

    The script would fail outright on tables whose names include + upper-case characters. Also, make the script capable of restoring + data in --inserts mode as well as the regular COPY mode. +

  • Fix pg_restore to accept POSIX-conformant + tar files (Brian Weaver, Tom Lane) +

    The original coding of pg_dump's tar + output mode produced files that are not fully conformant with the + POSIX standard. This has been corrected for version 9.3. This + patch updates previous branches so that they will accept both the + incorrect and the corrected formats, in hopes of avoiding + compatibility problems when 9.3 comes out. +

  • Fix pg_resetxlog to locate postmaster.pid + correctly when given a relative path to the data directory (Tom Lane) +

    This mistake could lead to pg_resetxlog not noticing + that there is an active postmaster using the data directory. +

  • Fix libpq's lo_import() and + lo_export() functions to report file I/O errors properly + (Tom Lane) +

  • Fix ecpg's processing of nested structure pointer + variables (Muhammad Usama) +

  • Fix ecpg's ecpg_get_data function to + handle arrays properly (Michael Meskes) +

  • Make contrib/pageinspect's btree page inspection + functions take buffer locks while examining pages (Tom Lane) +

  • Fix pgxs support for building loadable modules on AIX + (Tom Lane) +

    Building modules outside the original source tree didn't work on AIX. +

  • Update time zone data files to tzdata release 2012j + for DST law changes in Cuba, Israel, Jordan, Libya, Palestine, Western + Samoa, and portions of Brazil. +


PrevHomeNext
Release 9.1UpRelease 9.0.10
\ No newline at end of file diff --git a/doc/src/sgml/html/release-9-0-2.html b/doc/src/sgml/html/release-9-0-2.html new file mode 100644 index 000000000..133ac6a0a --- /dev/null +++ b/doc/src/sgml/html/release-9-0-2.html @@ -0,0 +1,733 @@ + +Release 9.0.2

E.21. Release 9.0.2

Release Date: 2010-12-16

This release contains a variety of fixes from 9.0.1. + For information about new features in the 9.0 major release, see + Section E.23. +

E.21.1. Migration to Version 9.0.2

A dump/restore is not required for those running 9.0.X. +

E.21.2. Changes

  • Force the default + wal_sync_method + to be fdatasync on Linux (Tom Lane, Marti Raudsepp) +

    The default on Linux has actually been fdatasync for many + years, but recent kernel changes caused PostgreSQL to + choose open_datasync instead. This choice did not result + in any performance improvement, and caused outright failures on + certain filesystems, notably ext4 with the + data=journal mount option. +

  • Fix "too many KnownAssignedXids" error during Hot Standby + replay (Heikki Linnakangas) +

  • Fix race condition in lock acquisition during Hot Standby (Simon Riggs) +

  • Avoid unnecessary conflicts during Hot Standby (Simon Riggs) +

    This fixes some cases where replay was considered to conflict with + standby queries (causing delay of replay or possibly cancellation of + the queries), but there was no real conflict. +

  • Fix assorted bugs in WAL replay logic for GIN indexes (Tom Lane) +

    This could result in "bad buffer id: 0" failures or + corruption of index contents during replication. +

  • Fix recovery from base backup when the starting checkpoint WAL record + is not in the same WAL segment as its redo point (Jeff Davis) +

  • Fix corner-case bug when streaming replication is enabled immediately + after creating the master database cluster (Heikki Linnakangas) +

  • Fix persistent slowdown of autovacuum workers when multiple workers + remain active for a long time (Tom Lane) +

    The effective vacuum_cost_limit for an autovacuum worker + could drop to nearly zero if it processed enough tables, causing it + to run extremely slowly. +

  • Fix long-term memory leak in autovacuum launcher (Alvaro Herrera) +

  • Avoid failure when trying to report an impending transaction + wraparound condition from outside a transaction (Tom Lane) +

    This oversight prevented recovery after transaction wraparound got + too close, because database startup processing would fail. +

  • Add support for detecting register-stack overrun on IA64 + (Tom Lane) +

    The IA64 architecture has two hardware stacks. Full + prevention of stack-overrun failures requires checking both. +

  • Add a check for stack overflow in copyObject() (Tom Lane) +

    Certain code paths could crash due to stack overflow given a + sufficiently complex query. +

  • Fix detection of page splits in temporary GiST indexes (Heikki + Linnakangas) +

    It is possible to have a "concurrent" page split in a + temporary index, if for example there is an open cursor scanning the + index when an insertion is done. GiST failed to detect this case and + hence could deliver wrong results when execution of the cursor + continued. +

  • Fix error checking during early connection processing (Tom Lane) +

    The check for too many child processes was skipped in some cases, + possibly leading to postmaster crash when attempting to add the new + child process to fixed-size arrays. +

  • Improve efficiency of window functions (Tom Lane) +

    Certain cases where a large number of tuples needed to be read in + advance, but work_mem was large enough to allow them all + to be held in memory, were unexpectedly slow. + percent_rank(), cume_dist() and + ntile() in particular were subject to this problem. +

  • Avoid memory leakage while ANALYZE'ing complex index + expressions (Tom Lane) +

  • Ensure an index that uses a whole-row Var still depends on its table + (Tom Lane) +

    An index declared like create index i on t (foo(t.*)) + would not automatically get dropped when its table was dropped. +

  • Add missing support in DROP OWNED BY for removing foreign + data wrapper/server privileges belonging to a user (Heikki Linnakangas) +

  • Do not "inline" a SQL function with multiple OUT + parameters (Tom Lane) +

    This avoids a possible crash due to loss of information about the + expected result rowtype. +

  • Fix crash when inline-ing a set-returning function whose argument list + contains a reference to an inline-able user function (Tom Lane) +

  • Behave correctly if ORDER BY, LIMIT, + FOR UPDATE, or WITH is attached to the + VALUES part of INSERT ... VALUES (Tom Lane) +

  • Make the OFF keyword unreserved (Heikki Linnakangas) +

    This prevents problems with using off as a variable name in + PL/pgSQL. That worked before 9.0, but was now broken + because PL/pgSQL now treats all core reserved words + as reserved. +

  • Fix constant-folding of COALESCE() expressions (Tom Lane) +

    The planner would sometimes attempt to evaluate sub-expressions that + in fact could never be reached, possibly leading to unexpected errors. +

  • Fix "could not find pathkey item to sort" planner failure + with comparison of whole-row Vars (Tom Lane) +

  • Fix postmaster crash when connection acceptance + (accept() or one of the calls made immediately after it) + fails, and the postmaster was compiled with GSSAPI support (Alexander + Chernikov) +

  • Retry after receiving an invalid response packet from a RADIUS + authentication server (Magnus Hagander) +

    This fixes a low-risk potential denial of service condition. +

  • Fix missed unlink of temporary files when log_temp_files + is active (Tom Lane) +

    If an error occurred while attempting to emit the log message, the + unlink was not done, resulting in accumulation of temp files. +

  • Add print functionality for InhRelation nodes (Tom Lane) +

    This avoids a failure when debug_print_parse is enabled + and certain types of query are executed. +

  • Fix incorrect calculation of distance from a point to a horizontal + line segment (Tom Lane) +

    This bug affected several different geometric distance-measurement + operators. +

  • Fix incorrect calculation of transaction status in + ecpg (Itagaki Takahiro) +

  • Fix errors in psql's Unicode-escape support (Tom Lane) +

  • Speed up parallel pg_restore when the archive + contains many large objects (blobs) (Tom Lane) +

  • Fix PL/pgSQL's handling of "simple" + expressions to not fail in recursion or error-recovery cases (Tom Lane) +

  • Fix PL/pgSQL's error reporting for no-such-column + cases (Tom Lane) +

    As of 9.0, it would sometimes report "missing FROM-clause entry + for table foo" when "record foo has no field bar" would be + more appropriate. +

  • Fix PL/Python to honor typmod (i.e., length or + precision restrictions) when assigning to tuple fields (Tom Lane) +

    This fixes a regression from 8.4. +

  • Fix PL/Python's handling of set-returning functions + (Jan Urbanski) +

    Attempts to call SPI functions within the iterator generating a set + result would fail. +

  • Fix bug in contrib/cube's GiST picksplit algorithm + (Alexander Korotkov) +

    This could result in considerable inefficiency, though not actually + incorrect answers, in a GiST index on a cube column. + If you have such an index, consider REINDEXing it after + installing this update. +

  • Don't emit "identifier will be truncated" notices in + contrib/dblink except when creating new connections + (Itagaki Takahiro) +

  • Fix potential coredump on missing public key in + contrib/pgcrypto (Marti Raudsepp) +

  • Fix buffer overrun in contrib/pg_upgrade (Hernan Gonzalez) +

  • Fix memory leak in contrib/xml2's XPath query functions + (Tom Lane) +

  • Update time zone data files to tzdata release 2010o + for DST law changes in Fiji and Samoa; + also historical corrections for Hong Kong. +


PrevHomeNext
Release 9.0.3UpRelease 9.0.1
\ No newline at end of file diff --git a/doc/src/sgml/html/release-9-0-3.html b/doc/src/sgml/html/release-9-0-3.html new file mode 100644 index 000000000..3f9332c88 --- /dev/null +++ b/doc/src/sgml/html/release-9-0-3.html @@ -0,0 +1,409 @@ + +Release 9.0.3

E.20. Release 9.0.3

Release Date: 2011-01-31

This release contains a variety of fixes from 9.0.2. + For information about new features in the 9.0 major release, see + Section E.23. +

E.20.1. Migration to Version 9.0.3

A dump/restore is not required for those running 9.0.X. +

E.20.2. Changes

  • Before exiting walreceiver, ensure all the received WAL + is fsync'd to disk (Heikki Linnakangas) +

    Otherwise the standby server could replay some un-synced WAL, conceivably + leading to data corruption if the system crashes just at that point. +

  • Avoid excess fsync activity in walreceiver + (Heikki Linnakangas) +

  • Make ALTER TABLE revalidate uniqueness and exclusion + constraints when needed (Noah Misch) +

    This was broken in 9.0 by a change that was intended to suppress + revalidation during VACUUM FULL and CLUSTER, + but unintentionally affected ALTER TABLE as well. +

  • Fix EvalPlanQual for UPDATE of an inheritance tree in which + the tables are not all alike (Tom Lane) +

    Any variation in the table row types (including dropped columns present + in only some child tables) would confuse the EvalPlanQual code, leading + to misbehavior or even crashes. Since EvalPlanQual is only executed + during concurrent updates to the same row, the problem was only seen + intermittently. +

  • Avoid failures when EXPLAIN tries to display a simple-form + CASE expression (Tom Lane) +

    If the CASE's test expression was a constant, the planner + could simplify the CASE into a form that confused the + expression-display code, resulting in "unexpected CASE WHEN + clause" errors. +

  • Fix assignment to an array slice that is before the existing range + of subscripts (Tom Lane) +

    If there was a gap between the newly added subscripts and the first + pre-existing subscript, the code miscalculated how many entries needed + to be copied from the old array's null bitmap, potentially leading to + data corruption or crash. +

  • Avoid unexpected conversion overflow in planner for very distant date + values (Tom Lane) +

    The date type supports a wider range of dates than can be + represented by the timestamp types, but the planner assumed it + could always convert a date to timestamp with impunity. +

  • Fix PL/Python crash when an array contains null entries (Alex Hunsaker) +

  • Remove ecpg's fixed length limit for constants defining + an array dimension (Michael Meskes) +

  • Fix erroneous parsing of tsquery values containing + ... & !(subexpression) | ... (Tom Lane) +

    Queries containing this combination of operators were not executed + correctly. The same error existed in contrib/intarray's + query_int type and contrib/ltree's + ltxtquery type. +

  • Fix buffer overrun in contrib/intarray's input function + for the query_int type (Apple) +

    This bug is a security risk since the function's return address could + be overwritten. Thanks to Apple Inc's security team for reporting this + issue and supplying the fix. (CVE-2010-4015) +

  • Fix bug in contrib/seg's GiST picksplit algorithm + (Alexander Korotkov) +

    This could result in considerable inefficiency, though not actually + incorrect answers, in a GiST index on a seg column. + If you have such an index, consider REINDEXing it after + installing this update. (This is identical to the bug that was fixed in + contrib/cube in the previous update.) +


PrevHomeNext
Release 9.0.4UpRelease 9.0.2
\ No newline at end of file diff --git a/doc/src/sgml/html/release-9-0-4.html b/doc/src/sgml/html/release-9-0-4.html new file mode 100644 index 000000000..f48167d18 --- /dev/null +++ b/doc/src/sgml/html/release-9-0-4.html @@ -0,0 +1,587 @@ + +Release 9.0.4

E.19. Release 9.0.4

Release Date: 2011-04-18

This release contains a variety of fixes from 9.0.3. + For information about new features in the 9.0 major release, see + Section E.23. +

E.19.1. Migration to Version 9.0.4

A dump/restore is not required for those running 9.0.X. +

However, if your installation was upgraded from a previous major + release by running pg_upgrade, you should take + action to prevent possible data loss due to a now-fixed bug in + pg_upgrade. The recommended solution is to run + VACUUM FREEZE on all TOAST tables. + More information is available at http://wiki.postgresql.org/wiki/20110408pg_upgrade_fix. +

E.19.2. Changes

  • Fix pg_upgrade's handling of TOAST tables + (Bruce Momjian) +

    The pg_class.relfrozenxid value for + TOAST tables was not correctly copied into the new installation + during pg_upgrade. This could later result in + pg_clog files being discarded while they were still + needed to validate tuples in the TOAST tables, leading to + "could not access status of transaction" failures. +

    This error poses a significant risk of data loss for installations + that have been upgraded with pg_upgrade. This patch + corrects the problem for future uses of pg_upgrade, + but does not in itself cure the issue in installations that have been + processed with a buggy version of pg_upgrade. +

  • Suppress incorrect "PD_ALL_VISIBLE flag was incorrectly set" + warning (Heikki Linnakangas) +

    VACUUM would sometimes issue this warning in cases that + are actually valid. +

  • Use better SQLSTATE error codes for hot standby conflict cases + (Tatsuo Ishii and Simon Riggs) +

    All retryable conflict errors now have an error code that indicates + that a retry is possible. Also, session closure due to the database + being dropped on the master is now reported as + ERRCODE_DATABASE_DROPPED, rather than + ERRCODE_ADMIN_SHUTDOWN, so that connection poolers can + handle the situation correctly. +

  • Prevent intermittent hang in interactions of startup process with + bgwriter process (Simon Riggs) +

    This affected recovery in non-hot-standby cases. +

  • Disallow including a composite type in itself (Tom Lane) +

    This prevents scenarios wherein the server could recurse infinitely + while processing the composite type. While there are some possible + uses for such a structure, they don't seem compelling enough to + justify the effort required to make sure it always works safely. +

  • Avoid potential deadlock during catalog cache initialization + (Nikhil Sontakke) +

    In some cases the cache loading code would acquire share lock on a + system index before locking the index's catalog. This could deadlock + against processes trying to acquire exclusive locks in the other, + more standard order. +

  • Fix dangling-pointer problem in BEFORE ROW UPDATE trigger + handling when there was a concurrent update to the target tuple + (Tom Lane) +

    This bug has been observed to result in intermittent "cannot + extract system attribute from virtual tuple" failures while trying to + do UPDATE RETURNING ctid. There is a very small probability + of more serious errors, such as generating incorrect index entries for + the updated tuple. +

  • Disallow DROP TABLE when there are pending deferred trigger + events for the table (Tom Lane) +

    Formerly the DROP would go through, leading to + "could not open relation with OID nnn" errors when the + triggers were eventually fired. +

  • Allow "replication" as a user name in + pg_hba.conf (Andrew Dunstan) +

    "replication" is special in the database name column, but it + was mistakenly also treated as special in the user name column. +

  • Prevent crash triggered by constant-false WHERE conditions during + GEQO optimization (Tom Lane) +

  • Improve planner's handling of semi-join and anti-join cases + (Tom Lane) +

  • Fix handling of SELECT FOR UPDATE in a sub-SELECT + (Tom Lane) +

    This bug typically led to "cannot extract system attribute from + virtual tuple" errors. +

  • Fix selectivity estimation for text search to account for NULLs + (Jesper Krogh) +

  • Fix get_actual_variable_range() to support hypothetical indexes + injected by an index adviser plugin (Gurjeet Singh) +

  • Fix PL/Python memory leak involving array slices (Daniel Popowich) +

  • Allow libpq's SSL initialization to succeed when + user's home directory is unavailable (Tom Lane) +

    If the SSL mode is such that a root certificate file is not required, + there is no need to fail. This change restores the behavior to what + it was in pre-9.0 releases. +

  • Fix libpq to return a useful error message for errors + detected in conninfo_array_parse (Joseph Adams) +

    A typo caused the library to return NULL, rather than the + PGconn structure containing the error message, to the + application. +

  • Fix ecpg preprocessor's handling of float constants + (Heikki Linnakangas) +

  • Fix parallel pg_restore to handle comments on + POST_DATA items correctly (Arnd Hannemann) +

  • Fix pg_restore to cope with long lines (over 1KB) in + TOC files (Tom Lane) +

  • Put in more safeguards against crashing due to division-by-zero + with overly enthusiastic compiler optimization (Aurelien Jarno) +

  • Support use of dlopen() in FreeBSD and OpenBSD on MIPS (Tom Lane) +

    There was a hard-wired assumption that this system function was not + available on MIPS hardware on these systems. Use a compile-time test + instead, since more recent versions have it. +

  • Fix compilation failures on HP-UX (Heikki Linnakangas) +

  • Avoid crash when trying to write to the Windows console very early + in process startup (Rushabh Lathia) +

  • Support building with MinGW 64 bit compiler for Windows + (Andrew Dunstan) +

  • Fix version-incompatibility problem with libintl on + Windows (Hiroshi Inoue) +

  • Fix usage of xcopy in Windows build scripts to + work correctly under Windows 7 (Andrew Dunstan) +

    This affects the build scripts only, not installation or usage. +

  • Fix path separator used by pg_regress on Cygwin + (Andrew Dunstan) +

  • Update time zone data files to tzdata release 2011f + for DST law changes in Chile, Cuba, Falkland Islands, Morocco, Samoa, + and Turkey; also historical corrections for South Australia, Alaska, + and Hawaii. +


PrevHomeNext
Release 9.0.5UpRelease 9.0.3
\ No newline at end of file diff --git a/doc/src/sgml/html/release-9-0-5.html b/doc/src/sgml/html/release-9-0-5.html new file mode 100644 index 000000000..ff0eb2e2e --- /dev/null +++ b/doc/src/sgml/html/release-9-0-5.html @@ -0,0 +1,959 @@ + +Release 9.0.5

E.18. Release 9.0.5

Release Date: 2011-09-26

This release contains a variety of fixes from 9.0.4. + For information about new features in the 9.0 major release, see + Section E.23. +

E.18.1. Migration to Version 9.0.5

A dump/restore is not required for those running 9.0.X. +

However, if you are upgrading from a version earlier than 9.0.4, + see the release notes for 9.0.4. +

E.18.2. Changes

  • Fix catalog cache invalidation after a VACUUM FULL or + CLUSTER on a system catalog (Tom Lane) +

    In some cases the relocation of a system catalog row to another place + would not be recognized by concurrent server processes, allowing catalog + corruption to occur if they then tried to update that row. The + worst-case outcome could be as bad as complete loss of a table. +

  • Fix incorrect order of operations during sinval reset processing, + and ensure that TOAST OIDs are preserved in system catalogs (Tom + Lane) +

    These mistakes could lead to transient failures after a VACUUM + FULL or CLUSTER on a system catalog. +

  • Fix bugs in indexing of in-doubt HOT-updated tuples (Tom Lane) +

    These bugs could result in index corruption after reindexing a system + catalog. They are not believed to affect user indexes. +

  • Fix multiple bugs in GiST index page split processing (Heikki + Linnakangas) +

    The probability of occurrence was low, but these could lead to index + corruption. +

  • Fix possible buffer overrun in tsvector_concat() + (Tom Lane) +

    The function could underestimate the amount of memory needed for its + result, leading to server crashes. +

  • Fix crash in xml_recv when processing a + "standalone" parameter (Tom Lane) +

  • Make pg_options_to_table return NULL for an option with no + value (Tom Lane) +

    Previously such cases would result in a server crash. +

  • Avoid possibly accessing off the end of memory in ANALYZE + and in SJIS-2004 encoding conversion (Noah Misch) +

    This fixes some very-low-probability server crash scenarios. +

  • Protect pg_stat_reset_shared() against NULL input (Magnus + Hagander) +

  • Fix possible failure when a recovery conflict deadlock is detected + within a sub-transaction (Tom Lane) +

  • Avoid spurious conflicts while recycling btree index pages during hot + standby (Noah Misch, Simon Riggs) +

  • Shut down WAL receiver if it's still running at end of recovery (Heikki + Linnakangas) +

    The postmaster formerly panicked in this situation, but it's actually a + legitimate case. +

  • Fix race condition in relcache init file invalidation (Tom Lane) +

    There was a window wherein a new backend process could read a stale init + file but miss the inval messages that would tell it the data is stale. + The result would be bizarre failures in catalog accesses, typically + "could not read block 0 in file ..." later during startup. +

  • Fix memory leak at end of a GiST index scan (Tom Lane) +

    Commands that perform many separate GiST index scans, such as + verification of a new GiST-based exclusion constraint on a table + already containing many rows, could transiently require large amounts of + memory due to this leak. +

  • Fix memory leak when encoding conversion has to be done on incoming + command strings and LISTEN is active (Tom Lane) +

  • Fix incorrect memory accounting (leading to possible memory bloat) in + tuplestores supporting holdable cursors and plpgsql's RETURN + NEXT command (Tom Lane) +

  • Fix trigger WHEN conditions when both BEFORE and + AFTER triggers exist (Tom Lane) +

    Evaluation of WHEN conditions for AFTER ROW + UPDATE triggers could crash if there had been a BEFORE + ROW trigger fired for the same update. +

  • Fix performance problem when constructing a large, lossy bitmap + (Tom Lane) +

  • Fix join selectivity estimation for unique columns (Tom Lane) +

    This fixes an erroneous planner heuristic that could lead to poor + estimates of the result size of a join. +

  • Fix nested PlaceHolderVar expressions that appear only in sub-select + target lists (Tom Lane) +

    This mistake could result in outputs of an outer join incorrectly + appearing as NULL. +

  • Allow the planner to assume that empty parent tables really are empty + (Tom Lane) +

    Normally an empty table is assumed to have a certain minimum size for + planning purposes; but this heuristic seems to do more harm than good + for the parent table of an inheritance hierarchy, which often is + permanently empty. +

  • Allow nested EXISTS queries to be optimized properly (Tom + Lane) +

  • Fix array- and path-creating functions to ensure padding bytes are + zeroes (Tom Lane) +

    This avoids some situations where the planner will think that + semantically-equal constants are not equal, resulting in poor + optimization. +

  • Fix EXPLAIN to handle gating Result nodes within + inner-indexscan subplans (Tom Lane) +

    The usual symptom of this oversight was "bogus varno" errors. +

  • Fix btree preprocessing of indexedcol IS + NULL conditions (Dean Rasheed) +

    Such a condition is unsatisfiable if combined with any other type of + btree-indexable condition on the same index column. The case was + handled incorrectly in 9.0.0 and later, leading to query output where + there should be none. +

  • Work around gcc 4.6.0 bug that breaks WAL replay (Tom Lane) +

    This could lead to loss of committed transactions after a server crash. +

  • Fix dump bug for VALUES in a view (Tom Lane) +

  • Disallow SELECT FOR UPDATE/SHARE on sequences (Tom Lane) +

    This operation doesn't work as expected and can lead to failures. +

  • Fix VACUUM so that it always updates + pg_class.reltuples/relpages (Tom + Lane) +

    This fixes some scenarios where autovacuum could make increasingly poor + decisions about when to vacuum tables. +

  • Defend against integer overflow when computing size of a hash table (Tom + Lane) +

  • Fix cases where CLUSTER might attempt to access + already-removed TOAST data (Tom Lane) +

  • Fix premature timeout failures during initial authentication transaction + (Tom Lane) +

  • Fix portability bugs in use of credentials control messages for + "peer" authentication (Tom Lane) +

  • Fix SSPI login when multiple roundtrips are required (Ahmed Shinwari, + Magnus Hagander) +

    The typical symptom of this problem was "The function requested is + not supported" errors during SSPI login. +

  • Fix failure when adding a new variable of a custom variable class to + postgresql.conf (Tom Lane) +

  • Throw an error if pg_hba.conf contains hostssl + but SSL is disabled (Tom Lane) +

    This was concluded to be more user-friendly than the previous behavior + of silently ignoring such lines. +

  • Fix failure when DROP OWNED BY attempts to remove default + privileges on sequences (Shigeru Hanada) +

  • Fix typo in pg_srand48 seed initialization (Andres Freund) +

    This led to failure to use all bits of the provided seed. This function + is not used on most platforms (only those without srandom), + and the potential security exposure from a less-random-than-expected + seed seems minimal in any case. +

  • Avoid integer overflow when the sum of LIMIT and + OFFSET values exceeds 2^63 (Heikki Linnakangas) +

  • Add overflow checks to int4 and int8 versions of + generate_series() (Robert Haas) +

  • Fix trailing-zero removal in to_char() (Marti Raudsepp) +

    In a format with FM and no digit positions + after the decimal point, zeroes to the left of the decimal point could + be removed incorrectly. +

  • Fix pg_size_pretty() to avoid overflow for inputs close to + 2^63 (Tom Lane) +

  • Weaken plpgsql's check for typmod matching in record values (Tom Lane) +

    An overly enthusiastic check could lead to discarding length modifiers + that should have been kept. +

  • Correctly handle quotes in locale names during initdb + (Heikki Linnakangas) +

    The case can arise with some Windows locales, such as "People's + Republic of China". +

  • In pg_upgrade, avoid dumping orphaned temporary tables + (Bruce Momjian) +

    This prevents situations wherein table OID assignments could get out of + sync between old and new installations. +

  • Fix pg_upgrade to preserve toast tables' relfrozenxids + during an upgrade from 8.3 (Bruce Momjian) +

    Failure to do this could lead to pg_clog files being + removed too soon after the upgrade. +

  • In pg_upgrade, fix the -l (log) option to + work on Windows (Bruce Momjian) +

  • In pg_ctl, support silent mode for service registrations + on Windows (MauMau) +

  • Fix psql's counting of script file line numbers during + COPY from a different file (Tom Lane) +

  • Fix pg_restore's direct-to-database mode for + standard_conforming_strings (Tom Lane) +

    pg_restore could emit incorrect commands when restoring + directly to a database server from an archive file that had been made + with standard_conforming_strings set to on. +

  • Be more user-friendly about unsupported cases for parallel + pg_restore (Tom Lane) +

    This change ensures that such cases are detected and reported before + any restore actions have been taken. +

  • Fix write-past-buffer-end and memory leak in libpq's + LDAP service lookup code (Albe Laurenz) +

  • In libpq, avoid failures when using nonblocking I/O + and an SSL connection (Martin Pihlak, Tom Lane) +

  • Improve libpq's handling of failures during connection startup + (Tom Lane) +

    In particular, the response to a server report of fork() + failure during SSL connection startup is now saner. +

  • Improve libpq's error reporting for SSL failures (Tom + Lane) +

  • Fix PQsetvalue() to avoid possible crash when adding a new + tuple to a PGresult originally obtained from a server + query (Andrew Chernow) +

  • Make ecpglib write double values with 15 digits + precision (Akira Kurosawa) +

  • In ecpglib, be sure LC_NUMERIC setting is + restored after an error (Michael Meskes) +

  • Apply upstream fix for blowfish signed-character bug (CVE-2011-2483) + (Tom Lane) +

    contrib/pg_crypto's blowfish encryption code could give + wrong results on platforms where char is signed (which is most), + leading to encrypted passwords being weaker than they should be. +

  • Fix memory leak in contrib/seg (Heikki Linnakangas) +

  • Fix pgstatindex() to give consistent results for empty + indexes (Tom Lane) +

  • Allow building with perl 5.14 (Alex Hunsaker) +

  • Fix assorted issues with build and install file paths containing spaces + (Tom Lane) +

  • Update time zone data files to tzdata release 2011i + for DST law changes in Canada, Egypt, Russia, Samoa, and South Sudan. +


PrevHomeNext
Release 9.0.6UpRelease 9.0.4
\ No newline at end of file diff --git a/doc/src/sgml/html/release-9-0-6.html b/doc/src/sgml/html/release-9-0-6.html new file mode 100644 index 000000000..34de6630f --- /dev/null +++ b/doc/src/sgml/html/release-9-0-6.html @@ -0,0 +1,657 @@ + +Release 9.0.6

E.17. Release 9.0.6

Release Date: 2011-12-05

This release contains a variety of fixes from 9.0.5. + For information about new features in the 9.0 major release, see + Section E.23. +

E.17.1. Migration to Version 9.0.6

A dump/restore is not required for those running 9.0.X. +

However, a longstanding error was discovered in the definition of the + information_schema.referential_constraints view. If you + rely on correct results from that view, you should replace its + definition as explained in the first changelog item below. +

Also, if you are upgrading from a version earlier than 9.0.4, + see the release notes for 9.0.4. +

E.17.2. Changes

  • Fix bugs in information_schema.referential_constraints view + (Tom Lane) +

    This view was being insufficiently careful about matching the + foreign-key constraint to the depended-on primary or unique key + constraint. That could result in failure to show a foreign key + constraint at all, or showing it multiple times, or claiming that it + depends on a different constraint than the one it really does. +

    Since the view definition is installed by initdb, + merely upgrading will not fix the problem. If you need to fix this + in an existing installation, you can (as a superuser) drop the + information_schema schema then re-create it by sourcing + SHAREDIR/information_schema.sql. + (Run pg_config --sharedir if you're uncertain where + SHAREDIR is.) This must be repeated in each database + to be fixed. +

  • Fix possible crash during UPDATE or DELETE that + joins to the output of a scalar-returning function (Tom Lane) +

    A crash could only occur if the target row had been concurrently + updated, so this problem surfaced only intermittently. +

  • Fix incorrect replay of WAL records for GIN index updates + (Tom Lane) +

    This could result in transiently failing to find index entries after + a crash, or on a hot-standby server. The problem would be repaired + by the next VACUUM of the index, however. +

  • Fix TOAST-related data corruption during CREATE TABLE dest AS + SELECT * FROM src or INSERT INTO dest SELECT * FROM src + (Tom Lane) +

    If a table has been modified by ALTER TABLE ADD COLUMN, + attempts to copy its data verbatim to another table could produce + corrupt results in certain corner cases. + The problem can only manifest in this precise form in 8.4 and later, + but we patched earlier versions as well in case there are other code + paths that could trigger the same bug. +

  • Fix possible failures during hot standby startup (Simon Riggs) +

  • Start hot standby faster when initial snapshot is incomplete + (Simon Riggs) +

  • Fix race condition during toast table access from stale syscache entries + (Tom Lane) +

    The typical symptom was transient errors like "missing chunk + number 0 for toast value NNNNN in pg_toast_2619", where the cited + toast table would always belong to a system catalog. +

  • Track dependencies of functions on items used in parameter default + expressions (Tom Lane) +

    Previously, a referenced object could be dropped without having dropped + or modified the function, leading to misbehavior when the function was + used. Note that merely installing this update will not fix the missing + dependency entries; to do that, you'd need to CREATE OR + REPLACE each such function afterwards. If you have functions whose + defaults depend on non-built-in objects, doing so is recommended. +

  • Allow inlining of set-returning SQL functions with multiple OUT + parameters (Tom Lane) +

  • Don't trust deferred-unique indexes for join removal (Tom Lane and Marti + Raudsepp) +

    A deferred uniqueness constraint might not hold intra-transaction, + so assuming that it does could give incorrect query results. +

  • Make DatumGetInetP() unpack inet datums that have a 1-byte + header, and add a new macro, DatumGetInetPP(), that does + not (Heikki Linnakangas) +

    This change affects no core code, but might prevent crashes in add-on + code that expects DatumGetInetP() to produce an unpacked + datum as per usual convention. +

  • Improve locale support in money type's input and output + (Tom Lane) +

    Aside from not supporting all standard + lc_monetary + formatting options, the input and output functions were inconsistent, + meaning there were locales in which dumped money values could + not be re-read. +

  • Don't let transform_null_equals + affect CASE foo WHEN NULL ... constructs + (Heikki Linnakangas) +

    transform_null_equals is only supposed to affect + foo = NULL expressions written directly by the user, not + equality checks generated internally by this form of CASE. +

  • Change foreign-key trigger creation order to better support + self-referential foreign keys (Tom Lane) +

    For a cascading foreign key that references its own table, a row update + will fire both the ON UPDATE trigger and the + CHECK trigger as one event. The ON UPDATE + trigger must execute first, else the CHECK will check a + non-final state of the row and possibly throw an inappropriate error. + However, the firing order of these triggers is determined by their + names, which generally sort in creation order since the triggers have + auto-generated names following the convention + "RI_ConstraintTrigger_NNNN". A proper fix would require + modifying that convention, which we will do in 9.2, but it seems risky + to change it in existing releases. So this patch just changes the + creation order of the triggers. Users encountering this type of error + should drop and re-create the foreign key constraint to get its + triggers into the right order. +

  • Avoid floating-point underflow while tracking buffer allocation rate + (Greg Matthews) +

    While harmless in itself, on certain platforms this would result in + annoying kernel log messages. +

  • Preserve configuration file name and line number values when starting + child processes under Windows (Tom Lane) +

    Formerly, these would not be displayed correctly in the + pg_settings view. +

  • Fix incorrect field alignment in ecpg's SQLDA area + (Zoltan Boszormenyi) +

  • Preserve blank lines within commands in psql's command + history (Robert Haas) +

    The former behavior could cause problems if an empty line was removed + from within a string literal, for example. +

  • Fix pg_dump to dump user-defined casts between + auto-generated types, such as table rowtypes (Tom Lane) +

  • Assorted fixes for pg_upgrade (Bruce Momjian) +

    Handle exclusion constraints correctly, avoid failures on Windows, + don't complain about mismatched toast table names in 8.4 databases. +

  • Use the preferred version of xsubpp to build PL/Perl, + not necessarily the operating system's main copy + (David Wheeler and Alex Hunsaker) +

  • Fix incorrect coding in contrib/dict_int and + contrib/dict_xsyn (Tom Lane) +

    Some functions incorrectly assumed that memory returned by + palloc() is guaranteed zeroed. +

  • Fix assorted errors in contrib/unaccent's configuration + file parsing (Tom Lane) +

  • Honor query cancel interrupts promptly in pgstatindex() + (Robert Haas) +

  • Fix incorrect quoting of log file name in Mac OS X start script + (Sidar Lopez) +

  • Ensure VPATH builds properly install all server header files + (Peter Eisentraut) +

  • Shorten file names reported in verbose error messages (Peter Eisentraut) +

    Regular builds have always reported just the name of the C file + containing the error message call, but VPATH builds formerly + reported an absolute path name. +

  • Fix interpretation of Windows timezone names for Central America + (Tom Lane) +

    Map "Central America Standard Time" to CST6, not + CST6CDT, because DST is generally not observed anywhere in + Central America. +

  • Update time zone data files to tzdata release 2011n + for DST law changes in Brazil, Cuba, Fiji, Palestine, Russia, and Samoa; + also historical corrections for Alaska and British East Africa. +


PrevHomeNext
Release 9.0.7UpRelease 9.0.5
\ No newline at end of file diff --git a/doc/src/sgml/html/release-9-0-7.html b/doc/src/sgml/html/release-9-0-7.html new file mode 100644 index 000000000..1125d6a18 --- /dev/null +++ b/doc/src/sgml/html/release-9-0-7.html @@ -0,0 +1,797 @@ + +Release 9.0.7

E.16. Release 9.0.7

Release Date: 2012-02-27

This release contains a variety of fixes from 9.0.6. + For information about new features in the 9.0 major release, see + Section E.23. +

E.16.1. Migration to Version 9.0.7

A dump/restore is not required for those running 9.0.X. +

However, if you are upgrading from a version earlier than 9.0.6, + see the release notes for 9.0.6. +

E.16.2. Changes

  • Require execute permission on the trigger function for + CREATE TRIGGER (Robert Haas) +

    This missing check could allow another user to execute a trigger + function with forged input data, by installing it on a table he owns. + This is only of significance for trigger functions marked + SECURITY DEFINER, since otherwise trigger functions run + as the table owner anyway. (CVE-2012-0866) +

  • Remove arbitrary limitation on length of common name in SSL + certificates (Heikki Linnakangas) +

    Both libpq and the server truncated the common name + extracted from an SSL certificate at 32 bytes. Normally this would + cause nothing worse than an unexpected verification failure, but there + are some rather-implausible scenarios in which it might allow one + certificate holder to impersonate another. The victim would have to + have a common name exactly 32 bytes long, and the attacker would have + to persuade a trusted CA to issue a certificate in which the common + name has that string as a prefix. Impersonating a server would also + require some additional exploit to redirect client connections. + (CVE-2012-0867) +

  • Convert newlines to spaces in names written in pg_dump + comments (Robert Haas) +

    pg_dump was incautious about sanitizing object names + that are emitted within SQL comments in its output script. A name + containing a newline would at least render the script syntactically + incorrect. Maliciously crafted object names could present a SQL + injection risk when the script is reloaded. (CVE-2012-0868) +

  • Fix btree index corruption from insertions concurrent with vacuuming + (Tom Lane) +

    An index page split caused by an insertion could sometimes cause a + concurrently-running VACUUM to miss removing index entries + that it should remove. After the corresponding table rows are removed, + the dangling index entries would cause errors (such as "could not + read block N in file ...") or worse, silently wrong query results + after unrelated rows are re-inserted at the now-free table locations. + This bug has been present since release 8.2, but occurs so infrequently + that it was not diagnosed until now. If you have reason to suspect + that it has happened in your database, reindexing the affected index + will fix things. +

  • Fix transient zeroing of shared buffers during WAL replay (Tom Lane) +

    The replay logic would sometimes zero and refill a shared buffer, so + that the contents were transiently invalid. In hot standby mode this + can result in a query that's executing in parallel seeing garbage data. + Various symptoms could result from that, but the most common one seems + to be "invalid memory alloc request size". +

  • Fix postmaster to attempt restart after a hot-standby crash (Tom Lane) +

    A logic error caused the postmaster to terminate, rather than attempt + to restart the cluster, if any backend process crashed while operating + in hot standby mode. +

  • Fix CLUSTER/VACUUM FULL handling of toast + values owned by recently-updated rows (Tom Lane) +

    This oversight could lead to "duplicate key value violates unique + constraint" errors being reported against the toast table's index + during one of these commands. +

  • Update per-column permissions, not only per-table permissions, when + changing table owner (Tom Lane) +

    Failure to do this meant that any previously granted column permissions + were still shown as having been granted by the old owner. This meant + that neither the new owner nor a superuser could revoke the + now-untraceable-to-table-owner permissions. +

  • Support foreign data wrappers and foreign servers in + REASSIGN OWNED (Alvaro Herrera) +

    This command failed with "unexpected classid" errors if + it needed to change the ownership of any such objects. +

  • Allow non-existent values for some settings in ALTER + USER/DATABASE SET (Heikki Linnakangas) +

    Allow default_text_search_config, + default_tablespace, and temp_tablespaces to be + set to names that are not known. This is because they might be known + in another database where the setting is intended to be used, or for the + tablespace cases because the tablespace might not be created yet. The + same issue was previously recognized for search_path, and + these settings now act like that one. +

  • Avoid crashing when we have problems deleting table files post-commit + (Tom Lane) +

    Dropping a table should lead to deleting the underlying disk files only + after the transaction commits. In event of failure then (for instance, + because of wrong file permissions) the code is supposed to just emit a + warning message and go on, since it's too late to abort the + transaction. This logic got broken as of release 8.4, causing such + situations to result in a PANIC and an unrestartable database. +

  • Recover from errors occurring during WAL replay of DROP + TABLESPACE (Tom Lane) +

    Replay will attempt to remove the tablespace's directories, but there + are various reasons why this might fail (for example, incorrect + ownership or permissions on those directories). Formerly the replay + code would panic, rendering the database unrestartable without manual + intervention. It seems better to log the problem and continue, since + the only consequence of failure to remove the directories is some + wasted disk space. +

  • Fix race condition in logging AccessExclusiveLocks for hot standby + (Simon Riggs) +

    Sometimes a lock would be logged as being held by "transaction + zero". This is at least known to produce assertion failures on + slave servers, and might be the cause of more serious problems. +

  • Track the OID counter correctly during WAL replay, even when it wraps + around (Tom Lane) +

    Previously the OID counter would remain stuck at a high value until the + system exited replay mode. The practical consequences of that are + usually nil, but there are scenarios wherein a standby server that's + been promoted to master might take a long time to advance the OID + counter to a reasonable value once values are needed. +

  • Prevent emitting misleading "consistent recovery state reached" + log message at the beginning of crash recovery (Heikki Linnakangas) +

  • Fix initial value of + pg_stat_replication.replay_location + (Fujii Masao) +

    Previously, the value shown would be wrong until at least one WAL + record had been replayed. +

  • Fix regular expression back-references with * attached + (Tom Lane) +

    Rather than enforcing an exact string match, the code would effectively + accept any string that satisfies the pattern sub-expression referenced + by the back-reference symbol. +

    A similar problem still afflicts back-references that are embedded in a + larger quantified expression, rather than being the immediate subject + of the quantifier. This will be addressed in a future + PostgreSQL release. +

  • Fix recently-introduced memory leak in processing of + inet/cidr values (Heikki Linnakangas) +

    A patch in the December 2011 releases of PostgreSQL + caused memory leakage in these operations, which could be significant + in scenarios such as building a btree index on such a column. +

  • Fix dangling pointer after CREATE TABLE AS/SELECT + INTO in a SQL-language function (Tom Lane) +

    In most cases this only led to an assertion failure in assert-enabled + builds, but worse consequences seem possible. +

  • Avoid double close of file handle in syslogger on Windows (MauMau) +

    Ordinarily this error was invisible, but it would cause an exception + when running on a debug version of Windows. +

  • Fix I/O-conversion-related memory leaks in plpgsql + (Andres Freund, Jan Urbanski, Tom Lane) +

    Certain operations would leak memory until the end of the current + function. +

  • Improve pg_dump's handling of inherited table columns + (Tom Lane) +

    pg_dump mishandled situations where a child column has + a different default expression than its parent column. If the default + is textually identical to the parent's default, but not actually the + same (for instance, because of schema search path differences) it would + not be recognized as different, so that after dump and restore the + child would be allowed to inherit the parent's default. Child columns + that are NOT NULL where their parent is not could also be + restored subtly incorrectly. +

  • Fix pg_restore's direct-to-database mode for + INSERT-style table data (Tom Lane) +

    Direct-to-database restores from archive files made with + --inserts or --column-inserts options fail when + using pg_restore from a release dated September or + December 2011, as a result of an oversight in a fix for another + problem. The archive file itself is not at fault, and text-mode + output is okay. +

  • Allow pg_upgrade to process tables containing + regclass columns (Bruce Momjian) +

    Since pg_upgrade now takes care to preserve + pg_class OIDs, there was no longer any reason for this + restriction. +

  • Make libpq ignore ENOTDIR errors + when looking for an SSL client certificate file + (Magnus Hagander) +

    This allows SSL connections to be established, though without a + certificate, even when the user's home directory is set to something + like /dev/null. +

  • Fix some more field alignment issues in ecpg's SQLDA area + (Zoltan Boszormenyi) +

  • Allow AT option in ecpg + DEALLOCATE statements (Michael Meskes) +

    The infrastructure to support this has been there for awhile, but + through an oversight there was still an error check rejecting the case. +

  • Do not use the variable name when defining a varchar structure in ecpg + (Michael Meskes) +

  • Fix contrib/auto_explain's JSON output mode to produce + valid JSON (Andrew Dunstan) +

    The output used brackets at the top level, when it should have used + braces. +

  • Fix error in contrib/intarray's int[] & + int[] operator (Guillaume Lelarge) +

    If the smallest integer the two input arrays have in common is 1, + and there are smaller values in either array, then 1 would be + incorrectly omitted from the result. +

  • Fix error detection in contrib/pgcrypto's + encrypt_iv() and decrypt_iv() + (Marko Kreen) +

    These functions failed to report certain types of invalid-input errors, + and would instead return random garbage values for incorrect input. +

  • Fix one-byte buffer overrun in contrib/test_parser + (Paul Guyot) +

    The code would try to read one more byte than it should, which would + crash in corner cases. + Since contrib/test_parser is only example code, this is + not a security issue in itself, but bad example code is still bad. +

  • Use __sync_lock_test_and_set() for spinlocks on ARM, if + available (Martin Pitt) +

    This function replaces our previous use of the SWPB + instruction, which is deprecated and not available on ARMv6 and later. + Reports suggest that the old code doesn't fail in an obvious way on + recent ARM boards, but simply doesn't interlock concurrent accesses, + leading to bizarre failures in multiprocess operation. +

  • Use -fexcess-precision=standard option when building with + gcc versions that accept it (Andrew Dunstan) +

    This prevents assorted scenarios wherein recent versions of gcc will + produce creative results. +

  • Allow use of threaded Python on FreeBSD (Chris Rees) +

    Our configure script previously believed that this combination wouldn't + work; but FreeBSD fixed the problem, so remove that error check. +


PrevHomeNext
Release 9.0.8UpRelease 9.0.6
\ No newline at end of file diff --git a/doc/src/sgml/html/release-9-0-8.html b/doc/src/sgml/html/release-9-0-8.html new file mode 100644 index 000000000..096ff4643 --- /dev/null +++ b/doc/src/sgml/html/release-9-0-8.html @@ -0,0 +1,565 @@ + +Release 9.0.8

E.15. Release 9.0.8

Release Date: 2012-06-04

This release contains a variety of fixes from 9.0.7. + For information about new features in the 9.0 major release, see + Section E.23. +

E.15.1. Migration to Version 9.0.8

A dump/restore is not required for those running 9.0.X. +

However, if you are upgrading from a version earlier than 9.0.6, + see the release notes for 9.0.6. +

E.15.2. Changes

  • Fix incorrect password transformation in + contrib/pgcrypto's DES crypt() function + (Solar Designer) +

    If a password string contained the byte value 0x80, the + remainder of the password was ignored, causing the password to be much + weaker than it appeared. With this fix, the rest of the string is + properly included in the DES hash. Any stored password values that are + affected by this bug will thus no longer match, so the stored values may + need to be updated. (CVE-2012-2143) +

  • Ignore SECURITY DEFINER and SET attributes for + a procedural language's call handler (Tom Lane) +

    Applying such attributes to a call handler could crash the server. + (CVE-2012-2655) +

  • Allow numeric timezone offsets in timestamp input to be up to + 16 hours away from UTC (Tom Lane) +

    Some historical time zones have offsets larger than 15 hours, the + previous limit. This could result in dumped data values being rejected + during reload. +

  • Fix timestamp conversion to cope when the given time is exactly the + last DST transition time for the current timezone (Tom Lane) +

    This oversight has been there a long time, but was not noticed + previously because most DST-using zones are presumed to have an + indefinite sequence of future DST transitions. +

  • Fix text to name and char to name + casts to perform string truncation correctly in multibyte encodings + (Karl Schnaitter) +

  • Fix memory copying bug in to_tsquery() (Heikki Linnakangas) +

  • Ensure txid_current() reports the correct epoch when + executed in hot standby (Simon Riggs) +

  • Fix planner's handling of outer PlaceHolderVars within subqueries (Tom + Lane) +

    This bug concerns sub-SELECTs that reference variables coming from the + nullable side of an outer join of the surrounding query. + In 9.1, queries affected by this bug would fail with "ERROR: + Upper-level PlaceHolderVar found where not expected". But in 9.0 and + 8.4, you'd silently get possibly-wrong answers, since the value + transmitted into the subquery wouldn't go to null when it should. +

  • Fix slow session startup when pg_attribute is very large + (Tom Lane) +

    If pg_attribute exceeds one-fourth of + shared_buffers, cache rebuilding code that is sometimes + needed during session start would trigger the synchronized-scan logic, + causing it to take many times longer than normal. The problem was + particularly acute if many new sessions were starting at once. +

  • Ensure sequential scans check for query cancel reasonably often (Merlin + Moncure) +

    A scan encountering many consecutive pages that contain no live tuples + would not respond to interrupts meanwhile. +

  • Ensure the Windows implementation of PGSemaphoreLock() + clears ImmediateInterruptOK before returning (Tom Lane) +

    This oversight meant that a query-cancel interrupt received later + in the same query could be accepted at an unsafe time, with + unpredictable but not good consequences. +

  • Show whole-row variables safely when printing views or rules + (Abbas Butt, Tom Lane) +

    Corner cases involving ambiguous names (that is, the name could be + either a table or column name of the query) were printed in an + ambiguous way, risking that the view or rule would be interpreted + differently after dump and reload. Avoid the ambiguous case by + attaching a no-op cast. +

  • Fix COPY FROM to properly handle null marker strings that + correspond to invalid encoding (Tom Lane) +

    A null marker string such as E'\\0' should work, and did + work in the past, but the case got broken in 8.4. +

  • Ensure autovacuum worker processes perform stack depth checking + properly (Heikki Linnakangas) +

    Previously, infinite recursion in a function invoked by + auto-ANALYZE could crash worker processes. +

  • Fix logging collector to not lose log coherency under high load (Andrew + Dunstan) +

    The collector previously could fail to reassemble large messages if it + got too busy. +

  • Fix logging collector to ensure it will restart file rotation + after receiving SIGHUP (Tom Lane) +

  • Fix WAL replay logic for GIN indexes to not fail if the index was + subsequently dropped (Tom Lane) +

  • Fix memory leak in PL/pgSQL's RETURN NEXT command (Joe + Conway) +

  • Fix PL/pgSQL's GET DIAGNOSTICS command when the target + is the function's first variable (Tom Lane) +

  • Fix potential access off the end of memory in psql's + expanded display (\x) mode (Peter Eisentraut) +

  • Fix several performance problems in pg_dump when + the database contains many objects (Jeff Janes, Tom Lane) +

    pg_dump could get very slow if the database contained + many schemas, or if many objects are in dependency loops, or if there + are many owned sequences. +

  • Fix pg_upgrade for the case that a database stored in a + non-default tablespace contains a table in the cluster's default + tablespace (Bruce Momjian) +

  • In ecpg, fix rare memory leaks and possible overwrite + of one byte after the sqlca_t structure (Peter Eisentraut) +

  • Fix contrib/dblink's dblink_exec() to not leak + temporary database connections upon error (Tom Lane) +

  • Fix contrib/dblink to report the correct connection name in + error messages (Kyotaro Horiguchi) +

  • Fix contrib/vacuumlo to use multiple transactions when + dropping many large objects (Tim Lewis, Robert Haas, Tom Lane) +

    This change avoids exceeding max_locks_per_transaction when + many objects need to be dropped. The behavior can be adjusted with the + new -l (limit) option. +

  • Update time zone data files to tzdata release 2012c + for DST law changes in Antarctica, Armenia, Chile, Cuba, Falkland + Islands, Gaza, Haiti, Hebron, Morocco, Syria, and Tokelau Islands; + also historical corrections for Canada. +


PrevHomeNext
Release 9.0.9UpRelease 9.0.7
\ No newline at end of file diff --git a/doc/src/sgml/html/release-9-0-9.html b/doc/src/sgml/html/release-9-0-9.html new file mode 100644 index 000000000..d0876bfd9 --- /dev/null +++ b/doc/src/sgml/html/release-9-0-9.html @@ -0,0 +1,614 @@ + +Release 9.0.9

E.14. Release 9.0.9

Release Date: 2012-08-17

This release contains a variety of fixes from 9.0.8. + For information about new features in the 9.0 major release, see + Section E.23. +

E.14.1. Migration to Version 9.0.9

A dump/restore is not required for those running 9.0.X. +

However, if you are upgrading from a version earlier than 9.0.6, + see the release notes for 9.0.6. +

E.14.2. Changes

  • Prevent access to external files/URLs via XML entity references + (Noah Misch, Tom Lane) +

    xml_parse() would attempt to fetch external files or + URLs as needed to resolve DTD and entity references in an XML value, + thus allowing unprivileged database users to attempt to fetch data + with the privileges of the database server. While the external data + wouldn't get returned directly to the user, portions of it could be + exposed in error messages if the data didn't parse as valid XML; and + in any case the mere ability to check existence of a file might be + useful to an attacker. (CVE-2012-3489) +

  • Prevent access to external files/URLs via contrib/xml2's + xslt_process() (Peter Eisentraut) +

    libxslt offers the ability to read and write both + files and URLs through stylesheet commands, thus allowing + unprivileged database users to both read and write data with the + privileges of the database server. Disable that through proper use + of libxslt's security options. (CVE-2012-3488) +

    Also, remove xslt_process()'s ability to fetch documents + and stylesheets from external files/URLs. While this was a + documented "feature", it was long regarded as a bad idea. + The fix for CVE-2012-3489 broke that capability, and rather than + expend effort on trying to fix it, we're just going to summarily + remove it. +

  • Prevent too-early recycling of btree index pages (Noah Misch) +

    When we allowed read-only transactions to skip assigning XIDs, we + introduced the possibility that a deleted btree page could be + recycled while a read-only transaction was still in flight to it. + This would result in incorrect index search results. The probability + of such an error occurring in the field seems very low because of the + timing requirements, but nonetheless it should be fixed. +

  • Fix crash-safety bug with newly-created-or-reset sequences (Tom Lane) +

    If ALTER SEQUENCE was executed on a freshly created or + reset sequence, and then precisely one nextval() call + was made on it, and then the server crashed, WAL replay would restore + the sequence to a state in which it appeared that no + nextval() had been done, thus allowing the first + sequence value to be returned again by the next + nextval() call. In particular this could manifest for + serial columns, since creation of a serial column's sequence + includes an ALTER SEQUENCE OWNED BY step. +

  • Fix txid_current() to report the correct epoch when not + in hot standby (Heikki Linnakangas) +

    This fixes a regression introduced in the previous minor release. +

  • Fix bug in startup of Hot Standby when a master transaction has many + subtransactions (Andres Freund) +

    This mistake led to failures reported as "out-of-order XID + insertion in KnownAssignedXids". +

  • Ensure the backup_label file is fsync'd after + pg_start_backup() (Dave Kerr) +

  • Fix timeout handling in walsender processes (Tom Lane) +

    WAL sender background processes neglected to establish a + SIGALRM handler, meaning they would wait forever in + some corner cases where a timeout ought to happen. +

  • Back-patch 9.1 improvement to compress the fsync request queue + (Robert Haas) +

    This improves performance during checkpoints. The 9.1 change + has now seen enough field testing to seem safe to back-patch. +

  • Fix LISTEN/NOTIFY to cope better with I/O + problems, such as out of disk space (Tom Lane) +

    After a write failure, all subsequent attempts to send more + NOTIFY messages would fail with messages like + "Could not read from file "pg_notify/nnnn" at + offset nnnnn: Success". +

  • Only allow autovacuum to be auto-canceled by a directly blocked + process (Tom Lane) +

    The original coding could allow inconsistent behavior in some cases; + in particular, an autovacuum could get canceled after less than + deadlock_timeout grace period. +

  • Improve logging of autovacuum cancels (Robert Haas) +

  • Fix log collector so that log_truncate_on_rotation works + during the very first log rotation after server start (Tom Lane) +

  • Fix WITH attached to a nested set operation + (UNION/INTERSECT/EXCEPT) + (Tom Lane) +

  • Ensure that a whole-row reference to a subquery doesn't include any + extra GROUP BY or ORDER BY columns (Tom Lane) +

  • Disallow copying whole-row references in CHECK + constraints and index definitions during CREATE TABLE + (Tom Lane) +

    This situation can arise in CREATE TABLE with + LIKE or INHERITS. The copied whole-row + variable was incorrectly labeled with the row type of the original + table not the new one. Rejecting the case seems reasonable for + LIKE, since the row types might well diverge later. For + INHERITS we should ideally allow it, with an implicit + coercion to the parent table's row type; but that will require more + work than seems safe to back-patch. +

  • Fix memory leak in ARRAY(SELECT ...) subqueries (Heikki + Linnakangas, Tom Lane) +

  • Fix extraction of common prefixes from regular expressions (Tom Lane) +

    The code could get confused by quantified parenthesized + subexpressions, such as ^(foo)?bar. This would lead to + incorrect index optimization of searches for such patterns. +

  • Fix bugs with parsing signed + hh:mm and + hh:mm:ss + fields in interval constants (Amit Kapila, Tom Lane) +

  • Use Postgres' encoding conversion functions, not Python's, when + converting a Python Unicode string to the server encoding in + PL/Python (Jan Urbanski) +

    This avoids some corner-case problems, notably that Python doesn't + support all the encodings Postgres does. A notable functional change + is that if the server encoding is SQL_ASCII, you will get the UTF-8 + representation of the string; formerly, any non-ASCII characters in + the string would result in an error. +

  • Fix mapping of PostgreSQL encodings to Python encodings in PL/Python + (Jan Urbanski) +

  • Report errors properly in contrib/xml2's + xslt_process() (Tom Lane) +

  • Update time zone data files to tzdata release 2012e + for DST law changes in Morocco and Tokelau +


PrevHomeNext
Release 9.0.10UpRelease 9.0.8
\ No newline at end of file diff --git a/doc/src/sgml/html/release-9-0.html b/doc/src/sgml/html/release-9-0.html new file mode 100644 index 000000000..c5f04ab7f --- /dev/null +++ b/doc/src/sgml/html/release-9-0.html @@ -0,0 +1,5351 @@ + +Release 9.0

E.23. Release 9.0

Release Date: 2010-09-20

E.23.1. Overview

This release of + PostgreSQL adds features that have been requested + for years, such as easy-to-use replication, a mass permission-changing + facility, and anonymous code blocks. While past major releases have + been conservative in their scope, this release shows a + bold new desire to provide facilities that new and existing + users of PostgreSQL will embrace. This has all + been done with few incompatibilities. Major enhancements include: +

  • Built-in replication based on log shipping. This advance consists of + two features: Streaming Replication, allowing continuous archive + (WAL) files to be streamed over a network connection to a + standby server, and Hot Standby, allowing continuous archive standby + servers to execute read-only queries. The net effect is to support a + single master with multiple read-only slave servers. +

  • Easier database object permissions management. GRANT/REVOKE IN + SCHEMA supports mass permissions changes on existing objects, + while ALTER DEFAULT + PRIVILEGES allows control of privileges for objects created in + the future. Large objects (BLOBs) now support permissions management as + well. +

  • Broadly enhanced stored procedure support. + The DO statement supports + ad-hoc or "anonymous" code blocks. + Functions can now be called using named parameters. + PL/pgSQL is now installed by default, and + PL/Perl and PL/Python have been enhanced in several ways, + including support for Python3. +

  • Full support for 64-bit + Windows. +

  • More advanced reporting queries, including additional windowing options + (PRECEDING and FOLLOWING) and the ability to + control the order in which values are fed to aggregate functions. +

  • New trigger features, including + SQL-standard-compliant per-column triggers and + conditional trigger execution. +

  • Deferrable + unique constraints. Mass updates to unique keys are now possible + without trickery. +

  • Exclusion constraints. + These provide a generalized version of unique constraints, allowing + enforcement of complex conditions. +

  • New and enhanced security features, including RADIUS authentication, + LDAP authentication improvements, and a new contrib module + passwordcheck + for testing password strength. +

  • New high-performance implementation of the + LISTEN/NOTIFY feature. + Pending events are now stored in a memory-based queue rather than + a table. Also, a "payload" string can be sent with each + event, rather than transmitting just an event name as before. +

  • New implementation of + VACUUM FULL. + This command now rewrites the entire table and indexes, rather than + moving individual rows to compact space. It is substantially faster + in most cases, and no longer results in index bloat. +

  • New contrib module + pg_upgrade + to support in-place upgrades from 8.3 or 8.4 to 9.0. +

  • Multiple performance enhancements for specific types of queries, + including elimination of unnecessary joins. This helps optimize some + automatically-generated queries, such as those produced by + object-relational mappers (ORMs). +

  • EXPLAIN enhancements. + The output is now available in JSON, XML, or YAML format, and includes + buffer utilization and other data not previously available. +

  • hstore improvements, + including new functions and greater data capacity. +

The above items are explained in more detail in the sections below. +

E.23.2. Migration to Version 9.0

A dump/restore using pg_dump, + or use of pg_upgrade, is required + for those wishing to migrate data from any previous + release. +

Version 9.0 contains a number of changes that selectively break backwards + compatibility in order to support new features and code quality + improvements. In particular, users who make extensive use of PL/pgSQL, + Point-In-Time Recovery (PITR), or Warm Standby should test their + applications because of slight user-visible changes in those areas. + Observe the following incompatibilities: +

E.23.2.1. Server Settings

  • Remove server parameter add_missing_from, which was + defaulted to off for many years (Tom Lane) +

  • Remove server parameter regex_flavor, which + was defaulted to advanced + for many years (Tom Lane) +

  • archive_mode + now only affects archive_command; + a new setting, wal_level, affects + the contents of the write-ahead log (Heikki Linnakangas) +

  • log_temp_files + now uses default file size units of kilobytes (Robert Haas) +

E.23.2.2. Queries

  • When querying a parent table, + do not do any separate permission checks on child tables + scanned as part of the query (Peter Eisentraut) +

    The SQL standard specifies this behavior, and it is also much more + convenient in practice than the former behavior of checking permissions + on each child as well as the parent. +

E.23.2.3. Data Types

  • bytea output now + appears in hex format by default (Peter Eisentraut) +

    The server parameter bytea_output can be + used to select the traditional output format if needed for + compatibility. +

  • Array input now considers only plain ASCII whitespace characters + to be potentially ignorable; it will never ignore non-ASCII characters, + even if they are whitespace according to some locales (Tom Lane) +

    This avoids some corner cases where array values could be interpreted + differently depending on the server's locale settings. +

  • Improve standards compliance of SIMILAR TO + patterns and SQL-style substring() patterns (Tom Lane) +

    This includes treating ? and {...} as + pattern metacharacters, while they were simple literal characters + before; that corresponds to new features added in SQL:2008. + Also, ^ and $ are now treated as simple + literal characters; formerly they were treated as metacharacters, + as if the pattern were following POSIX rather than SQL rules. + Also, in SQL-standard substring(), use of parentheses + for nesting no longer interferes with capturing of a substring. + Also, processing of bracket expressions (character classes) is + now more standards-compliant. +

  • Reject negative length values in 3-parameter substring() + for bit strings, per the SQL standard (Tom Lane) +

  • Make date_trunc truncate rather than round when reducing + precision of fractional seconds (Tom Lane) +

    The code always acted this way for integer-based dates/times. + Now float-based dates/times behave similarly. +

E.23.2.4. Object Renaming

  • Tighten enforcement of column name consistency during RENAME + when a child table inherits the same column from multiple unrelated + parents (KaiGai Kohei) +

  • No longer automatically rename indexes and index columns when the + underlying table columns are renamed (Tom Lane) +

    Administrators can still rename such indexes and columns manually. + This change will require an update of the JDBC driver, and possibly other + drivers, so that unique indexes are correctly recognized after a rename. +

  • CREATE OR REPLACE FUNCTION can no longer change + the declared names of function parameters (Pavel Stehule) +

    In order to avoid creating ambiguity in named-parameter calls, it is + no longer allowed to change the aliases for input parameters + in the declaration of an existing function (although names can still + be assigned to previously unnamed parameters). You now have to + DROP and recreate the function to do that. +

E.23.2.5. PL/pgSQL

  • PL/pgSQL now throws an error if a variable name conflicts with a + column name used in a query (Tom Lane) +

    The former behavior was to bind ambiguous names to PL/pgSQL variables + in preference to query columns, which often resulted in surprising + misbehavior. Throwing an error allows easy detection of ambiguous + situations. Although it's recommended that functions encountering this + type of error be modified to remove the conflict, the old behavior can + be restored if necessary via the configuration parameter plpgsql.variable_conflict, + or via the per-function option #variable_conflict. +

  • PL/pgSQL no longer allows variable names that match certain SQL + reserved words (Tom Lane) +

    This is a consequence of aligning the PL/pgSQL parser to match the + core SQL parser more closely. If necessary, + variable names can be double-quoted to avoid this restriction. +

  • PL/pgSQL now requires columns of composite results to match the + expected type modifier as well as base type (Pavel Stehule, Tom Lane) +

    For example, if a column of the result type is declared as + NUMERIC(30,2), it is no longer acceptable to return a + NUMERIC of some other precision in that column. Previous + versions neglected to check the type modifier and would thus allow + result rows that didn't actually conform to the declared restrictions. +

  • PL/pgSQL now treats selection into composite fields more consistently + (Tom Lane) +

    Formerly, a statement like + SELECT ... INTO rec.fld FROM ... + was treated as a scalar assignment even if the record field + fld was of composite type. Now it is treated as a + record assignment, the same as when the INTO target is a + regular variable of composite type. So the values to be assigned to the + field's subfields should be written as separate columns of the + SELECT list, not as a ROW(...) construct as in + previous versions. +

    If you need to do this in a way that will work in both 9.0 and previous + releases, you can write something like + rec.fld := ROW(...) FROM .... +

  • Remove PL/pgSQL's RENAME declaration (Tom Lane) +

    Instead of RENAME, use ALIAS, + which can now create an alias for any variable, not only dollar sign + parameter names (such as $1) as before. +

E.23.2.6. Other Incompatibilities

  • Deprecate use of => as an operator name (Robert Haas) +

    Future versions of PostgreSQL will probably reject + this operator name entirely, in order to support the SQL-standard + notation for named function parameters. For the moment, it is + still allowed, but a warning is emitted when such an operator is + defined. +

  • Remove support for platforms that don't have a working 64-bit + integer data type (Tom Lane) +

    It is believed all still-supported platforms have working 64-bit + integer data types. +

E.23.3. Changes

Version 9.0 has an unprecedented number of new major features, + and over 200 enhancements, improvements, new commands, + new functions, and other changes. +

E.23.3.1. Server

E.23.3.1.1. Continuous Archiving and Streaming Replication

PostgreSQL's existing standby-server capability has been expanded both to + support read-only queries on standby servers and to greatly reduce + the lag between master and standby servers. For many users, this + will be a useful and low-administration form of replication, either + for high availability or for horizontal scalability. +

  • Allow a standby server to accept read-only queries + (Simon Riggs, Heikki Linnakangas) +

    This feature is called Hot Standby. There are new + postgresql.conf and recovery.conf + settings to control this feature, as well as extensive + documentation. +

  • Allow write-ahead log (WAL) data to be streamed to a + standby server (Fujii Masao, Heikki Linnakangas) +

    This feature is called Streaming Replication. + Previously WAL data could be sent to standby servers only + in units of entire WAL files (normally 16 megabytes each). + Streaming Replication eliminates this inefficiency and allows updates + on the master to be propagated to standby servers with very little + delay. There are new postgresql.conf and + recovery.conf settings to control this feature, as well as + extensive documentation. +

  • Add pg_last_xlog_receive_location() + and pg_last_xlog_replay_location(), which + can be used to monitor standby server WAL + activity (Simon Riggs, Fujii Masao, Heikki Linnakangas) +

E.23.3.1.2. Performance

  • Allow per-tablespace values to be set for sequential and random page + cost estimates (seq_page_cost/random_page_cost) + via ALTER TABLESPACE + ... SET/RESET (Robert Haas) +

  • Improve performance and reliability of EvalPlanQual rechecks in join + queries (Tom Lane) +

    UPDATE, DELETE, and SELECT FOR + UPDATE/SHARE queries that involve joins will now behave much better + when encountering freshly-updated rows. +

  • Improve performance of TRUNCATE when + the table was created or truncated earlier in the same transaction + (Tom Lane) +

  • Improve performance of finding inheritance child tables (Tom Lane) +

E.23.3.1.3. Optimizer

  • Remove unnecessary outer + joins (Robert Haas) +

    Outer joins where the inner side is unique and not referenced above + the join are unnecessary and are therefore now removed. This will + accelerate many automatically generated queries, such as those created + by object-relational mappers (ORMs). +

  • Allow IS NOT NULL restrictions to use indexes (Tom Lane) +

    This is particularly useful for finding + MAX()/MIN() values in indexes that + contain many null values. +

  • Improve the optimizer's choices about when to use materialize nodes, + and when to use sorting versus hashing for DISTINCT + (Tom Lane) +

  • Improve the optimizer's equivalence detection for expressions involving + boolean <> operators (Tom Lane) +

E.23.3.1.4. GEQO

  • Use the same random seed every time GEQO plans a query (Andres + Freund) +

    While the Genetic Query Optimizer (GEQO) still selects + random plans, it now always selects the same random plans for identical + queries, thus giving more consistent performance. You can modify geqo_seed to experiment with + alternative plans. +

  • Improve GEQO plan selection (Tom Lane) +

    This avoids the rare error "failed to make a valid plan", + and should also improve planning speed. +

E.23.3.1.5. Optimizer Statistics

  • Improve ANALYZE + to support inheritance-tree statistics (Tom Lane) +

    This is particularly useful for partitioned tables. However, + autovacuum does not yet automatically re-analyze parent tables + when child tables change. +

  • Improve autovacuum's + detection of when re-analyze is necessary (Tom Lane) +

  • Improve optimizer's estimation for greater/less-than comparisons + (Tom Lane) +

    When looking up statistics for greater/less-than comparisons, + if the comparison value is in the first or last histogram bucket, + use an index (if available) to fetch the current actual column + minimum or maximum. This greatly improves the accuracy of estimates + for comparison values near the ends of the data range, particularly + if the range is constantly changing due to addition of new data. +

  • Allow setting of number-of-distinct-values statistics using ALTER TABLE + (Robert Haas) +

    This allows users to override the estimated number or percentage of + distinct values for a column. This statistic is normally computed by + ANALYZE, but the estimate can be poor, especially on tables + with very large numbers of rows. +

E.23.3.1.6. Authentication

  • Add support for RADIUS (Remote + Authentication Dial In User Service) authentication + (Magnus Hagander) +

  • Allow LDAP + (Lightweight Directory Access Protocol) authentication + to operate in "search/bind" mode + (Robert Fleming, Magnus Hagander) +

    This allows the user to be looked up first, then the system uses + the DN (Distinguished Name) returned for that user. +

  • Add samehost + and samenet designations to + pg_hba.conf (Stef Walter) +

    These match the server's IP address and subnet address + respectively. +

  • Pass trusted SSL root certificate names to the client so the client + can return an appropriate client certificate (Craig Ringer) +

E.23.3.1.7. Monitoring

  • Add the ability for clients to set an application + name, which is displayed in + pg_stat_activity (Dave Page) +

    This allows administrators to characterize database traffic + and troubleshoot problems by source application. +

  • Add a SQLSTATE option (%e) to log_line_prefix + (Guillaume Smet) +

    This allows users to compile statistics on errors and messages + by error code number. +

  • Write to the Windows event log in UTF16 encoding + (Itagaki Takahiro) +

    Now there is true multilingual support for PostgreSQL log messages + on Windows. +

E.23.3.1.8. Statistics Counters

E.23.3.1.9. Server Settings

  • Allow setting of configuration parameters based on database/role combinations + (Alvaro Herrera) +

    Previously only per-database and per-role settings were possible, + not combinations. All role and database settings are now stored + in the new pg_db_role_setting system catalog. A new + psql command \drds shows these settings. + The legacy system views pg_roles, + pg_shadow, and pg_user + do not show combination settings, and therefore no longer + completely represent the configuration for a user or database. +

  • Add server parameter bonjour, which + controls whether a Bonjour-enabled server advertises + itself via Bonjour (Tom Lane) +

    The default is off, meaning it does not advertise. This allows + packagers to distribute Bonjour-enabled builds without worrying + that individual users might not want the feature. +

  • Add server parameter enable_material, which + controls the use of materialize nodes in the optimizer + (Robert Haas) +

    The default is on. When off, the optimizer will not add + materialize nodes purely for performance reasons, though they + will still be used when necessary for correctness. +

  • Change server parameter log_temp_files to + use default file size units of kilobytes (Robert Haas) +

    Previously this setting was interpreted in bytes if no units were + specified. +

  • Log changes of parameter values when postgresql.conf is + reloaded (Peter Eisentraut) +

    This lets administrators and security staff audit changes of database + settings, and is also very convenient for checking the effects of + postgresql.conf edits. +

  • Properly enforce superuser permissions for custom server parameters + (Tom Lane) +

    Non-superusers can no longer issue ALTER + ROLE/DATABASE SET for parameters that are not currently + known to the server. This allows the server to correctly check that + superuser-only parameters are only set by superusers. Previously, + the SET would be allowed and then ignored at session start, + making superuser-only custom parameters much less useful than they + should be. +

E.23.3.2. Queries

  • Perform SELECT + FOR UPDATE/SHARE processing after + applying LIMIT, so the number of rows returned + is always predictable (Tom Lane) +

    Previously, changes made by concurrent transactions could cause a + SELECT FOR UPDATE to unexpectedly return fewer rows than + specified by its LIMIT. FOR UPDATE in combination + with ORDER BY can still produce surprising results, but that + can be corrected by placing FOR UPDATE in a subquery. +

  • Allow mixing of traditional and SQL-standard LIMIT/OFFSET + syntax (Tom Lane) +

  • Extend the supported frame options in window functions (Hitoshi + Harada) +

    Frames can now start with CURRENT ROW, and the ROWS + n PRECEDING/FOLLOWING options are now + supported. +

  • Make SELECT INTO and CREATE TABLE AS return + row counts to the client in their command tags + (Boszormenyi Zoltan) +

    This can save an entire round-trip to the client, allowing result counts + and pagination to be calculated without an additional + COUNT query. +

E.23.3.2.1. Unicode Strings

  • Support Unicode surrogate pairs (dual 16-bit representation) in + U& + strings and identifiers (Peter Eisentraut) +

  • Support Unicode escapes in E'...' + strings (Marko Kreen) +

E.23.3.3. Object Manipulation

  • Speed up CREATE + DATABASE by deferring flushes to disk (Andres + Freund, Greg Stark) +

  • Allow comments on + columns of tables, views, and composite types only, not other + relation types such as indexes and TOAST tables (Tom Lane) +

  • Allow the creation of enumerated types containing + no values (Bruce Momjian) +

  • Let values of columns having storage type MAIN remain on + the main heap page unless the row cannot fit on a page (Kevin Grittner) +

    Previously MAIN values were forced out to TOAST + tables until the row size was less than one-quarter of the page size. +

E.23.3.3.1. ALTER TABLE

  • Implement IF EXISTS for ALTER TABLE DROP COLUMN + and ALTER TABLE DROP CONSTRAINT (Andres Freund) +

  • Allow ALTER TABLE commands that rewrite tables to skip + WAL logging (Itagaki Takahiro) +

    Such operations either produce a new copy of the table or are rolled + back, so WAL archiving can be skipped, unless running in + continuous archiving mode. This reduces I/O overhead and improves + performance. +

  • Fix failure of ALTER TABLE table ADD COLUMN + col serial when done by non-owner of table + (Tom Lane) +

E.23.3.3.2. CREATE TABLE

  • Add support for copying COMMENTS and STORAGE + settings in CREATE TABLE ... LIKE commands + (Itagaki Takahiro) +

  • Add a shortcut for copying all properties in CREATE + TABLE ... LIKE commands (Itagaki Takahiro) +

  • Add the SQL-standard + CREATE TABLE ... OF type command + (Peter Eisentraut) +

    This allows creation of a table that matches an existing composite + type. Additional constraints and defaults can be specified in the + command. +

E.23.3.3.3. Constraints

  • Add deferrable + unique constraints (Dean Rasheed) +

    This allows mass updates, such as + UPDATE tab SET col = col + 1, + to work reliably + on columns that have unique indexes or are marked as primary keys. + If the constraint is specified as DEFERRABLE it will be + checked at the end of the statement, rather than after each row is + updated. The constraint check can also be deferred until the end of the + current transaction, allowing such updates to be spread over multiple + SQL commands. +

  • Add + exclusion constraints + (Jeff Davis) +

    Exclusion constraints generalize uniqueness constraints by allowing + arbitrary comparison operators, not just equality. They are created + with the CREATE + TABLE CONSTRAINT ... EXCLUDE clause. + The most common use of exclusion constraints is to specify that column + entries must not overlap, rather than simply not be equal. This is + useful for time periods and other ranges, as well as arrays. + This feature enhances checking of data integrity for many + calendaring, time-management, and scientific applications. +

  • Improve uniqueness-constraint violation error messages to + report the values causing the failure (Itagaki Takahiro) +

    For example, a uniqueness constraint violation might now report + Key (x)=(2) already exists. +

E.23.3.3.4. Object Permissions

  • Add the ability to make mass permission changes across a whole + schema using the new GRANT/REVOKE + IN SCHEMA clause (Petr Jelinek) +

    This simplifies management of object permissions + and makes it easier to utilize database roles for application + data security. +

  • Add ALTER + DEFAULT PRIVILEGES command to control privileges + of objects created later (Petr Jelinek) +

    This greatly simplifies the assignment of object privileges in a + complex database application. Default privileges can be set for + tables, views, sequences, and functions. Defaults may be assigned on a + per-schema basis, or database-wide. +

  • Add the ability to control large object (BLOB) permissions with + GRANT/REVOKE (KaiGai Kohei) +

    Formerly, any database user could read or modify any large object. + Read and write permissions can now be granted and revoked per + large object, and the ownership of large objects is tracked. +

E.23.3.4. Utility Operations

  • Make LISTEN/NOTIFY store pending events + in a memory queue, rather than in a system table (Joachim + Wieland) +

    This substantially improves performance, while retaining the existing + features of transactional support and guaranteed delivery. +

  • Allow NOTIFY + to pass an optional "payload" string to listeners + (Joachim Wieland) +

    This greatly improves the usefulness of + LISTEN/NOTIFY as a + general-purpose event queue system. +

  • Allow CLUSTER + on all per-database system catalogs (Tom Lane) +

    Shared catalogs still cannot be clustered. +

E.23.3.4.1. COPY

  • Accept COPY ... CSV FORCE QUOTE * + (Itagaki Takahiro) +

    Now * can be used as shorthand for "all columns" + in the FORCE QUOTE clause. +

  • Add new COPY syntax that allows options to be + specified inside parentheses (Robert Haas, Emmanuel Cecchet) +

    This allows greater flexibility for future COPY options. + The old syntax is still supported, but only for pre-existing options. +

E.23.3.4.2. EXPLAIN

  • Allow EXPLAIN to output in XML, + JSON, or YAML format (Robert Haas, Greg + Sabino Mullane) +

    The new output formats are easily machine-readable, supporting the + development of new tools for analysis of EXPLAIN output. +

  • Add new BUFFERS option to report query + buffer usage during EXPLAIN ANALYZE (Itagaki Takahiro) +

    This allows better query profiling for individual queries. + Buffer usage is no longer reported in the output for log_statement_stats + and related settings. +

  • Add hash usage information to EXPLAIN output (Robert + Haas) +

  • Add new EXPLAIN syntax that allows options to be + specified inside parentheses (Robert Haas) +

    This allows greater flexibility for future EXPLAIN options. + The old syntax is still supported, but only for pre-existing options. +

E.23.3.4.3. VACUUM

  • Change VACUUM FULL to rewrite the entire table and + rebuild its indexes, rather than moving individual rows around to + compact space (Itagaki Takahiro, Tom Lane) +

    The previous method was usually slower and caused index bloat. + Note that the new method will use more disk space transiently + during VACUUM FULL; potentially as much as twice + the space normally occupied by the table and its indexes. +

  • Add new VACUUM syntax that allows options to be + specified inside parentheses (Itagaki Takahiro) +

    This allows greater flexibility for future VACUUM options. + The old syntax is still supported, but only for pre-existing options. +

E.23.3.4.4. Indexes

  • Allow an index to be named automatically by omitting the index name in + CREATE INDEX + (Tom Lane) +

  • By default, multicolumn indexes are now named after all their columns; + and index expression columns are now named based on their expressions + (Tom Lane) +

  • Reindexing shared system catalogs is now fully transactional + and crash-safe (Tom Lane) +

    Formerly, reindexing a shared index was only allowed in standalone + mode, and a crash during the operation could leave the index in + worse condition than it was before. +

  • Add point_ops operator class for GiST + (Teodor Sigaev) +

    This feature permits GiST indexing of point + columns. The index can be used for several types of queries + such as point <@ polygon + (point is in polygon). This should make many + PostGIS queries faster. +

  • Use red-black binary trees for GIN index creation + (Teodor Sigaev) +

    Red-black trees are self-balancing. This avoids slowdowns in + cases where the input is in nonrandom order. +

E.23.3.5. Data Types

  • Allow bytea values + to be written in hex notation (Peter Eisentraut) +

    The server parameter bytea_output controls + whether hex or traditional format is used for bytea + output. Libpq's PQescapeByteaConn() function automatically + uses the hex format when connected to PostgreSQL 9.0 + or newer servers. However, pre-9.0 libpq versions will not + correctly process hex format from newer servers. +

    The new hex format will be directly compatible with more applications + that use binary data, allowing them to store and retrieve it without + extra conversion. It is also significantly faster to read and write + than the traditional format. +

  • Allow server parameter extra_float_digits + to be increased to 3 (Tom Lane) +

    The previous maximum extra_float_digits setting was + 2. There are cases where 3 digits are needed to dump and + restore float4 values exactly. pg_dump will + now use the setting of 3 when dumping from a server that allows it. +

  • Tighten input checking for int2vector values (Caleb + Welton) +

E.23.3.5.1. Full Text Search

  • Add prefix support in synonym dictionaries + (Teodor Sigaev) +

  • Add filtering dictionaries (Teodor Sigaev) +

    Filtering dictionaries allow tokens to be modified then passed to + subsequent dictionaries. +

  • Allow underscores in email-address tokens (Teodor Sigaev) +

  • Use more standards-compliant rules for parsing URL tokens + (Tom Lane) +

E.23.3.6. Functions

  • Allow function calls to supply parameter names and match them to named + parameters in the function definition (Pavel Stehule) +

    For example, if a function is defined to take parameters a + and b, it can be called with func(a := 7, b + := 12) or func(b := 12, a := 7). +

  • Support locale-specific regular expression + processing with UTF-8 server encoding (Tom Lane) +

    Locale-specific regular expression functionality includes + case-insensitive matching and locale-specific character classes. + Previously, these features worked correctly for non-ASCII + characters only if the database used a single-byte server encoding (such + as LATIN1). They will still misbehave in multi-byte encodings other + than UTF-8. +

  • Add support for scientific notation in to_char() + (EEEE + specification) + (Pavel Stehule, Brendan Jurd) +

  • Make to_char() honor FM + (fill mode) in Y, YY, and + YYY specifications (Bruce Momjian, Tom Lane) +

    It was already honored by YYYY. +

  • Fix to_char() to output localized numeric and monetary + strings in the correct encoding on Windows + (Hiroshi Inoue, Itagaki Takahiro, Bruce Momjian) +

  • Correct calculations of "overlaps" + and "contains" operations for polygons (Teodor Sigaev) +

    The polygon && (overlaps) operator formerly just + checked to see if the two polygons' bounding boxes overlapped. It now + does a more correct check. The polygon @> and + <@ (contains/contained by) operators formerly checked + to see if one polygon's vertexes were all contained in the other; + this can wrongly report "true" for some non-convex polygons. + Now they check that all line segments of one polygon are contained in + the other. +

E.23.3.6.1. Aggregates

  • Allow aggregate functions to use ORDER BY (Andrew Gierth) +

    For example, this is now supported: array_agg(a ORDER BY + b). This is useful with aggregates for which the order of input + values is significant, and eliminates the need to use a nonstandard + subquery to determine the ordering. +

  • Multi-argument aggregate functions can now use DISTINCT + (Andrew Gierth) +

  • Add the string_agg() + aggregate function to combine values into a single + string (Pavel Stehule) +

  • Aggregate functions that are called with DISTINCT are + now passed NULL values if the aggregate transition function is + not marked as STRICT (Andrew Gierth) +

    For example, agg(DISTINCT x) might pass a NULL x + value to agg(). This is more consistent with the behavior + in non-DISTINCT cases. +

E.23.3.6.2. Bit Strings

  • Add get_bit() + and set_bit() functions for bit + strings, mirroring those for bytea (Leonardo + F) +

  • Implement OVERLAY() + (replace) for bit strings and bytea + (Leonardo F) +

E.23.3.6.3. Object Information Functions

  • Add pg_table_size() + and pg_indexes_size() to provide a more + user-friendly interface to the pg_relation_size() + function (Bernd Helmle) +

  • Add has_sequence_privilege() + for sequence permission checking (Abhijit Menon-Sen) +

  • Update the information_schema + views to conform to SQL:2008 + (Peter Eisentraut) +

  • Make the information_schema views correctly display maximum + octet lengths for char and varchar columns (Peter + Eisentraut) +

  • Speed up information_schema privilege views + (Joachim Wieland) +

E.23.3.6.4. Function and Trigger Creation

  • Support execution of anonymous code blocks using the DO statement + (Petr Jelinek, Joshua Tolley, Hannu Valtonen) +

    This allows execution of server-side code without the need to create + and delete a temporary function definition. Code can be executed in + any language for which the user has permissions to define a function. +

  • Implement SQL-standard-compliant per-column triggers + (Itagaki Takahiro) +

    Such triggers are fired only when the specified column(s) are affected + by the query, e.g. appear in an UPDATE's SET + list. +

  • Add the WHEN clause to CREATE TRIGGER + to allow control over whether a trigger is fired (Itagaki + Takahiro) +

    While the same type of check can always be performed inside the + trigger, doing it in an external WHEN clause can have + performance benefits. +

E.23.3.7. Server-Side Languages

  • Add the OR REPLACE clause to CREATE LANGUAGE + (Tom Lane) +

    This is helpful to optionally install a language if it does not + already exist, and is particularly helpful now that PL/pgSQL is + installed by default. +

E.23.3.7.1. PL/pgSQL Server-Side + Language

  • Install PL/pgSQL by default (Bruce Momjian) +

    The language can still be removed from a particular database if the + administrator has security or performance concerns about making it + available. +

  • Improve handling of cases where PL/pgSQL variable names conflict with + identifiers used in queries within a function + (Tom Lane) +

    The default behavior is now to throw an error when there is a conflict, + so as to avoid surprising behaviors. This can be modified, via the + configuration parameter plpgsql.variable_conflict + or the per-function option #variable_conflict, to allow + either the variable or the query-supplied column to be used. In any + case PL/pgSQL will no longer attempt to substitute variables in places + where they would not be syntactically valid. +

  • Make PL/pgSQL use the main lexer, rather than its own version + (Tom Lane) +

    This ensures accurate tracking of the main system's behavior for details + such as string escaping. Some user-visible details, such as the set + of keywords considered reserved in PL/pgSQL, have changed in + consequence. +

  • Avoid throwing an unnecessary error for an invalid record reference + (Tom Lane) +

    An error is now thrown only if the reference is actually fetched, + rather than whenever the enclosing expression is reached. For + example, many people have tried to do this in triggers: +

    if TG_OP = 'INSERT' and NEW.col1 = ... then

    + This will now actually work as expected. +

  • Improve PL/pgSQL's ability to handle row types with dropped columns + (Pavel Stehule) +

  • Allow input parameters to be assigned values within + PL/pgSQL functions (Steve Prentice) +

    Formerly, input parameters were treated as being declared + CONST, so the function's code could not change their + values. This restriction has been removed to simplify + porting of functions from other DBMSes that do not impose the + equivalent restriction. An input parameter now acts like a local + variable initialized to the passed-in value. +

  • Improve error location reporting in PL/pgSQL (Tom Lane) +

  • Add count and ALL options to MOVE + FORWARD/BACKWARD in PL/pgSQL (Pavel Stehule) +

  • Allow PL/pgSQL's WHERE CURRENT OF to use a cursor + variable (Tom Lane) +

  • Allow PL/pgSQL's OPEN cursor FOR EXECUTE to + use parameters (Pavel Stehule, Itagaki Takahiro) +

    This is accomplished with a new USING clause. +

E.23.3.7.2. PL/Perl Server-Side Language

  • Add new PL/Perl functions: quote_literal(), + quote_nullable(), quote_ident(), + encode_bytea(), decode_bytea(), + looks_like_number(), + encode_array_literal(), + encode_array_constructor() (Tim Bunce) +

  • Add server parameter plperl.on_init to + specify a PL/Perl initialization function (Tim + Bunce) +

    plperl.on_plperl_init + and plperl.on_plperlu_init + are also available for initialization that is specific to the trusted + or untrusted language respectively. +

  • Support END blocks in PL/Perl (Tim Bunce) +

    END blocks do not currently allow database access. +

  • Allow use strict in PL/Perl (Tim Bunce) +

    Perl strict checks can also be globally enabled with the + new server parameter plperl.use_strict. +

  • Allow require in PL/Perl (Tim Bunce) +

    This basically tests to see if the module is loaded, and if not, + generates an error. It will not allow loading of modules that + the administrator has not preloaded via the initialization parameters. +

  • Allow use feature in PL/Perl if Perl version 5.10 or + later is used (Tim Bunce) +

  • Verify that PL/Perl return values are valid in the server encoding + (Andrew Dunstan) +

E.23.3.7.3. PL/Python Server-Side Language

  • Add Unicode support in PL/Python (Peter Eisentraut) +

    Strings are automatically converted from/to the server encoding as + necessary. +

  • Improve bytea support in PL/Python (Caleb Welton) +

    Bytea values passed into PL/Python are now represented as + binary, rather than the PostgreSQL bytea text format. + Bytea values containing null bytes are now also output + properly from PL/Python. Passing of boolean, integer, and float + values was also improved. +

  • Support arrays as parameters and + return values in PL/Python (Peter Eisentraut) +

  • Improve mapping of SQL domains to Python types (Peter Eisentraut) +

  • Add Python 3 support to PL/Python (Peter Eisentraut) +

    The new server-side language is called plpython3u. This + cannot be used in the same session with the + Python 2 server-side language. +

  • Improve error location and exception reporting in PL/Python (Peter Eisentraut) +

E.23.3.8. Client Applications

  • Add an --analyze-only option to vacuumdb, to analyze without + vacuuming (Bruce Momjian) +

E.23.3.8.1. psql

  • Add support for quoting/escaping the values of psql + variables as SQL strings or + identifiers (Pavel Stehule, Robert Haas) +

    For example, :'var' will produce the value of + var quoted and properly escaped as a literal string, while + :"var" will produce its value quoted and escaped as an + identifier. +

  • Ignore a leading UTF-8-encoded Unicode byte-order marker in + script files read by psql (Itagaki Takahiro) +

    This is enabled when the client encoding is UTF-8. + It improves compatibility with certain editors, mostly on Windows, + that insist on inserting such markers. +

  • Fix psql --file - to properly honor --single-transaction + (Bruce Momjian) +

  • Avoid overwriting of psql's command-line history when + two psql sessions are run concurrently (Tom Lane) +

  • Improve psql's tab completion support (Itagaki + Takahiro) +

  • Show \timing output when it is enabled, regardless of + "quiet" mode (Peter Eisentraut) +

E.23.3.8.1.1. psql Display

  • Improve display of wrapped columns in psql (Roger + Leigh) +

    This behavior is now the default. + The previous formatting is available by using \pset linestyle + old-ascii. +

  • Allow psql to use fancy Unicode line-drawing + characters via \pset linestyle unicode (Roger Leigh) +

E.23.3.8.1.2. psql \d + Commands

  • Make \d show child tables that inherit from the specified + parent (Damien Clochard) +

    \d shows only the number of child tables, while + \d+ shows the names of all child tables. +

  • Show definitions of index columns in \d index_name + (Khee Chin) +

    The definition is useful for expression indexes. +

  • Show a view's defining query only in + \d+, not in \d (Peter Eisentraut) +

    Always including the query was deemed overly verbose. +

E.23.3.8.2. pg_dump

  • Make pg_dump/pg_restore + --clean + also remove large objects (Itagaki Takahiro) +

  • Fix pg_dump to properly dump large objects when + standard_conforming_strings is enabled (Tom Lane) +

    The previous coding could fail when dumping to an archive file + and then generating script output from pg_restore. +

  • pg_restore now emits large-object data in hex format + when generating script output (Tom Lane) +

    This could cause compatibility problems if the script is then + loaded into a pre-9.0 server. To work around that, restore + directly to the server, instead. +

  • Allow pg_dump to dump comments attached to columns + of composite types (Taro Minowa (Higepon)) +

  • Make pg_dump --verbose + output the pg_dump and server versions + in text output mode (Jim Cox, Tom Lane) +

    These were already provided in custom output mode. +

  • pg_restore now complains if any command-line arguments + remain after the switches and optional file name (Tom Lane) +

    Previously, it silently ignored any such arguments. +

E.23.3.8.3. pg_ctl

  • Allow pg_ctl to be used safely to start the + postmaster during a system reboot (Tom Lane) +

    Previously, pg_ctl's parent process could have been + mistakenly identified as a running postmaster based on + a stale postmaster lock file, resulting in a transient + failure to start the database. +

  • Give pg_ctl the ability to initialize the database + (by invoking initdb) (Zdenek Kotala) +

E.23.3.9. Development Tools

E.23.3.9.1. libpq

  • Add new libpq functions + PQconnectdbParams() + and PQconnectStartParams() (Guillaume + Lelarge) +

    These functions are similar to PQconnectdb() and + PQconnectStart() except that they accept a null-terminated + array of connection options, rather than requiring all options to + be provided in a single string. +

  • Add libpq functions PQescapeLiteral() + and PQescapeIdentifier() (Robert Haas) +

    These functions return appropriately quoted and escaped SQL string + literals and identifiers. The caller is not required to pre-allocate + the string result, as is required by PQescapeStringConn(). +

  • Add support for a per-user service file (.pg_service.conf), + which is checked before the site-wide service file + (Peter Eisentraut) +

  • Properly report an error if the specified libpq service + cannot be found (Peter Eisentraut) +

  • Add TCP keepalive settings + in libpq (Tollef Fog Heen, Fujii Masao, Robert Haas) +

    Keepalive settings were already supported on the server end of + TCP connections. +

  • Avoid extra system calls to block and unblock SIGPIPE + in libpq, on platforms that offer alternative methods + (Jeremy Kerr) +

  • When a .pgpass-supplied + password fails, mention where the password came from in the error + message (Bruce Momjian) +

  • Load all SSL certificates given in the client certificate file + (Tom Lane) +

    This improves support for indirectly-signed SSL certificates. +

E.23.3.9.2. ecpg

  • Add SQLDA + (SQL Descriptor Area) support to ecpg + (Boszormenyi Zoltan) +

  • Add the DESCRIBE + [ OUTPUT ] statement to ecpg + (Boszormenyi Zoltan) +

  • Add an ECPGtransactionStatus + function to return the current transaction status (Bernd Helmle) +

  • Add the string data type in ecpg + Informix-compatibility mode (Boszormenyi Zoltan) +

  • Allow ecpg to use new and old + variable names without restriction (Michael Meskes) +

  • Allow ecpg to use variable names in + free() (Michael Meskes) +

  • Make ecpg_dynamic_type() return zero for non-SQL3 data + types (Michael Meskes) +

    Previously it returned the negative of the data type OID. + This could be confused with valid type OIDs, however. +

  • Support long long types on platforms that already have 64-bit + long (Michael Meskes) +

E.23.3.9.2.1. ecpg Cursors

  • Add out-of-scope cursor support in ecpg's native mode + (Boszormenyi Zoltan) +

    This allows DECLARE to use variables that are not in + scope when OPEN is called. This facility already existed + in ecpg's Informix-compatibility mode. +

  • Allow dynamic cursor names in ecpg (Boszormenyi Zoltan) +

  • Allow ecpg to use noise words FROM and + IN in FETCH and MOVE (Boszormenyi + Zoltan) +

E.23.3.10. Build Options

  • Enable client thread safety by default (Bruce Momjian) +

    The thread-safety option can be disabled with configure + --disable-thread-safety. +

  • Add support for controlling the Linux out-of-memory killer + (Alex Hunsaker, Tom Lane) +

    Now that /proc/self/oom_adj allows disabling + of the Linux out-of-memory (OOM) + killer, it's recommendable to disable OOM kills for the postmaster. + It may then be desirable to re-enable OOM kills for the postmaster's + child processes. The new compile-time option LINUX_OOM_ADJ + allows the killer to be reactivated for child processes. +

E.23.3.10.1. Makefiles

  • New Makefile targets world, + install-world, and installcheck-world + (Andrew Dunstan) +

    These are similar to the existing all, install, + and installcheck targets, but they also build the + HTML documentation, build and test contrib, + and test server-side languages and ecpg. +

  • Add data and documentation installation location control to + PGXS Makefiles (Mark Cave-Ayland) +

  • Add Makefile rules to build the PostgreSQL documentation + as a single HTML file or as a single plain-text file + (Peter Eisentraut, Bruce Momjian) +

E.23.3.10.2. Windows

  • Support compiling on 64-bit + Windows and running in 64-bit + mode (Tsutomu Yamada, Magnus Hagander) +

    This allows for large shared memory sizes on Windows. +

  • Support server builds using Visual Studio + 2008 (Magnus Hagander) +

E.23.3.11. Source Code

  • Distribute prebuilt documentation in a subdirectory tree, rather than + as tar archive files inside the distribution tarball + (Peter Eisentraut) +

    For example, the prebuilt HTML documentation is now in + doc/src/sgml/html/; the manual pages are packaged + similarly. +

  • Make the server's lexer reentrant (Tom Lane) +

    This was needed for use of the lexer by PL/pgSQL. +

  • Improve speed of memory allocation (Tom Lane, Greg Stark) +

  • User-defined constraint triggers now have entries in + pg_constraint as well as pg_trigger + (Tom Lane) +

    Because of this change, + pg_constraint.pgconstrname is now + redundant and has been removed. +

  • Add system catalog columns + pg_constraint.conindid and + pg_trigger.tgconstrindid + to better document the use of indexes for constraint + enforcement (Tom Lane) +

  • Allow multiple conditions to be communicated to backends using a single + operating system signal (Fujii Masao) +

    This allows new features to be added without a platform-specific + constraint on the number of signal conditions. +

  • Improve source code test coverage, including contrib, PL/Python, + and PL/Perl (Peter Eisentraut, Andrew Dunstan) +

  • Remove the use of flat files for system table bootstrapping + (Tom Lane, Alvaro Herrera) +

    This improves performance when using many roles or + databases, and eliminates some possible failure conditions. +

  • Automatically generate the initial contents of + pg_attribute for "bootstrapped" catalogs + (John Naylor) +

    This greatly simplifies changes to these catalogs. +

  • Split the processing of + INSERT/UPDATE/DELETE operations out + of execMain.c (Marko Tiikkaja) +

    Updates are now executed in a separate ModifyTable node. This change is + necessary infrastructure for future improvements. +

  • Simplify translation of psql's SQL help text + (Peter Eisentraut) +

  • Reduce the lengths of some file names so that all file paths in the + distribution tarball are less than 100 characters (Tom Lane) +

    Some decompression programs have problems with longer file paths. +

  • Add a new ERRCODE_INVALID_PASSWORD + SQLSTATE error code (Bruce Momjian) +

  • With authors' permissions, remove the few remaining personal source code + copyright notices (Bruce Momjian) +

    The personal copyright notices were insignificant but the community + occasionally had to answer questions about them. +

  • Add new documentation section + about running PostgreSQL in non-durable mode + to improve performance (Bruce Momjian) +

  • Restructure the HTML documentation + Makefile rules to make their dependency checks work + correctly, avoiding unnecessary rebuilds (Peter Eisentraut) +

  • Use DocBook XSL stylesheets for man page + building, rather than Docbook2X (Peter Eisentraut) +

    This changes the set of tools needed to build the man pages. +

  • Improve PL/Perl code structure (Tim Bunce) +

  • Improve error context reports in PL/Perl (Alexey Klyukin) +

E.23.3.11.1. New Build Requirements

Note that these requirements do not apply when building from a + distribution tarball, since tarballs include the files that these + programs are used to build. +

  • Require Autoconf 2.63 to build + configure (Peter Eisentraut) +

  • Require Flex 2.5.31 or later to build + from a CVS checkout (Tom Lane) +

  • Require Perl version 5.8 or later to build + from a CVS checkout (John Naylor, Andrew Dunstan) +

E.23.3.11.2. Portability

  • Use a more modern API for Bonjour (Tom Lane) +

    Bonjour support now requires OS X 10.3 or later. + The older API has been deprecated by Apple. +

  • Add spinlock support for the SuperH + architecture (Nobuhiro Iwamatsu) +

  • Allow non-GCC compilers to use inline functions if + they support them (Kurt Harriman) +

  • Remove support for platforms that don't have a working 64-bit + integer data type (Tom Lane) +

  • Restructure use of LDFLAGS to be more consistent + across platforms (Tom Lane) +

    LDFLAGS is now used for linking both executables and shared + libraries, and we add on LDFLAGS_EX when linking + executables, or LDFLAGS_SL when linking shared libraries. +

E.23.3.11.3. Server Programming

  • Make backend header files safe to include in C++ + (Kurt Harriman, Peter Eisentraut) +

    These changes remove keyword conflicts that previously made + C++ usage difficult in backend code. However, there + are still other complexities when using C++ for backend + functions. extern "C" { } is still necessary in + appropriate places, and memory management and error handling are + still problematic. +

  • Add AggCheckCallContext() + for use in detecting if a C function is + being called as an aggregate (Hitoshi Harada) +

  • Change calling convention for SearchSysCache() and related + functions to avoid hard-wiring the maximum number of cache keys + (Robert Haas) +

    Existing calls will still work for the moment, but can be expected to + break in 9.1 or later if not converted to the new style. +

  • Require calls of fastgetattr() and + heap_getattr() backend macros to provide a non-NULL fourth + argument (Robert Haas) +

  • Custom typanalyze functions should no longer rely on + VacAttrStats.attr to determine the type + of data they will be passed (Tom Lane) +

    This was changed to allow collection of statistics on index columns + for which the storage type is different from the underlying column + data type. There are new fields that tell the actual datatype being + analyzed. +

E.23.3.11.4. Server Hooks

  • Add parser hooks for processing ColumnRef and ParamRef nodes + (Tom Lane) +

  • Add a ProcessUtility hook so loadable modules can control utility + commands (Itagaki Takahiro) +

E.23.3.11.5. Binary Upgrade Support

  • Add contrib/pg_upgrade + to support in-place upgrades (Bruce Momjian) +

    This avoids the requirement of dumping/reloading the database when + upgrading to a new major release of PostgreSQL, thus reducing downtime + by orders of magnitude. It supports upgrades to 9.0 + from PostgreSQL 8.3 and 8.4. +

  • Add support for preserving relation relfilenode values + during binary upgrades (Bruce Momjian) +

  • Add support for preserving pg_type + and pg_enum OIDs during binary upgrades + (Bruce Momjian) +

  • Move data files within tablespaces into + PostgreSQL-version-specific subdirectories + (Bruce Momjian) +

    This simplifies binary upgrades. +

E.23.3.12. Contrib

  • Add multithreading option (-j) to contrib/pgbench + (Itagaki Takahiro) +

    This allows multiple CPUs to be used by pgbench, + reducing the risk of pgbench itself becoming the test bottleneck. +

  • Add \shell and \setshell meta + commands to contrib/pgbench + (Michael Paquier) +

  • New features for contrib/dict_xsyn + (Sergey Karpov) +

    The new options are matchorig, matchsynonyms, + and keepsynonyms. +

  • Add full text dictionary contrib/unaccent + (Teodor Sigaev) +

    This filtering dictionary removes accents from letters, which + makes full-text searches over multiple languages much easier. +

  • Add dblink_get_notify() + to contrib/dblink (Marcus Kempe) +

    This allows asynchronous notifications in dblink. +

  • Improve contrib/dblink's handling of dropped columns + (Tom Lane) +

    This affects dblink_build_sql_insert() + and related functions. These functions now number columns according + to logical not physical column numbers. +

  • Greatly increase contrib/hstore's data + length limit, and add B-tree and hash support so GROUP + BY and DISTINCT operations are possible on + hstore columns (Andrew Gierth) +

    New functions and operators were also added. These improvements + make hstore a full-function key-value store embedded in + PostgreSQL. +

  • Add contrib/passwordcheck + to support site-specific password strength policies (Laurenz + Albe) +

    The source code of this module should be modified to implement + site-specific password policies. +

  • Add contrib/pg_archivecleanup + tool (Simon Riggs) +

    This is designed to be used in the + archive_cleanup_command + server parameter, to remove no-longer-needed archive files. +

  • Add query text to contrib/auto_explain + output (Andrew Dunstan) +

  • Add buffer access counters to contrib/pg_stat_statements + (Itagaki Takahiro) +

  • Update contrib/start-scripts/linux + to use /proc/self/oom_adj to disable the + Linux + out-of-memory (OOM) killer (Alex + Hunsaker, Tom Lane) +


PrevHomeNext
Release 9.0.1UpRelease 8.4.15
\ No newline at end of file diff --git a/doc/src/sgml/html/release-9-1-1.html b/doc/src/sgml/html/release-9-1-1.html new file mode 100644 index 000000000..d7a849486 --- /dev/null +++ b/doc/src/sgml/html/release-9-1-1.html @@ -0,0 +1,244 @@ + +Release 9.1.1

E.10. Release 9.1.1

Release Date: 2011-09-26

This release contains a small number of fixes from 9.1.0. + For information about new features in the 9.1 major release, see + Section E.11. +

E.10.1. Migration to Version 9.1.1

A dump/restore is not required for those running 9.1.X. +

E.10.2. Changes

  • Make pg_options_to_table return NULL for an option with no + value (Tom Lane) +

    Previously such cases would result in a server crash. +

  • Fix memory leak at end of a GiST index scan (Tom Lane) +

    Commands that perform many separate GiST index scans, such as + verification of a new GiST-based exclusion constraint on a table + already containing many rows, could transiently require large amounts of + memory due to this leak. +

  • Fix explicit reference to pg_temp schema in CREATE + TEMPORARY TABLE (Robert Haas) +

    This used to be allowed, but failed in 9.1.0. +


PrevHomeNext
Release 9.1.2UpRelease 9.1
\ No newline at end of file diff --git a/doc/src/sgml/html/release-9-1-2.html b/doc/src/sgml/html/release-9-1-2.html new file mode 100644 index 000000000..7d896c389 --- /dev/null +++ b/doc/src/sgml/html/release-9-1-2.html @@ -0,0 +1,1029 @@ + +Release 9.1.2

E.9. Release 9.1.2

Release Date: 2011-12-05

This release contains a variety of fixes from 9.1.1. + For information about new features in the 9.1 major release, see + Section E.11. +

E.9.1. Migration to Version 9.1.2

A dump/restore is not required for those running 9.1.X. +

However, a longstanding error was discovered in the definition of the + information_schema.referential_constraints view. If you + rely on correct results from that view, you should replace its + definition as explained in the first changelog item below. +

Also, if you use the citext data type, and you upgraded + from a previous major release by running pg_upgrade, + you should run CREATE EXTENSION citext FROM unpackaged + to avoid collation-related failures in citext operations. + The same is necessary if you restore a dump from a pre-9.1 database + that contains an instance of the citext data type. + If you've already run the CREATE EXTENSION command before + upgrading to 9.1.2, you will instead need to do manual catalog updates + as explained in the second changelog item. +

E.9.2. Changes

  • Fix bugs in information_schema.referential_constraints view + (Tom Lane) +

    This view was being insufficiently careful about matching the + foreign-key constraint to the depended-on primary or unique key + constraint. That could result in failure to show a foreign key + constraint at all, or showing it multiple times, or claiming that it + depends on a different constraint than the one it really does. +

    Since the view definition is installed by initdb, + merely upgrading will not fix the problem. If you need to fix this + in an existing installation, you can (as a superuser) drop the + information_schema schema then re-create it by sourcing + SHAREDIR/information_schema.sql. + (Run pg_config --sharedir if you're uncertain where + SHAREDIR is.) This must be repeated in each database + to be fixed. +

  • Make contrib/citext's upgrade script fix collations of + citext columns and indexes (Tom Lane) +

    Existing citext columns and indexes aren't correctly marked as + being of a collatable data type during pg_upgrade from + a pre-9.1 server, or when a pre-9.1 dump containing the citext + type is loaded into a 9.1 server. + That leads to operations on these columns failing with errors + such as "could not determine which collation to use for string + comparison". This change allows them to be fixed by the same + script that upgrades the citext module into a proper 9.1 + extension during CREATE EXTENSION citext FROM unpackaged. +

    If you have a previously-upgraded database that is suffering from this + problem, and you already ran the CREATE EXTENSION command, + you can manually run (as superuser) the UPDATE commands + found at the end of + SHAREDIR/extension/citext--unpackaged--1.0.sql. + (Run pg_config --sharedir if you're uncertain where + SHAREDIR is.) + There is no harm in doing this again if unsure. +

  • Fix possible crash during UPDATE or DELETE that + joins to the output of a scalar-returning function (Tom Lane) +

    A crash could only occur if the target row had been concurrently + updated, so this problem surfaced only intermittently. +

  • Fix incorrect replay of WAL records for GIN index updates + (Tom Lane) +

    This could result in transiently failing to find index entries after + a crash, or on a hot-standby server. The problem would be repaired + by the next VACUUM of the index, however. +

  • Fix TOAST-related data corruption during CREATE TABLE dest AS + SELECT * FROM src or INSERT INTO dest SELECT * FROM src + (Tom Lane) +

    If a table has been modified by ALTER TABLE ADD COLUMN, + attempts to copy its data verbatim to another table could produce + corrupt results in certain corner cases. + The problem can only manifest in this precise form in 8.4 and later, + but we patched earlier versions as well in case there are other code + paths that could trigger the same bug. +

  • Fix possible failures during hot standby startup (Simon Riggs) +

  • Start hot standby faster when initial snapshot is incomplete + (Simon Riggs) +

  • Fix race condition during toast table access from stale syscache entries + (Tom Lane) +

    The typical symptom was transient errors like "missing chunk + number 0 for toast value NNNNN in pg_toast_2619", where the cited + toast table would always belong to a system catalog. +

  • Track dependencies of functions on items used in parameter default + expressions (Tom Lane) +

    Previously, a referenced object could be dropped without having dropped + or modified the function, leading to misbehavior when the function was + used. Note that merely installing this update will not fix the missing + dependency entries; to do that, you'd need to CREATE OR + REPLACE each such function afterwards. If you have functions whose + defaults depend on non-built-in objects, doing so is recommended. +

  • Fix incorrect management of placeholder variables in nestloop joins + (Tom Lane) +

    This bug is known to lead to "variable not found in subplan target + list" planner errors, and could possibly result in wrong query output + when outer joins are involved. +

  • Fix window functions that sort by expressions involving aggregates + (Tom Lane) +

    Previously these could fail with "could not find pathkey item to + sort" planner errors. +

  • Fix "MergeAppend child's targetlist doesn't match MergeAppend" + planner errors (Tom Lane) +

  • Fix index matching for operators with both collatable and noncollatable + inputs (Tom Lane) +

    In 9.1.0, an indexable operator that has a non-collatable left-hand + input type and a collatable right-hand input type would not be + recognized as matching the left-hand column's index. An example is + the hstore ? text operator. +

  • Allow inlining of set-returning SQL functions with multiple OUT + parameters (Tom Lane) +

  • Don't trust deferred-unique indexes for join removal (Tom Lane and Marti + Raudsepp) +

    A deferred uniqueness constraint might not hold intra-transaction, + so assuming that it does could give incorrect query results. +

  • Make DatumGetInetP() unpack inet datums that have a 1-byte + header, and add a new macro, DatumGetInetPP(), that does + not (Heikki Linnakangas) +

    This change affects no core code, but might prevent crashes in add-on + code that expects DatumGetInetP() to produce an unpacked + datum as per usual convention. +

  • Improve locale support in money type's input and output + (Tom Lane) +

    Aside from not supporting all standard + lc_monetary + formatting options, the input and output functions were inconsistent, + meaning there were locales in which dumped money values could + not be re-read. +

  • Don't let transform_null_equals + affect CASE foo WHEN NULL ... constructs + (Heikki Linnakangas) +

    transform_null_equals is only supposed to affect + foo = NULL expressions written directly by the user, not + equality checks generated internally by this form of CASE. +

  • Change foreign-key trigger creation order to better support + self-referential foreign keys (Tom Lane) +

    For a cascading foreign key that references its own table, a row update + will fire both the ON UPDATE trigger and the + CHECK trigger as one event. The ON UPDATE + trigger must execute first, else the CHECK will check a + non-final state of the row and possibly throw an inappropriate error. + However, the firing order of these triggers is determined by their + names, which generally sort in creation order since the triggers have + auto-generated names following the convention + "RI_ConstraintTrigger_NNNN". A proper fix would require + modifying that convention, which we will do in 9.2, but it seems risky + to change it in existing releases. So this patch just changes the + creation order of the triggers. Users encountering this type of error + should drop and re-create the foreign key constraint to get its + triggers into the right order. +

  • Fix IF EXISTS to work correctly in DROP OPERATOR + FAMILY (Robert Haas) +

  • Disallow dropping of an extension from within its own script + (Tom Lane) +

    This prevents odd behavior in case of incorrect management of extension + dependencies. +

  • Don't mark auto-generated types as extension members (Robert Haas) +

    Relation rowtypes and automatically-generated array types do not need to + have their own extension membership entries in pg_depend, + and creating such entries complicates matters for extension upgrades. +

  • Cope with invalid pre-existing search_path settings during + CREATE EXTENSION (Tom Lane) +

  • Avoid floating-point underflow while tracking buffer allocation rate + (Greg Matthews) +

    While harmless in itself, on certain platforms this would result in + annoying kernel log messages. +

  • Prevent autovacuum transactions from running in serializable mode + (Tom Lane) +

    Autovacuum formerly used the cluster-wide default transaction isolation + level, but there is no need for it to use anything higher than READ + COMMITTED, and using SERIALIZABLE could result in unnecessary delays + for other processes. +

  • Ensure walsender processes respond promptly to SIGTERM + (Magnus Hagander) +

  • Exclude postmaster.opts from base backups + (Magnus Hagander) +

  • Preserve configuration file name and line number values when starting + child processes under Windows (Tom Lane) +

    Formerly, these would not be displayed correctly in the + pg_settings view. +

  • Fix incorrect field alignment in ecpg's SQLDA area + (Zoltan Boszormenyi) +

  • Preserve blank lines within commands in psql's command + history (Robert Haas) +

    The former behavior could cause problems if an empty line was removed + from within a string literal, for example. +

  • Avoid platform-specific infinite loop in pg_dump + (Steve Singer) +

  • Fix compression of plain-text output format in pg_dump + (Adrian Klaver and Tom Lane) +

    pg_dump has historically understood -Z with + no -F switch to mean that it should emit a gzip-compressed + version of its plain text output. Restore that behavior. +

  • Fix pg_dump to dump user-defined casts between + auto-generated types, such as table rowtypes (Tom Lane) +

  • Fix missed quoting of foreign server names in pg_dump + (Tom Lane) +

  • Assorted fixes for pg_upgrade (Bruce Momjian) +

    Handle exclusion constraints correctly, avoid failures on Windows, + don't complain about mismatched toast table names in 8.4 databases. +

  • In PL/pgSQL, allow foreign tables to define row types + (Alexander Soudakov) +

  • Fix up conversions of PL/Perl functions' results + (Alex Hunsaker and Tom Lane) +

    Restore the pre-9.1 behavior that PL/Perl functions returning + void ignore the result value of their last Perl statement; + 9.1.0 would throw an error if that statement returned a reference. + Also, make sure it works to return a string value for a composite type, + so long as the string meets the type's input format. + In addition, throw errors for attempts to return Perl arrays or hashes + when the function's declared result type is not an array or composite + type, respectively. (Pre-9.1 versions rather uselessly returned + strings like ARRAY(0x221a9a0) or + HASH(0x221aa90) in such cases.) +

  • Ensure PL/Perl strings are always correctly UTF8-encoded + (Amit Khandekar and Alex Hunsaker) +

  • Use the preferred version of xsubpp to build PL/Perl, + not necessarily the operating system's main copy + (David Wheeler and Alex Hunsaker) +

  • Correctly propagate SQLSTATE in PL/Python exceptions + (Mika Eloranta and Jan Urbanski) +

  • Do not install PL/Python extension files for Python major versions + other than the one built against (Peter Eisentraut) +

  • Change all the contrib extension script files to report + a useful error message if they are fed to psql + (Andrew Dunstan and Tom Lane) +

    This should help teach people about the new method of using + CREATE EXTENSION to load these files. In most cases, + sourcing the scripts directly would fail anyway, but with + harder-to-interpret messages. +

  • Fix incorrect coding in contrib/dict_int and + contrib/dict_xsyn (Tom Lane) +

    Some functions incorrectly assumed that memory returned by + palloc() is guaranteed zeroed. +

  • Remove contrib/sepgsql tests from the regular regression + test mechanism (Tom Lane) +

    Since these tests require root privileges for setup, they're impractical + to run automatically. Switch over to a manual approach instead, and + provide a testing script to help with that. +

  • Fix assorted errors in contrib/unaccent's configuration + file parsing (Tom Lane) +

  • Honor query cancel interrupts promptly in pgstatindex() + (Robert Haas) +

  • Fix incorrect quoting of log file name in Mac OS X start script + (Sidar Lopez) +

  • Revert unintentional enabling of WAL_DEBUG (Robert Haas) +

    Fortunately, as debugging tools go, this one is pretty cheap; + but it's not intended to be enabled by default, so revert. +

  • Ensure VPATH builds properly install all server header files + (Peter Eisentraut) +

  • Shorten file names reported in verbose error messages (Peter Eisentraut) +

    Regular builds have always reported just the name of the C file + containing the error message call, but VPATH builds formerly + reported an absolute path name. +

  • Fix interpretation of Windows timezone names for Central America + (Tom Lane) +

    Map "Central America Standard Time" to CST6, not + CST6CDT, because DST is generally not observed anywhere in + Central America. +

  • Update time zone data files to tzdata release 2011n + for DST law changes in Brazil, Cuba, Fiji, Palestine, Russia, and Samoa; + also historical corrections for Alaska and British East Africa. +


PrevHomeNext
Release 9.1.3UpRelease 9.1.1
\ No newline at end of file diff --git a/doc/src/sgml/html/release-9-1-3.html b/doc/src/sgml/html/release-9-1-3.html new file mode 100644 index 000000000..3e98d7d7e --- /dev/null +++ b/doc/src/sgml/html/release-9-1-3.html @@ -0,0 +1,965 @@ + +Release 9.1.3

E.8. Release 9.1.3

Release Date: 2012-02-27

This release contains a variety of fixes from 9.1.2. + For information about new features in the 9.1 major release, see + Section E.11. +

E.8.1. Migration to Version 9.1.3

A dump/restore is not required for those running 9.1.X. +

However, if you are upgrading from a version earlier than 9.1.2, + see the release notes for 9.1.2. +

E.8.2. Changes

  • Require execute permission on the trigger function for + CREATE TRIGGER (Robert Haas) +

    This missing check could allow another user to execute a trigger + function with forged input data, by installing it on a table he owns. + This is only of significance for trigger functions marked + SECURITY DEFINER, since otherwise trigger functions run + as the table owner anyway. (CVE-2012-0866) +

  • Remove arbitrary limitation on length of common name in SSL + certificates (Heikki Linnakangas) +

    Both libpq and the server truncated the common name + extracted from an SSL certificate at 32 bytes. Normally this would + cause nothing worse than an unexpected verification failure, but there + are some rather-implausible scenarios in which it might allow one + certificate holder to impersonate another. The victim would have to + have a common name exactly 32 bytes long, and the attacker would have + to persuade a trusted CA to issue a certificate in which the common + name has that string as a prefix. Impersonating a server would also + require some additional exploit to redirect client connections. + (CVE-2012-0867) +

  • Convert newlines to spaces in names written in pg_dump + comments (Robert Haas) +

    pg_dump was incautious about sanitizing object names + that are emitted within SQL comments in its output script. A name + containing a newline would at least render the script syntactically + incorrect. Maliciously crafted object names could present a SQL + injection risk when the script is reloaded. (CVE-2012-0868) +

  • Fix btree index corruption from insertions concurrent with vacuuming + (Tom Lane) +

    An index page split caused by an insertion could sometimes cause a + concurrently-running VACUUM to miss removing index entries + that it should remove. After the corresponding table rows are removed, + the dangling index entries would cause errors (such as "could not + read block N in file ...") or worse, silently wrong query results + after unrelated rows are re-inserted at the now-free table locations. + This bug has been present since release 8.2, but occurs so infrequently + that it was not diagnosed until now. If you have reason to suspect + that it has happened in your database, reindexing the affected index + will fix things. +

  • Fix transient zeroing of shared buffers during WAL replay (Tom Lane) +

    The replay logic would sometimes zero and refill a shared buffer, so + that the contents were transiently invalid. In hot standby mode this + can result in a query that's executing in parallel seeing garbage data. + Various symptoms could result from that, but the most common one seems + to be "invalid memory alloc request size". +

  • Fix handling of data-modifying WITH subplans in + READ COMMITTED rechecking (Tom Lane) +

    A WITH clause containing + INSERT/UPDATE/DELETE would crash + if the parent UPDATE or DELETE command needed + to be re-evaluated at one or more rows due to concurrent updates + in READ COMMITTED mode. +

  • Fix corner case in SSI transaction cleanup + (Dan Ports) +

    When finishing up a read-write serializable transaction, + a crash could occur if all remaining active serializable transactions + are read-only. +

  • Fix postmaster to attempt restart after a hot-standby crash (Tom Lane) +

    A logic error caused the postmaster to terminate, rather than attempt + to restart the cluster, if any backend process crashed while operating + in hot standby mode. +

  • Fix CLUSTER/VACUUM FULL handling of toast + values owned by recently-updated rows (Tom Lane) +

    This oversight could lead to "duplicate key value violates unique + constraint" errors being reported against the toast table's index + during one of these commands. +

  • Update per-column permissions, not only per-table permissions, when + changing table owner (Tom Lane) +

    Failure to do this meant that any previously granted column permissions + were still shown as having been granted by the old owner. This meant + that neither the new owner nor a superuser could revoke the + now-untraceable-to-table-owner permissions. +

  • Support foreign data wrappers and foreign servers in + REASSIGN OWNED (Alvaro Herrera) +

    This command failed with "unexpected classid" errors if + it needed to change the ownership of any such objects. +

  • Allow non-existent values for some settings in ALTER + USER/DATABASE SET (Heikki Linnakangas) +

    Allow default_text_search_config, + default_tablespace, and temp_tablespaces to be + set to names that are not known. This is because they might be known + in another database where the setting is intended to be used, or for the + tablespace cases because the tablespace might not be created yet. The + same issue was previously recognized for search_path, and + these settings now act like that one. +

  • Fix "unsupported node type" error caused by COLLATE + in an INSERT expression (Tom Lane) +

  • Avoid crashing when we have problems deleting table files post-commit + (Tom Lane) +

    Dropping a table should lead to deleting the underlying disk files only + after the transaction commits. In event of failure then (for instance, + because of wrong file permissions) the code is supposed to just emit a + warning message and go on, since it's too late to abort the + transaction. This logic got broken as of release 8.4, causing such + situations to result in a PANIC and an unrestartable database. +

  • Recover from errors occurring during WAL replay of DROP + TABLESPACE (Tom Lane) +

    Replay will attempt to remove the tablespace's directories, but there + are various reasons why this might fail (for example, incorrect + ownership or permissions on those directories). Formerly the replay + code would panic, rendering the database unrestartable without manual + intervention. It seems better to log the problem and continue, since + the only consequence of failure to remove the directories is some + wasted disk space. +

  • Fix race condition in logging AccessExclusiveLocks for hot standby + (Simon Riggs) +

    Sometimes a lock would be logged as being held by "transaction + zero". This is at least known to produce assertion failures on + slave servers, and might be the cause of more serious problems. +

  • Track the OID counter correctly during WAL replay, even when it wraps + around (Tom Lane) +

    Previously the OID counter would remain stuck at a high value until the + system exited replay mode. The practical consequences of that are + usually nil, but there are scenarios wherein a standby server that's + been promoted to master might take a long time to advance the OID + counter to a reasonable value once values are needed. +

  • Prevent emitting misleading "consistent recovery state reached" + log message at the beginning of crash recovery (Heikki Linnakangas) +

  • Fix initial value of + pg_stat_replication.replay_location + (Fujii Masao) +

    Previously, the value shown would be wrong until at least one WAL + record had been replayed. +

  • Fix regular expression back-references with * attached + (Tom Lane) +

    Rather than enforcing an exact string match, the code would effectively + accept any string that satisfies the pattern sub-expression referenced + by the back-reference symbol. +

    A similar problem still afflicts back-references that are embedded in a + larger quantified expression, rather than being the immediate subject + of the quantifier. This will be addressed in a future + PostgreSQL release. +

  • Fix recently-introduced memory leak in processing of + inet/cidr values (Heikki Linnakangas) +

    A patch in the December 2011 releases of PostgreSQL + caused memory leakage in these operations, which could be significant + in scenarios such as building a btree index on such a column. +

  • Fix planner's ability to push down index-expression restrictions + through UNION ALL (Tom Lane) +

    This type of optimization was inadvertently disabled by a fix for + another problem in 9.1.2. +

  • Fix planning of WITH clauses referenced in + UPDATE/DELETE on an inherited table + (Tom Lane) +

    This bug led to "could not find plan for CTE" failures. +

  • Fix GIN cost estimation to handle column IN (...) + index conditions (Marti Raudsepp) +

    This oversight would usually lead to crashes if such a condition could + be used with a GIN index. +

  • Prevent assertion failure when exiting a session with an open, failed + transaction (Tom Lane) +

    This bug has no impact on normal builds with asserts not enabled. +

  • Fix dangling pointer after CREATE TABLE AS/SELECT + INTO in a SQL-language function (Tom Lane) +

    In most cases this only led to an assertion failure in assert-enabled + builds, but worse consequences seem possible. +

  • Avoid double close of file handle in syslogger on Windows (MauMau) +

    Ordinarily this error was invisible, but it would cause an exception + when running on a debug version of Windows. +

  • Fix I/O-conversion-related memory leaks in plpgsql + (Andres Freund, Jan Urbanski, Tom Lane) +

    Certain operations would leak memory until the end of the current + function. +

  • Work around bug in perl's SvPVutf8() function (Andrew Dunstan) +

    This function crashes when handed a typeglob or certain read-only + objects such as $^V. Make plperl avoid passing those to + it. +

  • In pg_dump, don't dump contents of an extension's + configuration tables if the extension itself is not being dumped + (Tom Lane) +

  • Improve pg_dump's handling of inherited table columns + (Tom Lane) +

    pg_dump mishandled situations where a child column has + a different default expression than its parent column. If the default + is textually identical to the parent's default, but not actually the + same (for instance, because of schema search path differences) it would + not be recognized as different, so that after dump and restore the + child would be allowed to inherit the parent's default. Child columns + that are NOT NULL where their parent is not could also be + restored subtly incorrectly. +

  • Fix pg_restore's direct-to-database mode for + INSERT-style table data (Tom Lane) +

    Direct-to-database restores from archive files made with + --inserts or --column-inserts options fail when + using pg_restore from a release dated September or + December 2011, as a result of an oversight in a fix for another + problem. The archive file itself is not at fault, and text-mode + output is okay. +

  • Teach pg_upgrade to handle renaming of + plpython's shared library (Bruce Momjian) +

    Upgrading a pre-9.1 database that included plpython would fail because + of this oversight. +

  • Allow pg_upgrade to process tables containing + regclass columns (Bruce Momjian) +

    Since pg_upgrade now takes care to preserve + pg_class OIDs, there was no longer any reason for this + restriction. +

  • Make libpq ignore ENOTDIR errors + when looking for an SSL client certificate file + (Magnus Hagander) +

    This allows SSL connections to be established, though without a + certificate, even when the user's home directory is set to something + like /dev/null. +

  • Fix some more field alignment issues in ecpg's SQLDA area + (Zoltan Boszormenyi) +

  • Allow AT option in ecpg + DEALLOCATE statements (Michael Meskes) +

    The infrastructure to support this has been there for awhile, but + through an oversight there was still an error check rejecting the case. +

  • Do not use the variable name when defining a varchar structure in ecpg + (Michael Meskes) +

  • Fix contrib/auto_explain's JSON output mode to produce + valid JSON (Andrew Dunstan) +

    The output used brackets at the top level, when it should have used + braces. +

  • Fix error in contrib/intarray's int[] & + int[] operator (Guillaume Lelarge) +

    If the smallest integer the two input arrays have in common is 1, + and there are smaller values in either array, then 1 would be + incorrectly omitted from the result. +

  • Fix error detection in contrib/pgcrypto's + encrypt_iv() and decrypt_iv() + (Marko Kreen) +

    These functions failed to report certain types of invalid-input errors, + and would instead return random garbage values for incorrect input. +

  • Fix one-byte buffer overrun in contrib/test_parser + (Paul Guyot) +

    The code would try to read one more byte than it should, which would + crash in corner cases. + Since contrib/test_parser is only example code, this is + not a security issue in itself, but bad example code is still bad. +

  • Use __sync_lock_test_and_set() for spinlocks on ARM, if + available (Martin Pitt) +

    This function replaces our previous use of the SWPB + instruction, which is deprecated and not available on ARMv6 and later. + Reports suggest that the old code doesn't fail in an obvious way on + recent ARM boards, but simply doesn't interlock concurrent accesses, + leading to bizarre failures in multiprocess operation. +

  • Use -fexcess-precision=standard option when building with + gcc versions that accept it (Andrew Dunstan) +

    This prevents assorted scenarios wherein recent versions of gcc will + produce creative results. +

  • Allow use of threaded Python on FreeBSD (Chris Rees) +

    Our configure script previously believed that this combination wouldn't + work; but FreeBSD fixed the problem, so remove that error check. +

  • Allow MinGW builds to use standardly-named OpenSSL libraries + (Tomasz Ostrowski) +


PrevHomeNext
Release 9.1.4UpRelease 9.1.2
\ No newline at end of file diff --git a/doc/src/sgml/html/release-9-1-4.html b/doc/src/sgml/html/release-9-1-4.html new file mode 100644 index 000000000..f40886091 --- /dev/null +++ b/doc/src/sgml/html/release-9-1-4.html @@ -0,0 +1,789 @@ + +Release 9.1.4

E.7. Release 9.1.4

Release Date: 2012-06-04

This release contains a variety of fixes from 9.1.3. + For information about new features in the 9.1 major release, see + Section E.11. +

E.7.1. Migration to Version 9.1.4

A dump/restore is not required for those running 9.1.X. +

However, if you use the citext data type, and you upgraded + from a previous major release by running pg_upgrade, + you should run CREATE EXTENSION citext FROM unpackaged + to avoid collation-related failures in citext operations. + The same is necessary if you restore a dump from a pre-9.1 database + that contains an instance of the citext data type. + If you've already run the CREATE EXTENSION command before + upgrading to 9.1.4, you will instead need to do manual catalog updates + as explained in the third changelog item below. +

Also, if you are upgrading from a version earlier than 9.1.2, + see the release notes for 9.1.2. +

E.7.2. Changes

  • Fix incorrect password transformation in + contrib/pgcrypto's DES crypt() function + (Solar Designer) +

    If a password string contained the byte value 0x80, the + remainder of the password was ignored, causing the password to be much + weaker than it appeared. With this fix, the rest of the string is + properly included in the DES hash. Any stored password values that are + affected by this bug will thus no longer match, so the stored values may + need to be updated. (CVE-2012-2143) +

  • Ignore SECURITY DEFINER and SET attributes for + a procedural language's call handler (Tom Lane) +

    Applying such attributes to a call handler could crash the server. + (CVE-2012-2655) +

  • Make contrib/citext's upgrade script fix collations of + citext arrays and domains over citext + (Tom Lane) +

    Release 9.1.2 provided a fix for collations of citext columns + and indexes in databases upgraded or reloaded from pre-9.1 + installations, but that fix was incomplete: it neglected to handle arrays + and domains over citext. This release extends the module's + upgrade script to handle these cases. As before, if you have already + run the upgrade script, you'll need to run the collation update + commands by hand instead. See the 9.1.2 release notes for more + information about doing this. +

  • Allow numeric timezone offsets in timestamp input to be up to + 16 hours away from UTC (Tom Lane) +

    Some historical time zones have offsets larger than 15 hours, the + previous limit. This could result in dumped data values being rejected + during reload. +

  • Fix timestamp conversion to cope when the given time is exactly the + last DST transition time for the current timezone (Tom Lane) +

    This oversight has been there a long time, but was not noticed + previously because most DST-using zones are presumed to have an + indefinite sequence of future DST transitions. +

  • Fix text to name and char to name + casts to perform string truncation correctly in multibyte encodings + (Karl Schnaitter) +

  • Fix memory copying bug in to_tsquery() (Heikki Linnakangas) +

  • Ensure txid_current() reports the correct epoch when + executed in hot standby (Simon Riggs) +

  • Fix planner's handling of outer PlaceHolderVars within subqueries (Tom + Lane) +

    This bug concerns sub-SELECTs that reference variables coming from the + nullable side of an outer join of the surrounding query. + In 9.1, queries affected by this bug would fail with "ERROR: + Upper-level PlaceHolderVar found where not expected". But in 9.0 and + 8.4, you'd silently get possibly-wrong answers, since the value + transmitted into the subquery wouldn't go to null when it should. +

  • Fix planning of UNION ALL subqueries with output columns + that are not simple variables (Tom Lane) +

    Planning of such cases got noticeably worse in 9.1 as a result of a + misguided fix for "MergeAppend child's targetlist doesn't match + MergeAppend" errors. Revert that fix and do it another way. +

  • Fix slow session startup when pg_attribute is very large + (Tom Lane) +

    If pg_attribute exceeds one-fourth of + shared_buffers, cache rebuilding code that is sometimes + needed during session start would trigger the synchronized-scan logic, + causing it to take many times longer than normal. The problem was + particularly acute if many new sessions were starting at once. +

  • Ensure sequential scans check for query cancel reasonably often (Merlin + Moncure) +

    A scan encountering many consecutive pages that contain no live tuples + would not respond to interrupts meanwhile. +

  • Ensure the Windows implementation of PGSemaphoreLock() + clears ImmediateInterruptOK before returning (Tom Lane) +

    This oversight meant that a query-cancel interrupt received later + in the same query could be accepted at an unsafe time, with + unpredictable but not good consequences. +

  • Show whole-row variables safely when printing views or rules + (Abbas Butt, Tom Lane) +

    Corner cases involving ambiguous names (that is, the name could be + either a table or column name of the query) were printed in an + ambiguous way, risking that the view or rule would be interpreted + differently after dump and reload. Avoid the ambiguous case by + attaching a no-op cast. +

  • Fix COPY FROM to properly handle null marker strings that + correspond to invalid encoding (Tom Lane) +

    A null marker string such as E'\\0' should work, and did + work in the past, but the case got broken in 8.4. +

  • Fix EXPLAIN VERBOSE for writable CTEs containing + RETURNING clauses (Tom Lane) +

  • Fix PREPARE TRANSACTION to work correctly in the presence + of advisory locks (Tom Lane) +

    Historically, PREPARE TRANSACTION has simply ignored any + session-level advisory locks the session holds, but this case was + accidentally broken in 9.1. +

  • Fix truncation of unlogged tables (Robert Haas) +

  • Ignore missing schemas during non-interactive assignments of + search_path (Tom Lane) +

    This re-aligns 9.1's behavior with that of older branches. Previously + 9.1 would throw an error for nonexistent schemas mentioned in + search_path settings obtained from places such as + ALTER DATABASE SET. +

  • Fix bugs with temporary or transient tables used in extension scripts + (Tom Lane) +

    This includes cases such as a rewriting ALTER TABLE within + an extension update script, since that uses a transient table behind + the scenes. +

  • Ensure autovacuum worker processes perform stack depth checking + properly (Heikki Linnakangas) +

    Previously, infinite recursion in a function invoked by + auto-ANALYZE could crash worker processes. +

  • Fix logging collector to not lose log coherency under high load (Andrew + Dunstan) +

    The collector previously could fail to reassemble large messages if it + got too busy. +

  • Fix logging collector to ensure it will restart file rotation + after receiving SIGHUP (Tom Lane) +

  • Fix "too many LWLocks taken" failure in GiST indexes (Heikki + Linnakangas) +

  • Fix WAL replay logic for GIN indexes to not fail if the index was + subsequently dropped (Tom Lane) +

  • Correctly detect SSI conflicts of prepared transactions after a crash + (Dan Ports) +

  • Avoid synchronous replication delay when committing a transaction that + only modified temporary tables (Heikki Linnakangas) +

    In such a case the transaction's commit record need not be flushed to + standby servers, but some of the code didn't know that and waited for + it to happen anyway. +

  • Fix error handling in pg_basebackup + (Thomas Ogrisegg, Fujii Masao) +

  • Fix walsender to not go into a busy loop if connection + is terminated (Fujii Masao) +

  • Fix memory leak in PL/pgSQL's RETURN NEXT command (Joe + Conway) +

  • Fix PL/pgSQL's GET DIAGNOSTICS command when the target + is the function's first variable (Tom Lane) +

  • Ensure that PL/Perl package-qualifies the _TD variable + (Alex Hunsaker) +

    This bug caused trigger invocations to fail when they are nested + within a function invocation that changes the current package. +

  • Fix PL/Python functions returning composite types to accept a string + for their result value (Jan Urbanski) +

    This case was accidentally broken by the 9.1 additions to allow a + composite result value to be supplied in other formats, such as + dictionaries. +

  • Fix potential access off the end of memory in psql's + expanded display (\x) mode (Peter Eisentraut) +

  • Fix several performance problems in pg_dump when + the database contains many objects (Jeff Janes, Tom Lane) +

    pg_dump could get very slow if the database contained + many schemas, or if many objects are in dependency loops, or if there + are many owned sequences. +

  • Fix memory and file descriptor leaks in pg_restore + when reading a directory-format archive (Peter Eisentraut) +

  • Fix pg_upgrade for the case that a database stored in a + non-default tablespace contains a table in the cluster's default + tablespace (Bruce Momjian) +

  • In ecpg, fix rare memory leaks and possible overwrite + of one byte after the sqlca_t structure (Peter Eisentraut) +

  • Fix contrib/dblink's dblink_exec() to not leak + temporary database connections upon error (Tom Lane) +

  • Fix contrib/dblink to report the correct connection name in + error messages (Kyotaro Horiguchi) +

  • Fix contrib/vacuumlo to use multiple transactions when + dropping many large objects (Tim Lewis, Robert Haas, Tom Lane) +

    This change avoids exceeding max_locks_per_transaction when + many objects need to be dropped. The behavior can be adjusted with the + new -l (limit) option. +

  • Update time zone data files to tzdata release 2012c + for DST law changes in Antarctica, Armenia, Chile, Cuba, Falkland + Islands, Gaza, Haiti, Hebron, Morocco, Syria, and Tokelau Islands; + also historical corrections for Canada. +


PrevHomeNext
Release 9.1.5UpRelease 9.1.3
\ No newline at end of file diff --git a/doc/src/sgml/html/release-9-1-5.html b/doc/src/sgml/html/release-9-1-5.html new file mode 100644 index 000000000..c83d72322 --- /dev/null +++ b/doc/src/sgml/html/release-9-1-5.html @@ -0,0 +1,719 @@ + +Release 9.1.5

E.6. Release 9.1.5

Release Date: 2012-08-17

This release contains a variety of fixes from 9.1.4. + For information about new features in the 9.1 major release, see + Section E.11. +

E.6.1. Migration to Version 9.1.5

A dump/restore is not required for those running 9.1.X. +

However, if you are upgrading from a version earlier than 9.1.4, + see the release notes for 9.1.4. +

E.6.2. Changes

  • Prevent access to external files/URLs via XML entity references + (Noah Misch, Tom Lane) +

    xml_parse() would attempt to fetch external files or + URLs as needed to resolve DTD and entity references in an XML value, + thus allowing unprivileged database users to attempt to fetch data + with the privileges of the database server. While the external data + wouldn't get returned directly to the user, portions of it could be + exposed in error messages if the data didn't parse as valid XML; and + in any case the mere ability to check existence of a file might be + useful to an attacker. (CVE-2012-3489) +

  • Prevent access to external files/URLs via contrib/xml2's + xslt_process() (Peter Eisentraut) +

    libxslt offers the ability to read and write both + files and URLs through stylesheet commands, thus allowing + unprivileged database users to both read and write data with the + privileges of the database server. Disable that through proper use + of libxslt's security options. (CVE-2012-3488) +

    Also, remove xslt_process()'s ability to fetch documents + and stylesheets from external files/URLs. While this was a + documented "feature", it was long regarded as a bad idea. + The fix for CVE-2012-3489 broke that capability, and rather than + expend effort on trying to fix it, we're just going to summarily + remove it. +

  • Prevent too-early recycling of btree index pages (Noah Misch) +

    When we allowed read-only transactions to skip assigning XIDs, we + introduced the possibility that a deleted btree page could be + recycled while a read-only transaction was still in flight to it. + This would result in incorrect index search results. The probability + of such an error occurring in the field seems very low because of the + timing requirements, but nonetheless it should be fixed. +

  • Fix crash-safety bug with newly-created-or-reset sequences (Tom Lane) +

    If ALTER SEQUENCE was executed on a freshly created or + reset sequence, and then precisely one nextval() call + was made on it, and then the server crashed, WAL replay would restore + the sequence to a state in which it appeared that no + nextval() had been done, thus allowing the first + sequence value to be returned again by the next + nextval() call. In particular this could manifest for + serial columns, since creation of a serial column's sequence + includes an ALTER SEQUENCE OWNED BY step. +

  • Fix race condition in enum-type value comparisons (Robert + Haas, Tom Lane) +

    Comparisons could fail when encountering an enum value added since + the current query started. +

  • Fix txid_current() to report the correct epoch when not + in hot standby (Heikki Linnakangas) +

    This fixes a regression introduced in the previous minor release. +

  • Prevent selection of unsuitable replication connections as + the synchronous standby (Fujii Masao) +

    The master might improperly choose pseudo-servers such as + pg_receivexlog or pg_basebackup + as the synchronous standby, and then wait indefinitely for them. +

  • Fix bug in startup of Hot Standby when a master transaction has many + subtransactions (Andres Freund) +

    This mistake led to failures reported as "out-of-order XID + insertion in KnownAssignedXids". +

  • Ensure the backup_label file is fsync'd after + pg_start_backup() (Dave Kerr) +

  • Fix timeout handling in walsender processes (Tom Lane) +

    WAL sender background processes neglected to establish a + SIGALRM handler, meaning they would wait forever in + some corner cases where a timeout ought to happen. +

  • Wake walsenders after each background flush by walwriter (Andres + Freund, Simon Riggs) +

    This greatly reduces replication delay when the workload contains + only asynchronously-committed transactions. +

  • Fix LISTEN/NOTIFY to cope better with I/O + problems, such as out of disk space (Tom Lane) +

    After a write failure, all subsequent attempts to send more + NOTIFY messages would fail with messages like + "Could not read from file "pg_notify/nnnn" at + offset nnnnn: Success". +

  • Only allow autovacuum to be auto-canceled by a directly blocked + process (Tom Lane) +

    The original coding could allow inconsistent behavior in some cases; + in particular, an autovacuum could get canceled after less than + deadlock_timeout grace period. +

  • Improve logging of autovacuum cancels (Robert Haas) +

  • Fix log collector so that log_truncate_on_rotation works + during the very first log rotation after server start (Tom Lane) +

  • Fix WITH attached to a nested set operation + (UNION/INTERSECT/EXCEPT) + (Tom Lane) +

  • Ensure that a whole-row reference to a subquery doesn't include any + extra GROUP BY or ORDER BY columns (Tom Lane) +

  • Fix dependencies generated during ALTER TABLE ... ADD + CONSTRAINT USING INDEX (Tom Lane) +

    This command left behind a redundant pg_depend entry + for the index, which could confuse later operations, notably + ALTER TABLE ... ALTER COLUMN TYPE on one of the indexed + columns. +

  • Fix REASSIGN OWNED to work on extensions (Alvaro Herrera) +

  • Disallow copying whole-row references in CHECK + constraints and index definitions during CREATE TABLE + (Tom Lane) +

    This situation can arise in CREATE TABLE with + LIKE or INHERITS. The copied whole-row + variable was incorrectly labeled with the row type of the original + table not the new one. Rejecting the case seems reasonable for + LIKE, since the row types might well diverge later. For + INHERITS we should ideally allow it, with an implicit + coercion to the parent table's row type; but that will require more + work than seems safe to back-patch. +

  • Fix memory leak in ARRAY(SELECT ...) subqueries (Heikki + Linnakangas, Tom Lane) +

  • Fix planner to pass correct collation to operator selectivity + estimators (Tom Lane) +

    This was not previously required by any core selectivity estimation + function, but third-party code might need it. +

  • Fix extraction of common prefixes from regular expressions (Tom Lane) +

    The code could get confused by quantified parenthesized + subexpressions, such as ^(foo)?bar. This would lead to + incorrect index optimization of searches for such patterns. +

  • Fix bugs with parsing signed + hh:mm and + hh:mm:ss + fields in interval constants (Amit Kapila, Tom Lane) +

  • Fix pg_dump to better handle views containing partial + GROUP BY lists (Tom Lane) +

    A view that lists only a primary key column in GROUP BY, + but uses other table columns as if they were grouped, gets marked as + depending on the primary key. Improper handling of such primary key + dependencies in pg_dump resulted in poorly-ordered + dumps, which at best would be inefficient to restore and at worst + could result in outright failure of a parallel + pg_restore run. +

  • In PL/Perl, avoid setting UTF8 flag when in SQL_ASCII encoding + (Alex Hunsaker, Kyotaro Horiguchi, Alvaro Herrera) +

  • Use Postgres' encoding conversion functions, not Python's, when + converting a Python Unicode string to the server encoding in + PL/Python (Jan Urbanski) +

    This avoids some corner-case problems, notably that Python doesn't + support all the encodings Postgres does. A notable functional change + is that if the server encoding is SQL_ASCII, you will get the UTF-8 + representation of the string; formerly, any non-ASCII characters in + the string would result in an error. +

  • Fix mapping of PostgreSQL encodings to Python encodings in PL/Python + (Jan Urbanski) +

  • Report errors properly in contrib/xml2's + xslt_process() (Tom Lane) +

  • Update time zone data files to tzdata release 2012e + for DST law changes in Morocco and Tokelau +


PrevHomeNext
Release 9.1.6UpRelease 9.1.4
\ No newline at end of file diff --git a/doc/src/sgml/html/release-9-1-6.html b/doc/src/sgml/html/release-9-1-6.html new file mode 100644 index 000000000..2b1aeed9e --- /dev/null +++ b/doc/src/sgml/html/release-9-1-6.html @@ -0,0 +1,507 @@ + +Release 9.1.6

E.5. Release 9.1.6

Release Date: 2012-09-24

This release contains a variety of fixes from 9.1.5. + For information about new features in the 9.1 major release, see + Section E.11. +

E.5.1. Migration to Version 9.1.6

A dump/restore is not required for those running 9.1.X. +

However, you may need to perform REINDEX operations to + recover from the effects of the data corruption bug described in the + first changelog item below. +

Also, if you are upgrading from a version earlier than 9.1.4, + see the release notes for 9.1.4. +

E.5.2. Changes

  • Fix persistence marking of shared buffers during WAL replay + (Jeff Davis) +

    This mistake can result in buffers not being written out during + checkpoints, resulting in data corruption if the server later crashes + without ever having written those buffers. Corruption can occur on + any server following crash recovery, but it is significantly more + likely to occur on standby slave servers since those perform much + more WAL replay. There is a low probability of corruption of btree + and GIN indexes. There is a much higher probability of corruption of + table "visibility maps". Fortunately, visibility maps are + non-critical data in 9.1, so the worst consequence of such corruption + in 9.1 installations is transient inefficiency of vacuuming. Table + data proper cannot be corrupted by this bug. +

    While no index corruption due to this bug is known to have occurred + in the field, as a precautionary measure it is recommended that + production installations REINDEX all btree and GIN + indexes at a convenient time after upgrading to 9.1.6. +

    Also, if you intend to do an in-place upgrade to 9.2.X, before doing + so it is recommended to perform a VACUUM of all tables + while having vacuum_freeze_table_age + set to zero. This will ensure that any lingering wrong data in the + visibility maps is corrected before 9.2.X can depend on it. vacuum_cost_delay + can be adjusted to reduce the performance impact of vacuuming, while + causing it to take longer to finish. +

  • Fix planner's assignment of executor parameters, and fix executor's + rescan logic for CTE plan nodes (Tom Lane) +

    These errors could result in wrong answers from queries that scan the + same WITH subquery multiple times. +

  • Fix misbehavior when default_transaction_isolation + is set to serializable (Kevin Grittner, Tom Lane, Heikki + Linnakangas) +

    Symptoms include crashes at process start on Windows, and crashes in + hot standby operation. +

  • Improve selectivity estimation for text search queries involving + prefixes, i.e. word:* patterns (Tom Lane) +

  • Improve page-splitting decisions in GiST indexes (Alexander Korotkov, + Robert Haas, Tom Lane) +

    Multi-column GiST indexes might suffer unexpected bloat due to this + error. +

  • Fix cascading privilege revoke to stop if privileges are still held + (Tom Lane) +

    If we revoke a grant option from some role X, but + X still holds that option via a grant from someone + else, we should not recursively revoke the corresponding privilege + from role(s) Y that X had granted it + to. +

  • Disallow extensions from containing the schema they are assigned to + (Thom Brown) +

    This situation creates circular dependencies that confuse + pg_dump and probably other things. It's confusing + for humans too, so disallow it. +

  • Improve error messages for Hot Standby misconfiguration errors + (Gurjeet Singh) +

  • Make configure probe for mbstowcs_l (Tom + Lane) +

    This fixes build failures on some versions of AIX. +

  • Fix handling of SIGFPE when PL/Perl is in use (Andres Freund) +

    Perl resets the process's SIGFPE handler to + SIG_IGN, which could result in crashes later on. Restore + the normal Postgres signal handler after initializing PL/Perl. +

  • Prevent PL/Perl from crashing if a recursive PL/Perl function is + redefined while being executed (Tom Lane) +

  • Work around possible misoptimization in PL/Perl (Tom Lane) +

    Some Linux distributions contain an incorrect version of + pthread.h that results in incorrect compiled code in + PL/Perl, leading to crashes if a PL/Perl function calls another one + that throws an error. +

  • Fix bugs in contrib/pg_trgm's LIKE pattern + analysis code (Fujii Masao) +

    LIKE queries using a trigram index could produce wrong + results if the pattern contained LIKE escape characters. +

  • Fix pg_upgrade's handling of line endings on Windows + (Andrew Dunstan) +

    Previously, pg_upgrade might add or remove carriage + returns in places such as function bodies. +

  • On Windows, make pg_upgrade use backslash path + separators in the scripts it emits (Andrew Dunstan) +

  • Remove unnecessary dependency on pg_config from + pg_upgrade (Peter Eisentraut) +

  • Update time zone data files to tzdata release 2012f + for DST law changes in Fiji +


PrevHomeNext
Release 9.1.7UpRelease 9.1.5
\ No newline at end of file diff --git a/doc/src/sgml/html/release-9-1-7.html b/doc/src/sgml/html/release-9-1-7.html new file mode 100644 index 000000000..858a196ca --- /dev/null +++ b/doc/src/sgml/html/release-9-1-7.html @@ -0,0 +1,778 @@ + +Release 9.1.7

E.4. Release 9.1.7

Release Date: 2012-12-06

This release contains a variety of fixes from 9.1.6. + For information about new features in the 9.1 major release, see + Section E.11. +

E.4.1. Migration to Version 9.1.7

A dump/restore is not required for those running 9.1.X. +

However, if you are upgrading from a version earlier than 9.1.6, + see the release notes for 9.1.6. +

E.4.2. Changes

  • Fix multiple bugs associated with CREATE INDEX + CONCURRENTLY (Andres Freund, Tom Lane) +

    Fix CREATE INDEX CONCURRENTLY to use + in-place updates when changing the state of an index's + pg_index row. This prevents race conditions that could + cause concurrent sessions to miss updating the target index, thus + resulting in corrupt concurrently-created indexes. +

    Also, fix various other operations to ensure that they ignore + invalid indexes resulting from a failed CREATE INDEX + CONCURRENTLY command. The most important of these is + VACUUM, because an auto-vacuum could easily be launched + on the table before corrective action can be taken to fix or remove + the invalid index. +

  • Fix buffer locking during WAL replay (Tom Lane) +

    The WAL replay code was insufficiently careful about locking buffers + when replaying WAL records that affect more than one page. This could + result in hot standby queries transiently seeing inconsistent states, + resulting in wrong answers or unexpected failures. +

  • Fix an error in WAL generation logic for GIN indexes (Tom Lane) +

    This could result in index corruption, if a torn-page failure occurred. +

  • Properly remove startup process's virtual XID lock when promoting a + hot standby server to normal running (Simon Riggs) +

    This oversight could prevent subsequent execution of certain + operations such as CREATE INDEX CONCURRENTLY. +

  • Avoid bogus "out-of-sequence timeline ID" errors in standby + mode (Heikki Linnakangas) +

  • Prevent the postmaster from launching new child processes after it's + received a shutdown signal (Tom Lane) +

    This mistake could result in shutdown taking longer than it should, or + even never completing at all without additional user action. +

  • Avoid corruption of internal hash tables when out of memory + (Hitoshi Harada) +

  • Prevent file descriptors for dropped tables from being held open past + transaction end (Tom Lane) +

    This should reduce problems with long-since-dropped tables continuing + to occupy disk space. +

  • Prevent database-wide crash and restart when a new child process is + unable to create a pipe for its latch (Tom Lane) +

    Although the new process must fail, there is no good reason to force a + database-wide restart, so avoid that. This improves robustness when + the kernel is nearly out of file descriptors. +

  • Fix planning of non-strict equivalence clauses above outer joins + (Tom Lane) +

    The planner could derive incorrect constraints from a clause equating + a non-strict construct to something else, for example + WHERE COALESCE(foo, 0) = 0 + when foo is coming from the nullable side of an outer join. +

  • Fix SELECT DISTINCT with index-optimized + MIN/MAX on an inheritance tree (Tom Lane) +

    The planner would fail with "failed to re-find MinMaxAggInfo + record" given this combination of factors. +

  • Improve planner's ability to prove exclusion constraints from + equivalence classes (Tom Lane) +

  • Fix partial-row matching in hashed subplans to handle cross-type cases + correctly (Tom Lane) +

    This affects multicolumn NOT IN subplans, such as + WHERE (a, b) NOT IN (SELECT x, y FROM ...) + when for instance b and y are int4 + and int8 respectively. This mistake led to wrong answers + or crashes depending on the specific datatypes involved. +

  • Acquire buffer lock when re-fetching the old tuple for an + AFTER ROW UPDATE/DELETE trigger (Andres Freund) +

    In very unusual circumstances, this oversight could result in passing + incorrect data to a trigger WHEN condition, or to the + precheck logic for a foreign-key enforcement trigger. That could + result in a crash, or in an incorrect decision about whether to + fire the trigger. +

  • Fix ALTER COLUMN TYPE to handle inherited check + constraints properly (Pavan Deolasee) +

    This worked correctly in pre-8.4 releases, and now works correctly + in 8.4 and later. +

  • Fix ALTER EXTENSION SET SCHEMA's failure to move some + subsidiary objects into the new schema (Álvaro Herrera, Dimitri + Fontaine) +

  • Fix REASSIGN OWNED to handle grants on tablespaces + (Álvaro Herrera) +

  • Ignore incorrect pg_attribute entries for system + columns for views (Tom Lane) +

    Views do not have any system columns. However, we forgot to + remove such entries when converting a table to a view. That's fixed + properly for 9.3 and later, but in previous branches we need to defend + against existing mis-converted views. +

  • Fix rule printing to dump INSERT INTO table + DEFAULT VALUES correctly (Tom Lane) +

  • Guard against stack overflow when there are too many + UNION/INTERSECT/EXCEPT clauses + in a query (Tom Lane) +

  • Prevent platform-dependent failures when dividing the minimum possible + integer value by -1 (Xi Wang, Tom Lane) +

  • Fix possible access past end of string in date parsing + (Hitoshi Harada) +

  • Fix failure to advance XID epoch if XID wraparound happens during a + checkpoint and wal_level is hot_standby + (Tom Lane, Andres Freund) +

    While this mistake had no particular impact on + PostgreSQL itself, it was bad for + applications that rely on txid_current() and related + functions: the TXID value would appear to go backwards. +

  • Fix display of + pg_stat_replication.sync_state at a + page boundary (Kyotaro Horiguchi) +

  • Produce an understandable error message if the length of the path name + for a Unix-domain socket exceeds the platform-specific limit + (Tom Lane, Andrew Dunstan) +

    Formerly, this would result in something quite unhelpful, such as + "Non-recoverable failure in name resolution". +

  • Fix memory leaks when sending composite column values to the client + (Tom Lane) +

  • Make pg_ctl more robust about reading the + postmaster.pid file (Heikki Linnakangas) +

    Fix race conditions and possible file descriptor leakage. +

  • Fix possible crash in psql if incorrectly-encoded data + is presented and the client_encoding setting is a + client-only encoding, such as SJIS (Jiang Guiqing) +

  • Make pg_dump dump SEQUENCE SET items in + the data not pre-data section of the archive (Tom Lane) +

    This change fixes dumping of sequences that are marked as extension + configuration tables. +

  • Fix bugs in the restore.sql script emitted by + pg_dump in tar output format (Tom Lane) +

    The script would fail outright on tables whose names include + upper-case characters. Also, make the script capable of restoring + data in --inserts mode as well as the regular COPY mode. +

  • Fix pg_restore to accept POSIX-conformant + tar files (Brian Weaver, Tom Lane) +

    The original coding of pg_dump's tar + output mode produced files that are not fully conformant with the + POSIX standard. This has been corrected for version 9.3. This + patch updates previous branches so that they will accept both the + incorrect and the corrected formats, in hopes of avoiding + compatibility problems when 9.3 comes out. +

  • Fix tar files emitted by pg_basebackup to + be POSIX conformant (Brian Weaver, Tom Lane) +

  • Fix pg_resetxlog to locate postmaster.pid + correctly when given a relative path to the data directory (Tom Lane) +

    This mistake could lead to pg_resetxlog not noticing + that there is an active postmaster using the data directory. +

  • Fix libpq's lo_import() and + lo_export() functions to report file I/O errors properly + (Tom Lane) +

  • Fix ecpg's processing of nested structure pointer + variables (Muhammad Usama) +

  • Fix ecpg's ecpg_get_data function to + handle arrays properly (Michael Meskes) +

  • Make contrib/pageinspect's btree page inspection + functions take buffer locks while examining pages (Tom Lane) +

  • Ensure that make install for an extension creates the + extension installation directory (Cédric Villemain) +

    Previously, this step was missed if MODULEDIR was set in + the extension's Makefile. +

  • Fix pgxs support for building loadable modules on AIX + (Tom Lane) +

    Building modules outside the original source tree didn't work on AIX. +

  • Update time zone data files to tzdata release 2012j + for DST law changes in Cuba, Israel, Jordan, Libya, Palestine, Western + Samoa, and portions of Brazil. +


PrevHomeNext
Release 9.2UpRelease 9.1.6
\ No newline at end of file diff --git a/doc/src/sgml/html/release-9-1.html b/doc/src/sgml/html/release-9-1.html new file mode 100644 index 000000000..52518aa87 --- /dev/null +++ b/doc/src/sgml/html/release-9-1.html @@ -0,0 +1,4663 @@ + +Release 9.1

E.11. Release 9.1

Release Date: 2011-09-12

E.11.1. Overview

This release shows PostgreSQL moving beyond the + traditional relational-database feature set with new, ground-breaking + functionality that is unique to PostgreSQL. + The streaming replication feature introduced in release 9.0 is + significantly enhanced by adding a synchronous-replication option, + streaming backups, and monitoring improvements. + Major enhancements include: +

The above items are explained in more detail in the sections below. +

E.11.2. Migration to Version 9.1

A dump/restore using pg_dump, + or use of pg_upgrade, is required + for those wishing to migrate data from any previous + release. +

Version 9.1 contains a number of changes that may affect compatibility + with previous releases. Observe the following incompatibilities: +

E.11.2.1. Strings

  • Change the default value of standard_conforming_strings + to on (Robert Haas) +

    By default, backslashes are now ordinary characters in string literals, + not escape characters. This change removes a long-standing + incompatibility with the SQL standard. escape_string_warning + has produced warnings about this usage for years. E'' + strings are the proper way to embed backslash escapes in strings and are + unaffected by this change. +

    Warning

    This change can break applications that are not expecting it and + do their own string escaping according to the old rules. The + consequences could be as severe as introducing SQL-injection security + holes. Be sure to test applications that are exposed to untrusted + input, to ensure that they correctly handle single quotes and + backslashes in text strings. +

E.11.2.2. Casting

  • Disallow function-style and attribute-style data type casts for + composite types (Tom Lane) +

    For example, disallow + composite_value.text and + text(composite_value). + Unintentional uses of this syntax have frequently resulted in bug + reports; although it was not a bug, it seems better to go back to + rejecting such expressions. + The CAST and :: syntaxes are still available + for use when a cast of an entire composite value is actually intended. +

  • Tighten casting checks for domains based on arrays (Tom Lane) +

    When a domain is based on an array type, it is allowed to "look + through" the domain type to access the array elements, including + subscripting the domain value to fetch or assign an element. + Assignment to an element of such a domain value, for instance via + UPDATE ... SET domaincol[5] = ..., will now result in + rechecking the domain type's constraints, whereas before the checks + were skipped. +

E.11.2.3. Arrays

  • Change string_to_array() + to return an empty array for a zero-length string (Pavel + Stehule) +

    Previously this returned a null value. +

  • Change string_to_array() + so a NULL separator splits the string into characters + (Pavel Stehule) +

    Previously this returned a null value. +

E.11.2.4. Object Modification

  • Fix improper checks for before/after triggers (Tom Lane) +

    Triggers can now be fired in three cases: BEFORE, + AFTER, or INSTEAD OF some action. + Trigger function authors should verify that their logic behaves + sanely in all three cases. +

  • Require superuser or CREATEROLE permissions in order to + set comments on roles (Tom Lane) +

E.11.2.5. Server Settings

  • Change pg_last_xlog_receive_location() + so it never moves backwards (Fujii Masao) +

    Previously, the value of pg_last_xlog_receive_location() + could move backward when streaming replication is restarted. +

  • Have logging of replication connections honor log_connections + (Magnus Hagander) +

    Previously, replication connections were always logged. +

E.11.2.6. PL/pgSQL Server-Side Language

  • Change PL/pgSQL's RAISE command without parameters + to be catchable by the attached exception block (Piyush Newe) +

    Previously RAISE in a code block was always scoped to + an attached exception block, so it was uncatchable at the same + scope. +

  • Adjust PL/pgSQL's error line numbering code to be consistent + with other PLs (Pavel Stehule) +

    Previously, PL/pgSQL would ignore (not count) an empty line at the + start of the function body. Since this was inconsistent with all + other languages, the special case was removed. +

  • Make PL/pgSQL complain about conflicting IN and OUT parameter names + (Tom Lane) +

    Formerly, the collision was not detected, and the name would just + silently refer to only the OUT parameter. +

  • Type modifiers of PL/pgSQL variables are now visible to the SQL parser + (Tom Lane) +

    A type modifier (such as a varchar length limit) attached to a PL/pgSQL + variable was formerly enforced during assignments, but was ignored for + all other purposes. Such variables will now behave more like table + columns declared with the same modifier. This is not expected to make + any visible difference in most cases, but it could result in subtle + changes for some SQL commands issued by PL/pgSQL functions. +

E.11.2.7. Contrib

  • All contrib modules are now installed with CREATE EXTENSION + rather than by manually invoking their SQL scripts + (Dimitri Fontaine, Tom Lane) +

    To update an existing database containing the 9.0 version of a contrib + module, use CREATE EXTENSION ... FROM unpackaged + to wrap the existing contrib module's objects into an extension. When + updating from a pre-9.0 version, drop the contrib module's objects + using its old uninstall script, then use CREATE EXTENSION. +

E.11.2.8. Other Incompatibilities

  • Make pg_stat_reset() + reset all database-level statistics (Tomas Vondra) +

    Some pg_stat_database counters were not being reset. +

  • Fix some information_schema.triggers + column names to match the new SQL-standard names (Dean Rasheed) +

  • Treat ECPG cursor names as case-insensitive + (Zoltan Boszormenyi) +

E.11.3. Changes

Below you will find a detailed account of the changes between + PostgreSQL 9.1 and the previous major + release. +

E.11.3.1. Server

E.11.3.1.1. Performance

  • Support unlogged tables using the UNLOGGED + option in CREATE + TABLE (Robert Haas) +

    Such tables provide better update performance than regular tables, + but are not crash-safe: their contents are automatically cleared in + case of a server crash. Their contents do not propagate to + replication slaves, either. +

  • Allow FULL OUTER JOIN to be implemented as a + hash join, and allow either side of a LEFT OUTER JOIN + or RIGHT OUTER JOIN to be hashed (Tom Lane) +

    Previously FULL OUTER JOIN could only be + implemented as a merge join, and LEFT OUTER JOIN + and RIGHT OUTER JOIN could hash only the nullable + side of the join. These changes provide additional query optimization + possibilities. +

  • Merge duplicate fsync requests (Robert Haas, Greg Smith) +

    This greatly improves performance under heavy write loads. +

  • Improve performance of commit_siblings + (Greg Smith) +

    This allows the use of commit_siblings with + less overhead. +

  • Reduce the memory requirement for large ispell dictionaries + (Pavel Stehule, Tom Lane) +

  • Avoid leaving data files open after "blind writes" + (Alvaro Herrera) +

    This fixes scenarios in which backends might hold files open long + after they were deleted, preventing the kernel from reclaiming + disk space. +

E.11.3.1.2. Optimizer

  • Allow inheritance table scans to return meaningfully-sorted + results (Greg Stark, Hans-Jurgen Schonig, Robert Haas, Tom Lane) +

    This allows better optimization of queries that use ORDER + BY, LIMIT, or MIN/MAX with + inherited tables. +

  • Improve GIN index scan cost estimation (Teodor Sigaev) +

  • Improve cost estimation for aggregates and window functions (Tom Lane) +

E.11.3.1.3. Authentication

  • Support host names and host suffixes + (e.g. .example.com) in pg_hba.conf + (Peter Eisentraut) +

    Previously only host IP addresses and CIDR + values were supported. +

  • Support the key word all in the host column of pg_hba.conf + (Peter Eisentraut) +

    Previously people used 0.0.0.0/0 or ::/0 + for this. +

  • Reject local lines in pg_hba.conf + on platforms that don't support Unix-socket connections + (Magnus Hagander) +

    Formerly, such lines were silently ignored, which could be surprising. + This makes the behavior more like other unsupported cases. +

  • Allow GSSAPI + to be used to authenticate to servers via SSPI (Christian Ullrich) +

    Specifically this allows Unix-based GSSAPI clients + to do SSPI authentication with Windows servers. +

  • ident + authentication over local sockets is now known as + peer + (Magnus Hagander) +

    The old term is still accepted for backward compatibility, but since + the two methods are fundamentally different, it seemed better to adopt + different names for them. +

  • Rewrite peer + authentication to avoid use of credential control messages (Tom Lane) +

    This change makes the peer authentication code simpler and + better-performing. However, it requires the platform to provide the + getpeereid function or an equivalent socket operation. + So far as is known, the only platform for which peer authentication + worked before and now will not is pre-5.0 NetBSD. +

E.11.3.1.4. Monitoring

  • Add details to the logging of restartpoints and checkpoints, + which is controlled by log_checkpoints + (Fujii Masao, Greg Smith) +

    New details include WAL file and sync activity. +

  • Add log_file_mode + which controls the permissions on log files created by the + logging collector (Martin Pihlak) +

  • Reduce the default maximum line length for syslog + logging to 900 bytes plus prefixes (Noah Misch) +

    This avoids truncation of long log lines on syslog implementations + that have a 1KB length limit, rather than the more common 2KB. +

E.11.3.1.5. Statistical Views

  • Add client_hostname column to pg_stat_activity + (Peter Eisentraut) +

    Previously only the client address was reported. +

  • Add pg_stat_xact_* + statistics functions and views (Joel Jacobson) +

    These are like the database-wide statistics counter views, but + reflect counts for only the current transaction. +

  • Add time of last reset in database-level and background writer + statistics views (Tomas Vondra) +

  • Add columns showing the number of vacuum and analyze operations + in pg_stat_*_tables + views (Magnus Hagander) +

  • Add buffers_backend_fsync column to pg_stat_bgwriter + (Greg Smith) +

    This new column counts the number of times a backend fsyncs a + buffer. +

E.11.3.1.6. Server Settings

  • Provide auto-tuning of wal_buffers (Greg + Smith) +

    By default, the value of wal_buffers is now chosen + automatically based on the value of shared_buffers. +

  • Increase the maximum values for + deadlock_timeout, + log_min_duration_statement, and + log_autovacuum_min_duration + (Peter Eisentraut) +

    The maximum value for each of these parameters was previously + only about 35 minutes. Much larger values are now allowed. +

E.11.3.2. Replication and Recovery

E.11.3.2.1. Streaming Replication and Continuous Archiving

  • Allow synchronous + replication (Simon Riggs, Fujii Masao) +

    This allows the primary server to wait for a standby to write a + transaction's information to disk before acknowledging the commit. + One standby at a time can take the role of the synchronous standby, + as controlled by the + synchronous_standby_names + setting. Synchronous replication can be enabled or disabled on a + per-transaction basis using the + synchronous_commit + setting. +

  • Add protocol support for sending file system backups to standby servers + using the streaming replication network connection (Magnus Hagander, + Heikki Linnakangas) +

    This avoids the requirement of manually transferring a file + system backup when setting up a standby server. +

  • Add + replication_timeout + setting (Fujii Masao, Heikki Linnakangas) +

    Replication connections that are idle for more than the + replication_timeout interval will be terminated + automatically. Formerly, a failed connection was typically not + detected until the TCP timeout elapsed, which is inconveniently + long in many situations. +

  • Add command-line tool pg_basebackup + for creating a new standby server or database backup (Magnus + Hagander) +

  • Add a replication permission + for roles (Magnus Hagander) +

    This is a read-only permission used for streaming replication. + It allows a non-superuser role to be used for replication connections. + Previously only superusers could initiate replication + connections; superusers still have this permission by default. +

E.11.3.2.2. Replication Monitoring

  • Add system view pg_stat_replication + which displays activity of WAL sender processes (Itagaki + Takahiro, Simon Riggs) +

    This reports the status of all connected standby servers. +

  • Add monitoring function pg_last_xact_replay_timestamp() + (Fujii Masao) +

    This returns the time at which the primary generated the most + recent commit or abort record applied on the standby. +

E.11.3.2.3. Hot Standby

  • Add configuration parameter hot_standby_feedback + to enable standbys to postpone cleanup of old row versions on the + primary (Simon Riggs) +

    This helps avoid canceling long-running queries on the standby. +

  • Add the pg_stat_database_conflicts + system view to show queries that have been canceled and the + reason (Magnus Hagander) +

    Cancellations can occur because of dropped tablespaces, lock + timeouts, old snapshots, pinned buffers, and deadlocks. +

  • Add a conflicts count to pg_stat_database + (Magnus Hagander) +

    This is the number of conflicts that occurred in the database. +

  • Increase the maximum values for + max_standby_archive_delay and + max_standby_streaming_delay +

    The maximum value for each of these parameters was previously + only about 35 minutes. Much larger values are now allowed. +

  • Add ERRCODE_T_R_DATABASE_DROPPED + error code to report recovery conflicts due to dropped databases + (Tatsuo Ishii) +

    This is useful for connection pooling software. +

E.11.3.2.4. Recovery Control

  • Add functions to control streaming replication replay (Simon Riggs) +

    The new functions are pg_xlog_replay_pause(), + pg_xlog_replay_resume(), + and the status function pg_is_xlog_replay_paused(). +

  • Add recovery.conf setting pause_at_recovery_target + to pause recovery at target (Simon Riggs) +

    This allows a recovery server to be queried to check whether + the recovery point is the one desired. +

  • Add the ability to create named restore points using pg_create_restore_point() + (Jaime Casanova) +

    These named restore points can be specified as recovery + targets using the new recovery.conf setting + recovery_target_name. +

  • Allow standby recovery to switch to a new timeline automatically + (Heikki Linnakangas) +

    Now standby servers scan the archive directory for new + timelines periodically. +

  • Add restart_after_crash + setting which disables automatic server restart after a backend + crash (Robert Haas) +

    This allows external cluster management software to control + whether the database server restarts or not. +

  • Allow recovery.conf + to use the same quoting behavior as postgresql.conf + (Dimitri Fontaine) +

    Previously all values had to be quoted. +

E.11.3.3. Queries

  • Add a true serializable isolation level + (Kevin Grittner, Dan Ports) +

    Previously, asking for serializable isolation guaranteed only that a + single MVCC snapshot would be used for the entire transaction, which + allowed certain documented anomalies. The old snapshot isolation + behavior is still available by requesting the REPEATABLE READ + isolation level. +

  • Allow data-modification commands + (INSERT/UPDATE/DELETE) in + WITH clauses + (Marko Tiikkaja, Hitoshi Harada) +

    These commands can use RETURNING to pass data up to the + containing query. +

  • Allow WITH + clauses to be attached to INSERT, UPDATE, + DELETE statements (Marko Tiikkaja, Hitoshi Harada) +

  • Allow non-GROUP + BY columns in the query target list when the primary + key is specified in the GROUP BY clause (Peter + Eisentraut) +

    The SQL standard allows this behavior, and + because of the primary key, the result is unambiguous. +

  • Allow use of the key word DISTINCT in UNION/INTERSECT/EXCEPT + clauses (Tom Lane) +

    DISTINCT is the default behavior so use of this + key word is redundant, but the SQL standard allows it. +

  • Fix ordinary queries with rules to use the same snapshot behavior + as EXPLAIN ANALYZE (Marko Tiikkaja) +

    Previously EXPLAIN ANALYZE used slightly different + snapshot timing for queries involving rules. The + EXPLAIN ANALYZE behavior was judged to be more logical. +

E.11.3.3.1. Strings

  • Add per-column collation support + (Peter Eisentraut, Tom Lane) +

    Previously collation (the sort ordering of text strings) could only be + chosen at database creation. + Collation can now be set per column, domain, index, or + expression, via the SQL-standard COLLATE clause. +

E.11.3.4. Object Manipulation

  • Add extensions which + simplify packaging of additions to PostgreSQL + (Dimitri Fontaine, Tom Lane) +

    Extensions are controlled by the new CREATE/ALTER/DROP EXTENSION + commands. This replaces ad-hoc methods of grouping objects that + are added to a PostgreSQL installation. +

  • Add support for foreign + tables (Shigeru Hanada, Robert Haas, Jan Urbanski, + Heikki Linnakangas) +

    This allows data stored outside the database to be used like + native PostgreSQL-stored data. Foreign tables + are currently read-only, however. +

  • Allow new values to be added to an existing enum type via + ALTER TYPE (Andrew + Dunstan) +

  • Add ALTER TYPE ... + ADD/DROP/ALTER/RENAME ATTRIBUTE (Peter Eisentraut) +

    This allows modification of composite types. +

E.11.3.4.1. ALTER Object

  • Add RESTRICT/CASCADE to ALTER TYPE operations + on typed tables (Peter Eisentraut) +

    This controls + ADD/DROP/ALTER/RENAME + ATTRIBUTE cascading behavior. +

  • Support ALTER TABLE name {OF | NOT OF} + type + (Noah Misch) +

    This syntax allows a standalone table to be made into a typed table, + or a typed table to be made standalone. +

  • Add support for more object types in ALTER ... SET + SCHEMA commands (Dimitri Fontaine) +

    This command is now supported for conversions, operators, operator + classes, operator families, text search configurations, text search + dictionaries, text search parsers, and text search templates. +

E.11.3.4.2. CREATE/ALTER TABLE

  • Add ALTER TABLE ... + ADD UNIQUE/PRIMARY KEY USING INDEX + (Gurjeet Singh) +

    This allows a primary key or unique constraint to be defined using an + existing unique index, including a concurrently created unique index. +

  • Allow ALTER TABLE + to add foreign keys without validation (Simon Riggs) +

    The new option is called NOT VALID. The constraint's + state can later be modified to VALIDATED and validation + checks performed. Together these allow you to add a foreign key + with minimal impact on read and write operations. +

  • Allow ALTER TABLE + ... SET DATA TYPE to avoid table rewrites in + appropriate cases (Noah Misch, Robert Haas) +

    For example, converting a varchar column to + text no longer requires a rewrite of the table. + However, increasing the length constraint on a + varchar column still requires a table rewrite. +

  • Add CREATE TABLE IF + NOT EXISTS syntax (Robert Haas) +

    This allows table creation without causing an error if the + table already exists. +

  • Fix possible "tuple concurrently updated" error + when two backends attempt to add an inheritance + child to the same table at the same time (Robert Haas) +

    ALTER TABLE + now takes a stronger lock on the parent table, so that the sessions + cannot try to update it simultaneously. +

E.11.3.4.3. Object Permissions

  • Add a SECURITY + LABEL command (KaiGai Kohei) +

    This allows security labels to be assigned to objects. +

E.11.3.5. Utility Operations

  • Add transaction-level advisory + locks (Marko Tiikkaja) +

    These are similar to the existing session-level advisory locks, + but such locks are automatically released at transaction end. +

  • Make TRUNCATE ... RESTART + IDENTITY restart sequences transactionally (Steve + Singer) +

    Previously the counter could have been left out of sync if a + backend crashed between the on-commit truncation activity and + commit completion. +

E.11.3.5.1. COPY

  • Add ENCODING option to COPY TO/FROM (Hitoshi + Harada, Itagaki Takahiro) +

    This allows the encoding of the COPY file to be + specified separately from client encoding. +

  • Add bidirectional COPY + protocol support (Fujii Masao) +

    This is currently only used by streaming replication. +

E.11.3.5.2. EXPLAIN

  • Make EXPLAIN VERBOSE show the function call expression + in a FunctionScan node (Tom Lane) +

E.11.3.5.3. VACUUM

  • Add additional details to the output of VACUUM FULL VERBOSE + and CLUSTER VERBOSE + (Itagaki Takahiro) +

    New information includes the live and dead tuple count and + whether CLUSTER is using an index to rebuild. +

  • Prevent autovacuum from + waiting if it cannot acquire a table lock (Robert Haas) +

    It will try to vacuum that table later. +

E.11.3.5.4. CLUSTER

  • Allow CLUSTER to sort the table rather than scanning + the index when it seems likely to be cheaper (Leonardo Francalanci) +

E.11.3.5.5. Indexes

  • Add nearest-neighbor (order-by-operator) searching to GiST indexes (Teodor Sigaev, Tom Lane) +

    This allows GiST indexes to quickly return the + N closest values in a query with LIMIT. + For example +

    SELECT * FROM places ORDER BY location <-> point '(101,456)' LIMIT 10;

    + finds the ten places closest to a given target point. +

  • Allow GIN indexes to index null + and empty values (Tom Lane) +

    This allows full GIN index scans, and fixes various + corner cases in which GIN scans would fail. +

  • Allow GIN indexes to + better recognize duplicate search entries (Tom Lane) +

    This reduces the cost of index scans, especially in cases where + it avoids unnecessary full index scans. +

  • Fix GiST indexes to be fully + crash-safe (Heikki Linnakangas) +

    Previously there were rare cases where a REINDEX + would be required (you would be informed). +

E.11.3.6. Data Types

  • Allow numeric to use a more compact, two-byte header + in common cases (Robert Haas) +

    Previously all numeric values had four-byte headers; + this change saves on disk storage. +

  • Add support for dividing money by money + (Andy Balholm) +

  • Allow binary I/O on type void (Radoslaw Smogura) +

  • Improve hypotenuse calculations for geometric operators (Paul Matthews) +

    This avoids unnecessary overflows, and may also be more accurate. +

  • Support hashing array values (Tom Lane) +

    This provides additional query optimization possibilities. +

  • Don't treat a composite type as sortable unless all its column types + are sortable (Tom Lane) +

    This avoids possible "could not identify a comparison function" + failures at runtime, if it is possible to implement the query without + sorting. Also, ANALYZE won't try to use inappropriate + statistics-gathering methods for columns of such composite types. +

E.11.3.6.1. Casting

  • Add support for casting between money and numeric + (Andy Balholm) +

  • Add support for casting from int4 and int8 + to money (Joey Adams) +

  • Allow casting a table's row type to the table's supertype if + it's a typed table (Peter Eisentraut) +

    This is analogous to the existing facility that allows casting a row + type to a supertable's row type. +

E.11.3.6.2. XML

E.11.3.7. Functions

  • Add SQL function format(text, ...), which + behaves analogously to C's printf() (Pavel Stehule, + Robert Haas) +

    It currently supports formats for strings, SQL literals, and + SQL identifiers. +

  • Add string functions concat(), + concat_ws(), + left(), + right(), + and reverse() + (Pavel Stehule) +

    These improve compatibility with other database products. +

  • Add function pg_read_binary_file() + to read binary files (Dimitri Fontaine, Itagaki Takahiro) +

  • Add a single-parameter version of function pg_read_file() + to read an entire file (Dimitri Fontaine, Itagaki Takahiro) +

  • Add three-parameter forms of array_to_string() + and string_to_array() + for null value processing control (Pavel Stehule) +

E.11.3.7.1. Object Information Functions

  • Add the pg_describe_object() + function (Alvaro Herrera) +

    This function is used to obtain a human-readable string describing + an object, based on the pg_class + OID, object OID, and sub-object ID. It can be used to help + interpret the contents of pg_depend. +

  • Update comments for built-in operators and their underlying + functions (Tom Lane) +

    Functions that are meant to be used via an associated operator + are now commented as such. +

  • Add variable quote_all_identifiers + to force the quoting of all identifiers in EXPLAIN + and in system catalog functions like pg_get_viewdef() + (Robert Haas) +

    This makes exporting schemas to tools and other databases with + different quoting rules easier. +

  • Add columns to the information_schema.sequences + system view (Peter Eisentraut) +

    Previously, though the view existed, the columns about the + sequence parameters were unimplemented. +

  • Allow public as a pseudo-role name in has_table_privilege() + and related functions (Alvaro Herrera) +

    This allows checking for public permissions. +

E.11.3.7.2. Function and Trigger Creation

  • Support INSTEAD + OF triggers on views (Dean Rasheed) +

    This feature can be used to implement fully updatable views. +

E.11.3.8. Server-Side Languages

E.11.3.8.1. PL/pgSQL Server-Side Language

  • Add FOREACH IN + ARRAY to PL/pgSQL + (Pavel Stehule) +

    This is more efficient and readable than previous methods of + iterating through the elements of an array value. +

  • Allow RAISE without parameters to be caught in + the same places that could catch a RAISE ERROR + from the same location (Piyush Newe) +

    The previous coding threw the error + from the block containing the active exception handler. + The new behavior is more consistent with other DBMS products. +

E.11.3.8.2. PL/Perl Server-Side Language

  • Allow generic record arguments to PL/Perl functions (Andrew + Dunstan) +

    PL/Perl functions can now be declared to accept type record. + The behavior is the same as for any named composite type. +

  • Convert PL/Perl array arguments to Perl arrays (Alexey Klyukin, + Alex Hunsaker) +

    String representations are still available. +

  • Convert PL/Perl composite-type arguments to Perl hashes + (Alexey Klyukin, Alex Hunsaker) +

    String representations are still available. +

E.11.3.8.3. PL/Python Server-Side Language

  • Add table function support for PL/Python (Jan Urbanski) +

    PL/Python can now return multiple OUT parameters + and record sets. +

  • Add a validator to PL/Python (Jan Urbanski) +

    This allows PL/Python functions to be syntax-checked at function + creation time. +

  • Allow exceptions for SQL queries in PL/Python (Jan Urbanski) +

    This allows access to SQL-generated exception error codes from + PL/Python exception blocks. +

  • Add explicit subtransactions to PL/Python (Jan Urbanski) +

  • Add PL/Python functions for quoting strings (Jan Urbanski) +

    These functions are plpy.quote_ident, + plpy.quote_literal, + and plpy.quote_nullable. +

  • Add traceback information to PL/Python errors (Jan Urbanski) +

  • Report PL/Python errors from iterators with PLy_elog (Jan + Urbanski) +

  • Fix exception handling with Python 3 (Jan Urbanski) +

    Exception classes were previously not available in + plpy under Python 3. +

E.11.3.9. Client Applications

  • Mark createlang + and droplang + as deprecated now that they just invoke extension commands (Tom + Lane) +

E.11.3.9.1. psql

  • Add psql command \conninfo + to show current connection information (David Christensen) +

  • Add psql command \sf to + show a function's definition (Pavel Stehule) +

  • Add psql command \dL to list + languages (Fernando Ike) +

  • Add the S ("system") option to psql's + \dn (list schemas) command (Tom Lane) +

    \dn without S now suppresses system + schemas. +

  • Allow psql's \e and \ef + commands to accept a line number to be used to position the + cursor in the editor (Pavel Stehule) +

    This is passed to the editor according to the + PSQL_EDITOR_LINENUMBER_ARG environment variable. +

  • Have psql set the client encoding from the + operating system locale by default (Heikki Linnakangas) +

    This only happens if the PGCLIENTENCODING environment + variable is not set. +

  • Make \d distinguish between unique + indexes and unique constraints (Josh Kupershmidt) +

  • Make \dt+ report pg_table_size + instead of pg_relation_size when talking to 9.0 or + later servers (Bernd Helmle) +

    This is a more useful measure of table size, but note that it is + not identical to what was previously reported in the same display. +

  • Additional tab completion support (Itagaki Takahiro, Pavel Stehule, + Andrey Popp, Christoph Berg, David Fetter, Josh Kupershmidt) +

E.11.3.9.2. pg_dump

  • Add pg_dump + and pg_dumpall + option --quote-all-identifiers to force quoting + of all identifiers (Robert Haas) +

  • Add directory format to pg_dump + (Joachim Wieland, Heikki Linnakangas) +

    This is internally similar to the tar + pg_dump format. +

E.11.3.9.3. pg_ctl

  • Fix pg_ctl + so it no longer incorrectly reports that the server is not + running (Bruce Momjian) +

    Previously this could happen if the server was running but + pg_ctl could not authenticate. +

  • Improve pg_ctl start's "wait" + (-w) option (Bruce Momjian, Tom Lane) +

    The wait mode is now significantly more robust. It will not get + confused by non-default postmaster port numbers, non-default + Unix-domain socket locations, permission problems, or stale + postmaster lock files. +

  • Add promote option to pg_ctl to + switch a standby server to primary (Fujii Masao) +

E.11.3.10. Development Tools

E.11.3.10.1. libpq

  • Add a libpq connection option client_encoding + which behaves like the PGCLIENTENCODING environment + variable (Heikki Linnakangas) +

    The value auto sets the client encoding based on + the operating system locale. +

  • Add PQlibVersion() + function which returns the libpq library version (Magnus + Hagander) +

    libpq already had PQserverVersion() which returns + the server version. +

  • Allow libpq-using clients to + check the user name of the server process + when connecting via Unix-domain sockets, with the new requirepeer + connection option + (Peter Eisentraut) +

    PostgreSQL already allowed servers to check + the client user name when connecting via Unix-domain sockets. +

  • Add PQping() + and PQpingParams() + to libpq (Bruce Momjian, Tom Lane) +

    These functions allow detection of the server's status without + trying to open a new session. +

E.11.3.10.2. ECPG

  • Allow ECPG to accept dynamic cursor names even in + WHERE CURRENT OF clauses + (Zoltan Boszormenyi) +

  • Make ecpglib write double values with a + precision of 15 digits, not 14 as formerly (Akira Kurosawa) +

E.11.3.11. Build Options

  • Use +Olibmerrno compile flag with HP-UX C compilers + that accept it (Ibrar Ahmed) +

    This avoids possible misbehavior of math library calls on recent + HP platforms. +

E.11.3.11.1. Makefiles

  • Improved parallel make support (Peter Eisentraut) +

    This allows for faster compiles. Also, make -k + now works more consistently. +

  • Require GNU make + 3.80 or newer (Peter Eisentraut) +

    This is necessary because of the parallel-make improvements. +

  • Add make maintainer-check target + (Peter Eisentraut) +

    This target performs various source code checks that are not + appropriate for either the build or the regression tests. Currently: + duplicate_oids, SGML syntax and tabs check, NLS syntax check. +

  • Support make check in contrib + (Peter Eisentraut) +

    Formerly only make installcheck worked, but now + there is support for testing in a temporary installation. + The top-level make check-world target now includes + testing contrib this way. +

E.11.3.11.2. Windows

  • On Windows, allow pg_ctl to register + the service as auto-start or start-on-demand (Quan Zongliang) +

  • Add support for collecting crash + dumps on Windows (Craig Ringer, Magnus Hagander) +

    minidumps can now be generated by non-debug + Windows binaries and analyzed by standard debugging tools. +

  • Enable building with the MinGW64 compiler (Andrew Dunstan) +

    This allows building 64-bit Windows binaries even on non-Windows + platforms via cross-compiling. +

E.11.3.12. Source Code

  • Revise the API for GUC variable assign hooks (Tom Lane) +

    The previous functions of assign hooks are now split between check + hooks and assign hooks, where the former can fail but the latter + shouldn't. This change will impact add-on modules that define custom + GUC parameters. +

  • Add latches to the source code to support waiting for events (Heikki + Linnakangas) +

  • Centralize data modification permissions-checking logic + (KaiGai Kohei) +

  • Add missing get_object_oid() functions, for consistency + (Robert Haas) +

  • Improve ability to use C++ compilers for compiling add-on modules by removing + conflicting key words (Tom Lane) +

  • Add support for DragonFly BSD (Rumko) +

  • Expose quote_literal_cstr() for backend use + (Robert Haas) +

  • Run regression tests in the + default encoding (Peter Eisentraut) +

    Regression tests were previously always run with + SQL_ASCII encoding. +

  • Add src/tools/git_changelog to replace + cvs2cl and pgcvslog (Robert + Haas, Tom Lane) +

  • Add git-external-diff script to + src/tools (Bruce Momjian) +

    This is used to generate context diffs from git. +

  • Improve support for building with + Clang (Peter Eisentraut) +

E.11.3.12.1. Server Hooks

  • Add source code hooks to check permissions (Robert Haas, + Stephen Frost) +

  • Add post-object-creation function hooks for use by security + frameworks (KaiGai Kohei) +

  • Add a client authentication hook (KaiGai Kohei) +

E.11.3.13. Contrib

  • Modify contrib modules and procedural + languages to install via the new extension mechanism (Tom Lane, + Dimitri Fontaine) +

  • Add contrib/file_fdw + foreign-data wrapper (Shigeru Hanada) +

    Foreign tables using this foreign data wrapper can read flat files + in a manner very similar to COPY. +

  • Add nearest-neighbor search support to contrib/pg_trgm and contrib/btree_gist + (Teodor Sigaev) +

  • Add contrib/btree_gist + support for searching on not-equals (Jeff Davis) +

  • Fix contrib/fuzzystrmatch's + levenshtein() function to handle multibyte characters + (Alexander Korotkov) +

  • Add ssl_cipher() and ssl_version() + functions to contrib/sslinfo (Robert + Haas) +

  • Fix contrib/intarray + and contrib/hstore + to give consistent results with indexed empty arrays (Tom Lane) +

    Previously an empty-array query that used an index might return + different results from one that used a sequential scan. +

  • Allow contrib/intarray + to work properly on multidimensional arrays (Tom Lane) +

  • In + contrib/intarray, + avoid errors complaining about the presence of nulls in cases where no + nulls are actually present (Tom Lane) +

  • In + contrib/intarray, + fix behavior of containment operators with respect to empty arrays + (Tom Lane) +

    Empty arrays are now correctly considered to be contained in any other + array. +

  • Remove contrib/xml2's + arbitrary limit on the number of + parameter=value pairs that can be + handled by xslt_process() (Pavel Stehule) +

    The previous limit was 10. +

  • In contrib/pageinspect, + fix heap_page_item to return infomasks as 32-bit values (Alvaro Herrera) +

    This avoids returning negative values, which was confusing. The + underlying value is a 16-bit unsigned integer. +

E.11.3.13.1. Security

  • Add contrib/sepgsql + to interface permission checks with SELinux (KaiGai Kohei) +

    This uses the new SECURITY LABEL + facility. +

  • Add contrib module auth_delay (KaiGai + Kohei) +

    This causes the server to pause before returning authentication + failure; it is designed to make brute force password attacks + more difficult. +

  • Add dummy_seclabel + contrib module (KaiGai Kohei) +

    This is used for permission regression testing. +

E.11.3.13.2. Performance

  • Add support for LIKE and ILIKE index + searches to contrib/pg_trgm (Alexander + Korotkov) +

  • Add levenshtein_less_equal() function to contrib/fuzzystrmatch, + which is optimized for small distances (Alexander Korotkov) +

  • Improve performance of index lookups on contrib/seg columns (Alexander + Korotkov) +

  • Improve performance of pg_upgrade for + databases with many relations (Bruce Momjian) +

  • Add flag to contrib/pgbench to + report per-statement latencies (Florian Pflug) +

E.11.3.13.3. Fsync Testing

E.11.3.14. Documentation

  • Extensive ECPG + documentation improvements (Satoshi Nagayasu) +

  • Extensive proofreading and documentation improvements + (Thom Brown, Josh Kupershmidt, Susanne Ebrecht) +

  • Add documentation for exit_on_error + (Robert Haas) +

    This parameter causes sessions to exit on any error. +

  • Add documentation for pg_options_to_table() + (Josh Berkus) +

    This function shows table storage options in a readable form. +

  • Document that it is possible to access all composite type + fields using (compositeval).* + syntax (Peter Eisentraut) +

  • Document that translate() + removes characters in from that don't have a + corresponding to character (Josh Kupershmidt) +

  • Merge documentation for CREATE CONSTRAINT TRIGGER and CREATE TRIGGER + (Alvaro Herrera) +

  • Centralize permission and upgrade documentation (Bruce Momjian) +

  • Add kernel tuning + documentation for Solaris 10 (Josh Berkus) +

    Previously only Solaris 9 kernel tuning was documented. +

  • Handle non-ASCII characters consistently in HISTORY file + (Peter Eisentraut) +

    While the HISTORY file is in English, we do have to deal + with non-ASCII letters in contributor names. These are now + transliterated so that they are reasonably legible without assumptions + about character set. +


PrevHomeNext
Release 9.1.1UpRelease 9.0.11
\ No newline at end of file diff --git a/doc/src/sgml/html/release-9-2-1.html b/doc/src/sgml/html/release-9-2-1.html new file mode 100644 index 000000000..3ece3b329 --- /dev/null +++ b/doc/src/sgml/html/release-9-2-1.html @@ -0,0 +1,397 @@ + +Release 9.2.1

E.2. Release 9.2.1

Release Date: 2012-09-24

This release contains a variety of fixes from 9.2.0. + For information about new features in the 9.2 major release, see + Section E.3. +

E.2.1. Migration to Version 9.2.1

A dump/restore is not required for those running 9.2.X. +

However, you may need to perform REINDEX and/or + VACUUM operations to recover from the effects of the data + corruption bug described in the first changelog item below. +

E.2.2. Changes

  • Fix persistence marking of shared buffers during WAL replay + (Jeff Davis) +

    This mistake can result in buffers not being written out during + checkpoints, resulting in data corruption if the server later crashes + without ever having written those buffers. Corruption can occur on + any server following crash recovery, but it is significantly more + likely to occur on standby slave servers since those perform much + more WAL replay. There is a low probability of corruption of btree + and GIN indexes. There is a much higher probability of corruption + of table "visibility maps", which might lead to wrong answers + from index-only scans. Table data proper cannot be corrupted by this + bug. +

    While no index corruption due to this bug is known to have occurred + in the field, as a precautionary measure it is recommended that + production installations REINDEX all btree and GIN + indexes at a convenient time after upgrading to 9.2.1. +

    Also, it is recommended to perform a VACUUM of all tables + while having vacuum_freeze_table_age + set to zero. This will fix any incorrect visibility map data. vacuum_cost_delay + can be adjusted to reduce the performance impact of vacuuming, while + causing it to take longer to finish. +

  • Fix possible incorrect sorting of output from queries involving + WHERE indexed_column IN + (list_of_values) (Tom Lane) +

  • Fix planner failure for queries involving GROUP BY + expressions along with window functions and aggregates (Tom Lane) +

  • Fix planner's assignment of executor parameters (Tom Lane) +

    This error could result in wrong answers from queries that scan the + same WITH subquery multiple times. +

  • Improve planner's handling of join conditions in index scans (Tom Lane) +

  • Improve selectivity estimation for text search queries involving + prefixes, i.e. word:* patterns (Tom Lane) +

  • Fix delayed recognition of permissions changes (Tom Lane) +

    A command that needed no locks other than ones its transaction already + had might fail to notice a concurrent GRANT or + REVOKE that committed since the start of its transaction. +

  • Fix ANALYZE to not fail when a column is a domain over an + array type (Tom Lane) +

  • Prevent PL/Perl from crashing if a recursive PL/Perl function is + redefined while being executed (Tom Lane) +

  • Work around possible misoptimization in PL/Perl (Tom Lane) +

    Some Linux distributions contain an incorrect version of + pthread.h that results in incorrect compiled code in + PL/Perl, leading to crashes if a PL/Perl function calls another one + that throws an error. +

  • Remove unnecessary dependency on pg_config from + pg_upgrade (Peter Eisentraut) +

  • Update time zone data files to tzdata release 2012f + for DST law changes in Fiji +


PrevHomeNext
Release 9.2.2UpRelease 9.2
\ No newline at end of file diff --git a/doc/src/sgml/html/release-9-2-2.html b/doc/src/sgml/html/release-9-2-2.html new file mode 100644 index 000000000..fe9074d72 --- /dev/null +++ b/doc/src/sgml/html/release-9-2-2.html @@ -0,0 +1,1136 @@ + +Release 9.2.2

E.1. Release 9.2.2

Release Date: 2012-12-06

This release contains a variety of fixes from 9.2.1. + For information about new features in the 9.2 major release, see + Section E.3. +

E.1.1. Migration to Version 9.2.2

A dump/restore is not required for those running 9.2.X. +

However, you may need to perform REINDEX operations to + correct problems in concurrently-built indexes, as described in the first + changelog item below. +

Also, if you are upgrading from version 9.2.0, + see the release notes for 9.2.1. +

E.1.2. Changes

  • Fix multiple bugs associated with CREATE/DROP INDEX + CONCURRENTLY (Andres Freund, Tom Lane, Simon Riggs, Pavan Deolasee) +

    An error introduced while adding DROP INDEX CONCURRENTLY + allowed incorrect indexing decisions to be made during the initial + phase of CREATE INDEX CONCURRENTLY; so that indexes built + by that command could be corrupt. It is recommended that indexes + built in 9.2.X with CREATE INDEX CONCURRENTLY be rebuilt + after applying this update. +

    In addition, fix CREATE/DROP INDEX CONCURRENTLY to use + in-place updates when changing the state of an index's + pg_index row. This prevents race conditions that could + cause concurrent sessions to miss updating the target index, thus + again resulting in corrupt concurrently-created indexes. +

    Also, fix various other operations to ensure that they ignore + invalid indexes resulting from a failed CREATE INDEX + CONCURRENTLY command. The most important of these is + VACUUM, because an auto-vacuum could easily be launched + on the table before corrective action can be taken to fix or remove + the invalid index. +

    Also fix DROP INDEX CONCURRENTLY to not disable + insertions into the target index until all queries using it are done. +

    Also fix misbehavior if DROP INDEX CONCURRENTLY is + canceled: the previous coding could leave an un-droppable index behind. +

  • Correct predicate locking for DROP INDEX CONCURRENTLY + (Kevin Grittner) +

    Previously, SSI predicate locks were processed at the wrong time, + possibly leading to incorrect behavior of serializable transactions + executing in parallel with the DROP. +

  • Fix buffer locking during WAL replay (Tom Lane) +

    The WAL replay code was insufficiently careful about locking buffers + when replaying WAL records that affect more than one page. This could + result in hot standby queries transiently seeing inconsistent states, + resulting in wrong answers or unexpected failures. +

  • Fix an error in WAL generation logic for GIN indexes (Tom Lane) +

    This could result in index corruption, if a torn-page failure occurred. +

  • Fix an error in WAL replay logic for SP-GiST indexes (Tom Lane) +

    This could result in index corruption after a crash, or on a standby + server. +

  • Fix incorrect detection of end-of-base-backup location during WAL + recovery (Heikki Linnakangas) +

    This mistake allowed hot standby mode to start up before the database + reaches a consistent state. +

  • Properly remove startup process's virtual XID lock when promoting a + hot standby server to normal running (Simon Riggs) +

    This oversight could prevent subsequent execution of certain + operations such as CREATE INDEX CONCURRENTLY. +

  • Avoid bogus "out-of-sequence timeline ID" errors in standby + mode (Heikki Linnakangas) +

  • Prevent the postmaster from launching new child processes after it's + received a shutdown signal (Tom Lane) +

    This mistake could result in shutdown taking longer than it should, or + even never completing at all without additional user action. +

  • Fix the syslogger process to not fail when + log_rotation_age exceeds 2^31 milliseconds (about 25 days) + (Tom Lane) +

  • Fix WaitLatch() to return promptly when the requested + timeout expires (Jeff Janes, Tom Lane) +

    With the previous coding, a steady stream of non-wait-terminating + interrupts could delay return from WaitLatch() + indefinitely. This has been shown to be a problem for the autovacuum + launcher process, and might cause trouble elsewhere as well. +

  • Avoid corruption of internal hash tables when out of memory + (Hitoshi Harada) +

  • Prevent file descriptors for dropped tables from being held open past + transaction end (Tom Lane) +

    This should reduce problems with long-since-dropped tables continuing + to occupy disk space. +

  • Prevent database-wide crash and restart when a new child process is + unable to create a pipe for its latch (Tom Lane) +

    Although the new process must fail, there is no good reason to force a + database-wide restart, so avoid that. This improves robustness when + the kernel is nearly out of file descriptors. +

  • Avoid planner crash with joins to unflattened subqueries (Tom Lane) +

  • Fix planning of non-strict equivalence clauses above outer joins + (Tom Lane) +

    The planner could derive incorrect constraints from a clause equating + a non-strict construct to something else, for example + WHERE COALESCE(foo, 0) = 0 + when foo is coming from the nullable side of an outer join. + 9.2 showed this type of error in more cases than previous releases, + but the basic bug has been there for a long time. +

  • Fix SELECT DISTINCT with index-optimized + MIN/MAX on an inheritance tree (Tom Lane) +

    The planner would fail with "failed to re-find MinMaxAggInfo + record" given this combination of factors. +

  • Make sure the planner sees implicit and explicit casts as equivalent + for all purposes, except in the minority of cases where there's + actually a semantic difference (Tom Lane) +

  • Include join clauses when considering whether partial indexes can be + used for a query (Tom Lane) +

    A strict join clause can be sufficient to establish an + x IS NOT NULL predicate, for example. + This fixes a planner regression in 9.2, since previous versions could + make comparable deductions. +

  • Limit growth of planning time when there are many indexable join + clauses for the same index (Tom Lane) +

  • Improve planner's ability to prove exclusion constraints from + equivalence classes (Tom Lane) +

  • Fix partial-row matching in hashed subplans to handle cross-type cases + correctly (Tom Lane) +

    This affects multicolumn NOT IN subplans, such as + WHERE (a, b) NOT IN (SELECT x, y FROM ...) + when for instance b and y are int4 + and int8 respectively. This mistake led to wrong answers + or crashes depending on the specific datatypes involved. +

  • Fix btree mark/restore functions to handle array keys (Tom Lane) +

    This oversight could result in wrong answers from merge joins whose + inner side is an index scan using an + indexed_column = + ANY(array) condition. +

  • Revert patch for taking fewer snapshots (Tom Lane) +

    The 9.2 change to reduce the number of snapshots taken during query + execution led to some anomalous behaviors not seen in previous + releases, because execution would proceed with a snapshot acquired + before locking the tables used by the query. Thus, for example, + a query would not be guaranteed to see updates committed by a + preceding transaction even if that transaction had exclusive lock. + We'll probably revisit this in future releases, but meanwhile put it + back the way it was before 9.2. +

  • Acquire buffer lock when re-fetching the old tuple for an + AFTER ROW UPDATE/DELETE trigger (Andres Freund) +

    In very unusual circumstances, this oversight could result in passing + incorrect data to a trigger WHEN condition, or to the + precheck logic for a foreign-key enforcement trigger. That could + result in a crash, or in an incorrect decision about whether to + fire the trigger. +

  • Fix ALTER COLUMN TYPE to handle inherited check + constraints properly (Pavan Deolasee) +

    This worked correctly in pre-8.4 releases, and now works correctly + in 8.4 and later. +

  • Fix ALTER EXTENSION SET SCHEMA's failure to move some + subsidiary objects into the new schema (Álvaro Herrera, Dimitri + Fontaine) +

  • Handle CREATE TABLE AS EXECUTE correctly in extended query + protocol (Tom Lane) +

  • Don't modify the input parse tree in DROP RULE IF NOT + EXISTS and DROP TRIGGER IF NOT EXISTS (Tom Lane) +

    This mistake would cause errors if a cached statement of one of these + types was re-executed. +

  • Fix REASSIGN OWNED to handle grants on tablespaces + (Álvaro Herrera) +

  • Ignore incorrect pg_attribute entries for system + columns for views (Tom Lane) +

    Views do not have any system columns. However, we forgot to + remove such entries when converting a table to a view. That's fixed + properly for 9.3 and later, but in previous branches we need to defend + against existing mis-converted views. +

  • Fix rule printing to dump INSERT INTO table + DEFAULT VALUES correctly (Tom Lane) +

  • Guard against stack overflow when there are too many + UNION/INTERSECT/EXCEPT clauses + in a query (Tom Lane) +

  • Prevent platform-dependent failures when dividing the minimum possible + integer value by -1 (Xi Wang, Tom Lane) +

  • Fix possible access past end of string in date parsing + (Hitoshi Harada) +

  • Fix failure to advance XID epoch if XID wraparound happens during a + checkpoint and wal_level is hot_standby + (Tom Lane, Andres Freund) +

    While this mistake had no particular impact on + PostgreSQL itself, it was bad for + applications that rely on txid_current() and related + functions: the TXID value would appear to go backwards. +

  • Fix pg_terminate_backend() and + pg_cancel_backend() to not throw error for a non-existent + target process (Josh Kupershmidt) +

    This case already worked as intended when called by a superuser, + but not so much when called by ordinary users. +

  • Fix display of + pg_stat_replication.sync_state at a + page boundary (Kyotaro Horiguchi) +

  • Produce an understandable error message if the length of the path name + for a Unix-domain socket exceeds the platform-specific limit + (Tom Lane, Andrew Dunstan) +

    Formerly, this would result in something quite unhelpful, such as + "Non-recoverable failure in name resolution". +

  • Fix memory leaks when sending composite column values to the client + (Tom Lane) +

  • Save some cycles by not searching for subtransaction locks at commit + (Simon Riggs) +

    In a transaction holding many exclusive locks, this useless activity + could be quite costly. +

  • Make pg_ctl more robust about reading the + postmaster.pid file (Heikki Linnakangas) +

    This fixes race conditions and possible file descriptor leakage. +

  • Fix possible crash in psql if incorrectly-encoded data + is presented and the client_encoding setting is a + client-only encoding, such as SJIS (Jiang Guiqing) +

  • Make pg_dump dump SEQUENCE SET items in + the data not pre-data section of the archive (Tom Lane) +

    This fixes an undesirable inconsistency between the meanings of + --data-only and --section=data, and also fixes + dumping of sequences that are marked as extension configuration tables. +

  • Fix pg_dump's handling of DROP DATABASE + commands in --clean mode (Guillaume Lelarge) +

    Beginning in 9.2.0, pg_dump --clean would issue a + DROP DATABASE command, which was either useless or + dangerous depending on the usage scenario. It no longer does that. + This change also fixes the combination of --clean and + --create to work sensibly, i.e., emit DROP + DATABASE then CREATE DATABASE before reconnecting to the + target database. +

  • Fix pg_dump for views with circular dependencies and + no relation options (Tom Lane) +

    The previous fix to dump relation options when a view is + involved in a circular dependency didn't work right for the case + that the view has no options; it emitted ALTER VIEW foo + SET () which is invalid syntax. +

  • Fix bugs in the restore.sql script emitted by + pg_dump in tar output format (Tom Lane) +

    The script would fail outright on tables whose names include + upper-case characters. Also, make the script capable of restoring + data in --inserts mode as well as the regular COPY mode. +

  • Fix pg_restore to accept POSIX-conformant + tar files (Brian Weaver, Tom Lane) +

    The original coding of pg_dump's tar + output mode produced files that are not fully conformant with the + POSIX standard. This has been corrected for version 9.3. This + patch updates previous branches so that they will accept both the + incorrect and the corrected formats, in hopes of avoiding + compatibility problems when 9.3 comes out. +

  • Fix tar files emitted by pg_basebackup to + be POSIX conformant (Brian Weaver, Tom Lane) +

  • Fix pg_resetxlog to locate postmaster.pid + correctly when given a relative path to the data directory (Tom Lane) +

    This mistake could lead to pg_resetxlog not noticing + that there is an active postmaster using the data directory. +

  • Fix libpq's lo_import() and + lo_export() functions to report file I/O errors properly + (Tom Lane) +

  • Fix ecpg's processing of nested structure pointer + variables (Muhammad Usama) +

  • Fix ecpg's ecpg_get_data function to + handle arrays properly (Michael Meskes) +

  • Prevent pg_upgrade from trying to process TOAST tables + for system catalogs (Bruce Momjian) +

    This fixes an error seen when the information_schema has + been dropped and recreated. Other failures were also possible. +

  • Improve pg_upgrade performance by setting + synchronous_commit to off in the new cluster + (Bruce Momjian) +

  • Make contrib/pageinspect's btree page inspection + functions take buffer locks while examining pages (Tom Lane) +

  • Work around unportable behavior of malloc(0) and + realloc(NULL, 0) (Tom Lane) +

    On platforms where these calls return NULL, some code + mistakenly thought that meant out-of-memory. + This is known to have broken pg_dump for databases + containing no user-defined aggregates. There might be other cases + as well. +

  • Ensure that make install for an extension creates the + extension installation directory (Cédric Villemain) +

    Previously, this step was missed if MODULEDIR was set in + the extension's Makefile. +

  • Fix pgxs support for building loadable modules on AIX + (Tom Lane) +

    Building modules outside the original source tree didn't work on AIX. +

  • Update time zone data files to tzdata release 2012j + for DST law changes in Cuba, Israel, Jordan, Libya, Palestine, Western + Samoa, and portions of Brazil. +


PrevHomeNext
Release NotesUpRelease 9.2.1
\ No newline at end of file diff --git a/doc/src/sgml/html/release-9-2.html b/doc/src/sgml/html/release-9-2.html new file mode 100644 index 000000000..f27dac412 --- /dev/null +++ b/doc/src/sgml/html/release-9-2.html @@ -0,0 +1,4527 @@ + +Release 9.2

E.3. Release 9.2

Release Date: 2012-09-10

E.3.1. Overview

This release has been largely focused on performance improvements, though + new SQL features are not lacking. Work also continues in the area of + replication support. Major enhancements include: +

  • Allow queries to retrieve data only from indexes, avoiding heap + access (index-only scans) +

  • Allow the planner to generate custom plans for specific parameter + values even when using prepared statements +

  • Improve the planner's ability to use nested loops with inner + index scans +

  • Allow streaming replication slaves to forward data to other slaves + (cascading + replication) +

  • Allow pg_basebackup + to make base backups from standby servers +

  • Add a pg_receivexlog + tool to archive WAL file changes as they are written +

  • Add the SP-GiST (Space-Partitioned + GiST) index access method +

  • Add support for range data types +

  • Add a JSON + data type +

  • Add a security_barrier + option for views +

  • Allow libpq connection strings to have the format of a + URI +

  • Add a single-row processing + mode to libpq for better handling of large + result sets +

The above items are explained in more detail in the sections below. +

E.3.2. Migration to Version 9.2

A dump/restore using pg_dump, or use of + pg_upgrade, is required for those wishing + to migrate data from any previous release. +

Version 9.2 contains a number of changes that may affect compatibility + with previous releases. Observe the following incompatibilities: +

E.3.2.1. System Catalogs

  • Remove the spclocation field from pg_tablespace + (Magnus Hagander) +

    This field was duplicative of the symbolic links that actually define + tablespace locations, and thus risked errors of omission when moving + a tablespace. This change allows tablespace directories to be moved + while the server is down, by manually adjusting the symbolic links. + To replace this field, we have added pg_tablespace_location() + to allow querying of the symbolic links. +

  • Move tsvector most-common-element statistics to new + pg_stats columns + (Alexander Korotkov) +

    Consult most_common_elems + and most_common_elem_freqs for the data formerly + available in most_common_vals + and most_common_freqs for a tsvector column. +

E.3.2.2. Functions

  • Remove hstore's => + operator (Robert Haas) +

    Users should now use hstore(text, text). Since + PostgreSQL 9.0, a warning message has been + emitted when an operator named => is created because + the SQL standard reserves that token for + another use. +

  • Ensure that xpath() + escapes special characters in string values (Florian Pflug) +

    Without this it is possible for the result not to be valid + XML. +

  • Make pg_relation_size() + and friends return NULL if the object does not exist (Phil Sorber) +

    This prevents queries that call these functions from returning + errors immediately after a concurrent DROP. +

  • Make EXTRACT(EPOCH FROM + timestamp without time zone) + measure the epoch from local midnight, not UTC + midnight (Tom Lane) +

    This change reverts an ill-considered change made in release 7.3. + Measuring from UTC midnight was inconsistent + because it made the result dependent on the timezone setting, which + computations for timestamp without time zone should not be. + The previous behavior remains available by casting the input value + to timestamp with time zone. +

  • Properly parse time strings with trailing yesterday, + today, and tomorrow (Dean Rasheed) +

    Previously, SELECT '04:00:00 yesterday'::timestamp + returned yesterday's date at midnight. +

  • Fix to_date() and + to_timestamp() to wrap incomplete dates toward 2020 + (Bruce Momjian) +

    Previously, supplied years and year masks of less than four digits + wrapped inconsistently. +

E.3.2.3. Object Modification

  • Prevent ALTER + DOMAIN from working on non-domain types (Peter + Eisentraut) +

    Owner and schema changes were previously possible on non-domain + types. +

  • No longer forcibly lowercase procedural language names in CREATE FUNCTION + (Robert Haas) +

    While unquoted language identifiers are still lowercased, strings + and quoted identifiers are no longer forcibly down-cased. + Thus for example CREATE FUNCTION ... LANGUAGE 'C' + will no longer work; it must be spelled 'c', or better + omit the quotes. +

  • Change system-generated names of foreign key enforcement triggers + (Tom Lane) +

    This change ensures that the triggers fire in the correct order in + some corner cases involving self-referential foreign key constraints. +

E.3.2.4. Command-Line Tools

  • Provide consistent backquote, variable + expansion, and quoted substring behavior in psql meta-command + arguments (Tom Lane) +

    Previously, such references were treated oddly when not separated by + whitespace from adjacent text. For example 'FOO'BAR was + output as FOO BAR (unexpected insertion of a space) and + FOO'BAR'BAZ was output unchanged (not removing the quotes + as most would expect). +

  • No longer treat clusterdb + table names as double-quoted; no longer treat reindexdb table + and index names as double-quoted (Bruce Momjian) +

    Users must now include double-quotes in the command arguments if + quoting is wanted. +

  • createuser + no longer prompts for option settings by default (Peter Eisentraut) +

    Use --interactive to obtain the old behavior. +

  • Disable prompting for the user name in dropuser unless + --interactive is specified (Peter Eisentraut) +

E.3.2.5. Server Settings

  • Add server parameters for specifying the locations of server-side + SSL files (Peter Eisentraut) +

    This allows changing the names and locations of the files that were + previously hard-coded as server.crt, + server.key, root.crt, and + root.crl in the data directory. + The server will no longer examine root.crt or + root.crl by default; to load these files, the + associated parameters must be set to non-default values. +

  • Remove the silent_mode parameter (Heikki Linnakangas) +

    Similar behavior can be obtained with pg_ctl start + -l postmaster.log. +

  • Remove the wal_sender_delay parameter, + as it is no longer needed (Tom Lane) +

  • Remove the custom_variable_classes parameter (Tom Lane) +

    The checking provided by this setting was dubious. Now any + setting can be prefixed by any class name. +

E.3.2.6. Monitoring

  • Rename pg_stat_activity.procpid + to pid, to match other system tables (Magnus Hagander) +

  • Create a separate pg_stat_activity column to + report process state (Scott Mead, Magnus Hagander) +

    The previous query and query_start + values now remain available for an idle session, allowing enhanced + analysis. +

  • Rename pg_stat_activity.current_query to + query because it is not cleared when the query + completes (Magnus Hagander) +

  • Change all SQL-level statistics timing values + to be float8 columns measured in milliseconds (Tom Lane) +

    This change eliminates the designed-in assumption that the values + are accurate to microseconds and no more (since the float8 + values can be fractional). + The columns affected are + pg_stat_user_functions.total_time, + pg_stat_user_functions.self_time, + pg_stat_xact_user_functions.total_time, + and + pg_stat_xact_user_functions.self_time. + The statistics functions underlying these columns now also return + float8 milliseconds, rather than bigint + microseconds. + contrib/pg_stat_statements' + total_time column is now also measured in + milliseconds. +

E.3.3. Changes

Below you will find a detailed account of the changes between + PostgreSQL 9.2 and the previous major + release. +

E.3.3.1. Server

E.3.3.1.1. Performance

  • Allow queries to retrieve data only from indexes, avoiding heap + access (Robert Haas, Ibrar Ahmed, Heikki Linnakangas, Tom Lane) +

    This feature is often called index-only scans. + Heap access can be skipped for heap pages containing only tuples that + are visible to all sessions, as reported by the visibility map; so + the benefit applies mainly to mostly-static data. The visibility map + was made crash-safe as a necessary part of implementing this feature. +

  • Add the SP-GiST (Space-Partitioned + GiST) index access method (Teodor Sigaev, Oleg Bartunov, Tom + Lane) +

    SP-GiST is comparable to GiST in flexibility, but supports + unbalanced partitioned search structures rather than balanced + trees. For suitable problems, SP-GiST can be faster than GiST in both + index build time and search time. +

  • Allow group commit to work effectively under heavy load (Peter + Geoghegan, Simon Riggs, Heikki Linnakangas) +

    Previously, batching of commits became ineffective as the write + workload increased, because of internal lock contention. +

  • Allow uncontended locks to be managed using a new + fast-path lock mechanism (Robert Haas) +

  • Reduce overhead of creating virtual transaction ID locks (Robert + Haas) +

  • Reduce the overhead of serializable isolation level locks (Dan + Ports) +

  • Improve PowerPC and Itanium spinlock performance (Manabu Ori, + Robert Haas, Tom Lane) +

  • Reduce overhead for shared invalidation cache messages (Robert + Haas) +

  • Move the frequently accessed members of the PGPROC + shared memory array to a separate array (Pavan + Deolasee, Heikki Linnakangas, Robert Haas) +

  • Improve COPY performance by adding tuples to + the heap in batches (Heikki Linnakangas) +

  • Improve GiST index performance for geometric data types by producing + better trees with less memory allocation overhead (Alexander Korotkov) +

  • Improve GiST index build times (Alexander Korotkov, Heikki + Linnakangas) +

  • Allow hint bits to be set sooner for temporary and unlogged tables + (Robert Haas) +

  • Allow sorting to be performed by inlined, + non-SQL-callable comparison functions (Peter + Geoghegan, Robert Haas, Tom Lane) +

  • Make the number of CLOG buffers scale based on shared_buffers + (Robert Haas, Simon Riggs, Tom Lane) +

  • Improve performance of buffer pool scans that occur when tables or + databases are dropped (Jeff Janes, Simon Riggs) +

  • Improve performance of checkpointer's fsync-request queue + when many tables are being dropped or truncated (Tom Lane) +

  • Pass the safe number of file descriptors to child processes on Windows + (Heikki Linnakangas) +

    This allows Windows sessions to use more open file descriptors than + before. +

E.3.3.1.2. Process Management

  • Create a dedicated background process to perform checkpoints (Simon + Riggs) +

    Formerly the background writer did both dirty-page writing and + checkpointing. Separating this into two processes allows each goal + to be accomplished more predictably. +

  • Improve asynchronous commit behavior by waking the walwriter sooner + (Simon Riggs) +

    Previously, only wal_writer_delay + triggered WAL flushing to disk; now filling a + WAL buffer also triggers WAL + writes. +

  • Allow the bgwriter, walwriter, checkpointer, statistics collector, + log collector, and archiver background processes to sleep more + efficiently during periods of inactivity (Peter Geoghegan, Tom Lane) +

    This series of changes reduces the frequency of process wake-ups when + there is nothing to do, dramatically reducing power consumption on + idle servers. +

E.3.3.1.3. Optimizer

  • Allow the planner to generate custom plans for specific parameter + values even when using prepared statements + (Tom Lane) +

    In the past, a prepared statement always had a single + "generic" plan that was used for all parameter values, which + was frequently much inferior to the plans used for non-prepared + statements containing explicit constant values. Now, the planner + attempts to generate custom plans for specific parameter values. + A generic plan will only be used after custom plans have repeatedly + proven to provide no benefit. This change should eliminate the + performance penalties formerly seen from use of prepared statements + (including non-dynamic statements in PL/pgSQL). +

  • Improve the planner's ability to use nested loops with inner + index scans (Tom Lane) +

    The new "parameterized path" mechanism allows inner + index scans to use values from relations that are more than one join + level up from the scan. This can greatly improve performance in + situations where semantic restrictions (such as outer joins) limit + the allowed join orderings. +

  • Improve the planning API for foreign data wrappers + (Etsuro Fujita, Shigeru Hanada, Tom Lane) +

    Wrappers can now provide multiple access "paths" for their + tables, allowing more flexibility in join planning. +

  • Recognize self-contradictory restriction clauses for non-table + relations (Tom Lane) +

    This check is only performed when constraint_exclusion + is on. +

  • Allow indexed_col op ANY(ARRAY[...]) conditions to be + used in plain index scans and index-only scans (Tom Lane) +

    Formerly such conditions could only be used in bitmap index scans. +

  • Support MIN/MAX index optimizations on + boolean columns (Marti Raudsepp) +

  • Account for set-returning functions in SELECT target + lists when setting row count estimates (Tom Lane) +

  • Fix planner to handle indexes with duplicated columns more reliably + (Tom Lane) +

  • Collect and use element-frequency statistics for arrays (Alexander + Korotkov, Tom Lane) +

    This change improves selectivity estimation for the array + <@, &&, and + @> operators (array containment and overlaps). +

  • Allow statistics to be collected for foreign tables + (Etsuro Fujita) +

  • Improve cost estimates for use of partial indexes (Tom Lane) +

  • Improve the planner's ability to use statistics for columns + referenced in subqueries (Tom Lane) +

  • Improve statistical estimates for subqueries using + DISTINCT (Tom Lane) +

E.3.3.1.4. Authentication

  • Do not treat role names and samerole specified in pg_hba.conf + as automatically including superusers (Andrew Dunstan) +

    This makes it easier to use reject lines with group roles. +

  • Adjust pg_hba.conf processing to handle token + parsing more consistently (Brendan Jurd, Álvaro Herrera) +

  • Disallow empty pg_hba.conf files (Tom Lane) +

    This was done to more quickly detect misconfiguration. +

  • Make superuser privilege imply replication privilege (Noah Misch) +

    This avoids the need to explicitly assign such privileges. +

E.3.3.1.5. Monitoring

  • Attempt to log the current query string during a backend crash + (Marti Raudsepp) +

  • Make logging of autovacuum I/O activity more verbose (Greg + Smith, Noah Misch) +

    This logging is triggered by log_autovacuum_min_duration. +

  • Make WAL replay report failures sooner + (Fujii Masao) +

    There were some cases where failures were only reported once the + server went into master mode. +

  • Add pg_xlog_location_diff() + to simplify WAL location comparisons (Euler Taveira de Oliveira) +

    This is useful for computing replication lag. +

  • Support configurable event log application names on Windows + (MauMau, Magnus Hagander) +

    This allows different instances to use the event log + with different identifiers, by setting the event_source + server parameter, which is similar to how syslog_ident works. +

  • Change "unexpected EOF" messages to DEBUG1 level, + except when there is an open transaction (Magnus Hagander) +

    This change reduces log chatter caused by applications that close + database connections ungracefully. +

E.3.3.1.6. Statistical Views

  • Track temporary file sizes and file counts in the pg_stat_database + system view (Tomas Vondra) +

  • Add a deadlock counter to the pg_stat_database + system view (Magnus Hagander) +

  • Add a server parameter track_io_timing + to track I/O timings (Ants Aasma, Robert Haas) +

  • Report checkpoint timing information in pg_stat_bgwriter + (Greg Smith, Peter Geoghegan) +

E.3.3.1.7. Server Settings

  • Silently ignore nonexistent schemas specified in search_path (Tom Lane) +

    This makes it more convenient to use generic path settings, which + might include some schemas that don't exist in all databases. +

  • Allow superusers to set deadlock_timeout + per-session, not just per-cluster (Noah Misch) +

    This allows deadlock_timeout to be reduced for + transactions that are likely to be involved in a deadlock, thus + detecting the failure more quickly. Alternatively, increasing the + value can be used to reduce the chances of a session being chosen for + cancellation due to a deadlock. +

  • Add a server parameter temp_file_limit + to constrain temporary file space usage per session (Mark Kirkwood) +

  • Allow a superuser to SET an extension's + superuser-only custom variable before loading the associated + extension (Tom Lane) +

    The system now remembers whether a SET was + performed by a superuser, so that proper privilege checking can be + done when the extension is loaded. +

  • Add postmaster -C + option to query configuration parameters (Bruce Momjian) +

    This allows pg_ctl to better handle cases where + PGDATA or -D points to a configuration-only + directory. +

  • Replace an empty locale name with the implied value in + CREATE DATABASE + (Tom Lane) +

    This prevents cases where + pg_database.datcollate or + datctype could be interpreted differently after a + server restart. +

E.3.3.1.7.1. postgresql.conf

  • Allow multiple errors in postgresql.conf + to be reported, rather than just the first one (Alexey Klyukin, + Tom Lane) +

  • Allow a reload of postgresql.conf to be + processed by all sessions, even if there are some settings that + are invalid for particular sessions (Alexey Klyukin) +

    Previously, such not-valid-within-session values would cause all + setting changes to be ignored by that session. +

  • Add an include_if_exists facility for configuration + files (Greg Smith) +

    This works the same as include, except that an error + is not thrown if the file is missing. +

  • Identify the server time zone during initdb, and set + postgresql.conf entries + timezone and + log_timezone + accordingly (Tom Lane) +

    This avoids expensive time zone probes during server start. +

  • Fix pg_settings to + report postgresql.conf line numbers on Windows + (Tom Lane) +

E.3.3.2. Replication and Recovery

  • Allow streaming replication slaves to forward data to other slaves + (cascading + replication) (Fujii Masao) +

    Previously, only the master server could supply streaming + replication log files to standby servers. +

  • Add new synchronous_commit + mode remote_write (Fujii Masao, Simon Riggs) +

    This mode waits for the standby server to write transaction data to + its own operating system, but does not wait for the data to be + flushed to the standby's disk. +

  • Add a pg_receivexlog + tool to archive WAL file changes as they are written, rather + than waiting for completed WAL files (Magnus Hagander) +

  • Allow pg_basebackup + to make base backups from standby servers (Jun Ishizuka, Fujii Masao) +

    This feature lets the work of making new base backups be off-loaded + from the primary server. +

  • Allow streaming of WAL files while pg_basebackup + is performing a backup (Magnus Hagander) +

    This allows passing of WAL files to the standby before they are + discarded on the primary. +

E.3.3.3. Queries

  • Cancel the running query if the client gets disconnected + (Florian Pflug) +

    If the backend detects loss of client connection during a query, it + will now cancel the query rather than attempting to finish it. +

  • Retain column names at run time for row expressions + (Andrew Dunstan, Tom Lane) +

    This change allows better results when a row value is converted to + hstore or json type: the fields of the resulting + value will now have the expected names. +

  • Improve column labels used for sub-SELECT results + (Marti Raudsepp) +

    Previously, the generic label ?column? was used. +

  • Improve heuristics for determining the types of unknown values + (Tom Lane) +

    The longstanding rule that an unknown constant might have the + same type as the value on the other side of the operator using it + is now applied when considering polymorphic operators, not only + for simple operator matches. +

  • Warn about creating casts to or from domain types (Robert Haas) +

    Such casts have no effect. +

  • When a row fails a CHECK or NOT NULL + constraint, show the row's contents as error detail (Jan + Kundrát) +

    This should make it easier to identify which row is problematic + when an insert or update is processing many rows. +

E.3.3.4. Object Manipulation

  • Provide more reliable operation during concurrent + DDL (Robert Haas, Noah Misch) +

    This change adds locking that should eliminate "cache lookup + failed" errors in many scenarios. Also, it is no longer possible + to add relations to a schema that is being concurrently dropped, a + scenario that formerly led to inconsistent system catalog contents. +

  • Add CONCURRENTLY option to DROP INDEX + (Simon Riggs) +

    This allows index removal without blocking other sessions. +

  • Allow foreign data wrappers to have per-column options (Shigeru Hanada) +

  • Improve pretty-printing of view definitions (Andrew Dunstan) +

E.3.3.4.1. Constraints

  • Allow CHECK + constraints to be declared NOT VALID (Álvaro + Herrera) +

    Adding a NOT VALID constraint does not cause the table to + be scanned to verify that existing rows meet the constraint. + Subsequently, newly added or updated rows are checked. + Such constraints are ignored by the planner when considering + constraint_exclusion, since it is not certain that all + rows meet the constraint. +

    The new ALTER TABLE VALIDATE command allows NOT + VALID constraints to be checked for existing rows, after which + they are converted into ordinary constraints. +

  • Allow CHECK constraints to be declared NO + INHERIT (Nikhil Sontakke, Alex Hunsaker, Álvaro Herrera) +

    This makes them enforceable only on the parent table, not on + child tables. +

  • Add the ability to rename + constraints (Peter Eisentraut) +

E.3.3.4.2. ALTER

  • Reduce need to rebuild tables and indexes for certain ALTER TABLE + ... ALTER COLUMN TYPE operations (Noah Misch) +

    Increasing the length limit for a varchar or varbit + column, or removing the limit altogether, no longer requires a table + rewrite. Similarly, increasing the allowable precision of a + numeric column, or changing a column from constrained + numeric to unconstrained numeric, no longer + requires a table rewrite. Table rewrites are also avoided in similar + cases involving the interval, timestamp, and + timestamptz types. +

  • Avoid having ALTER + TABLE revalidate foreign key constraints in some + cases where it is not necessary (Noah Misch) +

  • Add IF EXISTS options to some ALTER + commands (Pavel Stehule) +

    For example, ALTER FOREIGN TABLE IF EXISTS foo RENAME + TO bar. +

  • Add ALTER + FOREIGN DATA WRAPPER ... RENAME + and ALTER + SERVER ... RENAME (Peter Eisentraut) +

  • Add ALTER + DOMAIN ... RENAME (Peter Eisentraut) +

    You could already rename domains using ALTER + TYPE. +

  • Throw an error for ALTER DOMAIN ... DROP + CONSTRAINT on a nonexistent constraint (Peter Eisentraut) +

    An IF EXISTS option has been added to provide the + previous behavior. +

E.3.3.4.3. CREATE TABLE

  • Allow CREATE TABLE (LIKE ...) from foreign + tables, views, and composite types (Peter Eisentraut) +

    For example, this allows a table to be created whose schema matches a + view. +

  • Fix CREATE TABLE (LIKE ...) to avoid index name + conflicts when copying index comments (Tom Lane) +

  • Fix CREATE TABLE ... AS EXECUTE + to handle WITH NO DATA and column name specifications + (Tom Lane) +

E.3.3.4.4. Object Permissions

  • Add a security_barrier + option for views (KaiGai Kohei, Robert Haas) +

    This option prevents optimizations that might allow view-protected + data to be exposed to users, for example pushing a clause involving + an insecure function into the WHERE clause of the view. + Such views can be expected to perform more poorly than ordinary + views. +

  • Add a new LEAKPROOF function + attribute to mark functions that can safely be pushed down + into security_barrier views (KaiGai Kohei) +

  • Add support for privileges on data types (Peter Eisentraut) +

    This adds support for the SQL-conforming + USAGE privilege on types and domains. The intent is + to be able to restrict which users can create dependencies on types, + since such dependencies limit the owner's ability to alter the type. +

  • Check for INSERT privileges in SELECT + INTO / CREATE TABLE AS (KaiGai Kohei) +

    Because the object is being created by SELECT INTO + or CREATE TABLE AS, the creator would ordinarily + have insert permissions; but there are corner cases where this is not + true, such as when ALTER DEFAULT PRIVILEGES has removed + such permissions. +

E.3.3.5. Utility Operations

  • Allow VACUUM to more + easily skip pages that cannot be locked (Simon Riggs, Robert Haas) +

    This change should greatly reduce the incidence of VACUUM + getting "stuck" waiting for other sessions. +

  • Make EXPLAIN + (BUFFERS) count blocks dirtied and written (Robert Haas) +

  • Make EXPLAIN ANALYZE report the number of rows + rejected by filter steps (Marko Tiikkaja) +

  • Allow EXPLAIN ANALYZE to avoid timing overhead when + time values are not wanted (Tomas Vondra) +

    This is accomplished by setting the new TIMING option to + FALSE. +

E.3.3.6. Data Types

  • Add support for range data types + (Jeff Davis, Tom Lane, Alexander Korotkov) +

    A range data type stores a lower and upper bound belonging to its + base data type. It supports operations like contains, overlaps, and + intersection. +

  • Add a JSON + data type (Robert Haas) +

    This type stores JSON (JavaScript Object Notation) + data with proper validation. +

  • Add array_to_json() + and row_to_json() (Andrew Dunstan) +

  • Add a SMALLSERIAL + data type (Mike Pultz) +

    This is like SERIAL, except it stores the sequence in + a two-byte integer column (int2). +

  • Allow domains to be + declared NOT VALID (Álvaro Herrera) +

    This option can be set at domain creation time, or via ALTER + DOMAIN ... ADD CONSTRAINT ... NOT + VALID. ALTER DOMAIN ... VALIDATE + CONSTRAINT fully validates the constraint. +

  • Support more locale-specific formatting options for the money data type (Tom Lane) +

    Specifically, honor all the POSIX options for ordering of the value, + sign, and currency symbol in monetary output. Also, make sure that + the thousands separator is only inserted to the left of the decimal + point, as required by POSIX. +

  • Add bitwise "and", "or", and "not" + operators for the macaddr data type (Brendan Jurd) +

  • Allow xpath() to + return a single-element XML array when supplied a + scalar value (Florian Pflug) +

    Previously, it returned an empty array. This change will also + cause xpath_exists() to return true, not false, + for such expressions. +

  • Improve XML error handling to be more robust + (Florian Pflug) +

E.3.3.7. Functions

  • Allow non-superusers to use pg_cancel_backend() + and pg_terminate_backend() + on other sessions belonging to the same user + (Magnus Hagander, Josh Kupershmidt, Dan Farina) +

    Previously only superusers were allowed to use these functions. +

  • Allow importing and exporting of transaction snapshots (Joachim + Wieland, Tom Lane) +

    This allows multiple transactions to share identical views of the + database state. + Snapshots are exported via pg_export_snapshot() + and imported via SET + TRANSACTION SNAPSHOT. Only snapshots from + currently-running transactions can be imported. +

  • Support COLLATION + FOR on expressions (Peter Eisentraut) +

    This returns a string representing the collation of the expression. +

  • Add pg_opfamily_is_visible() + (Josh Kupershmidt) +

  • Add a numeric variant of pg_size_pretty() + for use with pg_xlog_location_diff() (Fujii Masao) +

  • Add a pg_trigger_depth() + function (Kevin Grittner) +

    This reports the current trigger call depth. +

  • Allow string_agg() + to process bytea values (Pavel Stehule) +

  • Fix regular expressions in which a back-reference occurs within + a larger quantified subexpression (Tom Lane) +

    For example, ^(\w+)( \1)+$. Previous releases did not + check that the back-reference actually matched the first occurrence. +

E.3.3.8. Information Schema

  • Add information schema views + role_udt_grants, udt_privileges, + and user_defined_types (Peter Eisentraut) +

  • Add composite-type attributes to the + information schema element_types view + (Peter Eisentraut) +

  • Implement interval_type columns in the information + schema (Peter Eisentraut) +

    Formerly these columns read as nulls. +

  • Implement collation-related columns in the information schema + attributes, columns, + domains, and element_types + views (Peter Eisentraut) +

  • Implement the with_hierarchy column in the + information schema table_privileges view (Peter + Eisentraut) +

  • Add display of sequence USAGE privileges to information + schema (Peter Eisentraut) +

  • Make the information schema show default privileges (Peter + Eisentraut) +

    Previously, non-empty default permissions were not represented in the + views. +

E.3.3.9. Server-Side Languages

E.3.3.9.1. PL/pgSQL Server-Side Language

  • Allow the PL/pgSQL OPEN cursor command to supply + parameters by name (Yeb Havinga) +

  • Add a GET STACKED DIAGNOSTICS PL/pgSQL command + to retrieve exception info (Pavel Stehule) +

  • Speed up PL/pgSQL array assignment by caching type information + (Pavel Stehule) +

  • Improve performance and memory consumption for long chains of + ELSIF clauses (Tom Lane) +

  • Output the function signature, not just the name, in PL/pgSQL + error messages (Pavel Stehule) +

E.3.3.9.2. PL/Python Server-Side Language

  • Add PL/Python SPI cursor support (Jan + Urbanski) +

    This allows PL/Python to read partial result sets. +

  • Add result metadata functions to PL/Python (Peter Eisentraut) +

    Specifically, this adds result object functions + .colnames, .coltypes, and + .coltypmods. +

  • Remove support for Python 2.2 (Peter Eisentraut) +

E.3.3.9.3. SQL Server-Side Language

  • Allow SQL-language functions to reference + parameters by name (Matthew Draper) +

    To use this, simply name the function arguments and then reference + the argument names in the SQL function body. +

E.3.3.10. Client Applications

  • Add initdb + options --auth-local and --auth-host + (Peter Eisentraut) +

    This allows separate control of local and + host pg_hba.conf authentication + settings. --auth still controls both. +

  • Add --replication/--no-replication flags to + createuser + to control replication permission (Fujii Masao) +

  • Add the --if-exists option to dropdb and dropuser (Josh + Kupershmidt) +

  • Give command-line tools the ability to specify the name of the + database to connect to, and fall back to template1 + if a postgres database connection fails (Robert Haas) +

E.3.3.10.1. psql

  • Add a display mode to auto-expand output based on the + display width (Peter Eisentraut) +

    This adds the auto option to the \x + command, which switches to the expanded mode when the normal + output would be wider than the screen. +

  • Allow inclusion of a script file that is named relative to the + directory of the file from which it was invoked (Gurjeet Singh) +

    This is done with a new command \ir. +

  • Add support for non-ASCII characters in + psql variable names (Tom Lane) +

  • Add support for major-version-specific .psqlrc files + (Bruce Momjian) +

    psql already supported minor-version-specific + .psqlrc files. +

  • Provide environment variable overrides for psql + history and startup file locations (Andrew Dunstan) +

    PSQL_HISTORY and PSQLRC now + determine these file names if set. +

  • Add a \setenv command to modify + the environment variables passed to child processes (Andrew Dunstan) +

  • Name psql's temporary editor files with a + .sql extension (Peter Eisentraut) +

    This allows extension-sensitive editors to select the right mode. +

  • Allow psql to use zero-byte field and record + separators (Peter Eisentraut) +

    Various shell tools use zero-byte (NUL) separators, + e.g. find. +

  • Make the \timing option report times for + failed queries (Magnus Hagander) +

    Previously times were reported only for successful queries. +

  • Unify and tighten psql's treatment of \copy + and SQL COPY (Noah Misch) +

    This fix makes failure behavior more predictable and honors + \set ON_ERROR_ROLLBACK. +

E.3.3.10.2. Informational Commands

  • Make \d on a sequence show the + table/column name owning it (Magnus Hagander) +

  • Show statistics target for columns in \d+ (Magnus + Hagander) +

  • Show role password expiration dates in \du + (Fabrízio de Royes Mello) +

  • Display comments for casts, conversions, domains, and languages + (Josh Kupershmidt) +

    These are included in the output of \dC+, + \dc+, \dD+, and \dL respectively. +

  • Display comments for SQL/MED + objects (Josh Kupershmidt) +

    These are included in the output of \des+, + \det+, and \dew+ for foreign servers, foreign + tables, and foreign data wrappers respectively. +

  • Change \dd to display comments only for object types + without their own backslash command (Josh Kupershmidt) +

E.3.3.10.3. Tab Completion

  • In psql tab completion, complete SQL + keywords in either upper or lower case according to the new COMP_KEYWORD_CASE + setting (Peter Eisentraut) +

  • Add tab completion support for + EXECUTE (Andreas Karlsson) +

  • Allow tab completion of role references in + GRANT/REVOKE (Peter + Eisentraut) +

  • Allow tab completion of file names to supply quotes, when necessary + (Noah Misch) +

  • Change tab completion support for + TABLE to also include views (Magnus Hagander) +

E.3.3.10.4. pg_dump

  • Add an --exclude-table-data option to + pg_dump (Andrew Dunstan) +

    This allows dumping of a table's definition but not its data, + on a per-table basis. +

  • Add a --section option to pg_dump + and pg_restore (Andrew Dunstan) +

    Valid values are pre-data, data, + and post-data. The option can be + given more than once to select two or more sections. +

  • Make pg_dumpall dump all + roles first, then all configuration settings on roles (Phil Sorber) +

    This allows a role's configuration settings to mention other + roles without generating an error. +

  • Allow pg_dumpall to avoid errors if the + postgres database is missing in the new cluster + (Robert Haas) +

  • Dump foreign server user mappings in user name order (Peter + Eisentraut) +

    This helps produce deterministic dump files. +

  • Dump operators in a predictable order (Peter Eisentraut) +

  • Tighten rules for when extension configuration tables are dumped + by pg_dump (Tom Lane) +

  • Make pg_dump emit more useful dependency + information (Tom Lane) +

    The dependency links included in archive-format dumps were formerly + of very limited use, because they frequently referenced objects that + appeared nowhere in the dump. Now they represent actual dependencies + (possibly indirect) among the dumped objects. +

  • Improve pg_dump's performance when dumping many + database objects (Tom Lane) +

E.3.3.11. libpq

  • Allow libpq connection strings to have the format of a + URI + (Alexander Shulgin) +

    The syntax begins with postgres://. This can allow + applications to avoid implementing their own parser for URIs + representing database connections. +

  • Add a connection + option to disable SSL compression + (Laurenz Albe) +

    This can be used to remove the overhead of SSL + compression on fast networks. +

  • Add a single-row processing + mode for better handling of large result sets + (Kyotaro Horiguchi, Marko Kreen) +

    Previously, libpq always collected the entire query + result in memory before passing it back to the application. +

  • Add const qualifiers to the declarations of the functions + PQconnectdbParams, PQconnectStartParams, + and PQpingParams (Lionel Elie Mamane) +

  • Allow the .pgpass file to include escaped characters + in the password field (Robert Haas) +

  • Make library functions use abort() instead of + exit() when it is necessary to terminate the process + (Peter Eisentraut) +

    This choice does not interfere with the normal exit codes used by the + program, and generates a signal that can be caught by the caller. +

E.3.3.12. Source Code

  • Remove dead ports (Peter Eisentraut) +

    The following platforms are no longer supported: dgux, + nextstep, sunos4, svr4, ultrix4, univel, bsdi. +

  • Add support for building with MS + Visual Studio 2010 (Brar Piening) +

  • Enable compiling with the MinGW-w64 32-bit compiler (Lars Kanis) +

  • Install plpgsql.h into include/server during installation + (Heikki Linnakangas) +

  • Improve the latch facility to include detection of postmaster death + (Peter Geoghegan, Heikki Linnakangas, Tom Lane) +

    This eliminates one of the main reasons that background processes + formerly had to wake up to poll for events. +

  • Use C flexible array members, where supported (Peter Eisentraut) +

  • Improve the concurrent transaction regression tests + (isolationtester) (Noah Misch) +

  • Modify thread_test to create its test files in + the current directory, rather than /tmp (Bruce Momjian) +

  • Improve flex and bison warning and error reporting (Tom Lane) +

  • Add memory barrier support (Robert Haas) +

    This is currently unused. +

  • Modify pgindent to use a typedef file (Bruce Momjian) +

  • Add a hook for processing messages due to be sent to the server + log (Martin Pihlak) +

  • Add object access hooks for DROP commands + (KaiGai Kohei) +

  • Centralize DROP handling for some object types + (KaiGai Kohei) +

  • Add a pg_upgrade test suite (Peter Eisentraut) +

  • Sync regular expression code with TCL 8.5.11 + and improve internal processing (Tom Lane) +

  • Move CRC tables to libpgport, and provide them + in a separate include file (Daniel Farina) +

  • Add options to git_changelog for use in major + release note creation (Bruce Momjian) +

  • Support Linux's /proc/self/oom_score_adj API (Tom Lane) +

E.3.3.13. Additional Modules

  • Improve efficiency of dblink by using + libpq's new single-row processing mode (Kyotaro Horiguchi, Marko + Kreen) +

    This improvement does not apply to + dblink_send_query()/dblink_get_result(). +

  • Support force_not_null option in file_fdw (Shigeru Hanada) +

  • Implement dry-run mode for pg_archivecleanup + (Gabriele Bartolini) +

    This only outputs the names of files to be deleted. +

  • Add new pgbench switches + --unlogged-tables, --tablespace, and + --index-tablespace (Robert Haas) +

  • Change pg_test_fsync to test + for a fixed amount of time, rather than a fixed number of cycles + (Bruce Momjian) +

    The -o/cycles option was removed, and + -s/seconds added. +

  • Add a pg_test_timing + utility to measure clock monotonicity and timing overhead (Ants + Aasma, Greg Smith) +

  • Add a tcn (triggered change notification) + module to generate NOTIFY events on table changes + (Kevin Grittner) +

E.3.3.13.1. pg_upgrade

  • Adjust pg_upgrade environment variables (Bruce + Momjian) +

    Rename data, bin, and port environment + variables to begin with PG, and support + PGPORTOLD/PGPORTNEW, to replace + PGPORT. +

  • Overhaul pg_upgrade logging and failure reporting + (Bruce Momjian) +

    Create four append-only log files, and delete them on success. + Add -r/--retain option to unconditionally + retain these files. Also remove pg_upgrade options + -g/-G/-l options as unnecessary, + and tighten log file permissions. +

  • Make pg_upgrade create a script to incrementally + generate more accurate optimizer statistics (Bruce Momjian) +

    This reduces the time needed to generate minimal cluster statistics + after an upgrade. +

  • Allow pg_upgrade to upgrade an old cluster that + does not have a postgres database (Bruce Momjian) +

  • Allow pg_upgrade to handle cases where some + old or new databases are missing, as long as they are empty + (Bruce Momjian) +

  • Allow pg_upgrade to handle configuration-only + directory installations (Bruce Momjian) +

  • In pg_upgrade, add -o/-O + options to pass parameters to the servers (Bruce Momjian) +

    This is useful for configuration-only directory installs. +

  • Change pg_upgrade to use port 50432 by default + (Bruce Momjian) +

    This helps avoid unintended client connections during the upgrade. +

  • Reduce cluster locking in pg_upgrade (Bruce + Momjian) +

    Specifically, only lock the old cluster if link mode is used, + and do it right after the schema is restored. +

E.3.3.13.2. pg_stat_statements

  • Allow pg_stat_statements to aggregate similar + queries via SQL text normalization (Peter Geoghegan, Tom Lane) +

    Users with applications that use non-parameterized SQL will now + be able to monitor query performance without detailed log analysis. +

  • Add dirtied and written block counts and read/write times to + pg_stat_statements (Robert Haas, Ants Aasma) +

  • Prevent pg_stat_statements from double-counting + PREPARE and EXECUTE commands + (Tom Lane) +

E.3.3.13.3. sepgsql

  • Support SECURITY LABEL on global objects (KaiGai + Kohei, Robert Haas) +

    Specifically, add security labels to databases, + tablespaces, and roles. +

  • Allow sepgsql to honor database labels (KaiGai Kohei) +

  • Perform sepgsql permission checks during the creation of various + objects (KaiGai Kohei) +

  • Add sepgsql_setcon() and related functions to control + the sepgsql security domain (KaiGai Kohei) +

  • Add a user space access cache to sepgsql to improve performance + (KaiGai Kohei) +

E.3.3.14. Documentation

  • Add a rule to optionally build HTML documentation using the + stylesheet from the website (Magnus Hagander) +

    Use gmake STYLE=website draft. +

  • Improve EXPLAIN documentation (Tom Lane) +

  • Document that user/database names are preserved with double-quoting + by command-line tools like vacuumdb (Bruce + Momjian) +

  • Document the actual string returned by the client for MD5 + authentication (Cyan Ogilvie) +

  • Deprecate use of GLOBAL and LOCAL in + CREATE TEMP TABLE (Noah Misch) +

    PostgreSQL has long treated these keyword as no-ops, + and continues to do so; but in future they might mean what the SQL + standard says they mean, so applications should avoid using them. +


PrevHomeNext
Release 9.2.1UpRelease 9.1.7
\ No newline at end of file diff --git a/doc/src/sgml/html/release.html b/doc/src/sgml/html/release.html new file mode 100644 index 000000000..9df9b9485 --- /dev/null +++ b/doc/src/sgml/html/release.html @@ -0,0 +1,1364 @@ + +Release Notes

Appendix E. Release Notes

Table of Contents
E.1. Release 9.2.2
E.2. Release 9.2.1
E.3. Release 9.2
E.4. Release 9.1.7
E.5. Release 9.1.6
E.6. Release 9.1.5
E.7. Release 9.1.4
E.8. Release 9.1.3
E.9. Release 9.1.2
E.10. Release 9.1.1
E.11. Release 9.1
E.12. Release 9.0.11
E.13. Release 9.0.10
E.14. Release 9.0.9
E.15. Release 9.0.8
E.16. Release 9.0.7
E.17. Release 9.0.6
E.18. Release 9.0.5
E.19. Release 9.0.4
E.20. Release 9.0.3
E.21. Release 9.0.2
E.22. Release 9.0.1
E.23. Release 9.0
E.24. Release 8.4.15
E.25. Release 8.4.14
E.26. Release 8.4.13
E.27. Release 8.4.12
E.28. Release 8.4.11
E.29. Release 8.4.10
E.30. Release 8.4.9
E.31. Release 8.4.8
E.32. Release 8.4.7
E.33. Release 8.4.6
E.34. Release 8.4.5
E.35. Release 8.4.4
E.36. Release 8.4.3
E.37. Release 8.4.2
E.38. Release 8.4.1
E.39. Release 8.4
E.40. Release 8.3.22
E.41. Release 8.3.21
E.42. Release 8.3.20
E.43. Release 8.3.19
E.44. Release 8.3.18
E.45. Release 8.3.17
E.46. Release 8.3.16
E.47. Release 8.3.15
E.48. Release 8.3.14
E.49. Release 8.3.13
E.50. Release 8.3.12
E.51. Release 8.3.11
E.52. Release 8.3.10
E.53. Release 8.3.9
E.54. Release 8.3.8
E.55. Release 8.3.7
E.56. Release 8.3.6
E.57. Release 8.3.5
E.58. Release 8.3.4
E.59. Release 8.3.3
E.60. Release 8.3.2
E.61. Release 8.3.1
E.62. Release 8.3
E.63. Release 8.2.23
E.64. Release 8.2.22
E.65. Release 8.2.21
E.66. Release 8.2.20
E.67. Release 8.2.19
E.68. Release 8.2.18
E.69. Release 8.2.17
E.70. Release 8.2.16
E.71. Release 8.2.15
E.72. Release 8.2.14
E.73. Release 8.2.13
E.74. Release 8.2.12
E.75. Release 8.2.11
E.76. Release 8.2.10
E.77. Release 8.2.9
E.78. Release 8.2.8
E.79. Release 8.2.7
E.80. Release 8.2.6
E.81. Release 8.2.5
E.82. Release 8.2.4
E.83. Release 8.2.3
E.84. Release 8.2.2
E.85. Release 8.2.1
E.86. Release 8.2
E.87. Release 8.1.23
E.88. Release 8.1.22
E.89. Release 8.1.21
E.90. Release 8.1.20
E.91. Release 8.1.19
E.92. Release 8.1.18
E.93. Release 8.1.17
E.94. Release 8.1.16
E.95. Release 8.1.15
E.96. Release 8.1.14
E.97. Release 8.1.13
E.98. Release 8.1.12
E.99. Release 8.1.11
E.100. Release 8.1.10
E.101. Release 8.1.9
E.102. Release 8.1.8
E.103. Release 8.1.7
E.104. Release 8.1.6
E.105. Release 8.1.5
E.106. Release 8.1.4
E.107. Release 8.1.3
E.108. Release 8.1.2
E.109. Release 8.1.1
E.110. Release 8.1
E.111. Release 8.0.26
E.112. Release 8.0.25
E.113. Release 8.0.24
E.114. Release 8.0.23
E.115. Release 8.0.22
E.116. Release 8.0.21
E.117. Release 8.0.20
E.118. Release 8.0.19
E.119. Release 8.0.18
E.120. Release 8.0.17
E.121. Release 8.0.16
E.122. Release 8.0.15
E.123. Release 8.0.14
E.124. Release 8.0.13
E.125. Release 8.0.12
E.126. Release 8.0.11
E.127. Release 8.0.10
E.128. Release 8.0.9
E.129. Release 8.0.8
E.130. Release 8.0.7
E.131. Release 8.0.6
E.132. Release 8.0.5
E.133. Release 8.0.4
E.134. Release 8.0.3
E.135. Release 8.0.2
E.136. Release 8.0.1
E.137. Release 8.0
E.138. Release 7.4.30
E.139. Release 7.4.29
E.140. Release 7.4.28
E.141. Release 7.4.27
E.142. Release 7.4.26
E.143. Release 7.4.25
E.144. Release 7.4.24
E.145. Release 7.4.23
E.146. Release 7.4.22
E.147. Release 7.4.21
E.148. Release 7.4.20
E.149. Release 7.4.19
E.150. Release 7.4.18
E.151. Release 7.4.17
E.152. Release 7.4.16
E.153. Release 7.4.15
E.154. Release 7.4.14
E.155. Release 7.4.13
E.156. Release 7.4.12
E.157. Release 7.4.11
E.158. Release 7.4.10
E.159. Release 7.4.9
E.160. Release 7.4.8
E.161. Release 7.4.7
E.162. Release 7.4.6
E.163. Release 7.4.5
E.164. Release 7.4.4
E.165. Release 7.4.3
E.166. Release 7.4.2
E.167. Release 7.4.1
E.168. Release 7.4
E.169. Release 7.3.21
E.170. Release 7.3.20
E.171. Release 7.3.19
E.172. Release 7.3.18
E.173. Release 7.3.17
E.174. Release 7.3.16
E.175. Release 7.3.15
E.176. Release 7.3.14
E.177. Release 7.3.13
E.178. Release 7.3.12
E.179. Release 7.3.11
E.180. Release 7.3.10
E.181. Release 7.3.9
E.182. Release 7.3.8
E.183. Release 7.3.7
E.184. Release 7.3.6
E.185. Release 7.3.5
E.186. Release 7.3.4
E.187. Release 7.3.3
E.188. Release 7.3.2
E.189. Release 7.3.1
E.190. Release 7.3
E.191. Release 7.2.8
E.192. Release 7.2.7
E.193. Release 7.2.6
E.194. Release 7.2.5
E.195. Release 7.2.4
E.196. Release 7.2.3
E.197. Release 7.2.2
E.198. Release 7.2.1
E.199. Release 7.2
E.200. Release 7.1.3
E.201. Release 7.1.2
E.202. Release 7.1.1
E.203. Release 7.1
E.204. Release 7.0.3
E.205. Release 7.0.2
E.206. Release 7.0.1
E.207. Release 7.0
E.208. Release 6.5.3
E.209. Release 6.5.2
E.210. Release 6.5.1
E.211. Release 6.5
E.212. Release 6.4.2
E.213. Release 6.4.1
E.214. Release 6.4
E.215. Release 6.3.2
E.216. Release 6.3.1
E.217. Release 6.3
E.218. Release 6.2.1
E.219. Release 6.2
E.220. Release 6.1.1
E.221. Release 6.1
E.222. Release 6.0
E.223. Release 1.09
E.224. Release 1.02
E.225. Release 1.01
E.226. Release 1.0
E.227. Postgres95 Release 0.03
E.228. Postgres95 Release 0.02
E.229. Postgres95 Release 0.01

The release notes contain the significant changes in each + PostgreSQL release, with major features and migration + issues listed at the top. The release notes do not contain changes + that affect only a few users or changes that are internal and therefore not + user-visible. For example, the optimizer is improved in almost every + release, but the improvements are usually observed by users as simply + faster queries. +

A complete list of changes for each release can be obtained by + viewing the Git logs for each release. + The pgsql-committers + email list records all source code changes as well. There is also + a web + interface that shows changes to specific files. +

The name appearing next to each item represents the major developer for + that item. Of course all changes involve community discussion and patch + review, so each item is truly a community effort. +


PrevHomeNext
Unsupported FeaturesUpRelease 9.2.2
\ No newline at end of file diff --git a/doc/src/sgml/html/resources.html b/doc/src/sgml/html/resources.html new file mode 100644 index 000000000..8e038d7ee --- /dev/null +++ b/doc/src/sgml/html/resources.html @@ -0,0 +1,258 @@ + +Further Information

Further Information

Besides the documentation, that is, this book, there are other + resources about PostgreSQL: + +

Wiki

The PostgreSQL wiki contains the project's FAQ + (Frequently Asked Questions) list, TODO list, and + detailed information about many more topics. +

Web Site

The PostgreSQL + web site + carries details on the latest release and other + information to make your work or play with + PostgreSQL more productive. +

Mailing Lists

The mailing lists are a good place to have your questions + answered, to share experiences with other users, and to contact + the developers. Consult the PostgreSQL web site + for details. +

Yourself!

PostgreSQL is an open-source project. + As such, it depends on the user community for ongoing support. + As you begin to use PostgreSQL, you + will rely on others for help, either through the documentation + or through the mailing lists. Consider contributing your + knowledge back. Read the mailing lists and answer questions. If + you learn something which is not in the documentation, write it + up and contribute it. If you add features to the code, + contribute them. +

+


PrevHomeNext
ConventionsUpBug Reporting Guidelines
\ No newline at end of file diff --git a/doc/src/sgml/html/role-attributes.html b/doc/src/sgml/html/role-attributes.html new file mode 100644 index 000000000..b11f88a93 --- /dev/null +++ b/doc/src/sgml/html/role-attributes.html @@ -0,0 +1,429 @@ + +Role Attributes

20.2. Role Attributes

A database role can have a number of attributes that define its + privileges and interact with the client authentication system. + +

login privilege

Only roles that have the LOGIN attribute can be used + as the initial role name for a database connection. A role with + the LOGIN attribute can be considered the same + as a "database user". To create a role with login privilege, + use either: +

CREATE ROLE name LOGIN;
+CREATE USER name;

+ (CREATE USER is equivalent to CREATE ROLE + except that CREATE USER assumes LOGIN by + default, while CREATE ROLE does not.) +

superuser status

A database superuser bypasses all permission checks, except the right + to log in. This is a dangerous privilege and should not be used + carelessly; it is best to do most of your work as a role that is not a + superuser. To create a new database superuser, use CREATE + ROLE name SUPERUSER. You must do + this as a role that is already a superuser. +

database creation

A role must be explicitly given permission to create databases + (except for superusers, since those bypass all permission + checks). To create such a role, use CREATE ROLE + name CREATEDB. +

role creation

A role must be explicitly given permission to create more roles + (except for superusers, since those bypass all permission + checks). To create such a role, use CREATE ROLE + name CREATEROLE. + A role with CREATEROLE privilege can alter and drop + other roles, too, as well as grant or revoke membership in them. + However, to create, alter, drop, or change membership of a + superuser role, superuser status is required; + CREATEROLE is insufficient for that. +

initiating replication

A role must explicitly be given permission to initiate streaming + replication (except for superusers, since those bypass all permission + checks). A role used for streaming replication must always + have LOGIN permission as well. To create such a role, use + CREATE ROLE name REPLICATION + LOGIN. +

password

A password is only significant if the client authentication + method requires the user to supply a password when connecting + to the database. The password and + md5 authentication methods + make use of passwords. Database passwords are separate from + operating system passwords. Specify a password upon role + creation with CREATE ROLE + name PASSWORD 'string'. +

+ + A role's attributes can be modified after creation with + ALTER ROLE. + See the reference pages for the CREATE ROLE + and ALTER ROLE commands for details. +

Tip: It is good practice to create a role that has the CREATEDB + and CREATEROLE privileges, but is not a superuser, and then + use this role for all routine management of databases and roles. This + approach avoids the dangers of operating as a superuser for tasks that + do not really require it. +

A role can also have role-specific defaults for many of the run-time + configuration settings described in Chapter 18. For example, if for some reason you + want to disable index scans (hint: not a good idea) anytime you + connect, you can use: +

ALTER ROLE myname SET enable_indexscan TO off;

+ This will save the setting (but not set it immediately). In + subsequent connections by this role it will appear as though + SET enable_indexscan TO off had been executed + just before the session started. + You can still alter this setting during the session; it will only + be the default. To remove a role-specific default setting, use + ALTER ROLE rolename RESET varname. + Note that role-specific defaults attached to roles without + LOGIN privilege are fairly useless, since they will never + be invoked. +


PrevHomeNext
Database RolesUpRole Membership
\ No newline at end of file diff --git a/doc/src/sgml/html/role-membership.html b/doc/src/sgml/html/role-membership.html new file mode 100644 index 000000000..af9d0515b --- /dev/null +++ b/doc/src/sgml/html/role-membership.html @@ -0,0 +1,464 @@ + +Role Membership

20.3. Role Membership

It is frequently convenient to group users together to ease + management of privileges: that way, privileges can be granted to, or + revoked from, a group as a whole. In PostgreSQL + this is done by creating a role that represents the group, and then + granting membership in the group role to individual user + roles. +

To set up a group role, first create the role: +

CREATE ROLE name;

+ Typically a role being used as a group would not have the LOGIN + attribute, though you can set it if you wish. +

Once the group role exists, you can add and remove members using the + GRANT and + REVOKE commands: +

GRANT group_role TO role1, ... ;
+REVOKE group_role FROM role1, ... ;

+ You can grant membership to other group roles, too (since there isn't + really any distinction between group roles and non-group roles). The + database will not let you set up circular membership loops. Also, + it is not permitted to grant membership in a role to + PUBLIC. +

The members of a group role can use the privileges of the role in two + ways. First, every member of a group can explicitly do + SET ROLE to + temporarily "become" the group role. In this state, the + database session has access to the privileges of the group role rather + than the original login role, and any database objects created are + considered owned by the group role not the login role. Second, member + roles that have the INHERIT attribute automatically have use + of the privileges of roles of which they are members, including any + privileges inherited by those roles. + As an example, suppose we have done: +

CREATE ROLE joe LOGIN INHERIT;
+CREATE ROLE admin NOINHERIT;
+CREATE ROLE wheel NOINHERIT;
+GRANT admin TO joe;
+GRANT wheel TO admin;

+ Immediately after connecting as role joe, a database + session will have use of privileges granted directly to joe + plus any privileges granted to admin, because joe + "inherits" admin's privileges. However, privileges + granted to wheel are not available, because even though + joe is indirectly a member of wheel, the + membership is via admin which has the NOINHERIT + attribute. After: +

SET ROLE admin;

+ the session would have use of only those privileges granted to + admin, and not those granted to joe. After: +

SET ROLE wheel;

+ the session would have use of only those privileges granted to + wheel, and not those granted to either joe + or admin. The original privilege state can be restored + with any of: +

SET ROLE joe;
+SET ROLE NONE;
+RESET ROLE;

+

Note: The SET ROLE command always allows selecting any role + that the original login role is directly or indirectly a member of. + Thus, in the above example, it is not necessary to become + admin before becoming wheel. +

Note: In the SQL standard, there is a clear distinction between users and roles, + and users do not automatically inherit privileges while roles do. This + behavior can be obtained in PostgreSQL by giving + roles being used as SQL roles the INHERIT attribute, while + giving roles being used as SQL users the NOINHERIT attribute. + However, PostgreSQL defaults to giving all roles + the INHERIT attribute, for backward compatibility with pre-8.1 + releases in which users always had use of permissions granted to groups + they were members of. +

The role attributes LOGIN, SUPERUSER, + CREATEDB, and CREATEROLE can be thought of as + special privileges, but they are never inherited as ordinary privileges + on database objects are. You must actually SET ROLE to a + specific role having one of these attributes in order to make use of + the attribute. Continuing the above example, we might choose to + grant CREATEDB and CREATEROLE to the + admin role. Then a session connecting as role joe + would not have these privileges immediately, only after doing + SET ROLE admin. +

To destroy a group role, use DROP ROLE: +

DROP ROLE name;

+ Any memberships in the group role are automatically revoked (but the + member roles are not otherwise affected). Note however that any objects + owned by the group role must first be dropped or reassigned to other + owners; and any permissions granted to the group role must be revoked. +


PrevHomeNext
Role AttributesUpFunction and Trigger Security
\ No newline at end of file diff --git a/doc/src/sgml/html/routine-reindex.html b/doc/src/sgml/html/routine-reindex.html new file mode 100644 index 000000000..8d36d7e79 --- /dev/null +++ b/doc/src/sgml/html/routine-reindex.html @@ -0,0 +1,192 @@ + +Routine Reindexing
PostgreSQL 9.2.2 Documentation
PrevUpChapter 23. Routine Database Maintenance TasksNext

23.2. Routine Reindexing

In some situations it is worthwhile to rebuild indexes periodically + with the REINDEX + command. +

B-tree index pages that have become completely empty are reclaimed for + re-use. However, there is still a possibility + of inefficient use of space: if all but a few index keys on a page have + been deleted, the page remains allocated. Therefore, a usage + pattern in which most, but not all, keys in each range are eventually + deleted will see poor use of space. For such usage patterns, + periodic reindexing is recommended. +

The potential for bloat in non-B-tree indexes has not been well + researched. It is a good idea to periodically monitor the index's physical + size when using any non-B-tree index type. +

Also, for B-tree indexes, a freshly-constructed index is slightly faster to + access than one that has been updated many times because logically + adjacent pages are usually also physically adjacent in a newly built index. + (This consideration does not apply to non-B-tree indexes.) It + might be worthwhile to reindex periodically just to improve access speed. +


PrevHomeNext
Routine VacuumingUpLog File Maintenance
\ No newline at end of file diff --git a/doc/src/sgml/html/routine-vacuuming.html b/doc/src/sgml/html/routine-vacuuming.html new file mode 100644 index 000000000..15fc56914 --- /dev/null +++ b/doc/src/sgml/html/routine-vacuuming.html @@ -0,0 +1,1441 @@ + +Routine Vacuuming
PostgreSQL 9.2.2 Documentation
PrevUpChapter 23. Routine Database Maintenance TasksNext

23.1. Routine Vacuuming

PostgreSQL databases require periodic + maintenance known as vacuuming. For many installations, it + is sufficient to let vacuuming be performed by the autovacuum + daemon, which is described in Section 23.1.6. You might + need to adjust the autovacuuming parameters described there to obtain best + results for your situation. Some database administrators will want to + supplement or replace the daemon's activities with manually-managed + VACUUM commands, which typically are executed according to a + schedule by cron or Task + Scheduler scripts. To set up manually-managed vacuuming properly, + it is essential to understand the issues discussed in the next few + subsections. Administrators who rely on autovacuuming may still wish + to skim this material to help them understand and adjust autovacuuming. +

23.1.1. Vacuuming Basics

PostgreSQL's + VACUUM command has to + process each table on a regular basis for several reasons: + +

  1. To recover or reuse disk space occupied by updated or deleted + rows.

  2. To update data statistics used by the + PostgreSQL query planner.

  3. To update the visibility map, which speeds up index-only + scans.

  4. To protect against loss of very old data due to + transaction ID wraparound.

+ + Each of these reasons dictates performing VACUUM operations + of varying frequency and scope, as explained in the following subsections. +

There are two variants of VACUUM: standard VACUUM + and VACUUM FULL. VACUUM FULL can reclaim more + disk space but runs much more slowly. Also, + the standard form of VACUUM can run in parallel with production + database operations. (Commands such as SELECT, + INSERT, UPDATE, and + DELETE will continue to function normally, though you + will not be able to modify the definition of a table with commands such as + ALTER TABLE while it is being vacuumed.) + VACUUM FULL requires exclusive lock on the table it is + working on, and therefore cannot be done in parallel with other use + of the table. Generally, therefore, + administrators should strive to use standard VACUUM and + avoid VACUUM FULL. +

VACUUM creates a substantial amount of I/O + traffic, which can cause poor performance for other active sessions. + There are configuration parameters that can be adjusted to reduce the + performance impact of background vacuuming — see + Section 18.4.4. +

23.1.2. Recovering Disk Space

In PostgreSQL, an + UPDATE or DELETE of a row does not + immediately remove the old version of the row. + This approach is necessary to gain the benefits of multiversion + concurrency control (MVCC, see Chapter 13): the row version + must not be deleted while it is still potentially visible to other + transactions. But eventually, an outdated or deleted row version is no + longer of interest to any transaction. The space it occupies must then be + reclaimed for reuse by new rows, to avoid unbounded growth of disk + space requirements. This is done by running VACUUM. +

The standard form of VACUUM removes dead row + versions in tables and indexes and marks the space available for + future reuse. However, it will not return the space to the operating + system, except in the special case where one or more pages at the + end of a table become entirely free and an exclusive table lock can be + easily obtained. In contrast, VACUUM FULL actively compacts + tables by writing a complete new version of the table file with no dead + space. This minimizes the size of the table, but can take a long time. + It also requires extra disk space for the new copy of the table, until + the operation completes. +

The usual goal of routine vacuuming is to do standard VACUUMs + often enough to avoid needing VACUUM FULL. The + autovacuum daemon attempts to work this way, and in fact will + never issue VACUUM FULL. In this approach, the idea + is not to keep tables at their minimum size, but to maintain steady-state + usage of disk space: each table occupies space equivalent to its + minimum size plus however much space gets used up between vacuumings. + Although VACUUM FULL can be used to shrink a table back + to its minimum size and return the disk space to the operating system, + there is not much point in this if the table will just grow again in the + future. Thus, moderately-frequent standard VACUUM runs are a + better approach than infrequent VACUUM FULL runs for + maintaining heavily-updated tables. +

Some administrators prefer to schedule vacuuming themselves, for example + doing all the work at night when load is low. + The difficulty with doing vacuuming according to a fixed schedule + is that if a table has an unexpected spike in update activity, it may + get bloated to the point that VACUUM FULL is really necessary + to reclaim space. Using the autovacuum daemon alleviates this problem, + since the daemon schedules vacuuming dynamically in response to update + activity. It is unwise to disable the daemon completely unless you + have an extremely predictable workload. One possible compromise is + to set the daemon's parameters so that it will only react to unusually + heavy update activity, thus keeping things from getting out of hand, + while scheduled VACUUMs are expected to do the bulk of the + work when the load is typical. +

For those not using autovacuum, a typical approach is to schedule a + database-wide VACUUM once a day during a low-usage period, + supplemented by more frequent vacuuming of heavily-updated tables as + necessary. (Some installations with extremely high update rates vacuum + their busiest tables as often as once every few minutes.) If you have + multiple databases in a cluster, don't forget to + VACUUM each one; the program vacuumdb might be helpful. +

Tip: Plain VACUUM may not be satisfactory when + a table contains large numbers of dead row versions as a result of + massive update or delete activity. If you have such a table and + you need to reclaim the excess disk space it occupies, you will need + to use VACUUM FULL, or alternatively + CLUSTER + or one of the table-rewriting variants of + ALTER TABLE. + These commands rewrite an entire new copy of the table and build + new indexes for it. All these options require exclusive lock. Note that + they also temporarily use extra disk space approximately equal to the size + of the table, since the old copies of the table and indexes can't be + released until the new ones are complete. +

Tip: If you have a table whose entire contents are deleted on a periodic + basis, consider doing it with + TRUNCATE rather + than using DELETE followed by + VACUUM. TRUNCATE removes the + entire content of the table immediately, without requiring a + subsequent VACUUM or VACUUM + FULL to reclaim the now-unused disk space. + The disadvantage is that strict MVCC semantics are violated. +

23.1.3. Updating Planner Statistics

The PostgreSQL query planner relies on + statistical information about the contents of tables in order to + generate good plans for queries. These statistics are gathered by + the ANALYZE command, + which can be invoked by itself or + as an optional step in VACUUM. It is important to have + reasonably accurate statistics, otherwise poor choices of plans might + degrade database performance. +

The autovacuum daemon, if enabled, will automatically issue + ANALYZE commands whenever the content of a table has + changed sufficiently. However, administrators might prefer to rely + on manually-scheduled ANALYZE operations, particularly + if it is known that update activity on a table will not affect the + statistics of "interesting" columns. The daemon schedules + ANALYZE strictly as a function of the number of rows + inserted or updated; it has no knowledge of whether that will lead + to meaningful statistical changes. +

As with vacuuming for space recovery, frequent updates of statistics + are more useful for heavily-updated tables than for seldom-updated + ones. But even for a heavily-updated table, there might be no need for + statistics updates if the statistical distribution of the data is + not changing much. A simple rule of thumb is to think about how much + the minimum and maximum values of the columns in the table change. + For example, a timestamp column that contains the time + of row update will have a constantly-increasing maximum value as + rows are added and updated; such a column will probably need more + frequent statistics updates than, say, a column containing URLs for + pages accessed on a website. The URL column might receive changes just + as often, but the statistical distribution of its values probably + changes relatively slowly. +

It is possible to run ANALYZE on specific tables and even + just specific columns of a table, so the flexibility exists to update some + statistics more frequently than others if your application requires it. + In practice, however, it is usually best to just analyze the entire + database, because it is a fast operation. ANALYZE uses a + statistically random sampling of the rows of a table rather than reading + every single row. +

Tip: Although per-column tweaking of ANALYZE frequency might not be + very productive, you might find it worthwhile to do per-column + adjustment of the level of detail of the statistics collected by + ANALYZE. Columns that are heavily used in WHERE + clauses and have highly irregular data distributions might require a + finer-grain data histogram than other columns. See ALTER TABLE + SET STATISTICS, or change the database-wide default using the default_statistics_target configuration parameter. +

Also, by default there is limited information available about + the selectivity of functions. However, if you create an expression + index that uses a function call, useful statistics will be + gathered about the function, which can greatly improve query + plans that use the expression index. +

Tip: The autovacuum daemon does not issue ANALYZE commands for + foreign tables, since it has no means of determining how often that + might be useful. If your queries require statistics on foreign tables + for proper planning, it's a good idea to run manually-managed + ANALYZE commands on those tables on a suitable schedule. +

23.1.4. Updating The Visibility Map

Vacuum maintains a visibility map for each + table to keep track of which pages contain only tuples that are known to be + visible to all active transactions (and all future transactions, until the + page is again modified). This has two purposes. First, vacuum + itself can skip such pages on the next run, since there is nothing to + clean up. +

Second, it allows PostgreSQL to answer some + queries using only the index, without reference to the underlying table. + Since PostgreSQL indexes don't contain tuple + visibility information, a normal index scan fetches the heap tuple for each + matching index entry, to check whether it should be seen by the current + transaction. An index-only scan, on the other hand, checks + the visibility map first. If it's known that all tuples on the page are + visible, the heap fetch can be skipped. This is most noticeable on + large data sets where the visibility map can prevent disk accesses. + The visibility map is vastly smaller than the heap, so it can easily be + cached even when the heap is very large. +

23.1.5. Preventing Transaction ID Wraparound Failures

PostgreSQL's MVCC transaction semantics + depend on being able to compare transaction ID (XID) + numbers: a row version with an insertion XID greater than the current + transaction's XID is "in the future" and should not be visible + to the current transaction. But since transaction IDs have limited size + (32 bits) a cluster that runs for a long time (more + than 4 billion transactions) would suffer transaction ID + wraparound: the XID counter wraps around to zero, and all of a sudden + transactions that were in the past appear to be in the future — which + means their output become invisible. In short, catastrophic data loss. + (Actually the data is still there, but that's cold comfort if you cannot + get at it.) To avoid this, it is necessary to vacuum every table + in every database at least once every two billion transactions. +

The reason that periodic vacuuming solves the problem is that + PostgreSQL reserves a special XID + as FrozenXID. This XID does not follow the normal XID + comparison rules and is always considered older + than every normal XID. Normal XIDs are + compared using modulo-231 arithmetic. This means + that for every normal XID, there are two billion XIDs that are + "older" and two billion that are "newer"; another + way to say it is that the normal XID space is circular with no + endpoint. Therefore, once a row version has been created with a particular + normal XID, the row version will appear to be "in the past" for + the next two billion transactions, no matter which normal XID we are + talking about. If the row version still exists after more than two billion + transactions, it will suddenly appear to be in the future. To + prevent this, old row versions must be reassigned the XID + FrozenXID sometime before they reach the + two-billion-transactions-old mark. Once they are assigned this + special XID, they will appear to be "in the past" to all + normal transactions regardless of wraparound issues, and so such + row versions will be valid until deleted, no matter how long that is. + This reassignment of old XIDs is handled by VACUUM. +

vacuum_freeze_min_age + controls how old an XID value has to be before it's replaced with + FrozenXID. Larger values of this setting + preserve transactional information longer, while smaller values increase + the number of transactions that can elapse before the table must be + vacuumed again. +

VACUUM normally skips pages that don't have any dead row + versions, but those pages might still have row versions with old XID + values. To ensure all old XIDs have been replaced by + FrozenXID, a scan of the whole table is needed. + vacuum_freeze_table_age controls when + VACUUM does that: a whole table sweep is forced if + the table hasn't been fully scanned for vacuum_freeze_table_age + minus vacuum_freeze_min_age transactions. Setting it to 0 + forces VACUUM to always scan all pages, effectively ignoring + the visibility map. +

The maximum time that a table can go unvacuumed is two billion + transactions minus the vacuum_freeze_min_age value at + the time VACUUM last scanned the whole table. If it were to go + unvacuumed for longer than + that, data loss could result. To ensure that this does not happen, + autovacuum is invoked on any table that might contain XIDs older than the + age specified by the configuration parameter autovacuum_freeze_max_age. (This will happen even if + autovacuum is disabled.) +

This implies that if a table is not otherwise vacuumed, + autovacuum will be invoked on it approximately once every + autovacuum_freeze_max_age minus + vacuum_freeze_min_age transactions. + For tables that are regularly vacuumed for space reclamation purposes, + this is of little importance. However, for static tables + (including tables that receive inserts, but no updates or deletes), + there is no need to vacuum for space reclamation, so it can + be useful to try to maximize the interval between forced autovacuums + on very large static tables. Obviously one can do this either by + increasing autovacuum_freeze_max_age or decreasing + vacuum_freeze_min_age. +

The effective maximum for vacuum_freeze_table_age is 0.95 * + autovacuum_freeze_max_age; a setting higher than that will be + capped to the maximum. A value higher than + autovacuum_freeze_max_age wouldn't make sense because an + anti-wraparound autovacuum would be triggered at that point anyway, and + the 0.95 multiplier leaves some breathing room to run a manual + VACUUM before that happens. As a rule of thumb, + vacuum_freeze_table_age should be set to a value somewhat + below autovacuum_freeze_max_age, leaving enough gap so that + a regularly scheduled VACUUM or an autovacuum triggered by + normal delete and update activity is run in that window. Setting it too + close could lead to anti-wraparound autovacuums, even though the table + was recently vacuumed to reclaim space, whereas lower values lead to more + frequent whole-table scans. +

The sole disadvantage of increasing autovacuum_freeze_max_age + (and vacuum_freeze_table_age along with it) + is that the pg_clog subdirectory of the database cluster + will take more space, because it must store the commit status of all + transactions back to the autovacuum_freeze_max_age horizon. + The commit status uses two bits per transaction, so if + autovacuum_freeze_max_age is set to its maximum allowed + value of two billion, pg_clog can be expected to + grow to about half a gigabyte. If this is trivial compared to your + total database size, setting autovacuum_freeze_max_age to + its maximum allowed value is recommended. Otherwise, set it depending + on what you are willing to allow for pg_clog storage. + (The default, 200 million transactions, translates to about 50MB of + pg_clog storage.) +

One disadvantage of decreasing vacuum_freeze_min_age is that + it might cause VACUUM to do useless work: changing a table row's + XID to FrozenXID is a waste of time if the row is modified + soon thereafter (causing it to acquire a new XID). So the setting should + be large enough that rows are not frozen until they are unlikely to change + any more. Another disadvantage of decreasing this setting is + that details about exactly which transaction inserted or modified a + row will be lost sooner. This information sometimes comes in handy, + particularly when trying to analyze what went wrong after a database + failure. For these two reasons, decreasing this setting is not + recommended except for completely static tables. +

To track the age of the oldest XIDs in a database, + VACUUM stores XID + statistics in the system tables pg_class and + pg_database. In particular, + the relfrozenxid column of a table's + pg_class row contains the freeze cutoff XID that was used + by the last whole-table VACUUM for that table. All normal + XIDs older than this cutoff XID are guaranteed to have been replaced by + FrozenXID within the table. Similarly, + the datfrozenxid column of a database's + pg_database row is a lower bound on the normal XIDs + appearing in that database — it is just the minimum of the + per-table relfrozenxid values within the database. + A convenient way to + examine this information is to execute queries such as: + +

SELECT relname, age(relfrozenxid) FROM pg_class WHERE relkind = 'r';
+SELECT datname, age(datfrozenxid) FROM pg_database;

+ + The age column measures the number of transactions from the + cutoff XID to the current transaction's XID. +

VACUUM normally + only scans pages that have been modified since the last vacuum, but + relfrozenxid can only be advanced when the whole table is + scanned. The whole table is scanned when relfrozenxid is + more than vacuum_freeze_table_age transactions old, when + VACUUM's FREEZE option is used, or when all pages + happen to + require vacuuming to remove dead row versions. When VACUUM + scans the whole table, after it's finished age(relfrozenxid) + should be a little more than the vacuum_freeze_min_age setting + that was used (more by the number of transactions started since the + VACUUM started). If no whole-table-scanning VACUUM + is issued on the table until autovacuum_freeze_max_age is + reached, an autovacuum will soon be forced for the table. +

If for some reason autovacuum fails to clear old XIDs from a table, + the system will begin to emit warning messages like this when the + database's oldest XIDs reach ten million transactions from the wraparound + point: + +

WARNING:  database "mydb" must be vacuumed within 177009986 transactions
+HINT:  To avoid a database shutdown, execute a database-wide VACUUM in "mydb".

+ + (A manual VACUUM should fix the problem, as suggested by the + hint; but note that the VACUUM must be performed by a + superuser, else it will fail to process system catalogs and thus not + be able to advance the database's datfrozenxid.) + If these warnings are + ignored, the system will shut down and refuse to start any new + transactions once there are fewer than 1 million transactions left + until wraparound: + +

ERROR:  database is not accepting commands to avoid wraparound data loss in database "mydb"
+HINT:  Stop the postmaster and use a standalone backend to VACUUM in "mydb".

+ + The 1-million-transaction safety margin exists to let the + administrator recover without data loss, by manually executing the + required VACUUM commands. However, since the system will not + execute commands once it has gone into the safety shutdown mode, + the only way to do this is to stop the server and use a single-user + backend to execute VACUUM. The shutdown mode is not enforced + by a single-user backend. See the postgres reference + page for details about using a single-user backend. +

23.1.6. The Autovacuum Daemon

PostgreSQL has an optional but highly + recommended feature called autovacuum, + whose purpose is to automate the execution of + VACUUM and ANALYZE commands. + When enabled, autovacuum checks for + tables that have had a large number of inserted, updated or deleted + tuples. These checks use the statistics collection facility; + therefore, autovacuum cannot be used unless track_counts is set to true. + In the default configuration, autovacuuming is enabled and the related + configuration parameters are appropriately set. +

The "autovacuum daemon" actually consists of multiple processes. + There is a persistent daemon process, called the + autovacuum launcher, which is in charge of starting + autovacuum worker processes for all databases. The + launcher will distribute the work across time, attempting to start one + worker within each database every autovacuum_naptime + seconds. (Therefore, if the installation has N databases, + a new worker will be launched every + autovacuum_naptime/N seconds.) + A maximum of autovacuum_max_workers worker processes + are allowed to run at the same time. If there are more than + autovacuum_max_workers databases to be processed, + the next database will be processed as soon as the first worker finishes. + Each worker process will check each table within its database and + execute VACUUM and/or ANALYZE as needed. +

If several large tables all become eligible for vacuuming in a short + amount of time, all autovacuum workers might become occupied with + vacuuming those tables for a long period. This would result + in other tables and databases not being vacuumed until a worker became + available. There is no limit on how many workers might be in a + single database, but workers do try to avoid repeating work that has + already been done by other workers. Note that the number of running + workers does not count towards max_connections or + superuser_reserved_connections limits. +

Tables whose relfrozenxid value is more than + autovacuum_freeze_max_age transactions old are always + vacuumed (this also applies to those tables whose freeze max age has + been modified via storage parameters; see below). Otherwise, if the + number of tuples obsoleted since the last + VACUUM exceeds the "vacuum threshold", the + table is vacuumed. The vacuum threshold is defined as: +

vacuum threshold = vacuum base threshold + vacuum scale factor * number of tuples

+ where the vacuum base threshold is + autovacuum_vacuum_threshold, + the vacuum scale factor is + autovacuum_vacuum_scale_factor, + and the number of tuples is + pg_class.reltuples. + The number of obsolete tuples is obtained from the statistics + collector; it is a semi-accurate count updated by each + UPDATE and DELETE operation. (It + is only semi-accurate because some information might be lost under heavy + load.) If the relfrozenxid value of the table is more + than vacuum_freeze_table_age transactions old, the whole + table is scanned to freeze old tuples and advance + relfrozenxid, otherwise only pages that have been modified + since the last vacuum are scanned. +

For analyze, a similar condition is used: the threshold, defined as: +

analyze threshold = analyze base threshold + analyze scale factor * number of tuples

+ is compared to the total number of tuples inserted, updated, or deleted + since the last ANALYZE. +

Temporary tables cannot be accessed by autovacuum. Therefore, + appropriate vacuum and analyze operations should be performed via + session SQL commands. +

The default thresholds and scale factors are taken from + postgresql.conf, but it is possible to override them + on a table-by-table basis; see + Storage Parameters for more information. + If a setting + has been changed via storage parameters, that value is used; otherwise the + global settings are used. See Section 18.10 for + more details on the global settings. +

Besides the base threshold values and scale factors, there are six + more autovacuum parameters that can be set for each table via + storage parameters. + The first parameter, autovacuum_enabled, + can be set to false to instruct the autovacuum daemon + to skip that particular table entirely. In this case + autovacuum will only touch the table if it must do so + to prevent transaction ID wraparound. + Another two parameters, + autovacuum_vacuum_cost_delay and + autovacuum_vacuum_cost_limit, are used to set + table-specific values for the cost-based vacuum delay feature + (see Section 18.4.4). + autovacuum_freeze_min_age, + autovacuum_freeze_max_age and + autovacuum_freeze_table_age are used to set + values for vacuum_freeze_min_age, + autovacuum_freeze_max_age and + vacuum_freeze_table_age respectively. +

When multiple workers are running, the cost limit is + "balanced" among all the running workers, so that the + total impact on the system is the same, regardless of the number + of workers actually running. +


PrevHomeNext
Routine Database Maintenance TasksUpRoutine Reindexing
\ No newline at end of file diff --git a/doc/src/sgml/html/row-estimation-examples.html b/doc/src/sgml/html/row-estimation-examples.html new file mode 100644 index 000000000..6a1088975 --- /dev/null +++ b/doc/src/sgml/html/row-estimation-examples.html @@ -0,0 +1,831 @@ + +Row Estimation Examples
PostgreSQL 9.2.2 Documentation
PrevUpChapter 58. How the Planner Uses StatisticsNext

58.1. Row Estimation Examples

The examples shown below use tables in the PostgreSQL + regression test database. + The outputs shown are taken from version 8.3. + The behavior of earlier (or later) versions might vary. + Note also that since ANALYZE uses random sampling + while producing statistics, the results will change slightly after + any new ANALYZE. +

Let's start with a very simple query: + +

EXPLAIN SELECT * FROM tenk1;
+
+                         QUERY PLAN
+-------------------------------------------------------------
+ Seq Scan on tenk1  (cost=0.00..458.00 rows=10000 width=244)

+ + How the planner determines the cardinality of tenk1 + is covered in Section 14.2, but is repeated here for + completeness. The number of pages and rows is looked up in + pg_class: + +

SELECT relpages, reltuples FROM pg_class WHERE relname = 'tenk1';
+
+ relpages | reltuples
+----------+-----------
+      358 |     10000

+ + These numbers are current as of the last VACUUM or + ANALYZE on the table. The planner then fetches the + actual current number of pages in the table (this is a cheap operation, + not requiring a table scan). If that is different from + relpages then + reltuples is scaled accordingly to + arrive at a current number-of-rows estimate. In this case the value of + relpages is up-to-date so the rows estimate is + the same as reltuples. +

Let's move on to an example with a range condition in its + WHERE clause: + +

EXPLAIN SELECT * FROM tenk1 WHERE unique1 < 1000;
+
+                                   QUERY PLAN
+--------------------------------------------------------------------------------
+ Bitmap Heap Scan on tenk1  (cost=24.06..394.64 rows=1007 width=244)
+   Recheck Cond: (unique1 < 1000)
+   ->  Bitmap Index Scan on tenk1_unique1  (cost=0.00..23.80 rows=1007 width=0)
+         Index Cond: (unique1 < 1000)

+ + The planner examines the WHERE clause condition + and looks up the selectivity function for the operator + < in pg_operator. + This is held in the column oprrest, + and the entry in this case is scalarltsel. + The scalarltsel function retrieves the histogram for + unique1 from + pg_statistics. For manual queries it is more + convenient to look in the simpler pg_stats + view: + +

SELECT histogram_bounds FROM pg_stats
+WHERE tablename='tenk1' AND attname='unique1';
+
+                   histogram_bounds
+------------------------------------------------------
+ {0,993,1997,3050,4040,5036,5957,7057,8029,9016,9995}

+ + Next the fraction of the histogram occupied by "< 1000" + is worked out. This is the selectivity. The histogram divides the range + into equal frequency buckets, so all we have to do is locate the bucket + that our value is in and count part of it and + all of the ones before. The value 1000 is clearly in + the second bucket (993-1997). Assuming a linear distribution of + values inside each bucket, we can calculate the selectivity as: + +

selectivity = (1 + (1000 - bucket[2].min)/(bucket[2].max - bucket[2].min))/num_buckets
+            = (1 + (1000 - 993)/(1997 - 993))/10
+            = 0.100697

+ + that is, one whole bucket plus a linear fraction of the second, divided by + the number of buckets. The estimated number of rows can now be calculated as + the product of the selectivity and the cardinality of + tenk1: + +

rows = rel_cardinality * selectivity
+     = 10000 * 0.100697
+     = 1007  (rounding off)

+

Next let's consider an example with an equality condition in its + WHERE clause: + +

EXPLAIN SELECT * FROM tenk1 WHERE stringu1 = 'CRAAAA';
+
+                        QUERY PLAN
+----------------------------------------------------------
+ Seq Scan on tenk1  (cost=0.00..483.00 rows=30 width=244)
+   Filter: (stringu1 = 'CRAAAA'::name)

+ + Again the planner examines the WHERE clause condition + and looks up the selectivity function for =, which is + eqsel. For equality estimation the histogram is + not useful; instead the list of most + common values (MCVs) is used to determine the + selectivity. Let's have a look at the MCVs, with some additional columns + that will be useful later: + +

SELECT null_frac, n_distinct, most_common_vals, most_common_freqs FROM pg_stats
+WHERE tablename='tenk1' AND attname='stringu1';
+
+null_frac         | 0
+n_distinct        | 676
+most_common_vals  | {EJAAAA,BBAAAA,CRAAAA,FCAAAA,FEAAAA,GSAAAA,JOAAAA,MCAAAA,NAAAAA,WGAAAA}
+most_common_freqs | {0.00333333,0.003,0.003,0.003,0.003,0.003,0.003,0.003,0.003,0.003}

+ + Since CRAAAA appears in the list of MCVs, the selectivity is + merely the corresponding entry in the list of most common frequencies + (MCFs): + +

selectivity = mcf[3]
+            = 0.003

+ + As before, the estimated number of rows is just the product of this with the + cardinality of tenk1: + +

rows = 10000 * 0.003
+     = 30

+

Now consider the same query, but with a constant that is not in the + MCV list: + +

EXPLAIN SELECT * FROM tenk1 WHERE stringu1 = 'xxx';
+
+                        QUERY PLAN
+----------------------------------------------------------
+ Seq Scan on tenk1  (cost=0.00..483.00 rows=15 width=244)
+   Filter: (stringu1 = 'xxx'::name)

+ + This is quite a different problem: how to estimate the selectivity when the + value is not in the MCV list. + The approach is to use the fact that the value is not in the list, + combined with the knowledge of the frequencies for all of the + MCVs: + +

selectivity = (1 - sum(mvf))/(num_distinct - num_mcv)
+            = (1 - (0.00333333 + 0.003 + 0.003 + 0.003 + 0.003 + 0.003 +
+                    0.003 + 0.003 + 0.003 + 0.003))/(676 - 10)
+            = 0.0014559

+ + That is, add up all the frequencies for the MCVs and + subtract them from one, then + divide by the number of other distinct values. + This amounts to assuming that the fraction of the column that is not any + of the MCVs is evenly distributed among all the other distinct values. + Notice that there are no null values so we don't have to worry about those + (otherwise we'd subtract the null fraction from the numerator as well). + The estimated number of rows is then calculated as usual: + +

rows = 10000 * 0.0014559
+     = 15  (rounding off)

+

The previous example with unique1 < 1000 was an + oversimplification of what scalarltsel really does; + now that we have seen an example of the use of MCVs, we can fill in some + more detail. The example was correct as far as it went, because since + unique1 is a unique column it has no MCVs (obviously, no + value is any more common than any other value). For a non-unique + column, there will normally be both a histogram and an MCV list, and + the histogram does not include the portion of the column + population represented by the MCVs. We do things this way because + it allows more precise estimation. In this situation + scalarltsel directly applies the condition (e.g., + "< 1000") to each value of the MCV list, and adds up the + frequencies of the MCVs for which the condition is true. This gives + an exact estimate of the selectivity within the portion of the table + that is MCVs. The histogram is then used in the same way as above + to estimate the selectivity in the portion of the table that is not + MCVs, and then the two numbers are combined to estimate the overall + selectivity. For example, consider + +

EXPLAIN SELECT * FROM tenk1 WHERE stringu1 < 'IAAAAA';
+
+                         QUERY PLAN
+------------------------------------------------------------
+ Seq Scan on tenk1  (cost=0.00..483.00 rows=3077 width=244)
+   Filter: (stringu1 < 'IAAAAA'::name)

+ + We already saw the MCV information for stringu1, + and here is its histogram: + +

SELECT histogram_bounds FROM pg_stats
+WHERE tablename='tenk1' AND attname='stringu1';
+
+                                histogram_bounds
+--------------------------------------------------------------------------------
+ {AAAAAA,CQAAAA,FRAAAA,IBAAAA,KRAAAA,NFAAAA,PSAAAA,SGAAAA,VAAAAA,XLAAAA,ZZAAAA}

+ + Checking the MCV list, we find that the condition stringu1 < + 'IAAAAA' is satisfied by the first six entries and not the last four, + so the selectivity within the MCV part of the population is + +

selectivity = sum(relevant mvfs)
+            = 0.00333333 + 0.003 + 0.003 + 0.003 + 0.003 + 0.003
+            = 0.01833333

+ + Summing all the MCFs also tells us that the total fraction of the + population represented by MCVs is 0.03033333, and therefore the + fraction represented by the histogram is 0.96966667 (again, there + are no nulls, else we'd have to exclude them here). We can see + that the value IAAAAA falls nearly at the end of the + third histogram bucket. Using some rather cheesy assumptions + about the frequency of different characters, the planner arrives + at the estimate 0.298387 for the portion of the histogram population + that is less than IAAAAA. We then combine the estimates + for the MCV and non-MCV populations: + +

selectivity = mcv_selectivity + histogram_selectivity * histogram_fraction
+            = 0.01833333 + 0.298387 * 0.96966667
+            = 0.307669
+
+rows        = 10000 * 0.307669
+            = 3077  (rounding off)

+ + In this particular example, the correction from the MCV list is fairly + small, because the column distribution is actually quite flat (the + statistics showing these particular values as being more common than + others are mostly due to sampling error). In a more typical case where + some values are significantly more common than others, this complicated + process gives a useful improvement in accuracy because the selectivity + for the most common values is found exactly. +

Now let's consider a case with more than one + condition in the WHERE clause: + +

EXPLAIN SELECT * FROM tenk1 WHERE unique1 < 1000 AND stringu1 = 'xxx';
+
+                                   QUERY PLAN
+--------------------------------------------------------------------------------
+ Bitmap Heap Scan on tenk1  (cost=23.80..396.91 rows=1 width=244)
+   Recheck Cond: (unique1 < 1000)
+   Filter: (stringu1 = 'xxx'::name)
+   ->  Bitmap Index Scan on tenk1_unique1  (cost=0.00..23.80 rows=1007 width=0)
+         Index Cond: (unique1 < 1000)

+ + The planner assumes that the two conditions are independent, so that + the individual selectivities of the clauses can be multiplied together: + +

selectivity = selectivity(unique1 < 1000) * selectivity(stringu1 = 'xxx')
+            = 0.100697 * 0.0014559
+            = 0.0001466
+
+rows        = 10000 * 0.0001466
+            = 1  (rounding off)

+ + Notice that the number of rows estimated to be returned from the bitmap + index scan reflects only the condition used with the index; this is + important since it affects the cost estimate for the subsequent heap + fetches. +

Finally we will examine a query that involves a join: + +

EXPLAIN SELECT * FROM tenk1 t1, tenk2 t2
+WHERE t1.unique1 < 50 AND t1.unique2 = t2.unique2;
+
+                                      QUERY PLAN
+--------------------------------------------------------------------------------------
+ Nested Loop  (cost=4.64..456.23 rows=50 width=488)
+   ->  Bitmap Heap Scan on tenk1 t1  (cost=4.64..142.17 rows=50 width=244)
+         Recheck Cond: (unique1 < 50)
+         ->  Bitmap Index Scan on tenk1_unique1  (cost=0.00..4.63 rows=50 width=0)
+               Index Cond: (unique1 < 50)
+   ->  Index Scan using tenk2_unique2 on tenk2 t2  (cost=0.00..6.27 rows=1 width=244)
+         Index Cond: (unique2 = t1.unique2)

+ + The restriction on tenk1, + unique1 < 50, + is evaluated before the nested-loop join. + This is handled analogously to the previous range example. This time the + value 50 falls into the first bucket of the + unique1 histogram: + +

selectivity = (0 + (50 - bucket[1].min)/(bucket[1].max - bucket[1].min))/num_buckets
+            = (0 + (50 - 0)/(993 - 0))/10
+            = 0.005035
+
+rows        = 10000 * 0.005035
+            = 50  (rounding off)

+ + The restriction for the join is t2.unique2 = t1.unique2. + The operator is just + our familiar =, however the selectivity function is + obtained from the oprjoin column of + pg_operator, and is eqjoinsel. + eqjoinsel looks up the statistical information for both + tenk2 and tenk1: + +

SELECT tablename, null_frac,n_distinct, most_common_vals FROM pg_stats
+WHERE tablename IN ('tenk1', 'tenk2') AND attname='unique2';
+
+tablename  | null_frac | n_distinct | most_common_vals
+-----------+-----------+------------+------------------
+ tenk1     |         0 |         -1 |
+ tenk2     |         0 |         -1 |

+ + In this case there is no MCV information for + unique2 because all the values appear to be + unique, so we use an algorithm that relies only on the number of + distinct values for both relations together with their null fractions: + +

selectivity = (1 - null_frac1) * (1 - null_frac2) * min(1/num_distinct1, 1/num_distinct2)
+            = (1 - 0) * (1 - 0) / max(10000, 10000)
+            = 0.0001

+ + This is, subtract the null fraction from one for each of the relations, + and divide by the maximum of the numbers of distinct values. + The number of rows + that the join is likely to emit is calculated as the cardinality of the + Cartesian product of the two inputs, multiplied by the + selectivity: + +

rows = (outer_cardinality * inner_cardinality) * selectivity
+     = (50 * 10000) * 0.0001
+     = 50

+

Had there been MCV lists for the two columns, + eqjoinsel would have used direct comparison of the MCV + lists to determine the join selectivity within the part of the column + populations represented by the MCVs. The estimate for the remainder of the + populations follows the same approach shown here. +

Notice that we showed inner_cardinality as 10000, that is, + the unmodified size of tenk2. It might appear from + inspection of the EXPLAIN output that the estimate of + join rows comes from 50 * 1, that is, the number of outer rows times + the estimated number of rows obtained by each inner index scan on + tenk2. But this is not the case: the join relation size + is estimated before any particular join plan has been considered. If + everything is working well then the two ways of estimating the join + size will produce about the same answer, but due to roundoff error and + other factors they sometimes diverge significantly. +

For those interested in further details, estimation of the size of + a table (before any WHERE clauses) is done in + src/backend/optimizer/util/plancat.c. The generic + logic for clause selectivities is in + src/backend/optimizer/path/clausesel.c. The + operator-specific selectivity functions are mostly found + in src/backend/utils/adt/selfuncs.c. +


PrevHomeNext
How the Planner Uses StatisticsUpAppendixes
\ No newline at end of file diff --git a/doc/src/sgml/html/rowtypes.html b/doc/src/sgml/html/rowtypes.html new file mode 100644 index 000000000..7248b007b --- /dev/null +++ b/doc/src/sgml/html/rowtypes.html @@ -0,0 +1,625 @@ + +Composite Types

8.16. Composite Types

A composite type represents the structure of a row or record; + it is essentially just a list of field names and their data types. + PostgreSQL allows composite types to be + used in many of the same ways that simple types can be used. For example, a + column of a table can be declared to be of a composite type. +

8.16.1. Declaration of Composite Types

Here are two simple examples of defining composite types: +

CREATE TYPE complex AS (
+    r       double precision,
+    i       double precision
+);
+
+CREATE TYPE inventory_item AS (
+    name            text,
+    supplier_id     integer,
+    price           numeric
+);

+ The syntax is comparable to CREATE TABLE, except that only + field names and types can be specified; no constraints (such as NOT + NULL) can presently be included. Note that the AS keyword + is essential; without it, the system will think a different kind + of CREATE TYPE command is meant, and you will get odd syntax + errors. +

Having defined the types, we can use them to create tables: + +

CREATE TABLE on_hand (
+    item      inventory_item,
+    count     integer
+);
+
+INSERT INTO on_hand VALUES (ROW('fuzzy dice', 42, 1.99), 1000);

+ + or functions: + +

CREATE FUNCTION price_extension(inventory_item, integer) RETURNS numeric
+AS 'SELECT $1.price * $2' LANGUAGE SQL;
+
+SELECT price_extension(item, 10) FROM on_hand;

+ +

Whenever you create a table, a composite type is also automatically + created, with the same name as the table, to represent the table's + row type. For example, had we said: +

CREATE TABLE inventory_item (
+    name            text,
+    supplier_id     integer REFERENCES suppliers,
+    price           numeric CHECK (price > 0)
+);

+ then the same inventory_item composite type shown above would + come into being as a + byproduct, and could be used just as above. Note however an important + restriction of the current implementation: since no constraints are + associated with a composite type, the constraints shown in the table + definition do not apply to values of the composite type + outside the table. (A partial workaround is to use domain + types as members of composite types.) +

8.16.2. Composite Value Input

To write a composite value as a literal constant, enclose the field + values within parentheses and separate them by commas. You can put double + quotes around any field value, and must do so if it contains commas or + parentheses. (More details appear below.) Thus, the general format of a + composite constant is the following: +

'( val1 , val2 , ... )'

+ An example is: +

'("fuzzy dice",42,1.99)'

+ which would be a valid value of the inventory_item type + defined above. To make a field be NULL, write no characters at all + in its position in the list. For example, this constant specifies + a NULL third field: +

'("fuzzy dice",42,)'

+ If you want an empty string rather than NULL, write double quotes: +

'("",42,)'

+ Here the first field is a non-NULL empty string, the third is NULL. +

(These constants are actually only a special case of + the generic type constants discussed in Section 4.1.2.7. The constant is initially + treated as a string and passed to the composite-type input conversion + routine. An explicit type specification might be necessary.) +

The ROW expression syntax can also be used to + construct composite values. In most cases this is considerably + simpler to use than the string-literal syntax since you don't have + to worry about multiple layers of quoting. We already used this + method above: +

ROW('fuzzy dice', 42, 1.99)
+ROW('', 42, NULL)

+ The ROW keyword is actually optional as long as you have more than one + field in the expression, so these can simplify to: +

('fuzzy dice', 42, 1.99)
+('', 42, NULL)

+ The ROW expression syntax is discussed in more detail in Section 4.2.13. +

8.16.3. Accessing Composite Types

To access a field of a composite column, one writes a dot and the field + name, much like selecting a field from a table name. In fact, it's so + much like selecting from a table name that you often have to use parentheses + to keep from confusing the parser. For example, you might try to select + some subfields from our on_hand example table with something + like: + +

SELECT item.name FROM on_hand WHERE item.price > 9.99;

+ + This will not work since the name item is taken to be a table + name, not a column name of on_hand, per SQL syntax rules. + You must write it like this: + +

SELECT (item).name FROM on_hand WHERE (item).price > 9.99;

+ + or if you need to use the table name as well (for instance in a multitable + query), like this: + +

SELECT (on_hand.item).name FROM on_hand WHERE (on_hand.item).price > 9.99;

+ + Now the parenthesized object is correctly interpreted as a reference to + the item column, and then the subfield can be selected from it. +

Similar syntactic issues apply whenever you select a field from a composite + value. For instance, to select just one field from the result of a function + that returns a composite value, you'd need to write something like: + +

SELECT (my_func(...)).field FROM ...

+ + Without the extra parentheses, this will generate a syntax error. +

8.16.4. Modifying Composite Types

Here are some examples of the proper syntax for inserting and updating + composite columns. + First, inserting or updating a whole column: + +

INSERT INTO mytab (complex_col) VALUES((1.1,2.2));
+
+UPDATE mytab SET complex_col = ROW(1.1,2.2) WHERE ...;

+ + The first example omits ROW, the second uses it; we + could have done it either way. +

We can update an individual subfield of a composite column: + +

UPDATE mytab SET complex_col.r = (complex_col).r + 1 WHERE ...;

+ + Notice here that we don't need to (and indeed cannot) + put parentheses around the column name appearing just after + SET, but we do need parentheses when referencing the same + column in the expression to the right of the equal sign. +

And we can specify subfields as targets for INSERT, too: + +

INSERT INTO mytab (complex_col.r, complex_col.i) VALUES(1.1, 2.2);

+ + Had we not supplied values for all the subfields of the column, the + remaining subfields would have been filled with null values. +

8.16.5. Composite Type Input and Output Syntax

The external text representation of a composite value consists of items that + are interpreted according to the I/O conversion rules for the individual + field types, plus decoration that indicates the composite structure. + The decoration consists of parentheses (( and )) + around the whole value, plus commas (,) between adjacent + items. Whitespace outside the parentheses is ignored, but within the + parentheses it is considered part of the field value, and might or might not be + significant depending on the input conversion rules for the field data type. + For example, in: +

'(  42)'

+ the whitespace will be ignored if the field type is integer, but not if + it is text. +

As shown previously, when writing a composite value you can write double + quotes around any individual field value. + You must do so if the field value would otherwise + confuse the composite-value parser. In particular, fields containing + parentheses, commas, double quotes, or backslashes must be double-quoted. + To put a double quote or backslash in a quoted composite field value, + precede it with a backslash. (Also, a pair of double quotes within a + double-quoted field value is taken to represent a double quote character, + analogously to the rules for single quotes in SQL literal strings.) + Alternatively, you can avoid quoting and use backslash-escaping to + protect all data characters + that would otherwise be taken as composite syntax. +

A completely empty field value (no characters at all between the commas + or parentheses) represents a NULL. To write a value that is an empty + string rather than NULL, write "". +

The composite output routine will put double quotes around field values + if they are empty strings or contain parentheses, commas, + double quotes, backslashes, or white space. (Doing so for white space + is not essential, but aids legibility.) Double quotes and backslashes + embedded in field values will be doubled. +

Note: Remember that what you write in an SQL command will first be interpreted + as a string literal, and then as a composite. This doubles the number of + backslashes you need (assuming escape string syntax is used). + For example, to insert a text field + containing a double quote and a backslash in a composite + value, you'd need to write: +

INSERT ... VALUES (E'("\\"\\\\")');

+ The string-literal processor removes one level of backslashes, so that + what arrives at the composite-value parser looks like + ("\"\\"). In turn, the string + fed to the text data type's input routine + becomes "\. (If we were working + with a data type whose input routine also treated backslashes specially, + bytea for example, we might need as many as eight backslashes + in the command to get one backslash into the stored composite field.) + Dollar quoting (see Section 4.1.2.4) can be + used to avoid the need to double backslashes. +

Tip: The ROW constructor syntax is usually easier to work with + than the composite-literal syntax when writing composite values in SQL + commands. + In ROW, individual field values are written the same way + they would be written when not members of a composite. +


PrevHomeNext
ArraysUpRange Types
\ No newline at end of file diff --git a/doc/src/sgml/html/rule-system.html b/doc/src/sgml/html/rule-system.html new file mode 100644 index 000000000..34e425aa3 --- /dev/null +++ b/doc/src/sgml/html/rule-system.html @@ -0,0 +1,248 @@ + +The PostgreSQL Rule System
PostgreSQL 9.2.2 Documentation
PrevUpChapter 44. Overview of PostgreSQL InternalsNext

44.4. The PostgreSQL Rule System

PostgreSQL supports a powerful + rule system for the specification + of views and ambiguous view updates. + Originally the PostgreSQL + rule system consisted of two implementations: + +

  • The first one worked using row level processing and was + implemented deep in the executor. The rule system was + called whenever an individual row had been accessed. This + implementation was removed in 1995 when the last official release + of the Berkeley Postgres project was + transformed into Postgres95. +

  • The second implementation of the rule system is a technique + called query rewriting. + The rewrite system is a module + that exists between the parser stage and the + planner/optimizer. This technique is still implemented. +

+

The query rewriter is discussed in some detail in + Chapter 37, so there is no need to cover it here. + We will only point out that both the input and the output of the + rewriter are query trees, that is, there is no change in the + representation or level of semantic detail in the trees. Rewriting + can be thought of as a form of macro expansion. +


PrevHomeNext
The Parser StageUpPlanner/Optimizer
\ No newline at end of file diff --git a/doc/src/sgml/html/rules-privileges.html b/doc/src/sgml/html/rules-privileges.html new file mode 100644 index 000000000..ec2f42ed1 --- /dev/null +++ b/doc/src/sgml/html/rules-privileges.html @@ -0,0 +1,463 @@ + +Rules and Privileges
PostgreSQL 9.2.2 Documentation
PrevUpChapter 37. The Rule SystemNext

37.4. Rules and Privileges

Due to rewriting of queries by the PostgreSQL + rule system, other tables/views than those used in the original + query get accessed. When update rules are used, this can include write access + to tables.

Rewrite rules don't have a separate owner. The owner of + a relation (table or view) is automatically the owner of the + rewrite rules that are defined for it. + The PostgreSQL rule system changes the + behavior of the default access control system. Relations that + are used due to rules get checked against the + privileges of the rule owner, not the user invoking the rule. + This means that a user only needs the required privileges + for the tables/views that he names explicitly in his queries.

For example: A user has a list of phone numbers where some of + them are private, the others are of interest for the secretary of the office. + He can construct the following: + +

CREATE TABLE phone_data (person text, phone text, private boolean);
+CREATE VIEW phone_number AS
+    SELECT person, CASE WHEN NOT private THEN phone END AS phone
+    FROM phone_data;
+GRANT SELECT ON phone_number TO secretary;

+ + Nobody except him (and the database superusers) can access the + phone_data table. But because of the GRANT, + the secretary can run a SELECT on the + phone_number view. The rule system will rewrite the + SELECT from phone_number into a + SELECT from phone_data. + Since the user is the owner of + phone_number and therefore the owner of the rule, the + read access to phone_data is now checked against his + privileges and the query is permitted. The check for accessing + phone_number is also performed, but this is done + against the invoking user, so nobody but the user and the + secretary can use it.

The privileges are checked rule by rule. So the secretary is for now the + only one who can see the public phone numbers. But the secretary can setup + another view and grant access to that to the public. Then, anyone + can see the phone_number data through the secretary's view. + What the secretary cannot do is to create a view that directly + accesses phone_data. (Actually he can, but it will not work since + every access will be denied during the permission checks.) + And as soon as the user will notice, that the secretary opened + his phone_number view, he can revoke his access. Immediately, any + access to the secretary's view would fail.

One might think that this rule-by-rule checking is a security + hole, but in fact it isn't. But if it did not work this way, the secretary + could set up a table with the same columns as phone_number and + copy the data to there once per day. Then it's his own data and + he can grant access to everyone he wants. A + GRANT command means, "I trust you". + If someone you trust does the thing above, it's time to + think it over and then use REVOKE.

Note that while views can be used to hide the contents of certain + columns using the technique shown above, they cannot be used to reliably + conceal the data in unseen rows unless the + security_barrier flag has been set. For example, + the following view is insecure: +

CREATE VIEW phone_number AS
+    SELECT person, phone FROM phone_data WHERE phone NOT LIKE '412%';

+ This view might seem secure, since the rule system will rewrite any + SELECT from phone_number into a + SELECT from phone_data and add the + qualification that only entries where phone does not begin + with 412 are wanted. But if the user can create his or her own functions, + it is not difficult to convince the planner to execute the user-defined + function prior to the NOT LIKE expression. + For example: +

CREATE FUNCTION tricky(text, text) RETURNS bool AS $$
+BEGIN
+    RAISE NOTICE '% => %', $1, $2;
+    RETURN true;
+END
+$$ LANGUAGE plpgsql COST 0.0000000000000000000001;
+
+SELECT * FROM phone_number WHERE tricky(person, phone);

+ Every person and phone number in the phone_data table will be + printed as a NOTICE, because the planner will choose to + execute the inexpensive tricky function before the + more expensive NOT LIKE. Even if the user is + prevented from defining new functions, built-in functions can be used in + similar attacks. (For example, most casting functions include their + input values in the error messages they produce.)

Similar considerations apply to update rules. In the examples of + the previous section, the owner of the tables in the example + database could grant the privileges SELECT, + INSERT, UPDATE, and DELETE on + the shoelace view to someone else, but only + SELECT on shoelace_log. The rule action to + write log entries will still be executed successfully, and that + other user could see the log entries. But he cannot create fake + entries, nor could he manipulate or remove existing ones. In this + case, there is no possibility of subverting the rules by convincing + the planner to alter the order of operations, because the only rule + which references shoelace_log is an unqualified + INSERT. This might not be true in more complex scenarios.

When it is necessary for a view to provide row-level security, the + security_barrier attribute should be applied to + the view. This prevents maliciously-chosen functions and operators from + being invoked on rows until after the view has done its work. For + example, if the view shown above had been created like this, it would + be secure: +

CREATE VIEW phone_number WITH (security_barrier) AS
+    SELECT person, phone FROM phone_data WHERE phone NOT LIKE '412%';

+ Views created with the security_barrier may perform + far worse than views created without this option. In general, there is + no way to avoid this: the fastest possible plan must be rejected + if it may compromise security. For this reason, this option is not + enabled by default.

The query planner has more flexibility when dealing with functions that + have no side effects. Such functions are referred to as LEAKPROOF, and + include many simple, commonly used operators, such as many equality + operators. The query planner can safely allow such functions to be evaluated + at any point in the query execution process, since invoking them on rows + invisible to the user will not leak any information about the unseen rows. + In contrast, a function that might throw an error depending on the values + received as arguments (such as one that throws an error in the event of + overflow or division by zero) are not leak-proof, and could provide + significant information about the unseen rows if applied before the security + view's row filters.

It is important to understand that even a view created with the + security_barrier option is intended to be secure only + in the limited sense that the contents of the invisible tuples will not be + passed to possibly-insecure functions. The user may well have other means + of making inferences about the unseen data; for example, they can see the + query plan using EXPLAIN, or measure the run time of + queries against the view. A malicious attacker might be able to infer + something about the amount of unseen data, or even gain some information + about the data distribution or most common values (since these things may + affect the run time of the plan; or even, since they are also reflected in + the optimizer statistics, the choice of plan). If these types of "covert + channel" attacks are of concern, it is probably unwise to grant any access + to the data at all.


PrevHomeNext
Rules on INSERT, UPDATE, and DELETEUpRules and Command Status
\ No newline at end of file diff --git a/doc/src/sgml/html/rules-status.html b/doc/src/sgml/html/rules-status.html new file mode 100644 index 000000000..6e09f8ef2 --- /dev/null +++ b/doc/src/sgml/html/rules-status.html @@ -0,0 +1,243 @@ + +Rules and Command Status
PostgreSQL 9.2.2 Documentation
PrevUpChapter 37. The Rule SystemNext

37.5. Rules and Command Status

The PostgreSQL server returns a command + status string, such as INSERT 149592 1, for each + command it receives. This is simple enough when there are no rules + involved, but what happens when the query is rewritten by rules?

Rules affect the command status as follows: + +

  • If there is no unconditional INSTEAD rule for the query, then + the originally given query will be executed, and its command + status will be returned as usual. (But note that if there were + any conditional INSTEAD rules, the negation of their qualifications + will have been added to the original query. This might reduce the + number of rows it processes, and if so the reported status will + be affected.) +

  • If there is any unconditional INSTEAD rule for the query, then + the original query will not be executed at all. In this case, + the server will return the command status for the last query + that was inserted by an INSTEAD rule (conditional or + unconditional) and is of the same command type + (INSERT, UPDATE, or + DELETE) as the original query. If no query + meeting those requirements is added by any rule, then the + returned command status shows the original query type and + zeroes for the row-count and OID fields. +

+ + (This system was established in PostgreSQL 7.3. + In versions before that, the command status might show different + results when rules exist.)

The programmer can ensure that any desired INSTEAD rule is the one + that sets the command status in the second case, by giving it the + alphabetically last rule name among the active rules, so that it + gets applied last.


PrevHomeNext
Rules and PrivilegesUpRules Versus Triggers
\ No newline at end of file diff --git a/doc/src/sgml/html/rules-triggers.html b/doc/src/sgml/html/rules-triggers.html new file mode 100644 index 000000000..175fea10b --- /dev/null +++ b/doc/src/sgml/html/rules-triggers.html @@ -0,0 +1,412 @@ + +Rules Versus Triggers
PostgreSQL 9.2.2 Documentation
PrevUpChapter 37. The Rule SystemNext

37.6. Rules Versus Triggers

Many things that can be done using triggers can also be + implemented using the PostgreSQL + rule system. One of the things that cannot be implemented by + rules are some kinds of constraints, especially foreign keys. It is possible + to place a qualified rule that rewrites a command to NOTHING + if the value of a column does not appear in another table. + But then the data is silently thrown away and that's + not a good idea. If checks for valid values are required, + and in the case of an invalid value an error message should + be generated, it must be done by a trigger.

In this chapter, we focused on using rules to update views. All of + the update rule examples in this chapter can also be implemented + using INSTEAD OF triggers on the views. Writing such + triggers is often easier than writing rules, particularly if complex + logic is required to perform the update.

For the things that can be implemented by both, which is best + depends on the usage of the database. + A trigger is fired once for each affected row. A rule modifies + the query or generates an additional query. So if many + rows are affected in one statement, a rule issuing one extra + command is likely to be faster than a trigger that is + called for every single row and must re-determine what to do + many times. However, the trigger approach is conceptually far + simpler than the rule approach, and is easier for novices to get right.

Here we show an example of how the choice of rules versus triggers + plays out in one situation. There are two tables: + +

CREATE TABLE computer (
+    hostname        text,    -- indexed
+    manufacturer    text     -- indexed
+);
+
+CREATE TABLE software (
+    software        text,    -- indexed
+    hostname        text     -- indexed
+);

+ + Both tables have many thousands of rows and the indexes on + hostname are unique. The rule or trigger should + implement a constraint that deletes rows from software + that reference a deleted computer. The trigger would use this command: + +

DELETE FROM software WHERE hostname = $1;

+ + Since the trigger is called for each individual row deleted from + computer, it can prepare and save the plan for this + command and pass the hostname value in the + parameter. The rule would be written as: + +

CREATE RULE computer_del AS ON DELETE TO computer
+    DO DELETE FROM software WHERE hostname = OLD.hostname;

+

Now we look at different types of deletes. In the case of a: + +

DELETE FROM computer WHERE hostname = 'mypc.local.net';

+ + the table computer is scanned by index (fast), and the + command issued by the trigger would also use an index scan (also fast). + The extra command from the rule would be: + +

DELETE FROM software WHERE computer.hostname = 'mypc.local.net'
+                       AND software.hostname = computer.hostname;

+ + Since there are appropriate indexes setup, the planner + will create a plan of + +

Nestloop
+  ->  Index Scan using comp_hostidx on computer
+  ->  Index Scan using soft_hostidx on software

+ + So there would be not that much difference in speed between + the trigger and the rule implementation. +

With the next delete we want to get rid of all the 2000 computers + where the hostname starts with + old. There are two possible commands to do that. One + is: + +

DELETE FROM computer WHERE hostname >= 'old'
+                       AND hostname <  'ole'

+ + The command added by the rule will be: + +

DELETE FROM software WHERE computer.hostname >= 'old' AND computer.hostname < 'ole'
+                       AND software.hostname = computer.hostname;

+ + with the plan + +

Hash Join
+  ->  Seq Scan on software
+  ->  Hash
+    ->  Index Scan using comp_hostidx on computer

+ + The other possible command is: + +

DELETE FROM computer WHERE hostname ~ '^old';

+ + which results in the following executing plan for the command + added by the rule: + +

Nestloop
+  ->  Index Scan using comp_hostidx on computer
+  ->  Index Scan using soft_hostidx on software

+ + This shows, that the planner does not realize that the + qualification for hostname in + computer could also be used for an index scan on + software when there are multiple qualification + expressions combined with AND, which is what it does + in the regular-expression version of the command. The trigger will + get invoked once for each of the 2000 old computers that have to be + deleted, and that will result in one index scan over + computer and 2000 index scans over + software. The rule implementation will do it with two + commands that use indexes. And it depends on the overall size of + the table software whether the rule will still be faster in the + sequential scan situation. 2000 command executions from the trigger over the SPI + manager take some time, even if all the index blocks will soon be in the cache.

The last command we look at is: + +

DELETE FROM computer WHERE manufacturer = 'bim';

+ + Again this could result in many rows to be deleted from + computer. So the trigger will again run many commands + through the executor. The command generated by the rule will be: + +

DELETE FROM software WHERE computer.manufacturer = 'bim'
+                       AND software.hostname = computer.hostname;

+ + The plan for that command will again be the nested loop over two + index scans, only using a different index on computer: + +

Nestloop
+  ->  Index Scan using comp_manufidx on computer
+  ->  Index Scan using soft_hostidx on software

+ + In any of these cases, the extra commands from the rule system + will be more or less independent from the number of affected rows + in a command.

The summary is, rules will only be significantly slower than + triggers if their actions result in large and badly qualified + joins, a situation where the planner fails.


PrevHomeNext
Rules and Command StatusUpProcedural Languages
\ No newline at end of file diff --git a/doc/src/sgml/html/rules-update.html b/doc/src/sgml/html/rules-update.html new file mode 100644 index 000000000..ac12ab111 --- /dev/null +++ b/doc/src/sgml/html/rules-update.html @@ -0,0 +1,1396 @@ + +Rules on INSERT, UPDATE, and DELETE
PostgreSQL 9.2.2 Documentation
PrevUpChapter 37. The Rule SystemNext

37.3. Rules on INSERT, UPDATE, and DELETE

Rules that are defined on INSERT, UPDATE, + and DELETE are significantly different from the view rules + described in the previous section. First, their CREATE + RULE command allows more: + +

  • They are allowed to have no action. +

  • They can have multiple actions. +

  • They can be INSTEAD or ALSO (the default). +

  • The pseudorelations NEW and OLD become useful. +

  • They can have rule qualifications. +

+ + Second, they don't modify the query tree in place. Instead they + create zero or more new query trees and can throw away the + original one.

37.3.1. How Update Rules Work

Keep the syntax: + +

CREATE [ OR REPLACE ] RULE name AS ON event
+    TO table [ WHERE condition ]
+    DO [ ALSO | INSTEAD ] { NOTHING | command | ( command ; command ... ) }

+ + in mind. + In the following, update rules means rules that are defined + on INSERT, UPDATE, or DELETE.

Update rules get applied by the rule system when the result + relation and the command type of a query tree are equal to the + object and event given in the CREATE RULE command. + For update rules, the rule system creates a list of query trees. + Initially the query-tree list is empty. + There can be zero (NOTHING key word), one, or multiple actions. + To simplify, we will look at a rule with one action. This rule + can have a qualification or not and it can be INSTEAD or + ALSO (the default).

What is a rule qualification? It is a restriction that tells + when the actions of the rule should be done and when not. This + qualification can only reference the pseudorelations NEW and/or OLD, + which basically represent the relation that was given as object (but with a + special meaning).

So we have three cases that produce the following query trees for + a one-action rule. + +

No qualification, with either ALSO or + INSTEAD

the query tree from the rule action with the original query + tree's qualification added +

Qualification given and ALSO

the query tree from the rule action with the rule + qualification and the original query tree's qualification + added +

Qualification given and INSTEAD

the query tree from the rule action with the rule + qualification and the original query tree's qualification; and + the original query tree with the negated rule qualification + added +

+ + Finally, if the rule is ALSO, the unchanged original query tree is + added to the list. Since only qualified INSTEAD rules already add the + original query tree, we end up with either one or two output query trees + for a rule with one action.

For ON INSERT rules, the original query (if not suppressed by INSTEAD) + is done before any actions added by rules. This allows the actions to + see the inserted row(s). But for ON UPDATE and ON + DELETE rules, the original query is done after the actions added by rules. + This ensures that the actions can see the to-be-updated or to-be-deleted + rows; otherwise, the actions might do nothing because they find no rows + matching their qualifications.

The query trees generated from rule actions are thrown into the + rewrite system again, and maybe more rules get applied resulting + in more or less query trees. + So a rule's actions must have either a different + command type or a different result relation than the rule itself is + on, otherwise this recursive process will end up in an infinite loop. + (Recursive expansion of a rule will be detected and reported as an + error.)

The query trees found in the actions of the + pg_rewrite system catalog are only + templates. Since they can reference the range-table entries for + NEW and OLD, some substitutions have to be made before they can be + used. For any reference to NEW, the target list of the original + query is searched for a corresponding entry. If found, that + entry's expression replaces the reference. Otherwise, NEW means the + same as OLD (for an UPDATE) or is replaced by + a null value (for an INSERT). Any reference to OLD is + replaced by a reference to the range-table entry that is the + result relation.

After the system is done applying update rules, it applies view rules to the + produced query tree(s). Views cannot insert new update actions so + there is no need to apply update rules to the output of view rewriting.

37.3.1.1. A First Rule Step by Step

Say we want to trace changes to the sl_avail column in the + shoelace_data relation. So we set up a log table + and a rule that conditionally writes a log entry when an + UPDATE is performed on + shoelace_data. + +

CREATE TABLE shoelace_log (
+    sl_name    text,          -- shoelace changed
+    sl_avail   integer,       -- new available value
+    log_who    text,          -- who did it
+    log_when   timestamp      -- when
+);
+
+CREATE RULE log_shoelace AS ON UPDATE TO shoelace_data
+    WHERE NEW.sl_avail <> OLD.sl_avail
+    DO INSERT INTO shoelace_log VALUES (
+                                    NEW.sl_name,
+                                    NEW.sl_avail,
+                                    current_user,
+                                    current_timestamp
+                                );

Now someone does: + +

UPDATE shoelace_data SET sl_avail = 6 WHERE sl_name = 'sl7';

+ + and we look at the log table: + +

SELECT * FROM shoelace_log;
+
+ sl_name | sl_avail | log_who | log_when                        
+---------+----------+---------+----------------------------------
+ sl7     |        6 | Al      | Tue Oct 20 16:14:45 1998 MET DST
+(1 row)

+

That's what we expected. What happened in the background is the following. + The parser created the query tree: + +

UPDATE shoelace_data SET sl_avail = 6
+  FROM shoelace_data shoelace_data
+ WHERE shoelace_data.sl_name = 'sl7';

+ + There is a rule log_shoelace that is ON UPDATE with the rule + qualification expression: + +

NEW.sl_avail <> OLD.sl_avail

+ + and the action: + +

INSERT INTO shoelace_log VALUES (
+       new.sl_name, new.sl_avail,
+       current_user, current_timestamp )
+  FROM shoelace_data new, shoelace_data old;

+ + (This looks a little strange since you cannot normally write + INSERT ... VALUES ... FROM. The FROM + clause here is just to indicate that there are range-table entries + in the query tree for new and old. + These are needed so that they can be referenced by variables in + the INSERT command's query tree.)

The rule is a qualified ALSO rule, so the rule system + has to return two query trees: the modified rule action and the original + query tree. In step 1, the range table of the original query is + incorporated into the rule's action query tree. This results in: + +

INSERT INTO shoelace_log VALUES (
+       new.sl_name, new.sl_avail,
+       current_user, current_timestamp )
+  FROM shoelace_data new, shoelace_data old,
+       shoelace_data shoelace_data;

+ + In step 2, the rule qualification is added to it, so the result set + is restricted to rows where sl_avail changes: + +

INSERT INTO shoelace_log VALUES (
+       new.sl_name, new.sl_avail,
+       current_user, current_timestamp )
+  FROM shoelace_data new, shoelace_data old,
+       shoelace_data shoelace_data
+ WHERE new.sl_avail <> old.sl_avail;

+ + (This looks even stranger, since INSERT ... VALUES doesn't have + a WHERE clause either, but the planner and executor will have no + difficulty with it. They need to support this same functionality + anyway for INSERT ... SELECT.) +

In step 3, the original query tree's qualification is added, + restricting the result set further to only the rows that would have been touched + by the original query: + +

INSERT INTO shoelace_log VALUES (
+       new.sl_name, new.sl_avail,
+       current_user, current_timestamp )
+  FROM shoelace_data new, shoelace_data old,
+       shoelace_data shoelace_data
+ WHERE new.sl_avail <> old.sl_avail
+   AND shoelace_data.sl_name = 'sl7';

+

Step 4 replaces references to NEW by the target list entries from the + original query tree or by the matching variable references + from the result relation: + +

INSERT INTO shoelace_log VALUES (
+       shoelace_data.sl_name, 6,
+       current_user, current_timestamp )
+  FROM shoelace_data new, shoelace_data old,
+       shoelace_data shoelace_data
+ WHERE 6 <> old.sl_avail
+   AND shoelace_data.sl_name = 'sl7';

+ +

Step 5 changes OLD references into result relation references: + +

INSERT INTO shoelace_log VALUES (
+       shoelace_data.sl_name, 6,
+       current_user, current_timestamp )
+  FROM shoelace_data new, shoelace_data old,
+       shoelace_data shoelace_data
+ WHERE 6 <> shoelace_data.sl_avail
+   AND shoelace_data.sl_name = 'sl7';

+

That's it. Since the rule is ALSO, we also output the + original query tree. In short, the output from the rule system + is a list of two query trees that correspond to these statements: + +

INSERT INTO shoelace_log VALUES (
+       shoelace_data.sl_name, 6,
+       current_user, current_timestamp )
+  FROM shoelace_data
+ WHERE 6 <> shoelace_data.sl_avail
+   AND shoelace_data.sl_name = 'sl7';
+
+UPDATE shoelace_data SET sl_avail = 6
+ WHERE sl_name = 'sl7';

+ + These are executed in this order, and that is exactly what + the rule was meant to do. +

The substitutions and the added qualifications + ensure that, if the original query would be, say: + +

UPDATE shoelace_data SET sl_color = 'green'
+ WHERE sl_name = 'sl7';

+ + no log entry would get written. In that case, the original query + tree does not contain a target list entry for + sl_avail, so NEW.sl_avail will get + replaced by shoelace_data.sl_avail. Thus, the extra + command generated by the rule is: + +

INSERT INTO shoelace_log VALUES (
+       shoelace_data.sl_name, shoelace_data.sl_avail,
+       current_user, current_timestamp )
+  FROM shoelace_data
+ WHERE shoelace_data.sl_avail <> shoelace_data.sl_avail
+   AND shoelace_data.sl_name = 'sl7';

+ + and that qualification will never be true. +

It will also work if the original query modifies multiple rows. So + if someone issued the command: + +

UPDATE shoelace_data SET sl_avail = 0
+ WHERE sl_color = 'black';

+ + four rows in fact get updated (sl1, sl2, sl3, and sl4). + But sl3 already has sl_avail = 0. In this case, the original + query trees qualification is different and that results + in the extra query tree: + +

INSERT INTO shoelace_log
+SELECT shoelace_data.sl_name, 0,
+       current_user, current_timestamp
+  FROM shoelace_data
+ WHERE 0 <> shoelace_data.sl_avail
+   AND shoelace_data.sl_color = 'black';

+ + being generated by the rule. This query tree will surely insert + three new log entries. And that's absolutely correct.

Here we can see why it is important that the original query tree + is executed last. If the UPDATE had been + executed first, all the rows would have already been set to zero, so the + logging INSERT would not find any row where + 0 <> shoelace_data.sl_avail.

37.3.2. Cooperation with Views

A simple way to protect view relations from the mentioned + possibility that someone can try to run INSERT, + UPDATE, or DELETE on them is + to let those query trees get thrown away. So we could create the rules: + +

CREATE RULE shoe_ins_protect AS ON INSERT TO shoe
+    DO INSTEAD NOTHING;
+CREATE RULE shoe_upd_protect AS ON UPDATE TO shoe
+    DO INSTEAD NOTHING;
+CREATE RULE shoe_del_protect AS ON DELETE TO shoe
+    DO INSTEAD NOTHING;

+ + If someone now tries to do any of these operations on the view + relation shoe, the rule system will + apply these rules. Since the rules have + no actions and are INSTEAD, the resulting list of + query trees will be empty and the whole query will become + nothing because there is nothing left to be optimized or + executed after the rule system is done with it.

A more sophisticated way to use the rule system is to + create rules that rewrite the query tree into one that + does the right operation on the real tables. To do that + on the shoelace view, we create + the following rules: + +

CREATE RULE shoelace_ins AS ON INSERT TO shoelace
+    DO INSTEAD
+    INSERT INTO shoelace_data VALUES (
+           NEW.sl_name,
+           NEW.sl_avail,
+           NEW.sl_color,
+           NEW.sl_len,
+           NEW.sl_unit
+    );
+
+CREATE RULE shoelace_upd AS ON UPDATE TO shoelace
+    DO INSTEAD
+    UPDATE shoelace_data
+       SET sl_name = NEW.sl_name,
+           sl_avail = NEW.sl_avail,
+           sl_color = NEW.sl_color,
+           sl_len = NEW.sl_len,
+           sl_unit = NEW.sl_unit
+     WHERE sl_name = OLD.sl_name;
+
+CREATE RULE shoelace_del AS ON DELETE TO shoelace
+    DO INSTEAD
+    DELETE FROM shoelace_data
+     WHERE sl_name = OLD.sl_name;

+

If you want to support RETURNING queries on the view, + you need to make the rules include RETURNING clauses that + compute the view rows. This is usually pretty trivial for views on a + single table, but it's a bit tedious for join views such as + shoelace. An example for the insert case is: + +

CREATE RULE shoelace_ins AS ON INSERT TO shoelace
+    DO INSTEAD
+    INSERT INTO shoelace_data VALUES (
+           NEW.sl_name,
+           NEW.sl_avail,
+           NEW.sl_color,
+           NEW.sl_len,
+           NEW.sl_unit
+    )
+    RETURNING
+           shoelace_data.*,
+           (SELECT shoelace_data.sl_len * u.un_fact
+            FROM unit u WHERE shoelace_data.sl_unit = u.un_name);

+ + Note that this one rule supports both INSERT and + INSERT RETURNING queries on the view — the + RETURNING clause is simply ignored for INSERT. +

Now assume that once in a while, a pack of shoelaces arrives at + the shop and a big parts list along with it. But you don't want + to manually update the shoelace view every + time. Instead we setup two little tables: one where you can + insert the items from the part list, and one with a special + trick. The creation commands for these are: + +

CREATE TABLE shoelace_arrive (
+    arr_name    text,
+    arr_quant   integer
+);
+
+CREATE TABLE shoelace_ok (
+    ok_name     text,
+    ok_quant    integer
+);
+
+CREATE RULE shoelace_ok_ins AS ON INSERT TO shoelace_ok
+    DO INSTEAD
+    UPDATE shoelace
+       SET sl_avail = sl_avail + NEW.ok_quant
+     WHERE sl_name = NEW.ok_name;

+ + Now you can fill the table shoelace_arrive with + the data from the parts list: + +

SELECT * FROM shoelace_arrive;
+
+ arr_name | arr_quant
+----------+-----------
+ sl3      |        10
+ sl6      |        20
+ sl8      |        20
+(3 rows)

+ + Take a quick look at the current data: + +

SELECT * FROM shoelace;
+
+ sl_name  | sl_avail | sl_color | sl_len | sl_unit | sl_len_cm
+----------+----------+----------+--------+---------+-----------
+ sl1      |        5 | black    |     80 | cm      |        80
+ sl2      |        6 | black    |    100 | cm      |       100
+ sl7      |        6 | brown    |     60 | cm      |        60
+ sl3      |        0 | black    |     35 | inch    |      88.9
+ sl4      |        8 | black    |     40 | inch    |     101.6
+ sl8      |        1 | brown    |     40 | inch    |     101.6
+ sl5      |        4 | brown    |      1 | m       |       100
+ sl6      |        0 | brown    |    0.9 | m       |        90
+(8 rows)

+ + Now move the arrived shoelaces in: + +

INSERT INTO shoelace_ok SELECT * FROM shoelace_arrive;

+ + and check the results: + +

SELECT * FROM shoelace ORDER BY sl_name;
+
+ sl_name  | sl_avail | sl_color | sl_len | sl_unit | sl_len_cm
+----------+----------+----------+--------+---------+-----------
+ sl1      |        5 | black    |     80 | cm      |        80
+ sl2      |        6 | black    |    100 | cm      |       100
+ sl7      |        6 | brown    |     60 | cm      |        60
+ sl4      |        8 | black    |     40 | inch    |     101.6
+ sl3      |       10 | black    |     35 | inch    |      88.9
+ sl8      |       21 | brown    |     40 | inch    |     101.6
+ sl5      |        4 | brown    |      1 | m       |       100
+ sl6      |       20 | brown    |    0.9 | m       |        90
+(8 rows)
+
+SELECT * FROM shoelace_log;
+
+ sl_name | sl_avail | log_who| log_when                        
+---------+----------+--------+----------------------------------
+ sl7     |        6 | Al     | Tue Oct 20 19:14:45 1998 MET DST
+ sl3     |       10 | Al     | Tue Oct 20 19:25:16 1998 MET DST
+ sl6     |       20 | Al     | Tue Oct 20 19:25:16 1998 MET DST
+ sl8     |       21 | Al     | Tue Oct 20 19:25:16 1998 MET DST
+(4 rows)

+

It's a long way from the one INSERT ... SELECT + to these results. And the description of the query-tree + transformation will be the last in this chapter. First, there is + the parser's output: + +

INSERT INTO shoelace_ok
+SELECT shoelace_arrive.arr_name, shoelace_arrive.arr_quant
+  FROM shoelace_arrive shoelace_arrive, shoelace_ok shoelace_ok;

+ + Now the first rule shoelace_ok_ins is applied and turns this + into: + +

UPDATE shoelace
+   SET sl_avail = shoelace.sl_avail + shoelace_arrive.arr_quant
+  FROM shoelace_arrive shoelace_arrive, shoelace_ok shoelace_ok,
+       shoelace_ok old, shoelace_ok new,
+       shoelace shoelace
+ WHERE shoelace.sl_name = shoelace_arrive.arr_name;

+ + and throws away the original INSERT on + shoelace_ok. This rewritten query is passed to + the rule system again, and the second applied rule + shoelace_upd produces: + +

UPDATE shoelace_data
+   SET sl_name = shoelace.sl_name,
+       sl_avail = shoelace.sl_avail + shoelace_arrive.arr_quant,
+       sl_color = shoelace.sl_color,
+       sl_len = shoelace.sl_len,
+       sl_unit = shoelace.sl_unit
+  FROM shoelace_arrive shoelace_arrive, shoelace_ok shoelace_ok,
+       shoelace_ok old, shoelace_ok new,
+       shoelace shoelace, shoelace old,
+       shoelace new, shoelace_data shoelace_data
+ WHERE shoelace.sl_name = shoelace_arrive.arr_name
+   AND shoelace_data.sl_name = shoelace.sl_name;

+ + Again it's an INSTEAD rule and the previous query tree is trashed. + Note that this query still uses the view shoelace. + But the rule system isn't finished with this step, so it continues + and applies the _RETURN rule on it, and we get: + +

UPDATE shoelace_data
+   SET sl_name = s.sl_name,
+       sl_avail = s.sl_avail + shoelace_arrive.arr_quant,
+       sl_color = s.sl_color,
+       sl_len = s.sl_len,
+       sl_unit = s.sl_unit
+  FROM shoelace_arrive shoelace_arrive, shoelace_ok shoelace_ok,
+       shoelace_ok old, shoelace_ok new,
+       shoelace shoelace, shoelace old,
+       shoelace new, shoelace_data shoelace_data,
+       shoelace old, shoelace new,
+       shoelace_data s, unit u
+ WHERE s.sl_name = shoelace_arrive.arr_name
+   AND shoelace_data.sl_name = s.sl_name;

+ + Finally, the rule log_shoelace gets applied, + producing the extra query tree: + +

INSERT INTO shoelace_log
+SELECT s.sl_name,
+       s.sl_avail + shoelace_arrive.arr_quant,
+       current_user,
+       current_timestamp
+  FROM shoelace_arrive shoelace_arrive, shoelace_ok shoelace_ok,
+       shoelace_ok old, shoelace_ok new,
+       shoelace shoelace, shoelace old,
+       shoelace new, shoelace_data shoelace_data,
+       shoelace old, shoelace new,
+       shoelace_data s, unit u,
+       shoelace_data old, shoelace_data new
+       shoelace_log shoelace_log
+ WHERE s.sl_name = shoelace_arrive.arr_name
+   AND shoelace_data.sl_name = s.sl_name
+   AND (s.sl_avail + shoelace_arrive.arr_quant) <> s.sl_avail;

+ + After that the rule system runs out of rules and returns the + generated query trees. +

So we end up with two final query trees that are equivalent to the + SQL statements: + +

INSERT INTO shoelace_log
+SELECT s.sl_name,
+       s.sl_avail + shoelace_arrive.arr_quant,
+       current_user,
+       current_timestamp
+  FROM shoelace_arrive shoelace_arrive, shoelace_data shoelace_data,
+       shoelace_data s
+ WHERE s.sl_name = shoelace_arrive.arr_name
+   AND shoelace_data.sl_name = s.sl_name
+   AND s.sl_avail + shoelace_arrive.arr_quant <> s.sl_avail;
+
+UPDATE shoelace_data
+   SET sl_avail = shoelace_data.sl_avail + shoelace_arrive.arr_quant
+  FROM shoelace_arrive shoelace_arrive,
+       shoelace_data shoelace_data,
+       shoelace_data s
+ WHERE s.sl_name = shoelace_arrive.sl_name
+   AND shoelace_data.sl_name = s.sl_name;

+ + The result is that data coming from one relation inserted into another, + changed into updates on a third, changed into updating + a fourth plus logging that final update in a fifth + gets reduced into two queries.

There is a little detail that's a bit ugly. Looking at the two + queries, it turns out that the shoelace_data + relation appears twice in the range table where it could + definitely be reduced to one. The planner does not handle it and + so the execution plan for the rule systems output of the + INSERT will be + +

Nested Loop
+  ->  Merge Join
+        ->  Seq Scan
+              ->  Sort
+                    ->  Seq Scan on s
+        ->  Seq Scan
+              ->  Sort
+                    ->  Seq Scan on shoelace_arrive
+  ->  Seq Scan on shoelace_data

+ + while omitting the extra range table entry would result in a + +

Merge Join
+  ->  Seq Scan
+        ->  Sort
+              ->  Seq Scan on s
+  ->  Seq Scan
+        ->  Sort
+              ->  Seq Scan on shoelace_arrive

+ + which produces exactly the same entries in the log table. Thus, + the rule system caused one extra scan on the table + shoelace_data that is absolutely not + necessary. And the same redundant scan is done once more in the + UPDATE. But it was a really hard job to make + that all possible at all.

Now we make a final demonstration of the + PostgreSQL rule system and its power. + Say you add some shoelaces with extraordinary colors to your + database: + +

INSERT INTO shoelace VALUES ('sl9', 0, 'pink', 35.0, 'inch', 0.0);
+INSERT INTO shoelace VALUES ('sl10', 1000, 'magenta', 40.0, 'inch', 0.0);

+ + We would like to make a view to check which + shoelace entries do not fit any shoe in color. + The view for this is: + +

CREATE VIEW shoelace_mismatch AS
+    SELECT * FROM shoelace WHERE NOT EXISTS
+        (SELECT shoename FROM shoe WHERE slcolor = sl_color);

+ + Its output is: + +

SELECT * FROM shoelace_mismatch;
+
+ sl_name | sl_avail | sl_color | sl_len | sl_unit | sl_len_cm
+---------+----------+----------+--------+---------+-----------
+ sl9     |        0 | pink     |     35 | inch    |      88.9
+ sl10    |     1000 | magenta  |     40 | inch    |     101.6

+

Now we want to set it up so that mismatching shoelaces that are + not in stock are deleted from the database. + To make it a little harder for PostgreSQL, + we don't delete it directly. Instead we create one more view: + +

CREATE VIEW shoelace_can_delete AS
+    SELECT * FROM shoelace_mismatch WHERE sl_avail = 0;

+ + and do it this way: + +

DELETE FROM shoelace WHERE EXISTS
+    (SELECT * FROM shoelace_can_delete
+             WHERE sl_name = shoelace.sl_name);

+ + Voilà: + +

SELECT * FROM shoelace;
+
+ sl_name | sl_avail | sl_color | sl_len | sl_unit | sl_len_cm
+---------+----------+----------+--------+---------+-----------
+ sl1     |        5 | black    |     80 | cm      |        80
+ sl2     |        6 | black    |    100 | cm      |       100
+ sl7     |        6 | brown    |     60 | cm      |        60
+ sl4     |        8 | black    |     40 | inch    |     101.6
+ sl3     |       10 | black    |     35 | inch    |      88.9
+ sl8     |       21 | brown    |     40 | inch    |     101.6
+ sl10    |     1000 | magenta  |     40 | inch    |     101.6
+ sl5     |        4 | brown    |      1 | m       |       100
+ sl6     |       20 | brown    |    0.9 | m       |        90
+(9 rows)

+

A DELETE on a view, with a subquery qualification that + in total uses 4 nesting/joined views, where one of them + itself has a subquery qualification containing a view + and where calculated view columns are used, + gets rewritten into + one single query tree that deletes the requested data + from a real table.

There are probably only a few situations out in the real world + where such a construct is necessary. But it makes you feel + comfortable that it works.


PrevHomeNext
Views and the Rule SystemUpRules and Privileges
\ No newline at end of file diff --git a/doc/src/sgml/html/rules-views.html b/doc/src/sgml/html/rules-views.html new file mode 100644 index 000000000..86dd4b327 --- /dev/null +++ b/doc/src/sgml/html/rules-views.html @@ -0,0 +1,1088 @@ + +Views and the Rule System
PostgreSQL 9.2.2 Documentation
PrevUpChapter 37. The Rule SystemNext

37.2. Views and the Rule System

Views in PostgreSQL are implemented + using the rule system. In fact, there is essentially no difference + between: + +

CREATE VIEW myview AS SELECT * FROM mytab;

+ + compared against the two commands: + +

CREATE TABLE myview (same column list as mytab);
+CREATE RULE "_RETURN" AS ON SELECT TO myview DO INSTEAD
+    SELECT * FROM mytab;

+ + because this is exactly what the CREATE VIEW + command does internally. This has some side effects. One of them + is that the information about a view in the + PostgreSQL system catalogs is exactly + the same as it is for a table. So for the parser, there is + absolutely no difference between a table and a view. They are the + same thing: relations.

37.2.1. How SELECT Rules Work

Rules ON SELECT are applied to all queries as the last step, even + if the command given is an INSERT, + UPDATE or DELETE. And they + have different semantics from rules on the other command types in that they modify the + query tree in place instead of creating a new one. So + SELECT rules are described first.

Currently, there can be only one action in an ON SELECT rule, and it must + be an unconditional SELECT action that is INSTEAD. This restriction was + required to make rules safe enough to open them for ordinary users, and + it restricts ON SELECT rules to act like views.

The examples for this chapter are two join views that do some + calculations and some more views using them in turn. One of the + two first views is customized later by adding rules for + INSERT, UPDATE, and + DELETE operations so that the final result will + be a view that behaves like a real table with some magic + functionality. This is not such a simple example to start from and + this makes things harder to get into. But it's better to have one + example that covers all the points discussed step by step rather + than having many different ones that might mix up in mind.

For the example, we need a little min function that +returns the lower of 2 integer values. We create that as: + +

CREATE FUNCTION min(integer, integer) RETURNS integer AS $$
+    SELECT CASE WHEN $1 < $2 THEN $1 ELSE $2 END
+$$ LANGUAGE SQL STRICT;

The real tables we need in the first two rule system descriptions + are these: + +

CREATE TABLE shoe_data (
+    shoename   text,          -- primary key
+    sh_avail   integer,       -- available number of pairs
+    slcolor    text,          -- preferred shoelace color
+    slminlen   real,          -- minimum shoelace length
+    slmaxlen   real,          -- maximum shoelace length
+    slunit     text           -- length unit
+);
+
+CREATE TABLE shoelace_data (
+    sl_name    text,          -- primary key
+    sl_avail   integer,       -- available number of pairs
+    sl_color   text,          -- shoelace color
+    sl_len     real,          -- shoelace length
+    sl_unit    text           -- length unit
+);
+
+CREATE TABLE unit (
+    un_name    text,          -- primary key
+    un_fact    real           -- factor to transform to cm
+);

+ + As you can see, they represent shoe-store data.

The views are created as: + +

CREATE VIEW shoe AS
+    SELECT sh.shoename,
+           sh.sh_avail,
+           sh.slcolor,
+           sh.slminlen,
+           sh.slminlen * un.un_fact AS slminlen_cm,
+           sh.slmaxlen,
+           sh.slmaxlen * un.un_fact AS slmaxlen_cm,
+           sh.slunit
+      FROM shoe_data sh, unit un
+     WHERE sh.slunit = un.un_name;
+
+CREATE VIEW shoelace AS
+    SELECT s.sl_name,
+           s.sl_avail,
+           s.sl_color,
+           s.sl_len,
+           s.sl_unit,
+           s.sl_len * u.un_fact AS sl_len_cm
+      FROM shoelace_data s, unit u
+     WHERE s.sl_unit = u.un_name;
+
+CREATE VIEW shoe_ready AS
+    SELECT rsh.shoename,
+           rsh.sh_avail,
+           rsl.sl_name,
+           rsl.sl_avail,
+           min(rsh.sh_avail, rsl.sl_avail) AS total_avail
+      FROM shoe rsh, shoelace rsl
+     WHERE rsl.sl_color = rsh.slcolor
+       AND rsl.sl_len_cm >= rsh.slminlen_cm
+       AND rsl.sl_len_cm <= rsh.slmaxlen_cm;

+ + The CREATE VIEW command for the + shoelace view (which is the simplest one we + have) will create a relation shoelace and an entry in + pg_rewrite that tells that there is a + rewrite rule that must be applied whenever the relation shoelace + is referenced in a query's range table. The rule has no rule + qualification (discussed later, with the non-SELECT rules, since + SELECT rules currently cannot have them) and it is INSTEAD. Note + that rule qualifications are not the same as query qualifications. + The action of our rule has a query qualification. + The action of the rule is one query tree that is a copy of the + SELECT statement in the view creation command.

Note: The two extra range + table entries for NEW and OLD that you can see in + the pg_rewrite entry aren't of interest + for SELECT rules. +

Now we populate unit, shoe_data + and shoelace_data and run a simple query on a view: + +

INSERT INTO unit VALUES ('cm', 1.0);
+INSERT INTO unit VALUES ('m', 100.0);
+INSERT INTO unit VALUES ('inch', 2.54);
+
+INSERT INTO shoe_data VALUES ('sh1', 2, 'black', 70.0, 90.0, 'cm');
+INSERT INTO shoe_data VALUES ('sh2', 0, 'black', 30.0, 40.0, 'inch');
+INSERT INTO shoe_data VALUES ('sh3', 4, 'brown', 50.0, 65.0, 'cm');
+INSERT INTO shoe_data VALUES ('sh4', 3, 'brown', 40.0, 50.0, 'inch');
+
+INSERT INTO shoelace_data VALUES ('sl1', 5, 'black', 80.0, 'cm');
+INSERT INTO shoelace_data VALUES ('sl2', 6, 'black', 100.0, 'cm');
+INSERT INTO shoelace_data VALUES ('sl3', 0, 'black', 35.0 , 'inch');
+INSERT INTO shoelace_data VALUES ('sl4', 8, 'black', 40.0 , 'inch');
+INSERT INTO shoelace_data VALUES ('sl5', 4, 'brown', 1.0 , 'm');
+INSERT INTO shoelace_data VALUES ('sl6', 0, 'brown', 0.9 , 'm');
+INSERT INTO shoelace_data VALUES ('sl7', 7, 'brown', 60 , 'cm');
+INSERT INTO shoelace_data VALUES ('sl8', 1, 'brown', 40 , 'inch');
+
+SELECT * FROM shoelace;
+
+ sl_name   | sl_avail | sl_color | sl_len | sl_unit | sl_len_cm
+-----------+----------+----------+--------+---------+-----------
+ sl1       |        5 | black    |     80 | cm      |        80
+ sl2       |        6 | black    |    100 | cm      |       100
+ sl7       |        7 | brown    |     60 | cm      |        60
+ sl3       |        0 | black    |     35 | inch    |      88.9
+ sl4       |        8 | black    |     40 | inch    |     101.6
+ sl8       |        1 | brown    |     40 | inch    |     101.6
+ sl5       |        4 | brown    |      1 | m       |       100
+ sl6       |        0 | brown    |    0.9 | m       |        90
+(8 rows)

+

This is the simplest SELECT you can do on our + views, so we take this opportunity to explain the basics of view + rules. The SELECT * FROM shoelace was + interpreted by the parser and produced the query tree: + +

SELECT shoelace.sl_name, shoelace.sl_avail,
+       shoelace.sl_color, shoelace.sl_len,
+       shoelace.sl_unit, shoelace.sl_len_cm
+  FROM shoelace shoelace;

+ + and this is given to the rule system. The rule system walks through the + range table and checks if there are rules + for any relation. When processing the range table entry for + shoelace (the only one up to now) it finds the + _RETURN rule with the query tree: + +

SELECT s.sl_name, s.sl_avail,
+       s.sl_color, s.sl_len, s.sl_unit,
+       s.sl_len * u.un_fact AS sl_len_cm
+  FROM shoelace old, shoelace new,
+       shoelace_data s, unit u
+ WHERE s.sl_unit = u.un_name;

To expand the view, the rewriter simply creates a subquery range-table + entry containing the rule's action query tree, and substitutes this + range table entry for the original one that referenced the view. The + resulting rewritten query tree is almost the same as if you had typed: + +

SELECT shoelace.sl_name, shoelace.sl_avail,
+       shoelace.sl_color, shoelace.sl_len,
+       shoelace.sl_unit, shoelace.sl_len_cm
+  FROM (SELECT s.sl_name,
+               s.sl_avail,
+               s.sl_color,
+               s.sl_len,
+               s.sl_unit,
+               s.sl_len * u.un_fact AS sl_len_cm
+          FROM shoelace_data s, unit u
+         WHERE s.sl_unit = u.un_name) shoelace;

+ + There is one difference however: the subquery's range table has two + extra entries shoelace old and shoelace new. These entries don't + participate directly in the query, since they aren't referenced by + the subquery's join tree or target list. The rewriter uses them + to store the access privilege check information that was originally present + in the range-table entry that referenced the view. In this way, the + executor will still check that the user has proper privileges to access + the view, even though there's no direct use of the view in the rewritten + query.

That was the first rule applied. The rule system will continue checking + the remaining range-table entries in the top query (in this example there + are no more), and it will recursively check the range-table entries in + the added subquery to see if any of them reference views. (But it + won't expand old or new — otherwise we'd have infinite recursion!) + In this example, there are no rewrite rules for shoelace_data or unit, + so rewriting is complete and the above is the final result given to + the planner.

Now we want to write a query that finds out for which shoes currently in the store + we have the matching shoelaces (color and length) and where the + total number of exactly matching pairs is greater or equal to two. + +

SELECT * FROM shoe_ready WHERE total_avail >= 2;
+
+ shoename | sh_avail | sl_name | sl_avail | total_avail
+----------+----------+---------+----------+-------------
+ sh1      |        2 | sl1     |        5 |           2
+ sh3      |        4 | sl7     |        7 |           4
+(2 rows)

The output of the parser this time is the query tree: + +

SELECT shoe_ready.shoename, shoe_ready.sh_avail,
+       shoe_ready.sl_name, shoe_ready.sl_avail,
+       shoe_ready.total_avail
+  FROM shoe_ready shoe_ready
+ WHERE shoe_ready.total_avail >= 2;

+ + The first rule applied will be the one for the + shoe_ready view and it results in the + query tree: + +

SELECT shoe_ready.shoename, shoe_ready.sh_avail,
+       shoe_ready.sl_name, shoe_ready.sl_avail,
+       shoe_ready.total_avail
+  FROM (SELECT rsh.shoename,
+               rsh.sh_avail,
+               rsl.sl_name,
+               rsl.sl_avail,
+               min(rsh.sh_avail, rsl.sl_avail) AS total_avail
+          FROM shoe rsh, shoelace rsl
+         WHERE rsl.sl_color = rsh.slcolor
+           AND rsl.sl_len_cm >= rsh.slminlen_cm
+           AND rsl.sl_len_cm <= rsh.slmaxlen_cm) shoe_ready
+ WHERE shoe_ready.total_avail >= 2;

+ + Similarly, the rules for shoe and + shoelace are substituted into the range table of + the subquery, leading to a three-level final query tree: + +

SELECT shoe_ready.shoename, shoe_ready.sh_avail,
+       shoe_ready.sl_name, shoe_ready.sl_avail,
+       shoe_ready.total_avail
+  FROM (SELECT rsh.shoename,
+               rsh.sh_avail,
+               rsl.sl_name,
+               rsl.sl_avail,
+               min(rsh.sh_avail, rsl.sl_avail) AS total_avail
+          FROM (SELECT sh.shoename,
+                       sh.sh_avail,
+                       sh.slcolor,
+                       sh.slminlen,
+                       sh.slminlen * un.un_fact AS slminlen_cm,
+                       sh.slmaxlen,
+                       sh.slmaxlen * un.un_fact AS slmaxlen_cm,
+                       sh.slunit
+                  FROM shoe_data sh, unit un
+                 WHERE sh.slunit = un.un_name) rsh,
+               (SELECT s.sl_name,
+                       s.sl_avail,
+                       s.sl_color,
+                       s.sl_len,
+                       s.sl_unit,
+                       s.sl_len * u.un_fact AS sl_len_cm
+                  FROM shoelace_data s, unit u
+                 WHERE s.sl_unit = u.un_name) rsl
+         WHERE rsl.sl_color = rsh.slcolor
+           AND rsl.sl_len_cm >= rsh.slminlen_cm
+           AND rsl.sl_len_cm <= rsh.slmaxlen_cm) shoe_ready
+ WHERE shoe_ready.total_avail > 2;

+

It turns out that the planner will collapse this tree into a + two-level query tree: the bottommost SELECT + commands will be "pulled up" into the middle + SELECT since there's no need to process them + separately. But the middle SELECT will remain + separate from the top, because it contains aggregate functions. + If we pulled those up it would change the behavior of the topmost + SELECT, which we don't want. However, + collapsing the query tree is an optimization that the rewrite + system doesn't have to concern itself with. +

37.2.2. View Rules in Non-SELECT Statements

Two details of the query tree aren't touched in the description of + view rules above. These are the command type and the result relation. + In fact, the command type is not needed by view rules, but the result + relation may affect the way in which the query rewriter works, because + special care needs to be taken if the result relation is a view.

There are only a few differences between a query tree for a + SELECT and one for any other + command. Obviously, they have a different command type and for a + command other than a SELECT, the result + relation points to the range-table entry where the result should + go. Everything else is absolutely the same. So having two tables + t1 and t2 with columns a and + b, the query trees for the two statements: + +

SELECT t2.b FROM t1, t2 WHERE t1.a = t2.a;
+
+UPDATE t1 SET b = t2.b FROM t2 WHERE t1.a = t2.a;

+ + are nearly identical. In particular: + +

  • The range tables contain entries for the tables t1 and t2. +

  • The target lists contain one variable that points to column + b of the range table entry for table t2. +

  • The qualification expressions compare the columns a of both + range-table entries for equality. +

  • The join trees show a simple join between t1 and t2. +

+

The consequence is, that both query trees result in similar + execution plans: They are both joins over the two tables. For the + UPDATE the missing columns from t1 are added to + the target list by the planner and the final query tree will read + as: + +

UPDATE t1 SET a = t1.a, b = t2.b FROM t2 WHERE t1.a = t2.a;

+ + and thus the executor run over the join will produce exactly the + same result set as: + +

SELECT t1.a, t2.b FROM t1, t2 WHERE t1.a = t2.a;

+ + But there is a little problem in + UPDATE: the part of the executor plan that does + the join does not care what the results from the join are + meant for. It just produces a result set of rows. The fact that + one is a SELECT command and the other is an + UPDATE is handled higher up in the executor, where + it knows that this is an UPDATE, and it knows that + this result should go into table t1. But which of the rows + that are there has to be replaced by the new row?

To resolve this problem, another entry is added to the target list + in UPDATE (and also in + DELETE) statements: the current tuple ID + (CTID). + This is a system column containing the + file block number and position in the block for the row. Knowing + the table, the CTID can be used to retrieve the + original row of t1 to be updated. After adding the + CTID to the target list, the query actually looks like: + +

SELECT t1.a, t2.b, t1.ctid FROM t1, t2 WHERE t1.a = t2.a;

+ + Now another detail of PostgreSQL enters + the stage. Old table rows aren't overwritten, and this + is why ROLLBACK is fast. In an UPDATE, + the new result row is inserted into the table (after stripping the + CTID) and in the row header of the old row, which the + CTID pointed to, the cmax and + xmax entries are set to the current command counter + and current transaction ID. Thus the old row is hidden, and after + the transaction commits the vacuum cleaner can eventually remove + the dead row.

Knowing all that, we can simply apply view rules in absolutely + the same way to any command. There is no difference.

37.2.3. The Power of Views in PostgreSQL

The above demonstrates how the rule system incorporates view + definitions into the original query tree. In the second example, a + simple SELECT from one view created a final + query tree that is a join of 4 tables (unit was used twice with + different names).

The benefit of implementing views with the rule system is, + that the planner has all + the information about which tables have to be scanned plus the + relationships between these tables plus the restrictive + qualifications from the views plus the qualifications from + the original query + in one single query tree. And this is still the situation + when the original query is already a join over views. + The planner has to decide which is + the best path to execute the query, and the more information + the planner has, the better this decision can be. And + the rule system as implemented in PostgreSQL + ensures, that this is all information available about the query + up to that point.

37.2.4. Updating a View

What happens if a view is named as the target relation for an + INSERT, UPDATE, or + DELETE? Simply doing the substitutions + described above would give a query tree in which the result + relation points at a subquery range-table entry, which will not + work. Instead, the rewriter assumes that the operation will be + handled by an INSTEAD OF trigger on the view. + (If there is no such trigger, the executor will throw an error + when execution starts.) Rewriting works slightly differently + in this case. For INSERT, the rewriter does + nothing at all with the view, leaving it as the result relation + for the query. For UPDATE and + DELETE, it's still necessary to expand the + view query to produce the "old" rows that the command will + attempt to update or delete. So the view is expanded as normal, + but another unexpanded range-table entry is added to the query + to represent the view in its capacity as the result relation.

The problem that now arises is how to identify the rows to be + updated in the view. Recall that when the result relation + is a table, a special CTID entry is added to the target + list to identify the physical locations of the rows to be updated. + This does not work if the result relation is a view, because a view + does not have any CTID, since its rows do not have + actual physical locations. Instead, for an UPDATE + or DELETE operation, a special wholerow + entry is added to the target list, which expands to include all + columns from the view. The executor uses this value to supply the + "old" row to the INSTEAD OF trigger. It is + up to the trigger to work out what to update based on the old and + new row values.

If there are no INSTEAD OF triggers to update the view, + the executor will throw an error, because it cannot automatically + update a view by itself. To change this, we can define rules that + modify the behavior of INSERT, + UPDATE, and DELETE commands on + a view. These rules will rewrite the command, typically into a command + that updates one or more tables, rather than views. That is the topic + of the next section.

Note that rules are evaluated first, rewriting the original query + before it is planned and executed. Therefore, if a view has + INSTEAD OF triggers as well as rules on INSERT, + UPDATE, or DELETE, then the rules will be + evaluated first, and depending on the result, the triggers may not be + used at all.


PrevHomeNext
The Query TreeUpRules on INSERT, UPDATE, and DELETE
\ No newline at end of file diff --git a/doc/src/sgml/html/rules.html b/doc/src/sgml/html/rules.html new file mode 100644 index 000000000..6f1e1996b --- /dev/null +++ b/doc/src/sgml/html/rules.html @@ -0,0 +1,297 @@ + +The Rule System

Chapter 37. The Rule System

This chapter discusses the rule system in + PostgreSQL. Production rule systems + are conceptually simple, but there are many subtle points + involved in actually using them.

Some other database systems define active database rules, which + are usually stored procedures and triggers. In + PostgreSQL, these can be implemented + using functions and triggers as well.

The rule system (more precisely speaking, the query rewrite rule + system) is totally different from stored procedures and triggers. + It modifies queries to take rules into consideration, and then + passes the modified query to the query planner for planning and + execution. It is very powerful, and can be used for many things + such as query language procedures, views, and versions. The + theoretical foundations and the power of this rule system are + also discussed in On Rules, Procedures, Caching and Views in Database Systems + and A Unified Framework for Version Modeling Using Production Rules in a Database System.


PrevHomeNext
A Complete Trigger ExampleUpThe Query Tree
\ No newline at end of file diff --git a/doc/src/sgml/html/runtime-config-autovacuum.html b/doc/src/sgml/html/runtime-config-autovacuum.html new file mode 100644 index 000000000..e2e9008f4 --- /dev/null +++ b/doc/src/sgml/html/runtime-config-autovacuum.html @@ -0,0 +1,535 @@ + +Automatic Vacuuming
PostgreSQL 9.2.2 Documentation
PrevUpChapter 18. Server ConfigurationNext

18.10. Automatic Vacuuming

These settings control the behavior of the autovacuum + feature. Refer to Section 23.1.6 for + more information. +

autovacuum (boolean)

Controls whether the server should run the + autovacuum launcher daemon. This is on by default; however, + track_counts must also be enabled for + autovacuum to work. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

Note that even when this parameter is disabled, the system + will launch autovacuum processes if necessary to + prevent transaction ID wraparound. See Section 23.1.5 for more information. +

log_autovacuum_min_duration (integer)

Causes each action executed by autovacuum to be logged if it ran for at + least the specified number of milliseconds. Setting this to zero logs + all autovacuum actions. Minus-one (the default) disables logging + autovacuum actions. For example, if you set this to + 250ms then all automatic vacuums and analyzes that run + 250ms or longer will be logged. In addition, when this parameter is + set to any value other than -1, a message will be + logged if an autovacuum action is skipped due to the existence of a + conflicting lock. Enabling this parameter can be helpful + in tracking autovacuum activity. This setting can only be set in + the postgresql.conf file or on the server command line. +

autovacuum_max_workers (integer)

Specifies the maximum number of autovacuum processes (other than the + autovacuum launcher) which may be running at any one time. The default + is three. This parameter can only be set at server start. +

autovacuum_naptime (integer)

Specifies the minimum delay between autovacuum runs on any given + database. In each round the daemon examines the + database and issues VACUUM and ANALYZE commands + as needed for tables in that database. The delay is measured + in seconds, and the default is one minute (1min). + This parameter can only be set in the postgresql.conf + file or on the server command line. +

autovacuum_vacuum_threshold (integer)

Specifies the minimum number of updated or deleted tuples needed + to trigger a VACUUM in any one table. + The default is 50 tuples. + This parameter can only be set in the postgresql.conf + file or on the server command line. + This setting can be overridden for individual tables by + changing storage parameters. +

autovacuum_analyze_threshold (integer)

Specifies the minimum number of inserted, updated or deleted tuples + needed to trigger an ANALYZE in any one table. + The default is 50 tuples. + This parameter can only be set in the postgresql.conf + file or on the server command line. + This setting can be overridden for individual tables by + changing storage parameters. +

autovacuum_vacuum_scale_factor (floating point)

Specifies a fraction of the table size to add to + autovacuum_vacuum_threshold + when deciding whether to trigger a VACUUM. + The default is 0.2 (20% of table size). + This parameter can only be set in the postgresql.conf + file or on the server command line. + This setting can be overridden for individual tables by + changing storage parameters. +

autovacuum_analyze_scale_factor (floating point)

Specifies a fraction of the table size to add to + autovacuum_analyze_threshold + when deciding whether to trigger an ANALYZE. + The default is 0.1 (10% of table size). + This parameter can only be set in the postgresql.conf + file or on the server command line. + This setting can be overridden for individual tables by + changing storage parameters. +

autovacuum_freeze_max_age (integer)

Specifies the maximum age (in transactions) that a table's + pg_class.relfrozenxid field can + attain before a VACUUM operation is forced + to prevent transaction ID wraparound within the table. + Note that the system will launch autovacuum processes to + prevent wraparound even when autovacuum is otherwise disabled. +

Vacuum also allows removal of old files from the + pg_clog subdirectory, which is why the default + is a relatively low 200 million transactions. + This parameter can only be set at server start, but the setting + can be reduced for individual tables by + changing storage parameters. + For more information see Section 23.1.5. +

autovacuum_vacuum_cost_delay (integer)

Specifies the cost delay value that will be used in automatic + VACUUM operations. If -1 is specified, the regular + vacuum_cost_delay value will be used. + The default value is 20 milliseconds. + This parameter can only be set in the postgresql.conf + file or on the server command line. + This setting can be overridden for individual tables by + changing storage parameters. +

autovacuum_vacuum_cost_limit (integer)

Specifies the cost limit value that will be used in automatic + VACUUM operations. If -1 is specified (which is the + default), the regular + vacuum_cost_limit value will be used. Note that + the value is distributed proportionally among the running autovacuum + workers, if there is more than one, so that the sum of the limits of + each worker never exceeds the limit on this variable. + This parameter can only be set in the postgresql.conf + file or on the server command line. + This setting can be overridden for individual tables by + changing storage parameters. +


PrevHomeNext
Run-time StatisticsUpClient Connection Defaults
\ No newline at end of file diff --git a/doc/src/sgml/html/runtime-config-client.html b/doc/src/sgml/html/runtime-config-client.html new file mode 100644 index 000000000..8e634337c --- /dev/null +++ b/doc/src/sgml/html/runtime-config-client.html @@ -0,0 +1,1547 @@ + +Client Connection Defaults
PostgreSQL 9.2.2 Documentation
PrevUpChapter 18. Server ConfigurationNext

18.11. Client Connection Defaults

18.11.1. Statement Behavior

search_path (string)

This variable specifies the order in which schemas are searched + when an object (table, data type, function, etc.) is referenced by a + simple name with no schema specified. When there are objects of + identical names in different schemas, the one found first + in the search path is used. An object that is not in any of the + schemas in the search path can only be referenced by specifying + its containing schema with a qualified (dotted) name. +

The value for search_path must be a comma-separated + list of schema names. Any name that is not an existing schema, or is + a schema for which the user does not have USAGE + permission, is silently ignored. +

If one of the list items is the special name + $user, then the schema having the name returned by + SESSION_USER is substituted, if there is such a schema + and the user has USAGE permission for it. + (If not, $user is ignored.) +

The system catalog schema, pg_catalog, is always + searched, whether it is mentioned in the path or not. If it is + mentioned in the path then it will be searched in the specified + order. If pg_catalog is not in the path then it will + be searched before searching any of the path items. +

Likewise, the current session's temporary-table schema, + pg_temp_nnn, is always searched if it + exists. It can be explicitly listed in the path by using the + alias pg_temp. If it is not listed in the path then + it is searched first (even before pg_catalog). However, + the temporary schema is only searched for relation (table, view, + sequence, etc) and data type names. It is never searched for + function or operator names. +

When objects are created without specifying a particular target + schema, they will be placed in the first valid schema named in + search_path. An error is reported if the search + path is empty. +

The default value for this parameter is + "$user", public. + This setting supports shared use of a database (where no users + have private schemas, and all share use of public), + private per-user schemas, and combinations of these. Other + effects can be obtained by altering the default search path + setting, either globally or per-user. +

The current effective value of the search path can be examined + via the SQL function + current_schemas + (see Section 9.25). + This is not quite the same as + examining the value of search_path, since + current_schemas shows how the items + appearing in search_path were resolved. +

For more information on schema handling, see Section 5.7. +

default_tablespace (string)

This variable specifies the default tablespace in which to create + objects (tables and indexes) when a CREATE command does + not explicitly specify a tablespace. +

The value is either the name of a tablespace, or an empty string + to specify using the default tablespace of the current database. + If the value does not match the name of any existing tablespace, + PostgreSQL will automatically use the default + tablespace of the current database. If a nondefault tablespace + is specified, the user must have CREATE privilege + for it, or creation attempts will fail. +

This variable is not used for temporary tables; for them, + temp_tablespaces is consulted instead. +

This variable is also not used when creating databases. + By default, a new database inherits its tablespace setting from + the template database it is copied from. +

For more information on tablespaces, + see Section 21.6. +

temp_tablespaces (string)

This variable specifies tablespaces in which to create temporary + objects (temp tables and indexes on temp tables) when a + CREATE command does not explicitly specify a tablespace. + Temporary files for purposes such as sorting large data sets + are also created in these tablespaces. +

The value is a list of names of tablespaces. When there is more than + one name in the list, PostgreSQL chooses a random + member of the list each time a temporary object is to be created; + except that within a transaction, successively created temporary + objects are placed in successive tablespaces from the list. + If the selected element of the list is an empty string, + PostgreSQL will automatically use the default + tablespace of the current database instead. +

When temp_tablespaces is set interactively, specifying a + nonexistent tablespace is an error, as is specifying a tablespace for + which the user does not have CREATE privilege. However, + when using a previously set value, nonexistent tablespaces are + ignored, as are tablespaces for which the user lacks + CREATE privilege. In particular, this rule applies when + using a value set in postgresql.conf. +

The default value is an empty string, which results in all temporary + objects being created in the default tablespace of the current + database. +

See also default_tablespace. +

check_function_bodies (boolean)

This parameter is normally on. When set to off, it + disables validation of the function body string during CREATE FUNCTION. Disabling validation is + occasionally useful to avoid problems such as forward references + when restoring function definitions from a dump. +

default_transaction_isolation (enum)

Each SQL transaction has an isolation level, which can be + either "read uncommitted", "read + committed", "repeatable read", or + "serializable". This parameter controls the + default isolation level of each new transaction. The default + is "read committed". +

Consult Chapter 13 and SET TRANSACTION for more information. +

default_transaction_read_only (boolean)

A read-only SQL transaction cannot alter non-temporary tables. + This parameter controls the default read-only status of each new + transaction. The default is off (read/write). +

Consult SET TRANSACTION for more information. +

default_transaction_deferrable (boolean)

When running at the serializable isolation level, + a deferrable read-only SQL transaction may be delayed before + it is allowed to proceed. However, once it begins executing + it does not incur any of the overhead required to ensure + serializability; so serialization code will have no reason to + force it to abort because of concurrent updates, making this + option suitable for long-running read-only transactions. +

This parameter controls the default deferrable status of each + new transaction. It currently has no effect on read-write + transactions or those operating at isolation levels lower + than serializable. The default is off. +

Consult SET TRANSACTION for more information. +

session_replication_role (enum)

Controls firing of replication-related triggers and rules for the + current session. Setting this variable requires + superuser privilege and results in discarding any previously cached + query plans. Possible values are origin (the default), + replica and local. + See ALTER TABLE for + more information. +

statement_timeout (integer)

Abort any statement that takes over the specified number of + milliseconds, starting from the time the command arrives at the server + from the client. If log_min_error_statement is set to + ERROR or lower, the statement that timed out will also be + logged. A value of zero (the default) turns this off. +

Setting statement_timeout in + postgresql.conf is not recommended because it + affects all sessions. +

vacuum_freeze_table_age (integer)

VACUUM performs a whole-table scan if the table's + pg_class.relfrozenxid field has reached + the age specified by this setting. The default is 150 million + transactions. Although users can set this value anywhere from zero to + one billion, VACUUM will silently limit the effective value + to 95% of autovacuum_freeze_max_age, so that a + periodical manual VACUUM has a chance to run before an + anti-wraparound autovacuum is launched for the table. For more + information see + Section 23.1.5. +

vacuum_freeze_min_age (integer)

Specifies the cutoff age (in transactions) that VACUUM + should use to decide whether to replace transaction IDs with + FrozenXID while scanning a table. + The default is 50 million transactions. Although + users can set this value anywhere from zero to one billion, + VACUUM will silently limit the effective value to half + the value of autovacuum_freeze_max_age, so + that there is not an unreasonably short time between forced + autovacuums. For more information see Section 23.1.5. +

bytea_output (enum)

Sets the output format for values of type bytea. + Valid values are hex (the default) + and escape (the traditional PostgreSQL + format). See Section 8.4 for more + information. The bytea type always + accepts both formats on input, regardless of this setting. +

xmlbinary (enum)

Sets how binary values are to be encoded in XML. This applies + for example when bytea values are converted to + XML by the functions xmlelement or + xmlforest. Possible values are + base64 and hex, which + are both defined in the XML Schema standard. The default is + base64. For further information about + XML-related functions, see Section 9.14. +

The actual choice here is mostly a matter of taste, + constrained only by possible restrictions in client + applications. Both methods support all possible values, + although the hex encoding will be somewhat larger than the + base64 encoding. +

xmloption (enum)

Sets whether DOCUMENT or + CONTENT is implicit when converting between + XML and character string values. See Section 8.13 for a description of this. Valid + values are DOCUMENT and + CONTENT. The default is + CONTENT. +

According to the SQL standard, the command to set this option is +

SET XML OPTION { DOCUMENT | CONTENT };

+ This syntax is also available in PostgreSQL. +

18.11.2. Locale and Formatting

DateStyle (string)

Sets the display format for date and time values, as well as the + rules for interpreting ambiguous date input values. For + historical reasons, this variable contains two independent + components: the output format specification (ISO, + Postgres, SQL, or German) + and the input/output specification for year/month/day ordering + (DMY, MDY, or YMD). These + can be set separately or together. The keywords Euro + and European are synonyms for DMY; the + keywords US, NonEuro, and + NonEuropean are synonyms for MDY. See + Section 8.5 for more information. The + built-in default is ISO, MDY, but + initdb will initialize the + configuration file with a setting that corresponds to the + behavior of the chosen lc_time locale. +

IntervalStyle (enum)

Sets the display format for interval values. + The value sql_standard will produce + output matching SQL standard interval literals. + The value postgres (which is the default) will produce + output matching PostgreSQL releases prior to 8.4 + when the DateStyle + parameter was set to ISO. + The value postgres_verbose will produce output + matching PostgreSQL releases prior to 8.4 + when the DateStyle + parameter was set to non-ISO output. + The value iso_8601 will produce output matching the time + interval "format with designators" defined in section + 4.4.3.2 of ISO 8601. +

The IntervalStyle parameter also affects the + interpretation of ambiguous interval input. See + Section 8.5.4 for more information. +

TimeZone (string)

Sets the time zone for displaying and interpreting time stamps. + The built-in default is GMT, but that is typically + overridden in postgresql.conf; initdb + will install a setting there corresponding to its system environment. + See Section 8.5.3 for more information. +

timezone_abbreviations (string)

Sets the collection of time zone abbreviations that will be accepted + by the server for datetime input. The default is 'Default', + which is a collection that works in most of the world; there are + also 'Australia' and 'India', and other collections can be defined + for a particular installation. See Appendix B for more information. +

extra_float_digits (integer)

This parameter adjusts the number of digits displayed for + floating-point values, including float4, float8, + and geometric data types. The parameter value is added to the + standard number of digits (FLT_DIG or DBL_DIG + as appropriate). The value can be set as high as 3, to include + partially-significant digits; this is especially useful for dumping + float data that needs to be restored exactly. Or it can be set + negative to suppress unwanted digits. +

client_encoding (string)

Sets the client-side encoding (character set). + The default is to use the database encoding. + The character sets supported by the PostgreSQL + server are described in Section 22.3.1. +

lc_messages (string)

Sets the language in which messages are displayed. Acceptable + values are system-dependent; see Section 22.1 for + more information. If this variable is set to the empty string + (which is the default) then the value is inherited from the + execution environment of the server in a system-dependent way. +

On some systems, this locale category does not exist. Setting + this variable will still work, but there will be no effect. + Also, there is a chance that no translated messages for the + desired language exist. In that case you will continue to see + the English messages. +

Only superusers can change this setting, because it affects the + messages sent to the server log as well as to the client, and + an improper value might obscure the readability of the server + logs. +

lc_monetary (string)

Sets the locale to use for formatting monetary amounts, for + example with the to_char family of + functions. Acceptable values are system-dependent; see Section 22.1 for more information. If this variable is + set to the empty string (which is the default) then the value + is inherited from the execution environment of the server in a + system-dependent way. +

lc_numeric (string)

Sets the locale to use for formatting numbers, for example + with the to_char family of + functions. Acceptable values are system-dependent; see Section 22.1 for more information. If this variable is + set to the empty string (which is the default) then the value + is inherited from the execution environment of the server in a + system-dependent way. +

lc_time (string)

Sets the locale to use for formatting dates and times, for example + with the to_char family of + functions. Acceptable values are system-dependent; see Section 22.1 for more information. If this variable is + set to the empty string (which is the default) then the value + is inherited from the execution environment of the server in a + system-dependent way. +

default_text_search_config (string)

Selects the text search configuration that is used by those variants + of the text search functions that do not have an explicit argument + specifying the configuration. + See Chapter 12 for further information. + The built-in default is pg_catalog.simple, but + initdb will initialize the + configuration file with a setting that corresponds to the + chosen lc_ctype locale, if a configuration + matching that locale can be identified. +

18.11.3. Other Defaults

dynamic_library_path (string)

If a dynamically loadable module needs to be opened and the + file name specified in the CREATE FUNCTION or + LOAD command + does not have a directory component (i.e., the + name does not contain a slash), the system will search this + path for the required file. +

The value for dynamic_library_path must be a + list of absolute directory paths separated by colons (or semi-colons + on Windows). If a list element starts + with the special string $libdir, the + compiled-in PostgreSQL package + library directory is substituted for $libdir; this + is where the modules provided by the standard + PostgreSQL distribution are installed. + (Use pg_config --pkglibdir to find out the name of + this directory.) For example: +

dynamic_library_path = '/usr/local/lib/postgresql:/home/my_project/lib:$libdir'

+ or, in a Windows environment: +

dynamic_library_path = 'C:\tools\postgresql;H:\my_project\lib;$libdir'

+

The default value for this parameter is + '$libdir'. If the value is set to an empty + string, the automatic path search is turned off. +

This parameter can be changed at run time by superusers, but a + setting done that way will only persist until the end of the + client connection, so this method should be reserved for + development purposes. The recommended way to set this parameter + is in the postgresql.conf configuration + file. +

gin_fuzzy_search_limit (integer)

Soft upper limit of the size of the set returned by GIN index scans. For more + information see Section 55.4. +

local_preload_libraries (string)

This variable specifies one or more shared libraries that are + to be preloaded at connection start. If more than one library + is to be loaded, separate their names with commas. All library + names are converted to lower case unless double-quoted. + This parameter cannot be changed after the start of a particular + session. +

Because this is not a superuser-only option, the libraries + that can be loaded are restricted to those appearing in the + plugins subdirectory of the installation's + standard library directory. (It is the database administrator's + responsibility to ensure that only "safe" libraries + are installed there.) Entries in local_preload_libraries + can specify this directory explicitly, for example + $libdir/plugins/mylib, or just specify + the library name — mylib would have + the same effect as $libdir/plugins/mylib. +

Unlike shared_preload_libraries, there is no + performance advantage to loading a library at session + start rather than when it is first used. Rather, the intent of + this feature is to allow debugging or performance-measurement + libraries to be loaded into specific sessions without an explicit + LOAD command being given. For example, debugging could + be enabled for all sessions under a given user name by setting + this parameter with ALTER ROLE SET. +

If a specified library is not found, + the connection attempt will fail. +

Every PostgreSQL-supported library has a "magic + block" that is checked to guarantee compatibility. + For this reason, non-PostgreSQL libraries cannot be + loaded in this way. +


PrevHomeNext
Automatic VacuumingUpLock Management
\ No newline at end of file diff --git a/doc/src/sgml/html/runtime-config-compatible.html b/doc/src/sgml/html/runtime-config-compatible.html new file mode 100644 index 000000000..8199cb77a --- /dev/null +++ b/doc/src/sgml/html/runtime-config-compatible.html @@ -0,0 +1,767 @@ + +Version and Platform Compatibility
PostgreSQL 9.2.2 Documentation
PrevUpChapter 18. Server ConfigurationNext

18.13. Version and Platform Compatibility

18.13.1. Previous PostgreSQL Versions

array_nulls (boolean)

This controls whether the array input parser recognizes + unquoted NULL as specifying a null array element. + By default, this is on, allowing array values containing + null values to be entered. However, PostgreSQL versions + before 8.2 did not support null values in arrays, and therefore would + treat NULL as specifying a normal array element with + the string value "NULL". For backward compatibility with + applications that require the old behavior, this variable can be + turned off. +

Note that it is possible to create array values containing null values + even when this variable is off. +

backslash_quote (enum)

This controls whether a quote mark can be represented by + \' in a string literal. The preferred, SQL-standard way + to represent a quote mark is by doubling it ('') but + PostgreSQL has historically also accepted + \'. However, use of \' creates security risks + because in some client character set encodings, there are multibyte + characters in which the last byte is numerically equivalent to ASCII + \. If client-side code does escaping incorrectly then a + SQL-injection attack is possible. This risk can be prevented by + making the server reject queries in which a quote mark appears to be + escaped by a backslash. + The allowed values of backslash_quote are + on (allow \' always), + off (reject always), and + safe_encoding (allow only if client encoding does not + allow ASCII \ within a multibyte character). + safe_encoding is the default setting. +

Note that in a standard-conforming string literal, \ just + means \ anyway. This parameter only affects the handling of + non-standard-conforming literals, including + escape string syntax (E'...'). +

default_with_oids (boolean)

This controls whether CREATE TABLE and + CREATE TABLE AS include an OID column in + newly-created tables, if neither WITH OIDS + nor WITHOUT OIDS is specified. It also + determines whether OIDs will be included in tables created by + SELECT INTO. The parameter is off + by default; in PostgreSQL 8.0 and earlier, it + was on by default. +

The use of OIDs in user tables is considered deprecated, so + most installations should leave this variable disabled. + Applications that require OIDs for a particular table should + specify WITH OIDS when creating the + table. This variable can be enabled for compatibility with old + applications that do not follow this behavior. +

escape_string_warning (boolean)

When on, a warning is issued if a backslash (\) + appears in an ordinary string literal ('...' + syntax) and standard_conforming_strings is off. + The default is on. +

Applications that wish to use backslash as escape should be + modified to use escape string syntax (E'...'), + because the default behavior of ordinary strings is now to treat + backslash as an ordinary character, per SQL standard. This variable + can be enabled to help locate code that needs to be changed. +

lo_compat_privileges (boolean)

In PostgreSQL releases prior to 9.0, large objects + did not have access privileges and were, in effect, readable and + writable by all users. Setting this variable to on + disables the new privilege checks, for compatibility with prior + releases. The default is off. +

Setting this variable does not disable all security checks related to + large objects — only those for which the default behavior has + changed in PostgreSQL 9.0. + For example, lo_import() and + lo_export() need superuser privileges independent + of this setting. +

quote_all_identifiers (boolean)

When the database generates SQL, force all identifiers to be quoted, + even if they are not (currently) keywords. This will affect the + output of EXPLAIN as well as the results of functions + like pg_get_viewdef. See also the + --quote-all-identifiers option of + pg_dump and pg_dumpall. +

sql_inheritance (boolean)

This setting controls whether undecorated table references are + considered to include inheritance child tables. The default is + on, which means child tables are included (thus, + a * suffix is assumed by default). If turned + off, child tables are not included (thus, an + ONLY prefix is assumed). The SQL standard + requires child tables to be included, so the off setting + is not spec-compliant, but it is provided for compatibility with + PostgreSQL releases prior to 7.1. + See Section 5.8 for more information. +

Turning sql_inheritance off is deprecated, because that + behavior has been found to be error-prone as well as contrary to SQL + standard. Discussions of inheritance behavior elsewhere in this + manual generally assume that it is on. +

standard_conforming_strings (boolean)

This controls whether ordinary string literals + ('...') treat backslashes literally, as specified in + the SQL standard. + Beginning in PostgreSQL 9.1, the default is + on (prior releases defaulted to off). + Applications can check this + parameter to determine how string literals will be processed. + The presence of this parameter can also be taken as an indication + that the escape string syntax (E'...') is supported. + Escape string syntax (Section 4.1.2.2) + should be used if an application desires + backslashes to be treated as escape characters. +

synchronize_seqscans (boolean)

This allows sequential scans of large tables to synchronize with each + other, so that concurrent scans read the same block at about the + same time and hence share the I/O workload. When this is enabled, + a scan might start in the middle of the table and then "wrap + around" the end to cover all rows, so as to synchronize with the + activity of scans already in progress. This can result in + unpredictable changes in the row ordering returned by queries that + have no ORDER BY clause. Setting this parameter to + off ensures the pre-8.3 behavior in which a sequential + scan always starts from the beginning of the table. The default + is on. +

18.13.2. Platform and Client Compatibility

transform_null_equals (boolean)

When on, expressions of the form expr = + NULL (or NULL = + expr) are treated as + expr IS NULL, that is, they + return true if expr evaluates to the null value, + and false otherwise. The correct SQL-spec-compliant behavior of + expr = NULL is to always + return null (unknown). Therefore this parameter defaults to + off. +

However, filtered forms in Microsoft + Access generate queries that appear to use + expr = NULL to test for + null values, so if you use that interface to access the database you + might want to turn this option on. Since expressions of the + form expr = NULL always + return the null value (using the SQL standard interpretation), they are not + very useful and do not appear often in normal applications so + this option does little harm in practice. But new users are + frequently confused about the semantics of expressions + involving null values, so this option is off by default. +

Note that this option only affects the exact form = NULL, + not other comparison operators or other expressions + that are computationally equivalent to some expression + involving the equals operator (such as IN). + Thus, this option is not a general fix for bad programming. +

Refer to Section 9.2 for related information. +


PrevHomeNext
Lock ManagementUpError Handling
\ No newline at end of file diff --git a/doc/src/sgml/html/runtime-config-connection.html b/doc/src/sgml/html/runtime-config-connection.html new file mode 100644 index 000000000..e6069dcd1 --- /dev/null +++ b/doc/src/sgml/html/runtime-config-connection.html @@ -0,0 +1,1103 @@ + +Connections and Authentication
PostgreSQL 9.2.2 Documentation
PrevUpChapter 18. Server ConfigurationNext

18.3. Connections and Authentication

18.3.1. Connection Settings

listen_addresses (string)

Specifies the TCP/IP address(es) on which the server is + to listen for connections from client applications. + The value takes the form of a comma-separated list of host names + and/or numeric IP addresses. The special entry * + corresponds to all available IP interfaces. The entry + 0.0.0.0 allows listening for all IPv4 addresses and + :: allows listening for all IPv6 addresses. + If the list is empty, the server does not listen on any IP interface + at all, in which case only Unix-domain sockets can be used to connect + to it. + The default value is localhost, + which allows only local TCP/IP "loopback" connections to be + made. While client authentication (Chapter 19) allows fine-grained control + over who can access the server, listen_addresses + controls which interfaces accept connection attempts, which + can help prevent repeated malicious connection requests on + insecure network interfaces. This parameter can only be set + at server start. +

port (integer)

The TCP port the server listens on; 5432 by default. Note that the + same port number is used for all IP addresses the server listens on. + This parameter can only be set at server start. +

max_connections (integer)

Determines the maximum number of concurrent connections to the + database server. The default is typically 100 connections, but + might be less if your kernel settings will not support it (as + determined during initdb). This parameter can + only be set at server start. +

Increasing this parameter might cause PostgreSQL + to request more System V shared + memory or semaphores than your operating system's default configuration + allows. See Section 17.4.1 for information on how to + adjust those parameters, if necessary. +

When running a standby server, you must set this parameter to the + same or higher value than on the master server. Otherwise, queries + will not be allowed in the standby server. +

superuser_reserved_connections + (integer)

Determines the number of connection "slots" that + are reserved for connections by PostgreSQL + superusers. At most max_connections + connections can ever be active simultaneously. Whenever the + number of active concurrent connections is at least + max_connections minus + superuser_reserved_connections, new + connections will be accepted only for superusers, and no + new replication connections will be accepted. +

The default value is three connections. The value must be less + than the value of max_connections. This + parameter can only be set at server start. +

unix_socket_directory (string)

Specifies the directory of the Unix-domain socket on which the + server is to listen for + connections from client applications. The default is normally + /tmp, but can be changed at build time. + This parameter can only be set at server start. +

In addition to the socket file itself, which is named + .s.PGSQL.nnnn where + nnnn is the server's port number, an ordinary file + named .s.PGSQL.nnnn.lock will be + created in the unix_socket_directory directory. Neither + file should ever be removed manually. +

This parameter is irrelevant on Windows, which does not have + Unix-domain sockets. +

unix_socket_group (string)

Sets the owning group of the Unix-domain socket. (The owning + user of the socket is always the user that starts the + server.) In combination with the parameter + unix_socket_permissions this can be used as + an additional access control mechanism for Unix-domain connections. + By default this is the empty string, which uses the default + group of the server user. This parameter can only be set at + server start. +

This parameter is irrelevant on Windows, which does not have + Unix-domain sockets. +

unix_socket_permissions (integer)

Sets the access permissions of the Unix-domain socket. Unix-domain + sockets use the usual Unix file system permission set. + The parameter value is expected to be a numeric mode + specified in the format accepted by the + chmod and umask + system calls. (To use the customary octal format the number + must start with a 0 (zero).) +

The default permissions are 0777, meaning + anyone can connect. Reasonable alternatives are + 0770 (only user and group, see also + unix_socket_group) and 0700 + (only user). (Note that for a Unix-domain socket, only write + permission matters, so there is no point in setting or revoking + read or execute permissions.) +

This access control mechanism is independent of the one + described in Chapter 19. +

This parameter can only be set at server start. +

This parameter is irrelevant on Windows, which does not have + Unix-domain sockets. +

bonjour (boolean)

Enables advertising the server's existence via + Bonjour. The default is off. + This parameter can only be set at server start. +

bonjour_name (string)

Specifies the Bonjour service + name. The computer name is used if this parameter is set to the + empty string '' (which is the default). This parameter is + ignored if the server was not compiled with + Bonjour support. + This parameter can only be set at server start. +

tcp_keepalives_idle (integer)

Specifies the number of seconds before sending a keepalive packet on + an otherwise idle connection. A value of 0 uses the system default. + This parameter is supported only on systems that support the + TCP_KEEPIDLE or TCP_KEEPALIVE symbols, and on + Windows; on other systems, it must be zero. + In sessions connected via a Unix-domain socket, this parameter is + ignored and always reads as zero. +

Note: On Windows, a value of 0 will set this parameter to 2 hours, + since Windows does not provide a way to read the system default value. +

tcp_keepalives_interval (integer)

Specifies the number of seconds between sending keepalives on an + otherwise idle connection. A value of 0 uses the system default. + This parameter is supported only on systems that support the + TCP_KEEPINTVL symbol, and on Windows; on other systems, it + must be zero. + In sessions connected via a Unix-domain socket, this parameter is + ignored and always reads as zero. +

Note: On Windows, a value of 0 will set this parameter to 1 second, + since Windows does not provide a way to read the system default value. +

tcp_keepalives_count (integer)

Specifies the number of keepalive packets to send on an otherwise idle + connection. A value of 0 uses the system default. This parameter is + supported only on systems that support the TCP_KEEPCNT + symbol; on other systems, it must be zero. + In sessions connected via a Unix-domain socket, this parameter is + ignored and always reads as zero. +

Note: This parameter is not supported on Windows, and must be zero. +

18.3.2. Security and Authentication

authentication_timeout (integer)

Maximum time to complete client authentication, in seconds. If a + would-be client has not completed the authentication protocol in + this much time, the server closes the connection. This prevents + hung clients from occupying a connection indefinitely. + The default is one minute (1m). + This parameter can only be set in the postgresql.conf + file or on the server command line. +

ssl (boolean)

Enables SSL connections. Please read + Section 17.9 before using this. The default + is off. This parameter can only be set at server + start. SSL communication is only possible with + TCP/IP connections. +

ssl_ca_file (string)

Specifies the name of the file containing the SSL server certificate + authority (CA). The default is empty, meaning no CA file is loaded, + and client certificate verification is not performed. (In previous + releases of PostgreSQL, the name of this file was hard-coded + as root.crt.) Relative paths are relative to the + data directory. This parameter can only be set at server start. +

ssl_cert_file (string)

Specifies the name of the file containing the SSL server certificate. + The default is server.crt. Relative paths are + relative to the data directory. This parameter can only be set at + server start. +

ssl_crl_file (string)

Specifies the name of the file containing the SSL server certificate + revocation list (CRL). The default is empty, meaning no CRL file is + loaded. (In previous releases of PostgreSQL, the name of this file was + hard-coded as root.crl.) Relative paths are + relative to the data directory. This parameter can only be set at + server start. +

ssl_key_file (string)

Specifies the name of the file containing the SSL server private key. + The default is server.key. Relative paths are + relative to the data directory. This parameter can only be set at + server start. +

ssl_renegotiation_limit (integer)

Specifies how much data can flow over an SSL-encrypted + connection before renegotiation of the session keys will take + place. Renegotiation decreases an attacker's chances of doing + cryptanalysis when large amounts of traffic can be examined, but it + also carries a large performance penalty. The sum of sent and received + traffic is used to check the limit. If this parameter is set to 0, + renegotiation is disabled. The default is 512MB. +

Note: SSL libraries from before November 2009 are insecure when using SSL + renegotiation, due to a vulnerability in the SSL protocol. As a + stop-gap fix for this vulnerability, some vendors shipped SSL + libraries incapable of doing renegotiation. If any such libraries + are in use on the client or server, SSL renegotiation should be + disabled. +

ssl_ciphers (string)

Specifies a list of SSL ciphers that are allowed to be + used on secure connections. See the openssl + manual page for a list of supported ciphers. +

password_encryption (boolean)

When a password is specified in CREATE USER or + ALTER ROLE + without writing either ENCRYPTED or + UNENCRYPTED, this parameter determines whether the + password is to be encrypted. The default is on + (encrypt the password). +

krb_server_keyfile (string)

Sets the location of the Kerberos server key file. See + Section 19.3.5 or Section 19.3.3 + for details. This parameter can only be set in the + postgresql.conf file or on the server command line. +

krb_srvname (string)

Sets the Kerberos service name. See Section 19.3.5 + for details. This parameter can only be set in the + postgresql.conf file or on the server command line. +

krb_caseins_users (boolean)

Sets whether Kerberos and GSSAPI user names should be treated + case-insensitively. + The default is off (case sensitive). This parameter can only be + set in the postgresql.conf file or on the server command line. +

db_user_namespace (boolean)

This parameter enables per-database user names. It is off by default. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

If this is on, you should create users as username@dbname. + When username is passed by a connecting client, + @ and the database name are appended to the user + name and that database-specific user name is looked up by the + server. Note that when you create users with names containing + @ within the SQL environment, you will need to + quote the user name. +

With this parameter enabled, you can still create ordinary global + users. Simply append @ when specifying the user + name in the client, e.g. joe@. The @ + will be stripped off before the user name is looked up by the + server. +

db_user_namespace causes the client's and + server's user name representation to differ. + Authentication checks are always done with the server's user name + so authentication methods must be configured for the + server's user name, not the client's. Because + md5 uses the user name as salt on both the + client and server, md5 cannot be used with + db_user_namespace. +

Note: This feature is intended as a temporary measure until a + complete solution is found. At that time, this option will + be removed. +


PrevHomeNext
File LocationsUpResource Consumption
\ No newline at end of file diff --git a/doc/src/sgml/html/runtime-config-custom.html b/doc/src/sgml/html/runtime-config-custom.html new file mode 100644 index 000000000..d2812a8ab --- /dev/null +++ b/doc/src/sgml/html/runtime-config-custom.html @@ -0,0 +1,193 @@ + +Customized Options
PostgreSQL 9.2.2 Documentation
PrevUpChapter 18. Server ConfigurationNext

18.16. Customized Options

This feature was designed to allow parameters not normally known to + PostgreSQL to be added by add-on modules + (such as procedural languages). This allows extension modules to be + configured in the standard ways. +

Custom options have two-part names: an extension name, then a dot, then + the parameter name proper, much like qualified names in SQL. An example + is plpgsql.variable_conflict. +

Because custom options may need to be set in processes that have not + loaded the relevant extension module, PostgreSQL + will accept a setting for any two-part parameter name. Such variables + are treated as placeholders and have no function until the module that + defines them is loaded. When an extension module is loaded, it will add + its variable definitions, convert any placeholder values according to + those definitions, and issue warnings for any unrecognized placeholders + that begin with its extension name. +


PrevHomeNext
Preset OptionsUpDeveloper Options
\ No newline at end of file diff --git a/doc/src/sgml/html/runtime-config-developer.html b/doc/src/sgml/html/runtime-config-developer.html new file mode 100644 index 000000000..7e4a15aa3 --- /dev/null +++ b/doc/src/sgml/html/runtime-config-developer.html @@ -0,0 +1,716 @@ + +Developer Options
PostgreSQL 9.2.2 Documentation
PrevUpChapter 18. Server ConfigurationNext

18.17. Developer Options

The following parameters are intended for work on the + PostgreSQL source code, and in some cases + to assist with recovery of severely damaged databases. There + should be no reason to use them on a production database. + As such, they have been excluded from the sample + postgresql.conf file. Note that many of these + parameters require special source compilation flags to work at all. +

allow_system_table_mods (boolean)

Allows modification of the structure of system tables. + This is used by initdb. + This parameter can only be set at server start. +

debug_assertions (boolean)

Turns on various assertion checks. This is a debugging aid. If + you are experiencing strange problems or crashes you might want + to turn this on, as it might expose programming mistakes. To use + this parameter, the macro USE_ASSERT_CHECKING + must be defined when PostgreSQL is + built (accomplished by the configure option + --enable-cassert). Note that + debug_assertions defaults to on + if PostgreSQL has been built with + assertions enabled. +

ignore_system_indexes (boolean)

Ignore system indexes when reading system tables (but still + update the indexes when modifying the tables). This is useful + when recovering from damaged system indexes. + This parameter cannot be changed after session start. +

post_auth_delay (integer)

If nonzero, a delay of this many seconds occurs when a new + server process is started, after it conducts the + authentication procedure. This is intended to give developers an + opportunity to attach to the server process with a debugger. + This parameter cannot be changed after session start. +

pre_auth_delay (integer)

If nonzero, a delay of this many seconds occurs just after a + new server process is forked, before it conducts the + authentication procedure. This is intended to give developers an + opportunity to attach to the server process with a debugger to + trace down misbehavior in authentication. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

trace_notify (boolean)

Generates a great amount of debugging output for the + LISTEN and NOTIFY + commands. client_min_messages or + log_min_messages must be + DEBUG1 or lower to send this output to the + client or server logs, respectively. +

trace_recovery_messages (enum)

Enables logging of recovery-related debugging output that otherwise + would not be logged. This parameter allows the user to override the + normal setting of log_min_messages, but only for + specific messages. This is intended for use in debugging Hot Standby. + Valid values are DEBUG5, DEBUG4, + DEBUG3, DEBUG2, DEBUG1, and + LOG. The default, LOG, does not affect + logging decisions at all. The other values cause recovery-related + debug messages of that priority or higher to be logged as though they + had LOG priority; for common settings of + log_min_messages this results in unconditionally sending + them to the server log. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

trace_sort (boolean)

If on, emit information about resource usage during sort operations. + This parameter is only available if the TRACE_SORT macro + was defined when PostgreSQL was compiled. + (However, TRACE_SORT is currently defined by default.) +

trace_locks (boolean)

If on, emit information about lock usage. Information dumped + includes the type of lock operation, the type of lock and the unique + identifier of the object being locked or unlocked. Also included + are bit masks for the lock types already granted on this object as + well as for the lock types awaited on this object. For each lock + type a count of the number of granted locks and waiting locks is + also dumped as well as the totals. An example of the log file output + is shown here: +

LOG:  LockAcquire: new: lock(0xb7acd844) id(24688,24696,0,0,0,1)
+      grantMask(0) req(0,0,0,0,0,0,0)=0 grant(0,0,0,0,0,0,0)=0
+      wait(0) type(AccessShareLock)
+LOG:  GrantLock: lock(0xb7acd844) id(24688,24696,0,0,0,1)
+      grantMask(2) req(1,0,0,0,0,0,0)=1 grant(1,0,0,0,0,0,0)=1
+      wait(0) type(AccessShareLock)
+LOG:  UnGrantLock: updated: lock(0xb7acd844) id(24688,24696,0,0,0,1)
+      grantMask(0) req(0,0,0,0,0,0,0)=0 grant(0,0,0,0,0,0,0)=0
+      wait(0) type(AccessShareLock)
+LOG:  CleanUpLock: deleting: lock(0xb7acd844) id(24688,24696,0,0,0,1)
+      grantMask(0) req(0,0,0,0,0,0,0)=0 grant(0,0,0,0,0,0,0)=0
+      wait(0) type(INVALID)

+ Details of the structure being dumped may be found in + src/include/storage/lock.h. +

This parameter is only available if the LOCK_DEBUG + macro was defined when PostgreSQL was + compiled. +

trace_lwlocks (boolean)

If on, emit information about lightweight lock usage. Lightweight + locks are intended primarily to provide mutual exclusion of access + to shared-memory data structures. +

This parameter is only available if the LOCK_DEBUG + macro was defined when PostgreSQL was + compiled. +

trace_userlocks (boolean)

If on, emit information about user lock usage. Output is the same + as for trace_locks, only for advisory locks. +

This parameter is only available if the LOCK_DEBUG + macro was defined when PostgreSQL was + compiled. +

trace_lock_oidmin (integer)

If set, do not trace locks for tables below this OID. (use to avoid + output on system tables) +

This parameter is only available if the LOCK_DEBUG + macro was defined when PostgreSQL was + compiled. +

trace_lock_table (integer)

Unconditionally trace locks on this table (OID). +

This parameter is only available if the LOCK_DEBUG + macro was defined when PostgreSQL was + compiled. +

debug_deadlocks (boolean)

If set, dumps information about all current locks when a + deadlock timeout occurs. +

This parameter is only available if the LOCK_DEBUG + macro was defined when PostgreSQL was + compiled. +

log_btree_build_stats (boolean)

If set, logs system resource usage statistics (memory and CPU) on + various B-tree operations. +

This parameter is only available if the BTREE_BUILD_STATS + macro was defined when PostgreSQL was + compiled. +

wal_debug (boolean)

If on, emit WAL-related debugging output. This parameter is + only available if the WAL_DEBUG macro was + defined when PostgreSQL was + compiled. +

zero_damaged_pages (boolean)

Detection of a damaged page header normally causes + PostgreSQL to report an error, aborting the current + transaction. Setting zero_damaged_pages to on causes + the system to instead report a warning, zero out the damaged + page in memory, and continue processing. This behavior will destroy data, + namely all the rows on the damaged page. However, it does allow you to get + past the error and retrieve rows from any undamaged pages that might + be present in the table. It is useful for recovering data if + corruption has occurred due to a hardware or software error. You should + generally not set this on until you have given up hope of recovering + data from the damaged pages of a table. Zeroed-out pages are not + forced to disk so it is recommended to recreate the table or + the index before turning this parameter off again. The + default setting is off, and it can only be changed + by a superuser. +


PrevHomeNext
Customized OptionsUpShort Options
\ No newline at end of file diff --git a/doc/src/sgml/html/runtime-config-error-handling.html b/doc/src/sgml/html/runtime-config-error-handling.html new file mode 100644 index 000000000..ce472f9cc --- /dev/null +++ b/doc/src/sgml/html/runtime-config-error-handling.html @@ -0,0 +1,216 @@ + +Error Handling
PostgreSQL 9.2.2 Documentation
PrevUpChapter 18. Server ConfigurationNext

18.14. Error Handling

exit_on_error (boolean)

If true, any error will terminate the current session. By default, + this is set to false, so that only FATAL errors will terminate the + session. +

restart_after_crash (boolean)

When set to true, which is the default, PostgreSQL + will automatically reinitialize after a backend crash. Leaving this + value set to true is normally the best way to maximize the availability + of the database. However, in some circumstances, such as when + PostgreSQL is being invoked by clusterware, it may be + useful to disable the restart so that the clusterware can gain + control and take any actions it deems appropriate. +


PrevHomeNext
Version and Platform CompatibilityUpPreset Options
\ No newline at end of file diff --git a/doc/src/sgml/html/runtime-config-file-locations.html b/doc/src/sgml/html/runtime-config-file-locations.html new file mode 100644 index 000000000..b790776fd --- /dev/null +++ b/doc/src/sgml/html/runtime-config-file-locations.html @@ -0,0 +1,388 @@ + +File Locations
PostgreSQL 9.2.2 Documentation
PrevUpChapter 18. Server ConfigurationNext

18.2. File Locations

In addition to the postgresql.conf file + already mentioned, PostgreSQL uses + two other manually-edited configuration files, which control + client authentication (their use is discussed in Chapter 19). By default, all three + configuration files are stored in the database cluster's data + directory. The parameters described in this section allow the + configuration files to be placed elsewhere. (Doing so can ease + administration. In particular it is often easier to ensure that + the configuration files are properly backed-up when they are + kept separate.) +

data_directory (string)

Specifies the directory to use for data storage. + This parameter can only be set at server start. +

config_file (string)

Specifies the main server configuration file + (customarily called postgresql.conf). + This parameter can only be set on the postgres command line. +

hba_file (string)

Specifies the configuration file for host-based authentication + (customarily called pg_hba.conf). + This parameter can only be set at server start. +

ident_file (string)

Specifies the configuration file for + Section 19.2 user name mapping + (customarily called pg_ident.conf). + This parameter can only be set at server start. +

external_pid_file (string)

Specifies the name of an additional process-ID (PID) file that the + server should create for use by server administration programs. + This parameter can only be set at server start. +

In a default installation, none of the above parameters are set + explicitly. Instead, the + data directory is specified by the -D command-line + option or the PGDATA environment variable, and the + configuration files are all found within the data directory. +

If you wish to keep the configuration files elsewhere than the + data directory, the postgres -D + command-line option or PGDATA environment variable + must point to the directory containing the configuration files, + and the data_directory parameter must be set in + postgresql.conf (or on the command line) to show + where the data directory is actually located. Notice that + data_directory overrides -D and + PGDATA for the location + of the data directory, but not for the location of the configuration + files. +

If you wish, you can specify the configuration file names and locations + individually using the parameters config_file, + hba_file and/or ident_file. + config_file can only be specified on the + postgres command line, but the others can be + set within the main configuration file. If all three parameters plus + data_directory are explicitly set, then it is not necessary + to specify -D or PGDATA. +

When setting any of these parameters, a relative path will be interpreted + with respect to the directory in which postgres + is started. +


PrevHomeNext
Setting ParametersUpConnections and Authentication
\ No newline at end of file diff --git a/doc/src/sgml/html/runtime-config-locks.html b/doc/src/sgml/html/runtime-config-locks.html new file mode 100644 index 000000000..c198b3c50 --- /dev/null +++ b/doc/src/sgml/html/runtime-config-locks.html @@ -0,0 +1,337 @@ + +Lock Management
PostgreSQL 9.2.2 Documentation
PrevUpChapter 18. Server ConfigurationNext

18.12. Lock Management

deadlock_timeout (integer)

This is the amount of time, in milliseconds, to wait on a lock + before checking to see if there is a deadlock condition. The + check for deadlock is relatively expensive, so the server doesn't run + it every time it waits for a lock. We optimistically assume + that deadlocks are not common in production applications and + just wait on the lock for a while before checking for a + deadlock. Increasing this value reduces the amount of time + wasted in needless deadlock checks, but slows down reporting of + real deadlock errors. The default is one second (1s), + which is probably about the smallest value you would want in + practice. On a heavily loaded server you might want to raise it. + Ideally the setting should exceed your typical transaction time, + so as to improve the odds that a lock will be released before + the waiter decides to check for deadlock. Only superusers can change + this setting. +

When log_lock_waits is set, + this parameter also determines the length of time to wait before + a log message is issued about the lock wait. If you are trying + to investigate locking delays you might want to set a shorter than + normal deadlock_timeout. +

max_locks_per_transaction (integer)

The shared lock table tracks locks on + max_locks_per_transaction * (max_connections + max_prepared_transactions) objects (e.g., tables); + hence, no more than this many distinct objects can be locked at + any one time. This parameter controls the average number of object + locks allocated for each transaction; individual transactions + can lock more objects as long as the locks of all transactions + fit in the lock table. This is not the number of + rows that can be locked; that value is unlimited. The default, + 64, has historically proven sufficient, but you might need to + raise this value if you have clients that touch many different + tables in a single transaction. This parameter can only be set at + server start. +

Increasing this parameter might cause PostgreSQL + to request more System V shared + memory than your operating system's default configuration + allows. See Section 17.4.1 for information on how to + adjust those parameters, if necessary. +

When running a standby server, you must set this parameter to the + same or higher value than on the master server. Otherwise, queries + will not be allowed in the standby server. +

max_pred_locks_per_transaction (integer)

The shared predicate lock table tracks locks on + max_pred_locks_per_transaction * (max_connections + max_prepared_transactions) objects (e.g., tables); + hence, no more than this many distinct objects can be locked at + any one time. This parameter controls the average number of object + locks allocated for each transaction; individual transactions + can lock more objects as long as the locks of all transactions + fit in the lock table. This is not the number of + rows that can be locked; that value is unlimited. The default, + 64, has generally been sufficient in testing, but you might need to + raise this value if you have clients that touch many different + tables in a single serializable transaction. This parameter can + only be set at server start. +

Increasing this parameter might cause PostgreSQL + to request more System V shared + memory than your operating system's default configuration + allows. See Section 17.4.1 for information on how to + adjust those parameters, if necessary. +


PrevHomeNext
Client Connection DefaultsUpVersion and Platform Compatibility
\ No newline at end of file diff --git a/doc/src/sgml/html/runtime-config-logging.html b/doc/src/sgml/html/runtime-config-logging.html new file mode 100644 index 000000000..7639007c6 --- /dev/null +++ b/doc/src/sgml/html/runtime-config-logging.html @@ -0,0 +1,2468 @@ + +Error Reporting and Logging
PostgreSQL 9.2.2 Documentation
PrevUpChapter 18. Server ConfigurationNext

18.8. Error Reporting and Logging

18.8.1. Where To Log

log_destination (string)

PostgreSQL supports several methods + for logging server messages, including + stderr, csvlog and + syslog. On Windows, + eventlog is also supported. Set this + parameter to a list of desired log destinations separated by + commas. The default is to log to stderr + only. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

If csvlog is included in log_destination, + log entries are output in "comma separated + value" (CSV) format, which is convenient for + loading logs into programs. + See Section 18.8.4 for details. + logging_collector must be enabled to generate + CSV-format log output. +

Note: On most Unix systems, you will need to alter the configuration of + your system's syslog daemon in order + to make use of the syslog option for + log_destination. PostgreSQL + can log to syslog facilities + LOCAL0 through LOCAL7 (see syslog_facility), but the default + syslog configuration on most platforms + will discard all such messages. You will need to add something like: +

local0.*    /var/log/postgresql

+ to the syslog daemon's configuration file + to make it work. +

On Windows, when you use the eventlog + option for log_destination, you should + register an event source and its library with the operating + system so that the Windows Event Viewer can display event + log messages cleanly. + See Section 17.11 for details. +

logging_collector (boolean)

This parameter enables the logging collector, which + is a background process that captures log messages + sent to stderr and redirects them into log files. + This approach is often more useful than + logging to syslog, since some types of messages + might not appear in syslog output. (One common + example is dynamic-linker failure messages; another is error messages + produced by scripts such as archive_command.) + This parameter can only be set at server start. +

Note: It is possible to log to stderr without using the + logging collector; the log messages will just go to wherever the + server's stderr is directed. However, that method is + only suitable for low log volumes, since it provides no convenient + way to rotate log files. Also, on some platforms not using the + logging collector can result in lost or garbled log output, because + multiple processes writing concurrently to the same log file can + overwrite each other's output. +

Note: The logging collector is designed to never lose messages. This means + that in case of extremely high load, server processes could be + blocked while trying to send additional log messages when the + collector has fallen behind. In contrast, syslog + prefers to drop messages if it cannot write them, which means it + may fail to log some messages in such cases but it will not block + the rest of the system. +

log_directory (string)

When logging_collector is enabled, + this parameter determines the directory in which log files will be created. + It can be specified as an absolute path, or relative to the + cluster data directory. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

log_filename (string)

When logging_collector is enabled, + this parameter sets the file names of the created log files. The value + is treated as a strftime pattern, + so %-escapes can be used to specify time-varying + file names. (Note that if there are + any time-zone-dependent %-escapes, the computation + is done in the zone specified + by log_timezone.) + The supported %-escapes are similar to those + listed in the Open Group's strftime + specification. + Note that the system's strftime is not used + directly, so platform-specific (nonstandard) extensions do not work. +

If you specify a file name without escapes, you should plan to + use a log rotation utility to avoid eventually filling the + entire disk. In releases prior to 8.4, if + no % escapes were + present, PostgreSQL would append + the epoch of the new log file's creation time, but this is no + longer the case. +

If CSV-format output is enabled in log_destination, + .csv will be appended to the timestamped + log file name to create the file name for CSV-format output. + (If log_filename ends in .log, the suffix is + replaced instead.) + In the case of the example above, the CSV + file name will be server_log.1093827753.csv. +

This parameter can only be set in the postgresql.conf + file or on the server command line. +

log_file_mode (integer)

On Unix systems this parameter sets the permissions for log files + when logging_collector is enabled. (On Microsoft + Windows this parameter is ignored.) + The parameter value is expected to be a numeric mode + specified in the format accepted by the + chmod and umask + system calls. (To use the customary octal format the number + must start with a 0 (zero).) +

The default permissions are 0600, meaning only the + server owner can read or write the log files. The other commonly + useful setting is 0640, allowing members of the owner's + group to read the files. Note however that to make use of such a + setting, you'll need to alter log_directory to + store the files somewhere outside the cluster data directory. In + any case, it's unwise to make the log files world-readable, since + they might contain sensitive data. +

This parameter can only be set in the postgresql.conf + file or on the server command line. +

log_rotation_age (integer)

When logging_collector is enabled, + this parameter determines the maximum lifetime of an individual log file. + After this many minutes have elapsed, a new log file will + be created. Set to zero to disable time-based creation of + new log files. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

log_rotation_size (integer)

When logging_collector is enabled, + this parameter determines the maximum size of an individual log file. + After this many kilobytes have been emitted into a log file, + a new log file will be created. Set to zero to disable size-based + creation of new log files. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

log_truncate_on_rotation (boolean)

When logging_collector is enabled, + this parameter will cause PostgreSQL to truncate (overwrite), + rather than append to, any existing log file of the same name. + However, truncation will occur only when a new file is being opened + due to time-based rotation, not during server startup or size-based + rotation. When off, pre-existing files will be appended to in + all cases. For example, using this setting in combination with + a log_filename like postgresql-%H.log + would result in generating twenty-four hourly log files and then + cyclically overwriting them. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

Example: To keep 7 days of logs, one log file per day named + server_log.Mon, server_log.Tue, + etc, and automatically overwrite last week's log with this week's log, + set log_filename to server_log.%a, + log_truncate_on_rotation to on, and + log_rotation_age to 1440. +

Example: To keep 24 hours of logs, one log file per hour, but + also rotate sooner if the log file size exceeds 1GB, set + log_filename to server_log.%H%M, + log_truncate_on_rotation to on, + log_rotation_age to 60, and + log_rotation_size to 1000000. + Including %M in log_filename allows + any size-driven rotations that might occur to select a file name + different from the hour's initial file name. +

syslog_facility (enum)

When logging to syslog is enabled, this parameter + determines the syslog + "facility" to be used. You can choose + from LOCAL0, LOCAL1, + LOCAL2, LOCAL3, LOCAL4, + LOCAL5, LOCAL6, LOCAL7; + the default is LOCAL0. See also the + documentation of your system's + syslog daemon. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

syslog_ident (string)

When logging to syslog is enabled, this parameter + determines the program name used to identify + PostgreSQL messages in + syslog logs. The default is + postgres. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

event_source (string)

When logging to event log is enabled, this parameter + determines the program name used to identify + PostgreSQL messages in + the log. The default is PostgreSQL. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

18.8.2. When To Log

client_min_messages (enum)

Controls which message levels are sent to the client. + Valid values are DEBUG5, + DEBUG4, DEBUG3, DEBUG2, + DEBUG1, LOG, NOTICE, + WARNING, ERROR, FATAL, + and PANIC. Each level + includes all the levels that follow it. The later the level, + the fewer messages are sent. The default is + NOTICE. Note that LOG has a different + rank here than in log_min_messages. +

log_min_messages (enum)

Controls which message levels are written to the server log. + Valid values are DEBUG5, DEBUG4, + DEBUG3, DEBUG2, DEBUG1, + INFO, NOTICE, WARNING, + ERROR, LOG, FATAL, and + PANIC. Each level includes all the levels that + follow it. The later the level, the fewer messages are sent + to the log. The default is WARNING. Note that + LOG has a different rank here than in + client_min_messages. + Only superusers can change this setting. +

log_min_error_statement (enum)

Controls which SQL statements that cause an error + condition are recorded in the server log. The current + SQL statement is included in the log entry for any message of + the specified severity or higher. + Valid values are DEBUG5, + DEBUG4, DEBUG3, + DEBUG2, DEBUG1, + INFO, NOTICE, + WARNING, ERROR, + LOG, + FATAL, and PANIC. + The default is ERROR, which means statements + causing errors, log messages, fatal errors, or panics will be logged. + To effectively turn off logging of failing statements, + set this parameter to PANIC. + Only superusers can change this setting. +

log_min_duration_statement (integer)

Causes the duration of each completed statement to be logged + if the statement ran for at least the specified number of + milliseconds. Setting this to zero prints all statement durations. + Minus-one (the default) disables logging statement durations. + For example, if you set it to 250ms + then all SQL statements that run 250ms or longer will be + logged. Enabling this parameter can be helpful in tracking down + unoptimized queries in your applications. + Only superusers can change this setting. +

For clients using extended query protocol, durations of the Parse, + Bind, and Execute steps are logged independently. +

Note: When using this option together with + log_statement, + the text of statements that are logged because of + log_statement will not be repeated in the + duration log message. + If you are not using syslog, it is recommended + that you log the PID or session ID using + log_line_prefix + so that you can link the statement message to the later + duration message using the process ID or session ID. +

Table 18-1 explains the message + severity levels used by PostgreSQL. If logging output + is sent to syslog or Windows' + eventlog, the severity levels are translated + as shown in the table. +

Table 18-1. Message Severity Levels

SeverityUsagesyslogeventlog
DEBUG1..DEBUG5Provides successively-more-detailed information for use by + developers.DEBUGINFORMATION
INFOProvides information implicitly requested by the user, + e.g., output from VACUUM VERBOSE.INFOINFORMATION
NOTICEProvides information that might be helpful to users, e.g., + notice of truncation of long identifiers.NOTICEINFORMATION
WARNINGProvides warnings of likely problems, e.g., COMMIT + outside a transaction block.NOTICEWARNING
ERRORReports an error that caused the current command to + abort.WARNINGERROR
LOGReports information of interest to administrators, e.g., + checkpoint activity.INFOINFORMATION
FATALReports an error that caused the current session to + abort.ERRERROR
PANICReports an error that caused all database sessions to abort.CRITERROR

18.8.3. What To Log

application_name (string)

The application_name can be any string of less than + NAMEDATALEN characters (64 characters in a standard build). + It is typically set by an application upon connection to the server. + The name will be displayed in the pg_stat_activity view + and included in CSV log entries. It can also be included in regular + log entries via the log_line_prefix parameter. + Only printable ASCII characters may be used in the + application_name value. Other characters will be + replaced with question marks (?). +

debug_print_parse (boolean)
debug_print_rewritten (boolean)
debug_print_plan (boolean)

These parameters enable various debugging output to be emitted. + When set, they print the resulting parse tree, the query rewriter + output, or the execution plan for each executed query. + These messages are emitted at LOG message level, so by + default they will appear in the server log but will not be sent to the + client. You can change that by adjusting + client_min_messages and/or + log_min_messages. + These parameters are off by default. +

debug_pretty_print (boolean)

When set, debug_pretty_print indents the messages + produced by debug_print_parse, + debug_print_rewritten, or + debug_print_plan. This results in more readable + but much longer output than the "compact" format used when + it is off. It is on by default. +

log_checkpoints (boolean)

Causes checkpoints and restartpoints to be logged in the server log. + Some statistics are included in the log messages, including the number + of buffers written and the time spent writing them. + This parameter can only be set in the postgresql.conf + file or on the server command line. The default is off. +

log_connections (boolean)

Causes each attempted connection to the server to be logged, + as well as successful completion of client authentication. + This parameter cannot be changed after session start. + The default is off. +

Note: Some client programs, like psql, attempt + to connect twice while determining if a password is required, so + duplicate "connection received" messages do not + necessarily indicate a problem. +

log_disconnections (boolean)

This outputs a line in the server log similar to + log_connections but at session termination, + and includes the duration of the session. This is off by + default. + This parameter cannot be changed after session start. +

log_duration (boolean)

Causes the duration of every completed statement to be logged. + The default is off. + Only superusers can change this setting. +

For clients using extended query protocol, durations of the Parse, + Bind, and Execute steps are logged independently. +

Note: The difference between setting this option and setting + log_min_duration_statement to zero is that + exceeding log_min_duration_statement forces the text of + the query to be logged, but this option doesn't. Thus, if + log_duration is on and + log_min_duration_statement has a positive value, all + durations are logged but the query text is included only for + statements exceeding the threshold. This behavior can be useful for + gathering statistics in high-load installations. +

log_error_verbosity (enum)

Controls the amount of detail written in the server log for each + message that is logged. Valid values are TERSE, + DEFAULT, and VERBOSE, each adding more + fields to displayed messages. TERSE excludes + the logging of DETAIL, HINT, + QUERY, and CONTEXT error information. + VERBOSE output includes the SQLSTATE error + code (see also Appendix A) and the source code file name, function name, + and line number that generated the error. + Only superusers can change this setting. +

log_hostname (boolean)

By default, connection log messages only show the IP address of the + connecting host. Turning this parameter on causes logging of the + host name as well. Note that depending on your host name resolution + setup this might impose a non-negligible performance penalty. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

log_line_prefix (string)

This is a printf-style string that is output at the + beginning of each log line. + % characters begin "escape sequences" + that are replaced with status information as outlined below. + Unrecognized escapes are ignored. Other + characters are copied straight to the log line. Some escapes are + only recognized by session processes, and are ignored by + background processes such as the main server process. + This parameter can only be set in the postgresql.conf + file or on the server command line. The default is an empty string. + +

EscapeEffectSession only
%aApplication nameyes
%uUser nameyes
%dDatabase nameyes
%rRemote host name or IP address, and remote portyes
%hRemote host name or IP addressyes
%pProcess IDno
%tTime stamp without millisecondsno
%mTime stamp with millisecondsno
%iCommand tag: type of session's current commandyes
%eSQLSTATE error codeno
%cSession ID: see belowno
%lNumber of the log line for each session or process, starting at 1no
%sProcess start time stampno
%vVirtual transaction ID (backendID/localXID)no
%xTransaction ID (0 if none is assigned)no
%qProduces no output, but tells non-session + processes to stop at this point in the string; ignored by + session processesno
%%Literal %no

+ + The %c escape prints a quasi-unique session identifier, + consisting of two 4-byte hexadecimal numbers (without leading zeros) + separated by a dot. The numbers are the process start time and the + process ID, so %c can also be used as a space saving way + of printing those items. For example, to generate the session + identifier from pg_stat_activity, use this query: +

SELECT to_hex(EXTRACT(EPOCH FROM backend_start)::integer) || '.' ||
+       to_hex(pid)
+FROM pg_stat_activity;

+ +

Tip: If you set a nonempty value for log_line_prefix, + you should usually make its last character be a space, to provide + visual separation from the rest of the log line. A punctuation + character can be used too. +

Tip: Syslog produces its own + time stamp and process ID information, so you probably do not want to + include those escapes if you are logging to syslog. +

log_lock_waits (boolean)

Controls whether a log message is produced when a session waits + longer than deadlock_timeout to acquire a + lock. This is useful in determining if lock waits are causing + poor performance. The default is off. +

log_statement (enum)

Controls which SQL statements are logged. Valid values are + none (off), ddl, mod, and + all (all statements). ddl logs all data definition + statements, such as CREATE, ALTER, and + DROP statements. mod logs all + ddl statements, plus data-modifying statements + such as INSERT, + UPDATE, DELETE, TRUNCATE, + and COPY FROM. + PREPARE, EXECUTE, and + EXPLAIN ANALYZE statements are also logged if their + contained command is of an appropriate type. For clients using + extended query protocol, logging occurs when an Execute message + is received, and values of the Bind parameters are included + (with any embedded single-quote marks doubled). +

The default is none. Only superusers can change this + setting. +

Note: Statements that contain simple syntax errors are not logged + even by the log_statement = all setting, + because the log message is emitted only after basic parsing has + been done to determine the statement type. In the case of extended + query protocol, this setting likewise does not log statements that + fail before the Execute phase (i.e., during parse analysis or + planning). Set log_min_error_statement to + ERROR (or lower) to log such statements. +

log_temp_files (integer)

Controls logging of temporary file names and sizes. + Temporary files can be + created for sorts, hashes, and temporary query results. + A log entry is made for each temporary file when it is deleted. + A value of zero logs all temporary file information, while positive + values log only files whose size is greater than or equal to + the specified number of kilobytes. The + default setting is -1, which disables such logging. + Only superusers can change this setting. +

log_timezone (string)

Sets the time zone used for timestamps written in the server log. + Unlike TimeZone, this value is cluster-wide, + so that all sessions will report timestamps consistently. + The built-in default is GMT, but that is typically + overridden in postgresql.conf; initdb + will install a setting there corresponding to its system environment. + See Section 8.5.3 for more information. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

18.8.4. Using CSV-Format Log Output

Including csvlog in the log_destination list + provides a convenient way to import log files into a database table. + This option emits log lines in comma-separated-values + (CSV) format, + with these columns: + time stamp with milliseconds, + user name, + database name, + process ID, + client host:port number, + session ID, + per-session line number, + command tag, + session start time, + virtual transaction ID, + regular transaction ID, + error severity, + SQLSTATE code, + error message, + error message detail, + hint, + internal query that led to the error (if any), + character count of the error position therein, + error context, + user query that led to the error (if any and enabled by + log_min_error_statement), + character count of the error position therein, + location of the error in the PostgreSQL source code + (if log_error_verbosity is set to verbose), + and application name. + Here is a sample table definition for storing CSV-format log output: + +

CREATE TABLE postgres_log
+(
+  log_time timestamp(3) with time zone,
+  user_name text,
+  database_name text,
+  process_id integer,
+  connection_from text,
+  session_id text,
+  session_line_num bigint,
+  command_tag text,
+  session_start_time timestamp with time zone,
+  virtual_transaction_id text,
+  transaction_id bigint,
+  error_severity text,
+  sql_state_code text,
+  message text,
+  detail text,
+  hint text,
+  internal_query text,
+  internal_query_pos integer,
+  context text,
+  query text,
+  query_pos integer,
+  location text,
+  application_name text,
+  PRIMARY KEY (session_id, session_line_num)
+);

+

To import a log file into this table, use the COPY FROM + command: + +

COPY postgres_log FROM '/full/path/to/logfile.csv' WITH csv;

+

There are a few things you need to do to simplify importing CSV log + files: + +

  1. Set log_filename and + log_rotation_age to provide a consistent, + predictable naming scheme for your log files. This lets you + predict what the file name will be and know when an individual log + file is complete and therefore ready to be imported. +

  2. Set log_rotation_size to 0 to disable + size-based log rotation, as it makes the log file name difficult + to predict. +

  3. Set log_truncate_on_rotation to on so + that old log data isn't mixed with the new in the same file. +

  4. The table definition above includes a primary key specification. + This is useful to protect against accidentally importing the same + information twice. The COPY command commits all of the + data it imports at one time, so any error will cause the entire + import to fail. If you import a partial log file and later import + the file again when it is complete, the primary key violation will + cause the import to fail. Wait until the log is complete and + closed before importing. This procedure will also protect against + accidentally importing a partial line that hasn't been completely + written, which would also cause COPY to fail. +

+


PrevHomeNext
Query PlanningUpRun-time Statistics
\ No newline at end of file diff --git a/doc/src/sgml/html/runtime-config-preset.html b/doc/src/sgml/html/runtime-config-preset.html new file mode 100644 index 000000000..d07879d1a --- /dev/null +++ b/doc/src/sgml/html/runtime-config-preset.html @@ -0,0 +1,514 @@ + +Preset Options
PostgreSQL 9.2.2 Documentation
PrevUpChapter 18. Server ConfigurationNext

18.15. Preset Options

The following "parameters" are read-only, and are determined + when PostgreSQL is compiled or when it is + installed. As such, they have been excluded from the sample + postgresql.conf file. These options report + various aspects of PostgreSQL behavior + that might be of interest to certain applications, particularly + administrative front-ends. +

block_size (integer)

Reports the size of a disk block. It is determined by the value + of BLCKSZ when building the server. The default + value is 8192 bytes. The meaning of some configuration + variables (such as shared_buffers) is + influenced by block_size. See Section 18.4 for information. +

integer_datetimes (boolean)

Reports whether PostgreSQL was built with + support for 64-bit-integer dates and times. This can be + disabled by configuring with --disable-integer-datetimes + when building PostgreSQL. The default value is + on. +

lc_collate (string)

Reports the locale in which sorting of textual data is done. + See Section 22.1 for more information. + This value is determined when a database is created. +

lc_ctype (string)

Reports the locale that determines character classifications. + See Section 22.1 for more information. + This value is determined when a database is created. + Ordinarily this will be the same as lc_collate, + but for special applications it might be set differently. +

max_function_args (integer)

Reports the maximum number of function arguments. It is determined by + the value of FUNC_MAX_ARGS when building the server. The + default value is 100 arguments. +

max_identifier_length (integer)

Reports the maximum identifier length. It is determined as one + less than the value of NAMEDATALEN when building + the server. The default value of NAMEDATALEN is + 64; therefore the default + max_identifier_length is 63 bytes, which + can be less than 63 characters when using multibyte encodings. +

max_index_keys (integer)

Reports the maximum number of index keys. It is determined by + the value of INDEX_MAX_KEYS when building the server. The + default value is 32 keys. +

segment_size (integer)

Reports the number of blocks (pages) that can be stored within a file + segment. It is determined by the value of RELSEG_SIZE + when building the server. The maximum size of a segment file in bytes + is equal to segment_size multiplied by + block_size; by default this is 1GB. +

server_encoding (string)

Reports the database encoding (character set). + It is determined when the database is created. Ordinarily, + clients need only be concerned with the value of client_encoding. +

server_version (string)

Reports the version number of the server. It is determined by the + value of PG_VERSION when building the server. +

server_version_num (integer)

Reports the version number of the server as an integer. It is determined + by the value of PG_VERSION_NUM when building the server. +

wal_block_size (integer)

Reports the size of a WAL disk block. It is determined by the value + of XLOG_BLCKSZ when building the server. The default value + is 8192 bytes. +

wal_segment_size (integer)

Reports the number of blocks (pages) in a WAL segment file. + The total size of a WAL segment file in bytes is equal to + wal_segment_size multiplied by wal_block_size; + by default this is 16MB. See Section 29.4 for + more information. +


PrevHomeNext
Error HandlingUpCustomized Options
\ No newline at end of file diff --git a/doc/src/sgml/html/runtime-config-query.html b/doc/src/sgml/html/runtime-config-query.html new file mode 100644 index 000000000..c5f5c3627 --- /dev/null +++ b/doc/src/sgml/html/runtime-config-query.html @@ -0,0 +1,1156 @@ + +Query Planning
PostgreSQL 9.2.2 Documentation
PrevUpChapter 18. Server ConfigurationNext

18.7. Query Planning

18.7.1. Planner Method Configuration

These configuration parameters provide a crude method of + influencing the query plans chosen by the query optimizer. If + the default plan chosen by the optimizer for a particular query + is not optimal, a temporary solution is to use one + of these configuration parameters to force the optimizer to + choose a different plan. + Better ways to improve the quality of the + plans chosen by the optimizer include adjusting the planer cost + constants (see Section 18.7.2), + running ANALYZE manually, increasing + the value of the default_statistics_target configuration parameter, + and increasing the amount of statistics collected for + specific columns using ALTER TABLE SET + STATISTICS. +

enable_bitmapscan (boolean)

Enables or disables the query planner's use of bitmap-scan plan + types. The default is on. +

enable_hashagg (boolean)

Enables or disables the query planner's use of hashed + aggregation plan types. The default is on. +

enable_hashjoin (boolean)

Enables or disables the query planner's use of hash-join plan + types. The default is on. +

enable_indexscan (boolean)

Enables or disables the query planner's use of index-scan plan + types. The default is on. +

enable_indexonlyscan (boolean)

Enables or disables the query planner's use of index-only-scan plan + types. The default is on. +

enable_material (boolean)

Enables or disables the query planner's use of materialization. + It is impossible to suppress materialization entirely, + but turning this variable off prevents the planner from inserting + materialize nodes except in cases where it is required for correctness. + The default is on. +

enable_mergejoin (boolean)

Enables or disables the query planner's use of merge-join plan + types. The default is on. +

enable_nestloop (boolean)

Enables or disables the query planner's use of nested-loop join + plans. It is impossible to suppress nested-loop joins entirely, + but turning this variable off discourages the planner from using + one if there are other methods available. The default is + on. +

enable_seqscan (boolean)

Enables or disables the query planner's use of sequential scan + plan types. It is impossible to suppress sequential scans + entirely, but turning this variable off discourages the planner + from using one if there are other methods available. The + default is on. +

enable_sort (boolean)

Enables or disables the query planner's use of explicit sort + steps. It is impossible to suppress explicit sorts entirely, + but turning this variable off discourages the planner from + using one if there are other methods available. The default + is on. +

enable_tidscan (boolean)

Enables or disables the query planner's use of TID + scan plan types. The default is on. +

18.7.2. Planner Cost Constants

The cost variables described in this section are measured + on an arbitrary scale. Only their relative values matter, hence + scaling them all up or down by the same factor will result in no change + in the planner's choices. By default, these cost variables are based on + the cost of sequential page fetches; that is, + seq_page_cost is conventionally set to 1.0 + and the other cost variables are set with reference to that. But + you can use a different scale if you prefer, such as actual execution + times in milliseconds on a particular machine. +

Note: Unfortunately, there is no well-defined method for determining ideal + values for the cost variables. They are best treated as averages over + the entire mix of queries that a particular installation will receive. This + means that changing them on the basis of just a few experiments is very + risky. +

seq_page_cost (floating point)

Sets the planner's estimate of the cost of a disk page fetch + that is part of a series of sequential fetches. The default is 1.0. + This value can be overridden for tables and indexes in a particular + tablespace by setting the tablespace parameter of the same name + (see ALTER TABLESPACE). +

random_page_cost (floating point)

Sets the planner's estimate of the cost of a + non-sequentially-fetched disk page. The default is 4.0. + This value can be overridden for tables and indexes in a particular + tablespace by setting the tablespace parameter of the same name + (see ALTER TABLESPACE). +

Reducing this value relative to seq_page_cost + will cause the system to prefer index scans; raising it will + make index scans look relatively more expensive. You can raise + or lower both values together to change the importance of disk I/O + costs relative to CPU costs, which are described by the following + parameters. +

Random access to mechanical disk storage is normally much more expensive + than four-times sequential access. However, a lower default is used + (4.0) because the majority of random accesses to disk, such as indexed + reads, are assumed to be in cache. The default value can be thought of + as modeling random access as 40 times slower than sequential, while + expecting 90% of random reads to be cached. +

If you believe a 90% cache rate is an incorrect assumption + for your workload, you can increase random_page_cost to better + reflect the true cost of random storage reads. Correspondingly, + if your data is likely to be completely in cache, such as when + the database is smaller than the total server memory, decreasing + random_page_cost can be appropriate. Storage that has a low random + read cost relative to sequential, e.g. solid-state drives, might + also be better modeled with a lower value for random_page_cost. +

Tip: Although the system will let you set random_page_cost to + less than seq_page_cost, it is not physically sensible + to do so. However, setting them equal makes sense if the database + is entirely cached in RAM, since in that case there is no penalty + for touching pages out of sequence. Also, in a heavily-cached + database you should lower both values relative to the CPU parameters, + since the cost of fetching a page already in RAM is much smaller + than it would normally be. +

cpu_tuple_cost (floating point)

Sets the planner's estimate of the cost of processing + each row during a query. + The default is 0.01. +

cpu_index_tuple_cost (floating point)

Sets the planner's estimate of the cost of processing + each index entry during an index scan. + The default is 0.005. +

cpu_operator_cost (floating point)

Sets the planner's estimate of the cost of processing each + operator or function executed during a query. + The default is 0.0025. +

effective_cache_size (integer)

Sets the planner's assumption about the effective size of the + disk cache that is available to a single query. This is + factored into estimates of the cost of using an index; a + higher value makes it more likely index scans will be used, a + lower value makes it more likely sequential scans will be + used. When setting this parameter you should consider both + PostgreSQL's shared buffers and the + portion of the kernel's disk cache that will be used for + PostgreSQL data files. Also, take + into account the expected number of concurrent queries on different + tables, since they will have to share the available + space. This parameter has no effect on the size of shared + memory allocated by PostgreSQL, nor + does it reserve kernel disk cache; it is used only for estimation + purposes. The system also does not assume data remains in + the disk cache between queries. The default is 128 megabytes + (128MB). +

18.7.3. Genetic Query Optimizer

The genetic query optimizer (GEQO) is an algorithm that does query + planning using heuristic searching. This reduces planning time for + complex queries (those joining many relations), at the cost of producing + plans that are sometimes inferior to those found by the normal + exhaustive-search algorithm. + For more information see Chapter 51. +

geqo (boolean)

Enables or disables genetic query optimization. + This is on by default. It is usually best not to turn it off in + production; the geqo_threshold variable provides + more granular control of GEQO. +

geqo_threshold (integer)

Use genetic query optimization to plan queries with at least + this many FROM items involved. (Note that a + FULL OUTER JOIN construct counts as only one FROM + item.) The default is 12. For simpler queries it is usually best + to use the regular, exhaustive-search planner, but for queries with + many tables the exhaustive search takes too long, often + longer than the penalty of executing a suboptimal plan. Thus, + a threshold on the size of the query is a convenient way to manage + use of GEQO. +

geqo_effort + (integer)

Controls the trade-off between planning time and query plan + quality in GEQO. This variable must be an integer in the + range from 1 to 10. The default value is five. Larger values + increase the time spent doing query planning, but also + increase the likelihood that an efficient query plan will be + chosen. +

geqo_effort doesn't actually do anything + directly; it is only used to compute the default values for + the other variables that influence GEQO behavior (described + below). If you prefer, you can set the other parameters by + hand instead. +

geqo_pool_size (integer)

Controls the pool size used by GEQO, that is the + number of individuals in the genetic population. It must be + at least two, and useful values are typically 100 to 1000. If + it is set to zero (the default setting) then a suitable + value is chosen based on geqo_effort and + the number of tables in the query. +

geqo_generations (integer)

Controls the number of generations used by GEQO, that is + the number of iterations of the algorithm. It must + be at least one, and useful values are in the same range as + the pool size. If it is set to zero (the default setting) + then a suitable value is chosen based on + geqo_pool_size. +

geqo_selection_bias (floating point)

Controls the selection bias used by GEQO. The selection bias + is the selective pressure within the population. Values can be + from 1.50 to 2.00; the latter is the default. +

geqo_seed (floating point)

Controls the initial value of the random number generator used + by GEQO to select random paths through the join order search space. + The value can range from zero (the default) to one. Varying the + value changes the set of join paths explored, and may result in a + better or worse best path being found. +

18.7.4. Other Planner Options

default_statistics_target (integer)

Sets the default statistics target for table columns without + a column-specific target set via ALTER TABLE + SET STATISTICS. Larger values increase the time needed to + do ANALYZE, but might improve the quality of the + planner's estimates. The default is 100. For more information + on the use of statistics by the PostgreSQL + query planner, refer to Section 14.2. +

constraint_exclusion (enum)

Controls the query planner's use of table constraints to + optimize queries. + The allowed values of constraint_exclusion are + on (examine constraints for all tables), + off (never examine constraints), and + partition (examine constraints only for inheritance child + tables and UNION ALL subqueries). + partition is the default setting. + It is often used with inheritance and partitioned tables to + improve performance. +

When this parameter allows it for a particular table, the planner + compares query conditions with the table's CHECK + constraints, and omits scanning tables for which the conditions + contradict the constraints. For example: + +

CREATE TABLE parent(key integer, ...);
+CREATE TABLE child1000(check (key between 1000 and 1999)) INHERITS(parent);
+CREATE TABLE child2000(check (key between 2000 and 2999)) INHERITS(parent);
+...
+SELECT * FROM parent WHERE key = 2400;

+ + With constraint exclusion enabled, this SELECT + will not scan child1000 at all, improving performance. +

Currently, constraint exclusion is enabled by default + only for cases that are often used to implement table partitioning. + Turning it on for all tables imposes extra planning overhead that is + quite noticeable on simple queries, and most often will yield no + benefit for simple queries. If you have no partitioned tables + you might prefer to turn it off entirely. +

Refer to Section 5.9.4 for + more information on using constraint exclusion and partitioning. +

cursor_tuple_fraction (floating point)

Sets the planner's estimate of the fraction of a cursor's rows that + will be retrieved. The default is 0.1. Smaller values of this + setting bias the planner towards using "fast start" plans + for cursors, which will retrieve the first few rows quickly while + perhaps taking a long time to fetch all rows. Larger values + put more emphasis on the total estimated time. At the maximum + setting of 1.0, cursors are planned exactly like regular queries, + considering only the total estimated time and not how soon the + first rows might be delivered. +

from_collapse_limit (integer)

The planner will merge sub-queries into upper queries if the + resulting FROM list would have no more than + this many items. Smaller values reduce planning time but might + yield inferior query plans. The default is eight. + For more information see Section 14.3. +

Setting this value to geqo_threshold or more + may trigger use of the GEQO planner, resulting in non-optimal + plans. See Section 18.7.3. +

join_collapse_limit (integer)

The planner will rewrite explicit JOIN + constructs (except FULL JOINs) into lists of + FROM items whenever a list of no more than this many items + would result. Smaller values reduce planning time but might + yield inferior query plans. +

By default, this variable is set the same as + from_collapse_limit, which is appropriate + for most uses. Setting it to 1 prevents any reordering of + explicit JOINs. Thus, the explicit join order + specified in the query will be the actual order in which the + relations are joined. Because the query planner does not always choose + the optimal join order, advanced users can elect to + temporarily set this variable to 1, and then specify the join + order they desire explicitly. + For more information see Section 14.3. +

Setting this value to geqo_threshold or more + may trigger use of the GEQO planner, resulting in non-optimal + plans. See Section 18.7.3. +


PrevHomeNext
ReplicationUpError Reporting and Logging
\ No newline at end of file diff --git a/doc/src/sgml/html/runtime-config-replication.html b/doc/src/sgml/html/runtime-config-replication.html new file mode 100644 index 000000000..9ba9bf4d1 --- /dev/null +++ b/doc/src/sgml/html/runtime-config-replication.html @@ -0,0 +1,742 @@ + +Replication
PostgreSQL 9.2.2 Documentation
PrevUpChapter 18. Server ConfigurationNext

18.6. Replication

These settings control the behavior of the built-in + streaming replication feature (see + Section 25.2.5). Servers will be either a + Master or a Standby server. Masters can send data, while Standby(s) + are always receivers of replicated data. When cascading replication + (see Section 25.2.6) is used, Standby server(s) + can also be senders, as well as receivers. + Parameters are mainly for Sending and Standby servers, though some + parameters have meaning only on the Master server. Settings may vary + across the cluster without problems if that is required. +

18.6.1. Sending Server(s)

These parameters can be set on any server that is + to send replication data to one or more standby servers. + The master is always a sending server, so these parameters must + always be set on the master. + The role and meaning of these parameters does not change after a + standby becomes the master. +

max_wal_senders (integer)

Specifies the maximum number of concurrent connections from + standby servers or streaming base backup clients (i.e., the + maximum number of simultaneously running WAL sender + processes). The default is zero, meaning replication is + disabled. WAL sender processes count towards the total number + of connections, so the parameter cannot be set higher than + max_connections. This parameter can only + be set at server start. wal_level must be set + to archive or hot_standby to allow + connections from standby servers. +

wal_keep_segments (integer)

Specifies the minimum number of past log file segments kept in the + pg_xlog + directory, in case a standby server needs to fetch them for streaming + replication. Each segment is normally 16 megabytes. If a standby + server connected to the sending server falls behind by more than + wal_keep_segments segments, the sending server might remove + a WAL segment still needed by the standby, in which case the + replication connection will be terminated. Downstream connections + will also eventually fail as a result. (However, the standby + server can recover by fetching the segment from archive, if WAL + archiving is in use.) +

This sets only the minimum number of segments retained in + pg_xlog; the system might need to retain more segments + for WAL archival or to recover from a checkpoint. If + wal_keep_segments is zero (the default), the system + doesn't keep any extra segments for standby purposes, so the number + of old WAL segments available to standby servers is a function of + the location of the previous checkpoint and status of WAL + archiving. + This parameter can only be set in the + postgresql.conf file or on the server command line. +

replication_timeout (integer)

Terminate replication connections that are inactive longer + than the specified number of milliseconds. This is useful for + the sending server to detect a standby crash or network outage. + A value of zero disables the timeout mechanism. This parameter + can only be set in + the postgresql.conf file or on the server command line. + The default value is 60 seconds. +

To prevent connections from being terminated prematurely, + wal_receiver_status_interval + must be enabled on the standby, and its value must be less than the + value of replication_timeout. +

18.6.2. Master Server

These parameters can be set on the master/primary server that is + to send replication data to one or more standby servers. + Note that in addition to these parameters, + wal_level must be set appropriately on the master + server, and optionally WAL archiving can be enabled as + well (see Section 18.5.3). + The values of these parameters on standby servers are irrelevant, + although you may wish to set them there in preparation for the + possibility of a standby becoming the master. +

synchronous_standby_names (string)

Specifies a comma-separated list of standby names that can support + synchronous replication, as described in + Section 25.2.7. + At any one time there will be at most one active synchronous standby; + transactions waiting for commit will be allowed to proceed after + this standby server confirms receipt of their data. + The synchronous standby will be the first standby named in this list + that is both currently connected and streaming data in real-time + (as shown by a state of streaming in the + pg_stat_replication view). + Other standby servers appearing later in this list represent potential + synchronous standbys. + If the current synchronous standby disconnects for whatever reason, + it will be replaced immediately with the next-highest-priority standby. + Specifying more than one standby name can allow very high availability. +

The name of a standby server for this purpose is the + application_name setting of the standby, as set in the + primary_conninfo of the standby's walreceiver. There is + no mechanism to enforce uniqueness. In case of duplicates one of the + matching standbys will be chosen to be the synchronous standby, though + exactly which one is indeterminate. + The special entry * matches any + application_name, including the default application name + of walreceiver. +

If no synchronous standby names are specified here, then synchronous + replication is not enabled and transaction commits will not wait for + replication. This is the default configuration. Even when + synchronous replication is enabled, individual transactions can be + configured not to wait for replication by setting the + synchronous_commit parameter to + local or off. +

This parameter can only be set in the postgresql.conf + file or on the server command line. +

vacuum_defer_cleanup_age (integer)

Specifies the number of transactions by which VACUUM and + HOT updates will defer cleanup of dead row versions. The + default is zero transactions, meaning that dead row versions can be + removed as soon as possible, that is, as soon as they are no longer + visible to any open transaction. You may wish to set this to a + non-zero value on a primary server that is supporting hot standby + servers, as described in Section 25.5. This allows + more time for queries on the standby to complete without incurring + conflicts due to early cleanup of rows. However, since the value + is measured in terms of number of write transactions occurring on the + primary server, it is difficult to predict just how much additional + grace time will be made available to standby queries. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

You should also consider setting hot_standby_feedback + on standby server(s) as an alternative to using this parameter. +

18.6.3. Standby Servers

These settings control the behavior of a standby server that is + to receive replication data. Their values on the master server + are irrelevant. +

hot_standby (boolean)

Specifies whether or not you can connect and run queries during + recovery, as described in Section 25.5. + The default value is off. + This parameter can only be set at server start. It only has effect + during archive recovery or in standby mode. +

max_standby_archive_delay (integer)

When Hot Standby is active, this parameter determines how long the + standby server should wait before canceling standby queries that + conflict with about-to-be-applied WAL entries, as described in + Section 25.5.2. + max_standby_archive_delay applies when WAL data is + being read from WAL archive (and is therefore not current). + The default is 30 seconds. Units are milliseconds if not specified. + A value of -1 allows the standby to wait forever for conflicting + queries to complete. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

Note that max_standby_archive_delay is not the same as the + maximum length of time a query can run before cancellation; rather it + is the maximum total time allowed to apply any one WAL segment's data. + Thus, if one query has resulted in significant delay earlier in the + WAL segment, subsequent conflicting queries will have much less grace + time. +

max_standby_streaming_delay (integer)

When Hot Standby is active, this parameter determines how long the + standby server should wait before canceling standby queries that + conflict with about-to-be-applied WAL entries, as described in + Section 25.5.2. + max_standby_streaming_delay applies when WAL data is + being received via streaming replication. + The default is 30 seconds. Units are milliseconds if not specified. + A value of -1 allows the standby to wait forever for conflicting + queries to complete. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

Note that max_standby_streaming_delay is not the same as + the maximum length of time a query can run before cancellation; rather + it is the maximum total time allowed to apply WAL data once it has + been received from the primary server. Thus, if one query has + resulted in significant delay, subsequent conflicting queries will + have much less grace time until the standby server has caught up + again. +

wal_receiver_status_interval (integer)

Specifies the minimum frequency for the WAL receiver + process on the standby to send information about replication progress + to the primary or upstream standby, where it can be seen using the + pg_stat_replication view. The standby will report + the last transaction log position it has written, the last position it + has flushed to disk, and the last position it has applied. + This parameter's + value is the maximum interval, in seconds, between reports. Updates are + sent each time the write or flush positions change, or at least as + often as specified by this parameter. Thus, the apply position may + lag slightly behind the true position. Setting this parameter to zero + disables status updates completely. This parameter can only be set in + the postgresql.conf file or on the server command line. + The default value is 10 seconds. +

When replication_timeout is enabled on a sending server, + wal_receiver_status_interval must be enabled, and its value + must be less than the value of replication_timeout. +

hot_standby_feedback (boolean)

Specifies whether or not a hot standby will send feedback to the primary + or upstream standby + about queries currently executing on the standby. This parameter can + be used to eliminate query cancels caused by cleanup records, but + can cause database bloat on the primary for some workloads. + Feedback messages will not be sent more frequently than once per + wal_receiver_status_interval. The default value is + off. This parameter can only be set in the + postgresql.conf file or on the server command line. +

If cascaded replication is in use the feedback is passed upstream + until it eventually reaches the primary. Standbys make no other use + of feedback they receive other than to pass upstream. +


PrevHomeNext
Write Ahead LogUpQuery Planning
\ No newline at end of file diff --git a/doc/src/sgml/html/runtime-config-resource.html b/doc/src/sgml/html/runtime-config-resource.html new file mode 100644 index 000000000..a46d25f76 --- /dev/null +++ b/doc/src/sgml/html/runtime-config-resource.html @@ -0,0 +1,1155 @@ + +Resource Consumption
PostgreSQL 9.2.2 Documentation
PrevUpChapter 18. Server ConfigurationNext

18.4. Resource Consumption

18.4.1. Memory

shared_buffers (integer)

Sets the amount of memory the database server uses for shared + memory buffers. The default is typically 32 megabytes + (32MB), but might be less if your kernel settings will + not support it (as determined during initdb). + This setting must be at least 128 kilobytes. (Non-default + values of BLCKSZ change the minimum.) However, + settings significantly higher than the minimum are usually needed + for good performance. This parameter can only be set at server start. +

If you have a dedicated database server with 1GB or more of RAM, a + reasonable starting value for shared_buffers is 25% + of the memory in your system. There are some workloads where even + large settings for shared_buffers are effective, but + because PostgreSQL also relies on the + operating system cache, it is unlikely that an allocation of more than + 40% of RAM to shared_buffers will work better than a + smaller amount. Larger settings for shared_buffers + usually require a corresponding increase in + checkpoint_segments, in order to spread out the + process of writing large quantities of new or changed data over a + longer period of time. +

On systems with less than 1GB of RAM, a smaller percentage of RAM is + appropriate, so as to leave adequate space for the operating system. + Also, on Windows, large values for shared_buffers + aren't as effective. You may find better results keeping the setting + relatively low and using the operating system cache more instead. The + useful range for shared_buffers on Windows systems + is generally from 64MB to 512MB. +

Increasing this parameter might cause PostgreSQL + to request more System V shared + memory than your operating system's default configuration + allows. See Section 17.4.1 for information on how to + adjust those parameters, if necessary. +

temp_buffers (integer)

Sets the maximum number of temporary buffers used by each database + session. These are session-local buffers used only for access to + temporary tables. The default is eight megabytes + (8MB). The setting can be changed within individual + sessions, but only before the first use of temporary tables + within the session; subsequent attempts to change the value will + have no effect on that session. +

A session will allocate temporary buffers as needed up to the limit + given by temp_buffers. The cost of setting a large + value in sessions that do not actually need many temporary + buffers is only a buffer descriptor, or about 64 bytes, per + increment in temp_buffers. However if a buffer is + actually used an additional 8192 bytes will be consumed for it + (or in general, BLCKSZ bytes). +

max_prepared_transactions (integer)

Sets the maximum number of transactions that can be in the + "prepared" state simultaneously (see PREPARE TRANSACTION). + Setting this parameter to zero (which is the default) + disables the prepared-transaction feature. + This parameter can only be set at server start. +

If you are not planning to use prepared transactions, this parameter + should be set to zero to prevent accidental creation of prepared + transactions. If you are using prepared transactions, you will + probably want max_prepared_transactions to be at + least as large as max_connections, so that every + session can have a prepared transaction pending. +

Increasing this parameter might cause PostgreSQL + to request more System V shared + memory than your operating system's default configuration + allows. See Section 17.4.1 for information on how to + adjust those parameters, if necessary. +

When running a standby server, you must set this parameter to the + same or higher value than on the master server. Otherwise, queries + will not be allowed in the standby server. +

work_mem (integer)

Specifies the amount of memory to be used by internal sort operations + and hash tables before writing to temporary disk files. The value + defaults to one megabyte (1MB). + Note that for a complex query, several sort or hash operations might be + running in parallel; each operation will be allowed to use as much memory + as this value specifies before it starts to write data into temporary + files. Also, several running sessions could be doing such operations + concurrently. Therefore, the total memory used could be many + times the value of work_mem; it is necessary to + keep this fact in mind when choosing the value. Sort operations are + used for ORDER BY, DISTINCT, and + merge joins. + Hash tables are used in hash joins, hash-based aggregation, and + hash-based processing of IN subqueries. +

maintenance_work_mem (integer)

Specifies the maximum amount of memory to be used by maintenance + operations, such as VACUUM, CREATE + INDEX, and ALTER TABLE ADD FOREIGN KEY. It defaults + to 16 megabytes (16MB). Since only one of these + operations can be executed at a time by a database session, and + an installation normally doesn't have many of them running + concurrently, it's safe to set this value significantly larger + than work_mem. Larger settings might improve + performance for vacuuming and for restoring database dumps. +

Note that when autovacuum runs, up to + autovacuum_max_workers times this memory may be + allocated, so be careful not to set the default value too high. +

max_stack_depth (integer)

Specifies the maximum safe depth of the server's execution stack. + The ideal setting for this parameter is the actual stack size limit + enforced by the kernel (as set by ulimit -s or local + equivalent), less a safety margin of a megabyte or so. The safety + margin is needed because the stack depth is not checked in every + routine in the server, but only in key potentially-recursive routines + such as expression evaluation. The default setting is two + megabytes (2MB), which is conservatively small and + unlikely to risk crashes. However, it might be too small to allow + execution of complex functions. Only superusers can change this + setting. +

Setting max_stack_depth higher than + the actual kernel limit will mean that a runaway recursive function + can crash an individual backend process. On platforms where + PostgreSQL can determine the kernel limit, + the server will not allow this variable to be set to an unsafe + value. However, not all platforms provide the information, + so caution is recommended in selecting a value. +

18.4.2. Disk

temp_file_limit (integer)

Specifies the maximum amount of disk space that a session can use + for temporary files, such as sort and hash temporary files, or the + storage file for a held cursor. A transaction attempting to exceed + this limit will be cancelled. + The value is specified in kilobytes, and -1 (the + default) means no limit. + Only superusers can change this setting. +

This setting constrains the total space used at any instant by all + temporary files used by a given PostgreSQL session. + It should be noted that disk space used for explicit temporary + tables, as opposed to temporary files used behind-the-scenes in query + execution, does not count against this limit. +

18.4.3. Kernel Resource Usage

max_files_per_process (integer)

Sets the maximum number of simultaneously open files allowed to each + server subprocess. The default is one thousand files. If the kernel is enforcing + a safe per-process limit, you don't need to worry about this setting. + But on some platforms (notably, most BSD systems), the kernel will + allow individual processes to open many more files than the system + can actually support if many processes all try to open + that many files. If you find yourself seeing "Too many open + files" failures, try reducing this setting. + This parameter can only be set at server start. +

shared_preload_libraries (string)

This variable specifies one or more shared libraries + to be preloaded at server start. For example, + '$libdir/mylib' would cause + mylib.so (or on some platforms, + mylib.sl) to be preloaded from the installation's + standard library directory. + All library names are converted to lower case unless double-quoted. + If more than one library is to be loaded, separate their names + with commas. This parameter can only be set at server start. +

PostgreSQL procedural language + libraries can be preloaded in this way, typically by using the + syntax '$libdir/plXXX' where + XXX is pgsql, perl, + tcl, or python. +

By preloading a shared library, the library startup time is avoided + when the library is first used. However, the time to start each new + server process might increase slightly, even if that process never + uses the library. So this parameter is recommended only for + libraries that will be used in most sessions. +

Note: On Windows hosts, preloading a library at server start will not reduce + the time required to start each new server process; each server process + will re-load all preload libraries. However, shared_preload_libraries + is still useful on Windows hosts because some shared libraries may + need to perform certain operations that only take place at postmaster start + (for example, a shared library may need to reserve lightweight locks + or shared memory and you can't do that after the postmaster has started). +

If a specified library is not found, + the server will fail to start. +

Every PostgreSQL-supported library has a "magic + block" that is checked to guarantee compatibility. + For this reason, non-PostgreSQL libraries cannot be + loaded in this way. +

18.4.4. Cost-based Vacuum Delay

During the execution of VACUUM + and ANALYZE + commands, the system maintains an + internal counter that keeps track of the estimated cost of the + various I/O operations that are performed. When the accumulated + cost reaches a limit (specified by + vacuum_cost_limit), the process performing + the operation will sleep for a short period of time, as specified by + vacuum_cost_delay. Then it will reset the + counter and continue execution. +

The intent of this feature is to allow administrators to reduce + the I/O impact of these commands on concurrent database + activity. There are many situations where it is not + important that maintenance commands like + VACUUM and ANALYZE finish + quickly; however, it is usually very important that these + commands do not significantly interfere with the ability of the + system to perform other database operations. Cost-based vacuum + delay provides a way for administrators to achieve this. +

This feature is disabled by default for manually issued + VACUUM commands. To enable it, set the + vacuum_cost_delay variable to a nonzero + value. +

vacuum_cost_delay (integer)

The length of time, in milliseconds, that the process will sleep + when the cost limit has been exceeded. + The default value is zero, which disables the cost-based vacuum + delay feature. Positive values enable cost-based vacuuming. + Note that on many systems, the effective resolution + of sleep delays is 10 milliseconds; setting + vacuum_cost_delay to a value that is + not a multiple of 10 might have the same results as setting it + to the next higher multiple of 10. +

When using cost-based vacuuming, appropriate values for + vacuum_cost_delay are usually quite small, perhaps + 10 or 20 milliseconds. Adjusting vacuum's resource consumption + is best done by changing the other vacuum cost parameters. +

vacuum_cost_page_hit (integer)

The estimated cost for vacuuming a buffer found in the shared buffer + cache. It represents the cost to lock the buffer pool, lookup + the shared hash table and scan the content of the page. The + default value is one. +

vacuum_cost_page_miss (integer)

The estimated cost for vacuuming a buffer that has to be read from + disk. This represents the effort to lock the buffer pool, + lookup the shared hash table, read the desired block in from + the disk and scan its content. The default value is 10. +

vacuum_cost_page_dirty (integer)

The estimated cost charged when vacuum modifies a block that was + previously clean. It represents the extra I/O required to + flush the dirty block out to disk again. The default value is + 20. +

vacuum_cost_limit (integer)

The accumulated cost that will cause the vacuuming process to sleep. + The default value is 200. +

Note: There are certain operations that hold critical locks and should + therefore complete as quickly as possible. Cost-based vacuum + delays do not occur during such operations. Therefore it is + possible that the cost accumulates far higher than the specified + limit. To avoid uselessly long delays in such cases, the actual + delay is calculated as vacuum_cost_delay * + accumulated_balance / + vacuum_cost_limit with a maximum of + vacuum_cost_delay * 4. +

18.4.5. Background Writer

There is a separate server + process called the background writer, whose function + is to issue writes of "dirty" (new or modified) shared + buffers. It writes shared buffers so server processes handling + user queries seldom or never need to wait for a write to occur. + However, the background writer does cause a net overall + increase in I/O load, because while a repeatedly-dirtied page might + otherwise be written only once per checkpoint interval, the + background writer might write it several times as it is dirtied + in the same interval. The parameters discussed in this subsection + can be used to tune the behavior for local needs. +

bgwriter_delay (integer)

Specifies the delay between activity rounds for the + background writer. In each round the writer issues writes + for some number of dirty buffers (controllable by the + following parameters). It then sleeps for bgwriter_delay + milliseconds, and repeats. When there are no dirty buffers in the + buffer pool, though, it goes into a longer sleep regardless of + bgwriter_delay. The default value is 200 + milliseconds (200ms). Note that on many systems, the + effective resolution of sleep delays is 10 milliseconds; setting + bgwriter_delay to a value that is not a multiple of 10 + might have the same results as setting it to the next higher multiple + of 10. This parameter can only be set in the + postgresql.conf file or on the server command line. +

bgwriter_lru_maxpages (integer)

In each round, no more than this many buffers will be written + by the background writer. Setting this to zero disables + background writing. (Note that checkpoints, which are managed by + a separate, dedicated auxiliary process, are unaffected.) + The default value is 100 buffers. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

bgwriter_lru_multiplier (floating point)

The number of dirty buffers written in each round is based on the + number of new buffers that have been needed by server processes + during recent rounds. The average recent need is multiplied by + bgwriter_lru_multiplier to arrive at an estimate of the + number of buffers that will be needed during the next round. Dirty + buffers are written until there are that many clean, reusable buffers + available. (However, no more than bgwriter_lru_maxpages + buffers will be written per round.) + Thus, a setting of 1.0 represents a "just in time" policy + of writing exactly the number of buffers predicted to be needed. + Larger values provide some cushion against spikes in demand, + while smaller values intentionally leave writes to be done by + server processes. + The default is 2.0. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

Smaller values of bgwriter_lru_maxpages and + bgwriter_lru_multiplier reduce the extra I/O load + caused by the background writer, but make it more likely that server + processes will have to issue writes for themselves, delaying interactive + queries. +

18.4.6. Asynchronous Behavior

effective_io_concurrency (integer)

Sets the number of concurrent disk I/O operations that + PostgreSQL expects can be executed + simultaneously. Raising this value will increase the number of I/O + operations that any individual PostgreSQL session + attempts to initiate in parallel. The allowed range is 1 to 1000, + or zero to disable issuance of asynchronous I/O requests. Currently, + this setting only affects bitmap heap scans. +

A good starting point for this setting is the number of separate + drives comprising a RAID 0 stripe or RAID 1 mirror being used for the + database. (For RAID 5 the parity drive should not be counted.) + However, if the database is often busy with multiple queries issued in + concurrent sessions, lower values may be sufficient to keep the disk + array busy. A value higher than needed to keep the disks busy will + only result in extra CPU overhead. +

For more exotic systems, such as memory-based storage or a RAID array + that is limited by bus bandwidth, the correct value might be the + number of I/O paths available. Some experimentation may be needed + to find the best value. +

Asynchronous I/O depends on an effective posix_fadvise + function, which some operating systems lack. If the function is not + present then setting this parameter to anything but zero will result + in an error. On some operating systems (e.g., Solaris), the function + is present but does not actually do anything. +


PrevHomeNext
Connections and AuthenticationUpWrite Ahead Log
\ No newline at end of file diff --git a/doc/src/sgml/html/runtime-config-short.html b/doc/src/sgml/html/runtime-config-short.html new file mode 100644 index 000000000..187fab1f3 --- /dev/null +++ b/doc/src/sgml/html/runtime-config-short.html @@ -0,0 +1,571 @@ + +Short Options
PostgreSQL 9.2.2 Documentation
PrevUpChapter 18. Server ConfigurationNext

18.18. Short Options

For convenience there are also single letter command-line option + switches available for some parameters. They are described in + Table 18-2. Some of these + options exist for historical reasons, and their presence as a + single-letter option does not necessarily indicate an endorsement + to use the option heavily. +

Table 18-2. Short Option Key

Short OptionEquivalent
-A xdebug_assertions = x
-B xshared_buffers = x
-d xlog_min_messages = DEBUGx
-edatestyle = euro
-fb, -fh, -fi, + -fm, -fn, -fo, + -fs, -ft + enable_bitmapscan = off, + enable_hashjoin = off, + enable_indexscan = off, + enable_mergejoin = off, + enable_nestloop = off, + enable_indexonlyscan = off, + enable_seqscan = off, + enable_tidscan = off +
-Ffsync = off
-h xlisten_addresses = x
-ilisten_addresses = '*'
-k xunix_socket_directory = x
-lssl = on
-N xmax_connections = x
-Oallow_system_table_mods = on
-p xport = x
-Pignore_system_indexes = on
-slog_statement_stats = on
-S xwork_mem = x
-tpa, -tpl, -telog_parser_stats = on, + log_planner_stats = on, + log_executor_stats = on
-W xpost_auth_delay = x

PrevHomeNext
Developer OptionsUpClient Authentication
\ No newline at end of file diff --git a/doc/src/sgml/html/runtime-config-statistics.html b/doc/src/sgml/html/runtime-config-statistics.html new file mode 100644 index 000000000..55bc02e43 --- /dev/null +++ b/doc/src/sgml/html/runtime-config-statistics.html @@ -0,0 +1,468 @@ + +Run-time Statistics
PostgreSQL 9.2.2 Documentation
PrevUpChapter 18. Server ConfigurationNext

18.9. Run-time Statistics

18.9.1. Query and Index Statistics Collector

These parameters control server-wide statistics collection features. + When statistics collection is enabled, the data that is produced can be + accessed via the pg_stat and + pg_statio family of system views. + Refer to Chapter 27 for more information. +

track_activities (boolean)

Enables the collection of information on the currently + executing command of each session, along with the time when + that command began execution. This parameter is on by + default. Note that even when enabled, this information is not + visible to all users, only to superusers and the user owning + the session being reported on, so it should not represent a + security risk. + Only superusers can change this setting. +

track_activity_query_size (integer)

Specifies the number of bytes reserved to track the currently + executing command for each active session, for the + pg_stat_activity.query field. + The default value is 1024. This parameter can only be set at server + start. +

track_counts (boolean)

Enables collection of statistics on database activity. + This parameter is on by default, because the autovacuum + daemon needs the collected information. + Only superusers can change this setting. +

track_io_timing (boolean)

Enables timing of database I/O calls. This parameter is off by + default, because it will repeatedly query the operating system for + the current time, which may cause significant overhead on some + platforms. You can use the pg_test_timing tool to + measure the overhead of timing on your system. + I/O timing information is + displayed in pg_stat_database, in the output of + EXPLAIN when the BUFFERS option is + used, and by pg_stat_statements. Only superusers can + change this setting. +

track_functions (enum)

Enables tracking of function call counts and time used. Specify + pl to track only procedural-language functions, + all to also track SQL and C language functions. + The default is none, which disables function + statistics tracking. Only superusers can change this setting. +

Note: SQL-language functions that are simple enough to be "inlined" + into the calling query will not be tracked, regardless of this + setting. +

update_process_title (boolean)

Enables updating of the process title every time a new SQL command + is received by the server. The process title is typically viewed + by the ps command, + or in Windows by using the Process Explorer. + Only superusers can change this setting. +

stats_temp_directory (string)

Sets the directory to store temporary statistics data in. This can be + a path relative to the data directory or an absolute path. The default + is pg_stat_tmp. Pointing this at a RAM-based + file system will decrease physical I/O requirements and can lead to + improved performance. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

18.9.2. Statistics Monitoring

log_statement_stats (boolean)
log_parser_stats (boolean)
log_planner_stats (boolean)
log_executor_stats (boolean)

For each query, output performance statistics of the respective + module to the server log. This is a crude profiling + instrument, similar to the Unix getrusage() operating + system facility. log_statement_stats reports total + statement statistics, while the others report per-module statistics. + log_statement_stats cannot be enabled together with + any of the per-module options. All of these options are disabled by + default. Only superusers can change these settings. +


PrevHomeNext
Error Reporting and LoggingUpAutomatic Vacuuming
\ No newline at end of file diff --git a/doc/src/sgml/html/runtime-config-wal.html b/doc/src/sgml/html/runtime-config-wal.html new file mode 100644 index 000000000..81611d81e --- /dev/null +++ b/doc/src/sgml/html/runtime-config-wal.html @@ -0,0 +1,1203 @@ + +Write Ahead Log
PostgreSQL 9.2.2 Documentation
PrevUpChapter 18. Server ConfigurationNext

18.5. Write Ahead Log

See also Section 29.4 for details on WAL + and checkpoint tuning. +

18.5.1. Settings

wal_level (enum)

wal_level determines how much information is written + to the WAL. The default value is minimal, which writes + only the information needed to recover from a crash or immediate + shutdown. archive adds logging required for WAL archiving, + and hot_standby further adds information required to run + read-only queries on a standby server. + This parameter can only be set at server start. +

In minimal level, WAL-logging of some bulk + operations can be safely skipped, which can make those + operations much faster (see Section 14.4.7). + Operations in which this optimization can be applied include: +

CREATE TABLE AS
CREATE INDEX
CLUSTER
COPY into tables that were created or truncated in the same + transaction

+ But minimal WAL does not contain + enough information to reconstruct the data from a base backup and the + WAL logs, so either archive or hot_standby + level must be used to enable + WAL archiving (archive_mode) and streaming + replication. +

In hot_standby level, the same information is logged as + with archive, plus information needed to reconstruct + the status of running transactions from the WAL. To enable read-only + queries on a standby server, wal_level must be set to + hot_standby on the primary, and + hot_standby must be enabled in the standby. It is + thought that there is + little measurable difference in performance between using + hot_standby and archive levels, so feedback + is welcome if any production impacts are noticeable. +

fsync (boolean)

If this parameter is on, the PostgreSQL server + will try to make sure that updates are physically written to + disk, by issuing fsync() system calls or various + equivalent methods (see wal_sync_method). + This ensures that the database cluster can recover to a + consistent state after an operating system or hardware crash. +

While turning off fsync is often a performance + benefit, this can result in unrecoverable data corruption in + the event of a power failure or system crash. Thus it + is only advisable to turn off fsync if + you can easily recreate your entire database from external + data. +

Examples of safe circumstances for turning off + fsync include the initial loading of a new + database cluster from a backup file, using a database cluster + for processing a batch of data after which the database + will be thrown away and recreated, + or for a read-only database clone which + gets recreated frequently and is not used for failover. High + quality hardware alone is not a sufficient justification for + turning off fsync. +

In many situations, turning off synchronous_commit + for noncritical transactions can provide much of the potential + performance benefit of turning off fsync, without + the attendant risks of data corruption. +

fsync can only be set in the postgresql.conf + file or on the server command line. + If you turn this parameter off, also consider turning off + full_page_writes. +

synchronous_commit (enum)

Specifies whether transaction commit will wait for WAL records + to be written to disk before the command returns a "success" + indication to the client. Valid values are on, + remote_write, local, and off. + The default, and safe, setting + is on. When off, there can be a delay between + when success is reported to the client and when the transaction is + really guaranteed to be safe against a server crash. (The maximum + delay is three times wal_writer_delay.) Unlike + fsync, setting this parameter to off + does not create any risk of database inconsistency: an operating + system or database crash might + result in some recent allegedly-committed transactions being lost, but + the database state will be just the same as if those transactions had + been aborted cleanly. So, turning synchronous_commit off + can be a useful alternative when performance is more important than + exact certainty about the durability of a transaction. For more + discussion see Section 29.3. +

If synchronous_standby_names is set, this + parameter also controls whether or not transaction commits will wait + for the transaction's WAL records to be replicated to the standby + server. + When set to on, commits will wait until a reply + from the current synchronous standby indicates it has received + the commit record of the transaction and flushed it to disk. This + ensures the transaction will not be lost unless both primary and + standby suffer corruption of their database storage. + When set to remote_write, commits will wait + until a reply from the current synchronous standby indicates it has + received the commit record of the transaction and written it out to + the standby's operating system, but the data has not necessarily + reached stable storage on the standby. This setting is sufficient to + ensure data preservation even if the standby instance of + PostgreSQL were to crash, but not if the standby + suffers an operating-system-level crash. +

When synchronous + replication is in use, it will normally be sensible either to wait + for both local flush to disk and replication of WAL records, or + to allow the transaction to commit asynchronously. However, the + setting local is available for transactions that + wish to wait for local flush to disk, but not synchronous replication. + If synchronous_standby_names is not set, the settings + on, remote_write and local all + provide the same synchronization level: transaction commits only wait + for local flush to disk. +

This parameter can be changed at any time; the behavior for any + one transaction is determined by the setting in effect when it + commits. It is therefore possible, and useful, to have some + transactions commit synchronously and others asynchronously. + For example, to make a single multistatement transaction commit + asynchronously when the default is the opposite, issue SET + LOCAL synchronous_commit TO OFF within the transaction. +

wal_sync_method (enum)

Method used for forcing WAL updates out to disk. + If fsync is off then this setting is irrelevant, + since WAL file updates will not be forced out at all. + Possible values are: +

  • open_datasync (write WAL files with open() option O_DSYNC) +

  • fdatasync (call fdatasync() at each commit) +

  • fsync (call fsync() at each commit) +

  • fsync_writethrough (call fsync() at each commit, forcing write-through of any disk write cache) +

  • open_sync (write WAL files with open() option O_SYNC) +

The open_* options also use O_DIRECT if available. + Not all of these choices are available on all platforms. + The default is the first method in the above list that is supported + by the platform, except that fdatasync is the default on + Linux. The default is not necessarily ideal; it might be + necessary to change this setting or other aspects of your system + configuration in order to create a crash-safe configuration or + achieve optimal performance. + These aspects are discussed in Section 29.1. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

full_page_writes (boolean)

When this parameter is on, the PostgreSQL server + writes the entire content of each disk page to WAL during the + first modification of that page after a checkpoint. + This is needed because + a page write that is in process during an operating system crash might + be only partially completed, leading to an on-disk page + that contains a mix of old and new data. The row-level change data + normally stored in WAL will not be enough to completely restore + such a page during post-crash recovery. Storing the full page image + guarantees that the page can be correctly restored, but at the price + of increasing the amount of data that must be written to WAL. + (Because WAL replay always starts from a checkpoint, it is sufficient + to do this during the first change of each page after a checkpoint. + Therefore, one way to reduce the cost of full-page writes is to + increase the checkpoint interval parameters.) +

Turning this parameter off speeds normal operation, but + might lead to either unrecoverable data corruption, or silent + data corruption, after a system failure. The risks are similar to turning off + fsync, though smaller, and it should be turned off + only based on the same circumstances recommended for that parameter. +

Turning off this parameter does not affect use of + WAL archiving for point-in-time recovery (PITR) + (see Section 24.3). +

This parameter can only be set in the postgresql.conf + file or on the server command line. + The default is on. +

wal_buffers (integer)

The amount of shared memory used for WAL data that has not yet been + written to disk. The default setting of -1 selects a size equal to + 1/32nd (about 3%) of shared_buffers, but not less + than 64kB nor more than the size of one WAL + segment, typically 16MB. This value can be set + manually if the automatic choice is too large or too small, + but any positive value less than 32kB will be + treated as 32kB. + This parameter can only be set at server start. +

The contents of the WAL buffers are written out to disk at every + transaction commit, so extremely large values are unlikely to + provide a significant benefit. However, setting this value to at + least a few megabytes can improve write performance on a busy + server where many clients are committing at once. The auto-tuning + selected by the default setting of -1 should give reasonable + results in most cases. +

Increasing this parameter might cause PostgreSQL + to request more System V shared + memory than your operating system's default configuration + allows. See Section 17.4.1 for information on how to + adjust those parameters, if necessary. +

wal_writer_delay (integer)

Specifies the delay between activity rounds for the WAL writer. + In each round the writer will flush WAL to disk. It then sleeps for + wal_writer_delay milliseconds, and repeats. The default + value is 200 milliseconds (200ms). Note that on many + systems, the effective resolution of sleep delays is 10 milliseconds; + setting wal_writer_delay to a value that is not a multiple + of 10 might have the same results as setting it to the next higher + multiple of 10. This parameter can only be set in the + postgresql.conf file or on the server command line. +

commit_delay (integer)

When the commit data for a transaction is flushed to disk, any + additional commits ready at that time are also flushed out. + commit_delay adds a time delay, set in + microseconds, before a transaction attempts to + flush the WAL buffer out to disk. A nonzero delay can allow more + transactions to be committed with only one flush operation, if + system load is high enough that additional transactions become + ready to commit within the given interval. But the delay is + just wasted if no other transactions become ready to + commit. Therefore, the delay is only performed if at least + commit_siblings other transactions are + active at the instant that a server process has written its + commit record. + The default commit_delay is zero (no delay). + Since all pending commit data will be written at every flush + regardless of this setting, it is rare that adding delay + by increasing this parameter will actually improve performance. +

commit_siblings (integer)

Minimum number of concurrent open transactions to require + before performing the commit_delay delay. A larger + value makes it more probable that at least one other + transaction will become ready to commit during the delay + interval. The default is five transactions. +

18.5.2. Checkpoints

checkpoint_segments (integer)

Maximum number of log file segments between automatic WAL + checkpoints (each segment is normally 16 megabytes). The default + is three segments. Increasing this parameter can increase the + amount of time needed for crash recovery. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

checkpoint_timeout (integer)

Maximum time between automatic WAL checkpoints, in + seconds. The default is five minutes (5min). + Increasing this parameter can increase the amount of time needed + for crash recovery. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

checkpoint_completion_target (floating point)

Specifies the target of checkpoint completion, as a fraction of + total time between checkpoints. The default is 0.5. + + This parameter can only be set in the postgresql.conf + file or on the server command line. +

checkpoint_warning (integer)

Write a message to the server log if checkpoints caused by + the filling of checkpoint segment files happen closer together + than this many seconds (which suggests that + checkpoint_segments ought to be raised). The default is + 30 seconds (30s). Zero disables the warning. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

18.5.3. Archiving

archive_mode (boolean)

When archive_mode is enabled, completed WAL segments + are sent to archive storage by setting + archive_command. + archive_mode and archive_command are + separate variables so that archive_command can be + changed without leaving archiving mode. + This parameter can only be set at server start. + archive_mode cannot be enabled when + wal_level is set to minimal. +

archive_command (string)

The shell command to execute to archive a completed WAL file + segment. Any %p in the string is + replaced by the path name of the file to archive, and any + %f is replaced by only the file name. + (The path name is relative to the working directory of the server, + i.e., the cluster's data directory.) + Use %% to embed an actual % character in the + command. It is important for the command to return a zero + exit status only if it succeeds. For more information see + Section 24.3.1. +

This parameter can only be set in the postgresql.conf + file or on the server command line. It is ignored unless + archive_mode was enabled at server start. + If archive_command is an empty string (the default) while + archive_mode is enabled, WAL archiving is temporarily + disabled, but the server continues to accumulate WAL segment files in + the expectation that a command will soon be provided. Setting + archive_command to a command that does nothing but + return true, e.g. /bin/true (REM on + Windows), effectively disables + archiving, but also breaks the chain of WAL files needed for + archive recovery, so it should only be used in unusual circumstances. +

archive_timeout (integer)

The archive_command is only invoked for + completed WAL segments. Hence, if your server generates little WAL + traffic (or has slack periods where it does so), there could be a + long delay between the completion of a transaction and its safe + recording in archive storage. To limit how old unarchived + data can be, you can set archive_timeout to force the + server to switch to a new WAL segment file periodically. When this + parameter is greater than zero, the server will switch to a new + segment file whenever this many seconds have elapsed since the last + segment file switch, and there has been any database activity, + including a single checkpoint. (Increasing + checkpoint_timeout will reduce unnecessary + checkpoints on an idle system.) + Note that archived files that are closed early + due to a forced switch are still the same length as completely full + files. Therefore, it is unwise to use a very short + archive_timeout — it will bloat your archive + storage. archive_timeout settings of a minute or so are + usually reasonable. You should consider using streaming replication, + instead of archiving, if you want data to be copied off the master + server more quickly than that. + This parameter can only be set in the + postgresql.conf file or on the server command line. +


PrevHomeNext
Resource ConsumptionUpReplication
\ No newline at end of file diff --git a/doc/src/sgml/html/runtime-config.html b/doc/src/sgml/html/runtime-config.html new file mode 100644 index 000000000..0e97b4277 --- /dev/null +++ b/doc/src/sgml/html/runtime-config.html @@ -0,0 +1,478 @@ + +Server Configuration

Chapter 18. Server Configuration

Table of Contents
18.1. Setting Parameters
18.1.1. Parameter Names and Values
18.1.2. Setting Parameters via the Configuration File
18.1.3. Other Ways to Set Parameters
18.1.4. Examining Parameter Settings
18.2. File Locations
18.3. Connections and Authentication
18.3.1. Connection Settings
18.3.2. Security and Authentication
18.4. Resource Consumption
18.4.1. Memory
18.4.2. Disk
18.4.3. Kernel Resource Usage
18.4.4. Cost-based Vacuum Delay
18.4.5. Background Writer
18.4.6. Asynchronous Behavior
18.5. Write Ahead Log
18.5.1. Settings
18.5.2. Checkpoints
18.5.3. Archiving
18.6. Replication
18.6.1. Sending Server(s)
18.6.2. Master Server
18.6.3. Standby Servers
18.7. Query Planning
18.7.1. Planner Method Configuration
18.7.2. Planner Cost Constants
18.7.3. Genetic Query Optimizer
18.7.4. Other Planner Options
18.8. Error Reporting and Logging
18.8.1. Where To Log
18.8.2. When To Log
18.8.3. What To Log
18.8.4. Using CSV-Format Log Output
18.9. Run-time Statistics
18.9.1. Query and Index Statistics Collector
18.9.2. Statistics Monitoring
18.10. Automatic Vacuuming
18.11. Client Connection Defaults
18.11.1. Statement Behavior
18.11.2. Locale and Formatting
18.11.3. Other Defaults
18.12. Lock Management
18.13. Version and Platform Compatibility
18.13.1. Previous PostgreSQL Versions
18.13.2. Platform and Client Compatibility
18.14. Error Handling
18.15. Preset Options
18.16. Customized Options
18.17. Developer Options
18.18. Short Options

There are many configuration parameters that affect the behavior of + the database system. In the first section of this chapter, we + describe how to set configuration parameters. The subsequent sections + discuss each parameter in detail. +


PrevHomeNext
Registering Event Log on WindowsUpSetting Parameters
\ No newline at end of file diff --git a/doc/src/sgml/html/runtime.html b/doc/src/sgml/html/runtime.html new file mode 100644 index 000000000..a7bf40ee5 --- /dev/null +++ b/doc/src/sgml/html/runtime.html @@ -0,0 +1,332 @@ + +Server Setup and Operation

Chapter 17. Server Setup and Operation

This chapter discusses how to set up and run the database server + and its interactions with the operating system. +


PrevHomeNext
Building libpq with + Visual C++ or + Borland C++UpThe PostgreSQL User Account
\ No newline at end of file diff --git a/doc/src/sgml/html/seg.html b/doc/src/sgml/html/seg.html new file mode 100644 index 000000000..eb60ef44f --- /dev/null +++ b/doc/src/sgml/html/seg.html @@ -0,0 +1,958 @@ + +seg
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.31. seg

This module implements a data type seg for + representing line segments, or floating point intervals. + seg can represent uncertainty in the interval endpoints, + making it especially useful for representing laboratory measurements. +

F.31.1. Rationale

The geometry of measurements is usually more complex than that of a + point in a numeric continuum. A measurement is usually a segment of + that continuum with somewhat fuzzy limits. The measurements come out + as intervals because of uncertainty and randomness, as well as because + the value being measured may naturally be an interval indicating some + condition, such as the temperature range of stability of a protein. +

Using just common sense, it appears more convenient to store such data + as intervals, rather than pairs of numbers. In practice, it even turns + out more efficient in most applications. +

Further along the line of common sense, the fuzziness of the limits + suggests that the use of traditional numeric data types leads to a + certain loss of information. Consider this: your instrument reads + 6.50, and you input this reading into the database. What do you get + when you fetch it? Watch: + +

test=> select 6.50 :: float8 as "pH";
+ pH
+---
+6.5
+(1 row)

+ + In the world of measurements, 6.50 is not the same as 6.5. It may + sometimes be critically different. The experimenters usually write + down (and publish) the digits they trust. 6.50 is actually a fuzzy + interval contained within a bigger and even fuzzier interval, 6.5, + with their center points being (probably) the only common feature they + share. We definitely do not want such different data items to appear the + same. +

Conclusion? It is nice to have a special data type that can record the + limits of an interval with arbitrarily variable precision. Variable in + the sense that each data element records its own precision. +

Check this out: + +

test=> select '6.25 .. 6.50'::seg as "pH";
+          pH
+------------
+6.25 .. 6.50
+(1 row)

+

F.31.2. Syntax

The external representation of an interval is formed using one or two + floating-point numbers joined by the range operator (.. + or ...). Alternatively, it can be specified as a + center point plus or minus a deviation. + Optional certainty indicators (<, + > or ~) can be stored as well. + (Certainty indicators are ignored by all the built-in operators, however.) + Table F-24 gives an overview of allowed + representations; Table F-25 shows some + examples. +

In Table F-24, x, y, and + delta denote + floating-point numbers. x and y, but + not delta, can be preceded by a certainty indicator. +

Table F-24. seg External Representations

xSingle value (zero-length interval) +
x .. yInterval from x to y +
x (+-) deltaInterval from x - delta to + x + delta +
x ..Open interval with lower bound x +
.. xOpen interval with upper bound x +

Table F-25. Examples of Valid seg Input

5.0 Creates a zero-length segment (a point, if you will) +
~5.0 Creates a zero-length segment and records + ~ in the data. ~ is ignored + by seg operations, but + is preserved as a comment. +
<5.0 Creates a point at 5.0. < is ignored but + is preserved as a comment. +
>5.0 Creates a point at 5.0. > is ignored but + is preserved as a comment. +
5(+-)0.3 Creates an interval 4.7 .. 5.3. + Note that the (+-) notation isn't preserved. +
50 .. Everything that is greater than or equal to 50
.. 0Everything that is less than or equal to 0
1.5e-2 .. 2E-2 Creates an interval 0.015 .. 0.02
1 ... 2 The same as 1...2, or 1 .. 2, + or 1..2 + (spaces around the range operator are ignored) +

Because ... is widely used in data sources, it is allowed + as an alternative spelling of ... Unfortunately, this + creates a parsing ambiguity: it is not clear whether the upper bound + in 0...23 is meant to be 23 or 0.23. + This is resolved by requiring at least one digit before the decimal + point in all numbers in seg input. +

As a sanity check, seg rejects intervals with the lower bound + greater than the upper, for example 5 .. 2. +

F.31.3. Precision

seg values are stored internally as pairs of 32-bit floating point + numbers. This means that numbers with more than 7 significant digits + will be truncated. +

Numbers with 7 or fewer significant digits retain their + original precision. That is, if your query returns 0.00, you will be + sure that the trailing zeroes are not the artifacts of formatting: they + reflect the precision of the original data. The number of leading + zeroes does not affect precision: the value 0.0067 is considered to + have just 2 significant digits. +

F.31.4. Usage

The seg module includes a GiST index operator class for + seg values. + The operators supported by the GiST operator class are shown in Table F-26. +

Table F-26. Seg GiST Operators

OperatorDescription
[a, b] << [c, d][a, b] is entirely to the left of [c, d]. That is, [a, + b] << [c, d] is true if b < c and false otherwise.
[a, b] >> [c, d][a, b] is entirely to the right of [c, d]. That is, [a, + b] >> [c, d] is true if a > d and false otherwise.
[a, b] &< [c, d]Overlaps or is left of — This might be better read + as "does not extend to right of". It is true when + b <= d.
[a, b] &> [c, d]Overlaps or is right of — This might be better read + as "does not extend to left of". It is true when + a >= c.
[a, b] = [c, d]Same as — The segments [a, b] and [c, d] are + identical, that is, a = c and b = d.
[a, b] && [c, d]The segments [a, b] and [c, d] overlap.
[a, b] @> [c, d]The segment [a, b] contains the segment [c, d], that is, + a <= c and b >= d.
[a, b] <@ [c, d]The segment [a, b] is contained in [c, d], that is, a + >= c and b <= d.

(Before PostgreSQL 8.2, the containment operators @> and <@ were + respectively called @ and ~. These names are still available, but are + deprecated and will eventually be retired. Notice that the old names + are reversed from the convention formerly followed by the core geometric + data types!) +

The standard B-tree operators are also provided, for example + +

OperatorDescription
[a, b] < [c, d]Less than
[a, b] > [c, d]Greater than

+ + These operators do not make a lot of sense for any practical + purpose but sorting. These operators first compare (a) to (c), + and if these are equal, compare (b) to (d). That results in + reasonably good sorting in most cases, which is useful if + you want to use ORDER BY with this type. +

F.31.5. Notes

For examples of usage, see the regression test sql/seg.sql. +

The mechanism that converts (+-) to regular ranges + isn't completely accurate in determining the number of significant digits + for the boundaries. For example, it adds an extra digit to the lower + boundary if the resulting interval includes a power of ten: + +

postgres=> select '10(+-)1'::seg as seg;
+      seg
+---------
+9.0 .. 11             -- should be: 9 .. 11

+

The performance of an R-tree index can largely depend on the initial + order of input values. It may be very helpful to sort the input table + on the seg column; see the script sort-segments.pl + for an example. +

F.31.6. Credits

Original author: Gene Selkov, Jr. <selkovjr@mcs.anl.gov>, + Mathematics and Computer Science Division, Argonne National Laboratory. +

My thanks are primarily to Prof. Joe Hellerstein + (http://db.cs.berkeley.edu/jmh/) for elucidating the + gist of the GiST (http://gist.cs.berkeley.edu/). I am + also grateful to all Postgres developers, present and past, for enabling + myself to create my own world and live undisturbed in it. And I would like + to acknowledge my gratitude to Argonne Lab and to the U.S. Department of + Energy for the years of faithful support of my database research. +


PrevHomeNext
pg_trgmUpsepgsql
\ No newline at end of file diff --git a/doc/src/sgml/html/sepgsql.html b/doc/src/sgml/html/sepgsql.html new file mode 100644 index 000000000..6abae73c3 --- /dev/null +++ b/doc/src/sgml/html/sepgsql.html @@ -0,0 +1,1386 @@ + +sepgsql
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.32. sepgsql

sepgsql is a loadable module that supports label-based + mandatory access control (MAC) based on SELinux security + policy. +

Warning

The current implementation has significant limitations, and does not + enforce mandatory access control for all actions. See + Section F.32.7. +

F.32.1. Overview

This module integrates with SELinux to provide an + additional layer of security checking above and beyond what is normally + provided by PostgreSQL. From the perspective of + SELinux, this module allows + PostgreSQL to function as a user-space object + manager. Each table or function access initiated by a DML query will be + checked against the system security policy. This check is in addition to + the usual SQL permissions checking performed by + PostgreSQL. +

SELinux access control decisions are made using + security labels, which are represented by strings such as + system_u:object_r:sepgsql_table_t:s0. Each access control + decision involves two labels: the label of the subject attempting to + perform the action, and the label of the object on which the operation is + to be performed. Since these labels can be applied to any sort of object, + access control decisions for objects stored within the database can be + (and, with this module, are) subjected to the same general criteria used + for objects of any other type, such as files. This design is intended to + allow a centralized security policy to protect information assets + independent of the particulars of how those assets are stored. +

The SECURITY LABEL statement allows assignment of + a security label to a database object. +

F.32.2. Installation

sepgsql can only be used on Linux + 2.6.28 or higher with SELinux enabled. + It is not available on any other platform. You will also need + libselinux 2.0.99 or higher and + selinux-policy 3.9.13 or higher (although some + distributions may backport the necessary rules into older policy + versions). +

The sestatus command allows you to check the status of + SELinux. A typical display is: +

$ sestatus
+SELinux status:                 enabled
+SELinuxfs mount:                /selinux
+Current mode:                   enforcing
+Mode from config file:          enforcing
+Policy version:                 24
+Policy from config file:        targeted

+ If SELinux is disabled or not installed, you must set + that product up first before installing this module. +

To build this module, include the option --with-selinux in + your PostgreSQL configure command. Be sure that the + libselinux-devel RPM is installed at build time. +

To use this module, you must include sepgsql + in the shared_preload_libraries parameter in + postgresql.conf. The module will not function correctly + if loaded in any other manner. Once the module is loaded, you + should execute sepgsql.sql in each database. + This will install functions needed for security label management, and + assign initial security labels. +

Here is an example showing how to initialize a fresh database cluster + with sepgsql functions and security labels installed. + Adjust the paths shown as appropriate for your installation: +

$ export PGDATA=/path/to/data/directory
+$ initdb
+$ vi $PGDATA/postgresql.conf
+  change
+    #shared_preload_libraries = ''                # (change requires restart)
+  to
+    shared_preload_libraries = 'sepgsql'          # (change requires restart)
+$ for DBNAME in template0 template1 postgres; do
+    postgres --single -F -c exit_on_error=true $DBNAME \
+      </usr/local/pgsql/share/contrib/sepgsql.sql >/dev/null
+  done

Please note that you may see some or all of the following notifications + depending on the particular versions you have of + libselinux and selinux-policy: +

/etc/selinux/targeted/contexts/sepgsql_contexts:  line 33 has invalid object type db_blobs
+/etc/selinux/targeted/contexts/sepgsql_contexts:  line 36 has invalid object type db_language
+/etc/selinux/targeted/contexts/sepgsql_contexts:  line 37 has invalid object type db_language
+/etc/selinux/targeted/contexts/sepgsql_contexts:  line 38 has invalid object type db_language
+/etc/selinux/targeted/contexts/sepgsql_contexts:  line 39 has invalid object type db_language
+/etc/selinux/targeted/contexts/sepgsql_contexts:  line 40 has invalid object type db_language

+ These messages are harmless and should be ignored. +

If the installation process completes without error, you can now start the + server normally. +

F.32.3. Regression Tests

Due to the nature of SELinux, running the + regression tests for sepgsql requires several extra + configuration steps, some of which must be done as root. + The regression tests will not be run by an ordinary + make check or make installcheck command; you must + set up the configuration and then invoke the test script manually. + The tests must be run in the contrib/sepgsql directory + of a configured PostgreSQL build tree. Although they require a build tree, + the tests are designed to be executed against an installed server, + that is they are comparable to make installcheck not + make check. +

First, set up sepgsql in a working database + according to the instructions in Section F.32.2. + Note that the current operating system user must be able to connect to the + database as superuser without password authentication. +

Second, build and install the policy package for the regression test. + The sepgsql-regtest policy is a special purpose policy package + which provides a set of rules to be allowed during the regression tests. + It should be built from the policy source file + sepgsql-regtest.te, which is done using + make with a Makefile supplied by SELinux. + You will need to locate the appropriate + Makefile on your system; the path shown below is only an example. + Once built, install this policy package using the + semodule command, which loads supplied policy packages + into the kernel. If the package is correctly installed, + semodule -l should list sepgsql-regtest as an + available policy package: +

$ cd .../contrib/sepgsql
+$ make -f /usr/share/selinux/devel/Makefile
+$ sudo semodule -u sepgsql-regtest.pp
+$ sudo semodule -l | grep sepgsql
+sepgsql-regtest 1.04

Third, turn on sepgsql_regression_test_mode. + For security reasons, the rules in sepgsql-regtest + are not enabled by default; + the sepgsql_regression_test_mode parameter enables + the rules needed to launch the regression tests. + It can be turned on using the setsebool command: +

$ sudo setsebool sepgsql_regression_test_mode on
+$ getsebool sepgsql_regression_test_mode
+sepgsql_regression_test_mode --> on

Fourth, verify your shell is operating in the unconfined_t + domain: +

$ id -Z
+unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023

See Section F.32.8 for details on adjusting your + working domain, if necessary. +

Finally, run the regression test script: +

$ ./test_sepgsql

This script will attempt to verify that you have done all the configuration + steps correctly, and then it will run the regression tests for the + sepgsql module. +

After completing the tests, it's recommended you disable + the sepgsql_regression_test_mode parameter: +

$ sudo setsebool sepgsql_regression_test_mode off

You might prefer to remove the sepgsql-regtest policy + entirely: +

$ sudo semodule -r sepgsql-regtest

F.32.4. GUC Parameters

sepgsql.permissive (boolean)

This parameter enables sepgsql to function + in permissive mode, regardless of the system setting. + The default is off. + This parameter can only be set in the postgresql.conf + file or on the server command line. +

When this parameter is on, sepgsql functions + in permissive mode, even if SELinux in general is working in enforcing + mode. This parameter is primarily useful for testing purposes. +

sepgsql.debug_audit (boolean)

This parameter enables the printing of audit messages regardless of + the system policy settings. + The default is off, which means that messages will be printed according + to the system settings. +

The security policy of SELinux also has rules to + control whether or not particular accesses are logged. + By default, access violations are logged, but allowed + accesses are not. +

This parameter forces all possible logging to be turned on, regardless + of the system policy. +

F.32.5. Features

F.32.5.1. Controlled Object Classes

The security model of SELinux describes all the access + control rules as relationships between a subject entity (typically, + a client of the database) and an object entity (such as a database + object), each of which is + identified by a security label. If access to an unlabelled object is + attempted, the object is treated as if it were assigned the label + unlabeled_t. +

Currently, sepgsql allows security labels to be + assigned to schemas, tables, columns, sequences, views, and functions. + When sepgsql is in use, security labels are + automatically assigned to supported database objects at creation time. + This label is called a default security label, and is decided according + to the system security policy, which takes as input the creator's label + and the label assigned to the new object's parent object. +

A new database object basically inherits the security label of the parent + object, except when the security policy has special rules known as + type-transition rules, in which case a different label may be applied. + For schemas, the parent object is the current database; for tables, + sequences, views, and functions, it is the containing schema; for columns, + it is the containing table. +

F.32.5.2. DML Permissions

For tables, db_table:select, db_table:insert, + db_table:update or db_table:delete are + checked for all the referenced target tables depending on the kind of + statement; in addition, db_table:select is also checked for + all the tables that contain columns referenced in the + WHERE or RETURNING clause, as a data source + for UPDATE, and so on. +

Column-level permissions will also be checked for each referenced column. + db_column:select is checked on not only the columns being + read using SELECT, but those being referenced in other DML + statements; db_column:update or db_column:insert + will also be checked for columns being modified by UPDATE or + INSERT. +

For example, consider: +

UPDATE t1 SET x = 2, y = md5sum(y) WHERE z = 100;

+ + Here, db_column:update will be checked for + t1.x, since it is being updated, + db_column:{select update} will be checked for + t1.y, since it is both updated and referenced, and + db_column:select will be checked for t1.z, since + it is only referenced. + db_table:{select update} will also be checked + at the table level. +

For sequences, db_sequence:get_value is checked when we + reference a sequence object using SELECT; however, note that we + do not currently check permissions on execution of corresponding functions + such as lastval(). +

For views, db_view:expand will be checked, then any other + required permissions will be checked on the objects being + expanded from the view, individually. +

For functions, db_procedure:{execute} is defined, but is not + checked in this version. +

The client must be allowed to access all referenced tables and + columns, even if they originated from views which were then expanded, + so that we apply consistent access control rules independent of the manner + in which the table contents are referenced. +

The default database privilege system allows database superusers to + modify system catalogs using DML commands, and reference or modify + toast tables. These operations are prohibited when + sepgsql is enabled. +

F.32.5.3. DDL Permissions

SELinux defines several permissions to control common + operations for each object type; such as creation, alter, drop and + relabel of security label. In addition, several object types have + special permissions to control their characteristic operations; such as + addition or deletion of name entries within a particular schema. +

When a CREATE command is executed, create will + be checked on the object being constructed for each object types. + A default security label will be assigned to the new database object, + and the create permission will be checked on the pair + of security label of the client and the new object itself. + We consider CREATE TABLE to construct a table and + underlying columns at the same time, so it requires the users to have + permission to create both the table and its columns. +

A few additional checks are applied depending on object types. + On CREATE DATABASE, getattr permission + will be checked on the source or template database of the new database, + not only create on the new database. + On creation of objects within a particular schema (tables, views, + sequences and procedures), add_name will be also checked + on the schema, not only create on the new object itself. +

When DROP command is executed, drop will be + checked on the object being removed for each object types. Permissions + will not be checked for objects dropped indirectly via CASCADE. + Deletion of objects contained within a particular schema (tables, views, + sequences and procedures) additionally requires + remove_name on the schema. +

When SECURITY LABEL is executed, setattr + and relabelfrom will be checked on the object being relabeled + with its old security label, then relabelto with the supplied + new security label. +

In the case where multiple label providers are installed and the user tries + to set a security label, but it is not managed by SELinux, + only setattr should be checked here. + This is currently not done due to implementation restrictions. +

F.32.5.4. Trusted Procedures

Trusted procedures are similar to security definer functions or setuid + commands. SELinux provides a feature to allow trusted + code to run using a security label different from that of the client, + generally for the purpose of providing highly controlled access to + sensitive data (e.g. rows might be omitted, or the precision of stored + values might be reduced). Whether or not a function acts as a trusted + procedure is controlled by its security label and the operating system + security policy. For example: +

postgres=# CREATE TABLE customer (
+               cid     int primary key,
+               cname   text,
+               credit  text
+           );
+CREATE TABLE
+postgres=# SECURITY LABEL ON COLUMN customer.credit
+               IS 'system_u:object_r:sepgsql_secret_table_t:s0';
+SECURITY LABEL
+postgres=# CREATE FUNCTION show_credit(int) RETURNS text
+             AS 'SELECT regexp_replace(credit, ''-[0-9]+$'', ''-xxxx'', ''g'')
+                        FROM customer WHERE cid = $1'
+           LANGUAGE sql;
+CREATE FUNCTION
+postgres=# SECURITY LABEL ON FUNCTION show_credit(int)
+               IS 'system_u:object_r:sepgsql_trusted_proc_exec_t:s0';
+SECURITY LABEL

The above operations should be performed by an administrative user. +

postgres=# SELECT * FROM customer;
+ERROR:  SELinux: security policy violation
+postgres=# SELECT cid, cname, show_credit(cid) FROM customer;
+ cid | cname  |     show_credit
+-----+--------+---------------------
+   1 | taro   | 1111-2222-3333-xxxx
+   2 | hanako | 5555-6666-7777-xxxx
+(2 rows)

In this case, a regular user cannot reference customer.credit + directly, but a trusted procedure show_credit allows him + to print the credit card numbers of customers with some of the digits + masked out. +

F.32.5.5. Dynamic Domain Transitions

It is possible to use SELinux's dynamic domain transition feature + to switch the security label of the client process, the client domain, + to a new context, if that is allowed by the security policy. + The client domain needs the setcurrent permission and also + dyntransition from the old to the new domain. +

Dynamic domain transitions should be considered carefully, because they + allow users to switch their label, and therefore their privileges, + at their option, rather than (as in the case of a trusted procedure) + as mandated by the system. + Thus, the dyntransition permission is only considered + safe when used to switch to a domain with a smaller set of privileges than + the original one. For example: +

regression=# select sepgsql_getcon();
+                    sepgsql_getcon
+-------------------------------------------------------
+ unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023
+(1 row)
+
+regression=# SELECT sepgsql_setcon('unconfined_u:unconfined_r:unconfined_t:s0-s0:c1.c4');
+ sepgsql_setcon 
+----------------
+ t
+(1 row)
+
+regression=# SELECT sepgsql_setcon('unconfined_u:unconfined_r:unconfined_t:s0-s0:c1.c1023');
+ERROR:  SELinux: security policy violation

In this example above we were allowed to switch from the larger MCS + range c1.c1023 to the smaller range c1.c4, but + switching back was denied. +

A combination of dynamic domain transition and trusted procedure + enables an interesting use case that fits the typical process life-cycle + of connection pooling software. + Even if your connection pooling software is not allowed to run most + of SQL commands, you can allow it to switch the security label + of the client using the sepgsql_setcon() function + from within a trusted procedure; that should take some + credential to authorize the request to switch the client label. + After that, this session will have the privileges of the target user, + rather than the connection pooler. + The connection pooler can later revert the security label change by + again using sepgsql_setcon() with + NULL argument, again invoked from within a trusted + procedure with appropriate permissions checks. + The point here is that only the trusted procedure actually has permission + to change the effective security label, and only does so when given proper + credentials. Of course, for secure operation, the credential store + (table, procedure definition, or whatever) must be protected from + unauthorized access. +

F.32.5.6. Miscellaneous

We reject the LOAD command across the board, because + any module loaded could easily circumvent security policy enforcement. +

F.32.6. Sepgsql Functions

Table F-27 shows the available functions. +

Table F-27. Sepgsql Functions

sepgsql_getcon() returns text Returns the client domain, the current security label of the client. +
sepgsql_setcon(text) returns bool Switches the client domain of the current session to the new domain, + if allowed by the security policy. + It also accepts NULL input as a request to transition + to the client's original domain. +
sepgsql_mcstrans_in(text) returns textTranslates the given qualifies MLS/MCS range into raw format if + the mcstrans daemon is running. +
sepgsql_mcstrans_out(text) returns textTranslates the given raw MCS/MCS range into qualified format if + the mcstrans daemon is running. +
sepgsql_restorecon(text) returns bool Sets up initial security labels for all objects within the + current database. The argument may be NULL, or the name of a specfile + to be used as alternative of the system default. +

F.32.7. Limitations

Data Definition Language (DDL) Permissions

Due to implementation restrictions, some DDL operations do not + check permissions. +

Data Control Language (DCL) Permissions

Due to implementation restrictions, DCL operations do not check + permissions. +

Row-level access control

PostgreSQL does not support row-level access; therefore, + sepgsql does not support it either. +

Covert channels

sepgsql does not try to hide the existence of + a certain object, even if the user is not allowed to reference it. + For example, we can infer the existence of an invisible object as + a result of primary key conflicts, foreign key violations, and so on, + even if we cannot obtain the contents of the object. The existence + of a top secret table cannot be hidden; we only hope to conceal its + contents. +

F.32.8. External Resources

SE-PostgreSQL Introduction

This wiki page provides a brief overview, security design, architecture, + administration and upcoming features. +

Fedora SELinux User Guide

This document provides a wide spectrum of knowledge to administer + SELinux on your systems. + It focuses primarily on Fedora, but is not limited to Fedora. +

Fedora SELinux FAQ

This document answers frequently asked questions about + SELinux. + It focuses primarily on Fedora, but is not limited to Fedora. +

\ No newline at end of file diff --git a/doc/src/sgml/html/server-programming.html b/doc/src/sgml/html/server-programming.html new file mode 100644 index 000000000..4b851b9b2 --- /dev/null +++ b/doc/src/sgml/html/server-programming.html @@ -0,0 +1,666 @@ + +Server Programming

V. Server Programming

This part is about extending the server functionality with + user-defined functions, data types, triggers, etc. These are + advanced topics which should probably be approached only after all + the other user documentation about PostgreSQL has + been understood. Later chapters in this part describe the server-side + programming languages available in the + PostgreSQL distribution as well as + general issues concerning server-side programming languages. It + is essential to read at least the earlier sections of Chapter 35 (covering functions) before diving into the + material about server-side programming languages. +

Table of Contents
35. Extending SQL
35.1. How Extensibility Works
35.2. The PostgreSQL Type System
35.3. User-defined Functions
35.4. Query Language (SQL) Functions
35.5. Function Overloading
35.6. Function Volatility Categories
35.7. Procedural Language Functions
35.8. Internal Functions
35.9. C-Language Functions
35.10. User-defined Aggregates
35.11. User-defined Types
35.12. User-defined Operators
35.13. Operator Optimization Information
35.14. Interfacing Extensions To Indexes
35.15. Packaging Related Objects into an Extension
35.16. Extension Building Infrastructure
36. Triggers
36.1. Overview of Trigger Behavior
36.2. Visibility of Data Changes
36.3. Writing Trigger Functions in C
36.4. A Complete Trigger Example
37. The Rule System
37.1. The Query Tree
37.2. Views and the Rule System
37.3. Rules on INSERT, UPDATE, and DELETE
37.4. Rules and Privileges
37.5. Rules and Command Status
37.6. Rules Versus Triggers
38. Procedural Languages
38.1. Installing Procedural Languages
39. PL/pgSQL - SQL Procedural Language
39.1. Overview
39.2. Structure of PL/pgSQL
39.3. Declarations
39.4. Expressions
39.5. Basic Statements
39.6. Control Structures
39.7. Cursors
39.8. Errors and Messages
39.9. Trigger Procedures
39.10. PL/pgSQL Under the Hood
39.11. Tips for Developing in PL/pgSQL
39.12. Porting from Oracle PL/SQL
40. PL/Tcl - Tcl Procedural Language
40.1. Overview
40.2. PL/Tcl Functions and Arguments
40.3. Data Values in PL/Tcl
40.4. Global Data in PL/Tcl
40.5. Database Access from PL/Tcl
40.6. Trigger Procedures in PL/Tcl
40.7. Modules and the unknown Command
40.8. Tcl Procedure Names
41. PL/Perl - Perl Procedural Language
41.1. PL/Perl Functions and Arguments
41.2. Data Values in PL/Perl
41.3. Built-in Functions
41.4. Global Values in PL/Perl
41.5. Trusted and Untrusted PL/Perl
41.6. PL/Perl Triggers
41.7. PL/Perl Under the Hood
42. PL/Python - Python Procedural Language
42.1. Python 2 vs. Python 3
42.2. PL/Python Functions
42.3. Data Values
42.4. Sharing Data
42.5. Anonymous Code Blocks
42.6. Trigger Functions
42.7. Database Access
42.8. Explicit Subtransactions
42.9. Utility Functions
42.10. Environment Variables
43. Server Programming Interface
43.1. Interface Functions
43.2. Interface Support Functions
43.3. Memory Management
43.4. Visibility of Data Changes
43.5. Examples

PrevHomeNext
views Extending SQL
\ No newline at end of file diff --git a/doc/src/sgml/html/server-shutdown.html b/doc/src/sgml/html/server-shutdown.html new file mode 100644 index 000000000..22c13e2e9 --- /dev/null +++ b/doc/src/sgml/html/server-shutdown.html @@ -0,0 +1,340 @@ + +Shutting Down the Server
PostgreSQL 9.2.2 Documentation
PrevUpChapter 17. Server Setup and OperationNext

17.5. Shutting Down the Server

There are several ways to shut down the database server. You control + the type of shutdown by sending different signals to the master + postgres process. + +

SIGTERM

This is the Smart Shutdown mode. + After receiving SIGTERM, the server + disallows new connections, but lets existing sessions end their + work normally. It shuts down only after all of the sessions terminate. + If the server is in online backup mode, it additionally waits + until online backup mode is no longer active. While backup mode is + active, new connections will still be allowed, but only to superusers + (this exception allows a superuser to connect to terminate + online backup mode). If the server is in recovery when a smart + shutdown is requested, recovery and streaming replication will be + stopped only after all regular sessions have terminated. +

SIGINT

This is the Fast Shutdown mode. + The server disallows new connections and sends all existing + server processes SIGTERM, which will cause them + to abort their current transactions and exit promptly. It then + waits for all server processes to exit and finally shuts down. + If the server is in online backup mode, backup mode will be + terminated, rendering the backup useless. +

SIGQUIT

This is the Immediate Shutdown mode. + The master postgres process will send a + SIGQUIT to all child processes and exit + immediately, without properly shutting itself down. The child processes + likewise exit immediately upon receiving + SIGQUIT. This will lead to recovery (by + replaying the WAL log) upon next start-up. This is recommended + only in emergencies. +

+

The pg_ctl program provides a convenient + interface for sending these signals to shut down the server. + Alternatively, you can send the signal directly using kill + on non-Windows systems. + The PID of the postgres process can be + found using the ps program, or from the file + postmaster.pid in the data directory. For + example, to do a fast shutdown: +

$ kill -INT `head -1 /usr/local/pgsql/data/postmaster.pid`

+

Important: It is best not to use SIGKILL to shut down + the server. Doing so will prevent the server from releasing + shared memory and semaphores, which might then have to be done + manually before a new server can be started. Furthermore, + SIGKILL kills the postgres + process without letting it relay the signal to its subprocesses, + so it will be necessary to kill the individual subprocesses by hand as + well. +

To terminate an individual session while allowing other sessions to + continue, use pg_terminate_backend() (see Table 9-58) or send a + SIGTERM signal to the child process associated with + the session. +


PrevHomeNext
Managing Kernel ResourcesUpUpgrading a PostgreSQL Cluster
\ No newline at end of file diff --git a/doc/src/sgml/html/server-start.html b/doc/src/sgml/html/server-start.html new file mode 100644 index 000000000..282d05359 --- /dev/null +++ b/doc/src/sgml/html/server-start.html @@ -0,0 +1,663 @@ + +Starting the Database Server
PostgreSQL 9.2.2 Documentation
PrevUpChapter 17. Server Setup and OperationNext

17.3. Starting the Database Server

Before anyone can access the database, you must start the database + server. The database server program is called + postgres. + The postgres program must know where to + find the data it is supposed to use. This is done with the + -D option. Thus, the simplest way to start the + server is: +

$ postgres -D /usr/local/pgsql/data

+ which will leave the server running in the foreground. This must be + done while logged into the PostgreSQL user + account. Without -D, the server will try to use + the data directory named by the environment variable PGDATA. + If that variable is not provided either, it will fail. +

Normally it is better to start postgres in the + background. For this, use the usual Unix shell syntax: +

$ postgres -D /usr/local/pgsql/data >logfile 2>&1 &

+ It is important to store the server's stdout and + stderr output somewhere, as shown above. It will help + for auditing purposes and to diagnose problems. (See Section 23.3 for a more thorough discussion of log + file handling.) +

The postgres program also takes a number of other + command-line options. For more information, see the + postgres reference page + and Chapter 18 below. +

This shell syntax can get tedious quickly. Therefore the wrapper + program + pg_ctl + is provided to simplify some tasks. For example: +

pg_ctl start -l logfile

+ will start the server in the background and put the output into the + named log file. The -D option has the same meaning + here as for postgres. pg_ctl + is also capable of stopping the server. +

Normally, you will want to start the database server when the + computer boots. + Autostart scripts are operating-system-specific. + There are a few distributed with + PostgreSQL in the + contrib/start-scripts directory. Installing one will require + root privileges. +

Different systems have different conventions for starting up daemons + at boot time. Many systems have a file + /etc/rc.local or + /etc/rc.d/rc.local. Others use init.d or + rc.d directories. Whatever you do, the server must be + run by the PostgreSQL user account + and not by root or any other user. Therefore you + probably should form your commands using + su postgres -c '...'. For example: +

su postgres -c 'pg_ctl start -D /usr/local/pgsql/data -l serverlog'

+

Here are a few more operating-system-specific suggestions. (In each + case be sure to use the proper installation directory and user + name where we show generic values.) + +

  • For FreeBSD, look at the file + contrib/start-scripts/freebsd in the + PostgreSQL source distribution. + +

  • On OpenBSD, add the following lines + to the file /etc/rc.local: + +

    if [ -x /usr/local/pgsql/bin/pg_ctl -a -x /usr/local/pgsql/bin/postgres ]; then
    +    su -l postgres -c '/usr/local/pgsql/bin/pg_ctl start -s -l /var/postgresql/log -D /usr/local/pgsql/data'
    +    echo -n ' postgresql'
    +fi

    +

  • On Linux systems either add + +

    /usr/local/pgsql/bin/pg_ctl start -l logfile -D /usr/local/pgsql/data

    + to /etc/rc.d/rc.local + or /etc/rc.local or look at the file + contrib/start-scripts/linux in the + PostgreSQL source distribution. +

  • On NetBSD, use either the + FreeBSD or + Linux start scripts, depending on + preference. + +

  • On Solaris, create a file called + /etc/init.d/postgresql that contains + the following line: + +

    su - postgres -c "/usr/local/pgsql/bin/pg_ctl start -l logfile -D /usr/local/pgsql/data"

    + Then, create a symbolic link to it in /etc/rc3.d as + S99postgresql. +

+ +

While the server is running, its + PID is stored in the file + postmaster.pid in the data directory. This is + used to prevent multiple server instances from + running in the same data directory and can also be used for + shutting down the server. +

17.3.1. Server Start-up Failures

There are several common reasons the server might fail to + start. Check the server's log file, or start it by hand (without + redirecting standard output or standard error) and see what error + messages appear. Below we explain some of the most common error + messages in more detail. +

LOG:  could not bind IPv4 socket: Address already in use
+HINT:  Is another postmaster already running on port 5432? If not, wait a few seconds and retry.
+FATAL:  could not create TCP/IP listen socket

+ This usually means just what it suggests: you tried to start + another server on the same port where one is already running. + However, if the kernel error message is not Address + already in use or some variant of that, there might + be a different problem. For example, trying to start a server + on a reserved port number might draw something like: +

$ postgres -p 666
+LOG:  could not bind IPv4 socket: Permission denied
+HINT:  Is another postmaster already running on port 666? If not, wait a few seconds and retry.
+FATAL:  could not create TCP/IP listen socket

+

A message like: +

FATAL:  could not create shared memory segment: Invalid argument
+DETAIL:  Failed system call was shmget(key=5440001, size=4011376640, 03600).

+ probably means your kernel's limit on the size of shared memory is + smaller than the work area PostgreSQL + is trying to create (4011376640 bytes in this example). Or it could + mean that you do not have System-V-style shared memory support + configured into your kernel at all. As a temporary workaround, you + can try starting the server with a smaller-than-normal number of + buffers (shared_buffers). You will eventually want + to reconfigure your kernel to increase the allowed shared memory + size. You might also see this message when trying to start multiple + servers on the same machine, if their total space requested + exceeds the kernel limit. +

An error like: +

FATAL:  could not create semaphores: No space left on device
+DETAIL:  Failed system call was semget(5440126, 17, 03600).

+ does not mean you've run out of disk + space. It means your kernel's limit on the number of System V semaphores is smaller than the number + PostgreSQL wants to create. As above, + you might be able to work around the problem by starting the + server with a reduced number of allowed connections + (max_connections), but you'll eventually want to + increase the kernel limit. +

If you get an "illegal system call" error, it is likely that + shared memory or semaphores are not supported in your kernel at + all. In that case your only option is to reconfigure the kernel to + enable these features. +

Details about configuring System V + IPC facilities are given in Section 17.4.1. +

17.3.2. Client Connection Problems

Although the error conditions possible on the client side are quite + varied and application-dependent, a few of them might be directly + related to how the server was started. Conditions other than + those shown below should be documented with the respective client + application. +

psql: could not connect to server: Connection refused
+        Is the server running on host "server.joe.com" and accepting
+        TCP/IP connections on port 5432?

+ This is the generic "I couldn't find a server to talk + to" failure. It looks like the above when TCP/IP + communication is attempted. A common mistake is to forget to + configure the server to allow TCP/IP connections. +

Alternatively, you'll get this when attempting Unix-domain socket + communication to a local server: +

psql: could not connect to server: No such file or directory
+        Is the server running locally and accepting
+        connections on Unix domain socket "/tmp/.s.PGSQL.5432"?

+

The last line is useful in verifying that the client is trying to + connect to the right place. If there is in fact no server + running there, the kernel error message will typically be either + Connection refused or + No such file or directory, as + illustrated. (It is important to realize that + Connection refused in this context + does not mean that the server got your + connection request and rejected it. That case will produce a + different message, as shown in Section 19.4.) Other error messages + such as Connection timed out might + indicate more fundamental problems, like lack of network + connectivity. +


PrevHomeNext
Creating a Database ClusterUpManaging Kernel Resources
\ No newline at end of file diff --git a/doc/src/sgml/html/source-format.html b/doc/src/sgml/html/source-format.html new file mode 100644 index 000000000..d51b3ce35 --- /dev/null +++ b/doc/src/sgml/html/source-format.html @@ -0,0 +1,270 @@ + +Formatting
PostgreSQL 9.2.2 Documentation
PrevUpChapter 47. PostgreSQL Coding ConventionsNext

47.1. Formatting

Source code formatting uses 4 column tab spacing, with + tabs preserved (i.e., tabs are not expanded to spaces). + Each logical indentation level is one additional tab stop. +

Layout rules (brace positioning, etc) follow BSD conventions. In + particular, curly braces for the controlled blocks of if, + while, switch, etc go on their own lines. +

Limit line lengths so that the code is readable in an 80-column window. + (This doesn't mean that you must never go past 80 columns. For instance, + breaking a long error message string in arbitrary places just to keep the + code within 80 columns is probably not a net gain in readability.) +

Do not use C++ style comments (// comments). Strict ANSI C + compilers do not accept them. For the same reason, do not use C++ + extensions such as declaring new variables mid-block. +

The preferred style for multi-line comment blocks is +

/*
+ * comment text begins here
+ * and continues here
+ */

+ Note that comment blocks that begin in column 1 will be preserved as-is + by pgindent, but it will re-flow indented comment blocks + as though they were plain text. If you want to preserve the line breaks + in an indented block, add dashes like this: +

    /*----------
+     * comment text begins here
+     * and continues here
+     *----------
+     */

+

While submitted patches do not absolutely have to follow these formatting + rules, it's a good idea to do so. Your code will get run through + pgindent before the next release, so there's no point in + making it look nice under some other set of formatting conventions. + A good rule of thumb for patches is "make the new code look like + the existing code around it". +

The src/tools directory contains sample settings + files that can be used with the emacs, + xemacs or vim + editors to help ensure that they format code according to these + conventions. +

The text browsing tools more and + less can be invoked as: +

more -x4
+less -x4

+ to make them show tabs appropriately. +


PrevHomeNext
PostgreSQL Coding ConventionsUpReporting Errors Within the Server
\ No newline at end of file diff --git a/doc/src/sgml/html/source.html b/doc/src/sgml/html/source.html new file mode 100644 index 000000000..b765f3685 --- /dev/null +++ b/doc/src/sgml/html/source.html @@ -0,0 +1,270 @@ + +PostgreSQL Coding Conventions

PrevHomeNext
Summary of Changes since Protocol 2.0UpFormatting
\ No newline at end of file diff --git a/doc/src/sgml/html/sourcerepo.html b/doc/src/sgml/html/sourcerepo.html new file mode 100644 index 000000000..7de1d8e1e --- /dev/null +++ b/doc/src/sgml/html/sourcerepo.html @@ -0,0 +1,208 @@ + +The Source Code Repository

Appendix I. The Source Code Repository

The PostgreSQL source code is stored and managed + using the Git version control system. A public + mirror of the master repository is available; it is updated within a minute + of any change to the master repository. +

Our wiki, http://wiki.postgresql.org/wiki/Working_with_Git, + has some discussion on working with Git. +

Note that building PostgreSQL from the source + repository requires reasonably up-to-date versions of bison, + flex, and Perl. These tools are not needed + to build from a distribution tarball since the files they are used to build + are included in the tarball. Other tool requirements are the same as shown + in Chapter 15. +


PrevHomeNext
ExtensionsUpGetting The Source via Git
\ No newline at end of file diff --git a/doc/src/sgml/html/spgist-examples.html b/doc/src/sgml/html/spgist-examples.html new file mode 100644 index 000000000..8dde76a85 --- /dev/null +++ b/doc/src/sgml/html/spgist-examples.html @@ -0,0 +1,180 @@ + +Examples
PostgreSQL 9.2.2 Documentation
PrevUpChapter 54. SP-GiST IndexesNext

54.4. Examples

The PostgreSQL source distribution includes + several examples of index operator classes for + SP-GiST. The core system currently provides suffix + trees over text columns and two types of trees over points: quad-tree and + k-d tree. Look into src/backend/access/spgist/ to see the + code. +


PrevHomeNext
ImplementationUpGIN Indexes
\ No newline at end of file diff --git a/doc/src/sgml/html/spgist-extensibility.html b/doc/src/sgml/html/spgist-extensibility.html new file mode 100644 index 000000000..8a35284ce --- /dev/null +++ b/doc/src/sgml/html/spgist-extensibility.html @@ -0,0 +1,1209 @@ + +Extensibility
PostgreSQL 9.2.2 Documentation
PrevUpChapter 54. SP-GiST IndexesNext

54.2. Extensibility

SP-GiST offers an interface with a high level of + abstraction, requiring the access method developer to implement only + methods specific to a given data type. The SP-GiST core + is responsible for efficient disk mapping and searching the tree structure. + It also takes care of concurrency and logging considerations. +

Leaf tuples of an SP-GiST tree contain values of the + same data type as the indexed column. Leaf tuples at the root level will + always contain the original indexed data value, but leaf tuples at lower + levels might contain only a compressed representation, such as a suffix. + In that case the operator class support functions must be able to + reconstruct the original value using information accumulated from the + inner tuples that are passed through to reach the leaf level. +

Inner tuples are more complex, since they are branching points in the + search tree. Each inner tuple contains a set of one or more + nodes, which represent groups of similar leaf values. + A node contains a downlink that leads to either another, lower-level inner + tuple, or a short list of leaf tuples that all lie on the same index page. + Each node has a label that describes it; for example, + in a suffix tree the node label could be the next character of the string + value. Optionally, an inner tuple can have a prefix value + that describes all its members. In a suffix tree this could be the common + prefix of the represented strings. The prefix value is not necessarily + really a prefix, but can be any data needed by the operator class; + for example, in a quad-tree it can store the central point that the four + quadrants are measured with respect to. A quad-tree inner tuple would + then also contain four nodes corresponding to the quadrants around this + central point. +

Some tree algorithms require knowledge of level (or depth) of the current + tuple, so the SP-GiST core provides the possibility for + operator classes to manage level counting while descending the tree. + There is also support for incrementally reconstructing the represented + value when that is needed. +

Note: The SP-GiST core code takes care of null entries. + Although SP-GiST indexes do store entries for nulls + in indexed columns, this is hidden from the index operator class code: + no null index entries or search conditions will ever be passed to the + operator class methods. (It is assumed that SP-GiST + operators are strict and so cannot succeed for null values.) Null values + are therefore not discussed further here. +

There are five user-defined methods that an index operator class for + SP-GiST must provide. All five follow the convention + of accepting two internal arguments, the first of which is a + pointer to a C struct containing input values for the support method, + while the second argument is a pointer to a C struct where output values + must be placed. Four of the methods just return void, since + all their results appear in the output struct; but + leaf_consistent additionally returns a boolean result. + The methods must not modify any fields of their input structs. In all + cases, the output struct is initialized to zeroes before calling the + user-defined method. +

The five user-defined methods are: +

config

Returns static information about the index implementation, including + the data type OIDs of the prefix and node label data types. +

The SQL declaration of the function must look like this: +

CREATE FUNCTION my_config(internal, internal) RETURNS void ...

+ The first argument is a pointer to a spgConfigIn + C struct, containing input data for the function. + The second argument is a pointer to a spgConfigOut + C struct, which the function must fill with result data. +

typedef struct spgConfigIn
+{
+    Oid         attType;        /* Data type to be indexed */
+} spgConfigIn;
+
+typedef struct spgConfigOut
+{
+    Oid         prefixType;     /* Data type of inner-tuple prefixes */
+    Oid         labelType;      /* Data type of inner-tuple node labels */
+    bool        canReturnData;  /* Opclass can reconstruct original data */
+    bool        longValuesOK;   /* Opclass can cope with values > 1 page */
+} spgConfigOut;

+ + attType is passed in order to support polymorphic + index operator classes; for ordinary fixed-data-type operator classes, it + will always have the same value and so can be ignored. +

For operator classes that do not use prefixes, + prefixType can be set to VOIDOID. + Likewise, for operator classes that do not use node labels, + labelType can be set to VOIDOID. + canReturnData should be set true if the operator class + is capable of reconstructing the originally-supplied index value. + longValuesOK should be set true only when the + attType is of variable length and the operator + class is capable of segmenting long values by repeated suffixing + (see Section 54.3.1). +

choose

Chooses a method for inserting a new value into an inner tuple. +

The SQL declaration of the function must look like this: +

CREATE FUNCTION my_choose(internal, internal) RETURNS void ...

+ The first argument is a pointer to a spgChooseIn + C struct, containing input data for the function. + The second argument is a pointer to a spgChooseOut + C struct, which the function must fill with result data. +

typedef struct spgChooseIn
+{
+    Datum       datum;          /* original datum to be indexed */
+    Datum       leafDatum;      /* current datum to be stored at leaf */
+    int         level;          /* current level (counting from zero) */
+
+    /* Data from current inner tuple */
+    bool        allTheSame;     /* tuple is marked all-the-same? */
+    bool        hasPrefix;      /* tuple has a prefix? */
+    Datum       prefixDatum;    /* if so, the prefix value */
+    int         nNodes;         /* number of nodes in the inner tuple */
+    Datum      *nodeLabels;     /* node label values (NULL if none) */
+} spgChooseIn;
+
+typedef enum spgChooseResultType
+{
+    spgMatchNode = 1,           /* descend into existing node */
+    spgAddNode,                 /* add a node to the inner tuple */
+    spgSplitTuple               /* split inner tuple (change its prefix) */
+} spgChooseResultType;
+
+typedef struct spgChooseOut
+{
+    spgChooseResultType resultType;     /* action code, see above */
+    union
+    {
+        struct                  /* results for spgMatchNode */
+        {
+            int         nodeN;      /* descend to this node (index from 0) */
+            int         levelAdd;   /* increment level by this much */
+            Datum       restDatum;  /* new leaf datum */
+        }           matchNode;
+        struct                  /* results for spgAddNode */
+        {
+            Datum       nodeLabel;  /* new node's label */
+            int         nodeN;      /* where to insert it (index from 0) */
+        }           addNode;
+        struct                  /* results for spgSplitTuple */
+        {
+            /* Info to form new inner tuple with one node */
+            bool        prefixHasPrefix;    /* tuple should have a prefix? */
+            Datum       prefixPrefixDatum;  /* if so, its value */
+            Datum       nodeLabel;          /* node's label */
+
+            /* Info to form new lower-level inner tuple with all old nodes */
+            bool        postfixHasPrefix;   /* tuple should have a prefix? */
+            Datum       postfixPrefixDatum; /* if so, its value */
+        }           splitTuple;
+    }           result;
+} spgChooseOut;

+ + datum is the original datum that was to be inserted + into the index. + leafDatum is initially the same as + datum, but can change at lower levels of the tree + if the choose or picksplit + methods change it. When the insertion search reaches a leaf page, + the current value of leafDatum is what will be stored + in the newly created leaf tuple. + level is the current inner tuple's level, starting at + zero for the root level. + allTheSame is true if the current inner tuple is + marked as containing multiple equivalent nodes + (see Section 54.3.3). + hasPrefix is true if the current inner tuple contains + a prefix; if so, + prefixDatum is its value. + nNodes is the number of child nodes contained in the + inner tuple, and + nodeLabels is an array of their label values, or + NULL if there are no labels. +

The choose function can determine either that + the new value matches one of the existing child nodes, or that a new + child node must be added, or that the new value is inconsistent with + the tuple prefix and so the inner tuple must be split to create a + less restrictive prefix. +

If the new value matches one of the existing child nodes, + set resultType to spgMatchNode. + Set nodeN to the index (from zero) of that node in + the node array. + Set levelAdd to the increment in + level caused by descending through that node, + or leave it as zero if the operator class does not use levels. + Set restDatum to equal datum + if the operator class does not modify datums from one level to the + next, or otherwise set it to the modified value to be used as + leafDatum at the next level. +

If a new child node must be added, + set resultType to spgAddNode. + Set nodeLabel to the label to be used for the new + node, and set nodeN to the index (from zero) at which + to insert the node in the node array. + After the node has been added, the choose + function will be called again with the modified inner tuple; + that call should result in an spgMatchNode result. +

If the new value is inconsistent with the tuple prefix, + set resultType to spgSplitTuple. + This action moves all the existing nodes into a new lower-level + inner tuple, and replaces the existing inner tuple with a tuple + having a single node that links to the new lower-level inner tuple. + Set prefixHasPrefix to indicate whether the new + upper tuple should have a prefix, and if so set + prefixPrefixDatum to the prefix value. This new + prefix value must be sufficiently less restrictive than the original + to accept the new value to be indexed, and it should be no longer + than the original prefix. + Set nodeLabel to the label to be used for the + node that will point to the new lower-level inner tuple. + Set postfixHasPrefix to indicate whether the new + lower-level inner tuple should have a prefix, and if so set + postfixPrefixDatum to the prefix value. The + combination of these two prefixes and the additional label must + have the same meaning as the original prefix, because there is + no opportunity to alter the node labels that are moved to the new + lower-level tuple, nor to change any child index entries. + After the node has been split, the choose + function will be called again with the replacement inner tuple. + That call will usually result in an spgAddNode result, + since presumably the node label added in the split step will not + match the new value; so after that, there will be a third call + that finally returns spgMatchNode and allows the + insertion to descend to the leaf level. +

picksplit

Decides how to create a new inner tuple over a set of leaf tuples. +

The SQL declaration of the function must look like this: +

CREATE FUNCTION my_picksplit(internal, internal) RETURNS void ...

+ The first argument is a pointer to a spgPickSplitIn + C struct, containing input data for the function. + The second argument is a pointer to a spgPickSplitOut + C struct, which the function must fill with result data. +

typedef struct spgPickSplitIn
+{
+    int         nTuples;        /* number of leaf tuples */
+    Datum      *datums;         /* their datums (array of length nTuples) */
+    int         level;          /* current level (counting from zero) */
+} spgPickSplitIn;
+
+typedef struct spgPickSplitOut
+{
+    bool        hasPrefix;      /* new inner tuple should have a prefix? */
+    Datum       prefixDatum;    /* if so, its value */
+
+    int         nNodes;         /* number of nodes for new inner tuple */
+    Datum      *nodeLabels;     /* their labels (or NULL for no labels) */
+
+    int        *mapTuplesToNodes;   /* node index for each leaf tuple */
+    Datum      *leafTupleDatums;    /* datum to store in each new leaf tuple */
+} spgPickSplitOut;

+ + nTuples is the number of leaf tuples provided. + datums is an array of their datum values. + level is the current level that all the leaf tuples + share, which will become the level of the new inner tuple. +

Set hasPrefix to indicate whether the new inner + tuple should have a prefix, and if so set + prefixDatum to the prefix value. + Set nNodes to indicate the number of nodes that + the new inner tuple will contain, and + set nodeLabels to an array of their label values. + (If the nodes do not require labels, set nodeLabels + to NULL; see Section 54.3.2 for details.) + Set mapTuplesToNodes to an array that gives the index + (from zero) of the node that each leaf tuple should be assigned to. + Set leafTupleDatums to an array of the values to + be stored in the new leaf tuples (these will be the same as the + input datums if the operator class does not modify + datums from one level to the next). + Note that the picksplit function is + responsible for palloc'ing the + nodeLabels, mapTuplesToNodes and + leafTupleDatums arrays. +

If more than one leaf tuple is supplied, it is expected that the + picksplit function will classify them into more than + one node; otherwise it is not possible to split the leaf tuples + across multiple pages, which is the ultimate purpose of this + operation. Therefore, if the picksplit function + ends up placing all the leaf tuples in the same node, the core + SP-GiST code will override that decision and generate an inner + tuple in which the leaf tuples are assigned at random to several + identically-labeled nodes. Such a tuple is marked + allTheSame to signify that this has happened. The + choose and inner_consistent functions + must take suitable care with such inner tuples. + See Section 54.3.3 for more information. +

picksplit can be applied to a single leaf tuple only + in the case that the config function set + longValuesOK to true and a larger-than-a-page input + value has been supplied. In this case the point of the operation is + to strip off a prefix and produce a new, shorter leaf datum value. + The call will be repeated until a leaf datum short enough to fit on + a page has been produced. See Section 54.3.1 for + more information. +

inner_consistent

Returns set of nodes (branches) to follow during tree search. +

The SQL declaration of the function must look like this: +

CREATE FUNCTION my_inner_consistent(internal, internal) RETURNS void ...

+ The first argument is a pointer to a spgInnerConsistentIn + C struct, containing input data for the function. + The second argument is a pointer to a spgInnerConsistentOut + C struct, which the function must fill with result data. + +

typedef struct spgInnerConsistentIn
+{
+    ScanKey     scankeys;       /* array of operators and comparison values */
+    int         nkeys;          /* length of array */
+
+    Datum       reconstructedValue;     /* value reconstructed at parent */
+    int         level;          /* current level (counting from zero) */
+    bool        returnData;     /* original data must be returned? */
+
+    /* Data from current inner tuple */
+    bool        allTheSame;     /* tuple is marked all-the-same? */
+    bool        hasPrefix;      /* tuple has a prefix? */
+    Datum       prefixDatum;    /* if so, the prefix value */
+    int         nNodes;         /* number of nodes in the inner tuple */
+    Datum      *nodeLabels;     /* node label values (NULL if none) */
+} spgInnerConsistentIn;
+
+typedef struct spgInnerConsistentOut
+{
+    int         nNodes;         /* number of child nodes to be visited */
+    int        *nodeNumbers;    /* their indexes in the node array */
+    int        *levelAdds;      /* increment level by this much for each */
+    Datum      *reconstructedValues;    /* associated reconstructed values */
+} spgInnerConsistentOut;

+ + The array scankeys, of length nkeys, + describes the index search condition(s). These conditions are + combined with AND — only index entries that satisfy all of + them are interesting. (Note that nkeys = 0 implies + that all index entries satisfy the query.) Usually the consistent + function only cares about the sk_strategy and + sk_argument fields of each array entry, which + respectively give the indexable operator and comparison value. + In particular it is not necessary to check sk_flags to + see if the comparison value is NULL, because the SP-GiST core code + will filter out such conditions. + reconstructedValue is the value reconstructed for the + parent tuple; it is (Datum) 0 at the root level or if the + inner_consistent function did not provide a value at the + parent level. + level is the current inner tuple's level, starting at + zero for the root level. + returnData is true if reconstructed data is + required for this query; this will only be so if the + config function asserted canReturnData. + allTheSame is true if the current inner tuple is + marked "all-the-same"; in this case all the nodes have the + same label (if any) and so either all or none of them match the query + (see Section 54.3.3). + hasPrefix is true if the current inner tuple contains + a prefix; if so, + prefixDatum is its value. + nNodes is the number of child nodes contained in the + inner tuple, and + nodeLabels is an array of their label values, or + NULL if the nodes do not have labels. +

nNodes must be set to the number of child nodes that + need to be visited by the search, and + nodeNumbers must be set to an array of their indexes. + If the operator class keeps track of levels, set + levelAdds to an array of the level increments + required when descending to each node to be visited. (Often these + increments will be the same for all the nodes, but that's not + necessarily so, so an array is used.) + If value reconstruction is needed, set + reconstructedValues to an array of the values + reconstructed for each child node to be visited; otherwise, leave + reconstructedValues as NULL. + Note that the inner_consistent function is + responsible for palloc'ing the + nodeNumbers, levelAdds and + reconstructedValues arrays. +

leaf_consistent

Returns true if a leaf tuple satisfies a query. +

The SQL declaration of the function must look like this: +

CREATE FUNCTION my_leaf_consistent(internal, internal) RETURNS bool ...

+ The first argument is a pointer to a spgLeafConsistentIn + C struct, containing input data for the function. + The second argument is a pointer to a spgLeafConsistentOut + C struct, which the function must fill with result data. +

typedef struct spgLeafConsistentIn
+{
+    ScanKey     scankeys;       /* array of operators and comparison values */
+    int         nkeys;          /* length of array */
+
+    Datum       reconstructedValue;     /* value reconstructed at parent */
+    int         level;          /* current level (counting from zero) */
+    bool        returnData;     /* original data must be returned? */
+
+    Datum       leafDatum;      /* datum in leaf tuple */
+} spgLeafConsistentIn;
+
+typedef struct spgLeafConsistentOut
+{
+    Datum       leafValue;      /* reconstructed original data, if any */
+    bool        recheck;        /* set true if operator must be rechecked */
+} spgLeafConsistentOut;

+ + The array scankeys, of length nkeys, + describes the index search condition(s). These conditions are + combined with AND — only index entries that satisfy all of + them satisfy the query. (Note that nkeys = 0 implies + that all index entries satisfy the query.) Usually the consistent + function only cares about the sk_strategy and + sk_argument fields of each array entry, which + respectively give the indexable operator and comparison value. + In particular it is not necessary to check sk_flags to + see if the comparison value is NULL, because the SP-GiST core code + will filter out such conditions. + reconstructedValue is the value reconstructed for the + parent tuple; it is (Datum) 0 at the root level or if the + inner_consistent function did not provide a value at the + parent level. + level is the current leaf tuple's level, starting at + zero for the root level. + returnData is true if reconstructed data is + required for this query; this will only be so if the + config function asserted canReturnData. + leafDatum is the key value stored in the current + leaf tuple. +

The function must return true if the leaf tuple matches the + query, or false if not. In the true case, + if returnData is true then + leafValue must be set to the value originally supplied + to be indexed for this leaf tuple. Also, + recheck may be set to true if the match + is uncertain and so the operator(s) must be re-applied to the actual + heap tuple to verify the match. +

All the SP-GiST support methods are normally called in a short-lived + memory context; that is, CurrentMemoryContext will be reset + after processing of each tuple. It is therefore not very important to + worry about pfree'ing everything you palloc. (The config + method is an exception: it should try to avoid leaking memory. But + usually the config method need do nothing but assign + constants into the passed parameter struct.) +

If the indexed column is of a collatable data type, the index collation + will be passed to all the support methods, using the standard + PG_GET_COLLATION() mechanism. +


PrevHomeNext
IntroductionUpImplementation
\ No newline at end of file diff --git a/doc/src/sgml/html/spgist-implementation.html b/doc/src/sgml/html/spgist-implementation.html new file mode 100644 index 000000000..0270bf74a --- /dev/null +++ b/doc/src/sgml/html/spgist-implementation.html @@ -0,0 +1,382 @@ + +Implementation
PostgreSQL 9.2.2 Documentation
PrevUpChapter 54. SP-GiST IndexesNext

54.3. Implementation

This section covers implementation details and other tricks that are + useful for implementers of SP-GiST operator classes to + know. +

54.3.1. SP-GiST Limits

Individual leaf tuples and inner tuples must fit on a single index page + (8KB by default). Therefore, when indexing values of variable-length + data types, long values can only be supported by methods such as suffix + trees, in which each level of the tree includes a prefix that is short + enough to fit on a page, and the final leaf level includes a suffix also + short enough to fit on a page. The operator class should set + longValuesOK to TRUE only if it is prepared to arrange for + this to happen. Otherwise, the SP-GiST core will + reject any request to index a value that is too large to fit + on an index page. +

Likewise, it is the operator class's responsibility that inner tuples + do not grow too large to fit on an index page; this limits the number + of child nodes that can be used in one inner tuple, as well as the + maximum size of a prefix value. +

Another limitation is that when an inner tuple's node points to a set + of leaf tuples, those tuples must all be in the same index page. + (This is a design decision to reduce seeking and save space in the + links that chain such tuples together.) If the set of leaf tuples + grows too large for a page, a split is performed and an intermediate + inner tuple is inserted. For this to fix the problem, the new inner + tuple must divide the set of leaf values into more than one + node group. If the operator class's picksplit function + fails to do that, the SP-GiST core resorts to + extraordinary measures described in Section 54.3.3. +

54.3.2. SP-GiST Without Node Labels

Some tree algorithms use a fixed set of nodes for each inner tuple; + for example, in a quad-tree there are always exactly four nodes + corresponding to the four quadrants around the inner tuple's centroid + point. In such a case the code typically works with the nodes by + number, and there is no need for explicit node labels. To suppress + node labels (and thereby save some space), the picksplit + function can return NULL for the nodeLabels array. + This will in turn result in nodeLabels being NULL during + subsequent calls to choose and inner_consistent. + In principle, node labels could be used for some inner tuples and omitted + for others in the same index. +

When working with an inner tuple having unlabeled nodes, it is an error + for choose to return spgAddNode, since the set + of nodes is supposed to be fixed in such cases. Also, there is no + provision for generating an unlabeled node in spgSplitTuple + actions, since it is expected that an spgAddNode action will + be needed as well. +

54.3.3. "All-the-same" Inner Tuples

The SP-GiST core can override the results of the + operator class's picksplit function when + picksplit fails to divide the supplied leaf values into + at least two node categories. When this happens, the new inner tuple + is created with multiple nodes that each have the same label (if any) + that picksplit gave to the one node it did use, and the + leaf values are divided at random among these equivalent nodes. + The allTheSame flag is set on the inner tuple to warn the + choose and inner_consistent functions that the + tuple does not have the node set that they might otherwise expect. +

When dealing with an allTheSame tuple, a choose + result of spgMatchNode is interpreted to mean that the new + value can be assigned to any of the equivalent nodes; the core code will + ignore the supplied nodeN value and descend into one + of the nodes at random (so as to keep the tree balanced). It is an + error for choose to return spgAddNode, since + that would make the nodes not all equivalent; the + spgSplitTuple action must be used if the value to be inserted + doesn't match the existing nodes. +

When dealing with an allTheSame tuple, the + inner_consistent function should return either all or none + of the nodes as targets for continuing the index search, since they are + all equivalent. This may or may not require any special-case code, + depending on how much the inner_consistent function normally + assumes about the meaning of the nodes. +


PrevHomeNext
ExtensibilityUpExamples
\ No newline at end of file diff --git a/doc/src/sgml/html/spgist-intro.html b/doc/src/sgml/html/spgist-intro.html new file mode 100644 index 000000000..27845f3a8 --- /dev/null +++ b/doc/src/sgml/html/spgist-intro.html @@ -0,0 +1,231 @@ + +Introduction
PostgreSQL 9.2.2 Documentation
PrevUpChapter 54. SP-GiST IndexesNext

54.1. Introduction

SP-GiST is an abbreviation for space-partitioned + GiST. SP-GiST supports partitioned + search trees, which facilitate development of a wide range of different + non-balanced data structures, such as quad-trees, k-d trees, and suffix + trees (tries). The common feature of these structures is that they + repeatedly divide the search space into partitions that need not be + of equal size. Searches that are well matched to the partitioning rule + can be very fast. +

These popular data structures were originally developed for in-memory + usage. In main memory, they are usually designed as a set of dynamically + allocated nodes linked by pointers. This is not suitable for direct + storing on disk, since these chains of pointers can be rather long which + would require too many disk accesses. In contrast, disk-based data + structures should have a high fanout to minimize I/O. The challenge + addressed by SP-GiST is to map search tree nodes to + disk pages in such a way that a search need access only a few disk pages, + even if it traverses many nodes. +

Like GiST, SP-GiST is meant to allow + the development of custom data types with the appropriate access methods, + by an expert in the domain of the data type, rather than a database expert. +

Some of the information here is derived from Purdue University's + SP-GiST Indexing Project + web site. + The SP-GiST implementation in + PostgreSQL is primarily maintained by Teodor + Sigaev and Oleg Bartunov, and there is more information on their + + web site. +


PrevHomeNext
SP-GiST IndexesUpExtensibility
\ No newline at end of file diff --git a/doc/src/sgml/html/spgist.html b/doc/src/sgml/html/spgist.html new file mode 100644 index 000000000..fa414dfd7 --- /dev/null +++ b/doc/src/sgml/html/spgist.html @@ -0,0 +1,213 @@ + +SP-GiST Indexes

Chapter 54. SP-GiST Indexes


PrevHomeNext
ExamplesUpIntroduction
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-examples.html b/doc/src/sgml/html/spi-examples.html new file mode 100644 index 000000000..c3cc5bfb4 --- /dev/null +++ b/doc/src/sgml/html/spi-examples.html @@ -0,0 +1,342 @@ + +Examples
PostgreSQL 9.2.2 Documentation
PrevUpChapter 43. Server Programming InterfaceNext

43.5. Examples

This section contains a very simple example of SPI usage. The + procedure execq takes an SQL command as its + first argument and a row count as its second, executes the command + using SPI_exec and returns the number of rows + that were processed by the command. You can find more complex + examples for SPI in the source tree in + src/test/regress/regress.c and in the + spi module. +

#include "postgres.h"
+
+#include "executor/spi.h"
+#include "utils/builtins.h"
+
+#ifdef PG_MODULE_MAGIC
+PG_MODULE_MAGIC;
+#endif
+
+int execq(text *sql, int cnt);
+
+int
+execq(text *sql, int cnt)
+{
+    char *command;
+    int ret;
+    int proc;
+
+    /* Convert given text object to a C string */
+    command = text_to_cstring(sql);
+
+    SPI_connect();
+
+    ret = SPI_exec(command, cnt);
+
+    proc = SPI_processed;
+    /*
+     * If some rows were fetched, print them via elog(INFO).
+     */
+    if (ret > 0 && SPI_tuptable != NULL)
+    {
+        TupleDesc tupdesc = SPI_tuptable->tupdesc;
+        SPITupleTable *tuptable = SPI_tuptable;
+        char buf[8192];
+        int i, j;
+
+        for (j = 0; j < proc; j++)
+        {
+            HeapTuple tuple = tuptable->vals[j];
+
+            for (i = 1, buf[0] = 0; i <= tupdesc->natts; i++)
+                snprintf(buf + strlen (buf), sizeof(buf) - strlen(buf), " %s%s",
+                        SPI_getvalue(tuple, tupdesc, i),
+                        (i == tupdesc->natts) ? " " : " |");
+            elog(INFO, "EXECQ: %s", buf);
+        }
+    }
+
+    SPI_finish();
+    pfree(command);
+
+    return (proc);
+}

(This function uses call convention version 0, to make the example + easier to understand. In real applications you should use the new + version 1 interface.) +

This is how you declare the function after having compiled it into + a shared library (details are in Section 35.9.6.): + +

CREATE FUNCTION execq(text, integer) RETURNS integer
+    AS 'filename'
+    LANGUAGE C;

+

Here is a sample session: + +

=> SELECT execq('CREATE TABLE a (x integer)', 0);
+ execq
+-------
+     0
+(1 row)
+
+=> INSERT INTO a VALUES (execq('INSERT INTO a VALUES (0)', 0));
+INSERT 0 1
+=> SELECT execq('SELECT * FROM a', 0);
+INFO:  EXECQ:  0    -- inserted by execq
+INFO:  EXECQ:  1    -- returned by execq and inserted by upper INSERT
+
+ execq
+-------
+     2
+(1 row)
+
+=> SELECT execq('INSERT INTO a SELECT x + 2 FROM a', 1);
+ execq
+-------
+     1
+(1 row)
+
+=> SELECT execq('SELECT * FROM a', 10);
+INFO:  EXECQ:  0
+INFO:  EXECQ:  1
+INFO:  EXECQ:  2    -- 0 + 2, only one row inserted - as specified
+
+ execq
+-------
+     3              -- 10 is the max value only, 3 is the real number of rows
+(1 row)
+
+=> DELETE FROM a;
+DELETE 3
+=> INSERT INTO a VALUES (execq('SELECT * FROM a', 0) + 1);
+INSERT 0 1
+=> SELECT * FROM a;
+ x
+---
+ 1                  -- no rows in a (0) + 1
+(1 row)
+
+=> INSERT INTO a VALUES (execq('SELECT * FROM a', 0) + 1);
+INFO:  EXECQ:  1
+INSERT 0 1
+=> SELECT * FROM a;
+ x
+---
+ 1
+ 2                  -- there was one row in a + 1
+(2 rows)
+
+-- This demonstrates the data changes visibility rule:
+
+=> INSERT INTO a SELECT execq('SELECT * FROM a', 0) * x FROM a;
+INFO:  EXECQ:  1
+INFO:  EXECQ:  2
+INFO:  EXECQ:  1
+INFO:  EXECQ:  2
+INFO:  EXECQ:  2
+INSERT 0 2
+=> SELECT * FROM a;
+ x
+---
+ 1
+ 2
+ 2                  -- 2 rows * 1 (x in first row)
+ 6                  -- 3 rows (2 + 1 just inserted) * 2 (x in second row)
+(4 rows)               ^^^^^^
+                       rows visible to execq() in different invocations

+


PrevHomeNext
Visibility of Data ChangesUpReference
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-interface-support.html b/doc/src/sgml/html/spi-interface-support.html new file mode 100644 index 000000000..ca1260c2c --- /dev/null +++ b/doc/src/sgml/html/spi-interface-support.html @@ -0,0 +1,227 @@ + +Interface Support Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 43. Server Programming InterfaceNext

43.2. Interface Support Functions

Table of Contents
SPI_fname -- determine the column name for the specified column number
SPI_fnumber -- determine the column number for the specified column name
SPI_getvalue -- return the string value of the specified column
SPI_getbinval -- return the binary value of the specified column
SPI_gettype -- return the data type name of the specified column
SPI_gettypeid -- return the data type OID of the specified column
SPI_getrelname -- return the name of the specified relation
SPI_getnspname -- return the namespace of the specified relation

The functions described here provide an interface for extracting + information from result sets returned by SPI_execute and + other SPI functions. +

All functions described in this section can be used by both + connected and unconnected procedures. +


PrevHomeNext
SPI_saveplanUpSPI_fname
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-interface.html b/doc/src/sgml/html/spi-interface.html new file mode 100644 index 000000000..55702d4cb --- /dev/null +++ b/doc/src/sgml/html/spi-interface.html @@ -0,0 +1,335 @@ + +Interface Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 43. Server Programming InterfaceNext

43.1. Interface Functions

Table of Contents
SPI_connect -- connect a procedure to the SPI manager
SPI_finish -- disconnect a procedure from the SPI manager
SPI_push -- push SPI stack to allow recursive SPI usage
SPI_pop -- pop SPI stack to return from recursive SPI usage
SPI_execute -- execute a command
SPI_exec -- execute a read/write command
SPI_execute_with_args -- execute a command with out-of-line parameters
SPI_prepare -- prepare a statement, without executing it yet
SPI_prepare_cursor -- prepare a statement, without executing it yet
SPI_prepare_params -- prepare a statement, without executing it yet
SPI_getargcount -- return the number of arguments needed by a statement + prepared by SPI_prepare
SPI_getargtypeid -- return the data type OID for an argument of + a statement prepared by SPI_prepare
SPI_is_cursor_plan -- return true if a statement + prepared by SPI_prepare can be used with + SPI_cursor_open
SPI_execute_plan -- execute a statement prepared by SPI_prepare
SPI_execute_plan_with_paramlist -- execute a statement prepared by SPI_prepare
SPI_execp -- execute a statement in read/write mode
SPI_cursor_open -- set up a cursor using a statement created with SPI_prepare
SPI_cursor_open_with_args -- set up a cursor using a query and parameters
SPI_cursor_open_with_paramlist -- set up a cursor using parameters
SPI_cursor_find -- find an existing cursor by name
SPI_cursor_fetch -- fetch some rows from a cursor
SPI_cursor_move -- move a cursor
SPI_scroll_cursor_fetch -- fetch some rows from a cursor
SPI_scroll_cursor_move -- move a cursor
SPI_cursor_close -- close a cursor
SPI_keepplan -- save a prepared statement
SPI_saveplan -- save a prepared statement

PrevHomeNext
Server Programming InterfaceUpSPI_connect
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-memory.html b/doc/src/sgml/html/spi-memory.html new file mode 100644 index 000000000..f3689f25d --- /dev/null +++ b/doc/src/sgml/html/spi-memory.html @@ -0,0 +1,363 @@ + +Memory Management
PostgreSQL 9.2.2 Documentation
PrevUpChapter 43. Server Programming InterfaceNext

43.3. Memory Management

Table of Contents
SPI_palloc -- allocate memory in the upper executor context
SPI_repalloc -- reallocate memory in the upper executor context
SPI_pfree -- free memory in the upper executor context
SPI_copytuple -- make a copy of a row in the upper executor context
SPI_returntuple -- prepare to return a tuple as a Datum
SPI_modifytuple -- create a row by replacing selected fields of a given row
SPI_freetuple -- free a row allocated in the upper executor context
SPI_freetuptable -- free a row set created by SPI_execute or a similar + function
SPI_freeplan -- free a previously saved prepared statement

+ PostgreSQL allocates memory within + memory contexts, which provide a convenient method of + managing allocations made in many different places that need to + live for differing amounts of time. Destroying a context releases + all the memory that was allocated in it. Thus, it is not necessary + to keep track of individual objects to avoid memory leaks; instead + only a relatively small number of contexts have to be managed. + palloc and related functions allocate memory + from the "current" context. +

SPI_connect creates a new memory context and + makes it current. SPI_finish restores the + previous current memory context and destroys the context created by + SPI_connect. These actions ensure that + transient memory allocations made inside your procedure are + reclaimed at procedure exit, avoiding memory leakage. +

However, if your procedure needs to return an object in allocated + memory (such as a value of a pass-by-reference data type), you + cannot allocate that memory using palloc, at + least not while you are connected to SPI. If you try, the object + will be deallocated by SPI_finish, and your + procedure will not work reliably. To solve this problem, use + SPI_palloc to allocate memory for your return + object. SPI_palloc allocates memory in the + "upper executor context", that is, the memory context + that was current when SPI_connect was called, + which is precisely the right context for a value returned from your + procedure. +

If SPI_palloc is called while the procedure is + not connected to SPI, then it acts the same as a normal + palloc. Before a procedure connects to the + SPI manager, the current memory context is the upper executor + context, so all allocations made by the procedure via + palloc or by SPI utility functions are made in + this context. +

When SPI_connect is called, the private + context of the procedure, which is created by + SPI_connect, is made the current context. All + allocations made by palloc, + repalloc, or SPI utility functions (except for + SPI_copytuple, + SPI_returntuple, + SPI_modifytuple, and + SPI_palloc) are made in this context. When a + procedure disconnects from the SPI manager (via + SPI_finish) the current context is restored to + the upper executor context, and all allocations made in the + procedure memory context are freed and cannot be used any more. +

All functions described in this section can be used by both + connected and unconnected procedures. In an unconnected procedure, + they act the same as the underlying ordinary server functions + (palloc, etc.). +


PrevHomeNext
SPI_getnspnameUpSPI_palloc
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-realloc.html b/doc/src/sgml/html/spi-realloc.html new file mode 100644 index 000000000..8654a4d46 --- /dev/null +++ b/doc/src/sgml/html/spi-realloc.html @@ -0,0 +1,263 @@ + +SPI_repalloc

SPI_repalloc

Name

SPI_repalloc -- reallocate memory in the upper executor context

Synopsis

void * SPI_repalloc(void * pointer, Size size)

Description

SPI_repalloc changes the size of a memory + segment previously allocated using SPI_palloc. +

This function is no longer different from plain + repalloc. It's kept just for backward + compatibility of existing code. +

Arguments

void * pointer

pointer to existing storage to change +

Size size

size in bytes of storage to allocate +

Return Value

pointer to new storage space of specified size with the contents + copied from the existing area +


PrevHomeNext
SPI_pallocUpSPI_pfree
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-connect.html b/doc/src/sgml/html/spi-spi-connect.html new file mode 100644 index 000000000..57946bd8f --- /dev/null +++ b/doc/src/sgml/html/spi-spi-connect.html @@ -0,0 +1,274 @@ + +SPI_connect

SPI_connect

Name

SPI_connect -- connect a procedure to the SPI manager

Synopsis

int SPI_connect(void)

Description

SPI_connect opens a connection from a + procedure invocation to the SPI manager. You must call this + function if you want to execute commands through SPI. Some utility + SPI functions can be called from unconnected procedures. +

If your procedure is already connected, + SPI_connect will return the error code + SPI_ERROR_CONNECT. This could happen if + a procedure that has called SPI_connect + directly calls another procedure that calls + SPI_connect. While recursive calls to the + SPI manager are permitted when an SQL command + called through SPI invokes another function that uses + SPI, directly nested calls to + SPI_connect and + SPI_finish are forbidden. + (But see SPI_push and SPI_pop.) +

Return Value

SPI_OK_CONNECT

on success +

SPI_ERROR_CONNECT

on error +


PrevHomeNext
Interface FunctionsUpSPI_finish
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-copytuple.html b/doc/src/sgml/html/spi-spi-copytuple.html new file mode 100644 index 000000000..cab825fb1 --- /dev/null +++ b/doc/src/sgml/html/spi-spi-copytuple.html @@ -0,0 +1,250 @@ + +SPI_copytuple

SPI_copytuple

Name

SPI_copytuple -- make a copy of a row in the upper executor context

Synopsis

HeapTuple SPI_copytuple(HeapTuple row)

Description

SPI_copytuple makes a copy of a row in the + upper executor context. This is normally used to return a modified + row from a trigger. In a function declared to return a composite + type, use SPI_returntuple instead. +

Arguments

HeapTuple row

row to be copied +

Return Value

the copied row; NULL only if + tuple is NULL +


PrevHomeNext
SPI_pfreeUpSPI_returntuple
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-cursor-close.html b/doc/src/sgml/html/spi-spi-cursor-close.html new file mode 100644 index 000000000..4845ea545 --- /dev/null +++ b/doc/src/sgml/html/spi-spi-cursor-close.html @@ -0,0 +1,232 @@ + +SPI_cursor_close

SPI_cursor_close

Name

SPI_cursor_close -- close a cursor

Synopsis

void SPI_cursor_close(Portal portal)

Description

SPI_cursor_close closes a previously created + cursor and releases its portal storage. +

All open cursors are closed automatically at the end of a + transaction. SPI_cursor_close need only be + invoked if it is desirable to release resources sooner. +

Arguments

Portal portal

portal containing the cursor +


PrevHomeNext
SPI_scroll_cursor_moveUpSPI_keepplan
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-cursor-fetch.html b/doc/src/sgml/html/spi-spi-cursor-fetch.html new file mode 100644 index 000000000..3e9a19f78 --- /dev/null +++ b/doc/src/sgml/html/spi-spi-cursor-fetch.html @@ -0,0 +1,301 @@ + +SPI_cursor_fetch

SPI_cursor_fetch

Name

SPI_cursor_fetch -- fetch some rows from a cursor

Synopsis

void SPI_cursor_fetch(Portal portal, bool forward, long count)

Description

SPI_cursor_fetch fetches some rows from a + cursor. This is equivalent to a subset of the SQL command + FETCH (see SPI_scroll_cursor_fetch + for more functionality). +

Arguments

Portal portal

portal containing the cursor +

bool forward

true for fetch forward, false for fetch backward +

long count

maximum number of rows to fetch +

Return Value

SPI_processed and + SPI_tuptable are set as in + SPI_execute if successful. +

Notes

Fetching backward may fail if the cursor's plan was not created + with the CURSOR_OPT_SCROLL option. +


PrevHomeNext
SPI_cursor_findUpSPI_cursor_move
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-cursor-find.html b/doc/src/sgml/html/spi-spi-cursor-find.html new file mode 100644 index 000000000..43670a0f5 --- /dev/null +++ b/doc/src/sgml/html/spi-spi-cursor-find.html @@ -0,0 +1,240 @@ + +SPI_cursor_find

SPI_cursor_find

Name

SPI_cursor_find -- find an existing cursor by name

Synopsis

Portal SPI_cursor_find(const char * name)

Description

SPI_cursor_find finds an existing portal by + name. This is primarily useful to resolve a cursor name returned + as text by some other function. +

Arguments

const char * name

name of the portal +

Return Value

pointer to the portal with the specified name, or + NULL if none was found +


PrevHomeNext
SPI_cursor_open_with_paramlistUpSPI_cursor_fetch
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-cursor-move.html b/doc/src/sgml/html/spi-spi-cursor-move.html new file mode 100644 index 000000000..9e388248e --- /dev/null +++ b/doc/src/sgml/html/spi-spi-cursor-move.html @@ -0,0 +1,279 @@ + +SPI_cursor_move

SPI_cursor_move

Name

SPI_cursor_move -- move a cursor

Synopsis

void SPI_cursor_move(Portal portal, bool forward, long count)

Description

SPI_cursor_move skips over some number of rows + in a cursor. This is equivalent to a subset of the SQL command + MOVE (see SPI_scroll_cursor_move + for more functionality). +

Arguments

Portal portal

portal containing the cursor +

bool forward

true for move forward, false for move backward +

long count

maximum number of rows to move +

Notes

Moving backward may fail if the cursor's plan was not created + with the CURSOR_OPT_SCROLL option. +


PrevHomeNext
SPI_cursor_fetchUpSPI_scroll_cursor_fetch
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-cursor-open-with-args.html b/doc/src/sgml/html/spi-spi-cursor-open-with-args.html new file mode 100644 index 000000000..fa9ac6b0c --- /dev/null +++ b/doc/src/sgml/html/spi-spi-cursor-open-with-args.html @@ -0,0 +1,412 @@ + +SPI_cursor_open_with_args

SPI_cursor_open_with_args

Name

SPI_cursor_open_with_args -- set up a cursor using a query and parameters

Synopsis

Portal SPI_cursor_open_with_args(const char *name,
+                                 const char *command,
+                                 int nargs, Oid *argtypes,
+                                 Datum *values, const char *nulls,
+                                 bool read_only, int cursorOptions)

Description

SPI_cursor_open_with_args sets up a cursor + (internally, a portal) that will execute the specified query. + Most of the parameters have the same meanings as the corresponding + parameters to SPI_prepare_cursor + and SPI_cursor_open. +

For one-time query execution, this function should be preferred + over SPI_prepare_cursor followed by + SPI_cursor_open. + If the same command is to be executed with many different parameters, + either method might be faster, depending on the cost of re-planning + versus the benefit of custom plans. +

The passed-in parameter data will be copied into the cursor's portal, so it + can be freed while the cursor still exists. +

Arguments

const char * name

name for portal, or NULL to let the system + select a name +

const char * command

command string +

int nargs

number of input parameters ($1, $2, etc.) +

Oid * argtypes

an array containing the OIDs of + the data types of the parameters +

Datum * values

an array of actual parameter values +

const char * nulls

an array describing which parameters are null +

If nulls is NULL then + SPI_cursor_open_with_args assumes that no + parameters are null. +

bool read_only

true for read-only execution

int cursorOptions

integer bit mask of cursor options; zero produces default behavior +

Return Value

Pointer to portal containing the cursor. Note there is no error + return convention; any error will be reported via elog. +


PrevHomeNext
SPI_cursor_openUpSPI_cursor_open_with_paramlist
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-cursor-open-with-paramlist.html b/doc/src/sgml/html/spi-spi-cursor-open-with-paramlist.html new file mode 100644 index 000000000..d14ae27d6 --- /dev/null +++ b/doc/src/sgml/html/spi-spi-cursor-open-with-paramlist.html @@ -0,0 +1,322 @@ + +SPI_cursor_open_with_paramlist

SPI_cursor_open_with_paramlist

Name

SPI_cursor_open_with_paramlist -- set up a cursor using parameters

Synopsis

Portal SPI_cursor_open_with_paramlist(const char *name,
+                                      SPIPlanPtr plan,
+                                      ParamListInfo params,
+                                      bool read_only)

Description

SPI_cursor_open_with_paramlist sets up a cursor + (internally, a portal) that will execute a statement prepared by + SPI_prepare. + This function is equivalent to SPI_cursor_open + except that information about the parameter values to be passed to the + query is presented differently. The ParamListInfo + representation can be convenient for passing down values that are + already available in that format. It also supports use of dynamic + parameter sets via hook functions specified in ParamListInfo. +

The passed-in parameter data will be copied into the cursor's portal, so it + can be freed while the cursor still exists. +

Arguments

const char * name

name for portal, or NULL to let the system + select a name +

SPIPlanPtr plan

prepared statement (returned by SPI_prepare) +

ParamListInfo params

data structure containing parameter types and values; NULL if none +

bool read_only

true for read-only execution

Return Value

Pointer to portal containing the cursor. Note there is no error + return convention; any error will be reported via elog. +


PrevHomeNext
SPI_cursor_open_with_argsUpSPI_cursor_find
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-cursor-open.html b/doc/src/sgml/html/spi-spi-cursor-open.html new file mode 100644 index 000000000..68cf09ca2 --- /dev/null +++ b/doc/src/sgml/html/spi-spi-cursor-open.html @@ -0,0 +1,367 @@ + +SPI_cursor_open

SPI_cursor_open

Name

SPI_cursor_open -- set up a cursor using a statement created with SPI_prepare

Synopsis

Portal SPI_cursor_open(const char * name, SPIPlanPtr plan,
+                       Datum * values, const char * nulls,
+                       bool read_only)

Description

SPI_cursor_open sets up a cursor (internally, + a portal) that will execute a statement prepared by + SPI_prepare. The parameters have the same + meanings as the corresponding parameters to + SPI_execute_plan. +

Using a cursor instead of executing the statement directly has two + benefits. First, the result rows can be retrieved a few at a time, + avoiding memory overrun for queries that return many rows. Second, + a portal can outlive the current procedure (it can, in fact, live + to the end of the current transaction). Returning the portal name + to the procedure's caller provides a way of returning a row set as + result. +

The passed-in parameter data will be copied into the cursor's portal, so it + can be freed while the cursor still exists. +

Arguments

const char * name

name for portal, or NULL to let the system + select a name +

SPIPlanPtr plan

prepared statement (returned by SPI_prepare) +

Datum * values

An array of actual parameter values. Must have same length as the + statement's number of arguments. +

const char * nulls

An array describing which parameters are null. Must have same length as + the statement's number of arguments. + n indicates a null value (entry in + values will be ignored); a space indicates a + nonnull value (entry in values is valid). +

If nulls is NULL then + SPI_cursor_open assumes that no parameters are + null. +

bool read_only

true for read-only execution

Return Value

Pointer to portal containing the cursor. Note there is no error + return convention; any error will be reported via elog. +


PrevHomeNext
SPI_execpUpSPI_cursor_open_with_args
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-exec.html b/doc/src/sgml/html/spi-spi-exec.html new file mode 100644 index 000000000..7f22090ad --- /dev/null +++ b/doc/src/sgml/html/spi-spi-exec.html @@ -0,0 +1,265 @@ + +SPI_exec

SPI_exec

Name

SPI_exec -- execute a read/write command

Synopsis

int SPI_exec(const char * command, long count)

Description

SPI_exec is the same as + SPI_execute, with the latter's + read_only parameter always taken as + false. +

Arguments

const char * command

string containing command to execute +

long count

maximum number of rows to process or return +

Return Value

See SPI_execute. +


PrevHomeNext
SPI_executeUpSPI_execute_with_args
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-execp.html b/doc/src/sgml/html/spi-spi-execp.html new file mode 100644 index 000000000..2b9addacf --- /dev/null +++ b/doc/src/sgml/html/spi-spi-execp.html @@ -0,0 +1,342 @@ + +SPI_execp

SPI_execp

Name

SPI_execp -- execute a statement in read/write mode

Synopsis

int SPI_execp(SPIPlanPtr plan, Datum * values, const char * nulls, long count)

Description

SPI_execp is the same as + SPI_execute_plan, with the latter's + read_only parameter always taken as + false. +

Arguments

SPIPlanPtr plan

prepared statement (returned by SPI_prepare) +

Datum * values

An array of actual parameter values. Must have same length as the + statement's number of arguments. +

const char * nulls

An array describing which parameters are null. Must have same length as + the statement's number of arguments. + n indicates a null value (entry in + values will be ignored); a space indicates a + nonnull value (entry in values is valid). +

If nulls is NULL then + SPI_execp assumes that no parameters are + null. +

long count

maximum number of rows to process or return +

Return Value

See SPI_execute_plan. +

SPI_processed and + SPI_tuptable are set as in + SPI_execute if successful. +


PrevHomeNext
SPI_execute_plan_with_paramlistUpSPI_cursor_open
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-execute-plan-with-paramlist.html b/doc/src/sgml/html/spi-spi-execute-plan-with-paramlist.html new file mode 100644 index 000000000..173ba8e2b --- /dev/null +++ b/doc/src/sgml/html/spi-spi-execute-plan-with-paramlist.html @@ -0,0 +1,329 @@ + +SPI_execute_plan_with_paramlist

SPI_execute_plan_with_paramlist

Name

SPI_execute_plan_with_paramlist -- execute a statement prepared by SPI_prepare

Synopsis

int SPI_execute_plan_with_paramlist(SPIPlanPtr plan,
+                                    ParamListInfo params,
+                                    bool read_only,
+                                    long count)

Description

SPI_execute_plan_with_paramlist executes a statement + prepared by SPI_prepare. + This function is equivalent to SPI_execute_plan + except that information about the parameter values to be passed to the + query is presented differently. The ParamListInfo + representation can be convenient for passing down values that are + already available in that format. It also supports use of dynamic + parameter sets via hook functions specified in ParamListInfo. +

Arguments

SPIPlanPtr plan

prepared statement (returned by SPI_prepare) +

ParamListInfo params

data structure containing parameter types and values; NULL if none +

bool read_only

true for read-only execution

long count

maximum number of rows to process or return +

Return Value

The return value is the same as for SPI_execute_plan. +

SPI_processed and + SPI_tuptable are set as in + SPI_execute_plan if successful. +


PrevHomeNext
SPI_execute_planUpSPI_execp
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-execute-plan.html b/doc/src/sgml/html/spi-spi-execute-plan.html new file mode 100644 index 000000000..98b7cb7da --- /dev/null +++ b/doc/src/sgml/html/spi-spi-execute-plan.html @@ -0,0 +1,418 @@ + +SPI_execute_plan

SPI_execute_plan

Name

SPI_execute_plan -- execute a statement prepared by SPI_prepare

Synopsis

int SPI_execute_plan(SPIPlanPtr plan, Datum * values, const char * nulls,
+                     bool read_only, long count)

Description

SPI_execute_plan executes a statement prepared by + SPI_prepare or one of its siblings. + read_only and + count have the same interpretation as in + SPI_execute. +

Arguments

SPIPlanPtr plan

prepared statement (returned by SPI_prepare) +

Datum * values

An array of actual parameter values. Must have same length as the + statement's number of arguments. +

const char * nulls

An array describing which parameters are null. Must have same length as + the statement's number of arguments. + n indicates a null value (entry in + values will be ignored); a space indicates a + nonnull value (entry in values is valid). +

If nulls is NULL then + SPI_execute_plan assumes that no parameters are + null. +

bool read_only

true for read-only execution

long count

maximum number of rows to process or return +

Return Value

The return value is the same as for SPI_execute, + with the following additional possible error (negative) results: + +

SPI_ERROR_ARGUMENT

if plan is NULL or invalid, + or count is less than 0 +

SPI_ERROR_PARAM

if values is NULL and + plan was prepared with some parameters +

+

SPI_processed and + SPI_tuptable are set as in + SPI_execute if successful. +


PrevHomeNext
SPI_is_cursor_planUpSPI_execute_plan_with_paramlist
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-execute-with-args.html b/doc/src/sgml/html/spi-spi-execute-with-args.html new file mode 100644 index 000000000..edb7702cb --- /dev/null +++ b/doc/src/sgml/html/spi-spi-execute-with-args.html @@ -0,0 +1,423 @@ + +SPI_execute_with_args

SPI_execute_with_args

Name

SPI_execute_with_args -- execute a command with out-of-line parameters

Synopsis

int SPI_execute_with_args(const char *command,
+                          int nargs, Oid *argtypes,
+                          Datum *values, const char *nulls,
+                          bool read_only, long count)

Description

SPI_execute_with_args executes a command that might + include references to externally supplied parameters. The command text + refers to a parameter as $n, and + the call specifies data types and values for each such symbol. + read_only and count have + the same interpretation as in SPI_execute. +

The main advantage of this routine compared to + SPI_execute is that data values can be inserted + into the command without tedious quoting/escaping, and thus with much + less risk of SQL-injection attacks. +

Similar results can be achieved with SPI_prepare followed by + SPI_execute_plan; however, when using this function + the query plan is always customized to the specific parameter values + provided. + For one-time query execution, this function should be preferred. + If the same command is to be executed with many different parameters, + either method might be faster, depending on the cost of re-planning + versus the benefit of custom plans. +

Arguments

const char * command

command string +

int nargs

number of input parameters ($1, $2, etc.) +

Oid * argtypes

an array containing the OIDs of + the data types of the parameters +

Datum * values

an array of actual parameter values +

const char * nulls

an array describing which parameters are null +

If nulls is NULL then + SPI_execute_with_args assumes that no parameters are + null. +

bool read_only

true for read-only execution

long count

maximum number of rows to process or return +

Return Value

The return value is the same as for SPI_execute. +

SPI_processed and + SPI_tuptable are set as in + SPI_execute if successful. +


PrevHomeNext
SPI_execUpSPI_prepare
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-execute.html b/doc/src/sgml/html/spi-spi-execute.html new file mode 100644 index 000000000..ff5ff619d --- /dev/null +++ b/doc/src/sgml/html/spi-spi-execute.html @@ -0,0 +1,777 @@ + +SPI_execute

SPI_execute

Name

SPI_execute -- execute a command

Synopsis

int SPI_execute(const char * command, bool read_only, long count)

Description

SPI_execute executes the specified SQL command + for count rows. If read_only + is true, the command must be read-only, and execution overhead + is somewhat reduced. +

This function can only be called from a connected procedure. +

If count is zero then the command is executed + for all rows that it applies to. If count + is greater than 0, then the number of rows for which the command + will be executed is restricted (much like a + LIMIT clause). For example: +

SPI_execute("INSERT INTO foo SELECT * FROM bar", false, 5);

+ will allow at most 5 rows to be inserted into the table. +

You can pass multiple commands in one string, but later commands cannot + depend on the creation of objects earlier in the string, because the + whole string will be parsed and planned before execution begins. + SPI_execute returns the + result for the command executed last. The count + limit applies to each command separately, but it is not applied to + hidden commands generated by rules. +

When read_only is false, + SPI_execute increments the command + counter and computes a new snapshot before executing each + command in the string. The snapshot does not actually change if the + current transaction isolation level is SERIALIZABLE or REPEATABLE READ, but in + READ COMMITTED mode the snapshot update allows each command to + see the results of newly committed transactions from other sessions. + This is essential for consistent behavior when the commands are modifying + the database. +

When read_only is true, + SPI_execute does not update either the snapshot + or the command counter, and it allows only plain SELECT + commands to appear in the command string. The commands are executed + using the snapshot previously established for the surrounding query. + This execution mode is somewhat faster than the read/write mode due + to eliminating per-command overhead. It also allows genuinely + stable functions to be built: since successive executions + will all use the same snapshot, there will be no change in the results. +

It is generally unwise to mix read-only and read-write commands within + a single function using SPI; that could result in very confusing behavior, + since the read-only queries would not see the results of any database + updates done by the read-write queries. +

The actual number of rows for which the (last) command was executed + is returned in the global variable SPI_processed. + If the return value of the function is SPI_OK_SELECT, + SPI_OK_INSERT_RETURNING, + SPI_OK_DELETE_RETURNING, or + SPI_OK_UPDATE_RETURNING, + then you can use the + global pointer SPITupleTable *SPI_tuptable to + access the result rows. Some utility commands (such as + EXPLAIN) also return row sets, and SPI_tuptable + will contain the result in these cases too. +

The structure SPITupleTable is defined + thus: +

typedef struct
+{
+    MemoryContext tuptabcxt;    /* memory context of result table */
+    uint32      alloced;        /* number of alloced vals */
+    uint32      free;           /* number of free vals */
+    TupleDesc   tupdesc;        /* row descriptor */
+    HeapTuple  *vals;           /* rows */
+} SPITupleTable;

vals is an array of pointers to rows. (The number + of valid entries is given by SPI_processed.) + tupdesc is a row descriptor which you can pass to + SPI functions dealing with rows. tuptabcxt, + alloced, and free are internal + fields not intended for use by SPI callers. +

SPI_finish frees all + SPITupleTables allocated during the current + procedure. You can free a particular result table earlier, if you + are done with it, by calling SPI_freetuptable. +

Arguments

const char * command

string containing command to execute +

bool read_only

true for read-only execution

long count

maximum number of rows to process or return +

Return Value

If the execution of the command was successful then one of the + following (nonnegative) values will be returned: + +

SPI_OK_SELECT

if a SELECT (but not SELECT + INTO) was executed +

SPI_OK_SELINTO

if a SELECT INTO was executed +

SPI_OK_INSERT

if an INSERT was executed +

SPI_OK_DELETE

if a DELETE was executed +

SPI_OK_UPDATE

if an UPDATE was executed +

SPI_OK_INSERT_RETURNING

if an INSERT RETURNING was executed +

SPI_OK_DELETE_RETURNING

if a DELETE RETURNING was executed +

SPI_OK_UPDATE_RETURNING

if an UPDATE RETURNING was executed +

SPI_OK_UTILITY

if a utility command (e.g., CREATE TABLE) + was executed +

SPI_OK_REWRITTEN

if the command was rewritten into another kind of command (e.g., + UPDATE became an INSERT) by a rule. +

+

On error, one of the following negative values is returned: + +

SPI_ERROR_ARGUMENT

if command is NULL or + count is less than 0 +

SPI_ERROR_COPY

if COPY TO stdout or COPY FROM stdin + was attempted +

SPI_ERROR_TRANSACTION

if a transaction manipulation command was attempted + (BEGIN, + COMMIT, + ROLLBACK, + SAVEPOINT, + PREPARE TRANSACTION, + COMMIT PREPARED, + ROLLBACK PREPARED, + or any variant thereof) +

SPI_ERROR_OPUNKNOWN

if the command type is unknown (shouldn't happen) +

SPI_ERROR_UNCONNECTED

if called from an unconnected procedure +

+

Notes

The functions SPI_execute, + SPI_exec, + SPI_execute_plan, and + SPI_execp change both + SPI_processed and + SPI_tuptable (just the pointer, not the contents + of the structure). Save these two global variables into local + procedure variables if you need to access the result table of + SPI_execute or a related function + across later calls. +


PrevHomeNext
SPI_popUpSPI_exec
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-finish.html b/doc/src/sgml/html/spi-spi-finish.html new file mode 100644 index 000000000..8b909336d --- /dev/null +++ b/doc/src/sgml/html/spi-spi-finish.html @@ -0,0 +1,247 @@ + +SPI_finish

SPI_finish

Name

SPI_finish -- disconnect a procedure from the SPI manager

Synopsis

int SPI_finish(void)

Description

SPI_finish closes an existing connection to + the SPI manager. You must call this function after completing the + SPI operations needed during your procedure's current invocation. + You do not need to worry about making this happen, however, if you + abort the transaction via elog(ERROR). In that + case SPI will clean itself up automatically. +

If SPI_finish is called without having a valid + connection, it will return SPI_ERROR_UNCONNECTED. + There is no fundamental problem with this; it means that the SPI + manager has nothing to do. +

Return Value

SPI_OK_FINISH

if properly disconnected +

SPI_ERROR_UNCONNECTED

if called from an unconnected procedure +


PrevHomeNext
SPI_connectUpSPI_push
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-fname.html b/doc/src/sgml/html/spi-spi-fname.html new file mode 100644 index 000000000..89ad9dc84 --- /dev/null +++ b/doc/src/sgml/html/spi-spi-fname.html @@ -0,0 +1,270 @@ + +SPI_fname

SPI_fname

Name

SPI_fname -- determine the column name for the specified column number

Synopsis

char * SPI_fname(TupleDesc rowdesc, int colnumber)

Description

SPI_fname returns a copy of the column name of the + specified column. (You can use pfree to + release the copy of the name when you don't need it anymore.) +

Arguments

TupleDesc rowdesc

input row description +

int colnumber

column number (count starts at 1) +

Return Value

The column name; NULL if + colnumber is out of range. + SPI_result set to + SPI_ERROR_NOATTRIBUTE on error. +


PrevHomeNext
Interface Support FunctionsUpSPI_fnumber
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-fnumber.html b/doc/src/sgml/html/spi-spi-fnumber.html new file mode 100644 index 000000000..08b8d128b --- /dev/null +++ b/doc/src/sgml/html/spi-spi-fnumber.html @@ -0,0 +1,273 @@ + +SPI_fnumber

SPI_fnumber

Name

SPI_fnumber -- determine the column number for the specified column name

Synopsis

int SPI_fnumber(TupleDesc rowdesc, const char * colname)

Description

SPI_fnumber returns the column number for the + column with the specified name. +

If colname refers to a system column (e.g., + oid) then the appropriate negative column number will + be returned. The caller should be careful to test the return value + for exact equality to SPI_ERROR_NOATTRIBUTE to + detect an error; testing the result for less than or equal to 0 is + not correct unless system columns should be rejected. +

Arguments

TupleDesc rowdesc

input row description +

const char * colname

column name +

Return Value

Column number (count starts at 1), or + SPI_ERROR_NOATTRIBUTE if the named column was not + found. +


PrevHomeNext
SPI_fnameUpSPI_getvalue
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-freeplan.html b/doc/src/sgml/html/spi-spi-freeplan.html new file mode 100644 index 000000000..3f26bcd7a --- /dev/null +++ b/doc/src/sgml/html/spi-spi-freeplan.html @@ -0,0 +1,256 @@ + +SPI_freeplan

SPI_freeplan

Name

SPI_freeplan -- free a previously saved prepared statement

Synopsis

int SPI_freeplan(SPIPlanPtr plan)

Description

SPI_freeplan releases a prepared statement + previously returned by SPI_prepare or saved by + SPI_keepplan or SPI_saveplan. +

Arguments

SPIPlanPtr plan

pointer to statement to free +

Return Value

0 on success; + SPI_ERROR_ARGUMENT if plan + is NULL or invalid +


PrevHomeNext
SPI_freetuptableUpVisibility of Data Changes
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-freetuple.html b/doc/src/sgml/html/spi-spi-freetuple.html new file mode 100644 index 000000000..0e0195d00 --- /dev/null +++ b/doc/src/sgml/html/spi-spi-freetuple.html @@ -0,0 +1,232 @@ + +SPI_freetuple

SPI_freetuple

Name

SPI_freetuple -- free a row allocated in the upper executor context

Synopsis

void SPI_freetuple(HeapTuple row)

Description

SPI_freetuple frees a row previously allocated + in the upper executor context. +

This function is no longer different from plain + heap_freetuple. It's kept just for backward + compatibility of existing code. +

Arguments

HeapTuple row

row to free +


PrevHomeNext
SPI_modifytupleUpSPI_freetuptable
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-freetupletable.html b/doc/src/sgml/html/spi-spi-freetupletable.html new file mode 100644 index 000000000..f5eaa52fc --- /dev/null +++ b/doc/src/sgml/html/spi-spi-freetupletable.html @@ -0,0 +1,246 @@ + +SPI_freetuptable

SPI_freetuptable

Name

SPI_freetuptable -- free a row set created by SPI_execute or a similar + function

Synopsis

void SPI_freetuptable(SPITupleTable * tuptable)

Description

SPI_freetuptable frees a row set created by a + prior SPI command execution function, such as + SPI_execute. Therefore, this function is usually called + with the global variable SPI_tupletable as + argument. +

This function is useful if a SPI procedure needs to execute + multiple commands and does not want to keep the results of earlier + commands around until it ends. Note that any unfreed row sets will + be freed anyway at SPI_finish. +

Arguments

SPITupleTable * tuptable

pointer to row set to free +


PrevHomeNext
SPI_freetupleUpSPI_freeplan
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-getargcount.html b/doc/src/sgml/html/spi-spi-getargcount.html new file mode 100644 index 000000000..db155369b --- /dev/null +++ b/doc/src/sgml/html/spi-spi-getargcount.html @@ -0,0 +1,263 @@ + +SPI_getargcount

SPI_getargcount

Name

SPI_getargcount -- return the number of arguments needed by a statement + prepared by SPI_prepare

Synopsis

int SPI_getargcount(SPIPlanPtr plan)

Description

SPI_getargcount returns the number of arguments needed + to execute a statement prepared by SPI_prepare. +

Arguments

SPIPlanPtr plan

prepared statement (returned by SPI_prepare) +

Return Value

The count of expected arguments for the plan. + If the plan is NULL or invalid, + SPI_result is set to SPI_ERROR_ARGUMENT + and -1 is returned. +


PrevHomeNext
SPI_prepare_paramsUpSPI_getargtypeid
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-getargtypeid.html b/doc/src/sgml/html/spi-spi-getargtypeid.html new file mode 100644 index 000000000..6e97e077c --- /dev/null +++ b/doc/src/sgml/html/spi-spi-getargtypeid.html @@ -0,0 +1,292 @@ + +SPI_getargtypeid

SPI_getargtypeid

Name

SPI_getargtypeid -- return the data type OID for an argument of + a statement prepared by SPI_prepare

Synopsis

Oid SPI_getargtypeid(SPIPlanPtr plan, int argIndex)

Description

SPI_getargtypeid returns the OID representing the type + for the argIndex'th argument of a statement prepared by + SPI_prepare. First argument is at index zero. +

Arguments

SPIPlanPtr plan

prepared statement (returned by SPI_prepare) +

int argIndex

zero based index of the argument +

Return Value

The type OID of the argument at the given index. + If the plan is NULL or invalid, + or argIndex is less than 0 or + not less than the number of arguments declared for the + plan, + SPI_result is set to SPI_ERROR_ARGUMENT + and InvalidOid is returned. +


PrevHomeNext
SPI_getargcountUpSPI_is_cursor_plan
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-getbinval.html b/doc/src/sgml/html/spi-spi-getbinval.html new file mode 100644 index 000000000..c05690217 --- /dev/null +++ b/doc/src/sgml/html/spi-spi-getbinval.html @@ -0,0 +1,307 @@ + +SPI_getbinval

SPI_getbinval

Name

SPI_getbinval -- return the binary value of the specified column

Synopsis

Datum SPI_getbinval(HeapTuple row, TupleDesc rowdesc, int colnumber,
+                    bool * isnull)

Description

SPI_getbinval returns the value of the + specified column in the internal form (as type Datum). +

This function does not allocate new space for the datum. In the + case of a pass-by-reference data type, the return value will be a + pointer into the passed row. +

Arguments

HeapTuple row

input row to be examined +

TupleDesc rowdesc

input row description +

int colnumber

column number (count starts at 1) +

bool * isnull

flag for a null value in the column +

Return Value

The binary value of the column is returned. The variable pointed + to by isnull is set to true if the column is + null, else to false. +

SPI_result is set to + SPI_ERROR_NOATTRIBUTE on error. +


PrevHomeNext
SPI_getvalueUpSPI_gettype
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-getnspname.html b/doc/src/sgml/html/spi-spi-getnspname.html new file mode 100644 index 000000000..9535a1892 --- /dev/null +++ b/doc/src/sgml/html/spi-spi-getnspname.html @@ -0,0 +1,244 @@ + +SPI_getnspname

SPI_getnspname

Name

SPI_getnspname -- return the namespace of the specified relation

Synopsis

char * SPI_getnspname(Relation rel)

Description

SPI_getnspname returns a copy of the name of + the namespace that the specified Relation + belongs to. This is equivalent to the relation's schema. You should + pfree the return value of this function when + you are finished with it. +

Arguments

Relation rel

input relation +

Return Value

The name of the specified relation's namespace. +


PrevHomeNext
SPI_getrelnameUpMemory Management
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-getrelname.html b/doc/src/sgml/html/spi-spi-getrelname.html new file mode 100644 index 000000000..d5ae88de8 --- /dev/null +++ b/doc/src/sgml/html/spi-spi-getrelname.html @@ -0,0 +1,239 @@ + +SPI_getrelname

SPI_getrelname

Name

SPI_getrelname -- return the name of the specified relation

Synopsis

char * SPI_getrelname(Relation rel)

Description

SPI_getrelname returns a copy of the name of the + specified relation. (You can use pfree to + release the copy of the name when you don't need it anymore.) +

Arguments

Relation rel

input relation +

Return Value

The name of the specified relation. +


PrevHomeNext
SPI_gettypeidUpSPI_getnspname
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-gettype.html b/doc/src/sgml/html/spi-spi-gettype.html new file mode 100644 index 000000000..28cad40f0 --- /dev/null +++ b/doc/src/sgml/html/spi-spi-gettype.html @@ -0,0 +1,266 @@ + +SPI_gettype

SPI_gettype

Name

SPI_gettype -- return the data type name of the specified column

Synopsis

char * SPI_gettype(TupleDesc rowdesc, int colnumber)

Description

SPI_gettype returns a copy of the data type name of the + specified column. (You can use pfree to + release the copy of the name when you don't need it anymore.) +

Arguments

TupleDesc rowdesc

input row description +

int colnumber

column number (count starts at 1) +

Return Value

The data type name of the specified column, or + NULL on error. SPI_result is + set to SPI_ERROR_NOATTRIBUTE on error. +


PrevHomeNext
SPI_getbinvalUpSPI_gettypeid
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-gettypeid.html b/doc/src/sgml/html/spi-spi-gettypeid.html new file mode 100644 index 000000000..dd3307acb --- /dev/null +++ b/doc/src/sgml/html/spi-spi-gettypeid.html @@ -0,0 +1,272 @@ + +SPI_gettypeid

SPI_gettypeid

Name

SPI_gettypeid -- return the data type OID of the specified column

Synopsis

Oid SPI_gettypeid(TupleDesc rowdesc, int colnumber)

Description

SPI_gettypeid returns the + OID of the data type of the specified column. +

Arguments

TupleDesc rowdesc

input row description +

int colnumber

column number (count starts at 1) +

Return Value

The OID of the data type of the specified column + or InvalidOid on error. On error, + SPI_result is set to + SPI_ERROR_NOATTRIBUTE. +


PrevHomeNext
SPI_gettypeUpSPI_getrelname
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-getvalue.html b/doc/src/sgml/html/spi-spi-getvalue.html new file mode 100644 index 000000000..9b29d7a34 --- /dev/null +++ b/doc/src/sgml/html/spi-spi-getvalue.html @@ -0,0 +1,302 @@ + +SPI_getvalue

SPI_getvalue

Name

SPI_getvalue -- return the string value of the specified column

Synopsis

char * SPI_getvalue(HeapTuple row, TupleDesc rowdesc, int colnumber)

Description

SPI_getvalue returns the string representation + of the value of the specified column. +

The result is returned in memory allocated using + palloc. (You can use + pfree to release the memory when you don't + need it anymore.) +

Arguments

HeapTuple row

input row to be examined +

TupleDesc rowdesc

input row description +

int colnumber

column number (count starts at 1) +

Return Value

Column value, or NULL if the column is null, + colnumber is out of range + (SPI_result is set to + SPI_ERROR_NOATTRIBUTE), or no output function is + available (SPI_result is set to + SPI_ERROR_NOOUTFUNC). +


PrevHomeNext
SPI_fnumberUpSPI_getbinval
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-is-cursor-plan.html b/doc/src/sgml/html/spi-spi-is-cursor-plan.html new file mode 100644 index 000000000..29bcf159b --- /dev/null +++ b/doc/src/sgml/html/spi-spi-is-cursor-plan.html @@ -0,0 +1,314 @@ + +SPI_is_cursor_plan

SPI_is_cursor_plan

Name

SPI_is_cursor_plan -- return true if a statement + prepared by SPI_prepare can be used with + SPI_cursor_open

Synopsis

bool SPI_is_cursor_plan(SPIPlanPtr plan)

Description

SPI_is_cursor_plan returns true + if a statement prepared by SPI_prepare can be passed + as an argument to SPI_cursor_open, or + false if that is not the case. The criteria are that the + plan represents one single command and that this + command returns tuples to the caller; for example, SELECT + is allowed unless it contains an INTO clause, and + UPDATE is allowed only if it contains a RETURNING + clause. +

Arguments

SPIPlanPtr plan

prepared statement (returned by SPI_prepare) +

Return Value

true or false to indicate if the + plan can produce a cursor or not, with + SPI_result set to zero. + If it is not possible to determine the answer (for example, + if the plan is NULL or invalid, + or if called when not connected to SPI), then + SPI_result is set to a suitable error code + and false is returned. +


PrevHomeNext
SPI_getargtypeidUpSPI_execute_plan
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-keepplan.html b/doc/src/sgml/html/spi-spi-keepplan.html new file mode 100644 index 000000000..bc95e156d --- /dev/null +++ b/doc/src/sgml/html/spi-spi-keepplan.html @@ -0,0 +1,271 @@ + +SPI_keepplan

SPI_keepplan

Name

SPI_keepplan -- save a prepared statement

Synopsis

int SPI_keepplan(SPIPlanPtr plan)

Description

SPI_keepplan saves a passed statement (prepared by + SPI_prepare) so that it will not be freed + by SPI_finish nor by the transaction manager. + This gives you the ability to reuse prepared statements in the subsequent + invocations of your procedure in the current session. +

Arguments

SPIPlanPtr plan

the prepared statement to be saved +

Return Value

0 on success; + SPI_ERROR_ARGUMENT if plan + is NULL or invalid +

Notes

The passed-in statement is relocated to permanent storage by means + of pointer adjustment (no data copying is required). If you later + wish to delete it, use SPI_freeplan on it. +


PrevHomeNext
SPI_cursor_closeUpSPI_saveplan
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-modifytuple.html b/doc/src/sgml/html/spi-spi-modifytuple.html new file mode 100644 index 000000000..17c84346e --- /dev/null +++ b/doc/src/sgml/html/spi-spi-modifytuple.html @@ -0,0 +1,411 @@ + +SPI_modifytuple

SPI_modifytuple

Name

SPI_modifytuple -- create a row by replacing selected fields of a given row

Synopsis

HeapTuple SPI_modifytuple(Relation rel, HeapTuple row, int ncols,
+                          int * colnum, Datum * values, const char * nulls)

Description

SPI_modifytuple creates a new row by + substituting new values for selected columns, copying the original + row's columns at other positions. The input row is not modified. +

Arguments

Relation rel

Used only as the source of the row descriptor for the row. + (Passing a relation rather than a row descriptor is a + misfeature.) +

HeapTuple row

row to be modified +

int ncols

number of column numbers in the array + colnum +

int * colnum

array of the numbers of the columns that are to be changed + (column numbers start at 1) +

Datum * values

new values for the specified columns +

const char * Nulls

which new values are null, if any (see + SPI_execute_plan for the format) +

Return Value

new row with modifications, allocated in the upper executor + context; NULL only if row + is NULL +

On error, SPI_result is set as follows: +

SPI_ERROR_ARGUMENT

if rel is NULL, or if + row is NULL, or if ncols + is less than or equal to 0, or if colnum is + NULL, or if values is NULL. +

SPI_ERROR_NOATTRIBUTE

if colnum contains an invalid column number (less + than or equal to 0 or greater than the number of column in + row) +

+


PrevHomeNext
SPI_returntupleUpSPI_freetuple
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-palloc.html b/doc/src/sgml/html/spi-spi-palloc.html new file mode 100644 index 000000000..3491980e1 --- /dev/null +++ b/doc/src/sgml/html/spi-spi-palloc.html @@ -0,0 +1,235 @@ + +SPI_palloc

SPI_palloc

Name

SPI_palloc -- allocate memory in the upper executor context

Synopsis

void * SPI_palloc(Size size)

Description

SPI_palloc allocates memory in the upper + executor context. +

Arguments

Size size

size in bytes of storage to allocate +

Return Value

pointer to new storage space of the specified size +


PrevHomeNext
Memory ManagementUpSPI_repalloc
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-pfree.html b/doc/src/sgml/html/spi-spi-pfree.html new file mode 100644 index 000000000..ae9e75c3e --- /dev/null +++ b/doc/src/sgml/html/spi-spi-pfree.html @@ -0,0 +1,239 @@ + +SPI_pfree

SPI_pfree

Name

SPI_pfree -- free memory in the upper executor context

Synopsis

void SPI_pfree(void * pointer)

Description

SPI_pfree frees memory previously allocated + using SPI_palloc or + SPI_repalloc. +

This function is no longer different from plain + pfree. It's kept just for backward + compatibility of existing code. +

Arguments

void * pointer

pointer to existing storage to free +


PrevHomeNext
SPI_repallocUpSPI_copytuple
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-pop.html b/doc/src/sgml/html/spi-spi-pop.html new file mode 100644 index 000000000..2f08ab20c --- /dev/null +++ b/doc/src/sgml/html/spi-spi-pop.html @@ -0,0 +1,196 @@ + +SPI_pop

SPI_pop

Name

SPI_pop -- pop SPI stack to return from recursive SPI usage

Synopsis

void SPI_pop(void)

Description

SPI_pop pops the previous environment from the + SPI call stack. See SPI_push. +


PrevHomeNext
SPI_pushUpSPI_execute
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-prepare-cursor.html b/doc/src/sgml/html/spi-spi-prepare-cursor.html new file mode 100644 index 000000000..8f74ae82d --- /dev/null +++ b/doc/src/sgml/html/spi-spi-prepare-cursor.html @@ -0,0 +1,361 @@ + +SPI_prepare_cursor

SPI_prepare_cursor

Name

SPI_prepare_cursor -- prepare a statement, without executing it yet

Synopsis

SPIPlanPtr SPI_prepare_cursor(const char * command, int nargs,
+                              Oid * argtypes, int cursorOptions)

Description

SPI_prepare_cursor is identical to + SPI_prepare, except that it also allows specification + of the planner's "cursor options" parameter. This is a bit mask + having the values shown in nodes/parsenodes.h + for the options field of DeclareCursorStmt. + SPI_prepare always takes the cursor options as zero. +

Arguments

const char * command

command string +

int nargs

number of input parameters ($1, $2, etc.) +

Oid * argtypes

pointer to an array containing the OIDs of + the data types of the parameters +

int cursorOptions

integer bit mask of cursor options; zero produces default behavior +

Return Value

SPI_prepare_cursor has the same return conventions as + SPI_prepare. +

Notes

Useful bits to set in cursorOptions include + CURSOR_OPT_SCROLL, + CURSOR_OPT_NO_SCROLL, + CURSOR_OPT_FAST_PLAN, + CURSOR_OPT_GENERIC_PLAN, and + CURSOR_OPT_CUSTOM_PLAN. Note in particular that + CURSOR_OPT_HOLD is ignored. +


PrevHomeNext
SPI_prepareUpSPI_prepare_params
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-prepare-params.html b/doc/src/sgml/html/spi-spi-prepare-params.html new file mode 100644 index 000000000..c03b46b72 --- /dev/null +++ b/doc/src/sgml/html/spi-spi-prepare-params.html @@ -0,0 +1,302 @@ + +SPI_prepare_params

SPI_prepare_params

Name

SPI_prepare_params -- prepare a statement, without executing it yet

Synopsis

SPIPlanPtr SPI_prepare_params(const char * command,
+                              ParserSetupHook parserSetup,
+                              void * parserSetupArg,
+                              int cursorOptions)

Description

SPI_prepare_params creates and returns a prepared + statement for the specified command, but doesn't execute the command. + This function is equivalent to SPI_prepare_cursor, + with the addition that the caller can specify parser hook functions + to control the parsing of external parameter references. +

Arguments

const char * command

command string +

ParserSetupHook parserSetup

Parser hook setup function +

void * parserSetupArg

passthrough argument for parserSetup +

int cursorOptions

integer bit mask of cursor options; zero produces default behavior +

Return Value

SPI_prepare_params has the same return conventions as + SPI_prepare. +


PrevHomeNext
SPI_prepare_cursorUpSPI_getargcount
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-prepare.html b/doc/src/sgml/html/spi-spi-prepare.html new file mode 100644 index 000000000..eea4e5aaa --- /dev/null +++ b/doc/src/sgml/html/spi-spi-prepare.html @@ -0,0 +1,442 @@ + +SPI_prepare

SPI_prepare

Name

SPI_prepare -- prepare a statement, without executing it yet

Synopsis

SPIPlanPtr SPI_prepare(const char * command, int nargs, Oid * argtypes)

Description

SPI_prepare creates and returns a prepared + statement for the specified command, but doesn't execute the command. + The prepared statement can later be executed repeatedly using + SPI_execute_plan. +

When the same or a similar command is to be executed repeatedly, it + is generally advantageous to perform parse analysis only once, and + might furthermore be advantageous to re-use an execution plan for the + command. + SPI_prepare converts a command string into a + prepared statement that encapsulates the results of parse analysis. + The prepared statement also provides a place for caching an execution plan + if it is found that generating a custom plan for each execution is not + helpful. +

A prepared command can be generalized by writing parameters + ($1, $2, etc.) in place of what would be + constants in a normal command. The actual values of the parameters + are then specified when SPI_execute_plan is called. + This allows the prepared command to be used over a wider range of + situations than would be possible without parameters. +

The statement returned by SPI_prepare can be used + only in the current invocation of the procedure, since + SPI_finish frees memory allocated for such a + statement. But the statement can be saved for longer using the functions + SPI_keepplan or SPI_saveplan. +

Arguments

const char * command

command string +

int nargs

number of input parameters ($1, $2, etc.) +

Oid * argtypes

pointer to an array containing the OIDs of + the data types of the parameters +

Return Value

SPI_prepare returns a non-null pointer to an + SPIPlan, which is an opaque struct representing a prepared + statement. On error, NULL will be returned, + and SPI_result will be set to one of the same + error codes used by SPI_execute, except that + it is set to SPI_ERROR_ARGUMENT if + command is NULL, or if + nargs is less than 0, or if nargs is + greater than 0 and argtypes is NULL. +

Notes

If no parameters are defined, a generic plan will be created at the + first use of SPI_execute_plan, and used for all + subsequent executions as well. If there are parameters, the first few uses + of SPI_execute_plan will generate custom plans + that are specific to the supplied parameter values. After enough uses + of the same prepared statement, SPI_execute_plan will + build a generic plan, and if that is not too much more expensive than the + custom plans, it will start using the generic plan instead of re-planning + each time. If this default behavior is unsuitable, you can alter it by + passing the CURSOR_OPT_GENERIC_PLAN or + CURSOR_OPT_CUSTOM_PLAN flag to + SPI_prepare_cursor, to force use of generic or custom + plans respectively. +

This function should only be called from a connected procedure. +

SPIPlanPtr is declared as a pointer to an opaque struct type in + spi.h. It is unwise to try to access its contents + directly, as that makes your code much more likely to break in + future revisions of PostgreSQL. +

The name SPIPlanPtr is somewhat historical, since the data + structure no longer necessarily contains an execution plan. +


PrevHomeNext
SPI_execute_with_argsUpSPI_prepare_cursor
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-push.html b/doc/src/sgml/html/spi-spi-push.html new file mode 100644 index 000000000..83cd1fb20 --- /dev/null +++ b/doc/src/sgml/html/spi-spi-push.html @@ -0,0 +1,235 @@ + +SPI_push

SPI_push

Name

SPI_push -- push SPI stack to allow recursive SPI usage

Synopsis

void SPI_push(void)

Description

SPI_push should be called before executing another + procedure that might itself wish to use SPI. + After SPI_push, SPI is no longer in a + "connected" state, and SPI function calls will be rejected unless + a fresh SPI_connect is done. This ensures a clean + separation between your procedure's SPI state and that of another procedure + you call. After the other procedure returns, call + SPI_pop to restore access to your own SPI state. +

Note that SPI_execute and related functions + automatically do the equivalent of SPI_push before + passing control back to the SQL execution engine, so it is not necessary + for you to worry about this when using those functions. + Only when you are directly calling arbitrary code that might contain + SPI_connect calls do you need to issue + SPI_push and SPI_pop. +


PrevHomeNext
SPI_finishUpSPI_pop
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-returntuple.html b/doc/src/sgml/html/spi-spi-returntuple.html new file mode 100644 index 000000000..d87382d6b --- /dev/null +++ b/doc/src/sgml/html/spi-spi-returntuple.html @@ -0,0 +1,289 @@ + +SPI_returntuple

SPI_returntuple

Name

SPI_returntuple -- prepare to return a tuple as a Datum

Synopsis

HeapTupleHeader SPI_returntuple(HeapTuple row, TupleDesc rowdesc)

Description

SPI_returntuple makes a copy of a row in + the upper executor context, returning it in the form of a row type Datum. + The returned pointer need only be converted to Datum via PointerGetDatum + before returning. +

Note that this should be used for functions that are declared to return + composite types. It is not used for triggers; use + SPI_copytuple for returning a modified row in a trigger. +

Arguments

HeapTuple row

row to be copied +

TupleDesc rowdesc

descriptor for row (pass the same descriptor each time for most + effective caching) +

Return Value

HeapTupleHeader pointing to copied row; + NULL only if + row or rowdesc is + NULL +


PrevHomeNext
SPI_copytupleUpSPI_modifytuple
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-saveplan.html b/doc/src/sgml/html/spi-spi-saveplan.html new file mode 100644 index 000000000..9ec99b1d7 --- /dev/null +++ b/doc/src/sgml/html/spi-spi-saveplan.html @@ -0,0 +1,314 @@ + +SPI_saveplan

SPI_saveplan

Name

SPI_saveplan -- save a prepared statement

Synopsis

SPIPlanPtr SPI_saveplan(SPIPlanPtr plan)

Description

SPI_saveplan copies a passed statement (prepared by + SPI_prepare) into memory that will not be freed + by SPI_finish nor by the transaction manager, + and returns a pointer to the copied statement. This gives you the + ability to reuse prepared statements in the subsequent invocations of + your procedure in the current session. +

Arguments

SPIPlanPtr plan

the prepared statement to be saved +

Return Value

Pointer to the copied statement; or NULL if unsuccessful. + On error, SPI_result is set thus: + +

SPI_ERROR_ARGUMENT

if plan is NULL or invalid +

SPI_ERROR_UNCONNECTED

if called from an unconnected procedure +

+

Notes

The originally passed-in statement is not freed, so you might wish to do + SPI_freeplan on it to avoid leaking memory + until SPI_finish. +

In most cases, SPI_keepplan is preferred to this + function, since it accomplishes largely the same result without needing + to physically copy the prepared statement's data structures. +


PrevHomeNext
SPI_keepplanUpInterface Support Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-scroll-cursor-fetch.html b/doc/src/sgml/html/spi-spi-scroll-cursor-fetch.html new file mode 100644 index 000000000..30e714c9f --- /dev/null +++ b/doc/src/sgml/html/spi-spi-scroll-cursor-fetch.html @@ -0,0 +1,347 @@ + +SPI_scroll_cursor_fetch

SPI_scroll_cursor_fetch

Name

SPI_scroll_cursor_fetch -- fetch some rows from a cursor

Synopsis

void SPI_scroll_cursor_fetch(Portal portal, FetchDirection direction,
+                             long count)

Description

SPI_scroll_cursor_fetch fetches some rows from a + cursor. This is equivalent to the SQL command FETCH. +

Arguments

Portal portal

portal containing the cursor +

FetchDirection direction

one of FETCH_FORWARD, + FETCH_BACKWARD, + FETCH_ABSOLUTE or + FETCH_RELATIVE +

long count

number of rows to fetch for + FETCH_FORWARD or + FETCH_BACKWARD; absolute row number to fetch for + FETCH_ABSOLUTE; or relative row number to fetch for + FETCH_RELATIVE +

Return Value

SPI_processed and + SPI_tuptable are set as in + SPI_execute if successful. +

Notes

See the SQL FETCH command + for details of the interpretation of the + direction and + count parameters. +

Direction values other than FETCH_FORWARD + may fail if the cursor's plan was not created + with the CURSOR_OPT_SCROLL option. +


PrevHomeNext
SPI_cursor_moveUpSPI_scroll_cursor_move
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-spi-scroll-cursor-move.html b/doc/src/sgml/html/spi-spi-scroll-cursor-move.html new file mode 100644 index 000000000..d7e0cd2d0 --- /dev/null +++ b/doc/src/sgml/html/spi-spi-scroll-cursor-move.html @@ -0,0 +1,352 @@ + +SPI_scroll_cursor_move

SPI_scroll_cursor_move

Name

SPI_scroll_cursor_move -- move a cursor

Synopsis

void SPI_scroll_cursor_move(Portal portal, FetchDirection direction,
+                            long count)

Description

SPI_scroll_cursor_move skips over some number of rows + in a cursor. This is equivalent to the SQL command + MOVE. +

Arguments

Portal portal

portal containing the cursor +

FetchDirection direction

one of FETCH_FORWARD, + FETCH_BACKWARD, + FETCH_ABSOLUTE or + FETCH_RELATIVE +

long count

number of rows to move for + FETCH_FORWARD or + FETCH_BACKWARD; absolute row number to move to for + FETCH_ABSOLUTE; or relative row number to move to for + FETCH_RELATIVE +

Return Value

SPI_processed is set as in + SPI_execute if successful. + SPI_tuptable is set to NULL, since + no rows are returned by this function. +

Notes

See the SQL FETCH command + for details of the interpretation of the + direction and + count parameters. +

Direction values other than FETCH_FORWARD + may fail if the cursor's plan was not created + with the CURSOR_OPT_SCROLL option. +


PrevHomeNext
SPI_scroll_cursor_fetchUpSPI_cursor_close
\ No newline at end of file diff --git a/doc/src/sgml/html/spi-visibility.html b/doc/src/sgml/html/spi-visibility.html new file mode 100644 index 000000000..366299040 --- /dev/null +++ b/doc/src/sgml/html/spi-visibility.html @@ -0,0 +1,230 @@ + +Visibility of Data Changes
PostgreSQL 9.2.2 Documentation
PrevUpChapter 43. Server Programming InterfaceNext

43.4. Visibility of Data Changes

The following rules govern the visibility of data changes in + functions that use SPI (or any other C function): + +

  • During the execution of an SQL command, any data changes made by + the command are invisible to the command itself. For + example, in: +

    INSERT INTO a SELECT * FROM a;

    + the inserted rows are invisible to the SELECT + part. +

  • Changes made by a command C are visible to all commands that are + started after C, no matter whether they are started inside C + (during the execution of C) or after C is done. +

  • Commands executed via SPI inside a function called by an SQL command + (either an ordinary function or a trigger) follow one or the + other of the above rules depending on the read/write flag passed + to SPI. Commands executed in read-only mode follow the first + rule: they cannot see changes of the calling command. Commands executed + in read-write mode follow the second rule: they can see all changes made + so far. +

  • All standard procedural languages set the SPI read-write mode + depending on the volatility attribute of the function. Commands of + STABLE and IMMUTABLE functions are done in + read-only mode, while commands of VOLATILE functions are + done in read-write mode. While authors of C functions are able to + violate this convention, it's unlikely to be a good idea to do so. +

+

The next section contains an example that illustrates the + application of these rules. +


PrevHomeNext
SPI_freeplanUpExamples
\ No newline at end of file diff --git a/doc/src/sgml/html/spi.html b/doc/src/sgml/html/spi.html new file mode 100644 index 000000000..fe4e3e6cc --- /dev/null +++ b/doc/src/sgml/html/spi.html @@ -0,0 +1,556 @@ + +Server Programming Interface

Chapter 43. Server Programming Interface

Table of Contents
43.1. Interface Functions
SPI_connect -- connect a procedure to the SPI manager
SPI_finish -- disconnect a procedure from the SPI manager
SPI_push -- push SPI stack to allow recursive SPI usage
SPI_pop -- pop SPI stack to return from recursive SPI usage
SPI_execute -- execute a command
SPI_exec -- execute a read/write command
SPI_execute_with_args -- execute a command with out-of-line parameters
SPI_prepare -- prepare a statement, without executing it yet
SPI_prepare_cursor -- prepare a statement, without executing it yet
SPI_prepare_params -- prepare a statement, without executing it yet
SPI_getargcount -- return the number of arguments needed by a statement + prepared by SPI_prepare
SPI_getargtypeid -- return the data type OID for an argument of + a statement prepared by SPI_prepare
SPI_is_cursor_plan -- return true if a statement + prepared by SPI_prepare can be used with + SPI_cursor_open
SPI_execute_plan -- execute a statement prepared by SPI_prepare
SPI_execute_plan_with_paramlist -- execute a statement prepared by SPI_prepare
SPI_execp -- execute a statement in read/write mode
SPI_cursor_open -- set up a cursor using a statement created with SPI_prepare
SPI_cursor_open_with_args -- set up a cursor using a query and parameters
SPI_cursor_open_with_paramlist -- set up a cursor using parameters
SPI_cursor_find -- find an existing cursor by name
SPI_cursor_fetch -- fetch some rows from a cursor
SPI_cursor_move -- move a cursor
SPI_scroll_cursor_fetch -- fetch some rows from a cursor
SPI_scroll_cursor_move -- move a cursor
SPI_cursor_close -- close a cursor
SPI_keepplan -- save a prepared statement
SPI_saveplan -- save a prepared statement
43.2. Interface Support Functions
SPI_fname -- determine the column name for the specified column number
SPI_fnumber -- determine the column number for the specified column name
SPI_getvalue -- return the string value of the specified column
SPI_getbinval -- return the binary value of the specified column
SPI_gettype -- return the data type name of the specified column
SPI_gettypeid -- return the data type OID of the specified column
SPI_getrelname -- return the name of the specified relation
SPI_getnspname -- return the namespace of the specified relation
43.3. Memory Management
SPI_palloc -- allocate memory in the upper executor context
SPI_repalloc -- reallocate memory in the upper executor context
SPI_pfree -- free memory in the upper executor context
SPI_copytuple -- make a copy of a row in the upper executor context
SPI_returntuple -- prepare to return a tuple as a Datum
SPI_modifytuple -- create a row by replacing selected fields of a given row
SPI_freetuple -- free a row allocated in the upper executor context
SPI_freetuptable -- free a row set created by SPI_execute or a similar + function
SPI_freeplan -- free a previously saved prepared statement
43.4. Visibility of Data Changes
43.5. Examples

The Server Programming Interface + (SPI) gives writers of user-defined + C functions the ability to run + SQL commands inside their functions. + SPI is a set of + interface functions to simplify access to the parser, planner, + and executor. SPI also does some + memory management. +

Note: The available procedural languages provide various means to + execute SQL commands from procedures. Most of these facilities are + based on SPI, so this documentation might be of use for users + of those languages as well. +

To avoid misunderstanding we'll use the term "function" + when we speak of SPI interface functions and + "procedure" for a user-defined C-function that is + using SPI. +

Note that if a command invoked via SPI fails, then control will not be + returned to your procedure. Rather, the + transaction or subtransaction in which your procedure executes will be + rolled back. (This might seem surprising given that the SPI functions mostly + have documented error-return conventions. Those conventions only apply + for errors detected within the SPI functions themselves, however.) + It is possible to recover control after an error by establishing your own + subtransaction surrounding SPI calls that might fail. This is not currently + documented because the mechanisms required are still in flux. +

SPI functions return a nonnegative result on + success (either via a returned integer value or in the global + variable SPI_result, as described below). On + error, a negative result or NULL will be returned. +

Source code files that use SPI must include the header file + executor/spi.h. +


PrevHomeNext
Environment VariablesUpInterface Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-abort.html b/doc/src/sgml/html/sql-abort.html new file mode 100644 index 000000000..a0f0cf4da --- /dev/null +++ b/doc/src/sgml/html/sql-abort.html @@ -0,0 +1,303 @@ + +ABORT

ABORT

Name

ABORT -- abort the current transaction

Synopsis

ABORT [ WORK | TRANSACTION ]

Description

ABORT rolls back the current transaction and causes + all the updates made by the transaction to be discarded. + This command is identical + in behavior to the standard SQL command + ROLLBACK, + and is present only for historical reasons. +

Parameters

WORK
TRANSACTION

Optional key words. They have no effect. +

Notes

Use COMMIT to + successfully terminate a transaction. +

Issuing ABORT when not inside a transaction does + no harm, but it will provoke a warning message. +

Examples

To abort all changes: +

ABORT;

Compatibility

This command is a PostgreSQL extension + present for historical reasons. ROLLBACK is the + equivalent standard SQL command. +


PrevHomeNext
SQL CommandsUpALTER AGGREGATE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-alteraggregate.html b/doc/src/sgml/html/sql-alteraggregate.html new file mode 100644 index 000000000..be6e90855 --- /dev/null +++ b/doc/src/sgml/html/sql-alteraggregate.html @@ -0,0 +1,427 @@ + +ALTER AGGREGATE

ALTER AGGREGATE

Name

ALTER AGGREGATE -- change the definition of an aggregate function

Synopsis

ALTER AGGREGATE name ( argtype [ , ... ] ) RENAME TO new_name
+ALTER AGGREGATE name ( argtype [ , ... ] ) OWNER TO new_owner
+ALTER AGGREGATE name ( argtype [ , ... ] ) SET SCHEMA new_schema

Description

ALTER AGGREGATE changes the definition of an + aggregate function. +

You must own the aggregate function to use ALTER AGGREGATE. + To change the schema of an aggregate function, you must also have + CREATE privilege on the new schema. + To alter the owner, you must also be a direct or indirect member of the new + owning role, and that role must have CREATE privilege on + the aggregate function's schema. (These restrictions enforce that altering + the owner doesn't do anything you couldn't do by dropping and recreating + the aggregate function. However, a superuser can alter ownership of any + aggregate function anyway.) +

Parameters

name

The name (optionally schema-qualified) of an existing aggregate function. +

argtype

An input data type on which the aggregate function operates. + To reference a zero-argument aggregate function, write * + in place of the list of input data types. +

new_name

The new name of the aggregate function. +

new_owner

The new owner of the aggregate function. +

new_schema

The new schema for the aggregate function. +

Examples

To rename the aggregate function myavg for type + integer to my_average: +

ALTER AGGREGATE myavg(integer) RENAME TO my_average;

+

To change the owner of the aggregate function myavg for type + integer to joe: +

ALTER AGGREGATE myavg(integer) OWNER TO joe;

+

To move the aggregate function myavg for type + integer into schema myschema: +

ALTER AGGREGATE myavg(integer) SET SCHEMA myschema;

Compatibility

There is no ALTER AGGREGATE statement in the SQL + standard. +


PrevHomeNext
ABORTUpALTER COLLATION
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-altercollation.html b/doc/src/sgml/html/sql-altercollation.html new file mode 100644 index 000000000..f6b05e637 --- /dev/null +++ b/doc/src/sgml/html/sql-altercollation.html @@ -0,0 +1,367 @@ + +ALTER COLLATION

ALTER COLLATION

Name

ALTER COLLATION -- change the definition of a collation

Synopsis

ALTER COLLATION name RENAME TO new_name
+ALTER COLLATION name OWNER TO new_owner
+ALTER COLLATION name SET SCHEMA new_schema

Description

ALTER COLLATION changes the definition of a + collation. +

You must own the collation to use ALTER COLLATION. + To alter the owner, you must also be a direct or indirect member of the new + owning role, and that role must have CREATE privilege on + the collation's schema. (These restrictions enforce that altering the + owner doesn't do anything you couldn't do by dropping and recreating the + collation. However, a superuser can alter ownership of any collation + anyway.) +

Parameters

name

The name (optionally schema-qualified) of an existing collation. +

new_name

The new name of the collation. +

new_owner

The new owner of the collation. +

new_schema

The new schema for the collation. +

Examples

To rename the collation de_DE to + german: +

ALTER COLLATION "de_DE" RENAME TO german;

+

To change the owner of the collation en_US to + joe: +

ALTER COLLATION "en_US" OWNER TO joe;

Compatibility

There is no ALTER COLLATION statement in the SQL + standard. +


PrevHomeNext
ALTER AGGREGATEUpALTER CONVERSION
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-alterconversion.html b/doc/src/sgml/html/sql-alterconversion.html new file mode 100644 index 000000000..d384eb7bc --- /dev/null +++ b/doc/src/sgml/html/sql-alterconversion.html @@ -0,0 +1,367 @@ + +ALTER CONVERSION

ALTER CONVERSION

Name

ALTER CONVERSION -- change the definition of a conversion

Synopsis

ALTER CONVERSION name RENAME TO new_name
+ALTER CONVERSION name OWNER TO new_owner
+ALTER CONVERSION name SET SCHEMA new_schema

Description

ALTER CONVERSION changes the definition of a + conversion. +

You must own the conversion to use ALTER CONVERSION. + To alter the owner, you must also be a direct or indirect member of the new + owning role, and that role must have CREATE privilege on + the conversion's schema. (These restrictions enforce that altering the + owner doesn't do anything you couldn't do by dropping and recreating the + conversion. However, a superuser can alter ownership of any conversion + anyway.) +

Parameters

name

The name (optionally schema-qualified) of an existing conversion. +

new_name

The new name of the conversion. +

new_owner

The new owner of the conversion. +

new_schema

The new schema for the conversion. +

Examples

To rename the conversion iso_8859_1_to_utf8 to + latin1_to_unicode: +

ALTER CONVERSION iso_8859_1_to_utf8 RENAME TO latin1_to_unicode;

+

To change the owner of the conversion iso_8859_1_to_utf8 to + joe: +

ALTER CONVERSION iso_8859_1_to_utf8 OWNER TO joe;

Compatibility

There is no ALTER CONVERSION statement in the SQL + standard. +


PrevHomeNext
ALTER COLLATIONUpALTER DATABASE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-alterdatabase.html b/doc/src/sgml/html/sql-alterdatabase.html new file mode 100644 index 000000000..b3fb8fba6 --- /dev/null +++ b/doc/src/sgml/html/sql-alterdatabase.html @@ -0,0 +1,562 @@ + +ALTER DATABASE

ALTER DATABASE

Name

ALTER DATABASE -- change a database

Synopsis

ALTER DATABASE name [ [ WITH ] option [ ... ] ]
+
+where option can be:
+
+    CONNECTION LIMIT connlimit
+
+ALTER DATABASE name RENAME TO new_name
+
+ALTER DATABASE name OWNER TO new_owner
+
+ALTER DATABASE name SET TABLESPACE new_tablespace
+
+ALTER DATABASE name SET configuration_parameter { TO | = } { value | DEFAULT }
+ALTER DATABASE name SET configuration_parameter FROM CURRENT
+ALTER DATABASE name RESET configuration_parameter
+ALTER DATABASE name RESET ALL

Description

ALTER DATABASE changes the attributes + of a database. +

The first form changes certain per-database settings. (See below for + details.) Only the database owner or a superuser can change these settings. +

The second form changes the name of the database. Only the database + owner or a superuser can rename a database; non-superuser owners must + also have the + CREATEDB privilege. The current database cannot + be renamed. (Connect to a different database if you need to do + that.) +

The third form changes the owner of the database. + To alter the owner, you must own the database and also be a direct or + indirect member of the new owning role, and you must have the + CREATEDB privilege. + (Note that superusers have all these privileges automatically.) +

The fourth form changes the default tablespace of the database. + Only the database owner or a superuser can do this; you must also have + create privilege for the new tablespace. + This command physically moves any tables or indexes in the database's old + default tablespace to the new tablespace. Note that tables and indexes + in non-default tablespaces are not affected. +

The remaining forms change the session default for a run-time + configuration variable for a PostgreSQL + database. Whenever a new session is subsequently started in that + database, the specified value becomes the session default value. + The database-specific default overrides whatever setting is present + in postgresql.conf or has been received from the + postgres command line. Only the database + owner or a superuser can change the session defaults for a + database. Certain variables cannot be set this way, or can only be + set by a superuser. +

Parameters

name

The name of the database whose attributes are to be altered. +

connlimit

How many concurrent connections can be made + to this database. -1 means no limit. +

new_name

The new name of the database. +

new_owner

The new owner of the database. +

new_tablespace

The new default tablespace of the database. +

configuration_parameter
value

Set this database's session default for the specified configuration + parameter to the given value. If + value is DEFAULT + or, equivalently, RESET is used, the + database-specific setting is removed, so the system-wide default + setting will be inherited in new sessions. Use RESET + ALL to clear all database-specific settings. + SET FROM CURRENT saves the session's current value of + the parameter as the database-specific value. +

See SET and Chapter 18 + for more information about allowed parameter names + and values. +

Notes

It is also possible to tie a session default to a specific role + rather than to a database; see + ALTER ROLE. + Role-specific settings override database-specific + ones if there is a conflict. +

Examples

To disable index scans by default in the database + test: + +

ALTER DATABASE test SET enable_indexscan TO off;

Compatibility

The ALTER DATABASE statement is a + PostgreSQL extension. +


PrevHomeNext
ALTER CONVERSIONUpALTER DEFAULT PRIVILEGES
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-alterdefaultprivileges.html b/doc/src/sgml/html/sql-alterdefaultprivileges.html new file mode 100644 index 000000000..4ed101af4 --- /dev/null +++ b/doc/src/sgml/html/sql-alterdefaultprivileges.html @@ -0,0 +1,537 @@ + +ALTER DEFAULT PRIVILEGES

ALTER DEFAULT PRIVILEGES

Name

ALTER DEFAULT PRIVILEGES -- define default access privileges

Synopsis

ALTER DEFAULT PRIVILEGES
+    [ FOR { ROLE | USER } target_role [, ...] ]
+    [ IN SCHEMA schema_name [, ...] ]
+    abbreviated_grant_or_revoke
+
+where abbreviated_grant_or_revoke is one of:
+
+GRANT { { SELECT | INSERT | UPDATE | DELETE | TRUNCATE | REFERENCES | TRIGGER }
+    [, ...] | ALL [ PRIVILEGES ] }
+    ON TABLES
+    TO { [ GROUP ] role_name | PUBLIC } [, ...] [ WITH GRANT OPTION ]
+
+GRANT { { USAGE | SELECT | UPDATE }
+    [, ...] | ALL [ PRIVILEGES ] }
+    ON SEQUENCES
+    TO { [ GROUP ] role_name | PUBLIC } [, ...] [ WITH GRANT OPTION ]
+
+GRANT { EXECUTE | ALL [ PRIVILEGES ] }
+    ON FUNCTIONS
+    TO { [ GROUP ] role_name | PUBLIC } [, ...] [ WITH GRANT OPTION ]
+
+GRANT { USAGE | ALL [ PRIVILEGES ] }
+    ON TYPES
+    TO { [ GROUP ] role_name | PUBLIC } [, ...] [ WITH GRANT OPTION ]
+
+REVOKE [ GRANT OPTION FOR ]
+    { { SELECT | INSERT | UPDATE | DELETE | TRUNCATE | REFERENCES | TRIGGER }
+    [, ...] | ALL [ PRIVILEGES ] }
+    ON TABLES
+    FROM { [ GROUP ] role_name | PUBLIC } [, ...]
+    [ CASCADE | RESTRICT ]
+
+REVOKE [ GRANT OPTION FOR ]
+    { { USAGE | SELECT | UPDATE }
+    [, ...] | ALL [ PRIVILEGES ] }
+    ON SEQUENCES
+    FROM { [ GROUP ] role_name | PUBLIC } [, ...]
+    [ CASCADE | RESTRICT ]
+
+REVOKE [ GRANT OPTION FOR ]
+    { EXECUTE | ALL [ PRIVILEGES ] }
+    ON FUNCTIONS
+    FROM { [ GROUP ] role_name | PUBLIC } [, ...]
+    [ CASCADE | RESTRICT ]
+
+REVOKE [ GRANT OPTION FOR ]
+    { USAGE | ALL [ PRIVILEGES ] }
+    ON TYPES
+    FROM { [ GROUP ] role_name | PUBLIC } [, ...]
+    [ CASCADE | RESTRICT ]

Description

ALTER DEFAULT PRIVILEGES allows you to set the privileges + that will be applied to objects created in the future. (It does not + affect privileges assigned to already-existing objects.) Currently, + only the privileges for tables (including views and foreign tables), + sequences, functions, and types (including domains) can be altered. +

You can change default privileges only for objects that will be created by + yourself or by roles that you are a member of. The privileges can be set + globally (i.e., for all objects created in the current database), + or just for objects created in specified schemas. Default privileges + that are specified per-schema are added to whatever the global default + privileges are for the particular object type. +

As explained under GRANT, + the default privileges for any object type normally grant all grantable + permissions to the object owner, and may grant some privileges to + PUBLIC as well. However, this behavior can be changed by + altering the global default privileges with + ALTER DEFAULT PRIVILEGES. +

Parameters

target_role

The name of an existing role of which the current role is a member. + If FOR ROLE is omitted, the current role is assumed. +

schema_name

The name of an existing schema. Each target_role + must have CREATE privileges for each specified schema. + If IN SCHEMA is omitted, the global default privileges + are altered. +

role_name

The name of an existing role to grant or revoke privileges for. + This parameter, and all the other parameters in + abbreviated_grant_or_revoke, + act as described under + GRANT or + REVOKE, + except that one is setting permissions for a whole class of objects + rather than specific named objects. +

Notes

Use psql's \ddp command + to obtain information about existing assignments of default privileges. + The meaning of the privilege values is the same as explained for + \dp under + GRANT. +

If you wish to drop a role for which the default privileges have been + altered, it is necessary to reverse the changes in its default privileges + or use DROP OWNED BY to get rid of the default privileges entry + for the role. +

Examples

Grant SELECT privilege to everyone for all tables (and views) you + subsequently create in schema myschema, and allow + role webuser to INSERT into them too: + +

ALTER DEFAULT PRIVILEGES IN SCHEMA myschema GRANT SELECT ON TABLES TO PUBLIC;
+ALTER DEFAULT PRIVILEGES IN SCHEMA myschema GRANT INSERT ON TABLES TO webuser;

+

Undo the above, so that subsequently-created tables won't have any + more permissions than normal: + +

ALTER DEFAULT PRIVILEGES IN SCHEMA myschema REVOKE SELECT ON TABLES FROM PUBLIC;
+ALTER DEFAULT PRIVILEGES IN SCHEMA myschema REVOKE INSERT ON TABLES FROM webuser;

+

Remove the public EXECUTE permission that is normally granted on functions, + for all functions subsequently created by role admin: + +

ALTER DEFAULT PRIVILEGES FOR ROLE admin REVOKE EXECUTE ON FUNCTIONS FROM PUBLIC;

Compatibility

There is no ALTER DEFAULT PRIVILEGES statement in the SQL + standard. +

See Also

GRANT, REVOKE

PrevHomeNext
ALTER DATABASEUpALTER DOMAIN
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-alterdomain.html b/doc/src/sgml/html/sql-alterdomain.html new file mode 100644 index 000000000..3a68da496 --- /dev/null +++ b/doc/src/sgml/html/sql-alterdomain.html @@ -0,0 +1,716 @@ + +ALTER DOMAIN

ALTER DOMAIN

Name

ALTER DOMAIN --  change the definition of a domain +

Synopsis

ALTER DOMAIN name
+    { SET DEFAULT expression | DROP DEFAULT }
+ALTER DOMAIN name
+    { SET | DROP } NOT NULL
+ALTER DOMAIN name
+    ADD domain_constraint [ NOT VALID ]
+ALTER DOMAIN name
+    DROP CONSTRAINT [ IF EXISTS ] constraint_name [ RESTRICT | CASCADE ]
+ALTER DOMAIN name
+     RENAME CONSTRAINT constraint_name TO new_constraint_name
+ALTER DOMAIN name
+    VALIDATE CONSTRAINT constraint_name
+ALTER DOMAIN name
+    OWNER TO new_owner
+ALTER DOMAIN name
+    RENAME TO new_name
+ALTER DOMAIN name
+    SET SCHEMA new_schema

Description

ALTER DOMAIN changes the definition of an existing domain. + There are several sub-forms: +

SET/DROP DEFAULT

These forms set or remove the default value for a domain. Note + that defaults only apply to subsequent INSERT + commands; they do not affect rows already in a table using the domain. +

SET/DROP NOT NULL

These forms change whether a domain is marked to allow NULL + values or to reject NULL values. You can only SET NOT NULL + when the columns using the domain contain no null values. +

ADD domain_constraint [ NOT VALID ]

This form adds a new constraint to a domain using the same syntax as + CREATE DOMAIN. + When a new constraint is added to a domain, all columns using that + domain will be checked against the newly added constraint. These + checks can be suppressed by adding the new constraint using the + NOT VALID option; the constraint can later be made + valid using ALTER DOMAIN ... VALIDATE CONSTRAINT. + Newly inserted or updated rows are always checked against all + constraints, even those marked NOT VALID. + NOT VALID is only accepted for CHECK constraints. +

DROP CONSTRAINT [ IF EXISTS ]

This form drops constraints on a domain. + If IF EXISTS is specified and the constraint + does not exist, no error is thrown. In this case a notice is issued instead. +

RENAME CONSTRAINT

This form changes the name of a constraint on a domain. +

VALIDATE CONSTRAINT

This form validates a constraint previously added as + NOT VALID, that is, verify that all data in columns using the + domain satisfy the specified constraint. +

OWNER

This form changes the owner of the domain to the specified user. +

RENAME

This form changes the name of the domain. +

SET SCHEMA

This form changes the schema of the domain. Any constraints + associated with the domain are moved into the new schema as well. +

You must own the domain to use ALTER DOMAIN. + To change the schema of a domain, you must also have + CREATE privilege on the new schema. + To alter the owner, you must also be a direct or indirect member of the new + owning role, and that role must have CREATE privilege on + the domain's schema. (These restrictions enforce that altering the owner + doesn't do anything you couldn't do by dropping and recreating the domain. + However, a superuser can alter ownership of any domain anyway.) +

Parameters

name

The name (possibly schema-qualified) of an existing domain to + alter. +

domain_constraint

New domain constraint for the domain. +

constraint_name

Name of an existing constraint to drop or rename. +

NOT VALID

Do not verify existing column data for constraint validity. +

CASCADE

Automatically drop objects that depend on the constraint. +

RESTRICT

Refuse to drop the constraint if there are any dependent + objects. This is the default behavior. +

new_name

The new name for the domain. +

new_constraint_name

The new name for the constraint. +

new_owner

The user name of the new owner of the domain. +

new_schema

The new schema for the domain. +

+

Notes

Currently, ALTER DOMAIN ADD CONSTRAINT and + ALTER DOMAIN SET NOT NULL will fail if the named domain or + any derived domain is used within a composite-type column of any + table in the database. They should eventually be improved to be + able to verify the new constraint for such nested columns. +

Examples

To add a NOT NULL constraint to a domain: +

ALTER DOMAIN zipcode SET NOT NULL;

+ To remove a NOT NULL constraint from a domain: +

ALTER DOMAIN zipcode DROP NOT NULL;

+

To add a check constraint to a domain: +

ALTER DOMAIN zipcode ADD CONSTRAINT zipchk CHECK (char_length(VALUE) = 5);

+

To remove a check constraint from a domain: +

ALTER DOMAIN zipcode DROP CONSTRAINT zipchk;

+

To rename a check constraint on a domain: +

ALTER DOMAIN zipcode RENAME CONSTRAINT zipchk TO zip_check;

+

To move the domain into a different schema: +

ALTER DOMAIN zipcode SET SCHEMA customers;

Compatibility

ALTER DOMAIN conforms to the SQL + standard, except for the OWNER, RENAME, SET SCHEMA, and + VALIDATE CONSTRAINT variants, which are + PostgreSQL extensions. The NOT VALID + clause of the ADD CONSTRAINT variant is also a + PostgreSQL extension. +


PrevHomeNext
ALTER DEFAULT PRIVILEGESUpALTER EXTENSION
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-alterextension.html b/doc/src/sgml/html/sql-alterextension.html new file mode 100644 index 000000000..d958a4731 --- /dev/null +++ b/doc/src/sgml/html/sql-alterextension.html @@ -0,0 +1,836 @@ + +ALTER EXTENSION

ALTER EXTENSION

Name

ALTER EXTENSION --  change the definition of an extension +

Synopsis

ALTER EXTENSION name UPDATE [ TO new_version ]
+ALTER EXTENSION name SET SCHEMA new_schema
+ALTER EXTENSION name ADD member_object
+ALTER EXTENSION name DROP member_object
+
+where member_object is:
+
+  AGGREGATE agg_name (agg_type [, ...] ) |
+  CAST (source_type AS target_type) |
+  COLLATION object_name |
+  CONVERSION object_name |
+  DOMAIN object_name |
+  FOREIGN DATA WRAPPER object_name |
+  FOREIGN TABLE object_name |
+  FUNCTION function_name ( [ [ argmode ] [ argname ] argtype [, ...] ] ) |
+  OPERATOR operator_name (left_type, right_type) |
+  OPERATOR CLASS object_name USING index_method |
+  OPERATOR FAMILY object_name USING index_method |
+  [ PROCEDURAL ] LANGUAGE object_name |
+  SCHEMA object_name |
+  SEQUENCE object_name |
+  SERVER object_name |
+  TABLE object_name |
+  TEXT SEARCH CONFIGURATION object_name |
+  TEXT SEARCH DICTIONARY object_name |
+  TEXT SEARCH PARSER object_name |
+  TEXT SEARCH TEMPLATE object_name |
+  TYPE object_name |
+  VIEW object_name

Description

ALTER EXTENSION changes the definition of an installed + extension. There are several subforms: + +

UPDATE

This form updates the extension to a newer version. The extension + must supply a suitable update script (or series of scripts) that can + modify the currently-installed version into the requested version. +

SET SCHEMA

This form moves the extension's objects into another schema. The + extension has to be relocatable for this command to + succeed. +

ADD member_object

This form adds an existing object to the extension. This is mainly + useful in extension update scripts. The object will subsequently + be treated as a member of the extension; notably, it can only be + dropped by dropping the extension. +

DROP member_object

This form removes a member object from the extension. This is mainly + useful in extension update scripts. The object is not dropped, only + disassociated from the extension. +

+ + See Section 35.15 for more information about these + operations. +

You must own the extension to use ALTER EXTENSION. + The ADD/DROP forms require ownership of the + added/dropped object as well. +

Parameters

name

The name of an installed extension. +

new_version

The desired new version of the extension. This can be written as + either an identifier or a string literal. If not specified, + ALTER EXTENSION UPDATE attempts to update to whatever is + shown as the default version in the extension's control file. +

new_schema

The new schema for the extension. +

object_name
agg_name
function_name
operator_name

The name of an object to be added to or removed from the extension. + Names of tables, + aggregates, domains, foreign tables, functions, operators, + operator classes, operator families, sequences, text search objects, + types, and views can be schema-qualified. +

agg_type

An input data type on which the aggregate function operates. + To reference a zero-argument aggregate function, write * + in place of the list of input data types. +

source_type

The name of the source data type of the cast. +

target_type

The name of the target data type of the cast. +

argmode

The mode of a function argument: IN, OUT, + INOUT, or VARIADIC. + If omitted, the default is IN. + Note that ALTER EXTENSION does not actually pay + any attention to OUT arguments, since only the input + arguments are needed to determine the function's identity. + So it is sufficient to list the IN, INOUT, + and VARIADIC arguments. +

argname

The name of a function argument. + Note that ALTER EXTENSION does not actually pay + any attention to argument names, since only the argument data + types are needed to determine the function's identity. +

argtype

The data type(s) of the function's arguments (optionally + schema-qualified), if any. +

left_type
right_type

The data type(s) of the operator's arguments (optionally + schema-qualified). Write NONE for the missing argument + of a prefix or postfix operator. +

PROCEDURAL

This is a noise word. +

+

Examples

To update the hstore extension to version 2.0: +

ALTER EXTENSION hstore UPDATE TO '2.0';

+

To change the schema of the hstore extension + to utils: +

ALTER EXTENSION hstore SET SCHEMA utils;

+

To add an existing function to the hstore extension: +

ALTER EXTENSION hstore ADD FUNCTION populate_record(anyelement, hstore);

Compatibility

ALTER EXTENSION is a PostgreSQL + extension. +


PrevHomeNext
ALTER DOMAINUpALTER FOREIGN DATA WRAPPER
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-alterforeigndatawrapper.html b/doc/src/sgml/html/sql-alterforeigndatawrapper.html new file mode 100644 index 000000000..2d7b6d78d --- /dev/null +++ b/doc/src/sgml/html/sql-alterforeigndatawrapper.html @@ -0,0 +1,482 @@ + +ALTER FOREIGN DATA WRAPPER

ALTER FOREIGN DATA WRAPPER

Name

ALTER FOREIGN DATA WRAPPER -- change the definition of a foreign-data wrapper

Synopsis

ALTER FOREIGN DATA WRAPPER name
+    [ HANDLER handler_function | NO HANDLER ]
+    [ VALIDATOR validator_function | NO VALIDATOR ]
+    [ OPTIONS ( [ ADD | SET | DROP ] option ['value'] [, ... ]) ]
+ALTER FOREIGN DATA WRAPPER name OWNER TO new_owner
+ALTER FOREIGN DATA WRAPPER name RENAME TO new_name

Description

ALTER FOREIGN DATA WRAPPER changes the + definition of a foreign-data wrapper. The first form of the + command changes the support functions or the generic options of the + foreign-data wrapper (at least one clause is required). The second + form changes the owner of the foreign-data wrapper. +

Only superusers can alter foreign-data wrappers. Additionally, + only superusers can own foreign-data wrappers. +

Parameters

name

The name of an existing foreign-data wrapper. +

HANDLER handler_function

Specifies a new handler function for the foreign-data wrapper. +

NO HANDLER

This is used to specify that the foreign-data wrapper should no + longer have a handler function. +

Note that foreign tables that use a foreign-data wrapper with no + handler cannot be accessed. +

VALIDATOR validator_function

Specifies a new validator function for the foreign-data wrapper. +

Note that it is possible that after changing the validator the + options to the foreign-data wrapper, servers, and user mappings + have become invalid. It is up to the user to make sure that + these options are correct before using the foreign-data + wrapper. +

NO VALIDATOR

This is used to specify that the foreign-data wrapper should no + longer have a validator function. +

OPTIONS ( [ ADD | SET | DROP ] option ['value'] [, ... ] )

Change options for the foreign-data + wrapper. ADD, SET, and DROP + specify the action to be performed. ADD is assumed + if no operation is explicitly specified. Option names must be + unique; names and values are also validated using the foreign + data wrapper's validator function, if any. +

new_owner

The user name of the new owner of the foreign-data wrapper. +

new_name

The new name for the foreign-data wrapper. +

Examples

Change a foreign-data wrapper dbi, add + option foo, drop bar: +

ALTER FOREIGN DATA WRAPPER dbi OPTIONS (ADD foo '1', DROP 'bar');

+

Change the foreign-data wrapper dbi validator + to bob.myvalidator: +

ALTER FOREIGN DATA WRAPPER dbi VALIDATOR bob.myvalidator;

Compatibility

ALTER FOREIGN DATA WRAPPER conforms to ISO/IEC + 9075-9 (SQL/MED), except that the HANDLER, + VALIDATOR, OWNER TO, and RENAME + clauses are extensions. +


PrevHomeNext
ALTER EXTENSIONUpALTER FOREIGN TABLE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-alterforeigntable.html b/doc/src/sgml/html/sql-alterforeigntable.html new file mode 100644 index 000000000..62f40a8e4 --- /dev/null +++ b/doc/src/sgml/html/sql-alterforeigntable.html @@ -0,0 +1,830 @@ + +ALTER FOREIGN TABLE

ALTER FOREIGN TABLE

Name

ALTER FOREIGN TABLE -- change the definition of a foreign table

Synopsis

ALTER FOREIGN TABLE [ IF EXISTS ] name
+    action [, ... ]
+ALTER FOREIGN TABLE [ IF EXISTS ] name
+    RENAME [ COLUMN ] column_name TO new_column_name
+ALTER FOREIGN TABLE [ IF EXISTS ] name
+    RENAME TO new_name
+ALTER FOREIGN TABLE [ IF EXISTS ] name
+    SET SCHEMA new_schema
+
+where action is one of:
+
+    ADD [ COLUMN ] column_name data_type [ NULL | NOT NULL ]
+    DROP [ COLUMN ] [ IF EXISTS ] column_name [ RESTRICT | CASCADE ]
+    ALTER [ COLUMN ] column_name [ SET DATA ] TYPE data_type
+    ALTER [ COLUMN ] column_name { SET | DROP } NOT NULL
+    ALTER [ COLUMN ] column_name SET STATISTICS integer
+    ALTER [ COLUMN ] column_name SET ( attribute_option = value [, ... ] )
+    ALTER [ COLUMN ] column_name RESET ( attribute_option [, ... ] )
+    ALTER [ COLUMN ] column_name OPTIONS ( [ ADD | SET | DROP ] option ['value'] [, ... ])
+    OWNER TO new_owner
+    OPTIONS ( [ ADD | SET | DROP ] option ['value'] [, ... ])

Description

ALTER FOREIGN TABLE changes the definition of an + existing foreign table. There are several subforms: + +

ADD COLUMN

This form adds a new column to the foreign table, using the same syntax as + CREATE FOREIGN TABLE. +

DROP COLUMN [ IF EXISTS ]

This form drops a column from a foreign table. + You will need to say CASCADE if + anything outside the table depends on the column; for example, + views. + If IF EXISTS is specified and the column + does not exist, no error is thrown. In this case a notice + is issued instead. +

IF EXISTS

Do not throw an error if the foreign table does not exist. A notice is + issued in this case. +

SET DATA TYPE

This form changes the type of a column of a foreign table. +

SET/DROP NOT NULL

Mark a column as allowing, or not allowing, null values. +

SET STATISTICS

This form + sets the per-column statistics-gathering target for subsequent + ANALYZE operations. + See the similar form of ALTER TABLE + for more details. +

SET ( attribute_option = value [, ... ] )
RESET ( attribute_option [, ... ] )

This form sets or resets per-attribute options. + See the similar form of ALTER TABLE + for more details. +

OWNER

This form changes the owner of the foreign table to the + specified user. +

RENAME

The RENAME forms change the name of a foreign table + or the name of an individual column in a foreign table. +

SET SCHEMA

This form moves the foreign table into another schema. +

OPTIONS ( [ ADD | SET | DROP ] option ['value'] [, ... ] )

Change options for the foreign table or one of its columns. + ADD, SET, and DROP + specify the action to be performed. ADD is assumed + if no operation is explicitly specified. Duplicate option names are not + allowed (although it's OK for a table option and a column option to have + the same name). Option names and values are also validated using the + foreign data wrapper library. +

+

All the actions except RENAME and SET SCHEMA + can be combined into + a list of multiple alterations to apply in parallel. For example, it + is possible to add several columns and/or alter the type of several + columns in a single command. +

You must own the table to use ALTER FOREIGN TABLE. + To change the schema of a foreign table, you must also have + CREATE privilege on the new schema. + To alter the owner, you must also be a direct or indirect member of the new + owning role, and that role must have CREATE privilege on + the table's schema. (These restrictions enforce that altering the owner + doesn't do anything you couldn't do by dropping and recreating the table. + However, a superuser can alter ownership of any table anyway.) + To add a column or alter a column type, you must also + have USAGE privilege on the data type. +

Parameters

name

The name (possibly schema-qualified) of an existing foreign table to + alter. +

column_name

Name of a new or existing column. +

new_column_name

New name for an existing column. +

new_name

New name for the table. +

data_type

Data type of the new column, or new data type for an existing + column. +

CASCADE

Automatically drop objects that depend on the dropped column + (for example, views referencing the column). +

RESTRICT

Refuse to drop the column if there are any dependent + objects. This is the default behavior. +

new_owner

The user name of the new owner of the table. +

new_schema

The name of the schema to which the table will be moved. +

Notes

The key word COLUMN is noise and can be omitted. +

Consistency with the foreign server is not checked when a column is added + or removed with ADD COLUMN or + DROP COLUMN, a NOT NULL constraint is + added, or a column type is changed with SET DATA TYPE. It is + the user's responsibility to ensure that the table definition matches the + remote side. +

Refer to CREATE FOREIGN TABLE for a further description of valid + parameters. +

Examples

To mark a column as not-null: +

ALTER FOREIGN TABLE distributors ALTER COLUMN street SET NOT NULL;

+

To change options of a foreign table: +

ALTER FOREIGN TABLE myschema.distributors OPTIONS (ADD opt1 'value', SET opt2, 'value2', DROP opt3 'value3');

Compatibility

The forms ADD, DROP, + and SET DATA TYPE + conform with the SQL standard. The other forms are + PostgreSQL extensions of the SQL standard. + Also, the ability to specify more than one manipulation in a single + ALTER FOREIGN TABLE command is an extension. +

ALTER FOREIGN TABLE DROP COLUMN can be used to drop the only + column of a foreign table, leaving a zero-column table. This is an + extension of SQL, which disallows zero-column foreign tables. +


PrevHomeNext
ALTER FOREIGN DATA WRAPPERUpALTER FUNCTION
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-alterfunction.html b/doc/src/sgml/html/sql-alterfunction.html new file mode 100644 index 000000000..934b5c4f8 --- /dev/null +++ b/doc/src/sgml/html/sql-alterfunction.html @@ -0,0 +1,837 @@ + +ALTER FUNCTION

ALTER FUNCTION

Name

ALTER FUNCTION -- change the definition of a function

Synopsis

ALTER FUNCTION name ( [ [ argmode ] [ argname ] argtype [, ...] ] )
+    action [ ... ] [ RESTRICT ]
+ALTER FUNCTION name ( [ [ argmode ] [ argname ] argtype [, ...] ] )
+    RENAME TO new_name
+ALTER FUNCTION name ( [ [ argmode ] [ argname ] argtype [, ...] ] )
+    OWNER TO new_owner
+ALTER FUNCTION name ( [ [ argmode ] [ argname ] argtype [, ...] ] )
+    SET SCHEMA new_schema
+
+where action is one of:
+
+    CALLED ON NULL INPUT | RETURNS NULL ON NULL INPUT | STRICT
+    IMMUTABLE | STABLE | VOLATILE | [ NOT ] LEAKPROOF
+    [ EXTERNAL ] SECURITY INVOKER | [ EXTERNAL ] SECURITY DEFINER
+    COST execution_cost
+    ROWS result_rows
+    SET configuration_parameter { TO | = } { value | DEFAULT }
+    SET configuration_parameter FROM CURRENT
+    RESET configuration_parameter
+    RESET ALL

Description

ALTER FUNCTION changes the definition of a + function. +

You must own the function to use ALTER FUNCTION. + To change a function's schema, you must also have CREATE + privilege on the new schema. + To alter the owner, you must also be a direct or indirect member of the new + owning role, and that role must have CREATE privilege on + the function's schema. (These restrictions enforce that altering the owner + doesn't do anything you couldn't do by dropping and recreating the function. + However, a superuser can alter ownership of any function anyway.) +

Parameters

name

The name (optionally schema-qualified) of an existing function. +

argmode

The mode of an argument: IN, OUT, + INOUT, or VARIADIC. + If omitted, the default is IN. + Note that ALTER FUNCTION does not actually pay + any attention to OUT arguments, since only the input + arguments are needed to determine the function's identity. + So it is sufficient to list the IN, INOUT, + and VARIADIC arguments. +

argname

The name of an argument. + Note that ALTER FUNCTION does not actually pay + any attention to argument names, since only the argument data + types are needed to determine the function's identity. +

argtype

The data type(s) of the function's arguments (optionally + schema-qualified), if any. +

new_name

The new name of the function. +

new_owner

The new owner of the function. Note that if the function is + marked SECURITY DEFINER, it will subsequently + execute as the new owner. +

new_schema

The new schema for the function. +

CALLED ON NULL INPUT
RETURNS NULL ON NULL INPUT
STRICT

CALLED ON NULL INPUT changes the function so + that it will be invoked when some or all of its arguments are + null. RETURNS NULL ON NULL INPUT or + STRICT changes the function so that it is not + invoked if any of its arguments are null; instead, a null result + is assumed automatically. See CREATE FUNCTION + for more information. +

IMMUTABLE
STABLE
VOLATILE

Change the volatility of the function to the specified setting. + See CREATE FUNCTION for details. +

[ EXTERNAL ] SECURITY INVOKER
[ EXTERNAL ] SECURITY DEFINER

Change whether the function is a security definer or not. The + key word EXTERNAL is ignored for SQL + conformance. See CREATE FUNCTION for more information about + this capability. +

LEAKPROOF

Change whether the function is considered leakproof or not. + See CREATE FUNCTION for more information about + this capability. +

COST execution_cost

Change the estimated execution cost of the function. + See CREATE FUNCTION for more information. +

ROWS result_rows

Change the estimated number of rows returned by a set-returning + function. See CREATE FUNCTION for more information. +

configuration_parameter
value

Add or change the assignment to be made to a configuration parameter + when the function is called. If + value is DEFAULT + or, equivalently, RESET is used, the function-local + setting is removed, so that the function executes with the value + present in its environment. Use RESET + ALL to clear all function-local settings. + SET FROM CURRENT saves the session's current value of + the parameter as the value to be applied when the function is entered. +

See SET and + Chapter 18 + for more information about allowed parameter names and values. +

RESTRICT

Ignored for conformance with the SQL standard. +

Examples

To rename the function sqrt for type + integer to square_root: +

ALTER FUNCTION sqrt(integer) RENAME TO square_root;

+

To change the owner of the function sqrt for type + integer to joe: +

ALTER FUNCTION sqrt(integer) OWNER TO joe;

+

To change the schema of the function sqrt for type + integer to maths: +

ALTER FUNCTION sqrt(integer) SET SCHEMA maths;

+

To adjust the search path that is automatically set for a function: +

ALTER FUNCTION check_password(text) SET search_path = admin, pg_temp;

+

To disable automatic setting of search_path for a function: +

ALTER FUNCTION check_password(text) RESET search_path;

+ The function will now execute with whatever search path is used by its + caller. +

Compatibility

This statement is partially compatible with the ALTER + FUNCTION statement in the SQL standard. The standard allows more + properties of a function to be modified, but does not provide the + ability to rename a function, make a function a security definer, + attach configuration parameter values to a function, + or change the owner, schema, or volatility of a function. The standard also + requires the RESTRICT key word, which is optional in + PostgreSQL. +


PrevHomeNext
ALTER FOREIGN TABLEUpALTER GROUP
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-altergroup.html b/doc/src/sgml/html/sql-altergroup.html new file mode 100644 index 000000000..de1f5c63f --- /dev/null +++ b/doc/src/sgml/html/sql-altergroup.html @@ -0,0 +1,370 @@ + +ALTER GROUP

ALTER GROUP

Name

ALTER GROUP -- change role name or membership

Synopsis

ALTER GROUP group_name ADD USER user_name [, ... ]
+ALTER GROUP group_name DROP USER user_name [, ... ]
+
+ALTER GROUP group_name RENAME TO new_name

Description

ALTER GROUP changes the attributes of a user group. + This is an obsolete command, though still accepted for backwards + compatibility, because groups (and users too) have been superseded by the + more general concept of roles. +

The first two variants add users to a group or remove them from a group. + (Any role can play the part of either a "user" or a + "group" for this purpose.) These variants are effectively + equivalent to granting or revoking membership in the role named as the + "group"; so the preferred way to do this is to use + GRANT or + REVOKE. +

The third variant changes the name of the group. This is exactly + equivalent to renaming the role with + ALTER ROLE. +

Parameters

group_name

The name of the group (role) to modify. +

user_name

Users (roles) that are to be added to or removed from the group. + The users must already exist; ALTER GROUP does not + create or drop users. +

new_name

The new name of the group. +

Examples

Add users to a group: + +

ALTER GROUP staff ADD USER karl, john;

+ + Remove a user from a group: + +

ALTER GROUP workers DROP USER beth;

Compatibility

There is no ALTER GROUP statement in the SQL + standard. +


PrevHomeNext
ALTER FUNCTIONUpALTER INDEX
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-alterindex.html b/doc/src/sgml/html/sql-alterindex.html new file mode 100644 index 000000000..092861135 --- /dev/null +++ b/doc/src/sgml/html/sql-alterindex.html @@ -0,0 +1,521 @@ + +ALTER INDEX

ALTER INDEX

Name

ALTER INDEX -- change the definition of an index

Synopsis

ALTER INDEX [ IF EXISTS ] name RENAME TO new_name
+ALTER INDEX [ IF EXISTS ] name SET TABLESPACE tablespace_name
+ALTER INDEX [ IF EXISTS ] name SET ( storage_parameter = value [, ... ] )
+ALTER INDEX [ IF EXISTS ] name RESET ( storage_parameter [, ... ] )

Description

ALTER INDEX changes the definition of an existing index. + There are several subforms: + +

IF EXISTS

Do not throw an error if the index does not exist. A notice is issued + in this case. +

RENAME

The RENAME form changes the name of the index. + There is no effect on the stored data. +

SET TABLESPACE

This form changes the index's tablespace to the specified tablespace and + moves the data file(s) associated with the index to the new tablespace. + See also + CREATE TABLESPACE. +

SET ( storage_parameter = value [, ... ] )

This form changes one or more index-method-specific storage parameters + for the index. See + CREATE INDEX + for details on the available parameters. Note that the index contents + will not be modified immediately by this command; depending on the + parameter you might need to rebuild the index with + REINDEX + to get the desired effects. +

RESET ( storage_parameter [, ... ] )

This form resets one or more index-method-specific storage parameters to + their defaults. As with SET, a REINDEX + might be needed to update the index entirely. +

+

Parameters

name

The name (possibly schema-qualified) of an existing index to + alter. +

new_name

The new name for the index. +

tablespace_name

The tablespace to which the index will be moved. +

storage_parameter

The name of an index-method-specific storage parameter. +

value

The new value for an index-method-specific storage parameter. + This might be a number or a word depending on the parameter. +

Notes

These operations are also possible using + ALTER TABLE. + ALTER INDEX is in fact just an alias for the forms + of ALTER TABLE that apply to indexes. +

There was formerly an ALTER INDEX OWNER variant, but + this is now ignored (with a warning). An index cannot have an owner + different from its table's owner. Changing the table's owner + automatically changes the index as well. +

Changing any part of a system catalog index is not permitted. +

Examples

To rename an existing index: +

ALTER INDEX distributors RENAME TO suppliers;

+

To move an index to a different tablespace: +

ALTER INDEX distributors SET TABLESPACE fasttablespace;

+

To change an index's fill factor (assuming that the index method + supports it): +

ALTER INDEX distributors SET (fillfactor = 75);
+REINDEX INDEX distributors;

Compatibility

ALTER INDEX is a PostgreSQL + extension. +


PrevHomeNext
ALTER GROUPUpALTER LANGUAGE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-alterlanguage.html b/doc/src/sgml/html/sql-alterlanguage.html new file mode 100644 index 000000000..b4ee8059c --- /dev/null +++ b/doc/src/sgml/html/sql-alterlanguage.html @@ -0,0 +1,299 @@ + +ALTER LANGUAGE

ALTER LANGUAGE

Name

ALTER LANGUAGE -- change the definition of a procedural language

Synopsis

ALTER [ PROCEDURAL ] LANGUAGE name RENAME TO new_name
+ALTER [ PROCEDURAL ] LANGUAGE name OWNER TO new_owner

Description

ALTER LANGUAGE changes the definition of a + procedural language. The only functionality is to rename the language or + assign a new owner. You must be superuser or owner of the language to + use ALTER LANGUAGE. +

Parameters

name

Name of a language +

new_name

The new name of the language +

new_owner

The new owner of the language +

Compatibility

There is no ALTER LANGUAGE statement in the SQL + standard. +


PrevHomeNext
ALTER INDEXUpALTER LARGE OBJECT
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-alterlargeobject.html b/doc/src/sgml/html/sql-alterlargeobject.html new file mode 100644 index 000000000..683075d46 --- /dev/null +++ b/doc/src/sgml/html/sql-alterlargeobject.html @@ -0,0 +1,273 @@ + +ALTER LARGE OBJECT

ALTER LARGE OBJECT

Name

ALTER LARGE OBJECT -- change the definition of a large object

Synopsis

ALTER LARGE OBJECT large_object_oid OWNER TO new_owner

Description

ALTER LARGE OBJECT changes the definition of a + large object. The only functionality is to assign a new owner. + You must be superuser or owner of the large object to use + ALTER LARGE OBJECT. +

Parameters

large_object_oid

OID of the large object to be altered +

new_owner

The new owner of the large object +

Compatibility

There is no ALTER LARGE OBJECT statement in the SQL + standard. +

See Also

Chapter 32

PrevHomeNext
ALTER LANGUAGEUpALTER OPERATOR
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-alteropclass.html b/doc/src/sgml/html/sql-alteropclass.html new file mode 100644 index 000000000..e4654fd71 --- /dev/null +++ b/doc/src/sgml/html/sql-alteropclass.html @@ -0,0 +1,363 @@ + +ALTER OPERATOR CLASS

ALTER OPERATOR CLASS

Name

ALTER OPERATOR CLASS -- change the definition of an operator class

Synopsis

ALTER OPERATOR CLASS name USING index_method RENAME TO new_name
+ALTER OPERATOR CLASS name USING index_method OWNER TO new_owner
+ALTER OPERATOR CLASS name USING index_method SET SCHEMA new_schema

Description

ALTER OPERATOR CLASS changes the definition of + an operator class. +

You must own the operator class to use ALTER OPERATOR CLASS. + To alter the owner, you must also be a direct or indirect member of the new + owning role, and that role must have CREATE privilege on + the operator class's schema. (These restrictions enforce that altering the + owner doesn't do anything you couldn't do by dropping and recreating the + operator class. However, a superuser can alter ownership of any operator + class anyway.) +

Parameters

name

The name (optionally schema-qualified) of an existing operator + class. +

index_method

The name of the index method this operator class is for. +

new_name

The new name of the operator class. +

new_owner

The new owner of the operator class. +

new_schema

The new schema for the operator class. +

Compatibility

There is no ALTER OPERATOR CLASS statement in + the SQL standard. +


PrevHomeNext
ALTER OPERATORUpALTER OPERATOR FAMILY
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-alteroperator.html b/doc/src/sgml/html/sql-alteroperator.html new file mode 100644 index 000000000..9d09dfee1 --- /dev/null +++ b/doc/src/sgml/html/sql-alteroperator.html @@ -0,0 +1,381 @@ + +ALTER OPERATOR

ALTER OPERATOR

Name

ALTER OPERATOR -- change the definition of an operator

Synopsis

ALTER OPERATOR name ( { left_type | NONE } , { right_type | NONE } ) OWNER TO new_owner
+ALTER OPERATOR name ( { left_type | NONE } , { right_type | NONE } ) SET SCHEMA new_schema

Description

ALTER OPERATOR changes the definition of + an operator. The only currently available functionality is to change the + owner of the operator. +

You must own the operator to use ALTER OPERATOR. + To alter the owner, you must also be a direct or indirect member of the new + owning role, and that role must have CREATE privilege on + the operator's schema. (These restrictions enforce that altering the owner + doesn't do anything you couldn't do by dropping and recreating the operator. + However, a superuser can alter ownership of any operator anyway.) +

Parameters

name

The name (optionally schema-qualified) of an existing operator. +

left_type

The data type of the operator's left operand; write + NONE if the operator has no left operand. +

right_type

The data type of the operator's right operand; write + NONE if the operator has no right operand. +

new_owner

The new owner of the operator. +

new_schema

The new schema for the operator. +

Examples

Change the owner of a custom operator a @@ b for type text: +

ALTER OPERATOR @@ (text, text) OWNER TO joe;

Compatibility

There is no ALTER OPERATOR statement in + the SQL standard. +


PrevHomeNext
ALTER LARGE OBJECTUpALTER OPERATOR CLASS
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-alteropfamily.html b/doc/src/sgml/html/sql-alteropfamily.html new file mode 100644 index 000000000..9a2a0a694 --- /dev/null +++ b/doc/src/sgml/html/sql-alteropfamily.html @@ -0,0 +1,789 @@ + +ALTER OPERATOR FAMILY

ALTER OPERATOR FAMILY

Name

ALTER OPERATOR FAMILY -- change the definition of an operator family

Synopsis

ALTER OPERATOR FAMILY name USING index_method ADD
+  {  OPERATOR strategy_number operator_name ( op_type, op_type ) [ FOR SEARCH | FOR ORDER BY sort_family_name ]
+   | FUNCTION support_number [ ( op_type [ , op_type ] ) ] function_name ( argument_type [, ...] )
+  } [, ... ]
+ALTER OPERATOR FAMILY name USING index_method DROP
+  {  OPERATOR strategy_number ( op_type [ , op_type ] )
+   | FUNCTION support_number ( op_type [ , op_type ] )
+  } [, ... ]
+ALTER OPERATOR FAMILY name USING index_method RENAME TO new_name
+ALTER OPERATOR FAMILY name USING index_method OWNER TO new_owner
+ALTER OPERATOR FAMILY name USING index_method SET SCHEMA new_schema

Description

ALTER OPERATOR FAMILY changes the definition of + an operator family. You can add operators and support functions + to the family, remove them from the family, + or change the family's name or owner. +

When operators and support functions are added to a family with + ALTER OPERATOR FAMILY, they are not part of any + specific operator class within the family, but are just "loose" + within the family. This indicates that these operators and functions + are compatible with the family's semantics, but are not required for + correct functioning of any specific index. (Operators and functions + that are so required should be declared as part of an operator class, + instead; see CREATE OPERATOR CLASS.) + PostgreSQL will allow loose members of a + family to be dropped from the family at any time, but members of an + operator class cannot be dropped without dropping the whole class and + any indexes that depend on it. + Typically, single-data-type operators + and functions are part of operator classes because they are needed to + support an index on that specific data type, while cross-data-type + operators and functions are made loose members of the family. +

You must be a superuser to use ALTER OPERATOR FAMILY. + (This restriction is made because an erroneous operator family definition + could confuse or even crash the server.) +

ALTER OPERATOR FAMILY does not presently check + whether the operator family definition includes all the operators and + functions required by the index method, nor whether the operators and + functions form a self-consistent set. It is the user's + responsibility to define a valid operator family. +

Refer to Section 35.14 for further information. +

Parameters

name

The name (optionally schema-qualified) of an existing operator + family. +

index_method

The name of the index method this operator family is for. +

strategy_number

The index method's strategy number for an operator + associated with the operator family. +

operator_name

The name (optionally schema-qualified) of an operator associated + with the operator family. +

op_type

In an OPERATOR clause, + the operand data type(s) of the operator, or NONE to + signify a left-unary or right-unary operator. Unlike the comparable + syntax in CREATE OPERATOR CLASS, the operand data types + must always be specified. +

In an ADD FUNCTION clause, the operand data type(s) the + function is intended to support, if different from + the input data type(s) of the function. For B-tree comparison functions + and hash functions it is not necessary to specify op_type since the function's input + data type(s) are always the correct ones to use. For B-tree sort + support functions and all functions in GiST, SP-GiST and GIN operator + classes, it is necessary to specify the operand data type(s) the function + is to be used with. +

In a DROP FUNCTION clause, the operand data type(s) the + function is intended to support must be specified. +

sort_family_name

The name (optionally schema-qualified) of an existing btree operator + family that describes the sort ordering associated with an ordering + operator. +

If neither FOR SEARCH nor FOR ORDER BY is + specified, FOR SEARCH is the default. +

support_number

The index method's support procedure number for a + function associated with the operator family. +

function_name

The name (optionally schema-qualified) of a function that is an + index method support procedure for the operator family. +

argument_type

The parameter data type(s) of the function. +

new_name

The new name of the operator family. +

new_owner

The new owner of the operator family. +

new_schema

The new schema for the operator family. +

The OPERATOR and FUNCTION + clauses can appear in any order. +

Notes

Notice that the DROP syntax only specifies the "slot" + in the operator family, by strategy or support number and input data + type(s). The name of the operator or function occupying the slot is not + mentioned. Also, for DROP FUNCTION the type(s) to specify + are the input data type(s) the function is intended to support; for + GiST, SP-GiST and GIN indexes this might have nothing to do with the actual + input argument types of the function. +

Because the index machinery does not check access permissions on functions + before using them, including a function or operator in an operator family + is tantamount to granting public execute permission on it. This is usually + not an issue for the sorts of functions that are useful in an operator + family. +

The operators should not be defined by SQL functions. A SQL function + is likely to be inlined into the calling query, which will prevent + the optimizer from recognizing that the query matches an index. +

Before PostgreSQL 8.4, the OPERATOR + clause could include a RECHECK option. This is no longer + supported because whether an index operator is "lossy" is now + determined on-the-fly at run time. This allows efficient handling of + cases where an operator might or might not be lossy. +

Examples

The following example command adds cross-data-type operators and + support functions to an operator family that already contains B-tree + operator classes for data types int4 and int2. +

ALTER OPERATOR FAMILY integer_ops USING btree ADD
+
+  -- int4 vs int2
+  OPERATOR 1 < (int4, int2) ,
+  OPERATOR 2 <= (int4, int2) ,
+  OPERATOR 3 = (int4, int2) ,
+  OPERATOR 4 >= (int4, int2) ,
+  OPERATOR 5 > (int4, int2) ,
+  FUNCTION 1 btint42cmp(int4, int2) ,
+
+  -- int2 vs int4
+  OPERATOR 1 < (int2, int4) ,
+  OPERATOR 2 <= (int2, int4) ,
+  OPERATOR 3 = (int2, int4) ,
+  OPERATOR 4 >= (int2, int4) ,
+  OPERATOR 5 > (int2, int4) ,
+  FUNCTION 1 btint24cmp(int2, int4) ;

To remove these entries again: +

ALTER OPERATOR FAMILY integer_ops USING btree DROP
+
+  -- int4 vs int2
+  OPERATOR 1 (int4, int2) ,
+  OPERATOR 2 (int4, int2) ,
+  OPERATOR 3 (int4, int2) ,
+  OPERATOR 4 (int4, int2) ,
+  OPERATOR 5 (int4, int2) ,
+  FUNCTION 1 (int4, int2) ,
+
+  -- int2 vs int4
+  OPERATOR 1 (int2, int4) ,
+  OPERATOR 2 (int2, int4) ,
+  OPERATOR 3 (int2, int4) ,
+  OPERATOR 4 (int2, int4) ,
+  OPERATOR 5 (int2, int4) ,
+  FUNCTION 1 (int2, int4) ;

Compatibility

There is no ALTER OPERATOR FAMILY statement in + the SQL standard. +


PrevHomeNext
ALTER OPERATOR CLASSUpALTER ROLE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-alterrole.html b/doc/src/sgml/html/sql-alterrole.html new file mode 100644 index 000000000..69eae016c --- /dev/null +++ b/doc/src/sgml/html/sql-alterrole.html @@ -0,0 +1,783 @@ + +ALTER ROLE

ALTER ROLE

Name

ALTER ROLE -- change a database role

Synopsis

ALTER ROLE name [ [ WITH ] option [ ... ] ]
+
+where option can be:
+
+      SUPERUSER | NOSUPERUSER
+    | CREATEDB | NOCREATEDB
+    | CREATEROLE | NOCREATEROLE
+    | CREATEUSER | NOCREATEUSER
+    | INHERIT | NOINHERIT
+    | LOGIN | NOLOGIN
+    | REPLICATION | NOREPLICATION
+    | CONNECTION LIMIT connlimit
+    | [ ENCRYPTED | UNENCRYPTED ] PASSWORD 'password'
+    | VALID UNTIL 'timestamp'
+
+ALTER ROLE name RENAME TO new_name
+
+ALTER ROLE name [ IN DATABASE database_name ] SET configuration_parameter { TO | = } { value | DEFAULT }
+ALTER ROLE name [ IN DATABASE database_name ] SET configuration_parameter FROM CURRENT
+ALTER ROLE name [ IN DATABASE database_name ] RESET configuration_parameter
+ALTER ROLE name [ IN DATABASE database_name ] RESET ALL

Description

ALTER ROLE changes the attributes of a + PostgreSQL role. +

The first variant of this command listed in the synopsis can change + many of the role attributes that can be specified in + CREATE ROLE. + (All the possible attributes are covered, + except that there are no options for adding or removing memberships; use + GRANT and + REVOKE for that.) + Attributes not mentioned in the command retain their previous settings. + Database superusers can change any of these settings for any role. + Roles having CREATEROLE privilege can change any of these + settings, but only for non-superuser and non-replication roles. + Ordinary roles can only change their own password. +

The second variant changes the name of the role. + Database superusers can rename any role. + Roles having CREATEROLE privilege can rename non-superuser + roles. + The current session user cannot be renamed. + (Connect as a different user if you need to do that.) + Because MD5-encrypted passwords use the role name as + cryptographic salt, renaming a role clears its password if the + password is MD5-encrypted. +

The remaining variants change a role's session default for a configuration + variable, either for all databases or, when the IN + DATABASE clause is specified, only for sessions in + the named database. Whenever the role subsequently + starts a new session, the specified value becomes the session + default, overriding whatever setting is present in + postgresql.conf or has been received from the postgres + command line. This only happens at login time; executing + SET ROLE or + SET SESSION AUTHORIZATION does not cause new + configuration values to be set. + Settings set for all databases are overridden by database-specific settings + attached to a role. + Superusers can change anyone's session defaults. Roles having + CREATEROLE privilege can change defaults for non-superuser + roles. Ordinary roles can only set defaults for themselves. + Certain configuration variables cannot be set this way, or can only be + set if a superuser issues the command. +

Parameters

name

The name of the role whose attributes are to be altered. +

SUPERUSER
NOSUPERUSER
CREATEDB
NOCREATEDB
CREATEROLE
NOCREATEROLE
CREATEUSER
NOCREATEUSER
INHERIT
NOINHERIT
LOGIN
NOLOGIN
REPLICATION
NOREPLICATION
CONNECTION LIMIT connlimit
PASSWORD password
ENCRYPTED
UNENCRYPTED
VALID UNTIL 'timestamp'

These clauses alter attributes originally set by + CREATE ROLE. For more information, see the + CREATE ROLE reference page. +

new_name

The new name of the role. +

database_name

The name of the database the configuration variable should be set in. +

configuration_parameter
value

Set this role's session default for the specified configuration + parameter to the given value. If + value is DEFAULT + or, equivalently, RESET is used, the + role-specific variable setting is removed, so the role will + inherit the system-wide default setting in new sessions. Use + RESET ALL to clear all role-specific settings. + SET FROM CURRENT saves the session's current value of + the parameter as the role-specific value. + If IN DATABASE is specified, the configuration + parameter is set or removed for the given role and database only. +

Role-specific variable settings take effect only at login; + SET ROLE and + SET SESSION AUTHORIZATION + do not process role-specific variable settings. +

See SET and Chapter 18 for more information about allowed + parameter names and values. +

Notes

Use CREATE ROLE + to add new roles, and DROP ROLE to remove a role. +

ALTER ROLE cannot change a role's memberships. + Use GRANT and + REVOKE + to do that. +

Caution must be exercised when specifying an unencrypted password + with this command. The password will be transmitted to the server + in cleartext, and it might also be logged in the client's command + history or the server log. psql + contains a command + \password that can be used to change a + role's password without exposing the cleartext password. +

It is also possible to tie a + session default to a specific database rather than to a role; see + ALTER DATABASE. + If there is a conflict, database-role-specific settings override role-specific + ones, which in turn override database-specific ones. +

Examples

Change a role's password: + +

ALTER ROLE davide WITH PASSWORD 'hu8jmn3';

+

Remove a role's password: + +

ALTER ROLE davide WITH PASSWORD NULL;

+

Change a password expiration date, specifying that the password + should expire at midday on 4th May 2015 using + the time zone which is one hour ahead of UTC: +

ALTER ROLE chris VALID UNTIL 'May 4 12:00:00 2015 +1';

+

Make a password valid forever: +

ALTER ROLE fred VALID UNTIL 'infinity';

+

Give a role the ability to create other roles and new databases: + +

ALTER ROLE miriam CREATEROLE CREATEDB;

+

Give a role a non-default setting of the + maintenance_work_mem parameter: + +

ALTER ROLE worker_bee SET maintenance_work_mem = 100000;

+

Give a role a non-default, database-specific setting of the + client_min_messages parameter: + +

ALTER ROLE fred IN DATABASE devel SET client_min_messages = DEBUG;

Compatibility

The ALTER ROLE statement is a + PostgreSQL extension. +


PrevHomeNext
ALTER OPERATOR FAMILYUpALTER SCHEMA
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-alterschema.html b/doc/src/sgml/html/sql-alterschema.html new file mode 100644 index 000000000..5ade60ec1 --- /dev/null +++ b/doc/src/sgml/html/sql-alterschema.html @@ -0,0 +1,316 @@ + +ALTER SCHEMA

ALTER SCHEMA

Name

ALTER SCHEMA -- change the definition of a schema

Synopsis

ALTER SCHEMA name RENAME TO new_name
+ALTER SCHEMA name OWNER TO new_owner

Description

ALTER SCHEMA changes the definition of a schema. +

You must own the schema to use ALTER SCHEMA. + To rename a schema you must also have the + CREATE privilege for the database. + To alter the owner, you must also be a direct or + indirect member of the new owning role, and you must have the + CREATE privilege for the database. + (Note that superusers have all these privileges automatically.) +

Parameters

name

The name of an existing schema. +

new_name

The new name of the schema. The new name cannot + begin with pg_, as such names + are reserved for system schemas. +

new_owner

The new owner of the schema. +

Compatibility

There is no ALTER SCHEMA statement in the SQL + standard. +


PrevHomeNext
ALTER ROLEUpALTER SEQUENCE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-altersequence.html b/doc/src/sgml/html/sql-altersequence.html new file mode 100644 index 000000000..d989b1657 --- /dev/null +++ b/doc/src/sgml/html/sql-altersequence.html @@ -0,0 +1,830 @@ + +ALTER SEQUENCE

ALTER SEQUENCE

Name

ALTER SEQUENCE --  change the definition of a sequence generator +

Synopsis

ALTER SEQUENCE [ IF EXISTS ] name [ INCREMENT [ BY ] increment ]
+    [ MINVALUE minvalue | NO MINVALUE ] [ MAXVALUE maxvalue | NO MAXVALUE ]
+    [ START [ WITH ] start ]
+    [ RESTART [ [ WITH ] restart ] ]
+    [ CACHE cache ] [ [ NO ] CYCLE ]
+    [ OWNED BY { table_name.column_name | NONE } ]
+ALTER SEQUENCE [ IF EXISTS ] name OWNER TO new_owner
+ALTER SEQUENCE [ IF EXISTS ] name RENAME TO new_name
+ALTER SEQUENCE [ IF EXISTS ] name SET SCHEMA new_schema

Description

ALTER SEQUENCE changes the parameters of an existing + sequence generator. Any parameters not specifically set in the + ALTER SEQUENCE command retain their prior settings. +

You must own the sequence to use ALTER SEQUENCE. + To change a sequence's schema, you must also have CREATE + privilege on the new schema. + To alter the owner, you must also be a direct or indirect member of the new + owning role, and that role must have CREATE privilege on + the sequence's schema. (These restrictions enforce that altering the owner + doesn't do anything you couldn't do by dropping and recreating the sequence. + However, a superuser can alter ownership of any sequence anyway.) +

Parameters

name

The name (optionally schema-qualified) of a sequence to be altered. +

IF EXISTS

Do not throw an error if the sequence does not exist. A notice is issued + in this case. +

increment

The clause INCREMENT BY increment is + optional. A positive value will make an ascending sequence, a + negative one a descending sequence. If unspecified, the old + increment value will be maintained. +

minvalue
NO MINVALUE

The optional clause MINVALUE minvalue determines + the minimum value a sequence can generate. If NO + MINVALUE is specified, the defaults of 1 and + -263-1 for ascending and descending sequences, + respectively, will be used. If neither option is specified, + the current minimum value will be maintained. +

maxvalue
NO MAXVALUE

The optional clause MAXVALUE maxvalue determines + the maximum value for the sequence. If NO + MAXVALUE is specified, the defaults are + 263-1 and -1 for ascending and descending + sequences, respectively, will be used. If neither option is + specified, the current maximum value will be maintained. +

start

The optional clause START WITH start changes the + recorded start value of the sequence. This has no effect on the + current sequence value; it simply sets the value + that future ALTER SEQUENCE RESTART commands will use. +

restart

The optional clause RESTART [ WITH restart ] changes the + current value of the sequence. This is equivalent to calling the + setval function with is_called = + false: the specified value will be returned by the + next call of nextval. + Writing RESTART with no restart value is equivalent to supplying + the start value that was recorded by CREATE SEQUENCE + or last set by ALTER SEQUENCE START WITH. +

cache

The clause CACHE cache enables + sequence numbers to be preallocated and stored in memory for + faster access. The minimum value is 1 (only one value can be + generated at a time, i.e., no cache). If unspecified, the old + cache value will be maintained. +

CYCLE

The optional CYCLE key word can be used to enable + the sequence to wrap around when the + maxvalue or + minvalue has been + reached by + an ascending or descending sequence respectively. If the limit is + reached, the next number generated will be the + minvalue or + maxvalue, + respectively. +

NO CYCLE

If the optional NO CYCLE key word is + specified, any calls to nextval after the + sequence has reached its maximum value will return an error. + If neither CYCLE or NO + CYCLE are specified, the old cycle behavior will be + maintained. +

OWNED BY table_name.column_name
OWNED BY NONE

The OWNED BY option causes the sequence to be + associated with a specific table column, such that if that column + (or its whole table) is dropped, the sequence will be automatically + dropped as well. If specified, this association replaces any + previously specified association for the sequence. The specified + table must have the same owner and be in the same schema as the + sequence. + Specifying OWNED BY NONE removes any existing + association, making the sequence "free-standing". +

new_owner

The user name of the new owner of the sequence. +

new_name

The new name for the sequence. +

new_schema

The new schema for the sequence. +

+

Notes

To avoid blocking of concurrent transactions that obtain numbers from the + same sequence, ALTER SEQUENCE's effects on the sequence + generation parameters are never rolled back; those changes take effect + immediately and are not reversible. However, the OWNED BY, + OWNER TO, RENAME TO, and SET SCHEMA + clauses cause ordinary catalog updates that can be rolled back. +

ALTER SEQUENCE will not immediately affect + nextval results in backends, + other than the current one, that have preallocated (cached) sequence + values. They will use up all cached values prior to noticing the changed + sequence generation parameters. The current backend will be affected + immediately. +

ALTER SEQUENCE does not affect the currval + status for the sequence. (Before PostgreSQL + 8.3, it sometimes did.) +

For historical reasons, ALTER TABLE can be used with + sequences too; but the only variants of ALTER TABLE + that are allowed with sequences are equivalent to the forms shown above. +

Examples

Restart a sequence called serial, at 105: +

ALTER SEQUENCE serial RESTART WITH 105;

Compatibility

ALTER SEQUENCE conforms to the SQL + standard, except for the START WITH, + OWNED BY, OWNER TO, RENAME TO, and + SET SCHEMA clauses, which are + PostgreSQL extensions. +


PrevHomeNext
ALTER SCHEMAUpALTER SERVER
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-alterserver.html b/doc/src/sgml/html/sql-alterserver.html new file mode 100644 index 000000000..dff028d45 --- /dev/null +++ b/doc/src/sgml/html/sql-alterserver.html @@ -0,0 +1,416 @@ + +ALTER SERVER

ALTER SERVER

Name

ALTER SERVER -- change the definition of a foreign server

Synopsis

ALTER SERVER name [ VERSION 'new_version' ]
+    [ OPTIONS ( [ ADD | SET | DROP ] option ['value'] [, ... ] ) ]
+ALTER SERVER name OWNER TO new_owner
+ALTER SERVER name RENAME TO new_name

Description

ALTER SERVER changes the definition of a foreign + server. The first form changes the server version string or the + generic options of the server (at least one clause is required). + The second form changes the owner of the server. +

To alter the server you must be the owner of the server. + Additionally to alter the owner, you must own the server and also + be a direct or indirect member of the new owning role, and you must + have USAGE privilege on the server's foreign-data + wrapper. (Note that superusers satisfy all these criteria + automatically.) +

Parameters

name

The name of an existing server. +

new_version

New server version. +

OPTIONS ( [ ADD | SET | DROP ] option ['value'] [, ... ] )

Change options for the + server. ADD, SET, and DROP + specify the action to be performed. ADD is assumed + if no operation is explicitly specified. Option names must be + unique; names and values are also validated using the server's + foreign-data wrapper library. +

new_owner

The user name of the new owner of the foreign server. +

new_name

The new name for the foreign server. +

Examples

Alter server foo, add connection options: +

ALTER SERVER foo OPTIONS (host 'foo', dbname 'foodb');

+

Alter server foo, change version, + change host option: +

ALTER SERVER foo VERSION '8.4' OPTIONS (SET host 'baz');

Compatibility

ALTER SERVER conforms to ISO/IEC 9075-9 (SQL/MED). + The OWNER TO and RENAME forms are + PostgreSQL extensions. +


PrevHomeNext
ALTER SEQUENCEUpALTER TABLE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-altertable.html b/doc/src/sgml/html/sql-altertable.html new file mode 100644 index 000000000..b35388eaf --- /dev/null +++ b/doc/src/sgml/html/sql-altertable.html @@ -0,0 +1,2183 @@ + +ALTER TABLE

ALTER TABLE

Name

ALTER TABLE -- change the definition of a table

Synopsis

ALTER TABLE [ IF EXISTS ] [ ONLY ] name [ * ]
+    action [, ... ]
+ALTER TABLE [ IF EXISTS ] [ ONLY ] name [ * ]
+    RENAME [ COLUMN ] column_name TO new_column_name
+ALTER TABLE [ IF EXISTS ] [ ONLY ] name [ * ]
+    RENAME CONSTRAINT constraint_name TO new_constraint_name
+ALTER TABLE [ IF EXISTS ] name
+    RENAME TO new_name
+ALTER TABLE [ IF EXISTS ] name
+    SET SCHEMA new_schema
+
+where action is one of:
+
+    ADD [ COLUMN ] column_name data_type [ COLLATE collation ] [ column_constraint [ ... ] ]
+    DROP [ COLUMN ] [ IF EXISTS ] column_name [ RESTRICT | CASCADE ]
+    ALTER [ COLUMN ] column_name [ SET DATA ] TYPE data_type [ COLLATE collation ] [ USING expression ]
+    ALTER [ COLUMN ] column_name SET DEFAULT expression
+    ALTER [ COLUMN ] column_name DROP DEFAULT
+    ALTER [ COLUMN ] column_name { SET | DROP } NOT NULL
+    ALTER [ COLUMN ] column_name SET STATISTICS integer
+    ALTER [ COLUMN ] column_name SET ( attribute_option = value [, ... ] )
+    ALTER [ COLUMN ] column_name RESET ( attribute_option [, ... ] )
+    ALTER [ COLUMN ] column_name SET STORAGE { PLAIN | EXTERNAL | EXTENDED | MAIN }
+    ADD table_constraint [ NOT VALID ]
+    ADD table_constraint_using_index
+    VALIDATE CONSTRAINT constraint_name
+    DROP CONSTRAINT [ IF EXISTS ]  constraint_name [ RESTRICT | CASCADE ]
+    DISABLE TRIGGER [ trigger_name | ALL | USER ]
+    ENABLE TRIGGER [ trigger_name | ALL | USER ]
+    ENABLE REPLICA TRIGGER trigger_name
+    ENABLE ALWAYS TRIGGER trigger_name
+    DISABLE RULE rewrite_rule_name
+    ENABLE RULE rewrite_rule_name
+    ENABLE REPLICA RULE rewrite_rule_name
+    ENABLE ALWAYS RULE rewrite_rule_name
+    CLUSTER ON index_name
+    SET WITHOUT CLUSTER
+    SET WITH OIDS
+    SET WITHOUT OIDS
+    SET ( storage_parameter = value [, ... ] )
+    RESET ( storage_parameter [, ... ] )
+    INHERIT parent_table
+    NO INHERIT parent_table
+    OF type_name
+    NOT OF
+    OWNER TO new_owner
+    SET TABLESPACE new_tablespace
+
+and table_constraint_using_index is:
+
+    [ CONSTRAINT constraint_name ]
+    { UNIQUE | PRIMARY KEY } USING INDEX index_name
+    [ DEFERRABLE | NOT DEFERRABLE ] [ INITIALLY DEFERRED | INITIALLY IMMEDIATE ]

Description

ALTER TABLE changes the definition of an existing table. + There are several subforms: + +

ADD COLUMN

This form adds a new column to the table, using the same syntax as + CREATE TABLE. +

DROP COLUMN [ IF EXISTS ]

This form drops a column from a table. Indexes and + table constraints involving the column will be automatically + dropped as well. You will need to say CASCADE if + anything outside the table depends on the column, for example, + foreign key references or views. + If IF EXISTS is specified and the column + does not exist, no error is thrown. In this case a notice + is issued instead. +

IF EXISTS

Do not throw an error if the table does not exist. A notice is issued + in this case. +

SET DATA TYPE

This form changes the type of a column of a table. Indexes and + simple table constraints involving the column will be automatically + converted to use the new column type by reparsing the originally + supplied expression. + The optional COLLATE clause specifies a collation + for the new column; if omitted, the collation is the default for the + new column type. + The optional USING + clause specifies how to compute the new column value from the old; + if omitted, the default conversion is the same as an assignment + cast from old data type to new. A USING + clause must be provided if there is no implicit or assignment + cast from old to new type. +

SET/DROP DEFAULT

These forms set or remove the default value for a column. + The default values only apply to subsequent INSERT + commands; they do not cause rows already in the table to change. + Defaults can also be created for views, in which case they are + inserted into INSERT statements on the view before + the view's ON INSERT rule is applied. +

SET/DROP NOT NULL

These forms change whether a column is marked to allow null + values or to reject null values. You can only use SET + NOT NULL when the column contains no null values. +

SET STATISTICS

This form + sets the per-column statistics-gathering target for subsequent + ANALYZE operations. + The target can be set in the range 0 to 10000; alternatively, set it + to -1 to revert to using the system default statistics + target (default_statistics_target). + For more information on the use of statistics by the + PostgreSQL query planner, refer to + Section 14.2. +

SET ( attribute_option = value [, ... ] )
RESET ( attribute_option [, ... ] )

This form sets or resets per-attribute options. Currently, the only + defined per-attribute options are n_distinct and + n_distinct_inherited, which override the + number-of-distinct-values estimates made by subsequent + ANALYZE + operations. n_distinct affects the statistics for the table + itself, while n_distinct_inherited affects the statistics + gathered for the table plus its inheritance children. When set to a + positive value, ANALYZE will assume that the column contains + exactly the specified number of distinct nonnull values. When set to a + negative value, which must be greater + than or equal to -1, ANALYZE will assume that the number of + distinct nonnull values in the column is linear in the size of the + table; the exact count is to be computed by multiplying the estimated + table size by the absolute value of the given number. For example, + a value of -1 implies that all values in the column are distinct, while + a value of -0.5 implies that each value appears twice on the average. + This can be useful when the size of the table changes over time, since + the multiplication by the number of rows in the table is not performed + until query planning time. Specify a value of 0 to revert to estimating + the number of distinct values normally. For more information on the use + of statistics by the PostgreSQL query + planner, refer to Section 14.2. +

SET STORAGE

This form sets the storage mode for a column. This controls whether this + column is held inline or in a secondary TOAST table, and + whether the data + should be compressed or not. PLAIN must be used + for fixed-length values such as integer and is + inline, uncompressed. MAIN is for inline, + compressible data. EXTERNAL is for external, + uncompressed data, and EXTENDED is for external, + compressed data. EXTENDED is the default for most + data types that support non-PLAIN storage. + Use of EXTERNAL will make substring operations on + very large text and bytea values run faster, + at the penalty of increased storage space. Note that + SET STORAGE doesn't itself change anything in the table, + it just sets the strategy to be pursued during future table updates. + See Section 56.2 for more information. +

ADD table_constraint [ NOT VALID ]

This form adds a new constraint to a table using the same syntax as + CREATE TABLE, plus the option NOT + VALID, which is currently only allowed for foreign key + and CHECK constraints. + If the constraint is marked NOT VALID, the + potentially-lengthy initial check to verify that all rows in the table + satisfy the constraint is skipped. The constraint will still be + enforced against subsequent inserts or updates (that is, they'll fail + unless there is a matching row in the referenced table, in the case + of foreign keys; and they'll fail unless the new row matches the + specified check constraints). But the + database will not assume that the constraint holds for all rows in + the table, until it is validated by using the VALIDATE + CONSTRAINT option. +

ADD table_constraint_using_index

This form adds a new PRIMARY KEY or UNIQUE + constraint to a table based on an existing unique index. All the + columns of the index will be included in the constraint. +

The index cannot have expression columns nor be a partial index. + Also, it must be a b-tree index with default sort ordering. These + restrictions ensure that the index is equivalent to one that would be + built by a regular ADD PRIMARY KEY or ADD UNIQUE + command. +

If PRIMARY KEY is specified, and the index's columns are not + already marked NOT NULL, then this command will attempt to + do ALTER COLUMN SET NOT NULL against each such column. + That requires a full table scan to verify the column(s) contain no + nulls. In all other cases, this is a fast operation. +

If a constraint name is provided then the index will be renamed to match + the constraint name. Otherwise the constraint will be named the same as + the index. +

After this command is executed, the index is "owned" by the + constraint, in the same way as if the index had been built by + a regular ADD PRIMARY KEY or ADD UNIQUE + command. In particular, dropping the constraint will make the index + disappear too. +

Note: Adding a constraint using an existing index can be helpful in + situations where a new constraint needs to be added without blocking + table updates for a long time. To do that, create the index using + CREATE INDEX CONCURRENTLY, and then install it as an + official constraint using this syntax. See the example below. +

VALIDATE CONSTRAINT

This form validates a foreign key or check constraint that was previously created + as NOT VALID, by scanning the table to ensure there + are no rows for which the constraint is not satisfied. + Nothing happens if the constraint is already marked valid. + The value of separating validation from initial creation of the + constraint is that validation requires a lesser lock on the table + than constraint creation does. +

DROP CONSTRAINT [ IF EXISTS ]

This form drops the specified constraint on a table. + If IF EXISTS is specified and the constraint + does not exist, no error is thrown. In this case a notice is issued instead. +

DISABLE/ENABLE [ REPLICA | ALWAYS ] TRIGGER

These forms configure the firing of trigger(s) belonging to the table. + A disabled trigger is still known to the system, but is not executed + when its triggering event occurs. For a deferred trigger, the enable + status is checked when the event occurs, not when the trigger function + is actually executed. One can disable or enable a single + trigger specified by name, or all triggers on the table, or only + user triggers (this option excludes internally generated constraint + triggers such as those that are used to implement foreign key + constraints or deferrable uniqueness and exclusion constraints). + Disabling or enabling internally generated constraint triggers + requires superuser privileges; it should be done with caution since + of course the integrity of the constraint cannot be guaranteed if the + triggers are not executed. + The trigger firing mechanism is also affected by the configuration + variable session_replication_role. Simply enabled + triggers will fire when the replication role is "origin" + (the default) or "local". Triggers configured as ENABLE + REPLICA will only fire if the session is in "replica" + mode, and triggers configured as ENABLE ALWAYS will + fire regardless of the current replication mode. +

DISABLE/ENABLE [ REPLICA | ALWAYS ] RULE

These forms configure the firing of rewrite rules belonging to the table. + A disabled rule is still known to the system, but is not applied + during query rewriting. The semantics are as for disabled/enabled + triggers. This configuration is ignored for ON SELECT rules, which + are always applied in order to keep views working even if the current + session is in a non-default replication role. +

CLUSTER ON

This form selects the default index for future + CLUSTER + operations. It does not actually re-cluster the table. +

SET WITHOUT CLUSTER

This form removes the most recently used + CLUSTER + index specification from the table. This affects + future cluster operations that don't specify an index. +

SET WITH OIDS

This form adds an oid system column to the + table (see Section 5.4). + It does nothing if the table already has OIDs. +

Note that this is not equivalent to ADD COLUMN oid oid; + that would add a normal column that happened to be named + oid, not a system column. +

SET WITHOUT OIDS

This form removes the oid system column from the + table. This is exactly equivalent to + DROP COLUMN oid RESTRICT, + except that it will not complain if there is already no + oid column. +

SET ( storage_parameter = value [, ... ] )

This form changes one or more storage parameters for the table. See + Storage Parameters + for details on the available parameters. Note that the table contents + will not be modified immediately by this command; depending on the + parameter you might need to rewrite the table to get the desired effects. + That can be done with VACUUM + FULL, CLUSTER or one of the forms + of ALTER TABLE that forces a table rewrite. +

Note: While CREATE TABLE allows OIDS to be specified + in the WITH (storage_parameter) syntax, + ALTER TABLE does not treat OIDS as a + storage parameter. Instead use the SET WITH OIDS + and SET WITHOUT OIDS forms to change OID status. +

RESET ( storage_parameter [, ... ] )

This form resets one or more storage parameters to their + defaults. As with SET, a table rewrite might be + needed to update the table entirely. +

INHERIT parent_table

This form adds the target table as a new child of the specified parent + table. Subsequently, queries against the parent will include records + of the target table. To be added as a child, the target table must + already contain all the same columns as the parent (it could have + additional columns, too). The columns must have matching data types, + and if they have NOT NULL constraints in the parent + then they must also have NOT NULL constraints in the + child. +

There must also be matching child-table constraints for all + CHECK constraints of the parent, except those + marked non-inheritable (that is, created with ALTER TABLE ... ADD CONSTRAINT ... NO INHERIT) + in the parent, which are ignored; all child-table constraints matched + must not be marked non-inheritable. + Currently + UNIQUE, PRIMARY KEY, and + FOREIGN KEY constraints are not considered, but + this might change in the future. +

NO INHERIT parent_table

This form removes the target table from the list of children of the + specified parent table. + Queries against the parent table will no longer include records drawn + from the target table. +

OF type_name

This form links the table to a composite type as though CREATE + TABLE OF had formed it. The table's list of column names and types + must precisely match that of the composite type; the presence of + an oid system column is permitted to differ. The table must + not inherit from any other table. These restrictions ensure + that CREATE TABLE OF would permit an equivalent table + definition. +

NOT OF

This form dissociates a typed table from its type. +

OWNER

This form changes the owner of the table, sequence, or view to the + specified user. +

SET TABLESPACE

This form changes the table's tablespace to the specified tablespace and + moves the data file(s) associated with the table to the new tablespace. + Indexes on the table, if any, are not moved; but they can be moved + separately with additional SET TABLESPACE commands. + See also + CREATE TABLESPACE. +

RENAME

The RENAME forms change the name of a table + (or an index, sequence, or view), the name of an individual column in + a table, or the name of a constraint of the table. There is no effect on the stored data. +

SET SCHEMA

This form moves the table into another schema. Associated indexes, + constraints, and sequences owned by table columns are moved as well. +

+

All the actions except RENAME and SET SCHEMA + can be combined into + a list of multiple alterations to apply in parallel. For example, it + is possible to add several columns and/or alter the type of several + columns in a single command. This is particularly useful with large + tables, since only one pass over the table need be made. +

You must own the table to use ALTER TABLE. + To change the schema of a table, you must also have + CREATE privilege on the new schema. + To add the table as a new child of a parent table, you must own the + parent table as well. + To alter the owner, you must also be a direct or indirect member of the new + owning role, and that role must have CREATE privilege on + the table's schema. (These restrictions enforce that altering the owner + doesn't do anything you couldn't do by dropping and recreating the table. + However, a superuser can alter ownership of any table anyway.) + To add a column or alter a column type or use the OF + clause, you must also have USAGE privilege on the data + type. +

Parameters

name

The name (optionally schema-qualified) of an existing table to + alter. If ONLY is specified before the table name, only + that table is altered. If ONLY is not specified, the table + and all its descendant tables (if any) are altered. Optionally, + * can be specified after the table name to explicitly + indicate that descendant tables are included. +

column_name

Name of a new or existing column. +

new_column_name

New name for an existing column. +

new_name

New name for the table. +

type

Data type of the new column, or new data type for an existing + column. +

table_constraint

New table constraint for the table. +

constraint_name

Name of an existing constraint to drop. +

CASCADE

Automatically drop objects that depend on the dropped column + or constraint (for example, views referencing the column). +

RESTRICT

Refuse to drop the column or constraint if there are any dependent + objects. This is the default behavior. +

trigger_name

Name of a single trigger to disable or enable. +

ALL

Disable or enable all triggers belonging to the table. + (This requires superuser privilege if any of the triggers are + internally generated constraint triggers such as those that are used + to implement foreign key constraints or deferrable uniqueness and + exclusion constraints.) +

USER

Disable or enable all triggers belonging to the table except for + internally generated constraint triggers such as those that are used + to implement foreign key constraints or deferrable uniqueness and + exclusion constraints. +

index_name

The index name on which the table should be marked for clustering. +

storage_parameter

The name of a table storage parameter. +

value

The new value for a table storage parameter. + This might be a number or a word depending on the parameter. +

parent_table

A parent table to associate or de-associate with this table. +

new_owner

The user name of the new owner of the table. +

new_tablespace

The name of the tablespace to which the table will be moved. +

new_schema

The name of the schema to which the table will be moved. +

Notes

The key word COLUMN is noise and can be omitted. +

When a column is added with ADD COLUMN, all existing + rows in the table are initialized with the column's default value + (NULL if no DEFAULT clause is specified). +

Adding a column with a non-null default or changing the type of an + existing column will require the entire table and indexes to be rewritten. + As an exception, if the USING clause does not change the column + contents and the old type is either binary coercible to the new type or + an unconstrained domain over the new type, a table rewrite is not needed, + but any indexes on the affected columns must still be rebuilt. Adding or + removing a system oid column also requires rewriting the entire + table. Table and/or index rebuilds may take a significant amount of time + for a large table; and will temporarily require as much as double the disk + space. +

Adding a CHECK or NOT NULL constraint requires + scanning the table to verify that existing rows meet the constraint. +

The main reason for providing the option to specify multiple changes + in a single ALTER TABLE is that multiple table scans or + rewrites can thereby be combined into a single pass over the table. +

The DROP COLUMN form does not physically remove + the column, but simply makes it invisible to SQL operations. Subsequent + insert and update operations in the table will store a null value for the + column. Thus, dropping a column is quick but it will not immediately + reduce the on-disk size of your table, as the space occupied + by the dropped column is not reclaimed. The space will be + reclaimed over time as existing rows are updated. (These statements do + not apply when dropping the system oid column; that is done + with an immediate rewrite.) +

To force an immediate rewrite of the table, you can use + VACUUM FULL, CLUSTER + or one of the forms of ALTER TABLE that forces a rewrite. This results in + no semantically-visible change in the table, but gets rid of + no-longer-useful data. +

The USING option of SET DATA TYPE can actually + specify any expression involving the old values of the row; that is, it + can refer to other columns as well as the one being converted. This allows + very general conversions to be done with the SET DATA TYPE + syntax. Because of this flexibility, the USING + expression is not applied to the column's default value (if any); the + result might not be a constant expression as required for a default. + This means that when there is no implicit or assignment cast from old to + new type, SET DATA TYPE might fail to convert the default even + though a USING clause is supplied. In such cases, + drop the default with DROP DEFAULT, perform the ALTER + TYPE, and then use SET DEFAULT to add a suitable new + default. Similar considerations apply to indexes and constraints involving + the column. +

If a table has any descendant tables, it is not permitted to add, + rename, or change the type of a column, or rename an inherited constraint + in the parent table without doing + the same to the descendants. That is, ALTER TABLE ONLY + will be rejected. This ensures that the descendants always have + columns matching the parent. +

A recursive DROP COLUMN operation will remove a + descendant table's column only if the descendant does not inherit + that column from any other parents and never had an independent + definition of the column. A nonrecursive DROP + COLUMN (i.e., ALTER TABLE ONLY ... DROP + COLUMN) never removes any descendant columns, but + instead marks them as independently defined rather than inherited. +

The TRIGGER, CLUSTER, OWNER, + and TABLESPACE actions never recurse to descendant tables; + that is, they always act as though ONLY were specified. + Adding a constraint recurses only for CHECK constraints + that are not marked NO INHERIT. +

Changing any part of a system catalog table is not permitted. +

Refer to CREATE TABLE for a further description of valid + parameters. Chapter 5 has further information on + inheritance. +

Examples

To add a column of type varchar to a table: +

ALTER TABLE distributors ADD COLUMN address varchar(30);

+

To drop a column from a table: +

ALTER TABLE distributors DROP COLUMN address RESTRICT;

+

To change the types of two existing columns in one operation: +

ALTER TABLE distributors
+    ALTER COLUMN address TYPE varchar(80),
+    ALTER COLUMN name TYPE varchar(100);

+

To change an integer column containing UNIX timestamps to timestamp + with time zone via a USING clause: +

ALTER TABLE foo
+    ALTER COLUMN foo_timestamp SET DATA TYPE timestamp with time zone
+    USING
+        timestamp with time zone 'epoch' + foo_timestamp * interval '1 second';

+

The same, when the column has a default expression that won't automatically + cast to the new data type: +

ALTER TABLE foo
+    ALTER COLUMN foo_timestamp DROP DEFAULT,
+    ALTER COLUMN foo_timestamp TYPE timestamp with time zone
+    USING
+        timestamp with time zone 'epoch' + foo_timestamp * interval '1 second',
+    ALTER COLUMN foo_timestamp SET DEFAULT now();

+

To rename an existing column: +

ALTER TABLE distributors RENAME COLUMN address TO city;

+

To rename an existing table: +

ALTER TABLE distributors RENAME TO suppliers;

+

To rename an existing constraint: +

ALTER TABLE distributors RENAME CONSTRAINT zipchk TO zip_check;

+

To add a not-null constraint to a column: +

ALTER TABLE distributors ALTER COLUMN street SET NOT NULL;

+ To remove a not-null constraint from a column: +

ALTER TABLE distributors ALTER COLUMN street DROP NOT NULL;

+

To add a check constraint to a table and all its children: +

ALTER TABLE distributors ADD CONSTRAINT zipchk CHECK (char_length(zipcode) = 5);

+

To add a check constraint only to a table and not to its children: +

ALTER TABLE distributors ADD CONSTRAINT zipchk CHECK (char_length(zipcode) = 5) NO INHERIT;

+ (The check constraint will not be inherited by future children, either.) +

To remove a check constraint from a table and all its children: +

ALTER TABLE distributors DROP CONSTRAINT zipchk;

+

To remove a check constraint from one table only: +

ALTER TABLE ONLY distributors DROP CONSTRAINT zipchk;

+ (The check constraint remains in place for any child tables.) +

To add a foreign key constraint to a table: +

ALTER TABLE distributors ADD CONSTRAINT distfk FOREIGN KEY (address) REFERENCES addresses (address);

+

To add a (multicolumn) unique constraint to a table: +

ALTER TABLE distributors ADD CONSTRAINT dist_id_zipcode_key UNIQUE (dist_id, zipcode);

+

To add an automatically named primary key constraint to a table, noting + that a table can only ever have one primary key: +

ALTER TABLE distributors ADD PRIMARY KEY (dist_id);

+

To move a table to a different tablespace: +

ALTER TABLE distributors SET TABLESPACE fasttablespace;

+

To move a table to a different schema: +

ALTER TABLE myschema.distributors SET SCHEMA yourschema;

+

To recreate a primary key constraint, without blocking updates while the + index is rebuilt: +

CREATE UNIQUE INDEX CONCURRENTLY dist_id_temp_idx ON distributors (dist_id);
+ALTER TABLE distributors DROP CONSTRAINT distributors_pkey,
+    ADD CONSTRAINT distributors_pkey PRIMARY KEY USING INDEX dist_id_temp_idx;

Compatibility

The forms ADD (without USING INDEX), + DROP, SET DEFAULT, + and SET DATA TYPE (without USING) + conform with the SQL standard. The other forms are + PostgreSQL extensions of the SQL standard. + Also, the ability to specify more than one manipulation in a single + ALTER TABLE command is an extension. +

ALTER TABLE DROP COLUMN can be used to drop the only + column of a table, leaving a zero-column table. This is an + extension of SQL, which disallows zero-column tables. +

See Also

CREATE TABLE

PrevHomeNext
ALTER SERVERUpALTER TABLESPACE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-altertablespace.html b/doc/src/sgml/html/sql-altertablespace.html new file mode 100644 index 000000000..d90feabdd --- /dev/null +++ b/doc/src/sgml/html/sql-altertablespace.html @@ -0,0 +1,398 @@ + +ALTER TABLESPACE

ALTER TABLESPACE

Name

ALTER TABLESPACE -- change the definition of a tablespace

Synopsis

ALTER TABLESPACE name RENAME TO new_name
+ALTER TABLESPACE name OWNER TO new_owner
+ALTER TABLESPACE name SET ( tablespace_option = value [, ... ] )
+ALTER TABLESPACE name RESET ( tablespace_option [, ... ] )

Description

ALTER TABLESPACE changes the definition of + a tablespace. +

You must own the tablespace to use ALTER TABLESPACE. + To alter the owner, you must also be a direct or indirect member of the new + owning role. + (Note that superusers have these privileges automatically.) +

Parameters

name

The name of an existing tablespace. +

new_name

The new name of the tablespace. The new name cannot + begin with pg_, as such names + are reserved for system tablespaces. +

new_owner

The new owner of the tablespace. +

tablespace_parameter

A tablespace parameter to be set or reset. Currently, the only + available parameters are seq_page_cost and + random_page_cost. Setting either value for a particular + tablespace will override the planner's usual estimate of the cost of + reading pages from tables in that tablespace, as established by + the configuration parameters of the same name (see + seq_page_cost, + random_page_cost). This may be useful if one + tablespace is located on a disk which is faster or slower than the + remainder of the I/O subsystem. +

Examples

Rename tablespace index_space to fast_raid: +

ALTER TABLESPACE index_space RENAME TO fast_raid;

+

Change the owner of tablespace index_space: +

ALTER TABLESPACE index_space OWNER TO mary;

Compatibility

There is no ALTER TABLESPACE statement in + the SQL standard. +


PrevHomeNext
ALTER TABLEUpALTER TEXT SEARCH CONFIGURATION
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-altertrigger.html b/doc/src/sgml/html/sql-altertrigger.html new file mode 100644 index 000000000..2a74f23f6 --- /dev/null +++ b/doc/src/sgml/html/sql-altertrigger.html @@ -0,0 +1,334 @@ + +ALTER TRIGGER

ALTER TRIGGER

Name

ALTER TRIGGER -- change the definition of a trigger

Synopsis

ALTER TRIGGER name ON table_name RENAME TO new_name

Description

ALTER TRIGGER changes properties of an existing + trigger. The RENAME clause changes the name of + the given trigger without otherwise changing the trigger + definition. +

You must own the table on which the trigger acts to be allowed to change its properties. +

Parameters

name

The name of an existing trigger to alter. +

table_name

The name of the table on which this trigger acts. +

new_name

The new name for the trigger. +

Notes

The ability to temporarily enable or disable a trigger is provided by + ALTER TABLE, not by + ALTER TRIGGER, because ALTER TRIGGER has no + convenient way to express the option of enabling or disabling all of + a table's triggers at once. +

Examples

To rename an existing trigger: +

ALTER TRIGGER emp_stamp ON emp RENAME TO emp_track_chgs;

Compatibility

ALTER TRIGGER is a PostgreSQL + extension of the SQL standard. +

See Also

ALTER TABLE

PrevHomeNext
ALTER TEXT SEARCH TEMPLATEUpALTER TYPE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-altertsconfig.html b/doc/src/sgml/html/sql-altertsconfig.html new file mode 100644 index 000000000..072d3fc6b --- /dev/null +++ b/doc/src/sgml/html/sql-altertsconfig.html @@ -0,0 +1,540 @@ + +ALTER TEXT SEARCH CONFIGURATION

ALTER TEXT SEARCH CONFIGURATION

Name

ALTER TEXT SEARCH CONFIGURATION -- change the definition of a text search configuration

Synopsis

ALTER TEXT SEARCH CONFIGURATION name
+    ADD MAPPING FOR token_type [, ... ] WITH dictionary_name [, ... ]
+ALTER TEXT SEARCH CONFIGURATION name
+    ALTER MAPPING FOR token_type [, ... ] WITH dictionary_name [, ... ]
+ALTER TEXT SEARCH CONFIGURATION name
+    ALTER MAPPING REPLACE old_dictionary WITH new_dictionary
+ALTER TEXT SEARCH CONFIGURATION name
+    ALTER MAPPING FOR token_type [, ... ] REPLACE old_dictionary WITH new_dictionary
+ALTER TEXT SEARCH CONFIGURATION name
+    DROP MAPPING [ IF EXISTS ] FOR token_type [, ... ]
+ALTER TEXT SEARCH CONFIGURATION name RENAME TO new_name
+ALTER TEXT SEARCH CONFIGURATION name OWNER TO new_owner
+ALTER TEXT SEARCH CONFIGURATION name SET SCHEMA new_schema

Description

ALTER TEXT SEARCH CONFIGURATION changes the definition of + a text search configuration. You can modify + its mappings from token types to dictionaries, + or change the configuration's name or owner. +

You must be the owner of the configuration to use + ALTER TEXT SEARCH CONFIGURATION. +

Parameters

name

The name (optionally schema-qualified) of an existing text search + configuration. +

token_type

The name of a token type that is emitted by the configuration's + parser. +

dictionary_name

The name of a text search dictionary to be consulted for the + specified token type(s). If multiple dictionaries are listed, + they are consulted in the specified order. +

old_dictionary

The name of a text search dictionary to be replaced in the mapping. +

new_dictionary

The name of a text search dictionary to be substituted for + old_dictionary. +

new_name

The new name of the text search configuration. +

new_owner

The new owner of the text search configuration. +

new_schema

The new schema for the text search configuration. +

The ADD MAPPING FOR form installs a list of dictionaries to be + consulted for the specified token type(s); it is an error if there is + already a mapping for any of the token types. + The ALTER MAPPING FOR form does the same, but first removing + any existing mapping for those token types. + The ALTER MAPPING REPLACE forms substitute new_dictionary for old_dictionary anywhere the latter appears. + This is done for only the specified token types when FOR + appears, or for all mappings of the configuration when it doesn't. + The DROP MAPPING form removes all dictionaries for the + specified token type(s), causing tokens of those types to be ignored + by the text search configuration. It is an error if there is no mapping + for the token types, unless IF EXISTS appears. +

Examples

The following example replaces the english dictionary + with the swedish dictionary anywhere that english + is used within my_config. +

ALTER TEXT SEARCH CONFIGURATION my_config
+  ALTER MAPPING REPLACE english WITH swedish;

Compatibility

There is no ALTER TEXT SEARCH CONFIGURATION statement in + the SQL standard. +


PrevHomeNext
ALTER TABLESPACEUpALTER TEXT SEARCH DICTIONARY
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-altertsdictionary.html b/doc/src/sgml/html/sql-altertsdictionary.html new file mode 100644 index 000000000..01595c117 --- /dev/null +++ b/doc/src/sgml/html/sql-altertsdictionary.html @@ -0,0 +1,417 @@ + +ALTER TEXT SEARCH DICTIONARY

ALTER TEXT SEARCH DICTIONARY

Name

ALTER TEXT SEARCH DICTIONARY -- change the definition of a text search dictionary

Synopsis

ALTER TEXT SEARCH DICTIONARY name (
+    option [ = value ] [, ... ]
+)
+ALTER TEXT SEARCH DICTIONARY name RENAME TO new_name
+ALTER TEXT SEARCH DICTIONARY name OWNER TO new_owner
+ALTER TEXT SEARCH DICTIONARY name SET SCHEMA new_schema

Description

ALTER TEXT SEARCH DICTIONARY changes the definition of + a text search dictionary. You can change the dictionary's + template-specific options, or change the dictionary's name or owner. +

You must be the owner of the dictionary to use + ALTER TEXT SEARCH DICTIONARY. +

Parameters

name

The name (optionally schema-qualified) of an existing text search + dictionary. +

option

The name of a template-specific option to be set for this dictionary. +

value

The new value to use for a template-specific option. + If the equal sign and value are omitted, then any previous + setting for the option is removed from the dictionary, + allowing the default to be used. +

new_name

The new name of the text search dictionary. +

new_owner

The new owner of the text search dictionary. +

new_schema

The new schema for the text search dictionary. +

Template-specific options can appear in any order. +

Examples

The following example command changes the stopword list + for a Snowball-based dictionary. Other parameters remain unchanged. +

ALTER TEXT SEARCH DICTIONARY my_dict ( StopWords = newrussian );

The following example command changes the language option to dutch, + and removes the stopword option entirely. +

ALTER TEXT SEARCH DICTIONARY my_dict ( language = dutch, StopWords );

The following example command "updates" the dictionary's + definition without actually changing anything. + +

ALTER TEXT SEARCH DICTIONARY my_dict ( dummy );

+ + (The reason this works is that the option removal code doesn't complain + if there is no such option.) This trick is useful when changing + configuration files for the dictionary: the ALTER will + force existing database sessions to re-read the configuration files, + which otherwise they would never do if they had read them earlier. +

Compatibility

There is no ALTER TEXT SEARCH DICTIONARY statement in + the SQL standard. +


PrevHomeNext
ALTER TEXT SEARCH CONFIGURATIONUpALTER TEXT SEARCH PARSER
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-altertsparser.html b/doc/src/sgml/html/sql-altertsparser.html new file mode 100644 index 000000000..6a9e91053 --- /dev/null +++ b/doc/src/sgml/html/sql-altertsparser.html @@ -0,0 +1,301 @@ + +ALTER TEXT SEARCH PARSER

ALTER TEXT SEARCH PARSER

Name

ALTER TEXT SEARCH PARSER -- change the definition of a text search parser

Synopsis

ALTER TEXT SEARCH PARSER name RENAME TO new_name
+ALTER TEXT SEARCH PARSER name SET SCHEMA new_schema

Description

ALTER TEXT SEARCH PARSER changes the definition of + a text search parser. Currently, the only supported functionality + is to change the parser's name. +

You must be a superuser to use ALTER TEXT SEARCH PARSER. +

Parameters

name

The name (optionally schema-qualified) of an existing text search parser. +

new_name

The new name of the text search parser. +

new_schema

The new schema for the text search parser. +

Compatibility

There is no ALTER TEXT SEARCH PARSER statement in + the SQL standard. +


PrevHomeNext
ALTER TEXT SEARCH DICTIONARYUpALTER TEXT SEARCH TEMPLATE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-altertstemplate.html b/doc/src/sgml/html/sql-altertstemplate.html new file mode 100644 index 000000000..9cdf478ab --- /dev/null +++ b/doc/src/sgml/html/sql-altertstemplate.html @@ -0,0 +1,301 @@ + +ALTER TEXT SEARCH TEMPLATE

ALTER TEXT SEARCH TEMPLATE

Name

ALTER TEXT SEARCH TEMPLATE -- change the definition of a text search template

Synopsis

ALTER TEXT SEARCH TEMPLATE name RENAME TO new_name
+ALTER TEXT SEARCH TEMPLATE name SET SCHEMA new_schema

Description

ALTER TEXT SEARCH TEMPLATE changes the definition of + a text search template. Currently, the only supported functionality + is to change the template's name. +

You must be a superuser to use ALTER TEXT SEARCH TEMPLATE. +

Parameters

name

The name (optionally schema-qualified) of an existing text search template. +

new_name

The new name of the text search template. +

new_schema

The new schema for the text search template. +

Compatibility

There is no ALTER TEXT SEARCH TEMPLATE statement in + the SQL standard. +


PrevHomeNext
ALTER TEXT SEARCH PARSERUpALTER TRIGGER
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-altertype.html b/doc/src/sgml/html/sql-altertype.html new file mode 100644 index 000000000..17f3632ba --- /dev/null +++ b/doc/src/sgml/html/sql-altertype.html @@ -0,0 +1,731 @@ + +ALTER TYPE

ALTER TYPE

Name

ALTER TYPE --  change the definition of a type +

Synopsis

ALTER TYPE name action [, ... ]
+ALTER TYPE name OWNER TO new_owner
+ALTER TYPE name RENAME ATTRIBUTE attribute_name TO new_attribute_name
+ALTER TYPE name RENAME TO new_name [ CASCADE | RESTRICT ]
+ALTER TYPE name SET SCHEMA new_schema
+ALTER TYPE name ADD VALUE new_enum_value [ { BEFORE | AFTER } existing_enum_value ]
+
+where action is one of:
+
+    ADD ATTRIBUTE attribute_name data_type [ COLLATE collation ] [ CASCADE | RESTRICT ]
+    DROP ATTRIBUTE [ IF EXISTS ] attribute_name [ CASCADE | RESTRICT ]
+    ALTER ATTRIBUTE attribute_name [ SET DATA ] TYPE data_type [ COLLATE collation ] [ CASCADE | RESTRICT ]

Description

ALTER TYPE changes the definition of an existing type. + There are several subforms: + +

ADD ATTRIBUTE

This form adds a new attribute to a composite type, using the same syntax as + CREATE TYPE. +

DROP ATTRIBUTE [ IF EXISTS ]

This form drops an attribute from a composite type. + If IF EXISTS is specified and the attribute + does not exist, no error is thrown. In this case a notice + is issued instead. +

SET DATA TYPE

This form changes the type of an attribute of a composite type. +

OWNER

This form changes the owner of the type. +

RENAME

This form changes the name of the type or the name of an + individual attribute of a composite type. +

SET SCHEMA

This form moves the type into another schema. +

ADD VALUE [ BEFORE | AFTER ]

This form adds a new value to an enum type. If the new value's place in + the enum's ordering is not specified using BEFORE or + AFTER, then the new item is placed at the end of the + list of values. +

CASCADE

Automatically propagate the operation to typed tables of the + type being altered, and their descendants. +

RESTRICT

Refuse the operation if the type being altered is the type of a + typed table. This is the default. +

+

The ADD ATTRIBUTE, DROP + ATTRIBUTE, and ALTER ATTRIBUTE actions + can be combined into a list of multiple alterations to apply in + parallel. For example, it is possible to add several attributes + and/or alter the type of several attributes in a single command. +

You must own the type to use ALTER TYPE. + To change the schema of a type, you must also have + CREATE privilege on the new schema. + To alter the owner, you must also be a direct or indirect member of the new + owning role, and that role must have CREATE privilege on + the type's schema. (These restrictions enforce that altering the owner + doesn't do anything you couldn't do by dropping and recreating the type. + However, a superuser can alter ownership of any type anyway.) + To add an attribute or alter an attribute type, you must also + have USAGE privilege on the data type. +

Parameters

name

The name (possibly schema-qualified) of an existing type to + alter. +

new_name

The new name for the type. +

new_owner

The user name of the new owner of the type. +

new_schema

The new schema for the type. +

attribute_name

The name of the attribute to add, alter, or drop. +

new_attribute_name

The new name of the attribute to be renamed. +

data_type

The data type of the attribute to add, or the new type of the + attribute to alter. +

new_enum_value

The new value to be added to an enum type's list of values. + Like all enum literals, it needs to be quoted. +

existing_enum_value

The existing enum value that the new value should be added immediately + before or after in the enum type's sort ordering. + Like all enum literals, it needs to be quoted. +

+

Notes

ALTER TYPE ... ADD VALUE (the form that adds a new value to an + enum type) cannot be executed inside a transaction block. +

Comparisons involving an added enum value will sometimes be slower than + comparisons involving only original members of the enum type. This will + usually only occur if BEFORE or AFTER + is used to set the new value's sort position somewhere other than at the + end of the list. However, sometimes it will happen even though the new + value is added at the end (this occurs if the OID counter "wrapped + around" since the original creation of the enum type). The slowdown is + usually insignificant; but if it matters, optimal performance can be + regained by dropping and recreating the enum type, or by dumping and + reloading the database. +

Examples

To rename a data type: +

ALTER TYPE electronic_mail RENAME TO email;

+

To change the owner of the type email + to joe: +

ALTER TYPE email OWNER TO joe;

+

To change the schema of the type email + to customers: +

ALTER TYPE email SET SCHEMA customers;

+

To add a new attribute to a type: +

ALTER TYPE compfoo ADD ATTRIBUTE f3 int;

+

To add a new value to an enum type in a particular sort position: +

ALTER TYPE colors ADD VALUE 'orange' AFTER 'red';

Compatibility

The variants to add and drop attributes are part of the SQL + standard; the other variants are PostgreSQL extensions. +


PrevHomeNext
ALTER TRIGGERUpALTER USER
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-alteruser.html b/doc/src/sgml/html/sql-alteruser.html new file mode 100644 index 000000000..512a9b683 --- /dev/null +++ b/doc/src/sgml/html/sql-alteruser.html @@ -0,0 +1,332 @@ + +ALTER USER

ALTER USER

Name

ALTER USER -- change a database role

Synopsis

ALTER USER name [ [ WITH ] option [ ... ] ]
+
+where option can be:
+
+      SUPERUSER | NOSUPERUSER
+    | CREATEDB | NOCREATEDB
+    | CREATEROLE | NOCREATEROLE
+    | CREATEUSER | NOCREATEUSER
+    | INHERIT | NOINHERIT
+    | LOGIN | NOLOGIN
+    | REPLICATION | NOREPLICATION
+    | CONNECTION LIMIT connlimit
+    | [ ENCRYPTED | UNENCRYPTED ] PASSWORD 'password'
+    | VALID UNTIL 'timestamp'
+
+ALTER USER name RENAME TO new_name
+
+ALTER USER name SET configuration_parameter { TO | = } { value | DEFAULT }
+ALTER USER name SET configuration_parameter FROM CURRENT
+ALTER USER name RESET configuration_parameter
+ALTER USER name RESET ALL

Description

ALTER USER is now an alias for + ALTER ROLE. +

Compatibility

The ALTER USER statement is a + PostgreSQL extension. The SQL standard + leaves the definition of users to the implementation. +

See Also

ALTER ROLE

PrevHomeNext
ALTER TYPEUpALTER USER MAPPING
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-alterusermapping.html b/doc/src/sgml/html/sql-alterusermapping.html new file mode 100644 index 000000000..165ef02c1 --- /dev/null +++ b/doc/src/sgml/html/sql-alterusermapping.html @@ -0,0 +1,384 @@ + +ALTER USER MAPPING

ALTER USER MAPPING

Name

ALTER USER MAPPING -- change the definition of a user mapping

Synopsis

ALTER USER MAPPING FOR { user_name | USER | CURRENT_USER | PUBLIC }
+    SERVER server_name
+    OPTIONS ( [ ADD | SET | DROP ] option ['value'] [, ... ] )

Description

ALTER USER MAPPING changes the definition of a + user mapping. +

The owner of a foreign server can alter user mappings for that + server for any user. Also, a user can alter a user mapping for + his own user name if USAGE privilege on the server has + been granted to the user. +

Parameters

user_name

User name of the mapping. CURRENT_USER + and USER match the name of the current + user. PUBLIC is used to match all present and future + user names in the system. +

server_name

Server name of the user mapping. +

OPTIONS ( [ ADD | SET | DROP ] option ['value'] [, ... ] )

Change options for the user mapping. The new options override + any previously specified + options. ADD, SET, and DROP + specify the action to be performed. ADD is assumed + if no operation is explicitly specified. Option names must be + unique; options are also validated by the server's foreign-data + wrapper. +

Examples

Change the password for user mapping bob, server foo: +

ALTER USER MAPPING FOR bob SERVER foo OPTIONS (user 'bob', password 'public');

Compatibility

ALTER USER MAPPING conforms to ISO/IEC 9075-9 + (SQL/MED). There is a subtle syntax issue: The standard omits + the FOR key word. Since both CREATE + USER MAPPING and DROP USER MAPPING use + FOR in analogous positions, and IBM DB2 (being + the other major SQL/MED implementation) also requires it + for ALTER USER MAPPING, PostgreSQL diverges from + the standard here in the interest of consistency and + interoperability. +


PrevHomeNext
ALTER USERUpALTER VIEW
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-alterview.html b/doc/src/sgml/html/sql-alterview.html new file mode 100644 index 000000000..af3bf0305 --- /dev/null +++ b/doc/src/sgml/html/sql-alterview.html @@ -0,0 +1,498 @@ + +ALTER VIEW

ALTER VIEW

Name

ALTER VIEW -- change the definition of a view

Synopsis

ALTER VIEW [ IF EXISTS ] name ALTER [ COLUMN ] column_name SET DEFAULT expression
+ALTER VIEW [ IF EXISTS ] name ALTER [ COLUMN ] column_name DROP DEFAULT
+ALTER VIEW [ IF EXISTS ] name OWNER TO new_owner
+ALTER VIEW [ IF EXISTS ] name RENAME TO new_name
+ALTER VIEW [ IF EXISTS ] name SET SCHEMA new_schema
+ALTER VIEW [ IF EXISTS ] name SET ( view_option_name [= view_option_value] [, ... ] )
+ALTER VIEW [ IF EXISTS ] name RESET ( view_option_name [, ... ] )

Description

ALTER VIEW changes various auxiliary properties + of a view. (If you want to modify the view's defining query, + use CREATE OR REPLACE VIEW.) +

You must own the view to use ALTER VIEW. + To change a view's schema, you must also have CREATE + privilege on the new schema. + To alter the owner, you must also be a direct or indirect member of the new + owning role, and that role must have CREATE privilege on + the view's schema. (These restrictions enforce that altering the owner + doesn't do anything you couldn't do by dropping and recreating the view. + However, a superuser can alter ownership of any view anyway.) +

Parameters

name

The name (optionally schema-qualified) of an existing view. +

IF EXISTS

Do not throw an error if the view does not exist. A notice is issued + in this case. +

SET/DROP DEFAULT

These forms set or remove the default value for a column. + A default value associated with a view column is + inserted into INSERT statements on the view before + the view's ON INSERT rule is applied, if + the INSERT does not specify a value for the column. +

new_owner

The user name of the new owner of the view. +

new_name

The new name for the view. +

new_schema

The new schema for the view. +

view_option_name

The name of a view option to be set or reset. +

view_option_name

The new value for a view option. +

Notes

For historical reasons, ALTER TABLE can be used with + views too; but the only variants of ALTER TABLE + that are allowed with views are equivalent to the ones shown above. +

Examples

To rename the view foo to + bar: +

ALTER VIEW foo RENAME TO bar;

Compatibility

ALTER VIEW is a PostgreSQL + extension of the SQL standard. +


PrevHomeNext
ALTER USER MAPPINGUpANALYZE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-analyze.html b/doc/src/sgml/html/sql-analyze.html new file mode 100644 index 000000000..c34c80d90 --- /dev/null +++ b/doc/src/sgml/html/sql-analyze.html @@ -0,0 +1,533 @@ + +ANALYZE

ANALYZE

Name

ANALYZE -- collect statistics about a database

Synopsis

ANALYZE [ VERBOSE ] [ table_name [ ( column_name [, ...] ) ] ]

Description

ANALYZE collects statistics about the contents + of tables in the database, and stores the results in the pg_statistic + system catalog. Subsequently, the query planner uses these + statistics to help determine the most efficient execution plans for + queries. +

With no parameter, ANALYZE examines every table in the + current database. With a parameter, ANALYZE examines + only that table. It is further possible to give a list of column names, + in which case only the statistics for those columns are collected. +

Parameters

VERBOSE

Enables display of progress messages. +

table_name

The name (possibly schema-qualified) of a specific table to + analyze. If omitted, all regular tables (but not foreign tables) + in the current database are analyzed. +

column_name

The name of a specific column to analyze. Defaults to all columns. +

Outputs

When VERBOSE is specified, ANALYZE emits + progress messages to indicate which table is currently being + processed. Various statistics about the tables are printed as well. +

Notes

Foreign tables are analyzed only when explicitly selected. Not all + foreign data wrappers support ANALYZE. If the table's + wrapper does not support ANALYZE, the command prints a + warning and does nothing. +

In the default PostgreSQL configuration, + the autovacuum daemon (see Section 23.1.6) + takes care of automatic analyzing of tables when they are first loaded + with data, and as they change throughout regular operation. + When autovacuum is disabled, + it is a good idea to run ANALYZE periodically, or + just after making major changes in the contents of a table. Accurate + statistics will help the planner to choose the most appropriate query + plan, and thereby improve the speed of query processing. A common + strategy for read-mostly databases is to run VACUUM + and ANALYZE once a day during a low-usage time of day. + (This will not be sufficient if there is heavy update activity.) +

ANALYZE + requires only a read lock on the target table, so it can run in + parallel with other activity on the table. +

The statistics collected by ANALYZE usually + include a list of some of the most common values in each column and + a histogram showing the approximate data distribution in each + column. One or both of these can be omitted if + ANALYZE deems them uninteresting (for example, + in a unique-key column, there are no common values) or if the + column data type does not support the appropriate operators. There + is more information about the statistics in Chapter 23. +

For large tables, ANALYZE takes a random sample + of the table contents, rather than examining every row. This + allows even very large tables to be analyzed in a small amount of + time. Note, however, that the statistics are only approximate, and + will change slightly each time ANALYZE is run, + even if the actual table contents did not change. This might result + in small changes in the planner's estimated costs shown by + EXPLAIN. + In rare situations, this non-determinism will cause the planner's + choices of query plans to change after ANALYZE is run. + To avoid this, raise the amount of statistics collected by + ANALYZE, as described below. +

The extent of analysis can be controlled by adjusting the + default_statistics_target configuration variable, or + on a column-by-column basis by setting the per-column statistics + target with ALTER TABLE ... ALTER COLUMN ... SET + STATISTICS (see ALTER TABLE). + The target value sets the + maximum number of entries in the most-common-value list and the + maximum number of bins in the histogram. The default target value + is 100, but this can be adjusted up or down to trade off accuracy of + planner estimates against the time taken for + ANALYZE and the amount of space occupied in + pg_statistic. In particular, setting the + statistics target to zero disables collection of statistics for + that column. It might be useful to do that for columns that are + never used as part of the WHERE, GROUP BY, + or ORDER BY clauses of queries, since the planner will + have no use for statistics on such columns. +

The largest statistics target among the columns being analyzed determines + the number of table rows sampled to prepare the statistics. Increasing + the target causes a proportional increase in the time and space needed + to do ANALYZE. +

One of the values estimated by ANALYZE is the number of + distinct values that appear in each column. Because only a subset of the + rows are examined, this estimate can sometimes be quite inaccurate, even + with the largest possible statistics target. If this inaccuracy leads to + bad query plans, a more accurate value can be determined manually and then + installed with + ALTER TABLE ... ALTER COLUMN ... SET (n_distinct = ...) + (see ALTER TABLE). +

If the table being analyzed has one or more children, + ANALYZE will gather statistics twice: once on the + rows of the parent table only, and a second time on the rows of the + parent table with all of its children. This second set of statistics + is needed when planning queries that traverse the entire inheritance + tree. The autovacuum daemon, however, will only consider inserts or + updates on the parent table itself when deciding whether to trigger an + automatic analyze for that table. If that table is rarely inserted into + or updated, the inheritance statistics will not be up to date unless you + run ANALYZE manually. +

If the table being analyzed is completely empty, ANALYZE + will not record new statistics for that table. Any existing statistics + will be retained. +

Compatibility

There is no ANALYZE statement in the SQL standard. +


PrevHomeNext
ALTER VIEWUpBEGIN
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-begin.html b/doc/src/sgml/html/sql-begin.html new file mode 100644 index 000000000..8176f80cd --- /dev/null +++ b/doc/src/sgml/html/sql-begin.html @@ -0,0 +1,425 @@ + +BEGIN

BEGIN

Name

BEGIN -- start a transaction block

Synopsis

BEGIN [ WORK | TRANSACTION ] [ transaction_mode [, ...] ]
+
+where transaction_mode is one of:
+
+    ISOLATION LEVEL { SERIALIZABLE | REPEATABLE READ | READ COMMITTED | READ UNCOMMITTED }
+    READ WRITE | READ ONLY
+    [ NOT ] DEFERRABLE

Description

BEGIN initiates a transaction block, that is, + all statements after a BEGIN command will be + executed in a single transaction until an explicit COMMIT or ROLLBACK is given. + By default (without BEGIN), + PostgreSQL executes + transactions in "autocommit" mode, that is, each + statement is executed in its own transaction and a commit is + implicitly performed at the end of the statement (if execution was + successful, otherwise a rollback is done). +

Statements are executed more quickly in a transaction block, because + transaction start/commit requires significant CPU and disk + activity. Execution of multiple statements inside a transaction is + also useful to ensure consistency when making several related changes: + other sessions will be unable to see the intermediate states + wherein not all the related updates have been done. +

If the isolation level, read/write mode, or deferrable mode is specified, the new + transaction has those characteristics, as if + SET TRANSACTION + was executed. +

Parameters

WORK
TRANSACTION

Optional key words. They have no effect. +

Refer to SET TRANSACTION for information on the meaning + of the other parameters to this statement. +

Notes

START TRANSACTION has the same functionality + as BEGIN. +

Use COMMIT or + ROLLBACK + to terminate a transaction block. +

Issuing BEGIN when already inside a transaction block will + provoke a warning message. The state of the transaction is not affected. + To nest transactions within a transaction block, use savepoints + (see SAVEPOINT). +

For reasons of backwards compatibility, the commas between successive + transaction_modes can be + omitted. +

Examples

To begin a transaction block: + +

BEGIN;

Compatibility

BEGIN is a PostgreSQL + language extension. It is equivalent to the SQL-standard command + START TRANSACTION, whose reference page + contains additional compatibility information. +

The DEFERRABLE + transaction_mode + is a PostgreSQL language extension. +

Incidentally, the BEGIN key word is used for a + different purpose in embedded SQL. You are advised to be careful + about the transaction semantics when porting database applications. +


PrevHomeNext
ANALYZEUpCHECKPOINT
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-checkpoint.html b/doc/src/sgml/html/sql-checkpoint.html new file mode 100644 index 000000000..be19206fe --- /dev/null +++ b/doc/src/sgml/html/sql-checkpoint.html @@ -0,0 +1,248 @@ + +CHECKPOINT

CHECKPOINT

Name

CHECKPOINT -- force a transaction log checkpoint

Synopsis

CHECKPOINT

Description

A checkpoint is a point in the transaction log sequence at which + all data files have been updated to reflect the information in the + log. All data files will be flushed to disk. Refer to + Section 29.4 for more details about what happens + during a checkpoint. +

The CHECKPOINT command forces an immediate + checkpoint when the command is issued, without waiting for a + regular checkpoint scheduled by the system (controlled by the settings in + Section 18.5.2). + CHECKPOINT is not intended for use during normal + operation. +

If executed during recovery, the CHECKPOINT command + will force a restartpoint (see Section 29.4) + rather than writing a new checkpoint. +

Only superusers can call CHECKPOINT. +

Compatibility

The CHECKPOINT command is a + PostgreSQL language extension. +


PrevHomeNext
BEGINUpCLOSE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-close.html b/doc/src/sgml/html/sql-close.html new file mode 100644 index 000000000..ff4a32a14 --- /dev/null +++ b/doc/src/sgml/html/sql-close.html @@ -0,0 +1,356 @@ + +CLOSE

CLOSE

Name

CLOSE -- close a cursor

Synopsis

CLOSE { name | ALL }

Description

CLOSE frees the resources associated with an open cursor. + After the cursor is closed, no subsequent operations + are allowed on it. A cursor should be closed when it is + no longer needed. +

Every non-holdable open cursor is implicitly closed when a + transaction is terminated by COMMIT or + ROLLBACK. A holdable cursor is implicitly + closed if the transaction that created it aborts via + ROLLBACK. If the creating transaction + successfully commits, the holdable cursor remains open until an + explicit CLOSE is executed, or the client + disconnects. +

Parameters

name

The name of an open cursor to close. +

ALL

Close all open cursors. +

Notes

PostgreSQL does not have an explicit + OPEN cursor statement; a cursor is considered + open when it is declared. Use the + DECLARE + statement to declare a cursor. +

You can see all available cursors by querying the pg_cursors system view. +

If a cursor is closed after a savepoint which is later rolled back, + the CLOSE is not rolled back; that is, the cursor + remains closed. +

Examples

Close the cursor liahona: +

CLOSE liahona;

Compatibility

CLOSE is fully conforming with the SQL + standard. CLOSE ALL is a PostgreSQL + extension. +

See Also

DECLARE, FETCH, MOVE

PrevHomeNext
CHECKPOINTUpCLUSTER
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-cluster.html b/doc/src/sgml/html/sql-cluster.html new file mode 100644 index 000000000..b32a28934 --- /dev/null +++ b/doc/src/sgml/html/sql-cluster.html @@ -0,0 +1,522 @@ + +CLUSTER

CLUSTER

Name

CLUSTER -- cluster a table according to an index

Synopsis

CLUSTER [VERBOSE] table_name [ USING index_name ]
+CLUSTER [VERBOSE]

Description

CLUSTER instructs PostgreSQL + to cluster the table specified + by table_name + based on the index specified by + index_name. The index must + already have been defined on + table_name. +

When a table is clustered, it is physically reordered + based on the index information. Clustering is a one-time operation: + when the table is subsequently updated, the changes are + not clustered. That is, no attempt is made to store new or + updated rows according to their index order. (If one wishes, one can + periodically recluster by issuing the command again. Also, setting + the table's FILLFACTOR storage parameter to less than + 100% can aid in preserving cluster ordering during updates, since updated + rows are kept on the same page if enough space is available there.) +

When a table is clustered, PostgreSQL + remembers which index it was clustered by. The form + CLUSTER table_name + reclusters the table using the same index as before. You can also + use the CLUSTER or SET WITHOUT CLUSTER + forms of ALTER TABLE to set the index to be used for + future cluster operations, or to clear any previous setting. +

CLUSTER without any parameter reclusters all the + previously-clustered tables in the current database that the calling user + owns, or all such tables if called by a superuser. This + form of CLUSTER cannot be executed inside a transaction + block. +

When a table is being clustered, an ACCESS + EXCLUSIVE lock is acquired on it. This prevents any other + database operations (both reads and writes) from operating on the + table until the CLUSTER is finished. +

Parameters

table_name

The name (possibly schema-qualified) of a table. +

index_name

The name of an index. +

VERBOSE

Prints a progress report as each table is clustered. +

Notes

In cases where you are accessing single rows randomly + within a table, the actual order of the data in the + table is unimportant. However, if you tend to access some + data more than others, and there is an index that groups + them together, you will benefit from using CLUSTER. + If you are requesting a range of indexed values from a table, or a + single indexed value that has multiple rows that match, + CLUSTER will help because once the index identifies the + table page for the first row that matches, all other rows + that match are probably already on the same table page, + and so you save disk accesses and speed up the query. +

CLUSTER can re-sort the table using either an index scan + on the specified index, or (if the index is a b-tree) a sequential + scan followed by sorting. It will attempt to choose the method that + will be faster, based on planner cost parameters and available statistical + information. +

When an index scan is used, a temporary copy of the table is created that + contains the table data in the index order. Temporary copies of each + index on the table are created as well. Therefore, you need free space on + disk at least equal to the sum of the table size and the index sizes. +

When a sequential scan and sort is used, a temporary sort file is + also created, so that the peak temporary space requirement is as much + as double the table size, plus the index sizes. This method is often + faster than the index scan method, but if the disk space requirement is + intolerable, you can disable this choice by temporarily setting enable_sort to off. +

It is advisable to set maintenance_work_mem to + a reasonably large value (but not more than the amount of RAM you can + dedicate to the CLUSTER operation) before clustering. +

Because the planner records statistics about the ordering of + tables, it is advisable to run ANALYZE + on the newly clustered table. + Otherwise, the planner might make poor choices of query plans. +

Because CLUSTER remembers which indexes are clustered, + one can cluster the tables one wants clustered manually the first time, + then set up a periodic maintenance script that executes + CLUSTER without any parameters, so that the desired tables + are periodically reclustered. +

Examples

Cluster the table employees on the basis of + its index employees_ind: +

CLUSTER employees USING employees_ind;

+

Cluster the employees table using the same + index that was used before: +

CLUSTER employees;

+

Cluster all tables in the database that have previously been clustered: +

CLUSTER;

Compatibility

There is no CLUSTER statement in the SQL standard. +

The syntax +

CLUSTER index_name ON table_name

+ is also supported for compatibility with pre-8.3 PostgreSQL + versions. +

See Also

clusterdb

PrevHomeNext
CLOSEUpCOMMENT
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-commands.html b/doc/src/sgml/html/sql-commands.html new file mode 100644 index 000000000..280391584 --- /dev/null +++ b/doc/src/sgml/html/sql-commands.html @@ -0,0 +1,952 @@ + +SQL Commands

I. SQL Commands

This part contains reference information for the + SQL commands supported by + PostgreSQL. By "SQL" the + language in general is meant; information about the standards + conformance and compatibility of each command can be found on the + respective reference page. +

Table of Contents
ABORT -- abort the current transaction
ALTER AGGREGATE -- change the definition of an aggregate function
ALTER COLLATION -- change the definition of a collation
ALTER CONVERSION -- change the definition of a conversion
ALTER DATABASE -- change a database
ALTER DEFAULT PRIVILEGES -- define default access privileges
ALTER DOMAIN --  change the definition of a domain +
ALTER EXTENSION --  change the definition of an extension +
ALTER FOREIGN DATA WRAPPER -- change the definition of a foreign-data wrapper
ALTER FOREIGN TABLE -- change the definition of a foreign table
ALTER FUNCTION -- change the definition of a function
ALTER GROUP -- change role name or membership
ALTER INDEX -- change the definition of an index
ALTER LANGUAGE -- change the definition of a procedural language
ALTER LARGE OBJECT -- change the definition of a large object
ALTER OPERATOR -- change the definition of an operator
ALTER OPERATOR CLASS -- change the definition of an operator class
ALTER OPERATOR FAMILY -- change the definition of an operator family
ALTER ROLE -- change a database role
ALTER SCHEMA -- change the definition of a schema
ALTER SEQUENCE --  change the definition of a sequence generator +
ALTER SERVER -- change the definition of a foreign server
ALTER TABLE -- change the definition of a table
ALTER TABLESPACE -- change the definition of a tablespace
ALTER TEXT SEARCH CONFIGURATION -- change the definition of a text search configuration
ALTER TEXT SEARCH DICTIONARY -- change the definition of a text search dictionary
ALTER TEXT SEARCH PARSER -- change the definition of a text search parser
ALTER TEXT SEARCH TEMPLATE -- change the definition of a text search template
ALTER TRIGGER -- change the definition of a trigger
ALTER TYPE --  change the definition of a type +
ALTER USER -- change a database role
ALTER USER MAPPING -- change the definition of a user mapping
ALTER VIEW -- change the definition of a view
ANALYZE -- collect statistics about a database
BEGIN -- start a transaction block
CHECKPOINT -- force a transaction log checkpoint
CLOSE -- close a cursor
CLUSTER -- cluster a table according to an index
COMMENT -- define or change the comment of an object
COMMIT -- commit the current transaction
COMMIT PREPARED -- commit a transaction that was earlier prepared for two-phase commit
COPY -- copy data between a file and a table
CREATE AGGREGATE -- define a new aggregate function
CREATE CAST -- define a new cast
CREATE COLLATION -- define a new collation
CREATE CONVERSION -- define a new encoding conversion
CREATE DATABASE -- create a new database
CREATE DOMAIN -- define a new domain
CREATE EXTENSION -- install an extension
CREATE FOREIGN DATA WRAPPER -- define a new foreign-data wrapper
CREATE FOREIGN TABLE -- define a new foreign table
CREATE FUNCTION -- define a new function
CREATE GROUP -- define a new database role
CREATE INDEX -- define a new index
CREATE LANGUAGE -- define a new procedural language
CREATE OPERATOR -- define a new operator
CREATE OPERATOR CLASS -- define a new operator class
CREATE OPERATOR FAMILY -- define a new operator family
CREATE ROLE -- define a new database role
CREATE RULE -- define a new rewrite rule
CREATE SCHEMA -- define a new schema
CREATE SEQUENCE -- define a new sequence generator
CREATE SERVER -- define a new foreign server
CREATE TABLE -- define a new table
CREATE TABLE AS -- define a new table from the results of a query
CREATE TABLESPACE -- define a new tablespace
CREATE TEXT SEARCH CONFIGURATION -- define a new text search configuration
CREATE TEXT SEARCH DICTIONARY -- define a new text search dictionary
CREATE TEXT SEARCH PARSER -- define a new text search parser
CREATE TEXT SEARCH TEMPLATE -- define a new text search template
CREATE TRIGGER -- define a new trigger
CREATE TYPE -- define a new data type
CREATE USER -- define a new database role
CREATE USER MAPPING -- define a new mapping of a user to a foreign server
CREATE VIEW -- define a new view
DEALLOCATE -- deallocate a prepared statement
DECLARE -- define a cursor
DELETE -- delete rows of a table
DISCARD -- discard session state
DO -- execute an anonymous code block
DROP AGGREGATE -- remove an aggregate function
DROP CAST -- remove a cast
DROP COLLATION -- remove a collation
DROP CONVERSION -- remove a conversion
DROP DATABASE -- remove a database
DROP DOMAIN -- remove a domain
DROP EXTENSION -- remove an extension
DROP FOREIGN DATA WRAPPER -- remove a foreign-data wrapper
DROP FOREIGN TABLE -- remove a foreign table
DROP FUNCTION -- remove a function
DROP GROUP -- remove a database role
DROP INDEX -- remove an index
DROP LANGUAGE -- remove a procedural language
DROP OPERATOR -- remove an operator
DROP OPERATOR CLASS -- remove an operator class
DROP OPERATOR FAMILY -- remove an operator family
DROP OWNED -- remove database objects owned by a database role
DROP ROLE -- remove a database role
DROP RULE -- remove a rewrite rule
DROP SCHEMA -- remove a schema
DROP SEQUENCE -- remove a sequence
DROP SERVER -- remove a foreign server descriptor
DROP TABLE -- remove a table
DROP TABLESPACE -- remove a tablespace
DROP TEXT SEARCH CONFIGURATION -- remove a text search configuration
DROP TEXT SEARCH DICTIONARY -- remove a text search dictionary
DROP TEXT SEARCH PARSER -- remove a text search parser
DROP TEXT SEARCH TEMPLATE -- remove a text search template
DROP TRIGGER -- remove a trigger
DROP TYPE -- remove a data type
DROP USER -- remove a database role
DROP USER MAPPING -- remove a user mapping for a foreign server
DROP VIEW -- remove a view
END -- commit the current transaction
EXECUTE -- execute a prepared statement
EXPLAIN -- show the execution plan of a statement
FETCH -- retrieve rows from a query using a cursor
GRANT -- define access privileges
INSERT -- create new rows in a table
LISTEN -- listen for a notification
LOAD -- load a shared library file
LOCK -- lock a table
MOVE -- position a cursor
NOTIFY -- generate a notification
PREPARE -- prepare a statement for execution
PREPARE TRANSACTION -- prepare the current transaction for two-phase commit
REASSIGN OWNED -- change the ownership of database objects owned by a database role
REINDEX -- rebuild indexes
RELEASE SAVEPOINT -- destroy a previously defined savepoint
RESET -- restore the value of a run-time parameter to the default value
REVOKE -- remove access privileges
ROLLBACK -- abort the current transaction
ROLLBACK PREPARED -- cancel a transaction that was earlier prepared for two-phase commit
ROLLBACK TO SAVEPOINT -- roll back to a savepoint
SAVEPOINT -- define a new savepoint within the current transaction
SECURITY LABEL -- define or change a security label applied to an object
SELECT -- retrieve rows from a table or view
SELECT INTO -- define a new table from the results of a query
SET -- change a run-time parameter
SET CONSTRAINTS -- set constraint check timing for the current transaction
SET ROLE -- set the current user identifier of the current session
SET SESSION AUTHORIZATION -- set the session user identifier and the current user identifier of the current session
SET TRANSACTION -- set the characteristics of the current transaction
SHOW -- show the value of a run-time parameter
START TRANSACTION -- start a transaction block
TRUNCATE -- empty a table or set of tables
UNLISTEN -- stop listening for a notification
UPDATE -- update rows of a table
VACUUM -- garbage-collect and optionally analyze a database
VALUES -- compute a set of rows

PrevHomeNext
ReferenceUpABORT
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-comment.html b/doc/src/sgml/html/sql-comment.html new file mode 100644 index 000000000..4314771b4 --- /dev/null +++ b/doc/src/sgml/html/sql-comment.html @@ -0,0 +1,866 @@ + +COMMENT

COMMENT

Name

COMMENT -- define or change the comment of an object

Synopsis

COMMENT ON
+{
+  AGGREGATE agg_name (agg_type [, ...] ) |
+  CAST (source_type AS target_type) |
+  COLLATION object_name |
+  COLUMN relation_name.column_name |
+  CONSTRAINT constraint_name ON table_name |
+  CONVERSION object_name |
+  DATABASE object_name |
+  DOMAIN object_name |
+  EXTENSION object_name |
+  FOREIGN DATA WRAPPER object_name |
+  FOREIGN TABLE object_name |
+  FUNCTION function_name ( [ [ argmode ] [ argname ] argtype [, ...] ] ) |
+  INDEX object_name |
+  LARGE OBJECT large_object_oid |
+  OPERATOR operator_name (left_type, right_type) |
+  OPERATOR CLASS object_name USING index_method |
+  OPERATOR FAMILY object_name USING index_method |
+  [ PROCEDURAL ] LANGUAGE object_name |
+  ROLE object_name |
+  RULE rule_name ON table_name |
+  SCHEMA object_name |
+  SEQUENCE object_name |
+  SERVER object_name |
+  TABLE object_name |
+  TABLESPACE object_name |
+  TEXT SEARCH CONFIGURATION object_name |
+  TEXT SEARCH DICTIONARY object_name |
+  TEXT SEARCH PARSER object_name |
+  TEXT SEARCH TEMPLATE object_name |
+  TRIGGER trigger_name ON table_name |
+  TYPE object_name |
+  VIEW object_name
+} IS 'text'

Description

COMMENT stores a comment about a database object. +

Only one comment string is stored for each object, so to modify a comment, + issue a new COMMENT command for the same object. To remove a + comment, write NULL in place of the text string. + Comments are automatically dropped when their object is dropped. +

For most kinds of object, only the object's owner can set the comment. + Roles don't have owners, so the rule for COMMENT ON ROLE is + that you must be superuser to comment on a superuser role, or have the + CREATEROLE privilege to comment on non-superuser roles. + Of course, a superuser can comment on anything. +

Comments can be viewed using psql's + \d family of commands. + Other user interfaces to retrieve comments can be built atop + the same built-in functions that psql uses, namely + obj_description, col_description, + and shobj_description + (see Table 9-54). +

Parameters

object_name
relation_name.column_name
agg_name
constraint_name
function_name
operator_name
rule_name
trigger_name

The name of the object to be commented. Names of tables, + aggregates, collations, conversions, domains, foreign tables, functions, + indexes, operators, operator classes, operator families, sequences, + text search objects, types, and views can be schema-qualified. + When commenting on a column, + relation_name must refer + to a table, view, composite type, or foreign table. +

agg_type

An input data type on which the aggregate function operates. + To reference a zero-argument aggregate function, write * + in place of the list of input data types. +

source_type

The name of the source data type of the cast. +

target_type

The name of the target data type of the cast. +

argmode

The mode of a function argument: IN, OUT, + INOUT, or VARIADIC. + If omitted, the default is IN. + Note that COMMENT ON FUNCTION does not actually pay + any attention to OUT arguments, since only the input + arguments are needed to determine the function's identity. + So it is sufficient to list the IN, INOUT, + and VARIADIC arguments. +

argname

The name of a function argument. + Note that COMMENT ON FUNCTION does not actually pay + any attention to argument names, since only the argument data + types are needed to determine the function's identity. +

argtype

The data type(s) of the function's arguments (optionally + schema-qualified), if any. +

large_object_oid

The OID of the large object. +

left_type
right_type

The data type(s) of the operator's arguments (optionally + schema-qualified). Write NONE for the missing argument + of a prefix or postfix operator. +

PROCEDURAL

This is a noise word. +

text

The new comment, written as a string literal; or NULL + to drop the comment. +

Notes

There is presently no security mechanism for viewing comments: any user + connected to a database can see all the comments for objects in + that database. For shared objects such as + databases, roles, and tablespaces, comments are stored globally so any + user connected to any database in the cluster can see all the comments + for shared objects. Therefore, don't put security-critical + information in comments. +

Examples

Attach a comment to the table mytable: + +

COMMENT ON TABLE mytable IS 'This is my table.';

+ + Remove it again: + +

COMMENT ON TABLE mytable IS NULL;

+

Some more examples: + +

COMMENT ON AGGREGATE my_aggregate (double precision) IS 'Computes sample variance';
+COMMENT ON CAST (text AS int4) IS 'Allow casts from text to int4';
+COMMENT ON COLLATION "fr_CA" IS 'Canadian French';
+COMMENT ON COLUMN my_table.my_column IS 'Employee ID number';
+COMMENT ON CONVERSION my_conv IS 'Conversion to UTF8';
+COMMENT ON CONSTRAINT bar_col_cons ON bar IS 'Constrains column col';
+COMMENT ON DATABASE my_database IS 'Development Database';
+COMMENT ON DOMAIN my_domain IS 'Email Address Domain';
+COMMENT ON EXTENSION hstore IS 'implements the hstore data type';
+COMMENT ON FOREIGN DATA WRAPPER mywrapper IS 'my foreign data wrapper';
+COMMENT ON FOREIGN TABLE my_foreign_table IS 'Employee Information in other database';
+COMMENT ON FUNCTION my_function (timestamp) IS 'Returns Roman Numeral';
+COMMENT ON INDEX my_index IS 'Enforces uniqueness on employee ID';
+COMMENT ON LANGUAGE plpython IS 'Python support for stored procedures';
+COMMENT ON LARGE OBJECT 346344 IS 'Planning document';
+COMMENT ON OPERATOR ^ (text, text) IS 'Performs intersection of two texts';
+COMMENT ON OPERATOR - (NONE, integer) IS 'Unary minus';
+COMMENT ON OPERATOR CLASS int4ops USING btree IS '4 byte integer operators for btrees';
+COMMENT ON OPERATOR FAMILY integer_ops USING btree IS 'all integer operators for btrees';
+COMMENT ON ROLE my_role IS 'Administration group for finance tables';
+COMMENT ON RULE my_rule ON my_table IS 'Logs updates of employee records';
+COMMENT ON SCHEMA my_schema IS 'Departmental data';
+COMMENT ON SEQUENCE my_sequence IS 'Used to generate primary keys';
+COMMENT ON SERVER myserver IS 'my foreign server';
+COMMENT ON TABLE my_schema.my_table IS 'Employee Information';
+COMMENT ON TABLESPACE my_tablespace IS 'Tablespace for indexes';
+COMMENT ON TEXT SEARCH CONFIGURATION my_config IS 'Special word filtering';
+COMMENT ON TEXT SEARCH DICTIONARY swedish IS 'Snowball stemmer for swedish language';
+COMMENT ON TEXT SEARCH PARSER my_parser IS 'Splits text into words';
+COMMENT ON TEXT SEARCH TEMPLATE snowball IS 'Snowball stemmer';
+COMMENT ON TRIGGER my_trigger ON my_table IS 'Used for RI';
+COMMENT ON TYPE complex IS 'Complex number data type';
+COMMENT ON VIEW my_view IS 'View of departmental costs';

Compatibility

There is no COMMENT command in the SQL standard. +


PrevHomeNext
CLUSTERUpCOMMIT
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-commit-prepared.html b/doc/src/sgml/html/sql-commit-prepared.html new file mode 100644 index 000000000..6afa76156 --- /dev/null +++ b/doc/src/sgml/html/sql-commit-prepared.html @@ -0,0 +1,308 @@ + +COMMIT PREPARED

COMMIT PREPARED

Name

COMMIT PREPARED -- commit a transaction that was earlier prepared for two-phase commit

Synopsis

COMMIT PREPARED transaction_id

Description

COMMIT PREPARED commits a transaction that is in + prepared state. +

Parameters

transaction_id

The transaction identifier of the transaction that is to be + committed. +

Notes

To commit a prepared transaction, you must be either the same user that + executed the transaction originally, or a superuser. But you do not + have to be in the same session that executed the transaction. +

This command cannot be executed inside a transaction block. The prepared + transaction is committed immediately. +

All currently available prepared transactions are listed in the + pg_prepared_xacts + system view. +

Examples

Commit the transaction identified by the transaction + identifier foobar: + +

COMMIT PREPARED 'foobar';

Compatibility

COMMIT PREPARED is a + PostgreSQL extension. It is intended for use by + external transaction management systems, some of which are covered by + standards (such as X/Open XA), but the SQL side of those systems is not + standardized. +


PrevHomeNext
COMMITUpCOPY
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-commit.html b/doc/src/sgml/html/sql-commit.html new file mode 100644 index 000000000..4638929a0 --- /dev/null +++ b/doc/src/sgml/html/sql-commit.html @@ -0,0 +1,291 @@ + +COMMIT

COMMIT

Name

COMMIT -- commit the current transaction

Synopsis

COMMIT [ WORK | TRANSACTION ]

Description

COMMIT commits the current transaction. All + changes made by the transaction become visible to others + and are guaranteed to be durable if a crash occurs. +

Parameters

WORK
TRANSACTION

Optional key words. They have no effect. +

Notes

Use ROLLBACK to + abort a transaction. +

Issuing COMMIT when not inside a transaction does + no harm, but it will provoke a warning message. +

Examples

To commit the current transaction and make all changes permanent: +

COMMIT;

Compatibility

The SQL standard only specifies the two forms + COMMIT and COMMIT + WORK. Otherwise, this command is fully conforming. +

See Also

BEGIN, ROLLBACK

PrevHomeNext
COMMENTUpCOMMIT PREPARED
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-copy.html b/doc/src/sgml/html/sql-copy.html new file mode 100644 index 000000000..7bc719b96 --- /dev/null +++ b/doc/src/sgml/html/sql-copy.html @@ -0,0 +1,2024 @@ + +COPY

COPY

Name

COPY -- copy data between a file and a table

Synopsis

COPY table_name [ ( column_name [, ...] ) ]
+    FROM { 'filename' | STDIN }
+    [ [ WITH ] ( option [, ...] ) ]
+
+COPY { table_name [ ( column_name [, ...] ) ] | ( query ) }
+    TO { 'filename' | STDOUT }
+    [ [ WITH ] ( option [, ...] ) ]
+
+where option can be one of:
+
+    FORMAT format_name
+    OIDS [ boolean ]
+    DELIMITER 'delimiter_character'
+    NULL 'null_string'
+    HEADER [ boolean ]
+    QUOTE 'quote_character'
+    ESCAPE 'escape_character'
+    FORCE_QUOTE { ( column_name [, ...] ) | * }
+    FORCE_NOT_NULL ( column_name [, ...] ) |
+    ENCODING 'encoding_name'

Description

COPY moves data between + PostgreSQL tables and standard file-system + files. COPY TO copies the contents of a table + to a file, while COPY FROM copies + data from a file to a table (appending the data to + whatever is in the table already). COPY TO + can also copy the results of a SELECT query. +

If a list of columns is specified, COPY will + only copy the data in the specified columns to or from the file. + If there are any columns in the table that are not in the column list, + COPY FROM will insert the default values for + those columns. +

COPY with a file name instructs the + PostgreSQL server to directly read from + or write to a file. The file must be accessible to the server and + the name must be specified from the viewpoint of the server. When + STDIN or STDOUT is + specified, data is transmitted via the connection between the + client and the server. +

Parameters

table_name

The name (optionally schema-qualified) of an existing table. +

column_name

An optional list of columns to be copied. If no column list is + specified, all columns of the table will be copied. +

query

A SELECT or + VALUES command + whose results are to be copied. + Note that parentheses are required around the query. +

filename

The absolute path name of the input or output file. Windows users + might need to use an E'' string and double any backslashes + used in the path name. +

STDIN

Specifies that input comes from the client application. +

STDOUT

Specifies that output goes to the client application. +

boolean

Specifies whether the selected option should be turned on or off. + You can write TRUE, ON, or + 1 to enable the option, and FALSE, + OFF, or 0 to disable it. The + boolean value can also + be omitted, in which case TRUE is assumed. +

FORMAT

Selects the data format to be read or written: + text, + csv (Comma Separated Values), + or binary. + The default is text. +

OIDS

Specifies copying the OID for each row. (An error is raised if + OIDS is specified for a table that does not + have OIDs, or in the case of copying a query.) +

DELIMITER

Specifies the character that separates columns within each row + (line) of the file. The default is a tab character in text format, + a comma in CSV format. + This must be a single one-byte character. + This option is not allowed when using binary format. +

NULL

Specifies the string that represents a null value. The default is + \N (backslash-N) in text format, and an unquoted empty + string in CSV format. You might prefer an + empty string even in text format for cases where you don't want to + distinguish nulls from empty strings. + This option is not allowed when using binary format. +

Note: When using COPY FROM, any data item that matches + this string will be stored as a null value, so you should make + sure that you use the same string as you used with + COPY TO. +

HEADER

Specifies that the file contains a header line with the names of each + column in the file. On output, the first line contains the column + names from the table, and on input, the first line is ignored. + This option is allowed only when using CSV format. +

QUOTE

Specifies the quoting character to be used when a data value is quoted. + The default is double-quote. + This must be a single one-byte character. + This option is allowed only when using CSV format. +

ESCAPE

Specifies the character that should appear before a + data character that matches the QUOTE value. + The default is the same as the QUOTE value (so that + the quoting character is doubled if it appears in the data). + This must be a single one-byte character. + This option is allowed only when using CSV format. +

FORCE_QUOTE

Forces quoting to be + used for all non-NULL values in each specified column. + NULL output is never quoted. If * is specified, + non-NULL values will be quoted in all columns. + This option is allowed only in COPY TO, and only when + using CSV format. +

FORCE_NOT_NULL

Do not match the specified columns' values against the null string. + In the default case where the null string is empty, this means that + empty values will be read as zero-length strings rather than nulls, + even when they are not quoted. + This option is allowed only in COPY FROM, and only when + using CSV format. +

ENCODING

Specifies that the file is encoded in the encoding_name. If this option is + omitted, the current client encoding is used. See the Notes below + for more details. +

Outputs

On successful completion, a COPY command returns a command + tag of the form +

COPY count

+ The count is the number + of rows copied. +

Notes

COPY can only be used with plain tables, not + with views. However, you can write COPY (SELECT * FROM + viewname) TO .... +

COPY only deals with the specific table named; + it does not copy data to or from child tables. Thus for example + COPY table TO + shows the same data as SELECT * FROM ONLY table. But COPY + (SELECT * FROM table) TO ... + can be used to dump all of the data in an inheritance hierarchy. +

You must have select privilege on the table + whose values are read by COPY TO, and + insert privilege on the table into which values + are inserted by COPY FROM. It is sufficient + to have column privileges on the column(s) listed in the command. +

Files named in a COPY command are read or written + directly by the server, not by the client application. Therefore, + they must reside on or be accessible to the database server machine, + not the client. They must be accessible to and readable or writable + by the PostgreSQL user (the user ID the + server runs as), not the client. COPY naming a + file is only allowed to database superusers, since it allows reading + or writing any file that the server has privileges to access. +

Do not confuse COPY with the + psql instruction + \copy. \copy invokes + COPY FROM STDIN or COPY TO + STDOUT, and then fetches/stores the data in a file + accessible to the psql client. Thus, + file accessibility and access rights depend on the client rather + than the server when \copy is used. +

It is recommended that the file name used in COPY + always be specified as an absolute path. This is enforced by the + server in the case of COPY TO, but for + COPY FROM you do have the option of reading from + a file specified by a relative path. The path will be interpreted + relative to the working directory of the server process (normally + the cluster's data directory), not the client's working directory. +

COPY FROM will invoke any triggers and check + constraints on the destination table. However, it will not invoke rules. +

COPY input and output is affected by + DateStyle. To ensure portability to other + PostgreSQL installations that might use + non-default DateStyle settings, + DateStyle should be set to ISO before + using COPY TO. It is also a good idea to avoid dumping + data with IntervalStyle set to + sql_standard, because negative interval values might be + misinterpreted by a server that has a different setting for + IntervalStyle. +

Input data is interpreted according to ENCODING + option or the current client encoding, and output data is encoded + in ENCODING or the current client encoding, even + if the data does not pass through the client but is read from or + written to a file directly by the server. +

COPY stops operation at the first error. This + should not lead to problems in the event of a COPY + TO, but the target table will already have received + earlier rows in a COPY FROM. These rows will not + be visible or accessible, but they still occupy disk space. This might + amount to a considerable amount of wasted disk space if the failure + happened well into a large copy operation. You might wish to invoke + VACUUM to recover the wasted space. +

File Formats

Text Format

When the text format is used, + the data read or written is a text file with one line per table row. + Columns in a row are separated by the delimiter character. + The column values themselves are strings generated by the + output function, or acceptable to the input function, of each + attribute's data type. The specified null string is used in + place of columns that are null. + COPY FROM will raise an error if any line of the + input file contains more or fewer columns than are expected. + If OIDS is specified, the OID is read or written as the first column, + preceding the user data columns. +

End of data can be represented by a single line containing just + backslash-period (\.). An end-of-data marker is + not necessary when reading from a file, since the end of file + serves perfectly well; it is needed only when copying data to or from + client applications using pre-3.0 client protocol. +

Backslash characters (\) can be used in the + COPY data to quote data characters that might + otherwise be taken as row or column delimiters. In particular, the + following characters must be preceded by a backslash if + they appear as part of a column value: backslash itself, + newline, carriage return, and the current delimiter character. +

The specified null string is sent by COPY TO without + adding any backslashes; conversely, COPY FROM matches + the input against the null string before removing backslashes. Therefore, + a null string such as \N cannot be confused with + the actual data value \N (which would be represented + as \\N). +

The following special backslash sequences are recognized by + COPY FROM: + +

SequenceRepresents
\bBackspace (ASCII 8)
\fForm feed (ASCII 12)
\nNewline (ASCII 10)
\rCarriage return (ASCII 13)
\tTab (ASCII 9)
\vVertical tab (ASCII 11)
\digitsBackslash followed by one to three octal digits specifies + the character with that numeric code
\xdigitsBackslash x followed by one or two hex digits specifies + the character with that numeric code

+ + Presently, COPY TO will never emit an octal or + hex-digits backslash sequence, but it does use the other sequences + listed above for those control characters. +

Any other backslashed character that is not mentioned in the above table + will be taken to represent itself. However, beware of adding backslashes + unnecessarily, since that might accidentally produce a string matching the + end-of-data marker (\.) or the null string (\N by + default). These strings will be recognized before any other backslash + processing is done. +

It is strongly recommended that applications generating COPY data convert + data newlines and carriage returns to the \n and + \r sequences respectively. At present it is + possible to represent a data carriage return by a backslash and carriage + return, and to represent a data newline by a backslash and newline. + However, these representations might not be accepted in future releases. + They are also highly vulnerable to corruption if the COPY file is + transferred across different machines (for example, from Unix to Windows + or vice versa). +

COPY TO will terminate each row with a Unix-style + newline ("\n"). Servers running on Microsoft Windows instead + output carriage return/newline ("\r\n"), but only for + COPY to a server file; for consistency across platforms, + COPY TO STDOUT always sends "\n" + regardless of server platform. + COPY FROM can handle lines ending with newlines, + carriage returns, or carriage return/newlines. To reduce the risk of + error due to un-backslashed newlines or carriage returns that were + meant as data, COPY FROM will complain if the line + endings in the input are not all alike. +

CSV Format

This format option is used for importing and exporting the Comma + Separated Value (CSV) file format used by many other + programs, such as spreadsheets. Instead of the escaping rules used by + PostgreSQL's standard text format, it + produces and recognizes the common CSV escaping mechanism. +

The values in each record are separated by the DELIMITER + character. If the value contains the delimiter character, the + QUOTE character, the NULL string, a carriage + return, or line feed character, then the whole value is prefixed and + suffixed by the QUOTE character, and any occurrence + within the value of a QUOTE character or the + ESCAPE character is preceded by the escape character. + You can also use FORCE_QUOTE to force quotes when outputting + non-NULL values in specific columns. +

The CSV format has no standard way to distinguish a + NULL value from an empty string. + PostgreSQL's COPY handles this by quoting. + A NULL is output as the NULL parameter string + and is not quoted, while a non-NULL value matching the + NULL parameter string is quoted. For example, with the + default settings, a NULL is written as an unquoted empty + string, while an empty string data value is written with double quotes + (""). Reading values follows similar rules. You can + use FORCE_NOT_NULL to prevent NULL input + comparisons for specific columns. +

Because backslash is not a special character in the CSV + format, \., the end-of-data marker, could also appear + as a data value. To avoid any misinterpretation, a \. + data value appearing as a lone entry on a line is automatically + quoted on output, and on input, if quoted, is not interpreted as the + end-of-data marker. If you are loading a file created by another + application that has a single unquoted column and might have a + value of \., you might need to quote that value in the + input file. +

Note: In CSV format, all characters are significant. A quoted value + surrounded by white space, or any characters other than + DELIMITER, will include those characters. This can cause + errors if you import data from a system that pads CSV + lines with white space out to some fixed width. If such a situation + arises you might need to preprocess the CSV file to remove + the trailing white space, before importing the data into + PostgreSQL. +

Note: CSV format will both recognize and produce CSV files with quoted + values containing embedded carriage returns and line feeds. Thus + the files are not strictly one line per table row like text-format + files. +

Note: Many programs produce strange and occasionally perverse CSV files, + so the file format is more a convention than a standard. Thus you + might encounter some files that cannot be imported using this + mechanism, and COPY might produce files that other + programs cannot process. +

Binary Format

The binary format option causes all data to be + stored/read as binary format rather than as text. It is + somewhat faster than the text and CSV formats, + but a binary-format file is less portable across machine architectures and + PostgreSQL versions. + Also, the binary format is very data type specific; for example + it will not work to output binary data from a smallint column + and read it into an integer column, even though that would work + fine in text format. +

The binary file format consists + of a file header, zero or more tuples containing the row data, and + a file trailer. Headers and data are in network byte order. +

Note: PostgreSQL releases before 7.4 used a + different binary file format. +

File Header

The file header consists of 15 bytes of fixed fields, followed + by a variable-length header extension area. The fixed fields are: + +

Signature

11-byte sequence PGCOPY\n\377\r\n\0 — note that the zero byte +is a required part of the signature. (The signature is designed to allow +easy identification of files that have been munged by a non-8-bit-clean +transfer. This signature will be changed by end-of-line-translation +filters, dropped zero bytes, dropped high bits, or parity changes.) +

Flags field

32-bit integer bit mask to denote important aspects of the file format. Bits +are numbered from 0 (LSB) to 31 (MSB). Note that +this field is stored in network byte order (most significant byte first), +as are all the integer fields used in the file format. Bits +16-31 are reserved to denote critical file format issues; a reader +should abort if it finds an unexpected bit set in this range. Bits 0-15 +are reserved to signal backwards-compatible format issues; a reader +should simply ignore any unexpected bits set in this range. Currently +only one flag bit is defined, and the rest must be zero: +

Bit 16

if 1, OIDs are included in the data; if 0, not +

Header extension area length

32-bit integer, length in bytes of remainder of header, not including self. +Currently, this is zero, and the first tuple follows +immediately. Future changes to the format might allow additional data +to be present in the header. A reader should silently skip over any header +extension data it does not know what to do with. +

+

The header extension area is envisioned to contain a sequence of +self-identifying chunks. The flags field is not intended to tell readers +what is in the extension area. Specific design of header extension contents +is left for a later release. +

This design allows for both backwards-compatible header additions (add + header extension chunks, or set low-order flag bits) and + non-backwards-compatible changes (set high-order flag bits to signal such + changes, and add supporting data to the extension area if needed). +

Tuples

Each tuple begins with a 16-bit integer count of the number of fields in the +tuple. (Presently, all tuples in a table will have the same count, but that +might not always be true.) Then, repeated for each field in the tuple, there +is a 32-bit length word followed by that many bytes of field data. (The +length word does not include itself, and can be zero.) As a special case, +-1 indicates a NULL field value. No value bytes follow in the NULL case. +

There is no alignment padding or any other extra data between fields. +

Presently, all data values in a binary-format file are +assumed to be in binary format (format code one). It is anticipated that a +future extension might add a header field that allows per-column format codes +to be specified. +

To determine the appropriate binary format for the actual tuple data you +should consult the PostgreSQL source, in +particular the *send and *recv functions for +each column's data type (typically these functions are found in the +src/backend/utils/adt/ directory of the source +distribution). +

If OIDs are included in the file, the OID field immediately follows the +field-count word. It is a normal field except that it's not included +in the field-count. In particular it has a length word — this will allow +handling of 4-byte vs. 8-byte OIDs without too much pain, and will allow +OIDs to be shown as null if that ever proves desirable. +

File Trailer

The file trailer consists of a 16-bit integer word containing -1. This + is easily distinguished from a tuple's field-count word. +

A reader should report an error if a field-count word is neither -1 + nor the expected number of columns. This provides an extra + check against somehow getting out of sync with the data. +

Examples

The following example copies a table to the client + using the vertical bar (|) as the field delimiter: +

COPY country TO STDOUT (DELIMITER '|');

+

To copy data from a file into the country table: +

COPY country FROM '/usr1/proj/bray/sql/country_data';

+

To copy into a file just the countries whose names start with 'A': +

COPY (SELECT * FROM country WHERE country_name LIKE 'A%') TO '/usr1/proj/bray/sql/a_list_countries.copy';

+

Here is a sample of data suitable for copying into a table from + STDIN: +

AF      AFGHANISTAN
+AL      ALBANIA
+DZ      ALGERIA
+ZM      ZAMBIA
+ZW      ZIMBABWE

+ Note that the white space on each line is actually a tab character. +

The following is the same data, output in binary format. + The data is shown after filtering through the + Unix utility od -c. The table has three columns; + the first has type char(2), the second has type text, + and the third has type integer. All the rows have a null value + in the third column. +

0000000   P   G   C   O   P   Y  \n 377  \r  \n  \0  \0  \0  \0  \0  \0
+0000020  \0  \0  \0  \0 003  \0  \0  \0 002   A   F  \0  \0  \0 013   A
+0000040   F   G   H   A   N   I   S   T   A   N 377 377 377 377  \0 003
+0000060  \0  \0  \0 002   A   L  \0  \0  \0 007   A   L   B   A   N   I
+0000100   A 377 377 377 377  \0 003  \0  \0  \0 002   D   Z  \0  \0  \0
+0000120 007   A   L   G   E   R   I   A 377 377 377 377  \0 003  \0  \0
+0000140  \0 002   Z   M  \0  \0  \0 006   Z   A   M   B   I   A 377 377
+0000160 377 377  \0 003  \0  \0  \0 002   Z   W  \0  \0  \0  \b   Z   I
+0000200   M   B   A   B   W   E 377 377 377 377 377 377

Compatibility

There is no COPY statement in the SQL standard. +

The following syntax was used before PostgreSQL + version 9.0 and is still supported: + +

COPY table_name [ ( column_name [, ...] ) ]
+    FROM { 'filename' | STDIN }
+    [ [ WITH ]
+          [ BINARY ]
+          [ OIDS ]
+          [ DELIMITER [ AS ] 'delimiter' ]
+          [ NULL [ AS ] 'null string' ]
+          [ CSV [ HEADER ]
+                [ QUOTE [ AS ] 'quote' ]
+                [ ESCAPE [ AS ] 'escape' ]
+                [ FORCE NOT NULL column_name [, ...] ] ] ]
+
+COPY { table_name [ ( column_name [, ...] ) ] | ( query ) }
+    TO { 'filename' | STDOUT }
+    [ [ WITH ]
+          [ BINARY ]
+          [ OIDS ]
+          [ DELIMITER [ AS ] 'delimiter' ]
+          [ NULL [ AS ] 'null string' ]
+          [ CSV [ HEADER ]
+                [ QUOTE [ AS ] 'quote' ]
+                [ ESCAPE [ AS ] 'escape' ]
+                [ FORCE QUOTE { column_name [, ...] | * } ] ] ]

+ + Note that in this syntax, BINARY and CSV are + treated as independent keywords, not as arguments of a FORMAT + option. +

The following syntax was used before PostgreSQL + version 7.3 and is still supported: + +

COPY [ BINARY ] table_name [ WITH OIDS ]
+    FROM { 'filename' | STDIN }
+    [ [USING] DELIMITERS 'delimiter' ]
+    [ WITH NULL AS 'null string' ]
+
+COPY [ BINARY ] table_name [ WITH OIDS ]
+    TO { 'filename' | STDOUT }
+    [ [USING] DELIMITERS 'delimiter' ]
+    [ WITH NULL AS 'null string' ]


PrevHomeNext
COMMIT PREPAREDUpCREATE AGGREGATE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createaggregate.html b/doc/src/sgml/html/sql-createaggregate.html new file mode 100644 index 000000000..c3f48e800 --- /dev/null +++ b/doc/src/sgml/html/sql-createaggregate.html @@ -0,0 +1,760 @@ + +CREATE AGGREGATE

CREATE AGGREGATE

Name

CREATE AGGREGATE -- define a new aggregate function

Synopsis

CREATE AGGREGATE name ( input_data_type [ , ... ] ) (
+    SFUNC = sfunc,
+    STYPE = state_data_type
+    [ , FINALFUNC = ffunc ]
+    [ , INITCOND = initial_condition ]
+    [ , SORTOP = sort_operator ]
+)
+
+or the old syntax
+
+CREATE AGGREGATE name (
+    BASETYPE = base_type,
+    SFUNC = sfunc,
+    STYPE = state_data_type
+    [ , FINALFUNC = ffunc ]
+    [ , INITCOND = initial_condition ]
+    [ , SORTOP = sort_operator ]
+)

Description

CREATE AGGREGATE defines a new aggregate + function. Some basic and commonly-used aggregate functions are + included with the distribution; they are documented in Section 9.20. If one defines new types or needs + an aggregate function not already provided, then CREATE + AGGREGATE can be used to provide the desired features. +

If a schema name is given (for example, CREATE AGGREGATE + myschema.myagg ...) then the aggregate function is created in the + specified schema. Otherwise it is created in the current schema. +

An aggregate function is identified by its name and input data type(s). + Two aggregates in the same schema can have the same name if they operate on + different input types. The + name and input data type(s) of an aggregate must also be distinct from + the name and input data type(s) of every ordinary function in the same + schema. +

An aggregate function is made from one or two ordinary + functions: + a state transition function + sfunc, + and an optional final calculation function + ffunc. + These are used as follows: +

sfunc( internal-state, next-data-values ) ---> next-internal-state
+ffunc( internal-state ) ---> aggregate-value

+

PostgreSQL creates a temporary variable + of data type stype + to hold the current internal state of the aggregate. At each input row, + the aggregate argument value(s) are calculated and + the state transition function is invoked with the current state value + and the new argument value(s) to calculate a new + internal state value. After all the rows have been processed, + the final function is invoked once to calculate the aggregate's return + value. If there is no final function then the ending state value + is returned as-is. +

An aggregate function can provide an initial condition, + that is, an initial value for the internal state value. + This is specified and stored in the database as a value of type + text, but it must be a valid external representation + of a constant of the state value data type. If it is not supplied + then the state value starts out null. +

If the state transition function is declared "strict", + then it cannot be called with null inputs. With such a transition + function, aggregate execution behaves as follows. Rows with any null input + values are ignored (the function is not called and the previous state value + is retained). If the initial state value is null, then at the first row + with all-nonnull input values, the first argument value replaces the state + value, and the transition function is invoked at subsequent rows with + all-nonnull input values. + This is handy for implementing aggregates like max. + Note that this behavior is only available when + state_data_type + is the same as the first + input_data_type. + When these types are different, you must supply a nonnull initial + condition or use a nonstrict transition function. +

If the state transition function is not strict, then it will be called + unconditionally at each input row, and must deal with null inputs + and null transition values for itself. This allows the aggregate + author to have full control over the aggregate's handling of null values. +

If the final function is declared "strict", then it will not + be called when the ending state value is null; instead a null result + will be returned automatically. (Of course this is just the normal + behavior of strict functions.) In any case the final function has + the option of returning a null value. For example, the final function for + avg returns null when it sees there were zero + input rows. +

Aggregates that behave like MIN or MAX can + sometimes be optimized by looking into an index instead of scanning every + input row. If this aggregate can be so optimized, indicate it by + specifying a sort operator. The basic requirement is that + the aggregate must yield the first element in the sort ordering induced by + the operator; in other words: +

SELECT agg(col) FROM tab;

+ must be equivalent to: +

SELECT col FROM tab ORDER BY col USING sortop LIMIT 1;

+ Further assumptions are that the aggregate ignores null inputs, and that + it delivers a null result if and only if there were no non-null inputs. + Ordinarily, a data type's < operator is the proper sort + operator for MIN, and > is the proper sort + operator for MAX. Note that the optimization will never + actually take effect unless the specified operator is the "less + than" or "greater than" strategy member of a B-tree + index operator class. +

To be able to create an aggregate function, you must + have USAGE privilege on the argument types, the state + type, and the return type, as well as EXECUTE privilege + on the transition and final functions. +

Parameters

name

The name (optionally schema-qualified) of the aggregate function + to create. +

input_data_type

An input data type on which this aggregate function operates. + To create a zero-argument aggregate function, write * + in place of the list of input data types. (An example of such an + aggregate is count(*).) +

base_type

In the old syntax for CREATE AGGREGATE, the input data type + is specified by a basetype parameter rather than being + written next to the aggregate name. Note that this syntax allows + only one input parameter. To define a zero-argument aggregate function, + specify the basetype as + "ANY" (not *). +

sfunc

The name of the state transition function to be called for each + input row. For an N-argument + aggregate function, the sfunc + must take N+1 arguments, + the first being of type state_data_type and the rest + matching the declared input data type(s) of the aggregate. + The function must return a value of type state_data_type. This function + takes the current state value and the current input data value(s), + and returns the next state value. +

state_data_type

The data type for the aggregate's state value. +

ffunc

The name of the final function called to compute the aggregate's + result after all input rows have been traversed. The function + must take a single argument of type state_data_type. The return + data type of the aggregate is defined as the return type of this + function. If ffunc + is not specified, then the ending state value is used as the + aggregate's result, and the return type is state_data_type. +

initial_condition

The initial setting for the state value. This must be a string + constant in the form accepted for the data type state_data_type. If not + specified, the state value starts out null. +

sort_operator

The associated sort operator for a MIN- or + MAX-like aggregate. + This is just an operator name (possibly schema-qualified). + The operator is assumed to have the same input data types as + the aggregate (which must be a single-argument aggregate). +

The parameters of CREATE AGGREGATE can be + written in any order, not just the order illustrated above. +

Examples

See Section 35.10. +

Compatibility

CREATE AGGREGATE is a + PostgreSQL language extension. The SQL + standard does not provide for user-defined aggregate functions. +


PrevHomeNext
COPYUpCREATE CAST
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createcast.html b/doc/src/sgml/html/sql-createcast.html new file mode 100644 index 000000000..7247d3bc8 --- /dev/null +++ b/doc/src/sgml/html/sql-createcast.html @@ -0,0 +1,954 @@ + +CREATE CAST

CREATE CAST

Name

CREATE CAST -- define a new cast

Synopsis

CREATE CAST (source_type AS target_type)
+    WITH FUNCTION function_name (argument_type [, ...])
+    [ AS ASSIGNMENT | AS IMPLICIT ]
+
+CREATE CAST (source_type AS target_type)
+    WITHOUT FUNCTION
+    [ AS ASSIGNMENT | AS IMPLICIT ]
+
+CREATE CAST (source_type AS target_type)
+    WITH INOUT
+    [ AS ASSIGNMENT | AS IMPLICIT ]

Description

CREATE CAST defines a new cast. A cast + specifies how to perform a conversion between + two data types. For example, +

SELECT CAST(42 AS float8);

+ converts the integer constant 42 to type float8 by + invoking a previously specified function, in this case + float8(int4). (If no suitable cast has been defined, the + conversion fails.) +

Two types can be binary coercible, which + means that the conversion can be performed "for free" + without invoking any function. This requires that corresponding + values use the same internal representation. For instance, the + types text and varchar are binary + coercible both ways. Binary coercibility is not necessarily a + symmetric relationship. For example, the cast + from xml to text can be performed for + free in the present implementation, but the reverse direction + requires a function that performs at least a syntax check. (Two + types that are binary coercible both ways are also referred to as + binary compatible.) +

You can define a cast as an I/O conversion cast by using + the WITH INOUT syntax. An I/O conversion cast is + performed by invoking the output function of the source data type, and + passing the resulting string to the input function of the target data type. + In many common cases, this feature avoids the need to write a separate + cast function for conversion. An I/O conversion cast acts the same as + a regular function-based cast; only the implementation is different. +

By default, a cast can be invoked only by an explicit cast request, + that is an explicit CAST(x AS + typename) or + x::typename + construct. +

If the cast is marked AS ASSIGNMENT then it can be invoked + implicitly when assigning a value to a column of the target data type. + For example, supposing that foo.f1 is a column of + type text, then: +

INSERT INTO foo (f1) VALUES (42);

+ will be allowed if the cast from type integer to type + text is marked AS ASSIGNMENT, otherwise not. + (We generally use the term assignment + cast to describe this kind of cast.) +

If the cast is marked AS IMPLICIT then it can be invoked + implicitly in any context, whether assignment or internally in an + expression. (We generally use the term implicit + cast to describe this kind of cast.) + For example, consider this query: +

SELECT 2 + 4.0;

+ The parser initially marks the constants as being of type integer + and numeric respectively. There is no integer + + numeric operator in the system catalogs, + but there is a numeric + numeric operator. + The query will therefore succeed if a cast from integer to + numeric is available and is marked AS IMPLICIT — + which in fact it is. The parser will apply the implicit cast and resolve + the query as if it had been written +

SELECT CAST ( 2 AS numeric ) + 4.0;

+

Now, the catalogs also provide a cast from numeric to + integer. If that cast were marked AS IMPLICIT — + which it is not — then the parser would be faced with choosing + between the above interpretation and the alternative of casting the + numeric constant to integer and applying the + integer + integer operator. Lacking any + knowledge of which choice to prefer, it would give up and declare the + query ambiguous. The fact that only one of the two casts is + implicit is the way in which we teach the parser to prefer resolution + of a mixed numeric-and-integer expression as + numeric; there is no built-in knowledge about that. +

It is wise to be conservative about marking casts as implicit. An + overabundance of implicit casting paths can cause + PostgreSQL to choose surprising + interpretations of commands, or to be unable to resolve commands at + all because there are multiple possible interpretations. A good + rule of thumb is to make a cast implicitly invokable only for + information-preserving transformations between types in the same + general type category. For example, the cast from int2 to + int4 can reasonably be implicit, but the cast from + float8 to int4 should probably be + assignment-only. Cross-type-category casts, such as text + to int4, are best made explicit-only. +

Note: Sometimes it is necessary for usability or standards-compliance reasons + to provide multiple implicit casts among a set of types, resulting in + ambiguity that cannot be avoided as above. The parser has a fallback + heuristic based on type categories and preferred + types that can help to provide desired behavior in such cases. See + CREATE TYPE for + more information. +

To be able to create a cast, you must own the source or the target data type + and have USAGE privilege on the other type. To create a + binary-coercible cast, you must be superuser. (This restriction is made + because an erroneous binary-coercible cast conversion can easily crash the + server.) +

Parameters

source_type

The name of the source data type of the cast. +

target_type

The name of the target data type of the cast. +

function_name(argument_type [, ...])

The function used to perform the cast. The function name can + be schema-qualified. If it is not, the function will be looked + up in the schema search path. The function's result data type must + match the target type of the cast. Its arguments are discussed below. +

WITHOUT FUNCTION

Indicates that the source type is binary-coercible to the target type, + so no function is required to perform the cast. +

WITH INOUT

Indicates that the cast is an I/O conversion cast, performed by + invoking the output function of the source data type, and passing the + resulting string to the input function of the target data type. +

AS ASSIGNMENT

Indicates that the cast can be invoked implicitly in assignment + contexts. +

AS IMPLICIT

Indicates that the cast can be invoked implicitly in any context. +

Cast implementation functions can have one to three arguments. + The first argument type must be identical to or binary-coercible from + the cast's source type. The second argument, + if present, must be type integer; it receives the type + modifier associated with the destination type, or -1 + if there is none. The third argument, + if present, must be type boolean; it receives true + if the cast is an explicit cast, false otherwise. + (Bizarrely, the SQL standard demands different behaviors for explicit and + implicit casts in some cases. This argument is supplied for functions + that must implement such casts. It is not recommended that you design + your own data types so that this matters.) +

The return type of a cast function must be identical to or + binary-coercible to the cast's target type. +

Ordinarily a cast must have different source and target data types. + However, it is allowed to declare a cast with identical source and + target types if it has a cast implementation function with more than one + argument. This is used to represent type-specific length coercion + functions in the system catalogs. The named function is used to + coerce a value of the type to the type modifier value given by its + second argument. +

When a cast has different source and + target types and a function that takes more than one argument, it + supports converting from one type to another and applying a length + coercion in a single step. When no such entry is available, coercion + to a type that uses a type modifier involves two cast steps, one to + convert between data types and a second to apply the modifier. +

A cast to or from a domain type currently has no effect. Casting + to or from a domain uses the casts associated with its underlying type. +

Notes

Use DROP CAST to remove user-defined casts. +

Remember that if you want to be able to convert types both ways you + need to declare casts both ways explicitly. +

It is normally not necessary to create casts between user-defined types + and the standard string types (text, varchar, and + char(n), as well as user-defined types that + are defined to be in the string category). PostgreSQL + provides automatic I/O conversion casts for that. The automatic casts to + string types are treated as assignment casts, while the automatic casts + from string types are + explicit-only. You can override this behavior by declaring your own + cast to replace an automatic cast, but usually the only reason to + do so is if you want the conversion to be more easily invokable than the + standard assignment-only or explicit-only setting. Another possible + reason is that you want the conversion to behave differently from the + type's I/O function; but that is sufficiently surprising that you + should think twice about whether it's a good idea. (A small number of + the built-in types do indeed have different behaviors for conversions, + mostly because of requirements of the SQL standard.) +

Prior to PostgreSQL 7.3, every function that had + the same name as a data type, returned that data type, and took one + argument of a different type was automatically a cast function. + This convention has been abandoned in face of the introduction of + schemas and to be able to represent binary-coercible casts in the + system catalogs. The built-in cast functions still follow this naming + scheme, but they have to be shown as casts in the system catalog + pg_cast as well. +

While not required, it is recommended that you continue to follow this old + convention of naming cast implementation functions after the target data + type. Many users are used to being able to cast data types using a + function-style notation, that is + typename(x). This notation is in fact + nothing more nor less than a call of the cast implementation function; it + is not specially treated as a cast. If your conversion functions are not + named to support this convention then you will have surprised users. + Since PostgreSQL allows overloading of the same function + name with different argument types, there is no difficulty in having + multiple conversion functions from different types that all use the + target type's name. +

Note: Actually the preceding paragraph is an oversimplification: there are + two cases in which a function-call construct will be treated as a cast + request without having matched it to an actual function. + If a function call name(x) does not + exactly match any existing function, but name is the name + of a data type and pg_cast provides a binary-coercible cast + to this type from the type of x, then the call will be + construed as a binary-coercible cast. This exception is made so that + binary-coercible casts can be invoked using functional syntax, even + though they lack any function. Likewise, if there is no + pg_cast entry but the cast would be to or from a string + type, the call will be construed as an I/O conversion cast. This + exception allows I/O conversion casts to be invoked using functional + syntax. +

Note: There is also an exception to the exception: I/O conversion casts from + composite types to string types cannot be invoked using functional + syntax, but must be written in explicit cast syntax (either + CAST or :: notation). This exception was added + because after the introduction of automatically-provided I/O conversion + casts, it was found too easy to accidentally invoke such a cast when + a function or column reference was intended. +

Examples

To create an assignment cast from type bigint to type + int4 using the function int4(bigint): +

CREATE CAST (bigint AS int4) WITH FUNCTION int4(bigint) AS ASSIGNMENT;

+ (This cast is already predefined in the system.) +

Compatibility

The CREATE CAST command conforms to the + SQL standard, + except that SQL does not make provisions for binary-coercible + types or extra arguments to implementation functions. + AS IMPLICIT is a PostgreSQL + extension, too. +


PrevHomeNext
CREATE AGGREGATEUpCREATE COLLATION
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createcollation.html b/doc/src/sgml/html/sql-createcollation.html new file mode 100644 index 000000000..83a4f05ca --- /dev/null +++ b/doc/src/sgml/html/sql-createcollation.html @@ -0,0 +1,433 @@ + +CREATE COLLATION

CREATE COLLATION

Name

CREATE COLLATION -- define a new collation

Synopsis

CREATE COLLATION name (
+    [ LOCALE = locale, ]
+    [ LC_COLLATE = lc_collate, ]
+    [ LC_CTYPE = lc_ctype ]
+)
+CREATE COLLATION name FROM existing_collation

Description

CREATE COLLATION defines a new collation using + the specified operating system locale settings, + or by copying an existing collation. +

To be able to create a collation, you must + have CREATE privilege on the destination schema. +

Parameters

name

The name of the collation. The collation name can be + schema-qualified. If it is not, the collation is defined in the + current schema. The collation name must be unique within that + schema. (The system catalogs can contain collations with the + same name for other encodings, but these are ignored if the + database encoding does not match.) +

locale

This is a shortcut for setting LC_COLLATE + and LC_CTYPE at once. If you specify this, + you cannot specify either of those parameters. +

lc_collate

Use the specified operating system locale for + the LC_COLLATE locale category. The locale + must be applicable to the current database encoding. + (See CREATE DATABASE for the precise + rules.) +

lc_ctype

Use the specified operating system locale for + the LC_CTYPE locale category. The locale + must be applicable to the current database encoding. + (See CREATE DATABASE for the precise + rules.) +

existing_collation

The name of an existing collation to copy. The new collation + will have the same properties as the existing one, but it + will be an independent object. +

Notes

Use DROP COLLATION to remove user-defined collations. +

See Section 22.2 for more information about collation + support in PostgreSQL. +

Examples

To create a collation from the operating system locale + fr_FR.utf8 + (assuming the current database encoding is UTF8): +

CREATE COLLATION french (LOCALE = 'fr_FR.utf8');

+

To create a collation from an existing collation: +

CREATE COLLATION german FROM "de_DE";

+ This can be convenient to be able to use operating-system-independent + collation names in applications. +

Compatibility

There is a CREATE COLLATION statement in the SQL + standard, but it is limited to copying an existing collation. The + syntax to create a new collation is + a PostgreSQL extension. +


PrevHomeNext
CREATE CASTUpCREATE CONVERSION
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createconversion.html b/doc/src/sgml/html/sql-createconversion.html new file mode 100644 index 000000000..bd1bd4724 --- /dev/null +++ b/doc/src/sgml/html/sql-createconversion.html @@ -0,0 +1,420 @@ + +CREATE CONVERSION

CREATE CONVERSION

Name

CREATE CONVERSION -- define a new encoding conversion

Synopsis

CREATE [ DEFAULT ] CONVERSION name
+    FOR source_encoding TO dest_encoding FROM function_name

Description

CREATE CONVERSION defines a new conversion between + character set encodings. Also, conversions that + are marked DEFAULT can be used for automatic encoding + conversion between + client and server. For this purpose, two conversions, from encoding A to + B and from encoding B to A, must be defined. +

To be able to create a conversion, you must have EXECUTE privilege + on the function and CREATE privilege on the destination schema. +

Parameters

DEFAULT

The DEFAULT clause indicates that this conversion + is the default for this particular source to destination + encoding. There should be only one default encoding in a schema + for the encoding pair. +

name

The name of the conversion. The conversion name can be + schema-qualified. If it is not, the conversion is defined in the + current schema. The conversion name must be unique within a + schema. +

source_encoding

The source encoding name. +

dest_encoding

The destination encoding name. +

function_name

The function used to perform the conversion. The function name can + be schema-qualified. If it is not, the function will be looked + up in the path. +

The function must have the following signature: + +

conv_proc(
+    integer,  -- source encoding ID
+    integer,  -- destination encoding ID
+    cstring,  -- source string (null terminated C string)
+    internal, -- destination (fill with a null terminated C string)
+    integer   -- source string length
+) RETURNS void;

Notes

Use DROP CONVERSION to remove user-defined conversions. +

The privileges required to create a conversion might be changed in a future + release. +

Examples

To create a conversion from encoding UTF8 to + LATIN1 using myfunc: +

CREATE CONVERSION myconv FOR 'UTF8' TO 'LATIN1' FROM myfunc;

Compatibility

CREATE CONVERSION + is a PostgreSQL extension. + There is no CREATE CONVERSION + statement in the SQL standard, but a CREATE TRANSLATION + statement that is very similar in purpose and syntax. +


PrevHomeNext
CREATE COLLATIONUpCREATE DATABASE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createdatabase.html b/doc/src/sgml/html/sql-createdatabase.html new file mode 100644 index 000000000..d60fc9bdf --- /dev/null +++ b/doc/src/sgml/html/sql-createdatabase.html @@ -0,0 +1,687 @@ + +CREATE DATABASE

CREATE DATABASE

Name

CREATE DATABASE -- create a new database

Synopsis

CREATE DATABASE name
+    [ [ WITH ] [ OWNER [=] user_name ]
+           [ TEMPLATE [=] template ]
+           [ ENCODING [=] encoding ]
+           [ LC_COLLATE [=] lc_collate ]
+           [ LC_CTYPE [=] lc_ctype ]
+           [ TABLESPACE [=] tablespace_name ]
+           [ CONNECTION LIMIT [=] connlimit ] ]

Description

CREATE DATABASE creates a new + PostgreSQL database. +

To create a database, you must be a superuser or have the special + CREATEDB privilege. + See CREATE USER. +

By default, the new database will be created by cloning the standard + system database template1. A different template can be + specified by writing TEMPLATE + name. In particular, + by writing TEMPLATE template0, you can create a virgin + database containing only the standard objects predefined by your + version of PostgreSQL. This is useful + if you wish to avoid copying + any installation-local objects that might have been added to + template1. +

Parameters

name

The name of a database to create. +

user_name

The role name of the user who will own the new database, + or DEFAULT to use the default (namely, the + user executing the command). To create a database owned by another + role, you must be a direct or indirect member of that role, + or be a superuser. +

template

The name of the template from which to create the new database, + or DEFAULT to use the default template + (template1). +

encoding

Character set encoding to use in the new database. Specify + a string constant (e.g., 'SQL_ASCII'), + or an integer encoding number, or DEFAULT + to use the default encoding (namely, the encoding of the + template database). The character sets supported by the + PostgreSQL server are described in + Section 22.3.1. See below for + additional restrictions. +

lc_collate

Collation order (LC_COLLATE) to use in the new database. + This affects the sort order applied to strings, e.g. in queries with + ORDER BY, as well as the order used in indexes on text columns. + The default is to use the collation order of the template database. + See below for additional restrictions. +

lc_ctype

Character classification (LC_CTYPE) to use in the new + database. This affects the categorization of characters, e.g. lower, + upper and digit. The default is to use the character classification of + the template database. See below for additional restrictions. +

tablespace_name

The name of the tablespace that will be associated with the + new database, or DEFAULT to use the + template database's tablespace. This + tablespace will be the default tablespace used for objects + created in this database. See + CREATE TABLESPACE + for more information. +

connlimit

How many concurrent connections can be made + to this database. -1 (the default) means no limit. +

Optional parameters can be written in any order, not only the order + illustrated above. +

Notes

CREATE DATABASE cannot be executed inside a transaction + block. +

Errors along the line of "could not initialize database directory" + are most likely related to insufficient permissions on the data + directory, a full disk, or other file system problems. +

Use DROP DATABASE to remove a database. +

The program createdb is a + wrapper program around this command, provided for convenience. +

Although it is possible to copy a database other than template1 + by specifying its name as the template, this is not (yet) intended as + a general-purpose "COPY DATABASE" facility. + The principal limitation is that no other sessions can be connected to + the template database while it is being copied. CREATE + DATABASE will fail if any other connection exists when it starts; + otherwise, new connections to the template database are locked out + until CREATE DATABASE completes. + See Section 21.3 for more information. +

The character set encoding specified for the new database must be + compatible with the chosen locale settings (LC_COLLATE and + LC_CTYPE). If the locale is C (or equivalently + POSIX), then all encodings are allowed, but for other + locale settings there is only one encoding that will work properly. + (On Windows, however, UTF-8 encoding can be used with any locale.) + CREATE DATABASE will allow superusers to specify + SQL_ASCII encoding regardless of the locale settings, + but this choice is deprecated and may result in misbehavior of + character-string functions if data that is not encoding-compatible + with the locale is stored in the database. +

The encoding and locale settings must match those of the template database, + except when template0 is used as template. This is because + other databases might contain data that does not match the specified + encoding, or might contain indexes whose sort ordering is affected by + LC_COLLATE and LC_CTYPE. Copying such data would + result in a database that is corrupt according to the new settings. + template0, however, is known to not contain any data or + indexes that would be affected. +

The CONNECTION LIMIT option is only enforced approximately; + if two new sessions start at about the same time when just one + connection "slot" remains for the database, it is possible that + both will fail. Also, the limit is not enforced against superusers. +

Examples

To create a new database: + +

CREATE DATABASE lusiadas;

+

To create a database sales owned by user salesapp + with a default tablespace of salesspace: + +

CREATE DATABASE sales OWNER salesapp TABLESPACE salesspace;

+

To create a database music which supports the ISO-8859-1 + character set: + +

CREATE DATABASE music ENCODING 'LATIN1' TEMPLATE template0;

+ + In this example, the TEMPLATE template0 clause would only + be required if template1's encoding is not ISO-8859-1. + Note that changing encoding might require selecting new + LC_COLLATE and LC_CTYPE settings as well. +

Compatibility

There is no CREATE DATABASE statement in the SQL + standard. Databases are equivalent to catalogs, whose creation is + implementation-defined. +


PrevHomeNext
CREATE CONVERSIONUpCREATE DOMAIN
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createdomain.html b/doc/src/sgml/html/sql-createdomain.html new file mode 100644 index 000000000..137344f45 --- /dev/null +++ b/doc/src/sgml/html/sql-createdomain.html @@ -0,0 +1,509 @@ + +CREATE DOMAIN

CREATE DOMAIN

Name

CREATE DOMAIN -- define a new domain

Synopsis

CREATE DOMAIN name [ AS ] data_type
+    [ COLLATE collation ]
+    [ DEFAULT expression ]
+    [ constraint [ ... ] ]
+
+where constraint is:
+
+[ CONSTRAINT constraint_name ]
+{ NOT NULL | NULL | CHECK (expression) }

Description

CREATE DOMAIN creates a new domain. A domain is + essentially a data type with optional constraints (restrictions on + the allowed set of values). + The user who defines a domain becomes its owner. +

If a schema name is given (for example, CREATE DOMAIN + myschema.mydomain ...) then the domain is created in the + specified schema. Otherwise it is created in the current schema. + The domain name must be unique among the types and domains existing + in its schema. +

Domains are useful for abstracting common constraints on fields into + a single location for maintenance. For example, several tables might + contain email address columns, all requiring the same CHECK constraint + to verify the address syntax. + Define a domain rather than setting up each table's constraint + individually. +

To be able to create a domain, you must have USAGE + privilege on the underlying type. +

Parameters

name

The name (optionally schema-qualified) of a domain to be created. +

data_type

The underlying data type of the domain. This can include array + specifiers. +

collation

An optional collation for the domain. If no collation is + specified, the underlying data type's default collation is used. + The underlying type must be collatable if COLLATE + is specified. +

DEFAULT expression

The DEFAULT clause specifies a default value for + columns of the domain data type. The value is any + variable-free expression (but subqueries are not allowed). + The data type of the default expression must match the data + type of the domain. If no default value is specified, then + the default value is the null value. +

The default expression will be used in any insert operation + that does not specify a value for the column. If a default + value is defined for a particular column, it overrides any + default associated with the domain. In turn, the domain + default overrides any default value associated with the + underlying data type. +

CONSTRAINT constraint_name

An optional name for a constraint. If not specified, + the system generates a name. +

NOT NULL

Values of this domain are normally prevented from being null. + However, it is still possible for a domain with this constraint + to take a null value if it is assigned a matching domain type + that has become null, e.g. via a LEFT OUTER JOIN, or + INSERT INTO tab (domcol) VALUES ((SELECT domcol FROM + tab WHERE false)). +

NULL

Values of this domain are allowed to be null. This is the default. +

This clause is only intended for compatibility with + nonstandard SQL databases. Its use is discouraged in new + applications. +

CHECK (expression)

CHECK clauses specify integrity constraints or tests + which values of the domain must satisfy. + Each constraint must be an expression + producing a Boolean result. It should use the key word VALUE + to refer to the value being tested. +

Currently, CHECK expressions cannot contain + subqueries nor refer to variables other than VALUE. +

Examples

This example creates the us_postal_code data type and + then uses the type in a table definition. A regular expression test + is used to verify that the value looks like a valid US postal code: + +

CREATE DOMAIN us_postal_code AS TEXT
+CHECK(
+   VALUE ~ '^\d{5}$'
+OR VALUE ~ '^\d{5}-\d{4}$'
+);
+
+CREATE TABLE us_snail_addy (
+  address_id SERIAL PRIMARY KEY,
+  street1 TEXT NOT NULL,
+  street2 TEXT,
+  street3 TEXT,
+  city TEXT NOT NULL,
+  postal us_postal_code NOT NULL
+);

Compatibility

The command CREATE DOMAIN conforms to the SQL + standard. +


PrevHomeNext
CREATE DATABASEUpCREATE EXTENSION
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createextension.html b/doc/src/sgml/html/sql-createextension.html new file mode 100644 index 000000000..775af738a --- /dev/null +++ b/doc/src/sgml/html/sql-createextension.html @@ -0,0 +1,509 @@ + +CREATE EXTENSION

CREATE EXTENSION

Name

CREATE EXTENSION -- install an extension

Synopsis

CREATE EXTENSION [ IF NOT EXISTS ] extension_name
+    [ WITH ] [ SCHEMA schema_name ]
+             [ VERSION version ]
+             [ FROM old_version ]

Description

CREATE EXTENSION loads a new extension into the current + database. There must not be an extension of the same name already loaded. +

Loading an extension essentially amounts to running the extension's script + file. The script will typically create new SQL objects such as + functions, data types, operators and index support methods. + CREATE EXTENSION additionally records the identities + of all the created objects, so that they can be dropped again if + DROP EXTENSION is issued. +

Loading an extension requires the same privileges that would be + required to create its component objects. For most extensions this + means superuser or database owner privileges are needed. + The user who runs CREATE EXTENSION becomes the + owner of the extension for purposes of later privilege checks, as well + as the owner of any objects created by the extension's script. +

Parameters

IF NOT EXISTS

Do not throw an error if an extension with the same name already + exists. A notice is issued in this case. Note that there is no + guarantee that the existing extension is anything like the one that + would have been created from the currently-available script file. +

extension_name

The name of the extension to be + installed. PostgreSQL will create the + extension using details from the file + SHAREDIR/extension/extension_name.control. +

schema_name

The name of the schema in which to install the extension's + objects, given that the extension allows its contents to be + relocated. The named schema must already exist. + If not specified, and the extension's control file does not specify a + schema either, the current default object creation schema is used. +

version

The version of the extension to install. This can be written as + either an identifier or a string literal. The default version is + whatever is specified in the extension's control file. +

old_version

FROM old_version + must be specified when, and only when, you are attempting to install + an extension that replaces an "old style" module that is just + a collection of objects not packaged into an extension. This option + causes CREATE EXTENSION to run an alternative installation + script that absorbs the existing objects into the extension, instead + of creating new objects. Be careful that SCHEMA specifies + the schema containing these pre-existing objects. +

The value to use for old_version is determined by the + extension's author, and might vary if there is more than one version + of the old-style module that can be upgraded into an extension. + For the standard additional modules supplied with pre-9.1 + PostgreSQL, use unpackaged + for old_version when + updating a module to extension style. +

Notes

Before you can use CREATE EXTENSION to load an extension + into a database, the extension's supporting files must be installed. + Information about installing the extensions supplied with + PostgreSQL can be found in + Additional Supplied Modules. +

The extensions currently available for loading can be identified from the + pg_available_extensions + or + pg_available_extension_versions + system views. +

For information about writing new extensions, see + Section 35.15. +

Examples

Install the hstore extension into the + current database: +

CREATE EXTENSION hstore;

+

Update a pre-9.1 installation of hstore into + extension style: +

CREATE EXTENSION hstore SCHEMA public FROM unpackaged;

+ Be careful to specify the schema in which you installed the existing + hstore objects. +

Compatibility

CREATE EXTENSION is a PostgreSQL + extension. +


PrevHomeNext
CREATE DOMAINUpCREATE FOREIGN DATA WRAPPER
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createforeigndatawrapper.html b/doc/src/sgml/html/sql-createforeigndatawrapper.html new file mode 100644 index 000000000..54eba1752 --- /dev/null +++ b/doc/src/sgml/html/sql-createforeigndatawrapper.html @@ -0,0 +1,479 @@ + +CREATE FOREIGN DATA WRAPPER

CREATE FOREIGN DATA WRAPPER

Name

CREATE FOREIGN DATA WRAPPER -- define a new foreign-data wrapper

Synopsis

CREATE FOREIGN DATA WRAPPER name
+    [ HANDLER handler_function | NO HANDLER ]
+    [ VALIDATOR validator_function | NO VALIDATOR ]
+    [ OPTIONS ( option 'value' [, ... ] ) ]

Description

CREATE FOREIGN DATA WRAPPER creates a new + foreign-data wrapper. The user who defines a foreign-data wrapper + becomes its owner. +

The foreign-data wrapper name must be unique within the database. +

Only superusers can create foreign-data wrappers. +

Parameters

name

The name of the foreign-data wrapper to be created. +

HANDLER handler_function

handler_function is the + name of a previously registered function that will be called to + retrieve the execution functions for foreign tables. + The handler function must take no arguments, and + its return type must be fdw_handler. +

It is possible to create a foreign-data wrapper with no handler + function, but foreign tables using such a wrapper can only be declared, + not accessed. +

VALIDATOR validator_function

validator_function is the + name of a previously registered function that will be called to + check the generic options given to the foreign-data wrapper, as + well as options for foreign servers and user mappings using the + foreign-data wrapper. If no validator function or NO + VALIDATOR is specified, then options will not be + checked at creation time. (Foreign-data wrappers will possibly + ignore or reject invalid option specifications at run time, + depending on the implementation.) The validator function must + take two arguments: one of type text[], which will + contain the array of options as stored in the system catalogs, + and one of type oid, which will be the OID of the + system catalog containing the options. The return type is ignored; + the function should report invalid options using the + ereport(ERROR) function. +

OPTIONS ( option 'value' [, ... ] )

This clause specifies options for the new foreign-data wrapper. + The allowed option names and values are specific to each foreign + data wrapper and are validated using the foreign-data wrapper's + validator function. Option names must be unique. +

Notes

At the moment, the foreign-data wrapper functionality is rudimentary. + There is no support for updating a foreign table, and optimization of + queries is primitive (and mostly left to the wrapper, too). +

There is one built-in foreign-data wrapper validator function + provided: + postgresql_fdw_validator, which accepts + options corresponding to libpq connection + parameters. +

Examples

Create a useless foreign-data wrapper dummy: +

CREATE FOREIGN DATA WRAPPER dummy;

+

Create a foreign-data wrapper file with + handler function file_fdw_handler: +

CREATE FOREIGN DATA WRAPPER file HANDLER file_fdw_handler;

+

Create a foreign-data wrapper mywrapper with some + options: +

CREATE FOREIGN DATA WRAPPER mywrapper
+    OPTIONS (debug 'true');

Compatibility

CREATE FOREIGN DATA WRAPPER conforms to ISO/IEC + 9075-9 (SQL/MED), with the exception that the HANDLER + and VALIDATOR clauses are extensions and the standard + clauses LIBRARY and LANGUAGE + are not implemented in PostgreSQL. +

Note, however, that the SQL/MED functionality as a whole is not yet + conforming. +


PrevHomeNext
CREATE EXTENSIONUpCREATE FOREIGN TABLE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createforeigntable.html b/doc/src/sgml/html/sql-createforeigntable.html new file mode 100644 index 000000000..7cdc9a348 --- /dev/null +++ b/doc/src/sgml/html/sql-createforeigntable.html @@ -0,0 +1,478 @@ + +CREATE FOREIGN TABLE

CREATE FOREIGN TABLE

Name

CREATE FOREIGN TABLE -- define a new foreign table

Synopsis

CREATE FOREIGN TABLE [ IF NOT EXISTS ] table_name ( [
+  { column_name data_type [ OPTIONS ( option 'value' [, ... ] ) ] [ NULL | NOT NULL ] }
+    [, ... ]
+] )
+  SERVER server_name
+[ OPTIONS ( option 'value' [, ... ] ) ]

Description

CREATE FOREIGN TABLE will create a new foreign table + in the current database. The table will be owned by the user issuing the + command. +

If a schema name is given (for example, CREATE FOREIGN TABLE + myschema.mytable ...) then the table is created in the specified + schema. Otherwise it is created in the current schema. + The name of the foreign table must be + distinct from the name of any other foreign table, table, sequence, index, + or view in the same schema. +

CREATE FOREIGN TABLE also automatically creates a data + type that represents the composite type corresponding to one row of + the foreign table. Therefore, foreign tables cannot have the same + name as any existing data type in the same schema. +

To be able to create a table, you must have USAGE + privilege on all column types. +

Parameters

IF NOT EXISTS

Do not throw an error if a relation with the same name already exists. + A notice is issued in this case. Note that there is no guarantee that + the existing relation is anything like the one that would have been + created. +

table_name

The name (optionally schema-qualified) of the table to be created. +

column_name

The name of a column to be created in the new table. +

data_type

The data type of the column. This can include array + specifiers. For more information on the data types supported by + PostgreSQL, refer to Chapter 8. +

NOT NULL

The column is not allowed to contain null values. +

NULL

The column is allowed to contain null values. This is the default. +

This clause is only provided for compatibility with + non-standard SQL databases. Its use is discouraged in new + applications. +

server_name

The name of an existing server for the foreign table. +

OPTIONS ( option 'value' [, ...] )

Options to be associated with the new foreign table or one of its + columns. + The allowed option names and values are specific to each foreign + data wrapper and are validated using the foreign-data wrapper's + validator function. Duplicate option names are not allowed (although + it's OK for a table option and a column option to have the same name). +

Examples

Create foreign table films with film_server: + +

CREATE FOREIGN TABLE films (
+    code        char(5) NOT NULL,
+    title       varchar(40) NOT NULL,
+    did         integer NOT NULL,
+    date_prod   date,
+    kind        varchar(10),
+    len         interval hour to minute
+)
+SERVER film_server;

Compatibility

The CREATE FOREIGN TABLE command largely conforms to the + SQL standard; however, much as with + CREATE TABLE, + NULL constraints and zero-column foreign tables are permitted. +


PrevHomeNext
CREATE FOREIGN DATA WRAPPERUpCREATE FUNCTION
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createfunction.html b/doc/src/sgml/html/sql-createfunction.html new file mode 100644 index 000000000..0fcd6fa29 --- /dev/null +++ b/doc/src/sgml/html/sql-createfunction.html @@ -0,0 +1,1509 @@ + +CREATE FUNCTION

CREATE FUNCTION

Name

CREATE FUNCTION -- define a new function

Synopsis

CREATE [ OR REPLACE ] FUNCTION
+    name ( [ [ argmode ] [ argname ] argtype [ { DEFAULT | = } default_expr ] [, ...] ] )
+    [ RETURNS rettype
+      | RETURNS TABLE ( column_name column_type [, ...] ) ]
+  { LANGUAGE lang_name
+    | WINDOW
+    | IMMUTABLE | STABLE | VOLATILE | [ NOT ] LEAKPROOF
+    | CALLED ON NULL INPUT | RETURNS NULL ON NULL INPUT | STRICT
+    | [ EXTERNAL ] SECURITY INVOKER | [ EXTERNAL ] SECURITY DEFINER
+    | COST execution_cost
+    | ROWS result_rows
+    | SET configuration_parameter { TO value | = value | FROM CURRENT }
+    | AS 'definition'
+    | AS 'obj_file', 'link_symbol'
+  } ...
+    [ WITH ( attribute [, ...] ) ]

Description

CREATE FUNCTION defines a new function. + CREATE OR REPLACE FUNCTION will either create a + new function, or replace an existing definition. + To be able to define a function, the user must have the + USAGE privilege on the language. +

If a schema name is included, then the function is created in the + specified schema. Otherwise it is created in the current schema. + The name of the new function must not match any existing function + with the same input argument types in the same schema. However, + functions of different argument types can share a name (this is + called overloading). +

To replace the current definition of an existing function, use + CREATE OR REPLACE FUNCTION. It is not possible + to change the name or argument types of a function this way (if you + tried, you would actually be creating a new, distinct function). + Also, CREATE OR REPLACE FUNCTION will not let + you change the return type of an existing function. To do that, + you must drop and recreate the function. (When using OUT + parameters, that means you cannot change the types of any + OUT parameters except by dropping the function.) +

When CREATE OR REPLACE FUNCTION is used to replace an + existing function, the ownership and permissions of the function + do not change. All other function properties are assigned the + values specified or implied in the command. You must own the function + to replace it (this includes being a member of the owning role). +

If you drop and then recreate a function, the new function is not + the same entity as the old; you will have to drop existing rules, views, + triggers, etc. that refer to the old function. Use + CREATE OR REPLACE FUNCTION to change a function + definition without breaking objects that refer to the function. + Also, ALTER FUNCTION can be used to change most of the + auxiliary properties of an existing function. +

The user that creates the function becomes the owner of the function. +

To be able to create a function, you must have USAGE + privilege on the argument types and the return type. +

Parameters

name

The name (optionally schema-qualified) of the function to create. +

argmode

The mode of an argument: IN, OUT, + INOUT, or VARIADIC. + If omitted, the default is IN. + Only OUT arguments can follow a VARIADIC one. + Also, OUT and INOUT arguments cannot be used + together with the RETURNS TABLE notation. +

argname

The name of an argument. Some languages (currently only PL/pgSQL) let + you use the name in the function body. For other languages the + name of an input argument is just extra documentation, so far as + the function itself is concerned; but you can use input argument names + when calling a function to improve readability (see Section 4.3). In any case, the name + of an output argument is significant, because it defines the column + name in the result row type. (If you omit the name for an output + argument, the system will choose a default column name.) +

argtype

The data type(s) of the function's arguments (optionally + schema-qualified), if any. The argument types can be base, composite, + or domain types, or can reference the type of a table column. +

Depending on the implementation language it might also be allowed + to specify "pseudotypes" such as cstring. + Pseudotypes indicate that the actual argument type is either + incompletely specified, or outside the set of ordinary SQL data types. +

The type of a column is referenced by writing + table_name.column_name%TYPE. + Using this feature can sometimes help make a function independent of + changes to the definition of a table. +

default_expr

An expression to be used as default value if the parameter is + not specified. The expression has to be coercible to the + argument type of the parameter. + Only input (including INOUT) parameters can have a default + value. All input parameters following a + parameter with a default value must have default values as well. +

rettype

The return data type (optionally schema-qualified). The return type + can be a base, composite, or domain type, + or can reference the type of a table column. + Depending on the implementation language it might also be allowed + to specify "pseudotypes" such as cstring. + If the function is not supposed to return a value, specify + void as the return type. +

When there are OUT or INOUT parameters, + the RETURNS clause can be omitted. If present, it + must agree with the result type implied by the output parameters: + RECORD if there are multiple output parameters, or + the same type as the single output parameter. +

The SETOF + modifier indicates that the function will return a set of + items, rather than a single item. +

The type of a column is referenced by writing + table_name.column_name%TYPE. +

column_name

The name of an output column in the RETURNS TABLE + syntax. This is effectively another way of declaring a named + OUT parameter, except that RETURNS TABLE + also implies RETURNS SETOF. +

column_type

The data type of an output column in the RETURNS TABLE + syntax. +

lang_name

The name of the language that the function is implemented in. + Can be SQL, C, + internal, or the name of a user-defined + procedural language. For backward compatibility, + the name can be enclosed by single quotes. +

WINDOW

WINDOW indicates that the function is a + window function rather than a plain function. + This is currently only useful for functions written in C. + The WINDOW attribute cannot be changed when + replacing an existing function definition. +

IMMUTABLE
STABLE
VOLATILE

These attributes inform the query optimizer about the behavior + of the function. At most one choice + can be specified. If none of these appear, + VOLATILE is the default assumption. +

IMMUTABLE indicates that the function + cannot modify the database and always + returns the same result when given the same argument values; that + is, it does not do database lookups or otherwise use information not + directly present in its argument list. If this option is given, + any call of the function with all-constant arguments can be + immediately replaced with the function value. +

STABLE indicates that the function + cannot modify the database, + and that within a single table scan it will consistently + return the same result for the same argument values, but that its + result could change across SQL statements. This is the appropriate + selection for functions whose results depend on database lookups, + parameter variables (such as the current time zone), etc. (It is + inappropriate for AFTER triggers that wish to + query rows modified by the current command.) Also note + that the current_timestamp family of functions qualify + as stable, since their values do not change within a transaction. +

VOLATILE indicates that the function value can + change even within a single table scan, so no optimizations can be + made. Relatively few database functions are volatile in this sense; + some examples are random(), currval(), + timeofday(). But note that any function that has + side-effects must be classified volatile, even if its result is quite + predictable, to prevent calls from being optimized away; an example is + setval(). +

For additional details see Section 35.6. +

LEAKPROOF

LEAKPROOF indicates that the function has no side + effects. It reveals no information about its arguments other than by + its return value. For example, a function which throws an error message + for some argument values but not others, or which includes the argument + values in any error message, is not leakproof. The query planner may + push leakproof functions (but not others) into views created with the + security_barrier option. See + CREATE VIEW and Section 37.4. + This option can only be set by the superuser. +

CALLED ON NULL INPUT
RETURNS NULL ON NULL INPUT
STRICT

CALLED ON NULL INPUT (the default) indicates + that the function will be called normally when some of its + arguments are null. It is then the function author's + responsibility to check for null values if necessary and respond + appropriately. +

RETURNS NULL ON NULL INPUT or + STRICT indicates that the function always + returns null whenever any of its arguments are null. If this + parameter is specified, the function is not executed when there + are null arguments; instead a null result is assumed + automatically. +

[EXTERNAL] SECURITY INVOKER
[EXTERNAL] SECURITY DEFINER

SECURITY INVOKER indicates that the function + is to be executed with the privileges of the user that calls it. + That is the default. SECURITY DEFINER + specifies that the function is to be executed with the + privileges of the user that created it. +

The key word EXTERNAL is allowed for SQL + conformance, but it is optional since, unlike in SQL, this feature + applies to all functions not only external ones. +

execution_cost

A positive number giving the estimated execution cost for the function, + in units of cpu_operator_cost. If the function + returns a set, this is the cost per returned row. If the cost is + not specified, 1 unit is assumed for C-language and internal functions, + and 100 units for functions in all other languages. Larger values + cause the planner to try to avoid evaluating the function more often + than necessary. +

result_rows

A positive number giving the estimated number of rows that the planner + should expect the function to return. This is only allowed when the + function is declared to return a set. The default assumption is + 1000 rows. +

configuration_parameter
value

The SET clause causes the specified configuration + parameter to be set to the specified value when the function is + entered, and then restored to its prior value when the function exits. + SET FROM CURRENT saves the session's current value of + the parameter as the value to be applied when the function is entered. +

If a SET clause is attached to a function, then + the effects of a SET LOCAL command executed inside the + function for the same variable are restricted to the function: the + configuration parameter's prior value is still restored at function exit. + However, an ordinary + SET command (without LOCAL) overrides the + SET clause, much as it would do for a previous SET + LOCAL command: the effects of such a command will persist after + function exit, unless the current transaction is rolled back. +

See SET and + Chapter 18 + for more information about allowed parameter names and values. +

definition

A string constant defining the function; the meaning depends on the + language. It can be an internal function name, the path to an + object file, an SQL command, or text in a procedural language. +

It is often helpful to use dollar quoting (see Section 4.1.2.4) to write the function definition + string, rather than the normal single quote syntax. Without dollar + quoting, any single quotes or backslashes in the function definition must + be escaped by doubling them. +

obj_file, link_symbol

This form of the AS clause is used for + dynamically loadable C language functions when the function name + in the C language source code is not the same as the name of + the SQL function. The string obj_file is the name of the + file containing the dynamically loadable object, and + link_symbol is the + function's link symbol, that is, the name of the function in the C + language source code. If the link symbol is omitted, it is assumed + to be the same as the name of the SQL function being defined. +

When repeated CREATE FUNCTION calls refer to + the same object file, the file is only loaded once per session. + To unload and + reload the file (perhaps during development), start a new session. +

attribute

The historical way to specify optional pieces of information + about the function. The following attributes can appear here: + +

isStrict

Equivalent to STRICT or RETURNS NULL ON NULL INPUT. +

isCachable

isCachable is an obsolete equivalent of + IMMUTABLE; it's still accepted for + backwards-compatibility reasons. +

+ + Attribute names are not case-sensitive. +

Refer to Section 35.3 for further information on writing + functions. +

Overloading

PostgreSQL allows function + overloading; that is, the same name can be + used for several different functions so long as they have distinct + input argument types. However, the C names of all functions must be + different, so you must give overloaded C functions different C + names (for example, use the argument types as part of the C + names). +

Two functions are considered the same if they have the same names and + input argument types, ignoring any OUT + parameters. Thus for example these declarations conflict: +

CREATE FUNCTION foo(int) ...
+CREATE FUNCTION foo(int, out text) ...

+

Functions that have different argument type lists will not be considered + to conflict at creation time, but if defaults are provided they might + conflict in use. For example, consider +

CREATE FUNCTION foo(int) ...
+CREATE FUNCTION foo(int, int default 42) ...

+ A call foo(10) will fail due to the ambiguity about which + function should be called. +

Notes

The full SQL type syntax is allowed for + input arguments and return value. However, some details of the + type specification (e.g., the precision field for + type numeric) are the responsibility of the + underlying function implementation and are silently swallowed + (i.e., not recognized or + enforced) by the CREATE FUNCTION command. +

When replacing an existing function with CREATE OR REPLACE + FUNCTION, there are restrictions on changing parameter names. + You cannot change the name already assigned to any input parameter + (although you can add names to parameters that had none before). + If there is more than one output parameter, you cannot change the + names of the output parameters, because that would change the + column names of the anonymous composite type that describes the + function's result. These restrictions are made to ensure that + existing calls of the function do not stop working when it is replaced. +

If a function is declared STRICT with a VARIADIC + argument, the strictness check tests that the variadic array as + a whole is non-null. The function will still be called if the + array has null elements. +

Examples

Here are some trivial examples to help you get started. For more + information and examples, see Section 35.3. +

CREATE FUNCTION add(integer, integer) RETURNS integer
+    AS 'select $1 + $2;'
+    LANGUAGE SQL
+    IMMUTABLE
+    RETURNS NULL ON NULL INPUT;

+

Increment an integer, making use of an argument name, in + PL/pgSQL: +

CREATE OR REPLACE FUNCTION increment(i integer) RETURNS integer AS $$
+        BEGIN
+                RETURN i + 1;
+        END;
+$$ LANGUAGE plpgsql;

+

Return a record containing multiple output parameters: +

CREATE FUNCTION dup(in int, out f1 int, out f2 text)
+    AS $$ SELECT $1, CAST($1 AS text) || ' is text' $$
+    LANGUAGE SQL;
+
+SELECT * FROM dup(42);

+ You can do the same thing more verbosely with an explicitly named + composite type: +

CREATE TYPE dup_result AS (f1 int, f2 text);
+
+CREATE FUNCTION dup(int) RETURNS dup_result
+    AS $$ SELECT $1, CAST($1 AS text) || ' is text' $$
+    LANGUAGE SQL;
+
+SELECT * FROM dup(42);

+ Another way to return multiple columns is to use a TABLE + function: +

CREATE FUNCTION dup(int) RETURNS TABLE(f1 int, f2 text)
+    AS $$ SELECT $1, CAST($1 AS text) || ' is text' $$
+    LANGUAGE SQL;
+
+SELECT * FROM dup(42);

+ However, a TABLE function is different from the + preceding examples, because it actually returns a set + of records, not just one record. +

Writing SECURITY DEFINER Functions Safely

Because a SECURITY DEFINER function is executed + with the privileges of the user that created it, care is needed to + ensure that the function cannot be misused. For security, + search_path should be set to exclude any schemas + writable by untrusted users. This prevents + malicious users from creating objects that mask objects used by the + function. Particularly important in this regard is the + temporary-table schema, which is searched first by default, and + is normally writable by anyone. A secure arrangement can be had + by forcing the temporary schema to be searched last. To do this, + write pg_temp as the last entry in search_path. + This function illustrates safe usage: +

CREATE FUNCTION check_password(uname TEXT, pass TEXT)
+RETURNS BOOLEAN AS $$
+DECLARE passed BOOLEAN;
+BEGIN
+        SELECT  (pwd = $2) INTO passed
+        FROM    pwds
+        WHERE   username = $1;
+
+        RETURN passed;
+END;
+$$  LANGUAGE plpgsql
+    SECURITY DEFINER
+    -- Set a secure search_path: trusted schema(s), then 'pg_temp'.
+    SET search_path = admin, pg_temp;

Before PostgreSQL version 8.3, the + SET option was not available, and so older functions may + contain rather complicated logic to save, set, and restore + search_path. The SET option is far easier + to use for this purpose. +

Another point to keep in mind is that by default, execute privilege + is granted to PUBLIC for newly created functions + (see GRANT for more + information). Frequently you will wish to restrict use of a security + definer function to only some users. To do that, you must revoke + the default PUBLIC privileges and then grant execute + privilege selectively. To avoid having a window where the new function + is accessible to all, create it and set the privileges within a single + transaction. For example: +

BEGIN;
+CREATE FUNCTION check_password(uname TEXT, pass TEXT) ... SECURITY DEFINER;
+REVOKE ALL ON FUNCTION check_password(uname TEXT, pass TEXT) FROM PUBLIC;
+GRANT EXECUTE ON FUNCTION check_password(uname TEXT, pass TEXT) TO admins;
+COMMIT;

Compatibility

A CREATE FUNCTION command is defined in SQL:1999 and later. + The PostgreSQL version is similar but + not fully compatible. The attributes are not portable, neither are the + different available languages. +

For compatibility with some other database systems, + argmode can be written + either before or after argname. + But only the first way is standard-compliant. +

The SQL standard does not specify parameter defaults. The syntax + with the DEFAULT key word is from Oracle, and it + is somewhat in the spirit of the standard: SQL/PSM uses it for + variable default values. The syntax with = is + used in T-SQL and Firebird. +


PrevHomeNext
CREATE FOREIGN TABLEUpCREATE GROUP
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-creategroup.html b/doc/src/sgml/html/sql-creategroup.html new file mode 100644 index 000000000..185c4ea4c --- /dev/null +++ b/doc/src/sgml/html/sql-creategroup.html @@ -0,0 +1,300 @@ + +CREATE GROUP

CREATE GROUP

Name

CREATE GROUP -- define a new database role

Synopsis

CREATE GROUP name [ [ WITH ] option [ ... ] ]
+
+where option can be:
+
+      SUPERUSER | NOSUPERUSER
+    | CREATEDB | NOCREATEDB
+    | CREATEROLE | NOCREATEROLE
+    | CREATEUSER | NOCREATEUSER
+    | INHERIT | NOINHERIT
+    | LOGIN | NOLOGIN
+    | [ ENCRYPTED | UNENCRYPTED ] PASSWORD 'password'
+    | VALID UNTIL 'timestamp'
+    | IN ROLE role_name [, ...]
+    | IN GROUP role_name [, ...]
+    | ROLE role_name [, ...]
+    | ADMIN role_name [, ...]
+    | USER role_name [, ...]
+    | SYSID uid

Description

CREATE GROUP is now an alias for + CREATE ROLE. +

Compatibility

There is no CREATE GROUP statement in the SQL + standard. +

See Also

CREATE ROLE

PrevHomeNext
CREATE FUNCTIONUpCREATE INDEX
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createindex.html b/doc/src/sgml/html/sql-createindex.html new file mode 100644 index 000000000..e73b6038d --- /dev/null +++ b/doc/src/sgml/html/sql-createindex.html @@ -0,0 +1,1238 @@ + +CREATE INDEX

CREATE INDEX

Name

CREATE INDEX -- define a new index

Synopsis

CREATE [ UNIQUE ] INDEX [ CONCURRENTLY ] [ name ] ON table_name [ USING method ]
+    ( { column_name | ( expression ) } [ COLLATE collation ] [ opclass ] [ ASC | DESC ] [ NULLS { FIRST | LAST } ] [, ...] )
+    [ WITH ( storage_parameter = value [, ... ] ) ]
+    [ TABLESPACE tablespace_name ]
+    [ WHERE predicate ]

Description

CREATE INDEX constructs an index + on the specified column(s) of the specified table. + Indexes are primarily used to enhance database performance (though + inappropriate use can result in slower performance). +

The key field(s) for the index are specified as column names, + or alternatively as expressions written in parentheses. + Multiple fields can be specified if the index method supports + multicolumn indexes. +

An index field can be an expression computed from the values of + one or more columns of the table row. This feature can be used + to obtain fast access to data based on some transformation of + the basic data. For example, an index computed on + upper(col) would allow the clause + WHERE upper(col) = 'JIM' to use an index. +

PostgreSQL provides the index methods + B-tree, hash, GiST, SP-GiST, and GIN. Users can also define their own index + methods, but that is fairly complicated. +

When the WHERE clause is present, a + partial index is created. + A partial index is an index that contains entries for only a portion of + a table, usually a portion that is more useful for indexing than the + rest of the table. For example, if you have a table that contains both + billed and unbilled orders where the unbilled orders take up a small + fraction of the total table and yet that is an often used section, you + can improve performance by creating an index on just that portion. + Another possible application is to use WHERE with + UNIQUE to enforce uniqueness over a subset of a + table. See Section 11.8 for more discussion. +

The expression used in the WHERE clause can refer + only to columns of the underlying table, but it can use all columns, + not just the ones being indexed. Presently, subqueries and + aggregate expressions are also forbidden in WHERE. + The same restrictions apply to index fields that are expressions. +

All functions and operators used in an index definition must be + "immutable", that is, their results must depend only on + their arguments and never on any outside influence (such as + the contents of another table or the current time). This restriction + ensures that the behavior of the index is well-defined. To use a + user-defined function in an index expression or WHERE + clause, remember to mark the function immutable when you create it. +

Parameters

UNIQUE

Causes the system to check for + duplicate values in the table when the index is created (if data + already exist) and each time data is added. Attempts to + insert or update data which would result in duplicate entries + will generate an error. +

CONCURRENTLY

When this option is used, PostgreSQL will build the + index without taking any locks that prevent concurrent inserts, + updates, or deletes on the table; whereas a standard index build + locks out writes (but not reads) on the table until it's done. + There are several caveats to be aware of when using this option + — see Building Indexes Concurrently. +

name

The name of the index to be created. No schema name can be included + here; the index is always created in the same schema as its parent + table. If the name is omitted, PostgreSQL chooses a + suitable name based on the parent table's name and the indexed column + name(s). +

table_name

The name (possibly schema-qualified) of the table to be indexed. +

method

The name of the index method to be used. Choices are + btree, hash, + gist, spgist and gin. + The default method is btree. +

column_name

The name of a column of the table. +

expression

An expression based on one or more columns of the table. The + expression usually must be written with surrounding parentheses, + as shown in the syntax. However, the parentheses can be omitted + if the expression has the form of a function call. +

collation

The name of the collation to use for the index. By default, + the index uses the collation declared for the column to be + indexed or the result collation of the expression to be + indexed. Indexes with non-default collations can be useful for + queries that involve expressions using non-default collations. +

opclass

The name of an operator class. See below for details. +

ASC

Specifies ascending sort order (which is the default). +

DESC

Specifies descending sort order. +

NULLS FIRST

Specifies that nulls sort before non-nulls. This is the default + when DESC is specified. +

NULLS LAST

Specifies that nulls sort after non-nulls. This is the default + when DESC is not specified. +

storage_parameter

The name of an index-method-specific storage parameter. See + Index Storage Parameters + for details. +

tablespace_name

The tablespace in which to create the index. If not specified, + default_tablespace is consulted, or + temp_tablespaces for indexes on temporary + tables. +

predicate

The constraint expression for a partial index. +

Index Storage Parameters

The optional WITH clause specifies storage + parameters for the index. Each index method has its own set of allowed + storage parameters. The B-tree, hash, GiST and SP-GiST index methods all + accept this parameter: +

FILLFACTOR

The fillfactor for an index is a percentage that determines how full + the index method will try to pack index pages. For B-trees, leaf pages + are filled to this percentage during initial index build, and also + when extending the index at the right (adding new largest key values). + If pages + subsequently become completely full, they will be split, leading to + gradual degradation in the index's efficiency. B-trees use a default + fillfactor of 90, but any integer value from 10 to 100 can be selected. + If the table is static then fillfactor 100 is best to minimize the + index's physical size, but for heavily updated tables a smaller + fillfactor is better to minimize the need for page splits. The + other index methods use fillfactor in different but roughly analogous + ways; the default fillfactor varies between methods. +

GiST indexes additionally accept this parameter: +

BUFFERING

Determines whether the buffering build technique described in + Section 53.3.1 is used to build the index. With + OFF it is disabled, with ON it is enabled, and + with AUTO it is initially disabled, but turned on + on-the-fly once the index size reaches effective_cache_size. The default is AUTO. +

GIN indexes accept a different parameter: +

FASTUPDATE

This setting controls usage of the fast update technique described in + Section 55.3.1. It is a Boolean parameter: + ON enables fast update, OFF disables it. + (Alternative spellings of ON and OFF are + allowed as described in Section 18.1.) The + default is ON. +

Note: Turning FASTUPDATE off via ALTER INDEX prevents + future insertions from going into the list of pending index entries, + but does not in itself flush previous entries. You might want to + VACUUM the table afterward to ensure the pending list is + emptied. +

Building Indexes Concurrently

Creating an index can interfere with regular operation of a database. + Normally PostgreSQL locks the table to be indexed against + writes and performs the entire index build with a single scan of the + table. Other transactions can still read the table, but if they try to + insert, update, or delete rows in the table they will block until the + index build is finished. This could have a severe effect if the system is + a live production database. Very large tables can take many hours to be + indexed, and even for smaller tables, an index build can lock out writers + for periods that are unacceptably long for a production system. +

PostgreSQL supports building indexes without locking + out writes. This method is invoked by specifying the + CONCURRENTLY option of CREATE INDEX. + When this option is used, + PostgreSQL must perform two scans of the table, and in + addition it must wait for all existing transactions that could potentially + use the index to terminate. Thus + this method requires more total work than a standard index build and takes + significantly longer to complete. However, since it allows normal + operations to continue while the index is built, this method is useful for + adding new indexes in a production environment. Of course, the extra CPU + and I/O load imposed by the index creation might slow other operations. +

In a concurrent index build, the index is actually entered into + the system catalogs in one transaction, then two table scans occur in + two more transactions. Any transaction active when the second table + scan starts can block concurrent index creation until it completes, + even transactions that only reference the table after the second table + scan starts. Concurrent index creation serially waits for each old + transaction to complete using the method outlined in section Section 45.58. +

If a problem arises while scanning the table, such as a + uniqueness violation in a unique index, the CREATE INDEX + command will fail but leave behind an "invalid" index. This index + will be ignored for querying purposes because it might be incomplete; + however it will still consume update overhead. The psql + \d command will report such an index as INVALID: + +

postgres=# \d tab
+       Table "public.tab"
+ Column |  Type   | Modifiers 
+--------+---------+-----------
+ col    | integer | 
+Indexes:
+    "idx" btree (col) INVALID

+ + The recommended recovery + method in such cases is to drop the index and try again to perform + CREATE INDEX CONCURRENTLY. (Another possibility is to rebuild + the index with REINDEX. However, since REINDEX + does not support concurrent builds, this option is unlikely to seem + attractive.) +

Another caveat when building a unique index concurrently is that the + uniqueness constraint is already being enforced against other transactions + when the second table scan begins. This means that constraint violations + could be reported in other queries prior to the index becoming available + for use, or even in cases where the index build eventually fails. Also, + if a failure does occur in the second scan, the "invalid" index + continues to enforce its uniqueness constraint afterwards. +

Concurrent builds of expression indexes and partial indexes are supported. + Errors occurring in the evaluation of these expressions could cause + behavior similar to that described above for unique constraint violations. +

Regular index builds permit other regular index builds on the + same table to occur in parallel, but only one concurrent index build + can occur on a table at a time. In both cases, no other types of schema + modification on the table are allowed meanwhile. Another difference + is that a regular CREATE INDEX command can be performed within + a transaction block, but CREATE INDEX CONCURRENTLY cannot. +

Notes

See Chapter 11 for information about when indexes can + be used, when they are not used, and in which particular situations + they can be useful. +

Caution

Hash index operations are not presently WAL-logged, + so hash indexes might need to be rebuilt with REINDEX + after a database crash if there were unwritten changes. + Also, changes to hash indexes are not replicated over streaming or + file-based replication after the initial base backup, so they + give wrong answers to queries that subsequently use them. + For these reasons, hash index use is presently discouraged. +

Currently, only the B-tree, GiST and GIN index methods support + multicolumn indexes. Up to 32 fields can be specified by default. + (This limit can be altered when building + PostgreSQL.) Only B-tree currently + supports unique indexes. +

An operator class can be specified for each + column of an index. The operator class identifies the operators to be + used by the index for that column. For example, a B-tree index on + four-byte integers would use the int4_ops class; + this operator class includes comparison functions for four-byte + integers. In practice the default operator class for the column's data + type is usually sufficient. The main point of having operator classes + is that for some data types, there could be more than one meaningful + ordering. For example, we might want to sort a complex-number data + type either by absolute value or by real part. We could do this by + defining two operator classes for the data type and then selecting + the proper class when making an index. More information about + operator classes is in Section 11.9 and in Section 35.14. +

For index methods that support ordered scans (currently, only B-tree), + the optional clauses ASC, DESC, NULLS + FIRST, and/or NULLS LAST can be specified to modify + the sort ordering of the index. Since an ordered index can be + scanned either forward or backward, it is not normally useful to create a + single-column DESC index — that sort ordering is already + available with a regular index. The value of these options is that + multicolumn indexes can be created that match the sort ordering requested + by a mixed-ordering query, such as SELECT ... ORDER BY x ASC, y + DESC. The NULLS options are useful if you need to support + "nulls sort low" behavior, rather than the default "nulls + sort high", in queries that depend on indexes to avoid sorting steps. +

For most index methods, the speed of creating an index is + dependent on the setting of maintenance_work_mem. + Larger values will reduce the time needed for index creation, so long + as you don't make it larger than the amount of memory really available, + which would drive the machine into swapping. For hash indexes, the + value of effective_cache_size is also relevant to + index creation time: PostgreSQL will use one + of two different hash index creation methods depending on whether the + estimated index size is more or less than effective_cache_size. + For best results, make sure that this parameter is also set to something + reflective of available memory, and be careful that the sum of + maintenance_work_mem and effective_cache_size is + less than the machine's RAM less whatever space is needed by other + programs. +

Use DROP INDEX + to remove an index. +

Prior releases of PostgreSQL also had an + R-tree index method. This method has been removed because + it had no significant advantages over the GiST method. + If USING rtree is specified, CREATE INDEX + will interpret it as USING gist, to simplify conversion + of old databases to GiST. +

Examples

To create a B-tree index on the column title in + the table films: +

CREATE UNIQUE INDEX title_idx ON films (title);

+

To create an index on the expression lower(title), + allowing efficient case-insensitive searches: +

CREATE INDEX ON films ((lower(title)));

+ (In this example we have chosen to omit the index name, so the system + will choose a name, typically films_lower_idx.) +

To create an index with non-default collation: +

CREATE INDEX title_idx_german ON films (title COLLATE "de_DE");

+

To create an index with non-default sort ordering of nulls: +

CREATE INDEX title_idx_nulls_low ON films (title NULLS FIRST);

+

To create an index with non-default fill factor: +

CREATE UNIQUE INDEX title_idx ON films (title) WITH (fillfactor = 70);

+

To create a GIN index with fast updates disabled: +

CREATE INDEX gin_idx ON documents_table USING gin (locations) WITH (fastupdate = off);

+

To create an index on the column code in the table + films and have the index reside in the tablespace + indexspace: +

CREATE INDEX code_idx ON films (code) TABLESPACE indexspace;

+

To create a GiST index on a point attribute so that we + can efficiently use box operators on the result of the + conversion function: +

CREATE INDEX pointloc
+    ON points USING gist (box(location,location));
+SELECT * FROM points
+    WHERE box(location,location) && '(0,0),(1,1)'::box;

+

To create an index without locking out writes to the table: +

CREATE INDEX CONCURRENTLY sales_quantity_index ON sales_table (quantity);

Compatibility

CREATE INDEX is a + PostgreSQL language extension. There + are no provisions for indexes in the SQL standard. +


PrevHomeNext
CREATE GROUPUpCREATE LANGUAGE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createlanguage.html b/doc/src/sgml/html/sql-createlanguage.html new file mode 100644 index 000000000..5391a4dc8 --- /dev/null +++ b/doc/src/sgml/html/sql-createlanguage.html @@ -0,0 +1,778 @@ + +CREATE LANGUAGE

CREATE LANGUAGE

Name

CREATE LANGUAGE -- define a new procedural language

Synopsis

CREATE [ OR REPLACE ] [ PROCEDURAL ] LANGUAGE name
+CREATE [ OR REPLACE ] [ TRUSTED ] [ PROCEDURAL ] LANGUAGE name
+    HANDLER call_handler [ INLINE inline_handler ] [ VALIDATOR valfunction ]

Description

CREATE LANGUAGE registers a new + procedural language with a PostgreSQL + database. Subsequently, functions and trigger procedures can be + defined in this new language. +

Note: As of PostgreSQL 9.1, most procedural + languages have been made into "extensions", and should + therefore be installed with CREATE EXTENSION + not CREATE LANGUAGE. Direct use of + CREATE LANGUAGE should now be confined to + extension installation scripts. If you have a "bare" + language in your database, perhaps as a result of an upgrade, + you can convert it to an extension using + CREATE EXTENSION langname FROM + unpackaged. +

CREATE LANGUAGE effectively associates the + language name with handler function(s) that are responsible for executing + functions written in the language. Refer to Chapter 49 + for more information about language handlers. +

There are two forms of the CREATE LANGUAGE command. + In the first form, the user supplies just the name of the desired + language, and the PostgreSQL server consults + the pg_pltemplate + system catalog to determine the correct parameters. In the second form, + the user supplies the language parameters along with the language name. + The second form can be used to create a language that is not defined in + pg_pltemplate, but this approach is considered obsolescent. +

When the server finds an entry in the pg_pltemplate catalog + for the given language name, it will use the catalog data even if the + command includes language parameters. This behavior simplifies loading of + old dump files, which are likely to contain out-of-date information + about language support functions. +

Ordinarily, the user must have the + PostgreSQL superuser privilege to + register a new language. However, the owner of a database can register + a new language within that database if the language is listed in + the pg_pltemplate catalog and is marked + as allowed to be created by database owners (tmpldbacreate + is true). The default is that trusted languages can be created + by database owners, but this can be adjusted by superusers by modifying + the contents of pg_pltemplate. + The creator of a language becomes its owner and can later + drop it, rename it, or assign it to a new owner. +

CREATE OR REPLACE LANGUAGE will either create a + new language, or replace an existing definition. If the language + already exists, its parameters are updated according to the values + specified or taken from pg_pltemplate, + but the language's ownership and permissions settings do not change, + and any existing functions written in the language are assumed to still + be valid. In addition to the normal privilege requirements for creating + a language, the user must be superuser or owner of the existing language. + The REPLACE case is mainly meant to be used to + ensure that the language exists. If the language has a + pg_pltemplate entry then REPLACE + will not actually change anything about an existing definition, except in + the unusual case where the pg_pltemplate entry + has been modified since the language was created. +

Parameters

TRUSTED

TRUSTED specifies that the language does + not grant access to data that the user would not otherwise + have. If this key word is omitted + when registering the language, only users with the + PostgreSQL superuser privilege can + use this language to create new functions. +

PROCEDURAL

This is a noise word. +

name

The name of the new procedural language. + The name must be unique among the languages in the database. +

For backward compatibility, the name can be enclosed by single + quotes. +

HANDLER call_handler

call_handler is + the name of a previously registered function that will be + called to execute the procedural language's functions. The call + handler for a procedural language must be written in a compiled + language such as C with version 1 call convention and + registered with PostgreSQL as a + function taking no arguments and returning the + language_handler type, a placeholder type that is + simply used to identify the function as a call handler. +

INLINE inline_handler

inline_handler is the + name of a previously registered function that will be called + to execute an anonymous code block + (DO command) + in this language. + If no inline_handler + function is specified, the language does not support anonymous code + blocks. + The handler function must take one argument of + type internal, which will be the DO command's + internal representation, and it will typically return + void. The return value of the handler is ignored. +

VALIDATOR valfunction

valfunction is the + name of a previously registered function that will be called + when a new function in the language is created, to validate the + new function. + If no + validator function is specified, then a new function will not + be checked when it is created. + The validator function must take one argument of + type oid, which will be the OID of the + to-be-created function, and will typically return void. +

A validator function would typically inspect the function body + for syntactical correctness, but it can also look at other + properties of the function, for example if the language cannot + handle certain argument types. To signal an error, the + validator function should use the ereport() + function. The return value of the function is ignored. +

The TRUSTED option and the support function name(s) are + ignored if the server has an entry for the specified language + name in pg_pltemplate. +

Notes

The createlang program is a simple wrapper around + the CREATE LANGUAGE command. It eases + installation of procedural languages from the shell command line. +

Use DROP LANGUAGE, or better yet the droplang program, to drop procedural languages. +

The system catalog pg_language (see Section 45.27) records information about the + currently installed languages. Also, createlang + has an option to list the installed languages. +

To create functions in a procedural language, a user must have the + USAGE privilege for the language. By default, + USAGE is granted to PUBLIC (i.e., everyone) + for trusted languages. This can be revoked if desired. +

Procedural languages are local to individual databases. + However, a language can be installed into the template1 + database, which will cause it to be available automatically in + all subsequently-created databases. +

The call handler function, the inline handler function (if any), + and the validator function (if any) + must already exist if the server does not have an entry for the language + in pg_pltemplate. But when there is an entry, + the functions need not already exist; + they will be automatically defined if not present in the database. + (This might result in CREATE LANGUAGE failing, if the + shared library that implements the language is not available in + the installation.) +

In PostgreSQL versions before 7.3, it was + necessary to declare handler functions as returning the placeholder + type opaque, rather than language_handler. + To support loading + of old dump files, CREATE LANGUAGE will accept a function + declared as returning opaque, but it will issue a notice and + change the function's declared return type to language_handler. +

Examples

The preferred way of creating any of the standard procedural languages + is just: +

CREATE LANGUAGE plperl;

+

For a language not known in the pg_pltemplate catalog, a + sequence such as this is needed: +

CREATE FUNCTION plsample_call_handler() RETURNS language_handler
+    AS '$libdir/plsample'
+    LANGUAGE C;
+CREATE LANGUAGE plsample
+    HANDLER plsample_call_handler;

Compatibility

CREATE LANGUAGE is a + PostgreSQL extension. +


PrevHomeNext
CREATE INDEXUpCREATE OPERATOR
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createopclass.html b/doc/src/sgml/html/sql-createopclass.html new file mode 100644 index 000000000..3fae2488a --- /dev/null +++ b/doc/src/sgml/html/sql-createopclass.html @@ -0,0 +1,696 @@ + +CREATE OPERATOR CLASS

CREATE OPERATOR CLASS

Name

CREATE OPERATOR CLASS -- define a new operator class

Synopsis

CREATE OPERATOR CLASS name [ DEFAULT ] FOR TYPE data_type
+  USING index_method [ FAMILY family_name ] AS
+  {  OPERATOR strategy_number operator_name [ ( op_type, op_type ) ] [ FOR SEARCH | FOR ORDER BY sort_family_name ]
+   | FUNCTION support_number [ ( op_type [ , op_type ] ) ] function_name ( argument_type [, ...] )
+   | STORAGE storage_type
+  } [, ... ]

Description

CREATE OPERATOR CLASS creates a new operator class. + An operator class defines how a particular data type can be used with + an index. The operator class specifies that certain operators will fill + particular roles or "strategies" for this data type and this + index method. The operator class also specifies the support procedures to + be used by + the index method when the operator class is selected for an + index column. All the operators and functions used by an operator + class must be defined before the operator class can be created. +

If a schema name is given then the operator class is created in the + specified schema. Otherwise it is created in the current schema. + Two operator classes in the same schema can have the same name only if they + are for different index methods. +

The user who defines an operator class becomes its owner. Presently, + the creating user must be a superuser. (This restriction is made because + an erroneous operator class definition could confuse or even crash the + server.) +

CREATE OPERATOR CLASS does not presently check + whether the operator class definition includes all the operators and + functions required by the index method, nor whether the operators and + functions form a self-consistent set. It is the user's + responsibility to define a valid operator class. +

Related operator classes can be grouped into operator + families. To add a new operator class to an existing family, + specify the FAMILY option in CREATE OPERATOR + CLASS. Without this option, the new class is placed into + a family named the same as the new class (creating that family if + it doesn't already exist). +

Refer to Section 35.14 for further information. +

Parameters

name

The name of the operator class to be created. The name can be + schema-qualified. +

DEFAULT

If present, the operator class will become the default + operator class for its data type. At most one operator class + can be the default for a specific data type and index method. +

data_type

The column data type that this operator class is for. +

index_method

The name of the index method this operator class is for. +

family_name

The name of the existing operator family to add this operator class to. + If not specified, a family named the same as the operator class is + used (creating it, if it doesn't already exist). +

strategy_number

The index method's strategy number for an operator + associated with the operator class. +

operator_name

The name (optionally schema-qualified) of an operator associated + with the operator class. +

op_type

In an OPERATOR clause, + the operand data type(s) of the operator, or NONE to + signify a left-unary or right-unary operator. The operand data + types can be omitted in the normal case where they are the same + as the operator class's data type. +

In a FUNCTION clause, the operand data type(s) the + function is intended to support, if different from + the input data type(s) of the function (for B-tree comparison functions + and hash functions) + or the class's data type (for B-tree sort support functions and all + functions in GiST, SP-GiST and GIN operator classes). These defaults + are correct, and so op_type need not be specified in + FUNCTION clauses, except for the case of a B-tree sort + support function that is meant to support cross-data-type comparisons. +

sort_family_name

The name (optionally schema-qualified) of an existing btree operator + family that describes the sort ordering associated with an ordering + operator. +

If neither FOR SEARCH nor FOR ORDER BY is + specified, FOR SEARCH is the default. +

support_number

The index method's support procedure number for a + function associated with the operator class. +

function_name

The name (optionally schema-qualified) of a function that is an + index method support procedure for the operator class. +

argument_type

The parameter data type(s) of the function. +

storage_type

The data type actually stored in the index. Normally this is + the same as the column data type, but some index methods + (currently GiST and GIN) allow it to be different. The + STORAGE clause must be omitted unless the index + method allows a different type to be used. +

The OPERATOR, FUNCTION, and STORAGE + clauses can appear in any order. +

Notes

Because the index machinery does not check access permissions on functions + before using them, including a function or operator in an operator class + is tantamount to granting public execute permission on it. This is usually + not an issue for the sorts of functions that are useful in an operator + class. +

The operators should not be defined by SQL functions. A SQL function + is likely to be inlined into the calling query, which will prevent + the optimizer from recognizing that the query matches an index. +

Before PostgreSQL 8.4, the OPERATOR + clause could include a RECHECK option. This is no longer + supported because whether an index operator is "lossy" is now + determined on-the-fly at run time. This allows efficient handling of + cases where an operator might or might not be lossy. +

Examples

The following example command defines a GiST index operator class + for the data type _int4 (array of int4). See the + intarray module for the complete example. +

CREATE OPERATOR CLASS gist__int_ops
+    DEFAULT FOR TYPE _int4 USING gist AS
+        OPERATOR        3       &&,
+        OPERATOR        6       = (anyarray, anyarray),
+        OPERATOR        7       @>,
+        OPERATOR        8       <@,
+        OPERATOR        20      @@ (_int4, query_int),
+        FUNCTION        1       g_int_consistent (internal, _int4, int, oid, internal),
+        FUNCTION        2       g_int_union (internal, internal),
+        FUNCTION        3       g_int_compress (internal),
+        FUNCTION        4       g_int_decompress (internal),
+        FUNCTION        5       g_int_penalty (internal, internal, internal),
+        FUNCTION        6       g_int_picksplit (internal, internal),
+        FUNCTION        7       g_int_same (_int4, _int4, internal);

Compatibility

CREATE OPERATOR CLASS is a + PostgreSQL extension. There is no + CREATE OPERATOR CLASS statement in the SQL + standard. +


PrevHomeNext
CREATE OPERATORUpCREATE OPERATOR FAMILY
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createoperator.html b/doc/src/sgml/html/sql-createoperator.html new file mode 100644 index 000000000..7e5e9ff52 --- /dev/null +++ b/doc/src/sgml/html/sql-createoperator.html @@ -0,0 +1,661 @@ + +CREATE OPERATOR

CREATE OPERATOR

Name

CREATE OPERATOR -- define a new operator

Synopsis

CREATE OPERATOR name (
+    PROCEDURE = function_name
+    [, LEFTARG = left_type ] [, RIGHTARG = right_type ]
+    [, COMMUTATOR = com_op ] [, NEGATOR = neg_op ]
+    [, RESTRICT = res_proc ] [, JOIN = join_proc ]
+    [, HASHES ] [, MERGES ]
+)

Description

CREATE OPERATOR defines a new operator, + name. The user who + defines an operator becomes its owner. If a schema name is given + then the operator is created in the specified schema. Otherwise it + is created in the current schema. +

The operator name is a sequence of up to NAMEDATALEN-1 + (63 by default) characters from the following list: +

+ - * / < > = ~ ! @ # % ^ & | ` ?

+ + There are a few restrictions on your choice of name: +

  • -- and /* cannot appear anywhere in an operator name, + since they will be taken as the start of a comment. +

  • A multicharacter operator name cannot end in + or + -, + unless the name also contains at least one of these characters: +

    ~ ! @ # % ^ & | ` ?

    + For example, @- is an allowed operator name, + but *- is not. + This restriction allows PostgreSQL to + parse SQL-compliant commands without requiring spaces between tokens. +

  • The use of => as an operator name is deprecated. It may + be disallowed altogether in a future release. +

+

The operator != is mapped to + <> on input, so these two names are always + equivalent. +

At least one of LEFTARG and RIGHTARG must be defined. For + binary operators, both must be defined. For right unary + operators, only LEFTARG should be defined, while for left + unary operators only RIGHTARG should be defined. +

The function_name + procedure must have been previously defined using CREATE + FUNCTION and must be defined to accept the correct number + of arguments (either one or two) of the indicated types. +

The other clauses specify optional operator optimization clauses. + Their meaning is detailed in Section 35.13. +

To be able to create an operator, you must have USAGE + privilege on the argument types and the return type, as well + as EXECUTE privilege on the underlying function. If a + commutator or negator operator is specified, you must own these operators. +

Parameters

name

The name of the operator to be defined. See above for allowable + characters. The name can be schema-qualified, for example + CREATE OPERATOR myschema.+ (...). If not, then + the operator is created in the current schema. Two operators + in the same schema can have the same name if they operate on + different data types. This is called + overloading. +

function_name

The function used to implement this operator. +

left_type

The data type of the operator's left operand, if any. + This option would be omitted for a left-unary operator. +

right_type

The data type of the operator's right operand, if any. + This option would be omitted for a right-unary operator. +

com_op

The commutator of this operator. +

neg_op

The negator of this operator. +

res_proc

The restriction selectivity estimator function for this operator. +

join_proc

The join selectivity estimator function for this operator. +

HASHES

Indicates this operator can support a hash join. +

MERGES

Indicates this operator can support a merge join. +

To give a schema-qualified operator name in com_op or the other optional + arguments, use the OPERATOR() syntax, for example: +

COMMUTATOR = OPERATOR(myschema.===) ,

Notes

Refer to Section 35.12 for further information. +

It is not possible to specify an operator's lexical precedence in + CREATE OPERATOR, because the parser's precedence behavior + is hard-wired. See Section 4.1.6 for precedence details. +

The obsolete options SORT1, SORT2, + LTCMP, and GTCMP were formerly used to + specify the names of sort operators associated with a merge-joinable + operator. This is no longer necessary, since information about + associated operators is found by looking at B-tree operator families + instead. If one of these options is given, it is ignored except + for implicitly setting MERGES true. +

Use DROP OPERATOR to delete user-defined operators + from a database. Use ALTER OPERATOR to modify operators in a + database. +

Examples

The following command defines a new operator, area-equality, for + the data type box: +

CREATE OPERATOR === (
+    LEFTARG = box,
+    RIGHTARG = box,
+    PROCEDURE = area_equal_procedure,
+    COMMUTATOR = ===,
+    NEGATOR = !==,
+    RESTRICT = area_restriction_procedure,
+    JOIN = area_join_procedure,
+    HASHES, MERGES
+);

Compatibility

CREATE OPERATOR is a + PostgreSQL extension. There are no + provisions for user-defined operators in the SQL standard. +


PrevHomeNext
CREATE LANGUAGEUpCREATE OPERATOR CLASS
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createopfamily.html b/doc/src/sgml/html/sql-createopfamily.html new file mode 100644 index 000000000..d63e80822 --- /dev/null +++ b/doc/src/sgml/html/sql-createopfamily.html @@ -0,0 +1,334 @@ + +CREATE OPERATOR FAMILY

CREATE OPERATOR FAMILY

Name

CREATE OPERATOR FAMILY -- define a new operator family

Synopsis

CREATE OPERATOR FAMILY name USING index_method

Description

CREATE OPERATOR FAMILY creates a new operator family. + An operator family defines a collection of related operator classes, + and perhaps some additional operators and support functions that are + compatible with these operator classes but not essential for the + functioning of any individual index. (Operators and functions that + are essential to indexes should be grouped within the relevant operator + class, rather than being "loose" in the operator family. + Typically, single-data-type operators are bound to operator classes, + while cross-data-type operators can be loose in an operator family + containing operator classes for both data types.) +

The new operator family is initially empty. It should be populated + by issuing subsequent CREATE OPERATOR CLASS commands + to add contained operator classes, and optionally + ALTER OPERATOR FAMILY commands to add "loose" + operators and their corresponding support functions. +

If a schema name is given then the operator family is created in the + specified schema. Otherwise it is created in the current schema. + Two operator families in the same schema can have the same name only if they + are for different index methods. +

The user who defines an operator family becomes its owner. Presently, + the creating user must be a superuser. (This restriction is made because + an erroneous operator family definition could confuse or even crash the + server.) +

Refer to Section 35.14 for further information. +

Parameters

name

The name of the operator family to be created. The name can be + schema-qualified. +

index_method

The name of the index method this operator family is for. +

Compatibility

CREATE OPERATOR FAMILY is a + PostgreSQL extension. There is no + CREATE OPERATOR FAMILY statement in the SQL + standard. +


PrevHomeNext
CREATE OPERATOR CLASSUpCREATE ROLE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createrole.html b/doc/src/sgml/html/sql-createrole.html new file mode 100644 index 000000000..ff962a310 --- /dev/null +++ b/doc/src/sgml/html/sql-createrole.html @@ -0,0 +1,1096 @@ + +CREATE ROLE

CREATE ROLE

Name

CREATE ROLE -- define a new database role

Synopsis

CREATE ROLE name [ [ WITH ] option [ ... ] ]
+
+where option can be:
+
+      SUPERUSER | NOSUPERUSER
+    | CREATEDB | NOCREATEDB
+    | CREATEROLE | NOCREATEROLE
+    | CREATEUSER | NOCREATEUSER
+    | INHERIT | NOINHERIT
+    | LOGIN | NOLOGIN
+    | REPLICATION | NOREPLICATION
+    | CONNECTION LIMIT connlimit
+    | [ ENCRYPTED | UNENCRYPTED ] PASSWORD 'password'
+    | VALID UNTIL 'timestamp'
+    | IN ROLE role_name [, ...]
+    | IN GROUP role_name [, ...]
+    | ROLE role_name [, ...]
+    | ADMIN role_name [, ...]
+    | USER role_name [, ...]
+    | SYSID uid

Description

CREATE ROLE adds a new role to a + PostgreSQL database cluster. A role is + an entity that can own database objects and have database privileges; + a role can be considered a "user", a "group", or both + depending on how it is used. Refer to + Chapter 20 and Chapter 19 for information about managing + users and authentication. You must have CREATEROLE + privilege or be a database superuser to use this command. +

Note that roles are defined at the database cluster + level, and so are valid in all databases in the cluster. +

Parameters

name

The name of the new role. +

SUPERUSER
NOSUPERUSER

These clauses determine whether the new role is a "superuser", + who can override all access restrictions within the database. + Superuser status is dangerous and should be used only when really + needed. You must yourself be a superuser to create a new superuser. + If not specified, + NOSUPERUSER is the default. +

CREATEDB
NOCREATEDB

These clauses define a role's ability to create databases. If + CREATEDB is specified, the role being + defined will be allowed to create new databases. Specifying + NOCREATEDB will deny a role the ability to + create databases. If not specified, + NOCREATEDB is the default. +

CREATEROLE
NOCREATEROLE

These clauses determine whether a role will be permitted to + create new roles (that is, execute CREATE ROLE). + A role with CREATEROLE privilege can also alter + and drop other roles. + If not specified, + NOCREATEROLE is the default. +

CREATEUSER
NOCREATEUSER

These clauses are an obsolete, but still accepted, spelling of + SUPERUSER and NOSUPERUSER. + Note that they are not equivalent to + CREATEROLE as one might naively expect! +

INHERIT
NOINHERIT

These clauses determine whether a role "inherits" the + privileges of roles it is a member of. + A role with the INHERIT attribute can automatically + use whatever database privileges have been granted to all roles + it is directly or indirectly a member of. + Without INHERIT, membership in another role + only grants the ability to SET ROLE to that other role; + the privileges of the other role are only available after having + done so. + If not specified, + INHERIT is the default. +

LOGIN
NOLOGIN

These clauses determine whether a role is allowed to log in; + that is, whether the role can be given as the initial session + authorization name during client connection. A role having + the LOGIN attribute can be thought of as a user. + Roles without this attribute are useful for managing database + privileges, but are not users in the usual sense of the word. + If not specified, + NOLOGIN is the default, except when + CREATE ROLE is invoked through its alternative spelling + CREATE USER. +

REPLICATION
NOREPLICATION

These clauses determine whether a role is allowed to initiate + streaming replication or put the system in and out of backup mode. + A role having the REPLICATION attribute is a very + highly privileged role, and should only be used on roles actually + used for replication. If not specified, + NOREPLICATION is the default. +

CONNECTION LIMIT connlimit

If role can log in, this specifies how many concurrent connections + the role can make. -1 (the default) means no limit. +

PASSWORD password

Sets the role's password. (A password is only of use for + roles having the LOGIN attribute, but you + can nonetheless define one for roles without it.) If you do + not plan to use password authentication you can omit this + option. If no password is specified, the password will be set + to null and password authentication will always fail for that + user. A null password can optionally be written explicitly as + PASSWORD NULL. +

ENCRYPTED
UNENCRYPTED

These key words control whether the password is stored + encrypted in the system catalogs. (If neither is specified, + the default behavior is determined by the configuration + parameter password_encryption.) If the + presented password string is already in MD5-encrypted format, + then it is stored encrypted as-is, regardless of whether + ENCRYPTED or UNENCRYPTED is specified + (since the system cannot decrypt the specified encrypted + password string). This allows reloading of encrypted + passwords during dump/restore. +

Note that older clients might lack support for the MD5 + authentication mechanism that is needed to work with passwords + that are stored encrypted. +

VALID UNTIL 'timestamp'

The VALID UNTIL clause sets a date and + time after which the role's password is no longer valid. If + this clause is omitted the password will be valid for all time. +

IN ROLE role_name

The IN ROLE clause lists one or more existing + roles to which the new role will be immediately added as a new + member. (Note that there is no option to add the new role as an + administrator; use a separate GRANT command to do that.) +

IN GROUP role_name

IN GROUP is an obsolete spelling of + IN ROLE. +

ROLE role_name

The ROLE clause lists one or more existing + roles which are automatically added as members of the new role. + (This in effect makes the new role a "group".) +

ADMIN role_name

The ADMIN clause is like ROLE, + but the named roles are added to the new role WITH ADMIN + OPTION, giving them the right to grant membership in this role + to others. +

USER role_name

The USER clause is an obsolete spelling of + the ROLE clause. +

SYSID uid

The SYSID clause is ignored, but is accepted + for backwards compatibility. +

Notes

Use ALTER ROLE to + change the attributes of a role, and DROP ROLE + to remove a role. All the attributes + specified by CREATE ROLE can be modified by later + ALTER ROLE commands. +

The preferred way to add and remove members of roles that are being + used as groups is to use + GRANT and + REVOKE. +

The VALID UNTIL clause defines an expiration time for a + password only, not for the role per se. In + particular, the expiration time is not enforced when logging in using + a non-password-based authentication method. +

The INHERIT attribute governs inheritance of grantable + privileges (that is, access privileges for database objects and role + memberships). It does not apply to the special role attributes set by + CREATE ROLE and ALTER ROLE. For example, being + a member of a role with CREATEDB privilege does not immediately + grant the ability to create databases, even if INHERIT is set; + it would be necessary to become that role via + SET ROLE before + creating a database. +

The INHERIT attribute is the default for reasons of backwards + compatibility: in prior releases of PostgreSQL, + users always had access to all privileges of groups they were members of. + However, NOINHERIT provides a closer match to the semantics + specified in the SQL standard. +

Be careful with the CREATEROLE privilege. There is no concept of + inheritance for the privileges of a CREATEROLE-role. That + means that even if a role does not have a certain privilege but is allowed + to create other roles, it can easily create another role with different + privileges than its own (except for creating roles with superuser + privileges). For example, if the role "user" has the + CREATEROLE privilege but not the CREATEDB privilege, + nonetheless it can create a new role with the CREATEDB + privilege. Therefore, regard roles that have the CREATEROLE + privilege as almost-superuser-roles. +

PostgreSQL includes a program createuser that has + the same functionality as CREATE ROLE (in fact, + it calls this command) but can be run from the command shell. +

The CONNECTION LIMIT option is only enforced approximately; + if two new sessions start at about the same time when just one + connection "slot" remains for the role, it is possible that + both will fail. Also, the limit is never enforced for superusers. +

Caution must be exercised when specifying an unencrypted password + with this command. The password will be transmitted to the server + in cleartext, and it might also be logged in the client's command + history or the server log. The command createuser, however, transmits + the password encrypted. Also, psql + contains a command + \password that can be used to safely change the + password later. +

Examples

Create a role that can log in, but don't give it a password: +

CREATE ROLE jonathan LOGIN;

+

Create a role with a password: +

CREATE USER davide WITH PASSWORD 'jw8s0F4';

+ (CREATE USER is the same as CREATE ROLE except + that it implies LOGIN.) +

Create a role with a password that is valid until the end of 2004. + After one second has ticked in 2005, the password is no longer + valid. + +

CREATE ROLE miriam WITH LOGIN PASSWORD 'jw8s0F4' VALID UNTIL '2005-01-01';

+

Create a role that can create databases and manage roles: +

CREATE ROLE admin WITH CREATEDB CREATEROLE;

Compatibility

The CREATE ROLE statement is in the SQL standard, + but the standard only requires the syntax +

CREATE ROLE name [ WITH ADMIN role_name ]

+ Multiple initial administrators, and all the other options of + CREATE ROLE, are + PostgreSQL extensions. +

The SQL standard defines the concepts of users and roles, but it + regards them as distinct concepts and leaves all commands defining + users to be specified by each database implementation. In + PostgreSQL we have chosen to unify + users and roles into a single kind of entity. Roles therefore + have many more optional attributes than they do in the standard. +

The behavior specified by the SQL standard is most closely approximated + by giving users the NOINHERIT attribute, while roles are + given the INHERIT attribute. +


PrevHomeNext
CREATE OPERATOR FAMILYUpCREATE RULE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createrule.html b/doc/src/sgml/html/sql-createrule.html new file mode 100644 index 000000000..44968f3d5 --- /dev/null +++ b/doc/src/sgml/html/sql-createrule.html @@ -0,0 +1,749 @@ + +CREATE RULE

CREATE RULE

Name

CREATE RULE -- define a new rewrite rule

Synopsis

CREATE [ OR REPLACE ] RULE name AS ON event
+    TO table_name [ WHERE condition ]
+    DO [ ALSO | INSTEAD ] { NOTHING | command | ( command ; command ... ) }

Description

CREATE RULE defines a new rule applying to a specified + table or view. + CREATE OR REPLACE RULE will either create a + new rule, or replace an existing rule of the same name for the same + table. +

The PostgreSQL rule system allows one to + define an alternative action to be performed on insertions, updates, + or deletions in database tables. Roughly speaking, a rule causes + additional commands to be executed when a given command on a given + table is executed. Alternatively, an INSTEAD + rule can replace a given command by another, or cause a command + not to be executed at all. Rules are used to implement table + views as well. It is important to realize that a rule is really + a command transformation mechanism, or command macro. The + transformation happens before the execution of the commands starts. + If you actually want an operation that fires independently for each + physical row, you probably want to use a trigger, not a rule. + More information about the rules system is in Chapter 37. +

Presently, ON SELECT rules must be unconditional + INSTEAD rules and must have actions that consist + of a single SELECT command. Thus, an + ON SELECT rule effectively turns the table into + a view, whose visible contents are the rows returned by the rule's + SELECT command rather than whatever had been + stored in the table (if anything). It is considered better style + to write a CREATE VIEW command than to create a + real table and define an ON SELECT rule for it. +

You can create the illusion of an updatable view by defining + ON INSERT, ON UPDATE, and + ON DELETE rules (or any subset of those that's + sufficient for your purposes) to replace update actions on the view + with appropriate updates on other tables. If you want to support + INSERT RETURNING and so on, then be sure to put a suitable + RETURNING clause into each of these rules. Alternatively, + an updatable view can be implemented using INSTEAD OF + triggers (see CREATE TRIGGER). +

There is a catch if you try to use conditional rules for view + updates: there must be an unconditional + INSTEAD rule for each action you wish to allow + on the view. If the rule is conditional, or is not + INSTEAD, then the system will still reject + attempts to perform the update action, because it thinks it might + end up trying to perform the action on the dummy table of the view + in some cases. If you want to handle all the useful cases in + conditional rules, add an unconditional DO + INSTEAD NOTHING rule to ensure that the system + understands it will never be called on to update the dummy table. + Then make the conditional rules non-INSTEAD; in + the cases where they are applied, they add to the default + INSTEAD NOTHING action. (This method does not + currently work to support RETURNING queries, however.) +

Parameters

name

The name of a rule to create. This must be distinct from the + name of any other rule for the same table. Multiple rules on + the same table and same event type are applied in alphabetical + name order. +

event

The event is one of SELECT, + INSERT, UPDATE, or + DELETE. +

table_name

The name (optionally schema-qualified) of the table or view the + rule applies to. +

condition

Any SQL conditional expression (returning + boolean). The condition expression cannot refer + to any tables except NEW and OLD, and + cannot contain aggregate functions. +

INSTEAD

INSTEAD indicates that the commands should be + executed instead of the original command. +

ALSO

ALSO indicates that the commands should be + executed in addition to the original + command. +

If neither ALSO nor + INSTEAD is specified, ALSO + is the default. +

command

The command or commands that make up the rule action. Valid + commands are SELECT, + INSERT, UPDATE, + DELETE, or NOTIFY. +

Within condition and + command, the special + table names NEW and OLD can + be used to refer to values in the referenced table. + NEW is valid in ON INSERT and + ON UPDATE rules to refer to the new row being + inserted or updated. OLD is valid in + ON UPDATE and ON DELETE rules + to refer to the existing row being updated or deleted. +

Notes

You must be the owner of a table to create or change rules for it. +

In a rule for INSERT, UPDATE, or + DELETE on a view, you can add a RETURNING + clause that emits the view's columns. This clause will be used to compute + the outputs if the rule is triggered by an INSERT RETURNING, + UPDATE RETURNING, or DELETE RETURNING command + respectively. When the rule is triggered by a command without + RETURNING, the rule's RETURNING clause will be + ignored. The current implementation allows only unconditional + INSTEAD rules to contain RETURNING; furthermore + there can be at most one RETURNING clause among all the rules + for the same event. (This ensures that there is only one candidate + RETURNING clause to be used to compute the results.) + RETURNING queries on the view will be rejected if + there is no RETURNING clause in any available rule. +

It is very important to take care to avoid circular rules. For + example, though each of the following two rule definitions are + accepted by PostgreSQL, the + SELECT command would cause + PostgreSQL to report an error because + of recursive expansion of a rule: + +

CREATE RULE "_RETURN" AS
+    ON SELECT TO t1
+    DO INSTEAD
+        SELECT * FROM t2;
+
+CREATE RULE "_RETURN" AS
+    ON SELECT TO t2
+    DO INSTEAD
+        SELECT * FROM t1;
+
+SELECT * FROM t1;

+

Presently, if a rule action contains a NOTIFY + command, the NOTIFY command will be executed + unconditionally, that is, the NOTIFY will be + issued even if there are not any rows that the rule should apply + to. For example, in: +

CREATE RULE notify_me AS ON UPDATE TO mytable DO ALSO NOTIFY mytable;
+
+UPDATE mytable SET name = 'foo' WHERE id = 42;

+ one NOTIFY event will be sent during the + UPDATE, whether or not there are any rows that + match the condition id = 42. This is an + implementation restriction that might be fixed in future releases. +

Compatibility

CREATE RULE is a + PostgreSQL language extension, as is the + entire query rewrite system. +


PrevHomeNext
CREATE ROLEUpCREATE SCHEMA
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createschema.html b/doc/src/sgml/html/sql-createschema.html new file mode 100644 index 000000000..d45d5ebc2 --- /dev/null +++ b/doc/src/sgml/html/sql-createschema.html @@ -0,0 +1,477 @@ + +CREATE SCHEMA

CREATE SCHEMA

Name

CREATE SCHEMA -- define a new schema

Synopsis

CREATE SCHEMA schema_name [ AUTHORIZATION user_name ] [ schema_element [ ... ] ]
+CREATE SCHEMA AUTHORIZATION user_name [ schema_element [ ... ] ]

Description

CREATE SCHEMA enters a new schema + into the current database. + The schema name must be distinct from the name of any existing schema + in the current database. +

A schema is essentially a namespace: + it contains named objects (tables, data types, functions, and operators) + whose names can duplicate those of other objects existing in other + schemas. Named objects are accessed either by "qualifying" + their names with the schema name as a prefix, or by setting a search + path that includes the desired schema(s). A CREATE command + specifying an unqualified object name creates the object + in the current schema (the one at the front of the search path, + which can be determined with the function current_schema). +

Optionally, CREATE SCHEMA can include subcommands + to create objects within the new schema. The subcommands are treated + essentially the same as separate commands issued after creating the + schema, except that if the AUTHORIZATION clause is used, + all the created objects will be owned by that user. +

Parameters

schema_name

The name of a schema to be created. If this is omitted, the + user_name + is used as the schema name. The name cannot + begin with pg_, as such names + are reserved for system schemas. +

user_name

The role name of the user who will own the new schema. If omitted, + defaults to the user executing the command. To create a schema + owned by another role, you must be a direct or indirect member of + that role, or be a superuser. +

schema_element

An SQL statement defining an object to be created within the + schema. Currently, only CREATE + TABLE, CREATE VIEW, CREATE + INDEX, CREATE SEQUENCE, CREATE + TRIGGER and GRANT are accepted as clauses + within CREATE SCHEMA. Other kinds of objects may + be created in separate commands after the schema is created. +

Notes

To create a schema, the invoking user must have the + CREATE privilege for the current database. + (Of course, superusers bypass this check.) +

Examples

Create a schema: +

CREATE SCHEMA myschema;

+

Create a schema for user joe; the schema will also be + named joe: +

CREATE SCHEMA AUTHORIZATION joe;

+

Create a schema and create a table and view within it: +

CREATE SCHEMA hollywood
+    CREATE TABLE films (title text, release date, awards text[])
+    CREATE VIEW winners AS
+        SELECT title, release FROM films WHERE awards IS NOT NULL;

+ Notice that the individual subcommands do not end with semicolons. +

The following is an equivalent way of accomplishing the same result: +

CREATE SCHEMA hollywood;
+CREATE TABLE hollywood.films (title text, release date, awards text[]);
+CREATE VIEW hollywood.winners AS
+    SELECT title, release FROM hollywood.films WHERE awards IS NOT NULL;

Compatibility

The SQL standard allows a DEFAULT CHARACTER SET clause + in CREATE SCHEMA, as well as more subcommand + types than are presently accepted by + PostgreSQL. +

The SQL standard specifies that the subcommands in CREATE + SCHEMA can appear in any order. The present + PostgreSQL implementation does not + handle all cases of forward references in subcommands; it might + sometimes be necessary to reorder the subcommands in order to avoid + forward references. +

According to the SQL standard, the owner of a schema always owns + all objects within it. PostgreSQL + allows schemas to contain objects owned by users other than the + schema owner. This can happen only if the schema owner grants the + CREATE privilege on his schema to someone else, or a + superuser chooses to create objects in it. +


PrevHomeNext
CREATE RULEUpCREATE SEQUENCE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createsequence.html b/doc/src/sgml/html/sql-createsequence.html new file mode 100644 index 000000000..39cd62cd2 --- /dev/null +++ b/doc/src/sgml/html/sql-createsequence.html @@ -0,0 +1,836 @@ + +CREATE SEQUENCE

CREATE SEQUENCE

Name

CREATE SEQUENCE -- define a new sequence generator

Synopsis

CREATE [ TEMPORARY | TEMP ] SEQUENCE name [ INCREMENT [ BY ] increment ]
+    [ MINVALUE minvalue | NO MINVALUE ] [ MAXVALUE maxvalue | NO MAXVALUE ]
+    [ START [ WITH ] start ] [ CACHE cache ] [ [ NO ] CYCLE ]
+    [ OWNED BY { table_name.column_name | NONE } ]

Description

CREATE SEQUENCE creates a new sequence number + generator. This involves creating and initializing a new special + single-row table with the name name. The generator will be + owned by the user issuing the command. +

If a schema name is given then the sequence is created in the + specified schema. Otherwise it is created in the current schema. + Temporary sequences exist in a special schema, so a schema name cannot be + given when creating a temporary sequence. + The sequence name must be distinct from the name of any other sequence, + table, index, view, or foreign table in the same schema. +

After a sequence is created, you use the functions + nextval, + currval, and + setval + to operate on the sequence. These functions are documented in + Section 9.16. +

Although you cannot update a sequence directly, you can use a query like: + +

SELECT * FROM name;

+ + to examine the parameters and current state of a sequence. In particular, + the last_value field of the sequence shows the last value + allocated by any session. (Of course, this value might be obsolete + by the time it's printed, if other sessions are actively doing + nextval calls.) +

Parameters

TEMPORARY or TEMP

If specified, the sequence object is created only for this + session, and is automatically dropped on session exit. Existing + permanent sequences with the same name are not visible (in this + session) while the temporary sequence exists, unless they are + referenced with schema-qualified names. +

name

The name (optionally schema-qualified) of the sequence to be created. +

increment

The optional clause INCREMENT BY increment specifies + which value is added to the current sequence value to create a + new value. A positive value will make an ascending sequence, a + negative one a descending sequence. The default value is 1. +

minvalue
NO MINVALUE

The optional clause MINVALUE minvalue determines + the minimum value a sequence can generate. If this clause is not + supplied or NO MINVALUE is specified, then + defaults will be used. The defaults are 1 and + -263-1 for ascending and descending sequences, + respectively. +

maxvalue
NO MAXVALUE

The optional clause MAXVALUE maxvalue determines + the maximum value for the sequence. If this clause is not + supplied or NO MAXVALUE is specified, then + default values will be used. The defaults are + 263-1 and -1 for ascending and descending + sequences, respectively. +

start

The optional clause START WITH start allows the + sequence to begin anywhere. The default starting value is + minvalue for + ascending sequences and maxvalue for descending ones. +

cache

The optional clause CACHE cache specifies how + many sequence numbers are to be preallocated and stored in + memory for faster access. The minimum value is 1 (only one value + can be generated at a time, i.e., no cache), and this is also the + default. +

CYCLE
NO CYCLE

The CYCLE option allows the sequence to wrap + around when the maxvalue or minvalue has been reached by an + ascending or descending sequence respectively. If the limit is + reached, the next number generated will be the minvalue or maxvalue, respectively. +

If NO CYCLE is specified, any calls to + nextval after the sequence has reached its + maximum value will return an error. If neither + CYCLE or NO CYCLE are + specified, NO CYCLE is the default. +

OWNED BY table_name.column_name
OWNED BY NONE

The OWNED BY option causes the sequence to be + associated with a specific table column, such that if that column + (or its whole table) is dropped, the sequence will be automatically + dropped as well. The specified table must have the same owner and be in + the same schema as the sequence. + OWNED BY NONE, the default, specifies that there + is no such association. +

Notes

Use DROP SEQUENCE to remove a sequence. +

Sequences are based on bigint arithmetic, so the range + cannot exceed the range of an eight-byte integer + (-9223372036854775808 to 9223372036854775807). On some older + platforms, there might be no compiler support for eight-byte + integers, in which case sequences use regular integer + arithmetic (range -2147483648 to +2147483647). +

Unexpected results might be obtained if a cache setting greater than one is + used for a sequence object that will be used concurrently by + multiple sessions. Each session will allocate and cache successive + sequence values during one access to the sequence object and + increase the sequence object's last_value accordingly. + Then, the next cache-1 + uses of nextval within that session simply return the + preallocated values without touching the sequence object. So, any + numbers allocated but not used within a session will be lost when + that session ends, resulting in "holes" in the + sequence. +

Furthermore, although multiple sessions are guaranteed to allocate + distinct sequence values, the values might be generated out of + sequence when all the sessions are considered. For example, with + a cache setting of 10, + session A might reserve values 1..10 and return + nextval=1, then session B might reserve values + 11..20 and return nextval=11 before session A + has generated nextval=2. Thus, with a + cache setting of one + it is safe to assume that nextval values are generated + sequentially; with a cache setting greater than one you + should only assume that the nextval values are all + distinct, not that they are generated purely sequentially. Also, + last_value will reflect the latest value reserved by + any session, whether or not it has yet been returned by + nextval. +

Another consideration is that a setval executed on + such a sequence will not be noticed by other sessions until they + have used up any preallocated values they have cached. +

Examples

Create an ascending sequence called serial, starting at 101: +

CREATE SEQUENCE serial START 101;

+

Select the next number from this sequence: +

SELECT nextval('serial');
+
+ nextval
+---------
+     101

+

Select the next number from this sequence: +

SELECT nextval('serial');
+
+ nextval
+---------
+     102

+

Use this sequence in an INSERT command: +

INSERT INTO distributors VALUES (nextval('serial'), 'nothing');

+

Update the sequence value after a COPY FROM: +

BEGIN;
+COPY distributors FROM 'input_file';
+SELECT setval('serial', max(id)) FROM distributors;
+END;

Compatibility

CREATE SEQUENCE conforms to the SQL + standard, with the following exceptions: +

  • The standard's AS <data type> expression is not + supported. +

  • Obtaining the next value is done using the nextval() + function instead of the standard's NEXT VALUE FOR + expression. +

  • The OWNED BY clause is a PostgreSQL + extension. +


PrevHomeNext
CREATE SCHEMAUpCREATE SERVER
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createserver.html b/doc/src/sgml/html/sql-createserver.html new file mode 100644 index 000000000..947a29bba --- /dev/null +++ b/doc/src/sgml/html/sql-createserver.html @@ -0,0 +1,425 @@ + +CREATE SERVER

CREATE SERVER

Name

CREATE SERVER -- define a new foreign server

Synopsis

CREATE SERVER server_name [ TYPE 'server_type' ] [ VERSION 'server_version' ]
+    FOREIGN DATA WRAPPER fdw_name
+    [ OPTIONS ( option 'value' [, ... ] ) ]

Description

CREATE SERVER defines a new foreign server. The + user who defines the server becomes its owner. +

A foreign server typically encapsulates connection information that + a foreign-data wrapper uses to access an external data resource. + Additional user-specific connection information may be specified by + means of user mappings. +

The server name must be unique within the database. +

Creating a server requires USAGE privilege on the + foreign-data wrapper being used. +

Parameters

server_name

The name of the foreign server to be created. +

server_type

Optional server type. +

server_version

Optional server version. +

fdw_name

The name of the foreign-data wrapper that manages the server. +

OPTIONS ( option 'value' [, ... ] )

This clause specifies the options for the server. The options + typically define the connection details of the server, but the + actual names and values are dependent on the server's + foreign-data wrapper. +

Notes

When using the dblink module + (see dblink), the foreign server name can be used + as an argument of the dblink_connect + function to indicate the connection parameters. See also there for + more examples. It is necessary to have + the USAGE privilege on the foreign server to be + able to use it in this way. +

Examples

Create a server foo that uses the built-in foreign-data + wrapper default: +

CREATE SERVER foo FOREIGN DATA WRAPPER "default";

+

Create a server myserver that uses the + foreign-data wrapper pgsql: +

CREATE SERVER myserver FOREIGN DATA WRAPPER pgsql OPTIONS (host 'foo', dbname 'foodb', port '5432');

Compatibility

CREATE SERVER conforms to ISO/IEC 9075-9 (SQL/MED). +


PrevHomeNext
CREATE SEQUENCEUpCREATE TABLE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createtable.html b/doc/src/sgml/html/sql-createtable.html new file mode 100644 index 000000000..86427f6dc --- /dev/null +++ b/doc/src/sgml/html/sql-createtable.html @@ -0,0 +1,2927 @@ + +CREATE TABLE

CREATE TABLE

Name

CREATE TABLE -- define a new table

Synopsis

CREATE [ [ GLOBAL | LOCAL ] { TEMPORARY | TEMP } | UNLOGGED ] TABLE [ IF NOT EXISTS ] table_name ( [
+  { column_name data_type [ COLLATE collation ] [ column_constraint [ ... ] ]
+    | table_constraint
+    | LIKE source_table [ like_option ... ] }
+    [, ... ]
+] )
+[ INHERITS ( parent_table [, ... ] ) ]
+[ WITH ( storage_parameter [= value] [, ... ] ) | WITH OIDS | WITHOUT OIDS ]
+[ ON COMMIT { PRESERVE ROWS | DELETE ROWS | DROP } ]
+[ TABLESPACE tablespace_name ]
+
+CREATE [ [ GLOBAL | LOCAL ] { TEMPORARY | TEMP } | UNLOGGED ] TABLE [ IF NOT EXISTS ] table_name
+    OF type_name [ (
+  { column_name WITH OPTIONS [ column_constraint [ ... ] ]
+    | table_constraint }
+    [, ... ]
+) ]
+[ WITH ( storage_parameter [= value] [, ... ] ) | WITH OIDS | WITHOUT OIDS ]
+[ ON COMMIT { PRESERVE ROWS | DELETE ROWS | DROP } ]
+[ TABLESPACE tablespace_name ]
+
+where column_constraint is:
+
+[ CONSTRAINT constraint_name ]
+{ NOT NULL |
+  NULL |
+  CHECK ( expression ) [ NO INHERIT ] |
+  DEFAULT default_expr |
+  UNIQUE index_parameters |
+  PRIMARY KEY index_parameters |
+  REFERENCES reftable [ ( refcolumn ) ] [ MATCH FULL | MATCH PARTIAL | MATCH SIMPLE ]
+    [ ON DELETE action ] [ ON UPDATE action ] }
+[ DEFERRABLE | NOT DEFERRABLE ] [ INITIALLY DEFERRED | INITIALLY IMMEDIATE ]
+
+and table_constraint is:
+
+[ CONSTRAINT constraint_name ]
+{ CHECK ( expression ) [ NO INHERIT ] |
+  UNIQUE ( column_name [, ... ] ) index_parameters |
+  PRIMARY KEY ( column_name [, ... ] ) index_parameters |
+  EXCLUDE [ USING index_method ] ( exclude_element WITH operator [, ... ] ) index_parameters [ WHERE ( predicate ) ] |
+  FOREIGN KEY ( column_name [, ... ] ) REFERENCES reftable [ ( refcolumn [, ... ] ) ]
+    [ MATCH FULL | MATCH PARTIAL | MATCH SIMPLE ] [ ON DELETE action ] [ ON UPDATE action ] }
+[ DEFERRABLE | NOT DEFERRABLE ] [ INITIALLY DEFERRED | INITIALLY IMMEDIATE ]
+
+and like_option is:
+
+{ INCLUDING | EXCLUDING } { DEFAULTS | CONSTRAINTS | INDEXES | STORAGE | COMMENTS | ALL }
+
+index_parameters in UNIQUE, PRIMARY KEY, and EXCLUDE constraints are:
+
+[ WITH ( storage_parameter [= value] [, ... ] ) ]
+[ USING INDEX TABLESPACE tablespace_name ]
+
+exclude_element in an EXCLUDE constraint is:
+
+{ column_name | ( expression ) } [ opclass ] [ ASC | DESC ] [ NULLS { FIRST | LAST } ]

Description

CREATE TABLE will create a new, initially empty table + in the current database. The table will be owned by the user issuing the + command. +

If a schema name is given (for example, CREATE TABLE + myschema.mytable ...) then the table is created in the specified + schema. Otherwise it is created in the current schema. Temporary + tables exist in a special schema, so a schema name cannot be given + when creating a temporary table. The name of the table must be + distinct from the name of any other table, sequence, index, view, + or foreign table in the same schema. +

CREATE TABLE also automatically creates a data + type that represents the composite type corresponding + to one row of the table. Therefore, tables cannot have the same + name as any existing data type in the same schema. +

The optional constraint clauses specify constraints (tests) that + new or updated rows must satisfy for an insert or update operation + to succeed. A constraint is an SQL object that helps define the + set of valid values in the table in various ways. +

There are two ways to define constraints: table constraints and + column constraints. A column constraint is defined as part of a + column definition. A table constraint definition is not tied to a + particular column, and it can encompass more than one column. + Every column constraint can also be written as a table constraint; + a column constraint is only a notational convenience for use when the + constraint only affects one column. +

To be able to create a table, you must have USAGE + privilege on all column types or the type in the OF + clause, respectively. +

Parameters

TEMPORARY or TEMP

If specified, the table is created as a temporary table. + Temporary tables are automatically dropped at the end of a + session, or optionally at the end of the current transaction + (see ON COMMIT below). Existing permanent + tables with the same name are not visible to the current session + while the temporary table exists, unless they are referenced + with schema-qualified names. Any indexes created on a temporary + table are automatically temporary as well. +

The autovacuum daemon cannot + access and therefore cannot vacuum or analyze temporary tables. + For this reason, appropriate vacuum and analyze operations should be + performed via session SQL commands. For example, if a temporary + table is going to be used in complex queries, it is wise to run + ANALYZE on the temporary table after it is populated. +

Optionally, GLOBAL or LOCAL + can be written before TEMPORARY or TEMP. + This presently makes no difference in PostgreSQL + and is deprecated; see + Compatibility. +

UNLOGGED

If specified, the table is created as an unlogged table. Data written + to unlogged tables is not written to the write-ahead log (see Chapter 29), which makes them considerably faster than ordinary + tables. However, they are not crash-safe: an unlogged table is + automatically truncated after a crash or unclean shutdown. The contents + of an unlogged table are also not replicated to standby servers. + Any indexes created on an unlogged table are automatically unlogged as + well; however, unlogged GiST indexes are + currently not supported and cannot be created on an unlogged table. +

IF NOT EXISTS

Do not throw an error if a relation with the same name already exists. + A notice is issued in this case. Note that there is no guarantee that + the existing relation is anything like the one that would have been + created. +

table_name

The name (optionally schema-qualified) of the table to be created. +

OF type_name

Creates a typed table, which takes its + structure from the specified composite type (name optionally + schema-qualified). A typed table is tied to its type; for + example the table will be dropped if the type is dropped + (with DROP TYPE ... CASCADE). +

When a typed table is created, then the data types of the + columns are determined by the underlying composite type and are + not specified by the CREATE TABLE command. + But the CREATE TABLE command can add defaults + and constraints to the table and can specify storage parameters. +

column_name

The name of a column to be created in the new table. +

data_type

The data type of the column. This can include array + specifiers. For more information on the data types supported by + PostgreSQL, refer to Chapter 8. +

COLLATE collation

The COLLATE clause assigns a collation to + the column (which must be of a collatable data type). + If not specified, the column data type's default collation is used. +

INHERITS ( parent_table [, ... ] )

The optional INHERITS clause specifies a list of + tables from which the new table automatically inherits all + columns. +

Use of INHERITS creates a persistent relationship + between the new child table and its parent table(s). Schema + modifications to the parent(s) normally propagate to children + as well, and by default the data of the child table is included in + scans of the parent(s). +

If the same column name exists in more than one parent + table, an error is reported unless the data types of the columns + match in each of the parent tables. If there is no conflict, + then the duplicate columns are merged to form a single column in + the new table. If the column name list of the new table + contains a column name that is also inherited, the data type must + likewise match the inherited column(s), and the column + definitions are merged into one. If the + new table explicitly specifies a default value for the column, + this default overrides any defaults from inherited declarations + of the column. Otherwise, any parents that specify default + values for the column must all specify the same default, or an + error will be reported. +

CHECK constraints are merged in essentially the same way as + columns: if multiple parent tables and/or the new table definition + contain identically-named CHECK constraints, these + constraints must all have the same check expression, or an error will be + reported. Constraints having the same name and expression will + be merged into one copy. A constraint marked NO INHERIT in a + parent will not be considered. Notice that an unnamed CHECK + constraint in the new table will never be merged, since a unique name + will always be chosen for it. +

Column STORAGE settings are also copied from parent tables. +

LIKE source_table [ like_option ... ]

The LIKE clause specifies a table from which + the new table automatically copies all column names, their data types, + and their not-null constraints. +

Unlike INHERITS, the new table and original table + are completely decoupled after creation is complete. Changes to the + original table will not be applied to the new table, and it is not + possible to include data of the new table in scans of the original + table. +

Default expressions for the copied column definitions will only be + copied if INCLUDING DEFAULTS is specified. The + default behavior is to exclude default expressions, resulting in the + copied columns in the new table having null defaults. +

Not-null constraints are always copied to the new table. + CHECK constraints will only be copied if + INCLUDING CONSTRAINTS is specified; other types of + constraints will never be copied. Also, no distinction is made between + column constraints and table constraints — when constraints are + requested, all check constraints are copied. +

Any indexes on the original table will not be created on the new + table, unless the INCLUDING INDEXES clause is + specified. +

STORAGE settings for the copied column definitions will only + be copied if INCLUDING STORAGE is specified. The + default behavior is to exclude STORAGE settings, resulting + in the copied columns in the new table having type-specific default + settings. For more on STORAGE settings, see + Section 56.2. +

Comments for the copied columns, constraints, and indexes + will only be copied if INCLUDING COMMENTS + is specified. The default behavior is to exclude comments, resulting in + the copied columns and constraints in the new table having no comments. +

INCLUDING ALL is an abbreviated form of + INCLUDING DEFAULTS INCLUDING CONSTRAINTS INCLUDING INDEXES INCLUDING STORAGE INCLUDING COMMENTS. +

Note also that unlike INHERITS, columns and + constraints copied by LIKE are not merged with similarly + named columns and constraints. + If the same name is specified explicitly or in another + LIKE clause, an error is signalled. +

The LIKE clause can also be used to copy columns from + views, foreign tables, or composite types. Inapplicable options (e.g., INCLUDING + INDEXES from a view) are ignored. +

CONSTRAINT constraint_name

An optional name for a column or table constraint. If the + constraint is violated, the constraint name is present in error messages, + so constraint names like col must be positive can be used + to communicate helpful constraint information to client applications. + (Double-quotes are needed to specify constraint names that contain spaces.) + If a constraint name is not specified, the system generates a name. +

NOT NULL

The column is not allowed to contain null values. +

NULL

The column is allowed to contain null values. This is the default. +

This clause is only provided for compatibility with + non-standard SQL databases. Its use is discouraged in new + applications. +

CHECK ( expression ) [ NO INHERIT ]

The CHECK clause specifies an expression producing a + Boolean result which new or updated rows must satisfy for an + insert or update operation to succeed. Expressions evaluating + to TRUE or UNKNOWN succeed. Should any row of an insert or + update operation produce a FALSE result an error exception is + raised and the insert or update does not alter the database. A + check constraint specified as a column constraint should + reference that column's value only, while an expression + appearing in a table constraint can reference multiple columns. +

Currently, CHECK expressions cannot contain + subqueries nor refer to variables other than columns of the + current row. +

A constraint marked with NO INHERIT will not propagate to + child tables. +

DEFAULT + default_expr

The DEFAULT clause assigns a default data value for + the column whose column definition it appears within. The value + is any variable-free expression (subqueries and cross-references + to other columns in the current table are not allowed). The + data type of the default expression must match the data type of the + column. +

The default expression will be used in any insert operation that + does not specify a value for the column. If there is no default + for a column, then the default is null. +

UNIQUE (column constraint)
UNIQUE ( column_name [, ... ] ) (table constraint)

The UNIQUE constraint specifies that a + group of one or more columns of a table can contain + only unique values. The behavior of the unique table constraint + is the same as that for column constraints, with the additional + capability to span multiple columns. +

For the purpose of a unique constraint, null values are not + considered equal. +

Each unique table constraint must name a set of columns that is + different from the set of columns named by any other unique or + primary key constraint defined for the table. (Otherwise it + would just be the same constraint listed twice.) +

PRIMARY KEY (column constraint)
PRIMARY KEY ( column_name [, ... ] ) (table constraint)

The primary key constraint specifies that a column or columns of a table + can contain only unique (non-duplicate), nonnull values. + Technically, PRIMARY KEY is merely a + combination of UNIQUE and NOT NULL, but + identifying a set of columns as primary key also provides + metadata about the design of the schema, as a primary key + implies that other tables + can rely on this set of columns as a unique identifier for rows. +

Only one primary key can be specified for a table, whether as a + column constraint or a table constraint. +

The primary key constraint should name a set of columns that is + different from other sets of columns named by any unique + constraint defined for the same table. +

EXCLUDE [ USING index_method ] ( exclude_element WITH operator [, ... ] ) index_parameters [ WHERE ( predicate ) ]

The EXCLUDE clause defines an exclusion + constraint, which guarantees that if + any two rows are compared on the specified column(s) or + expression(s) using the specified operator(s), not all of these + comparisons will return TRUE. If all of the + specified operators test for equality, this is equivalent to a + UNIQUE constraint, although an ordinary unique constraint + will be faster. However, exclusion constraints can specify + constraints that are more general than simple equality. + For example, you can specify a constraint that + no two rows in the table contain overlapping circles + (see Section 8.8) by using the + && operator. +

Exclusion constraints are implemented using + an index, so each specified operator must be associated with an + appropriate operator class + (see Section 11.9) for the index access + method index_method. + The operators are required to be commutative. + Each exclude_element + can optionally specify an operator class and/or ordering options; + these are described fully under + CREATE INDEX. +

The access method must support amgettuple (see Chapter 52); at present this means GIN + cannot be used. Although it's allowed, there is little point in using + B-tree or hash indexes with an exclusion constraint, because this + does nothing that an ordinary unique constraint doesn't do better. + So in practice the access method will always be GiST or + SP-GiST. +

The predicate allows you to specify an + exclusion constraint on a subset of the table; internally this creates a + partial index. Note that parentheses are required around the predicate. +

REFERENCES reftable [ ( refcolumn ) ] [ MATCH matchtype ] [ ON DELETE action ] [ ON UPDATE action ] (column constraint)
FOREIGN KEY ( column_name [, ... ] ) + REFERENCES reftable [ ( refcolumn [, ... ] ) ] + [ MATCH matchtype ] + [ ON DELETE action ] + [ ON UPDATE action ] + (table constraint)

These clauses specify a foreign key constraint, which requires + that a group of one or more columns of the new table must only + contain values that match values in the referenced + column(s) of some row of the referenced table. If refcolumn is omitted, the + primary key of the reftable + is used. The referenced columns must be the columns of a non-deferrable + unique or primary key constraint in the referenced table. Note that + foreign key constraints cannot be defined between temporary tables and + permanent tables. +

A value inserted into the referencing column(s) is matched against the + values of the referenced table and referenced columns using the + given match type. There are three match types: MATCH + FULL, MATCH PARTIAL, and MATCH + SIMPLE, which is also the default. MATCH + FULL will not allow one column of a multicolumn foreign key + to be null unless all foreign key columns are null. + MATCH SIMPLE allows some foreign key columns + to be null while other parts of the foreign key are not + null. MATCH PARTIAL is not yet implemented. +

In addition, when the data in the referenced columns is changed, + certain actions are performed on the data in this table's + columns. The ON DELETE clause specifies the + action to perform when a referenced row in the referenced table is + being deleted. Likewise, the ON UPDATE + clause specifies the action to perform when a referenced column + in the referenced table is being updated to a new value. If the + row is updated, but the referenced column is not actually + changed, no action is done. Referential actions other than the + NO ACTION check cannot be deferred, even if + the constraint is declared deferrable. There are the following possible + actions for each clause: + +

NO ACTION

Produce an error indicating that the deletion or update + would create a foreign key constraint violation. + If the constraint is deferred, this + error will be produced at constraint check time if there still + exist any referencing rows. This is the default action. +

RESTRICT

Produce an error indicating that the deletion or update + would create a foreign key constraint violation. + This is the same as NO ACTION except that + the check is not deferrable. +

CASCADE

Delete any rows referencing the deleted row, or update the + value of the referencing column to the new value of the + referenced column, respectively. +

SET NULL

Set the referencing column(s) to null. +

SET DEFAULT

Set the referencing column(s) to their default values. +

+

If the referenced column(s) are changed frequently, it might be wise to + add an index to the foreign key column so that referential actions + associated with the foreign key column can be performed more + efficiently. +

DEFERRABLE
NOT DEFERRABLE

This controls whether the constraint can be deferred. A + constraint that is not deferrable will be checked immediately + after every command. Checking of constraints that are + deferrable can be postponed until the end of the transaction + (using the SET CONSTRAINTS command). + NOT DEFERRABLE is the default. + Currently, only UNIQUE, PRIMARY KEY, + EXCLUDE, and + REFERENCES (foreign key) constraints accept this + clause. NOT NULL and CHECK constraints are not + deferrable. +

INITIALLY IMMEDIATE
INITIALLY DEFERRED

If a constraint is deferrable, this clause specifies the default + time to check the constraint. If the constraint is + INITIALLY IMMEDIATE, it is checked after each + statement. This is the default. If the constraint is + INITIALLY DEFERRED, it is checked only at the + end of the transaction. The constraint check time can be + altered with the SET CONSTRAINTS command. +

WITH ( storage_parameter [= value] [, ... ] )

This clause specifies optional storage parameters for a table or index; + see Storage Parameters for more + information. The WITH clause for a + table can also include OIDS=TRUE (or just OIDS) + to specify that rows of the new table + should have OIDs (object identifiers) assigned to them, or + OIDS=FALSE to specify that the rows should not have OIDs. + If OIDS is not specified, the default setting depends upon + the default_with_oids configuration parameter. + (If the new table inherits from any tables that have OIDs, then + OIDS=TRUE is forced even if the command says + OIDS=FALSE.) +

If OIDS=FALSE is specified or implied, the new + table does not store OIDs and no OID will be assigned for a row inserted + into it. This is generally considered worthwhile, since it + will reduce OID consumption and thereby postpone the wraparound + of the 32-bit OID counter. Once the counter wraps around, OIDs + can no longer be assumed to be unique, which makes them + considerably less useful. In addition, excluding OIDs from a + table reduces the space required to store the table on disk by + 4 bytes per row (on most machines), slightly improving performance. +

To remove OIDs from a table after it has been created, use ALTER TABLE. +

WITH OIDS
WITHOUT OIDS

These are obsolescent syntaxes equivalent to WITH (OIDS) + and WITH (OIDS=FALSE), respectively. If you wish to give + both an OIDS setting and storage parameters, you must use + the WITH ( ... ) syntax; see above. +

ON COMMIT

The behavior of temporary tables at the end of a transaction + block can be controlled using ON COMMIT. + The three options are: + +

PRESERVE ROWS

No special action is taken at the ends of transactions. + This is the default behavior. +

DELETE ROWS

All rows in the temporary table will be deleted at the end + of each transaction block. Essentially, an automatic TRUNCATE is done + at each commit. +

DROP

The temporary table will be dropped at the end of the current + transaction block. +

TABLESPACE tablespace_name

The tablespace_name is the name + of the tablespace in which the new table is to be created. + If not specified, + default_tablespace is consulted, or + temp_tablespaces if the table is temporary. +

USING INDEX TABLESPACE tablespace_name

This clause allows selection of the tablespace in which the index + associated with a UNIQUE, PRIMARY + KEY, or EXCLUDE constraint will be created. + If not specified, + default_tablespace is consulted, or + temp_tablespaces if the table is temporary. +

Storage Parameters

The WITH clause can specify storage parameters + for tables, and for indexes associated with a UNIQUE, + PRIMARY KEY, or EXCLUDE constraint. + Storage parameters for + indexes are documented in CREATE INDEX. + The storage parameters currently + available for tables are listed below. For each parameter, unless noted, + there is an additional parameter with the same name prefixed with + toast., which can be used to control the behavior of the + table's secondary TOAST table, if any + (see Section 56.2 for more information about TOAST). + Note that the TOAST table inherits the + autovacuum_* values from its parent table, if there are + no toast.autovacuum_* settings set. +

fillfactor (integer)

The fillfactor for a table is a percentage between 10 and 100. + 100 (complete packing) is the default. When a smaller fillfactor + is specified, INSERT operations pack table pages only + to the indicated percentage; the remaining space on each page is + reserved for updating rows on that page. This gives UPDATE + a chance to place the updated copy of a row on the same page as the + original, which is more efficient than placing it on a different page. + For a table whose entries are never updated, complete packing is the + best choice, but in heavily updated tables smaller fillfactors are + appropriate. This parameter cannot be set for TOAST tables. +

autovacuum_enabled, toast.autovacuum_enabled (boolean)

Enables or disables the autovacuum daemon on a particular table. + If true, the autovacuum daemon will initiate a VACUUM operation + on a particular table when the number of updated or deleted tuples exceeds + autovacuum_vacuum_threshold plus + autovacuum_vacuum_scale_factor times the number of live tuples + currently estimated to be in the relation. + Similarly, it will initiate an ANALYZE operation when the + number of inserted, updated or deleted tuples exceeds + autovacuum_analyze_threshold plus + autovacuum_analyze_scale_factor times the number of live tuples + currently estimated to be in the relation. + If false, this table will not be autovacuumed, except to prevent + transaction Id wraparound. See Section 23.1.5 for + more about wraparound prevention. + Observe that this variable inherits its value from the autovacuum setting. +

autovacuum_vacuum_threshold, toast.autovacuum_vacuum_threshold (integer)

Minimum number of updated or deleted tuples before initiate a + VACUUM operation on a particular table. +

autovacuum_vacuum_scale_factor, toast.autovacuum_vacuum_scale_factor (float4)

Multiplier for reltuples to add to + autovacuum_vacuum_threshold. +

autovacuum_analyze_threshold (integer)

Minimum number of inserted, updated, or deleted tuples before initiate an + ANALYZE operation on a particular table. +

autovacuum_analyze_scale_factor (float4)

Multiplier for reltuples to add to + autovacuum_analyze_threshold. +

autovacuum_vacuum_cost_delay, toast.autovacuum_vacuum_cost_delay (integer)

Custom autovacuum_vacuum_cost_delay parameter. +

autovacuum_vacuum_cost_limit, toast.autovacuum_vacuum_cost_limit (integer)

Custom autovacuum_vacuum_cost_limit parameter. +

autovacuum_freeze_min_age, toast.autovacuum_freeze_min_age (integer)

Custom vacuum_freeze_min_age parameter. Note that + autovacuum will ignore attempts to set a per-table + autovacuum_freeze_min_age larger than the half system-wide + autovacuum_freeze_max_age setting. +

autovacuum_freeze_max_age, toast.autovacuum_freeze_max_age (integer)

Custom autovacuum_freeze_max_age parameter. Note that + autovacuum will ignore attempts to set a per-table + autovacuum_freeze_max_age larger than the system-wide setting + (it can only be set smaller). Note that while you can set + autovacuum_freeze_max_age very small, or even zero, this is + usually unwise since it will force frequent vacuuming. +

autovacuum_freeze_table_age, toast.autovacuum_freeze_table_age (integer)

Custom vacuum_freeze_table_age parameter. +

Notes

Using OIDs in new applications is not recommended: where + possible, using a SERIAL or other sequence + generator as the table's primary key is preferred. However, if + your application does make use of OIDs to identify specific + rows of a table, it is recommended to create a unique constraint + on the oid column of that table, to ensure that + OIDs in the table will indeed uniquely identify rows even after + counter wraparound. Avoid assuming that OIDs are unique across + tables; if you need a database-wide unique identifier, use the + combination of tableoid and row OID for the + purpose. +

Tip: The use of OIDS=FALSE is not recommended + for tables with no primary key, since without either an OID or a + unique data key, it is difficult to identify specific rows. +

PostgreSQL automatically creates an + index for each unique constraint and primary key constraint to + enforce uniqueness. Thus, it is not necessary to create an + index explicitly for primary key columns. (See CREATE INDEX for more information.) +

Unique constraints and primary keys are not inherited in the + current implementation. This makes the combination of + inheritance and unique constraints rather dysfunctional. +

A table cannot have more than 1600 columns. (In practice, the + effective limit is usually lower because of tuple-length constraints.) +

Examples

Create table films and table + distributors: + +

CREATE TABLE films (
+    code        char(5) CONSTRAINT firstkey PRIMARY KEY,
+    title       varchar(40) NOT NULL,
+    did         integer NOT NULL,
+    date_prod   date,
+    kind        varchar(10),
+    len         interval hour to minute
+);
+
+CREATE TABLE distributors (
+     did    integer PRIMARY KEY DEFAULT nextval('serial'),
+     name   varchar(40) NOT NULL CHECK (name <> '')
+);

+

Create a table with a 2-dimensional array: + +

CREATE TABLE array_int (
+    vector  int[][]
+);

+

Define a unique table constraint for the table + films. Unique table constraints can be defined + on one or more columns of the table: + +

CREATE TABLE films (
+    code        char(5),
+    title       varchar(40),
+    did         integer,
+    date_prod   date,
+    kind        varchar(10),
+    len         interval hour to minute,
+    CONSTRAINT production UNIQUE(date_prod)
+);

+

Define a check column constraint: + +

CREATE TABLE distributors (
+    did     integer CHECK (did > 100),
+    name    varchar(40)
+);

+

Define a check table constraint: + +

CREATE TABLE distributors (
+    did     integer,
+    name    varchar(40)
+    CONSTRAINT con1 CHECK (did > 100 AND name <> '')
+);

+

Define a primary key table constraint for the table + films: + +

CREATE TABLE films (
+    code        char(5),
+    title       varchar(40),
+    did         integer,
+    date_prod   date,
+    kind        varchar(10),
+    len         interval hour to minute,
+    CONSTRAINT code_title PRIMARY KEY(code,title)
+);

+

Define a primary key constraint for table + distributors. The following two examples are + equivalent, the first using the table constraint syntax, the second + the column constraint syntax: + +

CREATE TABLE distributors (
+    did     integer,
+    name    varchar(40),
+    PRIMARY KEY(did)
+);
+
+CREATE TABLE distributors (
+    did     integer PRIMARY KEY,
+    name    varchar(40)
+);

+

Assign a literal constant default value for the column + name, arrange for the default value of column + did to be generated by selecting the next value + of a sequence object, and make the default value of + modtime be the time at which the row is + inserted: + +

CREATE TABLE distributors (
+    name      varchar(40) DEFAULT 'Luso Films',
+    did       integer DEFAULT nextval('distributors_serial'),
+    modtime   timestamp DEFAULT current_timestamp
+);

+

Define two NOT NULL column constraints on the table + distributors, one of which is explicitly + given a name: + +

CREATE TABLE distributors (
+    did     integer CONSTRAINT no_null NOT NULL,
+    name    varchar(40) NOT NULL
+);

+

Define a unique constraint for the name column: + +

CREATE TABLE distributors (
+    did     integer,
+    name    varchar(40) UNIQUE
+);

+ + The same, specified as a table constraint: + +

CREATE TABLE distributors (
+    did     integer,
+    name    varchar(40),
+    UNIQUE(name)
+);

+

Create the same table, specifying 70% fill factor for both the table + and its unique index: + +

CREATE TABLE distributors (
+    did     integer,
+    name    varchar(40),
+    UNIQUE(name) WITH (fillfactor=70)
+)
+WITH (fillfactor=70);

+

Create table circles with an exclusion + constraint that prevents any two circles from overlapping: + +

CREATE TABLE circles (
+    c circle,
+    EXCLUDE USING gist (c WITH &&)
+);

+

Create table cinemas in tablespace diskvol1: + +

CREATE TABLE cinemas (
+        id serial,
+        name text,
+        location text
+) TABLESPACE diskvol1;

+

Create a composite type and a typed table: +

CREATE TYPE employee_type AS (name text, salary numeric);
+
+CREATE TABLE employees OF employee_type (
+    PRIMARY KEY (name),
+    salary WITH OPTIONS DEFAULT 1000
+);

Compatibility

The CREATE TABLE command conforms to the + SQL standard, with exceptions listed below. +

Temporary Tables

Although the syntax of CREATE TEMPORARY TABLE + resembles that of the SQL standard, the effect is not the same. In the + standard, + temporary tables are defined just once and automatically exist (starting + with empty contents) in every session that needs them. + PostgreSQL instead + requires each session to issue its own CREATE TEMPORARY + TABLE command for each temporary table to be used. This allows + different sessions to use the same temporary table name for different + purposes, whereas the standard's approach constrains all instances of a + given temporary table name to have the same table structure. +

The standard's definition of the behavior of temporary tables is + widely ignored. PostgreSQL's behavior + on this point is similar to that of several other SQL databases. +

The SQL standard also distinguishes between global and local temporary + tables, where a local temporary table has a separate set of contents for + each SQL module within each session, though its definition is still shared + across sessions. Since PostgreSQL does not + support SQL modules, this distinction is not relevant in + PostgreSQL. +

For compatibility's sake, PostgreSQL will + accept the GLOBAL and LOCAL keywords + in a temporary table declaration, but they currently have no effect. + Use of these keywords is discouraged, since future versions of + PostgreSQL might adopt a more + standard-compliant interpretation of their meaning. +

The ON COMMIT clause for temporary tables + also resembles the SQL standard, but has some differences. + If the ON COMMIT clause is omitted, SQL specifies that the + default behavior is ON COMMIT DELETE ROWS. However, the + default behavior in PostgreSQL is + ON COMMIT PRESERVE ROWS. The ON COMMIT + DROP option does not exist in SQL. +

Non-deferred Uniqueness Constraints

When a UNIQUE or PRIMARY KEY constraint is + not deferrable, PostgreSQL checks for + uniqueness immediately whenever a row is inserted or modified. + The SQL standard says that uniqueness should be enforced only at + the end of the statement; this makes a difference when, for example, + a single command updates multiple key values. To obtain + standard-compliant behavior, declare the constraint as + DEFERRABLE but not deferred (i.e., INITIALLY + IMMEDIATE). Be aware that this can be significantly slower than + immediate uniqueness checking. +

Column Check Constraints

The SQL standard says that CHECK column constraints + can only refer to the column they apply to; only CHECK + table constraints can refer to multiple columns. + PostgreSQL does not enforce this + restriction; it treats column and table check constraints alike. +

EXCLUDE Constraint

The EXCLUDE constraint type is a + PostgreSQL extension. +

NULL "Constraint"

The NULL "constraint" (actually a + non-constraint) is a PostgreSQL + extension to the SQL standard that is included for compatibility with some + other database systems (and for symmetry with the NOT + NULL constraint). Since it is the default for any + column, its presence is simply noise. +

Inheritance

Multiple inheritance via the INHERITS clause is + a PostgreSQL language extension. + SQL:1999 and later define single inheritance using a + different syntax and different semantics. SQL:1999-style + inheritance is not yet supported by + PostgreSQL. +

Zero-column Tables

PostgreSQL allows a table of no columns + to be created (for example, CREATE TABLE foo();). This + is an extension from the SQL standard, which does not allow zero-column + tables. Zero-column tables are not in themselves very useful, but + disallowing them creates odd special cases for ALTER TABLE + DROP COLUMN, so it seems cleaner to ignore this spec restriction. +

WITH Clause

The WITH clause is a PostgreSQL + extension; neither storage parameters nor OIDs are in the standard. +

Tablespaces

The PostgreSQL concept of tablespaces is not + part of the standard. Hence, the clauses TABLESPACE + and USING INDEX TABLESPACE are extensions. +

Typed Tables

Typed tables implement a subset of the SQL standard. According to + the standard, a typed table has columns corresponding to the + underlying composite type as well as one other column that is + the "self-referencing column". PostgreSQL does not + support these self-referencing columns explicitly, but the same + effect can be had using the OID feature. +


PrevHomeNext
CREATE SERVERUpCREATE TABLE AS
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createtableas.html b/doc/src/sgml/html/sql-createtableas.html new file mode 100644 index 000000000..325b62f51 --- /dev/null +++ b/doc/src/sgml/html/sql-createtableas.html @@ -0,0 +1,788 @@ + +CREATE TABLE AS

CREATE TABLE AS

Name

CREATE TABLE AS -- define a new table from the results of a query

Synopsis

CREATE [ [ GLOBAL | LOCAL ] { TEMPORARY | TEMP } | UNLOGGED ] TABLE table_name
+    [ (column_name [, ...] ) ]
+    [ WITH ( storage_parameter [= value] [, ... ] ) | WITH OIDS | WITHOUT OIDS ]
+    [ ON COMMIT { PRESERVE ROWS | DELETE ROWS | DROP } ]
+    [ TABLESPACE tablespace_name ]
+    AS query
+    [ WITH [ NO ] DATA ]

Description

CREATE TABLE AS creates a table and fills it + with data computed by a SELECT command. + The table columns have the + names and data types associated with the output columns of the + SELECT (except that you can override the column + names by giving an explicit list of new column names). +

CREATE TABLE AS bears some resemblance to + creating a view, but it is really quite different: it creates a new + table and evaluates the query just once to fill the new table + initially. The new table will not track subsequent changes to the + source tables of the query. In contrast, a view re-evaluates its + defining SELECT statement whenever it is + queried. +

Parameters

GLOBAL or LOCAL

Ignored for compatibility. Use of these keywords is deprecated; + refer to CREATE TABLE for details. +

TEMPORARY or TEMP

If specified, the table is created as a temporary table. + Refer to CREATE TABLE for details. +

UNLOGGED

If specified, the table is created as an unlogged table. + Refer to CREATE TABLE for details. +

table_name

The name (optionally schema-qualified) of the table to be created. +

column_name

The name of a column in the new table. If column names are not + provided, they are taken from the output column names of the query. +

WITH ( storage_parameter [= value] [, ... ] )

This clause specifies optional storage parameters for the new table; + see Storage Parameters for more + information. The WITH clause + can also include OIDS=TRUE (or just OIDS) + to specify that rows of the new table + should have OIDs (object identifiers) assigned to them, or + OIDS=FALSE to specify that the rows should not have OIDs. + See CREATE TABLE for more information. +

WITH OIDS
WITHOUT OIDS

These are obsolescent syntaxes equivalent to WITH (OIDS) + and WITH (OIDS=FALSE), respectively. If you wish to give + both an OIDS setting and storage parameters, you must use + the WITH ( ... ) syntax; see above. +

ON COMMIT

The behavior of temporary tables at the end of a transaction + block can be controlled using ON COMMIT. + The three options are: + +

PRESERVE ROWS

No special action is taken at the ends of transactions. + This is the default behavior. +

DELETE ROWS

All rows in the temporary table will be deleted at the end + of each transaction block. Essentially, an automatic TRUNCATE is done + at each commit. +

DROP

The temporary table will be dropped at the end of the current + transaction block. +

TABLESPACE tablespace_name

The tablespace_name is the name + of the tablespace in which the new table is to be created. + If not specified, + default_tablespace is consulted, or + temp_tablespaces if the table is temporary. +

query

A SELECT, TABLE, or VALUES + command, or an EXECUTE command that runs a + prepared SELECT, TABLE, or + VALUES query. +

WITH [ NO ] DATA

This clause specifies whether or not the data produced by the query + should be copied into the new table. If not, only the table structure + is copied. The default is to copy the data. +

Notes

This command is functionally similar to SELECT INTO, but it is + preferred since it is less likely to be confused with other uses of + the SELECT INTO syntax. Furthermore, CREATE + TABLE AS offers a superset of the functionality offered + by SELECT INTO. +

Prior to PostgreSQL 8.0, CREATE + TABLE AS always included OIDs in the table it + created. As of PostgreSQL 8.0, + the CREATE TABLE AS command allows the user to + explicitly specify whether OIDs should be included. If the + presence of OIDs is not explicitly specified, + the default_with_oids configuration variable is + used. As of PostgreSQL 8.1, + this variable is false by default, so the default behavior is not + identical to pre-8.0 releases. Applications that + require OIDs in the table created by CREATE TABLE + AS should explicitly specify WITH (OIDS) + to ensure desired behavior. +

Examples

Create a new table films_recent consisting of only + recent entries from the table films: + +

CREATE TABLE films_recent AS
+  SELECT * FROM films WHERE date_prod >= '2002-01-01';

+

To copy a table completely, the short form using + the TABLE command can also be used: + +

CREATE TABLE films2 AS
+  TABLE films;

+

Create a new temporary table films_recent, consisting of + only recent entries from the table films, using a + prepared statement. The new table has OIDs and will be dropped at commit: + +

PREPARE recentfilms(date) AS
+  SELECT * FROM films WHERE date_prod > $1;
+CREATE TEMP TABLE films_recent WITH (OIDS) ON COMMIT DROP AS
+  EXECUTE recentfilms('2002-01-01');

Compatibility

CREATE TABLE AS conforms to the SQL + standard. The following are nonstandard extensions: + +

  • The standard requires parentheses around the subquery clause; in + PostgreSQL, these parentheses are + optional. +

  • In the standard, the WITH [ NO ] DATA clause + is required; in PostgreSQL it is optional. +

  • PostgreSQL handles temporary tables in a way + rather different from the standard; see + CREATE TABLE + for details. +

  • The WITH clause is a PostgreSQL + extension; neither storage parameters nor OIDs are in the standard. +

  • The PostgreSQL concept of tablespaces is not + part of the standard. Hence, the clause TABLESPACE + is an extension. +


PrevHomeNext
CREATE TABLEUpCREATE TABLESPACE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createtablespace.html b/doc/src/sgml/html/sql-createtablespace.html new file mode 100644 index 000000000..142d548f5 --- /dev/null +++ b/doc/src/sgml/html/sql-createtablespace.html @@ -0,0 +1,399 @@ + +CREATE TABLESPACE

CREATE TABLESPACE

Name

CREATE TABLESPACE -- define a new tablespace

Synopsis

CREATE TABLESPACE tablespace_name [ OWNER user_name ] LOCATION 'directory'

Description

CREATE TABLESPACE registers a new cluster-wide + tablespace. The tablespace name must be distinct from the name of any + existing tablespace in the database cluster. +

A tablespace allows superusers to define an alternative location on + the file system where the data files containing database objects + (such as tables and indexes) can reside. +

A user with appropriate privileges can pass + tablespace_name to + CREATE DATABASE, CREATE TABLE, + CREATE INDEX or ADD CONSTRAINT to have the data + files for these objects stored within the specified tablespace. +

Parameters

tablespace_name

The name of a tablespace to be created. The name cannot + begin with pg_, as such names + are reserved for system tablespaces. +

user_name

The name of the user who will own the tablespace. If omitted, + defaults to the user executing the command. Only superusers + can create tablespaces, but they can assign ownership of tablespaces + to non-superusers. +

directory

The directory that will be used for the tablespace. The directory + should be empty and must be owned by the + PostgreSQL system user. The directory must be + specified by an absolute path name. +

Notes

Tablespaces are only supported on systems that support symbolic links. +

CREATE TABLESPACE cannot be executed inside a transaction + block. +

Examples

Create a tablespace dbspace at /data/dbs: +

CREATE TABLESPACE dbspace LOCATION '/data/dbs';

+

Create a tablespace indexspace at /data/indexes + owned by user genevieve: +

CREATE TABLESPACE indexspace OWNER genevieve LOCATION '/data/indexes';

Compatibility

CREATE TABLESPACE is a PostgreSQL + extension. +


PrevHomeNext
CREATE TABLE ASUpCREATE TEXT SEARCH CONFIGURATION
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createtrigger.html b/doc/src/sgml/html/sql-createtrigger.html new file mode 100644 index 000000000..2ac9d5554 --- /dev/null +++ b/doc/src/sgml/html/sql-createtrigger.html @@ -0,0 +1,1311 @@ + +CREATE TRIGGER

CREATE TRIGGER

Name

CREATE TRIGGER -- define a new trigger

Synopsis

CREATE [ CONSTRAINT ] TRIGGER name { BEFORE | AFTER | INSTEAD OF } { event [ OR ... ] }
+    ON table_name
+    [ FROM referenced_table_name ]
+    { NOT DEFERRABLE | [ DEFERRABLE ] { INITIALLY IMMEDIATE | INITIALLY DEFERRED } }
+    [ FOR [ EACH ] { ROW | STATEMENT } ]
+    [ WHEN ( condition ) ]
+    EXECUTE PROCEDURE function_name ( arguments )
+
+where event can be one of:
+
+    INSERT
+    UPDATE [ OF column_name [, ... ] ]
+    DELETE
+    TRUNCATE

Description

CREATE TRIGGER creates a new trigger. The + trigger will be associated with the specified table or view and will + execute the specified function function_name when certain events occur. +

The trigger can be specified to fire before the + operation is attempted on a row (before constraints are checked and + the INSERT, UPDATE, or + DELETE is attempted); or after the operation has + completed (after constraints are checked and the + INSERT, UPDATE, or + DELETE has completed); or instead of the operation + (in the case of inserts, updates or deletes on a view). + If the trigger fires before or instead of the event, the trigger can skip + the operation for the current row, or change the row being inserted (for + INSERT and UPDATE operations + only). If the trigger fires after the event, all changes, including + the effects of other triggers, are "visible" + to the trigger. +

A trigger that is marked FOR EACH ROW is called + once for every row that the operation modifies. For example, a + DELETE that affects 10 rows will cause any + ON DELETE triggers on the target relation to be + called 10 separate times, once for each deleted row. In contrast, a + trigger that is marked FOR EACH STATEMENT only + executes once for any given operation, regardless of how many rows + it modifies (in particular, an operation that modifies zero rows + will still result in the execution of any applicable FOR + EACH STATEMENT triggers). +

Triggers that are specified to fire INSTEAD OF the trigger + event must be marked FOR EACH ROW, and can only be defined + on views. BEFORE and AFTER triggers on a view + must be marked as FOR EACH STATEMENT. +

In addition, triggers may be defined to fire for + TRUNCATE, though only + FOR EACH STATEMENT. +

The following table summarizes which types of triggers may be used on + tables and views: +

WhenEventRow-levelStatement-level
BEFOREINSERT/UPDATE/DELETETablesTables and views
TRUNCATETables
AFTERINSERT/UPDATE/DELETETablesTables and views
TRUNCATETables
INSTEAD OFINSERT/UPDATE/DELETEViews
TRUNCATE

Also, a trigger definition can specify a Boolean WHEN + condition, which will be tested to see whether the trigger should + be fired. In row-level triggers the WHEN condition can + examine the old and/or new values of columns of the row. Statement-level + triggers can also have WHEN conditions, although the feature + is not so useful for them since the condition cannot refer to any values + in the table. +

If multiple triggers of the same kind are defined for the same event, + they will be fired in alphabetical order by name. +

When the CONSTRAINT option is specified, this command creates a + constraint trigger. This is the same as a regular trigger + except that the timing of the trigger firing can be adjusted using + SET CONSTRAINTS. + Constraint triggers must be AFTER ROW triggers. They can + be fired either at the end of the statement causing the triggering event, + or at the end of the containing transaction; in the latter case they are + said to be deferred. A pending deferred-trigger firing can + also be forced to happen immediately by using SET CONSTRAINTS. + Constraint triggers are expected to raise an exception when the constraints + they implement are violated. +

SELECT does not modify any rows so you cannot + create SELECT triggers. Rules and views are more + appropriate in such cases. +

Refer to Chapter 36 for more information about triggers. +

Parameters

name

The name to give the new trigger. This must be distinct from + the name of any other trigger for the same table. + The name cannot be schema-qualified — the trigger inherits the + schema of its table. For a constraint trigger, this is also the name to + use when modifying the trigger's behavior using + SET CONSTRAINTS. +

BEFORE
AFTER
INSTEAD OF

Determines whether the function is called before, after, or instead of + the event. A constraint trigger can only be specified as + AFTER. +

event

One of INSERT, UPDATE, + DELETE, or TRUNCATE; + this specifies the event that will fire the trigger. Multiple + events can be specified using OR. +

For UPDATE events, it is possible to + specify a list of columns using this syntax: +

UPDATE OF column_name1 [, column_name2 ... ]

+ The trigger will only fire if at least one of the listed columns + is mentioned as a target of the UPDATE command. +

INSTEAD OF UPDATE events do not support lists of columns. +

table_name

The name (optionally schema-qualified) of the table or view the trigger + is for. +

referenced_table_name

The (possibly schema-qualified) name of another table referenced by the + constraint. This option is used for foreign-key constraints and is not + recommended for general use. This can only be specified for + constraint triggers. +

DEFERRABLE
NOT DEFERRABLE
INITIALLY IMMEDIATE
INITIALLY DEFERRED

The default timing of the trigger. + See the CREATE TABLE documentation for details of + these constraint options. This can only be specified for constraint + triggers. +

FOR EACH ROW
FOR EACH STATEMENT

This specifies whether the trigger procedure should be fired + once for every row affected by the trigger event, or just once + per SQL statement. If neither is specified, FOR EACH + STATEMENT is the default. Constraint triggers can only + be specified FOR EACH ROW. +

condition

A Boolean expression that determines whether the trigger function + will actually be executed. If WHEN is specified, the + function will only be called if the condition returns true. + In FOR EACH ROW triggers, the WHEN + condition can refer to columns of the old and/or new row values + by writing OLD.column_name or + NEW.column_name respectively. + Of course, INSERT triggers cannot refer to OLD + and DELETE triggers cannot refer to NEW. +

INSTEAD OF triggers do not support WHEN + conditions. +

Currently, WHEN expressions cannot contain + subqueries. +

Note that for constraint triggers, evaluation of the WHEN + condition is not deferred, but occurs immediately after the row update + operation is performed. If the condition does not evaluate to true then + the trigger is not queued for deferred execution. +

function_name

A user-supplied function that is declared as taking no arguments + and returning type trigger, which is executed when + the trigger fires. +

arguments

An optional comma-separated list of arguments to be provided to + the function when the trigger is executed. The arguments are + literal string constants. Simple names and numeric constants + can be written here, too, but they will all be converted to + strings. Please check the description of the implementation + language of the trigger function to find out how these arguments + can be accessed within the function; it might be different from + normal function arguments. +

Notes

To create a trigger on a table, the user must have the + TRIGGER privilege on the table. The user must + also have EXECUTE privilege on the trigger function. +

Use DROP TRIGGER to remove a trigger. +

A column-specific trigger (one defined using the UPDATE OF + column_name syntax) will fire when any + of its columns are listed as targets in the UPDATE + command's SET list. It is possible for a column's value + to change even when the trigger is not fired, because changes made to the + row's contents by BEFORE UPDATE triggers are not considered. + Conversely, a command such as UPDATE ... SET x = x ... + will fire a trigger on column x, even though the column's + value did not change. +

In a BEFORE trigger, the WHEN condition is + evaluated just before the function is or would be executed, so using + WHEN is not materially different from testing the same + condition at the beginning of the trigger function. Note in particular + that the NEW row seen by the condition is the current value, + as possibly modified by earlier triggers. Also, a BEFORE + trigger's WHEN condition is not allowed to examine the + system columns of the NEW row (such as oid), + because those won't have been set yet. +

In an AFTER trigger, the WHEN condition is + evaluated just after the row update occurs, and it determines whether an + event is queued to fire the trigger at the end of statement. So when an + AFTER trigger's WHEN condition does not return + true, it is not necessary to queue an event nor to re-fetch the row at end + of statement. This can result in significant speedups in statements that + modify many rows, if the trigger only needs to be fired for a few of the + rows. +

In PostgreSQL versions before 7.3, it was + necessary to declare trigger functions as returning the placeholder + type opaque, rather than trigger. To support loading + of old dump files, CREATE TRIGGER will accept a function + declared as returning opaque, but it will issue a notice and + change the function's declared return type to trigger. +

Examples

Execute the function check_account_update whenever + a row of the table accounts is about to be updated: + +

CREATE TRIGGER check_update
+    BEFORE UPDATE ON accounts
+    FOR EACH ROW
+    EXECUTE PROCEDURE check_account_update();

+ + The same, but only execute the function if column balance + is specified as a target in the UPDATE command: + +

CREATE TRIGGER check_update
+    BEFORE UPDATE OF balance ON accounts
+    FOR EACH ROW
+    EXECUTE PROCEDURE check_account_update();

+ + This form only executes the function if column balance + has in fact changed value: + +

CREATE TRIGGER check_update
+    BEFORE UPDATE ON accounts
+    FOR EACH ROW
+    WHEN (OLD.balance IS DISTINCT FROM NEW.balance)
+    EXECUTE PROCEDURE check_account_update();

+ + Call a function to log updates of accounts, but only if + something changed: + +

CREATE TRIGGER log_update
+    AFTER UPDATE ON accounts
+    FOR EACH ROW
+    WHEN (OLD.* IS DISTINCT FROM NEW.*)
+    EXECUTE PROCEDURE log_account_update();

+ + Execute the function view_insert_row for each row to insert + rows into the tables underlying a view: + +

CREATE TRIGGER view_insert
+    INSTEAD OF INSERT ON my_view
+    FOR EACH ROW
+    EXECUTE PROCEDURE view_insert_row();

+

Section 36.4 contains a complete example of a trigger + function written in C. +

Compatibility

The CREATE TRIGGER statement in + PostgreSQL implements a subset of the + SQL standard. The following functionality is currently missing: + +

  • SQL allows you to define aliases for the "old" + and "new" rows or tables for use in the definition + of the triggered action (e.g., CREATE TRIGGER ... ON + tablename REFERENCING OLD ROW AS somename NEW ROW AS othername + ...). Since PostgreSQL + allows trigger procedures to be written in any number of + user-defined languages, access to the data is handled in a + language-specific way. +

  • PostgreSQL only allows the execution + of a user-defined function for the triggered action. The standard + allows the execution of a number of other SQL commands, such as + CREATE TABLE, as the triggered action. This + limitation is not hard to work around by creating a user-defined + function that executes the desired commands. +

+

SQL specifies that multiple triggers should be fired in + time-of-creation order. PostgreSQL uses + name order, which was judged to be more convenient. +

SQL specifies that BEFORE DELETE triggers on cascaded + deletes fire after the cascaded DELETE completes. + The PostgreSQL behavior is for BEFORE + DELETE to always fire before the delete action, even a cascading + one. This is considered more consistent. There is also nonstandard + behavior if BEFORE triggers modify rows or prevent + updates during an update that is caused by a referential action. This can + lead to constraint violations or stored data that does not honor the + referential constraint. +

The ability to specify multiple actions for a single trigger using + OR is a PostgreSQL extension of + the SQL standard. +

The ability to fire triggers for TRUNCATE is a + PostgreSQL extension of the SQL standard, as is the + ability to define statement-level triggers on views. +

CREATE CONSTRAINT TRIGGER is a + PostgreSQL extension of the SQL + standard. +


PrevHomeNext
CREATE TEXT SEARCH TEMPLATEUpCREATE TYPE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createtsconfig.html b/doc/src/sgml/html/sql-createtsconfig.html new file mode 100644 index 000000000..18970e8c9 --- /dev/null +++ b/doc/src/sgml/html/sql-createtsconfig.html @@ -0,0 +1,337 @@ + +CREATE TEXT SEARCH CONFIGURATION

CREATE TEXT SEARCH CONFIGURATION

Name

CREATE TEXT SEARCH CONFIGURATION -- define a new text search configuration

Synopsis

CREATE TEXT SEARCH CONFIGURATION name (
+    PARSER = parser_name |
+    COPY = source_config
+)

Description

CREATE TEXT SEARCH CONFIGURATION creates a new text + search configuration. A text search configuration specifies a text + search parser that can divide a string into tokens, plus dictionaries + that can be used to determine which tokens are of interest for searching. +

If only the parser is specified, then the new text search configuration + initially has no mappings from token types to dictionaries, and therefore + will ignore all words. Subsequent ALTER TEXT SEARCH + CONFIGURATION commands must be used to create mappings to + make the configuration useful. Alternatively, an existing text search + configuration can be copied. +

If a schema name is given then the text search configuration is created in + the specified schema. Otherwise it is created in the current schema. +

The user who defines a text search configuration becomes its owner. +

Refer to Chapter 12 for further information. +

Parameters

name

The name of the text search configuration to be created. The name can be + schema-qualified. +

parser_name

The name of the text search parser to use for this configuration. +

source_config

The name of an existing text search configuration to copy. +

Notes

The PARSER and COPY options are mutually + exclusive, because when an existing configuration is copied, its + parser selection is copied too. +

Compatibility

There is no CREATE TEXT SEARCH CONFIGURATION statement + in the SQL standard. +


PrevHomeNext
CREATE TABLESPACEUpCREATE TEXT SEARCH DICTIONARY
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createtsdictionary.html b/doc/src/sgml/html/sql-createtsdictionary.html new file mode 100644 index 000000000..8df423616 --- /dev/null +++ b/doc/src/sgml/html/sql-createtsdictionary.html @@ -0,0 +1,351 @@ + +CREATE TEXT SEARCH DICTIONARY

CREATE TEXT SEARCH DICTIONARY

Name

CREATE TEXT SEARCH DICTIONARY -- define a new text search dictionary

Synopsis

CREATE TEXT SEARCH DICTIONARY name (
+    TEMPLATE = template
+    [, option = value [, ... ]]
+)

Description

CREATE TEXT SEARCH DICTIONARY creates a new text search + dictionary. A text search dictionary specifies a way of recognizing + interesting or uninteresting words for searching. A dictionary depends + on a text search template, which specifies the functions that actually + perform the work. Typically the dictionary provides some options that + control the detailed behavior of the template's functions. +

If a schema name is given then the text search dictionary is created in the + specified schema. Otherwise it is created in the current schema. +

The user who defines a text search dictionary becomes its owner. +

Refer to Chapter 12 for further information. +

Parameters

name

The name of the text search dictionary to be created. The name can be + schema-qualified. +

template

The name of the text search template that will define the basic + behavior of this dictionary. +

option

The name of a template-specific option to be set for this dictionary. +

value

The value to use for a template-specific option. If the value + is not a simple identifier or number, it must be quoted (but you can + always quote it, if you wish). +

The options can appear in any order. +

Examples

The following example command creates a Snowball-based dictionary + with a nonstandard list of stop words. +

CREATE TEXT SEARCH DICTIONARY my_russian (
+    template = snowball,
+    language = russian,
+    stopwords = myrussian
+);

Compatibility

There is no CREATE TEXT SEARCH DICTIONARY statement in + the SQL standard. +


PrevHomeNext
CREATE TEXT SEARCH CONFIGURATIONUpCREATE TEXT SEARCH PARSER
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createtsparser.html b/doc/src/sgml/html/sql-createtsparser.html new file mode 100644 index 000000000..73227c7a5 --- /dev/null +++ b/doc/src/sgml/html/sql-createtsparser.html @@ -0,0 +1,379 @@ + +CREATE TEXT SEARCH PARSER

CREATE TEXT SEARCH PARSER

Name

CREATE TEXT SEARCH PARSER -- define a new text search parser

Synopsis

CREATE TEXT SEARCH PARSER name (
+    START = start_function ,
+    GETTOKEN = gettoken_function ,
+    END = end_function ,
+    LEXTYPES = lextypes_function
+    [, HEADLINE = headline_function ]
+)

Description

CREATE TEXT SEARCH PARSER creates a new text search + parser. A text search parser defines a method for splitting a text + string into tokens and assigning types (categories) to the tokens. + A parser is not particularly useful by itself, but must be bound into a + text search configuration along with some text search dictionaries + to be used for searching. +

If a schema name is given then the text search parser is created in the + specified schema. Otherwise it is created in the current schema. +

You must be a superuser to use CREATE TEXT SEARCH PARSER. + (This restriction is made because an erroneous text search parser + definition could confuse or even crash the server.) +

Refer to Chapter 12 for further information. +

Parameters

name

The name of the text search parser to be created. The name can be + schema-qualified. +

start_function

The name of the start function for the parser. +

gettoken_function

The name of the get-next-token function for the parser. +

end_function

The name of the end function for the parser. +

lextypes_function

The name of the lextypes function for the parser (a function that + returns information about the set of token types it produces). +

headline_function

The name of the headline function for the parser (a function that + summarizes a set of tokens). +

The function names can be schema-qualified if necessary. Argument types + are not given, since the argument list for each type of function is + predetermined. All except the headline function are required. +

The arguments can appear in any order, not only the one shown above. +

Compatibility

There is no + CREATE TEXT SEARCH PARSER statement in the SQL + standard. +


PrevHomeNext
CREATE TEXT SEARCH DICTIONARYUpCREATE TEXT SEARCH TEMPLATE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createtstemplate.html b/doc/src/sgml/html/sql-createtstemplate.html new file mode 100644 index 000000000..e934217d7 --- /dev/null +++ b/doc/src/sgml/html/sql-createtstemplate.html @@ -0,0 +1,331 @@ + +CREATE TEXT SEARCH TEMPLATE

CREATE TEXT SEARCH TEMPLATE

Name

CREATE TEXT SEARCH TEMPLATE -- define a new text search template

Synopsis

CREATE TEXT SEARCH TEMPLATE name (
+    [ INIT = init_function , ]
+    LEXIZE = lexize_function
+)

Description

CREATE TEXT SEARCH TEMPLATE creates a new text search + template. Text search templates define the functions that implement + text search dictionaries. A template is not useful by itself, but must + be instantiated as a dictionary to be used. The dictionary typically + specifies parameters to be given to the template functions. +

If a schema name is given then the text search template is created in the + specified schema. Otherwise it is created in the current schema. +

You must be a superuser to use CREATE TEXT SEARCH + TEMPLATE. This restriction is made because an erroneous text + search template definition could confuse or even crash the server. + The reason for separating templates from dictionaries is that a template + encapsulates the "unsafe" aspects of defining a dictionary. + The parameters that can be set when defining a dictionary are safe for + unprivileged users to set, and so creating a dictionary need not be a + privileged operation. +

Refer to Chapter 12 for further information. +

Parameters

name

The name of the text search template to be created. The name can be + schema-qualified. +

init_function

The name of the init function for the template. +

lexize_function

The name of the lexize function for the template. +

The function names can be schema-qualified if necessary. Argument types + are not given, since the argument list for each type of function is + predetermined. The lexize function is required, but the init function + is optional. +

The arguments can appear in any order, not only the one shown above. +

Compatibility

There is no + CREATE TEXT SEARCH TEMPLATE statement in the SQL + standard. +


PrevHomeNext
CREATE TEXT SEARCH PARSERUpCREATE TRIGGER
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createtype.html b/doc/src/sgml/html/sql-createtype.html new file mode 100644 index 000000000..5f99988b7 --- /dev/null +++ b/doc/src/sgml/html/sql-createtype.html @@ -0,0 +1,1964 @@ + +CREATE TYPE

CREATE TYPE

Name

CREATE TYPE -- define a new data type

Synopsis

CREATE TYPE name AS
+    ( [ attribute_name data_type [ COLLATE collation ] [, ... ] ] )
+
+CREATE TYPE name AS ENUM
+    ( [ 'label' [, ... ] ] )
+
+CREATE TYPE name AS RANGE (
+    SUBTYPE = subtype
+    [ , SUBTYPE_OPCLASS = subtype_operator_class ]
+    [ , COLLATION = collation ]
+    [ , CANONICAL = canonical_function ]
+    [ , SUBTYPE_DIFF = subtype_diff_function ]
+)
+
+CREATE TYPE name (
+    INPUT = input_function,
+    OUTPUT = output_function
+    [ , RECEIVE = receive_function ]
+    [ , SEND = send_function ]
+    [ , TYPMOD_IN = type_modifier_input_function ]
+    [ , TYPMOD_OUT = type_modifier_output_function ]
+    [ , ANALYZE = analyze_function ]
+    [ , INTERNALLENGTH = { internallength | VARIABLE } ]
+    [ , PASSEDBYVALUE ]
+    [ , ALIGNMENT = alignment ]
+    [ , STORAGE = storage ]
+    [ , LIKE = like_type ]
+    [ , CATEGORY = category ]
+    [ , PREFERRED = preferred ]
+    [ , DEFAULT = default ]
+    [ , ELEMENT = element ]
+    [ , DELIMITER = delimiter ]
+    [ , COLLATABLE = collatable ]
+)
+
+CREATE TYPE name

Description

CREATE TYPE registers a new data type for use in + the current database. The user who defines a type becomes its + owner. +

If a schema name is given then the type is created in the specified + schema. Otherwise it is created in the current schema. The type + name must be distinct from the name of any existing type or domain + in the same schema. (Because tables have associated data types, + the type name must also be distinct from the name of any existing + table in the same schema.) +

There are five forms of CREATE TYPE, as shown in the + syntax synopsis above. They respectively create a composite + type, an enum type, a range type, a + base type, or a shell type. The first four + of these are discussed in turn below. A shell type is simply a placeholder + for a type to be defined later; it is created by issuing CREATE + TYPE with no parameters except for the type name. Shell types + are needed as forward references when creating range types and base types, + as discussed in those sections. +

Composite Types

The first form of CREATE TYPE + creates a composite type. + The composite type is specified by a list of attribute names and data types. + An attribute's collation can be specified too, if its data type is + collatable. A composite type is essentially the same as the row type + of a table, but using CREATE TYPE avoids the need to + create an actual table when all that is wanted is to define a type. + A stand-alone composite type is useful, for example, as the argument or + return type of a function. +

To be able to create a composite type, you must + have USAGE privilege on all attribute types. +

Enumerated Types

The second form of CREATE TYPE creates an enumerated + (enum) type, as described in Section 8.7. + Enum types take a list of one or more quoted labels, each of which + must be less than NAMEDATALEN bytes long (64 bytes in a + standard PostgreSQL build). +

Range Types

The third form of CREATE TYPE creates a new + range type, as described in Section 8.17. +

The range type's subtype can + be any type with an associated b-tree operator class (to determine the + ordering of values for the range type). Normally the subtype's default + b-tree operator class is used to determine ordering; to use a non-default + opclass, specify its name with subtype_opclass. If the subtype is + collatable, and you want to use a non-default collation in the range's + ordering, specify the desired collation with the collation option. +

The optional canonical + function must take one argument of the range type being defined, and + return a value of the same type. This is used to convert range values + to a canonical form, when applicable. See Section 8.17.8 for more information. Creating a + canonical function + is a bit tricky, since it must be defined before the range type can be + declared. To do this, you must first create a shell type, which is a + placeholder type that has no properties except a name and an + owner. This is done by issuing the command CREATE TYPE + name, with no additional parameters. Then + the function can be declared using the shell type as argument and result, + and finally the range type can be declared using the same name. This + automatically replaces the shell type entry with a valid range type. +

The optional subtype_diff + function must take two values of the + subtype type as argument, + and return a double precision value representing the + difference between the two given values. While this is optional, + providing it allows much greater efficiency of GiST indexes on columns of + the range type. See Section 8.17.8 for more + information. +

Base Types

The fourth form of CREATE TYPE creates a new base type + (scalar type). To create a new base type, you must be a superuser. + (This restriction is made because an erroneous type definition could + confuse or even crash the server.) +

The parameters can appear in any order, not only that + illustrated above, and most are optional. You must register + two or more functions (using CREATE FUNCTION) before + defining the type. The support functions + input_function and + output_function + are required, while the functions + receive_function, + send_function, + type_modifier_input_function, + type_modifier_output_function and + analyze_function + are optional. Generally these functions have to be coded in C + or another low-level language. +

The input_function + converts the type's external textual representation to the internal + representation used by the operators and functions defined for the type. + output_function + performs the reverse transformation. The input function can be + declared as taking one argument of type cstring, + or as taking three arguments of types + cstring, oid, integer. + The first argument is the input text as a C string, the second + argument is the type's own OID (except for array types, which instead + receive their element type's OID), + and the third is the typmod of the destination column, if known + (-1 will be passed if not). + The input function must return a value of the data type itself. + Usually, an input function should be declared STRICT; if it is not, + it will be called with a NULL first parameter when reading a NULL + input value. The function must still return NULL in this case, unless + it raises an error. + (This case is mainly meant to support domain input functions, which + might need to reject NULL inputs.) + The output function must be + declared as taking one argument of the new data type. + The output function must return type cstring. + Output functions are not invoked for NULL values. +

The optional receive_function + converts the type's external binary representation to the internal + representation. If this function is not supplied, the type cannot + participate in binary input. The binary representation should be + chosen to be cheap to convert to internal form, while being reasonably + portable. (For example, the standard integer data types use network + byte order as the external binary representation, while the internal + representation is in the machine's native byte order.) The receive + function should perform adequate checking to ensure that the value is + valid. + The receive function can be declared as taking one argument of type + internal, or as taking three arguments of types + internal, oid, integer. + The first argument is a pointer to a StringInfo buffer + holding the received byte string; the optional arguments are the + same as for the text input function. + The receive function must return a value of the data type itself. + Usually, a receive function should be declared STRICT; if it is not, + it will be called with a NULL first parameter when reading a NULL + input value. The function must still return NULL in this case, unless + it raises an error. + (This case is mainly meant to support domain receive functions, which + might need to reject NULL inputs.) + Similarly, the optional + send_function converts + from the internal representation to the external binary representation. + If this function is not supplied, the type cannot participate in binary + output. The send function must be + declared as taking one argument of the new data type. + The send function must return type bytea. + Send functions are not invoked for NULL values. +

You should at this point be wondering how the input and output functions + can be declared to have results or arguments of the new type, when they + have to be created before the new type can be created. The answer is that + the type should first be defined as a shell type, which is a + placeholder type that has no properties except a name and an owner. This + is done by issuing the command CREATE TYPE + name, with no additional parameters. Then the + I/O functions can be defined referencing the shell type. Finally, + CREATE TYPE with a full definition replaces the shell entry + with a complete, valid type definition, after which the new type can be + used normally. +

The optional + type_modifier_input_function + and type_modifier_output_function + are needed if the type supports modifiers, that is optional constraints + attached to a type declaration, such as char(5) or + numeric(30,2). PostgreSQL allows + user-defined types to take one or more simple constants or identifiers as + modifiers. However, this information must be capable of being packed into a + single non-negative integer value for storage in the system catalogs. The + type_modifier_input_function + is passed the declared modifier(s) in the form of a cstring + array. It must check the values for validity (throwing an error if they + are wrong), and if they are correct, return a single non-negative + integer value that will be stored as the column "typmod". + Type modifiers will be rejected if the type does not have a + type_modifier_input_function. + The type_modifier_output_function + converts the internal integer typmod value back to the correct form for + user display. It must return a cstring value that is the exact + string to append to the type name; for example numeric's + function might return (30,2). + It is allowed to omit the + type_modifier_output_function, + in which case the default display format is just the stored typmod integer + value enclosed in parentheses. +

The optional analyze_function + performs type-specific statistics collection for columns of the data type. + By default, ANALYZE will attempt to gather statistics using + the type's "equals" and "less-than" operators, if there + is a default b-tree operator class for the type. For non-scalar types + this behavior is likely to be unsuitable, so it can be overridden by + specifying a custom analysis function. The analysis function must be + declared to take a single argument of type internal, and return + a boolean result. The detailed API for analysis functions appears + in src/include/commands/vacuum.h. +

While the details of the new type's internal representation are only + known to the I/O functions and other functions you create to work with + the type, there are several properties of the internal representation + that must be declared to PostgreSQL. + Foremost of these is + internallength. + Base data types can be fixed-length, in which case + internallength is a + positive integer, or variable length, indicated by setting + internallength + to VARIABLE. (Internally, this is represented + by setting typlen to -1.) The internal representation of all + variable-length types must start with a 4-byte integer giving the total + length of this value of the type. +

The optional flag PASSEDBYVALUE indicates that + values of this data type are passed by value, rather than by + reference. You cannot pass by value types whose internal + representation is larger than the size of the Datum type + (4 bytes on most machines, 8 bytes on a few). +

The alignment parameter + specifies the storage alignment required for the data type. The + allowed values equate to alignment on 1, 2, 4, or 8 byte boundaries. + Note that variable-length types must have an alignment of at least + 4, since they necessarily contain an int4 as their first component. +

The storage parameter + allows selection of storage strategies for variable-length data + types. (Only plain is allowed for fixed-length + types.) plain specifies that data of the type + will always be stored in-line and not compressed. + extended specifies that the system will first + try to compress a long data value, and will move the value out of + the main table row if it's still too long. + external allows the value to be moved out of the + main table, but the system will not try to compress it. + main allows compression, but discourages moving + the value out of the main table. (Data items with this storage + strategy might still be moved out of the main table if there is no + other way to make a row fit, but they will be kept in the main + table preferentially over extended and + external items.) +

The like_type parameter + provides an alternative method for specifying the basic representation + properties of a data type: copy them from some existing type. The values of + internallength, + passedbyvalue, + alignment, and + storage are copied from the + named type. (It is possible, though usually undesirable, to override + some of these values by specifying them along with the LIKE + clause.) Specifying representation this way is especially useful when + the low-level implementation of the new type "piggybacks" on an + existing type in some fashion. +

The category and + preferred parameters can be + used to help control which implicit cast will be applied in ambiguous + situations. Each data type belongs to a category named by a single ASCII + character, and each type is either "preferred" or not within its + category. The parser will prefer casting to preferred types (but only from + other types within the same category) when this rule is helpful in + resolving overloaded functions or operators. For more details see Chapter 10. For types that have no implicit casts to or from any + other types, it is sufficient to leave these settings at the defaults. + However, for a group of related types that have implicit casts, it is often + helpful to mark them all as belonging to a category and select one or two + of the "most general" types as being preferred within the category. + The category parameter is + especially useful when adding a user-defined type to an existing built-in + category, such as the numeric or string types. However, it is also + possible to create new entirely-user-defined type categories. Select any + ASCII character other than an upper-case letter to name such a category. +

A default value can be specified, in case a user wants columns of the + data type to default to something other than the null value. + Specify the default with the DEFAULT key word. + (Such a default can be overridden by an explicit DEFAULT + clause attached to a particular column.) +

To indicate that a type is an array, specify the type of the array + elements using the ELEMENT key word. For example, to + define an array of 4-byte integers (int4), specify + ELEMENT = int4. More details about array types + appear below. +

To indicate the delimiter to be used between values in the external + representation of arrays of this type, delimiter can be + set to a specific character. The default delimiter is the comma + (,). Note that the delimiter is associated + with the array element type, not the array type itself. +

If the optional Boolean + parameter collatable + is true, column definitions and expressions of the type may carry + collation information through use of + the COLLATE clause. It is up to the + implementations of the functions operating on the type to actually + make use of the collation information; this does not happen + automatically merely by marking the type collatable. +

Array Types

Whenever a user-defined type is created, + PostgreSQL automatically creates an + associated array type, whose name consists of the element type's + name prepended with an underscore, and truncated if necessary to keep + it less than NAMEDATALEN bytes long. (If the name + so generated collides with an existing type name, the process is + repeated until a non-colliding name is found.) + This implicitly-created array type is variable length and uses the + built-in input and output functions array_in and + array_out. The array type tracks any changes in its + element type's owner or schema, and is dropped if the element type is. +

You might reasonably ask why there is an ELEMENT + option, if the system makes the correct array type automatically. + The only case where it's useful to use ELEMENT is when you are + making a fixed-length type that happens to be internally an array of a number of + identical things, and you want to allow these things to be accessed + directly by subscripting, in addition to whatever operations you plan + to provide for the type as a whole. For example, type point + is represented as just two floating-point numbers, each can be accessed using + point[0] and point[1]. + Note that + this facility only works for fixed-length types whose internal form + is exactly a sequence of identical fixed-length fields. A subscriptable + variable-length type must have the generalized internal representation + used by array_in and array_out. + For historical reasons (i.e., this is clearly wrong but it's far too + late to change it), subscripting of fixed-length array types starts from + zero, rather than from one as for variable-length arrays. +

Parameters

name

The name (optionally schema-qualified) of a type to be created. +

attribute_name

The name of an attribute (column) for the composite type. +

data_type

The name of an existing data type to become a column of the + composite type. +

collation

The name of an existing collation to be associated with a column of + a composite type, or with a range type. +

label

A string literal representing the textual label associated with + one value of an enum type. +

subtype

The name of the element type that the range type will represent ranges + of. +

subtype_operator_class

The name of a b-tree operator class for the subtype. +

canonical_function

The name of the canonicalization function for the range type. +

subtype_diff_function

The name of a difference function for the subtype. +

input_function

The name of a function that converts data from the type's + external textual form to its internal form. +

output_function

The name of a function that converts data from the type's + internal form to its external textual form. +

receive_function

The name of a function that converts data from the type's + external binary form to its internal form. +

send_function

The name of a function that converts data from the type's + internal form to its external binary form. +

type_modifier_input_function

The name of a function that converts an array of modifier(s) for the type + into internal form. +

type_modifier_output_function

The name of a function that converts the internal form of the type's + modifier(s) to external textual form. +

analyze_function

The name of a function that performs statistical analysis for the + data type. +

internallength

A numeric constant that specifies the length in bytes of the new + type's internal representation. The default assumption is that + it is variable-length. +

alignment

The storage alignment requirement of the data type. If specified, + it must be char, int2, + int4, or double; the + default is int4. +

storage

The storage strategy for the data type. If specified, must be + plain, external, + extended, or main; the + default is plain. +

like_type

The name of an existing data type that the new type will have the + same representation as. The values of + internallength, + passedbyvalue, + alignment, and + storage + are copied from that type, unless overridden by explicit + specification elsewhere in this CREATE TYPE command. +

category

The category code (a single ASCII character) for this type. + The default is 'U' for "user-defined type". + Other standard category codes can be found in + Table 45-51. You may also choose + other ASCII characters in order to create custom categories. +

preferred

True if this type is a preferred type within its type category, + else false. The default is false. Be very careful about creating + a new preferred type within an existing type category, as this + could cause surprising changes in behavior. +

default

The default value for the data type. If this is omitted, the + default is null. +

element

The type being created is an array; this specifies the type of + the array elements. +

delimiter

The delimiter character to be used between values in arrays made + of this type. +

collatable

True if this type's operations can use collation information. + The default is false. +

Notes

Because there are no restrictions on use of a data type once it's been + created, creating a base type or range type is tantamount to granting + public execute permission on the functions mentioned in the type definition. + This is usually + not an issue for the sorts of functions that are useful in a type + definition. But you might want to think twice before designing a type + in a way that would require "secret" information to be used + while converting it to or from external form. +

Before PostgreSQL version 8.3, the name of + a generated array type was always exactly the element type's name with one + underscore character (_) prepended. (Type names were + therefore restricted in length to one less character than other names.) + While this is still usually the case, the array type name may vary from + this in case of maximum-length names or collisions with user type names + that begin with underscore. Writing code that depends on this convention + is therefore deprecated. Instead, use + pg_type.typarray to locate the array type + associated with a given type. +

It may be advisable to avoid using type and table names that begin with + underscore. While the server will change generated array type names to + avoid collisions with user-given names, there is still risk of confusion, + particularly with old client software that may assume that type names + beginning with underscores always represent arrays. +

Before PostgreSQL version 8.2, the shell-type + creation syntax + CREATE TYPE name did not exist. + The way to create a new base type was to create its input function first. + In this approach, PostgreSQL will first see + the name of the new data type as the return type of the input function. + The shell type is implicitly created in this situation, and then it + can be referenced in the definitions of the remaining I/O functions. + This approach still works, but is deprecated and might be disallowed in + some future release. Also, to avoid accidentally cluttering + the catalogs with shell types as a result of simple typos in function + definitions, a shell type will only be made this way when the input + function is written in C. +

In PostgreSQL versions before 7.3, it + was customary to avoid creating a shell type at all, by replacing the + functions' forward references to the type name with the placeholder + pseudotype opaque. The cstring arguments and + results also had to be declared as opaque before 7.3. To + support loading of old dump files, CREATE TYPE will + accept I/O functions declared using opaque, but it will issue + a notice and change the function declarations to use the correct + types. +

Examples

This example creates a composite type and uses it in + a function definition: +

CREATE TYPE compfoo AS (f1 int, f2 text);
+
+CREATE FUNCTION getfoo() RETURNS SETOF compfoo AS $$
+    SELECT fooid, fooname FROM foo
+$$ LANGUAGE SQL;

+

This example creates an enumerated type and uses it in + a table definition: +

CREATE TYPE bug_status AS ENUM ('new', 'open', 'closed');
+
+CREATE TABLE bug (
+    id serial,
+    description text,
+    status bug_status
+);

+

This example creates a range type: +

CREATE TYPE float8_range AS RANGE (subtype = float8, subtype_diff = float8mi);

+

This example creates the base data type box and then uses the + type in a table definition: +

CREATE TYPE box;
+
+CREATE FUNCTION my_box_in_function(cstring) RETURNS box AS ... ;
+CREATE FUNCTION my_box_out_function(box) RETURNS cstring AS ... ;
+
+CREATE TYPE box (
+    INTERNALLENGTH = 16,
+    INPUT = my_box_in_function,
+    OUTPUT = my_box_out_function
+);
+
+CREATE TABLE myboxes (
+    id integer,
+    description box
+);

+

If the internal structure of box were an array of four + float4 elements, we might instead use: +

CREATE TYPE box (
+    INTERNALLENGTH = 16,
+    INPUT = my_box_in_function,
+    OUTPUT = my_box_out_function,
+    ELEMENT = float4
+);

+ which would allow a box value's component numbers to be accessed + by subscripting. Otherwise the type behaves the same as before. +

This example creates a large object type and uses it in + a table definition: +

CREATE TYPE bigobj (
+    INPUT = lo_filein, OUTPUT = lo_fileout,
+    INTERNALLENGTH = VARIABLE
+);
+CREATE TABLE big_objs (
+    id integer,
+    obj bigobj
+);

+

More examples, including suitable input and output functions, are + in Section 35.11. +

Compatibility

The first form of the CREATE TYPE command, which + creates a composite type, conforms to the SQL standard. + The other forms are PostgreSQL + extensions. The CREATE TYPE statement in + the SQL standard also defines other forms that are not + implemented in PostgreSQL. +

The ability to create a composite type with zero attributes is + a PostgreSQL-specific deviation from the + standard (analogous to the same case in CREATE TABLE). +


PrevHomeNext
CREATE TRIGGERUpCREATE USER
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createuser.html b/doc/src/sgml/html/sql-createuser.html new file mode 100644 index 000000000..c1c3baa7a --- /dev/null +++ b/doc/src/sgml/html/sql-createuser.html @@ -0,0 +1,328 @@ + +CREATE USER

CREATE USER

Name

CREATE USER -- define a new database role

Synopsis

CREATE USER name [ [ WITH ] option [ ... ] ]
+
+where option can be:
+
+      SUPERUSER | NOSUPERUSER
+    | CREATEDB | NOCREATEDB
+    | CREATEROLE | NOCREATEROLE
+    | CREATEUSER | NOCREATEUSER
+    | INHERIT | NOINHERIT
+    | LOGIN | NOLOGIN
+    | REPLICATION | NOREPLICATION
+    | CONNECTION LIMIT connlimit
+    | [ ENCRYPTED | UNENCRYPTED ] PASSWORD 'password'
+    | VALID UNTIL 'timestamp'
+    | IN ROLE role_name [, ...]
+    | IN GROUP role_name [, ...]
+    | ROLE role_name [, ...]
+    | ADMIN role_name [, ...]
+    | USER role_name [, ...]
+    | SYSID uid

Description

CREATE USER is now an alias for + CREATE ROLE. + The only difference is that when the command is spelled + CREATE USER, LOGIN is assumed + by default, whereas NOLOGIN is assumed when + the command is spelled + CREATE ROLE. +

Compatibility

The CREATE USER statement is a + PostgreSQL extension. The SQL standard + leaves the definition of users to the implementation. +

See Also

CREATE ROLE

PrevHomeNext
CREATE TYPEUpCREATE USER MAPPING
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createusermapping.html b/doc/src/sgml/html/sql-createusermapping.html new file mode 100644 index 000000000..d5eebd555 --- /dev/null +++ b/doc/src/sgml/html/sql-createusermapping.html @@ -0,0 +1,357 @@ + +CREATE USER MAPPING

CREATE USER MAPPING

Name

CREATE USER MAPPING -- define a new mapping of a user to a foreign server

Synopsis

CREATE USER MAPPING FOR { user_name | USER | CURRENT_USER | PUBLIC }
+    SERVER server_name
+    [ OPTIONS ( option 'value' [ , ... ] ) ]

Description

CREATE USER MAPPING defines a mapping of a user + to a foreign server. A user mapping typically encapsulates + connection information that a foreign-data wrapper uses together + with the information encapsulated by a foreign server to access an + external data resource. +

The owner of a foreign server can create user mappings for that + server for any user. Also, a user can create a user mapping for + his own user name if USAGE privilege on the server has + been granted to the user. +

Parameters

user_name

The name of an existing user that is mapped to foreign server. + CURRENT_USER and USER match the name of + the current user. When PUBLIC is specified, a + so-called public mapping is created that is used when no + user-specific mapping is applicable. +

server_name

The name of an existing server for which the user mapping is + to be created. +

OPTIONS ( option 'value' [, ... ] )

This clause specifies the options of the user mapping. The + options typically define the actual user name and password of + the mapping. Option names must be unique. The allowed option + names and values are specific to the server's foreign-data wrapper. +

Examples

Create a user mapping for user bob, server foo: +

CREATE USER MAPPING FOR bob SERVER foo OPTIONS (user 'bob', password 'secret');

Compatibility

CREATE USER MAPPING conforms to ISO/IEC 9075-9 (SQL/MED). +


PrevHomeNext
CREATE USERUpCREATE VIEW
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-createview.html b/doc/src/sgml/html/sql-createview.html new file mode 100644 index 000000000..8d0b68b51 --- /dev/null +++ b/doc/src/sgml/html/sql-createview.html @@ -0,0 +1,589 @@ + +CREATE VIEW

CREATE VIEW

Name

CREATE VIEW -- define a new view

Synopsis

CREATE [ OR REPLACE ] [ TEMP | TEMPORARY ] VIEW name [ ( column_name [, ...] ) ]
+    [ WITH ( view_option_name [= view_option_value] [, ... ] ) ]
+    AS query

Description

CREATE VIEW defines a view of a query. The view + is not physically materialized. Instead, the query is run every time + the view is referenced in a query. +

CREATE OR REPLACE VIEW is similar, but if a view + of the same name already exists, it is replaced. The new query must + generate the same columns that were generated by the existing view query + (that is, the same column names in the same order and with the same data + types), but it may add additional columns to the end of the list. The + calculations giving rise to the output columns may be completely different. +

If a schema name is given (for example, CREATE VIEW + myschema.myview ...) then the view is created in the specified + schema. Otherwise it is created in the current schema. Temporary + views exist in a special schema, so a schema name cannot be given + when creating a temporary view. The name of the view must be + distinct from the name of any other view, table, sequence, index or foreign table + in the same schema. +

Parameters

TEMPORARY or TEMP

If specified, the view is created as a temporary view. + Temporary views are automatically dropped at the end of the + current session. Existing + permanent relations with the same name are not visible to the + current session while the temporary view exists, unless they are + referenced with schema-qualified names. +

If any of the tables referenced by the view are temporary, + the view is created as a temporary view (whether + TEMPORARY is specified or not). +

name

The name (optionally schema-qualified) of a view to be created. +

column_name

An optional list of names to be used for columns of the view. + If not given, the column names are deduced from the query. +

WITH ( view_option_name [= view_option_value] [, ... ] )

This clause specifies optional parameters for a view; currently, the + only supported parameter name is security_barrier, + which should be enabled when a view is intended to provide row-level + security. See Section 37.4 for full details. +

query

A SELECT or + VALUES command + which will provide the columns and rows of the view. +

Notes

Currently, views are read only: the system will not allow an insert, + update, or delete on a view. You can get the effect of an updatable + view by creating INSTEAD triggers on the view, which + must convert attempted inserts, etc. on the view into + appropriate actions on other tables. For more information see + CREATE TRIGGER. Another possibility is to create + rules (see CREATE RULE), but in practice triggers + are easier to understand and use correctly. +

Use the DROP VIEW + statement to drop views. +

Be careful that the names and types of the view's columns will be + assigned the way you want. For example: +

CREATE VIEW vista AS SELECT 'Hello World';

+ is bad form in two ways: the column name defaults to ?column?, + and the column data type defaults to unknown. If you want a + string literal in a view's result, use something like: +

CREATE VIEW vista AS SELECT text 'Hello World' AS hello;

+

Access to tables referenced in the view is determined by permissions of + the view owner. In some cases, this can be used to provide secure but + restricted access to the underlying tables. However, not all views are + secure against tampering; see Section 37.4 for + details. Functions called in the view are treated the same as if they had + been called directly from the query using the view. Therefore the user of + a view must have permissions to call all functions used by the view. +

When CREATE OR REPLACE VIEW is used on an + existing view, only the view's defining SELECT rule is changed. + Other view properties, including ownership, permissions, and non-SELECT + rules, remain unchanged. You must own the view + to replace it (this includes being a member of the owning role). +

Examples

Create a view consisting of all comedy films: + +

CREATE VIEW comedies AS
+    SELECT *
+    FROM films
+    WHERE kind = 'Comedy';

+ This will create a view containing the columns that are in the + film table at the time of view creation. Though + * was used to create the view, columns added later to + the table will not be part of the view. +

Compatibility

The SQL standard specifies some additional capabilities for the + CREATE VIEW statement: +

CREATE VIEW name [ ( column_name [, ...] ) ]
+    AS query
+    [ WITH [ CASCADED | LOCAL ] CHECK OPTION ]

+

The optional clauses for the full SQL command are: + +

CHECK OPTION

This option has to do with updatable views. All + INSERT and UPDATE commands on the view + will be checked to ensure data satisfy the view-defining + condition (that is, the new data would be visible through the + view). If they do not, the update will be rejected. +

LOCAL

Check for integrity on this view. +

CASCADED

Check for integrity on this view and on any dependent + view. CASCADED is assumed if neither + CASCADED nor LOCAL is specified. +

+

CREATE OR REPLACE VIEW is a + PostgreSQL language extension. + So is the concept of a temporary view. +


PrevHomeNext
CREATE USER MAPPINGUpDEALLOCATE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-deallocate.html b/doc/src/sgml/html/sql-deallocate.html new file mode 100644 index 000000000..b477a7f84 --- /dev/null +++ b/doc/src/sgml/html/sql-deallocate.html @@ -0,0 +1,281 @@ + +DEALLOCATE

DEALLOCATE

Name

DEALLOCATE -- deallocate a prepared statement

Synopsis

DEALLOCATE [ PREPARE ] { name | ALL }

Description

DEALLOCATE is used to deallocate a previously + prepared SQL statement. If you do not explicitly deallocate a + prepared statement, it is deallocated when the session ends. +

For more information on prepared statements, see PREPARE. +

Parameters

PREPARE

This key word is ignored. +

name

The name of the prepared statement to deallocate. +

ALL

Deallocate all prepared statements. +

Compatibility

The SQL standard includes a DEALLOCATE + statement, but it is only for use in embedded SQL. +

See Also

EXECUTE, PREPARE

PrevHomeNext
CREATE VIEWUpDECLARE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-declare.html b/doc/src/sgml/html/sql-declare.html new file mode 100644 index 000000000..e268a87d2 --- /dev/null +++ b/doc/src/sgml/html/sql-declare.html @@ -0,0 +1,835 @@ + +DECLARE

DECLARE

Name

DECLARE -- define a cursor

Synopsis

DECLARE name [ BINARY ] [ INSENSITIVE ] [ [ NO ] SCROLL ]
+    CURSOR [ { WITH | WITHOUT } HOLD ] FOR query

Description

DECLARE allows a user to create cursors, which + can be used to retrieve + a small number of rows at a time out of a larger query. + After the cursor is created, rows are fetched from it using + FETCH. +

Note: This page describes usage of cursors at the SQL command level. + If you are trying to use cursors inside a PL/pgSQL + function, the rules are different — + see Section 39.7. +

Parameters

name

The name of the cursor to be created. +

BINARY

Causes the cursor to return data in binary rather than in text format. +

INSENSITIVE

Indicates that data retrieved from the cursor should be + unaffected by updates to the table(s) underlying the cursor that occur + after the cursor is created. In PostgreSQL, + this is the default behavior; so this key word has no + effect and is only accepted for compatibility with the SQL standard. +

SCROLL
NO SCROLL

SCROLL specifies that the cursor can be used + to retrieve rows in a nonsequential fashion (e.g., + backward). Depending upon the complexity of the query's + execution plan, specifying SCROLL might impose + a performance penalty on the query's execution time. + NO SCROLL specifies that the cursor cannot be + used to retrieve rows in a nonsequential fashion. The default is to + allow scrolling in some cases; this is not the same as specifying + SCROLL. See Notes for details. +

WITH HOLD
WITHOUT HOLD

WITH HOLD specifies that the cursor can + continue to be used after the transaction that created it + successfully commits. WITHOUT HOLD specifies + that the cursor cannot be used outside of the transaction that + created it. If neither WITHOUT HOLD nor + WITH HOLD is specified, WITHOUT + HOLD is the default. +

query

A SELECT or + VALUES command + which will provide the rows to be returned by the cursor. +

The key words BINARY, + INSENSITIVE, and SCROLL can + appear in any order. +

Notes

Normal cursors return data in text format, the same as a + SELECT would produce. The BINARY option + specifies that the cursor should return data in binary format. + This reduces conversion effort for both the server and client, + at the cost of more programmer effort to deal with platform-dependent + binary data formats. + As an example, if a query returns a value of one from an integer column, + you would get a string of 1 with a default cursor, + whereas with a binary cursor you would get + a 4-byte field containing the internal representation of the value + (in big-endian byte order). +

Binary cursors should be used carefully. Many applications, + including psql, are not prepared to + handle binary cursors and expect data to come back in the text + format. +

Note: When the client application uses the "extended query" protocol + to issue a FETCH command, the Bind protocol message + specifies whether data is to be retrieved in text or binary format. + This choice overrides the way that the cursor is defined. The concept + of a binary cursor as such is thus obsolete when using extended query + protocol — any cursor can be treated as either text or binary. +

Unless WITH HOLD is specified, the cursor + created by this command can only be used within the current + transaction. Thus, DECLARE without WITH + HOLD is useless outside a transaction block: the cursor would + survive only to the completion of the statement. Therefore + PostgreSQL reports an error if such a + command is used outside a transaction block. + Use + BEGIN and + COMMIT + (or ROLLBACK) + to define a transaction block. +

If WITH HOLD is specified and the transaction + that created the cursor successfully commits, the cursor can + continue to be accessed by subsequent transactions in the same + session. (But if the creating transaction is aborted, the cursor + is removed.) A cursor created with WITH HOLD + is closed when an explicit CLOSE command is + issued on it, or the session ends. In the current implementation, + the rows represented by a held cursor are copied into a temporary + file or memory area so that they remain available for subsequent + transactions. +

WITH HOLD may not be specified when the query + includes FOR UPDATE or FOR SHARE. +

The SCROLL option should be specified when defining a + cursor that will be used to fetch backwards. This is required by + the SQL standard. However, for compatibility with earlier + versions, PostgreSQL will allow + backward fetches without SCROLL, if the cursor's query + plan is simple enough that no extra overhead is needed to support + it. However, application developers are advised not to rely on + using backward fetches from a cursor that has not been created + with SCROLL. If NO SCROLL is + specified, then backward fetches are disallowed in any case. +

Backward fetches are also disallowed when the query + includes FOR UPDATE or FOR SHARE; therefore + SCROLL may not be specified in this case. +

Caution

Scrollable and WITH HOLD cursors may give unexpected + results if they invoke any volatile functions (see Section 35.6). When a previously fetched row is + re-fetched, the functions might be re-executed, perhaps leading to + results different from the first time. One workaround for such cases + is to declare the cursor WITH HOLD and commit the + transaction before reading any rows from it. This will force the + entire output of the cursor to be materialized in temporary storage, + so that volatile functions are executed exactly once for each row. +

If the cursor's query includes FOR UPDATE or FOR + SHARE, then returned rows are locked at the time they are first + fetched, in the same way as for a regular + SELECT command with + these options. + In addition, the returned rows will be the most up-to-date versions; + therefore these options provide the equivalent of what the SQL standard + calls a "sensitive cursor". (Specifying INSENSITIVE + together with FOR UPDATE or FOR SHARE is an error.) +

Caution

It is generally recommended to use FOR UPDATE if the cursor + is intended to be used with UPDATE ... WHERE CURRENT OF or + DELETE ... WHERE CURRENT OF. Using FOR UPDATE + prevents other sessions from changing the rows between the time they are + fetched and the time they are updated. Without FOR UPDATE, + a subsequent WHERE CURRENT OF command will have no effect if + the row was changed since the cursor was created. +

Another reason to use FOR UPDATE is that without it, a + subsequent WHERE CURRENT OF might fail if the cursor query + does not meet the SQL standard's rules for being "simply + updatable" (in particular, the cursor must reference just one table + and not use grouping or ORDER BY). Cursors + that are not simply updatable might work, or might not, depending on plan + choice details; so in the worst case, an application might work in testing + and then fail in production. +

The main reason not to use FOR UPDATE with WHERE + CURRENT OF is if you need the cursor to be scrollable, or to be + insensitive to the subsequent updates (that is, continue to show the old + data). If this is a requirement, pay close heed to the caveats shown + above. +

The SQL standard only makes provisions for cursors in embedded + SQL. The PostgreSQL + server does not implement an OPEN statement for + cursors; a cursor is considered to be open when it is declared. + However, ECPG, the embedded SQL + preprocessor for PostgreSQL, supports + the standard SQL cursor conventions, including those involving + DECLARE and OPEN statements. +

You can see all available cursors by querying the pg_cursors + system view. +

Examples

To declare a cursor: +

DECLARE liahona CURSOR FOR SELECT * FROM films;

+ See FETCH for more + examples of cursor usage. +

Compatibility

The SQL standard says that it is implementation-dependent whether cursors + are sensitive to concurrent updates of the underlying data by default. In + PostgreSQL, cursors are insensitive by default, + and can be made sensitive by specifying FOR UPDATE. Other + products may work differently. +

The SQL standard allows cursors only in embedded + SQL and in modules. PostgreSQL + permits cursors to be used interactively. +

Binary cursors are a PostgreSQL + extension. +

See Also

CLOSE, FETCH, MOVE

PrevHomeNext
DEALLOCATEUpDELETE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-delete.html b/doc/src/sgml/html/sql-delete.html new file mode 100644 index 000000000..d9d566881 --- /dev/null +++ b/doc/src/sgml/html/sql-delete.html @@ -0,0 +1,738 @@ + +DELETE

DELETE

Name

DELETE -- delete rows of a table

Synopsis

[ WITH [ RECURSIVE ] with_query [, ...] ]
+DELETE FROM [ ONLY ] table_name [ * ] [ [ AS ] alias ]
+    [ USING using_list ]
+    [ WHERE condition | WHERE CURRENT OF cursor_name ]
+    [ RETURNING * | output_expression [ [ AS ] output_name ] [, ...] ]

Description

DELETE deletes rows that satisfy the + WHERE clause from the specified table. If the + WHERE clause is absent, the effect is to delete + all rows in the table. The result is a valid, but empty table. +

Tip: TRUNCATE is a + PostgreSQL extension that provides a + faster mechanism to remove all rows from a table. +

There are two ways to delete rows in a table using information + contained in other tables in the database: using sub-selects, or + specifying additional tables in the USING clause. + Which technique is more appropriate depends on the specific + circumstances. +

The optional RETURNING clause causes DELETE + to compute and return value(s) based on each row actually deleted. + Any expression using the table's columns, and/or columns of other + tables mentioned in USING, can be computed. + The syntax of the RETURNING list is identical to that of the + output list of SELECT. +

You must have the DELETE privilege on the table + to delete from it, as well as the SELECT + privilege for any table in the USING clause or + whose values are read in the condition. +

Parameters

with_query

The WITH clause allows you to specify one or more + subqueries that can be referenced by name in the DELETE + query. See Section 7.8 and SELECT + for details. +

table_name

The name (optionally schema-qualified) of the table to delete rows + from. If ONLY is specified before the table name, + matching rows are deleted from the named table only. If + ONLY is not specified, matching rows are also deleted + from any tables inheriting from the named table. Optionally, + * can be specified after the table name to explicitly + indicate that descendant tables are included. +

alias

A substitute name for the target table. When an alias is + provided, it completely hides the actual name of the table. For + example, given DELETE FROM foo AS f, the remainder + of the DELETE statement must refer to this + table as f not foo. +

using_list

A list of table expressions, allowing columns from other tables + to appear in the WHERE condition. This is similar + to the list of tables that can be specified in the FROM Clause of a + SELECT statement; for example, an alias for + the table name can be specified. Do not repeat the target table + in the using_list, + unless you wish to set up a self-join. +

condition

An expression that returns a value of type boolean. + Only rows for which this expression returns true + will be deleted. +

cursor_name

The name of the cursor to use in a WHERE CURRENT OF + condition. The row to be deleted is the one most recently fetched + from this cursor. The cursor must be a non-grouping + query on the DELETE's target table. + Note that WHERE CURRENT OF cannot be + specified together with a Boolean condition. See + DECLARE + for more information about using cursors with + WHERE CURRENT OF. +

output_expression

An expression to be computed and returned by the DELETE + command after each row is deleted. The expression can use any + column names of the table named by table_name + or table(s) listed in USING. + Write * to return all columns. +

output_name

A name to use for a returned column. +

Outputs

On successful completion, a DELETE command returns a command + tag of the form +

DELETE count

+ The count is the number + of rows deleted. Note that the number may be less than the number of + rows that matched the condition when deletes were + suppressed by a BEFORE DELETE trigger. If count is 0, no rows were deleted by + the query (this is not considered an error). +

If the DELETE command contains a RETURNING + clause, the result will be similar to that of a SELECT + statement containing the columns and values defined in the + RETURNING list, computed over the row(s) deleted by the + command. +

Notes

PostgreSQL lets you reference columns of + other tables in the WHERE condition by specifying the + other tables in the USING clause. For example, + to delete all films produced by a given producer, one can do: +

DELETE FROM films USING producers
+  WHERE producer_id = producers.id AND producers.name = 'foo';

+ What is essentially happening here is a join between films + and producers, with all successfully joined + films rows being marked for deletion. + This syntax is not standard. A more standard way to do it is: +

DELETE FROM films
+  WHERE producer_id IN (SELECT id FROM producers WHERE name = 'foo');

+ In some cases the join style is easier to write or faster to + execute than the sub-select style. +

Examples

Delete all films but musicals: +

DELETE FROM films WHERE kind <> 'Musical';

+

Clear the table films: +

DELETE FROM films;

+

Delete completed tasks, returning full details of the deleted rows: +

DELETE FROM tasks WHERE status = 'DONE' RETURNING *;

+

Delete the row of tasks on which the cursor + c_tasks is currently positioned: +

DELETE FROM tasks WHERE CURRENT OF c_tasks;

Compatibility

This command conforms to the SQL standard, except + that the USING and RETURNING clauses + are PostgreSQL extensions, as is the ability + to use WITH with DELETE. +


PrevHomeNext
DECLAREUpDISCARD
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-discard.html b/doc/src/sgml/html/sql-discard.html new file mode 100644 index 000000000..b67452258 --- /dev/null +++ b/doc/src/sgml/html/sql-discard.html @@ -0,0 +1,302 @@ + +DISCARD

DISCARD

Name

DISCARD -- discard session state

Synopsis

DISCARD { ALL | PLANS | TEMPORARY | TEMP }

Description

DISCARD releases internal resources associated with a + database session. These resources are normally released at the end + of the session. +

DISCARD TEMP drops all temporary tables created in the + current session. DISCARD PLANS releases all internally + cached query plans. DISCARD ALL resets a session to + its original state, discarding temporary resources and resetting + session-local configuration changes. +

Parameters

TEMPORARY or TEMP

Drops all temporary tables created in the current session. +

PLANS

Releases all cached query plans. +

ALL

Releases all temporary resources associated with the current + session and resets the session to its initial state. + Currently, this has the same effect as executing the following sequence + of statements: +

SET SESSION AUTHORIZATION DEFAULT;
+RESET ALL;
+DEALLOCATE ALL;
+CLOSE ALL;
+UNLISTEN *;
+SELECT pg_advisory_unlock_all();
+DISCARD PLANS;
+DISCARD TEMP;

Notes

DISCARD ALL cannot be executed inside a transaction block. +

Compatibility

DISCARD is a PostgreSQL extension. +

\ No newline at end of file diff --git a/doc/src/sgml/html/sql-do.html b/doc/src/sgml/html/sql-do.html new file mode 100644 index 000000000..7d49bc45a --- /dev/null +++ b/doc/src/sgml/html/sql-do.html @@ -0,0 +1,347 @@ + +DO

DO

Name

DO -- execute an anonymous code block

Synopsis

DO [ LANGUAGE lang_name ] code

Description

DO executes an anonymous code block, or in other + words a transient anonymous function in a procedural language. +

The code block is treated as though it were the body of a function + with no parameters, returning void. It is parsed and + executed a single time. +

The optional LANGUAGE clause can be written either + before or after the code block. +

Parameters

code

The procedural language code to be executed. This must be specified + as a string literal, just as in CREATE FUNCTION. + Use of a dollar-quoted literal is recommended. +

lang_name

The name of the procedural language the code is written in. + If omitted, the default is plpgsql. +

Notes

The procedural language to be used must already have been installed + into the current database by means of CREATE LANGUAGE. + plpgsql is installed by default, but other languages are not. +

The user must have USAGE privilege for the procedural + language, or must be a superuser if the language is untrusted. + This is the same privilege requirement as for creating a function + in the language. +

Examples

Grant all privileges on all views in schema public to + role webuser: +

DO $$DECLARE r record;
+BEGIN
+    FOR r IN SELECT table_schema, table_name FROM information_schema.tables
+             WHERE table_type = 'VIEW' AND table_schema = 'public'
+    LOOP
+        EXECUTE 'GRANT ALL ON ' || quote_ident(r.table_schema) || '.' || quote_ident(r.table_name) || ' TO webuser';
+    END LOOP;
+END$$;

Compatibility

There is no DO statement in the SQL standard. +


PrevHomeNext
DISCARDUpDROP AGGREGATE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-drop-owned.html b/doc/src/sgml/html/sql-drop-owned.html new file mode 100644 index 000000000..08f26a95d --- /dev/null +++ b/doc/src/sgml/html/sql-drop-owned.html @@ -0,0 +1,320 @@ + +DROP OWNED

DROP OWNED

Name

DROP OWNED -- remove database objects owned by a database role

Synopsis

DROP OWNED BY name [, ...] [ CASCADE | RESTRICT ]

Description

DROP OWNED drops all the objects in the current + database that are owned by one of the specified roles. Any + privileges granted to the given roles on objects in the current + database will also be revoked. +

Parameters

name

The name of a role whose objects will be dropped, and whose + privileges will be revoked. +

CASCADE

Automatically drop objects that depend on the affected objects. +

RESTRICT

Refuse to drop the objects owned by a role if any other database + objects depend on one of the affected objects. This is the default. +

Notes

DROP OWNED is often used to prepare for the + removal of one or more roles. Because DROP OWNED + only affects the objects in the current database, it is usually + necessary to execute this command in each database that contains + objects owned by a role that is to be removed. +

Using the CASCADE option might make the command + recurse to objects owned by other users. +

The REASSIGN OWNED command is an alternative that + reassigns the ownership of all the database objects owned by one or + more roles. +

Databases owned by the role(s) will not be removed. +

Compatibility

The DROP OWNED statement is a + PostgreSQL extension. +


PrevHomeNext
DROP OPERATOR FAMILYUpDROP ROLE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-dropaggregate.html b/doc/src/sgml/html/sql-dropaggregate.html new file mode 100644 index 000000000..aa2f54523 --- /dev/null +++ b/doc/src/sgml/html/sql-dropaggregate.html @@ -0,0 +1,330 @@ + +DROP AGGREGATE

DROP AGGREGATE

Name

DROP AGGREGATE -- remove an aggregate function

Synopsis

DROP AGGREGATE [ IF EXISTS ] name ( argtype [ , ... ] ) [ CASCADE | RESTRICT ]

Description

DROP AGGREGATE removes an existing + aggregate function. To execute this command the current + user must be the owner of the aggregate function. +

Parameters

IF EXISTS

Do not throw an error if the aggregate does not exist. A notice is issued + in this case. +

name

The name (optionally schema-qualified) of an existing aggregate function. +

argtype

An input data type on which the aggregate function operates. + To reference a zero-argument aggregate function, write * + in place of the list of input data types. +

CASCADE

Automatically drop objects that depend on the aggregate function. +

RESTRICT

Refuse to drop the aggregate function if any objects depend on + it. This is the default. +

Examples

To remove the aggregate function myavg for type + integer: +

DROP AGGREGATE myavg(integer);

Compatibility

There is no DROP AGGREGATE statement in the SQL + standard. +


PrevHomeNext
DOUpDROP CAST
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-dropcast.html b/doc/src/sgml/html/sql-dropcast.html new file mode 100644 index 000000000..6c81887c3 --- /dev/null +++ b/doc/src/sgml/html/sql-dropcast.html @@ -0,0 +1,316 @@ + +DROP CAST

DROP CAST

Name

DROP CAST -- remove a cast

Synopsis

DROP CAST [ IF EXISTS ] (source_type AS target_type) [ CASCADE | RESTRICT ]

Description

DROP CAST removes a previously defined cast. +

To be able to drop a cast, you must own the source or the target + data type. These are the same privileges that are required to + create a cast. +

Parameters

IF EXISTS

Do not throw an error if the cast does not exist. A notice is issued + in this case. +

source_type

The name of the source data type of the cast. +

target_type

The name of the target data type of the cast. +

CASCADE
RESTRICT

These key words do not have any effect, since there are no + dependencies on casts. +

Examples

To drop the cast from type text to type int: +

DROP CAST (text AS int);

Compatibility

The DROP CAST command conforms to the SQL standard. +

See Also

CREATE CAST

PrevHomeNext
DROP AGGREGATEUpDROP COLLATION
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-dropcollation.html b/doc/src/sgml/html/sql-dropcollation.html new file mode 100644 index 000000000..d7f9837cf --- /dev/null +++ b/doc/src/sgml/html/sql-dropcollation.html @@ -0,0 +1,314 @@ + +DROP COLLATION

DROP COLLATION

Name

DROP COLLATION -- remove a collation

Synopsis

DROP COLLATION [ IF EXISTS ] name [ CASCADE | RESTRICT ]

Description

DROP COLLATION removes a previously defined collation. + To be able to drop a collation, you must own the collation. +

Parameters

IF EXISTS

Do not throw an error if the collation does not exist. + A notice is issued in this case. +

name

The name of the collation. The collation name can be + schema-qualified. +

CASCADE

Automatically drop objects that depend on the collation. +

RESTRICT

Refuse to drop the collation if any objects depend on it. This + is the default. +

Examples

To drop the collation named german: +

DROP COLLATION german;

Compatibility

The DROP COLLATION command conforms to the + SQL standard, apart from the IF + EXISTS option, which is a PostgreSQL extension. +


PrevHomeNext
DROP CASTUpDROP CONVERSION
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-dropconversion.html b/doc/src/sgml/html/sql-dropconversion.html new file mode 100644 index 000000000..325d55099 --- /dev/null +++ b/doc/src/sgml/html/sql-dropconversion.html @@ -0,0 +1,309 @@ + +DROP CONVERSION

DROP CONVERSION

Name

DROP CONVERSION -- remove a conversion

Synopsis

DROP CONVERSION [ IF EXISTS ] name [ CASCADE | RESTRICT ]

Description

DROP CONVERSION removes a previously defined conversion. + To be able to drop a conversion, you must own the conversion. +

Parameters

IF EXISTS

Do not throw an error if the conversion does not exist. + A notice is issued in this case. +

name

The name of the conversion. The conversion name can be + schema-qualified. +

CASCADE
RESTRICT

These key words do not have any effect, since there are no + dependencies on conversions. +

Examples

To drop the conversion named myname: +

DROP CONVERSION myname;

Compatibility

There is no DROP CONVERSION statement in the SQL + standard, but a DROP TRANSLATION statement that + goes along with the CREATE TRANSLATION statement + that is similar to the CREATE CONVERSION + statement in PostgreSQL. +


PrevHomeNext
DROP COLLATIONUpDROP DATABASE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-dropdatabase.html b/doc/src/sgml/html/sql-dropdatabase.html new file mode 100644 index 000000000..4f190788e --- /dev/null +++ b/doc/src/sgml/html/sql-dropdatabase.html @@ -0,0 +1,301 @@ + +DROP DATABASE

DROP DATABASE

Name

DROP DATABASE -- remove a database

Synopsis

DROP DATABASE [ IF EXISTS ] name

Description

DROP DATABASE drops a database. It removes the + catalog entries for the database and deletes the directory + containing the data. It can only be executed by the database owner. + Also, it cannot be executed while you or anyone else are connected + to the target database. (Connect to postgres or any + other database to issue this command.) +

DROP DATABASE cannot be undone. Use it with care! +

Parameters

IF EXISTS

Do not throw an error if the database does not exist. A notice is issued + in this case. +

name

The name of the database to remove. +

Notes

DROP DATABASE cannot be executed inside a transaction + block. +

This command cannot be executed while connected to the target + database. Thus, it might be more convenient to use the program + dropdb instead, + which is a wrapper around this command. +

Compatibility

There is no DROP DATABASE statement in the SQL standard. +


PrevHomeNext
DROP CONVERSIONUpDROP DOMAIN
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-dropdomain.html b/doc/src/sgml/html/sql-dropdomain.html new file mode 100644 index 000000000..a02572731 --- /dev/null +++ b/doc/src/sgml/html/sql-dropdomain.html @@ -0,0 +1,309 @@ + +DROP DOMAIN

DROP DOMAIN

Name

DROP DOMAIN -- remove a domain

Synopsis

DROP DOMAIN [ IF EXISTS ] name [, ...] [ CASCADE | RESTRICT ]

Description

DROP DOMAIN removes a domain. Only the owner of + a domain can remove it. +

Parameters

IF EXISTS

Do not throw an error if the domain does not exist. A notice is issued + in this case. +

name

The name (optionally schema-qualified) of an existing domain. +

CASCADE

Automatically drop objects that depend on the domain (such as + table columns). +

RESTRICT

Refuse to drop the domain if any objects depend on it. This is + the default. +

Examples

To remove the domain box: + +

DROP DOMAIN box;

Compatibility

This command conforms to the SQL standard, except for the + IF EXISTS option, which is a PostgreSQL + extension. +


PrevHomeNext
DROP DATABASEUpDROP EXTENSION
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-dropextension.html b/doc/src/sgml/html/sql-dropextension.html new file mode 100644 index 000000000..507216e8c --- /dev/null +++ b/doc/src/sgml/html/sql-dropextension.html @@ -0,0 +1,331 @@ + +DROP EXTENSION

DROP EXTENSION

Name

DROP EXTENSION -- remove an extension

Synopsis

DROP EXTENSION [ IF EXISTS ] name [, ...] [ CASCADE | RESTRICT ]

Description

DROP EXTENSION removes extensions from the database. + Dropping an extension causes its component objects to be dropped as well. +

You must own the extension to use DROP EXTENSION. +

Parameters

IF EXISTS

Do not throw an error if the extension does not exist. A notice is issued + in this case. +

name

The name of an installed extension. +

CASCADE

Automatically drop objects that depend on the extension. +

RESTRICT

Refuse to drop the extension if any objects depend on it (other than + its own member objects and other extensions listed in the same + DROP command). This is the default. +

Examples

To remove the extension hstore from the current + database: +

DROP EXTENSION hstore;

+ This command will fail if any of hstore's objects + are in use in the database, for example if any tables have columns + of the hstore type. Add the CASCADE option to + forcibly remove those dependent objects as well. +

Compatibility

DROP EXTENSION is a PostgreSQL + extension. +


PrevHomeNext
DROP DOMAINUpDROP FOREIGN DATA WRAPPER
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-dropforeigndatawrapper.html b/doc/src/sgml/html/sql-dropforeigndatawrapper.html new file mode 100644 index 000000000..17442f630 --- /dev/null +++ b/doc/src/sgml/html/sql-dropforeigndatawrapper.html @@ -0,0 +1,312 @@ + +DROP FOREIGN DATA WRAPPER

DROP FOREIGN DATA WRAPPER

Name

DROP FOREIGN DATA WRAPPER -- remove a foreign-data wrapper

Synopsis

DROP FOREIGN DATA WRAPPER [ IF EXISTS ] name [ CASCADE | RESTRICT ]

Description

DROP FOREIGN DATA WRAPPER removes an existing + foreign-data wrapper. To execute this command, the current user + must be the owner of the foreign-data wrapper. +

Parameters

IF EXISTS

Do not throw an error if the foreign-data wrapper does not + exist. A notice is issued in this case. +

name

The name of an existing foreign-data wrapper. +

CASCADE

Automatically drop objects that depend on the foreign-data + wrapper (such as servers). +

RESTRICT

Refuse to drop the foreign-data wrappers if any objects depend + on it. This is the default. +

Examples

Drop the foreign-data wrapper dbi: +

DROP FOREIGN DATA WRAPPER dbi;

Compatibility

DROP FOREIGN DATA WRAPPER conforms to ISO/IEC + 9075-9 (SQL/MED). The IF EXISTS clause is + a PostgreSQL extension. +


PrevHomeNext
DROP EXTENSIONUpDROP FOREIGN TABLE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-dropforeigntable.html b/doc/src/sgml/html/sql-dropforeigntable.html new file mode 100644 index 000000000..a5668a025 --- /dev/null +++ b/doc/src/sgml/html/sql-dropforeigntable.html @@ -0,0 +1,314 @@ + +DROP FOREIGN TABLE

DROP FOREIGN TABLE

Name

DROP FOREIGN TABLE -- remove a foreign table

Synopsis

DROP FOREIGN TABLE [ IF EXISTS ] name [, ...] [ CASCADE | RESTRICT ]

Description

DROP FOREIGN TABLE removes a foreign table. + Only the owner of a foreign table can remove it. +

Parameters

IF EXISTS

Do not throw an error if the foreign table does not exist. + A notice is issued in this case. +

name

The name (optionally schema-qualified) of the foreign table to drop. +

CASCADE

Automatically drop objects that depend on the foreign table (such as + views). +

RESTRICT

Refuse to drop the foreign table if any objects depend on it. This is + the default. +

Examples

To destroy two foreign tables, films and + distributors: + +

DROP FOREIGN TABLE films, distributors;

Compatibility

This command conforms to the ISO/IEC 9075-9 (SQL/MED), except that the + standard only allows one foreign table to be dropped per command, and apart + from the IF EXISTS option, which is a PostgreSQL + extension. +


PrevHomeNext
DROP FOREIGN DATA WRAPPERUpDROP FUNCTION
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-dropfunction.html b/doc/src/sgml/html/sql-dropfunction.html new file mode 100644 index 000000000..e160f7b72 --- /dev/null +++ b/doc/src/sgml/html/sql-dropfunction.html @@ -0,0 +1,401 @@ + +DROP FUNCTION

DROP FUNCTION

Name

DROP FUNCTION -- remove a function

Synopsis

DROP FUNCTION [ IF EXISTS ] name ( [ [ argmode ] [ argname ] argtype [, ...] ] )
+    [ CASCADE | RESTRICT ]

Description

DROP FUNCTION removes the definition of an existing + function. To execute this command the user must be the + owner of the function. The argument types to the + function must be specified, since several different functions + can exist with the same name and different argument lists. +

Parameters

IF EXISTS

Do not throw an error if the function does not exist. A notice is issued + in this case. +

name

The name (optionally schema-qualified) of an existing function. +

argmode

The mode of an argument: IN, OUT, + INOUT, or VARIADIC. + If omitted, the default is IN. + Note that DROP FUNCTION does not actually pay + any attention to OUT arguments, since only the input + arguments are needed to determine the function's identity. + So it is sufficient to list the IN, INOUT, + and VARIADIC arguments. +

argname

The name of an argument. + Note that DROP FUNCTION does not actually pay + any attention to argument names, since only the argument data + types are needed to determine the function's identity. +

argtype

The data type(s) of the function's arguments (optionally + schema-qualified), if any. +

CASCADE

Automatically drop objects that depend on the function (such as + operators or triggers). +

RESTRICT

Refuse to drop the function if any objects depend on it. This + is the default. +

Examples

This command removes the square root function: + +

DROP FUNCTION sqrt(integer);

Compatibility

A DROP FUNCTION statement is defined in the SQL + standard, but it is not compatible with this command. +


PrevHomeNext
DROP FOREIGN TABLEUpDROP GROUP
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-dropgroup.html b/doc/src/sgml/html/sql-dropgroup.html new file mode 100644 index 000000000..4caf4cafd --- /dev/null +++ b/doc/src/sgml/html/sql-dropgroup.html @@ -0,0 +1,226 @@ + +DROP GROUP

DROP GROUP

Name

DROP GROUP -- remove a database role

Synopsis

DROP GROUP [ IF EXISTS ] name [, ...]

Description

DROP GROUP is now an alias for + DROP ROLE. +

Compatibility

There is no DROP GROUP statement in the SQL standard. +

See Also

DROP ROLE

PrevHomeNext
DROP FUNCTIONUpDROP INDEX
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-dropindex.html b/doc/src/sgml/html/sql-dropindex.html new file mode 100644 index 000000000..41c866d6a --- /dev/null +++ b/doc/src/sgml/html/sql-dropindex.html @@ -0,0 +1,347 @@ + +DROP INDEX

DROP INDEX

Name

DROP INDEX -- remove an index

Synopsis

DROP INDEX [ CONCURRENTLY ] [ IF EXISTS ] name [, ...] [ CASCADE | RESTRICT ]

Description

DROP INDEX drops an existing index from the database + system. To execute this command you must be the owner of + the index. +

Parameters

CONCURRENTLY

Drop the index without locking out concurrent selects, inserts, updates, + and deletes on the index's table. A normal DROP INDEX + acquires exclusive lock on the table, blocking other accesses until the + index drop can be completed. With this option, the command instead + waits until conflicting transactions have completed. +

There are several caveats to be aware of when using this option. + Only one index name can be specified, and the CASCADE option + is not supported. (Thus, an index that supports a UNIQUE or + PRIMARY KEY constraint cannot be dropped this way.) + Also, regular DROP INDEX commands can be + performed within a transaction block, but + DROP INDEX CONCURRENTLY cannot. +

IF EXISTS

Do not throw an error if the index does not exist. A notice is issued + in this case. +

name

The name (optionally schema-qualified) of an index to remove. +

CASCADE

Automatically drop objects that depend on the index. +

RESTRICT

Refuse to drop the index if any objects depend on it. This is + the default. +

Examples

This command will remove the index title_idx: + +

DROP INDEX title_idx;

Compatibility

DROP INDEX is a + PostgreSQL language extension. There + are no provisions for indexes in the SQL standard. +

See Also

CREATE INDEX

PrevHomeNext
DROP GROUPUpDROP LANGUAGE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-droplanguage.html b/doc/src/sgml/html/sql-droplanguage.html new file mode 100644 index 000000000..b1a419e4f --- /dev/null +++ b/doc/src/sgml/html/sql-droplanguage.html @@ -0,0 +1,343 @@ + +DROP LANGUAGE

DROP LANGUAGE

Name

DROP LANGUAGE -- remove a procedural language

Synopsis

DROP [ PROCEDURAL ] LANGUAGE [ IF EXISTS ] name [ CASCADE | RESTRICT ]

Description

DROP LANGUAGE removes the definition of a + previously registered procedural language. You must be a superuser + or the owner of the language to use DROP LANGUAGE. +

Note: As of PostgreSQL 9.1, most procedural + languages have been made into "extensions", and should + therefore be removed with DROP EXTENSION + not DROP LANGUAGE. +

Parameters

IF EXISTS

Do not throw an error if the language does not exist. A notice is issued + in this case. +

name

The name of an existing procedural language. For backward + compatibility, the name can be enclosed by single quotes. +

CASCADE

Automatically drop objects that depend on the language (such as + functions in the language). +

RESTRICT

Refuse to drop the language if any objects depend on it. This + is the default. +

Examples

This command removes the procedural language + plsample: + +

DROP LANGUAGE plsample;

Compatibility

There is no DROP LANGUAGE statement in the SQL + standard. +


PrevHomeNext
DROP INDEXUpDROP OPERATOR
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-dropopclass.html b/doc/src/sgml/html/sql-dropopclass.html new file mode 100644 index 000000000..42b789ad2 --- /dev/null +++ b/doc/src/sgml/html/sql-dropopclass.html @@ -0,0 +1,373 @@ + +DROP OPERATOR CLASS

DROP OPERATOR CLASS

Name

DROP OPERATOR CLASS -- remove an operator class

Synopsis

DROP OPERATOR CLASS [ IF EXISTS ] name USING index_method [ CASCADE | RESTRICT ]

Description

DROP OPERATOR CLASS drops an existing operator class. + To execute this command you must be the owner of the operator class. +

DROP OPERATOR CLASS does not drop any of the operators + or functions referenced by the class. If there are any indexes depending + on the operator class, you will need to specify + CASCADE for the drop to complete. +

Parameters

IF EXISTS

Do not throw an error if the operator class does not exist. A notice is issued + in this case. +

name

The name (optionally schema-qualified) of an existing operator class. +

index_method

The name of the index access method the operator class is for. +

CASCADE

Automatically drop objects that depend on the operator class. +

RESTRICT

Refuse to drop the operator class if any objects depend on it. + This is the default. +

Notes

DROP OPERATOR CLASS will not drop the operator family + containing the class, even if there is nothing else left in the + family (in particular, in the case where the family was implicitly + created by CREATE OPERATOR CLASS). An empty operator + family is harmless, but for the sake of tidiness you might wish to + remove the family with DROP OPERATOR FAMILY; or perhaps + better, use DROP OPERATOR FAMILY in the first place. +

Examples

Remove the B-tree operator class widget_ops: + +

DROP OPERATOR CLASS widget_ops USING btree;

+ + This command will not succeed if there are any existing indexes + that use the operator class. Add CASCADE to drop + such indexes along with the operator class. +

Compatibility

There is no DROP OPERATOR CLASS statement in the + SQL standard. +


PrevHomeNext
DROP OPERATORUpDROP OPERATOR FAMILY
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-dropoperator.html b/doc/src/sgml/html/sql-dropoperator.html new file mode 100644 index 000000000..0d2143d2c --- /dev/null +++ b/doc/src/sgml/html/sql-dropoperator.html @@ -0,0 +1,376 @@ + +DROP OPERATOR

DROP OPERATOR

Name

DROP OPERATOR -- remove an operator

Synopsis

DROP OPERATOR [ IF EXISTS ] name ( { left_type | NONE } , { right_type | NONE } ) [ CASCADE | RESTRICT ]

Description

DROP OPERATOR drops an existing operator from + the database system. To execute this command you must be the owner + of the operator. +

Parameters

IF EXISTS

Do not throw an error if the operator does not exist. A notice is issued + in this case. +

name

The name (optionally schema-qualified) of an existing operator. +

left_type

The data type of the operator's left operand; write + NONE if the operator has no left operand. +

right_type

The data type of the operator's right operand; write + NONE if the operator has no right operand. +

CASCADE

Automatically drop objects that depend on the operator. +

RESTRICT

Refuse to drop the operator if any objects depend on it. This + is the default. +

Examples

Remove the power operator a^b for type integer: +

DROP OPERATOR ^ (integer, integer);

+

Remove the left unary bitwise complement operator + ~b for type bit: +

DROP OPERATOR ~ (none, bit);

+

Remove the right unary factorial operator x! + for type bigint: +

DROP OPERATOR ! (bigint, none);

Compatibility

There is no DROP OPERATOR statement in the SQL standard. +


PrevHomeNext
DROP LANGUAGEUpDROP OPERATOR CLASS
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-dropopfamily.html b/doc/src/sgml/html/sql-dropopfamily.html new file mode 100644 index 000000000..c3de6eba5 --- /dev/null +++ b/doc/src/sgml/html/sql-dropopfamily.html @@ -0,0 +1,351 @@ + +DROP OPERATOR FAMILY

DROP OPERATOR FAMILY

Name

DROP OPERATOR FAMILY -- remove an operator family

Synopsis

DROP OPERATOR FAMILY [ IF EXISTS ] name USING index_method [ CASCADE | RESTRICT ]

Description

DROP OPERATOR FAMILY drops an existing operator family. + To execute this command you must be the owner of the operator family. +

DROP OPERATOR FAMILY includes dropping any operator + classes contained in the family, but it does not drop any of the operators + or functions referenced by the family. If there are any indexes depending + on operator classes within the family, you will need to specify + CASCADE for the drop to complete. +

Parameters

IF EXISTS

Do not throw an error if the operator family does not exist. + A notice is issued in this case. +

name

The name (optionally schema-qualified) of an existing operator family. +

index_method

The name of the index access method the operator family is for. +

CASCADE

Automatically drop objects that depend on the operator family. +

RESTRICT

Refuse to drop the operator family if any objects depend on it. + This is the default. +

Examples

Remove the B-tree operator family float_ops: + +

DROP OPERATOR FAMILY float_ops USING btree;

+ + This command will not succeed if there are any existing indexes + that use operator classes within the family. Add CASCADE to + drop such indexes along with the operator family. +

Compatibility

There is no DROP OPERATOR FAMILY statement in the + SQL standard. +


PrevHomeNext
DROP OPERATOR CLASSUpDROP OWNED
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-droprole.html b/doc/src/sgml/html/sql-droprole.html new file mode 100644 index 000000000..568794185 --- /dev/null +++ b/doc/src/sgml/html/sql-droprole.html @@ -0,0 +1,336 @@ + +DROP ROLE

DROP ROLE

Name

DROP ROLE -- remove a database role

Synopsis

DROP ROLE [ IF EXISTS ] name [, ...]

Description

DROP ROLE removes the specified role(s). + To drop a superuser role, you must be a superuser yourself; + to drop non-superuser roles, you must have CREATEROLE + privilege. +

A role cannot be removed if it is still referenced in any database + of the cluster; an error will be raised if so. Before dropping the role, + you must drop all the objects it owns (or reassign their ownership) + and revoke any privileges the role has been granted. The REASSIGN OWNED + and DROP OWNED + commands can be useful for this purpose. +

However, it is not necessary to remove role memberships involving + the role; DROP ROLE automatically revokes any memberships + of the target role in other roles, and of other roles in the target role. + The other roles are not dropped nor otherwise affected. +

Parameters

IF EXISTS

Do not throw an error if the role does not exist. A notice is issued + in this case. +

name

The name of the role to remove. +

Notes

PostgreSQL includes a program dropuser that has the + same functionality as this command (in fact, it calls this command) + but can be run from the command shell. +

Examples

To drop a role: +

DROP ROLE jonathan;

Compatibility

The SQL standard defines DROP ROLE, but it allows + only one role to be dropped at a time, and it specifies different + privilege requirements than PostgreSQL uses. +


PrevHomeNext
DROP OWNEDUpDROP RULE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-droprule.html b/doc/src/sgml/html/sql-droprule.html new file mode 100644 index 000000000..7fb337a06 --- /dev/null +++ b/doc/src/sgml/html/sql-droprule.html @@ -0,0 +1,317 @@ + +DROP RULE

DROP RULE

Name

DROP RULE -- remove a rewrite rule

Synopsis

DROP RULE [ IF EXISTS ] name ON table_name [ CASCADE | RESTRICT ]

Description

DROP RULE drops a rewrite rule. +

Parameters

IF EXISTS

Do not throw an error if the rule does not exist. A notice is issued + in this case. +

name

The name of the rule to drop. +

table_name

The name (optionally schema-qualified) of the table or view that + the rule applies to. +

CASCADE

Automatically drop objects that depend on the rule. +

RESTRICT

Refuse to drop the rule if any objects depend on it. This is + the default. +

Examples

To drop the rewrite rule newrule: + +

DROP RULE newrule ON mytable;

Compatibility

There is no DROP RULE statement in the SQL standard. +

See Also

CREATE RULE

PrevHomeNext
DROP ROLEUpDROP SCHEMA
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-dropschema.html b/doc/src/sgml/html/sql-dropschema.html new file mode 100644 index 000000000..1ee867bf5 --- /dev/null +++ b/doc/src/sgml/html/sql-dropschema.html @@ -0,0 +1,319 @@ + +DROP SCHEMA

DROP SCHEMA

Name

DROP SCHEMA -- remove a schema

Synopsis

DROP SCHEMA [ IF EXISTS ] name [, ...] [ CASCADE | RESTRICT ]

Description

DROP SCHEMA removes schemas from the database. +

A schema can only be dropped by its owner or a superuser. Note that + the owner can drop the schema (and thereby all contained objects) + even if he does not own some of the objects within the schema. +

Parameters

IF EXISTS

Do not throw an error if the schema does not exist. A notice is issued + in this case. +

name

The name of a schema. +

CASCADE

Automatically drop objects (tables, functions, etc.) that are + contained in the schema. +

RESTRICT

Refuse to drop the schema if it contains any objects. This is + the default. +

Examples

To remove schema mystuff from the database, + along with everything it contains: + +

DROP SCHEMA mystuff CASCADE;

Compatibility

DROP SCHEMA is fully conforming with the SQL + standard, except that the standard only allows one schema to be + dropped per command, and apart from the + IF EXISTS option, which is a PostgreSQL + extension. +


PrevHomeNext
DROP RULEUpDROP SEQUENCE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-dropsequence.html b/doc/src/sgml/html/sql-dropsequence.html new file mode 100644 index 000000000..266b1af67 --- /dev/null +++ b/doc/src/sgml/html/sql-dropsequence.html @@ -0,0 +1,316 @@ + +DROP SEQUENCE

DROP SEQUENCE

Name

DROP SEQUENCE -- remove a sequence

Synopsis

DROP SEQUENCE [ IF EXISTS ] name [, ...] [ CASCADE | RESTRICT ]

Description

DROP SEQUENCE removes sequence number + generators. A sequence can only be dropped by its owner or a superuser. +

Parameters

IF EXISTS

Do not throw an error if the sequence does not exist. A notice is issued + in this case. +

name

The name (optionally schema-qualified) of a sequence. +

CASCADE

Automatically drop objects that depend on the sequence. +

RESTRICT

Refuse to drop the sequence if any objects depend on it. This + is the default. +

Examples

To remove the sequence serial: + +

DROP SEQUENCE serial;

Compatibility

DROP SEQUENCE conforms to the SQL + standard, except that the standard only allows one + sequence to be dropped per command, and apart from the + IF EXISTS option, which is a PostgreSQL + extension. +


PrevHomeNext
DROP SCHEMAUpDROP SERVER
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-dropserver.html b/doc/src/sgml/html/sql-dropserver.html new file mode 100644 index 000000000..76af0e082 --- /dev/null +++ b/doc/src/sgml/html/sql-dropserver.html @@ -0,0 +1,312 @@ + +DROP SERVER

DROP SERVER

Name

DROP SERVER -- remove a foreign server descriptor

Synopsis

DROP SERVER [ IF EXISTS ] name [ CASCADE | RESTRICT ]

Description

DROP SERVER removes an existing foreign server + descriptor. To execute this command, the current user must be the + owner of the server. +

Parameters

IF EXISTS

Do not throw an error if the server does not exist. A notice is + issued in this case. +

name

The name of an existing server. +

CASCADE

Automatically drop objects that depend on the server (such as + user mappings). +

RESTRICT

Refuse to drop the server if any objects depend on it. This is + the default. +

Examples

Drop a server foo if it exists: +

DROP SERVER IF EXISTS foo;

Compatibility

DROP SERVER conforms to ISO/IEC 9075-9 + (SQL/MED). The IF EXISTS clause is + a PostgreSQL extension. +


PrevHomeNext
DROP SEQUENCEUpDROP TABLE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-droptable.html b/doc/src/sgml/html/sql-droptable.html new file mode 100644 index 000000000..3dd95f182 --- /dev/null +++ b/doc/src/sgml/html/sql-droptable.html @@ -0,0 +1,341 @@ + +DROP TABLE

DROP TABLE

Name

DROP TABLE -- remove a table

Synopsis

DROP TABLE [ IF EXISTS ] name [, ...] [ CASCADE | RESTRICT ]

Description

DROP TABLE removes tables from the database. + Only the table owner, the schema owner, and superuser can drop a + table. To empty a table of rows + without destroying the table, use DELETE + or TRUNCATE. +

DROP TABLE always removes any indexes, rules, + triggers, and constraints that exist for the target table. + However, to drop a table that is referenced by a view or a foreign-key + constraint of another table, CASCADE must be + specified. (CASCADE will remove a dependent view entirely, + but in the foreign-key case it will only remove the foreign-key + constraint, not the other table entirely.) +

Parameters

IF EXISTS

Do not throw an error if the table does not exist. A notice is issued + in this case. +

name

The name (optionally schema-qualified) of the table to drop. +

CASCADE

Automatically drop objects that depend on the table (such as + views). +

RESTRICT

Refuse to drop the table if any objects depend on it. This is + the default. +

Examples

To destroy two tables, films and + distributors: + +

DROP TABLE films, distributors;

Compatibility

This command conforms to the SQL standard, except that the standard only + allows one table to be dropped per command, and apart from the + IF EXISTS option, which is a PostgreSQL + extension. +


PrevHomeNext
DROP SERVERUpDROP TABLESPACE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-droptablespace.html b/doc/src/sgml/html/sql-droptablespace.html new file mode 100644 index 000000000..ba3dc665e --- /dev/null +++ b/doc/src/sgml/html/sql-droptablespace.html @@ -0,0 +1,313 @@ + +DROP TABLESPACE

DROP TABLESPACE

Name

DROP TABLESPACE -- remove a tablespace

Synopsis

DROP TABLESPACE [ IF EXISTS ] name

Description

DROP TABLESPACE removes a tablespace from the system. +

A tablespace can only be dropped by its owner or a superuser. + The tablespace must be empty of all database objects before it can be + dropped. It is possible that objects in other databases might still reside + in the tablespace even if no objects in the current database are using + the tablespace. Also, if the tablespace is listed in the temp_tablespaces setting of any active session, the + DROP might fail due to temporary files residing in the + tablespace. +

Parameters

IF EXISTS

Do not throw an error if the tablespace does not exist. A notice is issued + in this case. +

name

The name of a tablespace. +

Notes

DROP TABLESPACE cannot be executed inside a transaction block. +

Examples

To remove tablespace mystuff from the system: +

DROP TABLESPACE mystuff;

Compatibility

DROP TABLESPACE is a PostgreSQL + extension. +


PrevHomeNext
DROP TABLEUpDROP TEXT SEARCH CONFIGURATION
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-droptrigger.html b/doc/src/sgml/html/sql-droptrigger.html new file mode 100644 index 000000000..ed1825663 --- /dev/null +++ b/doc/src/sgml/html/sql-droptrigger.html @@ -0,0 +1,338 @@ + +DROP TRIGGER

DROP TRIGGER

Name

DROP TRIGGER -- remove a trigger

Synopsis

DROP TRIGGER [ IF EXISTS ] name ON table_name [ CASCADE | RESTRICT ]

Description

DROP TRIGGER removes an existing + trigger definition. To execute this command, the current + user must be the owner of the table for which the trigger is defined. +

Parameters

IF EXISTS

Do not throw an error if the trigger does not exist. A notice is issued + in this case. +

name

The name of the trigger to remove. +

table_name

The name (optionally schema-qualified) of the table for which + the trigger is defined. +

CASCADE

Automatically drop objects that depend on the trigger. +

RESTRICT

Refuse to drop the trigger if any objects depend on it. This is + the default. +

Examples

Destroy the trigger if_dist_exists on the table + films: + +

DROP TRIGGER if_dist_exists ON films;

Compatibility

The DROP TRIGGER statement in + PostgreSQL is incompatible with the SQL + standard. In the SQL standard, trigger names are not local to + tables, so the command is simply DROP TRIGGER + name. +


PrevHomeNext
DROP TEXT SEARCH TEMPLATEUpDROP TYPE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-droptsconfig.html b/doc/src/sgml/html/sql-droptsconfig.html new file mode 100644 index 000000000..3c79f555b --- /dev/null +++ b/doc/src/sgml/html/sql-droptsconfig.html @@ -0,0 +1,318 @@ + +DROP TEXT SEARCH CONFIGURATION

DROP TEXT SEARCH CONFIGURATION

Name

DROP TEXT SEARCH CONFIGURATION -- remove a text search configuration

Synopsis

DROP TEXT SEARCH CONFIGURATION [ IF EXISTS ] name [ CASCADE | RESTRICT ]

Description

DROP TEXT SEARCH CONFIGURATION drops an existing text + search configuration. To execute this command you must be the owner of the + configuration. +

Parameters

IF EXISTS

Do not throw an error if the text search configuration does not exist. + A notice is issued in this case. +

name

The name (optionally schema-qualified) of an existing text search + configuration. +

CASCADE

Automatically drop objects that depend on the text search configuration. +

RESTRICT

Refuse to drop the text search configuration if any objects depend on it. + This is the default. +

Examples

Remove the text search configuration my_english: + +

DROP TEXT SEARCH CONFIGURATION my_english;

+ + This command will not succeed if there are any existing indexes + that reference the configuration in to_tsvector calls. + Add CASCADE to + drop such indexes along with the text search configuration. +

Compatibility

There is no DROP TEXT SEARCH CONFIGURATION statement in + the SQL standard. +


PrevHomeNext
DROP TABLESPACEUpDROP TEXT SEARCH DICTIONARY
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-droptsdictionary.html b/doc/src/sgml/html/sql-droptsdictionary.html new file mode 100644 index 000000000..09e4bfc08 --- /dev/null +++ b/doc/src/sgml/html/sql-droptsdictionary.html @@ -0,0 +1,314 @@ + +DROP TEXT SEARCH DICTIONARY

DROP TEXT SEARCH DICTIONARY

Name

DROP TEXT SEARCH DICTIONARY -- remove a text search dictionary

Synopsis

DROP TEXT SEARCH DICTIONARY [ IF EXISTS ] name [ CASCADE | RESTRICT ]

Description

DROP TEXT SEARCH DICTIONARY drops an existing text + search dictionary. To execute this command you must be the owner of the + dictionary. +

Parameters

IF EXISTS

Do not throw an error if the text search dictionary does not exist. + A notice is issued in this case. +

name

The name (optionally schema-qualified) of an existing text search + dictionary. +

CASCADE

Automatically drop objects that depend on the text search dictionary. +

RESTRICT

Refuse to drop the text search dictionary if any objects depend on it. + This is the default. +

Examples

Remove the text search dictionary english: + +

DROP TEXT SEARCH DICTIONARY english;

+ + This command will not succeed if there are any existing text search + configurations that use the dictionary. Add CASCADE to + drop such configurations along with the dictionary. +

Compatibility

There is no DROP TEXT SEARCH DICTIONARY statement in the + SQL standard. +


PrevHomeNext
DROP TEXT SEARCH CONFIGURATIONUpDROP TEXT SEARCH PARSER
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-droptsparser.html b/doc/src/sgml/html/sql-droptsparser.html new file mode 100644 index 000000000..d5905360e --- /dev/null +++ b/doc/src/sgml/html/sql-droptsparser.html @@ -0,0 +1,312 @@ + +DROP TEXT SEARCH PARSER

DROP TEXT SEARCH PARSER

Name

DROP TEXT SEARCH PARSER -- remove a text search parser

Synopsis

DROP TEXT SEARCH PARSER [ IF EXISTS ] name [ CASCADE | RESTRICT ]

Description

DROP TEXT SEARCH PARSER drops an existing text search + parser. You must be a superuser to use this command. +

Parameters

IF EXISTS

Do not throw an error if the text search parser does not exist. + A notice is issued in this case. +

name

The name (optionally schema-qualified) of an existing text search parser. +

CASCADE

Automatically drop objects that depend on the text search parser. +

RESTRICT

Refuse to drop the text search parser if any objects depend on it. + This is the default. +

Examples

Remove the text search parser my_parser: + +

DROP TEXT SEARCH PARSER my_parser;

+ + This command will not succeed if there are any existing text search + configurations that use the parser. Add CASCADE to + drop such configurations along with the parser. +

Compatibility

There is no DROP TEXT SEARCH PARSER statement in the + SQL standard. +


PrevHomeNext
DROP TEXT SEARCH DICTIONARYUpDROP TEXT SEARCH TEMPLATE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-droptstemplate.html b/doc/src/sgml/html/sql-droptstemplate.html new file mode 100644 index 000000000..38711b718 --- /dev/null +++ b/doc/src/sgml/html/sql-droptstemplate.html @@ -0,0 +1,313 @@ + +DROP TEXT SEARCH TEMPLATE

DROP TEXT SEARCH TEMPLATE

Name

DROP TEXT SEARCH TEMPLATE -- remove a text search template

Synopsis

DROP TEXT SEARCH TEMPLATE [ IF EXISTS ] name [ CASCADE | RESTRICT ]

Description

DROP TEXT SEARCH TEMPLATE drops an existing text search + template. You must be a superuser to use this command. +

Parameters

IF EXISTS

Do not throw an error if the text search template does not exist. + A notice is issued in this case. +

name

The name (optionally schema-qualified) of an existing text search + template. +

CASCADE

Automatically drop objects that depend on the text search template. +

RESTRICT

Refuse to drop the text search template if any objects depend on it. + This is the default. +

Examples

Remove the text search template thesaurus: + +

DROP TEXT SEARCH TEMPLATE thesaurus;

+ + This command will not succeed if there are any existing text search + dictionaries that use the template. Add CASCADE to + drop such dictionaries along with the template. +

Compatibility

There is no DROP TEXT SEARCH TEMPLATE statement in the + SQL standard. +


PrevHomeNext
DROP TEXT SEARCH PARSERUpDROP TRIGGER
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-droptype.html b/doc/src/sgml/html/sql-droptype.html new file mode 100644 index 000000000..3f577bd9a --- /dev/null +++ b/doc/src/sgml/html/sql-droptype.html @@ -0,0 +1,317 @@ + +DROP TYPE

DROP TYPE

Name

DROP TYPE -- remove a data type

Synopsis

DROP TYPE [ IF EXISTS ] name [, ...] [ CASCADE | RESTRICT ]

Description

DROP TYPE removes a user-defined data type. + Only the owner of a type can remove it. +

Parameters

IF EXISTS

Do not throw an error if the type does not exist. A notice is issued + in this case. +

name

The name (optionally schema-qualified) of the data type to remove. +

CASCADE

Automatically drop objects that depend on the type (such as + table columns, functions, operators). +

RESTRICT

Refuse to drop the type if any objects depend on it. This is + the default. +

Examples

To remove the data type box: +

DROP TYPE box;

Compatibility

This command is similar to the corresponding command in the SQL + standard, apart from the IF EXISTS + option, which is a PostgreSQL extension. + But note that much of the CREATE TYPE command + and the data type extension mechanisms in + PostgreSQL differ from the SQL standard. +


PrevHomeNext
DROP TRIGGERUpDROP USER
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-dropuser.html b/doc/src/sgml/html/sql-dropuser.html new file mode 100644 index 000000000..5dffb3827 --- /dev/null +++ b/doc/src/sgml/html/sql-dropuser.html @@ -0,0 +1,231 @@ + +DROP USER

DROP USER

Name

DROP USER -- remove a database role

Synopsis

DROP USER [ IF EXISTS ] name [, ...]

Description

DROP USER is now an alias for + DROP ROLE. +

Compatibility

The DROP USER statement is a + PostgreSQL extension. The SQL standard + leaves the definition of users to the implementation. +

See Also

DROP ROLE

PrevHomeNext
DROP TYPEUpDROP USER MAPPING
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-dropusermapping.html b/doc/src/sgml/html/sql-dropusermapping.html new file mode 100644 index 000000000..70cd9c993 --- /dev/null +++ b/doc/src/sgml/html/sql-dropusermapping.html @@ -0,0 +1,330 @@ + +DROP USER MAPPING

DROP USER MAPPING

Name

DROP USER MAPPING -- remove a user mapping for a foreign server

Synopsis

DROP USER MAPPING [ IF EXISTS ] FOR { user_name | USER | CURRENT_USER | PUBLIC } SERVER server_name

Description

DROP USER MAPPING removes an existing user + mapping from foreign server. +

The owner of a foreign server can drop user mappings for that server + for any user. Also, a user can drop a user mapping for his own + user name if USAGE privilege on the server has been + granted to the user. +

Parameters

IF EXISTS

Do not throw an error if the user mapping does not exist. A + notice is issued in this case. +

user_name

User name of the mapping. CURRENT_USER + and USER match the name of the current + user. PUBLIC is used to match all present and + future user names in the system. +

server_name

Server name of the user mapping. +

Examples

Drop a user mapping bob, server foo if it exists: +

DROP USER MAPPING IF EXISTS FOR bob SERVER foo;

Compatibility

DROP USER MAPPING conforms to ISO/IEC 9075-9 + (SQL/MED). The IF EXISTS clause is + a PostgreSQL extension. +


PrevHomeNext
DROP USERUpDROP VIEW
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-dropview.html b/doc/src/sgml/html/sql-dropview.html new file mode 100644 index 000000000..dd188e70e --- /dev/null +++ b/doc/src/sgml/html/sql-dropview.html @@ -0,0 +1,309 @@ + +DROP VIEW

DROP VIEW

Name

DROP VIEW -- remove a view

Synopsis

DROP VIEW [ IF EXISTS ] name [, ...] [ CASCADE | RESTRICT ]

Description

DROP VIEW drops an existing view. To execute + this command you must be the owner of the view. +

Parameters

IF EXISTS

Do not throw an error if the view does not exist. A notice is issued + in this case. +

name

The name (optionally schema-qualified) of the view to remove. +

CASCADE

Automatically drop objects that depend on the view (such as + other views). +

RESTRICT

Refuse to drop the view if any objects depend on it. This is + the default. +

Examples

This command will remove the view called kinds: +

DROP VIEW kinds;

Compatibility

This command conforms to the SQL standard, except that the standard only + allows one view to be dropped per command, and apart from the + IF EXISTS option, which is a PostgreSQL + extension. +


PrevHomeNext
DROP USER MAPPINGUpEND
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-end.html b/doc/src/sgml/html/sql-end.html new file mode 100644 index 000000000..6331188d2 --- /dev/null +++ b/doc/src/sgml/html/sql-end.html @@ -0,0 +1,305 @@ + +END

END

Name

END -- commit the current transaction

Synopsis

END [ WORK | TRANSACTION ]

Description

END commits the current transaction. All changes + made by the transaction become visible to others and are guaranteed + to be durable if a crash occurs. This command is a + PostgreSQL extension + that is equivalent to COMMIT. +

Parameters

WORK
TRANSACTION

Optional key words. They have no effect. +

Notes

Use ROLLBACK to + abort a transaction. +

Issuing END when not inside a transaction does + no harm, but it will provoke a warning message. +

Examples

To commit the current transaction and make all changes permanent: +

END;

Compatibility

END is a PostgreSQL + extension that provides functionality equivalent to COMMIT, which is + specified in the SQL standard. +


PrevHomeNext
DROP VIEWUpEXECUTE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-execute.html b/doc/src/sgml/html/sql-execute.html new file mode 100644 index 000000000..77b62346b --- /dev/null +++ b/doc/src/sgml/html/sql-execute.html @@ -0,0 +1,343 @@ + +EXECUTE

EXECUTE

Name

EXECUTE -- execute a prepared statement

Synopsis

EXECUTE name [ ( parameter [, ...] ) ]

Description

EXECUTE is used to execute a previously prepared + statement. Since prepared statements only exist for the duration of a + session, the prepared statement must have been created by a + PREPARE statement executed earlier in the + current session. +

If the PREPARE statement that created the statement + specified some parameters, a compatible set of parameters must be + passed to the EXECUTE statement, or else an + error is raised. Note that (unlike functions) prepared statements are + not overloaded based on the type or number of their parameters; the + name of a prepared statement must be unique within a database session. +

For more information on the creation and usage of prepared statements, + see PREPARE. +

Parameters

name

The name of the prepared statement to execute. +

parameter

The actual value of a parameter to the prepared statement. This + must be an expression yielding a value that is compatible with + the data type of this parameter, as was determined when the + prepared statement was created. +

Outputs

The command tag returned by EXECUTE + is that of the prepared statement, and not EXECUTE. +

Examples

Examples are given in the Examples section of the PREPARE documentation. +

Compatibility

The SQL standard includes an EXECUTE statement, + but it is only for use in embedded SQL. This version of the + EXECUTE statement also uses a somewhat different + syntax. +


PrevHomeNext
ENDUpEXPLAIN
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-explain.html b/doc/src/sgml/html/sql-explain.html new file mode 100644 index 000000000..158f88229 --- /dev/null +++ b/doc/src/sgml/html/sql-explain.html @@ -0,0 +1,863 @@ + +EXPLAIN

EXPLAIN

Name

EXPLAIN -- show the execution plan of a statement

Synopsis

EXPLAIN [ ( option [, ...] ) ] statement
+EXPLAIN [ ANALYZE ] [ VERBOSE ] statement
+
+where option can be one of:
+
+    ANALYZE [ boolean ]
+    VERBOSE [ boolean ]
+    COSTS [ boolean ]
+    BUFFERS [ boolean ]
+    TIMING [ boolean ]
+    FORMAT { TEXT | XML | JSON | YAML }

Description

This command displays the execution plan that the + PostgreSQL planner generates for the + supplied statement. The execution plan shows how the table(s) + referenced by the statement will be scanned — by plain sequential scan, + index scan, etc. — and if multiple tables are referenced, what join + algorithms will be used to bring together the required rows from + each input table. +

The most critical part of the display is the estimated statement execution + cost, which is the planner's guess at how long it will take to run the + statement (measured in cost units that are arbitrary, but conventionally + mean disk page fetches). Actually two numbers + are shown: the start-up cost before the first row can be returned, and + the total cost to return all the rows. For most queries the total cost + is what matters, but in contexts such as a subquery in EXISTS, the planner + will choose the smallest start-up cost instead of the smallest total cost + (since the executor will stop after getting one row, anyway). + Also, if you limit the number of rows to return with a LIMIT clause, + the planner makes an appropriate interpolation between the endpoint + costs to estimate which plan is really the cheapest. +

The ANALYZE option causes the statement to be actually + executed, not only planned. Then actual runtime statistics are added to + the display, including the total elapsed time expended within each plan + node (in milliseconds) and the total number of rows it actually returned. + This is useful for seeing whether the planner's estimates + are close to reality. +

Important: Keep in mind that the statement is actually executed when + the ANALYZE option is used. Although + EXPLAIN will discard any output that a + SELECT would return, other side effects of the + statement will happen as usual. If you wish to use + EXPLAIN ANALYZE on an + INSERT, UPDATE, + DELETE, CREATE TABLE AS, + or EXECUTE statement + without letting the command affect your data, use this approach: +

BEGIN;
+EXPLAIN ANALYZE ...;
+ROLLBACK;

+

Only the ANALYZE and VERBOSE options + can be specified, and only in that order, without surrounding the option + list in parentheses. Prior to PostgreSQL 9.0, + the unparenthesized syntax was the only one supported. It is expected that + all new options will be supported only in the parenthesized syntax. +

Parameters

ANALYZE

Carry out the command and show actual run times and other statistics. + This parameter defaults to FALSE. +

VERBOSE

Display additional information regarding the plan. Specifically, include + the output column list for each node in the plan tree, schema-qualify + table and function names, always label variables in expressions with + their range table alias, and always print the name of each trigger for + which statistics are displayed. This parameter defaults to + FALSE. +

COSTS

Include information on the estimated startup and total cost of each + plan node, as well as the estimated number of rows and the estimated + width of each row. This parameter defaults to TRUE. +

BUFFERS

Include information on buffer usage. Specifically, include the number of + shared blocks hit, read, dirtied, and written, the number of local blocks + hit, read, dirtied, and written, and the number of temp blocks read and + written. + A hit means that a read was avoided because the block was + found already in cache when needed. + Shared blocks contain data from regular tables and indexes; + local blocks contain data from temporary tables and indexes; + while temp blocks contain short-term working data used in sorts, hashes, + Materialize plan nodes, and similar cases. + The number of blocks dirtied indicates the number of + previously unmodified blocks that were changed by this query; while the + number of blocks written indicates the number of + previously-dirtied blocks evicted from cache by this backend during + query processing. + The number of blocks shown for an + upper-level node includes those used by all its child nodes. In text + format, only non-zero values are printed. This parameter may only be + used when ANALYZE is also enabled. It defaults to + FALSE. +

TIMING

Include the actual startup time and time spent in the node in the output. + The overhead of repeatedly reading the system clock can slow down the + query significantly on some systems, so it may be useful to set this + parameter to FALSE when only actual row counts, and not + exact times, are needed. + This parameter may only be used when ANALYZE is also + enabled. It defaults to TRUE. +

FORMAT

Specify the output format, which can be TEXT, XML, JSON, or YAML. + Non-text output contains the same information as the text output + format, but is easier for programs to parse. This parameter defaults to + TEXT. +

boolean

Specifies whether the selected option should be turned on or off. + You can write TRUE, ON, or + 1 to enable the option, and FALSE, + OFF, or 0 to disable it. The + boolean value can also + be omitted, in which case TRUE is assumed. +

statement

Any SELECT, INSERT, UPDATE, + DELETE, VALUES, EXECUTE, + DECLARE, or CREATE TABLE AS + statement, whose execution plan you wish to see. +

Outputs

The command's result is a textual description of the plan selected + for the statement, + optionally annotated with execution statistics. + Section 14.1 describes the information provided. +

Notes

In order to allow the PostgreSQL query + planner to make reasonably informed decisions when optimizing + queries, the pg_statistic + data should be up-to-date for all tables used in the query. Normally + the autovacuum daemon will take care + of that automatically. But if a table has recently had substantial + changes in its contents, you might need to do a manual + ANALYZE rather than wait for autovacuum to catch up + with the changes. +

In order to measure the run-time cost of each node in the execution + plan, the current implementation of EXPLAIN + ANALYZE adds profiling overhead to query execution. + As a result, running EXPLAIN ANALYZE + on a query can sometimes take significantly longer than executing + the query normally. The amount of overhead depends on the nature of + the query, as well as the platform being used. The worst case occurs + for plan nodes that in themselves require very little time per + execution, and on machines that have relatively slow operating + system calls for obtaining the time of day. +

Examples

To show the plan for a simple query on a table with a single + integer column and 10000 rows: + +

EXPLAIN SELECT * FROM foo;
+
+                       QUERY PLAN
+---------------------------------------------------------
+ Seq Scan on foo  (cost=0.00..155.00 rows=10000 width=4)
+(1 row)

+

Here is the same query, with JSON output formatting: +

EXPLAIN (FORMAT JSON) SELECT * FROM foo;
+           QUERY PLAN
+--------------------------------
+ [                             +
+   {                           +
+     "Plan": {                 +
+       "Node Type": "Seq Scan",+
+       "Relation Name": "foo", +
+       "Alias": "foo",         +
+       "Startup Cost": 0.00,   +
+       "Total Cost": 155.00,   +
+       "Plan Rows": 10000,     +
+       "Plan Width": 4         +
+     }                         +
+   }                           +
+ ]
+(1 row)

+

If there is an index and we use a query with an indexable + WHERE condition, EXPLAIN + might show a different plan: + +

EXPLAIN SELECT * FROM foo WHERE i = 4;
+
+                         QUERY PLAN
+--------------------------------------------------------------
+ Index Scan using fi on foo  (cost=0.00..5.98 rows=1 width=4)
+   Index Cond: (i = 4)
+(2 rows)

+

Here is the same query, but in YAML format: +

EXPLAIN (FORMAT YAML) SELECT * FROM foo WHERE i='4';
+          QUERY PLAN
+-------------------------------
+ - Plan:                      +
+     Node Type: "Index Scan"  +
+     Scan Direction: "Forward"+
+     Index Name: "fi"         +
+     Relation Name: "foo"     +
+     Alias: "foo"             +
+     Startup Cost: 0.00       +
+     Total Cost: 5.98         +
+     Plan Rows: 1             +
+     Plan Width: 4            +
+     Index Cond: "(i = 4)"
+(1 row)

+ + XML format is left as an exercise for the reader. +

Here is the same plan with cost estimates suppressed: + +

EXPLAIN (COSTS FALSE) SELECT * FROM foo WHERE i = 4;
+
+        QUERY PLAN
+----------------------------
+ Index Scan using fi on foo
+   Index Cond: (i = 4)
+(2 rows)

+

Here is an example of a query plan for a query using an aggregate + function: + +

EXPLAIN SELECT sum(i) FROM foo WHERE i < 10;
+
+                             QUERY PLAN
+---------------------------------------------------------------------
+ Aggregate  (cost=23.93..23.93 rows=1 width=4)
+   ->  Index Scan using fi on foo  (cost=0.00..23.92 rows=6 width=4)
+         Index Cond: (i < 10)
+(3 rows)

+

Here is an example of using EXPLAIN EXECUTE to + display the execution plan for a prepared query: + +

PREPARE query(int, int) AS SELECT sum(bar) FROM test
+    WHERE id > $1 AND id < $2
+    GROUP BY foo;
+
+EXPLAIN ANALYZE EXECUTE query(100, 200);
+
+                                                       QUERY PLAN
+-------------------------------------------------------------------------------------------------------------------------
+ HashAggregate  (cost=39.53..39.53 rows=1 width=8) (actual time=0.661..0.672 rows=7 loops=1)
+   ->  Index Scan using test_pkey on test  (cost=0.00..32.97 rows=1311 width=8) (actual time=0.050..0.395 rows=99 loops=1)
+         Index Cond: ((id > $1) AND (id < $2))
+ Total runtime: 0.851 ms
+(4 rows)

+

Of course, the specific numbers shown here depend on the actual + contents of the tables involved. Also note that the numbers, and + even the selected query strategy, might vary between + PostgreSQL releases due to planner + improvements. In addition, the ANALYZE command + uses random sampling to estimate data statistics; therefore, it is + possible for cost estimates to change after a fresh run of + ANALYZE, even if the actual distribution of data + in the table has not changed. +

Compatibility

There is no EXPLAIN statement defined in the SQL standard. +

See Also

ANALYZE

PrevHomeNext
EXECUTEUpFETCH
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-expressions.html b/doc/src/sgml/html/sql-expressions.html new file mode 100644 index 000000000..0b19ff8e5 --- /dev/null +++ b/doc/src/sgml/html/sql-expressions.html @@ -0,0 +1,2276 @@ + +Value Expressions

4.2. Value Expressions

Value expressions are used in a variety of contexts, such + as in the target list of the SELECT command, as + new column values in INSERT or + UPDATE, or in search conditions in a number of + commands. The result of a value expression is sometimes called a + scalar, to distinguish it from the result of + a table expression (which is a table). Value expressions are + therefore also called scalar expressions (or + even simply expressions). The expression + syntax allows the calculation of values from primitive parts using + arithmetic, logical, set, and other operations. +

A value expression is one of the following: + +

  • A constant or literal value +

  • A column reference +

  • A positional parameter reference, in the body of a function definition + or prepared statement +

  • A subscripted expression +

  • A field selection expression +

  • An operator invocation +

  • A function call +

  • An aggregate expression +

  • A window function call +

  • A type cast +

  • A collation expression +

  • A scalar subquery +

  • An array constructor +

  • A row constructor +

  • Another value expression in parentheses (used to group + subexpressions and override + precedence) +

+

In addition to this list, there are a number of constructs that can + be classified as an expression but do not follow any general syntax + rules. These generally have the semantics of a function or + operator and are explained in the appropriate location in Chapter 9. An example is the IS NULL + clause. +

We have already discussed constants in Section 4.1.2. The following sections discuss + the remaining options. +

4.2.1. Column References

A column can be referenced in the form: +

correlation.columnname

+

correlation is the name of a + table (possibly qualified with a schema name), or an alias for a table + defined by means of a FROM clause. + The correlation name and separating dot can be omitted if the column name + is unique across all the tables being used in the current query. (See also Chapter 7.) +

4.2.2. Positional Parameters

A positional parameter reference is used to indicate a value + that is supplied externally to an SQL statement. Parameters are + used in SQL function definitions and in prepared queries. Some + client libraries also support specifying data values separately + from the SQL command string, in which case parameters are used to + refer to the out-of-line data values. + The form of a parameter reference is: +

$number

+

For example, consider the definition of a function, + dept, as: + +

CREATE FUNCTION dept(text) RETURNS dept
+    AS $$ SELECT * FROM dept WHERE name = $1 $$
+    LANGUAGE SQL;

+ + Here the $1 references the value of the first + function argument whenever the function is invoked. +

4.2.3. Subscripts

If an expression yields a value of an array type, then a specific + element of the array value can be extracted by writing +

expression[subscript]

+ or multiple adjacent elements (an "array slice") can be extracted + by writing +

expression[lower_subscript:upper_subscript]

+ (Here, the brackets [ ] are meant to appear literally.) + Each subscript is itself an expression, + which must yield an integer value. +

In general the array expression must be + parenthesized, but the parentheses can be omitted when the expression + to be subscripted is just a column reference or positional parameter. + Also, multiple subscripts can be concatenated when the original array + is multidimensional. + For example: + +

mytable.arraycolumn[4]
+mytable.two_d_column[17][34]
+$1[10:42]
+(arrayfunction(a,b))[42]

+ + The parentheses in the last example are required. + See Section 8.15 for more about arrays. +

4.2.4. Field Selection

If an expression yields a value of a composite type (row type), then a + specific field of the row can be extracted by writing +

expression.fieldname

+

In general the row expression must be + parenthesized, but the parentheses can be omitted when the expression + to be selected from is just a table reference or positional parameter. + For example: + +

mytable.mycolumn
+$1.somecolumn
+(rowfunction(a,b)).col3

+ + (Thus, a qualified column reference is actually just a special case + of the field selection syntax.) An important special case is + extracting a field from a table column that is of a composite type: + +

(compositecol).somefield
+(mytable.compositecol).somefield

+ + The parentheses are required here to show that + compositecol is a column name not a table name, + or that mytable is a table name not a schema name + in the second case. +

In a select list (see Section 7.3), you + can ask for all fields of a composite value by + writing .*: +

(compositecol).*

+

4.2.5. Operator Invocations

There are three possible syntaxes for an operator invocation: +

expression operator expression (binary infix operator)
operator expression (unary prefix operator)
expression operator (unary postfix operator)

+ where the operator token follows the syntax + rules of Section 4.1.3, or is one of the + key words AND, OR, and + NOT, or is a qualified operator name in the form: +

OPERATOR(schema.operatorname)

+ Which particular operators exist and whether + they are unary or binary depends on what operators have been + defined by the system or the user. Chapter 9 + describes the built-in operators. +

4.2.6. Function Calls

The syntax for a function call is the name of a function + (possibly qualified with a schema name), followed by its argument list + enclosed in parentheses: + +

function_name ([expression [, expression ... ]] )

+

For example, the following computes the square root of 2: +

sqrt(2)

+

The list of built-in functions is in Chapter 9. + Other functions can be added by the user. +

The arguments can optionally have names attached. + See Section 4.3 for details. +

Note: A function that takes a single argument of composite type can + optionally be called using field-selection syntax, and conversely + field selection can be written in functional style. That is, the + notations col(table) and table.col are + interchangeable. This behavior is not SQL-standard but is provided + in PostgreSQL because it allows use of functions to + emulate "computed fields". For more information see + Section 35.4.3. +

4.2.7. Aggregate Expressions

An aggregate expression represents the + application of an aggregate function across the rows selected by a + query. An aggregate function reduces multiple inputs to a single + output value, such as the sum or average of the inputs. The + syntax of an aggregate expression is one of the following: + +

aggregate_name (expression [ , ... ] [ order_by_clause ] )
+aggregate_name (ALL expression [ , ... ] [ order_by_clause ] )
+aggregate_name (DISTINCT expression [ , ... ] [ order_by_clause ] )
+aggregate_name ( * )

+ + where aggregate_name is a previously + defined aggregate (possibly qualified with a schema name), + expression is + any value expression that does not itself contain an aggregate + expression or a window function call, and + order_by_clause is a optional + ORDER BY clause as described below. +

The first form of aggregate expression invokes the aggregate + once for each input row. + The second form is the same as the first, since + ALL is the default. + The third form invokes the aggregate once for each distinct value + of the expression (or distinct set of values, for multiple expressions) + found in the input rows. + The last form invokes the aggregate once for each input row; since no + particular input value is specified, it is generally only useful + for the count(*) aggregate function. +

Most aggregate functions ignore null inputs, so that rows in which + one or more of the expression(s) yield null are discarded. This + can be assumed to be true, unless otherwise specified, for all + built-in aggregates. +

For example, count(*) yields the total number + of input rows; count(f1) yields the number of + input rows in which f1 is non-null, since + count ignores nulls; and + count(distinct f1) yields the number of + distinct non-null values of f1. +

Ordinarily, the input rows are fed to the aggregate function in an + unspecified order. In many cases this does not matter; for example, + min produces the same result no matter what order it + receives the inputs in. However, some aggregate functions + (such as array_agg and string_agg) produce + results that depend on the ordering of the input rows. When using + such an aggregate, the optional order_by_clause can be + used to specify the desired ordering. The order_by_clause + has the same syntax as for a query-level ORDER BY clause, as + described in Section 7.5, except that its expressions + are always just expressions and cannot be output-column names or numbers. + For example: +

SELECT array_agg(a ORDER BY b DESC) FROM table;

+

When dealing with multiple-argument aggregate functions, note that the + ORDER BY clause goes after all the aggregate arguments. + For example, write this: +

SELECT string_agg(a, ',' ORDER BY a) FROM table;

+ not this: +

SELECT string_agg(a ORDER BY a, ',') FROM table;  -- incorrect

+ The latter is syntactically valid, but it represents a call of a + single-argument aggregate function with two ORDER BY keys + (the second one being rather useless since it's a constant). +

If DISTINCT is specified in addition to an + order_by_clause, then all the ORDER BY + expressions must match regular arguments of the aggregate; that is, + you cannot sort on an expression that is not included in the + DISTINCT list. +

Note: The ability to specify both DISTINCT and ORDER BY + in an aggregate function is a PostgreSQL extension. +

The predefined aggregate functions are described in Section 9.20. Other aggregate functions can be added + by the user. +

An aggregate expression can only appear in the result list or + HAVING clause of a SELECT command. + It is forbidden in other clauses, such as WHERE, + because those clauses are logically evaluated before the results + of aggregates are formed. +

When an aggregate expression appears in a subquery (see + Section 4.2.11 and + Section 9.22), the aggregate is normally + evaluated over the rows of the subquery. But an exception occurs + if the aggregate's arguments contain only outer-level variables: + the aggregate then belongs to the nearest such outer level, and is + evaluated over the rows of that query. The aggregate expression + as a whole is then an outer reference for the subquery it appears in, + and acts as a constant over any one evaluation of that subquery. + The restriction about + appearing only in the result list or HAVING clause + applies with respect to the query level that the aggregate belongs to. +

4.2.8. Window Function Calls

A window function call represents the application + of an aggregate-like function over some portion of the rows selected + by a query. Unlike regular aggregate function calls, this is not tied + to grouping of the selected rows into a single output row — each + row remains separate in the query output. However the window function + is able to scan all the rows that would be part of the current row's + group according to the grouping specification (PARTITION BY + list) of the window function call. + The syntax of a window function call is one of the following: + +

function_name ([expression [, expression ... ]]) OVER ( window_definition )
+function_name ([expression [, expression ... ]]) OVER window_name
+function_name ( * ) OVER ( window_definition )
+function_name ( * ) OVER window_name

+ where window_definition + has the syntax +

[ existing_window_name ]
+[ PARTITION BY expression [, ...] ]
+[ ORDER BY expression [ ASC | DESC | USING operator ] [ NULLS { FIRST | LAST } ] [, ...] ]
+[ frame_clause ]

+ and the optional frame_clause + can be one of +

[ RANGE | ROWS ] frame_start
+[ RANGE | ROWS ] BETWEEN frame_start AND frame_end

+ where frame_start and frame_end can be + one of +

UNBOUNDED PRECEDING
+value PRECEDING
+CURRENT ROW
+value FOLLOWING
+UNBOUNDED FOLLOWING

+

Here, expression represents any value + expression that does not itself contain window function calls. + The PARTITION BY and ORDER BY lists have + essentially the same syntax and semantics as GROUP BY + and ORDER BY clauses of the whole query, except that their + expressions are always just expressions and cannot be output-column + names or numbers. + window_name is a reference to a named window + specification defined in the query's WINDOW clause. + Named window specifications are usually referenced with just + OVER window_name, but it is + also possible to write a window name inside the parentheses and then + optionally supply an ordering clause and/or frame clause (the referenced + window must lack these clauses, if they are supplied here). + This latter syntax follows the same rules as modifying an existing + window name within the WINDOW clause; see the + SELECT reference + page for details. +

The frame_clause specifies + the set of rows constituting the window frame, for those + window functions that act on the frame instead of the whole partition. + If frame_end is omitted it defaults to CURRENT + ROW. Restrictions are that + frame_start cannot be UNBOUNDED FOLLOWING, + frame_end cannot be UNBOUNDED PRECEDING, + and the frame_end choice cannot appear earlier in the + above list than the frame_start choice — for example + RANGE BETWEEN CURRENT ROW AND value + PRECEDING is not allowed. + The default framing option is RANGE UNBOUNDED PRECEDING, + which is the same as RANGE BETWEEN UNBOUNDED PRECEDING AND + CURRENT ROW; it sets the frame to be all rows from the partition start + up through the current row's last peer in the ORDER BY + ordering (which means all rows if there is no ORDER BY). + In general, UNBOUNDED PRECEDING means that the frame + starts with the first row of the partition, and similarly + UNBOUNDED FOLLOWING means that the frame ends with the last + row of the partition (regardless of RANGE or ROWS + mode). In ROWS mode, CURRENT ROW + means that the frame starts or ends with the current row; but in + RANGE mode it means that the frame starts or ends with + the current row's first or last peer in the ORDER BY ordering. + The value PRECEDING and + value FOLLOWING cases are currently only + allowed in ROWS mode. They indicate that the frame starts + or ends with the row that many rows before or after the current row. + value must be an integer expression not + containing any variables, aggregate functions, or window functions. + The value must not be null or negative; but it can be zero, which + selects the current row itself. +

The built-in window functions are described in Table 9-47. Other window functions can be added by + the user. Also, any built-in or user-defined aggregate function can be + used as a window function. +

The syntaxes using * are used for calling parameter-less + aggregate functions as window functions, for example + count(*) OVER (PARTITION BY x ORDER BY y). + The asterisk (*) is customarily not used for non-aggregate window functions. + Aggregate window functions, unlike normal aggregate functions, do not + allow DISTINCT or ORDER BY to be used within the + function argument list. +

Window function calls are permitted only in the SELECT + list and the ORDER BY clause of the query. +

More information about window functions can be found in + Section 3.5, + Section 9.21, + Section 7.2.4. +

4.2.9. Type Casts

A type cast specifies a conversion from one data type to another. + PostgreSQL accepts two equivalent syntaxes + for type casts: +

CAST ( expression AS type )
+expression::type

+ The CAST syntax conforms to SQL; the syntax with + :: is historical PostgreSQL + usage. +

When a cast is applied to a value expression of a known type, it + represents a run-time type conversion. The cast will succeed only + if a suitable type conversion operation has been defined. Notice that this + is subtly different from the use of casts with constants, as shown in + Section 4.1.2.7. A cast applied to an + unadorned string literal represents the initial assignment of a type + to a literal constant value, and so it will succeed for any type + (if the contents of the string literal are acceptable input syntax for the + data type). +

An explicit type cast can usually be omitted if there is no ambiguity as + to the type that a value expression must produce (for example, when it is + assigned to a table column); the system will automatically apply a + type cast in such cases. However, automatic casting is only done for + casts that are marked "OK to apply implicitly" + in the system catalogs. Other casts must be invoked with + explicit casting syntax. This restriction is intended to prevent + surprising conversions from being applied silently. +

It is also possible to specify a type cast using a function-like + syntax: +

typename ( expression )

+ However, this only works for types whose names are also valid as + function names. For example, double precision + cannot be used this way, but the equivalent float8 + can. Also, the names interval, time, and + timestamp can only be used in this fashion if they are + double-quoted, because of syntactic conflicts. Therefore, the use of + the function-like cast syntax leads to inconsistencies and should + probably be avoided. +

Note: The function-like syntax is in fact just a function call. When + one of the two standard cast syntaxes is used to do a run-time + conversion, it will internally invoke a registered function to + perform the conversion. By convention, these conversion functions + have the same name as their output type, and thus the "function-like + syntax" is nothing more than a direct invocation of the underlying + conversion function. Obviously, this is not something that a portable + application should rely on. For further details see + CREATE CAST. +

4.2.10. Collation Expressions

The COLLATE clause overrides the collation of + an expression. It is appended to the expression it applies to: +

expr COLLATE collation

+ where collation is a possibly + schema-qualified identifier. The COLLATE + clause binds tighter than operators; parentheses can be used when + necessary. +

If no collation is explicitly specified, the database system + either derives a collation from the columns involved in the + expression, or it defaults to the default collation of the + database if no column is involved in the expression. +

The two common uses of the COLLATE clause are + overriding the sort order in an ORDER BY clause, for + example: +

SELECT a, b, c FROM tbl WHERE ... ORDER BY a COLLATE "C";

+ and overriding the collation of a function or operator call that + has locale-sensitive results, for example: +

SELECT * FROM tbl WHERE a > 'foo' COLLATE "C";

+ Note that in the latter case the COLLATE clause is + attached to an input argument of the operator we wish to affect. + It doesn't matter which argument of the operator or function call the + COLLATE clause is attached to, because the collation that is + applied by the operator or function is derived by considering all + arguments, and an explicit COLLATE clause will override the + collations of all other arguments. (Attaching non-matching + COLLATE clauses to more than one argument, however, is an + error. For more details see Section 22.2.) + Thus, this gives the same result as the previous example: +

SELECT * FROM tbl WHERE a COLLATE "C" > 'foo';

+ But this is an error: +

SELECT * FROM tbl WHERE (a > 'foo') COLLATE "C";

+ because it attempts to apply a collation to the result of the + > operator, which is of the non-collatable data type + boolean. +

4.2.11. Scalar Subqueries

A scalar subquery is an ordinary + SELECT query in parentheses that returns exactly one + row with one column. (See Chapter 7 for information about writing queries.) + The SELECT query is executed + and the single returned value is used in the surrounding value expression. + It is an error to use a query that + returns more than one row or more than one column as a scalar subquery. + (But if, during a particular execution, the subquery returns no rows, + there is no error; the scalar result is taken to be null.) + The subquery can refer to variables from the surrounding query, + which will act as constants during any one evaluation of the subquery. + See also Section 9.22 for other expressions involving subqueries. +

For example, the following finds the largest city population in each + state: +

SELECT name, (SELECT max(pop) FROM cities WHERE cities.state = states.name)
+    FROM states;

+

4.2.12. Array Constructors

An array constructor is an expression that builds an + array value using values for its member elements. A simple array + constructor + consists of the key word ARRAY, a left square bracket + [, a list of expressions (separated by commas) for the + array element values, and finally a right square bracket ]. + For example: +

SELECT ARRAY[1,2,3+4];
+  array
+---------
+ {1,2,7}
+(1 row)

+ By default, + the array element type is the common type of the member expressions, + determined using the same rules as for UNION or + CASE constructs (see Section 10.5). + You can override this by explicitly casting the array constructor to the + desired type, for example: +

SELECT ARRAY[1,2,22.7]::integer[];
+  array
+----------
+ {1,2,23}
+(1 row)

+ This has the same effect as casting each expression to the array + element type individually. + For more on casting, see Section 4.2.9. +

Multidimensional array values can be built by nesting array + constructors. + In the inner constructors, the key word ARRAY can + be omitted. For example, these produce the same result: + +

SELECT ARRAY[ARRAY[1,2], ARRAY[3,4]];
+     array
+---------------
+ {{1,2},{3,4}}
+(1 row)
+
+SELECT ARRAY[[1,2],[3,4]];
+     array
+---------------
+ {{1,2},{3,4}}
+(1 row)

+ + Since multidimensional arrays must be rectangular, inner constructors + at the same level must produce sub-arrays of identical dimensions. + Any cast applied to the outer ARRAY constructor propagates + automatically to all the inner constructors. +

Multidimensional array constructor elements can be anything yielding + an array of the proper kind, not only a sub-ARRAY construct. + For example: +

CREATE TABLE arr(f1 int[], f2 int[]);
+
+INSERT INTO arr VALUES (ARRAY[[1,2],[3,4]], ARRAY[[5,6],[7,8]]);
+
+SELECT ARRAY[f1, f2, '{{9,10},{11,12}}'::int[]] FROM arr;
+                     array
+------------------------------------------------
+ {{{1,2},{3,4}},{{5,6},{7,8}},{{9,10},{11,12}}}
+(1 row)

+

You can construct an empty array, but since it's impossible to have an + array with no type, you must explicitly cast your empty array to the + desired type. For example: +

SELECT ARRAY[]::integer[];
+ array
+-------
+ {}
+(1 row)

+

It is also possible to construct an array from the results of a + subquery. In this form, the array constructor is written with the + key word ARRAY followed by a parenthesized (not + bracketed) subquery. For example: +

SELECT ARRAY(SELECT oid FROM pg_proc WHERE proname LIKE 'bytea%');
+                                 array
+-----------------------------------------------------------------------
+ {2011,1954,1948,1952,1951,1244,1950,2005,1949,1953,2006,31,2412,2413}
+(1 row)

+ The subquery must return a single column. The resulting + one-dimensional array will have an element for each row in the + subquery result, with an element type matching that of the + subquery's output column. +

The subscripts of an array value built with ARRAY + always begin with one. For more information about arrays, see + Section 8.15. +

4.2.13. Row Constructors

A row constructor is an expression that builds a row value (also + called a composite value) using values + for its member fields. A row constructor consists of the key word + ROW, a left parenthesis, zero or more + expressions (separated by commas) for the row field values, and finally + a right parenthesis. For example: +

SELECT ROW(1,2.5,'this is a test');

+ The key word ROW is optional when there is more than one + expression in the list. +

A row constructor can include the syntax + rowvalue.*, + which will be expanded to a list of the elements of the row value, + just as occurs when the .* syntax is used at the top level + of a SELECT list. For example, if table t has + columns f1 and f2, these are the same: +

SELECT ROW(t.*, 42) FROM t;
+SELECT ROW(t.f1, t.f2, 42) FROM t;

+

Note: Before PostgreSQL 8.2, the + .* syntax was not expanded, so that writing + ROW(t.*, 42) created a two-field row whose first field + was another row value. The new behavior is usually more useful. + If you need the old behavior of nested row values, write the inner + row value without .*, for instance + ROW(t, 42). +

By default, the value created by a ROW expression is of + an anonymous record type. If necessary, it can be cast to a named + composite type — either the row type of a table, or a composite type + created with CREATE TYPE AS. An explicit cast might be needed + to avoid ambiguity. For example: +

CREATE TABLE mytable(f1 int, f2 float, f3 text);
+
+CREATE FUNCTION getf1(mytable) RETURNS int AS 'SELECT $1.f1' LANGUAGE SQL;
+
+-- No cast needed since only one getf1() exists
+SELECT getf1(ROW(1,2.5,'this is a test'));
+ getf1
+-------
+     1
+(1 row)
+
+CREATE TYPE myrowtype AS (f1 int, f2 text, f3 numeric);
+
+CREATE FUNCTION getf1(myrowtype) RETURNS int AS 'SELECT $1.f1' LANGUAGE SQL;
+
+-- Now we need a cast to indicate which function to call:
+SELECT getf1(ROW(1,2.5,'this is a test'));
+ERROR:  function getf1(record) is not unique
+
+SELECT getf1(ROW(1,2.5,'this is a test')::mytable);
+ getf1
+-------
+     1
+(1 row)
+
+SELECT getf1(CAST(ROW(11,'this is a test',2.5) AS myrowtype));
+ getf1
+-------
+    11
+(1 row)

+

Row constructors can be used to build composite values to be stored + in a composite-type table column, or to be passed to a function that + accepts a composite parameter. Also, + it is possible to compare two row values or test a row with + IS NULL or IS NOT NULL, for example: +

SELECT ROW(1,2.5,'this is a test') = ROW(1, 3, 'not the same');
+
+SELECT ROW(table.*) IS NULL FROM table;  -- detect all-null rows

+ For more detail see Section 9.23. + Row constructors can also be used in connection with subqueries, + as discussed in Section 9.22. +

4.2.14. Expression Evaluation Rules

The order of evaluation of subexpressions is not defined. In + particular, the inputs of an operator or function are not necessarily + evaluated left-to-right or in any other fixed order. +

Furthermore, if the result of an expression can be determined by + evaluating only some parts of it, then other subexpressions + might not be evaluated at all. For instance, if one wrote: +

SELECT true OR somefunc();

+ then somefunc() would (probably) not be called + at all. The same would be the case if one wrote: +

SELECT somefunc() OR true;

+ Note that this is not the same as the left-to-right + "short-circuiting" of Boolean operators that is found + in some programming languages. +

As a consequence, it is unwise to use functions with side effects + as part of complex expressions. It is particularly dangerous to + rely on side effects or evaluation order in WHERE and HAVING clauses, + since those clauses are extensively reprocessed as part of + developing an execution plan. Boolean + expressions (AND/OR/NOT combinations) in those clauses can be reorganized + in any manner allowed by the laws of Boolean algebra. +

When it is essential to force evaluation order, a CASE + construct (see Section 9.17) can be + used. For example, this is an untrustworthy way of trying to + avoid division by zero in a WHERE clause: +

SELECT ... WHERE x > 0 AND y/x > 1.5;

+ But this is safe: +

SELECT ... WHERE CASE WHEN x > 0 THEN y/x > 1.5 ELSE false END;

+ A CASE construct used in this fashion will defeat optimization + attempts, so it should only be done when necessary. (In this particular + example, it would be better to sidestep the problem by writing + y > 1.5*x instead.) +


PrevHomeNext
Lexical StructureUpCalling Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-fetch.html b/doc/src/sgml/html/sql-fetch.html new file mode 100644 index 000000000..23f28f355 --- /dev/null +++ b/doc/src/sgml/html/sql-fetch.html @@ -0,0 +1,957 @@ + +FETCH

FETCH

Name

FETCH -- retrieve rows from a query using a cursor

Synopsis

FETCH [ direction [ FROM | IN ] ] cursor_name
+
+where direction can be empty or one of:
+
+    NEXT
+    PRIOR
+    FIRST
+    LAST
+    ABSOLUTE count
+    RELATIVE count
+    count
+    ALL
+    FORWARD
+    FORWARD count
+    FORWARD ALL
+    BACKWARD
+    BACKWARD count
+    BACKWARD ALL

Description

FETCH retrieves rows using a previously-created cursor. +

A cursor has an associated position, which is used by + FETCH. The cursor position can be before the first row of the + query result, on any particular row of the result, or after the last row + of the result. When created, a cursor is positioned before the first row. + After fetching some rows, the cursor is positioned on the row most recently + retrieved. If FETCH runs off the end of the available rows + then the cursor is left positioned after the last row, or before the first + row if fetching backward. FETCH ALL or FETCH BACKWARD + ALL will always leave the cursor positioned after the last row or before + the first row. +

The forms NEXT, PRIOR, FIRST, + LAST, ABSOLUTE, RELATIVE fetch + a single row after moving the cursor appropriately. If there is no + such row, an empty result is returned, and the cursor is left + positioned before the first row or after the last row as + appropriate. +

The forms using FORWARD and BACKWARD + retrieve the indicated number of rows moving in the forward or + backward direction, leaving the cursor positioned on the + last-returned row (or after/before all rows, if the count exceeds the number of rows + available). +

RELATIVE 0, FORWARD 0, and + BACKWARD 0 all request fetching the current row without + moving the cursor, that is, re-fetching the most recently fetched + row. This will succeed unless the cursor is positioned before the + first row or after the last row; in which case, no row is returned. +

Note: This page describes usage of cursors at the SQL command level. + If you are trying to use cursors inside a PL/pgSQL + function, the rules are different — + see Section 39.7. +

Parameters

direction

direction defines + the fetch direction and number of rows to fetch. It can be one + of the following: + +

NEXT

Fetch the next row. This is the default if direction is omitted. +

PRIOR

Fetch the prior row. +

FIRST

Fetch the first row of the query (same as ABSOLUTE 1). +

LAST

Fetch the last row of the query (same as ABSOLUTE -1). +

ABSOLUTE count

Fetch the count'th row of the query, + or the abs(count)'th row from + the end if count is negative. Position + before first row or after last row if count is out of range; in + particular, ABSOLUTE 0 positions before + the first row. +

RELATIVE count

Fetch the count'th succeeding row, or + the abs(count)'th prior + row if count is + negative. RELATIVE 0 re-fetches the + current row, if any. +

count

Fetch the next count rows (same as + FORWARD count). +

ALL

Fetch all remaining rows (same as FORWARD ALL). +

FORWARD

Fetch the next row (same as NEXT). +

FORWARD count

Fetch the next count rows. + FORWARD 0 re-fetches the current row. +

FORWARD ALL

Fetch all remaining rows. +

BACKWARD

Fetch the prior row (same as PRIOR). +

BACKWARD count

Fetch the prior count rows (scanning + backwards). BACKWARD 0 re-fetches the + current row. +

BACKWARD ALL

Fetch all prior rows (scanning backwards). +

count

count is a + possibly-signed integer constant, determining the location or + number of rows to fetch. For FORWARD and + BACKWARD cases, specifying a negative count is equivalent to changing + the sense of FORWARD and BACKWARD. +

cursor_name

An open cursor's name. +

Outputs

On successful completion, a FETCH command returns a command + tag of the form +

FETCH count

+ The count is the number + of rows fetched (possibly zero). Note that in + psql, the command tag will not actually be + displayed, since psql displays the fetched + rows instead. +

Notes

The cursor should be declared with the SCROLL + option if one intends to use any variants of FETCH + other than FETCH NEXT or FETCH FORWARD with + a positive count. For simple queries + PostgreSQL will allow backwards fetch + from cursors not declared with SCROLL, but this + behavior is best not relied on. If the cursor is declared with + NO SCROLL, no backward fetches are allowed. +

ABSOLUTE fetches are not any faster than + navigating to the desired row with a relative move: the underlying + implementation must traverse all the intermediate rows anyway. + Negative absolute fetches are even worse: the query must be read to + the end to find the last row, and then traversed backward from + there. However, rewinding to the start of the query (as with + FETCH ABSOLUTE 0) is fast. +

DECLARE + is used to define a cursor. Use + MOVE + to change cursor position without retrieving data. +

Examples

The following example traverses a table using a cursor: + +

BEGIN WORK;
+
+-- Set up a cursor:
+DECLARE liahona SCROLL CURSOR FOR SELECT * FROM films;
+
+-- Fetch the first 5 rows in the cursor liahona:
+FETCH FORWARD 5 FROM liahona;
+
+ code  |          title          | did | date_prod  |   kind   |  len
+-------+-------------------------+-----+------------+----------+-------
+ BL101 | The Third Man           | 101 | 1949-12-23 | Drama    | 01:44
+ BL102 | The African Queen       | 101 | 1951-08-11 | Romantic | 01:43
+ JL201 | Une Femme est une Femme | 102 | 1961-03-12 | Romantic | 01:25
+ P_301 | Vertigo                 | 103 | 1958-11-14 | Action   | 02:08
+ P_302 | Becket                  | 103 | 1964-02-03 | Drama    | 02:28
+
+-- Fetch the previous row:
+FETCH PRIOR FROM liahona;
+
+ code  |  title  | did | date_prod  |  kind  |  len
+-------+---------+-----+------------+--------+-------
+ P_301 | Vertigo | 103 | 1958-11-14 | Action | 02:08
+
+-- Close the cursor and end the transaction:
+CLOSE liahona;
+COMMIT WORK;

Compatibility

The SQL standard defines FETCH for use in + embedded SQL only. The variant of FETCH + described here returns the data as if it were a + SELECT result rather than placing it in host + variables. Other than this point, FETCH is + fully upward-compatible with the SQL standard. +

The FETCH forms involving + FORWARD and BACKWARD, as well + as the forms FETCH count and FETCH + ALL, in which FORWARD is implicit, are + PostgreSQL extensions. +

The SQL standard allows only FROM preceding the cursor + name; the option to use IN, or to leave them out altogether, is + an extension. +

See Also

CLOSE, DECLARE, MOVE

PrevHomeNext
EXPLAINUpGRANT
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-grant.html b/doc/src/sgml/html/sql-grant.html new file mode 100644 index 000000000..b2745ea8c --- /dev/null +++ b/doc/src/sgml/html/sql-grant.html @@ -0,0 +1,1354 @@ + +GRANT

GRANT

Name

GRANT -- define access privileges

Synopsis

GRANT { { SELECT | INSERT | UPDATE | DELETE | TRUNCATE | REFERENCES | TRIGGER }
+    [, ...] | ALL [ PRIVILEGES ] }
+    ON { [ TABLE ] table_name [, ...]
+         | ALL TABLES IN SCHEMA schema_name [, ...] }
+    TO { [ GROUP ] role_name | PUBLIC } [, ...] [ WITH GRANT OPTION ]
+
+GRANT { { SELECT | INSERT | UPDATE | REFERENCES } ( column_name [, ...] )
+    [, ...] | ALL [ PRIVILEGES ] ( column_name [, ...] ) }
+    ON [ TABLE ] table_name [, ...]
+    TO { [ GROUP ] role_name | PUBLIC } [, ...] [ WITH GRANT OPTION ]
+
+GRANT { { USAGE | SELECT | UPDATE }
+    [, ...] | ALL [ PRIVILEGES ] }
+    ON { SEQUENCE sequence_name [, ...]
+         | ALL SEQUENCES IN SCHEMA schema_name [, ...] }
+    TO { [ GROUP ] role_name | PUBLIC } [, ...] [ WITH GRANT OPTION ]
+
+GRANT { { CREATE | CONNECT | TEMPORARY | TEMP } [, ...] | ALL [ PRIVILEGES ] }
+    ON DATABASE database_name [, ...]
+    TO { [ GROUP ] role_name | PUBLIC } [, ...] [ WITH GRANT OPTION ]
+
+GRANT { USAGE | ALL [ PRIVILEGES ] }
+    ON DOMAIN domain_name [, ...]
+    TO { [ GROUP ] role_name | PUBLIC } [, ...] [ WITH GRANT OPTION ]
+
+GRANT { USAGE | ALL [ PRIVILEGES ] }
+    ON FOREIGN DATA WRAPPER fdw_name [, ...]
+    TO { [ GROUP ] role_name | PUBLIC } [, ...] [ WITH GRANT OPTION ]
+
+GRANT { USAGE | ALL [ PRIVILEGES ] }
+    ON FOREIGN SERVER server_name [, ...]
+    TO { [ GROUP ] role_name | PUBLIC } [, ...] [ WITH GRANT OPTION ]
+
+GRANT { EXECUTE | ALL [ PRIVILEGES ] }
+    ON { FUNCTION function_name ( [ [ argmode ] [ arg_name ] arg_type [, ...] ] ) [, ...]
+         | ALL FUNCTIONS IN SCHEMA schema_name [, ...] }
+    TO { [ GROUP ] role_name | PUBLIC } [, ...] [ WITH GRANT OPTION ]
+
+GRANT { USAGE | ALL [ PRIVILEGES ] }
+    ON LANGUAGE lang_name [, ...]
+    TO { [ GROUP ] role_name | PUBLIC } [, ...] [ WITH GRANT OPTION ]
+
+GRANT { { SELECT | UPDATE } [, ...] | ALL [ PRIVILEGES ] }
+    ON LARGE OBJECT loid [, ...]
+    TO { [ GROUP ] role_name | PUBLIC } [, ...] [ WITH GRANT OPTION ]
+
+GRANT { { CREATE | USAGE } [, ...] | ALL [ PRIVILEGES ] }
+    ON SCHEMA schema_name [, ...]
+    TO { [ GROUP ] role_name | PUBLIC } [, ...] [ WITH GRANT OPTION ]
+
+GRANT { CREATE | ALL [ PRIVILEGES ] }
+    ON TABLESPACE tablespace_name [, ...]
+    TO { [ GROUP ] role_name | PUBLIC } [, ...] [ WITH GRANT OPTION ]
+
+GRANT { USAGE | ALL [ PRIVILEGES ] }
+    ON TYPE type_name [, ...]
+    TO { [ GROUP ] role_name | PUBLIC } [, ...] [ WITH GRANT OPTION ]
+
+GRANT role_name [, ...] TO role_name [, ...] [ WITH ADMIN OPTION ]

Description

The GRANT command has two basic variants: one + that grants privileges on a database object (table, column, view, foreign + table, sequence, database, foreign-data wrapper, foreign server, function, + procedural language, schema, or tablespace), and one that grants + membership in a role. These variants are similar in many ways, but + they are different enough to be described separately. +

GRANT on Database Objects

This variant of the GRANT command gives specific + privileges on a database object to + one or more roles. These privileges are added + to those already granted, if any. +

There is also an option to grant privileges on all objects of the same + type within one or more schemas. This functionality is currently supported + only for tables, sequences, and functions (but note that ALL + TABLES is considered to include views and foreign tables). +

The key word PUBLIC indicates that the + privileges are to be granted to all roles, including those that might + be created later. PUBLIC can be thought of as an + implicitly defined group that always includes all roles. + Any particular role will have the sum + of privileges granted directly to it, privileges granted to any role it + is presently a member of, and privileges granted to + PUBLIC. +

If WITH GRANT OPTION is specified, the recipient + of the privilege can in turn grant it to others. Without a grant + option, the recipient cannot do that. Grant options cannot be granted + to PUBLIC. +

There is no need to grant privileges to the owner of an object + (usually the user that created it), + as the owner has all privileges by default. (The owner could, + however, choose to revoke some of his own privileges for safety.) +

The right to drop an object, or to alter its definition in any way, is + not treated as a grantable privilege; it is inherent in the owner, + and cannot be granted or revoked. (However, a similar effect can be + obtained by granting or revoking membership in the role that owns + the object; see below.) The owner implicitly has all grant + options for the object, too. +

PostgreSQL grants default privileges on some types of objects to + PUBLIC. No privileges are granted to + PUBLIC by default on tables, + columns, schemas or tablespaces. For other types, the default privileges + granted to PUBLIC are as follows: + CONNECT and CREATE TEMP TABLE for + databases; EXECUTE privilege for functions; and + USAGE privilege for languages. + The object owner can, of course, REVOKE + both default and expressly granted privileges. (For maximum + security, issue the REVOKE in the same transaction that + creates the object; then there is no window in which another user + can use the object.) + Also, these initial default privilege settings can be changed using the + ALTER DEFAULT PRIVILEGES + command. +

The possible privileges are: + +

SELECT

Allows SELECT from + any column, or the specific columns listed, of the specified table, + view, or sequence. + Also allows the use of + COPY TO. + This privilege is also needed to reference existing column values in + UPDATE or + DELETE. + For sequences, this privilege also allows the use of the + currval function. + For large objects, this privilege allows the object to be read. +

INSERT

Allows INSERT of a new + row into the specified table. If specific columns are listed, + only those columns may be assigned to in the INSERT + command (other columns will therefore receive default values). + Also allows COPY FROM. +

UPDATE

Allows UPDATE of any + column, or the specific columns listed, of the specified table. + (In practice, any nontrivial UPDATE command will require + SELECT privilege as well, since it must reference table + columns to determine which rows to update, and/or to compute new + values for columns.) + SELECT ... FOR UPDATE + and SELECT ... FOR SHARE + also require this privilege on at least one column, in addition to the + SELECT privilege. For sequences, this + privilege allows the use of the nextval and + setval functions. + For large objects, this privilege allows writing or truncating the + object. +

DELETE

Allows DELETE of a row + from the specified table. + (In practice, any nontrivial DELETE command will require + SELECT privilege as well, since it must reference table + columns to determine which rows to delete.) +

TRUNCATE

Allows TRUNCATE on + the specified table. +

REFERENCES

To create a foreign key constraint, it is + necessary to have this privilege on both the referencing and + referenced columns. The privilege may be granted for all columns + of a table, or just specific columns. +

TRIGGER

Allows the creation of a trigger on the specified table. (See the + CREATE TRIGGER statement.) +

CREATE

For databases, allows new schemas to be created within the database. +

For schemas, allows new objects to be created within the schema. + To rename an existing object, you must own the object and + have this privilege for the containing schema. +

For tablespaces, allows tables, indexes, and temporary files to be + created within the tablespace, and allows databases to be created that + have the tablespace as their default tablespace. (Note that revoking + this privilege will not alter the placement of existing objects.) +

CONNECT

Allows the user to connect to the specified database. This + privilege is checked at connection startup (in addition to checking + any restrictions imposed by pg_hba.conf). +

TEMPORARY
TEMP

Allows temporary tables to be created while using the specified database. +

EXECUTE

Allows the use of the specified function and the use of any + operators that are implemented on top of the function. This is + the only type of privilege that is applicable to functions. + (This syntax works for aggregate functions, as well.) +

USAGE

For procedural languages, allows the use of the specified language for + the creation of functions in that language. This is the only type + of privilege that is applicable to procedural languages. +

For schemas, allows access to objects contained in the specified + schema (assuming that the objects' own privilege requirements are + also met). Essentially this allows the grantee to "look up" + objects within the schema. Without this permission, it is still + possible to see the object names, e.g. by querying the system tables. + Also, after revoking this permission, existing backends might have + statements that have previously performed this lookup, so this is not + a completely secure way to prevent object access. +

For sequences, this privilege allows the use of the + currval and nextval functions. +

For types and domains, this privilege allow the use of the type or + domain in the creation of tables, functions, and other schema objects. + (Note that it does not control general "usage" of the type, + such as values of the type appearing in queries. It only prevents + objects from being created that depend on the type. The main purpose of + the privilege is controlling which users create dependencies on a type, + which could prevent the owner from changing the type later.) +

For foreign-data wrappers, this privilege enables the grantee + to create new servers using that foreign-data wrapper. +

For servers, this privilege enables the grantee to create, + alter, and drop his own user's user mappings associated with + that server. Also, it enables the grantee to query the options + of the server and associated user mappings. +

ALL PRIVILEGES

Grant all of the available privileges at once. + The PRIVILEGES key word is optional in + PostgreSQL, though it is required by + strict SQL. +

+ + The privileges required by other commands are listed on the + reference page of the respective command. +

GRANT on Roles

This variant of the GRANT command grants membership + in a role to one or more other roles. Membership in a role is significant + because it conveys the privileges granted to a role to each of its + members. +

If WITH ADMIN OPTION is specified, the member can + in turn grant membership in the role to others, and revoke membership + in the role as well. Without the admin option, ordinary users cannot do + that. However, + database superusers can grant or revoke membership in any role to anyone. + Roles having CREATEROLE privilege can grant or revoke + membership in any role that is not a superuser. +

Unlike the case with privileges, membership in a role cannot be granted + to PUBLIC. Note also that this form of the command does not + allow the noise word GROUP. +

Notes

The REVOKE command is used + to revoke access privileges. +

Since PostgreSQL 8.1, the concepts of users and + groups have been unified into a single kind of entity called a role. + It is therefore no longer necessary to use the keyword GROUP + to identify whether a grantee is a user or a group. GROUP + is still allowed in the command, but it is a noise word. +

A user may perform SELECT, INSERT, etc. on a + column if he holds that privilege for either the specific column or + its whole table. Granting the privilege at the table level and then + revoking it for one column will not do what you might wish: the + table-level grant is unaffected by a column-level operation. +

When a non-owner of an object attempts to GRANT privileges + on the object, the command will fail outright if the user has no + privileges whatsoever on the object. As long as some privilege is + available, the command will proceed, but it will grant only those + privileges for which the user has grant options. The GRANT ALL + PRIVILEGES forms will issue a warning message if no grant options are + held, while the other forms will issue a warning if grant options for + any of the privileges specifically named in the command are not held. + (In principle these statements apply to the object owner as well, but + since the owner is always treated as holding all grant options, the + cases can never occur.) +

It should be noted that database superusers can access + all objects regardless of object privilege settings. This + is comparable to the rights of root in a Unix system. + As with root, it's unwise to operate as a superuser + except when absolutely necessary. +

If a superuser chooses to issue a GRANT or REVOKE + command, the command is performed as though it were issued by the + owner of the affected object. In particular, privileges granted via + such a command will appear to have been granted by the object owner. + (For role membership, the membership appears to have been granted + by the containing role itself.) +

GRANT and REVOKE can also be done by a role + that is not the owner of the affected object, but is a member of the role + that owns the object, or is a member of a role that holds privileges + WITH GRANT OPTION on the object. In this case the + privileges will be recorded as having been granted by the role that + actually owns the object or holds the privileges + WITH GRANT OPTION. For example, if table + t1 is owned by role g1, of which role + u1 is a member, then u1 can grant privileges + on t1 to u2, but those privileges will appear + to have been granted directly by g1. Any other member + of role g1 could revoke them later. +

If the role executing GRANT holds the required privileges + indirectly via more than one role membership path, it is unspecified + which containing role will be recorded as having done the grant. In such + cases it is best practice to use SET ROLE to become the + specific role you want to do the GRANT as. +

Granting permission on a table does not automatically extend + permissions to any sequences used by the table, including + sequences tied to SERIAL columns. Permissions on + sequences must be set separately. +

Use psql's \dp command + to obtain information about existing privileges for tables and + columns. For example: +

=> \dp mytable
+                              Access privileges
+ Schema |  Name   | Type  |   Access privileges   | Column access privileges 
+--------+---------+-------+-----------------------+--------------------------
+ public | mytable | table | miriam=arwdDxt/miriam | col1:
+                          : =r/miriam             :   miriam_rw=rw/miriam
+                          : admin=arw/miriam        
+(1 row)

+ The entries shown by \dp are interpreted thus: +

rolename=xxxx -- privileges granted to a role
+        =xxxx -- privileges granted to PUBLIC
+
+            r -- SELECT ("read")
+            w -- UPDATE ("write")
+            a -- INSERT ("append")
+            d -- DELETE
+            D -- TRUNCATE
+            x -- REFERENCES
+            t -- TRIGGER
+            X -- EXECUTE
+            U -- USAGE
+            C -- CREATE
+            c -- CONNECT
+            T -- TEMPORARY
+      arwdDxt -- ALL PRIVILEGES (for tables, varies for other objects)
+            * -- grant option for preceding privilege
+
+        /yyyy -- role that granted this privilege

+ + The above example display would be seen by user miriam after + creating table mytable and doing: + +

GRANT SELECT ON mytable TO PUBLIC;
+GRANT SELECT, UPDATE, INSERT ON mytable TO admin;
+GRANT SELECT (col1), UPDATE (col1) ON mytable TO miriam_rw;

+

For non-table objects there are other \d commands + that can display their privileges. +

If the "Access privileges" column is empty for a given object, + it means the object has default privileges (that is, its privileges column + is null). Default privileges always include all privileges for the owner, + and can include some privileges for PUBLIC depending on the + object type, as explained above. The first GRANT or + REVOKE on an object + will instantiate the default privileges (producing, for example, + {miriam=arwdDxt/miriam}) and then modify them per the + specified request. Similarly, entries are shown in "Column access + privileges" only for columns with nondefault privileges. + (Note: for this purpose, "default privileges" always means the + built-in default privileges for the object's type. An object whose + privileges have been affected by an ALTER DEFAULT PRIVILEGES + command will always be shown with an explicit privilege entry that + includes the effects of the ALTER.) +

Notice that the owner's implicit grant options are not marked in the + access privileges display. A * will appear only when + grant options have been explicitly granted to someone. +

Examples

Grant insert privilege to all users on table films: + +

GRANT INSERT ON films TO PUBLIC;

+

Grant all available privileges to user manuel on view + kinds: + +

GRANT ALL PRIVILEGES ON kinds TO manuel;

+ + Note that while the above will indeed grant all privileges if executed by a + superuser or the owner of kinds, when executed by someone + else it will only grant those permissions for which the someone else has + grant options. +

Grant membership in role admins to user joe: + +

GRANT admins TO joe;

Compatibility

According to the SQL standard, the PRIVILEGES + key word in ALL PRIVILEGES is required. The + SQL standard does not support setting the privileges on more than + one object per command. +

PostgreSQL allows an object owner to revoke his + own ordinary privileges: for example, a table owner can make the table + read-only to himself by revoking his own INSERT, + UPDATE, DELETE, and TRUNCATE + privileges. This is not possible according to the SQL standard. The + reason is that PostgreSQL treats the owner's + privileges as having been granted by the owner to himself; therefore he + can revoke them too. In the SQL standard, the owner's privileges are + granted by an assumed entity "_SYSTEM". Not being + "_SYSTEM", the owner cannot revoke these rights. +

According to the SQL standard, grant options can be granted to + PUBLIC; PostgreSQL only supports granting grant options + to roles. +

The SQL standard provides for a USAGE privilege + on other kinds of objects: character sets, collations, + translations. +

In the SQL standard, sequences only have a USAGE + privilege, which controls the use of the NEXT VALUE FOR + expression, which is equivalent to the + function nextval in PostgreSQL. The sequence + privileges SELECT and UPDATE are + PostgreSQL extensions. The application of the + sequence USAGE privilege to + the currval function is also a PostgreSQL extension (as + is the function itself). +

Privileges on databases, tablespaces, schemas, and languages are + PostgreSQL extensions. +


PrevHomeNext
FETCHUpINSERT
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-insert.html b/doc/src/sgml/html/sql-insert.html new file mode 100644 index 000000000..b172d846e --- /dev/null +++ b/doc/src/sgml/html/sql-insert.html @@ -0,0 +1,785 @@ + +INSERT

INSERT

Name

INSERT -- create new rows in a table

Synopsis

[ WITH [ RECURSIVE ] with_query [, ...] ]
+INSERT INTO table_name [ ( column_name [, ...] ) ]
+    { DEFAULT VALUES | VALUES ( { expression | DEFAULT } [, ...] ) [, ...] | query }
+    [ RETURNING * | output_expression [ [ AS ] output_name ] [, ...] ]

Description

INSERT inserts new rows into a table. + One can insert one or more rows specified by value expressions, + or zero or more rows resulting from a query. +

The target column names can be listed in any order. If no list of + column names is given at all, the default is all the columns of the + table in their declared order; or the first N column + names, if there are only N columns supplied by the + VALUES clause or query. The values + supplied by the VALUES clause or query are + associated with the explicit or implicit column list left-to-right. +

Each column not present in the explicit or implicit column list will be + filled with a default value, either its declared default value + or null if there is none. +

If the expression for any column is not of the correct data type, + automatic type conversion will be attempted. +

The optional RETURNING clause causes INSERT + to compute and return value(s) based on each row actually inserted. + This is primarily useful for obtaining values that were supplied by + defaults, such as a serial sequence number. However, any expression + using the table's columns is allowed. The syntax of the + RETURNING list is identical to that of the output list + of SELECT. +

You must have INSERT privilege on a table in + order to insert into it. If a column list is specified, you only + need INSERT privilege on the listed columns. + Use of the RETURNING clause requires SELECT + privilege on all columns mentioned in RETURNING. + If you use the query clause to insert rows from a + query, you of course need to have SELECT privilege on + any table or column used in the query. +

Parameters

with_query

The WITH clause allows you to specify one or more + subqueries that can be referenced by name in the INSERT + query. See Section 7.8 and SELECT + for details. +

It is possible for the query + (SELECT statement) + to also contain a WITH clause. In such a case both + sets of with_query can be referenced within + the query, but the + second one takes precedence since it is more closely nested. +

table_name

The name (optionally schema-qualified) of an existing table. +

column_name

The name of a column in the table named by table_name. + The column name can be qualified with a subfield name or array + subscript, if needed. (Inserting into only some fields of a + composite column leaves the other fields null.) +

DEFAULT VALUES

All columns will be filled with their default values. +

expression

An expression or value to assign to the corresponding column. +

DEFAULT

The corresponding column will be filled with + its default value. +

query

A query (SELECT statement) that supplies the + rows to be inserted. Refer to the + SELECT + statement for a description of the syntax. +

output_expression

An expression to be computed and returned by the INSERT + command after each row is inserted. The expression can use any + column names of the table named by table_name. + Write * to return all columns of the inserted row(s). +

output_name

A name to use for a returned column. +

Outputs

On successful completion, an INSERT command returns a command + tag of the form +

INSERT oid count

+ The count is the number + of rows inserted. If count + is exactly one, and the target table has OIDs, then + oid is the + OID assigned to the inserted row. Otherwise + oid is zero. +

If the INSERT command contains a RETURNING + clause, the result will be similar to that of a SELECT + statement containing the columns and values defined in the + RETURNING list, computed over the row(s) inserted by the + command. +

Examples

Insert a single row into table films: + +

INSERT INTO films VALUES
+    ('UA502', 'Bananas', 105, '1971-07-13', 'Comedy', '82 minutes');

+

In this example, the len column is + omitted and therefore it will have the default value: + +

INSERT INTO films (code, title, did, date_prod, kind)
+    VALUES ('T_601', 'Yojimbo', 106, '1961-06-16', 'Drama');

+

This example uses the DEFAULT clause for + the date columns rather than specifying a value: + +

INSERT INTO films VALUES
+    ('UA502', 'Bananas', 105, DEFAULT, 'Comedy', '82 minutes');
+INSERT INTO films (code, title, did, date_prod, kind)
+    VALUES ('T_601', 'Yojimbo', 106, DEFAULT, 'Drama');

+

To insert a row consisting entirely of default values: + +

INSERT INTO films DEFAULT VALUES;

+

To insert multiple rows using the multirow VALUES syntax: + +

INSERT INTO films (code, title, did, date_prod, kind) VALUES
+    ('B6717', 'Tampopo', 110, '1985-02-10', 'Comedy'),
+    ('HG120', 'The Dinner Game', 140, DEFAULT, 'Comedy');

+

This example inserts some rows into table + films from a table tmp_films + with the same column layout as films: + +

INSERT INTO films SELECT * FROM tmp_films WHERE date_prod < '2004-05-07';

+

This example inserts into array columns: + +

-- Create an empty 3x3 gameboard for noughts-and-crosses
+INSERT INTO tictactoe (game, board[1:3][1:3])
+    VALUES (1, '{{" "," "," "},{" "," "," "},{" "," "," "}}');
+-- The subscripts in the above example aren't really needed
+INSERT INTO tictactoe (game, board)
+    VALUES (2, '{{X," "," "},{" ",O," "},{" ",X," "}}');

+

Insert a single row into table distributors, returning + the sequence number generated by the DEFAULT clause: + +

INSERT INTO distributors (did, dname) VALUES (DEFAULT, 'XYZ Widgets')
+   RETURNING did;

+

Increment the sales count of the salesperson who manages the + account for Acme Corporation, and record the whole updated row + along with current time in a log table: +

WITH upd AS (
+  UPDATE employees SET sales_count = sales_count + 1 WHERE id =
+    (SELECT sales_person FROM accounts WHERE name = 'Acme Corporation')
+    RETURNING *
+)
+INSERT INTO employees_log SELECT *, current_timestamp FROM upd;

Compatibility

INSERT conforms to the SQL standard, except that + the RETURNING clause is a + PostgreSQL extension, as is the ability + to use WITH with INSERT. + Also, the case in + which a column name list is omitted, but not all the columns are + filled from the VALUES clause or query, + is disallowed by the standard. +

Possible limitations of the query clause are documented under + SELECT. +


PrevHomeNext
GRANTUpLISTEN
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-keywords-appendix.html b/doc/src/sgml/html/sql-keywords-appendix.html new file mode 100644 index 000000000..09c2c838d --- /dev/null +++ b/doc/src/sgml/html/sql-keywords-appendix.html @@ -0,0 +1,11438 @@ + +SQL Key Words

Appendix C. SQL Key Words

Table C-1 lists all tokens that are key words + in the SQL standard and in PostgreSQL + 9.2.2. Background information can be found in Section 4.1.1. + (For space reasons, only the latest two versions of the SQL standard, and + SQL-92 for historical comparison, are included. The differences between + those and the other intermediate standard versions are small.) +

SQL distinguishes between reserved and + non-reserved key words. According to the standard, + reserved key words + are the only real key words; they are never allowed as identifiers. + Non-reserved key words only have a special meaning in particular + contexts and can be used as identifiers in other contexts. Most + non-reserved key words are actually the names of built-in tables + and functions specified by SQL. The concept of non-reserved key + words essentially only exists to declare that some predefined meaning + is attached to a word in some contexts. +

In the PostgreSQL parser life is a bit + more complicated. There are several different classes of tokens + ranging from those that can never be used as an identifier to those + that have absolutely no special status in the parser as compared to + an ordinary identifier. (The latter is usually the case for + functions specified by SQL.) Even reserved key words are not + completely reserved in PostgreSQL, but + can be used as column labels (for example, SELECT 55 AS + CHECK, even though CHECK is a reserved key + word). +

In Table C-1 in the column for + PostgreSQL we classify as + "non-reserved" those key words that are explicitly + known to the parser but are allowed as column or table names. + Some key words that are otherwise + non-reserved cannot be used as function or data type names and are + marked accordingly. (Most of these words represent built-in + functions or data types with special syntax. The function or type + is still available but it cannot be redefined by the user.) Labeled + "reserved" are those tokens that are not allowed as + column or table names. Some reserved key words are + allowable as names for functions or data types; this is also shown in the + table. If not so marked, a reserved key word is only allowed as an + "AS" column label name. +

As a general rule, if you get spurious parser errors for commands + that contain any of the listed key words as an identifier you should + try to quote the identifier to see if the problem goes away. +

It is important to understand before studying Table C-1 that the fact that a key word is not + reserved in PostgreSQL does not mean that + the feature related to the word is not implemented. Conversely, the + presence of a key word does not indicate the existence of a feature. +

Table C-1. SQL Key Words

Key WordPostgreSQLSQL:2011SQL:2008SQL-92
A non-reservednon-reserved 
ABORTnon-reserved   
ABS reservedreserved 
ABSENT non-reservednon-reserved 
ABSOLUTEnon-reservednon-reservednon-reservedreserved
ACCESSnon-reserved   
ACCORDING non-reservednon-reserved 
ACTIONnon-reservednon-reservednon-reservedreserved
ADA non-reservednon-reservednon-reserved
ADDnon-reservednon-reservednon-reservedreserved
ADMINnon-reservednon-reservednon-reserved 
AFTERnon-reservednon-reservednon-reserved 
AGGREGATEnon-reserved   
ALLreservedreservedreservedreserved
ALLOCATE reservedreservedreserved
ALSOnon-reserved   
ALTERnon-reservedreservedreservedreserved
ALWAYSnon-reservednon-reservednon-reserved 
ANALYSEreserved   
ANALYZEreserved   
ANDreservedreservedreservedreserved
ANYreservedreservedreservedreserved
ARE reservedreservedreserved
ARRAYreservedreservedreserved 
ARRAY_AGG reservedreserved 
ARRAY_MAX_CARDINALITY reserved  
ASreservedreservedreservedreserved
ASCreservednon-reservednon-reservedreserved
ASENSITIVE reservedreserved 
ASSERTIONnon-reservednon-reservednon-reservedreserved
ASSIGNMENTnon-reservednon-reservednon-reserved 
ASYMMETRICreservedreservedreserved 
ATnon-reservedreservedreservedreserved
ATOMIC reservedreserved 
ATTRIBUTEnon-reservednon-reservednon-reserved 
ATTRIBUTES non-reservednon-reserved 
AUTHORIZATIONreserved (can be function or type)reservedreservedreserved
AVG reservedreservedreserved
BACKWARDnon-reserved   
BASE64 non-reservednon-reserved 
BEFOREnon-reservednon-reservednon-reserved 
BEGINnon-reservedreservedreservedreserved
BEGIN_FRAME reserved  
BEGIN_PARTITION reserved  
BERNOULLI non-reservednon-reserved 
BETWEENnon-reserved (cannot be function or type)reservedreservedreserved
BIGINTnon-reserved (cannot be function or type)reservedreserved 
BINARYreserved (can be function or type)reservedreserved 
BITnon-reserved (cannot be function or type)  reserved
BIT_LENGTH   reserved
BLOB reservedreserved 
BLOCKED non-reservednon-reserved 
BOM non-reservednon-reserved 
BOOLEANnon-reserved (cannot be function or type)reservedreserved 
BOTHreservedreservedreservedreserved
BREADTH non-reservednon-reserved 
BYnon-reservedreservedreservedreserved
C non-reservednon-reservednon-reserved
CACHEnon-reserved   
CALL reservedreserved 
CALLEDnon-reservedreservedreserved 
CARDINALITY reservedreserved 
CASCADEnon-reservednon-reservednon-reservedreserved
CASCADEDnon-reservedreservedreservedreserved
CASEreservedreservedreservedreserved
CASTreservedreservedreservedreserved
CATALOGnon-reservednon-reservednon-reservedreserved
CATALOG_NAME non-reservednon-reservednon-reserved
CEIL reservedreserved 
CEILING reservedreserved 
CHAINnon-reservednon-reservednon-reserved 
CHARnon-reserved (cannot be function or type)reservedreservedreserved
CHARACTERnon-reserved (cannot be function or type)reservedreservedreserved
CHARACTERISTICSnon-reservednon-reservednon-reserved 
CHARACTERS non-reservednon-reserved 
CHARACTER_LENGTH reservedreservedreserved
CHARACTER_SET_CATALOG non-reservednon-reservednon-reserved
CHARACTER_SET_NAME non-reservednon-reservednon-reserved
CHARACTER_SET_SCHEMA non-reservednon-reservednon-reserved
CHAR_LENGTH reservedreservedreserved
CHECKreservedreservedreservedreserved
CHECKPOINTnon-reserved   
CLASSnon-reserved   
CLASS_ORIGIN non-reservednon-reservednon-reserved
CLOB reservedreserved 
CLOSEnon-reservedreservedreservedreserved
CLUSTERnon-reserved   
COALESCEnon-reserved (cannot be function or type)reservedreservedreserved
COBOL non-reservednon-reservednon-reserved
COLLATEreservedreservedreservedreserved
COLLATIONreserved (can be function or type)non-reservednon-reservedreserved
COLLATION_CATALOG non-reservednon-reservednon-reserved
COLLATION_NAME non-reservednon-reservednon-reserved
COLLATION_SCHEMA non-reservednon-reservednon-reserved
COLLECT reservedreserved 
COLUMNreservedreservedreservedreserved
COLUMNS non-reservednon-reserved 
COLUMN_NAME non-reservednon-reservednon-reserved
COMMAND_FUNCTION non-reservednon-reservednon-reserved
COMMAND_FUNCTION_CODE non-reservednon-reserved 
COMMENTnon-reserved   
COMMENTSnon-reserved   
COMMITnon-reservedreservedreservedreserved
COMMITTEDnon-reservednon-reservednon-reservednon-reserved
CONCURRENTLYreserved (can be function or type)   
CONDITION reservedreserved 
CONDITION_NUMBER non-reservednon-reservednon-reserved
CONFIGURATIONnon-reserved   
CONNECT reservedreservedreserved
CONNECTIONnon-reservednon-reservednon-reservedreserved
CONNECTION_NAME non-reservednon-reservednon-reserved
CONSTRAINTreservedreservedreservedreserved
CONSTRAINTSnon-reservednon-reservednon-reservedreserved
CONSTRAINT_CATALOG non-reservednon-reservednon-reserved
CONSTRAINT_NAME non-reservednon-reservednon-reserved
CONSTRAINT_SCHEMA non-reservednon-reservednon-reserved
CONSTRUCTOR non-reservednon-reserved 
CONTAINS reservednon-reserved 
CONTENTnon-reservednon-reservednon-reserved 
CONTINUEnon-reservednon-reservednon-reservedreserved
CONTROL non-reservednon-reserved 
CONVERSIONnon-reserved   
CONVERT reservedreservedreserved
COPYnon-reserved   
CORR reservedreserved 
CORRESPONDING reservedreservedreserved
COSTnon-reserved   
COUNT reservedreservedreserved
COVAR_POP reservedreserved 
COVAR_SAMP reservedreserved 
CREATEreservedreservedreservedreserved
CROSSreserved (can be function or type)reservedreservedreserved
CSVnon-reserved   
CUBE reservedreserved 
CUME_DIST reservedreserved 
CURRENTnon-reservedreservedreservedreserved
CURRENT_CATALOGreservedreservedreserved 
CURRENT_DATEreservedreservedreservedreserved
CURRENT_DEFAULT_TRANSFORM_GROUP reservedreserved 
CURRENT_PATH reservedreserved 
CURRENT_ROLEreservedreservedreserved 
CURRENT_ROW reserved  
CURRENT_SCHEMAreserved (can be function or type)reservedreserved 
CURRENT_TIMEreservedreservedreservedreserved
CURRENT_TIMESTAMPreservedreservedreservedreserved
CURRENT_TRANSFORM_GROUP_FOR_TYPE reservedreserved 
CURRENT_USERreservedreservedreservedreserved
CURSORnon-reservedreservedreservedreserved
CURSOR_NAME non-reservednon-reservednon-reserved
CYCLEnon-reservedreservedreserved 
DATAnon-reservednon-reservednon-reservednon-reserved
DATABASEnon-reserved   
DATALINK reservedreserved 
DATE reservedreservedreserved
DATETIME_INTERVAL_CODE non-reservednon-reservednon-reserved
DATETIME_INTERVAL_PRECISION non-reservednon-reservednon-reserved
DAYnon-reservedreservedreservedreserved
DB non-reservednon-reserved 
DEALLOCATEnon-reservedreservedreservedreserved
DECnon-reserved (cannot be function or type)reservedreservedreserved
DECIMALnon-reserved (cannot be function or type)reservedreservedreserved
DECLAREnon-reservedreservedreservedreserved
DEFAULTreservedreservedreservedreserved
DEFAULTSnon-reservednon-reservednon-reserved 
DEFERRABLEreservednon-reservednon-reservedreserved
DEFERREDnon-reservednon-reservednon-reservedreserved
DEFINED non-reservednon-reserved 
DEFINERnon-reservednon-reservednon-reserved 
DEGREE non-reservednon-reserved 
DELETEnon-reservedreservedreservedreserved
DELIMITERnon-reserved   
DELIMITERSnon-reserved   
DENSE_RANK reservedreserved 
DEPTH non-reservednon-reserved 
DEREF reservedreserved 
DERIVED non-reservednon-reserved 
DESCreservednon-reservednon-reservedreserved
DESCRIBE reservedreservedreserved
DESCRIPTOR non-reservednon-reservedreserved
DETERMINISTIC reservedreserved 
DIAGNOSTICS non-reservednon-reservedreserved
DICTIONARYnon-reserved   
DISABLEnon-reserved   
DISCARDnon-reserved   
DISCONNECT reservedreservedreserved
DISPATCH non-reservednon-reserved 
DISTINCTreservedreservedreservedreserved
DLNEWCOPY reservedreserved 
DLPREVIOUSCOPY reservedreserved 
DLURLCOMPLETE reservedreserved 
DLURLCOMPLETEONLY reservedreserved 
DLURLCOMPLETEWRITE reservedreserved 
DLURLPATH reservedreserved 
DLURLPATHONLY reservedreserved 
DLURLPATHWRITE reservedreserved 
DLURLSCHEME reservedreserved 
DLURLSERVER reservedreserved 
DLVALUE reservedreserved 
DOreserved   
DOCUMENTnon-reservednon-reservednon-reserved 
DOMAINnon-reservednon-reservednon-reservedreserved
DOUBLEnon-reservedreservedreservedreserved
DROPnon-reservedreservedreservedreserved
DYNAMIC reservedreserved 
DYNAMIC_FUNCTION non-reservednon-reservednon-reserved
DYNAMIC_FUNCTION_CODE non-reservednon-reserved 
EACHnon-reservedreservedreserved 
ELEMENT reservedreserved 
ELSEreservedreservedreservedreserved
EMPTY non-reservednon-reserved 
ENABLEnon-reserved   
ENCODINGnon-reservednon-reservednon-reserved 
ENCRYPTEDnon-reserved   
ENDreservedreservedreservedreserved
END-EXEC reservedreservedreserved
END_FRAME reserved  
END_PARTITION reserved  
ENFORCED non-reserved  
ENUMnon-reserved   
EQUALS reservednon-reserved 
ESCAPEnon-reservedreservedreservedreserved
EVERY reservedreserved 
EXCEPTreservedreservedreservedreserved
EXCEPTION   reserved
EXCLUDEnon-reservednon-reservednon-reserved 
EXCLUDINGnon-reservednon-reservednon-reserved 
EXCLUSIVEnon-reserved   
EXEC reservedreservedreserved
EXECUTEnon-reservedreservedreservedreserved
EXISTSnon-reserved (cannot be function or type)reservedreservedreserved
EXP reservedreserved 
EXPLAINnon-reserved   
EXPRESSION non-reserved  
EXTENSIONnon-reserved   
EXTERNALnon-reservedreservedreservedreserved
EXTRACTnon-reserved (cannot be function or type)reservedreservedreserved
FALSEreservedreservedreservedreserved
FAMILYnon-reserved   
FETCHreservedreservedreservedreserved
FILE non-reservednon-reserved 
FILTER reservedreserved 
FINAL non-reservednon-reserved 
FIRSTnon-reservednon-reservednon-reservedreserved
FIRST_VALUE reservedreserved 
FLAG non-reservednon-reserved 
FLOATnon-reserved (cannot be function or type)reservedreservedreserved
FLOOR reservedreserved 
FOLLOWINGnon-reservednon-reservednon-reserved 
FORreservedreservedreservedreserved
FORCEnon-reserved   
FOREIGNreservedreservedreservedreserved
FORTRAN non-reservednon-reservednon-reserved
FORWARDnon-reserved   
FOUND non-reservednon-reservedreserved
FRAME_ROW reserved  
FREE reservedreserved 
FREEZEreserved (can be function or type)   
FROMreservedreservedreservedreserved
FS non-reservednon-reserved 
FULLreserved (can be function or type)reservedreservedreserved
FUNCTIONnon-reservedreservedreserved 
FUNCTIONSnon-reserved   
FUSION reservedreserved 
G non-reservednon-reserved 
GENERAL non-reservednon-reserved 
GENERATED non-reservednon-reserved 
GET reservedreservedreserved
GLOBALnon-reservedreservedreservedreserved
GO non-reservednon-reservedreserved
GOTO non-reservednon-reservedreserved
GRANTreservedreservedreservedreserved
GRANTEDnon-reservednon-reservednon-reserved 
GREATESTnon-reserved (cannot be function or type)   
GROUPreservedreservedreservedreserved
GROUPING reservedreserved 
GROUPS reserved  
HANDLERnon-reserved   
HAVINGreservedreservedreservedreserved
HEADERnon-reserved   
HEX non-reservednon-reserved 
HIERARCHY non-reservednon-reserved 
HOLDnon-reservedreservedreserved 
HOURnon-reservedreservedreservedreserved
ID non-reservednon-reserved 
IDENTITYnon-reservedreservedreservedreserved
IFnon-reserved   
IGNORE non-reservednon-reserved 
ILIKEreserved (can be function or type)   
IMMEDIATEnon-reservednon-reservednon-reservedreserved
IMMEDIATELY non-reserved  
IMMUTABLEnon-reserved   
IMPLEMENTATION non-reservednon-reserved 
IMPLICITnon-reserved   
IMPORT reservedreserved 
INreservedreservedreservedreserved
INCLUDINGnon-reservednon-reservednon-reserved 
INCREMENTnon-reservednon-reservednon-reserved 
INDENT non-reservednon-reserved 
INDEXnon-reserved   
INDEXESnon-reserved   
INDICATOR reservedreservedreserved
INHERITnon-reserved   
INHERITSnon-reserved   
INITIALLYreservednon-reservednon-reservedreserved
INLINEnon-reserved   
INNERreserved (can be function or type)reservedreservedreserved
INOUTnon-reserved (cannot be function or type)reservedreserved 
INPUTnon-reservednon-reservednon-reservedreserved
INSENSITIVEnon-reservedreservedreservedreserved
INSERTnon-reservedreservedreservedreserved
INSTANCE non-reservednon-reserved 
INSTANTIABLE non-reservednon-reserved 
INSTEADnon-reservednon-reservednon-reserved 
INTnon-reserved (cannot be function or type)reservedreservedreserved
INTEGERnon-reserved (cannot be function or type)reservedreservedreserved
INTEGRITY non-reservednon-reserved 
INTERSECTreservedreservedreservedreserved
INTERSECTION reservedreserved 
INTERVALnon-reserved (cannot be function or type)reservedreservedreserved
INTOreservedreservedreservedreserved
INVOKERnon-reservednon-reservednon-reserved 
ISreserved (can be function or type)reservedreservedreserved
ISNULLreserved (can be function or type)   
ISOLATIONnon-reservednon-reservednon-reservedreserved
JOINreserved (can be function or type)reservedreservedreserved
K non-reservednon-reserved 
KEYnon-reservednon-reservednon-reservedreserved
KEY_MEMBER non-reservednon-reserved 
KEY_TYPE non-reservednon-reserved 
LABELnon-reserved   
LAG reservedreserved 
LANGUAGEnon-reservedreservedreservedreserved
LARGEnon-reservedreservedreserved 
LASTnon-reservednon-reservednon-reservedreserved
LAST_VALUE reservedreserved 
LATERAL reservedreserved 
LC_COLLATEnon-reserved   
LC_CTYPEnon-reserved   
LEAD reservedreserved 
LEADINGreservedreservedreservedreserved
LEAKPROOFnon-reserved   
LEASTnon-reserved (cannot be function or type)   
LEFTreserved (can be function or type)reservedreservedreserved
LENGTH non-reservednon-reservednon-reserved
LEVELnon-reservednon-reservednon-reservedreserved
LIBRARY non-reservednon-reserved 
LIKEreserved (can be function or type)reservedreservedreserved
LIKE_REGEX reservedreserved 
LIMITreservednon-reservednon-reserved 
LINK non-reservednon-reserved 
LISTENnon-reserved   
LN reservedreserved 
LOADnon-reserved   
LOCALnon-reservedreservedreservedreserved
LOCALTIMEreservedreservedreserved 
LOCALTIMESTAMPreservedreservedreserved 
LOCATIONnon-reservednon-reservednon-reserved 
LOCATOR non-reservednon-reserved 
LOCKnon-reserved   
LOWER reservedreservedreserved
M non-reservednon-reserved 
MAP non-reservednon-reserved 
MAPPINGnon-reservednon-reservednon-reserved 
MATCHnon-reservedreservedreservedreserved
MATCHED non-reservednon-reserved 
MAX reservedreservedreserved
MAXVALUEnon-reservednon-reservednon-reserved 
MAX_CARDINALITY  reserved 
MEMBER reservedreserved 
MERGE reservedreserved 
MESSAGE_LENGTH non-reservednon-reservednon-reserved
MESSAGE_OCTET_LENGTH non-reservednon-reservednon-reserved
MESSAGE_TEXT non-reservednon-reservednon-reserved
METHOD reservedreserved 
MIN reservedreservedreserved
MINUTEnon-reservedreservedreservedreserved
MINVALUEnon-reservednon-reservednon-reserved 
MOD reservedreserved 
MODEnon-reserved   
MODIFIES reservedreserved 
MODULE reservedreservedreserved
MONTHnon-reservedreservedreservedreserved
MORE non-reservednon-reservednon-reserved
MOVEnon-reserved   
MULTISET reservedreserved 
MUMPS non-reservednon-reservednon-reserved
NAMEnon-reservednon-reservednon-reservednon-reserved
NAMESnon-reservednon-reservednon-reservedreserved
NAMESPACE non-reservednon-reserved 
NATIONALnon-reserved (cannot be function or type)reservedreservedreserved
NATURALreserved (can be function or type)reservedreservedreserved
NCHARnon-reserved (cannot be function or type)reservedreservedreserved
NCLOB reservedreserved 
NESTING non-reservednon-reserved 
NEW reservedreserved 
NEXTnon-reservednon-reservednon-reservedreserved
NFC non-reservednon-reserved 
NFD non-reservednon-reserved 
NFKC non-reservednon-reserved 
NFKD non-reservednon-reserved 
NIL non-reservednon-reserved 
NOnon-reservedreservedreservedreserved
NONEnon-reserved (cannot be function or type)reservedreserved 
NORMALIZE reservedreserved 
NORMALIZED non-reservednon-reserved 
NOTreservedreservedreservedreserved
NOTHINGnon-reserved   
NOTIFYnon-reserved   
NOTNULLreserved (can be function or type)   
NOWAITnon-reserved   
NTH_VALUE reservedreserved 
NTILE reservedreserved 
NULLreservedreservedreservedreserved
NULLABLE non-reservednon-reservednon-reserved
NULLIFnon-reserved (cannot be function or type)reservedreservedreserved
NULLSnon-reservednon-reservednon-reserved 
NUMBER non-reservednon-reservednon-reserved
NUMERICnon-reserved (cannot be function or type)reservedreservedreserved
OBJECTnon-reservednon-reservednon-reserved 
OCCURRENCES_REGEX reservedreserved 
OCTETS non-reservednon-reserved 
OCTET_LENGTH reservedreservedreserved
OFnon-reservedreservedreservedreserved
OFFnon-reservednon-reservednon-reserved 
OFFSETreservedreservedreserved 
OIDSnon-reserved   
OLD reservedreserved 
ONreservedreservedreservedreserved
ONLYreservedreservedreservedreserved
OPEN reservedreservedreserved
OPERATORnon-reserved   
OPTIONnon-reservednon-reservednon-reservedreserved
OPTIONSnon-reservednon-reservednon-reserved 
ORreservedreservedreservedreserved
ORDERreservedreservedreservedreserved
ORDERING non-reservednon-reserved 
ORDINALITY non-reservednon-reserved 
OTHERS non-reservednon-reserved 
OUTnon-reserved (cannot be function or type)reservedreserved 
OUTERreserved (can be function or type)reservedreservedreserved
OUTPUT non-reservednon-reservedreserved
OVERreserved (can be function or type)reservedreserved 
OVERLAPSreserved (can be function or type)reservedreservedreserved
OVERLAYnon-reserved (cannot be function or type)reservedreserved 
OVERRIDING non-reservednon-reserved 
OWNEDnon-reserved   
OWNERnon-reserved   
P non-reservednon-reserved 
PAD non-reservednon-reservedreserved
PARAMETER reservedreserved 
PARAMETER_MODE non-reservednon-reserved 
PARAMETER_NAME non-reservednon-reserved 
PARAMETER_ORDINAL_POSITION non-reservednon-reserved 
PARAMETER_SPECIFIC_CATALOG non-reservednon-reserved 
PARAMETER_SPECIFIC_NAME non-reservednon-reserved 
PARAMETER_SPECIFIC_SCHEMA non-reservednon-reserved 
PARSERnon-reserved   
PARTIALnon-reservednon-reservednon-reservedreserved
PARTITIONnon-reservedreservedreserved 
PASCAL non-reservednon-reservednon-reserved
PASSINGnon-reservednon-reservednon-reserved 
PASSTHROUGH non-reservednon-reserved 
PASSWORDnon-reserved   
PATH non-reservednon-reserved 
PERCENT reserved  
PERCENTILE_CONT reservedreserved 
PERCENTILE_DISC reservedreserved 
PERCENT_RANK reservedreserved 
PERIOD reserved  
PERMISSION non-reservednon-reserved 
PLACINGreservednon-reservednon-reserved 
PLANSnon-reserved   
PLI non-reservednon-reservednon-reserved
PORTION reserved  
POSITIONnon-reserved (cannot be function or type)reservedreservedreserved
POSITION_REGEX reservedreserved 
POWER reservedreserved 
PRECEDES reserved  
PRECEDINGnon-reservednon-reservednon-reserved 
PRECISIONnon-reserved (cannot be function or type)reservedreservedreserved
PREPAREnon-reservedreservedreservedreserved
PREPAREDnon-reserved   
PRESERVEnon-reservednon-reservednon-reservedreserved
PRIMARYreservedreservedreservedreserved
PRIORnon-reservednon-reservednon-reservedreserved
PRIVILEGESnon-reservednon-reservednon-reservedreserved
PROCEDURALnon-reserved   
PROCEDUREnon-reservedreservedreservedreserved
PUBLIC non-reservednon-reservedreserved
QUOTEnon-reserved   
RANGEnon-reservedreservedreserved 
RANK reservedreserved 
READnon-reservednon-reservednon-reservedreserved
READS reservedreserved 
REALnon-reserved (cannot be function or type)reservedreservedreserved
REASSIGNnon-reserved   
RECHECKnon-reserved   
RECOVERY non-reservednon-reserved 
RECURSIVEnon-reservedreservedreserved 
REFnon-reservedreservedreserved 
REFERENCESreservedreservedreservedreserved
REFERENCING reservedreserved 
REGR_AVGX reservedreserved 
REGR_AVGY reservedreserved 
REGR_COUNT reservedreserved 
REGR_INTERCEPT reservedreserved 
REGR_R2 reservedreserved 
REGR_SLOPE reservedreserved 
REGR_SXX reservedreserved 
REGR_SXY reservedreserved 
REGR_SYY reservedreserved 
REINDEXnon-reserved   
RELATIVEnon-reservednon-reservednon-reservedreserved
RELEASEnon-reservedreservedreserved 
RENAMEnon-reserved   
REPEATABLEnon-reservednon-reservednon-reservednon-reserved
REPLACEnon-reserved   
REPLICAnon-reserved   
REQUIRING non-reservednon-reserved 
RESETnon-reserved   
RESPECT non-reservednon-reserved 
RESTARTnon-reservednon-reservednon-reserved 
RESTORE non-reservednon-reserved 
RESTRICTnon-reservednon-reservednon-reservedreserved
RESULT reservedreserved 
RETURN reservedreserved 
RETURNED_CARDINALITY non-reservednon-reserved 
RETURNED_LENGTH non-reservednon-reservednon-reserved
RETURNED_OCTET_LENGTH non-reservednon-reservednon-reserved
RETURNED_SQLSTATE non-reservednon-reservednon-reserved
RETURNINGreservednon-reservednon-reserved 
RETURNSnon-reservedreservedreserved 
REVOKEnon-reservedreservedreservedreserved
RIGHTreserved (can be function or type)reservedreservedreserved
ROLEnon-reservednon-reservednon-reserved 
ROLLBACKnon-reservedreservedreservedreserved
ROLLUP reservedreserved 
ROUTINE non-reservednon-reserved 
ROUTINE_CATALOG non-reservednon-reserved 
ROUTINE_NAME non-reservednon-reserved 
ROUTINE_SCHEMA non-reservednon-reserved 
ROWnon-reserved (cannot be function or type)reservedreserved 
ROWSnon-reservedreservedreservedreserved
ROW_COUNT non-reservednon-reservednon-reserved
ROW_NUMBER reservedreserved 
RULEnon-reserved   
SAVEPOINTnon-reservedreservedreserved 
SCALE non-reservednon-reservednon-reserved
SCHEMAnon-reservednon-reservednon-reservedreserved
SCHEMA_NAME non-reservednon-reservednon-reserved
SCOPE reservedreserved 
SCOPE_CATALOG non-reservednon-reserved 
SCOPE_NAME non-reservednon-reserved 
SCOPE_SCHEMA non-reservednon-reserved 
SCROLLnon-reservedreservedreservedreserved
SEARCHnon-reservedreservedreserved 
SECONDnon-reservedreservedreservedreserved
SECTION non-reservednon-reservedreserved
SECURITYnon-reservednon-reservednon-reserved 
SELECTreservedreservedreservedreserved
SELECTIVE non-reservednon-reserved 
SELF non-reservednon-reserved 
SENSITIVE reservedreserved 
SEQUENCEnon-reservednon-reservednon-reserved 
SEQUENCESnon-reserved   
SERIALIZABLEnon-reservednon-reservednon-reservednon-reserved
SERVERnon-reservednon-reservednon-reserved 
SERVER_NAME non-reservednon-reservednon-reserved
SESSIONnon-reservednon-reservednon-reservedreserved
SESSION_USERreservedreservedreservedreserved
SETnon-reservedreservedreservedreserved
SETOFnon-reserved (cannot be function or type)   
SETS non-reservednon-reserved 
SHAREnon-reserved   
SHOWnon-reserved   
SIMILARreserved (can be function or type)reservedreserved 
SIMPLEnon-reservednon-reservednon-reserved 
SIZE non-reservednon-reservedreserved
SMALLINTnon-reserved (cannot be function or type)reservedreservedreserved
SNAPSHOTnon-reserved   
SOMEreservedreservedreservedreserved
SOURCE non-reservednon-reserved 
SPACE non-reservednon-reservedreserved
SPECIFIC reservedreserved 
SPECIFICTYPE reservedreserved 
SPECIFIC_NAME non-reservednon-reserved 
SQL reservedreservedreserved
SQLCODE   reserved
SQLERROR   reserved
SQLEXCEPTION reservedreserved 
SQLSTATE reservedreservedreserved
SQLWARNING reservedreserved 
SQRT reservedreserved 
STABLEnon-reserved   
STANDALONEnon-reservednon-reservednon-reserved 
STARTnon-reservedreservedreserved 
STATE non-reservednon-reserved 
STATEMENTnon-reservednon-reservednon-reserved 
STATIC reservedreserved 
STATISTICSnon-reserved   
STDDEV_POP reservedreserved 
STDDEV_SAMP reservedreserved 
STDINnon-reserved   
STDOUTnon-reserved   
STORAGEnon-reserved   
STRICTnon-reserved   
STRIPnon-reservednon-reservednon-reserved 
STRUCTURE non-reservednon-reserved 
STYLE non-reservednon-reserved 
SUBCLASS_ORIGIN non-reservednon-reservednon-reserved
SUBMULTISET reservedreserved 
SUBSTRINGnon-reserved (cannot be function or type)reservedreservedreserved
SUBSTRING_REGEX reservedreserved 
SUCCEEDS reserved  
SUM reservedreservedreserved
SYMMETRICreservedreservedreserved 
SYSIDnon-reserved   
SYSTEMnon-reservedreservedreserved 
SYSTEM_TIME reserved  
SYSTEM_USER reservedreservedreserved
T non-reservednon-reserved 
TABLEreservedreservedreservedreserved
TABLESnon-reserved   
TABLESAMPLE reservedreserved 
TABLESPACEnon-reserved   
TABLE_NAME non-reservednon-reservednon-reserved
TEMPnon-reserved   
TEMPLATEnon-reserved   
TEMPORARYnon-reservednon-reservednon-reservedreserved
TEXTnon-reserved   
THENreservedreservedreservedreserved
TIES non-reservednon-reserved 
TIMEnon-reserved (cannot be function or type)reservedreservedreserved
TIMESTAMPnon-reserved (cannot be function or type)reservedreservedreserved
TIMEZONE_HOUR reservedreservedreserved
TIMEZONE_MINUTE reservedreservedreserved
TOreservedreservedreservedreserved
TOKEN non-reservednon-reserved 
TOP_LEVEL_COUNT non-reservednon-reserved 
TRAILINGreservedreservedreservedreserved
TRANSACTIONnon-reservednon-reservednon-reservedreserved
TRANSACTIONS_COMMITTED non-reservednon-reserved 
TRANSACTIONS_ROLLED_BACK non-reservednon-reserved 
TRANSACTION_ACTIVE non-reservednon-reserved 
TRANSFORM non-reservednon-reserved 
TRANSFORMS non-reservednon-reserved 
TRANSLATE reservedreservedreserved
TRANSLATE_REGEX reservedreserved 
TRANSLATION reservedreservedreserved
TREATnon-reserved (cannot be function or type)reservedreserved 
TRIGGERnon-reservedreservedreserved 
TRIGGER_CATALOG non-reservednon-reserved 
TRIGGER_NAME non-reservednon-reserved 
TRIGGER_SCHEMA non-reservednon-reserved 
TRIMnon-reserved (cannot be function or type)reservedreservedreserved
TRIM_ARRAY reservedreserved 
TRUEreservedreservedreservedreserved
TRUNCATEnon-reservedreservedreserved 
TRUSTEDnon-reserved   
TYPEnon-reservednon-reservednon-reservednon-reserved
TYPESnon-reserved   
UESCAPE reservedreserved 
UNBOUNDEDnon-reservednon-reservednon-reserved 
UNCOMMITTEDnon-reservednon-reservednon-reservednon-reserved
UNDER non-reservednon-reserved 
UNENCRYPTEDnon-reserved   
UNIONreservedreservedreservedreserved
UNIQUEreservedreservedreservedreserved
UNKNOWNnon-reservedreservedreservedreserved
UNLINK non-reservednon-reserved 
UNLISTENnon-reserved   
UNLOGGEDnon-reserved   
UNNAMED non-reservednon-reservednon-reserved
UNNEST reservedreserved 
UNTILnon-reserved   
UNTYPED non-reservednon-reserved 
UPDATEnon-reservedreservedreservedreserved
UPPER reservedreservedreserved
URI non-reservednon-reserved 
USAGE non-reservednon-reservedreserved
USERreservedreservedreservedreserved
USER_DEFINED_TYPE_CATALOG non-reservednon-reserved 
USER_DEFINED_TYPE_CODE non-reservednon-reserved 
USER_DEFINED_TYPE_NAME non-reservednon-reserved 
USER_DEFINED_TYPE_SCHEMA non-reservednon-reserved 
USINGreservedreservedreservedreserved
VACUUMnon-reserved   
VALIDnon-reservednon-reservednon-reserved 
VALIDATEnon-reserved   
VALIDATORnon-reserved   
VALUEnon-reservedreservedreservedreserved
VALUESnon-reserved (cannot be function or type)reservedreservedreserved
VALUE_OF reserved  
VARBINARY reservedreserved 
VARCHARnon-reserved (cannot be function or type)reservedreservedreserved
VARIADICreserved   
VARYINGnon-reservedreservedreservedreserved
VAR_POP reservedreserved 
VAR_SAMP reservedreserved 
VERBOSEreserved (can be function or type)   
VERSIONnon-reservednon-reservednon-reserved 
VERSIONING reserved  
VIEWnon-reservednon-reservednon-reservedreserved
VOLATILEnon-reserved   
WHENreservedreservedreservedreserved
WHENEVER reservedreservedreserved
WHEREreservedreservedreservedreserved
WHITESPACEnon-reservednon-reservednon-reserved 
WIDTH_BUCKET reservedreserved 
WINDOWreservedreservedreserved 
WITHreservedreservedreservedreserved
WITHIN reservedreserved 
WITHOUTnon-reservedreservedreserved 
WORKnon-reservednon-reservednon-reservedreserved
WRAPPERnon-reservednon-reservednon-reserved 
WRITEnon-reservednon-reservednon-reservedreserved
XMLnon-reservedreservedreserved 
XMLAGG reservedreserved 
XMLATTRIBUTESnon-reserved (cannot be function or type)reservedreserved 
XMLBINARY reservedreserved 
XMLCAST reservedreserved 
XMLCOMMENT reservedreserved 
XMLCONCATnon-reserved (cannot be function or type)reservedreserved 
XMLDECLARATION non-reservednon-reserved 
XMLDOCUMENT reservedreserved 
XMLELEMENTnon-reserved (cannot be function or type)reservedreserved 
XMLEXISTSnon-reserved (cannot be function or type)reservedreserved 
XMLFORESTnon-reserved (cannot be function or type)reservedreserved 
XMLITERATE reservedreserved 
XMLNAMESPACES reservedreserved 
XMLPARSEnon-reserved (cannot be function or type)reservedreserved 
XMLPInon-reserved (cannot be function or type)reservedreserved 
XMLQUERY reservedreserved 
XMLROOTnon-reserved (cannot be function or type)   
XMLSCHEMA non-reservednon-reserved 
XMLSERIALIZEnon-reserved (cannot be function or type)reservedreserved 
XMLTABLE reservedreserved 
XMLTEXT reservedreserved 
XMLVALIDATE reservedreserved 
YEARnon-reservedreservedreservedreserved
YESnon-reservednon-reservednon-reserved 
ZONEnon-reservednon-reservednon-reservedreserved

PrevHomeNext
History of UnitsUpSQL Conformance
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-listen.html b/doc/src/sgml/html/sql-listen.html new file mode 100644 index 000000000..1e7df7899 --- /dev/null +++ b/doc/src/sgml/html/sql-listen.html @@ -0,0 +1,386 @@ + +LISTEN

LISTEN

Name

LISTEN -- listen for a notification

Synopsis

LISTEN channel

Description

LISTEN registers the current session as a + listener on the notification channel named channel. + If the current session is already registered as a listener for + this notification channel, nothing is done. +

Whenever the command NOTIFY channel is invoked, either + by this session or another one connected to the same database, all + the sessions currently listening on that notification channel are + notified, and each will in turn notify its connected client + application. +

A session can be unregistered for a given notification channel with the + UNLISTEN command. A session's listen + registrations are automatically cleared when the session ends. +

The method a client application must use to detect notification events depends on + which PostgreSQL application programming interface it + uses. With the libpq library, the application issues + LISTEN as an ordinary SQL command, and then must + periodically call the function PQnotifies to find out + whether any notification events have been received. Other interfaces such as + libpgtcl provide higher-level methods for handling notify events; indeed, + with libpgtcl the application programmer should not even issue + LISTEN or UNLISTEN directly. See the + documentation for the interface you are using for more details. +

NOTIFY + contains a more extensive + discussion of the use of LISTEN and + NOTIFY. +

Parameters

channel

Name of a notification channel (any identifier). +

Notes

LISTEN takes effect at transaction commit. + If LISTEN or UNLISTEN is executed + within a transaction that later rolls back, the set of notification + channels being listened to is unchanged. +

A transaction that has executed LISTEN cannot be + prepared for two-phase commit. +

Examples

Configure and execute a listen/notify sequence from + psql: + +

LISTEN virtual;
+NOTIFY virtual;
+Asynchronous notification "virtual" received from server process with PID 8448.

Compatibility

There is no LISTEN statement in the SQL + standard. +

See Also

NOTIFY, UNLISTEN

PrevHomeNext
INSERTUpLOAD
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-load.html b/doc/src/sgml/html/sql-load.html new file mode 100644 index 000000000..df29dd3dc --- /dev/null +++ b/doc/src/sgml/html/sql-load.html @@ -0,0 +1,276 @@ + +LOAD

LOAD

Name

LOAD -- load a shared library file

Synopsis

LOAD 'filename'

Description

This command loads a shared library file into the PostgreSQL + server's address space. If the file has been loaded already, + the command does nothing. Shared library files that contain C functions + are automatically loaded whenever one of their functions is called. + Therefore, an explicit LOAD is usually only needed to + load a library that modifies the server's behavior through "hooks" + rather than providing a set of functions. +

The file name is specified in the same way as for shared library + names in CREATE FUNCTION; in particular, one + can rely on a search path and automatic addition of the system's standard + shared library file name extension. See Section 35.9 for + more information on this topic. +

Non-superusers can only apply LOAD to library files + located in $libdir/plugins/ — the specified + filename must begin + with exactly that string. (It is the database administrator's + responsibility to ensure that only "safe" libraries + are installed there.) +

Compatibility

LOAD is a PostgreSQL + extension. +

See Also

CREATE FUNCTION +


PrevHomeNext
LISTENUpLOCK
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-lock.html b/doc/src/sgml/html/sql-lock.html new file mode 100644 index 000000000..b3cdffe4e --- /dev/null +++ b/doc/src/sgml/html/sql-lock.html @@ -0,0 +1,650 @@ + +LOCK

LOCK

Name

LOCK -- lock a table

Synopsis

LOCK [ TABLE ] [ ONLY ] name [ * ] [, ...] [ IN lockmode MODE ] [ NOWAIT ]
+
+where lockmode is one of:
+
+    ACCESS SHARE | ROW SHARE | ROW EXCLUSIVE | SHARE UPDATE EXCLUSIVE
+    | SHARE | SHARE ROW EXCLUSIVE | EXCLUSIVE | ACCESS EXCLUSIVE

Description

LOCK TABLE obtains a table-level lock, waiting + if necessary for any conflicting locks to be released. If + NOWAIT is specified, LOCK + TABLE does not wait to acquire the desired lock: if it + cannot be acquired immediately, the command is aborted and an + error is emitted. Once obtained, the lock is held for the + remainder of the current transaction. (There is no UNLOCK + TABLE command; locks are always released at transaction + end.) +

When acquiring locks automatically for commands that reference + tables, PostgreSQL always uses the least + restrictive lock mode possible. LOCK TABLE + provides for cases when you might need more restrictive locking. + For example, suppose an application runs a transaction at the + Read Committed isolation level and needs to ensure that data in a + table remains stable for the duration of the transaction. To + achieve this you could obtain SHARE lock mode over the + table before querying. This will prevent concurrent data changes + and ensure subsequent reads of the table see a stable view of + committed data, because SHARE lock mode conflicts with + the ROW EXCLUSIVE lock acquired by writers, and your + LOCK TABLE name IN SHARE MODE + statement will wait until any concurrent holders of ROW + EXCLUSIVE mode locks commit or roll back. Thus, once you + obtain the lock, there are no uncommitted writes outstanding; + furthermore none can begin until you release the lock. +

To achieve a similar effect when running a transaction at the + REPEATABLE READ or SERIALIZABLE + isolation level, you have to execute the LOCK TABLE statement + before executing any SELECT or data modification statement. + A REPEATABLE READ or SERIALIZABLE transaction's + view of data will be frozen when its first + SELECT or data modification statement begins. A LOCK + TABLE later in the transaction will still prevent concurrent writes + — but it won't ensure that what the transaction reads corresponds to + the latest committed values. +

If a transaction of this sort is going to change the data in the + table, then it should use SHARE ROW EXCLUSIVE lock mode + instead of SHARE mode. This ensures that only one + transaction of this type runs at a time. Without this, a deadlock + is possible: two transactions might both acquire SHARE + mode, and then be unable to also acquire ROW EXCLUSIVE + mode to actually perform their updates. (Note that a transaction's + own locks never conflict, so a transaction can acquire ROW + EXCLUSIVE mode when it holds SHARE mode — but not + if anyone else holds SHARE mode.) To avoid deadlocks, + make sure all transactions acquire locks on the same objects in the + same order, and if multiple lock modes are involved for a single + object, then transactions should always acquire the most + restrictive mode first. +

More information about the lock modes and locking strategies can be + found in Section 13.3. +

Parameters

name

The name (optionally schema-qualified) of an existing table to + lock. If ONLY is specified before the table name, only that + table is locked. If ONLY is not specified, the table and all + its descendant tables (if any) are locked. Optionally, * + can be specified after the table name to explicitly indicate that + descendant tables are included. +

The command LOCK TABLE a, b; is equivalent to + LOCK TABLE a; LOCK TABLE b;. The tables are locked + one-by-one in the order specified in the LOCK + TABLE command. +

lockmode

The lock mode specifies which locks this lock conflicts with. + Lock modes are described in Section 13.3. +

If no lock mode is specified, then ACCESS + EXCLUSIVE, the most restrictive mode, is used. +

NOWAIT

Specifies that LOCK TABLE should not wait for + any conflicting locks to be released: if the specified lock(s) + cannot be acquired immediately without waiting, the transaction + is aborted. +

Notes

LOCK TABLE ... IN ACCESS SHARE MODE requires SELECT + privileges on the target table. All other forms of LOCK + require table-level UPDATE, DELETE, or + TRUNCATE privileges. +

LOCK TABLE is useless outside a transaction block: the lock + would remain held only to the completion of the statement. Therefore + PostgreSQL reports an error if LOCK + is used outside a transaction block. + Use + BEGIN and + COMMIT + (or ROLLBACK) + to define a transaction block. +

LOCK TABLE only deals with table-level locks, and so + the mode names involving ROW are all misnomers. These + mode names should generally be read as indicating the intention of + the user to acquire row-level locks within the locked table. Also, + ROW EXCLUSIVE mode is a sharable table lock. Keep in + mind that all the lock modes have identical semantics so far as + LOCK TABLE is concerned, differing only in the rules + about which modes conflict with which. For information on how to + acquire an actual row-level lock, see Section 13.3.2 + and the FOR UPDATE/FOR SHARE Clause in the SELECT + reference documentation. +

Examples

Obtain a SHARE lock on a primary key table when going to perform + inserts into a foreign key table: + +

BEGIN WORK;
+LOCK TABLE films IN SHARE MODE;
+SELECT id FROM films
+    WHERE name = 'Star Wars: Episode I - The Phantom Menace';
+-- Do ROLLBACK if record was not returned
+INSERT INTO films_user_comments VALUES
+    (_id_, 'GREAT! I was waiting for it for so long!');
+COMMIT WORK;

+

Take a SHARE ROW EXCLUSIVE lock on a primary key table when going to perform + a delete operation: + +

BEGIN WORK;
+LOCK TABLE films IN SHARE ROW EXCLUSIVE MODE;
+DELETE FROM films_user_comments WHERE id IN
+    (SELECT id FROM films WHERE rating < 5);
+DELETE FROM films WHERE rating < 5;
+COMMIT WORK;

Compatibility

There is no LOCK TABLE in the SQL standard, + which instead uses SET TRANSACTION to specify + concurrency levels on transactions. PostgreSQL supports that too; + see SET TRANSACTION for details. +

Except for ACCESS SHARE, ACCESS EXCLUSIVE, + and SHARE UPDATE EXCLUSIVE lock modes, the + PostgreSQL lock modes and the + LOCK TABLE syntax are compatible with those + present in Oracle. +

\ No newline at end of file diff --git a/doc/src/sgml/html/sql-move.html b/doc/src/sgml/html/sql-move.html new file mode 100644 index 000000000..48b961605 --- /dev/null +++ b/doc/src/sgml/html/sql-move.html @@ -0,0 +1,371 @@ + +MOVE

MOVE

Name

MOVE -- position a cursor

Synopsis

MOVE [ direction [ FROM | IN ] ] cursor_name
+
+where direction can be empty or one of:
+
+    NEXT
+    PRIOR
+    FIRST
+    LAST
+    ABSOLUTE count
+    RELATIVE count
+    count
+    ALL
+    FORWARD
+    FORWARD count
+    FORWARD ALL
+    BACKWARD
+    BACKWARD count
+    BACKWARD ALL

Description

MOVE repositions a cursor without retrieving any data. + MOVE works exactly like the FETCH + command, except it only positions the cursor and does not return rows. +

The parameters for the MOVE command are identical to + those of the FETCH command; refer to + FETCH + for details on syntax and usage. +

Outputs

On successful completion, a MOVE command returns a command + tag of the form +

MOVE count

+ The count is the number + of rows that a FETCH command with the same parameters + would have returned (possibly zero). +

Examples

BEGIN WORK;
+DECLARE liahona CURSOR FOR SELECT * FROM films;
+
+-- Skip the first 5 rows:
+MOVE FORWARD 5 IN liahona;
+MOVE 5
+
+-- Fetch the 6th row from the cursor liahona:
+FETCH 1 FROM liahona;
+ code  | title  | did | date_prod  |  kind  |  len
+-------+--------+-----+------------+--------+-------
+ P_303 | 48 Hrs | 103 | 1982-10-22 | Action | 01:37
+(1 row)
+
+-- Close the cursor liahona and end the transaction:
+CLOSE liahona;
+COMMIT WORK;

Compatibility

There is no MOVE statement in the SQL standard. +

See Also

CLOSE, DECLARE, FETCH

PrevHomeNext
LOCKUpNOTIFY
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-notify.html b/doc/src/sgml/html/sql-notify.html new file mode 100644 index 000000000..00e7c46b2 --- /dev/null +++ b/doc/src/sgml/html/sql-notify.html @@ -0,0 +1,515 @@ + +NOTIFY

NOTIFY

Name

NOTIFY -- generate a notification

Synopsis

NOTIFY channel [ , payload ]

Description

The NOTIFY command sends a notification event together + with an optional "payload" string to each client application that + has previously executed + LISTEN channel + for the specified channel name in the current database. +

NOTIFY provides a simple + interprocess communication mechanism for a collection of processes + accessing the same PostgreSQL database. + A payload string can be sent along with the notification, and + higher-level mechanisms for passing structured data can be built by using + tables in the database to pass additional data from notifier to listener(s). +

The information passed to the client for a notification event includes the + notification channel + name, the notifying session's server process PID, and the + payload string, which is an empty string if it has not been specified. +

It is up to the database designer to define the channel names that will + be used in a given database and what each one means. + Commonly, the channel name is the same as the name of some table in + the database, and the notify event essentially means, "I changed this table, + take a look at it to see what's new". But no such association is enforced by + the NOTIFY and LISTEN commands. For + example, a database designer could use several different channel names + to signal different sorts of changes to a single table. Alternatively, + the payload string could be used to differentiate various cases. +

When NOTIFY is used to signal the occurrence of changes + to a particular table, a useful programming technique is to put the + NOTIFY in a rule that is triggered by table updates. + In this way, notification happens automatically when the table is changed, + and the application programmer cannot accidentally forget to do it. +

NOTIFY interacts with SQL transactions in some important + ways. Firstly, if a NOTIFY is executed inside a + transaction, the notify events are not delivered until and unless the + transaction is committed. This is appropriate, since if the transaction + is aborted, all the commands within it have had no + effect, including NOTIFY. But it can be disconcerting if one + is expecting the notification events to be delivered immediately. Secondly, if + a listening session receives a notification signal while it is within a transaction, + the notification event will not be delivered to its connected client until just + after the transaction is completed (either committed or aborted). Again, the + reasoning is that if a notification were delivered within a transaction that was + later aborted, one would want the notification to be undone somehow — + but + the server cannot "take back" a notification once it has sent it to the client. + So notification events are only delivered between transactions. The upshot of this + is that applications using NOTIFY for real-time signaling + should try to keep their transactions short. +

If the same channel name is signaled multiple times from the same + transaction with identical payload strings, the + database server can decide to deliver a single notification only. + On the other hand, notifications with distinct payload strings will + always be delivered as distinct notifications. Similarly, notifications from + different transactions will never get folded into one notification. + Except for dropping later instances of duplicate notifications, + NOTIFY guarantees that notifications from the same + transaction get delivered in the order they were sent. It is also + guaranteed that messages from different transactions are delivered in + the order in which the transactions committed. +

It is common for a client that executes NOTIFY + to be listening on the same notification channel itself. In that case + it will get back a notification event, just like all the other + listening sessions. Depending on the application logic, this could + result in useless work, for example, reading a database table to + find the same updates that that session just wrote out. It is + possible to avoid such extra work by noticing whether the notifying + session's server process PID (supplied in the + notification event message) is the same as one's own session's + PID (available from libpq). When they + are the same, the notification event is one's own work bouncing + back, and can be ignored. +

Parameters

channel

Name of the notification channel to be signaled (any identifier). +

payload

The "payload" string to be communicated along with the + notification. This must be specified as a simple string literal. + In the default configuration it must be shorter than 8000 bytes. + (If binary data or large amounts of information need to be communicated, + it's best to put it in a database table and send the key of the record.) +

Notes

There is a queue that holds notifications that have been sent but not + yet processed by all listening sessions. If this queue becomes full, + transactions calling NOTIFY will fail at commit. + The queue is quite large (8GB in a standard installation) and should be + sufficiently sized for almost every use case. However, no cleanup can take + place if a session executes LISTEN and then enters a + transaction for a very long time. Once the queue is half full you will see + warnings in the log file pointing you to the session that is preventing + cleanup. In this case you should make sure that this session ends its + current transaction so that cleanup can proceed. +

A transaction that has executed NOTIFY cannot be + prepared for two-phase commit. +

pg_notify

To send a notification you can also use the function + pg_notify(text, + text). The function takes the channel name as the + first argument and the payload as the second. The function is much easier + to use than the NOTIFY command if you need to work with + non-constant channel names and payloads. +

Examples

Configure and execute a listen/notify sequence from + psql: + +

LISTEN virtual;
+NOTIFY virtual;
+Asynchronous notification "virtual" received from server process with PID 8448.
+NOTIFY virtual, 'This is the payload';
+Asynchronous notification "virtual" with payload "This is the payload" received from server process with PID 8448.
+
+LISTEN foo;
+SELECT pg_notify('fo' || 'o', 'pay' || 'load');
+Asynchronous notification "foo" with payload "payload" received from server process with PID 14728.

Compatibility

There is no NOTIFY statement in the SQL + standard. +

See Also

LISTEN, UNLISTEN

PrevHomeNext
MOVEUpPREPARE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-prepare-transaction.html b/doc/src/sgml/html/sql-prepare-transaction.html new file mode 100644 index 000000000..d50ea9a0e --- /dev/null +++ b/doc/src/sgml/html/sql-prepare-transaction.html @@ -0,0 +1,471 @@ + +PREPARE TRANSACTION

PREPARE TRANSACTION

Name

PREPARE TRANSACTION -- prepare the current transaction for two-phase commit

Synopsis

PREPARE TRANSACTION transaction_id

Description

PREPARE TRANSACTION prepares the current transaction + for two-phase commit. After this command, the transaction is no longer + associated with the current session; instead, its state is fully stored on + disk, and there is a very high probability that it can be committed + successfully, even if a database crash occurs before the commit is + requested. +

Once prepared, a transaction can later be committed or rolled back + with COMMIT PREPARED + or ROLLBACK PREPARED, + respectively. Those commands can be issued from any session, not + only the one that executed the original transaction. +

From the point of view of the issuing session, PREPARE + TRANSACTION is not unlike a ROLLBACK command: + after executing it, there is no active current transaction, and the + effects of the prepared transaction are no longer visible. (The effects + will become visible again if the transaction is committed.) +

If the PREPARE TRANSACTION command fails for any + reason, it becomes a ROLLBACK: the current transaction + is canceled. +

Parameters

transaction_id

An arbitrary identifier that later identifies this transaction for + COMMIT PREPARED or ROLLBACK PREPARED. + The identifier must be written as a string literal, and must be + less than 200 bytes long. It must not be the same as the identifier + used for any currently prepared transaction. +

Notes

PREPARE TRANSACTION is not intended for use in applications + or interactive sessions. Its purpose is to allow an external + transaction manager to perform atomic global transactions across multiple + databases or other transactional resources. Unless you're writing a + transaction manager, you probably shouldn't be using PREPARE + TRANSACTION. +

This command must be used inside a transaction block. Use BEGIN to start one. +

It is not currently allowed to PREPARE a transaction that + has executed any operations involving temporary tables, + created any cursors WITH HOLD, or executed + LISTEN or UNLISTEN. + Those features are too tightly + tied to the current session to be useful in a transaction to be prepared. +

If the transaction modified any run-time parameters with SET + (without the LOCAL option), + those effects persist after PREPARE TRANSACTION, and will not + be affected by any later COMMIT PREPARED or + ROLLBACK PREPARED. Thus, in this one respect + PREPARE TRANSACTION acts more like COMMIT than + ROLLBACK. +

All currently available prepared transactions are listed in the + pg_prepared_xacts + system view. +

Caution

It is unwise to leave transactions in the prepared state for a long time. + This will interfere with the ability of VACUUM to reclaim + storage, and in extreme cases could cause the database to shut down + to prevent transaction ID wraparound (see Section 23.1.5). Keep in mind also that the transaction + continues to hold whatever locks it held. The intended usage of the + feature is that a prepared transaction will normally be committed or + rolled back as soon as an external transaction manager has verified that + other databases are also prepared to commit. +

If you have not set up an external transaction manager to track prepared + transactions and ensure they get closed out promptly, it is best to keep + the prepared-transaction feature disabled by setting + max_prepared_transactions to zero. This will + prevent accidental creation of prepared transactions that might then + be forgotten and eventually cause problems. +

Examples

Prepare the current transaction for two-phase commit, using + foobar as the transaction identifier: + +

PREPARE TRANSACTION 'foobar';

Compatibility

PREPARE TRANSACTION is a + PostgreSQL extension. It is intended for use by + external transaction management systems, some of which are covered by + standards (such as X/Open XA), but the SQL side of those systems is not + standardized. +


PrevHomeNext
PREPAREUpREASSIGN OWNED
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-prepare.html b/doc/src/sgml/html/sql-prepare.html new file mode 100644 index 000000000..8e7b14beb --- /dev/null +++ b/doc/src/sgml/html/sql-prepare.html @@ -0,0 +1,491 @@ + +PREPARE

PREPARE

Name

PREPARE -- prepare a statement for execution

Synopsis

PREPARE name [ ( data_type [, ...] ) ] AS statement

Description

PREPARE creates a prepared statement. A prepared + statement is a server-side object that can be used to optimize + performance. When the PREPARE statement is + executed, the specified statement is parsed, analyzed, and rewritten. + When an EXECUTE command is subsequently + issued, the prepared statement is planned and executed. This division + of labor avoids repetitive parse analysis work, while allowing + the execution plan to depend on the specific parameter values supplied. +

Prepared statements can take parameters: values that are + substituted into the statement when it is executed. When creating + the prepared statement, refer to parameters by position, using + $1, $2, etc. A corresponding list of + parameter data types can optionally be specified. When a + parameter's data type is not specified or is declared as + unknown, the type is inferred from the context + in which the parameter is used (if possible). When executing the + statement, specify the actual values for these parameters in the + EXECUTE statement. Refer to EXECUTE for more + information about that. +

Prepared statements only last for the duration of the current + database session. When the session ends, the prepared statement is + forgotten, so it must be recreated before being used again. This + also means that a single prepared statement cannot be used by + multiple simultaneous database clients; however, each client can create + their own prepared statement to use. Prepared statements can be + manually cleaned up using the DEALLOCATE command. +

Prepared statements have the largest performance advantage when a + single session is being used to execute a large number of similar + statements. The performance difference will be particularly + significant if the statements are complex to plan or rewrite, for + example, if the query involves a join of many tables or requires + the application of several rules. If the statement is relatively simple + to plan and rewrite but relatively expensive to execute, the + performance advantage of prepared statements will be less noticeable. +

Parameters

name

An arbitrary name given to this particular prepared + statement. It must be unique within a single session and is + subsequently used to execute or deallocate a previously prepared + statement. +

data_type

The data type of a parameter to the prepared statement. If the + data type of a particular parameter is unspecified or is + specified as unknown, it will be inferred + from the context in which the parameter is used. To refer to the + parameters in the prepared statement itself, use + $1, $2, etc. +

statement

Any SELECT, INSERT, UPDATE, + DELETE, or VALUES statement. +

Notes

If a prepared statement is executed enough times, the server may eventually + decide to save and re-use a generic plan rather than re-planning each time. + This will occur immediately if the prepared statement has no parameters; + otherwise it occurs only if the generic plan appears to be not much more + expensive than a plan that depends on specific parameter values. + Typically, a generic plan will be selected only if the query's performance + is estimated to be fairly insensitive to the specific parameter values + supplied. +

To examine the query plan PostgreSQL is using + for a prepared statement, use EXPLAIN. + If a generic plan is in use, it will contain parameter symbols + $n, while a custom plan will have the + current actual parameter values substituted into it. +

For more information on query planning and the statistics collected + by PostgreSQL for that purpose, see + the ANALYZE + documentation. +

You can see all prepared statements available in the session by querying the + pg_prepared_statements + system view. +

Examples

Create a prepared statement for an INSERT + statement, and then execute it: +

PREPARE fooplan (int, text, bool, numeric) AS
+    INSERT INTO foo VALUES($1, $2, $3, $4);
+EXECUTE fooplan(1, 'Hunter Valley', 't', 200.00);

+

Create a prepared statement for a SELECT + statement, and then execute it: +

PREPARE usrrptplan (int) AS
+    SELECT * FROM users u, logs l WHERE u.usrid=$1 AND u.usrid=l.usrid
+    AND l.date = $2;
+EXECUTE usrrptplan(1, current_date);

+ + Note that the data type of the second parameter is not specified, + so it is inferred from the context in which $2 is used. +

Compatibility

The SQL standard includes a PREPARE statement, + but it is only for use in embedded SQL. This version of the + PREPARE statement also uses a somewhat different + syntax. +


PrevHomeNext
NOTIFYUpPREPARE TRANSACTION
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-reassign-owned.html b/doc/src/sgml/html/sql-reassign-owned.html new file mode 100644 index 000000000..be04f4d56 --- /dev/null +++ b/doc/src/sgml/html/sql-reassign-owned.html @@ -0,0 +1,349 @@ + +REASSIGN OWNED

REASSIGN OWNED

Name

REASSIGN OWNED -- change the ownership of database objects owned by a database role

Synopsis

REASSIGN OWNED BY old_role [, ...] TO new_role

Description

REASSIGN OWNED instructs the system to change + the ownership of the database objects owned by one of the + old_roles, to new_role. +

Parameters

old_role

The name of a role. The ownership of all the objects in the + current database owned by this role will be reassigned to + new_role. +

new_role

The name of the role that will be made the new owner of the + affected objects. +

Notes

REASSIGN OWNED is often used to prepare for the + removal of one or more roles. Because REASSIGN + OWNED only affects the objects in the current database, + it is usually necessary to execute this command in each database + that contains objects owned by a role that is to be removed. +

REASSIGN OWNED requires privileges on both the + source role(s) and the target role. +

The DROP OWNED command is an alternative that + drops all the database objects owned by one or more roles. Note + also that DROP OWNED requires privileges only + on the source role(s). +

The REASSIGN OWNED command does not affect the + privileges granted to the old_roles in objects that are not owned + by them. Use DROP OWNED to revoke those + privileges. +

The REASSIGN OWNED command does not affect the + ownership of any databases owned by the role. Use + ALTER DATABASE to reassign that ownership. +

Compatibility

The REASSIGN OWNED statement is a + PostgreSQL extension. +


PrevHomeNext
PREPARE TRANSACTIONUpREINDEX
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-reindex.html b/doc/src/sgml/html/sql-reindex.html new file mode 100644 index 000000000..829af9691 --- /dev/null +++ b/doc/src/sgml/html/sql-reindex.html @@ -0,0 +1,590 @@ + +REINDEX

REINDEX

Name

REINDEX -- rebuild indexes

Synopsis

REINDEX { INDEX | TABLE | DATABASE | SYSTEM } name [ FORCE ]

Description

REINDEX rebuilds an index using the data + stored in the index's table, replacing the old copy of the index. There are + several scenarios in which to use REINDEX: + +

  • An index has become corrupted, and no longer contains valid + data. Although in theory this should never happen, in + practice indexes can become corrupted due to software bugs or + hardware failures. REINDEX provides a + recovery method. +

  • An index has become "bloated", that it is contains many + empty or nearly-empty pages. This can occur with B-tree indexes in + PostgreSQL under certain uncommon access + patterns. REINDEX provides a way to reduce + the space consumption of the index by writing a new version of + the index without the dead pages. See Section 23.2 for more information. +

  • You have altered a storage parameter (such as fillfactor) + for an index, and wish to ensure that the change has taken full effect. +

  • An index build with the CONCURRENTLY option failed, leaving + an "invalid" index. Such indexes are useless but it can be + convenient to use REINDEX to rebuild them. Note that + REINDEX will not perform a concurrent build. To build the + index without interfering with production you should drop the index and + reissue the CREATE INDEX CONCURRENTLY command. +

Parameters

INDEX

Recreate the specified index. +

TABLE

Recreate all indexes of the specified table. If the table has a + secondary "TOAST" table, that is reindexed as well. +

DATABASE

Recreate all indexes within the current database. + Indexes on shared system catalogs are also processed. + This form of REINDEX cannot be executed inside a + transaction block. +

SYSTEM

Recreate all indexes on system catalogs within the current database. + Indexes on shared system catalogs are included. + Indexes on user tables are not processed. + This form of REINDEX cannot be executed inside a + transaction block. +

name

The name of the specific index, table, or database to be + reindexed. Index and table names can be schema-qualified. + Presently, REINDEX DATABASE and REINDEX SYSTEM + can only reindex the current database, so their parameter must match + the current database's name. +

FORCE

This is an obsolete option; it is ignored if specified. +

Notes

If you suspect corruption of an index on a user table, you can + simply rebuild that index, or all indexes on the table, using + REINDEX INDEX or REINDEX TABLE. +

Things are more difficult if you need to recover from corruption of + an index on a system table. In this case it's important for the + system to not have used any of the suspect indexes itself. + (Indeed, in this sort of scenario you might find that server + processes are crashing immediately at start-up, due to reliance on + the corrupted indexes.) To recover safely, the server must be started + with the -P option, which prevents it from using + indexes for system catalog lookups. +

One way to do this is to shut down the server and start a single-user + PostgreSQL server + with the -P option included on its command line. + Then, REINDEX DATABASE, REINDEX SYSTEM, + REINDEX TABLE, or REINDEX INDEX can be + issued, depending on how much you want to reconstruct. If in + doubt, use REINDEX SYSTEM to select + reconstruction of all system indexes in the database. Then quit + the single-user server session and restart the regular server. + See the postgres reference page for more + information about how to interact with the single-user server + interface. +

Alternatively, a regular server session can be started with + -P included in its command line options. + The method for doing this varies across clients, but in all + libpq-based clients, it is possible to set + the PGOPTIONS environment variable to -P + before starting the client. Note that while this method does not + require locking out other clients, it might still be wise to prevent + other users from connecting to the damaged database until repairs + have been completed. +

REINDEX is similar to a drop and recreate of the index + in that the index contents are rebuilt from scratch. However, the locking + considerations are rather different. REINDEX locks out writes + but not reads of the index's parent table. It also takes an exclusive lock + on the specific index being processed, which will block reads that attempt + to use that index. In contrast, DROP INDEX momentarily takes + exclusive lock on the parent table, blocking both writes and reads. The + subsequent CREATE INDEX locks out writes but not reads; since + the index is not there, no read will attempt to use it, meaning that there + will be no blocking but reads might be forced into expensive sequential + scans. +

Reindexing a single index or table requires being the owner of that + index or table. Reindexing a database requires being the owner of + the database (note that the owner can therefore rebuild indexes of + tables owned by other users). Of course, superusers can always + reindex anything. +

Prior to PostgreSQL 8.1, REINDEX + DATABASE processed only system indexes, not all indexes as one would + expect from the name. This has been changed to reduce the surprise + factor. The old behavior is available as REINDEX SYSTEM. +

Prior to PostgreSQL 7.4, REINDEX + TABLE did not automatically process TOAST tables, and so those had + to be reindexed by separate commands. This is still possible, but + redundant. +

Examples

Rebuild a single index: + +

REINDEX INDEX my_index;

+

Rebuild all the indexes on the table my_table: + +

REINDEX TABLE my_table;

+

Rebuild all indexes in a particular database, without trusting the + system indexes to be valid already: + +

$ export PGOPTIONS="-P"
+$ psql broken_db
+...
+broken_db=> REINDEX DATABASE broken_db;
+broken_db=> \q

Compatibility

There is no REINDEX command in the SQL standard. +


PrevHomeNext
REASSIGN OWNEDUpRELEASE SAVEPOINT
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-release-savepoint.html b/doc/src/sgml/html/sql-release-savepoint.html new file mode 100644 index 000000000..89337ae2a --- /dev/null +++ b/doc/src/sgml/html/sql-release-savepoint.html @@ -0,0 +1,330 @@ + +RELEASE SAVEPOINT

RELEASE SAVEPOINT

Name

RELEASE SAVEPOINT -- destroy a previously defined savepoint

Synopsis

RELEASE [ SAVEPOINT ] savepoint_name

Description

RELEASE SAVEPOINT destroys a savepoint previously defined + in the current transaction. +

Destroying a savepoint makes it unavailable as a rollback point, + but it has no other user visible behavior. It does not undo the + effects of commands executed after the savepoint was established. + (To do that, see ROLLBACK TO SAVEPOINT.) + Destroying a savepoint when + it is no longer needed allows the system to reclaim some resources + earlier than transaction end. +

RELEASE SAVEPOINT also destroys all savepoints that were + established after the named savepoint was established. +

Parameters

savepoint_name

The name of the savepoint to destroy. +

Notes

Specifying a savepoint name that was not previously defined is an error. +

It is not possible to release a savepoint when the transaction is in + an aborted state. +

If multiple savepoints have the same name, only the one that was most + recently defined is released. +

Examples

To establish and later destroy a savepoint: +

BEGIN;
+    INSERT INTO table1 VALUES (3);
+    SAVEPOINT my_savepoint;
+    INSERT INTO table1 VALUES (4);
+    RELEASE SAVEPOINT my_savepoint;
+COMMIT;

+ The above transaction will insert both 3 and 4. +

Compatibility

This command conforms to the SQL standard. The standard + specifies that the key word SAVEPOINT is + mandatory, but PostgreSQL allows it to + be omitted. +


PrevHomeNext
REINDEXUpRESET
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-reset.html b/doc/src/sgml/html/sql-reset.html new file mode 100644 index 000000000..dc7ce0037 --- /dev/null +++ b/doc/src/sgml/html/sql-reset.html @@ -0,0 +1,340 @@ + +RESET

RESET

Name

RESET -- restore the value of a run-time parameter to the default value

Synopsis

RESET configuration_parameter
+RESET ALL

Description

RESET restores run-time parameters to their + default values. RESET is an alternative + spelling for +

SET configuration_parameter TO DEFAULT

+ Refer to SET for + details. +

The default value is defined as the value that the parameter would + have had, if no SET had ever been issued for it in the + current session. The actual source of this value might be a + compiled-in default, the configuration file, command-line options, + or per-database or per-user default settings. This is subtly different + from defining it as "the value that the parameter had at session + start", because if the value came from the configuration file, it + will be reset to whatever is specified by the configuration file now. + See Chapter 18 for details. +

The transactional behavior of RESET is the same as + SET: its effects will be undone by transaction rollback. +

Parameters

configuration_parameter

Name of a settable run-time parameter. Available parameters are + documented in Chapter 18 and on the + SET reference page. +

ALL

Resets all settable run-time parameters to default values. +

Examples

Set the timezone configuration variable to its default value: +

RESET timezone;

Compatibility

RESET is a PostgreSQL extension. +

See Also

SET, SHOW

PrevHomeNext
RELEASE SAVEPOINTUpREVOKE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-revoke.html b/doc/src/sgml/html/sql-revoke.html new file mode 100644 index 000000000..f4fa17c54 --- /dev/null +++ b/doc/src/sgml/html/sql-revoke.html @@ -0,0 +1,800 @@ + +REVOKE

REVOKE

Name

REVOKE -- remove access privileges

Synopsis

REVOKE [ GRANT OPTION FOR ]
+    { { SELECT | INSERT | UPDATE | DELETE | TRUNCATE | REFERENCES | TRIGGER }
+    [, ...] | ALL [ PRIVILEGES ] }
+    ON { [ TABLE ] table_name [, ...]
+         | ALL TABLES IN SCHEMA schema_name [, ...] }
+    FROM { [ GROUP ] role_name | PUBLIC } [, ...]
+    [ CASCADE | RESTRICT ]
+
+REVOKE [ GRANT OPTION FOR ]
+    { { SELECT | INSERT | UPDATE | REFERENCES } ( column_name [, ...] )
+    [, ...] | ALL [ PRIVILEGES ] ( column_name [, ...] ) }
+    ON [ TABLE ] table_name [, ...]
+    FROM { [ GROUP ] role_name | PUBLIC } [, ...]
+    [ CASCADE | RESTRICT ]
+
+REVOKE [ GRANT OPTION FOR ]
+    { { USAGE | SELECT | UPDATE }
+    [, ...] | ALL [ PRIVILEGES ] }
+    ON { SEQUENCE sequence_name [, ...]
+         | ALL SEQUENCES IN SCHEMA schema_name [, ...] }
+    FROM { [ GROUP ] role_name | PUBLIC } [, ...]
+    [ CASCADE | RESTRICT ]
+
+REVOKE [ GRANT OPTION FOR ]
+    { { CREATE | CONNECT | TEMPORARY | TEMP } [, ...] | ALL [ PRIVILEGES ] }
+    ON DATABASE database_name [, ...]
+    FROM { [ GROUP ] role_name | PUBLIC } [, ...]
+    [ CASCADE | RESTRICT ]
+
+REVOKE [ GRANT OPTION FOR ]
+    { USAGE | ALL [ PRIVILEGES ] }
+    ON DOMAIN domain_name [, ...]
+    FROM { [ GROUP ] role_name | PUBLIC } [, ...]
+    [ CASCADE | RESTRICT ]
+
+REVOKE [ GRANT OPTION FOR ]
+    { USAGE | ALL [ PRIVILEGES ] }
+    ON FOREIGN DATA WRAPPER fdw_name [, ...]
+    FROM { [ GROUP ] role_name | PUBLIC } [, ...]
+    [ CASCADE | RESTRICT ]
+
+REVOKE [ GRANT OPTION FOR ]
+    { USAGE | ALL [ PRIVILEGES ] }
+    ON FOREIGN SERVER server_name [, ...]
+    FROM { [ GROUP ] role_name | PUBLIC } [, ...]
+    [ CASCADE | RESTRICT ]
+
+REVOKE [ GRANT OPTION FOR ]
+    { EXECUTE | ALL [ PRIVILEGES ] }
+    ON { FUNCTION function_name ( [ [ argmode ] [ arg_name ] arg_type [, ...] ] ) [, ...]
+         | ALL FUNCTIONS IN SCHEMA schema_name [, ...] }
+    FROM { [ GROUP ] role_name | PUBLIC } [, ...]
+    [ CASCADE | RESTRICT ]
+
+REVOKE [ GRANT OPTION FOR ]
+    { USAGE | ALL [ PRIVILEGES ] }
+    ON LANGUAGE lang_name [, ...]
+    FROM { [ GROUP ] role_name | PUBLIC } [, ...]
+    [ CASCADE | RESTRICT ]
+
+REVOKE [ GRANT OPTION FOR ]
+    { { SELECT | UPDATE } [, ...] | ALL [ PRIVILEGES ] }
+    ON LARGE OBJECT loid [, ...]
+    FROM { [ GROUP ] role_name | PUBLIC } [, ...]
+    [ CASCADE | RESTRICT ]
+
+REVOKE [ GRANT OPTION FOR ]
+    { { CREATE | USAGE } [, ...] | ALL [ PRIVILEGES ] }
+    ON SCHEMA schema_name [, ...]
+    FROM { [ GROUP ] role_name | PUBLIC } [, ...]
+    [ CASCADE | RESTRICT ]
+
+REVOKE [ GRANT OPTION FOR ]
+    { CREATE | ALL [ PRIVILEGES ] }
+    ON TABLESPACE tablespace_name [, ...]
+    FROM { [ GROUP ] role_name | PUBLIC } [, ...]
+    [ CASCADE | RESTRICT ]
+
+REVOKE [ GRANT OPTION FOR ]
+    { USAGE | ALL [ PRIVILEGES ] }
+    ON TYPE type_name [, ...]
+    FROM { [ GROUP ] role_name | PUBLIC } [, ...]
+    [ CASCADE | RESTRICT ]
+
+REVOKE [ ADMIN OPTION FOR ]
+    role_name [, ...] FROM role_name [, ...]
+    [ CASCADE | RESTRICT ]

Description

The REVOKE command revokes previously granted + privileges from one or more roles. The key word + PUBLIC refers to the implicitly defined group of + all roles. +

See the description of the GRANT command for + the meaning of the privilege types. +

Note that any particular role will have the sum + of privileges granted directly to it, privileges granted to any role it + is presently a member of, and privileges granted to + PUBLIC. Thus, for example, revoking SELECT privilege + from PUBLIC does not necessarily mean that all roles + have lost SELECT privilege on the object: those who have it granted + directly or via another role will still have it. Similarly, revoking + SELECT from a user might not prevent that user from using + SELECT if PUBLIC or another membership + role still has SELECT rights. +

If GRANT OPTION FOR is specified, only the grant + option for the privilege is revoked, not the privilege itself. + Otherwise, both the privilege and the grant option are revoked. +

If a user holds a privilege with grant option and has granted it to + other users then the privileges held by those other users are + called dependent privileges. If the privilege or the grant option + held by the first user is being revoked and dependent privileges + exist, those dependent privileges are also revoked if + CASCADE is specified; if it is not, the revoke action + will fail. This recursive revocation only affects privileges that + were granted through a chain of users that is traceable to the user + that is the subject of this REVOKE command. + Thus, the affected users might effectively keep the privilege if it + was also granted through other users. +

When revoking privileges on a table, the corresponding column privileges + (if any) are automatically revoked on each column of the table, as well. + On the other hand, if a role has been granted privileges on a table, then + revoking the same privileges from individual columns will have no effect. +

When revoking membership in a role, GRANT OPTION is instead + called ADMIN OPTION, but the behavior is similar. + Note also that this form of the command does not + allow the noise word GROUP. +

Notes

Use psql's \dp command to + display the privileges granted on existing tables and columns. See GRANT for information about the + format. For non-table objects there are other \d commands + that can display their privileges. +

A user can only revoke privileges that were granted directly by + that user. If, for example, user A has granted a privilege with + grant option to user B, and user B has in turned granted it to user + C, then user A cannot revoke the privilege directly from C. + Instead, user A could revoke the grant option from user B and use + the CASCADE option so that the privilege is + in turn revoked from user C. For another example, if both A and B + have granted the same privilege to C, A can revoke his own grant + but not B's grant, so C will still effectively have the privilege. +

When a non-owner of an object attempts to REVOKE privileges + on the object, the command will fail outright if the user has no + privileges whatsoever on the object. As long as some privilege is + available, the command will proceed, but it will revoke only those + privileges for which the user has grant options. The REVOKE ALL + PRIVILEGES forms will issue a warning message if no grant options are + held, while the other forms will issue a warning if grant options for + any of the privileges specifically named in the command are not held. + (In principle these statements apply to the object owner as well, but + since the owner is always treated as holding all grant options, the + cases can never occur.) +

If a superuser chooses to issue a GRANT or REVOKE + command, the command is performed as though it were issued by the + owner of the affected object. Since all privileges ultimately come + from the object owner (possibly indirectly via chains of grant options), + it is possible for a superuser to revoke all privileges, but this might + require use of CASCADE as stated above. +

REVOKE can also be done by a role + that is not the owner of the affected object, but is a member of the role + that owns the object, or is a member of a role that holds privileges + WITH GRANT OPTION on the object. In this case the + command is performed as though it were issued by the containing role that + actually owns the object or holds the privileges + WITH GRANT OPTION. For example, if table + t1 is owned by role g1, of which role + u1 is a member, then u1 can revoke privileges + on t1 that are recorded as being granted by g1. + This would include grants made by u1 as well as by other + members of role g1. +

If the role executing REVOKE holds privileges + indirectly via more than one role membership path, it is unspecified + which containing role will be used to perform the command. In such cases + it is best practice to use SET ROLE to become the specific + role you want to do the REVOKE as. Failure to do so might + lead to revoking privileges other than the ones you intended, or not + revoking anything at all. +

Examples

Revoke insert privilege for the public on table + films: + +

REVOKE INSERT ON films FROM PUBLIC;

+

Revoke all privileges from user manuel on view + kinds: + +

REVOKE ALL PRIVILEGES ON kinds FROM manuel;

+ + Note that this actually means "revoke all privileges that I + granted". +

Revoke membership in role admins from user joe: + +

REVOKE admins FROM joe;

Compatibility

The compatibility notes of the GRANT command + apply analogously to REVOKE. + The keyword RESTRICT or CASCADE + is required according to the standard, but PostgreSQL + assumes RESTRICT by default. +

See Also

GRANT +


PrevHomeNext
RESETUpROLLBACK
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-rollback-prepared.html b/doc/src/sgml/html/sql-rollback-prepared.html new file mode 100644 index 000000000..2611c7ccc --- /dev/null +++ b/doc/src/sgml/html/sql-rollback-prepared.html @@ -0,0 +1,308 @@ + +ROLLBACK PREPARED

ROLLBACK PREPARED

Name

ROLLBACK PREPARED -- cancel a transaction that was earlier prepared for two-phase commit

Synopsis

ROLLBACK PREPARED transaction_id

Description

ROLLBACK PREPARED rolls back a transaction that is in + prepared state. +

Parameters

transaction_id

The transaction identifier of the transaction that is to be + rolled back. +

Notes

To roll back a prepared transaction, you must be either the same user that + executed the transaction originally, or a superuser. But you do not + have to be in the same session that executed the transaction. +

This command cannot be executed inside a transaction block. The prepared + transaction is rolled back immediately. +

All currently available prepared transactions are listed in the + pg_prepared_xacts + system view. +

Examples

Roll back the transaction identified by the transaction + identifier foobar: + +

ROLLBACK PREPARED 'foobar';

Compatibility

ROLLBACK PREPARED is a + PostgreSQL extension. It is intended for use by + external transaction management systems, some of which are covered by + standards (such as X/Open XA), but the SQL side of those systems is not + standardized. +


PrevHomeNext
ROLLBACKUpROLLBACK TO SAVEPOINT
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-rollback-to.html b/doc/src/sgml/html/sql-rollback-to.html new file mode 100644 index 000000000..f298bfff0 --- /dev/null +++ b/doc/src/sgml/html/sql-rollback-to.html @@ -0,0 +1,397 @@ + +ROLLBACK TO SAVEPOINT

ROLLBACK TO SAVEPOINT

Name

ROLLBACK TO SAVEPOINT -- roll back to a savepoint

Synopsis

ROLLBACK [ WORK | TRANSACTION ] TO [ SAVEPOINT ] savepoint_name

Description

Roll back all commands that were executed after the savepoint was + established. The savepoint remains valid and can be rolled back to + again later, if needed. +

ROLLBACK TO SAVEPOINT implicitly destroys all savepoints that + were established after the named savepoint. +

Parameters

savepoint_name

The savepoint to roll back to. +

Notes

Use RELEASE SAVEPOINT to destroy a savepoint + without discarding the effects of commands executed after it was + established. +

Specifying a savepoint name that has not been established is an error. +

Cursors have somewhat non-transactional behavior with respect to + savepoints. Any cursor that is opened inside a savepoint will be closed + when the savepoint is rolled back. If a previously opened cursor is + affected by a FETCH or MOVE command inside a + savepoint that is later rolled back, the cursor remains at the + position that FETCH left it pointing to (that is, the cursor + motion caused by FETCH is not rolled back). + Closing a cursor is not undone by rolling back, either. + However, other side-effects caused by the cursor's query (such as + side-effects of volatile functions called by the query) are + rolled back if they occur during a savepoint that is later rolled back. + A cursor whose execution causes a transaction to abort is put in a + cannot-execute state, so while the transaction can be restored using + ROLLBACK TO SAVEPOINT, the cursor can no longer be used. +

Examples

To undo the effects of the commands executed after my_savepoint + was established: +

ROLLBACK TO SAVEPOINT my_savepoint;

+

Cursor positions are not affected by savepoint rollback: +

BEGIN;
+
+DECLARE foo CURSOR FOR SELECT 1 UNION SELECT 2;
+
+SAVEPOINT foo;
+
+FETCH 1 FROM foo;
+ ?column? 
+----------
+        1
+
+ROLLBACK TO SAVEPOINT foo;
+
+FETCH 1 FROM foo;
+ ?column? 
+----------
+        2
+
+COMMIT;

Compatibility

The SQL standard specifies that the key word + SAVEPOINT is mandatory, but PostgreSQL + and Oracle allow it to be omitted. SQL allows + only WORK, not TRANSACTION, as a noise word + after ROLLBACK. Also, SQL has an optional clause + AND [ NO ] CHAIN which is not currently supported by + PostgreSQL. Otherwise, this command conforms to + the SQL standard. +


PrevHomeNext
ROLLBACK PREPAREDUpSAVEPOINT
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-rollback.html b/doc/src/sgml/html/sql-rollback.html new file mode 100644 index 000000000..4bc9932f3 --- /dev/null +++ b/doc/src/sgml/html/sql-rollback.html @@ -0,0 +1,293 @@ + +ROLLBACK

ROLLBACK

Name

ROLLBACK -- abort the current transaction

Synopsis

ROLLBACK [ WORK | TRANSACTION ]

Description

ROLLBACK rolls back the current transaction and causes + all the updates made by the transaction to be discarded. +

Parameters

WORK
TRANSACTION

Optional key words. They have no effect. +

Notes

Use COMMIT to + successfully terminate a transaction. +

Issuing ROLLBACK when not inside a transaction does + no harm, but it will provoke a warning message. +

Examples

To abort all changes: +

ROLLBACK;

Compatibility

The SQL standard only specifies the two forms + ROLLBACK and ROLLBACK + WORK. Otherwise, this command is fully conforming. +


PrevHomeNext
REVOKEUpROLLBACK PREPARED
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-savepoint.html b/doc/src/sgml/html/sql-savepoint.html new file mode 100644 index 000000000..d3081e6e7 --- /dev/null +++ b/doc/src/sgml/html/sql-savepoint.html @@ -0,0 +1,346 @@ + +SAVEPOINT

SAVEPOINT

Name

SAVEPOINT -- define a new savepoint within the current transaction

Synopsis

SAVEPOINT savepoint_name

Description

SAVEPOINT establishes a new savepoint within + the current transaction. +

A savepoint is a special mark inside a transaction that allows all commands + that are executed after it was established to be rolled back, restoring + the transaction state to what it was at the time of the savepoint. +

Parameters

savepoint_name

The name to give to the new savepoint. +

Notes

Use ROLLBACK TO SAVEPOINT to + rollback to a savepoint. Use RELEASE SAVEPOINT + to destroy a savepoint, keeping + the effects of commands executed after it was established. +

Savepoints can only be established when inside a transaction block. + There can be multiple savepoints defined within a transaction. +

Examples

To establish a savepoint and later undo the effects of all commands executed + after it was established: +

BEGIN;
+    INSERT INTO table1 VALUES (1);
+    SAVEPOINT my_savepoint;
+    INSERT INTO table1 VALUES (2);
+    ROLLBACK TO SAVEPOINT my_savepoint;
+    INSERT INTO table1 VALUES (3);
+COMMIT;

+ The above transaction will insert the values 1 and 3, but not 2. +

To establish and later destroy a savepoint: +

BEGIN;
+    INSERT INTO table1 VALUES (3);
+    SAVEPOINT my_savepoint;
+    INSERT INTO table1 VALUES (4);
+    RELEASE SAVEPOINT my_savepoint;
+COMMIT;

+ The above transaction will insert both 3 and 4. +

Compatibility

SQL requires a savepoint to be destroyed automatically when another + savepoint with the same name is established. In + PostgreSQL, the old savepoint is kept, though only the more + recent one will be used when rolling back or releasing. (Releasing the + newer savepoint with RELEASE SAVEPOINT will cause the older one + to again become accessible to ROLLBACK TO SAVEPOINT and + RELEASE SAVEPOINT.) Otherwise, SAVEPOINT is + fully SQL conforming. +


PrevHomeNext
ROLLBACK TO SAVEPOINTUpSECURITY LABEL
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-security-label.html b/doc/src/sgml/html/sql-security-label.html new file mode 100644 index 000000000..9254389cc --- /dev/null +++ b/doc/src/sgml/html/sql-security-label.html @@ -0,0 +1,597 @@ + +SECURITY LABEL

SECURITY LABEL

Name

SECURITY LABEL -- define or change a security label applied to an object

Synopsis

SECURITY LABEL [ FOR provider ] ON
+{
+  TABLE object_name |
+  COLUMN table_name.column_name |
+  AGGREGATE agg_name (agg_type [, ...] ) |
+  DATABASE object_name |
+  DOMAIN object_name |
+  FOREIGN TABLE object_name
+  FUNCTION function_name ( [ [ argmode ] [ argname ] argtype [, ...] ] ) |
+  LARGE OBJECT large_object_oid |
+  [ PROCEDURAL ] LANGUAGE object_name |
+  ROLE object_name |
+  SCHEMA object_name |
+  SEQUENCE object_name |
+  TABLESPACE object_name |
+  TYPE object_name |
+  VIEW object_name
+} IS 'label'

Description

SECURITY LABEL applies a security label to a database + object. An arbitrary number of security labels, one per label provider, can + be associated with a given database object. Label providers are loadable + modules which register themselves by using the function + register_label_provider. +

Note: register_label_provider is not an SQL function; it can + only be called from C code loaded into the backend. +

The label provider determines whether a given label is valid and whether + it is permissible to assign that label to a given object. The meaning of a + given label is likewise at the discretion of the label provider. + PostgreSQL places no restrictions on whether or how a + label provider must interpret security labels; it merely provides a + mechanism for storing them. In practice, this facility is intended to allow + integration with label-based mandatory access control (MAC) systems such as + SE-Linux. Such systems make all access control decisions + based on object labels, rather than traditional discretionary access control + (DAC) concepts such as users and groups. +

Parameters

object_name
table_name.column_name
agg_name
function_name

The name of the object to be labeled. Names of tables, + aggregates, domains, foreign tables, functions, sequences, types, and + views can be schema-qualified. +

provider

The name of the provider with which this label is to be associated. The + named provider must be loaded and must consent to the proposed labeling + operation. If exactly one provider is loaded, the provider name may be + omitted for brevity. +

arg_type

An input data type on which the aggregate function operates. + To reference a zero-argument aggregate function, write * + in place of the list of input data types. +

argmode

The mode of a function argument: IN, OUT, + INOUT, or VARIADIC. + If omitted, the default is IN. + Note that SECURITY LABEL ON FUNCTION does not actually + pay any attention to OUT arguments, since only the input + arguments are needed to determine the function's identity. + So it is sufficient to list the IN, INOUT, + and VARIADIC arguments. +

argname

The name of a function argument. + Note that SECURITY LABEL ON FUNCTION does not actually + pay any attention to argument names, since only the argument data + types are needed to determine the function's identity. +

argtype

The data type(s) of the function's arguments (optionally + schema-qualified), if any. +

large_object_oid

The OID of the large object. +

PROCEDURAL

This is a noise word. +

label

The new security label, written as a string literal; or NULL + to drop the security label. +

Examples

The following example shows how the security label of a table might + be changed. + +

SECURITY LABEL FOR selinux ON TABLE mytable IS 'system_u:object_r:sepgsql_table_t:s0';

Compatibility

There is no SECURITY LABEL command in the SQL standard. +


PrevHomeNext
SAVEPOINTUpSELECT
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-select.html b/doc/src/sgml/html/sql-select.html new file mode 100644 index 000000000..e12d136de --- /dev/null +++ b/doc/src/sgml/html/sql-select.html @@ -0,0 +1,4402 @@ + +SELECT

SELECT

Name

SELECT, TABLE, WITH -- retrieve rows from a table or view

Synopsis

[ WITH [ RECURSIVE ] with_query [, ...] ]
+SELECT [ ALL | DISTINCT [ ON ( expression [, ...] ) ] ]
+    * | expression [ [ AS ] output_name ] [, ...]
+    [ FROM from_item [, ...] ]
+    [ WHERE condition ]
+    [ GROUP BY expression [, ...] ]
+    [ HAVING condition [, ...] ]
+    [ WINDOW window_name AS ( window_definition ) [, ...] ]
+    [ { UNION | INTERSECT | EXCEPT } [ ALL | DISTINCT ] select ]
+    [ ORDER BY expression [ ASC | DESC | USING operator ] [ NULLS { FIRST | LAST } ] [, ...] ]
+    [ LIMIT { count | ALL } ]
+    [ OFFSET start [ ROW | ROWS ] ]
+    [ FETCH { FIRST | NEXT } [ count ] { ROW | ROWS } ONLY ]
+    [ FOR { UPDATE | SHARE } [ OF table_name [, ...] ] [ NOWAIT ] [...] ]
+
+where from_item can be one of:
+
+    [ ONLY ] table_name [ * ] [ [ AS ] alias [ ( column_alias [, ...] ) ] ]
+    ( select ) [ AS ] alias [ ( column_alias [, ...] ) ]
+    with_query_name [ [ AS ] alias [ ( column_alias [, ...] ) ] ]
+    function_name ( [ argument [, ...] ] ) [ AS ] alias [ ( column_alias [, ...] | column_definition [, ...] ) ]
+    function_name ( [ argument [, ...] ] ) AS ( column_definition [, ...] )
+    from_item [ NATURAL ] join_type from_item [ ON join_condition | USING ( join_column [, ...] ) ]
+
+and with_query is:
+
+    with_query_name [ ( column_name [, ...] ) ] AS ( select | values | insert | update | delete )
+
+TABLE [ ONLY ] table_name [ * ]

Description

SELECT retrieves rows from zero or more tables. + The general processing of SELECT is as follows: + +

  1. All queries in the WITH list are computed. + These effectively serve as temporary tables that can be referenced + in the FROM list. A WITH query + that is referenced more than once in FROM is + computed only once. + (See WITH Clause below.) +

  2. All elements in the FROM list are computed. + (Each element in the FROM list is a real or + virtual table.) If more than one element is specified in the + FROM list, they are cross-joined together. + (See FROM Clause below.) +

  3. If the WHERE clause is specified, all rows + that do not satisfy the condition are eliminated from the + output. (See WHERE Clause below.) +

  4. If the GROUP BY clause is specified, the + output is combined into groups of rows that match on one or more + values. If the HAVING clause is present, it + eliminates groups that do not satisfy the given condition. (See + GROUP BY Clause and + HAVING Clause below.) +

  5. The actual output rows are computed using the + SELECT output expressions for each selected + row or row group. (See + SELECT List + below.) +

  6. SELECT DISTINCT eliminates duplicate rows from the + result. SELECT DISTINCT ON eliminates rows that + match on all the specified expressions. SELECT ALL + (the default) will return all candidate rows, including + duplicates. (See DISTINCT Clause below.) +

  7. Using the operators UNION, + INTERSECT, and EXCEPT, the + output of more than one SELECT statement can + be combined to form a single result set. The + UNION operator returns all rows that are in + one or both of the result sets. The + INTERSECT operator returns all rows that are + strictly in both result sets. The EXCEPT + operator returns the rows that are in the first result set but + not in the second. In all three cases, duplicate rows are + eliminated unless ALL is specified. The noise + word DISTINCT can be added to explicitly specify + eliminating duplicate rows. Notice that DISTINCT is + the default behavior here, even though ALL is + the default for SELECT itself. (See + UNION Clause, INTERSECT Clause, and + EXCEPT Clause below.) +

  8. If the ORDER BY clause is specified, the + returned rows are sorted in the specified order. If + ORDER BY is not given, the rows are returned + in whatever order the system finds fastest to produce. (See + ORDER BY Clause below.) +

  9. If the LIMIT (or FETCH FIRST) or OFFSET + clause is specified, the SELECT statement + only returns a subset of the result rows. (See LIMIT Clause below.) +

  10. If FOR UPDATE or FOR SHARE + is specified, the + SELECT statement locks the selected rows + against concurrent updates. (See FOR UPDATE/FOR SHARE Clause below.) +

+

You must have SELECT privilege on each column used + in a SELECT command. The use of FOR UPDATE + or FOR SHARE requires + UPDATE privilege as well (for at least one column + of each table so selected). +

Parameters

WITH Clause

The WITH clause allows you to specify one or more + subqueries that can be referenced by name in the primary query. + The subqueries effectively act as temporary tables or views + for the duration of the primary query. + Each subquery can be a SELECT, VALUES, + INSERT, UPDATE or + DELETE statement. + When writing a data-modifying statement (INSERT, + UPDATE or DELETE) in + WITH, it is usual to include a RETURNING clause. + It is the output of RETURNING, not the underlying + table that the statement modifies, that forms the temporary table that is + read by the primary query. If RETURNING is omitted, the + statement is still executed, but it produces no output so it cannot be + referenced as a table by the primary query. +

A name (without schema qualification) must be specified for each + WITH query. Optionally, a list of column names + can be specified; if this is omitted, + the column names are inferred from the subquery. +

If RECURSIVE is specified, it allows a + SELECT subquery to reference itself by name. Such a + subquery must have the form +

non_recursive_term UNION [ ALL | DISTINCT ] recursive_term

+ where the recursive self-reference must appear on the right-hand + side of the UNION. Only one recursive self-reference + is permitted per query. Recursive data-modifying statements are not + supported, but you can use the results of a recursive + SELECT query in + a data-modifying statement. See Section 7.8 for + an example. +

Another effect of RECURSIVE is that + WITH queries need not be ordered: a query + can reference another one that is later in the list. (However, + circular references, or mutual recursion, are not implemented.) + Without RECURSIVE, WITH queries + can only reference sibling WITH queries + that are earlier in the WITH list. +

A key property of WITH queries is that they + are evaluated only once per execution of the primary query, + even if the primary query refers to them more than once. + In particular, data-modifying statements are guaranteed to be + executed once and only once, regardless of whether the primary query + reads all or any of their output. +

The primary query and the WITH queries are all + (notionally) executed at the same time. This implies that the effects of + a data-modifying statement in WITH cannot be seen from + other parts of the query, other than by reading its RETURNING + output. If two such data-modifying statements attempt to modify the same + row, the results are unspecified. +

See Section 7.8 for additional information. +

FROM Clause

The FROM clause specifies one or more source + tables for the SELECT. If multiple sources are + specified, the result is the Cartesian product (cross join) of all + the sources. But usually qualification conditions + are added to restrict the returned rows to a small subset of the + Cartesian product. +

The FROM clause can contain the following + elements: + +

table_name

The name (optionally schema-qualified) of an existing table or view. + If ONLY is specified before the table name, only that + table is scanned. If ONLY is not specified, the table + and all its descendant tables (if any) are scanned. Optionally, + * can be specified after the table name to explicitly + indicate that descendant tables are included. +

alias

A substitute name for the FROM item containing the + alias. An alias is used for brevity or to eliminate ambiguity + for self-joins (where the same table is scanned multiple + times). When an alias is provided, it completely hides the + actual name of the table or function; for example given + FROM foo AS f, the remainder of the + SELECT must refer to this FROM + item as f not foo. If an alias is + written, a column alias list can also be written to provide + substitute names for one or more columns of the table. +

select

A sub-SELECT can appear in the + FROM clause. This acts as though its + output were created as a temporary table for the duration of + this single SELECT command. Note that the + sub-SELECT must be surrounded by + parentheses, and an alias must be + provided for it. A + VALUES command + can also be used here. +

with_query_name

A WITH query is referenced by writing its name, + just as though the query's name were a table name. (In fact, + the WITH query hides any real table of the same name + for the purposes of the primary query. If necessary, you can + refer to a real table of the same name by schema-qualifying + the table's name.) + An alias can be provided in the same way as for a table. +

function_name

Function calls can appear in the FROM + clause. (This is especially useful for functions that return + result sets, but any function can be used.) This acts as + though its output were created as a temporary table for the + duration of this single SELECT command. An + alias can also be used. If an alias is written, a column alias + list can also be written to provide substitute names for one + or more attributes of the function's composite return type. If + the function has been defined as returning the record + data type, then an alias or the key word AS must + be present, followed by a column definition list in the form + ( column_name data_type [, ... ] + ). The column definition list must match the actual + number and types of columns returned by the function. +

join_type

One of +

  • [ INNER ] JOIN

  • LEFT [ OUTER ] JOIN

  • RIGHT [ OUTER ] JOIN

  • FULL [ OUTER ] JOIN

  • CROSS JOIN

+ + For the INNER and OUTER join types, a + join condition must be specified, namely exactly one of + NATURAL, ON join_condition, or + USING (join_column [, ...]). + See below for the meaning. For CROSS JOIN, + none of these clauses can appear. +

A JOIN clause combines two + FROM items. Use parentheses if necessary to + determine the order of nesting. In the absence of parentheses, + JOINs nest left-to-right. In any case + JOIN binds more tightly than the commas + separating FROM items. +

CROSS JOIN and INNER JOIN + produce a simple Cartesian product, the same result as you get from + listing the two items at the top level of FROM, + but restricted by the join condition (if any). + CROSS JOIN is equivalent to INNER JOIN ON + (TRUE), that is, no rows are removed by qualification. + These join types are just a notational convenience, since they + do nothing you couldn't do with plain FROM and + WHERE. +

LEFT OUTER JOIN returns all rows in the qualified + Cartesian product (i.e., all combined rows that pass its join + condition), plus one copy of each row in the left-hand table + for which there was no right-hand row that passed the join + condition. This left-hand row is extended to the full width + of the joined table by inserting null values for the + right-hand columns. Note that only the JOIN + clause's own condition is considered while deciding which rows + have matches. Outer conditions are applied afterwards. +

Conversely, RIGHT OUTER JOIN returns all the + joined rows, plus one row for each unmatched right-hand row + (extended with nulls on the left). This is just a notational + convenience, since you could convert it to a LEFT + OUTER JOIN by switching the left and right inputs. +

FULL OUTER JOIN returns all the joined rows, plus + one row for each unmatched left-hand row (extended with nulls + on the right), plus one row for each unmatched right-hand row + (extended with nulls on the left). +

ON join_condition

join_condition is + an expression resulting in a value of type + boolean (similar to a WHERE + clause) that specifies which rows in a join are considered to + match. +

USING ( join_column [, ...] )

A clause of the form USING ( a, b, ... ) is + shorthand for ON left_table.a = right_table.a AND + left_table.b = right_table.b .... Also, + USING implies that only one of each pair of + equivalent columns will be included in the join output, not + both. +

NATURAL

NATURAL is shorthand for a + USING list that mentions all columns in the two + tables that have the same names. +

+

WHERE Clause

The optional WHERE clause has the general form +

WHERE condition

+ where condition is + any expression that evaluates to a result of type + boolean. Any row that does not satisfy this + condition will be eliminated from the output. A row satisfies the + condition if it returns true when the actual row values are + substituted for any variable references. +

GROUP BY Clause

The optional GROUP BY clause has the general form +

GROUP BY expression [, ...]

+

GROUP BY will condense into a single row all + selected rows that share the same values for the grouped + expressions. expression can be an input column + name, or the name or ordinal number of an output column + (SELECT list item), or an arbitrary + expression formed from input-column values. In case of ambiguity, + a GROUP BY name will be interpreted as an + input-column name rather than an output column name. +

Aggregate functions, if any are used, are computed across all rows + making up each group, producing a separate value for each group + (whereas without GROUP BY, an aggregate + produces a single value computed across all the selected rows). + When GROUP BY is present, it is not valid for + the SELECT list expressions to refer to + ungrouped columns except within aggregate functions or if the + ungrouped column is functionally dependent on the grouped columns, + since there would otherwise be more than one possible value to + return for an ungrouped column. A functional dependency exists if + the grouped columns (or a subset thereof) are the primary key of + the table containing the ungrouped column. +

HAVING Clause

The optional HAVING clause has the general form +

HAVING condition

+ where condition is + the same as specified for the WHERE clause. +

HAVING eliminates group rows that do not + satisfy the condition. HAVING is different + from WHERE: WHERE filters + individual rows before the application of GROUP + BY, while HAVING filters group rows + created by GROUP BY. Each column referenced in + condition must + unambiguously reference a grouping column, unless the reference + appears within an aggregate function. +

The presence of HAVING turns a query into a grouped + query even if there is no GROUP BY clause. This is the + same as what happens when the query contains aggregate functions but + no GROUP BY clause. All the selected rows are considered to + form a single group, and the SELECT list and + HAVING clause can only reference table columns from + within aggregate functions. Such a query will emit a single row if the + HAVING condition is true, zero rows if it is not true. +

WINDOW Clause

The optional WINDOW clause has the general form +

WINDOW window_name AS ( window_definition ) [, ...]

+ where window_name is + a name that can be referenced from subsequent window definitions or + OVER clauses, and + window_definition is +

[ existing_window_name ]
+[ PARTITION BY expression [, ...] ]
+[ ORDER BY expression [ ASC | DESC | USING operator ] [ NULLS { FIRST | LAST } ] [, ...] ]
+[ frame_clause ]

+

If an existing_window_name + is specified it must refer to an earlier entry in the WINDOW + list; the new window copies its partitioning clause from that entry, + as well as its ordering clause if any. In this case the new window cannot + specify its own PARTITION BY clause, and it can specify + ORDER BY only if the copied window does not have one. + The new window always uses its own frame clause; the copied window + must not specify a frame clause. +

The elements of the PARTITION BY list are interpreted in + much the same fashion as elements of a + GROUP BY Clause, except that + they are always simple expressions and never the name or number of an + output column. + Another difference is that these expressions can contain aggregate + function calls, which are not allowed in a regular GROUP BY + clause. They are allowed here because windowing occurs after grouping + and aggregation. +

Similarly, the elements of the ORDER BY list are interpreted + in much the same fashion as elements of an + ORDER BY Clause, except that + the expressions are always taken as simple expressions and never the name + or number of an output column. +

The optional frame_clause defines + the window frame for window functions that depend on the + frame (not all do). The window frame is a set of related rows for + each row of the query (called the current row). + The frame_clause can be one of + +

[ RANGE | ROWS ] frame_start
+[ RANGE | ROWS ] BETWEEN frame_start AND frame_end

+ + where frame_start and frame_end can be + one of + +

UNBOUNDED PRECEDING
+value PRECEDING
+CURRENT ROW
+value FOLLOWING
+UNBOUNDED FOLLOWING

+ + If frame_end is omitted it defaults to CURRENT + ROW. Restrictions are that + frame_start cannot be UNBOUNDED FOLLOWING, + frame_end cannot be UNBOUNDED PRECEDING, + and the frame_end choice cannot appear earlier in the + above list than the frame_start choice — for example + RANGE BETWEEN CURRENT ROW AND value + PRECEDING is not allowed. +

The default framing option is RANGE UNBOUNDED PRECEDING, + which is the same as RANGE BETWEEN UNBOUNDED PRECEDING AND + CURRENT ROW; it sets the frame to be all rows from the partition start + up through the current row's last peer in the ORDER BY + ordering (which means all rows if there is no ORDER BY). + In general, UNBOUNDED PRECEDING means that the frame + starts with the first row of the partition, and similarly + UNBOUNDED FOLLOWING means that the frame ends with the last + row of the partition (regardless of RANGE or ROWS + mode). In ROWS mode, CURRENT ROW + means that the frame starts or ends with the current row; but in + RANGE mode it means that the frame starts or ends with + the current row's first or last peer in the ORDER BY ordering. + The value PRECEDING and + value FOLLOWING cases are currently only + allowed in ROWS mode. They indicate that the frame starts + or ends with the row that many rows before or after the current row. + value must be an integer expression not + containing any variables, aggregate functions, or window functions. + The value must not be null or negative; but it can be zero, which + selects the current row itself. +

Beware that the ROWS options can produce unpredictable + results if the ORDER BY ordering does not order the rows + uniquely. The RANGE options are designed to ensure that + rows that are peers in the ORDER BY ordering are treated + alike; any two peer rows will be both in or both not in the frame. +

The purpose of a WINDOW clause is to specify the + behavior of window functions appearing in the query's + SELECT List or + ORDER BY Clause. These functions + can reference the WINDOW clause entries by name + in their OVER clauses. A WINDOW clause + entry does not have to be referenced anywhere, however; if it is not + used in the query it is simply ignored. It is possible to use window + functions without any WINDOW clause at all, since + a window function call can specify its window definition directly in + its OVER clause. However, the WINDOW + clause saves typing when the same window definition is needed for more + than one window function. +

Window functions are described in detail in + Section 3.5, + Section 4.2.8, and + Section 7.2.4. +

SELECT List

The SELECT list (between the key words + SELECT and FROM) specifies expressions + that form the output rows of the SELECT + statement. The expressions can (and usually do) refer to columns + computed in the FROM clause. +

Just as in a table, every output column of a SELECT + has a name. In a simple SELECT this name is just + used to label the column for display, but when the SELECT + is a sub-query of a larger query, the name is seen by the larger query + as the column name of the virtual table produced by the sub-query. + To specify the name to use for an output column, write + AS output_name + after the column's expression. (You can omit AS, + but only if the desired output name does not match any + PostgreSQL keyword (see Appendix C). For protection against possible + future keyword additions, it is recommended that you always either + write AS or double-quote the output name.) + If you do not specify a column name, a name is chosen automatically + by PostgreSQL. If the column's expression + is a simple column reference then the chosen name is the same as that + column's name. In more complex cases a function or type name may be + used, or the system may fall back on a generated name such as + ?column?. +

An output column's name can be used to refer to the column's value in + ORDER BY and GROUP BY clauses, but not in the + WHERE or HAVING clauses; there you must write + out the expression instead. +

Instead of an expression, * can be written in + the output list as a shorthand for all the columns of the selected + rows. Also, you can write table_name.* as a + shorthand for the columns coming from just that table. In these + cases it is not possible to specify new names with AS; + the output column names will be the same as the table columns' names. +

DISTINCT Clause

If SELECT DISTINCT is specified, all duplicate rows are + removed from the result set (one row is kept from each group of + duplicates). SELECT ALL specifies the opposite: all rows are + kept; that is the default. +

SELECT DISTINCT ON ( expression [, ...] ) + keeps only the first row of each set of rows where the given + expressions evaluate to equal. The DISTINCT ON + expressions are interpreted using the same rules as for + ORDER BY (see above). Note that the "first + row" of each set is unpredictable unless ORDER + BY is used to ensure that the desired row appears first. For + example: +

SELECT DISTINCT ON (location) location, time, report
+    FROM weather_reports
+    ORDER BY location, time DESC;

+ retrieves the most recent weather report for each location. But + if we had not used ORDER BY to force descending order + of time values for each location, we'd have gotten a report from + an unpredictable time for each location. +

The DISTINCT ON expression(s) must match the leftmost + ORDER BY expression(s). The ORDER BY clause + will normally contain additional expression(s) that determine the + desired precedence of rows within each DISTINCT ON group. +

UNION Clause

The UNION clause has this general form: +

select_statement UNION [ ALL | DISTINCT ] select_statement

select_statement is + any SELECT statement without an ORDER + BY, LIMIT, FOR UPDATE, or + FOR SHARE clause. + (ORDER BY and LIMIT can be attached to a + subexpression if it is enclosed in parentheses. Without + parentheses, these clauses will be taken to apply to the result of + the UNION, not to its right-hand input + expression.) +

The UNION operator computes the set union of + the rows returned by the involved SELECT + statements. A row is in the set union of two result sets if it + appears in at least one of the result sets. The two + SELECT statements that represent the direct + operands of the UNION must produce the same + number of columns, and corresponding columns must be of compatible + data types. +

The result of UNION does not contain any duplicate + rows unless the ALL option is specified. + ALL prevents elimination of duplicates. (Therefore, + UNION ALL is usually significantly quicker than + UNION; use ALL when you can.) + DISTINCT can be written to explicitly specify the + default behavior of eliminating duplicate rows. +

Multiple UNION operators in the same + SELECT statement are evaluated left to right, + unless otherwise indicated by parentheses. +

Currently, FOR UPDATE and FOR SHARE cannot be + specified either for a UNION result or for any input of a + UNION. +

INTERSECT Clause

The INTERSECT clause has this general form: +

select_statement INTERSECT [ ALL | DISTINCT ] select_statement

select_statement is + any SELECT statement without an ORDER + BY, LIMIT, FOR UPDATE, or + FOR SHARE clause. +

The INTERSECT operator computes the set + intersection of the rows returned by the involved + SELECT statements. A row is in the + intersection of two result sets if it appears in both result sets. +

The result of INTERSECT does not contain any + duplicate rows unless the ALL option is specified. + With ALL, a row that has m duplicates in the + left table and n duplicates in the right table will appear + min(m,n) times in the result set. + DISTINCT can be written to explicitly specify the + default behavior of eliminating duplicate rows. +

Multiple INTERSECT operators in the same + SELECT statement are evaluated left to right, + unless parentheses dictate otherwise. + INTERSECT binds more tightly than + UNION. That is, A UNION B INTERSECT + C will be read as A UNION (B INTERSECT + C). +

Currently, FOR UPDATE and FOR SHARE cannot be + specified either for an INTERSECT result or for any input of + an INTERSECT. +

EXCEPT Clause

The EXCEPT clause has this general form: +

select_statement EXCEPT [ ALL | DISTINCT ] select_statement

select_statement is + any SELECT statement without an ORDER + BY, LIMIT, FOR UPDATE, or + FOR SHARE clause. +

The EXCEPT operator computes the set of rows + that are in the result of the left SELECT + statement but not in the result of the right one. +

The result of EXCEPT does not contain any + duplicate rows unless the ALL option is specified. + With ALL, a row that has m duplicates in the + left table and n duplicates in the right table will appear + max(m-n,0) times in the result set. + DISTINCT can be written to explicitly specify the + default behavior of eliminating duplicate rows. +

Multiple EXCEPT operators in the same + SELECT statement are evaluated left to right, + unless parentheses dictate otherwise. EXCEPT binds at + the same level as UNION. +

Currently, FOR UPDATE and FOR SHARE cannot be + specified either for an EXCEPT result or for any input of + an EXCEPT. +

ORDER BY Clause

The optional ORDER BY clause has this general form: +

ORDER BY expression [ ASC | DESC | USING operator ] [ NULLS { FIRST | LAST } ] [, ...]

+ The ORDER BY clause causes the result rows to + be sorted according to the specified expression(s). If two rows are + equal according to the leftmost expression, they are compared + according to the next expression and so on. If they are equal + according to all specified expressions, they are returned in + an implementation-dependent order. +

Each expression can be the + name or ordinal number of an output column + (SELECT list item), or it can be an arbitrary + expression formed from input-column values. +

The ordinal number refers to the ordinal (left-to-right) position + of the output column. This feature makes it possible to define an + ordering on the basis of a column that does not have a unique + name. This is never absolutely necessary because it is always + possible to assign a name to an output column using the + AS clause. +

It is also possible to use arbitrary expressions in the + ORDER BY clause, including columns that do not + appear in the SELECT output list. Thus the + following statement is valid: +

SELECT name FROM distributors ORDER BY code;

+ A limitation of this feature is that an ORDER BY + clause applying to the result of a UNION, + INTERSECT, or EXCEPT clause can only + specify an output column name or number, not an expression. +

If an ORDER BY expression is a simple name that + matches both an output column name and an input column name, + ORDER BY will interpret it as the output column name. + This is the opposite of the choice that GROUP BY will + make in the same situation. This inconsistency is made to be + compatible with the SQL standard. +

Optionally one can add the key word ASC (ascending) or + DESC (descending) after any expression in the + ORDER BY clause. If not specified, ASC is + assumed by default. Alternatively, a specific ordering operator + name can be specified in the USING clause. + An ordering operator must be a less-than or greater-than + member of some B-tree operator family. + ASC is usually equivalent to USING < and + DESC is usually equivalent to USING >. + (But the creator of a user-defined data type can define exactly what the + default sort ordering is, and it might correspond to operators with other + names.) +

If NULLS LAST is specified, null values sort after all + non-null values; if NULLS FIRST is specified, null values + sort before all non-null values. If neither is specified, the default + behavior is NULLS LAST when ASC is specified + or implied, and NULLS FIRST when DESC is specified + (thus, the default is to act as though nulls are larger than non-nulls). + When USING is specified, the default nulls ordering depends + on whether the operator is a less-than or greater-than operator. +

Note that ordering options apply only to the expression they follow; + for example ORDER BY x, y DESC does not mean + the same thing as ORDER BY x DESC, y DESC. +

Character-string data is sorted according to the collation that applies + to the column being sorted. That can be overridden at need by including + a COLLATE clause in the + expression, for example + ORDER BY mycolumn COLLATE "en_US". + For more information see Section 4.2.10 and + Section 22.2. +

LIMIT Clause

The LIMIT clause consists of two independent + sub-clauses: +

LIMIT { count | ALL }
+OFFSET start

+ count specifies the + maximum number of rows to return, while start specifies the number of rows + to skip before starting to return rows. When both are specified, + start rows are skipped + before starting to count the count rows to be returned. +

If the count expression + evaluates to NULL, it is treated as LIMIT ALL, i.e., no + limit. If start evaluates + to NULL, it is treated the same as OFFSET 0. +

SQL:2008 introduced a different syntax to achieve the same result, + which PostgreSQL also supports. It is: +

OFFSET start { ROW | ROWS }
+FETCH { FIRST | NEXT } [ count ] { ROW | ROWS } ONLY

+ In this syntax, to write anything except a simple integer constant for + start or count, you must write parentheses + around it. + If count is + omitted in a FETCH clause, it defaults to 1. + ROW + and ROWS as well as FIRST + and NEXT are noise words that don't influence + the effects of these clauses. + According to the standard, the OFFSET clause must come + before the FETCH clause if both are present; but + PostgreSQL is laxer and allows either order. +

When using LIMIT, it is a good idea to use an + ORDER BY clause that constrains the result rows into a + unique order. Otherwise you will get an unpredictable subset of + the query's rows — you might be asking for the tenth through + twentieth rows, but tenth through twentieth in what ordering? You + don't know what ordering unless you specify ORDER BY. +

The query planner takes LIMIT into account when + generating a query plan, so you are very likely to get different + plans (yielding different row orders) depending on what you use + for LIMIT and OFFSET. Thus, using + different LIMIT/OFFSET values to select + different subsets of a query result will give + inconsistent results unless you enforce a predictable + result ordering with ORDER BY. This is not a bug; it + is an inherent consequence of the fact that SQL does not promise + to deliver the results of a query in any particular order unless + ORDER BY is used to constrain the order. +

It is even possible for repeated executions of the same LIMIT + query to return different subsets of the rows of a table, if there + is not an ORDER BY to enforce selection of a deterministic + subset. Again, this is not a bug; determinism of the results is + simply not guaranteed in such a case. +

FOR UPDATE/FOR SHARE Clause

The FOR UPDATE clause has this form: +

FOR UPDATE [ OF table_name [, ...] ] [ NOWAIT ]

+

The closely related FOR SHARE clause has this form: +

FOR SHARE [ OF table_name [, ...] ] [ NOWAIT ]

+

FOR UPDATE causes the rows retrieved by the + SELECT statement to be locked as though for + update. This prevents them from being modified or deleted by + other transactions until the current transaction ends. That is, + other transactions that attempt UPDATE, + DELETE, or SELECT FOR UPDATE + of these rows will be blocked until the current transaction ends. + Also, if an UPDATE, DELETE, + or SELECT FOR UPDATE from another transaction + has already locked a selected row or rows, SELECT FOR + UPDATE will wait for the other transaction to complete, + and will then lock and return the updated row (or no row, if the + row was deleted). Within a REPEATABLE READ or SERIALIZABLE transaction, + however, an error will be thrown if a row to be locked has changed + since the transaction started. For further discussion see Chapter 13. +

FOR SHARE behaves similarly, except that it + acquires a shared rather than exclusive lock on each retrieved + row. A shared lock blocks other transactions from performing + UPDATE, DELETE, or SELECT + FOR UPDATE on these rows, but it does not prevent them + from performing SELECT FOR SHARE. +

To prevent the operation from waiting for other transactions to commit, + use the NOWAIT option. With NOWAIT, the statement + reports an error, rather than waiting, if a selected row + cannot be locked immediately. Note that NOWAIT applies only + to the row-level lock(s) — the required ROW SHARE + table-level lock is still taken in the ordinary way (see + Chapter 13). You can use + LOCK + with the NOWAIT option first, + if you need to acquire the table-level lock without waiting. +

If specific tables are named in FOR UPDATE + or FOR SHARE, + then only rows coming from those tables are locked; any other + tables used in the SELECT are simply read as + usual. A FOR UPDATE or FOR SHARE + clause without a table list affects all tables used in the statement. + If FOR UPDATE or FOR SHARE is + applied to a view or sub-query, it affects all tables used in + the view or sub-query. + However, FOR UPDATE/FOR SHARE + do not apply to WITH queries referenced by the primary query. + If you want row locking to occur within a WITH query, specify + FOR UPDATE or FOR SHARE within the + WITH query. +

Multiple FOR UPDATE and FOR SHARE + clauses can be written if it is necessary to specify different locking + behavior for different tables. If the same table is mentioned (or + implicitly affected) by both FOR UPDATE and + FOR SHARE clauses, then it is processed as + FOR UPDATE. Similarly, a table is processed + as NOWAIT if that is specified in any of the clauses + affecting it. +

FOR UPDATE and FOR SHARE cannot be + used in contexts where returned rows cannot be clearly identified with + individual table rows; for example they cannot be used with aggregation. +

When FOR UPDATE or FOR SHARE + appears at the top level of a SELECT query, the rows that + are locked are exactly those that are returned by the query; in the + case of a join query, the rows locked are those that contribute to + returned join rows. In addition, rows that satisfied the query + conditions as of the query snapshot will be locked, although they + will not be returned if they were updated after the snapshot + and no longer satisfy the query conditions. If a + LIMIT is used, locking stops + once enough rows have been returned to satisfy the limit (but note that + rows skipped over by OFFSET will get locked). Similarly, + if FOR UPDATE or FOR SHARE + is used in a cursor's query, only rows actually fetched or stepped past + by the cursor will be locked. +

When FOR UPDATE or FOR SHARE + appears in a sub-SELECT, the rows locked are those + returned to the outer query by the sub-query. This might involve + fewer rows than inspection of the sub-query alone would suggest, + since conditions from the outer query might be used to optimize + execution of the sub-query. For example, +

SELECT * FROM (SELECT * FROM mytable FOR UPDATE) ss WHERE col1 = 5;

+ will lock only rows having col1 = 5, even though that + condition is not textually within the sub-query. +

Caution

Avoid locking a row and then modifying it within a later savepoint or + PL/pgSQL exception block. A subsequent + rollback would cause the lock to be lost. For example: +

BEGIN;
+SELECT * FROM mytable WHERE key = 1 FOR UPDATE;
+SAVEPOINT s;
+UPDATE mytable SET ... WHERE key = 1;
+ROLLBACK TO s;

+ After the ROLLBACK, the row is effectively unlocked, rather + than returned to its pre-savepoint state of being locked but not modified. + This hazard occurs if a row locked in the current transaction is updated + or deleted, or if a shared lock is upgraded to exclusive: in all these + cases, the former lock state is forgotten. If the transaction is then + rolled back to a state between the original locking command and the + subsequent change, the row will appear not to be locked at all. This is + an implementation deficiency which will be addressed in a future release + of PostgreSQL. +

Caution

It is possible for a SELECT command running at the READ + COMMITTED transaction isolation level and using ORDER + BY and FOR UPDATE/SHARE to return rows out of + order. This is because ORDER BY is applied first. + The command sorts the result, but might then block trying to obtain a lock + on one or more of the rows. Once the SELECT unblocks, some + of the ordering column values might have been modified, leading to those + rows appearing to be out of order (though they are in order in terms + of the original column values). This can be worked around at need by + placing the FOR UPDATE/SHARE clause in a sub-query, + for example +

SELECT * FROM (SELECT * FROM mytable FOR UPDATE) ss ORDER BY column1;

+ Note that this will result in locking all rows of mytable, + whereas FOR UPDATE at the top level would lock only the + actually returned rows. This can make for a significant performance + difference, particularly if the ORDER BY is combined with + LIMIT or other restrictions. So this technique is recommended + only if concurrent updates of the ordering columns are expected and a + strictly sorted result is required. +

At the REPEATABLE READ or SERIALIZABLE + transaction isolation level this would cause a serialization failure (with + a SQLSTATE of '40001'), so there is + no possibility of receiving rows out of order under these isolation levels. +

TABLE Command

The command +

TABLE name

+ is completely equivalent to +

SELECT * FROM name

+ It can be used as a top-level command or as a space-saving syntax + variant in parts of complex queries. +

Examples

To join the table films with the table + distributors: + +

SELECT f.title, f.did, d.name, f.date_prod, f.kind
+    FROM distributors d, films f
+    WHERE f.did = d.did
+
+       title       | did |     name     | date_prod  |   kind
+-------------------+-----+--------------+------------+----------
+ The Third Man     | 101 | British Lion | 1949-12-23 | Drama
+ The African Queen | 101 | British Lion | 1951-08-11 | Romantic
+ ...

+

To sum the column len of all films and group + the results by kind: + +

SELECT kind, sum(len) AS total FROM films GROUP BY kind;
+
+   kind   | total
+----------+-------
+ Action   | 07:34
+ Comedy   | 02:58
+ Drama    | 14:28
+ Musical  | 06:42
+ Romantic | 04:38

+

To sum the column len of all films, group + the results by kind and show those group totals + that are less than 5 hours: + +

SELECT kind, sum(len) AS total
+    FROM films
+    GROUP BY kind
+    HAVING sum(len) < interval '5 hours';
+
+   kind   | total
+----------+-------
+ Comedy   | 02:58
+ Romantic | 04:38

+

The following two examples are identical ways of sorting the individual + results according to the contents of the second column + (name): + +

SELECT * FROM distributors ORDER BY name;
+SELECT * FROM distributors ORDER BY 2;
+
+ did |       name
+-----+------------------
+ 109 | 20th Century Fox
+ 110 | Bavaria Atelier
+ 101 | British Lion
+ 107 | Columbia
+ 102 | Jean Luc Godard
+ 113 | Luso films
+ 104 | Mosfilm
+ 103 | Paramount
+ 106 | Toho
+ 105 | United Artists
+ 111 | Walt Disney
+ 112 | Warner Bros.
+ 108 | Westward

+

The next example shows how to obtain the union of the tables + distributors and + actors, restricting the results to those that begin + with the letter W in each table. Only distinct rows are wanted, so the + key word ALL is omitted. + +

distributors:               actors:
+ did |     name              id |     name
+-----+--------------        ----+----------------
+ 108 | Westward               1 | Woody Allen
+ 111 | Walt Disney            2 | Warren Beatty
+ 112 | Warner Bros.           3 | Walter Matthau
+ ...                         ...
+
+SELECT distributors.name
+    FROM distributors
+    WHERE distributors.name LIKE 'W%'
+UNION
+SELECT actors.name
+    FROM actors
+    WHERE actors.name LIKE 'W%';
+
+      name
+----------------
+ Walt Disney
+ Walter Matthau
+ Warner Bros.
+ Warren Beatty
+ Westward
+ Woody Allen

+

This example shows how to use a function in the FROM + clause, both with and without a column definition list: + +

CREATE FUNCTION distributors(int) RETURNS SETOF distributors AS $$
+    SELECT * FROM distributors WHERE did = $1;
+$$ LANGUAGE SQL;
+
+SELECT * FROM distributors(111);
+ did |    name
+-----+-------------
+ 111 | Walt Disney
+
+CREATE FUNCTION distributors_2(int) RETURNS SETOF record AS $$
+    SELECT * FROM distributors WHERE did = $1;
+$$ LANGUAGE SQL;
+
+SELECT * FROM distributors_2(111) AS (f1 int, f2 text);
+ f1  |     f2
+-----+-------------
+ 111 | Walt Disney

+

This example shows how to use a simple WITH clause: + +

WITH t AS (
+    SELECT random() as x FROM generate_series(1, 3)
+  )
+SELECT * FROM t
+UNION ALL
+SELECT * FROM t
+
+         x          
+--------------------
+  0.534150459803641
+  0.520092216785997
+ 0.0735620250925422
+  0.534150459803641
+  0.520092216785997
+ 0.0735620250925422

+ + Notice that the WITH query was evaluated only once, + so that we got two sets of the same three random values. +

This example uses WITH RECURSIVE to find all + subordinates (direct or indirect) of the employee Mary, and their + level of indirectness, from a table that shows only direct + subordinates: + +

WITH RECURSIVE employee_recursive(distance, employee_name, manager_name) AS (
+    SELECT 1, employee_name, manager_name
+    FROM employee
+    WHERE manager_name = 'Mary'
+  UNION ALL
+    SELECT er.distance + 1, e.employee_name, e.manager_name
+    FROM employee_recursive er, employee e
+    WHERE er.employee_name = e.manager_name
+  )
+SELECT distance, employee_name FROM employee_recursive;

+ + Notice the typical form of recursive queries: + an initial condition, followed by UNION, + followed by the recursive part of the query. Be sure that the + recursive part of the query will eventually return no tuples, or + else the query will loop indefinitely. (See Section 7.8 + for more examples.) +

Compatibility

Of course, the SELECT statement is compatible + with the SQL standard. But there are some extensions and some + missing features. +

Omitted FROM Clauses

PostgreSQL allows one to omit the + FROM clause. It has a straightforward use to + compute the results of simple expressions: +

SELECT 2+2;
+
+ ?column?
+----------
+        4

+ Some other SQL databases cannot do this except + by introducing a dummy one-row table from which to do the + SELECT. +

Note that if a FROM clause is not specified, + the query cannot reference any database tables. For example, the + following query is invalid: +

SELECT distributors.* WHERE distributors.name = 'Westward';

PostgreSQL releases prior to + 8.1 would accept queries of this form, and add an implicit entry + to the query's FROM clause for each table + referenced by the query. This is no longer allowed. +

Omitting the AS Key Word

In the SQL standard, the optional key word AS can be + omitted before an output column name whenever the new column name + is a valid column name (that is, not the same as any reserved + keyword). PostgreSQL is slightly more + restrictive: AS is required if the new column name + matches any keyword at all, reserved or not. Recommended practice is + to use AS or double-quote output column names, to prevent + any possible conflict against future keyword additions. +

In FROM items, both the standard and + PostgreSQL allow AS to + be omitted before an alias that is an unreserved keyword. But + this is impractical for output column names, because of syntactic + ambiguities. +

ONLY and Inheritance

The SQL standard requires parentheses around the table name when + writing ONLY, for example SELECT * FROM ONLY + (tab1), ONLY (tab2) WHERE .... PostgreSQL + considers these parentheses to be optional. +

PostgreSQL allows a trailing * to be written to + explicitly specify the non-ONLY behavior of including + child tables. The standard does not allow this. +

(These points apply equally to all SQL commands supporting the + ONLY option.) +

Namespace Available to GROUP BY and ORDER BY

In the SQL-92 standard, an ORDER BY clause can + only use output column names or numbers, while a GROUP + BY clause can only use expressions based on input column + names. PostgreSQL extends each of + these clauses to allow the other choice as well (but it uses the + standard's interpretation if there is ambiguity). + PostgreSQL also allows both clauses to + specify arbitrary expressions. Note that names appearing in an + expression will always be taken as input-column names, not as + output-column names. +

SQL:1999 and later use a slightly different definition which is not + entirely upward compatible with SQL-92. + In most cases, however, PostgreSQL + will interpret an ORDER BY or GROUP + BY expression the same way SQL:1999 does. +

Functional Dependencies

PostgreSQL recognizes functional dependency + (allowing columns to be omitted from GROUP BY) only when + a table's primary key is included in the GROUP BY list. + The SQL standard specifies additional conditions that should be + recognized. +

WINDOW Clause Restrictions

The SQL standard provides additional options for the window + frame_clause. + PostgreSQL currently supports only the + options listed above. +

LIMIT and OFFSET

The clauses LIMIT and OFFSET + are PostgreSQL-specific syntax, also + used by MySQL. The SQL:2008 standard + has introduced the clauses OFFSET ... FETCH {FIRST|NEXT} + ... for the same functionality, as shown above + in LIMIT Clause. This + syntax is also used by IBM DB2. + (Applications written for Oracle + frequently use a workaround involving the automatically + generated rownum column, which is not available in + PostgreSQL, to implement the effects of these clauses.) +

FOR UPDATE and FOR SHARE

Although FOR UPDATE appears in the SQL standard, the + standard allows it only as an option of DECLARE CURSOR. + PostgreSQL allows it in any SELECT + query as well as in sub-SELECTs, but this is an extension. + The FOR SHARE variant, and the NOWAIT option, + do not appear in the standard. +

Data-Modifying Statements in WITH

PostgreSQL allows INSERT, + UPDATE, and DELETE to be used as WITH + queries. This is not found in the SQL standard. +

Nonstandard Clauses

The clause DISTINCT ON is not defined in the + SQL standard. +


PrevHomeNext
SECURITY LABELUpSELECT INTO
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-selectinto.html b/doc/src/sgml/html/sql-selectinto.html new file mode 100644 index 000000000..16f922716 --- /dev/null +++ b/doc/src/sgml/html/sql-selectinto.html @@ -0,0 +1,517 @@ + +SELECT INTO

SELECT INTO

Name

SELECT INTO -- define a new table from the results of a query

Synopsis

[ WITH [ RECURSIVE ] with_query [, ...] ]
+SELECT [ ALL | DISTINCT [ ON ( expression [, ...] ) ] ]
+    * | expression [ [ AS ] output_name ] [, ...]
+    INTO [ TEMPORARY | TEMP | UNLOGGED ] [ TABLE ] new_table
+    [ FROM from_item [, ...] ]
+    [ WHERE condition ]
+    [ GROUP BY expression [, ...] ]
+    [ HAVING condition [, ...] ]
+    [ WINDOW window_name AS ( window_definition ) [, ...] ]
+    [ { UNION | INTERSECT | EXCEPT } [ ALL | DISTINCT ] select ]
+    [ ORDER BY expression [ ASC | DESC | USING operator ] [ NULLS { FIRST | LAST } ] [, ...] ]
+    [ LIMIT { count | ALL } ]
+    [ OFFSET start [ ROW | ROWS ] ]
+    [ FETCH { FIRST | NEXT } [ count ] { ROW | ROWS } ONLY ]
+    [ FOR { UPDATE | SHARE } [ OF table_name [, ...] ] [ NOWAIT ] [...] ]

Description

SELECT INTO creates a new table and fills it + with data computed by a query. The data is not returned to the + client, as it is with a normal SELECT. The new + table's columns have the names and data types associated with the + output columns of the SELECT. +

Parameters

TEMPORARY or TEMP

If specified, the table is created as a temporary table. Refer + to CREATE TABLE for details. +

UNLOGGED

If specified, the table is created as an unlogged table. Refer + to CREATE TABLE for details. +

new_table

The name (optionally schema-qualified) of the table to be created. +

All other parameters are described in detail under SELECT. +

Notes

CREATE TABLE AS is functionally similar to + SELECT INTO. CREATE TABLE AS + is the recommended syntax, since this form of SELECT + INTO is not available in ECPG + or PL/pgSQL, because they interpret the + INTO clause differently. Furthermore, + CREATE TABLE AS offers a superset of the + functionality provided by SELECT INTO. +

Prior to PostgreSQL 8.1, the table created by + SELECT INTO included OIDs by default. In + PostgreSQL 8.1, this is not the case + — to include OIDs in the new table, the default_with_oids configuration variable must be + enabled. Alternatively, CREATE TABLE AS can be + used with the WITH OIDS clause. +

Examples

Create a new table films_recent consisting of only + recent entries from the table films: + +

SELECT * INTO films_recent FROM films WHERE date_prod >= '2002-01-01';

Compatibility

The SQL standard uses SELECT INTO to + represent selecting values into scalar variables of a host program, + rather than creating a new table. This indeed is the usage found + in ECPG (see Chapter 33) and + PL/pgSQL (see Chapter 39). + The PostgreSQL usage of SELECT + INTO to represent table creation is historical. It is + best to use CREATE TABLE AS for this purpose in + new code. +

\ No newline at end of file diff --git a/doc/src/sgml/html/sql-set-constraints.html b/doc/src/sgml/html/sql-set-constraints.html new file mode 100644 index 000000000..591d027ba --- /dev/null +++ b/doc/src/sgml/html/sql-set-constraints.html @@ -0,0 +1,396 @@ + +SET CONSTRAINTS

SET CONSTRAINTS

Name

SET CONSTRAINTS -- set constraint check timing for the current transaction

Synopsis

SET CONSTRAINTS { ALL | name [, ...] } { DEFERRED | IMMEDIATE }

Description

SET CONSTRAINTS sets the behavior of constraint + checking within the current transaction. IMMEDIATE + constraints are checked at the end of each + statement. DEFERRED constraints are not checked until + transaction commit. Each constraint has its own + IMMEDIATE or DEFERRED mode. +

Upon creation, a constraint is given one of three + characteristics: DEFERRABLE INITIALLY DEFERRED, + DEFERRABLE INITIALLY IMMEDIATE, or + NOT DEFERRABLE. The third + class is always IMMEDIATE and is not affected by the + SET CONSTRAINTS command. The first two classes start + every transaction in the indicated mode, but their behavior can be changed + within a transaction by SET CONSTRAINTS. +

SET CONSTRAINTS with a list of constraint names changes + the mode of just those constraints (which must all be deferrable). Each + constraint name can be schema-qualified. The + current schema search path is used to find the first matching name if + no schema name is specified. SET CONSTRAINTS ALL + changes the mode of all deferrable constraints. +

When SET CONSTRAINTS changes the mode of a constraint + from DEFERRED + to IMMEDIATE, the new mode takes effect + retroactively: any outstanding data modifications that would have + been checked at the end of the transaction are instead checked during the + execution of the SET CONSTRAINTS command. + If any such constraint is violated, the SET CONSTRAINTS + fails (and does not change the constraint mode). Thus, SET + CONSTRAINTS can be used to force checking of constraints to + occur at a specific point in a transaction. +

Currently, only UNIQUE, PRIMARY KEY, + REFERENCES (foreign key), and EXCLUDE + constraints are affected by this setting. + NOT NULL and CHECK constraints are + always checked immediately when a row is inserted or modified + (not at the end of the statement). + Uniqueness and exclusion constraints that have not been declared + DEFERRABLE are also checked immediately. +

The firing of triggers that are declared as "constraint triggers" + is also controlled by this setting — they fire at the same time + that the associated constraint should be checked. +

Notes

Because PostgreSQL does not require constraint + names to be unique within a schema (but only per-table), it is possible + that there is more than one match for a specified constraint name. + In this case SET CONSTRAINTS will act on all matches. + For a non-schema-qualified name, once a match or matches have been found in + some schema in the search path, schemas appearing later in the path are not + searched. +

This command only alters the behavior of constraints within the + current transaction. Thus, if you execute this command outside of a + transaction block + (BEGIN/COMMIT pair), it will + not appear to have any effect. +

Compatibility

This command complies with the behavior defined in the SQL + standard, except for the limitation that, in + PostgreSQL, it does not apply to + NOT NULL and CHECK constraints. + Also, PostgreSQL checks non-deferrable + uniqueness constraints immediately, not at end of statement as the + standard would suggest. +


PrevHomeNext
SETUpSET ROLE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-set-role.html b/doc/src/sgml/html/sql-set-role.html new file mode 100644 index 000000000..80fe5be1f --- /dev/null +++ b/doc/src/sgml/html/sql-set-role.html @@ -0,0 +1,408 @@ + +SET ROLE

SET ROLE

Name

SET ROLE -- set the current user identifier of the current session

Synopsis

SET [ SESSION | LOCAL ] ROLE role_name
+SET [ SESSION | LOCAL ] ROLE NONE
+RESET ROLE

Description

This command sets the current user + identifier of the current SQL session to be role_name. The role name can be + written as either an identifier or a string literal. + After SET ROLE, permissions checking for SQL commands + is carried out as though the named role were the one that had logged + in originally. +

The specified role_name + must be a role that the current session user is a member of. + (If the session user is a superuser, any role can be selected.) +

The SESSION and LOCAL modifiers act the same + as for the regular SET + command. +

The NONE and RESET forms reset the current + user identifier to be the current session user identifier. + These forms can be executed by any user. +

Notes

Using this command, it is possible to either add privileges or restrict + one's privileges. If the session user role has the INHERITS + attribute, then it automatically has all the privileges of every role that + it could SET ROLE to; in this case SET ROLE + effectively drops all the privileges assigned directly to the session user + and to the other roles it is a member of, leaving only the privileges + available to the named role. On the other hand, if the session user role + has the NOINHERITS attribute, SET ROLE drops the + privileges assigned directly to the session user and instead acquires the + privileges available to the named role. +

In particular, when a superuser chooses to SET ROLE to a + non-superuser role, she loses her superuser privileges. +

SET ROLE has effects comparable to + SET SESSION AUTHORIZATION, but the privilege + checks involved are quite different. Also, + SET SESSION AUTHORIZATION determines which roles are + allowable for later SET ROLE commands, whereas changing + roles with SET ROLE does not change the set of roles + allowed to a later SET ROLE. +

SET ROLE does not process session variables as specified by + the role's ALTER ROLE settings; this only happens during + login. +

SET ROLE cannot be used within a + SECURITY DEFINER function. +

Examples

SELECT SESSION_USER, CURRENT_USER;
+
+ session_user | current_user 
+--------------+--------------
+ peter        | peter
+
+SET ROLE 'paul';
+
+SELECT SESSION_USER, CURRENT_USER;
+
+ session_user | current_user 
+--------------+--------------
+ peter        | paul

Compatibility

PostgreSQL + allows identifier syntax ("rolename"), while + the SQL standard requires the role name to be written as a string + literal. SQL does not allow this command during a transaction; + PostgreSQL does not make this + restriction because there is no reason to. + The SESSION and LOCAL modifiers are a + PostgreSQL extension, as is the + RESET syntax. +


PrevHomeNext
SET CONSTRAINTSUpSET SESSION AUTHORIZATION
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-set-session-authorization.html b/doc/src/sgml/html/sql-set-session-authorization.html new file mode 100644 index 000000000..42a8a3eaa --- /dev/null +++ b/doc/src/sgml/html/sql-set-session-authorization.html @@ -0,0 +1,356 @@ + +SET SESSION AUTHORIZATION

SET SESSION AUTHORIZATION

Name

SET SESSION AUTHORIZATION -- set the session user identifier and the current user identifier of the current session

Synopsis

SET [ SESSION | LOCAL ] SESSION AUTHORIZATION user_name
+SET [ SESSION | LOCAL ] SESSION AUTHORIZATION DEFAULT
+RESET SESSION AUTHORIZATION

Description

This command sets the session user identifier and the current user + identifier of the current SQL session to be user_name. The user name can be + written as either an identifier or a string literal. Using this + command, it is possible, for example, to temporarily become an + unprivileged user and later switch back to being a superuser. +

The session user identifier is initially set to be the (possibly + authenticated) user name provided by the client. The current user + identifier is normally equal to the session user identifier, but + might change temporarily in the context of SECURITY DEFINER + functions and similar mechanisms; it can also be changed by + SET ROLE. + The current user identifier is relevant for permission checking. +

The session user identifier can be changed only if the initial session + user (the authenticated user) had the + superuser privilege. Otherwise, the command is accepted only if it + specifies the authenticated user name. +

The SESSION and LOCAL modifiers act the same + as for the regular SET + command. +

The DEFAULT and RESET forms reset the session + and current user identifiers to be the originally authenticated user + name. These forms can be executed by any user. +

Notes

SET SESSION AUTHORIZATION cannot be used within a + SECURITY DEFINER function. +

Examples

SELECT SESSION_USER, CURRENT_USER;
+
+ session_user | current_user 
+--------------+--------------
+ peter        | peter
+
+SET SESSION AUTHORIZATION 'paul';
+
+SELECT SESSION_USER, CURRENT_USER;
+
+ session_user | current_user 
+--------------+--------------
+ paul         | paul

Compatibility

The SQL standard allows some other expressions to appear in place + of the literal user_name, but these options + are not important in practice. PostgreSQL + allows identifier syntax ("username"), which SQL + does not. SQL does not allow this command during a transaction; + PostgreSQL does not make this + restriction because there is no reason to. + The SESSION and LOCAL modifiers are a + PostgreSQL extension, as is the + RESET syntax. +

The privileges necessary to execute this command are left + implementation-defined by the standard. +

See Also

SET ROLE

PrevHomeNext
SET ROLEUpSET TRANSACTION
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-set-transaction.html b/doc/src/sgml/html/sql-set-transaction.html new file mode 100644 index 000000000..edae5a4ef --- /dev/null +++ b/doc/src/sgml/html/sql-set-transaction.html @@ -0,0 +1,677 @@ + +SET TRANSACTION

SET TRANSACTION

Name

SET TRANSACTION -- set the characteristics of the current transaction

Synopsis

SET TRANSACTION transaction_mode [, ...]
+SET TRANSACTION SNAPSHOT snapshot_id
+SET SESSION CHARACTERISTICS AS TRANSACTION transaction_mode [, ...]
+
+where transaction_mode is one of:
+
+    ISOLATION LEVEL { SERIALIZABLE | REPEATABLE READ | READ COMMITTED | READ UNCOMMITTED }
+    READ WRITE | READ ONLY
+    [ NOT ] DEFERRABLE

Description

The SET TRANSACTION command sets the + characteristics of the current transaction. It has no effect on any + subsequent transactions. SET SESSION + CHARACTERISTICS sets the default transaction + characteristics for subsequent transactions of a session. These + defaults can be overridden by SET TRANSACTION + for an individual transaction. +

The available transaction characteristics are the transaction + isolation level, the transaction access mode (read/write or + read-only), and the deferrable mode. + In addition, a snapshot can be selected, though only for the current + transaction, not as a session default. +

The isolation level of a transaction determines what data the + transaction can see when other transactions are running concurrently: + +

READ COMMITTED

A statement can only see rows committed before it began. This + is the default. +

REPEATABLE READ

All statements of the current transaction can only see rows committed + before the first query or data-modification statement was executed in + this transaction. +

SERIALIZABLE

All statements of the current transaction can only see rows committed + before the first query or data-modification statement was executed in + this transaction. If a pattern of reads and writes among concurrent + serializable transactions would create a situation which could not + have occurred for any serial (one-at-a-time) execution of those + transactions, one of them will be rolled back with a + serialization_failure error. +

+ + The SQL standard defines one additional level, READ + UNCOMMITTED. + In PostgreSQL READ + UNCOMMITTED is treated as READ COMMITTED. +

The transaction isolation level cannot be changed after the first query or + data-modification statement (SELECT, + INSERT, DELETE, + UPDATE, FETCH, or + COPY) of a transaction has been executed. See + Chapter 13 for more information about transaction + isolation and concurrency control. +

The transaction access mode determines whether the transaction is + read/write or read-only. Read/write is the default. When a + transaction is read-only, the following SQL commands are + disallowed: INSERT, UPDATE, + DELETE, and COPY FROM if the + table they would write to is not a temporary table; all + CREATE, ALTER, and + DROP commands; COMMENT, + GRANT, REVOKE, + TRUNCATE; and EXPLAIN ANALYZE + and EXECUTE if the command they would execute is + among those listed. This is a high-level notion of read-only that + does not prevent all writes to disk. +

The DEFERRABLE transaction property has no effect + unless the transaction is also SERIALIZABLE and + READ ONLY. When all three of these properties are + selected for a + transaction, the transaction may block when first acquiring its snapshot, + after which it is able to run without the normal overhead of a + SERIALIZABLE transaction and without any risk of + contributing to or being canceled by a serialization failure. This mode + is well suited for long-running reports or backups. +

The SET TRANSACTION SNAPSHOT command allows a new + transaction to run with the same snapshot as an existing + transaction. The pre-existing transaction must have exported its snapshot + with the pg_export_snapshot function (see Section 9.26.5). That function returns a + snapshot identifier, which must be given to SET TRANSACTION + SNAPSHOT to specify which snapshot is to be imported. The + identifier must be written as a string literal in this command, for example + '000003A1-1'. + SET TRANSACTION SNAPSHOT can only be executed at the + start of a transaction, before the first query or + data-modification statement (SELECT, + INSERT, DELETE, + UPDATE, FETCH, or + COPY) of the transaction. Furthermore, the transaction + must already be set to SERIALIZABLE or + REPEATABLE READ isolation level (otherwise, the snapshot + would be discarded immediately, since READ COMMITTED mode takes + a new snapshot for each command). If the importing transaction uses + SERIALIZABLE isolation level, then the transaction that + exported the snapshot must also use that isolation level. Also, a + non-read-only serializable transaction cannot import a snapshot from a + read-only transaction. +

Notes

If SET TRANSACTION is executed without a prior + START TRANSACTION or BEGIN, + it will appear to have no effect, since the transaction will immediately + end. +

It is possible to dispense with SET TRANSACTION + by instead specifying the desired transaction_modes in + BEGIN or START TRANSACTION. + But that option is not available for SET TRANSACTION + SNAPSHOT. +

The session default transaction modes can also be set by setting the + configuration parameters default_transaction_isolation, + default_transaction_read_only, and + default_transaction_deferrable. + (In fact SET SESSION CHARACTERISTICS is just a + verbose equivalent for setting these variables with SET.) + This means the defaults can be set in the configuration file, via + ALTER DATABASE, etc. Consult Chapter 18 + for more information. +

Examples

To begin a new transaction with the same snapshot as an already + existing transaction, first export the snapshot from the existing + transaction. That will return the snapshot identifier, for example: + +

BEGIN TRANSACTION ISOLATION LEVEL REPEATABLE READ;
+SELECT pg_export_snapshot();
+ pg_export_snapshot
+--------------------
+ 000003A1-1
+(1 row)

+ + Then give the snapshot identifier in a SET TRANSACTION + SNAPSHOT command at the beginning of the newly opened + transaction: + +

BEGIN TRANSACTION ISOLATION LEVEL REPEATABLE READ;
+SET TRANSACTION SNAPSHOT '000003A1-1';

Compatibility

These commands are defined in the SQL standard, + except for the DEFERRABLE transaction mode + and the SET TRANSACTION SNAPSHOT form, which are + PostgreSQL extensions. +

SERIALIZABLE is the default transaction + isolation level in the standard. In + PostgreSQL the default is ordinarily + READ COMMITTED, but you can change it as + mentioned above. +

In the SQL standard, there is one other transaction characteristic + that can be set with these commands: the size of the diagnostics + area. This concept is specific to embedded SQL, and therefore is + not implemented in the PostgreSQL server. +

The SQL standard requires commas between successive transaction_modes, but for historical + reasons PostgreSQL allows the commas to be + omitted. +


PrevHomeNext
SET SESSION AUTHORIZATIONUpSHOW
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-set.html b/doc/src/sgml/html/sql-set.html new file mode 100644 index 000000000..dff77b06e --- /dev/null +++ b/doc/src/sgml/html/sql-set.html @@ -0,0 +1,773 @@ + +SET

SET

Name

SET -- change a run-time parameter

Synopsis

SET [ SESSION | LOCAL ] configuration_parameter { TO | = } { value | 'value' | DEFAULT }
+SET [ SESSION | LOCAL ] TIME ZONE { timezone | LOCAL | DEFAULT }

Description

The SET command changes run-time configuration + parameters. Many of the run-time parameters listed in + Chapter 18 can be changed on-the-fly with + SET. + (But some require superuser privileges to change, and others cannot + be changed after server or session start.) + SET only affects the value used by the current + session. +

If SET (or equivalently SET SESSION) + is issued within a transaction that is later aborted, the effects of the + SET command disappear when the transaction is rolled + back. Once the surrounding transaction is committed, the effects + will persist until the end of the session, unless overridden by another + SET. +

The effects of SET LOCAL last only till the end of + the current transaction, whether committed or not. A special case is + SET followed by SET LOCAL within + a single transaction: the SET LOCAL value will be + seen until the end of the transaction, but afterwards (if the transaction + is committed) the SET value will take effect. +

The effects of SET or SET LOCAL are + also canceled by rolling back to a savepoint that is earlier than the + command. +

If SET LOCAL is used within a function that has a + SET option for the same variable (see + CREATE FUNCTION), + the effects of the SET LOCAL command disappear at + function exit; that is, the value in effect when the function was called is + restored anyway. This allows SET LOCAL to be used for + dynamic or repeated changes of a parameter within a function, while still + having the convenience of using the SET option to save and + restore the caller's value. However, a regular SET command + overrides any surrounding function's SET option; its effects + will persist unless rolled back. +

Note: In PostgreSQL versions 8.0 through 8.2, + the effects of a SET LOCAL would be canceled by + releasing an earlier savepoint, or by successful exit from a + PL/pgSQL exception block. This behavior + has been changed because it was deemed unintuitive. +

Parameters

SESSION

Specifies that the command takes effect for the current session. + (This is the default if neither SESSION nor + LOCAL appears.) +

LOCAL

Specifies that the command takes effect for only the current + transaction. After COMMIT or ROLLBACK, + the session-level setting takes effect again. Note that + SET LOCAL will appear to have no effect if it is + executed outside a BEGIN block, since the + transaction will end immediately. +

configuration_parameter

Name of a settable run-time parameter. Available parameters are + documented in Chapter 18 and below. +

value

New value of parameter. Values can be specified as string + constants, identifiers, numbers, or comma-separated lists of + these, as appropriate for the particular parameter. + DEFAULT can be written to specify + resetting the parameter to its default value (that is, whatever + value it would have had if no SET had been executed + in the current session). +

Besides the configuration parameters documented in Chapter 18, there are a few that can only be + adjusted using the SET command or that have a + special syntax: + +

SCHEMA

SET SCHEMA 'value' is an alias for + SET search_path TO value. Only one + schema can be specified using this syntax. +

NAMES

SET NAMES value is an alias for + SET client_encoding TO value. +

SEED

Sets the internal seed for the random number generator (the + function random). Allowed values are + floating-point numbers between -1 and 1, which are then + multiplied by 231-1. +

The seed can also be set by invoking the function + setseed: +

SELECT setseed(value);

TIME ZONE

SET TIME ZONE value is an alias + for SET timezone TO value. The + syntax SET TIME ZONE allows special syntax + for the time zone specification. Here are examples of valid + values: + +

'PST8PDT'

The time zone for Berkeley, California. +

'Europe/Rome'

The time zone for Italy. +

-7

The time zone 7 hours west from UTC (equivalent + to PDT). Positive values are east from UTC. +

INTERVAL '-08:00' HOUR TO MINUTE

The time zone 8 hours west from UTC (equivalent + to PST). +

LOCAL
DEFAULT

Set the time zone to your local time zone (that is, the + server's default value of timezone). +

+ + See Section 8.5.3 for more information + about time zones. +

+

Notes

The function set_config provides equivalent + functionality; see Section 9.26. + Also, it is possible to UPDATE the + pg_settings + system view to perform the equivalent of SET. +

Examples

Set the schema search path: +

SET search_path TO my_schema, public;

+

Set the style of date to traditional + POSTGRES with "day before month" + input convention: +

SET datestyle TO postgres, dmy;

+

Set the time zone for Berkeley, California: +

SET TIME ZONE 'PST8PDT';

+

Set the time zone for Italy: +

SET TIME ZONE 'Europe/Rome';

Compatibility

SET TIME ZONE extends syntax defined in the SQL + standard. The standard allows only numeric time zone offsets while + PostgreSQL allows more flexible + time-zone specifications. All other SET + features are PostgreSQL extensions. +

See Also

RESET, SHOW

PrevHomeNext
SELECT INTOUpSET CONSTRAINTS
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-show.html b/doc/src/sgml/html/sql-show.html new file mode 100644 index 000000000..f230ab284 --- /dev/null +++ b/doc/src/sgml/html/sql-show.html @@ -0,0 +1,450 @@ + +SHOW

SHOW

Name

SHOW -- show the value of a run-time parameter

Synopsis

SHOW name
+SHOW ALL

Description

SHOW will display the current setting of + run-time parameters. These variables can be set using the + SET statement, by editing the + postgresql.conf configuration file, through + the PGOPTIONS environmental variable (when using + libpq or a libpq-based + application), or through command-line flags when starting the + postgres server. See Chapter 18 for details. +

Parameters

name

The name of a run-time parameter. Available parameters are + documented in Chapter 18 and on the SET reference page. In + addition, there are a few parameters that can be shown but not + set: + +

SERVER_VERSION

Shows the server's version number. +

SERVER_ENCODING

Shows the server-side character set encoding. At present, + this parameter can be shown but not set, because the + encoding is determined at database creation time. +

LC_COLLATE

Shows the database's locale setting for collation (text + ordering). At present, this parameter can be shown but not + set, because the setting is determined at database creation + time. +

LC_CTYPE

Shows the database's locale setting for character + classification. At present, this parameter can be shown but + not set, because the setting is determined at database creation + time. +

IS_SUPERUSER

True if the current role has superuser privileges. +

ALL

Show the values of all configuration parameters, with descriptions. +

Notes

The function current_setting produces + equivalent output; see Section 9.26. + Also, the + pg_settings + system view produces the same information. + +

Examples

Show the current setting of the parameter DateStyle: + +

SHOW DateStyle;
+ DateStyle
+-----------
+ ISO, MDY
+(1 row)

+

Show the current setting of the parameter geqo: +

SHOW geqo;
+ geqo
+------
+ on
+(1 row)

+

Show all settings: +

SHOW ALL;
+            name         | setting |                description                                                          
+-------------------------+---------+-------------------------------------------------
+ allow_system_table_mods | off     | Allows modifications of the structure of ...
+    .
+    .
+    .
+ xmloption               | content | Sets whether XML data in implicit parsing ...
+ zero_damaged_pages      | off     | Continues processing past damaged page headers.
+(196 rows)

Compatibility

The SHOW command is a + PostgreSQL extension. +

See Also

SET, RESET

PrevHomeNext
SET TRANSACTIONUpSTART TRANSACTION
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-start-transaction.html b/doc/src/sgml/html/sql-start-transaction.html new file mode 100644 index 000000000..6eeee4051 --- /dev/null +++ b/doc/src/sgml/html/sql-start-transaction.html @@ -0,0 +1,329 @@ + +START TRANSACTION

START TRANSACTION

Name

START TRANSACTION -- start a transaction block

Synopsis

START TRANSACTION [ transaction_mode [, ...] ]
+
+where transaction_mode is one of:
+
+    ISOLATION LEVEL { SERIALIZABLE | REPEATABLE READ | READ COMMITTED | READ UNCOMMITTED }
+    READ WRITE | READ ONLY
+    [ NOT ] DEFERRABLE

Description

This command begins a new transaction block. If the isolation level, + read/write mode, or deferrable mode is specified, the new transaction has those + characteristics, as if SET TRANSACTION was executed. This is the same + as the BEGIN command. +

Parameters

Refer to SET TRANSACTION for information on the meaning + of the parameters to this statement. +

Compatibility

In the standard, it is not necessary to issue START TRANSACTION + to start a transaction block: any SQL command implicitly begins a block. + PostgreSQL's behavior can be seen as implicitly + issuing a COMMIT after each command that does not + follow START TRANSACTION (or BEGIN), + and it is therefore often called "autocommit". + Other relational database systems might offer an autocommit feature + as a convenience. +

The DEFERRABLE + transaction_mode + is a PostgreSQL language extension. +

The SQL standard requires commas between successive transaction_modes, but for historical + reasons PostgreSQL allows the commas to be + omitted. +

See also the compatibility section of SET TRANSACTION. +


PrevHomeNext
SHOWUpTRUNCATE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-syntax-calling-funcs.html b/doc/src/sgml/html/sql-syntax-calling-funcs.html new file mode 100644 index 000000000..01d311196 --- /dev/null +++ b/doc/src/sgml/html/sql-syntax-calling-funcs.html @@ -0,0 +1,393 @@ + +Calling Functions

4.3. Calling Functions

PostgreSQL allows functions that have named + parameters to be called using either positional or + named notation. Named notation is especially + useful for functions that have a large number of parameters, since it + makes the associations between parameters and actual arguments more + explicit and reliable. + In positional notation, a function call is written with + its argument values in the same order as they are defined in the function + declaration. In named notation, the arguments are matched to the + function parameters by name and can be written in any order. +

In either notation, parameters that have default values given in the + function declaration need not be written in the call at all. But this + is particularly useful in named notation, since any combination of + parameters can be omitted; while in positional notation parameters can + only be omitted from right to left. +

PostgreSQL also supports + mixed notation, which combines positional and + named notation. In this case, positional parameters are written first + and named parameters appear after them. +

The following examples will illustrate the usage of all three + notations, using the following function definition: +

CREATE FUNCTION concat_lower_or_upper(a text, b text, uppercase boolean DEFAULT false)
+RETURNS text
+AS
+$$
+ SELECT CASE
+        WHEN $3 THEN UPPER($1 || ' ' || $2)
+        ELSE LOWER($1 || ' ' || $2)
+        END;
+$$
+LANGUAGE SQL IMMUTABLE STRICT;

+ Function concat_lower_or_upper has two mandatory + parameters, a and b. Additionally + there is one optional parameter uppercase which defaults + to false. The a and + b inputs will be concatenated, and forced to either + upper or lower case depending on the uppercase + parameter. The remaining details of this function + definition are not important here (see Chapter 35 for + more information). +

4.3.1. Using Positional Notation

Positional notation is the traditional mechanism for passing arguments + to functions in PostgreSQL. An example is: +

SELECT concat_lower_or_upper('Hello', 'World', true);
+ concat_lower_or_upper 
+-----------------------
+ HELLO WORLD
+(1 row)

+ All arguments are specified in order. The result is upper case since + uppercase is specified as true. + Another example is: +

SELECT concat_lower_or_upper('Hello', 'World');
+ concat_lower_or_upper 
+-----------------------
+ hello world
+(1 row)

+ Here, the uppercase parameter is omitted, so it + receives its default value of false, resulting in + lower case output. In positional notation, arguments can be omitted + from right to left so long as they have defaults. +

4.3.2. Using Named Notation

In named notation, each argument's name is specified using + := to separate it from the argument expression. + For example: +

SELECT concat_lower_or_upper(a := 'Hello', b := 'World');
+ concat_lower_or_upper 
+-----------------------
+ hello world
+(1 row)

+ Again, the argument uppercase was omitted + so it is set to false implicitly. One advantage of + using named notation is that the arguments may be specified in any + order, for example: +

SELECT concat_lower_or_upper(a := 'Hello', b := 'World', uppercase := true);
+ concat_lower_or_upper 
+-----------------------
+ HELLO WORLD
+(1 row)
+
+SELECT concat_lower_or_upper(a := 'Hello', uppercase := true, b := 'World');
+ concat_lower_or_upper 
+-----------------------
+ HELLO WORLD
+(1 row)

+

4.3.3. Using Mixed Notation

The mixed notation combines positional and named notation. However, as + already mentioned, named arguments cannot precede positional arguments. + For example: +

SELECT concat_lower_or_upper('Hello', 'World', uppercase := true);
+ concat_lower_or_upper 
+-----------------------
+ HELLO WORLD
+(1 row)

+ In the above query, the arguments a and + b are specified positionally, while + uppercase is specified by name. In this example, + that adds little except documentation. With a more complex function + having numerous parameters that have default values, named or mixed + notation can save a great deal of writing and reduce chances for error. +


PrevHomeNext
Value ExpressionsUpData Definition
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-syntax-lexical.html b/doc/src/sgml/html/sql-syntax-lexical.html new file mode 100644 index 000000000..539f3fadf --- /dev/null +++ b/doc/src/sgml/html/sql-syntax-lexical.html @@ -0,0 +1,2223 @@ + +Lexical Structure

4.1. Lexical Structure

SQL input consists of a sequence of + commands. A command is composed of a + sequence of tokens, terminated by a + semicolon (";"). The end of the input stream also + terminates a command. Which tokens are valid depends on the syntax + of the particular command. +

A token can be a key word, an + identifier, a quoted + identifier, a literal (or + constant), or a special character symbol. Tokens are normally + separated by whitespace (space, tab, newline), but need not be if + there is no ambiguity (which is generally only the case if a + special character is adjacent to some other token type). +

For example, the following is (syntactically) valid SQL input: +

SELECT * FROM MY_TABLE;
+UPDATE MY_TABLE SET A = 5;
+INSERT INTO MY_TABLE VALUES (3, 'hi there');

+ This is a sequence of three commands, one per line (although this + is not required; more than one command can be on a line, and + commands can usefully be split across lines). +

Additionally, comments can occur in SQL + input. They are not tokens, they are effectively equivalent to + whitespace. +

The SQL syntax is not very consistent regarding what tokens + identify commands and which are operands or parameters. The first + few tokens are generally the command name, so in the above example + we would usually speak of a "SELECT", an + "UPDATE", and an "INSERT" command. But + for instance the UPDATE command always requires + a SET token to appear in a certain position, and + this particular variation of INSERT also + requires a VALUES in order to be complete. The + precise syntax rules for each command are described in Part VI. +

4.1.1. Identifiers and Key Words

Tokens such as SELECT, UPDATE, or + VALUES in the example above are examples of + key words, that is, words that have a fixed + meaning in the SQL language. The tokens MY_TABLE + and A are examples of + identifiers. They identify names of + tables, columns, or other database objects, depending on the + command they are used in. Therefore they are sometimes simply + called "names". Key words and identifiers have the + same lexical structure, meaning that one cannot know whether a + token is an identifier or a key word without knowing the language. + A complete list of key words can be found in Appendix C. +

SQL identifiers and key words must begin with a letter + (a-z, but also letters with + diacritical marks and non-Latin letters) or an underscore + (_). Subsequent characters in an identifier or + key word can be letters, underscores, digits + (0-9), or dollar signs + ($). Note that dollar signs are not allowed in identifiers + according to the letter of the SQL standard, so their use might render + applications less portable. + The SQL standard will not define a key word that contains + digits or starts or ends with an underscore, so identifiers of this + form are safe against possible conflict with future extensions of the + standard. +

+ The system uses no more than NAMEDATALEN-1 + bytes of an identifier; longer names can be written in + commands, but they will be truncated. By default, + NAMEDATALEN is 64 so the maximum identifier + length is 63 bytes. If this limit is problematic, it can be raised by + changing the NAMEDATALEN constant in + src/include/pg_config_manual.h. +

+ Key words and unquoted identifiers are case insensitive. Therefore: +

UPDATE MY_TABLE SET A = 5;

+ can equivalently be written as: +

uPDaTE my_TabLE SeT a = 5;

+ A convention often used is to write key words in upper + case and names in lower case, e.g.: +

UPDATE my_table SET a = 5;

+

+ There is a second kind of identifier: the delimited + identifier or quoted + identifier. It is formed by enclosing an arbitrary + sequence of characters in double-quotes + ("). A delimited + identifier is always an identifier, never a key word. So + "select" could be used to refer to a column or + table named "select", whereas an unquoted + select would be taken as a key word and + would therefore provoke a parse error when used where a table or + column name is expected. The example can be written with quoted + identifiers like this: +

UPDATE "my_table" SET "a" = 5;

+

Quoted identifiers can contain any character, except the character + with code zero. (To include a double quote, write two double quotes.) + This allows constructing table or column names that would + otherwise not be possible, such as ones containing spaces or + ampersands. The length limitation still applies. +

A variant of quoted + identifiers allows including escaped Unicode characters identified + by their code points. This variant starts + with U& (upper or lower case U followed by + ampersand) immediately before the opening double quote, without + any spaces in between, for example U&"foo". + (Note that this creates an ambiguity with the + operator &. Use spaces around the operator to + avoid this problem.) Inside the quotes, Unicode characters can be + specified in escaped form by writing a backslash followed by the + four-digit hexadecimal code point number or alternatively a + backslash followed by a plus sign followed by a six-digit + hexadecimal code point number. For example, the + identifier "data" could be written as +

U&"d\0061t\+000061"

+ The following less trivial example writes the Russian + word "slon" (elephant) in Cyrillic letters: +

U&"\0441\043B\043E\043D"

+

If a different escape character than backslash is desired, it can + be specified using + the UESCAPE + clause after the string, for example: +

U&"d!0061t!+000061" UESCAPE '!'

+ The escape character can be any single character other than a + hexadecimal digit, the plus sign, a single quote, a double quote, + or a whitespace character. Note that the escape character is + written in single quotes, not double quotes. +

To include the escape character in the identifier literally, write + it twice. +

The Unicode escape syntax works only when the server encoding is + UTF8. When other server encodings are used, only code + points in the ASCII range (up to \007F) can be + specified. Both the 4-digit and the 6-digit form can be used to + specify UTF-16 surrogate pairs to compose characters with code + points larger than U+FFFF, although the availability of the + 6-digit form technically makes this unnecessary. (Surrogate + pairs are not stored directly, but combined into a single + code point that is then encoded in UTF-8.) +

Quoting an identifier also makes it case-sensitive, whereas + unquoted names are always folded to lower case. For example, the + identifiers FOO, foo, and + "foo" are considered the same by + PostgreSQL, but + "Foo" and "FOO" are + different from these three and each other. (The folding of + unquoted names to lower case in PostgreSQL is + incompatible with the SQL standard, which says that unquoted names + should be folded to upper case. Thus, foo + should be equivalent to "FOO" not + "foo" according to the standard. If you want + to write portable applications you are advised to always quote a + particular name or never quote it.) +

4.1.2. Constants

There are three kinds of implicitly-typed + constants in PostgreSQL: + strings, bit strings, and numbers. + Constants can also be specified with explicit types, which can + enable more accurate representation and more efficient handling by + the system. These alternatives are discussed in the following + subsections. +

4.1.2.1. String Constants

+ A string constant in SQL is an arbitrary sequence of characters + bounded by single quotes ('), for example + 'This is a string'. To include + a single-quote character within a string constant, + write two adjacent single quotes, e.g., + 'Dianne''s horse'. + Note that this is not the same as a double-quote + character ("). +

Two string constants that are only separated by whitespace + with at least one newline are concatenated + and effectively treated as if the string had been written as one + constant. For example: +

SELECT 'foo'
+'bar';

+ is equivalent to: +

SELECT 'foobar';

+ but: +

SELECT 'foo'      'bar';

+ is not valid syntax. (This slightly bizarre behavior is specified + by SQL; PostgreSQL is + following the standard.) +

4.1.2.2. String Constants with C-style Escapes

PostgreSQL also accepts "escape" + string constants, which are an extension to the SQL standard. + An escape string constant is specified by writing the letter + E (upper or lower case) just before the opening single + quote, e.g., E'foo'. (When continuing an escape string + constant across lines, write E only before the first opening + quote.) + Within an escape string, a backslash character (\) begins a + C-like backslash escape sequence, in which the combination + of backslash and following character(s) represent a special byte + value, as shown in Table 4-1. +

Table 4-1. Backslash Escape Sequences

Backslash Escape SequenceInterpretation
\bbackspace
\fform feed
\nnewline
\rcarriage return
\ttab
\o, + \oo, + \ooo + (o = 0 - 7) + octal byte value
\xh, + \xhh + (h = 0 - 9, A - F) + hexadecimal byte value
\uxxxx, + \Uxxxxxxxx + (x = 0 - 9, A - F) + 16 or 32-bit hexadecimal Unicode character value

Any other + character following a backslash is taken literally. Thus, to + include a backslash character, write two backslashes (\\). + Also, a single quote can be included in an escape string by writing + \', in addition to the normal way of ''. +

It is your responsibility that the byte sequences you create, + especially when using the octal or hexadecimal escapes, compose + valid characters in the server character set encoding. When the + server encoding is UTF-8, then the Unicode escapes or the + alternative Unicode escape syntax, explained + in Section 4.1.2.3, should be used + instead. (The alternative would be doing the UTF-8 encoding by + hand and writing out the bytes, which would be very cumbersome.) +

The Unicode escape syntax works fully only when the server + encoding is UTF8. When other server encodings are + used, only code points in the ASCII range (up + to \u007F) can be specified. Both the 4-digit and + the 8-digit form can be used to specify UTF-16 surrogate pairs to + compose characters with code points larger than U+FFFF, although + the availability of the 8-digit form technically makes this + unnecessary. (When surrogate pairs are used when the server + encoding is UTF8, they are first combined into a + single code point that is then encoded in UTF-8.) +

Caution

If the configuration parameter + standard_conforming_strings is off, + then PostgreSQL recognizes backslash escapes + in both regular and escape string constants. However, as of + PostgreSQL 9.1, the default is on, meaning + that backslash escapes are recognized only in escape string constants. + This behavior is more standards-compliant, but might break applications + which rely on the historical behavior, where backslash escapes + were always recognized. As a workaround, you can set this parameter + to off, but it is better to migrate away from using backslash + escapes. If you need to use a backslash escape to represent a special + character, write the string constant with an E. +

In addition to standard_conforming_strings, the configuration + parameters escape_string_warning and + backslash_quote govern treatment of backslashes + in string constants. +

The character with the code zero cannot be in a string constant. +

4.1.2.3. String Constants with Unicode Escapes

PostgreSQL also supports another type + of escape syntax for strings that allows specifying arbitrary + Unicode characters by code point. A Unicode escape string + constant starts with U& (upper or lower case + letter U followed by ampersand) immediately before the opening + quote, without any spaces in between, for + example U&'foo'. (Note that this creates an + ambiguity with the operator &. Use spaces + around the operator to avoid this problem.) Inside the quotes, + Unicode characters can be specified in escaped form by writing a + backslash followed by the four-digit hexadecimal code point + number or alternatively a backslash followed by a plus sign + followed by a six-digit hexadecimal code point number. For + example, the string 'data' could be written as +

U&'d\0061t\+000061'

+ The following less trivial example writes the Russian + word "slon" (elephant) in Cyrillic letters: +

U&'\0441\043B\043E\043D'

+

If a different escape character than backslash is desired, it can + be specified using + the UESCAPE + clause after the string, for example: +

U&'d!0061t!+000061' UESCAPE '!'

+ The escape character can be any single character other than a + hexadecimal digit, the plus sign, a single quote, a double quote, + or a whitespace character. +

The Unicode escape syntax works only when the server encoding is + UTF8. When other server encodings are used, only + code points in the ASCII range (up to \007F) + can be specified. Both the 4-digit and the 6-digit form can be + used to specify UTF-16 surrogate pairs to compose characters with + code points larger than U+FFFF, although the availability of the + 6-digit form technically makes this unnecessary. (When surrogate + pairs are used when the server encoding is UTF8, they + are first combined into a single code point that is then encoded + in UTF-8.) +

Also, the Unicode escape syntax for string constants only works + when the configuration + parameter standard_conforming_strings is + turned on. This is because otherwise this syntax could confuse + clients that parse the SQL statements to the point that it could + lead to SQL injections and similar security issues. If the + parameter is set to off, this syntax will be rejected with an + error message. +

To include the escape character in the string literally, write it + twice. +

4.1.2.4. Dollar-quoted String Constants

While the standard syntax for specifying string constants is usually + convenient, it can be difficult to understand when the desired string + contains many single quotes or backslashes, since each of those must + be doubled. To allow more readable queries in such situations, + PostgreSQL provides another way, called + "dollar quoting", to write string constants. + A dollar-quoted string constant + consists of a dollar sign ($), an optional + "tag" of zero or more characters, another dollar + sign, an arbitrary sequence of characters that makes up the + string content, a dollar sign, the same tag that began this + dollar quote, and a dollar sign. For example, here are two + different ways to specify the string "Dianne's horse" + using dollar quoting: +

$$Dianne's horse$$
+$SomeTag$Dianne's horse$SomeTag$

+ Notice that inside the dollar-quoted string, single quotes can be + used without needing to be escaped. Indeed, no characters inside + a dollar-quoted string are ever escaped: the string content is always + written literally. Backslashes are not special, and neither are + dollar signs, unless they are part of a sequence matching the opening + tag. +

It is possible to nest dollar-quoted string constants by choosing + different tags at each nesting level. This is most commonly used in + writing function definitions. For example: +

$function$
+BEGIN
+    RETURN ($1 ~ $q$[\t\r\n\v\\]$q$);
+END;
+$function$

+ Here, the sequence $q$[\t\r\n\v\\]$q$ represents a + dollar-quoted literal string [\t\r\n\v\\], which will + be recognized when the function body is executed by + PostgreSQL. But since the sequence does not match + the outer dollar quoting delimiter $function$, it is + just some more characters within the constant so far as the outer + string is concerned. +

The tag, if any, of a dollar-quoted string follows the same rules + as an unquoted identifier, except that it cannot contain a dollar sign. + Tags are case sensitive, so $tag$String content$tag$ + is correct, but $TAG$String content$tag$ is not. +

A dollar-quoted string that follows a keyword or identifier must + be separated from it by whitespace; otherwise the dollar quoting + delimiter would be taken as part of the preceding identifier. +

Dollar quoting is not part of the SQL standard, but it is often a more + convenient way to write complicated string literals than the + standard-compliant single quote syntax. It is particularly useful when + representing string constants inside other constants, as is often needed + in procedural function definitions. With single-quote syntax, each + backslash in the above example would have to be written as four + backslashes, which would be reduced to two backslashes in parsing the + original string constant, and then to one when the inner string constant + is re-parsed during function execution. +

4.1.2.5. Bit-string Constants

Bit-string constants look like regular string constants with a + B (upper or lower case) immediately before the + opening quote (no intervening whitespace), e.g., + B'1001'. The only characters allowed within + bit-string constants are 0 and + 1. +

Alternatively, bit-string constants can be specified in hexadecimal + notation, using a leading X (upper or lower case), + e.g., X'1FF'. This notation is equivalent to + a bit-string constant with four binary digits for each hexadecimal digit. +

Both forms of bit-string constant can be continued + across lines in the same way as regular string constants. + Dollar quoting cannot be used in a bit-string constant. +

4.1.2.6. Numeric Constants

Numeric constants are accepted in these general forms: +

digits
+digits.[digits][e[+-]digits]
+[digits].digits[e[+-]digits]
+digitse[+-]digits

+ where digits is one or more decimal + digits (0 through 9). At least one digit must be before or after the + decimal point, if one is used. At least one digit must follow the + exponent marker (e), if one is present. + There cannot be any spaces or other characters embedded in the + constant. Note that any leading plus or minus sign is not actually + considered part of the constant; it is an operator applied to the + constant. +

These are some examples of valid numeric constants: +

42
+3.5
+4.
+.001
+5e2
+1.925e-3

+

+ + + A numeric constant that contains neither a decimal point nor an + exponent is initially presumed to be type integer if its + value fits in type integer (32 bits); otherwise it is + presumed to be type bigint if its + value fits in type bigint (64 bits); otherwise it is + taken to be type numeric. Constants that contain decimal + points and/or exponents are always initially presumed to be type + numeric. +

The initially assigned data type of a numeric constant is just a + starting point for the type resolution algorithms. In most cases + the constant will be automatically coerced to the most + appropriate type depending on context. When necessary, you can + force a numeric value to be interpreted as a specific data type + by casting it. + For example, you can force a numeric value to be treated as type + real (float4) by writing: + +

REAL '1.23'  -- string style
+1.23::REAL   -- PostgreSQL (historical) style

+ + These are actually just special cases of the general casting + notations discussed next. +

4.1.2.7. Constants of Other Types

A constant of an arbitrary type can be + entered using any one of the following notations: +

type 'string'
+'string'::type
+CAST ( 'string' AS type )

+ The string constant's text is passed to the input conversion + routine for the type called type. The + result is a constant of the indicated type. The explicit type + cast can be omitted if there is no ambiguity as to the type the + constant must be (for example, when it is assigned directly to a + table column), in which case it is automatically coerced. +

The string constant can be written using either regular SQL + notation or dollar-quoting. +

It is also possible to specify a type coercion using a function-like + syntax: +

typename ( 'string' )

+ but not all type names can be used in this way; see Section 4.2.9 for details. +

The ::, CAST(), and + function-call syntaxes can also be used to specify run-time type + conversions of arbitrary expressions, as discussed in Section 4.2.9. To avoid syntactic ambiguity, the + type 'string' + syntax can only be used to specify the type of a simple literal constant. + Another restriction on the + type 'string' + syntax is that it does not work for array types; use :: + or CAST() to specify the type of an array constant. +

The CAST() syntax conforms to SQL. The + type 'string' + syntax is a generalization of the standard: SQL specifies this syntax only + for a few data types, but PostgreSQL allows it + for all types. The syntax with + :: is historical PostgreSQL + usage, as is the function-call syntax. +

4.1.3. Operators

An operator name is a sequence of up to NAMEDATALEN-1 + (63 by default) characters from the following list: +

+ - * / < > = ~ ! @ # % ^ & | ` ?

+ + There are a few restrictions on operator names, however: +

  • -- and /* cannot appear + anywhere in an operator name, since they will be taken as the + start of a comment. +

  • A multiple-character operator name cannot end in + or -, + unless the name also contains at least one of these characters: +

    ~ ! @ # % ^ & | ` ?

    + For example, @- is an allowed operator name, + but *- is not. This restriction allows + PostgreSQL to parse SQL-compliant + queries without requiring spaces between tokens. +

+

When working with non-SQL-standard operator names, you will usually + need to separate adjacent operators with spaces to avoid ambiguity. + For example, if you have defined a left unary operator named @, + you cannot write X*@Y; you must write + X* @Y to ensure that + PostgreSQL reads it as two operator names + not one. +

4.1.4. Special Characters

Some characters that are not alphanumeric have a special meaning + that is different from being an operator. Details on the usage can + be found at the location where the respective syntax element is + described. This section only exists to advise the existence and + summarize the purposes of these characters. + +

  • A dollar sign ($) followed by digits is used + to represent a positional parameter in the body of a function + definition or a prepared statement. In other contexts the + dollar sign can be part of an identifier or a dollar-quoted string + constant. +

  • Parentheses (()) have their usual meaning to + group expressions and enforce precedence. In some cases + parentheses are required as part of the fixed syntax of a + particular SQL command. +

  • Brackets ([]) are used to select the elements + of an array. See Section 8.15 for more information + on arrays. +

  • Commas (,) are used in some syntactical + constructs to separate the elements of a list. +

  • The semicolon (;) terminates an SQL command. + It cannot appear anywhere within a command, except within a + string constant or quoted identifier. +

  • The colon (:) is used to select + "slices" from arrays. (See Section 8.15.) In certain SQL dialects (such as Embedded + SQL), the colon is used to prefix variable names. +

  • The asterisk (*) is used in some contexts to denote + all the fields of a table row or composite value. It also + has a special meaning when used as the argument of an + aggregate function, namely that the aggregate does not require + any explicit parameter. +

  • The period (.) is used in numeric + constants, and to separate schema, table, and column names. +

+ +

4.1.5. Comments

A comment is a sequence of characters beginning with + double dashes and extending to the end of the line, e.g.: +

-- This is a standard SQL comment

+

Alternatively, C-style block comments can be used: +

/* multiline comment
+ * with nesting: /* nested block comment */
+ */

+ where the comment begins with /* and extends to + the matching occurrence of */. These block + comments nest, as specified in the SQL standard but unlike C, so that one can + comment out larger blocks of code that might contain existing block + comments. +

A comment is removed from the input stream before further syntax + analysis and is effectively replaced by whitespace. +

4.1.6. Operator Precedence

Table 4-2 shows the precedence and + associativity of the operators in PostgreSQL. + Most operators have the same precedence and are left-associative. + The precedence and associativity of the operators is hard-wired + into the parser. This can lead to non-intuitive behavior; for + example the Boolean operators < and + > have a different precedence than the Boolean + operators <= and >=. Also, you will + sometimes need to add parentheses when using combinations of + binary and unary operators. For instance: +

SELECT 5 ! - 6;

+ will be parsed as: +

SELECT 5 ! (- 6);

+ because the parser has no idea — until it is too late + — that ! is defined as a postfix operator, + not an infix one. To get the desired behavior in this case, you + must write: +

SELECT (5 !) - 6;

+ This is the price one pays for extensibility. +

Table 4-2. Operator Precedence (decreasing)

Operator/ElementAssociativityDescription
.lefttable/column name separator
::leftPostgreSQL-style typecast
[ ]leftarray element selection
+ -rightunary plus, unary minus
^leftexponentiation
* / %leftmultiplication, division, modulo
+ -leftaddition, subtraction
IS IS TRUE, IS FALSE, IS NULL, etc
ISNULL test for null
NOTNULL test for not null
(any other)leftall other native and user-defined operators
IN set membership
BETWEEN range containment
OVERLAPS time interval overlap
LIKE ILIKE SIMILAR string pattern matching
< > less than, greater than
=rightequality, assignment
NOTrightlogical negation
ANDleftlogical conjunction
ORleftlogical disjunction

Note that the operator precedence rules also apply to user-defined + operators that have the same names as the built-in operators + mentioned above. For example, if you define a + "+" operator for some custom data type it will have + the same precedence as the built-in "+" operator, no + matter what yours does. +

When a schema-qualified operator name is used in the + OPERATOR syntax, as for example in: +

SELECT 3 OPERATOR(pg_catalog.+) 4;

+ the OPERATOR construct is taken to have the default precedence + shown in Table 4-2 for "any other" operator. This is true no matter + which specific operator appears inside OPERATOR(). +


PrevHomeNext
SQL SyntaxUpValue Expressions
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-syntax.html b/doc/src/sgml/html/sql-syntax.html new file mode 100644 index 000000000..f046f2f52 --- /dev/null +++ b/doc/src/sgml/html/sql-syntax.html @@ -0,0 +1,327 @@ + +SQL Syntax

Chapter 4. SQL Syntax

This chapter describes the syntax of SQL. It forms the foundation + for understanding the following chapters which will go into detail + about how SQL commands are applied to define and modify data. +

We also advise users who are already familiar with SQL to read this + chapter carefully because it contains several rules and concepts that + are implemented inconsistently among SQL databases or that are + specific to PostgreSQL. +


PrevHomeNext
The SQL LanguageUpLexical Structure
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-truncate.html b/doc/src/sgml/html/sql-truncate.html new file mode 100644 index 000000000..b5b43d227 --- /dev/null +++ b/doc/src/sgml/html/sql-truncate.html @@ -0,0 +1,549 @@ + +TRUNCATE

TRUNCATE

Name

TRUNCATE -- empty a table or set of tables

Synopsis

TRUNCATE [ TABLE ] [ ONLY ] name [ * ] [, ... ]
+    [ RESTART IDENTITY | CONTINUE IDENTITY ] [ CASCADE | RESTRICT ]

Description

TRUNCATE quickly removes all rows from a set of + tables. It has the same effect as an unqualified + DELETE on each table, but since it does not actually + scan the tables it is faster. Furthermore, it reclaims disk space + immediately, rather than requiring a subsequent VACUUM + operation. This is most useful on large tables. +

Parameters

name

The name (optionally schema-qualified) of a table to truncate. + If ONLY is specified before the table name, only that table + is truncated. If ONLY is not specified, the table and all + its descendant tables (if any) are truncated. Optionally, * + can be specified after the table name to explicitly indicate that + descendant tables are included. +

RESTART IDENTITY

Automatically restart sequences owned by columns of + the truncated table(s). +

CONTINUE IDENTITY

Do not change the values of sequences. This is the default. +

CASCADE

Automatically truncate all tables that have foreign-key references + to any of the named tables, or to any tables added to the group + due to CASCADE. +

RESTRICT

Refuse to truncate if any of the tables have foreign-key references + from tables that are not listed in the command. This is the default. +

Notes

You must have the TRUNCATE privilege on a table + to truncate it. +

TRUNCATE acquires an ACCESS EXCLUSIVE lock on each + table it operates on, which blocks all other concurrent operations + on the table. When RESTART IDENTITY is specified, any + sequences that are to be restarted are likewise locked exclusively. + If concurrent access to a table is required, then + the DELETE command should be used instead. +

TRUNCATE cannot be used on a table that has foreign-key + references from other tables, unless all such tables are also truncated + in the same command. Checking validity in such cases would require table + scans, and the whole point is not to do one. The CASCADE + option can be used to automatically include all dependent tables — + but be very careful when using this option, or else you might lose data you + did not intend to! +

TRUNCATE will not fire any ON DELETE + triggers that might exist for the tables. But it will fire + ON TRUNCATE triggers. + If ON TRUNCATE triggers are defined for any of + the tables, then all BEFORE TRUNCATE triggers are + fired before any truncation happens, and all AFTER + TRUNCATE triggers are fired after the last truncation is + performed and any sequences are reset. + The triggers will fire in the order that the tables are + to be processed (first those listed in the command, and then any + that were added due to cascading). +

Warning

TRUNCATE is not MVCC-safe (see Chapter 13 + for general information about MVCC). After truncation, the table + will appear empty to all concurrent transactions, even if they + are using a snapshot taken before the truncation occurred. This + will only be an issue for a transaction that did not access the + truncated table before the truncation happened — any + transaction that has done so would hold at least an + ACCESS SHARE lock, which would block + TRUNCATE until that transaction completes. So + truncation will not cause any apparent inconsistency in the table + contents for successive queries on the same table, but it could + cause visible inconsistency between the contents of the truncated + table and other tables in the database. +

TRUNCATE is transaction-safe with respect to the data + in the tables: the truncation will be safely rolled back if the surrounding + transaction does not commit. +

When RESTART IDENTITY is specified, the implied + ALTER SEQUENCE RESTART operations are also done + transactionally; that is, they will be rolled back if the surrounding + transaction does not commit. This is unlike the normal behavior of + ALTER SEQUENCE RESTART. Be aware that if any additional + sequence operations are done on the restarted sequences before the + transaction rolls back, the effects of these operations on the sequences + will be rolled back, but not their effects on currval(); + that is, after the transaction currval() will continue to + reflect the last sequence value obtained inside the failed transaction, + even though the sequence itself may no longer be consistent with that. + This is similar to the usual behavior of currval() after + a failed transaction. +

Examples

Truncate the tables bigtable and + fattable: + +

TRUNCATE bigtable, fattable;

+

The same, and also reset any associated sequence generators: + +

TRUNCATE bigtable, fattable RESTART IDENTITY;

+

Truncate the table othertable, and cascade to any tables + that reference othertable via foreign-key + constraints: + +

TRUNCATE othertable CASCADE;

Compatibility

The SQL:2008 standard includes a TRUNCATE command + with the syntax TRUNCATE TABLE + tablename. The clauses + CONTINUE IDENTITY/RESTART IDENTITY + also appear in that standard, but have slightly different though related + meanings. Some of the concurrency behavior of this command is left + implementation-defined by the standard, so the above notes should be + considered and compared with other implementations if necessary. +


PrevHomeNext
START TRANSACTIONUpUNLISTEN
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-unlisten.html b/doc/src/sgml/html/sql-unlisten.html new file mode 100644 index 000000000..129d21e4d --- /dev/null +++ b/doc/src/sgml/html/sql-unlisten.html @@ -0,0 +1,360 @@ + +UNLISTEN

UNLISTEN

Name

UNLISTEN -- stop listening for a notification

Synopsis

UNLISTEN { channel | * }

Description

UNLISTEN is used to remove an existing + registration for NOTIFY events. + UNLISTEN cancels any existing registration of + the current PostgreSQL session as a + listener on the notification channel named channel. The special wildcard + * cancels all listener registrations for the + current session. +

NOTIFY + contains a more extensive + discussion of the use of LISTEN and + NOTIFY. +

Parameters

channel

Name of a notification channel (any identifier). +

*

All current listen registrations for this session are cleared. +

Notes

You can unlisten something you were not listening for; no warning or error + will appear. +

At the end of each session, UNLISTEN * is + automatically executed. +

A transaction that has executed UNLISTEN cannot be + prepared for two-phase commit. +

Examples

To make a registration: + +

LISTEN virtual;
+NOTIFY virtual;
+Asynchronous notification "virtual" received from server process with PID 8448.

+

Once UNLISTEN has been executed, further NOTIFY + messages will be ignored: + +

UNLISTEN virtual;
+NOTIFY virtual;
+-- no NOTIFY event is received

Compatibility

There is no UNLISTEN command in the SQL standard. +

See Also

LISTEN, NOTIFY

PrevHomeNext
TRUNCATEUpUPDATE
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-update.html b/doc/src/sgml/html/sql-update.html new file mode 100644 index 000000000..e57611d80 --- /dev/null +++ b/doc/src/sgml/html/sql-update.html @@ -0,0 +1,893 @@ + +UPDATE

UPDATE

Name

UPDATE -- update rows of a table

Synopsis

[ WITH [ RECURSIVE ] with_query [, ...] ]
+UPDATE [ ONLY ] table_name [ * ] [ [ AS ] alias ]
+    SET { column_name = { expression | DEFAULT } |
+          ( column_name [, ...] ) = ( { expression | DEFAULT } [, ...] ) } [, ...]
+    [ FROM from_list ]
+    [ WHERE condition | WHERE CURRENT OF cursor_name ]
+    [ RETURNING * | output_expression [ [ AS ] output_name ] [, ...] ]

Description

UPDATE changes the values of the specified + columns in all rows that satisfy the condition. Only the columns to + be modified need be mentioned in the SET clause; + columns not explicitly modified retain their previous values. +

There are two ways to modify a table using information contained in + other tables in the database: using sub-selects, or specifying + additional tables in the FROM clause. Which + technique is more appropriate depends on the specific + circumstances. +

The optional RETURNING clause causes UPDATE + to compute and return value(s) based on each row actually updated. + Any expression using the table's columns, and/or columns of other + tables mentioned in FROM, can be computed. + The new (post-update) values of the table's columns are used. + The syntax of the RETURNING list is identical to that of the + output list of SELECT. +

You must have the UPDATE privilege on the table, + or at least on the column(s) that are listed to be updated. + You must also have the SELECT + privilege on any column whose values are read in the + expressions or + condition. +

Parameters

with_query

The WITH clause allows you to specify one or more + subqueries that can be referenced by name in the UPDATE + query. See Section 7.8 and SELECT + for details. +

table_name

The name (optionally schema-qualified) of the table to update. + If ONLY is specified before the table name, matching rows + are updated in the named table only. If ONLY is not + specified, matching rows are also updated in any tables inheriting from + the named table. Optionally, * can be specified after the + table name to explicitly indicate that descendant tables are included. +

alias

A substitute name for the target table. When an alias is + provided, it completely hides the actual name of the table. For + example, given UPDATE foo AS f, the remainder of the + UPDATE statement must refer to this table as + f not foo. +

column_name

The name of a column in the table named by table_name. + The column name can be qualified with a subfield name or array + subscript, if needed. Do not include the table's name in the + specification of a target column — for example, + UPDATE tab SET tab.col = 1 is invalid. +

expression

An expression to assign to the column. The expression can use the + old values of this and other columns in the table. +

DEFAULT

Set the column to its default value (which will be NULL if no + specific default expression has been assigned to it). +

from_list

A list of table expressions, allowing columns from other tables + to appear in the WHERE condition and the update + expressions. This is similar to the list of tables that can be + specified in the FROM Clause of a SELECT + statement. Note that the target table must not appear in the + from_list, unless you intend a self-join (in which + case it must appear with an alias in the from_list). +

condition

An expression that returns a value of type boolean. + Only rows for which this expression returns true + will be updated. +

cursor_name

The name of the cursor to use in a WHERE CURRENT OF + condition. The row to be updated is the one most recently fetched + from this cursor. The cursor must be a non-grouping + query on the UPDATE's target table. + Note that WHERE CURRENT OF cannot be + specified together with a Boolean condition. See + DECLARE + for more information about using cursors with + WHERE CURRENT OF. +

output_expression

An expression to be computed and returned by the UPDATE + command after each row is updated. The expression can use any + column names of the table named by table_name + or table(s) listed in FROM. + Write * to return all columns. +

output_name

A name to use for a returned column. +

Outputs

On successful completion, an UPDATE command returns a command + tag of the form +

UPDATE count

+ The count is the number + of rows updated, including matched rows whose values did not change. + Note that the number may be less than the number of rows that matched + the condition when + updates were suppressed by a BEFORE UPDATE trigger. If + count is 0, no rows were + updated by the query (this is not considered an error). +

If the UPDATE command contains a RETURNING + clause, the result will be similar to that of a SELECT + statement containing the columns and values defined in the + RETURNING list, computed over the row(s) updated by the + command. +

Notes

When a FROM clause is present, what essentially happens + is that the target table is joined to the tables mentioned in the + from_list, and each output row of the join + represents an update operation for the target table. When using + FROM you should ensure that the join + produces at most one output row for each row to be modified. In + other words, a target row shouldn't join to more than one row from + the other table(s). If it does, then only one of the join rows + will be used to update the target row, but which one will be used + is not readily predictable. +

Because of this indeterminacy, referencing other tables only within + sub-selects is safer, though often harder to read and slower than + using a join. +

Examples

Change the word Drama to Dramatic in the + column kind of the table films: + +

UPDATE films SET kind = 'Dramatic' WHERE kind = 'Drama';

+

Adjust temperature entries and reset precipitation to its default + value in one row of the table weather: + +

UPDATE weather SET temp_lo = temp_lo+1, temp_hi = temp_lo+15, prcp = DEFAULT
+  WHERE city = 'San Francisco' AND date = '2003-07-03';

+

Perform the same operation and return the updated entries: + +

UPDATE weather SET temp_lo = temp_lo+1, temp_hi = temp_lo+15, prcp = DEFAULT
+  WHERE city = 'San Francisco' AND date = '2003-07-03'
+  RETURNING temp_lo, temp_hi, prcp;

+

Use the alternative column-list syntax to do the same update: +

UPDATE weather SET (temp_lo, temp_hi, prcp) = (temp_lo+1, temp_lo+15, DEFAULT)
+  WHERE city = 'San Francisco' AND date = '2003-07-03';

+

Increment the sales count of the salesperson who manages the + account for Acme Corporation, using the FROM + clause syntax: +

UPDATE employees SET sales_count = sales_count + 1 FROM accounts
+  WHERE accounts.name = 'Acme Corporation'
+  AND employees.id = accounts.sales_person;

+

Perform the same operation, using a sub-select in the + WHERE clause: +

UPDATE employees SET sales_count = sales_count + 1 WHERE id =
+  (SELECT sales_person FROM accounts WHERE name = 'Acme Corporation');

+

Attempt to insert a new stock item along with the quantity of stock. If + the item already exists, instead update the stock count of the existing + item. To do this without failing the entire transaction, use savepoints: +

BEGIN;
+-- other operations
+SAVEPOINT sp1;
+INSERT INTO wines VALUES('Chateau Lafite 2003', '24');
+-- Assume the above fails because of a unique key violation,
+-- so now we issue these commands:
+ROLLBACK TO sp1;
+UPDATE wines SET stock = stock + 24 WHERE winename = 'Chateau Lafite 2003';
+-- continue with other operations, and eventually
+COMMIT;

+

Change the kind column of the table + films in the row on which the cursor + c_films is currently positioned: +

UPDATE films SET kind = 'Dramatic' WHERE CURRENT OF c_films;

Compatibility

This command conforms to the SQL standard, except + that the FROM and RETURNING clauses + are PostgreSQL extensions, as is the ability + to use WITH with UPDATE. +

According to the standard, the column-list syntax should allow a list + of columns to be assigned from a single row-valued expression, such + as a sub-select: +

UPDATE accounts SET (contact_last_name, contact_first_name) =
+    (SELECT last_name, first_name FROM salesmen
+     WHERE salesmen.id = accounts.sales_id);

+ This is not currently implemented — the source must be a list + of independent expressions. +

Some other database systems offer a FROM option in which + the target table is supposed to be listed again within FROM. + That is not how PostgreSQL interprets + FROM. Be careful when porting applications that use this + extension. +


PrevHomeNext
UNLISTENUpVACUUM
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-vacuum.html b/doc/src/sgml/html/sql-vacuum.html new file mode 100644 index 000000000..7efa7aaa1 --- /dev/null +++ b/doc/src/sgml/html/sql-vacuum.html @@ -0,0 +1,611 @@ + +VACUUM

VACUUM

Name

VACUUM -- garbage-collect and optionally analyze a database

Synopsis

VACUUM [ ( { FULL | FREEZE | VERBOSE | ANALYZE } [, ...] ) ] [ table_name [ (column_name [, ...] ) ] ]
+VACUUM [ FULL ] [ FREEZE ] [ VERBOSE ] [ table_name ]
+VACUUM [ FULL ] [ FREEZE ] [ VERBOSE ] ANALYZE [ table_name [ (column_name [, ...] ) ] ]

Description

VACUUM reclaims storage occupied by dead tuples. + In normal PostgreSQL operation, tuples that + are deleted or obsoleted by an update are not physically removed from + their table; they remain present until a VACUUM is + done. Therefore it's necessary to do VACUUM + periodically, especially on frequently-updated tables. +

With no parameter, VACUUM processes every table in the + current database that the current user has permission to vacuum. + With a parameter, VACUUM processes only that table. +

VACUUM ANALYZE performs a VACUUM + and then an ANALYZE for each selected table. This + is a handy combination form for routine maintenance scripts. See + ANALYZE + for more details about its processing. +

Plain VACUUM (without FULL) simply reclaims + space and makes it + available for re-use. This form of the command can operate in parallel + with normal reading and writing of the table, as an exclusive lock + is not obtained. However, extra space is not returned to the operating + system (in most cases); it's just kept available for re-use within the + same table. VACUUM FULL rewrites the entire contents + of the table into a new disk file with no extra space, allowing unused + space to be returned to the operating system. This form is much slower and + requires an exclusive lock on each table while it is being processed. +

When the option list is surrounded by parentheses, the options can be + written in any order. Without parentheses, options must be specified + in exactly the order shown above. + The parenthesized syntax was added in + PostgreSQL 9.0; the unparenthesized + syntax is deprecated. +

Parameters

FULL

Selects "full" vacuum, which can reclaim more + space, but takes much longer and exclusively locks the table. + This method also requires extra disk space, since it writes a + new copy of the table and doesn't release the old copy until + the operation is complete. Usually this should only be used when a + significant amount of space needs to be reclaimed from within the table. +

FREEZE

Selects aggressive "freezing" of tuples. + Specifying FREEZE is equivalent to performing + VACUUM with the + vacuum_freeze_min_age parameter + set to zero. +

VERBOSE

Prints a detailed vacuum activity report for each table. +

ANALYZE

Updates statistics used by the planner to determine the most + efficient way to execute a query. +

table_name

The name (optionally schema-qualified) of a specific table to + vacuum. Defaults to all tables in the current database. +

column_name

The name of a specific column to analyze. Defaults to all columns. + If a column list is specified, ANALYZE is implied. +

Outputs

When VERBOSE is specified, VACUUM emits + progress messages to indicate which table is currently being + processed. Various statistics about the tables are printed as well. +

Notes

To vacuum a table, one must ordinarily be the table's owner or a + superuser. However, database owners are allowed to + vacuum all tables in their databases, except shared catalogs. + (The restriction for shared catalogs means that a true database-wide + VACUUM can only be performed by a superuser.) + VACUUM will skip over any tables that the calling user + does not have permission to vacuum. +

VACUUM cannot be executed inside a transaction block. +

For tables with GIN indexes, VACUUM (in + any form) also completes any pending index insertions, by moving pending + index entries to the appropriate places in the main GIN index + structure. See Section 55.3.1 for details. +

We recommend that active production databases be + vacuumed frequently (at least nightly), in order to + remove dead rows. After adding or deleting a large number + of rows, it might be a good idea to issue a VACUUM + ANALYZE command for the affected table. This will update the + system catalogs with + the results of all recent changes, and allow the + PostgreSQL query planner to make better + choices in planning queries. +

The FULL option is not recommended for routine use, + but might be useful in special cases. An example is when you have deleted + or updated most of the rows in a table and would like the table to + physically shrink to occupy less disk space and allow faster table + scans. VACUUM FULL will usually shrink the table + more than a plain VACUUM would. +

VACUUM causes a substantial increase in I/O traffic, + which might cause poor performance for other active sessions. Therefore, + it is sometimes advisable to use the cost-based vacuum delay feature. + See Section 18.4.4 for details. +

PostgreSQL includes an "autovacuum" + facility which can automate routine vacuum maintenance. For more + information about automatic and manual vacuuming, see + Section 23.1. +

Examples

The following is an example from running VACUUM on a + table in the regression database: + +

regression=# VACUUM (VERBOSE, ANALYZE) onek;
+INFO:  vacuuming "public.onek"
+INFO:  index "onek_unique1" now contains 1000 tuples in 14 pages
+DETAIL:  3000 index tuples were removed.
+0 index pages have been deleted, 0 are currently reusable.
+CPU 0.01s/0.08u sec elapsed 0.18 sec.
+INFO:  index "onek_unique2" now contains 1000 tuples in 16 pages
+DETAIL:  3000 index tuples were removed.
+0 index pages have been deleted, 0 are currently reusable.
+CPU 0.00s/0.07u sec elapsed 0.23 sec.
+INFO:  index "onek_hundred" now contains 1000 tuples in 13 pages
+DETAIL:  3000 index tuples were removed.
+0 index pages have been deleted, 0 are currently reusable.
+CPU 0.01s/0.08u sec elapsed 0.17 sec.
+INFO:  index "onek_stringu1" now contains 1000 tuples in 48 pages
+DETAIL:  3000 index tuples were removed.
+0 index pages have been deleted, 0 are currently reusable.
+CPU 0.01s/0.09u sec elapsed 0.59 sec.
+INFO:  "onek": removed 3000 tuples in 108 pages
+DETAIL:  CPU 0.01s/0.06u sec elapsed 0.07 sec.
+INFO:  "onek": found 3000 removable, 1000 nonremovable tuples in 143 pages
+DETAIL:  0 dead tuples cannot be removed yet.
+There were 0 unused item pointers.
+0 pages are entirely empty.
+CPU 0.07s/0.39u sec elapsed 1.56 sec.
+INFO:  analyzing "public.onek"
+INFO:  "onek": 36 pages, 1000 rows sampled, 1000 estimated total rows
+VACUUM

Compatibility

There is no VACUUM statement in the SQL standard. +


PrevHomeNext
UPDATEUpVALUES
\ No newline at end of file diff --git a/doc/src/sgml/html/sql-values.html b/doc/src/sgml/html/sql-values.html new file mode 100644 index 000000000..ea3139160 --- /dev/null +++ b/doc/src/sgml/html/sql-values.html @@ -0,0 +1,667 @@ + +VALUES

VALUES

Name

VALUES -- compute a set of rows

Synopsis

VALUES ( expression [, ...] ) [, ...]
+    [ ORDER BY sort_expression [ ASC | DESC | USING operator ] [, ...] ]
+    [ LIMIT { count | ALL } ]
+    [ OFFSET start [ ROW | ROWS ] ]
+    [ FETCH { FIRST | NEXT } [ count ] { ROW | ROWS } ONLY ]

Description

VALUES computes a row value or set of row values + specified by value expressions. It is most commonly used to generate + a "constant table" within a larger command, but it can be + used on its own. +

When more than one row is specified, all the rows must have the same + number of elements. The data types of the resulting table's columns are + determined by combining the explicit or inferred types of the expressions + appearing in that column, using the same rules as for UNION + (see Section 10.5). +

Within larger commands, VALUES is syntactically allowed + anywhere that SELECT is. Because it is treated like a + SELECT by the grammar, it is possible to use + the ORDER BY, LIMIT (or + equivalently FETCH FIRST), + and OFFSET clauses with a + VALUES command. +

Parameters

expression

A constant or expression to compute and insert at the indicated place + in the resulting table (set of rows). In a VALUES list + appearing at the top level of an INSERT, an + expression can be replaced + by DEFAULT to indicate that the destination column's + default value should be inserted. DEFAULT cannot + be used when VALUES appears in other contexts. +

sort_expression

An expression or integer constant indicating how to sort the result + rows. This expression can refer to the columns of the + VALUES result as column1, column2, + etc. For more details see + ORDER BY Clause. +

operator

A sorting operator. For details see + ORDER BY Clause. +

count

The maximum number of rows to return. For details see + LIMIT Clause. +

start

The number of rows to skip before starting to return rows. + For details see + LIMIT Clause. +

Notes

VALUES lists with very large numbers of rows should be avoided, + as you might encounter out-of-memory failures or poor performance. + VALUES appearing within INSERT is a special case + (because the desired column types are known from the INSERT's + target table, and need not be inferred by scanning the VALUES + list), so it can handle larger lists than are practical in other contexts. +

Examples

A bare VALUES command: + +

VALUES (1, 'one'), (2, 'two'), (3, 'three');

+ + This will return a table of two columns and three rows. It's effectively + equivalent to: + +

SELECT 1 AS column1, 'one' AS column2
+UNION ALL
+SELECT 2, 'two'
+UNION ALL
+SELECT 3, 'three';

+ +

More usually, VALUES is used within a larger SQL command. + The most common use is in INSERT: + +

INSERT INTO films (code, title, did, date_prod, kind)
+    VALUES ('T_601', 'Yojimbo', 106, '1961-06-16', 'Drama');

+

In the context of INSERT, entries of a VALUES list + can be DEFAULT to indicate that the column default + should be used here instead of specifying a value: + +

INSERT INTO films VALUES
+    ('UA502', 'Bananas', 105, DEFAULT, 'Comedy', '82 minutes'),
+    ('T_601', 'Yojimbo', 106, DEFAULT, 'Drama', DEFAULT);

+

VALUES can also be used where a sub-SELECT might + be written, for example in a FROM clause: + +

SELECT f.*
+  FROM films f, (VALUES('MGM', 'Horror'), ('UA', 'Sci-Fi')) AS t (studio, kind)
+  WHERE f.studio = t.studio AND f.kind = t.kind;
+
+UPDATE employees SET salary = salary * v.increase
+  FROM (VALUES(1, 200000, 1.2), (2, 400000, 1.4)) AS v (depno, target, increase)
+  WHERE employees.depno = v.depno AND employees.sales >= v.target;

+ + Note that an AS clause is required when VALUES + is used in a FROM clause, just as is true for + SELECT. It is not required that the AS clause + specify names for all the columns, but it's good practice to do so. + (The default column names for VALUES are column1, + column2, etc in PostgreSQL, but + these names might be different in other database systems.) +

When VALUES is used in INSERT, the values are all + automatically coerced to the data type of the corresponding destination + column. When it's used in other contexts, it might be necessary to specify + the correct data type. If the entries are all quoted literal constants, + coercing the first is sufficient to determine the assumed type for all: + +

SELECT * FROM machines
+WHERE ip_address IN (VALUES('192.168.0.1'::inet), ('192.168.0.10'), ('192.168.1.43'));

Tip: For simple IN tests, it's better to rely on the + list-of-scalars form of IN than to write a VALUES + query as shown above. The list of scalars method requires less writing + and is often more efficient. +

Compatibility

VALUES conforms to the SQL standard. + LIMIT and OFFSET are + PostgreSQL extensions; see also + under SELECT. +

See Also

INSERT, SELECT

PrevHomeNext
VACUUMUpPostgreSQL Client Applications
\ No newline at end of file diff --git a/doc/src/sgml/html/sql.html b/doc/src/sgml/html/sql.html new file mode 100644 index 000000000..cc187dfef --- /dev/null +++ b/doc/src/sgml/html/sql.html @@ -0,0 +1,926 @@ + +The SQL Language

II. The SQL Language

This part describes the use of the SQL language + in PostgreSQL. We start with + describing the general syntax of SQL, then + explain how to create the structures to hold data, how to populate + the database, and how to query it. The middle part lists the + available data types and functions for use in + SQL commands. The rest treats several + aspects that are important for tuning a database for optimal + performance. +

The information in this part is arranged so that a novice user can + follow it start to end to gain a full understanding of the topics + without having to refer forward too many times. The chapters are + intended to be self-contained, so that advanced users can read the + chapters individually as they choose. The information in this + part is presented in a narrative fashion in topical units. + Readers looking for a complete description of a particular command + should see Part VI. +

Readers of this part should know how to connect to a + PostgreSQL database and issue + SQL commands. Readers that are unfamiliar with + these issues are encouraged to read Part I + first. SQL commands are typically entered + using the PostgreSQL interactive terminal + psql, but other programs that have + similar functionality can be used as well. +

Table of Contents
4. SQL Syntax
4.1. Lexical Structure
4.2. Value Expressions
4.3. Calling Functions
5. Data Definition
5.1. Table Basics
5.2. Default Values
5.3. Constraints
5.4. System Columns
5.5. Modifying Tables
5.6. Privileges
5.7. Schemas
5.8. Inheritance
5.9. Partitioning
5.10. Foreign Data
5.11. Other Database Objects
5.12. Dependency Tracking
6. Data Manipulation
6.1. Inserting Data
6.2. Updating Data
6.3. Deleting Data
7. Queries
7.1. Overview
7.2. Table Expressions
7.3. Select Lists
7.4. Combining Queries
7.5. Sorting Rows
7.6. LIMIT and OFFSET
7.7. VALUES Lists
7.8. WITH Queries (Common Table Expressions)
8. Data Types
8.1. Numeric Types
8.2. Monetary Types
8.3. Character Types
8.4. Binary Data Types
8.5. Date/Time Types
8.6. Boolean Type
8.7. Enumerated Types
8.8. Geometric Types
8.9. Network Address Types
8.10. Bit String Types
8.11. Text Search Types
8.12. UUID Type
8.13. XML Type
8.14. JSON Type
8.15. Arrays
8.16. Composite Types
8.17. Range Types
8.18. Object Identifier Types
8.19. Pseudo-Types
9. Functions and Operators
9.1. Logical Operators
9.2. Comparison Operators
9.3. Mathematical Functions and Operators
9.4. String Functions and Operators
9.5. Binary String Functions and Operators
9.6. Bit String Functions and Operators
9.7. Pattern Matching
9.8. Data Type Formatting Functions
9.9. Date/Time Functions and Operators
9.10. Enum Support Functions
9.11. Geometric Functions and Operators
9.12. Network Address Functions and Operators
9.13. Text Search Functions and Operators
9.14. XML Functions
9.15. JSON Functions
9.16. Sequence Manipulation Functions
9.17. Conditional Expressions
9.18. Array Functions and Operators
9.19. Range Functions and Operators
9.20. Aggregate Functions
9.21. Window Functions
9.22. Subquery Expressions
9.23. Row and Array Comparisons
9.24. Set Returning Functions
9.25. System Information Functions
9.26. System Administration Functions
9.27. Trigger Functions
10. Type Conversion
10.1. Overview
10.2. Operators
10.3. Functions
10.4. Value Storage
10.5. UNION, CASE, and Related Constructs
11. Indexes
11.1. Introduction
11.2. Index Types
11.3. Multicolumn Indexes
11.4. Indexes and ORDER BY
11.5. Combining Multiple Indexes
11.6. Unique Indexes
11.7. Indexes on Expressions
11.8. Partial Indexes
11.9. Operator Classes and Operator Families
11.10. Indexes and Collations
11.11. Examining Index Usage
12. Full Text Search
12.1. Introduction
12.2. Tables and Indexes
12.3. Controlling Text Search
12.4. Additional Features
12.5. Parsers
12.6. Dictionaries
12.7. Configuration Example
12.8. Testing and Debugging Text Search
12.9. GiST and GIN Index Types
12.10. psql Support
12.11. Limitations
12.12. Migration from Pre-8.3 Text Search
13. Concurrency Control
13.1. Introduction
13.2. Transaction Isolation
13.3. Explicit Locking
13.4. Data Consistency Checks at the Application Level
13.5. Locking and Indexes
14. Performance Tips
14.1. Using EXPLAIN
14.2. Statistics Used by the Planner
14.3. Controlling the Planner with Explicit JOIN Clauses
14.4. Populating a Database
14.5. Non-Durable Settings

PrevHomeNext
Conclusion SQL Syntax
\ No newline at end of file diff --git a/doc/src/sgml/html/ssh-tunnels.html b/doc/src/sgml/html/ssh-tunnels.html new file mode 100644 index 000000000..141fbb3e6 --- /dev/null +++ b/doc/src/sgml/html/ssh-tunnels.html @@ -0,0 +1,319 @@ + +Secure TCP/IP Connections with SSH Tunnels
PostgreSQL 9.2.2 Documentation
PrevUpChapter 17. Server Setup and OperationNext

17.10. Secure TCP/IP Connections with SSH Tunnels

It is possible to use SSH to encrypt the network + connection between clients and a + PostgreSQL server. Done properly, this + provides an adequately secure network connection, even for non-SSL-capable + clients. +

First make sure that an SSH server is + running properly on the same machine as the + PostgreSQL server and that you can log in using + ssh as some user. Then you can establish a secure + tunnel with a command like this from the client machine: +

ssh -L 63333:localhost:5432 joe@foo.com

+ The first number in the -L argument, 63333, is the + port number of your end of the tunnel; it can be any unused port. + (IANA reserves ports 49152 through 65535 for private use.) The + second number, 5432, is the remote end of the tunnel: the port + number your server is using. The name or IP address between the + port numbers is the host with the database server you are going to + connect to, as seen from the host you are logging in to, which + is foo.com in this example. In order to connect + to the database server using this tunnel, you connect to port 63333 + on the local machine: +

psql -h localhost -p 63333 postgres

+ To the database server it will then look as though you are really + user joe on host foo.com + connecting to localhost in that context, and it + will use whatever authentication procedure was configured for + connections from this user and host. Note that the server will not + think the connection is SSL-encrypted, since in fact it is not + encrypted between the + SSH server and the + PostgreSQL server. This should not pose any + extra security risk as long as they are on the same machine. +

In order for the + tunnel setup to succeed you must be allowed to connect via + ssh as joe@foo.com, just + as if you had attempted to use ssh to create a + terminal session. +

You could also have set up the port forwarding as +

ssh -L 63333:foo.com:5432 joe@foo.com

+ but then the database server will see the connection as coming in + on its foo.com interface, which is not opened by + the default setting listen_addresses = + 'localhost'. This is usually not what you want. +

If you have to "hop" to the database server via some + login host, one possible setup could look like this: +

ssh -L 63333:db.foo.com:5432 joe@shell.foo.com

+ Note that this way the connection + from shell.foo.com + to db.foo.com will not be encrypted by the SSH + tunnel. + SSH offers quite a few configuration possibilities when the network + is restricted in various ways. Please refer to the SSH + documentation for details. +

Tip: Several other applications exist that can provide secure tunnels using + a procedure similar in concept to the one just described. +


PrevHomeNext
Secure TCP/IP Connections with SSLUpRegistering Event Log on Windows
\ No newline at end of file diff --git a/doc/src/sgml/html/ssl-tcp.html b/doc/src/sgml/html/ssl-tcp.html new file mode 100644 index 000000000..b64055d15 --- /dev/null +++ b/doc/src/sgml/html/ssl-tcp.html @@ -0,0 +1,648 @@ + +Secure TCP/IP Connections with SSL
PostgreSQL 9.2.2 Documentation
PrevUpChapter 17. Server Setup and OperationNext

17.9. Secure TCP/IP Connections with SSL

PostgreSQL has native support for using + SSL connections to encrypt client/server communications + for increased security. This requires that + OpenSSL is installed on both client and + server systems and that support in PostgreSQL is + enabled at build time (see Chapter 15). +

With SSL support compiled in, the + PostgreSQL server can be started with + SSL enabled by setting the parameter + ssl to on in + postgresql.conf. The server will listen for both normal + and SSL connections on the same TCP port, and will negotiate + with any connecting client on whether to use SSL. By + default, this is at the client's option; see Section 19.1 about how to set up the server to require + use of SSL for some or all connections. +

PostgreSQL reads the system-wide + OpenSSL configuration file. By default, this + file is named openssl.cnf and is located in the + directory reported by openssl version -d. + This default can be overridden by setting environment variable + OPENSSL_CONF to the name of the desired configuration file. +

OpenSSL supports a wide range of ciphers + and authentication algorithms, of varying strength. While a list of + ciphers can be specified in the OpenSSL + configuration file, you can specify ciphers specifically for use by + the database server by modifying ssl_ciphers in + postgresql.conf. +

Note: It is possible to have authentication without encryption overhead by + using NULL-SHA or NULL-MD5 ciphers. However, + a man-in-the-middle could read and pass communications between client + and server. Also, encryption overhead is minimal compared to the + overhead of authentication. For these reasons NULL ciphers are not + recommended. +

To start in SSL mode, files containing the server certificate + and private key must exist. By default, these files are expected to be + named server.crt and server.key, respectively, in + the server's data directory, but other names and locations can be specified + using the configuration parameters ssl_cert_file + and ssl_key_file. + On Unix systems, the permissions on server.key must + disallow any access to world or group; achieve this by the command + chmod 0600 server.key. + If the private key is protected with a passphrase, the + server will prompt for the passphrase and will not start until it has + been entered. +

In some cases, the server certificate might be signed by an + "intermediate" certificate authority, rather than one that is + directly trusted by clients. To use such a certificate, append the + certificate of the signing authority to the server.crt file, + then its parent authority's certificate, and so on up to a "root" + authority that is trusted by the clients. The root certificate should + be included in every case where server.crt contains more than + one certificate. +

17.9.1. Using Client Certificates

To require the client to supply a trusted certificate, place + certificates of the certificate authorities (CAs) + you trust in the file root.crt in the data + directory, set the parameter ssl_ca_file in + postgresql.conf to root.crt, + and set the clientcert parameter + to 1 on the appropriate hostssl line(s) in + pg_hba.conf. + A certificate will then be requested from the client during + SSL connection startup. (See Section 31.18 for a + description of how to set up certificates on the client.) The server will + verify that the client's certificate is signed by one of the trusted + certificate authorities. Certificate Revocation List (CRL) entries + are also checked if the parameter ssl_crl_file is set. + + (See http://h71000.www7.hp.com/DOC/83final/BA554_90007/ch04s02.html + for diagrams showing SSL certificate usage.) +

The clientcert option in pg_hba.conf is + available for all authentication methods, but only for rows specified as + hostssl. When clientcert is not specified + or is set to 0, the server will still verify presented client + certificates against its CA list, if one is configured, + — but it will not insist that a client certificate be presented. +

Note that root.crt lists the top-level CAs that are + considered trusted for signing client certificates. In principle it need + not list the CA that signed the server's certificate, though in most cases + that CA would also be trusted for client certificates. +

If you are setting up client certificates, you may wish to use + the cert authentication method, so that the certificates + control user authentication as well as providing connection security. + See Section 19.3.10 for details. +

17.9.2. SSL Server File Usage

Table 17-3 summarizes the files that are + relevant to the SSL setup on the server. (The shown file names are default + or typical names. The locally configured names could be different.) +

Table 17-3. SSL Server File Usage

FileContentsEffect
ssl_cert_file ($PGDATA/server.crt)server certificatesent to client to indicate server's identity
ssl_key_file ($PGDATA/server.key)server private keyproves server certificate was sent by the owner; does not indicate + certificate owner is trustworthy
ssl_ca_file ($PGDATA/root.crt)trusted certificate authoritieschecks that client certificate is + signed by a trusted certificate authority
ssl_crl_file ($PGDATA/root.crl)certificates revoked by certificate authoritiesclient certificate must not be on this list

The files server.key, server.crt, + root.crt, and root.crl + (or their configured alternative names) + are only examined during server start; so you must restart + the server for changes in them to take effect. +

17.9.3. Creating a Self-signed Certificate

To create a quick self-signed certificate for the server, use the + following OpenSSL command: +

openssl req -new -text -out server.req

+ Fill out the information that openssl asks for. Make sure + you enter the local host name as "Common Name"; the challenge + password can be left blank. The program will generate a key that is + passphrase protected; it will not accept a passphrase that is less + than four characters long. To remove the passphrase (as you must if + you want automatic start-up of the server), run the commands: +

openssl rsa -in privkey.pem -out server.key
+rm privkey.pem

+ Enter the old passphrase to unlock the existing key. Now do: +

openssl req -x509 -in server.req -text -key server.key -out server.crt

+ to turn the certificate into a self-signed certificate and to copy + the key and certificate to where the server will look for them. + Finally do: +

chmod og-rwx server.key

+ because the server will reject the file if its permissions are more + liberal than this. + For more details on how to create your server private key and + certificate, refer to the OpenSSL documentation. +

A self-signed certificate can be used for testing, but a certificate + signed by a certificate authority (CA) (either one of the + global CAs or a local one) should be used in production + so that clients can verify the server's identity. If all the clients + are local to the organization, using a local CA is + recommended. +


PrevHomeNext
Encryption OptionsUpSecure TCP/IP Connections with SSH Tunnels
\ No newline at end of file diff --git a/doc/src/sgml/html/sslinfo.html b/doc/src/sgml/html/sslinfo.html new file mode 100644 index 000000000..2d3d443d0 --- /dev/null +++ b/doc/src/sgml/html/sslinfo.html @@ -0,0 +1,409 @@ + +sslinfo
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.34. sslinfo

The sslinfo module provides information about the SSL + certificate that the current client provided when connecting to + PostgreSQL. The module is useless (most functions + will return NULL) if the current connection does not use SSL. +

This extension won't build at all unless the installation was + configured with --with-openssl. +

F.34.1. Functions Provided

ssl_is_used() returns boolean +

Returns TRUE if current connection to server uses SSL, and FALSE + otherwise. +

ssl_version() returns text +

Returns the name of the protocol used for the SSL connection (e.g. SSLv2, + SSLv3, or TLSv1). +

ssl_cipher() returns text +

Returns the name of the cipher used for the SSL connection + (e.g. DHE-RSA-AES256-SHA). +

ssl_client_cert_present() returns boolean +

Returns TRUE if current client has presented a valid SSL client + certificate to the server, and FALSE otherwise. (The server + might or might not be configured to require a client certificate.) +

ssl_client_serial() returns numeric +

Returns serial number of current client certificate. The combination of + certificate serial number and certificate issuer is guaranteed to + uniquely identify a certificate (but not its owner — the owner + ought to regularly change his keys, and get new certificates from the + issuer). +

So, if you run your own CA and allow only certificates from this CA to + be accepted by the server, the serial number is the most reliable (albeit + not very mnemonic) means to identify a user. +

ssl_client_dn() returns text +

Returns the full subject of the current client certificate, converting + character data into the current database encoding. It is assumed that + if you use non-ASCII characters in the certificate names, your + database is able to represent these characters, too. If your database + uses the SQL_ASCII encoding, non-ASCII characters in the name will be + represented as UTF-8 sequences. +

The result looks like /CN=Somebody /C=Some country/O=Some organization. +

ssl_issuer_dn() returns text +

Returns the full issuer name of the current client certificate, converting + character data into the current database encoding. Encoding conversions + are handled the same as for ssl_client_dn. +

The combination of the return value of this function with the + certificate serial number uniquely identifies the certificate. +

This function is really useful only if you have more than one trusted CA + certificate in your server's root.crt file, or if this CA + has issued some intermediate certificate authority certificates. +

ssl_client_dn_field(fieldname text) returns text +

This function returns the value of the specified field in the + certificate subject, or NULL if the field is not present. + Field names are string constants that are + converted into ASN1 object identifiers using the OpenSSL object + database. The following values are acceptable: +

commonName (alias CN)
+surname (alias SN)
+name
+givenName (alias GN)
+countryName (alias C)
+localityName (alias L)
+stateOrProvinceName (alias ST)
+organizationName (alias O)
+organizationUnitName (alias OU)
+title
+description
+initials
+postalCode
+streetAddress
+generationQualifier
+description
+dnQualifier
+x500UniqueIdentifier
+pseudonym
+role
+emailAddress

All of these fields are optional, except commonName. + It depends + entirely on your CA's policy which of them would be included and which + wouldn't. The meaning of these fields, however, is strictly defined by + the X.500 and X.509 standards, so you cannot just assign arbitrary + meaning to them. +

ssl_issuer_field(fieldname text) returns text +

Same as ssl_client_dn_field, but for the certificate issuer + rather than the certificate subject. +

F.34.2. Author

Victor Wagner <vitus@cryptocom.ru>, Cryptocom LTD +

E-Mail of Cryptocom OpenSSL development group: + <openssl@cryptocom.ru> +


PrevHomeNext
spiUptablefunc
\ No newline at end of file diff --git a/doc/src/sgml/html/standby-settings.html b/doc/src/sgml/html/standby-settings.html new file mode 100644 index 000000000..c9c7ea031 --- /dev/null +++ b/doc/src/sgml/html/standby-settings.html @@ -0,0 +1,303 @@ + +Standby Server Settings
PostgreSQL 9.2.2 Documentation
PrevUpChapter 26. Recovery ConfigurationNext

26.3. Standby Server Settings

standby_mode (boolean)

Specifies whether to start the PostgreSQL server as + a standby. If this parameter is on, the server will + not stop recovery when the end of archived WAL is reached, but + will keep trying to continue recovery by fetching new WAL segments + using restore_command + and/or by connecting to the primary server as specified by the + primary_conninfo setting. +

primary_conninfo (string)

Specifies a connection string to be used for the standby server + to connect with the primary. This string is in the format + accepted by the libpq PQconnectdb function, + described in Section 31.1. If any option is + unspecified in this string, then the corresponding environment + variable (see Section 31.14) is checked. If the + environment variable is not set either, then + defaults are used. +

The connection string should specify the host name (or address) + of the primary server, as well as the port number if it is not + the same as the standby server's default. + Also specify a user name corresponding to a suitably-privileged role + on the primary (see + Section 25.2.5.1). + A password needs to be provided too, if the primary demands password + authentication. It can be provided in the + primary_conninfo string, or in a separate + ~/.pgpass file on the standby server (use + replication as the database name). + Do not specify a database name in the + primary_conninfo string. +

This setting has no effect if standby_mode is off. +

trigger_file (string)

Specifies a trigger file whose presence ends recovery in the + standby. Even if this value is not set, you can still promote + the standby using pg_ctl promote. + This setting has no effect if standby_mode is off. +


PrevHomeNext
Recovery Target SettingsUpMonitoring Database Activity
\ No newline at end of file diff --git a/doc/src/sgml/html/storage-file-layout.html b/doc/src/sgml/html/storage-file-layout.html new file mode 100644 index 000000000..99de29f91 --- /dev/null +++ b/doc/src/sgml/html/storage-file-layout.html @@ -0,0 +1,716 @@ + +Database File Layout
PostgreSQL 9.2.2 Documentation
PrevUpChapter 56. Database Physical StorageNext

56.1. Database File Layout

This section describes the storage format at the level of files and +directories.

All the data needed for a database cluster is stored within the cluster's data +directory, commonly referred to as PGDATA (after the name of the +environment variable that can be used to define it). A common location for +PGDATA is /var/lib/pgsql/data. Multiple clusters, +managed by different server instances, can exist on the same machine.

The PGDATA directory contains several subdirectories and control +files, as shown in Table 56-1. In addition to +these required items, the cluster configuration files +postgresql.conf, pg_hba.conf, and +pg_ident.conf are traditionally stored in +PGDATA (although in PostgreSQL 8.0 and +later, it is possible to keep them elsewhere).

Table 56-1. Contents of PGDATA

ItemDescription
PG_VERSIONA file containing the major version number of PostgreSQL
baseSubdirectory containing per-database subdirectories
globalSubdirectory containing cluster-wide tables, such as + pg_database
pg_clogSubdirectory containing transaction commit status data
pg_multixactSubdirectory containing multitransaction status data + (used for shared row locks)
pg_notifySubdirectory containing LISTEN/NOTIFY status data
pg_serialSubdirectory containing information about committed serializable transactions
pg_snapshotsSubdirectory containing exported snapshots
pg_stat_tmpSubdirectory containing temporary files for the statistics + subsystem
pg_subtransSubdirectory containing subtransaction status data
pg_tblspcSubdirectory containing symbolic links to tablespaces
pg_twophaseSubdirectory containing state files for prepared transactions
pg_xlogSubdirectory containing WAL (Write Ahead Log) files
postmaster.optsA file recording the command-line options the server was +last started with
postmaster.pidA lock file recording the current postmaster process ID (PID), + cluster data directory path, + postmaster start timestamp, + port number, + Unix-domain socket directory path (empty on Windows), + first valid listen_address (IP address or *, or empty if + not listening on TCP), + and shared memory segment ID + (this file is not present after server shutdown)

For each database in the cluster there is a subdirectory within +PGDATA/base, named after the database's OID in +pg_database. This subdirectory is the default location +for the database's files; in particular, its system catalogs are stored +there.

Each table and index is stored in a separate file. For ordinary relations, +these files are named after the table or index's filenode number, +which can be found in pg_class.relfilenode. But +for temporary relations, the file name is of the form +tBBB_FFF, where BBB +is the backend ID of the backend which created the file, and FFF +is the filenode number. In either case, in addition to the main file (a/k/a +main fork), each table and index has a free space map (see Section 56.3), which stores information about free space available in +the relation. The free space map is stored in a file named with the filenode +number plus the suffix _fsm. Tables also have a +visibility map, stored in a fork with the suffix _vm, +to track which pages are known to have no dead tuples. The visibility map is +described further in Section 56.4. Unlogged tables and indexes +have a third fork, known as the initialization fork, which is stored in a fork +with the suffix _init (see Section 56.5).

Caution

Note that while a table's filenode often matches its OID, this is +not necessarily the case; some operations, like +TRUNCATE, REINDEX, CLUSTER and some forms +of ALTER TABLE, can change the filenode while preserving the OID. +Avoid assuming that filenode and table OID are the same. +Also, for certain system catalogs including pg_class itself, +pg_class.relfilenode contains zero. The +actual filenode number of these catalogs is stored in a lower-level data +structure, and can be obtained using the pg_relation_filenode() +function.

When a table or index exceeds 1 GB, it is divided into gigabyte-sized +segments. The first segment's file name is the same as the +filenode; subsequent segments are named filenode.1, filenode.2, etc. +This arrangement avoids problems on platforms that have file size limitations. +(Actually, 1 GB is just the default segment size. The segment size can be +adjusted using the configuration option --with-segsize +when building PostgreSQL.) +In principle, free space map and visibility map forks could require multiple +segments as well, though this is unlikely to happen in practice.

A table that has columns with potentially large entries will have an +associated TOAST table, which is used for out-of-line storage of +field values that are too large to keep in the table rows proper. +pg_class.reltoastrelid links from a table to +its TOAST table, if any. +See Section 56.2 for more information.

The contents of tables and indexes are discussed further in +Section 56.6.

Tablespaces make the scenario more complicated. Each user-defined tablespace +has a symbolic link inside the PGDATA/pg_tblspc +directory, which points to the physical tablespace directory (i.e., the +location specified in the tablespace's CREATE TABLESPACE command). +This symbolic link is named after +the tablespace's OID. Inside the physical tablespace directory there is +a subdirectory with a name that depends on the PostgreSQL +server version, such as PG_9.0_201008051. (The reason for using +this subdirectory is so that successive versions of the database can use +the same CREATE TABLESPACE location value without conflicts.) +Within the version-specific subdirectory, there is +a subdirectory for each database that has elements in the tablespace, named +after the database's OID. Tables and indexes are stored within that +directory, using the filenode naming scheme. +The pg_default tablespace is not accessed through +pg_tblspc, but corresponds to +PGDATA/base. Similarly, the pg_global +tablespace is not accessed through pg_tblspc, but corresponds to +PGDATA/global.

The pg_relation_filepath() function shows the entire path +(relative to PGDATA) of any relation. It is often useful +as a substitute for remembering many of the above rules. But keep in +mind that this function just gives the name of the first segment of the +main fork of the relation — you may need to append a segment number +and/or _fsm or _vm to find all the files associated +with the relation.

Temporary files (for operations such as sorting more data than can fit in +memory) are created within PGDATA/base/pgsql_tmp, +or within a pgsql_tmp subdirectory of a tablespace directory +if a tablespace other than pg_default is specified for them. +The name of a temporary file has the form +pgsql_tmpPPP.NNN, +where PPP is the PID of the owning backend and +NNN distinguishes different temporary files of that backend.


PrevHomeNext
Database Physical StorageUpTOAST
\ No newline at end of file diff --git a/doc/src/sgml/html/storage-fsm.html b/doc/src/sgml/html/storage-fsm.html new file mode 100644 index 000000000..e20b2b5dd --- /dev/null +++ b/doc/src/sgml/html/storage-fsm.html @@ -0,0 +1,213 @@ + +Free Space Map
PostgreSQL 9.2.2 Documentation
PrevUpChapter 56. Database Physical StorageNext

56.3. Free Space Map

Each heap and index relation, except for hash indexes, has a Free Space Map +(FSM) to keep track of available space in the relation. It's stored +alongside the main relation data in a separate relation fork, named after the +filenode number of the relation, plus a _fsm suffix. For example, +if the filenode of a relation is 12345, the FSM is stored in a file called +12345_fsm, in the same directory as the main relation file.

The Free Space Map is organized as a tree of FSM pages. The +bottom level FSM pages store the free space available on each +heap (or index) page, using one byte to represent each such page. The upper +levels aggregate information from the lower levels.

Within each FSM page is a binary tree, stored in an array with +one byte per node. Each leaf node represents a heap page, or a lower level +FSM page. In each non-leaf node, the higher of its children's +values is stored. The maximum value in the leaf nodes is therefore stored +at the root.

See src/backend/storage/freespace/README for more details on +how the FSM is structured, and how it's updated and searched. +The pg_freespacemap module +can be used to examine the information stored in free space maps.


PrevHomeNext
TOASTUpVisibility Map
\ No newline at end of file diff --git a/doc/src/sgml/html/storage-init.html b/doc/src/sgml/html/storage-init.html new file mode 100644 index 000000000..d6f71575b --- /dev/null +++ b/doc/src/sgml/html/storage-init.html @@ -0,0 +1,169 @@ + +The Initialization Fork
PostgreSQL 9.2.2 Documentation
PrevUpChapter 56. Database Physical StorageNext

56.5. The Initialization Fork

Each unlogged table, and each index on an unlogged table, has an initialization +fork. The initialization fork is an empty table or index of the appropriate +type. When an unlogged table must be reset to empty due to a crash, the +initialization fork is copied over the main fork, and any other forks are +erased (they will be recreated automatically as needed).


PrevHomeNext
Visibility MapUpDatabase Page Layout
\ No newline at end of file diff --git a/doc/src/sgml/html/storage-page-layout.html b/doc/src/sgml/html/storage-page-layout.html new file mode 100644 index 000000000..a04544c7f --- /dev/null +++ b/doc/src/sgml/html/storage-page-layout.html @@ -0,0 +1,754 @@ + +Database Page Layout
PostgreSQL 9.2.2 Documentation
PrevUpChapter 56. Database Physical StorageNext

56.6. Database Page Layout

This section provides an overview of the page format used within +PostgreSQL tables and indexes.[1] +Sequences and TOAST tables are formatted just like a regular table.

In the following explanation, a +byte +is assumed to contain 8 bits. In addition, the term +item +refers to an individual data value that is stored on a page. In a table, +an item is a row; in an index, an item is an index entry.

Every table and index is stored as an array of pages of a +fixed size (usually 8 kB, although a different page size can be selected +when compiling the server). In a table, all the pages are logically +equivalent, so a particular item (row) can be stored in any page. In +indexes, the first page is generally reserved as a metapage +holding control information, and there can be different types of pages +within the index, depending on the index access method.

Table 56-2 shows the overall layout of a page. +There are five parts to each page.

Table 56-2. Overall Page Layout

ItemDescription
PageHeaderData24 bytes long. Contains general information about the page, including +free space pointers.
ItemIdDataArray of (offset,length) pairs pointing to the actual items. +4 bytes per item.
Free spaceThe unallocated space. New item pointers are allocated from the start +of this area, new items from the end.
ItemsThe actual items themselves.
Special spaceIndex access method specific data. Different methods store different +data. Empty in ordinary tables.

The first 24 bytes of each page consists of a page header + (PageHeaderData). Its format is detailed in Table 56-3. The first two fields track the most + recent WAL entry related to this page. Next is a 2-byte field + containing flag bits. This is followed by three 2-byte integer fields + (pd_lower, pd_upper, + and pd_special). These contain byte offsets + from the page start to the start + of unallocated space, to the end of unallocated space, and to the start of + the special space. + The next 2 bytes of the page header, + pd_pagesize_version, store both the page size + and a version indicator. Beginning with + PostgreSQL 8.3 the version number is 4; + PostgreSQL 8.1 and 8.2 used version number 3; + PostgreSQL 8.0 used version number 2; + PostgreSQL 7.3 and 7.4 used version number 1; + prior releases used version number 0. + (The basic page layout and header format has not changed in most of these + versions, but the layout of heap row headers has.) The page size + is basically only present as a cross-check; there is no support for having + more than one page size in an installation. + The last field is a hint that shows whether pruning the page is likely + to be profitable: it tracks the oldest un-pruned XMAX on the page. + +

Table 56-3. PageHeaderData Layout

FieldTypeLengthDescription
pd_lsnXLogRecPtr8 bytesLSN: next byte after last byte of xlog record for last change + to this page
pd_tliuint162 bytesTimeLineID of last change (only its lowest 16 bits)
pd_flagsuint162 bytesFlag bits
pd_lowerLocationIndex2 bytesOffset to start of free space
pd_upperLocationIndex2 bytesOffset to end of free space
pd_specialLocationIndex2 bytesOffset to start of special space
pd_pagesize_versionuint162 bytesPage size and layout version number information
pd_prune_xidTransactionId4 bytesOldest unpruned XMAX on page, or zero if none

All the details can be found in + src/include/storage/bufpage.h. +

Following the page header are item identifiers + (ItemIdData), each requiring four bytes. + An item identifier contains a byte-offset to + the start of an item, its length in bytes, and a few attribute bits + which affect its interpretation. + New item identifiers are allocated + as needed from the beginning of the unallocated space. + The number of item identifiers present can be determined by looking at + pd_lower, which is increased to allocate a new identifier. + Because an item + identifier is never moved until it is freed, its index can be used on a + long-term basis to reference an item, even when the item itself is moved + around on the page to compact free space. In fact, every pointer to an + item (ItemPointer, also known as + CTID) created by + PostgreSQL consists of a page number and the + index of an item identifier. + +

The items themselves are stored in space allocated backwards from the end + of unallocated space. The exact structure varies depending on what the + table is to contain. Tables and sequences both use a structure named + HeapTupleHeaderData, described below. + +

The final section is the "special section" which can + contain anything the access method wishes to store. For example, + b-tree indexes store links to the page's left and right siblings, + as well as some other data relevant to the index structure. + Ordinary tables do not use a special section at all (indicated by setting + pd_special to equal the page size). + +

All table rows are structured in the same way. There is a fixed-size + header (occupying 23 bytes on most machines), followed by an optional null + bitmap, an optional object ID field, and the user data. The header is + detailed + in Table 56-4. The actual user data + (columns of the row) begins at the offset indicated by + t_hoff, which must always be a multiple of the MAXALIGN + distance for the platform. + The null bitmap is + only present if the HEAP_HASNULL bit is set in + t_infomask. If it is present it begins just after + the fixed header and occupies enough bytes to have one bit per data column + (that is, t_natts bits altogether). In this list of bits, a + 1 bit indicates not-null, a 0 bit is a null. When the bitmap is not + present, all columns are assumed not-null. + The object ID is only present if the HEAP_HASOID bit + is set in t_infomask. If present, it appears just + before the t_hoff boundary. Any padding needed to make + t_hoff a MAXALIGN multiple will appear between the null + bitmap and the object ID. (This in turn ensures that the object ID is + suitably aligned.) + +

Table 56-4. HeapTupleHeaderData Layout

FieldTypeLengthDescription
t_xminTransactionId4 bytesinsert XID stamp
t_xmaxTransactionId4 bytesdelete XID stamp
t_cidCommandId4 bytesinsert and/or delete CID stamp (overlays with t_xvac)
t_xvacTransactionId4 bytesXID for VACUUM operation moving a row version
t_ctidItemPointerData6 bytescurrent TID of this or newer row version
t_infomask2uint162 bytesnumber of attributes, plus various flag bits
t_infomaskuint162 bytesvarious flag bits
t_hoffuint81 byteoffset to user data

All the details can be found in + src/include/access/htup.h. +

Interpreting the actual data can only be done with information obtained + from other tables, mostly pg_attribute. The + key values needed to identify field locations are + attlen and attalign. + There is no way to directly get a + particular attribute, except when there are only fixed width fields and no + null values. All this trickery is wrapped up in the functions + heap_getattr, fastgetattr + and heap_getsysattr. + +

To read the data you need to examine each attribute in turn. First check + whether the field is NULL according to the null bitmap. If it is, go to + the next. Then make sure you have the right alignment. If the field is a + fixed width field, then all the bytes are simply placed. If it's a + variable length field (attlen = -1) then it's a bit more complicated. + All variable-length data types share the common header structure + struct varlena, which includes the total length of the stored + value and some flag bits. Depending on the flags, the data can be either + inline or in a TOAST table; + it might be compressed, too (see Section 56.2). + +

Notes

[1]

Actually, index access methods need not use this page format. + All the existing index methods do use this basic format, + but the data kept on index metapages usually doesn't follow + the item layout rules. +


PrevHomeNext
The Initialization ForkUpBKI Backend Interface
\ No newline at end of file diff --git a/doc/src/sgml/html/storage-toast.html b/doc/src/sgml/html/storage-toast.html new file mode 100644 index 000000000..72194d64d --- /dev/null +++ b/doc/src/sgml/html/storage-toast.html @@ -0,0 +1,477 @@ + +TOAST
PostgreSQL 9.2.2 Documentation
PrevUpChapter 56. Database Physical StorageNext

56.2. TOAST

This section provides an overview of TOAST (The +Oversized-Attribute Storage Technique).

PostgreSQL uses a fixed page size (commonly +8 kB), and does not allow tuples to span multiple pages. Therefore, it is +not possible to store very large field values directly. To overcome +this limitation, large field values are compressed and/or broken up into +multiple physical rows. This happens transparently to the user, with only +small impact on most of the backend code. The technique is affectionately +known as TOAST (or "the best thing since sliced bread").

Only certain data types support TOAST — there is no need to +impose the overhead on data types that cannot produce large field values. +To support TOAST, a data type must have a variable-length +(varlena) representation, in which the first 32-bit word of any +stored value contains the total length of the value in bytes (including +itself). TOAST does not constrain the rest of the representation. +All the C-level functions supporting a TOAST-able data type must +be careful to handle TOASTed input values. (This is normally done +by invoking PG_DETOAST_DATUM before doing anything with an input +value, but in some cases more efficient approaches are possible.)

TOAST usurps two bits of the varlena length word (the high-order +bits on big-endian machines, the low-order bits on little-endian machines), +thereby limiting the logical size of any value of a TOAST-able +data type to 1 GB (230 - 1 bytes). When both bits are zero, +the value is an ordinary un-TOASTed value of the data type, and +the remaining bits of the length word give the total datum size (including +length word) in bytes. When the highest-order or lowest-order bit is set, +the value has only a single-byte header instead of the normal four-byte +header, and the remaining bits give the total datum size (including length +byte) in bytes. As a special case, if the remaining bits are all zero +(which would be impossible for a self-inclusive length), the value is a +pointer to out-of-line data stored in a separate TOAST table. (The size of +a TOAST pointer is given in the second byte of the datum.) +Values with single-byte headers aren't aligned on any particular +boundary, either. Lastly, when the highest-order or lowest-order bit is +clear but the adjacent bit is set, the content of the datum has been +compressed and must be decompressed before use. In this case the remaining +bits of the length word give the total size of the compressed datum, not the +original data. Note that compression is also possible for out-of-line data +but the varlena header does not tell whether it has occurred — +the content of the TOAST pointer tells that, instead.

If any of the columns of a table are TOAST-able, the table will +have an associated TOAST table, whose OID is stored in the table's +pg_class.reltoastrelid entry. Out-of-line +TOASTed values are kept in the TOAST table, as +described in more detail below.

The compression technique used is a fairly simple and very fast member +of the LZ family of compression techniques. See +src/backend/utils/adt/pg_lzcompress.c for the details.

Out-of-line values are divided (after compression if used) into chunks of at +most TOAST_MAX_CHUNK_SIZE bytes (by default this value is chosen +so that four chunk rows will fit on a page, making it about 2000 bytes). +Each chunk is stored +as a separate row in the TOAST table for the owning table. Every +TOAST table has the columns chunk_id (an OID +identifying the particular TOASTed value), +chunk_seq (a sequence number for the chunk within its value), +and chunk_data (the actual data of the chunk). A unique index +on chunk_id and chunk_seq provides fast +retrieval of the values. A pointer datum representing an out-of-line +TOASTed value therefore needs to store the OID of the +TOAST table in which to look and the OID of the specific value +(its chunk_id). For convenience, pointer datums also store the +logical datum size (original uncompressed data length) and actual stored size +(different if compression was applied). Allowing for the varlena header bytes, +the total size of a TOAST pointer datum is therefore 18 bytes +regardless of the actual size of the represented value.

The TOAST code is triggered only +when a row value to be stored in a table is wider than +TOAST_TUPLE_THRESHOLD bytes (normally 2 kB). +The TOAST code will compress and/or move +field values out-of-line until the row value is shorter than +TOAST_TUPLE_TARGET bytes (also normally 2 kB) +or no more gains can be had. During an UPDATE +operation, values of unchanged fields are normally preserved as-is; so an +UPDATE of a row with out-of-line values incurs no TOAST costs if +none of the out-of-line values change.

The TOAST code recognizes four different strategies for storing +TOAST-able columns: + +

  • PLAIN prevents either compression or + out-of-line storage; furthermore it disables use of single-byte headers + for varlena types. + This is the only possible strategy for + columns of non-TOAST-able data types. +

  • EXTENDED allows both compression and out-of-line + storage. This is the default for most TOAST-able data types. + Compression will be attempted first, then out-of-line storage if + the row is still too big. +

  • EXTERNAL allows out-of-line storage but not + compression. Use of EXTERNAL will + make substring operations on wide text and + bytea columns faster (at the penalty of increased storage + space) because these operations are optimized to fetch only the + required parts of the out-of-line value when it is not compressed. +

  • MAIN allows compression but not out-of-line + storage. (Actually, out-of-line storage will still be performed + for such columns, but only as a last resort when there is no other + way to make the row small enough to fit on a page.) +

+ +Each TOAST-able data type specifies a default strategy for columns +of that data type, but the strategy for a given table column can be altered +with ALTER TABLE SET STORAGE.

This scheme has a number of advantages compared to a more straightforward +approach such as allowing row values to span pages. Assuming that queries are +usually qualified by comparisons against relatively small key values, most of +the work of the executor will be done using the main row entry. The big values +of TOASTed attributes will only be pulled out (if selected at all) +at the time the result set is sent to the client. Thus, the main table is much +smaller and more of its rows fit in the shared buffer cache than would be the +case without any out-of-line storage. Sort sets shrink also, and sorts will +more often be done entirely in memory. A little test showed that a table +containing typical HTML pages and their URLs was stored in about half of the +raw data size including the TOAST table, and that the main table +contained only about 10% of the entire data (the URLs and some small HTML +pages). There was no run time difference compared to an un-TOASTed +comparison table, in which all the HTML pages were cut down to 7 kB to fit.


PrevHomeNext
Database File LayoutUpFree Space Map
\ No newline at end of file diff --git a/doc/src/sgml/html/storage-vm.html b/doc/src/sgml/html/storage-vm.html new file mode 100644 index 000000000..1e3a013bd --- /dev/null +++ b/doc/src/sgml/html/storage-vm.html @@ -0,0 +1,192 @@ + +Visibility Map
PostgreSQL 9.2.2 Documentation
PrevUpChapter 56. Database Physical StorageNext

56.4. Visibility Map

Each heap relation has a Visibility Map +(VM) to keep track of which pages contain only tuples that are known to be +visible to all active transactions. It's stored +alongside the main relation data in a separate relation fork, named after the +filenode number of the relation, plus a _vm suffix. For example, +if the filenode of a relation is 12345, the VM is stored in a file called +12345_vm, in the same directory as the main relation file. +Note that indexes do not have VMs.

The visibility map simply stores one bit per heap page. A set bit means +that all tuples on the page are known to be visible to all transactions. +This means that the page does not contain any tuples that need to be vacuumed. +This information can also be used by index-only scans to answer +queries using only the index tuple.

The map is conservative in the sense that we make sure that whenever a bit is +set, we know the condition is true, but if a bit is not set, it might or +might not be true. Visibility map bits are only set by vacuum, but are +cleared by any data-modifying operations on a page.


PrevHomeNext
Free Space MapUpThe Initialization Fork
\ No newline at end of file diff --git a/doc/src/sgml/html/storage.html b/doc/src/sgml/html/storage.html new file mode 100644 index 000000000..1a21d1e78 --- /dev/null +++ b/doc/src/sgml/html/storage.html @@ -0,0 +1,207 @@ + +Database Physical Storage

Chapter 56. Database Physical Storage

This chapter provides an overview of the physical storage format used by +PostgreSQL databases.


PrevHomeNext
ExamplesUpDatabase File Layout
\ No newline at end of file diff --git a/doc/src/sgml/html/stylesheet.css b/doc/src/sgml/html/stylesheet.css new file mode 100644 index 000000000..0fd0f0178 --- /dev/null +++ b/doc/src/sgml/html/stylesheet.css @@ -0,0 +1,96 @@ +/* doc/src/sgml/stylesheet.css */ + +/* color scheme similar to www.postgresql.org */ + +BODY { + color: #000000; + background: #FFFFFF; + font-family: verdana, sans-serif; +} + +A:link { color:#0066A2; } +A:visited { color:#004E66; } +A:active { color:#0066A2; } +A:hover { color:#000000; } + +H1 { + font-size: 1.4em; + font-weight: bold; + margin-top: 0em; + margin-bottom: 0em; + color: #EC5800; +} + +H2 { + font-size: 1.2em; + margin: 1.2em 0em 1.2em 0em; + font-weight: bold; + color: #666; +} + +H3 { + font-size: 1.1em; + margin: 1.2em 0em 1.2em 0em; + font-weight: bold; + color: #666; +} + +H4 { + font-size: 0.95em; + margin: 1.2em 0em 1.2em 0em; + font-weight: normal; + color: #666; +} + +H5 { + font-size: 0.9em; + margin: 1.2em 0em 1.2em 0em; + font-weight: normal; +} + +H6 { + font-size: 0.85em; + margin: 1.2em 0em 1.2em 0em; + font-weight: normal; +} + +/* center some titles */ + +.BOOK .TITLE, .BOOK .CORPAUTHOR, .BOOK .COPYRIGHT { + text-align: center; +} + +/* decoration for formal examples */ + +DIV.EXAMPLE { + padding-left: 15px; + border-style: solid; + border-width: 0px; + border-left-width: 2px; + border-color: black; + margin: 0.5ex; +} + +/* less dense spacing of TOC */ + +.BOOK .TOC DL DT { + padding-top: 1.5ex; + padding-bottom: 1.5ex; +} + +.BOOK .TOC DL DL DT { + padding-top: 0ex; + padding-bottom: 0ex; +} + +/* miscellaneous */ + +PRE.LITERALLAYOUT, .SCREEN, .SYNOPSIS, .PROGRAMLISTING { + margin-left: 4ex; +} + +.COMMENT { color: red; } + +VAR { font-family: monospace; font-style: italic; } +/* Konqueror's standard style for ACRONYM is italic. */ +ACRONYM { font-style: inherit; } diff --git a/doc/src/sgml/html/supported-platforms.html b/doc/src/sgml/html/supported-platforms.html new file mode 100644 index 000000000..d82476da3 --- /dev/null +++ b/doc/src/sgml/html/supported-platforms.html @@ -0,0 +1,241 @@ + +Supported Platforms
PostgreSQL 9.2.2 Documentation
PrevUpChapter 15. Installation from Source CodeNext

15.6. Supported Platforms

A platform (that is, a CPU architecture and operating system combination) + is considered supported by the PostgreSQL development + community if the code contains provisions to work on that platform and + it has recently been verified to build and pass its regression tests + on that platform. Currently, most testing of platform compatibility + is done automatically by test machines in the + PostgreSQL Build Farm. + If you are interested in using PostgreSQL on a platform + that is not represented in the build farm, but on which the code works + or can be made to work, you are strongly encouraged to set up a build + farm member machine so that continued compatibility can be assured. +

In general, PostgreSQL can be expected to work on + these CPU architectures: x86, x86_64, IA64, PowerPC, + PowerPC 64, S/390, S/390x, Sparc, Sparc 64, Alpha, ARM, MIPS, MIPSEL, M68K, + and PA-RISC. Code support exists for M32R, NS32K, and VAX, but these + architectures are not known to have been tested recently. It is often + possible to build on an unsupported CPU type by configuring with + --disable-spinlocks, but performance will be poor. +

PostgreSQL can be expected to work on these operating + systems: Linux (all recent distributions), Windows (Win2000 SP4 and later), + FreeBSD, OpenBSD, NetBSD, Mac OS X, AIX, HP/UX, IRIX, Solaris, Tru64 Unix, + and UnixWare. Other Unix-like systems may also work but are not currently + being tested. In most cases, all CPU architectures supported by + a given operating system will work. Look in + the Section 15.7 below to see if + there is information + specific to your operating system, particularly if using an older system. +

If you have installation problems on a platform that is known + to be supported according to recent build farm results, please report + it to <pgsql-bugs@postgresql.org>. If you are interested + in porting PostgreSQL to a new platform, + <pgsql-hackers@postgresql.org> is the appropriate place + to discuss that. +


PrevHomeNext
Post-Installation SetupUpPlatform-specific Notes
\ No newline at end of file diff --git a/doc/src/sgml/html/tablefunc.html b/doc/src/sgml/html/tablefunc.html new file mode 100644 index 000000000..6156d988c --- /dev/null +++ b/doc/src/sgml/html/tablefunc.html @@ -0,0 +1,1528 @@ + +tablefunc
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.35. tablefunc

The tablefunc module includes various functions that return + tables (that is, multiple rows). These functions are useful both in their + own right and as examples of how to write C functions that return + multiple rows. +

F.35.1. Functions Provided

Table F-28 shows the functions provided + by the tablefunc module. +

Table F-28. tablefunc Functions

FunctionReturnsDescription
normal_rand(int numvals, float8 mean, float8 stddev)setof float8 Produces a set of normally distributed random values +
crosstab(text sql)setof record Produces a "pivot table" containing + row names plus N value columns, where + N is determined by the row type specified in the calling + query +
crosstabN(text sql)setof table_crosstab_N Produces a "pivot table" containing + row names plus N value columns. + crosstab2, crosstab3, and + crosstab4 are predefined, but you can create additional + crosstabN functions as described below +
crosstab(text source_sql, text category_sql)setof record Produces a "pivot table" + with the value columns specified by a second query +
crosstab(text sql, int N)setof record

Obsolete version of crosstab(text). + The parameter N is now ignored, since the number of + value columns is always determined by the calling query +

+
connectby(text relname, text keyid_fld, text parent_keyid_fld + [, text orderby_fld ], text start_with, int max_depth + [, text branch_delim ]) + + setof record Produces a representation of a hierarchical tree structure +

F.35.1.1. normal_rand

normal_rand(int numvals, float8 mean, float8 stddev) returns setof float8

normal_rand produces a set of normally distributed random + values (Gaussian distribution). +

numvals is the number of values to be returned + from the function. mean is the mean of the normal + distribution of values and stddev is the standard + deviation of the normal distribution of values. +

For example, this call requests 1000 values with a mean of 5 and a + standard deviation of 3: +

test=# SELECT * FROM normal_rand(1000, 5, 3);
+     normal_rand
+----------------------
+     1.56556322244898
+     9.10040991424657
+     5.36957140345079
+   -0.369151492880995
+    0.283600703686639
+       .
+       .
+       .
+     4.82992125404908
+     9.71308014517282
+     2.49639286969028
+(1000 rows)

F.35.1.2. crosstab(text)

crosstab(text sql)
+crosstab(text sql, int N)

The crosstab function is used to produce "pivot" + displays, wherein data is listed across the page rather than down. + For example, we might have data like +

row1    val11
+row1    val12
+row1    val13
+...
+row2    val21
+row2    val22
+row2    val23
+...

+ which we wish to display like +

row1    val11   val12   val13   ...
+row2    val21   val22   val23   ...
+...

+ The crosstab function takes a text parameter that is a SQL + query producing raw data formatted in the first way, and produces a table + formatted in the second way. +

The sql parameter is a SQL statement that produces + the source set of data. This statement must return one + row_name column, one + category column, and one + value column. N is an + obsolete parameter, ignored if supplied (formerly this had to match the + number of output value columns, but now that is determined by the + calling query). +

For example, the provided query might produce a set something like: +

 row_name    cat    value
+----------+-------+-------
+  row1      cat1    val1
+  row1      cat2    val2
+  row1      cat3    val3
+  row1      cat4    val4
+  row2      cat1    val5
+  row2      cat2    val6
+  row2      cat3    val7
+  row2      cat4    val8

+

The crosstab function is declared to return setof + record, so the actual names and types of the output columns must be + defined in the FROM clause of the calling SELECT + statement, for example: +

SELECT * FROM crosstab('...') AS ct(row_name text, category_1 text, category_2 text);

+ This example produces a set something like: +

           <== value  columns  ==>
+ row_name   category_1   category_2
+----------+------------+------------
+  row1        val1         val2
+  row2        val5         val6

+

The FROM clause must define the output as one + row_name column (of the same data type as the first result + column of the SQL query) followed by N value columns + (all of the same data type as the third result column of the SQL query). + You can set up as many output value columns as you wish. The names of the + output columns are up to you. +

The crosstab function produces one output row for each + consecutive group of input rows with the same + row_name value. It fills the output + value columns, left to right, with the + value fields from these rows. If there + are fewer rows in a group than there are output value + columns, the extra output columns are filled with nulls; if there are + more rows, the extra input rows are skipped. +

In practice the SQL query should always specify ORDER BY 1,2 + to ensure that the input rows are properly ordered, that is, values with + the same row_name are brought together and + correctly ordered within the row. Notice that crosstab + itself does not pay any attention to the second column of the query + result; it's just there to be ordered by, to control the order in which + the third-column values appear across the page. +

Here is a complete example: +

CREATE TABLE ct(id SERIAL, rowid TEXT, attribute TEXT, value TEXT);
+INSERT INTO ct(rowid, attribute, value) VALUES('test1','att1','val1');
+INSERT INTO ct(rowid, attribute, value) VALUES('test1','att2','val2');
+INSERT INTO ct(rowid, attribute, value) VALUES('test1','att3','val3');
+INSERT INTO ct(rowid, attribute, value) VALUES('test1','att4','val4');
+INSERT INTO ct(rowid, attribute, value) VALUES('test2','att1','val5');
+INSERT INTO ct(rowid, attribute, value) VALUES('test2','att2','val6');
+INSERT INTO ct(rowid, attribute, value) VALUES('test2','att3','val7');
+INSERT INTO ct(rowid, attribute, value) VALUES('test2','att4','val8');
+
+SELECT *
+FROM crosstab(
+  'select rowid, attribute, value
+   from ct
+   where attribute = ''att2'' or attribute = ''att3''
+   order by 1,2')
+AS ct(row_name text, category_1 text, category_2 text, category_3 text);
+
+ row_name | category_1 | category_2 | category_3
+----------+------------+------------+------------
+ test1    | val2       | val3       |
+ test2    | val6       | val7       |
+(2 rows)

+

You can avoid always having to write out a FROM clause to + define the output columns, by setting up a custom crosstab function that + has the desired output row type wired into its definition. This is + described in the next section. Another possibility is to embed the + required FROM clause in a view definition. +

F.35.1.3. crosstabN(text)

crosstabN(text sql)

The crosstabN functions are examples of how + to set up custom wrappers for the general crosstab function, + so that you need not write out column names and types in the calling + SELECT query. The tablefunc module includes + crosstab2, crosstab3, and + crosstab4, whose output row types are defined as +

CREATE TYPE tablefunc_crosstab_N AS (
+    row_name TEXT,
+    category_1 TEXT,
+    category_2 TEXT,
+        .
+        .
+        .
+    category_N TEXT
+);

Thus, these functions can be used directly when the input query produces + row_name and value columns of type + text, and you want 2, 3, or 4 output values columns. + In all other ways they behave exactly as described above for the + general crosstab function. +

For instance, the example given in the previous section would also + work as +

SELECT *
+FROM crosstab3(
+  'select rowid, attribute, value
+   from ct
+   where attribute = ''att2'' or attribute = ''att3''
+   order by 1,2');

+

These functions are provided mostly for illustration purposes. You + can create your own return types and functions based on the + underlying crosstab() function. There are two ways + to do it: + +

  • Create a composite type describing the desired output columns, + similar to the examples in + contrib/tablefunc/tablefunc--1.0.sql. + Then define a + unique function name accepting one text parameter and returning + setof your_type_name, but linking to the same underlying + crosstab C function. For example, if your source data + produces row names that are text, and values that are + float8, and you want 5 value columns: +

    CREATE TYPE my_crosstab_float8_5_cols AS (
    +    my_row_name text,
    +    my_category_1 float8,
    +    my_category_2 float8,
    +    my_category_3 float8,
    +    my_category_4 float8,
    +    my_category_5 float8
    +);
    +
    +CREATE OR REPLACE FUNCTION crosstab_float8_5_cols(text)
    +    RETURNS setof my_crosstab_float8_5_cols
    +    AS '$libdir/tablefunc','crosstab' LANGUAGE C STABLE STRICT;

    +

  • Use OUT parameters to define the return type implicitly. + The same example could also be done this way: +

    CREATE OR REPLACE FUNCTION crosstab_float8_5_cols(
    +    IN text,
    +    OUT my_row_name text,
    +    OUT my_category_1 float8,
    +    OUT my_category_2 float8,
    +    OUT my_category_3 float8,
    +    OUT my_category_4 float8,
    +    OUT my_category_5 float8)
    +  RETURNS setof record
    +  AS '$libdir/tablefunc','crosstab' LANGUAGE C STABLE STRICT;

    +

+

F.35.1.4. crosstab(text, text)

crosstab(text source_sql, text category_sql)

The main limitation of the single-parameter form of crosstab + is that it treats all values in a group alike, inserting each value into + the first available column. If you want the value + columns to correspond to specific categories of data, and some groups + might not have data for some of the categories, that doesn't work well. + The two-parameter form of crosstab handles this case by + providing an explicit list of the categories corresponding to the + output columns. +

source_sql is a SQL statement that produces the + source set of data. This statement must return one + row_name column, one + category column, and one + value column. It may also have one or more + "extra" columns. + The row_name column must be first. The + category and value + columns must be the last two columns, in that order. Any columns between + row_name and + category are treated as "extra". + The "extra" columns are expected to be the same for all rows + with the same row_name value. +

For example, source_sql might produce a set + something like: +

SELECT row_name, extra_col, cat, value FROM foo ORDER BY 1;
+
+ row_name    extra_col   cat    value
+----------+------------+-----+---------
+  row1         extra1    cat1    val1
+  row1         extra1    cat2    val2
+  row1         extra1    cat4    val4
+  row2         extra2    cat1    val5
+  row2         extra2    cat2    val6
+  row2         extra2    cat3    val7
+  row2         extra2    cat4    val8

+

category_sql is a SQL statement that produces + the set of categories. This statement must return only one column. + It must produce at least one row, or an error will be generated. + Also, it must not produce duplicate values, or an error will be + generated. category_sql might be something like: + +

SELECT DISTINCT cat FROM foo ORDER BY 1;
+    cat
+  -------
+    cat1
+    cat2
+    cat3
+    cat4

+

The crosstab function is declared to return setof + record, so the actual names and types of the output columns must be + defined in the FROM clause of the calling SELECT + statement, for example: + +

SELECT * FROM crosstab('...', '...')
+    AS ct(row_name text, extra text, cat1 text, cat2 text, cat3 text, cat4 text);

+

This will produce a result something like: +

                  <==  value  columns   ==>
+row_name   extra   cat1   cat2   cat3   cat4
+---------+-------+------+------+------+------
+  row1     extra1  val1   val2          val4
+  row2     extra2  val5   val6   val7   val8

+

The FROM clause must define the proper number of output + columns of the proper data types. If there are N + columns in the source_sql query's result, the first + N-2 of them must match up with the first + N-2 output columns. The remaining output columns + must have the type of the last column of the source_sql + query's result, and there must be exactly as many of them as there + are rows in the category_sql query's result. +

The crosstab function produces one output row for each + consecutive group of input rows with the same + row_name value. The output + row_name column, plus any "extra" + columns, are copied from the first row of the group. The output + value columns are filled with the + value fields from rows having matching + category values. If a row's category + does not match any output of the category_sql + query, its value is ignored. Output + columns whose matching category is not present in any input row + of the group are filled with nulls. +

In practice the source_sql query should always + specify ORDER BY 1 to ensure that values with the same + row_name are brought together. However, + ordering of the categories within a group is not important. + Also, it is essential to be sure that the order of the + category_sql query's output matches the specified + output column order. +

Here are two complete examples: +

create table sales(year int, month int, qty int);
+insert into sales values(2007, 1, 1000);
+insert into sales values(2007, 2, 1500);
+insert into sales values(2007, 7, 500);
+insert into sales values(2007, 11, 1500);
+insert into sales values(2007, 12, 2000);
+insert into sales values(2008, 1, 1000);
+
+select * from crosstab(
+  'select year, month, qty from sales order by 1',
+  'select m from generate_series(1,12) m'
+) as (
+  year int,
+  "Jan" int,
+  "Feb" int,
+  "Mar" int,
+  "Apr" int,
+  "May" int,
+  "Jun" int,
+  "Jul" int,
+  "Aug" int,
+  "Sep" int,
+  "Oct" int,
+  "Nov" int,
+  "Dec" int
+);
+ year | Jan  | Feb  | Mar | Apr | May | Jun | Jul | Aug | Sep | Oct | Nov  | Dec
+------+------+------+-----+-----+-----+-----+-----+-----+-----+-----+------+------
+ 2007 | 1000 | 1500 |     |     |     |     | 500 |     |     |     | 1500 | 2000
+ 2008 | 1000 |      |     |     |     |     |     |     |     |     |      |
+(2 rows)

+ +

CREATE TABLE cth(rowid text, rowdt timestamp, attribute text, val text);
+INSERT INTO cth VALUES('test1','01 March 2003','temperature','42');
+INSERT INTO cth VALUES('test1','01 March 2003','test_result','PASS');
+INSERT INTO cth VALUES('test1','01 March 2003','volts','2.6987');
+INSERT INTO cth VALUES('test2','02 March 2003','temperature','53');
+INSERT INTO cth VALUES('test2','02 March 2003','test_result','FAIL');
+INSERT INTO cth VALUES('test2','02 March 2003','test_startdate','01 March 2003');
+INSERT INTO cth VALUES('test2','02 March 2003','volts','3.1234');
+
+SELECT * FROM crosstab
+(
+  'SELECT rowid, rowdt, attribute, val FROM cth ORDER BY 1',
+  'SELECT DISTINCT attribute FROM cth ORDER BY 1'
+)
+AS
+(
+       rowid text,
+       rowdt timestamp,
+       temperature int4,
+       test_result text,
+       test_startdate timestamp,
+       volts float8
+);
+ rowid |          rowdt           | temperature | test_result |      test_startdate      | volts
+-------+--------------------------+-------------+-------------+--------------------------+--------
+ test1 | Sat Mar 01 00:00:00 2003 |          42 | PASS        |                          | 2.6987
+ test2 | Sun Mar 02 00:00:00 2003 |          53 | FAIL        | Sat Mar 01 00:00:00 2003 | 3.1234
+(2 rows)

+

You can create predefined functions to avoid having to write out + the result column names and types in each query. See the examples + in the previous section. The underlying C function for this form + of crosstab is named crosstab_hash. +

F.35.1.5. connectby

connectby(text relname, text keyid_fld, text parent_keyid_fld
+          [, text orderby_fld ], text start_with, int max_depth
+          [, text branch_delim ])

The connectby function produces a display of hierarchical + data that is stored in a table. The table must have a key field that + uniquely identifies rows, and a parent-key field that references the + parent (if any) of each row. connectby can display the + sub-tree descending from any row. +

Table F-29 explains the + parameters. +

Table F-29. connectby Parameters

ParameterDescription
relnameName of the source relation
keyid_fldName of the key field
parent_keyid_fldName of the parent-key field
orderby_fldName of the field to order siblings by (optional)
start_withKey value of the row to start at
max_depthMaximum depth to descend to, or zero for unlimited depth
branch_delimString to separate keys with in branch output (optional)

The key and parent-key fields can be any data type, but they must be + the same type. Note that the start_with value must be + entered as a text string, regardless of the type of the key field. +

The connectby function is declared to return setof + record, so the actual names and types of the output columns must be + defined in the FROM clause of the calling SELECT + statement, for example: +

SELECT * FROM connectby('connectby_tree', 'keyid', 'parent_keyid', 'pos', 'row2', 0, '~')
+    AS t(keyid text, parent_keyid text, level int, branch text, pos int);

The first two output columns are used for the current row's key and + its parent row's key; they must match the type of the table's key field. + The third output column is the depth in the tree and must be of type + integer. If a branch_delim parameter was + given, the next output column is the branch display and must be of type + text. Finally, if an orderby_fld + parameter was given, the last output column is a serial number, and must + be of type integer. +

The "branch" output column shows the path of keys taken to + reach the current row. The keys are separated by the specified + branch_delim string. If no branch display is + wanted, omit both the branch_delim parameter + and the branch column in the output column list. +

If the ordering of siblings of the same parent is important, + include the orderby_fld parameter to + specify which field to order siblings by. This field can be of any + sortable data type. The output column list must include a final + integer serial-number column, if and only if + orderby_fld is specified. +

The parameters representing table and field names are copied as-is + into the SQL queries that connectby generates internally. + Therefore, include double quotes if the names are mixed-case or contain + special characters. You may also need to schema-qualify the table name. +

In large tables, performance will be poor unless there is an index on + the parent-key field. +

It is important that the branch_delim string + not appear in any key values, else connectby may incorrectly + report an infinite-recursion error. Note that if + branch_delim is not provided, a default value + of ~ is used for recursion detection purposes. + +

Here is an example: +

CREATE TABLE connectby_tree(keyid text, parent_keyid text, pos int);
+
+INSERT INTO connectby_tree VALUES('row1',NULL, 0);
+INSERT INTO connectby_tree VALUES('row2','row1', 0);
+INSERT INTO connectby_tree VALUES('row3','row1', 0);
+INSERT INTO connectby_tree VALUES('row4','row2', 1);
+INSERT INTO connectby_tree VALUES('row5','row2', 0);
+INSERT INTO connectby_tree VALUES('row6','row4', 0);
+INSERT INTO connectby_tree VALUES('row7','row3', 0);
+INSERT INTO connectby_tree VALUES('row8','row6', 0);
+INSERT INTO connectby_tree VALUES('row9','row5', 0);
+
+-- with branch, without orderby_fld (order of results is not guaranteed)
+SELECT * FROM connectby('connectby_tree', 'keyid', 'parent_keyid', 'row2', 0, '~')
+ AS t(keyid text, parent_keyid text, level int, branch text);
+ keyid | parent_keyid | level |       branch
+-------+--------------+-------+---------------------
+ row2  |              |     0 | row2
+ row4  | row2         |     1 | row2~row4
+ row6  | row4         |     2 | row2~row4~row6
+ row8  | row6         |     3 | row2~row4~row6~row8
+ row5  | row2         |     1 | row2~row5
+ row9  | row5         |     2 | row2~row5~row9
+(6 rows)
+
+-- without branch, without orderby_fld (order of results is not guaranteed)
+SELECT * FROM connectby('connectby_tree', 'keyid', 'parent_keyid', 'row2', 0)
+ AS t(keyid text, parent_keyid text, level int);
+ keyid | parent_keyid | level
+-------+--------------+-------
+ row2  |              |     0
+ row4  | row2         |     1
+ row6  | row4         |     2
+ row8  | row6         |     3
+ row5  | row2         |     1
+ row9  | row5         |     2
+(6 rows)
+
+-- with branch, with orderby_fld (notice that row5 comes before row4)
+SELECT * FROM connectby('connectby_tree', 'keyid', 'parent_keyid', 'pos', 'row2', 0, '~')
+ AS t(keyid text, parent_keyid text, level int, branch text, pos int);
+ keyid | parent_keyid | level |       branch        | pos
+-------+--------------+-------+---------------------+-----
+ row2  |              |     0 | row2                |   1
+ row5  | row2         |     1 | row2~row5           |   2
+ row9  | row5         |     2 | row2~row5~row9      |   3
+ row4  | row2         |     1 | row2~row4           |   4
+ row6  | row4         |     2 | row2~row4~row6      |   5
+ row8  | row6         |     3 | row2~row4~row6~row8 |   6
+(6 rows)
+
+-- without branch, with orderby_fld (notice that row5 comes before row4)
+SELECT * FROM connectby('connectby_tree', 'keyid', 'parent_keyid', 'pos', 'row2', 0)
+ AS t(keyid text, parent_keyid text, level int, pos int);
+ keyid | parent_keyid | level | pos
+-------+--------------+-------+-----
+ row2  |              |     0 |   1
+ row5  | row2         |     1 |   2
+ row9  | row5         |     2 |   3
+ row4  | row2         |     1 |   4
+ row6  | row4         |     2 |   5
+ row8  | row6         |     3 |   6
+(6 rows)

+

F.35.2. Author

Joe Conway +


PrevHomeNext
sslinfoUptcn
\ No newline at end of file diff --git a/doc/src/sgml/html/tcn.html b/doc/src/sgml/html/tcn.html new file mode 100644 index 000000000..43179c631 --- /dev/null +++ b/doc/src/sgml/html/tcn.html @@ -0,0 +1,233 @@ + +tcn
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.36. tcn

The tcn module provides a trigger function that notifies + listeners of changes to any table on which it is attached. It must be + used as an AFTER trigger FOR EACH ROW. +

Only one parameter may be supplied to the function in a + CREATE TRIGGER statement, and that is optional. If supplied + it will be used for the channel name for the notifications. If omitted + tcn will be used for the channel name. +

The payload of the notifications consists of the table name, a letter to + indicate which type of operation was performed, and column name/value pairs + for primary key columns. Each part is separated from the next by a comma. + For ease of parsing using regular expressions, table and column names are + always wrapped in double quotes, and data values are always wrapped in + single quotes. Embedded quotes are doubled. +

A brief example of using the extension follows. + +

test=# create table tcndata
+test-#   (
+test(#     a int not null,
+test(#     b date not null,
+test(#     c text,
+test(#     primary key (a, b)
+test(#   );
+NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit index "tcndata_pkey" for table "tcndata"
+CREATE TABLE
+test=# create trigger tcndata_tcn_trigger
+test-#   after insert or update or delete on tcndata
+test-#   for each row execute procedure triggered_change_notification();
+CREATE TRIGGER
+test=# listen tcn;
+LISTEN
+test=# insert into tcndata values (1, date '2012-12-22', 'one'),
+test-#                            (1, date '2012-12-23', 'another'),
+test-#                            (2, date '2012-12-23', 'two');
+INSERT 0 3
+Asynchronous notification "tcn" with payload ""tcndata",I,"a"='1',"b"='2012-12-22'" received from server process with PID 22770.
+Asynchronous notification "tcn" with payload ""tcndata",I,"a"='1',"b"='2012-12-23'" received from server process with PID 22770.
+Asynchronous notification "tcn" with payload ""tcndata",I,"a"='2',"b"='2012-12-23'" received from server process with PID 22770.
+test=# update tcndata set c = 'uno' where a = 1;
+UPDATE 2
+Asynchronous notification "tcn" with payload ""tcndata",U,"a"='1',"b"='2012-12-22'" received from server process with PID 22770.
+Asynchronous notification "tcn" with payload ""tcndata",U,"a"='1',"b"='2012-12-23'" received from server process with PID 22770.
+test=# delete from tcndata where a = 1 and b = date '2012-12-22';
+DELETE 1
+Asynchronous notification "tcn" with payload ""tcndata",D,"a"='1',"b"='2012-12-22'" received from server process with PID 22770.

+


PrevHomeNext
tablefuncUptest_parser
\ No newline at end of file diff --git a/doc/src/sgml/html/test-parser.html b/doc/src/sgml/html/test-parser.html new file mode 100644 index 000000000..b02454fe4 --- /dev/null +++ b/doc/src/sgml/html/test-parser.html @@ -0,0 +1,260 @@ + +test_parser
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.37. test_parser

test_parser is an example of a custom parser for full-text + search. It doesn't do anything especially useful, but can serve as + a starting point for developing your own parser. +

test_parser recognizes words separated by white space, + and returns just two token types: + +

mydb=# SELECT * FROM ts_token_type('testparser');
+ tokid | alias |  description
+-------+-------+---------------
+     3 | word  | Word
+    12 | blank | Space symbols
+(2 rows)

+ + These token numbers have been chosen to be compatible with the default + parser's numbering. This allows us to use its headline() + function, thus keeping the example simple. +

F.37.1. Usage

Installing the test_parser extension creates a text search + parser testparser. It has no user-configurable parameters. +

You can test the parser with, for example, + +

mydb=# SELECT * FROM ts_parse('testparser', 'That''s my first own parser');
+ tokid | token
+-------+--------
+     3 | That's
+    12 |
+     3 | my
+    12 |
+     3 | first
+    12 |
+     3 | own
+    12 |
+     3 | parser

+

Real-world use requires setting up a text search configuration + that uses the parser. For example, + +

mydb=# CREATE TEXT SEARCH CONFIGURATION testcfg ( PARSER = testparser );
+CREATE TEXT SEARCH CONFIGURATION
+
+mydb=# ALTER TEXT SEARCH CONFIGURATION testcfg
+mydb-#   ADD MAPPING FOR word WITH english_stem;
+ALTER TEXT SEARCH CONFIGURATION
+
+mydb=#  SELECT to_tsvector('testcfg', 'That''s my first own parser');
+          to_tsvector
+-------------------------------
+ 'that':1 'first':3 'parser':5
+(1 row)
+
+mydb=# SELECT ts_headline('testcfg', 'Supernovae stars are the brightest phenomena in galaxies',
+mydb(#                    to_tsquery('testcfg', 'star'));
+                           ts_headline
+-----------------------------------------------------------------
+ Supernovae <b>stars</b> are the brightest phenomena in galaxies
+(1 row)

+


PrevHomeNext
tcnUptsearch2
\ No newline at end of file diff --git a/doc/src/sgml/html/textsearch-configuration.html b/doc/src/sgml/html/textsearch-configuration.html new file mode 100644 index 000000000..fa15e15eb --- /dev/null +++ b/doc/src/sgml/html/textsearch-configuration.html @@ -0,0 +1,331 @@ + +Configuration Example
PostgreSQL 9.2.2 Documentation
PrevUpChapter 12. Full Text SearchNext

12.7. Configuration Example

A text search configuration specifies all options necessary to transform a + document into a tsvector: the parser to use to break text + into tokens, and the dictionaries to use to transform each token into a + lexeme. Every call of + to_tsvector or to_tsquery + needs a text search configuration to perform its processing. + The configuration parameter + default_text_search_config + specifies the name of the default configuration, which is the + one used by text search functions if an explicit configuration + parameter is omitted. + It can be set in postgresql.conf, or set for an + individual session using the SET command. +

Several predefined text search configurations are available, and + you can create custom configurations easily. To facilitate management + of text search objects, a set of SQL commands + is available, and there are several psql commands that display information + about text search objects (Section 12.10). +

As an example we will create a configuration + pg, starting by duplicating the built-in + english configuration: + +

CREATE TEXT SEARCH CONFIGURATION public.pg ( COPY = pg_catalog.english );

+

We will use a PostgreSQL-specific synonym list + and store it in $SHAREDIR/tsearch_data/pg_dict.syn. + The file contents look like: + +

postgres    pg
+pgsql       pg
+postgresql  pg

+ + We define the synonym dictionary like this: + +

CREATE TEXT SEARCH DICTIONARY pg_dict (
+    TEMPLATE = synonym,
+    SYNONYMS = pg_dict
+);

+ + Next we register the Ispell dictionary + english_ispell, which has its own configuration files: + +

CREATE TEXT SEARCH DICTIONARY english_ispell (
+    TEMPLATE = ispell,
+    DictFile = english,
+    AffFile = english,
+    StopWords = english
+);

+ + Now we can set up the mappings for words in configuration + pg: + +

ALTER TEXT SEARCH CONFIGURATION pg
+    ALTER MAPPING FOR asciiword, asciihword, hword_asciipart,
+                      word, hword, hword_part
+    WITH pg_dict, english_ispell, english_stem;

+ + We choose not to index or search some token types that the built-in + configuration does handle: + +

ALTER TEXT SEARCH CONFIGURATION pg
+    DROP MAPPING FOR email, url, url_path, sfloat, float;

+

Now we can test our configuration: + +

SELECT * FROM ts_debug('public.pg', '
+PostgreSQL, the highly scalable, SQL compliant, open source object-relational
+database management system, is now undergoing beta testing of the next
+version of our software.
+');

+

The next step is to set the session to use the new configuration, which was + created in the public schema: + +

=> \dF
+   List of text search configurations
+ Schema  | Name | Description
+---------+------+-------------
+ public  | pg   |
+
+SET default_text_search_config = 'public.pg';
+SET
+
+SHOW default_text_search_config;
+ default_text_search_config
+----------------------------
+ public.pg

+


PrevHomeNext
DictionariesUpTesting and Debugging Text Search
\ No newline at end of file diff --git a/doc/src/sgml/html/textsearch-controls.html b/doc/src/sgml/html/textsearch-controls.html new file mode 100644 index 000000000..e9ed65d87 --- /dev/null +++ b/doc/src/sgml/html/textsearch-controls.html @@ -0,0 +1,1329 @@ + +Controlling Text Search
PostgreSQL 9.2.2 Documentation
PrevUpChapter 12. Full Text SearchNext

12.3. Controlling Text Search

To implement full text searching there must be a function to create a + tsvector from a document and a tsquery from a + user query. Also, we need to return results in a useful order, so we need + a function that compares documents with respect to their relevance to + the query. It's also important to be able to display the results nicely. + PostgreSQL provides support for all of these + functions. +

12.3.1. Parsing Documents

PostgreSQL provides the + function to_tsvector for converting a document to + the tsvector data type. +

to_tsvector([ config regconfig, ] document text) returns tsvector

to_tsvector parses a textual document into tokens, + reduces the tokens to lexemes, and returns a tsvector which + lists the lexemes together with their positions in the document. + The document is processed according to the specified or default + text search configuration. + Here is a simple example: + +

SELECT to_tsvector('english', 'a fat  cat sat on a mat - it ate a fat rats');
+                  to_tsvector
+-----------------------------------------------------
+ 'ate':9 'cat':3 'fat':2,11 'mat':7 'rat':12 'sat':4

+

In the example above we see that the resulting tsvector does not + contain the words a, on, or + it, the word rats became + rat, and the punctuation sign - was + ignored. +

The to_tsvector function internally calls a parser + which breaks the document text into tokens and assigns a type to + each token. For each token, a list of + dictionaries (Section 12.6) is consulted, + where the list can vary depending on the token type. The first dictionary + that recognizes the token emits one or more normalized + lexemes to represent the token. For example, + rats became rat because one of the + dictionaries recognized that the word rats is a plural + form of rat. Some words are recognized as + stop words (Section 12.6.1), which + causes them to be ignored since they occur too frequently to be useful in + searching. In our example these are + a, on, and it. + If no dictionary in the list recognizes the token then it is also ignored. + In this example that happened to the punctuation sign - + because there are in fact no dictionaries assigned for its token type + (Space symbols), meaning space tokens will never be + indexed. The choices of parser, dictionaries and which types of tokens to + index are determined by the selected text search configuration (Section 12.7). It is possible to have + many different configurations in the same database, and predefined + configurations are available for various languages. In our example + we used the default configuration english for the + English language. +

The function setweight can be used to label the + entries of a tsvector with a given weight, + where a weight is one of the letters A, B, + C, or D. + This is typically used to mark entries coming from + different parts of a document, such as title versus body. Later, this + information can be used for ranking of search results. +

Because to_tsvector(NULL) will + return NULL, it is recommended to use + coalesce whenever a field might be null. + Here is the recommended method for creating + a tsvector from a structured document: + +

UPDATE tt SET ti =
+    setweight(to_tsvector(coalesce(title,'')), 'A')    ||
+    setweight(to_tsvector(coalesce(keyword,'')), 'B')  ||
+    setweight(to_tsvector(coalesce(abstract,'')), 'C') ||
+    setweight(to_tsvector(coalesce(body,'')), 'D');

+ + Here we have used setweight to label the source + of each lexeme in the finished tsvector, and then merged + the labeled tsvector values using the tsvector + concatenation operator ||. (Section 12.4.1 gives details about these + operations.) +

12.3.2. Parsing Queries

PostgreSQL provides the + functions to_tsquery and + plainto_tsquery for converting a query to + the tsquery data type. to_tsquery + offers access to more features than plainto_tsquery, + but is less forgiving about its input. +

to_tsquery([ config regconfig, ] querytext text) returns tsquery

to_tsquery creates a tsquery value from + querytext, which must consist of single tokens + separated by the Boolean operators & (AND), + | (OR) and ! (NOT). These operators + can be grouped using parentheses. In other words, the input to + to_tsquery must already follow the general rules for + tsquery input, as described in Section 8.11. The difference is that while basic + tsquery input takes the tokens at face value, + to_tsquery normalizes each token to a lexeme using + the specified or default configuration, and discards any tokens that are + stop words according to the configuration. For example: + +

SELECT to_tsquery('english', 'The & Fat & Rats');
+  to_tsquery   
+---------------
+ 'fat' & 'rat'

+ + As in basic tsquery input, weight(s) can be attached to each + lexeme to restrict it to match only tsvector lexemes of those + weight(s). For example: + +

SELECT to_tsquery('english', 'Fat | Rats:AB');
+    to_tsquery    
+------------------
+ 'fat' | 'rat':AB

+ + Also, * can be attached to a lexeme to specify prefix matching: + +

SELECT to_tsquery('supern:*A & star:A*B');
+        to_tsquery        
+--------------------------
+ 'supern':*A & 'star':*AB

+ + Such a lexeme will match any word in a tsvector that begins + with the given string. +

to_tsquery can also accept single-quoted + phrases. This is primarily useful when the configuration includes a + thesaurus dictionary that may trigger on such phrases. + In the example below, a thesaurus contains the rule supernovae + stars : sn: + +

SELECT to_tsquery('''supernovae stars'' & !crab');
+  to_tsquery
+---------------
+ 'sn' & !'crab'

+ + Without quotes, to_tsquery will generate a syntax + error for tokens that are not separated by an AND or OR operator. +

plainto_tsquery([ config regconfig, ] querytext text) returns tsquery

plainto_tsquery transforms unformatted text + querytext to tsquery. + The text is parsed and normalized much as for to_tsvector, + then the & (AND) Boolean operator is inserted + between surviving words. +

Example: + +

SELECT plainto_tsquery('english', 'The Fat Rats');
+ plainto_tsquery 
+-----------------
+ 'fat' & 'rat'

+ + Note that plainto_tsquery cannot + recognize Boolean operators, weight labels, or prefix-match labels + in its input: + +

SELECT plainto_tsquery('english', 'The Fat & Rats:C');
+   plainto_tsquery   
+---------------------
+ 'fat' & 'rat' & 'c'

+ + Here, all the input punctuation was discarded as being space symbols. +

12.3.3. Ranking Search Results

Ranking attempts to measure how relevant documents are to a particular + query, so that when there are many matches the most relevant ones can be + shown first. PostgreSQL provides two + predefined ranking functions, which take into account lexical, proximity, + and structural information; that is, they consider how often the query + terms appear in the document, how close together the terms are in the + document, and how important is the part of the document where they occur. + However, the concept of relevancy is vague and very application-specific. + Different applications might require additional information for ranking, + e.g., document modification time. The built-in ranking functions are only + examples. You can write your own ranking functions and/or combine their + results with additional factors to fit your specific needs. +

The two ranking functions currently available are: + +

ts_rank([ weights float4[], ] vector tsvector,
+        query tsquery [, normalization integer ]) returns float4

Ranks vectors based on the frequency of their matching lexemes. +

ts_rank_cd([ weights float4[], ] vector tsvector,
+           query tsquery [, normalization integer ]) returns float4

This function computes the cover density + ranking for the given document vector and query, as described in + Clarke, Cormack, and Tudhope's "Relevance Ranking for One to Three + Term Queries" in the journal "Information Processing and Management", + 1999. +

This function requires positional information in its input. + Therefore it will not work on "stripped" tsvector + values — it will always return zero. +

+ +

For both these functions, + the optional weights + argument offers the ability to weigh word instances more or less + heavily depending on how they are labeled. The weight arrays specify + how heavily to weigh each category of word, in the order: + +

{D-weight, C-weight, B-weight, A-weight}

+ + If no weights are provided, + then these defaults are used: + +

{0.1, 0.2, 0.4, 1.0}

+ + Typically weights are used to mark words from special areas of the + document, like the title or an initial abstract, so they can be + treated with more or less importance than words in the document body. +

Since a longer document has a greater chance of containing a query term + it is reasonable to take into account document size, e.g., a hundred-word + document with five instances of a search word is probably more relevant + than a thousand-word document with five instances. Both ranking functions + take an integer normalization option that + specifies whether and how a document's length should impact its rank. + The integer option controls several behaviors, so it is a bit mask: + you can specify one or more behaviors using + | (for example, 2|4). + +

  • 0 (the default) ignores the document length +

  • 1 divides the rank by 1 + the logarithm of the document length +

  • 2 divides the rank by the document length +

  • 4 divides the rank by the mean harmonic distance between extents + (this is implemented only by ts_rank_cd) +

  • 8 divides the rank by the number of unique words in document +

  • 16 divides the rank by 1 + the logarithm of the number + of unique words in document +

  • 32 divides the rank by itself + 1 +

+ + If more than one flag bit is specified, the transformations are + applied in the order listed. +

It is important to note that the ranking functions do not use any global + information, so it is impossible to produce a fair normalization to 1% or + 100% as sometimes desired. Normalization option 32 + (rank/(rank+1)) can be applied to scale all ranks + into the range zero to one, but of course this is just a cosmetic change; + it will not affect the ordering of the search results. +

Here is an example that selects only the ten highest-ranked matches: + +

SELECT title, ts_rank_cd(textsearch, query) AS rank
+FROM apod, to_tsquery('neutrino|(dark & matter)') query
+WHERE query @@ textsearch
+ORDER BY rank DESC
+LIMIT 10;
+                     title                     |   rank
+-----------------------------------------------+----------
+ Neutrinos in the Sun                          |      3.1
+ The Sudbury Neutrino Detector                 |      2.4
+ A MACHO View of Galactic Dark Matter          |  2.01317
+ Hot Gas and Dark Matter                       |  1.91171
+ The Virgo Cluster: Hot Plasma and Dark Matter |  1.90953
+ Rafting for Solar Neutrinos                   |      1.9
+ NGC 4650A: Strange Galaxy and Dark Matter     |  1.85774
+ Hot Gas and Dark Matter                       |   1.6123
+ Ice Fishing for Cosmic Neutrinos              |      1.6
+ Weak Lensing Distorts the Universe            | 0.818218

+ + This is the same example using normalized ranking: + +

SELECT title, ts_rank_cd(textsearch, query, 32 /* rank/(rank+1) */ ) AS rank
+FROM apod, to_tsquery('neutrino|(dark & matter)') query
+WHERE  query @@ textsearch
+ORDER BY rank DESC
+LIMIT 10;
+                     title                     |        rank
+-----------------------------------------------+-------------------
+ Neutrinos in the Sun                          | 0.756097569485493
+ The Sudbury Neutrino Detector                 | 0.705882361190954
+ A MACHO View of Galactic Dark Matter          | 0.668123210574724
+ Hot Gas and Dark Matter                       |  0.65655958650282
+ The Virgo Cluster: Hot Plasma and Dark Matter | 0.656301290640973
+ Rafting for Solar Neutrinos                   | 0.655172410958162
+ NGC 4650A: Strange Galaxy and Dark Matter     | 0.650072921219637
+ Hot Gas and Dark Matter                       | 0.617195790024749
+ Ice Fishing for Cosmic Neutrinos              | 0.615384618911517
+ Weak Lensing Distorts the Universe            | 0.450010798361481

+

Ranking can be expensive since it requires consulting the + tsvector of each matching document, which can be I/O bound and + therefore slow. Unfortunately, it is almost impossible to avoid since + practical queries often result in large numbers of matches. +

12.3.4. Highlighting Results

To present search results it is ideal to show a part of each document and + how it is related to the query. Usually, search engines show fragments of + the document with marked search terms. PostgreSQL + provides a function ts_headline that + implements this functionality. +

ts_headline([ config regconfig, ] document text, query tsquery [, options text ]) returns text

ts_headline accepts a document along + with a query, and returns an excerpt from + the document in which terms from the query are highlighted. The + configuration to be used to parse the document can be specified by + config; if config + is omitted, the + default_text_search_config configuration is used. +

If an options string is specified it must + consist of a comma-separated list of one or more + option=value pairs. + The available options are: + +

  • StartSel, StopSel: the strings with + which to delimit query words appearing in the document, to distinguish + them from other excerpted words. You must double-quote these strings + if they contain spaces or commas. +

  • MaxWords, MinWords: these numbers + determine the longest and shortest headlines to output. +

  • ShortWord: words of this length or less will be + dropped at the start and end of a headline. The default + value of three eliminates common English articles. +

  • HighlightAll: Boolean flag; if + true the whole document will be used as the + headline, ignoring the preceding three parameters. +

  • MaxFragments: maximum number of text excerpts + or fragments to display. The default value of zero selects a + non-fragment-oriented headline generation method. A value greater than + zero selects fragment-based headline generation. This method + finds text fragments with as many query words as possible and + stretches those fragments around the query words. As a result + query words are close to the middle of each fragment and have words on + each side. Each fragment will be of at most MaxWords and + words of length ShortWord or less are dropped at the start + and end of each fragment. If not all query words are found in the + document, then a single fragment of the first MinWords + in the document will be displayed. +

  • FragmentDelimiter: When more than one fragment is + displayed, the fragments will be separated by this string. +

+ + Any unspecified options receive these defaults: + +

StartSel=<b>, StopSel=</b>,
+MaxWords=35, MinWords=15, ShortWord=3, HighlightAll=FALSE,
+MaxFragments=0, FragmentDelimiter=" ... "

+

For example: + +

SELECT ts_headline('english',
+  'The most common type of search
+is to find all documents containing given query terms
+and return them in order of their similarity to the
+query.',
+  to_tsquery('query & similarity'));
+                        ts_headline                         
+------------------------------------------------------------
+ containing given <b>query</b> terms
+ and return them in order of their <b>similarity</b> to the
+ <b>query</b>.
+
+SELECT ts_headline('english',
+  'The most common type of search
+is to find all documents containing given query terms
+and return them in order of their similarity to the
+query.',
+  to_tsquery('query & similarity'),
+  'StartSel = <, StopSel = >');
+                      ts_headline                      
+-------------------------------------------------------
+ containing given <query> terms
+ and return them in order of their <similarity> to the
+ <query>.

+

ts_headline uses the original document, not a + tsvector summary, so it can be slow and should be used with + care. A typical mistake is to call ts_headline for + every matching document when only ten documents are + to be shown. SQL subqueries can help; here is an + example: + +

SELECT id, ts_headline(body, q), rank
+FROM (SELECT id, body, q, ts_rank_cd(ti, q) AS rank
+      FROM apod, to_tsquery('stars') q
+      WHERE ti @@ q
+      ORDER BY rank DESC
+      LIMIT 10) AS foo;

+


PrevHomeNext
Tables and IndexesUpAdditional Features
\ No newline at end of file diff --git a/doc/src/sgml/html/textsearch-debugging.html b/doc/src/sgml/html/textsearch-debugging.html new file mode 100644 index 000000000..d2e4d2d71 --- /dev/null +++ b/doc/src/sgml/html/textsearch-debugging.html @@ -0,0 +1,918 @@ + +Testing and Debugging Text Search
PostgreSQL 9.2.2 Documentation
PrevUpChapter 12. Full Text SearchNext

12.8. Testing and Debugging Text Search

The behavior of a custom text search configuration can easily become + confusing. The functions described + in this section are useful for testing text search objects. You can + test a complete configuration, or test parsers and dictionaries separately. +

12.8.1. Configuration Testing

The function ts_debug allows easy testing of a + text search configuration. +

ts_debug([ config regconfig, ] document text,
+         OUT alias text,
+         OUT description text,
+         OUT token text,
+         OUT dictionaries regdictionary[],
+         OUT dictionary regdictionary,
+         OUT lexemes text[])
+         returns setof record

ts_debug displays information about every token of + document as produced by the + parser and processed by the configured dictionaries. It uses the + configuration specified by config, + or default_text_search_config if that argument is + omitted. +

ts_debug returns one row for each token identified in the text + by the parser. The columns returned are + +

  • alias text — short name of the token type +

  • description text — description of the + token type +

  • token text — text of the token +

  • dictionaries regdictionary[] — the + dictionaries selected by the configuration for this token type +

  • dictionary regdictionary — the dictionary + that recognized the token, or NULL if none did +

  • lexemes text[] — the lexeme(s) produced + by the dictionary that recognized the token, or NULL if + none did; an empty array ({}) means it was recognized as a + stop word +

+

Here is a simple example: + +

SELECT * FROM ts_debug('english','a fat  cat sat on a mat - it ate a fat rats');
+   alias   |   description   | token |  dictionaries  |  dictionary  | lexemes 
+-----------+-----------------+-------+----------------+--------------+---------
+ asciiword | Word, all ASCII | a     | {english_stem} | english_stem | {}
+ blank     | Space symbols   |       | {}             |              | 
+ asciiword | Word, all ASCII | fat   | {english_stem} | english_stem | {fat}
+ blank     | Space symbols   |       | {}             |              | 
+ asciiword | Word, all ASCII | cat   | {english_stem} | english_stem | {cat}
+ blank     | Space symbols   |       | {}             |              | 
+ asciiword | Word, all ASCII | sat   | {english_stem} | english_stem | {sat}
+ blank     | Space symbols   |       | {}             |              | 
+ asciiword | Word, all ASCII | on    | {english_stem} | english_stem | {}
+ blank     | Space symbols   |       | {}             |              | 
+ asciiword | Word, all ASCII | a     | {english_stem} | english_stem | {}
+ blank     | Space symbols   |       | {}             |              | 
+ asciiword | Word, all ASCII | mat   | {english_stem} | english_stem | {mat}
+ blank     | Space symbols   |       | {}             |              | 
+ blank     | Space symbols   | -     | {}             |              | 
+ asciiword | Word, all ASCII | it    | {english_stem} | english_stem | {}
+ blank     | Space symbols   |       | {}             |              | 
+ asciiword | Word, all ASCII | ate   | {english_stem} | english_stem | {ate}
+ blank     | Space symbols   |       | {}             |              | 
+ asciiword | Word, all ASCII | a     | {english_stem} | english_stem | {}
+ blank     | Space symbols   |       | {}             |              | 
+ asciiword | Word, all ASCII | fat   | {english_stem} | english_stem | {fat}
+ blank     | Space symbols   |       | {}             |              | 
+ asciiword | Word, all ASCII | rats  | {english_stem} | english_stem | {rat}

+

For a more extensive demonstration, we + first create a public.english configuration and + Ispell dictionary for the English language: +

CREATE TEXT SEARCH CONFIGURATION public.english ( COPY = pg_catalog.english );
+
+CREATE TEXT SEARCH DICTIONARY english_ispell (
+    TEMPLATE = ispell,
+    DictFile = english,
+    AffFile = english,
+    StopWords = english
+);
+
+ALTER TEXT SEARCH CONFIGURATION public.english
+   ALTER MAPPING FOR asciiword WITH english_ispell, english_stem;
SELECT * FROM ts_debug('public.english','The Brightest supernovaes');
+   alias   |   description   |    token    |         dictionaries          |   dictionary   |   lexemes   
+-----------+-----------------+-------------+-------------------------------+----------------+-------------
+ asciiword | Word, all ASCII | The         | {english_ispell,english_stem} | english_ispell | {}
+ blank     | Space symbols   |             | {}                            |                | 
+ asciiword | Word, all ASCII | Brightest   | {english_ispell,english_stem} | english_ispell | {bright}
+ blank     | Space symbols   |             | {}                            |                | 
+ asciiword | Word, all ASCII | supernovaes | {english_ispell,english_stem} | english_stem   | {supernova}

In this example, the word Brightest was recognized by the + parser as an ASCII word (alias asciiword). + For this token type the dictionary list is + english_ispell and + english_stem. The word was recognized by + english_ispell, which reduced it to the noun + bright. The word supernovaes is + unknown to the english_ispell dictionary so it + was passed to the next dictionary, and, fortunately, was recognized (in + fact, english_stem is a Snowball dictionary which + recognizes everything; that is why it was placed at the end of the + dictionary list). +

The word The was recognized by the + english_ispell dictionary as a stop word (Section 12.6.1) and will not be indexed. + The spaces are discarded too, since the configuration provides no + dictionaries at all for them. +

You can reduce the width of the output by explicitly specifying which columns + you want to see: + +

SELECT alias, token, dictionary, lexemes
+FROM ts_debug('public.english','The Brightest supernovaes');
+   alias   |    token    |   dictionary   |   lexemes   
+-----------+-------------+----------------+-------------
+ asciiword | The         | english_ispell | {}
+ blank     |             |                | 
+ asciiword | Brightest   | english_ispell | {bright}
+ blank     |             |                | 
+ asciiword | supernovaes | english_stem   | {supernova}

+

12.8.2. Parser Testing

The following functions allow direct testing of a text search parser. +

ts_parse(parser_name text, document text,
+         OUT tokid integer, OUT token text) returns setof record
+ts_parse(parser_oid oid, document text,
+         OUT tokid integer, OUT token text) returns setof record

ts_parse parses the given document + and returns a series of records, one for each token produced by + parsing. Each record includes a tokid showing the + assigned token type and a token which is the text of the + token. For example: + +

SELECT * FROM ts_parse('default', '123 - a number');
+ tokid | token
+-------+--------
+    22 | 123
+    12 |
+    12 | -
+     1 | a
+    12 |
+     1 | number

+

ts_token_type(parser_name text, OUT tokid integer,
+              OUT alias text, OUT description text) returns setof record
+ts_token_type(parser_oid oid, OUT tokid integer,
+              OUT alias text, OUT description text) returns setof record

ts_token_type returns a table which describes each type of + token the specified parser can recognize. For each token type, the table + gives the integer tokid that the parser uses to label a + token of that type, the alias that names the token type + in configuration commands, and a short description. For + example: + +

SELECT * FROM ts_token_type('default');
+ tokid |      alias      |               description                
+-------+-----------------+------------------------------------------
+     1 | asciiword       | Word, all ASCII
+     2 | word            | Word, all letters
+     3 | numword         | Word, letters and digits
+     4 | email           | Email address
+     5 | url             | URL
+     6 | host            | Host
+     7 | sfloat          | Scientific notation
+     8 | version         | Version number
+     9 | hword_numpart   | Hyphenated word part, letters and digits
+    10 | hword_part      | Hyphenated word part, all letters
+    11 | hword_asciipart | Hyphenated word part, all ASCII
+    12 | blank           | Space symbols
+    13 | tag             | XML tag
+    14 | protocol        | Protocol head
+    15 | numhword        | Hyphenated word, letters and digits
+    16 | asciihword      | Hyphenated word, all ASCII
+    17 | hword           | Hyphenated word, all letters
+    18 | url_path        | URL path
+    19 | file            | File or path name
+    20 | float           | Decimal notation
+    21 | int             | Signed integer
+    22 | uint            | Unsigned integer
+    23 | entity          | XML entity

+

12.8.3. Dictionary Testing

The ts_lexize function facilitates dictionary testing. +

ts_lexize(dict regdictionary, token text) returns text[]

ts_lexize returns an array of lexemes if the input + token is known to the dictionary, + or an empty array if the token + is known to the dictionary but it is a stop word, or + NULL if it is an unknown word. +

Examples: + +

SELECT ts_lexize('english_stem', 'stars');
+ ts_lexize
+-----------
+ {star}
+
+SELECT ts_lexize('english_stem', 'a');
+ ts_lexize
+-----------
+ {}

+

Note: The ts_lexize function expects a single + token, not text. Here is a case + where this can be confusing: + +

SELECT ts_lexize('thesaurus_astro','supernovae stars') is null;
+ ?column?
+----------
+ t

+ + The thesaurus dictionary thesaurus_astro does know the + phrase supernovae stars, but ts_lexize + fails since it does not parse the input text but treats it as a single + token. Use plainto_tsquery or to_tsvector to + test thesaurus dictionaries, for example: + +

SELECT plainto_tsquery('supernovae stars');
+ plainto_tsquery
+-----------------
+ 'sn'

+


PrevHomeNext
Configuration ExampleUpGiST and GIN Index Types
\ No newline at end of file diff --git a/doc/src/sgml/html/textsearch-dictionaries.html b/doc/src/sgml/html/textsearch-dictionaries.html new file mode 100644 index 000000000..31c935ae5 --- /dev/null +++ b/doc/src/sgml/html/textsearch-dictionaries.html @@ -0,0 +1,1451 @@ + +Dictionaries
PostgreSQL 9.2.2 Documentation
PrevUpChapter 12. Full Text SearchNext

12.6. Dictionaries

Dictionaries are used to eliminate words that should not be considered in a + search (stop words), and to normalize words so + that different derived forms of the same word will match. A successfully + normalized word is called a lexeme. Aside from + improving search quality, normalization and removal of stop words reduce the + size of the tsvector representation of a document, thereby + improving performance. Normalization does not always have linguistic meaning + and usually depends on application semantics. +

Some examples of normalization: + +

  • Linguistic - Ispell dictionaries try to reduce input words to a + normalized form; stemmer dictionaries remove word endings +

  • URL locations can be canonicalized to make + equivalent URLs match: + +

    • http://www.pgsql.ru/db/mw/index.html +

    • http://www.pgsql.ru/db/mw/ +

    • http://www.pgsql.ru/db/../db/mw/index.html +

    +

  • Color names can be replaced by their hexadecimal values, e.g., + red, green, blue, magenta -> FF0000, 00FF00, 0000FF, FF00FF +

  • If indexing numbers, we can + remove some fractional digits to reduce the range of possible + numbers, so for example 3.14159265359, + 3.1415926, 3.14 will be the same + after normalization if only two digits are kept after the decimal point. +

+ +

A dictionary is a program that accepts a token as + input and returns: +

  • an array of lexemes if the input token is known to the dictionary + (notice that one token can produce more than one lexeme) +

  • a single lexeme with the TSL_FILTER flag set, to replace + the original token with a new token to be passed to subsequent + dictionaries (a dictionary that does this is called a + filtering dictionary) +

  • an empty array if the dictionary knows the token, but it is a stop word +

  • NULL if the dictionary does not recognize the input token +

+

PostgreSQL provides predefined dictionaries for + many languages. There are also several predefined templates that can be + used to create new dictionaries with custom parameters. Each predefined + dictionary template is described below. If no existing + template is suitable, it is possible to create new ones; see the + contrib/ area of the PostgreSQL distribution + for examples. +

A text search configuration binds a parser together with a set of + dictionaries to process the parser's output tokens. For each token + type that the parser can return, a separate list of dictionaries is + specified by the configuration. When a token of that type is found + by the parser, each dictionary in the list is consulted in turn, + until some dictionary recognizes it as a known word. If it is identified + as a stop word, or if no dictionary recognizes the token, it will be + discarded and not indexed or searched for. + Normally, the first dictionary that returns a non-NULL + output determines the result, and any remaining dictionaries are not + consulted; but a filtering dictionary can replace the given word + with a modified word, which is then passed to subsequent dictionaries. +

The general rule for configuring a list of dictionaries + is to place first the most narrow, most specific dictionary, then the more + general dictionaries, finishing with a very general dictionary, like + a Snowball stemmer or simple, which + recognizes everything. For example, for an astronomy-specific search + (astro_en configuration) one could bind token type + asciiword (ASCII word) to a synonym dictionary of astronomical + terms, a general English dictionary and a Snowball English + stemmer: + +

ALTER TEXT SEARCH CONFIGURATION astro_en
+    ADD MAPPING FOR asciiword WITH astrosyn, english_ispell, english_stem;

+

A filtering dictionary can be placed anywhere in the list, except at the + end where it'd be useless. Filtering dictionaries are useful to partially + normalize words to simplify the task of later dictionaries. For example, + a filtering dictionary could be used to remove accents from accented + letters, as is done by the unaccent module. +

12.6.1. Stop Words

Stop words are words that are very common, appear in almost every + document, and have no discrimination value. Therefore, they can be ignored + in the context of full text searching. For example, every English text + contains words like a and the, so it is + useless to store them in an index. However, stop words do affect the + positions in tsvector, which in turn affect ranking: + +

SELECT to_tsvector('english','in the list of stop words');
+        to_tsvector
+----------------------------
+ 'list':3 'stop':5 'word':6

+ + The missing positions 1,2,4 are because of stop words. Ranks + calculated for documents with and without stop words are quite different: + +

SELECT ts_rank_cd (to_tsvector('english','in the list of stop words'), to_tsquery('list & stop'));
+ ts_rank_cd
+------------
+       0.05
+
+SELECT ts_rank_cd (to_tsvector('english','list stop words'), to_tsquery('list & stop'));
+ ts_rank_cd
+------------
+        0.1

+ +

It is up to the specific dictionary how it treats stop words. For example, + ispell dictionaries first normalize words and then + look at the list of stop words, while Snowball stemmers + first check the list of stop words. The reason for the different + behavior is an attempt to decrease noise. +

12.6.2. Simple Dictionary

The simple dictionary template operates by converting the + input token to lower case and checking it against a file of stop words. + If it is found in the file then an empty array is returned, causing + the token to be discarded. If not, the lower-cased form of the word + is returned as the normalized lexeme. Alternatively, the dictionary + can be configured to report non-stop-words as unrecognized, allowing + them to be passed on to the next dictionary in the list. +

Here is an example of a dictionary definition using the simple + template: + +

CREATE TEXT SEARCH DICTIONARY public.simple_dict (
+    TEMPLATE = pg_catalog.simple,
+    STOPWORDS = english
+);

+ + Here, english is the base name of a file of stop words. + The file's full name will be + $SHAREDIR/tsearch_data/english.stop, + where $SHAREDIR means the + PostgreSQL installation's shared-data directory, + often /usr/local/share/postgresql (use pg_config + --sharedir to determine it if you're not sure). + The file format is simply a list + of words, one per line. Blank lines and trailing spaces are ignored, + and upper case is folded to lower case, but no other processing is done + on the file contents. +

Now we can test our dictionary: + +

SELECT ts_lexize('public.simple_dict','YeS');
+ ts_lexize
+-----------
+ {yes}
+
+SELECT ts_lexize('public.simple_dict','The');
+ ts_lexize
+-----------
+ {}

+

We can also choose to return NULL, instead of the lower-cased + word, if it is not found in the stop words file. This behavior is + selected by setting the dictionary's Accept parameter to + false. Continuing the example: + +

ALTER TEXT SEARCH DICTIONARY public.simple_dict ( Accept = false );
+
+SELECT ts_lexize('public.simple_dict','YeS');
+ ts_lexize
+-----------
+
+
+SELECT ts_lexize('public.simple_dict','The');
+ ts_lexize
+-----------
+ {}

+

With the default setting of Accept = true, + it is only useful to place a simple dictionary at the end + of a list of dictionaries, since it will never pass on any token to + a following dictionary. Conversely, Accept = false + is only useful when there is at least one following dictionary. +

Caution

Most types of dictionaries rely on configuration files, such as files of + stop words. These files must be stored in UTF-8 encoding. + They will be translated to the actual database encoding, if that is + different, when they are read into the server. +

Caution

Normally, a database session will read a dictionary configuration file + only once, when it is first used within the session. If you modify a + configuration file and want to force existing sessions to pick up the + new contents, issue an ALTER TEXT SEARCH DICTIONARY command + on the dictionary. This can be a "dummy" update that doesn't + actually change any parameter values. +

12.6.3. Synonym Dictionary

This dictionary template is used to create dictionaries that replace a + word with a synonym. Phrases are not supported (use the thesaurus + template (Section 12.6.4) for that). A synonym + dictionary can be used to overcome linguistic problems, for example, to + prevent an English stemmer dictionary from reducing the word "Paris" to + "pari". It is enough to have a Paris paris line in the + synonym dictionary and put it before the english_stem + dictionary. For example: + +

SELECT * FROM ts_debug('english', 'Paris');
+   alias   |   description   | token |  dictionaries  |  dictionary  | lexemes 
+-----------+-----------------+-------+----------------+--------------+---------
+ asciiword | Word, all ASCII | Paris | {english_stem} | english_stem | {pari}
+
+CREATE TEXT SEARCH DICTIONARY my_synonym (
+    TEMPLATE = synonym,
+    SYNONYMS = my_synonyms
+);
+
+ALTER TEXT SEARCH CONFIGURATION english
+    ALTER MAPPING FOR asciiword
+    WITH my_synonym, english_stem;
+
+SELECT * FROM ts_debug('english', 'Paris');
+   alias   |   description   | token |       dictionaries        | dictionary | lexemes 
+-----------+-----------------+-------+---------------------------+------------+---------
+ asciiword | Word, all ASCII | Paris | {my_synonym,english_stem} | my_synonym | {paris}

+

The only parameter required by the synonym template is + SYNONYMS, which is the base name of its configuration file + — my_synonyms in the above example. + The file's full name will be + $SHAREDIR/tsearch_data/my_synonyms.syn + (where $SHAREDIR means the + PostgreSQL installation's shared-data directory). + The file format is just one line + per word to be substituted, with the word followed by its synonym, + separated by white space. Blank lines and trailing spaces are ignored. +

The synonym template also has an optional parameter + CaseSensitive, which defaults to false. When + CaseSensitive is false, words in the synonym file + are folded to lower case, as are input tokens. When it is + true, words and tokens are not folded to lower case, + but are compared as-is. +

An asterisk (*) can be placed at the end of a synonym + in the configuration file. This indicates that the synonym is a prefix. + The asterisk is ignored when the entry is used in + to_tsvector(), but when it is used in + to_tsquery(), the result will be a query item with + the prefix match marker (see + Section 12.3.2). + For example, suppose we have these entries in + $SHAREDIR/tsearch_data/synonym_sample.syn: +

postgres        pgsql
+postgresql      pgsql
+postgre pgsql
+gogle   googl
+indices index*

+ Then we will get these results: +

mydb=# CREATE TEXT SEARCH DICTIONARY syn (template=synonym, synonyms='synonym_sample');
+mydb=# SELECT ts_lexize('syn','indices');
+ ts_lexize
+-----------
+ {index}
+(1 row)
+
+mydb=# CREATE TEXT SEARCH CONFIGURATION tst (copy=simple);
+mydb=# ALTER TEXT SEARCH CONFIGURATION tst ALTER MAPPING FOR asciiword WITH syn;
+mydb=# SELECT to_tsvector('tst','indices');
+ to_tsvector
+-------------
+ 'index':1
+(1 row)
+
+mydb=# SELECT to_tsquery('tst','indices');
+ to_tsquery
+------------
+ 'index':*
+(1 row)
+
+mydb=# SELECT 'indexes are very useful'::tsvector;
+            tsvector             
+---------------------------------
+ 'are' 'indexes' 'useful' 'very'
+(1 row)
+
+mydb=# SELECT 'indexes are very useful'::tsvector @@ to_tsquery('tst','indices');
+ ?column?
+----------
+ t
+(1 row)

+

12.6.4. Thesaurus Dictionary

A thesaurus dictionary (sometimes abbreviated as TZ) is + a collection of words that includes information about the relationships + of words and phrases, i.e., broader terms (BT), narrower + terms (NT), preferred terms, non-preferred terms, related + terms, etc. +

Basically a thesaurus dictionary replaces all non-preferred terms by one + preferred term and, optionally, preserves the original terms for indexing + as well. PostgreSQL's current implementation of the + thesaurus dictionary is an extension of the synonym dictionary with added + phrase support. A thesaurus dictionary requires + a configuration file of the following format: + +

# this is a comment
+sample word(s) : indexed word(s)
+more sample word(s) : more indexed word(s)
+...

+ + where the colon (:) symbol acts as a delimiter between a + a phrase and its replacement. +

A thesaurus dictionary uses a subdictionary (which + is specified in the dictionary's configuration) to normalize the input + text before checking for phrase matches. It is only possible to select one + subdictionary. An error is reported if the subdictionary fails to + recognize a word. In that case, you should remove the use of the word or + teach the subdictionary about it. You can place an asterisk + (*) at the beginning of an indexed word to skip applying + the subdictionary to it, but all sample words must be known + to the subdictionary. +

The thesaurus dictionary chooses the longest match if there are multiple + phrases matching the input, and ties are broken by using the last + definition. +

Specific stop words recognized by the subdictionary cannot be + specified; instead use ? to mark the location where any + stop word can appear. For example, assuming that a and + the are stop words according to the subdictionary: + +

? one ? two : swsw

+ + matches a one the two and the one a two; + both would be replaced by swsw. +

Since a thesaurus dictionary has the capability to recognize phrases it + must remember its state and interact with the parser. A thesaurus dictionary + uses these assignments to check if it should handle the next word or stop + accumulation. The thesaurus dictionary must be configured + carefully. For example, if the thesaurus dictionary is assigned to handle + only the asciiword token, then a thesaurus dictionary + definition like one 7 will not work since token type + uint is not assigned to the thesaurus dictionary. +

Caution

Thesauruses are used during indexing so any change in the thesaurus + dictionary's parameters requires reindexing. + For most other dictionary types, small changes such as adding or + removing stopwords does not force reindexing. +

12.6.4.1. Thesaurus Configuration

To define a new thesaurus dictionary, use the thesaurus + template. For example: + +

CREATE TEXT SEARCH DICTIONARY thesaurus_simple (
+    TEMPLATE = thesaurus,
+    DictFile = mythesaurus,
+    Dictionary = pg_catalog.english_stem
+);

+ + Here: +

  • thesaurus_simple is the new dictionary's name +

  • mythesaurus is the base name of the thesaurus + configuration file. + (Its full name will be $SHAREDIR/tsearch_data/mythesaurus.ths, + where $SHAREDIR means the installation shared-data + directory.) +

  • pg_catalog.english_stem is the subdictionary (here, + a Snowball English stemmer) to use for thesaurus normalization. + Notice that the subdictionary will have its own + configuration (for example, stop words), which is not shown here. +

+ + Now it is possible to bind the thesaurus dictionary thesaurus_simple + to the desired token types in a configuration, for example: + +

ALTER TEXT SEARCH CONFIGURATION russian
+    ALTER MAPPING FOR asciiword, asciihword, hword_asciipart
+    WITH thesaurus_simple;

+

12.6.4.2. Thesaurus Example

Consider a simple astronomical thesaurus thesaurus_astro, + which contains some astronomical word combinations: + +

supernovae stars : sn
+crab nebulae : crab

+ + Below we create a dictionary and bind some token types to + an astronomical thesaurus and English stemmer: + +

CREATE TEXT SEARCH DICTIONARY thesaurus_astro (
+    TEMPLATE = thesaurus,
+    DictFile = thesaurus_astro,
+    Dictionary = english_stem
+);
+
+ALTER TEXT SEARCH CONFIGURATION russian
+    ALTER MAPPING FOR asciiword, asciihword, hword_asciipart
+    WITH thesaurus_astro, english_stem;

+ + Now we can see how it works. + ts_lexize is not very useful for testing a thesaurus, + because it treats its input as a single token. Instead we can use + plainto_tsquery and to_tsvector + which will break their input strings into multiple tokens: + +

SELECT plainto_tsquery('supernova star');
+ plainto_tsquery
+-----------------
+ 'sn'
+
+SELECT to_tsvector('supernova star');
+ to_tsvector
+-------------
+ 'sn':1

+ + In principle, one can use to_tsquery if you quote + the argument: + +

SELECT to_tsquery('''supernova star''');
+ to_tsquery
+------------
+ 'sn'

+ + Notice that supernova star matches supernovae + stars in thesaurus_astro because we specified + the english_stem stemmer in the thesaurus definition. + The stemmer removed the e and s. +

To index the original phrase as well as the substitute, just include it + in the right-hand part of the definition: + +

supernovae stars : sn supernovae stars
+
+SELECT plainto_tsquery('supernova star');
+       plainto_tsquery
+-----------------------------
+ 'sn' & 'supernova' & 'star'

+

12.6.5. Ispell Dictionary

The Ispell dictionary template supports + morphological dictionaries, which can normalize many + different linguistic forms of a word into the same lexeme. For example, + an English Ispell dictionary can match all declensions and + conjugations of the search term bank, e.g., + banking, banked, banks, + banks', and bank's. +

The standard PostgreSQL distribution does + not include any Ispell configuration files. + Dictionaries for a large number of languages are available from Ispell. + Also, some more modern dictionary file formats are supported — MySpell (OO < 2.0.1) + and Hunspell + (OO >= 2.0.2). A large list of dictionaries is available on the OpenOffice + Wiki. +

To create an Ispell dictionary, use the built-in + ispell template and specify several parameters: +

CREATE TEXT SEARCH DICTIONARY english_ispell (
+    TEMPLATE = ispell,
+    DictFile = english,
+    AffFile = english,
+    StopWords = english
+);

Here, DictFile, AffFile, and StopWords + specify the base names of the dictionary, affixes, and stop-words files. + The stop-words file has the same format explained above for the + simple dictionary type. The format of the other files is + not specified here but is available from the above-mentioned web sites. +

Ispell dictionaries usually recognize a limited set of words, so they + should be followed by another broader dictionary; for + example, a Snowball dictionary, which recognizes everything. +

Ispell dictionaries support splitting compound words; + a useful feature. + Notice that the affix file should specify a special flag using the + compoundwords controlled statement that marks dictionary + words that can participate in compound formation: + +

compoundwords  controlled z

+ + Here are some examples for the Norwegian language: + +

SELECT ts_lexize('norwegian_ispell', 'overbuljongterningpakkmesterassistent');
+   {over,buljong,terning,pakk,mester,assistent}
+SELECT ts_lexize('norwegian_ispell', 'sjokoladefabrikk');
+   {sjokoladefabrikk,sjokolade,fabrikk}

+

Note: MySpell does not support compound words. + Hunspell has sophisticated support for compound words. At + present, PostgreSQL implements only the basic + compound word operations of Hunspell. +

12.6.6. Snowball Dictionary

The Snowball dictionary template is based on a project + by Martin Porter, inventor of the popular Porter's stemming algorithm + for the English language. Snowball now provides stemming algorithms for + many languages (see the Snowball + site for more information). Each algorithm understands how to + reduce common variant forms of words to a base, or stem, spelling within + its language. A Snowball dictionary requires a language + parameter to identify which stemmer to use, and optionally can specify a + stopword file name that gives a list of words to eliminate. + (PostgreSQL's standard stopword lists are also + provided by the Snowball project.) + For example, there is a built-in definition equivalent to + +

CREATE TEXT SEARCH DICTIONARY english_stem (
+    TEMPLATE = snowball,
+    Language = english,
+    StopWords = english
+);

+ + The stopword file format is the same as already explained. +

A Snowball dictionary recognizes everything, whether + or not it is able to simplify the word, so it should be placed + at the end of the dictionary list. It is useless to have it + before any other dictionary because a token will never pass through it to + the next dictionary. +


PrevHomeNext
ParsersUpConfiguration Example
\ No newline at end of file diff --git a/doc/src/sgml/html/textsearch-features.html b/doc/src/sgml/html/textsearch-features.html new file mode 100644 index 000000000..9933a96af --- /dev/null +++ b/doc/src/sgml/html/textsearch-features.html @@ -0,0 +1,1167 @@ + +Additional Features
PostgreSQL 9.2.2 Documentation
PrevUpChapter 12. Full Text SearchNext

12.4. Additional Features

This section describes additional functions and operators that are + useful in connection with text search. +

12.4.1. Manipulating Documents

Section 12.3.1 showed how raw textual + documents can be converted into tsvector values. + PostgreSQL also provides functions and + operators that can be used to manipulate documents that are already + in tsvector form. +

tsvector || tsvector

The tsvector concatenation operator + returns a vector which combines the lexemes and positional information + of the two vectors given as arguments. Positions and weight labels + are retained during the concatenation. + Positions appearing in the right-hand vector are offset by the largest + position mentioned in the left-hand vector, so that the result is + nearly equivalent to the result of performing to_tsvector + on the concatenation of the two original document strings. (The + equivalence is not exact, because any stop-words removed from the + end of the left-hand argument will not affect the result, whereas + they would have affected the positions of the lexemes in the + right-hand argument if textual concatenation were used.) +

One advantage of using concatenation in the vector form, rather than + concatenating text before applying to_tsvector, is that + you can use different configurations to parse different sections + of the document. Also, because the setweight function + marks all lexemes of the given vector the same way, it is necessary + to parse the text and do setweight before concatenating + if you want to label different parts of the document with different + weights. +

setweight(vector tsvector, weight "char") returns tsvector

setweight returns a copy of the input vector in which every + position has been labeled with the given weight, either + A, B, C, or + D. (D is the default for new + vectors and as such is not displayed on output.) These labels are + retained when vectors are concatenated, allowing words from different + parts of a document to be weighted differently by ranking functions. +

Note that weight labels apply to positions, not + lexemes. If the input vector has been stripped of + positions then setweight does nothing. +

length(vector tsvector) returns integer

Returns the number of lexemes stored in the vector. +

strip(vector tsvector) returns tsvector

Returns a vector which lists the same lexemes as the given vector, but + which lacks any position or weight information. While the returned + vector is much less useful than an unstripped vector for relevance + ranking, it will usually be much smaller. +

12.4.2. Manipulating Queries

Section 12.3.2 showed how raw textual + queries can be converted into tsquery values. + PostgreSQL also provides functions and + operators that can be used to manipulate queries that are already + in tsquery form. +

tsquery && tsquery

Returns the AND-combination of the two given queries. +

tsquery || tsquery

Returns the OR-combination of the two given queries. +

!! tsquery

Returns the negation (NOT) of the given query. +

numnode(query tsquery) returns integer

Returns the number of nodes (lexemes plus operators) in a + tsquery. This function is useful + to determine if the query is meaningful + (returns > 0), or contains only stop words (returns 0). + Examples: + +

SELECT numnode(plainto_tsquery('the any'));
+NOTICE:  query contains only stopword(s) or doesn't contain lexeme(s), ignored
+ numnode
+---------
+       0
+
+SELECT numnode('foo & bar'::tsquery);
+ numnode
+---------
+       3

+

querytree(query tsquery) returns text

Returns the portion of a tsquery that can be used for + searching an index. This function is useful for detecting + unindexable queries, for example those containing only stop words + or only negated terms. For example: + +

SELECT querytree(to_tsquery('!defined'));
+ querytree
+-----------

+

12.4.2.1. Query Rewriting

The ts_rewrite family of functions search a + given tsquery for occurrences of a target + subquery, and replace each occurrence with a + substitute subquery. In essence this operation is a + tsquery-specific version of substring replacement. + A target and substitute combination can be + thought of as a query rewrite rule. A collection + of such rewrite rules can be a powerful search aid. + For example, you can expand the search using synonyms + (e.g., new york, big apple, nyc, + gotham) or narrow the search to direct the user to some hot + topic. There is some overlap in functionality between this feature + and thesaurus dictionaries (Section 12.6.4). + However, you can modify a set of rewrite rules on-the-fly without + reindexing, whereas updating a thesaurus requires reindexing to be + effective. +

ts_rewrite (query tsquery, target tsquery, substitute tsquery) returns tsquery

This form of ts_rewrite simply applies a single + rewrite rule: target + is replaced by substitute + wherever it appears in query. For example: + +

SELECT ts_rewrite('a & b'::tsquery, 'a'::tsquery, 'c'::tsquery);
+ ts_rewrite
+------------
+ 'b' & 'c'

+

ts_rewrite (query tsquery, select text) returns tsquery

This form of ts_rewrite accepts a starting + query and a SQL select command, which + is given as a text string. The select must yield two + columns of tsquery type. For each row of the + select result, occurrences of the first column value + (the target) are replaced by the second column value (the substitute) + within the current query value. For example: + +

CREATE TABLE aliases (t tsquery PRIMARY KEY, s tsquery);
+INSERT INTO aliases VALUES('a', 'c');
+
+SELECT ts_rewrite('a & b'::tsquery, 'SELECT t,s FROM aliases');
+ ts_rewrite
+------------
+ 'b' & 'c'

+

Note that when multiple rewrite rules are applied in this way, + the order of application can be important; so in practice you will + want the source query to ORDER BY some ordering key. +

Let's consider a real-life astronomical example. We'll expand query + supernovae using table-driven rewriting rules: + +

CREATE TABLE aliases (t tsquery primary key, s tsquery);
+INSERT INTO aliases VALUES(to_tsquery('supernovae'), to_tsquery('supernovae|sn'));
+
+SELECT ts_rewrite(to_tsquery('supernovae & crab'), 'SELECT * FROM aliases');
+           ts_rewrite            
+---------------------------------
+ 'crab' & ( 'supernova' | 'sn' )

+ + We can change the rewriting rules just by updating the table: + +

UPDATE aliases
+SET s = to_tsquery('supernovae|sn & !nebulae')
+WHERE t = to_tsquery('supernovae');
+
+SELECT ts_rewrite(to_tsquery('supernovae & crab'), 'SELECT * FROM aliases');
+                 ts_rewrite                  
+---------------------------------------------
+ 'crab' & ( 'supernova' | 'sn' & !'nebula' )

+

Rewriting can be slow when there are many rewriting rules, since it + checks every rule for a possible match. To filter out obvious non-candidate + rules we can use the containment operators for the tsquery + type. In the example below, we select only those rules which might match + the original query: + +

SELECT ts_rewrite('a & b'::tsquery,
+                  'SELECT t,s FROM aliases WHERE ''a & b''::tsquery @> t');
+ ts_rewrite
+------------
+ 'b' & 'c'

+

12.4.3. Triggers for Automatic Updates

When using a separate column to store the tsvector representation + of your documents, it is necessary to create a trigger to update the + tsvector column when the document content columns change. + Two built-in trigger functions are available for this, or you can write + your own. +

tsvector_update_trigger(tsvector_column_name, config_name, text_column_name [, ... ])
+tsvector_update_trigger_column(tsvector_column_name, config_column_name, text_column_name [, ... ])

These trigger functions automatically compute a tsvector + column from one or more textual columns, under the control of + parameters specified in the CREATE TRIGGER command. + An example of their use is: + +

CREATE TABLE messages (
+    title       text,
+    body        text,
+    tsv         tsvector
+);
+
+CREATE TRIGGER tsvectorupdate BEFORE INSERT OR UPDATE
+ON messages FOR EACH ROW EXECUTE PROCEDURE
+tsvector_update_trigger(tsv, 'pg_catalog.english', title, body);
+
+INSERT INTO messages VALUES('title here', 'the body text is here');
+
+SELECT * FROM messages;
+   title    |         body          |            tsv             
+------------+-----------------------+----------------------------
+ title here | the body text is here | 'bodi':4 'text':5 'titl':1
+
+SELECT title, body FROM messages WHERE tsv @@ to_tsquery('title & body');
+   title    |         body          
+------------+-----------------------
+ title here | the body text is here

+ + Having created this trigger, any change in title or + body will automatically be reflected into + tsv, without the application having to worry about it. +

The first trigger argument must be the name of the tsvector + column to be updated. The second argument specifies the text search + configuration to be used to perform the conversion. For + tsvector_update_trigger, the configuration name is simply + given as the second trigger argument. It must be schema-qualified as + shown above, so that the trigger behavior will not change with changes + in search_path. For + tsvector_update_trigger_column, the second trigger argument + is the name of another table column, which must be of type + regconfig. This allows a per-row selection of configuration + to be made. The remaining argument(s) are the names of textual columns + (of type text, varchar, or char). These + will be included in the document in the order given. NULL values will + be skipped (but the other columns will still be indexed). +

A limitation of these built-in triggers is that they treat all the + input columns alike. To process columns differently — for + example, to weight title differently from body — it is necessary + to write a custom trigger. Here is an example using + PL/pgSQL as the trigger language: + +

CREATE FUNCTION messages_trigger() RETURNS trigger AS $$
+begin
+  new.tsv :=
+     setweight(to_tsvector('pg_catalog.english', coalesce(new.title,'')), 'A') ||
+     setweight(to_tsvector('pg_catalog.english', coalesce(new.body,'')), 'D');
+  return new;
+end
+$$ LANGUAGE plpgsql;
+
+CREATE TRIGGER tsvectorupdate BEFORE INSERT OR UPDATE
+    ON messages FOR EACH ROW EXECUTE PROCEDURE messages_trigger();

+

Keep in mind that it is important to specify the configuration name + explicitly when creating tsvector values inside triggers, + so that the column's contents will not be affected by changes to + default_text_search_config. Failure to do this is likely to + lead to problems such as search results changing after a dump and reload. +

12.4.4. Gathering Document Statistics

The function ts_stat is useful for checking your + configuration and for finding stop-word candidates. +

ts_stat(sqlquery text, [ weights text, ]
+        OUT word text, OUT ndoc integer,
+        OUT nentry integer) returns setof record

sqlquery is a text value containing an SQL + query which must return a single tsvector column. + ts_stat executes the query and returns statistics about + each distinct lexeme (word) contained in the tsvector + data. The columns returned are + +

  • word text — the value of a lexeme +

  • ndoc integer — number of documents + (tsvectors) the word occurred in +

  • nentry integer — total number of + occurrences of the word +

+ + If weights is supplied, only occurrences + having one of those weights are counted. +

For example, to find the ten most frequent words in a document collection: + +

SELECT * FROM ts_stat('SELECT vector FROM apod')
+ORDER BY nentry DESC, ndoc DESC, word
+LIMIT 10;

+ + The same, but counting only word occurrences with weight A + or B: + +

SELECT * FROM ts_stat('SELECT vector FROM apod', 'ab')
+ORDER BY nentry DESC, ndoc DESC, word
+LIMIT 10;

+


PrevHomeNext
Controlling Text SearchUpParsers
\ No newline at end of file diff --git a/doc/src/sgml/html/textsearch-indexes.html b/doc/src/sgml/html/textsearch-indexes.html new file mode 100644 index 000000000..44c595c05 --- /dev/null +++ b/doc/src/sgml/html/textsearch-indexes.html @@ -0,0 +1,379 @@ + +GiST and GIN Index Types
PostgreSQL 9.2.2 Documentation
PrevUpChapter 12. Full Text SearchNext

12.9. GiST and GIN Index Types

There are two kinds of indexes that can be used to speed up full text + searches. + Note that indexes are not mandatory for full text searching, but in + cases where a column is searched on a regular basis, an index is + usually desirable. + +

CREATE INDEX name ON table USING gist(column);

Creates a GiST (Generalized Search Tree)-based index. + The column can be of tsvector or + tsquery type. +

CREATE INDEX name ON table USING gin(column);

Creates a GIN (Generalized Inverted Index)-based index. + The column must be of tsvector type. +

+

There are substantial performance differences between the two index types, + so it is important to understand their characteristics. +

A GiST index is lossy, meaning that the index + may produce false matches, and it is necessary + to check the actual table row to eliminate such false matches. + (PostgreSQL does this automatically when needed.) + GiST indexes are lossy because each document is represented in the + index by a fixed-length signature. The signature is generated by hashing + each word into a single bit in an n-bit string, with all these bits OR-ed + together to produce an n-bit document signature. When two words hash to + the same bit position there will be a false match. If all words in + the query have matches (real or false) then the table row must be + retrieved to see if the match is correct. +

Lossiness causes performance degradation due to unnecessary fetches of table + records that turn out to be false matches. Since random access to table + records is slow, this limits the usefulness of GiST indexes. The + likelihood of false matches depends on several factors, in particular the + number of unique words, so using dictionaries to reduce this number is + recommended. +

GIN indexes are not lossy for standard queries, but their performance + depends logarithmically on the number of unique words. + (However, GIN indexes store only the words (lexemes) of tsvector + values, and not their weight labels. Thus a table row recheck is needed + when using a query that involves weights.) +

In choosing which index type to use, GiST or GIN, consider these + performance differences: + +

  • GIN index lookups are about three times faster than GiST +

  • GIN indexes take about three times longer to build than GiST +

  • GIN indexes are moderately slower to update than GiST indexes, but + about 10 times slower if fast-update support was disabled + (see Section 55.3.1 for details) +

  • GIN indexes are two-to-three times larger than GiST indexes +

+

As a rule of thumb, GIN indexes are best for static data + because lookups are faster. For dynamic data, GiST indexes are + faster to update. Specifically, GiST indexes are very + good for dynamic data and fast if the number of unique words (lexemes) is + under 100,000, while GIN indexes will handle 100,000+ + lexemes better but are slower to update. +

Note that GIN index build time can often be improved + by increasing maintenance_work_mem, while + GiST index build time is not sensitive to that + parameter. +

Partitioning of big collections and the proper use of GiST and GIN indexes + allows the implementation of very fast searches with online update. + Partitioning can be done at the database level using table inheritance, + or by distributing documents over + servers and collecting search results using the dblink + module. The latter is possible because ranking functions use + only local information. +


PrevHomeNext
Testing and Debugging Text SearchUppsql Support
\ No newline at end of file diff --git a/doc/src/sgml/html/textsearch-intro.html b/doc/src/sgml/html/textsearch-intro.html new file mode 100644 index 000000000..bb6a0506a --- /dev/null +++ b/doc/src/sgml/html/textsearch-intro.html @@ -0,0 +1,876 @@ + +Introduction
PostgreSQL 9.2.2 Documentation
PrevUpChapter 12. Full Text SearchNext

12.1. Introduction

Full Text Searching (or just text search) provides + the capability to identify natural-language documents that + satisfy a query, and optionally to sort them by + relevance to the query. The most common type of search + is to find all documents containing given query terms + and return them in order of their similarity to the + query. Notions of query and + similarity are very flexible and depend on the specific + application. The simplest search considers query as a + set of words and similarity as the frequency of query + words in the document. +

Textual search operators have existed in databases for years. + PostgreSQL has + ~, ~*, LIKE, and + ILIKE operators for textual data types, but they lack + many essential properties required by modern information systems: +

  • There is no linguistic support, even for English. Regular expressions + are not sufficient because they cannot easily handle derived words, e.g., + satisfies and satisfy. You might + miss documents that contain satisfies, although you + probably would like to find them when searching for + satisfy. It is possible to use OR + to search for multiple derived forms, but this is tedious and error-prone + (some words can have several thousand derivatives). +

  • They provide no ordering (ranking) of search results, which makes them + ineffective when thousands of matching documents are found. +

  • They tend to be slow because there is no index support, so they must + process all documents for every search. +

Full text indexing allows documents to be preprocessed + and an index saved for later rapid searching. Preprocessing includes: +

  • Parsing documents into tokens. It is + useful to identify various classes of tokens, e.g., numbers, words, + complex words, email addresses, so that they can be processed + differently. In principle token classes depend on the specific + application, but for most purposes it is adequate to use a predefined + set of classes. + PostgreSQL uses a parser to + perform this step. A standard parser is provided, and custom parsers + can be created for specific needs. +

  • Converting tokens into lexemes. + A lexeme is a string, just like a token, but it has been + normalized so that different forms of the same word + are made alike. For example, normalization almost always includes + folding upper-case letters to lower-case, and often involves removal + of suffixes (such as s or es in English). + This allows searches to find variant forms of the + same word, without tediously entering all the possible variants. + Also, this step typically eliminates stop words, which + are words that are so common that they are useless for searching. + (In short, then, tokens are raw fragments of the document text, while + lexemes are words that are believed useful for indexing and searching.) + PostgreSQL uses dictionaries to + perform this step. Various standard dictionaries are provided, and + custom ones can be created for specific needs. +

  • Storing preprocessed documents optimized for + searching. For example, each document can be represented + as a sorted array of normalized lexemes. Along with the lexemes it is + often desirable to store positional information to use for + proximity ranking, so that a document that + contains a more "dense" region of query words is + assigned a higher rank than one with scattered query words. +

Dictionaries allow fine-grained control over how tokens are normalized. + With appropriate dictionaries, you can: +

  • Define stop words that should not be indexed. +

  • Map synonyms to a single word using Ispell. +

  • Map phrases to a single word using a thesaurus. +

  • Map different variations of a word to a canonical form using + an Ispell dictionary. +

  • Map different variations of a word to a canonical form using + Snowball stemmer rules. +

A data type tsvector is provided for storing preprocessed + documents, along with a type tsquery for representing processed + queries (Section 8.11). There are many + functions and operators available for these data types + (Section 9.13), the most important of which is + the match operator @@, which we introduce in + Section 12.1.2. Full text searches can be accelerated + using indexes (Section 12.9). +

12.1.1. What Is a Document?

A document is the unit of searching in a full text search + system; for example, a magazine article or email message. The text search + engine must be able to parse documents and store associations of lexemes + (key words) with their parent document. Later, these associations are + used to search for documents that contain query words. +

For searches within PostgreSQL, + a document is normally a textual field within a row of a database table, + or possibly a combination (concatenation) of such fields, perhaps stored + in several tables or obtained dynamically. In other words, a document can + be constructed from different parts for indexing and it might not be + stored anywhere as a whole. For example: + +

SELECT title || ' ' ||  author || ' ' ||  abstract || ' ' || body AS document
+FROM messages
+WHERE mid = 12;
+
+SELECT m.title || ' ' || m.author || ' ' || m.abstract || ' ' || d.body AS document
+FROM messages m, docs d
+WHERE mid = did AND mid = 12;

+

Note: Actually, in these example queries, coalesce + should be used to prevent a single NULL attribute from + causing a NULL result for the whole document. +

Another possibility is to store the documents as simple text files in the + file system. In this case, the database can be used to store the full text + index and to execute searches, and some unique identifier can be used to + retrieve the document from the file system. However, retrieving files + from outside the database requires superuser permissions or special + function support, so this is usually less convenient than keeping all + the data inside PostgreSQL. Also, keeping + everything inside the database allows easy access + to document metadata to assist in indexing and display. +

For text search purposes, each document must be reduced to the + preprocessed tsvector format. Searching and ranking + are performed entirely on the tsvector representation + of a document — the original text need only be retrieved + when the document has been selected for display to a user. + We therefore often speak of the tsvector as being the + document, but of course it is only a compact representation of + the full document. +

12.1.2. Basic Text Matching

Full text searching in PostgreSQL is based on + the match operator @@, which returns + true if a tsvector + (document) matches a tsquery (query). + It doesn't matter which data type is written first: + +

SELECT 'a fat cat sat on a mat and ate a fat rat'::tsvector @@ 'cat & rat'::tsquery;
+ ?column?
+----------
+ t
+
+SELECT 'fat & cow'::tsquery @@ 'a fat cat sat on a mat and ate a fat rat'::tsvector;
+ ?column?
+----------
+ f

+

As the above example suggests, a tsquery is not just raw + text, any more than a tsvector is. A tsquery + contains search terms, which must be already-normalized lexemes, and + may combine multiple terms using AND, OR, and NOT operators. + (For details see Section 8.11.) There are + functions to_tsquery and plainto_tsquery + that are helpful in converting user-written text into a proper + tsquery, for example by normalizing words appearing in + the text. Similarly, to_tsvector is used to parse and + normalize a document string. So in practice a text search match would + look more like this: + +

SELECT to_tsvector('fat cats ate fat rats') @@ to_tsquery('fat & rat');
+ ?column? 
+----------
+ t

+ + Observe that this match would not succeed if written as + +

SELECT 'fat cats ate fat rats'::tsvector @@ to_tsquery('fat & rat');
+ ?column? 
+----------
+ f

+ + since here no normalization of the word rats will occur. + The elements of a tsvector are lexemes, which are assumed + already normalized, so rats does not match rat. +

The @@ operator also + supports text input, allowing explicit conversion of a text + string to tsvector or tsquery to be skipped + in simple cases. The variants available are: + +

tsvector @@ tsquery
+tsquery  @@ tsvector
+text @@ tsquery
+text @@ text

+

The first two of these we saw already. + The form text @@ tsquery + is equivalent to to_tsvector(x) @@ y. + The form text @@ text + is equivalent to to_tsvector(x) @@ plainto_tsquery(y). +

12.1.3. Configurations

The above are all simple text search examples. As mentioned before, full + text search functionality includes the ability to do many more things: + skip indexing certain words (stop words), process synonyms, and use + sophisticated parsing, e.g., parse based on more than just white space. + This functionality is controlled by text search + configurations. PostgreSQL comes with predefined + configurations for many languages, and you can easily create your own + configurations. (psql's \dF command + shows all available configurations.) +

During installation an appropriate configuration is selected and + default_text_search_config is set accordingly + in postgresql.conf. If you are using the same text search + configuration for the entire cluster you can use the value in + postgresql.conf. To use different configurations + throughout the cluster but the same configuration within any one database, + use ALTER DATABASE ... SET. Otherwise, you can set + default_text_search_config in each session. +

Each text search function that depends on a configuration has an optional + regconfig argument, so that the configuration to use can be + specified explicitly. default_text_search_config + is used only when this argument is omitted. +

To make it easier to build custom text search configurations, a + configuration is built up from simpler database objects. + PostgreSQL's text search facility provides + four types of configuration-related database objects: +

  • Text search parsers break documents into tokens + and classify each token (for example, as words or numbers). +

  • Text search dictionaries convert tokens to normalized + form and reject stop words. +

  • Text search templates provide the functions underlying + dictionaries. (A dictionary simply specifies a template and a set + of parameters for the template.) +

  • Text search configurations select a parser and a set + of dictionaries to use to normalize the tokens produced by the parser. +

Text search parsers and templates are built from low-level C functions; + therefore it requires C programming ability to develop new ones, and + superuser privileges to install one into a database. (There are examples + of add-on parsers and templates in the contrib/ area of the + PostgreSQL distribution.) Since dictionaries and + configurations just parameterize and connect together some underlying + parsers and templates, no special privilege is needed to create a new + dictionary or configuration. Examples of creating custom dictionaries and + configurations appear later in this chapter. +


PrevHomeNext
Full Text SearchUpTables and Indexes
\ No newline at end of file diff --git a/doc/src/sgml/html/textsearch-limitations.html b/doc/src/sgml/html/textsearch-limitations.html new file mode 100644 index 000000000..2ed7a7c0d --- /dev/null +++ b/doc/src/sgml/html/textsearch-limitations.html @@ -0,0 +1,244 @@ + +Limitations
PostgreSQL 9.2.2 Documentation
PrevUpChapter 12. Full Text SearchNext

12.11. Limitations

The current limitations of PostgreSQL's + text search features are: +

  • The length of each lexeme must be less than 2K bytes

  • The length of a tsvector (lexemes + positions) must be + less than 1 megabyte

  • The number of lexemes must be less than + 264

  • Position values in tsvector must be greater than 0 and + no more than 16,383

  • No more than 256 positions per lexeme

  • The number of nodes (lexemes + operators) in a tsquery + must be less than 32,768

+

For comparison, the PostgreSQL 8.1 documentation + contained 10,441 unique words, a total of 335,420 words, and the most + frequent word "postgresql" was mentioned 6,127 times in 655 + documents. +

Another example — the PostgreSQL mailing + list archives contained 910,989 unique words with 57,491,343 lexemes in + 461,020 messages. +


PrevHomeNext
psql SupportUpMigration from Pre-8.3 Text Search
\ No newline at end of file diff --git a/doc/src/sgml/html/textsearch-migration.html b/doc/src/sgml/html/textsearch-migration.html new file mode 100644 index 000000000..d461c190d --- /dev/null +++ b/doc/src/sgml/html/textsearch-migration.html @@ -0,0 +1,275 @@ + +Migration from Pre-8.3 Text Search
PostgreSQL 9.2.2 Documentation
PrevUpChapter 12. Full Text SearchNext

12.12. Migration from Pre-8.3 Text Search

Applications that use the tsearch2 + module for text searching will need some adjustments to work + with the + built-in features: +

  • Some functions have been renamed or had small adjustments in their + argument lists, and all of them are now in the pg_catalog + schema, whereas in a previous installation they would have been in + public or another non-system schema. There is a new + version of tsearch2 + that provides a compatibility layer to solve most problems in this + area. +

  • The old tsearch2 functions and other objects + must be suppressed when loading pg_dump + output from a pre-8.3 database. While many of them won't load anyway, + a few will and then cause problems. One simple way to deal with this + is to load the new tsearch2 module before restoring + the dump; then it will block the old objects from being loaded. +

  • Text search configuration setup is completely different now. + Instead of manually inserting rows into configuration tables, + search is configured through the specialized SQL commands shown + earlier in this chapter. There is no automated + support for converting an existing custom configuration for 8.3; + you're on your own here. +

  • Most types of dictionaries rely on some outside-the-database + configuration files. These are largely compatible with pre-8.3 + usage, but note the following differences: + +

    • Configuration files now must be placed in a single specified + directory ($SHAREDIR/tsearch_data), and must have + a specific extension depending on the type of file, as noted + previously in the descriptions of the various dictionary types. + This restriction was added to forestall security problems. +

    • Configuration files must be encoded in UTF-8 encoding, + regardless of what database encoding is used. +

    • In thesaurus configuration files, stop words must be marked with + ?. +

    +


PrevHomeNext
LimitationsUpConcurrency Control
\ No newline at end of file diff --git a/doc/src/sgml/html/textsearch-parsers.html b/doc/src/sgml/html/textsearch-parsers.html new file mode 100644 index 000000000..1ef220c42 --- /dev/null +++ b/doc/src/sgml/html/textsearch-parsers.html @@ -0,0 +1,619 @@ + +Parsers
PostgreSQL 9.2.2 Documentation
PrevUpChapter 12. Full Text SearchNext

12.5. Parsers

Text search parsers are responsible for splitting raw document text + into tokens and identifying each token's type, where + the set of possible types is defined by the parser itself. + Note that a parser does not modify the text at all — it simply + identifies plausible word boundaries. Because of this limited scope, + there is less need for application-specific custom parsers than there is + for custom dictionaries. At present PostgreSQL + provides just one built-in parser, which has been found to be useful for a + wide range of applications. +

The built-in parser is named pg_catalog.default. + It recognizes 23 token types, shown in Table 12-1. +

Table 12-1. Default Parser's Token Types

AliasDescriptionExample
asciiwordWord, all ASCII letterselephant
wordWord, all lettersmañana
numwordWord, letters and digitsbeta1
asciihwordHyphenated word, all ASCIIup-to-date
hwordHyphenated word, all letterslógico-matemática
numhwordHyphenated word, letters and digitspostgresql-beta1
hword_asciipartHyphenated word part, all ASCIIpostgresql in the context postgresql-beta1
hword_partHyphenated word part, all letterslógico or matemática + in the context lógico-matemática
hword_numpartHyphenated word part, letters and digitsbeta1 in the context + postgresql-beta1
emailEmail addressfoo@example.com
protocolProtocol headhttp://
urlURLexample.com/stuff/index.html
hostHostexample.com
url_pathURL path/stuff/index.html, in the context of a URL
fileFile or path name/usr/local/foo.txt, if not within a URL
sfloatScientific notation-1.234e56
floatDecimal notation-1.234
intSigned integer-1234
uintUnsigned integer1234
versionVersion number8.3.0
tagXML tag<a href="dictionaries.html">
entityXML entity&amp;
blankSpace symbols(any whitespace or punctuation not otherwise recognized)

Note: The parser's notion of a "letter" is determined by the database's + locale setting, specifically lc_ctype. Words containing + only the basic ASCII letters are reported as a separate token type, + since it is sometimes useful to distinguish them. In most European + languages, token types word and asciiword + should be treated alike. +

email does not support all valid email characters as + defined by RFC 5322. Specifically, the only non-alphanumeric + characters supported for email user names are period, dash, and + underscore. +

It is possible for the parser to produce overlapping tokens from the same + piece of text. As an example, a hyphenated word will be reported both + as the entire word and as each component: + +

SELECT alias, description, token FROM ts_debug('foo-bar-beta1');
+      alias      |               description                |     token     
+-----------------+------------------------------------------+---------------
+ numhword        | Hyphenated word, letters and digits      | foo-bar-beta1
+ hword_asciipart | Hyphenated word part, all ASCII          | foo
+ blank           | Space symbols                            | -
+ hword_asciipart | Hyphenated word part, all ASCII          | bar
+ blank           | Space symbols                            | -
+ hword_numpart   | Hyphenated word part, letters and digits | beta1

+ + This behavior is desirable since it allows searches to work for both + the whole compound word and for components. Here is another + instructive example: + +

SELECT alias, description, token FROM ts_debug('http://example.com/stuff/index.html');
+  alias   |  description  |            token             
+----------+---------------+------------------------------
+ protocol | Protocol head | http://
+ url      | URL           | example.com/stuff/index.html
+ host     | Host          | example.com
+ url_path | URL path      | /stuff/index.html

+


PrevHomeNext
Additional FeaturesUpDictionaries
\ No newline at end of file diff --git a/doc/src/sgml/html/textsearch-psql.html b/doc/src/sgml/html/textsearch-psql.html new file mode 100644 index 000000000..f5baf1939 --- /dev/null +++ b/doc/src/sgml/html/textsearch-psql.html @@ -0,0 +1,427 @@ + +psql Support
PostgreSQL 9.2.2 Documentation
PrevUpChapter 12. Full Text SearchNext

12.10. psql Support

Information about text search configuration objects can be obtained + in psql using a set of commands: +

\dF{d,p,t}[+] [PATTERN]

+ An optional + produces more details. +

The optional parameter PATTERN can be the name of + a text search object, optionally schema-qualified. If + PATTERN is omitted then information about all + visible objects will be displayed. PATTERN can be a + regular expression and can provide separate patterns + for the schema and object names. The following examples illustrate this: + +

=> \dF *fulltext*
+       List of text search configurations
+ Schema |  Name        | Description
+--------+--------------+-------------
+ public | fulltext_cfg |

+ +

=> \dF *.fulltext*
+       List of text search configurations
+ Schema   |  Name        | Description
+----------+----------------------------
+ fulltext | fulltext_cfg |
+ public   | fulltext_cfg |

+ + The available commands are: +

\dF[+] [PATTERN]

List text search configurations (add + for more detail). +

=> \dF russian
+            List of text search configurations
+   Schema   |  Name   |            Description             
+------------+---------+------------------------------------
+ pg_catalog | russian | configuration for russian language
+
+=> \dF+ russian
+Text search configuration "pg_catalog.russian"
+Parser: "pg_catalog.default"
+      Token      | Dictionaries 
+-----------------+--------------
+ asciihword      | english_stem
+ asciiword       | english_stem
+ email           | simple
+ file            | simple
+ float           | simple
+ host            | simple
+ hword           | russian_stem
+ hword_asciipart | english_stem
+ hword_numpart   | simple
+ hword_part      | russian_stem
+ int             | simple
+ numhword        | simple
+ numword         | simple
+ sfloat          | simple
+ uint            | simple
+ url             | simple
+ url_path        | simple
+ version         | simple
+ word            | russian_stem

+

\dFd[+] [PATTERN]

List text search dictionaries (add + for more detail). +

=> \dFd
+                            List of text search dictionaries
+   Schema   |      Name       |                        Description                        
+------------+-----------------+-----------------------------------------------------------
+ pg_catalog | danish_stem     | snowball stemmer for danish language
+ pg_catalog | dutch_stem      | snowball stemmer for dutch language
+ pg_catalog | english_stem    | snowball stemmer for english language
+ pg_catalog | finnish_stem    | snowball stemmer for finnish language
+ pg_catalog | french_stem     | snowball stemmer for french language
+ pg_catalog | german_stem     | snowball stemmer for german language
+ pg_catalog | hungarian_stem  | snowball stemmer for hungarian language
+ pg_catalog | italian_stem    | snowball stemmer for italian language
+ pg_catalog | norwegian_stem  | snowball stemmer for norwegian language
+ pg_catalog | portuguese_stem | snowball stemmer for portuguese language
+ pg_catalog | romanian_stem   | snowball stemmer for romanian language
+ pg_catalog | russian_stem    | snowball stemmer for russian language
+ pg_catalog | simple          | simple dictionary: just lower case and check for stopword
+ pg_catalog | spanish_stem    | snowball stemmer for spanish language
+ pg_catalog | swedish_stem    | snowball stemmer for swedish language
+ pg_catalog | turkish_stem    | snowball stemmer for turkish language

+

\dFp[+] [PATTERN]

List text search parsers (add + for more detail). +

=> \dFp
+        List of text search parsers
+   Schema   |  Name   |     Description     
+------------+---------+---------------------
+ pg_catalog | default | default word parser
+=> \dFp+
+    Text search parser "pg_catalog.default"
+     Method      |    Function    | Description 
+-----------------+----------------+-------------
+ Start parse     | prsd_start     | 
+ Get next token  | prsd_nexttoken | 
+ End parse       | prsd_end       | 
+ Get headline    | prsd_headline  | 
+ Get token types | prsd_lextype   | 
+
+        Token types for parser "pg_catalog.default"
+   Token name    |               Description                
+-----------------+------------------------------------------
+ asciihword      | Hyphenated word, all ASCII
+ asciiword       | Word, all ASCII
+ blank           | Space symbols
+ email           | Email address
+ entity          | XML entity
+ file            | File or path name
+ float           | Decimal notation
+ host            | Host
+ hword           | Hyphenated word, all letters
+ hword_asciipart | Hyphenated word part, all ASCII
+ hword_numpart   | Hyphenated word part, letters and digits
+ hword_part      | Hyphenated word part, all letters
+ int             | Signed integer
+ numhword        | Hyphenated word, letters and digits
+ numword         | Word, letters and digits
+ protocol        | Protocol head
+ sfloat          | Scientific notation
+ tag             | XML tag
+ uint            | Unsigned integer
+ url             | URL
+ url_path        | URL path
+ version         | Version number
+ word            | Word, all letters
+(23 rows)

+

\dFt[+] [PATTERN]

List text search templates (add + for more detail). +

=> \dFt
+                           List of text search templates
+   Schema   |   Name    |                        Description                        
+------------+-----------+-----------------------------------------------------------
+ pg_catalog | ispell    | ispell dictionary
+ pg_catalog | simple    | simple dictionary: just lower case and check for stopword
+ pg_catalog | snowball  | snowball stemmer
+ pg_catalog | synonym   | synonym dictionary: replace word by its synonym
+ pg_catalog | thesaurus | thesaurus dictionary: phrase by phrase substitution

+


PrevHomeNext
GiST and GIN Index TypesUpLimitations
\ No newline at end of file diff --git a/doc/src/sgml/html/textsearch-tables.html b/doc/src/sgml/html/textsearch-tables.html new file mode 100644 index 000000000..4a0c21e85 --- /dev/null +++ b/doc/src/sgml/html/textsearch-tables.html @@ -0,0 +1,469 @@ + +Tables and Indexes
PostgreSQL 9.2.2 Documentation
PrevUpChapter 12. Full Text SearchNext

12.2. Tables and Indexes

The examples in the previous section illustrated full text matching using + simple constant strings. This section shows how to search table data, + optionally using indexes. +

12.2.1. Searching a Table

It is possible to do a full text search without an index. A simple query + to print the title of each row that contains the word + friend in its body field is: + +

SELECT title
+FROM pgweb
+WHERE to_tsvector('english', body) @@ to_tsquery('english', 'friend');

+ + This will also find related words such as friends + and friendly, since all these are reduced to the same + normalized lexeme. +

The query above specifies that the english configuration + is to be used to parse and normalize the strings. Alternatively we + could omit the configuration parameters: + +

SELECT title
+FROM pgweb
+WHERE to_tsvector(body) @@ to_tsquery('friend');

+ + This query will use the configuration set by default_text_search_config. +

A more complex example is to + select the ten most recent documents that contain create and + table in the title or body: + +

SELECT title
+FROM pgweb
+WHERE to_tsvector(title || ' ' || body) @@ to_tsquery('create & table')
+ORDER BY last_mod_date DESC
+LIMIT 10;

+ + For clarity we omitted the coalesce function calls + which would be needed to find rows that contain NULL + in one of the two fields. +

Although these queries will work without an index, most applications + will find this approach too slow, except perhaps for occasional ad-hoc + searches. Practical use of text searching usually requires creating + an index. +

12.2.2. Creating Indexes

We can create a GIN index (Section 12.9) to speed up text searches: + +

CREATE INDEX pgweb_idx ON pgweb USING gin(to_tsvector('english', body));

+ + Notice that the 2-argument version of to_tsvector is + used. Only text search functions that specify a configuration name can + be used in expression indexes (Section 11.7). + This is because the index contents must be unaffected by default_text_search_config. If they were affected, the + index contents might be inconsistent because different entries could + contain tsvectors that were created with different text search + configurations, and there would be no way to guess which was which. It + would be impossible to dump and restore such an index correctly. +

Because the two-argument version of to_tsvector was + used in the index above, only a query reference that uses the 2-argument + version of to_tsvector with the same configuration + name will use that index. That is, WHERE + to_tsvector('english', body) @@ 'a & b' can use the index, + but WHERE to_tsvector(body) @@ 'a & b' cannot. + This ensures that an index will be used only with the same configuration + used to create the index entries. +

It is possible to set up more complex expression indexes wherein the + configuration name is specified by another column, e.g.: + +

CREATE INDEX pgweb_idx ON pgweb USING gin(to_tsvector(config_name, body));

+ + where config_name is a column in the pgweb + table. This allows mixed configurations in the same index while + recording which configuration was used for each index entry. This + would be useful, for example, if the document collection contained + documents in different languages. Again, + queries that are meant to use the index must be phrased to match, e.g., + WHERE to_tsvector(config_name, body) @@ 'a & b'. +

Indexes can even concatenate columns: + +

CREATE INDEX pgweb_idx ON pgweb USING gin(to_tsvector('english', title || ' ' || body));

+

Another approach is to create a separate tsvector column + to hold the output of to_tsvector. This example is a + concatenation of title and body, + using coalesce to ensure that one field will still be + indexed when the other is NULL: + +

ALTER TABLE pgweb ADD COLUMN textsearchable_index_col tsvector;
+UPDATE pgweb SET textsearchable_index_col =
+     to_tsvector('english', coalesce(title,'') || ' ' || coalesce(body,''));

+ + Then we create a GIN index to speed up the search: + +

CREATE INDEX textsearch_idx ON pgweb USING gin(textsearchable_index_col);

+ + Now we are ready to perform a fast full text search: + +

SELECT title
+FROM pgweb
+WHERE textsearchable_index_col @@ to_tsquery('create & table')
+ORDER BY last_mod_date DESC
+LIMIT 10;

+

When using a separate column to store the tsvector + representation, + it is necessary to create a trigger to keep the tsvector + column current anytime title or body changes. + Section 12.4.3 explains how to do that. +

One advantage of the separate-column approach over an expression index + is that it is not necessary to explicitly specify the text search + configuration in queries in order to make use of the index. As shown + in the example above, the query can depend on + default_text_search_config. Another advantage is that + searches will be faster, since it will not be necessary to redo the + to_tsvector calls to verify index matches. (This is more + important when using a GiST index than a GIN index; see Section 12.9.) The expression-index approach is + simpler to set up, however, and it requires less disk space since the + tsvector representation is not stored explicitly. +


PrevHomeNext
IntroductionUpControlling Text Search
\ No newline at end of file diff --git a/doc/src/sgml/html/textsearch.html b/doc/src/sgml/html/textsearch.html new file mode 100644 index 000000000..9b732d236 --- /dev/null +++ b/doc/src/sgml/html/textsearch.html @@ -0,0 +1,374 @@ + +Full Text Search

Chapter 12. Full Text Search

Table of Contents
12.1. Introduction
12.1.1. What Is a Document?
12.1.2. Basic Text Matching
12.1.3. Configurations
12.2. Tables and Indexes
12.2.1. Searching a Table
12.2.2. Creating Indexes
12.3. Controlling Text Search
12.3.1. Parsing Documents
12.3.2. Parsing Queries
12.3.3. Ranking Search Results
12.3.4. Highlighting Results
12.4. Additional Features
12.4.1. Manipulating Documents
12.4.2. Manipulating Queries
12.4.3. Triggers for Automatic Updates
12.4.4. Gathering Document Statistics
12.5. Parsers
12.6. Dictionaries
12.6.1. Stop Words
12.6.2. Simple Dictionary
12.6.3. Synonym Dictionary
12.6.4. Thesaurus Dictionary
12.6.5. Ispell Dictionary
12.6.6. Snowball Dictionary
12.7. Configuration Example
12.8. Testing and Debugging Text Search
12.8.1. Configuration Testing
12.8.2. Parser Testing
12.8.3. Dictionary Testing
12.9. GiST and GIN Index Types
12.10. psql Support
12.11. Limitations
12.12. Migration from Pre-8.3 Text Search

PrevHomeNext
Examining Index UsageUpIntroduction
\ No newline at end of file diff --git a/doc/src/sgml/html/transaction-iso.html b/doc/src/sgml/html/transaction-iso.html new file mode 100644 index 000000000..a18710cdb --- /dev/null +++ b/doc/src/sgml/html/transaction-iso.html @@ -0,0 +1,1038 @@ + +Transaction Isolation
PostgreSQL 9.2.2 Documentation
PrevUpChapter 13. Concurrency ControlNext

13.2. Transaction Isolation

The SQL standard defines four levels of + transaction isolation. The most strict is Serializable, + which is defined by the standard in a paragraph which says that any + concurrent execution of a set of Serializable transactions is guaranteed + to produce the same effect as running them one at a time in some order. + The other three levels are defined in terms of phenomena, resulting from + interaction between concurrent transactions, which must not occur at + each level. The standard notes that due to the definition of + Serializable, none of these phenomena are possible at that level. (This + is hardly surprising -- if the effect of the transactions must be + consistent with having been run one at a time, how could you see any + phenomena caused by interactions?) +

The phenomena which are prohibited at various levels are: + +

dirty read +

A transaction reads data written by a concurrent uncommitted transaction. +

nonrepeatable read +

A transaction re-reads data it has previously read and finds that data + has been modified by another transaction (that committed since the + initial read). +

phantom read +

A transaction re-executes a query returning a set of rows that satisfy a + search condition and finds that the set of rows satisfying the condition + has changed due to another recently-committed transaction. +

+

+ The four transaction isolation levels and the corresponding + behaviors are described in Table 13-1. +

Table 13-1. Standard SQL Transaction Isolation Levels

Isolation Level + Dirty Read + Nonrepeatable Read + Phantom Read +
Read uncommitted + Possible + Possible + Possible +
Read committed + Not possible + Possible + Possible +
Repeatable read + Not possible + Not possible + Possible +
Serializable + Not possible + Not possible + Not possible +

In PostgreSQL, you can request any of the + four standard transaction isolation levels. But internally, there are + only three distinct isolation levels, which correspond to the levels Read + Committed, Repeatable Read, and Serializable. When you select the level Read + Uncommitted you really get Read Committed, and phantom reads are not possible + in the PostgreSQL implementation of Repeatable + Read, so the actual + isolation level might be stricter than what you select. This is + permitted by the SQL standard: the four isolation levels only + define which phenomena must not happen, they do not define which + phenomena must happen. The reason that PostgreSQL + only provides three isolation levels is that this is the only + sensible way to map the standard isolation levels to the multiversion + concurrency control architecture. The behavior of the available + isolation levels is detailed in the following subsections. +

To set the transaction isolation level of a transaction, use the + command SET TRANSACTION. +

13.2.1. Read Committed Isolation Level

Read Committed is the default isolation + level in PostgreSQL. When a transaction + uses this isolation level, a SELECT query + (without a FOR UPDATE/SHARE clause) sees only data + committed before the query began; it never sees either uncommitted + data or changes committed during query execution by concurrent + transactions. In effect, a SELECT query sees + a snapshot of the database as of the instant the query begins to + run. However, SELECT does see the effects + of previous updates executed within its own transaction, even + though they are not yet committed. Also note that two successive + SELECT commands can see different data, even + though they are within a single transaction, if other transactions + commit changes during execution of the first SELECT. +

UPDATE, DELETE, SELECT + FOR UPDATE, and SELECT FOR SHARE commands + behave the same as SELECT + in terms of searching for target rows: they will only find target rows + that were committed as of the command start time. However, such a target + row might have already been updated (or deleted or locked) by + another concurrent transaction by the time it is found. In this case, the + would-be updater will wait for the first updating transaction to commit or + roll back (if it is still in progress). If the first updater rolls back, + then its effects are negated and the second updater can proceed with + updating the originally found row. If the first updater commits, the + second updater will ignore the row if the first updater deleted it, + otherwise it will attempt to apply its operation to the updated version of + the row. The search condition of the command (the WHERE clause) is + re-evaluated to see if the updated version of the row still matches the + search condition. If so, the second updater proceeds with its operation + using the updated version of the row. In the case of + SELECT FOR UPDATE and SELECT FOR + SHARE, this means it is the updated version of the row that is + locked and returned to the client. +

Because of the above rule, it is possible for an updating command to see an + inconsistent snapshot: it can see the effects of concurrent updating + commands on the same rows it is trying to update, but it + does not see effects of those commands on other rows in the database. + This behavior makes Read Committed mode unsuitable for commands that + involve complex search conditions; however, it is just right for simpler + cases. For example, consider updating bank balances with transactions + like: + +

BEGIN;
+UPDATE accounts SET balance = balance + 100.00 WHERE acctnum = 12345;
+UPDATE accounts SET balance = balance - 100.00 WHERE acctnum = 7534;
+COMMIT;

+ + If two such transactions concurrently try to change the balance of account + 12345, we clearly want the second transaction to start with the updated + version of the account's row. Because each command is affecting only a + predetermined row, letting it see the updated version of the row does + not create any troublesome inconsistency. +

More complex usage can produce undesirable results in Read Committed + mode. For example, consider a DELETE command + operating on data that is being both added and removed from its + restriction criteria by another command, e.g., assume + website is a two-row table with + website.hits equaling 9 and + 10: + +

BEGIN;
+UPDATE website SET hits = hits + 1;
+-- run from another session:  DELETE FROM website WHERE hits = 10;
+COMMIT;

+ + The DELETE will have no effect even though + there is a website.hits = 10 row before and + after the UPDATE. This occurs because the + pre-update row value 9 is skipped, and when the + UPDATE completes and DELETE + obtains a lock, the new row value is no longer 10 but + 11, which no longer matches the criteria. +

Because Read Committed mode starts each command with a new snapshot + that includes all transactions committed up to that instant, + subsequent commands in the same transaction will see the effects + of the committed concurrent transaction in any case. The point + at issue above is whether or not a single command + sees an absolutely consistent view of the database. +

The partial transaction isolation provided by Read Committed mode + is adequate for many applications, and this mode is fast and simple + to use; however, it is not sufficient for all cases. Applications + that do complex queries and updates might require a more rigorously + consistent view of the database than Read Committed mode provides. +

13.2.2. Repeatable Read Isolation Level

The Repeatable Read isolation level only sees + data committed before the transaction began; it never sees either + uncommitted data or changes committed during transaction execution + by concurrent transactions. (However, the query does see the + effects of previous updates executed within its own transaction, + even though they are not yet committed.) This is a stronger + guarantee than is required by the SQL standard + for this isolation level, and prevents all of the phenomena described + in Table 13-1. As mentioned above, this is + specifically allowed by the standard, which only describes the + minimum protections each isolation level must + provide. +

This level is different from Read Committed in that a query in a + repeatable read transaction sees a snapshot as of the start of the + transaction, not as of the start + of the current query within the transaction. Thus, successive + SELECT commands within a single + transaction see the same data, i.e., they do not see changes made by + other transactions that committed after their own transaction started. +

Applications using this level must be prepared to retry transactions + due to serialization failures. +

UPDATE, DELETE, SELECT + FOR UPDATE, and SELECT FOR SHARE commands + behave the same as SELECT + in terms of searching for target rows: they will only find target rows + that were committed as of the transaction start time. However, such a + target row might have already been updated (or deleted or locked) by + another concurrent transaction by the time it is found. In this case, the + repeatable read transaction will wait for the first updating transaction to commit or + roll back (if it is still in progress). If the first updater rolls back, + then its effects are negated and the repeatable read transaction can proceed + with updating the originally found row. But if the first updater commits + (and actually updated or deleted the row, not just locked it) + then the repeatable read transaction will be rolled back with the message + +

ERROR:  could not serialize access due to concurrent update

+ + because a repeatable read transaction cannot modify or lock rows changed by + other transactions after the repeatable read transaction began. +

When an application receives this error message, it should abort + the current transaction and retry the whole transaction from + the beginning. The second time through, the transaction will see the + previously-committed change as part of its initial view of the database, + so there is no logical conflict in using the new version of the row + as the starting point for the new transaction's update. +

Note that only updating transactions might need to be retried; read-only + transactions will never have serialization conflicts. +

The Repeatable Read mode provides a rigorous guarantee that each + transaction sees a completely stable view of the database. However, + this view will not necessarily always be consistent with some serial + (one at a time) execution of concurrent transactions of the same level. + For example, even a read only transaction at this level may see a + control record updated to show that a batch has been completed but + not see one of the detail records which is logically + part of the batch because it read an earlier revision of the control + record. Attempts to enforce business rules by transactions running at + this isolation level are not likely to work correctly without careful use + of explicit locks to block conflicting transactions. +

Note: Prior to PostgreSQL version 9.1, a request + for the Serializable transaction isolation level provided exactly the + same behavior described here. To retain the legacy Serializable + behavior, Repeatable Read should now be requested. +

13.2.3. Serializable Isolation Level

The Serializable isolation level provides the strictest transaction + isolation. This level emulates serial transaction execution, + as if transactions had been executed one after another, serially, + rather than concurrently. However, like the Repeatable Read level, + applications using this level must + be prepared to retry transactions due to serialization failures. + In fact, this isolation level works exactly the same as Repeatable + Read except that it monitors for conditions which could make + execution of a concurrent set of serializable transactions behave + in a manner inconsistent with all possible serial (one at a time) + executions of those transactions. This monitoring does not + introduce any blocking beyond that present in repeatable read, but + there is some overhead to the monitoring, and detection of the + conditions which could cause a + serialization anomaly will trigger a + serialization failure. +

As an example, + consider a table mytab, initially containing: +

 class | value
+-------+-------
+     1 |    10
+     1 |    20
+     2 |   100
+     2 |   200

+ Suppose that serializable transaction A computes: +

SELECT SUM(value) FROM mytab WHERE class = 1;

+ and then inserts the result (30) as the value in a + new row with class = 2. Concurrently, serializable + transaction B computes: +

SELECT SUM(value) FROM mytab WHERE class = 2;

+ and obtains the result 300, which it inserts in a new row with + class = 1. Then both transactions try to commit. + If either transaction were running at the Repeatable Read isolation level, + both would be allowed to commit; but since there is no serial order of execution + consistent with the result, using Serializable transactions will allow one + transaction to commit and will roll the other back with this message: + +

ERROR:  could not serialize access due to read/write dependencies among transactions

+ + This is because if A had + executed before B, B would have computed the sum 330, not 300, and + similarly the other order would have resulted in a different sum + computed by A. +

To guarantee true serializability PostgreSQL + uses predicate locking, which means that it keeps locks + which allow it to determine when a write would have had an impact on + the result of a previous read from a concurrent transaction, had it run + first. In PostgreSQL these locks do not + cause any blocking and therefore can not play any part in + causing a deadlock. They are used to identify and flag dependencies + among concurrent serializable transactions which in certain combinations + can lead to serialization anomalies. In contrast, a Read Committed or + Repeatable Read transaction which wants to ensure data consistency may + need to take out a lock on an entire table, which could block other + users attempting to use that table, or it may use SELECT FOR + UPDATE or SELECT FOR SHARE which not only + can block other transactions but cause disk access. +

Predicate locks in PostgreSQL, like in most + other database systems, are based on data actually accessed by a + transaction. These will show up in the + pg_locks + system view with a mode of SIReadLock. The + particular locks + acquired during execution of a query will depend on the plan used by + the query, and multiple finer-grained locks (e.g., tuple locks) may be + combined into fewer coarser-grained locks (e.g., page locks) during the + course of the transaction to prevent exhaustion of the memory used to + track the locks. A READ ONLY transaction may be able to + release its SIRead locks before completion, if it detects that no + conflicts can still occur which could lead to a serialization anomaly. + In fact, READ ONLY transactions will often be able to + establish that fact at startup and avoid taking any predicate locks. + If you explicitly request a SERIALIZABLE READ ONLY DEFERRABLE + transaction, it will block until it can establish this fact. (This is + the only case where Serializable transactions block but + Repeatable Read transactions don't.) On the other hand, SIRead locks + often need to be kept past transaction commit, until overlapping read + write transactions complete. +

Consistent use of Serializable transactions can simplify development. + The guarantee that any set of concurrent serializable transactions will + have the same effect as if they were run one at a time means that if + you can demonstrate that a single transaction, as written, will do the + right thing when run by itself, you can have confidence that it will + do the right thing in any mix of serializable transactions, even without + any information about what those other transactions might do. It is + important that an environment which uses this technique have a + generalized way of handling serialization failures (which always return + with a SQLSTATE value of '40001'), because it will be very hard to + predict exactly which transactions might contribute to the read/write + dependencies and need to be rolled back to prevent serialization + anomalies. The monitoring of read/write dependencies has a cost, as does + the restart of transactions which are terminated with a serialization + failure, but balanced against the cost and blocking involved in use of + explicit locks and SELECT FOR UPDATE or SELECT FOR + SHARE, Serializable transactions are the best performance choice + for some environments. +

For optimal performance when relying on Serializable transactions for + concurrency control, these issues should be considered: + +

  • Declare transactions as READ ONLY when possible. +

  • Control the number of active connections, using a connection pool if + needed. This is always an important performance consideration, but + it can be particularly important in a busy system using Serializable + transactions. +

  • Don't put more into a single transaction than needed for integrity + purposes. +

  • Don't leave connections dangling "idle in transaction" + longer than necessary. +

  • Eliminate explicit locks, SELECT FOR UPDATE, and + SELECT FOR SHARE where no longer needed due to the + protections automatically provided by Serializable transactions. +

  • When the system is forced to combine multiple page-level predicate + locks into a single relation-level predicate lock because the predicate + lock table is short of memory, an increase in the rate of serialization + failures may occur. You can avoid this by increasing + max_pred_locks_per_transaction. +

  • A sequential scan will always necessitate a relation-level predicate + lock. This can result in an increased rate of serialization failures. + It may be helpful to encourage the use of index scans by reducing + random_page_cost and/or increasing + cpu_tuple_cost. Be sure to weigh any decrease + in transaction rollbacks and restarts against any overall change in + query execution time. +

+

Warning

Support for the Serializable transaction isolation level has not yet + been added to Hot Standby replication targets (described in + Section 25.5). The strictest isolation level currently + supported in hot standby mode is Repeatable Read. While performing all + permanent database writes within Serializable transactions on the + master will ensure that all standbys will eventually reach a consistent + state, a Repeatable Read transaction run on the standby can sometimes + see a transient state which is inconsistent with any serial execution + of serializable transactions on the master. +


PrevHomeNext
IntroductionUpExplicit Locking
\ No newline at end of file diff --git a/doc/src/sgml/html/trigger-datachanges.html b/doc/src/sgml/html/trigger-datachanges.html new file mode 100644 index 000000000..aa9d23e32 --- /dev/null +++ b/doc/src/sgml/html/trigger-datachanges.html @@ -0,0 +1,274 @@ + +Visibility of Data Changes

36.2. Visibility of Data Changes

If you execute SQL commands in your trigger function, and these + commands access the table that the trigger is for, then + you need to be aware of the data visibility rules, because they determine + whether these SQL commands will see the data change that the trigger + is fired for. Briefly: + +

  • Statement-level triggers follow simple visibility rules: none of + the changes made by a statement are visible to statement-level + triggers that are invoked before the statement, whereas all + modifications are visible to statement-level AFTER + triggers. +

  • The data change (insertion, update, or deletion) causing the + trigger to fire is naturally not visible + to SQL commands executed in a row-level BEFORE trigger, + because it hasn't happened yet. +

  • However, SQL commands executed in a row-level BEFORE + trigger will see the effects of data + changes for rows previously processed in the same outer + command. This requires caution, since the ordering of these + change events is not in general predictable; a SQL command that + affects multiple rows can visit the rows in any order. +

  • Similarly, a row-level INSTEAD OF trigger will see the + effects of data changes made by previous firings of INSTEAD + OF triggers in the same outer command. +

  • When a row-level AFTER trigger is fired, all data + changes made + by the outer command are already complete, and are visible to + the invoked trigger function. +

+

If your trigger function is written in any of the standard procedural + languages, then the above statements apply only if the function is + declared VOLATILE. Functions that are declared + STABLE or IMMUTABLE will not see changes made by + the calling command in any case. +

Further information about data visibility rules can be found in + Section 43.4. The example in Section 36.4 contains a demonstration of these rules. +


PrevHomeNext
Overview of Trigger BehaviorUpWriting Trigger Functions in C
\ No newline at end of file diff --git a/doc/src/sgml/html/trigger-definition.html b/doc/src/sgml/html/trigger-definition.html new file mode 100644 index 000000000..36b13c3df --- /dev/null +++ b/doc/src/sgml/html/trigger-definition.html @@ -0,0 +1,704 @@ + +Overview of Trigger Behavior

36.1. Overview of Trigger Behavior

A trigger is a specification that the database should automatically + execute a particular function whenever a certain type of operation is + performed. Triggers can be attached to both tables and views. +

On tables, triggers can be defined to execute either before or after any + INSERT, UPDATE, or + DELETE operation, either once per modified row, + or once per SQL statement. + UPDATE triggers can moreover be set to fire only if + certain columns are mentioned in the SET clause of the + UPDATE statement. + Triggers can also fire for TRUNCATE statements. + If a trigger event occurs, the trigger's function is called at the + appropriate time to handle the event. +

On views, triggers can be defined to execute instead of + INSERT, UPDATE, or + DELETE operations. INSTEAD OF triggers + are fired once for each row that needs to be modified in the view. + It is the responsibility of the + trigger's function to perform the necessary modifications to the + underlying base tables and, where appropriate, return the modified + row as it will appear in the view. Triggers on views can also be defined + to execute once per SQL statement, before or after + INSERT, UPDATE, or + DELETE operations. +

The trigger function must be defined before the trigger itself can be + created. The trigger function must be declared as a + function taking no arguments and returning type trigger. + (The trigger function receives its input through a specially-passed + TriggerData structure, not in the form of ordinary function + arguments.) +

Once a suitable trigger function has been created, the trigger is + established with + CREATE TRIGGER. + The same trigger function can be used for multiple triggers. +

PostgreSQL offers both per-row + triggers and per-statement triggers. With a per-row + trigger, the trigger function + is invoked once for each row that is affected by the statement + that fired the trigger. In contrast, a per-statement trigger is + invoked only once when an appropriate statement is executed, + regardless of the number of rows affected by that statement. In + particular, a statement that affects zero rows will still result + in the execution of any applicable per-statement triggers. These + two types of triggers are sometimes called row-level + triggers and statement-level triggers, + respectively. Triggers on TRUNCATE may only be + defined at statement level. On views, triggers that fire before or + after may only be defined at statement level, while triggers that fire + instead of an INSERT, UPDATE, + or DELETE may only be defined at row level. +

Triggers are also classified according to whether they fire + before, after, or + instead of the operation. These are referred to + as BEFORE triggers, AFTER triggers, and + INSTEAD OF triggers respectively. + Statement-level BEFORE triggers naturally fire before the + statement starts to do anything, while statement-level AFTER + triggers fire at the very end of the statement. These types of + triggers may be defined on tables or views. Row-level BEFORE + triggers fire immediately before a particular row is operated on, + while row-level AFTER triggers fire at the end of the + statement (but before any statement-level AFTER triggers). + These types of triggers may only be defined on tables. Row-level + INSTEAD OF triggers may only be defined on views, and fire + immediately as each row in the view is identified as needing to be + operated on. +

Trigger functions invoked by per-statement triggers should always + return NULL. Trigger functions invoked by per-row + triggers can return a table row (a value of + type HeapTuple) to the calling executor, + if they choose. A row-level trigger fired before an operation has + the following choices: + +

  • It can return NULL to skip the operation for the + current row. This instructs the executor to not perform the + row-level operation that invoked the trigger (the insertion, + modification, or deletion of a particular table row). +

  • For row-level INSERT + and UPDATE triggers only, the returned row + becomes the row that will be inserted or will replace the row + being updated. This allows the trigger function to modify the + row being inserted or updated. +

+ + A row-level BEFORE trigger that does not intend to cause + either of these behaviors must be careful to return as its result the same + row that was passed in (that is, the NEW row + for INSERT and UPDATE + triggers, the OLD row for + DELETE triggers). +

A row-level INSTEAD OF trigger should either return + NULL to indicate that it did not modify any data from + the view's underlying base tables, or it should return the view + row that was passed in (the NEW row + for INSERT and UPDATE + operations, or the OLD row for + DELETE operations). A nonnull return value is + used to signal that the trigger performed the necessary data + modifications in the view. This will cause the count of the number + of rows affected by the command to be incremented. For + INSERT and UPDATE operations, the trigger + may modify the NEW row before returning it. This will + change the data returned by + INSERT RETURNING or UPDATE RETURNING, + and is useful when the view will not show exactly the same data + that was provided. +

The return value is ignored for row-level triggers fired after an + operation, and so they can return NULL. +

If more than one trigger is defined for the same event on the same + relation, the triggers will be fired in alphabetical order by + trigger name. In the case of BEFORE and + INSTEAD OF triggers, the possibly-modified row returned by + each trigger becomes the input to the next trigger. If any + BEFORE or INSTEAD OF trigger returns + NULL, the operation is abandoned for that row and subsequent + triggers are not fired (for that row). +

A trigger definition can also specify a Boolean WHEN + condition, which will be tested to see whether the trigger should + be fired. In row-level triggers the WHEN condition can + examine the old and/or new values of columns of the row. (Statement-level + triggers can also have WHEN conditions, although the feature + is not so useful for them.) In a BEFORE trigger, the + WHEN + condition is evaluated just before the function is or would be executed, + so using WHEN is not materially different from testing the + same condition at the beginning of the trigger function. However, in + an AFTER trigger, the WHEN condition is evaluated + just after the row update occurs, and it determines whether an event is + queued to fire the trigger at the end of statement. So when an + AFTER trigger's + WHEN condition does not return true, it is not necessary + to queue an event nor to re-fetch the row at end of statement. This + can result in significant speedups in statements that modify many + rows, if the trigger only needs to be fired for a few of the rows. + INSTEAD OF triggers do not support + WHEN conditions. +

Typically, row-level BEFORE triggers are used for checking or + modifying the data that will be inserted or updated. For example, + a BEFORE trigger might be used to insert the current time into a + timestamp column, or to check that two elements of the row are + consistent. Row-level AFTER triggers are most sensibly + used to propagate the updates to other tables, or make consistency + checks against other tables. The reason for this division of labor is + that an AFTER trigger can be certain it is seeing the final + value of the row, while a BEFORE trigger cannot; there might + be other BEFORE triggers firing after it. If you have no + specific reason to make a trigger BEFORE or + AFTER, the BEFORE case is more efficient, since + the information about + the operation doesn't have to be saved until end of statement. +

If a trigger function executes SQL commands then these + commands might fire triggers again. This is known as cascading + triggers. There is no direct limitation on the number of cascade + levels. It is possible for cascades to cause a recursive invocation + of the same trigger; for example, an INSERT + trigger might execute a command that inserts an additional row + into the same table, causing the INSERT trigger + to be fired again. It is the trigger programmer's responsibility + to avoid infinite recursion in such scenarios. +

+ When a trigger is being defined, arguments can be specified for + it. The purpose of including arguments in the + trigger definition is to allow different triggers with similar + requirements to call the same function. As an example, there + could be a generalized trigger function that takes as its + arguments two column names and puts the current user in one and + the current time stamp in the other. Properly written, this + trigger function would be independent of the specific table it is + triggering on. So the same function could be used for + INSERT events on any table with suitable + columns, to automatically track creation of records in a + transaction table for example. It could also be used to track + last-update events if defined as an UPDATE + trigger. +

Each programming language that supports triggers has its own method + for making the trigger input data available to the trigger function. + This input data includes the type of trigger event (e.g., + INSERT or UPDATE) as well as any + arguments that were listed in CREATE TRIGGER. + For a row-level trigger, the input data also includes the + NEW row for INSERT and + UPDATE triggers, and/or the OLD row + for UPDATE and DELETE triggers. + Statement-level triggers do not currently have any way to examine the + individual row(s) modified by the statement. +


PrevHomeNext
TriggersUpVisibility of Data Changes
\ No newline at end of file diff --git a/doc/src/sgml/html/trigger-example.html b/doc/src/sgml/html/trigger-example.html new file mode 100644 index 000000000..d045adbad --- /dev/null +++ b/doc/src/sgml/html/trigger-example.html @@ -0,0 +1,377 @@ + +A Complete Trigger Example

36.4. A Complete Trigger Example

Here is a very simple example of a trigger function written in C. + (Examples of triggers written in procedural languages can be found + in the documentation of the procedural languages.) +

The function trigf reports the number of rows in the + table ttest and skips the actual operation if the + command attempts to insert a null value into the column + x. (So the trigger acts as a not-null constraint but + doesn't abort the transaction.) +

First, the table definition: +

CREATE TABLE ttest (
+    x integer
+);

+

This is the source code of the trigger function: +

#include "postgres.h"
+#include "executor/spi.h"       /* this is what you need to work with SPI */
+#include "commands/trigger.h"   /* ... triggers ... */
+#include "utils/rel.h"          /* ... and relations */
+
+#ifdef PG_MODULE_MAGIC
+PG_MODULE_MAGIC;
+#endif
+
+extern Datum trigf(PG_FUNCTION_ARGS);
+
+PG_FUNCTION_INFO_V1(trigf);
+
+Datum
+trigf(PG_FUNCTION_ARGS)
+{
+    TriggerData *trigdata = (TriggerData *) fcinfo->context;
+    TupleDesc   tupdesc;
+    HeapTuple   rettuple;
+    char       *when;
+    bool        checknull = false;
+    bool        isnull;
+    int         ret, i;
+
+    /* make sure it's called as a trigger at all */
+    if (!CALLED_AS_TRIGGER(fcinfo))
+        elog(ERROR, "trigf: not called by trigger manager");
+
+    /* tuple to return to executor */
+    if (TRIGGER_FIRED_BY_UPDATE(trigdata->tg_event))
+        rettuple = trigdata->tg_newtuple;
+    else
+        rettuple = trigdata->tg_trigtuple;
+
+    /* check for null values */
+    if (!TRIGGER_FIRED_BY_DELETE(trigdata->tg_event)
+        && TRIGGER_FIRED_BEFORE(trigdata->tg_event))
+        checknull = true;
+
+    if (TRIGGER_FIRED_BEFORE(trigdata->tg_event))
+        when = "before";
+    else
+        when = "after ";
+
+    tupdesc = trigdata->tg_relation->rd_att;
+
+    /* connect to SPI manager */
+    if ((ret = SPI_connect()) < 0)
+        elog(ERROR, "trigf (fired %s): SPI_connect returned %d", when, ret);
+
+    /* get number of rows in table */
+    ret = SPI_exec("SELECT count(*) FROM ttest", 0);
+
+    if (ret < 0)
+        elog(ERROR, "trigf (fired %s): SPI_exec returned %d", when, ret);
+
+    /* count(*) returns int8, so be careful to convert */
+    i = DatumGetInt64(SPI_getbinval(SPI_tuptable->vals[0],
+                                    SPI_tuptable->tupdesc,
+                                    1,
+                                    &isnull));
+
+    elog (INFO, "trigf (fired %s): there are %d rows in ttest", when, i);
+
+    SPI_finish();
+
+    if (checknull)
+    {
+        SPI_getbinval(rettuple, tupdesc, 1, &isnull);
+        if (isnull)
+            rettuple = NULL;
+    }
+
+    return PointerGetDatum(rettuple);
+}

+

After you have compiled the source code (see Section 35.9.6), declare the function and the triggers: +

CREATE FUNCTION trigf() RETURNS trigger
+    AS 'filename'
+    LANGUAGE C;
+
+CREATE TRIGGER tbefore BEFORE INSERT OR UPDATE OR DELETE ON ttest
+    FOR EACH ROW EXECUTE PROCEDURE trigf();
+
+CREATE TRIGGER tafter AFTER INSERT OR UPDATE OR DELETE ON ttest
+    FOR EACH ROW EXECUTE PROCEDURE trigf();

+

Now you can test the operation of the trigger: +

=> INSERT INTO ttest VALUES (NULL);
+INFO:  trigf (fired before): there are 0 rows in ttest
+INSERT 0 0
+
+-- Insertion skipped and AFTER trigger is not fired
+
+=> SELECT * FROM ttest;
+ x
+---
+(0 rows)
+
+=> INSERT INTO ttest VALUES (1);
+INFO:  trigf (fired before): there are 0 rows in ttest
+INFO:  trigf (fired after ): there are 1 rows in ttest
+                                       ^^^^^^^^
+                             remember what we said about visibility.
+INSERT 167793 1
+vac=> SELECT * FROM ttest;
+ x
+---
+ 1
+(1 row)
+
+=> INSERT INTO ttest SELECT x * 2 FROM ttest;
+INFO:  trigf (fired before): there are 1 rows in ttest
+INFO:  trigf (fired after ): there are 2 rows in ttest
+                                       ^^^^^^
+                             remember what we said about visibility.
+INSERT 167794 1
+=> SELECT * FROM ttest;
+ x
+---
+ 1
+ 2
+(2 rows)
+
+=> UPDATE ttest SET x = NULL WHERE x = 2;
+INFO:  trigf (fired before): there are 2 rows in ttest
+UPDATE 0
+=> UPDATE ttest SET x = 4 WHERE x = 2;
+INFO:  trigf (fired before): there are 2 rows in ttest
+INFO:  trigf (fired after ): there are 2 rows in ttest
+UPDATE 1
+vac=> SELECT * FROM ttest;
+ x
+---
+ 1
+ 4
+(2 rows)
+
+=> DELETE FROM ttest;
+INFO:  trigf (fired before): there are 2 rows in ttest
+INFO:  trigf (fired before): there are 1 rows in ttest
+INFO:  trigf (fired after ): there are 0 rows in ttest
+INFO:  trigf (fired after ): there are 0 rows in ttest
+                                       ^^^^^^
+                             remember what we said about visibility.
+DELETE 2
+=> SELECT * FROM ttest;
+ x
+---
+(0 rows)

+ +

There are more complex examples in + src/test/regress/regress.c and + in spi. +


PrevHomeNext
Writing Trigger Functions in CUpThe Rule System
\ No newline at end of file diff --git a/doc/src/sgml/html/trigger-interface.html b/doc/src/sgml/html/trigger-interface.html new file mode 100644 index 000000000..f0709ae18 --- /dev/null +++ b/doc/src/sgml/html/trigger-interface.html @@ -0,0 +1,619 @@ + +Writing Trigger Functions in C

36.3. Writing Trigger Functions in C

This section describes the low-level details of the interface to a + trigger function. This information is only needed when writing + trigger functions in C. If you are using a higher-level language then + these details are handled for you. In most cases you should consider + using a procedural language before writing your triggers in C. The + documentation of each procedural language explains how to write a + trigger in that language. +

Trigger functions must use the "version 1" function manager + interface. +

When a function is called by the trigger manager, it is not passed + any normal arguments, but it is passed a "context" + pointer pointing to a TriggerData structure. C + functions can check whether they were called from the trigger + manager or not by executing the macro: +

CALLED_AS_TRIGGER(fcinfo)

+ which expands to: +

((fcinfo)->context != NULL && IsA((fcinfo)->context, TriggerData))

+ If this returns true, then it is safe to cast + fcinfo->context to type TriggerData + * and make use of the pointed-to + TriggerData structure. The function must + not alter the TriggerData + structure or any of the data it points to. +

struct TriggerData is defined in + commands/trigger.h: + +

typedef struct TriggerData
+{
+    NodeTag       type;
+    TriggerEvent  tg_event;
+    Relation      tg_relation;
+    HeapTuple     tg_trigtuple;
+    HeapTuple     tg_newtuple;
+    Trigger      *tg_trigger;
+    Buffer        tg_trigtuplebuf;
+    Buffer        tg_newtuplebuf;
+} TriggerData;

+ + where the members are defined as follows: + +

type

Always T_TriggerData. +

tg_event

Describes the event for which the function is called. You can use the + following macros to examine tg_event: + +

TRIGGER_FIRED_BEFORE(tg_event)

Returns true if the trigger fired before the operation. +

TRIGGER_FIRED_AFTER(tg_event)

Returns true if the trigger fired after the operation. +

TRIGGER_FIRED_INSTEAD(tg_event)

Returns true if the trigger fired instead of the operation. +

TRIGGER_FIRED_FOR_ROW(tg_event)

Returns true if the trigger fired for a row-level event. +

TRIGGER_FIRED_FOR_STATEMENT(tg_event)

Returns true if the trigger fired for a statement-level event. +

TRIGGER_FIRED_BY_INSERT(tg_event)

Returns true if the trigger was fired by an INSERT command. +

TRIGGER_FIRED_BY_UPDATE(tg_event)

Returns true if the trigger was fired by an UPDATE command. +

TRIGGER_FIRED_BY_DELETE(tg_event)

Returns true if the trigger was fired by a DELETE command. +

TRIGGER_FIRED_BY_TRUNCATE(tg_event)

Returns true if the trigger was fired by a TRUNCATE command. +

+

tg_relation

A pointer to a structure describing the relation that the trigger fired for. + Look at utils/rel.h for details about + this structure. The most interesting things are + tg_relation->rd_att (descriptor of the relation + tuples) and tg_relation->rd_rel->relname + (relation name; the type is not char* but + NameData; use + SPI_getrelname(tg_relation) to get a char* if you + need a copy of the name). +

tg_trigtuple

A pointer to the row for which the trigger was fired. This is + the row being inserted, updated, or deleted. If this trigger + was fired for an INSERT or + DELETE then this is what you should return + from the function if you don't want to replace the row with + a different one (in the case of INSERT) or + skip the operation. +

tg_newtuple

A pointer to the new version of the row, if the trigger was + fired for an UPDATE, and NULL if + it is for an INSERT or a + DELETE. This is what you have to return + from the function if the event is an UPDATE + and you don't want to replace this row by a different one or + skip the operation. +

tg_trigger

A pointer to a structure of type Trigger, + defined in utils/reltrigger.h: + +

typedef struct Trigger
+{
+    Oid         tgoid;
+    char       *tgname;
+    Oid         tgfoid;
+    int16       tgtype;
+    char        tgenabled;
+    bool        tgisinternal;
+    Oid         tgconstrrelid;
+    Oid         tgconstrindid;
+    Oid         tgconstraint;
+    bool        tgdeferrable;
+    bool        tginitdeferred;
+    int16       tgnargs;
+    int16       tgnattr;
+    int16      *tgattr;
+    char      **tgargs;
+    char       *tgqual;
+} Trigger;

+ + where tgname is the trigger's name, + tgnargs is the number of arguments in + tgargs, and tgargs is an array of + pointers to the arguments specified in the CREATE + TRIGGER statement. The other members are for internal use + only. +

tg_trigtuplebuf

The buffer containing tg_trigtuple, or InvalidBuffer if there + is no such tuple or it is not stored in a disk buffer. +

tg_newtuplebuf

The buffer containing tg_newtuple, or InvalidBuffer if there + is no such tuple or it is not stored in a disk buffer. +

+

A trigger function must return either a + HeapTuple pointer or a NULL pointer + (not an SQL null value, that is, do not set isNull true). + Be careful to return either + tg_trigtuple or tg_newtuple, + as appropriate, if you don't want to modify the row being operated on. +


PrevHomeNext
Visibility of Data ChangesUpA Complete Trigger Example
\ No newline at end of file diff --git a/doc/src/sgml/html/triggers.html b/doc/src/sgml/html/triggers.html new file mode 100644 index 000000000..7f409afcf --- /dev/null +++ b/doc/src/sgml/html/triggers.html @@ -0,0 +1,233 @@ + +Triggers

Chapter 36. Triggers

This chapter provides general information about writing trigger functions. + Trigger functions can be written in most of the available procedural + languages, including + PL/pgSQL (Chapter 39), + PL/Tcl (Chapter 40), + PL/Perl (Chapter 41), and + PL/Python (Chapter 42). + After reading this chapter, you should consult the chapter for + your favorite procedural language to find out the language-specific + details of writing a trigger in it. +

It is also possible to write a trigger function in C, although + most people find it easier to use one of the procedural languages. + It is not currently possible to write a trigger function in the + plain SQL function language. +


PrevHomeNext
Extension Building InfrastructureUpOverview of Trigger Behavior
\ No newline at end of file diff --git a/doc/src/sgml/html/tsearch2.html b/doc/src/sgml/html/tsearch2.html new file mode 100644 index 000000000..d12549b78 --- /dev/null +++ b/doc/src/sgml/html/tsearch2.html @@ -0,0 +1,514 @@ + +tsearch2
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.38. tsearch2

The tsearch2 module provides backwards-compatible + text search functionality for applications that used + tsearch2 before text searching was integrated + into core PostgreSQL in release 8.3. +

F.38.1. Portability Issues

Although the built-in text search features were based on + tsearch2 and are largely similar to it, + there are numerous small differences that will create portability + issues for existing applications: +

  • Some functions' names were changed, for example rank + to ts_rank. + The replacement tsearch2 module + provides aliases having the old names. +

  • The built-in text search data types and functions all exist within + the system schema pg_catalog. In an installation using + tsearch2, these objects would usually have been in + the public schema, though some users chose to place them + in a separate schema of their own. Explicitly schema-qualified + references to the objects will therefore fail in either case. + The replacement tsearch2 module + provides alias objects that are stored in public + (or another schema if necessary) so that such references will still work. +

  • There is no concept of a "current parser" or "current + dictionary" in the built-in text search features, only of a current + search configuration (set by the default_text_search_config + parameter). While the current parser and current dictionary were used + only by functions intended for debugging, this might still pose + a porting obstacle in some cases. + The replacement tsearch2 module emulates these + additional state variables and provides backwards-compatible functions + for setting and retrieving them. +

There are some issues that are not addressed by the replacement + tsearch2 module, and will therefore require + application code changes in any case: +

  • The old tsearch2 trigger function allowed items in its + argument list to be names of functions to be invoked on the text data + before it was converted to tsvector format. This was removed + as being a security hole, since it was not possible to guarantee that + the function invoked was the one intended. The recommended approach + if the data must be massaged before being indexed is to write a custom + trigger that does the work for itself. +

  • Text search configuration information has been moved into core + system catalogs that are noticeably different from the tables used + by tsearch2. Any applications that examined + or modified those tables will need adjustment. +

  • If an application used any custom text search configurations, + those will need to be set up in the core + catalogs using the new text search configuration SQL commands. + The replacement tsearch2 module offers a little + bit of support for this by making it possible to load an old set + of tsearch2 configuration tables into + PostgreSQL 8.3. (Without the module, + it is not possible to load the configuration data because values in the + regprocedure columns cannot be resolved to functions.) + While those configuration tables won't actually do + anything, at least their contents will be available to be consulted + while setting up an equivalent custom configuration in 8.3. +

  • The old reset_tsearch() and get_covers() + functions are not supported. +

  • The replacement tsearch2 module does not define + any alias operators, relying entirely on the built-in ones. + This would only pose an issue if an application used explicitly + schema-qualified operator names, which is very uncommon. +

F.38.2. Converting a pre-8.3 Installation

The recommended way to update a pre-8.3 installation that uses + tsearch2 is: +

  1. Make a dump from the old installation in the usual way, + but be sure not to use -c (--clean) + option of pg_dump or pg_dumpall. +

  2. In the new installation, create empty database(s) and install + the replacement tsearch2 module into each + database that will use text search. This must be done + before loading the dump data! If your old installation + had the tsearch2 objects in a schema other + than public, be sure to adjust the + CREATE EXTENSION command so that the replacement + objects are created in that same schema. +

  3. Load the dump data. There will be quite a few errors reported + due to failure to recreate the original tsearch2 + objects. These errors can be ignored, but this means you cannot + restore the dump in a single transaction (eg, you cannot use + pg_restore's -1 switch). +

  4. Examine the contents of the restored tsearch2 + configuration tables (pg_ts_cfg and so on), and + create equivalent built-in text search configurations as needed. + You may drop the old configuration tables once you've extracted + all the useful information from them. +

  5. Test your application. +

At a later time you may wish to rename application references + to the alias text search objects, so that you can eventually + uninstall the replacement tsearch2 module. +


PrevHomeNext
test_parserUpunaccent
\ No newline at end of file diff --git a/doc/src/sgml/html/tutorial-accessdb.html b/doc/src/sgml/html/tutorial-accessdb.html new file mode 100644 index 000000000..ee6c62f91 --- /dev/null +++ b/doc/src/sgml/html/tutorial-accessdb.html @@ -0,0 +1,428 @@ + +Accessing a Database

1.4. Accessing a Database

Once you have created a database, you can access it by: + +

  • Running the PostgreSQL interactive + terminal program, called psql, which allows you + to interactively enter, edit, and execute + SQL commands. +

  • Using an existing graphical frontend tool like + pgAdmin or an office suite with + ODBC or JDBC support to create and manipulate a + database. These possibilities are not covered in this + tutorial. +

  • Writing a custom application, using one of the several + available language bindings. These possibilities are discussed + further in Part IV. +

+ + You probably want to start up psql to try + the examples in this tutorial. It can be activated for the + mydb database by typing the command: +

$ psql mydb

+ If you do not supply the database name then it will default to your + user account name. You already discovered this scheme in the + previous section using createdb. +

In psql, you will be greeted with the following + message: +

psql (9.2.2)
+Type "help" for help.
+
+mydb=>

+ + The last line could also be: +

mydb=#

+ That would mean you are a database superuser, which is most likely + the case if you installed PostgreSQL + yourself. Being a superuser means that you are not subject to + access controls. For the purposes of this tutorial that is not + important. +

If you encounter problems starting psql + then go back to the previous section. The diagnostics of + createdb and psql are + similar, and if the former worked the latter should work as well. +

The last line printed out by psql is the + prompt, and it indicates that psql is listening + to you and that you can type SQL queries into a + work space maintained by psql. Try out these + commands: + +

mydb=> SELECT version();
+                               version
+ -----------------------------------------------------------------------
+ PostgreSQL 9.2.2 on i586-pc-linux-gnu, compiled by GCC 2.96, 32-bit
+(1 row)
+
+mydb=> SELECT current_date;
+    date
+------------
+ 2002-08-31
+(1 row)
+
+mydb=> SELECT 2 + 2;
+ ?column?
+----------
+        4
+(1 row)

+

The psql program has a number of internal + commands that are not SQL commands. They begin with the backslash + character, "\". + For example, + you can get help on the syntax of various + PostgreSQL SQL + commands by typing: +

mydb=> \h

+

To get out of psql, type: +

mydb=> \q

+ and psql will quit and return you to your + command shell. (For more internal commands, type + \? at the psql prompt.) The + full capabilities of psql are documented in + psql. In this tutorial we will not use these + features explicitly, but you can use them yourself when it is helpful. +


PrevHomeNext
Creating a DatabaseUpThe SQL Language
\ No newline at end of file diff --git a/doc/src/sgml/html/tutorial-advanced-intro.html b/doc/src/sgml/html/tutorial-advanced-intro.html new file mode 100644 index 000000000..da254dd1c --- /dev/null +++ b/doc/src/sgml/html/tutorial-advanced-intro.html @@ -0,0 +1,202 @@ + +Introduction
PostgreSQL 9.2.2 Documentation
PrevUpChapter 3. Advanced FeaturesNext

3.1. Introduction

In the previous chapter we have covered the basics of using + SQL to store and access your data in + PostgreSQL. We will now discuss some + more advanced features of SQL that simplify + management and prevent loss or corruption of your data. Finally, + we will look at some PostgreSQL + extensions. +

This chapter will on occasion refer to examples found in Chapter 2 to change or improve them, so it will be + useful to have read that chapter. Some examples from + this chapter can also be found in + advanced.sql in the tutorial directory. This + file also contains some sample data to load, which is not + repeated here. (Refer to Section 2.1 for + how to use the file.) +


PrevHomeNext
Advanced FeaturesUpViews
\ No newline at end of file diff --git a/doc/src/sgml/html/tutorial-advanced.html b/doc/src/sgml/html/tutorial-advanced.html new file mode 100644 index 000000000..53306c4a2 --- /dev/null +++ b/doc/src/sgml/html/tutorial-advanced.html @@ -0,0 +1,206 @@ + +Advanced Features

Chapter 3. Advanced Features

Table of Contents
3.1. Introduction
3.2. Views
3.3. Foreign Keys
3.4. Transactions
3.5. Window Functions
3.6. Inheritance
3.7. Conclusion

PrevHomeNext
DeletionsUpIntroduction
\ No newline at end of file diff --git a/doc/src/sgml/html/tutorial-agg.html b/doc/src/sgml/html/tutorial-agg.html new file mode 100644 index 000000000..74dcb98d3 --- /dev/null +++ b/doc/src/sgml/html/tutorial-agg.html @@ -0,0 +1,438 @@ + +Aggregate Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 2. The SQL LanguageNext

2.7. Aggregate Functions

Like most other relational database products, + PostgreSQL supports + aggregate functions. + An aggregate function computes a single result from multiple input rows. + For example, there are aggregates to compute the + count, sum, + avg (average), max (maximum) and + min (minimum) over a set of rows. +

As an example, we can find the highest low-temperature reading anywhere + with: + +

SELECT max(temp_lo) FROM weather;

+ +

 max
+-----
+  46
+(1 row)

+

+ + If we wanted to know what city (or cities) that reading occurred in, + we might try: + +

SELECT city FROM weather WHERE temp_lo = max(temp_lo);     WRONG

+ + but this will not work since the aggregate + max cannot be used in the + WHERE clause. (This restriction exists because + the WHERE clause determines which rows will be + included in the aggregate calculation; so obviously it has to be evaluated + before aggregate functions are computed.) + However, as is often the case + the query can be restated to accomplish the desired result, here + by using a subquery: + +

SELECT city FROM weather
+    WHERE temp_lo = (SELECT max(temp_lo) FROM weather);

+ +

     city
+---------------
+ San Francisco
+(1 row)

+ + This is OK because the subquery is an independent computation + that computes its own aggregate separately from what is happening + in the outer query. +

+ + + Aggregates are also very useful in combination with GROUP + BY clauses. For example, we can get the maximum low + temperature observed in each city with: + +

SELECT city, max(temp_lo)
+    FROM weather
+    GROUP BY city;

+ +

     city      | max
+---------------+-----
+ Hayward       |  37
+ San Francisco |  46
+(2 rows)

+ + which gives us one output row per city. Each aggregate result is + computed over the table rows matching that city. + We can filter these grouped + rows using HAVING: + +

SELECT city, max(temp_lo)
+    FROM weather
+    GROUP BY city
+    HAVING max(temp_lo) < 40;

+ +

  city   | max
+---------+-----
+ Hayward |  37
+(1 row)

+ + which gives us the same results for only the cities that have all + temp_lo values below 40. Finally, if we only care about + cities whose + names begin with "S", we might do: + +

SELECT city, max(temp_lo)
+    FROM weather
+    WHERE city LIKE 'S%'(1)
+    GROUP BY city
+    HAVING max(temp_lo) < 40;

+

(1)
The LIKE operator does pattern matching and + is explained in Section 9.7. +
+

It is important to understand the interaction between aggregates and + SQL's WHERE and HAVING clauses. + The fundamental difference between WHERE and + HAVING is this: WHERE selects + input rows before groups and aggregates are computed (thus, it controls + which rows go into the aggregate computation), whereas + HAVING selects group rows after groups and + aggregates are computed. Thus, the + WHERE clause must not contain aggregate functions; + it makes no sense to try to use an aggregate to determine which rows + will be inputs to the aggregates. On the other hand, the + HAVING clause always contains aggregate functions. + (Strictly speaking, you are allowed to write a HAVING + clause that doesn't use aggregates, but it's seldom useful. The same + condition could be used more efficiently at the WHERE + stage.) +

In the previous example, we can apply the city name restriction in + WHERE, since it needs no aggregate. This is + more efficient than adding the restriction to HAVING, + because we avoid doing the grouping and aggregate calculations + for all rows that fail the WHERE check. +


PrevHomeNext
Joins Between TablesUpUpdates
\ No newline at end of file diff --git a/doc/src/sgml/html/tutorial-arch.html b/doc/src/sgml/html/tutorial-arch.html new file mode 100644 index 000000000..c00cfad8a --- /dev/null +++ b/doc/src/sgml/html/tutorial-arch.html @@ -0,0 +1,251 @@ + +Architectural Fundamentals

1.2. Architectural Fundamentals

Before we proceed, you should understand the basic + PostgreSQL system architecture. + Understanding how the parts of + PostgreSQL interact will make this + chapter somewhat clearer. +

In database jargon, PostgreSQL uses a + client/server model. A PostgreSQL + session consists of the following cooperating processes + (programs): + +

  • A server process, which manages the database files, accepts + connections to the database from client applications, and + performs database actions on behalf of the clients. The + database server program is called + postgres. + +

  • The user's client (frontend) application that wants to perform + database operations. Client applications can be very diverse + in nature: a client could be a text-oriented tool, a graphical + application, a web server that accesses the database to + display web pages, or a specialized database maintenance tool. + Some client applications are supplied with the + PostgreSQL distribution; most are + developed by users. +

+

As is typical of client/server applications, the client and the + server can be on different hosts. In that case they communicate + over a TCP/IP network connection. You should keep this in mind, + because the files that can be accessed on a client machine might + not be accessible (or might only be accessible using a different + file name) on the database server machine. +

The PostgreSQL server can handle + multiple concurrent connections from clients. To achieve this it + starts ("forks") a new process for each connection. + From that point on, the client and the new server process + communicate without intervention by the original + postgres process. Thus, the + master server process is always running, waiting for + client connections, whereas client and associated server processes + come and go. (All of this is of course invisible to the user. We + only mention it here for completeness.) +


PrevHomeNext
InstallationUpCreating a Database
\ No newline at end of file diff --git a/doc/src/sgml/html/tutorial-concepts.html b/doc/src/sgml/html/tutorial-concepts.html new file mode 100644 index 000000000..8ef0b84c5 --- /dev/null +++ b/doc/src/sgml/html/tutorial-concepts.html @@ -0,0 +1,231 @@ + +Concepts
PostgreSQL 9.2.2 Documentation
PrevUpChapter 2. The SQL LanguageNext

2.2. Concepts

+ + + + + + PostgreSQL is a relational + database management system (RDBMS). + That means it is a system for managing data stored in + relations. Relation is essentially a + mathematical term for table. The notion of + storing data in tables is so commonplace today that it might + seem inherently obvious, but there are a number of other ways of + organizing databases. Files and directories on Unix-like + operating systems form an example of a hierarchical database. A + more modern development is the object-oriented database. +

+ + + Each table is a named collection of rows. + Each row of a given table has the same set of named + columns, + and each column is of a specific data type. Whereas columns have + a fixed order in each row, it is important to remember that SQL + does not guarantee the order of the rows within the table in any + way (although they can be explicitly sorted for display). +

+ + + Tables are grouped into databases, and a collection of databases + managed by a single PostgreSQL server + instance constitutes a database cluster. +


PrevHomeNext
IntroductionUpCreating a New Table
\ No newline at end of file diff --git a/doc/src/sgml/html/tutorial-conclusion.html b/doc/src/sgml/html/tutorial-conclusion.html new file mode 100644 index 000000000..1537a6cc9 --- /dev/null +++ b/doc/src/sgml/html/tutorial-conclusion.html @@ -0,0 +1,185 @@ + +Conclusion
PostgreSQL 9.2.2 Documentation
PrevUpChapter 3. Advanced FeaturesNext

3.7. Conclusion

PostgreSQL has many features not + touched upon in this tutorial introduction, which has been + oriented toward newer users of SQL. These + features are discussed in more detail in the remainder of this + book. +

If you feel you need more introductory material, please visit the PostgreSQL + web site + for links to more resources. +


PrevHomeNext
InheritanceUpThe SQL Language
\ No newline at end of file diff --git a/doc/src/sgml/html/tutorial-createdb.html b/doc/src/sgml/html/tutorial-createdb.html new file mode 100644 index 000000000..1814e25ee --- /dev/null +++ b/doc/src/sgml/html/tutorial-createdb.html @@ -0,0 +1,442 @@ + +Creating a Database

1.3. Creating a Database

The first test to see whether you can access the database server + is to try to create a database. A running + PostgreSQL server can manage many + databases. Typically, a separate database is used for each + project or for each user. +

Possibly, your site administrator has already created a database + for your use. He should have told you what the name of your + database is. In that case you can omit this step and skip ahead + to the next section. +

To create a new database, in this example named + mydb, you use the following command: +

$ createdb mydb

+ If this produces no response then this step was successful and you can skip over the + remainder of this section. +

If you see a message similar to: +

createdb: command not found

+ then PostgreSQL was not installed properly. Either it was not + installed at all or your shell's search path was not set to include it. + Try calling the command with an absolute path instead: +

$ /usr/local/pgsql/bin/createdb mydb

+ The path at your site might be different. Contact your site + administrator or check the installation instructions to + correct the situation. +

Another response could be this: +

createdb: could not connect to database postgres: could not connect to server: No such file or directory
+        Is the server running locally and accepting
+        connections on Unix domain socket "/tmp/.s.PGSQL.5432"?

+ This means that the server was not started, or it was not started + where createdb expected it. Again, check the + installation instructions or consult the administrator. +

Another response could be this: +

createdb: could not connect to database postgres: FATAL:  role "joe" does not exist

+ where your own login name is mentioned. This will happen if the + administrator has not created a PostgreSQL user account + for you. (PostgreSQL user accounts are distinct from + operating system user accounts.) If you are the administrator, see + Chapter 20 for help creating accounts. You will need to + become the operating system user under which PostgreSQL + was installed (usually postgres) to create the first user + account. It could also be that you were assigned a + PostgreSQL user name that is different from your + operating system user name; in that case you need to use the -U + switch or set the PGUSER environment variable to specify your + PostgreSQL user name. +

If you have a user account but it does not have the privileges required to + create a database, you will see the following: +

createdb: database creation failed: ERROR:  permission denied to create database

+ Not every user has authorization to create new databases. If + PostgreSQL refuses to create databases + for you then the site administrator needs to grant you permission + to create databases. Consult your site administrator if this + occurs. If you installed PostgreSQL + yourself then you should log in for the purposes of this tutorial + under the user account that you started the server as. + + [1] +

You can also create databases with other names. + PostgreSQL allows you to create any + number of databases at a given site. Database names must have an + alphabetic first character and are limited to 63 bytes in + length. A convenient choice is to create a database with the same + name as your current user name. Many tools assume that database + name as the default, so it can save you some typing. To create + that database, simply type: +

$ createdb

+

If you do not want to use your database anymore you can remove it. + For example, if you are the owner (creator) of the database + mydb, you can destroy it using the following + command: +

$ dropdb mydb

+ (For this command, the database name does not default to the user + account name. You always need to specify it.) This action + physically removes all files associated with the database and + cannot be undone, so this should only be done with a great deal of + forethought. +

More about createdb and dropdb can + be found in createdb and dropdb + respectively. +

Notes

[1]

As an explanation for why this works: + PostgreSQL user names are separate + from operating system user accounts. When you connect to a + database, you can choose what + PostgreSQL user name to connect as; + if you don't, it will default to the same name as your current + operating system account. As it happens, there will always be a + PostgreSQL user account that has the + same name as the operating system user that started the server, + and it also happens that that user always has permission to + create databases. Instead of logging in as that user you can + also specify the -U option everywhere to select + a PostgreSQL user name to connect as. +


PrevHomeNext
Architectural FundamentalsUpAccessing a Database
\ No newline at end of file diff --git a/doc/src/sgml/html/tutorial-delete.html b/doc/src/sgml/html/tutorial-delete.html new file mode 100644 index 000000000..633d7a0f0 --- /dev/null +++ b/doc/src/sgml/html/tutorial-delete.html @@ -0,0 +1,221 @@ + +Deletions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 2. The SQL LanguageNext

2.9. Deletions

Rows can be removed from a table using the DELETE + command. + Suppose you are no longer interested in the weather of Hayward. + Then you can do the following to delete those rows from the table: +

DELETE FROM weather WHERE city = 'Hayward';

+ + All weather records belonging to Hayward are removed. + +

SELECT * FROM weather;

+ +

     city      | temp_lo | temp_hi | prcp |    date
+---------------+---------+---------+------+------------
+ San Francisco |      46 |      50 | 0.25 | 1994-11-27
+ San Francisco |      41 |      55 |    0 | 1994-11-29
+(2 rows)

+

One should be wary of statements of the form +

DELETE FROM tablename;

+ + Without a qualification, DELETE will + remove all rows from the given table, leaving it + empty. The system will not request confirmation before + doing this! +


PrevHomeNext
UpdatesUpAdvanced Features
\ No newline at end of file diff --git a/doc/src/sgml/html/tutorial-fk.html b/doc/src/sgml/html/tutorial-fk.html new file mode 100644 index 000000000..767583d24 --- /dev/null +++ b/doc/src/sgml/html/tutorial-fk.html @@ -0,0 +1,248 @@ + +Foreign Keys
PostgreSQL 9.2.2 Documentation
PrevUpChapter 3. Advanced FeaturesNext

3.3. Foreign Keys

Recall the weather and + cities tables from Chapter 2. Consider the following problem: You + want to make sure that no one can insert rows in the + weather table that do not have a matching + entry in the cities table. This is called + maintaining the referential integrity of + your data. In simplistic database systems this would be + implemented (if at all) by first looking at the + cities table to check if a matching record + exists, and then inserting or rejecting the new + weather records. This approach has a + number of problems and is very inconvenient, so + PostgreSQL can do this for you. +

The new declaration of the tables would look like this: + +

CREATE TABLE cities (
+        city     varchar(80) primary key,
+        location point
+);
+
+CREATE TABLE weather (
+        city      varchar(80) references cities(city),
+        temp_lo   int,
+        temp_hi   int,
+        prcp      real,
+        date      date
+);

+ + Now try inserting an invalid record: + +

INSERT INTO weather VALUES ('Berkeley', 45, 53, 0.0, '1994-11-28');

+ +

ERROR:  insert or update on table "weather" violates foreign key constraint "weather_city_fkey"
+DETAIL:  Key (city)=(Berkeley) is not present in table "cities".

+

The behavior of foreign keys can be finely tuned to your + application. We will not go beyond this simple example in this + tutorial, but just refer you to Chapter 5 + for more information. Making correct use of + foreign keys will definitely improve the quality of your database + applications, so you are strongly encouraged to learn about them. +


PrevHomeNext
ViewsUpTransactions
\ No newline at end of file diff --git a/doc/src/sgml/html/tutorial-inheritance.html b/doc/src/sgml/html/tutorial-inheritance.html new file mode 100644 index 000000000..6fac53576 --- /dev/null +++ b/doc/src/sgml/html/tutorial-inheritance.html @@ -0,0 +1,363 @@ + +Inheritance
PostgreSQL 9.2.2 Documentation
PrevUpChapter 3. Advanced FeaturesNext

3.6. Inheritance

Inheritance is a concept from object-oriented databases. It opens + up interesting new possibilities of database design. +

Let's create two tables: A table cities + and a table capitals. Naturally, capitals + are also cities, so you want some way to show the capitals + implicitly when you list all cities. If you're really clever you + might invent some scheme like this: + +

CREATE TABLE capitals (
+  name       text,
+  population real,
+  altitude   int,    -- (in ft)
+  state      char(2)
+);
+
+CREATE TABLE non_capitals (
+  name       text,
+  population real,
+  altitude   int     -- (in ft)
+);
+
+CREATE VIEW cities AS
+  SELECT name, population, altitude FROM capitals
+    UNION
+  SELECT name, population, altitude FROM non_capitals;

+ + This works OK as far as querying goes, but it gets ugly when you + need to update several rows, for one thing. +

A better solution is this: + +

CREATE TABLE cities (
+  name       text,
+  population real,
+  altitude   int     -- (in ft)
+);
+
+CREATE TABLE capitals (
+  state      char(2)
+) INHERITS (cities);

+

In this case, a row of capitals + inherits all columns (name, + population, and altitude) from its + parent, cities. The + type of the column name is + text, a native PostgreSQL + type for variable length character strings. State capitals have + an extra column, state, that shows their state. In + PostgreSQL, a table can inherit from + zero or more other tables. +

For example, the following query finds the names of all cities, + including state capitals, that are located at an altitude + over 500 feet: + +

SELECT name, altitude
+  FROM cities
+  WHERE altitude > 500;

+ + which returns: + +

   name    | altitude
+-----------+----------
+ Las Vegas |     2174
+ Mariposa  |     1953
+ Madison   |      845
+(3 rows)

+

On the other hand, the following query finds + all the cities that are not state capitals and + are situated at an altitude of 500 feet or higher: + +

SELECT name, altitude
+    FROM ONLY cities
+    WHERE altitude > 500;

+ +

   name    | altitude
+-----------+----------
+ Las Vegas |     2174
+ Mariposa  |     1953
+(2 rows)

+

Here the ONLY before cities + indicates that the query should be run over only the + cities table, and not tables below + cities in the inheritance hierarchy. Many + of the commands that we have already discussed — + SELECT, UPDATE, and + DELETE — support this ONLY + notation. +

Note: Although inheritance is frequently useful, it has not been integrated + with unique constraints or foreign keys, which limits its usefulness. + See Section 5.8 for more detail. +


PrevHomeNext
Window FunctionsUpConclusion
\ No newline at end of file diff --git a/doc/src/sgml/html/tutorial-install.html b/doc/src/sgml/html/tutorial-install.html new file mode 100644 index 000000000..14bb4ac42 --- /dev/null +++ b/doc/src/sgml/html/tutorial-install.html @@ -0,0 +1,233 @@ + +Installation

1.1. Installation

Before you can use PostgreSQL you need + to install it, of course. It is possible that + PostgreSQL is already installed at your + site, either because it was included in your operating system + distribution or because the system administrator already installed + it. If that is the case, you should obtain information from the + operating system documentation or your system administrator about + how to access PostgreSQL. +

If you are not sure whether PostgreSQL + is already available or whether you can use it for your + experimentation then you can install it yourself. Doing so is not + hard and it can be a good exercise. + PostgreSQL can be installed by any + unprivileged user; no superuser (root) + access is required. +

If you are installing PostgreSQL + yourself, then refer to Chapter 15 + for instructions on installation, and return to + this guide when the installation is complete. Be sure to follow + closely the section about setting up the appropriate environment + variables. +

If your site administrator has not set things up in the default + way, you might have some more work to do. For example, if the + database server machine is a remote machine, you will need to set + the PGHOST environment variable to the name of the + database server machine. The environment variable + PGPORT might also have to be set. The bottom line is + this: if you try to start an application program and it complains + that it cannot connect to the database, you should consult your + site administrator or, if that is you, the documentation to make + sure that your environment is properly set up. If you did not + understand the preceding paragraph then read the next section. +


PrevHomeNext
Getting StartedUpArchitectural Fundamentals
\ No newline at end of file diff --git a/doc/src/sgml/html/tutorial-join.html b/doc/src/sgml/html/tutorial-join.html new file mode 100644 index 000000000..b24544868 --- /dev/null +++ b/doc/src/sgml/html/tutorial-join.html @@ -0,0 +1,452 @@ + +Joins Between Tables
PostgreSQL 9.2.2 Documentation
PrevUpChapter 2. The SQL LanguageNext

2.6. Joins Between Tables

Thus far, our queries have only accessed one table at a time. + Queries can access multiple tables at once, or access the same + table in such a way that multiple rows of the table are being + processed at the same time. A query that accesses multiple rows + of the same or different tables at one time is called a + join query. As an example, say you wish to + list all the weather records together with the location of the + associated city. To do that, we need to compare the city + column of each row of the weather table with the + name column of all rows in the cities + table, and select the pairs of rows where these values match. +

Note: This is only a conceptual model. The join is usually performed + in a more efficient manner than actually comparing each possible + pair of rows, but this is invisible to the user. +

+ This would be accomplished by the following query: + +

SELECT *
+    FROM weather, cities
+    WHERE city = name;

+ +

     city      | temp_lo | temp_hi | prcp |    date    |     name      | location
+---------------+---------+---------+------+------------+---------------+-----------
+ San Francisco |      46 |      50 | 0.25 | 1994-11-27 | San Francisco | (-194,53)
+ San Francisco |      43 |      57 |    0 | 1994-11-29 | San Francisco | (-194,53)
+(2 rows)

+ +

Observe two things about the result set: +

  • There is no result row for the city of Hayward. This is + because there is no matching entry in the + cities table for Hayward, so the join + ignores the unmatched rows in the weather table. We will see + shortly how this can be fixed. +

  • There are two columns containing the city name. This is + correct because the lists of columns from the + weather and + cities tables are concatenated. In + practice this is undesirable, though, so you will probably want + to list the output columns explicitly rather than using + *: +

    SELECT city, temp_lo, temp_hi, prcp, date, location
    +    FROM weather, cities
    +    WHERE city = name;

    +

+

Exercise: Attempt to determine the semantics of this query when the + WHERE clause is omitted. +

Since the columns all had different names, the parser + automatically found which table they belong to. If there + were duplicate column names in the two tables you'd need to + qualify the column names to show which one you + meant, as in: + +

SELECT weather.city, weather.temp_lo, weather.temp_hi,
+       weather.prcp, weather.date, cities.location
+    FROM weather, cities
+    WHERE cities.name = weather.city;

+ + It is widely considered good style to qualify all column names + in a join query, so that the query won't fail if a duplicate + column name is later added to one of the tables. +

Join queries of the kind seen thus far can also be written in this + alternative form: + +

SELECT *
+    FROM weather INNER JOIN cities ON (weather.city = cities.name);

+ + This syntax is not as commonly used as the one above, but we show + it here to help you understand the following topics. +

+ + Now we will figure out how we can get the Hayward records back in. + What we want the query to do is to scan the + weather table and for each row to find the + matching cities row(s). If no matching row is + found we want some "empty values" to be substituted + for the cities table's columns. This kind + of query is called an outer join. (The + joins we have seen so far are inner joins.) The command looks + like this: + +

SELECT *
+    FROM weather LEFT OUTER JOIN cities ON (weather.city = cities.name);
+
+     city      | temp_lo | temp_hi | prcp |    date    |     name      | location
+---------------+---------+---------+------+------------+---------------+-----------
+ Hayward       |      37 |      54 |      | 1994-11-29 |               |
+ San Francisco |      46 |      50 | 0.25 | 1994-11-27 | San Francisco | (-194,53)
+ San Francisco |      43 |      57 |    0 | 1994-11-29 | San Francisco | (-194,53)
+(3 rows)

+ + This query is called a left outer + join because the table mentioned on the left of the + join operator will have each of its rows in the output at least + once, whereas the table on the right will only have those rows + output that match some row of the left table. When outputting a + left-table row for which there is no right-table match, empty (null) + values are substituted for the right-table columns. +

Exercise: There are also right outer joins and full outer joins. Try to + find out what those do. +

+ + + We can also join a table against itself. This is called a + self join. As an example, suppose we wish + to find all the weather records that are in the temperature range + of other weather records. So we need to compare the + temp_lo and temp_hi columns of + each weather row to the + temp_lo and + temp_hi columns of all other + weather rows. We can do this with the + following query: + +

SELECT W1.city, W1.temp_lo AS low, W1.temp_hi AS high,
+    W2.city, W2.temp_lo AS low, W2.temp_hi AS high
+    FROM weather W1, weather W2
+    WHERE W1.temp_lo < W2.temp_lo
+    AND W1.temp_hi > W2.temp_hi;
+
+     city      | low | high |     city      | low | high
+---------------+-----+------+---------------+-----+------
+ San Francisco |  43 |   57 | San Francisco |  46 |   50
+ Hayward       |  37 |   54 | San Francisco |  46 |   50
+(2 rows)

+ + Here we have relabeled the weather table as W1 and + W2 to be able to distinguish the left and right side + of the join. You can also use these kinds of aliases in other + queries to save some typing, e.g.: +

SELECT *
+    FROM weather w, cities c
+    WHERE w.city = c.name;

+ You will encounter this style of abbreviating quite frequently. +


PrevHomeNext
Querying a TableUpAggregate Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/tutorial-populate.html b/doc/src/sgml/html/tutorial-populate.html new file mode 100644 index 000000000..bc18fbb36 --- /dev/null +++ b/doc/src/sgml/html/tutorial-populate.html @@ -0,0 +1,260 @@ + +Populating a Table With Rows
PostgreSQL 9.2.2 Documentation
PrevUpChapter 2. The SQL LanguageNext

2.4. Populating a Table With Rows

The INSERT statement is used to populate a table with + rows: + +

INSERT INTO weather VALUES ('San Francisco', 46, 50, 0.25, '1994-11-27');

+ + Note that all data types use rather obvious input formats. + Constants that are not simple numeric values usually must be + surrounded by single quotes ('), as in the example. + The + date type is actually quite flexible in what it + accepts, but for this tutorial we will stick to the unambiguous + format shown here. +

The point type requires a coordinate pair as input, + as shown here: +

INSERT INTO cities VALUES ('San Francisco', '(-194.0, 53.0)');

+

The syntax used so far requires you to remember the order of the + columns. An alternative syntax allows you to list the columns + explicitly: +

INSERT INTO weather (city, temp_lo, temp_hi, prcp, date)
+    VALUES ('San Francisco', 43, 57, 0.0, '1994-11-29');

+ You can list the columns in a different order if you wish or + even omit some columns, e.g., if the precipitation is unknown: +

INSERT INTO weather (date, city, temp_hi, temp_lo)
+    VALUES ('1994-11-29', 'Hayward', 54, 37);

+ Many developers consider explicitly listing the columns better + style than relying on the order implicitly. +

Please enter all the commands shown above so you have some data to + work with in the following sections. +

+ + You could also have used COPY to load large + amounts of data from flat-text files. This is usually faster + because the COPY command is optimized for this + application while allowing less flexibility than + INSERT. An example would be: + +

COPY weather FROM '/home/user/weather.txt';

+ + where the file name for the source file must be available on the + machine running the backend process, not the client, since the backend process + reads the file directly. You can read more about the + COPY command in COPY. +


PrevHomeNext
Creating a New TableUpQuerying a Table
\ No newline at end of file diff --git a/doc/src/sgml/html/tutorial-select.html b/doc/src/sgml/html/tutorial-select.html new file mode 100644 index 000000000..c7c24a77c --- /dev/null +++ b/doc/src/sgml/html/tutorial-select.html @@ -0,0 +1,452 @@ + +Querying a Table
PostgreSQL 9.2.2 Documentation
PrevUpChapter 2. The SQL LanguageNext

2.5. Querying a Table

+ + + To retrieve data from a table, the table is + queried. An SQL + SELECT statement is used to do this. The + statement is divided into a select list (the part that lists the + columns to be returned), a table list (the part that lists the + tables from which to retrieve the data), and an optional + qualification (the part that specifies any restrictions). For + example, to retrieve all the rows of table + weather, type: +

SELECT * FROM weather;

+ Here * is a shorthand for "all columns". + [1] + So the same result would be had with: +

SELECT city, temp_lo, temp_hi, prcp, date FROM weather;

+ + The output should be: + +

     city      | temp_lo | temp_hi | prcp |    date
+---------------+---------+---------+------+------------
+ San Francisco |      46 |      50 | 0.25 | 1994-11-27
+ San Francisco |      43 |      57 |    0 | 1994-11-29
+ Hayward       |      37 |      54 |      | 1994-11-29
+(3 rows)

+

You can write expressions, not just simple column references, in the + select list. For example, you can do: +

SELECT city, (temp_hi+temp_lo)/2 AS temp_avg, date FROM weather;

+ This should give: +

     city      | temp_avg |    date
+---------------+----------+------------
+ San Francisco |       48 | 1994-11-27
+ San Francisco |       50 | 1994-11-29
+ Hayward       |       45 | 1994-11-29
+(3 rows)

+ Notice how the AS clause is used to relabel the + output column. (The AS clause is optional.) +

A query can be "qualified" by adding a WHERE + clause that specifies which rows are wanted. The WHERE + clause contains a Boolean (truth value) expression, and only rows for + which the Boolean expression is true are returned. The usual + Boolean operators (AND, + OR, and NOT) are allowed in + the qualification. For example, the following + retrieves the weather of San Francisco on rainy days: + +

SELECT * FROM weather
+    WHERE city = 'San Francisco' AND prcp > 0.0;

+ Result: +

     city      | temp_lo | temp_hi | prcp |    date
+---------------+---------+---------+------+------------
+ San Francisco |      46 |      50 | 0.25 | 1994-11-27
+(1 row)

+

+ + You can request that the results of a query + be returned in sorted order: + +

SELECT * FROM weather
+    ORDER BY city;

+ +

     city      | temp_lo | temp_hi | prcp |    date
+---------------+---------+---------+------+------------
+ Hayward       |      37 |      54 |      | 1994-11-29
+ San Francisco |      43 |      57 |    0 | 1994-11-29
+ San Francisco |      46 |      50 | 0.25 | 1994-11-27

+ + In this example, the sort order isn't fully specified, and so you + might get the San Francisco rows in either order. But you'd always + get the results shown above if you do: + +

SELECT * FROM weather
+    ORDER BY city, temp_lo;

+

+ + + You can request that duplicate rows be removed from the result of + a query: + +

SELECT DISTINCT city
+    FROM weather;

+ +

     city
+---------------
+ Hayward
+ San Francisco
+(2 rows)

+ + Here again, the result row ordering might vary. + You can ensure consistent results by using DISTINCT and + ORDER BY together: + [2] + +

SELECT DISTINCT city
+    FROM weather
+    ORDER BY city;

+

Notes

[1]

While SELECT * is useful for off-the-cuff + queries, it is widely considered bad style in production code, + since adding a column to the table would change the results. +

[2]

In some database systems, including older versions of + PostgreSQL, the implementation of + DISTINCT automatically orders the rows and + so ORDER BY is unnecessary. But this is not + required by the SQL standard, and current + PostgreSQL does not guarantee that + DISTINCT causes the rows to be ordered. +


PrevHomeNext
Populating a Table With RowsUpJoins Between Tables
\ No newline at end of file diff --git a/doc/src/sgml/html/tutorial-sql-intro.html b/doc/src/sgml/html/tutorial-sql-intro.html new file mode 100644 index 000000000..2fb5149a3 --- /dev/null +++ b/doc/src/sgml/html/tutorial-sql-intro.html @@ -0,0 +1,316 @@ + +Introduction
PostgreSQL 9.2.2 Documentation
PrevUpChapter 2. The SQL LanguageNext

2.1. Introduction

This chapter provides an overview of how to use + SQL to perform simple operations. This + tutorial is only intended to give you an introduction and is in no + way a complete tutorial on SQL. Numerous books + have been written on SQL, including Understanding the New SQL and A Guide to the SQL Standard. + You should be aware that some PostgreSQL + language features are extensions to the standard. +

In the examples that follow, we assume that you have created a + database named mydb, as described in the previous + chapter, and have been able to start psql. +

Examples in this manual can also be found in the + PostgreSQL source distribution + in the directory src/tutorial/. (Binary + distributions of PostgreSQL might not + compile these files.) To use those + files, first change to that directory and run make: + +

$ cd ..../src/tutorial
+$ make

+ + This creates the scripts and compiles the C files containing user-defined + functions and types. Then, to start the tutorial, do the following: + +

$ cd ..../tutorial
+$ psql -s mydb
+...
+
+mydb=> \i basics.sql

+ + The \i command reads in commands from the + specified file. psql's -s option puts you in + single step mode which pauses before sending each statement to the + server. The commands used in this section are in the file + basics.sql. +


PrevHomeNext
The SQL LanguageUpConcepts
\ No newline at end of file diff --git a/doc/src/sgml/html/tutorial-sql.html b/doc/src/sgml/html/tutorial-sql.html new file mode 100644 index 000000000..6b14fd51c --- /dev/null +++ b/doc/src/sgml/html/tutorial-sql.html @@ -0,0 +1,219 @@ + +The SQL Language

PrevHomeNext
Accessing a DatabaseUpIntroduction
\ No newline at end of file diff --git a/doc/src/sgml/html/tutorial-start.html b/doc/src/sgml/html/tutorial-start.html new file mode 100644 index 000000000..40670dfff --- /dev/null +++ b/doc/src/sgml/html/tutorial-start.html @@ -0,0 +1,191 @@ + +Getting Started

Chapter 1. Getting Started


PrevHomeNext
TutorialUpInstallation
\ No newline at end of file diff --git a/doc/src/sgml/html/tutorial-table.html b/doc/src/sgml/html/tutorial-table.html new file mode 100644 index 000000000..6e066ead9 --- /dev/null +++ b/doc/src/sgml/html/tutorial-table.html @@ -0,0 +1,335 @@ + +Creating a New Table
PostgreSQL 9.2.2 Documentation
PrevUpChapter 2. The SQL LanguageNext

2.3. Creating a New Table

You can create a new table by specifying the table + name, along with all column names and their types: + +

CREATE TABLE weather (
+    city            varchar(80),
+    temp_lo         int,           -- low temperature
+    temp_hi         int,           -- high temperature
+    prcp            real,          -- precipitation
+    date            date
+);

+ + You can enter this into psql with the line + breaks. psql will recognize that the command + is not terminated until the semicolon. +

White space (i.e., spaces, tabs, and newlines) can be used freely + in SQL commands. That means you can type the command aligned + differently than above, or even all on one line. Two dashes + ("--") introduce comments. + Whatever follows them is ignored up to the end of the line. SQL + is case insensitive about key words and identifiers, except + when identifiers are double-quoted to preserve the case (not done + above). +

varchar(80) specifies a data type that can store + arbitrary character strings up to 80 characters in length. + int is the normal integer type. real is + a type for storing single precision floating-point numbers. + date should be self-explanatory. (Yes, the column of + type date is also named date. + This might be convenient or confusing — you choose.) +

PostgreSQL supports the standard + SQL types int, + smallint, real, double + precision, char(N), + varchar(N), date, + time, timestamp, and + interval, as well as other types of general utility + and a rich set of geometric types. + PostgreSQL can be customized with an + arbitrary number of user-defined data types. Consequently, type + names are not key words in the syntax, except where required to + support special cases in the SQL standard. +

The second example will store cities and their associated + geographical location: +

CREATE TABLE cities (
+    name            varchar(80),
+    location        point
+);

+ The point type is an example of a + PostgreSQL-specific data type. +

+ + Finally, it should be mentioned that if you don't need a table any + longer or want to recreate it differently you can remove it using + the following command: +

DROP TABLE tablename;

+


PrevHomeNext
ConceptsUpPopulating a Table With Rows
\ No newline at end of file diff --git a/doc/src/sgml/html/tutorial-transactions.html b/doc/src/sgml/html/tutorial-transactions.html new file mode 100644 index 000000000..3150d27fc --- /dev/null +++ b/doc/src/sgml/html/tutorial-transactions.html @@ -0,0 +1,391 @@ + +Transactions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 3. Advanced FeaturesNext

3.4. Transactions

Transactions are a fundamental concept of all database + systems. The essential point of a transaction is that it bundles + multiple steps into a single, all-or-nothing operation. The intermediate + states between the steps are not visible to other concurrent transactions, + and if some failure occurs that prevents the transaction from completing, + then none of the steps affect the database at all. +

For example, consider a bank database that contains balances for various + customer accounts, as well as total deposit balances for branches. + Suppose that we want to record a payment of $100.00 from Alice's account + to Bob's account. Simplifying outrageously, the SQL commands for this + might look like: + +

UPDATE accounts SET balance = balance - 100.00
+    WHERE name = 'Alice';
+UPDATE branches SET balance = balance - 100.00
+    WHERE name = (SELECT branch_name FROM accounts WHERE name = 'Alice');
+UPDATE accounts SET balance = balance + 100.00
+    WHERE name = 'Bob';
+UPDATE branches SET balance = balance + 100.00
+    WHERE name = (SELECT branch_name FROM accounts WHERE name = 'Bob');

+

The details of these commands are not important here; the important + point is that there are several separate updates involved to accomplish + this rather simple operation. Our bank's officers will want to be + assured that either all these updates happen, or none of them happen. + It would certainly not do for a system failure to result in Bob + receiving $100.00 that was not debited from Alice. Nor would Alice long + remain a happy customer if she was debited without Bob being credited. + We need a guarantee that if something goes wrong partway through the + operation, none of the steps executed so far will take effect. Grouping + the updates into a transaction gives us this guarantee. + A transaction is said to be atomic: from the point of + view of other transactions, it either happens completely or not at all. +

We also want a + guarantee that once a transaction is completed and acknowledged by + the database system, it has indeed been permanently recorded + and won't be lost even if a crash ensues shortly thereafter. + For example, if we are recording a cash withdrawal by Bob, + we do not want any chance that the debit to his account will + disappear in a crash just after he walks out the bank door. + A transactional database guarantees that all the updates made by + a transaction are logged in permanent storage (i.e., on disk) before + the transaction is reported complete. +

Another important property of transactional databases is closely + related to the notion of atomic updates: when multiple transactions + are running concurrently, each one should not be able to see the + incomplete changes made by others. For example, if one transaction + is busy totalling all the branch balances, it would not do for it + to include the debit from Alice's branch but not the credit to + Bob's branch, nor vice versa. So transactions must be all-or-nothing + not only in terms of their permanent effect on the database, but + also in terms of their visibility as they happen. The updates made + so far by an open transaction are invisible to other transactions + until the transaction completes, whereupon all the updates become + visible simultaneously. +

In PostgreSQL, a transaction is set up by surrounding + the SQL commands of the transaction with + BEGIN and COMMIT commands. So our banking + transaction would actually look like: + +

BEGIN;
+UPDATE accounts SET balance = balance - 100.00
+    WHERE name = 'Alice';
+-- etc etc
+COMMIT;

+

If, partway through the transaction, we decide we do not want to + commit (perhaps we just noticed that Alice's balance went negative), + we can issue the command ROLLBACK instead of + COMMIT, and all our updates so far will be canceled. +

PostgreSQL actually treats every SQL statement as being + executed within a transaction. If you do not issue a BEGIN + command, + then each individual statement has an implicit BEGIN and + (if successful) COMMIT wrapped around it. A group of + statements surrounded by BEGIN and COMMIT + is sometimes called a transaction block. +

Note: Some client libraries issue BEGIN and COMMIT + commands automatically, so that you might get the effect of transaction + blocks without asking. Check the documentation for the interface + you are using. +

It's possible to control the statements in a transaction in a more + granular fashion through the use of savepoints. Savepoints + allow you to selectively discard parts of the transaction, while + committing the rest. After defining a savepoint with + SAVEPOINT, you can if needed roll back to the savepoint + with ROLLBACK TO. All the transaction's database changes + between defining the savepoint and rolling back to it are discarded, but + changes earlier than the savepoint are kept. +

After rolling back to a savepoint, it continues to be defined, so you can + roll back to it several times. Conversely, if you are sure you won't need + to roll back to a particular savepoint again, it can be released, so the + system can free some resources. Keep in mind that either releasing or + rolling back to a savepoint + will automatically release all savepoints that were defined after it. +

All this is happening within the transaction block, so none of it + is visible to other database sessions. When and if you commit the + transaction block, the committed actions become visible as a unit + to other sessions, while the rolled-back actions never become visible + at all. +

Remembering the bank database, suppose we debit $100.00 from Alice's + account, and credit Bob's account, only to find later that we should + have credited Wally's account. We could do it using savepoints like + this: + +

BEGIN;
+UPDATE accounts SET balance = balance - 100.00
+    WHERE name = 'Alice';
+SAVEPOINT my_savepoint;
+UPDATE accounts SET balance = balance + 100.00
+    WHERE name = 'Bob';
+-- oops ... forget that and use Wally's account
+ROLLBACK TO my_savepoint;
+UPDATE accounts SET balance = balance + 100.00
+    WHERE name = 'Wally';
+COMMIT;

+

This example is, of course, oversimplified, but there's a lot of control + possible in a transaction block through the use of savepoints. + Moreover, ROLLBACK TO is the only way to regain control of a + transaction block that was put in aborted state by the + system due to an error, short of rolling it back completely and starting + again. +


PrevHomeNext
Foreign KeysUpWindow Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/tutorial-update.html b/doc/src/sgml/html/tutorial-update.html new file mode 100644 index 000000000..8960ae5fb --- /dev/null +++ b/doc/src/sgml/html/tutorial-update.html @@ -0,0 +1,197 @@ + +Updates
PostgreSQL 9.2.2 Documentation
PrevUpChapter 2. The SQL LanguageNext

2.8. Updates

You can update existing rows using the + UPDATE command. + Suppose you discover the temperature readings are + all off by 2 degrees after November 28. You can correct the + data as follows: + +

UPDATE weather
+    SET temp_hi = temp_hi - 2,  temp_lo = temp_lo - 2
+    WHERE date > '1994-11-28';

+

Look at the new state of the data: +

SELECT * FROM weather;
+
+     city      | temp_lo | temp_hi | prcp |    date
+---------------+---------+---------+------+------------
+ San Francisco |      46 |      50 | 0.25 | 1994-11-27
+ San Francisco |      41 |      55 |    0 | 1994-11-29
+ Hayward       |      35 |      52 |      | 1994-11-29
+(3 rows)

+


PrevHomeNext
Aggregate FunctionsUpDeletions
\ No newline at end of file diff --git a/doc/src/sgml/html/tutorial-views.html b/doc/src/sgml/html/tutorial-views.html new file mode 100644 index 000000000..cfa3f7d08 --- /dev/null +++ b/doc/src/sgml/html/tutorial-views.html @@ -0,0 +1,197 @@ + +Views
PostgreSQL 9.2.2 Documentation
PrevUpChapter 3. Advanced FeaturesNext

3.2. Views

Refer back to the queries in Section 2.6. + Suppose the combined listing of weather records and city location + is of particular interest to your application, but you do not want + to type the query each time you need it. You can create a + view over the query, which gives a name to + the query that you can refer to like an ordinary table: + +

CREATE VIEW myview AS
+    SELECT city, temp_lo, temp_hi, prcp, date, location
+        FROM weather, cities
+        WHERE city = name;
+
+SELECT * FROM myview;

+

Making liberal use of views is a key aspect of good SQL database + design. Views allow you to encapsulate the details of the + structure of your tables, which might change as your application + evolves, behind consistent interfaces. +

Views can be used in almost any place a real table can be used. + Building views upon other views is not uncommon. +


PrevHomeNext
IntroductionUpForeign Keys
\ No newline at end of file diff --git a/doc/src/sgml/html/tutorial-window.html b/doc/src/sgml/html/tutorial-window.html new file mode 100644 index 000000000..2ba748582 --- /dev/null +++ b/doc/src/sgml/html/tutorial-window.html @@ -0,0 +1,570 @@ + +Window Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 3. Advanced FeaturesNext

3.5. Window Functions

A window function performs a calculation across a set of + table rows that are somehow related to the current row. This is comparable + to the type of calculation that can be done with an aggregate function. + But unlike regular aggregate functions, use of a window function does not + cause rows to become grouped into a single output row — the + rows retain their separate identities. Behind the scenes, the window + function is able to access more than just the current row of the query + result. +

Here is an example that shows how to compare each employee's salary + with the average salary in his or her department: + +

SELECT depname, empno, salary, avg(salary) OVER (PARTITION BY depname) FROM empsalary;

+ +

  depname  | empno | salary |          avg          
+-----------+-------+--------+-----------------------
+ develop   |    11 |   5200 | 5020.0000000000000000
+ develop   |     7 |   4200 | 5020.0000000000000000
+ develop   |     9 |   4500 | 5020.0000000000000000
+ develop   |     8 |   6000 | 5020.0000000000000000
+ develop   |    10 |   5200 | 5020.0000000000000000
+ personnel |     5 |   3500 | 3700.0000000000000000
+ personnel |     2 |   3900 | 3700.0000000000000000
+ sales     |     3 |   4800 | 4866.6666666666666667
+ sales     |     1 |   5000 | 4866.6666666666666667
+ sales     |     4 |   4800 | 4866.6666666666666667
+(10 rows)

+ + The first three output columns come directly from the table + empsalary, and there is one output row for each row in the + table. The fourth column represents an average taken across all the table + rows that have the same depname value as the current row. + (This actually is the same function as the regular avg + aggregate function, but the OVER clause causes it to be + treated as a window function and computed across an appropriate set of + rows.) +

A window function call always contains an OVER clause + directly following the window function's name and argument(s). This is what + syntactically distinguishes it from a regular function or aggregate + function. The OVER clause determines exactly how the + rows of the query are split up for processing by the window function. + The PARTITION BY list within OVER specifies + dividing the rows into groups, or partitions, that share the same + values of the PARTITION BY expression(s). For each row, + the window function is computed across the rows that fall into the + same partition as the current row. +

You can also control the order in which rows are processed by + window functions using ORDER BY within OVER. + (The window ORDER BY does not even have to match the + order in which the rows are output.) Here is an example: + +

SELECT depname, empno, salary, rank() OVER (PARTITION BY depname ORDER BY salary DESC) FROM empsalary;

+ +

  depname  | empno | salary | rank 
+-----------+-------+--------+------
+ develop   |     8 |   6000 |    1
+ develop   |    10 |   5200 |    2
+ develop   |    11 |   5200 |    2
+ develop   |     9 |   4500 |    4
+ develop   |     7 |   4200 |    5
+ personnel |     2 |   3900 |    1
+ personnel |     5 |   3500 |    2
+ sales     |     1 |   5000 |    1
+ sales     |     4 |   4800 |    2
+ sales     |     3 |   4800 |    2
+(10 rows)

+ + As shown here, the rank function produces a numerical rank + within the current row's partition for each distinct ORDER BY + value, in the order defined by the ORDER BY clause. + rank needs no explicit parameter, because its behavior + is entirely determined by the OVER clause. +

The rows considered by a window function are those of the "virtual + table" produced by the query's FROM clause as filtered by its + WHERE, GROUP BY, and HAVING clauses + if any. For example, a row removed because it does not meet the + WHERE condition is not seen by any window function. + A query can contain multiple window functions that slice up the data + in different ways by means of different OVER clauses, but + they all act on the same collection of rows defined by this virtual table. +

We already saw that ORDER BY can be omitted if the ordering + of rows is not important. It is also possible to omit PARTITION + BY, in which case there is just one partition containing all the rows. +

There is another important concept associated with window functions: + for each row, there is a set of rows within its partition called its + window frame. Many (but not all) window functions act only + on the rows of the window frame, rather than of the whole partition. + By default, if ORDER BY is supplied then the frame consists of + all rows from the start of the partition up through the current row, plus + any following rows that are equal to the current row according to the + ORDER BY clause. When ORDER BY is omitted the + default frame consists of all rows in the partition. + [1] + Here is an example using sum: +

SELECT salary, sum(salary) OVER () FROM empsalary;
 salary |  sum  
+--------+-------
+   5200 | 47100
+   5000 | 47100
+   3500 | 47100
+   4800 | 47100
+   3900 | 47100
+   4200 | 47100
+   4500 | 47100
+   4800 | 47100
+   6000 | 47100
+   5200 | 47100
+(10 rows)

Above, since there is no ORDER BY in the OVER + clause, the window frame is the same as the partition, which for lack of + PARTITION BY is the whole table; in other words each sum is + taken over the whole table and so we get the same result for each output + row. But if we add an ORDER BY clause, we get very different + results: +

SELECT salary, sum(salary) OVER (ORDER BY salary) FROM empsalary;
 salary |  sum  
+--------+-------
+   3500 |  3500
+   3900 |  7400
+   4200 | 11600
+   4500 | 16100
+   4800 | 25700
+   4800 | 25700
+   5000 | 30700
+   5200 | 41100
+   5200 | 41100
+   6000 | 47100
+(10 rows)

Here the sum is taken from the first (lowest) salary up through the + current one, including any duplicates of the current one (notice the + results for the duplicated salaries). +

Window functions are permitted only in the SELECT list + and the ORDER BY clause of the query. They are forbidden + elsewhere, such as in GROUP BY, HAVING + and WHERE clauses. This is because they logically + execute after the processing of those clauses. Also, window functions + execute after regular aggregate functions. This means it is valid to + include an aggregate function call in the arguments of a window function, + but not vice versa. +

If there is a need to filter or group rows after the window calculations + are performed, you can use a sub-select. For example: + +

SELECT depname, empno, salary, enroll_date
+FROM
+  (SELECT depname, empno, salary, enroll_date,
+          rank() OVER (PARTITION BY depname ORDER BY salary DESC, empno) AS pos
+     FROM empsalary
+  ) AS ss
+WHERE pos < 3;

+ + The above query only shows the rows from the inner query having + rank less than 3. +

When a query involves multiple window functions, it is possible to write + out each one with a separate OVER clause, but this is + duplicative and error-prone if the same windowing behavior is wanted + for several functions. Instead, each windowing behavior can be named + in a WINDOW clause and then referenced in OVER. + For example: + +

SELECT sum(salary) OVER w, avg(salary) OVER w
+  FROM empsalary
+  WINDOW w AS (PARTITION BY depname ORDER BY salary DESC);

+

More details about window functions can be found in + Section 4.2.8, + Section 9.21, + Section 7.2.4, and the + SELECT reference page. +

Notes

[1]

There are options to define the window frame in other ways, but + this tutorial does not cover them. See + Section 4.2.8 for details. +


PrevHomeNext
TransactionsUpInheritance
\ No newline at end of file diff --git a/doc/src/sgml/html/tutorial.html b/doc/src/sgml/html/tutorial.html new file mode 100644 index 000000000..268fbc319 --- /dev/null +++ b/doc/src/sgml/html/tutorial.html @@ -0,0 +1,345 @@ + +Tutorial

I. Tutorial

Welcome to the PostgreSQL Tutorial. The + following few chapters are intended to give a simple introduction + to PostgreSQL, relational database + concepts, and the SQL language to those who are new to any one of + these aspects. We only assume some general knowledge about how to + use computers. No particular Unix or programming experience is + required. This part is mainly intended to give you some hands-on + experience with important aspects of the + PostgreSQL system. It makes no attempt + to be a complete or thorough treatment of the topics it covers. +

After you have worked through this tutorial you might want to move + on to reading Part II to gain a more formal knowledge + of the SQL language, or Part IV for + information about developing applications for + PostgreSQL. Those who set up and + manage their own server should also read Part III. +


PrevHomeNext
Bug Reporting Guidelines Getting Started
\ No newline at end of file diff --git a/doc/src/sgml/html/typeconv-func.html b/doc/src/sgml/html/typeconv-func.html new file mode 100644 index 000000000..5626804c4 --- /dev/null +++ b/doc/src/sgml/html/typeconv-func.html @@ -0,0 +1,585 @@ + +Functions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 10. Type ConversionNext

10.3. Functions

The specific function that is referenced by a function call + is determined using the following procedure. +

Function Type Resolution

  1. Select the functions to be considered from the +pg_proc system catalog. If a non-schema-qualified +function name was used, the functions +considered are those with the matching name and argument count that are +visible in the current search path (see Section 5.7.3). +If a qualified function name was given, only functions in the specified +schema are considered.

    1. If the search path finds multiple functions of identical argument types, +only the one appearing earliest in the path is considered. Functions of +different argument types are considered on an equal footing regardless of +search path position.

    2. If a function is declared with a VARIADIC array parameter, and +the call does not use the VARIADIC keyword, then the function +is treated as if the array parameter were replaced by one or more occurrences +of its element type, as needed to match the call. After such expansion the +function might have effective argument types identical to some non-variadic +function. In that case the function appearing earlier in the search path is +used, or if the two functions are in the same schema, the non-variadic one is +preferred.

    3. Functions that have default values for parameters are considered to match any +call that omits zero or more of the defaultable parameter positions. If more +than one such function matches a call, the one appearing earliest in the +search path is used. If there are two or more such functions in the same +schema with identical parameter types in the non-defaulted positions (which is +possible if they have different sets of defaultable parameters), the system +will not be able to determine which to prefer, and so an "ambiguous +function call" error will result if no better match to the call can be +found.

  2. Check for a function accepting exactly the input argument types. +If one exists (there can be only one exact match in the set of +functions considered), use it. +(Cases involving unknown will never find a match at +this step.)

  3. If no exact match is found, see if the function call appears +to be a special type conversion request. This happens if the function call +has just one argument and the function name is the same as the (internal) +name of some data type. Furthermore, the function argument must be either +an unknown-type literal, or a type that is binary-coercible to the named +data type, or a type that could be converted to the named data type by +applying that type's I/O functions (that is, the conversion is either to or +from one of the standard string types). When these conditions are met, +the function call is treated as a form of CAST specification. + [1]

  4. Look for the best match.

    1. Discard candidate functions for which the input types do not match +and cannot be converted (using an implicit conversion) to match. +unknown literals are +assumed to be convertible to anything for this purpose. If only one +candidate remains, use it; else continue to the next step.

    2. Run through all candidates and keep those with the most exact matches +on input types. (Domains are considered the same as their base type +for this purpose.) Keep all candidates if none have exact matches. +If only one candidate remains, use it; else continue to the next step.

    3. Run through all candidates and keep those that accept preferred types (of the +input data type's type category) at the most positions where type conversion +will be required. +Keep all candidates if none accept preferred types. +If only one candidate remains, use it; else continue to the next step.

    4. If any input arguments are unknown, check the type categories +accepted +at those argument positions by the remaining candidates. At each position, +select the string category if any candidate accepts that category. +(This bias towards string +is appropriate since an unknown-type literal looks like a string.) +Otherwise, if all the remaining candidates accept the same type category, +select that category; otherwise fail because +the correct choice cannot be deduced without more clues. +Now discard candidates that do not accept the selected type category. +Furthermore, if any candidate accepts a preferred type in that category, +discard candidates that accept non-preferred types for that argument. +Keep all candidates if none survive these tests. +If only one candidate remains, use it; else continue to the next step.

    5. If there are both unknown and known-type arguments, and all +the known-type arguments have the same type, assume that the +unknown arguments are also of that type, and check which +candidates can accept that type at the unknown-argument +positions. If exactly one candidate passes this test, use it. +Otherwise, fail.

Note that the "best match" rules are identical for operator and +function type resolution. +Some examples follow.

Example 10-5. Rounding Function Argument Type Resolution

There is only one round function that takes two +arguments; it takes a first argument of type numeric and +a second argument of type integer. +So the following query automatically converts +the first argument of type integer to +numeric: + +

SELECT round(4, 4);
+
+ round
+--------
+ 4.0000
+(1 row)

+ +That query is actually transformed by the parser to: +

SELECT round(CAST (4 AS numeric), 4);

Since numeric constants with decimal points are initially assigned the +type numeric, the following query will require no type +conversion and therefore might be slightly more efficient: +

SELECT round(4.0, 4);

Example 10-6. Substring Function Type Resolution

There are several substr functions, one of which +takes types text and integer. If called +with a string constant of unspecified type, the system chooses the +candidate function that accepts an argument of the preferred category +string (namely of type text). + +

SELECT substr('1234', 3);
+
+ substr
+--------
+     34
+(1 row)

If the string is declared to be of type varchar, as might be the case +if it comes from a table, then the parser will try to convert it to become text: +

SELECT substr(varchar '1234', 3);
+
+ substr
+--------
+     34
+(1 row)

+ +This is transformed by the parser to effectively become: +

SELECT substr(CAST (varchar '1234' AS text), 3);

Note: The parser learns from the pg_cast catalog that +text and varchar +are binary-compatible, meaning that one can be passed to a function that +accepts the other without doing any physical conversion. Therefore, no +type conversion call is really inserted in this case.

And, if the function is called with an argument of type integer, +the parser will try to convert that to text: +

SELECT substr(1234, 3);
+ERROR:  function substr(integer, integer) does not exist
+HINT:  No function matches the given name and argument types. You might need
+to add explicit type casts.

+ +This does not work because integer does not have an implicit cast +to text. An explicit cast will work, however: +

SELECT substr(CAST (1234 AS text), 3);
+
+ substr
+--------
+     34
+(1 row)

Notes

[1]

The reason for this step is to support function-style cast specifications + in cases where there is not an actual cast function. If there is a cast + function, it is conventionally named after its output type, and so there + is no need to have a special case. See + CREATE CAST + for additional commentary. +


PrevHomeNext
OperatorsUpValue Storage
\ No newline at end of file diff --git a/doc/src/sgml/html/typeconv-oper.html b/doc/src/sgml/html/typeconv-oper.html new file mode 100644 index 000000000..4c93c2f39 --- /dev/null +++ b/doc/src/sgml/html/typeconv-oper.html @@ -0,0 +1,575 @@ + +Operators
PostgreSQL 9.2.2 Documentation
PrevUpChapter 10. Type ConversionNext

10.2. Operators

The specific operator that is referenced by an operator expression + is determined using the following procedure. + Note that this procedure is indirectly affected + by the precedence of the involved operators, since that will determine + which sub-expressions are taken to be the inputs of which operators. + See Section 4.1.6 for more information. +

Operator Type Resolution

  1. Select the operators to be considered from the +pg_operator system catalog. If a non-schema-qualified +operator name was used (the usual case), the operators +considered are those with the matching name and argument count that are +visible in the current search path (see Section 5.7.3). +If a qualified operator name was given, only operators in the specified +schema are considered.

    1. If the search path finds multiple operators with identical argument types, +only the one appearing earliest in the path is considered. Operators with +different argument types are considered on an equal footing regardless of +search path position.

  2. Check for an operator accepting exactly the input argument types. +If one exists (there can be only one exact match in the set of +operators considered), use it.

    1. If one argument of a binary operator invocation is of the unknown type, +then assume it is the same type as the other argument for this check. +Invocations involving two unknown inputs, or a unary operator +with an unknown input, will never find a match at this step.

  3. Look for the best match.

    1. Discard candidate operators for which the input types do not match +and cannot be converted (using an implicit conversion) to match. +unknown literals are +assumed to be convertible to anything for this purpose. If only one +candidate remains, use it; else continue to the next step.

    2. Run through all candidates and keep those with the most exact matches +on input types. (Domains are considered the same as their base type +for this purpose.) Keep all candidates if none have exact matches. +If only one candidate remains, use it; else continue to the next step.

    3. Run through all candidates and keep those that accept preferred types (of the +input data type's type category) at the most positions where type conversion +will be required. +Keep all candidates if none accept preferred types. +If only one candidate remains, use it; else continue to the next step.

    4. If any input arguments are unknown, check the type +categories accepted at those argument positions by the remaining +candidates. At each position, select the string category +if any +candidate accepts that category. (This bias towards string is appropriate +since an unknown-type literal looks like a string.) Otherwise, if +all the remaining candidates accept the same type category, select that +category; otherwise fail because the correct choice cannot be deduced +without more clues. Now discard +candidates that do not accept the selected type category. Furthermore, +if any candidate accepts a preferred type in that category, +discard candidates that accept non-preferred types for that argument. +Keep all candidates if none survive these tests. +If only one candidate remains, use it; else continue to the next step.

    5. If there are both unknown and known-type arguments, and all +the known-type arguments have the same type, assume that the +unknown arguments are also of that type, and check which +candidates can accept that type at the unknown-argument +positions. If exactly one candidate passes this test, use it. +Otherwise, fail.

Some examples follow.

Example 10-1. Factorial Operator Type Resolution

There is only one factorial operator (postfix !) +defined in the standard catalog, and it takes an argument of type +bigint. +The scanner assigns an initial type of integer to the argument +in this query expression: +

SELECT 40 ! AS "40 factorial";
+
+                   40 factorial
+--------------------------------------------------
+ 815915283247897734345611269596115894272000000000
+(1 row)

+ +So the parser does a type conversion on the operand and the query +is equivalent to: + +

SELECT CAST(40 AS bigint) ! AS "40 factorial";

Example 10-2. String Concatenation Operator Type Resolution

A string-like syntax is used for working with string types and for +working with complex extension types. +Strings with unspecified type are matched with likely operator candidates.

An example with one unspecified argument: +

SELECT text 'abc' || 'def' AS "text and unknown";
+
+ text and unknown
+------------------
+ abcdef
+(1 row)

In this case the parser looks to see if there is an operator taking text +for both arguments. Since there is, it assumes that the second argument should +be interpreted as type text.

Here is a concatenation of two values of unspecified types: +

SELECT 'abc' || 'def' AS "unspecified";
+
+ unspecified
+-------------
+ abcdef
+(1 row)

In this case there is no initial hint for which type to use, since no types +are specified in the query. So, the parser looks for all candidate operators +and finds that there are candidates accepting both string-category and +bit-string-category inputs. Since string category is preferred when available, +that category is selected, and then the +preferred type for strings, text, is used as the specific +type to resolve the unknown-type literals as.

Example 10-3. Absolute-Value and Negation Operator Type Resolution

The PostgreSQL operator catalog has several +entries for the prefix operator @, all of which implement +absolute-value operations for various numeric data types. One of these +entries is for type float8, which is the preferred type in +the numeric category. Therefore, PostgreSQL +will use that entry when faced with an unknown input: +

SELECT @ '-4.5' AS "abs";
+ abs
+-----
+ 4.5
+(1 row)

+Here the system has implicitly resolved the unknown-type literal as type +float8 before applying the chosen operator. We can verify that +float8 and not some other type was used: +

SELECT @ '-4.5e500' AS "abs";
+
+ERROR:  "-4.5e500" is out of range for type double precision

On the other hand, the prefix operator ~ (bitwise negation) +is defined only for integer data types, not for float8. So, if we +try a similar case with ~, we get: +

SELECT ~ '20' AS "negation";
+
+ERROR:  operator is not unique: ~ "unknown"
+HINT:  Could not choose a best candidate operator. You might need to add
+explicit type casts.

+This happens because the system cannot decide which of the several +possible ~ operators should be preferred. We can help +it out with an explicit cast: +

SELECT ~ CAST('20' AS int8) AS "negation";
+
+ negation
+----------
+      -21
+(1 row)

Example 10-4. Array Inclusion Operator Type Resolution

Here is another example of resolving an operator with one known and one +unknown input: +

SELECT array[1,2] <@ '{1,2,3}' as "is subset";
+
+ is subset
+-----------
+ t
+(1 row)

+The PostgreSQL operator catalog has several +entries for the infix operator <@, but the only two that +could possibly accept an integer array on the left-hand side are +array inclusion (anyarray <@ anyarray) +and range inclusion (anyelement <@ anyrange). +Since none of these polymorphic pseudo-types (see Section 8.19) are considered preferred, the parser cannot +resolve the ambiguity on that basis. However, the last resolution rule tells +it to assume that the unknown-type literal is of the same type as the other +input, that is, integer array. Now only one of the two operators can match, +so array inclusion is selected. (Had range inclusion been selected, we would +have gotten an error, because the string does not have the right format to be +a range literal.)


PrevHomeNext
OverviewUpFunctions
\ No newline at end of file diff --git a/doc/src/sgml/html/typeconv-overview.html b/doc/src/sgml/html/typeconv-overview.html new file mode 100644 index 000000000..94577b8ee --- /dev/null +++ b/doc/src/sgml/html/typeconv-overview.html @@ -0,0 +1,419 @@ + +Overview
PostgreSQL 9.2.2 Documentation
PrevUpChapter 10. Type ConversionNext

10.1. Overview

SQL is a strongly typed language. That is, every data item +has an associated data type which determines its behavior and allowed usage. +PostgreSQL has an extensible type system that is +more general and flexible than other SQL implementations. +Hence, most type conversion behavior in PostgreSQL +is governed by general rules rather than by ad hoc +heuristics. This allows the use of mixed-type expressions even with +user-defined types.

The PostgreSQL scanner/parser divides lexical +elements into five fundamental categories: integers, non-integer numbers, +strings, identifiers, and key words. Constants of most non-numeric types are +first classified as strings. The SQL language definition +allows specifying type names with strings, and this mechanism can be used in +PostgreSQL to start the parser down the correct +path. For example, the query: + +

SELECT text 'Origin' AS "label", point '(0,0)' AS "value";
+
+ label  | value
+--------+-------
+ Origin | (0,0)
+(1 row)

+ +has two literal constants, of type text and point. +If a type is not specified for a string literal, then the placeholder type +unknown is assigned initially, to be resolved in later +stages as described below.

There are four fundamental SQL constructs requiring +distinct type conversion rules in the PostgreSQL +parser: + +

Function calls

Much of the PostgreSQL type system is built around a +rich set of functions. Functions can have one or more arguments. +Since PostgreSQL permits function +overloading, the function name alone does not uniquely identify the function +to be called; the parser must select the right function based on the data +types of the supplied arguments.

Operators

PostgreSQL allows expressions with +prefix and postfix unary (one-argument) operators, +as well as binary (two-argument) operators. Like functions, operators can +be overloaded, so the same problem of selecting the right operator +exists.

Value Storage

SQL INSERT and UPDATE statements place the results of +expressions into a table. The expressions in the statement must be matched up +with, and perhaps converted to, the types of the target columns.

UNION, CASE, and related constructs

Since all query results from a unionized SELECT statement +must appear in a single set of columns, the types of the results of each +SELECT clause must be matched up and converted to a uniform set. +Similarly, the result expressions of a CASE construct must be +converted to a common type so that the CASE expression as a whole +has a known output type. The same holds for ARRAY constructs, +and for the GREATEST and LEAST functions.

The system catalogs store information about which conversions, or +casts, exist between which data types, and how to +perform those conversions. Additional casts can be added by the user +with the CREATE CAST +command. (This is usually +done in conjunction with defining new data types. The set of casts +between built-in types has been carefully crafted and is best not +altered.)

An additional heuristic provided by the parser allows improved determination +of the proper casting behavior among groups of types that have implicit casts. +Data types are divided into several basic type +categories, including boolean, numeric, +string, bitstring, datetime, +timespan, geometric, network, and +user-defined. (For a list see Table 45-51; +but note it is also possible to create custom type categories.) Within each +category there can be one or more preferred types, which +are preferred when there is a choice of possible types. With careful selection +of preferred types and available implicit casts, it is possible to ensure that +ambiguous expressions (those with multiple candidate parsing solutions) can be +resolved in a useful way.

All type conversion rules are designed with several principles in mind: + +

  • Implicit conversions should never have surprising or unpredictable outcomes.

  • There should be no extra overhead in the parser or executor +if a query does not need implicit type conversion. +That is, if a query is well-formed and the types already match, then the query should execute +without spending extra time in the parser and without introducing unnecessary implicit conversion +calls in the query.

    Additionally, if a query usually requires an implicit conversion for a function, and +if then the user defines a new function with the correct argument types, the parser +should use this new function and no longer do implicit conversion to use the old function.


PrevHomeNext
Type ConversionUpOperators
\ No newline at end of file diff --git a/doc/src/sgml/html/typeconv-query.html b/doc/src/sgml/html/typeconv-query.html new file mode 100644 index 000000000..8364428dc --- /dev/null +++ b/doc/src/sgml/html/typeconv-query.html @@ -0,0 +1,303 @@ + +Value Storage
PostgreSQL 9.2.2 Documentation
PrevUpChapter 10. Type ConversionNext

10.4. Value Storage

Values to be inserted into a table are converted to the destination + column's data type according to the + following steps. +

Value Storage Type Conversion

  1. Check for an exact match with the target.

  2. Otherwise, try to convert the expression to the target type. This will succeed +if there is a registered cast between the two types. +If the expression is an unknown-type literal, the contents of +the literal string will be fed to the input conversion routine for the target +type.

  3. Check to see if there is a sizing cast for the target type. A sizing +cast is a cast from that type to itself. If one is found in the +pg_cast catalog, apply it to the expression before storing +into the destination column. The implementation function for such a cast +always takes an extra parameter of type integer, which receives +the destination column's atttypmod value (typically its +declared length, although the interpretation of atttypmod +varies for different data types), and it may take a third boolean +parameter that says whether the cast is explicit or implicit. The cast +function +is responsible for applying any length-dependent semantics such as size +checking or truncation.

Example 10-7. character Storage Type Conversion

For a target column declared as character(20) the following +statement shows that the stored value is sized correctly: + +

CREATE TABLE vv (v character(20));
+INSERT INTO vv SELECT 'abc' || 'def';
+SELECT v, octet_length(v) FROM vv;
+
+          v           | octet_length
+----------------------+--------------
+ abcdef               |           20
+(1 row)

What has really happened here is that the two unknown literals are resolved +to text by default, allowing the || operator +to be resolved as text concatenation. Then the text +result of the operator is converted to bpchar ("blank-padded +char", the internal name of the character data type) to match the target +column type. (Since the conversion from text to +bpchar is binary-coercible, this conversion does +not insert any real function call.) Finally, the sizing function +bpchar(bpchar, integer, boolean) is found in the system catalog +and applied to the operator's result and the stored column length. This +type-specific function performs the required length check and addition of +padding spaces.


PrevHomeNext
FunctionsUpUNION, CASE, and Related Constructs
\ No newline at end of file diff --git a/doc/src/sgml/html/typeconv-union-case.html b/doc/src/sgml/html/typeconv-union-case.html new file mode 100644 index 000000000..c0f496653 --- /dev/null +++ b/doc/src/sgml/html/typeconv-union-case.html @@ -0,0 +1,382 @@ + +UNION, CASE, and Related Constructs
PostgreSQL 9.2.2 Documentation
PrevUpChapter 10. Type ConversionNext

10.5. UNION, CASE, and Related Constructs

SQL UNION constructs must match up possibly dissimilar +types to become a single result set. The resolution algorithm is +applied separately to each output column of a union query. The +INTERSECT and EXCEPT constructs resolve +dissimilar types in the same way as UNION. The +CASE, ARRAY, VALUES, +GREATEST and LEAST constructs use the identical +algorithm to match up their component expressions and select a result +data type.

Type Resolution for UNION, CASE, +and Related Constructs

  1. If all inputs are of the same type, and it is not unknown, +resolve as that type. Otherwise, replace any domain types in the list with +their underlying base types.

  2. If all inputs are of type unknown, resolve as type +text (the preferred type of the string category). +Otherwise, unknown inputs are ignored.

  3. If the non-unknown inputs are not all of the same type category, fail.

  4. Choose the first non-unknown input type which is a preferred type in +that category, if there is one.

  5. Otherwise, choose the last non-unknown input type that allows all the +preceding non-unknown inputs to be implicitly converted to it. (There +always is such a type, since at least the first type in the list must +satisfy this condition.)

  6. Convert all inputs to the selected type. Fail if there is not a +conversion from a given input to the selected type.

Some examples follow.

Example 10-8. Type Resolution with Underspecified Types in a Union

SELECT text 'a' AS "text" UNION SELECT 'b';
+
+ text
+------
+ a
+ b
+(2 rows)

+Here, the unknown-type literal 'b' will be resolved to type text.

Example 10-9. Type Resolution in a Simple Union

SELECT 1.2 AS "numeric" UNION SELECT 1;
+
+ numeric
+---------
+       1
+     1.2
+(2 rows)

+The literal 1.2 is of type numeric, +and the integer value 1 can be cast implicitly to +numeric, so that type is used.

Example 10-10. Type Resolution in a Transposed Union

SELECT 1 AS "real" UNION SELECT CAST('2.2' AS REAL);
+
+ real
+------
+    1
+  2.2
+(2 rows)

+Here, since type real cannot be implicitly cast to integer, +but integer can be implicitly cast to real, the union +result type is resolved as real.


PrevHomeNext
Value StorageUpIndexes
\ No newline at end of file diff --git a/doc/src/sgml/html/typeconv.html b/doc/src/sgml/html/typeconv.html new file mode 100644 index 000000000..a78d86a20 --- /dev/null +++ b/doc/src/sgml/html/typeconv.html @@ -0,0 +1,243 @@ + +Type Conversion

Chapter 10. Type Conversion

SQL statements can, intentionally or not, require +the mixing of different data types in the same expression. +PostgreSQL has extensive facilities for +evaluating mixed-type expressions.

In many cases a user does not need +to understand the details of the type conversion mechanism. +However, implicit conversions done by PostgreSQL +can affect the results of a query. When necessary, these results +can be tailored by using explicit type conversion.

This chapter introduces the PostgreSQL +type conversion mechanisms and conventions. +Refer to the relevant sections in Chapter 8 and Chapter 9 +for more information on specific data types and allowed functions and +operators.


PrevHomeNext
Trigger FunctionsUpOverview
\ No newline at end of file diff --git a/doc/src/sgml/html/unaccent.html b/doc/src/sgml/html/unaccent.html new file mode 100644 index 000000000..074928f0b --- /dev/null +++ b/doc/src/sgml/html/unaccent.html @@ -0,0 +1,402 @@ + +unaccent
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.39. unaccent

unaccent is a text search dictionary that removes accents + (diacritic signs) from lexemes. + It's a filtering dictionary, which means its output is + always passed to the next dictionary (if any), unlike the normal + behavior of dictionaries. This allows accent-insensitive processing + for full text search. +

The current implementation of unaccent cannot be used as a + normalizing dictionary for the thesaurus dictionary. +

F.39.1. Configuration

An unaccent dictionary accepts the following options: +

  • RULES is the base name of the file containing the list of + translation rules. This file must be stored in + $SHAREDIR/tsearch_data/ (where $SHAREDIR means + the PostgreSQL installation's shared-data directory). + Its name must end in .rules (which is not to be included in + the RULES parameter). +

The rules file has the following format: +

  • Each line represents a pair, consisting of a character with accent + followed by a character without accent. The first is translated into + the second. For example, +

    À        A
    +Á        A
    +Â        A
    +Ã        A
    +Ä        A
    +Å        A
    +Æ        A

    +

A more complete example, which is directly useful for most European + languages, can be found in unaccent.rules, which is installed + in $SHAREDIR/tsearch_data/ when the unaccent + module is installed. +

F.39.2. Usage

Installing the unaccent extension creates a text + search template unaccent and a dictionary unaccent + based on it. The unaccent dictionary has the default + parameter setting RULES='unaccent', which makes it immediately + usable with the standard unaccent.rules file. + If you wish, you can alter the parameter, for example + +

mydb=# ALTER TEXT SEARCH DICTIONARY unaccent (RULES='my_rules');

+ + or create new dictionaries based on the template. +

To test the dictionary, you can try: +

mydb=# select ts_lexize('unaccent','Hôtel');
+ ts_lexize
+-----------
+ {Hotel}
+(1 row)

+

Here is an example showing how to insert the + unaccent dictionary into a text search configuration: +

mydb=# CREATE TEXT SEARCH CONFIGURATION fr ( COPY = french );
+mydb=# ALTER TEXT SEARCH CONFIGURATION fr
+        ALTER MAPPING FOR hword, hword_part, word
+        WITH unaccent, french_stem;
+mydb=# select to_tsvector('fr','Hôtels de la Mer');
+    to_tsvector
+-------------------
+ 'hotel':1 'mer':4
+(1 row)
+
+mydb=# select to_tsvector('fr','Hôtel de la Mer') @@ to_tsquery('fr','Hotels');
+ ?column?
+----------
+ t
+(1 row)
+
+mydb=# select ts_headline('fr','Hôtel de la Mer',to_tsquery('fr','Hotels'));
+      ts_headline
+------------------------
+ <b>Hôtel</b> de la Mer
+(1 row)

+

F.39.3. Functions

The unaccent() function removes accents (diacritic signs) from + a given string. Basically, it's a wrapper around the + unaccent dictionary, but it can be used outside normal + text search contexts. +

unaccent([dictionary, ] string) returns text

For example: +

SELECT unaccent('unaccent', 'Hôtel');
+SELECT unaccent('Hôtel');

+


PrevHomeNext
tsearch2Upuuid-ossp
\ No newline at end of file diff --git a/doc/src/sgml/html/unsupported-features-sql-standard.html b/doc/src/sgml/html/unsupported-features-sql-standard.html new file mode 100644 index 000000000..1e8985e33 --- /dev/null +++ b/doc/src/sgml/html/unsupported-features-sql-standard.html @@ -0,0 +1,3355 @@ + +Unsupported Features
PostgreSQL 9.2.2 Documentation
PrevUpAppendix D. SQL ConformanceNext

D.2. Unsupported Features

The following features defined in SQL:2011 are not + implemented in this release of + PostgreSQL. In a few cases, equivalent + functionality is available. + +

IdentifierPackageDescriptionComment
B011 Embedded Ada 
B013 Embedded COBOL 
B014 Embedded Fortran 
B015 Embedded MUMPS 
B016 Embedded Pascal 
B017 Embedded PL/I 
B031 Basic dynamic SQL 
B032 Extended dynamic SQL 
B032-01 <describe input statement> 
B033 Untyped SQL-invoked function arguments 
B034 Dynamic specification of cursor attributes 
B035 Non-extended descriptor names 
B041 Extensions to embedded SQL exception declarations 
B051 Enhanced execution rights 
B111 Module language Ada 
B112 Module language C 
B113 Module language COBOL 
B114 Module language Fortran 
B115 Module language MUMPS 
B116 Module language Pascal 
B117 Module language PL/I 
B121 Routine language Ada 
B122 Routine language C 
B123 Routine language COBOL 
B124 Routine language Fortran 
B125 Routine language MUMPS 
B126 Routine language Pascal 
B127 Routine language PL/I 
B128 Routine language SQL 
B211 Module language Ada: VARCHAR and NUMERIC support 
B221 Routine language Ada: VARCHAR and NUMERIC support 
E153CoreUpdatable queries with subqueries 
E182CoreModule language 
F054 TIMESTAMP in DATE type precedence list 
F121 Basic diagnostics management 
F121-01 GET DIAGNOSTICS statement 
F121-02 SET TRANSACTION statement: DIAGNOSTICS SIZE clause 
F122 Enhanced diagnostics management 
F123 All diagnostics 
F181CoreMultiple module support 
F202 TRUNCATE TABLE: identity column restart option 
F263 Comma-separated predicates in simple CASE expression 
F291 UNIQUE predicate 
F301 CORRESPONDING in query expressions 
F311CoreSchema definition statement 
F311-04CoreCREATE VIEW: WITH CHECK OPTION 
F312 MERGE statement 
F313 Enhanced MERGE statement 
F314 MERGE statement with DELETE branch 
F341 Usage tablesno ROUTINE_*_USAGE tables
F384 Drop identity property clause 
F385 Drop column generation expression clause 
F386 Set identity column generation clause 
F394 Optional normal form specification 
F403 Partitioned joined tables 
F451 Character set definition 
F461 Named character sets 
F492 Optional table constraint enforcement 
F521Enhanced integrity managementAssertions 
F671Enhanced integrity managementSubqueries in CHECKintentionally omitted
F693 SQL-session and client module collations 
F695 Translation support 
F696 Additional translation documentation 
F721 Deferrable constraintsforeign and unique keys only
F741 Referential MATCH typesno partial match yet
F751 View CHECK enhancements 
F812CoreBasic flagging 
F813 Extended flagging 
F821 Local table references 
F831 Full cursor update 
F831-01 Updatable scrollable cursors 
F831-02 Updatable ordered cursors 
F841 LIKE_REGEX predicate 
F842 OCCURENCES_REGEX function 
F843 POSITION_REGEX function 
F844 SUBSTRING_REGEX function 
F845 TRANSLATE_REGEX function 
F846 Octet support in regular expression operators 
F847 Nonconstant regular expressions 
F866 FETCH FIRST clause: PERCENT option 
F867 FETCH FIRST clause: WITH TIES option 
S011CoreDistinct data types 
S011-01CoreUSER_DEFINED_TYPES view 
S023Basic object supportBasic structured types 
S024Enhanced object supportEnhanced structured types 
S025 Final structured types 
S026 Self-referencing structured types 
S027 Create method by specific method name 
S028 Permutable UDT options list 
S041Basic object supportBasic reference types 
S043Enhanced object supportEnhanced reference types 
S051Basic object supportCreate table of typepartially supported
S081Enhanced object supportSubtables 
S091 Basic array supportpartially supported
S091-01 Arrays of built-in data types 
S091-02 Arrays of distinct types 
S091-03 Array expressions 
S094 Arrays of reference types 
S097 Array element assignment 
S151Basic object supportType predicate 
S161Enhanced object supportSubtype treatment 
S162 Subtype treatment for references 
S202 SQL-invoked routines on multisets 
S231Enhanced object supportStructured type locators 
S232 Array locators 
S233 Multiset locators 
S241 Transform functions 
S242 Alter transform statement 
S251 User-defined orderings 
S261 Specific type method 
S271 Basic multiset support 
S272 Multisets of user-defined types 
S274 Multisets of reference types 
S275 Advanced multiset support 
S281 Nested collection types 
S291 Unique constraint on entire row 
S301 Enhanced UNNEST 
S401 Distinct types based on array types 
S402 Distinct types based on distinct types 
S403 MAX_CARDINALITY 
S404 TRIM_ARRAY 
T011 Timestamp in Information Schema 
T021 BINARY and VARBINARY data types 
T022 Advanced support for BINARY and VARBINARY data types 
T023 Compound binary literal 
T024 Spaces in binary literals 
T041Basic object supportBasic LOB data type support 
T041-01Basic object supportBLOB data type 
T041-02Basic object supportCLOB data type 
T041-03Basic object supportPOSITION, LENGTH, LOWER, TRIM, UPPER, and SUBSTRING functions for LOB data types 
T041-04Basic object supportConcatenation of LOB data types 
T041-05Basic object supportLOB locator: non-holdable 
T042 Extended LOB data type support 
T043 Multiplier T 
T044 Multiplier P 
T051 Row types 
T052 MAX and MIN for row types 
T053 Explicit aliases for all-fields reference 
T061 UCS support 
T101 Enhanced nullability determination 
T111 Updatable joins, unions, and columns 
T174 Identity columns 
T175 Generated columns 
T176 Sequence generator support 
T177 Sequence generator support: simple restart option 
T178 Identity columns: simple restart option 
T180 System-versioned tables 
T181 Application-time period tables 
T211Active database, Enhanced integrity managementBasic trigger capability 
T211-06Active database, Enhanced integrity managementSupport for run-time rules for the interaction of triggers and constraints 
T211-08Active database, Enhanced integrity managementMultiple triggers for the same event are executed in the order in which they were created in the catalogintentionally omitted
T251 SET TRANSACTION statement: LOCAL option 
T261 Chained transactions 
T272 Enhanced savepoint management 
T285 Enhanced derived column names 
T301 Functional dependenciespartially supported
T321CoreBasic SQL-invoked routines 
T321-02CoreUser-defined stored procedures with no overloading 
T321-04CoreCALL statement 
T321-05CoreRETURN statement 
T322PSMDeclared data type attributes 
T324 Explicit security for SQL routines 
T325 Qualified SQL parameter references 
T326 Table functions 
T332 Extended rolesmostly supported
T431OLAPExtended grouping capabilities 
T432 Nested and concatenated GROUPING SETS 
T433 Multiargument GROUPING function 
T434 GROUP BY DISTINCT 
T471 Result sets return value 
T472 DESCRIBE CURSOR 
T491 LATERAL derived table 
T495 Combined data change and retrievaldifferent syntax
T502 Period predicates 
T511 Transaction counts 
T521 Named arguments in CALL statement 
T522 Default values for IN parameters of SQL-invoked procedures 
T541 Updatable table references 
T561 Holdable locators 
T571 Array-returning external SQL-invoked functions 
T572 Multiset-returning external SQL-invoked functions 
T601 Local cursor references 
T611OLAPElementary OLAP operationsmost forms supported
T612 Advanced OLAP operationssome forms supported
T613 Sampling 
T616 Null treatment option for LEAD and LAG functions 
T618 NTH_VALUE functionfunction exists, but some options missing
T619 Nested window functions 
T620 WINDOW clause: GROUPS option 
T641 Multiple column assignmentonly some syntax variants supported
T652 SQL-dynamic statements in SQL routines 
T653 SQL-schema statements in external routines 
T654 SQL-dynamic statements in external routines 
M001 Datalinks 
M002 Datalinks via SQL/CLI 
M003 Datalinks via Embedded SQL 
M004 Foreign data supportpartially supported
M005 Foreign schema support 
M006 GetSQLString routine 
M007 TransmitRequest 
M009 GetOpts and GetStatistics routines 
M010 Foreign data wrapper support 
M011 Datalinks via Ada 
M012 Datalinks via C 
M013 Datalinks via COBOL 
M014 Datalinks via Fortran 
M015 Datalinks via M 
M016 Datalinks via Pascal 
M017 Datalinks via PL/I 
M018 Foreign data wrapper interface routines in Ada 
M019 Foreign data wrapper interface routines in C 
M020 Foreign data wrapper interface routines in COBOL 
M021 Foreign data wrapper interface routines in Fortran 
M022 Foreign data wrapper interface routines in MUMPS 
M023 Foreign data wrapper interface routines in Pascal 
M024 Foreign data wrapper interface routines in PL/I 
M030 SQL-server foreign data support 
M031 Foreign data wrapper general routines 
X012 Multisets of XML type 
X013 Distinct types of XML type 
X014 Attributes of XML type 
X015 Fields of XML type 
X025 XMLCast 
X030 XMLDocument 
X038 XMLText 
X065 XMLParse: BLOB input and CONTENT option 
X066 XMLParse: BLOB input and DOCUMENT option 
X068 XMLSerialize: BOM 
X069 XMLSerialize: INDENT 
X073 XMLSerialize: BLOB serialization and CONTENT option 
X074 XMLSerialize: BLOB serialization and DOCUMENT option 
X075 XMLSerialize: BLOB serialization 
X076 XMLSerialize: VERSION 
X077 XMLSerialize: explicit ENCODING option 
X078 XMLSerialize: explicit XML declaration 
X080 Namespaces in XML publishing 
X081 Query-level XML namespace declarations 
X082 XML namespace declarations in DML 
X083 XML namespace declarations in DDL 
X084 XML namespace declarations in compound statements 
X085 Predefined namespace prefixes 
X086 XML namespace declarations in XMLTable 
X091 XML content predicate 
X096 XMLExists 
X100 Host language support for XML: CONTENT option 
X101 Host language support for XML: DOCUMENT option 
X110 Host language support for XML: VARCHAR mapping 
X111 Host language support for XML: CLOB mapping 
X112 Host language support for XML: BLOB mapping 
X113 Host language support for XML: STRIP WHITESPACE option 
X114 Host language support for XML: PRESERVE WHITESPACE option 
X131 Query-level XMLBINARY clause 
X132 XMLBINARY clause in DML 
X133 XMLBINARY clause in DDL 
X134 XMLBINARY clause in compound statements 
X135 XMLBINARY clause in subqueries 
X141 IS VALID predicate: data-driven case 
X142 IS VALID predicate: ACCORDING TO clause 
X143 IS VALID predicate: ELEMENT clause 
X144 IS VALID predicate: schema location 
X145 IS VALID predicate outside check constraints 
X151 IS VALID predicate with DOCUMENT option 
X152 IS VALID predicate with CONTENT option 
X153 IS VALID predicate with SEQUENCE option 
X155 IS VALID predicate: NAMESPACE without ELEMENT clause 
X157 IS VALID predicate: NO NAMESPACE with ELEMENT clause 
X160 Basic Information Schema for registered XML Schemas 
X161 Advanced Information Schema for registered XML Schemas 
X170 XML null handling options 
X171 NIL ON NO CONTENT option 
X181 XML(DOCUMENT(UNTYPED)) type 
X182 XML(DOCUMENT(ANY)) type 
X190 XML(SEQUENCE) type 
X191 XML(DOCUMENT(XMLSCHEMA)) type 
X192 XML(CONTENT(XMLSCHEMA)) type 
X200 XMLQuery 
X201 XMLQuery: RETURNING CONTENT 
X202 XMLQuery: RETURNING SEQUENCE 
X203 XMLQuery: passing a context item 
X204 XMLQuery: initializing an XQuery variable 
X205 XMLQuery: EMPTY ON EMPTY option 
X206 XMLQuery: NULL ON EMPTY option 
X211 XML 1.1 support 
X221 XML passing mechanism BY VALUE 
X222 XML passing mechanism BY REF 
X231 XML(CONTENT(UNTYPED)) type 
X232 XML(CONTENT(ANY)) type 
X241 RETURNING CONTENT in XML publishing 
X242 RETURNING SEQUENCE in XML publishing 
X251 Persistent XML values of XML(DOCUMENT(UNTYPED)) type 
X252 Persistent XML values of XML(DOCUMENT(ANY)) type 
X253 Persistent XML values of XML(CONTENT(UNTYPED)) type 
X254 Persistent XML values of XML(CONTENT(ANY)) type 
X255 Persistent XML values of XML(SEQUENCE) type 
X256 Persistent XML values of XML(DOCUMENT(XMLSCHEMA)) type 
X257 Persistent XML values of XML(CONTENT(XMLSCHEMA)) type 
X260 XML type: ELEMENT clause 
X261 XML type: NAMESPACE without ELEMENT clause 
X263 XML type: NO NAMESPACE with ELEMENT clause 
X264 XML type: schema location 
X271 XMLValidate: data-driven case 
X272 XMLValidate: ACCORDING TO clause 
X273 XMLValidate: ELEMENT clause 
X274 XMLValidate: schema location 
X281 XMLValidate: with DOCUMENT option 
X282 XMLValidate with CONTENT option 
X283 XMLValidate with SEQUENCE option 
X284 XMLValidate NAMESPACE without ELEMENT clause 
X286 XMLValidate: NO NAMESPACE with ELEMENT clause 
X300 XMLTable 
X301 XMLTable: derived column list option 
X302 XMLTable: ordinality column option 
X303 XMLTable: column default option 
X304 XMLTable: passing a context item 
X305 XMLTable: initializing an XQuery variable 

+


PrevHomeNext
Supported FeaturesUpRelease Notes
\ No newline at end of file diff --git a/doc/src/sgml/html/upgrading.html b/doc/src/sgml/html/upgrading.html new file mode 100644 index 000000000..0a5bc447f --- /dev/null +++ b/doc/src/sgml/html/upgrading.html @@ -0,0 +1,602 @@ + +Upgrading a PostgreSQL Cluster
PostgreSQL 9.2.2 Documentation
PrevUpChapter 17. Server Setup and OperationNext

17.6. Upgrading a PostgreSQL Cluster

This section discusses how to upgrade your database data from one + PostgreSQL release to a newer one. +

PostgreSQL major versions are represented by the + first two digit groups of the version number, e.g., 8.4. + PostgreSQL minor versions are represented by the + third group of version digits, e.g., 8.4.2 is the second minor + release of 8.4. Minor releases never change the internal storage + format and are always compatible with earlier and later minor + releases of the same major version number, e.g., 8.4.2 is compatible + with 8.4, 8.4.1 and 8.4.6. To update between compatible versions, + you simply replace the executables while the server is down and + restart the server. The data directory remains unchanged — + minor upgrades are that simple. +

For major releases of PostgreSQL, the + internal data storage format is subject to change, thus complicating + upgrades. The traditional method for moving data to a new major version + is to dump and reload the database. Other methods are available, + as discussed below. +

New major versions also typically introduce some user-visible + incompatibilities, so application programming changes might be required. + All user-visible changes are listed in the release notes (Appendix E); pay particular attention to the section + labeled "Migration". If you are upgrading across several major + versions, be sure to read the release notes for each intervening + version. +

Cautious users will want to test their client applications on the new + version before switching over fully; therefore, it's often a good idea to + set up concurrent installations of old and new versions. When + testing a PostgreSQL major upgrade, consider the + following categories of possible changes: +

Administration

The capabilities available for administrators to monitor and control + the server often change and improve in each major release. +

SQL

Typically this includes new SQL command capabilities and not changes + in behavior, unless specifically mentioned in the release notes. +

Library API

Typically libraries like libpq only add new + functionality, again unless mentioned in the release notes. +

System Catalogs

System catalog changes usually only affect database management tools. +

Server C-language API

This involves changes in the backend function API, which is written + in the C programming language. Such changes affect code that + references backend functions deep inside the server. +

17.6.1. Upgrading Data via pg_dump

To dump data from one major version of PostgreSQL and + reload it in another, you must use pg_dump; file system + level backup methods will not work. (There are checks in place that prevent + you from using a data directory with an incompatible version of + PostgreSQL, so no great harm can be done by + trying to start the wrong server version on a data directory.) +

It is recommended that you use the pg_dump and + pg_dumpall programs from the newer version of + PostgreSQL, to take advantage of enhancements + that might have been made in these programs. Current releases of the + dump programs can read data from any server version back to 7.0. +

These instructions assume that your existing installation is under the + /usr/local/pgsql directory, and that the data area is in + /usr/local/pgsql/data. Substitute your paths + appropriately. +

  1. If making a backup, make sure that your database is not being updated. + This does not affect the integrity of the backup, but the changed + data would of course not be included. If necessary, edit the + permissions in the file /usr/local/pgsql/data/pg_hba.conf + (or equivalent) to disallow access from everyone except you. + See Chapter 19 for additional information on + access control. +

    + + To back up your database installation, type: +

    pg_dumpall > outputfile

    + If you need to preserve OIDs (such as when using them as + foreign keys), then use the -o option when running + pg_dumpall. +

    To make the backup, you can use the pg_dumpall + command from the version you are currently running. For best + results, however, try to use the pg_dumpall + command from PostgreSQL 9.2.2, + since this version contains bug fixes and improvements over older + versions. While this advice might seem idiosyncratic since you + haven't installed the new version yet, it is advisable to follow + it if you plan to install the new version in parallel with the + old version. In that case you can complete the installation + normally and transfer the data later. This will also decrease + the downtime. +

  2. Shut down the old server: +

    pg_ctl stop

    + On systems that have PostgreSQL started at boot time, + there is probably a start-up file that will accomplish the same thing. For + example, on a Red Hat Linux system one + might find that this works: +

    /etc/rc.d/init.d/postgresql stop

    + See Chapter 17 for details about starting and + stopping the server. +

  3. If restoring from backup, rename or delete the old installation + directory. It is a good idea to rename the directory, rather than + delete it, in case you have trouble and need to revert to it. Keep + in mind the directory might consume significant disk space. To rename + the directory, use a command like this: +

    mv /usr/local/pgsql /usr/local/pgsql.old

    + (Be sure to move the directory as a single unit so relative paths + remain unchanged.) +

  4. Install the new version of PostgreSQL as + outlined in + Section 15.4. +

  5. Create a new database cluster if needed. Remember that you must + execute these commands while logged in to the special database user + account (which you already have if you are upgrading). +

    /usr/local/pgsql/bin/initdb -D /usr/local/pgsql/data

    +

  6. Restore your previous pg_hba.conf and any + postgresql.conf modifications. +

  7. Start the database server, again using the special database user + account: +

    /usr/local/pgsql/bin/postgres -D /usr/local/pgsql/data

    +

  8. Finally, restore your data from backup with: +

    /usr/local/pgsql/bin/psql -d postgres -f outputfile

    + using the new psql. +

The least downtime can be achieved by installing the new server in + a different directory and running both the old and the new servers + in parallel, on different ports. Then you can use something like: + +

pg_dumpall -p 5432 | psql -d postgres -p 5433

+ to transfer your data. +

17.6.2. Non-Dump Upgrade Methods

The pg_upgrade module allows an + installation to be migrated in-place from one major + PostgreSQL version to the next. Upgrades can be + performed in minutes. +

It is also possible to use certain replication methods, such as + Slony, to create a standby server with the updated version of + PostgreSQL. This is possible because Slony supports + replication between different major versions of + PostgreSQL. The standby can be on the same computer or + a different computer. Once it has synced up with the master server + (running the older version of PostgreSQL), you can + switch masters and make the standby the master and shut down the older + database instance. Such a switch-over results in only several seconds + of downtime for an upgrade. +


PrevHomeNext
Shutting Down the ServerUpPreventing Server Spoofing
\ No newline at end of file diff --git a/doc/src/sgml/html/user-manag.html b/doc/src/sgml/html/user-manag.html new file mode 100644 index 000000000..7582c76cf --- /dev/null +++ b/doc/src/sgml/html/user-manag.html @@ -0,0 +1,233 @@ + +Database Roles

Chapter 20. Database Roles

PostgreSQL manages database access permissions + using the concept of roles. A role can be thought of as + either a database user, or a group of database users, depending on how + the role is set up. Roles can own database objects (for example, + tables) and can assign privileges on those objects to other roles to + control who has access to which objects. Furthermore, it is possible + to grant membership in a role to another role, thus + allowing the member role to use privileges assigned to another role. +

The concept of roles subsumes the concepts of "users" and + "groups". In PostgreSQL versions + before 8.1, users and groups were distinct kinds of entities, but now + there are only roles. Any role can act as a user, a group, or both. +

This chapter describes how to create and manage roles. + More information about the effects of role privileges on various + database objects can be found in Section 5.6. +


PrevHomeNext
Authentication ProblemsUpDatabase Roles
\ No newline at end of file diff --git a/doc/src/sgml/html/using-explain.html b/doc/src/sgml/html/using-explain.html new file mode 100644 index 000000000..d4cd6bd56 --- /dev/null +++ b/doc/src/sgml/html/using-explain.html @@ -0,0 +1,1312 @@ + +Using EXPLAIN
PostgreSQL 9.2.2 Documentation
PrevUpChapter 14. Performance TipsNext

14.1. Using EXPLAIN

PostgreSQL devises a query + plan for each query it receives. Choosing the right + plan to match the query structure and the properties of the data + is absolutely critical for good performance, so the system includes + a complex planner that tries to choose good plans. + You can use the EXPLAIN command + to see what query plan the planner creates for any query. + Plan-reading is an art that requires some experience to master, + but this section attempts to cover the basics. +

Examples in this section are drawn from the regression test database + after doing a VACUUM ANALYZE, using 9.2 development sources. + You should be able to get similar results if you try the examples + yourself, but your estimated costs and row counts might vary slightly + because ANALYZE's statistics are random samples rather + than exact, and because costs are inherently somewhat platform-dependent. +

The examples use EXPLAIN's default "text" output + format, which is compact and convenient for humans to read. + If you want to feed EXPLAIN's output to a program for further + analysis, you should use one of its machine-readable output formats + (XML, JSON, or YAML) instead. +

14.1.1. EXPLAIN Basics

The structure of a query plan is a tree of plan nodes. + Nodes at the bottom level of the tree are scan nodes: they return raw rows + from a table. There are different types of scan nodes for different + table access methods: sequential scans, index scans, and bitmap index + scans. There are also non-table row sources, such as VALUES + clauses and set-returning functions in FROM, which have their + own scan node types. + If the query requires joining, aggregation, sorting, or other + operations on the raw rows, then there will be additional nodes + above the scan nodes to perform these operations. Again, + there is usually more than one possible way to do these operations, + so different node types can appear here too. The output + of EXPLAIN has one line for each node in the plan + tree, showing the basic node type plus the cost estimates that the planner + made for the execution of that plan node. Additional lines might appear, + indented from the node's summary line, + to show additional properties of the node. + The very first line (the summary line for the topmost + node) has the estimated total execution cost for the plan; it is this + number that the planner seeks to minimize. +

Here is a trivial example, just to show what the output looks like: + +

EXPLAIN SELECT * FROM tenk1;
+
+                         QUERY PLAN
+-------------------------------------------------------------
+ Seq Scan on tenk1  (cost=0.00..458.00 rows=10000 width=244)

+

Since this query has no WHERE clause, it must scan all the + rows of the table, so the planner has chosen to use a simple sequential + scan plan. The numbers that are quoted in parentheses are (left + to right): + +

  • Estimated start-up cost. This is the time expended before the output + phase can begin, e.g., time to do the sorting in a sort node. +

  • Estimated total cost. This is stated on the assumption that the plan + node is run to completion, i.e., all available rows are retrieved. + In practice a node's parent node might stop short of reading all + available rows (see the LIMIT example below). +

  • Estimated number of rows output by this plan node. Again, the node + is assumed to be run to completion. +

  • Estimated average width of rows output by this plan node (in bytes). +

+

The costs are measured in arbitrary units determined by the planner's + cost parameters (see Section 18.7.2). + Traditional practice is to measure the costs in units of disk page + fetches; that is, seq_page_cost is conventionally + set to 1.0 and the other cost parameters are set relative + to that. The examples in this section are run with the default cost + parameters. +

It's important to understand that the cost of an upper-level node includes + the cost of all its child nodes. It's also important to realize that + the cost only reflects things that the planner cares about. + In particular, the cost does not consider the time spent transmitting + result rows to the client, which could be an important + factor in the real elapsed time; but the planner ignores it because + it cannot change it by altering the plan. (Every correct plan will + output the same row set, we trust.) +

The rows value is a little tricky because it is + not the number of rows processed or scanned by the + plan node, but rather the number emitted by the node. This is often + less than the number scanned, as a result of filtering by any + WHERE-clause conditions that are being applied at the node. + Ideally the top-level rows estimate will approximate the number of rows + actually returned, updated, or deleted by the query. +

Returning to our example: + +

EXPLAIN SELECT * FROM tenk1;
+
+                         QUERY PLAN
+-------------------------------------------------------------
+ Seq Scan on tenk1  (cost=0.00..458.00 rows=10000 width=244)

+

These numbers are derived very straightforwardly. If you do: + +

SELECT relpages, reltuples FROM pg_class WHERE relname = 'tenk1';

+ + you will find that tenk1 has 358 disk + pages and 10000 rows. The estimated cost is computed as (disk pages read * + seq_page_cost) + (rows scanned * + cpu_tuple_cost). By default, + seq_page_cost is 1.0 and cpu_tuple_cost is 0.01, + so the estimated cost is (358 * 1.0) + (10000 * 0.01) = 458. +

Now let's modify the query to add a WHERE condition: + +

EXPLAIN SELECT * FROM tenk1 WHERE unique1 < 7000;
+
+                         QUERY PLAN
+------------------------------------------------------------
+ Seq Scan on tenk1  (cost=0.00..483.00 rows=7001 width=244)
+   Filter: (unique1 < 7000)

+ + Notice that the EXPLAIN output shows the WHERE + clause being applied as a "filter" condition attached to the Seq + Scan plan node. This means that + the plan node checks the condition for each row it scans, and outputs + only the ones that pass the condition. + The estimate of output rows has been reduced because of the + WHERE clause. + However, the scan will still have to visit all 10000 rows, so the cost + hasn't decreased; in fact it has gone up a bit (by 10000 * cpu_operator_cost, to be exact) to reflect the extra CPU + time spent checking the WHERE condition. +

The actual number of rows this query would select is 7000, but the rows + estimate is only approximate. If you try to duplicate this experiment, + you will probably get a slightly different estimate; moreover, it can + change after each ANALYZE command, because the + statistics produced by ANALYZE are taken from a + randomized sample of the table. +

Now, let's make the condition more restrictive: + +

EXPLAIN SELECT * FROM tenk1 WHERE unique1 < 100;
+
+                                  QUERY PLAN
+------------------------------------------------------------------------------
+ Bitmap Heap Scan on tenk1  (cost=5.03..229.17 rows=101 width=244)
+   Recheck Cond: (unique1 < 100)
+   ->  Bitmap Index Scan on tenk1_unique1  (cost=0.00..5.01 rows=101 width=0)
+         Index Cond: (unique1 < 100)

+ + Here the planner has decided to use a two-step plan: the child plan + node visits an index to find the locations of rows matching the index + condition, and then the upper plan node actually fetches those rows + from the table itself. Fetching rows separately is much more + expensive than reading them sequentially, but because not all the pages + of the table have to be visited, this is still cheaper than a sequential + scan. (The reason for using two plan levels is that the upper plan + node sorts the row locations identified by the index into physical order + before reading them, to minimize the cost of separate fetches. + The "bitmap" mentioned in the node names is the mechanism that + does the sorting.) +

Now let's add another condition to the WHERE clause: + +

EXPLAIN SELECT * FROM tenk1 WHERE unique1 < 100 AND stringu1 = 'xxx';
+
+                                  QUERY PLAN
+------------------------------------------------------------------------------
+ Bitmap Heap Scan on tenk1  (cost=5.01..229.40 rows=1 width=244)
+   Recheck Cond: (unique1 < 100)
+   Filter: (stringu1 = 'xxx'::name)
+   ->  Bitmap Index Scan on tenk1_unique1  (cost=0.00..5.01 rows=101 width=0)
+         Index Cond: (unique1 < 100)

+ + The added condition stringu1 = 'xxx' reduces the + output row count estimate, but not the cost because we still have to visit + the same set of rows. Notice that the stringu1 clause + cannot be applied as an index condition, since this index is only on + the unique1 column. Instead it is applied as a filter on + the rows retrieved by the index. Thus the cost has actually gone up + slightly to reflect this extra checking. +

In some cases the planner will prefer a "simple" index scan plan: + +

EXPLAIN SELECT * FROM tenk1 WHERE unique1 = 42;
+
+                                 QUERY PLAN
+-----------------------------------------------------------------------------
+ Index Scan using tenk1_unique1 on tenk1  (cost=0.00..8.27 rows=1 width=244)
+   Index Cond: (unique1 = 42)

+ + In this type of plan the table rows are fetched in index order, which + makes them even more expensive to read, but there are so few that the + extra cost of sorting the row locations is not worth it. You'll most + often see this plan type for queries that fetch just a single row. It's + also often used for queries that have an ORDER BY condition + that matches the index order, because then no extra sort step is needed to + satisfy the ORDER BY. +

If there are indexes on several columns referenced in WHERE, + the planner might choose to use an AND or OR combination of the indexes: + +

EXPLAIN SELECT * FROM tenk1 WHERE unique1 < 100 AND unique2 > 9000;
+
+                                     QUERY PLAN
+-------------------------------------------------------------------------------------
+ Bitmap Heap Scan on tenk1  (cost=25.01..60.14 rows=10 width=244)
+   Recheck Cond: ((unique1 < 100) AND (unique2 > 9000))
+   ->  BitmapAnd  (cost=25.01..25.01 rows=10 width=0)
+         ->  Bitmap Index Scan on tenk1_unique1  (cost=0.00..5.01 rows=101 width=0)
+               Index Cond: (unique1 < 100)
+         ->  Bitmap Index Scan on tenk1_unique2  (cost=0.00..19.74 rows=999 width=0)
+               Index Cond: (unique2 > 9000)

+ + But this requires visiting both indexes, so it's not necessarily a win + compared to using just one index and treating the other condition as + a filter. If you vary the ranges involved you'll see the plan change + accordingly. +

Here is an example showing the effects of LIMIT: + +

EXPLAIN SELECT * FROM tenk1 WHERE unique1 < 100 AND unique2 > 9000 LIMIT 2;
+
+                                     QUERY PLAN
+-------------------------------------------------------------------------------------
+ Limit  (cost=0.00..14.25 rows=2 width=244)
+   ->  Index Scan using tenk1_unique2 on tenk1  (cost=0.00..71.23 rows=10 width=244)
+         Index Cond: (unique2 > 9000)
+         Filter: (unique1 < 100)

+

This is the same query as above, but we added a LIMIT so that + not all the rows need be retrieved, and the planner changed its mind about + what to do. Notice that the total cost and row count of the Index Scan + node are shown as if it were run to completion. However, the Limit node + is expected to stop after retrieving only a fifth of those rows, so its + total cost is only a fifth as much, and that's the actual estimated cost + of the query. This plan is preferred over adding a Limit node to the + previous plan because the Limit could not avoid paying the startup cost + of the bitmap scan, so the total cost would be something over 25 units + with that approach. +

Let's try joining two tables, using the columns we have been discussing: + +

EXPLAIN SELECT *
+FROM tenk1 t1, tenk2 t2
+WHERE t1.unique1 < 10 AND t1.unique2 = t2.unique2;
+
+                                      QUERY PLAN
+--------------------------------------------------------------------------------------
+ Nested Loop  (cost=4.33..118.25 rows=10 width=488)
+   ->  Bitmap Heap Scan on tenk1 t1  (cost=4.33..39.44 rows=10 width=244)
+         Recheck Cond: (unique1 < 10)
+         ->  Bitmap Index Scan on tenk1_unique1  (cost=0.00..4.33 rows=10 width=0)
+               Index Cond: (unique1 < 10)
+   ->  Index Scan using tenk2_unique2 on tenk2 t2  (cost=0.00..7.87 rows=1 width=244)
+         Index Cond: (unique2 = t1.unique2)

+

In this plan, we have a nested-loop join node with two table scans as + inputs, or children. The indentation of the node summary lines reflects + the plan tree structure. The join's first, or "outer", child + is a bitmap scan similar to those we saw before. Its cost and row count + are the same as we'd get from SELECT ... WHERE unique1 < 10 + because we are + applying the WHERE clause unique1 < 10 + at that node. + The t1.unique2 = t2.unique2 clause is not relevant yet, + so it doesn't affect the row count of the outer scan. The nested-loop + join node will run its second, + or "inner" child once for each row obtained from the outer child. + Column values from the current outer row can be plugged into the inner + scan; here, the t1.unique2 value from the outer row is available, + so we get a plan and costs similar to what we saw above for a simple + SELECT ... WHERE t2.unique2 = constant case. + (The estimated cost is actually a bit lower than what was seen above, + as a result of caching that's expected to occur during the repeated + index scans on t2.) The + costs of the loop node are then set on the basis of the cost of the outer + scan, plus one repetition of the inner scan for each outer row (10 * 7.87, + here), plus a little CPU time for join processing. +

In this example the join's output row count is the same as the product + of the two scans' row counts, but that's not true in all cases because + there can be additional WHERE clauses that mention both tables + and so can only be applied at the join point, not to either input scan. + For example, if we add one more condition: + +

EXPLAIN SELECT *
+FROM tenk1 t1, tenk2 t2
+WHERE t1.unique1 < 10 AND t1.unique2 = t2.unique2 AND t1.hundred < t2.hundred;
+
+                                      QUERY PLAN
+--------------------------------------------------------------------------------------
+ Nested Loop  (cost=4.33..118.28 rows=3 width=488)
+   Join Filter: (t1.hundred < t2.hundred)
+   ->  Bitmap Heap Scan on tenk1 t1  (cost=4.33..39.44 rows=10 width=244)
+         Recheck Cond: (unique1 < 10)
+         ->  Bitmap Index Scan on tenk1_unique1  (cost=0.00..4.33 rows=10 width=0)
+               Index Cond: (unique1 < 10)
+   ->  Index Scan using tenk2_unique2 on tenk2 t2  (cost=0.00..7.87 rows=1 width=244)
+         Index Cond: (unique2 = t1.unique2)

+ + The extra condition t1.hundred < t2.hundred can't be + tested in the tenk2_unique2 index, so it's applied at the + join node. This reduces the estimated output row count of the join node, + but does not change either input scan. +

When dealing with outer joins, you might see join plan nodes with both + "Join Filter" and plain "Filter" conditions attached. + Join Filter conditions come from the outer join's ON clause, + so a row that fails the Join Filter condition could still get emitted as + a null-extended row. But a plain Filter condition is applied after the + outer-join rules and so acts to remove rows unconditionally. In an inner + join there is no semantic difference between these types of filters. +

If we change the query's selectivity a bit, we might get a very different + join plan: + +

EXPLAIN SELECT *
+FROM tenk1 t1, tenk2 t2
+WHERE t1.unique1 < 100 AND t1.unique2 = t2.unique2;
+
+                                        QUERY PLAN
+------------------------------------------------------------------------------------------
+ Hash Join  (cost=230.43..713.94 rows=101 width=488)
+   Hash Cond: (t2.unique2 = t1.unique2)
+   ->  Seq Scan on tenk2 t2  (cost=0.00..445.00 rows=10000 width=244)
+   ->  Hash  (cost=229.17..229.17 rows=101 width=244)
+         ->  Bitmap Heap Scan on tenk1 t1  (cost=5.03..229.17 rows=101 width=244)
+               Recheck Cond: (unique1 < 100)
+               ->  Bitmap Index Scan on tenk1_unique1  (cost=0.00..5.01 rows=101 width=0)
+                     Index Cond: (unique1 < 100)

+

Here, the planner has chosen to use a hash join, in which rows of one + table are entered into an in-memory hash table, after which the other + table is scanned and the hash table is probed for matches to each row. + Again note how the indentation reflects the plan structure: the bitmap + scan on tenk1 is the input to the Hash node, which constructs + the hash table. That's then returned to the Hash Join node, which reads + rows from its outer child plan and searches the hash table for each one. +

Another possible type of join is a merge join, illustrated here: + +

EXPLAIN SELECT *
+FROM tenk1 t1, onek t2
+WHERE t1.unique1 < 100 AND t1.unique2 = t2.unique2;
+
+                                        QUERY PLAN
+------------------------------------------------------------------------------------------
+ Merge Join  (cost=197.83..267.93 rows=10 width=488)
+   Merge Cond: (t1.unique2 = t2.unique2)
+   ->  Index Scan using tenk1_unique2 on tenk1 t1  (cost=0.00..656.25 rows=101 width=244)
+         Filter: (unique1 < 100)
+   ->  Sort  (cost=197.83..200.33 rows=1000 width=244)
+         Sort Key: t2.unique2
+         ->  Seq Scan on onek t2  (cost=0.00..148.00 rows=1000 width=244)

+

Merge join requires its input data to be sorted on the join keys. In this + plan the tenk1 data is sorted by using an index scan to visit + the rows in the correct order, but a sequential scan and sort is preferred + for onek, because there are many more rows to be visited in + that table. + (Sequential-scan-and-sort frequently beats an index scan for sorting many rows, + because of the nonsequential disk access required by the index scan.) +

One way to look at variant plans is to force the planner to disregard + whatever strategy it thought was the cheapest, using the enable/disable + flags described in Section 18.7.1. + (This is a crude tool, but useful. See + also Section 14.3.) + For example, if we're unconvinced that sequential-scan-and-sort is the best way to + deal with table onek in the previous example, we could try + +

SET enable_sort = off;
+
+EXPLAIN SELECT *
+FROM tenk1 t1, onek t2
+WHERE t1.unique1 < 100 AND t1.unique2 = t2.unique2;
+
+                                        QUERY PLAN
+------------------------------------------------------------------------------------------
+ Merge Join  (cost=0.00..292.36 rows=10 width=488)
+   Merge Cond: (t1.unique2 = t2.unique2)
+   ->  Index Scan using tenk1_unique2 on tenk1 t1  (cost=0.00..656.25 rows=101 width=244)
+         Filter: (unique1 < 100)
+   ->  Index Scan using onek_unique2 on onek t2  (cost=0.00..224.76 rows=1000 width=244)

+ + which shows that the planner thinks that sorting onek by + index-scanning is about 12% more expensive than sequential-scan-and-sort. + Of course, the next question is whether it's right about that. + We can investigate that using EXPLAIN ANALYZE, as discussed + below. +

14.1.2. EXPLAIN ANALYZE

It is possible to check the accuracy of the planner's estimates + by using EXPLAIN's ANALYZE option. With this + option, EXPLAIN actually executes the query, and then displays + the true row counts and true run time accumulated within each plan node, + along with the same estimates that a plain EXPLAIN + shows. For example, we might get a result like this: + +

EXPLAIN ANALYZE SELECT *
+FROM tenk1 t1, tenk2 t2
+WHERE t1.unique1 < 10 AND t1.unique2 = t2.unique2;
+
+                                                           QUERY PLAN
+---------------------------------------------------------------------------------------------------------------------------------
+ Nested Loop  (cost=4.33..118.25 rows=10 width=488) (actual time=0.370..1.126 rows=10 loops=1)
+   ->  Bitmap Heap Scan on tenk1 t1  (cost=4.33..39.44 rows=10 width=244) (actual time=0.254..0.380 rows=10 loops=1)
+         Recheck Cond: (unique1 < 10)
+         ->  Bitmap Index Scan on tenk1_unique1  (cost=0.00..4.33 rows=10 width=0) (actual time=0.164..0.164 rows=10 loops=1)
+               Index Cond: (unique1 < 10)
+   ->  Index Scan using tenk2_unique2 on tenk2 t2  (cost=0.00..7.87 rows=1 width=244) (actual time=0.041..0.048 rows=1 loops=10)
+         Index Cond: (unique2 = t1.unique2)
+ Total runtime: 2.414 ms

+ + Note that the "actual time" values are in milliseconds of + real time, whereas the cost estimates are expressed in + arbitrary units; so they are unlikely to match up. + The thing that's usually most important to look for is whether the + estimated row counts are reasonably close to reality. In this example + the estimates were all dead-on, but that's quite unusual in practice. +

In some query plans, it is possible for a subplan node to be executed more + than once. For example, the inner index scan will be executed once per + outer row in the above nested-loop plan. In such cases, the + loops value reports the + total number of executions of the node, and the actual time and rows + values shown are averages per-execution. This is done to make the numbers + comparable with the way that the cost estimates are shown. Multiply by + the loops value to get the total time actually spent in + the node. In the above example, we spent a total of 0.480 milliseconds + executing the index scans on tenk2. +

In some cases EXPLAIN ANALYZE shows additional execution + statistics beyond the plan node execution times and row counts. + For example, Sort and Hash nodes provide extra information: + +

EXPLAIN ANALYZE SELECT *
+FROM tenk1 t1, tenk2 t2
+WHERE t1.unique1 < 100 AND t1.unique2 = t2.unique2 ORDER BY t1.fivethous;
+
+                                                                 QUERY PLAN
+--------------------------------------------------------------------------------------------------------------------------------------------
+ Sort  (cost=717.30..717.56 rows=101 width=488) (actual time=104.950..105.327 rows=100 loops=1)
+   Sort Key: t1.fivethous
+   Sort Method: quicksort  Memory: 68kB
+   ->  Hash Join  (cost=230.43..713.94 rows=101 width=488) (actual time=3.680..102.396 rows=100 loops=1)
+         Hash Cond: (t2.unique2 = t1.unique2)
+         ->  Seq Scan on tenk2 t2  (cost=0.00..445.00 rows=10000 width=244) (actual time=0.046..46.219 rows=10000 loops=1)
+         ->  Hash  (cost=229.17..229.17 rows=101 width=244) (actual time=3.184..3.184 rows=100 loops=1)
+               Buckets: 1024  Batches: 1  Memory Usage: 27kB
+               ->  Bitmap Heap Scan on tenk1 t1  (cost=5.03..229.17 rows=101 width=244) (actual time=0.612..1.959 rows=100 loops=1)
+                     Recheck Cond: (unique1 < 100)
+                     ->  Bitmap Index Scan on tenk1_unique1  (cost=0.00..5.01 rows=101 width=0) (actual time=0.390..0.390 rows=100 loops=1)
+                           Index Cond: (unique1 < 100)
+ Total runtime: 107.392 ms

+ + The Sort node shows the sort method used (in particular, whether the sort + was in-memory or on-disk) and the amount of memory or disk space needed. + The Hash node shows the number of hash buckets and batches as well as the + peak amount of memory used for the hash table. (If the number of batches + exceeds one, there will also be disk space usage involved, but that is not + shown.) +

Another type of extra information is the number of rows removed by a + filter condition: + +

EXPLAIN ANALYZE SELECT * FROM tenk1 WHERE ten < 7;
+
+                                                QUERY PLAN
+----------------------------------------------------------------------------------------------------------
+ Seq Scan on tenk1  (cost=0.00..483.00 rows=7000 width=244) (actual time=0.111..59.249 rows=7000 loops=1)
+   Filter: (ten < 7)
+   Rows Removed by Filter: 3000
+ Total runtime: 85.340 ms

+ + These counts can be particularly valuable for filter conditions applied at + join nodes. The "Rows Removed" line only appears when at least + one scanned row, or potential join pair in the case of a join node, + is rejected by the filter condition. +

A case similar to filter conditions occurs with "lossy" + index scans. For example, consider this search for polygons containing a + specific point: + +

EXPLAIN ANALYZE SELECT * FROM polygon_tbl WHERE f1 @> polygon '(0.5,2.0)';
+
+                                              QUERY PLAN
+------------------------------------------------------------------------------------------------------
+ Seq Scan on polygon_tbl  (cost=0.00..1.05 rows=1 width=32) (actual time=0.251..0.251 rows=0 loops=1)
+   Filter: (f1 @> '((0.5,2))'::polygon)
+   Rows Removed by Filter: 4
+ Total runtime: 0.517 ms

+ + The planner thinks (quite correctly) that this sample table is too small + to bother with an index scan, so we have a plain sequential scan in which + all the rows got rejected by the filter condition. But if we force an + index scan to be used, we see: + +

SET enable_seqscan TO off;
+
+EXPLAIN ANALYZE SELECT * FROM polygon_tbl WHERE f1 @> polygon '(0.5,2.0)';
+
+                                                        QUERY PLAN
+--------------------------------------------------------------------------------------------------------------------------
+ Index Scan using gpolygonind on polygon_tbl  (cost=0.00..8.27 rows=1 width=32) (actual time=0.293..0.293 rows=0 loops=1)
+   Index Cond: (f1 @> '((0.5,2))'::polygon)
+   Rows Removed by Index Recheck: 1
+ Total runtime: 1.054 ms

+ + Here we can see that the index returned one candidate row, which was + then rejected by a recheck of the index condition. This happens because a + GiST index is "lossy" for polygon containment tests: it actually + returns the rows with polygons that overlap the target, and then we have + to do the exact containment test on those rows. +

EXPLAIN has a BUFFERS option that can be used with + ANALYZE to get even more runtime statistics: + +

EXPLAIN (ANALYZE, BUFFERS) SELECT * FROM tenk1 WHERE unique1 < 100 AND unique2 > 9000;
+
+                                                            QUERY PLAN
+-----------------------------------------------------------------------------------------------------------------------------------
+ Bitmap Heap Scan on tenk1  (cost=25.07..60.23 rows=10 width=244) (actual time=3.069..3.213 rows=10 loops=1)
+   Recheck Cond: ((unique1 < 100) AND (unique2 > 9000))
+   Buffers: shared hit=16
+   ->  BitmapAnd  (cost=25.07..25.07 rows=10 width=0) (actual time=2.967..2.967 rows=0 loops=1)
+         Buffers: shared hit=7
+         ->  Bitmap Index Scan on tenk1_unique1  (cost=0.00..5.02 rows=102 width=0) (actual time=0.732..0.732 rows=200 loops=1)
+               Index Cond: (unique1 < 100)
+               Buffers: shared hit=2
+         ->  Bitmap Index Scan on tenk1_unique2  (cost=0.00..19.80 rows=1007 width=0) (actual time=2.015..2.015 rows=1009 loops=1)
+               Index Cond: (unique2 > 9000)
+               Buffers: shared hit=5
+ Total runtime: 3.917 ms

+ + The numbers provided by BUFFERS help to identify which parts + of the query are the most I/O-intensive. +

Keep in mind that because EXPLAIN ANALYZE actually + runs the query, any side-effects will happen as usual, even though + whatever results the query might output are discarded in favor of + printing the EXPLAIN data. If you want to analyze a + data-modifying query without changing your tables, you can + roll the command back afterwards, for example: + +

BEGIN;
+
+EXPLAIN ANALYZE UPDATE tenk1 SET hundred = hundred + 1 WHERE unique1 < 100;
+
+                                                           QUERY PLAN
+--------------------------------------------------------------------------------------------------------------------------------
+ Update on tenk1  (cost=5.03..229.42 rows=101 width=250) (actual time=81.055..81.055 rows=0 loops=1)
+   ->  Bitmap Heap Scan on tenk1  (cost=5.03..229.42 rows=101 width=250) (actual time=0.766..3.396 rows=100 loops=1)
+         Recheck Cond: (unique1 < 100)
+         ->  Bitmap Index Scan on tenk1_unique1  (cost=0.00..5.01 rows=101 width=0) (actual time=0.461..0.461 rows=100 loops=1)
+               Index Cond: (unique1 < 100)
+ Total runtime: 81.922 ms
+
+ROLLBACK;

+

As seen in this example, when the query is an INSERT, + UPDATE, or DELETE command, the actual work of + applying the table changes is done by a top-level Insert, Update, + or Delete plan node. The plan nodes underneath this node perform + the work of locating the old rows and/or computing the new data. + So above, we see the same sort of bitmap table scan we've seen already, + and its output is fed to an Update node that stores the updated rows. + It's worth noting that although the data-modifying node can take a + considerable amount of runtime (here, it's consuming the lion's share + of the time), the planner does not currently add anything to the cost + estimates to account for that work. That's because the work to be done is + the same for every correct query plan, so it doesn't affect planning + decisions. +

The Total runtime shown by EXPLAIN + ANALYZE includes executor start-up and shut-down time, as well + as the time to run any triggers that are fired, but it does not include + parsing, rewriting, or planning time. + Time spent executing BEFORE triggers, if any, is included in + the time for the related Insert, Update, or Delete node; but time + spent executing AFTER triggers is not counted there because + AFTER triggers are fired after completion of the whole plan. + The total time spent in each trigger + (either BEFORE or AFTER) is also shown separately. + Note that deferred constraint triggers will not be executed + until end of transaction and are thus not shown at all by + EXPLAIN ANALYZE. +

14.1.3. Caveats

There are two significant ways in which run times measured by + EXPLAIN ANALYZE can deviate from normal execution of + the same query. First, since no output rows are delivered to the client, + network transmission costs and I/O conversion costs are not included. + Second, the measurement overhead added by EXPLAIN + ANALYZE can be significant, especially on machines with slow + gettimeofday() operating-system calls. You can use the + pg_test_timing tool to measure the overhead of timing + on your system. +

EXPLAIN results should not be extrapolated to situations + much different from the one you are actually testing; for example, + results on a toy-sized table cannot be assumed to apply to large tables. + The planner's cost estimates are not linear and so it might choose + a different plan for a larger or smaller table. An extreme example + is that on a table that only occupies one disk page, you'll nearly + always get a sequential scan plan whether indexes are available or not. + The planner realizes that it's going to take one disk page read to + process the table in any case, so there's no value in expending additional + page reads to look at an index. (We saw this happening in the + polygon_tbl example above.) +

There are cases in which the actual and estimated values won't match up + well, but nothing is really wrong. One such case occurs when + plan node execution is stopped short by a LIMIT or similar + effect. For example, in the LIMIT query we used before, + +

EXPLAIN ANALYZE SELECT * FROM tenk1 WHERE unique1 < 100 AND unique2 > 9000 LIMIT 2;
+
+                                                          QUERY PLAN
+-------------------------------------------------------------------------------------------------------------------------------
+ Limit  (cost=0.00..14.25 rows=2 width=244) (actual time=1.652..2.293 rows=2 loops=1)
+   ->  Index Scan using tenk1_unique2 on tenk1  (cost=0.00..71.23 rows=10 width=244) (actual time=1.631..2.259 rows=2 loops=1)
+         Index Cond: (unique2 > 9000)
+         Filter: (unique1 < 100)
+         Rows Removed by Filter: 287
+ Total runtime: 2.857 ms

+ + the estimated cost and row count for the Index Scan node are shown as + though it were run to completion. But in reality the Limit node stopped + requesting rows after it got two, so the actual row count is only 2 and + the runtime is less than the cost estimate would suggest. This is not + an estimation error, only a discrepancy in the way the estimates and true + values are displayed. +

Merge joins also have measurement artifacts that can confuse the unwary. + A merge join will stop reading one input if it's exhausted the other input + and the next key value in the one input is greater than the last key value + of the other input; in such a case there can be no more matches and so no + need to scan the rest of the first input. This results in not reading all + of one child, with results like those mentioned for LIMIT. + Also, if the outer (first) child contains rows with duplicate key values, + the inner (second) child is backed up and rescanned for the portion of its + rows matching that key value. EXPLAIN ANALYZE counts these + repeated emissions of the same inner rows as if they were real additional + rows. When there are many outer duplicates, the reported actual row count + for the inner child plan node can be significantly larger than the number + of rows that are actually in the inner relation. +

BitmapAnd and BitmapOr nodes always report their actual row counts as zero, + due to implementation limitations. +


PrevHomeNext
Performance TipsUpStatistics Used by the Planner
\ No newline at end of file diff --git a/doc/src/sgml/html/uuid-ossp.html b/doc/src/sgml/html/uuid-ossp.html new file mode 100644 index 000000000..7e8fcc35b --- /dev/null +++ b/doc/src/sgml/html/uuid-ossp.html @@ -0,0 +1,434 @@ + +uuid-ossp
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.40. uuid-ossp

The uuid-ossp module provides functions to generate universally + unique identifiers (UUIDs) using one of several standard algorithms. There + are also functions to produce certain special UUID constants. +

This module depends on the OSSP UUID library, which can be found at + http://www.ossp.org/pkg/lib/uuid/. +

F.40.1. uuid-ossp Functions

Table F-30 shows the functions available to + generate UUIDs. + The relevant standards ITU-T Rec. X.667, ISO/IEC 9834-8:2005, and RFC + 4122 specify four algorithms for generating UUIDs, identified by the + version numbers 1, 3, 4, and 5. (There is no version 2 algorithm.) + Each of these algorithms could be suitable for a different set of + applications. +

Table F-30. Functions for UUID Generation

FunctionDescription
uuid_generate_v1()

This function generates a version 1 UUID. This involves the MAC + address of the computer and a time stamp. Note that UUIDs of this + kind reveal the identity of the computer that created the identifier + and the time at which it did so, which might make it unsuitable for + certain security-sensitive applications. +

+
uuid_generate_v1mc()

This function generates a version 1 UUID but uses a random multicast + MAC address instead of the real MAC address of the computer. +

+
uuid_generate_v3(namespace uuid, name text)

This function generates a version 3 UUID in the given namespace using + the specified input name. The namespace should be one of the special + constants produced by the uuid_ns_*() functions shown + in Table F-31. (It could be any UUID in theory.) The name is an identifier + in the selected namespace. +

+ +

For example: + +

SELECT uuid_generate_v3(uuid_ns_url(), 'http://www.postgresql.org');

+ + The name parameter will be MD5-hashed, so the cleartext cannot be + derived from the generated UUID. + The generation of UUIDs by this method has no random or + environment-dependent element and is therefore reproducible. +

+
uuid_generate_v4()

This function generates a version 4 UUID, which is derived entirely + from random numbers. +

+
uuid_generate_v5(namespace uuid, name text)

This function generates a version 5 UUID, which works like a version 3 + UUID except that SHA-1 is used as a hashing method. Version 5 should + be preferred over version 3 because SHA-1 is thought to be more secure + than MD5. +

+

Table F-31. Functions Returning UUID Constants

uuid_nil()

A "nil" UUID constant, which does not occur as a real UUID. +

+
uuid_ns_dns()

Constant designating the DNS namespace for UUIDs. +

+
uuid_ns_url()

Constant designating the URL namespace for UUIDs. +

+
uuid_ns_oid()

Constant designating the ISO object identifier (OID) namespace for + UUIDs. (This pertains to ASN.1 OIDs, which are unrelated to the OIDs + used in PostgreSQL.) +

+
uuid_ns_x500()

Constant designating the X.500 distinguished name (DN) namespace for + UUIDs. +

+

F.40.2. Author

Peter Eisentraut <peter_e@gmx.net> +


PrevHomeNext
unaccentUpxml2
\ No newline at end of file diff --git a/doc/src/sgml/html/vacuumlo.html b/doc/src/sgml/html/vacuumlo.html new file mode 100644 index 000000000..fb8f5e7a5 --- /dev/null +++ b/doc/src/sgml/html/vacuumlo.html @@ -0,0 +1,505 @@ + +vacuumlo

vacuumlo

Name

vacuumlo -- remove orphaned large objects from a PostgreSQL database

Synopsis

vacuumlo [option...] dbname...

Description

vacuumlo is a simple utility program that will remove any + "orphaned" large objects from a + PostgreSQL database. An orphaned large object (LO) is + considered to be any LO whose OID does not appear in any oid or + lo data column of the database. +

If you use this, you may also be interested in the lo_manage + trigger in the lo module. + lo_manage is useful to try + to avoid creating orphaned LOs in the first place. +

All databases named on the command line are processed. +

Options

vacuumlo accepts the following command-line arguments: + +

-l limit

Remove no more than limit large objects per + transaction (default 1000). Since the server acquires a lock per LO + removed, removing too many LOs in one transaction risks exceeding + max_locks_per_transaction. Set the limit to + zero if you want all removals done in a single transaction. +

-n

Don't remove anything, just show what would be done.

-v

Write a lot of progress messages.

-V
--version

Print the vacuumlo version and exit. +

-?
--help

Show help about vacuumlo command line + arguments, and exit. +

+

vacuumlo also accepts the following command-line + arguments for connection parameters: + +

-h hostname

Database server's host.

-p port

Database server's port.

-U username

User name to connect as.

-w
--no-password

Never issue a password prompt. If the server requires password + authentication and a password is not available by other means + such as a .pgpass file, the connection + attempt will fail. This option can be useful in batch jobs and + scripts where no user is present to enter a password. +

-W

Force vacuumlo to prompt for a + password before connecting to a database. +

This option is never essential, since + vacuumlo will automatically prompt + for a password if the server demands password authentication. + However, vacuumlo will waste a + connection attempt finding out that the server wants a password. + In some cases it is worth typing -W to avoid the extra + connection attempt. +

+

Notes

vacuumlo works by the following method: + First, vacuumlo builds a temporary table which contains all + of the OIDs of the large objects in the selected database. It then scans + through all columns in the database that are of type + oid or lo, and removes matching entries from the temporary + table. (Note: Only types with these names are considered; in particular, + domains over them are not considered.) The remaining entries in the + temporary table identify orphaned LOs. These are removed. +

Author

Peter Mount <peter@retep.org.uk> +


PrevHomeNext
pgbenchUpServer Applications
\ No newline at end of file diff --git a/doc/src/sgml/html/view-pg-available-extension-versions.html b/doc/src/sgml/html/view-pg-available-extension-versions.html new file mode 100644 index 000000000..b343ccd5b --- /dev/null +++ b/doc/src/sgml/html/view-pg-available-extension-versions.html @@ -0,0 +1,344 @@ + +pg_available_extension_versions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.54. pg_available_extension_versions

The pg_available_extension_versions view lists the + specific extension versions that are available for installation. + See also the pg_extension + catalog, which shows the extensions currently installed. +

Table 45-55. pg_available_extension_versions Columns

NameTypeDescription
namenameExtension name
versiontextVersion name
installedboolTrue if this version of this extension is currently + installed
superuserboolTrue if only superusers are allowed to install this extension
relocatableboolTrue if extension can be relocated to another schema
schemanameName of the schema that the extension must be installed into, + or NULL if partially or fully relocatable
requiresname[]Names of prerequisite extensions, + or NULL if none
commenttextComment string from the extension's control file

The pg_available_extension_versions view is read + only. +


PrevHomeNext
pg_available_extensionsUppg_cursors
\ No newline at end of file diff --git a/doc/src/sgml/html/view-pg-available-extensions.html b/doc/src/sgml/html/view-pg-available-extensions.html new file mode 100644 index 000000000..c753ee1a3 --- /dev/null +++ b/doc/src/sgml/html/view-pg-available-extensions.html @@ -0,0 +1,284 @@ + +pg_available_extensions
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.53. pg_available_extensions

The pg_available_extensions view lists the + extensions that are available for installation. + See also the + pg_extension + catalog, which shows the extensions currently installed. +

Table 45-54. pg_available_extensions Columns

NameTypeDescription
namenameExtension name
default_versiontextName of default version, or NULL if none is + specified
installed_versiontextCurrently installed version of the extension, + or NULL if not installed
commenttextComment string from the extension's control file

The pg_available_extensions view is read only. +


PrevHomeNext
System ViewsUppg_available_extension_versions
\ No newline at end of file diff --git a/doc/src/sgml/html/view-pg-cursors.html b/doc/src/sgml/html/view-pg-cursors.html new file mode 100644 index 000000000..77c734914 --- /dev/null +++ b/doc/src/sgml/html/view-pg-cursors.html @@ -0,0 +1,395 @@ + +pg_cursors
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.55. pg_cursors

The pg_cursors view lists the cursors that + are currently available. Cursors can be defined in several ways: +

  • via the DECLARE + statement in SQL +

  • via the Bind message in the frontend/backend protocol, as + described in Section 46.2.3 +

  • via the Server Programming Interface (SPI), as described in + Section 43.1 +

+ + The pg_cursors view displays cursors + created by any of these means. Cursors only exist for the duration + of the transaction that defines them, unless they have been + declared WITH HOLD. Therefore non-holdable + cursors are only present in the view until the end of their + creating transaction. + +

Note: Cursors are used internally to implement some of the components + of PostgreSQL, such as procedural languages. + Therefore, the pg_cursors view might include cursors + that have not been explicitly created by the user. +

+

Table 45-56. pg_cursors Columns

NameTypeDescription
nametextThe name of the cursor
statementtextThe verbatim query string submitted to declare this cursor
is_holdableboolean true if the cursor is holdable (that is, it + can be accessed after the transaction that declared the cursor + has committed); false otherwise +
is_binaryboolean true if the cursor was declared + BINARY; false + otherwise +
is_scrollableboolean true if the cursor is scrollable (that is, it + allows rows to be retrieved in a nonsequential manner); + false otherwise +
creation_timetimestamptzThe time at which the cursor was declared

The pg_cursors view is read only. +


PrevHomeNext
pg_available_extension_versionsUppg_group
\ No newline at end of file diff --git a/doc/src/sgml/html/view-pg-group.html b/doc/src/sgml/html/view-pg-group.html new file mode 100644 index 000000000..f5b9b6c2b --- /dev/null +++ b/doc/src/sgml/html/view-pg-group.html @@ -0,0 +1,295 @@ + +pg_group
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.56. pg_group

The view pg_group exists for backwards + compatibility: it emulates a catalog that existed in + PostgreSQL before version 8.1. + It shows the names and members of all roles that are marked as not + rolcanlogin, which is an approximation to the set + of roles that are being used as groups. +

Table 45-57. pg_group Columns

NameTypeReferencesDescription
gronamenamepg_authid.rolnameName of the group
grosysidoidpg_authid.oidID of this group
grolistoid[]pg_authid.oidAn array containing the IDs of the roles in this group

PrevHomeNext
pg_cursorsUppg_indexes
\ No newline at end of file diff --git a/doc/src/sgml/html/view-pg-indexes.html b/doc/src/sgml/html/view-pg-indexes.html new file mode 100644 index 000000000..d0ec282e8 --- /dev/null +++ b/doc/src/sgml/html/view-pg-indexes.html @@ -0,0 +1,330 @@ + +pg_indexes
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.57. pg_indexes

The view pg_indexes provides access to + useful information about each index in the database. +

Table 45-58. pg_indexes Columns

NameTypeReferencesDescription
schemanamenamepg_namespace.nspnameName of schema containing table and index
tablenamenamepg_class.relnameName of table the index is for
indexnamenamepg_class.relnameName of index
tablespacenamepg_tablespace.spcnameName of tablespace containing index (null if default for database)
indexdeftext Index definition (a reconstructed CREATE INDEX + command)

PrevHomeNext
pg_groupUppg_locks
\ No newline at end of file diff --git a/doc/src/sgml/html/view-pg-locks.html b/doc/src/sgml/html/view-pg-locks.html new file mode 100644 index 000000000..28be25858 --- /dev/null +++ b/doc/src/sgml/html/view-pg-locks.html @@ -0,0 +1,755 @@ + +pg_locks
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.58. pg_locks

The view pg_locks provides access to + information about the locks held by open transactions within the + database server. See Chapter 13 for more discussion + of locking. +

pg_locks contains one row per active lockable + object, requested lock mode, and relevant transaction. Thus, the same + lockable object might + appear many times, if multiple transactions are holding or waiting + for locks on it. However, an object that currently has no locks on it + will not appear at all. +

There are several distinct types of lockable objects: + whole relations (e.g., tables), individual pages of relations, + individual tuples of relations, + transaction IDs (both virtual and permanent IDs), + and general database objects (identified by class OID and object OID, + in the same way as in pg_description or + pg_depend). Also, the right to extend a + relation is represented as a separate lockable object. + Also, "advisory" locks can be taken on numbers that have + user-defined meanings. +

Table 45-59. pg_locks Columns

NameTypeReferencesDescription
locktypetext  Type of the lockable object: + relation, + extend, + page, + tuple, + transactionid, + virtualxid, + object, + userlock, or + advisory +
databaseoidpg_database.oid OID of the database in which the lock target exists, or + zero if the target is a shared object, or + null if the target is a transaction ID +
relationoidpg_class.oid OID of the relation targeted by the lock, or null if the target is not + a relation or part of a relation +
pageinteger  Page number targeted by the lock within the relation, + or null if the target is not a relation page or tuple +
tuplesmallint  Tuple number targeted by the lock within the page, + or null if the target is not a tuple +
virtualxidtext  Virtual ID of the transaction targeted by the lock, + or null if the target is not a virtual transaction ID +
transactionidxid  ID of the transaction targeted by the lock, + or null if the target is not a transaction ID +
classidoidpg_class.oid OID of the system catalog containing the lock target, or null if the + target is not a general database object +
objidoidany OID column OID of the lock target within its system catalog, or null if the + target is not a general database object +
objsubidsmallint  Column number targeted by the lock (the + classid and objid refer to the + table itself), + or zero if the target is some other general database object, + or null if the target is not a general database object +
virtualtransactiontext  Virtual ID of the transaction that is holding or awaiting this lock +
pidinteger  Process ID of the server process holding or awaiting this + lock, or null if the lock is held by a prepared transaction +
modetext Name of the lock mode held or desired by this process (see Section 13.3.1 and Section 13.2.3)
grantedboolean True if lock is held, false if lock is awaited
fastpathboolean True if lock was taken via fast path, false if taken via main + lock table

granted is true in a row representing a lock + held by the indicated transaction. False indicates that this transaction is + currently waiting to acquire this lock, which implies that some other + transaction is holding a conflicting lock mode on the same lockable object. + The waiting transaction will sleep until the other lock is released (or a + deadlock situation is detected). A single transaction can be waiting to + acquire at most one lock at a time. +

Every transaction holds an exclusive lock on its virtual transaction ID for + its entire duration. If a permanent ID is assigned to the transaction + (which normally happens only if the transaction changes the state of the + database), it also holds an exclusive lock on its permanent transaction ID + until it ends. When one transaction finds it necessary to wait specifically + for another transaction, it does so by attempting to acquire share lock on + the other transaction ID (either virtual or permanent ID depending on the + situation). That will succeed only when the other transaction + terminates and releases its locks. +

Although tuples are a lockable type of object, + information about row-level locks is stored on disk, not in memory, + and therefore row-level locks normally do not appear in this view. + If a transaction is waiting for a + row-level lock, it will usually appear in the view as waiting for the + permanent transaction ID of the current holder of that row lock. +

Advisory locks can be acquired on keys consisting of either a single + bigint value or two integer values. + A bigint key is displayed with its + high-order half in the classid column, its low-order half + in the objid column, and objsubid equal + to 1. Integer keys are displayed with the first key in the + classid column, the second key in the objid + column, and objsubid equal to 2. The actual meaning of + the keys is up to the user. Advisory locks are local to each database, + so the database column is meaningful for an advisory lock. +

pg_locks provides a global view of all locks + in the database cluster, not only those relevant to the current database. + Although its relation column can be joined + against pg_class.oid to identify locked + relations, this will only work correctly for relations in the current + database (those for which the database column + is either the current database's OID or zero). +

The pid column can be joined to the + pid column of the + pg_stat_activity view to get more + information on the session holding or waiting to hold each lock. + Also, if you are using prepared transactions, the + transaction column can be joined to the + transaction column of the + pg_prepared_xacts view to get more + information on prepared transactions that hold locks. + (A prepared transaction can never be waiting for a lock, + but it continues to hold the locks it acquired while running.) +

The pg_locks view displays data from both the + regular lock manager and the predicate lock manager, which are + separate systems; in addition, the regular lock manager subdivides its + locks into regular and fast-path locks. + This data is not guaranteed to be entirely consistent. + When the view is queried, + data on fast-path locks (with fastpath = true) + is gathered from each backend one at a time, without freezing the state of + the entire lock manager, so it is possible for locks to be taken or + released while information is gathered. Note, however, that these locks are + known not to conflict with any other lock currently in place. After + all backends have been queried for fast-path locks, the remainder of the + regular lock manager is locked as a unit, and a consistent snapshot of all + remaining locks is collected as an atomic action. After unlocking the + regular lock manager, the predicate lock manager is similarly locked and all + predicate locks are collected as an atomic action. Thus, with the exception + of fast-path locks, each lock manager will deliver a consistent set of + results, but as we do not lock both lock managers simultaneously, it is + possible for locks to be taken or released after we interrogate the regular + lock manager and before we interrogate the predicate lock manager. +

Locking the regular and/or predicate lock manager could have some + impact on database performance if this view is very frequently accessed. + The locks are held only for the minimum amount of time necessary to + obtain data from the lock managers, but this does not completely eliminate + the possibility of a performance impact. +


PrevHomeNext
pg_indexesUppg_prepared_statements
\ No newline at end of file diff --git a/doc/src/sgml/html/view-pg-prepared-statements.html b/doc/src/sgml/html/view-pg-prepared-statements.html new file mode 100644 index 000000000..f431e4e99 --- /dev/null +++ b/doc/src/sgml/html/view-pg-prepared-statements.html @@ -0,0 +1,338 @@ + +pg_prepared_statements
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.59. pg_prepared_statements

The pg_prepared_statements view displays + all the prepared statements that are available in the current + session. See PREPARE for more information about prepared + statements. +

pg_prepared_statements contains one row + for each prepared statement. Rows are added to the view when a new + prepared statement is created and removed when a prepared statement + is released (for example, via the DEALLOCATE command). +

Table 45-60. pg_prepared_statements Columns

NameTypeDescription
nametext The identifier of the prepared statement +
statementtext The query string submitted by the client to create this + prepared statement. For prepared statements created via SQL, + this is the PREPARE statement submitted by + the client. For prepared statements created via the + frontend/backend protocol, this is the text of the prepared + statement itself. +
prepare_timetimestamptz The time at which the prepared statement was created +
parameter_typesregtype[] The expected parameter types for the prepared statement in the + form of an array of regtype. The OID corresponding + to an element of this array can be obtained by casting the + regtype value to oid. +
from_sqlboolean true if the prepared statement was created + via the PREPARE SQL statement; + false if the statement was prepared via the + frontend/backend protocol +

The pg_prepared_statements view is read only. +


PrevHomeNext
pg_locksUppg_prepared_xacts
\ No newline at end of file diff --git a/doc/src/sgml/html/view-pg-prepared-xacts.html b/doc/src/sgml/html/view-pg-prepared-xacts.html new file mode 100644 index 000000000..b5fc70fe5 --- /dev/null +++ b/doc/src/sgml/html/view-pg-prepared-xacts.html @@ -0,0 +1,337 @@ + +pg_prepared_xacts
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.60. pg_prepared_xacts

The view pg_prepared_xacts displays + information about transactions that are currently prepared for two-phase + commit (see PREPARE TRANSACTION for details). +

pg_prepared_xacts contains one row per prepared + transaction. An entry is removed when the transaction is committed or + rolled back. +

Table 45-61. pg_prepared_xacts Columns

NameTypeReferencesDescription
transactionxid  Numeric transaction identifier of the prepared transaction +
gidtext  Global transaction identifier that was assigned to the transaction +
preparedtimestamp with time zone  Time at which the transaction was prepared for commit +
ownernamepg_authid.rolname Name of the user that executed the transaction +
databasenamepg_database.datname Name of the database in which the transaction was executed +

When the pg_prepared_xacts view is accessed, the + internal transaction manager data structures are momentarily locked, and + a copy is made for the view to display. This ensures that the + view produces a consistent set of results, while not blocking + normal operations longer than necessary. Nonetheless + there could be some impact on database performance if this view is + frequently accessed. +


PrevHomeNext
pg_prepared_statementsUppg_roles
\ No newline at end of file diff --git a/doc/src/sgml/html/view-pg-roles.html b/doc/src/sgml/html/view-pg-roles.html new file mode 100644 index 000000000..8dd03e9ef --- /dev/null +++ b/doc/src/sgml/html/view-pg-roles.html @@ -0,0 +1,464 @@ + +pg_roles
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.61. pg_roles

The view pg_roles provides access to + information about database roles. This is simply a publicly + readable view of + pg_authid + that blanks out the password field. +

This view explicitly exposes the OID column of the underlying table, + since that is needed to do joins to other catalogs. +

Table 45-62. pg_roles Columns

NameTypeReferencesDescription
rolnamename Role name
rolsuperbool Role has superuser privileges
rolinheritbool Role automatically inherits privileges of roles it is a + member of
rolcreaterolebool Role can create more roles
rolcreatedbbool Role can create databases
rolcatupdatebool  Role can update system catalogs directly. (Even a superuser cannot do + this unless this column is true) +
rolcanloginbool  Role can log in. That is, this role can be given as the initial + session authorization identifier +
rolreplicationbool  Role is a replication role. That is, this role can initiate streaming + replication (see Section 25.2.5) and set/unset + the system backup mode using pg_start_backup and + pg_stop_backup +
rolconnlimitint4  For roles that can log in, this sets maximum number of concurrent + connections this role can make. -1 means no limit. +
rolpasswordtext Not the password (always reads as ********)
rolvaliduntiltimestamptz Password expiry time (only used for password authentication); + null if no expiration
rolconfigtext[] Role-specific defaults for run-time configuration variables
oidoidpg_authid.oidID of role

PrevHomeNext
pg_prepared_xactsUppg_rules
\ No newline at end of file diff --git a/doc/src/sgml/html/view-pg-rules.html b/doc/src/sgml/html/view-pg-rules.html new file mode 100644 index 000000000..00bcee990 --- /dev/null +++ b/doc/src/sgml/html/view-pg-rules.html @@ -0,0 +1,314 @@ + +pg_rules
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.62. pg_rules

The view pg_rules provides access to + useful information about query rewrite rules. +

Table 45-63. pg_rules Columns

NameTypeReferencesDescription
schemanamenamepg_namespace.nspnameName of schema containing table
tablenamenamepg_class.relnameName of table the rule is for
rulenamenamepg_rewrite.rulenameName of rule
definitiontext Rule definition (a reconstructed creation command)

The pg_rules view excludes the ON SELECT rules + of views; those can be seen in pg_views. +


PrevHomeNext
pg_rolesUppg_seclabels
\ No newline at end of file diff --git a/doc/src/sgml/html/view-pg-seclabels.html b/doc/src/sgml/html/view-pg-seclabels.html new file mode 100644 index 000000000..76ed3ae2f --- /dev/null +++ b/doc/src/sgml/html/view-pg-seclabels.html @@ -0,0 +1,395 @@ + +pg_seclabels
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.63. pg_seclabels

The view pg_seclabels provides information about + security labels. It as an easier-to-query version of the + pg_seclabel catalog. +

Table 45-64. pg_seclabels Columns

NameTypeReferencesDescription
objoidoidany OID columnThe OID of the object this security label pertains to
classoidoidpg_class.oidThe OID of the system catalog this object appears in
objsubidint4  For a security label on a table column, this is the column number (the + objoid and classoid refer to + the table itself). For all other object types, this column is + zero. +
objtypetext  The type of object to which this label applies, as text. +
objnamespaceoidpg_namespace.oid The OID of the namespace for this object, if applicable; + otherwise NULL. +
objnametext  The name of the object to which this label applies, as text. +
providertextpg_seclabel.providerThe label provider associated with this label.
labeltextpg_seclabel.labelThe security label applied to this object.

PrevHomeNext
pg_rulesUppg_settings
\ No newline at end of file diff --git a/doc/src/sgml/html/view-pg-settings.html b/doc/src/sgml/html/view-pg-settings.html new file mode 100644 index 000000000..e267cc8f5 --- /dev/null +++ b/doc/src/sgml/html/view-pg-settings.html @@ -0,0 +1,695 @@ + +pg_settings
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.64. pg_settings

The view pg_settings provides access to + run-time parameters of the server. It is essentially an alternative + interface to the SHOW + and SET commands. + It also provides access to some facts about each parameter that are + not directly available from SHOW, such as minimum and + maximum values. +

Table 45-65. pg_settings Columns

NameTypeDescription
nametextRun-time configuration parameter name
settingtextCurrent value of the parameter
unittextImplicit unit of the parameter
categorytextLogical group of the parameter
short_desctextA brief description of the parameter
extra_desctextAdditional, more detailed, description of the parameter
contexttextContext required to set the parameter's value (see below)
vartypetextParameter type (bool, enum, + integer, real, or string) +
sourcetextSource of the current parameter value
min_valtextMinimum allowed value of the parameter (null for non-numeric + values)
max_valtextMaximum allowed value of the parameter (null for non-numeric + values)
enumvalstext[]Allowed values of an enum parameter (null for non-enum + values)
boot_valtextParameter value assumed at server startup if the parameter is + not otherwise set
reset_valtextValue that RESET would reset the parameter to + in the current session
sourcefiletextConfiguration file the current value was set in (null for + values set from sources other than configuration files, or when + examined by a non-superuser); + helpful when using include directives in configuration files
sourcelineintegerLine number within the configuration file the current value was + set at (null for values set from sources other than configuration files, + or when examined by a non-superuser) +

There are several possible values of context. + In order of decreasing difficulty of changing the setting, they are: +

internal

These settings cannot be changed directly; they reflect internally + determined values. Some of them may be adjustable by rebuilding the + server with different configuration options, or by changing options + supplied to initdb. +

postmaster

These settings can only be applied when the server starts, so any change + requires restarting the server. Values for these settings are typically + stored in the postgresql.conf file, or passed on + the command line when starting the server. Of course, settings with any + of the lower context types can also be + set at server start time. +

sighup

Changes to these settings can be made in + postgresql.conf without restarting the server. + Send a SIGHUP signal to the postmaster to + cause it to re-read postgresql.conf and apply + the changes. The postmaster will also forward the + SIGHUP signal to its child processes so that + they all pick up the new value. +

backend

Changes to these settings can be made in + postgresql.conf without restarting the server; + they can also be set for a particular session in the connection request + packet (for example, via libpq's PGOPTIONS + environment variable). However, these settings never change in a + session after it is started. If you change them in + postgresql.conf, send a + SIGHUP signal to the postmaster to cause it to + re-read postgresql.conf. The new values will only + affect subsequently-launched sessions. +

superuser

These settings can be set from postgresql.conf, + or within a session via the SET command; but only superusers + can change them via SET. Changes in + postgresql.conf will affect existing sessions + only if no session-local value has been established with SET. +

user

These settings can be set from postgresql.conf, + or within a session via the SET command. Any user is + allowed to change his session-local value. Changes in + postgresql.conf will affect existing sessions + only if no session-local value has been established with SET. +

See Section 18.1 for more information about the various + ways to change these parameters. +

The pg_settings view cannot be inserted into or + deleted from, but it can be updated. An UPDATE applied + to a row of pg_settings is equivalent to executing + the SET command on that named + parameter. The change only affects the value used by the current + session. If an UPDATE is issued within a transaction + that is later aborted, the effects of the UPDATE command + disappear when the transaction is rolled back. Once the surrounding + transaction is committed, the effects will persist until the end of the + session, unless overridden by another UPDATE or + SET. +


PrevHomeNext
pg_seclabelsUppg_shadow
\ No newline at end of file diff --git a/doc/src/sgml/html/view-pg-shadow.html b/doc/src/sgml/html/view-pg-shadow.html new file mode 100644 index 000000000..f3215650b --- /dev/null +++ b/doc/src/sgml/html/view-pg-shadow.html @@ -0,0 +1,416 @@ + +pg_shadow
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.65. pg_shadow

The view pg_shadow exists for backwards + compatibility: it emulates a catalog that existed in + PostgreSQL before version 8.1. + It shows properties of all roles that are marked as + rolcanlogin in + pg_authid. +

The name stems from the fact that this table + should not be readable by the public since it contains passwords. + pg_user + is a publicly readable view on + pg_shadow that blanks out the password field. +

Table 45-66. pg_shadow Columns

NameTypeReferencesDescription
usenamenamepg_authid.rolnameUser name
usesysidoidpg_authid.oidID of this user
usecreatedbbool User can create databases
usesuperbool User is a superuser
usecatupdbool  User can update system catalogs. (Even a superuser cannot do + this unless this column is true.) +
usereplbool  User can initiate streaming replication and put the system in and + out of backup mode. +
passwdtext Password (possibly encrypted); null if none. See + pg_authid + for details of how encrypted passwords are stored.
valuntilabstime Password expiry time (only used for password authentication)
useconfigtext[] Session defaults for run-time configuration variables

PrevHomeNext
pg_settingsUppg_stats
\ No newline at end of file diff --git a/doc/src/sgml/html/view-pg-stats.html b/doc/src/sgml/html/view-pg-stats.html new file mode 100644 index 000000000..b9da026b3 --- /dev/null +++ b/doc/src/sgml/html/view-pg-stats.html @@ -0,0 +1,557 @@ + +pg_stats
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.66. pg_stats

The view pg_stats provides access to + the information stored in the pg_statistic + catalog. This view allows access only to rows of + pg_statistic that correspond to tables the + user has permission to read, and therefore it is safe to allow public + read access to this view. +

pg_stats is also designed to present the + information in a more readable format than the underlying catalog + — at the cost that its schema must be extended whenever new slot types + are defined for pg_statistic. +

Table 45-67. pg_stats Columns

NameTypeReferencesDescription
schemanamenamepg_namespace.nspnameName of schema containing table
tablenamenamepg_class.relnameName of table
attnamenamepg_attribute.attnameName of the column described by this row
inheritedbool If true, this row includes inheritance child columns, not just the + values in the specified table
null_fracreal Fraction of column entries that are null
avg_widthinteger Average width in bytes of column's entries
n_distinctreal  If greater than zero, the estimated number of distinct values in the + column. If less than zero, the negative of the number of distinct + values divided by the number of rows. (The negated form is used when + ANALYZE believes that the number of distinct values is + likely to increase as the table grows; the positive form is used when + the column seems to have a fixed number of possible values.) For + example, -1 indicates a unique column in which the number of distinct + values is the same as the number of rows. +
most_common_valsanyarray  A list of the most common values in the column. (Null if + no values seem to be more common than any others.) +
most_common_freqsreal[]  A list of the frequencies of the most common values, + i.e., number of occurrences of each divided by total number of rows. + (Null when most_common_vals is.) +
histogram_boundsanyarray  A list of values that divide the column's values into groups of + approximately equal population. The values in + most_common_vals, if present, are omitted from this + histogram calculation. (This column is null if the column data type + does not have a < operator or if the + most_common_vals list accounts for the entire + population.) +
correlationreal  Statistical correlation between physical row ordering and + logical ordering of the column values. This ranges from -1 to +1. + When the value is near -1 or +1, an index scan on the column will + be estimated to be cheaper than when it is near zero, due to reduction + of random access to the disk. (This column is null if the column data + type does not have a < operator.) +
most_common_elemsanyarray  A list of non-null element values most often appearing within values of + the column. (Null for scalar types.) +
most_common_elem_freqsreal[]  A list of the frequencies of the most common element values, i.e., the + fraction of rows containing at least one instance of the given value. + Two or three additional values follow the per-element frequencies; + these are the minimum and maximum of the preceding per-element + frequencies, and optionally the frequency of null elements. + (Null when most_common_elems is.) +
elem_count_histogramreal[]  A histogram of the counts of distinct non-null element values within the + values of the column, followed by the average number of distinct + non-null elements. (Null for scalar types.) +

The maximum number of entries in the array fields can be controlled on a + column-by-column basis using the ALTER TABLE SET STATISTICS + command, or globally by setting the + default_statistics_target run-time parameter. +


PrevHomeNext
pg_shadowUppg_tables
\ No newline at end of file diff --git a/doc/src/sgml/html/view-pg-tables.html b/doc/src/sgml/html/view-pg-tables.html new file mode 100644 index 000000000..557739bab --- /dev/null +++ b/doc/src/sgml/html/view-pg-tables.html @@ -0,0 +1,385 @@ + +pg_tables
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.67. pg_tables

The view pg_tables provides access to + useful information about each table in the database. +

Table 45-68. pg_tables Columns

NameTypeReferencesDescription
schemanamenamepg_namespace.nspnameName of schema containing table
tablenamenamepg_class.relnameName of table
tableownernamepg_authid.rolnameName of table's owner
tablespacenamepg_tablespace.spcnameName of tablespace containing table (null if default for database)
hasindexesbooleanpg_class.relhasindexTrue if table has (or recently had) any indexes
hasrulesbooleanpg_class.relhasrulesTrue if table has (or once had) rules
hastriggersbooleanpg_class.relhastriggersTrue if table has (or once had) triggers

PrevHomeNext
pg_statsUppg_timezone_abbrevs
\ No newline at end of file diff --git a/doc/src/sgml/html/view-pg-timezone-abbrevs.html b/doc/src/sgml/html/view-pg-timezone-abbrevs.html new file mode 100644 index 000000000..bde3a9369 --- /dev/null +++ b/doc/src/sgml/html/view-pg-timezone-abbrevs.html @@ -0,0 +1,255 @@ + +pg_timezone_abbrevs
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.68. pg_timezone_abbrevs

The view pg_timezone_abbrevs provides a list + of time zone abbreviations that are currently recognized by the datetime + input routines. The contents of this view change when the + timezone_abbreviations run-time parameter is modified. +

Table 45-69. pg_timezone_abbrevs Columns

NameTypeDescription
abbrevtextTime zone abbreviation
utc_offsetintervalOffset from UTC (positive means east of Greenwich)
is_dstbooleanTrue if this is a daylight-savings abbreviation

PrevHomeNext
pg_tablesUppg_timezone_names
\ No newline at end of file diff --git a/doc/src/sgml/html/view-pg-timezone-names.html b/doc/src/sgml/html/view-pg-timezone-names.html new file mode 100644 index 000000000..9e8ac21f1 --- /dev/null +++ b/doc/src/sgml/html/view-pg-timezone-names.html @@ -0,0 +1,290 @@ + +pg_timezone_names
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.69. pg_timezone_names

The view pg_timezone_names provides a list + of time zone names that are recognized by SET TIMEZONE, + along with their associated abbreviations, UTC offsets, + and daylight-savings status. (Technically, + PostgreSQL uses UT1 rather + than UTC because leap seconds are not handled.) + Unlike the abbreviations shown in pg_timezone_abbrevs, many of these names imply a set of daylight-savings transition + date rules. Therefore, the associated information changes across local DST + boundaries. The displayed information is computed based on the current + value of CURRENT_TIMESTAMP. +

Table 45-70. pg_timezone_names Columns

NameTypeDescription
nametextTime zone name
abbrevtextTime zone abbreviation
utc_offsetintervalOffset from UTC (positive means east of Greenwich)
is_dstbooleanTrue if currently observing daylight savings

PrevHomeNext
pg_timezone_abbrevsUppg_user
\ No newline at end of file diff --git a/doc/src/sgml/html/view-pg-user-mappings.html b/doc/src/sgml/html/view-pg-user-mappings.html new file mode 100644 index 000000000..97457b1be --- /dev/null +++ b/doc/src/sgml/html/view-pg-user-mappings.html @@ -0,0 +1,360 @@ + +pg_user_mappings
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.71. pg_user_mappings

The view pg_user_mappings provides access + to information about user mappings. This is essentially a publicly + readable view of + pg_user_mapping + that leaves out the options field if the user has no rights to use + it. +

Table 45-72. pg_user_mappings Columns

NameTypeReferencesDescription
umidoidpg_user_mapping.oidOID of the user mapping
srvidoidpg_foreign_server.oid The OID of the foreign server that contains this mapping +
srvnamenamepg_foreign_server.srvname Name of the foreign server +
umuseroidpg_authid.oidOID of the local role being mapped, 0 if the user mapping is public
usenamename Name of the local user to be mapped
umoptionstext[]  User mapping specific options, as "keyword=value" + strings, if the current user is the owner of the foreign + server, else null +

PrevHomeNext
pg_userUppg_views
\ No newline at end of file diff --git a/doc/src/sgml/html/view-pg-user.html b/doc/src/sgml/html/view-pg-user.html new file mode 100644 index 000000000..f1f512013 --- /dev/null +++ b/doc/src/sgml/html/view-pg-user.html @@ -0,0 +1,350 @@ + +pg_user
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.70. pg_user

The view pg_user provides access to + information about database users. This is simply a publicly + readable view of + pg_shadow + that blanks out the password field. +

Table 45-71. pg_user Columns

NameTypeDescription
usenamenameUser name
usesysidoidID of this user
usecreatedbboolUser can create databases
usesuperboolUser is a superuser
usecatupdbool User can update system catalogs. (Even a superuser cannot do + this unless this column is true.) +
usereplbool User can initiate streaming replication and put the system in and + out of backup mode. +
passwdtextNot the password (always reads as ********)
valuntilabstimePassword expiry time (only used for password authentication)
useconfigtext[]Session defaults for run-time configuration variables

PrevHomeNext
pg_timezone_namesUppg_user_mappings
\ No newline at end of file diff --git a/doc/src/sgml/html/view-pg-views.html b/doc/src/sgml/html/view-pg-views.html new file mode 100644 index 000000000..e100e0676 --- /dev/null +++ b/doc/src/sgml/html/view-pg-views.html @@ -0,0 +1,301 @@ + +pg_views
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.72. pg_views

The view pg_views provides access to + useful information about each view in the database. +

Table 45-73. pg_views Columns

NameTypeReferencesDescription
schemanamenamepg_namespace.nspnameName of schema containing view
viewnamenamepg_class.relnameName of view
viewownernamepg_authid.rolnameName of view's owner
definitiontext View definition (a reconstructed SELECT query)

PrevHomeNext
pg_user_mappingsUpFrontend/Backend Protocol
\ No newline at end of file diff --git a/doc/src/sgml/html/views-overview.html b/doc/src/sgml/html/views-overview.html new file mode 100644 index 000000000..4b98aa01b --- /dev/null +++ b/doc/src/sgml/html/views-overview.html @@ -0,0 +1,471 @@ + +System Views
PostgreSQL 9.2.2 Documentation
PrevUpChapter 45. System CatalogsNext

45.52. System Views

In addition to the system catalogs, PostgreSQL + provides a number of built-in views. Some system views provide convenient + access to some commonly used queries on the system catalogs. Other views + provide access to internal server state. +

The information schema (Chapter 34) provides + an alternative set of views which overlap the functionality of the system + views. Since the information schema is SQL-standard whereas the views + described here are PostgreSQL-specific, + it's usually better to use the information schema if it provides all + the information you need. +

Table 45-53 lists the system views described here. + More detailed documentation of each view follows below. + There are some additional views that provide access to the results of + the statistics collector; they are described in Table 27-1. +

Except where noted, all the views described here are read-only. +

Table 45-53. System Views

View NamePurpose
pg_available_extensionsavailable extensions
pg_available_extension_versionsavailable versions of extensions
pg_cursorsopen cursors
pg_groupgroups of database users
pg_indexesindexes
pg_lockscurrently held locks
pg_prepared_statementsprepared statements
pg_prepared_xactsprepared transactions
pg_rolesdatabase roles
pg_rulesrules
pg_seclabelssecurity labels
pg_settingsparameter settings
pg_shadowdatabase users
pg_statsplanner statistics
pg_tablestables
pg_timezone_abbrevstime zone abbreviations
pg_timezone_namestime zone names
pg_userdatabase users
pg_user_mappingsuser mappings
pg_viewsviews

PrevHomeNext
pg_user_mappingUppg_available_extensions
\ No newline at end of file diff --git a/doc/src/sgml/html/wal-async-commit.html b/doc/src/sgml/html/wal-async-commit.html new file mode 100644 index 000000000..947d029d1 --- /dev/null +++ b/doc/src/sgml/html/wal-async-commit.html @@ -0,0 +1,380 @@ + +Asynchronous Commit
PostgreSQL 9.2.2 Documentation
PrevUpChapter 29. Reliability and the Write-Ahead LogNext

29.3. Asynchronous Commit

Asynchronous commit is an option that allows transactions + to complete more quickly, at the cost that the most recent transactions may + be lost if the database should crash. In many applications this is an + acceptable trade-off. +

As described in the previous section, transaction commit is normally + synchronous: the server waits for the transaction's + WAL records to be flushed to permanent storage + before returning a success indication to the client. The client is + therefore guaranteed that a transaction reported to be committed will + be preserved, even in the event of a server crash immediately after. + However, for short transactions this delay is a major component of the + total transaction time. Selecting asynchronous commit mode means that + the server returns success as soon as the transaction is logically + completed, before the WAL records it generated have + actually made their way to disk. This can provide a significant boost + in throughput for small transactions. +

Asynchronous commit introduces the risk of data loss. There is a short + time window between the report of transaction completion to the client + and the time that the transaction is truly committed (that is, it is + guaranteed not to be lost if the server crashes). Thus asynchronous + commit should not be used if the client will take external actions + relying on the assumption that the transaction will be remembered. + As an example, a bank would certainly not use asynchronous commit for + a transaction recording an ATM's dispensing of cash. But in many + scenarios, such as event logging, there is no need for a strong + guarantee of this kind. +

The risk that is taken by using asynchronous commit is of data loss, + not data corruption. If the database should crash, it will recover + by replaying WAL up to the last record that was + flushed. The database will therefore be restored to a self-consistent + state, but any transactions that were not yet flushed to disk will + not be reflected in that state. The net effect is therefore loss of + the last few transactions. Because the transactions are replayed in + commit order, no inconsistency can be introduced — for example, + if transaction B made changes relying on the effects of a previous + transaction A, it is not possible for A's effects to be lost while B's + effects are preserved. +

The user can select the commit mode of each transaction, so that + it is possible to have both synchronous and asynchronous commit + transactions running concurrently. This allows flexible trade-offs + between performance and certainty of transaction durability. + The commit mode is controlled by the user-settable parameter + synchronous_commit, which can be changed in any of + the ways that a configuration parameter can be set. The mode used for + any one transaction depends on the value of + synchronous_commit when transaction commit begins. +

Certain utility commands, for instance DROP TABLE, are + forced to commit synchronously regardless of the setting of + synchronous_commit. This is to ensure consistency + between the server's file system and the logical state of the database. + The commands supporting two-phase commit, such as PREPARE + TRANSACTION, are also always synchronous. +

If the database crashes during the risk window between an + asynchronous commit and the writing of the transaction's + WAL records, + then changes made during that transaction will be lost. + The duration of the + risk window is limited because a background process (the "WAL + writer") flushes unwritten WAL records to disk + every wal_writer_delay milliseconds. + The actual maximum duration of the risk window is three times + wal_writer_delay because the WAL writer is + designed to favor writing whole pages at a time during busy periods. +

Caution

An immediate-mode shutdown is equivalent to a server crash, and will + therefore cause loss of any unflushed asynchronous commits. +

Asynchronous commit provides behavior different from setting + fsync = off. + fsync is a server-wide + setting that will alter the behavior of all transactions. It disables + all logic within PostgreSQL that attempts to synchronize + writes to different portions of the database, and therefore a system + crash (that is, a hardware or operating system crash, not a failure of + PostgreSQL itself) could result in arbitrarily bad + corruption of the database state. In many scenarios, asynchronous + commit provides most of the performance improvement that could be + obtained by turning off fsync, but without the risk + of data corruption. +

commit_delay also sounds very similar to + asynchronous commit, but it is actually a synchronous commit method + (in fact, commit_delay is ignored during an + asynchronous commit). commit_delay causes a delay + just before a synchronous commit attempts to flush + WAL to disk, in the hope that a single flush + executed by one such transaction can also serve other transactions + committing at about the same time. Setting commit_delay + can only help when there are many concurrently committing transactions, + and it is difficult to tune it to a value that actually helps rather + than hurts throughput. +


PrevHomeNext
Write-Ahead Logging (WAL)UpWAL Configuration
\ No newline at end of file diff --git a/doc/src/sgml/html/wal-configuration.html b/doc/src/sgml/html/wal-configuration.html new file mode 100644 index 000000000..040a65e10 --- /dev/null +++ b/doc/src/sgml/html/wal-configuration.html @@ -0,0 +1,556 @@ + +WAL Configuration
PostgreSQL 9.2.2 Documentation
PrevUpChapter 29. Reliability and the Write-Ahead LogNext

29.4. WAL Configuration

There are several WAL-related configuration parameters that + affect database performance. This section explains their use. + Consult Chapter 18 for general information about + setting server configuration parameters. +

Checkpoints + are points in the sequence of transactions at which it is guaranteed + that the heap and index data files have been updated with all information written before + the checkpoint. At checkpoint time, all dirty data pages are flushed to + disk and a special checkpoint record is written to the log file. + (The changes were previously flushed to the WAL files.) + In the event of a crash, the crash recovery procedure looks at the latest + checkpoint record to determine the point in the log (known as the redo + record) from which it should start the REDO operation. Any changes made to + data files before that point are guaranteed to be already on disk. Hence, after + a checkpoint, log segments preceding the one containing + the redo record are no longer needed and can be recycled or removed. (When + WAL archiving is being done, the log segments must be + archived before being recycled or removed.) +

The checkpoint requirement of flushing all dirty data pages to disk + can cause a significant I/O load. For this reason, checkpoint + activity is throttled so I/O begins at checkpoint start and completes + before the next checkpoint starts; this minimizes performance + degradation during checkpoints. +

The server's checkpointer process automatically performs + a checkpoint every so often. A checkpoint is created every checkpoint_segments log segments, or every checkpoint_timeout seconds, whichever comes first. + The default settings are 3 segments and 300 seconds (5 minutes), respectively. + In cases where no WAL has been written since the previous checkpoint, new + checkpoints will be skipped even if checkpoint_timeout has passed. + If WAL archiving is being used and you want to put a lower limit on + how often files are archived in order to bound potential data + loss, you should adjust archive_timeout parameter rather than the checkpoint + parameters. It is also possible to force a checkpoint by using the SQL + command CHECKPOINT. +

Reducing checkpoint_segments and/or + checkpoint_timeout causes checkpoints to occur + more often. This allows faster after-crash recovery (since less work + will need to be redone). However, one must balance this against the + increased cost of flushing dirty data pages more often. If + full_page_writes is set (as is the default), there is + another factor to consider. To ensure data page consistency, + the first modification of a data page after each checkpoint results in + logging the entire page content. In that case, + a smaller checkpoint interval increases the volume of output to the WAL log, + partially negating the goal of using a smaller interval, + and in any case causing more disk I/O. +

Checkpoints are fairly expensive, first because they require writing + out all currently dirty buffers, and second because they result in + extra subsequent WAL traffic as discussed above. It is therefore + wise to set the checkpointing parameters high enough that checkpoints + don't happen too often. As a simple sanity check on your checkpointing + parameters, you can set the checkpoint_warning + parameter. If checkpoints happen closer together than + checkpoint_warning seconds, + a message will be output to the server log recommending increasing + checkpoint_segments. Occasional appearance of such + a message is not cause for alarm, but if it appears often then the + checkpoint control parameters should be increased. Bulk operations such + as large COPY transfers might cause a number of such warnings + to appear if you have not set checkpoint_segments high + enough. +

To avoid flooding the I/O system with a burst of page writes, + writing dirty buffers during a checkpoint is spread over a period of time. + That period is controlled by + checkpoint_completion_target, which is + given as a fraction of the checkpoint interval. + The I/O rate is adjusted so that the checkpoint finishes when the + given fraction of checkpoint_segments WAL segments + have been consumed since checkpoint start, or the given fraction of + checkpoint_timeout seconds have elapsed, + whichever is sooner. With the default value of 0.5, + PostgreSQL can be expected to complete each checkpoint + in about half the time before the next checkpoint starts. On a system + that's very close to maximum I/O throughput during normal operation, + you might want to increase checkpoint_completion_target + to reduce the I/O load from checkpoints. The disadvantage of this is that + prolonging checkpoints affects recovery time, because more WAL segments + will need to be kept around for possible use in recovery. Although + checkpoint_completion_target can be set as high as 1.0, + it is best to keep it less than that (perhaps 0.9 at most) since + checkpoints include some other activities besides writing dirty buffers. + A setting of 1.0 is quite likely to result in checkpoints not being + completed on time, which would result in performance loss due to + unexpected variation in the number of WAL segments needed. +

There will always be at least one WAL segment file, and will normally + not be more than (2 + checkpoint_completion_target) * checkpoint_segments + 1 + or checkpoint_segments + wal_keep_segments + 1 + files. Each segment file is normally 16 MB (though this size can be + altered when building the server). You can use this to estimate space + requirements for WAL. + Ordinarily, when old log segment files are no longer needed, they + are recycled (renamed to become the next segments in the numbered + sequence). If, due to a short-term peak of log output rate, there + are more than 3 * checkpoint_segments + 1 + segment files, the unneeded segment files will be deleted instead + of recycled until the system gets back under this limit. +

In archive recovery or standby mode, the server periodically performs + restartpoints + which are similar to checkpoints in normal operation: the server forces + all its state to disk, updates the pg_control file to + indicate that the already-processed WAL data need not be scanned again, + and then recycles any old log segment files in pg_xlog + directory. A restartpoint is triggered if at least one checkpoint record + has been replayed and checkpoint_timeout seconds have passed + since last restartpoint. In standby mode, a restartpoint is also triggered + if checkpoint_segments log segments have been replayed since + last restartpoint and at least one checkpoint record has been replayed. + Restartpoints can't be performed more frequently than checkpoints in the + master because restartpoints can only be performed at checkpoint records. +

There are two commonly used internal WAL functions: + LogInsert and LogFlush. + LogInsert is used to place a new record into + the WAL buffers in shared memory. If there is no + space for the new record, LogInsert will have + to write (move to kernel cache) a few filled WAL + buffers. This is undesirable because LogInsert + is used on every database low level modification (for example, row + insertion) at a time when an exclusive lock is held on affected + data pages, so the operation needs to be as fast as possible. What + is worse, writing WAL buffers might also force the + creation of a new log segment, which takes even more + time. Normally, WAL buffers should be written + and flushed by a LogFlush request, which is + made, for the most part, at transaction commit time to ensure that + transaction records are flushed to permanent storage. On systems + with high log output, LogFlush requests might + not occur often enough to prevent LogInsert + from having to do writes. On such systems + one should increase the number of WAL buffers by + modifying the configuration parameter wal_buffers. When + full_page_writes is set and the system is very busy, + setting this value higher will help smooth response times during the + period immediately following each checkpoint. +

The commit_delay parameter defines for how many + microseconds the server process will sleep after writing a commit + record to the log with LogInsert but before + performing a LogFlush. This delay allows other + server processes to add their commit records to the log so as to have all + of them flushed with a single log sync. No sleep will occur if + fsync + is not enabled, or if fewer than commit_siblings + other sessions are currently in active transactions; this avoids + sleeping when it's unlikely that any other session will commit soon. + Note that on most platforms, the resolution of a sleep request is + ten milliseconds, so that any nonzero commit_delay + setting between 1 and 10000 microseconds would have the same effect. + Good values for these parameters are not yet clear; experimentation + is encouraged. +

The wal_sync_method parameter determines how + PostgreSQL will ask the kernel to force + WAL updates out to disk. + All the options should be the same in terms of reliability, with + the exception of fsync_writethrough, which can sometimes + force a flush of the disk cache even when other options do not do so. + However, it's quite platform-specific which one will be the fastest; + you can test option speeds using the pg_test_fsync module. + Note that this parameter is irrelevant if fsync + has been turned off. +

Enabling the wal_debug configuration parameter + (provided that PostgreSQL has been + compiled with support for it) will result in each + LogInsert and LogFlush + WAL call being logged to the server log. This + option might be replaced by a more general mechanism in the future. +


PrevHomeNext
Asynchronous CommitUpWAL Internals
\ No newline at end of file diff --git a/doc/src/sgml/html/wal-internals.html b/doc/src/sgml/html/wal-internals.html new file mode 100644 index 000000000..a3b96d00c --- /dev/null +++ b/doc/src/sgml/html/wal-internals.html @@ -0,0 +1,294 @@ + +WAL Internals
PostgreSQL 9.2.2 Documentation
PrevUpChapter 29. Reliability and the Write-Ahead LogNext

29.5. WAL Internals

WAL is automatically enabled; no action is + required from the administrator except ensuring that the + disk-space requirements for the WAL logs are met, + and that any necessary tuning is done (see Section 29.4). +

WAL logs are stored in the directory + pg_xlog under the data directory, as a set of + segment files, normally each 16 MB in size (but the size can be changed + by altering the --with-wal-segsize configure option when + building the server). Each segment is divided into pages, normally + 8 kB each (this size can be changed via the --with-wal-blocksize + configure option). The log record headers are described in + access/xlog.h; the record content is dependent + on the type of event that is being logged. Segment files are given + ever-increasing numbers as names, starting at + 000000010000000000000000. The numbers do not wrap, + but it will take a very, very long time to exhaust the + available stock of numbers. +

It is advantageous if the log is located on a different disk from the + main database files. This can be achieved by moving the + pg_xlog directory to another location (while the server + is shut down, of course) and creating a symbolic link from the + original location in the main data directory to the new location. +

The aim of WAL is to ensure that the log is + written before database records are altered, but this can be subverted by + disk drives that falsely report a + successful write to the kernel, + when in fact they have only cached the data and not yet stored it + on the disk. A power failure in such a situation might lead to + irrecoverable data corruption. Administrators should try to ensure + that disks holding PostgreSQL's + WAL log files do not make such false reports. + (See Section 29.1.) +

After a checkpoint has been made and the log flushed, the + checkpoint's position is saved in the file + pg_control. Therefore, at the start of recovery, + the server first reads pg_control and + then the checkpoint record; then it performs the REDO operation by + scanning forward from the log position indicated in the checkpoint + record. Because the entire content of data pages is saved in the + log on the first page modification after a checkpoint (assuming + full_page_writes is not disabled), all pages + changed since the checkpoint will be restored to a consistent + state. +

To deal with the case where pg_control is + corrupt, we should support the possibility of scanning existing log + segments in reverse order — newest to oldest — in order to find the + latest checkpoint. This has not been implemented yet. + pg_control is small enough (less than one disk page) + that it is not subject to partial-write problems, and as of this writing + there have been no reports of database failures due solely to the inability + to read pg_control itself. So while it is + theoretically a weak spot, pg_control does not + seem to be a problem in practice. +


PrevHomeNext
WAL ConfigurationUpRegression Tests
\ No newline at end of file diff --git a/doc/src/sgml/html/wal-intro.html b/doc/src/sgml/html/wal-intro.html new file mode 100644 index 000000000..880293e85 --- /dev/null +++ b/doc/src/sgml/html/wal-intro.html @@ -0,0 +1,257 @@ + +Write-Ahead Logging (WAL)
PostgreSQL 9.2.2 Documentation
PrevUpChapter 29. Reliability and the Write-Ahead LogNext

29.2. Write-Ahead Logging (WAL)

Write-Ahead Logging (WAL) + is a standard method for ensuring data integrity. A detailed + description can be found in most (if not all) books about + transaction processing. Briefly, WAL's central + concept is that changes to data files (where tables and indexes + reside) must be written only after those changes have been logged, + that is, after log records describing the changes have been flushed + to permanent storage. If we follow this procedure, we do not need + to flush data pages to disk on every transaction commit, because we + know that in the event of a crash we will be able to recover the + database using the log: any changes that have not been applied to + the data pages can be redone from the log records. (This is + roll-forward recovery, also known as REDO.) +

Tip: Because WAL restores database file + contents after a crash, journaled file systems are not necessary for + reliable storage of the data files or WAL files. In fact, journaling + overhead can reduce performance, especially if journaling + causes file system data to be flushed + to disk. Fortunately, data flushing during journaling can + often be disabled with a file system mount option, e.g. + data=writeback on a Linux ext3 file system. + Journaled file systems do improve boot speed after a crash. +

Using WAL results in a + significantly reduced number of disk writes, because only the log + file needs to be flushed to disk to guarantee that a transaction is + committed, rather than every data file changed by the transaction. + The log file is written sequentially, + and so the cost of syncing the log is much less than the cost of + flushing the data pages. This is especially true for servers + handling many small transactions touching different parts of the data + store. Furthermore, when the server is processing many small concurrent + transactions, one fsync of the log file may + suffice to commit many transactions. +

WAL also makes it possible to support on-line + backup and point-in-time recovery, as described in Section 24.3. By archiving the WAL data we can support + reverting to any time instant covered by the available WAL data: + we simply install a prior physical backup of the database, and + replay the WAL log just as far as the desired time. What's more, + the physical backup doesn't have to be an instantaneous snapshot + of the database state — if it is made over some period of time, + then replaying the WAL log for that period will fix any internal + inconsistencies. +


PrevHomeNext
ReliabilityUpAsynchronous Commit
\ No newline at end of file diff --git a/doc/src/sgml/html/wal-reliability.html b/doc/src/sgml/html/wal-reliability.html new file mode 100644 index 000000000..896ead670 --- /dev/null +++ b/doc/src/sgml/html/wal-reliability.html @@ -0,0 +1,490 @@ + +Reliability
PostgreSQL 9.2.2 Documentation
PrevUpChapter 29. Reliability and the Write-Ahead LogNext

29.1. Reliability

Reliability is an important property of any serious database + system, and PostgreSQL does everything possible to + guarantee reliable operation. One aspect of reliable operation is + that all data recorded by a committed transaction should be stored + in a nonvolatile area that is safe from power loss, operating + system failure, and hardware failure (except failure of the + nonvolatile area itself, of course). Successfully writing the data + to the computer's permanent storage (disk drive or equivalent) + ordinarily meets this requirement. In fact, even if a computer is + fatally damaged, if the disk drives survive they can be moved to + another computer with similar hardware and all committed + transactions will remain intact. +

While forcing data to the disk platters periodically might seem like + a simple operation, it is not. Because disk drives are dramatically + slower than main memory and CPUs, several layers of caching exist + between the computer's main memory and the disk platters. + First, there is the operating system's buffer cache, which caches + frequently requested disk blocks and combines disk writes. Fortunately, + all operating systems give applications a way to force writes from + the buffer cache to disk, and PostgreSQL uses those + features. (See the wal_sync_method parameter + to adjust how this is done.) +

Next, there might be a cache in the disk drive controller; this is + particularly common on RAID controller cards. Some of + these caches are write-through, meaning writes are sent + to the drive as soon as they arrive. Others are + write-back, meaning data is sent to the drive at + some later time. Such caches can be a reliability hazard because the + memory in the disk controller cache is volatile, and will lose its + contents in a power failure. Better controller cards have + battery-backup units (BBUs), meaning + the card has a battery that + maintains power to the cache in case of system power loss. After power + is restored the data will be written to the disk drives. +

And finally, most disk drives have caches. Some are write-through + while some are write-back, and the same concerns about data loss + exist for write-back drive caches as for disk controller + caches. Consumer-grade IDE and SATA drives are particularly likely + to have write-back caches that will not survive a power failure. Many + solid-state drives (SSD) also have volatile write-back caches. +

These caches can typically be disabled; however, the method for doing + this varies by operating system and drive type: +

  • On Linux, IDE drives can be queried using + hdparm -I; write caching is enabled if there is + a * next to Write cache. hdparm -W 0 + can be used to turn off write caching. SCSI drives can be queried + using sdparm. + Use sdparm --get=WCE to check + whether the write cache is enabled and sdparm --clear=WCE + to disable it. +

  • On FreeBSD, IDE drives can be queried using + atacontrol and write caching turned off using + hw.ata.wc=0 in /boot/loader.conf; + SCSI drives can be queried using camcontrol identify, + and the write cache both queried and changed using + sdparm when available. +

  • On Solaris, the disk write cache is controlled by + format -e. + (The Solaris ZFS file system is safe with disk write-cache + enabled because it issues its own disk cache flush commands.) +

  • On Windows, if wal_sync_method is + open_datasync (the default), write caching can be disabled + by unchecking My Computer\Open\disk drive\Properties\Hardware\Properties\Policies\Enable write caching on the disk. + Alternatively, set wal_sync_method to + fsync or fsync_writethrough, which prevent + write caching. +

  • On Mac OS X, write caching can be prevented by + setting wal_sync_method to fsync_writethrough. +

Recent SATA drives (those following ATAPI-6 or later) + offer a drive cache flush command (FLUSH CACHE EXT), + while SCSI drives have long supported a similar command + SYNCHRONIZE CACHE. These commands are not directly + accessible to PostgreSQL, but some file systems + (e.g., ZFS, ext4) can use them to flush + data to the platters on write-back-enabled drives. Unfortunately, such + file systems behave suboptimally when combined with battery-backup unit + (BBU) disk controllers. In such setups, the synchronize + command forces all data from the controller cache to the disks, + eliminating much of the benefit of the BBU. You can run the + pg_test_fsync module to see + if you are affected. If you are affected, the performance benefits + of the BBU can be regained by turning off write barriers in + the file system or reconfiguring the disk controller, if that is + an option. If write barriers are turned off, make sure the battery + remains functional; a faulty battery can potentially lead to data loss. + Hopefully file system and disk controller designers will eventually + address this suboptimal behavior. +

When the operating system sends a write request to the storage hardware, + there is little it can do to make sure the data has arrived at a truly + non-volatile storage area. Rather, it is the + administrator's responsibility to make certain that all storage components + ensure data integrity. Avoid disk controllers that have non-battery-backed + write caches. At the drive level, disable write-back caching if the + drive cannot guarantee the data will be written before shutdown. + If you use SSDs, be aware that many of these do not honor cache flush + commands by default. + You can test for reliable I/O subsystem behavior using diskchecker.pl. +

Another risk of data loss is posed by the disk platter write + operations themselves. Disk platters are divided into sectors, + commonly 512 bytes each. Every physical read or write operation + processes a whole sector. + When a write request arrives at the drive, it might be for some multiple + of 512 bytes (PostgreSQL typically writes 8192 bytes, or + 16 sectors, at a time), and the process of writing could fail due + to power loss at any time, meaning some of the 512-byte sectors were + written while others were not. To guard against such failures, + PostgreSQL periodically writes full page images to + permanent WAL storage before modifying the actual page on + disk. By doing this, during crash recovery PostgreSQL can + restore partially-written pages from WAL. If you have file-system software + that prevents partial page writes (e.g., ZFS), you can turn off + this page imaging by turning off the full_page_writes parameter. Battery-Backed Unit + (BBU) disk controllers do not prevent partial page writes unless + they guarantee that data is written to the BBU as full (8kB) pages. +


PrevHomeNext
Reliability and the Write-Ahead LogUpWrite-Ahead Logging (WAL)
\ No newline at end of file diff --git a/doc/src/sgml/html/wal.html b/doc/src/sgml/html/wal.html new file mode 100644 index 000000000..c24ccc64d --- /dev/null +++ b/doc/src/sgml/html/wal.html @@ -0,0 +1,206 @@ + +Reliability and the Write-Ahead Log

Chapter 29. Reliability and the Write-Ahead Log

This chapter explains how the Write-Ahead Log is used to obtain + efficient, reliable operation. +


PrevHomeNext
Disk Full FailureUpReliability
\ No newline at end of file diff --git a/doc/src/sgml/html/warm-standby-failover.html b/doc/src/sgml/html/warm-standby-failover.html new file mode 100644 index 000000000..f71a86c1f --- /dev/null +++ b/doc/src/sgml/html/warm-standby-failover.html @@ -0,0 +1,251 @@ + +Failover
PostgreSQL 9.2.2 Documentation
PrevUpChapter 25. High Availability, Load Balancing, and ReplicationNext

25.3. Failover

If the primary server fails then the standby server should begin + failover procedures. +

If the standby server fails then no failover need take place. If the + standby server can be restarted, even some time later, then the recovery + process can also be restarted immediately, taking advantage of + restartable recovery. If the standby server cannot be restarted, then a + full new standby server instance should be created. +

If the primary server fails and the standby server becomes the + new primary, and then the old primary restarts, you must have + a mechanism for informing the old primary that it is no longer the primary. This is + sometimes known as STONITH (Shoot The Other Node In The Head), which is + necessary to avoid situations where both systems think they are the + primary, which will lead to confusion and ultimately data loss. +

Many failover systems use just two systems, the primary and the standby, + connected by some kind of heartbeat mechanism to continually verify the + connectivity between the two and the viability of the primary. It is + also possible to use a third system (called a witness server) to prevent + some cases of inappropriate failover, but the additional complexity + might not be worthwhile unless it is set up with sufficient care and + rigorous testing. +

PostgreSQL does not provide the system + software required to identify a failure on the primary and notify + the standby database server. Many such tools exist and are well + integrated with the operating system facilities required for + successful failover, such as IP address migration. +

Once failover to the standby occurs, there is only a + single server in operation. This is known as a degenerate state. + The former standby is now the primary, but the former primary is down + and might stay down. To return to normal operation, a standby server + must be recreated, + either on the former primary system when it comes up, or on a third, + possibly new, system. Once complete, the primary and standby can be + considered to have switched roles. Some people choose to use a third + server to provide backup for the new primary until the new standby + server is recreated, + though clearly this complicates the system configuration and + operational processes. +

So, switching from primary to standby server can be fast but requires + some time to re-prepare the failover cluster. Regular switching from + primary to standby is useful, since it allows regular downtime on + each system for maintenance. This also serves as a test of the + failover mechanism to ensure that it will really work when you need it. + Written administration procedures are advised. +

To trigger failover of a log-shipping standby server, + run pg_ctl promote or create a trigger + file with the file name and path specified by the trigger_file + setting in recovery.conf. If you're planning to use + pg_ctl promote to fail over, trigger_file is + not required. If you're setting up the reporting servers that are + only used to offload read-only queries from the primary, not for high + availability purposes, you don't need to promote it. +


PrevHomeNext
Log-Shipping Standby ServersUpAlternative Method for Log Shipping
\ No newline at end of file diff --git a/doc/src/sgml/html/warm-standby.html b/doc/src/sgml/html/warm-standby.html new file mode 100644 index 000000000..18824086e --- /dev/null +++ b/doc/src/sgml/html/warm-standby.html @@ -0,0 +1,1173 @@ + +Log-Shipping Standby Servers
PostgreSQL 9.2.2 Documentation
PrevUpChapter 25. High Availability, Load Balancing, and ReplicationNext

25.2. Log-Shipping Standby Servers

Continuous archiving can be used to create a high + availability (HA) cluster configuration with one or more + standby servers ready to take over operations if the + primary server fails. This capability is widely referred to as + warm standby or log shipping. +

The primary and standby server work together to provide this capability, + though the servers are only loosely coupled. The primary server operates + in continuous archiving mode, while each standby server operates in + continuous recovery mode, reading the WAL files from the primary. No + changes to the database tables are required to enable this capability, + so it offers low administration overhead compared to some other + replication solutions. This configuration also has relatively low + performance impact on the primary server. +

Directly moving WAL records from one database server to another + is typically described as log shipping. PostgreSQL + implements file-based log shipping by transferring WAL records + one file (WAL segment) at a time. WAL files (16MB) can be + shipped easily and cheaply over any distance, whether it be to an + adjacent system, another system at the same site, or another system on + the far side of the globe. The bandwidth required for this technique + varies according to the transaction rate of the primary server. + Record-based log shipping is more granular and streams WAL changes + incrementally over a network connection (see Section 25.2.5). +

It should be noted that log shipping is asynchronous, i.e., the WAL + records are shipped after transaction commit. As a result, there is a + window for data loss should the primary server suffer a catastrophic + failure; transactions not yet shipped will be lost. The size of the + data loss window in file-based log shipping can be limited by use of the + archive_timeout parameter, which can be set as low + as a few seconds. However such a low setting will + substantially increase the bandwidth required for file shipping. + Streaming replication (see Section 25.2.5) + allows a much smaller window of data loss. +

Recovery performance is sufficiently good that the standby will + typically be only moments away from full + availability once it has been activated. As a result, this is called + a warm standby configuration which offers high + availability. Restoring a server from an archived base backup and + rollforward will take considerably longer, so that technique only + offers a solution for disaster recovery, not high availability. + A standby server can also be used for read-only queries, in which case + it is called a Hot Standby server. See Section 25.5 for + more information. +

25.2.1. Planning

It is usually wise to create the primary and standby servers + so that they are as similar as possible, at least from the + perspective of the database server. In particular, the path names + associated with tablespaces will be passed across unmodified, so both + primary and standby servers must have the same mount paths for + tablespaces if that feature is used. Keep in mind that if + CREATE TABLESPACE + is executed on the primary, any new mount point needed for it must + be created on the primary and all standby servers before the command + is executed. Hardware need not be exactly the same, but experience shows + that maintaining two identical systems is easier than maintaining two + dissimilar ones over the lifetime of the application and system. + In any case the hardware architecture must be the same — shipping + from, say, a 32-bit to a 64-bit system will not work. +

In general, log shipping between servers running different major + PostgreSQL release + levels is not possible. It is the policy of the PostgreSQL Global + Development Group not to make changes to disk formats during minor release + upgrades, so it is likely that running different minor release levels + on primary and standby servers will work successfully. However, no + formal support for that is offered and you are advised to keep primary + and standby servers at the same release level as much as possible. + When updating to a new minor release, the safest policy is to update + the standby servers first — a new minor release is more likely + to be able to read WAL files from a previous minor release than vice + versa. +

25.2.2. Standby Server Operation

In standby mode, the server continuously applies WAL received from the + master server. The standby server can read WAL from a WAL archive + (see restore_command) or directly from the master + over a TCP connection (streaming replication). The standby server will + also attempt to restore any WAL found in the standby cluster's + pg_xlog directory. That typically happens after a server + restart, when the standby replays again WAL that was streamed from the + master before the restart, but you can also manually copy files to + pg_xlog at any time to have them replayed. +

At startup, the standby begins by restoring all WAL available in the + archive location, calling restore_command. Once it + reaches the end of WAL available there and restore_command + fails, it tries to restore any WAL available in the pg_xlog directory. + If that fails, and streaming replication has been configured, the + standby tries to connect to the primary server and start streaming WAL + from the last valid record found in archive or pg_xlog. If that fails + or streaming replication is not configured, or if the connection is + later disconnected, the standby goes back to step 1 and tries to + restore the file from the archive again. This loop of retries from the + archive, pg_xlog, and via streaming replication goes on until the server + is stopped or failover is triggered by a trigger file. +

Standby mode is exited and the server switches to normal operation + when pg_ctl promote is run or a trigger file is found + (trigger_file). Before failover, + any WAL immediately available in the archive or in pg_xlog will be + restored, but no attempt is made to connect to the master. +

25.2.3. Preparing the Master for Standby Servers

Set up continuous archiving on the primary to an archive directory + accessible from the standby, as described + in Section 24.3. The archive location should be + accessible from the standby even when the master is down, i.e. it should + reside on the standby server itself or another trusted server, not on + the master server. +

If you want to use streaming replication, set up authentication on the + primary server to allow replication connections from the standby + server(s); that is, create a role and provide a suitable entry or + entries in pg_hba.conf with the database field set to + replication. Also ensure max_wal_senders is set + to a sufficiently large value in the configuration file of the primary + server. +

Take a base backup as described in Section 24.3.2 + to bootstrap the standby server. +

25.2.4. Setting Up a Standby Server

To set up the standby server, restore the base backup taken from primary + server (see Section 24.3.4). Create a recovery + command file recovery.conf in the standby's cluster data + directory, and turn on standby_mode. Set + restore_command to a simple command to copy files from + the WAL archive. If you plan to have multiple standby servers for high + availability purposes, set recovery_target_timeline to + latest, to make the standby server follow the timeline change + that occurs at failover to another standby. +

Note: Do not use pg_standby or similar tools with the built-in standby mode + described here. restore_command should return immediately + if the file does not exist; the server will retry the command again if + necessary. See Section 25.4 + for using tools like pg_standby. +

If you want to use streaming replication, fill in + primary_conninfo with a libpq connection string, including + the host name (or IP address) and any additional details needed to + connect to the primary server. If the primary needs a password for + authentication, the password needs to be specified in + primary_conninfo as well. +

If you're setting up the standby server for high availability purposes, + set up WAL archiving, connections and authentication like the primary + server, because the standby server will work as a primary server after + failover. +

If you're using a WAL archive, its size can be minimized using the archive_cleanup_command parameter to remove files that are no + longer required by the standby server. + The pg_archivecleanup utility is designed specifically to + be used with archive_cleanup_command in typical single-standby + configurations, see pg_archivecleanup. + Note however, that if you're using the archive for backup purposes, you + need to retain files needed to recover from at least the latest base + backup, even if they're no longer needed by the standby. +

A simple example of a recovery.conf is: +

standby_mode = 'on'
+primary_conninfo = 'host=192.168.1.50 port=5432 user=foo password=foopass'
+restore_command = 'cp /path/to/archive/%f %p'
+archive_cleanup_command = 'pg_archivecleanup /path/to/archive %r'

+

You can have any number of standby servers, but if you use streaming + replication, make sure you set max_wal_senders high enough in + the primary to allow them to be connected simultaneously. +

25.2.5. Streaming Replication

Streaming replication allows a standby server to stay more up-to-date + than is possible with file-based log shipping. The standby connects + to the primary, which streams WAL records to the standby as they're + generated, without waiting for the WAL file to be filled. +

Streaming replication is asynchronous, so there is still a small delay + between committing a transaction in the primary and for the changes to + become visible in the standby. The delay is however much smaller than with + file-based log shipping, typically under one second assuming the standby + is powerful enough to keep up with the load. With streaming replication, + archive_timeout is not required to reduce the data loss + window. +

If you use streaming replication without file-based continuous + archiving, you have to set wal_keep_segments in the master + to a value high enough to ensure that old WAL segments are not recycled + too early, while the standby might still need them to catch up. If the + standby falls behind too much, it needs to be reinitialized from a new + base backup. If you set up a WAL archive that's accessible from the + standby, wal_keep_segments is not required as the standby can always + use the archive to catch up. +

To use streaming replication, set up a file-based log-shipping standby + server as described in Section 25.2. The step that + turns a file-based log-shipping standby into streaming replication + standby is setting primary_conninfo setting in the + recovery.conf file to point to the primary server. Set + listen_addresses and authentication options + (see pg_hba.conf) on the primary so that the standby server + can connect to the replication pseudo-database on the primary + server (see Section 25.2.5.1). +

On systems that support the keepalive socket option, setting + tcp_keepalives_idle, + tcp_keepalives_interval and + tcp_keepalives_count helps the primary promptly + notice a broken connection. +

Set the maximum number of concurrent connections from the standby servers + (see max_wal_senders for details). +

When the standby is started and primary_conninfo is set + correctly, the standby will connect to the primary after replaying all + WAL files available in the archive. If the connection is established + successfully, you will see a walreceiver process in the standby, and + a corresponding walsender process in the primary. +

25.2.5.1. Authentication

It is very important that the access privileges for replication be set up + so that only trusted users can read the WAL stream, because it is + easy to extract privileged information from it. Standby servers must + authenticate to the primary as a superuser or an account that has the + REPLICATION privilege. It is recommended to create a + dedicated user account with REPLICATION and LOGIN + privileges for replication. While REPLICATION privilege gives + very high permissions, it does not allow the user to modify any data on + the primary system, which the SUPERUSER privilege does. +

Client authentication for replication is controlled by a + pg_hba.conf record specifying replication in the + database field. For example, if the standby is running on + host IP 192.168.1.100 and the account name for replication + is foo, the administrator can add the following line to the + pg_hba.conf file on the primary: + +

# Allow the user "foo" from host 192.168.1.100 to connect to the primary
+# as a replication standby if the user's password is correctly supplied.
+#
+# TYPE  DATABASE        USER            ADDRESS                 METHOD
+host    replication     foo             192.168.1.100/32        md5

+

The host name and port number of the primary, connection user name, + and password are specified in the recovery.conf file. + The password can also be set in the ~/.pgpass file on the + standby (specify replication in the database + field). + For example, if the primary is running on host IP 192.168.1.50, + port 5432, the account name for replication is + foo, and the password is foopass, the administrator + can add the following line to the recovery.conf file on the + standby: + +

# The standby connects to the primary that is running on host 192.168.1.50
+# and port 5432 as the user "foo" whose password is "foopass".
+primary_conninfo = 'host=192.168.1.50 port=5432 user=foo password=foopass'

+

25.2.5.2. Monitoring

An important health indicator of streaming replication is the amount + of WAL records generated in the primary, but not yet applied in the + standby. You can calculate this lag by comparing the current WAL write + location on the primary with the last WAL location received by the + standby. They can be retrieved using + pg_current_xlog_location on the primary and the + pg_last_xlog_receive_location on the standby, + respectively (see Table 9-59 and + Table 9-60 for details). + The last WAL receive location in the standby is also displayed in the + process status of the WAL receiver process, displayed using the + ps command (see Section 27.1 for details). +

You can retrieve a list of WAL sender processes via the + pg_stat_replication view. Large differences between + pg_current_xlog_location and sent_location field + might indicate that the master server is under heavy load, while + differences between sent_location and + pg_last_xlog_receive_location on the standby might indicate + network delay, or that the standby is under heavy load. +

25.2.6. Cascading Replication

The cascading replication feature allows a standby server to accept replication + connections and stream WAL records to other standbys, acting as a relay. + This can be used to reduce the number of direct connections to the master + and also to minimize inter-site bandwidth overheads. +

A standby acting as both a receiver and a sender is known as a cascading + standby. Standbys that are more directly connected to the master are known + as upstream servers, while those standby servers further away are downstream + servers. Cascading replication does not place limits on the number or + arrangement of downstream servers, though each standby connects to only + one upstream server which eventually links to a single master/primary + server. +

A cascading standby sends not only WAL records received from the + master but also those restored from the archive. So even if the replication + connection in some upstream connection is terminated, streaming replication + continues downstream for as long as new WAL records are available. +

Cascading replication is currently asynchronous. Synchronous replication + (see Section 25.2.7) settings have no effect on + cascading replication at present. +

Hot Standby feedback propagates upstream, whatever the cascaded arrangement. +

Promoting a cascading standby terminates the immediate downstream replication + connections which it serves. This is because the timeline becomes different + between standbys, and they can no longer continue replication. The + affected standby(s) may reconnect to reestablish streaming replication. +

To use cascading replication, set up the cascading standby so that it can + accept replication connections (that is, set + max_wal_senders and hot_standby, + and configure + host-based authentication). + You will also need to set primary_conninfo in the downstream + standby to point to the cascading standby. +

25.2.7. Synchronous Replication

PostgreSQL streaming replication is asynchronous by + default. If the primary server + crashes then some transactions that were committed may not have been + replicated to the standby server, causing data loss. The amount + of data loss is proportional to the replication delay at the time of + failover. +

Synchronous replication offers the ability to confirm that all changes + made by a transaction have been transferred to one synchronous standby + server. This extends the standard level of durability + offered by a transaction commit. This level of protection is referred + to as 2-safe replication in computer science theory. +

When requesting synchronous replication, each commit of a + write transaction will wait until confirmation is + received that the commit has been written to the transaction log on disk + of both the primary and standby server. The only possibility that data + can be lost is if both the primary and the standby suffer crashes at the + same time. This can provide a much higher level of durability, though only + if the sysadmin is cautious about the placement and management of the two + servers. Waiting for confirmation increases the user's confidence that the + changes will not be lost in the event of server crashes but it also + necessarily increases the response time for the requesting transaction. + The minimum wait time is the roundtrip time between primary to standby. +

Read only transactions and transaction rollbacks need not wait for + replies from standby servers. Subtransaction commits do not wait for + responses from standby servers, only top-level commits. Long + running actions such as data loading or index building do not wait + until the very final commit message. All two-phase commit actions + require commit waits, including both prepare and commit. +

25.2.7.1. Basic Configuration

Once streaming replication has been configured, configuring synchronous + replication requires only one additional configuration step: + synchronous_standby_names must be set to + a non-empty value. synchronous_commit must also be set to + on, but since this is the default value, typically no change is + required. (See Section 18.5.1 and + Section 18.6.2.) + This configuration will cause each commit to wait for + confirmation that the standby has written the commit record to durable + storage. + synchronous_commit can be set by individual + users, so it can be configured in the configuration file, for particular + users or databases, or dynamically by applications, in order to control + the durability guarantee on a per-transaction basis. +

After a commit record has been written to disk on the primary, the + WAL record is then sent to the standby. The standby sends reply + messages each time a new batch of WAL data is written to disk, unless + wal_receiver_status_interval is set to zero on the standby. + If the standby is the first matching standby, as specified in + synchronous_standby_names on the primary, the reply + messages from that standby will be used to wake users waiting for + confirmation that the commit record has been received. These parameters + allow the administrator to specify which standby servers should be + synchronous standbys. Note that the configuration of synchronous + replication is mainly on the master. Named standbys must be directly + connected to the master; the master knows nothing about downstream + standby servers using cascaded replication. +

Setting synchronous_commit to remote_write will + cause each commit to wait for confirmation that the standby has received + the commit record and written it out to its own operating system, but not + for the data to be flushed to disk on the standby. This + setting provides a weaker guarantee of durability than on + does: the standby could lose the data in the event of an operating system + crash, though not a PostgreSQL crash. + However, it's a useful setting in practice + because it can decrease the response time for the transaction. + Data loss could only occur if both the primary and the standby crash and + the database of the primary gets corrupted at the same time. +

Users will stop waiting if a fast shutdown is requested. However, as + when using asynchronous replication, the server will not fully + shutdown until all outstanding WAL records are transferred to the currently + connected standby servers. +

25.2.7.2. Planning for Performance

Synchronous replication usually requires carefully planned and placed + standby servers to ensure applications perform acceptably. Waiting + doesn't utilize system resources, but transaction locks continue to be + held until the transfer is confirmed. As a result, incautious use of + synchronous replication will reduce performance for database + applications because of increased response times and higher contention. +

PostgreSQL allows the application developer + to specify the durability level required via replication. This can be + specified for the system overall, though it can also be specified for + specific users or connections, or even individual transactions. +

For example, an application workload might consist of: + 10% of changes are important customer details, while + 90% of changes are less important data that the business can more + easily survive if it is lost, such as chat messages between users. +

With synchronous replication options specified at the application level + (on the primary) we can offer synchronous replication for the most + important changes, without slowing down the bulk of the total workload. + Application level options are an important and practical tool for allowing + the benefits of synchronous replication for high performance applications. +

You should consider that the network bandwidth must be higher than + the rate of generation of WAL data. +

25.2.7.3. Planning for High Availability

Commits made when synchronous_commit is set to on + or remote_write will wait until the synchronous standby responds. The response + may never occur if the last, or only, standby should crash. +

The best solution for avoiding data loss is to ensure you don't lose + your last remaining synchronous standby. This can be achieved by naming multiple + potential synchronous standbys using synchronous_standby_names. + The first named standby will be used as the synchronous standby. Standbys + listed after this will take over the role of synchronous standby if the + first one should fail. +

When a standby first attaches to the primary, it will not yet be properly + synchronized. This is described as catchup mode. Once + the lag between standby and primary reaches zero for the first time + we move to real-time streaming state. + The catch-up duration may be long immediately after the standby has + been created. If the standby is shut down, then the catch-up period + will increase according to the length of time the standby has been down. + The standby is only able to become a synchronous standby + once it has reached streaming state. +

If primary restarts while commits are waiting for acknowledgement, those + waiting transactions will be marked fully committed once the primary + database recovers. + There is no way to be certain that all standbys have received all + outstanding WAL data at time of the crash of the primary. Some + transactions may not show as committed on the standby, even though + they show as committed on the primary. The guarantee we offer is that + the application will not receive explicit acknowledgement of the + successful commit of a transaction until the WAL data is known to be + safely received by the standby. +

If you really do lose your last standby server then you should disable + synchronous_standby_names and reload the configuration file + on the primary server. +

If the primary is isolated from remaining standby servers you should + fail over to the best candidate of those other remaining standby servers. +

If you need to re-create a standby server while transactions are + waiting, make sure that the commands pg_start_backup() and + pg_stop_backup() are run in a session with + synchronous_commit = off, otherwise those + requests will wait forever for the standby to appear. +


PrevHomeNext
Comparison of Different SolutionsUpFailover
\ No newline at end of file diff --git a/doc/src/sgml/html/xaggr.html b/doc/src/sgml/html/xaggr.html new file mode 100644 index 000000000..1071c91fa --- /dev/null +++ b/doc/src/sgml/html/xaggr.html @@ -0,0 +1,440 @@ + +User-defined Aggregates

35.10. User-defined Aggregates

Aggregate functions in PostgreSQL + are expressed in terms of state values + and state transition functions. + That is, an aggregate operates using a state value that is updated + as each successive input row is processed. + To define a new aggregate + function, one selects a data type for the state value, + an initial value for the state, and a state transition + function. The state transition function is just an + ordinary function that could also be used outside the + context of the aggregate. A final function + can also be specified, in case the desired result of the aggregate + is different from the data that needs to be kept in the running + state value. +

Thus, in addition to the argument and result data types seen by a user + of the aggregate, there is an internal state-value data type that + might be different from both the argument and result types. +

If we define an aggregate that does not use a final function, + we have an aggregate that computes a running function of + the column values from each row. sum is an + example of this kind of aggregate. sum starts at + zero and always adds the current row's value to + its running total. For example, if we want to make a sum + aggregate to work on a data type for complex numbers, + we only need the addition function for that data type. + The aggregate definition would be: + +

CREATE AGGREGATE sum (complex)
+(
+    sfunc = complex_add,
+    stype = complex,
+    initcond = '(0,0)'
+);
+
+SELECT sum(a) FROM test_complex;
+
+   sum
+-----------
+ (34,53.9)

+ + (Notice that we are relying on function overloading: there is more than + one aggregate named sum, but + PostgreSQL can figure out which kind + of sum applies to a column of type complex.) +

The above definition of sum will return zero (the initial + state condition) if there are no nonnull input values. + Perhaps we want to return null in that case instead — the SQL standard + expects sum to behave that way. We can do this simply by + omitting the initcond phrase, so that the initial state + condition is null. Ordinarily this would mean that the sfunc + would need to check for a null state-condition input. But for + sum and some other simple aggregates like + max and min, + it is sufficient to insert the first nonnull input value into + the state variable and then start applying the transition function + at the second nonnull input value. PostgreSQL + will do that automatically if the initial condition is null and + the transition function is marked "strict" (i.e., not to be called + for null inputs). +

Another bit of default behavior for a "strict" transition function + is that the previous state value is retained unchanged whenever a + null input value is encountered. Thus, null values are ignored. If you + need some other behavior for null inputs, do not declare your + transition function as strict; instead code it to test for null inputs and + do whatever is needed. +

avg (average) is a more complex example of an aggregate. + It requires + two pieces of running state: the sum of the inputs and the count + of the number of inputs. The final result is obtained by dividing + these quantities. Average is typically implemented by using an + array as the state value. For example, + the built-in implementation of avg(float8) + looks like: + +

CREATE AGGREGATE avg (float8)
+(
+    sfunc = float8_accum,
+    stype = float8[],
+    finalfunc = float8_avg,
+    initcond = '{0,0,0}'
+);

+ + (float8_accum requires a three-element array, not just + two elements, because it accumulates the sum of squares as well as + the sum and count of the inputs. This is so that it can be used for + some other aggregates besides avg.) +

Aggregate functions can use polymorphic + state transition functions or final functions, so that the same functions + can be used to implement multiple aggregates. + See Section 35.2.5 + for an explanation of polymorphic functions. + Going a step further, the aggregate function itself can be specified + with polymorphic input type(s) and state type, allowing a single + aggregate definition to serve for multiple input data types. + Here is an example of a polymorphic aggregate: + +

CREATE AGGREGATE array_accum (anyelement)
+(
+    sfunc = array_append,
+    stype = anyarray,
+    initcond = '{}'
+);

+ + Here, the actual state type for any aggregate call is the array type + having the actual input type as elements. The behavior of the aggregate + is to concatenate all the inputs into an array of that type. + (Note: the built-in aggregate array_agg provides similar + functionality, with better performance than this definition would have.) +

Here's the output using two different actual data types as arguments: + +

SELECT attrelid::regclass, array_accum(attname)
+    FROM pg_attribute
+    WHERE attnum > 0 AND attrelid = 'pg_tablespace'::regclass
+    GROUP BY attrelid;
+
+   attrelid    |              array_accum              
+---------------+---------------------------------------
+ pg_tablespace | {spcname,spcowner,spcacl,spcoptions}
+(1 row)
+
+SELECT attrelid::regclass, array_accum(atttypid::regtype)
+    FROM pg_attribute
+    WHERE attnum > 0 AND attrelid = 'pg_tablespace'::regclass
+    GROUP BY attrelid;
+
+   attrelid    |        array_accum        
+---------------+---------------------------
+ pg_tablespace | {name,oid,aclitem[],text[]}
+(1 row)

+

A function written in C can detect that it is being called as an + aggregate transition or final function by calling + AggCheckCallContext, for example: +

if (AggCheckCallContext(fcinfo, NULL))

+ One reason for checking this is that when it is true for a transition + function, the first input + must be a temporary transition value and can therefore safely be modified + in-place rather than allocating a new copy. + See int8inc() for an example. + (This is the only + case where it is safe for a function to modify a pass-by-reference input. + In particular, aggregate final functions should not modify their inputs in + any case, because in some cases they will be re-executed on the same + final transition value.) +

For further details see the + CREATE AGGREGATE + command. +


PrevHomeNext
C-Language FunctionsUpUser-defined Types
\ No newline at end of file diff --git a/doc/src/sgml/html/xfunc-c.html b/doc/src/sgml/html/xfunc-c.html new file mode 100644 index 000000000..f695e6154 --- /dev/null +++ b/doc/src/sgml/html/xfunc-c.html @@ -0,0 +1,3835 @@ + +C-Language Functions

35.9. C-Language Functions

User-defined functions can be written in C (or a language that can + be made compatible with C, such as C++). Such functions are + compiled into dynamically loadable objects (also called shared + libraries) and are loaded by the server on demand. The dynamic + loading feature is what distinguishes "C language" functions + from "internal" functions — the actual coding conventions + are essentially the same for both. (Hence, the standard internal + function library is a rich source of coding examples for user-defined + C functions.) +

Two different calling conventions are currently used for C functions. + The newer "version 1" calling convention is indicated by writing + a PG_FUNCTION_INFO_V1() macro call for the function, + as illustrated below. Lack of such a macro indicates an old-style + ("version 0") function. The language name specified in CREATE FUNCTION + is C in either case. Old-style functions are now deprecated + because of portability problems and lack of functionality, but they + are still supported for compatibility reasons. +

35.9.1. Dynamic Loading

The first time a user-defined function in a particular + loadable object file is called in a session, + the dynamic loader loads that object file into memory so that the + function can be called. The CREATE FUNCTION + for a user-defined C function must therefore specify two pieces of + information for the function: the name of the loadable + object file, and the C name (link symbol) of the specific function to call + within that object file. If the C name is not explicitly specified then + it is assumed to be the same as the SQL function name. +

The following algorithm is used to locate the shared object file + based on the name given in the CREATE FUNCTION + command: + +

  1. If the name is an absolute path, the given file is loaded. +

  2. If the name starts with the string $libdir, + that part is replaced by the PostgreSQL package + library directory + name, which is determined at build time. +

  3. If the name does not contain a directory part, the file is + searched for in the path specified by the configuration variable + dynamic_library_path. +

  4. Otherwise (the file was not found in the path, or it contains a + non-absolute directory part), the dynamic loader will try to + take the name as given, which will most likely fail. (It is + unreliable to depend on the current working directory.) +

+ + If this sequence does not work, the platform-specific shared + library file name extension (often .so) is + appended to the given name and this sequence is tried again. If + that fails as well, the load will fail. +

It is recommended to locate shared libraries either relative to + $libdir or through the dynamic library path. + This simplifies version upgrades if the new installation is at a + different location. The actual directory that + $libdir stands for can be found out with the + command pg_config --pkglibdir. +

The user ID the PostgreSQL server runs + as must be able to traverse the path to the file you intend to + load. Making the file or a higher-level directory not readable + and/or not executable by the postgres + user is a common mistake. +

In any case, the file name that is given in the + CREATE FUNCTION command is recorded literally + in the system catalogs, so if the file needs to be loaded again + the same procedure is applied. +

Note: PostgreSQL will not compile a C function + automatically. The object file must be compiled before it is referenced + in a CREATE + FUNCTION command. See Section 35.9.6 for additional + information. +

To ensure that a dynamically loaded object file is not loaded into an + incompatible server, PostgreSQL checks that the + file contains a "magic block" with the appropriate contents. + This allows the server to detect obvious incompatibilities, such as code + compiled for a different major version of + PostgreSQL. A magic block is required as of + PostgreSQL 8.2. To include a magic block, + write this in one (and only one) of the module source files, after having + included the header fmgr.h: + +

#ifdef PG_MODULE_MAGIC
+PG_MODULE_MAGIC;
+#endif

+ + The #ifdef test can be omitted if the code doesn't + need to compile against pre-8.2 PostgreSQL + releases. +

After it is used for the first time, a dynamically loaded object + file is retained in memory. Future calls in the same session to + the function(s) in that file will only incur the small overhead of + a symbol table lookup. If you need to force a reload of an object + file, for example after recompiling it, begin a fresh session. +

Optionally, a dynamically loaded file can contain initialization and + finalization functions. If the file includes a function named + _PG_init, that function will be called immediately after + loading the file. The function receives no parameters and should + return void. If the file includes a function named + _PG_fini, that function will be called immediately before + unloading the file. Likewise, the function receives no parameters and + should return void. Note that _PG_fini will only be called + during an unload of the file, not during process termination. + (Presently, unloads are disabled and will never occur, but this may + change in the future.) +

35.9.2. Base Types in C-Language Functions

To know how to write C-language functions, you need to know how + PostgreSQL internally represents base + data types and how they can be passed to and from functions. + Internally, PostgreSQL regards a base + type as a "blob of memory". The user-defined + functions that you define over a type in turn define the way that + PostgreSQL can operate on it. That + is, PostgreSQL will only store and + retrieve the data from disk and use your user-defined functions + to input, process, and output the data. +

Base types can have one of three internal formats: + +

  • pass by value, fixed-length +

  • pass by reference, fixed-length +

  • pass by reference, variable-length +

+

By-value types can only be 1, 2, or 4 bytes in length + (also 8 bytes, if sizeof(Datum) is 8 on your machine). + You should be careful to define your types such that they will be the + same size (in bytes) on all architectures. For example, the + long type is dangerous because it is 4 bytes on some + machines and 8 bytes on others, whereas int type is 4 bytes + on most Unix machines. A reasonable implementation of the + int4 type on Unix machines might be: + +

/* 4-byte integer, passed by value */
+typedef int int4;

+

On the other hand, fixed-length types of any size can + be passed by-reference. For example, here is a sample + implementation of a PostgreSQL type: + +

/* 16-byte structure, passed by reference */
+typedef struct
+{
+    double  x, y;
+} Point;

+ + Only pointers to such types can be used when passing + them in and out of PostgreSQL functions. + To return a value of such a type, allocate the right amount of + memory with palloc, fill in the allocated memory, + and return a pointer to it. (Also, if you just want to return the + same value as one of your input arguments that's of the same data type, + you can skip the extra palloc and just return the + pointer to the input value.) +

Finally, all variable-length types must also be passed + by reference. All variable-length types must begin + with an opaque length field of exactly 4 bytes, which will be set + by SET_VARSIZE; never set this field directly! All data to + be stored within that type must be located in the memory + immediately following that length field. The + length field contains the total length of the structure, + that is, it includes the size of the length field + itself. +

Another important point is to avoid leaving any uninitialized bits + within data type values; for example, take care to zero out any + alignment padding bytes that might be present in structs. Without + this, logically-equivalent constants of your data type might be + seen as unequal by the planner, leading to inefficient (though not + incorrect) plans. +

Warning

Never modify the contents of a pass-by-reference input + value. If you do so you are likely to corrupt on-disk data, since + the pointer you are given might point directly into a disk buffer. + The sole exception to this rule is explained in + Section 35.10. +

As an example, we can define the type text as + follows: + +

typedef struct {
+    int4 length;
+    char data[1];
+} text;

+ + Obviously, the data field declared here is not long enough to hold + all possible strings. Since it's impossible to declare a variable-size + structure in C, we rely on the knowledge that the + C compiler won't range-check array subscripts. We + just allocate the necessary amount of space and then access the array as + if it were declared the right length. (This is a common trick, which + you can read about in many textbooks about C.) +

When manipulating + variable-length types, we must be careful to allocate + the correct amount of memory and set the length field correctly. + For example, if we wanted to store 40 bytes in a text + structure, we might use a code fragment like this: + +

#include "postgres.h"
+...
+char buffer[40]; /* our source data */
+...
+text *destination = (text *) palloc(VARHDRSZ + 40);
+SET_VARSIZE(destination, VARHDRSZ + 40);
+memcpy(destination->data, buffer, 40);
+...

+ + VARHDRSZ is the same as sizeof(int32), but + it's considered good style to use the macro VARHDRSZ + to refer to the size of the overhead for a variable-length type. + Also, the length field must be set using the + SET_VARSIZE macro, not by simple assignment. +

Table 35-1 specifies which C type + corresponds to which SQL type when writing a C-language function + that uses a built-in type of PostgreSQL. + The "Defined In" column gives the header file that + needs to be included to get the type definition. (The actual + definition might be in a different file that is included by the + listed file. It is recommended that users stick to the defined + interface.) Note that you should always include + postgres.h first in any source file, because + it declares a number of things that you will need anyway. +

Table 35-1. Equivalent C Types for Built-in SQL Types

SQL Type + C Type + Defined In +
abstimeAbsoluteTimeutils/nabstime.h
booleanboolpostgres.h (maybe compiler built-in)
boxBOX*utils/geo_decls.h
byteabytea*postgres.h
"char"char(compiler built-in)
characterBpChar*postgres.h
cidCommandIdpostgres.h
dateDateADTutils/date.h
smallint (int2)int2 or int16postgres.h
int2vectorint2vector*postgres.h
integer (int4)int4 or int32postgres.h
real (float4)float4*postgres.h
double precision (float8)float8*postgres.h
intervalInterval*datatype/timestamp.h
lsegLSEG*utils/geo_decls.h
nameNamepostgres.h
oidOidpostgres.h
oidvectoroidvector*postgres.h
pathPATH*utils/geo_decls.h
pointPOINT*utils/geo_decls.h
regprocregprocpostgres.h
reltimeRelativeTimeutils/nabstime.h
texttext*postgres.h
tidItemPointerstorage/itemptr.h
timeTimeADTutils/date.h
time with time zoneTimeTzADTutils/date.h
timestampTimestamp*datatype/timestamp.h
tintervalTimeIntervalutils/nabstime.h
varcharVarChar*postgres.h
xidTransactionIdpostgres.h

Now that we've gone over all of the possible structures + for base types, we can show some examples of real functions. +

35.9.3. Version 0 Calling Conventions

We present the "old style" calling convention first — although + this approach is now deprecated, it's easier to get a handle on + initially. In the version-0 method, the arguments and result + of the C function are just declared in normal C style, but being + careful to use the C representation of each SQL data type as shown + above. +

Here are some examples: + +

#include "postgres.h"
+#include <string.h>
+#include "utils/geo_decls.h"
+
+#ifdef PG_MODULE_MAGIC
+PG_MODULE_MAGIC;
+#endif
+
+/* by value */
+
+int
+add_one(int arg)
+{
+    return arg + 1;
+}
+
+/* by reference, fixed length */
+
+float8 *
+add_one_float8(float8 *arg)
+{
+    float8    *result = (float8 *) palloc(sizeof(float8));
+
+    *result = *arg + 1.0;
+
+    return result;
+}
+
+Point *
+makepoint(Point *pointx, Point *pointy)
+{
+    Point     *new_point = (Point *) palloc(sizeof(Point));
+
+    new_point->x = pointx->x;
+    new_point->y = pointy->y;
+
+    return new_point;
+}
+
+/* by reference, variable length */
+
+text *
+copytext(text *t)
+{
+    /*
+     * VARSIZE is the total size of the struct in bytes.
+     */
+    text *new_t = (text *) palloc(VARSIZE(t));
+    SET_VARSIZE(new_t, VARSIZE(t));
+    /*
+     * VARDATA is a pointer to the data region of the struct.
+     */
+    memcpy((void *) VARDATA(new_t), /* destination */
+           (void *) VARDATA(t),     /* source */
+           VARSIZE(t) - VARHDRSZ);  /* how many bytes */
+    return new_t;
+}
+
+text *
+concat_text(text *arg1, text *arg2)
+{
+    int32 new_text_size = VARSIZE(arg1) + VARSIZE(arg2) - VARHDRSZ;
+    text *new_text = (text *) palloc(new_text_size);
+
+    SET_VARSIZE(new_text, new_text_size);
+    memcpy(VARDATA(new_text), VARDATA(arg1), VARSIZE(arg1) - VARHDRSZ);
+    memcpy(VARDATA(new_text) + (VARSIZE(arg1) - VARHDRSZ),
+           VARDATA(arg2), VARSIZE(arg2) - VARHDRSZ);
+    return new_text;
+}

+

Supposing that the above code has been prepared in file + funcs.c and compiled into a shared object, + we could define the functions to PostgreSQL + with commands like this: + +

CREATE FUNCTION add_one(integer) RETURNS integer
+     AS 'DIRECTORY/funcs', 'add_one'
+     LANGUAGE C STRICT;
+
+-- note overloading of SQL function name "add_one"
+CREATE FUNCTION add_one(double precision) RETURNS double precision
+     AS 'DIRECTORY/funcs', 'add_one_float8'
+     LANGUAGE C STRICT;
+
+CREATE FUNCTION makepoint(point, point) RETURNS point
+     AS 'DIRECTORY/funcs', 'makepoint'
+     LANGUAGE C STRICT;
+
+CREATE FUNCTION copytext(text) RETURNS text
+     AS 'DIRECTORY/funcs', 'copytext'
+     LANGUAGE C STRICT;
+
+CREATE FUNCTION concat_text(text, text) RETURNS text
+     AS 'DIRECTORY/funcs', 'concat_text'
+     LANGUAGE C STRICT;

+

Here, DIRECTORY stands for the + directory of the shared library file (for instance the + PostgreSQL tutorial directory, which + contains the code for the examples used in this section). + (Better style would be to use just 'funcs' in the + AS clause, after having added + DIRECTORY to the search path. In any + case, we can omit the system-specific extension for a shared + library, commonly .so or + .sl.) +

Notice that we have specified the functions as "strict", + meaning that + the system should automatically assume a null result if any input + value is null. By doing this, we avoid having to check for null inputs + in the function code. Without this, we'd have to check for null values + explicitly, by checking for a null pointer for each + pass-by-reference argument. (For pass-by-value arguments, we don't + even have a way to check!) +

Although this calling convention is simple to use, + it is not very portable; on some architectures there are problems + with passing data types that are smaller than int this way. Also, there is + no simple way to return a null result, nor to cope with null arguments + in any way other than making the function strict. The version-1 + convention, presented next, overcomes these objections. +

35.9.4. Version 1 Calling Conventions

The version-1 calling convention relies on macros to suppress most + of the complexity of passing arguments and results. The C declaration + of a version-1 function is always: +

Datum funcname(PG_FUNCTION_ARGS)

+ In addition, the macro call: +

PG_FUNCTION_INFO_V1(funcname);

+ must appear in the same source file. (Conventionally, it's + written just before the function itself.) This macro call is not + needed for internal-language functions, since + PostgreSQL assumes that all internal functions + use the version-1 convention. It is, however, required for + dynamically-loaded functions. +

In a version-1 function, each actual argument is fetched using a + PG_GETARG_xxx() + macro that corresponds to the argument's data type, and the + result is returned using a + PG_RETURN_xxx() + macro for the return type. + PG_GETARG_xxx() + takes as its argument the number of the function argument to + fetch, where the count starts at 0. + PG_RETURN_xxx() + takes as its argument the actual value to return. +

Here we show the same functions as above, coded in version-1 style: + +

#include "postgres.h"
+#include <string.h>
+#include "fmgr.h"
+#include "utils/geo_decls.h"
+
+#ifdef PG_MODULE_MAGIC
+PG_MODULE_MAGIC;
+#endif
+
+/* by value */
+
+PG_FUNCTION_INFO_V1(add_one);
+
+Datum
+add_one(PG_FUNCTION_ARGS)
+{
+    int32   arg = PG_GETARG_INT32(0);
+
+    PG_RETURN_INT32(arg + 1);
+}
+
+/* by reference, fixed length */
+
+PG_FUNCTION_INFO_V1(add_one_float8);
+
+Datum
+add_one_float8(PG_FUNCTION_ARGS)
+{
+    /* The macros for FLOAT8 hide its pass-by-reference nature. */
+    float8   arg = PG_GETARG_FLOAT8(0);
+
+    PG_RETURN_FLOAT8(arg + 1.0);
+}
+
+PG_FUNCTION_INFO_V1(makepoint);
+
+Datum
+makepoint(PG_FUNCTION_ARGS)
+{
+    /* Here, the pass-by-reference nature of Point is not hidden. */
+    Point     *pointx = PG_GETARG_POINT_P(0);
+    Point     *pointy = PG_GETARG_POINT_P(1);
+    Point     *new_point = (Point *) palloc(sizeof(Point));
+
+    new_point->x = pointx->x;
+    new_point->y = pointy->y;
+
+    PG_RETURN_POINT_P(new_point);
+}
+
+/* by reference, variable length */
+
+PG_FUNCTION_INFO_V1(copytext);
+
+Datum
+copytext(PG_FUNCTION_ARGS)
+{
+    text     *t = PG_GETARG_TEXT_P(0);
+    /*
+     * VARSIZE is the total size of the struct in bytes.
+     */
+    text     *new_t = (text *) palloc(VARSIZE(t));
+    SET_VARSIZE(new_t, VARSIZE(t));
+    /*
+     * VARDATA is a pointer to the data region of the struct.
+     */
+    memcpy((void *) VARDATA(new_t), /* destination */
+           (void *) VARDATA(t),     /* source */
+           VARSIZE(t) - VARHDRSZ);  /* how many bytes */
+    PG_RETURN_TEXT_P(new_t);
+}
+
+PG_FUNCTION_INFO_V1(concat_text);
+
+Datum
+concat_text(PG_FUNCTION_ARGS)
+{
+    text  *arg1 = PG_GETARG_TEXT_P(0);
+    text  *arg2 = PG_GETARG_TEXT_P(1);
+    int32 new_text_size = VARSIZE(arg1) + VARSIZE(arg2) - VARHDRSZ;
+    text *new_text = (text *) palloc(new_text_size);
+
+    SET_VARSIZE(new_text, new_text_size);
+    memcpy(VARDATA(new_text), VARDATA(arg1), VARSIZE(arg1) - VARHDRSZ);
+    memcpy(VARDATA(new_text) + (VARSIZE(arg1) - VARHDRSZ),
+           VARDATA(arg2), VARSIZE(arg2) - VARHDRSZ);
+    PG_RETURN_TEXT_P(new_text);
+}

+

The CREATE FUNCTION commands are the same as + for the version-0 equivalents. +

At first glance, the version-1 coding conventions might appear to + be just pointless obscurantism. They do, however, offer a number + of improvements, because the macros can hide unnecessary detail. + An example is that in coding add_one_float8, we no longer need to + be aware that float8 is a pass-by-reference type. Another + example is that the GETARG macros for variable-length types allow + for more efficient fetching of "toasted" (compressed or + out-of-line) values. +

One big improvement in version-1 functions is better handling of null + inputs and results. The macro PG_ARGISNULL(n) + allows a function to test whether each input is null. (Of course, doing + this is only necessary in functions not declared "strict".) + As with the + PG_GETARG_xxx() macros, + the input arguments are counted beginning at zero. Note that one + should refrain from executing + PG_GETARG_xxx() until + one has verified that the argument isn't null. + To return a null result, execute PG_RETURN_NULL(); + this works in both strict and nonstrict functions. +

Other options provided in the new-style interface are two + variants of the + PG_GETARG_xxx() + macros. The first of these, + PG_GETARG_xxx_COPY(), + guarantees to return a copy of the specified argument that is + safe for writing into. (The normal macros will sometimes return a + pointer to a value that is physically stored in a table, which + must not be written to. Using the + PG_GETARG_xxx_COPY() + macros guarantees a writable result.) + The second variant consists of the + PG_GETARG_xxx_SLICE() + macros which take three arguments. The first is the number of the + function argument (as above). The second and third are the offset and + length of the segment to be returned. Offsets are counted from + zero, and a negative length requests that the remainder of the + value be returned. These macros provide more efficient access to + parts of large values in the case where they have storage type + "external". (The storage type of a column can be specified using + ALTER TABLE tablename ALTER + COLUMN colname SET STORAGE + storagetype. storagetype is one of + plain, external, extended, + or main.) +

Finally, the version-1 function call conventions make it possible + to return set results (Section 35.9.9) and + implement trigger functions (Chapter 36) and + procedural-language call handlers (Chapter 49). Version-1 code is also more + portable than version-0, because it does not break restrictions + on function call protocol in the C standard. For more details + see src/backend/utils/fmgr/README in the + source distribution. +

35.9.5. Writing Code

Before we turn to the more advanced topics, we should discuss + some coding rules for PostgreSQL + C-language functions. While it might be possible to load functions + written in languages other than C into + PostgreSQL, this is usually difficult + (when it is possible at all) because other languages, such as + C++, FORTRAN, or Pascal often do not follow the same calling + convention as C. That is, other languages do not pass argument + and return values between functions in the same way. For this + reason, we will assume that your C-language functions are + actually written in C. +

The basic rules for writing and building C functions are as follows: + +

  • Use pg_config + --includedir-server + to find out where the PostgreSQL server header + files are installed on your system (or the system that your + users will be running on). +

  • Compiling and linking your code so that it can be dynamically + loaded into PostgreSQL always + requires special flags. See Section 35.9.6 for a + detailed explanation of how to do it for your particular + operating system. +

  • Remember to define a "magic block" for your shared library, + as described in Section 35.9.1. +

  • When allocating memory, use the + PostgreSQL functions + palloc and pfree + instead of the corresponding C library functions + malloc and free. + The memory allocated by palloc will be + freed automatically at the end of each transaction, preventing + memory leaks. +

  • Always zero the bytes of your structures using memset + (or allocate them with palloc0 in the first place). + Even if you assign to each field of your structure, there might be + alignment padding (holes in the structure) that contain + garbage values. Without this, it's difficult to + support hash indexes or hash joins, as you must pick out only + the significant bits of your data structure to compute a hash. + The planner also sometimes relies on comparing constants via + bitwise equality, so you can get undesirable planning results if + logically-equivalent values aren't bitwise equal. +

  • Most of the internal PostgreSQL + types are declared in postgres.h, while + the function manager interfaces + (PG_FUNCTION_ARGS, etc.) are in + fmgr.h, so you will need to include at + least these two files. For portability reasons it's best to + include postgres.h first, + before any other system or user header files. Including + postgres.h will also include + elog.h and palloc.h + for you. +

  • Symbol names defined within object files must not conflict + with each other or with symbols defined in the + PostgreSQL server executable. You + will have to rename your functions or variables if you get + error messages to this effect. +

+

35.9.6. Compiling and Linking Dynamically-loaded Functions

Before you are able to use your + PostgreSQL extension functions written in + C, they must be compiled and linked in a special way to produce a + file that can be dynamically loaded by the server. To be precise, a + shared library needs to be + created. + +

For information beyond what is contained in this section + you should read the documentation of your + operating system, in particular the manual pages for the C compiler, + cc, and the link editor, ld. + In addition, the PostgreSQL source code + contains several working examples in the + contrib directory. If you rely on these + examples you will make your modules dependent on the availability + of the PostgreSQL source code, however. +

Creating shared libraries is generally analogous to linking + executables: first the source files are compiled into object files, + then the object files are linked together. The object files need to + be created as position-independent code + (PIC), which + conceptually means that they can be placed at an arbitrary location + in memory when they are loaded by the executable. (Object files + intended for executables are usually not compiled that way.) The + command to link a shared library contains special flags to + distinguish it from linking an executable (at least in theory + — on some systems the practice is much uglier). +

In the following examples we assume that your source code is in a + file foo.c and we will create a shared library + foo.so. The intermediate object file will be + called foo.o unless otherwise noted. A shared + library can contain more than one object file, but we only use one + here. +

FreeBSD

The compiler flag to create PIC is + -fpic. To create shared libraries the compiler + flag is -shared. +

gcc -fpic -c foo.c
+gcc -shared -o foo.so foo.o

+ This is applicable as of version 3.0 of + FreeBSD. +

HP-UX

The compiler flag of the system compiler to create + PIC is +z. When using + GCC it's -fpic. The + linker flag for shared libraries is -b. So: +

cc +z -c foo.c

+ or: +

gcc -fpic -c foo.c

+ and then: +

ld -b -o foo.sl foo.o

+ HP-UX uses the extension + .sl for shared libraries, unlike most other + systems. +

IRIX

PIC is the default, no special compiler + options are necessary. The linker option to produce shared + libraries is -shared. +

cc -c foo.c
+ld -shared -o foo.so foo.o

+

Linux

The compiler flag to create PIC is + -fpic. On some platforms in some situations + -fPIC must be used if -fpic + does not work. Refer to the GCC manual for more information. + The compiler flag to create a shared library is + -shared. A complete example looks like this: +

cc -fpic -c foo.c
+cc -shared -o foo.so foo.o

+

Mac OS X

Here is an example. It assumes the developer tools are installed. +

cc -c foo.c
+cc -bundle -flat_namespace -undefined suppress -o foo.so foo.o

+

NetBSD

The compiler flag to create PIC is + -fpic. For ELF systems, the + compiler with the flag -shared is used to link + shared libraries. On the older non-ELF systems, ld + -Bshareable is used. +

gcc -fpic -c foo.c
+gcc -shared -o foo.so foo.o

+

OpenBSD

The compiler flag to create PIC is + -fpic. ld -Bshareable is + used to link shared libraries. +

gcc -fpic -c foo.c
+ld -Bshareable -o foo.so foo.o

+

Solaris

The compiler flag to create PIC is + -KPIC with the Sun compiler and + -fpic with GCC. To + link shared libraries, the compiler option is + -G with either compiler or alternatively + -shared with GCC. +

cc -KPIC -c foo.c
+cc -G -o foo.so foo.o

+ or +

gcc -fpic -c foo.c
+gcc -G -o foo.so foo.o

+

Tru64 UNIX

PIC is the default, so the compilation command + is the usual one. ld with special options is + used to do the linking. +

cc -c foo.c
+ld -shared -expect_unresolved '*' -o foo.so foo.o

+ The same procedure is used with GCC instead of the system + compiler; no special options are required. +

UnixWare

The compiler flag to create PIC is -K + PIC with the SCO compiler and -fpic + with GCC. To link shared libraries, + the compiler option is -G with the SCO compiler + and -shared with + GCC. +

cc -K PIC -c foo.c
+cc -G -o foo.so foo.o

+ or +

gcc -fpic -c foo.c
+gcc -shared -o foo.so foo.o

+

Tip: If this is too complicated for you, you should consider using + GNU Libtool, + which hides the platform differences behind a uniform interface. +

The resulting shared library file can then be loaded into + PostgreSQL. When specifying the file name + to the CREATE FUNCTION command, one must give it + the name of the shared library file, not the intermediate object file. + Note that the system's standard shared-library extension (usually + .so or .sl) can be omitted from + the CREATE FUNCTION command, and normally should + be omitted for best portability. +

Refer back to Section 35.9.1 about where the + server expects to find the shared library files. +

35.9.7. Composite-type Arguments

Composite types do not have a fixed layout like C structures. + Instances of a composite type can contain null fields. In + addition, composite types that are part of an inheritance + hierarchy can have different fields than other members of the + same inheritance hierarchy. Therefore, + PostgreSQL provides a function + interface for accessing fields of composite types from C. +

Suppose we want to write a function to answer the query: + +

SELECT name, c_overpaid(emp, 1500) AS overpaid
+    FROM emp
+    WHERE name = 'Bill' OR name = 'Sam';

+ + Using call conventions version 0, we can define + c_overpaid as: + +

#include "postgres.h"
+#include "executor/executor.h"  /* for GetAttributeByName() */
+
+#ifdef PG_MODULE_MAGIC
+PG_MODULE_MAGIC;
+#endif
+
+bool
+c_overpaid(HeapTupleHeader t, /* the current row of emp */
+           int32 limit)
+{
+    bool isnull;
+    int32 salary;
+
+    salary = DatumGetInt32(GetAttributeByName(t, "salary", &isnull));
+    if (isnull)
+        return false;
+    return salary > limit;
+}

+ + In version-1 coding, the above would look like this: + +

#include "postgres.h"
+#include "executor/executor.h"  /* for GetAttributeByName() */
+
+#ifdef PG_MODULE_MAGIC
+PG_MODULE_MAGIC;
+#endif
+
+PG_FUNCTION_INFO_V1(c_overpaid);
+
+Datum
+c_overpaid(PG_FUNCTION_ARGS)
+{
+    HeapTupleHeader  t = PG_GETARG_HEAPTUPLEHEADER(0);
+    int32            limit = PG_GETARG_INT32(1);
+    bool isnull;
+    Datum salary;
+
+    salary = GetAttributeByName(t, "salary", &isnull);
+    if (isnull)
+        PG_RETURN_BOOL(false);
+    /* Alternatively, we might prefer to do PG_RETURN_NULL() for null salary. */
+
+    PG_RETURN_BOOL(DatumGetInt32(salary) > limit);
+}

+

GetAttributeByName is the + PostgreSQL system function that + returns attributes out of the specified row. It has + three arguments: the argument of type HeapTupleHeader passed + into + the function, the name of the desired attribute, and a + return parameter that tells whether the attribute + is null. GetAttributeByName returns a Datum + value that you can convert to the proper data type by using the + appropriate DatumGetXXX() + macro. Note that the return value is meaningless if the null flag is + set; always check the null flag before trying to do anything with the + result. +

There is also GetAttributeByNum, which selects + the target attribute by column number instead of name. +

The following command declares the function + c_overpaid in SQL: + +

CREATE FUNCTION c_overpaid(emp, integer) RETURNS boolean
+    AS 'DIRECTORY/funcs', 'c_overpaid'
+    LANGUAGE C STRICT;

+ + Notice we have used STRICT so that we did not have to + check whether the input arguments were NULL. +

35.9.8. Returning Rows (Composite Types)

To return a row or composite-type value from a C-language + function, you can use a special API that provides macros and + functions to hide most of the complexity of building composite + data types. To use this API, the source file must include: +

#include "funcapi.h"

+

There are two ways you can build a composite data value (henceforth + a "tuple"): you can build it from an array of Datum values, + or from an array of C strings that can be passed to the input + conversion functions of the tuple's column data types. In either + case, you first need to obtain or construct a TupleDesc + descriptor for the tuple structure. When working with Datums, you + pass the TupleDesc to BlessTupleDesc, + and then call heap_form_tuple for each row. When working + with C strings, you pass the TupleDesc to + TupleDescGetAttInMetadata, and then call + BuildTupleFromCStrings for each row. In the case of a + function returning a set of tuples, the setup steps can all be done + once during the first call of the function. +

Several helper functions are available for setting up the needed + TupleDesc. The recommended way to do this in most + functions returning composite values is to call: +

TypeFuncClass get_call_result_type(FunctionCallInfo fcinfo,
+                                   Oid *resultTypeId,
+                                   TupleDesc *resultTupleDesc)

+ passing the same fcinfo struct passed to the calling function + itself. (This of course requires that you use the version-1 + calling conventions.) resultTypeId can be specified + as NULL or as the address of a local variable to receive the + function's result type OID. resultTupleDesc should be the + address of a local TupleDesc variable. Check that the + result is TYPEFUNC_COMPOSITE; if so, + resultTupleDesc has been filled with the needed + TupleDesc. (If it is not, you can report an error along + the lines of "function returning record called in context that + cannot accept type record".) +

Tip: get_call_result_type can resolve the actual type of a + polymorphic function result; so it is useful in functions that return + scalar polymorphic results, not only functions that return composites. + The resultTypeId output is primarily useful for functions + returning polymorphic scalars. +

Note: get_call_result_type has a sibling + get_expr_result_type, which can be used to resolve the + expected output type for a function call represented by an expression + tree. This can be used when trying to determine the result type from + outside the function itself. There is also + get_func_result_type, which can be used when only the + function's OID is available. However these functions are not able + to deal with functions declared to return record, and + get_func_result_type cannot resolve polymorphic types, + so you should preferentially use get_call_result_type. +

Older, now-deprecated functions for obtaining + TupleDescs are: +

TupleDesc RelationNameGetTupleDesc(const char *relname)

+ to get a TupleDesc for the row type of a named relation, + and: +

TupleDesc TypeGetTupleDesc(Oid typeoid, List *colaliases)

+ to get a TupleDesc based on a type OID. This can + be used to get a TupleDesc for a base or + composite type. It will not work for a function that returns + record, however, and it cannot resolve polymorphic + types. +

Once you have a TupleDesc, call: +

TupleDesc BlessTupleDesc(TupleDesc tupdesc)

+ if you plan to work with Datums, or: +

AttInMetadata *TupleDescGetAttInMetadata(TupleDesc tupdesc)

+ if you plan to work with C strings. If you are writing a function + returning set, you can save the results of these functions in the + FuncCallContext structure — use the + tuple_desc or attinmeta field + respectively. +

When working with Datums, use: +

HeapTuple heap_form_tuple(TupleDesc tupdesc, Datum *values, bool *isnull)

+ to build a HeapTuple given user data in Datum form. +

When working with C strings, use: +

HeapTuple BuildTupleFromCStrings(AttInMetadata *attinmeta, char **values)

+ to build a HeapTuple given user data + in C string form. values is an array of C strings, + one for each attribute of the return row. Each C string should be in + the form expected by the input function of the attribute data + type. In order to return a null value for one of the attributes, + the corresponding pointer in the values array + should be set to NULL. This function will need to + be called again for each row you return. +

Once you have built a tuple to return from your function, it + must be converted into a Datum. Use: +

HeapTupleGetDatum(HeapTuple tuple)

+ to convert a HeapTuple into a valid Datum. This + Datum can be returned directly if you intend to return + just a single row, or it can be used as the current return value + in a set-returning function. +

An example appears in the next section. +

35.9.9. Returning Sets

There is also a special API that provides support for returning + sets (multiple rows) from a C-language function. A set-returning + function must follow the version-1 calling conventions. Also, + source files must include funcapi.h, as + above. +

A set-returning function (SRF) is called + once for each item it returns. The SRF must + therefore save enough state to remember what it was doing and + return the next item on each call. + The structure FuncCallContext is provided to help + control this process. Within a function, fcinfo->flinfo->fn_extra + is used to hold a pointer to FuncCallContext + across calls. +

typedef struct
+{
+    /*
+     * Number of times we've been called before
+     *
+     * call_cntr is initialized to 0 for you by SRF_FIRSTCALL_INIT(), and
+     * incremented for you every time SRF_RETURN_NEXT() is called.
+     */
+    uint32 call_cntr;
+
+    /*
+     * OPTIONAL maximum number of calls
+     *
+     * max_calls is here for convenience only and setting it is optional.
+     * If not set, you must provide alternative means to know when the
+     * function is done.
+     */
+    uint32 max_calls;
+
+    /*
+     * OPTIONAL pointer to result slot
+     *
+     * This is obsolete and only present for backward compatibility, viz,
+     * user-defined SRFs that use the deprecated TupleDescGetSlot().
+     */
+    TupleTableSlot *slot;
+
+    /*
+     * OPTIONAL pointer to miscellaneous user-provided context information
+     *
+     * user_fctx is for use as a pointer to your own data to retain
+     * arbitrary context information between calls of your function.
+     */
+    void *user_fctx;
+
+    /*
+     * OPTIONAL pointer to struct containing attribute type input metadata
+     *
+     * attinmeta is for use when returning tuples (i.e., composite data types)
+     * and is not used when returning base data types. It is only needed
+     * if you intend to use BuildTupleFromCStrings() to create the return
+     * tuple.
+     */
+    AttInMetadata *attinmeta;
+
+    /*
+     * memory context used for structures that must live for multiple calls
+     *
+     * multi_call_memory_ctx is set by SRF_FIRSTCALL_INIT() for you, and used
+     * by SRF_RETURN_DONE() for cleanup. It is the most appropriate memory
+     * context for any memory that is to be reused across multiple calls
+     * of the SRF.
+     */
+    MemoryContext multi_call_memory_ctx;
+
+    /*
+     * OPTIONAL pointer to struct containing tuple description
+     *
+     * tuple_desc is for use when returning tuples (i.e., composite data types)
+     * and is only needed if you are going to build the tuples with
+     * heap_form_tuple() rather than with BuildTupleFromCStrings().  Note that
+     * the TupleDesc pointer stored here should usually have been run through
+     * BlessTupleDesc() first.
+     */
+    TupleDesc tuple_desc;
+
+} FuncCallContext;

+

An SRF uses several functions and macros that + automatically manipulate the FuncCallContext + structure (and expect to find it via fn_extra). Use: +

SRF_IS_FIRSTCALL()

+ to determine if your function is being called for the first or a + subsequent time. On the first call (only) use: +

SRF_FIRSTCALL_INIT()

+ to initialize the FuncCallContext. On every function call, + including the first, use: +

SRF_PERCALL_SETUP()

+ to properly set up for using the FuncCallContext + and clearing any previously returned data left over from the + previous pass. +

If your function has data to return, use: +

SRF_RETURN_NEXT(funcctx, result)

+ to return it to the caller. (result must be of type + Datum, either a single value or a tuple prepared as + described above.) Finally, when your function is finished + returning data, use: +

SRF_RETURN_DONE(funcctx)

+ to clean up and end the SRF. +

The memory context that is current when the SRF is called is + a transient context that will be cleared between calls. This means + that you do not need to call pfree on everything + you allocated using palloc; it will go away anyway. However, if you want to allocate + any data structures to live across calls, you need to put them somewhere + else. The memory context referenced by + multi_call_memory_ctx is a suitable location for any + data that needs to survive until the SRF is finished running. In most + cases, this means that you should switch into + multi_call_memory_ctx while doing the first-call setup. +

A complete pseudo-code example looks like the following: +

Datum
+my_set_returning_function(PG_FUNCTION_ARGS)
+{
+    FuncCallContext  *funcctx;
+    Datum             result;
+    further declarations as needed
+
+    if (SRF_IS_FIRSTCALL())
+    {
+        MemoryContext oldcontext;
+
+        funcctx = SRF_FIRSTCALL_INIT();
+        oldcontext = MemoryContextSwitchTo(funcctx->multi_call_memory_ctx);
+        /* One-time setup code appears here: */
+        user code
+        if returning composite
+            build TupleDesc, and perhaps AttInMetadata
+        endif returning composite
+        user code
+        MemoryContextSwitchTo(oldcontext);
+    }
+
+    /* Each-time setup code appears here: */
+    user code
+    funcctx = SRF_PERCALL_SETUP();
+    user code
+
+    /* this is just one way we might test whether we are done: */
+    if (funcctx->call_cntr < funcctx->max_calls)
+    {
+        /* Here we want to return another item: */
+        user code
+        obtain result Datum
+        SRF_RETURN_NEXT(funcctx, result);
+    }
+    else
+    {
+        /* Here we are done returning items and just need to clean up: */
+        user code
+        SRF_RETURN_DONE(funcctx);
+    }
+}

+

A complete example of a simple SRF returning a composite type + looks like: +

PG_FUNCTION_INFO_V1(retcomposite);
+
+Datum
+retcomposite(PG_FUNCTION_ARGS)
+{
+    FuncCallContext     *funcctx;
+    int                  call_cntr;
+    int                  max_calls;
+    TupleDesc            tupdesc;
+    AttInMetadata       *attinmeta;
+
+    /* stuff done only on the first call of the function */
+    if (SRF_IS_FIRSTCALL())
+    {
+        MemoryContext   oldcontext;
+
+        /* create a function context for cross-call persistence */
+        funcctx = SRF_FIRSTCALL_INIT();
+
+        /* switch to memory context appropriate for multiple function calls */
+        oldcontext = MemoryContextSwitchTo(funcctx->multi_call_memory_ctx);
+
+        /* total number of tuples to be returned */
+        funcctx->max_calls = PG_GETARG_UINT32(0);
+
+        /* Build a tuple descriptor for our result type */
+        if (get_call_result_type(fcinfo, NULL, &tupdesc) != TYPEFUNC_COMPOSITE)
+            ereport(ERROR,
+                    (errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
+                     errmsg("function returning record called in context "
+                            "that cannot accept type record")));
+
+        /*
+         * generate attribute metadata needed later to produce tuples from raw
+         * C strings
+         */
+        attinmeta = TupleDescGetAttInMetadata(tupdesc);
+        funcctx->attinmeta = attinmeta;
+
+        MemoryContextSwitchTo(oldcontext);
+    }
+
+    /* stuff done on every call of the function */
+    funcctx = SRF_PERCALL_SETUP();
+
+    call_cntr = funcctx->call_cntr;
+    max_calls = funcctx->max_calls;
+    attinmeta = funcctx->attinmeta;
+
+    if (call_cntr < max_calls)    /* do when there is more left to send */
+    {
+        char       **values;
+        HeapTuple    tuple;
+        Datum        result;
+
+        /*
+         * Prepare a values array for building the returned tuple.
+         * This should be an array of C strings which will
+         * be processed later by the type input functions.
+         */
+        values = (char **) palloc(3 * sizeof(char *));
+        values[0] = (char *) palloc(16 * sizeof(char));
+        values[1] = (char *) palloc(16 * sizeof(char));
+        values[2] = (char *) palloc(16 * sizeof(char));
+
+        snprintf(values[0], 16, "%d", 1 * PG_GETARG_INT32(1));
+        snprintf(values[1], 16, "%d", 2 * PG_GETARG_INT32(1));
+        snprintf(values[2], 16, "%d", 3 * PG_GETARG_INT32(1));
+
+        /* build a tuple */
+        tuple = BuildTupleFromCStrings(attinmeta, values);
+
+        /* make the tuple into a datum */
+        result = HeapTupleGetDatum(tuple);
+
+        /* clean up (this is not really necessary) */
+        pfree(values[0]);
+        pfree(values[1]);
+        pfree(values[2]);
+        pfree(values);
+
+        SRF_RETURN_NEXT(funcctx, result);
+    }
+    else    /* do when there is no more left */
+    {
+        SRF_RETURN_DONE(funcctx);
+    }
+}

+ + One way to declare this function in SQL is: +

CREATE TYPE __retcomposite AS (f1 integer, f2 integer, f3 integer);
+
+CREATE OR REPLACE FUNCTION retcomposite(integer, integer)
+    RETURNS SETOF __retcomposite
+    AS 'filename', 'retcomposite'
+    LANGUAGE C IMMUTABLE STRICT;

+ A different way is to use OUT parameters: +

CREATE OR REPLACE FUNCTION retcomposite(IN integer, IN integer,
+    OUT f1 integer, OUT f2 integer, OUT f3 integer)
+    RETURNS SETOF record
+    AS 'filename', 'retcomposite'
+    LANGUAGE C IMMUTABLE STRICT;

+ Notice that in this method the output type of the function is formally + an anonymous record type. +

The directory contrib/tablefunc + module in the source distribution contains more examples of + set-returning functions. +

35.9.10. Polymorphic Arguments and Return Types

C-language functions can be declared to accept and + return the polymorphic types + anyelement, anyarray, anynonarray, + anyenum, and anyrange. + See Section 35.2.5 for a more detailed explanation + of polymorphic functions. When function arguments or return types + are defined as polymorphic types, the function author cannot know + in advance what data type it will be called with, or + need to return. There are two routines provided in fmgr.h + to allow a version-1 C function to discover the actual data types + of its arguments and the type it is expected to return. The routines are + called get_fn_expr_rettype(FmgrInfo *flinfo) and + get_fn_expr_argtype(FmgrInfo *flinfo, int argnum). + They return the result or argument type OID, or InvalidOid if the + information is not available. + The structure flinfo is normally accessed as + fcinfo->flinfo. The parameter argnum + is zero based. get_call_result_type can also be used + as an alternative to get_fn_expr_rettype. +

For example, suppose we want to write a function to accept a single + element of any type, and return a one-dimensional array of that type: + +

PG_FUNCTION_INFO_V1(make_array);
+Datum
+make_array(PG_FUNCTION_ARGS)
+{
+    ArrayType  *result;
+    Oid         element_type = get_fn_expr_argtype(fcinfo->flinfo, 0);
+    Datum       element;
+    bool        isnull;
+    int16       typlen;
+    bool        typbyval;
+    char        typalign;
+    int         ndims;
+    int         dims[MAXDIM];
+    int         lbs[MAXDIM];
+
+    if (!OidIsValid(element_type))
+        elog(ERROR, "could not determine data type of input");
+
+    /* get the provided element, being careful in case it's NULL */
+    isnull = PG_ARGISNULL(0);
+    if (isnull)
+        element = (Datum) 0;
+    else
+        element = PG_GETARG_DATUM(0);
+
+    /* we have one dimension */
+    ndims = 1;
+    /* and one element */
+    dims[0] = 1;
+    /* and lower bound is 1 */
+    lbs[0] = 1;
+
+    /* get required info about the element type */
+    get_typlenbyvalalign(element_type, &typlen, &typbyval, &typalign);
+
+    /* now build the array */
+    result = construct_md_array(&element, &isnull, ndims, dims, lbs,
+                                element_type, typlen, typbyval, typalign);
+
+    PG_RETURN_ARRAYTYPE_P(result);
+}

+

The following command declares the function + make_array in SQL: + +

CREATE FUNCTION make_array(anyelement) RETURNS anyarray
+    AS 'DIRECTORY/funcs', 'make_array'
+    LANGUAGE C IMMUTABLE;

+

There is a variant of polymorphism that is only available to C-language + functions: they can be declared to take parameters of type + "any". (Note that this type name must be double-quoted, + since it's also a SQL reserved word.) This works like + anyelement except that it does not constrain different + "any" arguments to be the same type, nor do they help + determine the function's result type. A C-language function can also + declare its final parameter to be VARIADIC "any". This will + match one or more actual arguments of any type (not necessarily the same + type). These arguments will not be gathered into an array + as happens with normal variadic functions; they will just be passed to + the function separately. The PG_NARGS() macro and the + methods described above must be used to determine the number of actual + arguments and their types when using this feature. +

35.9.11. Transform Functions

Some function calls can be simplified during planning based on + properties specific to the function. For example, + int4mul(n, 1) could be simplified to just n. + To define such function-specific optimizations, write a + transform function and place its OID in the + protransform field of the primary function's + pg_proc entry. The transform function must have the SQL + signature protransform(internal) RETURNS internal. The + argument, actually FuncExpr *, is a dummy node representing a + call to the primary function. If the transform function's study of the + expression tree proves that a simplified expression tree can substitute + for all possible concrete calls represented thereby, build and return + that simplified expression. Otherwise, return a NULL + pointer (not a SQL null). +

We make no guarantee that PostgreSQL will never call the + primary function in cases that the transform function could simplify. + Ensure rigorous equivalence between the simplified expression and an + actual call to the primary function. +

Currently, this facility is not exposed to users at the SQL level + because of security concerns, so it is only practical to use for + optimizing built-in functions. +

35.9.12. Shared Memory and LWLocks

Add-ins can reserve LWLocks and an allocation of shared memory on server + startup. The add-in's shared library must be preloaded by specifying + it in + shared_preload_libraries. + Shared memory is reserved by calling: +

void RequestAddinShmemSpace(int size)

+ from your _PG_init function. +

LWLocks are reserved by calling: +

void RequestAddinLWLocks(int n)

+ from _PG_init. +

To avoid possible race-conditions, each backend should use the LWLock + AddinShmemInitLock when connecting to and initializing + its allocation of shared memory, as shown here: +

static mystruct *ptr = NULL;
+
+if (!ptr)
+{
+        bool    found;
+
+        LWLockAcquire(AddinShmemInitLock, LW_EXCLUSIVE);
+        ptr = ShmemInitStruct("my struct name", size, &found);
+        if (!found)
+        {
+                initialize contents of shmem area;
+                acquire any requested LWLocks using:
+                ptr->mylockid = LWLockAssign();
+        }
+        LWLockRelease(AddinShmemInitLock);
+}

+

35.9.13. Using C++ for Extensibility

Although the PostgreSQL backend is written in + C, it is possible to write extensions in C++ if these guidelines are + followed: + +

  • All functions accessed by the backend must present a C interface + to the backend; these C functions can then call C++ functions. + For example, extern C linkage is required for + backend-accessed functions. This is also necessary for any + functions that are passed as pointers between the backend and + C++ code. +

  • Free memory using the appropriate deallocation method. For example, + most backend memory is allocated using palloc(), so use + pfree() to free it. Using C++ + delete in such cases will fail. +

  • Prevent exceptions from propagating into the C code (use a catch-all + block at the top level of all extern C functions). This + is necessary even if the C++ code does not explicitly throw any + exceptions, because events like out-of-memory can still throw + exceptions. Any exceptions must be caught and appropriate errors + passed back to the C interface. If possible, compile C++ with + -fno-exceptions to eliminate exceptions entirely; in such + cases, you must check for failures in your C++ code, e.g. check for + NULL returned by new(). +

  • If calling backend functions from C++ code, be sure that the + C++ call stack contains only plain old data structures + (POD). This is necessary because backend errors + generate a distant longjmp() that does not properly + unroll a C++ call stack with non-POD objects. +

+

In summary, it is best to place C++ code behind a wall of + extern C functions that interface to the backend, + and avoid exception, memory, and call stack leakage. +


PrevHomeNext
Internal FunctionsUpUser-defined Aggregates
\ No newline at end of file diff --git a/doc/src/sgml/html/xfunc-internal.html b/doc/src/sgml/html/xfunc-internal.html new file mode 100644 index 000000000..dc7141564 --- /dev/null +++ b/doc/src/sgml/html/xfunc-internal.html @@ -0,0 +1,237 @@ + +Internal Functions

35.8. Internal Functions

Internal functions are functions written in C that have been statically + linked into the PostgreSQL server. + The "body" of the function definition + specifies the C-language name of the function, which need not be the + same as the name being declared for SQL use. + (For reasons of backward compatibility, an empty body + is accepted as meaning that the C-language function name is the + same as the SQL name.) +

Normally, all internal functions present in the + server are declared during the initialization of the database cluster + (see Section 17.2), + but a user could use CREATE FUNCTION + to create additional alias names for an internal function. + Internal functions are declared in CREATE FUNCTION + with language name internal. For instance, to + create an alias for the sqrt function: +

CREATE FUNCTION square_root(double precision) RETURNS double precision
+    AS 'dsqrt'
+    LANGUAGE internal
+    STRICT;

+ (Most internal functions expect to be declared "strict".) +

Note: Not all "predefined" functions are + "internal" in the above sense. Some predefined + functions are written in SQL. +


PrevHomeNext
Procedural Language FunctionsUpC-Language Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/xfunc-overload.html b/doc/src/sgml/html/xfunc-overload.html new file mode 100644 index 000000000..3975c41ce --- /dev/null +++ b/doc/src/sgml/html/xfunc-overload.html @@ -0,0 +1,278 @@ + +Function Overloading

35.5. Function Overloading

More than one function can be defined with the same SQL name, so long + as the arguments they take are different. In other words, + function names can be overloaded. When a + query is executed, the server will determine which function to + call from the data types and the number of the provided arguments. + Overloading can also be used to simulate functions with a variable + number of arguments, up to a finite maximum number. +

When creating a family of overloaded functions, one should be + careful not to create ambiguities. For instance, given the + functions: +

CREATE FUNCTION test(int, real) RETURNS ...
+CREATE FUNCTION test(smallint, double precision) RETURNS ...

+ it is not immediately clear which function would be called with + some trivial input like test(1, 1.5). The + currently implemented resolution rules are described in + Chapter 10, but it is unwise to design a system that subtly + relies on this behavior. +

A function that takes a single argument of a composite type should + generally not have the same name as any attribute (field) of that type. + Recall that attribute(table) is considered equivalent + to table.attribute. In the case that there is an + ambiguity between a function on a composite type and an attribute of + the composite type, the attribute will always be used. It is possible + to override that choice by schema-qualifying the function name + (that is, schema.func(table)) but it's better to + avoid the problem by not choosing conflicting names. +

Another possible conflict is between variadic and non-variadic functions. + For instance, it is possible to create both foo(numeric) and + foo(VARIADIC numeric[]). In this case it is unclear which one + should be matched to a call providing a single numeric argument, such as + foo(10.1). The rule is that the function appearing + earlier in the search path is used, or if the two functions are in the + same schema, the non-variadic one is preferred. +

When overloading C-language functions, there is an additional + constraint: The C name of each function in the family of + overloaded functions must be different from the C names of all + other functions, either internal or dynamically loaded. If this + rule is violated, the behavior is not portable. You might get a + run-time linker error, or one of the functions will get called + (usually the internal one). The alternative form of the + AS clause for the SQL CREATE + FUNCTION command decouples the SQL function name from + the function name in the C source code. For instance: +

CREATE FUNCTION test(int) RETURNS int
+    AS 'filename', 'test_1arg'
+    LANGUAGE C;
+CREATE FUNCTION test(int, int) RETURNS int
+    AS 'filename', 'test_2arg'
+    LANGUAGE C;

+ The names of the C functions here reflect one of many possible conventions. +


PrevHomeNext
Query Language (SQL) FunctionsUpFunction Volatility Categories
\ No newline at end of file diff --git a/doc/src/sgml/html/xfunc-pl.html b/doc/src/sgml/html/xfunc-pl.html new file mode 100644 index 000000000..e5ba1ec3d --- /dev/null +++ b/doc/src/sgml/html/xfunc-pl.html @@ -0,0 +1,192 @@ + +Procedural Language Functions

35.7. Procedural Language Functions

PostgreSQL allows user-defined functions + to be written in other languages besides SQL and C. These other + languages are generically called procedural + languages (PLs). + Procedural languages aren't built into the + PostgreSQL server; they are offered + by loadable modules. + See Chapter 38 and following chapters for more + information. +


PrevHomeNext
Function Volatility CategoriesUpInternal Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/xfunc-sql.html b/doc/src/sgml/html/xfunc-sql.html new file mode 100644 index 000000000..19c1dbd09 --- /dev/null +++ b/doc/src/sgml/html/xfunc-sql.html @@ -0,0 +1,1768 @@ + +Query Language (SQL) Functions

35.4. Query Language (SQL) Functions

SQL functions execute an arbitrary list of SQL statements, returning + the result of the last query in the list. + In the simple (non-set) + case, the first row of the last query's result will be returned. + (Bear in mind that "the first row" of a multirow + result is not well-defined unless you use ORDER BY.) + If the last query happens + to return no rows at all, the null value will be returned. +

Alternatively, an SQL function can be declared to return a set, + by specifying the function's return type as SETOF + sometype, or equivalently by declaring it as + RETURNS TABLE(columns). In this case + all rows of the last query's result are returned. Further details appear + below. +

The body of an SQL function must be a list of SQL + statements separated by semicolons. A semicolon after the last + statement is optional. Unless the function is declared to return + void, the last statement must be a SELECT, + or an INSERT, UPDATE, or DELETE + that has a RETURNING clause. +

Any collection of commands in the SQL + language can be packaged together and defined as a function. + Besides SELECT queries, the commands can include data + modification queries (INSERT, + UPDATE, and DELETE), as well as + other SQL commands. (You cannot use transaction control commands, e.g. + COMMIT, SAVEPOINT, and some utility + commands, e.g. VACUUM, in SQL functions.) + However, the final command + must be a SELECT or have a RETURNING + clause that returns whatever is + specified as the function's return type. Alternatively, if you + want to define a SQL function that performs actions but has no + useful value to return, you can define it as returning void. + For example, this function removes rows with negative salaries from + the emp table: + +

CREATE FUNCTION clean_emp() RETURNS void AS '
+    DELETE FROM emp
+        WHERE salary < 0;
+' LANGUAGE SQL;
+
+SELECT clean_emp();
+
+ clean_emp
+-----------
+
+(1 row)

+

The syntax of the CREATE FUNCTION command requires + the function body to be written as a string constant. It is usually + most convenient to use dollar quoting (see Section 4.1.2.4) for the string constant. + If you choose to use regular single-quoted string constant syntax, + you must double single quote marks (') and backslashes + (\) (assuming escape string syntax) in the body of + the function (see Section 4.1.2.1). +

35.4.1. Arguments for SQL Functions

Arguments of a SQL function can be referenced in the function + body using either names or numbers. Examples of both methods appear + below. +

To use a name, declare the function argument as having a name, and + then just write that name in the function body. If the argument name + is the same as any column name in the current SQL command within the + function, the column name will take precedence. To override this, + qualify the argument name with the name of the function itself, that is + function_name.argument_name. + (If this would conflict with a qualified column name, again the column + name wins. You can avoid the ambiguity by choosing a different alias for + the table within the SQL command.) +

In the older numeric approach, arguments are referenced using the syntax + $n: $1 refers to the first input + argument, $2 to the second, and so on. This will work + whether or not the particular argument was declared with a name. +

If an argument is of a composite type, then the dot notation, + e.g., argname.fieldname or + $1.fieldname, can be used to access attributes of the + argument. Again, you might need to qualify the argument's name with the + function name to make the form with an argument name unambiguous. +

SQL function arguments can only be used as data values, + not as identifiers. Thus for example this is reasonable: +

INSERT INTO mytable VALUES ($1);

+but this will not work: +

INSERT INTO $1 VALUES (42);

+

Note: The ability to use names to reference SQL function arguments was added + in PostgreSQL 9.2. Functions to be used in + older servers must use the $n notation. +

35.4.2. SQL Functions on Base Types

The simplest possible SQL function has no arguments and + simply returns a base type, such as integer: + +

CREATE FUNCTION one() RETURNS integer AS $$
+    SELECT 1 AS result;
+$$ LANGUAGE SQL;
+
+-- Alternative syntax for string literal:
+CREATE FUNCTION one() RETURNS integer AS '
+    SELECT 1 AS result;
+' LANGUAGE SQL;
+
+SELECT one();
+
+ one
+-----
+   1

+

Notice that we defined a column alias within the function body for the result of the function + (with the name result), but this column alias is not visible + outside the function. Hence, the result is labeled one + instead of result. +

It is almost as easy to define SQL functions + that take base types as arguments: + +

CREATE FUNCTION add_em(x integer, y integer) RETURNS integer AS $$
+    SELECT x + y;
+$$ LANGUAGE SQL;
+
+SELECT add_em(1, 2) AS answer;
+
+ answer
+--------
+      3

+

Alternatively, we could dispense with names for the arguments and + use numbers: + +

CREATE FUNCTION add_em(integer, integer) RETURNS integer AS $$
+    SELECT $1 + $2;
+$$ LANGUAGE SQL;
+
+SELECT add_em(1, 2) AS answer;
+
+ answer
+--------
+      3

+

Here is a more useful function, which might be used to debit a + bank account: + +

CREATE FUNCTION tf1 (accountno integer, debit numeric) RETURNS integer AS $$
+    UPDATE bank
+        SET balance = balance - debit
+        WHERE accountno = tf1.accountno;
+    SELECT 1;
+$$ LANGUAGE SQL;

+ + A user could execute this function to debit account 17 by $100.00 as + follows: + +

SELECT tf1(17, 100.0);

+

In this example, we chose the name accountno for the first + argument, but this is the same as the name of a column in the + bank table. Within the UPDATE command, + accountno refers to the column bank.accountno, + so tf1.accountno must be used to refer to the argument. + We could of course avoid this by using a different name for the argument. +

In practice one would probably like a more useful result from the + function than a constant 1, so a more likely definition + is: + +

CREATE FUNCTION tf1 (accountno integer, debit numeric) RETURNS integer AS $$
+    UPDATE bank
+        SET balance = balance - debit
+        WHERE accountno = tf1.accountno;
+    SELECT balance FROM bank WHERE accountno = tf1.accountno;
+$$ LANGUAGE SQL;

+ + which adjusts the balance and returns the new balance. + The same thing could be done in one command using RETURNING: + +

CREATE FUNCTION tf1 (accountno integer, debit numeric) RETURNS integer AS $$
+    UPDATE bank
+        SET balance = balance - debit
+        WHERE accountno = tf1.accountno
+    RETURNING balance;
+$$ LANGUAGE SQL;

+

35.4.3. SQL Functions on Composite Types

When writing functions with arguments of composite types, we must not + only specify which argument we want but also the desired attribute + (field) of that argument. For example, suppose that + emp is a table containing employee data, and therefore + also the name of the composite type of each row of the table. Here + is a function double_salary that computes what someone's + salary would be if it were doubled: + +

CREATE TABLE emp (
+    name        text,
+    salary      numeric,
+    age         integer,
+    cubicle     point
+);
+
+INSERT INTO emp VALUES ('Bill', 4200, 45, '(2,1)');
+
+CREATE FUNCTION double_salary(emp) RETURNS numeric AS $$
+    SELECT $1.salary * 2 AS salary;
+$$ LANGUAGE SQL;
+
+SELECT name, double_salary(emp.*) AS dream
+    FROM emp
+    WHERE emp.cubicle ~= point '(2,1)';
+
+ name | dream
+------+-------
+ Bill |  8400

+

Notice the use of the syntax $1.salary + to select one field of the argument row value. Also notice + how the calling SELECT command uses * + to select + the entire current row of a table as a composite value. The table + row can alternatively be referenced using just the table name, + like this: +

SELECT name, double_salary(emp) AS dream
+    FROM emp
+    WHERE emp.cubicle ~= point '(2,1)';

+ but this usage is deprecated since it's easy to get confused. +

Sometimes it is handy to construct a composite argument value + on-the-fly. This can be done with the ROW construct. + For example, we could adjust the data being passed to the function: +

SELECT name, double_salary(ROW(name, salary*1.1, age, cubicle)) AS dream
+    FROM emp;

+

It is also possible to build a function that returns a composite type. + This is an example of a function + that returns a single emp row: + +

CREATE FUNCTION new_emp() RETURNS emp AS $$
+    SELECT text 'None' AS name,
+        1000.0 AS salary,
+        25 AS age,
+        point '(2,2)' AS cubicle;
+$$ LANGUAGE SQL;

+ + In this example we have specified each of the attributes + with a constant value, but any computation + could have been substituted for these constants. +

Note two important things about defining the function: + +

  • The select list order in the query must be exactly the same as + that in which the columns appear in the table associated + with the composite type. (Naming the columns, as we did above, + is irrelevant to the system.) +

  • You must typecast the expressions to match the + definition of the composite type, or you will get errors like this: +

    ERROR:  function declared to return emp returns varchar instead of text at column 1

    +

+

A different way to define the same function is: + +

CREATE FUNCTION new_emp() RETURNS emp AS $$
+    SELECT ROW('None', 1000.0, 25, '(2,2)')::emp;
+$$ LANGUAGE SQL;

+ + Here we wrote a SELECT that returns just a single + column of the correct composite type. This isn't really better + in this situation, but it is a handy alternative in some cases + — for example, if we need to compute the result by calling + another function that returns the desired composite value. +

We could call this function directly in either of two ways: + +

SELECT new_emp();
+
+         new_emp
+--------------------------
+ (None,1000.0,25,"(2,2)")
+
+SELECT * FROM new_emp();
+
+ name | salary | age | cubicle
+------+--------+-----+---------
+ None | 1000.0 |  25 | (2,2)

+ + The second way is described more fully in Section 35.4.7. +

When you use a function that returns a composite type, + you might want only one field (attribute) from its result. + You can do that with syntax like this: + +

SELECT (new_emp()).name;
+
+ name
+------
+ None

+ + The extra parentheses are needed to keep the parser from getting + confused. If you try to do it without them, you get something like this: + +

SELECT new_emp().name;
+ERROR:  syntax error at or near "."
+LINE 1: SELECT new_emp().name;
+                        ^

+

Another option is to use + functional notation for extracting an attribute. The simple way + to explain this is that we can use the + notations attribute(table) and table.attribute + interchangeably. + +

SELECT name(new_emp());
+
+ name
+------
+ None

+ +

-- This is the same as:
+-- SELECT emp.name AS youngster FROM emp WHERE emp.age < 30;
+
+SELECT name(emp) AS youngster FROM emp WHERE age(emp) < 30;
+
+ youngster
+-----------
+ Sam
+ Andy

+

Tip: The equivalence between functional notation and attribute notation + makes it possible to use functions on composite types to emulate + "computed fields". + + + For example, using the previous definition + for double_salary(emp), we can write + +

SELECT emp.name, emp.double_salary FROM emp;

+ + An application using this wouldn't need to be directly aware that + double_salary isn't a real column of the table. + (You can also emulate computed fields with views.) +

Because of this behavior, it's unwise to give a function that takes + a single composite-type argument the same name as any of the fields of + that composite type. +

Another way to use a function returning a composite type is to pass the + result to another function that accepts the correct row type as input: + +

CREATE FUNCTION getname(emp) RETURNS text AS $$
+    SELECT $1.name;
+$$ LANGUAGE SQL;
+
+SELECT getname(new_emp());
+ getname
+---------
+ None
+(1 row)

+

Still another way to use a function that returns a composite type is to + call it as a table function, as described in Section 35.4.7. +

35.4.4. SQL Functions with Output Parameters

An alternative way of describing a function's results is to define it + with output parameters, as in this example: + +

CREATE FUNCTION add_em (IN x int, IN y int, OUT sum int)
+AS 'SELECT x + y'
+LANGUAGE SQL;
+
+SELECT add_em(3,7);
+ add_em
+--------
+     10
+(1 row)

+ + This is not essentially different from the version of add_em + shown in Section 35.4.2. The real value of + output parameters is that they provide a convenient way of defining + functions that return several columns. For example, + +

CREATE FUNCTION sum_n_product (x int, y int, OUT sum int, OUT product int)
+AS 'SELECT x + y, x * y'
+LANGUAGE SQL;
+
+ SELECT * FROM sum_n_product(11,42);
+ sum | product
+-----+---------
+  53 |     462
+(1 row)

+ + What has essentially happened here is that we have created an anonymous + composite type for the result of the function. The above example has + the same end result as + +

CREATE TYPE sum_prod AS (sum int, product int);
+
+CREATE FUNCTION sum_n_product (int, int) RETURNS sum_prod
+AS 'SELECT $1 + $2, $1 * $2'
+LANGUAGE SQL;

+ + but not having to bother with the separate composite type definition + is often handy. Notice that the names attached to the output parameters + are not just decoration, but determine the column names of the anonymous + composite type. (If you omit a name for an output parameter, the + system will choose a name on its own.) +

Notice that output parameters are not included in the calling argument + list when invoking such a function from SQL. This is because + PostgreSQL considers only the input + parameters to define the function's calling signature. That means + also that only the input parameters matter when referencing the function + for purposes such as dropping it. We could drop the above function + with either of + +

DROP FUNCTION sum_n_product (x int, y int, OUT sum int, OUT product int);
+DROP FUNCTION sum_n_product (int, int);

+

Parameters can be marked as IN (the default), + OUT, INOUT, or VARIADIC. + An INOUT + parameter serves as both an input parameter (part of the calling + argument list) and an output parameter (part of the result record type). + VARIADIC parameters are input parameters, but are treated + specially as described next. +

35.4.5. SQL Functions with Variable Numbers of Arguments

SQL functions can be declared to accept + variable numbers of arguments, so long as all the "optional" + arguments are of the same data type. The optional arguments will be + passed to the function as an array. The function is declared by + marking the last parameter as VARIADIC; this parameter + must be declared as being of an array type. For example: + +

CREATE FUNCTION mleast(VARIADIC arr numeric[]) RETURNS numeric AS $$
+    SELECT min($1[i]) FROM generate_subscripts($1, 1) g(i);
+$$ LANGUAGE SQL;
+
+SELECT mleast(10, -1, 5, 4.4);
+ mleast 
+--------
+     -1
+(1 row)

+ + Effectively, all the actual arguments at or beyond the + VARIADIC position are gathered up into a one-dimensional + array, as if you had written + +

SELECT mleast(ARRAY[10, -1, 5, 4.4]);    -- doesn't work

+ + You can't actually write that, though — or at least, it will + not match this function definition. A parameter marked + VARIADIC matches one or more occurrences of its element + type, not of its own type. +

Sometimes it is useful to be able to pass an already-constructed array + to a variadic function; this is particularly handy when one variadic + function wants to pass on its array parameter to another one. You can + do that by specifying VARIADIC in the call: + +

SELECT mleast(VARIADIC ARRAY[10, -1, 5, 4.4]);

+ + This prevents expansion of the function's variadic parameter into its + element type, thereby allowing the array argument value to match + normally. VARIADIC can only be attached to the last + actual argument of a function call. +

The array element parameters generated from a variadic parameter are + treated as not having any names of their own. This means it is not + possible to call a variadic function using named arguments (Section 4.3), except when you specify + VARIADIC. For example, this will work: + +

SELECT mleast(VARIADIC arr := ARRAY[10, -1, 5, 4.4]);

+ + but not these: + +

SELECT mleast(arr := 10);
+SELECT mleast(arr := ARRAY[10, -1, 5, 4.4]);

+

35.4.6. SQL Functions with Default Values for Arguments

Functions can be declared with default values for some or all input + arguments. The default values are inserted whenever the function is + called with insufficiently many actual arguments. Since arguments + can only be omitted from the end of the actual argument list, all + parameters after a parameter with a default value have to have + default values as well. (Although the use of named argument notation + could allow this restriction to be relaxed, it's still enforced so that + positional argument notation works sensibly.) +

For example: +

CREATE FUNCTION foo(a int, b int DEFAULT 2, c int DEFAULT 3)
+RETURNS int
+LANGUAGE SQL
+AS $$
+    SELECT $1 + $2 + $3;
+$$;
+
+SELECT foo(10, 20, 30);
+ foo 
+-----
+  60
+(1 row)
+
+SELECT foo(10, 20);
+ foo 
+-----
+  33
+(1 row)
+
+SELECT foo(10);
+ foo 
+-----
+  15
+(1 row)
+
+SELECT foo();  -- fails since there is no default for the first argument
+ERROR:  function foo() does not exist

+ The = sign can also be used in place of the + key word DEFAULT. +

35.4.7. SQL Functions as Table Sources

All SQL functions can be used in the FROM clause of a query, + but it is particularly useful for functions returning composite types. + If the function is defined to return a base type, the table function + produces a one-column table. If the function is defined to return + a composite type, the table function produces a column for each attribute + of the composite type. +

Here is an example: + +

CREATE TABLE foo (fooid int, foosubid int, fooname text);
+INSERT INTO foo VALUES (1, 1, 'Joe');
+INSERT INTO foo VALUES (1, 2, 'Ed');
+INSERT INTO foo VALUES (2, 1, 'Mary');
+
+CREATE FUNCTION getfoo(int) RETURNS foo AS $$
+    SELECT * FROM foo WHERE fooid = $1;
+$$ LANGUAGE SQL;
+
+SELECT *, upper(fooname) FROM getfoo(1) AS t1;
+
+ fooid | foosubid | fooname | upper
+-------+----------+---------+-------
+     1 |        1 | Joe     | JOE
+(1 row)

+ + As the example shows, we can work with the columns of the function's + result just the same as if they were columns of a regular table. +

Note that we only got one row out of the function. This is because + we did not use SETOF. That is described in the next section. +

35.4.8. SQL Functions Returning Sets

When an SQL function is declared as returning SETOF + sometype, the function's final + query is executed to completion, and each row it + outputs is returned as an element of the result set. +

This feature is normally used when calling the function in the FROM + clause. In this case each row returned by the function becomes + a row of the table seen by the query. For example, assume that + table foo has the same contents as above, and we say: + +

CREATE FUNCTION getfoo(int) RETURNS SETOF foo AS $$
+    SELECT * FROM foo WHERE fooid = $1;
+$$ LANGUAGE SQL;
+
+SELECT * FROM getfoo(1) AS t1;

+ + Then we would get: +

 fooid | foosubid | fooname
+-------+----------+---------
+     1 |        1 | Joe
+     1 |        2 | Ed
+(2 rows)

+

It is also possible to return multiple rows with the columns defined by + output parameters, like this: + +

CREATE TABLE tab (y int, z int);
+INSERT INTO tab VALUES (1, 2), (3, 4), (5, 6), (7, 8);
+
+CREATE FUNCTION sum_n_product_with_tab (x int, OUT sum int, OUT product int)
+RETURNS SETOF record
+AS $$
+    SELECT $1 + tab.y, $1 * tab.y FROM tab;
+$$ LANGUAGE SQL;
+
+SELECT * FROM sum_n_product_with_tab(10);
+ sum | product
+-----+---------
+  11 |      10
+  13 |      30
+  15 |      50
+  17 |      70
+(4 rows)

+ + The key point here is that you must write RETURNS SETOF record + to indicate that the function returns multiple rows instead of just one. + If there is only one output parameter, write that parameter's type + instead of record. +

Currently, functions returning sets can also be called in the select list + of a query. For each row that the query + generates by itself, the function returning set is invoked, and an output + row is generated for each element of the function's result set. Note, + however, that this capability is deprecated and might be removed in future + releases. The following is an example function returning a set from the + select list: + +

CREATE FUNCTION listchildren(text) RETURNS SETOF text AS $$
+    SELECT name FROM nodes WHERE parent = $1
+$$ LANGUAGE SQL;
+
+SELECT * FROM nodes;
+   name    | parent
+-----------+--------
+ Top       |
+ Child1    | Top
+ Child2    | Top
+ Child3    | Top
+ SubChild1 | Child1
+ SubChild2 | Child1
+(6 rows)
+
+SELECT listchildren('Top');
+ listchildren
+--------------
+ Child1
+ Child2
+ Child3
+(3 rows)
+
+SELECT name, listchildren(name) FROM nodes;
+  name  | listchildren
+--------+--------------
+ Top    | Child1
+ Top    | Child2
+ Top    | Child3
+ Child1 | SubChild1
+ Child1 | SubChild2
+(5 rows)

+ + In the last SELECT, + notice that no output row appears for Child2, Child3, etc. + This happens because listchildren returns an empty set + for those arguments, so no result rows are generated. +

Note: If a function's last command is INSERT, UPDATE, + or DELETE with RETURNING, that command will + always be executed to completion, even if the function is not declared + with SETOF or the calling query does not fetch all the + result rows. Any extra rows produced by the RETURNING + clause are silently dropped, but the commanded table modifications + still happen (and are all completed before returning from the function). +

35.4.9. SQL Functions Returning TABLE

There is another way to declare a function as returning a set, + which is to use the syntax + RETURNS TABLE(columns). + This is equivalent to using one or more OUT parameters plus + marking the function as returning SETOF record (or + SETOF a single output parameter's type, as appropriate). + This notation is specified in recent versions of the SQL standard, and + thus may be more portable than using SETOF. +

For example, the preceding sum-and-product example could also be + done this way: + +

CREATE FUNCTION sum_n_product_with_tab (x int)
+RETURNS TABLE(sum int, product int) AS $$
+    SELECT $1 + tab.y, $1 * tab.y FROM tab;
+$$ LANGUAGE SQL;

+ + It is not allowed to use explicit OUT or INOUT + parameters with the RETURNS TABLE notation — you must + put all the output columns in the TABLE list. +

35.4.10. Polymorphic SQL Functions

SQL functions can be declared to accept and + return the polymorphic types anyelement, + anyarray, anynonarray, + anyenum, and anyrange. See Section 35.2.5 for a more detailed + explanation of polymorphic functions. Here is a polymorphic + function make_array that builds up an array + from two arbitrary data type elements: +

CREATE FUNCTION make_array(anyelement, anyelement) RETURNS anyarray AS $$
+    SELECT ARRAY[$1, $2];
+$$ LANGUAGE SQL;
+
+SELECT make_array(1, 2) AS intarray, make_array('a'::text, 'b') AS textarray;
+ intarray | textarray
+----------+-----------
+ {1,2}    | {a,b}
+(1 row)

+

Notice the use of the typecast 'a'::text + to specify that the argument is of type text. This is + required if the argument is just a string literal, since otherwise + it would be treated as type + unknown, and array of unknown is not a valid + type. + Without the typecast, you will get errors like this: +

ERROR:  could not determine polymorphic type because input has type "unknown"

+

It is permitted to have polymorphic arguments with a fixed + return type, but the converse is not. For example: +

CREATE FUNCTION is_greater(anyelement, anyelement) RETURNS boolean AS $$
+    SELECT $1 > $2;
+$$ LANGUAGE SQL;
+
+SELECT is_greater(1, 2);
+ is_greater
+------------
+ f
+(1 row)
+
+CREATE FUNCTION invalid_func() RETURNS anyelement AS $$
+    SELECT 1;
+$$ LANGUAGE SQL;
+ERROR:  cannot determine result data type
+DETAIL:  A function returning a polymorphic type must have at least one polymorphic argument.

+

Polymorphism can be used with functions that have output arguments. + For example: +

CREATE FUNCTION dup (f1 anyelement, OUT f2 anyelement, OUT f3 anyarray)
+AS 'select $1, array[$1,$1]' LANGUAGE SQL;
+
+SELECT * FROM dup(22);
+ f2 |   f3
+----+---------
+ 22 | {22,22}
+(1 row)

+

Polymorphism can also be used with variadic functions. + For example: +

CREATE FUNCTION anyleast (VARIADIC anyarray) RETURNS anyelement AS $$
+    SELECT min($1[i]) FROM generate_subscripts($1, 1) g(i);
+$$ LANGUAGE SQL;
+
+SELECT anyleast(10, -1, 5, 4);
+ anyleast 
+----------
+       -1
+(1 row)
+
+SELECT anyleast('abc'::text, 'def');
+ anyleast 
+----------
+ abc
+(1 row)
+
+CREATE FUNCTION concat_values(text, VARIADIC anyarray) RETURNS text AS $$
+    SELECT array_to_string($2, $1);
+$$ LANGUAGE SQL;
+
+SELECT concat_values('|', 1, 4, 2);
+ concat_values 
+---------------
+ 1|4|2
+(1 row)

+

35.4.11. SQL Functions with Collations

When a SQL function has one or more parameters of collatable data types, + a collation is identified for each function call depending on the + collations assigned to the actual arguments, as described in Section 22.2. If a collation is successfully identified + (i.e., there are no conflicts of implicit collations among the arguments) + then all the collatable parameters are treated as having that collation + implicitly. This will affect the behavior of collation-sensitive + operations within the function. For example, using the + anyleast function described above, the result of +

SELECT anyleast('abc'::text, 'ABC');

+ will depend on the database's default collation. In C locale + the result will be ABC, but in many other locales it will + be abc. The collation to use can be forced by adding + a COLLATE clause to any of the arguments, for example +

SELECT anyleast('abc'::text, 'ABC' COLLATE "C");

+ Alternatively, if you wish a function to operate with a particular + collation regardless of what it is called with, insert + COLLATE clauses as needed in the function definition. + This version of anyleast would always use en_US + locale to compare strings: +

CREATE FUNCTION anyleast (VARIADIC anyarray) RETURNS anyelement AS $$
+    SELECT min($1[i] COLLATE "en_US") FROM generate_subscripts($1, 1) g(i);
+$$ LANGUAGE SQL;

+ But note that this will throw an error if applied to a non-collatable + data type. +

If no common collation can be identified among the actual arguments, + then a SQL function treats its parameters as having their data types' + default collation (which is usually the database's default collation, + but could be different for parameters of domain types). +

The behavior of collatable parameters can be thought of as a limited + form of polymorphism, applicable only to textual data types. +


PrevHomeNext
User-defined FunctionsUpFunction Overloading
\ No newline at end of file diff --git a/doc/src/sgml/html/xfunc-volatility.html b/doc/src/sgml/html/xfunc-volatility.html new file mode 100644 index 000000000..564850b2c --- /dev/null +++ b/doc/src/sgml/html/xfunc-volatility.html @@ -0,0 +1,466 @@ + +Function Volatility Categories

35.6. Function Volatility Categories

Every function has a volatility classification, with + the possibilities being VOLATILE, STABLE, or + IMMUTABLE. VOLATILE is the default if the + CREATE FUNCTION + command does not specify a category. The volatility category is a + promise to the optimizer about the behavior of the function: + +

  • A VOLATILE function can do anything, including modifying + the database. It can return different results on successive calls with + the same arguments. The optimizer makes no assumptions about the + behavior of such functions. A query using a volatile function will + re-evaluate the function at every row where its value is needed. +

  • A STABLE function cannot modify the database and is + guaranteed to return the same results given the same arguments + for all rows within a single statement. This category allows the + optimizer to optimize multiple calls of the function to a single + call. In particular, it is safe to use an expression containing + such a function in an index scan condition. (Since an index scan + will evaluate the comparison value only once, not once at each + row, it is not valid to use a VOLATILE function in an + index scan condition.) +

  • An IMMUTABLE function cannot modify the database and is + guaranteed to return the same results given the same arguments forever. + This category allows the optimizer to pre-evaluate the function when + a query calls it with constant arguments. For example, a query like + SELECT ... WHERE x = 2 + 2 can be simplified on sight to + SELECT ... WHERE x = 4, because the function underlying + the integer addition operator is marked IMMUTABLE. +

+

For best optimization results, you should label your functions with the + strictest volatility category that is valid for them. +

Any function with side-effects must be labeled + VOLATILE, so that calls to it cannot be optimized away. + Even a function with no side-effects needs to be labeled + VOLATILE if its value can change within a single query; + some examples are random(), currval(), + timeofday(). +

Another important example is that the current_timestamp + family of functions qualify as STABLE, since their values do + not change within a transaction. +

There is relatively little difference between STABLE and + IMMUTABLE categories when considering simple interactive + queries that are planned and immediately executed: it doesn't matter + a lot whether a function is executed once during planning or once during + query execution startup. But there is a big difference if the plan is + saved and reused later. Labeling a function IMMUTABLE when + it really isn't might allow it to be prematurely folded to a constant during + planning, resulting in a stale value being re-used during subsequent uses + of the plan. This is a hazard when using prepared statements or when + using function languages that cache plans (such as + PL/pgSQL). +

For functions written in SQL or in any of the standard procedural + languages, there is a second important property determined by the + volatility category, namely the visibility of any data changes that have + been made by the SQL command that is calling the function. A + VOLATILE function will see such changes, a STABLE + or IMMUTABLE function will not. This behavior is implemented + using the snapshotting behavior of MVCC (see Chapter 13): + STABLE and IMMUTABLE functions use a snapshot + established as of the start of the calling query, whereas + VOLATILE functions obtain a fresh snapshot at the start of + each query they execute. +

Note: Functions written in C can manage snapshots however they want, but it's + usually a good idea to make C functions work this way too. +

Because of this snapshotting behavior, + a function containing only SELECT commands can safely be + marked STABLE, even if it selects from tables that might be + undergoing modifications by concurrent queries. + PostgreSQL will execute all commands of a + STABLE function using the snapshot established for the + calling query, and so it will see a fixed view of the database throughout + that query. +

The same snapshotting behavior is used for SELECT commands + within IMMUTABLE functions. It is generally unwise to select + from database tables within an IMMUTABLE function at all, + since the immutability will be broken if the table contents ever change. + However, PostgreSQL does not enforce that you + do not do that. +

A common error is to label a function IMMUTABLE when its + results depend on a configuration parameter. For example, a function + that manipulates timestamps might well have results that depend on the + TimeZone setting. For safety, such functions should + be labeled STABLE instead. +

Note: Before PostgreSQL release 8.0, the requirement + that STABLE and IMMUTABLE functions cannot modify + the database was not enforced by the system. Releases 8.0 and later enforce it + by requiring SQL functions and procedural language functions of these + categories to contain no SQL commands other than SELECT. + (This is not a completely bulletproof test, since such functions could + still call VOLATILE functions that modify the database. + If you do that, you will find that the STABLE or + IMMUTABLE function does not notice the database changes + applied by the called function, since they are hidden from its snapshot.) +


PrevHomeNext
Function OverloadingUpProcedural Language Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/xfunc.html b/doc/src/sgml/html/xfunc.html new file mode 100644 index 000000000..d6573756e --- /dev/null +++ b/doc/src/sgml/html/xfunc.html @@ -0,0 +1,278 @@ + +User-defined Functions

35.3. User-defined Functions

PostgreSQL provides four kinds of + functions: + +

  • query language functions (functions written in + SQL) (Section 35.4) +

  • procedural language functions (functions written in, for + example, PL/pgSQL or PL/Tcl) + (Section 35.7) +

  • internal functions (Section 35.8) +

  • C-language functions (Section 35.9) +

+

Every kind + of function can take base types, composite types, or + combinations of these as arguments (parameters). In addition, + every kind of function can return a base type or + a composite type. Functions can also be defined to return + sets of base or composite values. +

Many kinds of functions can take or return certain pseudo-types + (such as polymorphic types), but the available facilities vary. + Consult the description of each kind of function for more details. +

It's easiest to define SQL + functions, so we'll start by discussing those. + Most of the concepts presented for SQL functions + will carry over to the other types of functions. +

Throughout this chapter, it can be useful to look at the reference + page of the CREATE FUNCTION command to + understand the examples better. Some examples from this chapter + can be found in funcs.sql and + funcs.c in the src/tutorial + directory in the PostgreSQL source + distribution. +


PrevHomeNext
The PostgreSQL Type SystemUpQuery Language (SQL) Functions
\ No newline at end of file diff --git a/doc/src/sgml/html/xindex.html b/doc/src/sgml/html/xindex.html new file mode 100644 index 000000000..ae31ae22c --- /dev/null +++ b/doc/src/sgml/html/xindex.html @@ -0,0 +1,2008 @@ + +Interfacing Extensions To Indexes

35.14. Interfacing Extensions To Indexes

The procedures described thus far let you define new types, new + functions, and new operators. However, we cannot yet define an + index on a column of a new data type. To do this, we must define an + operator class for the new data type. Later in this + section, we will illustrate this concept in an example: a new + operator class for the B-tree index method that stores and sorts + complex numbers in ascending absolute value order. +

Operator classes can be grouped into operator families + to show the relationships between semantically compatible classes. + When only a single data type is involved, an operator class is sufficient, + so we'll focus on that case first and then return to operator families. +

35.14.1. Index Methods and Operator Classes

The pg_am table contains one row for every + index method (internally known as access method). Support for + regular access to tables is built into + PostgreSQL, but all index methods are + described in pg_am. It is possible to add a + new index method by defining the required interface routines and + then creating a row in pg_am — but that is + beyond the scope of this chapter (see Chapter 52). +

The routines for an index method do not directly know anything + about the data types that the index method will operate on. + Instead, an operator + class + identifies the set of operations that the index method needs to use + to work with a particular data type. Operator classes are so + called because one thing they specify is the set of + WHERE-clause operators that can be used with an index + (i.e., can be converted into an index-scan qualification). An + operator class can also specify some support + procedures that are needed by the internal operations of the + index method, but do not directly correspond to any + WHERE-clause operator that can be used with the index. +

It is possible to define multiple operator classes for the same + data type and index method. By doing this, multiple + sets of indexing semantics can be defined for a single data type. + For example, a B-tree index requires a sort ordering to be defined + for each data type it works on. + It might be useful for a complex-number data type + to have one B-tree operator class that sorts the data by complex + absolute value, another that sorts by real part, and so on. + Typically, one of the operator classes will be deemed most commonly + useful and will be marked as the default operator class for that + data type and index method. +

The same operator class name + can be used for several different index methods (for example, both B-tree + and hash index methods have operator classes named + int4_ops), but each such class is an independent + entity and must be defined separately. +

35.14.2. Index Method Strategies

The operators associated with an operator class are identified by + "strategy numbers", which serve to identify the semantics of + each operator within the context of its operator class. + For example, B-trees impose a strict ordering on keys, lesser to greater, + and so operators like "less than" and "greater than or equal + to" are interesting with respect to a B-tree. + Because + PostgreSQL allows the user to define operators, + PostgreSQL cannot look at the name of an operator + (e.g., < or >=) and tell what kind of + comparison it is. Instead, the index method defines a set of + "strategies", which can be thought of as generalized operators. + Each operator class specifies which actual operator corresponds to each + strategy for a particular data type and interpretation of the index + semantics. +

The B-tree index method defines five strategies, shown in Table 35-2. +

Table 35-2. B-tree Strategies

OperationStrategy Number
less than1
less than or equal2
equal3
greater than or equal4
greater than5

Hash indexes support only equality comparisons, and so they use only one + strategy, shown in Table 35-3. +

Table 35-3. Hash Strategies

OperationStrategy Number
equal1

GiST indexes are more flexible: they do not have a fixed set of + strategies at all. Instead, the "consistency" support routine + of each particular GiST operator class interprets the strategy numbers + however it likes. As an example, several of the built-in GiST index + operator classes index two-dimensional geometric objects, providing + the "R-tree" strategies shown in + Table 35-4. Four of these are true + two-dimensional tests (overlaps, same, contains, contained by); + four of them consider only the X direction; and the other four + provide the same tests in the Y direction. +

Table 35-4. GiST Two-Dimensional "R-tree" Strategies

OperationStrategy Number
strictly left of1
does not extend to right of2
overlaps3
does not extend to left of4
strictly right of5
same6
contains7
contained by8
does not extend above9
strictly below10
strictly above11
does not extend below12

SP-GiST indexes are similar to GiST indexes in flexibility: they don't have + a fixed set of strategies. Instead the support routines of each operator + class interpret the strategy numbers according to the operator class's + definition. As an example, the strategy numbers used by the built-in + operator classes for points are shown in Table 35-5. +

Table 35-5. SP-GiST Point Strategies

OperationStrategy Number
strictly left of1
strictly right of5
same6
contained by8
strictly below10
strictly above11

GIN indexes are similar to GiST and SP-GiST indexes, in that they don't + have a fixed set of strategies either. Instead the support routines of + each operator class interpret the strategy numbers according to the + operator class's definition. As an example, the strategy numbers used by + the built-in operator classes for arrays are shown in + Table 35-6. +

Table 35-6. GIN Array Strategies

OperationStrategy Number
overlap1
contains2
is contained by3
equal4

Notice that all the operators listed above return Boolean values. In + practice, all operators defined as index method search operators must + return type boolean, since they must appear at the top + level of a WHERE clause to be used with an index. + (Some index access methods also support ordering operators, + which typically don't return Boolean values; that feature is discussed + in Section 35.14.7.) +

35.14.3. Index Method Support Routines

Strategies aren't usually enough information for the system to figure + out how to use an index. In practice, the index methods require + additional support routines in order to work. For example, the B-tree + index method must be able to compare two keys and determine whether one + is greater than, equal to, or less than the other. Similarly, the + hash index method must be able to compute hash codes for key values. + These operations do not correspond to operators used in qualifications in + SQL commands; they are administrative routines used by + the index methods, internally. +

Just as with strategies, the operator class identifies which specific + functions should play each of these roles for a given data type and + semantic interpretation. The index method defines the set + of functions it needs, and the operator class identifies the correct + functions to use by assigning them to the "support function numbers" + specified by the index method. +

B-trees require a single support function, and allow a second one to be + supplied at the operator class author's option, as shown in Table 35-7. +

Table 35-7. B-tree Support Functions

FunctionSupport Number
Compare two keys and return an integer less than zero, zero, or + greater than zero, indicating whether the first key is less than, + equal to, or greater than the second + 1
Return the addresses of C-callable sort support function(s), + as documented in utils/sortsupport.h (optional) + 2

Hash indexes require one support function, shown in Table 35-8. +

Table 35-8. Hash Support Functions

FunctionSupport Number
Compute the hash value for a key1

GiST indexes require seven support functions, with an optional eighth, as + shown in Table 35-9. + (For more information see Chapter 53.) +

Table 35-9. GiST Support Functions

FunctionDescriptionSupport Number
consistentdetermine whether key satisfies the + query qualifier1
unioncompute union of a set of keys2
compresscompute a compressed representation of a key or value + to be indexed3
decompresscompute a decompressed representation of a + compressed key4
penaltycompute penalty for inserting new key into subtree + with given subtree's key5
picksplitdetermine which entries of a page are to be moved + to the new page and compute the union keys for resulting pages6
equalcompare two keys and return true if they are equal7
distancedetermine distance from key to query value (optional)8

SP-GiST indexes require five support functions, as + shown in Table 35-10. + (For more information see Chapter 54.) +

Table 35-10. SP-GiST Support Functions

FunctionDescriptionSupport Number
configprovide basic information about the operator class1
choosedetermine how to insert a new value into an inner tuple2
picksplitdetermine how to partition a set of values3
inner_consistentdetermine which sub-partitions need to be searched for a + query4
leaf_consistentdetermine whether key satisfies the + query qualifier5

GIN indexes require four support functions, with an optional fifth, as + shown in Table 35-11. + (For more information see Chapter 55.) +

Table 35-11. GIN Support Functions

FunctionDescriptionSupport Number
compare compare two keys and return an integer less than zero, zero, + or greater than zero, indicating whether the first key is less than, + equal to, or greater than the second + 1
extractValueextract keys from a value to be indexed2
extractQueryextract keys from a query condition3
consistentdetermine whether value matches query condition4
comparePartial compare partial key from + query and key from index, and return an integer less than zero, zero, + or greater than zero, indicating whether GIN should ignore this index + entry, treat the entry as a match, or stop the index scan (optional) + 5

Unlike search operators, support functions return whichever data + type the particular index method expects; for example in the case + of the comparison function for B-trees, a signed integer. The number + and types of the arguments to each support function are likewise + dependent on the index method. For B-tree and hash the comparison and + hashing support functions take the same input data types as do the + operators included in the operator class, but this is not the case for + most GiST, SP-GiST, and GIN support functions. +

35.14.4. An Example

Now that we have seen the ideas, here is the promised example of + creating a new operator class. + (You can find a working copy of this example in + src/tutorial/complex.c and + src/tutorial/complex.sql in the source + distribution.) + The operator class encapsulates + operators that sort complex numbers in absolute value order, so we + choose the name complex_abs_ops. First, we need + a set of operators. The procedure for defining operators was + discussed in Section 35.12. For an operator class on + B-trees, the operators we require are: + +

  • absolute-value less-than (strategy 1)
  • absolute-value less-than-or-equal (strategy 2)
  • absolute-value equal (strategy 3)
  • absolute-value greater-than-or-equal (strategy 4)
  • absolute-value greater-than (strategy 5)

+

The least error-prone way to define a related set of comparison operators + is to write the B-tree comparison support function first, and then write the + other functions as one-line wrappers around the support function. This + reduces the odds of getting inconsistent results for corner cases. + Following this approach, we first write: + +

#define Mag(c)  ((c)->x*(c)->x + (c)->y*(c)->y)
+
+static int
+complex_abs_cmp_internal(Complex *a, Complex *b)
+{
+    double      amag = Mag(a),
+                bmag = Mag(b);
+
+    if (amag < bmag)
+        return -1;
+    if (amag > bmag)
+        return 1;
+    return 0;
+}

+ + Now the less-than function looks like: + +

PG_FUNCTION_INFO_V1(complex_abs_lt);
+
+Datum
+complex_abs_lt(PG_FUNCTION_ARGS)
+{
+    Complex    *a = (Complex *) PG_GETARG_POINTER(0);
+    Complex    *b = (Complex *) PG_GETARG_POINTER(1);
+
+    PG_RETURN_BOOL(complex_abs_cmp_internal(a, b) < 0);
+}

+ + The other four functions differ only in how they compare the internal + function's result to zero. +

Next we declare the functions and the operators based on the functions + to SQL: + +

CREATE FUNCTION complex_abs_lt(complex, complex) RETURNS bool
+    AS 'filename', 'complex_abs_lt'
+    LANGUAGE C IMMUTABLE STRICT;
+
+CREATE OPERATOR < (
+   leftarg = complex, rightarg = complex, procedure = complex_abs_lt,
+   commutator = > , negator = >= ,
+   restrict = scalarltsel, join = scalarltjoinsel
+);

+ It is important to specify the correct commutator and negator operators, + as well as suitable restriction and join selectivity + functions, otherwise the optimizer will be unable to make effective + use of the index. Note that the less-than, equal, and + greater-than cases should use different selectivity functions. +

Other things worth noting are happening here: + +

  • There can only be one operator named, say, = + and taking type complex for both operands. In this + case we don't have any other operator = for + complex, but if we were building a practical data + type we'd probably want = to be the ordinary + equality operation for complex numbers (and not the equality of + the absolute values). In that case, we'd need to use some other + operator name for complex_abs_eq. +

  • Although PostgreSQL can cope with + functions having the same SQL name as long as they have different + argument data types, C can only cope with one global function + having a given name. So we shouldn't name the C function + something simple like abs_eq. Usually it's + a good practice to include the data type name in the C function + name, so as not to conflict with functions for other data types. +

  • We could have made the SQL name + of the function abs_eq, relying on + PostgreSQL to distinguish it by + argument data types from any other SQL function of the same name. + To keep the example simple, we make the function have the same + names at the C level and SQL level. +

+

The next step is the registration of the support routine required + by B-trees. The example C code that implements this is in the same + file that contains the operator functions. This is how we declare + the function: + +

CREATE FUNCTION complex_abs_cmp(complex, complex)
+    RETURNS integer
+    AS 'filename'
+    LANGUAGE C IMMUTABLE STRICT;

+

Now that we have the required operators and support routine, + we can finally create the operator class: + +

CREATE OPERATOR CLASS complex_abs_ops
+    DEFAULT FOR TYPE complex USING btree AS
+        OPERATOR        1       < ,
+        OPERATOR        2       <= ,
+        OPERATOR        3       = ,
+        OPERATOR        4       >= ,
+        OPERATOR        5       > ,
+        FUNCTION        1       complex_abs_cmp(complex, complex);

+

And we're done! It should now be possible to create + and use B-tree indexes on complex columns. +

We could have written the operator entries more verbosely, as in: +

        OPERATOR        1       < (complex, complex) ,

+ but there is no need to do so when the operators take the same data type + we are defining the operator class for. +

The above example assumes that you want to make this new operator class the + default B-tree operator class for the complex data type. + If you don't, just leave out the word DEFAULT. +

35.14.5. Operator Classes and Operator Families

So far we have implicitly assumed that an operator class deals with + only one data type. While there certainly can be only one data type in + a particular index column, it is often useful to index operations that + compare an indexed column to a value of a different data type. Also, + if there is use for a cross-data-type operator in connection with an + operator class, it is often the case that the other data type has a + related operator class of its own. It is helpful to make the connections + between related classes explicit, because this can aid the planner in + optimizing SQL queries (particularly for B-tree operator classes, since + the planner contains a great deal of knowledge about how to work with them). +

To handle these needs, PostgreSQL + uses the concept of an operator + family. + An operator family contains one or more operator classes, and can also + contain indexable operators and corresponding support functions that + belong to the family as a whole but not to any single class within the + family. We say that such operators and functions are "loose" + within the family, as opposed to being bound into a specific class. + Typically each operator class contains single-data-type operators + while cross-data-type operators are loose in the family. +

All the operators and functions in an operator family must have compatible + semantics, where the compatibility requirements are set by the index + method. You might therefore wonder why bother to single out particular + subsets of the family as operator classes; and indeed for many purposes + the class divisions are irrelevant and the family is the only interesting + grouping. The reason for defining operator classes is that they specify + how much of the family is needed to support any particular index. + If there is an index using an operator class, then that operator class + cannot be dropped without dropping the index — but other parts of + the operator family, namely other operator classes and loose operators, + could be dropped. Thus, an operator class should be specified to contain + the minimum set of operators and functions that are reasonably needed + to work with an index on a specific data type, and then related but + non-essential operators can be added as loose members of the operator + family. +

As an example, PostgreSQL has a built-in + B-tree operator family integer_ops, which includes operator + classes int8_ops, int4_ops, and + int2_ops for indexes on bigint (int8), + integer (int4), and smallint (int2) + columns respectively. The family also contains cross-data-type comparison + operators allowing any two of these types to be compared, so that an index + on one of these types can be searched using a comparison value of another + type. The family could be duplicated by these definitions: + +

CREATE OPERATOR FAMILY integer_ops USING btree;
+
+CREATE OPERATOR CLASS int8_ops
+DEFAULT FOR TYPE int8 USING btree FAMILY integer_ops AS
+  -- standard int8 comparisons
+  OPERATOR 1 < ,
+  OPERATOR 2 <= ,
+  OPERATOR 3 = ,
+  OPERATOR 4 >= ,
+  OPERATOR 5 > ,
+  FUNCTION 1 btint8cmp(int8, int8) ,
+  FUNCTION 2 btint8sortsupport(internal) ;
+
+CREATE OPERATOR CLASS int4_ops
+DEFAULT FOR TYPE int4 USING btree FAMILY integer_ops AS
+  -- standard int4 comparisons
+  OPERATOR 1 < ,
+  OPERATOR 2 <= ,
+  OPERATOR 3 = ,
+  OPERATOR 4 >= ,
+  OPERATOR 5 > ,
+  FUNCTION 1 btint4cmp(int4, int4) ,
+  FUNCTION 2 btint4sortsupport(internal) ;
+
+CREATE OPERATOR CLASS int2_ops
+DEFAULT FOR TYPE int2 USING btree FAMILY integer_ops AS
+  -- standard int2 comparisons
+  OPERATOR 1 < ,
+  OPERATOR 2 <= ,
+  OPERATOR 3 = ,
+  OPERATOR 4 >= ,
+  OPERATOR 5 > ,
+  FUNCTION 1 btint2cmp(int2, int2) ,
+  FUNCTION 2 btint2sortsupport(internal) ;
+
+ALTER OPERATOR FAMILY integer_ops USING btree ADD
+  -- cross-type comparisons int8 vs int2
+  OPERATOR 1 < (int8, int2) ,
+  OPERATOR 2 <= (int8, int2) ,
+  OPERATOR 3 = (int8, int2) ,
+  OPERATOR 4 >= (int8, int2) ,
+  OPERATOR 5 > (int8, int2) ,
+  FUNCTION 1 btint82cmp(int8, int2) ,
+
+  -- cross-type comparisons int8 vs int4
+  OPERATOR 1 < (int8, int4) ,
+  OPERATOR 2 <= (int8, int4) ,
+  OPERATOR 3 = (int8, int4) ,
+  OPERATOR 4 >= (int8, int4) ,
+  OPERATOR 5 > (int8, int4) ,
+  FUNCTION 1 btint84cmp(int8, int4) ,
+
+  -- cross-type comparisons int4 vs int2
+  OPERATOR 1 < (int4, int2) ,
+  OPERATOR 2 <= (int4, int2) ,
+  OPERATOR 3 = (int4, int2) ,
+  OPERATOR 4 >= (int4, int2) ,
+  OPERATOR 5 > (int4, int2) ,
+  FUNCTION 1 btint42cmp(int4, int2) ,
+
+  -- cross-type comparisons int4 vs int8
+  OPERATOR 1 < (int4, int8) ,
+  OPERATOR 2 <= (int4, int8) ,
+  OPERATOR 3 = (int4, int8) ,
+  OPERATOR 4 >= (int4, int8) ,
+  OPERATOR 5 > (int4, int8) ,
+  FUNCTION 1 btint48cmp(int4, int8) ,
+
+  -- cross-type comparisons int2 vs int8
+  OPERATOR 1 < (int2, int8) ,
+  OPERATOR 2 <= (int2, int8) ,
+  OPERATOR 3 = (int2, int8) ,
+  OPERATOR 4 >= (int2, int8) ,
+  OPERATOR 5 > (int2, int8) ,
+  FUNCTION 1 btint28cmp(int2, int8) ,
+
+  -- cross-type comparisons int2 vs int4
+  OPERATOR 1 < (int2, int4) ,
+  OPERATOR 2 <= (int2, int4) ,
+  OPERATOR 3 = (int2, int4) ,
+  OPERATOR 4 >= (int2, int4) ,
+  OPERATOR 5 > (int2, int4) ,
+  FUNCTION 1 btint24cmp(int2, int4) ;

+ + Notice that this definition "overloads" the operator strategy and + support function numbers: each number occurs multiple times within the + family. This is allowed so long as each instance of a + particular number has distinct input data types. The instances that have + both input types equal to an operator class's input type are the + primary operators and support functions for that operator class, + and in most cases should be declared as part of the operator class rather + than as loose members of the family. +

In a B-tree operator family, all the operators in the family must sort + compatibly, meaning that the transitive laws hold across all the data types + supported by the family: "if A = B and B = C, then A = C", + and "if A < B and B < C, then A < C". Moreover, implicit + or binary coercion casts between types represented in the operator family + must not change the associated sort ordering. For each + operator in the family there must be a support function having the same + two input data types as the operator. It is recommended that a family be + complete, i.e., for each combination of data types, all operators are + included. Each operator class should include just the non-cross-type + operators and support function for its data type. +

To build a multiple-data-type hash operator family, compatible hash + support functions must be created for each data type supported by the + family. Here compatibility means that the functions are guaranteed to + return the same hash code for any two values that are considered equal + by the family's equality operators, even when the values are of different + types. This is usually difficult to accomplish when the types have + different physical representations, but it can be done in some cases. + Furthermore, casting a value from one data type represented in the operator + family to another data type also represented in the operator family via + an implicit or binary coercion cast must not change the computed hash value. + Notice that there is only one support function per data type, not one + per equality operator. It is recommended that a family be complete, i.e., + provide an equality operator for each combination of data types. + Each operator class should include just the non-cross-type equality + operator and the support function for its data type. +

GiST, SP-GiST, and GIN indexes do not have any explicit notion of + cross-data-type operations. The set of operators supported is just + whatever the primary support functions for a given operator class can + handle. +

Note: Prior to PostgreSQL 8.3, there was no concept + of operator families, and so any cross-data-type operators intended to be + used with an index had to be bound directly into the index's operator + class. While this approach still works, it is deprecated because it + makes an index's dependencies too broad, and because the planner can + handle cross-data-type comparisons more effectively when both data types + have operators in the same operator family. +

35.14.6. System Dependencies on Operator Classes

PostgreSQL uses operator classes to infer the + properties of operators in more ways than just whether they can be used + with indexes. Therefore, you might want to create operator classes + even if you have no intention of indexing any columns of your data type. +

In particular, there are SQL features such as ORDER BY and + DISTINCT that require comparison and sorting of values. + To implement these features on a user-defined data type, + PostgreSQL looks for the default B-tree operator + class for the data type. The "equals" member of this operator + class defines the system's notion of equality of values for + GROUP BY and DISTINCT, and the sort ordering + imposed by the operator class defines the default ORDER BY + ordering. +

Comparison of arrays of user-defined types also relies on the semantics + defined by the default B-tree operator class. +

If there is no default B-tree operator class for a data type, the system + will look for a default hash operator class. But since that kind of + operator class only provides equality, in practice it is only enough + to support array equality. +

When there is no default operator class for a data type, you will get + errors like "could not identify an ordering operator" if you + try to use these SQL features with the data type. +

Note: In PostgreSQL versions before 7.4, + sorting and grouping operations would implicitly use operators named + =, <, and >. The new + behavior of relying on default operator classes avoids having to make + any assumption about the behavior of operators with particular names. +

Another important point is that an operator that + appears in a hash operator family is a candidate for hash joins, + hash aggregation, and related optimizations. The hash operator family + is essential here since it identifies the hash function(s) to use. +

35.14.7. Ordering Operators

Some index access methods (currently, only GiST) support the concept of + ordering operators. What we have been discussing so far + are search operators. A search operator is one for which + the index can be searched to find all rows satisfying + WHERE + indexed_column + operator + constant. + Note that nothing is promised about the order in which the matching rows + will be returned. In contrast, an ordering operator does not restrict the + set of rows that can be returned, but instead determines their order. + An ordering operator is one for which the index can be scanned to return + rows in the order represented by + ORDER BY + indexed_column + operator + constant. + The reason for defining ordering operators that way is that it supports + nearest-neighbor searches, if the operator is one that measures distance. + For example, a query like +

SELECT * FROM places ORDER BY location <-> point '(101,456)' LIMIT 10;

+ finds the ten places closest to a given target point. A GiST index + on the location column can do this efficiently because + <-> is an ordering operator. +

While search operators have to return Boolean results, ordering operators + usually return some other type, such as float or numeric for distances. + This type is normally not the same as the data type being indexed. + To avoid hard-wiring assumptions about the behavior of different data + types, the definition of an ordering operator is required to name + a B-tree operator family that specifies the sort ordering of the result + data type. As was stated in the previous section, B-tree operator families + define PostgreSQL's notion of ordering, so + this is a natural representation. Since the point <-> + operator returns float8, it could be specified in an operator + class creation command like this: +

OPERATOR 15    <-> (point, point) FOR ORDER BY float_ops

+ where float_ops is the built-in operator family that includes + operations on float8. This declaration states that the index + is able to return rows in order of increasing values of the + <-> operator. +

35.14.8. Special Features of Operator Classes

There are two special features of operator classes that we have + not discussed yet, mainly because they are not useful + with the most commonly used index methods. +

Normally, declaring an operator as a member of an operator class + (or family) means that the index method can retrieve exactly the set of rows + that satisfy a WHERE condition using the operator. For example: +

SELECT * FROM table WHERE integer_column < 4;

+ can be satisfied exactly by a B-tree index on the integer column. + But there are cases where an index is useful as an inexact guide to + the matching rows. For example, if a GiST index stores only bounding boxes + for geometric objects, then it cannot exactly satisfy a WHERE + condition that tests overlap between nonrectangular objects such as + polygons. Yet we could use the index to find objects whose bounding + box overlaps the bounding box of the target object, and then do the + exact overlap test only on the objects found by the index. If this + scenario applies, the index is said to be "lossy" for the + operator. Lossy index searches are implemented by having the index + method return a recheck flag when a row might or might + not really satisfy the query condition. The core system will then + test the original query condition on the retrieved row to see whether + it should be returned as a valid match. This approach works if + the index is guaranteed to return all the required rows, plus perhaps + some additional rows, which can be eliminated by performing the original + operator invocation. The index methods that support lossy searches + (currently, GiST, SP-GiST and GIN) allow the support functions of individual + operator classes to set the recheck flag, and so this is essentially an + operator-class feature. +

Consider again the situation where we are storing in the index only + the bounding box of a complex object such as a polygon. In this + case there's not much value in storing the whole polygon in the index + entry — we might as well store just a simpler object of type + box. This situation is expressed by the STORAGE + option in CREATE OPERATOR CLASS: we'd write something like: + +

CREATE OPERATOR CLASS polygon_ops
+    DEFAULT FOR TYPE polygon USING gist AS
+        ...
+        STORAGE box;

+ + At present, only the GiST and GIN index methods support a + STORAGE type that's different from the column data type. + The GiST compress and decompress support + routines must deal with data-type conversion when STORAGE + is used. In GIN, the STORAGE type identifies the type of + the "key" values, which normally is different from the type + of the indexed column — for example, an operator class for + integer-array columns might have keys that are just integers. The + GIN extractValue and extractQuery support + routines are responsible for extracting keys from indexed values. +


PrevHomeNext
Operator Optimization InformationUpPackaging Related Objects into an Extension
\ No newline at end of file diff --git a/doc/src/sgml/html/xml2.html b/doc/src/sgml/html/xml2.html new file mode 100644 index 000000000..004ae199b --- /dev/null +++ b/doc/src/sgml/html/xml2.html @@ -0,0 +1,852 @@ + +xml2
PostgreSQL 9.2.2 Documentation
PrevUpAppendix F. Additional Supplied ModulesNext

F.41. xml2

The xml2 module provides XPath querying and + XSLT functionality. +

F.41.1. Deprecation Notice

From PostgreSQL 8.3 on, there is XML-related + functionality based on the SQL/XML standard in the core server. + That functionality covers XML syntax checking and XPath queries, + which is what this module does, and more, but the API is + not at all compatible. It is planned that this module will be + removed in PostgreSQL 8.4 in favor of the newer standard API, so + you are encouraged to try converting your applications. If you + find that some of the functionality of this module is not + available in an adequate form with the newer API, please explain + your issue to pgsql-hackers@postgresql.org so that the deficiency + can be addressed. +

F.41.2. Description of Functions

Table F-32 shows the functions provided by this module. + These functions provide straightforward XML parsing and XPath queries. + All arguments are of type text, so for brevity that is not shown. +

Table F-32. Functions

FunctionReturnsDescription
xml_is_well_formed(document) + + bool +

This parses the document text in its parameter and returns true if the + document is well-formed XML. (Note: before PostgreSQL 8.2, this + function was called xml_valid(). That is the wrong name + since validity and well-formedness have different meanings in XML. + The old name is still available, but is deprecated.) +

+
xpath_string(document, query) + + text +

These functions evaluate the XPath query on the supplied document, and + cast the result to the specified type. +

+
xpath_number(document, query) + + float4 +
xpath_bool(document, query) + + bool +
xpath_nodeset(document, query, toptag, itemtag) + + text +

This evaluates query on document and wraps the result in XML tags. If + the result is multivalued, the output will look like: +

<toptag>
+<itemtag>Value 1 which could be an XML fragment</itemtag>
+<itemtag>Value 2....</itemtag>
+</toptag>

+ If either toptag or itemtag is an empty string, the relevant tag is omitted. +

+
xpath_nodeset(document, query) + + text +

Like xpath_nodeset(document, query, toptag, itemtag) but result omits both tags. +

+
xpath_nodeset(document, query, itemtag) + + text +

Like xpath_nodeset(document, query, toptag, itemtag) but result omits toptag. +

+
xpath_list(document, query, separator) + + text +

This function returns multiple values separated by the specified + separator, for example Value 1,Value 2,Value 3 if + separator is ,. +

+
xpath_list(document, query) + + text + This is a wrapper for the above function that uses , + as the separator. +

F.41.3. xpath_table

xpath_table(text key, text document, text relation, text xpaths, text criteria) returns setof record

xpath_table is a table function that evaluates a set of XPath + queries on each of a set of documents and returns the results as a + table. The primary key field from the original document table is returned + as the first column of the result so that the result set + can readily be used in joins. The parameters are described in + Table F-33. +

Table F-33. xpath_table Parameters

ParameterDescription
key

the name of the "key" field — this is just a field to be used as + the first column of the output table, i.e., it identifies the record from + which each output row came (see note below about multiple values) +

+
document

the name of the field containing the XML document +

+
relation

the name of the table or view containing the documents +

+
xpaths

one or more XPath expressions, separated by | +

+
criteria

the contents of the WHERE clause. This cannot be omitted, so use + true or 1=1 if you want to + process all the rows in the relation +

+

These parameters (except the XPath strings) are just substituted + into a plain SQL SELECT statement, so you have some flexibility — the + statement is +

SELECT <key>, <document> FROM <relation> WHERE <criteria> + +

so those parameters can be anything valid in those particular + locations. The result from this SELECT needs to return exactly two + columns (which it will unless you try to list multiple fields for key + or document). Beware that this simplistic approach requires that you + validate any user-supplied values to avoid SQL injection attacks. +

The function has to be used in a FROM expression, with an + AS clause to specify the output columns; for example +

SELECT * FROM
+xpath_table('article_id',
+            'article_xml',
+            'articles',
+            '/article/author|/article/pages|/article/title',
+            'date_entered > ''2003-01-01'' ')
+AS t(article_id integer, author text, page_count integer, title text);

+ The AS clause defines the names and types of the columns in the + output table. The first is the "key" field and the rest correspond + to the XPath queries. + If there are more XPath queries than result columns, + the extra queries will be ignored. If there are more result columns + than XPath queries, the extra columns will be NULL. +

Notice that this example defines the page_count result + column as an integer. The function deals internally with string + representations, so when you say you want an integer in the output, it will + take the string representation of the XPath result and use PostgreSQL input + functions to transform it into an integer (or whatever type the AS + clause requests). An error will result if it can't do this — for + example if the result is empty — so you may wish to just stick to + text as the column type if you think your data has any problems. +

The calling SELECT statement doesn't necessarily have be + be just SELECT * — it can reference the output + columns by name or join them to other tables. The function produces a + virtual table with which you can perform any operation you wish (e.g. + aggregation, joining, sorting etc). So we could also have: +

SELECT t.title, p.fullname, p.email
+FROM xpath_table('article_id', 'article_xml', 'articles',
+                 '/article/title|/article/author/@id',
+                 'xpath_string(article_xml,''/article/@date'') > ''2003-03-20'' ')
+       AS t(article_id integer, title text, author_id integer),
+     tblPeopleInfo AS p
+WHERE t.author_id = p.person_id;

+ as a more complicated example. Of course, you could wrap all + of this in a view for convenience. +

F.41.3.1. Multivalued Results

The xpath_table function assumes that the results of each XPath query + might be multivalued, so the number of rows returned by the function + may not be the same as the number of input documents. The first row + returned contains the first result from each query, the second row the + second result from each query. If one of the queries has fewer values + than the others, null values will be returned instead. +

In some cases, a user will know that a given XPath query will return + only a single result (perhaps a unique document identifier) — if used + alongside an XPath query returning multiple results, the single-valued + result will appear only on the first row of the result. The solution + to this is to use the key field as part of a join against a simpler + XPath query. As an example: + +

CREATE TABLE test (
+    id int PRIMARY KEY,
+    xml text
+);
+
+INSERT INTO test VALUES (1, '<doc num="C1">
+<line num="L1"><a>1</a><b>2</b><c>3</c></line>
+<line num="L2"><a>11</a><b>22</b><c>33</c></line>
+</doc>');
+
+INSERT INTO test VALUES (2, '<doc num="C2">
+<line num="L1"><a>111</a><b>222</b><c>333</c></line>
+<line num="L2"><a>111</a><b>222</b><c>333</c></line>
+</doc>');
+
+SELECT * FROM
+  xpath_table('id','xml','test',
+              '/doc/@num|/doc/line/@num|/doc/line/a|/doc/line/b|/doc/line/c',
+              'true')
+  AS t(id int, doc_num varchar(10), line_num varchar(10), val1 int, val2 int, val3 int)
+WHERE id = 1 ORDER BY doc_num, line_num
+
+ id | doc_num | line_num | val1 | val2 | val3
+----+---------+----------+------+------+------
+  1 | C1      | L1       |    1 |    2 |    3
+  1 |         | L2       |   11 |   22 |   33

+

To get doc_num on every line, the solution is to use two invocations + of xpath_table and join the results: + +

SELECT t.*,i.doc_num FROM
+  xpath_table('id', 'xml', 'test',
+              '/doc/line/@num|/doc/line/a|/doc/line/b|/doc/line/c',
+              'true')
+    AS t(id int, line_num varchar(10), val1 int, val2 int, val3 int),
+  xpath_table('id', 'xml', 'test', '/doc/@num', 'true')
+    AS i(id int, doc_num varchar(10))
+WHERE i.id=t.id AND i.id=1
+ORDER BY doc_num, line_num;
+
+ id | line_num | val1 | val2 | val3 | doc_num
+----+----------+------+------+------+---------
+  1 | L1       |    1 |    2 |    3 | C1
+  1 | L2       |   11 |   22 |   33 | C1
+(2 rows)

+

F.41.4. XSLT Functions

The following functions are available if libxslt is installed: +

F.41.4.1. xslt_process

xslt_process(text document, text stylesheet, text paramlist) returns text

This function applies the XSL stylesheet to the document and returns + the transformed result. The paramlist is a list of parameter + assignments to be used in the transformation, specified in the form + a=1,b=2. Note that the + parameter parsing is very simple-minded: parameter values cannot + contain commas! +

There is also a two-parameter version of xslt_process which + does not pass any parameters to the transformation. +

F.41.5. Author

John Gray <jgray@azuli.co.uk> +

Development of this module was sponsored by Torchbox Ltd. (www.torchbox.com). + It has the same BSD licence as PostgreSQL. +


PrevHomeNext
uuid-osspUpAdditional Supplied Programs
\ No newline at end of file diff --git a/doc/src/sgml/html/xoper-optimization.html b/doc/src/sgml/html/xoper-optimization.html new file mode 100644 index 000000000..0bea385c4 --- /dev/null +++ b/doc/src/sgml/html/xoper-optimization.html @@ -0,0 +1,963 @@ + +Operator Optimization Information

35.13. Operator Optimization Information

A PostgreSQL operator definition can include + several optional clauses that tell the system useful things about how + the operator behaves. These clauses should be provided whenever + appropriate, because they can make for considerable speedups in execution + of queries that use the operator. But if you provide them, you must be + sure that they are right! Incorrect use of an optimization clause can + result in slow queries, subtly wrong output, or other Bad Things. + You can always leave out an optimization clause if you are not sure + about it; the only consequence is that queries might run slower than + they need to. +

Additional optimization clauses might be added in future versions of + PostgreSQL. The ones described here are all + the ones that release 9.2.2 understands. +

35.13.1. COMMUTATOR

The COMMUTATOR clause, if provided, names an operator that is the + commutator of the operator being defined. We say that operator A is the + commutator of operator B if (x A y) equals (y B x) for all possible input + values x, y. Notice that B is also the commutator of A. For example, + operators < and > for a particular data type are usually each others' + commutators, and operator + is usually commutative with itself. + But operator - is usually not commutative with anything. +

The left operand type of a commutable operator is the same as the + right operand type of its commutator, and vice versa. So the name of + the commutator operator is all that PostgreSQL + needs to be given to look up the commutator, and that's all that needs to + be provided in the COMMUTATOR clause. +

It's critical to provide commutator information for operators that + will be used in indexes and join clauses, because this allows the + query optimizer to "flip around" such a clause to the forms + needed for different plan types. For example, consider a query with + a WHERE clause like tab1.x = tab2.y, where tab1.x + and tab2.y are of a user-defined type, and suppose that + tab2.y is indexed. The optimizer cannot generate an + index scan unless it can determine how to flip the clause around to + tab2.y = tab1.x, because the index-scan machinery expects + to see the indexed column on the left of the operator it is given. + PostgreSQL will not simply + assume that this is a valid transformation — the creator of the + = operator must specify that it is valid, by marking the + operator with commutator information. +

When you are defining a self-commutative operator, you just do it. + When you are defining a pair of commutative operators, things are + a little trickier: how can the first one to be defined refer to the + other one, which you haven't defined yet? There are two solutions + to this problem: + +

  • One way is to omit the COMMUTATOR clause in the first operator that + you define, and then provide one in the second operator's definition. + Since PostgreSQL knows that commutative + operators come in pairs, when it sees the second definition it will + automatically go back and fill in the missing COMMUTATOR clause in + the first definition. +

  • The other, more straightforward way is just to include COMMUTATOR clauses + in both definitions. When PostgreSQL processes + the first definition and realizes that COMMUTATOR refers to a nonexistent + operator, the system will make a dummy entry for that operator in the + system catalog. This dummy entry will have valid data only + for the operator name, left and right operand types, and result type, + since that's all that PostgreSQL can deduce + at this point. The first operator's catalog entry will link to this + dummy entry. Later, when you define the second operator, the system + updates the dummy entry with the additional information from the second + definition. If you try to use the dummy operator before it's been filled + in, you'll just get an error message. +

+

35.13.2. NEGATOR

The NEGATOR clause, if provided, names an operator that is the + negator of the operator being defined. We say that operator A + is the negator of operator B if both return Boolean results and + (x A y) equals NOT (x B y) for all possible inputs x, y. + Notice that B is also the negator of A. + For example, < and >= are a negator pair for most data types. + An operator can never validly be its own negator. +

Unlike commutators, a pair of unary operators could validly be marked + as each others' negators; that would mean (A x) equals NOT (B x) + for all x, or the equivalent for right unary operators. +

An operator's negator must have the same left and/or right operand types + as the operator to be defined, so just as with COMMUTATOR, only the operator + name need be given in the NEGATOR clause. +

Providing a negator is very helpful to the query optimizer since + it allows expressions like NOT (x = y) to be simplified into + x <> y. This comes up more often than you might think, because + NOT operations can be inserted as a consequence of other rearrangements. +

Pairs of negator operators can be defined using the same methods + explained above for commutator pairs. +

35.13.3. RESTRICT

The RESTRICT clause, if provided, names a restriction selectivity + estimation function for the operator. (Note that this is a function + name, not an operator name.) RESTRICT clauses only make sense for + binary operators that return boolean. The idea behind a restriction + selectivity estimator is to guess what fraction of the rows in a + table will satisfy a WHERE-clause condition of the form: +

column OP constant

+ for the current operator and a particular constant value. + This assists the optimizer by + giving it some idea of how many rows will be eliminated by WHERE + clauses that have this form. (What happens if the constant is on + the left, you might be wondering? Well, that's one of the things that + COMMUTATOR is for...) +

Writing new restriction selectivity estimation functions is far beyond + the scope of this chapter, but fortunately you can usually just use + one of the system's standard estimators for many of your own operators. + These are the standard restriction estimators: +

eqsel for =
neqsel for <>
scalarltsel for < or <=
scalargtsel for > or >=

+ It might seem a little odd that these are the categories, but they + make sense if you think about it. = will typically accept only + a small fraction of the rows in a table; <> will typically reject + only a small fraction. < will accept a fraction that depends on + where the given constant falls in the range of values for that table + column (which, it just so happens, is information collected by + ANALYZE and made available to the selectivity estimator). + <= will accept a slightly larger fraction than < for the same + comparison constant, but they're close enough to not be worth + distinguishing, especially since we're not likely to do better than a + rough guess anyhow. Similar remarks apply to > and >=. +

You can frequently get away with using either eqsel or neqsel for + operators that have very high or very low selectivity, even if they + aren't really equality or inequality. For example, the + approximate-equality geometric operators use eqsel on the assumption that + they'll usually only match a small fraction of the entries in a table. +

You can use scalarltsel and scalargtsel for comparisons on data types that + have some sensible means of being converted into numeric scalars for + range comparisons. If possible, add the data type to those understood + by the function convert_to_scalar() in src/backend/utils/adt/selfuncs.c. + (Eventually, this function should be replaced by per-data-type functions + identified through a column of the pg_type system catalog; but that hasn't happened + yet.) If you do not do this, things will still work, but the optimizer's + estimates won't be as good as they could be. +

There are additional selectivity estimation functions designed for geometric + operators in src/backend/utils/adt/geo_selfuncs.c: areasel, positionsel, + and contsel. At this writing these are just stubs, but you might want + to use them (or even better, improve them) anyway. +

35.13.4. JOIN

The JOIN clause, if provided, names a join selectivity + estimation function for the operator. (Note that this is a function + name, not an operator name.) JOIN clauses only make sense for + binary operators that return boolean. The idea behind a join + selectivity estimator is to guess what fraction of the rows in a + pair of tables will satisfy a WHERE-clause condition of the form: +

table1.column1 OP table2.column2

+ for the current operator. As with the RESTRICT clause, this helps + the optimizer very substantially by letting it figure out which + of several possible join sequences is likely to take the least work. +

As before, this chapter will make no attempt to explain how to write + a join selectivity estimator function, but will just suggest that + you use one of the standard estimators if one is applicable: +

eqjoinsel for =
neqjoinsel for <>
scalarltjoinsel for < or <=
scalargtjoinsel for > or >=
areajoinsel for 2D area-based comparisons
positionjoinsel for 2D position-based comparisons
contjoinsel for 2D containment-based comparisons

+

35.13.5. HASHES

The HASHES clause, if present, tells the system that + it is permissible to use the hash join method for a join based on this + operator. HASHES only makes sense for a binary operator that + returns boolean, and in practice the operator must represent + equality for some data type or pair of data types. +

The assumption underlying hash join is that the join operator can + only return true for pairs of left and right values that hash to the + same hash code. If two values get put in different hash buckets, the + join will never compare them at all, implicitly assuming that the + result of the join operator must be false. So it never makes sense + to specify HASHES for operators that do not represent + some form of equality. In most cases it is only practical to support + hashing for operators that take the same data type on both sides. + However, sometimes it is possible to design compatible hash functions + for two or more data types; that is, functions that will generate the + same hash codes for "equal" values, even though the values + have different representations. For example, it's fairly simple + to arrange this property when hashing integers of different widths. +

To be marked HASHES, the join operator must appear + in a hash index operator family. This is not enforced when you create + the operator, since of course the referencing operator family couldn't + exist yet. But attempts to use the operator in hash joins will fail + at run time if no such operator family exists. The system needs the + operator family to find the data-type-specific hash function(s) for the + operator's input data type(s). Of course, you must also create suitable + hash functions before you can create the operator family. +

Care should be exercised when preparing a hash function, because there + are machine-dependent ways in which it might fail to do the right thing. + For example, if your data type is a structure in which there might be + uninteresting pad bits, you cannot simply pass the whole structure to + hash_any. (Unless you write your other operators and + functions to ensure that the unused bits are always zero, which is the + recommended strategy.) + Another example is that on machines that meet the IEEE + floating-point standard, negative zero and positive zero are different + values (different bit patterns) but they are defined to compare equal. + If a float value might contain negative zero then extra steps are needed + to ensure it generates the same hash value as positive zero. +

A hash-joinable operator must have a commutator (itself if the two + operand data types are the same, or a related equality operator + if they are different) that appears in the same operator family. + If this is not the case, planner errors might occur when the operator + is used. Also, it is a good idea (but not strictly required) for + a hash operator family that supports multiple data types to provide + equality operators for every combination of the data types; this + allows better optimization. +

Note: The function underlying a hash-joinable operator must be marked + immutable or stable. If it is volatile, the system will never + attempt to use the operator for a hash join. +

Note: If a hash-joinable operator has an underlying function that is marked + strict, the + function must also be complete: that is, it should return true or + false, never null, for any two nonnull inputs. If this rule is + not followed, hash-optimization of IN operations might + generate wrong results. (Specifically, IN might return + false where the correct answer according to the standard would be null; + or it might yield an error complaining that it wasn't prepared for a + null result.) +

35.13.6. MERGES

The MERGES clause, if present, tells the system that + it is permissible to use the merge-join method for a join based on this + operator. MERGES only makes sense for a binary operator that + returns boolean, and in practice the operator must represent + equality for some data type or pair of data types. +

Merge join is based on the idea of sorting the left- and right-hand tables + into order and then scanning them in parallel. So, both data types must + be capable of being fully ordered, and the join operator must be one + that can only succeed for pairs of values that fall at the + "same place" + in the sort order. In practice this means that the join operator must + behave like equality. But it is possible to merge-join two + distinct data types so long as they are logically compatible. For + example, the smallint-versus-integer + equality operator is merge-joinable. + We only need sorting operators that will bring both data types into a + logically compatible sequence. +

To be marked MERGES, the join operator must appear + as an equality member of a btree index operator family. + This is not enforced when you create + the operator, since of course the referencing operator family couldn't + exist yet. But the operator will not actually be used for merge joins + unless a matching operator family can be found. The + MERGES flag thus acts as a hint to the planner that + it's worth looking for a matching operator family. +

A merge-joinable operator must have a commutator (itself if the two + operand data types are the same, or a related equality operator + if they are different) that appears in the same operator family. + If this is not the case, planner errors might occur when the operator + is used. Also, it is a good idea (but not strictly required) for + a btree operator family that supports multiple data types to provide + equality operators for every combination of the data types; this + allows better optimization. +

Note: The function underlying a merge-joinable operator must be marked + immutable or stable. If it is volatile, the system will never + attempt to use the operator for a merge join. +


PrevHomeNext
User-defined OperatorsUpInterfacing Extensions To Indexes
\ No newline at end of file diff --git a/doc/src/sgml/html/xoper.html b/doc/src/sgml/html/xoper.html new file mode 100644 index 000000000..1e8605998 --- /dev/null +++ b/doc/src/sgml/html/xoper.html @@ -0,0 +1,270 @@ + +User-defined Operators

35.12. User-defined Operators

Every operator is "syntactic sugar" for a call to an + underlying function that does the real work; so you must + first create the underlying function before you can create + the operator. However, an operator is not merely + syntactic sugar, because it carries additional information + that helps the query planner optimize queries that use the + operator. The next section will be devoted to explaining + that additional information. +

PostgreSQL supports left unary, right + unary, and binary operators. Operators can be + overloaded; + that is, the same operator name can be used for different operators + that have different numbers and types of operands. When a query is + executed, the system determines the operator to call from the + number and types of the provided operands. +

Here is an example of creating an operator for adding two complex + numbers. We assume we've already created the definition of type + complex (see Section 35.11). First we need a + function that does the work, then we can define the operator: + +

CREATE FUNCTION complex_add(complex, complex)
+    RETURNS complex
+    AS 'filename', 'complex_add'
+    LANGUAGE C IMMUTABLE STRICT;
+
+CREATE OPERATOR + (
+    leftarg = complex,
+    rightarg = complex,
+    procedure = complex_add,
+    commutator = +
+);

+

Now we could execute a query like this: + +

SELECT (a + b) AS c FROM test_complex;
+
+        c
+-----------------
+ (5.2,6.05)
+ (133.42,144.95)

+

We've shown how to create a binary operator here. To create unary + operators, just omit one of leftarg (for left unary) or + rightarg (for right unary). The procedure + clause and the argument clauses are the only required items in + CREATE OPERATOR. The commutator + clause shown in the example is an optional hint to the query + optimizer. Further details about commutator and other + optimizer hints appear in the next section. +


PrevHomeNext
User-defined TypesUpOperator Optimization Information
\ No newline at end of file diff --git a/doc/src/sgml/html/xplang-install.html b/doc/src/sgml/html/xplang-install.html new file mode 100644 index 000000000..e4183ef92 --- /dev/null +++ b/doc/src/sgml/html/xplang-install.html @@ -0,0 +1,589 @@ + +Installing Procedural Languages
PostgreSQL 9.2.2 Documentation
PrevUpChapter 38. Procedural LanguagesNext

38.1. Installing Procedural Languages

A procedural language must be "installed" into each + database where it is to be used. But procedural languages installed in + the database template1 are automatically available in all + subsequently created databases, since their entries in + template1 will be copied by CREATE DATABASE. + So the database administrator can + decide which languages are available in which databases and can make + some languages available by default if he chooses. +

For the languages supplied with the standard distribution, it is + only necessary to execute CREATE EXTENSION + language_name to install the language into the + current database. Alternatively, the program createlang can be used to do this from the shell + command line. For example, to install the language + PL/Perl into the database + template1, use: +

createlang plperl template1

+ The manual procedure described below is only recommended for + installing languages that have not been packaged as extensions. +

Manual Procedural Language Installation +

A procedural language is installed in a database in five steps, + which must be carried out by a database superuser. In most cases + the required SQL commands should be packaged as the installation script + of an "extension", so that CREATE EXTENSION can be + used to execute them. +

  1. The shared object for the language handler must be compiled and + installed into an appropriate library directory. This works in the same + way as building and installing modules with regular user-defined C + functions does; see Section 35.9.6. Often, the language + handler will depend on an external library that provides the actual + programming language engine; if so, that must be installed as well. +

  2. The handler must be declared with the command +

    CREATE FUNCTION handler_function_name()
    +    RETURNS language_handler
    +    AS 'path-to-shared-object'
    +    LANGUAGE C;

    + The special return type of language_handler tells + the database system that this function does not return one of + the defined SQL data types and is not directly usable + in SQL statements. +

  3. Optionally, the language handler can provide an "inline" + handler function that executes anonymous code blocks + (DO commands) + written in this language. If an inline handler function + is provided by the language, declare it with a command like +

    CREATE FUNCTION inline_function_name(internal)
    +    RETURNS void
    +    AS 'path-to-shared-object'
    +    LANGUAGE C;

    +

  4. Optionally, the language handler can provide a "validator" + function that checks a function definition for correctness without + actually executing it. The validator function is called by + CREATE FUNCTION if it exists. If a validator function + is provided by the language, declare it with a command like +

    CREATE FUNCTION validator_function_name(oid)
    +    RETURNS void
    +    AS 'path-to-shared-object'
    +    LANGUAGE C STRICT;

    +

  5. Finally, the PL must be declared with the command +

    CREATE [TRUSTED] [PROCEDURAL] LANGUAGE language-name
    +    HANDLER handler_function_name
    +    [INLINE inline_function_name]
    +    [VALIDATOR validator_function_name] ;

    + The optional key word TRUSTED specifies that + the language does not grant access to data that the user would + not otherwise have. Trusted languages are designed for ordinary + database users (those without superuser privilege) and allows them + to safely create functions and trigger + procedures. Since PL functions are executed inside the database + server, the TRUSTED flag should only be given + for languages that do not allow access to database server + internals or the file system. The languages + PL/pgSQL, + PL/Tcl, and + PL/Perl + are considered trusted; the languages + PL/TclU, + PL/PerlU, and + PL/PythonU + are designed to provide unlimited functionality and should + not be marked trusted. +

Example 38-1 shows how the manual + installation procedure would work with the language + PL/Perl. +

Example 38-1. Manual Installation of PL/Perl

The following command tells the database server where to find the + shared object for the PL/Perl language's call + handler function: + +

CREATE FUNCTION plperl_call_handler() RETURNS language_handler AS
+    '$libdir/plperl' LANGUAGE C;

+

PL/Perl has an inline handler function + and a validator function, so we declare those too: + +

CREATE FUNCTION plperl_inline_handler(internal) RETURNS void AS
+    '$libdir/plperl' LANGUAGE C;
+
+CREATE FUNCTION plperl_validator(oid) RETURNS void AS
+    '$libdir/plperl' LANGUAGE C STRICT;

+

The command: +

CREATE TRUSTED PROCEDURAL LANGUAGE plperl
+    HANDLER plperl_call_handler
+    INLINE plperl_inline_handler
+    VALIDATOR plperl_validator;

+ then defines that the previously declared functions + should be invoked for functions and trigger procedures where the + language attribute is plperl. +

In a default PostgreSQL installation, + the handler for the PL/pgSQL language + is built and installed into the "library" + directory; furthermore, the PL/pgSQL language + itself is installed in all databases. + If Tcl support is configured in, the handlers for + PL/Tcl and PL/TclU are built and installed + in the library directory, but the language itself is not installed in any + database by default. + Likewise, the PL/Perl and PL/PerlU + handlers are built and installed if Perl support is configured, and the + PL/PythonU handler is installed if Python support is + configured, but these languages are not installed by default. +


PrevHomeNext
Procedural LanguagesUpPL/pgSQL - SQL Procedural Language
\ No newline at end of file diff --git a/doc/src/sgml/html/xplang.html b/doc/src/sgml/html/xplang.html new file mode 100644 index 000000000..6b13919b0 --- /dev/null +++ b/doc/src/sgml/html/xplang.html @@ -0,0 +1,239 @@ + +Procedural Languages

Chapter 38. Procedural Languages

PostgreSQL allows user-defined functions + to be written in other languages besides SQL and C. These other + languages are generically called procedural + languages (PLs). For a function + written in a procedural language, the database server has + no built-in knowledge about how to interpret the function's source + text. Instead, the task is passed to a special handler that knows + the details of the language. The handler could either do all the + work of parsing, syntax analysis, execution, etc. itself, or it + could serve as "glue" between + PostgreSQL and an existing implementation + of a programming language. The handler itself is a + C language function compiled into a shared object and + loaded on demand, just like any other C function. +

There are currently four procedural languages available in the + standard PostgreSQL distribution: + PL/pgSQL (Chapter 39), + PL/Tcl (Chapter 40), + PL/Perl (Chapter 41), and + PL/Python (Chapter 42). + There are additional procedural languages available that are not + included in the core distribution. Appendix H + has information about finding them. In addition other languages can + be defined by users; the basics of developing a new procedural + language are covered in Chapter 49. +


PrevHomeNext
Rules Versus TriggersUpInstalling Procedural Languages
\ No newline at end of file diff --git a/doc/src/sgml/html/xtypes.html b/doc/src/sgml/html/xtypes.html new file mode 100644 index 000000000..068f5acf1 --- /dev/null +++ b/doc/src/sgml/html/xtypes.html @@ -0,0 +1,563 @@ + +User-defined Types

35.11. User-defined Types

As described in Section 35.2, + PostgreSQL can be extended to support new + data types. This section describes how to define new base types, + which are data types defined below the level of the SQL + language. Creating a new base type requires implementing functions + to operate on the type in a low-level language, usually C. +

The examples in this section can be found in + complex.sql and complex.c + in the src/tutorial directory of the source distribution. + See the README file in that directory for instructions + about running the examples. +

+ + A user-defined type must always have input and output functions. + These functions determine how the type appears in strings (for input + by the user and output to the user) and how the type is organized in + memory. The input function takes a null-terminated character string + as its argument and returns the internal (in memory) representation + of the type. The output function takes the internal representation + of the type as argument and returns a null-terminated character + string. If we want to do anything more with the type than merely + store it, we must provide additional functions to implement whatever + operations we'd like to have for the type. +

Suppose we want to define a type complex that represents + complex numbers. A natural way to represent a complex number in + memory would be the following C structure: + +

typedef struct Complex {
+    double      x;
+    double      y;
+} Complex;

+ + We will need to make this a pass-by-reference type, since it's too + large to fit into a single Datum value. +

As the external string representation of the type, we choose a + string of the form (x,y). +

The input and output functions are usually not hard to write, + especially the output function. But when defining the external + string representation of the type, remember that you must eventually + write a complete and robust parser for that representation as your + input function. For instance: + +

PG_FUNCTION_INFO_V1(complex_in);
+
+Datum
+complex_in(PG_FUNCTION_ARGS)
+{
+    char       *str = PG_GETARG_CSTRING(0);
+    double      x,
+                y;
+    Complex    *result;
+
+    if (sscanf(str, " ( %lf , %lf )", &x, &y) != 2)
+        ereport(ERROR,
+                (errcode(ERRCODE_INVALID_TEXT_REPRESENTATION),
+                 errmsg("invalid input syntax for complex: \"%s\"",
+                        str)));
+
+    result = (Complex *) palloc(sizeof(Complex));
+    result->x = x;
+    result->y = y;
+    PG_RETURN_POINTER(result);
+}

+ + The output function can simply be: + +

PG_FUNCTION_INFO_V1(complex_out);
+
+Datum
+complex_out(PG_FUNCTION_ARGS)
+{
+    Complex    *complex = (Complex *) PG_GETARG_POINTER(0);
+    char       *result;
+
+    result = (char *) palloc(100);
+    snprintf(result, 100, "(%g,%g)", complex->x, complex->y);
+    PG_RETURN_CSTRING(result);
+}

+

You should be careful to make the input and output functions inverses of + each other. If you do not, you will have severe problems when you + need to dump your data into a file and then read it back in. This + is a particularly common problem when floating-point numbers are + involved. +

Optionally, a user-defined type can provide binary input and output + routines. Binary I/O is normally faster but less portable than textual + I/O. As with textual I/O, it is up to you to define exactly what the + external binary representation is. Most of the built-in data types + try to provide a machine-independent binary representation. For + complex, we will piggy-back on the binary I/O converters + for type float8: + +

PG_FUNCTION_INFO_V1(complex_recv);
+
+Datum
+complex_recv(PG_FUNCTION_ARGS)
+{
+    StringInfo  buf = (StringInfo) PG_GETARG_POINTER(0);
+    Complex    *result;
+
+    result = (Complex *) palloc(sizeof(Complex));
+    result->x = pq_getmsgfloat8(buf);
+    result->y = pq_getmsgfloat8(buf);
+    PG_RETURN_POINTER(result);
+}
+
+PG_FUNCTION_INFO_V1(complex_send);
+
+Datum
+complex_send(PG_FUNCTION_ARGS)
+{
+    Complex    *complex = (Complex *) PG_GETARG_POINTER(0);
+    StringInfoData buf;
+
+    pq_begintypsend(&buf);
+    pq_sendfloat8(&buf, complex->x);
+    pq_sendfloat8(&buf, complex->y);
+    PG_RETURN_BYTEA_P(pq_endtypsend(&buf));
+}

+

Once we have written the I/O functions and compiled them into a shared + library, we can define the complex type in SQL. + First we declare it as a shell type: + +

CREATE TYPE complex;

+ + This serves as a placeholder that allows us to reference the type while + defining its I/O functions. Now we can define the I/O functions: + +

CREATE FUNCTION complex_in(cstring)
+    RETURNS complex
+    AS 'filename'
+    LANGUAGE C IMMUTABLE STRICT;
+
+CREATE FUNCTION complex_out(complex)
+    RETURNS cstring
+    AS 'filename'
+    LANGUAGE C IMMUTABLE STRICT;
+
+CREATE FUNCTION complex_recv(internal)
+   RETURNS complex
+   AS 'filename'
+   LANGUAGE C IMMUTABLE STRICT;
+
+CREATE FUNCTION complex_send(complex)
+   RETURNS bytea
+   AS 'filename'
+   LANGUAGE C IMMUTABLE STRICT;

+

Finally, we can provide the full definition of the data type: +

CREATE TYPE complex (
+   internallength = 16,
+   input = complex_in,
+   output = complex_out,
+   receive = complex_recv,
+   send = complex_send,
+   alignment = double
+);

+

+ When you define a new base type, + PostgreSQL automatically provides support + for arrays of that type. The array type typically + has the same name as the base type with the underscore character + (_) prepended. +

Once the data type exists, we can declare additional functions to + provide useful operations on the data type. Operators can then be + defined atop the functions, and if needed, operator classes can be + created to support indexing of the data type. These additional + layers are discussed in following sections. +

+ If the values of your data type vary in size (in internal form), you should + make the data type TOAST-able (see Section 56.2). You should do this even if the data are always + too small to be compressed or stored externally, because + TOAST can save space on small data too, by reducing header + overhead. +

To do this, the internal representation must follow the standard layout for + variable-length data: the first four bytes must be a char[4] + field which is never accessed directly (customarily named + vl_len_). You + must use SET_VARSIZE() to store the size of the datum + in this field and VARSIZE() to retrieve it. The C + functions operating on the data type must always be careful to unpack any + toasted values they are handed, by using PG_DETOAST_DATUM. + (This detail is customarily hidden by defining type-specific + GETARG_DATATYPE_P macros.) Then, when running the + CREATE TYPE command, specify the internal length as + variable and select the appropriate storage option. +

If the alignment is unimportant (either just for a specific function or + because the data type specifies byte alignment anyway) then it's possible + to avoid some of the overhead of PG_DETOAST_DATUM. You can use + PG_DETOAST_DATUM_PACKED instead (customarily hidden by + defining a GETARG_DATATYPE_PP macro) and using the macros + VARSIZE_ANY_EXHDR and VARDATA_ANY to access + a potentially-packed datum. + Again, the data returned by these macros is not aligned even if the data + type definition specifies an alignment. If the alignment is important you + must go through the regular PG_DETOAST_DATUM interface. +

Note: Older code frequently declares vl_len_ as an + int32 field instead of char[4]. This is OK as long as + the struct definition has other fields that have at least int32 + alignment. But it is dangerous to use such a struct definition when + working with a potentially unaligned datum; the compiler may take it as + license to assume the datum actually is aligned, leading to core dumps on + architectures that are strict about alignment. +

For further details see the description of the + CREATE TYPE command. +


PrevHomeNext
User-defined AggregatesUpUser-defined Operators
\ No newline at end of file diff --git a/doc/src/sgml/man-stamp b/doc/src/sgml/man-stamp new file mode 100644 index 000000000..e69de29bb diff --git a/doc/src/sgml/man1/clusterdb.1 b/doc/src/sgml/man1/clusterdb.1 new file mode 100644 index 000000000..af0688625 --- /dev/null +++ b/doc/src/sgml/man1/clusterdb.1 @@ -0,0 +1,209 @@ +'\" t +.\" Title: clusterdb +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CLUSTERDB" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +clusterdb \- cluster a PostgreSQL database +.\" clusterdb +.SH "SYNOPSIS" +.HP \w'\fBclusterdb\fR\ 'u +\fBclusterdb\fR [\fIconnection\-option\fR...] [\fB\-\-verbose\fR | \fB\-v\fR] [\fB\-\-table\fR\ |\ \fB\-t\fR\ \fItable\fR] [\fIdbname\fR] +.HP \w'\fBclusterdb\fR\ 'u +\fBclusterdb\fR [\fIconnection\-option\fR...] [\fB\-\-verbose\fR | \fB\-v\fR] \fB\-\-all\fR | \fB\-a\fR +.SH "DESCRIPTION" +.PP + +clusterdb +is a utility for reclustering tables in a +PostgreSQL +database\&. It finds tables that have previously been clustered, and clusters them again on the same index that was last used\&. Tables that have never been clustered are not affected\&. +.PP + +clusterdb +is a wrapper around the SQL command +\fBCLUSTER\fR(7)\&. There is no effective difference between clustering databases via this utility and via other methods for accessing the server\&. +.SH "OPTIONS" +.PP + +clusterdb +accepts the following command\-line arguments: +.PP +\fB\-a\fR, \fB\-\-all\fR +.RS 4 +Cluster all databases\&. +.RE +.PP +\fB[\-d]\fR\fB \fR\fB\fIdbname\fR\fR, \fB[\-\-dbname=]\fR\fB\fIdbname\fR\fR +.RS 4 +Specifies the name of the database to be clustered\&. If this is not specified and +\fB\-a\fR +(or +\fB\-\-all\fR) is not used, the database name is read from the environment variable +\fBPGDATABASE\fR\&. If that is not set, the user name specified for the connection is used\&. +.RE +.PP +\fB\-e\fR, \fB\-\-echo\fR +.RS 4 +Echo the commands that +clusterdb +generates and sends to the server\&. +.RE +.PP +\fB\-q\fR, \fB\-\-quiet\fR +.RS 4 +Do not display progress messages\&. +.RE +.PP +\fB\-t \fR\fB\fItable\fR\fR, \fB\-\-table=\fR\fB\fItable\fR\fR +.RS 4 +Cluster +\fItable\fR +only\&. +.RE +.PP +\fB\-v\fR, \fB\-\-verbose\fR +.RS 4 +Print detailed information during processing\&. +.RE +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +clusterdb +version and exit\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +clusterdb +command line arguments, and exit\&. +.RE +.PP + +clusterdb +also accepts the following command\-line arguments for connection parameters: +.PP +\fB\-h \fR\fB\fIhost\fR\fR, \fB\-\-host=\fR\fB\fIhost\fR\fR +.RS 4 +Specifies the host name of the machine on which the server is running\&. If the value begins with a slash, it is used as the directory for the Unix domain socket\&. +.RE +.PP +\fB\-p \fR\fB\fIport\fR\fR, \fB\-\-port=\fR\fB\fIport\fR\fR +.RS 4 +Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections\&. +.RE +.PP +\fB\-U \fR\fB\fIusername\fR\fR, \fB\-\-username=\fR\fB\fIusername\fR\fR +.RS 4 +User name to connect as\&. +.RE +.PP +\fB\-w\fR, \fB\-\-no\-password\fR +.RS 4 +Never issue a password prompt\&. If the server requires password authentication and a password is not available by other means such as a +\&.pgpass +file, the connection attempt will fail\&. This option can be useful in batch jobs and scripts where no user is present to enter a password\&. +.RE +.PP +\fB\-W\fR, \fB\-\-password\fR +.RS 4 +Force +clusterdb +to prompt for a password before connecting to a database\&. +.sp +This option is never essential, since +clusterdb +will automatically prompt for a password if the server demands password authentication\&. However, +clusterdb +will waste a connection attempt finding out that the server wants a password\&. In some cases it is worth typing +\fB\-W\fR +to avoid the extra connection attempt\&. +.RE +.PP +\fB\-\-maintenance\-db=\fR\fB\fIdbname\fR\fR +.RS 4 +Specifies the name of the database to connect to discover what other databases should be clustered\&. If not specified, the +postgres +database will be used, and if that does not exist, +template1 +will be used\&. +.RE +.SH "ENVIRONMENT" +.PP +\fBPGDATABASE\fR, \fBPGHOST\fR, \fBPGPORT\fR, \fBPGUSER\fR +.RS 4 +Default connection parameters +.RE +.PP +This utility, like most other +PostgreSQL +utilities, also uses the environment variables supported by +libpq +(see +Section 31.14, \(lqEnvironment Variables\(rq, in the documentation)\&. +.SH "DIAGNOSTICS" +.PP +In case of difficulty, see +\fBCLUSTER\fR(7) +and +\fBpsql\fR(1) +for discussions of potential problems and error messages\&. The database server must be running at the targeted host\&. Also, any default connection settings and environment variables used by the +libpq +front\-end library will apply\&. +.SH "EXAMPLES" +.PP +To cluster the database +test: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBclusterdb test\fR +.fi +.if n \{\ +.RE +.\} +.PP +To cluster a single table +foo +in a database named +xyzzy: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBclusterdb \-\-table foo xyzzy\fR +.fi +.if n \{\ +.RE +.\} +.SH "SEE ALSO" +\fBCLUSTER\fR(7) diff --git a/doc/src/sgml/man1/createdb.1 b/doc/src/sgml/man1/createdb.1 new file mode 100644 index 000000000..360648adc --- /dev/null +++ b/doc/src/sgml/man1/createdb.1 @@ -0,0 +1,256 @@ +'\" t +.\" Title: createdb +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATEDB" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +createdb \- create a new PostgreSQL database +.\" createdb +.SH "SYNOPSIS" +.HP \w'\fBcreatedb\fR\ 'u +\fBcreatedb\fR [\fIconnection\-option\fR...] [\fIoption\fR...] [\fIdbname\fR\ [\fIdescription\fR]] +.SH "DESCRIPTION" +.PP + +createdb +creates a new +PostgreSQL +database\&. +.PP +Normally, the database user who executes this command becomes the owner of the new database\&. However, a different owner can be specified via the +\fB\-O\fR +option, if the executing user has appropriate privileges\&. +.PP + +createdb +is a wrapper around the +SQL +command +CREATE DATABASE (\fBCREATE_DATABASE\fR(7))\&. There is no effective difference between creating databases via this utility and via other methods for accessing the server\&. +.SH "OPTIONS" +.PP + +createdb +accepts the following command\-line arguments: +.PP +\fIdbname\fR +.RS 4 +Specifies the name of the database to be created\&. The name must be unique among all +PostgreSQL +databases in this cluster\&. The default is to create a database with the same name as the current system user\&. +.RE +.PP +\fIdescription\fR +.RS 4 +Specifies a comment to be associated with the newly created database\&. +.RE +.PP +\fB\-D \fR\fB\fItablespace\fR\fR, \fB\-\-tablespace=\fR\fB\fItablespace\fR\fR +.RS 4 +Specifies the default tablespace for the database\&. (This name is processed as a double\-quoted identifier\&.) +.RE +.PP +\fB\-e\fR, \fB\-\-echo\fR +.RS 4 +Echo the commands that +createdb +generates and sends to the server\&. +.RE +.PP +\fB\-E \fR\fB\fIencoding\fR\fR, \fB\-\-encoding=\fR\fB\fIencoding\fR\fR +.RS 4 +Specifies the character encoding scheme to be used in this database\&. The character sets supported by the +PostgreSQL +server are described in +Section 22.3.1, \(lqSupported Character Sets\(rq, in the documentation\&. +.RE +.PP +\fB\-l \fR\fB\fIlocale\fR\fR, \fB\-\-locale=\fR\fB\fIlocale\fR\fR +.RS 4 +Specifies the locale to be used in this database\&. This is equivalent to specifying both +\fB\-\-lc\-collate\fR +and +\fB\-\-lc\-ctype\fR\&. +.RE +.PP +\fB\-\-lc\-collate=\fR\fB\fIlocale\fR\fR +.RS 4 +Specifies the LC_COLLATE setting to be used in this database\&. +.RE +.PP +\fB\-\-lc\-ctype=\fR\fB\fIlocale\fR\fR +.RS 4 +Specifies the LC_CTYPE setting to be used in this database\&. +.RE +.PP +\fB\-O \fR\fB\fIowner\fR\fR, \fB\-\-owner=\fR\fB\fIowner\fR\fR +.RS 4 +Specifies the database user who will own the new database\&. (This name is processed as a double\-quoted identifier\&.) +.RE +.PP +\fB\-T \fR\fB\fItemplate\fR\fR, \fB\-\-template=\fR\fB\fItemplate\fR\fR +.RS 4 +Specifies the template database from which to build this database\&. (This name is processed as a double\-quoted identifier\&.) +.RE +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +createdb +version and exit\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +createdb +command line arguments, and exit\&. +.RE +.PP +The options +\fB\-D\fR, +\fB\-l\fR, +\fB\-E\fR, +\fB\-O\fR, and +\fB\-T\fR +correspond to options of the underlying SQL command +CREATE DATABASE (\fBCREATE_DATABASE\fR(7)); see there for more information about them\&. +.PP + +createdb +also accepts the following command\-line arguments for connection parameters: +.PP +\fB\-h \fR\fB\fIhost\fR\fR, \fB\-\-host=\fR\fB\fIhost\fR\fR +.RS 4 +Specifies the host name of the machine on which the server is running\&. If the value begins with a slash, it is used as the directory for the Unix domain socket\&. +.RE +.PP +\fB\-p \fR\fB\fIport\fR\fR, \fB\-\-port=\fR\fB\fIport\fR\fR +.RS 4 +Specifies the TCP port or the local Unix domain socket file extension on which the server is listening for connections\&. +.RE +.PP +\fB\-U \fR\fB\fIusername\fR\fR, \fB\-\-username=\fR\fB\fIusername\fR\fR +.RS 4 +User name to connect as\&. +.RE +.PP +\fB\-w\fR, \fB\-\-no\-password\fR +.RS 4 +Never issue a password prompt\&. If the server requires password authentication and a password is not available by other means such as a +\&.pgpass +file, the connection attempt will fail\&. This option can be useful in batch jobs and scripts where no user is present to enter a password\&. +.RE +.PP +\fB\-W\fR, \fB\-\-password\fR +.RS 4 +Force +createdb +to prompt for a password before connecting to a database\&. +.sp +This option is never essential, since +createdb +will automatically prompt for a password if the server demands password authentication\&. However, +createdb +will waste a connection attempt finding out that the server wants a password\&. In some cases it is worth typing +\fB\-W\fR +to avoid the extra connection attempt\&. +.RE +.PP +\fB\-\-maintenance\-db=\fR\fB\fIdbname\fR\fR +.RS 4 +Specifies the name of the database to connect to when creating the new database\&. If not specified, the +postgres +database will be used; if that does not exist (or if it is the name of the new database being created), +template1 +will be used\&. +.RE +.SH "ENVIRONMENT" +.PP +\fBPGDATABASE\fR +.RS 4 +If set, the name of the database to create, unless overridden on the command line\&. +.RE +.PP +\fBPGHOST\fR, \fBPGPORT\fR, \fBPGUSER\fR +.RS 4 +Default connection parameters\&. +\fBPGUSER\fR +also determines the name of the database to create, if it is not specified on the command line or by +\fBPGDATABASE\fR\&. +.RE +.PP +This utility, like most other +PostgreSQL +utilities, also uses the environment variables supported by +libpq +(see +Section 31.14, \(lqEnvironment Variables\(rq, in the documentation)\&. +.SH "DIAGNOSTICS" +.PP +In case of difficulty, see +CREATE DATABASE (\fBCREATE_DATABASE\fR(7)) +and +\fBpsql\fR(1) +for discussions of potential problems and error messages\&. The database server must be running at the targeted host\&. Also, any default connection settings and environment variables used by the +libpq +front\-end library will apply\&. +.SH "EXAMPLES" +.PP +To create the database +demo +using the default database server: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBcreatedb demo\fR +.fi +.if n \{\ +.RE +.\} +.PP +To create the database +demo +using the server on host +eden, port 5000, using the +LATIN1 +encoding scheme with a look at the underlying command: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBcreatedb \-p 5000 \-h eden \-E LATIN1 \-e demo\fR +CREATE DATABASE demo ENCODING \*(AqLATIN1\*(Aq; +.fi +.if n \{\ +.RE +.\} +.SH "SEE ALSO" +\fBdropdb\fR(1), CREATE DATABASE (\fBCREATE_DATABASE\fR(7)) diff --git a/doc/src/sgml/man1/createlang.1 b/doc/src/sgml/man1/createlang.1 new file mode 100644 index 000000000..184b59039 --- /dev/null +++ b/doc/src/sgml/man1/createlang.1 @@ -0,0 +1,203 @@ +'\" t +.\" Title: createlang +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATELANG" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +createlang \- install a PostgreSQL procedural language +.\" createlang +.SH "SYNOPSIS" +.HP \w'\fBcreatelang\fR\ 'u +\fBcreatelang\fR [\fIconnection\-option\fR...] \fIlangname\fR [\fIdbname\fR] +.HP \w'\fBcreatelang\fR\ 'u +\fBcreatelang\fR [\fIconnection\-option\fR...] \fB\-\-list\fR | \fB\-l\fR [\fIdbname\fR] +.SH "DESCRIPTION" +.PP + +createlang +is a utility for adding a procedural language to a +PostgreSQL +database\&. +.PP + +createlang +is just a wrapper around the +CREATE EXTENSION (\fBCREATE_EXTENSION\fR(7)) +SQL command\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBCaution\fR +.ps -1 +.br +.PP + +createlang +is deprecated and may be removed in a future +PostgreSQL +release\&. Direct use of the +\fBCREATE EXTENSION\fR +command is recommended instead\&. +.sp .5v +.RE +.SH "OPTIONS" +.PP + +createlang +accepts the following command\-line arguments: +.PP +\fIlangname\fR +.RS 4 +Specifies the name of the procedural language to be installed\&. (This name is lower\-cased\&.) +.RE +.PP +\fB[\-d]\fR\fB \fR\fB\fIdbname\fR\fR, \fB[\-\-dbname=]\fR\fB\fIdbname\fR\fR +.RS 4 +Specifies the database to which the language should be added\&. The default is to use the database with the same name as the current system user\&. +.RE +.PP +\fB\-e\fR, \fB\-\-echo\fR +.RS 4 +Display SQL commands as they are executed\&. +.RE +.PP +\fB\-l\fR, \fB\-\-list\fR +.RS 4 +Show a list of already installed languages in the target database\&. +.RE +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +createlang +version and exit\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +createlang +command line arguments, and exit\&. +.RE +.PP + +createlang +also accepts the following command\-line arguments for connection parameters: +.PP +\fB\-h \fR\fB\fIhost\fR\fR, \fB\-\-host=\fR\fB\fIhost\fR\fR +.RS 4 +Specifies the host name of the machine on which the server is running\&. If the value begins with a slash, it is used as the directory for the Unix domain socket\&. +.RE +.PP +\fB\-p \fR\fB\fIport\fR\fR, \fB\-\-port=\fR\fB\fIport\fR\fR +.RS 4 +Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections\&. +.RE +.PP +\fB\-U \fR\fB\fIusername\fR\fR, \fB\-\-username=\fR\fB\fIusername\fR\fR +.RS 4 +User name to connect as\&. +.RE +.PP +\fB\-w\fR, \fB\-\-no\-password\fR +.RS 4 +Never issue a password prompt\&. If the server requires password authentication and a password is not available by other means such as a +\&.pgpass +file, the connection attempt will fail\&. This option can be useful in batch jobs and scripts where no user is present to enter a password\&. +.RE +.PP +\fB\-W\fR, \fB\-\-password\fR +.RS 4 +Force +createlang +to prompt for a password before connecting to a database\&. +.sp +This option is never essential, since +createlang +will automatically prompt for a password if the server demands password authentication\&. However, +createlang +will waste a connection attempt finding out that the server wants a password\&. In some cases it is worth typing +\fB\-W\fR +to avoid the extra connection attempt\&. +.RE +.SH "ENVIRONMENT" +.PP +\fBPGDATABASE\fR, \fBPGHOST\fR, \fBPGPORT\fR, \fBPGUSER\fR +.RS 4 +Default connection parameters +.RE +.PP +This utility, like most other +PostgreSQL +utilities, also uses the environment variables supported by +libpq +(see +Section 31.14, \(lqEnvironment Variables\(rq, in the documentation)\&. +.SH "DIAGNOSTICS" +.PP +Most error messages are self\-explanatory\&. If not, run +createlang +with the +\fB\-\-echo\fR +option and see the respective +SQL +command for details\&. Also, any default connection settings and environment variables used by the +libpq +front\-end library will apply\&. +.SH "NOTES" +.PP +Use +\fBdroplang\fR(1) +to remove a language\&. +.SH "EXAMPLES" +.PP +To install the language +pltcl +into the database +template1: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBcreatelang pltcl template1\fR +.fi +.if n \{\ +.RE +.\} +.sp +Note that installing the language into +template1 +will cause it to be automatically installed into subsequently\-created databases as well\&. +.SH "SEE ALSO" +\fBdroplang\fR(1), CREATE EXTENSION (\fBCREATE_EXTENSION\fR(7)), CREATE LANGUAGE (\fBCREATE_LANGUAGE\fR(7)) diff --git a/doc/src/sgml/man1/createuser.1 b/doc/src/sgml/man1/createuser.1 new file mode 100644 index 000000000..4ba69829e --- /dev/null +++ b/doc/src/sgml/man1/createuser.1 @@ -0,0 +1,331 @@ +'\" t +.\" Title: createuser +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATEUSER" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +createuser \- define a new PostgreSQL user account +.\" createuser +.SH "SYNOPSIS" +.HP \w'\fBcreateuser\fR\ 'u +\fBcreateuser\fR [\fIconnection\-option\fR...] [\fIoption\fR...] [\fIusername\fR] +.SH "DESCRIPTION" +.PP + +createuser +creates a new +PostgreSQL +user (or more precisely, a role)\&. Only superusers and users with +CREATEROLE +privilege can create new users, so +createuser +must be invoked by someone who can connect as a superuser or a user with +CREATEROLE +privilege\&. +.PP +If you wish to create a new superuser, you must connect as a superuser, not merely with +CREATEROLE +privilege\&. Being a superuser implies the ability to bypass all access permission checks within the database, so superuserdom should not be granted lightly\&. +.PP + +createuser +is a wrapper around the +SQL +command +CREATE ROLE (\fBCREATE_ROLE\fR(7))\&. There is no effective difference between creating users via this utility and via other methods for accessing the server\&. +.SH "OPTIONS" +.PP + +createuser +accepts the following command\-line arguments: +.PP +\fIusername\fR +.RS 4 +Specifies the name of the +PostgreSQL +user to be created\&. This name must be different from all existing roles in this +PostgreSQL +installation\&. +.RE +.PP +\fB\-c \fR\fB\fInumber\fR\fR, \fB\-\-connection\-limit=\fR\fB\fInumber\fR\fR +.RS 4 +Set a maximum number of connections for the new user\&. The default is to set no limit\&. +.RE +.PP +\fB\-d\fR, \fB\-\-createdb\fR +.RS 4 +The new user will be allowed to create databases\&. +.RE +.PP +\fB\-D\fR, \fB\-\-no\-createdb\fR +.RS 4 +The new user will not be allowed to create databases\&. This is the default\&. +.RE +.PP +\fB\-e\fR, \fB\-\-echo\fR +.RS 4 +Echo the commands that +createuser +generates and sends to the server\&. +.RE +.PP +\fB\-E\fR, \fB\-\-encrypted\fR +.RS 4 +Encrypts the user\*(Aqs password stored in the database\&. If not specified, the default password behavior is used\&. +.RE +.PP +\fB\-i\fR, \fB\-\-inherit\fR +.RS 4 +The new role will automatically inherit privileges of roles it is a member of\&. This is the default\&. +.RE +.PP +\fB\-I\fR, \fB\-\-no\-inherit\fR +.RS 4 +The new role will not automatically inherit privileges of roles it is a member of\&. +.RE +.PP +\fB\-\-interactive\fR +.RS 4 +Prompt for the user name if none is specified on the command line, and also prompt for whichever of the options +\fB\-d\fR/\fB\-D\fR, +\fB\-r\fR/\fB\-R\fR, +\fB\-s\fR/\fB\-S\fR +is not specified on the command line\&. (This was the default behavior up to PostgreSQL 9\&.1\&.) +.RE +.PP +\fB\-l\fR, \fB\-\-login\fR +.RS 4 +The new user will be allowed to log in (that is, the user name can be used as the initial session user identifier)\&. This is the default\&. +.RE +.PP +\fB\-L\fR, \fB\-\-no\-login\fR +.RS 4 +The new user will not be allowed to log in\&. (A role without login privilege is still useful as a means of managing database permissions\&.) +.RE +.PP +\fB\-N\fR, \fB\-\-unencrypted\fR +.RS 4 +Does not encrypt the user\*(Aqs password stored in the database\&. If not specified, the default password behavior is used\&. +.RE +.PP +\fB\-P\fR, \fB\-\-pwprompt\fR +.RS 4 +If given, +createuser +will issue a prompt for the password of the new user\&. This is not necessary if you do not plan on using password authentication\&. +.RE +.PP +\fB\-r\fR, \fB\-\-createrole\fR +.RS 4 +The new user will be allowed to create new roles (that is, this user will have +CREATEROLE +privilege)\&. +.RE +.PP +\fB\-R\fR, \fB\-\-no\-createrole\fR +.RS 4 +The new user will not be allowed to create new roles\&. This is the default\&. +.RE +.PP +\fB\-s\fR, \fB\-\-superuser\fR +.RS 4 +The new user will be a superuser\&. +.RE +.PP +\fB\-S\fR, \fB\-\-no\-superuser\fR +.RS 4 +The new user will not be a superuser\&. This is the default\&. +.RE +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +createuser +version and exit\&. +.RE +.PP +\fB\-\-replication\fR +.RS 4 +The new user will have the +REPLICATION +privilege, which is described more fully in the documentation for +CREATE ROLE (\fBCREATE_ROLE\fR(7))\&. +.RE +.PP +\fB\-\-no\-replication\fR +.RS 4 +The new user will not have the +REPLICATION +privilege, which is described more fully in the documentation for +CREATE ROLE (\fBCREATE_ROLE\fR(7))\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +createuser +command line arguments, and exit\&. +.RE +.PP + +createuser +also accepts the following command\-line arguments for connection parameters: +.PP +\fB\-h \fR\fB\fIhost\fR\fR, \fB\-\-host=\fR\fB\fIhost\fR\fR +.RS 4 +Specifies the host name of the machine on which the server is running\&. If the value begins with a slash, it is used as the directory for the Unix domain socket\&. +.RE +.PP +\fB\-p \fR\fB\fIport\fR\fR, \fB\-\-port=\fR\fB\fIport\fR\fR +.RS 4 +Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections\&. +.RE +.PP +\fB\-U \fR\fB\fIusername\fR\fR, \fB\-\-username=\fR\fB\fIusername\fR\fR +.RS 4 +User name to connect as (not the user name to create)\&. +.RE +.PP +\fB\-w\fR, \fB\-\-no\-password\fR +.RS 4 +Never issue a password prompt\&. If the server requires password authentication and a password is not available by other means such as a +\&.pgpass +file, the connection attempt will fail\&. This option can be useful in batch jobs and scripts where no user is present to enter a password\&. +.RE +.PP +\fB\-W\fR, \fB\-\-password\fR +.RS 4 +Force +createuser +to prompt for a password (for connecting to the server, not for the password of the new user)\&. +.sp +This option is never essential, since +createuser +will automatically prompt for a password if the server demands password authentication\&. However, +createuser +will waste a connection attempt finding out that the server wants a password\&. In some cases it is worth typing +\fB\-W\fR +to avoid the extra connection attempt\&. +.RE +.SH "ENVIRONMENT" +.PP +\fBPGHOST\fR, \fBPGPORT\fR, \fBPGUSER\fR +.RS 4 +Default connection parameters +.RE +.PP +This utility, like most other +PostgreSQL +utilities, also uses the environment variables supported by +libpq +(see +Section 31.14, \(lqEnvironment Variables\(rq, in the documentation)\&. +.SH "DIAGNOSTICS" +.PP +In case of difficulty, see +CREATE ROLE (\fBCREATE_ROLE\fR(7)) +and +\fBpsql\fR(1) +for discussions of potential problems and error messages\&. The database server must be running at the targeted host\&. Also, any default connection settings and environment variables used by the +libpq +front\-end library will apply\&. +.SH "EXAMPLES" +.PP +To create a user +joe +on the default database server: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBcreateuser joe\fR +.fi +.if n \{\ +.RE +.\} +.PP +To create a user +joe +on the default database server with prompting for some additional attributes: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBcreateuser \-\-interactive joe\fR +Shall the new role be a superuser? (y/n) \fBn\fR +Shall the new role be allowed to create databases? (y/n) \fBn\fR +Shall the new role be allowed to create more new roles? (y/n) \fBn\fR +.fi +.if n \{\ +.RE +.\} +.PP +To create the same user +joe +using the server on host +eden, port 5000, with attributes explicitly specified, taking a look at the underlying command: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBcreateuser \-h eden \-p 5000 \-S \-D \-R \-e joe\fR +CREATE ROLE joe NOSUPERUSER NOCREATEDB NOCREATEROLE INHERIT LOGIN; +.fi +.if n \{\ +.RE +.\} +.PP +To create the user +joe +as a superuser, and assign a password immediately: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBcreateuser \-P \-s \-e joe\fR +Enter password for new role: \fBxyzzy\fR +Enter it again: \fBxyzzy\fR +CREATE ROLE joe PASSWORD \*(Aqmd5b5f5ba1a423792b526f799ae4eb3d59e\*(Aq SUPERUSER CREATEDB CREATEROLE INHERIT LOGIN; +.fi +.if n \{\ +.RE +.\} +.sp +In the above example, the new password isn\*(Aqt actually echoed when typed, but we show what was typed for clarity\&. As you see, the password is encrypted before it is sent to the client\&. If the option +\fB\-\-unencrypted\fR +is used, the password +\fIwill\fR +appear in the echoed command (and possibly also in the server log and elsewhere), so you don\*(Aqt want to use +\fB\-e\fR +in that case, if anyone else can see your screen\&. +.SH "SEE ALSO" +\fBdropuser\fR(1), CREATE ROLE (\fBCREATE_ROLE\fR(7)) diff --git a/doc/src/sgml/man1/dropdb.1 b/doc/src/sgml/man1/dropdb.1 new file mode 100644 index 000000000..b92eb5e32 --- /dev/null +++ b/doc/src/sgml/man1/dropdb.1 @@ -0,0 +1,197 @@ +'\" t +.\" Title: dropdb +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROPDB" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +dropdb \- remove a PostgreSQL database +.\" dropdb +.SH "SYNOPSIS" +.HP \w'\fBdropdb\fR\ 'u +\fBdropdb\fR [\fIconnection\-option\fR...] [\fIoption\fR...] \fIdbname\fR +.SH "DESCRIPTION" +.PP + +dropdb +destroys an existing +PostgreSQL +database\&. The user who executes this command must be a database superuser or the owner of the database\&. +.PP + +dropdb +is a wrapper around the +SQL +command +DROP DATABASE (\fBDROP_DATABASE\fR(7))\&. There is no effective difference between dropping databases via this utility and via other methods for accessing the server\&. +.SH "OPTIONS" +.PP + +dropdb +accepts the following command\-line arguments: +.PP +\fIdbname\fR +.RS 4 +Specifies the name of the database to be removed\&. +.RE +.PP +\fB\-e\fR, \fB\-\-echo\fR +.RS 4 +Echo the commands that +dropdb +generates and sends to the server\&. +.RE +.PP +\fB\-i\fR, \fB\-\-interactive\fR +.RS 4 +Issues a verification prompt before doing anything destructive\&. +.RE +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +dropdb +version and exit\&. +.RE +.PP +\fB\-\-if\-exists\fR +.RS 4 +Do not throw an error if the database does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +dropdb +command line arguments, and exit\&. +.RE +.PP + +dropdb +also accepts the following command\-line arguments for connection parameters: +.PP +\fB\-h \fR\fB\fIhost\fR\fR, \fB\-\-host=\fR\fB\fIhost\fR\fR +.RS 4 +Specifies the host name of the machine on which the server is running\&. If the value begins with a slash, it is used as the directory for the Unix domain socket\&. +.RE +.PP +\fB\-p \fR\fB\fIport\fR\fR, \fB\-\-port=\fR\fB\fIport\fR\fR +.RS 4 +Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections\&. +.RE +.PP +\fB\-U \fR\fB\fIusername\fR\fR, \fB\-\-username=\fR\fB\fIusername\fR\fR +.RS 4 +User name to connect as\&. +.RE +.PP +\fB\-w\fR, \fB\-\-no\-password\fR +.RS 4 +Never issue a password prompt\&. If the server requires password authentication and a password is not available by other means such as a +\&.pgpass +file, the connection attempt will fail\&. This option can be useful in batch jobs and scripts where no user is present to enter a password\&. +.RE +.PP +\fB\-W\fR, \fB\-\-password\fR +.RS 4 +Force +dropdb +to prompt for a password before connecting to a database\&. +.sp +This option is never essential, since +dropdb +will automatically prompt for a password if the server demands password authentication\&. However, +dropdb +will waste a connection attempt finding out that the server wants a password\&. In some cases it is worth typing +\fB\-W\fR +to avoid the extra connection attempt\&. +.RE +.PP +\fB\-\-maintenance\-db=\fR\fB\fIdbname\fR\fR +.RS 4 +Specifies the name of the database to connect to in order to drop the target database\&. If not specified, the +postgres +database will be used; if that does not exist (or is the database being dropped), +template1 +will be used\&. +.RE +.SH "ENVIRONMENT" +.PP +\fBPGHOST\fR, \fBPGPORT\fR, \fBPGUSER\fR +.RS 4 +Default connection parameters +.RE +.PP +This utility, like most other +PostgreSQL +utilities, also uses the environment variables supported by +libpq +(see +Section 31.14, \(lqEnvironment Variables\(rq, in the documentation)\&. +.SH "DIAGNOSTICS" +.PP +In case of difficulty, see +DROP DATABASE (\fBDROP_DATABASE\fR(7)) +and +\fBpsql\fR(1) +for discussions of potential problems and error messages\&. The database server must be running at the targeted host\&. Also, any default connection settings and environment variables used by the +libpq +front\-end library will apply\&. +.SH "EXAMPLES" +.PP +To destroy the database +demo +on the default database server: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBdropdb demo\fR +.fi +.if n \{\ +.RE +.\} +.PP +To destroy the database +demo +using the server on host +eden, port 5000, with verification and a peek at the underlying command: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBdropdb \-p 5000 \-h eden \-i \-e demo\fR +Database "demo" will be permanently deleted\&. +Are you sure? (y/n) \fBy\fR +DROP DATABASE demo; +.fi +.if n \{\ +.RE +.\} +.SH "SEE ALSO" +\fBcreatedb\fR(1), DROP DATABASE (\fBDROP_DATABASE\fR(7)) diff --git a/doc/src/sgml/man1/droplang.1 b/doc/src/sgml/man1/droplang.1 new file mode 100644 index 000000000..c7ef7b1a1 --- /dev/null +++ b/doc/src/sgml/man1/droplang.1 @@ -0,0 +1,197 @@ +'\" t +.\" Title: droplang +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROPLANG" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +droplang \- remove a PostgreSQL procedural language +.\" droplang +.SH "SYNOPSIS" +.HP \w'\fBdroplang\fR\ 'u +\fBdroplang\fR [\fIconnection\-option\fR...] \fIlangname\fR [\fIdbname\fR] +.HP \w'\fBdroplang\fR\ 'u +\fBdroplang\fR [\fIconnection\-option\fR...] \fB\-\-list\fR | \fB\-l\fR [\fIdbname\fR] +.SH "DESCRIPTION" +.PP + +droplang +is a utility for removing an existing procedural language from a +PostgreSQL +database\&. +.PP + +droplang +is just a wrapper around the +DROP EXTENSION (\fBDROP_EXTENSION\fR(7)) +SQL command\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBCaution\fR +.ps -1 +.br +.PP + +droplang +is deprecated and may be removed in a future +PostgreSQL +release\&. Direct use of the +\fBDROP EXTENSION\fR +command is recommended instead\&. +.sp .5v +.RE +.SH "OPTIONS" +.PP + +droplang +accepts the following command line arguments: +.PP +\fIlangname\fR +.RS 4 +Specifies the name of the procedural language to be removed\&. (This name is lower\-cased\&.) +.RE +.PP +\fB[\-d]\fR\fB \fR\fB\fIdbname\fR\fR, \fB[\-\-dbname=]\fR\fB\fIdbname\fR\fR +.RS 4 +Specifies from which database the language should be removed\&. The default is to use the database with the same name as the current system user\&. +.RE +.PP +\fB\-e\fR, \fB\-\-echo\fR +.RS 4 +Display SQL commands as they are executed\&. +.RE +.PP +\fB\-l\fR, \fB\-\-list\fR +.RS 4 +Show a list of already installed languages in the target database\&. +.RE +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +droplang +version and exit\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +droplang +command line arguments, and exit\&. +.RE +.PP + +droplang +also accepts the following command line arguments for connection parameters: +.PP +\fB\-h \fR\fB\fIhost\fR\fR, \fB\-\-host=\fR\fB\fIhost\fR\fR +.RS 4 +Specifies the host name of the machine on which the server is running\&. If host begins with a slash, it is used as the directory for the Unix domain socket\&. +.RE +.PP +\fB\-p \fR\fB\fIport\fR\fR, \fB\-\-port=\fR\fB\fIport\fR\fR +.RS 4 +Specifies the Internet TCP/IP port or local Unix domain socket file extension on which the server is listening for connections\&. +.RE +.PP +\fB\-U \fR\fB\fIusername\fR\fR, \fB\-\-username=\fR\fB\fIusername\fR\fR +.RS 4 +User name to connect as\&. +.RE +.PP +\fB\-w\fR, \fB\-\-no\-password\fR +.RS 4 +Never issue a password prompt\&. If the server requires password authentication and a password is not available by other means such as a +\&.pgpass +file, the connection attempt will fail\&. This option can be useful in batch jobs and scripts where no user is present to enter a password\&. +.RE +.PP +\fB\-W\fR, \fB\-\-password\fR +.RS 4 +Force +droplang +to prompt for a password before connecting to a database\&. +.sp +This option is never essential, since +droplang +will automatically prompt for a password if the server demands password authentication\&. However, +droplang +will waste a connection attempt finding out that the server wants a password\&. In some cases it is worth typing +\fB\-W\fR +to avoid the extra connection attempt\&. +.RE +.SH "ENVIRONMENT" +.PP +\fBPGDATABASE\fR, \fBPGHOST\fR, \fBPGPORT\fR, \fBPGUSER\fR +.RS 4 +Default connection parameters +.RE +.PP +This utility, like most other +PostgreSQL +utilities, also uses the environment variables supported by +libpq +(see +Section 31.14, \(lqEnvironment Variables\(rq, in the documentation)\&. +.SH "DIAGNOSTICS" +.PP +Most error messages are self\-explanatory\&. If not, run +droplang +with the +\fB\-\-echo\fR +option and see under the respective +SQL +command for details\&. Also, any default connection settings and environment variables used by the +libpq +front\-end library will apply\&. +.SH "NOTES" +.PP +Use +\fBcreatelang\fR(1) +to add a language\&. +.SH "EXAMPLES" +.PP +To remove the language +pltcl: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBdroplang pltcl dbname\fR +.fi +.if n \{\ +.RE +.\} +.SH "SEE ALSO" +\fBcreatelang\fR(1), DROP EXTENSION (\fBDROP_EXTENSION\fR(7)), DROP LANGUAGE (\fBDROP_LANGUAGE\fR(7)) diff --git a/doc/src/sgml/man1/dropuser.1 b/doc/src/sgml/man1/dropuser.1 new file mode 100644 index 000000000..f9b462f0a --- /dev/null +++ b/doc/src/sgml/man1/dropuser.1 @@ -0,0 +1,196 @@ +'\" t +.\" Title: dropuser +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROPUSER" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +dropuser \- remove a PostgreSQL user account +.\" dropuser +.SH "SYNOPSIS" +.HP \w'\fBdropuser\fR\ 'u +\fBdropuser\fR [\fIconnection\-option\fR...] [\fIoption\fR...] [\fIusername\fR] +.SH "DESCRIPTION" +.PP + +dropuser +removes an existing +PostgreSQL +user\&. Only superusers and users with the +CREATEROLE +privilege can remove +PostgreSQL +users\&. (To remove a superuser, you must yourself be a superuser\&.) +.PP + +dropuser +is a wrapper around the +SQL +command +DROP ROLE (\fBDROP_ROLE\fR(7))\&. There is no effective difference between dropping users via this utility and via other methods for accessing the server\&. +.SH "OPTIONS" +.PP + +dropuser +accepts the following command\-line arguments: +.PP +\fIusername\fR +.RS 4 +Specifies the name of the +PostgreSQL +user to be removed\&. You will be prompted for a name if none is specified on the command line and the +\fB\-i\fR/\fB\-\-interactive\fR +option is used\&. +.RE +.PP +\fB\-e\fR, \fB\-\-echo\fR +.RS 4 +Echo the commands that +dropuser +generates and sends to the server\&. +.RE +.PP +\fB\-i\fR, \fB\-\-interactive\fR +.RS 4 +Prompt for confirmation before actually removing the user, and prompt for the user name if none is specified on the command line\&. +.RE +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +dropuser +version and exit\&. +.RE +.PP +\fB\-\-if\-exists\fR +.RS 4 +Do not throw an error if the user does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +dropuser +command line arguments, and exit\&. +.RE +.PP + +dropuser +also accepts the following command\-line arguments for connection parameters: +.PP +\fB\-h \fR\fB\fIhost\fR\fR, \fB\-\-host=\fR\fB\fIhost\fR\fR +.RS 4 +Specifies the host name of the machine on which the server is running\&. If the value begins with a slash, it is used as the directory for the Unix domain socket\&. +.RE +.PP +\fB\-p \fR\fB\fIport\fR\fR, \fB\-\-port=\fR\fB\fIport\fR\fR +.RS 4 +Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections\&. +.RE +.PP +\fB\-U \fR\fB\fIusername\fR\fR, \fB\-\-username=\fR\fB\fIusername\fR\fR +.RS 4 +User name to connect as (not the user name to drop)\&. +.RE +.PP +\fB\-w\fR, \fB\-\-no\-password\fR +.RS 4 +Never issue a password prompt\&. If the server requires password authentication and a password is not available by other means such as a +\&.pgpass +file, the connection attempt will fail\&. This option can be useful in batch jobs and scripts where no user is present to enter a password\&. +.RE +.PP +\fB\-W\fR, \fB\-\-password\fR +.RS 4 +Force +dropuser +to prompt for a password before connecting to a database\&. +.sp +This option is never essential, since +dropuser +will automatically prompt for a password if the server demands password authentication\&. However, +dropuser +will waste a connection attempt finding out that the server wants a password\&. In some cases it is worth typing +\fB\-W\fR +to avoid the extra connection attempt\&. +.RE +.SH "ENVIRONMENT" +.PP +\fBPGHOST\fR, \fBPGPORT\fR, \fBPGUSER\fR +.RS 4 +Default connection parameters +.RE +.PP +This utility, like most other +PostgreSQL +utilities, also uses the environment variables supported by +libpq +(see +Section 31.14, \(lqEnvironment Variables\(rq, in the documentation)\&. +.SH "DIAGNOSTICS" +.PP +In case of difficulty, see +DROP ROLE (\fBDROP_ROLE\fR(7)) +and +\fBpsql\fR(1) +for discussions of potential problems and error messages\&. The database server must be running at the targeted host\&. Also, any default connection settings and environment variables used by the +libpq +front\-end library will apply\&. +.SH "EXAMPLES" +.PP +To remove user +joe +from the default database server: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBdropuser joe\fR +.fi +.if n \{\ +.RE +.\} +.PP +To remove user +joe +using the server on host +eden, port 5000, with verification and a peek at the underlying command: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBdropuser \-p 5000 \-h eden \-i \-e joe\fR +Role "joe" will be permanently removed\&. +Are you sure? (y/n) \fBy\fR +DROP ROLE joe; +.fi +.if n \{\ +.RE +.\} +.SH "SEE ALSO" +\fBcreateuser\fR(1), DROP ROLE (\fBDROP_ROLE\fR(7)) diff --git a/doc/src/sgml/man1/ecpg.1 b/doc/src/sgml/man1/ecpg.1 new file mode 100644 index 000000000..dfc17dfd0 --- /dev/null +++ b/doc/src/sgml/man1/ecpg.1 @@ -0,0 +1,191 @@ +'\" t +.\" Title: ecpg +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ECPG" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ecpg \- embedded SQL C preprocessor +.\" ecpg +.SH "SYNOPSIS" +.HP \w'\fBecpg\fR\ 'u +\fBecpg\fR [\fIoption\fR...] \fIfile\fR... +.SH "DESCRIPTION" +.PP + +\fBecpg\fR +is the embedded SQL preprocessor for C programs\&. It converts C programs with embedded SQL statements to normal C code by replacing the SQL invocations with special function calls\&. The output files can then be processed with any C compiler tool chain\&. +.PP + +\fBecpg\fR +will convert each input file given on the command line to the corresponding C output file\&. Input files preferably have the extension +\&.pgc, in which case the extension will be replaced by +\&.c +to determine the output file name\&. If the extension of the input file is not +\&.pgc, then the output file name is computed by appending +\&.c +to the full file name\&. The output file name can also be overridden using the +\fB\-o\fR +option\&. +.PP +This reference page does not describe the embedded SQL language\&. See +Chapter 33, ECPG - Embedded SQL in C, in the documentation +for more information on that topic\&. +.SH "OPTIONS" +.PP + +\fBecpg\fR +accepts the following command\-line arguments: +.PP +\fB\-c\fR +.RS 4 +Automatically generate certain C code from SQL code\&. Currently, this works for +EXEC SQL TYPE\&. +.RE +.PP +\fB\-C \fR\fB\fImode\fR\fR +.RS 4 +Set a compatibility mode\&. +\fImode\fR +can be +INFORMIX +or +INFORMIX_SE\&. +.RE +.PP +\fB\-D \fR\fB\fIsymbol\fR\fR +.RS 4 +Define a C preprocessor symbol\&. +.RE +.PP +\fB\-i\fR +.RS 4 +Parse system include files as well\&. +.RE +.PP +\fB\-I \fR\fB\fIdirectory\fR\fR +.RS 4 +Specify an additional include path, used to find files included via +EXEC SQL INCLUDE\&. Defaults are +\&. +(current directory), +/usr/local/include, the +PostgreSQL +include directory which is defined at compile time (default: +/usr/local/pgsql/include), and +/usr/include, in that order\&. +.RE +.PP +\fB\-o \fR\fB\fIfilename\fR\fR +.RS 4 +Specifies that +\fBecpg\fR +should write all its output to the given +\fIfilename\fR\&. +.RE +.PP +\fB\-r \fR\fB\fIoption\fR\fR +.RS 4 +Selects run\-time behavior\&. +\fIOption\fR +can be one of the following: +.PP +\fBno_indicator\fR +.RS 4 +Do not use indicators but instead use special values to represent null values\&. Historically there have been databases using this approach\&. +.RE +.PP +\fBprepare\fR +.RS 4 +Prepare all statements before using them\&. Libecpg will keep a cache of prepared statements and reuse a statement if it gets executed again\&. If the cache runs full, libecpg will free the least used statement\&. +.RE +.PP +\fBquestionmarks\fR +.RS 4 +Allow question mark as placeholder for compatibility reasons\&. This used to be the default long ago\&. +.RE +.RE +.PP +\fB\-t\fR +.RS 4 +Turn on autocommit of transactions\&. In this mode, each SQL command is automatically committed unless it is inside an explicit transaction block\&. In the default mode, commands are committed only when +\fBEXEC SQL COMMIT\fR +is issued\&. +.RE +.PP +\fB\-v\fR +.RS 4 +Print additional information including the version and the "include" path\&. +.RE +.PP +\fB\-\-version\fR +.RS 4 +Print the +ecpg +version and exit\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +ecpg +command line arguments, and exit\&. +.RE +.SH "NOTES" +.PP +When compiling the preprocessed C code files, the compiler needs to be able to find the +ECPG +header files in the +PostgreSQL +include directory\&. Therefore, you might have to use the +\fB\-I\fR +option when invoking the compiler (e\&.g\&., +\-I/usr/local/pgsql/include)\&. +.PP +Programs using C code with embedded SQL have to be linked against the +libecpg +library, for example using the linker options +\-L/usr/local/pgsql/lib \-lecpg\&. +.PP +The value of either of these directories that is appropriate for the installation can be found out using +\fBpg_config\fR(1)\&. +.SH "EXAMPLES" +.PP +If you have an embedded SQL C source file named +prog1\&.pgc, you can create an executable program using the following sequence of commands: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ecpg prog1\&.pgc +cc \-I/usr/local/pgsql/include \-c prog1\&.c +cc \-o prog1 prog1\&.o \-L/usr/local/pgsql/lib \-lecpg +.fi +.if n \{\ +.RE +.\} + diff --git a/doc/src/sgml/man1/initdb.1 b/doc/src/sgml/man1/initdb.1 new file mode 100644 index 000000000..8f18592c0 --- /dev/null +++ b/doc/src/sgml/man1/initdb.1 @@ -0,0 +1,265 @@ +'\" t +.\" Title: initdb +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "INITDB" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +initdb \- create a new PostgreSQL database cluster +.\" initdb +.SH "SYNOPSIS" +.HP \w'\fBinitdb\fR\ 'u +\fBinitdb\fR [\fIoption\fR...] [\fB\-\-pgdata\fR | \fB\-D\fR]\fI directory\fR +.SH "DESCRIPTION" +.PP + +\fBinitdb\fR +creates a new +PostgreSQL +database cluster\&. A database cluster is a collection of databases that are managed by a single server instance\&. +.PP +Creating a database cluster consists of creating the directories in which the database data will live, generating the shared catalog tables (tables that belong to the whole cluster rather than to any particular database), and creating the +template1 +and +postgres +databases\&. When you later create a new database, everything in the +template1 +database is copied\&. (Therefore, anything installed in +template1 +is automatically copied into each database created later\&.) The +postgres +database is a default database meant for use by users, utilities and third party applications\&. +.PP +Although +\fBinitdb\fR +will attempt to create the specified data directory, it might not have permission if the parent directory of the desired data directory is root\-owned\&. To initialize in such a setup, create an empty data directory as root, then use +\fBchown\fR +to assign ownership of that directory to the database user account, then +\fBsu\fR +to become the database user to run +\fBinitdb\fR\&. +.PP + +\fBinitdb\fR +must be run as the user that will own the server process, because the server needs to have access to the files and directories that +\fBinitdb\fR +creates\&. Since the server cannot be run as root, you must not run +\fBinitdb\fR +as root either\&. (It will in fact refuse to do so\&.) +.PP + +\fBinitdb\fR +initializes the database cluster\*(Aqs default locale and character set encoding\&. The character set encoding, collation order (LC_COLLATE) and character set classes (LC_CTYPE, e\&.g\&. upper, lower, digit) can be set separately for a database when it is created\&. +\fBinitdb\fR +determines those settings for the +template1 +database, which will serve as the default for all other databases\&. +.PP +To alter the default collation order or character set classes, use the +\fB\-\-lc\-collate\fR +and +\fB\-\-lc\-ctype\fR +options\&. Collation orders other than +C +or +POSIX +also have a performance penalty\&. For these reasons it is important to choose the right locale when running +\fBinitdb\fR\&. +.PP +The remaining locale categories can be changed later when the server is started\&. You can also use +\fB\-\-locale\fR +to set the default for all locale categories, including collation order and character set classes\&. All server locale values (lc_*) can be displayed via +\fBSHOW ALL\fR\&. More details can be found in +Section 22.1, \(lqLocale Support\(rq, in the documentation\&. +.PP +To alter the default encoding, use the +\fB\-\-encoding\fR\&. More details can be found in +Section 22.3, \(lqCharacter Set Support\(rq, in the documentation\&. +.SH "OPTIONS" +.PP +.PP +\fB\-A \fR\fB\fIauthmethod\fR\fR, \fB\-\-auth=\fR\fB\fIauthmethod\fR\fR +.RS 4 +This option specifies the authentication method for local users used in +pg_hba\&.conf +(host +and +local +lines)\&. Do not use +trust +unless you trust all local users on your system\&. +trust +is the default for ease of installation\&. +.RE +.PP +\fB\-\-auth\-host=\fR\fB\fIauthmethod\fR\fR +.RS 4 +This option specifies the authentication method for local users via TCP/IP connections used in +pg_hba\&.conf +(host +lines)\&. +.RE +.PP +\fB\-\-auth\-local=\fR\fB\fIauthmethod\fR\fR +.RS 4 +This option specifies the authentication method for local users via Unix\-domain socket connections used in +pg_hba\&.conf +(local +lines)\&. +.RE +.PP +\fB\-D \fR\fB\fIdirectory\fR\fR, \fB\-\-pgdata=\fR\fB\fIdirectory\fR\fR +.RS 4 +This option specifies the directory where the database cluster should be stored\&. This is the only information required by +\fBinitdb\fR, but you can avoid writing it by setting the +\fBPGDATA\fR +environment variable, which can be convenient since the database server (\fBpostgres\fR) can find the database directory later by the same variable\&. +.RE +.PP +\fB\-E \fR\fB\fIencoding\fR\fR, \fB\-\-encoding=\fR\fB\fIencoding\fR\fR +.RS 4 +Selects the encoding of the template database\&. This will also be the default encoding of any database you create later, unless you override it there\&. The default is derived from the locale, or +SQL_ASCII +if that does not work\&. The character sets supported by the +PostgreSQL +server are described in +Section 22.3.1, \(lqSupported Character Sets\(rq, in the documentation\&. +.RE +.PP +\fB\-\-locale=\fR\fB\fIlocale\fR\fR +.RS 4 +Sets the default locale for the database cluster\&. If this option is not specified, the locale is inherited from the environment that +\fBinitdb\fR +runs in\&. Locale support is described in +Section 22.1, \(lqLocale Support\(rq, in the documentation\&. +.RE +.PP +\fB\-\-lc\-collate=\fR\fB\fIlocale\fR\fR, \fB\-\-lc\-ctype=\fR\fB\fIlocale\fR\fR, \fB\-\-lc\-messages=\fR\fB\fIlocale\fR\fR, \fB\-\-lc\-monetary=\fR\fB\fIlocale\fR\fR, \fB\-\-lc\-numeric=\fR\fB\fIlocale\fR\fR, \fB\-\-lc\-time=\fR\fB\fIlocale\fR\fR +.RS 4 +Like +\fB\-\-locale\fR, but only sets the locale in the specified category\&. +.RE +.PP +\fB\-\-no\-locale\fR +.RS 4 +Equivalent to +\fB\-\-locale=C\fR\&. +.RE +.PP +\fB\-\-pwfile=\fR\fB\fIfilename\fR\fR +.RS 4 +Makes +\fBinitdb\fR +read the database superuser\*(Aqs password from a file\&. The first line of the file is taken as the password\&. +.RE +.PP +\fB\-T \fR\fB\fICFG\fR\fR, \fB\-\-text\-search\-config=\fR\fB\fICFG\fR\fR +.RS 4 +Sets the default text search configuration\&. See +default_text_search_config +for further information\&. +.RE +.PP +\fB\-U \fR\fB\fIusername\fR\fR, \fB\-\-username=\fR\fB\fIusername\fR\fR +.RS 4 +Selects the user name of the database superuser\&. This defaults to the name of the effective user running +\fBinitdb\fR\&. It is really not important what the superuser\*(Aqs name is, but one might choose to keep the customary name +postgres, even if the operating system user\*(Aqs name is different\&. +.RE +.PP +\fB\-W\fR, \fB\-\-pwprompt\fR +.RS 4 +Makes +\fBinitdb\fR +prompt for a password to give the database superuser\&. If you don\*(Aqt plan on using password authentication, this is not important\&. Otherwise you won\*(Aqt be able to use password authentication until you have a password set up\&. +.RE +.PP +\fB\-X \fR\fB\fIdirectory\fR\fR, \fB\-\-xlogdir=\fR\fB\fIdirectory\fR\fR +.RS 4 +This option specifies the directory where the transaction log should be stored\&. +.RE +.PP +Other, less commonly used, options are also available: +.PP +\fB\-d\fR, \fB\-\-debug\fR +.RS 4 +Print debugging output from the bootstrap backend and a few other messages of lesser interest for the general public\&. The bootstrap backend is the program +\fBinitdb\fR +uses to create the catalog tables\&. This option generates a tremendous amount of extremely boring output\&. +.RE +.PP +\fB\-L \fR\fB\fIdirectory\fR\fR +.RS 4 +Specifies where +\fBinitdb\fR +should find its input files to initialize the database cluster\&. This is normally not necessary\&. You will be told if you need to specify their location explicitly\&. +.RE +.PP +\fB\-n\fR, \fB\-\-noclean\fR +.RS 4 +By default, when +\fBinitdb\fR +determines that an error prevented it from completely creating the database cluster, it removes any files it might have created before discovering that it cannot finish the job\&. This option inhibits tidying\-up and is thus useful for debugging\&. +.RE +.PP +Other options: +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +initdb +version and exit\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +initdb +command line arguments, and exit\&. +.RE +.SH "ENVIRONMENT" +.PP +\fBPGDATA\fR +.RS 4 +Specifies the directory where the database cluster is to be stored; can be overridden using the +\fB\-D\fR +option\&. +.RE +.PP +This utility, like most other +PostgreSQL +utilities, also uses the environment variables supported by +libpq +(see +Section 31.14, \(lqEnvironment Variables\(rq, in the documentation)\&. +.SH "NOTES" +.PP + +\fBinitdb\fR +can also be invoked via +\fBpg_ctl initdb\fR\&. +.SH "SEE ALSO" +\fBpg_ctl\fR(1), \fBpostgres\fR(1) diff --git a/doc/src/sgml/man1/oid2name.1 b/doc/src/sgml/man1/oid2name.1 new file mode 100644 index 000000000..c783270b8 --- /dev/null +++ b/doc/src/sgml/man1/oid2name.1 @@ -0,0 +1,328 @@ +'\" t +.\" Title: oid2name +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "OID2NAME" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +oid2name \- resolve OIDs and file nodes in a PostgreSQL data directory +.\" oid2name +.SH "SYNOPSIS" +.HP \w'\fBoid2name\fR\ 'u +\fBoid2name\fR [\fIoption\fR...] +.SH "DESCRIPTION" +.PP + +oid2name +is a utility program that helps administrators to examine the file structure used by PostgreSQL\&. To make use of it, you need to be familiar with the database file structure, which is described in +Chapter 56, Database Physical Storage, in the documentation\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +.PP +The name +\(lqoid2name\(rq +is historical, and is actually rather misleading, since most of the time when you use it, you will really be concerned with tables\*(Aq filenode numbers (which are the file names visible in the database directories)\&. Be sure you understand the difference between table OIDs and table filenodes! +.sp .5v +.RE +.PP + +oid2name +connects to a target database and extracts OID, filenode, and/or table name information\&. You can also have it show database OIDs or tablespace OIDs\&. +.SH "OPTIONS" +.PP + +oid2name +accepts the following command\-line arguments: +.PP +\fB\-f\fR \fIfilenode\fR +.RS 4 +show info for table with filenode +\fIfilenode\fR +.RE +.PP +\fB\-i\fR +.RS 4 +include indexes and sequences in the listing +.RE +.PP +\fB\-o\fR \fIoid\fR +.RS 4 +show info for table with OID +\fIoid\fR +.RE +.PP +\fB\-q\fR +.RS 4 +omit headers (useful for scripting) +.RE +.PP +\fB\-s\fR +.RS 4 +show tablespace OIDs +.RE +.PP +\fB\-S\fR +.RS 4 +include system objects (those in +\fBinformation_schema\fR, +\fBpg_toast\fR +and +\fBpg_catalog\fR +schemas) +.RE +.PP +\fB\-t\fR \fItablename_pattern\fR +.RS 4 +show info for table(s) matching +\fItablename_pattern\fR +.RE +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +oid2name +version and exit\&. +.RE +.PP +\fB\-x\fR +.RS 4 +display more information about each object shown: tablespace name, schema name, and OID +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +oid2name +command line arguments, and exit\&. +.RE +.PP + +oid2name +also accepts the following command\-line arguments for connection parameters: +.PP +\fB\-d\fR \fIdatabase\fR +.RS 4 +database to connect to +.RE +.PP +\fB\-H\fR \fIhost\fR +.RS 4 +database server\*(Aqs host +.RE +.PP +\fB\-p\fR \fIport\fR +.RS 4 +database server\*(Aqs port +.RE +.PP +\fB\-U\fR \fIusername\fR +.RS 4 +user name to connect as +.RE +.PP +\fB\-P\fR \fIpassword\fR +.RS 4 +password (deprecated \(em putting this on the command line is a security hazard) +.RE +.PP +To display specific tables, select which tables to show by using +\fB\-o\fR, +\fB\-f\fR +and/or +\fB\-t\fR\&. +\fB\-o\fR +takes an OID, +\fB\-f\fR +takes a filenode, and +\fB\-t\fR +takes a table name (actually, it\*(Aqs a +LIKE +pattern, so you can use things like +foo%)\&. You can use as many of these options as you like, and the listing will include all objects matched by any of the options\&. But note that these options can only show objects in the database given by +\fB\-d\fR\&. +.PP +If you don\*(Aqt give any of +\fB\-o\fR, +\fB\-f\fR +or +\fB\-t\fR, but do give +\fB\-d\fR, it will list all tables in the database named by +\fB\-d\fR\&. In this mode, the +\fB\-S\fR +and +\fB\-i\fR +options control what gets listed\&. +.PP +If you don\*(Aqt give +\fB\-d\fR +either, it will show a listing of database OIDs\&. Alternatively you can give +\fB\-s\fR +to get a tablespace listing\&. +.SH "NOTES" +.PP + +oid2name +requires a running database server with non\-corrupt system catalogs\&. It is therefore of only limited use for recovering from catastrophic database corruption situations\&. +.SH "EXAMPLES" +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ # what\*(Aqs in this database server, anyway? +$ oid2name +All databases: + Oid Database Name Tablespace +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + 17228 alvherre pg_default + 17255 regression pg_default + 17227 template0 pg_default + 1 template1 pg_default + +$ oid2name \-s +All tablespaces: + Oid Tablespace Name +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + 1663 pg_default + 1664 pg_global + 155151 fastdisk + 155152 bigdisk + +$ # OK, let\*(Aqs look into database alvherre +$ cd $PGDATA/base/17228 + +$ # get top 10 db objects in the default tablespace, ordered by size +$ ls \-lS * | head \-10 +\-rw\-\-\-\-\-\-\- 1 alvherre alvherre 136536064 sep 14 09:51 155173 +\-rw\-\-\-\-\-\-\- 1 alvherre alvherre 17965056 sep 14 09:51 1155291 +\-rw\-\-\-\-\-\-\- 1 alvherre alvherre 1204224 sep 14 09:51 16717 +\-rw\-\-\-\-\-\-\- 1 alvherre alvherre 581632 sep 6 17:51 1255 +\-rw\-\-\-\-\-\-\- 1 alvherre alvherre 237568 sep 14 09:50 16674 +\-rw\-\-\-\-\-\-\- 1 alvherre alvherre 212992 sep 14 09:51 1249 +\-rw\-\-\-\-\-\-\- 1 alvherre alvherre 204800 sep 14 09:51 16684 +\-rw\-\-\-\-\-\-\- 1 alvherre alvherre 196608 sep 14 09:50 16700 +\-rw\-\-\-\-\-\-\- 1 alvherre alvherre 163840 sep 14 09:50 16699 +\-rw\-\-\-\-\-\-\- 1 alvherre alvherre 122880 sep 6 17:51 16751 + +$ # I wonder what file 155173 is \&.\&.\&. +$ oid2name \-d alvherre \-f 155173 +From database "alvherre": + Filenode Table Name +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + 155173 accounts + +$ # you can ask for more than one object +$ oid2name \-d alvherre \-f 155173 \-f 1155291 +From database "alvherre": + Filenode Table Name +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + 155173 accounts + 1155291 accounts_pkey + +$ # you can mix the options, and get more details with \-x +$ oid2name \-d alvherre \-t accounts \-f 1155291 \-x +From database "alvherre": + Filenode Table Name Oid Schema Tablespace +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + 155173 accounts 155173 public pg_default + 1155291 accounts_pkey 1155291 public pg_default + +$ # show disk space for every db object +$ du [0\-9]* | +> while read SIZE FILENODE +> do +> echo "$SIZE `oid2name \-q \-d alvherre \-i \-f $FILENODE`" +> done +16 1155287 branches_pkey +16 1155289 tellers_pkey +17561 1155291 accounts_pkey +\&.\&.\&. + +$ # same, but sort by size +$ du [0\-9]* | sort \-rn | while read SIZE FN +> do +> echo "$SIZE `oid2name \-q \-d alvherre \-f $FN`" +> done +133466 155173 accounts +17561 1155291 accounts_pkey +1177 16717 pg_proc_proname_args_nsp_index +\&.\&.\&. + +$ # If you want to see what\*(Aqs in tablespaces, use the pg_tblspc directory +$ cd $PGDATA/pg_tblspc +$ oid2name \-s +All tablespaces: + Oid Tablespace Name +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + 1663 pg_default + 1664 pg_global + 155151 fastdisk + 155152 bigdisk + +$ # what databases have objects in tablespace "fastdisk"? +$ ls \-d 155151/* +155151/17228/ 155151/PG_VERSION + +$ # Oh, what was database 17228 again? +$ oid2name +All databases: + Oid Database Name Tablespace +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + 17228 alvherre pg_default + 17255 regression pg_default + 17227 template0 pg_default + 1 template1 pg_default + +$ # Let\*(Aqs see what objects does this database have in the tablespace\&. +$ cd 155151/17228 +$ ls \-l +total 0 +\-rw\-\-\-\-\-\-\- 1 postgres postgres 0 sep 13 23:20 155156 + +$ # OK, this is a pretty small table \&.\&.\&. but which one is it? +$ oid2name \-d alvherre \-f 155156 +From database "alvherre": + Filenode Table Name +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + 155156 foo +.fi +.if n \{\ +.RE +.\} +.SH "AUTHOR" +.PP +B\&. Palmer + diff --git a/doc/src/sgml/man1/pg_archivecleanup.1 b/doc/src/sgml/man1/pg_archivecleanup.1 new file mode 100644 index 000000000..3264c369f --- /dev/null +++ b/doc/src/sgml/man1/pg_archivecleanup.1 @@ -0,0 +1,206 @@ +'\" t +.\" Title: pg_archivecleanup +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "PG_ARCHIVECLEANUP" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +pg_archivecleanup \- clean up PostgreSQL WAL archive files +.\" pg_archivecleanup +.SH "SYNOPSIS" +.HP \w'\fBpg_archivecleanup\fR\ 'u +\fBpg_archivecleanup\fR [\fIoption\fR...] \fIarchivelocation\fR \fIoldestkeptwalfile\fR +.SH "DESCRIPTION" +.PP + +pg_archivecleanup +is designed to be used as an +archive_cleanup_command +to clean up WAL file archives when running as a standby server (see +Section 25.2, \(lqLog-Shipping Standby Servers\(rq, in the documentation)\&. +pg_archivecleanup +can also be used as a standalone program to clean WAL file archives\&. +.PP +To configure a standby server to use +pg_archivecleanup, put this into its +recovery\&.conf +configuration file: +.sp +.if n \{\ +.RS 4 +.\} +.nf +archive_cleanup_command = \*(Aqpg_archivecleanup \fIarchivelocation\fR %r\*(Aq +.fi +.if n \{\ +.RE +.\} +.sp +where +\fIarchivelocation\fR +is the directory from which WAL segment files should be removed\&. +.PP +When used within +archive_cleanup_command, all WAL files logically preceding the value of the +%r +argument will be removed from +\fIarchivelocation\fR\&. This minimizes the number of files that need to be retained, while preserving crash\-restart capability\&. Use of this parameter is appropriate if the +\fIarchivelocation\fR +is a transient staging area for this particular standby server, but +\fInot\fR +when the +\fIarchivelocation\fR +is intended as a long\-term WAL archive area, or when multiple standby servers are recovering from the same archive location\&. +.PP +When used as a standalone program all WAL files logically preceding the +\fIoldestkeptwalfile\fR +will be removed from +\fIarchivelocation\fR\&. In this mode, if you specify a +\&.backup +file name, then only the file prefix will be used as the +\fIoldestkeptwalfile\fR\&. This allows you to remove all WAL files archived prior to a specific base backup without error\&. For example, the following example will remove all files older than WAL file name +000000010000003700000010: +.sp +.if n \{\ +.RS 4 +.\} +.nf +pg_archivecleanup \-d archive 000000010000003700000010\&.00000020\&.backup + +pg_archivecleanup: keep WAL file "archive/000000010000003700000010" and later +pg_archivecleanup: removing file "archive/00000001000000370000000F" +pg_archivecleanup: removing file "archive/00000001000000370000000E" +.fi +.if n \{\ +.RE +.\} +.PP + +pg_archivecleanup +assumes that +\fIarchivelocation\fR +is a directory readable and writable by the server\-owning user\&. +.SH "OPTIONS" +.PP + +pg_archivecleanup +accepts the following command\-line arguments: +.PP +\fB\-d\fR +.RS 4 +Print lots of debug logging output on +stderr\&. +.RE +.PP +\fB\-n\fR +.RS 4 +Print the names of the files that would have been removed on +stdout +(performs a dry run)\&. +.RE +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +pg_archivecleanup +version and exit\&. +.RE +.PP +\fB\-x\fR \fIextension\fR +.RS 4 +When using the program as a standalone utility, provide an extension that will be stripped from all file names before deciding if they should be deleted\&. This is typically useful for cleaning up archives that have been compressed during storage, and therefore have had an extension added by the compression program\&. For example: +\-x \&.gz\&. +.sp +Note that the +\&.backup +file name passed to the program should not include the extension\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +pg_archivecleanup +command line arguments, and exit\&. +.RE +.SH "NOTES" +.PP + +pg_archivecleanup +is designed to work with +PostgreSQL +8\&.0 and later when used as a standalone utility, or with +PostgreSQL +9\&.0 and later when used as an archive cleanup command\&. +.PP + +pg_archivecleanup +is written in C and has an easy\-to\-modify source code, with specifically designated sections to modify for your own needs +.SH "EXAMPLES" +.PP +On Linux or Unix systems, you might use: +.sp +.if n \{\ +.RS 4 +.\} +.nf +archive_cleanup_command = \*(Aqpg_archivecleanup \-d /mnt/standby/archive %r 2>>cleanup\&.log\*(Aq +.fi +.if n \{\ +.RE +.\} +.sp +where the archive directory is physically located on the standby server, so that the +\fIarchive_command\fR +is accessing it across NFS, but the files are local to the standby\&. This will: +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +produce debugging output in +cleanup\&.log +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +remove no\-longer\-needed files from the archive directory +.RE +.SH "AUTHOR" +.PP +Simon Riggs + +.SH "SEE ALSO" +\fBpg_standby\fR(1) diff --git a/doc/src/sgml/man1/pg_basebackup.1 b/doc/src/sgml/man1/pg_basebackup.1 new file mode 100644 index 000000000..b13e970a0 --- /dev/null +++ b/doc/src/sgml/man1/pg_basebackup.1 @@ -0,0 +1,364 @@ +'\" t +.\" Title: pg_basebackup +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "PG_BASEBACKUP" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +pg_basebackup \- take a base backup of a PostgreSQL cluster +.\" pg_basebackup +.SH "SYNOPSIS" +.HP \w'\fBpg_basebackup\fR\ 'u +\fBpg_basebackup\fR [\fIoption\fR...] +.SH "DESCRIPTION" +.PP + +pg_basebackup +is used to take base backups of a running +PostgreSQL +database cluster\&. These are taken without affecting other clients to the database, and can be used both for point\-in\-time recovery (see +Section 24.3, \(lqContinuous Archiving and Point-in-Time Recovery (PITR)\(rq, in the documentation) and as the starting point for a log shipping or streaming replication standby servers (see +Section 25.2, \(lqLog-Shipping Standby Servers\(rq, in the documentation)\&. +.PP + +pg_basebackup +makes a binary copy of the database cluster files, while making sure the system is automatically put in and out of backup mode automatically\&. Backups are always taken of the entire database cluster, it is not possible to back up individual databases or database objects\&. For individual database backups, a tool such as +\fBpg_dump\fR(1) +must be used\&. +.PP +The backup is made over a regular +PostgreSQL +connection, and uses the replication protocol\&. The connection must be made with a superuser or a user having +REPLICATION +permissions (see +Section 20.2, \(lqRole Attributes\(rq, in the documentation), and +pg_hba\&.conf +must explicitly permit the replication connection\&. The server must also be configured with +max_wal_senders +set high enough to leave at least one session available for the backup\&. +.PP +There can be multiple +\fBpg_basebackup\fRs running at the same time, but it is better from a performance point of view to take only one backup, and copy the result\&. +.PP + +pg_basebackup +can make a base backup from not only the master but also the standby\&. To take a backup from the standby, set up the standby so that it can accept replication connections (that is, set +\fImax_wal_senders\fR +and +hot_standby, and configure +host\-based authentication)\&. You will also need to enable +full_page_writes +on the master\&. +.PP +Note that there are some limitations in an online backup from the standby: +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +The backup history file is not created in the database cluster backed up\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +There is no guarantee that all WAL files required for the backup are archived at the end of backup\&. If you are planning to use the backup for an archive recovery and want to ensure that all required files are available at that moment, you need to include them into the backup by using +\-x +option\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +If the standby is promoted to the master during online backup, the backup fails\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +All WAL records required for the backup must contain sufficient full\-page writes, which requires you to enable +\fIfull_page_writes\fR +on the master and not to use the tool like +pg_compresslog +as +\fIarchive_command\fR +to remove full\-page writes from WAL files\&. +.RE +.sp +.SH "OPTIONS" +.PP +The following command\-line options control the location and format of the output\&. +.PP +\fB\-D \fR\fB\fIdirectory\fR\fR, \fB\-\-pgdata=\fR\fB\fIdirectory\fR\fR +.RS 4 +Directory to write the output to\&. +pg_basebackup +will create the directory and any parent directories if necessary\&. The directory may already exist, but it is an error if the directory already exists and is not empty\&. +.sp +When the backup is in tar mode, and the directory is specified as +\- +(dash), the tar file will be written to +stdout\&. +.sp +This option is required\&. +.RE +.PP +\fB\-F \fR\fB\fIformat\fR\fR, \fB\-\-format=\fR\fB\fIformat\fR\fR +.RS 4 +Selects the format for the output\&. +\fIformat\fR +can be one of the following: +.PP +p, plain +.RS 4 +Write the output as plain files, with the same layout as the current data directory and tablespaces\&. When the cluster has no additional tablespaces, the whole database will be placed in the target directory\&. If the cluster contains additional tablespaces, the main data directory will be placed in the target directory, but all other tablespaces will be placed in the same absolute path as they have on the server\&. +.sp +This is the default format\&. +.RE +.PP +t, tar +.RS 4 +Write the output as tar files in the target directory\&. The main data directory will be written to a file named +base\&.tar, and all other tablespaces will be named after the tablespace OID\&. +.sp +If the value +\- +(dash) is specified as target directory, the tar contents will be written to standard output, suitable for piping to for example +gzip\&. This is only possible if the cluster has no additional tablespaces\&. +.RE +.RE +.PP +\fB\-x\fR, \fB\-\-xlog\fR +.RS 4 +Using this option is equivalent of using +\-X +with method +fetch\&. +.RE +.PP +\fB\-X \fR\fB\fImethod\fR\fR, \fB\-\-xlog\-method=\fR\fB\fImethod\fR\fR +.RS 4 +Includes the required transaction log files (WAL files) in the backup\&. This will include all transaction logs generated during the backup\&. If this option is specified, it is possible to start a postmaster directly in the extracted directory without the need to consult the log archive, thus making this a completely standalone backup\&. +.sp +The following methods for collecting the transaction logs are supported: +.PP +f, fetch +.RS 4 +The transaction log files are collected at the end of the backup\&. Therefore, it is necessary for the +wal_keep_segments +parameter to be set high enough that the log is not removed before the end of the backup\&. If the log has been rotated when it\*(Aqs time to transfer it, the backup will fail and be unusable\&. +.RE +.PP +s, stream +.RS 4 +Stream the transaction log while the backup is created\&. This will open a second connection to the server and start streaming the transaction log in parallel while running the backup\&. Therefore, it will use up two slots configured by the +max_wal_senders +parameter\&. As long as the client can keep up with transaction log received, using this mode requires no extra transaction logs to be saved on the master\&. +.RE +.sp +.RE +.PP +\fB\-z\fR, \fB\-\-gzip\fR +.RS 4 +Enables gzip compression of tar file output, with the default compression level\&. Compression is only available when using the tar format\&. +.RE +.PP +\fB\-Z \fR\fB\fIlevel\fR\fR, \fB\-\-compress=\fR\fB\fIlevel\fR\fR +.RS 4 +Enables gzip compression of tar file output, and specifies the compression level (1 through 9, 9 being best compression)\&. Compression is only available when using the tar format\&. +.RE +.PP +The following command\-line options control the generation of the backup and the running of the program\&. +.PP +\fB\-c \fR\fB\fIfast|spread\fR\fR, \fB\-\-checkpoint=\fR\fB\fIfast|spread\fR\fR +.RS 4 +Sets checkpoint mode to fast or spread (default)\&. +.RE +.PP +\fB\-l \fR\fB\fIlabel\fR\fR, \fB\-\-label=\fR\fB\fIlabel\fR\fR +.RS 4 +Sets the label for the backup\&. If none is specified, a default value of +\(lqpg_basebackup base backup\(rq +will be used\&. +.RE +.PP +\fB\-P\fR, \fB\-\-progress\fR +.RS 4 +Enables progress reporting\&. Turning this on will deliver an approximate progress report during the backup\&. Since the database may change during the backup, this is only an approximation and may not end at exactly +100%\&. In particular, when WAL log is included in the backup, the total amount of data cannot be estimated in advance, and in this case the estimated target size will increase once it passes the total estimate without WAL\&. +.sp +When this is enabled, the backup will start by enumerating the size of the entire database, and then go back and send the actual contents\&. This may make the backup take slightly longer, and in particular it will take longer before the first data is sent\&. +.RE +.PP +\fB\-v\fR, \fB\-\-verbose\fR +.RS 4 +Enables verbose mode\&. Will output some extra steps during startup and shutdown, as well as show the exact file name that is currently being processed if progress reporting is also enabled\&. +.RE +.PP +The following command\-line options control the database connection parameters\&. +.PP +\fB\-h \fR\fB\fIhost\fR\fR, \fB\-\-host=\fR\fB\fIhost\fR\fR +.RS 4 +Specifies the host name of the machine on which the server is running\&. If the value begins with a slash, it is used as the directory for the Unix domain socket\&. The default is taken from the +\fBPGHOST\fR +environment variable, if set, else a Unix domain socket connection is attempted\&. +.RE +.PP +\fB\-p \fR\fB\fIport\fR\fR, \fB\-\-port=\fR\fB\fIport\fR\fR +.RS 4 +Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections\&. Defaults to the +\fBPGPORT\fR +environment variable, if set, or a compiled\-in default\&. +.RE +.PP +\fB\-s \fR\fB\fIinterval\fR\fR, \fB\-\-status\-interval=\fR\fB\fIinterval\fR\fR +.RS 4 +Specifies the number of seconds between status packets sent back to the server\&. This is required when streaming the transaction log (using +\-\-xlog=stream) if replication timeout is configured on the server, and allows for easier monitoring\&. A value of zero disables the status updates completely\&. The default value is 10 seconds\&. +.RE +.PP +\fB\-U \fR\fB\fIusername\fR\fR, \fB\-\-username=\fR\fB\fIusername\fR\fR +.RS 4 +User name to connect as\&. +.RE +.PP +\fB\-w\fR, \fB\-\-no\-password\fR +.RS 4 +Never issue a password prompt\&. If the server requires password authentication and a password is not available by other means such as a +\&.pgpass +file, the connection attempt will fail\&. This option can be useful in batch jobs and scripts where no user is present to enter a password\&. +.RE +.PP +\fB\-W\fR, \fB\-\-password\fR +.RS 4 +Force +pg_basebackup +to prompt for a password before connecting to a database\&. +.sp +This option is never essential, since +pg_basebackup +will automatically prompt for a password if the server demands password authentication\&. However, +pg_basebackup +will waste a connection attempt finding out that the server wants a password\&. In some cases it is worth typing +\fB\-W\fR +to avoid the extra connection attempt\&. +.RE +.PP +Other options are also available: +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +pg_basebackup +version and exit\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +pg_basebackup +command line arguments, and exit\&. +.RE +.SH "ENVIRONMENT" +.PP +This utility, like most other +PostgreSQL +utilities, uses the environment variables supported by +libpq +(see +Section 31.14, \(lqEnvironment Variables\(rq, in the documentation)\&. +.SH "NOTES" +.PP +The backup will include all files in the data directory and tablespaces, including the configuration files and any additional files placed in the directory by third parties\&. Only regular files and directories are allowed in the data directory, no symbolic links or special device files\&. +.PP +The way +PostgreSQL +manages tablespaces, the path for all additional tablespaces must be identical whenever a backup is restored\&. The main data directory, however, is relocatable to any location\&. +.SH "EXAMPLES" +.PP +To create a base backup of the server at +mydbserver +and store it in the local directory +/usr/local/pgsql/data: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_basebackup \-h mydbserver \-D /usr/local/pgsql/data\fR +.fi +.if n \{\ +.RE +.\} +.PP +To create a backup of the local server with one compressed tar file for each tablespace, and store it in the directory +backup, showing a progress report while running: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_basebackup \-D backup \-Ft \-z \-P\fR +.fi +.if n \{\ +.RE +.\} +.PP +To create a backup of a single\-tablespace local database and compress this with +bzip2: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_basebackup \-D \- \-Ft | bzip2 > backup\&.tar\&.bz2\fR +.fi +.if n \{\ +.RE +.\} +.sp +(This command will fail if there are multiple tablespaces in the database\&.) +.SH "SEE ALSO" +\fBpg_dump\fR(1) diff --git a/doc/src/sgml/man1/pg_config.1 b/doc/src/sgml/man1/pg_config.1 new file mode 100644 index 000000000..c56efb799 --- /dev/null +++ b/doc/src/sgml/man1/pg_config.1 @@ -0,0 +1,269 @@ +'\" t +.\" Title: pg_config +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "PG_CONFIG" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +pg_config \- retrieve information about the installed version of PostgreSQL +.\" pg_config +.SH "SYNOPSIS" +.HP \w'\fBpg_config\fR\ 'u +\fBpg_config\fR [\fIoption\fR...] +.SH "DESCRIPTION" +.PP +The +pg_config +utility prints configuration parameters of the currently installed version of +PostgreSQL\&. It is intended, for example, to be used by software packages that want to interface to +PostgreSQL +to facilitate finding the required header files and libraries\&. +.SH "OPTIONS" +.PP +To use +pg_config, supply one or more of the following options: +.PP +\fB\-\-bindir\fR +.RS 4 +Print the location of user executables\&. Use this, for example, to find the +\fBpsql\fR +program\&. This is normally also the location where the +pg_config +program resides\&. +.RE +.PP +\fB\-\-docdir\fR +.RS 4 +Print the location of documentation files\&. +.RE +.PP +\fB\-\-htmldir\fR +.RS 4 +Print the location of HTML documentation files\&. +.RE +.PP +\fB\-\-includedir\fR +.RS 4 +Print the location of C header files of the client interfaces\&. +.RE +.PP +\fB\-\-pkgincludedir\fR +.RS 4 +Print the location of other C header files\&. +.RE +.PP +\fB\-\-includedir\-server\fR +.RS 4 +Print the location of C header files for server programming\&. +.RE +.PP +\fB\-\-libdir\fR +.RS 4 +Print the location of object code libraries\&. +.RE +.PP +\fB\-\-pkglibdir\fR +.RS 4 +Print the location of dynamically loadable modules, or where the server would search for them\&. (Other architecture\-dependent data files might also be installed in this directory\&.) +.RE +.PP +\fB\-\-localedir\fR +.RS 4 +Print the location of locale support files\&. (This will be an empty string if locale support was not configured when +PostgreSQL +was built\&.) +.RE +.PP +\fB\-\-mandir\fR +.RS 4 +Print the location of manual pages\&. +.RE +.PP +\fB\-\-sharedir\fR +.RS 4 +Print the location of architecture\-independent support files\&. +.RE +.PP +\fB\-\-sysconfdir\fR +.RS 4 +Print the location of system\-wide configuration files\&. +.RE +.PP +\fB\-\-pgxs\fR +.RS 4 +Print the location of extension makefiles\&. +.RE +.PP +\fB\-\-configure\fR +.RS 4 +Print the options that were given to the +configure +script when +PostgreSQL +was configured for building\&. This can be used to reproduce the identical configuration, or to find out with what options a binary package was built\&. (Note however that binary packages often contain vendor\-specific custom patches\&.) See also the examples below\&. +.RE +.PP +\fB\-\-cc\fR +.RS 4 +Print the value of the +\fICC\fR +variable that was used for building +PostgreSQL\&. This shows the C compiler used\&. +.RE +.PP +\fB\-\-cppflags\fR +.RS 4 +Print the value of the +\fICPPFLAGS\fR +variable that was used for building +PostgreSQL\&. This shows C compiler switches needed at preprocessing time (typically, +\-I +switches)\&. +.RE +.PP +\fB\-\-cflags\fR +.RS 4 +Print the value of the +\fICFLAGS\fR +variable that was used for building +PostgreSQL\&. This shows C compiler switches\&. +.RE +.PP +\fB\-\-cflags_sl\fR +.RS 4 +Print the value of the +\fICFLAGS_SL\fR +variable that was used for building +PostgreSQL\&. This shows extra C compiler switches used for building shared libraries\&. +.RE +.PP +\fB\-\-ldflags\fR +.RS 4 +Print the value of the +\fILDFLAGS\fR +variable that was used for building +PostgreSQL\&. This shows linker switches\&. +.RE +.PP +\fB\-\-ldflags_ex\fR +.RS 4 +Print the value of the +\fILDFLAGS_EX\fR +variable that was used for building +PostgreSQL\&. This shows linker switches used for building executables only\&. +.RE +.PP +\fB\-\-ldflags_sl\fR +.RS 4 +Print the value of the +\fILDFLAGS_SL\fR +variable that was used for building +PostgreSQL\&. This shows linker switches used for building shared libraries only\&. +.RE +.PP +\fB\-\-libs\fR +.RS 4 +Print the value of the +\fILIBS\fR +variable that was used for building +PostgreSQL\&. This normally contains +\-l +switches for external libraries linked into +PostgreSQL\&. +.RE +.PP +\fB\-\-version\fR +.RS 4 +Print the version of +PostgreSQL\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +pg_config +command line arguments, and exit\&. +.RE +If more than one option is given, the information is printed in that order, one item per line\&. If no options are given, all available information is printed, with labels\&. +.SH "NOTES" +.PP +The option +\fB\-\-includedir\-server\fR +was added in +PostgreSQL +7\&.2\&. In prior releases, the server include files were installed in the same location as the client headers, which could be queried with the option +\fB\-\-includedir\fR\&. To make your package handle both cases, try the newer option first and test the exit status to see whether it succeeded\&. +.PP +The options +\fB\-\-docdir\fR, +\fB\-\-pkgincludedir\fR, +\fB\-\-localedir\fR, +\fB\-\-mandir\fR, +\fB\-\-sharedir\fR, +\fB\-\-sysconfdir\fR, +\fB\-\-cc\fR, +\fB\-\-cppflags\fR, +\fB\-\-cflags\fR, +\fB\-\-cflags_sl\fR, +\fB\-\-ldflags\fR, +\fB\-\-ldflags_sl\fR, and +\fB\-\-libs\fR +were added in +PostgreSQL +8\&.1\&. The option +\fB\-\-htmldir\fR +was added in +PostgreSQL +8\&.4\&. The option +\fB\-\-ldflags_ex\fR +was added in +PostgreSQL +9\&.0\&. +.PP +In releases prior to +PostgreSQL +7\&.1, before +\fBpg_config\fR +came to be, a method for finding the equivalent configuration information did not exist\&. +.SH "EXAMPLE" +.PP +To reproduce the build configuration of the current PostgreSQL installation, run the following command: +.sp +.if n \{\ +.RS 4 +.\} +.nf +eval \&./configure `pg_config \-\-configure` +.fi +.if n \{\ +.RE +.\} +.sp +The output of +pg_config \-\-configure +contains shell quotation marks so arguments with spaces are represented correctly\&. Therefore, using +eval +is required for proper results\&. diff --git a/doc/src/sgml/man1/pg_controldata.1 b/doc/src/sgml/man1/pg_controldata.1 new file mode 100644 index 000000000..0156597eb --- /dev/null +++ b/doc/src/sgml/man1/pg_controldata.1 @@ -0,0 +1,58 @@ +'\" t +.\" Title: pg_controldata +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "PG_CONTROLDATA" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +pg_controldata \- display control information of a PostgreSQL database cluster +.\" pg_controldata +.SH "SYNOPSIS" +.HP \w'\fBpg_controldata\fR\ 'u +\fBpg_controldata\fR [\fIoption\fR] [\fIdatadir\fR] +.SH "DESCRIPTION" +.PP + +\fBpg_controldata\fR +prints information initialized during +\fBinitdb\fR, such as the catalog version\&. It also shows information about write\-ahead logging and checkpoint processing\&. This information is cluster\-wide, and not specific to any one database\&. +.PP +This utility can only be run by the user who initialized the cluster because it requires read access to the data directory\&. You can specify the data directory on the command line, or use the environment variable +\fBPGDATA\fR\&. This utility supports the options +\fB\-V\fR +and +\fB\-\-version\fR, which print the +pg_controldata +version and exit\&. It also supports options +\fB\-?\fR +and +\fB\-\-help\fR, which output the supported arguments\&. +.SH "ENVIRONMENT" +.PP +\fBPGDATA\fR +.RS 4 +Default data directory location +.RE diff --git a/doc/src/sgml/man1/pg_ctl.1 b/doc/src/sgml/man1/pg_ctl.1 new file mode 100644 index 000000000..b8b74af08 --- /dev/null +++ b/doc/src/sgml/man1/pg_ctl.1 @@ -0,0 +1,462 @@ +'\" t +.\" Title: pg_ctl +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "PG_CTL" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +pg_ctl \- initialize, start, stop, or control a PostgreSQL server +.\" pg_ctl +.SH "SYNOPSIS" +.HP \w'\fBpg_ctl\fR\ 'u +\fBpg_ctl\fR \fBinit[db]\fR [\fB\-s\fR] [\fB\-D\fR\ \fIdatadir\fR] [\fB\-o\fR\ \fIinitdb\-options\fR] +.HP \w'\fBpg_ctl\fR\ 'u +\fBpg_ctl\fR \fBstart\fR [\fB\-w\fR] [\fB\-t\fR\ \fIseconds\fR] [\fB\-s\fR] [\fB\-D\fR\ \fIdatadir\fR] [\fB\-l\fR\ \fIfilename\fR] [\fB\-o\fR\ \fIoptions\fR] [\fB\-p\fR\ \fIpath\fR] [\fB\-c\fR] +.HP \w'\fBpg_ctl\fR\ 'u +\fBpg_ctl\fR \fBstop\fR [\fB\-W\fR] [\fB\-t\fR\ \fIseconds\fR] [\fB\-s\fR] [\fB\-D\fR\ \fIdatadir\fR] [\fB\-m\fR\ \fBs[mart]\fR\ |\ \fBf[ast]\fR\ |\ \fBi[mmediate]\fR] +.HP \w'\fBpg_ctl\fR\ 'u +\fBpg_ctl\fR \fBrestart\fR [\fB\-w\fR] [\fB\-t\fR\ \fIseconds\fR] [\fB\-s\fR] [\fB\-D\fR\ \fIdatadir\fR] [\fB\-c\fR] [\fB\-m\fR\ \fBs[mart]\fR\ |\ \fBf[ast]\fR\ |\ \fBi[mmediate]\fR] [\fB\-o\fR\ \fIoptions\fR] +.HP \w'\fBpg_ctl\fR\ 'u +\fBpg_ctl\fR \fBreload\fR [\fB\-s\fR] [\fB\-D\fR\ \fIdatadir\fR] +.HP \w'\fBpg_ctl\fR\ 'u +\fBpg_ctl\fR \fBstatus\fR [\fB\-D\fR\ \fIdatadir\fR] +.HP \w'\fBpg_ctl\fR\ 'u +\fBpg_ctl\fR \fBpromote\fR [\fB\-s\fR] [\fB\-D\fR\ \fIdatadir\fR] +.HP \w'\fBpg_ctl\fR\ 'u +\fBpg_ctl\fR \fBkill\fR \fIsignal_name\fR \fIprocess_id\fR +.HP \w'\fBpg_ctl\fR\ 'u +\fBpg_ctl\fR \fBregister\fR [\fB\-N\fR\ \fIservicename\fR] [\fB\-U\fR\ \fIusername\fR] [\fB\-P\fR\ \fIpassword\fR] [\fB\-D\fR\ \fIdatadir\fR] [\fB\-S\fR\ \fBa[uto]\fR\ |\ \fBd[emand]\fR] [\fB\-w\fR] [\fB\-t\fR\ \fIseconds\fR] [\fB\-s\fR] [\fB\-o\fR\ \fIoptions\fR] +.HP \w'\fBpg_ctl\fR\ 'u +\fBpg_ctl\fR \fBunregister\fR [\fB\-N\fR\ \fIservicename\fR] +.SH "DESCRIPTION" +.PP + +pg_ctl +is a utility for initializing a +PostgreSQL +database cluster, starting, stopping, or restarting the +PostgreSQL +database server (\fBpostgres\fR(1)), or displaying the status of a running server\&. Although the server can be started manually, +pg_ctl +encapsulates tasks such as redirecting log output and properly detaching from the terminal and process group\&. It also provides convenient options for controlled shutdown\&. +.PP +The +\fBinit\fR +or +\fBinitdb\fR +mode creates a new +PostgreSQL +database cluster\&. A database cluster is a collection of databases that are managed by a single server instance\&. This mode invokes the +\fBinitdb\fR +command\&. See +\fBinitdb\fR(1) +for details\&. +.PP +In +\fBstart\fR +mode, a new server is launched\&. The server is started in the background, and its standard input is attached to +/dev/null +(or +nul +on Windows)\&. On Unix\-like systems, by default, the server\*(Aqs standard output and standard error are sent to +pg_ctl\*(Aqs standard output (not standard error)\&. The standard output of +pg_ctl +should then be redirected to a file or piped to another process such as a log rotating program like +rotatelogs; otherwise +\fBpostgres\fR +will write its output to the controlling terminal (from the background) and will not leave the shell\*(Aqs process group\&. On Windows, by default the server\*(Aqs standard output and standard error are sent to the terminal\&. These default behaviors can be changed by using +\fB\-l\fR +to append the server\*(Aqs output to a log file\&. Use of either +\fB\-l\fR +or output redirection is recommended\&. +.PP +In +\fBstop\fR +mode, the server that is running in the specified data directory is shut down\&. Three different shutdown methods can be selected with the +\fB\-m\fR +option\&. +\(lqSmart\(rq +mode (the default) waits for all active clients to disconnect and any online backup to finish\&. If the server is in hot standby, recovery and streaming replication will be terminated once all clients have disconnected\&. +\(lqFast\(rq +mode does not wait for clients to disconnect and will terminate an online backup in progress\&. All active transactions are rolled back and clients are forcibly disconnected, then the server is shut down\&. +\(lqImmediate\(rq +mode will abort all server processes immediately, without a clean shutdown\&. This will lead to a crash\-recovery run on the next restart\&. +.PP + +\fBrestart\fR +mode effectively executes a stop followed by a start\&. This allows changing the +\fBpostgres\fR +command\-line options\&. +.PP + +\fBreload\fR +mode simply sends the +\fBpostgres\fR +process a +SIGHUP +signal, causing it to reread its configuration files (postgresql\&.conf, +pg_hba\&.conf, etc\&.)\&. This allows changing of configuration\-file options that do not require a complete restart to take effect\&. +.PP + +\fBstatus\fR +mode checks whether a server is running in the specified data directory\&. If it is, the +PID +and the command line options that were used to invoke it are displayed\&. If the server is not running, the process returns an exit status of 3\&. +.PP +In +\fBpromote\fR +mode, the standby server that is running in the specified data directory is commanded to exit recovery and begin read\-write operations\&. +.PP + +\fBkill\fR +mode allows you to send a signal to a specified process\&. This is particularly valuable for +Microsoft Windows +which does not have a +kill +command\&. Use +\-\-help +to see a list of supported signal names\&. +.PP + +\fBregister\fR +mode allows you to register a system service on +Microsoft Windows\&. The +\fB\-S\fR +option allows selection of service start type, either +\(lqauto\(rq +(start service automatically on system startup) or +\(lqdemand\(rq +(start service on demand)\&. +.PP + +\fBunregister\fR +mode allows you to unregister a system service on +Microsoft Windows\&. This undoes the effects of the +\fBregister\fR +command\&. +.SH "OPTIONS" +.PP +\fB\-c\fR, \fB\-\-core\-file\fR +.RS 4 +Attempt to allow server crashes to produce core files, on platforms where this is possible, by lifting any soft resource limit placed on core files\&. This is useful in debugging or diagnosing problems by allowing a stack trace to be obtained from a failed server process\&. +.RE +.PP +\fB\-D \fR\fB\fIdatadir\fR\fR, \fB\-\-pgdata \fR\fB\fIdatadir\fR\fR +.RS 4 +Specifies the file system location of the database files\&. If this is omitted, the environment variable +\fBPGDATA\fR +is used\&. +.RE +.PP +\fB\-l \fR\fB\fIfilename\fR\fR, \fB\-\-log \fR\fB\fIfilename\fR\fR +.RS 4 +Append the server log output to +\fIfilename\fR\&. If the file does not exist, it is created\&. The +umask +is set to 077, so access to the log file is disallowed to other users by default\&. +.RE +.PP +\fB\-m \fR\fB\fImode\fR\fR, \fB\-\-mode \fR\fB\fImode\fR\fR +.RS 4 +Specifies the shutdown mode\&. +\fImode\fR +can be +smart, +fast, or +immediate, or the first letter of one of these three\&. If this is omitted, +smart +is used\&. +.RE +.PP +\fB\-o \fR\fB\fIoptions\fR\fR +.RS 4 +Specifies options to be passed directly to the +\fBpostgres\fR +command\&. +.sp +The options should usually be surrounded by single or double quotes to ensure that they are passed through as a group\&. +.RE +.PP +\fB\-o \fR\fB\fIinitdb\-options\fR\fR +.RS 4 +Specifies options to be passed directly to the +\fBinitdb\fR +command\&. +.sp +The options should usually be surrounded by single or double quotes to ensure that they are passed through as a group\&. +.RE +.PP +\fB\-p \fR\fB\fIpath\fR\fR +.RS 4 +Specifies the location of the +postgres +executable\&. By default the +postgres +executable is taken from the same directory as +\fBpg_ctl\fR, or failing that, the hard\-wired installation directory\&. It is not necessary to use this option unless you are doing something unusual and get errors that the +postgres +executable was not found\&. +.sp +In +init +mode, this option analogously specifies the location of the +initdb +executable\&. +.RE +.PP +\fB\-s\fR, \fB\-\-silent\fR +.RS 4 +Print only errors, no informational messages\&. +.RE +.PP +\fB\-t\fR, \fB\-\-timeout\fR +.RS 4 +The maximum number of seconds to wait when waiting for startup or shutdown to complete\&. The default is 60 seconds\&. +.RE +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +pg_ctl +version and exit\&. +.RE +.PP +\fB\-w\fR +.RS 4 +Wait for the startup or shutdown to complete\&. Waiting is the default option for shutdowns, but not startups\&. When waiting for startup, +\fBpg_ctl\fR +repeatedly attempts to connect to the server\&. When waiting for shutdown, +\fBpg_ctl\fR +waits for the server to remove its +PID +file\&. +\fBpg_ctl\fR +returns an exit code based on the success of the startup or shutdown\&. +.RE +.PP +\fB\-W\fR +.RS 4 +Do not wait for startup or shutdown to complete\&. This is the default for start and restart modes\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +pg_ctl +command line arguments, and exit\&. +.RE +.SS "Options for Windows" +.PP +\fB\-N \fR\fB\fIservicename\fR\fR +.RS 4 +Name of the system service to register\&. The name will be used as both the service name and the display name\&. +.RE +.PP +\fB\-P \fR\fB\fIpassword\fR\fR +.RS 4 +Password for the user to start the service\&. +.RE +.PP +\fB\-S \fR\fB\fIstart\-type\fR\fR +.RS 4 +Start type of the system service to register\&. start\-type can be +auto, or +demand, or the first letter of one of these two\&. If this is omitted, +auto +is used\&. +.RE +.PP +\fB\-U \fR\fB\fIusername\fR\fR +.RS 4 +User name for the user to start the service\&. For domain users, use the format +DOMAIN\eusername\&. +.RE +.SH "ENVIRONMENT" +.PP +\fBPGDATA\fR +.RS 4 +Default data directory location\&. +.RE +.PP + +\fBpg_ctl\fR, like most other +PostgreSQL +utilities, also uses the environment variables supported by +libpq +(see +Section 31.14, \(lqEnvironment Variables\(rq, in the documentation)\&. For additional server variables, see +\fBpostgres\fR(1)\&. +.SH "FILES" +.PP +postmaster\&.pid +.RS 4 +The existence of this file in the data directory is used to help +pg_ctl +determine if the server is currently running\&. +.RE +.PP +postmaster\&.opts +.RS 4 +If this file exists in the data directory, +pg_ctl +(in +\fBrestart\fR +mode) will pass the contents of the file as options to +postgres, unless overridden by the +\fB\-o\fR +option\&. The contents of this file are also displayed in +\fBstatus\fR +mode\&. +.RE +.SH "EXAMPLES" +.SS "Starting the Server" +.PP +To start the server: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_ctl start\fR +.fi +.if n \{\ +.RE +.\} +.PP +To start the server, waiting until the server is accepting connections: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_ctl \-w start\fR +.fi +.if n \{\ +.RE +.\} +.PP +To start the server using port 5433, and running without +\fBfsync\fR, use: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_ctl \-o "\-F \-p 5433" start\fR +.fi +.if n \{\ +.RE +.\} +.SS "Stopping the Server" +.PP +To stop the server, use: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_ctl stop\fR +.fi +.if n \{\ +.RE +.\} +.sp +The +\fB\-m\fR +option allows control over +\fIhow\fR +the server shuts down: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_ctl stop \-m fast\fR +.fi +.if n \{\ +.RE +.\} +.SS "Restarting the Server" +.PP +Restarting the server is almost equivalent to stopping the server and starting it again, except that +\fBpg_ctl\fR +saves and reuses the command line options that were passed to the previously running instance\&. To restart the server in the simplest form, use: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_ctl restart\fR +.fi +.if n \{\ +.RE +.\} +.PP +To restart the server, waiting for it to shut down and restart: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_ctl \-w restart\fR +.fi +.if n \{\ +.RE +.\} +.PP +To restart using port 5433, disabling +\fBfsync\fR +upon restart: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_ctl \-o "\-F \-p 5433" restart\fR +.fi +.if n \{\ +.RE +.\} +.SS "Showing the Server Status" +.PP +Here is sample status output from +pg_ctl: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_ctl status\fR +pg_ctl: server is running (PID: 13718) +/usr/local/pgsql/bin/postgres "\-D" "/usr/local/pgsql/data" "\-p" "5433" "\-B" "128" +.fi +.if n \{\ +.RE +.\} +.sp +This is the command line that would be invoked in restart mode\&. +.SH "SEE ALSO" +\fBinitdb\fR(1), \fBpostgres\fR(1) diff --git a/doc/src/sgml/man1/pg_dump.1 b/doc/src/sgml/man1/pg_dump.1 new file mode 100644 index 000000000..73ad99a7b --- /dev/null +++ b/doc/src/sgml/man1/pg_dump.1 @@ -0,0 +1,855 @@ +'\" t +.\" Title: pg_dump +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "PG_DUMP" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +pg_dump \- extract a PostgreSQL database into a script file or other archive file +.\" pg_dump +.SH "SYNOPSIS" +.HP \w'\fBpg_dump\fR\ 'u +\fBpg_dump\fR [\fIconnection\-option\fR...] [\fIoption\fR...] [\fIdbname\fR] +.SH "DESCRIPTION" +.PP + +pg_dump +is a utility for backing up a +PostgreSQL +database\&. It makes consistent backups even if the database is being used concurrently\&. +pg_dump +does not block other users accessing the database (readers or writers)\&. +.PP +Dumps can be output in script or archive file formats\&. Script dumps are plain\-text files containing the SQL commands required to reconstruct the database to the state it was in at the time it was saved\&. To restore from such a script, feed it to +\fBpsql\fR(1)\&. Script files can be used to reconstruct the database even on other machines and other architectures; with some modifications, even on other SQL database products\&. +.PP +The alternative archive file formats must be used with +\fBpg_restore\fR(1) +to rebuild the database\&. They allow +pg_restore +to be selective about what is restored, or even to reorder the items prior to being restored\&. The archive file formats are designed to be portable across architectures\&. +.PP +When used with one of the archive file formats and combined with +pg_restore, +pg_dump +provides a flexible archival and transfer mechanism\&. +pg_dump +can be used to backup an entire database, then +pg_restore +can be used to examine the archive and/or select which parts of the database are to be restored\&. The most flexible output file format is the +\(lqcustom\(rq +format (\fB\-Fc\fR)\&. It allows for selection and reordering of all archived items, and is compressed by default\&. +.PP +While running +pg_dump, one should examine the output for any warnings (printed on standard error), especially in light of the limitations listed below\&. +.SH "OPTIONS" +.PP +The following command\-line options control the content and format of the output\&. +.PP +\fIdbname\fR +.RS 4 +Specifies the name of the database to be dumped\&. If this is not specified, the environment variable +\fBPGDATABASE\fR +is used\&. If that is not set, the user name specified for the connection is used\&. +.RE +.PP +\fB\-a\fR, \fB\-\-data\-only\fR +.RS 4 +Dump only the data, not the schema (data definitions)\&. Table data, large objects, and sequence values are dumped\&. +.sp +This option is similar to, but for historical reasons not identical to, specifying +\fB\-\-section=data\fR\&. +.RE +.PP +\fB\-b\fR, \fB\-\-blobs\fR +.RS 4 +Include large objects in the dump\&. This is the default behavior except when +\fB\-\-schema\fR, +\fB\-\-table\fR, or +\fB\-\-schema\-only\fR +is specified, so the +\fB\-b\fR +switch is only useful to add large objects to selective dumps\&. +.RE +.PP +\fB\-c\fR, \fB\-\-clean\fR +.RS 4 +Output commands to clean (drop) database objects prior to outputting the commands for creating them\&. (Restore might generate some harmless error messages, if any objects were not present in the destination database\&.) +.sp +This option is only meaningful for the plain\-text format\&. For the archive formats, you can specify the option when you call +\fBpg_restore\fR\&. +.RE +.PP +\fB\-C\fR, \fB\-\-create\fR +.RS 4 +Begin the output with a command to create the database itself and reconnect to the created database\&. (With a script of this form, it doesn\*(Aqt matter which database in the destination installation you connect to before running the script\&.) If +\fB\-\-clean\fR +is also specified, the script drops and recreates the target database before reconnecting to it\&. +.sp +This option is only meaningful for the plain\-text format\&. For the archive formats, you can specify the option when you call +\fBpg_restore\fR\&. +.RE +.PP +\fB\-E \fR\fB\fIencoding\fR\fR, \fB\-\-encoding=\fR\fB\fIencoding\fR\fR +.RS 4 +Create the dump in the specified character set encoding\&. By default, the dump is created in the database encoding\&. (Another way to get the same result is to set the +\fBPGCLIENTENCODING\fR +environment variable to the desired dump encoding\&.) +.RE +.PP +\fB\-f \fR\fB\fIfile\fR\fR, \fB\-\-file=\fR\fB\fIfile\fR\fR +.RS 4 +Send output to the specified file\&. This parameter can be omitted for file based output formats, in which case the standard output is used\&. It must be given for the directory output format however, where it specifies the target directory instead of a file\&. In this case the directory is created by +\fBpg_dump\fR +and must not exist before\&. +.RE +.PP +\fB\-F \fR\fB\fIformat\fR\fR, \fB\-\-format=\fR\fB\fIformat\fR\fR +.RS 4 +Selects the format of the output\&. +\fIformat\fR +can be one of the following: +.PP +p, plain +.RS 4 +Output a plain\-text +SQL +script file (the default)\&. +.RE +.PP +c, custom +.RS 4 +Output a custom\-format archive suitable for input into +pg_restore\&. Together with the directory output format, this is the most flexible output format in that it allows manual selection and reordering of archived items during restore\&. This format is also compressed by default\&. +.RE +.PP +d, directory +.RS 4 +Output a directory\-format archive suitable for input into +pg_restore\&. This will create a directory with one file for each table and blob being dumped, plus a so\-called Table of Contents file describing the dumped objects in a machine\-readable format that +pg_restore +can read\&. A directory format archive can be manipulated with standard Unix tools; for example, files in an uncompressed archive can be compressed with the +gzip +tool\&. This format is compressed by default\&. +.RE +.PP +t, tar +.RS 4 +Output a +\fBtar\fR\-format archive suitable for input into +pg_restore\&. The tar\-format is compatible with the directory\-format; extracting a tar\-format archive produces a valid directory\-format archive\&. However, the tar\-format does not support compression and has a limit of 8 GB on the size of individual tables\&. Also, the relative order of table data items cannot be changed during restore\&. +.RE +.RE +.PP +\fB\-i\fR, \fB\-\-ignore\-version\fR +.RS 4 +A deprecated option that is now ignored\&. +.RE +.PP +\fB\-n \fR\fB\fIschema\fR\fR, \fB\-\-schema=\fR\fB\fIschema\fR\fR +.RS 4 +Dump only schemas matching +\fIschema\fR; this selects both the schema itself, and all its contained objects\&. When this option is not specified, all non\-system schemas in the target database will be dumped\&. Multiple schemas can be selected by writing multiple +\fB\-n\fR +switches\&. Also, the +\fIschema\fR +parameter is interpreted as a pattern according to the same rules used by +psql\*(Aqs +\ed +commands (see +Patterns), so multiple schemas can also be selected by writing wildcard characters in the pattern\&. When using wildcards, be careful to quote the pattern if needed to prevent the shell from expanding the wildcards; see +EXAMPLES\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +When +\fB\-n\fR +is specified, +pg_dump +makes no attempt to dump any other database objects that the selected schema(s) might depend upon\&. Therefore, there is no guarantee that the results of a specific\-schema dump can be successfully restored by themselves into a clean database\&. +.sp .5v +.RE +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +Non\-schema objects such as blobs are not dumped when +\fB\-n\fR +is specified\&. You can add blobs back to the dump with the +\fB\-\-blobs\fR +switch\&. +.sp .5v +.RE +.RE +.PP +\fB\-N \fR\fB\fIschema\fR\fR, \fB\-\-exclude\-schema=\fR\fB\fIschema\fR\fR +.RS 4 +Do not dump any schemas matching the +\fIschema\fR +pattern\&. The pattern is interpreted according to the same rules as for +\fB\-n\fR\&. +\fB\-N\fR +can be given more than once to exclude schemas matching any of several patterns\&. +.sp +When both +\fB\-n\fR +and +\fB\-N\fR +are given, the behavior is to dump just the schemas that match at least one +\fB\-n\fR +switch but no +\fB\-N\fR +switches\&. If +\fB\-N\fR +appears without +\fB\-n\fR, then schemas matching +\fB\-N\fR +are excluded from what is otherwise a normal dump\&. +.RE +.PP +\fB\-o\fR, \fB\-\-oids\fR +.RS 4 +Dump object identifiers (OIDs) as part of the data for every table\&. Use this option if your application references the +OID +columns in some way (e\&.g\&., in a foreign key constraint)\&. Otherwise, this option should not be used\&. +.RE +.PP +\fB\-O\fR, \fB\-\-no\-owner\fR +.RS 4 +Do not output commands to set ownership of objects to match the original database\&. By default, +pg_dump +issues +\fBALTER OWNER\fR +or +\fBSET SESSION AUTHORIZATION\fR +statements to set ownership of created database objects\&. These statements will fail when the script is run unless it is started by a superuser (or the same user that owns all of the objects in the script)\&. To make a script that can be restored by any user, but will give that user ownership of all the objects, specify +\fB\-O\fR\&. +.sp +This option is only meaningful for the plain\-text format\&. For the archive formats, you can specify the option when you call +\fBpg_restore\fR\&. +.RE +.PP +\fB\-R\fR, \fB\-\-no\-reconnect\fR +.RS 4 +This option is obsolete but still accepted for backwards compatibility\&. +.RE +.PP +\fB\-s\fR, \fB\-\-schema\-only\fR +.RS 4 +Dump only the object definitions (schema), not data\&. +.sp +This option is the inverse of +\fB\-\-data\-only\fR\&. It is similar to, but for historical reasons not identical to, specifying +\fB\-\-section=pre\-data \-\-section=post\-data\fR\&. +.sp +(Do not confuse this with the +\fB\-\-schema\fR +option, which uses the word +\(lqschema\(rq +in a different meaning\&.) +.sp +To exclude table data for only a subset of tables in the database, see +\fB\-\-exclude\-table\-data\fR\&. +.RE +.PP +\fB\-S \fR\fB\fIusername\fR\fR, \fB\-\-superuser=\fR\fB\fIusername\fR\fR +.RS 4 +Specify the superuser user name to use when disabling triggers\&. This is only relevant if +\fB\-\-disable\-triggers\fR +is used\&. (Usually, it\*(Aqs better to leave this out, and instead start the resulting script as superuser\&.) +.RE +.PP +\fB\-t \fR\fB\fItable\fR\fR, \fB\-\-table=\fR\fB\fItable\fR\fR +.RS 4 +Dump only tables (or views or sequences or foreign tables) matching +\fItable\fR\&. Multiple tables can be selected by writing multiple +\fB\-t\fR +switches\&. Also, the +\fItable\fR +parameter is interpreted as a pattern according to the same rules used by +psql\*(Aqs +\ed +commands (see +Patterns), so multiple tables can also be selected by writing wildcard characters in the pattern\&. When using wildcards, be careful to quote the pattern if needed to prevent the shell from expanding the wildcards; see +EXAMPLES\&. +.sp +The +\fB\-n\fR +and +\fB\-N\fR +switches have no effect when +\fB\-t\fR +is used, because tables selected by +\fB\-t\fR +will be dumped regardless of those switches, and non\-table objects will not be dumped\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +When +\fB\-t\fR +is specified, +pg_dump +makes no attempt to dump any other database objects that the selected table(s) might depend upon\&. Therefore, there is no guarantee that the results of a specific\-table dump can be successfully restored by themselves into a clean database\&. +.sp .5v +.RE +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +The behavior of the +\fB\-t\fR +switch is not entirely upward compatible with pre\-8\&.2 +PostgreSQL +versions\&. Formerly, writing +\-t tab +would dump all tables named +tab, but now it just dumps whichever one is visible in your default search path\&. To get the old behavior you can write +\-t \*(Aq*\&.tab\*(Aq\&. Also, you must write something like +\-t sch\&.tab +to select a table in a particular schema, rather than the old locution of +\-n sch \-t tab\&. +.sp .5v +.RE +.RE +.PP +\fB\-T \fR\fB\fItable\fR\fR, \fB\-\-exclude\-table=\fR\fB\fItable\fR\fR +.RS 4 +Do not dump any tables matching the +\fItable\fR +pattern\&. The pattern is interpreted according to the same rules as for +\fB\-t\fR\&. +\fB\-T\fR +can be given more than once to exclude tables matching any of several patterns\&. +.sp +When both +\fB\-t\fR +and +\fB\-T\fR +are given, the behavior is to dump just the tables that match at least one +\fB\-t\fR +switch but no +\fB\-T\fR +switches\&. If +\fB\-T\fR +appears without +\fB\-t\fR, then tables matching +\fB\-T\fR +are excluded from what is otherwise a normal dump\&. +.RE +.PP +\fB\-v\fR, \fB\-\-verbose\fR +.RS 4 +Specifies verbose mode\&. This will cause +pg_dump +to output detailed object comments and start/stop times to the dump file, and progress messages to standard error\&. +.RE +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +pg_dump +version and exit\&. +.RE +.PP +\fB\-x\fR, \fB\-\-no\-privileges\fR, \fB\-\-no\-acl\fR +.RS 4 +Prevent dumping of access privileges (grant/revoke commands)\&. +.RE +.PP +\fB\-Z \fR\fB\fI0\&.\&.9\fR\fR, \fB\-\-compress=\fR\fB\fI0\&.\&.9\fR\fR +.RS 4 +Specify the compression level to use\&. Zero means no compression\&. For the custom archive format, this specifies compression of individual table\-data segments, and the default is to compress at a moderate level\&. For plain text output, setting a nonzero compression level causes the entire output file to be compressed, as though it had been fed through +gzip; but the default is not to compress\&. The tar archive format currently does not support compression at all\&. +.RE +.PP +\fB\-\-binary\-upgrade\fR +.RS 4 +This option is for use by in\-place upgrade utilities\&. Its use for other purposes is not recommended or supported\&. The behavior of the option may change in future releases without notice\&. +.RE +.PP +\fB\-\-column\-inserts\fR, \fB\-\-attribute\-inserts\fR +.RS 4 +Dump data as +\fBINSERT\fR +commands with explicit column names (INSERT INTO \fItable\fR (\fIcolumn\fR, \&.\&.\&.) VALUES \&.\&.\&.)\&. This will make restoration very slow; it is mainly useful for making dumps that can be loaded into non\-PostgreSQL +databases\&. However, since this option generates a separate command for each row, an error in reloading a row causes only that row to be lost rather than the entire table contents\&. +.RE +.PP +\fB\-\-disable\-dollar\-quoting\fR +.RS 4 +This option disables the use of dollar quoting for function bodies, and forces them to be quoted using SQL standard string syntax\&. +.RE +.PP +\fB\-\-disable\-triggers\fR +.RS 4 +This option is only relevant when creating a data\-only dump\&. It instructs +pg_dump +to include commands to temporarily disable triggers on the target tables while the data is reloaded\&. Use this if you have referential integrity checks or other triggers on the tables that you do not want to invoke during data reload\&. +.sp +Presently, the commands emitted for +\fB\-\-disable\-triggers\fR +must be done as superuser\&. So, you should also specify a superuser name with +\fB\-S\fR, or preferably be careful to start the resulting script as a superuser\&. +.sp +This option is only meaningful for the plain\-text format\&. For the archive formats, you can specify the option when you call +\fBpg_restore\fR\&. +.RE +.PP +\fB\-\-exclude\-table\-data=\fR\fB\fItable\fR\fR +.RS 4 +Do not dump data for any tables matching the +\fItable\fR +pattern\&. The pattern is interpreted according to the same rules as for +\fB\-t\fR\&. +\fB\-\-exclude\-table\-data\fR +can be given more than once to exclude tables matching any of several patterns\&. This option is useful when you need the definition of a particular table even though you do not need the data in it\&. +.sp +To exclude data for all tables in the database, see +\fB\-\-schema\-only\fR\&. +.RE +.PP +\fB\-\-inserts\fR +.RS 4 +Dump data as +\fBINSERT\fR +commands (rather than +\fBCOPY\fR)\&. This will make restoration very slow; it is mainly useful for making dumps that can be loaded into non\-PostgreSQL +databases\&. However, since this option generates a separate command for each row, an error in reloading a row causes only that row to be lost rather than the entire table contents\&. Note that the restore might fail altogether if you have rearranged column order\&. The +\fB\-\-column\-inserts\fR +option is safe against column order changes, though even slower\&. +.RE +.PP +\fB\-\-lock\-wait\-timeout=\fR\fB\fItimeout\fR\fR +.RS 4 +Do not wait forever to acquire shared table locks at the beginning of the dump\&. Instead fail if unable to lock a table within the specified +\fItimeout\fR\&. The timeout may be specified in any of the formats accepted by +\fBSET statement_timeout\fR\&. (Allowed values vary depending on the server version you are dumping from, but an integer number of milliseconds is accepted by all versions since 7\&.3\&. This option is ignored when dumping from a pre\-7\&.3 server\&.) +.RE +.PP +\fB\-\-no\-security\-labels\fR +.RS 4 +Do not dump security labels\&. +.RE +.PP +\fB\-\-no\-tablespaces\fR +.RS 4 +Do not output commands to select tablespaces\&. With this option, all objects will be created in whichever tablespace is the default during restore\&. +.sp +This option is only meaningful for the plain\-text format\&. For the archive formats, you can specify the option when you call +\fBpg_restore\fR\&. +.RE +.PP +\fB\-\-no\-unlogged\-table\-data\fR +.RS 4 +Do not dump the contents of unlogged tables\&. This option has no effect on whether or not the table definitions (schema) are dumped; it only suppresses dumping the table data\&. +.RE +.PP +\fB\-\-quote\-all\-identifiers\fR +.RS 4 +Force quoting of all identifiers\&. This may be useful when dumping a database for migration to a future version that may have introduced additional keywords\&. +.RE +.PP +\fB\-\-section=\fR\fB\fIsectionname\fR\fR +.RS 4 +Only dump the named section\&. The section name can be +\fBpre\-data\fR, +\fBdata\fR, or +\fBpost\-data\fR\&. This option can be specified more than once to select multiple sections\&. The default is to dump all sections\&. +.sp +The data section contains actual table data, large\-object contents, and sequence values\&. Post\-data items include definitions of indexes, triggers, rules, and constraints other than validated check constraints\&. Pre\-data items include all other data definition items\&. +.RE +.PP +\fB\-\-serializable\-deferrable\fR +.RS 4 +Use a +serializable +transaction for the dump, to ensure that the snapshot used is consistent with later database states; but do this by waiting for a point in the transaction stream at which no anomalies can be present, so that there isn\*(Aqt a risk of the dump failing or causing other transactions to roll back with a +serialization_failure\&. See +Chapter 13, Concurrency Control, in the documentation +for more information about transaction isolation and concurrency control\&. +.sp +This option is not beneficial for a dump which is intended only for disaster recovery\&. It could be useful for a dump used to load a copy of the database for reporting or other read\-only load sharing while the original database continues to be updated\&. Without it the dump may reflect a state which is not consistent with any serial execution of the transactions eventually committed\&. For example, if batch processing techniques are used, a batch may show as closed in the dump without all of the items which are in the batch appearing\&. +.sp +This option will make no difference if there are no read\-write transactions active when pg_dump is started\&. If read\-write transactions are active, the start of the dump may be delayed for an indeterminate length of time\&. Once running, performance with or without the switch is the same\&. +.RE +.PP +\fB\-\-use\-set\-session\-authorization\fR +.RS 4 +Output SQL\-standard +\fBSET SESSION AUTHORIZATION\fR +commands instead of +\fBALTER OWNER\fR +commands to determine object ownership\&. This makes the dump more standards\-compatible, but depending on the history of the objects in the dump, might not restore properly\&. Also, a dump using +\fBSET SESSION AUTHORIZATION\fR +will certainly require superuser privileges to restore correctly, whereas +\fBALTER OWNER\fR +requires lesser privileges\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +pg_dump +command line arguments, and exit\&. +.RE +.PP +The following command\-line options control the database connection parameters\&. +.PP +\fB\-h \fR\fB\fIhost\fR\fR, \fB\-\-host=\fR\fB\fIhost\fR\fR +.RS 4 +Specifies the host name of the machine on which the server is running\&. If the value begins with a slash, it is used as the directory for the Unix domain socket\&. The default is taken from the +\fBPGHOST\fR +environment variable, if set, else a Unix domain socket connection is attempted\&. +.RE +.PP +\fB\-p \fR\fB\fIport\fR\fR, \fB\-\-port=\fR\fB\fIport\fR\fR +.RS 4 +Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections\&. Defaults to the +\fBPGPORT\fR +environment variable, if set, or a compiled\-in default\&. +.RE +.PP +\fB\-U \fR\fB\fIusername\fR\fR, \fB\-\-username=\fR\fB\fIusername\fR\fR +.RS 4 +User name to connect as\&. +.RE +.PP +\fB\-w\fR, \fB\-\-no\-password\fR +.RS 4 +Never issue a password prompt\&. If the server requires password authentication and a password is not available by other means such as a +\&.pgpass +file, the connection attempt will fail\&. This option can be useful in batch jobs and scripts where no user is present to enter a password\&. +.RE +.PP +\fB\-W\fR, \fB\-\-password\fR +.RS 4 +Force +pg_dump +to prompt for a password before connecting to a database\&. +.sp +This option is never essential, since +pg_dump +will automatically prompt for a password if the server demands password authentication\&. However, +pg_dump +will waste a connection attempt finding out that the server wants a password\&. In some cases it is worth typing +\fB\-W\fR +to avoid the extra connection attempt\&. +.RE +.PP +\fB\-\-role=\fR\fB\fIrolename\fR\fR +.RS 4 +Specifies a role name to be used to create the dump\&. This option causes +pg_dump +to issue a +\fBSET ROLE\fR +\fIrolename\fR +command after connecting to the database\&. It is useful when the authenticated user (specified by +\fB\-U\fR) lacks privileges needed by +pg_dump, but can switch to a role with the required rights\&. Some installations have a policy against logging in directly as a superuser, and use of this option allows dumps to be made without violating the policy\&. +.RE +.SH "ENVIRONMENT" +.PP +\fBPGDATABASE\fR, \fBPGHOST\fR, \fBPGOPTIONS\fR, \fBPGPORT\fR, \fBPGUSER\fR +.RS 4 +Default connection parameters\&. +.RE +.PP +This utility, like most other +PostgreSQL +utilities, also uses the environment variables supported by +libpq +(see +Section 31.14, \(lqEnvironment Variables\(rq, in the documentation)\&. +.SH "DIAGNOSTICS" +.PP + +pg_dump +internally executes +\fBSELECT\fR +statements\&. If you have problems running +pg_dump, make sure you are able to select information from the database using, for example, +\fBpsql\fR(1)\&. Also, any default connection settings and environment variables used by the +libpq +front\-end library will apply\&. +.PP +The database activity of +pg_dump +is normally collected by the statistics collector\&. If this is undesirable, you can set parameter +\fItrack_counts\fR +to false via +\fBPGOPTIONS\fR +or the +ALTER USER +command\&. +.SH "NOTES" +.PP +If your database cluster has any local additions to the +template1 +database, be careful to restore the output of +pg_dump +into a truly empty database; otherwise you are likely to get errors due to duplicate definitions of the added objects\&. To make an empty database without any local additions, copy from +template0 +not +template1, for example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE DATABASE foo WITH TEMPLATE template0; +.fi +.if n \{\ +.RE +.\} +.PP +When a data\-only dump is chosen and the option +\fB\-\-disable\-triggers\fR +is used, +pg_dump +emits commands to disable triggers on user tables before inserting the data, and then commands to re\-enable them after the data has been inserted\&. If the restore is stopped in the middle, the system catalogs might be left in the wrong state\&. +.PP +Members of tar archives are limited to a size less than 8 GB\&. (This is an inherent limitation of the tar file format\&.) Therefore this format cannot be used if the textual representation of any one table exceeds that size\&. The total size of a tar archive and any of the other output formats is not limited, except possibly by the operating system\&. +.PP +The dump file produced by +pg_dump +does not contain the statistics used by the optimizer to make query planning decisions\&. Therefore, it is wise to run +\fBANALYZE\fR +after restoring from a dump file to ensure optimal performance; see +Section 23.1.3, \(lqUpdating Planner Statistics\(rq, in the documentation +and +Section 23.1.6, \(lqThe Autovacuum Daemon\(rq, in the documentation +for more information\&. The dump file also does not contain any +\fBALTER DATABASE \&.\&.\&. SET\fR +commands; these settings are dumped by +\fBpg_dumpall\fR(1), along with database users and other installation\-wide settings\&. +.PP +Because +pg_dump +is used to transfer data to newer versions of +PostgreSQL, the output of +pg_dump +can be expected to load into +PostgreSQL +server versions newer than +pg_dump\*(Aqs version\&. +pg_dump +can also dump from +PostgreSQL +servers older than its own version\&. (Currently, servers back to version 7\&.0 are supported\&.) However, +pg_dump +cannot dump from +PostgreSQL +servers newer than its own major version; it will refuse to even try, rather than risk making an invalid dump\&. Also, it is not guaranteed that +pg_dump\*(Aqs output can be loaded into a server of an older major version \(em not even if the dump was taken from a server of that version\&. Loading a dump file into an older server may require manual editing of the dump file to remove syntax not understood by the older server\&. +.SH "EXAMPLES" +.PP +To dump a database called +mydb +into a SQL\-script file: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_dump mydb > db\&.sql\fR +.fi +.if n \{\ +.RE +.\} +.PP +To reload such a script into a (freshly created) database named +newdb: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpsql \-d newdb \-f db\&.sql\fR +.fi +.if n \{\ +.RE +.\} +.PP +To dump a database into a custom\-format archive file: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_dump \-Fc mydb > db\&.dump\fR +.fi +.if n \{\ +.RE +.\} +.PP +To dump a database into a directory\-format archive: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_dump \-Fd mydb \-f dumpdir\fR +.fi +.if n \{\ +.RE +.\} +.PP +To reload an archive file into a (freshly created) database named +newdb: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_restore \-d newdb db\&.dump\fR +.fi +.if n \{\ +.RE +.\} +.PP +To dump a single table named +mytab: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_dump \-t mytab mydb > db\&.sql\fR +.fi +.if n \{\ +.RE +.\} +.PP +To dump all tables whose names start with +emp +in the +detroit +schema, except for the table named +employee_log: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_dump \-t \*(Aqdetroit\&.emp*\*(Aq \-T detroit\&.employee_log mydb > db\&.sql\fR +.fi +.if n \{\ +.RE +.\} +.PP +To dump all schemas whose names start with +east +or +west +and end in +gsm, excluding any schemas whose names contain the word +test: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_dump \-n \*(Aqeast*gsm\*(Aq \-n \*(Aqwest*gsm\*(Aq \-N \*(Aq*test*\*(Aq mydb > db\&.sql\fR +.fi +.if n \{\ +.RE +.\} +.PP +The same, using regular expression notation to consolidate the switches: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_dump \-n \*(Aq(east|west)*gsm\*(Aq \-N \*(Aq*test*\*(Aq mydb > db\&.sql\fR +.fi +.if n \{\ +.RE +.\} +.PP +To dump all database objects except for tables whose names begin with +ts_: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_dump \-T \*(Aqts_*\*(Aq mydb > db\&.sql\fR +.fi +.if n \{\ +.RE +.\} +.PP +To specify an upper\-case or mixed\-case name in +\fB\-t\fR +and related switches, you need to double\-quote the name; else it will be folded to lower case (see +Patterns)\&. But double quotes are special to the shell, so in turn they must be quoted\&. Thus, to dump a single table with a mixed\-case name, you need something like +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_dump \-t \*(Aq"MixedCaseName"\*(Aq mydb > mytab\&.sql\fR +.fi +.if n \{\ +.RE +.\} +.SH "SEE ALSO" +\fBpg_dumpall\fR(1), \fBpg_restore\fR(1), \fBpsql\fR(1) diff --git a/doc/src/sgml/man1/pg_dumpall.1 b/doc/src/sgml/man1/pg_dumpall.1 new file mode 100644 index 000000000..38bfab65f --- /dev/null +++ b/doc/src/sgml/man1/pg_dumpall.1 @@ -0,0 +1,375 @@ +'\" t +.\" Title: pg_dumpall +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "PG_DUMPALL" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +pg_dumpall \- extract a PostgreSQL database cluster into a script file +.\" pg_dumpall +.SH "SYNOPSIS" +.HP \w'\fBpg_dumpall\fR\ 'u +\fBpg_dumpall\fR [\fIconnection\-option\fR...] [\fIoption\fR...] +.SH "DESCRIPTION" +.PP + +pg_dumpall +is a utility for writing out (\(lqdumping\(rq) all +PostgreSQL +databases of a cluster into one script file\&. The script file contains +SQL +commands that can be used as input to +\fBpsql\fR(1) +to restore the databases\&. It does this by calling +\fBpg_dump\fR(1) +for each database in a cluster\&. +pg_dumpall +also dumps global objects that are common to all databases\&. (pg_dump +does not save these objects\&.) This currently includes information about database users and groups, tablespaces, and properties such as access permissions that apply to databases as a whole\&. +.PP +Since +pg_dumpall +reads tables from all databases you will most likely have to connect as a database superuser in order to produce a complete dump\&. Also you will need superuser privileges to execute the saved script in order to be allowed to add users and groups, and to create databases\&. +.PP +The SQL script will be written to the standard output\&. Use the [\-f|file] option or shell operators to redirect it into a file\&. +.PP + +pg_dumpall +needs to connect several times to the +PostgreSQL +server (once per database)\&. If you use password authentication it will ask for a password each time\&. It is convenient to have a +~/\&.pgpass +file in such cases\&. See +Section 31.15, \(lqThe Password File\(rq, in the documentation +for more information\&. +.SH "OPTIONS" +.PP +The following command\-line options control the content and format of the output\&. +.PP +\fB\-a\fR, \fB\-\-data\-only\fR +.RS 4 +Dump only the data, not the schema (data definitions)\&. +.RE +.PP +\fB\-c\fR, \fB\-\-clean\fR +.RS 4 +Include SQL commands to clean (drop) databases before recreating them\&. +\fBDROP\fR +commands for roles and tablespaces are added as well\&. +.RE +.PP +\fB\-f \fR\fB\fIfilename\fR\fR, \fB\-\-file=\fR\fB\fIfilename\fR\fR +.RS 4 +Send output to the specified file\&. If this is omitted, the standard output is used\&. +.RE +.PP +\fB\-g\fR, \fB\-\-globals\-only\fR +.RS 4 +Dump only global objects (roles and tablespaces), no databases\&. +.RE +.PP +\fB\-i\fR, \fB\-\-ignore\-version\fR +.RS 4 +A deprecated option that is now ignored\&. +.RE +.PP +\fB\-o\fR, \fB\-\-oids\fR +.RS 4 +Dump object identifiers (OIDs) as part of the data for every table\&. Use this option if your application references the +OID +columns in some way (e\&.g\&., in a foreign key constraint)\&. Otherwise, this option should not be used\&. +.RE +.PP +\fB\-O\fR, \fB\-\-no\-owner\fR +.RS 4 +Do not output commands to set ownership of objects to match the original database\&. By default, +pg_dumpall +issues +\fBALTER OWNER\fR +or +\fBSET SESSION AUTHORIZATION\fR +statements to set ownership of created schema elements\&. These statements will fail when the script is run unless it is started by a superuser (or the same user that owns all of the objects in the script)\&. To make a script that can be restored by any user, but will give that user ownership of all the objects, specify +\fB\-O\fR\&. +.RE +.PP +\fB\-r\fR, \fB\-\-roles\-only\fR +.RS 4 +Dump only roles, no databases or tablespaces\&. +.RE +.PP +\fB\-s\fR, \fB\-\-schema\-only\fR +.RS 4 +Dump only the object definitions (schema), not data\&. +.RE +.PP +\fB\-S \fR\fB\fIusername\fR\fR, \fB\-\-superuser=\fR\fB\fIusername\fR\fR +.RS 4 +Specify the superuser user name to use when disabling triggers\&. This is only relevant if +\fB\-\-disable\-triggers\fR +is used\&. (Usually, it\*(Aqs better to leave this out, and instead start the resulting script as superuser\&.) +.RE +.PP +\fB\-t\fR, \fB\-\-tablespaces\-only\fR +.RS 4 +Dump only tablespaces, no databases or roles\&. +.RE +.PP +\fB\-v\fR, \fB\-\-verbose\fR +.RS 4 +Specifies verbose mode\&. This will cause +pg_dumpall +to output start/stop times to the dump file, and progress messages to standard error\&. It will also enable verbose output in +pg_dump\&. +.RE +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +pg_dumpall +version and exit\&. +.RE +.PP +\fB\-x\fR, \fB\-\-no\-privileges\fR, \fB\-\-no\-acl\fR +.RS 4 +Prevent dumping of access privileges (grant/revoke commands)\&. +.RE +.PP +\fB\-\-binary\-upgrade\fR +.RS 4 +This option is for use by in\-place upgrade utilities\&. Its use for other purposes is not recommended or supported\&. The behavior of the option may change in future releases without notice\&. +.RE +.PP +\fB\-\-column\-inserts\fR, \fB\-\-attribute\-inserts\fR +.RS 4 +Dump data as +\fBINSERT\fR +commands with explicit column names (INSERT INTO \fItable\fR (\fIcolumn\fR, \&.\&.\&.) VALUES \&.\&.\&.)\&. This will make restoration very slow; it is mainly useful for making dumps that can be loaded into non\-PostgreSQL +databases\&. +.RE +.PP +\fB\-\-disable\-dollar\-quoting\fR +.RS 4 +This option disables the use of dollar quoting for function bodies, and forces them to be quoted using SQL standard string syntax\&. +.RE +.PP +\fB\-\-disable\-triggers\fR +.RS 4 +This option is only relevant when creating a data\-only dump\&. It instructs +pg_dumpall +to include commands to temporarily disable triggers on the target tables while the data is reloaded\&. Use this if you have referential integrity checks or other triggers on the tables that you do not want to invoke during data reload\&. +.sp +Presently, the commands emitted for +\fB\-\-disable\-triggers\fR +must be done as superuser\&. So, you should also specify a superuser name with +\fB\-S\fR, or preferably be careful to start the resulting script as a superuser\&. +.RE +.PP +\fB\-\-inserts\fR +.RS 4 +Dump data as +\fBINSERT\fR +commands (rather than +\fBCOPY\fR)\&. This will make restoration very slow; it is mainly useful for making dumps that can be loaded into non\-PostgreSQL +databases\&. Note that the restore might fail altogether if you have rearranged column order\&. The +\fB\-\-column\-inserts\fR +option is safer, though even slower\&. +.RE +.PP +\fB\-\-lock\-wait\-timeout=\fR\fB\fItimeout\fR\fR +.RS 4 +Do not wait forever to acquire shared table locks at the beginning of the dump\&. Instead, fail if unable to lock a table within the specified +\fItimeout\fR\&. The timeout may be specified in any of the formats accepted by +\fBSET statement_timeout\fR\&. Allowed values vary depending on the server version you are dumping from, but an integer number of milliseconds is accepted by all versions since 7\&.3\&. This option is ignored when dumping from a pre\-7\&.3 server\&. +.RE +.PP +\fB\-\-no\-security\-labels\fR +.RS 4 +Do not dump security labels\&. +.RE +.PP +\fB\-\-no\-tablespaces\fR +.RS 4 +Do not output commands to create tablespaces nor select tablespaces for objects\&. With this option, all objects will be created in whichever tablespace is the default during restore\&. +.RE +.PP +\fB\-\-no\-unlogged\-table\-data\fR +.RS 4 +Do not dump the contents of unlogged tables\&. This option has no effect on whether or not the table definitions (schema) are dumped; it only suppresses dumping the table data\&. +.RE +.PP +\fB\-\-quote\-all\-identifiers\fR +.RS 4 +Force quoting of all identifiers\&. This may be useful when dumping a database for migration to a future version that may have introduced additional keywords\&. +.RE +.PP +\fB\-\-use\-set\-session\-authorization\fR +.RS 4 +Output SQL\-standard +\fBSET SESSION AUTHORIZATION\fR +commands instead of +\fBALTER OWNER\fR +commands to determine object ownership\&. This makes the dump more standards compatible, but depending on the history of the objects in the dump, might not restore properly\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +pg_dumpall +command line arguments, and exit\&. +.RE +.PP +The following command\-line options control the database connection parameters\&. +.PP +\fB\-h \fR\fB\fIhost\fR\fR, \fB\-\-host=\fR\fB\fIhost\fR\fR +.RS 4 +Specifies the host name of the machine on which the database server is running\&. If the value begins with a slash, it is used as the directory for the Unix domain socket\&. The default is taken from the +\fBPGHOST\fR +environment variable, if set, else a Unix domain socket connection is attempted\&. +.RE +.PP +\fB\-l \fR\fB\fIdbname\fR\fR, \fB\-\-database=\fR\fB\fIdbname\fR\fR +.RS 4 +Specifies the name of the database to connect to to dump global objects and discover what other databases should be dumped\&. If not specified, the +postgres +database will be used, and if that does not exist, +template1 +will be used\&. +.RE +.PP +\fB\-p \fR\fB\fIport\fR\fR, \fB\-\-port=\fR\fB\fIport\fR\fR +.RS 4 +Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections\&. Defaults to the +\fBPGPORT\fR +environment variable, if set, or a compiled\-in default\&. +.RE +.PP +\fB\-U \fR\fB\fIusername\fR\fR, \fB\-\-username=\fR\fB\fIusername\fR\fR +.RS 4 +User name to connect as\&. +.RE +.PP +\fB\-w\fR, \fB\-\-no\-password\fR +.RS 4 +Never issue a password prompt\&. If the server requires password authentication and a password is not available by other means such as a +\&.pgpass +file, the connection attempt will fail\&. This option can be useful in batch jobs and scripts where no user is present to enter a password\&. +.RE +.PP +\fB\-W\fR, \fB\-\-password\fR +.RS 4 +Force +pg_dumpall +to prompt for a password before connecting to a database\&. +.sp +This option is never essential, since +pg_dumpall +will automatically prompt for a password if the server demands password authentication\&. However, +pg_dumpall +will waste a connection attempt finding out that the server wants a password\&. In some cases it is worth typing +\fB\-W\fR +to avoid the extra connection attempt\&. +.sp +Note that the password prompt will occur again for each database to be dumped\&. Usually, it\*(Aqs better to set up a +~/\&.pgpass +file than to rely on manual password entry\&. +.RE +.PP +\fB\-\-role=\fR\fB\fIrolename\fR\fR +.RS 4 +Specifies a role name to be used to create the dump\&. This option causes +pg_dumpall +to issue a +\fBSET ROLE\fR +\fIrolename\fR +command after connecting to the database\&. It is useful when the authenticated user (specified by +\fB\-U\fR) lacks privileges needed by +pg_dumpall, but can switch to a role with the required rights\&. Some installations have a policy against logging in directly as a superuser, and use of this option allows dumps to be made without violating the policy\&. +.RE +.SH "ENVIRONMENT" +.PP +\fBPGHOST\fR, \fBPGOPTIONS\fR, \fBPGPORT\fR, \fBPGUSER\fR +.RS 4 +Default connection parameters +.RE +.PP +This utility, like most other +PostgreSQL +utilities, also uses the environment variables supported by +libpq +(see +Section 31.14, \(lqEnvironment Variables\(rq, in the documentation)\&. +.SH "NOTES" +.PP +Since +pg_dumpall +calls +pg_dump +internally, some diagnostic messages will refer to +pg_dump\&. +.PP +Once restored, it is wise to run +\fBANALYZE\fR +on each database so the optimizer has useful statistics\&. You can also run +\fBvacuumdb \-a \-z\fR +to analyze all databases\&. +.PP + +pg_dumpall +requires all needed tablespace directories to exist before the restore; otherwise, database creation will fail for databases in non\-default locations\&. +.SH "EXAMPLES" +.PP +To dump all databases: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_dumpall > db\&.out\fR +.fi +.if n \{\ +.RE +.\} +.PP +To reload database(s) from this file, you can use: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpsql \-f db\&.out postgres\fR +.fi +.if n \{\ +.RE +.\} +.sp +(It is not important to which database you connect here since the script file created by +pg_dumpall +will contain the appropriate commands to create and connect to the saved databases\&.) +.SH "SEE ALSO" +.PP +Check +\fBpg_dump\fR(1) +for details on possible error conditions\&. diff --git a/doc/src/sgml/man1/pg_receivexlog.1 b/doc/src/sgml/man1/pg_receivexlog.1 new file mode 100644 index 000000000..5e8114664 --- /dev/null +++ b/doc/src/sgml/man1/pg_receivexlog.1 @@ -0,0 +1,203 @@ +'\" t +.\" Title: pg_receivexlog +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "PG_RECEIVEXLOG" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +pg_receivexlog \- streams transaction logs from a PostgreSQL cluster +.\" pg_receivexlog +.SH "SYNOPSIS" +.HP \w'\fBpg_receivexlog\fR\ 'u +\fBpg_receivexlog\fR [\fIoption\fR...] +.SH "DESCRIPTION" +.PP + +pg_receivexlog +is used to stream transaction log from a running +PostgreSQL +cluster\&. The transaction log is streamed using the streaming replication protocol, and is written to a local directory of files\&. This directory can be used as the archive location for doing a restore using point\-in\-time recovery (see +Section 24.3, \(lqContinuous Archiving and Point-in-Time Recovery (PITR)\(rq, in the documentation)\&. +.PP + +pg_receivexlog +streams the transaction log in real time as it\*(Aqs being generated on the server, and does not wait for segments to complete like +archive_command +does\&. For this reason, it is not necessary to set +archive_timeout +when using +pg_receivexlog\&. +.PP +The transaction log is streamed over a regular +PostgreSQL +connection, and uses the replication protocol\&. The connection must be made with a superuser or a user having +REPLICATION +permissions (see +Section 20.2, \(lqRole Attributes\(rq, in the documentation), and +pg_hba\&.conf +must explicitly permit the replication connection\&. The server must also be configured with +max_wal_senders +set high enough to leave at least one session available for the stream\&. +.PP +If the connection is lost, or if it cannot be initially established, with a non\-fatal error, +pg_receivexlog +will retry the connection indefinitely, and reestablish streaming as soon as possible\&. To avoid this behavior, use the +\-n +parameter\&. +.SH "OPTIONS" +.PP +The following command\-line options control the location and format of the output\&. +.PP +\fB\-D \fR\fB\fIdirectory\fR\fR, \fB\-\-directory=\fR\fB\fIdirectory\fR\fR +.RS 4 +Directory to write the output to\&. +.sp +This parameter is required\&. +.RE +.PP +The following command\-line options control the running of the program\&. +.PP +\fB\-n\fR, \fB\-\-no\-loop\fR +.RS 4 +Don\*(Aqt loop on connection errors\&. Instead, exit right away with an error\&. +.RE +.PP +\fB\-v\fR, \fB\-\-verbose\fR +.RS 4 +Enables verbose mode\&. +.RE +.PP +The following command\-line options control the database connection parameters\&. +.PP +\fB\-h \fR\fB\fIhost\fR\fR, \fB\-\-host=\fR\fB\fIhost\fR\fR +.RS 4 +Specifies the host name of the machine on which the server is running\&. If the value begins with a slash, it is used as the directory for the Unix domain socket\&. The default is taken from the +\fBPGHOST\fR +environment variable, if set, else a Unix domain socket connection is attempted\&. +.RE +.PP +\fB\-p \fR\fB\fIport\fR\fR, \fB\-\-port=\fR\fB\fIport\fR\fR +.RS 4 +Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections\&. Defaults to the +\fBPGPORT\fR +environment variable, if set, or a compiled\-in default\&. +.RE +.PP +\fB\-s \fR\fB\fIinterval\fR\fR, \fB\-\-status\-interval=\fR\fB\fIinterval\fR\fR +.RS 4 +Specifies the number of seconds between status packets sent back to the server\&. This is required if replication timeout is configured on the server, and allows for easier monitoring\&. A value of zero disables the status updates completely\&. The default value is 10 seconds\&. +.RE +.PP +\fB\-U \fR\fB\fIusername\fR\fR, \fB\-\-username=\fR\fB\fIusername\fR\fR +.RS 4 +User name to connect as\&. +.RE +.PP +\fB\-w\fR, \fB\-\-no\-password\fR +.RS 4 +Never issue a password prompt\&. If the server requires password authentication and a password is not available by other means such as a +\&.pgpass +file, the connection attempt will fail\&. This option can be useful in batch jobs and scripts where no user is present to enter a password\&. +.RE +.PP +\fB\-W\fR, \fB\-\-password\fR +.RS 4 +Force +pg_receivexlog +to prompt for a password before connecting to a database\&. +.sp +This option is never essential, since +pg_receivexlog +will automatically prompt for a password if the server demands password authentication\&. However, +pg_receivexlog +will waste a connection attempt finding out that the server wants a password\&. In some cases it is worth typing +\fB\-W\fR +to avoid the extra connection attempt\&. +.RE +.PP +Other options are also available: +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +pg_receivexlog +version and exit\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +pg_receivexlog +command line arguments, and exit\&. +.RE +.SH "ENVIRONMENT" +.PP +This utility, like most other +PostgreSQL +utilities, uses the environment variables supported by +libpq +(see +Section 31.14, \(lqEnvironment Variables\(rq, in the documentation)\&. +.SH "NOTES" +.PP +When using +pg_receivexlog +instead of +archive_command, the server will continue to recycle transaction log files even if the backups are not properly archived, since there is no command that fails\&. This can be worked around by having an +archive_command +that fails when the file has not been properly archived yet, for example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +archive_command = \*(Aqsleep 5 && test \-f /mnt/server/archivedir/%f\*(Aq +.fi +.if n \{\ +.RE +.\} +.sp +The initial timeout is necessary because +pg_receivexlog +works using asynchronous replication and can therefore be slightly behind the master\&. +.SH "EXAMPLES" +.PP +To stream the transaction log from the server at +mydbserver +and store it in the local directory +/usr/local/pgsql/archive: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_receivexlog \-h mydbserver \-D /usr/local/pgsql/archive\fR +.fi +.if n \{\ +.RE +.\} +.SH "SEE ALSO" +\fBpg_basebackup\fR(1) diff --git a/doc/src/sgml/man1/pg_resetxlog.1 b/doc/src/sgml/man1/pg_resetxlog.1 new file mode 100644 index 000000000..e3a963300 --- /dev/null +++ b/doc/src/sgml/man1/pg_resetxlog.1 @@ -0,0 +1,220 @@ +'\" t +.\" Title: pg_resetxlog +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "PG_RESETXLOG" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +pg_resetxlog \- reset the write\-ahead log and other control information of a PostgreSQL database cluster +.\" pg_resetxlog +.SH "SYNOPSIS" +.HP \w'\fBpg_resetxlog\fR\ 'u +\fBpg_resetxlog\fR [\fB\-f\fR] [\fB\-n\fR] [\fB\-o\fR\ \fIoid\fR] [\fB\-x\fR\ \fIxid\fR] [\fB\-e\fR\ \fIxid_epoch\fR] [\fB\-m\fR\ \fImxid\fR] [\fB\-O\fR\ \fImxoff\fR] [\fB\-l\fR\ \fItimelineid\fR,\fIfileid\fR,\fIseg\fR] \fIdatadir\fR +.SH "DESCRIPTION" +.PP + +\fBpg_resetxlog\fR +clears the write\-ahead log (WAL) and optionally resets some other control information stored in the +pg_control +file\&. This function is sometimes needed if these files have become corrupted\&. It should be used only as a last resort, when the server will not start due to such corruption\&. +.PP +After running this command, it should be possible to start the server, but bear in mind that the database might contain inconsistent data due to partially\-committed transactions\&. You should immediately dump your data, run +\fBinitdb\fR, and reload\&. After reload, check for inconsistencies and repair as needed\&. +.PP +This utility can only be run by the user who installed the server, because it requires read/write access to the data directory\&. For safety reasons, you must specify the data directory on the command line\&. +\fBpg_resetxlog\fR +does not use the environment variable +\fBPGDATA\fR\&. +.PP +If +\fBpg_resetxlog\fR +complains that it cannot determine valid data for +pg_control, you can force it to proceed anyway by specifying the +\fB\-f\fR +(force) option\&. In this case plausible values will be substituted for the missing data\&. Most of the fields can be expected to match, but manual assistance might be needed for the next OID, next transaction ID and epoch, next multitransaction ID and offset, and WAL starting address fields\&. These fields can be set using the options discussed below\&. If you are not able to determine correct values for all these fields, +\fB\-f\fR +can still be used, but the recovered database must be treated with even more suspicion than usual: an immediate dump and reload is imperative\&. +\fIDo not\fR +execute any data\-modifying operations in the database before you dump, as any such action is likely to make the corruption worse\&. +.PP +The +\fB\-o\fR, +\fB\-x\fR, +\fB\-e\fR, +\fB\-m\fR, +\fB\-O\fR, and +\fB\-l\fR +options allow the next OID, next transaction ID, next transaction ID\*(Aqs epoch, next multitransaction ID, next multitransaction offset, and WAL starting address values to be set manually\&. These are only needed when +\fBpg_resetxlog\fR +is unable to determine appropriate values by reading +pg_control\&. Safe values can be determined as follows: +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +A safe value for the next transaction ID (\fB\-x\fR) can be determined by looking for the numerically largest file name in the directory +pg_clog +under the data directory, adding one, and then multiplying by 1048576\&. Note that the file names are in hexadecimal\&. It is usually easiest to specify the option value in hexadecimal too\&. For example, if +0011 +is the largest entry in +pg_clog, +\-x 0x1200000 +will work (five trailing zeroes provide the proper multiplier)\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +A safe value for the next multitransaction ID (\fB\-m\fR) can be determined by looking for the numerically largest file name in the directory +pg_multixact/offsets +under the data directory, adding one, and then multiplying by 65536\&. As above, the file names are in hexadecimal, so the easiest way to do this is to specify the option value in hexadecimal and add four zeroes\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +A safe value for the next multitransaction offset (\fB\-O\fR) can be determined by looking for the numerically largest file name in the directory +pg_multixact/members +under the data directory, adding one, and then multiplying by 65536\&. As above, the file names are in hexadecimal, so the easiest way to do this is to specify the option value in hexadecimal and add four zeroes\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +The WAL starting address (\fB\-l\fR) should be larger than any WAL segment file name currently existing in the directory +pg_xlog +under the data directory\&. These names are also in hexadecimal and have three parts\&. The first part is the +\(lqtimeline ID\(rq +and should usually be kept the same\&. Do not choose a value larger than 255 (0xFF) for the third part; instead increment the second part and reset the third part to 0\&. For example, if +00000001000000320000004A +is the largest entry in +pg_xlog, +\-l 0x1,0x32,0x4B +will work; but if the largest entry is +000000010000003A000000FF, choose +\-l 0x1,0x3B,0x0 +or more\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br + +\fBpg_resetxlog\fR +itself looks at the files in +pg_xlog +and chooses a default +\fB\-l\fR +setting beyond the last existing file name\&. Therefore, manual adjustment of +\fB\-l\fR +should only be needed if you are aware of WAL segment files that are not currently present in +pg_xlog, such as entries in an offline archive; or if the contents of +pg_xlog +have been lost entirely\&. +.sp .5v +.RE +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +There is no comparably easy way to determine a next OID that\*(Aqs beyond the largest one in the database, but fortunately it is not critical to get the next\-OID setting right\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +The transaction ID epoch is not actually stored anywhere in the database except in the field that is set by +\fBpg_resetxlog\fR, so any value will work so far as the database itself is concerned\&. You might need to adjust this value to ensure that replication systems such as +Slony\-I +work correctly \(em if so, an appropriate value should be obtainable from the state of the downstream replicated database\&. +.RE +.PP +The +\fB\-n\fR +(no operation) option instructs +\fBpg_resetxlog\fR +to print the values reconstructed from +pg_control +and then exit without modifying anything\&. This is mainly a debugging tool, but can be useful as a sanity check before allowing +\fBpg_resetxlog\fR +to proceed for real\&. +.PP +The +\fB\-V\fR +and +\fB\-\-version\fR +options print the +pg_resetxlog +version and exit\&. The options +\fB\-?\fR +and +\fB\-\-help\fR +show supported arguments, and exit\&. +.SH "NOTES" +.PP +This command must not be used when the server is running\&. +\fBpg_resetxlog\fR +will refuse to start up if it finds a server lock file in the data directory\&. If the server crashed then a lock file might have been left behind; in that case you can remove the lock file to allow +\fBpg_resetxlog\fR +to run\&. But before you do so, make doubly certain that there is no server process still alive\&. diff --git a/doc/src/sgml/man1/pg_restore.1 b/doc/src/sgml/man1/pg_restore.1 new file mode 100644 index 000000000..5be522d83 --- /dev/null +++ b/doc/src/sgml/man1/pg_restore.1 @@ -0,0 +1,632 @@ +'\" t +.\" Title: pg_restore +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "PG_RESTORE" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +pg_restore \- restore a PostgreSQL database from an archive file created by pg_dump +.\" pg_restore +.SH "SYNOPSIS" +.HP \w'\fBpg_restore\fR\ 'u +\fBpg_restore\fR [\fIconnection\-option\fR...] [\fIoption\fR...] [\fIfilename\fR] +.SH "DESCRIPTION" +.PP + +pg_restore +is a utility for restoring a +PostgreSQL +database from an archive created by +\fBpg_dump\fR(1) +in one of the non\-plain\-text formats\&. It will issue the commands necessary to reconstruct the database to the state it was in at the time it was saved\&. The archive files also allow +pg_restore +to be selective about what is restored, or even to reorder the items prior to being restored\&. The archive files are designed to be portable across architectures\&. +.PP + +pg_restore +can operate in two modes\&. If a database name is specified, +pg_restore +connects to that database and restores archive contents directly into the database\&. Otherwise, a script containing the SQL commands necessary to rebuild the database is created and written to a file or standard output\&. This script output is equivalent to the plain text output format of +pg_dump\&. Some of the options controlling the output are therefore analogous to +pg_dump +options\&. +.PP +Obviously, +pg_restore +cannot restore information that is not present in the archive file\&. For instance, if the archive was made using the +\(lqdump data as \fBINSERT\fR commands\(rq +option, +pg_restore +will not be able to load the data using +\fBCOPY\fR +statements\&. +.SH "OPTIONS" +.PP + +pg_restore +accepts the following command line arguments\&. +.PP +\fIfilename\fR +.RS 4 +Specifies the location of the archive file (or directory, for a directory\-format archive) to be restored\&. If not specified, the standard input is used\&. +.RE +.PP +\fB\-a\fR, \fB\-\-data\-only\fR +.RS 4 +Restore only the data, not the schema (data definitions)\&. Table data, large objects, and sequence values are restored, if present in the archive\&. +.sp +This option is similar to, but for historical reasons not identical to, specifying +\fB\-\-section=data\fR\&. +.RE +.PP +\fB\-c\fR, \fB\-\-clean\fR +.RS 4 +Clean (drop) database objects before recreating them\&. (This might generate some harmless error messages, if any objects were not present in the destination database\&.) +.RE +.PP +\fB\-C\fR, \fB\-\-create\fR +.RS 4 +Create the database before restoring into it\&. If +\fB\-\-clean\fR +is also specified, drop and recreate the target database before connecting to it\&. +.sp +When this option is used, the database named with +\fB\-d\fR +is used only to issue the initial +\fBDROP DATABASE\fR +and +\fBCREATE DATABASE\fR +commands\&. All data is restored into the database name that appears in the archive\&. +.RE +.PP +\fB\-d \fR\fB\fIdbname\fR\fR, \fB\-\-dbname=\fR\fB\fIdbname\fR\fR +.RS 4 +Connect to database +\fIdbname\fR +and restore directly into the database\&. +.RE +.PP +\fB\-e\fR, \fB\-\-exit\-on\-error\fR +.RS 4 +Exit if an error is encountered while sending SQL commands to the database\&. The default is to continue and to display a count of errors at the end of the restoration\&. +.RE +.PP +\fB\-f \fR\fB\fIfilename\fR\fR, \fB\-\-file=\fR\fB\fIfilename\fR\fR +.RS 4 +Specify output file for generated script, or for the listing when used with +\fB\-l\fR\&. Default is the standard output\&. +.RE +.PP +\fB\-F \fR\fB\fIformat\fR\fR, \fB\-\-format=\fR\fB\fIformat\fR\fR +.RS 4 +Specify format of the archive\&. It is not necessary to specify the format, since +pg_restore +will determine the format automatically\&. If specified, it can be one of the following: +.PP +c, custom +.RS 4 +The archive is in the custom format of +pg_dump\&. +.RE +.PP +d, directory +.RS 4 +The archive is a directory archive\&. +.RE +.PP +t, tar +.RS 4 +The archive is a +\fBtar\fR +archive\&. +.RE +.RE +.PP +\fB\-i\fR, \fB\-\-ignore\-version\fR +.RS 4 +A deprecated option that is now ignored\&. +.RE +.PP +\fB\-I \fR\fB\fIindex\fR\fR, \fB\-\-index=\fR\fB\fIindex\fR\fR +.RS 4 +Restore definition of named index only\&. +.RE +.PP +\fB\-j \fR\fB\fInumber\-of\-jobs\fR\fR, \fB\-\-jobs=\fR\fB\fInumber\-of\-jobs\fR\fR +.RS 4 +Run the most time\-consuming parts of +pg_restore +\(em those which load data, create indexes, or create constraints \(em using multiple concurrent jobs\&. This option can dramatically reduce the time to restore a large database to a server running on a multiprocessor machine\&. +.sp +Each job is one process or one thread, depending on the operating system, and uses a separate connection to the server\&. +.sp +The optimal value for this option depends on the hardware setup of the server, of the client, and of the network\&. Factors include the number of CPU cores and the disk setup\&. A good place to start is the number of CPU cores on the server, but values larger than that can also lead to faster restore times in many cases\&. Of course, values that are too high will lead to decreased performance because of thrashing\&. +.sp +Only the custom archive format is supported with this option\&. The input file must be a regular file (not, for example, a pipe)\&. This option is ignored when emitting a script rather than connecting directly to a database server\&. Also, multiple jobs cannot be used together with the option +\fB\-\-single\-transaction\fR\&. +.RE +.PP +\fB\-l\fR, \fB\-\-list\fR +.RS 4 +List the contents of the archive\&. The output of this operation can be used as input to the +\fB\-L\fR +option\&. Note that if filtering switches such as +\fB\-n\fR +or +\fB\-t\fR +are used with +\fB\-l\fR, they will restrict the items listed\&. +.RE +.PP +\fB\-L \fR\fB\fIlist\-file\fR\fR, \fB\-\-use\-list=\fR\fB\fIlist\-file\fR\fR +.RS 4 +Restore only those archive elements that are listed in +\fIlist\-file\fR, and restore them in the order they appear in the file\&. Note that if filtering switches such as +\fB\-n\fR +or +\fB\-t\fR +are used with +\fB\-L\fR, they will further restrict the items restored\&. +.sp +\fIlist\-file\fR +is normally created by editing the output of a previous +\fB\-l\fR +operation\&. Lines can be moved or removed, and can also be commented out by placing a semicolon (;) at the start of the line\&. See below for examples\&. +.RE +.PP +\fB\-n \fR\fB\fInamespace\fR\fR, \fB\-\-schema=\fR\fB\fIschema\fR\fR +.RS 4 +Restore only objects that are in the named schema\&. This can be combined with the +\fB\-t\fR +option to restore just a specific table\&. +.RE +.PP +\fB\-O\fR, \fB\-\-no\-owner\fR +.RS 4 +Do not output commands to set ownership of objects to match the original database\&. By default, +pg_restore +issues +\fBALTER OWNER\fR +or +\fBSET SESSION AUTHORIZATION\fR +statements to set ownership of created schema elements\&. These statements will fail unless the initial connection to the database is made by a superuser (or the same user that owns all of the objects in the script)\&. With +\fB\-O\fR, any user name can be used for the initial connection, and this user will own all the created objects\&. +.RE +.PP +\fB\-P \fR\fB\fIfunction\-name(argtype [, \&.\&.\&.])\fR\fR, \fB\-\-function=\fR\fB\fIfunction\-name(argtype [, \&.\&.\&.])\fR\fR +.RS 4 +Restore the named function only\&. Be careful to spell the function name and arguments exactly as they appear in the dump file\*(Aqs table of contents\&. +.RE +.PP +\fB\-R\fR, \fB\-\-no\-reconnect\fR +.RS 4 +This option is obsolete but still accepted for backwards compatibility\&. +.RE +.PP +\fB\-s\fR, \fB\-\-schema\-only\fR +.RS 4 +Restore only the schema (data definitions), not data, to the extent that schema entries are present in the archive\&. +.sp +This option is the inverse of +\fB\-\-data\-only\fR\&. It is similar to, but for historical reasons not identical to, specifying +\fB\-\-section=pre\-data \-\-section=post\-data\fR\&. +.sp +(Do not confuse this with the +\fB\-\-schema\fR +option, which uses the word +\(lqschema\(rq +in a different meaning\&.) +.RE +.PP +\fB\-S \fR\fB\fIusername\fR\fR, \fB\-\-superuser=\fR\fB\fIusername\fR\fR +.RS 4 +Specify the superuser user name to use when disabling triggers\&. This is only relevant if +\fB\-\-disable\-triggers\fR +is used\&. +.RE +.PP +\fB\-t \fR\fB\fItable\fR\fR, \fB\-\-table=\fR\fB\fItable\fR\fR +.RS 4 +Restore definition and/or data of named table only\&. This can be combined with the +\fB\-n\fR +option to specify a schema\&. +.RE +.PP +\fB\-T \fR\fB\fItrigger\fR\fR, \fB\-\-trigger=\fR\fB\fItrigger\fR\fR +.RS 4 +Restore named trigger only\&. +.RE +.PP +\fB\-v\fR, \fB\-\-verbose\fR +.RS 4 +Specifies verbose mode\&. +.RE +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +pg_restore +version and exit\&. +.RE +.PP +\fB\-x\fR, \fB\-\-no\-privileges\fR, \fB\-\-no\-acl\fR +.RS 4 +Prevent restoration of access privileges (grant/revoke commands)\&. +.RE +.PP +\fB\-1\fR, \fB\-\-single\-transaction\fR +.RS 4 +Execute the restore as a single transaction (that is, wrap the emitted commands in +\fBBEGIN\fR/\fBCOMMIT\fR)\&. This ensures that either all the commands complete successfully, or no changes are applied\&. This option implies +\fB\-\-exit\-on\-error\fR\&. +.RE +.PP +\fB\-\-disable\-triggers\fR +.RS 4 +This option is only relevant when performing a data\-only restore\&. It instructs +pg_restore +to execute commands to temporarily disable triggers on the target tables while the data is reloaded\&. Use this if you have referential integrity checks or other triggers on the tables that you do not want to invoke during data reload\&. +.sp +Presently, the commands emitted for +\fB\-\-disable\-triggers\fR +must be done as superuser\&. So, you should also specify a superuser name with +\fB\-S\fR, or preferably run +pg_restore +as a +PostgreSQL +superuser\&. +.RE +.PP +\fB\-\-no\-data\-for\-failed\-tables\fR +.RS 4 +By default, table data is restored even if the creation command for the table failed (e\&.g\&., because it already exists)\&. With this option, data for such a table is skipped\&. This behavior is useful if the target database already contains the desired table contents\&. For example, auxiliary tables for +PostgreSQL +extensions such as +PostGIS +might already be loaded in the target database; specifying this option prevents duplicate or obsolete data from being loaded into them\&. +.sp +This option is effective only when restoring directly into a database, not when producing SQL script output\&. +.RE +.PP +\fB\-\-no\-security\-labels\fR +.RS 4 +Do not output commands to restore security labels, even if the archive contains them\&. +.RE +.PP +\fB\-\-no\-tablespaces\fR +.RS 4 +Do not output commands to select tablespaces\&. With this option, all objects will be created in whichever tablespace is the default during restore\&. +.RE +.PP +\fB\-\-section=\fR\fB\fIsectionname\fR\fR +.RS 4 +Only restore the named section\&. The section name can be +\fBpre\-data\fR, +\fBdata\fR, or +\fBpost\-data\fR\&. This option can be specified more than once to select multiple sections\&. The default is to restore all sections\&. +.sp +The data section contains actual table data as well as large\-object definitions\&. Post\-data items consist of definitions of indexes, triggers, rules and constraints other than validated check constraints\&. Pre\-data items consist of all other data definition items\&. +.RE +.PP +\fB\-\-use\-set\-session\-authorization\fR +.RS 4 +Output SQL\-standard +\fBSET SESSION AUTHORIZATION\fR +commands instead of +\fBALTER OWNER\fR +commands to determine object ownership\&. This makes the dump more standards\-compatible, but depending on the history of the objects in the dump, might not restore properly\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +pg_restore +command line arguments, and exit\&. +.RE +.PP + +pg_restore +also accepts the following command line arguments for connection parameters: +.PP +\fB\-h \fR\fB\fIhost\fR\fR, \fB\-\-host=\fR\fB\fIhost\fR\fR +.RS 4 +Specifies the host name of the machine on which the server is running\&. If the value begins with a slash, it is used as the directory for the Unix domain socket\&. The default is taken from the +\fBPGHOST\fR +environment variable, if set, else a Unix domain socket connection is attempted\&. +.RE +.PP +\fB\-p \fR\fB\fIport\fR\fR, \fB\-\-port=\fR\fB\fIport\fR\fR +.RS 4 +Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections\&. Defaults to the +\fBPGPORT\fR +environment variable, if set, or a compiled\-in default\&. +.RE +.PP +\fB\-U \fR\fB\fIusername\fR\fR, \fB\-\-username=\fR\fB\fIusername\fR\fR +.RS 4 +User name to connect as\&. +.RE +.PP +\fB\-w\fR, \fB\-\-no\-password\fR +.RS 4 +Never issue a password prompt\&. If the server requires password authentication and a password is not available by other means such as a +\&.pgpass +file, the connection attempt will fail\&. This option can be useful in batch jobs and scripts where no user is present to enter a password\&. +.RE +.PP +\fB\-W\fR, \fB\-\-password\fR +.RS 4 +Force +pg_restore +to prompt for a password before connecting to a database\&. +.sp +This option is never essential, since +pg_restore +will automatically prompt for a password if the server demands password authentication\&. However, +pg_restore +will waste a connection attempt finding out that the server wants a password\&. In some cases it is worth typing +\fB\-W\fR +to avoid the extra connection attempt\&. +.RE +.PP +\fB\-\-role=\fR\fB\fIrolename\fR\fR +.RS 4 +Specifies a role name to be used to perform the restore\&. This option causes +pg_restore +to issue a +\fBSET ROLE\fR +\fIrolename\fR +command after connecting to the database\&. It is useful when the authenticated user (specified by +\fB\-U\fR) lacks privileges needed by +pg_restore, but can switch to a role with the required rights\&. Some installations have a policy against logging in directly as a superuser, and use of this option allows restores to be performed without violating the policy\&. +.RE +.SH "ENVIRONMENT" +.PP +\fBPGHOST\fR, \fBPGOPTIONS\fR, \fBPGPORT\fR, \fBPGUSER\fR +.RS 4 +Default connection parameters +.RE +.PP +This utility, like most other +PostgreSQL +utilities, also uses the environment variables supported by +libpq +(see +Section 31.14, \(lqEnvironment Variables\(rq, in the documentation)\&. +.SH "DIAGNOSTICS" +.PP +When a direct database connection is specified using the +\fB\-d\fR +option, +pg_restore +internally executes +SQL +statements\&. If you have problems running +pg_restore, make sure you are able to select information from the database using, for example, +\fBpsql\fR(1)\&. Also, any default connection settings and environment variables used by the +libpq +front\-end library will apply\&. +.SH "NOTES" +.PP +If your installation has any local additions to the +template1 +database, be careful to load the output of +pg_restore +into a truly empty database; otherwise you are likely to get errors due to duplicate definitions of the added objects\&. To make an empty database without any local additions, copy from +template0 +not +template1, for example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE DATABASE foo WITH TEMPLATE template0; +.fi +.if n \{\ +.RE +.\} +.PP +The limitations of +pg_restore +are detailed below\&. +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +When restoring data to a pre\-existing table and the option +\fB\-\-disable\-triggers\fR +is used, +pg_restore +emits commands to disable triggers on user tables before inserting the data, then emits commands to re\-enable them after the data has been inserted\&. If the restore is stopped in the middle, the system catalogs might be left in the wrong state\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +pg_restore +cannot restore large objects selectively; for instance, only those for a specific table\&. If an archive contains large objects, then all large objects will be restored, or none of them if they are excluded via +\fB\-L\fR, +\fB\-t\fR, or other options\&. +.RE +.PP +See also the +\fBpg_dump\fR(1) +documentation for details on limitations of +pg_dump\&. +.PP +Once restored, it is wise to run +\fBANALYZE\fR +on each restored table so the optimizer has useful statistics; see +Section 23.1.3, \(lqUpdating Planner Statistics\(rq, in the documentation +and +Section 23.1.6, \(lqThe Autovacuum Daemon\(rq, in the documentation +for more information\&. +.SH "EXAMPLES" +.PP +Assume we have dumped a database called +mydb +into a custom\-format dump file: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_dump \-Fc mydb > db\&.dump\fR +.fi +.if n \{\ +.RE +.\} +.PP +To drop the database and recreate it from the dump: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBdropdb mydb\fR +$ \fBpg_restore \-C \-d postgres db\&.dump\fR +.fi +.if n \{\ +.RE +.\} +.sp +The database named in the +\fB\-d\fR +switch can be any database existing in the cluster; +pg_restore +only uses it to issue the +\fBCREATE DATABASE\fR +command for +mydb\&. With +\fB\-C\fR, data is always restored into the database name that appears in the dump file\&. +.PP +To reload the dump into a new database called +newdb: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBcreatedb \-T template0 newdb\fR +$ \fBpg_restore \-d newdb db\&.dump\fR +.fi +.if n \{\ +.RE +.\} +.sp +Notice we don\*(Aqt use +\fB\-C\fR, and instead connect directly to the database to be restored into\&. Also note that we clone the new database from +template0 +not +template1, to ensure it is initially empty\&. +.PP +To reorder database items, it is first necessary to dump the table of contents of the archive: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_restore \-l db\&.dump > db\&.list\fR +.fi +.if n \{\ +.RE +.\} +.sp +The listing file consists of a header and one line for each item, e\&.g\&.: +.sp +.if n \{\ +.RS 4 +.\} +.nf +; +; Archive created at Mon Sep 14 13:55:39 2009 +; dbname: DBDEMOS +; TOC Entries: 81 +; Compression: 9 +; Dump Version: 1\&.10\-0 +; Format: CUSTOM +; Integer: 4 bytes +; Offset: 8 bytes +; Dumped from database version: 8\&.3\&.5 +; Dumped by pg_dump version: 8\&.3\&.8 +; +; +; Selected TOC Entries: +; +3; 2615 2200 SCHEMA \- public pasha +1861; 0 0 COMMENT \- SCHEMA public pasha +1862; 0 0 ACL \- public pasha +317; 1247 17715 TYPE public composite pasha +319; 1247 25899 DOMAIN public domain0 pasha +.fi +.if n \{\ +.RE +.\} +.sp +Semicolons start a comment, and the numbers at the start of lines refer to the internal archive ID assigned to each item\&. +.PP +Lines in the file can be commented out, deleted, and reordered\&. For example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +10; 145433 TABLE map_resolutions postgres +;2; 145344 TABLE species postgres +;4; 145359 TABLE nt_header postgres +6; 145402 TABLE species_records postgres +;8; 145416 TABLE ss_old postgres +.fi +.if n \{\ +.RE +.\} +.sp +could be used as input to +pg_restore +and would only restore items 10 and 6, in that order: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpg_restore \-L db\&.list db\&.dump\fR +.fi +.if n \{\ +.RE +.\} +.SH "SEE ALSO" +\fBpg_dump\fR(1), \fBpg_dumpall\fR(1), \fBpsql\fR(1) diff --git a/doc/src/sgml/man1/pg_standby.1 b/doc/src/sgml/man1/pg_standby.1 new file mode 100644 index 000000000..20599c64f --- /dev/null +++ b/doc/src/sgml/man1/pg_standby.1 @@ -0,0 +1,414 @@ +'\" t +.\" Title: pg_standby +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "PG_STANDBY" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +pg_standby \- supports the creation of a PostgreSQL warm standby server +.\" pg_standby +.SH "SYNOPSIS" +.HP \w'\fBpg_standby\fR\ 'u +\fBpg_standby\fR [\fIoption\fR...] \fIarchivelocation\fR \fInextwalfile\fR \fIxlogfilepath\fR [\fIrestartwalfile\fR] +.SH "DESCRIPTION" +.PP + +pg_standby +supports creation of a +\(lqwarm standby\(rq +database server\&. It is designed to be a production\-ready program, as well as a customizable template should you require specific modifications\&. +.PP + +pg_standby +is designed to be a waiting +\fIrestore_command\fR, which is needed to turn a standard archive recovery into a warm standby operation\&. Other configuration is required as well, all of which is described in the main server manual (see +Section 25.2, \(lqLog-Shipping Standby Servers\(rq, in the documentation)\&. +.PP +To configure a standby server to use +pg_standby, put this into its +recovery\&.conf +configuration file: +.sp +.if n \{\ +.RS 4 +.\} +.nf +restore_command = \*(Aqpg_standby \fIarchiveDir\fR %f %p %r\*(Aq +.fi +.if n \{\ +.RE +.\} +.sp +where +\fIarchiveDir\fR +is the directory from which WAL segment files should be restored\&. +.PP +If +\fIrestartwalfile\fR +is specified, normally by using the +%r +macro, then all WAL files logically preceding this file will be removed from +\fIarchivelocation\fR\&. This minimizes the number of files that need to be retained, while preserving crash\-restart capability\&. Use of this parameter is appropriate if the +\fIarchivelocation\fR +is a transient staging area for this particular standby server, but +\fInot\fR +when the +\fIarchivelocation\fR +is intended as a long\-term WAL archive area\&. +.PP + +pg_standby +assumes that +\fIarchivelocation\fR +is a directory readable by the server\-owning user\&. If +\fIrestartwalfile\fR +(or +\-k) is specified, the +\fIarchivelocation\fR +directory must be writable too\&. +.PP +There are two ways to fail over to a +\(lqwarm standby\(rq +database server when the master server fails: +.PP +Smart Failover +.RS 4 +In smart failover, the server is brought up after applying all WAL files available in the archive\&. This results in zero data loss, even if the standby server has fallen behind, but if there is a lot of unapplied WAL it can be a long time before the standby server becomes ready\&. To trigger a smart failover, create a trigger file containing the word +smart, or just create it and leave it empty\&. +.RE +.PP +Fast Failover +.RS 4 +In fast failover, the server is brought up immediately\&. Any WAL files in the archive that have not yet been applied will be ignored, and all transactions in those files are lost\&. To trigger a fast failover, create a trigger file and write the word +fast +into it\&. +pg_standby +can also be configured to execute a fast failover automatically if no new WAL file appears within a defined interval\&. +.RE +.SH "OPTIONS" +.PP + +pg_standby +accepts the following command\-line arguments: +.PP +\fB\-c\fR +.RS 4 +Use +cp +or +copy +command to restore WAL files from archive\&. This is the only supported behavior so this option is useless\&. +.RE +.PP +\fB\-d\fR +.RS 4 +Print lots of debug logging output on +stderr\&. +.RE +.PP +\fB\-k\fR +.RS 4 +Remove files from +\fIarchivelocation\fR +so that no more than this many WAL files before the current one are kept in the archive\&. Zero (the default) means not to remove any files from +\fIarchivelocation\fR\&. This parameter will be silently ignored if +\fIrestartwalfile\fR +is specified, since that specification method is more accurate in determining the correct archive cut\-off point\&. Use of this parameter is +\fIdeprecated\fR +as of +PostgreSQL +8\&.3; it is safer and more efficient to specify a +\fIrestartwalfile\fR +parameter\&. A too small setting could result in removal of files that are still needed for a restart of the standby server, while a too large setting wastes archive space\&. +.RE +.PP +\fB\-r\fR \fImaxretries\fR +.RS 4 +Set the maximum number of times to retry the copy command if it fails (default 3)\&. After each failure, we wait for +\fIsleeptime\fR +* +\fInum_retries\fR +so that the wait time increases progressively\&. So by default, we will wait 5 secs, 10 secs, then 15 secs before reporting the failure back to the standby server\&. This will be interpreted as end of recovery and the standby will come up fully as a result\&. +.RE +.PP +\fB\-s\fR \fIsleeptime\fR +.RS 4 +Set the number of seconds (up to 60, default 5) to sleep between tests to see if the WAL file to be restored is available in the archive yet\&. The default setting is not necessarily recommended; consult +Section 25.2, \(lqLog-Shipping Standby Servers\(rq, in the documentation +for discussion\&. +.RE +.PP +\fB\-t\fR \fItriggerfile\fR +.RS 4 +Specify a trigger file whose presence should cause failover\&. It is recommended that you use a structured file name to avoid confusion as to which server is being triggered when multiple servers exist on the same system; for example +/tmp/pgsql\&.trigger\&.5432\&. +.RE +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +pg_standby +version and exit\&. +.RE +.PP +\fB\-w\fR \fImaxwaittime\fR +.RS 4 +Set the maximum number of seconds to wait for the next WAL file, after which a fast failover will be performed\&. A setting of zero (the default) means wait forever\&. The default setting is not necessarily recommended; consult +Section 25.2, \(lqLog-Shipping Standby Servers\(rq, in the documentation +for discussion\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +pg_standby +command line arguments, and exit\&. +.RE +.SH "NOTES" +.PP + +pg_standby +is designed to work with +PostgreSQL +8\&.2 and later\&. +.PP + +PostgreSQL +8\&.3 provides the +%r +macro, which is designed to let +pg_standby +know the last file it needs to keep\&. With +PostgreSQL +8\&.2, the +\-k +option must be used if archive cleanup is required\&. This option remains available in 8\&.3, but its use is deprecated\&. +.PP + +PostgreSQL +8\&.4 provides the +\fIrecovery_end_command\fR +option\&. Without this option a leftover trigger file can be hazardous\&. +.PP + +pg_standby +is written in C and has an easy\-to\-modify source code, with specifically designated sections to modify for your own needs +.SH "EXAMPLES" +.PP +On Linux or Unix systems, you might use: +.sp +.if n \{\ +.RS 4 +.\} +.nf +archive_command = \*(Aqcp %p \&.\&.\&./archive/%f\*(Aq + +restore_command = \*(Aqpg_standby \-d \-s 2 \-t /tmp/pgsql\&.trigger\&.5442 \&.\&.\&./archive %f %p %r 2>>standby\&.log\*(Aq + +recovery_end_command = \*(Aqrm \-f /tmp/pgsql\&.trigger\&.5442\*(Aq +.fi +.if n \{\ +.RE +.\} +.sp +where the archive directory is physically located on the standby server, so that the +\fIarchive_command\fR +is accessing it across NFS, but the files are local to the standby (enabling use of +ln)\&. This will: +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +produce debugging output in +standby\&.log +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +sleep for 2 seconds between checks for next WAL file availability +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +stop waiting only when a trigger file called +/tmp/pgsql\&.trigger\&.5442 +appears, and perform failover according to its content +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +remove the trigger file when recovery ends +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +remove no\-longer\-needed files from the archive directory +.RE +.PP +On Windows, you might use: +.sp +.if n \{\ +.RS 4 +.\} +.nf +archive_command = \*(Aqcopy %p \&.\&.\&.\e\earchive\e\e%f\*(Aq + +restore_command = \*(Aqpg_standby \-d \-s 5 \-t C:\epgsql\&.trigger\&.5442 \&.\&.\&.\earchive %f %p %r 2>>standby\&.log\*(Aq + +recovery_end_command = \*(Aqdel C:\epgsql\&.trigger\&.5442\*(Aq +.fi +.if n \{\ +.RE +.\} +.sp +Note that backslashes need to be doubled in the +\fIarchive_command\fR, but +\fInot\fR +in the +\fIrestore_command\fR +or +\fIrecovery_end_command\fR\&. This will: +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +use the +copy +command to restore WAL files from archive +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +produce debugging output in +standby\&.log +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +sleep for 5 seconds between checks for next WAL file availability +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +stop waiting only when a trigger file called +C:\epgsql\&.trigger\&.5442 +appears, and perform failover according to its content +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +remove the trigger file when recovery ends +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +remove no\-longer\-needed files from the archive directory +.RE +.PP +The +copy +command on Windows sets the final file size before the file is completely copied, which would ordinarily confuse +pg_standby\&. Therefore +pg_standby +waits +sleeptime +seconds once it sees the proper file size\&. GNUWin32\*(Aqs +cp +sets the file size only after the file copy is complete\&. +.PP +Since the Windows example uses +copy +at both ends, either or both servers might be accessing the archive directory across the network\&. +.SH "AUTHOR" +.PP +Simon Riggs + +.SH "SEE ALSO" +\fBpg_archivecleanup\fR(1) diff --git a/doc/src/sgml/man1/pg_test_fsync.1 b/doc/src/sgml/man1/pg_test_fsync.1 new file mode 100644 index 000000000..c0f9caf6e --- /dev/null +++ b/doc/src/sgml/man1/pg_test_fsync.1 @@ -0,0 +1,86 @@ +'\" t +.\" Title: pg_test_fsync +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "PG_TEST_FSYNC" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +pg_test_fsync \- determine fastest wal_sync_method for PostgreSQL +.\" pg_test_fsync +.SH "SYNOPSIS" +.HP \w'\fBpg_test_fsync\fR\ 'u +\fBpg_test_fsync\fR [\fIoption\fR...] +.SH "DESCRIPTION" +.PP + +pg_test_fsync +is intended to give you a reasonable idea of what the fastest +wal_sync_method +is on your specific system, as well as supplying diagnostic information in the event of an identified I/O problem\&. However, differences shown by +pg_test_fsync +might not make any difference in real database throughput, especially since many database servers are not speed\-limited by their transaction logs\&. +.SH "OPTIONS" +.PP + +pg_test_fsync +accepts the following command\-line options: +.PP +\fB\-f\fR, \fB\-\-filename\fR +.RS 4 +Specifies the file name to write test data in\&. This file should be in the same file system that the +pg_xlog +directory is or will be placed in\&. (pg_xlog +contains the +WAL +files\&.) The default is +pg_test_fsync\&.out +in the current directory\&. +.RE +.PP +\fB\-s\fR, \fB\-\-secs\-per\-test\fR +.RS 4 +Specifies the number of seconds for each test\&. The more time per test, the greater the test\*(Aqs accuracy, but the longer it takes to run\&. The default is 2 seconds, which allows the program to complete in about 30 seconds\&. +.RE +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +pg_test_fsync +version and exit\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +pg_test_fsync +command line arguments, and exit\&. +.RE +.SH "AUTHOR" +.PP +Bruce Momjian + +.SH "SEE ALSO" +\fBpostgres\fR(1) diff --git a/doc/src/sgml/man1/pg_test_timing.1 b/doc/src/sgml/man1/pg_test_timing.1 new file mode 100644 index 000000000..e368bc965 --- /dev/null +++ b/doc/src/sgml/man1/pg_test_timing.1 @@ -0,0 +1,204 @@ +'\" t +.\" Title: pg_test_timing +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "PG_TEST_TIMING" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +pg_test_timing \- measure timing overhead +.\" pg_test_timing +.SH "SYNOPSIS" +.HP \w'\fBpg_test_timing\fR\ 'u +\fBpg_test_timing\fR [\fIoption\fR...] +.SH "DESCRIPTION" +.PP + +pg_test_timing +is a tool to measure the timing overhead on your system and confirm that the system time never moves backwards\&. Systems that are slow to collect timing data can give less accurate +\fBEXPLAIN ANALYZE\fR +results\&. +.SH "OPTIONS" +.PP + +pg_test_timing +accepts the following command\-line options: +.PP +\fB\-d \fR\fB\fIduration\fR\fR, \fB\-\-duration=\fR\fB\fIduration\fR\fR +.RS 4 +Specifies the test duration, in seconds\&. Longer durations give slightly better accuracy, and are more likely to discover problems with the system clock moving backwards\&. The default test duration is 3 seconds\&. +.RE +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +pg_test_timing +version and exit\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +pg_test_timing +command line arguments, and exit\&. +.RE +.SH "USAGE" +.SS "Interpreting results" +.PP +Good results will show most (>90%) individual timing calls take less than one microsecond\&. Average per loop overhead will be even lower, below 100 nanoseconds\&. This example from an Intel i7\-860 system using a TSC clock source shows excellent performance: +.sp +.if n \{\ +.RS 4 +.\} +.nf +Testing timing overhead for 3 seconds\&. +Per loop time including overhead: 35\&.96 nsec +Histogram of timing durations: + < usec: count percent + 16: 2 0\&.00000% + 8: 13 0\&.00002% + 4: 126 0\&.00015% + 2: 2999652 3\&.59518% + 1: 80435604 96\&.40465% +.fi +.if n \{\ +.RE +.\} +.PP +Note that different units are used for the per loop time than the histogram\&. The loop can have resolution within a few nanoseconds (nsec), while the individual timing calls can only resolve down to one microsecond (usec)\&. +.SS "Measuring executor timing overhead" +.PP +When the query executor is running a statement using +\fBEXPLAIN ANALYZE\fR, individual operations are timed as well as showing a summary\&. The overhead of your system can be checked by counting rows with the +psql +program: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TABLE t AS SELECT * FROM generate_series(1,100000); +\etiming +SELECT COUNT(*) FROM t; +EXPLAIN ANALYZE SELECT COUNT(*) FROM t; +.fi +.if n \{\ +.RE +.\} +.PP +The i7\-860 system measured runs the count query in 9\&.8 ms while the +\fBEXPLAIN ANALYZE\fR +version takes 16\&.6 ms, each processing just over 100,000 rows\&. That 6\&.8 ms difference means the timing overhead per row is 68 ns, about twice what pg_test_timing estimated it would be\&. Even that relatively small amount of overhead is making the fully timed count statement take almost 70% longer\&. On more substantial queries, the timing overhead would be less problematic\&. +.SS "Changing time sources" +.PP +On some newer Linux systems, it\*(Aqs possible to change the clock source used to collect timing data at any time\&. A second example shows the slowdown possible from switching to the slower acpi_pm time source, on the same system used for the fast results above: +.sp +.if n \{\ +.RS 4 +.\} +.nf +# cat /sys/devices/system/clocksource/clocksource0/available_clocksource +tsc hpet acpi_pm +# echo acpi_pm > /sys/devices/system/clocksource/clocksource0/current_clocksource +# pg_test_timing +Per loop time including overhead: 722\&.92 nsec +Histogram of timing durations: + < usec: count percent + 16: 3 0\&.00007% + 8: 563 0\&.01357% + 4: 3241 0\&.07810% + 2: 2990371 72\&.05956% + 1: 1155682 27\&.84870% +.fi +.if n \{\ +.RE +.\} +.PP +In this configuration, the sample +\fBEXPLAIN ANALYZE\fR +above takes 115\&.9 ms\&. That\*(Aqs 1061 nsec of timing overhead, again a small multiple of what\*(Aqs measured directly by this utility\&. That much timing overhead means the actual query itself is only taking a tiny fraction of the accounted for time, most of it is being consumed in overhead instead\&. In this configuration, any +\fBEXPLAIN ANALYZE\fR +totals involving many timed operations would be inflated significantly by timing overhead\&. +.PP +FreeBSD also allows changing the time source on the fly, and it logs information about the timer selected during boot: +.sp +.if n \{\ +.RS 4 +.\} +.nf +dmesg | grep "Timecounter" +sysctl kern\&.timecounter\&.hardware=TSC +.fi +.if n \{\ +.RE +.\} +.PP +Other systems may only allow setting the time source on boot\&. On older Linux systems the "clock" kernel setting is the only way to make this sort of change\&. And even on some more recent ones, the only option you\*(Aqll see for a clock source is "jiffies"\&. Jiffies are the older Linux software clock implementation, which can have good resolution when it\*(Aqs backed by fast enough timing hardware, as in this example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ cat /sys/devices/system/clocksource/clocksource0/available_clocksource +jiffies +$ dmesg | grep time\&.c +time\&.c: Using 3\&.579545 MHz WALL PM GTOD PIT/TSC timer\&. +time\&.c: Detected 2400\&.153 MHz processor\&. +$ pg_test_timing +Testing timing overhead for 3 seconds\&. +Per timing duration including loop overhead: 97\&.75 ns +Histogram of timing durations: + < usec: count percent + 32: 1 0\&.00000% + 16: 1 0\&.00000% + 8: 22 0\&.00007% + 4: 3010 0\&.00981% + 2: 2993204 9\&.75277% + 1: 27694571 90\&.23734% +.fi +.if n \{\ +.RE +.\} +.SS "Clock hardware and timing accuracy" +.PP +Collecting accurate timing information is normally done on computers using hardware clocks with various levels of accuracy\&. With some hardware the operating systems can pass the system clock time almost directly to programs\&. A system clock can also be derived from a chip that simply provides timing interrupts, periodic ticks at some known time interval\&. In either case, operating system kernels provide a clock source that hides these details\&. But the accuracy of that clock source and how quickly it can return results varies based on the underlying hardware\&. +.PP +Inaccurate time keeping can result in system instability\&. Test any change to the clock source very carefully\&. Operating system defaults are sometimes made to favor reliability over best accuracy\&. And if you are using a virtual machine, look into the recommended time sources compatible with it\&. Virtual hardware faces additional difficulties when emulating timers, and there are often per operating system settings suggested by vendors\&. +.PP +The Time Stamp Counter (TSC) clock source is the most accurate one available on current generation CPUs\&. It\*(Aqs the preferred way to track the system time when it\*(Aqs supported by the operating system and the TSC clock is reliable\&. There are several ways that TSC can fail to provide an accurate timing source, making it unreliable\&. Older systems can have a TSC clock that varies based on the CPU temperature, making it unusable for timing\&. Trying to use TSC on some older multicore CPUs can give a reported time that\*(Aqs inconsistent among multiple cores\&. This can result in the time going backwards, a problem this program checks for\&. And even the newest systems can fail to provide accurate TSC timing with very aggressive power saving configurations\&. +.PP +Newer operating systems may check for the known TSC problems and switch to a slower, more stable clock source when they are seen\&. If your system supports TSC time but doesn\*(Aqt default to that, it may be disabled for a good reason\&. And some operating systems may not detect all the possible problems correctly, or will allow using TSC even in situations where it\*(Aqs known to be inaccurate\&. +.PP +The High Precision Event Timer (HPET) is the preferred timer on systems where it\*(Aqs available and TSC is not accurate\&. The timer chip itself is programmable to allow up to 100 nanosecond resolution, but you may not see that much accuracy in your system clock\&. +.PP +Advanced Configuration and Power Interface (ACPI) provides a Power Management (PM) Timer, which Linux refers to as the acpi_pm\&. The clock derived from acpi_pm will at best provide 300 nanosecond resolution\&. +.PP +Timers used on older PC hardware including the 8254 Programmable Interval Timer (PIT), the real\-time clock (RTC), the Advanced Programmable Interrupt Controller (APIC) timer, and the Cyclone timer\&. These timers aim for millisecond resolution\&. +.SH "AUTHOR" +.PP +Ants Aasma + +.SH "SEE ALSO" +\fBEXPLAIN\fR(7) diff --git a/doc/src/sgml/man1/pg_upgrade.1 b/doc/src/sgml/man1/pg_upgrade.1 new file mode 100644 index 000000000..dfdfe6403 --- /dev/null +++ b/doc/src/sgml/man1/pg_upgrade.1 @@ -0,0 +1,684 @@ +'\" t +.\" Title: pg_upgrade +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "PG_UPGRADE" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +pg_upgrade \- upgrade a PostgreSQL server instance +.\" pg_upgrade +.SH "SYNOPSIS" +.HP \w'\fBpg_upgrade\fR\ 'u +\fBpg_upgrade\fR \fB\-b\fR \fIoldbindir\fR \fB\-B\fR \fInewbindir\fR \fB\-d\fR \fIolddatadir\fR \fB\-D\fR \fInewdatadir\fR [\fIoption\fR...] +.SH "DESCRIPTION" +.PP + +pg_upgrade +(formerly called +pg_migrator) allows data stored in +PostgreSQL +data files to be upgraded to a later +PostgreSQL +major version without the data dump/reload typically required for major version upgrades, e\&.g\&. from 8\&.4\&.7 to the current major release of +PostgreSQL\&. It is not required for minor version upgrades, e\&.g\&. from 9\&.0\&.1 to 9\&.0\&.4\&. +.PP +Major PostgreSQL releases regularly add new features that often change the layout of the system tables, but the internal data storage format rarely changes\&. +pg_upgrade +uses this fact to perform rapid upgrades by creating new system tables and simply reusing the old user data files\&. If a future major release ever changes the data storage format in a way that makes the old data format unreadable, +pg_upgrade +will not be usable for such upgrades\&. (The community will attempt to avoid such situations\&.) +.PP + +pg_upgrade +does its best to make sure the old and new clusters are binary\-compatible, e\&.g\&. by checking for compatible compile\-time settings, including 32/64\-bit binaries\&. It is important that any external modules are also binary compatible, though this cannot be checked by +pg_upgrade\&. +.PP +pg_upgrade supports upgrades from 8\&.3\&.X and later to the current major release of +PostgreSQL, including snapshot and alpha releases\&. +.SH "OPTIONS" +.PP + +pg_upgrade +accepts the following command\-line arguments: +.PP +\fB\-b\fR \fIold_bindir\fR, \fB\-\-old\-bindir=\fR\fIold_bindir\fR +.RS 4 +the old cluster executable directory; environment variable +\fBPGBINOLD\fR +.RE +.PP +\fB\-B\fR \fInew_bindir\fR, \fB\-\-new\-bindir=\fR\fInew_bindir\fR +.RS 4 +the new cluster executable directory; environment variable +\fBPGBINNEW\fR +.RE +.PP +\fB\-c\fR, \fB\-\-check\fR +.RS 4 +check clusters only, don\*(Aqt change any data +.RE +.PP +\fB\-d\fR \fIold_datadir\fR, \fB\-\-old\-datadir=\fR\fIold_datadir\fR +.RS 4 +the old cluster data directory; environment variable +\fBPGDATAOLD\fR +.RE +.PP +\fB\-D\fR \fInew_datadir\fR, \fB\-\-new\-datadir=\fR\fInew_datadir\fR +.RS 4 +the new cluster data directory; environment variable +\fBPGDATANEW\fR +.RE +.PP +\fB\-k\fR, \fB\-\-link\fR +.RS 4 +use hard links instead of copying files to the new cluster +.RE +.PP +\fB\-o\fR \fIoptions\fR, \fB\-\-old\-options\fR \fIoptions\fR +.RS 4 +options to be passed directly to the old +\fBpostgres\fR +command +.RE +.PP +\fB\-O\fR \fIoptions\fR, \fB\-\-new\-options\fR \fIoptions\fR +.RS 4 +options to be passed directly to the new +\fBpostgres\fR +command +.RE +.PP +\fB\-p\fR \fIold_port_number\fR, \fB\-\-old\-port=\fR\fIold_portnum\fR +.RS 4 +the old cluster port number; environment variable +\fBPGPORTOLD\fR +.RE +.PP +\fB\-P\fR \fInew_port_number\fR, \fB\-\-new\-port=\fR\fInew_portnum\fR +.RS 4 +the new cluster port number; environment variable +\fBPGPORTNEW\fR +.RE +.PP +\fB\-r\fR, \fB\-\-retain\fR +.RS 4 +retain SQL and log files even after successful completion +.RE +.PP +\fB\-u\fR \fIuser_name\fR, \fB\-\-user=\fR\fIuser_name\fR +.RS 4 +cluster\*(Aqs super user name; environment variable +\fBPGUSER\fR +.RE +.PP +\fB\-v\fR, \fB\-\-verbose\fR +.RS 4 +enable verbose internal logging +.RE +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +display version information, then exit +.RE +.PP +\fB\-?\fR, \fB\-h\fR, \fB\-\-help\fR +.RS 4 +show help, then exit +.RE +.SH "USAGE" +.PP +These are the steps to perform an upgrade with +pg_upgrade: +.sp +.RS 4 +.ie n \{\ +\h'-04' 1.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 1." 4.2 +.\} +Optionally move the old cluster: If you are using a version\-specific installation directory, e\&.g\&. +/opt/PostgreSQL/9\&.1, you do not need to move the old cluster\&. The one\-click installers all use version\-specific installation directories\&. +.sp +If your installation directory is not version\-specific, e\&.g\&. +/usr/local/pgsql, it is necessary to move the current PostgreSQL install directory so it does not interfere with the new +PostgreSQL +installation\&. Once the current +PostgreSQL +server is shut down, it is safe to rename the PostgreSQL installation directory; assuming the old directory is +/usr/local/pgsql, you can do: +.sp +.if n \{\ +.RS 4 +.\} +.nf +mv /usr/local/pgsql /usr/local/pgsql\&.old +.fi +.if n \{\ +.RE +.\} +.sp +to rename the directory\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 2.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 2." 4.2 +.\} +For source installs, build the new version: Build the new PostgreSQL source with +\fBconfigure\fR +flags that are compatible with the old cluster\&. +pg_upgrade +will check +\fBpg_controldata\fR +to make sure all settings are compatible before starting the upgrade\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 3.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 3." 4.2 +.\} +Install the new PostgreSQL binaries: Install the new server\*(Aqs binaries and support files\&. +.sp +For source installs, if you wish to install the new server in a custom location, use the +prefix +variable: +.sp +.if n \{\ +.RS 4 +.\} +.nf +gmake prefix=/usr/local/pgsql\&.new install +.fi +.if n \{\ +.RE +.\} +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 4.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 4." 4.2 +.\} +Install pg_upgrade and pg_upgrade_support: Install the +pg_upgrade +binary and +pg_upgrade_support +library in the new PostgreSQL cluster\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 5.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 5." 4.2 +.\} +Initialize the new PostgreSQL cluster: Initialize the new cluster using +\fBinitdb\fR\&. Again, use compatible +\fBinitdb\fR +flags that match the old cluster\&. Many prebuilt installers do this step automatically\&. There is no need to start the new cluster\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 6.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 6." 4.2 +.\} +Install custom shared object files: Install any custom shared object files (or DLLs) used by the old cluster into the new cluster, e\&.g\&. +pgcrypto\&.so, whether they are from +contrib +or some other source\&. Do not install the schema definitions, e\&.g\&. +pgcrypto\&.sql, because these will be upgraded from the old cluster\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 7.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 7." 4.2 +.\} +Adjust authentication: +\fBpg_upgrade\fR +will connect to the old and new servers several times, so you might want to set authentication to +trust +in +pg_hba\&.conf, or if using +md5 +authentication, use a +~/\&.pgpass +file (see +Section 31.15, \(lqThe Password File\(rq, in the documentation) to avoid being prompted repeatedly for a password\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 8.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 8." 4.2 +.\} +Stop both servers: Make sure both database servers are stopped using, on Unix, e\&.g\&.: +.sp +.if n \{\ +.RS 4 +.\} +.nf +pg_ctl \-D /opt/PostgreSQL/8\&.4 stop +pg_ctl \-D /opt/PostgreSQL/9\&.0 stop +.fi +.if n \{\ +.RE +.\} +.sp +or on Windows, using the proper service names: +.sp +.if n \{\ +.RS 4 +.\} +.nf +NET STOP postgresql\-8\&.4 +NET STOP postgresql\-9\&.0 +.fi +.if n \{\ +.RE +.\} +.sp +or +.sp +.if n \{\ +.RS 4 +.\} +.nf +NET STOP pgsql\-8\&.3 (PostgreSQL 8\&.3 and older used a different service name) +.fi +.if n \{\ +.RE +.\} +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 9.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 9." 4.2 +.\} +Run pg_upgrade: Always run the +pg_upgrade +binary of the new server, not the old one\&. +pg_upgrade +requires the specification of the old and new cluster\*(Aqs data and executable (bin) directories\&. You can also specify user and port values, and whether you want the data linked instead of copied (the default)\&. +.sp +If you use link mode, the upgrade will be much faster (no file copying), but you will not be able to access your old cluster once you start the new cluster after the upgrade\&. Link mode also requires that the old and new cluster data directories be in the same file system\&. See +pg_upgrade \-\-help +for a full list of options\&. +.sp +For Windows users, you must be logged into an administrative account, and then start a shell as the +postgres +user and set the proper path: +.sp +.if n \{\ +.RS 4 +.\} +.nf +RUNAS /USER:postgres "CMD\&.EXE" +SET PATH=%PATH%;C:\eProgram Files\ePostgreSQL\e9\&.0\ebin; +.fi +.if n \{\ +.RE +.\} +.sp +and then run +pg_upgrade +with quoted directories, e\&.g\&.: +.sp +.if n \{\ +.RS 4 +.\} +.nf +pg_upgrade\&.exe + \-\-old\-datadir "C:/Program Files/PostgreSQL/8\&.4/data" + \-\-new\-datadir "C:/Program Files/PostgreSQL/9\&.0/data" + \-\-old\-bindir "C:/Program Files/PostgreSQL/8\&.4/bin" + \-\-new\-bindir "C:/Program Files/PostgreSQL/9\&.0/bin" +.fi +.if n \{\ +.RE +.\} +.sp +Once started, +\fBpg_upgrade\fR +will verify the two clusters are compatible and then do the upgrade\&. You can use +\fBpg_upgrade \-\-check\fR +to perform only the checks, even if the old server is still running\&. +\fBpg_upgrade \-\-check\fR +will also outline any manual adjustments you will need to make after the upgrade\&. +\fBpg_upgrade\fR +requires write permission in the current directory\&. +.sp +Obviously, no one should be accessing the clusters during the upgrade\&. +pg_upgrade +defaults to running servers on port 50432 to avoid unintended client connections\&. You can use the same port number for both clusters when doing an upgrade because the old and new clusters will not be running at the same time\&. However, when checking an old running server, the old and new port numbers must be different\&. +.sp +If an error occurs while restoring the database schema, +\fBpg_upgrade\fR +will exit and you will have to revert to the old cluster as outlined in +Step 14 +below\&. To try +\fBpg_upgrade\fR +again, you will need to modify the old cluster so the pg_upgrade schema restore succeeds\&. If the problem is a contrib module, you might need to uninstall the contrib module from the old cluster and install it in the new cluster after the upgrade, assuming the module is not being used to store user data\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 10.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 10." 4.2 +.\} +Restore pg_hba\&.conf: If you modified +pg_hba\&.conf +to use +trust, restore its original authentication settings\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 11.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 11." 4.2 +.\} +Post\-Upgrade processing: If any post\-upgrade processing is required, pg_upgrade will issue warnings as it completes\&. It will also generate script files that must be run by the administrator\&. The script files will connect to each database that needs post\-upgrade processing\&. Each script should be run using: +.sp +.if n \{\ +.RS 4 +.\} +.nf +psql \-\-username postgres \-\-file script\&.sql postgres +.fi +.if n \{\ +.RE +.\} +.sp +The scripts can be run in any order and can be deleted once they have been run\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBCaution\fR +.ps -1 +.br +In general it is unsafe to access tables referenced in rebuild scripts until the rebuild scripts have run to completion; doing so could yield incorrect results or poor performance\&. Tables not referenced in rebuild scripts can be accessed immediately\&. +.sp .5v +.RE +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 12.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 12." 4.2 +.\} +Statistics: Because optimizer statistics are not transferred by +\fBpg_upgrade\fR, you will be instructed to run a command to regenerate that information at the end of the upgrade\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 13.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 13." 4.2 +.\} +Delete old cluster: Once you are satisfied with the upgrade, you can delete the old cluster\*(Aqs data directories by running the script mentioned when +\fBpg_upgrade\fR +completes\&. You can also delete the old installation directories (e\&.g\&. +bin, +share)\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 14.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 14." 4.2 +.\} +Reverting to old cluster: If, after running +\fBpg_upgrade\fR, you wish to revert to the old cluster, there are several options: +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +If you ran +\fBpg_upgrade\fR +with +\fB\-\-check\fR, no modifications were made to the old cluster and you can re\-use it anytime\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +If you ran +\fBpg_upgrade\fR +with +\fB\-\-link\fR, the data files are shared between the old and new cluster\&. If you started the new cluster, the new server has written to those shared files and it is unsafe to use the old cluster\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +If you ran +\fBpg_upgrade\fR +\fIwithout\fR +\fB\-\-link\fR +or did not start the new server, the old cluster was not modified except that, if linking started, a +\&.old +suffix was appended to +$PGDATA/global/pg_control\&. To reuse the old cluster, possibly remove the +\&.old +suffix from +$PGDATA/global/pg_control; you can then restart the old cluster\&. +.RE +.sp +.RE +.SH "NOTES" +.PP + +pg_upgrade +does not support upgrading of databases containing these +reg* +OID\-referencing system data types: +regproc, +regprocedure, +regoper, +regoperator, +regconfig, and +regdictionary\&. (regtype +can be upgraded\&.) +.PP +All failure, rebuild, and reindex cases will be reported by +pg_upgrade +if they affect your installation; post\-upgrade scripts to rebuild tables and indexes will be generated automatically\&. +.PP +For deployment testing, create a schema\-only copy of the old cluster, insert dummy data, and upgrade that\&. +.PP +If you are upgrading a pre\-PostgreSQL +9\&.2 cluster that uses a configuration\-file\-only directory, you must pass the real data directory location to +pg_upgrade, and pass the configuration directory location to the server, e\&.g\&. +\-d /real\-data\-directory \-o \*(Aq\-D /configuration\-directory\*(Aq\&. +.PP +If using a pre\-9\&.1 old server that is using a non\-default Unix\-domain socket directory or a default that differs from the default of the new cluster, set +\fBPGHOST\fR +to point to the old server\*(Aqs socket location\&. (This is not relevant on Windows\&.) +.PP +A Log\-Shipping Standby Server (Section 25.2, \(lqLog-Shipping Standby Servers\(rq, in the documentation) cannot be upgraded because the server must allow writes\&. The simplest way is to upgrade the primary and use +\fBrsync\fR +to rebuild the standbys\&. You can run +\fBrsync\fR +while the primary is down, or as part of a base backup (Section 24.3.2, \(lqMaking a Base Backup\(rq, in the documentation) which overwrites the old standby cluster\&. +.PP +If you want to use link mode and you do not want your old cluster to be modified when the new cluster is started, make a copy of the old cluster and upgrade that in link mode\&. To make a valid copy of the old cluster, use +\fBrsync\fR +to create a dirty copy of the old cluster while the server is running, then shut down the old server and run +\fBrsync\fR +again to update the copy with any changes to make it consistent\&. You might want to exclude some files, e\&.g\&. +postmaster\&.pid, as documented in +Section 24.3.3, \(lqMaking a Base Backup Using the Low Level API\(rq, in the documentation\&. +.SS "Limitations in Upgrading from PostgreSQL 8\&.3" +.PP +Upgrading +\fIfrom\fR +PostgreSQL 8\&.3 has additional restrictions not present when upgrading from later PostgreSQL releases\&. For example, pg_upgrade will not work for upgrading from 8\&.3 if a user column is defined as: +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +a +tsquery +data type +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +data type +name +and is not the first column +.RE +.PP +You must drop any such columns and upgrade them manually\&. +.PP +pg_upgrade will not work if the +ltree +contrib module is installed in a database\&. +.PP +pg_upgrade will require a table rebuild if: +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +a user column is of data type +tsvector +.RE +.PP +pg_upgrade will require a reindex if: +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +an index is of type hash or GIN +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +an index uses +\fBbpchar_pattern_ops\fR +.RE +.PP +Also, the default datetime storage format changed to integer after +PostgreSQL +8\&.3\&. pg_upgrade will check that the datetime storage format used by the old and new clusters match\&. Make sure your new cluster is built with the configure flag +\fB\-\-disable\-integer\-datetimes\fR\&. +.PP +For Windows users, note that due to different integer datetimes settings used by the one\-click installer and the MSI installer, it is only possible to upgrade from version 8\&.3 of the one\-click distribution to version 8\&.4 or later of the one\-click distribution\&. It is not possible to upgrade from the MSI installer to the one\-click installer\&. +.SH "SEE ALSO" +\fBinitdb\fR(1), \fBpg_ctl\fR(1), \fBpg_dump\fR(1), \fBpostgres\fR(1) diff --git a/doc/src/sgml/man1/pgbench.1 b/doc/src/sgml/man1/pgbench.1 new file mode 100644 index 000000000..15827ef39 --- /dev/null +++ b/doc/src/sgml/man1/pgbench.1 @@ -0,0 +1,799 @@ +'\" t +.\" Title: pgbench +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "PGBENCH" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +pgbench \- run a benchmark test on PostgreSQL +.\" pgbench +.SH "SYNOPSIS" +.HP \w'\fBpgbench\fR\ 'u +\fBpgbench\fR \fB\-i\fR [\fIoption\fR...] [\fIdbname\fR] +.HP \w'\fBpgbench\fR\ 'u +\fBpgbench\fR [\fIoption\fR...] [\fIdbname\fR] +.SH "DESCRIPTION" +.PP + +pgbench +is a simple program for running benchmark tests on +PostgreSQL\&. It runs the same sequence of SQL commands over and over, possibly in multiple concurrent database sessions, and then calculates the average transaction rate (transactions per second)\&. By default, +pgbench +tests a scenario that is loosely based on TPC\-B, involving five +\fBSELECT\fR, +\fBUPDATE\fR, and +\fBINSERT\fR +commands per transaction\&. However, it is easy to test other cases by writing your own transaction script files\&. +.PP +Typical output from pgbench looks like: +.sp +.if n \{\ +.RS 4 +.\} +.nf +transaction type: TPC\-B (sort of) +scaling factor: 10 +query mode: simple +number of clients: 10 +number of threads: 1 +number of transactions per client: 1000 +number of transactions actually processed: 10000/10000 +tps = 85\&.184871 (including connections establishing) +tps = 85\&.296346 (excluding connections establishing) +.fi +.if n \{\ +.RE +.\} +.sp +The first six lines report some of the most important parameter settings\&. The next line reports the number of transactions completed and intended (the latter being just the product of number of clients and number of transactions per client); these will be equal unless the run failed before completion\&. (In +\fB\-T\fR +mode, only the actual number of transactions is printed\&.) The last two lines report the number of transactions per second, figured with and without counting the time to start database sessions\&. +.PP +The default TPC\-B\-like transaction test requires specific tables to be set up beforehand\&. +pgbench +should be invoked with the +\fB\-i\fR +(initialize) option to create and populate these tables\&. (When you are testing a custom script, you don\*(Aqt need this step, but will instead need to do whatever setup your test needs\&.) Initialization looks like: +.sp +.if n \{\ +.RS 4 +.\} +.nf +pgbench \-i [ \fIother\-options\fR ] \fIdbname\fR +.fi +.if n \{\ +.RE +.\} +.sp +where +\fIdbname\fR +is the name of the already\-created database to test in\&. (You may also need +\fB\-h\fR, +\fB\-p\fR, and/or +\fB\-U\fR +options to specify how to connect to the database server\&.) +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBCaution\fR +.ps -1 +.br +.PP + +pgbench \-i +creates four tables +pgbench_accounts, +pgbench_branches, +pgbench_history, and +pgbench_tellers, destroying any existing tables of these names\&. Be very careful to use another database if you have tables having these names! +.sp .5v +.RE +.PP +At the default +\(lqscale factor\(rq +of 1, the tables initially contain this many rows: +.sp +.if n \{\ +.RS 4 +.\} +.nf +table # of rows +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- +pgbench_branches 1 +pgbench_tellers 10 +pgbench_accounts 100000 +pgbench_history 0 +.fi +.if n \{\ +.RE +.\} +.sp +You can (and, for most purposes, probably should) increase the number of rows by using the +\fB\-s\fR +(scale factor) option\&. The +\fB\-F\fR +(fillfactor) option might also be used at this point\&. +.PP +Once you have done the necessary setup, you can run your benchmark with a command that doesn\*(Aqt include +\fB\-i\fR, that is +.sp +.if n \{\ +.RS 4 +.\} +.nf +pgbench [ \fIoptions\fR ] \fIdbname\fR +.fi +.if n \{\ +.RE +.\} +.sp +In nearly all cases, you\*(Aqll need some options to make a useful test\&. The most important options are +\fB\-c\fR +(number of clients), +\fB\-t\fR +(number of transactions), +\fB\-T\fR +(time limit), and +\fB\-f\fR +(specify a custom script file)\&. See below for a full list\&. +.SH "OPTIONS" +.PP +The following is divided into three subsections: Different options are used during database initialization and while running benchmarks, some options are useful in both cases\&. +.SS "Initialization Options" +.PP + +pgbench +accepts the following command\-line initialization arguments: +.PP +\fB\-i\fR +.RS 4 +Required to invoke initialization mode\&. +.RE +.PP +\fB\-F\fR \fIfillfactor\fR +.RS 4 +Create the +pgbench_accounts, +pgbench_tellers +and +pgbench_branches +tables with the given fillfactor\&. Default is 100\&. +.RE +.PP +\fB\-s\fR \fIscale_factor\fR +.RS 4 +Multiply the number of rows generated by the scale factor\&. For example, +\-s 100 +will create 10,000,000 rows in the +pgbench_accounts +table\&. Default is 1\&. +.RE +.PP +\fB\-\-index\-tablespace=\fR\fB\fIindex_tablespace\fR\fR +.RS 4 +Create indexes in the specified tablespace, rather than the default tablespace\&. +.RE +.PP +\fB\-\-tablespace=\fR\fB\fItablespace\fR\fR +.RS 4 +Create tables in the specified tablespace, rather than the default tablespace\&. +.RE +.PP +\fB\-\-unlogged\-tables\fR +.RS 4 +Create all tables as unlogged tables, rather than permanent tables\&. +.RE +.SS "Benchmarking Options" +.PP + +pgbench +accepts the following command\-line benchmarking arguments: +.PP +\fB\-c\fR \fIclients\fR +.RS 4 +Number of clients simulated, that is, number of concurrent database sessions\&. Default is 1\&. +.RE +.PP +\fB\-C\fR +.RS 4 +Establish a new connection for each transaction, rather than doing it just once per client session\&. This is useful to measure the connection overhead\&. +.RE +.PP +\fB\-d\fR +.RS 4 +Print debugging output\&. +.RE +.PP +\fB\-D\fR \fIvarname\fR=\fIvalue\fR +.RS 4 +Define a variable for use by a custom script (see below)\&. Multiple +\fB\-D\fR +options are allowed\&. +.RE +.PP +\fB\-f\fR \fIfilename\fR +.RS 4 +Read transaction script from +\fIfilename\fR\&. See below for details\&. +\fB\-N\fR, +\fB\-S\fR, and +\fB\-f\fR +are mutually exclusive\&. +.RE +.PP +\fB\-j\fR \fIthreads\fR +.RS 4 +Number of worker threads within +pgbench\&. Using more than one thread can be helpful on multi\-CPU machines\&. The number of clients must be a multiple of the number of threads, since each thread is given the same number of client sessions to manage\&. Default is 1\&. +.RE +.PP +\fB\-l\fR +.RS 4 +Write the time taken by each transaction to a log file\&. See below for details\&. +.RE +.PP +\fB\-M\fR \fIquerymode\fR +.RS 4 +Protocol to use for submitting queries to the server: +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +simple: use simple query protocol\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +extended: use extended query protocol\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +prepared: use extended query protocol with prepared statements\&. +.RE +.sp +The default is simple query protocol\&. (See +Chapter 46, Frontend/Backend Protocol, in the documentation +for more information\&.) +.RE +.PP +\fB\-n\fR +.RS 4 +Perform no vacuuming before running the test\&. This option is +\fInecessary\fR +if you are running a custom test scenario that does not include the standard tables +pgbench_accounts, +pgbench_branches, +pgbench_history, and +pgbench_tellers\&. +.RE +.PP +\fB\-N\fR +.RS 4 +Do not update +pgbench_tellers +and +pgbench_branches\&. This will avoid update contention on these tables, but it makes the test case even less like TPC\-B\&. +.RE +.PP +\fB\-r\fR +.RS 4 +Report the average per\-statement latency (execution time from the perspective of the client) of each command after the benchmark finishes\&. See below for details\&. +.RE +.PP +\fB\-s\fR \fIscale_factor\fR +.RS 4 +Report the specified scale factor in +pgbench\*(Aqs output\&. With the built\-in tests, this is not necessary; the correct scale factor will be detected by counting the number of rows in the +pgbench_branches +table\&. However, when testing custom benchmarks (\fB\-f\fR +option), the scale factor will be reported as 1 unless this option is used\&. +.RE +.PP +\fB\-S\fR +.RS 4 +Perform select\-only transactions instead of TPC\-B\-like test\&. +.RE +.PP +\fB\-t\fR \fItransactions\fR +.RS 4 +Number of transactions each client runs\&. Default is 10\&. +.RE +.PP +\fB\-T\fR \fIseconds\fR +.RS 4 +Run the test for this many seconds, rather than a fixed number of transactions per client\&. +\fB\-t\fR +and +\fB\-T\fR +are mutually exclusive\&. +.RE +.PP +\fB\-v\fR +.RS 4 +Vacuum all four standard tables before running the test\&. With neither +\fB\-n\fR +nor +\fB\-v\fR, pgbench will vacuum the +pgbench_tellers +and +pgbench_branches +tables, and will truncate +pgbench_history\&. +.RE +.SS "Common Options" +.PP + +pgbench +accepts the following command\-line common arguments: +.PP +\fB\-h\fR \fIhostname\fR +.RS 4 +The database server\*(Aqs host name +.RE +.PP +\fB\-p\fR \fIport\fR +.RS 4 +The database server\*(Aqs port number +.RE +.PP +\fB\-U\fR \fIlogin\fR +.RS 4 +The user name to connect as +.RE +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +pgbench +version and exit\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +pgbench +command line arguments, and exit\&. +.RE +.SH "NOTES" +.SS "What is the \(lqTransaction\(rq Actually Performed in pgbench?" +.PP +The default transaction script issues seven commands per transaction: +.sp +.RS 4 +.ie n \{\ +\h'-04' 1.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 1." 4.2 +.\} +BEGIN; +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 2.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 2." 4.2 +.\} +UPDATE pgbench_accounts SET abalance = abalance + :delta WHERE aid = :aid; +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 3.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 3." 4.2 +.\} +SELECT abalance FROM pgbench_accounts WHERE aid = :aid; +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 4.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 4." 4.2 +.\} +UPDATE pgbench_tellers SET tbalance = tbalance + :delta WHERE tid = :tid; +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 5.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 5." 4.2 +.\} +UPDATE pgbench_branches SET bbalance = bbalance + :delta WHERE bid = :bid; +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 6.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 6." 4.2 +.\} +INSERT INTO pgbench_history (tid, bid, aid, delta, mtime) VALUES (:tid, :bid, :aid, :delta, CURRENT_TIMESTAMP); +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 7.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 7." 4.2 +.\} +END; +.RE +.PP +If you specify +\fB\-N\fR, steps 4 and 5 aren\*(Aqt included in the transaction\&. If you specify +\fB\-S\fR, only the +\fBSELECT\fR +is issued\&. +.SS "Custom Scripts" +.PP + +pgbench +has support for running custom benchmark scenarios by replacing the default transaction script (described above) with a transaction script read from a file (\fB\-f\fR +option)\&. In this case a +\(lqtransaction\(rq +counts as one execution of a script file\&. You can even specify multiple scripts (multiple +\fB\-f\fR +options), in which case a random one of the scripts is chosen each time a client session starts a new transaction\&. +.PP +The format of a script file is one SQL command per line; multiline SQL commands are not supported\&. Empty lines and lines beginning with +\-\- +are ignored\&. Script file lines can also be +\(lqmeta commands\(rq, which are interpreted by +pgbench +itself, as described below\&. +.PP +There is a simple variable\-substitution facility for script files\&. Variables can be set by the command\-line +\fB\-D\fR +option, explained above, or by the meta commands explained below\&. In addition to any variables preset by +\fB\-D\fR +command\-line options, the variable +scale +is preset to the current scale factor\&. Once set, a variable\*(Aqs value can be inserted into a SQL command by writing +:\fIvariablename\fR\&. When running more than one client session, each session has its own set of variables\&. +.PP +Script file meta commands begin with a backslash (\e)\&. Arguments to a meta command are separated by white space\&. These meta commands are supported: +.PP +\eset \fIvarname\fR \fIoperand1\fR [ \fIoperator\fR \fIoperand2\fR ] +.RS 4 +Sets variable +\fIvarname\fR +to a calculated integer value\&. Each +\fIoperand\fR +is either an integer constant or a +:\fIvariablename\fR +reference to a variable having an integer value\&. The +\fIoperator\fR +can be ++, +\-, +*, or +/\&. +.sp +Example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +\eset ntellers 10 * :scale +.fi +.if n \{\ +.RE +.\} +.RE +.PP +\esetrandom \fIvarname\fR \fImin\fR \fImax\fR +.RS 4 +Sets variable +\fIvarname\fR +to a random integer value between the limits +\fImin\fR +and +\fImax\fR +inclusive\&. Each limit can be either an integer constant or a +:\fIvariablename\fR +reference to a variable having an integer value\&. +.sp +Example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +\esetrandom aid 1 :naccounts +.fi +.if n \{\ +.RE +.\} +.RE +.PP +\esleep \fInumber\fR [ us | ms | s ] +.RS 4 +Causes script execution to sleep for the specified duration in microseconds (us), milliseconds (ms) or seconds (s)\&. If the unit is omitted then seconds are the default\&. +\fInumber\fR +can be either an integer constant or a +:\fIvariablename\fR +reference to a variable having an integer value\&. +.sp +Example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +\esleep 10 ms +.fi +.if n \{\ +.RE +.\} +.RE +.PP +\esetshell \fIvarname\fR \fIcommand\fR [ \fIargument\fR \&.\&.\&. ] +.RS 4 +Sets variable +\fIvarname\fR +to the result of the shell command +\fIcommand\fR\&. The command must return an integer value through its standard output\&. +.sp + +\fIargument\fR +can be either a text constant or a +:\fIvariablename\fR +reference to a variable of any types\&. If you want to use +\fIargument\fR +starting with colons, you need to add an additional colon at the beginning of +\fIargument\fR\&. +.sp +Example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +\esetshell variable_to_be_assigned command literal_argument :variable ::literal_starting_with_colon +.fi +.if n \{\ +.RE +.\} +.RE +.PP +\eshell \fIcommand\fR [ \fIargument\fR \&.\&.\&. ] +.RS 4 +Same as +\esetshell, but the result is ignored\&. +.sp +Example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +\eshell command literal_argument :variable ::literal_starting_with_colon +.fi +.if n \{\ +.RE +.\} +.RE +.PP +As an example, the full definition of the built\-in TPC\-B\-like transaction is: +.sp +.if n \{\ +.RS 4 +.\} +.nf +\eset nbranches :scale +\eset ntellers 10 * :scale +\eset naccounts 100000 * :scale +\esetrandom aid 1 :naccounts +\esetrandom bid 1 :nbranches +\esetrandom tid 1 :ntellers +\esetrandom delta \-5000 5000 +BEGIN; +UPDATE pgbench_accounts SET abalance = abalance + :delta WHERE aid = :aid; +SELECT abalance FROM pgbench_accounts WHERE aid = :aid; +UPDATE pgbench_tellers SET tbalance = tbalance + :delta WHERE tid = :tid; +UPDATE pgbench_branches SET bbalance = bbalance + :delta WHERE bid = :bid; +INSERT INTO pgbench_history (tid, bid, aid, delta, mtime) VALUES (:tid, :bid, :aid, :delta, CURRENT_TIMESTAMP); +END; +.fi +.if n \{\ +.RE +.\} +.sp +This script allows each iteration of the transaction to reference different, randomly\-chosen rows\&. (This example also shows why it\*(Aqs important for each client session to have its own variables \(em otherwise they\*(Aqd not be independently touching different rows\&.) +.SS "Per\-Transaction Logging" +.PP +With the +\fB\-l\fR +option, +pgbench +writes the time taken by each transaction to a log file\&. The log file will be named +pgbench_log\&.\fInnn\fR, where +\fInnn\fR +is the PID of the pgbench process\&. If the +\fB\-j\fR +option is 2 or higher, creating multiple worker threads, each will have its own log file\&. The first worker will use the same name for its log file as in the standard single worker case\&. The additional log files for the other workers will be named +pgbench_log\&.\fInnn\fR\&.\fImmm\fR, where +\fImmm\fR +is a sequential number for each worker starting with 1\&. +.PP +The format of the log is: +.sp +.if n \{\ +.RS 4 +.\} +.nf +\fIclient_id\fR \fItransaction_no\fR \fItime\fR \fIfile_no\fR \fItime_epoch\fR \fItime_us\fR +.fi +.if n \{\ +.RE +.\} +.sp + +where +\fItime\fR +is the total elapsed transaction time in microseconds, +\fIfile_no\fR +identifies which script file was used (useful when multiple scripts were specified with +\fB\-f\fR), and +\fItime_epoch\fR/\fItime_us\fR +are a UNIX epoch format timestamp and an offset in microseconds (suitable for creating a ISO 8601 timestamp with fractional seconds) showing when the transaction completed\&. +.PP +Here are example outputs: +.sp +.if n \{\ +.RS 4 +.\} +.nf + 0 199 2241 0 1175850568 995598 + 0 200 2465 0 1175850568 998079 + 0 201 2513 0 1175850569 608 + 0 202 2038 0 1175850569 2663 +.fi +.if n \{\ +.RE +.\} +.SS "Per\-Statement Latencies" +.PP +With the +\fB\-r\fR +option, +pgbench +collects the elapsed transaction time of each statement executed by every client\&. It then reports an average of those values, referred to as the latency for each statement, after the benchmark has finished\&. +.PP +For the default script, the output will look similar to this: +.sp +.if n \{\ +.RS 4 +.\} +.nf +starting vacuum\&.\&.\&.end\&. +transaction type: TPC\-B (sort of) +scaling factor: 1 +query mode: simple +number of clients: 10 +number of threads: 1 +number of transactions per client: 1000 +number of transactions actually processed: 10000/10000 +tps = 618\&.764555 (including connections establishing) +tps = 622\&.977698 (excluding connections establishing) +statement latencies in milliseconds: + 0\&.004386 \eset nbranches 1 * :scale + 0\&.001343 \eset ntellers 10 * :scale + 0\&.001212 \eset naccounts 100000 * :scale + 0\&.001310 \esetrandom aid 1 :naccounts + 0\&.001073 \esetrandom bid 1 :nbranches + 0\&.001005 \esetrandom tid 1 :ntellers + 0\&.001078 \esetrandom delta \-5000 5000 + 0\&.326152 BEGIN; + 0\&.603376 UPDATE pgbench_accounts SET abalance = abalance + :delta WHERE aid = :aid; + 0\&.454643 SELECT abalance FROM pgbench_accounts WHERE aid = :aid; + 5\&.528491 UPDATE pgbench_tellers SET tbalance = tbalance + :delta WHERE tid = :tid; + 7\&.335435 UPDATE pgbench_branches SET bbalance = bbalance + :delta WHERE bid = :bid; + 0\&.371851 INSERT INTO pgbench_history (tid, bid, aid, delta, mtime) VALUES (:tid, :bid, :aid, :delta, CURRENT_TIMESTAMP); + 1\&.212976 END; +.fi +.if n \{\ +.RE +.\} +.PP +If multiple script files are specified, the averages are reported separately for each script file\&. +.PP +Note that collecting the additional timing information needed for per\-statement latency computation adds some overhead\&. This will slow average execution speed and lower the computed TPS\&. The amount of slowdown varies significantly depending on platform and hardware\&. Comparing average TPS values with and without latency reporting enabled is a good way to measure if the timing overhead is significant\&. +.SS "Good Practices" +.PP +It is very easy to use +pgbench +to produce completely meaningless numbers\&. Here are some guidelines to help you get useful results\&. +.PP +In the first place, +\fInever\fR +believe any test that runs for only a few seconds\&. Use the +\fB\-t\fR +or +\fB\-T\fR +option to make the run last at least a few minutes, so as to average out noise\&. In some cases you could need hours to get numbers that are reproducible\&. It\*(Aqs a good idea to try the test run a few times, to find out if your numbers are reproducible or not\&. +.PP +For the default TPC\-B\-like test scenario, the initialization scale factor (\fB\-s\fR) should be at least as large as the largest number of clients you intend to test (\fB\-c\fR); else you\*(Aqll mostly be measuring update contention\&. There are only +\fB\-s\fR +rows in the +pgbench_branches +table, and every transaction wants to update one of them, so +\fB\-c\fR +values in excess of +\fB\-s\fR +will undoubtedly result in lots of transactions blocked waiting for other transactions\&. +.PP +The default test scenario is also quite sensitive to how long it\*(Aqs been since the tables were initialized: accumulation of dead rows and dead space in the tables changes the results\&. To understand the results you must keep track of the total number of updates and when vacuuming happens\&. If autovacuum is enabled it can result in unpredictable changes in measured performance\&. +.PP +A limitation of +pgbench +is that it can itself become the bottleneck when trying to test a large number of client sessions\&. This can be alleviated by running +pgbench +on a different machine from the database server, although low network latency will be essential\&. It might even be useful to run several +pgbench +instances concurrently, on several client machines, against the same database server\&. diff --git a/doc/src/sgml/man1/postgres.1 b/doc/src/sgml/man1/postgres.1 new file mode 100644 index 000000000..dad1e7174 --- /dev/null +++ b/doc/src/sgml/man1/postgres.1 @@ -0,0 +1,639 @@ +'\" t +.\" Title: postgres +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "POSTGRES" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +postgres \- PostgreSQL database server +.\" postgres +.SH "SYNOPSIS" +.HP \w'\fBpostgres\fR\ 'u +\fBpostgres\fR [\fIoption\fR...] +.SH "DESCRIPTION" +.PP + +\fBpostgres\fR +is the +PostgreSQL +database server\&. In order for a client application to access a database it connects (over a network or locally) to a running +\fBpostgres\fR +instance\&. The +\fBpostgres\fR +instance then starts a separate server process to handle the connection\&. +.PP +One +\fBpostgres\fR +instance always manages the data of exactly one database cluster\&. A database cluster is a collection of databases that is stored at a common file system location (the +\(lqdata area\(rq)\&. More than one +\fBpostgres\fR +instance can run on a system at one time, so long as they use different data areas and different communication ports (see below)\&. When +\fBpostgres\fR +starts it needs to know the location of the data area\&. The location must be specified by the +\fB\-D\fR +option or the +\fBPGDATA\fR +environment variable; there is no default\&. Typically, +\fB\-D\fR +or +\fBPGDATA\fR +points directly to the data area directory created by +\fBinitdb\fR(1)\&. Other possible file layouts are discussed in +Section 18.2, \(lqFile Locations\(rq, in the documentation\&. +.PP +By default +\fBpostgres\fR +starts in the foreground and prints log messages to the standard error stream\&. In practical applications +\fBpostgres\fR +should be started as a background process, perhaps at boot time\&. +.PP +The +\fBpostgres\fR +command can also be called in single\-user mode\&. The primary use for this mode is during bootstrapping by +\fBinitdb\fR(1)\&. Sometimes it is used for debugging or disaster recovery; note that running a single\-user server is not truly suitable for debugging the server, since no realistic interprocess communication and locking will happen\&. When invoked in single\-user mode from the shell, the user can enter queries and the results will be printed to the screen, but in a form that is more useful for developers than end users\&. In the single\-user mode, the session user will be set to the user with ID 1, and implicit superuser powers are granted to this user\&. This user does not actually have to exist, so the single\-user mode can be used to manually recover from certain kinds of accidental damage to the system catalogs\&. +.SH "OPTIONS" +.PP + +\fBpostgres\fR +accepts the following command\-line arguments\&. For a detailed discussion of the options consult +Chapter 18, Server Configuration, in the documentation\&. You can save typing most of these options by setting up a configuration file\&. Some (safe) options can also be set from the connecting client in an application\-dependent way to apply only for that session\&. For example, if the environment variable +\fBPGOPTIONS\fR +is set, then +libpq\-based clients will pass that string to the server, which will interpret it as +\fBpostgres\fR +command\-line options\&. +.SS "General Purpose" +.PP +\fB\-A 0|1\fR +.RS 4 +Enables run\-time assertion checks, which is a debugging aid to detect programming mistakes\&. This option is only available if assertions were enabled when +PostgreSQL +was compiled\&. If so, the default is on\&. +.RE +.PP +\fB\-B \fR\fB\fInbuffers\fR\fR +.RS 4 +Sets the number of shared buffers for use by the server processes\&. The default value of this parameter is chosen automatically by +initdb\&. Specifying this option is equivalent to setting the +shared_buffers +configuration parameter\&. +.RE +.PP +\fB\-c \fR\fB\fIname\fR\fR\fB=\fR\fB\fIvalue\fR\fR +.RS 4 +Sets a named run\-time parameter\&. The configuration parameters supported by +PostgreSQL +are described in +Chapter 18, Server Configuration, in the documentation\&. Most of the other command line options are in fact short forms of such a parameter assignment\&. +\fB\-c\fR +can appear multiple times to set multiple parameters\&. +.RE +.PP +\fB\-C \fR\fB\fIname\fR\fR +.RS 4 +Prints the value of the named run\-time parameter, and exits\&. (See the +\fB\-c\fR +option above for details\&.) This can be used on a running server, and returns values from +postgresql\&.conf, modified by any parameters supplied in this invocation\&. It does not reflect parameters supplied when the cluster was started\&. +.sp +This option is meant for other programs that interact with a server instance, such as +\fBpg_ctl\fR(1), to query configuration parameter values\&. User\-facing applications should instead use +\fBSHOW\fR(7) +or the +pg_settings +view\&. +.RE +.PP +\fB\-d \fR\fB\fIdebug\-level\fR\fR +.RS 4 +Sets the debug level\&. The higher this value is set, the more debugging output is written to the server log\&. Values are from 1 to 5\&. It is also possible to pass +\-d 0 +for a specific session, which will prevent the server log level of the parent +\fBpostgres\fR +process from being propagated to this session\&. +.RE +.PP +\fB\-D \fR\fB\fIdatadir\fR\fR +.RS 4 +Specifies the file system location of the data directory or configuration file(s)\&. See +Section 18.2, \(lqFile Locations\(rq, in the documentation +for details\&. +.RE +.PP +\fB\-e\fR +.RS 4 +Sets the default date style to +\(lqEuropean\(rq, that is +DMY +ordering of input date fields\&. This also causes the day to be printed before the month in certain date output formats\&. See +Section 8.5, \(lqDate/Time Types\(rq, in the documentation +for more information\&. +.RE +.PP +\fB\-F\fR +.RS 4 +Disables +\fBfsync\fR +calls for improved performance, at the risk of data corruption in the event of a system crash\&. Specifying this option is equivalent to disabling the +fsync +configuration parameter\&. Read the detailed documentation before using this! +.RE +.PP +\fB\-h \fR\fB\fIhostname\fR\fR +.RS 4 +Specifies the IP host name or address on which +\fBpostgres\fR +is to listen for TCP/IP connections from client applications\&. The value can also be a comma\-separated list of addresses, or +* +to specify listening on all available interfaces\&. An empty value specifies not listening on any IP addresses, in which case only Unix\-domain sockets can be used to connect to the server\&. Defaults to listening only on +localhost\&. Specifying this option is equivalent to setting the +listen_addresses +configuration parameter\&. +.RE +.PP +\fB\-i\fR +.RS 4 +Allows remote clients to connect via TCP/IP (Internet domain) connections\&. Without this option, only local connections are accepted\&. This option is equivalent to setting +\fIlisten_addresses\fR +to +* +in +postgresql\&.conf +or via +\fB\-h\fR\&. +.sp +This option is deprecated since it does not allow access to the full functionality of +listen_addresses\&. It\*(Aqs usually better to set +\fIlisten_addresses\fR +directly\&. +.RE +.PP +\fB\-k \fR\fB\fIdirectory\fR\fR +.RS 4 +Specifies the directory of the Unix\-domain socket on which +\fBpostgres\fR +is to listen for connections from client applications\&. The default is normally +/tmp, but can be changed at build time\&. +.RE +.PP +\fB\-l\fR +.RS 4 +Enables secure connections using +SSL\&. +PostgreSQL +must have been compiled with support for +SSL +for this option to be available\&. For more information on using +SSL, refer to +Section 17.9, \(lqSecure TCP/IP Connections with SSL\(rq, in the documentation\&. +.RE +.PP +\fB\-N \fR\fB\fImax\-connections\fR\fR +.RS 4 +Sets the maximum number of client connections that this server will accept\&. The default value of this parameter is chosen automatically by +initdb\&. Specifying this option is equivalent to setting the +max_connections +configuration parameter\&. +.RE +.PP +\fB\-o \fR\fB\fIextra\-options\fR\fR +.RS 4 +The command\-line\-style options specified in +\fIextra\-options\fR +are passed to all server processes started by this +\fBpostgres\fR +process\&. If the option string contains any spaces, the entire string must be quoted\&. +.sp +The use of this option is obsolete; all command\-line options for server processes can be specified directly on the +\fBpostgres\fR +command line\&. +.RE +.PP +\fB\-p \fR\fB\fIport\fR\fR +.RS 4 +Specifies the TCP/IP port or local Unix domain socket file extension on which +\fBpostgres\fR +is to listen for connections from client applications\&. Defaults to the value of the +\fBPGPORT\fR +environment variable, or if +\fBPGPORT\fR +is not set, then defaults to the value established during compilation (normally 5432)\&. If you specify a port other than the default port, then all client applications must specify the same port using either command\-line options or +\fBPGPORT\fR\&. +.RE +.PP +\fB\-s\fR +.RS 4 +Print time information and other statistics at the end of each command\&. This is useful for benchmarking or for use in tuning the number of buffers\&. +.RE +.PP +\fB\-S\fR \fIwork\-mem\fR +.RS 4 +Specifies the amount of memory to be used by internal sorts and hashes before resorting to temporary disk files\&. See the description of the +\fIwork_mem\fR +configuration parameter in +Section 18.4.1, \(lqMemory\(rq, in the documentation\&. +.RE +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +postgres +version and exit\&. +.RE +.PP +\fB\-\-\fR\fB\fIname\fR\fR\fB=\fR\fB\fIvalue\fR\fR +.RS 4 +Sets a named run\-time parameter; a shorter form of +\fB\-c\fR\&. +.RE +.PP +\fB\-\-describe\-config\fR +.RS 4 +This option dumps out the server\*(Aqs internal configuration variables, descriptions, and defaults in tab\-delimited +\fBCOPY\fR +format\&. It is designed primarily for use by administration tools\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +postgres +command line arguments, and exit\&. +.RE +.SS "Semi\-internal Options" +.PP +The options described here are used mainly for debugging purposes, and in some cases to assist with recovery of severely damaged databases\&. There should be no reason to use them in a production database setup\&. They are listed here only for use by +PostgreSQL +system developers\&. Furthermore, these options might change or be removed in a future release without notice\&. +.PP +\fB\-f\fR { s | i | o | b | t | n | m | h } +.RS 4 +Forbids the use of particular scan and join methods: +s +and +i +disable sequential and index scans respectively, +o, +b +and +t +disable index\-only scans, bitmap index scans, and TID scans respectively, while +n, +m, and +h +disable nested\-loop, merge and hash joins respectively\&. +.sp +Neither sequential scans nor nested\-loop joins can be disabled completely; the +\-fs +and +\-fn +options simply discourage the optimizer from using those plan types if it has any other alternative\&. +.RE +.PP +\fB\-n\fR +.RS 4 +This option is for debugging problems that cause a server process to die abnormally\&. The ordinary strategy in this situation is to notify all other server processes that they must terminate and then reinitialize the shared memory and semaphores\&. This is because an errant server process could have corrupted some shared state before terminating\&. This option specifies that +\fBpostgres\fR +will not reinitialize shared data structures\&. A knowledgeable system programmer can then use a debugger to examine shared memory and semaphore state\&. +.RE +.PP +\fB\-O\fR +.RS 4 +Allows the structure of system tables to be modified\&. This is used by +\fBinitdb\fR\&. +.RE +.PP +\fB\-P\fR +.RS 4 +Ignore system indexes when reading system tables, but still update the indexes when modifying the tables\&. This is useful when recovering from damaged system indexes\&. +.RE +.PP +\fB\-t\fR pa[rser] | pl[anner] | e[xecutor] +.RS 4 +Print timing statistics for each query relating to each of the major system modules\&. This option cannot be used together with the +\fB\-s\fR +option\&. +.RE +.PP +\fB\-T\fR +.RS 4 +This option is for debugging problems that cause a server process to die abnormally\&. The ordinary strategy in this situation is to notify all other server processes that they must terminate and then reinitialize the shared memory and semaphores\&. This is because an errant server process could have corrupted some shared state before terminating\&. This option specifies that +\fBpostgres\fR +will stop all other server processes by sending the signal +SIGSTOP, but will not cause them to terminate\&. This permits system programmers to collect core dumps from all server processes by hand\&. +.RE +.PP +\fB\-v\fR \fIprotocol\fR +.RS 4 +Specifies the version number of the frontend/backend protocol to be used for a particular session\&. This option is for internal use only\&. +.RE +.PP +\fB\-W\fR \fIseconds\fR +.RS 4 +A delay of this many seconds occurs when a new server process is started, after it conducts the authentication procedure\&. This is intended to give an opportunity to attach to the server process with a debugger\&. +.RE +.SS "Options for Single\-User Mode" +.PP +The following options only apply to the single\-user mode\&. +.PP +\fB\-\-single\fR +.RS 4 +Selects the single\-user mode\&. This must be the first argument on the command line\&. +.RE +.PP +\fIdatabase\fR +.RS 4 +Specifies the name of the database to be accessed\&. This must be the last argument on the command line\&. If it is omitted it defaults to the user name\&. +.RE +.PP +\fB\-E\fR +.RS 4 +Echo all commands\&. +.RE +.PP +\fB\-j\fR +.RS 4 +Disables use of newline as a statement delimiter\&. +.RE +.PP +\fB\-r\fR \fIfilename\fR +.RS 4 +Send all server log output to +\fIfilename\fR\&. In normal multiuser mode, this option is ignored, and +stderr +is used by all processes\&. +.RE +.SH "ENVIRONMENT" +.PP +\fBPGCLIENTENCODING\fR +.RS 4 +Default character encoding used by clients\&. (The clients can override this individually\&.) This value can also be set in the configuration file\&. +.RE +.PP +\fBPGDATA\fR +.RS 4 +Default data directory location +.RE +.PP +\fBPGDATESTYLE\fR +.RS 4 +Default value of the +DateStyle +run\-time parameter\&. (The use of this environment variable is deprecated\&.) +.RE +.PP +\fBPGPORT\fR +.RS 4 +Default port number (preferably set in the configuration file) +.RE +.PP +\fBTZ\fR +.RS 4 +Server time zone +.RE +.SH "DIAGNOSTICS" +.PP +A failure message mentioning +semget +or +shmget +probably indicates you need to configure your kernel to provide adequate shared memory and semaphores\&. For more discussion see +Section 17.4, \(lqManaging Kernel Resources\(rq, in the documentation\&. You might be able to postpone reconfiguring your kernel by decreasing +shared_buffers +to reduce the shared memory consumption of +PostgreSQL, and/or by reducing +max_connections +to reduce the semaphore consumption\&. +.PP +A failure message suggesting that another server is already running should be checked carefully, for example by using the command +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBps ax | grep postgres\fR +.fi +.if n \{\ +.RE +.\} +.sp +or +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBps \-ef | grep postgres\fR +.fi +.if n \{\ +.RE +.\} +.sp +depending on your system\&. If you are certain that no conflicting server is running, you can remove the lock file mentioned in the message and try again\&. +.PP +A failure message indicating inability to bind to a port might indicate that that port is already in use by some non\-PostgreSQL +process\&. You might also get this error if you terminate +\fBpostgres\fR +and immediately restart it using the same port; in this case, you must simply wait a few seconds until the operating system closes the port before trying again\&. Finally, you might get this error if you specify a port number that your operating system considers to be reserved\&. For example, many versions of Unix consider port numbers under 1024 to be +\(lqtrusted\(rq +and only permit the Unix superuser to access them\&. +.SH "NOTES" +.PP +The utility command +\fBpg_ctl\fR(1) +can be used to start and shut down the +\fBpostgres\fR +server safely and comfortably\&. +.PP +If at all possible, +\fIdo not\fR +use +SIGKILL +to kill the main +\fBpostgres\fR +server\&. Doing so will prevent +\fBpostgres\fR +from freeing the system resources (e\&.g\&., shared memory and semaphores) that it holds before terminating\&. This might cause problems for starting a fresh +\fBpostgres\fR +run\&. +.PP +To terminate the +\fBpostgres\fR +server normally, the signals +SIGTERM, +SIGINT, or +SIGQUIT +can be used\&. The first will wait for all clients to terminate before quitting, the second will forcefully disconnect all clients, and the third will quit immediately without proper shutdown, resulting in a recovery run during restart\&. +.PP +The +SIGHUP +signal will reload the server configuration files\&. It is also possible to send +SIGHUP +to an individual server process, but that is usually not sensible\&. +.PP +To cancel a running query, send the +SIGINT +signal to the process running that command\&. +.PP +The +\fBpostgres\fR +server uses +SIGTERM +to tell subordinate server processes to quit normally and +SIGQUIT +to terminate without the normal cleanup\&. These signals +\fIshould not\fR +be used by users\&. It is also unwise to send +SIGKILL +to a server process \(em the main +\fBpostgres\fR +process will interpret this as a crash and will force all the sibling processes to quit as part of its standard crash\-recovery procedure\&. +.SH "BUGS" +.PP +The +\fB\-\-\fR +options will not work on +FreeBSD +or +OpenBSD\&. Use +\fB\-c\fR +instead\&. This is a bug in the affected operating systems; a future release of +PostgreSQL +will provide a workaround if this is not fixed\&. +.SH "USAGE" +.PP +To start a single\-user mode server, use a command like +.sp +.if n \{\ +.RS 4 +.\} +.nf +\fBpostgres \-\-single \-D /usr/local/pgsql/data \fR\fB\fIother\-options\fR\fR\fB my_database\fR +.fi +.if n \{\ +.RE +.\} +.sp +Provide the correct path to the database directory with +\fB\-D\fR, or make sure that the environment variable +\fBPGDATA\fR +is set\&. Also specify the name of the particular database you want to work in\&. +.PP +Normally, the single\-user mode server treats newline as the command entry terminator; there is no intelligence about semicolons, as there is in +psql\&. To continue a command across multiple lines, you must type backslash just before each newline except the last one\&. +.PP +But if you use the +\fB\-j\fR +command line switch, then newline does not terminate command entry\&. In this case, the server will read the standard input until the end\-of\-file (EOF) marker, then process the input as a single command string\&. Backslash\-newline is not treated specially in this case\&. +.PP +To quit the session, type +EOF +(Control+D, usually)\&. If you\*(Aqve used +\fB\-j\fR, two consecutive +EOFs are needed to exit\&. +.PP +Note that the single\-user mode server does not provide sophisticated line\-editing features (no command history, for example)\&. Single\-User mode also does not do any background processing, like automatic checkpoints\&. +.SH "EXAMPLES" +.PP +To start +\fBpostgres\fR +in the background using default values, type: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBnohup postgres >logfile 2>&1 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "POSTMASTER" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +postmaster \- PostgreSQL database server +.\" postmaster +.SH "SYNOPSIS" +.HP \w'\fBpostmaster\fR\ 'u +\fBpostmaster\fR [\fIoption\fR...] +.SH "DESCRIPTION" +.PP + +\fBpostmaster\fR +is a deprecated alias of +\fBpostgres\fR\&. +.SH "SEE ALSO" +.PP + +\fBpostgres\fR(1) diff --git a/doc/src/sgml/man1/psql.1 b/doc/src/sgml/man1/psql.1 new file mode 100644 index 000000000..3895645e9 --- /dev/null +++ b/doc/src/sgml/man1/psql.1 @@ -0,0 +1,3103 @@ +'\" t +.\" Title: psql +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "PSQL" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +psql \- PostgreSQL interactive terminal +.\" psql +.SH "SYNOPSIS" +.HP \w'\fBpsql\fR\ 'u +\fBpsql\fR [\fIoption\fR...] [\fIdbname\fR\ [\fIusername\fR]] +.SH "DESCRIPTION" +.PP + +psql +is a terminal\-based front\-end to +PostgreSQL\&. It enables you to type in queries interactively, issue them to +PostgreSQL, and see the query results\&. Alternatively, input can be from a file\&. In addition, it provides a number of meta\-commands and various shell\-like features to facilitate writing scripts and automating a wide variety of tasks\&. +.SH "OPTIONS" +.PP +\fB\-a\fR, \fB\-\-echo\-all\fR +.RS 4 +Print all input lines to standard output as they are read\&. This is more useful for script processing than interactive mode\&. This is equivalent to setting the variable +\fIECHO\fR +to +all\&. +.RE +.PP +\fB\-A\fR, \fB\-\-no\-align\fR +.RS 4 +Switches to unaligned output mode\&. (The default output mode is otherwise aligned\&.) +.RE +.PP +\fB\-c \fR\fB\fIcommand\fR\fR, \fB\-\-command=\fR\fB\fIcommand\fR\fR +.RS 4 +Specifies that +psql +is to execute one command string, +\fIcommand\fR, and then exit\&. This is useful in shell scripts\&. Start\-up files (psqlrc +and +~/\&.psqlrc) are ignored with this option\&. +.sp +\fIcommand\fR +must be either a command string that is completely parsable by the server (i\&.e\&., it contains no +psql\-specific features), or a single backslash command\&. Thus you cannot mix +SQL +and +psql +meta\-commands with this option\&. To achieve that, you could pipe the string into +psql, like this: +echo \*(Aq\ex \e\e SELECT * FROM foo;\*(Aq | psql\&. (\e\e +is the separator meta\-command\&.) +.sp +If the command string contains multiple SQL commands, they are processed in a single transaction, unless there are explicit +\fBBEGIN\fR/\fBCOMMIT\fR +commands included in the string to divide it into multiple transactions\&. This is different from the behavior when the same string is fed to +psql\*(Aqs standard input\&. Also, only the result of the last SQL command is returned\&. +.RE +.PP +\fB\-d \fR\fB\fIdbname\fR\fR, \fB\-\-dbname=\fR\fB\fIdbname\fR\fR +.RS 4 +Specifies the name of the database to connect to\&. This is equivalent to specifying +\fIdbname\fR +as the first non\-option argument on the command line\&. +.sp +If this parameter contains an += +sign or starts with a valid +URI +prefix (postgresql:// +or +postgres://), it is treated as a +\fIconninfo\fR +string\&. See +Section 31.1, \(lqDatabase Connection Control Functions\(rq, in the documentation +for more information\&. +.RE +.PP +\fB\-e\fR, \fB\-\-echo\-queries\fR +.RS 4 +Copy all SQL commands sent to the server to standard output as well\&. This is equivalent to setting the variable +\fIECHO\fR +to +queries\&. +.RE +.PP +\fB\-E\fR, \fB\-\-echo\-hidden\fR +.RS 4 +Echo the actual queries generated by +\fB\ed\fR +and other backslash commands\&. You can use this to study +psql\*(Aqs internal operations\&. This is equivalent to setting the variable +\fIECHO_HIDDEN\fR +from within +psql\&. +.RE +.PP +\fB\-f \fR\fB\fIfilename\fR\fR, \fB\-\-file=\fR\fB\fIfilename\fR\fR +.RS 4 +Use the file +\fIfilename\fR +as the source of commands instead of reading commands interactively\&. After the file is processed, +psql +terminates\&. This is in many ways equivalent to the meta\-command +\fB\ei\fR\&. +.sp +If +\fIfilename\fR +is +\- +(hyphen), then standard input is read\&. +.sp +Using this option is subtly different from writing +psql < \fIfilename\fR\&. In general, both will do what you expect, but using +\-f +enables some nice features such as error messages with line numbers\&. There is also a slight chance that using this option will reduce the start\-up overhead\&. On the other hand, the variant using the shell\*(Aqs input redirection is (in theory) guaranteed to yield exactly the same output you would have received had you entered everything by hand\&. +.RE +.PP +\fB\-F \fR\fB\fIseparator\fR\fR, \fB\-\-field\-separator=\fR\fB\fIseparator\fR\fR +.RS 4 +Use +\fIseparator\fR +as the field separator for unaligned output\&. This is equivalent to +\fB\epset fieldsep\fR +or +\fB\ef\fR\&. +.RE +.PP +\fB\-h \fR\fB\fIhostname\fR\fR, \fB\-\-host=\fR\fB\fIhostname\fR\fR +.RS 4 +Specifies the host name of the machine on which the server is running\&. If the value begins with a slash, it is used as the directory for the Unix\-domain socket\&. +.RE +.PP +\fB\-H\fR, \fB\-\-html\fR +.RS 4 +Turn on +HTML +tabular output\&. This is equivalent to +\epset format html +or the +\fB\eH\fR +command\&. +.RE +.PP +\fB\-l\fR, \fB\-\-list\fR +.RS 4 +List all available databases, then exit\&. Other non\-connection options are ignored\&. This is similar to the meta\-command +\fB\elist\fR\&. +.RE +.PP +\fB\-L \fR\fB\fIfilename\fR\fR, \fB\-\-log\-file=\fR\fB\fIfilename\fR\fR +.RS 4 +Write all query output into file +\fIfilename\fR, in addition to the normal output destination\&. +.RE +.PP +\fB\-n\fR, \fB\-\-no\-readline\fR +.RS 4 +Do not use +readline +for line editing and do not use the history\&. This can be useful to turn off tab expansion when cutting and pasting\&. +.RE +.PP +\fB\-o \fR\fB\fIfilename\fR\fR, \fB\-\-output=\fR\fB\fIfilename\fR\fR +.RS 4 +Put all query output into file +\fIfilename\fR\&. This is equivalent to the command +\fB\eo\fR\&. +.RE +.PP +\fB\-p \fR\fB\fIport\fR\fR, \fB\-\-port=\fR\fB\fIport\fR\fR +.RS 4 +Specifies the TCP port or the local Unix\-domain socket file extension on which the server is listening for connections\&. Defaults to the value of the +\fBPGPORT\fR +environment variable or, if not set, to the port specified at compile time, usually 5432\&. +.RE +.PP +\fB\-P \fR\fB\fIassignment\fR\fR, \fB\-\-pset=\fR\fB\fIassignment\fR\fR +.RS 4 +Specifies printing options, in the style of +\fB\epset\fR\&. Note that here you have to separate name and value with an equal sign instead of a space\&. For example, to set the output format to +LaTeX, you could write +\-P format=latex\&. +.RE +.PP +\fB\-q\fR, \fB\-\-quiet\fR +.RS 4 +Specifies that +psql +should do its work quietly\&. By default, it prints welcome messages and various informational output\&. If this option is used, none of this happens\&. This is useful with the +\fB\-c\fR +option\&. Within +psql +you can also set the +\fIQUIET\fR +variable to achieve the same effect\&. +.RE +.PP +\fB\-R \fR\fB\fIseparator\fR\fR, \fB\-\-record\-separator=\fR\fB\fIseparator\fR\fR +.RS 4 +Use +\fIseparator\fR +as the record separator for unaligned output\&. This is equivalent to the +\fB\epset recordsep\fR +command\&. +.RE +.PP +\fB\-s\fR, \fB\-\-single\-step\fR +.RS 4 +Run in single\-step mode\&. That means the user is prompted before each command is sent to the server, with the option to cancel execution as well\&. Use this to debug scripts\&. +.RE +.PP +\fB\-S\fR, \fB\-\-single\-line\fR +.RS 4 +Runs in single\-line mode where a newline terminates an SQL command, as a semicolon does\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +This mode is provided for those who insist on it, but you are not necessarily encouraged to use it\&. In particular, if you mix +SQL +and meta\-commands on a line the order of execution might not always be clear to the inexperienced user\&. +.sp .5v +.RE +.RE +.PP +\fB\-t\fR, \fB\-\-tuples\-only\fR +.RS 4 +Turn off printing of column names and result row count footers, etc\&. This is equivalent to the +\fB\et\fR +command\&. +.RE +.PP +\fB\-T \fR\fB\fItable_options\fR\fR, \fB\-\-table\-attr=\fR\fB\fItable_options\fR\fR +.RS 4 +Specifies options to be placed within the +HTML +table +tag\&. See +\fB\epset\fR +for details\&. +.RE +.PP +\fB\-U \fR\fB\fIusername\fR\fR, \fB\-\-username=\fR\fB\fIusername\fR\fR +.RS 4 +Connect to the database as the user +\fIusername\fR +instead of the default\&. (You must have permission to do so, of course\&.) +.RE +.PP +\fB\-v \fR\fB\fIassignment\fR\fR, \fB\-\-set=\fR\fB\fIassignment\fR\fR, \fB\-\-variable=\fR\fB\fIassignment\fR\fR +.RS 4 +Perform a variable assignment, like the +\fB\eset\fR +meta\-command\&. Note that you must separate name and value, if any, by an equal sign on the command line\&. To unset a variable, leave off the equal sign\&. To set a variable with an empty value, use the equal sign but leave off the value\&. These assignments are done during a very early stage of start\-up, so variables reserved for internal purposes might get overwritten later\&. +.RE +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +psql +version and exit\&. +.RE +.PP +\fB\-w\fR, \fB\-\-no\-password\fR +.RS 4 +Never issue a password prompt\&. If the server requires password authentication and a password is not available by other means such as a +\&.pgpass +file, the connection attempt will fail\&. This option can be useful in batch jobs and scripts where no user is present to enter a password\&. +.sp +Note that this option will remain set for the entire session, and so it affects uses of the meta\-command +\fB\econnect\fR +as well as the initial connection attempt\&. +.RE +.PP +\fB\-W\fR, \fB\-\-password\fR +.RS 4 +Force +psql +to prompt for a password before connecting to a database\&. +.sp +This option is never essential, since +psql +will automatically prompt for a password if the server demands password authentication\&. However, +psql +will waste a connection attempt finding out that the server wants a password\&. In some cases it is worth typing +\fB\-W\fR +to avoid the extra connection attempt\&. +.sp +Note that this option will remain set for the entire session, and so it affects uses of the meta\-command +\fB\econnect\fR +as well as the initial connection attempt\&. +.RE +.PP +\fB\-x\fR, \fB\-\-expanded\fR +.RS 4 +Turn on the expanded table formatting mode\&. This is equivalent to the +\fB\ex\fR +command\&. +.RE +.PP +\fB\-X,\fR, \fB\-\-no\-psqlrc\fR +.RS 4 +Do not read the start\-up file (neither the system\-wide +psqlrc +file nor the user\*(Aqs +~/\&.psqlrc +file)\&. +.RE +.PP +\fB\-z\fR, \fB\-\-field\-separator\-zero\fR +.RS 4 +Set the field separator for unaligned output to a zero byte\&. +.RE +.PP +\fB\-0\fR, \fB\-\-record\-separator\-zero\fR +.RS 4 +Set the record separator for unaligned output to a zero byte\&. This is useful for interfacing, for example, with +xargs \-0\&. +.RE +.PP +\fB\-1\fR, \fB\-\-single\-transaction\fR +.RS 4 +When +psql +executes a script with the +\fB\-f\fR +option, adding this option wraps +\fBBEGIN\fR/\fBCOMMIT\fR +around the script to execute it as a single transaction\&. This ensures that either all the commands complete successfully, or no changes are applied\&. +.sp +If the script itself uses +\fBBEGIN\fR, +\fBCOMMIT\fR, or +\fBROLLBACK\fR, this option will not have the desired effects\&. Also, if the script contains any command that cannot be executed inside a transaction block, specifying this option will cause that command (and hence the whole transaction) to fail\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +psql +command line arguments, and exit\&. +.RE +.SH "EXIT STATUS" +.PP + +psql +returns 0 to the shell if it finished normally, 1 if a fatal error of its own occurs (e\&.g\&. out of memory, file not found), 2 if the connection to the server went bad and the session was not interactive, and 3 if an error occurred in a script and the variable +\fION_ERROR_STOP\fR +was set\&. +.SH "USAGE" +.SS "Connecting to a Database" +.PP + +psql +is a regular +PostgreSQL +client application\&. In order to connect to a database you need to know the name of your target database, the host name and port number of the server, and what user name you want to connect as\&. +psql +can be told about those parameters via command line options, namely +\fB\-d\fR, +\fB\-h\fR, +\fB\-p\fR, and +\fB\-U\fR +respectively\&. If an argument is found that does not belong to any option it will be interpreted as the database name (or the user name, if the database name is already given)\&. Not all of these options are required; there are useful defaults\&. If you omit the host name, +psql +will connect via a Unix\-domain socket to a server on the local host, or via TCP/IP to +localhost +on machines that don\*(Aqt have Unix\-domain sockets\&. The default port number is determined at compile time\&. Since the database server uses the same default, you will not have to specify the port in most cases\&. The default user name is your Unix user name, as is the default database name\&. Note that you cannot just connect to any database under any user name\&. Your database administrator should have informed you about your access rights\&. +.PP +When the defaults aren\*(Aqt quite right, you can save yourself some typing by setting the environment variables +\fBPGDATABASE\fR, +\fBPGHOST\fR, +\fBPGPORT\fR +and/or +\fBPGUSER\fR +to appropriate values\&. (For additional environment variables, see +Section 31.14, \(lqEnvironment Variables\(rq, in the documentation\&.) It is also convenient to have a +~/\&.pgpass +file to avoid regularly having to type in passwords\&. See +Section 31.15, \(lqThe Password File\(rq, in the documentation +for more information\&. +.PP +An alternative way to specify connection parameters is in a +\fIconninfo\fR +string or a +URI, which is used instead of a database name\&. This mechanism give you very wide control over the connection\&. For example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpsql "service=myservice sslmode=require"\fR +$ \fBpsql postgresql://dbmaster:5433/mydb?sslmode=require\fR +.fi +.if n \{\ +.RE +.\} +.sp +This way you can also use +LDAP +for connection parameter lookup as described in +Section 31.17, \(lqLDAP Lookup of Connection Parameters\(rq, in the documentation\&. See +Section 31.1, \(lqDatabase Connection Control Functions\(rq, in the documentation +for more information on all the available connection options\&. +.PP +If the connection could not be made for any reason (e\&.g\&., insufficient privileges, server is not running on the targeted host, etc\&.), +psql +will return an error and terminate\&. +.PP +If at least one of standard input or standard output are a terminal, then +psql +sets the client encoding to +\(lqauto\(rq, which will detect the appropriate client encoding from the locale settings (\fBLC_CTYPE\fR +environment variable on Unix systems)\&. If this doesn\*(Aqt work out as expected, the client encoding can be overridden using the environment variable +\fBPGCLIENTENCODING\fR\&. +.SS "Entering SQL Commands" +.PP +In normal operation, +psql +provides a prompt with the name of the database to which +psql +is currently connected, followed by the string +=>\&. For example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBpsql testdb\fR +psql (9\&.2\&.2) +Type "help" for help\&. + +testdb=> +.fi +.if n \{\ +.RE +.\} +.PP +At the prompt, the user can type in +SQL +commands\&. Ordinarily, input lines are sent to the server when a command\-terminating semicolon is reached\&. An end of line does not terminate a command\&. Thus commands can be spread over several lines for clarity\&. If the command was sent and executed without error, the results of the command are displayed on the screen\&. +.PP +Whenever a command is executed, +psql +also polls for asynchronous notification events generated by +\fBLISTEN\fR(7) +and +\fBNOTIFY\fR(7)\&. +.SS "Meta\-Commands" +.PP +Anything you enter in +psql +that begins with an unquoted backslash is a +psql +meta\-command that is processed by +psql +itself\&. These commands make +psql +more useful for administration or scripting\&. Meta\-commands are often called slash or backslash commands\&. +.PP +The format of a +psql +command is the backslash, followed immediately by a command verb, then any arguments\&. The arguments are separated from the command verb and each other by any number of whitespace characters\&. +.PP +To include whitespace in an argument you can quote it with single quotes\&. To include a single quote in an argument, write two single quotes within single\-quoted text\&. Anything contained in single quotes is furthermore subject to C\-like substitutions for +\en +(new line), +\et +(tab), +\eb +(backspace), +\er +(carriage return), +\ef +(form feed), +\e\fIdigits\fR +(octal), and +\ex\fIdigits\fR +(hexadecimal)\&. A backslash preceding any other character within single\-quoted text quotes that single character, whatever it is\&. +.PP +Within an argument, text that is enclosed in backquotes (`) is taken as a command line that is passed to the shell\&. The output of the command (with any trailing newline removed) replaces the backquoted text\&. +.PP +If an unquoted colon (:) followed by a +psql +variable name appears within an argument, it is replaced by the variable\*(Aqs value, as described in +SQL Interpolation\&. +.PP +Some commands take an +SQL +identifier (such as a table name) as argument\&. These arguments follow the syntax rules of +SQL: Unquoted letters are forced to lowercase, while double quotes (") protect letters from case conversion and allow incorporation of whitespace into the identifier\&. Within double quotes, paired double quotes reduce to a single double quote in the resulting name\&. For example, +FOO"BAR"BAZ +is interpreted as +fooBARbaz, and +"A weird"" name" +becomes +A weird" name\&. +.PP +Parsing for arguments stops at the end of the line, or when another unquoted backslash is found\&. An unquoted backslash is taken as the beginning of a new meta\-command\&. The special sequence +\e\e +(two backslashes) marks the end of arguments and continues parsing +SQL +commands, if any\&. That way +SQL +and +psql +commands can be freely mixed on a line\&. But in any case, the arguments of a meta\-command cannot continue beyond the end of the line\&. +.PP +The following meta\-commands are defined: +.PP +\ea +.RS 4 +If the current table output format is unaligned, it is switched to aligned\&. If it is not unaligned, it is set to unaligned\&. This command is kept for backwards compatibility\&. See +\fB\epset\fR +for a more general solution\&. +.RE +.PP +\ec or \econnect [ \fIdbname\fR [ \fIusername\fR ] [ \fIhost\fR ] [ \fIport\fR ] ] +.RS 4 +Establishes a new connection to a +PostgreSQL +server\&. If the new connection is successfully made, the previous connection is closed\&. If any of +\fIdbname\fR, +\fIusername\fR, +\fIhost\fR +or +\fIport\fR +are omitted or specified as +\-, the value of that parameter from the previous connection is used\&. If there is no previous connection, the +libpq +default for the parameter\*(Aqs value is used\&. +.sp +If the connection attempt failed (wrong user name, access denied, etc\&.), the previous connection will only be kept if +psql +is in interactive mode\&. When executing a non\-interactive script, processing will immediately stop with an error\&. This distinction was chosen as a user convenience against typos on the one hand, and a safety mechanism that scripts are not accidentally acting on the wrong database on the other hand\&. +.RE +.PP +\eC [ \fItitle\fR ] +.RS 4 +Sets the title of any tables being printed as the result of a query or unset any such title\&. This command is equivalent to +\epset title \fItitle\fR\&. (The name of this command derives from +\(lqcaption\(rq, as it was previously only used to set the caption in an +HTML +table\&.) +.RE +.PP +\ecd [ \fIdirectory\fR ] +.RS 4 +Changes the current working directory to +\fIdirectory\fR\&. Without argument, changes to the current user\*(Aqs home directory\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBTip\fR +.ps -1 +.br +To print your current working directory, use +\e! pwd\&. +.sp .5v +.RE +.RE +.PP +\econninfo +.RS 4 +Outputs information about the current database connection\&. +.RE +.PP +\ecopy { \fItable\fR [ ( \fIcolumn_list\fR ) ] | ( \fIquery\fR ) } { from | to } { \fIfilename\fR | stdin | stdout | pstdin | pstdout } [ with ] [ binary ] [ oids ] [ delimiter [ as ] \*(Aq\fIcharacter\fR\*(Aq ] [ null [ as ] \*(Aq\fIstring\fR\*(Aq ] [ csv [ header ] [ quote [ as ] \*(Aq\fIcharacter\fR\*(Aq ] [ escape [ as ] \*(Aq\fIcharacter\fR\*(Aq ] [ force quote \fIcolumn_list\fR | * ] [ force not null \fIcolumn_list\fR ] ] +.RS 4 +Performs a frontend (client) copy\&. This is an operation that runs an +SQL +\fBCOPY\fR(7) +command, but instead of the server reading or writing the specified file, +psql +reads or writes the file and routes the data between the server and the local file system\&. This means that file accessibility and privileges are those of the local user, not the server, and no SQL superuser privileges are required\&. +.sp +The syntax of the command is similar to that of the +SQL +\fBCOPY\fR(7) +command\&. Note that, because of this, special parsing rules apply to the +\fB\ecopy\fR +command\&. In particular, the variable substitution rules and backslash escapes do not apply\&. +.sp +\ecopy \&.\&.\&. from stdin | to stdout +reads/writes based on the command input and output respectively\&. All rows are read from the same source that issued the command, continuing until +\e\&. +is read or the stream reaches +EOF\&. Output is sent to the same place as command output\&. To read/write from +psql\*(Aqs standard input or output, use +pstdin +or +pstdout\&. This option is useful for populating tables in\-line within a SQL script file\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBTip\fR +.ps -1 +.br +This operation is not as efficient as the +SQL +\fBCOPY\fR +command because all data must pass through the client/server connection\&. For large amounts of data the +SQL +command might be preferable\&. +.sp .5v +.RE +.RE +.PP +\ecopyright +.RS 4 +Shows the copyright and distribution terms of +PostgreSQL\&. +.RE +.PP +\ed[S+] [ \fIpattern\fR ] +.RS 4 +For each relation (table, view, index, sequence, or foreign table) or composite type matching the +\fIpattern\fR, show all columns, their types, the tablespace (if not the default) and any special attributes such as +NOT NULL +or defaults\&. Associated indexes, constraints, rules, and triggers are also shown\&. For foreign tables, the associated foreign server is shown as well\&. (\(lqMatching the pattern\(rq +is defined in +Patterns +below\&.) +.sp +For some types of relation, +\ed +shows additional information for each column: column values for sequences, indexed expression for indexes and foreign data wrapper options for foreign tables\&. +.sp +The command form +\ed+ +is identical, except that more information is displayed: any comments associated with the columns of the table are shown, as is the presence of OIDs in the table, the view definition if the relation is a view\&. +.sp +By default, only user\-created objects are shown; supply a pattern or the +S +modifier to include system objects\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +If +\fB\ed\fR +is used without a +\fIpattern\fR +argument, it is equivalent to +\fB\edtvsE\fR +which will show a list of all visible tables, views, sequences and foreign tables\&. This is purely a convenience measure\&. +.sp .5v +.RE +.RE +.PP +\eda[S] [ \fIpattern\fR ] +.RS 4 +Lists aggregate functions, together with their return type and the data types they operate on\&. If +\fIpattern\fR +is specified, only aggregates whose names match the pattern are shown\&. By default, only user\-created objects are shown; supply a pattern or the +S +modifier to include system objects\&. +.RE +.PP +\edb[+] [ \fIpattern\fR ] +.RS 4 +Lists tablespaces\&. If +\fIpattern\fR +is specified, only tablespaces whose names match the pattern are shown\&. If ++ +is appended to the command name, each object is listed with its associated permissions\&. +.RE +.PP +\edc[S+] [ \fIpattern\fR ] +.RS 4 +Lists conversions between character\-set encodings\&. If +\fIpattern\fR +is specified, only conversions whose names match the pattern are listed\&. By default, only user\-created objects are shown; supply a pattern or the +S +modifier to include system objects\&. If ++ +is appended to the command name, each object is listed with its associated description\&. +.RE +.PP +\edC[+] [ \fIpattern\fR ] +.RS 4 +Lists type casts\&. If +\fIpattern\fR +is specified, only casts whose source or target types match the pattern are listed\&. If ++ +is appended to the command name, each object is listed with its associated description\&. +.RE +.PP +\edd[S] [ \fIpattern\fR ] +.RS 4 +Shows the descriptions of objects of type +constraint, +operator class, +operator family, +rule, and +trigger\&. All other comments may be viewed by the respective backslash commands for those object types\&. +.sp +\edd +displays descriptions for objects matching the +\fIpattern\fR, or of visible objects of the appropriate type if no argument is given\&. But in either case, only objects that have a description are listed\&. By default, only user\-created objects are shown; supply a pattern or the +S +modifier to include system objects\&. +.sp +Descriptions for objects can be created with the +\fBCOMMENT\fR(7) +SQL +command\&. +.RE +.PP +\eddp [ \fIpattern\fR ] +.RS 4 +Lists default access privilege settings\&. An entry is shown for each role (and schema, if applicable) for which the default privilege settings have been changed from the built\-in defaults\&. If +\fIpattern\fR +is specified, only entries whose role name or schema name matches the pattern are listed\&. +.sp +The +ALTER DEFAULT PRIVILEGES (\fBALTER_DEFAULT_PRIVILEGES\fR(7)) +command is used to set default access privileges\&. The meaning of the privilege display is explained under +\fBGRANT\fR(7)\&. +.RE +.PP +\edD[S+] [ \fIpattern\fR ] +.RS 4 +Lists domains\&. If +\fIpattern\fR +is specified, only domains whose names match the pattern are shown\&. By default, only user\-created objects are shown; supply a pattern or the +S +modifier to include system objects\&. If ++ +is appended to the command name, each object is listed with its associated permissions and description\&. +.RE +.PP +\edE[S+] [ \fIpattern\fR ], \edi[S+] [ \fIpattern\fR ], \eds[S+] [ \fIpattern\fR ], \edt[S+] [ \fIpattern\fR ], \edv[S+] [ \fIpattern\fR ] +.RS 4 +In this group of commands, the letters +E, +i, +s, +t, and +v +stand for foreign table, index, sequence, table, and view, respectively\&. You can specify any or all of these letters, in any order, to obtain a listing of objects of these types\&. For example, +\edit +lists indexes and tables\&. If ++ +is appended to the command name, each object is listed with its physical size on disk and its associated description, if any\&. If +\fIpattern\fR +is specified, only objects whose names match the pattern are listed\&. By default, only user\-created objects are shown; supply a pattern or the +S +modifier to include system objects\&. +.RE +.PP +\edes[+] [ \fIpattern\fR ] +.RS 4 +Lists foreign servers (mnemonic: +\(lqexternal servers\(rq)\&. If +\fIpattern\fR +is specified, only those servers whose name matches the pattern are listed\&. If the form +\edes+ +is used, a full description of each server is shown, including the server\*(Aqs ACL, type, version, options, and description\&. +.RE +.PP +\edet[+] [ \fIpattern\fR ] +.RS 4 +Lists foreign tables (mnemonic: +\(lqexternal tables\(rq)\&. If +\fIpattern\fR +is specified, only entries whose table name or schema name matches the pattern are listed\&. If the form +\edet+ +is used, generic options and the foreign table description are also displayed\&. +.RE +.PP +\edeu[+] [ \fIpattern\fR ] +.RS 4 +Lists user mappings (mnemonic: +\(lqexternal users\(rq)\&. If +\fIpattern\fR +is specified, only those mappings whose user names match the pattern are listed\&. If the form +\edeu+ +is used, additional information about each mapping is shown\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBCaution\fR +.ps -1 +.br + +\edeu+ +might also display the user name and password of the remote user, so care should be taken not to disclose them\&. +.sp .5v +.RE +.RE +.PP +\edew[+] [ \fIpattern\fR ] +.RS 4 +Lists foreign\-data wrappers (mnemonic: +\(lqexternal wrappers\(rq)\&. If +\fIpattern\fR +is specified, only those foreign\-data wrappers whose name matches the pattern are listed\&. If the form +\edew+ +is used, the ACL, options, and description of the foreign\-data wrapper are also shown\&. +.RE +.PP +\edf[antwS+] [ \fIpattern\fR ] +.RS 4 +Lists functions, together with their arguments, return types, and function types, which are classified as +\(lqagg\(rq +(aggregate), +\(lqnormal\(rq, +\(lqtrigger\(rq, or +\(lqwindow\(rq\&. To display only functions of specific type(s), add the corresponding letters +a, +n, +t, or +w +to the command\&. If +\fIpattern\fR +is specified, only functions whose names match the pattern are shown\&. If the form +\edf+ +is used, additional information about each function, including volatility, language, source code and description, is shown\&. By default, only user\-created objects are shown; supply a pattern or the +S +modifier to include system objects\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBTip\fR +.ps -1 +.br +To look up functions taking arguments or returning values of a specific type, use your pager\*(Aqs search capability to scroll through the +\edf +output\&. +.sp .5v +.RE +.RE +.PP +\edF[+] [ \fIpattern\fR ] +.RS 4 +Lists text search configurations\&. If +\fIpattern\fR +is specified, only configurations whose names match the pattern are shown\&. If the form +\edF+ +is used, a full description of each configuration is shown, including the underlying text search parser and the dictionary list for each parser token type\&. +.RE +.PP +\edFd[+] [ \fIpattern\fR ] +.RS 4 +Lists text search dictionaries\&. If +\fIpattern\fR +is specified, only dictionaries whose names match the pattern are shown\&. If the form +\edFd+ +is used, additional information is shown about each selected dictionary, including the underlying text search template and the option values\&. +.RE +.PP +\edFp[+] [ \fIpattern\fR ] +.RS 4 +Lists text search parsers\&. If +\fIpattern\fR +is specified, only parsers whose names match the pattern are shown\&. If the form +\edFp+ +is used, a full description of each parser is shown, including the underlying functions and the list of recognized token types\&. +.RE +.PP +\edFt[+] [ \fIpattern\fR ] +.RS 4 +Lists text search templates\&. If +\fIpattern\fR +is specified, only templates whose names match the pattern are shown\&. If the form +\edFt+ +is used, additional information is shown about each template, including the underlying function names\&. +.RE +.PP +\edg[+] [ \fIpattern\fR ] +.RS 4 +Lists database roles\&. (Since the concepts of +\(lqusers\(rq +and +\(lqgroups\(rq +have been unified into +\(lqroles\(rq, this command is now equivalent to +\edu\&.) If +\fIpattern\fR +is specified, only those roles whose names match the pattern are listed\&. If the form +\edg+ +is used, additional information is shown about each role; currently this adds the comment for each role\&. +.RE +.PP +\edl +.RS 4 +This is an alias for +\fB\elo_list\fR, which shows a list of large objects\&. +.RE +.PP +\edL[S+] [ \fIpattern\fR ] +.RS 4 +Lists procedural languages\&. If +\fIpattern\fR +is specified, only languages whose names match the pattern are listed\&. By default, only user\-created languages are shown; supply the +S +modifier to include system objects\&. If ++ +is appended to the command name, each language is listed with its call handler, validator, access privileges, and whether it is a system object\&. +.RE +.PP +\edn[S+] [ \fIpattern\fR ] +.RS 4 +Lists schemas (namespaces)\&. If +\fIpattern\fR +is specified, only schemas whose names match the pattern are listed\&. By default, only user\-created objects are shown; supply a pattern or the +S +modifier to include system objects\&. If ++ +is appended to the command name, each object is listed with its associated permissions and description, if any\&. +.RE +.PP +\edo[S] [ \fIpattern\fR ] +.RS 4 +Lists operators with their operand and return types\&. If +\fIpattern\fR +is specified, only operators whose names match the pattern are listed\&. By default, only user\-created objects are shown; supply a pattern or the +S +modifier to include system objects\&. +.RE +.PP +\edO[S+] [ \fIpattern\fR ] +.RS 4 +Lists collations\&. If +\fIpattern\fR +is specified, only collations whose names match the pattern are listed\&. By default, only user\-created objects are shown; supply a pattern or the +S +modifier to include system objects\&. If ++ +is appended to the command name, each collation is listed with its associated description, if any\&. Note that only collations usable with the current database\*(Aqs encoding are shown, so the results may vary in different databases of the same installation\&. +.RE +.PP +\edp [ \fIpattern\fR ] +.RS 4 +Lists tables, views and sequences with their associated access privileges\&. If +\fIpattern\fR +is specified, only tables, views and sequences whose names match the pattern are listed\&. +.sp +The +\fBGRANT\fR(7) +and +\fBREVOKE\fR(7) +commands are used to set access privileges\&. The meaning of the privilege display is explained under +\fBGRANT\fR(7)\&. +.RE +.PP +\edrds [ \fIrole\-pattern\fR [ \fIdatabase\-pattern\fR ] ] +.RS 4 +Lists defined configuration settings\&. These settings can be role\-specific, database\-specific, or both\&. +\fIrole\-pattern\fR +and +\fIdatabase\-pattern\fR +are used to select specific roles and databases to list, respectively\&. If omitted, or if +* +is specified, all settings are listed, including those not role\-specific or database\-specific, respectively\&. +.sp +The +ALTER ROLE (\fBALTER_ROLE\fR(7)) +and +ALTER DATABASE (\fBALTER_DATABASE\fR(7)) +commands are used to define per\-role and per\-database configuration settings\&. +.RE +.PP +\edT[S+] [ \fIpattern\fR ] +.RS 4 +Lists data types\&. If +\fIpattern\fR +is specified, only types whose names match the pattern are listed\&. If ++ +is appended to the command name, each type is listed with its internal name and size, its allowed values if it is an +enum +type, and its associated permissions\&. By default, only user\-created objects are shown; supply a pattern or the +S +modifier to include system objects\&. +.RE +.PP +\edu[+] [ \fIpattern\fR ] +.RS 4 +Lists database roles\&. (Since the concepts of +\(lqusers\(rq +and +\(lqgroups\(rq +have been unified into +\(lqroles\(rq, this command is now equivalent to +\edg\&.) If +\fIpattern\fR +is specified, only those roles whose names match the pattern are listed\&. If the form +\edu+ +is used, additional information is shown about each role; currently this adds the comment for each role\&. +.RE +.PP +\edx[+] [ \fIpattern\fR ] +.RS 4 +Lists installed extensions\&. If +\fIpattern\fR +is specified, only those extensions whose names match the pattern are listed\&. If the form +\edx+ +is used, all the objects belonging to each matching extension are listed\&. +.RE +.PP +\ee or \eedit [ \fIfilename\fR ] [ \fIline_number\fR ] +.RS 4 +If +\fIfilename\fR +is specified, the file is edited; after the editor exits, its content is copied back to the query buffer\&. If no +\fIfilename\fR +is given, the current query buffer is copied to a temporary file which is then edited in the same fashion\&. +.sp +The new query buffer is then re\-parsed according to the normal rules of +psql, where the whole buffer is treated as a single line\&. (Thus you cannot make scripts this way\&. Use +\fB\ei\fR +for that\&.) This means that if the query ends with (or contains) a semicolon, it is immediately executed\&. Otherwise it will merely wait in the query buffer; type semicolon or +\eg +to send it, or +\er +to cancel\&. +.sp +If a line number is specified, +psql +will position the cursor on the specified line of the file or query buffer\&. Note that if a single all\-digits argument is given, +psql +assumes it is a line number, not a file name\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBTip\fR +.ps -1 +.br +See under +ENVIRONMENT +for how to configure and customize your editor\&. +.sp .5v +.RE +.RE +.PP +\eecho \fItext\fR [ \&.\&.\&. ] +.RS 4 +Prints the arguments to the standard output, separated by one space and followed by a newline\&. This can be useful to intersperse information in the output of scripts\&. For example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +=> \fB\eecho `date`\fR +Tue Oct 26 21:40:57 CEST 1999 +.fi +.if n \{\ +.RE +.\} +.sp +If the first argument is an unquoted +\-n +the trailing newline is not written\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBTip\fR +.ps -1 +.br +If you use the +\fB\eo\fR +command to redirect your query output you might wish to use +\fB\eqecho\fR +instead of this command\&. +.sp .5v +.RE +.RE +.PP +\eef [ \fIfunction_description\fR [ \fIline_number\fR ] ] +.RS 4 +This command fetches and edits the definition of the named function, in the form of a +\fBCREATE OR REPLACE FUNCTION\fR +command\&. Editing is done in the same way as for +\eedit\&. After the editor exits, the updated command waits in the query buffer; type semicolon or +\eg +to send it, or +\er +to cancel\&. +.sp +The target function can be specified by name alone, or by name and arguments, for example +foo(integer, text)\&. The argument types must be given if there is more than one function of the same name\&. +.sp +If no function is specified, a blank +\fBCREATE FUNCTION\fR +template is presented for editing\&. +.sp +If a line number is specified, +psql +will position the cursor on the specified line of the function body\&. (Note that the function body typically does not begin on the first line of the file\&.) +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBTip\fR +.ps -1 +.br +See under +ENVIRONMENT +for how to configure and customize your editor\&. +.sp .5v +.RE +.RE +.PP +\eencoding [ \fIencoding\fR ] +.RS 4 +Sets the client character set encoding\&. Without an argument, this command shows the current encoding\&. +.RE +.PP +\ef [ \fIstring\fR ] +.RS 4 +Sets the field separator for unaligned query output\&. The default is the vertical bar (|)\&. See also +\fB\epset\fR +for a generic way of setting output options\&. +.RE +.PP +\eg [ { \fIfilename\fR | |\fIcommand\fR } ] +.RS 4 +Sends the current query input buffer to the server and optionally stores the query\*(Aqs output in +\fIfilename\fR +or pipes the output into a separate Unix shell executing +\fIcommand\fR\&. A bare +\eg +is virtually equivalent to a semicolon\&. A +\eg +with argument is a +\(lqone\-shot\(rq +alternative to the +\fB\eo\fR +command\&. +.RE +.PP +\eh or \ehelp [ \fIcommand\fR ] +.RS 4 +Gives syntax help on the specified +SQL +command\&. If +\fIcommand\fR +is not specified, then +psql +will list all the commands for which syntax help is available\&. If +\fIcommand\fR +is an asterisk (*), then syntax help on all +SQL +commands is shown\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +To simplify typing, commands that consists of several words do not have to be quoted\&. Thus it is fine to type +\fB\ehelp alter table\fR\&. +.sp .5v +.RE +.RE +.PP +\eH +.RS 4 +Turns on +HTML +query output format\&. If the +HTML +format is already on, it is switched back to the default aligned text format\&. This command is for compatibility and convenience, but see +\fB\epset\fR +about setting other output options\&. +.RE +.PP +\ei \fIfilename\fR +.RS 4 +Reads input from the file +\fIfilename\fR +and executes it as though it had been typed on the keyboard\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +If you want to see the lines on the screen as they are read you must set the variable +\fIECHO\fR +to +all\&. +.sp .5v +.RE +.RE +.PP +\eir \fIfilename\fR +.RS 4 +The +\eir +command is similar to +\ei, but resolves relative file names differently\&. When executing in interactive mode, the two commands behave identically\&. However, when invoked from a script, +\eir +interprets file names relative to the directory in which the script is located, rather than the current working directory\&. +.RE +.PP +\el (or \elist), \el+ (or \elist+) +.RS 4 +List the names, owners, character set encodings, and access privileges of all the databases in the server\&. If ++ +is appended to the command name, database sizes, default tablespaces, and descriptions are also displayed\&. (Size information is only available for databases that the current user can connect to\&.) +.RE +.PP +\elo_export \fIloid\fR \fIfilename\fR +.RS 4 +Reads the large object with +OID +\fIloid\fR +from the database and writes it to +\fIfilename\fR\&. Note that this is subtly different from the server function +\fBlo_export\fR, which acts with the permissions of the user that the database server runs as and on the server\*(Aqs file system\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBTip\fR +.ps -1 +.br +Use +\fB\elo_list\fR +to find out the large object\*(Aqs +OID\&. +.sp .5v +.RE +.RE +.PP +\elo_import \fIfilename\fR [ \fIcomment\fR ] +.RS 4 +Stores the file into a +PostgreSQL +large object\&. Optionally, it associates the given comment with the object\&. Example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +foo=> \fB\elo_import \*(Aq/home/peter/pictures/photo\&.xcf\*(Aq \*(Aqa picture of me\*(Aq\fR +lo_import 152801 +.fi +.if n \{\ +.RE +.\} +.sp +The response indicates that the large object received object ID 152801, which can be used to access the newly\-created large object in the future\&. For the sake of readability, it is recommended to always associate a human\-readable comment with every object\&. Both OIDs and comments can be viewed with the +\fB\elo_list\fR +command\&. +.sp +Note that this command is subtly different from the server\-side +\fBlo_import\fR +because it acts as the local user on the local file system, rather than the server\*(Aqs user and file system\&. +.RE +.PP +\elo_list +.RS 4 +Shows a list of all +PostgreSQL +large objects currently stored in the database, along with any comments provided for them\&. +.RE +.PP +\elo_unlink \fIloid\fR +.RS 4 +Deletes the large object with +OID +\fIloid\fR +from the database\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBTip\fR +.ps -1 +.br +Use +\fB\elo_list\fR +to find out the large object\*(Aqs +OID\&. +.sp .5v +.RE +.RE +.PP +\eo [ {\fIfilename\fR | |\fIcommand\fR} ] +.RS 4 +Saves future query results to the file +\fIfilename\fR +or pipes future results into a separate Unix shell to execute +\fIcommand\fR\&. If no arguments are specified, the query output will be reset to the standard output\&. +.sp +\(lqQuery results\(rq +includes all tables, command responses, and notices obtained from the database server, as well as output of various backslash commands that query the database (such as +\fB\ed\fR), but not error messages\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBTip\fR +.ps -1 +.br +To intersperse text output in between query results, use +\fB\eqecho\fR\&. +.sp .5v +.RE +.RE +.PP +\ep +.RS 4 +Print the current query buffer to the standard output\&. +.RE +.PP +\epassword [ \fIusername\fR ] +.RS 4 +Changes the password of the specified user (by default, the current user)\&. This command prompts for the new password, encrypts it, and sends it to the server as an +\fBALTER ROLE\fR +command\&. This makes sure that the new password does not appear in cleartext in the command history, the server log, or elsewhere\&. +.RE +.PP +\eprompt [ \fItext\fR ] \fIname\fR +.RS 4 +Prompts the user to supply text, which is assigned to the variable +\fIname\fR\&. An optional prompt string, +\fItext\fR, can be specified\&. (For multiword prompts, surround the text with single quotes\&.) +.sp +By default, +\eprompt +uses the terminal for input and output\&. However, if the +\fB\-f\fR +command line switch was used, +\eprompt +uses standard input and standard output\&. +.RE +.PP +\epset \fIoption\fR [ \fIvalue\fR ] +.RS 4 +This command sets options affecting the output of query result tables\&. +\fIoption\fR +indicates which option is to be set\&. The semantics of +\fIvalue\fR +vary depending on the selected option\&. For some options, omitting +\fIvalue\fR +causes the option to be toggled or unset, as described under the particular option\&. If no such behavior is mentioned, then omitting +\fIvalue\fR +just results in the current setting being displayed\&. +.sp +Adjustable printing options are: +.PP +border +.RS 4 +The +\fIvalue\fR +must be a number\&. In general, the higher the number the more borders and lines the tables will have, but this depends on the particular format\&. In +HTML +format, this will translate directly into the +border=\&.\&.\&. +attribute; in the other formats only values 0 (no border), 1 (internal dividing lines), and 2 (table frame) make sense\&. +.RE +.PP +columns +.RS 4 +Sets the target width for the +wrapped +format, and also the width limit for determining whether output is wide enough to require the pager or switch to the vertical display in expanded auto mode\&. Zero (the default) causes the target width to be controlled by the environment variable +\fBCOLUMNS\fR, or the detected screen width if +\fBCOLUMNS\fR +is not set\&. In addition, if +columns +is zero then the +wrapped +format only affects screen output\&. If +columns +is nonzero then file and pipe output is wrapped to that width as well\&. +.RE +.PP +expanded (or x) +.RS 4 +If +\fIvalue\fR +is specified it must be either +on +or +off, which will enable or disable expanded mode, or +auto\&. If +\fIvalue\fR +is omitted the command toggles between the on and off settings\&. When expanded mode is enabled, query results are displayed in two columns, with the column name on the left and the data on the right\&. This mode is useful if the data wouldn\*(Aqt fit on the screen in the normal +\(lqhorizontal\(rq +mode\&. In the auto setting, the expanded mode is used whenever the query output is wider than the screen, otherwise the regular mode is used\&. The auto setting is only effective in the aligned and wrapped formats\&. In other formats, it always behaves as if the expanded mode is off\&. +.RE +.PP +fieldsep +.RS 4 +Specifies the field separator to be used in unaligned output format\&. That way one can create, for example, tab\- or comma\-separated output, which other programs might prefer\&. To set a tab as field separator, type +\epset fieldsep \*(Aq\et\*(Aq\&. The default field separator is +\*(Aq|\*(Aq +(a vertical bar)\&. +.RE +.PP +fieldsep_zero +.RS 4 +Sets the field separator to use in unaligned output format to a zero byte\&. +.RE +.PP +footer +.RS 4 +If +\fIvalue\fR +is specified it must be either +on +or +off +which will enable or disable display of the table footer (the +(\fIn\fR rows) +count)\&. If +\fIvalue\fR +is omitted the command toggles footer display on or off\&. +.RE +.PP +format +.RS 4 +Sets the output format to one of +unaligned, +aligned, +wrapped, +html, +latex, or +troff\-ms\&. Unique abbreviations are allowed\&. (That would mean one letter is enough\&.) +.sp +unaligned +format writes all columns of a row on one line, separated by the currently active field separator\&. This is useful for creating output that might be intended to be read in by other programs (for example, tab\-separated or comma\-separated format)\&. +.sp +aligned +format is the standard, human\-readable, nicely formatted text output; this is the default\&. +.sp +wrapped +format is like +aligned +but wraps wide data values across lines to make the output fit in the target column width\&. The target width is determined as described under the +columns +option\&. Note that +psql +will not attempt to wrap column header titles; therefore, +wrapped +format behaves the same as +aligned +if the total width needed for column headers exceeds the target\&. +.sp +The +html, +latex, and +troff\-ms +formats put out tables that are intended to be included in documents using the respective mark\-up language\&. They are not complete documents! (This might not be so dramatic in +HTML, but in +LaTeX +you must have a complete document wrapper\&.) +.RE +.PP +linestyle +.RS 4 +Sets the border line drawing style to one of +ascii, +old\-ascii +or +unicode\&. Unique abbreviations are allowed\&. (That would mean one letter is enough\&.) The default setting is +ascii\&. This option only affects the +aligned +and +wrapped +output formats\&. +.sp +ascii +style uses plain +ASCII +characters\&. Newlines in data are shown using a ++ +symbol in the right\-hand margin\&. When the +wrapped +format wraps data from one line to the next without a newline character, a dot (\&.) is shown in the right\-hand margin of the first line, and again in the left\-hand margin of the following line\&. +.sp +old\-ascii +style uses plain +ASCII +characters, using the formatting style used in +PostgreSQL +8\&.4 and earlier\&. Newlines in data are shown using a +: +symbol in place of the left\-hand column separator\&. When the data is wrapped from one line to the next without a newline character, a +; +symbol is used in place of the left\-hand column separator\&. +.sp +unicode +style uses Unicode box\-drawing characters\&. Newlines in data are shown using a carriage return symbol in the right\-hand margin\&. When the data is wrapped from one line to the next without a newline character, an ellipsis symbol is shown in the right\-hand margin of the first line, and again in the left\-hand margin of the following line\&. +.sp +When the +border +setting is greater than zero, this option also determines the characters with which the border lines are drawn\&. Plain +ASCII +characters work everywhere, but Unicode characters look nicer on displays that recognize them\&. +.RE +.PP +null +.RS 4 +Sets the string to be printed in place of a null value\&. The default is to print nothing, which can easily be mistaken for an empty string\&. For example, one might prefer +\epset null \*(Aq(null)\*(Aq\&. +.RE +.PP +numericlocale +.RS 4 +If +\fIvalue\fR +is specified it must be either +on +or +off +which will enable or disable display of a locale\-specific character to separate groups of digits to the left of the decimal marker\&. If +\fIvalue\fR +is omitted the command toggles between regular and locale\-specific numeric output\&. +.RE +.PP +pager +.RS 4 +Controls use of a pager program for query and +psql +help output\&. If the environment variable +\fBPAGER\fR +is set, the output is piped to the specified program\&. Otherwise a platform\-dependent default (such as +more) is used\&. +.sp +When the +pager +option is +off, the pager program is not used\&. When the +pager +option is +on, the pager is used when appropriate, i\&.e\&., when the output is to a terminal and will not fit on the screen\&. The +pager +option can also be set to +always, which causes the pager to be used for all terminal output regardless of whether it fits on the screen\&. +\epset pager +without a +\fIvalue\fR +toggles pager use on and off\&. +.RE +.PP +recordsep +.RS 4 +Specifies the record (line) separator to use in unaligned output format\&. The default is a newline character\&. +.RE +.PP +recordsep_zero +.RS 4 +Sets the record separator to use in unaligned output format to a zero byte\&. +.RE +.PP +tableattr (or T) +.RS 4 +Specifies attributes to be placed inside the +HTML +table +tag in +html +output format\&. This could for example be +cellpadding +or +bgcolor\&. Note that you probably don\*(Aqt want to specify +border +here, as that is already taken care of by +\epset border\&. If no +\fIvalue\fR +is given, the table attributes are unset\&. +.RE +.PP +title +.RS 4 +Sets the table title for any subsequently printed tables\&. This can be used to give your output descriptive tags\&. If no +\fIvalue\fR +is given, the title is unset\&. +.RE +.PP +tuples_only (or t) +.RS 4 +If +\fIvalue\fR +is specified it must be either +on +or +off +which will enable or disable tuples\-only mode\&. If +\fIvalue\fR +is omitted the command toggles between regular and tuples\-only output\&. Regular output includes extra information such as column headers, titles, and various footers\&. In tuples\-only mode, only actual table data is shown\&. +.RE +.sp +Illustrations of how these different formats look can be seen in the +EXAMPLES +section\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBTip\fR +.ps -1 +.br +There are various shortcut commands for +\fB\epset\fR\&. See +\fB\ea\fR, +\fB\eC\fR, +\fB\eH\fR, +\fB\et\fR, +\fB\eT\fR, and +\fB\ex\fR\&. +.sp .5v +.RE +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +It is an error to call +\fB\epset\fR +without any arguments\&. In the future this case might show the current status of all printing options\&. +.sp .5v +.RE +.RE +.PP +\eq or \equit +.RS 4 +Quits the +psql +program\&. In a script file, only execution of that script is terminated\&. +.RE +.PP +\eqecho \fItext\fR [ \&.\&.\&. ] +.RS 4 +This command is identical to +\fB\eecho\fR +except that the output will be written to the query output channel, as set by +\fB\eo\fR\&. +.RE +.PP +\er +.RS 4 +Resets (clears) the query buffer\&. +.RE +.PP +\es [ \fIfilename\fR ] +.RS 4 +Print or save the command line history to +\fIfilename\fR\&. If +\fIfilename\fR +is omitted, the history is written to the standard output\&. This option is only available if +psql +is configured to use the +GNU +Readline +library\&. +.RE +.PP +\eset [ \fIname\fR [ \fIvalue\fR [ \&.\&.\&. ] ] ] +.RS 4 +Sets the +psql +variable +\fIname\fR +to +\fIvalue\fR, or if more than one value is given, to the concatenation of all of them\&. If only one argument is given, the variable is set with an empty value\&. To unset a variable, use the +\fB\eunset\fR +command\&. +.sp +\fB\eset\fR +without any arguments displays the names and values of all currently\-set +psql +variables\&. +.sp +Valid variable names can contain letters, digits, and underscores\&. See the section +Variables +below for details\&. Variable names are case\-sensitive\&. +.sp +Although you are welcome to set any variable to anything you want, +psql +treats several variables as special\&. They are documented in the section about variables\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +This command is unrelated to the +SQL +command +\fBSET\fR(7)\&. +.sp .5v +.RE +.RE +.PP +\esetenv [ \fIname\fR [ \fIvalue\fR ] ] +.RS 4 +Sets the environment variable +\fIname\fR +to +\fIvalue\fR, or if the +\fIvalue\fR +is not supplied, unsets the environment variable\&. Example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +testdb=> \fB\esetenv PAGER less\fR +testdb=> \fB\esetenv LESS \-imx4F\fR +.fi +.if n \{\ +.RE +.\} +.RE +.PP +\esf[+] \fIfunction_description\fR +.RS 4 +This command fetches and shows the definition of the named function, in the form of a +\fBCREATE OR REPLACE FUNCTION\fR +command\&. The definition is printed to the current query output channel, as set by +\fB\eo\fR\&. +.sp +The target function can be specified by name alone, or by name and arguments, for example +foo(integer, text)\&. The argument types must be given if there is more than one function of the same name\&. +.sp +If ++ +is appended to the command name, then the output lines are numbered, with the first line of the function body being line 1\&. +.RE +.PP +\et +.RS 4 +Toggles the display of output column name headings and row count footer\&. This command is equivalent to +\epset tuples_only +and is provided for convenience\&. +.RE +.PP +\eT \fItable_options\fR +.RS 4 +Specifies attributes to be placed within the +table +tag in +HTML +output format\&. This command is equivalent to +\epset tableattr \fItable_options\fR\&. +.RE +.PP +\etiming [ \fIon\fR | \fIoff\fR ] +.RS 4 +Without parameter, toggles a display of how long each SQL statement takes, in milliseconds\&. With parameter, sets same\&. +.RE +.PP +\eunset \fIname\fR +.RS 4 +Unsets (deletes) the +psql +variable +\fIname\fR\&. +.RE +.PP +\ew \fIfilename\fR, \ew |\fIcommand\fR +.RS 4 +Outputs the current query buffer to the file +\fIfilename\fR +or pipes it to the Unix command +\fIcommand\fR\&. +.RE +.PP +\ex [ \fIon\fR | \fIoff\fR | \fIauto\fR ] +.RS 4 +Sets or toggles expanded table formatting mode\&. As such it is equivalent to +\epset expanded\&. +.RE +.PP +\ez [ \fIpattern\fR ] +.RS 4 +Lists tables, views and sequences with their associated access privileges\&. If a +\fIpattern\fR +is specified, only tables, views and sequences whose names match the pattern are listed\&. +.sp +This is an alias for +\fB\edp\fR +(\(lqdisplay privileges\(rq)\&. +.RE +.PP +\e! [ \fIcommand\fR ] +.RS 4 +Escapes to a separate Unix shell or executes the Unix command +\fIcommand\fR\&. The arguments are not further interpreted; the shell will see them as\-is\&. +.RE +.PP +\e? +.RS 4 +Shows help information about the backslash commands\&. +.RE +.sp +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBPatterns\fR +.RS 4 +.\" patterns: in psql and pg_dump +.PP +The various +\ed +commands accept a +\fIpattern\fR +parameter to specify the object name(s) to be displayed\&. In the simplest case, a pattern is just the exact name of the object\&. The characters within a pattern are normally folded to lower case, just as in SQL names; for example, +\edt FOO +will display the table named +foo\&. As in SQL names, placing double quotes around a pattern stops folding to lower case\&. Should you need to include an actual double quote character in a pattern, write it as a pair of double quotes within a double\-quote sequence; again this is in accord with the rules for SQL quoted identifiers\&. For example, +\edt "FOO""BAR" +will display the table named +FOO"BAR +(not +foo"bar)\&. Unlike the normal rules for SQL names, you can put double quotes around just part of a pattern, for instance +\edt FOO"FOO"BAR +will display the table named +fooFOObar\&. +.PP +Whenever the +\fIpattern\fR +parameter is omitted completely, the +\ed +commands display all objects that are visible in the current schema search path \(em this is equivalent to using +* +as the pattern\&. (An object is said to be +visible +if its containing schema is in the search path and no object of the same kind and name appears earlier in the search path\&. This is equivalent to the statement that the object can be referenced by name without explicit schema qualification\&.) To see all objects in the database regardless of visibility, use +*\&.* +as the pattern\&. +.PP +Within a pattern, +* +matches any sequence of characters (including no characters) and +? +matches any single character\&. (This notation is comparable to Unix shell file name patterns\&.) For example, +\edt int* +displays tables whose names begin with +int\&. But within double quotes, +* +and +? +lose these special meanings and are just matched literally\&. +.PP +A pattern that contains a dot (\&.) is interpreted as a schema name pattern followed by an object name pattern\&. For example, +\edt foo*\&.*bar* +displays all tables whose table name includes +bar +that are in schemas whose schema name starts with +foo\&. When no dot appears, then the pattern matches only objects that are visible in the current schema search path\&. Again, a dot within double quotes loses its special meaning and is matched literally\&. +.PP +Advanced users can use regular\-expression notations such as character classes, for example +[0\-9] +to match any digit\&. All regular expression special characters work as specified in +Section 9.7.3, \(lqPOSIX Regular Expressions\(rq, in the documentation, except for +\&. +which is taken as a separator as mentioned above, +* +which is translated to the regular\-expression notation +\&.*, +? +which is translated to +\&., and +$ +which is matched literally\&. You can emulate these pattern characters at need by writing +? +for +\&., +(\fIR\fR+|) +for +\fIR\fR*, or +(\fIR\fR|) +for +\fIR\fR?\&. +$ +is not needed as a regular\-expression character since the pattern must match the whole name, unlike the usual interpretation of regular expressions (in other words, +$ +is automatically appended to your pattern)\&. Write +* +at the beginning and/or end if you don\*(Aqt wish the pattern to be anchored\&. Note that within double quotes, all regular expression special characters lose their special meanings and are matched literally\&. Also, the regular expression special characters are matched literally in operator name patterns (i\&.e\&., the argument of +\edo)\&. +.RE +.SS "Advanced Features" +.sp +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBVariables\fR +.RS 4 +.PP + +psql +provides variable substitution features similar to common Unix command shells\&. Variables are simply name/value pairs, where the value can be any string of any length\&. The name must consist of letters (including non\-Latin letters), digits, and underscores\&. +.PP +To set a variable, use the +psql +meta\-command +\fB\eset\fR\&. For example, +.sp +.if n \{\ +.RS 4 +.\} +.nf +testdb=> \fB\eset foo bar\fR +.fi +.if n \{\ +.RE +.\} +.sp +sets the variable +foo +to the value +bar\&. To retrieve the content of the variable, precede the name with a colon, for example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +testdb=> \fB\eecho :foo\fR +bar +.fi +.if n \{\ +.RE +.\} +.sp +This works in both regular SQL commands and meta\-commands; there is more detail in +SQL Interpolation, below\&. +.PP +If you call +\fB\eset\fR +without a second argument, the variable is set, with an empty string as value\&. To unset (i\&.e\&., delete) a variable, use the command +\fB\eunset\fR\&. To show the values of all variables, call +\fB\eset\fR +without any argument\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +.PP +The arguments of +\fB\eset\fR +are subject to the same substitution rules as with other commands\&. Thus you can construct interesting references such as +\eset :foo \*(Aqsomething\*(Aq +and get +\(lqsoft links\(rq +or +\(lqvariable variables\(rq +of +Perl +or +PHP +fame, respectively\&. Unfortunately (or fortunately?), there is no way to do anything useful with these constructs\&. On the other hand, +\eset bar :foo +is a perfectly valid way to copy a variable\&. +.sp .5v +.RE +.PP +A number of these variables are treated specially by +psql\&. They represent certain option settings that can be changed at run time by altering the value of the variable, or in some cases represent changeable state of +psql\&. Although you can use these variables for other purposes, this is not recommended, as the program behavior might grow really strange really quickly\&. By convention, all specially treated variables\*(Aq names consist of all upper\-case ASCII letters (and possibly digits and underscores)\&. To ensure maximum compatibility in the future, avoid using such variable names for your own purposes\&. A list of all specially treated variables follows\&. +.PP +\fIAUTOCOMMIT\fR +.RS 4 +.\" autocommit: psql +When +on +(the default), each SQL command is automatically committed upon successful completion\&. To postpone commit in this mode, you must enter a +\fBBEGIN\fR +or +\fBSTART TRANSACTION\fR +SQL command\&. When +off +or unset, SQL commands are not committed until you explicitly issue +\fBCOMMIT\fR +or +\fBEND\fR\&. The autocommit\-off mode works by issuing an implicit +\fBBEGIN\fR +for you, just before any command that is not already in a transaction block and is not itself a +\fBBEGIN\fR +or other transaction\-control command, nor a command that cannot be executed inside a transaction block (such as +\fBVACUUM\fR)\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +In autocommit\-off mode, you must explicitly abandon any failed transaction by entering +\fBABORT\fR +or +\fBROLLBACK\fR\&. Also keep in mind that if you exit the session without committing, your work will be lost\&. +.sp .5v +.RE +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +The autocommit\-on mode is +PostgreSQL\*(Aqs traditional behavior, but autocommit\-off is closer to the SQL spec\&. If you prefer autocommit\-off, you might wish to set it in the system\-wide +psqlrc +file or your +~/\&.psqlrc +file\&. +.sp .5v +.RE +.RE +.PP +\fICOMP_KEYWORD_CASE\fR +.RS 4 +Determines which letter case to use when completing an SQL key word\&. If set to +lower +or +upper, the completed word will be in lower or upper case, respectively\&. If set to +preserve\-lower +or +preserve\-upper +(the default), the completed word will be in the case of the word already entered, but words being completed without anything entered will be in lower or upper case, respectively\&. +.RE +.PP +\fIDBNAME\fR +.RS 4 +The name of the database you are currently connected to\&. This is set every time you connect to a database (including program start\-up), but can be unset\&. +.RE +.PP +\fIECHO\fR +.RS 4 +If set to +all, all lines entered from the keyboard or from a script are written to the standard output before they are parsed or executed\&. To select this behavior on program start\-up, use the switch +\fB\-a\fR\&. If set to +queries, +psql +merely prints all queries as they are sent to the server\&. The switch for this is +\fB\-e\fR\&. +.RE +.PP +\fIECHO_HIDDEN\fR +.RS 4 +When this variable is set and a backslash command queries the database, the query is first shown\&. This way you can study the +PostgreSQL +internals and provide similar functionality in your own programs\&. (To select this behavior on program start\-up, use the switch +\fB\-E\fR\&.) If you set the variable to the value +noexec, the queries are just shown but are not actually sent to the server and executed\&. +.RE +.PP +\fIENCODING\fR +.RS 4 +The current client character set encoding\&. +.RE +.PP +\fIFETCH_COUNT\fR +.RS 4 +If this variable is set to an integer value > 0, the results of +\fBSELECT\fR +queries are fetched and displayed in groups of that many rows, rather than the default behavior of collecting the entire result set before display\&. Therefore only a limited amount of memory is used, regardless of the size of the result set\&. Settings of 100 to 1000 are commonly used when enabling this feature\&. Keep in mind that when using this feature, a query might fail after having already displayed some rows\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBTip\fR +.ps -1 +.br +Although you can use any output format with this feature, the default +aligned +format tends to look bad because each group of +\fIFETCH_COUNT\fR +rows will be formatted separately, leading to varying column widths across the row groups\&. The other output formats work better\&. +.sp .5v +.RE +.RE +.PP +\fIHISTCONTROL\fR +.RS 4 +If this variable is set to +ignorespace, lines which begin with a space are not entered into the history list\&. If set to a value of +ignoredups, lines matching the previous history line are not entered\&. A value of +ignoreboth +combines the two options\&. If unset, or if set to any other value than those above, all lines read in interactive mode are saved on the history list\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +This feature was shamelessly plagiarized from +Bash\&. +.sp .5v +.RE +.RE +.PP +\fIHISTFILE\fR +.RS 4 +The file name that will be used to store the history list\&. The default value is +~/\&.psql_history\&. For example, putting: +.sp +.if n \{\ +.RS 4 +.\} +.nf +\eset HISTFILE ~/\&.psql_history\- :DBNAME +.fi +.if n \{\ +.RE +.\} +.sp +in +~/\&.psqlrc +will cause +psql +to maintain a separate history for each database\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +This feature was shamelessly plagiarized from +Bash\&. +.sp .5v +.RE +.RE +.PP +\fIHISTSIZE\fR +.RS 4 +The number of commands to store in the command history\&. The default value is 500\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +This feature was shamelessly plagiarized from +Bash\&. +.sp .5v +.RE +.RE +.PP +\fIHOST\fR +.RS 4 +The database server host you are currently connected to\&. This is set every time you connect to a database (including program start\-up), but can be unset\&. +.RE +.PP +\fIIGNOREEOF\fR +.RS 4 +If unset, sending an +EOF +character (usually +Control+D) to an interactive session of +psql +will terminate the application\&. If set to a numeric value, that many +EOF +characters are ignored before the application terminates\&. If the variable is set but has no numeric value, the default is 10\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +This feature was shamelessly plagiarized from +Bash\&. +.sp .5v +.RE +.RE +.PP +\fILASTOID\fR +.RS 4 +The value of the last affected OID, as returned from an +\fBINSERT\fR +or +\fB\elo_import\fR +command\&. This variable is only guaranteed to be valid until after the result of the next +SQL +command has been displayed\&. +.RE +.PP +\fION_ERROR_ROLLBACK\fR +.RS 4 +.\" rollback: psql +When +on, if a statement in a transaction block generates an error, the error is ignored and the transaction continues\&. When +interactive, such errors are only ignored in interactive sessions, and not when reading script files\&. When +off +(the default), a statement in a transaction block that generates an error aborts the entire transaction\&. The on_error_rollback\-on mode works by issuing an implicit +\fBSAVEPOINT\fR +for you, just before each command that is in a transaction block, and rolls back to the savepoint on error\&. +.RE +.PP +\fION_ERROR_STOP\fR +.RS 4 +By default, command processing continues after an error\&. When this variable is set, it will instead stop immediately\&. In interactive mode, +psql +will return to the command prompt; otherwise, +psql +will exit, returning error code 3 to distinguish this case from fatal error conditions, which are reported using error code 1\&. In either case, any currently running scripts (the top\-level script, if any, and any other scripts which it may have in invoked) will be terminated immediately\&. If the top\-level command string contained multiple SQL commands, processing will stop with the current command\&. +.RE +.PP +\fIPORT\fR +.RS 4 +The database server port to which you are currently connected\&. This is set every time you connect to a database (including program start\-up), but can be unset\&. +.RE +.PP +\fIPROMPT1\fR, \fIPROMPT2\fR, \fIPROMPT3\fR +.RS 4 +These specify what the prompts +psql +issues should look like\&. See +Prompting +below\&. +.RE +.PP +\fIQUIET\fR +.RS 4 +This variable is equivalent to the command line option +\fB\-q\fR\&. It is probably not too useful in interactive mode\&. +.RE +.PP +\fISINGLELINE\fR +.RS 4 +This variable is equivalent to the command line option +\fB\-S\fR\&. +.RE +.PP +\fISINGLESTEP\fR +.RS 4 +This variable is equivalent to the command line option +\fB\-s\fR\&. +.RE +.PP +\fIUSER\fR +.RS 4 +The database user you are currently connected as\&. This is set every time you connect to a database (including program start\-up), but can be unset\&. +.RE +.PP +\fIVERBOSITY\fR +.RS 4 +This variable can be set to the values +default, +verbose, or +terse +to control the verbosity of error reports\&. +.RE +.RE +.sp +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBSQL Interpolation\fR +.RS 4 +.PP +A key feature of +psql +variables is that you can substitute (\(lqinterpolate\(rq) them into regular +SQL +statements, as well as the arguments of meta\-commands\&. Furthermore, +psql +provides facilities for ensuring that variable values used as SQL literals and identifiers are properly quoted\&. The syntax for interpolating a value without any quoting is to prepend the variable name with a colon (:)\&. For example, +.sp +.if n \{\ +.RS 4 +.\} +.nf +testdb=> \fB\eset foo \*(Aqmy_table\*(Aq\fR +testdb=> \fBSELECT * FROM :foo;\fR +.fi +.if n \{\ +.RE +.\} +.sp +would query the table +my_table\&. Note that this may be unsafe: the value of the variable is copied literally, so it can contain unbalanced quotes, or even backslash commands\&. You must make sure that it makes sense where you put it\&. +.PP +When a value is to be used as an SQL literal or identifier, it is safest to arrange for it to be quoted\&. To quote the value of a variable as an SQL literal, write a colon followed by the variable name in single quotes\&. To quote the value as an SQL identifier, write a colon followed by the variable name in double quotes\&. These constructs deal correctly with quotes and other special characters embedded within the variable value\&. The previous example would be more safely written this way: +.sp +.if n \{\ +.RS 4 +.\} +.nf +testdb=> \fB\eset foo \*(Aqmy_table\*(Aq\fR +testdb=> \fBSELECT * FROM :"foo";\fR +.fi +.if n \{\ +.RE +.\} +.PP +Variable interpolation will not be performed within quoted +SQL +literals and identifiers\&. Therefore, a construction such as +\*(Aq:foo\*(Aq +doesn\*(Aqt work to produce a quoted literal from a variable\*(Aqs value (and it would be unsafe if it did work, since it wouldn\*(Aqt correctly handle quotes embedded in the value)\&. +.PP +One example use of this mechanism is to copy the contents of a file into a table column\&. First load the file into a variable and then interpolate the variable\*(Aqs value as a quoted string: +.sp +.if n \{\ +.RS 4 +.\} +.nf +testdb=> \fB\eset content `cat my_file\&.txt`\fR +testdb=> \fBINSERT INTO my_table VALUES (:\*(Aqcontent\*(Aq);\fR +.fi +.if n \{\ +.RE +.\} +.sp +(Note that this still won\*(Aqt work if +my_file\&.txt +contains NUL bytes\&. +psql +does not support embedded NUL bytes in variable values\&.) +.PP +Since colons can legally appear in SQL commands, an apparent attempt at interpolation (that is, +:name, +:\*(Aqname\*(Aq, or +:"name") is not replaced unless the named variable is currently set\&. In any case, you can escape a colon with a backslash to protect it from substitution\&. +.PP +The colon syntax for variables is standard +SQL +for embedded query languages, such as +ECPG\&. The colon syntaxes for array slices and type casts are +PostgreSQL +extensions, which can sometimes conflict with the standard usage\&. The colon\-quote syntax for escaping a variable\*(Aqs value as an SQL literal or identifier is a +psql +extension\&. +.RE +.sp +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBPrompting\fR +.RS 4 +.PP +The prompts +psql +issues can be customized to your preference\&. The three variables +\fIPROMPT1\fR, +\fIPROMPT2\fR, and +\fIPROMPT3\fR +contain strings and special escape sequences that describe the appearance of the prompt\&. Prompt 1 is the normal prompt that is issued when +psql +requests a new command\&. Prompt 2 is issued when more input is expected during command input because the command was not terminated with a semicolon or a quote was not closed\&. Prompt 3 is issued when you run an +SQL +\fBCOPY\fR +command and you are expected to type in the row values on the terminal\&. +.PP +The value of the selected prompt variable is printed literally, except where a percent sign (%) is encountered\&. Depending on the next character, certain other text is substituted instead\&. Defined substitutions are: +.PP +%M +.RS 4 +The full host name (with domain name) of the database server, or +[local] +if the connection is over a Unix domain socket, or +[local:\fI/dir/name\fR], if the Unix domain socket is not at the compiled in default location\&. +.RE +.PP +%m +.RS 4 +The host name of the database server, truncated at the first dot, or +[local] +if the connection is over a Unix domain socket\&. +.RE +.PP +%> +.RS 4 +The port number at which the database server is listening\&. +.RE +.PP +%n +.RS 4 +The database session user name\&. (The expansion of this value might change during a database session as the result of the command +\fBSET SESSION AUTHORIZATION\fR\&.) +.RE +.PP +%/ +.RS 4 +The name of the current database\&. +.RE +.PP +%~ +.RS 4 +Like +%/, but the output is +~ +(tilde) if the database is your default database\&. +.RE +.PP +%# +.RS 4 +If the session user is a database superuser, then a +#, otherwise a +>\&. (The expansion of this value might change during a database session as the result of the command +\fBSET SESSION AUTHORIZATION\fR\&.) +.RE +.PP +%R +.RS 4 +In prompt 1 normally +=, but +^ +if in single\-line mode, and +! +if the session is disconnected from the database (which can happen if +\fB\econnect\fR +fails)\&. In prompt 2 the sequence is replaced by +\-, +*, a single quote, a double quote, or a dollar sign, depending on whether +psql +expects more input because the command wasn\*(Aqt terminated yet, because you are inside a +/* \&.\&.\&. */ +comment, or because you are inside a quoted or dollar\-escaped string\&. In prompt 3 the sequence doesn\*(Aqt produce anything\&. +.RE +.PP +%x +.RS 4 +Transaction status: an empty string when not in a transaction block, or +* +when in a transaction block, or +! +when in a failed transaction block, or +? +when the transaction state is indeterminate (for example, because there is no connection)\&. +.RE +.PP +%\fIdigits\fR +.RS 4 +The character with the indicated octal code is substituted\&. +.RE +.PP +%:\fIname\fR: +.RS 4 +The value of the +psql +variable +\fIname\fR\&. See the section +Variables +for details\&. +.RE +.PP +%`\fIcommand\fR` +.RS 4 +The output of +\fIcommand\fR, similar to ordinary +\(lqback\-tick\(rq +substitution\&. +.RE +.PP +%[ \&.\&.\&. %] +.RS 4 +Prompts can contain terminal control characters which, for example, change the color, background, or style of the prompt text, or change the title of the terminal window\&. In order for the line editing features of +Readline +to work properly, these non\-printing control characters must be designated as invisible by surrounding them with +%[ +and +%]\&. Multiple pairs of these can occur within the prompt\&. For example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +testdb=> \eset PROMPT1 \*(Aq%[%033[1;33;40m%]%n@%/%R%[%033[0m%]%# \*(Aq +.fi +.if n \{\ +.RE +.\} +.sp +results in a boldfaced (1;) yellow\-on\-black (33;40) prompt on VT100\-compatible, color\-capable terminals\&. +.RE +To insert a percent sign into your prompt, write +%%\&. The default prompts are +\*(Aq%/%R%# \*(Aq +for prompts 1 and 2, and +\*(Aq>> \*(Aq +for prompt 3\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +.PP +This feature was shamelessly plagiarized from +tcsh\&. +.sp .5v +.RE +.RE +.sp +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBCommand-Line Editing\fR +.RS 4 +.PP + +psql +supports the +Readline +library for convenient line editing and retrieval\&. The command history is automatically saved when +psql +exits and is reloaded when +psql +starts up\&. Tab\-completion is also supported, although the completion logic makes no claim to be an +SQL +parser\&. If for some reason you do not like the tab completion, you can turn it off by putting this in a file named +\&.inputrc +in your home directory: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$if psql +set disable\-completion on +$endif +.fi +.if n \{\ +.RE +.\} +.sp +(This is not a +psql +but a +Readline +feature\&. Read its documentation for further details\&.) +.RE +.SH "ENVIRONMENT" +.PP +\fBCOLUMNS\fR +.RS 4 +If +\epset columns +is zero, controls the width for the +wrapped +format and width for determining if wide output requires the pager or should be switched to the vertical format in expanded auto mode\&. +.RE +.PP +\fBPAGER\fR +.RS 4 +If the query results do not fit on the screen, they are piped through this command\&. Typical values are +more +or +less\&. The default is platform\-dependent\&. The use of the pager can be disabled by using the +\fB\epset\fR +command\&. +.RE +.PP +\fBPGDATABASE\fR, \fBPGHOST\fR, \fBPGPORT\fR, \fBPGUSER\fR +.RS 4 +Default connection parameters (see +Section 31.14, \(lqEnvironment Variables\(rq, in the documentation)\&. +.RE +.PP +\fBPSQL_EDITOR\fR, \fBEDITOR\fR, \fBVISUAL\fR +.RS 4 +Editor used by the +\fB\ee\fR +and +\fB\eef\fR +commands\&. The variables are examined in the order listed; the first that is set is used\&. +.sp +The built\-in default editors are +vi +on Unix systems and +notepad\&.exe +on Windows systems\&. +.RE +.PP +\fBPSQL_EDITOR_LINENUMBER_ARG\fR +.RS 4 +When +\fB\ee\fR +or +\fB\eef\fR +is used with a line number argument, this variable specifies the command\-line argument used to pass the starting line number to the user\*(Aqs editor\&. For editors such as +Emacs +or +vi, this is a plus sign\&. Include a trailing space in the value of the variable if there needs to be space between the option name and the line number\&. Examples: +.sp +.if n \{\ +.RS 4 +.\} +.nf +PSQL_EDITOR_LINENUMBER_ARG=\*(Aq+\*(Aq +PSQL_EDITOR_LINENUMBER_ARG=\*(Aq\-\-line \*(Aq +.fi +.if n \{\ +.RE +.\} +.sp +The default is ++ +on Unix systems (corresponding to the default editor +vi, and useful for many other common editors); but there is no default on Windows systems\&. +.RE +.PP +\fBPSQL_HISTORY\fR +.RS 4 +Alternative location for the command history file\&. Tilde (~) expansion is performed\&. +.RE +.PP +\fBPSQLRC\fR +.RS 4 +Alternative location of the user\*(Aqs +\&.psqlrc +file\&. Tilde (~) expansion is performed\&. +.RE +.PP +\fBSHELL\fR +.RS 4 +Command executed by the +\fB\e!\fR +command\&. +.RE +.PP +\fBTMPDIR\fR +.RS 4 +Directory for storing temporary files\&. The default is +/tmp\&. +.RE +.PP +This utility, like most other +PostgreSQL +utilities, also uses the environment variables supported by +libpq +(see +Section 31.14, \(lqEnvironment Variables\(rq, in the documentation)\&. +.SH "FILES" +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +Unless it is passed an +\fB\-X\fR +or +\fB\-c\fR +option, +psql +attempts to read and execute commands from the system\-wide +psqlrc +file and the user\*(Aqs +~/\&.psqlrc +file before starting up\&. (On Windows, the user\*(Aqs startup file is named +%APPDATA%\epostgresql\epsqlrc\&.conf\&.) See +\fIPREFIX\fR/share/psqlrc\&.sample +for information on setting up the system\-wide file\&. It could be used to set up the client or the server to taste (using the +\fB\eset \fR +and +\fBSET\fR +commands)\&. +.sp +The location of the user\*(Aqs +~/\&.psqlrc +file can also be set explicitly via the +\fBPSQLRC\fR +environment setting\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +Both the system\-wide +psqlrc +file and the user\*(Aqs +~/\&.psqlrc +file can be made +psql\-version\-specific by appending a dash and the +PostgreSQL +major or minor +psql +release number, for example +~/\&.psqlrc\-9\&.2 +or +~/\&.psqlrc\-9\&.2\&.5\&. The most specific version\-matching file will be read in preference to a non\-version\-specific file\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +The command\-line history is stored in the file +~/\&.psql_history, or +%APPDATA%\epostgresql\epsql_history +on Windows\&. +.sp +The location of the history file can also be set explicitly via the +\fBPSQL_HISTORY\fR +environment setting\&. +.RE +.SH "NOTES" +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +In an earlier life +psql +allowed the first argument of a single\-letter backslash command to start directly after the command, without intervening whitespace\&. As of +PostgreSQL +8\&.4 this is no longer allowed\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +psql +is only guaranteed to work smoothly with servers of the same version\&. That does not mean other combinations will fail outright, but subtle and not\-so\-subtle problems might come up\&. Backslash commands are particularly likely to fail if the server is of a newer version than +psql +itself\&. However, backslash commands of the +\ed +family should work with servers of versions back to 7\&.4, though not necessarily with servers newer than +psql +itself\&. +.RE +.SH "NOTES FOR WINDOWS USERS" +.PP + +psql +is built as a +\(lqconsole application\(rq\&. Since the Windows console windows use a different encoding than the rest of the system, you must take special care when using 8\-bit characters within +psql\&. If +psql +detects a problematic console code page, it will warn you at startup\&. To change the console code page, two things are necessary: +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +Set the code page by entering +\fBcmd\&.exe /c chcp 1252\fR\&. (1252 is a code page that is appropriate for German; replace it with your value\&.) If you are using Cygwin, you can put this command in +/etc/profile\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +Set the console font to +Lucida Console, because the raster font does not work with the ANSI code page\&. +.RE +.SH "EXAMPLES" +.PP +The first example shows how to spread a command over several lines of input\&. Notice the changing prompt: +.sp +.if n \{\ +.RS 4 +.\} +.nf +testdb=> \fBCREATE TABLE my_table (\fR +testdb(> \fB first integer not null default 0,\fR +testdb(> \fB second text)\fR +testdb\-> \fB;\fR +CREATE TABLE +.fi +.if n \{\ +.RE +.\} +.sp +Now look at the table definition again: +.sp +.if n \{\ +.RS 4 +.\} +.nf +testdb=> \fB\ed my_table\fR + Table "my_table" + Attribute | Type | Modifier +\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + first | integer | not null default 0 + second | text | +.fi +.if n \{\ +.RE +.\} +.sp +Now we change the prompt to something more interesting: +.sp +.if n \{\ +.RS 4 +.\} +.nf +testdb=> \fB\eset PROMPT1 \*(Aq%n@%m %~%R%# \*(Aq\fR +peter@localhost testdb=> +.fi +.if n \{\ +.RE +.\} +.sp +Let\*(Aqs assume you have filled the table with data and want to take a look at it: +.sp +.if n \{\ +.RS 4 +.\} +.nf +peter@localhost testdb=> SELECT * FROM my_table; + first | second +\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\- + 1 | one + 2 | two + 3 | three + 4 | four +(4 rows) +.fi +.if n \{\ +.RE +.\} +.sp +You can display tables in different ways by using the +\fB\epset\fR +command: +.sp +.if n \{\ +.RS 4 +.\} +.nf +peter@localhost testdb=> \fB\epset border 2\fR +Border style is 2\&. +peter@localhost testdb=> \fBSELECT * FROM my_table;\fR ++\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-+ +| first | second | ++\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-+ +| 1 | one | +| 2 | two | +| 3 | three | +| 4 | four | ++\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-+ +(4 rows) + +peter@localhost testdb=> \fB\epset border 0\fR +Border style is 0\&. +peter@localhost testdb=> \fBSELECT * FROM my_table;\fR +first second +\-\-\-\-\- \-\-\-\-\-\- + 1 one + 2 two + 3 three + 4 four +(4 rows) + +peter@localhost testdb=> \fB\epset border 1\fR +Border style is 1\&. +peter@localhost testdb=> \fB\epset format unaligned\fR +Output format is unaligned\&. +peter@localhost testdb=> \fB\epset fieldsep ","\fR +Field separator is ","\&. +peter@localhost testdb=> \fB\epset tuples_only\fR +Showing only tuples\&. +peter@localhost testdb=> \fBSELECT second, first FROM my_table;\fR +one,1 +two,2 +three,3 +four,4 +.fi +.if n \{\ +.RE +.\} +.sp +Alternatively, use the short commands: +.sp +.if n \{\ +.RS 4 +.\} +.nf +peter@localhost testdb=> \fB\ea \et \ex\fR +Output format is aligned\&. +Tuples only is off\&. +Expanded display is on\&. +peter@localhost testdb=> \fBSELECT * FROM my_table;\fR +\-[ RECORD 1 ]\- +first | 1 +second | one +\-[ RECORD 2 ]\- +first | 2 +second | two +\-[ RECORD 3 ]\- +first | 3 +second | three +\-[ RECORD 4 ]\- +first | 4 +second | four +.fi +.if n \{\ +.RE +.\} + diff --git a/doc/src/sgml/man1/reindexdb.1 b/doc/src/sgml/man1/reindexdb.1 new file mode 100644 index 000000000..bb5805d75 --- /dev/null +++ b/doc/src/sgml/man1/reindexdb.1 @@ -0,0 +1,231 @@ +'\" t +.\" Title: reindexdb +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "REINDEXDB" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +reindexdb \- reindex a PostgreSQL database +.\" reindexdb +.SH "SYNOPSIS" +.HP \w'\fBreindexdb\fR\ 'u +\fBreindexdb\fR [\fIconnection\-option\fR...] [\fB\-\-table\fR | \fB\-t\fR \fItable\fR] [\fB\-\-index\fR | \fB\-i\fR \fIindex\fR] [\fIdbname\fR] +.HP \w'\fBreindexdb\fR\ 'u +\fBreindexdb\fR [\fIconnection\-option\fR...] \fB\-\-all\fR | \fB\-a\fR +.HP \w'\fBreindexdb\fR\ 'u +\fBreindexdb\fR [\fIconnection\-option\fR...] \fB\-\-system\fR | \fB\-s\fR [\fIdbname\fR] +.SH "DESCRIPTION" +.PP + +reindexdb +is a utility for rebuilding indexes in a +PostgreSQL +database\&. +.PP + +reindexdb +is a wrapper around the SQL command +\fBREINDEX\fR(7)\&. There is no effective difference between reindexing databases via this utility and via other methods for accessing the server\&. +.SH "OPTIONS" +.PP + +reindexdb +accepts the following command\-line arguments: +.PP +\fB\-a\fR, \fB\-\-all\fR +.RS 4 +Reindex all databases\&. +.RE +.PP +\fB[\-d]\fR\fB \fR\fB\fIdbname\fR\fR, \fB[\-\-dbname=]\fR\fB\fIdbname\fR\fR +.RS 4 +Specifies the name of the database to be reindexed\&. If this is not specified and +\fB\-a\fR +(or +\fB\-\-all\fR) is not used, the database name is read from the environment variable +\fBPGDATABASE\fR\&. If that is not set, the user name specified for the connection is used\&. +.RE +.PP +\fB\-e\fR, \fB\-\-echo\fR +.RS 4 +Echo the commands that +reindexdb +generates and sends to the server\&. +.RE +.PP +\fB\-i \fR\fB\fIindex\fR\fR, \fB\-\-index=\fR\fB\fIindex\fR\fR +.RS 4 +Recreate +\fIindex\fR +only\&. +.RE +.PP +\fB\-q\fR, \fB\-\-quiet\fR +.RS 4 +Do not display progress messages\&. +.RE +.PP +\fB\-s\fR, \fB\-\-system\fR +.RS 4 +Reindex database\*(Aqs system catalogs\&. +.RE +.PP +\fB\-t \fR\fB\fItable\fR\fR, \fB\-\-table=\fR\fB\fItable\fR\fR +.RS 4 +Reindex +\fItable\fR +only\&. +.RE +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +reindexdb +version and exit\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +reindexdb +command line arguments, and exit\&. +.RE +.PP + +reindexdb +also accepts the following command\-line arguments for connection parameters: +.PP +\fB\-h \fR\fB\fIhost\fR\fR, \fB\-\-host=\fR\fB\fIhost\fR\fR +.RS 4 +Specifies the host name of the machine on which the server is running\&. If the value begins with a slash, it is used as the directory for the Unix domain socket\&. +.RE +.PP +\fB\-p \fR\fB\fIport\fR\fR, \fB\-\-port=\fR\fB\fIport\fR\fR +.RS 4 +Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections\&. +.RE +.PP +\fB\-U \fR\fB\fIusername\fR\fR, \fB\-\-username=\fR\fB\fIusername\fR\fR +.RS 4 +User name to connect as\&. +.RE +.PP +\fB\-w\fR, \fB\-\-no\-password\fR +.RS 4 +Never issue a password prompt\&. If the server requires password authentication and a password is not available by other means such as a +\&.pgpass +file, the connection attempt will fail\&. This option can be useful in batch jobs and scripts where no user is present to enter a password\&. +.RE +.PP +\fB\-W\fR, \fB\-\-password\fR +.RS 4 +Force +reindexdb +to prompt for a password before connecting to a database\&. +.sp +This option is never essential, since +reindexdb +will automatically prompt for a password if the server demands password authentication\&. However, +reindexdb +will waste a connection attempt finding out that the server wants a password\&. In some cases it is worth typing +\fB\-W\fR +to avoid the extra connection attempt\&. +.RE +.PP +\fB\-\-maintenance\-db=\fR\fB\fIdbname\fR\fR +.RS 4 +Specifies the name of the database to connect to discover what other databases should be reindexed\&. If not specified, the +postgres +database will be used, and if that does not exist, +template1 +will be used\&. +.RE +.SH "ENVIRONMENT" +.PP +\fBPGDATABASE\fR, \fBPGHOST\fR, \fBPGPORT\fR, \fBPGUSER\fR +.RS 4 +Default connection parameters +.RE +.PP +This utility, like most other +PostgreSQL +utilities, also uses the environment variables supported by +libpq +(see +Section 31.14, \(lqEnvironment Variables\(rq, in the documentation)\&. +.SH "DIAGNOSTICS" +.PP +In case of difficulty, see +\fBREINDEX\fR(7) +and +\fBpsql\fR(1) +for discussions of potential problems and error messages\&. The database server must be running at the targeted host\&. Also, any default connection settings and environment variables used by the +libpq +front\-end library will apply\&. +.SH "NOTES" +.PP + +reindexdb +might need to connect several times to the +PostgreSQL +server, asking for a password each time\&. It is convenient to have a +~/\&.pgpass +file in such cases\&. See +Section 31.15, \(lqThe Password File\(rq, in the documentation +for more information\&. +.SH "EXAMPLES" +.PP +To reindex the database +test: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBreindexdb test\fR +.fi +.if n \{\ +.RE +.\} +.PP +To reindex the table +foo +and the index +bar +in a database named +abcd: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBreindexdb \-\-table foo \-\-index bar abcd\fR +.fi +.if n \{\ +.RE +.\} +.SH "SEE ALSO" +\fBREINDEX\fR(7) diff --git a/doc/src/sgml/man1/vacuumdb.1 b/doc/src/sgml/man1/vacuumdb.1 new file mode 100644 index 000000000..e5cd9186f --- /dev/null +++ b/doc/src/sgml/man1/vacuumdb.1 @@ -0,0 +1,282 @@ +'\" t +.\" Title: vacuumdb +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "VACUUMDB" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +vacuumdb \- garbage\-collect and analyze a PostgreSQL database +.\" vacuumdb +.SH "SYNOPSIS" +.HP \w'\fBvacuumdb\fR\ 'u +\fBvacuumdb\fR [\fIconnection\-option\fR...] [\fIoption\fR...] [\fB\-\-table\fR\ |\ \fB\-t\fR\ \fItable\fR\ [(\ \fIcolumn\fR\ [,\&.\&.\&.]\ )]] [\fIdbname\fR] +.HP \w'\fBvacuumdb\fR\ 'u +\fBvacuumdb\fR [\fIconnection\-option\fR...] [\fIoption\fR...] \fB\-\-all\fR | \fB\-a\fR +.SH "DESCRIPTION" +.PP + +vacuumdb +is a utility for cleaning a +PostgreSQL +database\&. +vacuumdb +will also generate internal statistics used by the +PostgreSQL +query optimizer\&. +.PP + +vacuumdb +is a wrapper around the SQL command +\fBVACUUM\fR(7)\&. There is no effective difference between vacuuming and analyzing databases via this utility and via other methods for accessing the server\&. +.SH "OPTIONS" +.PP + +vacuumdb +accepts the following command\-line arguments: +.PP +\fB\-a\fR, \fB\-\-all\fR +.RS 4 +Vacuum all databases\&. +.RE +.PP +\fB[\-d]\fR\fB \fR\fB\fIdbname\fR\fR, \fB[\-\-dbname=]\fR\fB\fIdbname\fR\fR +.RS 4 +Specifies the name of the database to be cleaned or analyzed\&. If this is not specified and +\fB\-a\fR +(or +\fB\-\-all\fR) is not used, the database name is read from the environment variable +\fBPGDATABASE\fR\&. If that is not set, the user name specified for the connection is used\&. +.RE +.PP +\fB\-e\fR, \fB\-\-echo\fR +.RS 4 +Echo the commands that +vacuumdb +generates and sends to the server\&. +.RE +.PP +\fB\-f\fR, \fB\-\-full\fR +.RS 4 +Perform +\(lqfull\(rq +vacuuming\&. +.RE +.PP +\fB\-F\fR, \fB\-\-freeze\fR +.RS 4 +Aggressively +\(lqfreeze\(rq +tuples\&. +.RE +.PP +\fB\-q\fR, \fB\-\-quiet\fR +.RS 4 +Do not display progress messages\&. +.RE +.PP +\fB\-t \fR\fB\fItable\fR\fR\fB [ (\fR\fB\fIcolumn\fR\fR\fB [,\&.\&.\&.]) ]\fR, \fB\-\-table=\fR\fB\fItable\fR\fR\fB [ (\fR\fB\fIcolumn\fR\fR\fB [,\&.\&.\&.]) ]\fR +.RS 4 +Clean or analyze +\fItable\fR +only\&. Column names can be specified only in conjunction with the +\fB\-\-analyze\fR +or +\fB\-\-analyze\-only\fR +options\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBTip\fR +.ps -1 +.br +If you specify columns, you probably have to escape the parentheses from the shell\&. (See examples below\&.) +.sp .5v +.RE +.RE +.PP +\fB\-v\fR, \fB\-\-verbose\fR +.RS 4 +Print detailed information during processing\&. +.RE +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +vacuumdb +version and exit\&. +.RE +.PP +\fB\-z\fR, \fB\-\-analyze\fR +.RS 4 +Also calculate statistics for use by the optimizer\&. +.RE +.PP +\fB\-Z\fR, \fB\-\-analyze\-only\fR +.RS 4 +Only calculate statistics for use by the optimizer (no vacuum)\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +vacuumdb +command line arguments, and exit\&. +.RE +.PP + +vacuumdb +also accepts the following command\-line arguments for connection parameters: +.PP +\fB\-h \fR\fB\fIhost\fR\fR, \fB\-\-host=\fR\fB\fIhost\fR\fR +.RS 4 +Specifies the host name of the machine on which the server is running\&. If the value begins with a slash, it is used as the directory for the Unix domain socket\&. +.RE +.PP +\fB\-p \fR\fB\fIport\fR\fR, \fB\-\-port=\fR\fB\fIport\fR\fR +.RS 4 +Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections\&. +.RE +.PP +\fB\-U \fR\fB\fIusername\fR\fR, \fB\-\-username=\fR\fB\fIusername\fR\fR +.RS 4 +User name to connect as\&. +.RE +.PP +\fB\-w\fR, \fB\-\-no\-password\fR +.RS 4 +Never issue a password prompt\&. If the server requires password authentication and a password is not available by other means such as a +\&.pgpass +file, the connection attempt will fail\&. This option can be useful in batch jobs and scripts where no user is present to enter a password\&. +.RE +.PP +\fB\-W\fR, \fB\-\-password\fR +.RS 4 +Force +vacuumdb +to prompt for a password before connecting to a database\&. +.sp +This option is never essential, since +vacuumdb +will automatically prompt for a password if the server demands password authentication\&. However, +vacuumdb +will waste a connection attempt finding out that the server wants a password\&. In some cases it is worth typing +\fB\-W\fR +to avoid the extra connection attempt\&. +.RE +.PP +\fB\-\-maintenance\-db=\fR\fB\fIdbname\fR\fR +.RS 4 +Specifies the name of the database to connect to discover what other databases should be vacuumed\&. If not specified, the +postgres +database will be used, and if that does not exist, +template1 +will be used\&. +.RE +.SH "ENVIRONMENT" +.PP +\fBPGDATABASE\fR, \fBPGHOST\fR, \fBPGPORT\fR, \fBPGUSER\fR +.RS 4 +Default connection parameters +.RE +.PP +This utility, like most other +PostgreSQL +utilities, also uses the environment variables supported by +libpq +(see +Section 31.14, \(lqEnvironment Variables\(rq, in the documentation)\&. +.SH "DIAGNOSTICS" +.PP +In case of difficulty, see +\fBVACUUM\fR(7) +and +\fBpsql\fR(1) +for discussions of potential problems and error messages\&. The database server must be running at the targeted host\&. Also, any default connection settings and environment variables used by the +libpq +front\-end library will apply\&. +.SH "NOTES" +.PP + +vacuumdb +might need to connect several times to the +PostgreSQL +server, asking for a password each time\&. It is convenient to have a +~/\&.pgpass +file in such cases\&. See +Section 31.15, \(lqThe Password File\(rq, in the documentation +for more information\&. +.SH "EXAMPLES" +.PP +To clean the database +test: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBvacuumdb test\fR +.fi +.if n \{\ +.RE +.\} +.PP +To clean and analyze for the optimizer a database named +bigdb: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBvacuumdb \-\-analyze bigdb\fR +.fi +.if n \{\ +.RE +.\} +.PP +To clean a single table +foo +in a database named +xyzzy, and analyze a single column +bar +of the table for the optimizer: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBvacuumdb \-\-analyze \-\-verbose \-\-table \*(Aqfoo(bar)\*(Aq xyzzy\fR +.fi +.if n \{\ +.RE +.\} +.SH "SEE ALSO" +\fBVACUUM\fR(7) diff --git a/doc/src/sgml/man1/vacuumlo.1 b/doc/src/sgml/man1/vacuumlo.1 new file mode 100644 index 000000000..c3668bf20 --- /dev/null +++ b/doc/src/sgml/man1/vacuumlo.1 @@ -0,0 +1,150 @@ +'\" t +.\" Title: vacuumlo +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "VACUUMLO" "1" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +vacuumlo \- remove orphaned large objects from a PostgreSQL database +.\" vacuumlo +.SH "SYNOPSIS" +.HP \w'\fBvacuumlo\fR\ 'u +\fBvacuumlo\fR [\fIoption\fR...] \fIdbname\fR... +.SH "DESCRIPTION" +.PP + +vacuumlo +is a simple utility program that will remove any +\(lqorphaned\(rq +large objects from a +PostgreSQL +database\&. An orphaned large object (LO) is considered to be any LO whose OID does not appear in any +oid +or +lo +data column of the database\&. +.PP +If you use this, you may also be interested in the +\fBlo_manage\fR +trigger in the +lo +module\&. +\fBlo_manage\fR +is useful to try to avoid creating orphaned LOs in the first place\&. +.PP +All databases named on the command line are processed\&. +.SH "OPTIONS" +.PP + +vacuumlo +accepts the following command\-line arguments: +.PP +\fB\-l\fR \fIlimit\fR +.RS 4 +Remove no more than +\fIlimit\fR +large objects per transaction (default 1000)\&. Since the server acquires a lock per LO removed, removing too many LOs in one transaction risks exceeding +max_locks_per_transaction\&. Set the limit to zero if you want all removals done in a single transaction\&. +.RE +.PP +\fB\-n\fR +.RS 4 +Don\*(Aqt remove anything, just show what would be done\&. +.RE +.PP +\fB\-v\fR +.RS 4 +Write a lot of progress messages\&. +.RE +.PP +\fB\-V\fR, \fB\-\-version\fR +.RS 4 +Print the +vacuumlo +version and exit\&. +.RE +.PP +\fB\-?\fR, \fB\-\-help\fR +.RS 4 +Show help about +vacuumlo +command line arguments, and exit\&. +.RE +.PP + +vacuumlo +also accepts the following command\-line arguments for connection parameters: +.PP +\fB\-h\fR \fIhostname\fR +.RS 4 +Database server\*(Aqs host\&. +.RE +.PP +\fB\-p\fR \fIport\fR +.RS 4 +Database server\*(Aqs port\&. +.RE +.PP +\fB\-U\fR \fIusername\fR +.RS 4 +User name to connect as\&. +.RE +.PP +\fB\-w\fR, \fB\-\-no\-password\fR +.RS 4 +Never issue a password prompt\&. If the server requires password authentication and a password is not available by other means such as a +\&.pgpass +file, the connection attempt will fail\&. This option can be useful in batch jobs and scripts where no user is present to enter a password\&. +.RE +.PP +\fB\-W\fR +.RS 4 +Force +vacuumlo +to prompt for a password before connecting to a database\&. +.sp +This option is never essential, since +vacuumlo +will automatically prompt for a password if the server demands password authentication\&. However, +vacuumlo +will waste a connection attempt finding out that the server wants a password\&. In some cases it is worth typing +\fB\-W\fR +to avoid the extra connection attempt\&. +.RE +.SH "NOTES" +.PP + +vacuumlo +works by the following method: First, +vacuumlo +builds a temporary table which contains all of the OIDs of the large objects in the selected database\&. It then scans through all columns in the database that are of type +oid +or +lo, and removes matching entries from the temporary table\&. (Note: Only types with these names are considered; in particular, domains over them are not considered\&.) The remaining entries in the temporary table identify orphaned LOs\&. These are removed\&. +.SH "AUTHOR" +.PP +Peter Mount + diff --git a/doc/src/sgml/man3/SPI_connect.3 b/doc/src/sgml/man3/SPI_connect.3 new file mode 100644 index 000000000..1f3feba7b --- /dev/null +++ b/doc/src/sgml/man3/SPI_connect.3 @@ -0,0 +1,71 @@ +'\" t +.\" Title: SPI_connect +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_CONNECT" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_connect \- connect a procedure to the SPI manager +.\" SPI_connect +.SH "SYNOPSIS" +.sp +.nf +int SPI_connect(void) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_connect\fR +opens a connection from a procedure invocation to the SPI manager\&. You must call this function if you want to execute commands through SPI\&. Some utility SPI functions can be called from unconnected procedures\&. +.PP +If your procedure is already connected, +\fBSPI_connect\fR +will return the error code +SPI_ERROR_CONNECT\&. This could happen if a procedure that has called +\fBSPI_connect\fR +directly calls another procedure that calls +\fBSPI_connect\fR\&. While recursive calls to the +SPI +manager are permitted when an SQL command called through SPI invokes another function that uses +SPI, directly nested calls to +\fBSPI_connect\fR +and +\fBSPI_finish\fR +are forbidden\&. (But see +\fBSPI_push\fR +and +\fBSPI_pop\fR\&.) +.SH "RETURN VALUE" +.PP +SPI_OK_CONNECT +.RS 4 +on success +.RE +.PP +SPI_ERROR_CONNECT +.RS 4 +on error +.RE diff --git a/doc/src/sgml/man3/SPI_copytuple.3 b/doc/src/sgml/man3/SPI_copytuple.3 new file mode 100644 index 000000000..bc7cf4e9d --- /dev/null +++ b/doc/src/sgml/man3/SPI_copytuple.3 @@ -0,0 +1,58 @@ +'\" t +.\" Title: SPI_copytuple +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_COPYTUPLE" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_copytuple \- make a copy of a row in the upper executor context +.\" SPI_copytuple +.SH "SYNOPSIS" +.sp +.nf +HeapTuple SPI_copytuple(HeapTuple \fIrow\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_copytuple\fR +makes a copy of a row in the upper executor context\&. This is normally used to return a modified row from a trigger\&. In a function declared to return a composite type, use +\fBSPI_returntuple\fR +instead\&. +.SH "ARGUMENTS" +.PP +HeapTuple \fIrow\fR +.RS 4 +row to be copied +.RE +.SH "RETURN VALUE" +.PP +the copied row; +NULL +only if +\fItuple\fR +is +NULL diff --git a/doc/src/sgml/man3/SPI_cursor_close.3 b/doc/src/sgml/man3/SPI_cursor_close.3 new file mode 100644 index 000000000..029ced808 --- /dev/null +++ b/doc/src/sgml/man3/SPI_cursor_close.3 @@ -0,0 +1,52 @@ +'\" t +.\" Title: SPI_cursor_close +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_CURSOR_CLOSE" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_cursor_close \- close a cursor +.\" SPI_cursor_close +.SH "SYNOPSIS" +.sp +.nf +void SPI_cursor_close(Portal \fIportal\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_cursor_close\fR +closes a previously created cursor and releases its portal storage\&. +.PP +All open cursors are closed automatically at the end of a transaction\&. +\fBSPI_cursor_close\fR +need only be invoked if it is desirable to release resources sooner\&. +.SH "ARGUMENTS" +.PP +Portal \fIportal\fR +.RS 4 +portal containing the cursor +.RE diff --git a/doc/src/sgml/man3/SPI_cursor_fetch.3 b/doc/src/sgml/man3/SPI_cursor_fetch.3 new file mode 100644 index 000000000..d62d33d60 --- /dev/null +++ b/doc/src/sgml/man3/SPI_cursor_fetch.3 @@ -0,0 +1,76 @@ +'\" t +.\" Title: SPI_cursor_fetch +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_CURSOR_FETCH" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_cursor_fetch \- fetch some rows from a cursor +.\" SPI_cursor_fetch +.SH "SYNOPSIS" +.sp +.nf +void SPI_cursor_fetch(Portal \fIportal\fR, bool \fIforward\fR, long \fIcount\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_cursor_fetch\fR +fetches some rows from a cursor\&. This is equivalent to a subset of the SQL command +\fBFETCH\fR +(see +\fBSPI_scroll_cursor_fetch\fR +for more functionality)\&. +.SH "ARGUMENTS" +.PP +Portal \fIportal\fR +.RS 4 +portal containing the cursor +.RE +.PP +bool \fIforward\fR +.RS 4 +true for fetch forward, false for fetch backward +.RE +.PP +long \fIcount\fR +.RS 4 +maximum number of rows to fetch +.RE +.SH "RETURN VALUE" +.PP + +\fISPI_processed\fR +and +\fISPI_tuptable\fR +are set as in +\fBSPI_execute\fR +if successful\&. +.SH "NOTES" +.PP +Fetching backward may fail if the cursor\*(Aqs plan was not created with the +CURSOR_OPT_SCROLL +option\&. diff --git a/doc/src/sgml/man3/SPI_cursor_find.3 b/doc/src/sgml/man3/SPI_cursor_find.3 new file mode 100644 index 000000000..0afb7d358 --- /dev/null +++ b/doc/src/sgml/man3/SPI_cursor_find.3 @@ -0,0 +1,53 @@ +'\" t +.\" Title: SPI_cursor_find +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_CURSOR_FIND" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_cursor_find \- find an existing cursor by name +.\" SPI_cursor_find +.SH "SYNOPSIS" +.sp +.nf +Portal SPI_cursor_find(const char * \fIname\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_cursor_find\fR +finds an existing portal by name\&. This is primarily useful to resolve a cursor name returned as text by some other function\&. +.SH "ARGUMENTS" +.PP +const char * \fIname\fR +.RS 4 +name of the portal +.RE +.SH "RETURN VALUE" +.PP +pointer to the portal with the specified name, or +NULL +if none was found diff --git a/doc/src/sgml/man3/SPI_cursor_move.3 b/doc/src/sgml/man3/SPI_cursor_move.3 new file mode 100644 index 000000000..df3ec3c0f --- /dev/null +++ b/doc/src/sgml/man3/SPI_cursor_move.3 @@ -0,0 +1,67 @@ +'\" t +.\" Title: SPI_cursor_move +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_CURSOR_MOVE" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_cursor_move \- move a cursor +.\" SPI_cursor_move +.SH "SYNOPSIS" +.sp +.nf +void SPI_cursor_move(Portal \fIportal\fR, bool \fIforward\fR, long \fIcount\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_cursor_move\fR +skips over some number of rows in a cursor\&. This is equivalent to a subset of the SQL command +\fBMOVE\fR +(see +\fBSPI_scroll_cursor_move\fR +for more functionality)\&. +.SH "ARGUMENTS" +.PP +Portal \fIportal\fR +.RS 4 +portal containing the cursor +.RE +.PP +bool \fIforward\fR +.RS 4 +true for move forward, false for move backward +.RE +.PP +long \fIcount\fR +.RS 4 +maximum number of rows to move +.RE +.SH "NOTES" +.PP +Moving backward may fail if the cursor\*(Aqs plan was not created with the +CURSOR_OPT_SCROLL +option\&. diff --git a/doc/src/sgml/man3/SPI_cursor_open.3 b/doc/src/sgml/man3/SPI_cursor_open.3 new file mode 100644 index 000000000..f5a9f7bf0 --- /dev/null +++ b/doc/src/sgml/man3/SPI_cursor_open.3 @@ -0,0 +1,98 @@ +'\" t +.\" Title: SPI_cursor_open +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_CURSOR_OPEN" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_cursor_open \- set up a cursor using a statement created with \fBSPI_prepare\fR +.\" SPI_cursor_open +.SH "SYNOPSIS" +.sp +.nf +Portal SPI_cursor_open(const char * \fIname\fR, SPIPlanPtr \fIplan\fR, + Datum * \fIvalues\fR, const char * \fInulls\fR, + bool \fIread_only\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_cursor_open\fR +sets up a cursor (internally, a portal) that will execute a statement prepared by +\fBSPI_prepare\fR\&. The parameters have the same meanings as the corresponding parameters to +\fBSPI_execute_plan\fR\&. +.PP +Using a cursor instead of executing the statement directly has two benefits\&. First, the result rows can be retrieved a few at a time, avoiding memory overrun for queries that return many rows\&. Second, a portal can outlive the current procedure (it can, in fact, live to the end of the current transaction)\&. Returning the portal name to the procedure\*(Aqs caller provides a way of returning a row set as result\&. +.PP +The passed\-in parameter data will be copied into the cursor\*(Aqs portal, so it can be freed while the cursor still exists\&. +.SH "ARGUMENTS" +.PP +const char * \fIname\fR +.RS 4 +name for portal, or +NULL +to let the system select a name +.RE +.PP +SPIPlanPtr \fIplan\fR +.RS 4 +prepared statement (returned by +\fBSPI_prepare\fR) +.RE +.PP +Datum * \fIvalues\fR +.RS 4 +An array of actual parameter values\&. Must have same length as the statement\*(Aqs number of arguments\&. +.RE +.PP +const char * \fInulls\fR +.RS 4 +An array describing which parameters are null\&. Must have same length as the statement\*(Aqs number of arguments\&. +n +indicates a null value (entry in +\fIvalues\fR +will be ignored); a space indicates a nonnull value (entry in +\fIvalues\fR +is valid)\&. +.sp +If +\fInulls\fR +is +NULL +then +\fBSPI_cursor_open\fR +assumes that no parameters are null\&. +.RE +.PP +bool \fIread_only\fR +.RS 4 +true +for read\-only execution +.RE +.SH "RETURN VALUE" +.PP +Pointer to portal containing the cursor\&. Note there is no error return convention; any error will be reported via +\fBelog\fR\&. diff --git a/doc/src/sgml/man3/SPI_cursor_open_with_args.3 b/doc/src/sgml/man3/SPI_cursor_open_with_args.3 new file mode 100644 index 000000000..8707254fb --- /dev/null +++ b/doc/src/sgml/man3/SPI_cursor_open_with_args.3 @@ -0,0 +1,114 @@ +'\" t +.\" Title: SPI_cursor_open_with_args +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_CURSOR_OPEN_WITH_ARGS" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_cursor_open_with_args \- set up a cursor using a query and parameters +.\" SPI_cursor_open_with_args +.SH "SYNOPSIS" +.sp +.nf +Portal SPI_cursor_open_with_args(const char *\fIname\fR, + const char *\fIcommand\fR, + int \fInargs\fR, Oid *\fIargtypes\fR, + Datum *\fIvalues\fR, const char *\fInulls\fR, + bool \fIread_only\fR, int \fIcursorOptions\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_cursor_open_with_args\fR +sets up a cursor (internally, a portal) that will execute the specified query\&. Most of the parameters have the same meanings as the corresponding parameters to +\fBSPI_prepare_cursor\fR +and +\fBSPI_cursor_open\fR\&. +.PP +For one\-time query execution, this function should be preferred over +\fBSPI_prepare_cursor\fR +followed by +\fBSPI_cursor_open\fR\&. If the same command is to be executed with many different parameters, either method might be faster, depending on the cost of re\-planning versus the benefit of custom plans\&. +.PP +The passed\-in parameter data will be copied into the cursor\*(Aqs portal, so it can be freed while the cursor still exists\&. +.SH "ARGUMENTS" +.PP +const char * \fIname\fR +.RS 4 +name for portal, or +NULL +to let the system select a name +.RE +.PP +const char * \fIcommand\fR +.RS 4 +command string +.RE +.PP +int \fInargs\fR +.RS 4 +number of input parameters ($1, +$2, etc\&.) +.RE +.PP +Oid * \fIargtypes\fR +.RS 4 +an array containing the +OIDs of the data types of the parameters +.RE +.PP +Datum * \fIvalues\fR +.RS 4 +an array of actual parameter values +.RE +.PP +const char * \fInulls\fR +.RS 4 +an array describing which parameters are null +.sp +If +\fInulls\fR +is +NULL +then +\fBSPI_cursor_open_with_args\fR +assumes that no parameters are null\&. +.RE +.PP +bool \fIread_only\fR +.RS 4 +true +for read\-only execution +.RE +.PP +int \fIcursorOptions\fR +.RS 4 +integer bit mask of cursor options; zero produces default behavior +.RE +.SH "RETURN VALUE" +.PP +Pointer to portal containing the cursor\&. Note there is no error return convention; any error will be reported via +\fBelog\fR\&. diff --git a/doc/src/sgml/man3/SPI_cursor_open_with_paramlist.3 b/doc/src/sgml/man3/SPI_cursor_open_with_paramlist.3 new file mode 100644 index 000000000..81145a291 --- /dev/null +++ b/doc/src/sgml/man3/SPI_cursor_open_with_paramlist.3 @@ -0,0 +1,82 @@ +'\" t +.\" Title: SPI_cursor_open_with_paramlist +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_CURSOR_OPEN_WITH_PARAMLIST" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_cursor_open_with_paramlist \- set up a cursor using parameters +.\" SPI_cursor_open_with_paramlist +.SH "SYNOPSIS" +.sp +.nf +Portal SPI_cursor_open_with_paramlist(const char *\fIname\fR, + SPIPlanPtr \fIplan\fR, + ParamListInfo \fIparams\fR, + bool \fIread_only\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_cursor_open_with_paramlist\fR +sets up a cursor (internally, a portal) that will execute a statement prepared by +\fBSPI_prepare\fR\&. This function is equivalent to +\fBSPI_cursor_open\fR +except that information about the parameter values to be passed to the query is presented differently\&. The +ParamListInfo +representation can be convenient for passing down values that are already available in that format\&. It also supports use of dynamic parameter sets via hook functions specified in +ParamListInfo\&. +.PP +The passed\-in parameter data will be copied into the cursor\*(Aqs portal, so it can be freed while the cursor still exists\&. +.SH "ARGUMENTS" +.PP +const char * \fIname\fR +.RS 4 +name for portal, or +NULL +to let the system select a name +.RE +.PP +SPIPlanPtr \fIplan\fR +.RS 4 +prepared statement (returned by +\fBSPI_prepare\fR) +.RE +.PP +ParamListInfo \fIparams\fR +.RS 4 +data structure containing parameter types and values; NULL if none +.RE +.PP +bool \fIread_only\fR +.RS 4 +true +for read\-only execution +.RE +.SH "RETURN VALUE" +.PP +Pointer to portal containing the cursor\&. Note there is no error return convention; any error will be reported via +\fBelog\fR\&. diff --git a/doc/src/sgml/man3/SPI_exec.3 b/doc/src/sgml/man3/SPI_exec.3 new file mode 100644 index 000000000..237812134 --- /dev/null +++ b/doc/src/sgml/man3/SPI_exec.3 @@ -0,0 +1,61 @@ +'\" t +.\" Title: SPI_exec +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_EXEC" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_exec \- execute a read/write command +.\" SPI_exec +.SH "SYNOPSIS" +.sp +.nf +int SPI_exec(const char * \fIcommand\fR, long \fIcount\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_exec\fR +is the same as +\fBSPI_execute\fR, with the latter\*(Aqs +\fIread_only\fR +parameter always taken as +false\&. +.SH "ARGUMENTS" +.PP +const char * \fIcommand\fR +.RS 4 +string containing command to execute +.RE +.PP +long \fIcount\fR +.RS 4 +maximum number of rows to process or return +.RE +.SH "RETURN VALUE" +.PP +See +\fBSPI_execute\fR\&. diff --git a/doc/src/sgml/man3/SPI_execp.3 b/doc/src/sgml/man3/SPI_execp.3 new file mode 100644 index 000000000..349dfc50a --- /dev/null +++ b/doc/src/sgml/man3/SPI_execp.3 @@ -0,0 +1,94 @@ +'\" t +.\" Title: SPI_execp +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_EXECP" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_execp \- execute a statement in read/write mode +.\" SPI_execp +.SH "SYNOPSIS" +.sp +.nf +int SPI_execp(SPIPlanPtr \fIplan\fR, Datum * \fIvalues\fR, const char * \fInulls\fR, long \fIcount\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_execp\fR +is the same as +\fBSPI_execute_plan\fR, with the latter\*(Aqs +\fIread_only\fR +parameter always taken as +false\&. +.SH "ARGUMENTS" +.PP +SPIPlanPtr \fIplan\fR +.RS 4 +prepared statement (returned by +\fBSPI_prepare\fR) +.RE +.PP +Datum * \fIvalues\fR +.RS 4 +An array of actual parameter values\&. Must have same length as the statement\*(Aqs number of arguments\&. +.RE +.PP +const char * \fInulls\fR +.RS 4 +An array describing which parameters are null\&. Must have same length as the statement\*(Aqs number of arguments\&. +n +indicates a null value (entry in +\fIvalues\fR +will be ignored); a space indicates a nonnull value (entry in +\fIvalues\fR +is valid)\&. +.sp +If +\fInulls\fR +is +NULL +then +\fBSPI_execp\fR +assumes that no parameters are null\&. +.RE +.PP +long \fIcount\fR +.RS 4 +maximum number of rows to process or return +.RE +.SH "RETURN VALUE" +.PP +See +\fBSPI_execute_plan\fR\&. +.PP + +\fISPI_processed\fR +and +\fISPI_tuptable\fR +are set as in +\fBSPI_execute\fR +if successful\&. diff --git a/doc/src/sgml/man3/SPI_execute.3 b/doc/src/sgml/man3/SPI_execute.3 new file mode 100644 index 000000000..ba2a6f250 --- /dev/null +++ b/doc/src/sgml/man3/SPI_execute.3 @@ -0,0 +1,300 @@ +'\" t +.\" Title: SPI_execute +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_EXECUTE" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_execute \- execute a command +.\" SPI_execute +.SH "SYNOPSIS" +.sp +.nf +int SPI_execute(const char * \fIcommand\fR, bool \fIread_only\fR, long \fIcount\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_execute\fR +executes the specified SQL command for +\fIcount\fR +rows\&. If +\fIread_only\fR +is +true, the command must be read\-only, and execution overhead is somewhat reduced\&. +.PP +This function can only be called from a connected procedure\&. +.PP +If +\fIcount\fR +is zero then the command is executed for all rows that it applies to\&. If +\fIcount\fR +is greater than 0, then the number of rows for which the command will be executed is restricted (much like a +LIMIT +clause)\&. For example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SPI_execute("INSERT INTO foo SELECT * FROM bar", false, 5); +.fi +.if n \{\ +.RE +.\} +.sp +will allow at most 5 rows to be inserted into the table\&. +.PP +You can pass multiple commands in one string, but later commands cannot depend on the creation of objects earlier in the string, because the whole string will be parsed and planned before execution begins\&. +\fBSPI_execute\fR +returns the result for the command executed last\&. The +\fIcount\fR +limit applies to each command separately, but it is not applied to hidden commands generated by rules\&. +.PP +When +\fIread_only\fR +is +false, +\fBSPI_execute\fR +increments the command counter and computes a new +snapshot +before executing each command in the string\&. The snapshot does not actually change if the current transaction isolation level is +SERIALIZABLE +or +REPEATABLE READ, but in +READ COMMITTED +mode the snapshot update allows each command to see the results of newly committed transactions from other sessions\&. This is essential for consistent behavior when the commands are modifying the database\&. +.PP +When +\fIread_only\fR +is +true, +\fBSPI_execute\fR +does not update either the snapshot or the command counter, and it allows only plain +\fBSELECT\fR +commands to appear in the command string\&. The commands are executed using the snapshot previously established for the surrounding query\&. This execution mode is somewhat faster than the read/write mode due to eliminating per\-command overhead\&. It also allows genuinely +stable +functions to be built: since successive executions will all use the same snapshot, there will be no change in the results\&. +.PP +It is generally unwise to mix read\-only and read\-write commands within a single function using SPI; that could result in very confusing behavior, since the read\-only queries would not see the results of any database updates done by the read\-write queries\&. +.PP +The actual number of rows for which the (last) command was executed is returned in the global variable +\fISPI_processed\fR\&. If the return value of the function is +SPI_OK_SELECT, +SPI_OK_INSERT_RETURNING, +SPI_OK_DELETE_RETURNING, or +SPI_OK_UPDATE_RETURNING, then you can use the global pointer +SPITupleTable *SPI_tuptable +to access the result rows\&. Some utility commands (such as +\fBEXPLAIN\fR) also return row sets, and +SPI_tuptable +will contain the result in these cases too\&. +.PP +The structure +SPITupleTable +is defined thus: +.sp +.if n \{\ +.RS 4 +.\} +.nf +typedef struct +{ + MemoryContext tuptabcxt; /* memory context of result table */ + uint32 alloced; /* number of alloced vals */ + uint32 free; /* number of free vals */ + TupleDesc tupdesc; /* row descriptor */ + HeapTuple *vals; /* rows */ +} SPITupleTable; +.fi +.if n \{\ +.RE +.\} +.sp +vals +is an array of pointers to rows\&. (The number of valid entries is given by +\fISPI_processed\fR\&.) +tupdesc +is a row descriptor which you can pass to SPI functions dealing with rows\&. +tuptabcxt, +alloced, and +free +are internal fields not intended for use by SPI callers\&. +.PP + +\fBSPI_finish\fR +frees all +SPITupleTables allocated during the current procedure\&. You can free a particular result table earlier, if you are done with it, by calling +\fBSPI_freetuptable\fR\&. +.SH "ARGUMENTS" +.PP +const char * \fIcommand\fR +.RS 4 +string containing command to execute +.RE +.PP +bool \fIread_only\fR +.RS 4 +true +for read\-only execution +.RE +.PP +long \fIcount\fR +.RS 4 +maximum number of rows to process or return +.RE +.SH "RETURN VALUE" +.PP +If the execution of the command was successful then one of the following (nonnegative) values will be returned: +.PP +SPI_OK_SELECT +.RS 4 +if a +\fBSELECT\fR +(but not +\fBSELECT INTO\fR) was executed +.RE +.PP +SPI_OK_SELINTO +.RS 4 +if a +\fBSELECT INTO\fR +was executed +.RE +.PP +SPI_OK_INSERT +.RS 4 +if an +\fBINSERT\fR +was executed +.RE +.PP +SPI_OK_DELETE +.RS 4 +if a +\fBDELETE\fR +was executed +.RE +.PP +SPI_OK_UPDATE +.RS 4 +if an +\fBUPDATE\fR +was executed +.RE +.PP +SPI_OK_INSERT_RETURNING +.RS 4 +if an +\fBINSERT RETURNING\fR +was executed +.RE +.PP +SPI_OK_DELETE_RETURNING +.RS 4 +if a +\fBDELETE RETURNING\fR +was executed +.RE +.PP +SPI_OK_UPDATE_RETURNING +.RS 4 +if an +\fBUPDATE RETURNING\fR +was executed +.RE +.PP +SPI_OK_UTILITY +.RS 4 +if a utility command (e\&.g\&., +\fBCREATE TABLE\fR) was executed +.RE +.PP +SPI_OK_REWRITTEN +.RS 4 +if the command was rewritten into another kind of command (e\&.g\&., +\fBUPDATE\fR +became an +\fBINSERT\fR) by a +rule\&. +.RE +.PP +On error, one of the following negative values is returned: +.PP +SPI_ERROR_ARGUMENT +.RS 4 +if +\fIcommand\fR +is +NULL +or +\fIcount\fR +is less than 0 +.RE +.PP +SPI_ERROR_COPY +.RS 4 +if +\fBCOPY TO stdout\fR +or +\fBCOPY FROM stdin\fR +was attempted +.RE +.PP +SPI_ERROR_TRANSACTION +.RS 4 +if a transaction manipulation command was attempted (\fBBEGIN\fR, +\fBCOMMIT\fR, +\fBROLLBACK\fR, +\fBSAVEPOINT\fR, +\fBPREPARE TRANSACTION\fR, +\fBCOMMIT PREPARED\fR, +\fBROLLBACK PREPARED\fR, or any variant thereof) +.RE +.PP +SPI_ERROR_OPUNKNOWN +.RS 4 +if the command type is unknown (shouldn\*(Aqt happen) +.RE +.PP +SPI_ERROR_UNCONNECTED +.RS 4 +if called from an unconnected procedure +.RE +.SH "NOTES" +.PP +The functions +\fBSPI_execute\fR, +\fBSPI_exec\fR, +\fBSPI_execute_plan\fR, and +\fBSPI_execp\fR +change both +\fISPI_processed\fR +and +\fISPI_tuptable\fR +(just the pointer, not the contents of the structure)\&. Save these two global variables into local procedure variables if you need to access the result table of +\fBSPI_execute\fR +or a related function across later calls\&. diff --git a/doc/src/sgml/man3/SPI_execute_plan.3 b/doc/src/sgml/man3/SPI_execute_plan.3 new file mode 100644 index 000000000..c68bb03d4 --- /dev/null +++ b/doc/src/sgml/man3/SPI_execute_plan.3 @@ -0,0 +1,126 @@ +'\" t +.\" Title: SPI_execute_plan +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_EXECUTE_PLAN" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_execute_plan \- execute a statement prepared by \fBSPI_prepare\fR +.\" SPI_execute_plan +.SH "SYNOPSIS" +.sp +.nf +int SPI_execute_plan(SPIPlanPtr \fIplan\fR, Datum * \fIvalues\fR, const char * \fInulls\fR, + bool \fIread_only\fR, long \fIcount\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_execute_plan\fR +executes a statement prepared by +\fBSPI_prepare\fR +or one of its siblings\&. +\fIread_only\fR +and +\fIcount\fR +have the same interpretation as in +\fBSPI_execute\fR\&. +.SH "ARGUMENTS" +.PP +SPIPlanPtr \fIplan\fR +.RS 4 +prepared statement (returned by +\fBSPI_prepare\fR) +.RE +.PP +Datum * \fIvalues\fR +.RS 4 +An array of actual parameter values\&. Must have same length as the statement\*(Aqs number of arguments\&. +.RE +.PP +const char * \fInulls\fR +.RS 4 +An array describing which parameters are null\&. Must have same length as the statement\*(Aqs number of arguments\&. +n +indicates a null value (entry in +\fIvalues\fR +will be ignored); a space indicates a nonnull value (entry in +\fIvalues\fR +is valid)\&. +.sp +If +\fInulls\fR +is +NULL +then +\fBSPI_execute_plan\fR +assumes that no parameters are null\&. +.RE +.PP +bool \fIread_only\fR +.RS 4 +true +for read\-only execution +.RE +.PP +long \fIcount\fR +.RS 4 +maximum number of rows to process or return +.RE +.SH "RETURN VALUE" +.PP +The return value is the same as for +\fBSPI_execute\fR, with the following additional possible error (negative) results: +.PP +SPI_ERROR_ARGUMENT +.RS 4 +if +\fIplan\fR +is +NULL +or invalid, or +\fIcount\fR +is less than 0 +.RE +.PP +SPI_ERROR_PARAM +.RS 4 +if +\fIvalues\fR +is +NULL +and +\fIplan\fR +was prepared with some parameters +.RE +.PP + +\fISPI_processed\fR +and +\fISPI_tuptable\fR +are set as in +\fBSPI_execute\fR +if successful\&. diff --git a/doc/src/sgml/man3/SPI_execute_plan_with_paramlist.3 b/doc/src/sgml/man3/SPI_execute_plan_with_paramlist.3 new file mode 100644 index 000000000..2f06dbd83 --- /dev/null +++ b/doc/src/sgml/man3/SPI_execute_plan_with_paramlist.3 @@ -0,0 +1,86 @@ +'\" t +.\" Title: SPI_execute_plan_with_paramlist +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_EXECUTE_PLAN_WITH_PARAMLIST" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_execute_plan_with_paramlist \- execute a statement prepared by \fBSPI_prepare\fR +.\" SPI_execute_plan_with_paramlist +.SH "SYNOPSIS" +.sp +.nf +int SPI_execute_plan_with_paramlist(SPIPlanPtr \fIplan\fR, + ParamListInfo \fIparams\fR, + bool \fIread_only\fR, + long \fIcount\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_execute_plan_with_paramlist\fR +executes a statement prepared by +\fBSPI_prepare\fR\&. This function is equivalent to +\fBSPI_execute_plan\fR +except that information about the parameter values to be passed to the query is presented differently\&. The +ParamListInfo +representation can be convenient for passing down values that are already available in that format\&. It also supports use of dynamic parameter sets via hook functions specified in +ParamListInfo\&. +.SH "ARGUMENTS" +.PP +SPIPlanPtr \fIplan\fR +.RS 4 +prepared statement (returned by +\fBSPI_prepare\fR) +.RE +.PP +ParamListInfo \fIparams\fR +.RS 4 +data structure containing parameter types and values; NULL if none +.RE +.PP +bool \fIread_only\fR +.RS 4 +true +for read\-only execution +.RE +.PP +long \fIcount\fR +.RS 4 +maximum number of rows to process or return +.RE +.SH "RETURN VALUE" +.PP +The return value is the same as for +\fBSPI_execute_plan\fR\&. +.PP + +\fISPI_processed\fR +and +\fISPI_tuptable\fR +are set as in +\fBSPI_execute_plan\fR +if successful\&. diff --git a/doc/src/sgml/man3/SPI_execute_with_args.3 b/doc/src/sgml/man3/SPI_execute_with_args.3 new file mode 100644 index 000000000..b20258d6c --- /dev/null +++ b/doc/src/sgml/man3/SPI_execute_with_args.3 @@ -0,0 +1,119 @@ +'\" t +.\" Title: SPI_execute_with_args +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_EXECUTE_WITH_ARGS" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_execute_with_args \- execute a command with out\-of\-line parameters +.\" SPI_execute_with_args +.SH "SYNOPSIS" +.sp +.nf +int SPI_execute_with_args(const char *\fIcommand\fR, + int \fInargs\fR, Oid *\fIargtypes\fR, + Datum *\fIvalues\fR, const char *\fInulls\fR, + bool \fIread_only\fR, long \fIcount\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_execute_with_args\fR +executes a command that might include references to externally supplied parameters\&. The command text refers to a parameter as +$\fIn\fR, and the call specifies data types and values for each such symbol\&. +\fIread_only\fR +and +\fIcount\fR +have the same interpretation as in +\fBSPI_execute\fR\&. +.PP +The main advantage of this routine compared to +\fBSPI_execute\fR +is that data values can be inserted into the command without tedious quoting/escaping, and thus with much less risk of SQL\-injection attacks\&. +.PP +Similar results can be achieved with +\fBSPI_prepare\fR +followed by +\fBSPI_execute_plan\fR; however, when using this function the query plan is always customized to the specific parameter values provided\&. For one\-time query execution, this function should be preferred\&. If the same command is to be executed with many different parameters, either method might be faster, depending on the cost of re\-planning versus the benefit of custom plans\&. +.SH "ARGUMENTS" +.PP +const char * \fIcommand\fR +.RS 4 +command string +.RE +.PP +int \fInargs\fR +.RS 4 +number of input parameters ($1, +$2, etc\&.) +.RE +.PP +Oid * \fIargtypes\fR +.RS 4 +an array containing the +OIDs of the data types of the parameters +.RE +.PP +Datum * \fIvalues\fR +.RS 4 +an array of actual parameter values +.RE +.PP +const char * \fInulls\fR +.RS 4 +an array describing which parameters are null +.sp +If +\fInulls\fR +is +NULL +then +\fBSPI_execute_with_args\fR +assumes that no parameters are null\&. +.RE +.PP +bool \fIread_only\fR +.RS 4 +true +for read\-only execution +.RE +.PP +long \fIcount\fR +.RS 4 +maximum number of rows to process or return +.RE +.SH "RETURN VALUE" +.PP +The return value is the same as for +\fBSPI_execute\fR\&. +.PP + +\fISPI_processed\fR +and +\fISPI_tuptable\fR +are set as in +\fBSPI_execute\fR +if successful\&. diff --git a/doc/src/sgml/man3/SPI_finish.3 b/doc/src/sgml/man3/SPI_finish.3 new file mode 100644 index 000000000..2f1af44d2 --- /dev/null +++ b/doc/src/sgml/man3/SPI_finish.3 @@ -0,0 +1,59 @@ +'\" t +.\" Title: SPI_finish +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_FINISH" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_finish \- disconnect a procedure from the SPI manager +.\" SPI_finish +.SH "SYNOPSIS" +.sp +.nf +int SPI_finish(void) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_finish\fR +closes an existing connection to the SPI manager\&. You must call this function after completing the SPI operations needed during your procedure\*(Aqs current invocation\&. You do not need to worry about making this happen, however, if you abort the transaction via +elog(ERROR)\&. In that case SPI will clean itself up automatically\&. +.PP +If +\fBSPI_finish\fR +is called without having a valid connection, it will return +SPI_ERROR_UNCONNECTED\&. There is no fundamental problem with this; it means that the SPI manager has nothing to do\&. +.SH "RETURN VALUE" +.PP +SPI_OK_FINISH +.RS 4 +if properly disconnected +.RE +.PP +SPI_ERROR_UNCONNECTED +.RS 4 +if called from an unconnected procedure +.RE diff --git a/doc/src/sgml/man3/SPI_fname.3 b/doc/src/sgml/man3/SPI_fname.3 new file mode 100644 index 000000000..be28eb643 --- /dev/null +++ b/doc/src/sgml/man3/SPI_fname.3 @@ -0,0 +1,66 @@ +'\" t +.\" Title: SPI_fname +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_FNAME" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_fname \- determine the column name for the specified column number +.\" SPI_fname +.SH "SYNOPSIS" +.sp +.nf +char * SPI_fname(TupleDesc \fIrowdesc\fR, int \fIcolnumber\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_fname\fR +returns a copy of the column name of the specified column\&. (You can use +\fBpfree\fR +to release the copy of the name when you don\*(Aqt need it anymore\&.) +.SH "ARGUMENTS" +.PP +TupleDesc \fIrowdesc\fR +.RS 4 +input row description +.RE +.PP +int \fIcolnumber\fR +.RS 4 +column number (count starts at 1) +.RE +.SH "RETURN VALUE" +.PP +The column name; +NULL +if +\fIcolnumber\fR +is out of range\&. +\fISPI_result\fR +set to +SPI_ERROR_NOATTRIBUTE +on error\&. diff --git a/doc/src/sgml/man3/SPI_fnumber.3 b/doc/src/sgml/man3/SPI_fnumber.3 new file mode 100644 index 000000000..fdb22f081 --- /dev/null +++ b/doc/src/sgml/man3/SPI_fnumber.3 @@ -0,0 +1,65 @@ +'\" t +.\" Title: SPI_fnumber +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_FNUMBER" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_fnumber \- determine the column number for the specified column name +.\" SPI_fnumber +.SH "SYNOPSIS" +.sp +.nf +int SPI_fnumber(TupleDesc \fIrowdesc\fR, const char * \fIcolname\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_fnumber\fR +returns the column number for the column with the specified name\&. +.PP +If +\fIcolname\fR +refers to a system column (e\&.g\&., +oid) then the appropriate negative column number will be returned\&. The caller should be careful to test the return value for exact equality to +SPI_ERROR_NOATTRIBUTE +to detect an error; testing the result for less than or equal to 0 is not correct unless system columns should be rejected\&. +.SH "ARGUMENTS" +.PP +TupleDesc \fIrowdesc\fR +.RS 4 +input row description +.RE +.PP +const char * \fIcolname\fR +.RS 4 +column name +.RE +.SH "RETURN VALUE" +.PP +Column number (count starts at 1), or +SPI_ERROR_NOATTRIBUTE +if the named column was not found\&. diff --git a/doc/src/sgml/man3/SPI_freeplan.3 b/doc/src/sgml/man3/SPI_freeplan.3 new file mode 100644 index 000000000..a39ec66c7 --- /dev/null +++ b/doc/src/sgml/man3/SPI_freeplan.3 @@ -0,0 +1,62 @@ +'\" t +.\" Title: SPI_freeplan +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_FREEPLAN" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_freeplan \- free a previously saved prepared statement +.\" SPI_freeplan +.SH "SYNOPSIS" +.sp +.nf +int SPI_freeplan(SPIPlanPtr \fIplan\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_freeplan\fR +releases a prepared statement previously returned by +\fBSPI_prepare\fR +or saved by +\fBSPI_keepplan\fR +or +\fBSPI_saveplan\fR\&. +.SH "ARGUMENTS" +.PP +SPIPlanPtr \fIplan\fR +.RS 4 +pointer to statement to free +.RE +.SH "RETURN VALUE" +.PP +0 on success; +SPI_ERROR_ARGUMENT +if +\fIplan\fR +is +NULL +or invalid diff --git a/doc/src/sgml/man3/SPI_freetuple.3 b/doc/src/sgml/man3/SPI_freetuple.3 new file mode 100644 index 000000000..3e32f6300 --- /dev/null +++ b/doc/src/sgml/man3/SPI_freetuple.3 @@ -0,0 +1,51 @@ +'\" t +.\" Title: SPI_freetuple +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_FREETUPLE" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_freetuple \- free a row allocated in the upper executor context +.\" SPI_freetuple +.SH "SYNOPSIS" +.sp +.nf +void SPI_freetuple(HeapTuple \fIrow\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_freetuple\fR +frees a row previously allocated in the upper executor context\&. +.PP +This function is no longer different from plain +\fBheap_freetuple\fR\&. It\*(Aqs kept just for backward compatibility of existing code\&. +.SH "ARGUMENTS" +.PP +HeapTuple \fIrow\fR +.RS 4 +row to free +.RE diff --git a/doc/src/sgml/man3/SPI_freetuptable.3 b/doc/src/sgml/man3/SPI_freetuptable.3 new file mode 100644 index 000000000..d2a8600a6 --- /dev/null +++ b/doc/src/sgml/man3/SPI_freetuptable.3 @@ -0,0 +1,54 @@ +'\" t +.\" Title: SPI_freetuptable +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_FREETUPTABLE" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_freetuptable \- free a row set created by \fBSPI_execute\fR or a similar function +.\" SPI_freetuptable +.SH "SYNOPSIS" +.sp +.nf +void SPI_freetuptable(SPITupleTable * \fItuptable\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_freetuptable\fR +frees a row set created by a prior SPI command execution function, such as +\fBSPI_execute\fR\&. Therefore, this function is usually called with the global variable +\fISPI_tupletable\fR +as argument\&. +.PP +This function is useful if a SPI procedure needs to execute multiple commands and does not want to keep the results of earlier commands around until it ends\&. Note that any unfreed row sets will be freed anyway at +\fBSPI_finish\fR\&. +.SH "ARGUMENTS" +.PP +SPITupleTable * \fItuptable\fR +.RS 4 +pointer to row set to free +.RE diff --git a/doc/src/sgml/man3/SPI_getargcount.3 b/doc/src/sgml/man3/SPI_getargcount.3 new file mode 100644 index 000000000..960f68863 --- /dev/null +++ b/doc/src/sgml/man3/SPI_getargcount.3 @@ -0,0 +1,62 @@ +'\" t +.\" Title: SPI_getargcount +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_GETARGCOUNT" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_getargcount \- return the number of arguments needed by a statement prepared by \fBSPI_prepare\fR +.\" SPI_getargcount +.SH "SYNOPSIS" +.sp +.nf +int SPI_getargcount(SPIPlanPtr \fIplan\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_getargcount\fR +returns the number of arguments needed to execute a statement prepared by +\fBSPI_prepare\fR\&. +.SH "ARGUMENTS" +.PP +SPIPlanPtr \fIplan\fR +.RS 4 +prepared statement (returned by +\fBSPI_prepare\fR) +.RE +.SH "RETURN VALUE" +.PP +The count of expected arguments for the +\fIplan\fR\&. If the +\fIplan\fR +is +NULL +or invalid, +\fISPI_result\fR +is set to +SPI_ERROR_ARGUMENT +and \-1 is returned\&. diff --git a/doc/src/sgml/man3/SPI_getargtypeid.3 b/doc/src/sgml/man3/SPI_getargtypeid.3 new file mode 100644 index 000000000..2362dacce --- /dev/null +++ b/doc/src/sgml/man3/SPI_getargtypeid.3 @@ -0,0 +1,72 @@ +'\" t +.\" Title: SPI_getargtypeid +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_GETARGTYPEID" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_getargtypeid \- return the data type OID for an argument of a statement prepared by \fBSPI_prepare\fR +.\" SPI_getargtypeid +.SH "SYNOPSIS" +.sp +.nf +Oid SPI_getargtypeid(SPIPlanPtr \fIplan\fR, int \fIargIndex\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_getargtypeid\fR +returns the OID representing the type for the +\fIargIndex\fR\*(Aqth argument of a statement prepared by +\fBSPI_prepare\fR\&. First argument is at index zero\&. +.SH "ARGUMENTS" +.PP +SPIPlanPtr \fIplan\fR +.RS 4 +prepared statement (returned by +\fBSPI_prepare\fR) +.RE +.PP +int \fIargIndex\fR +.RS 4 +zero based index of the argument +.RE +.SH "RETURN VALUE" +.PP +The type OID of the argument at the given index\&. If the +\fIplan\fR +is +NULL +or invalid, or +\fIargIndex\fR +is less than 0 or not less than the number of arguments declared for the +\fIplan\fR, +\fISPI_result\fR +is set to +SPI_ERROR_ARGUMENT +and +InvalidOid +is returned\&. diff --git a/doc/src/sgml/man3/SPI_getbinval.3 b/doc/src/sgml/man3/SPI_getbinval.3 new file mode 100644 index 000000000..186b68ac8 --- /dev/null +++ b/doc/src/sgml/man3/SPI_getbinval.3 @@ -0,0 +1,78 @@ +'\" t +.\" Title: SPI_getbinval +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_GETBINVAL" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_getbinval \- return the binary value of the specified column +.\" SPI_getbinval +.SH "SYNOPSIS" +.sp +.nf +Datum SPI_getbinval(HeapTuple \fIrow\fR, TupleDesc \fIrowdesc\fR, int \fIcolnumber\fR, + bool * \fIisnull\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_getbinval\fR +returns the value of the specified column in the internal form (as type +Datum)\&. +.PP +This function does not allocate new space for the datum\&. In the case of a pass\-by\-reference data type, the return value will be a pointer into the passed row\&. +.SH "ARGUMENTS" +.PP +HeapTuple \fIrow\fR +.RS 4 +input row to be examined +.RE +.PP +TupleDesc \fIrowdesc\fR +.RS 4 +input row description +.RE +.PP +int \fIcolnumber\fR +.RS 4 +column number (count starts at 1) +.RE +.PP +bool * \fIisnull\fR +.RS 4 +flag for a null value in the column +.RE +.SH "RETURN VALUE" +.PP +The binary value of the column is returned\&. The variable pointed to by +\fIisnull\fR +is set to true if the column is null, else to false\&. +.PP + +\fISPI_result\fR +is set to +SPI_ERROR_NOATTRIBUTE +on error\&. diff --git a/doc/src/sgml/man3/SPI_getnspname.3 b/doc/src/sgml/man3/SPI_getnspname.3 new file mode 100644 index 000000000..34866d41d --- /dev/null +++ b/doc/src/sgml/man3/SPI_getnspname.3 @@ -0,0 +1,55 @@ +'\" t +.\" Title: SPI_getnspname +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_GETNSPNAME" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_getnspname \- return the namespace of the specified relation +.\" SPI_getnspname +.SH "SYNOPSIS" +.sp +.nf +char * SPI_getnspname(Relation \fIrel\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_getnspname\fR +returns a copy of the name of the namespace that the specified +Relation +belongs to\&. This is equivalent to the relation\*(Aqs schema\&. You should +\fBpfree\fR +the return value of this function when you are finished with it\&. +.SH "ARGUMENTS" +.PP +Relation \fIrel\fR +.RS 4 +input relation +.RE +.SH "RETURN VALUE" +.PP +The name of the specified relation\*(Aqs namespace\&. diff --git a/doc/src/sgml/man3/SPI_getrelname.3 b/doc/src/sgml/man3/SPI_getrelname.3 new file mode 100644 index 000000000..10f408aa9 --- /dev/null +++ b/doc/src/sgml/man3/SPI_getrelname.3 @@ -0,0 +1,53 @@ +'\" t +.\" Title: SPI_getrelname +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_GETRELNAME" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_getrelname \- return the name of the specified relation +.\" SPI_getrelname +.SH "SYNOPSIS" +.sp +.nf +char * SPI_getrelname(Relation \fIrel\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_getrelname\fR +returns a copy of the name of the specified relation\&. (You can use +\fBpfree\fR +to release the copy of the name when you don\*(Aqt need it anymore\&.) +.SH "ARGUMENTS" +.PP +Relation \fIrel\fR +.RS 4 +input relation +.RE +.SH "RETURN VALUE" +.PP +The name of the specified relation\&. diff --git a/doc/src/sgml/man3/SPI_gettype.3 b/doc/src/sgml/man3/SPI_gettype.3 new file mode 100644 index 000000000..206737c0d --- /dev/null +++ b/doc/src/sgml/man3/SPI_gettype.3 @@ -0,0 +1,64 @@ +'\" t +.\" Title: SPI_gettype +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_GETTYPE" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_gettype \- return the data type name of the specified column +.\" SPI_gettype +.SH "SYNOPSIS" +.sp +.nf +char * SPI_gettype(TupleDesc \fIrowdesc\fR, int \fIcolnumber\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_gettype\fR +returns a copy of the data type name of the specified column\&. (You can use +\fBpfree\fR +to release the copy of the name when you don\*(Aqt need it anymore\&.) +.SH "ARGUMENTS" +.PP +TupleDesc \fIrowdesc\fR +.RS 4 +input row description +.RE +.PP +int \fIcolnumber\fR +.RS 4 +column number (count starts at 1) +.RE +.SH "RETURN VALUE" +.PP +The data type name of the specified column, or +NULL +on error\&. +\fISPI_result\fR +is set to +SPI_ERROR_NOATTRIBUTE +on error\&. diff --git a/doc/src/sgml/man3/SPI_gettypeid.3 b/doc/src/sgml/man3/SPI_gettypeid.3 new file mode 100644 index 000000000..9b833eea6 --- /dev/null +++ b/doc/src/sgml/man3/SPI_gettypeid.3 @@ -0,0 +1,65 @@ +'\" t +.\" Title: SPI_gettypeid +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_GETTYPEID" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_gettypeid \- return the data type OID of the specified column +.\" SPI_gettypeid +.SH "SYNOPSIS" +.sp +.nf +Oid SPI_gettypeid(TupleDesc \fIrowdesc\fR, int \fIcolnumber\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_gettypeid\fR +returns the +OID +of the data type of the specified column\&. +.SH "ARGUMENTS" +.PP +TupleDesc \fIrowdesc\fR +.RS 4 +input row description +.RE +.PP +int \fIcolnumber\fR +.RS 4 +column number (count starts at 1) +.RE +.SH "RETURN VALUE" +.PP +The +OID +of the data type of the specified column or +InvalidOid +on error\&. On error, +\fISPI_result\fR +is set to +SPI_ERROR_NOATTRIBUTE\&. diff --git a/doc/src/sgml/man3/SPI_getvalue.3 b/doc/src/sgml/man3/SPI_getvalue.3 new file mode 100644 index 000000000..d92f0d08c --- /dev/null +++ b/doc/src/sgml/man3/SPI_getvalue.3 @@ -0,0 +1,74 @@ +'\" t +.\" Title: SPI_getvalue +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_GETVALUE" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_getvalue \- return the string value of the specified column +.\" SPI_getvalue +.SH "SYNOPSIS" +.sp +.nf +char * SPI_getvalue(HeapTuple \fIrow\fR, TupleDesc \fIrowdesc\fR, int \fIcolnumber\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_getvalue\fR +returns the string representation of the value of the specified column\&. +.PP +The result is returned in memory allocated using +\fBpalloc\fR\&. (You can use +\fBpfree\fR +to release the memory when you don\*(Aqt need it anymore\&.) +.SH "ARGUMENTS" +.PP +HeapTuple \fIrow\fR +.RS 4 +input row to be examined +.RE +.PP +TupleDesc \fIrowdesc\fR +.RS 4 +input row description +.RE +.PP +int \fIcolnumber\fR +.RS 4 +column number (count starts at 1) +.RE +.SH "RETURN VALUE" +.PP +Column value, or +NULL +if the column is null, +\fIcolnumber\fR +is out of range (\fISPI_result\fR +is set to +SPI_ERROR_NOATTRIBUTE), or no output function is available (\fISPI_result\fR +is set to +SPI_ERROR_NOOUTFUNC)\&. diff --git a/doc/src/sgml/man3/SPI_is_cursor_plan.3 b/doc/src/sgml/man3/SPI_is_cursor_plan.3 new file mode 100644 index 000000000..9f8799ca5 --- /dev/null +++ b/doc/src/sgml/man3/SPI_is_cursor_plan.3 @@ -0,0 +1,85 @@ +'\" t +.\" Title: SPI_is_cursor_plan +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_IS_CURSOR_PLAN" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_is_cursor_plan \- return true if a statement prepared by \fBSPI_prepare\fR can be used with \fBSPI_cursor_open\fR +.\" SPI_is_cursor_plan +.SH "SYNOPSIS" +.sp +.nf +bool SPI_is_cursor_plan(SPIPlanPtr \fIplan\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_is_cursor_plan\fR +returns +true +if a statement prepared by +\fBSPI_prepare\fR +can be passed as an argument to +\fBSPI_cursor_open\fR, or +false +if that is not the case\&. The criteria are that the +\fIplan\fR +represents one single command and that this command returns tuples to the caller; for example, +\fBSELECT\fR +is allowed unless it contains an +INTO +clause, and +\fBUPDATE\fR +is allowed only if it contains a +RETURNING +clause\&. +.SH "ARGUMENTS" +.PP +SPIPlanPtr \fIplan\fR +.RS 4 +prepared statement (returned by +\fBSPI_prepare\fR) +.RE +.SH "RETURN VALUE" +.PP + +true +or +false +to indicate if the +\fIplan\fR +can produce a cursor or not, with +\fISPI_result\fR +set to zero\&. If it is not possible to determine the answer (for example, if the +\fIplan\fR +is +NULL +or invalid, or if called when not connected to SPI), then +\fISPI_result\fR +is set to a suitable error code and +false +is returned\&. diff --git a/doc/src/sgml/man3/SPI_keepplan.3 b/doc/src/sgml/man3/SPI_keepplan.3 new file mode 100644 index 000000000..ed81282bc --- /dev/null +++ b/doc/src/sgml/man3/SPI_keepplan.3 @@ -0,0 +1,65 @@ +'\" t +.\" Title: SPI_keepplan +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_KEEPPLAN" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_keepplan \- save a prepared statement +.\" SPI_keepplan +.SH "SYNOPSIS" +.sp +.nf +int SPI_keepplan(SPIPlanPtr \fIplan\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_keepplan\fR +saves a passed statement (prepared by +\fBSPI_prepare\fR) so that it will not be freed by +\fBSPI_finish\fR +nor by the transaction manager\&. This gives you the ability to reuse prepared statements in the subsequent invocations of your procedure in the current session\&. +.SH "ARGUMENTS" +.PP +SPIPlanPtr \fIplan\fR +.RS 4 +the prepared statement to be saved +.RE +.SH "RETURN VALUE" +.PP +0 on success; +SPI_ERROR_ARGUMENT +if +\fIplan\fR +is +NULL +or invalid +.SH "NOTES" +.PP +The passed\-in statement is relocated to permanent storage by means of pointer adjustment (no data copying is required)\&. If you later wish to delete it, use +\fBSPI_freeplan\fR +on it\&. diff --git a/doc/src/sgml/man3/SPI_modifytuple.3 b/doc/src/sgml/man3/SPI_modifytuple.3 new file mode 100644 index 000000000..08c7e1353 --- /dev/null +++ b/doc/src/sgml/man3/SPI_modifytuple.3 @@ -0,0 +1,116 @@ +'\" t +.\" Title: SPI_modifytuple +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_MODIFYTUPLE" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_modifytuple \- create a row by replacing selected fields of a given row +.\" SPI_modifytuple +.SH "SYNOPSIS" +.sp +.nf +HeapTuple SPI_modifytuple(Relation \fIrel\fR, HeapTuple \fIrow\fR, int \fIncols\fR, + int * \fIcolnum\fR, Datum * \fIvalues\fR, const char * \fInulls\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_modifytuple\fR +creates a new row by substituting new values for selected columns, copying the original row\*(Aqs columns at other positions\&. The input row is not modified\&. +.SH "ARGUMENTS" +.PP +Relation \fIrel\fR +.RS 4 +Used only as the source of the row descriptor for the row\&. (Passing a relation rather than a row descriptor is a misfeature\&.) +.RE +.PP +HeapTuple \fIrow\fR +.RS 4 +row to be modified +.RE +.PP +int \fIncols\fR +.RS 4 +number of column numbers in the array +\fIcolnum\fR +.RE +.PP +int * \fIcolnum\fR +.RS 4 +array of the numbers of the columns that are to be changed (column numbers start at 1) +.RE +.PP +Datum * \fIvalues\fR +.RS 4 +new values for the specified columns +.RE +.PP +const char * \fINulls\fR +.RS 4 +which new values are null, if any (see +\fBSPI_execute_plan\fR +for the format) +.RE +.SH "RETURN VALUE" +.PP +new row with modifications, allocated in the upper executor context; +NULL +only if +\fIrow\fR +is +NULL +.PP +On error, +\fISPI_result\fR +is set as follows: +.PP +SPI_ERROR_ARGUMENT +.RS 4 +if +\fIrel\fR +is +NULL, or if +\fIrow\fR +is +NULL, or if +\fIncols\fR +is less than or equal to 0, or if +\fIcolnum\fR +is +NULL, or if +\fIvalues\fR +is +NULL\&. +.RE +.PP +SPI_ERROR_NOATTRIBUTE +.RS 4 +if +\fIcolnum\fR +contains an invalid column number (less than or equal to 0 or greater than the number of column in +\fIrow\fR) +.RE diff --git a/doc/src/sgml/man3/SPI_palloc.3 b/doc/src/sgml/man3/SPI_palloc.3 new file mode 100644 index 000000000..8385f3048 --- /dev/null +++ b/doc/src/sgml/man3/SPI_palloc.3 @@ -0,0 +1,51 @@ +'\" t +.\" Title: SPI_palloc +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_PALLOC" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_palloc \- allocate memory in the upper executor context +.\" SPI_palloc +.SH "SYNOPSIS" +.sp +.nf +void * SPI_palloc(Size \fIsize\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_palloc\fR +allocates memory in the upper executor context\&. +.SH "ARGUMENTS" +.PP +Size \fIsize\fR +.RS 4 +size in bytes of storage to allocate +.RE +.SH "RETURN VALUE" +.PP +pointer to new storage space of the specified size diff --git a/doc/src/sgml/man3/SPI_pfree.3 b/doc/src/sgml/man3/SPI_pfree.3 new file mode 100644 index 000000000..a8283f772 --- /dev/null +++ b/doc/src/sgml/man3/SPI_pfree.3 @@ -0,0 +1,54 @@ +'\" t +.\" Title: SPI_pfree +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_PFREE" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_pfree \- free memory in the upper executor context +.\" SPI_pfree +.SH "SYNOPSIS" +.sp +.nf +void SPI_pfree(void * \fIpointer\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_pfree\fR +frees memory previously allocated using +\fBSPI_palloc\fR +or +\fBSPI_repalloc\fR\&. +.PP +This function is no longer different from plain +\fBpfree\fR\&. It\*(Aqs kept just for backward compatibility of existing code\&. +.SH "ARGUMENTS" +.PP +void * \fIpointer\fR +.RS 4 +pointer to existing storage to free +.RE diff --git a/doc/src/sgml/man3/SPI_pop.3 b/doc/src/sgml/man3/SPI_pop.3 new file mode 100644 index 000000000..0b6f929c3 --- /dev/null +++ b/doc/src/sgml/man3/SPI_pop.3 @@ -0,0 +1,43 @@ +'\" t +.\" Title: SPI_pop +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_POP" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_pop \- pop SPI stack to return from recursive SPI usage +.\" SPI_pop +.SH "SYNOPSIS" +.sp +.nf +void SPI_pop(void) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_pop\fR +pops the previous environment from the SPI call stack\&. See +\fBSPI_push\fR\&. diff --git a/doc/src/sgml/man3/SPI_prepare.3 b/doc/src/sgml/man3/SPI_prepare.3 new file mode 100644 index 000000000..bdea07057 --- /dev/null +++ b/doc/src/sgml/man3/SPI_prepare.3 @@ -0,0 +1,127 @@ +'\" t +.\" Title: SPI_prepare +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_PREPARE" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_prepare \- prepare a statement, without executing it yet +.\" SPI_prepare +.SH "SYNOPSIS" +.sp +.nf +SPIPlanPtr SPI_prepare(const char * \fIcommand\fR, int \fInargs\fR, Oid * \fIargtypes\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_prepare\fR +creates and returns a prepared statement for the specified command, but doesn\*(Aqt execute the command\&. The prepared statement can later be executed repeatedly using +\fBSPI_execute_plan\fR\&. +.PP +When the same or a similar command is to be executed repeatedly, it is generally advantageous to perform parse analysis only once, and might furthermore be advantageous to re\-use an execution plan for the command\&. +\fBSPI_prepare\fR +converts a command string into a prepared statement that encapsulates the results of parse analysis\&. The prepared statement also provides a place for caching an execution plan if it is found that generating a custom plan for each execution is not helpful\&. +.PP +A prepared command can be generalized by writing parameters ($1, +$2, etc\&.) in place of what would be constants in a normal command\&. The actual values of the parameters are then specified when +\fBSPI_execute_plan\fR +is called\&. This allows the prepared command to be used over a wider range of situations than would be possible without parameters\&. +.PP +The statement returned by +\fBSPI_prepare\fR +can be used only in the current invocation of the procedure, since +\fBSPI_finish\fR +frees memory allocated for such a statement\&. But the statement can be saved for longer using the functions +\fBSPI_keepplan\fR +or +\fBSPI_saveplan\fR\&. +.SH "ARGUMENTS" +.PP +const char * \fIcommand\fR +.RS 4 +command string +.RE +.PP +int \fInargs\fR +.RS 4 +number of input parameters ($1, +$2, etc\&.) +.RE +.PP +Oid * \fIargtypes\fR +.RS 4 +pointer to an array containing the +OIDs of the data types of the parameters +.RE +.SH "RETURN VALUE" +.PP + +\fBSPI_prepare\fR +returns a non\-null pointer to an +SPIPlan, which is an opaque struct representing a prepared statement\&. On error, +NULL +will be returned, and +\fISPI_result\fR +will be set to one of the same error codes used by +\fBSPI_execute\fR, except that it is set to +SPI_ERROR_ARGUMENT +if +\fIcommand\fR +is +NULL, or if +\fInargs\fR +is less than 0, or if +\fInargs\fR +is greater than 0 and +\fIargtypes\fR +is +NULL\&. +.SH "NOTES" +.PP +If no parameters are defined, a generic plan will be created at the first use of +\fBSPI_execute_plan\fR, and used for all subsequent executions as well\&. If there are parameters, the first few uses of +\fBSPI_execute_plan\fR +will generate custom plans that are specific to the supplied parameter values\&. After enough uses of the same prepared statement, +\fBSPI_execute_plan\fR +will build a generic plan, and if that is not too much more expensive than the custom plans, it will start using the generic plan instead of re\-planning each time\&. If this default behavior is unsuitable, you can alter it by passing the +CURSOR_OPT_GENERIC_PLAN +or +CURSOR_OPT_CUSTOM_PLAN +flag to +\fBSPI_prepare_cursor\fR, to force use of generic or custom plans respectively\&. +.PP +This function should only be called from a connected procedure\&. +.PP + +SPIPlanPtr +is declared as a pointer to an opaque struct type in +spi\&.h\&. It is unwise to try to access its contents directly, as that makes your code much more likely to break in future revisions of +PostgreSQL\&. +.PP +The name +SPIPlanPtr +is somewhat historical, since the data structure no longer necessarily contains an execution plan\&. diff --git a/doc/src/sgml/man3/SPI_prepare_cursor.3 b/doc/src/sgml/man3/SPI_prepare_cursor.3 new file mode 100644 index 000000000..ac10cf59c --- /dev/null +++ b/doc/src/sgml/man3/SPI_prepare_cursor.3 @@ -0,0 +1,94 @@ +'\" t +.\" Title: SPI_prepare_cursor +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_PREPARE_CURSOR" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_prepare_cursor \- prepare a statement, without executing it yet +.\" SPI_prepare_cursor +.SH "SYNOPSIS" +.sp +.nf +SPIPlanPtr SPI_prepare_cursor(const char * \fIcommand\fR, int \fInargs\fR, + Oid * \fIargtypes\fR, int \fIcursorOptions\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_prepare_cursor\fR +is identical to +\fBSPI_prepare\fR, except that it also allows specification of the planner\*(Aqs +\(lqcursor options\(rq +parameter\&. This is a bit mask having the values shown in +nodes/parsenodes\&.h +for the +options +field of +DeclareCursorStmt\&. +\fBSPI_prepare\fR +always takes the cursor options as zero\&. +.SH "ARGUMENTS" +.PP +const char * \fIcommand\fR +.RS 4 +command string +.RE +.PP +int \fInargs\fR +.RS 4 +number of input parameters ($1, +$2, etc\&.) +.RE +.PP +Oid * \fIargtypes\fR +.RS 4 +pointer to an array containing the +OIDs of the data types of the parameters +.RE +.PP +int \fIcursorOptions\fR +.RS 4 +integer bit mask of cursor options; zero produces default behavior +.RE +.SH "RETURN VALUE" +.PP + +\fBSPI_prepare_cursor\fR +has the same return conventions as +\fBSPI_prepare\fR\&. +.SH "NOTES" +.PP +Useful bits to set in +\fIcursorOptions\fR +include +CURSOR_OPT_SCROLL, +CURSOR_OPT_NO_SCROLL, +CURSOR_OPT_FAST_PLAN, +CURSOR_OPT_GENERIC_PLAN, and +CURSOR_OPT_CUSTOM_PLAN\&. Note in particular that +CURSOR_OPT_HOLD +is ignored\&. diff --git a/doc/src/sgml/man3/SPI_prepare_params.3 b/doc/src/sgml/man3/SPI_prepare_params.3 new file mode 100644 index 000000000..53538738b --- /dev/null +++ b/doc/src/sgml/man3/SPI_prepare_params.3 @@ -0,0 +1,74 @@ +'\" t +.\" Title: SPI_prepare_params +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_PREPARE_PARAMS" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_prepare_params \- prepare a statement, without executing it yet +.\" SPI_prepare_params +.SH "SYNOPSIS" +.sp +.nf +SPIPlanPtr SPI_prepare_params(const char * \fIcommand\fR, + ParserSetupHook \fIparserSetup\fR, + void * \fIparserSetupArg\fR, + int \fIcursorOptions\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_prepare_params\fR +creates and returns a prepared statement for the specified command, but doesn\*(Aqt execute the command\&. This function is equivalent to +\fBSPI_prepare_cursor\fR, with the addition that the caller can specify parser hook functions to control the parsing of external parameter references\&. +.SH "ARGUMENTS" +.PP +const char * \fIcommand\fR +.RS 4 +command string +.RE +.PP +ParserSetupHook \fIparserSetup\fR +.RS 4 +Parser hook setup function +.RE +.PP +void * \fIparserSetupArg\fR +.RS 4 +passthrough argument for +\fIparserSetup\fR +.RE +.PP +int \fIcursorOptions\fR +.RS 4 +integer bit mask of cursor options; zero produces default behavior +.RE +.SH "RETURN VALUE" +.PP + +\fBSPI_prepare_params\fR +has the same return conventions as +\fBSPI_prepare\fR\&. diff --git a/doc/src/sgml/man3/SPI_push.3 b/doc/src/sgml/man3/SPI_push.3 new file mode 100644 index 000000000..520c840ee --- /dev/null +++ b/doc/src/sgml/man3/SPI_push.3 @@ -0,0 +1,60 @@ +'\" t +.\" Title: SPI_push +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_PUSH" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_push \- push SPI stack to allow recursive SPI usage +.\" SPI_push +.SH "SYNOPSIS" +.sp +.nf +void SPI_push(void) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_push\fR +should be called before executing another procedure that might itself wish to use SPI\&. After +\fBSPI_push\fR, SPI is no longer in a +\(lqconnected\(rq +state, and SPI function calls will be rejected unless a fresh +\fBSPI_connect\fR +is done\&. This ensures a clean separation between your procedure\*(Aqs SPI state and that of another procedure you call\&. After the other procedure returns, call +\fBSPI_pop\fR +to restore access to your own SPI state\&. +.PP +Note that +\fBSPI_execute\fR +and related functions automatically do the equivalent of +\fBSPI_push\fR +before passing control back to the SQL execution engine, so it is not necessary for you to worry about this when using those functions\&. Only when you are directly calling arbitrary code that might contain +\fBSPI_connect\fR +calls do you need to issue +\fBSPI_push\fR +and +\fBSPI_pop\fR\&. diff --git a/doc/src/sgml/man3/SPI_repalloc.3 b/doc/src/sgml/man3/SPI_repalloc.3 new file mode 100644 index 000000000..79ad6ef1e --- /dev/null +++ b/doc/src/sgml/man3/SPI_repalloc.3 @@ -0,0 +1,60 @@ +'\" t +.\" Title: SPI_repalloc +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_REPALLOC" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_repalloc \- reallocate memory in the upper executor context +.\" SPI_repalloc +.SH "SYNOPSIS" +.sp +.nf +void * SPI_repalloc(void * \fIpointer\fR, Size \fIsize\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_repalloc\fR +changes the size of a memory segment previously allocated using +\fBSPI_palloc\fR\&. +.PP +This function is no longer different from plain +\fBrepalloc\fR\&. It\*(Aqs kept just for backward compatibility of existing code\&. +.SH "ARGUMENTS" +.PP +void * \fIpointer\fR +.RS 4 +pointer to existing storage to change +.RE +.PP +Size \fIsize\fR +.RS 4 +size in bytes of storage to allocate +.RE +.SH "RETURN VALUE" +.PP +pointer to new storage space of specified size with the contents copied from the existing area diff --git a/doc/src/sgml/man3/SPI_returntuple.3 b/doc/src/sgml/man3/SPI_returntuple.3 new file mode 100644 index 000000000..7376d5509 --- /dev/null +++ b/doc/src/sgml/man3/SPI_returntuple.3 @@ -0,0 +1,74 @@ +'\" t +.\" Title: SPI_returntuple +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_RETURNTUPLE" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_returntuple \- prepare to return a tuple as a Datum +.\" SPI_returntuple +.SH "SYNOPSIS" +.sp +.nf +HeapTupleHeader SPI_returntuple(HeapTuple \fIrow\fR, TupleDesc \fIrowdesc\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_returntuple\fR +makes a copy of a row in the upper executor context, returning it in the form of a row type +Datum\&. The returned pointer need only be converted to +Datum +via +\fBPointerGetDatum\fR +before returning\&. +.PP +Note that this should be used for functions that are declared to return composite types\&. It is not used for triggers; use +\fBSPI_copytuple\fR +for returning a modified row in a trigger\&. +.SH "ARGUMENTS" +.PP +HeapTuple \fIrow\fR +.RS 4 +row to be copied +.RE +.PP +TupleDesc \fIrowdesc\fR +.RS 4 +descriptor for row (pass the same descriptor each time for most effective caching) +.RE +.SH "RETURN VALUE" +.PP + +HeapTupleHeader +pointing to copied row; +NULL +only if +\fIrow\fR +or +\fIrowdesc\fR +is +NULL diff --git a/doc/src/sgml/man3/SPI_saveplan.3 b/doc/src/sgml/man3/SPI_saveplan.3 new file mode 100644 index 000000000..3413755bc --- /dev/null +++ b/doc/src/sgml/man3/SPI_saveplan.3 @@ -0,0 +1,82 @@ +'\" t +.\" Title: SPI_saveplan +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_SAVEPLAN" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_saveplan \- save a prepared statement +.\" SPI_saveplan +.SH "SYNOPSIS" +.sp +.nf +SPIPlanPtr SPI_saveplan(SPIPlanPtr \fIplan\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_saveplan\fR +copies a passed statement (prepared by +\fBSPI_prepare\fR) into memory that will not be freed by +\fBSPI_finish\fR +nor by the transaction manager, and returns a pointer to the copied statement\&. This gives you the ability to reuse prepared statements in the subsequent invocations of your procedure in the current session\&. +.SH "ARGUMENTS" +.PP +SPIPlanPtr \fIplan\fR +.RS 4 +the prepared statement to be saved +.RE +.SH "RETURN VALUE" +.PP +Pointer to the copied statement; or +NULL +if unsuccessful\&. On error, +\fISPI_result\fR +is set thus: +.PP +SPI_ERROR_ARGUMENT +.RS 4 +if +\fIplan\fR +is +NULL +or invalid +.RE +.PP +SPI_ERROR_UNCONNECTED +.RS 4 +if called from an unconnected procedure +.RE +.SH "NOTES" +.PP +The originally passed\-in statement is not freed, so you might wish to do +\fBSPI_freeplan\fR +on it to avoid leaking memory until +\fBSPI_finish\fR\&. +.PP +In most cases, +\fBSPI_keepplan\fR +is preferred to this function, since it accomplishes largely the same result without needing to physically copy the prepared statement\*(Aqs data structures\&. diff --git a/doc/src/sgml/man3/SPI_scroll_cursor_fetch.3 b/doc/src/sgml/man3/SPI_scroll_cursor_fetch.3 new file mode 100644 index 000000000..cb500fe6b --- /dev/null +++ b/doc/src/sgml/man3/SPI_scroll_cursor_fetch.3 @@ -0,0 +1,94 @@ +'\" t +.\" Title: SPI_scroll_cursor_fetch +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_SCROLL_CURSOR_FETCH" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_scroll_cursor_fetch \- fetch some rows from a cursor +.\" SPI_scroll_cursor_fetch +.SH "SYNOPSIS" +.sp +.nf +void SPI_scroll_cursor_fetch(Portal \fIportal\fR, FetchDirection \fIdirection\fR, + long \fIcount\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_scroll_cursor_fetch\fR +fetches some rows from a cursor\&. This is equivalent to the SQL command +\fBFETCH\fR\&. +.SH "ARGUMENTS" +.PP +Portal \fIportal\fR +.RS 4 +portal containing the cursor +.RE +.PP +FetchDirection \fIdirection\fR +.RS 4 +one of +FETCH_FORWARD, +FETCH_BACKWARD, +FETCH_ABSOLUTE +or +FETCH_RELATIVE +.RE +.PP +long \fIcount\fR +.RS 4 +number of rows to fetch for +FETCH_FORWARD +or +FETCH_BACKWARD; absolute row number to fetch for +FETCH_ABSOLUTE; or relative row number to fetch for +FETCH_RELATIVE +.RE +.SH "RETURN VALUE" +.PP + +\fISPI_processed\fR +and +\fISPI_tuptable\fR +are set as in +\fBSPI_execute\fR +if successful\&. +.SH "NOTES" +.PP +See the SQL +\fBFETCH\fR(7) +command for details of the interpretation of the +\fIdirection\fR +and +\fIcount\fR +parameters\&. +.PP +Direction values other than +FETCH_FORWARD +may fail if the cursor\*(Aqs plan was not created with the +CURSOR_OPT_SCROLL +option\&. diff --git a/doc/src/sgml/man3/SPI_scroll_cursor_move.3 b/doc/src/sgml/man3/SPI_scroll_cursor_move.3 new file mode 100644 index 000000000..6bac9218f --- /dev/null +++ b/doc/src/sgml/man3/SPI_scroll_cursor_move.3 @@ -0,0 +1,95 @@ +'\" t +.\" Title: SPI_scroll_cursor_move +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SPI_SCROLL_CURSOR_MOVE" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SPI_scroll_cursor_move \- move a cursor +.\" SPI_scroll_cursor_move +.SH "SYNOPSIS" +.sp +.nf +void SPI_scroll_cursor_move(Portal \fIportal\fR, FetchDirection \fIdirection\fR, + long \fIcount\fR) +.fi +.SH "DESCRIPTION" +.PP + +\fBSPI_scroll_cursor_move\fR +skips over some number of rows in a cursor\&. This is equivalent to the SQL command +\fBMOVE\fR\&. +.SH "ARGUMENTS" +.PP +Portal \fIportal\fR +.RS 4 +portal containing the cursor +.RE +.PP +FetchDirection \fIdirection\fR +.RS 4 +one of +FETCH_FORWARD, +FETCH_BACKWARD, +FETCH_ABSOLUTE +or +FETCH_RELATIVE +.RE +.PP +long \fIcount\fR +.RS 4 +number of rows to move for +FETCH_FORWARD +or +FETCH_BACKWARD; absolute row number to move to for +FETCH_ABSOLUTE; or relative row number to move to for +FETCH_RELATIVE +.RE +.SH "RETURN VALUE" +.PP + +\fISPI_processed\fR +is set as in +\fBSPI_execute\fR +if successful\&. +\fISPI_tuptable\fR +is set to +NULL, since no rows are returned by this function\&. +.SH "NOTES" +.PP +See the SQL +\fBFETCH\fR(7) +command for details of the interpretation of the +\fIdirection\fR +and +\fIcount\fR +parameters\&. +.PP +Direction values other than +FETCH_FORWARD +may fail if the cursor\*(Aqs plan was not created with the +CURSOR_OPT_SCROLL +option\&. diff --git a/doc/src/sgml/man3/dblink.3 b/doc/src/sgml/man3/dblink.3 new file mode 100644 index 000000000..8e25ac169 --- /dev/null +++ b/doc/src/sgml/man3/dblink.3 @@ -0,0 +1,210 @@ +'\" t +.\" Title: dblink +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DBLINK" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +dblink \- executes a query in a remote database +.SH "SYNOPSIS" +.sp +.nf +dblink(text connname, text sql [, bool fail_on_error]) returns setof record +dblink(text connstr, text sql [, bool fail_on_error]) returns setof record +dblink(text sql [, bool fail_on_error]) returns setof record +.fi +.SH "DESCRIPTION" +.PP + +\fBdblink\fR +executes a query (usually a +\fBSELECT\fR, but it can be any SQL statement that returns rows) in a remote database\&. +.PP +When two +text +arguments are given, the first one is first looked up as a persistent connection\*(Aqs name; if found, the command is executed on that connection\&. If not found, the first argument is treated as a connection info string as for +\fBdblink_connect\fR, and the indicated connection is made just for the duration of this command\&. +.SH "ARGUMENTS" +.PP +\fIconname\fR +.RS 4 +Name of the connection to use; omit this parameter to use the unnamed connection\&. +.RE +.PP +\fIconnstr\fR +.RS 4 +A connection info string, as previously described for +\fBdblink_connect\fR\&. +.RE +.PP +\fIsql\fR +.RS 4 +The SQL query that you wish to execute in the remote database, for example +select * from foo\&. +.RE +.PP +\fIfail_on_error\fR +.RS 4 +If true (the default when omitted) then an error thrown on the remote side of the connection causes an error to also be thrown locally\&. If false, the remote error is locally reported as a NOTICE, and the function returns no rows\&. +.RE +.SH "RETURN VALUE" +.PP +The function returns the row(s) produced by the query\&. Since +\fBdblink\fR +can be used with any query, it is declared to return +record, rather than specifying any particular set of columns\&. This means that you must specify the expected set of columns in the calling query \(em otherwise +PostgreSQL +would not know what to expect\&. Here is an example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT * + FROM dblink(\*(Aqdbname=mydb\*(Aq, \*(Aqselect proname, prosrc from pg_proc\*(Aq) + AS t1(proname name, prosrc text) + WHERE proname LIKE \*(Aqbytea%\*(Aq; +.fi +.if n \{\ +.RE +.\} +.sp +The +\(lqalias\(rq +part of the +FROM +clause must specify the column names and types that the function will return\&. (Specifying column names in an alias is actually standard SQL syntax, but specifying column types is a +PostgreSQL +extension\&.) This allows the system to understand what +* +should expand to, and what +proname +in the +WHERE +clause refers to, in advance of trying to execute the function\&. At run time, an error will be thrown if the actual query result from the remote database does not have the same number of columns shown in the +FROM +clause\&. The column names need not match, however, and +\fBdblink\fR +does not insist on exact type matches either\&. It will succeed so long as the returned data strings are valid input for the column type declared in the +FROM +clause\&. +.SH "NOTES" +.PP +A convenient way to use +\fBdblink\fR +with predetermined queries is to create a view\&. This allows the column type information to be buried in the view, instead of having to spell it out in every query\&. For example, +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE VIEW myremote_pg_proc AS + SELECT * + FROM dblink(\*(Aqdbname=postgres\*(Aq, \*(Aqselect proname, prosrc from pg_proc\*(Aq) + AS t1(proname name, prosrc text); + +SELECT * FROM myremote_pg_proc WHERE proname LIKE \*(Aqbytea%\*(Aq; +.fi +.if n \{\ +.RE +.\} +.SH "EXAMPLES" +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT * FROM dblink(\*(Aqdbname=postgres\*(Aq, \*(Aqselect proname, prosrc from pg_proc\*(Aq) + AS t1(proname name, prosrc text) WHERE proname LIKE \*(Aqbytea%\*(Aq; + proname | prosrc +\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\- + byteacat | byteacat + byteaeq | byteaeq + bytealt | bytealt + byteale | byteale + byteagt | byteagt + byteage | byteage + byteane | byteane + byteacmp | byteacmp + bytealike | bytealike + byteanlike | byteanlike + byteain | byteain + byteaout | byteaout +(12 rows) + +SELECT dblink_connect(\*(Aqdbname=postgres\*(Aq); + dblink_connect +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + OK +(1 row) + +SELECT * FROM dblink(\*(Aqselect proname, prosrc from pg_proc\*(Aq) + AS t1(proname name, prosrc text) WHERE proname LIKE \*(Aqbytea%\*(Aq; + proname | prosrc +\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\- + byteacat | byteacat + byteaeq | byteaeq + bytealt | bytealt + byteale | byteale + byteagt | byteagt + byteage | byteage + byteane | byteane + byteacmp | byteacmp + bytealike | bytealike + byteanlike | byteanlike + byteain | byteain + byteaout | byteaout +(12 rows) + +SELECT dblink_connect(\*(Aqmyconn\*(Aq, \*(Aqdbname=regression\*(Aq); + dblink_connect +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + OK +(1 row) + +SELECT * FROM dblink(\*(Aqmyconn\*(Aq, \*(Aqselect proname, prosrc from pg_proc\*(Aq) + AS t1(proname name, prosrc text) WHERE proname LIKE \*(Aqbytea%\*(Aq; + proname | prosrc +\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\- + bytearecv | bytearecv + byteasend | byteasend + byteale | byteale + byteagt | byteagt + byteage | byteage + byteane | byteane + byteacmp | byteacmp + bytealike | bytealike + byteanlike | byteanlike + byteacat | byteacat + byteaeq | byteaeq + bytealt | bytealt + byteain | byteain + byteaout | byteaout +(14 rows) +.fi +.if n \{\ +.RE +.\} diff --git a/doc/src/sgml/man3/dblink_build_sql_delete.3 b/doc/src/sgml/man3/dblink_build_sql_delete.3 new file mode 100644 index 000000000..48b31f5bd --- /dev/null +++ b/doc/src/sgml/man3/dblink_build_sql_delete.3 @@ -0,0 +1,100 @@ +'\" t +.\" Title: dblink_build_sql_delete +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DBLINK_BUILD_SQL_DELETE" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +dblink_build_sql_delete \- builds a DELETE statement using supplied values for primary key field values +.SH "SYNOPSIS" +.sp +.nf +dblink_build_sql_delete(text relname, + int2vector primary_key_attnums, + integer num_primary_key_atts, + text[] tgt_pk_att_vals_array) returns text +.fi +.SH "DESCRIPTION" +.PP + +\fBdblink_build_sql_delete\fR +can be useful in doing selective replication of a local table to a remote database\&. It builds a SQL +\fBDELETE\fR +command that will delete the row with the given primary key values\&. +.SH "ARGUMENTS" +.PP +\fIrelname\fR +.RS 4 +Name of a local relation, for example +foo +or +myschema\&.mytab\&. Include double quotes if the name is mixed\-case or contains special characters, for example +"FooBar"; without quotes, the string will be folded to lower case\&. +.RE +.PP +\fIprimary_key_attnums\fR +.RS 4 +Attribute numbers (1\-based) of the primary key fields, for example +1 2\&. +.RE +.PP +\fInum_primary_key_atts\fR +.RS 4 +The number of primary key fields\&. +.RE +.PP +\fItgt_pk_att_vals_array\fR +.RS 4 +Values of the primary key fields to be used in the resulting +\fBDELETE\fR +command\&. Each field is represented in text form\&. +.RE +.SH "RETURN VALUE" +.PP +Returns the requested SQL statement as text\&. +.SH "NOTES" +.PP +As of +PostgreSQL +9\&.0, the attribute numbers in +\fIprimary_key_attnums\fR +are interpreted as logical column numbers, corresponding to the column\*(Aqs position in +SELECT * FROM relname\&. Previous versions interpreted the numbers as physical column positions\&. There is a difference if any column(s) to the left of the indicated column have been dropped during the lifetime of the table\&. +.SH "EXAMPLES" +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT dblink_build_sql_delete(\*(Aq"MyFoo"\*(Aq, \*(Aq1 2\*(Aq, 2, \*(Aq{"1", "b"}\*(Aq); + dblink_build_sql_delete +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + DELETE FROM "MyFoo" WHERE f1=\*(Aq1\*(Aq AND f2=\*(Aqb\*(Aq +(1 row) +.fi +.if n \{\ +.RE +.\} diff --git a/doc/src/sgml/man3/dblink_build_sql_insert.3 b/doc/src/sgml/man3/dblink_build_sql_insert.3 new file mode 100644 index 000000000..a0cb7349d --- /dev/null +++ b/doc/src/sgml/man3/dblink_build_sql_insert.3 @@ -0,0 +1,106 @@ +'\" t +.\" Title: dblink_build_sql_insert +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DBLINK_BUILD_SQL_INSERT" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +dblink_build_sql_insert \- builds an INSERT statement using a local tuple, replacing the primary key field values with alternative supplied values +.SH "SYNOPSIS" +.sp +.nf +dblink_build_sql_insert(text relname, + int2vector primary_key_attnums, + integer num_primary_key_atts, + text[] src_pk_att_vals_array, + text[] tgt_pk_att_vals_array) returns text +.fi +.SH "DESCRIPTION" +.PP + +\fBdblink_build_sql_insert\fR +can be useful in doing selective replication of a local table to a remote database\&. It selects a row from the local table based on primary key, and then builds a SQL +\fBINSERT\fR +command that will duplicate that row, but with the primary key values replaced by the values in the last argument\&. (To make an exact copy of the row, just specify the same values for the last two arguments\&.) +.SH "ARGUMENTS" +.PP +\fIrelname\fR +.RS 4 +Name of a local relation, for example +foo +or +myschema\&.mytab\&. Include double quotes if the name is mixed\-case or contains special characters, for example +"FooBar"; without quotes, the string will be folded to lower case\&. +.RE +.PP +\fIprimary_key_attnums\fR +.RS 4 +Attribute numbers (1\-based) of the primary key fields, for example +1 2\&. +.RE +.PP +\fInum_primary_key_atts\fR +.RS 4 +The number of primary key fields\&. +.RE +.PP +\fIsrc_pk_att_vals_array\fR +.RS 4 +Values of the primary key fields to be used to look up the local tuple\&. Each field is represented in text form\&. An error is thrown if there is no local row with these primary key values\&. +.RE +.PP +\fItgt_pk_att_vals_array\fR +.RS 4 +Values of the primary key fields to be placed in the resulting +\fBINSERT\fR +command\&. Each field is represented in text form\&. +.RE +.SH "RETURN VALUE" +.PP +Returns the requested SQL statement as text\&. +.SH "NOTES" +.PP +As of +PostgreSQL +9\&.0, the attribute numbers in +\fIprimary_key_attnums\fR +are interpreted as logical column numbers, corresponding to the column\*(Aqs position in +SELECT * FROM relname\&. Previous versions interpreted the numbers as physical column positions\&. There is a difference if any column(s) to the left of the indicated column have been dropped during the lifetime of the table\&. +.SH "EXAMPLES" +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT dblink_build_sql_insert(\*(Aqfoo\*(Aq, \*(Aq1 2\*(Aq, 2, \*(Aq{"1", "a"}\*(Aq, \*(Aq{"1", "b\*(Aq\*(Aqa"}\*(Aq); + dblink_build_sql_insert +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + INSERT INTO foo(f1,f2,f3) VALUES(\*(Aq1\*(Aq,\*(Aqb\*(Aq\*(Aqa\*(Aq,\*(Aq1\*(Aq) +(1 row) +.fi +.if n \{\ +.RE +.\} diff --git a/doc/src/sgml/man3/dblink_build_sql_update.3 b/doc/src/sgml/man3/dblink_build_sql_update.3 new file mode 100644 index 000000000..caca5328f --- /dev/null +++ b/doc/src/sgml/man3/dblink_build_sql_update.3 @@ -0,0 +1,110 @@ +'\" t +.\" Title: dblink_build_sql_update +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DBLINK_BUILD_SQL_UPDATE" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +dblink_build_sql_update \- builds an UPDATE statement using a local tuple, replacing the primary key field values with alternative supplied values +.SH "SYNOPSIS" +.sp +.nf +dblink_build_sql_update(text relname, + int2vector primary_key_attnums, + integer num_primary_key_atts, + text[] src_pk_att_vals_array, + text[] tgt_pk_att_vals_array) returns text +.fi +.SH "DESCRIPTION" +.PP + +\fBdblink_build_sql_update\fR +can be useful in doing selective replication of a local table to a remote database\&. It selects a row from the local table based on primary key, and then builds a SQL +\fBUPDATE\fR +command that will duplicate that row, but with the primary key values replaced by the values in the last argument\&. (To make an exact copy of the row, just specify the same values for the last two arguments\&.) The +\fBUPDATE\fR +command always assigns all fields of the row \(em the main difference between this and +\fBdblink_build_sql_insert\fR +is that it\*(Aqs assumed that the target row already exists in the remote table\&. +.SH "ARGUMENTS" +.PP +\fIrelname\fR +.RS 4 +Name of a local relation, for example +foo +or +myschema\&.mytab\&. Include double quotes if the name is mixed\-case or contains special characters, for example +"FooBar"; without quotes, the string will be folded to lower case\&. +.RE +.PP +\fIprimary_key_attnums\fR +.RS 4 +Attribute numbers (1\-based) of the primary key fields, for example +1 2\&. +.RE +.PP +\fInum_primary_key_atts\fR +.RS 4 +The number of primary key fields\&. +.RE +.PP +\fIsrc_pk_att_vals_array\fR +.RS 4 +Values of the primary key fields to be used to look up the local tuple\&. Each field is represented in text form\&. An error is thrown if there is no local row with these primary key values\&. +.RE +.PP +\fItgt_pk_att_vals_array\fR +.RS 4 +Values of the primary key fields to be placed in the resulting +\fBUPDATE\fR +command\&. Each field is represented in text form\&. +.RE +.SH "RETURN VALUE" +.PP +Returns the requested SQL statement as text\&. +.SH "NOTES" +.PP +As of +PostgreSQL +9\&.0, the attribute numbers in +\fIprimary_key_attnums\fR +are interpreted as logical column numbers, corresponding to the column\*(Aqs position in +SELECT * FROM relname\&. Previous versions interpreted the numbers as physical column positions\&. There is a difference if any column(s) to the left of the indicated column have been dropped during the lifetime of the table\&. +.SH "EXAMPLES" +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT dblink_build_sql_update(\*(Aqfoo\*(Aq, \*(Aq1 2\*(Aq, 2, \*(Aq{"1", "a"}\*(Aq, \*(Aq{"1", "b"}\*(Aq); + dblink_build_sql_update +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + UPDATE foo SET f1=\*(Aq1\*(Aq,f2=\*(Aqb\*(Aq,f3=\*(Aq1\*(Aq WHERE f1=\*(Aq1\*(Aq AND f2=\*(Aqb\*(Aq +(1 row) +.fi +.if n \{\ +.RE +.\} diff --git a/doc/src/sgml/man3/dblink_cancel_query.3 b/doc/src/sgml/man3/dblink_cancel_query.3 new file mode 100644 index 000000000..45eae8137 --- /dev/null +++ b/doc/src/sgml/man3/dblink_cancel_query.3 @@ -0,0 +1,64 @@ +'\" t +.\" Title: dblink_cancel_query +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DBLINK_CANCEL_QUERY" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +dblink_cancel_query \- cancels any active query on the named connection +.SH "SYNOPSIS" +.sp +.nf +dblink_cancel_query(text connname) returns text +.fi +.SH "DESCRIPTION" +.PP + +\fBdblink_cancel_query\fR +attempts to cancel any query that is in progress on the named connection\&. Note that this is not certain to succeed (since, for example, the remote query might already have finished)\&. A cancel request simply improves the odds that the query will fail soon\&. You must still complete the normal query protocol, for example by calling +\fBdblink_get_result\fR\&. +.SH "ARGUMENTS" +.PP +\fIconname\fR +.RS 4 +Name of the connection to use\&. +.RE +.SH "RETURN VALUE" +.PP +Returns +OK +if the cancel request has been sent, or the text of an error message on failure\&. +.SH "EXAMPLES" +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT dblink_cancel_query(\*(Aqdtest1\*(Aq); +.fi +.if n \{\ +.RE +.\} diff --git a/doc/src/sgml/man3/dblink_close.3 b/doc/src/sgml/man3/dblink_close.3 new file mode 100644 index 000000000..995d0571b --- /dev/null +++ b/doc/src/sgml/man3/dblink_close.3 @@ -0,0 +1,101 @@ +'\" t +.\" Title: dblink_close +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DBLINK_CLOSE" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +dblink_close \- closes a cursor in a remote database +.SH "SYNOPSIS" +.sp +.nf +dblink_close(text cursorname [, bool fail_on_error]) returns text +dblink_close(text connname, text cursorname [, bool fail_on_error]) returns text +.fi +.SH "DESCRIPTION" +.PP + +\fBdblink_close\fR +closes a cursor previously opened with +\fBdblink_open\fR\&. +.SH "ARGUMENTS" +.PP +\fIconname\fR +.RS 4 +Name of the connection to use; omit this parameter to use the unnamed connection\&. +.RE +.PP +\fIcursorname\fR +.RS 4 +The name of the cursor to close\&. +.RE +.PP +\fIfail_on_error\fR +.RS 4 +If true (the default when omitted) then an error thrown on the remote side of the connection causes an error to also be thrown locally\&. If false, the remote error is locally reported as a NOTICE, and the function\*(Aqs return value is set to +ERROR\&. +.RE +.SH "RETURN VALUE" +.PP +Returns status, either +OK +or +ERROR\&. +.SH "NOTES" +.PP +If +\fBdblink_open\fR +started an explicit transaction block, and this is the last remaining open cursor in this connection, +\fBdblink_close\fR +will issue the matching +\fBCOMMIT\fR\&. +.SH "EXAMPLES" +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT dblink_connect(\*(Aqdbname=postgres\*(Aq); + dblink_connect +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + OK +(1 row) + +SELECT dblink_open(\*(Aqfoo\*(Aq, \*(Aqselect proname, prosrc from pg_proc\*(Aq); + dblink_open +\-\-\-\-\-\-\-\-\-\-\-\-\- + OK +(1 row) + +SELECT dblink_close(\*(Aqfoo\*(Aq); + dblink_close +\-\-\-\-\-\-\-\-\-\-\-\-\-\- + OK +(1 row) +.fi +.if n \{\ +.RE +.\} diff --git a/doc/src/sgml/man3/dblink_connect.3 b/doc/src/sgml/man3/dblink_connect.3 new file mode 100644 index 000000000..a6c0d2ee9 --- /dev/null +++ b/doc/src/sgml/man3/dblink_connect.3 @@ -0,0 +1,150 @@ +'\" t +.\" Title: dblink_connect +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DBLINK_CONNECT" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +dblink_connect \- opens a persistent connection to a remote database +.SH "SYNOPSIS" +.sp +.nf +dblink_connect(text connstr) returns text +dblink_connect(text connname, text connstr) returns text +.fi +.SH "DESCRIPTION" +.PP + +\fBdblink_connect()\fR +establishes a connection to a remote +PostgreSQL +database\&. The server and database to be contacted are identified through a standard +libpq +connection string\&. Optionally, a name can be assigned to the connection\&. Multiple named connections can be open at once, but only one unnamed connection is permitted at a time\&. The connection will persist until closed or until the database session is ended\&. +.PP +The connection string may also be the name of an existing foreign server\&. It is recommended to use the +\fBpostgresql_fdw_validator\fR +when defining the corresponding foreign\-data wrapper\&. See the example below, as well as the following: +CREATE FOREIGN DATA WRAPPER (\fBCREATE_FOREIGN_DATA_WRAPPER\fR(7)), CREATE SERVER (\fBCREATE_SERVER\fR(7)), CREATE USER MAPPING (\fBCREATE_USER_MAPPING\fR(7)) +.SH "ARGUMENTS" +.PP +\fIconname\fR +.RS 4 +The name to use for this connection; if omitted, an unnamed connection is opened, replacing any existing unnamed connection\&. +.RE +.PP +\fIconnstr\fR +.RS 4 +libpq\-style connection info string, for example +hostaddr=127\&.0\&.0\&.1 port=5432 dbname=mydb user=postgres password=mypasswd\&. For details see +\fBPQconnectdb\fR +in +Section 31.1, \(lqDatabase Connection Control Functions\(rq, in the documentation\&. +.RE +.SH "RETURN VALUE" +.PP +Returns status, which is always +OK +(since any error causes the function to throw an error instead of returning)\&. +.SH "NOTES" +.PP +Only superusers may use +\fBdblink_connect\fR +to create non\-password\-authenticated connections\&. If non\-superusers need this capability, use +\fBdblink_connect_u\fR +instead\&. +.PP +It is unwise to choose connection names that contain equal signs, as this opens a risk of confusion with connection info strings in other +dblink +functions\&. +.SH "EXAMPLES" +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT dblink_connect(\*(Aqdbname=postgres\*(Aq); + dblink_connect +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + OK +(1 row) + +SELECT dblink_connect(\*(Aqmyconn\*(Aq, \*(Aqdbname=postgres\*(Aq); + dblink_connect +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + OK +(1 row) + +\-\- FOREIGN DATA WRAPPER functionality +\-\- Note: local connection must require password authentication for this to work properly +\-\- Otherwise, you will receive the following error from dblink_connect(): +\-\- \-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- +\-\- ERROR: password is required +\-\- DETAIL: Non\-superuser cannot connect if the server does not request a password\&. +\-\- HINT: Target server\*(Aqs authentication method must be changed\&. +CREATE USER dblink_regression_test WITH PASSWORD \*(Aqsecret\*(Aq; +CREATE FOREIGN DATA WRAPPER postgresql VALIDATOR postgresql_fdw_validator; +CREATE SERVER fdtest FOREIGN DATA WRAPPER postgresql OPTIONS (hostaddr \*(Aq127\&.0\&.0\&.1\*(Aq, dbname \*(Aqcontrib_regression\*(Aq); + +CREATE USER MAPPING FOR dblink_regression_test SERVER fdtest OPTIONS (user \*(Aqdblink_regression_test\*(Aq, password \*(Aqsecret\*(Aq); +GRANT USAGE ON FOREIGN SERVER fdtest TO dblink_regression_test; +GRANT SELECT ON TABLE foo TO dblink_regression_test; + +\eset ORIGINAL_USER :USER +\ec \- dblink_regression_test +SELECT dblink_connect(\*(Aqmyconn\*(Aq, \*(Aqfdtest\*(Aq); + dblink_connect +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + OK +(1 row) + +SELECT * FROM dblink(\*(Aqmyconn\*(Aq,\*(AqSELECT * FROM foo\*(Aq) AS t(a int, b text, c text[]); + a | b | c +\-\-\-\-+\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + 0 | a | {a0,b0,c0} + 1 | b | {a1,b1,c1} + 2 | c | {a2,b2,c2} + 3 | d | {a3,b3,c3} + 4 | e | {a4,b4,c4} + 5 | f | {a5,b5,c5} + 6 | g | {a6,b6,c6} + 7 | h | {a7,b7,c7} + 8 | i | {a8,b8,c8} + 9 | j | {a9,b9,c9} + 10 | k | {a10,b10,c10} +(11 rows) + +\ec \- :ORIGINAL_USER +REVOKE USAGE ON FOREIGN SERVER fdtest FROM dblink_regression_test; +REVOKE SELECT ON TABLE foo FROM dblink_regression_test; +DROP USER MAPPING FOR dblink_regression_test SERVER fdtest; +DROP USER dblink_regression_test; +DROP SERVER fdtest; +DROP FOREIGN DATA WRAPPER postgresql; +.fi +.if n \{\ +.RE +.\} diff --git a/doc/src/sgml/man3/dblink_connect_u.3 b/doc/src/sgml/man3/dblink_connect_u.3 new file mode 100644 index 000000000..1ff518217 --- /dev/null +++ b/doc/src/sgml/man3/dblink_connect_u.3 @@ -0,0 +1,63 @@ +'\" t +.\" Title: dblink_connect_u +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DBLINK_CONNECT_U" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +dblink_connect_u \- opens a persistent connection to a remote database, insecurely +.SH "SYNOPSIS" +.sp +.nf +dblink_connect_u(text connstr) returns text +dblink_connect_u(text connname, text connstr) returns text +.fi +.SH "DESCRIPTION" +.PP + +\fBdblink_connect_u()\fR +is identical to +\fBdblink_connect()\fR, except that it will allow non\-superusers to connect using any authentication method\&. +.PP +If the remote server selects an authentication method that does not involve a password, then impersonation and subsequent escalation of privileges can occur, because the session will appear to have originated from the user as which the local +PostgreSQL +server runs\&. Also, even if the remote server does demand a password, it is possible for the password to be supplied from the server environment, such as a +~/\&.pgpass +file belonging to the server\*(Aqs user\&. This opens not only a risk of impersonation, but the possibility of exposing a password to an untrustworthy remote server\&. Therefore, +\fBdblink_connect_u()\fR +is initially installed with all privileges revoked from +PUBLIC, making it un\-callable except by superusers\&. In some situations it may be appropriate to grant +EXECUTE +permission for +\fBdblink_connect_u()\fR +to specific users who are considered trustworthy, but this should be done with care\&. It is also recommended that any +~/\&.pgpass +file belonging to the server\*(Aqs user +\fInot\fR +contain any records specifying a wildcard host name\&. +.PP +For further details see +\fBdblink_connect()\fR\&. diff --git a/doc/src/sgml/man3/dblink_disconnect.3 b/doc/src/sgml/man3/dblink_disconnect.3 new file mode 100644 index 000000000..7ee20745d --- /dev/null +++ b/doc/src/sgml/man3/dblink_disconnect.3 @@ -0,0 +1,75 @@ +'\" t +.\" Title: dblink_disconnect +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DBLINK_DISCONNECT" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +dblink_disconnect \- closes a persistent connection to a remote database +.SH "SYNOPSIS" +.sp +.nf +dblink_disconnect() returns text +dblink_disconnect(text connname) returns text +.fi +.SH "DESCRIPTION" +.PP + +\fBdblink_disconnect()\fR +closes a connection previously opened by +\fBdblink_connect()\fR\&. The form with no arguments closes an unnamed connection\&. +.SH "ARGUMENTS" +.PP +\fIconname\fR +.RS 4 +The name of a named connection to be closed\&. +.RE +.SH "RETURN VALUE" +.PP +Returns status, which is always +OK +(since any error causes the function to throw an error instead of returning)\&. +.SH "EXAMPLES" +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT dblink_disconnect(); + dblink_disconnect +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + OK +(1 row) + +SELECT dblink_disconnect(\*(Aqmyconn\*(Aq); + dblink_disconnect +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + OK +(1 row) +.fi +.if n \{\ +.RE +.\} diff --git a/doc/src/sgml/man3/dblink_error_message.3 b/doc/src/sgml/man3/dblink_error_message.3 new file mode 100644 index 000000000..bd4644bc7 --- /dev/null +++ b/doc/src/sgml/man3/dblink_error_message.3 @@ -0,0 +1,61 @@ +'\" t +.\" Title: dblink_error_message +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DBLINK_ERROR_MESSAGE" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +dblink_error_message \- gets last error message on the named connection +.SH "SYNOPSIS" +.sp +.nf +dblink_error_message(text connname) returns text +.fi +.SH "DESCRIPTION" +.PP + +\fBdblink_error_message\fR +fetches the most recent remote error message for a given connection\&. +.SH "ARGUMENTS" +.PP +\fIconname\fR +.RS 4 +Name of the connection to use\&. +.RE +.SH "RETURN VALUE" +.PP +Returns last error message, or an empty string if there has been no error in this connection\&. +.SH "EXAMPLES" +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT dblink_error_message(\*(Aqdtest1\*(Aq); +.fi +.if n \{\ +.RE +.\} diff --git a/doc/src/sgml/man3/dblink_exec.3 b/doc/src/sgml/man3/dblink_exec.3 new file mode 100644 index 000000000..4aa1a7df4 --- /dev/null +++ b/doc/src/sgml/man3/dblink_exec.3 @@ -0,0 +1,118 @@ +'\" t +.\" Title: dblink_exec +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DBLINK_EXEC" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +dblink_exec \- executes a command in a remote database +.SH "SYNOPSIS" +.sp +.nf +dblink_exec(text connname, text sql [, bool fail_on_error]) returns text +dblink_exec(text connstr, text sql [, bool fail_on_error]) returns text +dblink_exec(text sql [, bool fail_on_error]) returns text +.fi +.SH "DESCRIPTION" +.PP + +\fBdblink_exec\fR +executes a command (that is, any SQL statement that doesn\*(Aqt return rows) in a remote database\&. +.PP +When two +text +arguments are given, the first one is first looked up as a persistent connection\*(Aqs name; if found, the command is executed on that connection\&. If not found, the first argument is treated as a connection info string as for +\fBdblink_connect\fR, and the indicated connection is made just for the duration of this command\&. +.SH "ARGUMENTS" +.PP +\fIconname\fR +.RS 4 +Name of the connection to use; omit this parameter to use the unnamed connection\&. +.RE +.PP +\fIconnstr\fR +.RS 4 +A connection info string, as previously described for +\fBdblink_connect\fR\&. +.RE +.PP +\fIsql\fR +.RS 4 +The SQL command that you wish to execute in the remote database, for example +insert into foo values(0,\*(Aqa\*(Aq,\*(Aq{"a0","b0","c0"}\*(Aq)\&. +.RE +.PP +\fIfail_on_error\fR +.RS 4 +If true (the default when omitted) then an error thrown on the remote side of the connection causes an error to also be thrown locally\&. If false, the remote error is locally reported as a NOTICE, and the function\*(Aqs return value is set to +ERROR\&. +.RE +.SH "RETURN VALUE" +.PP +Returns status, either the command\*(Aqs status string or +ERROR\&. +.SH "EXAMPLES" +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT dblink_connect(\*(Aqdbname=dblink_test_standby\*(Aq); + dblink_connect +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + OK +(1 row) + +SELECT dblink_exec(\*(Aqinsert into foo values(21,\*(Aq\*(Aqz\*(Aq\*(Aq,\*(Aq\*(Aq{"a0","b0","c0"}\*(Aq\*(Aq);\*(Aq); + dblink_exec +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + INSERT 943366 1 +(1 row) + +SELECT dblink_connect(\*(Aqmyconn\*(Aq, \*(Aqdbname=regression\*(Aq); + dblink_connect +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + OK +(1 row) + +SELECT dblink_exec(\*(Aqmyconn\*(Aq, \*(Aqinsert into foo values(21,\*(Aq\*(Aqz\*(Aq\*(Aq,\*(Aq\*(Aq{"a0","b0","c0"}\*(Aq\*(Aq);\*(Aq); + dblink_exec +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + INSERT 6432584 1 +(1 row) + +SELECT dblink_exec(\*(Aqmyconn\*(Aq, \*(Aqinsert into pg_class values (\*(Aq\*(Aqfoo\*(Aq\*(Aq)\*(Aq,false); +NOTICE: sql error +DETAIL: ERROR: null value in column "relnamespace" violates not\-null constraint + + dblink_exec +\-\-\-\-\-\-\-\-\-\-\-\-\- + ERROR +(1 row) +.fi +.if n \{\ +.RE +.\} diff --git a/doc/src/sgml/man3/dblink_fetch.3 b/doc/src/sgml/man3/dblink_fetch.3 new file mode 100644 index 000000000..67436571d --- /dev/null +++ b/doc/src/sgml/man3/dblink_fetch.3 @@ -0,0 +1,130 @@ +'\" t +.\" Title: dblink_fetch +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DBLINK_FETCH" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +dblink_fetch \- returns rows from an open cursor in a remote database +.SH "SYNOPSIS" +.sp +.nf +dblink_fetch(text cursorname, int howmany [, bool fail_on_error]) returns setof record +dblink_fetch(text connname, text cursorname, int howmany [, bool fail_on_error]) returns setof record +.fi +.SH "DESCRIPTION" +.PP + +\fBdblink_fetch\fR +fetches rows from a cursor previously established by +\fBdblink_open\fR\&. +.SH "ARGUMENTS" +.PP +\fIconname\fR +.RS 4 +Name of the connection to use; omit this parameter to use the unnamed connection\&. +.RE +.PP +\fIcursorname\fR +.RS 4 +The name of the cursor to fetch from\&. +.RE +.PP +\fIhowmany\fR +.RS 4 +The maximum number of rows to retrieve\&. The next +\fIhowmany\fR +rows are fetched, starting at the current cursor position, moving forward\&. Once the cursor has reached its end, no more rows are produced\&. +.RE +.PP +\fIfail_on_error\fR +.RS 4 +If true (the default when omitted) then an error thrown on the remote side of the connection causes an error to also be thrown locally\&. If false, the remote error is locally reported as a NOTICE, and the function returns no rows\&. +.RE +.SH "RETURN VALUE" +.PP +The function returns the row(s) fetched from the cursor\&. To use this function, you will need to specify the expected set of columns, as previously discussed for +\fBdblink\fR\&. +.SH "NOTES" +.PP +On a mismatch between the number of return columns specified in the +FROM +clause, and the actual number of columns returned by the remote cursor, an error will be thrown\&. In this event, the remote cursor is still advanced by as many rows as it would have been if the error had not occurred\&. The same is true for any other error occurring in the local query after the remote +\fBFETCH\fR +has been done\&. +.SH "EXAMPLES" +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT dblink_connect(\*(Aqdbname=postgres\*(Aq); + dblink_connect +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + OK +(1 row) + +SELECT dblink_open(\*(Aqfoo\*(Aq, \*(Aqselect proname, prosrc from pg_proc where proname like \*(Aq\*(Aqbytea%\*(Aq\*(Aq\*(Aq); + dblink_open +\-\-\-\-\-\-\-\-\-\-\-\-\- + OK +(1 row) + +SELECT * FROM dblink_fetch(\*(Aqfoo\*(Aq, 5) AS (funcname name, source text); + funcname | source +\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\- + byteacat | byteacat + byteacmp | byteacmp + byteaeq | byteaeq + byteage | byteage + byteagt | byteagt +(5 rows) + +SELECT * FROM dblink_fetch(\*(Aqfoo\*(Aq, 5) AS (funcname name, source text); + funcname | source +\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\- + byteain | byteain + byteale | byteale + bytealike | bytealike + bytealt | bytealt + byteane | byteane +(5 rows) + +SELECT * FROM dblink_fetch(\*(Aqfoo\*(Aq, 5) AS (funcname name, source text); + funcname | source +\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\- + byteanlike | byteanlike + byteaout | byteaout +(2 rows) + +SELECT * FROM dblink_fetch(\*(Aqfoo\*(Aq, 5) AS (funcname name, source text); + funcname | source +\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\- +(0 rows) +.fi +.if n \{\ +.RE +.\} diff --git a/doc/src/sgml/man3/dblink_get_connections.3 b/doc/src/sgml/man3/dblink_get_connections.3 new file mode 100644 index 000000000..7c247d69d --- /dev/null +++ b/doc/src/sgml/man3/dblink_get_connections.3 @@ -0,0 +1,57 @@ +'\" t +.\" Title: dblink_get_connections +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DBLINK_GET_CONNECTIONS" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +dblink_get_connections \- returns the names of all open named dblink connections +.SH "SYNOPSIS" +.sp +.nf +dblink_get_connections() returns text[] +.fi +.SH "DESCRIPTION" +.PP + +\fBdblink_get_connections\fR +returns an array of the names of all open named +dblink +connections\&. +.SH "RETURN VALUE" +.PP +Returns a text array of connection names, or NULL if none\&. +.SH "EXAMPLES" +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT dblink_get_connections(); +.fi +.if n \{\ +.RE +.\} diff --git a/doc/src/sgml/man3/dblink_get_notify.3 b/doc/src/sgml/man3/dblink_get_notify.3 new file mode 100644 index 000000000..0a1d1b1c1 --- /dev/null +++ b/doc/src/sgml/man3/dblink_get_notify.3 @@ -0,0 +1,87 @@ +'\" t +.\" Title: dblink_get_notify +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DBLINK_GET_NOTIFY" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +dblink_get_notify \- retrieve async notifications on a connection +.SH "SYNOPSIS" +.sp +.nf +dblink_get_notify() returns setof (notify_name text, be_pid int, extra text) +dblink_get_notify(text connname) returns setof (notify_name text, be_pid int, extra text) +.fi +.SH "DESCRIPTION" +.PP + +\fBdblink_get_notify\fR +retrieves notifications on either the unnamed connection, or on a named connection if specified\&. To receive notifications via dblink, +\fBLISTEN\fR +must first be issued, using +\fBdblink_exec\fR\&. For details see +\fBLISTEN\fR(7) +and +\fBNOTIFY\fR(7)\&. +.SH "ARGUMENTS" +.PP +\fIconname\fR +.RS 4 +The name of a named connection to get notifications on\&. +.RE +.SH "RETURN VALUE" +.PP +Returns +setof (notify_name text, be_pid int, extra text), or an empty set if none\&. +.SH "EXAMPLES" +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT dblink_exec(\*(AqLISTEN virtual\*(Aq); + dblink_exec +\-\-\-\-\-\-\-\-\-\-\-\-\- + LISTEN +(1 row) + +SELECT * FROM dblink_get_notify(); + notify_name | be_pid | extra +\-\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\- +(0 rows) + +NOTIFY virtual; +NOTIFY + +SELECT * FROM dblink_get_notify(); + notify_name | be_pid | extra +\-\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\- + virtual | 1229 | +(1 row) +.fi +.if n \{\ +.RE +.\} diff --git a/doc/src/sgml/man3/dblink_get_pkey.3 b/doc/src/sgml/man3/dblink_get_pkey.3 new file mode 100644 index 000000000..7aed35688 --- /dev/null +++ b/doc/src/sgml/man3/dblink_get_pkey.3 @@ -0,0 +1,94 @@ +'\" t +.\" Title: dblink_get_pkey +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DBLINK_GET_PKEY" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +dblink_get_pkey \- returns the positions and field names of a relation\*(Aqs primary key fields +.SH "SYNOPSIS" +.sp +.nf +dblink_get_pkey(text relname) returns setof dblink_pkey_results +.fi +.SH "DESCRIPTION" +.PP + +\fBdblink_get_pkey\fR +provides information about the primary key of a relation in the local database\&. This is sometimes useful in generating queries to be sent to remote databases\&. +.SH "ARGUMENTS" +.PP +\fIrelname\fR +.RS 4 +Name of a local relation, for example +foo +or +myschema\&.mytab\&. Include double quotes if the name is mixed\-case or contains special characters, for example +"FooBar"; without quotes, the string will be folded to lower case\&. +.RE +.SH "RETURN VALUE" +.PP +Returns one row for each primary key field, or no rows if the relation has no primary key\&. The result row type is defined as +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TYPE dblink_pkey_results AS (position int, colname text); +.fi +.if n \{\ +.RE +.\} +.sp +The +position +column simply runs from 1 to +\fIN\fR; it is the number of the field within the primary key, not the number within the table\*(Aqs columns\&. +.SH "EXAMPLES" +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TABLE foobar ( + f1 int, + f2 int, + f3 int, + PRIMARY KEY (f1, f2, f3) +); +CREATE TABLE + +SELECT * FROM dblink_get_pkey(\*(Aqfoobar\*(Aq); + position | colname +\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\- + 1 | f1 + 2 | f2 + 3 | f3 +(3 rows) +.fi +.if n \{\ +.RE +.\} diff --git a/doc/src/sgml/man3/dblink_get_result.3 b/doc/src/sgml/man3/dblink_get_result.3 new file mode 100644 index 000000000..178e27ac6 --- /dev/null +++ b/doc/src/sgml/man3/dblink_get_result.3 @@ -0,0 +1,144 @@ +'\" t +.\" Title: dblink_get_result +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DBLINK_GET_RESULT" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +dblink_get_result \- gets an async query result +.SH "SYNOPSIS" +.sp +.nf +dblink_get_result(text connname [, bool fail_on_error]) returns setof record +.fi +.SH "DESCRIPTION" +.PP + +\fBdblink_get_result\fR +collects the results of an asynchronous query previously sent with +\fBdblink_send_query\fR\&. If the query is not already completed, +\fBdblink_get_result\fR +will wait until it is\&. +.SH "ARGUMENTS" +.PP +\fIconname\fR +.RS 4 +Name of the connection to use\&. +.RE +.PP +\fIfail_on_error\fR +.RS 4 +If true (the default when omitted) then an error thrown on the remote side of the connection causes an error to also be thrown locally\&. If false, the remote error is locally reported as a NOTICE, and the function returns no rows\&. +.RE +.SH "RETURN VALUE" +.PP +For an async query (that is, a SQL statement returning rows), the function returns the row(s) produced by the query\&. To use this function, you will need to specify the expected set of columns, as previously discussed for +\fBdblink\fR\&. +.PP +For an async command (that is, a SQL statement not returning rows), the function returns a single row with a single text column containing the command\*(Aqs status string\&. It is still necessary to specify that the result will have a single text column in the calling +FROM +clause\&. +.SH "NOTES" +.PP +This function +\fImust\fR +be called if +\fBdblink_send_query\fR +returned 1\&. It must be called once for each query sent, and one additional time to obtain an empty set result, before the connection can be used again\&. +.PP +When using +\fBdblink_send_query\fR +and +\fBdblink_get_result\fR, +dblink +fetches the entire remote query result before returning any of it to the local query processor\&. If the query returns a large number of rows, this can result in transient memory bloat in the local session\&. It may be better to open such a query as a cursor with +\fBdblink_open\fR +and then fetch a manageable number of rows at a time\&. Alternatively, use plain +\fBdblink()\fR, which avoids memory bloat by spooling large result sets to disk\&. +.SH "EXAMPLES" +.sp +.if n \{\ +.RS 4 +.\} +.nf +contrib_regression=# SELECT dblink_connect(\*(Aqdtest1\*(Aq, \*(Aqdbname=contrib_regression\*(Aq); + dblink_connect +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + OK +(1 row) + +contrib_regression=# SELECT * FROM +contrib_regression\-# dblink_send_query(\*(Aqdtest1\*(Aq, \*(Aqselect * from foo where f1 < 3\*(Aq) AS t1; + t1 +\-\-\-\- + 1 +(1 row) + +contrib_regression=# SELECT * FROM dblink_get_result(\*(Aqdtest1\*(Aq) AS t1(f1 int, f2 text, f3 text[]); + f1 | f2 | f3 +\-\-\-\-+\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\- + 0 | a | {a0,b0,c0} + 1 | b | {a1,b1,c1} + 2 | c | {a2,b2,c2} +(3 rows) + +contrib_regression=# SELECT * FROM dblink_get_result(\*(Aqdtest1\*(Aq) AS t1(f1 int, f2 text, f3 text[]); + f1 | f2 | f3 +\-\-\-\-+\-\-\-\-+\-\-\-\- +(0 rows) + +contrib_regression=# SELECT * FROM +contrib_regression\-# dblink_send_query(\*(Aqdtest1\*(Aq, \*(Aqselect * from foo where f1 < 3; select * from foo where f1 > 6\*(Aq) AS t1; + t1 +\-\-\-\- + 1 +(1 row) + +contrib_regression=# SELECT * FROM dblink_get_result(\*(Aqdtest1\*(Aq) AS t1(f1 int, f2 text, f3 text[]); + f1 | f2 | f3 +\-\-\-\-+\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\- + 0 | a | {a0,b0,c0} + 1 | b | {a1,b1,c1} + 2 | c | {a2,b2,c2} +(3 rows) + +contrib_regression=# SELECT * FROM dblink_get_result(\*(Aqdtest1\*(Aq) AS t1(f1 int, f2 text, f3 text[]); + f1 | f2 | f3 +\-\-\-\-+\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + 7 | h | {a7,b7,c7} + 8 | i | {a8,b8,c8} + 9 | j | {a9,b9,c9} + 10 | k | {a10,b10,c10} +(4 rows) + +contrib_regression=# SELECT * FROM dblink_get_result(\*(Aqdtest1\*(Aq) AS t1(f1 int, f2 text, f3 text[]); + f1 | f2 | f3 +\-\-\-\-+\-\-\-\-+\-\-\-\- +(0 rows) +.fi +.if n \{\ +.RE +.\} diff --git a/doc/src/sgml/man3/dblink_is_busy.3 b/doc/src/sgml/man3/dblink_is_busy.3 new file mode 100644 index 000000000..b23a2253d --- /dev/null +++ b/doc/src/sgml/man3/dblink_is_busy.3 @@ -0,0 +1,63 @@ +'\" t +.\" Title: dblink_is_busy +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DBLINK_IS_BUSY" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +dblink_is_busy \- checks if connection is busy with an async query +.SH "SYNOPSIS" +.sp +.nf +dblink_is_busy(text connname) returns int +.fi +.SH "DESCRIPTION" +.PP + +\fBdblink_is_busy\fR +tests whether an async query is in progress\&. +.SH "ARGUMENTS" +.PP +\fIconname\fR +.RS 4 +Name of the connection to check\&. +.RE +.SH "RETURN VALUE" +.PP +Returns 1 if connection is busy, 0 if it is not busy\&. If this function returns 0, it is guaranteed that +\fBdblink_get_result\fR +will not block\&. +.SH "EXAMPLES" +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT dblink_is_busy(\*(Aqdtest1\*(Aq); +.fi +.if n \{\ +.RE +.\} diff --git a/doc/src/sgml/man3/dblink_open.3 b/doc/src/sgml/man3/dblink_open.3 new file mode 100644 index 000000000..a27c20395 --- /dev/null +++ b/doc/src/sgml/man3/dblink_open.3 @@ -0,0 +1,114 @@ +'\" t +.\" Title: dblink_open +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DBLINK_OPEN" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +dblink_open \- opens a cursor in a remote database +.SH "SYNOPSIS" +.sp +.nf +dblink_open(text cursorname, text sql [, bool fail_on_error]) returns text +dblink_open(text connname, text cursorname, text sql [, bool fail_on_error]) returns text +.fi +.SH "DESCRIPTION" +.PP + +\fBdblink_open()\fR +opens a cursor in a remote database\&. The cursor can subsequently be manipulated with +\fBdblink_fetch()\fR +and +\fBdblink_close()\fR\&. +.SH "ARGUMENTS" +.PP +\fIconname\fR +.RS 4 +Name of the connection to use; omit this parameter to use the unnamed connection\&. +.RE +.PP +\fIcursorname\fR +.RS 4 +The name to assign to this cursor\&. +.RE +.PP +\fIsql\fR +.RS 4 +The +\fBSELECT\fR +statement that you wish to execute in the remote database, for example +select * from pg_class\&. +.RE +.PP +\fIfail_on_error\fR +.RS 4 +If true (the default when omitted) then an error thrown on the remote side of the connection causes an error to also be thrown locally\&. If false, the remote error is locally reported as a NOTICE, and the function\*(Aqs return value is set to +ERROR\&. +.RE +.SH "RETURN VALUE" +.PP +Returns status, either +OK +or +ERROR\&. +.SH "NOTES" +.PP +Since a cursor can only persist within a transaction, +\fBdblink_open\fR +starts an explicit transaction block (\fBBEGIN\fR) on the remote side, if the remote side was not already within a transaction\&. This transaction will be closed again when the matching +\fBdblink_close\fR +is executed\&. Note that if you use +\fBdblink_exec\fR +to change data between +\fBdblink_open\fR +and +\fBdblink_close\fR, and then an error occurs or you use +\fBdblink_disconnect\fR +before +\fBdblink_close\fR, your change +\fIwill be lost\fR +because the transaction will be aborted\&. +.SH "EXAMPLES" +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT dblink_connect(\*(Aqdbname=postgres\*(Aq); + dblink_connect +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + OK +(1 row) + +SELECT dblink_open(\*(Aqfoo\*(Aq, \*(Aqselect proname, prosrc from pg_proc\*(Aq); + dblink_open +\-\-\-\-\-\-\-\-\-\-\-\-\- + OK +(1 row) +.fi +.if n \{\ +.RE +.\} diff --git a/doc/src/sgml/man3/dblink_send_query.3 b/doc/src/sgml/man3/dblink_send_query.3 new file mode 100644 index 000000000..a67c90b89 --- /dev/null +++ b/doc/src/sgml/man3/dblink_send_query.3 @@ -0,0 +1,72 @@ +'\" t +.\" Title: dblink_send_query +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DBLINK_SEND_QUERY" "3" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +dblink_send_query \- sends an async query to a remote database +.SH "SYNOPSIS" +.sp +.nf +dblink_send_query(text connname, text sql) returns int +.fi +.SH "DESCRIPTION" +.PP + +\fBdblink_send_query\fR +sends a query to be executed asynchronously, that is, without immediately waiting for the result\&. There must not be an async query already in progress on the connection\&. +.PP +After successfully dispatching an async query, completion status can be checked with +\fBdblink_is_busy\fR, and the results are ultimately collected with +\fBdblink_get_result\fR\&. It is also possible to attempt to cancel an active async query using +\fBdblink_cancel_query\fR\&. +.SH "ARGUMENTS" +.PP +\fIconname\fR +.RS 4 +Name of the connection to use\&. +.RE +.PP +\fIsql\fR +.RS 4 +The SQL statement that you wish to execute in the remote database, for example +select * from pg_class\&. +.RE +.SH "RETURN VALUE" +.PP +Returns 1 if the query was successfully dispatched, 0 otherwise\&. +.SH "EXAMPLES" +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT dblink_send_query(\*(Aqdtest1\*(Aq, \*(AqSELECT * FROM foo WHERE f1 < 3\*(Aq); +.fi +.if n \{\ +.RE +.\} diff --git a/doc/src/sgml/man7/ABORT.7 b/doc/src/sgml/man7/ABORT.7 new file mode 100644 index 000000000..cc2a21b9d --- /dev/null +++ b/doc/src/sgml/man7/ABORT.7 @@ -0,0 +1,82 @@ +'\" t +.\" Title: ABORT +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ABORT" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ABORT \- abort the current transaction +.\" ABORT +.SH "SYNOPSIS" +.sp +.nf +ABORT [ WORK | TRANSACTION ] +.fi +.SH "DESCRIPTION" +.PP + +\fBABORT\fR +rolls back the current transaction and causes all the updates made by the transaction to be discarded\&. This command is identical in behavior to the standard +SQL +command +\fBROLLBACK\fR(7), and is present only for historical reasons\&. +.SH "PARAMETERS" +.PP +WORK, TRANSACTION +.RS 4 +Optional key words\&. They have no effect\&. +.RE +.SH "NOTES" +.PP +Use +\fBCOMMIT\fR(7) +to successfully terminate a transaction\&. +.PP +Issuing +\fBABORT\fR +when not inside a transaction does no harm, but it will provoke a warning message\&. +.SH "EXAMPLES" +.PP +To abort all changes: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ABORT; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +This command is a +PostgreSQL +extension present for historical reasons\&. +\fBROLLBACK\fR +is the equivalent standard SQL command\&. +.SH "SEE ALSO" +\fBBEGIN\fR(7), \fBCOMMIT\fR(7), \fBROLLBACK\fR(7) diff --git a/doc/src/sgml/man7/ALTER_AGGREGATE.7 b/doc/src/sgml/man7/ALTER_AGGREGATE.7 new file mode 100644 index 000000000..03d5dbb74 --- /dev/null +++ b/doc/src/sgml/man7/ALTER_AGGREGATE.7 @@ -0,0 +1,138 @@ +'\" t +.\" Title: ALTER AGGREGATE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER AGGREGATE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_AGGREGATE \- change the definition of an aggregate function +.\" ALTER AGGREGATE +.SH "SYNOPSIS" +.sp +.nf +ALTER AGGREGATE \fIname\fR ( \fIargtype\fR [ , \&.\&.\&. ] ) RENAME TO \fInew_name\fR +ALTER AGGREGATE \fIname\fR ( \fIargtype\fR [ , \&.\&.\&. ] ) OWNER TO \fInew_owner\fR +ALTER AGGREGATE \fIname\fR ( \fIargtype\fR [ , \&.\&.\&. ] ) SET SCHEMA \fInew_schema\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER AGGREGATE\fR +changes the definition of an aggregate function\&. +.PP +You must own the aggregate function to use +\fBALTER AGGREGATE\fR\&. To change the schema of an aggregate function, you must also have +CREATE +privilege on the new schema\&. To alter the owner, you must also be a direct or indirect member of the new owning role, and that role must have +CREATE +privilege on the aggregate function\*(Aqs schema\&. (These restrictions enforce that altering the owner doesn\*(Aqt do anything you couldn\*(Aqt do by dropping and recreating the aggregate function\&. However, a superuser can alter ownership of any aggregate function anyway\&.) +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an existing aggregate function\&. +.RE +.PP +\fIargtype\fR +.RS 4 +An input data type on which the aggregate function operates\&. To reference a zero\-argument aggregate function, write +* +in place of the list of input data types\&. +.RE +.PP +\fInew_name\fR +.RS 4 +The new name of the aggregate function\&. +.RE +.PP +\fInew_owner\fR +.RS 4 +The new owner of the aggregate function\&. +.RE +.PP +\fInew_schema\fR +.RS 4 +The new schema for the aggregate function\&. +.RE +.SH "EXAMPLES" +.PP +To rename the aggregate function +myavg +for type +integer +to +my_average: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER AGGREGATE myavg(integer) RENAME TO my_average; +.fi +.if n \{\ +.RE +.\} +.PP +To change the owner of the aggregate function +myavg +for type +integer +to +joe: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER AGGREGATE myavg(integer) OWNER TO joe; +.fi +.if n \{\ +.RE +.\} +.PP +To move the aggregate function +myavg +for type +integer +into schema +myschema: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER AGGREGATE myavg(integer) SET SCHEMA myschema; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBALTER AGGREGATE\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +CREATE AGGREGATE (\fBCREATE_AGGREGATE\fR(7)), DROP AGGREGATE (\fBDROP_AGGREGATE\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_COLLATION.7 b/doc/src/sgml/man7/ALTER_COLLATION.7 new file mode 100644 index 000000000..85deb0a8a --- /dev/null +++ b/doc/src/sgml/man7/ALTER_COLLATION.7 @@ -0,0 +1,108 @@ +'\" t +.\" Title: ALTER COLLATION +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER COLLATION" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_COLLATION \- change the definition of a collation +.\" ALTER COLLATION +.SH "SYNOPSIS" +.sp +.nf +ALTER COLLATION \fIname\fR RENAME TO \fInew_name\fR +ALTER COLLATION \fIname\fR OWNER TO \fInew_owner\fR +ALTER COLLATION \fIname\fR SET SCHEMA \fInew_schema\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER COLLATION\fR +changes the definition of a collation\&. +.PP +You must own the collation to use +\fBALTER COLLATION\fR\&. To alter the owner, you must also be a direct or indirect member of the new owning role, and that role must have +CREATE +privilege on the collation\*(Aqs schema\&. (These restrictions enforce that altering the owner doesn\*(Aqt do anything you couldn\*(Aqt do by dropping and recreating the collation\&. However, a superuser can alter ownership of any collation anyway\&.) +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an existing collation\&. +.RE +.PP +\fInew_name\fR +.RS 4 +The new name of the collation\&. +.RE +.PP +\fInew_owner\fR +.RS 4 +The new owner of the collation\&. +.RE +.PP +\fInew_schema\fR +.RS 4 +The new schema for the collation\&. +.RE +.SH "EXAMPLES" +.PP +To rename the collation +de_DE +to +german: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER COLLATION "de_DE" RENAME TO german; +.fi +.if n \{\ +.RE +.\} +.PP +To change the owner of the collation +en_US +to +joe: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER COLLATION "en_US" OWNER TO joe; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBALTER COLLATION\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +CREATE COLLATION (\fBCREATE_COLLATION\fR(7)), DROP COLLATION (\fBDROP_COLLATION\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_CONVERSION.7 b/doc/src/sgml/man7/ALTER_CONVERSION.7 new file mode 100644 index 000000000..b6f20e8e3 --- /dev/null +++ b/doc/src/sgml/man7/ALTER_CONVERSION.7 @@ -0,0 +1,108 @@ +'\" t +.\" Title: ALTER CONVERSION +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER CONVERSION" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_CONVERSION \- change the definition of a conversion +.\" ALTER CONVERSION +.SH "SYNOPSIS" +.sp +.nf +ALTER CONVERSION \fIname\fR RENAME TO \fInew_name\fR +ALTER CONVERSION \fIname\fR OWNER TO \fInew_owner\fR +ALTER CONVERSION \fIname\fR SET SCHEMA \fInew_schema\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER CONVERSION\fR +changes the definition of a conversion\&. +.PP +You must own the conversion to use +\fBALTER CONVERSION\fR\&. To alter the owner, you must also be a direct or indirect member of the new owning role, and that role must have +CREATE +privilege on the conversion\*(Aqs schema\&. (These restrictions enforce that altering the owner doesn\*(Aqt do anything you couldn\*(Aqt do by dropping and recreating the conversion\&. However, a superuser can alter ownership of any conversion anyway\&.) +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an existing conversion\&. +.RE +.PP +\fInew_name\fR +.RS 4 +The new name of the conversion\&. +.RE +.PP +\fInew_owner\fR +.RS 4 +The new owner of the conversion\&. +.RE +.PP +\fInew_schema\fR +.RS 4 +The new schema for the conversion\&. +.RE +.SH "EXAMPLES" +.PP +To rename the conversion +iso_8859_1_to_utf8 +to +latin1_to_unicode: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER CONVERSION iso_8859_1_to_utf8 RENAME TO latin1_to_unicode; +.fi +.if n \{\ +.RE +.\} +.PP +To change the owner of the conversion +iso_8859_1_to_utf8 +to +joe: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER CONVERSION iso_8859_1_to_utf8 OWNER TO joe; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBALTER CONVERSION\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +CREATE CONVERSION (\fBCREATE_CONVERSION\fR(7)), DROP CONVERSION (\fBDROP_CONVERSION\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_DATABASE.7 b/doc/src/sgml/man7/ALTER_DATABASE.7 new file mode 100644 index 000000000..039ca2586 --- /dev/null +++ b/doc/src/sgml/man7/ALTER_DATABASE.7 @@ -0,0 +1,151 @@ +'\" t +.\" Title: ALTER DATABASE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER DATABASE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_DATABASE \- change a database +.\" ALTER DATABASE +.SH "SYNOPSIS" +.sp +.nf +ALTER DATABASE \fIname\fR [ [ WITH ] \fIoption\fR [ \&.\&.\&. ] ] + +where \fIoption\fR can be: + + CONNECTION LIMIT \fIconnlimit\fR + +ALTER DATABASE \fIname\fR RENAME TO \fInew_name\fR + +ALTER DATABASE \fIname\fR OWNER TO \fInew_owner\fR + +ALTER DATABASE \fIname\fR SET TABLESPACE \fInew_tablespace\fR + +ALTER DATABASE \fIname\fR SET \fIconfiguration_parameter\fR { TO | = } { \fIvalue\fR | DEFAULT } +ALTER DATABASE \fIname\fR SET \fIconfiguration_parameter\fR FROM CURRENT +ALTER DATABASE \fIname\fR RESET \fIconfiguration_parameter\fR +ALTER DATABASE \fIname\fR RESET ALL +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER DATABASE\fR +changes the attributes of a database\&. +.PP +The first form changes certain per\-database settings\&. (See below for details\&.) Only the database owner or a superuser can change these settings\&. +.PP +The second form changes the name of the database\&. Only the database owner or a superuser can rename a database; non\-superuser owners must also have the +CREATEDB +privilege\&. The current database cannot be renamed\&. (Connect to a different database if you need to do that\&.) +.PP +The third form changes the owner of the database\&. To alter the owner, you must own the database and also be a direct or indirect member of the new owning role, and you must have the +CREATEDB +privilege\&. (Note that superusers have all these privileges automatically\&.) +.PP +The fourth form changes the default tablespace of the database\&. Only the database owner or a superuser can do this; you must also have create privilege for the new tablespace\&. This command physically moves any tables or indexes in the database\*(Aqs old default tablespace to the new tablespace\&. Note that tables and indexes in non\-default tablespaces are not affected\&. +.PP +The remaining forms change the session default for a run\-time configuration variable for a +PostgreSQL +database\&. Whenever a new session is subsequently started in that database, the specified value becomes the session default value\&. The database\-specific default overrides whatever setting is present in +postgresql\&.conf +or has been received from the +\fBpostgres\fR +command line\&. Only the database owner or a superuser can change the session defaults for a database\&. Certain variables cannot be set this way, or can only be set by a superuser\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name of the database whose attributes are to be altered\&. +.RE +.PP +\fIconnlimit\fR +.RS 4 +How many concurrent connections can be made to this database\&. \-1 means no limit\&. +.RE +.PP +\fInew_name\fR +.RS 4 +The new name of the database\&. +.RE +.PP +\fInew_owner\fR +.RS 4 +The new owner of the database\&. +.RE +.PP +\fInew_tablespace\fR +.RS 4 +The new default tablespace of the database\&. +.RE +.PP +\fIconfiguration_parameter\fR, \fIvalue\fR +.RS 4 +Set this database\*(Aqs session default for the specified configuration parameter to the given value\&. If +\fIvalue\fR +is +DEFAULT +or, equivalently, +RESET +is used, the database\-specific setting is removed, so the system\-wide default setting will be inherited in new sessions\&. Use +RESET ALL +to clear all database\-specific settings\&. +SET FROM CURRENT +saves the session\*(Aqs current value of the parameter as the database\-specific value\&. +.sp +See +\fBSET\fR(7) +and +Chapter 18, Server Configuration, in the documentation +for more information about allowed parameter names and values\&. +.RE +.SH "NOTES" +.PP +It is also possible to tie a session default to a specific role rather than to a database; see +ALTER ROLE (\fBALTER_ROLE\fR(7))\&. Role\-specific settings override database\-specific ones if there is a conflict\&. +.SH "EXAMPLES" +.PP +To disable index scans by default in the database +test: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER DATABASE test SET enable_indexscan TO off; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +The +\fBALTER DATABASE\fR +statement is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +CREATE DATABASE (\fBCREATE_DATABASE\fR(7)), DROP DATABASE (\fBDROP_DATABASE\fR(7)), \fBSET\fR(7), CREATE TABLESPACE (\fBCREATE_TABLESPACE\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_DEFAULT_PRIVILEGES.7 b/doc/src/sgml/man7/ALTER_DEFAULT_PRIVILEGES.7 new file mode 100644 index 000000000..49652a404 --- /dev/null +++ b/doc/src/sgml/man7/ALTER_DEFAULT_PRIVILEGES.7 @@ -0,0 +1,190 @@ +'\" t +.\" Title: ALTER DEFAULT PRIVILEGES +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER DEFAULT PRIVILEGES" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_DEFAULT_PRIVILEGES \- define default access privileges +.\" ALTER DEFAULT PRIVILEGES +.SH "SYNOPSIS" +.sp +.nf +ALTER DEFAULT PRIVILEGES + [ FOR { ROLE | USER } \fItarget_role\fR [, \&.\&.\&.] ] + [ IN SCHEMA \fIschema_name\fR [, \&.\&.\&.] ] + \fIabbreviated_grant_or_revoke\fR + +where \fIabbreviated_grant_or_revoke\fR is one of: + +GRANT { { SELECT | INSERT | UPDATE | DELETE | TRUNCATE | REFERENCES | TRIGGER } + [, \&.\&.\&.] | ALL [ PRIVILEGES ] } + ON TABLES + TO { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] [ WITH GRANT OPTION ] + +GRANT { { USAGE | SELECT | UPDATE } + [, \&.\&.\&.] | ALL [ PRIVILEGES ] } + ON SEQUENCES + TO { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] [ WITH GRANT OPTION ] + +GRANT { EXECUTE | ALL [ PRIVILEGES ] } + ON FUNCTIONS + TO { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] [ WITH GRANT OPTION ] + +GRANT { USAGE | ALL [ PRIVILEGES ] } + ON TYPES + TO { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] [ WITH GRANT OPTION ] + +REVOKE [ GRANT OPTION FOR ] + { { SELECT | INSERT | UPDATE | DELETE | TRUNCATE | REFERENCES | TRIGGER } + [, \&.\&.\&.] | ALL [ PRIVILEGES ] } + ON TABLES + FROM { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] + [ CASCADE | RESTRICT ] + +REVOKE [ GRANT OPTION FOR ] + { { USAGE | SELECT | UPDATE } + [, \&.\&.\&.] | ALL [ PRIVILEGES ] } + ON SEQUENCES + FROM { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] + [ CASCADE | RESTRICT ] + +REVOKE [ GRANT OPTION FOR ] + { EXECUTE | ALL [ PRIVILEGES ] } + ON FUNCTIONS + FROM { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] + [ CASCADE | RESTRICT ] + +REVOKE [ GRANT OPTION FOR ] + { USAGE | ALL [ PRIVILEGES ] } + ON TYPES + FROM { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] + [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER DEFAULT PRIVILEGES\fR +allows you to set the privileges that will be applied to objects created in the future\&. (It does not affect privileges assigned to already\-existing objects\&.) Currently, only the privileges for tables (including views and foreign tables), sequences, functions, and types (including domains) can be altered\&. +.PP +You can change default privileges only for objects that will be created by yourself or by roles that you are a member of\&. The privileges can be set globally (i\&.e\&., for all objects created in the current database), or just for objects created in specified schemas\&. Default privileges that are specified per\-schema are added to whatever the global default privileges are for the particular object type\&. +.PP +As explained under +\fBGRANT\fR(7), the default privileges for any object type normally grant all grantable permissions to the object owner, and may grant some privileges to +PUBLIC +as well\&. However, this behavior can be changed by altering the global default privileges with +\fBALTER DEFAULT PRIVILEGES\fR\&. +.SS "Parameters" +.PP +\fItarget_role\fR +.RS 4 +The name of an existing role of which the current role is a member\&. If +FOR ROLE +is omitted, the current role is assumed\&. +.RE +.PP +\fIschema_name\fR +.RS 4 +The name of an existing schema\&. Each +\fItarget_role\fR +must have +CREATE +privileges for each specified schema\&. If +IN SCHEMA +is omitted, the global default privileges are altered\&. +.RE +.PP +\fIrole_name\fR +.RS 4 +The name of an existing role to grant or revoke privileges for\&. This parameter, and all the other parameters in +\fIabbreviated_grant_or_revoke\fR, act as described under +\fBGRANT\fR(7) +or +\fBREVOKE\fR(7), except that one is setting permissions for a whole class of objects rather than specific named objects\&. +.RE +.SH "NOTES" +.PP +Use +\fBpsql\fR(1)\*(Aqs +\fB\eddp\fR +command to obtain information about existing assignments of default privileges\&. The meaning of the privilege values is the same as explained for +\fB\edp\fR +under +\fBGRANT\fR(7)\&. +.PP +If you wish to drop a role for which the default privileges have been altered, it is necessary to reverse the changes in its default privileges or use +\fBDROP OWNED BY\fR +to get rid of the default privileges entry for the role\&. +.SH "EXAMPLES" +.PP +Grant SELECT privilege to everyone for all tables (and views) you subsequently create in schema +myschema, and allow role +webuser +to INSERT into them too: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER DEFAULT PRIVILEGES IN SCHEMA myschema GRANT SELECT ON TABLES TO PUBLIC; +ALTER DEFAULT PRIVILEGES IN SCHEMA myschema GRANT INSERT ON TABLES TO webuser; +.fi +.if n \{\ +.RE +.\} +.PP +Undo the above, so that subsequently\-created tables won\*(Aqt have any more permissions than normal: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER DEFAULT PRIVILEGES IN SCHEMA myschema REVOKE SELECT ON TABLES FROM PUBLIC; +ALTER DEFAULT PRIVILEGES IN SCHEMA myschema REVOKE INSERT ON TABLES FROM webuser; +.fi +.if n \{\ +.RE +.\} +.PP +Remove the public EXECUTE permission that is normally granted on functions, for all functions subsequently created by role +admin: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER DEFAULT PRIVILEGES FOR ROLE admin REVOKE EXECUTE ON FUNCTIONS FROM PUBLIC; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBALTER DEFAULT PRIVILEGES\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +\fBGRANT\fR(7), \fBREVOKE\fR(7) diff --git a/doc/src/sgml/man7/ALTER_DOMAIN.7 b/doc/src/sgml/man7/ALTER_DOMAIN.7 new file mode 100644 index 000000000..c5a18ddb2 --- /dev/null +++ b/doc/src/sgml/man7/ALTER_DOMAIN.7 @@ -0,0 +1,285 @@ +'\" t +.\" Title: ALTER DOMAIN +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER DOMAIN" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_DOMAIN \- change the definition of a domain +.\" ALTER DOMAIN +.SH "SYNOPSIS" +.sp +.nf +ALTER DOMAIN \fIname\fR + { SET DEFAULT \fIexpression\fR | DROP DEFAULT } +ALTER DOMAIN \fIname\fR + { SET | DROP } NOT NULL +ALTER DOMAIN \fIname\fR + ADD \fIdomain_constraint\fR [ NOT VALID ] +ALTER DOMAIN \fIname\fR + DROP CONSTRAINT [ IF EXISTS ] \fIconstraint_name\fR [ RESTRICT | CASCADE ] +ALTER DOMAIN \fIname\fR + RENAME CONSTRAINT \fIconstraint_name\fR TO \fInew_constraint_name\fR +ALTER DOMAIN \fIname\fR + VALIDATE CONSTRAINT \fIconstraint_name\fR +ALTER DOMAIN \fIname\fR + OWNER TO \fInew_owner\fR +ALTER DOMAIN \fIname\fR + RENAME TO \fInew_name\fR +ALTER DOMAIN \fIname\fR + SET SCHEMA \fInew_schema\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER DOMAIN\fR +changes the definition of an existing domain\&. There are several sub\-forms: +.PP +SET/DROP DEFAULT +.RS 4 +These forms set or remove the default value for a domain\&. Note that defaults only apply to subsequent +\fBINSERT\fR +commands; they do not affect rows already in a table using the domain\&. +.RE +.PP +SET/DROP NOT NULL +.RS 4 +These forms change whether a domain is marked to allow NULL values or to reject NULL values\&. You can only +SET NOT NULL +when the columns using the domain contain no null values\&. +.RE +.PP +ADD \fIdomain_constraint\fR [ NOT VALID ] +.RS 4 +This form adds a new constraint to a domain using the same syntax as +CREATE DOMAIN (\fBCREATE_DOMAIN\fR(7))\&. When a new constraint is added to a domain, all columns using that domain will be checked against the newly added constraint\&. These checks can be suppressed by adding the new constraint using the +NOT VALID +option; the constraint can later be made valid using +\fBALTER DOMAIN \&.\&.\&. VALIDATE CONSTRAINT\fR\&. Newly inserted or updated rows are always checked against all constraints, even those marked +NOT VALID\&. +NOT VALID +is only accepted for +CHECK +constraints\&. +.RE +.PP +DROP CONSTRAINT [ IF EXISTS ] +.RS 4 +This form drops constraints on a domain\&. If +IF EXISTS +is specified and the constraint does not exist, no error is thrown\&. In this case a notice is issued instead\&. +.RE +.PP +RENAME CONSTRAINT +.RS 4 +This form changes the name of a constraint on a domain\&. +.RE +.PP +VALIDATE CONSTRAINT +.RS 4 +This form validates a constraint previously added as +NOT VALID, that is, verify that all data in columns using the domain satisfy the specified constraint\&. +.RE +.PP +OWNER +.RS 4 +This form changes the owner of the domain to the specified user\&. +.RE +.PP +RENAME +.RS 4 +This form changes the name of the domain\&. +.RE +.PP +SET SCHEMA +.RS 4 +This form changes the schema of the domain\&. Any constraints associated with the domain are moved into the new schema as well\&. +.RE +.PP +You must own the domain to use +\fBALTER DOMAIN\fR\&. To change the schema of a domain, you must also have +CREATE +privilege on the new schema\&. To alter the owner, you must also be a direct or indirect member of the new owning role, and that role must have +CREATE +privilege on the domain\*(Aqs schema\&. (These restrictions enforce that altering the owner doesn\*(Aqt do anything you couldn\*(Aqt do by dropping and recreating the domain\&. However, a superuser can alter ownership of any domain anyway\&.) +.SH "PARAMETERS" +.PP +.PP +\fIname\fR +.RS 4 +The name (possibly schema\-qualified) of an existing domain to alter\&. +.RE +.PP +\fIdomain_constraint\fR +.RS 4 +New domain constraint for the domain\&. +.RE +.PP +\fIconstraint_name\fR +.RS 4 +Name of an existing constraint to drop or rename\&. +.RE +.PP +\fINOT VALID\fR +.RS 4 +Do not verify existing column data for constraint validity\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the constraint\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the constraint if there are any dependent objects\&. This is the default behavior\&. +.RE +.PP +\fInew_name\fR +.RS 4 +The new name for the domain\&. +.RE +.PP +\fInew_constraint_name\fR +.RS 4 +The new name for the constraint\&. +.RE +.PP +\fInew_owner\fR +.RS 4 +The user name of the new owner of the domain\&. +.RE +.PP +\fInew_schema\fR +.RS 4 +The new schema for the domain\&. +.RE +.SH "NOTES" +.PP +Currently, +\fBALTER DOMAIN ADD CONSTRAINT\fR +and +\fBALTER DOMAIN SET NOT NULL\fR +will fail if the named domain or any derived domain is used within a composite\-type column of any table in the database\&. They should eventually be improved to be able to verify the new constraint for such nested columns\&. +.SH "EXAMPLES" +.PP +To add a +NOT NULL +constraint to a domain: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER DOMAIN zipcode SET NOT NULL; +.fi +.if n \{\ +.RE +.\} +.sp +To remove a +NOT NULL +constraint from a domain: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER DOMAIN zipcode DROP NOT NULL; +.fi +.if n \{\ +.RE +.\} +.PP +To add a check constraint to a domain: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER DOMAIN zipcode ADD CONSTRAINT zipchk CHECK (char_length(VALUE) = 5); +.fi +.if n \{\ +.RE +.\} +.PP +To remove a check constraint from a domain: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER DOMAIN zipcode DROP CONSTRAINT zipchk; +.fi +.if n \{\ +.RE +.\} +.PP +To rename a check constraint on a domain: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER DOMAIN zipcode RENAME CONSTRAINT zipchk TO zip_check; +.fi +.if n \{\ +.RE +.\} +.PP +To move the domain into a different schema: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER DOMAIN zipcode SET SCHEMA customers; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBALTER DOMAIN\fR +conforms to the +SQL +standard, except for the +OWNER, +RENAME, +SET SCHEMA, and +VALIDATE CONSTRAINT +variants, which are +PostgreSQL +extensions\&. The +NOT VALID +clause of the +ADD CONSTRAINT +variant is also a +PostgreSQL +extension\&. +.SH "SEE ALSO" +CREATE DOMAIN (\fBCREATE_DOMAIN\fR(7)), DROP DOMAIN (\fBDROP_DOMAIN\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_EXTENSION.7 b/doc/src/sgml/man7/ALTER_EXTENSION.7 new file mode 100644 index 000000000..090616897 --- /dev/null +++ b/doc/src/sgml/man7/ALTER_EXTENSION.7 @@ -0,0 +1,236 @@ +'\" t +.\" Title: ALTER EXTENSION +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER EXTENSION" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_EXTENSION \- change the definition of an extension +.\" ALTER EXTENSION +.SH "SYNOPSIS" +.sp +.nf +ALTER EXTENSION \fIname\fR UPDATE [ TO \fInew_version\fR ] +ALTER EXTENSION \fIname\fR SET SCHEMA \fInew_schema\fR +ALTER EXTENSION \fIname\fR ADD \fImember_object\fR +ALTER EXTENSION \fIname\fR DROP \fImember_object\fR + +where \fImember_object\fR is: + + AGGREGATE \fIagg_name\fR (\fIagg_type\fR [, \&.\&.\&.] ) | + CAST (\fIsource_type\fR AS \fItarget_type\fR) | + COLLATION \fIobject_name\fR | + CONVERSION \fIobject_name\fR | + DOMAIN \fIobject_name\fR | + FOREIGN DATA WRAPPER \fIobject_name\fR | + FOREIGN TABLE \fIobject_name\fR | + FUNCTION \fIfunction_name\fR ( [ [ \fIargmode\fR ] [ \fIargname\fR ] \fIargtype\fR [, \&.\&.\&.] ] ) | + OPERATOR \fIoperator_name\fR (\fIleft_type\fR, \fIright_type\fR) | + OPERATOR CLASS \fIobject_name\fR USING \fIindex_method\fR | + OPERATOR FAMILY \fIobject_name\fR USING \fIindex_method\fR | + [ PROCEDURAL ] LANGUAGE \fIobject_name\fR | + SCHEMA \fIobject_name\fR | + SEQUENCE \fIobject_name\fR | + SERVER \fIobject_name\fR | + TABLE \fIobject_name\fR | + TEXT SEARCH CONFIGURATION \fIobject_name\fR | + TEXT SEARCH DICTIONARY \fIobject_name\fR | + TEXT SEARCH PARSER \fIobject_name\fR | + TEXT SEARCH TEMPLATE \fIobject_name\fR | + TYPE \fIobject_name\fR | + VIEW \fIobject_name\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER EXTENSION\fR +changes the definition of an installed extension\&. There are several subforms: +.PP +UPDATE +.RS 4 +This form updates the extension to a newer version\&. The extension must supply a suitable update script (or series of scripts) that can modify the currently\-installed version into the requested version\&. +.RE +.PP +SET SCHEMA +.RS 4 +This form moves the extension\*(Aqs objects into another schema\&. The extension has to be +relocatable +for this command to succeed\&. +.RE +.PP +ADD \fImember_object\fR +.RS 4 +This form adds an existing object to the extension\&. This is mainly useful in extension update scripts\&. The object will subsequently be treated as a member of the extension; notably, it can only be dropped by dropping the extension\&. +.RE +.PP +DROP \fImember_object\fR +.RS 4 +This form removes a member object from the extension\&. This is mainly useful in extension update scripts\&. The object is not dropped, only disassociated from the extension\&. +.RE +See +Section 35.15, \(lqPackaging Related Objects into an Extension\(rq, in the documentation +for more information about these operations\&. +.PP +You must own the extension to use +\fBALTER EXTENSION\fR\&. The +ADD/DROP +forms require ownership of the added/dropped object as well\&. +.SH "PARAMETERS" +.PP +.PP +\fIname\fR +.RS 4 +The name of an installed extension\&. +.RE +.PP +\fInew_version\fR +.RS 4 +The desired new version of the extension\&. This can be written as either an identifier or a string literal\&. If not specified, +\fBALTER EXTENSION UPDATE\fR +attempts to update to whatever is shown as the default version in the extension\*(Aqs control file\&. +.RE +.PP +\fInew_schema\fR +.RS 4 +The new schema for the extension\&. +.RE +.PP +\fIobject_name\fR, \fIagg_name\fR, \fIfunction_name\fR, \fIoperator_name\fR +.RS 4 +The name of an object to be added to or removed from the extension\&. Names of tables, aggregates, domains, foreign tables, functions, operators, operator classes, operator families, sequences, text search objects, types, and views can be schema\-qualified\&. +.RE +.PP +\fIagg_type\fR +.RS 4 +An input data type on which the aggregate function operates\&. To reference a zero\-argument aggregate function, write +* +in place of the list of input data types\&. +.RE +.PP +\fIsource_type\fR +.RS 4 +The name of the source data type of the cast\&. +.RE +.PP +\fItarget_type\fR +.RS 4 +The name of the target data type of the cast\&. +.RE +.PP +\fIargmode\fR +.RS 4 +The mode of a function argument: +IN, +OUT, +INOUT, or +VARIADIC\&. If omitted, the default is +IN\&. Note that +\fBALTER EXTENSION\fR +does not actually pay any attention to +OUT +arguments, since only the input arguments are needed to determine the function\*(Aqs identity\&. So it is sufficient to list the +IN, +INOUT, and +VARIADIC +arguments\&. +.RE +.PP +\fIargname\fR +.RS 4 +The name of a function argument\&. Note that +\fBALTER EXTENSION\fR +does not actually pay any attention to argument names, since only the argument data types are needed to determine the function\*(Aqs identity\&. +.RE +.PP +\fIargtype\fR +.RS 4 +The data type(s) of the function\*(Aqs arguments (optionally schema\-qualified), if any\&. +.RE +.PP +\fIleft_type\fR, \fIright_type\fR +.RS 4 +The data type(s) of the operator\*(Aqs arguments (optionally schema\-qualified)\&. Write +NONE +for the missing argument of a prefix or postfix operator\&. +.RE +.PP +PROCEDURAL +.RS 4 +This is a noise word\&. +.RE +.SH "EXAMPLES" +.PP +To update the +hstore +extension to version 2\&.0: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER EXTENSION hstore UPDATE TO \*(Aq2\&.0\*(Aq; +.fi +.if n \{\ +.RE +.\} +.PP +To change the schema of the +hstore +extension to +utils: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER EXTENSION hstore SET SCHEMA utils; +.fi +.if n \{\ +.RE +.\} +.PP +To add an existing function to the +hstore +extension: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER EXTENSION hstore ADD FUNCTION populate_record(anyelement, hstore); +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBALTER EXTENSION\fR +is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +CREATE EXTENSION (\fBCREATE_EXTENSION\fR(7)), DROP EXTENSION (\fBDROP_EXTENSION\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_FOREIGN_DATA_WRAPPER.7 b/doc/src/sgml/man7/ALTER_FOREIGN_DATA_WRAPPER.7 new file mode 100644 index 000000000..d2bd128e7 --- /dev/null +++ b/doc/src/sgml/man7/ALTER_FOREIGN_DATA_WRAPPER.7 @@ -0,0 +1,143 @@ +'\" t +.\" Title: ALTER FOREIGN DATA WRAPPER +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER FOREIGN DATA WRAPPER" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_FOREIGN_DATA_WRAPPER \- change the definition of a foreign\-data wrapper +.\" ALTER FOREIGN DATA WRAPPER +.SH "SYNOPSIS" +.sp +.nf +ALTER FOREIGN DATA WRAPPER \fIname\fR + [ HANDLER \fIhandler_function\fR | NO HANDLER ] + [ VALIDATOR \fIvalidator_function\fR | NO VALIDATOR ] + [ OPTIONS ( [ ADD | SET | DROP ] \fIoption\fR [\*(Aq\fIvalue\fR\*(Aq] [, \&.\&.\&. ]) ] +ALTER FOREIGN DATA WRAPPER \fIname\fR OWNER TO \fInew_owner\fR +ALTER FOREIGN DATA WRAPPER \fIname\fR RENAME TO \fInew_name\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER FOREIGN DATA WRAPPER\fR +changes the definition of a foreign\-data wrapper\&. The first form of the command changes the support functions or the generic options of the foreign\-data wrapper (at least one clause is required)\&. The second form changes the owner of the foreign\-data wrapper\&. +.PP +Only superusers can alter foreign\-data wrappers\&. Additionally, only superusers can own foreign\-data wrappers\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name of an existing foreign\-data wrapper\&. +.RE +.PP +HANDLER \fIhandler_function\fR +.RS 4 +Specifies a new handler function for the foreign\-data wrapper\&. +.RE +.PP +NO HANDLER +.RS 4 +This is used to specify that the foreign\-data wrapper should no longer have a handler function\&. +.sp +Note that foreign tables that use a foreign\-data wrapper with no handler cannot be accessed\&. +.RE +.PP +VALIDATOR \fIvalidator_function\fR +.RS 4 +Specifies a new validator function for the foreign\-data wrapper\&. +.sp +Note that it is possible that after changing the validator the options to the foreign\-data wrapper, servers, and user mappings have become invalid\&. It is up to the user to make sure that these options are correct before using the foreign\-data wrapper\&. +.RE +.PP +NO VALIDATOR +.RS 4 +This is used to specify that the foreign\-data wrapper should no longer have a validator function\&. +.RE +.PP +OPTIONS ( [ ADD | SET | DROP ] \fIoption\fR [\*(Aq\fIvalue\fR\*(Aq] [, \&.\&.\&. ] ) +.RS 4 +Change options for the foreign\-data wrapper\&. +ADD, +SET, and +DROP +specify the action to be performed\&. +ADD +is assumed if no operation is explicitly specified\&. Option names must be unique; names and values are also validated using the foreign data wrapper\*(Aqs validator function, if any\&. +.RE +.PP +\fInew_owner\fR +.RS 4 +The user name of the new owner of the foreign\-data wrapper\&. +.RE +.PP +\fInew_name\fR +.RS 4 +The new name for the foreign\-data wrapper\&. +.RE +.SH "EXAMPLES" +.PP +Change a foreign\-data wrapper +dbi, add option +foo, drop +bar: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER FOREIGN DATA WRAPPER dbi OPTIONS (ADD foo \*(Aq1\*(Aq, DROP \*(Aqbar\*(Aq); +.fi +.if n \{\ +.RE +.\} +.PP +Change the foreign\-data wrapper +dbi +validator to +bob\&.myvalidator: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER FOREIGN DATA WRAPPER dbi VALIDATOR bob\&.myvalidator; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBALTER FOREIGN DATA WRAPPER\fR +conforms to ISO/IEC 9075\-9 (SQL/MED), except that the +HANDLER, +VALIDATOR, +OWNER TO, and +RENAME +clauses are extensions\&. +.SH "SEE ALSO" +CREATE FOREIGN DATA WRAPPER (\fBCREATE_FOREIGN_DATA_WRAPPER\fR(7)), DROP FOREIGN DATA WRAPPER (\fBDROP_FOREIGN_DATA_WRAPPER\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_FOREIGN_TABLE.7 b/doc/src/sgml/man7/ALTER_FOREIGN_TABLE.7 new file mode 100644 index 000000000..cecbf0f99 --- /dev/null +++ b/doc/src/sgml/man7/ALTER_FOREIGN_TABLE.7 @@ -0,0 +1,254 @@ +'\" t +.\" Title: ALTER FOREIGN TABLE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER FOREIGN TABLE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_FOREIGN_TABLE \- change the definition of a foreign table +.\" ALTER FOREIGN TABLE +.SH "SYNOPSIS" +.sp +.nf +ALTER FOREIGN TABLE [ IF EXISTS ] \fIname\fR + \fIaction\fR [, \&.\&.\&. ] +ALTER FOREIGN TABLE [ IF EXISTS ] \fIname\fR + RENAME [ COLUMN ] \fIcolumn_name\fR TO \fInew_column_name\fR +ALTER FOREIGN TABLE [ IF EXISTS ] \fIname\fR + RENAME TO \fInew_name\fR +ALTER FOREIGN TABLE [ IF EXISTS ] \fIname\fR + SET SCHEMA \fInew_schema\fR + +where \fIaction\fR is one of: + + ADD [ COLUMN ] \fIcolumn_name\fR \fIdata_type\fR [ NULL | NOT NULL ] + DROP [ COLUMN ] [ IF EXISTS ] \fIcolumn_name\fR [ RESTRICT | CASCADE ] + ALTER [ COLUMN ] \fIcolumn_name\fR [ SET DATA ] TYPE \fIdata_type\fR + ALTER [ COLUMN ] \fIcolumn_name\fR { SET | DROP } NOT NULL + ALTER [ COLUMN ] \fIcolumn_name\fR SET STATISTICS \fIinteger\fR + ALTER [ COLUMN ] \fIcolumn_name\fR SET ( \fIattribute_option\fR = \fIvalue\fR [, \&.\&.\&. ] ) + ALTER [ COLUMN ] \fIcolumn_name\fR RESET ( \fIattribute_option\fR [, \&.\&.\&. ] ) + ALTER [ COLUMN ] \fIcolumn_name\fR OPTIONS ( [ ADD | SET | DROP ] \fIoption\fR [\*(Aq\fIvalue\fR\*(Aq] [, \&.\&.\&. ]) + OWNER TO \fInew_owner\fR + OPTIONS ( [ ADD | SET | DROP ] \fIoption\fR [\*(Aq\fIvalue\fR\*(Aq] [, \&.\&.\&. ]) +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER FOREIGN TABLE\fR +changes the definition of an existing foreign table\&. There are several subforms: +.PP +ADD COLUMN +.RS 4 +This form adds a new column to the foreign table, using the same syntax as +CREATE FOREIGN TABLE (\fBCREATE_FOREIGN_TABLE\fR(7))\&. +.RE +.PP +DROP COLUMN [ IF EXISTS ] +.RS 4 +This form drops a column from a foreign table\&. You will need to say +CASCADE +if anything outside the table depends on the column; for example, views\&. If +IF EXISTS +is specified and the column does not exist, no error is thrown\&. In this case a notice is issued instead\&. +.RE +.PP +IF EXISTS +.RS 4 +Do not throw an error if the foreign table does not exist\&. A notice is issued in this case\&. +.RE +.PP +SET DATA TYPE +.RS 4 +This form changes the type of a column of a foreign table\&. +.RE +.PP +SET/DROP NOT NULL +.RS 4 +Mark a column as allowing, or not allowing, null values\&. +.RE +.PP +SET STATISTICS +.RS 4 +This form sets the per\-column statistics\-gathering target for subsequent +\fBANALYZE\fR(7) +operations\&. See the similar form of +ALTER TABLE (\fBALTER_TABLE\fR(7)) +for more details\&. +.RE +.PP +SET ( \fIattribute_option\fR = \fIvalue\fR [, \&.\&.\&. ] ), RESET ( \fIattribute_option\fR [, \&.\&.\&. ] ) +.RS 4 +This form sets or resets per\-attribute options\&. See the similar form of +ALTER TABLE (\fBALTER_TABLE\fR(7)) +for more details\&. +.RE +.PP +OWNER +.RS 4 +This form changes the owner of the foreign table to the specified user\&. +.RE +.PP +RENAME +.RS 4 +The +RENAME +forms change the name of a foreign table or the name of an individual column in a foreign table\&. +.RE +.PP +SET SCHEMA +.RS 4 +This form moves the foreign table into another schema\&. +.RE +.PP +OPTIONS ( [ ADD | SET | DROP ] \fIoption\fR [\*(Aq\fIvalue\fR\*(Aq] [, \&.\&.\&. ] ) +.RS 4 +Change options for the foreign table or one of its columns\&. +ADD, +SET, and +DROP +specify the action to be performed\&. +ADD +is assumed if no operation is explicitly specified\&. Duplicate option names are not allowed (although it\*(Aqs OK for a table option and a column option to have the same name)\&. Option names and values are also validated using the foreign data wrapper library\&. +.RE +.PP +All the actions except +RENAME +and +SET SCHEMA +can be combined into a list of multiple alterations to apply in parallel\&. For example, it is possible to add several columns and/or alter the type of several columns in a single command\&. +.PP +You must own the table to use +\fBALTER FOREIGN TABLE\fR\&. To change the schema of a foreign table, you must also have +CREATE +privilege on the new schema\&. To alter the owner, you must also be a direct or indirect member of the new owning role, and that role must have +CREATE +privilege on the table\*(Aqs schema\&. (These restrictions enforce that altering the owner doesn\*(Aqt do anything you couldn\*(Aqt do by dropping and recreating the table\&. However, a superuser can alter ownership of any table anyway\&.) To add a column or alter a column type, you must also have +USAGE +privilege on the data type\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name (possibly schema\-qualified) of an existing foreign table to alter\&. +.RE +.PP +\fIcolumn_name\fR +.RS 4 +Name of a new or existing column\&. +.RE +.PP +\fInew_column_name\fR +.RS 4 +New name for an existing column\&. +.RE +.PP +\fInew_name\fR +.RS 4 +New name for the table\&. +.RE +.PP +\fIdata_type\fR +.RS 4 +Data type of the new column, or new data type for an existing column\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the dropped column (for example, views referencing the column)\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the column if there are any dependent objects\&. This is the default behavior\&. +.RE +.PP +\fInew_owner\fR +.RS 4 +The user name of the new owner of the table\&. +.RE +.PP +\fInew_schema\fR +.RS 4 +The name of the schema to which the table will be moved\&. +.RE +.SH "NOTES" +.PP +The key word +COLUMN +is noise and can be omitted\&. +.PP +Consistency with the foreign server is not checked when a column is added or removed with +ADD COLUMN +or +DROP COLUMN, a +NOT NULL +constraint is added, or a column type is changed with +SET DATA TYPE\&. It is the user\*(Aqs responsibility to ensure that the table definition matches the remote side\&. +.PP +Refer to +CREATE FOREIGN TABLE (\fBCREATE_FOREIGN_TABLE\fR(7)) +for a further description of valid parameters\&. +.SH "EXAMPLES" +.PP +To mark a column as not\-null: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER FOREIGN TABLE distributors ALTER COLUMN street SET NOT NULL; +.fi +.if n \{\ +.RE +.\} +.PP +To change options of a foreign table: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER FOREIGN TABLE myschema\&.distributors OPTIONS (ADD opt1 \*(Aqvalue\*(Aq, SET opt2, \*(Aqvalue2\*(Aq, DROP opt3 \*(Aqvalue3\*(Aq); +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +The forms +ADD, +DROP, and +SET DATA TYPE +conform with the SQL standard\&. The other forms are +PostgreSQL +extensions of the SQL standard\&. Also, the ability to specify more than one manipulation in a single +\fBALTER FOREIGN TABLE\fR +command is an extension\&. +.PP + +\fBALTER FOREIGN TABLE DROP COLUMN\fR +can be used to drop the only column of a foreign table, leaving a zero\-column table\&. This is an extension of SQL, which disallows zero\-column foreign tables\&. diff --git a/doc/src/sgml/man7/ALTER_FUNCTION.7 b/doc/src/sgml/man7/ALTER_FUNCTION.7 new file mode 100644 index 000000000..e1639737d --- /dev/null +++ b/doc/src/sgml/man7/ALTER_FUNCTION.7 @@ -0,0 +1,285 @@ +'\" t +.\" Title: ALTER FUNCTION +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER FUNCTION" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_FUNCTION \- change the definition of a function +.\" ALTER FUNCTION +.SH "SYNOPSIS" +.sp +.nf +ALTER FUNCTION \fIname\fR ( [ [ \fIargmode\fR ] [ \fIargname\fR ] \fIargtype\fR [, \&.\&.\&.] ] ) + \fIaction\fR [ \&.\&.\&. ] [ RESTRICT ] +ALTER FUNCTION \fIname\fR ( [ [ \fIargmode\fR ] [ \fIargname\fR ] \fIargtype\fR [, \&.\&.\&.] ] ) + RENAME TO \fInew_name\fR +ALTER FUNCTION \fIname\fR ( [ [ \fIargmode\fR ] [ \fIargname\fR ] \fIargtype\fR [, \&.\&.\&.] ] ) + OWNER TO \fInew_owner\fR +ALTER FUNCTION \fIname\fR ( [ [ \fIargmode\fR ] [ \fIargname\fR ] \fIargtype\fR [, \&.\&.\&.] ] ) + SET SCHEMA \fInew_schema\fR + +where \fIaction\fR is one of: + + CALLED ON NULL INPUT | RETURNS NULL ON NULL INPUT | STRICT + IMMUTABLE | STABLE | VOLATILE | [ NOT ] LEAKPROOF + [ EXTERNAL ] SECURITY INVOKER | [ EXTERNAL ] SECURITY DEFINER + COST \fIexecution_cost\fR + ROWS \fIresult_rows\fR + SET \fIconfiguration_parameter\fR { TO | = } { \fIvalue\fR | DEFAULT } + SET \fIconfiguration_parameter\fR FROM CURRENT + RESET \fIconfiguration_parameter\fR + RESET ALL +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER FUNCTION\fR +changes the definition of a function\&. +.PP +You must own the function to use +\fBALTER FUNCTION\fR\&. To change a function\*(Aqs schema, you must also have +CREATE +privilege on the new schema\&. To alter the owner, you must also be a direct or indirect member of the new owning role, and that role must have +CREATE +privilege on the function\*(Aqs schema\&. (These restrictions enforce that altering the owner doesn\*(Aqt do anything you couldn\*(Aqt do by dropping and recreating the function\&. However, a superuser can alter ownership of any function anyway\&.) +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an existing function\&. +.RE +.PP +\fIargmode\fR +.RS 4 +The mode of an argument: +IN, +OUT, +INOUT, or +VARIADIC\&. If omitted, the default is +IN\&. Note that +\fBALTER FUNCTION\fR +does not actually pay any attention to +OUT +arguments, since only the input arguments are needed to determine the function\*(Aqs identity\&. So it is sufficient to list the +IN, +INOUT, and +VARIADIC +arguments\&. +.RE +.PP +\fIargname\fR +.RS 4 +The name of an argument\&. Note that +\fBALTER FUNCTION\fR +does not actually pay any attention to argument names, since only the argument data types are needed to determine the function\*(Aqs identity\&. +.RE +.PP +\fIargtype\fR +.RS 4 +The data type(s) of the function\*(Aqs arguments (optionally schema\-qualified), if any\&. +.RE +.PP +\fInew_name\fR +.RS 4 +The new name of the function\&. +.RE +.PP +\fInew_owner\fR +.RS 4 +The new owner of the function\&. Note that if the function is marked +SECURITY DEFINER, it will subsequently execute as the new owner\&. +.RE +.PP +\fInew_schema\fR +.RS 4 +The new schema for the function\&. +.RE +.PP +CALLED ON NULL INPUT, RETURNS NULL ON NULL INPUT, STRICT +.RS 4 +CALLED ON NULL INPUT +changes the function so that it will be invoked when some or all of its arguments are null\&. +RETURNS NULL ON NULL INPUT +or +STRICT +changes the function so that it is not invoked if any of its arguments are null; instead, a null result is assumed automatically\&. See +CREATE FUNCTION (\fBCREATE_FUNCTION\fR(7)) +for more information\&. +.RE +.PP +IMMUTABLE, STABLE, VOLATILE +.RS 4 +Change the volatility of the function to the specified setting\&. See +CREATE FUNCTION (\fBCREATE_FUNCTION\fR(7)) +for details\&. +.RE +.PP +[ EXTERNAL ] SECURITY INVOKER, [ EXTERNAL ] SECURITY DEFINER +.RS 4 +Change whether the function is a security definer or not\&. The key word +EXTERNAL +is ignored for SQL conformance\&. See +CREATE FUNCTION (\fBCREATE_FUNCTION\fR(7)) +for more information about this capability\&. +.RE +.PP +LEAKPROOF +.RS 4 +Change whether the function is considered leakproof or not\&. See +CREATE FUNCTION (\fBCREATE_FUNCTION\fR(7)) +for more information about this capability\&. +.RE +.PP +COST \fIexecution_cost\fR +.RS 4 +Change the estimated execution cost of the function\&. See +CREATE FUNCTION (\fBCREATE_FUNCTION\fR(7)) +for more information\&. +.RE +.PP +ROWS \fIresult_rows\fR +.RS 4 +Change the estimated number of rows returned by a set\-returning function\&. See +CREATE FUNCTION (\fBCREATE_FUNCTION\fR(7)) +for more information\&. +.RE +.PP +\fIconfiguration_parameter\fR, \fIvalue\fR +.RS 4 +Add or change the assignment to be made to a configuration parameter when the function is called\&. If +\fIvalue\fR +is +DEFAULT +or, equivalently, +RESET +is used, the function\-local setting is removed, so that the function executes with the value present in its environment\&. Use +RESET ALL +to clear all function\-local settings\&. +SET FROM CURRENT +saves the session\*(Aqs current value of the parameter as the value to be applied when the function is entered\&. +.sp +See +\fBSET\fR(7) +and +Chapter 18, Server Configuration, in the documentation +for more information about allowed parameter names and values\&. +.RE +.PP +RESTRICT +.RS 4 +Ignored for conformance with the SQL standard\&. +.RE +.SH "EXAMPLES" +.PP +To rename the function +sqrt +for type +integer +to +square_root: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER FUNCTION sqrt(integer) RENAME TO square_root; +.fi +.if n \{\ +.RE +.\} +.PP +To change the owner of the function +sqrt +for type +integer +to +joe: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER FUNCTION sqrt(integer) OWNER TO joe; +.fi +.if n \{\ +.RE +.\} +.PP +To change the schema of the function +sqrt +for type +integer +to +maths: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER FUNCTION sqrt(integer) SET SCHEMA maths; +.fi +.if n \{\ +.RE +.\} +.PP +To adjust the search path that is automatically set for a function: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER FUNCTION check_password(text) SET search_path = admin, pg_temp; +.fi +.if n \{\ +.RE +.\} +.PP +To disable automatic setting of +\fIsearch_path\fR +for a function: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER FUNCTION check_password(text) RESET search_path; +.fi +.if n \{\ +.RE +.\} +.sp +The function will now execute with whatever search path is used by its caller\&. +.SH "COMPATIBILITY" +.PP +This statement is partially compatible with the +\fBALTER FUNCTION\fR +statement in the SQL standard\&. The standard allows more properties of a function to be modified, but does not provide the ability to rename a function, make a function a security definer, attach configuration parameter values to a function, or change the owner, schema, or volatility of a function\&. The standard also requires the +RESTRICT +key word, which is optional in +PostgreSQL\&. +.SH "SEE ALSO" +CREATE FUNCTION (\fBCREATE_FUNCTION\fR(7)), DROP FUNCTION (\fBDROP_FUNCTION\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_GROUP.7 b/doc/src/sgml/man7/ALTER_GROUP.7 new file mode 100644 index 000000000..fc16ebc3d --- /dev/null +++ b/doc/src/sgml/man7/ALTER_GROUP.7 @@ -0,0 +1,108 @@ +'\" t +.\" Title: ALTER GROUP +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER GROUP" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_GROUP \- change role name or membership +.\" ALTER GROUP +.SH "SYNOPSIS" +.sp +.nf +ALTER GROUP \fIgroup_name\fR ADD USER \fIuser_name\fR [, \&.\&.\&. ] +ALTER GROUP \fIgroup_name\fR DROP USER \fIuser_name\fR [, \&.\&.\&. ] + +ALTER GROUP \fIgroup_name\fR RENAME TO \fInew_name\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER GROUP\fR +changes the attributes of a user group\&. This is an obsolete command, though still accepted for backwards compatibility, because groups (and users too) have been superseded by the more general concept of roles\&. +.PP +The first two variants add users to a group or remove them from a group\&. (Any role can play the part of either a +\(lquser\(rq +or a +\(lqgroup\(rq +for this purpose\&.) These variants are effectively equivalent to granting or revoking membership in the role named as the +\(lqgroup\(rq; so the preferred way to do this is to use +\fBGRANT\fR(7) +or +\fBREVOKE\fR(7)\&. +.PP +The third variant changes the name of the group\&. This is exactly equivalent to renaming the role with +ALTER ROLE (\fBALTER_ROLE\fR(7))\&. +.SH "PARAMETERS" +.PP +\fIgroup_name\fR +.RS 4 +The name of the group (role) to modify\&. +.RE +.PP +\fIuser_name\fR +.RS 4 +Users (roles) that are to be added to or removed from the group\&. The users must already exist; +\fBALTER GROUP\fR +does not create or drop users\&. +.RE +.PP +\fInew_name\fR +.RS 4 +The new name of the group\&. +.RE +.SH "EXAMPLES" +.PP +Add users to a group: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER GROUP staff ADD USER karl, john; +.fi +.if n \{\ +.RE +.\} +.sp +Remove a user from a group: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER GROUP workers DROP USER beth; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBALTER GROUP\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +\fBGRANT\fR(7), \fBREVOKE\fR(7), ALTER ROLE (\fBALTER_ROLE\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_INDEX.7 b/doc/src/sgml/man7/ALTER_INDEX.7 new file mode 100644 index 000000000..399fc84eb --- /dev/null +++ b/doc/src/sgml/man7/ALTER_INDEX.7 @@ -0,0 +1,167 @@ +'\" t +.\" Title: ALTER INDEX +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER INDEX" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_INDEX \- change the definition of an index +.\" ALTER INDEX +.SH "SYNOPSIS" +.sp +.nf +ALTER INDEX [ IF EXISTS ] \fIname\fR RENAME TO \fInew_name\fR +ALTER INDEX [ IF EXISTS ] \fIname\fR SET TABLESPACE \fItablespace_name\fR +ALTER INDEX [ IF EXISTS ] \fIname\fR SET ( \fIstorage_parameter\fR = \fIvalue\fR [, \&.\&.\&. ] ) +ALTER INDEX [ IF EXISTS ] \fIname\fR RESET ( \fIstorage_parameter\fR [, \&.\&.\&. ] ) +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER INDEX\fR +changes the definition of an existing index\&. There are several subforms: +.PP +IF EXISTS +.RS 4 +Do not throw an error if the index does not exist\&. A notice is issued in this case\&. +.RE +.PP +RENAME +.RS 4 +The +RENAME +form changes the name of the index\&. There is no effect on the stored data\&. +.RE +.PP +SET TABLESPACE +.RS 4 +This form changes the index\*(Aqs tablespace to the specified tablespace and moves the data file(s) associated with the index to the new tablespace\&. See also +CREATE TABLESPACE (\fBCREATE_TABLESPACE\fR(7))\&. +.RE +.PP +SET ( \fIstorage_parameter\fR = \fIvalue\fR [, \&.\&.\&. ] ) +.RS 4 +This form changes one or more index\-method\-specific storage parameters for the index\&. See +CREATE INDEX (\fBCREATE_INDEX\fR(7)) +for details on the available parameters\&. Note that the index contents will not be modified immediately by this command; depending on the parameter you might need to rebuild the index with +\fBREINDEX\fR(7) +to get the desired effects\&. +.RE +.PP +RESET ( \fIstorage_parameter\fR [, \&.\&.\&. ] ) +.RS 4 +This form resets one or more index\-method\-specific storage parameters to their defaults\&. As with +SET, a +REINDEX +might be needed to update the index entirely\&. +.RE +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name (possibly schema\-qualified) of an existing index to alter\&. +.RE +.PP +\fInew_name\fR +.RS 4 +The new name for the index\&. +.RE +.PP +\fItablespace_name\fR +.RS 4 +The tablespace to which the index will be moved\&. +.RE +.PP +\fIstorage_parameter\fR +.RS 4 +The name of an index\-method\-specific storage parameter\&. +.RE +.PP +\fIvalue\fR +.RS 4 +The new value for an index\-method\-specific storage parameter\&. This might be a number or a word depending on the parameter\&. +.RE +.SH "NOTES" +.PP +These operations are also possible using +ALTER TABLE (\fBALTER_TABLE\fR(7))\&. +\fBALTER INDEX\fR +is in fact just an alias for the forms of +\fBALTER TABLE\fR +that apply to indexes\&. +.PP +There was formerly an +\fBALTER INDEX OWNER\fR +variant, but this is now ignored (with a warning)\&. An index cannot have an owner different from its table\*(Aqs owner\&. Changing the table\*(Aqs owner automatically changes the index as well\&. +.PP +Changing any part of a system catalog index is not permitted\&. +.SH "EXAMPLES" +.PP +To rename an existing index: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER INDEX distributors RENAME TO suppliers; +.fi +.if n \{\ +.RE +.\} +.PP +To move an index to a different tablespace: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER INDEX distributors SET TABLESPACE fasttablespace; +.fi +.if n \{\ +.RE +.\} +.PP +To change an index\*(Aqs fill factor (assuming that the index method supports it): +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER INDEX distributors SET (fillfactor = 75); +REINDEX INDEX distributors; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBALTER INDEX\fR +is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +CREATE INDEX (\fBCREATE_INDEX\fR(7)), \fBREINDEX\fR(7) diff --git a/doc/src/sgml/man7/ALTER_LANGUAGE.7 b/doc/src/sgml/man7/ALTER_LANGUAGE.7 new file mode 100644 index 000000000..c8e99c31b --- /dev/null +++ b/doc/src/sgml/man7/ALTER_LANGUAGE.7 @@ -0,0 +1,67 @@ +'\" t +.\" Title: ALTER LANGUAGE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER LANGUAGE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_LANGUAGE \- change the definition of a procedural language +.\" ALTER LANGUAGE +.SH "SYNOPSIS" +.sp +.nf +ALTER [ PROCEDURAL ] LANGUAGE \fIname\fR RENAME TO \fInew_name\fR +ALTER [ PROCEDURAL ] LANGUAGE \fIname\fR OWNER TO \fInew_owner\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER LANGUAGE\fR +changes the definition of a procedural language\&. The only functionality is to rename the language or assign a new owner\&. You must be superuser or owner of the language to use +\fBALTER LANGUAGE\fR\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +Name of a language +.RE +.PP +\fInew_name\fR +.RS 4 +The new name of the language +.RE +.PP +\fInew_owner\fR +.RS 4 +The new owner of the language +.RE +.SH "COMPATIBILITY" +.PP +There is no +\fBALTER LANGUAGE\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +CREATE LANGUAGE (\fBCREATE_LANGUAGE\fR(7)), DROP LANGUAGE (\fBDROP_LANGUAGE\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_LARGE_OBJECT.7 b/doc/src/sgml/man7/ALTER_LARGE_OBJECT.7 new file mode 100644 index 000000000..e3cc6c72b --- /dev/null +++ b/doc/src/sgml/man7/ALTER_LARGE_OBJECT.7 @@ -0,0 +1,61 @@ +'\" t +.\" Title: ALTER LARGE OBJECT +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER LARGE OBJECT" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_LARGE_OBJECT \- change the definition of a large object +.\" ALTER LARGE OBJECT +.SH "SYNOPSIS" +.sp +.nf +ALTER LARGE OBJECT \fIlarge_object_oid\fR OWNER TO \fInew_owner\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER LARGE OBJECT\fR +changes the definition of a large object\&. The only functionality is to assign a new owner\&. You must be superuser or owner of the large object to use +\fBALTER LARGE OBJECT\fR\&. +.SH "PARAMETERS" +.PP +\fIlarge_object_oid\fR +.RS 4 +OID of the large object to be altered +.RE +.PP +\fInew_owner\fR +.RS 4 +The new owner of the large object +.RE +.SH "COMPATIBILITY" +.PP +There is no +\fBALTER LARGE OBJECT\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +Chapter 32, Large Objects, in the documentation diff --git a/doc/src/sgml/man7/ALTER_OPERATOR.7 b/doc/src/sgml/man7/ALTER_OPERATOR.7 new file mode 100644 index 000000000..340078177 --- /dev/null +++ b/doc/src/sgml/man7/ALTER_OPERATOR.7 @@ -0,0 +1,101 @@ +'\" t +.\" Title: ALTER OPERATOR +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER OPERATOR" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_OPERATOR \- change the definition of an operator +.\" ALTER OPERATOR +.SH "SYNOPSIS" +.sp +.nf +ALTER OPERATOR \fIname\fR ( { \fIleft_type\fR | NONE } , { \fIright_type\fR | NONE } ) OWNER TO \fInew_owner\fR +ALTER OPERATOR \fIname\fR ( { \fIleft_type\fR | NONE } , { \fIright_type\fR | NONE } ) SET SCHEMA \fInew_schema\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER OPERATOR\fR +changes the definition of an operator\&. The only currently available functionality is to change the owner of the operator\&. +.PP +You must own the operator to use +\fBALTER OPERATOR\fR\&. To alter the owner, you must also be a direct or indirect member of the new owning role, and that role must have +CREATE +privilege on the operator\*(Aqs schema\&. (These restrictions enforce that altering the owner doesn\*(Aqt do anything you couldn\*(Aqt do by dropping and recreating the operator\&. However, a superuser can alter ownership of any operator anyway\&.) +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an existing operator\&. +.RE +.PP +\fIleft_type\fR +.RS 4 +The data type of the operator\*(Aqs left operand; write +NONE +if the operator has no left operand\&. +.RE +.PP +\fIright_type\fR +.RS 4 +The data type of the operator\*(Aqs right operand; write +NONE +if the operator has no right operand\&. +.RE +.PP +\fInew_owner\fR +.RS 4 +The new owner of the operator\&. +.RE +.PP +\fInew_schema\fR +.RS 4 +The new schema for the operator\&. +.RE +.SH "EXAMPLES" +.PP +Change the owner of a custom operator +a @@ b +for type +text: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER OPERATOR @@ (text, text) OWNER TO joe; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBALTER OPERATOR\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +CREATE OPERATOR (\fBCREATE_OPERATOR\fR(7)), DROP OPERATOR (\fBDROP_OPERATOR\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_OPERATOR_CLASS.7 b/doc/src/sgml/man7/ALTER_OPERATOR_CLASS.7 new file mode 100644 index 000000000..06e1b8daa --- /dev/null +++ b/doc/src/sgml/man7/ALTER_OPERATOR_CLASS.7 @@ -0,0 +1,82 @@ +'\" t +.\" Title: ALTER OPERATOR CLASS +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER OPERATOR CLASS" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_OPERATOR_CLASS \- change the definition of an operator class +.\" ALTER OPERATOR CLASS +.SH "SYNOPSIS" +.sp +.nf +ALTER OPERATOR CLASS \fIname\fR USING \fIindex_method\fR RENAME TO \fInew_name\fR +ALTER OPERATOR CLASS \fIname\fR USING \fIindex_method\fR OWNER TO \fInew_owner\fR +ALTER OPERATOR CLASS \fIname\fR USING \fIindex_method\fR SET SCHEMA \fInew_schema\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER OPERATOR CLASS\fR +changes the definition of an operator class\&. +.PP +You must own the operator class to use +\fBALTER OPERATOR CLASS\fR\&. To alter the owner, you must also be a direct or indirect member of the new owning role, and that role must have +CREATE +privilege on the operator class\*(Aqs schema\&. (These restrictions enforce that altering the owner doesn\*(Aqt do anything you couldn\*(Aqt do by dropping and recreating the operator class\&. However, a superuser can alter ownership of any operator class anyway\&.) +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an existing operator class\&. +.RE +.PP +\fIindex_method\fR +.RS 4 +The name of the index method this operator class is for\&. +.RE +.PP +\fInew_name\fR +.RS 4 +The new name of the operator class\&. +.RE +.PP +\fInew_owner\fR +.RS 4 +The new owner of the operator class\&. +.RE +.PP +\fInew_schema\fR +.RS 4 +The new schema for the operator class\&. +.RE +.SH "COMPATIBILITY" +.PP +There is no +\fBALTER OPERATOR CLASS\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +CREATE OPERATOR CLASS (\fBCREATE_OPERATOR_CLASS\fR(7)), DROP OPERATOR CLASS (\fBDROP_OPERATOR_CLASS\fR(7)), ALTER OPERATOR FAMILY (\fBALTER_OPERATOR_FAMILY\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_OPERATOR_FAMILY.7 b/doc/src/sgml/man7/ALTER_OPERATOR_FAMILY.7 new file mode 100644 index 000000000..00c722713 --- /dev/null +++ b/doc/src/sgml/man7/ALTER_OPERATOR_FAMILY.7 @@ -0,0 +1,253 @@ +'\" t +.\" Title: ALTER OPERATOR FAMILY +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER OPERATOR FAMILY" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_OPERATOR_FAMILY \- change the definition of an operator family +.\" ALTER OPERATOR FAMILY +.SH "SYNOPSIS" +.sp +.nf +ALTER OPERATOR FAMILY \fIname\fR USING \fIindex_method\fR ADD + { OPERATOR \fIstrategy_number\fR \fIoperator_name\fR ( \fIop_type\fR, \fIop_type\fR ) [ FOR SEARCH | FOR ORDER BY \fIsort_family_name\fR ] + | FUNCTION \fIsupport_number\fR [ ( \fIop_type\fR [ , \fIop_type\fR ] ) ] \fIfunction_name\fR ( \fIargument_type\fR [, \&.\&.\&.] ) + } [, \&.\&.\&. ] +ALTER OPERATOR FAMILY \fIname\fR USING \fIindex_method\fR DROP + { OPERATOR \fIstrategy_number\fR ( \fIop_type\fR [ , \fIop_type\fR ] ) + | FUNCTION \fIsupport_number\fR ( \fIop_type\fR [ , \fIop_type\fR ] ) + } [, \&.\&.\&. ] +ALTER OPERATOR FAMILY \fIname\fR USING \fIindex_method\fR RENAME TO \fInew_name\fR +ALTER OPERATOR FAMILY \fIname\fR USING \fIindex_method\fR OWNER TO \fInew_owner\fR +ALTER OPERATOR FAMILY \fIname\fR USING \fIindex_method\fR SET SCHEMA \fInew_schema\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER OPERATOR FAMILY\fR +changes the definition of an operator family\&. You can add operators and support functions to the family, remove them from the family, or change the family\*(Aqs name or owner\&. +.PP +When operators and support functions are added to a family with +\fBALTER OPERATOR FAMILY\fR, they are not part of any specific operator class within the family, but are just +\(lqloose\(rq +within the family\&. This indicates that these operators and functions are compatible with the family\*(Aqs semantics, but are not required for correct functioning of any specific index\&. (Operators and functions that are so required should be declared as part of an operator class, instead; see +CREATE OPERATOR CLASS (\fBCREATE_OPERATOR_CLASS\fR(7))\&.) +PostgreSQL +will allow loose members of a family to be dropped from the family at any time, but members of an operator class cannot be dropped without dropping the whole class and any indexes that depend on it\&. Typically, single\-data\-type operators and functions are part of operator classes because they are needed to support an index on that specific data type, while cross\-data\-type operators and functions are made loose members of the family\&. +.PP +You must be a superuser to use +\fBALTER OPERATOR FAMILY\fR\&. (This restriction is made because an erroneous operator family definition could confuse or even crash the server\&.) +.PP + +\fBALTER OPERATOR FAMILY\fR +does not presently check whether the operator family definition includes all the operators and functions required by the index method, nor whether the operators and functions form a self\-consistent set\&. It is the user\*(Aqs responsibility to define a valid operator family\&. +.PP +Refer to +Section 35.14, \(lqInterfacing Extensions To Indexes\(rq, in the documentation +for further information\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an existing operator family\&. +.RE +.PP +\fIindex_method\fR +.RS 4 +The name of the index method this operator family is for\&. +.RE +.PP +\fIstrategy_number\fR +.RS 4 +The index method\*(Aqs strategy number for an operator associated with the operator family\&. +.RE +.PP +\fIoperator_name\fR +.RS 4 +The name (optionally schema\-qualified) of an operator associated with the operator family\&. +.RE +.PP +\fIop_type\fR +.RS 4 +In an +OPERATOR +clause, the operand data type(s) of the operator, or +NONE +to signify a left\-unary or right\-unary operator\&. Unlike the comparable syntax in +\fBCREATE OPERATOR CLASS\fR, the operand data types must always be specified\&. +.sp +In an +ADD FUNCTION +clause, the operand data type(s) the function is intended to support, if different from the input data type(s) of the function\&. For B\-tree comparison functions and hash functions it is not necessary to specify +\fIop_type\fR +since the function\*(Aqs input data type(s) are always the correct ones to use\&. For B\-tree sort support functions and all functions in GiST, SP\-GiST and GIN operator classes, it is necessary to specify the operand data type(s) the function is to be used with\&. +.sp +In a +DROP FUNCTION +clause, the operand data type(s) the function is intended to support must be specified\&. +.RE +.PP +\fIsort_family_name\fR +.RS 4 +The name (optionally schema\-qualified) of an existing +btree +operator family that describes the sort ordering associated with an ordering operator\&. +.sp +If neither +FOR SEARCH +nor +FOR ORDER BY +is specified, +FOR SEARCH +is the default\&. +.RE +.PP +\fIsupport_number\fR +.RS 4 +The index method\*(Aqs support procedure number for a function associated with the operator family\&. +.RE +.PP +\fIfunction_name\fR +.RS 4 +The name (optionally schema\-qualified) of a function that is an index method support procedure for the operator family\&. +.RE +.PP +\fIargument_type\fR +.RS 4 +The parameter data type(s) of the function\&. +.RE +.PP +\fInew_name\fR +.RS 4 +The new name of the operator family\&. +.RE +.PP +\fInew_owner\fR +.RS 4 +The new owner of the operator family\&. +.RE +.PP +\fInew_schema\fR +.RS 4 +The new schema for the operator family\&. +.RE +.PP +The +OPERATOR +and +FUNCTION +clauses can appear in any order\&. +.SH "NOTES" +.PP +Notice that the +DROP +syntax only specifies the +\(lqslot\(rq +in the operator family, by strategy or support number and input data type(s)\&. The name of the operator or function occupying the slot is not mentioned\&. Also, for +DROP FUNCTION +the type(s) to specify are the input data type(s) the function is intended to support; for GiST, SP\-GiST and GIN indexes this might have nothing to do with the actual input argument types of the function\&. +.PP +Because the index machinery does not check access permissions on functions before using them, including a function or operator in an operator family is tantamount to granting public execute permission on it\&. This is usually not an issue for the sorts of functions that are useful in an operator family\&. +.PP +The operators should not be defined by SQL functions\&. A SQL function is likely to be inlined into the calling query, which will prevent the optimizer from recognizing that the query matches an index\&. +.PP +Before +PostgreSQL +8\&.4, the +OPERATOR +clause could include a +RECHECK +option\&. This is no longer supported because whether an index operator is +\(lqlossy\(rq +is now determined on\-the\-fly at run time\&. This allows efficient handling of cases where an operator might or might not be lossy\&. +.SH "EXAMPLES" +.PP +The following example command adds cross\-data\-type operators and support functions to an operator family that already contains B\-tree operator classes for data types +int4 +and +int2\&. +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER OPERATOR FAMILY integer_ops USING btree ADD + + \-\- int4 vs int2 + OPERATOR 1 < (int4, int2) , + OPERATOR 2 <= (int4, int2) , + OPERATOR 3 = (int4, int2) , + OPERATOR 4 >= (int4, int2) , + OPERATOR 5 > (int4, int2) , + FUNCTION 1 btint42cmp(int4, int2) , + + \-\- int2 vs int4 + OPERATOR 1 < (int2, int4) , + OPERATOR 2 <= (int2, int4) , + OPERATOR 3 = (int2, int4) , + OPERATOR 4 >= (int2, int4) , + OPERATOR 5 > (int2, int4) , + FUNCTION 1 btint24cmp(int2, int4) ; +.fi +.if n \{\ +.RE +.\} +.PP +To remove these entries again: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER OPERATOR FAMILY integer_ops USING btree DROP + + \-\- int4 vs int2 + OPERATOR 1 (int4, int2) , + OPERATOR 2 (int4, int2) , + OPERATOR 3 (int4, int2) , + OPERATOR 4 (int4, int2) , + OPERATOR 5 (int4, int2) , + FUNCTION 1 (int4, int2) , + + \-\- int2 vs int4 + OPERATOR 1 (int2, int4) , + OPERATOR 2 (int2, int4) , + OPERATOR 3 (int2, int4) , + OPERATOR 4 (int2, int4) , + OPERATOR 5 (int2, int4) , + FUNCTION 1 (int2, int4) ; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBALTER OPERATOR FAMILY\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +CREATE OPERATOR FAMILY (\fBCREATE_OPERATOR_FAMILY\fR(7)), DROP OPERATOR FAMILY (\fBDROP_OPERATOR_FAMILY\fR(7)), CREATE OPERATOR CLASS (\fBCREATE_OPERATOR_CLASS\fR(7)), ALTER OPERATOR CLASS (\fBALTER_OPERATOR_CLASS\fR(7)), DROP OPERATOR CLASS (\fBDROP_OPERATOR_CLASS\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_ROLE.7 b/doc/src/sgml/man7/ALTER_ROLE.7 new file mode 100644 index 000000000..16683c584 --- /dev/null +++ b/doc/src/sgml/man7/ALTER_ROLE.7 @@ -0,0 +1,269 @@ +'\" t +.\" Title: ALTER ROLE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER ROLE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_ROLE \- change a database role +.\" ALTER ROLE +.SH "SYNOPSIS" +.sp +.nf +ALTER ROLE \fIname\fR [ [ WITH ] \fIoption\fR [ \&.\&.\&. ] ] + +where \fIoption\fR can be: + + SUPERUSER | NOSUPERUSER + | CREATEDB | NOCREATEDB + | CREATEROLE | NOCREATEROLE + | CREATEUSER | NOCREATEUSER + | INHERIT | NOINHERIT + | LOGIN | NOLOGIN + | REPLICATION | NOREPLICATION + | CONNECTION LIMIT \fIconnlimit\fR + | [ ENCRYPTED | UNENCRYPTED ] PASSWORD \*(Aq\fIpassword\fR\*(Aq + | VALID UNTIL \*(Aq\fItimestamp\fR\*(Aq + +ALTER ROLE \fIname\fR RENAME TO \fInew_name\fR + +ALTER ROLE \fIname\fR [ IN DATABASE \fIdatabase_name\fR ] SET \fIconfiguration_parameter\fR { TO | = } { \fIvalue\fR | DEFAULT } +ALTER ROLE \fIname\fR [ IN DATABASE \fIdatabase_name\fR ] SET \fIconfiguration_parameter\fR FROM CURRENT +ALTER ROLE \fIname\fR [ IN DATABASE \fIdatabase_name\fR ] RESET \fIconfiguration_parameter\fR +ALTER ROLE \fIname\fR [ IN DATABASE \fIdatabase_name\fR ] RESET ALL +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER ROLE\fR +changes the attributes of a +PostgreSQL +role\&. +.PP +The first variant of this command listed in the synopsis can change many of the role attributes that can be specified in +CREATE ROLE (\fBCREATE_ROLE\fR(7))\&. (All the possible attributes are covered, except that there are no options for adding or removing memberships; use +\fBGRANT\fR(7) +and +\fBREVOKE\fR(7) +for that\&.) Attributes not mentioned in the command retain their previous settings\&. Database superusers can change any of these settings for any role\&. Roles having +CREATEROLE +privilege can change any of these settings, but only for non\-superuser and non\-replication roles\&. Ordinary roles can only change their own password\&. +.PP +The second variant changes the name of the role\&. Database superusers can rename any role\&. Roles having +CREATEROLE +privilege can rename non\-superuser roles\&. The current session user cannot be renamed\&. (Connect as a different user if you need to do that\&.) Because +MD5\-encrypted passwords use the role name as cryptographic salt, renaming a role clears its password if the password is +MD5\-encrypted\&. +.PP +The remaining variants change a role\*(Aqs session default for a configuration variable, either for all databases or, when the +IN DATABASE +clause is specified, only for sessions in the named database\&. Whenever the role subsequently starts a new session, the specified value becomes the session default, overriding whatever setting is present in +postgresql\&.conf +or has been received from the +\fBpostgres\fR +command line\&. This only happens at login time; executing +SET ROLE (\fBSET_ROLE\fR(7)) +or +SET SESSION AUTHORIZATION (\fBSET_SESSION_AUTHORIZATION\fR(7)) +does not cause new configuration values to be set\&. Settings set for all databases are overridden by database\-specific settings attached to a role\&. Superusers can change anyone\*(Aqs session defaults\&. Roles having +CREATEROLE +privilege can change defaults for non\-superuser roles\&. Ordinary roles can only set defaults for themselves\&. Certain configuration variables cannot be set this way, or can only be set if a superuser issues the command\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name of the role whose attributes are to be altered\&. +.RE +.PP +SUPERUSER, NOSUPERUSER, CREATEDB, NOCREATEDB, CREATEROLE, NOCREATEROLE, CREATEUSER, NOCREATEUSER, INHERIT, NOINHERIT, LOGIN, NOLOGIN, REPLICATION, NOREPLICATION, CONNECTION LIMIT \fIconnlimit\fR, PASSWORD \fIpassword\fR, ENCRYPTED, UNENCRYPTED, VALID UNTIL \*(Aq\fItimestamp\fR\*(Aq +.RS 4 +These clauses alter attributes originally set by +CREATE ROLE (\fBCREATE_ROLE\fR(7))\&. For more information, see the +\fBCREATE ROLE\fR +reference page\&. +.RE +.PP +\fInew_name\fR +.RS 4 +The new name of the role\&. +.RE +.PP +\fIdatabase_name\fR +.RS 4 +The name of the database the configuration variable should be set in\&. +.RE +.PP +\fIconfiguration_parameter\fR, \fIvalue\fR +.RS 4 +Set this role\*(Aqs session default for the specified configuration parameter to the given value\&. If +\fIvalue\fR +is +DEFAULT +or, equivalently, +RESET +is used, the role\-specific variable setting is removed, so the role will inherit the system\-wide default setting in new sessions\&. Use +RESET ALL +to clear all role\-specific settings\&. +SET FROM CURRENT +saves the session\*(Aqs current value of the parameter as the role\-specific value\&. If +IN DATABASE +is specified, the configuration parameter is set or removed for the given role and database only\&. +.sp +Role\-specific variable settings take effect only at login; +SET ROLE (\fBSET_ROLE\fR(7)) +and +SET SESSION AUTHORIZATION (\fBSET_SESSION_AUTHORIZATION\fR(7)) +do not process role\-specific variable settings\&. +.sp +See +\fBSET\fR(7) +and +Chapter 18, Server Configuration, in the documentation +for more information about allowed parameter names and values\&. +.RE +.SH "NOTES" +.PP +Use +CREATE ROLE (\fBCREATE_ROLE\fR(7)) +to add new roles, and +DROP ROLE (\fBDROP_ROLE\fR(7)) +to remove a role\&. +.PP + +\fBALTER ROLE\fR +cannot change a role\*(Aqs memberships\&. Use +\fBGRANT\fR(7) +and +\fBREVOKE\fR(7) +to do that\&. +.PP +Caution must be exercised when specifying an unencrypted password with this command\&. The password will be transmitted to the server in cleartext, and it might also be logged in the client\*(Aqs command history or the server log\&. +\fBpsql\fR(1) +contains a command +\fB\epassword\fR +that can be used to change a role\*(Aqs password without exposing the cleartext password\&. +.PP +It is also possible to tie a session default to a specific database rather than to a role; see +ALTER DATABASE (\fBALTER_DATABASE\fR(7))\&. If there is a conflict, database\-role\-specific settings override role\-specific ones, which in turn override database\-specific ones\&. +.SH "EXAMPLES" +.PP +Change a role\*(Aqs password: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER ROLE davide WITH PASSWORD \*(Aqhu8jmn3\*(Aq; +.fi +.if n \{\ +.RE +.\} +.PP +Remove a role\*(Aqs password: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER ROLE davide WITH PASSWORD NULL; +.fi +.if n \{\ +.RE +.\} +.PP +Change a password expiration date, specifying that the password should expire at midday on 4th May 2015 using the time zone which is one hour ahead of +UTC: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER ROLE chris VALID UNTIL \*(AqMay 4 12:00:00 2015 +1\*(Aq; +.fi +.if n \{\ +.RE +.\} +.PP +Make a password valid forever: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER ROLE fred VALID UNTIL \*(Aqinfinity\*(Aq; +.fi +.if n \{\ +.RE +.\} +.PP +Give a role the ability to create other roles and new databases: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER ROLE miriam CREATEROLE CREATEDB; +.fi +.if n \{\ +.RE +.\} +.PP +Give a role a non\-default setting of the +maintenance_work_mem +parameter: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER ROLE worker_bee SET maintenance_work_mem = 100000; +.fi +.if n \{\ +.RE +.\} +.PP +Give a role a non\-default, database\-specific setting of the +client_min_messages +parameter: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER ROLE fred IN DATABASE devel SET client_min_messages = DEBUG; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +The +\fBALTER ROLE\fR +statement is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +CREATE ROLE (\fBCREATE_ROLE\fR(7)), DROP ROLE (\fBDROP_ROLE\fR(7)), \fBSET\fR(7) diff --git a/doc/src/sgml/man7/ALTER_SCHEMA.7 b/doc/src/sgml/man7/ALTER_SCHEMA.7 new file mode 100644 index 000000000..66f9667f4 --- /dev/null +++ b/doc/src/sgml/man7/ALTER_SCHEMA.7 @@ -0,0 +1,74 @@ +'\" t +.\" Title: ALTER SCHEMA +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER SCHEMA" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_SCHEMA \- change the definition of a schema +.\" ALTER SCHEMA +.SH "SYNOPSIS" +.sp +.nf +ALTER SCHEMA \fIname\fR RENAME TO \fInew_name\fR +ALTER SCHEMA \fIname\fR OWNER TO \fInew_owner\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER SCHEMA\fR +changes the definition of a schema\&. +.PP +You must own the schema to use +\fBALTER SCHEMA\fR\&. To rename a schema you must also have the +CREATE +privilege for the database\&. To alter the owner, you must also be a direct or indirect member of the new owning role, and you must have the +CREATE +privilege for the database\&. (Note that superusers have all these privileges automatically\&.) +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name of an existing schema\&. +.RE +.PP +\fInew_name\fR +.RS 4 +The new name of the schema\&. The new name cannot begin with +pg_, as such names are reserved for system schemas\&. +.RE +.PP +\fInew_owner\fR +.RS 4 +The new owner of the schema\&. +.RE +.SH "COMPATIBILITY" +.PP +There is no +\fBALTER SCHEMA\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +CREATE SCHEMA (\fBCREATE_SCHEMA\fR(7)), DROP SCHEMA (\fBDROP_SCHEMA\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_SEQUENCE.7 b/doc/src/sgml/man7/ALTER_SEQUENCE.7 new file mode 100644 index 000000000..a22b41459 --- /dev/null +++ b/doc/src/sgml/man7/ALTER_SEQUENCE.7 @@ -0,0 +1,248 @@ +'\" t +.\" Title: ALTER SEQUENCE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER SEQUENCE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_SEQUENCE \- change the definition of a sequence generator +.\" ALTER SEQUENCE +.SH "SYNOPSIS" +.sp +.nf +ALTER SEQUENCE [ IF EXISTS ] \fIname\fR [ INCREMENT [ BY ] \fIincrement\fR ] + [ MINVALUE \fIminvalue\fR | NO MINVALUE ] [ MAXVALUE \fImaxvalue\fR | NO MAXVALUE ] + [ START [ WITH ] \fIstart\fR ] + [ RESTART [ [ WITH ] \fIrestart\fR ] ] + [ CACHE \fIcache\fR ] [ [ NO ] CYCLE ] + [ OWNED BY { \fItable_name\fR\&.\fIcolumn_name\fR | NONE } ] +ALTER SEQUENCE [ IF EXISTS ] \fIname\fR OWNER TO \fInew_owner\fR +ALTER SEQUENCE [ IF EXISTS ] \fIname\fR RENAME TO \fInew_name\fR +ALTER SEQUENCE [ IF EXISTS ] \fIname\fR SET SCHEMA \fInew_schema\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER SEQUENCE\fR +changes the parameters of an existing sequence generator\&. Any parameters not specifically set in the +\fBALTER SEQUENCE\fR +command retain their prior settings\&. +.PP +You must own the sequence to use +\fBALTER SEQUENCE\fR\&. To change a sequence\*(Aqs schema, you must also have +CREATE +privilege on the new schema\&. To alter the owner, you must also be a direct or indirect member of the new owning role, and that role must have +CREATE +privilege on the sequence\*(Aqs schema\&. (These restrictions enforce that altering the owner doesn\*(Aqt do anything you couldn\*(Aqt do by dropping and recreating the sequence\&. However, a superuser can alter ownership of any sequence anyway\&.) +.SH "PARAMETERS" +.PP +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of a sequence to be altered\&. +.RE +.PP +IF EXISTS +.RS 4 +Do not throw an error if the sequence does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIincrement\fR +.RS 4 +The clause +INCREMENT BY \fIincrement\fR +is optional\&. A positive value will make an ascending sequence, a negative one a descending sequence\&. If unspecified, the old increment value will be maintained\&. +.RE +.PP +\fIminvalue\fR, NO MINVALUE +.RS 4 +The optional clause +MINVALUE \fIminvalue\fR +determines the minimum value a sequence can generate\&. If +NO MINVALUE +is specified, the defaults of 1 and \-263\-1 for ascending and descending sequences, respectively, will be used\&. If neither option is specified, the current minimum value will be maintained\&. +.RE +.PP +\fImaxvalue\fR, NO MAXVALUE +.RS 4 +The optional clause +MAXVALUE \fImaxvalue\fR +determines the maximum value for the sequence\&. If +NO MAXVALUE +is specified, the defaults are 263\-1 and \-1 for ascending and descending sequences, respectively, will be used\&. If neither option is specified, the current maximum value will be maintained\&. +.RE +.PP +\fIstart\fR +.RS 4 +The optional clause +START WITH \fIstart\fR +changes the recorded start value of the sequence\&. This has no effect on the +\fIcurrent\fR +sequence value; it simply sets the value that future +\fBALTER SEQUENCE RESTART\fR +commands will use\&. +.RE +.PP +\fIrestart\fR +.RS 4 +The optional clause +RESTART [ WITH \fIrestart\fR ] +changes the current value of the sequence\&. This is equivalent to calling the +\fBsetval\fR +function with +is_called += +false: the specified value will be returned by the +\fInext\fR +call of +\fBnextval\fR\&. Writing +RESTART +with no +\fIrestart\fR +value is equivalent to supplying the start value that was recorded by +\fBCREATE SEQUENCE\fR +or last set by +\fBALTER SEQUENCE START WITH\fR\&. +.RE +.PP +\fIcache\fR +.RS 4 +The clause +CACHE \fIcache\fR +enables sequence numbers to be preallocated and stored in memory for faster access\&. The minimum value is 1 (only one value can be generated at a time, i\&.e\&., no cache)\&. If unspecified, the old cache value will be maintained\&. +.RE +.PP +CYCLE +.RS 4 +The optional +CYCLE +key word can be used to enable the sequence to wrap around when the +\fImaxvalue\fR +or +\fIminvalue\fR +has been reached by an ascending or descending sequence respectively\&. If the limit is reached, the next number generated will be the +\fIminvalue\fR +or +\fImaxvalue\fR, respectively\&. +.RE +.PP +NO CYCLE +.RS 4 +If the optional +NO CYCLE +key word is specified, any calls to +\fBnextval\fR +after the sequence has reached its maximum value will return an error\&. If neither +CYCLE +or +NO CYCLE +are specified, the old cycle behavior will be maintained\&. +.RE +.PP +OWNED BY \fItable_name\fR\&.\fIcolumn_name\fR, OWNED BY NONE +.RS 4 +The +OWNED BY +option causes the sequence to be associated with a specific table column, such that if that column (or its whole table) is dropped, the sequence will be automatically dropped as well\&. If specified, this association replaces any previously specified association for the sequence\&. The specified table must have the same owner and be in the same schema as the sequence\&. Specifying +OWNED BY NONE +removes any existing association, making the sequence +\(lqfree\-standing\(rq\&. +.RE +.PP +\fInew_owner\fR +.RS 4 +The user name of the new owner of the sequence\&. +.RE +.PP +\fInew_name\fR +.RS 4 +The new name for the sequence\&. +.RE +.PP +\fInew_schema\fR +.RS 4 +The new schema for the sequence\&. +.RE +.SH "NOTES" +.PP +To avoid blocking of concurrent transactions that obtain numbers from the same sequence, +\fBALTER SEQUENCE\fR\*(Aqs effects on the sequence generation parameters are never rolled back; those changes take effect immediately and are not reversible\&. However, the +OWNED BY, +OWNER TO, +RENAME TO, and +SET SCHEMA +clauses cause ordinary catalog updates that can be rolled back\&. +.PP + +\fBALTER SEQUENCE\fR +will not immediately affect +\fBnextval\fR +results in backends, other than the current one, that have preallocated (cached) sequence values\&. They will use up all cached values prior to noticing the changed sequence generation parameters\&. The current backend will be affected immediately\&. +.PP + +\fBALTER SEQUENCE\fR +does not affect the +\fBcurrval\fR +status for the sequence\&. (Before +PostgreSQL +8\&.3, it sometimes did\&.) +.PP +For historical reasons, +\fBALTER TABLE\fR +can be used with sequences too; but the only variants of +\fBALTER TABLE\fR +that are allowed with sequences are equivalent to the forms shown above\&. +.SH "EXAMPLES" +.PP +Restart a sequence called +serial, at 105: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER SEQUENCE serial RESTART WITH 105; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBALTER SEQUENCE\fR +conforms to the +SQL +standard, except for the +START WITH, +OWNED BY, +OWNER TO, +RENAME TO, and +SET SCHEMA +clauses, which are +PostgreSQL +extensions\&. +.SH "SEE ALSO" +CREATE SEQUENCE (\fBCREATE_SEQUENCE\fR(7)), DROP SEQUENCE (\fBDROP_SEQUENCE\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_SERVER.7 b/doc/src/sgml/man7/ALTER_SERVER.7 new file mode 100644 index 000000000..d688163c1 --- /dev/null +++ b/doc/src/sgml/man7/ALTER_SERVER.7 @@ -0,0 +1,121 @@ +'\" t +.\" Title: ALTER SERVER +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER SERVER" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_SERVER \- change the definition of a foreign server +.\" ALTER SERVER +.SH "SYNOPSIS" +.sp +.nf +ALTER SERVER \fIname\fR [ VERSION \*(Aq\fInew_version\fR\*(Aq ] + [ OPTIONS ( [ ADD | SET | DROP ] \fIoption\fR [\*(Aq\fIvalue\fR\*(Aq] [, \&.\&.\&. ] ) ] +ALTER SERVER \fIname\fR OWNER TO \fInew_owner\fR +ALTER SERVER \fIname\fR RENAME TO \fInew_name\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER SERVER\fR +changes the definition of a foreign server\&. The first form changes the server version string or the generic options of the server (at least one clause is required)\&. The second form changes the owner of the server\&. +.PP +To alter the server you must be the owner of the server\&. Additionally to alter the owner, you must own the server and also be a direct or indirect member of the new owning role, and you must have +USAGE +privilege on the server\*(Aqs foreign\-data wrapper\&. (Note that superusers satisfy all these criteria automatically\&.) +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name of an existing server\&. +.RE +.PP +\fInew_version\fR +.RS 4 +New server version\&. +.RE +.PP +OPTIONS ( [ ADD | SET | DROP ] \fIoption\fR [\*(Aq\fIvalue\fR\*(Aq] [, \&.\&.\&. ] ) +.RS 4 +Change options for the server\&. +ADD, +SET, and +DROP +specify the action to be performed\&. +ADD +is assumed if no operation is explicitly specified\&. Option names must be unique; names and values are also validated using the server\*(Aqs foreign\-data wrapper library\&. +.RE +.PP +\fInew_owner\fR +.RS 4 +The user name of the new owner of the foreign server\&. +.RE +.PP +\fInew_name\fR +.RS 4 +The new name for the foreign server\&. +.RE +.SH "EXAMPLES" +.PP +Alter server +foo, add connection options: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER SERVER foo OPTIONS (host \*(Aqfoo\*(Aq, dbname \*(Aqfoodb\*(Aq); +.fi +.if n \{\ +.RE +.\} +.PP +Alter server +foo, change version, change +host +option: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER SERVER foo VERSION \*(Aq8\&.4\*(Aq OPTIONS (SET host \*(Aqbaz\*(Aq); +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBALTER SERVER\fR +conforms to ISO/IEC 9075\-9 (SQL/MED)\&. The +OWNER TO +and +RENAME +forms are PostgreSQL extensions\&. +.SH "SEE ALSO" +CREATE SERVER (\fBCREATE_SERVER\fR(7)), DROP SERVER (\fBDROP_SERVER\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_TABLE.7 b/doc/src/sgml/man7/ALTER_TABLE.7 new file mode 100644 index 000000000..2f7607cb3 --- /dev/null +++ b/doc/src/sgml/man7/ALTER_TABLE.7 @@ -0,0 +1,934 @@ +'\" t +.\" Title: ALTER TABLE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER TABLE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_TABLE \- change the definition of a table +.\" ALTER TABLE +.SH "SYNOPSIS" +.sp +.nf +ALTER TABLE [ IF EXISTS ] [ ONLY ] \fIname\fR [ * ] + \fIaction\fR [, \&.\&.\&. ] +ALTER TABLE [ IF EXISTS ] [ ONLY ] \fIname\fR [ * ] + RENAME [ COLUMN ] \fIcolumn_name\fR TO \fInew_column_name\fR +ALTER TABLE [ IF EXISTS ] [ ONLY ] \fIname\fR [ * ] + RENAME CONSTRAINT \fIconstraint_name\fR TO \fInew_constraint_name\fR +ALTER TABLE [ IF EXISTS ] \fIname\fR + RENAME TO \fInew_name\fR +ALTER TABLE [ IF EXISTS ] \fIname\fR + SET SCHEMA \fInew_schema\fR + +where \fIaction\fR is one of: + + ADD [ COLUMN ] \fIcolumn_name\fR \fIdata_type\fR [ COLLATE \fIcollation\fR ] [ \fIcolumn_constraint\fR [ \&.\&.\&. ] ] + DROP [ COLUMN ] [ IF EXISTS ] \fIcolumn_name\fR [ RESTRICT | CASCADE ] + ALTER [ COLUMN ] \fIcolumn_name\fR [ SET DATA ] TYPE \fIdata_type\fR [ COLLATE \fIcollation\fR ] [ USING \fIexpression\fR ] + ALTER [ COLUMN ] \fIcolumn_name\fR SET DEFAULT \fIexpression\fR + ALTER [ COLUMN ] \fIcolumn_name\fR DROP DEFAULT + ALTER [ COLUMN ] \fIcolumn_name\fR { SET | DROP } NOT NULL + ALTER [ COLUMN ] \fIcolumn_name\fR SET STATISTICS \fIinteger\fR + ALTER [ COLUMN ] \fIcolumn_name\fR SET ( \fIattribute_option\fR = \fIvalue\fR [, \&.\&.\&. ] ) + ALTER [ COLUMN ] \fIcolumn_name\fR RESET ( \fIattribute_option\fR [, \&.\&.\&. ] ) + ALTER [ COLUMN ] \fIcolumn_name\fR SET STORAGE { PLAIN | EXTERNAL | EXTENDED | MAIN } + ADD \fItable_constraint\fR [ NOT VALID ] + ADD \fItable_constraint_using_index\fR + VALIDATE CONSTRAINT \fIconstraint_name\fR + DROP CONSTRAINT [ IF EXISTS ] \fIconstraint_name\fR [ RESTRICT | CASCADE ] + DISABLE TRIGGER [ \fItrigger_name\fR | ALL | USER ] + ENABLE TRIGGER [ \fItrigger_name\fR | ALL | USER ] + ENABLE REPLICA TRIGGER \fItrigger_name\fR + ENABLE ALWAYS TRIGGER \fItrigger_name\fR + DISABLE RULE \fIrewrite_rule_name\fR + ENABLE RULE \fIrewrite_rule_name\fR + ENABLE REPLICA RULE \fIrewrite_rule_name\fR + ENABLE ALWAYS RULE \fIrewrite_rule_name\fR + CLUSTER ON \fIindex_name\fR + SET WITHOUT CLUSTER + SET WITH OIDS + SET WITHOUT OIDS + SET ( \fIstorage_parameter\fR = \fIvalue\fR [, \&.\&.\&. ] ) + RESET ( \fIstorage_parameter\fR [, \&.\&.\&. ] ) + INHERIT \fIparent_table\fR + NO INHERIT \fIparent_table\fR + OF \fItype_name\fR + NOT OF + OWNER TO \fInew_owner\fR + SET TABLESPACE \fInew_tablespace\fR + +and \fItable_constraint_using_index\fR is: + + [ CONSTRAINT \fIconstraint_name\fR ] + { UNIQUE | PRIMARY KEY } USING INDEX \fIindex_name\fR + [ DEFERRABLE | NOT DEFERRABLE ] [ INITIALLY DEFERRED | INITIALLY IMMEDIATE ] +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER TABLE\fR +changes the definition of an existing table\&. There are several subforms: +.PP +ADD COLUMN +.RS 4 +This form adds a new column to the table, using the same syntax as +CREATE TABLE (\fBCREATE_TABLE\fR(7))\&. +.RE +.PP +DROP COLUMN [ IF EXISTS ] +.RS 4 +This form drops a column from a table\&. Indexes and table constraints involving the column will be automatically dropped as well\&. You will need to say +CASCADE +if anything outside the table depends on the column, for example, foreign key references or views\&. If +IF EXISTS +is specified and the column does not exist, no error is thrown\&. In this case a notice is issued instead\&. +.RE +.PP +IF EXISTS +.RS 4 +Do not throw an error if the table does not exist\&. A notice is issued in this case\&. +.RE +.PP +SET DATA TYPE +.RS 4 +This form changes the type of a column of a table\&. Indexes and simple table constraints involving the column will be automatically converted to use the new column type by reparsing the originally supplied expression\&. The optional +COLLATE +clause specifies a collation for the new column; if omitted, the collation is the default for the new column type\&. The optional +USING +clause specifies how to compute the new column value from the old; if omitted, the default conversion is the same as an assignment cast from old data type to new\&. A +USING +clause must be provided if there is no implicit or assignment cast from old to new type\&. +.RE +.PP +SET/DROP DEFAULT +.RS 4 +These forms set or remove the default value for a column\&. The default values only apply to subsequent +\fBINSERT\fR +commands; they do not cause rows already in the table to change\&. Defaults can also be created for views, in which case they are inserted into +\fBINSERT\fR +statements on the view before the view\*(Aqs +ON INSERT +rule is applied\&. +.RE +.PP +SET/DROP NOT NULL +.RS 4 +These forms change whether a column is marked to allow null values or to reject null values\&. You can only use +SET NOT NULL +when the column contains no null values\&. +.RE +.PP +SET STATISTICS +.RS 4 +This form sets the per\-column statistics\-gathering target for subsequent +\fBANALYZE\fR(7) +operations\&. The target can be set in the range 0 to 10000; alternatively, set it to \-1 to revert to using the system default statistics target (default_statistics_target)\&. For more information on the use of statistics by the +PostgreSQL +query planner, refer to +Section 14.2, \(lqStatistics Used by the Planner\(rq, in the documentation\&. +.RE +.PP +SET ( \fIattribute_option\fR = \fIvalue\fR [, \&.\&.\&. ] ), RESET ( \fIattribute_option\fR [, \&.\&.\&. ] ) +.RS 4 +This form sets or resets per\-attribute options\&. Currently, the only defined per\-attribute options are +n_distinct +and +n_distinct_inherited, which override the number\-of\-distinct\-values estimates made by subsequent +\fBANALYZE\fR(7) +operations\&. +n_distinct +affects the statistics for the table itself, while +n_distinct_inherited +affects the statistics gathered for the table plus its inheritance children\&. When set to a positive value, +\fBANALYZE\fR +will assume that the column contains exactly the specified number of distinct nonnull values\&. When set to a negative value, which must be greater than or equal to \-1, +\fBANALYZE\fR +will assume that the number of distinct nonnull values in the column is linear in the size of the table; the exact count is to be computed by multiplying the estimated table size by the absolute value of the given number\&. For example, a value of \-1 implies that all values in the column are distinct, while a value of \-0\&.5 implies that each value appears twice on the average\&. This can be useful when the size of the table changes over time, since the multiplication by the number of rows in the table is not performed until query planning time\&. Specify a value of 0 to revert to estimating the number of distinct values normally\&. For more information on the use of statistics by the +PostgreSQL +query planner, refer to +Section 14.2, \(lqStatistics Used by the Planner\(rq, in the documentation\&. +.RE +.PP +SET STORAGE +.RS 4 +.\" TOAST: per-column storage settings +This form sets the storage mode for a column\&. This controls whether this column is held inline or in a secondary +TOAST +table, and whether the data should be compressed or not\&. +PLAIN +must be used for fixed\-length values such as +integer +and is inline, uncompressed\&. +MAIN +is for inline, compressible data\&. +EXTERNAL +is for external, uncompressed data, and +EXTENDED +is for external, compressed data\&. +EXTENDED +is the default for most data types that support non\-PLAIN +storage\&. Use of +EXTERNAL +will make substring operations on very large +text +and +bytea +values run faster, at the penalty of increased storage space\&. Note that +SET STORAGE +doesn\*(Aqt itself change anything in the table, it just sets the strategy to be pursued during future table updates\&. See +Section 56.2, \(lqTOAST\(rq, in the documentation +for more information\&. +.RE +.PP +ADD \fItable_constraint\fR [ NOT VALID ] +.RS 4 +This form adds a new constraint to a table using the same syntax as +CREATE TABLE (\fBCREATE_TABLE\fR(7)), plus the option +NOT VALID, which is currently only allowed for foreign key and CHECK constraints\&. If the constraint is marked +NOT VALID, the potentially\-lengthy initial check to verify that all rows in the table satisfy the constraint is skipped\&. The constraint will still be enforced against subsequent inserts or updates (that is, they\*(Aqll fail unless there is a matching row in the referenced table, in the case of foreign keys; and they\*(Aqll fail unless the new row matches the specified check constraints)\&. But the database will not assume that the constraint holds for all rows in the table, until it is validated by using the +VALIDATE CONSTRAINT +option\&. +.RE +.PP +ADD \fItable_constraint_using_index\fR +.RS 4 +This form adds a new +PRIMARY KEY +or +UNIQUE +constraint to a table based on an existing unique index\&. All the columns of the index will be included in the constraint\&. +.sp +The index cannot have expression columns nor be a partial index\&. Also, it must be a b\-tree index with default sort ordering\&. These restrictions ensure that the index is equivalent to one that would be built by a regular +ADD PRIMARY KEY +or +ADD UNIQUE +command\&. +.sp +If +PRIMARY KEY +is specified, and the index\*(Aqs columns are not already marked +NOT NULL, then this command will attempt to do +ALTER COLUMN SET NOT NULL +against each such column\&. That requires a full table scan to verify the column(s) contain no nulls\&. In all other cases, this is a fast operation\&. +.sp +If a constraint name is provided then the index will be renamed to match the constraint name\&. Otherwise the constraint will be named the same as the index\&. +.sp +After this command is executed, the index is +\(lqowned\(rq +by the constraint, in the same way as if the index had been built by a regular +ADD PRIMARY KEY +or +ADD UNIQUE +command\&. In particular, dropping the constraint will make the index disappear too\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +Adding a constraint using an existing index can be helpful in situations where a new constraint needs to be added without blocking table updates for a long time\&. To do that, create the index using +\fBCREATE INDEX CONCURRENTLY\fR, and then install it as an official constraint using this syntax\&. See the example below\&. +.sp .5v +.RE +.RE +.PP +VALIDATE CONSTRAINT +.RS 4 +This form validates a foreign key or check constraint that was previously created as +NOT VALID, by scanning the table to ensure there are no rows for which the constraint is not satisfied\&. Nothing happens if the constraint is already marked valid\&. The value of separating validation from initial creation of the constraint is that validation requires a lesser lock on the table than constraint creation does\&. +.RE +.PP +DROP CONSTRAINT [ IF EXISTS ] +.RS 4 +This form drops the specified constraint on a table\&. If +IF EXISTS +is specified and the constraint does not exist, no error is thrown\&. In this case a notice is issued instead\&. +.RE +.PP +DISABLE/ENABLE [ REPLICA | ALWAYS ] TRIGGER +.RS 4 +These forms configure the firing of trigger(s) belonging to the table\&. A disabled trigger is still known to the system, but is not executed when its triggering event occurs\&. For a deferred trigger, the enable status is checked when the event occurs, not when the trigger function is actually executed\&. One can disable or enable a single trigger specified by name, or all triggers on the table, or only user triggers (this option excludes internally generated constraint triggers such as those that are used to implement foreign key constraints or deferrable uniqueness and exclusion constraints)\&. Disabling or enabling internally generated constraint triggers requires superuser privileges; it should be done with caution since of course the integrity of the constraint cannot be guaranteed if the triggers are not executed\&. The trigger firing mechanism is also affected by the configuration variable +session_replication_role\&. Simply enabled triggers will fire when the replication role is +\(lqorigin\(rq +(the default) or +\(lqlocal\(rq\&. Triggers configured as +ENABLE REPLICA +will only fire if the session is in +\(lqreplica\(rq +mode, and triggers configured as +ENABLE ALWAYS +will fire regardless of the current replication mode\&. +.RE +.PP +DISABLE/ENABLE [ REPLICA | ALWAYS ] RULE +.RS 4 +These forms configure the firing of rewrite rules belonging to the table\&. A disabled rule is still known to the system, but is not applied during query rewriting\&. The semantics are as for disabled/enabled triggers\&. This configuration is ignored for +ON SELECT +rules, which are always applied in order to keep views working even if the current session is in a non\-default replication role\&. +.RE +.PP +CLUSTER ON +.RS 4 +This form selects the default index for future +\fBCLUSTER\fR(7) +operations\&. It does not actually re\-cluster the table\&. +.RE +.PP +SET WITHOUT CLUSTER +.RS 4 +This form removes the most recently used +\fBCLUSTER\fR(7) +index specification from the table\&. This affects future cluster operations that don\*(Aqt specify an index\&. +.RE +.PP +SET WITH OIDS +.RS 4 +This form adds an +oid +system column to the table (see +Section 5.4, \(lqSystem Columns\(rq, in the documentation)\&. It does nothing if the table already has OIDs\&. +.sp +Note that this is not equivalent to +ADD COLUMN oid oid; that would add a normal column that happened to be named +oid, not a system column\&. +.RE +.PP +SET WITHOUT OIDS +.RS 4 +This form removes the +oid +system column from the table\&. This is exactly equivalent to +DROP COLUMN oid RESTRICT, except that it will not complain if there is already no +oid +column\&. +.RE +.PP +SET ( \fIstorage_parameter\fR = \fIvalue\fR [, \&.\&.\&. ] ) +.RS 4 +This form changes one or more storage parameters for the table\&. See +Storage Parameters +for details on the available parameters\&. Note that the table contents will not be modified immediately by this command; depending on the parameter you might need to rewrite the table to get the desired effects\&. That can be done with +VACUUM FULL, +\fBCLUSTER\fR(7) +or one of the forms of +\fBALTER TABLE\fR +that forces a table rewrite\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +While +\fBCREATE TABLE\fR +allows +OIDS +to be specified in the +WITH (\fIstorage_parameter\fR) +syntax, +\fBALTER TABLE\fR +does not treat +OIDS +as a storage parameter\&. Instead use the +SET WITH OIDS +and +SET WITHOUT OIDS +forms to change OID status\&. +.sp .5v +.RE +.RE +.PP +RESET ( \fIstorage_parameter\fR [, \&.\&.\&. ] ) +.RS 4 +This form resets one or more storage parameters to their defaults\&. As with +SET, a table rewrite might be needed to update the table entirely\&. +.RE +.PP +INHERIT \fIparent_table\fR +.RS 4 +This form adds the target table as a new child of the specified parent table\&. Subsequently, queries against the parent will include records of the target table\&. To be added as a child, the target table must already contain all the same columns as the parent (it could have additional columns, too)\&. The columns must have matching data types, and if they have +NOT NULL +constraints in the parent then they must also have +NOT NULL +constraints in the child\&. +.sp +There must also be matching child\-table constraints for all +CHECK +constraints of the parent, except those marked non\-inheritable (that is, created with +ALTER TABLE \&.\&.\&. ADD CONSTRAINT \&.\&.\&. NO INHERIT) in the parent, which are ignored; all child\-table constraints matched must not be marked non\-inheritable\&. Currently +UNIQUE, +PRIMARY KEY, and +FOREIGN KEY +constraints are not considered, but this might change in the future\&. +.RE +.PP +NO INHERIT \fIparent_table\fR +.RS 4 +This form removes the target table from the list of children of the specified parent table\&. Queries against the parent table will no longer include records drawn from the target table\&. +.RE +.PP +OF \fItype_name\fR +.RS 4 +This form links the table to a composite type as though +\fBCREATE TABLE OF\fR +had formed it\&. The table\*(Aqs list of column names and types must precisely match that of the composite type; the presence of an +oid +system column is permitted to differ\&. The table must not inherit from any other table\&. These restrictions ensure that +\fBCREATE TABLE OF\fR +would permit an equivalent table definition\&. +.RE +.PP +NOT OF +.RS 4 +This form dissociates a typed table from its type\&. +.RE +.PP +OWNER +.RS 4 +This form changes the owner of the table, sequence, or view to the specified user\&. +.RE +.PP +SET TABLESPACE +.RS 4 +This form changes the table\*(Aqs tablespace to the specified tablespace and moves the data file(s) associated with the table to the new tablespace\&. Indexes on the table, if any, are not moved; but they can be moved separately with additional +SET TABLESPACE +commands\&. See also +CREATE TABLESPACE (\fBCREATE_TABLESPACE\fR(7))\&. +.RE +.PP +RENAME +.RS 4 +The +RENAME +forms change the name of a table (or an index, sequence, or view), the name of an individual column in a table, or the name of a constraint of the table\&. There is no effect on the stored data\&. +.RE +.PP +SET SCHEMA +.RS 4 +This form moves the table into another schema\&. Associated indexes, constraints, and sequences owned by table columns are moved as well\&. +.RE +.PP +All the actions except +RENAME +and +SET SCHEMA +can be combined into a list of multiple alterations to apply in parallel\&. For example, it is possible to add several columns and/or alter the type of several columns in a single command\&. This is particularly useful with large tables, since only one pass over the table need be made\&. +.PP +You must own the table to use +\fBALTER TABLE\fR\&. To change the schema of a table, you must also have +CREATE +privilege on the new schema\&. To add the table as a new child of a parent table, you must own the parent table as well\&. To alter the owner, you must also be a direct or indirect member of the new owning role, and that role must have +CREATE +privilege on the table\*(Aqs schema\&. (These restrictions enforce that altering the owner doesn\*(Aqt do anything you couldn\*(Aqt do by dropping and recreating the table\&. However, a superuser can alter ownership of any table anyway\&.) To add a column or alter a column type or use the +OF +clause, you must also have +USAGE +privilege on the data type\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an existing table to alter\&. If +ONLY +is specified before the table name, only that table is altered\&. If +ONLY +is not specified, the table and all its descendant tables (if any) are altered\&. Optionally, +* +can be specified after the table name to explicitly indicate that descendant tables are included\&. +.RE +.PP +\fIcolumn_name\fR +.RS 4 +Name of a new or existing column\&. +.RE +.PP +\fInew_column_name\fR +.RS 4 +New name for an existing column\&. +.RE +.PP +\fInew_name\fR +.RS 4 +New name for the table\&. +.RE +.PP +\fItype\fR +.RS 4 +Data type of the new column, or new data type for an existing column\&. +.RE +.PP +\fItable_constraint\fR +.RS 4 +New table constraint for the table\&. +.RE +.PP +\fIconstraint_name\fR +.RS 4 +Name of an existing constraint to drop\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the dropped column or constraint (for example, views referencing the column)\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the column or constraint if there are any dependent objects\&. This is the default behavior\&. +.RE +.PP +\fItrigger_name\fR +.RS 4 +Name of a single trigger to disable or enable\&. +.RE +.PP +ALL +.RS 4 +Disable or enable all triggers belonging to the table\&. (This requires superuser privilege if any of the triggers are internally generated constraint triggers such as those that are used to implement foreign key constraints or deferrable uniqueness and exclusion constraints\&.) +.RE +.PP +USER +.RS 4 +Disable or enable all triggers belonging to the table except for internally generated constraint triggers such as those that are used to implement foreign key constraints or deferrable uniqueness and exclusion constraints\&. +.RE +.PP +\fIindex_name\fR +.RS 4 +The index name on which the table should be marked for clustering\&. +.RE +.PP +\fIstorage_parameter\fR +.RS 4 +The name of a table storage parameter\&. +.RE +.PP +\fIvalue\fR +.RS 4 +The new value for a table storage parameter\&. This might be a number or a word depending on the parameter\&. +.RE +.PP +\fIparent_table\fR +.RS 4 +A parent table to associate or de\-associate with this table\&. +.RE +.PP +\fInew_owner\fR +.RS 4 +The user name of the new owner of the table\&. +.RE +.PP +\fInew_tablespace\fR +.RS 4 +The name of the tablespace to which the table will be moved\&. +.RE +.PP +\fInew_schema\fR +.RS 4 +The name of the schema to which the table will be moved\&. +.RE +.SH "NOTES" +.PP +The key word +COLUMN +is noise and can be omitted\&. +.PP +When a column is added with +ADD COLUMN, all existing rows in the table are initialized with the column\*(Aqs default value (NULL if no +DEFAULT +clause is specified)\&. +.PP +Adding a column with a non\-null default or changing the type of an existing column will require the entire table and indexes to be rewritten\&. As an exception, if the +USING +clause does not change the column contents and the old type is either binary coercible to the new type or an unconstrained domain over the new type, a table rewrite is not needed, but any indexes on the affected columns must still be rebuilt\&. Adding or removing a system +oid +column also requires rewriting the entire table\&. Table and/or index rebuilds may take a significant amount of time for a large table; and will temporarily require as much as double the disk space\&. +.PP +Adding a +CHECK +or +NOT NULL +constraint requires scanning the table to verify that existing rows meet the constraint\&. +.PP +The main reason for providing the option to specify multiple changes in a single +\fBALTER TABLE\fR +is that multiple table scans or rewrites can thereby be combined into a single pass over the table\&. +.PP +The +DROP COLUMN +form does not physically remove the column, but simply makes it invisible to SQL operations\&. Subsequent insert and update operations in the table will store a null value for the column\&. Thus, dropping a column is quick but it will not immediately reduce the on\-disk size of your table, as the space occupied by the dropped column is not reclaimed\&. The space will be reclaimed over time as existing rows are updated\&. (These statements do not apply when dropping the system +oid +column; that is done with an immediate rewrite\&.) +.PP +To force an immediate rewrite of the table, you can use +VACUUM FULL, +\fBCLUSTER\fR(7) +or one of the forms of ALTER TABLE that forces a rewrite\&. This results in no semantically\-visible change in the table, but gets rid of no\-longer\-useful data\&. +.PP +The +USING +option of +SET DATA TYPE +can actually specify any expression involving the old values of the row; that is, it can refer to other columns as well as the one being converted\&. This allows very general conversions to be done with the +SET DATA TYPE +syntax\&. Because of this flexibility, the +USING +expression is not applied to the column\*(Aqs default value (if any); the result might not be a constant expression as required for a default\&. This means that when there is no implicit or assignment cast from old to new type, +SET DATA TYPE +might fail to convert the default even though a +USING +clause is supplied\&. In such cases, drop the default with +DROP DEFAULT, perform the +ALTER TYPE, and then use +SET DEFAULT +to add a suitable new default\&. Similar considerations apply to indexes and constraints involving the column\&. +.PP +If a table has any descendant tables, it is not permitted to add, rename, or change the type of a column, or rename an inherited constraint in the parent table without doing the same to the descendants\&. That is, +\fBALTER TABLE ONLY\fR +will be rejected\&. This ensures that the descendants always have columns matching the parent\&. +.PP +A recursive +DROP COLUMN +operation will remove a descendant table\*(Aqs column only if the descendant does not inherit that column from any other parents and never had an independent definition of the column\&. A nonrecursive +DROP COLUMN +(i\&.e\&., +\fBALTER TABLE ONLY \&.\&.\&. DROP COLUMN\fR) never removes any descendant columns, but instead marks them as independently defined rather than inherited\&. +.PP +The +TRIGGER, +CLUSTER, +OWNER, and +TABLESPACE +actions never recurse to descendant tables; that is, they always act as though +ONLY +were specified\&. Adding a constraint recurses only for +CHECK +constraints that are not marked +NO INHERIT\&. +.PP +Changing any part of a system catalog table is not permitted\&. +.PP +Refer to +CREATE TABLE (\fBCREATE_TABLE\fR(7)) +for a further description of valid parameters\&. +Chapter 5, Data Definition, in the documentation +has further information on inheritance\&. +.SH "EXAMPLES" +.PP +To add a column of type +varchar +to a table: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TABLE distributors ADD COLUMN address varchar(30); +.fi +.if n \{\ +.RE +.\} +.PP +To drop a column from a table: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TABLE distributors DROP COLUMN address RESTRICT; +.fi +.if n \{\ +.RE +.\} +.PP +To change the types of two existing columns in one operation: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TABLE distributors + ALTER COLUMN address TYPE varchar(80), + ALTER COLUMN name TYPE varchar(100); +.fi +.if n \{\ +.RE +.\} +.PP +To change an integer column containing UNIX timestamps to +timestamp with time zone +via a +USING +clause: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TABLE foo + ALTER COLUMN foo_timestamp SET DATA TYPE timestamp with time zone + USING + timestamp with time zone \*(Aqepoch\*(Aq + foo_timestamp * interval \*(Aq1 second\*(Aq; +.fi +.if n \{\ +.RE +.\} +.PP +The same, when the column has a default expression that won\*(Aqt automatically cast to the new data type: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TABLE foo + ALTER COLUMN foo_timestamp DROP DEFAULT, + ALTER COLUMN foo_timestamp TYPE timestamp with time zone + USING + timestamp with time zone \*(Aqepoch\*(Aq + foo_timestamp * interval \*(Aq1 second\*(Aq, + ALTER COLUMN foo_timestamp SET DEFAULT now(); +.fi +.if n \{\ +.RE +.\} +.PP +To rename an existing column: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TABLE distributors RENAME COLUMN address TO city; +.fi +.if n \{\ +.RE +.\} +.PP +To rename an existing table: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TABLE distributors RENAME TO suppliers; +.fi +.if n \{\ +.RE +.\} +.PP +To rename an existing constraint: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TABLE distributors RENAME CONSTRAINT zipchk TO zip_check; +.fi +.if n \{\ +.RE +.\} +.PP +To add a not\-null constraint to a column: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TABLE distributors ALTER COLUMN street SET NOT NULL; +.fi +.if n \{\ +.RE +.\} +.sp +To remove a not\-null constraint from a column: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TABLE distributors ALTER COLUMN street DROP NOT NULL; +.fi +.if n \{\ +.RE +.\} +.PP +To add a check constraint to a table and all its children: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TABLE distributors ADD CONSTRAINT zipchk CHECK (char_length(zipcode) = 5); +.fi +.if n \{\ +.RE +.\} +.PP +To add a check constraint only to a table and not to its children: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TABLE distributors ADD CONSTRAINT zipchk CHECK (char_length(zipcode) = 5) NO INHERIT; +.fi +.if n \{\ +.RE +.\} +.sp +(The check constraint will not be inherited by future children, either\&.) +.PP +To remove a check constraint from a table and all its children: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TABLE distributors DROP CONSTRAINT zipchk; +.fi +.if n \{\ +.RE +.\} +.PP +To remove a check constraint from one table only: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TABLE ONLY distributors DROP CONSTRAINT zipchk; +.fi +.if n \{\ +.RE +.\} +.sp +(The check constraint remains in place for any child tables\&.) +.PP +To add a foreign key constraint to a table: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TABLE distributors ADD CONSTRAINT distfk FOREIGN KEY (address) REFERENCES addresses (address); +.fi +.if n \{\ +.RE +.\} +.PP +To add a (multicolumn) unique constraint to a table: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TABLE distributors ADD CONSTRAINT dist_id_zipcode_key UNIQUE (dist_id, zipcode); +.fi +.if n \{\ +.RE +.\} +.PP +To add an automatically named primary key constraint to a table, noting that a table can only ever have one primary key: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TABLE distributors ADD PRIMARY KEY (dist_id); +.fi +.if n \{\ +.RE +.\} +.PP +To move a table to a different tablespace: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TABLE distributors SET TABLESPACE fasttablespace; +.fi +.if n \{\ +.RE +.\} +.PP +To move a table to a different schema: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TABLE myschema\&.distributors SET SCHEMA yourschema; +.fi +.if n \{\ +.RE +.\} +.PP +To recreate a primary key constraint, without blocking updates while the index is rebuilt: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE UNIQUE INDEX CONCURRENTLY dist_id_temp_idx ON distributors (dist_id); +ALTER TABLE distributors DROP CONSTRAINT distributors_pkey, + ADD CONSTRAINT distributors_pkey PRIMARY KEY USING INDEX dist_id_temp_idx; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +The forms +ADD +(without +USING INDEX), +DROP, +SET DEFAULT, and +SET DATA TYPE +(without +USING) conform with the SQL standard\&. The other forms are +PostgreSQL +extensions of the SQL standard\&. Also, the ability to specify more than one manipulation in a single +\fBALTER TABLE\fR +command is an extension\&. +.PP + +\fBALTER TABLE DROP COLUMN\fR +can be used to drop the only column of a table, leaving a zero\-column table\&. This is an extension of SQL, which disallows zero\-column tables\&. +.SH "SEE ALSO" +CREATE TABLE (\fBCREATE_TABLE\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_TABLESPACE.7 b/doc/src/sgml/man7/ALTER_TABLESPACE.7 new file mode 100644 index 000000000..97baebccb --- /dev/null +++ b/doc/src/sgml/man7/ALTER_TABLESPACE.7 @@ -0,0 +1,111 @@ +'\" t +.\" Title: ALTER TABLESPACE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER TABLESPACE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_TABLESPACE \- change the definition of a tablespace +.\" ALTER TABLESPACE +.SH "SYNOPSIS" +.sp +.nf +ALTER TABLESPACE \fIname\fR RENAME TO \fInew_name\fR +ALTER TABLESPACE \fIname\fR OWNER TO \fInew_owner\fR +ALTER TABLESPACE \fIname\fR SET ( \fItablespace_option\fR = \fIvalue\fR [, \&.\&.\&. ] ) +ALTER TABLESPACE \fIname\fR RESET ( \fItablespace_option\fR [, \&.\&.\&. ] ) +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER TABLESPACE\fR +changes the definition of a tablespace\&. +.PP +You must own the tablespace to use +\fBALTER TABLESPACE\fR\&. To alter the owner, you must also be a direct or indirect member of the new owning role\&. (Note that superusers have these privileges automatically\&.) +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name of an existing tablespace\&. +.RE +.PP +\fInew_name\fR +.RS 4 +The new name of the tablespace\&. The new name cannot begin with +pg_, as such names are reserved for system tablespaces\&. +.RE +.PP +\fInew_owner\fR +.RS 4 +The new owner of the tablespace\&. +.RE +.PP +\fItablespace_parameter\fR +.RS 4 +A tablespace parameter to be set or reset\&. Currently, the only available parameters are +\fIseq_page_cost\fR +and +\fIrandom_page_cost\fR\&. Setting either value for a particular tablespace will override the planner\*(Aqs usual estimate of the cost of reading pages from tables in that tablespace, as established by the configuration parameters of the same name (see +seq_page_cost, +random_page_cost)\&. This may be useful if one tablespace is located on a disk which is faster or slower than the remainder of the I/O subsystem\&. +.RE +.SH "EXAMPLES" +.PP +Rename tablespace +index_space +to +fast_raid: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TABLESPACE index_space RENAME TO fast_raid; +.fi +.if n \{\ +.RE +.\} +.PP +Change the owner of tablespace +index_space: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TABLESPACE index_space OWNER TO mary; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBALTER TABLESPACE\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +CREATE TABLESPACE (\fBCREATE_TABLESPACE\fR(7)), DROP TABLESPACE (\fBDROP_TABLESPACE\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_TEXT_SEARCH_CONFIGURATION.7 b/doc/src/sgml/man7/ALTER_TEXT_SEARCH_CONFIGURATION.7 new file mode 100644 index 000000000..350865b19 --- /dev/null +++ b/doc/src/sgml/man7/ALTER_TEXT_SEARCH_CONFIGURATION.7 @@ -0,0 +1,145 @@ +'\" t +.\" Title: ALTER TEXT SEARCH CONFIGURATION +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER TEXT SEARCH CONFIGURATION" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_TEXT_SEARCH_CONFIGURATION \- change the definition of a text search configuration +.\" ALTER TEXT SEARCH CONFIGURATION +.SH "SYNOPSIS" +.sp +.nf +ALTER TEXT SEARCH CONFIGURATION \fIname\fR + ADD MAPPING FOR \fItoken_type\fR [, \&.\&.\&. ] WITH \fIdictionary_name\fR [, \&.\&.\&. ] +ALTER TEXT SEARCH CONFIGURATION \fIname\fR + ALTER MAPPING FOR \fItoken_type\fR [, \&.\&.\&. ] WITH \fIdictionary_name\fR [, \&.\&.\&. ] +ALTER TEXT SEARCH CONFIGURATION \fIname\fR + ALTER MAPPING REPLACE \fIold_dictionary\fR WITH \fInew_dictionary\fR +ALTER TEXT SEARCH CONFIGURATION \fIname\fR + ALTER MAPPING FOR \fItoken_type\fR [, \&.\&.\&. ] REPLACE \fIold_dictionary\fR WITH \fInew_dictionary\fR +ALTER TEXT SEARCH CONFIGURATION \fIname\fR + DROP MAPPING [ IF EXISTS ] FOR \fItoken_type\fR [, \&.\&.\&. ] +ALTER TEXT SEARCH CONFIGURATION \fIname\fR RENAME TO \fInew_name\fR +ALTER TEXT SEARCH CONFIGURATION \fIname\fR OWNER TO \fInew_owner\fR +ALTER TEXT SEARCH CONFIGURATION \fIname\fR SET SCHEMA \fInew_schema\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER TEXT SEARCH CONFIGURATION\fR +changes the definition of a text search configuration\&. You can modify its mappings from token types to dictionaries, or change the configuration\*(Aqs name or owner\&. +.PP +You must be the owner of the configuration to use +\fBALTER TEXT SEARCH CONFIGURATION\fR\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an existing text search configuration\&. +.RE +.PP +\fItoken_type\fR +.RS 4 +The name of a token type that is emitted by the configuration\*(Aqs parser\&. +.RE +.PP +\fIdictionary_name\fR +.RS 4 +The name of a text search dictionary to be consulted for the specified token type(s)\&. If multiple dictionaries are listed, they are consulted in the specified order\&. +.RE +.PP +\fIold_dictionary\fR +.RS 4 +The name of a text search dictionary to be replaced in the mapping\&. +.RE +.PP +\fInew_dictionary\fR +.RS 4 +The name of a text search dictionary to be substituted for +\fIold_dictionary\fR\&. +.RE +.PP +\fInew_name\fR +.RS 4 +The new name of the text search configuration\&. +.RE +.PP +\fInew_owner\fR +.RS 4 +The new owner of the text search configuration\&. +.RE +.PP +\fInew_schema\fR +.RS 4 +The new schema for the text search configuration\&. +.RE +.PP +The +ADD MAPPING FOR +form installs a list of dictionaries to be consulted for the specified token type(s); it is an error if there is already a mapping for any of the token types\&. The +ALTER MAPPING FOR +form does the same, but first removing any existing mapping for those token types\&. The +ALTER MAPPING REPLACE +forms substitute +\fInew_dictionary\fR +for +\fIold_dictionary\fR +anywhere the latter appears\&. This is done for only the specified token types when +FOR +appears, or for all mappings of the configuration when it doesn\*(Aqt\&. The +DROP MAPPING +form removes all dictionaries for the specified token type(s), causing tokens of those types to be ignored by the text search configuration\&. It is an error if there is no mapping for the token types, unless +IF EXISTS +appears\&. +.SH "EXAMPLES" +.PP +The following example replaces the +english +dictionary with the +swedish +dictionary anywhere that +english +is used within +my_config\&. +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TEXT SEARCH CONFIGURATION my_config + ALTER MAPPING REPLACE english WITH swedish; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBALTER TEXT SEARCH CONFIGURATION\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +CREATE TEXT SEARCH CONFIGURATION (\fBCREATE_TEXT_SEARCH_CONFIGURATION\fR(7)), DROP TEXT SEARCH CONFIGURATION (\fBDROP_TEXT_SEARCH_CONFIGURATION\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_TEXT_SEARCH_DICTIONARY.7 b/doc/src/sgml/man7/ALTER_TEXT_SEARCH_DICTIONARY.7 new file mode 100644 index 000000000..5a9f12f26 --- /dev/null +++ b/doc/src/sgml/man7/ALTER_TEXT_SEARCH_DICTIONARY.7 @@ -0,0 +1,133 @@ +'\" t +.\" Title: ALTER TEXT SEARCH DICTIONARY +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER TEXT SEARCH DICTIONARY" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_TEXT_SEARCH_DICTIONARY \- change the definition of a text search dictionary +.\" ALTER TEXT SEARCH DICTIONARY +.SH "SYNOPSIS" +.sp +.nf +ALTER TEXT SEARCH DICTIONARY \fIname\fR ( + \fIoption\fR [ = \fIvalue\fR ] [, \&.\&.\&. ] +) +ALTER TEXT SEARCH DICTIONARY \fIname\fR RENAME TO \fInew_name\fR +ALTER TEXT SEARCH DICTIONARY \fIname\fR OWNER TO \fInew_owner\fR +ALTER TEXT SEARCH DICTIONARY \fIname\fR SET SCHEMA \fInew_schema\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER TEXT SEARCH DICTIONARY\fR +changes the definition of a text search dictionary\&. You can change the dictionary\*(Aqs template\-specific options, or change the dictionary\*(Aqs name or owner\&. +.PP +You must be the owner of the dictionary to use +\fBALTER TEXT SEARCH DICTIONARY\fR\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an existing text search dictionary\&. +.RE +.PP +\fIoption\fR +.RS 4 +The name of a template\-specific option to be set for this dictionary\&. +.RE +.PP +\fIvalue\fR +.RS 4 +The new value to use for a template\-specific option\&. If the equal sign and value are omitted, then any previous setting for the option is removed from the dictionary, allowing the default to be used\&. +.RE +.PP +\fInew_name\fR +.RS 4 +The new name of the text search dictionary\&. +.RE +.PP +\fInew_owner\fR +.RS 4 +The new owner of the text search dictionary\&. +.RE +.PP +\fInew_schema\fR +.RS 4 +The new schema for the text search dictionary\&. +.RE +.PP +Template\-specific options can appear in any order\&. +.SH "EXAMPLES" +.PP +The following example command changes the stopword list for a Snowball\-based dictionary\&. Other parameters remain unchanged\&. +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TEXT SEARCH DICTIONARY my_dict ( StopWords = newrussian ); +.fi +.if n \{\ +.RE +.\} +.PP +The following example command changes the language option to dutch, and removes the stopword option entirely\&. +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TEXT SEARCH DICTIONARY my_dict ( language = dutch, StopWords ); +.fi +.if n \{\ +.RE +.\} +.PP +The following example command +\(lqupdates\(rq +the dictionary\*(Aqs definition without actually changing anything\&. +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TEXT SEARCH DICTIONARY my_dict ( dummy ); +.fi +.if n \{\ +.RE +.\} +.sp +(The reason this works is that the option removal code doesn\*(Aqt complain if there is no such option\&.) This trick is useful when changing configuration files for the dictionary: the +\fBALTER\fR +will force existing database sessions to re\-read the configuration files, which otherwise they would never do if they had read them earlier\&. +.SH "COMPATIBILITY" +.PP +There is no +\fBALTER TEXT SEARCH DICTIONARY\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +CREATE TEXT SEARCH DICTIONARY (\fBCREATE_TEXT_SEARCH_DICTIONARY\fR(7)), DROP TEXT SEARCH DICTIONARY (\fBDROP_TEXT_SEARCH_DICTIONARY\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_TEXT_SEARCH_PARSER.7 b/doc/src/sgml/man7/ALTER_TEXT_SEARCH_PARSER.7 new file mode 100644 index 000000000..6b2baeb35 --- /dev/null +++ b/doc/src/sgml/man7/ALTER_TEXT_SEARCH_PARSER.7 @@ -0,0 +1,69 @@ +'\" t +.\" Title: ALTER TEXT SEARCH PARSER +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER TEXT SEARCH PARSER" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_TEXT_SEARCH_PARSER \- change the definition of a text search parser +.\" ALTER TEXT SEARCH PARSER +.SH "SYNOPSIS" +.sp +.nf +ALTER TEXT SEARCH PARSER \fIname\fR RENAME TO \fInew_name\fR +ALTER TEXT SEARCH PARSER \fIname\fR SET SCHEMA \fInew_schema\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER TEXT SEARCH PARSER\fR +changes the definition of a text search parser\&. Currently, the only supported functionality is to change the parser\*(Aqs name\&. +.PP +You must be a superuser to use +\fBALTER TEXT SEARCH PARSER\fR\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an existing text search parser\&. +.RE +.PP +\fInew_name\fR +.RS 4 +The new name of the text search parser\&. +.RE +.PP +\fInew_schema\fR +.RS 4 +The new schema for the text search parser\&. +.RE +.SH "COMPATIBILITY" +.PP +There is no +\fBALTER TEXT SEARCH PARSER\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +CREATE TEXT SEARCH PARSER (\fBCREATE_TEXT_SEARCH_PARSER\fR(7)), DROP TEXT SEARCH PARSER (\fBDROP_TEXT_SEARCH_PARSER\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_TEXT_SEARCH_TEMPLATE.7 b/doc/src/sgml/man7/ALTER_TEXT_SEARCH_TEMPLATE.7 new file mode 100644 index 000000000..1d3d397fb --- /dev/null +++ b/doc/src/sgml/man7/ALTER_TEXT_SEARCH_TEMPLATE.7 @@ -0,0 +1,69 @@ +'\" t +.\" Title: ALTER TEXT SEARCH TEMPLATE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER TEXT SEARCH TEMPLATE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_TEXT_SEARCH_TEMPLATE \- change the definition of a text search template +.\" ALTER TEXT SEARCH TEMPLATE +.SH "SYNOPSIS" +.sp +.nf +ALTER TEXT SEARCH TEMPLATE \fIname\fR RENAME TO \fInew_name\fR +ALTER TEXT SEARCH TEMPLATE \fIname\fR SET SCHEMA \fInew_schema\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER TEXT SEARCH TEMPLATE\fR +changes the definition of a text search template\&. Currently, the only supported functionality is to change the template\*(Aqs name\&. +.PP +You must be a superuser to use +\fBALTER TEXT SEARCH TEMPLATE\fR\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an existing text search template\&. +.RE +.PP +\fInew_name\fR +.RS 4 +The new name of the text search template\&. +.RE +.PP +\fInew_schema\fR +.RS 4 +The new schema for the text search template\&. +.RE +.SH "COMPATIBILITY" +.PP +There is no +\fBALTER TEXT SEARCH TEMPLATE\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +CREATE TEXT SEARCH TEMPLATE (\fBCREATE_TEXT_SEARCH_TEMPLATE\fR(7)), DROP TEXT SEARCH TEMPLATE (\fBDROP_TEXT_SEARCH_TEMPLATE\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_TRIGGER.7 b/doc/src/sgml/man7/ALTER_TRIGGER.7 new file mode 100644 index 000000000..7841e1167 --- /dev/null +++ b/doc/src/sgml/man7/ALTER_TRIGGER.7 @@ -0,0 +1,91 @@ +'\" t +.\" Title: ALTER TRIGGER +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER TRIGGER" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_TRIGGER \- change the definition of a trigger +.\" ALTER TRIGGER +.SH "SYNOPSIS" +.sp +.nf +ALTER TRIGGER \fIname\fR ON \fItable_name\fR RENAME TO \fInew_name\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER TRIGGER\fR +changes properties of an existing trigger\&. The +RENAME +clause changes the name of the given trigger without otherwise changing the trigger definition\&. +.PP +You must own the table on which the trigger acts to be allowed to change its properties\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name of an existing trigger to alter\&. +.RE +.PP +\fItable_name\fR +.RS 4 +The name of the table on which this trigger acts\&. +.RE +.PP +\fInew_name\fR +.RS 4 +The new name for the trigger\&. +.RE +.SH "NOTES" +.PP +The ability to temporarily enable or disable a trigger is provided by +ALTER TABLE (\fBALTER_TABLE\fR(7)), not by +\fBALTER TRIGGER\fR, because +\fBALTER TRIGGER\fR +has no convenient way to express the option of enabling or disabling all of a table\*(Aqs triggers at once\&. +.SH "EXAMPLES" +.PP +To rename an existing trigger: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TRIGGER emp_stamp ON emp RENAME TO emp_track_chgs; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBALTER TRIGGER\fR +is a +PostgreSQL +extension of the SQL standard\&. +.SH "SEE ALSO" +ALTER TABLE (\fBALTER_TABLE\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_TYPE.7 b/doc/src/sgml/man7/ALTER_TYPE.7 new file mode 100644 index 000000000..9aebe70f7 --- /dev/null +++ b/doc/src/sgml/man7/ALTER_TYPE.7 @@ -0,0 +1,251 @@ +'\" t +.\" Title: ALTER TYPE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER TYPE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_TYPE \- change the definition of a type +.\" ALTER TYPE +.SH "SYNOPSIS" +.sp +.nf +ALTER TYPE \fIname\fR \fIaction\fR [, \&.\&.\&. ] +ALTER TYPE \fIname\fR OWNER TO \fInew_owner\fR +ALTER TYPE \fIname\fR RENAME ATTRIBUTE \fIattribute_name\fR TO \fInew_attribute_name\fR +ALTER TYPE \fIname\fR RENAME TO \fInew_name\fR [ CASCADE | RESTRICT ] +ALTER TYPE \fIname\fR SET SCHEMA \fInew_schema\fR +ALTER TYPE \fIname\fR ADD VALUE \fInew_enum_value\fR [ { BEFORE | AFTER } \fIexisting_enum_value\fR ] + +where \fIaction\fR is one of: + + ADD ATTRIBUTE \fIattribute_name\fR \fIdata_type\fR [ COLLATE \fIcollation\fR ] [ CASCADE | RESTRICT ] + DROP ATTRIBUTE [ IF EXISTS ] \fIattribute_name\fR [ CASCADE | RESTRICT ] + ALTER ATTRIBUTE \fIattribute_name\fR [ SET DATA ] TYPE \fIdata_type\fR [ COLLATE \fIcollation\fR ] [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER TYPE\fR +changes the definition of an existing type\&. There are several subforms: +.PP +ADD ATTRIBUTE +.RS 4 +This form adds a new attribute to a composite type, using the same syntax as +CREATE TYPE (\fBCREATE_TYPE\fR(7))\&. +.RE +.PP +DROP ATTRIBUTE [ IF EXISTS ] +.RS 4 +This form drops an attribute from a composite type\&. If +IF EXISTS +is specified and the attribute does not exist, no error is thrown\&. In this case a notice is issued instead\&. +.RE +.PP +SET DATA TYPE +.RS 4 +This form changes the type of an attribute of a composite type\&. +.RE +.PP +OWNER +.RS 4 +This form changes the owner of the type\&. +.RE +.PP +RENAME +.RS 4 +This form changes the name of the type or the name of an individual attribute of a composite type\&. +.RE +.PP +SET SCHEMA +.RS 4 +This form moves the type into another schema\&. +.RE +.PP +ADD VALUE [ BEFORE | AFTER ] +.RS 4 +This form adds a new value to an enum type\&. If the new value\*(Aqs place in the enum\*(Aqs ordering is not specified using +BEFORE +or +AFTER, then the new item is placed at the end of the list of values\&. +.RE +.PP +CASCADE +.RS 4 +Automatically propagate the operation to typed tables of the type being altered, and their descendants\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse the operation if the type being altered is the type of a typed table\&. This is the default\&. +.RE +.PP +The +ADD ATTRIBUTE, +DROP ATTRIBUTE, and +ALTER ATTRIBUTE +actions can be combined into a list of multiple alterations to apply in parallel\&. For example, it is possible to add several attributes and/or alter the type of several attributes in a single command\&. +.PP +You must own the type to use +\fBALTER TYPE\fR\&. To change the schema of a type, you must also have +CREATE +privilege on the new schema\&. To alter the owner, you must also be a direct or indirect member of the new owning role, and that role must have +CREATE +privilege on the type\*(Aqs schema\&. (These restrictions enforce that altering the owner doesn\*(Aqt do anything you couldn\*(Aqt do by dropping and recreating the type\&. However, a superuser can alter ownership of any type anyway\&.) To add an attribute or alter an attribute type, you must also have +USAGE +privilege on the data type\&. +.SH "PARAMETERS" +.PP +.PP +\fIname\fR +.RS 4 +The name (possibly schema\-qualified) of an existing type to alter\&. +.RE +.PP +\fInew_name\fR +.RS 4 +The new name for the type\&. +.RE +.PP +\fInew_owner\fR +.RS 4 +The user name of the new owner of the type\&. +.RE +.PP +\fInew_schema\fR +.RS 4 +The new schema for the type\&. +.RE +.PP +\fIattribute_name\fR +.RS 4 +The name of the attribute to add, alter, or drop\&. +.RE +.PP +\fInew_attribute_name\fR +.RS 4 +The new name of the attribute to be renamed\&. +.RE +.PP +\fIdata_type\fR +.RS 4 +The data type of the attribute to add, or the new type of the attribute to alter\&. +.RE +.PP +\fInew_enum_value\fR +.RS 4 +The new value to be added to an enum type\*(Aqs list of values\&. Like all enum literals, it needs to be quoted\&. +.RE +.PP +\fIexisting_enum_value\fR +.RS 4 +The existing enum value that the new value should be added immediately before or after in the enum type\*(Aqs sort ordering\&. Like all enum literals, it needs to be quoted\&. +.RE +.SH "NOTES" +.PP + +\fBALTER TYPE \&.\&.\&. ADD VALUE\fR +(the form that adds a new value to an enum type) cannot be executed inside a transaction block\&. +.PP +Comparisons involving an added enum value will sometimes be slower than comparisons involving only original members of the enum type\&. This will usually only occur if +BEFORE +or +AFTER +is used to set the new value\*(Aqs sort position somewhere other than at the end of the list\&. However, sometimes it will happen even though the new value is added at the end (this occurs if the OID counter +\(lqwrapped around\(rq +since the original creation of the enum type)\&. The slowdown is usually insignificant; but if it matters, optimal performance can be regained by dropping and recreating the enum type, or by dumping and reloading the database\&. +.SH "EXAMPLES" +.PP +To rename a data type: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TYPE electronic_mail RENAME TO email; +.fi +.if n \{\ +.RE +.\} +.PP +To change the owner of the type +email +to +joe: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TYPE email OWNER TO joe; +.fi +.if n \{\ +.RE +.\} +.PP +To change the schema of the type +email +to +customers: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TYPE email SET SCHEMA customers; +.fi +.if n \{\ +.RE +.\} +.PP +To add a new attribute to a type: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TYPE compfoo ADD ATTRIBUTE f3 int; +.fi +.if n \{\ +.RE +.\} +.PP +To add a new value to an enum type in a particular sort position: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER TYPE colors ADD VALUE \*(Aqorange\*(Aq AFTER \*(Aqred\*(Aq; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +The variants to add and drop attributes are part of the SQL standard; the other variants are PostgreSQL extensions\&. +.SH "SEE ALSO" +CREATE TYPE (\fBCREATE_TYPE\fR(7)), DROP TYPE (\fBDROP_TYPE\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_USER.7 b/doc/src/sgml/man7/ALTER_USER.7 new file mode 100644 index 000000000..f783b9f8c --- /dev/null +++ b/doc/src/sgml/man7/ALTER_USER.7 @@ -0,0 +1,72 @@ +'\" t +.\" Title: ALTER USER +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER USER" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_USER \- change a database role +.\" ALTER USER +.SH "SYNOPSIS" +.sp +.nf +ALTER USER \fIname\fR [ [ WITH ] \fIoption\fR [ \&.\&.\&. ] ] + +where \fIoption\fR can be: + + SUPERUSER | NOSUPERUSER + | CREATEDB | NOCREATEDB + | CREATEROLE | NOCREATEROLE + | CREATEUSER | NOCREATEUSER + | INHERIT | NOINHERIT + | LOGIN | NOLOGIN + | REPLICATION | NOREPLICATION + | CONNECTION LIMIT \fIconnlimit\fR + | [ ENCRYPTED | UNENCRYPTED ] PASSWORD \*(Aq\fIpassword\fR\*(Aq + | VALID UNTIL \*(Aq\fItimestamp\fR\*(Aq + +ALTER USER \fIname\fR RENAME TO \fInew_name\fR + +ALTER USER \fIname\fR SET \fIconfiguration_parameter\fR { TO | = } { \fIvalue\fR | DEFAULT } +ALTER USER \fIname\fR SET \fIconfiguration_parameter\fR FROM CURRENT +ALTER USER \fIname\fR RESET \fIconfiguration_parameter\fR +ALTER USER \fIname\fR RESET ALL +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER USER\fR +is now an alias for +ALTER ROLE (\fBALTER_ROLE\fR(7))\&. +.SH "COMPATIBILITY" +.PP +The +\fBALTER USER\fR +statement is a +PostgreSQL +extension\&. The SQL standard leaves the definition of users to the implementation\&. +.SH "SEE ALSO" +ALTER ROLE (\fBALTER_ROLE\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_USER_MAPPING.7 b/doc/src/sgml/man7/ALTER_USER_MAPPING.7 new file mode 100644 index 000000000..cd8fbfd71 --- /dev/null +++ b/doc/src/sgml/man7/ALTER_USER_MAPPING.7 @@ -0,0 +1,106 @@ +'\" t +.\" Title: ALTER USER MAPPING +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER USER MAPPING" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_USER_MAPPING \- change the definition of a user mapping +.\" ALTER USER MAPPING +.SH "SYNOPSIS" +.sp +.nf +ALTER USER MAPPING FOR { \fIuser_name\fR | USER | CURRENT_USER | PUBLIC } + SERVER \fIserver_name\fR + OPTIONS ( [ ADD | SET | DROP ] \fIoption\fR [\*(Aq\fIvalue\fR\*(Aq] [, \&.\&.\&. ] ) +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER USER MAPPING\fR +changes the definition of a user mapping\&. +.PP +The owner of a foreign server can alter user mappings for that server for any user\&. Also, a user can alter a user mapping for his own user name if +USAGE +privilege on the server has been granted to the user\&. +.SH "PARAMETERS" +.PP +\fIuser_name\fR +.RS 4 +User name of the mapping\&. +CURRENT_USER +and +USER +match the name of the current user\&. +PUBLIC +is used to match all present and future user names in the system\&. +.RE +.PP +\fIserver_name\fR +.RS 4 +Server name of the user mapping\&. +.RE +.PP +OPTIONS ( [ ADD | SET | DROP ] \fIoption\fR [\*(Aq\fIvalue\fR\*(Aq] [, \&.\&.\&. ] ) +.RS 4 +Change options for the user mapping\&. The new options override any previously specified options\&. +ADD, +SET, and +DROP +specify the action to be performed\&. +ADD +is assumed if no operation is explicitly specified\&. Option names must be unique; options are also validated by the server\*(Aqs foreign\-data wrapper\&. +.RE +.SH "EXAMPLES" +.PP +Change the password for user mapping +bob, serverfoo: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER USER MAPPING FOR bob SERVER foo OPTIONS (user \*(Aqbob\*(Aq, password \*(Aqpublic\*(Aq); +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBALTER USER MAPPING\fR +conforms to ISO/IEC 9075\-9 (SQL/MED)\&. There is a subtle syntax issue: The standard omits the +FOR +key word\&. Since both +CREATE USER MAPPING +and +DROP USER MAPPING +use +FOR +in analogous positions, and IBM DB2 (being the other major SQL/MED implementation) also requires it for +ALTER USER MAPPING, PostgreSQL diverges from the standard here in the interest of consistency and interoperability\&. +.SH "SEE ALSO" +CREATE USER MAPPING (\fBCREATE_USER_MAPPING\fR(7)), DROP USER MAPPING (\fBDROP_USER_MAPPING\fR(7)) diff --git a/doc/src/sgml/man7/ALTER_VIEW.7 b/doc/src/sgml/man7/ALTER_VIEW.7 new file mode 100644 index 000000000..12f444167 --- /dev/null +++ b/doc/src/sgml/man7/ALTER_VIEW.7 @@ -0,0 +1,135 @@ +'\" t +.\" Title: ALTER VIEW +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ALTER VIEW" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ALTER_VIEW \- change the definition of a view +.\" ALTER VIEW +.SH "SYNOPSIS" +.sp +.nf +ALTER VIEW [ IF EXISTS ] \fIname\fR ALTER [ COLUMN ] \fIcolumn_name\fR SET DEFAULT \fIexpression\fR +ALTER VIEW [ IF EXISTS ] \fIname\fR ALTER [ COLUMN ] \fIcolumn_name\fR DROP DEFAULT +ALTER VIEW [ IF EXISTS ] \fIname\fR OWNER TO \fInew_owner\fR +ALTER VIEW [ IF EXISTS ] \fIname\fR RENAME TO \fInew_name\fR +ALTER VIEW [ IF EXISTS ] \fIname\fR SET SCHEMA \fInew_schema\fR +ALTER VIEW [ IF EXISTS ] \fIname\fR SET ( \fIview_option_name\fR [= \fIview_option_value\fR] [, \&.\&.\&. ] ) +ALTER VIEW [ IF EXISTS ] \fIname\fR RESET ( \fIview_option_name\fR [, \&.\&.\&. ] ) +.fi +.SH "DESCRIPTION" +.PP + +\fBALTER VIEW\fR +changes various auxiliary properties of a view\&. (If you want to modify the view\*(Aqs defining query, use +\fBCREATE OR REPLACE VIEW\fR\&.) +.PP +You must own the view to use +\fBALTER VIEW\fR\&. To change a view\*(Aqs schema, you must also have +CREATE +privilege on the new schema\&. To alter the owner, you must also be a direct or indirect member of the new owning role, and that role must have +CREATE +privilege on the view\*(Aqs schema\&. (These restrictions enforce that altering the owner doesn\*(Aqt do anything you couldn\*(Aqt do by dropping and recreating the view\&. However, a superuser can alter ownership of any view anyway\&.) +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an existing view\&. +.RE +.PP +IF EXISTS +.RS 4 +Do not throw an error if the view does not exist\&. A notice is issued in this case\&. +.RE +.PP +SET/DROP DEFAULT +.RS 4 +These forms set or remove the default value for a column\&. A default value associated with a view column is inserted into +\fBINSERT\fR +statements on the view before the view\*(Aqs +ON INSERT +rule is applied, if the +\fBINSERT\fR +does not specify a value for the column\&. +.RE +.PP +\fInew_owner\fR +.RS 4 +The user name of the new owner of the view\&. +.RE +.PP +\fInew_name\fR +.RS 4 +The new name for the view\&. +.RE +.PP +\fInew_schema\fR +.RS 4 +The new schema for the view\&. +.RE +.PP +\fIview_option_name\fR +.RS 4 +The name of a view option to be set or reset\&. +.RE +.PP +\fIview_option_name\fR +.RS 4 +The new value for a view option\&. +.RE +.SH "NOTES" +.PP +For historical reasons, +\fBALTER TABLE\fR +can be used with views too; but the only variants of +\fBALTER TABLE\fR +that are allowed with views are equivalent to the ones shown above\&. +.SH "EXAMPLES" +.PP +To rename the view +foo +to +bar: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ALTER VIEW foo RENAME TO bar; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBALTER VIEW\fR +is a +PostgreSQL +extension of the SQL standard\&. +.SH "SEE ALSO" +CREATE VIEW (\fBCREATE_VIEW\fR(7)), DROP VIEW (\fBDROP_VIEW\fR(7)) diff --git a/doc/src/sgml/man7/ANALYZE.7 b/doc/src/sgml/man7/ANALYZE.7 new file mode 100644 index 000000000..38133d110 --- /dev/null +++ b/doc/src/sgml/man7/ANALYZE.7 @@ -0,0 +1,151 @@ +'\" t +.\" Title: ANALYZE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ANALYZE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ANALYZE \- collect statistics about a database +.\" ANALYZE +.SH "SYNOPSIS" +.sp +.nf +ANALYZE [ VERBOSE ] [ \fItable_name\fR [ ( \fIcolumn_name\fR [, \&.\&.\&.] ) ] ] +.fi +.SH "DESCRIPTION" +.PP + +\fBANALYZE\fR +collects statistics about the contents of tables in the database, and stores the results in the +pg_statistic +system catalog\&. Subsequently, the query planner uses these statistics to help determine the most efficient execution plans for queries\&. +.PP +With no parameter, +\fBANALYZE\fR +examines every table in the current database\&. With a parameter, +\fBANALYZE\fR +examines only that table\&. It is further possible to give a list of column names, in which case only the statistics for those columns are collected\&. +.SH "PARAMETERS" +.PP +VERBOSE +.RS 4 +Enables display of progress messages\&. +.RE +.PP +\fItable_name\fR +.RS 4 +The name (possibly schema\-qualified) of a specific table to analyze\&. If omitted, all regular tables (but not foreign tables) in the current database are analyzed\&. +.RE +.PP +\fIcolumn_name\fR +.RS 4 +The name of a specific column to analyze\&. Defaults to all columns\&. +.RE +.SH "OUTPUTS" +.PP +When +VERBOSE +is specified, +\fBANALYZE\fR +emits progress messages to indicate which table is currently being processed\&. Various statistics about the tables are printed as well\&. +.SH "NOTES" +.PP +Foreign tables are analyzed only when explicitly selected\&. Not all foreign data wrappers support +\fBANALYZE\fR\&. If the table\*(Aqs wrapper does not support +\fBANALYZE\fR, the command prints a warning and does nothing\&. +.PP +In the default +PostgreSQL +configuration, the autovacuum daemon (see +Section 23.1.6, \(lqThe Autovacuum Daemon\(rq, in the documentation) takes care of automatic analyzing of tables when they are first loaded with data, and as they change throughout regular operation\&. When autovacuum is disabled, it is a good idea to run +\fBANALYZE\fR +periodically, or just after making major changes in the contents of a table\&. Accurate statistics will help the planner to choose the most appropriate query plan, and thereby improve the speed of query processing\&. A common strategy for read\-mostly databases is to run +\fBVACUUM\fR(7) +and +\fBANALYZE\fR +once a day during a low\-usage time of day\&. (This will not be sufficient if there is heavy update activity\&.) +.PP + +\fBANALYZE\fR +requires only a read lock on the target table, so it can run in parallel with other activity on the table\&. +.PP +The statistics collected by +\fBANALYZE\fR +usually include a list of some of the most common values in each column and a histogram showing the approximate data distribution in each column\&. One or both of these can be omitted if +\fBANALYZE\fR +deems them uninteresting (for example, in a unique\-key column, there are no common values) or if the column data type does not support the appropriate operators\&. There is more information about the statistics in +Chapter 23, Routine Database Maintenance Tasks, in the documentation\&. +.PP +For large tables, +\fBANALYZE\fR +takes a random sample of the table contents, rather than examining every row\&. This allows even very large tables to be analyzed in a small amount of time\&. Note, however, that the statistics are only approximate, and will change slightly each time +\fBANALYZE\fR +is run, even if the actual table contents did not change\&. This might result in small changes in the planner\*(Aqs estimated costs shown by +\fBEXPLAIN\fR(7)\&. In rare situations, this non\-determinism will cause the planner\*(Aqs choices of query plans to change after +\fBANALYZE\fR +is run\&. To avoid this, raise the amount of statistics collected by +\fBANALYZE\fR, as described below\&. +.PP +The extent of analysis can be controlled by adjusting the +default_statistics_target +configuration variable, or on a column\-by\-column basis by setting the per\-column statistics target with +\fBALTER TABLE \&.\&.\&. ALTER COLUMN \&.\&.\&. SET STATISTICS\fR +(see +ALTER TABLE (\fBALTER_TABLE\fR(7)))\&. The target value sets the maximum number of entries in the most\-common\-value list and the maximum number of bins in the histogram\&. The default target value is 100, but this can be adjusted up or down to trade off accuracy of planner estimates against the time taken for +\fBANALYZE\fR +and the amount of space occupied in +pg_statistic\&. In particular, setting the statistics target to zero disables collection of statistics for that column\&. It might be useful to do that for columns that are never used as part of the +WHERE, +GROUP BY, or +ORDER BY +clauses of queries, since the planner will have no use for statistics on such columns\&. +.PP +The largest statistics target among the columns being analyzed determines the number of table rows sampled to prepare the statistics\&. Increasing the target causes a proportional increase in the time and space needed to do +\fBANALYZE\fR\&. +.PP +One of the values estimated by +\fBANALYZE\fR +is the number of distinct values that appear in each column\&. Because only a subset of the rows are examined, this estimate can sometimes be quite inaccurate, even with the largest possible statistics target\&. If this inaccuracy leads to bad query plans, a more accurate value can be determined manually and then installed with +\fBALTER TABLE \&.\&.\&. ALTER COLUMN \&.\&.\&. SET (n_distinct = \&.\&.\&.)\fR +(see +ALTER TABLE (\fBALTER_TABLE\fR(7)))\&. +.PP +If the table being analyzed has one or more children, +\fBANALYZE\fR +will gather statistics twice: once on the rows of the parent table only, and a second time on the rows of the parent table with all of its children\&. This second set of statistics is needed when planning queries that traverse the entire inheritance tree\&. The autovacuum daemon, however, will only consider inserts or updates on the parent table itself when deciding whether to trigger an automatic analyze for that table\&. If that table is rarely inserted into or updated, the inheritance statistics will not be up to date unless you run +\fBANALYZE\fR +manually\&. +.PP +If the table being analyzed is completely empty, +\fBANALYZE\fR +will not record new statistics for that table\&. Any existing statistics will be retained\&. +.SH "COMPATIBILITY" +.PP +There is no +\fBANALYZE\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +\fBVACUUM\fR(7), \fBvacuumdb\fR(1), Section 18.4.4, \(lqCost-based Vacuum Delay\(rq, in the documentation, Section 23.1.6, \(lqThe Autovacuum Daemon\(rq, in the documentation diff --git a/doc/src/sgml/man7/BEGIN.7 b/doc/src/sgml/man7/BEGIN.7 new file mode 100644 index 000000000..cc3abe5f0 --- /dev/null +++ b/doc/src/sgml/man7/BEGIN.7 @@ -0,0 +1,130 @@ +'\" t +.\" Title: BEGIN +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "BEGIN" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +BEGIN \- start a transaction block +.\" BEGIN +.SH "SYNOPSIS" +.sp +.nf +BEGIN [ WORK | TRANSACTION ] [ \fItransaction_mode\fR [, \&.\&.\&.] ] + +where \fItransaction_mode\fR is one of: + + ISOLATION LEVEL { SERIALIZABLE | REPEATABLE READ | READ COMMITTED | READ UNCOMMITTED } + READ WRITE | READ ONLY + [ NOT ] DEFERRABLE +.fi +.SH "DESCRIPTION" +.PP + +\fBBEGIN\fR +initiates a transaction block, that is, all statements after a +\fBBEGIN\fR +command will be executed in a single transaction until an explicit +\fBCOMMIT\fR(7) +or +\fBROLLBACK\fR(7) +is given\&. By default (without +\fBBEGIN\fR), +PostgreSQL +executes transactions in +\(lqautocommit\(rq +mode, that is, each statement is executed in its own transaction and a commit is implicitly performed at the end of the statement (if execution was successful, otherwise a rollback is done)\&. +.PP +Statements are executed more quickly in a transaction block, because transaction start/commit requires significant CPU and disk activity\&. Execution of multiple statements inside a transaction is also useful to ensure consistency when making several related changes: other sessions will be unable to see the intermediate states wherein not all the related updates have been done\&. +.PP +If the isolation level, read/write mode, or deferrable mode is specified, the new transaction has those characteristics, as if +SET TRANSACTION (\fBSET_TRANSACTION\fR(7)) +was executed\&. +.SH "PARAMETERS" +.PP +WORK, TRANSACTION +.RS 4 +Optional key words\&. They have no effect\&. +.RE +.PP +Refer to +SET TRANSACTION (\fBSET_TRANSACTION\fR(7)) +for information on the meaning of the other parameters to this statement\&. +.SH "NOTES" +.PP + +START TRANSACTION (\fBSTART_TRANSACTION\fR(7)) +has the same functionality as +\fBBEGIN\fR\&. +.PP +Use +\fBCOMMIT\fR(7) +or +\fBROLLBACK\fR(7) +to terminate a transaction block\&. +.PP +Issuing +\fBBEGIN\fR +when already inside a transaction block will provoke a warning message\&. The state of the transaction is not affected\&. To nest transactions within a transaction block, use savepoints (see +\fBSAVEPOINT\fR(7))\&. +.PP +For reasons of backwards compatibility, the commas between successive +\fItransaction_modes\fR +can be omitted\&. +.SH "EXAMPLES" +.PP +To begin a transaction block: +.sp +.if n \{\ +.RS 4 +.\} +.nf +BEGIN; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBBEGIN\fR +is a +PostgreSQL +language extension\&. It is equivalent to the SQL\-standard command +START TRANSACTION (\fBSTART_TRANSACTION\fR(7)), whose reference page contains additional compatibility information\&. +.PP +The +DEFERRABLE +\fItransaction_mode\fR +is a +PostgreSQL +language extension\&. +.PP +Incidentally, the +BEGIN +key word is used for a different purpose in embedded SQL\&. You are advised to be careful about the transaction semantics when porting database applications\&. +.SH "SEE ALSO" +\fBCOMMIT\fR(7), \fBROLLBACK\fR(7), START TRANSACTION (\fBSTART_TRANSACTION\fR(7)), \fBSAVEPOINT\fR(7) diff --git a/doc/src/sgml/man7/CHECKPOINT.7 b/doc/src/sgml/man7/CHECKPOINT.7 new file mode 100644 index 000000000..2bbfa21f6 --- /dev/null +++ b/doc/src/sgml/man7/CHECKPOINT.7 @@ -0,0 +1,64 @@ +'\" t +.\" Title: CHECKPOINT +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CHECKPOINT" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CHECKPOINT \- force a transaction log checkpoint +.\" CHECKPOINT +.SH "SYNOPSIS" +.sp +.nf +CHECKPOINT +.fi +.SH "DESCRIPTION" +.PP +A checkpoint is a point in the transaction log sequence at which all data files have been updated to reflect the information in the log\&. All data files will be flushed to disk\&. Refer to +Section 29.4, \(lqWAL Configuration\(rq, in the documentation +for more details about what happens during a checkpoint\&. +.PP +The +\fBCHECKPOINT\fR +command forces an immediate checkpoint when the command is issued, without waiting for a regular checkpoint scheduled by the system (controlled by the settings in +Section 18.5.2, \(lqCheckpoints\(rq, in the documentation)\&. +\fBCHECKPOINT\fR +is not intended for use during normal operation\&. +.PP +If executed during recovery, the +\fBCHECKPOINT\fR +command will force a restartpoint (see +Section 29.4, \(lqWAL Configuration\(rq, in the documentation) rather than writing a new checkpoint\&. +.PP +Only superusers can call +\fBCHECKPOINT\fR\&. +.SH "COMPATIBILITY" +.PP +The +\fBCHECKPOINT\fR +command is a +PostgreSQL +language extension\&. diff --git a/doc/src/sgml/man7/CLOSE.7 b/doc/src/sgml/man7/CLOSE.7 new file mode 100644 index 000000000..0415d117f --- /dev/null +++ b/doc/src/sgml/man7/CLOSE.7 @@ -0,0 +1,104 @@ +'\" t +.\" Title: CLOSE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CLOSE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CLOSE \- close a cursor +.\" CLOSE +.\" cursor: CLOSE +.SH "SYNOPSIS" +.sp +.nf +CLOSE { \fIname\fR | ALL } +.fi +.SH "DESCRIPTION" +.PP + +\fBCLOSE\fR +frees the resources associated with an open cursor\&. After the cursor is closed, no subsequent operations are allowed on it\&. A cursor should be closed when it is no longer needed\&. +.PP +Every non\-holdable open cursor is implicitly closed when a transaction is terminated by +\fBCOMMIT\fR +or +\fBROLLBACK\fR\&. A holdable cursor is implicitly closed if the transaction that created it aborts via +\fBROLLBACK\fR\&. If the creating transaction successfully commits, the holdable cursor remains open until an explicit +\fBCLOSE\fR +is executed, or the client disconnects\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name of an open cursor to close\&. +.RE +.PP +ALL +.RS 4 +Close all open cursors\&. +.RE +.SH "NOTES" +.PP + +PostgreSQL +does not have an explicit +\fBOPEN\fR +cursor statement; a cursor is considered open when it is declared\&. Use the +\fBDECLARE\fR(7) +statement to declare a cursor\&. +.PP +You can see all available cursors by querying the +pg_cursors +system view\&. +.PP +If a cursor is closed after a savepoint which is later rolled back, the +\fBCLOSE\fR +is not rolled back; that is, the cursor remains closed\&. +.SH "EXAMPLES" +.PP +Close the cursor +liahona: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CLOSE liahona; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBCLOSE\fR +is fully conforming with the SQL standard\&. +\fBCLOSE ALL\fR +is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +\fBDECLARE\fR(7), \fBFETCH\fR(7), \fBMOVE\fR(7) diff --git a/doc/src/sgml/man7/CLUSTER.7 b/doc/src/sgml/man7/CLUSTER.7 new file mode 100644 index 000000000..1b1bea224 --- /dev/null +++ b/doc/src/sgml/man7/CLUSTER.7 @@ -0,0 +1,192 @@ +'\" t +.\" Title: CLUSTER +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CLUSTER" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CLUSTER \- cluster a table according to an index +.\" CLUSTER +.SH "SYNOPSIS" +.sp +.nf +CLUSTER [VERBOSE] \fItable_name\fR [ USING \fIindex_name\fR ] +CLUSTER [VERBOSE] +.fi +.SH "DESCRIPTION" +.PP + +\fBCLUSTER\fR +instructs +PostgreSQL +to cluster the table specified by +\fItable_name\fR +based on the index specified by +\fIindex_name\fR\&. The index must already have been defined on +\fItable_name\fR\&. +.PP +When a table is clustered, it is physically reordered based on the index information\&. Clustering is a one\-time operation: when the table is subsequently updated, the changes are not clustered\&. That is, no attempt is made to store new or updated rows according to their index order\&. (If one wishes, one can periodically recluster by issuing the command again\&. Also, setting the table\*(Aqs +FILLFACTOR +storage parameter to less than 100% can aid in preserving cluster ordering during updates, since updated rows are kept on the same page if enough space is available there\&.) +.PP +When a table is clustered, +PostgreSQL +remembers which index it was clustered by\&. The form +\fBCLUSTER \fR\fB\fItable_name\fR\fR +reclusters the table using the same index as before\&. You can also use the +CLUSTER +or +SET WITHOUT CLUSTER +forms of +ALTER TABLE (\fBALTER_TABLE\fR(7)) +to set the index to be used for future cluster operations, or to clear any previous setting\&. +.PP + +\fBCLUSTER\fR +without any parameter reclusters all the previously\-clustered tables in the current database that the calling user owns, or all such tables if called by a superuser\&. This form of +\fBCLUSTER\fR +cannot be executed inside a transaction block\&. +.PP +When a table is being clustered, an +ACCESS EXCLUSIVE +lock is acquired on it\&. This prevents any other database operations (both reads and writes) from operating on the table until the +\fBCLUSTER\fR +is finished\&. +.SH "PARAMETERS" +.PP +\fItable_name\fR +.RS 4 +The name (possibly schema\-qualified) of a table\&. +.RE +.PP +\fIindex_name\fR +.RS 4 +The name of an index\&. +.RE +.PP +VERBOSE +.RS 4 +Prints a progress report as each table is clustered\&. +.RE +.SH "NOTES" +.PP +In cases where you are accessing single rows randomly within a table, the actual order of the data in the table is unimportant\&. However, if you tend to access some data more than others, and there is an index that groups them together, you will benefit from using +\fBCLUSTER\fR\&. If you are requesting a range of indexed values from a table, or a single indexed value that has multiple rows that match, +\fBCLUSTER\fR +will help because once the index identifies the table page for the first row that matches, all other rows that match are probably already on the same table page, and so you save disk accesses and speed up the query\&. +.PP + +\fBCLUSTER\fR +can re\-sort the table using either an index scan on the specified index, or (if the index is a b\-tree) a sequential scan followed by sorting\&. It will attempt to choose the method that will be faster, based on planner cost parameters and available statistical information\&. +.PP +When an index scan is used, a temporary copy of the table is created that contains the table data in the index order\&. Temporary copies of each index on the table are created as well\&. Therefore, you need free space on disk at least equal to the sum of the table size and the index sizes\&. +.PP +When a sequential scan and sort is used, a temporary sort file is also created, so that the peak temporary space requirement is as much as double the table size, plus the index sizes\&. This method is often faster than the index scan method, but if the disk space requirement is intolerable, you can disable this choice by temporarily setting +enable_sort +to +off\&. +.PP +It is advisable to set +maintenance_work_mem +to a reasonably large value (but not more than the amount of RAM you can dedicate to the +\fBCLUSTER\fR +operation) before clustering\&. +.PP +Because the planner records statistics about the ordering of tables, it is advisable to run +\fBANALYZE\fR(7) +on the newly clustered table\&. Otherwise, the planner might make poor choices of query plans\&. +.PP +Because +\fBCLUSTER\fR +remembers which indexes are clustered, one can cluster the tables one wants clustered manually the first time, then set up a periodic maintenance script that executes +\fBCLUSTER\fR +without any parameters, so that the desired tables are periodically reclustered\&. +.SH "EXAMPLES" +.PP +Cluster the table +employees +on the basis of its index +employees_ind: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CLUSTER employees USING employees_ind; +.fi +.if n \{\ +.RE +.\} +.PP +Cluster the +employees +table using the same index that was used before: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CLUSTER employees; +.fi +.if n \{\ +.RE +.\} +.PP +Cluster all tables in the database that have previously been clustered: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CLUSTER; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBCLUSTER\fR +statement in the SQL standard\&. +.PP +The syntax +.sp +.if n \{\ +.RS 4 +.\} +.nf +CLUSTER \fIindex_name\fR ON \fItable_name\fR +.fi +.if n \{\ +.RE +.\} +.sp + +is also supported for compatibility with pre\-8\&.3 +PostgreSQL +versions\&. +.SH "SEE ALSO" +\fBclusterdb\fR(1) diff --git a/doc/src/sgml/man7/COMMENT.7 b/doc/src/sgml/man7/COMMENT.7 new file mode 100644 index 000000000..90eb7b808 --- /dev/null +++ b/doc/src/sgml/man7/COMMENT.7 @@ -0,0 +1,257 @@ +'\" t +.\" Title: COMMENT +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "COMMENT" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +COMMENT \- define or change the comment of an object +.\" COMMENT +.SH "SYNOPSIS" +.sp +.nf +COMMENT ON +{ + AGGREGATE \fIagg_name\fR (\fIagg_type\fR [, \&.\&.\&.] ) | + CAST (\fIsource_type\fR AS \fItarget_type\fR) | + COLLATION \fIobject_name\fR | + COLUMN \fIrelation_name\fR\&.\fIcolumn_name\fR | + CONSTRAINT \fIconstraint_name\fR ON \fItable_name\fR | + CONVERSION \fIobject_name\fR | + DATABASE \fIobject_name\fR | + DOMAIN \fIobject_name\fR | + EXTENSION \fIobject_name\fR | + FOREIGN DATA WRAPPER \fIobject_name\fR | + FOREIGN TABLE \fIobject_name\fR | + FUNCTION \fIfunction_name\fR ( [ [ \fIargmode\fR ] [ \fIargname\fR ] \fIargtype\fR [, \&.\&.\&.] ] ) | + INDEX \fIobject_name\fR | + LARGE OBJECT \fIlarge_object_oid\fR | + OPERATOR \fIoperator_name\fR (\fIleft_type\fR, \fIright_type\fR) | + OPERATOR CLASS \fIobject_name\fR USING \fIindex_method\fR | + OPERATOR FAMILY \fIobject_name\fR USING \fIindex_method\fR | + [ PROCEDURAL ] LANGUAGE \fIobject_name\fR | + ROLE \fIobject_name\fR | + RULE \fIrule_name\fR ON \fItable_name\fR | + SCHEMA \fIobject_name\fR | + SEQUENCE \fIobject_name\fR | + SERVER \fIobject_name\fR | + TABLE \fIobject_name\fR | + TABLESPACE \fIobject_name\fR | + TEXT SEARCH CONFIGURATION \fIobject_name\fR | + TEXT SEARCH DICTIONARY \fIobject_name\fR | + TEXT SEARCH PARSER \fIobject_name\fR | + TEXT SEARCH TEMPLATE \fIobject_name\fR | + TRIGGER \fItrigger_name\fR ON \fItable_name\fR | + TYPE \fIobject_name\fR | + VIEW \fIobject_name\fR +} IS \*(Aq\fItext\fR\*(Aq +.fi +.SH "DESCRIPTION" +.PP + +\fBCOMMENT\fR +stores a comment about a database object\&. +.PP +Only one comment string is stored for each object, so to modify a comment, issue a new +\fBCOMMENT\fR +command for the same object\&. To remove a comment, write +NULL +in place of the text string\&. Comments are automatically dropped when their object is dropped\&. +.PP +For most kinds of object, only the object\*(Aqs owner can set the comment\&. Roles don\*(Aqt have owners, so the rule for +COMMENT ON ROLE +is that you must be superuser to comment on a superuser role, or have the +CREATEROLE +privilege to comment on non\-superuser roles\&. Of course, a superuser can comment on anything\&. +.PP +Comments can be viewed using +psql\*(Aqs +\fB\ed\fR +family of commands\&. Other user interfaces to retrieve comments can be built atop the same built\-in functions that +psql +uses, namely +\fBobj_description\fR, +\fBcol_description\fR, and +\fBshobj_description\fR +(see +Table\ \&9.54, \(lqComment Information Functions\(rq)\&. +.SH "PARAMETERS" +.PP +\fIobject_name\fR, \fIrelation_name\fR\&.\fIcolumn_name\fR, \fIagg_name\fR, \fIconstraint_name\fR, \fIfunction_name\fR, \fIoperator_name\fR, \fIrule_name\fR, \fItrigger_name\fR +.RS 4 +The name of the object to be commented\&. Names of tables, aggregates, collations, conversions, domains, foreign tables, functions, indexes, operators, operator classes, operator families, sequences, text search objects, types, and views can be schema\-qualified\&. When commenting on a column, +\fIrelation_name\fR +must refer to a table, view, composite type, or foreign table\&. +.RE +.PP +\fIagg_type\fR +.RS 4 +An input data type on which the aggregate function operates\&. To reference a zero\-argument aggregate function, write +* +in place of the list of input data types\&. +.RE +.PP +\fIsource_type\fR +.RS 4 +The name of the source data type of the cast\&. +.RE +.PP +\fItarget_type\fR +.RS 4 +The name of the target data type of the cast\&. +.RE +.PP +\fIargmode\fR +.RS 4 +The mode of a function argument: +IN, +OUT, +INOUT, or +VARIADIC\&. If omitted, the default is +IN\&. Note that +\fBCOMMENT ON FUNCTION\fR +does not actually pay any attention to +OUT +arguments, since only the input arguments are needed to determine the function\*(Aqs identity\&. So it is sufficient to list the +IN, +INOUT, and +VARIADIC +arguments\&. +.RE +.PP +\fIargname\fR +.RS 4 +The name of a function argument\&. Note that +\fBCOMMENT ON FUNCTION\fR +does not actually pay any attention to argument names, since only the argument data types are needed to determine the function\*(Aqs identity\&. +.RE +.PP +\fIargtype\fR +.RS 4 +The data type(s) of the function\*(Aqs arguments (optionally schema\-qualified), if any\&. +.RE +.PP +\fIlarge_object_oid\fR +.RS 4 +The OID of the large object\&. +.RE +.PP +\fIleft_type\fR, \fIright_type\fR +.RS 4 +The data type(s) of the operator\*(Aqs arguments (optionally schema\-qualified)\&. Write +NONE +for the missing argument of a prefix or postfix operator\&. +.RE +.PP +PROCEDURAL +.RS 4 +This is a noise word\&. +.RE +.PP +\fItext\fR +.RS 4 +The new comment, written as a string literal; or +NULL +to drop the comment\&. +.RE +.SH "NOTES" +.PP +There is presently no security mechanism for viewing comments: any user connected to a database can see all the comments for objects in that database\&. For shared objects such as databases, roles, and tablespaces, comments are stored globally so any user connected to any database in the cluster can see all the comments for shared objects\&. Therefore, don\*(Aqt put security\-critical information in comments\&. +.SH "EXAMPLES" +.PP +Attach a comment to the table +mytable: +.sp +.if n \{\ +.RS 4 +.\} +.nf +COMMENT ON TABLE mytable IS \*(AqThis is my table\&.\*(Aq; +.fi +.if n \{\ +.RE +.\} +.sp +Remove it again: +.sp +.if n \{\ +.RS 4 +.\} +.nf +COMMENT ON TABLE mytable IS NULL; +.fi +.if n \{\ +.RE +.\} +.PP +Some more examples: +.sp +.if n \{\ +.RS 4 +.\} +.nf +COMMENT ON AGGREGATE my_aggregate (double precision) IS \*(AqComputes sample variance\*(Aq; +COMMENT ON CAST (text AS int4) IS \*(AqAllow casts from text to int4\*(Aq; +COMMENT ON COLLATION "fr_CA" IS \*(AqCanadian French\*(Aq; +COMMENT ON COLUMN my_table\&.my_column IS \*(AqEmployee ID number\*(Aq; +COMMENT ON CONVERSION my_conv IS \*(AqConversion to UTF8\*(Aq; +COMMENT ON CONSTRAINT bar_col_cons ON bar IS \*(AqConstrains column col\*(Aq; +COMMENT ON DATABASE my_database IS \*(AqDevelopment Database\*(Aq; +COMMENT ON DOMAIN my_domain IS \*(AqEmail Address Domain\*(Aq; +COMMENT ON EXTENSION hstore IS \*(Aqimplements the hstore data type\*(Aq; +COMMENT ON FOREIGN DATA WRAPPER mywrapper IS \*(Aqmy foreign data wrapper\*(Aq; +COMMENT ON FOREIGN TABLE my_foreign_table IS \*(AqEmployee Information in other database\*(Aq; +COMMENT ON FUNCTION my_function (timestamp) IS \*(AqReturns Roman Numeral\*(Aq; +COMMENT ON INDEX my_index IS \*(AqEnforces uniqueness on employee ID\*(Aq; +COMMENT ON LANGUAGE plpython IS \*(AqPython support for stored procedures\*(Aq; +COMMENT ON LARGE OBJECT 346344 IS \*(AqPlanning document\*(Aq; +COMMENT ON OPERATOR ^ (text, text) IS \*(AqPerforms intersection of two texts\*(Aq; +COMMENT ON OPERATOR \- (NONE, integer) IS \*(AqUnary minus\*(Aq; +COMMENT ON OPERATOR CLASS int4ops USING btree IS \*(Aq4 byte integer operators for btrees\*(Aq; +COMMENT ON OPERATOR FAMILY integer_ops USING btree IS \*(Aqall integer operators for btrees\*(Aq; +COMMENT ON ROLE my_role IS \*(AqAdministration group for finance tables\*(Aq; +COMMENT ON RULE my_rule ON my_table IS \*(AqLogs updates of employee records\*(Aq; +COMMENT ON SCHEMA my_schema IS \*(AqDepartmental data\*(Aq; +COMMENT ON SEQUENCE my_sequence IS \*(AqUsed to generate primary keys\*(Aq; +COMMENT ON SERVER myserver IS \*(Aqmy foreign server\*(Aq; +COMMENT ON TABLE my_schema\&.my_table IS \*(AqEmployee Information\*(Aq; +COMMENT ON TABLESPACE my_tablespace IS \*(AqTablespace for indexes\*(Aq; +COMMENT ON TEXT SEARCH CONFIGURATION my_config IS \*(AqSpecial word filtering\*(Aq; +COMMENT ON TEXT SEARCH DICTIONARY swedish IS \*(AqSnowball stemmer for swedish language\*(Aq; +COMMENT ON TEXT SEARCH PARSER my_parser IS \*(AqSplits text into words\*(Aq; +COMMENT ON TEXT SEARCH TEMPLATE snowball IS \*(AqSnowball stemmer\*(Aq; +COMMENT ON TRIGGER my_trigger ON my_table IS \*(AqUsed for RI\*(Aq; +COMMENT ON TYPE complex IS \*(AqComplex number data type\*(Aq; +COMMENT ON VIEW my_view IS \*(AqView of departmental costs\*(Aq; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBCOMMENT\fR +command in the SQL standard\&. diff --git a/doc/src/sgml/man7/COMMIT.7 b/doc/src/sgml/man7/COMMIT.7 new file mode 100644 index 000000000..32e5d7517 --- /dev/null +++ b/doc/src/sgml/man7/COMMIT.7 @@ -0,0 +1,78 @@ +'\" t +.\" Title: COMMIT +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "COMMIT" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +COMMIT \- commit the current transaction +.\" COMMIT +.SH "SYNOPSIS" +.sp +.nf +COMMIT [ WORK | TRANSACTION ] +.fi +.SH "DESCRIPTION" +.PP + +\fBCOMMIT\fR +commits the current transaction\&. All changes made by the transaction become visible to others and are guaranteed to be durable if a crash occurs\&. +.SH "PARAMETERS" +.PP +WORK, TRANSACTION +.RS 4 +Optional key words\&. They have no effect\&. +.RE +.SH "NOTES" +.PP +Use +\fBROLLBACK\fR(7) +to abort a transaction\&. +.PP +Issuing +\fBCOMMIT\fR +when not inside a transaction does no harm, but it will provoke a warning message\&. +.SH "EXAMPLES" +.PP +To commit the current transaction and make all changes permanent: +.sp +.if n \{\ +.RS 4 +.\} +.nf +COMMIT; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +The SQL standard only specifies the two forms +COMMIT +and +COMMIT WORK\&. Otherwise, this command is fully conforming\&. +.SH "SEE ALSO" +\fBBEGIN\fR(7), \fBROLLBACK\fR(7) diff --git a/doc/src/sgml/man7/COMMIT_PREPARED.7 b/doc/src/sgml/man7/COMMIT_PREPARED.7 new file mode 100644 index 000000000..b6dc49d2e --- /dev/null +++ b/doc/src/sgml/man7/COMMIT_PREPARED.7 @@ -0,0 +1,80 @@ +'\" t +.\" Title: COMMIT PREPARED +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "COMMIT PREPARED" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +COMMIT_PREPARED \- commit a transaction that was earlier prepared for two\-phase commit +.\" COMMIT PREPARED +.SH "SYNOPSIS" +.sp +.nf +COMMIT PREPARED \fItransaction_id\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBCOMMIT PREPARED\fR +commits a transaction that is in prepared state\&. +.SH "PARAMETERS" +.PP +\fItransaction_id\fR +.RS 4 +The transaction identifier of the transaction that is to be committed\&. +.RE +.SH "NOTES" +.PP +To commit a prepared transaction, you must be either the same user that executed the transaction originally, or a superuser\&. But you do not have to be in the same session that executed the transaction\&. +.PP +This command cannot be executed inside a transaction block\&. The prepared transaction is committed immediately\&. +.PP +All currently available prepared transactions are listed in the +pg_prepared_xacts +system view\&. +.SH "EXAMPLES" +.PP +Commit the transaction identified by the transaction identifier +foobar: +.sp +.if n \{\ +.RS 4 +.\} +.nf +COMMIT PREPARED \*(Aqfoobar\*(Aq; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBCOMMIT PREPARED\fR +is a +PostgreSQL +extension\&. It is intended for use by external transaction management systems, some of which are covered by standards (such as X/Open XA), but the SQL side of those systems is not standardized\&. +.SH "SEE ALSO" +PREPARE TRANSACTION (\fBPREPARE_TRANSACTION\fR(7)), ROLLBACK PREPARED (\fBROLLBACK_PREPARED\fR(7)) diff --git a/doc/src/sgml/man7/COPY.7 b/doc/src/sgml/man7/COPY.7 new file mode 100644 index 000000000..38018e0c0 --- /dev/null +++ b/doc/src/sgml/man7/COPY.7 @@ -0,0 +1,857 @@ +'\" t +.\" Title: COPY +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "COPY" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +COPY \- copy data between a file and a table +.\" COPY +.SH "SYNOPSIS" +.sp +.nf +COPY \fItable_name\fR [ ( \fIcolumn_name\fR [, \&.\&.\&.] ) ] + FROM { \*(Aq\fIfilename\fR\*(Aq | STDIN } + [ [ WITH ] ( \fIoption\fR [, \&.\&.\&.] ) ] + +COPY { \fItable_name\fR [ ( \fIcolumn_name\fR [, \&.\&.\&.] ) ] | ( \fIquery\fR ) } + TO { \*(Aq\fIfilename\fR\*(Aq | STDOUT } + [ [ WITH ] ( \fIoption\fR [, \&.\&.\&.] ) ] + +where \fIoption\fR can be one of: + + FORMAT \fIformat_name\fR + OIDS [ \fIboolean\fR ] + DELIMITER \*(Aq\fIdelimiter_character\fR\*(Aq + NULL \*(Aq\fInull_string\fR\*(Aq + HEADER [ \fIboolean\fR ] + QUOTE \*(Aq\fIquote_character\fR\*(Aq + ESCAPE \*(Aq\fIescape_character\fR\*(Aq + FORCE_QUOTE { ( \fIcolumn_name\fR [, \&.\&.\&.] ) | * } + FORCE_NOT_NULL ( \fIcolumn_name\fR [, \&.\&.\&.] ) | + ENCODING \*(Aq\fIencoding_name\fR\*(Aq +.fi +.SH "DESCRIPTION" +.PP + +\fBCOPY\fR +moves data between +PostgreSQL +tables and standard file\-system files\&. +\fBCOPY TO\fR +copies the contents of a table +\fIto\fR +a file, while +\fBCOPY FROM\fR +copies data +\fIfrom\fR +a file to a table (appending the data to whatever is in the table already)\&. +\fBCOPY TO\fR +can also copy the results of a +\fBSELECT\fR +query\&. +.PP +If a list of columns is specified, +\fBCOPY\fR +will only copy the data in the specified columns to or from the file\&. If there are any columns in the table that are not in the column list, +\fBCOPY FROM\fR +will insert the default values for those columns\&. +.PP + +\fBCOPY\fR +with a file name instructs the +PostgreSQL +server to directly read from or write to a file\&. The file must be accessible to the server and the name must be specified from the viewpoint of the server\&. When +STDIN +or +STDOUT +is specified, data is transmitted via the connection between the client and the server\&. +.SH "PARAMETERS" +.PP +\fItable_name\fR +.RS 4 +The name (optionally schema\-qualified) of an existing table\&. +.RE +.PP +\fIcolumn_name\fR +.RS 4 +An optional list of columns to be copied\&. If no column list is specified, all columns of the table will be copied\&. +.RE +.PP +\fIquery\fR +.RS 4 +A +\fBSELECT\fR(7) +or +\fBVALUES\fR(7) +command whose results are to be copied\&. Note that parentheses are required around the query\&. +.RE +.PP +\fIfilename\fR +.RS 4 +The absolute path name of the input or output file\&. Windows users might need to use an +E\*(Aq\*(Aq +string and double any backslashes used in the path name\&. +.RE +.PP +STDIN +.RS 4 +Specifies that input comes from the client application\&. +.RE +.PP +STDOUT +.RS 4 +Specifies that output goes to the client application\&. +.RE +.PP +\fIboolean\fR +.RS 4 +Specifies whether the selected option should be turned on or off\&. You can write +TRUE, +ON, or +1 +to enable the option, and +FALSE, +OFF, or +0 +to disable it\&. The +\fIboolean\fR +value can also be omitted, in which case +TRUE +is assumed\&. +.RE +.PP +FORMAT +.RS 4 +Selects the data format to be read or written: +text, +csv +(Comma Separated Values), or +binary\&. The default is +text\&. +.RE +.PP +OIDS +.RS 4 +Specifies copying the OID for each row\&. (An error is raised if +OIDS +is specified for a table that does not have OIDs, or in the case of copying a +\fIquery\fR\&.) +.RE +.PP +DELIMITER +.RS 4 +Specifies the character that separates columns within each row (line) of the file\&. The default is a tab character in text format, a comma in +CSV +format\&. This must be a single one\-byte character\&. This option is not allowed when using +binary +format\&. +.RE +.PP +NULL +.RS 4 +Specifies the string that represents a null value\&. The default is +\eN +(backslash\-N) in text format, and an unquoted empty string in +CSV +format\&. You might prefer an empty string even in text format for cases where you don\*(Aqt want to distinguish nulls from empty strings\&. This option is not allowed when using +binary +format\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +When using +\fBCOPY FROM\fR, any data item that matches this string will be stored as a null value, so you should make sure that you use the same string as you used with +\fBCOPY TO\fR\&. +.sp .5v +.RE +.RE +.PP +HEADER +.RS 4 +Specifies that the file contains a header line with the names of each column in the file\&. On output, the first line contains the column names from the table, and on input, the first line is ignored\&. This option is allowed only when using +CSV +format\&. +.RE +.PP +QUOTE +.RS 4 +Specifies the quoting character to be used when a data value is quoted\&. The default is double\-quote\&. This must be a single one\-byte character\&. This option is allowed only when using +CSV +format\&. +.RE +.PP +ESCAPE +.RS 4 +Specifies the character that should appear before a data character that matches the +QUOTE +value\&. The default is the same as the +QUOTE +value (so that the quoting character is doubled if it appears in the data)\&. This must be a single one\-byte character\&. This option is allowed only when using +CSV +format\&. +.RE +.PP +FORCE_QUOTE +.RS 4 +Forces quoting to be used for all non\-NULL +values in each specified column\&. +NULL +output is never quoted\&. If +* +is specified, non\-NULL +values will be quoted in all columns\&. This option is allowed only in +\fBCOPY TO\fR, and only when using +CSV +format\&. +.RE +.PP +FORCE_NOT_NULL +.RS 4 +Do not match the specified columns\*(Aq values against the null string\&. In the default case where the null string is empty, this means that empty values will be read as zero\-length strings rather than nulls, even when they are not quoted\&. This option is allowed only in +\fBCOPY FROM\fR, and only when using +CSV +format\&. +.RE +.PP +ENCODING +.RS 4 +Specifies that the file is encoded in the +\fIencoding_name\fR\&. If this option is omitted, the current client encoding is used\&. See the Notes below for more details\&. +.RE +.SH "OUTPUTS" +.PP +On successful completion, a +\fBCOPY\fR +command returns a command tag of the form +.sp +.if n \{\ +.RS 4 +.\} +.nf +COPY \fIcount\fR +.fi +.if n \{\ +.RE +.\} +.sp +The +\fIcount\fR +is the number of rows copied\&. +.SH "NOTES" +.PP + +\fBCOPY\fR +can only be used with plain tables, not with views\&. However, you can write +COPY (SELECT * FROM \fIviewname\fR) TO \&.\&.\&.\&. +.PP + +\fBCOPY\fR +only deals with the specific table named; it does not copy data to or from child tables\&. Thus for example +COPY \fItable\fR TO +shows the same data as +SELECT * FROM ONLY \fItable\fR\&. But +COPY (SELECT * FROM \fItable\fR) TO \&.\&.\&. +can be used to dump all of the data in an inheritance hierarchy\&. +.PP +You must have select privilege on the table whose values are read by +\fBCOPY TO\fR, and insert privilege on the table into which values are inserted by +\fBCOPY FROM\fR\&. It is sufficient to have column privileges on the column(s) listed in the command\&. +.PP +Files named in a +\fBCOPY\fR +command are read or written directly by the server, not by the client application\&. Therefore, they must reside on or be accessible to the database server machine, not the client\&. They must be accessible to and readable or writable by the +PostgreSQL +user (the user ID the server runs as), not the client\&. +\fBCOPY\fR +naming a file is only allowed to database superusers, since it allows reading or writing any file that the server has privileges to access\&. +.PP +Do not confuse +\fBCOPY\fR +with the +psql +instruction +\fB\ecopy\fR\&. +\fB\ecopy\fR +invokes +\fBCOPY FROM STDIN\fR +or +\fBCOPY TO STDOUT\fR, and then fetches/stores the data in a file accessible to the +psql +client\&. Thus, file accessibility and access rights depend on the client rather than the server when +\fB\ecopy\fR +is used\&. +.PP +It is recommended that the file name used in +\fBCOPY\fR +always be specified as an absolute path\&. This is enforced by the server in the case of +\fBCOPY TO\fR, but for +\fBCOPY FROM\fR +you do have the option of reading from a file specified by a relative path\&. The path will be interpreted relative to the working directory of the server process (normally the cluster\*(Aqs data directory), not the client\*(Aqs working directory\&. +.PP + +\fBCOPY FROM\fR +will invoke any triggers and check constraints on the destination table\&. However, it will not invoke rules\&. +.PP + +\fBCOPY\fR +input and output is affected by +\fIDateStyle\fR\&. To ensure portability to other +PostgreSQL +installations that might use non\-default +\fIDateStyle\fR +settings, +\fIDateStyle\fR +should be set to +ISO +before using +\fBCOPY TO\fR\&. It is also a good idea to avoid dumping data with +\fIIntervalStyle\fR +set to +sql_standard, because negative interval values might be misinterpreted by a server that has a different setting for +\fIIntervalStyle\fR\&. +.PP +Input data is interpreted according to +ENCODING +option or the current client encoding, and output data is encoded in +ENCODING +or the current client encoding, even if the data does not pass through the client but is read from or written to a file directly by the server\&. +.PP + +\fBCOPY\fR +stops operation at the first error\&. This should not lead to problems in the event of a +\fBCOPY TO\fR, but the target table will already have received earlier rows in a +\fBCOPY FROM\fR\&. These rows will not be visible or accessible, but they still occupy disk space\&. This might amount to a considerable amount of wasted disk space if the failure happened well into a large copy operation\&. You might wish to invoke +\fBVACUUM\fR +to recover the wasted space\&. +.SH "FILE FORMATS" +.SS "Text Format" +.PP +When the +text +format is used, the data read or written is a text file with one line per table row\&. Columns in a row are separated by the delimiter character\&. The column values themselves are strings generated by the output function, or acceptable to the input function, of each attribute\*(Aqs data type\&. The specified null string is used in place of columns that are null\&. +\fBCOPY FROM\fR +will raise an error if any line of the input file contains more or fewer columns than are expected\&. If +OIDS +is specified, the OID is read or written as the first column, preceding the user data columns\&. +.PP +End of data can be represented by a single line containing just backslash\-period (\e\&.)\&. An end\-of\-data marker is not necessary when reading from a file, since the end of file serves perfectly well; it is needed only when copying data to or from client applications using pre\-3\&.0 client protocol\&. +.PP +Backslash characters (\e) can be used in the +\fBCOPY\fR +data to quote data characters that might otherwise be taken as row or column delimiters\&. In particular, the following characters +\fImust\fR +be preceded by a backslash if they appear as part of a column value: backslash itself, newline, carriage return, and the current delimiter character\&. +.PP +The specified null string is sent by +\fBCOPY TO\fR +without adding any backslashes; conversely, +\fBCOPY FROM\fR +matches the input against the null string before removing backslashes\&. Therefore, a null string such as +\eN +cannot be confused with the actual data value +\eN +(which would be represented as +\e\eN)\&. +.PP +The following special backslash sequences are recognized by +\fBCOPY FROM\fR: +.TS +allbox tab(:); +lB lB. +T{ +Sequence +T}:T{ +Represents +T} +.T& +l l +l l +l l +l l +l l +l l +l l +l l. +T{ +\eb +T}:T{ +Backspace (ASCII 8) +T} +T{ +\ef +T}:T{ +Form feed (ASCII 12) +T} +T{ +\en +T}:T{ +Newline (ASCII 10) +T} +T{ +\er +T}:T{ +Carriage return (ASCII 13) +T} +T{ +\et +T}:T{ +Tab (ASCII 9) +T} +T{ +\ev +T}:T{ +Vertical tab (ASCII 11) +T} +T{ +\e\fIdigits\fR +T}:T{ +Backslash followed by one to three octal digits specifies + the character with that numeric code +T} +T{ +\ex\fIdigits\fR +T}:T{ +Backslash x followed by one or two hex digits specifies + the character with that numeric code +T} +.TE +.sp 1 +Presently, +\fBCOPY TO\fR +will never emit an octal or hex\-digits backslash sequence, but it does use the other sequences listed above for those control characters\&. +.PP +Any other backslashed character that is not mentioned in the above table will be taken to represent itself\&. However, beware of adding backslashes unnecessarily, since that might accidentally produce a string matching the end\-of\-data marker (\e\&.) or the null string (\eN +by default)\&. These strings will be recognized before any other backslash processing is done\&. +.PP +It is strongly recommended that applications generating +\fBCOPY\fR +data convert data newlines and carriage returns to the +\en +and +\er +sequences respectively\&. At present it is possible to represent a data carriage return by a backslash and carriage return, and to represent a data newline by a backslash and newline\&. However, these representations might not be accepted in future releases\&. They are also highly vulnerable to corruption if the +\fBCOPY\fR +file is transferred across different machines (for example, from Unix to Windows or vice versa)\&. +.PP + +\fBCOPY TO\fR +will terminate each row with a Unix\-style newline (\(lq\en\(rq)\&. Servers running on Microsoft Windows instead output carriage return/newline (\(lq\er\en\(rq), but only for +\fBCOPY\fR +to a server file; for consistency across platforms, +\fBCOPY TO STDOUT\fR +always sends +\(lq\en\(rq +regardless of server platform\&. +\fBCOPY FROM\fR +can handle lines ending with newlines, carriage returns, or carriage return/newlines\&. To reduce the risk of error due to un\-backslashed newlines or carriage returns that were meant as data, +\fBCOPY FROM\fR +will complain if the line endings in the input are not all alike\&. +.SS "CSV Format" +.PP +This format option is used for importing and exporting the Comma Separated Value (CSV) file format used by many other programs, such as spreadsheets\&. Instead of the escaping rules used by +PostgreSQL\*(Aqs standard text format, it produces and recognizes the common CSV escaping mechanism\&. +.PP +The values in each record are separated by the +DELIMITER +character\&. If the value contains the delimiter character, the +QUOTE +character, the +NULL +string, a carriage return, or line feed character, then the whole value is prefixed and suffixed by the +QUOTE +character, and any occurrence within the value of a +QUOTE +character or the +ESCAPE +character is preceded by the escape character\&. You can also use +FORCE_QUOTE +to force quotes when outputting non\-NULL +values in specific columns\&. +.PP +The +CSV +format has no standard way to distinguish a +NULL +value from an empty string\&. +PostgreSQL\*(Aqs +\fBCOPY\fR +handles this by quoting\&. A +NULL +is output as the +NULL +parameter string and is not quoted, while a non\-NULL +value matching the +NULL +parameter string is quoted\&. For example, with the default settings, a +NULL +is written as an unquoted empty string, while an empty string data value is written with double quotes ("")\&. Reading values follows similar rules\&. You can use +FORCE_NOT_NULL +to prevent +NULL +input comparisons for specific columns\&. +.PP +Because backslash is not a special character in the +CSV +format, +\e\&., the end\-of\-data marker, could also appear as a data value\&. To avoid any misinterpretation, a +\e\&. +data value appearing as a lone entry on a line is automatically quoted on output, and on input, if quoted, is not interpreted as the end\-of\-data marker\&. If you are loading a file created by another application that has a single unquoted column and might have a value of +\e\&., you might need to quote that value in the input file\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +.PP +In +CSV +format, all characters are significant\&. A quoted value surrounded by white space, or any characters other than +DELIMITER, will include those characters\&. This can cause errors if you import data from a system that pads +CSV +lines with white space out to some fixed width\&. If such a situation arises you might need to preprocess the +CSV +file to remove the trailing white space, before importing the data into +PostgreSQL\&. +.sp .5v +.RE +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +.PP +CSV format will both recognize and produce CSV files with quoted values containing embedded carriage returns and line feeds\&. Thus the files are not strictly one line per table row like text\-format files\&. +.sp .5v +.RE +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +.PP +Many programs produce strange and occasionally perverse CSV files, so the file format is more a convention than a standard\&. Thus you might encounter some files that cannot be imported using this mechanism, and +\fBCOPY\fR +might produce files that other programs cannot process\&. +.sp .5v +.RE +.SS "Binary Format" +.PP +The +binary +format option causes all data to be stored/read as binary format rather than as text\&. It is somewhat faster than the text and +CSV +formats, but a binary\-format file is less portable across machine architectures and +PostgreSQL +versions\&. Also, the binary format is very data type specific; for example it will not work to output binary data from a +smallint +column and read it into an +integer +column, even though that would work fine in text format\&. +.PP +The +binary +file format consists of a file header, zero or more tuples containing the row data, and a file trailer\&. Headers and data are in network byte order\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +.PP + +PostgreSQL +releases before 7\&.4 used a different binary file format\&. +.sp .5v +.RE +.sp +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBFile Header\fR +.RS 4 +.PP +The file header consists of 15 bytes of fixed fields, followed by a variable\-length header extension area\&. The fixed fields are: +.PP +Signature +.RS 4 +11\-byte sequence +PGCOPY\en\e377\er\en\e0 +\(em note that the zero byte is a required part of the signature\&. (The signature is designed to allow easy identification of files that have been munged by a non\-8\-bit\-clean transfer\&. This signature will be changed by end\-of\-line\-translation filters, dropped zero bytes, dropped high bits, or parity changes\&.) +.RE +.PP +Flags field +.RS 4 +32\-bit integer bit mask to denote important aspects of the file format\&. Bits are numbered from 0 (LSB) to 31 (MSB)\&. Note that this field is stored in network byte order (most significant byte first), as are all the integer fields used in the file format\&. Bits 16\-31 are reserved to denote critical file format issues; a reader should abort if it finds an unexpected bit set in this range\&. Bits 0\-15 are reserved to signal backwards\-compatible format issues; a reader should simply ignore any unexpected bits set in this range\&. Currently only one flag bit is defined, and the rest must be zero: +.PP +Bit 16 +.RS 4 +if 1, OIDs are included in the data; if 0, not +.RE +.RE +.PP +Header extension area length +.RS 4 +32\-bit integer, length in bytes of remainder of header, not including self\&. Currently, this is zero, and the first tuple follows immediately\&. Future changes to the format might allow additional data to be present in the header\&. A reader should silently skip over any header extension data it does not know what to do with\&. +.RE +.PP +The header extension area is envisioned to contain a sequence of self\-identifying chunks\&. The flags field is not intended to tell readers what is in the extension area\&. Specific design of header extension contents is left for a later release\&. +.PP +This design allows for both backwards\-compatible header additions (add header extension chunks, or set low\-order flag bits) and non\-backwards\-compatible changes (set high\-order flag bits to signal such changes, and add supporting data to the extension area if needed)\&. +.RE +.sp +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBTuples\fR +.RS 4 +.PP +Each tuple begins with a 16\-bit integer count of the number of fields in the tuple\&. (Presently, all tuples in a table will have the same count, but that might not always be true\&.) Then, repeated for each field in the tuple, there is a 32\-bit length word followed by that many bytes of field data\&. (The length word does not include itself, and can be zero\&.) As a special case, \-1 indicates a NULL field value\&. No value bytes follow in the NULL case\&. +.PP +There is no alignment padding or any other extra data between fields\&. +.PP +Presently, all data values in a binary\-format file are assumed to be in binary format (format code one)\&. It is anticipated that a future extension might add a header field that allows per\-column format codes to be specified\&. +.PP +To determine the appropriate binary format for the actual tuple data you should consult the +PostgreSQL +source, in particular the +\fB*send\fR +and +\fB*recv\fR +functions for each column\*(Aqs data type (typically these functions are found in the +src/backend/utils/adt/ +directory of the source distribution)\&. +.PP +If OIDs are included in the file, the OID field immediately follows the field\-count word\&. It is a normal field except that it\*(Aqs not included in the field\-count\&. In particular it has a length word \(em this will allow handling of 4\-byte vs\&. 8\-byte OIDs without too much pain, and will allow OIDs to be shown as null if that ever proves desirable\&. +.RE +.sp +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBFile Trailer\fR +.RS 4 +.PP +The file trailer consists of a 16\-bit integer word containing \-1\&. This is easily distinguished from a tuple\*(Aqs field\-count word\&. +.PP +A reader should report an error if a field\-count word is neither \-1 nor the expected number of columns\&. This provides an extra check against somehow getting out of sync with the data\&. +.RE +.SH "EXAMPLES" +.PP +The following example copies a table to the client using the vertical bar (|) as the field delimiter: +.sp +.if n \{\ +.RS 4 +.\} +.nf +COPY country TO STDOUT (DELIMITER \*(Aq|\*(Aq); +.fi +.if n \{\ +.RE +.\} +.PP +To copy data from a file into the +country +table: +.sp +.if n \{\ +.RS 4 +.\} +.nf +COPY country FROM \*(Aq/usr1/proj/bray/sql/country_data\*(Aq; +.fi +.if n \{\ +.RE +.\} +.PP +To copy into a file just the countries whose names start with \*(AqA\*(Aq: +.sp +.if n \{\ +.RS 4 +.\} +.nf +COPY (SELECT * FROM country WHERE country_name LIKE \*(AqA%\*(Aq) TO \*(Aq/usr1/proj/bray/sql/a_list_countries\&.copy\*(Aq; +.fi +.if n \{\ +.RE +.\} +.PP +Here is a sample of data suitable for copying into a table from +STDIN: +.sp +.if n \{\ +.RS 4 +.\} +.nf +AF AFGHANISTAN +AL ALBANIA +DZ ALGERIA +ZM ZAMBIA +ZW ZIMBABWE +.fi +.if n \{\ +.RE +.\} +.sp +Note that the white space on each line is actually a tab character\&. +.PP +The following is the same data, output in binary format\&. The data is shown after filtering through the Unix utility +\fBod \-c\fR\&. The table has three columns; the first has type +char(2), the second has type +text, and the third has type +integer\&. All the rows have a null value in the third column\&. +.sp +.if n \{\ +.RS 4 +.\} +.nf +0000000 P G C O P Y \en 377 \er \en \e0 \e0 \e0 \e0 \e0 \e0 +0000020 \e0 \e0 \e0 \e0 003 \e0 \e0 \e0 002 A F \e0 \e0 \e0 013 A +0000040 F G H A N I S T A N 377 377 377 377 \e0 003 +0000060 \e0 \e0 \e0 002 A L \e0 \e0 \e0 007 A L B A N I +0000100 A 377 377 377 377 \e0 003 \e0 \e0 \e0 002 D Z \e0 \e0 \e0 +0000120 007 A L G E R I A 377 377 377 377 \e0 003 \e0 \e0 +0000140 \e0 002 Z M \e0 \e0 \e0 006 Z A M B I A 377 377 +0000160 377 377 \e0 003 \e0 \e0 \e0 002 Z W \e0 \e0 \e0 \eb Z I +0000200 M B A B W E 377 377 377 377 377 377 +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBCOPY\fR +statement in the SQL standard\&. +.PP +The following syntax was used before +PostgreSQL +version 9\&.0 and is still supported: +.sp +.if n \{\ +.RS 4 +.\} +.nf +COPY \fItable_name\fR [ ( \fIcolumn_name\fR [, \&.\&.\&.] ) ] + FROM { \*(Aq\fIfilename\fR\*(Aq | STDIN } + [ [ WITH ] + [ BINARY ] + [ OIDS ] + [ DELIMITER [ AS ] \*(Aq\fIdelimiter\fR\*(Aq ] + [ NULL [ AS ] \*(Aq\fInull string\fR\*(Aq ] + [ CSV [ HEADER ] + [ QUOTE [ AS ] \*(Aq\fIquote\fR\*(Aq ] + [ ESCAPE [ AS ] \*(Aq\fIescape\fR\*(Aq ] + [ FORCE NOT NULL \fIcolumn_name\fR [, \&.\&.\&.] ] ] ] + +COPY { \fItable_name\fR [ ( \fIcolumn_name\fR [, \&.\&.\&.] ) ] | ( \fIquery\fR ) } + TO { \*(Aq\fIfilename\fR\*(Aq | STDOUT } + [ [ WITH ] + [ BINARY ] + [ OIDS ] + [ DELIMITER [ AS ] \*(Aq\fIdelimiter\fR\*(Aq ] + [ NULL [ AS ] \*(Aq\fInull string\fR\*(Aq ] + [ CSV [ HEADER ] + [ QUOTE [ AS ] \*(Aq\fIquote\fR\*(Aq ] + [ ESCAPE [ AS ] \*(Aq\fIescape\fR\*(Aq ] + [ FORCE QUOTE { \fIcolumn_name\fR [, \&.\&.\&.] | * } ] ] ] +.fi +.if n \{\ +.RE +.\} +.sp + +Note that in this syntax, +BINARY +and +CSV +are treated as independent keywords, not as arguments of a +FORMAT +option\&. +.PP +The following syntax was used before +PostgreSQL +version 7\&.3 and is still supported: +.sp +.if n \{\ +.RS 4 +.\} +.nf +COPY [ BINARY ] \fItable_name\fR [ WITH OIDS ] + FROM { \*(Aq\fIfilename\fR\*(Aq | STDIN } + [ [USING] DELIMITERS \*(Aq\fIdelimiter\fR\*(Aq ] + [ WITH NULL AS \*(Aq\fInull string\fR\*(Aq ] + +COPY [ BINARY ] \fItable_name\fR [ WITH OIDS ] + TO { \*(Aq\fIfilename\fR\*(Aq | STDOUT } + [ [USING] DELIMITERS \*(Aq\fIdelimiter\fR\*(Aq ] + [ WITH NULL AS \*(Aq\fInull string\fR\*(Aq ] +.fi +.if n \{\ +.RE +.\} + diff --git a/doc/src/sgml/man7/CREATE_AGGREGATE.7 b/doc/src/sgml/man7/CREATE_AGGREGATE.7 new file mode 100644 index 000000000..5469956ee --- /dev/null +++ b/doc/src/sgml/man7/CREATE_AGGREGATE.7 @@ -0,0 +1,235 @@ +'\" t +.\" Title: CREATE AGGREGATE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE AGGREGATE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_AGGREGATE \- define a new aggregate function +.\" CREATE AGGREGATE +.SH "SYNOPSIS" +.sp +.nf +CREATE AGGREGATE \fIname\fR ( \fIinput_data_type\fR [ , \&.\&.\&. ] ) ( + SFUNC = \fIsfunc\fR, + STYPE = \fIstate_data_type\fR + [ , FINALFUNC = \fIffunc\fR ] + [ , INITCOND = \fIinitial_condition\fR ] + [ , SORTOP = \fIsort_operator\fR ] +) + +or the old syntax + +CREATE AGGREGATE \fIname\fR ( + BASETYPE = \fIbase_type\fR, + SFUNC = \fIsfunc\fR, + STYPE = \fIstate_data_type\fR + [ , FINALFUNC = \fIffunc\fR ] + [ , INITCOND = \fIinitial_condition\fR ] + [ , SORTOP = \fIsort_operator\fR ] +) +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE AGGREGATE\fR +defines a new aggregate function\&. Some basic and commonly\-used aggregate functions are included with the distribution; they are documented in +Section 9.20, \(lqAggregate Functions\(rq, in the documentation\&. If one defines new types or needs an aggregate function not already provided, then +\fBCREATE AGGREGATE\fR +can be used to provide the desired features\&. +.PP +If a schema name is given (for example, +CREATE AGGREGATE myschema\&.myagg \&.\&.\&.) then the aggregate function is created in the specified schema\&. Otherwise it is created in the current schema\&. +.PP +An aggregate function is identified by its name and input data type(s)\&. Two aggregates in the same schema can have the same name if they operate on different input types\&. The name and input data type(s) of an aggregate must also be distinct from the name and input data type(s) of every ordinary function in the same schema\&. +.PP +An aggregate function is made from one or two ordinary functions: a state transition function +\fIsfunc\fR, and an optional final calculation function +\fIffunc\fR\&. These are used as follows: +.sp +.if n \{\ +.RS 4 +.\} +.nf +\fIsfunc\fR( internal\-state, next\-data\-values ) \-\-\-> next\-internal\-state +\fIffunc\fR( internal\-state ) \-\-\-> aggregate\-value +.fi +.if n \{\ +.RE +.\} +.PP + +PostgreSQL +creates a temporary variable of data type +\fIstype\fR +to hold the current internal state of the aggregate\&. At each input row, the aggregate argument value(s) are calculated and the state transition function is invoked with the current state value and the new argument value(s) to calculate a new internal state value\&. After all the rows have been processed, the final function is invoked once to calculate the aggregate\*(Aqs return value\&. If there is no final function then the ending state value is returned as\-is\&. +.PP +An aggregate function can provide an initial condition, that is, an initial value for the internal state value\&. This is specified and stored in the database as a value of type +text, but it must be a valid external representation of a constant of the state value data type\&. If it is not supplied then the state value starts out null\&. +.PP +If the state transition function is declared +\(lqstrict\(rq, then it cannot be called with null inputs\&. With such a transition function, aggregate execution behaves as follows\&. Rows with any null input values are ignored (the function is not called and the previous state value is retained)\&. If the initial state value is null, then at the first row with all\-nonnull input values, the first argument value replaces the state value, and the transition function is invoked at subsequent rows with all\-nonnull input values\&. This is handy for implementing aggregates like +\fBmax\fR\&. Note that this behavior is only available when +\fIstate_data_type\fR +is the same as the first +\fIinput_data_type\fR\&. When these types are different, you must supply a nonnull initial condition or use a nonstrict transition function\&. +.PP +If the state transition function is not strict, then it will be called unconditionally at each input row, and must deal with null inputs and null transition values for itself\&. This allows the aggregate author to have full control over the aggregate\*(Aqs handling of null values\&. +.PP +If the final function is declared +\(lqstrict\(rq, then it will not be called when the ending state value is null; instead a null result will be returned automatically\&. (Of course this is just the normal behavior of strict functions\&.) In any case the final function has the option of returning a null value\&. For example, the final function for +\fBavg\fR +returns null when it sees there were zero input rows\&. +.PP +Aggregates that behave like +\fBMIN\fR +or +\fBMAX\fR +can sometimes be optimized by looking into an index instead of scanning every input row\&. If this aggregate can be so optimized, indicate it by specifying a +sort operator\&. The basic requirement is that the aggregate must yield the first element in the sort ordering induced by the operator; in other words: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT agg(col) FROM tab; +.fi +.if n \{\ +.RE +.\} +.sp +must be equivalent to: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT col FROM tab ORDER BY col USING sortop LIMIT 1; +.fi +.if n \{\ +.RE +.\} +.sp +Further assumptions are that the aggregate ignores null inputs, and that it delivers a null result if and only if there were no non\-null inputs\&. Ordinarily, a data type\*(Aqs +< +operator is the proper sort operator for +\fBMIN\fR, and +> +is the proper sort operator for +\fBMAX\fR\&. Note that the optimization will never actually take effect unless the specified operator is the +\(lqless than\(rq +or +\(lqgreater than\(rq +strategy member of a B\-tree index operator class\&. +.PP +To be able to create an aggregate function, you must have +USAGE +privilege on the argument types, the state type, and the return type, as well as +EXECUTE +privilege on the transition and final functions\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of the aggregate function to create\&. +.RE +.PP +\fIinput_data_type\fR +.RS 4 +An input data type on which this aggregate function operates\&. To create a zero\-argument aggregate function, write +* +in place of the list of input data types\&. (An example of such an aggregate is +\fBcount(*)\fR\&.) +.RE +.PP +\fIbase_type\fR +.RS 4 +In the old syntax for +\fBCREATE AGGREGATE\fR, the input data type is specified by a +basetype +parameter rather than being written next to the aggregate name\&. Note that this syntax allows only one input parameter\&. To define a zero\-argument aggregate function, specify the +basetype +as +"ANY" +(not +*)\&. +.RE +.PP +\fIsfunc\fR +.RS 4 +The name of the state transition function to be called for each input row\&. For an +\fIN\fR\-argument aggregate function, the +\fIsfunc\fR +must take +\fIN\fR+1 arguments, the first being of type +\fIstate_data_type\fR +and the rest matching the declared input data type(s) of the aggregate\&. The function must return a value of type +\fIstate_data_type\fR\&. This function takes the current state value and the current input data value(s), and returns the next state value\&. +.RE +.PP +\fIstate_data_type\fR +.RS 4 +The data type for the aggregate\*(Aqs state value\&. +.RE +.PP +\fIffunc\fR +.RS 4 +The name of the final function called to compute the aggregate\*(Aqs result after all input rows have been traversed\&. The function must take a single argument of type +\fIstate_data_type\fR\&. The return data type of the aggregate is defined as the return type of this function\&. If +\fIffunc\fR +is not specified, then the ending state value is used as the aggregate\*(Aqs result, and the return type is +\fIstate_data_type\fR\&. +.RE +.PP +\fIinitial_condition\fR +.RS 4 +The initial setting for the state value\&. This must be a string constant in the form accepted for the data type +\fIstate_data_type\fR\&. If not specified, the state value starts out null\&. +.RE +.PP +\fIsort_operator\fR +.RS 4 +The associated sort operator for a +\fBMIN\fR\- or +\fBMAX\fR\-like aggregate\&. This is just an operator name (possibly schema\-qualified)\&. The operator is assumed to have the same input data types as the aggregate (which must be a single\-argument aggregate)\&. +.RE +.PP +The parameters of +\fBCREATE AGGREGATE\fR +can be written in any order, not just the order illustrated above\&. +.SH "EXAMPLES" +.PP +See +Section 35.10, \(lqUser-defined Aggregates\(rq, in the documentation\&. +.SH "COMPATIBILITY" +.PP + +\fBCREATE AGGREGATE\fR +is a +PostgreSQL +language extension\&. The SQL standard does not provide for user\-defined aggregate functions\&. +.SH "SEE ALSO" +ALTER AGGREGATE (\fBALTER_AGGREGATE\fR(7)), DROP AGGREGATE (\fBDROP_AGGREGATE\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_CAST.7 b/doc/src/sgml/man7/CREATE_CAST.7 new file mode 100644 index 000000000..fda1d0e19 --- /dev/null +++ b/doc/src/sgml/man7/CREATE_CAST.7 @@ -0,0 +1,383 @@ +'\" t +.\" Title: CREATE CAST +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE CAST" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_CAST \- define a new cast +.\" CREATE CAST +.SH "SYNOPSIS" +.sp +.nf +CREATE CAST (\fIsource_type\fR AS \fItarget_type\fR) + WITH FUNCTION \fIfunction_name\fR (\fIargument_type\fR [, \&.\&.\&.]) + [ AS ASSIGNMENT | AS IMPLICIT ] + +CREATE CAST (\fIsource_type\fR AS \fItarget_type\fR) + WITHOUT FUNCTION + [ AS ASSIGNMENT | AS IMPLICIT ] + +CREATE CAST (\fIsource_type\fR AS \fItarget_type\fR) + WITH INOUT + [ AS ASSIGNMENT | AS IMPLICIT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE CAST\fR +defines a new cast\&. A cast specifies how to perform a conversion between two data types\&. For example, +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT CAST(42 AS float8); +.fi +.if n \{\ +.RE +.\} +.sp +converts the integer constant 42 to type +float8 +by invoking a previously specified function, in this case +float8(int4)\&. (If no suitable cast has been defined, the conversion fails\&.) +.PP +Two types can be +binary coercible, which means that the conversion can be performed +\(lqfor free\(rq +without invoking any function\&. This requires that corresponding values use the same internal representation\&. For instance, the types +text +and +varchar +are binary coercible both ways\&. Binary coercibility is not necessarily a symmetric relationship\&. For example, the cast from +xml +to +text +can be performed for free in the present implementation, but the reverse direction requires a function that performs at least a syntax check\&. (Two types that are binary coercible both ways are also referred to as binary compatible\&.) +.PP +You can define a cast as an +I/O conversion cast +by using the +WITH INOUT +syntax\&. An I/O conversion cast is performed by invoking the output function of the source data type, and passing the resulting string to the input function of the target data type\&. In many common cases, this feature avoids the need to write a separate cast function for conversion\&. An I/O conversion cast acts the same as a regular function\-based cast; only the implementation is different\&. +.PP +By default, a cast can be invoked only by an explicit cast request, that is an explicit +CAST(\fIx\fR AS \fItypename\fR) +or +\fIx\fR::\fItypename\fR +construct\&. +.PP +If the cast is marked +AS ASSIGNMENT +then it can be invoked implicitly when assigning a value to a column of the target data type\&. For example, supposing that +foo\&.f1 +is a column of type +text, then: +.sp +.if n \{\ +.RS 4 +.\} +.nf +INSERT INTO foo (f1) VALUES (42); +.fi +.if n \{\ +.RE +.\} +.sp +will be allowed if the cast from type +integer +to type +text +is marked +AS ASSIGNMENT, otherwise not\&. (We generally use the term +assignment cast +to describe this kind of cast\&.) +.PP +If the cast is marked +AS IMPLICIT +then it can be invoked implicitly in any context, whether assignment or internally in an expression\&. (We generally use the term +implicit cast +to describe this kind of cast\&.) For example, consider this query: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT 2 + 4\&.0; +.fi +.if n \{\ +.RE +.\} +.sp +The parser initially marks the constants as being of type +integer +and +numeric +respectively\&. There is no +integer ++ +numeric +operator in the system catalogs, but there is a +numeric ++ +numeric +operator\&. The query will therefore succeed if a cast from +integer +to +numeric +is available and is marked +AS IMPLICIT +\(em which in fact it is\&. The parser will apply the implicit cast and resolve the query as if it had been written +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT CAST ( 2 AS numeric ) + 4\&.0; +.fi +.if n \{\ +.RE +.\} +.PP +Now, the catalogs also provide a cast from +numeric +to +integer\&. If that cast were marked +AS IMPLICIT +\(em which it is not \(em then the parser would be faced with choosing between the above interpretation and the alternative of casting the +numeric +constant to +integer +and applying the +integer ++ +integer +operator\&. Lacking any knowledge of which choice to prefer, it would give up and declare the query ambiguous\&. The fact that only one of the two casts is implicit is the way in which we teach the parser to prefer resolution of a mixed +numeric\-and\-integer +expression as +numeric; there is no built\-in knowledge about that\&. +.PP +It is wise to be conservative about marking casts as implicit\&. An overabundance of implicit casting paths can cause +PostgreSQL +to choose surprising interpretations of commands, or to be unable to resolve commands at all because there are multiple possible interpretations\&. A good rule of thumb is to make a cast implicitly invokable only for information\-preserving transformations between types in the same general type category\&. For example, the cast from +int2 +to +int4 +can reasonably be implicit, but the cast from +float8 +to +int4 +should probably be assignment\-only\&. Cross\-type\-category casts, such as +text +to +int4, are best made explicit\-only\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +.PP +Sometimes it is necessary for usability or standards\-compliance reasons to provide multiple implicit casts among a set of types, resulting in ambiguity that cannot be avoided as above\&. The parser has a fallback heuristic based on +type categories +and +preferred types +that can help to provide desired behavior in such cases\&. See +CREATE TYPE (\fBCREATE_TYPE\fR(7)) +for more information\&. +.sp .5v +.RE +.PP +To be able to create a cast, you must own the source or the target data type and have +USAGE +privilege on the other type\&. To create a binary\-coercible cast, you must be superuser\&. (This restriction is made because an erroneous binary\-coercible cast conversion can easily crash the server\&.) +.SH "PARAMETERS" +.PP +\fIsource_type\fR +.RS 4 +The name of the source data type of the cast\&. +.RE +.PP +\fItarget_type\fR +.RS 4 +The name of the target data type of the cast\&. +.RE +.PP +\fIfunction_name\fR(\fIargument_type\fR [, \&.\&.\&.]) +.RS 4 +The function used to perform the cast\&. The function name can be schema\-qualified\&. If it is not, the function will be looked up in the schema search path\&. The function\*(Aqs result data type must match the target type of the cast\&. Its arguments are discussed below\&. +.RE +.PP +WITHOUT FUNCTION +.RS 4 +Indicates that the source type is binary\-coercible to the target type, so no function is required to perform the cast\&. +.RE +.PP +WITH INOUT +.RS 4 +Indicates that the cast is an I/O conversion cast, performed by invoking the output function of the source data type, and passing the resulting string to the input function of the target data type\&. +.RE +.PP +AS ASSIGNMENT +.RS 4 +Indicates that the cast can be invoked implicitly in assignment contexts\&. +.RE +.PP +AS IMPLICIT +.RS 4 +Indicates that the cast can be invoked implicitly in any context\&. +.RE +.PP +Cast implementation functions can have one to three arguments\&. The first argument type must be identical to or binary\-coercible from the cast\*(Aqs source type\&. The second argument, if present, must be type +integer; it receives the type modifier associated with the destination type, or +\-1 +if there is none\&. The third argument, if present, must be type +boolean; it receives +true +if the cast is an explicit cast, +false +otherwise\&. (Bizarrely, the SQL standard demands different behaviors for explicit and implicit casts in some cases\&. This argument is supplied for functions that must implement such casts\&. It is not recommended that you design your own data types so that this matters\&.) +.PP +The return type of a cast function must be identical to or binary\-coercible to the cast\*(Aqs target type\&. +.PP +Ordinarily a cast must have different source and target data types\&. However, it is allowed to declare a cast with identical source and target types if it has a cast implementation function with more than one argument\&. This is used to represent type\-specific length coercion functions in the system catalogs\&. The named function is used to coerce a value of the type to the type modifier value given by its second argument\&. +.PP +When a cast has different source and target types and a function that takes more than one argument, it supports converting from one type to another and applying a length coercion in a single step\&. When no such entry is available, coercion to a type that uses a type modifier involves two cast steps, one to convert between data types and a second to apply the modifier\&. +.PP +A cast to or from a domain type currently has no effect\&. Casting to or from a domain uses the casts associated with its underlying type\&. +.SH "NOTES" +.PP +Use +DROP CAST (\fBDROP_CAST\fR(7)) +to remove user\-defined casts\&. +.PP +Remember that if you want to be able to convert types both ways you need to declare casts both ways explicitly\&. +.\" cast: I/O conversion +.PP +It is normally not necessary to create casts between user\-defined types and the standard string types (text, +varchar, and +char(\fIn\fR), as well as user\-defined types that are defined to be in the string category)\&. +PostgreSQL +provides automatic I/O conversion casts for that\&. The automatic casts to string types are treated as assignment casts, while the automatic casts from string types are explicit\-only\&. You can override this behavior by declaring your own cast to replace an automatic cast, but usually the only reason to do so is if you want the conversion to be more easily invokable than the standard assignment\-only or explicit\-only setting\&. Another possible reason is that you want the conversion to behave differently from the type\*(Aqs I/O function; but that is sufficiently surprising that you should think twice about whether it\*(Aqs a good idea\&. (A small number of the built\-in types do indeed have different behaviors for conversions, mostly because of requirements of the SQL standard\&.) +.PP +Prior to +PostgreSQL +7\&.3, every function that had the same name as a data type, returned that data type, and took one argument of a different type was automatically a cast function\&. This convention has been abandoned in face of the introduction of schemas and to be able to represent binary\-coercible casts in the system catalogs\&. The built\-in cast functions still follow this naming scheme, but they have to be shown as casts in the system catalog +pg_cast +as well\&. +.PP +While not required, it is recommended that you continue to follow this old convention of naming cast implementation functions after the target data type\&. Many users are used to being able to cast data types using a function\-style notation, that is +\fItypename\fR(\fIx\fR)\&. This notation is in fact nothing more nor less than a call of the cast implementation function; it is not specially treated as a cast\&. If your conversion functions are not named to support this convention then you will have surprised users\&. Since +PostgreSQL +allows overloading of the same function name with different argument types, there is no difficulty in having multiple conversion functions from different types that all use the target type\*(Aqs name\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +.PP +Actually the preceding paragraph is an oversimplification: there are two cases in which a function\-call construct will be treated as a cast request without having matched it to an actual function\&. If a function call +\fIname\fR(\fIx\fR) does not exactly match any existing function, but +\fIname\fR +is the name of a data type and +pg_cast +provides a binary\-coercible cast to this type from the type of +\fIx\fR, then the call will be construed as a binary\-coercible cast\&. This exception is made so that binary\-coercible casts can be invoked using functional syntax, even though they lack any function\&. Likewise, if there is no +pg_cast +entry but the cast would be to or from a string type, the call will be construed as an I/O conversion cast\&. This exception allows I/O conversion casts to be invoked using functional syntax\&. +.sp .5v +.RE +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +.PP +There is also an exception to the exception: I/O conversion casts from composite types to string types cannot be invoked using functional syntax, but must be written in explicit cast syntax (either +CAST +or +:: +notation)\&. This exception was added because after the introduction of automatically\-provided I/O conversion casts, it was found too easy to accidentally invoke such a cast when a function or column reference was intended\&. +.sp .5v +.RE +.SH "EXAMPLES" +.PP +To create an assignment cast from type +bigint +to type +int4 +using the function +int4(bigint): +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE CAST (bigint AS int4) WITH FUNCTION int4(bigint) AS ASSIGNMENT; +.fi +.if n \{\ +.RE +.\} +.sp +(This cast is already predefined in the system\&.) +.SH "COMPATIBILITY" +.PP +The +\fBCREATE CAST\fR +command conforms to the +SQL +standard, except that SQL does not make provisions for binary\-coercible types or extra arguments to implementation functions\&. +AS IMPLICIT +is a +PostgreSQL +extension, too\&. +.SH "SEE ALSO" +.PP + +CREATE FUNCTION (\fBCREATE_FUNCTION\fR(7)), +CREATE TYPE (\fBCREATE_TYPE\fR(7)), +DROP CAST (\fBDROP_CAST\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_COLLATION.7 b/doc/src/sgml/man7/CREATE_COLLATION.7 new file mode 100644 index 000000000..39e389a18 --- /dev/null +++ b/doc/src/sgml/man7/CREATE_COLLATION.7 @@ -0,0 +1,137 @@ +'\" t +.\" Title: CREATE COLLATION +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE COLLATION" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_COLLATION \- define a new collation +.\" CREATE COLLATION +.SH "SYNOPSIS" +.sp +.nf +CREATE COLLATION \fIname\fR ( + [ LOCALE = \fIlocale\fR, ] + [ LC_COLLATE = \fIlc_collate\fR, ] + [ LC_CTYPE = \fIlc_ctype\fR ] +) +CREATE COLLATION \fIname\fR FROM \fIexisting_collation\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE COLLATION\fR +defines a new collation using the specified operating system locale settings, or by copying an existing collation\&. +.PP +To be able to create a collation, you must have +CREATE +privilege on the destination schema\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name of the collation\&. The collation name can be schema\-qualified\&. If it is not, the collation is defined in the current schema\&. The collation name must be unique within that schema\&. (The system catalogs can contain collations with the same name for other encodings, but these are ignored if the database encoding does not match\&.) +.RE +.PP +\fIlocale\fR +.RS 4 +This is a shortcut for setting +LC_COLLATE +and +LC_CTYPE +at once\&. If you specify this, you cannot specify either of those parameters\&. +.RE +.PP +\fIlc_collate\fR +.RS 4 +Use the specified operating system locale for the +LC_COLLATE +locale category\&. The locale must be applicable to the current database encoding\&. (See +CREATE DATABASE (\fBCREATE_DATABASE\fR(7)) +for the precise rules\&.) +.RE +.PP +\fIlc_ctype\fR +.RS 4 +Use the specified operating system locale for the +LC_CTYPE +locale category\&. The locale must be applicable to the current database encoding\&. (See +CREATE DATABASE (\fBCREATE_DATABASE\fR(7)) +for the precise rules\&.) +.RE +.PP +\fIexisting_collation\fR +.RS 4 +The name of an existing collation to copy\&. The new collation will have the same properties as the existing one, but it will be an independent object\&. +.RE +.SH "NOTES" +.PP +Use +\fBDROP COLLATION\fR +to remove user\-defined collations\&. +.PP +See +Section 22.2, \(lqCollation Support\(rq, in the documentation +for more information about collation support in PostgreSQL\&. +.SH "EXAMPLES" +.PP +To create a collation from the operating system locale +fr_FR\&.utf8 +(assuming the current database encoding is +UTF8): +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE COLLATION french (LOCALE = \*(Aqfr_FR\&.utf8\*(Aq); +.fi +.if n \{\ +.RE +.\} +.PP +To create a collation from an existing collation: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE COLLATION german FROM "de_DE"; +.fi +.if n \{\ +.RE +.\} +.sp +This can be convenient to be able to use operating\-system\-independent collation names in applications\&. +.SH "COMPATIBILITY" +.PP +There is a +\fBCREATE COLLATION\fR +statement in the SQL standard, but it is limited to copying an existing collation\&. The syntax to create a new collation is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +ALTER COLLATION (\fBALTER_COLLATION\fR(7)), DROP COLLATION (\fBDROP_COLLATION\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_CONVERSION.7 b/doc/src/sgml/man7/CREATE_CONVERSION.7 new file mode 100644 index 000000000..522bc5e56 --- /dev/null +++ b/doc/src/sgml/man7/CREATE_CONVERSION.7 @@ -0,0 +1,137 @@ +'\" t +.\" Title: CREATE CONVERSION +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE CONVERSION" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_CONVERSION \- define a new encoding conversion +.\" CREATE CONVERSION +.SH "SYNOPSIS" +.sp +.nf +CREATE [ DEFAULT ] CONVERSION \fIname\fR + FOR \fIsource_encoding\fR TO \fIdest_encoding\fR FROM \fIfunction_name\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE CONVERSION\fR +defines a new conversion between character set encodings\&. Also, conversions that are marked +DEFAULT +can be used for automatic encoding conversion between client and server\&. For this purpose, two conversions, from encoding A to B +\fIand\fR +from encoding B to A, must be defined\&. +.PP +To be able to create a conversion, you must have +EXECUTE +privilege on the function and +CREATE +privilege on the destination schema\&. +.SH "PARAMETERS" +.PP +DEFAULT +.RS 4 +The +DEFAULT +clause indicates that this conversion is the default for this particular source to destination encoding\&. There should be only one default encoding in a schema for the encoding pair\&. +.RE +.PP +\fIname\fR +.RS 4 +The name of the conversion\&. The conversion name can be schema\-qualified\&. If it is not, the conversion is defined in the current schema\&. The conversion name must be unique within a schema\&. +.RE +.PP +\fIsource_encoding\fR +.RS 4 +The source encoding name\&. +.RE +.PP +\fIdest_encoding\fR +.RS 4 +The destination encoding name\&. +.RE +.PP +\fIfunction_name\fR +.RS 4 +The function used to perform the conversion\&. The function name can be schema\-qualified\&. If it is not, the function will be looked up in the path\&. +.sp +The function must have the following signature: +.sp +.if n \{\ +.RS 4 +.\} +.nf +conv_proc( + integer, \-\- source encoding ID + integer, \-\- destination encoding ID + cstring, \-\- source string (null terminated C string) + internal, \-\- destination (fill with a null terminated C string) + integer \-\- source string length +) RETURNS void; +.fi +.if n \{\ +.RE +.\} +.RE +.SH "NOTES" +.PP +Use +\fBDROP CONVERSION\fR +to remove user\-defined conversions\&. +.PP +The privileges required to create a conversion might be changed in a future release\&. +.SH "EXAMPLES" +.PP +To create a conversion from encoding +UTF8 +to +LATIN1 +using +\fBmyfunc\fR: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE CONVERSION myconv FOR \*(AqUTF8\*(Aq TO \*(AqLATIN1\*(Aq FROM myfunc; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBCREATE CONVERSION\fR +is a +PostgreSQL +extension\&. There is no +\fBCREATE CONVERSION\fR +statement in the SQL standard, but a +\fBCREATE TRANSLATION\fR +statement that is very similar in purpose and syntax\&. +.SH "SEE ALSO" +ALTER CONVERSION (\fBALTER_CONVERSION\fR(7)), CREATE FUNCTION (\fBCREATE_FUNCTION\fR(7)), DROP CONVERSION (\fBDROP_CONVERSION\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_DATABASE.7 b/doc/src/sgml/man7/CREATE_DATABASE.7 new file mode 100644 index 000000000..71119cd69 --- /dev/null +++ b/doc/src/sgml/man7/CREATE_DATABASE.7 @@ -0,0 +1,234 @@ +'\" t +.\" Title: CREATE DATABASE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE DATABASE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_DATABASE \- create a new database +.\" CREATE DATABASE +.SH "SYNOPSIS" +.sp +.nf +CREATE DATABASE \fIname\fR + [ [ WITH ] [ OWNER [=] \fIuser_name\fR ] + [ TEMPLATE [=] \fItemplate\fR ] + [ ENCODING [=] \fIencoding\fR ] + [ LC_COLLATE [=] \fIlc_collate\fR ] + [ LC_CTYPE [=] \fIlc_ctype\fR ] + [ TABLESPACE [=] \fItablespace_name\fR ] + [ CONNECTION LIMIT [=] \fIconnlimit\fR ] ] +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE DATABASE\fR +creates a new +PostgreSQL +database\&. +.PP +To create a database, you must be a superuser or have the special +CREATEDB +privilege\&. See +CREATE USER (\fBCREATE_USER\fR(7))\&. +.PP +By default, the new database will be created by cloning the standard system database +template1\&. A different template can be specified by writing +TEMPLATE \fIname\fR\&. In particular, by writing +TEMPLATE template0, you can create a virgin database containing only the standard objects predefined by your version of +PostgreSQL\&. This is useful if you wish to avoid copying any installation\-local objects that might have been added to +template1\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name of a database to create\&. +.RE +.PP +\fIuser_name\fR +.RS 4 +The role name of the user who will own the new database, or +DEFAULT +to use the default (namely, the user executing the command)\&. To create a database owned by another role, you must be a direct or indirect member of that role, or be a superuser\&. +.RE +.PP +\fItemplate\fR +.RS 4 +The name of the template from which to create the new database, or +DEFAULT +to use the default template (template1)\&. +.RE +.PP +\fIencoding\fR +.RS 4 +Character set encoding to use in the new database\&. Specify a string constant (e\&.g\&., +\*(AqSQL_ASCII\*(Aq), or an integer encoding number, or +DEFAULT +to use the default encoding (namely, the encoding of the template database)\&. The character sets supported by the +PostgreSQL +server are described in +Section 22.3.1, \(lqSupported Character Sets\(rq, in the documentation\&. See below for additional restrictions\&. +.RE +.PP +\fIlc_collate\fR +.RS 4 +Collation order (LC_COLLATE) to use in the new database\&. This affects the sort order applied to strings, e\&.g\&. in queries with ORDER BY, as well as the order used in indexes on text columns\&. The default is to use the collation order of the template database\&. See below for additional restrictions\&. +.RE +.PP +\fIlc_ctype\fR +.RS 4 +Character classification (LC_CTYPE) to use in the new database\&. This affects the categorization of characters, e\&.g\&. lower, upper and digit\&. The default is to use the character classification of the template database\&. See below for additional restrictions\&. +.RE +.PP +\fItablespace_name\fR +.RS 4 +The name of the tablespace that will be associated with the new database, or +DEFAULT +to use the template database\*(Aqs tablespace\&. This tablespace will be the default tablespace used for objects created in this database\&. See +CREATE TABLESPACE (\fBCREATE_TABLESPACE\fR(7)) +for more information\&. +.RE +.PP +\fIconnlimit\fR +.RS 4 +How many concurrent connections can be made to this database\&. \-1 (the default) means no limit\&. +.RE +.PP +Optional parameters can be written in any order, not only the order illustrated above\&. +.SH "NOTES" +.PP + +\fBCREATE DATABASE\fR +cannot be executed inside a transaction block\&. +.PP +Errors along the line of +\(lqcould not initialize database directory\(rq +are most likely related to insufficient permissions on the data directory, a full disk, or other file system problems\&. +.PP +Use +DROP DATABASE (\fBDROP_DATABASE\fR(7)) +to remove a database\&. +.PP +The program +\fBcreatedb\fR(1) +is a wrapper program around this command, provided for convenience\&. +.PP +Although it is possible to copy a database other than +template1 +by specifying its name as the template, this is not (yet) intended as a general\-purpose +\(lq\fBCOPY DATABASE\fR\(rq +facility\&. The principal limitation is that no other sessions can be connected to the template database while it is being copied\&. +\fBCREATE DATABASE\fR +will fail if any other connection exists when it starts; otherwise, new connections to the template database are locked out until +\fBCREATE DATABASE\fR +completes\&. See +Section 21.3, \(lqTemplate Databases\(rq, in the documentation +for more information\&. +.PP +The character set encoding specified for the new database must be compatible with the chosen locale settings (LC_COLLATE +and +LC_CTYPE)\&. If the locale is +C +(or equivalently +POSIX), then all encodings are allowed, but for other locale settings there is only one encoding that will work properly\&. (On Windows, however, UTF\-8 encoding can be used with any locale\&.) +\fBCREATE DATABASE\fR +will allow superusers to specify +SQL_ASCII +encoding regardless of the locale settings, but this choice is deprecated and may result in misbehavior of character\-string functions if data that is not encoding\-compatible with the locale is stored in the database\&. +.PP +The encoding and locale settings must match those of the template database, except when +template0 +is used as template\&. This is because other databases might contain data that does not match the specified encoding, or might contain indexes whose sort ordering is affected by +LC_COLLATE +and +LC_CTYPE\&. Copying such data would result in a database that is corrupt according to the new settings\&. +template0, however, is known to not contain any data or indexes that would be affected\&. +.PP +The +CONNECTION LIMIT +option is only enforced approximately; if two new sessions start at about the same time when just one connection +\(lqslot\(rq +remains for the database, it is possible that both will fail\&. Also, the limit is not enforced against superusers\&. +.SH "EXAMPLES" +.PP +To create a new database: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE DATABASE lusiadas; +.fi +.if n \{\ +.RE +.\} +.PP +To create a database +sales +owned by user +salesapp +with a default tablespace of +salesspace: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE DATABASE sales OWNER salesapp TABLESPACE salesspace; +.fi +.if n \{\ +.RE +.\} +.PP +To create a database +music +which supports the ISO\-8859\-1 character set: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE DATABASE music ENCODING \*(AqLATIN1\*(Aq TEMPLATE template0; +.fi +.if n \{\ +.RE +.\} +.sp +In this example, the +TEMPLATE template0 +clause would only be required if +template1\*(Aqs encoding is not ISO\-8859\-1\&. Note that changing encoding might require selecting new +LC_COLLATE +and +LC_CTYPE +settings as well\&. +.SH "COMPATIBILITY" +.PP +There is no +\fBCREATE DATABASE\fR +statement in the SQL standard\&. Databases are equivalent to catalogs, whose creation is implementation\-defined\&. +.SH "SEE ALSO" +ALTER DATABASE (\fBALTER_DATABASE\fR(7)), DROP DATABASE (\fBDROP_DATABASE\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_DOMAIN.7 b/doc/src/sgml/man7/CREATE_DOMAIN.7 new file mode 100644 index 000000000..7d5d90b3b --- /dev/null +++ b/doc/src/sgml/man7/CREATE_DOMAIN.7 @@ -0,0 +1,152 @@ +'\" t +.\" Title: CREATE DOMAIN +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE DOMAIN" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_DOMAIN \- define a new domain +.\" CREATE DOMAIN +.SH "SYNOPSIS" +.sp +.nf +CREATE DOMAIN \fIname\fR [ AS ] \fIdata_type\fR + [ COLLATE \fIcollation\fR ] + [ DEFAULT \fIexpression\fR ] + [ \fIconstraint\fR [ \&.\&.\&. ] ] + +where \fIconstraint\fR is: + +[ CONSTRAINT \fIconstraint_name\fR ] +{ NOT NULL | NULL | CHECK (\fIexpression\fR) } +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE DOMAIN\fR +creates a new domain\&. A domain is essentially a data type with optional constraints (restrictions on the allowed set of values)\&. The user who defines a domain becomes its owner\&. +.PP +If a schema name is given (for example, +CREATE DOMAIN myschema\&.mydomain \&.\&.\&.) then the domain is created in the specified schema\&. Otherwise it is created in the current schema\&. The domain name must be unique among the types and domains existing in its schema\&. +.PP +Domains are useful for abstracting common constraints on fields into a single location for maintenance\&. For example, several tables might contain email address columns, all requiring the same CHECK constraint to verify the address syntax\&. Define a domain rather than setting up each table\*(Aqs constraint individually\&. +.PP +To be able to create a domain, you must have +USAGE +privilege on the underlying type\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of a domain to be created\&. +.RE +.PP +\fIdata_type\fR +.RS 4 +The underlying data type of the domain\&. This can include array specifiers\&. +.RE +.PP +\fIcollation\fR +.RS 4 +An optional collation for the domain\&. If no collation is specified, the underlying data type\*(Aqs default collation is used\&. The underlying type must be collatable if +COLLATE +is specified\&. +.RE +.PP +DEFAULT \fIexpression\fR +.RS 4 +The +DEFAULT +clause specifies a default value for columns of the domain data type\&. The value is any variable\-free expression (but subqueries are not allowed)\&. The data type of the default expression must match the data type of the domain\&. If no default value is specified, then the default value is the null value\&. +.sp +The default expression will be used in any insert operation that does not specify a value for the column\&. If a default value is defined for a particular column, it overrides any default associated with the domain\&. In turn, the domain default overrides any default value associated with the underlying data type\&. +.RE +.PP +CONSTRAINT \fIconstraint_name\fR +.RS 4 +An optional name for a constraint\&. If not specified, the system generates a name\&. +.RE +.PP +NOT NULL +.RS 4 +Values of this domain are normally prevented from being null\&. However, it is still possible for a domain with this constraint to take a null value if it is assigned a matching domain type that has become null, e\&.g\&. via a LEFT OUTER JOIN, or +\fBINSERT INTO tab (domcol) VALUES ((SELECT domcol FROM tab WHERE false))\fR\&. +.RE +.PP +NULL +.RS 4 +Values of this domain are allowed to be null\&. This is the default\&. +.sp +This clause is only intended for compatibility with nonstandard SQL databases\&. Its use is discouraged in new applications\&. +.RE +.PP +CHECK (\fIexpression\fR) +.RS 4 +CHECK +clauses specify integrity constraints or tests which values of the domain must satisfy\&. Each constraint must be an expression producing a Boolean result\&. It should use the key word +VALUE +to refer to the value being tested\&. +.sp +Currently, +CHECK +expressions cannot contain subqueries nor refer to variables other than +VALUE\&. +.RE +.SH "EXAMPLES" +.PP +This example creates the +us_postal_code +data type and then uses the type in a table definition\&. A regular expression test is used to verify that the value looks like a valid US postal code: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE DOMAIN us_postal_code AS TEXT +CHECK( + VALUE ~ \*(Aq^\ed{5}$\*(Aq +OR VALUE ~ \*(Aq^\ed{5}\-\ed{4}$\*(Aq +); + +CREATE TABLE us_snail_addy ( + address_id SERIAL PRIMARY KEY, + street1 TEXT NOT NULL, + street2 TEXT, + street3 TEXT, + city TEXT NOT NULL, + postal us_postal_code NOT NULL +); +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +The command +\fBCREATE DOMAIN\fR +conforms to the SQL standard\&. +.SH "SEE ALSO" +ALTER DOMAIN (\fBALTER_DOMAIN\fR(7)), DROP DOMAIN (\fBDROP_DOMAIN\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_EXTENSION.7 b/doc/src/sgml/man7/CREATE_EXTENSION.7 new file mode 100644 index 000000000..3918920d5 --- /dev/null +++ b/doc/src/sgml/man7/CREATE_EXTENSION.7 @@ -0,0 +1,162 @@ +'\" t +.\" Title: CREATE EXTENSION +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE EXTENSION" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_EXTENSION \- install an extension +.\" CREATE EXTENSION +.SH "SYNOPSIS" +.sp +.nf +CREATE EXTENSION [ IF NOT EXISTS ] \fIextension_name\fR + [ WITH ] [ SCHEMA \fIschema_name\fR ] + [ VERSION \fIversion\fR ] + [ FROM \fIold_version\fR ] +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE EXTENSION\fR +loads a new extension into the current database\&. There must not be an extension of the same name already loaded\&. +.PP +Loading an extension essentially amounts to running the extension\*(Aqs script file\&. The script will typically create new +SQL +objects such as functions, data types, operators and index support methods\&. +\fBCREATE EXTENSION\fR +additionally records the identities of all the created objects, so that they can be dropped again if +\fBDROP EXTENSION\fR +is issued\&. +.PP +Loading an extension requires the same privileges that would be required to create its component objects\&. For most extensions this means superuser or database owner privileges are needed\&. The user who runs +\fBCREATE EXTENSION\fR +becomes the owner of the extension for purposes of later privilege checks, as well as the owner of any objects created by the extension\*(Aqs script\&. +.SH "PARAMETERS" +.PP +IF NOT EXISTS +.RS 4 +Do not throw an error if an extension with the same name already exists\&. A notice is issued in this case\&. Note that there is no guarantee that the existing extension is anything like the one that would have been created from the currently\-available script file\&. +.RE +.PP +\fIextension_name\fR +.RS 4 +The name of the extension to be installed\&. +PostgreSQL +will create the extension using details from the file +SHAREDIR/extension/\fIextension_name\fR\&.control\&. +.RE +.PP +\fIschema_name\fR +.RS 4 +The name of the schema in which to install the extension\*(Aqs objects, given that the extension allows its contents to be relocated\&. The named schema must already exist\&. If not specified, and the extension\*(Aqs control file does not specify a schema either, the current default object creation schema is used\&. +.RE +.PP +\fIversion\fR +.RS 4 +The version of the extension to install\&. This can be written as either an identifier or a string literal\&. The default version is whatever is specified in the extension\*(Aqs control file\&. +.RE +.PP +\fIold_version\fR +.RS 4 +FROM +\fIold_version\fR +must be specified when, and only when, you are attempting to install an extension that replaces an +\(lqold style\(rq +module that is just a collection of objects not packaged into an extension\&. This option causes +\fBCREATE EXTENSION\fR +to run an alternative installation script that absorbs the existing objects into the extension, instead of creating new objects\&. Be careful that +SCHEMA +specifies the schema containing these pre\-existing objects\&. +.sp +The value to use for +\fIold_version\fR +is determined by the extension\*(Aqs author, and might vary if there is more than one version of the old\-style module that can be upgraded into an extension\&. For the standard additional modules supplied with pre\-9\&.1 +PostgreSQL, use +unpackaged +for +\fIold_version\fR +when updating a module to extension style\&. +.RE +.SH "NOTES" +.PP +Before you can use +\fBCREATE EXTENSION\fR +to load an extension into a database, the extension\*(Aqs supporting files must be installed\&. Information about installing the extensions supplied with +PostgreSQL +can be found in +Additional Supplied Modules\&. +.PP +The extensions currently available for loading can be identified from the +pg_available_extensions +or +pg_available_extension_versions +system views\&. +.PP +For information about writing new extensions, see +Section 35.15, \(lqPackaging Related Objects into an Extension\(rq, in the documentation\&. +.SH "EXAMPLES" +.PP +Install the +hstore +extension into the current database: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE EXTENSION hstore; +.fi +.if n \{\ +.RE +.\} +.PP +Update a pre\-9\&.1 installation of +hstore +into extension style: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE EXTENSION hstore SCHEMA public FROM unpackaged; +.fi +.if n \{\ +.RE +.\} +.sp +Be careful to specify the schema in which you installed the existing +hstore +objects\&. +.SH "COMPATIBILITY" +.PP + +\fBCREATE EXTENSION\fR +is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +ALTER EXTENSION (\fBALTER_EXTENSION\fR(7)), DROP EXTENSION (\fBDROP_EXTENSION\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_FOREIGN_DATA_WRAPPER.7 b/doc/src/sgml/man7/CREATE_FOREIGN_DATA_WRAPPER.7 new file mode 100644 index 000000000..b71f956b9 --- /dev/null +++ b/doc/src/sgml/man7/CREATE_FOREIGN_DATA_WRAPPER.7 @@ -0,0 +1,150 @@ +'\" t +.\" Title: CREATE FOREIGN DATA WRAPPER +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE FOREIGN DATA WRAPPER" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_FOREIGN_DATA_WRAPPER \- define a new foreign\-data wrapper +.\" CREATE FOREIGN DATA WRAPPER +.SH "SYNOPSIS" +.sp +.nf +CREATE FOREIGN DATA WRAPPER \fIname\fR + [ HANDLER \fIhandler_function\fR | NO HANDLER ] + [ VALIDATOR \fIvalidator_function\fR | NO VALIDATOR ] + [ OPTIONS ( \fIoption\fR \*(Aq\fIvalue\fR\*(Aq [, \&.\&.\&. ] ) ] +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE FOREIGN DATA WRAPPER\fR +creates a new foreign\-data wrapper\&. The user who defines a foreign\-data wrapper becomes its owner\&. +.PP +The foreign\-data wrapper name must be unique within the database\&. +.PP +Only superusers can create foreign\-data wrappers\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name of the foreign\-data wrapper to be created\&. +.RE +.PP +HANDLER \fIhandler_function\fR +.RS 4 +\fIhandler_function\fR +is the name of a previously registered function that will be called to retrieve the execution functions for foreign tables\&. The handler function must take no arguments, and its return type must be +fdw_handler\&. +.sp +It is possible to create a foreign\-data wrapper with no handler function, but foreign tables using such a wrapper can only be declared, not accessed\&. +.RE +.PP +VALIDATOR \fIvalidator_function\fR +.RS 4 +\fIvalidator_function\fR +is the name of a previously registered function that will be called to check the generic options given to the foreign\-data wrapper, as well as options for foreign servers and user mappings using the foreign\-data wrapper\&. If no validator function or +NO VALIDATOR +is specified, then options will not be checked at creation time\&. (Foreign\-data wrappers will possibly ignore or reject invalid option specifications at run time, depending on the implementation\&.) The validator function must take two arguments: one of type +text[], which will contain the array of options as stored in the system catalogs, and one of type +oid, which will be the OID of the system catalog containing the options\&. The return type is ignored; the function should report invalid options using the +\fBereport(ERROR)\fR +function\&. +.RE +.PP +OPTIONS ( \fIoption\fR \*(Aq\fIvalue\fR\*(Aq [, \&.\&.\&. ] ) +.RS 4 +This clause specifies options for the new foreign\-data wrapper\&. The allowed option names and values are specific to each foreign data wrapper and are validated using the foreign\-data wrapper\*(Aqs validator function\&. Option names must be unique\&. +.RE +.SH "NOTES" +.PP +At the moment, the foreign\-data wrapper functionality is rudimentary\&. There is no support for updating a foreign table, and optimization of queries is primitive (and mostly left to the wrapper, too)\&. +.PP +There is one built\-in foreign\-data wrapper validator function provided: +postgresql_fdw_validator, which accepts options corresponding to +libpq +connection parameters\&. +.SH "EXAMPLES" +.PP +Create a useless foreign\-data wrapper +dummy: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE FOREIGN DATA WRAPPER dummy; +.fi +.if n \{\ +.RE +.\} +.PP +Create a foreign\-data wrapper +file +with handler function +file_fdw_handler: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE FOREIGN DATA WRAPPER file HANDLER file_fdw_handler; +.fi +.if n \{\ +.RE +.\} +.PP +Create a foreign\-data wrapper +mywrapper +with some options: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE FOREIGN DATA WRAPPER mywrapper + OPTIONS (debug \*(Aqtrue\*(Aq); +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBCREATE FOREIGN DATA WRAPPER\fR +conforms to ISO/IEC 9075\-9 (SQL/MED), with the exception that the +HANDLER +and +VALIDATOR +clauses are extensions and the standard clauses +LIBRARY +and +LANGUAGE +are not implemented in PostgreSQL\&. +.PP +Note, however, that the SQL/MED functionality as a whole is not yet conforming\&. +.SH "SEE ALSO" +ALTER FOREIGN DATA WRAPPER (\fBALTER_FOREIGN_DATA_WRAPPER\fR(7)), DROP FOREIGN DATA WRAPPER (\fBDROP_FOREIGN_DATA_WRAPPER\fR(7)), CREATE SERVER (\fBCREATE_SERVER\fR(7)), CREATE USER MAPPING (\fBCREATE_USER_MAPPING\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_FOREIGN_TABLE.7 b/doc/src/sgml/man7/CREATE_FOREIGN_TABLE.7 new file mode 100644 index 000000000..f782c2d8c --- /dev/null +++ b/doc/src/sgml/man7/CREATE_FOREIGN_TABLE.7 @@ -0,0 +1,139 @@ +'\" t +.\" Title: CREATE FOREIGN TABLE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE FOREIGN TABLE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_FOREIGN_TABLE \- define a new foreign table +.\" CREATE FOREIGN TABLE +.SH "SYNOPSIS" +.sp +.nf +CREATE FOREIGN TABLE [ IF NOT EXISTS ] \fItable_name\fR ( [ + { \fIcolumn_name\fR \fIdata_type\fR [ OPTIONS ( \fIoption\fR \*(Aq\fIvalue\fR\*(Aq [, \&.\&.\&. ] ) ] [ NULL | NOT NULL ] } + [, \&.\&.\&. ] +] ) + SERVER \fIserver_name\fR +[ OPTIONS ( \fIoption\fR \*(Aq\fIvalue\fR\*(Aq [, \&.\&.\&. ] ) ] +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE FOREIGN TABLE\fR +will create a new foreign table in the current database\&. The table will be owned by the user issuing the command\&. +.PP +If a schema name is given (for example, +CREATE FOREIGN TABLE myschema\&.mytable \&.\&.\&.) then the table is created in the specified schema\&. Otherwise it is created in the current schema\&. The name of the foreign table must be distinct from the name of any other foreign table, table, sequence, index, or view in the same schema\&. +.PP + +\fBCREATE FOREIGN TABLE\fR +also automatically creates a data type that represents the composite type corresponding to one row of the foreign table\&. Therefore, foreign tables cannot have the same name as any existing data type in the same schema\&. +.PP +To be able to create a table, you must have +USAGE +privilege on all column types\&. +.SH "PARAMETERS" +.PP +IF NOT EXISTS +.RS 4 +Do not throw an error if a relation with the same name already exists\&. A notice is issued in this case\&. Note that there is no guarantee that the existing relation is anything like the one that would have been created\&. +.RE +.PP +\fItable_name\fR +.RS 4 +The name (optionally schema\-qualified) of the table to be created\&. +.RE +.PP +\fIcolumn_name\fR +.RS 4 +The name of a column to be created in the new table\&. +.RE +.PP +\fIdata_type\fR +.RS 4 +The data type of the column\&. This can include array specifiers\&. For more information on the data types supported by +PostgreSQL, refer to +Chapter 8, Data Types, in the documentation\&. +.RE +.PP +NOT NULL +.RS 4 +The column is not allowed to contain null values\&. +.RE +.PP +NULL +.RS 4 +The column is allowed to contain null values\&. This is the default\&. +.sp +This clause is only provided for compatibility with non\-standard SQL databases\&. Its use is discouraged in new applications\&. +.RE +.PP +\fIserver_name\fR +.RS 4 +The name of an existing server for the foreign table\&. +.RE +.PP +OPTIONS ( \fIoption\fR \*(Aq\fIvalue\fR\*(Aq [, \&.\&.\&.] ) +.RS 4 +Options to be associated with the new foreign table or one of its columns\&. The allowed option names and values are specific to each foreign data wrapper and are validated using the foreign\-data wrapper\*(Aqs validator function\&. Duplicate option names are not allowed (although it\*(Aqs OK for a table option and a column option to have the same name)\&. +.RE +.SH "EXAMPLES" +.PP +Create foreign table +films +with +film_server: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE FOREIGN TABLE films ( + code char(5) NOT NULL, + title varchar(40) NOT NULL, + did integer NOT NULL, + date_prod date, + kind varchar(10), + len interval hour to minute +) +SERVER film_server; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +The +\fBCREATE FOREIGN TABLE\fR +command largely conforms to the +SQL +standard; however, much as with +\fBCREATE TABLE\fR, +NULL +constraints and zero\-column foreign tables are permitted\&. +.SH "SEE ALSO" +ALTER FOREIGN TABLE (\fBALTER_FOREIGN_TABLE\fR(7)), DROP FOREIGN TABLE (\fBDROP_FOREIGN_TABLE\fR(7)), CREATE TABLE (\fBCREATE_TABLE\fR(7)), CREATE SERVER (\fBCREATE_SERVER\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_FUNCTION.7 b/doc/src/sgml/man7/CREATE_FUNCTION.7 new file mode 100644 index 000000000..41c599ac4 --- /dev/null +++ b/doc/src/sgml/man7/CREATE_FUNCTION.7 @@ -0,0 +1,590 @@ +'\" t +.\" Title: CREATE FUNCTION +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE FUNCTION" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_FUNCTION \- define a new function +.\" CREATE FUNCTION +.SH "SYNOPSIS" +.sp +.nf +CREATE [ OR REPLACE ] FUNCTION + \fIname\fR ( [ [ \fIargmode\fR ] [ \fIargname\fR ] \fIargtype\fR [ { DEFAULT | = } \fIdefault_expr\fR ] [, \&.\&.\&.] ] ) + [ RETURNS \fIrettype\fR + | RETURNS TABLE ( \fIcolumn_name\fR \fIcolumn_type\fR [, \&.\&.\&.] ) ] + { LANGUAGE \fIlang_name\fR + | WINDOW + | IMMUTABLE | STABLE | VOLATILE | [ NOT ] LEAKPROOF + | CALLED ON NULL INPUT | RETURNS NULL ON NULL INPUT | STRICT + | [ EXTERNAL ] SECURITY INVOKER | [ EXTERNAL ] SECURITY DEFINER + | COST \fIexecution_cost\fR + | ROWS \fIresult_rows\fR + | SET \fIconfiguration_parameter\fR { TO \fIvalue\fR | = \fIvalue\fR | FROM CURRENT } + | AS \*(Aq\fIdefinition\fR\*(Aq + | AS \*(Aq\fIobj_file\fR\*(Aq, \*(Aq\fIlink_symbol\fR\*(Aq + } \&.\&.\&. + [ WITH ( \fIattribute\fR [, \&.\&.\&.] ) ] +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE FUNCTION\fR +defines a new function\&. +\fBCREATE OR REPLACE FUNCTION\fR +will either create a new function, or replace an existing definition\&. To be able to define a function, the user must have the +USAGE +privilege on the language\&. +.PP +If a schema name is included, then the function is created in the specified schema\&. Otherwise it is created in the current schema\&. The name of the new function must not match any existing function with the same input argument types in the same schema\&. However, functions of different argument types can share a name (this is called +overloading)\&. +.PP +To replace the current definition of an existing function, use +\fBCREATE OR REPLACE FUNCTION\fR\&. It is not possible to change the name or argument types of a function this way (if you tried, you would actually be creating a new, distinct function)\&. Also, +\fBCREATE OR REPLACE FUNCTION\fR +will not let you change the return type of an existing function\&. To do that, you must drop and recreate the function\&. (When using +OUT +parameters, that means you cannot change the types of any +OUT +parameters except by dropping the function\&.) +.PP +When +\fBCREATE OR REPLACE FUNCTION\fR +is used to replace an existing function, the ownership and permissions of the function do not change\&. All other function properties are assigned the values specified or implied in the command\&. You must own the function to replace it (this includes being a member of the owning role)\&. +.PP +If you drop and then recreate a function, the new function is not the same entity as the old; you will have to drop existing rules, views, triggers, etc\&. that refer to the old function\&. Use +\fBCREATE OR REPLACE FUNCTION\fR +to change a function definition without breaking objects that refer to the function\&. Also, +\fBALTER FUNCTION\fR +can be used to change most of the auxiliary properties of an existing function\&. +.PP +The user that creates the function becomes the owner of the function\&. +.PP +To be able to create a function, you must have +USAGE +privilege on the argument types and the return type\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of the function to create\&. +.RE +.PP +\fIargmode\fR +.RS 4 +The mode of an argument: +IN, +OUT, +INOUT, or +VARIADIC\&. If omitted, the default is +IN\&. Only +OUT +arguments can follow a +VARIADIC +one\&. Also, +OUT +and +INOUT +arguments cannot be used together with the +RETURNS TABLE +notation\&. +.RE +.PP +\fIargname\fR +.RS 4 +The name of an argument\&. Some languages (currently only PL/pgSQL) let you use the name in the function body\&. For other languages the name of an input argument is just extra documentation, so far as the function itself is concerned; but you can use input argument names when calling a function to improve readability (see +Section 4.3, \(lqCalling Functions\(rq, in the documentation)\&. In any case, the name of an output argument is significant, because it defines the column name in the result row type\&. (If you omit the name for an output argument, the system will choose a default column name\&.) +.RE +.PP +\fIargtype\fR +.RS 4 +The data type(s) of the function\*(Aqs arguments (optionally schema\-qualified), if any\&. The argument types can be base, composite, or domain types, or can reference the type of a table column\&. +.sp +Depending on the implementation language it might also be allowed to specify +\(lqpseudotypes\(rq +such as +cstring\&. Pseudotypes indicate that the actual argument type is either incompletely specified, or outside the set of ordinary SQL data types\&. +.sp +The type of a column is referenced by writing +\fItable_name\fR\&.\fIcolumn_name\fR%TYPE\&. Using this feature can sometimes help make a function independent of changes to the definition of a table\&. +.RE +.PP +\fIdefault_expr\fR +.RS 4 +An expression to be used as default value if the parameter is not specified\&. The expression has to be coercible to the argument type of the parameter\&. Only input (including +INOUT) parameters can have a default value\&. All input parameters following a parameter with a default value must have default values as well\&. +.RE +.PP +\fIrettype\fR +.RS 4 +The return data type (optionally schema\-qualified)\&. The return type can be a base, composite, or domain type, or can reference the type of a table column\&. Depending on the implementation language it might also be allowed to specify +\(lqpseudotypes\(rq +such as +cstring\&. If the function is not supposed to return a value, specify +void +as the return type\&. +.sp +When there are +OUT +or +INOUT +parameters, the +RETURNS +clause can be omitted\&. If present, it must agree with the result type implied by the output parameters: +RECORD +if there are multiple output parameters, or the same type as the single output parameter\&. +.sp +The +SETOF +modifier indicates that the function will return a set of items, rather than a single item\&. +.sp +The type of a column is referenced by writing +\fItable_name\fR\&.\fIcolumn_name\fR%TYPE\&. +.RE +.PP +\fIcolumn_name\fR +.RS 4 +The name of an output column in the +RETURNS TABLE +syntax\&. This is effectively another way of declaring a named +OUT +parameter, except that +RETURNS TABLE +also implies +RETURNS SETOF\&. +.RE +.PP +\fIcolumn_type\fR +.RS 4 +The data type of an output column in the +RETURNS TABLE +syntax\&. +.RE +.PP +\fIlang_name\fR +.RS 4 +The name of the language that the function is implemented in\&. Can be +SQL, +C, +internal, or the name of a user\-defined procedural language\&. For backward compatibility, the name can be enclosed by single quotes\&. +.RE +.PP +WINDOW +.RS 4 +WINDOW +indicates that the function is a +window function +rather than a plain function\&. This is currently only useful for functions written in C\&. The +WINDOW +attribute cannot be changed when replacing an existing function definition\&. +.RE +.PP +IMMUTABLE, STABLE, VOLATILE +.RS 4 +These attributes inform the query optimizer about the behavior of the function\&. At most one choice can be specified\&. If none of these appear, +VOLATILE +is the default assumption\&. +.sp +IMMUTABLE +indicates that the function cannot modify the database and always returns the same result when given the same argument values; that is, it does not do database lookups or otherwise use information not directly present in its argument list\&. If this option is given, any call of the function with all\-constant arguments can be immediately replaced with the function value\&. +.sp +STABLE +indicates that the function cannot modify the database, and that within a single table scan it will consistently return the same result for the same argument values, but that its result could change across SQL statements\&. This is the appropriate selection for functions whose results depend on database lookups, parameter variables (such as the current time zone), etc\&. (It is inappropriate for +AFTER +triggers that wish to query rows modified by the current command\&.) Also note that the +\fBcurrent_timestamp\fR +family of functions qualify as stable, since their values do not change within a transaction\&. +.sp +VOLATILE +indicates that the function value can change even within a single table scan, so no optimizations can be made\&. Relatively few database functions are volatile in this sense; some examples are +random(), +currval(), +timeofday()\&. But note that any function that has side\-effects must be classified volatile, even if its result is quite predictable, to prevent calls from being optimized away; an example is +setval()\&. +.sp +For additional details see +Section 35.6, \(lqFunction Volatility Categories\(rq, in the documentation\&. +.RE +.PP +LEAKPROOF +.RS 4 + +LEAKPROOF +indicates that the function has no side effects\&. It reveals no information about its arguments other than by its return value\&. For example, a function which throws an error message for some argument values but not others, or which includes the argument values in any error message, is not leakproof\&. The query planner may push leakproof functions (but not others) into views created with the +security_barrier +option\&. See +CREATE VIEW (\fBCREATE_VIEW\fR(7)) +and +Section 37.4, \(lqRules and Privileges\(rq, in the documentation\&. This option can only be set by the superuser\&. +.RE +.PP +CALLED ON NULL INPUT, RETURNS NULL ON NULL INPUT, STRICT +.RS 4 +CALLED ON NULL INPUT +(the default) indicates that the function will be called normally when some of its arguments are null\&. It is then the function author\*(Aqs responsibility to check for null values if necessary and respond appropriately\&. +.sp +RETURNS NULL ON NULL INPUT +or +STRICT +indicates that the function always returns null whenever any of its arguments are null\&. If this parameter is specified, the function is not executed when there are null arguments; instead a null result is assumed automatically\&. +.RE +.PP +[EXTERNAL] SECURITY INVOKER, [EXTERNAL] SECURITY DEFINER +.RS 4 +SECURITY INVOKER +indicates that the function is to be executed with the privileges of the user that calls it\&. That is the default\&. +SECURITY DEFINER +specifies that the function is to be executed with the privileges of the user that created it\&. +.sp +The key word +EXTERNAL +is allowed for SQL conformance, but it is optional since, unlike in SQL, this feature applies to all functions not only external ones\&. +.RE +.PP +\fIexecution_cost\fR +.RS 4 +A positive number giving the estimated execution cost for the function, in units of +cpu_operator_cost\&. If the function returns a set, this is the cost per returned row\&. If the cost is not specified, 1 unit is assumed for C\-language and internal functions, and 100 units for functions in all other languages\&. Larger values cause the planner to try to avoid evaluating the function more often than necessary\&. +.RE +.PP +\fIresult_rows\fR +.RS 4 +A positive number giving the estimated number of rows that the planner should expect the function to return\&. This is only allowed when the function is declared to return a set\&. The default assumption is 1000 rows\&. +.RE +.PP +\fIconfiguration_parameter\fR, \fIvalue\fR +.RS 4 +The +SET +clause causes the specified configuration parameter to be set to the specified value when the function is entered, and then restored to its prior value when the function exits\&. +SET FROM CURRENT +saves the session\*(Aqs current value of the parameter as the value to be applied when the function is entered\&. +.sp +If a +SET +clause is attached to a function, then the effects of a +\fBSET LOCAL\fR +command executed inside the function for the same variable are restricted to the function: the configuration parameter\*(Aqs prior value is still restored at function exit\&. However, an ordinary +\fBSET\fR +command (without +LOCAL) overrides the +SET +clause, much as it would do for a previous +\fBSET LOCAL\fR +command: the effects of such a command will persist after function exit, unless the current transaction is rolled back\&. +.sp +See +\fBSET\fR(7) +and +Chapter 18, Server Configuration, in the documentation +for more information about allowed parameter names and values\&. +.RE +.PP +\fIdefinition\fR +.RS 4 +A string constant defining the function; the meaning depends on the language\&. It can be an internal function name, the path to an object file, an SQL command, or text in a procedural language\&. +.sp +It is often helpful to use dollar quoting (see +Section 4.1.2.4, \(lqDollar-quoted String Constants\(rq, in the documentation) to write the function definition string, rather than the normal single quote syntax\&. Without dollar quoting, any single quotes or backslashes in the function definition must be escaped by doubling them\&. +.RE +.PP +\fIobj_file\fR, \fIlink_symbol\fR +.RS 4 +This form of the +AS +clause is used for dynamically loadable C language functions when the function name in the C language source code is not the same as the name of the SQL function\&. The string +\fIobj_file\fR +is the name of the file containing the dynamically loadable object, and +\fIlink_symbol\fR +is the function\*(Aqs link symbol, that is, the name of the function in the C language source code\&. If the link symbol is omitted, it is assumed to be the same as the name of the SQL function being defined\&. +.sp +When repeated +\fBCREATE FUNCTION\fR +calls refer to the same object file, the file is only loaded once per session\&. To unload and reload the file (perhaps during development), start a new session\&. +.RE +.PP +\fIattribute\fR +.RS 4 +The historical way to specify optional pieces of information about the function\&. The following attributes can appear here: +.PP +isStrict +.RS 4 +Equivalent to +STRICT +or +RETURNS NULL ON NULL INPUT\&. +.RE +.PP +isCachable +.RS 4 +isCachable +is an obsolete equivalent of +IMMUTABLE; it\*(Aqs still accepted for backwards\-compatibility reasons\&. +.RE +.sp +Attribute names are not case\-sensitive\&. +.RE +.PP +Refer to +Section 35.3, \(lqUser-defined Functions\(rq, in the documentation +for further information on writing functions\&. +.SH "OVERLOADING" +.PP + +PostgreSQL +allows function +overloading; that is, the same name can be used for several different functions so long as they have distinct input argument types\&. However, the C names of all functions must be different, so you must give overloaded C functions different C names (for example, use the argument types as part of the C names)\&. +.PP +Two functions are considered the same if they have the same names and +\fIinput\fR +argument types, ignoring any +OUT +parameters\&. Thus for example these declarations conflict: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE FUNCTION foo(int) \&.\&.\&. +CREATE FUNCTION foo(int, out text) \&.\&.\&. +.fi +.if n \{\ +.RE +.\} +.PP +Functions that have different argument type lists will not be considered to conflict at creation time, but if defaults are provided they might conflict in use\&. For example, consider +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE FUNCTION foo(int) \&.\&.\&. +CREATE FUNCTION foo(int, int default 42) \&.\&.\&. +.fi +.if n \{\ +.RE +.\} +.sp +A call +foo(10) +will fail due to the ambiguity about which function should be called\&. +.SH "NOTES" +.PP +The full +SQL +type syntax is allowed for input arguments and return value\&. However, some details of the type specification (e\&.g\&., the precision field for type +numeric) are the responsibility of the underlying function implementation and are silently swallowed (i\&.e\&., not recognized or enforced) by the +\fBCREATE FUNCTION\fR +command\&. +.PP +When replacing an existing function with +\fBCREATE OR REPLACE FUNCTION\fR, there are restrictions on changing parameter names\&. You cannot change the name already assigned to any input parameter (although you can add names to parameters that had none before)\&. If there is more than one output parameter, you cannot change the names of the output parameters, because that would change the column names of the anonymous composite type that describes the function\*(Aqs result\&. These restrictions are made to ensure that existing calls of the function do not stop working when it is replaced\&. +.PP +If a function is declared +STRICT +with a +VARIADIC +argument, the strictness check tests that the variadic array +\fIas a whole\fR +is non\-null\&. The function will still be called if the array has null elements\&. +.SH "EXAMPLES" +.PP +Here are some trivial examples to help you get started\&. For more information and examples, see +Section 35.3, \(lqUser-defined Functions\(rq, in the documentation\&. +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE FUNCTION add(integer, integer) RETURNS integer + AS \*(Aqselect $1 + $2;\*(Aq + LANGUAGE SQL + IMMUTABLE + RETURNS NULL ON NULL INPUT; +.fi +.if n \{\ +.RE +.\} +.PP +Increment an integer, making use of an argument name, in +PL/pgSQL: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE OR REPLACE FUNCTION increment(i integer) RETURNS integer AS $$ + BEGIN + RETURN i + 1; + END; +$$ LANGUAGE plpgsql; +.fi +.if n \{\ +.RE +.\} +.PP +Return a record containing multiple output parameters: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE FUNCTION dup(in int, out f1 int, out f2 text) + AS $$ SELECT $1, CAST($1 AS text) || \*(Aq is text\*(Aq $$ + LANGUAGE SQL; + +SELECT * FROM dup(42); +.fi +.if n \{\ +.RE +.\} +.sp +You can do the same thing more verbosely with an explicitly named composite type: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TYPE dup_result AS (f1 int, f2 text); + +CREATE FUNCTION dup(int) RETURNS dup_result + AS $$ SELECT $1, CAST($1 AS text) || \*(Aq is text\*(Aq $$ + LANGUAGE SQL; + +SELECT * FROM dup(42); +.fi +.if n \{\ +.RE +.\} +.sp +Another way to return multiple columns is to use a +TABLE +function: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE FUNCTION dup(int) RETURNS TABLE(f1 int, f2 text) + AS $$ SELECT $1, CAST($1 AS text) || \*(Aq is text\*(Aq $$ + LANGUAGE SQL; + +SELECT * FROM dup(42); +.fi +.if n \{\ +.RE +.\} +.sp +However, a +TABLE +function is different from the preceding examples, because it actually returns a +\fIset\fR +of records, not just one record\&. +.SH "WRITING SECURITY DEFINER FUNCTIONS SAFELY" +.PP +Because a +SECURITY DEFINER +function is executed with the privileges of the user that created it, care is needed to ensure that the function cannot be misused\&. For security, +search_path +should be set to exclude any schemas writable by untrusted users\&. This prevents malicious users from creating objects that mask objects used by the function\&. Particularly important in this regard is the temporary\-table schema, which is searched first by default, and is normally writable by anyone\&. A secure arrangement can be had by forcing the temporary schema to be searched last\&. To do this, write +pg_temp +as the last entry in +\fIsearch_path\fR\&. This function illustrates safe usage: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE FUNCTION check_password(uname TEXT, pass TEXT) +RETURNS BOOLEAN AS $$ +DECLARE passed BOOLEAN; +BEGIN + SELECT (pwd = $2) INTO passed + FROM pwds + WHERE username = $1; + + RETURN passed; +END; +$$ LANGUAGE plpgsql + SECURITY DEFINER + \-\- Set a secure search_path: trusted schema(s), then \*(Aqpg_temp\*(Aq\&. + SET search_path = admin, pg_temp; +.fi +.if n \{\ +.RE +.\} +.PP +Before +PostgreSQL +version 8\&.3, the +SET +option was not available, and so older functions may contain rather complicated logic to save, set, and restore +\fIsearch_path\fR\&. The +SET +option is far easier to use for this purpose\&. +.PP +Another point to keep in mind is that by default, execute privilege is granted to +PUBLIC +for newly created functions (see +\fBGRANT\fR(7) +for more information)\&. Frequently you will wish to restrict use of a security definer function to only some users\&. To do that, you must revoke the default +PUBLIC +privileges and then grant execute privilege selectively\&. To avoid having a window where the new function is accessible to all, create it and set the privileges within a single transaction\&. For example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +BEGIN; +CREATE FUNCTION check_password(uname TEXT, pass TEXT) \&.\&.\&. SECURITY DEFINER; +REVOKE ALL ON FUNCTION check_password(uname TEXT, pass TEXT) FROM PUBLIC; +GRANT EXECUTE ON FUNCTION check_password(uname TEXT, pass TEXT) TO admins; +COMMIT; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +A +\fBCREATE FUNCTION\fR +command is defined in SQL:1999 and later\&. The +PostgreSQL +version is similar but not fully compatible\&. The attributes are not portable, neither are the different available languages\&. +.PP +For compatibility with some other database systems, +\fIargmode\fR +can be written either before or after +\fIargname\fR\&. But only the first way is standard\-compliant\&. +.PP +The SQL standard does not specify parameter defaults\&. The syntax with the +DEFAULT +key word is from Oracle, and it is somewhat in the spirit of the standard: SQL/PSM uses it for variable default values\&. The syntax with += +is used in T\-SQL and Firebird\&. +.SH "SEE ALSO" +ALTER FUNCTION (\fBALTER_FUNCTION\fR(7)), DROP FUNCTION (\fBDROP_FUNCTION\fR(7)), \fBGRANT\fR(7), \fBLOAD\fR(7), \fBREVOKE\fR(7), \fBcreatelang\fR(1) diff --git a/doc/src/sgml/man7/CREATE_GROUP.7 b/doc/src/sgml/man7/CREATE_GROUP.7 new file mode 100644 index 000000000..41559f549 --- /dev/null +++ b/doc/src/sgml/man7/CREATE_GROUP.7 @@ -0,0 +1,67 @@ +'\" t +.\" Title: CREATE GROUP +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE GROUP" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_GROUP \- define a new database role +.\" CREATE GROUP +.SH "SYNOPSIS" +.sp +.nf +CREATE GROUP \fIname\fR [ [ WITH ] \fIoption\fR [ \&.\&.\&. ] ] + +where \fIoption\fR can be: + + SUPERUSER | NOSUPERUSER + | CREATEDB | NOCREATEDB + | CREATEROLE | NOCREATEROLE + | CREATEUSER | NOCREATEUSER + | INHERIT | NOINHERIT + | LOGIN | NOLOGIN + | [ ENCRYPTED | UNENCRYPTED ] PASSWORD \*(Aq\fIpassword\fR\*(Aq + | VALID UNTIL \*(Aq\fItimestamp\fR\*(Aq + | IN ROLE \fIrole_name\fR [, \&.\&.\&.] + | IN GROUP \fIrole_name\fR [, \&.\&.\&.] + | ROLE \fIrole_name\fR [, \&.\&.\&.] + | ADMIN \fIrole_name\fR [, \&.\&.\&.] + | USER \fIrole_name\fR [, \&.\&.\&.] + | SYSID \fIuid\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE GROUP\fR +is now an alias for +CREATE ROLE (\fBCREATE_ROLE\fR(7))\&. +.SH "COMPATIBILITY" +.PP +There is no +\fBCREATE GROUP\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +CREATE ROLE (\fBCREATE_ROLE\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_INDEX.7 b/doc/src/sgml/man7/CREATE_INDEX.7 new file mode 100644 index 000000000..0b7c662fa --- /dev/null +++ b/doc/src/sgml/man7/CREATE_INDEX.7 @@ -0,0 +1,523 @@ +'\" t +.\" Title: CREATE INDEX +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE INDEX" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_INDEX \- define a new index +.\" CREATE INDEX +.SH "SYNOPSIS" +.sp +.nf +CREATE [ UNIQUE ] INDEX [ CONCURRENTLY ] [ \fIname\fR ] ON \fItable_name\fR [ USING \fImethod\fR ] + ( { \fIcolumn_name\fR | ( \fIexpression\fR ) } [ COLLATE \fIcollation\fR ] [ \fIopclass\fR ] [ ASC | DESC ] [ NULLS { FIRST | LAST } ] [, \&.\&.\&.] ) + [ WITH ( \fIstorage_parameter\fR = \fIvalue\fR [, \&.\&.\&. ] ) ] + [ TABLESPACE \fItablespace_name\fR ] + [ WHERE \fIpredicate\fR ] +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE INDEX\fR +constructs an index on the specified column(s) of the specified table\&. Indexes are primarily used to enhance database performance (though inappropriate use can result in slower performance)\&. +.PP +The key field(s) for the index are specified as column names, or alternatively as expressions written in parentheses\&. Multiple fields can be specified if the index method supports multicolumn indexes\&. +.PP +An index field can be an expression computed from the values of one or more columns of the table row\&. This feature can be used to obtain fast access to data based on some transformation of the basic data\&. For example, an index computed on +upper(col) +would allow the clause +WHERE upper(col) = \*(AqJIM\*(Aq +to use an index\&. +.PP + +PostgreSQL +provides the index methods B\-tree, hash, GiST, SP\-GiST, and GIN\&. Users can also define their own index methods, but that is fairly complicated\&. +.PP +When the +WHERE +clause is present, a +partial index +is created\&. A partial index is an index that contains entries for only a portion of a table, usually a portion that is more useful for indexing than the rest of the table\&. For example, if you have a table that contains both billed and unbilled orders where the unbilled orders take up a small fraction of the total table and yet that is an often used section, you can improve performance by creating an index on just that portion\&. Another possible application is to use +WHERE +with +UNIQUE +to enforce uniqueness over a subset of a table\&. See +Section 11.8, \(lqPartial Indexes\(rq, in the documentation +for more discussion\&. +.PP +The expression used in the +WHERE +clause can refer only to columns of the underlying table, but it can use all columns, not just the ones being indexed\&. Presently, subqueries and aggregate expressions are also forbidden in +WHERE\&. The same restrictions apply to index fields that are expressions\&. +.PP +All functions and operators used in an index definition must be +\(lqimmutable\(rq, that is, their results must depend only on their arguments and never on any outside influence (such as the contents of another table or the current time)\&. This restriction ensures that the behavior of the index is well\-defined\&. To use a user\-defined function in an index expression or +WHERE +clause, remember to mark the function immutable when you create it\&. +.SH "PARAMETERS" +.PP +UNIQUE +.RS 4 +Causes the system to check for duplicate values in the table when the index is created (if data already exist) and each time data is added\&. Attempts to insert or update data which would result in duplicate entries will generate an error\&. +.RE +.PP +CONCURRENTLY +.RS 4 +When this option is used, +PostgreSQL +will build the index without taking any locks that prevent concurrent inserts, updates, or deletes on the table; whereas a standard index build locks out writes (but not reads) on the table until it\*(Aqs done\&. There are several caveats to be aware of when using this option \(em see +Building Indexes Concurrently\&. +.RE +.PP +\fIname\fR +.RS 4 +The name of the index to be created\&. No schema name can be included here; the index is always created in the same schema as its parent table\&. If the name is omitted, +PostgreSQL +chooses a suitable name based on the parent table\*(Aqs name and the indexed column name(s)\&. +.RE +.PP +\fItable_name\fR +.RS 4 +The name (possibly schema\-qualified) of the table to be indexed\&. +.RE +.PP +\fImethod\fR +.RS 4 +The name of the index method to be used\&. Choices are +btree, +hash, +gist, +spgist +and +gin\&. The default method is +btree\&. +.RE +.PP +\fIcolumn_name\fR +.RS 4 +The name of a column of the table\&. +.RE +.PP +\fIexpression\fR +.RS 4 +An expression based on one or more columns of the table\&. The expression usually must be written with surrounding parentheses, as shown in the syntax\&. However, the parentheses can be omitted if the expression has the form of a function call\&. +.RE +.PP +\fIcollation\fR +.RS 4 +The name of the collation to use for the index\&. By default, the index uses the collation declared for the column to be indexed or the result collation of the expression to be indexed\&. Indexes with non\-default collations can be useful for queries that involve expressions using non\-default collations\&. +.RE +.PP +\fIopclass\fR +.RS 4 +The name of an operator class\&. See below for details\&. +.RE +.PP +ASC +.RS 4 +Specifies ascending sort order (which is the default)\&. +.RE +.PP +DESC +.RS 4 +Specifies descending sort order\&. +.RE +.PP +NULLS FIRST +.RS 4 +Specifies that nulls sort before non\-nulls\&. This is the default when +DESC +is specified\&. +.RE +.PP +NULLS LAST +.RS 4 +Specifies that nulls sort after non\-nulls\&. This is the default when +DESC +is not specified\&. +.RE +.PP +\fIstorage_parameter\fR +.RS 4 +The name of an index\-method\-specific storage parameter\&. See +Index Storage Parameters +for details\&. +.RE +.PP +\fItablespace_name\fR +.RS 4 +The tablespace in which to create the index\&. If not specified, +default_tablespace +is consulted, or +temp_tablespaces +for indexes on temporary tables\&. +.RE +.PP +\fIpredicate\fR +.RS 4 +The constraint expression for a partial index\&. +.RE +.SS "Index Storage Parameters" +.PP +The optional +WITH +clause specifies +storage parameters +for the index\&. Each index method has its own set of allowed storage parameters\&. The B\-tree, hash, GiST and SP\-GiST index methods all accept this parameter: +.PP +FILLFACTOR +.RS 4 +The fillfactor for an index is a percentage that determines how full the index method will try to pack index pages\&. For B\-trees, leaf pages are filled to this percentage during initial index build, and also when extending the index at the right (adding new largest key values)\&. If pages subsequently become completely full, they will be split, leading to gradual degradation in the index\*(Aqs efficiency\&. B\-trees use a default fillfactor of 90, but any integer value from 10 to 100 can be selected\&. If the table is static then fillfactor 100 is best to minimize the index\*(Aqs physical size, but for heavily updated tables a smaller fillfactor is better to minimize the need for page splits\&. The other index methods use fillfactor in different but roughly analogous ways; the default fillfactor varies between methods\&. +.RE +.PP +GiST indexes additionally accept this parameter: +.PP +BUFFERING +.RS 4 +Determines whether the buffering build technique described in +Section 53.3.1, \(lqGiST buffering build\(rq, in the documentation +is used to build the index\&. With +OFF +it is disabled, with +ON +it is enabled, and with +AUTO +it is initially disabled, but turned on on\-the\-fly once the index size reaches +effective_cache_size\&. The default is +AUTO\&. +.RE +.PP +GIN indexes accept a different parameter: +.PP +FASTUPDATE +.RS 4 +This setting controls usage of the fast update technique described in +Section 55.3.1, \(lqGIN Fast Update Technique\(rq, in the documentation\&. It is a Boolean parameter: +ON +enables fast update, +OFF +disables it\&. (Alternative spellings of +ON +and +OFF +are allowed as described in +Section 18.1, \(lqSetting Parameters\(rq, in the documentation\&.) The default is +ON\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +Turning +FASTUPDATE +off via +\fBALTER INDEX\fR +prevents future insertions from going into the list of pending index entries, but does not in itself flush previous entries\&. You might want to +\fBVACUUM\fR +the table afterward to ensure the pending list is emptied\&. +.sp .5v +.RE +.RE +.SS "Building Indexes Concurrently" +.\" index: building concurrently +.PP +Creating an index can interfere with regular operation of a database\&. Normally +PostgreSQL +locks the table to be indexed against writes and performs the entire index build with a single scan of the table\&. Other transactions can still read the table, but if they try to insert, update, or delete rows in the table they will block until the index build is finished\&. This could have a severe effect if the system is a live production database\&. Very large tables can take many hours to be indexed, and even for smaller tables, an index build can lock out writers for periods that are unacceptably long for a production system\&. +.PP + +PostgreSQL +supports building indexes without locking out writes\&. This method is invoked by specifying the +CONCURRENTLY +option of +\fBCREATE INDEX\fR\&. When this option is used, +PostgreSQL +must perform two scans of the table, and in addition it must wait for all existing transactions that could potentially use the index to terminate\&. Thus this method requires more total work than a standard index build and takes significantly longer to complete\&. However, since it allows normal operations to continue while the index is built, this method is useful for adding new indexes in a production environment\&. Of course, the extra CPU and I/O load imposed by the index creation might slow other operations\&. +.PP +In a concurrent index build, the index is actually entered into the system catalogs in one transaction, then two table scans occur in two more transactions\&. Any transaction active when the second table scan starts can block concurrent index creation until it completes, even transactions that only reference the table after the second table scan starts\&. Concurrent index creation serially waits for each old transaction to complete using the method outlined in section +Section 45.58, \(lqpg_locks\(rq, in the documentation\&. +.PP +If a problem arises while scanning the table, such as a uniqueness violation in a unique index, the +\fBCREATE INDEX\fR +command will fail but leave behind an +\(lqinvalid\(rq +index\&. This index will be ignored for querying purposes because it might be incomplete; however it will still consume update overhead\&. The +psql +\fB\ed\fR +command will report such an index as +INVALID: +.sp +.if n \{\ +.RS 4 +.\} +.nf +postgres=# \ed tab + Table "public\&.tab" + Column | Type | Modifiers +\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\- + col | integer | +Indexes: + "idx" btree (col) INVALID +.fi +.if n \{\ +.RE +.\} +.sp +The recommended recovery method in such cases is to drop the index and try again to perform +\fBCREATE INDEX CONCURRENTLY\fR\&. (Another possibility is to rebuild the index with +\fBREINDEX\fR\&. However, since +\fBREINDEX\fR +does not support concurrent builds, this option is unlikely to seem attractive\&.) +.PP +Another caveat when building a unique index concurrently is that the uniqueness constraint is already being enforced against other transactions when the second table scan begins\&. This means that constraint violations could be reported in other queries prior to the index becoming available for use, or even in cases where the index build eventually fails\&. Also, if a failure does occur in the second scan, the +\(lqinvalid\(rq +index continues to enforce its uniqueness constraint afterwards\&. +.PP +Concurrent builds of expression indexes and partial indexes are supported\&. Errors occurring in the evaluation of these expressions could cause behavior similar to that described above for unique constraint violations\&. +.PP +Regular index builds permit other regular index builds on the same table to occur in parallel, but only one concurrent index build can occur on a table at a time\&. In both cases, no other types of schema modification on the table are allowed meanwhile\&. Another difference is that a regular +\fBCREATE INDEX\fR +command can be performed within a transaction block, but +\fBCREATE INDEX CONCURRENTLY\fR +cannot\&. +.SH "NOTES" +.PP +See +Chapter 11, Indexes, in the documentation +for information about when indexes can be used, when they are not used, and in which particular situations they can be useful\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBCaution\fR +.ps -1 +.br +.PP +Hash index operations are not presently WAL\-logged, so hash indexes might need to be rebuilt with +\fBREINDEX\fR +after a database crash if there were unwritten changes\&. Also, changes to hash indexes are not replicated over streaming or file\-based replication after the initial base backup, so they give wrong answers to queries that subsequently use them\&. For these reasons, hash index use is presently discouraged\&. +.sp .5v +.RE +.PP +Currently, only the B\-tree, GiST and GIN index methods support multicolumn indexes\&. Up to 32 fields can be specified by default\&. (This limit can be altered when building +PostgreSQL\&.) Only B\-tree currently supports unique indexes\&. +.PP +An +operator class +can be specified for each column of an index\&. The operator class identifies the operators to be used by the index for that column\&. For example, a B\-tree index on four\-byte integers would use the +int4_ops +class; this operator class includes comparison functions for four\-byte integers\&. In practice the default operator class for the column\*(Aqs data type is usually sufficient\&. The main point of having operator classes is that for some data types, there could be more than one meaningful ordering\&. For example, we might want to sort a complex\-number data type either by absolute value or by real part\&. We could do this by defining two operator classes for the data type and then selecting the proper class when making an index\&. More information about operator classes is in +Section 11.9, \(lqOperator Classes and Operator Families\(rq, in the documentation +and in +Section 35.14, \(lqInterfacing Extensions To Indexes\(rq, in the documentation\&. +.PP +For index methods that support ordered scans (currently, only B\-tree), the optional clauses +ASC, +DESC, +NULLS FIRST, and/or +NULLS LAST +can be specified to modify the sort ordering of the index\&. Since an ordered index can be scanned either forward or backward, it is not normally useful to create a single\-column +DESC +index \(em that sort ordering is already available with a regular index\&. The value of these options is that multicolumn indexes can be created that match the sort ordering requested by a mixed\-ordering query, such as +SELECT \&.\&.\&. ORDER BY x ASC, y DESC\&. The +NULLS +options are useful if you need to support +\(lqnulls sort low\(rq +behavior, rather than the default +\(lqnulls sort high\(rq, in queries that depend on indexes to avoid sorting steps\&. +.PP +For most index methods, the speed of creating an index is dependent on the setting of +maintenance_work_mem\&. Larger values will reduce the time needed for index creation, so long as you don\*(Aqt make it larger than the amount of memory really available, which would drive the machine into swapping\&. For hash indexes, the value of +effective_cache_size +is also relevant to index creation time: +PostgreSQL +will use one of two different hash index creation methods depending on whether the estimated index size is more or less than +\fIeffective_cache_size\fR\&. For best results, make sure that this parameter is also set to something reflective of available memory, and be careful that the sum of +\fImaintenance_work_mem\fR +and +\fIeffective_cache_size\fR +is less than the machine\*(Aqs RAM less whatever space is needed by other programs\&. +.PP +Use +DROP INDEX (\fBDROP_INDEX\fR(7)) +to remove an index\&. +.PP +Prior releases of +PostgreSQL +also had an R\-tree index method\&. This method has been removed because it had no significant advantages over the GiST method\&. If +USING rtree +is specified, +\fBCREATE INDEX\fR +will interpret it as +USING gist, to simplify conversion of old databases to GiST\&. +.SH "EXAMPLES" +.PP +To create a B\-tree index on the column +title +in the table +films: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE UNIQUE INDEX title_idx ON films (title); +.fi +.if n \{\ +.RE +.\} +.PP +To create an index on the expression +lower(title), allowing efficient case\-insensitive searches: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE INDEX ON films ((lower(title))); +.fi +.if n \{\ +.RE +.\} +.sp +(In this example we have chosen to omit the index name, so the system will choose a name, typically +films_lower_idx\&.) +.PP +To create an index with non\-default collation: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE INDEX title_idx_german ON films (title COLLATE "de_DE"); +.fi +.if n \{\ +.RE +.\} +.PP +To create an index with non\-default sort ordering of nulls: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE INDEX title_idx_nulls_low ON films (title NULLS FIRST); +.fi +.if n \{\ +.RE +.\} +.PP +To create an index with non\-default fill factor: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE UNIQUE INDEX title_idx ON films (title) WITH (fillfactor = 70); +.fi +.if n \{\ +.RE +.\} +.PP +To create a +GIN +index with fast updates disabled: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE INDEX gin_idx ON documents_table USING gin (locations) WITH (fastupdate = off); +.fi +.if n \{\ +.RE +.\} +.PP +To create an index on the column +code +in the table +films +and have the index reside in the tablespace +indexspace: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE INDEX code_idx ON films (code) TABLESPACE indexspace; +.fi +.if n \{\ +.RE +.\} +.PP +To create a GiST index on a point attribute so that we can efficiently use box operators on the result of the conversion function: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE INDEX pointloc + ON points USING gist (box(location,location)); +SELECT * FROM points + WHERE box(location,location) && \*(Aq(0,0),(1,1)\*(Aq::box; +.fi +.if n \{\ +.RE +.\} +.PP +To create an index without locking out writes to the table: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE INDEX CONCURRENTLY sales_quantity_index ON sales_table (quantity); +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBCREATE INDEX\fR +is a +PostgreSQL +language extension\&. There are no provisions for indexes in the SQL standard\&. +.SH "SEE ALSO" +ALTER INDEX (\fBALTER_INDEX\fR(7)), DROP INDEX (\fBDROP_INDEX\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_LANGUAGE.7 b/doc/src/sgml/man7/CREATE_LANGUAGE.7 new file mode 100644 index 000000000..0be553374 --- /dev/null +++ b/doc/src/sgml/man7/CREATE_LANGUAGE.7 @@ -0,0 +1,260 @@ +'\" t +.\" Title: CREATE LANGUAGE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE LANGUAGE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_LANGUAGE \- define a new procedural language +.\" CREATE LANGUAGE +.SH "SYNOPSIS" +.sp +.nf +CREATE [ OR REPLACE ] [ PROCEDURAL ] LANGUAGE \fIname\fR +CREATE [ OR REPLACE ] [ TRUSTED ] [ PROCEDURAL ] LANGUAGE \fIname\fR + HANDLER \fIcall_handler\fR [ INLINE \fIinline_handler\fR ] [ VALIDATOR \fIvalfunction\fR ] +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE LANGUAGE\fR +registers a new procedural language with a +PostgreSQL +database\&. Subsequently, functions and trigger procedures can be defined in this new language\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +.PP +As of +PostgreSQL +9\&.1, most procedural languages have been made into +\(lqextensions\(rq, and should therefore be installed with +CREATE EXTENSION (\fBCREATE_EXTENSION\fR(7)) +not +\fBCREATE LANGUAGE\fR\&. Direct use of +\fBCREATE LANGUAGE\fR +should now be confined to extension installation scripts\&. If you have a +\(lqbare\(rq +language in your database, perhaps as a result of an upgrade, you can convert it to an extension using +CREATE EXTENSION \fIlangname\fR FROM unpackaged\&. +.sp .5v +.RE +.PP + +\fBCREATE LANGUAGE\fR +effectively associates the language name with handler function(s) that are responsible for executing functions written in the language\&. Refer to +Chapter 49, Writing A Procedural Language Handler, in the documentation +for more information about language handlers\&. +.PP +There are two forms of the +\fBCREATE LANGUAGE\fR +command\&. In the first form, the user supplies just the name of the desired language, and the +PostgreSQL +server consults the +pg_pltemplate +system catalog to determine the correct parameters\&. In the second form, the user supplies the language parameters along with the language name\&. The second form can be used to create a language that is not defined in +pg_pltemplate, but this approach is considered obsolescent\&. +.PP +When the server finds an entry in the +pg_pltemplate +catalog for the given language name, it will use the catalog data even if the command includes language parameters\&. This behavior simplifies loading of old dump files, which are likely to contain out\-of\-date information about language support functions\&. +.PP +Ordinarily, the user must have the +PostgreSQL +superuser privilege to register a new language\&. However, the owner of a database can register a new language within that database if the language is listed in the +pg_pltemplate +catalog and is marked as allowed to be created by database owners (tmpldbacreate +is true)\&. The default is that trusted languages can be created by database owners, but this can be adjusted by superusers by modifying the contents of +pg_pltemplate\&. The creator of a language becomes its owner and can later drop it, rename it, or assign it to a new owner\&. +.PP + +\fBCREATE OR REPLACE LANGUAGE\fR +will either create a new language, or replace an existing definition\&. If the language already exists, its parameters are updated according to the values specified or taken from +pg_pltemplate, but the language\*(Aqs ownership and permissions settings do not change, and any existing functions written in the language are assumed to still be valid\&. In addition to the normal privilege requirements for creating a language, the user must be superuser or owner of the existing language\&. The +REPLACE +case is mainly meant to be used to ensure that the language exists\&. If the language has a +pg_pltemplate +entry then +REPLACE +will not actually change anything about an existing definition, except in the unusual case where the +pg_pltemplate +entry has been modified since the language was created\&. +.SH "PARAMETERS" +.PP +TRUSTED +.RS 4 +TRUSTED +specifies that the language does not grant access to data that the user would not otherwise have\&. If this key word is omitted when registering the language, only users with the +PostgreSQL +superuser privilege can use this language to create new functions\&. +.RE +.PP +PROCEDURAL +.RS 4 +This is a noise word\&. +.RE +.PP +\fIname\fR +.RS 4 +The name of the new procedural language\&. The name must be unique among the languages in the database\&. +.sp +For backward compatibility, the name can be enclosed by single quotes\&. +.RE +.PP +HANDLER \fIcall_handler\fR +.RS 4 +\fIcall_handler\fR +is the name of a previously registered function that will be called to execute the procedural language\*(Aqs functions\&. The call handler for a procedural language must be written in a compiled language such as C with version 1 call convention and registered with +PostgreSQL +as a function taking no arguments and returning the +language_handler +type, a placeholder type that is simply used to identify the function as a call handler\&. +.RE +.PP +INLINE \fIinline_handler\fR +.RS 4 +\fIinline_handler\fR +is the name of a previously registered function that will be called to execute an anonymous code block (\fBDO\fR(7) +command) in this language\&. If no +\fIinline_handler\fR +function is specified, the language does not support anonymous code blocks\&. The handler function must take one argument of type +internal, which will be the +\fBDO\fR +command\*(Aqs internal representation, and it will typically return +void\&. The return value of the handler is ignored\&. +.RE +.PP +VALIDATOR \fIvalfunction\fR +.RS 4 +\fIvalfunction\fR +is the name of a previously registered function that will be called when a new function in the language is created, to validate the new function\&. If no validator function is specified, then a new function will not be checked when it is created\&. The validator function must take one argument of type +oid, which will be the OID of the to\-be\-created function, and will typically return +void\&. +.sp +A validator function would typically inspect the function body for syntactical correctness, but it can also look at other properties of the function, for example if the language cannot handle certain argument types\&. To signal an error, the validator function should use the +\fBereport()\fR +function\&. The return value of the function is ignored\&. +.RE +.PP +The +TRUSTED +option and the support function name(s) are ignored if the server has an entry for the specified language name in +pg_pltemplate\&. +.SH "NOTES" +.PP +The +\fBcreatelang\fR(1) +program is a simple wrapper around the +\fBCREATE LANGUAGE\fR +command\&. It eases installation of procedural languages from the shell command line\&. +.PP +Use +DROP LANGUAGE (\fBDROP_LANGUAGE\fR(7)), or better yet the +\fBdroplang\fR(1) +program, to drop procedural languages\&. +.PP +The system catalog +pg_language +(see +Section 45.27, \(lqpg_language\(rq, in the documentation) records information about the currently installed languages\&. Also, +\fBcreatelang\fR +has an option to list the installed languages\&. +.PP +To create functions in a procedural language, a user must have the +USAGE +privilege for the language\&. By default, +USAGE +is granted to +PUBLIC +(i\&.e\&., everyone) for trusted languages\&. This can be revoked if desired\&. +.PP +Procedural languages are local to individual databases\&. However, a language can be installed into the +template1 +database, which will cause it to be available automatically in all subsequently\-created databases\&. +.PP +The call handler function, the inline handler function (if any), and the validator function (if any) must already exist if the server does not have an entry for the language in +pg_pltemplate\&. But when there is an entry, the functions need not already exist; they will be automatically defined if not present in the database\&. (This might result in +\fBCREATE LANGUAGE\fR +failing, if the shared library that implements the language is not available in the installation\&.) +.PP +In +PostgreSQL +versions before 7\&.3, it was necessary to declare handler functions as returning the placeholder type +opaque, rather than +language_handler\&. To support loading of old dump files, +\fBCREATE LANGUAGE\fR +will accept a function declared as returning +opaque, but it will issue a notice and change the function\*(Aqs declared return type to +language_handler\&. +.SH "EXAMPLES" +.PP +The preferred way of creating any of the standard procedural languages is just: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE LANGUAGE plperl; +.fi +.if n \{\ +.RE +.\} +.PP +For a language not known in the +pg_pltemplate +catalog, a sequence such as this is needed: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE FUNCTION plsample_call_handler() RETURNS language_handler + AS \*(Aq$libdir/plsample\*(Aq + LANGUAGE C; +CREATE LANGUAGE plsample + HANDLER plsample_call_handler; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBCREATE LANGUAGE\fR +is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +ALTER LANGUAGE (\fBALTER_LANGUAGE\fR(7)), CREATE FUNCTION (\fBCREATE_FUNCTION\fR(7)), DROP LANGUAGE (\fBDROP_LANGUAGE\fR(7)), \fBGRANT\fR(7), \fBREVOKE\fR(7), \fBcreatelang\fR(1), \fBdroplang\fR(1) diff --git a/doc/src/sgml/man7/CREATE_OPERATOR.7 b/doc/src/sgml/man7/CREATE_OPERATOR.7 new file mode 100644 index 000000000..5c786b200 --- /dev/null +++ b/doc/src/sgml/man7/CREATE_OPERATOR.7 @@ -0,0 +1,280 @@ +'\" t +.\" Title: CREATE OPERATOR +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE OPERATOR" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_OPERATOR \- define a new operator +.\" CREATE OPERATOR +.SH "SYNOPSIS" +.sp +.nf +CREATE OPERATOR \fIname\fR ( + PROCEDURE = \fIfunction_name\fR + [, LEFTARG = \fIleft_type\fR ] [, RIGHTARG = \fIright_type\fR ] + [, COMMUTATOR = \fIcom_op\fR ] [, NEGATOR = \fIneg_op\fR ] + [, RESTRICT = \fIres_proc\fR ] [, JOIN = \fIjoin_proc\fR ] + [, HASHES ] [, MERGES ] +) +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE OPERATOR\fR +defines a new operator, +\fIname\fR\&. The user who defines an operator becomes its owner\&. If a schema name is given then the operator is created in the specified schema\&. Otherwise it is created in the current schema\&. +.PP +The operator name is a sequence of up to +NAMEDATALEN\-1 (63 by default) characters from the following list: +.sp +.if n \{\ +.RS 4 +.\} +.nf ++ \- * / < > = ~ ! @ # % ^ & | ` ? +.fi +.if n \{\ +.RE +.\} +.sp +There are a few restrictions on your choice of name: +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +\-\- +and +/* +cannot appear anywhere in an operator name, since they will be taken as the start of a comment\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +A multicharacter operator name cannot end in ++ +or +\-, unless the name also contains at least one of these characters: +.sp +.if n \{\ +.RS 4 +.\} +.nf +~ ! @ # % ^ & | ` ? +.fi +.if n \{\ +.RE +.\} +.sp +For example, +@\- +is an allowed operator name, but +*\- +is not\&. This restriction allows +PostgreSQL +to parse SQL\-compliant commands without requiring spaces between tokens\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +The use of +=> +as an operator name is deprecated\&. It may be disallowed altogether in a future release\&. +.RE +.PP +The operator +!= +is mapped to +<> +on input, so these two names are always equivalent\&. +.PP +At least one of +LEFTARG +and +RIGHTARG +must be defined\&. For binary operators, both must be defined\&. For right unary operators, only +LEFTARG +should be defined, while for left unary operators only +RIGHTARG +should be defined\&. +.PP +The +\fIfunction_name\fR +procedure must have been previously defined using +\fBCREATE FUNCTION\fR +and must be defined to accept the correct number of arguments (either one or two) of the indicated types\&. +.PP +The other clauses specify optional operator optimization clauses\&. Their meaning is detailed in +Section 35.13, \(lqOperator Optimization Information\(rq, in the documentation\&. +.PP +To be able to create an operator, you must have +USAGE +privilege on the argument types and the return type, as well as +EXECUTE +privilege on the underlying function\&. If a commutator or negator operator is specified, you must own these operators\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name of the operator to be defined\&. See above for allowable characters\&. The name can be schema\-qualified, for example +CREATE OPERATOR myschema\&.+ (\&.\&.\&.)\&. If not, then the operator is created in the current schema\&. Two operators in the same schema can have the same name if they operate on different data types\&. This is called +overloading\&. +.RE +.PP +\fIfunction_name\fR +.RS 4 +The function used to implement this operator\&. +.RE +.PP +\fIleft_type\fR +.RS 4 +The data type of the operator\*(Aqs left operand, if any\&. This option would be omitted for a left\-unary operator\&. +.RE +.PP +\fIright_type\fR +.RS 4 +The data type of the operator\*(Aqs right operand, if any\&. This option would be omitted for a right\-unary operator\&. +.RE +.PP +\fIcom_op\fR +.RS 4 +The commutator of this operator\&. +.RE +.PP +\fIneg_op\fR +.RS 4 +The negator of this operator\&. +.RE +.PP +\fIres_proc\fR +.RS 4 +The restriction selectivity estimator function for this operator\&. +.RE +.PP +\fIjoin_proc\fR +.RS 4 +The join selectivity estimator function for this operator\&. +.RE +.PP +HASHES +.RS 4 +Indicates this operator can support a hash join\&. +.RE +.PP +MERGES +.RS 4 +Indicates this operator can support a merge join\&. +.RE +.PP +To give a schema\-qualified operator name in +\fIcom_op\fR +or the other optional arguments, use the +OPERATOR() +syntax, for example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +COMMUTATOR = OPERATOR(myschema\&.===) , +.fi +.if n \{\ +.RE +.\} +.SH "NOTES" +.PP +Refer to +Section 35.12, \(lqUser-defined Operators\(rq, in the documentation +for further information\&. +.PP +It is not possible to specify an operator\*(Aqs lexical precedence in +\fBCREATE OPERATOR\fR, because the parser\*(Aqs precedence behavior is hard\-wired\&. See +Section 4.1.6, \(lqOperator Precedence\(rq, in the documentation +for precedence details\&. +.PP +The obsolete options +SORT1, +SORT2, +LTCMP, and +GTCMP +were formerly used to specify the names of sort operators associated with a merge\-joinable operator\&. This is no longer necessary, since information about associated operators is found by looking at B\-tree operator families instead\&. If one of these options is given, it is ignored except for implicitly setting +MERGES +true\&. +.PP +Use +DROP OPERATOR (\fBDROP_OPERATOR\fR(7)) +to delete user\-defined operators from a database\&. Use +ALTER OPERATOR (\fBALTER_OPERATOR\fR(7)) +to modify operators in a database\&. +.SH "EXAMPLES" +.PP +The following command defines a new operator, area\-equality, for the data type +box: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE OPERATOR === ( + LEFTARG = box, + RIGHTARG = box, + PROCEDURE = area_equal_procedure, + COMMUTATOR = ===, + NEGATOR = !==, + RESTRICT = area_restriction_procedure, + JOIN = area_join_procedure, + HASHES, MERGES +); +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBCREATE OPERATOR\fR +is a +PostgreSQL +extension\&. There are no provisions for user\-defined operators in the SQL standard\&. +.SH "SEE ALSO" +ALTER OPERATOR (\fBALTER_OPERATOR\fR(7)), CREATE OPERATOR CLASS (\fBCREATE_OPERATOR_CLASS\fR(7)), DROP OPERATOR (\fBDROP_OPERATOR\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_OPERATOR_CLASS.7 b/doc/src/sgml/man7/CREATE_OPERATOR_CLASS.7 new file mode 100644 index 000000000..dbd2715b6 --- /dev/null +++ b/doc/src/sgml/man7/CREATE_OPERATOR_CLASS.7 @@ -0,0 +1,220 @@ +'\" t +.\" Title: CREATE OPERATOR CLASS +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE OPERATOR CLASS" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_OPERATOR_CLASS \- define a new operator class +.\" CREATE OPERATOR CLASS +.SH "SYNOPSIS" +.sp +.nf +CREATE OPERATOR CLASS \fIname\fR [ DEFAULT ] FOR TYPE \fIdata_type\fR + USING \fIindex_method\fR [ FAMILY \fIfamily_name\fR ] AS + { OPERATOR \fIstrategy_number\fR \fIoperator_name\fR [ ( \fIop_type\fR, \fIop_type\fR ) ] [ FOR SEARCH | FOR ORDER BY \fIsort_family_name\fR ] + | FUNCTION \fIsupport_number\fR [ ( \fIop_type\fR [ , \fIop_type\fR ] ) ] \fIfunction_name\fR ( \fIargument_type\fR [, \&.\&.\&.] ) + | STORAGE \fIstorage_type\fR + } [, \&.\&.\&. ] +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE OPERATOR CLASS\fR +creates a new operator class\&. An operator class defines how a particular data type can be used with an index\&. The operator class specifies that certain operators will fill particular roles or +\(lqstrategies\(rq +for this data type and this index method\&. The operator class also specifies the support procedures to be used by the index method when the operator class is selected for an index column\&. All the operators and functions used by an operator class must be defined before the operator class can be created\&. +.PP +If a schema name is given then the operator class is created in the specified schema\&. Otherwise it is created in the current schema\&. Two operator classes in the same schema can have the same name only if they are for different index methods\&. +.PP +The user who defines an operator class becomes its owner\&. Presently, the creating user must be a superuser\&. (This restriction is made because an erroneous operator class definition could confuse or even crash the server\&.) +.PP + +\fBCREATE OPERATOR CLASS\fR +does not presently check whether the operator class definition includes all the operators and functions required by the index method, nor whether the operators and functions form a self\-consistent set\&. It is the user\*(Aqs responsibility to define a valid operator class\&. +.PP +Related operator classes can be grouped into +operator families\&. To add a new operator class to an existing family, specify the +FAMILY +option in +\fBCREATE OPERATOR CLASS\fR\&. Without this option, the new class is placed into a family named the same as the new class (creating that family if it doesn\*(Aqt already exist)\&. +.PP +Refer to +Section 35.14, \(lqInterfacing Extensions To Indexes\(rq, in the documentation +for further information\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name of the operator class to be created\&. The name can be schema\-qualified\&. +.RE +.PP +DEFAULT +.RS 4 +If present, the operator class will become the default operator class for its data type\&. At most one operator class can be the default for a specific data type and index method\&. +.RE +.PP +\fIdata_type\fR +.RS 4 +The column data type that this operator class is for\&. +.RE +.PP +\fIindex_method\fR +.RS 4 +The name of the index method this operator class is for\&. +.RE +.PP +\fIfamily_name\fR +.RS 4 +The name of the existing operator family to add this operator class to\&. If not specified, a family named the same as the operator class is used (creating it, if it doesn\*(Aqt already exist)\&. +.RE +.PP +\fIstrategy_number\fR +.RS 4 +The index method\*(Aqs strategy number for an operator associated with the operator class\&. +.RE +.PP +\fIoperator_name\fR +.RS 4 +The name (optionally schema\-qualified) of an operator associated with the operator class\&. +.RE +.PP +\fIop_type\fR +.RS 4 +In an +OPERATOR +clause, the operand data type(s) of the operator, or +NONE +to signify a left\-unary or right\-unary operator\&. The operand data types can be omitted in the normal case where they are the same as the operator class\*(Aqs data type\&. +.sp +In a +FUNCTION +clause, the operand data type(s) the function is intended to support, if different from the input data type(s) of the function (for B\-tree comparison functions and hash functions) or the class\*(Aqs data type (for B\-tree sort support functions and all functions in GiST, SP\-GiST and GIN operator classes)\&. These defaults are correct, and so +\fIop_type\fR +need not be specified in +FUNCTION +clauses, except for the case of a B\-tree sort support function that is meant to support cross\-data\-type comparisons\&. +.RE +.PP +\fIsort_family_name\fR +.RS 4 +The name (optionally schema\-qualified) of an existing +btree +operator family that describes the sort ordering associated with an ordering operator\&. +.sp +If neither +FOR SEARCH +nor +FOR ORDER BY +is specified, +FOR SEARCH +is the default\&. +.RE +.PP +\fIsupport_number\fR +.RS 4 +The index method\*(Aqs support procedure number for a function associated with the operator class\&. +.RE +.PP +\fIfunction_name\fR +.RS 4 +The name (optionally schema\-qualified) of a function that is an index method support procedure for the operator class\&. +.RE +.PP +\fIargument_type\fR +.RS 4 +The parameter data type(s) of the function\&. +.RE +.PP +\fIstorage_type\fR +.RS 4 +The data type actually stored in the index\&. Normally this is the same as the column data type, but some index methods (currently GiST and GIN) allow it to be different\&. The +STORAGE +clause must be omitted unless the index method allows a different type to be used\&. +.RE +.PP +The +OPERATOR, +FUNCTION, and +STORAGE +clauses can appear in any order\&. +.SH "NOTES" +.PP +Because the index machinery does not check access permissions on functions before using them, including a function or operator in an operator class is tantamount to granting public execute permission on it\&. This is usually not an issue for the sorts of functions that are useful in an operator class\&. +.PP +The operators should not be defined by SQL functions\&. A SQL function is likely to be inlined into the calling query, which will prevent the optimizer from recognizing that the query matches an index\&. +.PP +Before +PostgreSQL +8\&.4, the +OPERATOR +clause could include a +RECHECK +option\&. This is no longer supported because whether an index operator is +\(lqlossy\(rq +is now determined on\-the\-fly at run time\&. This allows efficient handling of cases where an operator might or might not be lossy\&. +.SH "EXAMPLES" +.PP +The following example command defines a GiST index operator class for the data type +_int4 +(array of +int4)\&. See the +intarray +module for the complete example\&. +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE OPERATOR CLASS gist__int_ops + DEFAULT FOR TYPE _int4 USING gist AS + OPERATOR 3 &&, + OPERATOR 6 = (anyarray, anyarray), + OPERATOR 7 @>, + OPERATOR 8 <@, + OPERATOR 20 @@ (_int4, query_int), + FUNCTION 1 g_int_consistent (internal, _int4, int, oid, internal), + FUNCTION 2 g_int_union (internal, internal), + FUNCTION 3 g_int_compress (internal), + FUNCTION 4 g_int_decompress (internal), + FUNCTION 5 g_int_penalty (internal, internal, internal), + FUNCTION 6 g_int_picksplit (internal, internal), + FUNCTION 7 g_int_same (_int4, _int4, internal); +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBCREATE OPERATOR CLASS\fR +is a +PostgreSQL +extension\&. There is no +\fBCREATE OPERATOR CLASS\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +ALTER OPERATOR CLASS (\fBALTER_OPERATOR_CLASS\fR(7)), DROP OPERATOR CLASS (\fBDROP_OPERATOR_CLASS\fR(7)), CREATE OPERATOR FAMILY (\fBCREATE_OPERATOR_FAMILY\fR(7)), ALTER OPERATOR FAMILY (\fBALTER_OPERATOR_FAMILY\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_OPERATOR_FAMILY.7 b/doc/src/sgml/man7/CREATE_OPERATOR_FAMILY.7 new file mode 100644 index 000000000..e34eefbb4 --- /dev/null +++ b/doc/src/sgml/man7/CREATE_OPERATOR_FAMILY.7 @@ -0,0 +1,82 @@ +'\" t +.\" Title: CREATE OPERATOR FAMILY +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE OPERATOR FAMILY" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_OPERATOR_FAMILY \- define a new operator family +.\" CREATE OPERATOR FAMILY +.SH "SYNOPSIS" +.sp +.nf +CREATE OPERATOR FAMILY \fIname\fR USING \fIindex_method\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE OPERATOR FAMILY\fR +creates a new operator family\&. An operator family defines a collection of related operator classes, and perhaps some additional operators and support functions that are compatible with these operator classes but not essential for the functioning of any individual index\&. (Operators and functions that are essential to indexes should be grouped within the relevant operator class, rather than being +\(lqloose\(rq +in the operator family\&. Typically, single\-data\-type operators are bound to operator classes, while cross\-data\-type operators can be loose in an operator family containing operator classes for both data types\&.) +.PP +The new operator family is initially empty\&. It should be populated by issuing subsequent +\fBCREATE OPERATOR CLASS\fR +commands to add contained operator classes, and optionally +\fBALTER OPERATOR FAMILY\fR +commands to add +\(lqloose\(rq +operators and their corresponding support functions\&. +.PP +If a schema name is given then the operator family is created in the specified schema\&. Otherwise it is created in the current schema\&. Two operator families in the same schema can have the same name only if they are for different index methods\&. +.PP +The user who defines an operator family becomes its owner\&. Presently, the creating user must be a superuser\&. (This restriction is made because an erroneous operator family definition could confuse or even crash the server\&.) +.PP +Refer to +Section 35.14, \(lqInterfacing Extensions To Indexes\(rq, in the documentation +for further information\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name of the operator family to be created\&. The name can be schema\-qualified\&. +.RE +.PP +\fIindex_method\fR +.RS 4 +The name of the index method this operator family is for\&. +.RE +.SH "COMPATIBILITY" +.PP + +\fBCREATE OPERATOR FAMILY\fR +is a +PostgreSQL +extension\&. There is no +\fBCREATE OPERATOR FAMILY\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +ALTER OPERATOR FAMILY (\fBALTER_OPERATOR_FAMILY\fR(7)), DROP OPERATOR FAMILY (\fBDROP_OPERATOR_FAMILY\fR(7)), CREATE OPERATOR CLASS (\fBCREATE_OPERATOR_CLASS\fR(7)), ALTER OPERATOR CLASS (\fBALTER_OPERATOR_CLASS\fR(7)), DROP OPERATOR CLASS (\fBDROP_OPERATOR_CLASS\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_ROLE.7 b/doc/src/sgml/man7/CREATE_ROLE.7 new file mode 100644 index 000000000..5bd1eb535 --- /dev/null +++ b/doc/src/sgml/man7/CREATE_ROLE.7 @@ -0,0 +1,401 @@ +'\" t +.\" Title: CREATE ROLE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE ROLE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_ROLE \- define a new database role +.\" CREATE ROLE +.SH "SYNOPSIS" +.sp +.nf +CREATE ROLE \fIname\fR [ [ WITH ] \fIoption\fR [ \&.\&.\&. ] ] + +where \fIoption\fR can be: + + SUPERUSER | NOSUPERUSER + | CREATEDB | NOCREATEDB + | CREATEROLE | NOCREATEROLE + | CREATEUSER | NOCREATEUSER + | INHERIT | NOINHERIT + | LOGIN | NOLOGIN + | REPLICATION | NOREPLICATION + | CONNECTION LIMIT \fIconnlimit\fR + | [ ENCRYPTED | UNENCRYPTED ] PASSWORD \*(Aq\fIpassword\fR\*(Aq + | VALID UNTIL \*(Aq\fItimestamp\fR\*(Aq + | IN ROLE \fIrole_name\fR [, \&.\&.\&.] + | IN GROUP \fIrole_name\fR [, \&.\&.\&.] + | ROLE \fIrole_name\fR [, \&.\&.\&.] + | ADMIN \fIrole_name\fR [, \&.\&.\&.] + | USER \fIrole_name\fR [, \&.\&.\&.] + | SYSID \fIuid\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE ROLE\fR +adds a new role to a +PostgreSQL +database cluster\&. A role is an entity that can own database objects and have database privileges; a role can be considered a +\(lquser\(rq, a +\(lqgroup\(rq, or both depending on how it is used\&. Refer to +Chapter 20, Database Roles, in the documentation +and +Chapter 19, Client Authentication, in the documentation +for information about managing users and authentication\&. You must have +CREATEROLE +privilege or be a database superuser to use this command\&. +.PP +Note that roles are defined at the database cluster level, and so are valid in all databases in the cluster\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name of the new role\&. +.RE +.PP +SUPERUSER, NOSUPERUSER +.RS 4 +These clauses determine whether the new role is a +\(lqsuperuser\(rq, who can override all access restrictions within the database\&. Superuser status is dangerous and should be used only when really needed\&. You must yourself be a superuser to create a new superuser\&. If not specified, +NOSUPERUSER +is the default\&. +.RE +.PP +CREATEDB, NOCREATEDB +.RS 4 +These clauses define a role\*(Aqs ability to create databases\&. If +CREATEDB +is specified, the role being defined will be allowed to create new databases\&. Specifying +NOCREATEDB +will deny a role the ability to create databases\&. If not specified, +NOCREATEDB +is the default\&. +.RE +.PP +CREATEROLE, NOCREATEROLE +.RS 4 +These clauses determine whether a role will be permitted to create new roles (that is, execute +\fBCREATE ROLE\fR)\&. A role with +CREATEROLE +privilege can also alter and drop other roles\&. If not specified, +NOCREATEROLE +is the default\&. +.RE +.PP +CREATEUSER, NOCREATEUSER +.RS 4 +These clauses are an obsolete, but still accepted, spelling of +SUPERUSER +and +NOSUPERUSER\&. Note that they are +\fInot\fR +equivalent to +CREATEROLE +as one might naively expect! +.RE +.PP +INHERIT, NOINHERIT +.RS 4 +These clauses determine whether a role +\(lqinherits\(rq +the privileges of roles it is a member of\&. A role with the +INHERIT +attribute can automatically use whatever database privileges have been granted to all roles it is directly or indirectly a member of\&. Without +INHERIT, membership in another role only grants the ability to +\fBSET ROLE\fR +to that other role; the privileges of the other role are only available after having done so\&. If not specified, +INHERIT +is the default\&. +.RE +.PP +LOGIN, NOLOGIN +.RS 4 +These clauses determine whether a role is allowed to log in; that is, whether the role can be given as the initial session authorization name during client connection\&. A role having the +LOGIN +attribute can be thought of as a user\&. Roles without this attribute are useful for managing database privileges, but are not users in the usual sense of the word\&. If not specified, +NOLOGIN +is the default, except when +\fBCREATE ROLE\fR +is invoked through its alternative spelling +CREATE USER (\fBCREATE_USER\fR(7))\&. +.RE +.PP +REPLICATION, NOREPLICATION +.RS 4 +These clauses determine whether a role is allowed to initiate streaming replication or put the system in and out of backup mode\&. A role having the +REPLICATION +attribute is a very highly privileged role, and should only be used on roles actually used for replication\&. If not specified, +NOREPLICATION +is the default\&. +.RE +.PP +CONNECTION LIMIT \fIconnlimit\fR +.RS 4 +If role can log in, this specifies how many concurrent connections the role can make\&. \-1 (the default) means no limit\&. +.RE +.PP +PASSWORD \fIpassword\fR +.RS 4 +Sets the role\*(Aqs password\&. (A password is only of use for roles having the +LOGIN +attribute, but you can nonetheless define one for roles without it\&.) If you do not plan to use password authentication you can omit this option\&. If no password is specified, the password will be set to null and password authentication will always fail for that user\&. A null password can optionally be written explicitly as +PASSWORD NULL\&. +.RE +.PP +ENCRYPTED, UNENCRYPTED +.RS 4 +These key words control whether the password is stored encrypted in the system catalogs\&. (If neither is specified, the default behavior is determined by the configuration parameter +password_encryption\&.) If the presented password string is already in MD5\-encrypted format, then it is stored encrypted as\-is, regardless of whether +ENCRYPTED +or +UNENCRYPTED +is specified (since the system cannot decrypt the specified encrypted password string)\&. This allows reloading of encrypted passwords during dump/restore\&. +.sp +Note that older clients might lack support for the MD5 authentication mechanism that is needed to work with passwords that are stored encrypted\&. +.RE +.PP +VALID UNTIL \*(Aq\fItimestamp\fR\*(Aq +.RS 4 +The +VALID UNTIL +clause sets a date and time after which the role\*(Aqs password is no longer valid\&. If this clause is omitted the password will be valid for all time\&. +.RE +.PP +IN ROLE \fIrole_name\fR +.RS 4 +The +IN ROLE +clause lists one or more existing roles to which the new role will be immediately added as a new member\&. (Note that there is no option to add the new role as an administrator; use a separate +\fBGRANT\fR +command to do that\&.) +.RE +.PP +IN GROUP \fIrole_name\fR +.RS 4 +IN GROUP +is an obsolete spelling of +IN ROLE\&. +.RE +.PP +ROLE \fIrole_name\fR +.RS 4 +The +ROLE +clause lists one or more existing roles which are automatically added as members of the new role\&. (This in effect makes the new role a +\(lqgroup\(rq\&.) +.RE +.PP +ADMIN \fIrole_name\fR +.RS 4 +The +ADMIN +clause is like +ROLE, but the named roles are added to the new role +WITH ADMIN OPTION, giving them the right to grant membership in this role to others\&. +.RE +.PP +USER \fIrole_name\fR +.RS 4 +The +USER +clause is an obsolete spelling of the +ROLE +clause\&. +.RE +.PP +SYSID \fIuid\fR +.RS 4 +The +SYSID +clause is ignored, but is accepted for backwards compatibility\&. +.RE +.SH "NOTES" +.PP +Use +ALTER ROLE (\fBALTER_ROLE\fR(7)) +to change the attributes of a role, and +DROP ROLE (\fBDROP_ROLE\fR(7)) +to remove a role\&. All the attributes specified by +\fBCREATE ROLE\fR +can be modified by later +\fBALTER ROLE\fR +commands\&. +.PP +The preferred way to add and remove members of roles that are being used as groups is to use +\fBGRANT\fR(7) +and +\fBREVOKE\fR(7)\&. +.PP +The +VALID UNTIL +clause defines an expiration time for a password only, not for the role +per se\&. In particular, the expiration time is not enforced when logging in using a non\-password\-based authentication method\&. +.PP +The +INHERIT +attribute governs inheritance of grantable privileges (that is, access privileges for database objects and role memberships)\&. It does not apply to the special role attributes set by +\fBCREATE ROLE\fR +and +\fBALTER ROLE\fR\&. For example, being a member of a role with +CREATEDB +privilege does not immediately grant the ability to create databases, even if +INHERIT +is set; it would be necessary to become that role via +SET ROLE (\fBSET_ROLE\fR(7)) +before creating a database\&. +.PP +The +INHERIT +attribute is the default for reasons of backwards compatibility: in prior releases of +PostgreSQL, users always had access to all privileges of groups they were members of\&. However, +NOINHERIT +provides a closer match to the semantics specified in the SQL standard\&. +.PP +Be careful with the +CREATEROLE +privilege\&. There is no concept of inheritance for the privileges of a +CREATEROLE\-role\&. That means that even if a role does not have a certain privilege but is allowed to create other roles, it can easily create another role with different privileges than its own (except for creating roles with superuser privileges)\&. For example, if the role +\(lquser\(rq +has the +CREATEROLE +privilege but not the +CREATEDB +privilege, nonetheless it can create a new role with the +CREATEDB +privilege\&. Therefore, regard roles that have the +CREATEROLE +privilege as almost\-superuser\-roles\&. +.PP + +PostgreSQL +includes a program +\fBcreateuser\fR(1) +that has the same functionality as +\fBCREATE ROLE\fR +(in fact, it calls this command) but can be run from the command shell\&. +.PP +The +CONNECTION LIMIT +option is only enforced approximately; if two new sessions start at about the same time when just one connection +\(lqslot\(rq +remains for the role, it is possible that both will fail\&. Also, the limit is never enforced for superusers\&. +.PP +Caution must be exercised when specifying an unencrypted password with this command\&. The password will be transmitted to the server in cleartext, and it might also be logged in the client\*(Aqs command history or the server log\&. The command +\fBcreateuser\fR(1), however, transmits the password encrypted\&. Also, +\fBpsql\fR(1) +contains a command +\fB\epassword\fR +that can be used to safely change the password later\&. +.SH "EXAMPLES" +.PP +Create a role that can log in, but don\*(Aqt give it a password: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE ROLE jonathan LOGIN; +.fi +.if n \{\ +.RE +.\} +.PP +Create a role with a password: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE USER davide WITH PASSWORD \*(Aqjw8s0F4\*(Aq; +.fi +.if n \{\ +.RE +.\} +.sp +(\fBCREATE USER\fR +is the same as +\fBCREATE ROLE\fR +except that it implies +LOGIN\&.) +.PP +Create a role with a password that is valid until the end of 2004\&. After one second has ticked in 2005, the password is no longer valid\&. +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE ROLE miriam WITH LOGIN PASSWORD \*(Aqjw8s0F4\*(Aq VALID UNTIL \*(Aq2005\-01\-01\*(Aq; +.fi +.if n \{\ +.RE +.\} +.PP +Create a role that can create databases and manage roles: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE ROLE admin WITH CREATEDB CREATEROLE; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +The +\fBCREATE ROLE\fR +statement is in the SQL standard, but the standard only requires the syntax +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE ROLE \fIname\fR [ WITH ADMIN \fIrole_name\fR ] +.fi +.if n \{\ +.RE +.\} +.sp + +Multiple initial administrators, and all the other options of +\fBCREATE ROLE\fR, are +PostgreSQL +extensions\&. +.PP +The SQL standard defines the concepts of users and roles, but it regards them as distinct concepts and leaves all commands defining users to be specified by each database implementation\&. In +PostgreSQL +we have chosen to unify users and roles into a single kind of entity\&. Roles therefore have many more optional attributes than they do in the standard\&. +.PP +The behavior specified by the SQL standard is most closely approximated by giving users the +NOINHERIT +attribute, while roles are given the +INHERIT +attribute\&. +.SH "SEE ALSO" +SET ROLE (\fBSET_ROLE\fR(7)), ALTER ROLE (\fBALTER_ROLE\fR(7)), DROP ROLE (\fBDROP_ROLE\fR(7)), \fBGRANT\fR(7), \fBREVOKE\fR(7), \fBcreateuser\fR(1) diff --git a/doc/src/sgml/man7/CREATE_RULE.7 b/doc/src/sgml/man7/CREATE_RULE.7 new file mode 100644 index 000000000..4632194db --- /dev/null +++ b/doc/src/sgml/man7/CREATE_RULE.7 @@ -0,0 +1,270 @@ +'\" t +.\" Title: CREATE RULE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE RULE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_RULE \- define a new rewrite rule +.\" CREATE RULE +.SH "SYNOPSIS" +.sp +.nf +CREATE [ OR REPLACE ] RULE \fIname\fR AS ON \fIevent\fR + TO \fItable_name\fR [ WHERE \fIcondition\fR ] + DO [ ALSO | INSTEAD ] { NOTHING | \fIcommand\fR | ( \fIcommand\fR ; \fIcommand\fR \&.\&.\&. ) } +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE RULE\fR +defines a new rule applying to a specified table or view\&. +\fBCREATE OR REPLACE RULE\fR +will either create a new rule, or replace an existing rule of the same name for the same table\&. +.PP +The +PostgreSQL +rule system allows one to define an alternative action to be performed on insertions, updates, or deletions in database tables\&. Roughly speaking, a rule causes additional commands to be executed when a given command on a given table is executed\&. Alternatively, an +INSTEAD +rule can replace a given command by another, or cause a command not to be executed at all\&. Rules are used to implement table views as well\&. It is important to realize that a rule is really a command transformation mechanism, or command macro\&. The transformation happens before the execution of the commands starts\&. If you actually want an operation that fires independently for each physical row, you probably want to use a trigger, not a rule\&. More information about the rules system is in +Chapter 37, The Rule System, in the documentation\&. +.PP +Presently, +ON SELECT +rules must be unconditional +INSTEAD +rules and must have actions that consist of a single +\fBSELECT\fR +command\&. Thus, an +ON SELECT +rule effectively turns the table into a view, whose visible contents are the rows returned by the rule\*(Aqs +\fBSELECT\fR +command rather than whatever had been stored in the table (if anything)\&. It is considered better style to write a +\fBCREATE VIEW\fR +command than to create a real table and define an +ON SELECT +rule for it\&. +.PP +You can create the illusion of an updatable view by defining +ON INSERT, +ON UPDATE, and +ON DELETE +rules (or any subset of those that\*(Aqs sufficient for your purposes) to replace update actions on the view with appropriate updates on other tables\&. If you want to support +\fBINSERT RETURNING\fR +and so on, then be sure to put a suitable +RETURNING +clause into each of these rules\&. Alternatively, an updatable view can be implemented using +INSTEAD OF +triggers (see +CREATE TRIGGER (\fBCREATE_TRIGGER\fR(7)))\&. +.PP +There is a catch if you try to use conditional rules for view updates: there +\fImust\fR +be an unconditional +INSTEAD +rule for each action you wish to allow on the view\&. If the rule is conditional, or is not +INSTEAD, then the system will still reject attempts to perform the update action, because it thinks it might end up trying to perform the action on the dummy table of the view in some cases\&. If you want to handle all the useful cases in conditional rules, add an unconditional +DO INSTEAD NOTHING +rule to ensure that the system understands it will never be called on to update the dummy table\&. Then make the conditional rules non\-INSTEAD; in the cases where they are applied, they add to the default +INSTEAD NOTHING +action\&. (This method does not currently work to support +RETURNING +queries, however\&.) +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name of a rule to create\&. This must be distinct from the name of any other rule for the same table\&. Multiple rules on the same table and same event type are applied in alphabetical name order\&. +.RE +.PP +\fIevent\fR +.RS 4 +The event is one of +SELECT, +INSERT, +UPDATE, or +DELETE\&. +.RE +.PP +\fItable_name\fR +.RS 4 +The name (optionally schema\-qualified) of the table or view the rule applies to\&. +.RE +.PP +\fIcondition\fR +.RS 4 +Any +SQL +conditional expression (returning +boolean)\&. The condition expression cannot refer to any tables except +NEW +and +OLD, and cannot contain aggregate functions\&. +.RE +.PP +\fBINSTEAD\fR +.RS 4 +INSTEAD +indicates that the commands should be executed +\fIinstead of\fR +the original command\&. +.RE +.PP +\fBALSO\fR +.RS 4 +ALSO +indicates that the commands should be executed +\fIin addition to\fR +the original command\&. +.sp +If neither +ALSO +nor +INSTEAD +is specified, +ALSO +is the default\&. +.RE +.PP +\fIcommand\fR +.RS 4 +The command or commands that make up the rule action\&. Valid commands are +\fBSELECT\fR, +\fBINSERT\fR, +\fBUPDATE\fR, +\fBDELETE\fR, or +\fBNOTIFY\fR\&. +.RE +.PP +Within +\fIcondition\fR +and +\fIcommand\fR, the special table names +NEW +and +OLD +can be used to refer to values in the referenced table\&. +NEW +is valid in +ON INSERT +and +ON UPDATE +rules to refer to the new row being inserted or updated\&. +OLD +is valid in +ON UPDATE +and +ON DELETE +rules to refer to the existing row being updated or deleted\&. +.SH "NOTES" +.PP +You must be the owner of a table to create or change rules for it\&. +.PP +In a rule for +INSERT, +UPDATE, or +DELETE +on a view, you can add a +RETURNING +clause that emits the view\*(Aqs columns\&. This clause will be used to compute the outputs if the rule is triggered by an +\fBINSERT RETURNING\fR, +\fBUPDATE RETURNING\fR, or +\fBDELETE RETURNING\fR +command respectively\&. When the rule is triggered by a command without +RETURNING, the rule\*(Aqs +RETURNING +clause will be ignored\&. The current implementation allows only unconditional +INSTEAD +rules to contain +RETURNING; furthermore there can be at most one +RETURNING +clause among all the rules for the same event\&. (This ensures that there is only one candidate +RETURNING +clause to be used to compute the results\&.) +RETURNING +queries on the view will be rejected if there is no +RETURNING +clause in any available rule\&. +.PP +It is very important to take care to avoid circular rules\&. For example, though each of the following two rule definitions are accepted by +PostgreSQL, the +\fBSELECT\fR +command would cause +PostgreSQL +to report an error because of recursive expansion of a rule: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE RULE "_RETURN" AS + ON SELECT TO t1 + DO INSTEAD + SELECT * FROM t2; + +CREATE RULE "_RETURN" AS + ON SELECT TO t2 + DO INSTEAD + SELECT * FROM t1; + +SELECT * FROM t1; +.fi +.if n \{\ +.RE +.\} +.PP +Presently, if a rule action contains a +\fBNOTIFY\fR +command, the +\fBNOTIFY\fR +command will be executed unconditionally, that is, the +\fBNOTIFY\fR +will be issued even if there are not any rows that the rule should apply to\&. For example, in: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE RULE notify_me AS ON UPDATE TO mytable DO ALSO NOTIFY mytable; + +UPDATE mytable SET name = \*(Aqfoo\*(Aq WHERE id = 42; +.fi +.if n \{\ +.RE +.\} +.sp +one +\fBNOTIFY\fR +event will be sent during the +\fBUPDATE\fR, whether or not there are any rows that match the condition +id = 42\&. This is an implementation restriction that might be fixed in future releases\&. +.SH "COMPATIBILITY" +.PP + +\fBCREATE RULE\fR +is a +PostgreSQL +language extension, as is the entire query rewrite system\&. diff --git a/doc/src/sgml/man7/CREATE_SCHEMA.7 b/doc/src/sgml/man7/CREATE_SCHEMA.7 new file mode 100644 index 000000000..dd628aba1 --- /dev/null +++ b/doc/src/sgml/man7/CREATE_SCHEMA.7 @@ -0,0 +1,169 @@ +'\" t +.\" Title: CREATE SCHEMA +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE SCHEMA" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_SCHEMA \- define a new schema +.\" CREATE SCHEMA +.SH "SYNOPSIS" +.sp +.nf +CREATE SCHEMA \fIschema_name\fR [ AUTHORIZATION \fIuser_name\fR ] [ \fIschema_element\fR [ \&.\&.\&. ] ] +CREATE SCHEMA AUTHORIZATION \fIuser_name\fR [ \fIschema_element\fR [ \&.\&.\&. ] ] +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE SCHEMA\fR +enters a new schema into the current database\&. The schema name must be distinct from the name of any existing schema in the current database\&. +.PP +A schema is essentially a namespace: it contains named objects (tables, data types, functions, and operators) whose names can duplicate those of other objects existing in other schemas\&. Named objects are accessed either by +\(lqqualifying\(rq +their names with the schema name as a prefix, or by setting a search path that includes the desired schema(s)\&. A +CREATE +command specifying an unqualified object name creates the object in the current schema (the one at the front of the search path, which can be determined with the function +\fBcurrent_schema\fR)\&. +.PP +Optionally, +\fBCREATE SCHEMA\fR +can include subcommands to create objects within the new schema\&. The subcommands are treated essentially the same as separate commands issued after creating the schema, except that if the +AUTHORIZATION +clause is used, all the created objects will be owned by that user\&. +.SH "PARAMETERS" +.PP +\fIschema_name\fR +.RS 4 +The name of a schema to be created\&. If this is omitted, the +\fIuser_name\fR +is used as the schema name\&. The name cannot begin with +pg_, as such names are reserved for system schemas\&. +.RE +.PP +\fIuser_name\fR +.RS 4 +The role name of the user who will own the new schema\&. If omitted, defaults to the user executing the command\&. To create a schema owned by another role, you must be a direct or indirect member of that role, or be a superuser\&. +.RE +.PP +\fIschema_element\fR +.RS 4 +An SQL statement defining an object to be created within the schema\&. Currently, only +\fBCREATE TABLE\fR, +\fBCREATE VIEW\fR, +\fBCREATE INDEX\fR, +\fBCREATE SEQUENCE\fR, +\fBCREATE TRIGGER\fR +and +\fBGRANT\fR +are accepted as clauses within +\fBCREATE SCHEMA\fR\&. Other kinds of objects may be created in separate commands after the schema is created\&. +.RE +.SH "NOTES" +.PP +To create a schema, the invoking user must have the +CREATE +privilege for the current database\&. (Of course, superusers bypass this check\&.) +.SH "EXAMPLES" +.PP +Create a schema: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE SCHEMA myschema; +.fi +.if n \{\ +.RE +.\} +.PP +Create a schema for user +joe; the schema will also be named +joe: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE SCHEMA AUTHORIZATION joe; +.fi +.if n \{\ +.RE +.\} +.PP +Create a schema and create a table and view within it: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE SCHEMA hollywood + CREATE TABLE films (title text, release date, awards text[]) + CREATE VIEW winners AS + SELECT title, release FROM films WHERE awards IS NOT NULL; +.fi +.if n \{\ +.RE +.\} +.sp +Notice that the individual subcommands do not end with semicolons\&. +.PP +The following is an equivalent way of accomplishing the same result: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE SCHEMA hollywood; +CREATE TABLE hollywood\&.films (title text, release date, awards text[]); +CREATE VIEW hollywood\&.winners AS + SELECT title, release FROM hollywood\&.films WHERE awards IS NOT NULL; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +The SQL standard allows a +DEFAULT CHARACTER SET +clause in +\fBCREATE SCHEMA\fR, as well as more subcommand types than are presently accepted by +PostgreSQL\&. +.PP +The SQL standard specifies that the subcommands in +\fBCREATE SCHEMA\fR +can appear in any order\&. The present +PostgreSQL +implementation does not handle all cases of forward references in subcommands; it might sometimes be necessary to reorder the subcommands in order to avoid forward references\&. +.PP +According to the SQL standard, the owner of a schema always owns all objects within it\&. +PostgreSQL +allows schemas to contain objects owned by users other than the schema owner\&. This can happen only if the schema owner grants the +CREATE +privilege on his schema to someone else, or a superuser chooses to create objects in it\&. +.SH "SEE ALSO" +ALTER SCHEMA (\fBALTER_SCHEMA\fR(7)), DROP SCHEMA (\fBDROP_SCHEMA\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_SEQUENCE.7 b/doc/src/sgml/man7/CREATE_SEQUENCE.7 new file mode 100644 index 000000000..451bd8e46 --- /dev/null +++ b/doc/src/sgml/man7/CREATE_SEQUENCE.7 @@ -0,0 +1,333 @@ +'\" t +.\" Title: CREATE SEQUENCE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE SEQUENCE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_SEQUENCE \- define a new sequence generator +.\" CREATE SEQUENCE +.SH "SYNOPSIS" +.sp +.nf +CREATE [ TEMPORARY | TEMP ] SEQUENCE \fIname\fR [ INCREMENT [ BY ] \fIincrement\fR ] + [ MINVALUE \fIminvalue\fR | NO MINVALUE ] [ MAXVALUE \fImaxvalue\fR | NO MAXVALUE ] + [ START [ WITH ] \fIstart\fR ] [ CACHE \fIcache\fR ] [ [ NO ] CYCLE ] + [ OWNED BY { \fItable_name\fR\&.\fIcolumn_name\fR | NONE } ] +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE SEQUENCE\fR +creates a new sequence number generator\&. This involves creating and initializing a new special single\-row table with the name +\fIname\fR\&. The generator will be owned by the user issuing the command\&. +.PP +If a schema name is given then the sequence is created in the specified schema\&. Otherwise it is created in the current schema\&. Temporary sequences exist in a special schema, so a schema name cannot be given when creating a temporary sequence\&. The sequence name must be distinct from the name of any other sequence, table, index, view, or foreign table in the same schema\&. +.PP +After a sequence is created, you use the functions +\fBnextval\fR, +\fBcurrval\fR, and +\fBsetval\fR +to operate on the sequence\&. These functions are documented in +Section 9.16, \(lqSequence Manipulation Functions\(rq, in the documentation\&. +.PP +Although you cannot update a sequence directly, you can use a query like: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT * FROM \fIname\fR; +.fi +.if n \{\ +.RE +.\} +.sp +to examine the parameters and current state of a sequence\&. In particular, the +last_value +field of the sequence shows the last value allocated by any session\&. (Of course, this value might be obsolete by the time it\*(Aqs printed, if other sessions are actively doing +\fBnextval\fR +calls\&.) +.SH "PARAMETERS" +.PP +TEMPORARY or TEMP +.RS 4 +If specified, the sequence object is created only for this session, and is automatically dropped on session exit\&. Existing permanent sequences with the same name are not visible (in this session) while the temporary sequence exists, unless they are referenced with schema\-qualified names\&. +.RE +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of the sequence to be created\&. +.RE +.PP +\fIincrement\fR +.RS 4 +The optional clause +INCREMENT BY \fIincrement\fR +specifies which value is added to the current sequence value to create a new value\&. A positive value will make an ascending sequence, a negative one a descending sequence\&. The default value is 1\&. +.RE +.PP +\fIminvalue\fR, NO MINVALUE +.RS 4 +The optional clause +MINVALUE \fIminvalue\fR +determines the minimum value a sequence can generate\&. If this clause is not supplied or +\fBNO MINVALUE\fR +is specified, then defaults will be used\&. The defaults are 1 and \-263\-1 for ascending and descending sequences, respectively\&. +.RE +.PP +\fImaxvalue\fR, NO MAXVALUE +.RS 4 +The optional clause +MAXVALUE \fImaxvalue\fR +determines the maximum value for the sequence\&. If this clause is not supplied or +\fBNO MAXVALUE\fR +is specified, then default values will be used\&. The defaults are 263\-1 and \-1 for ascending and descending sequences, respectively\&. +.RE +.PP +\fIstart\fR +.RS 4 +The optional clause +START WITH \fIstart\fR +allows the sequence to begin anywhere\&. The default starting value is +\fIminvalue\fR +for ascending sequences and +\fImaxvalue\fR +for descending ones\&. +.RE +.PP +\fIcache\fR +.RS 4 +The optional clause +CACHE \fIcache\fR +specifies how many sequence numbers are to be preallocated and stored in memory for faster access\&. The minimum value is 1 (only one value can be generated at a time, i\&.e\&., no cache), and this is also the default\&. +.RE +.PP +CYCLE, NO CYCLE +.RS 4 +The +CYCLE +option allows the sequence to wrap around when the +\fImaxvalue\fR +or +\fIminvalue\fR +has been reached by an ascending or descending sequence respectively\&. If the limit is reached, the next number generated will be the +\fIminvalue\fR +or +\fImaxvalue\fR, respectively\&. +.sp +If +NO CYCLE +is specified, any calls to +\fBnextval\fR +after the sequence has reached its maximum value will return an error\&. If neither +CYCLE +or +NO CYCLE +are specified, +NO CYCLE +is the default\&. +.RE +.PP +OWNED BY \fItable_name\fR\&.\fIcolumn_name\fR, OWNED BY NONE +.RS 4 +The +OWNED BY +option causes the sequence to be associated with a specific table column, such that if that column (or its whole table) is dropped, the sequence will be automatically dropped as well\&. The specified table must have the same owner and be in the same schema as the sequence\&. +OWNED BY NONE, the default, specifies that there is no such association\&. +.RE +.SH "NOTES" +.PP +Use +\fBDROP SEQUENCE\fR +to remove a sequence\&. +.PP +Sequences are based on +bigint +arithmetic, so the range cannot exceed the range of an eight\-byte integer (\-9223372036854775808 to 9223372036854775807)\&. On some older platforms, there might be no compiler support for eight\-byte integers, in which case sequences use regular +integer +arithmetic (range \-2147483648 to +2147483647)\&. +.PP +Unexpected results might be obtained if a +\fIcache\fR +setting greater than one is used for a sequence object that will be used concurrently by multiple sessions\&. Each session will allocate and cache successive sequence values during one access to the sequence object and increase the sequence object\*(Aqs +last_value +accordingly\&. Then, the next +\fIcache\fR\-1 uses of +\fBnextval\fR +within that session simply return the preallocated values without touching the sequence object\&. So, any numbers allocated but not used within a session will be lost when that session ends, resulting in +\(lqholes\(rq +in the sequence\&. +.PP +Furthermore, although multiple sessions are guaranteed to allocate distinct sequence values, the values might be generated out of sequence when all the sessions are considered\&. For example, with a +\fIcache\fR +setting of 10, session A might reserve values 1\&.\&.10 and return +\fBnextval\fR=1, then session B might reserve values 11\&.\&.20 and return +\fBnextval\fR=11 before session A has generated +nextval=2\&. Thus, with a +\fIcache\fR +setting of one it is safe to assume that +\fBnextval\fR +values are generated sequentially; with a +\fIcache\fR +setting greater than one you should only assume that the +\fBnextval\fR +values are all distinct, not that they are generated purely sequentially\&. Also, +last_value +will reflect the latest value reserved by any session, whether or not it has yet been returned by +\fBnextval\fR\&. +.PP +Another consideration is that a +\fBsetval\fR +executed on such a sequence will not be noticed by other sessions until they have used up any preallocated values they have cached\&. +.SH "EXAMPLES" +.PP +Create an ascending sequence called +serial, starting at 101: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE SEQUENCE serial START 101; +.fi +.if n \{\ +.RE +.\} +.PP +Select the next number from this sequence: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT nextval(\*(Aqserial\*(Aq); + + nextval +\-\-\-\-\-\-\-\-\- + 101 +.fi +.if n \{\ +.RE +.\} +.PP +Select the next number from this sequence: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT nextval(\*(Aqserial\*(Aq); + + nextval +\-\-\-\-\-\-\-\-\- + 102 +.fi +.if n \{\ +.RE +.\} +.PP +Use this sequence in an +\fBINSERT\fR +command: +.sp +.if n \{\ +.RS 4 +.\} +.nf +INSERT INTO distributors VALUES (nextval(\*(Aqserial\*(Aq), \*(Aqnothing\*(Aq); +.fi +.if n \{\ +.RE +.\} +.PP +Update the sequence value after a +\fBCOPY FROM\fR: +.sp +.if n \{\ +.RS 4 +.\} +.nf +BEGIN; +COPY distributors FROM \*(Aqinput_file\*(Aq; +SELECT setval(\*(Aqserial\*(Aq, max(id)) FROM distributors; +END; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBCREATE SEQUENCE\fR +conforms to the +SQL +standard, with the following exceptions: +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +The standard\*(Aqs +AS +expression is not supported\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +Obtaining the next value is done using the +\fBnextval()\fR +function instead of the standard\*(Aqs +\fBNEXT VALUE FOR\fR +expression\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +The +OWNED BY +clause is a +PostgreSQL +extension\&. +.RE +.SH "SEE ALSO" +ALTER SEQUENCE (\fBALTER_SEQUENCE\fR(7)), DROP SEQUENCE (\fBDROP_SEQUENCE\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_SERVER.7 b/doc/src/sgml/man7/CREATE_SERVER.7 new file mode 100644 index 000000000..1e502b873 --- /dev/null +++ b/doc/src/sgml/man7/CREATE_SERVER.7 @@ -0,0 +1,126 @@ +'\" t +.\" Title: CREATE SERVER +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE SERVER" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_SERVER \- define a new foreign server +.\" CREATE SERVER +.SH "SYNOPSIS" +.sp +.nf +CREATE SERVER \fIserver_name\fR [ TYPE \*(Aq\fIserver_type\fR\*(Aq ] [ VERSION \*(Aq\fIserver_version\fR\*(Aq ] + FOREIGN DATA WRAPPER \fIfdw_name\fR + [ OPTIONS ( \fIoption\fR \*(Aq\fIvalue\fR\*(Aq [, \&.\&.\&. ] ) ] +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE SERVER\fR +defines a new foreign server\&. The user who defines the server becomes its owner\&. +.PP +A foreign server typically encapsulates connection information that a foreign\-data wrapper uses to access an external data resource\&. Additional user\-specific connection information may be specified by means of user mappings\&. +.PP +The server name must be unique within the database\&. +.PP +Creating a server requires +USAGE +privilege on the foreign\-data wrapper being used\&. +.SH "PARAMETERS" +.PP +\fIserver_name\fR +.RS 4 +The name of the foreign server to be created\&. +.RE +.PP +\fIserver_type\fR +.RS 4 +Optional server type\&. +.RE +.PP +\fIserver_version\fR +.RS 4 +Optional server version\&. +.RE +.PP +\fIfdw_name\fR +.RS 4 +The name of the foreign\-data wrapper that manages the server\&. +.RE +.PP +OPTIONS ( \fIoption\fR \*(Aq\fIvalue\fR\*(Aq [, \&.\&.\&. ] ) +.RS 4 +This clause specifies the options for the server\&. The options typically define the connection details of the server, but the actual names and values are dependent on the server\*(Aqs foreign\-data wrapper\&. +.RE +.SH "NOTES" +.PP +When using the +dblink +module (see +dblink), the foreign server name can be used as an argument of the +\fBdblink_connect\fR(3) +function to indicate the connection parameters\&. See also there for more examples\&. It is necessary to have the +USAGE +privilege on the foreign server to be able to use it in this way\&. +.SH "EXAMPLES" +.PP +Create a server +foo +that uses the built\-in foreign\-data wrapper +default: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE SERVER foo FOREIGN DATA WRAPPER "default"; +.fi +.if n \{\ +.RE +.\} +.PP +Create a server +myserver +that uses the foreign\-data wrapper +pgsql: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE SERVER myserver FOREIGN DATA WRAPPER pgsql OPTIONS (host \*(Aqfoo\*(Aq, dbname \*(Aqfoodb\*(Aq, port \*(Aq5432\*(Aq); +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBCREATE SERVER\fR +conforms to ISO/IEC 9075\-9 (SQL/MED)\&. +.SH "SEE ALSO" +ALTER SERVER (\fBALTER_SERVER\fR(7)), DROP SERVER (\fBDROP_SERVER\fR(7)), CREATE FOREIGN DATA WRAPPER (\fBCREATE_FOREIGN_DATA_WRAPPER\fR(7)), CREATE USER MAPPING (\fBCREATE_USER_MAPPING\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_TABLE.7 b/doc/src/sgml/man7/CREATE_TABLE.7 new file mode 100644 index 000000000..1ed9a6bce --- /dev/null +++ b/doc/src/sgml/man7/CREATE_TABLE.7 @@ -0,0 +1,1107 @@ +'\" t +.\" Title: CREATE TABLE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE TABLE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_TABLE \- define a new table +.\" CREATE TABLE +.SH "SYNOPSIS" +.sp +.nf +CREATE [ [ GLOBAL | LOCAL ] { TEMPORARY | TEMP } | UNLOGGED ] TABLE [ IF NOT EXISTS ] \fItable_name\fR ( [ + { \fIcolumn_name\fR \fIdata_type\fR [ COLLATE \fIcollation\fR ] [ \fIcolumn_constraint\fR [ \&.\&.\&. ] ] + | \fItable_constraint\fR + | LIKE \fIsource_table\fR [ \fIlike_option\fR \&.\&.\&. ] } + [, \&.\&.\&. ] +] ) +[ INHERITS ( \fIparent_table\fR [, \&.\&.\&. ] ) ] +[ WITH ( \fIstorage_parameter\fR [= \fIvalue\fR] [, \&.\&.\&. ] ) | WITH OIDS | WITHOUT OIDS ] +[ ON COMMIT { PRESERVE ROWS | DELETE ROWS | DROP } ] +[ TABLESPACE \fItablespace_name\fR ] + +CREATE [ [ GLOBAL | LOCAL ] { TEMPORARY | TEMP } | UNLOGGED ] TABLE [ IF NOT EXISTS ] \fItable_name\fR + OF \fItype_name\fR [ ( + { \fIcolumn_name\fR WITH OPTIONS [ \fIcolumn_constraint\fR [ \&.\&.\&. ] ] + | \fItable_constraint\fR } + [, \&.\&.\&. ] +) ] +[ WITH ( \fIstorage_parameter\fR [= \fIvalue\fR] [, \&.\&.\&. ] ) | WITH OIDS | WITHOUT OIDS ] +[ ON COMMIT { PRESERVE ROWS | DELETE ROWS | DROP } ] +[ TABLESPACE \fItablespace_name\fR ] + +where \fIcolumn_constraint\fR is: + +[ CONSTRAINT \fIconstraint_name\fR ] +{ NOT NULL | + NULL | + CHECK ( \fIexpression\fR ) [ NO INHERIT ] | + DEFAULT \fIdefault_expr\fR | + UNIQUE \fIindex_parameters\fR | + PRIMARY KEY \fIindex_parameters\fR | + REFERENCES \fIreftable\fR [ ( \fIrefcolumn\fR ) ] [ MATCH FULL | MATCH PARTIAL | MATCH SIMPLE ] + [ ON DELETE \fIaction\fR ] [ ON UPDATE \fIaction\fR ] } +[ DEFERRABLE | NOT DEFERRABLE ] [ INITIALLY DEFERRED | INITIALLY IMMEDIATE ] + +and \fItable_constraint\fR is: + +[ CONSTRAINT \fIconstraint_name\fR ] +{ CHECK ( \fIexpression\fR ) [ NO INHERIT ] | + UNIQUE ( \fIcolumn_name\fR [, \&.\&.\&. ] ) \fIindex_parameters\fR | + PRIMARY KEY ( \fIcolumn_name\fR [, \&.\&.\&. ] ) \fIindex_parameters\fR | + EXCLUDE [ USING \fIindex_method\fR ] ( \fIexclude_element\fR WITH \fIoperator\fR [, \&.\&.\&. ] ) \fIindex_parameters\fR [ WHERE ( \fIpredicate\fR ) ] | + FOREIGN KEY ( \fIcolumn_name\fR [, \&.\&.\&. ] ) REFERENCES \fIreftable\fR [ ( \fIrefcolumn\fR [, \&.\&.\&. ] ) ] + [ MATCH FULL | MATCH PARTIAL | MATCH SIMPLE ] [ ON DELETE \fIaction\fR ] [ ON UPDATE \fIaction\fR ] } +[ DEFERRABLE | NOT DEFERRABLE ] [ INITIALLY DEFERRED | INITIALLY IMMEDIATE ] + +and \fIlike_option\fR is: + +{ INCLUDING | EXCLUDING } { DEFAULTS | CONSTRAINTS | INDEXES | STORAGE | COMMENTS | ALL } + +\fIindex_parameters\fR in UNIQUE, PRIMARY KEY, and EXCLUDE constraints are: + +[ WITH ( \fIstorage_parameter\fR [= \fIvalue\fR] [, \&.\&.\&. ] ) ] +[ USING INDEX TABLESPACE \fItablespace_name\fR ] + +\fIexclude_element\fR in an EXCLUDE constraint is: + +{ \fIcolumn_name\fR | ( \fIexpression\fR ) } [ \fIopclass\fR ] [ ASC | DESC ] [ NULLS { FIRST | LAST } ] +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE TABLE\fR +will create a new, initially empty table in the current database\&. The table will be owned by the user issuing the command\&. +.PP +If a schema name is given (for example, +CREATE TABLE myschema\&.mytable \&.\&.\&.) then the table is created in the specified schema\&. Otherwise it is created in the current schema\&. Temporary tables exist in a special schema, so a schema name cannot be given when creating a temporary table\&. The name of the table must be distinct from the name of any other table, sequence, index, view, or foreign table in the same schema\&. +.PP + +\fBCREATE TABLE\fR +also automatically creates a data type that represents the composite type corresponding to one row of the table\&. Therefore, tables cannot have the same name as any existing data type in the same schema\&. +.PP +The optional constraint clauses specify constraints (tests) that new or updated rows must satisfy for an insert or update operation to succeed\&. A constraint is an SQL object that helps define the set of valid values in the table in various ways\&. +.PP +There are two ways to define constraints: table constraints and column constraints\&. A column constraint is defined as part of a column definition\&. A table constraint definition is not tied to a particular column, and it can encompass more than one column\&. Every column constraint can also be written as a table constraint; a column constraint is only a notational convenience for use when the constraint only affects one column\&. +.PP +To be able to create a table, you must have +USAGE +privilege on all column types or the type in the +OF +clause, respectively\&. +.SH "PARAMETERS" +.PP +TEMPORARY or TEMP +.RS 4 +If specified, the table is created as a temporary table\&. Temporary tables are automatically dropped at the end of a session, or optionally at the end of the current transaction (see +ON COMMIT +below)\&. Existing permanent tables with the same name are not visible to the current session while the temporary table exists, unless they are referenced with schema\-qualified names\&. Any indexes created on a temporary table are automatically temporary as well\&. +.sp +The +autovacuum daemon +cannot access and therefore cannot vacuum or analyze temporary tables\&. For this reason, appropriate vacuum and analyze operations should be performed via session SQL commands\&. For example, if a temporary table is going to be used in complex queries, it is wise to run +\fBANALYZE\fR +on the temporary table after it is populated\&. +.sp +Optionally, +GLOBAL +or +LOCAL +can be written before +TEMPORARY +or +TEMP\&. This presently makes no difference in +PostgreSQL +and is deprecated; see +COMPATIBILITY\&. +.RE +.PP +UNLOGGED +.RS 4 +If specified, the table is created as an unlogged table\&. Data written to unlogged tables is not written to the write\-ahead log (see +Chapter 29, Reliability and the Write-Ahead Log, in the documentation), which makes them considerably faster than ordinary tables\&. However, they are not crash\-safe: an unlogged table is automatically truncated after a crash or unclean shutdown\&. The contents of an unlogged table are also not replicated to standby servers\&. Any indexes created on an unlogged table are automatically unlogged as well; however, unlogged +GiST indexes +are currently not supported and cannot be created on an unlogged table\&. +.RE +.PP +IF NOT EXISTS +.RS 4 +Do not throw an error if a relation with the same name already exists\&. A notice is issued in this case\&. Note that there is no guarantee that the existing relation is anything like the one that would have been created\&. +.RE +.PP +\fItable_name\fR +.RS 4 +The name (optionally schema\-qualified) of the table to be created\&. +.RE +.PP +OF \fItype_name\fR +.RS 4 +Creates a +typed table, which takes its structure from the specified composite type (name optionally schema\-qualified)\&. A typed table is tied to its type; for example the table will be dropped if the type is dropped (with +DROP TYPE \&.\&.\&. CASCADE)\&. +.sp +When a typed table is created, then the data types of the columns are determined by the underlying composite type and are not specified by the +CREATE TABLE +command\&. But the +CREATE TABLE +command can add defaults and constraints to the table and can specify storage parameters\&. +.RE +.PP +\fIcolumn_name\fR +.RS 4 +The name of a column to be created in the new table\&. +.RE +.PP +\fIdata_type\fR +.RS 4 +The data type of the column\&. This can include array specifiers\&. For more information on the data types supported by +PostgreSQL, refer to +Chapter 8, Data Types, in the documentation\&. +.RE +.PP +COLLATE \fIcollation\fR +.RS 4 +The +COLLATE +clause assigns a collation to the column (which must be of a collatable data type)\&. If not specified, the column data type\*(Aqs default collation is used\&. +.RE +.PP +INHERITS ( \fIparent_table\fR [, \&.\&.\&. ] ) +.RS 4 +The optional +INHERITS +clause specifies a list of tables from which the new table automatically inherits all columns\&. +.sp +Use of +INHERITS +creates a persistent relationship between the new child table and its parent table(s)\&. Schema modifications to the parent(s) normally propagate to children as well, and by default the data of the child table is included in scans of the parent(s)\&. +.sp +If the same column name exists in more than one parent table, an error is reported unless the data types of the columns match in each of the parent tables\&. If there is no conflict, then the duplicate columns are merged to form a single column in the new table\&. If the column name list of the new table contains a column name that is also inherited, the data type must likewise match the inherited column(s), and the column definitions are merged into one\&. If the new table explicitly specifies a default value for the column, this default overrides any defaults from inherited declarations of the column\&. Otherwise, any parents that specify default values for the column must all specify the same default, or an error will be reported\&. +.sp +CHECK +constraints are merged in essentially the same way as columns: if multiple parent tables and/or the new table definition contain identically\-named +CHECK +constraints, these constraints must all have the same check expression, or an error will be reported\&. Constraints having the same name and expression will be merged into one copy\&. A constraint marked +NO INHERIT +in a parent will not be considered\&. Notice that an unnamed +CHECK +constraint in the new table will never be merged, since a unique name will always be chosen for it\&. +.sp +Column +STORAGE +settings are also copied from parent tables\&. +.RE +.PP +LIKE \fIsource_table\fR [ \fIlike_option\fR \&.\&.\&. ] +.RS 4 +The +LIKE +clause specifies a table from which the new table automatically copies all column names, their data types, and their not\-null constraints\&. +.sp +Unlike +INHERITS, the new table and original table are completely decoupled after creation is complete\&. Changes to the original table will not be applied to the new table, and it is not possible to include data of the new table in scans of the original table\&. +.sp +Default expressions for the copied column definitions will only be copied if +INCLUDING DEFAULTS +is specified\&. The default behavior is to exclude default expressions, resulting in the copied columns in the new table having null defaults\&. +.sp +Not\-null constraints are always copied to the new table\&. +CHECK +constraints will only be copied if +INCLUDING CONSTRAINTS +is specified; other types of constraints will never be copied\&. Also, no distinction is made between column constraints and table constraints \(em when constraints are requested, all check constraints are copied\&. +.sp +Any indexes on the original table will not be created on the new table, unless the +INCLUDING INDEXES +clause is specified\&. +.sp +STORAGE +settings for the copied column definitions will only be copied if +INCLUDING STORAGE +is specified\&. The default behavior is to exclude +STORAGE +settings, resulting in the copied columns in the new table having type\-specific default settings\&. For more on +STORAGE +settings, see +Section 56.2, \(lqTOAST\(rq, in the documentation\&. +.sp +Comments for the copied columns, constraints, and indexes will only be copied if +INCLUDING COMMENTS +is specified\&. The default behavior is to exclude comments, resulting in the copied columns and constraints in the new table having no comments\&. +.sp +INCLUDING ALL +is an abbreviated form of +INCLUDING DEFAULTS INCLUDING CONSTRAINTS INCLUDING INDEXES INCLUDING STORAGE INCLUDING COMMENTS\&. +.sp +Note also that unlike +INHERITS, columns and constraints copied by +LIKE +are not merged with similarly named columns and constraints\&. If the same name is specified explicitly or in another +LIKE +clause, an error is signalled\&. +.sp +The +LIKE +clause can also be used to copy columns from views, foreign tables, or composite types\&. Inapplicable options (e\&.g\&., +INCLUDING INDEXES +from a view) are ignored\&. +.RE +.PP +CONSTRAINT \fIconstraint_name\fR +.RS 4 +An optional name for a column or table constraint\&. If the constraint is violated, the constraint name is present in error messages, so constraint names like +col must be positive +can be used to communicate helpful constraint information to client applications\&. (Double\-quotes are needed to specify constraint names that contain spaces\&.) If a constraint name is not specified, the system generates a name\&. +.RE +.PP +NOT NULL +.RS 4 +The column is not allowed to contain null values\&. +.RE +.PP +NULL +.RS 4 +The column is allowed to contain null values\&. This is the default\&. +.sp +This clause is only provided for compatibility with non\-standard SQL databases\&. Its use is discouraged in new applications\&. +.RE +.PP +CHECK ( \fIexpression\fR ) [ NO INHERIT ] +.RS 4 +The +CHECK +clause specifies an expression producing a Boolean result which new or updated rows must satisfy for an insert or update operation to succeed\&. Expressions evaluating to TRUE or UNKNOWN succeed\&. Should any row of an insert or update operation produce a FALSE result an error exception is raised and the insert or update does not alter the database\&. A check constraint specified as a column constraint should reference that column\*(Aqs value only, while an expression appearing in a table constraint can reference multiple columns\&. +.sp +Currently, +CHECK +expressions cannot contain subqueries nor refer to variables other than columns of the current row\&. +.sp +A constraint marked with +NO INHERIT +will not propagate to child tables\&. +.RE +.PP +DEFAULT \fIdefault_expr\fR +.RS 4 +The +DEFAULT +clause assigns a default data value for the column whose column definition it appears within\&. The value is any variable\-free expression (subqueries and cross\-references to other columns in the current table are not allowed)\&. The data type of the default expression must match the data type of the column\&. +.sp +The default expression will be used in any insert operation that does not specify a value for the column\&. If there is no default for a column, then the default is null\&. +.RE +.PP +UNIQUE (column constraint), UNIQUE ( \fIcolumn_name\fR [, \&.\&.\&. ] ) (table constraint) +.RS 4 +The +UNIQUE +constraint specifies that a group of one or more columns of a table can contain only unique values\&. The behavior of the unique table constraint is the same as that for column constraints, with the additional capability to span multiple columns\&. +.sp +For the purpose of a unique constraint, null values are not considered equal\&. +.sp +Each unique table constraint must name a set of columns that is different from the set of columns named by any other unique or primary key constraint defined for the table\&. (Otherwise it would just be the same constraint listed twice\&.) +.RE +.PP +PRIMARY KEY (column constraint), PRIMARY KEY ( \fIcolumn_name\fR [, \&.\&.\&. ] ) (table constraint) +.RS 4 +The primary key constraint specifies that a column or columns of a table can contain only unique (non\-duplicate), nonnull values\&. Technically, +PRIMARY KEY +is merely a combination of +UNIQUE +and +NOT NULL, but identifying a set of columns as primary key also provides metadata about the design of the schema, as a primary key implies that other tables can rely on this set of columns as a unique identifier for rows\&. +.sp +Only one primary key can be specified for a table, whether as a column constraint or a table constraint\&. +.sp +The primary key constraint should name a set of columns that is different from other sets of columns named by any unique constraint defined for the same table\&. +.RE +.PP +EXCLUDE [ USING \fIindex_method\fR ] ( \fIexclude_element\fR WITH \fIoperator\fR [, \&.\&.\&. ] ) \fIindex_parameters\fR [ WHERE ( \fIpredicate\fR ) ] +.RS 4 +The +EXCLUDE +clause defines an exclusion constraint, which guarantees that if any two rows are compared on the specified column(s) or expression(s) using the specified operator(s), not all of these comparisons will return +TRUE\&. If all of the specified operators test for equality, this is equivalent to a +UNIQUE +constraint, although an ordinary unique constraint will be faster\&. However, exclusion constraints can specify constraints that are more general than simple equality\&. For example, you can specify a constraint that no two rows in the table contain overlapping circles (see +Section 8.8, \(lqGeometric Types\(rq, in the documentation) by using the +&& +operator\&. +.sp +Exclusion constraints are implemented using an index, so each specified operator must be associated with an appropriate operator class (see +Section 11.9, \(lqOperator Classes and Operator Families\(rq, in the documentation) for the index access method +\fIindex_method\fR\&. The operators are required to be commutative\&. Each +\fIexclude_element\fR +can optionally specify an operator class and/or ordering options; these are described fully under +CREATE INDEX (\fBCREATE_INDEX\fR(7))\&. +.sp +The access method must support +amgettuple +(see +Chapter 52, Index Access Method Interface Definition, in the documentation); at present this means +GIN +cannot be used\&. Although it\*(Aqs allowed, there is little point in using B\-tree or hash indexes with an exclusion constraint, because this does nothing that an ordinary unique constraint doesn\*(Aqt do better\&. So in practice the access method will always be +GiST +or +SP\-GiST\&. +.sp +The +\fIpredicate\fR +allows you to specify an exclusion constraint on a subset of the table; internally this creates a partial index\&. Note that parentheses are required around the predicate\&. +.RE +.PP +REFERENCES \fIreftable\fR [ ( \fIrefcolumn\fR ) ] [ MATCH \fImatchtype\fR ] [ ON DELETE \fIaction\fR ] [ ON UPDATE \fIaction\fR ] (column constraint), FOREIGN KEY ( \fIcolumn_name\fR [, \&.\&.\&. ] ) REFERENCES \fIreftable\fR [ ( \fIrefcolumn\fR [, \&.\&.\&. ] ) ] [ MATCH \fImatchtype\fR ] [ ON DELETE \fIaction\fR ] [ ON UPDATE \fIaction\fR ] (table constraint) +.RS 4 +These clauses specify a foreign key constraint, which requires that a group of one or more columns of the new table must only contain values that match values in the referenced column(s) of some row of the referenced table\&. If +\fIrefcolumn\fR +is omitted, the primary key of the +\fIreftable\fR +is used\&. The referenced columns must be the columns of a non\-deferrable unique or primary key constraint in the referenced table\&. Note that foreign key constraints cannot be defined between temporary tables and permanent tables\&. +.sp +A value inserted into the referencing column(s) is matched against the values of the referenced table and referenced columns using the given match type\&. There are three match types: +MATCH FULL, +MATCH PARTIAL, and +MATCH SIMPLE, which is also the default\&. +MATCH FULL +will not allow one column of a multicolumn foreign key to be null unless all foreign key columns are null\&. +MATCH SIMPLE +allows some foreign key columns to be null while other parts of the foreign key are not null\&. +MATCH PARTIAL +is not yet implemented\&. +.sp +In addition, when the data in the referenced columns is changed, certain actions are performed on the data in this table\*(Aqs columns\&. The +ON DELETE +clause specifies the action to perform when a referenced row in the referenced table is being deleted\&. Likewise, the +ON UPDATE +clause specifies the action to perform when a referenced column in the referenced table is being updated to a new value\&. If the row is updated, but the referenced column is not actually changed, no action is done\&. Referential actions other than the +NO ACTION +check cannot be deferred, even if the constraint is declared deferrable\&. There are the following possible actions for each clause: +.PP +NO ACTION +.RS 4 +Produce an error indicating that the deletion or update would create a foreign key constraint violation\&. If the constraint is deferred, this error will be produced at constraint check time if there still exist any referencing rows\&. This is the default action\&. +.RE +.PP +RESTRICT +.RS 4 +Produce an error indicating that the deletion or update would create a foreign key constraint violation\&. This is the same as +NO ACTION +except that the check is not deferrable\&. +.RE +.PP +CASCADE +.RS 4 +Delete any rows referencing the deleted row, or update the value of the referencing column to the new value of the referenced column, respectively\&. +.RE +.PP +SET NULL +.RS 4 +Set the referencing column(s) to null\&. +.RE +.PP +SET DEFAULT +.RS 4 +Set the referencing column(s) to their default values\&. +.RE +.sp +If the referenced column(s) are changed frequently, it might be wise to add an index to the foreign key column so that referential actions associated with the foreign key column can be performed more efficiently\&. +.RE +.PP +DEFERRABLE, NOT DEFERRABLE +.RS 4 +This controls whether the constraint can be deferred\&. A constraint that is not deferrable will be checked immediately after every command\&. Checking of constraints that are deferrable can be postponed until the end of the transaction (using the +SET CONSTRAINTS (\fBSET_CONSTRAINTS\fR(7)) +command)\&. +NOT DEFERRABLE +is the default\&. Currently, only +UNIQUE, +PRIMARY KEY, +EXCLUDE, and +REFERENCES +(foreign key) constraints accept this clause\&. +NOT NULL +and +CHECK +constraints are not deferrable\&. +.RE +.PP +INITIALLY IMMEDIATE, INITIALLY DEFERRED +.RS 4 +If a constraint is deferrable, this clause specifies the default time to check the constraint\&. If the constraint is +INITIALLY IMMEDIATE, it is checked after each statement\&. This is the default\&. If the constraint is +INITIALLY DEFERRED, it is checked only at the end of the transaction\&. The constraint check time can be altered with the +SET CONSTRAINTS (\fBSET_CONSTRAINTS\fR(7)) +command\&. +.RE +.PP +WITH ( \fIstorage_parameter\fR [= \fIvalue\fR] [, \&.\&.\&. ] ) +.RS 4 +This clause specifies optional storage parameters for a table or index; see +Storage Parameters +for more information\&. The +WITH +clause for a table can also include +OIDS=TRUE +(or just +OIDS) to specify that rows of the new table should have OIDs (object identifiers) assigned to them, or +OIDS=FALSE +to specify that the rows should not have OIDs\&. If +OIDS +is not specified, the default setting depends upon the +default_with_oids +configuration parameter\&. (If the new table inherits from any tables that have OIDs, then +OIDS=TRUE +is forced even if the command says +OIDS=FALSE\&.) +.sp +If +OIDS=FALSE +is specified or implied, the new table does not store OIDs and no OID will be assigned for a row inserted into it\&. This is generally considered worthwhile, since it will reduce OID consumption and thereby postpone the wraparound of the 32\-bit OID counter\&. Once the counter wraps around, OIDs can no longer be assumed to be unique, which makes them considerably less useful\&. In addition, excluding OIDs from a table reduces the space required to store the table on disk by 4 bytes per row (on most machines), slightly improving performance\&. +.sp +To remove OIDs from a table after it has been created, use +ALTER TABLE (\fBALTER_TABLE\fR(7))\&. +.RE +.PP +WITH OIDS, WITHOUT OIDS +.RS 4 +These are obsolescent syntaxes equivalent to +WITH (OIDS) +and +WITH (OIDS=FALSE), respectively\&. If you wish to give both an +OIDS +setting and storage parameters, you must use the +WITH ( \&.\&.\&. ) +syntax; see above\&. +.RE +.PP +ON COMMIT +.RS 4 +The behavior of temporary tables at the end of a transaction block can be controlled using +ON COMMIT\&. The three options are: +.PP +PRESERVE ROWS +.RS 4 +No special action is taken at the ends of transactions\&. This is the default behavior\&. +.RE +.PP +DELETE ROWS +.RS 4 +All rows in the temporary table will be deleted at the end of each transaction block\&. Essentially, an automatic +\fBTRUNCATE\fR(7) +is done at each commit\&. +.RE +.PP +DROP +.RS 4 +The temporary table will be dropped at the end of the current transaction block\&. +.RE +.RE +.PP +TABLESPACE \fItablespace_name\fR +.RS 4 +The +\fItablespace_name\fR +is the name of the tablespace in which the new table is to be created\&. If not specified, +default_tablespace +is consulted, or +temp_tablespaces +if the table is temporary\&. +.RE +.PP +USING INDEX TABLESPACE \fItablespace_name\fR +.RS 4 +This clause allows selection of the tablespace in which the index associated with a +UNIQUE, +PRIMARY KEY, or +EXCLUDE +constraint will be created\&. If not specified, +default_tablespace +is consulted, or +temp_tablespaces +if the table is temporary\&. +.RE +.SS "Storage Parameters" +.\" storage parameters +.PP +The +WITH +clause can specify +storage parameters +for tables, and for indexes associated with a +UNIQUE, +PRIMARY KEY, or +EXCLUDE +constraint\&. Storage parameters for indexes are documented in +CREATE INDEX (\fBCREATE_INDEX\fR(7))\&. The storage parameters currently available for tables are listed below\&. For each parameter, unless noted, there is an additional parameter with the same name prefixed with +toast\&., which can be used to control the behavior of the table\*(Aqs secondary +TOAST +table, if any (see +Section 56.2, \(lqTOAST\(rq, in the documentation +for more information about TOAST)\&. Note that the TOAST table inherits the +autovacuum_* +values from its parent table, if there are no +toast\&.autovacuum_* +settings set\&. +.PP +fillfactor (integer) +.RS 4 +The fillfactor for a table is a percentage between 10 and 100\&. 100 (complete packing) is the default\&. When a smaller fillfactor is specified, +\fBINSERT\fR +operations pack table pages only to the indicated percentage; the remaining space on each page is reserved for updating rows on that page\&. This gives +\fBUPDATE\fR +a chance to place the updated copy of a row on the same page as the original, which is more efficient than placing it on a different page\&. For a table whose entries are never updated, complete packing is the best choice, but in heavily updated tables smaller fillfactors are appropriate\&. This parameter cannot be set for TOAST tables\&. +.RE +.PP +autovacuum_enabled, toast\&.autovacuum_enabled (boolean) +.RS 4 +Enables or disables the autovacuum daemon on a particular table\&. If true, the autovacuum daemon will initiate a +\fBVACUUM\fR +operation on a particular table when the number of updated or deleted tuples exceeds +autovacuum_vacuum_threshold +plus +autovacuum_vacuum_scale_factor +times the number of live tuples currently estimated to be in the relation\&. Similarly, it will initiate an +\fBANALYZE\fR +operation when the number of inserted, updated or deleted tuples exceeds +autovacuum_analyze_threshold +plus +autovacuum_analyze_scale_factor +times the number of live tuples currently estimated to be in the relation\&. If false, this table will not be autovacuumed, except to prevent transaction Id wraparound\&. See +Section 23.1.5, \(lqPreventing Transaction ID Wraparound Failures\(rq, in the documentation +for more about wraparound prevention\&. Observe that this variable inherits its value from the +autovacuum +setting\&. +.RE +.PP +autovacuum_vacuum_threshold, toast\&.autovacuum_vacuum_threshold (integer) +.RS 4 +Minimum number of updated or deleted tuples before initiate a +\fBVACUUM\fR +operation on a particular table\&. +.RE +.PP +autovacuum_vacuum_scale_factor, toast\&.autovacuum_vacuum_scale_factor (float4) +.RS 4 +Multiplier for +reltuples +to add to +autovacuum_vacuum_threshold\&. +.RE +.PP +autovacuum_analyze_threshold (integer) +.RS 4 +Minimum number of inserted, updated, or deleted tuples before initiate an +\fBANALYZE\fR +operation on a particular table\&. +.RE +.PP +autovacuum_analyze_scale_factor (float4) +.RS 4 +Multiplier for +reltuples +to add to +autovacuum_analyze_threshold\&. +.RE +.PP +autovacuum_vacuum_cost_delay, toast\&.autovacuum_vacuum_cost_delay (integer) +.RS 4 +Custom +autovacuum_vacuum_cost_delay +parameter\&. +.RE +.PP +autovacuum_vacuum_cost_limit, toast\&.autovacuum_vacuum_cost_limit (integer) +.RS 4 +Custom +autovacuum_vacuum_cost_limit +parameter\&. +.RE +.PP +autovacuum_freeze_min_age, toast\&.autovacuum_freeze_min_age (integer) +.RS 4 +Custom +vacuum_freeze_min_age +parameter\&. Note that autovacuum will ignore attempts to set a per\-table +autovacuum_freeze_min_age +larger than the half system\-wide +autovacuum_freeze_max_age +setting\&. +.RE +.PP +autovacuum_freeze_max_age, toast\&.autovacuum_freeze_max_age (integer) +.RS 4 +Custom +autovacuum_freeze_max_age +parameter\&. Note that autovacuum will ignore attempts to set a per\-table +autovacuum_freeze_max_age +larger than the system\-wide setting (it can only be set smaller)\&. Note that while you can set +autovacuum_freeze_max_age +very small, or even zero, this is usually unwise since it will force frequent vacuuming\&. +.RE +.PP +autovacuum_freeze_table_age, toast\&.autovacuum_freeze_table_age (integer) +.RS 4 +Custom +vacuum_freeze_table_age +parameter\&. +.RE +.SH "NOTES" +.PP +Using OIDs in new applications is not recommended: where possible, using a +SERIAL +or other sequence generator as the table\*(Aqs primary key is preferred\&. However, if your application does make use of OIDs to identify specific rows of a table, it is recommended to create a unique constraint on the +oid +column of that table, to ensure that OIDs in the table will indeed uniquely identify rows even after counter wraparound\&. Avoid assuming that OIDs are unique across tables; if you need a database\-wide unique identifier, use the combination of +tableoid +and row OID for the purpose\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBTip\fR +.ps -1 +.br +.PP +The use of +OIDS=FALSE +is not recommended for tables with no primary key, since without either an OID or a unique data key, it is difficult to identify specific rows\&. +.sp .5v +.RE +.PP + +PostgreSQL +automatically creates an index for each unique constraint and primary key constraint to enforce uniqueness\&. Thus, it is not necessary to create an index explicitly for primary key columns\&. (See +CREATE INDEX (\fBCREATE_INDEX\fR(7)) +for more information\&.) +.PP +Unique constraints and primary keys are not inherited in the current implementation\&. This makes the combination of inheritance and unique constraints rather dysfunctional\&. +.PP +A table cannot have more than 1600 columns\&. (In practice, the effective limit is usually lower because of tuple\-length constraints\&.) +.SH "EXAMPLES" +.PP +Create table +films +and table +distributors: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TABLE films ( + code char(5) CONSTRAINT firstkey PRIMARY KEY, + title varchar(40) NOT NULL, + did integer NOT NULL, + date_prod date, + kind varchar(10), + len interval hour to minute +); + +CREATE TABLE distributors ( + did integer PRIMARY KEY DEFAULT nextval(\*(Aqserial\*(Aq), + name varchar(40) NOT NULL CHECK (name <> \*(Aq\*(Aq) +); +.fi +.if n \{\ +.RE +.\} +.PP +Create a table with a 2\-dimensional array: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TABLE array_int ( + vector int[][] +); +.fi +.if n \{\ +.RE +.\} +.PP +Define a unique table constraint for the table +films\&. Unique table constraints can be defined on one or more columns of the table: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TABLE films ( + code char(5), + title varchar(40), + did integer, + date_prod date, + kind varchar(10), + len interval hour to minute, + CONSTRAINT production UNIQUE(date_prod) +); +.fi +.if n \{\ +.RE +.\} +.PP +Define a check column constraint: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TABLE distributors ( + did integer CHECK (did > 100), + name varchar(40) +); +.fi +.if n \{\ +.RE +.\} +.PP +Define a check table constraint: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TABLE distributors ( + did integer, + name varchar(40) + CONSTRAINT con1 CHECK (did > 100 AND name <> \*(Aq\*(Aq) +); +.fi +.if n \{\ +.RE +.\} +.PP +Define a primary key table constraint for the table +films: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TABLE films ( + code char(5), + title varchar(40), + did integer, + date_prod date, + kind varchar(10), + len interval hour to minute, + CONSTRAINT code_title PRIMARY KEY(code,title) +); +.fi +.if n \{\ +.RE +.\} +.PP +Define a primary key constraint for table +distributors\&. The following two examples are equivalent, the first using the table constraint syntax, the second the column constraint syntax: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TABLE distributors ( + did integer, + name varchar(40), + PRIMARY KEY(did) +); + +CREATE TABLE distributors ( + did integer PRIMARY KEY, + name varchar(40) +); +.fi +.if n \{\ +.RE +.\} +.PP +Assign a literal constant default value for the column +name, arrange for the default value of column +did +to be generated by selecting the next value of a sequence object, and make the default value of +modtime +be the time at which the row is inserted: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TABLE distributors ( + name varchar(40) DEFAULT \*(AqLuso Films\*(Aq, + did integer DEFAULT nextval(\*(Aqdistributors_serial\*(Aq), + modtime timestamp DEFAULT current_timestamp +); +.fi +.if n \{\ +.RE +.\} +.PP +Define two +NOT NULL +column constraints on the table +distributors, one of which is explicitly given a name: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TABLE distributors ( + did integer CONSTRAINT no_null NOT NULL, + name varchar(40) NOT NULL +); +.fi +.if n \{\ +.RE +.\} +.PP +Define a unique constraint for the +name +column: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TABLE distributors ( + did integer, + name varchar(40) UNIQUE +); +.fi +.if n \{\ +.RE +.\} +.sp +The same, specified as a table constraint: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TABLE distributors ( + did integer, + name varchar(40), + UNIQUE(name) +); +.fi +.if n \{\ +.RE +.\} +.PP +Create the same table, specifying 70% fill factor for both the table and its unique index: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TABLE distributors ( + did integer, + name varchar(40), + UNIQUE(name) WITH (fillfactor=70) +) +WITH (fillfactor=70); +.fi +.if n \{\ +.RE +.\} +.PP +Create table +circles +with an exclusion constraint that prevents any two circles from overlapping: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TABLE circles ( + c circle, + EXCLUDE USING gist (c WITH &&) +); +.fi +.if n \{\ +.RE +.\} +.PP +Create table +cinemas +in tablespace +diskvol1: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TABLE cinemas ( + id serial, + name text, + location text +) TABLESPACE diskvol1; +.fi +.if n \{\ +.RE +.\} +.PP +Create a composite type and a typed table: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TYPE employee_type AS (name text, salary numeric); + +CREATE TABLE employees OF employee_type ( + PRIMARY KEY (name), + salary WITH OPTIONS DEFAULT 1000 +); +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +The +\fBCREATE TABLE\fR +command conforms to the +SQL +standard, with exceptions listed below\&. +.SS "Temporary Tables" +.PP +Although the syntax of +CREATE TEMPORARY TABLE +resembles that of the SQL standard, the effect is not the same\&. In the standard, temporary tables are defined just once and automatically exist (starting with empty contents) in every session that needs them\&. +PostgreSQL +instead requires each session to issue its own +CREATE TEMPORARY TABLE +command for each temporary table to be used\&. This allows different sessions to use the same temporary table name for different purposes, whereas the standard\*(Aqs approach constrains all instances of a given temporary table name to have the same table structure\&. +.PP +The standard\*(Aqs definition of the behavior of temporary tables is widely ignored\&. +PostgreSQL\*(Aqs behavior on this point is similar to that of several other SQL databases\&. +.PP +The SQL standard also distinguishes between global and local temporary tables, where a local temporary table has a separate set of contents for each SQL module within each session, though its definition is still shared across sessions\&. Since +PostgreSQL +does not support SQL modules, this distinction is not relevant in +PostgreSQL\&. +.PP +For compatibility\*(Aqs sake, +PostgreSQL +will accept the +GLOBAL +and +LOCAL +keywords in a temporary table declaration, but they currently have no effect\&. Use of these keywords is discouraged, since future versions of +PostgreSQL +might adopt a more standard\-compliant interpretation of their meaning\&. +.PP +The +ON COMMIT +clause for temporary tables also resembles the SQL standard, but has some differences\&. If the +ON COMMIT +clause is omitted, SQL specifies that the default behavior is +ON COMMIT DELETE ROWS\&. However, the default behavior in +PostgreSQL +is +ON COMMIT PRESERVE ROWS\&. The +ON COMMIT DROP +option does not exist in SQL\&. +.SS "Non\-deferred Uniqueness Constraints" +.PP +When a +UNIQUE +or +PRIMARY KEY +constraint is not deferrable, +PostgreSQL +checks for uniqueness immediately whenever a row is inserted or modified\&. The SQL standard says that uniqueness should be enforced only at the end of the statement; this makes a difference when, for example, a single command updates multiple key values\&. To obtain standard\-compliant behavior, declare the constraint as +DEFERRABLE +but not deferred (i\&.e\&., +INITIALLY IMMEDIATE)\&. Be aware that this can be significantly slower than immediate uniqueness checking\&. +.SS "Column Check Constraints" +.PP +The SQL standard says that +CHECK +column constraints can only refer to the column they apply to; only +CHECK +table constraints can refer to multiple columns\&. +PostgreSQL +does not enforce this restriction; it treats column and table check constraints alike\&. +.SS "EXCLUDE Constraint" +.PP +The +EXCLUDE +constraint type is a +PostgreSQL +extension\&. +.SS "NULL \(lqConstraint\(rq" +.PP +The +NULL +\(lqconstraint\(rq +(actually a non\-constraint) is a +PostgreSQL +extension to the SQL standard that is included for compatibility with some other database systems (and for symmetry with the +NOT NULL +constraint)\&. Since it is the default for any column, its presence is simply noise\&. +.SS "Inheritance" +.PP +Multiple inheritance via the +INHERITS +clause is a +PostgreSQL +language extension\&. SQL:1999 and later define single inheritance using a different syntax and different semantics\&. SQL:1999\-style inheritance is not yet supported by +PostgreSQL\&. +.SS "Zero\-column Tables" +.PP + +PostgreSQL +allows a table of no columns to be created (for example, +CREATE TABLE foo();)\&. This is an extension from the SQL standard, which does not allow zero\-column tables\&. Zero\-column tables are not in themselves very useful, but disallowing them creates odd special cases for +\fBALTER TABLE DROP COLUMN\fR, so it seems cleaner to ignore this spec restriction\&. +.SS "WITH Clause" +.PP +The +WITH +clause is a +PostgreSQL +extension; neither storage parameters nor OIDs are in the standard\&. +.SS "Tablespaces" +.PP +The +PostgreSQL +concept of tablespaces is not part of the standard\&. Hence, the clauses +TABLESPACE +and +USING INDEX TABLESPACE +are extensions\&. +.SS "Typed Tables" +.PP +Typed tables implement a subset of the SQL standard\&. According to the standard, a typed table has columns corresponding to the underlying composite type as well as one other column that is the +\(lqself\-referencing column\(rq\&. PostgreSQL does not support these self\-referencing columns explicitly, but the same effect can be had using the OID feature\&. +.SH "SEE ALSO" +ALTER TABLE (\fBALTER_TABLE\fR(7)), DROP TABLE (\fBDROP_TABLE\fR(7)), CREATE TABLESPACE (\fBCREATE_TABLESPACE\fR(7)), CREATE TYPE (\fBCREATE_TYPE\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_TABLESPACE.7 b/doc/src/sgml/man7/CREATE_TABLESPACE.7 new file mode 100644 index 000000000..9c94a72d6 --- /dev/null +++ b/doc/src/sgml/man7/CREATE_TABLESPACE.7 @@ -0,0 +1,122 @@ +'\" t +.\" Title: CREATE TABLESPACE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE TABLESPACE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_TABLESPACE \- define a new tablespace +.\" CREATE TABLESPACE +.SH "SYNOPSIS" +.sp +.nf +CREATE TABLESPACE \fItablespace_name\fR [ OWNER \fIuser_name\fR ] LOCATION \*(Aq\fIdirectory\fR\*(Aq +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE TABLESPACE\fR +registers a new cluster\-wide tablespace\&. The tablespace name must be distinct from the name of any existing tablespace in the database cluster\&. +.PP +A tablespace allows superusers to define an alternative location on the file system where the data files containing database objects (such as tables and indexes) can reside\&. +.PP +A user with appropriate privileges can pass +\fItablespace_name\fR +to +\fBCREATE DATABASE\fR, +\fBCREATE TABLE\fR, +\fBCREATE INDEX\fR +or +\fBADD CONSTRAINT\fR +to have the data files for these objects stored within the specified tablespace\&. +.SH "PARAMETERS" +.PP +\fItablespace_name\fR +.RS 4 +The name of a tablespace to be created\&. The name cannot begin with +pg_, as such names are reserved for system tablespaces\&. +.RE +.PP +\fIuser_name\fR +.RS 4 +The name of the user who will own the tablespace\&. If omitted, defaults to the user executing the command\&. Only superusers can create tablespaces, but they can assign ownership of tablespaces to non\-superusers\&. +.RE +.PP +\fIdirectory\fR +.RS 4 +The directory that will be used for the tablespace\&. The directory should be empty and must be owned by the +PostgreSQL +system user\&. The directory must be specified by an absolute path name\&. +.RE +.SH "NOTES" +.PP +Tablespaces are only supported on systems that support symbolic links\&. +.PP + +\fBCREATE TABLESPACE\fR +cannot be executed inside a transaction block\&. +.SH "EXAMPLES" +.PP +Create a tablespace +dbspace +at +/data/dbs: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TABLESPACE dbspace LOCATION \*(Aq/data/dbs\*(Aq; +.fi +.if n \{\ +.RE +.\} +.PP +Create a tablespace +indexspace +at +/data/indexes +owned by user +genevieve: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TABLESPACE indexspace OWNER genevieve LOCATION \*(Aq/data/indexes\*(Aq; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBCREATE TABLESPACE\fR +is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +CREATE DATABASE (\fBCREATE_DATABASE\fR(7)), CREATE TABLE (\fBCREATE_TABLE\fR(7)), CREATE INDEX (\fBCREATE_INDEX\fR(7)), DROP TABLESPACE (\fBDROP_TABLESPACE\fR(7)), ALTER TABLESPACE (\fBALTER_TABLESPACE\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_TABLE_AS.7 b/doc/src/sgml/man7/CREATE_TABLE_AS.7 new file mode 100644 index 000000000..6989a5be0 --- /dev/null +++ b/doc/src/sgml/man7/CREATE_TABLE_AS.7 @@ -0,0 +1,326 @@ +'\" t +.\" Title: CREATE TABLE AS +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE TABLE AS" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_TABLE_AS \- define a new table from the results of a query +.\" CREATE TABLE AS +.SH "SYNOPSIS" +.sp +.nf +CREATE [ [ GLOBAL | LOCAL ] { TEMPORARY | TEMP } | UNLOGGED ] TABLE \fItable_name\fR + [ (\fIcolumn_name\fR [, \&.\&.\&.] ) ] + [ WITH ( \fIstorage_parameter\fR [= \fIvalue\fR] [, \&.\&.\&. ] ) | WITH OIDS | WITHOUT OIDS ] + [ ON COMMIT { PRESERVE ROWS | DELETE ROWS | DROP } ] + [ TABLESPACE \fItablespace_name\fR ] + AS \fIquery\fR + [ WITH [ NO ] DATA ] +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE TABLE AS\fR +creates a table and fills it with data computed by a +\fBSELECT\fR +command\&. The table columns have the names and data types associated with the output columns of the +\fBSELECT\fR +(except that you can override the column names by giving an explicit list of new column names)\&. +.PP + +\fBCREATE TABLE AS\fR +bears some resemblance to creating a view, but it is really quite different: it creates a new table and evaluates the query just once to fill the new table initially\&. The new table will not track subsequent changes to the source tables of the query\&. In contrast, a view re\-evaluates its defining +\fBSELECT\fR +statement whenever it is queried\&. +.SH "PARAMETERS" +.PP +GLOBAL or LOCAL +.RS 4 +Ignored for compatibility\&. Use of these keywords is deprecated; refer to +CREATE TABLE (\fBCREATE_TABLE\fR(7)) +for details\&. +.RE +.PP +TEMPORARY or TEMP +.RS 4 +If specified, the table is created as a temporary table\&. Refer to +CREATE TABLE (\fBCREATE_TABLE\fR(7)) +for details\&. +.RE +.PP +UNLOGGED +.RS 4 +If specified, the table is created as an unlogged table\&. Refer to +CREATE TABLE (\fBCREATE_TABLE\fR(7)) +for details\&. +.RE +.PP +\fItable_name\fR +.RS 4 +The name (optionally schema\-qualified) of the table to be created\&. +.RE +.PP +\fIcolumn_name\fR +.RS 4 +The name of a column in the new table\&. If column names are not provided, they are taken from the output column names of the query\&. +.RE +.PP +WITH ( \fIstorage_parameter\fR [= \fIvalue\fR] [, \&.\&.\&. ] ) +.RS 4 +This clause specifies optional storage parameters for the new table; see +Storage Parameters +for more information\&. The +WITH +clause can also include +OIDS=TRUE +(or just +OIDS) to specify that rows of the new table should have OIDs (object identifiers) assigned to them, or +OIDS=FALSE +to specify that the rows should not have OIDs\&. See +CREATE TABLE (\fBCREATE_TABLE\fR(7)) +for more information\&. +.RE +.PP +WITH OIDS, WITHOUT OIDS +.RS 4 +These are obsolescent syntaxes equivalent to +WITH (OIDS) +and +WITH (OIDS=FALSE), respectively\&. If you wish to give both an +OIDS +setting and storage parameters, you must use the +WITH ( \&.\&.\&. ) +syntax; see above\&. +.RE +.PP +ON COMMIT +.RS 4 +The behavior of temporary tables at the end of a transaction block can be controlled using +ON COMMIT\&. The three options are: +.PP +PRESERVE ROWS +.RS 4 +No special action is taken at the ends of transactions\&. This is the default behavior\&. +.RE +.PP +DELETE ROWS +.RS 4 +All rows in the temporary table will be deleted at the end of each transaction block\&. Essentially, an automatic +\fBTRUNCATE\fR(7) +is done at each commit\&. +.RE +.PP +DROP +.RS 4 +The temporary table will be dropped at the end of the current transaction block\&. +.RE +.RE +.PP +TABLESPACE \fItablespace_name\fR +.RS 4 +The +\fItablespace_name\fR +is the name of the tablespace in which the new table is to be created\&. If not specified, +default_tablespace +is consulted, or +temp_tablespaces +if the table is temporary\&. +.RE +.PP +\fIquery\fR +.RS 4 +A +\fBSELECT\fR(7), +TABLE, or +\fBVALUES\fR(7) +command, or an +\fBEXECUTE\fR(7) +command that runs a prepared +\fBSELECT\fR, +\fBTABLE\fR, or +\fBVALUES\fR +query\&. +.RE +.PP +WITH [ NO ] DATA +.RS 4 +This clause specifies whether or not the data produced by the query should be copied into the new table\&. If not, only the table structure is copied\&. The default is to copy the data\&. +.RE +.SH "NOTES" +.PP +This command is functionally similar to +SELECT INTO (\fBSELECT_INTO\fR(7)), but it is preferred since it is less likely to be confused with other uses of the +\fBSELECT INTO\fR +syntax\&. Furthermore, +\fBCREATE TABLE AS\fR +offers a superset of the functionality offered by +\fBSELECT INTO\fR\&. +.PP +Prior to +PostgreSQL +8\&.0, +\fBCREATE TABLE AS\fR +always included OIDs in the table it created\&. As of +PostgreSQL +8\&.0, the +\fBCREATE TABLE AS\fR +command allows the user to explicitly specify whether OIDs should be included\&. If the presence of OIDs is not explicitly specified, the +default_with_oids +configuration variable is used\&. As of +PostgreSQL +8\&.1, this variable is false by default, so the default behavior is not identical to pre\-8\&.0 releases\&. Applications that require OIDs in the table created by +\fBCREATE TABLE AS\fR +should explicitly specify +WITH (OIDS) +to ensure desired behavior\&. +.SH "EXAMPLES" +.PP +Create a new table +films_recent +consisting of only recent entries from the table +films: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TABLE films_recent AS + SELECT * FROM films WHERE date_prod >= \*(Aq2002\-01\-01\*(Aq; +.fi +.if n \{\ +.RE +.\} +.PP +To copy a table completely, the short form using the +TABLE +command can also be used: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TABLE films2 AS + TABLE films; +.fi +.if n \{\ +.RE +.\} +.PP +Create a new temporary table +films_recent, consisting of only recent entries from the table +films, using a prepared statement\&. The new table has OIDs and will be dropped at commit: +.sp +.if n \{\ +.RS 4 +.\} +.nf +PREPARE recentfilms(date) AS + SELECT * FROM films WHERE date_prod > $1; +CREATE TEMP TABLE films_recent WITH (OIDS) ON COMMIT DROP AS + EXECUTE recentfilms(\*(Aq2002\-01\-01\*(Aq); +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBCREATE TABLE AS\fR +conforms to the +SQL +standard\&. The following are nonstandard extensions: +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +The standard requires parentheses around the subquery clause; in +PostgreSQL, these parentheses are optional\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +In the standard, the +WITH [ NO ] DATA +clause is required; in PostgreSQL it is optional\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +PostgreSQL +handles temporary tables in a way rather different from the standard; see +CREATE TABLE (\fBCREATE_TABLE\fR(7)) +for details\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +The +WITH +clause is a +PostgreSQL +extension; neither storage parameters nor OIDs are in the standard\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +The +PostgreSQL +concept of tablespaces is not part of the standard\&. Hence, the clause +TABLESPACE +is an extension\&. +.RE +.SH "SEE ALSO" +CREATE TABLE (\fBCREATE_TABLE\fR(7)), \fBEXECUTE\fR(7), \fBSELECT\fR(7), SELECT INTO (\fBSELECT_INTO\fR(7)), \fBVALUES\fR(7) diff --git a/doc/src/sgml/man7/CREATE_TEXT_SEARCH_CONFIGURATION.7 b/doc/src/sgml/man7/CREATE_TEXT_SEARCH_CONFIGURATION.7 new file mode 100644 index 000000000..9139ff8cc --- /dev/null +++ b/doc/src/sgml/man7/CREATE_TEXT_SEARCH_CONFIGURATION.7 @@ -0,0 +1,87 @@ +'\" t +.\" Title: CREATE TEXT SEARCH CONFIGURATION +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE TEXT SEARCH CONFIGURATION" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_TEXT_SEARCH_CONFIGURATION \- define a new text search configuration +.\" CREATE TEXT SEARCH CONFIGURATION +.SH "SYNOPSIS" +.sp +.nf +CREATE TEXT SEARCH CONFIGURATION \fIname\fR ( + PARSER = \fIparser_name\fR | + COPY = \fIsource_config\fR +) +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE TEXT SEARCH CONFIGURATION\fR +creates a new text search configuration\&. A text search configuration specifies a text search parser that can divide a string into tokens, plus dictionaries that can be used to determine which tokens are of interest for searching\&. +.PP +If only the parser is specified, then the new text search configuration initially has no mappings from token types to dictionaries, and therefore will ignore all words\&. Subsequent +\fBALTER TEXT SEARCH CONFIGURATION\fR +commands must be used to create mappings to make the configuration useful\&. Alternatively, an existing text search configuration can be copied\&. +.PP +If a schema name is given then the text search configuration is created in the specified schema\&. Otherwise it is created in the current schema\&. +.PP +The user who defines a text search configuration becomes its owner\&. +.PP +Refer to +Chapter 12, Full Text Search, in the documentation +for further information\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name of the text search configuration to be created\&. The name can be schema\-qualified\&. +.RE +.PP +\fIparser_name\fR +.RS 4 +The name of the text search parser to use for this configuration\&. +.RE +.PP +\fIsource_config\fR +.RS 4 +The name of an existing text search configuration to copy\&. +.RE +.SH "NOTES" +.PP +The +PARSER +and +COPY +options are mutually exclusive, because when an existing configuration is copied, its parser selection is copied too\&. +.SH "COMPATIBILITY" +.PP +There is no +\fBCREATE TEXT SEARCH CONFIGURATION\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +ALTER TEXT SEARCH CONFIGURATION (\fBALTER_TEXT_SEARCH_CONFIGURATION\fR(7)), DROP TEXT SEARCH CONFIGURATION (\fBDROP_TEXT_SEARCH_CONFIGURATION\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_TEXT_SEARCH_DICTIONARY.7 b/doc/src/sgml/man7/CREATE_TEXT_SEARCH_DICTIONARY.7 new file mode 100644 index 000000000..09f744484 --- /dev/null +++ b/doc/src/sgml/man7/CREATE_TEXT_SEARCH_DICTIONARY.7 @@ -0,0 +1,100 @@ +'\" t +.\" Title: CREATE TEXT SEARCH DICTIONARY +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE TEXT SEARCH DICTIONARY" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_TEXT_SEARCH_DICTIONARY \- define a new text search dictionary +.\" CREATE TEXT SEARCH DICTIONARY +.SH "SYNOPSIS" +.sp +.nf +CREATE TEXT SEARCH DICTIONARY \fIname\fR ( + TEMPLATE = \fItemplate\fR + [, \fIoption\fR = \fIvalue\fR [, \&.\&.\&. ]] +) +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE TEXT SEARCH DICTIONARY\fR +creates a new text search dictionary\&. A text search dictionary specifies a way of recognizing interesting or uninteresting words for searching\&. A dictionary depends on a text search template, which specifies the functions that actually perform the work\&. Typically the dictionary provides some options that control the detailed behavior of the template\*(Aqs functions\&. +.PP +If a schema name is given then the text search dictionary is created in the specified schema\&. Otherwise it is created in the current schema\&. +.PP +The user who defines a text search dictionary becomes its owner\&. +.PP +Refer to +Chapter 12, Full Text Search, in the documentation +for further information\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name of the text search dictionary to be created\&. The name can be schema\-qualified\&. +.RE +.PP +\fItemplate\fR +.RS 4 +The name of the text search template that will define the basic behavior of this dictionary\&. +.RE +.PP +\fIoption\fR +.RS 4 +The name of a template\-specific option to be set for this dictionary\&. +.RE +.PP +\fIvalue\fR +.RS 4 +The value to use for a template\-specific option\&. If the value is not a simple identifier or number, it must be quoted (but you can always quote it, if you wish)\&. +.RE +.PP +The options can appear in any order\&. +.SH "EXAMPLES" +.PP +The following example command creates a Snowball\-based dictionary with a nonstandard list of stop words\&. +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TEXT SEARCH DICTIONARY my_russian ( + template = snowball, + language = russian, + stopwords = myrussian +); +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBCREATE TEXT SEARCH DICTIONARY\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +ALTER TEXT SEARCH DICTIONARY (\fBALTER_TEXT_SEARCH_DICTIONARY\fR(7)), DROP TEXT SEARCH DICTIONARY (\fBDROP_TEXT_SEARCH_DICTIONARY\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_TEXT_SEARCH_PARSER.7 b/doc/src/sgml/man7/CREATE_TEXT_SEARCH_PARSER.7 new file mode 100644 index 000000000..b9b7512c5 --- /dev/null +++ b/doc/src/sgml/man7/CREATE_TEXT_SEARCH_PARSER.7 @@ -0,0 +1,99 @@ +'\" t +.\" Title: CREATE TEXT SEARCH PARSER +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE TEXT SEARCH PARSER" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_TEXT_SEARCH_PARSER \- define a new text search parser +.\" CREATE TEXT SEARCH PARSER +.SH "SYNOPSIS" +.sp +.nf +CREATE TEXT SEARCH PARSER \fIname\fR ( + START = \fIstart_function\fR , + GETTOKEN = \fIgettoken_function\fR , + END = \fIend_function\fR , + LEXTYPES = \fIlextypes_function\fR + [, HEADLINE = \fIheadline_function\fR ] +) +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE TEXT SEARCH PARSER\fR +creates a new text search parser\&. A text search parser defines a method for splitting a text string into tokens and assigning types (categories) to the tokens\&. A parser is not particularly useful by itself, but must be bound into a text search configuration along with some text search dictionaries to be used for searching\&. +.PP +If a schema name is given then the text search parser is created in the specified schema\&. Otherwise it is created in the current schema\&. +.PP +You must be a superuser to use +\fBCREATE TEXT SEARCH PARSER\fR\&. (This restriction is made because an erroneous text search parser definition could confuse or even crash the server\&.) +.PP +Refer to +Chapter 12, Full Text Search, in the documentation +for further information\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name of the text search parser to be created\&. The name can be schema\-qualified\&. +.RE +.PP +\fIstart_function\fR +.RS 4 +The name of the start function for the parser\&. +.RE +.PP +\fIgettoken_function\fR +.RS 4 +The name of the get\-next\-token function for the parser\&. +.RE +.PP +\fIend_function\fR +.RS 4 +The name of the end function for the parser\&. +.RE +.PP +\fIlextypes_function\fR +.RS 4 +The name of the lextypes function for the parser (a function that returns information about the set of token types it produces)\&. +.RE +.PP +\fIheadline_function\fR +.RS 4 +The name of the headline function for the parser (a function that summarizes a set of tokens)\&. +.RE +.PP +The function names can be schema\-qualified if necessary\&. Argument types are not given, since the argument list for each type of function is predetermined\&. All except the headline function are required\&. +.PP +The arguments can appear in any order, not only the one shown above\&. +.SH "COMPATIBILITY" +.PP +There is no +\fBCREATE TEXT SEARCH PARSER\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +ALTER TEXT SEARCH PARSER (\fBALTER_TEXT_SEARCH_PARSER\fR(7)), DROP TEXT SEARCH PARSER (\fBDROP_TEXT_SEARCH_PARSER\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_TEXT_SEARCH_TEMPLATE.7 b/doc/src/sgml/man7/CREATE_TEXT_SEARCH_TEMPLATE.7 new file mode 100644 index 000000000..7d4d0a3df --- /dev/null +++ b/doc/src/sgml/man7/CREATE_TEXT_SEARCH_TEMPLATE.7 @@ -0,0 +1,83 @@ +'\" t +.\" Title: CREATE TEXT SEARCH TEMPLATE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE TEXT SEARCH TEMPLATE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_TEXT_SEARCH_TEMPLATE \- define a new text search template +.\" CREATE TEXT SEARCH TEMPLATE +.SH "SYNOPSIS" +.sp +.nf +CREATE TEXT SEARCH TEMPLATE \fIname\fR ( + [ INIT = \fIinit_function\fR , ] + LEXIZE = \fIlexize_function\fR +) +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE TEXT SEARCH TEMPLATE\fR +creates a new text search template\&. Text search templates define the functions that implement text search dictionaries\&. A template is not useful by itself, but must be instantiated as a dictionary to be used\&. The dictionary typically specifies parameters to be given to the template functions\&. +.PP +If a schema name is given then the text search template is created in the specified schema\&. Otherwise it is created in the current schema\&. +.PP +You must be a superuser to use +\fBCREATE TEXT SEARCH TEMPLATE\fR\&. This restriction is made because an erroneous text search template definition could confuse or even crash the server\&. The reason for separating templates from dictionaries is that a template encapsulates the +\(lqunsafe\(rq +aspects of defining a dictionary\&. The parameters that can be set when defining a dictionary are safe for unprivileged users to set, and so creating a dictionary need not be a privileged operation\&. +.PP +Refer to +Chapter 12, Full Text Search, in the documentation +for further information\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name of the text search template to be created\&. The name can be schema\-qualified\&. +.RE +.PP +\fIinit_function\fR +.RS 4 +The name of the init function for the template\&. +.RE +.PP +\fIlexize_function\fR +.RS 4 +The name of the lexize function for the template\&. +.RE +.PP +The function names can be schema\-qualified if necessary\&. Argument types are not given, since the argument list for each type of function is predetermined\&. The lexize function is required, but the init function is optional\&. +.PP +The arguments can appear in any order, not only the one shown above\&. +.SH "COMPATIBILITY" +.PP +There is no +\fBCREATE TEXT SEARCH TEMPLATE\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +ALTER TEXT SEARCH TEMPLATE (\fBALTER_TEXT_SEARCH_TEMPLATE\fR(7)), DROP TEXT SEARCH TEMPLATE (\fBDROP_TEXT_SEARCH_TEMPLATE\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_TRIGGER.7 b/doc/src/sgml/man7/CREATE_TRIGGER.7 new file mode 100644 index 000000000..308b5db33 --- /dev/null +++ b/doc/src/sgml/man7/CREATE_TRIGGER.7 @@ -0,0 +1,555 @@ +'\" t +.\" Title: CREATE TRIGGER +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE TRIGGER" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_TRIGGER \- define a new trigger +.\" CREATE TRIGGER +.SH "SYNOPSIS" +.sp +.nf +CREATE [ CONSTRAINT ] TRIGGER \fIname\fR { BEFORE | AFTER | INSTEAD OF } { \fIevent\fR [ OR \&.\&.\&. ] } + ON \fItable_name\fR + [ FROM \fIreferenced_table_name\fR ] + { NOT DEFERRABLE | [ DEFERRABLE ] { INITIALLY IMMEDIATE | INITIALLY DEFERRED } } + [ FOR [ EACH ] { ROW | STATEMENT } ] + [ WHEN ( \fIcondition\fR ) ] + EXECUTE PROCEDURE \fIfunction_name\fR ( \fIarguments\fR ) + +where \fIevent\fR can be one of: + + INSERT + UPDATE [ OF \fIcolumn_name\fR [, \&.\&.\&. ] ] + DELETE + TRUNCATE +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE TRIGGER\fR +creates a new trigger\&. The trigger will be associated with the specified table or view and will execute the specified function +\fIfunction_name\fR +when certain events occur\&. +.PP +The trigger can be specified to fire before the operation is attempted on a row (before constraints are checked and the +\fBINSERT\fR, +\fBUPDATE\fR, or +\fBDELETE\fR +is attempted); or after the operation has completed (after constraints are checked and the +\fBINSERT\fR, +\fBUPDATE\fR, or +\fBDELETE\fR +has completed); or instead of the operation (in the case of inserts, updates or deletes on a view)\&. If the trigger fires before or instead of the event, the trigger can skip the operation for the current row, or change the row being inserted (for +\fBINSERT\fR +and +\fBUPDATE\fR +operations only)\&. If the trigger fires after the event, all changes, including the effects of other triggers, are +\(lqvisible\(rq +to the trigger\&. +.PP +A trigger that is marked +FOR EACH ROW +is called once for every row that the operation modifies\&. For example, a +\fBDELETE\fR +that affects 10 rows will cause any +ON DELETE +triggers on the target relation to be called 10 separate times, once for each deleted row\&. In contrast, a trigger that is marked +FOR EACH STATEMENT +only executes once for any given operation, regardless of how many rows it modifies (in particular, an operation that modifies zero rows will still result in the execution of any applicable +FOR EACH STATEMENT +triggers)\&. +.PP +Triggers that are specified to fire +INSTEAD OF +the trigger event must be marked +FOR EACH ROW, and can only be defined on views\&. +BEFORE +and +AFTER +triggers on a view must be marked as +FOR EACH STATEMENT\&. +.PP +In addition, triggers may be defined to fire for +\fBTRUNCATE\fR, though only +FOR EACH STATEMENT\&. +.PP +The following table summarizes which types of triggers may be used on tables and views: +.TS +allbox tab(:); +lB lB lB lB. +T{ +When +T}:T{ +Event +T}:T{ +Row\-level +T}:T{ +Statement\-level +T} +.T& +c c c c +^ c c c +c c c c +^ c c c +c c c c +^ c c c. +T{ +BEFORE +T}:T{ +\fBINSERT\fR/\fBUPDATE\fR/\fBDELETE\fR +T}:T{ +Tables +T}:T{ +Tables and views +T} +:T{ +\fBTRUNCATE\fR +T}:T{ +\(em +T}:T{ +Tables +T} +T{ +AFTER +T}:T{ +\fBINSERT\fR/\fBUPDATE\fR/\fBDELETE\fR +T}:T{ +Tables +T}:T{ +Tables and views +T} +:T{ +\fBTRUNCATE\fR +T}:T{ +\(em +T}:T{ +Tables +T} +T{ +INSTEAD OF +T}:T{ +\fBINSERT\fR/\fBUPDATE\fR/\fBDELETE\fR +T}:T{ +Views +T}:T{ +\(em +T} +:T{ +\fBTRUNCATE\fR +T}:T{ +\(em +T}:T{ +\(em +T} +.TE +.sp 1 +.PP +Also, a trigger definition can specify a Boolean +WHEN +condition, which will be tested to see whether the trigger should be fired\&. In row\-level triggers the +WHEN +condition can examine the old and/or new values of columns of the row\&. Statement\-level triggers can also have +WHEN +conditions, although the feature is not so useful for them since the condition cannot refer to any values in the table\&. +.PP +If multiple triggers of the same kind are defined for the same event, they will be fired in alphabetical order by name\&. +.PP +When the +CONSTRAINT +option is specified, this command creates a +constraint trigger\&. This is the same as a regular trigger except that the timing of the trigger firing can be adjusted using +SET CONSTRAINTS (\fBSET_CONSTRAINTS\fR(7))\&. Constraint triggers must be +AFTER ROW +triggers\&. They can be fired either at the end of the statement causing the triggering event, or at the end of the containing transaction; in the latter case they are said to be +deferred\&. A pending deferred\-trigger firing can also be forced to happen immediately by using +\fBSET CONSTRAINTS\fR\&. Constraint triggers are expected to raise an exception when the constraints they implement are violated\&. +.PP + +\fBSELECT\fR +does not modify any rows so you cannot create +\fBSELECT\fR +triggers\&. Rules and views are more appropriate in such cases\&. +.PP +Refer to +Chapter 36, Triggers, in the documentation +for more information about triggers\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name to give the new trigger\&. This must be distinct from the name of any other trigger for the same table\&. The name cannot be schema\-qualified \(em the trigger inherits the schema of its table\&. For a constraint trigger, this is also the name to use when modifying the trigger\*(Aqs behavior using +\fBSET CONSTRAINTS\fR\&. +.RE +.PP +BEFORE, AFTER, INSTEAD OF +.RS 4 +Determines whether the function is called before, after, or instead of the event\&. A constraint trigger can only be specified as +AFTER\&. +.RE +.PP +\fIevent\fR +.RS 4 +One of +INSERT, +UPDATE, +DELETE, or +TRUNCATE; this specifies the event that will fire the trigger\&. Multiple events can be specified using +OR\&. +.sp +For +UPDATE +events, it is possible to specify a list of columns using this syntax: +.sp +.if n \{\ +.RS 4 +.\} +.nf +UPDATE OF \fIcolumn_name1\fR [, \fIcolumn_name2\fR \&.\&.\&. ] +.fi +.if n \{\ +.RE +.\} +.sp + +The trigger will only fire if at least one of the listed columns is mentioned as a target of the +\fBUPDATE\fR +command\&. +.sp +INSTEAD OF UPDATE +events do not support lists of columns\&. +.RE +.PP +\fItable_name\fR +.RS 4 +The name (optionally schema\-qualified) of the table or view the trigger is for\&. +.RE +.PP +\fIreferenced_table_name\fR +.RS 4 +The (possibly schema\-qualified) name of another table referenced by the constraint\&. This option is used for foreign\-key constraints and is not recommended for general use\&. This can only be specified for constraint triggers\&. +.RE +.PP +DEFERRABLE, NOT DEFERRABLE, INITIALLY IMMEDIATE, INITIALLY DEFERRED +.RS 4 +The default timing of the trigger\&. See the +CREATE TABLE (\fBCREATE_TABLE\fR(7)) +documentation for details of these constraint options\&. This can only be specified for constraint triggers\&. +.RE +.PP +FOR EACH ROW, FOR EACH STATEMENT +.RS 4 +This specifies whether the trigger procedure should be fired once for every row affected by the trigger event, or just once per SQL statement\&. If neither is specified, +FOR EACH STATEMENT +is the default\&. Constraint triggers can only be specified +FOR EACH ROW\&. +.RE +.PP +\fIcondition\fR +.RS 4 +A Boolean expression that determines whether the trigger function will actually be executed\&. If +WHEN +is specified, the function will only be called if the +\fIcondition\fR +returns +true\&. In +FOR EACH ROW +triggers, the +WHEN +condition can refer to columns of the old and/or new row values by writing +OLD\&.\fIcolumn_name\fR +or +NEW\&.\fIcolumn_name\fR +respectively\&. Of course, +INSERT +triggers cannot refer to +OLD +and +DELETE +triggers cannot refer to +NEW\&. +.sp +INSTEAD OF +triggers do not support +WHEN +conditions\&. +.sp +Currently, +WHEN +expressions cannot contain subqueries\&. +.sp +Note that for constraint triggers, evaluation of the +WHEN +condition is not deferred, but occurs immediately after the row update operation is performed\&. If the condition does not evaluate to true then the trigger is not queued for deferred execution\&. +.RE +.PP +\fIfunction_name\fR +.RS 4 +A user\-supplied function that is declared as taking no arguments and returning type +trigger, which is executed when the trigger fires\&. +.RE +.PP +\fIarguments\fR +.RS 4 +An optional comma\-separated list of arguments to be provided to the function when the trigger is executed\&. The arguments are literal string constants\&. Simple names and numeric constants can be written here, too, but they will all be converted to strings\&. Please check the description of the implementation language of the trigger function to find out how these arguments can be accessed within the function; it might be different from normal function arguments\&. +.RE +.SH "NOTES" +.PP +To create a trigger on a table, the user must have the +TRIGGER +privilege on the table\&. The user must also have +EXECUTE +privilege on the trigger function\&. +.PP +Use +DROP TRIGGER (\fBDROP_TRIGGER\fR(7)) +to remove a trigger\&. +.PP +A column\-specific trigger (one defined using the +UPDATE OF \fIcolumn_name\fR +syntax) will fire when any of its columns are listed as targets in the +\fBUPDATE\fR +command\*(Aqs +SET +list\&. It is possible for a column\*(Aqs value to change even when the trigger is not fired, because changes made to the row\*(Aqs contents by +BEFORE UPDATE +triggers are not considered\&. Conversely, a command such as +UPDATE \&.\&.\&. SET x = x \&.\&.\&. +will fire a trigger on column +x, even though the column\*(Aqs value did not change\&. +.PP +In a +BEFORE +trigger, the +WHEN +condition is evaluated just before the function is or would be executed, so using +WHEN +is not materially different from testing the same condition at the beginning of the trigger function\&. Note in particular that the +NEW +row seen by the condition is the current value, as possibly modified by earlier triggers\&. Also, a +BEFORE +trigger\*(Aqs +WHEN +condition is not allowed to examine the system columns of the +NEW +row (such as +oid), because those won\*(Aqt have been set yet\&. +.PP +In an +AFTER +trigger, the +WHEN +condition is evaluated just after the row update occurs, and it determines whether an event is queued to fire the trigger at the end of statement\&. So when an +AFTER +trigger\*(Aqs +WHEN +condition does not return true, it is not necessary to queue an event nor to re\-fetch the row at end of statement\&. This can result in significant speedups in statements that modify many rows, if the trigger only needs to be fired for a few of the rows\&. +.PP +In +PostgreSQL +versions before 7\&.3, it was necessary to declare trigger functions as returning the placeholder type +opaque, rather than +trigger\&. To support loading of old dump files, +\fBCREATE TRIGGER\fR +will accept a function declared as returning +opaque, but it will issue a notice and change the function\*(Aqs declared return type to +trigger\&. +.SH "EXAMPLES" +.PP +Execute the function +\fBcheck_account_update\fR +whenever a row of the table +accounts +is about to be updated: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TRIGGER check_update + BEFORE UPDATE ON accounts + FOR EACH ROW + EXECUTE PROCEDURE check_account_update(); +.fi +.if n \{\ +.RE +.\} +.sp +The same, but only execute the function if column +balance +is specified as a target in the +\fBUPDATE\fR +command: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TRIGGER check_update + BEFORE UPDATE OF balance ON accounts + FOR EACH ROW + EXECUTE PROCEDURE check_account_update(); +.fi +.if n \{\ +.RE +.\} +.sp +This form only executes the function if column +balance +has in fact changed value: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TRIGGER check_update + BEFORE UPDATE ON accounts + FOR EACH ROW + WHEN (OLD\&.balance IS DISTINCT FROM NEW\&.balance) + EXECUTE PROCEDURE check_account_update(); +.fi +.if n \{\ +.RE +.\} +.sp +Call a function to log updates of +accounts, but only if something changed: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TRIGGER log_update + AFTER UPDATE ON accounts + FOR EACH ROW + WHEN (OLD\&.* IS DISTINCT FROM NEW\&.*) + EXECUTE PROCEDURE log_account_update(); +.fi +.if n \{\ +.RE +.\} +.sp +Execute the function +\fBview_insert_row\fR +for each row to insert rows into the tables underlying a view: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TRIGGER view_insert + INSTEAD OF INSERT ON my_view + FOR EACH ROW + EXECUTE PROCEDURE view_insert_row(); +.fi +.if n \{\ +.RE +.\} +.PP + +Section 36.4, \(lqA Complete Trigger Example\(rq, in the documentation +contains a complete example of a trigger function written in C\&. +.SH "COMPATIBILITY" +.PP +The +\fBCREATE TRIGGER\fR +statement in +PostgreSQL +implements a subset of the +SQL +standard\&. The following functionality is currently missing: +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +SQL allows you to define aliases for the +\(lqold\(rq +and +\(lqnew\(rq +rows or tables for use in the definition of the triggered action (e\&.g\&., +CREATE TRIGGER \&.\&.\&. ON tablename REFERENCING OLD ROW AS somename NEW ROW AS othername \&.\&.\&.)\&. Since +PostgreSQL +allows trigger procedures to be written in any number of user\-defined languages, access to the data is handled in a language\-specific way\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +PostgreSQL +only allows the execution of a user\-defined function for the triggered action\&. The standard allows the execution of a number of other SQL commands, such as +\fBCREATE TABLE\fR, as the triggered action\&. This limitation is not hard to work around by creating a user\-defined function that executes the desired commands\&. +.RE +.PP +SQL specifies that multiple triggers should be fired in time\-of\-creation order\&. +PostgreSQL +uses name order, which was judged to be more convenient\&. +.PP +SQL specifies that +BEFORE DELETE +triggers on cascaded deletes fire +\fIafter\fR +the cascaded +DELETE +completes\&. The +PostgreSQL +behavior is for +BEFORE DELETE +to always fire before the delete action, even a cascading one\&. This is considered more consistent\&. There is also nonstandard behavior if +BEFORE +triggers modify rows or prevent updates during an update that is caused by a referential action\&. This can lead to constraint violations or stored data that does not honor the referential constraint\&. +.PP +The ability to specify multiple actions for a single trigger using +OR +is a +PostgreSQL +extension of the SQL standard\&. +.PP +The ability to fire triggers for +\fBTRUNCATE\fR +is a +PostgreSQL +extension of the SQL standard, as is the ability to define statement\-level triggers on views\&. +.PP + +\fBCREATE CONSTRAINT TRIGGER\fR +is a +PostgreSQL +extension of the +SQL +standard\&. +.SH "SEE ALSO" +CREATE FUNCTION (\fBCREATE_FUNCTION\fR(7)), ALTER TRIGGER (\fBALTER_TRIGGER\fR(7)), DROP TRIGGER (\fBDROP_TRIGGER\fR(7)), SET CONSTRAINTS (\fBSET_CONSTRAINTS\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_TYPE.7 b/doc/src/sgml/man7/CREATE_TYPE.7 new file mode 100644 index 000000000..ddd39383e --- /dev/null +++ b/doc/src/sgml/man7/CREATE_TYPE.7 @@ -0,0 +1,670 @@ +'\" t +.\" Title: CREATE TYPE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE TYPE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_TYPE \- define a new data type +.\" CREATE TYPE +.SH "SYNOPSIS" +.sp +.nf +CREATE TYPE \fIname\fR AS + ( [ \fIattribute_name\fR \fIdata_type\fR [ COLLATE \fIcollation\fR ] [, \&.\&.\&. ] ] ) + +CREATE TYPE \fIname\fR AS ENUM + ( [ \*(Aq\fIlabel\fR\*(Aq [, \&.\&.\&. ] ] ) + +CREATE TYPE \fIname\fR AS RANGE ( + SUBTYPE = \fIsubtype\fR + [ , SUBTYPE_OPCLASS = \fIsubtype_operator_class\fR ] + [ , COLLATION = \fIcollation\fR ] + [ , CANONICAL = \fIcanonical_function\fR ] + [ , SUBTYPE_DIFF = \fIsubtype_diff_function\fR ] +) + +CREATE TYPE \fIname\fR ( + INPUT = \fIinput_function\fR, + OUTPUT = \fIoutput_function\fR + [ , RECEIVE = \fIreceive_function\fR ] + [ , SEND = \fIsend_function\fR ] + [ , TYPMOD_IN = \fItype_modifier_input_function\fR ] + [ , TYPMOD_OUT = \fItype_modifier_output_function\fR ] + [ , ANALYZE = \fIanalyze_function\fR ] + [ , INTERNALLENGTH = { \fIinternallength\fR | VARIABLE } ] + [ , PASSEDBYVALUE ] + [ , ALIGNMENT = \fIalignment\fR ] + [ , STORAGE = \fIstorage\fR ] + [ , LIKE = \fIlike_type\fR ] + [ , CATEGORY = \fIcategory\fR ] + [ , PREFERRED = \fIpreferred\fR ] + [ , DEFAULT = \fIdefault\fR ] + [ , ELEMENT = \fIelement\fR ] + [ , DELIMITER = \fIdelimiter\fR ] + [ , COLLATABLE = \fIcollatable\fR ] +) + +CREATE TYPE \fIname\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE TYPE\fR +registers a new data type for use in the current database\&. The user who defines a type becomes its owner\&. +.PP +If a schema name is given then the type is created in the specified schema\&. Otherwise it is created in the current schema\&. The type name must be distinct from the name of any existing type or domain in the same schema\&. (Because tables have associated data types, the type name must also be distinct from the name of any existing table in the same schema\&.) +.PP +There are five forms of +\fBCREATE TYPE\fR, as shown in the syntax synopsis above\&. They respectively create a +composite type, an +enum type, a +range type, a +base type, or a +shell type\&. The first four of these are discussed in turn below\&. A shell type is simply a placeholder for a type to be defined later; it is created by issuing +\fBCREATE TYPE\fR +with no parameters except for the type name\&. Shell types are needed as forward references when creating range types and base types, as discussed in those sections\&. +.SS "Composite Types" +.PP +The first form of +\fBCREATE TYPE\fR +creates a composite type\&. The composite type is specified by a list of attribute names and data types\&. An attribute\*(Aqs collation can be specified too, if its data type is collatable\&. A composite type is essentially the same as the row type of a table, but using +\fBCREATE TYPE\fR +avoids the need to create an actual table when all that is wanted is to define a type\&. A stand\-alone composite type is useful, for example, as the argument or return type of a function\&. +.PP +To be able to create a composite type, you must have +USAGE +privilege on all attribute types\&. +.SS "Enumerated Types" +.PP +The second form of +\fBCREATE TYPE\fR +creates an enumerated (enum) type, as described in +Section 8.7, \(lqEnumerated Types\(rq, in the documentation\&. Enum types take a list of one or more quoted labels, each of which must be less than +NAMEDATALEN +bytes long (64 bytes in a standard +PostgreSQL +build)\&. +.SS "Range Types" +.PP +The third form of +\fBCREATE TYPE\fR +creates a new range type, as described in +Section 8.17, \(lqRange Types\(rq, in the documentation\&. +.PP +The range type\*(Aqs +\fIsubtype\fR +can be any type with an associated b\-tree operator class (to determine the ordering of values for the range type)\&. Normally the subtype\*(Aqs default b\-tree operator class is used to determine ordering; to use a non\-default opclass, specify its name with +\fIsubtype_opclass\fR\&. If the subtype is collatable, and you want to use a non\-default collation in the range\*(Aqs ordering, specify the desired collation with the +\fIcollation\fR +option\&. +.PP +The optional +\fIcanonical\fR +function must take one argument of the range type being defined, and return a value of the same type\&. This is used to convert range values to a canonical form, when applicable\&. See +Section 8.17.8, \(lqDefining New Range Types\(rq, in the documentation +for more information\&. Creating a +\fIcanonical\fR +function is a bit tricky, since it must be defined before the range type can be declared\&. To do this, you must first create a shell type, which is a placeholder type that has no properties except a name and an owner\&. This is done by issuing the command +CREATE TYPE \fIname\fR, with no additional parameters\&. Then the function can be declared using the shell type as argument and result, and finally the range type can be declared using the same name\&. This automatically replaces the shell type entry with a valid range type\&. +.PP +The optional +\fIsubtype_diff\fR +function must take two values of the +\fIsubtype\fR +type as argument, and return a +double precision +value representing the difference between the two given values\&. While this is optional, providing it allows much greater efficiency of GiST indexes on columns of the range type\&. See +Section 8.17.8, \(lqDefining New Range Types\(rq, in the documentation +for more information\&. +.SS "Base Types" +.PP +The fourth form of +\fBCREATE TYPE\fR +creates a new base type (scalar type)\&. To create a new base type, you must be a superuser\&. (This restriction is made because an erroneous type definition could confuse or even crash the server\&.) +.PP +The parameters can appear in any order, not only that illustrated above, and most are optional\&. You must register two or more functions (using +\fBCREATE FUNCTION\fR) before defining the type\&. The support functions +\fIinput_function\fR +and +\fIoutput_function\fR +are required, while the functions +\fIreceive_function\fR, +\fIsend_function\fR, +\fItype_modifier_input_function\fR, +\fItype_modifier_output_function\fR +and +\fIanalyze_function\fR +are optional\&. Generally these functions have to be coded in C or another low\-level language\&. +.PP +The +\fIinput_function\fR +converts the type\*(Aqs external textual representation to the internal representation used by the operators and functions defined for the type\&. +\fIoutput_function\fR +performs the reverse transformation\&. The input function can be declared as taking one argument of type +cstring, or as taking three arguments of types +cstring, +oid, +integer\&. The first argument is the input text as a C string, the second argument is the type\*(Aqs own OID (except for array types, which instead receive their element type\*(Aqs OID), and the third is the +typmod +of the destination column, if known (\-1 will be passed if not)\&. The input function must return a value of the data type itself\&. Usually, an input function should be declared STRICT; if it is not, it will be called with a NULL first parameter when reading a NULL input value\&. The function must still return NULL in this case, unless it raises an error\&. (This case is mainly meant to support domain input functions, which might need to reject NULL inputs\&.) The output function must be declared as taking one argument of the new data type\&. The output function must return type +cstring\&. Output functions are not invoked for NULL values\&. +.PP +The optional +\fIreceive_function\fR +converts the type\*(Aqs external binary representation to the internal representation\&. If this function is not supplied, the type cannot participate in binary input\&. The binary representation should be chosen to be cheap to convert to internal form, while being reasonably portable\&. (For example, the standard integer data types use network byte order as the external binary representation, while the internal representation is in the machine\*(Aqs native byte order\&.) The receive function should perform adequate checking to ensure that the value is valid\&. The receive function can be declared as taking one argument of type +internal, or as taking three arguments of types +internal, +oid, +integer\&. The first argument is a pointer to a +StringInfo +buffer holding the received byte string; the optional arguments are the same as for the text input function\&. The receive function must return a value of the data type itself\&. Usually, a receive function should be declared STRICT; if it is not, it will be called with a NULL first parameter when reading a NULL input value\&. The function must still return NULL in this case, unless it raises an error\&. (This case is mainly meant to support domain receive functions, which might need to reject NULL inputs\&.) Similarly, the optional +\fIsend_function\fR +converts from the internal representation to the external binary representation\&. If this function is not supplied, the type cannot participate in binary output\&. The send function must be declared as taking one argument of the new data type\&. The send function must return type +bytea\&. Send functions are not invoked for NULL values\&. +.PP +You should at this point be wondering how the input and output functions can be declared to have results or arguments of the new type, when they have to be created before the new type can be created\&. The answer is that the type should first be defined as a +shell type, which is a placeholder type that has no properties except a name and an owner\&. This is done by issuing the command +CREATE TYPE \fIname\fR, with no additional parameters\&. Then the I/O functions can be defined referencing the shell type\&. Finally, +\fBCREATE TYPE\fR +with a full definition replaces the shell entry with a complete, valid type definition, after which the new type can be used normally\&. +.PP +The optional +\fItype_modifier_input_function\fR +and +\fItype_modifier_output_function\fR +are needed if the type supports modifiers, that is optional constraints attached to a type declaration, such as +char(5) +or +numeric(30,2)\&. +PostgreSQL +allows user\-defined types to take one or more simple constants or identifiers as modifiers\&. However, this information must be capable of being packed into a single non\-negative integer value for storage in the system catalogs\&. The +\fItype_modifier_input_function\fR +is passed the declared modifier(s) in the form of a +cstring +array\&. It must check the values for validity (throwing an error if they are wrong), and if they are correct, return a single non\-negative +integer +value that will be stored as the column +\(lqtypmod\(rq\&. Type modifiers will be rejected if the type does not have a +\fItype_modifier_input_function\fR\&. The +\fItype_modifier_output_function\fR +converts the internal integer typmod value back to the correct form for user display\&. It must return a +cstring +value that is the exact string to append to the type name; for example +numeric\*(Aqs function might return +(30,2)\&. It is allowed to omit the +\fItype_modifier_output_function\fR, in which case the default display format is just the stored typmod integer value enclosed in parentheses\&. +.PP +The optional +\fIanalyze_function\fR +performs type\-specific statistics collection for columns of the data type\&. By default, +\fBANALYZE\fR +will attempt to gather statistics using the type\*(Aqs +\(lqequals\(rq +and +\(lqless\-than\(rq +operators, if there is a default b\-tree operator class for the type\&. For non\-scalar types this behavior is likely to be unsuitable, so it can be overridden by specifying a custom analysis function\&. The analysis function must be declared to take a single argument of type +internal, and return a +boolean +result\&. The detailed API for analysis functions appears in +src/include/commands/vacuum\&.h\&. +.PP +While the details of the new type\*(Aqs internal representation are only known to the I/O functions and other functions you create to work with the type, there are several properties of the internal representation that must be declared to +PostgreSQL\&. Foremost of these is +\fIinternallength\fR\&. Base data types can be fixed\-length, in which case +\fIinternallength\fR +is a positive integer, or variable length, indicated by setting +\fIinternallength\fR +to +VARIABLE\&. (Internally, this is represented by setting +typlen +to \-1\&.) The internal representation of all variable\-length types must start with a 4\-byte integer giving the total length of this value of the type\&. +.PP +The optional flag +PASSEDBYVALUE +indicates that values of this data type are passed by value, rather than by reference\&. You cannot pass by value types whose internal representation is larger than the size of the +Datum +type (4 bytes on most machines, 8 bytes on a few)\&. +.PP +The +\fIalignment\fR +parameter specifies the storage alignment required for the data type\&. The allowed values equate to alignment on 1, 2, 4, or 8 byte boundaries\&. Note that variable\-length types must have an alignment of at least 4, since they necessarily contain an +int4 +as their first component\&. +.PP +The +\fIstorage\fR +parameter allows selection of storage strategies for variable\-length data types\&. (Only +plain +is allowed for fixed\-length types\&.) +plain +specifies that data of the type will always be stored in\-line and not compressed\&. +extended +specifies that the system will first try to compress a long data value, and will move the value out of the main table row if it\*(Aqs still too long\&. +external +allows the value to be moved out of the main table, but the system will not try to compress it\&. +main +allows compression, but discourages moving the value out of the main table\&. (Data items with this storage strategy might still be moved out of the main table if there is no other way to make a row fit, but they will be kept in the main table preferentially over +extended +and +external +items\&.) +.PP +The +\fIlike_type\fR +parameter provides an alternative method for specifying the basic representation properties of a data type: copy them from some existing type\&. The values of +\fIinternallength\fR, +\fIpassedbyvalue\fR, +\fIalignment\fR, and +\fIstorage\fR +are copied from the named type\&. (It is possible, though usually undesirable, to override some of these values by specifying them along with the +LIKE +clause\&.) Specifying representation this way is especially useful when the low\-level implementation of the new type +\(lqpiggybacks\(rq +on an existing type in some fashion\&. +.PP +The +\fIcategory\fR +and +\fIpreferred\fR +parameters can be used to help control which implicit cast will be applied in ambiguous situations\&. Each data type belongs to a category named by a single ASCII character, and each type is either +\(lqpreferred\(rq +or not within its category\&. The parser will prefer casting to preferred types (but only from other types within the same category) when this rule is helpful in resolving overloaded functions or operators\&. For more details see +Chapter 10, Type Conversion, in the documentation\&. For types that have no implicit casts to or from any other types, it is sufficient to leave these settings at the defaults\&. However, for a group of related types that have implicit casts, it is often helpful to mark them all as belonging to a category and select one or two of the +\(lqmost general\(rq +types as being preferred within the category\&. The +\fIcategory\fR +parameter is especially useful when adding a user\-defined type to an existing built\-in category, such as the numeric or string types\&. However, it is also possible to create new entirely\-user\-defined type categories\&. Select any ASCII character other than an upper\-case letter to name such a category\&. +.PP +A default value can be specified, in case a user wants columns of the data type to default to something other than the null value\&. Specify the default with the +DEFAULT +key word\&. (Such a default can be overridden by an explicit +DEFAULT +clause attached to a particular column\&.) +.PP +To indicate that a type is an array, specify the type of the array elements using the +ELEMENT +key word\&. For example, to define an array of 4\-byte integers (int4), specify +ELEMENT = int4\&. More details about array types appear below\&. +.PP +To indicate the delimiter to be used between values in the external representation of arrays of this type, +\fIdelimiter\fR +can be set to a specific character\&. The default delimiter is the comma (,)\&. Note that the delimiter is associated with the array element type, not the array type itself\&. +.PP +If the optional Boolean parameter +\fIcollatable\fR +is true, column definitions and expressions of the type may carry collation information through use of the +COLLATE +clause\&. It is up to the implementations of the functions operating on the type to actually make use of the collation information; this does not happen automatically merely by marking the type collatable\&. +.SS "Array Types" +.PP +Whenever a user\-defined type is created, +PostgreSQL +automatically creates an associated array type, whose name consists of the element type\*(Aqs name prepended with an underscore, and truncated if necessary to keep it less than +NAMEDATALEN +bytes long\&. (If the name so generated collides with an existing type name, the process is repeated until a non\-colliding name is found\&.) This implicitly\-created array type is variable length and uses the built\-in input and output functions +array_in +and +array_out\&. The array type tracks any changes in its element type\*(Aqs owner or schema, and is dropped if the element type is\&. +.PP +You might reasonably ask why there is an +\fBELEMENT\fR +option, if the system makes the correct array type automatically\&. The only case where it\*(Aqs useful to use +\fBELEMENT\fR +is when you are making a fixed\-length type that happens to be internally an array of a number of identical things, and you want to allow these things to be accessed directly by subscripting, in addition to whatever operations you plan to provide for the type as a whole\&. For example, type +point +is represented as just two floating\-point numbers, each can be accessed using +point[0] +and +point[1]\&. Note that this facility only works for fixed\-length types whose internal form is exactly a sequence of identical fixed\-length fields\&. A subscriptable variable\-length type must have the generalized internal representation used by +array_in +and +array_out\&. For historical reasons (i\&.e\&., this is clearly wrong but it\*(Aqs far too late to change it), subscripting of fixed\-length array types starts from zero, rather than from one as for variable\-length arrays\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of a type to be created\&. +.RE +.PP +\fIattribute_name\fR +.RS 4 +The name of an attribute (column) for the composite type\&. +.RE +.PP +\fIdata_type\fR +.RS 4 +The name of an existing data type to become a column of the composite type\&. +.RE +.PP +\fIcollation\fR +.RS 4 +The name of an existing collation to be associated with a column of a composite type, or with a range type\&. +.RE +.PP +\fIlabel\fR +.RS 4 +A string literal representing the textual label associated with one value of an enum type\&. +.RE +.PP +\fIsubtype\fR +.RS 4 +The name of the element type that the range type will represent ranges of\&. +.RE +.PP +\fIsubtype_operator_class\fR +.RS 4 +The name of a b\-tree operator class for the subtype\&. +.RE +.PP +\fIcanonical_function\fR +.RS 4 +The name of the canonicalization function for the range type\&. +.RE +.PP +\fIsubtype_diff_function\fR +.RS 4 +The name of a difference function for the subtype\&. +.RE +.PP +\fIinput_function\fR +.RS 4 +The name of a function that converts data from the type\*(Aqs external textual form to its internal form\&. +.RE +.PP +\fIoutput_function\fR +.RS 4 +The name of a function that converts data from the type\*(Aqs internal form to its external textual form\&. +.RE +.PP +\fIreceive_function\fR +.RS 4 +The name of a function that converts data from the type\*(Aqs external binary form to its internal form\&. +.RE +.PP +\fIsend_function\fR +.RS 4 +The name of a function that converts data from the type\*(Aqs internal form to its external binary form\&. +.RE +.PP +\fItype_modifier_input_function\fR +.RS 4 +The name of a function that converts an array of modifier(s) for the type into internal form\&. +.RE +.PP +\fItype_modifier_output_function\fR +.RS 4 +The name of a function that converts the internal form of the type\*(Aqs modifier(s) to external textual form\&. +.RE +.PP +\fIanalyze_function\fR +.RS 4 +The name of a function that performs statistical analysis for the data type\&. +.RE +.PP +\fIinternallength\fR +.RS 4 +A numeric constant that specifies the length in bytes of the new type\*(Aqs internal representation\&. The default assumption is that it is variable\-length\&. +.RE +.PP +\fIalignment\fR +.RS 4 +The storage alignment requirement of the data type\&. If specified, it must be +char, +int2, +int4, or +double; the default is +int4\&. +.RE +.PP +\fIstorage\fR +.RS 4 +The storage strategy for the data type\&. If specified, must be +plain, +external, +extended, or +main; the default is +plain\&. +.RE +.PP +\fIlike_type\fR +.RS 4 +The name of an existing data type that the new type will have the same representation as\&. The values of +\fIinternallength\fR, +\fIpassedbyvalue\fR, +\fIalignment\fR, and +\fIstorage\fR +are copied from that type, unless overridden by explicit specification elsewhere in this +\fBCREATE TYPE\fR +command\&. +.RE +.PP +\fIcategory\fR +.RS 4 +The category code (a single ASCII character) for this type\&. The default is +\*(AqU\*(Aq +for +\(lquser\-defined type\(rq\&. Other standard category codes can be found in +Table\ \&45.51, \(lqtypcategory Codes\(rq\&. You may also choose other ASCII characters in order to create custom categories\&. +.RE +.PP +\fIpreferred\fR +.RS 4 +True if this type is a preferred type within its type category, else false\&. The default is false\&. Be very careful about creating a new preferred type within an existing type category, as this could cause surprising changes in behavior\&. +.RE +.PP +\fIdefault\fR +.RS 4 +The default value for the data type\&. If this is omitted, the default is null\&. +.RE +.PP +\fIelement\fR +.RS 4 +The type being created is an array; this specifies the type of the array elements\&. +.RE +.PP +\fIdelimiter\fR +.RS 4 +The delimiter character to be used between values in arrays made of this type\&. +.RE +.PP +\fIcollatable\fR +.RS 4 +True if this type\*(Aqs operations can use collation information\&. The default is false\&. +.RE +.SH "NOTES" +.PP +Because there are no restrictions on use of a data type once it\*(Aqs been created, creating a base type or range type is tantamount to granting public execute permission on the functions mentioned in the type definition\&. This is usually not an issue for the sorts of functions that are useful in a type definition\&. But you might want to think twice before designing a type in a way that would require +\(lqsecret\(rq +information to be used while converting it to or from external form\&. +.PP +Before +PostgreSQL +version 8\&.3, the name of a generated array type was always exactly the element type\*(Aqs name with one underscore character (_) prepended\&. (Type names were therefore restricted in length to one less character than other names\&.) While this is still usually the case, the array type name may vary from this in case of maximum\-length names or collisions with user type names that begin with underscore\&. Writing code that depends on this convention is therefore deprecated\&. Instead, use +pg_type\&.typarray +to locate the array type associated with a given type\&. +.PP +It may be advisable to avoid using type and table names that begin with underscore\&. While the server will change generated array type names to avoid collisions with user\-given names, there is still risk of confusion, particularly with old client software that may assume that type names beginning with underscores always represent arrays\&. +.PP +Before +PostgreSQL +version 8\&.2, the shell\-type creation syntax +CREATE TYPE \fIname\fR +did not exist\&. The way to create a new base type was to create its input function first\&. In this approach, +PostgreSQL +will first see the name of the new data type as the return type of the input function\&. The shell type is implicitly created in this situation, and then it can be referenced in the definitions of the remaining I/O functions\&. This approach still works, but is deprecated and might be disallowed in some future release\&. Also, to avoid accidentally cluttering the catalogs with shell types as a result of simple typos in function definitions, a shell type will only be made this way when the input function is written in C\&. +.PP +In +PostgreSQL +versions before 7\&.3, it was customary to avoid creating a shell type at all, by replacing the functions\*(Aq forward references to the type name with the placeholder pseudotype +opaque\&. The +cstring +arguments and results also had to be declared as +opaque +before 7\&.3\&. To support loading of old dump files, +\fBCREATE TYPE\fR +will accept I/O functions declared using +opaque, but it will issue a notice and change the function declarations to use the correct types\&. +.SH "EXAMPLES" +.PP +This example creates a composite type and uses it in a function definition: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TYPE compfoo AS (f1 int, f2 text); + +CREATE FUNCTION getfoo() RETURNS SETOF compfoo AS $$ + SELECT fooid, fooname FROM foo +$$ LANGUAGE SQL; +.fi +.if n \{\ +.RE +.\} +.PP +This example creates an enumerated type and uses it in a table definition: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TYPE bug_status AS ENUM (\*(Aqnew\*(Aq, \*(Aqopen\*(Aq, \*(Aqclosed\*(Aq); + +CREATE TABLE bug ( + id serial, + description text, + status bug_status +); +.fi +.if n \{\ +.RE +.\} +.PP +This example creates a range type: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TYPE float8_range AS RANGE (subtype = float8, subtype_diff = float8mi); +.fi +.if n \{\ +.RE +.\} +.PP +This example creates the base data type +box +and then uses the type in a table definition: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TYPE box; + +CREATE FUNCTION my_box_in_function(cstring) RETURNS box AS \&.\&.\&. ; +CREATE FUNCTION my_box_out_function(box) RETURNS cstring AS \&.\&.\&. ; + +CREATE TYPE box ( + INTERNALLENGTH = 16, + INPUT = my_box_in_function, + OUTPUT = my_box_out_function +); + +CREATE TABLE myboxes ( + id integer, + description box +); +.fi +.if n \{\ +.RE +.\} +.PP +If the internal structure of +box +were an array of four +float4 +elements, we might instead use: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TYPE box ( + INTERNALLENGTH = 16, + INPUT = my_box_in_function, + OUTPUT = my_box_out_function, + ELEMENT = float4 +); +.fi +.if n \{\ +.RE +.\} +.sp +which would allow a box value\*(Aqs component numbers to be accessed by subscripting\&. Otherwise the type behaves the same as before\&. +.PP +This example creates a large object type and uses it in a table definition: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE TYPE bigobj ( + INPUT = lo_filein, OUTPUT = lo_fileout, + INTERNALLENGTH = VARIABLE +); +CREATE TABLE big_objs ( + id integer, + obj bigobj +); +.fi +.if n \{\ +.RE +.\} +.PP +More examples, including suitable input and output functions, are in +Section 35.11, \(lqUser-defined Types\(rq, in the documentation\&. +.SH "COMPATIBILITY" +.PP +The first form of the +\fBCREATE TYPE\fR +command, which creates a composite type, conforms to the +SQL +standard\&. The other forms are +PostgreSQL +extensions\&. The +\fBCREATE TYPE\fR +statement in the +SQL +standard also defines other forms that are not implemented in +PostgreSQL\&. +.PP +The ability to create a composite type with zero attributes is a +PostgreSQL\-specific deviation from the standard (analogous to the same case in +\fBCREATE TABLE\fR)\&. +.SH "SEE ALSO" +ALTER TYPE (\fBALTER_TYPE\fR(7)), CREATE DOMAIN (\fBCREATE_DOMAIN\fR(7)), CREATE FUNCTION (\fBCREATE_FUNCTION\fR(7)), DROP TYPE (\fBDROP_TYPE\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_USER.7 b/doc/src/sgml/man7/CREATE_USER.7 new file mode 100644 index 000000000..769d3a1d6 --- /dev/null +++ b/doc/src/sgml/man7/CREATE_USER.7 @@ -0,0 +1,77 @@ +'\" t +.\" Title: CREATE USER +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE USER" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_USER \- define a new database role +.\" CREATE USER +.SH "SYNOPSIS" +.sp +.nf +CREATE USER \fIname\fR [ [ WITH ] \fIoption\fR [ \&.\&.\&. ] ] + +where \fIoption\fR can be: + + SUPERUSER | NOSUPERUSER + | CREATEDB | NOCREATEDB + | CREATEROLE | NOCREATEROLE + | CREATEUSER | NOCREATEUSER + | INHERIT | NOINHERIT + | LOGIN | NOLOGIN + | REPLICATION | NOREPLICATION + | CONNECTION LIMIT \fIconnlimit\fR + | [ ENCRYPTED | UNENCRYPTED ] PASSWORD \*(Aq\fIpassword\fR\*(Aq + | VALID UNTIL \*(Aq\fItimestamp\fR\*(Aq + | IN ROLE \fIrole_name\fR [, \&.\&.\&.] + | IN GROUP \fIrole_name\fR [, \&.\&.\&.] + | ROLE \fIrole_name\fR [, \&.\&.\&.] + | ADMIN \fIrole_name\fR [, \&.\&.\&.] + | USER \fIrole_name\fR [, \&.\&.\&.] + | SYSID \fIuid\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE USER\fR +is now an alias for +CREATE ROLE (\fBCREATE_ROLE\fR(7))\&. The only difference is that when the command is spelled +\fBCREATE USER\fR, +LOGIN +is assumed by default, whereas +NOLOGIN +is assumed when the command is spelled +\fBCREATE ROLE\fR\&. +.SH "COMPATIBILITY" +.PP +The +\fBCREATE USER\fR +statement is a +PostgreSQL +extension\&. The SQL standard leaves the definition of users to the implementation\&. +.SH "SEE ALSO" +CREATE ROLE (\fBCREATE_ROLE\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_USER_MAPPING.7 b/doc/src/sgml/man7/CREATE_USER_MAPPING.7 new file mode 100644 index 000000000..edd83afbe --- /dev/null +++ b/doc/src/sgml/man7/CREATE_USER_MAPPING.7 @@ -0,0 +1,92 @@ +'\" t +.\" Title: CREATE USER MAPPING +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE USER MAPPING" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_USER_MAPPING \- define a new mapping of a user to a foreign server +.\" CREATE USER MAPPING +.SH "SYNOPSIS" +.sp +.nf +CREATE USER MAPPING FOR { \fIuser_name\fR | USER | CURRENT_USER | PUBLIC } + SERVER \fIserver_name\fR + [ OPTIONS ( \fIoption\fR \*(Aq\fIvalue\fR\*(Aq [ , \&.\&.\&. ] ) ] +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE USER MAPPING\fR +defines a mapping of a user to a foreign server\&. A user mapping typically encapsulates connection information that a foreign\-data wrapper uses together with the information encapsulated by a foreign server to access an external data resource\&. +.PP +The owner of a foreign server can create user mappings for that server for any user\&. Also, a user can create a user mapping for his own user name if +USAGE +privilege on the server has been granted to the user\&. +.SH "PARAMETERS" +.PP +\fIuser_name\fR +.RS 4 +The name of an existing user that is mapped to foreign server\&. +CURRENT_USER +and +USER +match the name of the current user\&. When +PUBLIC +is specified, a so\-called public mapping is created that is used when no user\-specific mapping is applicable\&. +.RE +.PP +\fIserver_name\fR +.RS 4 +The name of an existing server for which the user mapping is to be created\&. +.RE +.PP +OPTIONS ( \fIoption\fR \*(Aq\fIvalue\fR\*(Aq [, \&.\&.\&. ] ) +.RS 4 +This clause specifies the options of the user mapping\&. The options typically define the actual user name and password of the mapping\&. Option names must be unique\&. The allowed option names and values are specific to the server\*(Aqs foreign\-data wrapper\&. +.RE +.SH "EXAMPLES" +.PP +Create a user mapping for user +bob, server +foo: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE USER MAPPING FOR bob SERVER foo OPTIONS (user \*(Aqbob\*(Aq, password \*(Aqsecret\*(Aq); +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBCREATE USER MAPPING\fR +conforms to ISO/IEC 9075\-9 (SQL/MED)\&. +.SH "SEE ALSO" +ALTER USER MAPPING (\fBALTER_USER_MAPPING\fR(7)), DROP USER MAPPING (\fBDROP_USER_MAPPING\fR(7)), CREATE FOREIGN DATA WRAPPER (\fBCREATE_FOREIGN_DATA_WRAPPER\fR(7)), CREATE SERVER (\fBCREATE_SERVER\fR(7)) diff --git a/doc/src/sgml/man7/CREATE_VIEW.7 b/doc/src/sgml/man7/CREATE_VIEW.7 new file mode 100644 index 000000000..9de6fa5fe --- /dev/null +++ b/doc/src/sgml/man7/CREATE_VIEW.7 @@ -0,0 +1,207 @@ +'\" t +.\" Title: CREATE VIEW +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "CREATE VIEW" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +CREATE_VIEW \- define a new view +.\" CREATE VIEW +.SH "SYNOPSIS" +.sp +.nf +CREATE [ OR REPLACE ] [ TEMP | TEMPORARY ] VIEW \fIname\fR [ ( \fIcolumn_name\fR [, \&.\&.\&.] ) ] + [ WITH ( \fIview_option_name\fR [= \fIview_option_value\fR] [, \&.\&.\&. ] ) ] + AS \fIquery\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBCREATE VIEW\fR +defines a view of a query\&. The view is not physically materialized\&. Instead, the query is run every time the view is referenced in a query\&. +.PP + +\fBCREATE OR REPLACE VIEW\fR +is similar, but if a view of the same name already exists, it is replaced\&. The new query must generate the same columns that were generated by the existing view query (that is, the same column names in the same order and with the same data types), but it may add additional columns to the end of the list\&. The calculations giving rise to the output columns may be completely different\&. +.PP +If a schema name is given (for example, +CREATE VIEW myschema\&.myview \&.\&.\&.) then the view is created in the specified schema\&. Otherwise it is created in the current schema\&. Temporary views exist in a special schema, so a schema name cannot be given when creating a temporary view\&. The name of the view must be distinct from the name of any other view, table, sequence, index or foreign table in the same schema\&. +.SH "PARAMETERS" +.PP +TEMPORARY or TEMP +.RS 4 +If specified, the view is created as a temporary view\&. Temporary views are automatically dropped at the end of the current session\&. Existing permanent relations with the same name are not visible to the current session while the temporary view exists, unless they are referenced with schema\-qualified names\&. +.sp +If any of the tables referenced by the view are temporary, the view is created as a temporary view (whether +TEMPORARY +is specified or not)\&. +.RE +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of a view to be created\&. +.RE +.PP +\fIcolumn_name\fR +.RS 4 +An optional list of names to be used for columns of the view\&. If not given, the column names are deduced from the query\&. +.RE +.PP +WITH ( \fIview_option_name\fR [= \fIview_option_value\fR] [, \&.\&.\&. ] ) +.RS 4 +This clause specifies optional parameters for a view; currently, the only supported parameter name is +security_barrier, which should be enabled when a view is intended to provide row\-level security\&. See +Section 37.4, \(lqRules and Privileges\(rq, in the documentation +for full details\&. +.RE +.PP +\fIquery\fR +.RS 4 +A +\fBSELECT\fR(7) +or +\fBVALUES\fR(7) +command which will provide the columns and rows of the view\&. +.RE +.SH "NOTES" +.PP +Currently, views are read only: the system will not allow an insert, update, or delete on a view\&. You can get the effect of an updatable view by creating +INSTEAD +triggers on the view, which must convert attempted inserts, etc\&. on the view into appropriate actions on other tables\&. For more information see +CREATE TRIGGER (\fBCREATE_TRIGGER\fR(7))\&. Another possibility is to create rules (see +CREATE RULE (\fBCREATE_RULE\fR(7))), but in practice triggers are easier to understand and use correctly\&. +.PP +Use the +DROP VIEW (\fBDROP_VIEW\fR(7)) +statement to drop views\&. +.PP +Be careful that the names and types of the view\*(Aqs columns will be assigned the way you want\&. For example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE VIEW vista AS SELECT \*(AqHello World\*(Aq; +.fi +.if n \{\ +.RE +.\} +.sp +is bad form in two ways: the column name defaults to +?column?, and the column data type defaults to +unknown\&. If you want a string literal in a view\*(Aqs result, use something like: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE VIEW vista AS SELECT text \*(AqHello World\*(Aq AS hello; +.fi +.if n \{\ +.RE +.\} +.PP +Access to tables referenced in the view is determined by permissions of the view owner\&. In some cases, this can be used to provide secure but restricted access to the underlying tables\&. However, not all views are secure against tampering; see +Section 37.4, \(lqRules and Privileges\(rq, in the documentation +for details\&. Functions called in the view are treated the same as if they had been called directly from the query using the view\&. Therefore the user of a view must have permissions to call all functions used by the view\&. +.PP +When +\fBCREATE OR REPLACE VIEW\fR +is used on an existing view, only the view\*(Aqs defining SELECT rule is changed\&. Other view properties, including ownership, permissions, and non\-SELECT rules, remain unchanged\&. You must own the view to replace it (this includes being a member of the owning role)\&. +.SH "EXAMPLES" +.PP +Create a view consisting of all comedy films: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE VIEW comedies AS + SELECT * + FROM films + WHERE kind = \*(AqComedy\*(Aq; +.fi +.if n \{\ +.RE +.\} +.sp +This will create a view containing the columns that are in the +film +table at the time of view creation\&. Though +* +was used to create the view, columns added later to the table will not be part of the view\&. +.SH "COMPATIBILITY" +.PP +The SQL standard specifies some additional capabilities for the +\fBCREATE VIEW\fR +statement: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE VIEW \fIname\fR [ ( \fIcolumn_name\fR [, \&.\&.\&.] ) ] + AS \fIquery\fR + [ WITH [ CASCADED | LOCAL ] CHECK OPTION ] +.fi +.if n \{\ +.RE +.\} +.PP +The optional clauses for the full SQL command are: +.PP +CHECK OPTION +.RS 4 +This option has to do with updatable views\&. All +\fBINSERT\fR +and +\fBUPDATE\fR +commands on the view will be checked to ensure data satisfy the view\-defining condition (that is, the new data would be visible through the view)\&. If they do not, the update will be rejected\&. +.RE +.PP +LOCAL +.RS 4 +Check for integrity on this view\&. +.RE +.PP +CASCADED +.RS 4 +Check for integrity on this view and on any dependent view\&. +CASCADED +is assumed if neither +CASCADED +nor +LOCAL +is specified\&. +.RE +.PP + +\fBCREATE OR REPLACE VIEW\fR +is a +PostgreSQL +language extension\&. So is the concept of a temporary view\&. +.SH "SEE ALSO" +ALTER VIEW (\fBALTER_VIEW\fR(7)), DROP VIEW (\fBDROP_VIEW\fR(7)) diff --git a/doc/src/sgml/man7/DEALLOCATE.7 b/doc/src/sgml/man7/DEALLOCATE.7 new file mode 100644 index 000000000..c25441801 --- /dev/null +++ b/doc/src/sgml/man7/DEALLOCATE.7 @@ -0,0 +1,69 @@ +'\" t +.\" Title: DEALLOCATE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DEALLOCATE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DEALLOCATE \- deallocate a prepared statement +.\" DEALLOCATE +.\" prepared statements: removing +.SH "SYNOPSIS" +.sp +.nf +DEALLOCATE [ PREPARE ] { \fIname\fR | ALL } +.fi +.SH "DESCRIPTION" +.PP + +\fBDEALLOCATE\fR +is used to deallocate a previously prepared SQL statement\&. If you do not explicitly deallocate a prepared statement, it is deallocated when the session ends\&. +.PP +For more information on prepared statements, see +\fBPREPARE\fR(7)\&. +.SH "PARAMETERS" +.PP +PREPARE +.RS 4 +This key word is ignored\&. +.RE +.PP +\fIname\fR +.RS 4 +The name of the prepared statement to deallocate\&. +.RE +.PP +ALL +.RS 4 +Deallocate all prepared statements\&. +.RE +.SH "COMPATIBILITY" +.PP +The SQL standard includes a +\fBDEALLOCATE\fR +statement, but it is only for use in embedded SQL\&. +.SH "SEE ALSO" +\fBEXECUTE\fR(7), \fBPREPARE\fR(7) diff --git a/doc/src/sgml/man7/DECLARE.7 b/doc/src/sgml/man7/DECLARE.7 new file mode 100644 index 000000000..748caec63 --- /dev/null +++ b/doc/src/sgml/man7/DECLARE.7 @@ -0,0 +1,329 @@ +'\" t +.\" Title: DECLARE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DECLARE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DECLARE \- define a cursor +.\" DECLARE +.\" cursor: DECLARE +.SH "SYNOPSIS" +.sp +.nf +DECLARE \fIname\fR [ BINARY ] [ INSENSITIVE ] [ [ NO ] SCROLL ] + CURSOR [ { WITH | WITHOUT } HOLD ] FOR \fIquery\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBDECLARE\fR +allows a user to create cursors, which can be used to retrieve a small number of rows at a time out of a larger query\&. After the cursor is created, rows are fetched from it using +\fBFETCH\fR(7)\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +.PP +This page describes usage of cursors at the SQL command level\&. If you are trying to use cursors inside a +PL/pgSQL +function, the rules are different \(em see +Section 39.7, \(lqCursors\(rq, in the documentation\&. +.sp .5v +.RE +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name of the cursor to be created\&. +.RE +.PP +BINARY +.RS 4 +Causes the cursor to return data in binary rather than in text format\&. +.RE +.PP +INSENSITIVE +.RS 4 +Indicates that data retrieved from the cursor should be unaffected by updates to the table(s) underlying the cursor that occur after the cursor is created\&. In +PostgreSQL, this is the default behavior; so this key word has no effect and is only accepted for compatibility with the SQL standard\&. +.RE +.PP +SCROLL, NO SCROLL +.RS 4 +SCROLL +specifies that the cursor can be used to retrieve rows in a nonsequential fashion (e\&.g\&., backward)\&. Depending upon the complexity of the query\*(Aqs execution plan, specifying +SCROLL +might impose a performance penalty on the query\*(Aqs execution time\&. +NO SCROLL +specifies that the cursor cannot be used to retrieve rows in a nonsequential fashion\&. The default is to allow scrolling in some cases; this is not the same as specifying +SCROLL\&. See +NOTES +for details\&. +.RE +.PP +WITH HOLD, WITHOUT HOLD +.RS 4 +WITH HOLD +specifies that the cursor can continue to be used after the transaction that created it successfully commits\&. +WITHOUT HOLD +specifies that the cursor cannot be used outside of the transaction that created it\&. If neither +WITHOUT HOLD +nor +WITH HOLD +is specified, +WITHOUT HOLD +is the default\&. +.RE +.PP +\fIquery\fR +.RS 4 +A +\fBSELECT\fR(7) +or +\fBVALUES\fR(7) +command which will provide the rows to be returned by the cursor\&. +.RE +.PP +The key words +BINARY, +INSENSITIVE, and +SCROLL +can appear in any order\&. +.SH "NOTES" +.PP +Normal cursors return data in text format, the same as a +\fBSELECT\fR +would produce\&. The +BINARY +option specifies that the cursor should return data in binary format\&. This reduces conversion effort for both the server and client, at the cost of more programmer effort to deal with platform\-dependent binary data formats\&. As an example, if a query returns a value of one from an integer column, you would get a string of +1 +with a default cursor, whereas with a binary cursor you would get a 4\-byte field containing the internal representation of the value (in big\-endian byte order)\&. +.PP +Binary cursors should be used carefully\&. Many applications, including +psql, are not prepared to handle binary cursors and expect data to come back in the text format\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +.PP +When the client application uses the +\(lqextended query\(rq +protocol to issue a +\fBFETCH\fR +command, the Bind protocol message specifies whether data is to be retrieved in text or binary format\&. This choice overrides the way that the cursor is defined\&. The concept of a binary cursor as such is thus obsolete when using extended query protocol \(em any cursor can be treated as either text or binary\&. +.sp .5v +.RE +.PP +Unless +WITH HOLD +is specified, the cursor created by this command can only be used within the current transaction\&. Thus, +\fBDECLARE\fR +without +WITH HOLD +is useless outside a transaction block: the cursor would survive only to the completion of the statement\&. Therefore +PostgreSQL +reports an error if such a command is used outside a transaction block\&. Use +\fBBEGIN\fR(7) +and +\fBCOMMIT\fR(7) +(or +\fBROLLBACK\fR(7)) to define a transaction block\&. +.PP +If +WITH HOLD +is specified and the transaction that created the cursor successfully commits, the cursor can continue to be accessed by subsequent transactions in the same session\&. (But if the creating transaction is aborted, the cursor is removed\&.) A cursor created with +WITH HOLD +is closed when an explicit +\fBCLOSE\fR +command is issued on it, or the session ends\&. In the current implementation, the rows represented by a held cursor are copied into a temporary file or memory area so that they remain available for subsequent transactions\&. +.PP + +WITH HOLD +may not be specified when the query includes +FOR UPDATE +or +FOR SHARE\&. +.PP +The +SCROLL +option should be specified when defining a cursor that will be used to fetch backwards\&. This is required by the SQL standard\&. However, for compatibility with earlier versions, +PostgreSQL +will allow backward fetches without +SCROLL, if the cursor\*(Aqs query plan is simple enough that no extra overhead is needed to support it\&. However, application developers are advised not to rely on using backward fetches from a cursor that has not been created with +SCROLL\&. If +NO SCROLL +is specified, then backward fetches are disallowed in any case\&. +.PP +Backward fetches are also disallowed when the query includes +FOR UPDATE +or +FOR SHARE; therefore +SCROLL +may not be specified in this case\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBCaution\fR +.ps -1 +.br +.PP +Scrollable and +WITH HOLD +cursors may give unexpected results if they invoke any volatile functions (see +Section 35.6, \(lqFunction Volatility Categories\(rq, in the documentation)\&. When a previously fetched row is re\-fetched, the functions might be re\-executed, perhaps leading to results different from the first time\&. One workaround for such cases is to declare the cursor +WITH HOLD +and commit the transaction before reading any rows from it\&. This will force the entire output of the cursor to be materialized in temporary storage, so that volatile functions are executed exactly once for each row\&. +.sp .5v +.RE +.PP +If the cursor\*(Aqs query includes +FOR UPDATE +or +FOR SHARE, then returned rows are locked at the time they are first fetched, in the same way as for a regular +\fBSELECT\fR(7) +command with these options\&. In addition, the returned rows will be the most up\-to\-date versions; therefore these options provide the equivalent of what the SQL standard calls a +\(lqsensitive cursor\(rq\&. (Specifying +INSENSITIVE +together with +FOR UPDATE +or +FOR SHARE +is an error\&.) +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBCaution\fR +.ps -1 +.br +.PP +It is generally recommended to use +FOR UPDATE +if the cursor is intended to be used with +\fBUPDATE \&.\&.\&. WHERE CURRENT OF\fR +or +\fBDELETE \&.\&.\&. WHERE CURRENT OF\fR\&. Using +FOR UPDATE +prevents other sessions from changing the rows between the time they are fetched and the time they are updated\&. Without +FOR UPDATE, a subsequent +WHERE CURRENT OF +command will have no effect if the row was changed since the cursor was created\&. +.PP +Another reason to use +FOR UPDATE +is that without it, a subsequent +WHERE CURRENT OF +might fail if the cursor query does not meet the SQL standard\*(Aqs rules for being +\(lqsimply updatable\(rq +(in particular, the cursor must reference just one table and not use grouping or +ORDER BY)\&. Cursors that are not simply updatable might work, or might not, depending on plan choice details; so in the worst case, an application might work in testing and then fail in production\&. +.PP +The main reason not to use +FOR UPDATE +with +WHERE CURRENT OF +is if you need the cursor to be scrollable, or to be insensitive to the subsequent updates (that is, continue to show the old data)\&. If this is a requirement, pay close heed to the caveats shown above\&. +.sp .5v +.RE +.PP +The SQL standard only makes provisions for cursors in embedded +SQL\&. The +PostgreSQL +server does not implement an +\fBOPEN\fR +statement for cursors; a cursor is considered to be open when it is declared\&. However, +ECPG, the embedded SQL preprocessor for +PostgreSQL, supports the standard SQL cursor conventions, including those involving +\fBDECLARE\fR +and +\fBOPEN\fR +statements\&. +.PP +You can see all available cursors by querying the +pg_cursors +system view\&. +.SH "EXAMPLES" +.PP +To declare a cursor: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DECLARE liahona CURSOR FOR SELECT * FROM films; +.fi +.if n \{\ +.RE +.\} +.sp +See +\fBFETCH\fR(7) +for more examples of cursor usage\&. +.SH "COMPATIBILITY" +.PP +The SQL standard says that it is implementation\-dependent whether cursors are sensitive to concurrent updates of the underlying data by default\&. In +PostgreSQL, cursors are insensitive by default, and can be made sensitive by specifying +FOR UPDATE\&. Other products may work differently\&. +.PP +The SQL standard allows cursors only in embedded +SQL +and in modules\&. +PostgreSQL +permits cursors to be used interactively\&. +.PP +Binary cursors are a +PostgreSQL +extension\&. +.SH "SEE ALSO" +\fBCLOSE\fR(7), \fBFETCH\fR(7), \fBMOVE\fR(7) diff --git a/doc/src/sgml/man7/DELETE.7 b/doc/src/sgml/man7/DELETE.7 new file mode 100644 index 000000000..1f89cb30d --- /dev/null +++ b/doc/src/sgml/man7/DELETE.7 @@ -0,0 +1,322 @@ +'\" t +.\" Title: DELETE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DELETE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DELETE \- delete rows of a table +.\" DELETE +.SH "SYNOPSIS" +.sp +.nf +[ WITH [ RECURSIVE ] \fIwith_query\fR [, \&.\&.\&.] ] +DELETE FROM [ ONLY ] \fItable_name\fR [ * ] [ [ AS ] \fIalias\fR ] + [ USING \fIusing_list\fR ] + [ WHERE \fIcondition\fR | WHERE CURRENT OF \fIcursor_name\fR ] + [ RETURNING * | \fIoutput_expression\fR [ [ AS ] \fIoutput_name\fR ] [, \&.\&.\&.] ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDELETE\fR +deletes rows that satisfy the +WHERE +clause from the specified table\&. If the +WHERE +clause is absent, the effect is to delete all rows in the table\&. The result is a valid, but empty table\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBTip\fR +.ps -1 +.br +.PP + +\fBTRUNCATE\fR(7) +is a +PostgreSQL +extension that provides a faster mechanism to remove all rows from a table\&. +.sp .5v +.RE +.PP +There are two ways to delete rows in a table using information contained in other tables in the database: using sub\-selects, or specifying additional tables in the +USING +clause\&. Which technique is more appropriate depends on the specific circumstances\&. +.PP +The optional +RETURNING +clause causes +\fBDELETE\fR +to compute and return value(s) based on each row actually deleted\&. Any expression using the table\*(Aqs columns, and/or columns of other tables mentioned in +USING, can be computed\&. The syntax of the +RETURNING +list is identical to that of the output list of +\fBSELECT\fR\&. +.PP +You must have the +DELETE +privilege on the table to delete from it, as well as the +SELECT +privilege for any table in the +USING +clause or whose values are read in the +\fIcondition\fR\&. +.SH "PARAMETERS" +.PP +\fIwith_query\fR +.RS 4 +The +WITH +clause allows you to specify one or more subqueries that can be referenced by name in the +\fBDELETE\fR +query\&. See +Section 7.8, \(lqWITH Queries (Common Table Expressions)\(rq, in the documentation +and +\fBSELECT\fR(7) +for details\&. +.RE +.PP +\fItable_name\fR +.RS 4 +The name (optionally schema\-qualified) of the table to delete rows from\&. If +ONLY +is specified before the table name, matching rows are deleted from the named table only\&. If +ONLY +is not specified, matching rows are also deleted from any tables inheriting from the named table\&. Optionally, +* +can be specified after the table name to explicitly indicate that descendant tables are included\&. +.RE +.PP +\fIalias\fR +.RS 4 +A substitute name for the target table\&. When an alias is provided, it completely hides the actual name of the table\&. For example, given +DELETE FROM foo AS f, the remainder of the +\fBDELETE\fR +statement must refer to this table as +f +not +foo\&. +.RE +.PP +\fIusing_list\fR +.RS 4 +A list of table expressions, allowing columns from other tables to appear in the +WHERE +condition\&. This is similar to the list of tables that can be specified in the +FROM Clause +of a +\fBSELECT\fR +statement; for example, an alias for the table name can be specified\&. Do not repeat the target table in the +\fIusing_list\fR, unless you wish to set up a self\-join\&. +.RE +.PP +\fIcondition\fR +.RS 4 +An expression that returns a value of type +boolean\&. Only rows for which this expression returns +true +will be deleted\&. +.RE +.PP +\fIcursor_name\fR +.RS 4 +The name of the cursor to use in a +WHERE CURRENT OF +condition\&. The row to be deleted is the one most recently fetched from this cursor\&. The cursor must be a non\-grouping query on the +\fBDELETE\fR\*(Aqs target table\&. Note that +WHERE CURRENT OF +cannot be specified together with a Boolean condition\&. See +\fBDECLARE\fR(7) +for more information about using cursors with +WHERE CURRENT OF\&. +.RE +.PP +\fIoutput_expression\fR +.RS 4 +An expression to be computed and returned by the +\fBDELETE\fR +command after each row is deleted\&. The expression can use any column names of the table named by +\fItable_name\fR +or table(s) listed in +USING\&. Write +* +to return all columns\&. +.RE +.PP +\fIoutput_name\fR +.RS 4 +A name to use for a returned column\&. +.RE +.SH "OUTPUTS" +.PP +On successful completion, a +\fBDELETE\fR +command returns a command tag of the form +.sp +.if n \{\ +.RS 4 +.\} +.nf +DELETE \fIcount\fR +.fi +.if n \{\ +.RE +.\} +.sp +The +\fIcount\fR +is the number of rows deleted\&. Note that the number may be less than the number of rows that matched the +\fIcondition\fR +when deletes were suppressed by a +BEFORE DELETE +trigger\&. If +\fIcount\fR +is 0, no rows were deleted by the query (this is not considered an error)\&. +.PP +If the +\fBDELETE\fR +command contains a +RETURNING +clause, the result will be similar to that of a +\fBSELECT\fR +statement containing the columns and values defined in the +RETURNING +list, computed over the row(s) deleted by the command\&. +.SH "NOTES" +.PP + +PostgreSQL +lets you reference columns of other tables in the +WHERE +condition by specifying the other tables in the +USING +clause\&. For example, to delete all films produced by a given producer, one can do: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DELETE FROM films USING producers + WHERE producer_id = producers\&.id AND producers\&.name = \*(Aqfoo\*(Aq; +.fi +.if n \{\ +.RE +.\} +.sp +What is essentially happening here is a join between +films +and +producers, with all successfully joined +films +rows being marked for deletion\&. This syntax is not standard\&. A more standard way to do it is: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DELETE FROM films + WHERE producer_id IN (SELECT id FROM producers WHERE name = \*(Aqfoo\*(Aq); +.fi +.if n \{\ +.RE +.\} +.sp +In some cases the join style is easier to write or faster to execute than the sub\-select style\&. +.SH "EXAMPLES" +.PP +Delete all films but musicals: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DELETE FROM films WHERE kind <> \*(AqMusical\*(Aq; +.fi +.if n \{\ +.RE +.\} +.PP +Clear the table +films: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DELETE FROM films; +.fi +.if n \{\ +.RE +.\} +.PP +Delete completed tasks, returning full details of the deleted rows: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DELETE FROM tasks WHERE status = \*(AqDONE\*(Aq RETURNING *; +.fi +.if n \{\ +.RE +.\} +.PP +Delete the row of +tasks +on which the cursor +c_tasks +is currently positioned: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DELETE FROM tasks WHERE CURRENT OF c_tasks; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +This command conforms to the +SQL +standard, except that the +USING +and +RETURNING +clauses are +PostgreSQL +extensions, as is the ability to use +WITH +with +\fBDELETE\fR\&. diff --git a/doc/src/sgml/man7/DISCARD.7 b/doc/src/sgml/man7/DISCARD.7 new file mode 100644 index 000000000..45e04d70e --- /dev/null +++ b/doc/src/sgml/man7/DISCARD.7 @@ -0,0 +1,95 @@ +'\" t +.\" Title: DISCARD +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DISCARD" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DISCARD \- discard session state +.\" DISCARD +.SH "SYNOPSIS" +.sp +.nf +DISCARD { ALL | PLANS | TEMPORARY | TEMP } +.fi +.SH "DESCRIPTION" +.PP + +\fBDISCARD\fR +releases internal resources associated with a database session\&. These resources are normally released at the end of the session\&. +.PP + +\fBDISCARD TEMP\fR +drops all temporary tables created in the current session\&. +\fBDISCARD PLANS\fR +releases all internally cached query plans\&. +\fBDISCARD ALL\fR +resets a session to its original state, discarding temporary resources and resetting session\-local configuration changes\&. +.SH "PARAMETERS" +.PP +TEMPORARY or TEMP +.RS 4 +Drops all temporary tables created in the current session\&. +.RE +.PP +PLANS +.RS 4 +Releases all cached query plans\&. +.RE +.PP +ALL +.RS 4 +Releases all temporary resources associated with the current session and resets the session to its initial state\&. Currently, this has the same effect as executing the following sequence of statements: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SET SESSION AUTHORIZATION DEFAULT; +RESET ALL; +DEALLOCATE ALL; +CLOSE ALL; +UNLISTEN *; +SELECT pg_advisory_unlock_all(); +DISCARD PLANS; +DISCARD TEMP; +.fi +.if n \{\ +.RE +.\} +.RE +.SH "NOTES" +.PP + +\fBDISCARD ALL\fR +cannot be executed inside a transaction block\&. +.SH "COMPATIBILITY" +.PP + +\fBDISCARD\fR +is a +PostgreSQL +extension\&. diff --git a/doc/src/sgml/man7/DO.7 b/doc/src/sgml/man7/DO.7 new file mode 100644 index 000000000..1f80a6a07 --- /dev/null +++ b/doc/src/sgml/man7/DO.7 @@ -0,0 +1,103 @@ +'\" t +.\" Title: DO +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DO" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DO \- execute an anonymous code block +.\" DO +.\" anonymous code blocks +.SH "SYNOPSIS" +.sp +.nf +DO [ LANGUAGE \fIlang_name\fR ] \fIcode\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBDO\fR +executes an anonymous code block, or in other words a transient anonymous function in a procedural language\&. +.PP +The code block is treated as though it were the body of a function with no parameters, returning +void\&. It is parsed and executed a single time\&. +.PP +The optional +LANGUAGE +clause can be written either before or after the code block\&. +.SH "PARAMETERS" +.PP +\fIcode\fR +.RS 4 +The procedural language code to be executed\&. This must be specified as a string literal, just as in +\fBCREATE FUNCTION\fR\&. Use of a dollar\-quoted literal is recommended\&. +.RE +.PP +\fIlang_name\fR +.RS 4 +The name of the procedural language the code is written in\&. If omitted, the default is +plpgsql\&. +.RE +.SH "NOTES" +.PP +The procedural language to be used must already have been installed into the current database by means of +\fBCREATE LANGUAGE\fR\&. +plpgsql +is installed by default, but other languages are not\&. +.PP +The user must have +USAGE +privilege for the procedural language, or must be a superuser if the language is untrusted\&. This is the same privilege requirement as for creating a function in the language\&. +.SH "EXAMPLES" +.PP +Grant all privileges on all views in schema +public +to role +webuser: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DO $$DECLARE r record; +BEGIN + FOR r IN SELECT table_schema, table_name FROM information_schema\&.tables + WHERE table_type = \*(AqVIEW\*(Aq AND table_schema = \*(Aqpublic\*(Aq + LOOP + EXECUTE \*(AqGRANT ALL ON \*(Aq || quote_ident(r\&.table_schema) || \*(Aq\&.\*(Aq || quote_ident(r\&.table_name) || \*(Aq TO webuser\*(Aq; + END LOOP; +END$$; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBDO\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +CREATE LANGUAGE (\fBCREATE_LANGUAGE\fR(7)) diff --git a/doc/src/sgml/man7/DROP_AGGREGATE.7 b/doc/src/sgml/man7/DROP_AGGREGATE.7 new file mode 100644 index 000000000..86822c14e --- /dev/null +++ b/doc/src/sgml/man7/DROP_AGGREGATE.7 @@ -0,0 +1,93 @@ +'\" t +.\" Title: DROP AGGREGATE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP AGGREGATE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_AGGREGATE \- remove an aggregate function +.\" DROP AGGREGATE +.SH "SYNOPSIS" +.sp +.nf +DROP AGGREGATE [ IF EXISTS ] \fIname\fR ( \fIargtype\fR [ , \&.\&.\&. ] ) [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP AGGREGATE\fR +removes an existing aggregate function\&. To execute this command the current user must be the owner of the aggregate function\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the aggregate does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an existing aggregate function\&. +.RE +.PP +\fIargtype\fR +.RS 4 +An input data type on which the aggregate function operates\&. To reference a zero\-argument aggregate function, write +* +in place of the list of input data types\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the aggregate function\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the aggregate function if any objects depend on it\&. This is the default\&. +.RE +.SH "EXAMPLES" +.PP +To remove the aggregate function +myavg +for type +integer: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP AGGREGATE myavg(integer); +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBDROP AGGREGATE\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +ALTER AGGREGATE (\fBALTER_AGGREGATE\fR(7)), CREATE AGGREGATE (\fBCREATE_AGGREGATE\fR(7)) diff --git a/doc/src/sgml/man7/DROP_CAST.7 b/doc/src/sgml/man7/DROP_CAST.7 new file mode 100644 index 000000000..d340c99a5 --- /dev/null +++ b/doc/src/sgml/man7/DROP_CAST.7 @@ -0,0 +1,88 @@ +'\" t +.\" Title: DROP CAST +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP CAST" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_CAST \- remove a cast +.\" DROP CAST +.SH "SYNOPSIS" +.sp +.nf +DROP CAST [ IF EXISTS ] (\fIsource_type\fR AS \fItarget_type\fR) [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP CAST\fR +removes a previously defined cast\&. +.PP +To be able to drop a cast, you must own the source or the target data type\&. These are the same privileges that are required to create a cast\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the cast does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIsource_type\fR +.RS 4 +The name of the source data type of the cast\&. +.RE +.PP +\fItarget_type\fR +.RS 4 +The name of the target data type of the cast\&. +.RE +.PP +CASCADE, RESTRICT +.RS 4 +These key words do not have any effect, since there are no dependencies on casts\&. +.RE +.SH "EXAMPLES" +.PP +To drop the cast from type +text +to type +int: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP CAST (text AS int); +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +The +\fBDROP CAST\fR +command conforms to the SQL standard\&. +.SH "SEE ALSO" +CREATE CAST (\fBCREATE_CAST\fR(7)) diff --git a/doc/src/sgml/man7/DROP_COLLATION.7 b/doc/src/sgml/man7/DROP_COLLATION.7 new file mode 100644 index 000000000..ebd4df870 --- /dev/null +++ b/doc/src/sgml/man7/DROP_COLLATION.7 @@ -0,0 +1,90 @@ +'\" t +.\" Title: DROP COLLATION +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP COLLATION" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_COLLATION \- remove a collation +.\" DROP COLLATION +.SH "SYNOPSIS" +.sp +.nf +DROP COLLATION [ IF EXISTS ] \fIname\fR [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP COLLATION\fR +removes a previously defined collation\&. To be able to drop a collation, you must own the collation\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the collation does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name of the collation\&. The collation name can be schema\-qualified\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the collation\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the collation if any objects depend on it\&. This is the default\&. +.RE +.SH "EXAMPLES" +.PP +To drop the collation named +german: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP COLLATION german; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +The +\fBDROP COLLATION\fR +command conforms to the +SQL +standard, apart from the +IF EXISTS +option, which is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +ALTER COLLATION (\fBALTER_COLLATION\fR(7)), CREATE COLLATION (\fBCREATE_COLLATION\fR(7)) diff --git a/doc/src/sgml/man7/DROP_CONVERSION.7 b/doc/src/sgml/man7/DROP_CONVERSION.7 new file mode 100644 index 000000000..deb1f3369 --- /dev/null +++ b/doc/src/sgml/man7/DROP_CONVERSION.7 @@ -0,0 +1,85 @@ +'\" t +.\" Title: DROP CONVERSION +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP CONVERSION" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_CONVERSION \- remove a conversion +.\" DROP CONVERSION +.SH "SYNOPSIS" +.sp +.nf +DROP CONVERSION [ IF EXISTS ] \fIname\fR [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP CONVERSION\fR +removes a previously defined conversion\&. To be able to drop a conversion, you must own the conversion\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the conversion does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name of the conversion\&. The conversion name can be schema\-qualified\&. +.RE +.PP +CASCADE, RESTRICT +.RS 4 +These key words do not have any effect, since there are no dependencies on conversions\&. +.RE +.SH "EXAMPLES" +.PP +To drop the conversion named +myname: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP CONVERSION myname; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBDROP CONVERSION\fR +statement in the SQL standard, but a +\fBDROP TRANSLATION\fR +statement that goes along with the +\fBCREATE TRANSLATION\fR +statement that is similar to the +\fBCREATE CONVERSION\fR +statement in PostgreSQL\&. +.SH "SEE ALSO" +ALTER CONVERSION (\fBALTER_CONVERSION\fR(7)), CREATE CONVERSION (\fBCREATE_CONVERSION\fR(7)) diff --git a/doc/src/sgml/man7/DROP_DATABASE.7 b/doc/src/sgml/man7/DROP_DATABASE.7 new file mode 100644 index 000000000..b90f7324f --- /dev/null +++ b/doc/src/sgml/man7/DROP_DATABASE.7 @@ -0,0 +1,75 @@ +'\" t +.\" Title: DROP DATABASE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP DATABASE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_DATABASE \- remove a database +.\" DROP DATABASE +.SH "SYNOPSIS" +.sp +.nf +DROP DATABASE [ IF EXISTS ] \fIname\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP DATABASE\fR +drops a database\&. It removes the catalog entries for the database and deletes the directory containing the data\&. It can only be executed by the database owner\&. Also, it cannot be executed while you or anyone else are connected to the target database\&. (Connect to +postgres +or any other database to issue this command\&.) +.PP + +\fBDROP DATABASE\fR +cannot be undone\&. Use it with care! +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the database does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name of the database to remove\&. +.RE +.SH "NOTES" +.PP + +\fBDROP DATABASE\fR +cannot be executed inside a transaction block\&. +.PP +This command cannot be executed while connected to the target database\&. Thus, it might be more convenient to use the program +\fBdropdb\fR(1) +instead, which is a wrapper around this command\&. +.SH "COMPATIBILITY" +.PP +There is no +\fBDROP DATABASE\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +CREATE DATABASE (\fBCREATE_DATABASE\fR(7)) diff --git a/doc/src/sgml/man7/DROP_DOMAIN.7 b/doc/src/sgml/man7/DROP_DOMAIN.7 new file mode 100644 index 000000000..7d078d71d --- /dev/null +++ b/doc/src/sgml/man7/DROP_DOMAIN.7 @@ -0,0 +1,86 @@ +'\" t +.\" Title: DROP DOMAIN +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP DOMAIN" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_DOMAIN \- remove a domain +.\" DROP DOMAIN +.SH "SYNOPSIS" +.sp +.nf +DROP DOMAIN [ IF EXISTS ] \fIname\fR [, \&.\&.\&.] [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP DOMAIN\fR +removes a domain\&. Only the owner of a domain can remove it\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the domain does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an existing domain\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the domain (such as table columns)\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the domain if any objects depend on it\&. This is the default\&. +.RE +.SH "EXAMPLES" +.PP +To remove the domain +box: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP DOMAIN box; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +This command conforms to the SQL standard, except for the +IF EXISTS +option, which is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +CREATE DOMAIN (\fBCREATE_DOMAIN\fR(7)), ALTER DOMAIN (\fBALTER_DOMAIN\fR(7)) diff --git a/doc/src/sgml/man7/DROP_EXTENSION.7 b/doc/src/sgml/man7/DROP_EXTENSION.7 new file mode 100644 index 000000000..825304991 --- /dev/null +++ b/doc/src/sgml/man7/DROP_EXTENSION.7 @@ -0,0 +1,99 @@ +'\" t +.\" Title: DROP EXTENSION +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP EXTENSION" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_EXTENSION \- remove an extension +.\" DROP EXTENSION +.SH "SYNOPSIS" +.sp +.nf +DROP EXTENSION [ IF EXISTS ] \fIname\fR [, \&.\&.\&.] [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP EXTENSION\fR +removes extensions from the database\&. Dropping an extension causes its component objects to be dropped as well\&. +.PP +You must own the extension to use +\fBDROP EXTENSION\fR\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the extension does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name of an installed extension\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the extension\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the extension if any objects depend on it (other than its own member objects and other extensions listed in the same +\fBDROP\fR +command)\&. This is the default\&. +.RE +.SH "EXAMPLES" +.PP +To remove the extension +hstore +from the current database: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP EXTENSION hstore; +.fi +.if n \{\ +.RE +.\} +.sp +This command will fail if any of +hstore\*(Aqs objects are in use in the database, for example if any tables have columns of the +hstore +type\&. Add the +CASCADE +option to forcibly remove those dependent objects as well\&. +.SH "COMPATIBILITY" +.PP + +\fBDROP EXTENSION\fR +is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +CREATE EXTENSION (\fBCREATE_EXTENSION\fR(7)), ALTER EXTENSION (\fBALTER_EXTENSION\fR(7)) diff --git a/doc/src/sgml/man7/DROP_FOREIGN_DATA_WRAPPER.7 b/doc/src/sgml/man7/DROP_FOREIGN_DATA_WRAPPER.7 new file mode 100644 index 000000000..a4a9f3dc4 --- /dev/null +++ b/doc/src/sgml/man7/DROP_FOREIGN_DATA_WRAPPER.7 @@ -0,0 +1,88 @@ +'\" t +.\" Title: DROP FOREIGN DATA WRAPPER +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP FOREIGN DATA WRAPPER" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_FOREIGN_DATA_WRAPPER \- remove a foreign\-data wrapper +.\" DROP FOREIGN DATA WRAPPER +.SH "SYNOPSIS" +.sp +.nf +DROP FOREIGN DATA WRAPPER [ IF EXISTS ] \fIname\fR [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP FOREIGN DATA WRAPPER\fR +removes an existing foreign\-data wrapper\&. To execute this command, the current user must be the owner of the foreign\-data wrapper\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the foreign\-data wrapper does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name of an existing foreign\-data wrapper\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the foreign\-data wrapper (such as servers)\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the foreign\-data wrappers if any objects depend on it\&. This is the default\&. +.RE +.SH "EXAMPLES" +.PP +Drop the foreign\-data wrapper +dbi: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP FOREIGN DATA WRAPPER dbi; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBDROP FOREIGN DATA WRAPPER\fR +conforms to ISO/IEC 9075\-9 (SQL/MED)\&. The +IF EXISTS +clause is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +CREATE FOREIGN DATA WRAPPER (\fBCREATE_FOREIGN_DATA_WRAPPER\fR(7)), ALTER FOREIGN DATA WRAPPER (\fBALTER_FOREIGN_DATA_WRAPPER\fR(7)) diff --git a/doc/src/sgml/man7/DROP_FOREIGN_TABLE.7 b/doc/src/sgml/man7/DROP_FOREIGN_TABLE.7 new file mode 100644 index 000000000..91d7daf79 --- /dev/null +++ b/doc/src/sgml/man7/DROP_FOREIGN_TABLE.7 @@ -0,0 +1,88 @@ +'\" t +.\" Title: DROP FOREIGN TABLE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP FOREIGN TABLE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_FOREIGN_TABLE \- remove a foreign table +.\" DROP FOREIGN TABLE +.SH "SYNOPSIS" +.sp +.nf +DROP FOREIGN TABLE [ IF EXISTS ] \fIname\fR [, \&.\&.\&.] [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP FOREIGN TABLE\fR +removes a foreign table\&. Only the owner of a foreign table can remove it\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the foreign table does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of the foreign table to drop\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the foreign table (such as views)\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the foreign table if any objects depend on it\&. This is the default\&. +.RE +.SH "EXAMPLES" +.PP +To destroy two foreign tables, +films +and +distributors: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP FOREIGN TABLE films, distributors; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +This command conforms to the ISO/IEC 9075\-9 (SQL/MED), except that the standard only allows one foreign table to be dropped per command, and apart from the +IF EXISTS +option, which is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +ALTER FOREIGN TABLE (\fBALTER_FOREIGN_TABLE\fR(7)), CREATE FOREIGN TABLE (\fBCREATE_FOREIGN_TABLE\fR(7)) diff --git a/doc/src/sgml/man7/DROP_FUNCTION.7 b/doc/src/sgml/man7/DROP_FUNCTION.7 new file mode 100644 index 000000000..7eb5634b9 --- /dev/null +++ b/doc/src/sgml/man7/DROP_FUNCTION.7 @@ -0,0 +1,114 @@ +'\" t +.\" Title: DROP FUNCTION +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP FUNCTION" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_FUNCTION \- remove a function +.\" DROP FUNCTION +.SH "SYNOPSIS" +.sp +.nf +DROP FUNCTION [ IF EXISTS ] \fIname\fR ( [ [ \fIargmode\fR ] [ \fIargname\fR ] \fIargtype\fR [, \&.\&.\&.] ] ) + [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP FUNCTION\fR +removes the definition of an existing function\&. To execute this command the user must be the owner of the function\&. The argument types to the function must be specified, since several different functions can exist with the same name and different argument lists\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the function does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an existing function\&. +.RE +.PP +\fIargmode\fR +.RS 4 +The mode of an argument: +IN, +OUT, +INOUT, or +VARIADIC\&. If omitted, the default is +IN\&. Note that +\fBDROP FUNCTION\fR +does not actually pay any attention to +OUT +arguments, since only the input arguments are needed to determine the function\*(Aqs identity\&. So it is sufficient to list the +IN, +INOUT, and +VARIADIC +arguments\&. +.RE +.PP +\fIargname\fR +.RS 4 +The name of an argument\&. Note that +\fBDROP FUNCTION\fR +does not actually pay any attention to argument names, since only the argument data types are needed to determine the function\*(Aqs identity\&. +.RE +.PP +\fIargtype\fR +.RS 4 +The data type(s) of the function\*(Aqs arguments (optionally schema\-qualified), if any\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the function (such as operators or triggers)\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the function if any objects depend on it\&. This is the default\&. +.RE +.SH "EXAMPLES" +.PP +This command removes the square root function: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP FUNCTION sqrt(integer); +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +A +\fBDROP FUNCTION\fR +statement is defined in the SQL standard, but it is not compatible with this command\&. +.SH "SEE ALSO" +CREATE FUNCTION (\fBCREATE_FUNCTION\fR(7)), ALTER FUNCTION (\fBALTER_FUNCTION\fR(7)) diff --git a/doc/src/sgml/man7/DROP_GROUP.7 b/doc/src/sgml/man7/DROP_GROUP.7 new file mode 100644 index 000000000..0966d1006 --- /dev/null +++ b/doc/src/sgml/man7/DROP_GROUP.7 @@ -0,0 +1,50 @@ +'\" t +.\" Title: DROP GROUP +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP GROUP" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_GROUP \- remove a database role +.\" DROP GROUP +.SH "SYNOPSIS" +.sp +.nf +DROP GROUP [ IF EXISTS ] \fIname\fR [, \&.\&.\&.] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP GROUP\fR +is now an alias for +DROP ROLE (\fBDROP_ROLE\fR(7))\&. +.SH "COMPATIBILITY" +.PP +There is no +\fBDROP GROUP\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +DROP ROLE (\fBDROP_ROLE\fR(7)) diff --git a/doc/src/sgml/man7/DROP_INDEX.7 b/doc/src/sgml/man7/DROP_INDEX.7 new file mode 100644 index 000000000..ca7f7f237 --- /dev/null +++ b/doc/src/sgml/man7/DROP_INDEX.7 @@ -0,0 +1,105 @@ +'\" t +.\" Title: DROP INDEX +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP INDEX" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_INDEX \- remove an index +.\" DROP INDEX +.SH "SYNOPSIS" +.sp +.nf +DROP INDEX [ CONCURRENTLY ] [ IF EXISTS ] \fIname\fR [, \&.\&.\&.] [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP INDEX\fR +drops an existing index from the database system\&. To execute this command you must be the owner of the index\&. +.SH "PARAMETERS" +.PP +CONCURRENTLY +.RS 4 +Drop the index without locking out concurrent selects, inserts, updates, and deletes on the index\*(Aqs table\&. A normal +\fBDROP INDEX\fR +acquires exclusive lock on the table, blocking other accesses until the index drop can be completed\&. With this option, the command instead waits until conflicting transactions have completed\&. +.sp +There are several caveats to be aware of when using this option\&. Only one index name can be specified, and the +CASCADE +option is not supported\&. (Thus, an index that supports a +UNIQUE +or +PRIMARY KEY +constraint cannot be dropped this way\&.) Also, regular +\fBDROP INDEX\fR +commands can be performed within a transaction block, but +\fBDROP INDEX CONCURRENTLY\fR +cannot\&. +.RE +.PP +IF EXISTS +.RS 4 +Do not throw an error if the index does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an index to remove\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the index\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the index if any objects depend on it\&. This is the default\&. +.RE +.SH "EXAMPLES" +.PP +This command will remove the index +title_idx: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP INDEX title_idx; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBDROP INDEX\fR +is a +PostgreSQL +language extension\&. There are no provisions for indexes in the SQL standard\&. +.SH "SEE ALSO" +CREATE INDEX (\fBCREATE_INDEX\fR(7)) diff --git a/doc/src/sgml/man7/DROP_LANGUAGE.7 b/doc/src/sgml/man7/DROP_LANGUAGE.7 new file mode 100644 index 000000000..4a02418ae --- /dev/null +++ b/doc/src/sgml/man7/DROP_LANGUAGE.7 @@ -0,0 +1,107 @@ +'\" t +.\" Title: DROP LANGUAGE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP LANGUAGE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_LANGUAGE \- remove a procedural language +.\" DROP LANGUAGE +.SH "SYNOPSIS" +.sp +.nf +DROP [ PROCEDURAL ] LANGUAGE [ IF EXISTS ] \fIname\fR [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP LANGUAGE\fR +removes the definition of a previously registered procedural language\&. You must be a superuser or the owner of the language to use +\fBDROP LANGUAGE\fR\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +.PP +As of +PostgreSQL +9\&.1, most procedural languages have been made into +\(lqextensions\(rq, and should therefore be removed with +DROP EXTENSION (\fBDROP_EXTENSION\fR(7)) +not +\fBDROP LANGUAGE\fR\&. +.sp .5v +.RE +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the language does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name of an existing procedural language\&. For backward compatibility, the name can be enclosed by single quotes\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the language (such as functions in the language)\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the language if any objects depend on it\&. This is the default\&. +.RE +.SH "EXAMPLES" +.PP +This command removes the procedural language +plsample: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP LANGUAGE plsample; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBDROP LANGUAGE\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +ALTER LANGUAGE (\fBALTER_LANGUAGE\fR(7)), CREATE LANGUAGE (\fBCREATE_LANGUAGE\fR(7)), \fBdroplang\fR(1) diff --git a/doc/src/sgml/man7/DROP_OPERATOR.7 b/doc/src/sgml/man7/DROP_OPERATOR.7 new file mode 100644 index 000000000..7dc2b6df2 --- /dev/null +++ b/doc/src/sgml/man7/DROP_OPERATOR.7 @@ -0,0 +1,130 @@ +'\" t +.\" Title: DROP OPERATOR +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP OPERATOR" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_OPERATOR \- remove an operator +.\" DROP OPERATOR +.SH "SYNOPSIS" +.sp +.nf +DROP OPERATOR [ IF EXISTS ] \fIname\fR ( { \fIleft_type\fR | NONE } , { \fIright_type\fR | NONE } ) [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP OPERATOR\fR +drops an existing operator from the database system\&. To execute this command you must be the owner of the operator\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the operator does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an existing operator\&. +.RE +.PP +\fIleft_type\fR +.RS 4 +The data type of the operator\*(Aqs left operand; write +NONE +if the operator has no left operand\&. +.RE +.PP +\fIright_type\fR +.RS 4 +The data type of the operator\*(Aqs right operand; write +NONE +if the operator has no right operand\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the operator\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the operator if any objects depend on it\&. This is the default\&. +.RE +.SH "EXAMPLES" +.PP +Remove the power operator +a^b +for type +integer: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP OPERATOR ^ (integer, integer); +.fi +.if n \{\ +.RE +.\} +.PP +Remove the left unary bitwise complement operator +~b +for type +bit: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP OPERATOR ~ (none, bit); +.fi +.if n \{\ +.RE +.\} +.PP +Remove the right unary factorial operator +x! +for type +bigint: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP OPERATOR ! (bigint, none); +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBDROP OPERATOR\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +CREATE OPERATOR (\fBCREATE_OPERATOR\fR(7)), ALTER OPERATOR (\fBALTER_OPERATOR\fR(7)) diff --git a/doc/src/sgml/man7/DROP_OPERATOR_CLASS.7 b/doc/src/sgml/man7/DROP_OPERATOR_CLASS.7 new file mode 100644 index 000000000..f144c8240 --- /dev/null +++ b/doc/src/sgml/man7/DROP_OPERATOR_CLASS.7 @@ -0,0 +1,108 @@ +'\" t +.\" Title: DROP OPERATOR CLASS +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP OPERATOR CLASS" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_OPERATOR_CLASS \- remove an operator class +.\" DROP OPERATOR CLASS +.SH "SYNOPSIS" +.sp +.nf +DROP OPERATOR CLASS [ IF EXISTS ] \fIname\fR USING \fIindex_method\fR [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP OPERATOR CLASS\fR +drops an existing operator class\&. To execute this command you must be the owner of the operator class\&. +.PP + +\fBDROP OPERATOR CLASS\fR +does not drop any of the operators or functions referenced by the class\&. If there are any indexes depending on the operator class, you will need to specify +CASCADE +for the drop to complete\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the operator class does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an existing operator class\&. +.RE +.PP +\fIindex_method\fR +.RS 4 +The name of the index access method the operator class is for\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the operator class\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the operator class if any objects depend on it\&. This is the default\&. +.RE +.SH "NOTES" +.PP + +\fBDROP OPERATOR CLASS\fR +will not drop the operator family containing the class, even if there is nothing else left in the family (in particular, in the case where the family was implicitly created by +\fBCREATE OPERATOR CLASS\fR)\&. An empty operator family is harmless, but for the sake of tidiness you might wish to remove the family with +\fBDROP OPERATOR FAMILY\fR; or perhaps better, use +\fBDROP OPERATOR FAMILY\fR +in the first place\&. +.SH "EXAMPLES" +.PP +Remove the B\-tree operator class +widget_ops: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP OPERATOR CLASS widget_ops USING btree; +.fi +.if n \{\ +.RE +.\} +.sp +This command will not succeed if there are any existing indexes that use the operator class\&. Add +CASCADE +to drop such indexes along with the operator class\&. +.SH "COMPATIBILITY" +.PP +There is no +\fBDROP OPERATOR CLASS\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +ALTER OPERATOR CLASS (\fBALTER_OPERATOR_CLASS\fR(7)), CREATE OPERATOR CLASS (\fBCREATE_OPERATOR_CLASS\fR(7)), DROP OPERATOR FAMILY (\fBDROP_OPERATOR_FAMILY\fR(7)) diff --git a/doc/src/sgml/man7/DROP_OPERATOR_FAMILY.7 b/doc/src/sgml/man7/DROP_OPERATOR_FAMILY.7 new file mode 100644 index 000000000..a2e436fc7 --- /dev/null +++ b/doc/src/sgml/man7/DROP_OPERATOR_FAMILY.7 @@ -0,0 +1,99 @@ +'\" t +.\" Title: DROP OPERATOR FAMILY +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP OPERATOR FAMILY" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_OPERATOR_FAMILY \- remove an operator family +.\" DROP OPERATOR FAMILY +.SH "SYNOPSIS" +.sp +.nf +DROP OPERATOR FAMILY [ IF EXISTS ] \fIname\fR USING \fIindex_method\fR [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP OPERATOR FAMILY\fR +drops an existing operator family\&. To execute this command you must be the owner of the operator family\&. +.PP + +\fBDROP OPERATOR FAMILY\fR +includes dropping any operator classes contained in the family, but it does not drop any of the operators or functions referenced by the family\&. If there are any indexes depending on operator classes within the family, you will need to specify +CASCADE +for the drop to complete\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the operator family does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an existing operator family\&. +.RE +.PP +\fIindex_method\fR +.RS 4 +The name of the index access method the operator family is for\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the operator family\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the operator family if any objects depend on it\&. This is the default\&. +.RE +.SH "EXAMPLES" +.PP +Remove the B\-tree operator family +float_ops: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP OPERATOR FAMILY float_ops USING btree; +.fi +.if n \{\ +.RE +.\} +.sp +This command will not succeed if there are any existing indexes that use operator classes within the family\&. Add +CASCADE +to drop such indexes along with the operator family\&. +.SH "COMPATIBILITY" +.PP +There is no +\fBDROP OPERATOR FAMILY\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +ALTER OPERATOR FAMILY (\fBALTER_OPERATOR_FAMILY\fR(7)), CREATE OPERATOR FAMILY (\fBCREATE_OPERATOR_FAMILY\fR(7)), ALTER OPERATOR CLASS (\fBALTER_OPERATOR_CLASS\fR(7)), CREATE OPERATOR CLASS (\fBCREATE_OPERATOR_CLASS\fR(7)), DROP OPERATOR CLASS (\fBDROP_OPERATOR_CLASS\fR(7)) diff --git a/doc/src/sgml/man7/DROP_OWNED.7 b/doc/src/sgml/man7/DROP_OWNED.7 new file mode 100644 index 000000000..db59c3745 --- /dev/null +++ b/doc/src/sgml/man7/DROP_OWNED.7 @@ -0,0 +1,84 @@ +'\" t +.\" Title: DROP OWNED +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP OWNED" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_OWNED \- remove database objects owned by a database role +.\" DROP OWNED +.SH "SYNOPSIS" +.sp +.nf +DROP OWNED BY \fIname\fR [, \&.\&.\&.] [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP OWNED\fR +drops all the objects in the current database that are owned by one of the specified roles\&. Any privileges granted to the given roles on objects in the current database will also be revoked\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name of a role whose objects will be dropped, and whose privileges will be revoked\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the affected objects\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the objects owned by a role if any other database objects depend on one of the affected objects\&. This is the default\&. +.RE +.SH "NOTES" +.PP + +\fBDROP OWNED\fR +is often used to prepare for the removal of one or more roles\&. Because +\fBDROP OWNED\fR +only affects the objects in the current database, it is usually necessary to execute this command in each database that contains objects owned by a role that is to be removed\&. +.PP +Using the +CASCADE +option might make the command recurse to objects owned by other users\&. +.PP +The +REASSIGN OWNED (\fBREASSIGN_OWNED\fR(7)) +command is an alternative that reassigns the ownership of all the database objects owned by one or more roles\&. +.PP +Databases owned by the role(s) will not be removed\&. +.SH "COMPATIBILITY" +.PP +The +\fBDROP OWNED\fR +statement is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +REASSIGN OWNED (\fBREASSIGN_OWNED\fR(7)), DROP ROLE (\fBDROP_ROLE\fR(7)) diff --git a/doc/src/sgml/man7/DROP_ROLE.7 b/doc/src/sgml/man7/DROP_ROLE.7 new file mode 100644 index 000000000..ed5928f48 --- /dev/null +++ b/doc/src/sgml/man7/DROP_ROLE.7 @@ -0,0 +1,93 @@ +'\" t +.\" Title: DROP ROLE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP ROLE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_ROLE \- remove a database role +.\" DROP ROLE +.SH "SYNOPSIS" +.sp +.nf +DROP ROLE [ IF EXISTS ] \fIname\fR [, \&.\&.\&.] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP ROLE\fR +removes the specified role(s)\&. To drop a superuser role, you must be a superuser yourself; to drop non\-superuser roles, you must have +CREATEROLE +privilege\&. +.PP +A role cannot be removed if it is still referenced in any database of the cluster; an error will be raised if so\&. Before dropping the role, you must drop all the objects it owns (or reassign their ownership) and revoke any privileges the role has been granted\&. The +REASSIGN OWNED (\fBREASSIGN_OWNED\fR(7)) +and +DROP OWNED (\fBDROP_OWNED\fR(7)) +commands can be useful for this purpose\&. +.PP +However, it is not necessary to remove role memberships involving the role; +\fBDROP ROLE\fR +automatically revokes any memberships of the target role in other roles, and of other roles in the target role\&. The other roles are not dropped nor otherwise affected\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the role does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name of the role to remove\&. +.RE +.SH "NOTES" +.PP + +PostgreSQL +includes a program +\fBdropuser\fR(1) +that has the same functionality as this command (in fact, it calls this command) but can be run from the command shell\&. +.SH "EXAMPLES" +.PP +To drop a role: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP ROLE jonathan; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +The SQL standard defines +\fBDROP ROLE\fR, but it allows only one role to be dropped at a time, and it specifies different privilege requirements than +PostgreSQL +uses\&. +.SH "SEE ALSO" +CREATE ROLE (\fBCREATE_ROLE\fR(7)), ALTER ROLE (\fBALTER_ROLE\fR(7)), SET ROLE (\fBSET_ROLE\fR(7)) diff --git a/doc/src/sgml/man7/DROP_RULE.7 b/doc/src/sgml/man7/DROP_RULE.7 new file mode 100644 index 000000000..47844332a --- /dev/null +++ b/doc/src/sgml/man7/DROP_RULE.7 @@ -0,0 +1,89 @@ +'\" t +.\" Title: DROP RULE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP RULE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_RULE \- remove a rewrite rule +.\" DROP RULE +.SH "SYNOPSIS" +.sp +.nf +DROP RULE [ IF EXISTS ] \fIname\fR ON \fItable_name\fR [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP RULE\fR +drops a rewrite rule\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the rule does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name of the rule to drop\&. +.RE +.PP +\fItable_name\fR +.RS 4 +The name (optionally schema\-qualified) of the table or view that the rule applies to\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the rule\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the rule if any objects depend on it\&. This is the default\&. +.RE +.SH "EXAMPLES" +.PP +To drop the rewrite rule +newrule: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP RULE newrule ON mytable; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBDROP RULE\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +CREATE RULE (\fBCREATE_RULE\fR(7)) diff --git a/doc/src/sgml/man7/DROP_SCHEMA.7 b/doc/src/sgml/man7/DROP_SCHEMA.7 new file mode 100644 index 000000000..b3eb4112d --- /dev/null +++ b/doc/src/sgml/man7/DROP_SCHEMA.7 @@ -0,0 +1,91 @@ +'\" t +.\" Title: DROP SCHEMA +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP SCHEMA" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_SCHEMA \- remove a schema +.\" DROP SCHEMA +.SH "SYNOPSIS" +.sp +.nf +DROP SCHEMA [ IF EXISTS ] \fIname\fR [, \&.\&.\&.] [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP SCHEMA\fR +removes schemas from the database\&. +.PP +A schema can only be dropped by its owner or a superuser\&. Note that the owner can drop the schema (and thereby all contained objects) even if he does not own some of the objects within the schema\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the schema does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name of a schema\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects (tables, functions, etc\&.) that are contained in the schema\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the schema if it contains any objects\&. This is the default\&. +.RE +.SH "EXAMPLES" +.PP +To remove schema +mystuff +from the database, along with everything it contains: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP SCHEMA mystuff CASCADE; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBDROP SCHEMA\fR +is fully conforming with the SQL standard, except that the standard only allows one schema to be dropped per command, and apart from the +IF EXISTS +option, which is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +ALTER SCHEMA (\fBALTER_SCHEMA\fR(7)), CREATE SCHEMA (\fBCREATE_SCHEMA\fR(7)) diff --git a/doc/src/sgml/man7/DROP_SEQUENCE.7 b/doc/src/sgml/man7/DROP_SEQUENCE.7 new file mode 100644 index 000000000..01f3bfbf6 --- /dev/null +++ b/doc/src/sgml/man7/DROP_SEQUENCE.7 @@ -0,0 +1,90 @@ +'\" t +.\" Title: DROP SEQUENCE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP SEQUENCE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_SEQUENCE \- remove a sequence +.\" DROP SEQUENCE +.SH "SYNOPSIS" +.sp +.nf +DROP SEQUENCE [ IF EXISTS ] \fIname\fR [, \&.\&.\&.] [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP SEQUENCE\fR +removes sequence number generators\&. A sequence can only be dropped by its owner or a superuser\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the sequence does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of a sequence\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the sequence\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the sequence if any objects depend on it\&. This is the default\&. +.RE +.SH "EXAMPLES" +.PP +To remove the sequence +serial: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP SEQUENCE serial; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBDROP SEQUENCE\fR +conforms to the +SQL +standard, except that the standard only allows one sequence to be dropped per command, and apart from the +IF EXISTS +option, which is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +CREATE SEQUENCE (\fBCREATE_SEQUENCE\fR(7)), ALTER SEQUENCE (\fBALTER_SEQUENCE\fR(7)) diff --git a/doc/src/sgml/man7/DROP_SERVER.7 b/doc/src/sgml/man7/DROP_SERVER.7 new file mode 100644 index 000000000..8923cf658 --- /dev/null +++ b/doc/src/sgml/man7/DROP_SERVER.7 @@ -0,0 +1,89 @@ +'\" t +.\" Title: DROP SERVER +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP SERVER" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_SERVER \- remove a foreign server descriptor +.\" DROP SERVER +.SH "SYNOPSIS" +.sp +.nf +DROP SERVER [ IF EXISTS ] \fIname\fR [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP SERVER\fR +removes an existing foreign server descriptor\&. To execute this command, the current user must be the owner of the server\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the server does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name of an existing server\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the server (such as user mappings)\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the server if any objects depend on it\&. This is the default\&. +.RE +.SH "EXAMPLES" +.PP +Drop a server +foo +if it exists: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP SERVER IF EXISTS foo; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBDROP SERVER\fR +conforms to ISO/IEC 9075\-9 (SQL/MED)\&. The +IF EXISTS +clause is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +CREATE SERVER (\fBCREATE_SERVER\fR(7)), ALTER SERVER (\fBALTER_SERVER\fR(7)) diff --git a/doc/src/sgml/man7/DROP_TABLE.7 b/doc/src/sgml/man7/DROP_TABLE.7 new file mode 100644 index 000000000..3613b16be --- /dev/null +++ b/doc/src/sgml/man7/DROP_TABLE.7 @@ -0,0 +1,98 @@ +'\" t +.\" Title: DROP TABLE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP TABLE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_TABLE \- remove a table +.\" DROP TABLE +.SH "SYNOPSIS" +.sp +.nf +DROP TABLE [ IF EXISTS ] \fIname\fR [, \&.\&.\&.] [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP TABLE\fR +removes tables from the database\&. Only the table owner, the schema owner, and superuser can drop a table\&. To empty a table of rows without destroying the table, use +\fBDELETE\fR(7) +or +\fBTRUNCATE\fR(7)\&. +.PP + +\fBDROP TABLE\fR +always removes any indexes, rules, triggers, and constraints that exist for the target table\&. However, to drop a table that is referenced by a view or a foreign\-key constraint of another table, +CASCADE +must be specified\&. (CASCADE +will remove a dependent view entirely, but in the foreign\-key case it will only remove the foreign\-key constraint, not the other table entirely\&.) +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the table does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of the table to drop\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the table (such as views)\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the table if any objects depend on it\&. This is the default\&. +.RE +.SH "EXAMPLES" +.PP +To destroy two tables, +films +and +distributors: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP TABLE films, distributors; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +This command conforms to the SQL standard, except that the standard only allows one table to be dropped per command, and apart from the +IF EXISTS +option, which is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +ALTER TABLE (\fBALTER_TABLE\fR(7)), CREATE TABLE (\fBCREATE_TABLE\fR(7)) diff --git a/doc/src/sgml/man7/DROP_TABLESPACE.7 b/doc/src/sgml/man7/DROP_TABLESPACE.7 new file mode 100644 index 000000000..dc8eba6ac --- /dev/null +++ b/doc/src/sgml/man7/DROP_TABLESPACE.7 @@ -0,0 +1,88 @@ +'\" t +.\" Title: DROP TABLESPACE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP TABLESPACE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_TABLESPACE \- remove a tablespace +.\" DROP TABLESPACE +.SH "SYNOPSIS" +.sp +.nf +DROP TABLESPACE [ IF EXISTS ] \fIname\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP TABLESPACE\fR +removes a tablespace from the system\&. +.PP +A tablespace can only be dropped by its owner or a superuser\&. The tablespace must be empty of all database objects before it can be dropped\&. It is possible that objects in other databases might still reside in the tablespace even if no objects in the current database are using the tablespace\&. Also, if the tablespace is listed in the +temp_tablespaces +setting of any active session, the +\fBDROP\fR +might fail due to temporary files residing in the tablespace\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the tablespace does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name of a tablespace\&. +.RE +.SH "NOTES" +.PP + +\fBDROP TABLESPACE\fR +cannot be executed inside a transaction block\&. +.SH "EXAMPLES" +.PP +To remove tablespace +mystuff +from the system: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP TABLESPACE mystuff; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBDROP TABLESPACE\fR +is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +CREATE TABLESPACE (\fBCREATE_TABLESPACE\fR(7)), ALTER TABLESPACE (\fBALTER_TABLESPACE\fR(7)) diff --git a/doc/src/sgml/man7/DROP_TEXT_SEARCH_CONFIGURATION.7 b/doc/src/sgml/man7/DROP_TEXT_SEARCH_CONFIGURATION.7 new file mode 100644 index 000000000..680fd2eaa --- /dev/null +++ b/doc/src/sgml/man7/DROP_TEXT_SEARCH_CONFIGURATION.7 @@ -0,0 +1,90 @@ +'\" t +.\" Title: DROP TEXT SEARCH CONFIGURATION +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP TEXT SEARCH CONFIGURATION" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_TEXT_SEARCH_CONFIGURATION \- remove a text search configuration +.\" DROP TEXT SEARCH CONFIGURATION +.SH "SYNOPSIS" +.sp +.nf +DROP TEXT SEARCH CONFIGURATION [ IF EXISTS ] \fIname\fR [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP TEXT SEARCH CONFIGURATION\fR +drops an existing text search configuration\&. To execute this command you must be the owner of the configuration\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the text search configuration does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an existing text search configuration\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the text search configuration\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the text search configuration if any objects depend on it\&. This is the default\&. +.RE +.SH "EXAMPLES" +.PP +Remove the text search configuration +my_english: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP TEXT SEARCH CONFIGURATION my_english; +.fi +.if n \{\ +.RE +.\} +.sp +This command will not succeed if there are any existing indexes that reference the configuration in +\fBto_tsvector\fR +calls\&. Add +CASCADE +to drop such indexes along with the text search configuration\&. +.SH "COMPATIBILITY" +.PP +There is no +\fBDROP TEXT SEARCH CONFIGURATION\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +ALTER TEXT SEARCH CONFIGURATION (\fBALTER_TEXT_SEARCH_CONFIGURATION\fR(7)), CREATE TEXT SEARCH CONFIGURATION (\fBCREATE_TEXT_SEARCH_CONFIGURATION\fR(7)) diff --git a/doc/src/sgml/man7/DROP_TEXT_SEARCH_DICTIONARY.7 b/doc/src/sgml/man7/DROP_TEXT_SEARCH_DICTIONARY.7 new file mode 100644 index 000000000..9749654b9 --- /dev/null +++ b/doc/src/sgml/man7/DROP_TEXT_SEARCH_DICTIONARY.7 @@ -0,0 +1,88 @@ +'\" t +.\" Title: DROP TEXT SEARCH DICTIONARY +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP TEXT SEARCH DICTIONARY" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_TEXT_SEARCH_DICTIONARY \- remove a text search dictionary +.\" DROP TEXT SEARCH DICTIONARY +.SH "SYNOPSIS" +.sp +.nf +DROP TEXT SEARCH DICTIONARY [ IF EXISTS ] \fIname\fR [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP TEXT SEARCH DICTIONARY\fR +drops an existing text search dictionary\&. To execute this command you must be the owner of the dictionary\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the text search dictionary does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an existing text search dictionary\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the text search dictionary\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the text search dictionary if any objects depend on it\&. This is the default\&. +.RE +.SH "EXAMPLES" +.PP +Remove the text search dictionary +english: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP TEXT SEARCH DICTIONARY english; +.fi +.if n \{\ +.RE +.\} +.sp +This command will not succeed if there are any existing text search configurations that use the dictionary\&. Add +CASCADE +to drop such configurations along with the dictionary\&. +.SH "COMPATIBILITY" +.PP +There is no +\fBDROP TEXT SEARCH DICTIONARY\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +ALTER TEXT SEARCH DICTIONARY (\fBALTER_TEXT_SEARCH_DICTIONARY\fR(7)), CREATE TEXT SEARCH DICTIONARY (\fBCREATE_TEXT_SEARCH_DICTIONARY\fR(7)) diff --git a/doc/src/sgml/man7/DROP_TEXT_SEARCH_PARSER.7 b/doc/src/sgml/man7/DROP_TEXT_SEARCH_PARSER.7 new file mode 100644 index 000000000..a4af59b3e --- /dev/null +++ b/doc/src/sgml/man7/DROP_TEXT_SEARCH_PARSER.7 @@ -0,0 +1,88 @@ +'\" t +.\" Title: DROP TEXT SEARCH PARSER +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP TEXT SEARCH PARSER" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_TEXT_SEARCH_PARSER \- remove a text search parser +.\" DROP TEXT SEARCH PARSER +.SH "SYNOPSIS" +.sp +.nf +DROP TEXT SEARCH PARSER [ IF EXISTS ] \fIname\fR [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP TEXT SEARCH PARSER\fR +drops an existing text search parser\&. You must be a superuser to use this command\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the text search parser does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an existing text search parser\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the text search parser\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the text search parser if any objects depend on it\&. This is the default\&. +.RE +.SH "EXAMPLES" +.PP +Remove the text search parser +my_parser: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP TEXT SEARCH PARSER my_parser; +.fi +.if n \{\ +.RE +.\} +.sp +This command will not succeed if there are any existing text search configurations that use the parser\&. Add +CASCADE +to drop such configurations along with the parser\&. +.SH "COMPATIBILITY" +.PP +There is no +\fBDROP TEXT SEARCH PARSER\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +ALTER TEXT SEARCH PARSER (\fBALTER_TEXT_SEARCH_PARSER\fR(7)), CREATE TEXT SEARCH PARSER (\fBCREATE_TEXT_SEARCH_PARSER\fR(7)) diff --git a/doc/src/sgml/man7/DROP_TEXT_SEARCH_TEMPLATE.7 b/doc/src/sgml/man7/DROP_TEXT_SEARCH_TEMPLATE.7 new file mode 100644 index 000000000..62c3bcff7 --- /dev/null +++ b/doc/src/sgml/man7/DROP_TEXT_SEARCH_TEMPLATE.7 @@ -0,0 +1,88 @@ +'\" t +.\" Title: DROP TEXT SEARCH TEMPLATE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP TEXT SEARCH TEMPLATE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_TEXT_SEARCH_TEMPLATE \- remove a text search template +.\" DROP TEXT SEARCH TEMPLATE +.SH "SYNOPSIS" +.sp +.nf +DROP TEXT SEARCH TEMPLATE [ IF EXISTS ] \fIname\fR [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP TEXT SEARCH TEMPLATE\fR +drops an existing text search template\&. You must be a superuser to use this command\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the text search template does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an existing text search template\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the text search template\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the text search template if any objects depend on it\&. This is the default\&. +.RE +.SH "EXAMPLES" +.PP +Remove the text search template +thesaurus: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP TEXT SEARCH TEMPLATE thesaurus; +.fi +.if n \{\ +.RE +.\} +.sp +This command will not succeed if there are any existing text search dictionaries that use the template\&. Add +CASCADE +to drop such dictionaries along with the template\&. +.SH "COMPATIBILITY" +.PP +There is no +\fBDROP TEXT SEARCH TEMPLATE\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +ALTER TEXT SEARCH TEMPLATE (\fBALTER_TEXT_SEARCH_TEMPLATE\fR(7)), CREATE TEXT SEARCH TEMPLATE (\fBCREATE_TEXT_SEARCH_TEMPLATE\fR(7)) diff --git a/doc/src/sgml/man7/DROP_TRIGGER.7 b/doc/src/sgml/man7/DROP_TRIGGER.7 new file mode 100644 index 000000000..dba26b8a2 --- /dev/null +++ b/doc/src/sgml/man7/DROP_TRIGGER.7 @@ -0,0 +1,94 @@ +'\" t +.\" Title: DROP TRIGGER +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP TRIGGER" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_TRIGGER \- remove a trigger +.\" DROP TRIGGER +.SH "SYNOPSIS" +.sp +.nf +DROP TRIGGER [ IF EXISTS ] \fIname\fR ON \fItable_name\fR [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP TRIGGER\fR +removes an existing trigger definition\&. To execute this command, the current user must be the owner of the table for which the trigger is defined\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the trigger does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name of the trigger to remove\&. +.RE +.PP +\fItable_name\fR +.RS 4 +The name (optionally schema\-qualified) of the table for which the trigger is defined\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the trigger\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the trigger if any objects depend on it\&. This is the default\&. +.RE +.SH "EXAMPLES" +.PP +Destroy the trigger +if_dist_exists +on the table +films: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP TRIGGER if_dist_exists ON films; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +The +\fBDROP TRIGGER\fR +statement in +PostgreSQL +is incompatible with the SQL standard\&. In the SQL standard, trigger names are not local to tables, so the command is simply +DROP TRIGGER \fIname\fR\&. +.SH "SEE ALSO" +CREATE TRIGGER (\fBCREATE_TRIGGER\fR(7)) diff --git a/doc/src/sgml/man7/DROP_TYPE.7 b/doc/src/sgml/man7/DROP_TYPE.7 new file mode 100644 index 000000000..a5e3fcd11 --- /dev/null +++ b/doc/src/sgml/man7/DROP_TYPE.7 @@ -0,0 +1,90 @@ +'\" t +.\" Title: DROP TYPE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP TYPE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_TYPE \- remove a data type +.\" DROP TYPE +.SH "SYNOPSIS" +.sp +.nf +DROP TYPE [ IF EXISTS ] \fIname\fR [, \&.\&.\&.] [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP TYPE\fR +removes a user\-defined data type\&. Only the owner of a type can remove it\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the type does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of the data type to remove\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the type (such as table columns, functions, operators)\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the type if any objects depend on it\&. This is the default\&. +.RE +.SH "EXAMPLES" +.PP +To remove the data type +box: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP TYPE box; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +This command is similar to the corresponding command in the SQL standard, apart from the +IF EXISTS +option, which is a +PostgreSQL +extension\&. But note that much of the +\fBCREATE TYPE\fR +command and the data type extension mechanisms in +PostgreSQL +differ from the SQL standard\&. +.SH "SEE ALSO" +ALTER TYPE (\fBALTER_TYPE\fR(7)), CREATE TYPE (\fBCREATE_TYPE\fR(7)) diff --git a/doc/src/sgml/man7/DROP_USER.7 b/doc/src/sgml/man7/DROP_USER.7 new file mode 100644 index 000000000..00d07b8c1 --- /dev/null +++ b/doc/src/sgml/man7/DROP_USER.7 @@ -0,0 +1,52 @@ +'\" t +.\" Title: DROP USER +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP USER" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_USER \- remove a database role +.\" DROP USER +.SH "SYNOPSIS" +.sp +.nf +DROP USER [ IF EXISTS ] \fIname\fR [, \&.\&.\&.] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP USER\fR +is now an alias for +DROP ROLE (\fBDROP_ROLE\fR(7))\&. +.SH "COMPATIBILITY" +.PP +The +\fBDROP USER\fR +statement is a +PostgreSQL +extension\&. The SQL standard leaves the definition of users to the implementation\&. +.SH "SEE ALSO" +DROP ROLE (\fBDROP_ROLE\fR(7)) diff --git a/doc/src/sgml/man7/DROP_USER_MAPPING.7 b/doc/src/sgml/man7/DROP_USER_MAPPING.7 new file mode 100644 index 000000000..aa18ed90b --- /dev/null +++ b/doc/src/sgml/man7/DROP_USER_MAPPING.7 @@ -0,0 +1,95 @@ +'\" t +.\" Title: DROP USER MAPPING +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP USER MAPPING" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_USER_MAPPING \- remove a user mapping for a foreign server +.\" DROP USER MAPPING +.SH "SYNOPSIS" +.sp +.nf +DROP USER MAPPING [ IF EXISTS ] FOR { \fIuser_name\fR | USER | CURRENT_USER | PUBLIC } SERVER \fIserver_name\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP USER MAPPING\fR +removes an existing user mapping from foreign server\&. +.PP +The owner of a foreign server can drop user mappings for that server for any user\&. Also, a user can drop a user mapping for his own user name if +USAGE +privilege on the server has been granted to the user\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the user mapping does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIuser_name\fR +.RS 4 +User name of the mapping\&. +CURRENT_USER +and +USER +match the name of the current user\&. +PUBLIC +is used to match all present and future user names in the system\&. +.RE +.PP +\fIserver_name\fR +.RS 4 +Server name of the user mapping\&. +.RE +.SH "EXAMPLES" +.PP +Drop a user mapping +bob, server +foo +if it exists: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP USER MAPPING IF EXISTS FOR bob SERVER foo; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBDROP USER MAPPING\fR +conforms to ISO/IEC 9075\-9 (SQL/MED)\&. The +IF EXISTS +clause is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +CREATE USER MAPPING (\fBCREATE_USER_MAPPING\fR(7)), ALTER USER MAPPING (\fBALTER_USER_MAPPING\fR(7)) diff --git a/doc/src/sgml/man7/DROP_VIEW.7 b/doc/src/sgml/man7/DROP_VIEW.7 new file mode 100644 index 000000000..2242aa7a4 --- /dev/null +++ b/doc/src/sgml/man7/DROP_VIEW.7 @@ -0,0 +1,86 @@ +'\" t +.\" Title: DROP VIEW +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "DROP VIEW" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +DROP_VIEW \- remove a view +.\" DROP VIEW +.SH "SYNOPSIS" +.sp +.nf +DROP VIEW [ IF EXISTS ] \fIname\fR [, \&.\&.\&.] [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBDROP VIEW\fR +drops an existing view\&. To execute this command you must be the owner of the view\&. +.SH "PARAMETERS" +.PP +IF EXISTS +.RS 4 +Do not throw an error if the view does not exist\&. A notice is issued in this case\&. +.RE +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of the view to remove\&. +.RE +.PP +CASCADE +.RS 4 +Automatically drop objects that depend on the view (such as other views)\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to drop the view if any objects depend on it\&. This is the default\&. +.RE +.SH "EXAMPLES" +.PP +This command will remove the view called +kinds: +.sp +.if n \{\ +.RS 4 +.\} +.nf +DROP VIEW kinds; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +This command conforms to the SQL standard, except that the standard only allows one view to be dropped per command, and apart from the +IF EXISTS +option, which is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +ALTER VIEW (\fBALTER_VIEW\fR(7)), CREATE VIEW (\fBCREATE_VIEW\fR(7)) diff --git a/doc/src/sgml/man7/END.7 b/doc/src/sgml/man7/END.7 new file mode 100644 index 000000000..1ce4ff69d --- /dev/null +++ b/doc/src/sgml/man7/END.7 @@ -0,0 +1,83 @@ +'\" t +.\" Title: END +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "END" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +END \- commit the current transaction +.\" END +.SH "SYNOPSIS" +.sp +.nf +END [ WORK | TRANSACTION ] +.fi +.SH "DESCRIPTION" +.PP + +\fBEND\fR +commits the current transaction\&. All changes made by the transaction become visible to others and are guaranteed to be durable if a crash occurs\&. This command is a +PostgreSQL +extension that is equivalent to +\fBCOMMIT\fR(7)\&. +.SH "PARAMETERS" +.PP +WORK, TRANSACTION +.RS 4 +Optional key words\&. They have no effect\&. +.RE +.SH "NOTES" +.PP +Use +\fBROLLBACK\fR(7) +to abort a transaction\&. +.PP +Issuing +\fBEND\fR +when not inside a transaction does no harm, but it will provoke a warning message\&. +.SH "EXAMPLES" +.PP +To commit the current transaction and make all changes permanent: +.sp +.if n \{\ +.RS 4 +.\} +.nf +END; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBEND\fR +is a +PostgreSQL +extension that provides functionality equivalent to +\fBCOMMIT\fR(7), which is specified in the SQL standard\&. +.SH "SEE ALSO" +\fBBEGIN\fR(7), \fBCOMMIT\fR(7), \fBROLLBACK\fR(7) diff --git a/doc/src/sgml/man7/EXECUTE.7 b/doc/src/sgml/man7/EXECUTE.7 new file mode 100644 index 000000000..119952f24 --- /dev/null +++ b/doc/src/sgml/man7/EXECUTE.7 @@ -0,0 +1,87 @@ +'\" t +.\" Title: EXECUTE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "EXECUTE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +EXECUTE \- execute a prepared statement +.\" EXECUTE +.\" prepared statements: executing +.SH "SYNOPSIS" +.sp +.nf +EXECUTE \fIname\fR [ ( \fIparameter\fR [, \&.\&.\&.] ) ] +.fi +.SH "DESCRIPTION" +.PP + +\fBEXECUTE\fR +is used to execute a previously prepared statement\&. Since prepared statements only exist for the duration of a session, the prepared statement must have been created by a +\fBPREPARE\fR +statement executed earlier in the current session\&. +.PP +If the +\fBPREPARE\fR +statement that created the statement specified some parameters, a compatible set of parameters must be passed to the +\fBEXECUTE\fR +statement, or else an error is raised\&. Note that (unlike functions) prepared statements are not overloaded based on the type or number of their parameters; the name of a prepared statement must be unique within a database session\&. +.PP +For more information on the creation and usage of prepared statements, see +\fBPREPARE\fR(7)\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name of the prepared statement to execute\&. +.RE +.PP +\fIparameter\fR +.RS 4 +The actual value of a parameter to the prepared statement\&. This must be an expression yielding a value that is compatible with the data type of this parameter, as was determined when the prepared statement was created\&. +.RE +.SH "OUTPUTS" +.PP +The command tag returned by +\fBEXECUTE\fR +is that of the prepared statement, and not +EXECUTE\&. +.SH "EXAMPLES" +.PP +Examples are given in the +EXAMPLES +section of the +\fBPREPARE\fR(7) +documentation\&. +.SH "COMPATIBILITY" +.PP +The SQL standard includes an +\fBEXECUTE\fR +statement, but it is only for use in embedded SQL\&. This version of the +\fBEXECUTE\fR +statement also uses a somewhat different syntax\&. +.SH "SEE ALSO" +\fBDEALLOCATE\fR(7), \fBPREPARE\fR(7) diff --git a/doc/src/sgml/man7/EXPLAIN.7 b/doc/src/sgml/man7/EXPLAIN.7 new file mode 100644 index 000000000..566eeb912 --- /dev/null +++ b/doc/src/sgml/man7/EXPLAIN.7 @@ -0,0 +1,391 @@ +'\" t +.\" Title: EXPLAIN +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "EXPLAIN" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +EXPLAIN \- show the execution plan of a statement +.\" EXPLAIN +.\" prepared statements: showing the query plan +.\" cursor: showing the query plan +.SH "SYNOPSIS" +.sp +.nf +EXPLAIN [ ( \fIoption\fR [, \&.\&.\&.] ) ] \fIstatement\fR +EXPLAIN [ ANALYZE ] [ VERBOSE ] \fIstatement\fR + +where \fIoption\fR can be one of: + + ANALYZE [ \fIboolean\fR ] + VERBOSE [ \fIboolean\fR ] + COSTS [ \fIboolean\fR ] + BUFFERS [ \fIboolean\fR ] + TIMING [ \fIboolean\fR ] + FORMAT { TEXT | XML | JSON | YAML } +.fi +.SH "DESCRIPTION" +.PP +This command displays the execution plan that the +PostgreSQL +planner generates for the supplied statement\&. The execution plan shows how the table(s) referenced by the statement will be scanned \(em by plain sequential scan, index scan, etc\&. \(em and if multiple tables are referenced, what join algorithms will be used to bring together the required rows from each input table\&. +.PP +The most critical part of the display is the estimated statement execution cost, which is the planner\*(Aqs guess at how long it will take to run the statement (measured in cost units that are arbitrary, but conventionally mean disk page fetches)\&. Actually two numbers are shown: the start\-up cost before the first row can be returned, and the total cost to return all the rows\&. For most queries the total cost is what matters, but in contexts such as a subquery in +EXISTS, the planner will choose the smallest start\-up cost instead of the smallest total cost (since the executor will stop after getting one row, anyway)\&. Also, if you limit the number of rows to return with a +LIMIT +clause, the planner makes an appropriate interpolation between the endpoint costs to estimate which plan is really the cheapest\&. +.PP +The +ANALYZE +option causes the statement to be actually executed, not only planned\&. Then actual runtime statistics are added to the display, including the total elapsed time expended within each plan node (in milliseconds) and the total number of rows it actually returned\&. This is useful for seeing whether the planner\*(Aqs estimates are close to reality\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBImportant\fR +.ps -1 +.br +.PP +Keep in mind that the statement is actually executed when the +ANALYZE +option is used\&. Although +\fBEXPLAIN\fR +will discard any output that a +\fBSELECT\fR +would return, other side effects of the statement will happen as usual\&. If you wish to use +\fBEXPLAIN ANALYZE\fR +on an +\fBINSERT\fR, +\fBUPDATE\fR, +\fBDELETE\fR, +\fBCREATE TABLE AS\fR, or +\fBEXECUTE\fR +statement without letting the command affect your data, use this approach: +.sp +.if n \{\ +.RS 4 +.\} +.nf +BEGIN; +EXPLAIN ANALYZE \&.\&.\&.; +ROLLBACK; +.fi +.if n \{\ +.RE +.\} +.sp .5v +.RE +.PP +Only the +ANALYZE +and +VERBOSE +options can be specified, and only in that order, without surrounding the option list in parentheses\&. Prior to +PostgreSQL +9\&.0, the unparenthesized syntax was the only one supported\&. It is expected that all new options will be supported only in the parenthesized syntax\&. +.SH "PARAMETERS" +.PP +ANALYZE +.RS 4 +Carry out the command and show actual run times and other statistics\&. This parameter defaults to +FALSE\&. +.RE +.PP +VERBOSE +.RS 4 +Display additional information regarding the plan\&. Specifically, include the output column list for each node in the plan tree, schema\-qualify table and function names, always label variables in expressions with their range table alias, and always print the name of each trigger for which statistics are displayed\&. This parameter defaults to +FALSE\&. +.RE +.PP +COSTS +.RS 4 +Include information on the estimated startup and total cost of each plan node, as well as the estimated number of rows and the estimated width of each row\&. This parameter defaults to +TRUE\&. +.RE +.PP +BUFFERS +.RS 4 +Include information on buffer usage\&. Specifically, include the number of shared blocks hit, read, dirtied, and written, the number of local blocks hit, read, dirtied, and written, and the number of temp blocks read and written\&. A +\fIhit\fR +means that a read was avoided because the block was found already in cache when needed\&. Shared blocks contain data from regular tables and indexes; local blocks contain data from temporary tables and indexes; while temp blocks contain short\-term working data used in sorts, hashes, Materialize plan nodes, and similar cases\&. The number of blocks +\fIdirtied\fR +indicates the number of previously unmodified blocks that were changed by this query; while the number of blocks +\fIwritten\fR +indicates the number of previously\-dirtied blocks evicted from cache by this backend during query processing\&. The number of blocks shown for an upper\-level node includes those used by all its child nodes\&. In text format, only non\-zero values are printed\&. This parameter may only be used when +ANALYZE +is also enabled\&. It defaults to +FALSE\&. +.RE +.PP +TIMING +.RS 4 +Include the actual startup time and time spent in the node in the output\&. The overhead of repeatedly reading the system clock can slow down the query significantly on some systems, so it may be useful to set this parameter to +FALSE +when only actual row counts, and not exact times, are needed\&. This parameter may only be used when +ANALYZE +is also enabled\&. It defaults to +TRUE\&. +.RE +.PP +FORMAT +.RS 4 +Specify the output format, which can be TEXT, XML, JSON, or YAML\&. Non\-text output contains the same information as the text output format, but is easier for programs to parse\&. This parameter defaults to +TEXT\&. +.RE +.PP +\fIboolean\fR +.RS 4 +Specifies whether the selected option should be turned on or off\&. You can write +TRUE, +ON, or +1 +to enable the option, and +FALSE, +OFF, or +0 +to disable it\&. The +\fIboolean\fR +value can also be omitted, in which case +TRUE +is assumed\&. +.RE +.PP +\fIstatement\fR +.RS 4 +Any +\fBSELECT\fR, +\fBINSERT\fR, +\fBUPDATE\fR, +\fBDELETE\fR, +\fBVALUES\fR, +\fBEXECUTE\fR, +\fBDECLARE\fR, or +\fBCREATE TABLE AS\fR +statement, whose execution plan you wish to see\&. +.RE +.SH "OUTPUTS" +.PP +The command\*(Aqs result is a textual description of the plan selected for the +\fIstatement\fR, optionally annotated with execution statistics\&. +Section 14.1, \(lqUsing EXPLAIN\(rq, in the documentation +describes the information provided\&. +.SH "NOTES" +.PP +In order to allow the +PostgreSQL +query planner to make reasonably informed decisions when optimizing queries, the +pg_statistic +data should be up\-to\-date for all tables used in the query\&. Normally the +autovacuum daemon +will take care of that automatically\&. But if a table has recently had substantial changes in its contents, you might need to do a manual +\fBANALYZE\fR(7) +rather than wait for autovacuum to catch up with the changes\&. +.PP +In order to measure the run\-time cost of each node in the execution plan, the current implementation of +\fBEXPLAIN ANALYZE\fR +adds profiling overhead to query execution\&. As a result, running +\fBEXPLAIN ANALYZE\fR +on a query can sometimes take significantly longer than executing the query normally\&. The amount of overhead depends on the nature of the query, as well as the platform being used\&. The worst case occurs for plan nodes that in themselves require very little time per execution, and on machines that have relatively slow operating system calls for obtaining the time of day\&. +.SH "EXAMPLES" +.PP +To show the plan for a simple query on a table with a single +integer +column and 10000 rows: +.sp +.if n \{\ +.RS 4 +.\} +.nf +EXPLAIN SELECT * FROM foo; + + QUERY PLAN +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + Seq Scan on foo (cost=0\&.00\&.\&.155\&.00 rows=10000 width=4) +(1 row) +.fi +.if n \{\ +.RE +.\} +.PP +Here is the same query, with JSON output formatting: +.sp +.if n \{\ +.RS 4 +.\} +.nf +EXPLAIN (FORMAT JSON) SELECT * FROM foo; + QUERY PLAN +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + [ + + { + + "Plan": { + + "Node Type": "Seq Scan",+ + "Relation Name": "foo", + + "Alias": "foo", + + "Startup Cost": 0\&.00, + + "Total Cost": 155\&.00, + + "Plan Rows": 10000, + + "Plan Width": 4 + + } + + } + + ] +(1 row) +.fi +.if n \{\ +.RE +.\} +.PP +If there is an index and we use a query with an indexable +WHERE +condition, +\fBEXPLAIN\fR +might show a different plan: +.sp +.if n \{\ +.RS 4 +.\} +.nf +EXPLAIN SELECT * FROM foo WHERE i = 4; + + QUERY PLAN +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + Index Scan using fi on foo (cost=0\&.00\&.\&.5\&.98 rows=1 width=4) + Index Cond: (i = 4) +(2 rows) +.fi +.if n \{\ +.RE +.\} +.PP +Here is the same query, but in YAML format: +.sp +.if n \{\ +.RS 4 +.\} +.nf +EXPLAIN (FORMAT YAML) SELECT * FROM foo WHERE i=\*(Aq4\*(Aq; + QUERY PLAN +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + \- Plan: + + Node Type: "Index Scan" + + Scan Direction: "Forward"+ + Index Name: "fi" + + Relation Name: "foo" + + Alias: "foo" + + Startup Cost: 0\&.00 + + Total Cost: 5\&.98 + + Plan Rows: 1 + + Plan Width: 4 + + Index Cond: "(i = 4)" +(1 row) +.fi +.if n \{\ +.RE +.\} +.sp +XML format is left as an exercise for the reader\&. +.PP +Here is the same plan with cost estimates suppressed: +.sp +.if n \{\ +.RS 4 +.\} +.nf +EXPLAIN (COSTS FALSE) SELECT * FROM foo WHERE i = 4; + + QUERY PLAN +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + Index Scan using fi on foo + Index Cond: (i = 4) +(2 rows) +.fi +.if n \{\ +.RE +.\} +.PP +Here is an example of a query plan for a query using an aggregate function: +.sp +.if n \{\ +.RS 4 +.\} +.nf +EXPLAIN SELECT sum(i) FROM foo WHERE i < 10; + + QUERY PLAN +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + Aggregate (cost=23\&.93\&.\&.23\&.93 rows=1 width=4) + \-> Index Scan using fi on foo (cost=0\&.00\&.\&.23\&.92 rows=6 width=4) + Index Cond: (i < 10) +(3 rows) +.fi +.if n \{\ +.RE +.\} +.PP +Here is an example of using +\fBEXPLAIN EXECUTE\fR +to display the execution plan for a prepared query: +.sp +.if n \{\ +.RS 4 +.\} +.nf +PREPARE query(int, int) AS SELECT sum(bar) FROM test + WHERE id > $1 AND id < $2 + GROUP BY foo; + +EXPLAIN ANALYZE EXECUTE query(100, 200); + + QUERY PLAN +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + HashAggregate (cost=39\&.53\&.\&.39\&.53 rows=1 width=8) (actual time=0\&.661\&.\&.0\&.672 rows=7 loops=1) + \-> Index Scan using test_pkey on test (cost=0\&.00\&.\&.32\&.97 rows=1311 width=8) (actual time=0\&.050\&.\&.0\&.395 rows=99 loops=1) + Index Cond: ((id > $1) AND (id < $2)) + Total runtime: 0\&.851 ms +(4 rows) +.fi +.if n \{\ +.RE +.\} +.PP +Of course, the specific numbers shown here depend on the actual contents of the tables involved\&. Also note that the numbers, and even the selected query strategy, might vary between +PostgreSQL +releases due to planner improvements\&. In addition, the +\fBANALYZE\fR +command uses random sampling to estimate data statistics; therefore, it is possible for cost estimates to change after a fresh run of +\fBANALYZE\fR, even if the actual distribution of data in the table has not changed\&. +.SH "COMPATIBILITY" +.PP +There is no +\fBEXPLAIN\fR +statement defined in the SQL standard\&. +.SH "SEE ALSO" +\fBANALYZE\fR(7) diff --git a/doc/src/sgml/man7/FETCH.7 b/doc/src/sgml/man7/FETCH.7 new file mode 100644 index 000000000..e4895e5b7 --- /dev/null +++ b/doc/src/sgml/man7/FETCH.7 @@ -0,0 +1,358 @@ +'\" t +.\" Title: FETCH +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "FETCH" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +FETCH \- retrieve rows from a query using a cursor +.\" FETCH +.\" cursor: FETCH +.SH "SYNOPSIS" +.sp +.nf +FETCH [ \fIdirection\fR [ FROM | IN ] ] \fIcursor_name\fR + +where \fIdirection\fR can be empty or one of: + + NEXT + PRIOR + FIRST + LAST + ABSOLUTE \fIcount\fR + RELATIVE \fIcount\fR + \fIcount\fR + ALL + FORWARD + FORWARD \fIcount\fR + FORWARD ALL + BACKWARD + BACKWARD \fIcount\fR + BACKWARD ALL +.fi +.SH "DESCRIPTION" +.PP + +\fBFETCH\fR +retrieves rows using a previously\-created cursor\&. +.PP +A cursor has an associated position, which is used by +\fBFETCH\fR\&. The cursor position can be before the first row of the query result, on any particular row of the result, or after the last row of the result\&. When created, a cursor is positioned before the first row\&. After fetching some rows, the cursor is positioned on the row most recently retrieved\&. If +\fBFETCH\fR +runs off the end of the available rows then the cursor is left positioned after the last row, or before the first row if fetching backward\&. +\fBFETCH ALL\fR +or +\fBFETCH BACKWARD ALL\fR +will always leave the cursor positioned after the last row or before the first row\&. +.PP +The forms +NEXT, +PRIOR, +FIRST, +LAST, +ABSOLUTE, +RELATIVE +fetch a single row after moving the cursor appropriately\&. If there is no such row, an empty result is returned, and the cursor is left positioned before the first row or after the last row as appropriate\&. +.PP +The forms using +FORWARD +and +BACKWARD +retrieve the indicated number of rows moving in the forward or backward direction, leaving the cursor positioned on the last\-returned row (or after/before all rows, if the +\fIcount\fR +exceeds the number of rows available)\&. +.PP + +RELATIVE 0, +FORWARD 0, and +BACKWARD 0 +all request fetching the current row without moving the cursor, that is, re\-fetching the most recently fetched row\&. This will succeed unless the cursor is positioned before the first row or after the last row; in which case, no row is returned\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +.PP +This page describes usage of cursors at the SQL command level\&. If you are trying to use cursors inside a +PL/pgSQL +function, the rules are different \(em see +Section 39.7, \(lqCursors\(rq, in the documentation\&. +.sp .5v +.RE +.SH "PARAMETERS" +.PP +\fIdirection\fR +.RS 4 +\fIdirection\fR +defines the fetch direction and number of rows to fetch\&. It can be one of the following: +.PP +NEXT +.RS 4 +Fetch the next row\&. This is the default if +\fIdirection\fR +is omitted\&. +.RE +.PP +PRIOR +.RS 4 +Fetch the prior row\&. +.RE +.PP +FIRST +.RS 4 +Fetch the first row of the query (same as +ABSOLUTE 1)\&. +.RE +.PP +LAST +.RS 4 +Fetch the last row of the query (same as +ABSOLUTE \-1)\&. +.RE +.PP +ABSOLUTE \fIcount\fR +.RS 4 +Fetch the +\fIcount\fR\*(Aqth row of the query, or the +abs(\fIcount\fR)\*(Aqth row from the end if +\fIcount\fR +is negative\&. Position before first row or after last row if +\fIcount\fR +is out of range; in particular, +ABSOLUTE 0 +positions before the first row\&. +.RE +.PP +RELATIVE \fIcount\fR +.RS 4 +Fetch the +\fIcount\fR\*(Aqth succeeding row, or the +abs(\fIcount\fR)\*(Aqth prior row if +\fIcount\fR +is negative\&. +RELATIVE 0 +re\-fetches the current row, if any\&. +.RE +.PP +\fIcount\fR +.RS 4 +Fetch the next +\fIcount\fR +rows (same as +FORWARD \fIcount\fR)\&. +.RE +.PP +ALL +.RS 4 +Fetch all remaining rows (same as +FORWARD ALL)\&. +.RE +.PP +FORWARD +.RS 4 +Fetch the next row (same as +NEXT)\&. +.RE +.PP +FORWARD \fIcount\fR +.RS 4 +Fetch the next +\fIcount\fR +rows\&. +FORWARD 0 +re\-fetches the current row\&. +.RE +.PP +FORWARD ALL +.RS 4 +Fetch all remaining rows\&. +.RE +.PP +BACKWARD +.RS 4 +Fetch the prior row (same as +PRIOR)\&. +.RE +.PP +BACKWARD \fIcount\fR +.RS 4 +Fetch the prior +\fIcount\fR +rows (scanning backwards)\&. +BACKWARD 0 +re\-fetches the current row\&. +.RE +.PP +BACKWARD ALL +.RS 4 +Fetch all prior rows (scanning backwards)\&. +.RE +.RE +.PP +\fIcount\fR +.RS 4 +\fIcount\fR +is a possibly\-signed integer constant, determining the location or number of rows to fetch\&. For +FORWARD +and +BACKWARD +cases, specifying a negative +\fIcount\fR +is equivalent to changing the sense of +FORWARD +and +BACKWARD\&. +.RE +.PP +\fIcursor_name\fR +.RS 4 +An open cursor\*(Aqs name\&. +.RE +.SH "OUTPUTS" +.PP +On successful completion, a +\fBFETCH\fR +command returns a command tag of the form +.sp +.if n \{\ +.RS 4 +.\} +.nf +FETCH \fIcount\fR +.fi +.if n \{\ +.RE +.\} +.sp +The +\fIcount\fR +is the number of rows fetched (possibly zero)\&. Note that in +psql, the command tag will not actually be displayed, since +psql +displays the fetched rows instead\&. +.SH "NOTES" +.PP +The cursor should be declared with the +SCROLL +option if one intends to use any variants of +\fBFETCH\fR +other than +\fBFETCH NEXT\fR +or +\fBFETCH FORWARD\fR +with a positive count\&. For simple queries +PostgreSQL +will allow backwards fetch from cursors not declared with +SCROLL, but this behavior is best not relied on\&. If the cursor is declared with +NO SCROLL, no backward fetches are allowed\&. +.PP + +ABSOLUTE +fetches are not any faster than navigating to the desired row with a relative move: the underlying implementation must traverse all the intermediate rows anyway\&. Negative absolute fetches are even worse: the query must be read to the end to find the last row, and then traversed backward from there\&. However, rewinding to the start of the query (as with +FETCH ABSOLUTE 0) is fast\&. +.PP + +\fBDECLARE\fR(7) +is used to define a cursor\&. Use +\fBMOVE\fR(7) +to change cursor position without retrieving data\&. +.SH "EXAMPLES" +.PP +The following example traverses a table using a cursor: +.sp +.if n \{\ +.RS 4 +.\} +.nf +BEGIN WORK; + +\-\- Set up a cursor: +DECLARE liahona SCROLL CURSOR FOR SELECT * FROM films; + +\-\- Fetch the first 5 rows in the cursor liahona: +FETCH FORWARD 5 FROM liahona; + + code | title | did | date_prod | kind | len +\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\- + BL101 | The Third Man | 101 | 1949\-12\-23 | Drama | 01:44 + BL102 | The African Queen | 101 | 1951\-08\-11 | Romantic | 01:43 + JL201 | Une Femme est une Femme | 102 | 1961\-03\-12 | Romantic | 01:25 + P_301 | Vertigo | 103 | 1958\-11\-14 | Action | 02:08 + P_302 | Becket | 103 | 1964\-02\-03 | Drama | 02:28 + +\-\- Fetch the previous row: +FETCH PRIOR FROM liahona; + + code | title | did | date_prod | kind | len +\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-+\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\- + P_301 | Vertigo | 103 | 1958\-11\-14 | Action | 02:08 + +\-\- Close the cursor and end the transaction: +CLOSE liahona; +COMMIT WORK; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +The SQL standard defines +\fBFETCH\fR +for use in embedded SQL only\&. The variant of +\fBFETCH\fR +described here returns the data as if it were a +\fBSELECT\fR +result rather than placing it in host variables\&. Other than this point, +\fBFETCH\fR +is fully upward\-compatible with the SQL standard\&. +.PP +The +\fBFETCH\fR +forms involving +FORWARD +and +BACKWARD, as well as the forms +FETCH \fIcount\fR +and +FETCH ALL, in which +FORWARD +is implicit, are +PostgreSQL +extensions\&. +.PP +The SQL standard allows only +FROM +preceding the cursor name; the option to use +IN, or to leave them out altogether, is an extension\&. +.SH "SEE ALSO" +\fBCLOSE\fR(7), \fBDECLARE\fR(7), \fBMOVE\fR(7) diff --git a/doc/src/sgml/man7/GRANT.7 b/doc/src/sgml/man7/GRANT.7 new file mode 100644 index 000000000..0ad4015dc --- /dev/null +++ b/doc/src/sgml/man7/GRANT.7 @@ -0,0 +1,560 @@ +'\" t +.\" Title: GRANT +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "GRANT" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +GRANT \- define access privileges +.\" GRANT +.SH "SYNOPSIS" +.sp +.nf +GRANT { { SELECT | INSERT | UPDATE | DELETE | TRUNCATE | REFERENCES | TRIGGER } + [, \&.\&.\&.] | ALL [ PRIVILEGES ] } + ON { [ TABLE ] \fItable_name\fR [, \&.\&.\&.] + | ALL TABLES IN SCHEMA \fIschema_name\fR [, \&.\&.\&.] } + TO { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] [ WITH GRANT OPTION ] + +GRANT { { SELECT | INSERT | UPDATE | REFERENCES } ( \fIcolumn_name\fR [, \&.\&.\&.] ) + [, \&.\&.\&.] | ALL [ PRIVILEGES ] ( \fIcolumn_name\fR [, \&.\&.\&.] ) } + ON [ TABLE ] \fItable_name\fR [, \&.\&.\&.] + TO { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] [ WITH GRANT OPTION ] + +GRANT { { USAGE | SELECT | UPDATE } + [, \&.\&.\&.] | ALL [ PRIVILEGES ] } + ON { SEQUENCE \fIsequence_name\fR [, \&.\&.\&.] + | ALL SEQUENCES IN SCHEMA \fIschema_name\fR [, \&.\&.\&.] } + TO { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] [ WITH GRANT OPTION ] + +GRANT { { CREATE | CONNECT | TEMPORARY | TEMP } [, \&.\&.\&.] | ALL [ PRIVILEGES ] } + ON DATABASE \fIdatabase_name\fR [, \&.\&.\&.] + TO { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] [ WITH GRANT OPTION ] + +GRANT { USAGE | ALL [ PRIVILEGES ] } + ON DOMAIN \fIdomain_name\fR [, \&.\&.\&.] + TO { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] [ WITH GRANT OPTION ] + +GRANT { USAGE | ALL [ PRIVILEGES ] } + ON FOREIGN DATA WRAPPER \fIfdw_name\fR [, \&.\&.\&.] + TO { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] [ WITH GRANT OPTION ] + +GRANT { USAGE | ALL [ PRIVILEGES ] } + ON FOREIGN SERVER \fIserver_name\fR [, \&.\&.\&.] + TO { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] [ WITH GRANT OPTION ] + +GRANT { EXECUTE | ALL [ PRIVILEGES ] } + ON { FUNCTION \fIfunction_name\fR ( [ [ \fIargmode\fR ] [ \fIarg_name\fR ] \fIarg_type\fR [, \&.\&.\&.] ] ) [, \&.\&.\&.] + | ALL FUNCTIONS IN SCHEMA \fIschema_name\fR [, \&.\&.\&.] } + TO { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] [ WITH GRANT OPTION ] + +GRANT { USAGE | ALL [ PRIVILEGES ] } + ON LANGUAGE \fIlang_name\fR [, \&.\&.\&.] + TO { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] [ WITH GRANT OPTION ] + +GRANT { { SELECT | UPDATE } [, \&.\&.\&.] | ALL [ PRIVILEGES ] } + ON LARGE OBJECT \fIloid\fR [, \&.\&.\&.] + TO { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] [ WITH GRANT OPTION ] + +GRANT { { CREATE | USAGE } [, \&.\&.\&.] | ALL [ PRIVILEGES ] } + ON SCHEMA \fIschema_name\fR [, \&.\&.\&.] + TO { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] [ WITH GRANT OPTION ] + +GRANT { CREATE | ALL [ PRIVILEGES ] } + ON TABLESPACE \fItablespace_name\fR [, \&.\&.\&.] + TO { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] [ WITH GRANT OPTION ] + +GRANT { USAGE | ALL [ PRIVILEGES ] } + ON TYPE \fItype_name\fR [, \&.\&.\&.] + TO { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] [ WITH GRANT OPTION ] + +GRANT \fIrole_name\fR [, \&.\&.\&.] TO \fIrole_name\fR [, \&.\&.\&.] [ WITH ADMIN OPTION ] +.fi +.SH "DESCRIPTION" +.PP +The +\fBGRANT\fR +command has two basic variants: one that grants privileges on a database object (table, column, view, foreign table, sequence, database, foreign\-data wrapper, foreign server, function, procedural language, schema, or tablespace), and one that grants membership in a role\&. These variants are similar in many ways, but they are different enough to be described separately\&. +.SS "GRANT on Database Objects" +.PP +This variant of the +\fBGRANT\fR +command gives specific privileges on a database object to one or more roles\&. These privileges are added to those already granted, if any\&. +.PP +There is also an option to grant privileges on all objects of the same type within one or more schemas\&. This functionality is currently supported only for tables, sequences, and functions (but note that +ALL TABLES +is considered to include views and foreign tables)\&. +.PP +The key word +PUBLIC +indicates that the privileges are to be granted to all roles, including those that might be created later\&. +PUBLIC +can be thought of as an implicitly defined group that always includes all roles\&. Any particular role will have the sum of privileges granted directly to it, privileges granted to any role it is presently a member of, and privileges granted to +PUBLIC\&. +.PP +If +WITH GRANT OPTION +is specified, the recipient of the privilege can in turn grant it to others\&. Without a grant option, the recipient cannot do that\&. Grant options cannot be granted to +PUBLIC\&. +.PP +There is no need to grant privileges to the owner of an object (usually the user that created it), as the owner has all privileges by default\&. (The owner could, however, choose to revoke some of his own privileges for safety\&.) +.PP +The right to drop an object, or to alter its definition in any way, is not treated as a grantable privilege; it is inherent in the owner, and cannot be granted or revoked\&. (However, a similar effect can be obtained by granting or revoking membership in the role that owns the object; see below\&.) The owner implicitly has all grant options for the object, too\&. +.PP +PostgreSQL grants default privileges on some types of objects to +PUBLIC\&. No privileges are granted to +PUBLIC +by default on tables, columns, schemas or tablespaces\&. For other types, the default privileges granted to +PUBLIC +are as follows: +CONNECT +and +CREATE TEMP TABLE +for databases; +EXECUTE +privilege for functions; and +USAGE +privilege for languages\&. The object owner can, of course, +\fBREVOKE\fR +both default and expressly granted privileges\&. (For maximum security, issue the +\fBREVOKE\fR +in the same transaction that creates the object; then there is no window in which another user can use the object\&.) Also, these initial default privilege settings can be changed using the +ALTER DEFAULT PRIVILEGES (\fBALTER_DEFAULT_PRIVILEGES\fR(7)) +command\&. +.PP +The possible privileges are: +.PP +SELECT +.RS 4 +Allows +\fBSELECT\fR(7) +from any column, or the specific columns listed, of the specified table, view, or sequence\&. Also allows the use of +\fBCOPY\fR(7) +TO\&. This privilege is also needed to reference existing column values in +\fBUPDATE\fR(7) +or +\fBDELETE\fR(7)\&. For sequences, this privilege also allows the use of the +\fBcurrval\fR +function\&. For large objects, this privilege allows the object to be read\&. +.RE +.PP +INSERT +.RS 4 +Allows +\fBINSERT\fR(7) +of a new row into the specified table\&. If specific columns are listed, only those columns may be assigned to in the +\fBINSERT\fR +command (other columns will therefore receive default values)\&. Also allows +\fBCOPY\fR(7) +FROM\&. +.RE +.PP +UPDATE +.RS 4 +Allows +\fBUPDATE\fR(7) +of any column, or the specific columns listed, of the specified table\&. (In practice, any nontrivial +\fBUPDATE\fR +command will require +SELECT +privilege as well, since it must reference table columns to determine which rows to update, and/or to compute new values for columns\&.) +SELECT \&.\&.\&. FOR UPDATE +and +SELECT \&.\&.\&. FOR SHARE +also require this privilege on at least one column, in addition to the +SELECT +privilege\&. For sequences, this privilege allows the use of the +\fBnextval\fR +and +\fBsetval\fR +functions\&. For large objects, this privilege allows writing or truncating the object\&. +.RE +.PP +DELETE +.RS 4 +Allows +\fBDELETE\fR(7) +of a row from the specified table\&. (In practice, any nontrivial +\fBDELETE\fR +command will require +SELECT +privilege as well, since it must reference table columns to determine which rows to delete\&.) +.RE +.PP +TRUNCATE +.RS 4 +Allows +\fBTRUNCATE\fR(7) +on the specified table\&. +.RE +.PP +REFERENCES +.RS 4 +To create a foreign key constraint, it is necessary to have this privilege on both the referencing and referenced columns\&. The privilege may be granted for all columns of a table, or just specific columns\&. +.RE +.PP +TRIGGER +.RS 4 +Allows the creation of a trigger on the specified table\&. (See the +CREATE TRIGGER (\fBCREATE_TRIGGER\fR(7)) +statement\&.) +.RE +.PP +CREATE +.RS 4 +For databases, allows new schemas to be created within the database\&. +.sp +For schemas, allows new objects to be created within the schema\&. To rename an existing object, you must own the object +\fIand\fR +have this privilege for the containing schema\&. +.sp +For tablespaces, allows tables, indexes, and temporary files to be created within the tablespace, and allows databases to be created that have the tablespace as their default tablespace\&. (Note that revoking this privilege will not alter the placement of existing objects\&.) +.RE +.PP +CONNECT +.RS 4 +Allows the user to connect to the specified database\&. This privilege is checked at connection startup (in addition to checking any restrictions imposed by +pg_hba\&.conf)\&. +.RE +.PP +TEMPORARY, TEMP +.RS 4 +Allows temporary tables to be created while using the specified database\&. +.RE +.PP +EXECUTE +.RS 4 +Allows the use of the specified function and the use of any operators that are implemented on top of the function\&. This is the only type of privilege that is applicable to functions\&. (This syntax works for aggregate functions, as well\&.) +.RE +.PP +USAGE +.RS 4 +For procedural languages, allows the use of the specified language for the creation of functions in that language\&. This is the only type of privilege that is applicable to procedural languages\&. +.sp +For schemas, allows access to objects contained in the specified schema (assuming that the objects\*(Aq own privilege requirements are also met)\&. Essentially this allows the grantee to +\(lqlook up\(rq +objects within the schema\&. Without this permission, it is still possible to see the object names, e\&.g\&. by querying the system tables\&. Also, after revoking this permission, existing backends might have statements that have previously performed this lookup, so this is not a completely secure way to prevent object access\&. +.sp +For sequences, this privilege allows the use of the +\fBcurrval\fR +and +\fBnextval\fR +functions\&. +.sp +For types and domains, this privilege allow the use of the type or domain in the creation of tables, functions, and other schema objects\&. (Note that it does not control general +\(lqusage\(rq +of the type, such as values of the type appearing in queries\&. It only prevents objects from being created that depend on the type\&. The main purpose of the privilege is controlling which users create dependencies on a type, which could prevent the owner from changing the type later\&.) +.sp +For foreign\-data wrappers, this privilege enables the grantee to create new servers using that foreign\-data wrapper\&. +.sp +For servers, this privilege enables the grantee to create, alter, and drop his own user\*(Aqs user mappings associated with that server\&. Also, it enables the grantee to query the options of the server and associated user mappings\&. +.RE +.PP +ALL PRIVILEGES +.RS 4 +Grant all of the available privileges at once\&. The +PRIVILEGES +key word is optional in +PostgreSQL, though it is required by strict SQL\&. +.RE +The privileges required by other commands are listed on the reference page of the respective command\&. +.SS "GRANT on Roles" +.PP +This variant of the +\fBGRANT\fR +command grants membership in a role to one or more other roles\&. Membership in a role is significant because it conveys the privileges granted to a role to each of its members\&. +.PP +If +WITH ADMIN OPTION +is specified, the member can in turn grant membership in the role to others, and revoke membership in the role as well\&. Without the admin option, ordinary users cannot do that\&. However, database superusers can grant or revoke membership in any role to anyone\&. Roles having +CREATEROLE +privilege can grant or revoke membership in any role that is not a superuser\&. +.PP +Unlike the case with privileges, membership in a role cannot be granted to +PUBLIC\&. Note also that this form of the command does not allow the noise word +GROUP\&. +.SH "NOTES" +.PP +The +\fBREVOKE\fR(7) +command is used to revoke access privileges\&. +.PP +Since +PostgreSQL +8\&.1, the concepts of users and groups have been unified into a single kind of entity called a role\&. It is therefore no longer necessary to use the keyword +GROUP +to identify whether a grantee is a user or a group\&. +GROUP +is still allowed in the command, but it is a noise word\&. +.PP +A user may perform +\fBSELECT\fR, +\fBINSERT\fR, etc\&. on a column if he holds that privilege for either the specific column or its whole table\&. Granting the privilege at the table level and then revoking it for one column will not do what you might wish: the table\-level grant is unaffected by a column\-level operation\&. +.PP +When a non\-owner of an object attempts to +\fBGRANT\fR +privileges on the object, the command will fail outright if the user has no privileges whatsoever on the object\&. As long as some privilege is available, the command will proceed, but it will grant only those privileges for which the user has grant options\&. The +\fBGRANT ALL PRIVILEGES\fR +forms will issue a warning message if no grant options are held, while the other forms will issue a warning if grant options for any of the privileges specifically named in the command are not held\&. (In principle these statements apply to the object owner as well, but since the owner is always treated as holding all grant options, the cases can never occur\&.) +.PP +It should be noted that database superusers can access all objects regardless of object privilege settings\&. This is comparable to the rights of +root +in a Unix system\&. As with +root, it\*(Aqs unwise to operate as a superuser except when absolutely necessary\&. +.PP +If a superuser chooses to issue a +\fBGRANT\fR +or +\fBREVOKE\fR +command, the command is performed as though it were issued by the owner of the affected object\&. In particular, privileges granted via such a command will appear to have been granted by the object owner\&. (For role membership, the membership appears to have been granted by the containing role itself\&.) +.PP + +\fBGRANT\fR +and +\fBREVOKE\fR +can also be done by a role that is not the owner of the affected object, but is a member of the role that owns the object, or is a member of a role that holds privileges +WITH GRANT OPTION +on the object\&. In this case the privileges will be recorded as having been granted by the role that actually owns the object or holds the privileges +WITH GRANT OPTION\&. For example, if table +t1 +is owned by role +g1, of which role +u1 +is a member, then +u1 +can grant privileges on +t1 +to +u2, but those privileges will appear to have been granted directly by +g1\&. Any other member of role +g1 +could revoke them later\&. +.PP +If the role executing +\fBGRANT\fR +holds the required privileges indirectly via more than one role membership path, it is unspecified which containing role will be recorded as having done the grant\&. In such cases it is best practice to use +\fBSET ROLE\fR +to become the specific role you want to do the +\fBGRANT\fR +as\&. +.PP +Granting permission on a table does not automatically extend permissions to any sequences used by the table, including sequences tied to +SERIAL +columns\&. Permissions on sequences must be set separately\&. +.PP +Use +\fBpsql\fR(1)\*(Aqs +\fB\edp\fR +command to obtain information about existing privileges for tables and columns\&. For example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +=> \edp mytable + Access privileges + Schema | Name | Type | Access privileges | Column access privileges +\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + public | mytable | table | miriam=arwdDxt/miriam | col1: + : =r/miriam : miriam_rw=rw/miriam + : admin=arw/miriam +(1 row) +.fi +.if n \{\ +.RE +.\} +.sp +The entries shown by +\fB\edp\fR +are interpreted thus: +.sp +.if n \{\ +.RS 4 +.\} +.nf +rolename=xxxx \-\- privileges granted to a role + =xxxx \-\- privileges granted to PUBLIC + + r \-\- SELECT ("read") + w \-\- UPDATE ("write") + a \-\- INSERT ("append") + d \-\- DELETE + D \-\- TRUNCATE + x \-\- REFERENCES + t \-\- TRIGGER + X \-\- EXECUTE + U \-\- USAGE + C \-\- CREATE + c \-\- CONNECT + T \-\- TEMPORARY + arwdDxt \-\- ALL PRIVILEGES (for tables, varies for other objects) + * \-\- grant option for preceding privilege + + /yyyy \-\- role that granted this privilege +.fi +.if n \{\ +.RE +.\} +.sp +The above example display would be seen by user +miriam +after creating table +mytable +and doing: +.sp +.if n \{\ +.RS 4 +.\} +.nf +GRANT SELECT ON mytable TO PUBLIC; +GRANT SELECT, UPDATE, INSERT ON mytable TO admin; +GRANT SELECT (col1), UPDATE (col1) ON mytable TO miriam_rw; +.fi +.if n \{\ +.RE +.\} +.PP +For non\-table objects there are other +\fB\ed\fR +commands that can display their privileges\&. +.PP +If the +\(lqAccess privileges\(rq +column is empty for a given object, it means the object has default privileges (that is, its privileges column is null)\&. Default privileges always include all privileges for the owner, and can include some privileges for +PUBLIC +depending on the object type, as explained above\&. The first +\fBGRANT\fR +or +\fBREVOKE\fR +on an object will instantiate the default privileges (producing, for example, +{miriam=arwdDxt/miriam}) and then modify them per the specified request\&. Similarly, entries are shown in +\(lqColumn access privileges\(rq +only for columns with nondefault privileges\&. (Note: for this purpose, +\(lqdefault privileges\(rq +always means the built\-in default privileges for the object\*(Aqs type\&. An object whose privileges have been affected by an +\fBALTER DEFAULT PRIVILEGES\fR +command will always be shown with an explicit privilege entry that includes the effects of the +\fBALTER\fR\&.) +.PP +Notice that the owner\*(Aqs implicit grant options are not marked in the access privileges display\&. A +* +will appear only when grant options have been explicitly granted to someone\&. +.SH "EXAMPLES" +.PP +Grant insert privilege to all users on table +films: +.sp +.if n \{\ +.RS 4 +.\} +.nf +GRANT INSERT ON films TO PUBLIC; +.fi +.if n \{\ +.RE +.\} +.PP +Grant all available privileges to user +manuel +on view +kinds: +.sp +.if n \{\ +.RS 4 +.\} +.nf +GRANT ALL PRIVILEGES ON kinds TO manuel; +.fi +.if n \{\ +.RE +.\} +.sp +Note that while the above will indeed grant all privileges if executed by a superuser or the owner of +kinds, when executed by someone else it will only grant those permissions for which the someone else has grant options\&. +.PP +Grant membership in role +admins +to user +joe: +.sp +.if n \{\ +.RS 4 +.\} +.nf +GRANT admins TO joe; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +According to the SQL standard, the +PRIVILEGES +key word in +ALL PRIVILEGES +is required\&. The SQL standard does not support setting the privileges on more than one object per command\&. +.PP + +PostgreSQL +allows an object owner to revoke his own ordinary privileges: for example, a table owner can make the table read\-only to himself by revoking his own +INSERT, +UPDATE, +DELETE, and +TRUNCATE +privileges\&. This is not possible according to the SQL standard\&. The reason is that +PostgreSQL +treats the owner\*(Aqs privileges as having been granted by the owner to himself; therefore he can revoke them too\&. In the SQL standard, the owner\*(Aqs privileges are granted by an assumed entity +\(lq_SYSTEM\(rq\&. Not being +\(lq_SYSTEM\(rq, the owner cannot revoke these rights\&. +.PP +According to the SQL standard, grant options can be granted to +PUBLIC; PostgreSQL only supports granting grant options to roles\&. +.PP +The SQL standard provides for a +USAGE +privilege on other kinds of objects: character sets, collations, translations\&. +.PP +In the SQL standard, sequences only have a +USAGE +privilege, which controls the use of the +NEXT VALUE FOR +expression, which is equivalent to the function +\fBnextval\fR +in PostgreSQL\&. The sequence privileges +SELECT +and +UPDATE +are PostgreSQL extensions\&. The application of the sequence +USAGE +privilege to the +currval +function is also a PostgreSQL extension (as is the function itself)\&. +.PP +Privileges on databases, tablespaces, schemas, and languages are +PostgreSQL +extensions\&. +.SH "SEE ALSO" +\fBREVOKE\fR(7), ALTER DEFAULT PRIVILEGES (\fBALTER_DEFAULT_PRIVILEGES\fR(7)) diff --git a/doc/src/sgml/man7/INSERT.7 b/doc/src/sgml/man7/INSERT.7 new file mode 100644 index 000000000..52ddc8dcc --- /dev/null +++ b/doc/src/sgml/man7/INSERT.7 @@ -0,0 +1,358 @@ +'\" t +.\" Title: INSERT +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "INSERT" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +INSERT \- create new rows in a table +.\" INSERT +.SH "SYNOPSIS" +.sp +.nf +[ WITH [ RECURSIVE ] \fIwith_query\fR [, \&.\&.\&.] ] +INSERT INTO \fItable_name\fR [ ( \fIcolumn_name\fR [, \&.\&.\&.] ) ] + { DEFAULT VALUES | VALUES ( { \fIexpression\fR | DEFAULT } [, \&.\&.\&.] ) [, \&.\&.\&.] | \fIquery\fR } + [ RETURNING * | \fIoutput_expression\fR [ [ AS ] \fIoutput_name\fR ] [, \&.\&.\&.] ] +.fi +.SH "DESCRIPTION" +.PP + +\fBINSERT\fR +inserts new rows into a table\&. One can insert one or more rows specified by value expressions, or zero or more rows resulting from a query\&. +.PP +The target column names can be listed in any order\&. If no list of column names is given at all, the default is all the columns of the table in their declared order; or the first +\fIN\fR +column names, if there are only +\fIN\fR +columns supplied by the +VALUES +clause or +\fIquery\fR\&. The values supplied by the +VALUES +clause or +\fIquery\fR +are associated with the explicit or implicit column list left\-to\-right\&. +.PP +Each column not present in the explicit or implicit column list will be filled with a default value, either its declared default value or null if there is none\&. +.PP +If the expression for any column is not of the correct data type, automatic type conversion will be attempted\&. +.PP +The optional +RETURNING +clause causes +\fBINSERT\fR +to compute and return value(s) based on each row actually inserted\&. This is primarily useful for obtaining values that were supplied by defaults, such as a serial sequence number\&. However, any expression using the table\*(Aqs columns is allowed\&. The syntax of the +RETURNING +list is identical to that of the output list of +\fBSELECT\fR\&. +.PP +You must have +INSERT +privilege on a table in order to insert into it\&. If a column list is specified, you only need +INSERT +privilege on the listed columns\&. Use of the +RETURNING +clause requires +SELECT +privilege on all columns mentioned in +RETURNING\&. If you use the +\fIquery\fR +clause to insert rows from a query, you of course need to have +SELECT +privilege on any table or column used in the query\&. +.SH "PARAMETERS" +.PP +\fIwith_query\fR +.RS 4 +The +WITH +clause allows you to specify one or more subqueries that can be referenced by name in the +\fBINSERT\fR +query\&. See +Section 7.8, \(lqWITH Queries (Common Table Expressions)\(rq, in the documentation +and +\fBSELECT\fR(7) +for details\&. +.sp +It is possible for the +\fIquery\fR +(\fBSELECT\fR +statement) to also contain a +WITH +clause\&. In such a case both sets of +\fIwith_query\fR +can be referenced within the +\fIquery\fR, but the second one takes precedence since it is more closely nested\&. +.RE +.PP +\fItable_name\fR +.RS 4 +The name (optionally schema\-qualified) of an existing table\&. +.RE +.PP +\fIcolumn_name\fR +.RS 4 +The name of a column in the table named by +\fItable_name\fR\&. The column name can be qualified with a subfield name or array subscript, if needed\&. (Inserting into only some fields of a composite column leaves the other fields null\&.) +.RE +.PP +DEFAULT VALUES +.RS 4 +All columns will be filled with their default values\&. +.RE +.PP +\fIexpression\fR +.RS 4 +An expression or value to assign to the corresponding column\&. +.RE +.PP +DEFAULT +.RS 4 +The corresponding column will be filled with its default value\&. +.RE +.PP +\fIquery\fR +.RS 4 +A query (\fBSELECT\fR +statement) that supplies the rows to be inserted\&. Refer to the +\fBSELECT\fR(7) +statement for a description of the syntax\&. +.RE +.PP +\fIoutput_expression\fR +.RS 4 +An expression to be computed and returned by the +\fBINSERT\fR +command after each row is inserted\&. The expression can use any column names of the table named by +\fItable_name\fR\&. Write +* +to return all columns of the inserted row(s)\&. +.RE +.PP +\fIoutput_name\fR +.RS 4 +A name to use for a returned column\&. +.RE +.SH "OUTPUTS" +.PP +On successful completion, an +\fBINSERT\fR +command returns a command tag of the form +.sp +.if n \{\ +.RS 4 +.\} +.nf +INSERT \fIoid\fR \fIcount\fR +.fi +.if n \{\ +.RE +.\} +.sp +The +\fIcount\fR +is the number of rows inserted\&. If +\fIcount\fR +is exactly one, and the target table has OIDs, then +\fIoid\fR +is the +OID +assigned to the inserted row\&. Otherwise +\fIoid\fR +is zero\&. +.PP +If the +\fBINSERT\fR +command contains a +RETURNING +clause, the result will be similar to that of a +\fBSELECT\fR +statement containing the columns and values defined in the +RETURNING +list, computed over the row(s) inserted by the command\&. +.SH "EXAMPLES" +.PP +Insert a single row into table +films: +.sp +.if n \{\ +.RS 4 +.\} +.nf +INSERT INTO films VALUES + (\*(AqUA502\*(Aq, \*(AqBananas\*(Aq, 105, \*(Aq1971\-07\-13\*(Aq, \*(AqComedy\*(Aq, \*(Aq82 minutes\*(Aq); +.fi +.if n \{\ +.RE +.\} +.PP +In this example, the +len +column is omitted and therefore it will have the default value: +.sp +.if n \{\ +.RS 4 +.\} +.nf +INSERT INTO films (code, title, did, date_prod, kind) + VALUES (\*(AqT_601\*(Aq, \*(AqYojimbo\*(Aq, 106, \*(Aq1961\-06\-16\*(Aq, \*(AqDrama\*(Aq); +.fi +.if n \{\ +.RE +.\} +.PP +This example uses the +DEFAULT +clause for the date columns rather than specifying a value: +.sp +.if n \{\ +.RS 4 +.\} +.nf +INSERT INTO films VALUES + (\*(AqUA502\*(Aq, \*(AqBananas\*(Aq, 105, DEFAULT, \*(AqComedy\*(Aq, \*(Aq82 minutes\*(Aq); +INSERT INTO films (code, title, did, date_prod, kind) + VALUES (\*(AqT_601\*(Aq, \*(AqYojimbo\*(Aq, 106, DEFAULT, \*(AqDrama\*(Aq); +.fi +.if n \{\ +.RE +.\} +.PP +To insert a row consisting entirely of default values: +.sp +.if n \{\ +.RS 4 +.\} +.nf +INSERT INTO films DEFAULT VALUES; +.fi +.if n \{\ +.RE +.\} +.PP +To insert multiple rows using the multirow +\fBVALUES\fR +syntax: +.sp +.if n \{\ +.RS 4 +.\} +.nf +INSERT INTO films (code, title, did, date_prod, kind) VALUES + (\*(AqB6717\*(Aq, \*(AqTampopo\*(Aq, 110, \*(Aq1985\-02\-10\*(Aq, \*(AqComedy\*(Aq), + (\*(AqHG120\*(Aq, \*(AqThe Dinner Game\*(Aq, 140, DEFAULT, \*(AqComedy\*(Aq); +.fi +.if n \{\ +.RE +.\} +.PP +This example inserts some rows into table +films +from a table +tmp_films +with the same column layout as +films: +.sp +.if n \{\ +.RS 4 +.\} +.nf +INSERT INTO films SELECT * FROM tmp_films WHERE date_prod < \*(Aq2004\-05\-07\*(Aq; +.fi +.if n \{\ +.RE +.\} +.PP +This example inserts into array columns: +.sp +.if n \{\ +.RS 4 +.\} +.nf +\-\- Create an empty 3x3 gameboard for noughts\-and\-crosses +INSERT INTO tictactoe (game, board[1:3][1:3]) + VALUES (1, \*(Aq{{" "," "," "},{" "," "," "},{" "," "," "}}\*(Aq); +\-\- The subscripts in the above example aren\*(Aqt really needed +INSERT INTO tictactoe (game, board) + VALUES (2, \*(Aq{{X," "," "},{" ",O," "},{" ",X," "}}\*(Aq); +.fi +.if n \{\ +.RE +.\} +.PP +Insert a single row into table +distributors, returning the sequence number generated by the +DEFAULT +clause: +.sp +.if n \{\ +.RS 4 +.\} +.nf +INSERT INTO distributors (did, dname) VALUES (DEFAULT, \*(AqXYZ Widgets\*(Aq) + RETURNING did; +.fi +.if n \{\ +.RE +.\} +.PP +Increment the sales count of the salesperson who manages the account for Acme Corporation, and record the whole updated row along with current time in a log table: +.sp +.if n \{\ +.RS 4 +.\} +.nf +WITH upd AS ( + UPDATE employees SET sales_count = sales_count + 1 WHERE id = + (SELECT sales_person FROM accounts WHERE name = \*(AqAcme Corporation\*(Aq) + RETURNING * +) +INSERT INTO employees_log SELECT *, current_timestamp FROM upd; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBINSERT\fR +conforms to the SQL standard, except that the +RETURNING +clause is a +PostgreSQL +extension, as is the ability to use +WITH +with +\fBINSERT\fR\&. Also, the case in which a column name list is omitted, but not all the columns are filled from the +VALUES +clause or +\fIquery\fR, is disallowed by the standard\&. +.PP +Possible limitations of the +\fIquery\fR +clause are documented under +\fBSELECT\fR(7)\&. diff --git a/doc/src/sgml/man7/LISTEN.7 b/doc/src/sgml/man7/LISTEN.7 new file mode 100644 index 000000000..7192f68a3 --- /dev/null +++ b/doc/src/sgml/man7/LISTEN.7 @@ -0,0 +1,118 @@ +'\" t +.\" Title: LISTEN +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "LISTEN" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +LISTEN \- listen for a notification +.\" LISTEN +.SH "SYNOPSIS" +.sp +.nf +LISTEN \fIchannel\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBLISTEN\fR +registers the current session as a listener on the notification channel named +\fIchannel\fR\&. If the current session is already registered as a listener for this notification channel, nothing is done\&. +.PP +Whenever the command +\fBNOTIFY \fR\fB\fIchannel\fR\fR +is invoked, either by this session or another one connected to the same database, all the sessions currently listening on that notification channel are notified, and each will in turn notify its connected client application\&. +.PP +A session can be unregistered for a given notification channel with the +\fBUNLISTEN\fR +command\&. A session\*(Aqs listen registrations are automatically cleared when the session ends\&. +.PP +The method a client application must use to detect notification events depends on which +PostgreSQL +application programming interface it uses\&. With the +libpq +library, the application issues +\fBLISTEN\fR +as an ordinary SQL command, and then must periodically call the function +\fBPQnotifies\fR +to find out whether any notification events have been received\&. Other interfaces such as +libpgtcl +provide higher\-level methods for handling notify events; indeed, with +libpgtcl +the application programmer should not even issue +\fBLISTEN\fR +or +\fBUNLISTEN\fR +directly\&. See the documentation for the interface you are using for more details\&. +.PP + +\fBNOTIFY\fR(7) +contains a more extensive discussion of the use of +\fBLISTEN\fR +and +\fBNOTIFY\fR\&. +.SH "PARAMETERS" +.PP +\fIchannel\fR +.RS 4 +Name of a notification channel (any identifier)\&. +.RE +.SH "NOTES" +.PP + +\fBLISTEN\fR +takes effect at transaction commit\&. If +\fBLISTEN\fR +or +\fBUNLISTEN\fR +is executed within a transaction that later rolls back, the set of notification channels being listened to is unchanged\&. +.PP +A transaction that has executed +\fBLISTEN\fR +cannot be prepared for two\-phase commit\&. +.SH "EXAMPLES" +.PP +Configure and execute a listen/notify sequence from +psql: +.sp +.if n \{\ +.RS 4 +.\} +.nf +LISTEN virtual; +NOTIFY virtual; +Asynchronous notification "virtual" received from server process with PID 8448\&. +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBLISTEN\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +\fBNOTIFY\fR(7), \fBUNLISTEN\fR(7) diff --git a/doc/src/sgml/man7/LOAD.7 b/doc/src/sgml/man7/LOAD.7 new file mode 100644 index 000000000..9a1be033c --- /dev/null +++ b/doc/src/sgml/man7/LOAD.7 @@ -0,0 +1,73 @@ +'\" t +.\" Title: LOAD +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "LOAD" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +LOAD \- load a shared library file +.\" LOAD +.SH "SYNOPSIS" +.sp +.nf +LOAD \*(Aq\fIfilename\fR\*(Aq +.fi +.SH "DESCRIPTION" +.PP +This command loads a shared library file into the +PostgreSQL +server\*(Aqs address space\&. If the file has been loaded already, the command does nothing\&. Shared library files that contain C functions are automatically loaded whenever one of their functions is called\&. Therefore, an explicit +\fBLOAD\fR +is usually only needed to load a library that modifies the server\*(Aqs behavior through +\(lqhooks\(rq +rather than providing a set of functions\&. +.PP +The file name is specified in the same way as for shared library names in +CREATE FUNCTION (\fBCREATE_FUNCTION\fR(7)); in particular, one can rely on a search path and automatic addition of the system\*(Aqs standard shared library file name extension\&. See +Section 35.9, \(lqC-Language Functions\(rq, in the documentation +for more information on this topic\&. +.\" $libdir/plugins +.PP +Non\-superusers can only apply +\fBLOAD\fR +to library files located in +$libdir/plugins/ +\(em the specified +\fIfilename\fR +must begin with exactly that string\&. (It is the database administrator\*(Aqs responsibility to ensure that only +\(lqsafe\(rq +libraries are installed there\&.) +.SH "COMPATIBILITY" +.PP + +\fBLOAD\fR +is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +.PP + +CREATE FUNCTION (\fBCREATE_FUNCTION\fR(7)) diff --git a/doc/src/sgml/man7/LOCK.7 b/doc/src/sgml/man7/LOCK.7 new file mode 100644 index 000000000..1c94b3071 --- /dev/null +++ b/doc/src/sgml/man7/LOCK.7 @@ -0,0 +1,246 @@ +'\" t +.\" Title: LOCK +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "LOCK" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +LOCK \- lock a table +.\" LOCK +.SH "SYNOPSIS" +.sp +.nf +LOCK [ TABLE ] [ ONLY ] \fIname\fR [ * ] [, \&.\&.\&.] [ IN \fIlockmode\fR MODE ] [ NOWAIT ] + +where \fIlockmode\fR is one of: + + ACCESS SHARE | ROW SHARE | ROW EXCLUSIVE | SHARE UPDATE EXCLUSIVE + | SHARE | SHARE ROW EXCLUSIVE | EXCLUSIVE | ACCESS EXCLUSIVE +.fi +.SH "DESCRIPTION" +.PP + +\fBLOCK TABLE\fR +obtains a table\-level lock, waiting if necessary for any conflicting locks to be released\&. If +NOWAIT +is specified, +\fBLOCK TABLE\fR +does not wait to acquire the desired lock: if it cannot be acquired immediately, the command is aborted and an error is emitted\&. Once obtained, the lock is held for the remainder of the current transaction\&. (There is no +\fBUNLOCK TABLE\fR +command; locks are always released at transaction end\&.) +.PP +When acquiring locks automatically for commands that reference tables, +PostgreSQL +always uses the least restrictive lock mode possible\&. +\fBLOCK TABLE\fR +provides for cases when you might need more restrictive locking\&. For example, suppose an application runs a transaction at the Read Committed isolation level and needs to ensure that data in a table remains stable for the duration of the transaction\&. To achieve this you could obtain +SHARE +lock mode over the table before querying\&. This will prevent concurrent data changes and ensure subsequent reads of the table see a stable view of committed data, because +SHARE +lock mode conflicts with the +ROW EXCLUSIVE +lock acquired by writers, and your +\fBLOCK TABLE \fR\fB\fIname\fR\fR\fB IN SHARE MODE\fR +statement will wait until any concurrent holders of +ROW EXCLUSIVE +mode locks commit or roll back\&. Thus, once you obtain the lock, there are no uncommitted writes outstanding; furthermore none can begin until you release the lock\&. +.PP +To achieve a similar effect when running a transaction at the +REPEATABLE READ +or +SERIALIZABLE +isolation level, you have to execute the +\fBLOCK TABLE\fR +statement before executing any +\fBSELECT\fR +or data modification statement\&. A +REPEATABLE READ +or +SERIALIZABLE +transaction\*(Aqs view of data will be frozen when its first +\fBSELECT\fR +or data modification statement begins\&. A +\fBLOCK TABLE\fR +later in the transaction will still prevent concurrent writes \(em but it won\*(Aqt ensure that what the transaction reads corresponds to the latest committed values\&. +.PP +If a transaction of this sort is going to change the data in the table, then it should use +SHARE ROW EXCLUSIVE +lock mode instead of +SHARE +mode\&. This ensures that only one transaction of this type runs at a time\&. Without this, a deadlock is possible: two transactions might both acquire +SHARE +mode, and then be unable to also acquire +ROW EXCLUSIVE +mode to actually perform their updates\&. (Note that a transaction\*(Aqs own locks never conflict, so a transaction can acquire +ROW EXCLUSIVE +mode when it holds +SHARE +mode \(em but not if anyone else holds +SHARE +mode\&.) To avoid deadlocks, make sure all transactions acquire locks on the same objects in the same order, and if multiple lock modes are involved for a single object, then transactions should always acquire the most restrictive mode first\&. +.PP +More information about the lock modes and locking strategies can be found in +Section 13.3, \(lqExplicit Locking\(rq, in the documentation\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of an existing table to lock\&. If +ONLY +is specified before the table name, only that table is locked\&. If +ONLY +is not specified, the table and all its descendant tables (if any) are locked\&. Optionally, +* +can be specified after the table name to explicitly indicate that descendant tables are included\&. +.sp +The command +LOCK TABLE a, b; +is equivalent to +LOCK TABLE a; LOCK TABLE b;\&. The tables are locked one\-by\-one in the order specified in the +\fBLOCK TABLE\fR +command\&. +.RE +.PP +\fIlockmode\fR +.RS 4 +The lock mode specifies which locks this lock conflicts with\&. Lock modes are described in +Section 13.3, \(lqExplicit Locking\(rq, in the documentation\&. +.sp +If no lock mode is specified, then +ACCESS EXCLUSIVE, the most restrictive mode, is used\&. +.RE +.PP +NOWAIT +.RS 4 +Specifies that +\fBLOCK TABLE\fR +should not wait for any conflicting locks to be released: if the specified lock(s) cannot be acquired immediately without waiting, the transaction is aborted\&. +.RE +.SH "NOTES" +.PP + +LOCK TABLE \&.\&.\&. IN ACCESS SHARE MODE +requires +SELECT +privileges on the target table\&. All other forms of +\fBLOCK\fR +require table\-level +UPDATE, +DELETE, or +TRUNCATE +privileges\&. +.PP + +\fBLOCK TABLE\fR +is useless outside a transaction block: the lock would remain held only to the completion of the statement\&. Therefore +PostgreSQL +reports an error if +\fBLOCK\fR +is used outside a transaction block\&. Use +\fBBEGIN\fR(7) +and +\fBCOMMIT\fR(7) +(or +\fBROLLBACK\fR(7)) to define a transaction block\&. +.PP + +\fBLOCK TABLE\fR +only deals with table\-level locks, and so the mode names involving +ROW +are all misnomers\&. These mode names should generally be read as indicating the intention of the user to acquire row\-level locks within the locked table\&. Also, +ROW EXCLUSIVE +mode is a sharable table lock\&. Keep in mind that all the lock modes have identical semantics so far as +\fBLOCK TABLE\fR +is concerned, differing only in the rules about which modes conflict with which\&. For information on how to acquire an actual row\-level lock, see +Section 13.3.2, \(lqRow-level Locks\(rq, in the documentation +and the +FOR UPDATE/FOR SHARE Clause +in the +\fBSELECT\fR +reference documentation\&. +.SH "EXAMPLES" +.PP +Obtain a +SHARE +lock on a primary key table when going to perform inserts into a foreign key table: +.sp +.if n \{\ +.RS 4 +.\} +.nf +BEGIN WORK; +LOCK TABLE films IN SHARE MODE; +SELECT id FROM films + WHERE name = \*(AqStar Wars: Episode I \- The Phantom Menace\*(Aq; +\-\- Do ROLLBACK if record was not returned +INSERT INTO films_user_comments VALUES + (_id_, \*(AqGREAT! I was waiting for it for so long!\*(Aq); +COMMIT WORK; +.fi +.if n \{\ +.RE +.\} +.PP +Take a +SHARE ROW EXCLUSIVE +lock on a primary key table when going to perform a delete operation: +.sp +.if n \{\ +.RS 4 +.\} +.nf +BEGIN WORK; +LOCK TABLE films IN SHARE ROW EXCLUSIVE MODE; +DELETE FROM films_user_comments WHERE id IN + (SELECT id FROM films WHERE rating < 5); +DELETE FROM films WHERE rating < 5; +COMMIT WORK; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBLOCK TABLE\fR +in the SQL standard, which instead uses +\fBSET TRANSACTION\fR +to specify concurrency levels on transactions\&. +PostgreSQL +supports that too; see +SET TRANSACTION (\fBSET_TRANSACTION\fR(7)) +for details\&. +.PP +Except for +ACCESS SHARE, +ACCESS EXCLUSIVE, and +SHARE UPDATE EXCLUSIVE +lock modes, the +PostgreSQL +lock modes and the +\fBLOCK TABLE\fR +syntax are compatible with those present in +Oracle\&. diff --git a/doc/src/sgml/man7/MOVE.7 b/doc/src/sgml/man7/MOVE.7 new file mode 100644 index 000000000..9528b218b --- /dev/null +++ b/doc/src/sgml/man7/MOVE.7 @@ -0,0 +1,127 @@ +'\" t +.\" Title: MOVE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "MOVE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +MOVE \- position a cursor +.\" MOVE +.\" cursor: MOVE +.SH "SYNOPSIS" +.sp +.nf +MOVE [ \fIdirection\fR [ FROM | IN ] ] \fIcursor_name\fR + +where \fIdirection\fR can be empty or one of: + + NEXT + PRIOR + FIRST + LAST + ABSOLUTE \fIcount\fR + RELATIVE \fIcount\fR + \fIcount\fR + ALL + FORWARD + FORWARD \fIcount\fR + FORWARD ALL + BACKWARD + BACKWARD \fIcount\fR + BACKWARD ALL +.fi +.SH "DESCRIPTION" +.PP + +\fBMOVE\fR +repositions a cursor without retrieving any data\&. +\fBMOVE\fR +works exactly like the +\fBFETCH\fR +command, except it only positions the cursor and does not return rows\&. +.PP +The parameters for the +\fBMOVE\fR +command are identical to those of the +\fBFETCH\fR +command; refer to +\fBFETCH\fR(7) +for details on syntax and usage\&. +.SH "OUTPUTS" +.PP +On successful completion, a +\fBMOVE\fR +command returns a command tag of the form +.sp +.if n \{\ +.RS 4 +.\} +.nf +MOVE \fIcount\fR +.fi +.if n \{\ +.RE +.\} +.sp +The +\fIcount\fR +is the number of rows that a +\fBFETCH\fR +command with the same parameters would have returned (possibly zero)\&. +.SH "EXAMPLES" +.sp +.if n \{\ +.RS 4 +.\} +.nf +BEGIN WORK; +DECLARE liahona CURSOR FOR SELECT * FROM films; + +\-\- Skip the first 5 rows: +MOVE FORWARD 5 IN liahona; +MOVE 5 + +\-\- Fetch the 6th row from the cursor liahona: +FETCH 1 FROM liahona; + code | title | did | date_prod | kind | len +\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-+\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\- + P_303 | 48 Hrs | 103 | 1982\-10\-22 | Action | 01:37 +(1 row) + +\-\- Close the cursor liahona and end the transaction: +CLOSE liahona; +COMMIT WORK; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBMOVE\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +\fBCLOSE\fR(7), \fBDECLARE\fR(7), \fBFETCH\fR(7) diff --git a/doc/src/sgml/man7/NOTIFY.7 b/doc/src/sgml/man7/NOTIFY.7 new file mode 100644 index 000000000..a9029e12c --- /dev/null +++ b/doc/src/sgml/man7/NOTIFY.7 @@ -0,0 +1,152 @@ +'\" t +.\" Title: NOTIFY +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "NOTIFY" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +NOTIFY \- generate a notification +.\" NOTIFY +.SH "SYNOPSIS" +.sp +.nf +NOTIFY \fIchannel\fR [ , \fIpayload\fR ] +.fi +.SH "DESCRIPTION" +.PP +The +\fBNOTIFY\fR +command sends a notification event together with an optional +\(lqpayload\(rq +string to each client application that has previously executed +\fBLISTEN \fR\fB\fIchannel\fR\fR +for the specified channel name in the current database\&. +.PP + +\fBNOTIFY\fR +provides a simple interprocess communication mechanism for a collection of processes accessing the same +PostgreSQL +database\&. A payload string can be sent along with the notification, and higher\-level mechanisms for passing structured data can be built by using tables in the database to pass additional data from notifier to listener(s)\&. +.PP +The information passed to the client for a notification event includes the notification channel name, the notifying session\*(Aqs server process +PID, and the payload string, which is an empty string if it has not been specified\&. +.PP +It is up to the database designer to define the channel names that will be used in a given database and what each one means\&. Commonly, the channel name is the same as the name of some table in the database, and the notify event essentially means, +\(lqI changed this table, take a look at it to see what\*(Aqs new\(rq\&. But no such association is enforced by the +\fBNOTIFY\fR +and +\fBLISTEN\fR +commands\&. For example, a database designer could use several different channel names to signal different sorts of changes to a single table\&. Alternatively, the payload string could be used to differentiate various cases\&. +.PP +When +\fBNOTIFY\fR +is used to signal the occurrence of changes to a particular table, a useful programming technique is to put the +\fBNOTIFY\fR +in a rule that is triggered by table updates\&. In this way, notification happens automatically when the table is changed, and the application programmer cannot accidentally forget to do it\&. +.PP + +\fBNOTIFY\fR +interacts with SQL transactions in some important ways\&. Firstly, if a +\fBNOTIFY\fR +is executed inside a transaction, the notify events are not delivered until and unless the transaction is committed\&. This is appropriate, since if the transaction is aborted, all the commands within it have had no effect, including +\fBNOTIFY\fR\&. But it can be disconcerting if one is expecting the notification events to be delivered immediately\&. Secondly, if a listening session receives a notification signal while it is within a transaction, the notification event will not be delivered to its connected client until just after the transaction is completed (either committed or aborted)\&. Again, the reasoning is that if a notification were delivered within a transaction that was later aborted, one would want the notification to be undone somehow \(em but the server cannot +\(lqtake back\(rq +a notification once it has sent it to the client\&. So notification events are only delivered between transactions\&. The upshot of this is that applications using +\fBNOTIFY\fR +for real\-time signaling should try to keep their transactions short\&. +.PP +If the same channel name is signaled multiple times from the same transaction with identical payload strings, the database server can decide to deliver a single notification only\&. On the other hand, notifications with distinct payload strings will always be delivered as distinct notifications\&. Similarly, notifications from different transactions will never get folded into one notification\&. Except for dropping later instances of duplicate notifications, +\fBNOTIFY\fR +guarantees that notifications from the same transaction get delivered in the order they were sent\&. It is also guaranteed that messages from different transactions are delivered in the order in which the transactions committed\&. +.PP +It is common for a client that executes +\fBNOTIFY\fR +to be listening on the same notification channel itself\&. In that case it will get back a notification event, just like all the other listening sessions\&. Depending on the application logic, this could result in useless work, for example, reading a database table to find the same updates that that session just wrote out\&. It is possible to avoid such extra work by noticing whether the notifying session\*(Aqs server process +PID +(supplied in the notification event message) is the same as one\*(Aqs own session\*(Aqs +PID +(available from +libpq)\&. When they are the same, the notification event is one\*(Aqs own work bouncing back, and can be ignored\&. +.SH "PARAMETERS" +.PP +\fIchannel\fR +.RS 4 +Name of the notification channel to be signaled (any identifier)\&. +.RE +.PP +\fIpayload\fR +.RS 4 +The +\(lqpayload\(rq +string to be communicated along with the notification\&. This must be specified as a simple string literal\&. In the default configuration it must be shorter than 8000 bytes\&. (If binary data or large amounts of information need to be communicated, it\*(Aqs best to put it in a database table and send the key of the record\&.) +.RE +.SH "NOTES" +.PP +There is a queue that holds notifications that have been sent but not yet processed by all listening sessions\&. If this queue becomes full, transactions calling +\fBNOTIFY\fR +will fail at commit\&. The queue is quite large (8GB in a standard installation) and should be sufficiently sized for almost every use case\&. However, no cleanup can take place if a session executes +\fBLISTEN\fR +and then enters a transaction for a very long time\&. Once the queue is half full you will see warnings in the log file pointing you to the session that is preventing cleanup\&. In this case you should make sure that this session ends its current transaction so that cleanup can proceed\&. +.PP +A transaction that has executed +\fBNOTIFY\fR +cannot be prepared for two\-phase commit\&. +.SS "pg_notify" +.\" pg_notify +.PP +To send a notification you can also use the function +\fBpg_notify\fR(text, text)\&. The function takes the channel name as the first argument and the payload as the second\&. The function is much easier to use than the +\fBNOTIFY\fR +command if you need to work with non\-constant channel names and payloads\&. +.SH "EXAMPLES" +.PP +Configure and execute a listen/notify sequence from +psql: +.sp +.if n \{\ +.RS 4 +.\} +.nf +LISTEN virtual; +NOTIFY virtual; +Asynchronous notification "virtual" received from server process with PID 8448\&. +NOTIFY virtual, \*(AqThis is the payload\*(Aq; +Asynchronous notification "virtual" with payload "This is the payload" received from server process with PID 8448\&. + +LISTEN foo; +SELECT pg_notify(\*(Aqfo\*(Aq || \*(Aqo\*(Aq, \*(Aqpay\*(Aq || \*(Aqload\*(Aq); +Asynchronous notification "foo" with payload "payload" received from server process with PID 14728\&. +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBNOTIFY\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +\fBLISTEN\fR(7), \fBUNLISTEN\fR(7) diff --git a/doc/src/sgml/man7/PREPARE.7 b/doc/src/sgml/man7/PREPARE.7 new file mode 100644 index 000000000..5f2e23f58 --- /dev/null +++ b/doc/src/sgml/man7/PREPARE.7 @@ -0,0 +1,153 @@ +'\" t +.\" Title: PREPARE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "PREPARE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +PREPARE \- prepare a statement for execution +.\" PREPARE +.\" prepared statements: creating +.SH "SYNOPSIS" +.sp +.nf +PREPARE \fIname\fR [ ( \fIdata_type\fR [, \&.\&.\&.] ) ] AS \fIstatement\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBPREPARE\fR +creates a prepared statement\&. A prepared statement is a server\-side object that can be used to optimize performance\&. When the +\fBPREPARE\fR +statement is executed, the specified statement is parsed, analyzed, and rewritten\&. When an +\fBEXECUTE\fR +command is subsequently issued, the prepared statement is planned and executed\&. This division of labor avoids repetitive parse analysis work, while allowing the execution plan to depend on the specific parameter values supplied\&. +.PP +Prepared statements can take parameters: values that are substituted into the statement when it is executed\&. When creating the prepared statement, refer to parameters by position, using +$1, +$2, etc\&. A corresponding list of parameter data types can optionally be specified\&. When a parameter\*(Aqs data type is not specified or is declared as +unknown, the type is inferred from the context in which the parameter is used (if possible)\&. When executing the statement, specify the actual values for these parameters in the +\fBEXECUTE\fR +statement\&. Refer to +\fBEXECUTE\fR(7) +for more information about that\&. +.PP +Prepared statements only last for the duration of the current database session\&. When the session ends, the prepared statement is forgotten, so it must be recreated before being used again\&. This also means that a single prepared statement cannot be used by multiple simultaneous database clients; however, each client can create their own prepared statement to use\&. Prepared statements can be manually cleaned up using the +\fBDEALLOCATE\fR(7) +command\&. +.PP +Prepared statements have the largest performance advantage when a single session is being used to execute a large number of similar statements\&. The performance difference will be particularly significant if the statements are complex to plan or rewrite, for example, if the query involves a join of many tables or requires the application of several rules\&. If the statement is relatively simple to plan and rewrite but relatively expensive to execute, the performance advantage of prepared statements will be less noticeable\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +An arbitrary name given to this particular prepared statement\&. It must be unique within a single session and is subsequently used to execute or deallocate a previously prepared statement\&. +.RE +.PP +\fIdata_type\fR +.RS 4 +The data type of a parameter to the prepared statement\&. If the data type of a particular parameter is unspecified or is specified as +unknown, it will be inferred from the context in which the parameter is used\&. To refer to the parameters in the prepared statement itself, use +$1, +$2, etc\&. +.RE +.PP +\fIstatement\fR +.RS 4 +Any +\fBSELECT\fR, +\fBINSERT\fR, +\fBUPDATE\fR, +\fBDELETE\fR, or +\fBVALUES\fR +statement\&. +.RE +.SH "NOTES" +.PP +If a prepared statement is executed enough times, the server may eventually decide to save and re\-use a generic plan rather than re\-planning each time\&. This will occur immediately if the prepared statement has no parameters; otherwise it occurs only if the generic plan appears to be not much more expensive than a plan that depends on specific parameter values\&. Typically, a generic plan will be selected only if the query\*(Aqs performance is estimated to be fairly insensitive to the specific parameter values supplied\&. +.PP +To examine the query plan +PostgreSQL +is using for a prepared statement, use +\fBEXPLAIN\fR(7)\&. If a generic plan is in use, it will contain parameter symbols +$\fIn\fR, while a custom plan will have the current actual parameter values substituted into it\&. +.PP +For more information on query planning and the statistics collected by +PostgreSQL +for that purpose, see the +\fBANALYZE\fR(7) +documentation\&. +.PP +You can see all prepared statements available in the session by querying the +pg_prepared_statements +system view\&. +.SH "EXAMPLES" +.PP +Create a prepared statement for an +\fBINSERT\fR +statement, and then execute it: +.sp +.if n \{\ +.RS 4 +.\} +.nf +PREPARE fooplan (int, text, bool, numeric) AS + INSERT INTO foo VALUES($1, $2, $3, $4); +EXECUTE fooplan(1, \*(AqHunter Valley\*(Aq, \*(Aqt\*(Aq, 200\&.00); +.fi +.if n \{\ +.RE +.\} +.PP +Create a prepared statement for a +\fBSELECT\fR +statement, and then execute it: +.sp +.if n \{\ +.RS 4 +.\} +.nf +PREPARE usrrptplan (int) AS + SELECT * FROM users u, logs l WHERE u\&.usrid=$1 AND u\&.usrid=l\&.usrid + AND l\&.date = $2; +EXECUTE usrrptplan(1, current_date); +.fi +.if n \{\ +.RE +.\} +.sp +Note that the data type of the second parameter is not specified, so it is inferred from the context in which +$2 +is used\&. +.SH "COMPATIBILITY" +.PP +The SQL standard includes a +\fBPREPARE\fR +statement, but it is only for use in embedded SQL\&. This version of the +\fBPREPARE\fR +statement also uses a somewhat different syntax\&. +.SH "SEE ALSO" +\fBDEALLOCATE\fR(7), \fBEXECUTE\fR(7) diff --git a/doc/src/sgml/man7/PREPARE_TRANSACTION.7 b/doc/src/sgml/man7/PREPARE_TRANSACTION.7 new file mode 100644 index 000000000..9eab7a012 --- /dev/null +++ b/doc/src/sgml/man7/PREPARE_TRANSACTION.7 @@ -0,0 +1,151 @@ +'\" t +.\" Title: PREPARE TRANSACTION +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "PREPARE TRANSACTION" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +PREPARE_TRANSACTION \- prepare the current transaction for two\-phase commit +.\" PREPARE TRANSACTION +.SH "SYNOPSIS" +.sp +.nf +PREPARE TRANSACTION \fItransaction_id\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBPREPARE TRANSACTION\fR +prepares the current transaction for two\-phase commit\&. After this command, the transaction is no longer associated with the current session; instead, its state is fully stored on disk, and there is a very high probability that it can be committed successfully, even if a database crash occurs before the commit is requested\&. +.PP +Once prepared, a transaction can later be committed or rolled back with +COMMIT PREPARED (\fBCOMMIT_PREPARED\fR(7)) +or +ROLLBACK PREPARED (\fBROLLBACK_PREPARED\fR(7)), respectively\&. Those commands can be issued from any session, not only the one that executed the original transaction\&. +.PP +From the point of view of the issuing session, +\fBPREPARE TRANSACTION\fR +is not unlike a +\fBROLLBACK\fR +command: after executing it, there is no active current transaction, and the effects of the prepared transaction are no longer visible\&. (The effects will become visible again if the transaction is committed\&.) +.PP +If the +\fBPREPARE TRANSACTION\fR +command fails for any reason, it becomes a +\fBROLLBACK\fR: the current transaction is canceled\&. +.SH "PARAMETERS" +.PP +\fItransaction_id\fR +.RS 4 +An arbitrary identifier that later identifies this transaction for +\fBCOMMIT PREPARED\fR +or +\fBROLLBACK PREPARED\fR\&. The identifier must be written as a string literal, and must be less than 200 bytes long\&. It must not be the same as the identifier used for any currently prepared transaction\&. +.RE +.SH "NOTES" +.PP + +\fBPREPARE TRANSACTION\fR +is not intended for use in applications or interactive sessions\&. Its purpose is to allow an external transaction manager to perform atomic global transactions across multiple databases or other transactional resources\&. Unless you\*(Aqre writing a transaction manager, you probably shouldn\*(Aqt be using +\fBPREPARE TRANSACTION\fR\&. +.PP +This command must be used inside a transaction block\&. Use +\fBBEGIN\fR(7) +to start one\&. +.PP +It is not currently allowed to +\fBPREPARE\fR +a transaction that has executed any operations involving temporary tables, created any cursors +WITH HOLD, or executed +\fBLISTEN\fR +or +\fBUNLISTEN\fR\&. Those features are too tightly tied to the current session to be useful in a transaction to be prepared\&. +.PP +If the transaction modified any run\-time parameters with +\fBSET\fR +(without the +LOCAL +option), those effects persist after +\fBPREPARE TRANSACTION\fR, and will not be affected by any later +\fBCOMMIT PREPARED\fR +or +\fBROLLBACK PREPARED\fR\&. Thus, in this one respect +\fBPREPARE TRANSACTION\fR +acts more like +\fBCOMMIT\fR +than +\fBROLLBACK\fR\&. +.PP +All currently available prepared transactions are listed in the +pg_prepared_xacts +system view\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBCaution\fR +.ps -1 +.br +.PP +It is unwise to leave transactions in the prepared state for a long time\&. This will interfere with the ability of +\fBVACUUM\fR +to reclaim storage, and in extreme cases could cause the database to shut down to prevent transaction ID wraparound (see +Section 23.1.5, \(lqPreventing Transaction ID Wraparound Failures\(rq, in the documentation)\&. Keep in mind also that the transaction continues to hold whatever locks it held\&. The intended usage of the feature is that a prepared transaction will normally be committed or rolled back as soon as an external transaction manager has verified that other databases are also prepared to commit\&. +.PP +If you have not set up an external transaction manager to track prepared transactions and ensure they get closed out promptly, it is best to keep the prepared\-transaction feature disabled by setting +max_prepared_transactions +to zero\&. This will prevent accidental creation of prepared transactions that might then be forgotten and eventually cause problems\&. +.sp .5v +.RE +.SH "EXAMPLES" +.PP +Prepare the current transaction for two\-phase commit, using +foobar +as the transaction identifier: +.sp +.if n \{\ +.RS 4 +.\} +.nf +PREPARE TRANSACTION \*(Aqfoobar\*(Aq; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBPREPARE TRANSACTION\fR +is a +PostgreSQL +extension\&. It is intended for use by external transaction management systems, some of which are covered by standards (such as X/Open XA), but the SQL side of those systems is not standardized\&. +.SH "SEE ALSO" +COMMIT PREPARED (\fBCOMMIT_PREPARED\fR(7)), ROLLBACK PREPARED (\fBROLLBACK_PREPARED\fR(7)) diff --git a/doc/src/sgml/man7/REASSIGN_OWNED.7 b/doc/src/sgml/man7/REASSIGN_OWNED.7 new file mode 100644 index 000000000..fd82c69ce --- /dev/null +++ b/doc/src/sgml/man7/REASSIGN_OWNED.7 @@ -0,0 +1,92 @@ +'\" t +.\" Title: REASSIGN OWNED +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "REASSIGN OWNED" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +REASSIGN_OWNED \- change the ownership of database objects owned by a database role +.\" REASSIGN OWNED +.SH "SYNOPSIS" +.sp +.nf +REASSIGN OWNED BY \fIold_role\fR [, \&.\&.\&.] TO \fInew_role\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBREASSIGN OWNED\fR +instructs the system to change the ownership of the database objects owned by one of the old_roles, to new_role\&. +.SH "PARAMETERS" +.PP +\fIold_role\fR +.RS 4 +The name of a role\&. The ownership of all the objects in the current database owned by this role will be reassigned to +\fInew_role\fR\&. +.RE +.PP +\fInew_role\fR +.RS 4 +The name of the role that will be made the new owner of the affected objects\&. +.RE +.SH "NOTES" +.PP + +\fBREASSIGN OWNED\fR +is often used to prepare for the removal of one or more roles\&. Because +\fBREASSIGN OWNED\fR +only affects the objects in the current database, it is usually necessary to execute this command in each database that contains objects owned by a role that is to be removed\&. +.PP + +\fBREASSIGN OWNED\fR +requires privileges on both the source role(s) and the target role\&. +.PP +The +DROP OWNED (\fBDROP_OWNED\fR(7)) +command is an alternative that drops all the database objects owned by one or more roles\&. Note also that +\fBDROP OWNED\fR +requires privileges only on the source role(s)\&. +.PP +The +\fBREASSIGN OWNED\fR +command does not affect the privileges granted to the old_roles in objects that are not owned by them\&. Use +\fBDROP OWNED\fR +to revoke those privileges\&. +.PP +The +\fBREASSIGN OWNED\fR +command does not affect the ownership of any databases owned by the role\&. Use +ALTER DATABASE (\fBALTER_DATABASE\fR(7)) +to reassign that ownership\&. +.SH "COMPATIBILITY" +.PP +The +\fBREASSIGN OWNED\fR +statement is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +DROP OWNED (\fBDROP_OWNED\fR(7)), DROP ROLE (\fBDROP_ROLE\fR(7)), ALTER DATABASE (\fBALTER_DATABASE\fR(7)) diff --git a/doc/src/sgml/man7/REINDEX.7 b/doc/src/sgml/man7/REINDEX.7 new file mode 100644 index 000000000..f47d15ed0 --- /dev/null +++ b/doc/src/sgml/man7/REINDEX.7 @@ -0,0 +1,253 @@ +'\" t +.\" Title: REINDEX +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "REINDEX" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +REINDEX \- rebuild indexes +.\" REINDEX +.SH "SYNOPSIS" +.sp +.nf +REINDEX { INDEX | TABLE | DATABASE | SYSTEM } \fIname\fR [ FORCE ] +.fi +.SH "DESCRIPTION" +.PP + +\fBREINDEX\fR +rebuilds an index using the data stored in the index\*(Aqs table, replacing the old copy of the index\&. There are several scenarios in which to use +\fBREINDEX\fR: +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +An index has become corrupted, and no longer contains valid data\&. Although in theory this should never happen, in practice indexes can become corrupted due to software bugs or hardware failures\&. +\fBREINDEX\fR +provides a recovery method\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +An index has become +\(lqbloated\(rq, that it is contains many empty or nearly\-empty pages\&. This can occur with B\-tree indexes in +PostgreSQL +under certain uncommon access patterns\&. +\fBREINDEX\fR +provides a way to reduce the space consumption of the index by writing a new version of the index without the dead pages\&. See +Section 23.2, \(lqRoutine Reindexing\(rq, in the documentation +for more information\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +You have altered a storage parameter (such as fillfactor) for an index, and wish to ensure that the change has taken full effect\&. +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +An index build with the +CONCURRENTLY +option failed, leaving an +\(lqinvalid\(rq +index\&. Such indexes are useless but it can be convenient to use +\fBREINDEX\fR +to rebuild them\&. Note that +\fBREINDEX\fR +will not perform a concurrent build\&. To build the index without interfering with production you should drop the index and reissue the +\fBCREATE INDEX CONCURRENTLY\fR +command\&. +.RE +.SH "PARAMETERS" +.PP +INDEX +.RS 4 +Recreate the specified index\&. +.RE +.PP +TABLE +.RS 4 +Recreate all indexes of the specified table\&. If the table has a secondary +\(lqTOAST\(rq +table, that is reindexed as well\&. +.RE +.PP +DATABASE +.RS 4 +Recreate all indexes within the current database\&. Indexes on shared system catalogs are also processed\&. This form of +\fBREINDEX\fR +cannot be executed inside a transaction block\&. +.RE +.PP +SYSTEM +.RS 4 +Recreate all indexes on system catalogs within the current database\&. Indexes on shared system catalogs are included\&. Indexes on user tables are not processed\&. This form of +\fBREINDEX\fR +cannot be executed inside a transaction block\&. +.RE +.PP +\fIname\fR +.RS 4 +The name of the specific index, table, or database to be reindexed\&. Index and table names can be schema\-qualified\&. Presently, +\fBREINDEX DATABASE\fR +and +\fBREINDEX SYSTEM\fR +can only reindex the current database, so their parameter must match the current database\*(Aqs name\&. +.RE +.PP +FORCE +.RS 4 +This is an obsolete option; it is ignored if specified\&. +.RE +.SH "NOTES" +.PP +If you suspect corruption of an index on a user table, you can simply rebuild that index, or all indexes on the table, using +\fBREINDEX INDEX\fR +or +\fBREINDEX TABLE\fR\&. +.PP +Things are more difficult if you need to recover from corruption of an index on a system table\&. In this case it\*(Aqs important for the system to not have used any of the suspect indexes itself\&. (Indeed, in this sort of scenario you might find that server processes are crashing immediately at start\-up, due to reliance on the corrupted indexes\&.) To recover safely, the server must be started with the +\fB\-P\fR +option, which prevents it from using indexes for system catalog lookups\&. +.PP +One way to do this is to shut down the server and start a single\-user +PostgreSQL +server with the +\fB\-P\fR +option included on its command line\&. Then, +\fBREINDEX DATABASE\fR, +\fBREINDEX SYSTEM\fR, +\fBREINDEX TABLE\fR, or +\fBREINDEX INDEX\fR +can be issued, depending on how much you want to reconstruct\&. If in doubt, use +\fBREINDEX SYSTEM\fR +to select reconstruction of all system indexes in the database\&. Then quit the single\-user server session and restart the regular server\&. See the +\fBpostgres\fR(1) +reference page for more information about how to interact with the single\-user server interface\&. +.PP +Alternatively, a regular server session can be started with +\fB\-P\fR +included in its command line options\&. The method for doing this varies across clients, but in all +libpq\-based clients, it is possible to set the +\fBPGOPTIONS\fR +environment variable to +\-P +before starting the client\&. Note that while this method does not require locking out other clients, it might still be wise to prevent other users from connecting to the damaged database until repairs have been completed\&. +.PP + +\fBREINDEX\fR +is similar to a drop and recreate of the index in that the index contents are rebuilt from scratch\&. However, the locking considerations are rather different\&. +\fBREINDEX\fR +locks out writes but not reads of the index\*(Aqs parent table\&. It also takes an exclusive lock on the specific index being processed, which will block reads that attempt to use that index\&. In contrast, +\fBDROP INDEX\fR +momentarily takes exclusive lock on the parent table, blocking both writes and reads\&. The subsequent +\fBCREATE INDEX\fR +locks out writes but not reads; since the index is not there, no read will attempt to use it, meaning that there will be no blocking but reads might be forced into expensive sequential scans\&. +.PP +Reindexing a single index or table requires being the owner of that index or table\&. Reindexing a database requires being the owner of the database (note that the owner can therefore rebuild indexes of tables owned by other users)\&. Of course, superusers can always reindex anything\&. +.PP +Prior to +PostgreSQL +8\&.1, +\fBREINDEX DATABASE\fR +processed only system indexes, not all indexes as one would expect from the name\&. This has been changed to reduce the surprise factor\&. The old behavior is available as +\fBREINDEX SYSTEM\fR\&. +.PP +Prior to +PostgreSQL +7\&.4, +\fBREINDEX TABLE\fR +did not automatically process TOAST tables, and so those had to be reindexed by separate commands\&. This is still possible, but redundant\&. +.SH "EXAMPLES" +.PP +Rebuild a single index: +.sp +.if n \{\ +.RS 4 +.\} +.nf +REINDEX INDEX my_index; +.fi +.if n \{\ +.RE +.\} +.PP +Rebuild all the indexes on the table +my_table: +.sp +.if n \{\ +.RS 4 +.\} +.nf +REINDEX TABLE my_table; +.fi +.if n \{\ +.RE +.\} +.PP +Rebuild all indexes in a particular database, without trusting the system indexes to be valid already: +.sp +.if n \{\ +.RS 4 +.\} +.nf +$ \fBexport PGOPTIONS="\-P"\fR +$ \fBpsql broken_db\fR +\&.\&.\&. +broken_db=> REINDEX DATABASE broken_db; +broken_db=> \eq +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBREINDEX\fR +command in the SQL standard\&. diff --git a/doc/src/sgml/man7/RELEASE_SAVEPOINT.7 b/doc/src/sgml/man7/RELEASE_SAVEPOINT.7 new file mode 100644 index 000000000..6fae8eba4 --- /dev/null +++ b/doc/src/sgml/man7/RELEASE_SAVEPOINT.7 @@ -0,0 +1,94 @@ +'\" t +.\" Title: RELEASE SAVEPOINT +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "RELEASE SAVEPOINT" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +RELEASE_SAVEPOINT \- destroy a previously defined savepoint +.\" RELEASE SAVEPOINT +.\" savepoints: releasing +.SH "SYNOPSIS" +.sp +.nf +RELEASE [ SAVEPOINT ] \fIsavepoint_name\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBRELEASE SAVEPOINT\fR +destroys a savepoint previously defined in the current transaction\&. +.PP +Destroying a savepoint makes it unavailable as a rollback point, but it has no other user visible behavior\&. It does not undo the effects of commands executed after the savepoint was established\&. (To do that, see +ROLLBACK TO SAVEPOINT (\fBROLLBACK_TO_SAVEPOINT\fR(7))\&.) Destroying a savepoint when it is no longer needed allows the system to reclaim some resources earlier than transaction end\&. +.PP + +\fBRELEASE SAVEPOINT\fR +also destroys all savepoints that were established after the named savepoint was established\&. +.SH "PARAMETERS" +.PP +\fIsavepoint_name\fR +.RS 4 +The name of the savepoint to destroy\&. +.RE +.SH "NOTES" +.PP +Specifying a savepoint name that was not previously defined is an error\&. +.PP +It is not possible to release a savepoint when the transaction is in an aborted state\&. +.PP +If multiple savepoints have the same name, only the one that was most recently defined is released\&. +.SH "EXAMPLES" +.PP +To establish and later destroy a savepoint: +.sp +.if n \{\ +.RS 4 +.\} +.nf +BEGIN; + INSERT INTO table1 VALUES (3); + SAVEPOINT my_savepoint; + INSERT INTO table1 VALUES (4); + RELEASE SAVEPOINT my_savepoint; +COMMIT; +.fi +.if n \{\ +.RE +.\} +.sp +The above transaction will insert both 3 and 4\&. +.SH "COMPATIBILITY" +.PP +This command conforms to the +SQL +standard\&. The standard specifies that the key word +SAVEPOINT +is mandatory, but +PostgreSQL +allows it to be omitted\&. +.SH "SEE ALSO" +\fBBEGIN\fR(7), \fBCOMMIT\fR(7), \fBROLLBACK\fR(7), ROLLBACK TO SAVEPOINT (\fBROLLBACK_TO_SAVEPOINT\fR(7)), \fBSAVEPOINT\fR(7) diff --git a/doc/src/sgml/man7/RESET.7 b/doc/src/sgml/man7/RESET.7 new file mode 100644 index 000000000..2b7b2c6d9 --- /dev/null +++ b/doc/src/sgml/man7/RESET.7 @@ -0,0 +1,111 @@ +'\" t +.\" Title: RESET +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "RESET" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +RESET \- restore the value of a run\-time parameter to the default value +.\" RESET +.SH "SYNOPSIS" +.sp +.nf +RESET \fIconfiguration_parameter\fR +RESET ALL +.fi +.SH "DESCRIPTION" +.PP + +\fBRESET\fR +restores run\-time parameters to their default values\&. +\fBRESET\fR +is an alternative spelling for +.sp +.if n \{\ +.RS 4 +.\} +.nf +SET \fIconfiguration_parameter\fR TO DEFAULT +.fi +.if n \{\ +.RE +.\} +.sp + +Refer to +\fBSET\fR(7) +for details\&. +.PP +The default value is defined as the value that the parameter would have had, if no +\fBSET\fR +had ever been issued for it in the current session\&. The actual source of this value might be a compiled\-in default, the configuration file, command\-line options, or per\-database or per\-user default settings\&. This is subtly different from defining it as +\(lqthe value that the parameter had at session start\(rq, because if the value came from the configuration file, it will be reset to whatever is specified by the configuration file now\&. See +Chapter 18, Server Configuration, in the documentation +for details\&. +.PP +The transactional behavior of +\fBRESET\fR +is the same as +\fBSET\fR: its effects will be undone by transaction rollback\&. +.SH "PARAMETERS" +.PP +\fIconfiguration_parameter\fR +.RS 4 +Name of a settable run\-time parameter\&. Available parameters are documented in +Chapter 18, Server Configuration, in the documentation +and on the +\fBSET\fR(7) +reference page\&. +.RE +.PP +ALL +.RS 4 +Resets all settable run\-time parameters to default values\&. +.RE +.SH "EXAMPLES" +.PP +Set the +\fItimezone\fR +configuration variable to its default value: +.sp +.if n \{\ +.RS 4 +.\} +.nf +RESET timezone; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBRESET\fR +is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +\fBSET\fR(7), \fBSHOW\fR(7) diff --git a/doc/src/sgml/man7/REVOKE.7 b/doc/src/sgml/man7/REVOKE.7 new file mode 100644 index 000000000..69ba32524 --- /dev/null +++ b/doc/src/sgml/man7/REVOKE.7 @@ -0,0 +1,289 @@ +'\" t +.\" Title: REVOKE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "REVOKE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +REVOKE \- remove access privileges +.\" REVOKE +.SH "SYNOPSIS" +.sp +.nf +REVOKE [ GRANT OPTION FOR ] + { { SELECT | INSERT | UPDATE | DELETE | TRUNCATE | REFERENCES | TRIGGER } + [, \&.\&.\&.] | ALL [ PRIVILEGES ] } + ON { [ TABLE ] \fItable_name\fR [, \&.\&.\&.] + | ALL TABLES IN SCHEMA \fIschema_name\fR [, \&.\&.\&.] } + FROM { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] + [ CASCADE | RESTRICT ] + +REVOKE [ GRANT OPTION FOR ] + { { SELECT | INSERT | UPDATE | REFERENCES } ( \fIcolumn_name\fR [, \&.\&.\&.] ) + [, \&.\&.\&.] | ALL [ PRIVILEGES ] ( \fIcolumn_name\fR [, \&.\&.\&.] ) } + ON [ TABLE ] \fItable_name\fR [, \&.\&.\&.] + FROM { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] + [ CASCADE | RESTRICT ] + +REVOKE [ GRANT OPTION FOR ] + { { USAGE | SELECT | UPDATE } + [, \&.\&.\&.] | ALL [ PRIVILEGES ] } + ON { SEQUENCE \fIsequence_name\fR [, \&.\&.\&.] + | ALL SEQUENCES IN SCHEMA \fIschema_name\fR [, \&.\&.\&.] } + FROM { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] + [ CASCADE | RESTRICT ] + +REVOKE [ GRANT OPTION FOR ] + { { CREATE | CONNECT | TEMPORARY | TEMP } [, \&.\&.\&.] | ALL [ PRIVILEGES ] } + ON DATABASE \fIdatabase_name\fR [, \&.\&.\&.] + FROM { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] + [ CASCADE | RESTRICT ] + +REVOKE [ GRANT OPTION FOR ] + { USAGE | ALL [ PRIVILEGES ] } + ON DOMAIN \fIdomain_name\fR [, \&.\&.\&.] + FROM { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] + [ CASCADE | RESTRICT ] + +REVOKE [ GRANT OPTION FOR ] + { USAGE | ALL [ PRIVILEGES ] } + ON FOREIGN DATA WRAPPER \fIfdw_name\fR [, \&.\&.\&.] + FROM { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] + [ CASCADE | RESTRICT ] + +REVOKE [ GRANT OPTION FOR ] + { USAGE | ALL [ PRIVILEGES ] } + ON FOREIGN SERVER \fIserver_name\fR [, \&.\&.\&.] + FROM { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] + [ CASCADE | RESTRICT ] + +REVOKE [ GRANT OPTION FOR ] + { EXECUTE | ALL [ PRIVILEGES ] } + ON { FUNCTION \fIfunction_name\fR ( [ [ \fIargmode\fR ] [ \fIarg_name\fR ] \fIarg_type\fR [, \&.\&.\&.] ] ) [, \&.\&.\&.] + | ALL FUNCTIONS IN SCHEMA \fIschema_name\fR [, \&.\&.\&.] } + FROM { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] + [ CASCADE | RESTRICT ] + +REVOKE [ GRANT OPTION FOR ] + { USAGE | ALL [ PRIVILEGES ] } + ON LANGUAGE \fIlang_name\fR [, \&.\&.\&.] + FROM { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] + [ CASCADE | RESTRICT ] + +REVOKE [ GRANT OPTION FOR ] + { { SELECT | UPDATE } [, \&.\&.\&.] | ALL [ PRIVILEGES ] } + ON LARGE OBJECT \fIloid\fR [, \&.\&.\&.] + FROM { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] + [ CASCADE | RESTRICT ] + +REVOKE [ GRANT OPTION FOR ] + { { CREATE | USAGE } [, \&.\&.\&.] | ALL [ PRIVILEGES ] } + ON SCHEMA \fIschema_name\fR [, \&.\&.\&.] + FROM { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] + [ CASCADE | RESTRICT ] + +REVOKE [ GRANT OPTION FOR ] + { CREATE | ALL [ PRIVILEGES ] } + ON TABLESPACE \fItablespace_name\fR [, \&.\&.\&.] + FROM { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] + [ CASCADE | RESTRICT ] + +REVOKE [ GRANT OPTION FOR ] + { USAGE | ALL [ PRIVILEGES ] } + ON TYPE \fItype_name\fR [, \&.\&.\&.] + FROM { [ GROUP ] \fIrole_name\fR | PUBLIC } [, \&.\&.\&.] + [ CASCADE | RESTRICT ] + +REVOKE [ ADMIN OPTION FOR ] + \fIrole_name\fR [, \&.\&.\&.] FROM \fIrole_name\fR [, \&.\&.\&.] + [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP +The +\fBREVOKE\fR +command revokes previously granted privileges from one or more roles\&. The key word +PUBLIC +refers to the implicitly defined group of all roles\&. +.PP +See the description of the +\fBGRANT\fR(7) +command for the meaning of the privilege types\&. +.PP +Note that any particular role will have the sum of privileges granted directly to it, privileges granted to any role it is presently a member of, and privileges granted to +PUBLIC\&. Thus, for example, revoking +SELECT +privilege from +PUBLIC +does not necessarily mean that all roles have lost +SELECT +privilege on the object: those who have it granted directly or via another role will still have it\&. Similarly, revoking +SELECT +from a user might not prevent that user from using +SELECT +if +PUBLIC +or another membership role still has +SELECT +rights\&. +.PP +If +GRANT OPTION FOR +is specified, only the grant option for the privilege is revoked, not the privilege itself\&. Otherwise, both the privilege and the grant option are revoked\&. +.PP +If a user holds a privilege with grant option and has granted it to other users then the privileges held by those other users are called dependent privileges\&. If the privilege or the grant option held by the first user is being revoked and dependent privileges exist, those dependent privileges are also revoked if +CASCADE +is specified; if it is not, the revoke action will fail\&. This recursive revocation only affects privileges that were granted through a chain of users that is traceable to the user that is the subject of this +REVOKE +command\&. Thus, the affected users might effectively keep the privilege if it was also granted through other users\&. +.PP +When revoking privileges on a table, the corresponding column privileges (if any) are automatically revoked on each column of the table, as well\&. On the other hand, if a role has been granted privileges on a table, then revoking the same privileges from individual columns will have no effect\&. +.PP +When revoking membership in a role, +GRANT OPTION +is instead called +ADMIN OPTION, but the behavior is similar\&. Note also that this form of the command does not allow the noise word +GROUP\&. +.SH "NOTES" +.PP +Use +\fBpsql\fR(1)\*(Aqs +\fB\edp\fR +command to display the privileges granted on existing tables and columns\&. See +\fBGRANT\fR(7) +for information about the format\&. For non\-table objects there are other +\fB\ed\fR +commands that can display their privileges\&. +.PP +A user can only revoke privileges that were granted directly by that user\&. If, for example, user A has granted a privilege with grant option to user B, and user B has in turned granted it to user C, then user A cannot revoke the privilege directly from C\&. Instead, user A could revoke the grant option from user B and use the +CASCADE +option so that the privilege is in turn revoked from user C\&. For another example, if both A and B have granted the same privilege to C, A can revoke his own grant but not B\*(Aqs grant, so C will still effectively have the privilege\&. +.PP +When a non\-owner of an object attempts to +\fBREVOKE\fR +privileges on the object, the command will fail outright if the user has no privileges whatsoever on the object\&. As long as some privilege is available, the command will proceed, but it will revoke only those privileges for which the user has grant options\&. The +\fBREVOKE ALL PRIVILEGES\fR +forms will issue a warning message if no grant options are held, while the other forms will issue a warning if grant options for any of the privileges specifically named in the command are not held\&. (In principle these statements apply to the object owner as well, but since the owner is always treated as holding all grant options, the cases can never occur\&.) +.PP +If a superuser chooses to issue a +\fBGRANT\fR +or +\fBREVOKE\fR +command, the command is performed as though it were issued by the owner of the affected object\&. Since all privileges ultimately come from the object owner (possibly indirectly via chains of grant options), it is possible for a superuser to revoke all privileges, but this might require use of +CASCADE +as stated above\&. +.PP + +\fBREVOKE\fR +can also be done by a role that is not the owner of the affected object, but is a member of the role that owns the object, or is a member of a role that holds privileges +WITH GRANT OPTION +on the object\&. In this case the command is performed as though it were issued by the containing role that actually owns the object or holds the privileges +WITH GRANT OPTION\&. For example, if table +t1 +is owned by role +g1, of which role +u1 +is a member, then +u1 +can revoke privileges on +t1 +that are recorded as being granted by +g1\&. This would include grants made by +u1 +as well as by other members of role +g1\&. +.PP +If the role executing +\fBREVOKE\fR +holds privileges indirectly via more than one role membership path, it is unspecified which containing role will be used to perform the command\&. In such cases it is best practice to use +\fBSET ROLE\fR +to become the specific role you want to do the +\fBREVOKE\fR +as\&. Failure to do so might lead to revoking privileges other than the ones you intended, or not revoking anything at all\&. +.SH "EXAMPLES" +.PP +Revoke insert privilege for the public on table +films: +.sp +.if n \{\ +.RS 4 +.\} +.nf +REVOKE INSERT ON films FROM PUBLIC; +.fi +.if n \{\ +.RE +.\} +.PP +Revoke all privileges from user +manuel +on view +kinds: +.sp +.if n \{\ +.RS 4 +.\} +.nf +REVOKE ALL PRIVILEGES ON kinds FROM manuel; +.fi +.if n \{\ +.RE +.\} +.sp +Note that this actually means +\(lqrevoke all privileges that I granted\(rq\&. +.PP +Revoke membership in role +admins +from user +joe: +.sp +.if n \{\ +.RS 4 +.\} +.nf +REVOKE admins FROM joe; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +The compatibility notes of the +\fBGRANT\fR(7) +command apply analogously to +\fBREVOKE\fR\&. The keyword +RESTRICT +or +CASCADE +is required according to the standard, but +PostgreSQL +assumes +RESTRICT +by default\&. +.SH "SEE ALSO" +.sp +\fBGRANT\fR(7) diff --git a/doc/src/sgml/man7/ROLLBACK.7 b/doc/src/sgml/man7/ROLLBACK.7 new file mode 100644 index 000000000..e70e4674b --- /dev/null +++ b/doc/src/sgml/man7/ROLLBACK.7 @@ -0,0 +1,78 @@ +'\" t +.\" Title: ROLLBACK +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ROLLBACK" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ROLLBACK \- abort the current transaction +.\" ROLLBACK +.SH "SYNOPSIS" +.sp +.nf +ROLLBACK [ WORK | TRANSACTION ] +.fi +.SH "DESCRIPTION" +.PP + +\fBROLLBACK\fR +rolls back the current transaction and causes all the updates made by the transaction to be discarded\&. +.SH "PARAMETERS" +.PP +WORK, TRANSACTION +.RS 4 +Optional key words\&. They have no effect\&. +.RE +.SH "NOTES" +.PP +Use +\fBCOMMIT\fR(7) +to successfully terminate a transaction\&. +.PP +Issuing +\fBROLLBACK\fR +when not inside a transaction does no harm, but it will provoke a warning message\&. +.SH "EXAMPLES" +.PP +To abort all changes: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ROLLBACK; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +The SQL standard only specifies the two forms +ROLLBACK +and +ROLLBACK WORK\&. Otherwise, this command is fully conforming\&. +.SH "SEE ALSO" +\fBBEGIN\fR(7), \fBCOMMIT\fR(7), ROLLBACK TO SAVEPOINT (\fBROLLBACK_TO_SAVEPOINT\fR(7)) diff --git a/doc/src/sgml/man7/ROLLBACK_PREPARED.7 b/doc/src/sgml/man7/ROLLBACK_PREPARED.7 new file mode 100644 index 000000000..afa369ef6 --- /dev/null +++ b/doc/src/sgml/man7/ROLLBACK_PREPARED.7 @@ -0,0 +1,80 @@ +'\" t +.\" Title: ROLLBACK PREPARED +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ROLLBACK PREPARED" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ROLLBACK_PREPARED \- cancel a transaction that was earlier prepared for two\-phase commit +.\" ROLLBACK PREPARED +.SH "SYNOPSIS" +.sp +.nf +ROLLBACK PREPARED \fItransaction_id\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBROLLBACK PREPARED\fR +rolls back a transaction that is in prepared state\&. +.SH "PARAMETERS" +.PP +\fItransaction_id\fR +.RS 4 +The transaction identifier of the transaction that is to be rolled back\&. +.RE +.SH "NOTES" +.PP +To roll back a prepared transaction, you must be either the same user that executed the transaction originally, or a superuser\&. But you do not have to be in the same session that executed the transaction\&. +.PP +This command cannot be executed inside a transaction block\&. The prepared transaction is rolled back immediately\&. +.PP +All currently available prepared transactions are listed in the +pg_prepared_xacts +system view\&. +.SH "EXAMPLES" +.PP +Roll back the transaction identified by the transaction identifier +foobar: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ROLLBACK PREPARED \*(Aqfoobar\*(Aq; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +\fBROLLBACK PREPARED\fR +is a +PostgreSQL +extension\&. It is intended for use by external transaction management systems, some of which are covered by standards (such as X/Open XA), but the SQL side of those systems is not standardized\&. +.SH "SEE ALSO" +PREPARE TRANSACTION (\fBPREPARE_TRANSACTION\fR(7)), COMMIT PREPARED (\fBCOMMIT_PREPARED\fR(7)) diff --git a/doc/src/sgml/man7/ROLLBACK_TO_SAVEPOINT.7 b/doc/src/sgml/man7/ROLLBACK_TO_SAVEPOINT.7 new file mode 100644 index 000000000..47dc6bcfe --- /dev/null +++ b/doc/src/sgml/man7/ROLLBACK_TO_SAVEPOINT.7 @@ -0,0 +1,135 @@ +'\" t +.\" Title: ROLLBACK TO SAVEPOINT +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "ROLLBACK TO SAVEPOINT" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +ROLLBACK_TO_SAVEPOINT \- roll back to a savepoint +.\" ROLLBACK TO SAVEPOINT +.\" savepoints: rolling back +.SH "SYNOPSIS" +.sp +.nf +ROLLBACK [ WORK | TRANSACTION ] TO [ SAVEPOINT ] \fIsavepoint_name\fR +.fi +.SH "DESCRIPTION" +.PP +Roll back all commands that were executed after the savepoint was established\&. The savepoint remains valid and can be rolled back to again later, if needed\&. +.PP + +\fBROLLBACK TO SAVEPOINT\fR +implicitly destroys all savepoints that were established after the named savepoint\&. +.SH "PARAMETERS" +.PP +\fIsavepoint_name\fR +.RS 4 +The savepoint to roll back to\&. +.RE +.SH "NOTES" +.PP +Use +RELEASE SAVEPOINT (\fBRELEASE_SAVEPOINT\fR(7)) +to destroy a savepoint without discarding the effects of commands executed after it was established\&. +.PP +Specifying a savepoint name that has not been established is an error\&. +.PP +Cursors have somewhat non\-transactional behavior with respect to savepoints\&. Any cursor that is opened inside a savepoint will be closed when the savepoint is rolled back\&. If a previously opened cursor is affected by a +\fBFETCH\fR +or +\fBMOVE\fR +command inside a savepoint that is later rolled back, the cursor remains at the position that +\fBFETCH\fR +left it pointing to (that is, the cursor motion caused by +\fBFETCH\fR +is not rolled back)\&. Closing a cursor is not undone by rolling back, either\&. However, other side\-effects caused by the cursor\*(Aqs query (such as side\-effects of volatile functions called by the query) +\fIare\fR +rolled back if they occur during a savepoint that is later rolled back\&. A cursor whose execution causes a transaction to abort is put in a cannot\-execute state, so while the transaction can be restored using +\fBROLLBACK TO SAVEPOINT\fR, the cursor can no longer be used\&. +.SH "EXAMPLES" +.PP +To undo the effects of the commands executed after +my_savepoint +was established: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ROLLBACK TO SAVEPOINT my_savepoint; +.fi +.if n \{\ +.RE +.\} +.PP +Cursor positions are not affected by savepoint rollback: +.sp +.if n \{\ +.RS 4 +.\} +.nf +BEGIN; + +DECLARE foo CURSOR FOR SELECT 1 UNION SELECT 2; + +SAVEPOINT foo; + +FETCH 1 FROM foo; + ?column? +\-\-\-\-\-\-\-\-\-\- + 1 + +ROLLBACK TO SAVEPOINT foo; + +FETCH 1 FROM foo; + ?column? +\-\-\-\-\-\-\-\-\-\- + 2 + +COMMIT; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +The +SQL +standard specifies that the key word +SAVEPOINT +is mandatory, but +PostgreSQL +and +Oracle +allow it to be omitted\&. SQL allows only +WORK, not +TRANSACTION, as a noise word after +ROLLBACK\&. Also, SQL has an optional clause +AND [ NO ] CHAIN +which is not currently supported by +PostgreSQL\&. Otherwise, this command conforms to the SQL standard\&. +.SH "SEE ALSO" +\fBBEGIN\fR(7), \fBCOMMIT\fR(7), RELEASE SAVEPOINT (\fBRELEASE_SAVEPOINT\fR(7)), \fBROLLBACK\fR(7), \fBSAVEPOINT\fR(7) diff --git a/doc/src/sgml/man7/SAVEPOINT.7 b/doc/src/sgml/man7/SAVEPOINT.7 new file mode 100644 index 000000000..3c3a318f1 --- /dev/null +++ b/doc/src/sgml/man7/SAVEPOINT.7 @@ -0,0 +1,113 @@ +'\" t +.\" Title: SAVEPOINT +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SAVEPOINT" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SAVEPOINT \- define a new savepoint within the current transaction +.\" SAVEPOINT +.\" savepoints: defining +.SH "SYNOPSIS" +.sp +.nf +SAVEPOINT \fIsavepoint_name\fR +.fi +.SH "DESCRIPTION" +.PP + +\fBSAVEPOINT\fR +establishes a new savepoint within the current transaction\&. +.PP +A savepoint is a special mark inside a transaction that allows all commands that are executed after it was established to be rolled back, restoring the transaction state to what it was at the time of the savepoint\&. +.SH "PARAMETERS" +.PP +\fIsavepoint_name\fR +.RS 4 +The name to give to the new savepoint\&. +.RE +.SH "NOTES" +.PP +Use +ROLLBACK TO SAVEPOINT (\fBROLLBACK_TO_SAVEPOINT\fR(7)) +to rollback to a savepoint\&. Use +RELEASE SAVEPOINT (\fBRELEASE_SAVEPOINT\fR(7)) +to destroy a savepoint, keeping the effects of commands executed after it was established\&. +.PP +Savepoints can only be established when inside a transaction block\&. There can be multiple savepoints defined within a transaction\&. +.SH "EXAMPLES" +.PP +To establish a savepoint and later undo the effects of all commands executed after it was established: +.sp +.if n \{\ +.RS 4 +.\} +.nf +BEGIN; + INSERT INTO table1 VALUES (1); + SAVEPOINT my_savepoint; + INSERT INTO table1 VALUES (2); + ROLLBACK TO SAVEPOINT my_savepoint; + INSERT INTO table1 VALUES (3); +COMMIT; +.fi +.if n \{\ +.RE +.\} +.sp +The above transaction will insert the values 1 and 3, but not 2\&. +.PP +To establish and later destroy a savepoint: +.sp +.if n \{\ +.RS 4 +.\} +.nf +BEGIN; + INSERT INTO table1 VALUES (3); + SAVEPOINT my_savepoint; + INSERT INTO table1 VALUES (4); + RELEASE SAVEPOINT my_savepoint; +COMMIT; +.fi +.if n \{\ +.RE +.\} +.sp +The above transaction will insert both 3 and 4\&. +.SH "COMPATIBILITY" +.PP +SQL requires a savepoint to be destroyed automatically when another savepoint with the same name is established\&. In +PostgreSQL, the old savepoint is kept, though only the more recent one will be used when rolling back or releasing\&. (Releasing the newer savepoint with +\fBRELEASE SAVEPOINT\fR +will cause the older one to again become accessible to +\fBROLLBACK TO SAVEPOINT\fR +and +\fBRELEASE SAVEPOINT\fR\&.) Otherwise, +\fBSAVEPOINT\fR +is fully SQL conforming\&. +.SH "SEE ALSO" +\fBBEGIN\fR(7), \fBCOMMIT\fR(7), RELEASE SAVEPOINT (\fBRELEASE_SAVEPOINT\fR(7)), \fBROLLBACK\fR(7), ROLLBACK TO SAVEPOINT (\fBROLLBACK_TO_SAVEPOINT\fR(7)) diff --git a/doc/src/sgml/man7/SECURITY_LABEL.7 b/doc/src/sgml/man7/SECURITY_LABEL.7 new file mode 100644 index 000000000..e4982ba76 --- /dev/null +++ b/doc/src/sgml/man7/SECURITY_LABEL.7 @@ -0,0 +1,168 @@ +'\" t +.\" Title: SECURITY LABEL +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SECURITY LABEL" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SECURITY_LABEL \- define or change a security label applied to an object +.\" SECURITY LABEL +.SH "SYNOPSIS" +.sp +.nf +SECURITY LABEL [ FOR \fIprovider\fR ] ON +{ + TABLE \fIobject_name\fR | + COLUMN \fItable_name\fR\&.\fIcolumn_name\fR | + AGGREGATE \fIagg_name\fR (\fIagg_type\fR [, \&.\&.\&.] ) | + DATABASE \fIobject_name\fR | + DOMAIN \fIobject_name\fR | + FOREIGN TABLE \fIobject_name\fR + FUNCTION \fIfunction_name\fR ( [ [ \fIargmode\fR ] [ \fIargname\fR ] \fIargtype\fR [, \&.\&.\&.] ] ) | + LARGE OBJECT \fIlarge_object_oid\fR | + [ PROCEDURAL ] LANGUAGE \fIobject_name\fR | + ROLE \fIobject_name\fR | + SCHEMA \fIobject_name\fR | + SEQUENCE \fIobject_name\fR | + TABLESPACE \fIobject_name\fR | + TYPE \fIobject_name\fR | + VIEW \fIobject_name\fR +} IS \*(Aq\fIlabel\fR\*(Aq +.fi +.SH "DESCRIPTION" +.PP + +\fBSECURITY LABEL\fR +applies a security label to a database object\&. An arbitrary number of security labels, one per label provider, can be associated with a given database object\&. Label providers are loadable modules which register themselves by using the function +\fBregister_label_provider\fR\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +.PP + +\fBregister_label_provider\fR +is not an SQL function; it can only be called from C code loaded into the backend\&. +.sp .5v +.RE +.PP +The label provider determines whether a given label is valid and whether it is permissible to assign that label to a given object\&. The meaning of a given label is likewise at the discretion of the label provider\&. +PostgreSQL +places no restrictions on whether or how a label provider must interpret security labels; it merely provides a mechanism for storing them\&. In practice, this facility is intended to allow integration with label\-based mandatory access control (MAC) systems such as +SE\-Linux\&. Such systems make all access control decisions based on object labels, rather than traditional discretionary access control (DAC) concepts such as users and groups\&. +.SH "PARAMETERS" +.PP +\fIobject_name\fR, \fItable_name\&.column_name\fR, \fIagg_name\fR, \fIfunction_name\fR +.RS 4 +The name of the object to be labeled\&. Names of tables, aggregates, domains, foreign tables, functions, sequences, types, and views can be schema\-qualified\&. +.RE +.PP +\fIprovider\fR +.RS 4 +The name of the provider with which this label is to be associated\&. The named provider must be loaded and must consent to the proposed labeling operation\&. If exactly one provider is loaded, the provider name may be omitted for brevity\&. +.RE +.PP +\fIarg_type\fR +.RS 4 +An input data type on which the aggregate function operates\&. To reference a zero\-argument aggregate function, write +* +in place of the list of input data types\&. +.RE +.PP +\fIargmode\fR +.RS 4 +The mode of a function argument: +IN, +OUT, +INOUT, or +VARIADIC\&. If omitted, the default is +IN\&. Note that +\fBSECURITY LABEL ON FUNCTION\fR +does not actually pay any attention to +OUT +arguments, since only the input arguments are needed to determine the function\*(Aqs identity\&. So it is sufficient to list the +IN, +INOUT, and +VARIADIC +arguments\&. +.RE +.PP +\fIargname\fR +.RS 4 +The name of a function argument\&. Note that +\fBSECURITY LABEL ON FUNCTION\fR +does not actually pay any attention to argument names, since only the argument data types are needed to determine the function\*(Aqs identity\&. +.RE +.PP +\fIargtype\fR +.RS 4 +The data type(s) of the function\*(Aqs arguments (optionally schema\-qualified), if any\&. +.RE +.PP +\fIlarge_object_oid\fR +.RS 4 +The OID of the large object\&. +.RE +.PP +PROCEDURAL +.RS 4 +This is a noise word\&. +.RE +.PP +\fIlabel\fR +.RS 4 +The new security label, written as a string literal; or +NULL +to drop the security label\&. +.RE +.SH "EXAMPLES" +.PP +The following example shows how the security label of a table might be changed\&. +.sp +.if n \{\ +.RS 4 +.\} +.nf +SECURITY LABEL FOR selinux ON TABLE mytable IS \*(Aqsystem_u:object_r:sepgsql_table_t:s0\*(Aq; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBSECURITY LABEL\fR +command in the SQL standard\&. +.SH "SEE ALSO" +sepgsql, dummy_seclabel diff --git a/doc/src/sgml/man7/SELECT.7 b/doc/src/sgml/man7/SELECT.7 new file mode 100644 index 000000000..98aff1d28 --- /dev/null +++ b/doc/src/sgml/man7/SELECT.7 @@ -0,0 +1,2035 @@ +'\" t +.\" Title: SELECT +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SELECT" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SELECT, TABLE, WITH \- retrieve rows from a table or view +.\" SELECT +.\" TABLE command +.\" WITH: in SELECT +.SH "SYNOPSIS" +.sp +.nf +[ WITH [ RECURSIVE ] \fIwith_query\fR [, \&.\&.\&.] ] +SELECT [ ALL | DISTINCT [ ON ( \fIexpression\fR [, \&.\&.\&.] ) ] ] + * | \fIexpression\fR [ [ AS ] \fIoutput_name\fR ] [, \&.\&.\&.] + [ FROM \fIfrom_item\fR [, \&.\&.\&.] ] + [ WHERE \fIcondition\fR ] + [ GROUP BY \fIexpression\fR [, \&.\&.\&.] ] + [ HAVING \fIcondition\fR [, \&.\&.\&.] ] + [ WINDOW \fIwindow_name\fR AS ( \fIwindow_definition\fR ) [, \&.\&.\&.] ] + [ { UNION | INTERSECT | EXCEPT } [ ALL | DISTINCT ] \fIselect\fR ] + [ ORDER BY \fIexpression\fR [ ASC | DESC | USING \fIoperator\fR ] [ NULLS { FIRST | LAST } ] [, \&.\&.\&.] ] + [ LIMIT { \fIcount\fR | ALL } ] + [ OFFSET \fIstart\fR [ ROW | ROWS ] ] + [ FETCH { FIRST | NEXT } [ \fIcount\fR ] { ROW | ROWS } ONLY ] + [ FOR { UPDATE | SHARE } [ OF \fItable_name\fR [, \&.\&.\&.] ] [ NOWAIT ] [\&.\&.\&.] ] + +where \fIfrom_item\fR can be one of: + + [ ONLY ] \fItable_name\fR [ * ] [ [ AS ] \fIalias\fR [ ( \fIcolumn_alias\fR [, \&.\&.\&.] ) ] ] + ( \fIselect\fR ) [ AS ] \fIalias\fR [ ( \fIcolumn_alias\fR [, \&.\&.\&.] ) ] + \fIwith_query_name\fR [ [ AS ] \fIalias\fR [ ( \fIcolumn_alias\fR [, \&.\&.\&.] ) ] ] + \fIfunction_name\fR ( [ \fIargument\fR [, \&.\&.\&.] ] ) [ AS ] \fIalias\fR [ ( \fIcolumn_alias\fR [, \&.\&.\&.] | \fIcolumn_definition\fR [, \&.\&.\&.] ) ] + \fIfunction_name\fR ( [ \fIargument\fR [, \&.\&.\&.] ] ) AS ( \fIcolumn_definition\fR [, \&.\&.\&.] ) + \fIfrom_item\fR [ NATURAL ] \fIjoin_type\fR \fIfrom_item\fR [ ON \fIjoin_condition\fR | USING ( \fIjoin_column\fR [, \&.\&.\&.] ) ] + +and \fIwith_query\fR is: + + \fIwith_query_name\fR [ ( \fIcolumn_name\fR [, \&.\&.\&.] ) ] AS ( \fIselect\fR | \fIvalues\fR | \fIinsert\fR | \fIupdate\fR | \fIdelete\fR ) + +TABLE [ ONLY ] \fItable_name\fR [ * ] +.fi +.SH "DESCRIPTION" +.PP + +\fBSELECT\fR +retrieves rows from zero or more tables\&. The general processing of +\fBSELECT\fR +is as follows: +.sp +.RS 4 +.ie n \{\ +\h'-04' 1.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 1." 4.2 +.\} +All queries in the +WITH +list are computed\&. These effectively serve as temporary tables that can be referenced in the +FROM +list\&. A +WITH +query that is referenced more than once in +FROM +is computed only once\&. (See +WITH Clause +below\&.) +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 2.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 2." 4.2 +.\} +All elements in the +FROM +list are computed\&. (Each element in the +FROM +list is a real or virtual table\&.) If more than one element is specified in the +FROM +list, they are cross\-joined together\&. (See +FROM Clause +below\&.) +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 3.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 3." 4.2 +.\} +If the +WHERE +clause is specified, all rows that do not satisfy the condition are eliminated from the output\&. (See +WHERE Clause +below\&.) +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 4.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 4." 4.2 +.\} +If the +GROUP BY +clause is specified, the output is combined into groups of rows that match on one or more values\&. If the +HAVING +clause is present, it eliminates groups that do not satisfy the given condition\&. (See +GROUP BY Clause +and +HAVING Clause +below\&.) +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 5.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 5." 4.2 +.\} +The actual output rows are computed using the +\fBSELECT\fR +output expressions for each selected row or row group\&. (See +SELECT List +below\&.) +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 6.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 6." 4.2 +.\} +SELECT DISTINCT +eliminates duplicate rows from the result\&. +SELECT DISTINCT ON +eliminates rows that match on all the specified expressions\&. +SELECT ALL +(the default) will return all candidate rows, including duplicates\&. (See +DISTINCT Clause +below\&.) +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 7.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 7." 4.2 +.\} +Using the operators +UNION, +INTERSECT, and +EXCEPT, the output of more than one +\fBSELECT\fR +statement can be combined to form a single result set\&. The +UNION +operator returns all rows that are in one or both of the result sets\&. The +INTERSECT +operator returns all rows that are strictly in both result sets\&. The +EXCEPT +operator returns the rows that are in the first result set but not in the second\&. In all three cases, duplicate rows are eliminated unless +ALL +is specified\&. The noise word +DISTINCT +can be added to explicitly specify eliminating duplicate rows\&. Notice that +DISTINCT +is the default behavior here, even though +ALL +is the default for +\fBSELECT\fR +itself\&. (See +UNION Clause, +INTERSECT Clause, and +EXCEPT Clause +below\&.) +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 8.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 8." 4.2 +.\} +If the +ORDER BY +clause is specified, the returned rows are sorted in the specified order\&. If +ORDER BY +is not given, the rows are returned in whatever order the system finds fastest to produce\&. (See +ORDER BY Clause +below\&.) +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04' 9.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP " 9." 4.2 +.\} +If the +LIMIT +(or +FETCH FIRST) or +OFFSET +clause is specified, the +\fBSELECT\fR +statement only returns a subset of the result rows\&. (See +LIMIT Clause +below\&.) +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'10.\h'+01'\c +.\} +.el \{\ +.sp -1 +.IP "10." 4.2 +.\} +If +FOR UPDATE +or +FOR SHARE +is specified, the +\fBSELECT\fR +statement locks the selected rows against concurrent updates\&. (See +FOR UPDATE/FOR SHARE Clause +below\&.) +.RE +.PP +You must have +SELECT +privilege on each column used in a +\fBSELECT\fR +command\&. The use of +FOR UPDATE +or +FOR SHARE +requires +UPDATE +privilege as well (for at least one column of each table so selected)\&. +.SH "PARAMETERS" +.SS "WITH Clause" +.PP +The +WITH +clause allows you to specify one or more subqueries that can be referenced by name in the primary query\&. The subqueries effectively act as temporary tables or views for the duration of the primary query\&. Each subquery can be a +\fBSELECT\fR, +\fBVALUES\fR, +\fBINSERT\fR, +\fBUPDATE\fR +or +\fBDELETE\fR +statement\&. When writing a data\-modifying statement (\fBINSERT\fR, +\fBUPDATE\fR +or +\fBDELETE\fR) in +WITH, it is usual to include a +RETURNING +clause\&. It is the output of +RETURNING, +\fInot\fR +the underlying table that the statement modifies, that forms the temporary table that is read by the primary query\&. If +RETURNING +is omitted, the statement is still executed, but it produces no output so it cannot be referenced as a table by the primary query\&. +.PP +A name (without schema qualification) must be specified for each +WITH +query\&. Optionally, a list of column names can be specified; if this is omitted, the column names are inferred from the subquery\&. +.PP +If +RECURSIVE +is specified, it allows a +\fBSELECT\fR +subquery to reference itself by name\&. Such a subquery must have the form +.sp +.if n \{\ +.RS 4 +.\} +.nf +\fInon_recursive_term\fR UNION [ ALL | DISTINCT ] \fIrecursive_term\fR +.fi +.if n \{\ +.RE +.\} +.sp + +where the recursive self\-reference must appear on the right\-hand side of the +UNION\&. Only one recursive self\-reference is permitted per query\&. Recursive data\-modifying statements are not supported, but you can use the results of a recursive +\fBSELECT\fR +query in a data\-modifying statement\&. See +Section 7.8, \(lqWITH Queries (Common Table Expressions)\(rq, in the documentation +for an example\&. +.PP +Another effect of +RECURSIVE +is that +WITH +queries need not be ordered: a query can reference another one that is later in the list\&. (However, circular references, or mutual recursion, are not implemented\&.) Without +RECURSIVE, +WITH +queries can only reference sibling +WITH +queries that are earlier in the +WITH +list\&. +.PP +A key property of +WITH +queries is that they are evaluated only once per execution of the primary query, even if the primary query refers to them more than once\&. In particular, data\-modifying statements are guaranteed to be executed once and only once, regardless of whether the primary query reads all or any of their output\&. +.PP +The primary query and the +WITH +queries are all (notionally) executed at the same time\&. This implies that the effects of a data\-modifying statement in +WITH +cannot be seen from other parts of the query, other than by reading its +RETURNING +output\&. If two such data\-modifying statements attempt to modify the same row, the results are unspecified\&. +.PP +See +Section 7.8, \(lqWITH Queries (Common Table Expressions)\(rq, in the documentation +for additional information\&. +.SS "FROM Clause" +.PP +The +FROM +clause specifies one or more source tables for the +\fBSELECT\fR\&. If multiple sources are specified, the result is the Cartesian product (cross join) of all the sources\&. But usually qualification conditions are added to restrict the returned rows to a small subset of the Cartesian product\&. +.PP +The +FROM +clause can contain the following elements: +.PP +\fItable_name\fR +.RS 4 +The name (optionally schema\-qualified) of an existing table or view\&. If +ONLY +is specified before the table name, only that table is scanned\&. If +ONLY +is not specified, the table and all its descendant tables (if any) are scanned\&. Optionally, +* +can be specified after the table name to explicitly indicate that descendant tables are included\&. +.RE +.PP +\fIalias\fR +.RS 4 +A substitute name for the +FROM +item containing the alias\&. An alias is used for brevity or to eliminate ambiguity for self\-joins (where the same table is scanned multiple times)\&. When an alias is provided, it completely hides the actual name of the table or function; for example given +FROM foo AS f, the remainder of the +\fBSELECT\fR +must refer to this +FROM +item as +f +not +foo\&. If an alias is written, a column alias list can also be written to provide substitute names for one or more columns of the table\&. +.RE +.PP +\fIselect\fR +.RS 4 +A sub\-\fBSELECT\fR +can appear in the +FROM +clause\&. This acts as though its output were created as a temporary table for the duration of this single +\fBSELECT\fR +command\&. Note that the sub\-\fBSELECT\fR +must be surrounded by parentheses, and an alias +\fImust\fR +be provided for it\&. A +\fBVALUES\fR(7) +command can also be used here\&. +.RE +.PP +\fIwith_query_name\fR +.RS 4 +A +WITH +query is referenced by writing its name, just as though the query\*(Aqs name were a table name\&. (In fact, the +WITH +query hides any real table of the same name for the purposes of the primary query\&. If necessary, you can refer to a real table of the same name by schema\-qualifying the table\*(Aqs name\&.) An alias can be provided in the same way as for a table\&. +.RE +.PP +\fIfunction_name\fR +.RS 4 +Function calls can appear in the +FROM +clause\&. (This is especially useful for functions that return result sets, but any function can be used\&.) This acts as though its output were created as a temporary table for the duration of this single +\fBSELECT\fR +command\&. An alias can also be used\&. If an alias is written, a column alias list can also be written to provide substitute names for one or more attributes of the function\*(Aqs composite return type\&. If the function has been defined as returning the +record +data type, then an alias or the key word +AS +must be present, followed by a column definition list in the form +( \fIcolumn_name\fR \fIdata_type\fR [, \&.\&.\&. ] )\&. The column definition list must match the actual number and types of columns returned by the function\&. +.RE +.PP +\fIjoin_type\fR +.RS 4 +One of +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +[ INNER ] JOIN +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +LEFT [ OUTER ] JOIN +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +RIGHT [ OUTER ] JOIN +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +FULL [ OUTER ] JOIN +.RE +.sp +.RS 4 +.ie n \{\ +\h'-04'\(bu\h'+03'\c +.\} +.el \{\ +.sp -1 +.IP \(bu 2.3 +.\} +CROSS JOIN +.RE +.sp +For the +INNER +and +OUTER +join types, a join condition must be specified, namely exactly one of +NATURAL, +ON \fIjoin_condition\fR, or +USING (\fIjoin_column\fR [, \&.\&.\&.])\&. See below for the meaning\&. For +CROSS JOIN, none of these clauses can appear\&. +.sp +A +JOIN +clause combines two +FROM +items\&. Use parentheses if necessary to determine the order of nesting\&. In the absence of parentheses, +JOINs nest left\-to\-right\&. In any case +JOIN +binds more tightly than the commas separating +FROM +items\&. +.sp +CROSS JOIN +and +INNER JOIN +produce a simple Cartesian product, the same result as you get from listing the two items at the top level of +FROM, but restricted by the join condition (if any)\&. +CROSS JOIN +is equivalent to +INNER JOIN ON (TRUE), that is, no rows are removed by qualification\&. These join types are just a notational convenience, since they do nothing you couldn\*(Aqt do with plain +FROM +and +WHERE\&. +.sp +LEFT OUTER JOIN +returns all rows in the qualified Cartesian product (i\&.e\&., all combined rows that pass its join condition), plus one copy of each row in the left\-hand table for which there was no right\-hand row that passed the join condition\&. This left\-hand row is extended to the full width of the joined table by inserting null values for the right\-hand columns\&. Note that only the +JOIN +clause\*(Aqs own condition is considered while deciding which rows have matches\&. Outer conditions are applied afterwards\&. +.sp +Conversely, +RIGHT OUTER JOIN +returns all the joined rows, plus one row for each unmatched right\-hand row (extended with nulls on the left)\&. This is just a notational convenience, since you could convert it to a +LEFT OUTER JOIN +by switching the left and right inputs\&. +.sp +FULL OUTER JOIN +returns all the joined rows, plus one row for each unmatched left\-hand row (extended with nulls on the right), plus one row for each unmatched right\-hand row (extended with nulls on the left)\&. +.RE +.PP +ON \fIjoin_condition\fR +.RS 4 +\fIjoin_condition\fR +is an expression resulting in a value of type +boolean +(similar to a +WHERE +clause) that specifies which rows in a join are considered to match\&. +.RE +.PP +USING ( \fIjoin_column\fR [, \&.\&.\&.] ) +.RS 4 +A clause of the form +USING ( a, b, \&.\&.\&. ) +is shorthand for +ON left_table\&.a = right_table\&.a AND left_table\&.b = right_table\&.b \&.\&.\&.\&. Also, +USING +implies that only one of each pair of equivalent columns will be included in the join output, not both\&. +.RE +.PP +NATURAL +.RS 4 +NATURAL +is shorthand for a +USING +list that mentions all columns in the two tables that have the same names\&. +.RE +.SS "WHERE Clause" +.PP +The optional +WHERE +clause has the general form +.sp +.if n \{\ +.RS 4 +.\} +.nf +WHERE \fIcondition\fR +.fi +.if n \{\ +.RE +.\} +.sp + +where +\fIcondition\fR +is any expression that evaluates to a result of type +boolean\&. Any row that does not satisfy this condition will be eliminated from the output\&. A row satisfies the condition if it returns true when the actual row values are substituted for any variable references\&. +.SS "GROUP BY Clause" +.PP +The optional +GROUP BY +clause has the general form +.sp +.if n \{\ +.RS 4 +.\} +.nf +GROUP BY \fIexpression\fR [, \&.\&.\&.] +.fi +.if n \{\ +.RE +.\} +.PP + +GROUP BY +will condense into a single row all selected rows that share the same values for the grouped expressions\&. +\fIexpression\fR +can be an input column name, or the name or ordinal number of an output column (\fBSELECT\fR +list item), or an arbitrary expression formed from input\-column values\&. In case of ambiguity, a +GROUP BY +name will be interpreted as an input\-column name rather than an output column name\&. +.PP +Aggregate functions, if any are used, are computed across all rows making up each group, producing a separate value for each group (whereas without +GROUP BY, an aggregate produces a single value computed across all the selected rows)\&. When +GROUP BY +is present, it is not valid for the +\fBSELECT\fR +list expressions to refer to ungrouped columns except within aggregate functions or if the ungrouped column is functionally dependent on the grouped columns, since there would otherwise be more than one possible value to return for an ungrouped column\&. A functional dependency exists if the grouped columns (or a subset thereof) are the primary key of the table containing the ungrouped column\&. +.SS "HAVING Clause" +.PP +The optional +HAVING +clause has the general form +.sp +.if n \{\ +.RS 4 +.\} +.nf +HAVING \fIcondition\fR +.fi +.if n \{\ +.RE +.\} +.sp + +where +\fIcondition\fR +is the same as specified for the +WHERE +clause\&. +.PP + +HAVING +eliminates group rows that do not satisfy the condition\&. +HAVING +is different from +WHERE: +WHERE +filters individual rows before the application of +GROUP BY, while +HAVING +filters group rows created by +GROUP BY\&. Each column referenced in +\fIcondition\fR +must unambiguously reference a grouping column, unless the reference appears within an aggregate function\&. +.PP +The presence of +HAVING +turns a query into a grouped query even if there is no +GROUP BY +clause\&. This is the same as what happens when the query contains aggregate functions but no +GROUP BY +clause\&. All the selected rows are considered to form a single group, and the +\fBSELECT\fR +list and +HAVING +clause can only reference table columns from within aggregate functions\&. Such a query will emit a single row if the +HAVING +condition is true, zero rows if it is not true\&. +.SS "WINDOW Clause" +.PP +The optional +WINDOW +clause has the general form +.sp +.if n \{\ +.RS 4 +.\} +.nf +WINDOW \fIwindow_name\fR AS ( \fIwindow_definition\fR ) [, \&.\&.\&.] +.fi +.if n \{\ +.RE +.\} +.sp + +where +\fIwindow_name\fR +is a name that can be referenced from subsequent window definitions or +OVER +clauses, and +\fIwindow_definition\fR +is +.sp +.if n \{\ +.RS 4 +.\} +.nf +[ \fIexisting_window_name\fR ] +[ PARTITION BY \fIexpression\fR [, \&.\&.\&.] ] +[ ORDER BY \fIexpression\fR [ ASC | DESC | USING \fIoperator\fR ] [ NULLS { FIRST | LAST } ] [, \&.\&.\&.] ] +[ \fIframe_clause\fR ] +.fi +.if n \{\ +.RE +.\} +.PP +If an +\fIexisting_window_name\fR +is specified it must refer to an earlier entry in the +WINDOW +list; the new window copies its partitioning clause from that entry, as well as its ordering clause if any\&. In this case the new window cannot specify its own +PARTITION BY +clause, and it can specify +ORDER BY +only if the copied window does not have one\&. The new window always uses its own frame clause; the copied window must not specify a frame clause\&. +.PP +The elements of the +PARTITION BY +list are interpreted in much the same fashion as elements of a +GROUP BY Clause, except that they are always simple expressions and never the name or number of an output column\&. Another difference is that these expressions can contain aggregate function calls, which are not allowed in a regular +GROUP BY +clause\&. They are allowed here because windowing occurs after grouping and aggregation\&. +.PP +Similarly, the elements of the +ORDER BY +list are interpreted in much the same fashion as elements of an +ORDER BY Clause, except that the expressions are always taken as simple expressions and never the name or number of an output column\&. +.PP +The optional +\fIframe_clause\fR +defines the +window frame +for window functions that depend on the frame (not all do)\&. The window frame is a set of related rows for each row of the query (called the +current row)\&. The +\fIframe_clause\fR +can be one of +.sp +.if n \{\ +.RS 4 +.\} +.nf +[ RANGE | ROWS ] \fIframe_start\fR +[ RANGE | ROWS ] BETWEEN \fIframe_start\fR AND \fIframe_end\fR +.fi +.if n \{\ +.RE +.\} +.sp + +where +\fIframe_start\fR +and +\fIframe_end\fR +can be one of +.sp +.if n \{\ +.RS 4 +.\} +.nf +UNBOUNDED PRECEDING +\fIvalue\fR PRECEDING +CURRENT ROW +\fIvalue\fR FOLLOWING +UNBOUNDED FOLLOWING +.fi +.if n \{\ +.RE +.\} +.sp + +If +\fIframe_end\fR +is omitted it defaults to +CURRENT ROW\&. Restrictions are that +\fIframe_start\fR +cannot be +UNBOUNDED FOLLOWING, +\fIframe_end\fR +cannot be +UNBOUNDED PRECEDING, and the +\fIframe_end\fR +choice cannot appear earlier in the above list than the +\fIframe_start\fR +choice \(em for example +RANGE BETWEEN CURRENT ROW AND \fIvalue\fR PRECEDING +is not allowed\&. +.PP +The default framing option is +RANGE UNBOUNDED PRECEDING, which is the same as +RANGE BETWEEN UNBOUNDED PRECEDING AND CURRENT ROW; it sets the frame to be all rows from the partition start up through the current row\*(Aqs last peer in the +ORDER BY +ordering (which means all rows if there is no +ORDER BY)\&. In general, +UNBOUNDED PRECEDING +means that the frame starts with the first row of the partition, and similarly +UNBOUNDED FOLLOWING +means that the frame ends with the last row of the partition (regardless of +RANGE +or +ROWS +mode)\&. In +ROWS +mode, +CURRENT ROW +means that the frame starts or ends with the current row; but in +RANGE +mode it means that the frame starts or ends with the current row\*(Aqs first or last peer in the +ORDER BY +ordering\&. The +\fIvalue\fR +PRECEDING +and +\fIvalue\fR +FOLLOWING +cases are currently only allowed in +ROWS +mode\&. They indicate that the frame starts or ends with the row that many rows before or after the current row\&. +\fIvalue\fR +must be an integer expression not containing any variables, aggregate functions, or window functions\&. The value must not be null or negative; but it can be zero, which selects the current row itself\&. +.PP +Beware that the +ROWS +options can produce unpredictable results if the +ORDER BY +ordering does not order the rows uniquely\&. The +RANGE +options are designed to ensure that rows that are peers in the +ORDER BY +ordering are treated alike; any two peer rows will be both in or both not in the frame\&. +.PP +The purpose of a +WINDOW +clause is to specify the behavior of +window functions +appearing in the query\*(Aqs +SELECT List +or +ORDER BY Clause\&. These functions can reference the +WINDOW +clause entries by name in their +OVER +clauses\&. A +WINDOW +clause entry does not have to be referenced anywhere, however; if it is not used in the query it is simply ignored\&. It is possible to use window functions without any +WINDOW +clause at all, since a window function call can specify its window definition directly in its +OVER +clause\&. However, the +WINDOW +clause saves typing when the same window definition is needed for more than one window function\&. +.PP +Window functions are described in detail in +Section 3.5, \(lqWindow Functions\(rq, in the documentation, +Section 4.2.8, \(lqWindow Function Calls\(rq, in the documentation, and +Section 7.2.4, \(lqWindow Function Processing\(rq, in the documentation\&. +.SS "SELECT List" +.PP +The +\fBSELECT\fR +list (between the key words +SELECT +and +FROM) specifies expressions that form the output rows of the +\fBSELECT\fR +statement\&. The expressions can (and usually do) refer to columns computed in the +FROM +clause\&. +.PP +Just as in a table, every output column of a +\fBSELECT\fR +has a name\&. In a simple +\fBSELECT\fR +this name is just used to label the column for display, but when the +\fBSELECT\fR +is a sub\-query of a larger query, the name is seen by the larger query as the column name of the virtual table produced by the sub\-query\&. To specify the name to use for an output column, write +AS +\fIoutput_name\fR +after the column\*(Aqs expression\&. (You can omit +AS, but only if the desired output name does not match any +PostgreSQL +keyword (see +Appendix\ \&C, SQL Key Words)\&. For protection against possible future keyword additions, it is recommended that you always either write +AS +or double\-quote the output name\&.) If you do not specify a column name, a name is chosen automatically by +PostgreSQL\&. If the column\*(Aqs expression is a simple column reference then the chosen name is the same as that column\*(Aqs name\&. In more complex cases a function or type name may be used, or the system may fall back on a generated name such as +?column?\&. +.PP +An output column\*(Aqs name can be used to refer to the column\*(Aqs value in +ORDER BY +and +GROUP BY +clauses, but not in the +WHERE +or +HAVING +clauses; there you must write out the expression instead\&. +.PP +Instead of an expression, +* +can be written in the output list as a shorthand for all the columns of the selected rows\&. Also, you can write +\fItable_name\fR\&.* +as a shorthand for the columns coming from just that table\&. In these cases it is not possible to specify new names with +AS; the output column names will be the same as the table columns\*(Aq names\&. +.SS "DISTINCT Clause" +.PP +If +SELECT DISTINCT +is specified, all duplicate rows are removed from the result set (one row is kept from each group of duplicates)\&. +SELECT ALL +specifies the opposite: all rows are kept; that is the default\&. +.PP + +SELECT DISTINCT ON ( \fIexpression\fR [, \&.\&.\&.] ) +keeps only the first row of each set of rows where the given expressions evaluate to equal\&. The +DISTINCT ON +expressions are interpreted using the same rules as for +ORDER BY +(see above)\&. Note that the +\(lqfirst row\(rq +of each set is unpredictable unless +ORDER BY +is used to ensure that the desired row appears first\&. For example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT DISTINCT ON (location) location, time, report + FROM weather_reports + ORDER BY location, time DESC; +.fi +.if n \{\ +.RE +.\} +.sp +retrieves the most recent weather report for each location\&. But if we had not used +ORDER BY +to force descending order of time values for each location, we\*(Aqd have gotten a report from an unpredictable time for each location\&. +.PP +The +DISTINCT ON +expression(s) must match the leftmost +ORDER BY +expression(s)\&. The +ORDER BY +clause will normally contain additional expression(s) that determine the desired precedence of rows within each +DISTINCT ON +group\&. +.SS "UNION Clause" +.PP +The +UNION +clause has this general form: +.sp +.if n \{\ +.RS 4 +.\} +.nf +\fIselect_statement\fR UNION [ ALL | DISTINCT ] \fIselect_statement\fR +.fi +.if n \{\ +.RE +.\} +.sp +\fIselect_statement\fR +is any +\fBSELECT\fR +statement without an +ORDER BY, +LIMIT, +FOR UPDATE, or +FOR SHARE +clause\&. (ORDER BY +and +LIMIT +can be attached to a subexpression if it is enclosed in parentheses\&. Without parentheses, these clauses will be taken to apply to the result of the +UNION, not to its right\-hand input expression\&.) +.PP +The +UNION +operator computes the set union of the rows returned by the involved +\fBSELECT\fR +statements\&. A row is in the set union of two result sets if it appears in at least one of the result sets\&. The two +\fBSELECT\fR +statements that represent the direct operands of the +UNION +must produce the same number of columns, and corresponding columns must be of compatible data types\&. +.PP +The result of +UNION +does not contain any duplicate rows unless the +ALL +option is specified\&. +ALL +prevents elimination of duplicates\&. (Therefore, +UNION ALL +is usually significantly quicker than +UNION; use +ALL +when you can\&.) +DISTINCT +can be written to explicitly specify the default behavior of eliminating duplicate rows\&. +.PP +Multiple +UNION +operators in the same +\fBSELECT\fR +statement are evaluated left to right, unless otherwise indicated by parentheses\&. +.PP +Currently, +FOR UPDATE +and +FOR SHARE +cannot be specified either for a +UNION +result or for any input of a +UNION\&. +.SS "INTERSECT Clause" +.PP +The +INTERSECT +clause has this general form: +.sp +.if n \{\ +.RS 4 +.\} +.nf +\fIselect_statement\fR INTERSECT [ ALL | DISTINCT ] \fIselect_statement\fR +.fi +.if n \{\ +.RE +.\} +.sp +\fIselect_statement\fR +is any +\fBSELECT\fR +statement without an +ORDER BY, +LIMIT, +FOR UPDATE, or +FOR SHARE +clause\&. +.PP +The +INTERSECT +operator computes the set intersection of the rows returned by the involved +\fBSELECT\fR +statements\&. A row is in the intersection of two result sets if it appears in both result sets\&. +.PP +The result of +INTERSECT +does not contain any duplicate rows unless the +ALL +option is specified\&. With +ALL, a row that has +\fIm\fR +duplicates in the left table and +\fIn\fR +duplicates in the right table will appear min(\fIm\fR,\fIn\fR) times in the result set\&. +DISTINCT +can be written to explicitly specify the default behavior of eliminating duplicate rows\&. +.PP +Multiple +INTERSECT +operators in the same +\fBSELECT\fR +statement are evaluated left to right, unless parentheses dictate otherwise\&. +INTERSECT +binds more tightly than +UNION\&. That is, +A UNION B INTERSECT C +will be read as +A UNION (B INTERSECT C)\&. +.PP +Currently, +FOR UPDATE +and +FOR SHARE +cannot be specified either for an +INTERSECT +result or for any input of an +INTERSECT\&. +.SS "EXCEPT Clause" +.PP +The +EXCEPT +clause has this general form: +.sp +.if n \{\ +.RS 4 +.\} +.nf +\fIselect_statement\fR EXCEPT [ ALL | DISTINCT ] \fIselect_statement\fR +.fi +.if n \{\ +.RE +.\} +.sp +\fIselect_statement\fR +is any +\fBSELECT\fR +statement without an +ORDER BY, +LIMIT, +FOR UPDATE, or +FOR SHARE +clause\&. +.PP +The +EXCEPT +operator computes the set of rows that are in the result of the left +\fBSELECT\fR +statement but not in the result of the right one\&. +.PP +The result of +EXCEPT +does not contain any duplicate rows unless the +ALL +option is specified\&. With +ALL, a row that has +\fIm\fR +duplicates in the left table and +\fIn\fR +duplicates in the right table will appear max(\fIm\fR\-\fIn\fR,0) times in the result set\&. +DISTINCT +can be written to explicitly specify the default behavior of eliminating duplicate rows\&. +.PP +Multiple +EXCEPT +operators in the same +\fBSELECT\fR +statement are evaluated left to right, unless parentheses dictate otherwise\&. +EXCEPT +binds at the same level as +UNION\&. +.PP +Currently, +FOR UPDATE +and +FOR SHARE +cannot be specified either for an +EXCEPT +result or for any input of an +EXCEPT\&. +.SS "ORDER BY Clause" +.PP +The optional +ORDER BY +clause has this general form: +.sp +.if n \{\ +.RS 4 +.\} +.nf +ORDER BY \fIexpression\fR [ ASC | DESC | USING \fIoperator\fR ] [ NULLS { FIRST | LAST } ] [, \&.\&.\&.] +.fi +.if n \{\ +.RE +.\} +.sp + +The +ORDER BY +clause causes the result rows to be sorted according to the specified expression(s)\&. If two rows are equal according to the leftmost expression, they are compared according to the next expression and so on\&. If they are equal according to all specified expressions, they are returned in an implementation\-dependent order\&. +.PP +Each +\fIexpression\fR +can be the name or ordinal number of an output column (\fBSELECT\fR +list item), or it can be an arbitrary expression formed from input\-column values\&. +.PP +The ordinal number refers to the ordinal (left\-to\-right) position of the output column\&. This feature makes it possible to define an ordering on the basis of a column that does not have a unique name\&. This is never absolutely necessary because it is always possible to assign a name to an output column using the +AS +clause\&. +.PP +It is also possible to use arbitrary expressions in the +ORDER BY +clause, including columns that do not appear in the +\fBSELECT\fR +output list\&. Thus the following statement is valid: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT name FROM distributors ORDER BY code; +.fi +.if n \{\ +.RE +.\} +.sp +A limitation of this feature is that an +ORDER BY +clause applying to the result of a +UNION, +INTERSECT, or +EXCEPT +clause can only specify an output column name or number, not an expression\&. +.PP +If an +ORDER BY +expression is a simple name that matches both an output column name and an input column name, +ORDER BY +will interpret it as the output column name\&. This is the opposite of the choice that +GROUP BY +will make in the same situation\&. This inconsistency is made to be compatible with the SQL standard\&. +.PP +Optionally one can add the key word +ASC +(ascending) or +DESC +(descending) after any expression in the +ORDER BY +clause\&. If not specified, +ASC +is assumed by default\&. Alternatively, a specific ordering operator name can be specified in the +USING +clause\&. An ordering operator must be a less\-than or greater\-than member of some B\-tree operator family\&. +ASC +is usually equivalent to +USING < +and +DESC +is usually equivalent to +USING >\&. (But the creator of a user\-defined data type can define exactly what the default sort ordering is, and it might correspond to operators with other names\&.) +.PP +If +NULLS LAST +is specified, null values sort after all non\-null values; if +NULLS FIRST +is specified, null values sort before all non\-null values\&. If neither is specified, the default behavior is +NULLS LAST +when +ASC +is specified or implied, and +NULLS FIRST +when +DESC +is specified (thus, the default is to act as though nulls are larger than non\-nulls)\&. When +USING +is specified, the default nulls ordering depends on whether the operator is a less\-than or greater\-than operator\&. +.PP +Note that ordering options apply only to the expression they follow; for example +ORDER BY x, y DESC +does not mean the same thing as +ORDER BY x DESC, y DESC\&. +.PP +Character\-string data is sorted according to the collation that applies to the column being sorted\&. That can be overridden at need by including a +COLLATE +clause in the +\fIexpression\fR, for example +ORDER BY mycolumn COLLATE "en_US"\&. For more information see +Section 4.2.10, \(lqCollation Expressions\(rq, in the documentation +and +Section 22.2, \(lqCollation Support\(rq, in the documentation\&. +.SS "LIMIT Clause" +.PP +The +LIMIT +clause consists of two independent sub\-clauses: +.sp +.if n \{\ +.RS 4 +.\} +.nf +LIMIT { \fIcount\fR | ALL } +OFFSET \fIstart\fR +.fi +.if n \{\ +.RE +.\} +.sp + +\fIcount\fR +specifies the maximum number of rows to return, while +\fIstart\fR +specifies the number of rows to skip before starting to return rows\&. When both are specified, +\fIstart\fR +rows are skipped before starting to count the +\fIcount\fR +rows to be returned\&. +.PP +If the +\fIcount\fR +expression evaluates to NULL, it is treated as +LIMIT ALL, i\&.e\&., no limit\&. If +\fIstart\fR +evaluates to NULL, it is treated the same as +OFFSET 0\&. +.PP +SQL:2008 introduced a different syntax to achieve the same result, which +PostgreSQL +also supports\&. It is: +.sp +.if n \{\ +.RS 4 +.\} +.nf +OFFSET \fIstart\fR { ROW | ROWS } +FETCH { FIRST | NEXT } [ \fIcount\fR ] { ROW | ROWS } ONLY +.fi +.if n \{\ +.RE +.\} +.sp + +In this syntax, to write anything except a simple integer constant for +\fIstart\fR +or +\fIcount\fR, you must write parentheses around it\&. If +\fIcount\fR +is omitted in a +FETCH +clause, it defaults to 1\&. +ROW +and +ROWS +as well as +FIRST +and +NEXT +are noise words that don\*(Aqt influence the effects of these clauses\&. According to the standard, the +OFFSET +clause must come before the +FETCH +clause if both are present; but +PostgreSQL +is laxer and allows either order\&. +.PP +When using +LIMIT, it is a good idea to use an +ORDER BY +clause that constrains the result rows into a unique order\&. Otherwise you will get an unpredictable subset of the query\*(Aqs rows \(em you might be asking for the tenth through twentieth rows, but tenth through twentieth in what ordering? You don\*(Aqt know what ordering unless you specify +ORDER BY\&. +.PP +The query planner takes +LIMIT +into account when generating a query plan, so you are very likely to get different plans (yielding different row orders) depending on what you use for +LIMIT +and +OFFSET\&. Thus, using different +LIMIT/OFFSET +values to select different subsets of a query result +\fIwill give inconsistent results\fR +unless you enforce a predictable result ordering with +ORDER BY\&. This is not a bug; it is an inherent consequence of the fact that SQL does not promise to deliver the results of a query in any particular order unless +ORDER BY +is used to constrain the order\&. +.PP +It is even possible for repeated executions of the same +LIMIT +query to return different subsets of the rows of a table, if there is not an +ORDER BY +to enforce selection of a deterministic subset\&. Again, this is not a bug; determinism of the results is simply not guaranteed in such a case\&. +.SS "FOR UPDATE/FOR SHARE Clause" +.PP +The +FOR UPDATE +clause has this form: +.sp +.if n \{\ +.RS 4 +.\} +.nf +FOR UPDATE [ OF \fItable_name\fR [, \&.\&.\&.] ] [ NOWAIT ] +.fi +.if n \{\ +.RE +.\} +.PP +The closely related +FOR SHARE +clause has this form: +.sp +.if n \{\ +.RS 4 +.\} +.nf +FOR SHARE [ OF \fItable_name\fR [, \&.\&.\&.] ] [ NOWAIT ] +.fi +.if n \{\ +.RE +.\} +.PP + +FOR UPDATE +causes the rows retrieved by the +\fBSELECT\fR +statement to be locked as though for update\&. This prevents them from being modified or deleted by other transactions until the current transaction ends\&. That is, other transactions that attempt +\fBUPDATE\fR, +\fBDELETE\fR, or +\fBSELECT FOR UPDATE\fR +of these rows will be blocked until the current transaction ends\&. Also, if an +\fBUPDATE\fR, +\fBDELETE\fR, or +\fBSELECT FOR UPDATE\fR +from another transaction has already locked a selected row or rows, +\fBSELECT FOR UPDATE\fR +will wait for the other transaction to complete, and will then lock and return the updated row (or no row, if the row was deleted)\&. Within a +REPEATABLE READ +or +SERIALIZABLE +transaction, however, an error will be thrown if a row to be locked has changed since the transaction started\&. For further discussion see +Chapter 13, Concurrency Control, in the documentation\&. +.PP + +FOR SHARE +behaves similarly, except that it acquires a shared rather than exclusive lock on each retrieved row\&. A shared lock blocks other transactions from performing +\fBUPDATE\fR, +\fBDELETE\fR, or +\fBSELECT FOR UPDATE\fR +on these rows, but it does not prevent them from performing +\fBSELECT FOR SHARE\fR\&. +.PP +To prevent the operation from waiting for other transactions to commit, use the +NOWAIT +option\&. With +NOWAIT, the statement reports an error, rather than waiting, if a selected row cannot be locked immediately\&. Note that +NOWAIT +applies only to the row\-level lock(s) \(em the required +ROW SHARE +table\-level lock is still taken in the ordinary way (see +Chapter 13, Concurrency Control, in the documentation)\&. You can use +\fBLOCK\fR(7) +with the +NOWAIT +option first, if you need to acquire the table\-level lock without waiting\&. +.PP +If specific tables are named in +FOR UPDATE +or +FOR SHARE, then only rows coming from those tables are locked; any other tables used in the +\fBSELECT\fR +are simply read as usual\&. A +FOR UPDATE +or +FOR SHARE +clause without a table list affects all tables used in the statement\&. If +FOR UPDATE +or +FOR SHARE +is applied to a view or sub\-query, it affects all tables used in the view or sub\-query\&. However, +FOR UPDATE/FOR SHARE +do not apply to +WITH +queries referenced by the primary query\&. If you want row locking to occur within a +WITH +query, specify +FOR UPDATE +or +FOR SHARE +within the +WITH +query\&. +.PP +Multiple +FOR UPDATE +and +FOR SHARE +clauses can be written if it is necessary to specify different locking behavior for different tables\&. If the same table is mentioned (or implicitly affected) by both +FOR UPDATE +and +FOR SHARE +clauses, then it is processed as +FOR UPDATE\&. Similarly, a table is processed as +NOWAIT +if that is specified in any of the clauses affecting it\&. +.PP + +FOR UPDATE +and +FOR SHARE +cannot be used in contexts where returned rows cannot be clearly identified with individual table rows; for example they cannot be used with aggregation\&. +.PP +When +FOR UPDATE +or +FOR SHARE +appears at the top level of a +\fBSELECT\fR +query, the rows that are locked are exactly those that are returned by the query; in the case of a join query, the rows locked are those that contribute to returned join rows\&. In addition, rows that satisfied the query conditions as of the query snapshot will be locked, although they will not be returned if they were updated after the snapshot and no longer satisfy the query conditions\&. If a +LIMIT +is used, locking stops once enough rows have been returned to satisfy the limit (but note that rows skipped over by +OFFSET +will get locked)\&. Similarly, if +FOR UPDATE +or +FOR SHARE +is used in a cursor\*(Aqs query, only rows actually fetched or stepped past by the cursor will be locked\&. +.PP +When +FOR UPDATE +or +FOR SHARE +appears in a sub\-\fBSELECT\fR, the rows locked are those returned to the outer query by the sub\-query\&. This might involve fewer rows than inspection of the sub\-query alone would suggest, since conditions from the outer query might be used to optimize execution of the sub\-query\&. For example, +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT * FROM (SELECT * FROM mytable FOR UPDATE) ss WHERE col1 = 5; +.fi +.if n \{\ +.RE +.\} +.sp +will lock only rows having +col1 = 5, even though that condition is not textually within the sub\-query\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBCaution\fR +.ps -1 +.br +.PP +Avoid locking a row and then modifying it within a later savepoint or +PL/pgSQL +exception block\&. A subsequent rollback would cause the lock to be lost\&. For example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +BEGIN; +SELECT * FROM mytable WHERE key = 1 FOR UPDATE; +SAVEPOINT s; +UPDATE mytable SET \&.\&.\&. WHERE key = 1; +ROLLBACK TO s; +.fi +.if n \{\ +.RE +.\} +.sp +After the +\fBROLLBACK\fR, the row is effectively unlocked, rather than returned to its pre\-savepoint state of being locked but not modified\&. This hazard occurs if a row locked in the current transaction is updated or deleted, or if a shared lock is upgraded to exclusive: in all these cases, the former lock state is forgotten\&. If the transaction is then rolled back to a state between the original locking command and the subsequent change, the row will appear not to be locked at all\&. This is an implementation deficiency which will be addressed in a future release of +PostgreSQL\&. +.sp .5v +.RE +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBCaution\fR +.ps -1 +.br +.PP +It is possible for a +\fBSELECT\fR +command running at the +READ COMMITTED +transaction isolation level and using +ORDER BY +and +FOR UPDATE/SHARE +to return rows out of order\&. This is because +ORDER BY +is applied first\&. The command sorts the result, but might then block trying to obtain a lock on one or more of the rows\&. Once the +SELECT +unblocks, some of the ordering column values might have been modified, leading to those rows appearing to be out of order (though they are in order in terms of the original column values)\&. This can be worked around at need by placing the +FOR UPDATE/SHARE +clause in a sub\-query, for example +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT * FROM (SELECT * FROM mytable FOR UPDATE) ss ORDER BY column1; +.fi +.if n \{\ +.RE +.\} +.sp +Note that this will result in locking all rows of +mytable, whereas +FOR UPDATE +at the top level would lock only the actually returned rows\&. This can make for a significant performance difference, particularly if the +ORDER BY +is combined with +LIMIT +or other restrictions\&. So this technique is recommended only if concurrent updates of the ordering columns are expected and a strictly sorted result is required\&. +.PP +At the +REPEATABLE READ +or +SERIALIZABLE +transaction isolation level this would cause a serialization failure (with a +SQLSTATE +of +\*(Aq40001\*(Aq), so there is no possibility of receiving rows out of order under these isolation levels\&. +.sp .5v +.RE +.SS "TABLE Command" +.PP +The command +.sp +.if n \{\ +.RS 4 +.\} +.nf +TABLE \fIname\fR +.fi +.if n \{\ +.RE +.\} +.sp +is completely equivalent to +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT * FROM \fIname\fR +.fi +.if n \{\ +.RE +.\} +.sp +It can be used as a top\-level command or as a space\-saving syntax variant in parts of complex queries\&. +.SH "EXAMPLES" +.PP +To join the table +films +with the table +distributors: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT f\&.title, f\&.did, d\&.name, f\&.date_prod, f\&.kind + FROM distributors d, films f + WHERE f\&.did = d\&.did + + title | did | name | date_prod | kind +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\- + The Third Man | 101 | British Lion | 1949\-12\-23 | Drama + The African Queen | 101 | British Lion | 1951\-08\-11 | Romantic + \&.\&.\&. +.fi +.if n \{\ +.RE +.\} +.PP +To sum the column +len +of all films and group the results by +kind: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT kind, sum(len) AS total FROM films GROUP BY kind; + + kind | total +\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\- + Action | 07:34 + Comedy | 02:58 + Drama | 14:28 + Musical | 06:42 + Romantic | 04:38 +.fi +.if n \{\ +.RE +.\} +.PP +To sum the column +len +of all films, group the results by +kind +and show those group totals that are less than 5 hours: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT kind, sum(len) AS total + FROM films + GROUP BY kind + HAVING sum(len) < interval \*(Aq5 hours\*(Aq; + + kind | total +\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\- + Comedy | 02:58 + Romantic | 04:38 +.fi +.if n \{\ +.RE +.\} +.PP +The following two examples are identical ways of sorting the individual results according to the contents of the second column (name): +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT * FROM distributors ORDER BY name; +SELECT * FROM distributors ORDER BY 2; + + did | name +\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + 109 | 20th Century Fox + 110 | Bavaria Atelier + 101 | British Lion + 107 | Columbia + 102 | Jean Luc Godard + 113 | Luso films + 104 | Mosfilm + 103 | Paramount + 106 | Toho + 105 | United Artists + 111 | Walt Disney + 112 | Warner Bros\&. + 108 | Westward +.fi +.if n \{\ +.RE +.\} +.PP +The next example shows how to obtain the union of the tables +distributors +and +actors, restricting the results to those that begin with the letter W in each table\&. Only distinct rows are wanted, so the key word +ALL +is omitted\&. +.sp +.if n \{\ +.RS 4 +.\} +.nf +distributors: actors: + did | name id | name +\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\- \-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + 108 | Westward 1 | Woody Allen + 111 | Walt Disney 2 | Warren Beatty + 112 | Warner Bros\&. 3 | Walter Matthau + \&.\&.\&. \&.\&.\&. + +SELECT distributors\&.name + FROM distributors + WHERE distributors\&.name LIKE \*(AqW%\*(Aq +UNION +SELECT actors\&.name + FROM actors + WHERE actors\&.name LIKE \*(AqW%\*(Aq; + + name +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + Walt Disney + Walter Matthau + Warner Bros\&. + Warren Beatty + Westward + Woody Allen +.fi +.if n \{\ +.RE +.\} +.PP +This example shows how to use a function in the +FROM +clause, both with and without a column definition list: +.sp +.if n \{\ +.RS 4 +.\} +.nf +CREATE FUNCTION distributors(int) RETURNS SETOF distributors AS $$ + SELECT * FROM distributors WHERE did = $1; +$$ LANGUAGE SQL; + +SELECT * FROM distributors(111); + did | name +\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\- + 111 | Walt Disney + +CREATE FUNCTION distributors_2(int) RETURNS SETOF record AS $$ + SELECT * FROM distributors WHERE did = $1; +$$ LANGUAGE SQL; + +SELECT * FROM distributors_2(111) AS (f1 int, f2 text); + f1 | f2 +\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\- + 111 | Walt Disney +.fi +.if n \{\ +.RE +.\} +.PP +This example shows how to use a simple +WITH +clause: +.sp +.if n \{\ +.RS 4 +.\} +.nf +WITH t AS ( + SELECT random() as x FROM generate_series(1, 3) + ) +SELECT * FROM t +UNION ALL +SELECT * FROM t + + x +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + 0\&.534150459803641 + 0\&.520092216785997 + 0\&.0735620250925422 + 0\&.534150459803641 + 0\&.520092216785997 + 0\&.0735620250925422 +.fi +.if n \{\ +.RE +.\} +.sp +Notice that the +WITH +query was evaluated only once, so that we got two sets of the same three random values\&. +.PP +This example uses +WITH RECURSIVE +to find all subordinates (direct or indirect) of the employee Mary, and their level of indirectness, from a table that shows only direct subordinates: +.sp +.if n \{\ +.RS 4 +.\} +.nf +WITH RECURSIVE employee_recursive(distance, employee_name, manager_name) AS ( + SELECT 1, employee_name, manager_name + FROM employee + WHERE manager_name = \*(AqMary\*(Aq + UNION ALL + SELECT er\&.distance + 1, e\&.employee_name, e\&.manager_name + FROM employee_recursive er, employee e + WHERE er\&.employee_name = e\&.manager_name + ) +SELECT distance, employee_name FROM employee_recursive; +.fi +.if n \{\ +.RE +.\} +.sp +Notice the typical form of recursive queries: an initial condition, followed by +UNION, followed by the recursive part of the query\&. Be sure that the recursive part of the query will eventually return no tuples, or else the query will loop indefinitely\&. (See +Section 7.8, \(lqWITH Queries (Common Table Expressions)\(rq, in the documentation +for more examples\&.) +.SH "COMPATIBILITY" +.PP +Of course, the +\fBSELECT\fR +statement is compatible with the SQL standard\&. But there are some extensions and some missing features\&. +.SS "Omitted FROM Clauses" +.PP + +PostgreSQL +allows one to omit the +FROM +clause\&. It has a straightforward use to compute the results of simple expressions: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT 2+2; + + ?column? +\-\-\-\-\-\-\-\-\-\- + 4 +.fi +.if n \{\ +.RE +.\} +.sp +Some other +SQL +databases cannot do this except by introducing a dummy one\-row table from which to do the +\fBSELECT\fR\&. +.PP +Note that if a +FROM +clause is not specified, the query cannot reference any database tables\&. For example, the following query is invalid: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT distributors\&.* WHERE distributors\&.name = \*(AqWestward\*(Aq; +.fi +.if n \{\ +.RE +.\} +.sp +PostgreSQL +releases prior to 8\&.1 would accept queries of this form, and add an implicit entry to the query\*(Aqs +FROM +clause for each table referenced by the query\&. This is no longer allowed\&. +.SS "Omitting the AS Key Word" +.PP +In the SQL standard, the optional key word +AS +can be omitted before an output column name whenever the new column name is a valid column name (that is, not the same as any reserved keyword)\&. +PostgreSQL +is slightly more restrictive: +AS +is required if the new column name matches any keyword at all, reserved or not\&. Recommended practice is to use +AS +or double\-quote output column names, to prevent any possible conflict against future keyword additions\&. +.PP +In +FROM +items, both the standard and +PostgreSQL +allow +AS +to be omitted before an alias that is an unreserved keyword\&. But this is impractical for output column names, because of syntactic ambiguities\&. +.SS "ONLY and Inheritance" +.PP +The SQL standard requires parentheses around the table name when writing +ONLY, for example +SELECT * FROM ONLY (tab1), ONLY (tab2) WHERE \&.\&.\&.\&. +PostgreSQL +considers these parentheses to be optional\&. +.PP + +PostgreSQL +allows a trailing +* +to be written to explicitly specify the non\-ONLY +behavior of including child tables\&. The standard does not allow this\&. +.PP +(These points apply equally to all SQL commands supporting the +ONLY +option\&.) +.SS "Namespace Available to GROUP BY and ORDER BY" +.PP +In the SQL\-92 standard, an +ORDER BY +clause can only use output column names or numbers, while a +GROUP BY +clause can only use expressions based on input column names\&. +PostgreSQL +extends each of these clauses to allow the other choice as well (but it uses the standard\*(Aqs interpretation if there is ambiguity)\&. +PostgreSQL +also allows both clauses to specify arbitrary expressions\&. Note that names appearing in an expression will always be taken as input\-column names, not as output\-column names\&. +.PP +SQL:1999 and later use a slightly different definition which is not entirely upward compatible with SQL\-92\&. In most cases, however, +PostgreSQL +will interpret an +ORDER BY +or +GROUP BY +expression the same way SQL:1999 does\&. +.SS "Functional Dependencies" +.PP + +PostgreSQL +recognizes functional dependency (allowing columns to be omitted from +GROUP BY) only when a table\*(Aqs primary key is included in the +GROUP BY +list\&. The SQL standard specifies additional conditions that should be recognized\&. +.SS "WINDOW Clause Restrictions" +.PP +The SQL standard provides additional options for the window +\fIframe_clause\fR\&. +PostgreSQL +currently supports only the options listed above\&. +.SS "LIMIT and OFFSET" +.PP +The clauses +LIMIT +and +OFFSET +are +PostgreSQL\-specific syntax, also used by +MySQL\&. The SQL:2008 standard has introduced the clauses +OFFSET \&.\&.\&. FETCH {FIRST|NEXT} \&.\&.\&. +for the same functionality, as shown above in +LIMIT Clause\&. This syntax is also used by +IBM DB2\&. (Applications written for +Oracle +frequently use a workaround involving the automatically generated +rownum +column, which is not available in PostgreSQL, to implement the effects of these clauses\&.) +.SS "FOR UPDATE and FOR SHARE" +.PP +Although +FOR UPDATE +appears in the SQL standard, the standard allows it only as an option of +\fBDECLARE CURSOR\fR\&. +PostgreSQL +allows it in any +\fBSELECT\fR +query as well as in sub\-\fBSELECT\fRs, but this is an extension\&. The +FOR SHARE +variant, and the +NOWAIT +option, do not appear in the standard\&. +.SS "Data\-Modifying Statements in WITH" +.PP + +PostgreSQL +allows +\fBINSERT\fR, +\fBUPDATE\fR, and +\fBDELETE\fR +to be used as +WITH +queries\&. This is not found in the SQL standard\&. +.SS "Nonstandard Clauses" +.PP +The clause +DISTINCT ON +is not defined in the SQL standard\&. diff --git a/doc/src/sgml/man7/SELECT_INTO.7 b/doc/src/sgml/man7/SELECT_INTO.7 new file mode 100644 index 000000000..2a0b85b72 --- /dev/null +++ b/doc/src/sgml/man7/SELECT_INTO.7 @@ -0,0 +1,148 @@ +'\" t +.\" Title: SELECT INTO +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SELECT INTO" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SELECT_INTO \- define a new table from the results of a query +.\" SELECT INTO +.SH "SYNOPSIS" +.sp +.nf +[ WITH [ RECURSIVE ] \fIwith_query\fR [, \&.\&.\&.] ] +SELECT [ ALL | DISTINCT [ ON ( \fIexpression\fR [, \&.\&.\&.] ) ] ] + * | \fIexpression\fR [ [ AS ] \fIoutput_name\fR ] [, \&.\&.\&.] + INTO [ TEMPORARY | TEMP | UNLOGGED ] [ TABLE ] \fInew_table\fR + [ FROM \fIfrom_item\fR [, \&.\&.\&.] ] + [ WHERE \fIcondition\fR ] + [ GROUP BY \fIexpression\fR [, \&.\&.\&.] ] + [ HAVING \fIcondition\fR [, \&.\&.\&.] ] + [ WINDOW \fIwindow_name\fR AS ( \fIwindow_definition\fR ) [, \&.\&.\&.] ] + [ { UNION | INTERSECT | EXCEPT } [ ALL | DISTINCT ] \fIselect\fR ] + [ ORDER BY \fIexpression\fR [ ASC | DESC | USING \fIoperator\fR ] [ NULLS { FIRST | LAST } ] [, \&.\&.\&.] ] + [ LIMIT { \fIcount\fR | ALL } ] + [ OFFSET \fIstart\fR [ ROW | ROWS ] ] + [ FETCH { FIRST | NEXT } [ \fIcount\fR ] { ROW | ROWS } ONLY ] + [ FOR { UPDATE | SHARE } [ OF \fItable_name\fR [, \&.\&.\&.] ] [ NOWAIT ] [\&.\&.\&.] ] +.fi +.SH "DESCRIPTION" +.PP + +\fBSELECT INTO\fR +creates a new table and fills it with data computed by a query\&. The data is not returned to the client, as it is with a normal +\fBSELECT\fR\&. The new table\*(Aqs columns have the names and data types associated with the output columns of the +\fBSELECT\fR\&. +.SH "PARAMETERS" +.PP +TEMPORARY or TEMP +.RS 4 +If specified, the table is created as a temporary table\&. Refer to +CREATE TABLE (\fBCREATE_TABLE\fR(7)) +for details\&. +.RE +.PP +UNLOGGED +.RS 4 +If specified, the table is created as an unlogged table\&. Refer to +CREATE TABLE (\fBCREATE_TABLE\fR(7)) +for details\&. +.RE +.PP +\fInew_table\fR +.RS 4 +The name (optionally schema\-qualified) of the table to be created\&. +.RE +.PP +All other parameters are described in detail under +\fBSELECT\fR(7)\&. +.SH "NOTES" +.PP + +CREATE TABLE AS (\fBCREATE_TABLE_AS\fR(7)) +is functionally similar to +\fBSELECT INTO\fR\&. +\fBCREATE TABLE AS\fR +is the recommended syntax, since this form of +\fBSELECT INTO\fR +is not available in +ECPG +or +PL/pgSQL, because they interpret the +INTO +clause differently\&. Furthermore, +\fBCREATE TABLE AS\fR +offers a superset of the functionality provided by +\fBSELECT INTO\fR\&. +.PP +Prior to +PostgreSQL +8\&.1, the table created by +\fBSELECT INTO\fR +included OIDs by default\&. In +PostgreSQL +8\&.1, this is not the case \(em to include OIDs in the new table, the +default_with_oids +configuration variable must be enabled\&. Alternatively, +\fBCREATE TABLE AS\fR +can be used with the +WITH OIDS +clause\&. +.SH "EXAMPLES" +.PP +Create a new table +films_recent +consisting of only recent entries from the table +films: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT * INTO films_recent FROM films WHERE date_prod >= \*(Aq2002\-01\-01\*(Aq; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +The SQL standard uses +\fBSELECT INTO\fR +to represent selecting values into scalar variables of a host program, rather than creating a new table\&. This indeed is the usage found in +ECPG +(see +Chapter 33, ECPG - Embedded SQL in C, in the documentation) and +PL/pgSQL +(see +Chapter 39, PL/pgSQL - SQL Procedural Language, in the documentation)\&. The +PostgreSQL +usage of +\fBSELECT INTO\fR +to represent table creation is historical\&. It is best to use +\fBCREATE TABLE AS\fR +for this purpose in new code\&. +.SH "SEE ALSO" +CREATE TABLE AS (\fBCREATE_TABLE_AS\fR(7)) diff --git a/doc/src/sgml/man7/SET.7 b/doc/src/sgml/man7/SET.7 new file mode 100644 index 000000000..56f162ed8 --- /dev/null +++ b/doc/src/sgml/man7/SET.7 @@ -0,0 +1,303 @@ +'\" t +.\" Title: SET +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SET" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SET \- change a run\-time parameter +.\" SET +.SH "SYNOPSIS" +.sp +.nf +SET [ SESSION | LOCAL ] \fIconfiguration_parameter\fR { TO | = } { \fIvalue\fR | \*(Aq\fIvalue\fR\*(Aq | DEFAULT } +SET [ SESSION | LOCAL ] TIME ZONE { \fItimezone\fR | LOCAL | DEFAULT } +.fi +.SH "DESCRIPTION" +.PP +The +\fBSET\fR +command changes run\-time configuration parameters\&. Many of the run\-time parameters listed in +Chapter 18, Server Configuration, in the documentation +can be changed on\-the\-fly with +\fBSET\fR\&. (But some require superuser privileges to change, and others cannot be changed after server or session start\&.) +\fBSET\fR +only affects the value used by the current session\&. +.PP +If +\fBSET\fR +(or equivalently +\fBSET SESSION\fR) is issued within a transaction that is later aborted, the effects of the +\fBSET\fR +command disappear when the transaction is rolled back\&. Once the surrounding transaction is committed, the effects will persist until the end of the session, unless overridden by another +\fBSET\fR\&. +.PP +The effects of +\fBSET LOCAL\fR +last only till the end of the current transaction, whether committed or not\&. A special case is +\fBSET\fR +followed by +\fBSET LOCAL\fR +within a single transaction: the +\fBSET LOCAL\fR +value will be seen until the end of the transaction, but afterwards (if the transaction is committed) the +\fBSET\fR +value will take effect\&. +.PP +The effects of +\fBSET\fR +or +\fBSET LOCAL\fR +are also canceled by rolling back to a savepoint that is earlier than the command\&. +.PP +If +\fBSET LOCAL\fR +is used within a function that has a +SET +option for the same variable (see +CREATE FUNCTION (\fBCREATE_FUNCTION\fR(7))), the effects of the +\fBSET LOCAL\fR +command disappear at function exit; that is, the value in effect when the function was called is restored anyway\&. This allows +\fBSET LOCAL\fR +to be used for dynamic or repeated changes of a parameter within a function, while still having the convenience of using the +SET +option to save and restore the caller\*(Aqs value\&. However, a regular +\fBSET\fR +command overrides any surrounding function\*(Aqs +SET +option; its effects will persist unless rolled back\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBNote\fR +.ps -1 +.br +.PP +In +PostgreSQL +versions 8\&.0 through 8\&.2, the effects of a +\fBSET LOCAL\fR +would be canceled by releasing an earlier savepoint, or by successful exit from a +PL/pgSQL +exception block\&. This behavior has been changed because it was deemed unintuitive\&. +.sp .5v +.RE +.SH "PARAMETERS" +.PP +SESSION +.RS 4 +Specifies that the command takes effect for the current session\&. (This is the default if neither +SESSION +nor +LOCAL +appears\&.) +.RE +.PP +LOCAL +.RS 4 +Specifies that the command takes effect for only the current transaction\&. After +\fBCOMMIT\fR +or +\fBROLLBACK\fR, the session\-level setting takes effect again\&. Note that +\fBSET LOCAL\fR +will appear to have no effect if it is executed outside a +\fBBEGIN\fR +block, since the transaction will end immediately\&. +.RE +.PP +\fIconfiguration_parameter\fR +.RS 4 +Name of a settable run\-time parameter\&. Available parameters are documented in +Chapter 18, Server Configuration, in the documentation +and below\&. +.RE +.PP +\fIvalue\fR +.RS 4 +New value of parameter\&. Values can be specified as string constants, identifiers, numbers, or comma\-separated lists of these, as appropriate for the particular parameter\&. +DEFAULT +can be written to specify resetting the parameter to its default value (that is, whatever value it would have had if no +\fBSET\fR +had been executed in the current session)\&. +.RE +.PP +Besides the configuration parameters documented in +Chapter 18, Server Configuration, in the documentation, there are a few that can only be adjusted using the +\fBSET\fR +command or that have a special syntax: +.PP +SCHEMA +.RS 4 +SET SCHEMA \*(Aq\fIvalue\fR\*(Aq +is an alias for +SET search_path TO \fIvalue\fR\&. Only one schema can be specified using this syntax\&. +.RE +.PP +NAMES +.RS 4 +SET NAMES \fIvalue\fR +is an alias for +SET client_encoding TO \fIvalue\fR\&. +.RE +.PP +SEED +.RS 4 +Sets the internal seed for the random number generator (the function +\fBrandom\fR)\&. Allowed values are floating\-point numbers between \-1 and 1, which are then multiplied by 231\-1\&. +.sp +The seed can also be set by invoking the function +\fBsetseed\fR: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT setseed(\fIvalue\fR); +.fi +.if n \{\ +.RE +.\} +.RE +.PP +TIME ZONE +.RS 4 +SET TIME ZONE \fIvalue\fR +is an alias for +SET timezone TO \fIvalue\fR\&. The syntax +SET TIME ZONE +allows special syntax for the time zone specification\&. Here are examples of valid values: +.PP +\*(AqPST8PDT\*(Aq +.RS 4 +The time zone for Berkeley, California\&. +.RE +.PP +\*(AqEurope/Rome\*(Aq +.RS 4 +The time zone for Italy\&. +.RE +.PP +\-7 +.RS 4 +The time zone 7 hours west from UTC (equivalent to PDT)\&. Positive values are east from UTC\&. +.RE +.PP +INTERVAL \*(Aq\-08:00\*(Aq HOUR TO MINUTE +.RS 4 +The time zone 8 hours west from UTC (equivalent to PST)\&. +.RE +.PP +LOCAL, DEFAULT +.RS 4 +Set the time zone to your local time zone (that is, the server\*(Aqs default value of +\fItimezone\fR)\&. +.RE +.sp +See +Section 8.5.3, \(lqTime Zones\(rq, in the documentation +for more information about time zones\&. +.RE +.SH "NOTES" +.PP +The function +\fBset_config\fR +provides equivalent functionality; see +Section 9.26, \(lqSystem Administration Functions\(rq, in the documentation\&. Also, it is possible to UPDATE the +pg_settings +system view to perform the equivalent of +\fBSET\fR\&. +.SH "EXAMPLES" +.PP +Set the schema search path: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SET search_path TO my_schema, public; +.fi +.if n \{\ +.RE +.\} +.PP +Set the style of date to traditional +POSTGRES +with +\(lqday before month\(rq +input convention: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SET datestyle TO postgres, dmy; +.fi +.if n \{\ +.RE +.\} +.PP +Set the time zone for Berkeley, California: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SET TIME ZONE \*(AqPST8PDT\*(Aq; +.fi +.if n \{\ +.RE +.\} +.PP +Set the time zone for Italy: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SET TIME ZONE \*(AqEurope/Rome\*(Aq; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +SET TIME ZONE +extends syntax defined in the SQL standard\&. The standard allows only numeric time zone offsets while +PostgreSQL +allows more flexible time\-zone specifications\&. All other +SET +features are +PostgreSQL +extensions\&. +.SH "SEE ALSO" +\fBRESET\fR(7), \fBSHOW\fR(7) diff --git a/doc/src/sgml/man7/SET_CONSTRAINTS.7 b/doc/src/sgml/man7/SET_CONSTRAINTS.7 new file mode 100644 index 000000000..8ef818bbf --- /dev/null +++ b/doc/src/sgml/man7/SET_CONSTRAINTS.7 @@ -0,0 +1,118 @@ +'\" t +.\" Title: SET CONSTRAINTS +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SET CONSTRAINTS" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SET_CONSTRAINTS \- set constraint check timing for the current transaction +.\" SET CONSTRAINTS +.SH "SYNOPSIS" +.sp +.nf +SET CONSTRAINTS { ALL | \fIname\fR [, \&.\&.\&.] } { DEFERRED | IMMEDIATE } +.fi +.SH "DESCRIPTION" +.PP + +\fBSET CONSTRAINTS\fR +sets the behavior of constraint checking within the current transaction\&. +IMMEDIATE +constraints are checked at the end of each statement\&. +DEFERRED +constraints are not checked until transaction commit\&. Each constraint has its own +IMMEDIATE +or +DEFERRED +mode\&. +.PP +Upon creation, a constraint is given one of three characteristics: +DEFERRABLE INITIALLY DEFERRED, +DEFERRABLE INITIALLY IMMEDIATE, or +NOT DEFERRABLE\&. The third class is always +IMMEDIATE +and is not affected by the +\fBSET CONSTRAINTS\fR +command\&. The first two classes start every transaction in the indicated mode, but their behavior can be changed within a transaction by +\fBSET CONSTRAINTS\fR\&. +.PP + +\fBSET CONSTRAINTS\fR +with a list of constraint names changes the mode of just those constraints (which must all be deferrable)\&. Each constraint name can be schema\-qualified\&. The current schema search path is used to find the first matching name if no schema name is specified\&. +\fBSET CONSTRAINTS ALL\fR +changes the mode of all deferrable constraints\&. +.PP +When +\fBSET CONSTRAINTS\fR +changes the mode of a constraint from +DEFERRED +to +IMMEDIATE, the new mode takes effect retroactively: any outstanding data modifications that would have been checked at the end of the transaction are instead checked during the execution of the +\fBSET CONSTRAINTS\fR +command\&. If any such constraint is violated, the +\fBSET CONSTRAINTS\fR +fails (and does not change the constraint mode)\&. Thus, +\fBSET CONSTRAINTS\fR +can be used to force checking of constraints to occur at a specific point in a transaction\&. +.PP +Currently, only +UNIQUE, +PRIMARY KEY, +REFERENCES +(foreign key), and +EXCLUDE +constraints are affected by this setting\&. +NOT NULL +and +CHECK +constraints are always checked immediately when a row is inserted or modified (\fInot\fR +at the end of the statement)\&. Uniqueness and exclusion constraints that have not been declared +DEFERRABLE +are also checked immediately\&. +.PP +The firing of triggers that are declared as +\(lqconstraint triggers\(rq +is also controlled by this setting \(em they fire at the same time that the associated constraint should be checked\&. +.SH "NOTES" +.PP +Because +PostgreSQL +does not require constraint names to be unique within a schema (but only per\-table), it is possible that there is more than one match for a specified constraint name\&. In this case +\fBSET CONSTRAINTS\fR +will act on all matches\&. For a non\-schema\-qualified name, once a match or matches have been found in some schema in the search path, schemas appearing later in the path are not searched\&. +.PP +This command only alters the behavior of constraints within the current transaction\&. Thus, if you execute this command outside of a transaction block (\fBBEGIN\fR/\fBCOMMIT\fR +pair), it will not appear to have any effect\&. +.SH "COMPATIBILITY" +.PP +This command complies with the behavior defined in the SQL standard, except for the limitation that, in +PostgreSQL, it does not apply to +NOT NULL +and +CHECK +constraints\&. Also, +PostgreSQL +checks non\-deferrable uniqueness constraints immediately, not at end of statement as the standard would suggest\&. diff --git a/doc/src/sgml/man7/SET_ROLE.7 b/doc/src/sgml/man7/SET_ROLE.7 new file mode 100644 index 000000000..6317ad790 --- /dev/null +++ b/doc/src/sgml/man7/SET_ROLE.7 @@ -0,0 +1,143 @@ +'\" t +.\" Title: SET ROLE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SET ROLE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SET_ROLE \- set the current user identifier of the current session +.\" SET ROLE +.SH "SYNOPSIS" +.sp +.nf +SET [ SESSION | LOCAL ] ROLE \fIrole_name\fR +SET [ SESSION | LOCAL ] ROLE NONE +RESET ROLE +.fi +.SH "DESCRIPTION" +.PP +This command sets the current user identifier of the current SQL session to be +\fIrole_name\fR\&. The role name can be written as either an identifier or a string literal\&. After +\fBSET ROLE\fR, permissions checking for SQL commands is carried out as though the named role were the one that had logged in originally\&. +.PP +The specified +\fIrole_name\fR +must be a role that the current session user is a member of\&. (If the session user is a superuser, any role can be selected\&.) +.PP +The +SESSION +and +LOCAL +modifiers act the same as for the regular +\fBSET\fR(7) +command\&. +.PP +The +NONE +and +RESET +forms reset the current user identifier to be the current session user identifier\&. These forms can be executed by any user\&. +.SH "NOTES" +.PP +Using this command, it is possible to either add privileges or restrict one\*(Aqs privileges\&. If the session user role has the +INHERITS +attribute, then it automatically has all the privileges of every role that it could +\fBSET ROLE\fR +to; in this case +\fBSET ROLE\fR +effectively drops all the privileges assigned directly to the session user and to the other roles it is a member of, leaving only the privileges available to the named role\&. On the other hand, if the session user role has the +NOINHERITS +attribute, +\fBSET ROLE\fR +drops the privileges assigned directly to the session user and instead acquires the privileges available to the named role\&. +.PP +In particular, when a superuser chooses to +\fBSET ROLE\fR +to a non\-superuser role, she loses her superuser privileges\&. +.PP + +\fBSET ROLE\fR +has effects comparable to +SET SESSION AUTHORIZATION (\fBSET_SESSION_AUTHORIZATION\fR(7)), but the privilege checks involved are quite different\&. Also, +\fBSET SESSION AUTHORIZATION\fR +determines which roles are allowable for later +\fBSET ROLE\fR +commands, whereas changing roles with +\fBSET ROLE\fR +does not change the set of roles allowed to a later +\fBSET ROLE\fR\&. +.PP + +\fBSET ROLE\fR +does not process session variables as specified by the role\*(Aqs +ALTER ROLE (\fBALTER_ROLE\fR(7)) +settings; this only happens during login\&. +.PP + +\fBSET ROLE\fR +cannot be used within a +SECURITY DEFINER +function\&. +.SH "EXAMPLES" +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT SESSION_USER, CURRENT_USER; + + session_user | current_user +\-\-\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\- + peter | peter + +SET ROLE \*(Aqpaul\*(Aq; + +SELECT SESSION_USER, CURRENT_USER; + + session_user | current_user +\-\-\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\- + peter | paul +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP + +PostgreSQL +allows identifier syntax ("rolename"), while the SQL standard requires the role name to be written as a string literal\&. SQL does not allow this command during a transaction; +PostgreSQL +does not make this restriction because there is no reason to\&. The +SESSION +and +LOCAL +modifiers are a +PostgreSQL +extension, as is the +RESET +syntax\&. +.SH "SEE ALSO" +SET SESSION AUTHORIZATION (\fBSET_SESSION_AUTHORIZATION\fR(7)) diff --git a/doc/src/sgml/man7/SET_SESSION_AUTHORIZATION.7 b/doc/src/sgml/man7/SET_SESSION_AUTHORIZATION.7 new file mode 100644 index 000000000..115e1507c --- /dev/null +++ b/doc/src/sgml/man7/SET_SESSION_AUTHORIZATION.7 @@ -0,0 +1,115 @@ +'\" t +.\" Title: SET SESSION AUTHORIZATION +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SET SESSION AUTHORIZATION" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SET_SESSION_AUTHORIZATION \- set the session user identifier and the current user identifier of the current session +.\" SET SESSION AUTHORIZATION +.SH "SYNOPSIS" +.sp +.nf +SET [ SESSION | LOCAL ] SESSION AUTHORIZATION \fIuser_name\fR +SET [ SESSION | LOCAL ] SESSION AUTHORIZATION DEFAULT +RESET SESSION AUTHORIZATION +.fi +.SH "DESCRIPTION" +.PP +This command sets the session user identifier and the current user identifier of the current SQL session to be +\fIuser_name\fR\&. The user name can be written as either an identifier or a string literal\&. Using this command, it is possible, for example, to temporarily become an unprivileged user and later switch back to being a superuser\&. +.PP +The session user identifier is initially set to be the (possibly authenticated) user name provided by the client\&. The current user identifier is normally equal to the session user identifier, but might change temporarily in the context of +SECURITY DEFINER +functions and similar mechanisms; it can also be changed by +SET ROLE (\fBSET_ROLE\fR(7))\&. The current user identifier is relevant for permission checking\&. +.PP +The session user identifier can be changed only if the initial session user (the +authenticated user) had the superuser privilege\&. Otherwise, the command is accepted only if it specifies the authenticated user name\&. +.PP +The +SESSION +and +LOCAL +modifiers act the same as for the regular +\fBSET\fR(7) +command\&. +.PP +The +DEFAULT +and +RESET +forms reset the session and current user identifiers to be the originally authenticated user name\&. These forms can be executed by any user\&. +.SH "NOTES" +.PP + +\fBSET SESSION AUTHORIZATION\fR +cannot be used within a +SECURITY DEFINER +function\&. +.SH "EXAMPLES" +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT SESSION_USER, CURRENT_USER; + + session_user | current_user +\-\-\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\- + peter | peter + +SET SESSION AUTHORIZATION \*(Aqpaul\*(Aq; + +SELECT SESSION_USER, CURRENT_USER; + + session_user | current_user +\-\-\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\- + paul | paul +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +The SQL standard allows some other expressions to appear in place of the literal +\fIuser_name\fR, but these options are not important in practice\&. +PostgreSQL +allows identifier syntax ("username"), which SQL does not\&. SQL does not allow this command during a transaction; +PostgreSQL +does not make this restriction because there is no reason to\&. The +SESSION +and +LOCAL +modifiers are a +PostgreSQL +extension, as is the +RESET +syntax\&. +.PP +The privileges necessary to execute this command are left implementation\-defined by the standard\&. +.SH "SEE ALSO" +SET ROLE (\fBSET_ROLE\fR(7)) diff --git a/doc/src/sgml/man7/SET_TRANSACTION.7 b/doc/src/sgml/man7/SET_TRANSACTION.7 new file mode 100644 index 000000000..b65bb274e --- /dev/null +++ b/doc/src/sgml/man7/SET_TRANSACTION.7 @@ -0,0 +1,237 @@ +'\" t +.\" Title: SET TRANSACTION +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SET TRANSACTION" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SET_TRANSACTION \- set the characteristics of the current transaction +.\" SET TRANSACTION +.\" transaction isolation level: setting +.\" read-only transaction: setting +.\" deferrable transaction: setting +.SH "SYNOPSIS" +.sp +.nf +SET TRANSACTION \fItransaction_mode\fR [, \&.\&.\&.] +SET TRANSACTION SNAPSHOT \fIsnapshot_id\fR +SET SESSION CHARACTERISTICS AS TRANSACTION \fItransaction_mode\fR [, \&.\&.\&.] + +where \fItransaction_mode\fR is one of: + + ISOLATION LEVEL { SERIALIZABLE | REPEATABLE READ | READ COMMITTED | READ UNCOMMITTED } + READ WRITE | READ ONLY + [ NOT ] DEFERRABLE +.fi +.SH "DESCRIPTION" +.PP +The +\fBSET TRANSACTION\fR +command sets the characteristics of the current transaction\&. It has no effect on any subsequent transactions\&. +\fBSET SESSION CHARACTERISTICS\fR +sets the default transaction characteristics for subsequent transactions of a session\&. These defaults can be overridden by +\fBSET TRANSACTION\fR +for an individual transaction\&. +.PP +The available transaction characteristics are the transaction isolation level, the transaction access mode (read/write or read\-only), and the deferrable mode\&. In addition, a snapshot can be selected, though only for the current transaction, not as a session default\&. +.PP +The isolation level of a transaction determines what data the transaction can see when other transactions are running concurrently: +.PP +READ COMMITTED +.RS 4 +A statement can only see rows committed before it began\&. This is the default\&. +.RE +.PP +REPEATABLE READ +.RS 4 +All statements of the current transaction can only see rows committed before the first query or data\-modification statement was executed in this transaction\&. +.RE +.PP +SERIALIZABLE +.RS 4 +All statements of the current transaction can only see rows committed before the first query or data\-modification statement was executed in this transaction\&. If a pattern of reads and writes among concurrent serializable transactions would create a situation which could not have occurred for any serial (one\-at\-a\-time) execution of those transactions, one of them will be rolled back with a +serialization_failure +error\&. +.RE +The SQL standard defines one additional level, +READ UNCOMMITTED\&. In +PostgreSQL +READ UNCOMMITTED +is treated as +READ COMMITTED\&. +.PP +The transaction isolation level cannot be changed after the first query or data\-modification statement (\fBSELECT\fR, +\fBINSERT\fR, +\fBDELETE\fR, +\fBUPDATE\fR, +\fBFETCH\fR, or +\fBCOPY\fR) of a transaction has been executed\&. See +Chapter 13, Concurrency Control, in the documentation +for more information about transaction isolation and concurrency control\&. +.PP +The transaction access mode determines whether the transaction is read/write or read\-only\&. Read/write is the default\&. When a transaction is read\-only, the following SQL commands are disallowed: +INSERT, +UPDATE, +DELETE, and +COPY FROM +if the table they would write to is not a temporary table; all +CREATE, +ALTER, and +DROP +commands; +COMMENT, +GRANT, +REVOKE, +TRUNCATE; and +EXPLAIN ANALYZE +and +EXECUTE +if the command they would execute is among those listed\&. This is a high\-level notion of read\-only that does not prevent all writes to disk\&. +.PP +The +DEFERRABLE +transaction property has no effect unless the transaction is also +SERIALIZABLE +and +READ ONLY\&. When all three of these properties are selected for a transaction, the transaction may block when first acquiring its snapshot, after which it is able to run without the normal overhead of a +SERIALIZABLE +transaction and without any risk of contributing to or being canceled by a serialization failure\&. This mode is well suited for long\-running reports or backups\&. +.PP +The +SET TRANSACTION SNAPSHOT +command allows a new transaction to run with the same +snapshot +as an existing transaction\&. The pre\-existing transaction must have exported its snapshot with the +pg_export_snapshot +function (see +Section 9.26.5, \(lqSnapshot Synchronization Functions\(rq, in the documentation)\&. That function returns a snapshot identifier, which must be given to +SET TRANSACTION SNAPSHOT +to specify which snapshot is to be imported\&. The identifier must be written as a string literal in this command, for example +\*(Aq000003A1\-1\*(Aq\&. +SET TRANSACTION SNAPSHOT +can only be executed at the start of a transaction, before the first query or data\-modification statement (\fBSELECT\fR, +\fBINSERT\fR, +\fBDELETE\fR, +\fBUPDATE\fR, +\fBFETCH\fR, or +\fBCOPY\fR) of the transaction\&. Furthermore, the transaction must already be set to +SERIALIZABLE +or +REPEATABLE READ +isolation level (otherwise, the snapshot would be discarded immediately, since +READ COMMITTED +mode takes a new snapshot for each command)\&. If the importing transaction uses +SERIALIZABLE +isolation level, then the transaction that exported the snapshot must also use that isolation level\&. Also, a non\-read\-only serializable transaction cannot import a snapshot from a read\-only transaction\&. +.SH "NOTES" +.PP +If +\fBSET TRANSACTION\fR +is executed without a prior +\fBSTART TRANSACTION\fR +or +\fBBEGIN\fR, it will appear to have no effect, since the transaction will immediately end\&. +.PP +It is possible to dispense with +\fBSET TRANSACTION\fR +by instead specifying the desired +\fItransaction_modes\fR +in +\fBBEGIN\fR +or +\fBSTART TRANSACTION\fR\&. But that option is not available for +\fBSET TRANSACTION SNAPSHOT\fR\&. +.PP +The session default transaction modes can also be set by setting the configuration parameters +default_transaction_isolation, +default_transaction_read_only, and +default_transaction_deferrable\&. (In fact +\fBSET SESSION CHARACTERISTICS\fR +is just a verbose equivalent for setting these variables with +\fBSET\fR\&.) This means the defaults can be set in the configuration file, via +\fBALTER DATABASE\fR, etc\&. Consult +Chapter 18, Server Configuration, in the documentation +for more information\&. +.SH "EXAMPLES" +.PP +To begin a new transaction with the same snapshot as an already existing transaction, first export the snapshot from the existing transaction\&. That will return the snapshot identifier, for example: +.sp +.if n \{\ +.RS 4 +.\} +.nf +BEGIN TRANSACTION ISOLATION LEVEL REPEATABLE READ; +SELECT pg_export_snapshot(); + pg_export_snapshot +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + 000003A1\-1 +(1 row) +.fi +.if n \{\ +.RE +.\} +.sp +Then give the snapshot identifier in a +\fBSET TRANSACTION SNAPSHOT\fR +command at the beginning of the newly opened transaction: +.sp +.if n \{\ +.RS 4 +.\} +.nf +BEGIN TRANSACTION ISOLATION LEVEL REPEATABLE READ; +SET TRANSACTION SNAPSHOT \*(Aq000003A1\-1\*(Aq; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +These commands are defined in the +SQL +standard, except for the +DEFERRABLE +transaction mode and the +\fBSET TRANSACTION SNAPSHOT\fR +form, which are +PostgreSQL +extensions\&. +.PP + +SERIALIZABLE +is the default transaction isolation level in the standard\&. In +PostgreSQL +the default is ordinarily +READ COMMITTED, but you can change it as mentioned above\&. +.PP +In the SQL standard, there is one other transaction characteristic that can be set with these commands: the size of the diagnostics area\&. This concept is specific to embedded SQL, and therefore is not implemented in the +PostgreSQL +server\&. +.PP +The SQL standard requires commas between successive +\fItransaction_modes\fR, but for historical reasons +PostgreSQL +allows the commas to be omitted\&. diff --git a/doc/src/sgml/man7/SHOW.7 b/doc/src/sgml/man7/SHOW.7 new file mode 100644 index 000000000..a1430b247 --- /dev/null +++ b/doc/src/sgml/man7/SHOW.7 @@ -0,0 +1,169 @@ +'\" t +.\" Title: SHOW +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "SHOW" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +SHOW \- show the value of a run\-time parameter +.\" SHOW +.SH "SYNOPSIS" +.sp +.nf +SHOW \fIname\fR +SHOW ALL +.fi +.SH "DESCRIPTION" +.PP + +\fBSHOW\fR +will display the current setting of run\-time parameters\&. These variables can be set using the +\fBSET\fR +statement, by editing the +postgresql\&.conf +configuration file, through the +\fBPGOPTIONS\fR +environmental variable (when using +libpq +or a +libpq\-based application), or through command\-line flags when starting the +\fBpostgres\fR +server\&. See +Chapter 18, Server Configuration, in the documentation +for details\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name of a run\-time parameter\&. Available parameters are documented in +Chapter 18, Server Configuration, in the documentation +and on the +\fBSET\fR(7) +reference page\&. In addition, there are a few parameters that can be shown but not set: +.PP +SERVER_VERSION +.RS 4 +Shows the server\*(Aqs version number\&. +.RE +.PP +SERVER_ENCODING +.RS 4 +Shows the server\-side character set encoding\&. At present, this parameter can be shown but not set, because the encoding is determined at database creation time\&. +.RE +.PP +LC_COLLATE +.RS 4 +Shows the database\*(Aqs locale setting for collation (text ordering)\&. At present, this parameter can be shown but not set, because the setting is determined at database creation time\&. +.RE +.PP +LC_CTYPE +.RS 4 +Shows the database\*(Aqs locale setting for character classification\&. At present, this parameter can be shown but not set, because the setting is determined at database creation time\&. +.RE +.PP +IS_SUPERUSER +.RS 4 +True if the current role has superuser privileges\&. +.RE +.RE +.PP +ALL +.RS 4 +Show the values of all configuration parameters, with descriptions\&. +.RE +.SH "NOTES" +.PP +The function +\fBcurrent_setting\fR +produces equivalent output; see +Section 9.26, \(lqSystem Administration Functions\(rq, in the documentation\&. Also, the +pg_settings +system view produces the same information\&. +.SH "EXAMPLES" +.PP +Show the current setting of the parameter +\fIDateStyle\fR: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SHOW DateStyle; + DateStyle +\-\-\-\-\-\-\-\-\-\-\- + ISO, MDY +(1 row) +.fi +.if n \{\ +.RE +.\} +.PP +Show the current setting of the parameter +\fIgeqo\fR: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SHOW geqo; + geqo +\-\-\-\-\-\- + on +(1 row) +.fi +.if n \{\ +.RE +.\} +.PP +Show all settings: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SHOW ALL; + name | setting | description +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + allow_system_table_mods | off | Allows modifications of the structure of \&.\&.\&. + \&. + \&. + \&. + xmloption | content | Sets whether XML data in implicit parsing \&.\&.\&. + zero_damaged_pages | off | Continues processing past damaged page headers\&. +(196 rows) +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +The +\fBSHOW\fR +command is a +PostgreSQL +extension\&. +.SH "SEE ALSO" +\fBSET\fR(7), \fBRESET\fR(7) diff --git a/doc/src/sgml/man7/START_TRANSACTION.7 b/doc/src/sgml/man7/START_TRANSACTION.7 new file mode 100644 index 000000000..f2381b7ea --- /dev/null +++ b/doc/src/sgml/man7/START_TRANSACTION.7 @@ -0,0 +1,84 @@ +'\" t +.\" Title: START TRANSACTION +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "START TRANSACTION" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +START_TRANSACTION \- start a transaction block +.\" START TRANSACTION +.SH "SYNOPSIS" +.sp +.nf +START TRANSACTION [ \fItransaction_mode\fR [, \&.\&.\&.] ] + +where \fItransaction_mode\fR is one of: + + ISOLATION LEVEL { SERIALIZABLE | REPEATABLE READ | READ COMMITTED | READ UNCOMMITTED } + READ WRITE | READ ONLY + [ NOT ] DEFERRABLE +.fi +.SH "DESCRIPTION" +.PP +This command begins a new transaction block\&. If the isolation level, read/write mode, or deferrable mode is specified, the new transaction has those characteristics, as if +SET TRANSACTION (\fBSET_TRANSACTION\fR(7)) +was executed\&. This is the same as the +\fBBEGIN\fR(7) +command\&. +.SH "PARAMETERS" +.PP +Refer to +SET TRANSACTION (\fBSET_TRANSACTION\fR(7)) +for information on the meaning of the parameters to this statement\&. +.SH "COMPATIBILITY" +.PP +In the standard, it is not necessary to issue +\fBSTART TRANSACTION\fR +to start a transaction block: any SQL command implicitly begins a block\&. +PostgreSQL\*(Aqs behavior can be seen as implicitly issuing a +\fBCOMMIT\fR +after each command that does not follow +\fBSTART TRANSACTION\fR +(or +\fBBEGIN\fR), and it is therefore often called +\(lqautocommit\(rq\&. Other relational database systems might offer an autocommit feature as a convenience\&. +.PP +The +DEFERRABLE +\fItransaction_mode\fR +is a +PostgreSQL +language extension\&. +.PP +The SQL standard requires commas between successive +\fItransaction_modes\fR, but for historical reasons +PostgreSQL +allows the commas to be omitted\&. +.PP +See also the compatibility section of +SET TRANSACTION (\fBSET_TRANSACTION\fR(7))\&. +.SH "SEE ALSO" +\fBBEGIN\fR(7), \fBCOMMIT\fR(7), \fBROLLBACK\fR(7), \fBSAVEPOINT\fR(7), SET TRANSACTION (\fBSET_TRANSACTION\fR(7)) diff --git a/doc/src/sgml/man7/TABLE.7 b/doc/src/sgml/man7/TABLE.7 new file mode 100644 index 000000000..8e9105d2d --- /dev/null +++ b/doc/src/sgml/man7/TABLE.7 @@ -0,0 +1 @@ +.so man7/SELECT.7 diff --git a/doc/src/sgml/man7/TRUNCATE.7 b/doc/src/sgml/man7/TRUNCATE.7 new file mode 100644 index 000000000..e47d559be --- /dev/null +++ b/doc/src/sgml/man7/TRUNCATE.7 @@ -0,0 +1,206 @@ +'\" t +.\" Title: TRUNCATE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "TRUNCATE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +TRUNCATE \- empty a table or set of tables +.\" TRUNCATE +.SH "SYNOPSIS" +.sp +.nf +TRUNCATE [ TABLE ] [ ONLY ] \fIname\fR [ * ] [, \&.\&.\&. ] + [ RESTART IDENTITY | CONTINUE IDENTITY ] [ CASCADE | RESTRICT ] +.fi +.SH "DESCRIPTION" +.PP + +\fBTRUNCATE\fR +quickly removes all rows from a set of tables\&. It has the same effect as an unqualified +\fBDELETE\fR +on each table, but since it does not actually scan the tables it is faster\&. Furthermore, it reclaims disk space immediately, rather than requiring a subsequent +\fBVACUUM\fR +operation\&. This is most useful on large tables\&. +.SH "PARAMETERS" +.PP +\fIname\fR +.RS 4 +The name (optionally schema\-qualified) of a table to truncate\&. If +ONLY +is specified before the table name, only that table is truncated\&. If +ONLY +is not specified, the table and all its descendant tables (if any) are truncated\&. Optionally, +* +can be specified after the table name to explicitly indicate that descendant tables are included\&. +.RE +.PP +RESTART IDENTITY +.RS 4 +Automatically restart sequences owned by columns of the truncated table(s)\&. +.RE +.PP +CONTINUE IDENTITY +.RS 4 +Do not change the values of sequences\&. This is the default\&. +.RE +.PP +CASCADE +.RS 4 +Automatically truncate all tables that have foreign\-key references to any of the named tables, or to any tables added to the group due to +CASCADE\&. +.RE +.PP +RESTRICT +.RS 4 +Refuse to truncate if any of the tables have foreign\-key references from tables that are not listed in the command\&. This is the default\&. +.RE +.SH "NOTES" +.PP +You must have the +TRUNCATE +privilege on a table to truncate it\&. +.PP + +\fBTRUNCATE\fR +acquires an +ACCESS EXCLUSIVE +lock on each table it operates on, which blocks all other concurrent operations on the table\&. When +RESTART IDENTITY +is specified, any sequences that are to be restarted are likewise locked exclusively\&. If concurrent access to a table is required, then the +\fBDELETE\fR +command should be used instead\&. +.PP + +\fBTRUNCATE\fR +cannot be used on a table that has foreign\-key references from other tables, unless all such tables are also truncated in the same command\&. Checking validity in such cases would require table scans, and the whole point is not to do one\&. The +CASCADE +option can be used to automatically include all dependent tables \(em but be very careful when using this option, or else you might lose data you did not intend to! +.PP + +\fBTRUNCATE\fR +will not fire any +ON DELETE +triggers that might exist for the tables\&. But it will fire +ON TRUNCATE +triggers\&. If +ON TRUNCATE +triggers are defined for any of the tables, then all +BEFORE TRUNCATE +triggers are fired before any truncation happens, and all +AFTER TRUNCATE +triggers are fired after the last truncation is performed and any sequences are reset\&. The triggers will fire in the order that the tables are to be processed (first those listed in the command, and then any that were added due to cascading)\&. +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBWarning\fR +.ps -1 +.br +.PP + +\fBTRUNCATE\fR +is not MVCC\-safe (see +Chapter 13, Concurrency Control, in the documentation +for general information about MVCC)\&. After truncation, the table will appear empty to all concurrent transactions, even if they are using a snapshot taken before the truncation occurred\&. This will only be an issue for a transaction that did not access the truncated table before the truncation happened \(em any transaction that has done so would hold at least an +ACCESS SHARE +lock, which would block +\fBTRUNCATE\fR +until that transaction completes\&. So truncation will not cause any apparent inconsistency in the table contents for successive queries on the same table, but it could cause visible inconsistency between the contents of the truncated table and other tables in the database\&. +.sp .5v +.RE +.PP + +\fBTRUNCATE\fR +is transaction\-safe with respect to the data in the tables: the truncation will be safely rolled back if the surrounding transaction does not commit\&. +.PP +When +RESTART IDENTITY +is specified, the implied +\fBALTER SEQUENCE RESTART\fR +operations are also done transactionally; that is, they will be rolled back if the surrounding transaction does not commit\&. This is unlike the normal behavior of +\fBALTER SEQUENCE RESTART\fR\&. Be aware that if any additional sequence operations are done on the restarted sequences before the transaction rolls back, the effects of these operations on the sequences will be rolled back, but not their effects on +\fBcurrval()\fR; that is, after the transaction +\fBcurrval()\fR +will continue to reflect the last sequence value obtained inside the failed transaction, even though the sequence itself may no longer be consistent with that\&. This is similar to the usual behavior of +\fBcurrval()\fR +after a failed transaction\&. +.SH "EXAMPLES" +.PP +Truncate the tables +bigtable +and +fattable: +.sp +.if n \{\ +.RS 4 +.\} +.nf +TRUNCATE bigtable, fattable; +.fi +.if n \{\ +.RE +.\} +.PP +The same, and also reset any associated sequence generators: +.sp +.if n \{\ +.RS 4 +.\} +.nf +TRUNCATE bigtable, fattable RESTART IDENTITY; +.fi +.if n \{\ +.RE +.\} +.PP +Truncate the table +othertable, and cascade to any tables that reference +othertable +via foreign\-key constraints: +.sp +.if n \{\ +.RS 4 +.\} +.nf +TRUNCATE othertable CASCADE; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +The SQL:2008 standard includes a +\fBTRUNCATE\fR +command with the syntax +TRUNCATE TABLE \fItablename\fR\&. The clauses +CONTINUE IDENTITY/RESTART IDENTITY +also appear in that standard, but have slightly different though related meanings\&. Some of the concurrency behavior of this command is left implementation\-defined by the standard, so the above notes should be considered and compared with other implementations if necessary\&. diff --git a/doc/src/sgml/man7/UNLISTEN.7 b/doc/src/sgml/man7/UNLISTEN.7 new file mode 100644 index 000000000..00c1c5458 --- /dev/null +++ b/doc/src/sgml/man7/UNLISTEN.7 @@ -0,0 +1,120 @@ +'\" t +.\" Title: UNLISTEN +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "UNLISTEN" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +UNLISTEN \- stop listening for a notification +.\" UNLISTEN +.SH "SYNOPSIS" +.sp +.nf +UNLISTEN { \fIchannel\fR | * } +.fi +.SH "DESCRIPTION" +.PP + +\fBUNLISTEN\fR +is used to remove an existing registration for +\fBNOTIFY\fR +events\&. +\fBUNLISTEN\fR +cancels any existing registration of the current +PostgreSQL +session as a listener on the notification channel named +\fIchannel\fR\&. The special wildcard +* +cancels all listener registrations for the current session\&. +.PP + +\fBNOTIFY\fR(7) +contains a more extensive discussion of the use of +\fBLISTEN\fR +and +\fBNOTIFY\fR\&. +.SH "PARAMETERS" +.PP +\fIchannel\fR +.RS 4 +Name of a notification channel (any identifier)\&. +.RE +.PP +* +.RS 4 +All current listen registrations for this session are cleared\&. +.RE +.SH "NOTES" +.PP +You can unlisten something you were not listening for; no warning or error will appear\&. +.PP +At the end of each session, +\fBUNLISTEN *\fR +is automatically executed\&. +.PP +A transaction that has executed +\fBUNLISTEN\fR +cannot be prepared for two\-phase commit\&. +.SH "EXAMPLES" +.PP +To make a registration: +.sp +.if n \{\ +.RS 4 +.\} +.nf +LISTEN virtual; +NOTIFY virtual; +Asynchronous notification "virtual" received from server process with PID 8448\&. +.fi +.if n \{\ +.RE +.\} +.PP +Once +\fBUNLISTEN\fR +has been executed, further +\fBNOTIFY\fR +messages will be ignored: +.sp +.if n \{\ +.RS 4 +.\} +.nf +UNLISTEN virtual; +NOTIFY virtual; +\-\- no NOTIFY event is received +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBUNLISTEN\fR +command in the SQL standard\&. +.SH "SEE ALSO" +\fBLISTEN\fR(7), \fBNOTIFY\fR(7) diff --git a/doc/src/sgml/man7/UPDATE.7 b/doc/src/sgml/man7/UPDATE.7 new file mode 100644 index 000000000..ddcae9872 --- /dev/null +++ b/doc/src/sgml/man7/UPDATE.7 @@ -0,0 +1,392 @@ +'\" t +.\" Title: UPDATE +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "UPDATE" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +UPDATE \- update rows of a table +.\" UPDATE +.SH "SYNOPSIS" +.sp +.nf +[ WITH [ RECURSIVE ] \fIwith_query\fR [, \&.\&.\&.] ] +UPDATE [ ONLY ] \fItable_name\fR [ * ] [ [ AS ] \fIalias\fR ] + SET { \fIcolumn_name\fR = { \fIexpression\fR | DEFAULT } | + ( \fIcolumn_name\fR [, \&.\&.\&.] ) = ( { \fIexpression\fR | DEFAULT } [, \&.\&.\&.] ) } [, \&.\&.\&.] + [ FROM \fIfrom_list\fR ] + [ WHERE \fIcondition\fR | WHERE CURRENT OF \fIcursor_name\fR ] + [ RETURNING * | \fIoutput_expression\fR [ [ AS ] \fIoutput_name\fR ] [, \&.\&.\&.] ] +.fi +.SH "DESCRIPTION" +.PP + +\fBUPDATE\fR +changes the values of the specified columns in all rows that satisfy the condition\&. Only the columns to be modified need be mentioned in the +SET +clause; columns not explicitly modified retain their previous values\&. +.PP +There are two ways to modify a table using information contained in other tables in the database: using sub\-selects, or specifying additional tables in the +FROM +clause\&. Which technique is more appropriate depends on the specific circumstances\&. +.PP +The optional +RETURNING +clause causes +\fBUPDATE\fR +to compute and return value(s) based on each row actually updated\&. Any expression using the table\*(Aqs columns, and/or columns of other tables mentioned in +FROM, can be computed\&. The new (post\-update) values of the table\*(Aqs columns are used\&. The syntax of the +RETURNING +list is identical to that of the output list of +\fBSELECT\fR\&. +.PP +You must have the +UPDATE +privilege on the table, or at least on the column(s) that are listed to be updated\&. You must also have the +SELECT +privilege on any column whose values are read in the +\fIexpressions\fR +or +\fIcondition\fR\&. +.SH "PARAMETERS" +.PP +\fIwith_query\fR +.RS 4 +The +WITH +clause allows you to specify one or more subqueries that can be referenced by name in the +\fBUPDATE\fR +query\&. See +Section 7.8, \(lqWITH Queries (Common Table Expressions)\(rq, in the documentation +and +\fBSELECT\fR(7) +for details\&. +.RE +.PP +\fItable_name\fR +.RS 4 +The name (optionally schema\-qualified) of the table to update\&. If +ONLY +is specified before the table name, matching rows are updated in the named table only\&. If +ONLY +is not specified, matching rows are also updated in any tables inheriting from the named table\&. Optionally, +* +can be specified after the table name to explicitly indicate that descendant tables are included\&. +.RE +.PP +\fIalias\fR +.RS 4 +A substitute name for the target table\&. When an alias is provided, it completely hides the actual name of the table\&. For example, given +UPDATE foo AS f, the remainder of the +\fBUPDATE\fR +statement must refer to this table as +f +not +foo\&. +.RE +.PP +\fIcolumn_name\fR +.RS 4 +The name of a column in the table named by +\fItable_name\fR\&. The column name can be qualified with a subfield name or array subscript, if needed\&. Do not include the table\*(Aqs name in the specification of a target column \(em for example, +UPDATE tab SET tab\&.col = 1 +is invalid\&. +.RE +.PP +\fIexpression\fR +.RS 4 +An expression to assign to the column\&. The expression can use the old values of this and other columns in the table\&. +.RE +.PP +DEFAULT +.RS 4 +Set the column to its default value (which will be NULL if no specific default expression has been assigned to it)\&. +.RE +.PP +\fIfrom_list\fR +.RS 4 +A list of table expressions, allowing columns from other tables to appear in the +WHERE +condition and the update expressions\&. This is similar to the list of tables that can be specified in the +FROM Clause +of a +\fBSELECT\fR +statement\&. Note that the target table must not appear in the +\fIfrom_list\fR, unless you intend a self\-join (in which case it must appear with an alias in the +\fIfrom_list\fR)\&. +.RE +.PP +\fIcondition\fR +.RS 4 +An expression that returns a value of type +boolean\&. Only rows for which this expression returns +true +will be updated\&. +.RE +.PP +\fIcursor_name\fR +.RS 4 +The name of the cursor to use in a +WHERE CURRENT OF +condition\&. The row to be updated is the one most recently fetched from this cursor\&. The cursor must be a non\-grouping query on the +\fBUPDATE\fR\*(Aqs target table\&. Note that +WHERE CURRENT OF +cannot be specified together with a Boolean condition\&. See +\fBDECLARE\fR(7) +for more information about using cursors with +WHERE CURRENT OF\&. +.RE +.PP +\fIoutput_expression\fR +.RS 4 +An expression to be computed and returned by the +\fBUPDATE\fR +command after each row is updated\&. The expression can use any column names of the table named by +\fItable_name\fR +or table(s) listed in +FROM\&. Write +* +to return all columns\&. +.RE +.PP +\fIoutput_name\fR +.RS 4 +A name to use for a returned column\&. +.RE +.SH "OUTPUTS" +.PP +On successful completion, an +\fBUPDATE\fR +command returns a command tag of the form +.sp +.if n \{\ +.RS 4 +.\} +.nf +UPDATE \fIcount\fR +.fi +.if n \{\ +.RE +.\} +.sp +The +\fIcount\fR +is the number of rows updated, including matched rows whose values did not change\&. Note that the number may be less than the number of rows that matched the +\fIcondition\fR +when updates were suppressed by a +BEFORE UPDATE +trigger\&. If +\fIcount\fR +is 0, no rows were updated by the query (this is not considered an error)\&. +.PP +If the +\fBUPDATE\fR +command contains a +RETURNING +clause, the result will be similar to that of a +\fBSELECT\fR +statement containing the columns and values defined in the +RETURNING +list, computed over the row(s) updated by the command\&. +.SH "NOTES" +.PP +When a +FROM +clause is present, what essentially happens is that the target table is joined to the tables mentioned in the +\fIfrom_list\fR, and each output row of the join represents an update operation for the target table\&. When using +FROM +you should ensure that the join produces at most one output row for each row to be modified\&. In other words, a target row shouldn\*(Aqt join to more than one row from the other table(s)\&. If it does, then only one of the join rows will be used to update the target row, but which one will be used is not readily predictable\&. +.PP +Because of this indeterminacy, referencing other tables only within sub\-selects is safer, though often harder to read and slower than using a join\&. +.SH "EXAMPLES" +.PP +Change the word +Drama +to +Dramatic +in the column +kind +of the table +films: +.sp +.if n \{\ +.RS 4 +.\} +.nf +UPDATE films SET kind = \*(AqDramatic\*(Aq WHERE kind = \*(AqDrama\*(Aq; +.fi +.if n \{\ +.RE +.\} +.PP +Adjust temperature entries and reset precipitation to its default value in one row of the table +weather: +.sp +.if n \{\ +.RS 4 +.\} +.nf +UPDATE weather SET temp_lo = temp_lo+1, temp_hi = temp_lo+15, prcp = DEFAULT + WHERE city = \*(AqSan Francisco\*(Aq AND date = \*(Aq2003\-07\-03\*(Aq; +.fi +.if n \{\ +.RE +.\} +.PP +Perform the same operation and return the updated entries: +.sp +.if n \{\ +.RS 4 +.\} +.nf +UPDATE weather SET temp_lo = temp_lo+1, temp_hi = temp_lo+15, prcp = DEFAULT + WHERE city = \*(AqSan Francisco\*(Aq AND date = \*(Aq2003\-07\-03\*(Aq + RETURNING temp_lo, temp_hi, prcp; +.fi +.if n \{\ +.RE +.\} +.PP +Use the alternative column\-list syntax to do the same update: +.sp +.if n \{\ +.RS 4 +.\} +.nf +UPDATE weather SET (temp_lo, temp_hi, prcp) = (temp_lo+1, temp_lo+15, DEFAULT) + WHERE city = \*(AqSan Francisco\*(Aq AND date = \*(Aq2003\-07\-03\*(Aq; +.fi +.if n \{\ +.RE +.\} +.PP +Increment the sales count of the salesperson who manages the account for Acme Corporation, using the +FROM +clause syntax: +.sp +.if n \{\ +.RS 4 +.\} +.nf +UPDATE employees SET sales_count = sales_count + 1 FROM accounts + WHERE accounts\&.name = \*(AqAcme Corporation\*(Aq + AND employees\&.id = accounts\&.sales_person; +.fi +.if n \{\ +.RE +.\} +.PP +Perform the same operation, using a sub\-select in the +WHERE +clause: +.sp +.if n \{\ +.RS 4 +.\} +.nf +UPDATE employees SET sales_count = sales_count + 1 WHERE id = + (SELECT sales_person FROM accounts WHERE name = \*(AqAcme Corporation\*(Aq); +.fi +.if n \{\ +.RE +.\} +.PP +Attempt to insert a new stock item along with the quantity of stock\&. If the item already exists, instead update the stock count of the existing item\&. To do this without failing the entire transaction, use savepoints: +.sp +.if n \{\ +.RS 4 +.\} +.nf +BEGIN; +\-\- other operations +SAVEPOINT sp1; +INSERT INTO wines VALUES(\*(AqChateau Lafite 2003\*(Aq, \*(Aq24\*(Aq); +\-\- Assume the above fails because of a unique key violation, +\-\- so now we issue these commands: +ROLLBACK TO sp1; +UPDATE wines SET stock = stock + 24 WHERE winename = \*(AqChateau Lafite 2003\*(Aq; +\-\- continue with other operations, and eventually +COMMIT; +.fi +.if n \{\ +.RE +.\} +.PP +Change the +kind +column of the table +films +in the row on which the cursor +c_films +is currently positioned: +.sp +.if n \{\ +.RS 4 +.\} +.nf +UPDATE films SET kind = \*(AqDramatic\*(Aq WHERE CURRENT OF c_films; +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +This command conforms to the +SQL +standard, except that the +FROM +and +RETURNING +clauses are +PostgreSQL +extensions, as is the ability to use +WITH +with +\fBUPDATE\fR\&. +.PP +According to the standard, the column\-list syntax should allow a list of columns to be assigned from a single row\-valued expression, such as a sub\-select: +.sp +.if n \{\ +.RS 4 +.\} +.nf +UPDATE accounts SET (contact_last_name, contact_first_name) = + (SELECT last_name, first_name FROM salesmen + WHERE salesmen\&.id = accounts\&.sales_id); +.fi +.if n \{\ +.RE +.\} +.sp +This is not currently implemented \(em the source must be a list of independent expressions\&. +.PP +Some other database systems offer a +FROM +option in which the target table is supposed to be listed again within +FROM\&. That is not how +PostgreSQL +interprets +FROM\&. Be careful when porting applications that use this extension\&. diff --git a/doc/src/sgml/man7/VACUUM.7 b/doc/src/sgml/man7/VACUUM.7 new file mode 100644 index 000000000..cbd81212b --- /dev/null +++ b/doc/src/sgml/man7/VACUUM.7 @@ -0,0 +1,224 @@ +'\" t +.\" Title: VACUUM +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "VACUUM" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +VACUUM \- garbage\-collect and optionally analyze a database +.\" VACUUM +.SH "SYNOPSIS" +.sp +.nf +VACUUM [ ( { FULL | FREEZE | VERBOSE | ANALYZE } [, \&.\&.\&.] ) ] [ \fItable_name\fR [ (\fIcolumn_name\fR [, \&.\&.\&.] ) ] ] +VACUUM [ FULL ] [ FREEZE ] [ VERBOSE ] [ \fItable_name\fR ] +VACUUM [ FULL ] [ FREEZE ] [ VERBOSE ] ANALYZE [ \fItable_name\fR [ (\fIcolumn_name\fR [, \&.\&.\&.] ) ] ] +.fi +.SH "DESCRIPTION" +.PP + +\fBVACUUM\fR +reclaims storage occupied by dead tuples\&. In normal +PostgreSQL +operation, tuples that are deleted or obsoleted by an update are not physically removed from their table; they remain present until a +\fBVACUUM\fR +is done\&. Therefore it\*(Aqs necessary to do +\fBVACUUM\fR +periodically, especially on frequently\-updated tables\&. +.PP +With no parameter, +\fBVACUUM\fR +processes every table in the current database that the current user has permission to vacuum\&. With a parameter, +\fBVACUUM\fR +processes only that table\&. +.PP + +\fBVACUUM ANALYZE\fR +performs a +\fBVACUUM\fR +and then an +\fBANALYZE\fR +for each selected table\&. This is a handy combination form for routine maintenance scripts\&. See +\fBANALYZE\fR(7) +for more details about its processing\&. +.PP +Plain +\fBVACUUM\fR +(without +FULL) simply reclaims space and makes it available for re\-use\&. This form of the command can operate in parallel with normal reading and writing of the table, as an exclusive lock is not obtained\&. However, extra space is not returned to the operating system (in most cases); it\*(Aqs just kept available for re\-use within the same table\&. +\fBVACUUM FULL\fR +rewrites the entire contents of the table into a new disk file with no extra space, allowing unused space to be returned to the operating system\&. This form is much slower and requires an exclusive lock on each table while it is being processed\&. +.PP +When the option list is surrounded by parentheses, the options can be written in any order\&. Without parentheses, options must be specified in exactly the order shown above\&. The parenthesized syntax was added in +PostgreSQL +9\&.0; the unparenthesized syntax is deprecated\&. +.SH "PARAMETERS" +.PP +FULL +.RS 4 +Selects +\(lqfull\(rq +vacuum, which can reclaim more space, but takes much longer and exclusively locks the table\&. This method also requires extra disk space, since it writes a new copy of the table and doesn\*(Aqt release the old copy until the operation is complete\&. Usually this should only be used when a significant amount of space needs to be reclaimed from within the table\&. +.RE +.PP +FREEZE +.RS 4 +Selects aggressive +\(lqfreezing\(rq +of tuples\&. Specifying +FREEZE +is equivalent to performing +\fBVACUUM\fR +with the +vacuum_freeze_min_age +parameter set to zero\&. +.RE +.PP +VERBOSE +.RS 4 +Prints a detailed vacuum activity report for each table\&. +.RE +.PP +ANALYZE +.RS 4 +Updates statistics used by the planner to determine the most efficient way to execute a query\&. +.RE +.PP +\fItable_name\fR +.RS 4 +The name (optionally schema\-qualified) of a specific table to vacuum\&. Defaults to all tables in the current database\&. +.RE +.PP +\fIcolumn_name\fR +.RS 4 +The name of a specific column to analyze\&. Defaults to all columns\&. If a column list is specified, +ANALYZE +is implied\&. +.RE +.SH "OUTPUTS" +.PP +When +VERBOSE +is specified, +\fBVACUUM\fR +emits progress messages to indicate which table is currently being processed\&. Various statistics about the tables are printed as well\&. +.SH "NOTES" +.PP +To vacuum a table, one must ordinarily be the table\*(Aqs owner or a superuser\&. However, database owners are allowed to vacuum all tables in their databases, except shared catalogs\&. (The restriction for shared catalogs means that a true database\-wide +\fBVACUUM\fR +can only be performed by a superuser\&.) +\fBVACUUM\fR +will skip over any tables that the calling user does not have permission to vacuum\&. +.PP + +\fBVACUUM\fR +cannot be executed inside a transaction block\&. +.PP +For tables with +GIN +indexes, +\fBVACUUM\fR +(in any form) also completes any pending index insertions, by moving pending index entries to the appropriate places in the main +GIN +index structure\&. See +Section 55.3.1, \(lqGIN Fast Update Technique\(rq, in the documentation +for details\&. +.PP +We recommend that active production databases be vacuumed frequently (at least nightly), in order to remove dead rows\&. After adding or deleting a large number of rows, it might be a good idea to issue a +\fBVACUUM ANALYZE\fR +command for the affected table\&. This will update the system catalogs with the results of all recent changes, and allow the +PostgreSQL +query planner to make better choices in planning queries\&. +.PP +The +\fBFULL\fR +option is not recommended for routine use, but might be useful in special cases\&. An example is when you have deleted or updated most of the rows in a table and would like the table to physically shrink to occupy less disk space and allow faster table scans\&. +\fBVACUUM FULL\fR +will usually shrink the table more than a plain +\fBVACUUM\fR +would\&. +.PP + +\fBVACUUM\fR +causes a substantial increase in I/O traffic, which might cause poor performance for other active sessions\&. Therefore, it is sometimes advisable to use the cost\-based vacuum delay feature\&. See +Section 18.4.4, \(lqCost-based Vacuum Delay\(rq, in the documentation +for details\&. +.PP + +PostgreSQL +includes an +\(lqautovacuum\(rq +facility which can automate routine vacuum maintenance\&. For more information about automatic and manual vacuuming, see +Section 23.1, \(lqRoutine Vacuuming\(rq, in the documentation\&. +.SH "EXAMPLES" +.PP +The following is an example from running +\fBVACUUM\fR +on a table in the regression database: +.sp +.if n \{\ +.RS 4 +.\} +.nf +regression=# VACUUM (VERBOSE, ANALYZE) onek; +INFO: vacuuming "public\&.onek" +INFO: index "onek_unique1" now contains 1000 tuples in 14 pages +DETAIL: 3000 index tuples were removed\&. +0 index pages have been deleted, 0 are currently reusable\&. +CPU 0\&.01s/0\&.08u sec elapsed 0\&.18 sec\&. +INFO: index "onek_unique2" now contains 1000 tuples in 16 pages +DETAIL: 3000 index tuples were removed\&. +0 index pages have been deleted, 0 are currently reusable\&. +CPU 0\&.00s/0\&.07u sec elapsed 0\&.23 sec\&. +INFO: index "onek_hundred" now contains 1000 tuples in 13 pages +DETAIL: 3000 index tuples were removed\&. +0 index pages have been deleted, 0 are currently reusable\&. +CPU 0\&.01s/0\&.08u sec elapsed 0\&.17 sec\&. +INFO: index "onek_stringu1" now contains 1000 tuples in 48 pages +DETAIL: 3000 index tuples were removed\&. +0 index pages have been deleted, 0 are currently reusable\&. +CPU 0\&.01s/0\&.09u sec elapsed 0\&.59 sec\&. +INFO: "onek": removed 3000 tuples in 108 pages +DETAIL: CPU 0\&.01s/0\&.06u sec elapsed 0\&.07 sec\&. +INFO: "onek": found 3000 removable, 1000 nonremovable tuples in 143 pages +DETAIL: 0 dead tuples cannot be removed yet\&. +There were 0 unused item pointers\&. +0 pages are entirely empty\&. +CPU 0\&.07s/0\&.39u sec elapsed 1\&.56 sec\&. +INFO: analyzing "public\&.onek" +INFO: "onek": 36 pages, 1000 rows sampled, 1000 estimated total rows +VACUUM +.fi +.if n \{\ +.RE +.\} +.SH "COMPATIBILITY" +.PP +There is no +\fBVACUUM\fR +statement in the SQL standard\&. +.SH "SEE ALSO" +\fBvacuumdb\fR(1), Section 18.4.4, \(lqCost-based Vacuum Delay\(rq, in the documentation, Section 23.1.6, \(lqThe Autovacuum Daemon\(rq, in the documentation diff --git a/doc/src/sgml/man7/VALUES.7 b/doc/src/sgml/man7/VALUES.7 new file mode 100644 index 000000000..b8a0fdda3 --- /dev/null +++ b/doc/src/sgml/man7/VALUES.7 @@ -0,0 +1,282 @@ +'\" t +.\" Title: VALUES +.\" Author: The PostgreSQL Global Development Group +.\" Generator: DocBook XSL Stylesheets v1.75.2 +.\" Date: 2012-12-03 +.\" Manual: PostgreSQL 9.2.2 Documentation +.\" Source: PostgreSQL 9.2.2 +.\" Language: English +.\" +.TH "VALUES" "7" "2012-12-03" "PostgreSQL 9.2.2" "PostgreSQL 9.2.2 Documentation" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +VALUES \- compute a set of rows +.\" VALUES +.SH "SYNOPSIS" +.sp +.nf +VALUES ( \fIexpression\fR [, \&.\&.\&.] ) [, \&.\&.\&.] + [ ORDER BY \fIsort_expression\fR [ ASC | DESC | USING \fIoperator\fR ] [, \&.\&.\&.] ] + [ LIMIT { \fIcount\fR | ALL } ] + [ OFFSET \fIstart\fR [ ROW | ROWS ] ] + [ FETCH { FIRST | NEXT } [ \fIcount\fR ] { ROW | ROWS } ONLY ] +.fi +.SH "DESCRIPTION" +.PP + +\fBVALUES\fR +computes a row value or set of row values specified by value expressions\&. It is most commonly used to generate a +\(lqconstant table\(rq +within a larger command, but it can be used on its own\&. +.PP +When more than one row is specified, all the rows must have the same number of elements\&. The data types of the resulting table\*(Aqs columns are determined by combining the explicit or inferred types of the expressions appearing in that column, using the same rules as for +UNION +(see +Section 10.5, \(lqUNION, CASE, and Related Constructs\(rq, in the documentation)\&. +.PP +Within larger commands, +\fBVALUES\fR +is syntactically allowed anywhere that +\fBSELECT\fR +is\&. Because it is treated like a +\fBSELECT\fR +by the grammar, it is possible to use the +ORDER BY, +LIMIT +(or equivalently +FETCH FIRST), and +OFFSET +clauses with a +\fBVALUES\fR +command\&. +.SH "PARAMETERS" +.PP +\fIexpression\fR +.RS 4 +A constant or expression to compute and insert at the indicated place in the resulting table (set of rows)\&. In a +\fBVALUES\fR +list appearing at the top level of an +\fBINSERT\fR, an +\fIexpression\fR +can be replaced by +DEFAULT +to indicate that the destination column\*(Aqs default value should be inserted\&. +DEFAULT +cannot be used when +\fBVALUES\fR +appears in other contexts\&. +.RE +.PP +\fIsort_expression\fR +.RS 4 +An expression or integer constant indicating how to sort the result rows\&. This expression can refer to the columns of the +\fBVALUES\fR +result as +column1, +column2, etc\&. For more details see +ORDER BY Clause\&. +.RE +.PP +\fIoperator\fR +.RS 4 +A sorting operator\&. For details see +ORDER BY Clause\&. +.RE +.PP +\fIcount\fR +.RS 4 +The maximum number of rows to return\&. For details see +LIMIT Clause\&. +.RE +.PP +\fIstart\fR +.RS 4 +The number of rows to skip before starting to return rows\&. For details see +LIMIT Clause\&. +.RE +.SH "NOTES" +.PP + +\fBVALUES\fR +lists with very large numbers of rows should be avoided, as you might encounter out\-of\-memory failures or poor performance\&. +\fBVALUES\fR +appearing within +\fBINSERT\fR +is a special case (because the desired column types are known from the +\fBINSERT\fR\*(Aqs target table, and need not be inferred by scanning the +\fBVALUES\fR +list), so it can handle larger lists than are practical in other contexts\&. +.SH "EXAMPLES" +.PP +A bare +\fBVALUES\fR +command: +.sp +.if n \{\ +.RS 4 +.\} +.nf +VALUES (1, \*(Aqone\*(Aq), (2, \*(Aqtwo\*(Aq), (3, \*(Aqthree\*(Aq); +.fi +.if n \{\ +.RE +.\} +.sp +This will return a table of two columns and three rows\&. It\*(Aqs effectively equivalent to: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT 1 AS column1, \*(Aqone\*(Aq AS column2 +UNION ALL +SELECT 2, \*(Aqtwo\*(Aq +UNION ALL +SELECT 3, \*(Aqthree\*(Aq; +.fi +.if n \{\ +.RE +.\} +.PP +More usually, +\fBVALUES\fR +is used within a larger SQL command\&. The most common use is in +\fBINSERT\fR: +.sp +.if n \{\ +.RS 4 +.\} +.nf +INSERT INTO films (code, title, did, date_prod, kind) + VALUES (\*(AqT_601\*(Aq, \*(AqYojimbo\*(Aq, 106, \*(Aq1961\-06\-16\*(Aq, \*(AqDrama\*(Aq); +.fi +.if n \{\ +.RE +.\} +.PP +In the context of +\fBINSERT\fR, entries of a +\fBVALUES\fR +list can be +DEFAULT +to indicate that the column default should be used here instead of specifying a value: +.sp +.if n \{\ +.RS 4 +.\} +.nf +INSERT INTO films VALUES + (\*(AqUA502\*(Aq, \*(AqBananas\*(Aq, 105, DEFAULT, \*(AqComedy\*(Aq, \*(Aq82 minutes\*(Aq), + (\*(AqT_601\*(Aq, \*(AqYojimbo\*(Aq, 106, DEFAULT, \*(AqDrama\*(Aq, DEFAULT); +.fi +.if n \{\ +.RE +.\} +.PP + +\fBVALUES\fR +can also be used where a sub\-\fBSELECT\fR +might be written, for example in a +FROM +clause: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT f\&.* + FROM films f, (VALUES(\*(AqMGM\*(Aq, \*(AqHorror\*(Aq), (\*(AqUA\*(Aq, \*(AqSci\-Fi\*(Aq)) AS t (studio, kind) + WHERE f\&.studio = t\&.studio AND f\&.kind = t\&.kind; + +UPDATE employees SET salary = salary * v\&.increase + FROM (VALUES(1, 200000, 1\&.2), (2, 400000, 1\&.4)) AS v (depno, target, increase) + WHERE employees\&.depno = v\&.depno AND employees\&.sales >= v\&.target; +.fi +.if n \{\ +.RE +.\} +.sp +Note that an +AS +clause is required when +\fBVALUES\fR +is used in a +FROM +clause, just as is true for +\fBSELECT\fR\&. It is not required that the +AS +clause specify names for all the columns, but it\*(Aqs good practice to do so\&. (The default column names for +\fBVALUES\fR +are +column1, +column2, etc in +PostgreSQL, but these names might be different in other database systems\&.) +.PP +When +\fBVALUES\fR +is used in +\fBINSERT\fR, the values are all automatically coerced to the data type of the corresponding destination column\&. When it\*(Aqs used in other contexts, it might be necessary to specify the correct data type\&. If the entries are all quoted literal constants, coercing the first is sufficient to determine the assumed type for all: +.sp +.if n \{\ +.RS 4 +.\} +.nf +SELECT * FROM machines +WHERE ip_address IN (VALUES(\*(Aq192\&.168\&.0\&.1\*(Aq::inet), (\*(Aq192\&.168\&.0\&.10\*(Aq), (\*(Aq192\&.168\&.1\&.43\*(Aq)); +.fi +.if n \{\ +.RE +.\} +.if n \{\ +.sp +.\} +.RS 4 +.it 1 an-trap +.nr an-no-space-flag 1 +.nr an-break-flag 1 +.br +.ps +1 +\fBTip\fR +.ps -1 +.br +.PP +For simple +IN +tests, it\*(Aqs better to rely on the list\-of\-scalars form of +IN +than to write a +\fBVALUES\fR +query as shown above\&. The list of scalars method requires less writing and is often more efficient\&. +.sp .5v +.RE +.SH "COMPATIBILITY" +.PP +\fBVALUES\fR +conforms to the SQL standard\&. +LIMIT +and +OFFSET +are +PostgreSQL +extensions; see also under +\fBSELECT\fR(7)\&. +.SH "SEE ALSO" +\fBINSERT\fR(7), \fBSELECT\fR(7) diff --git a/doc/src/sgml/man7/WITH.7 b/doc/src/sgml/man7/WITH.7 new file mode 100644 index 000000000..8e9105d2d --- /dev/null +++ b/doc/src/sgml/man7/WITH.7 @@ -0,0 +1 @@ +.so man7/SELECT.7 diff --git a/dropdb.vcxproj b/dropdb.vcxproj deleted file mode 100644 index 82b77d502..000000000 --- a/dropdb.vcxproj +++ /dev/null @@ -1,147 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {12C9A9F5-EF84-42A5-8A0C-8168E35E6D15} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\dropdb\ - .\Debug\dropdb\ - false - .\Release\dropdb\ - .\Release\dropdb\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\bin\pg_dump;src\bin\psql;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\dropdb\ - .\Debug\dropdb\ - .\Debug\dropdb\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\dropdb\dropdb.exe - Debug\libpq\libpq.lib;Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\dropdb\dropdb.pdb - false - .\Debug\dropdb\dropdb.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\bin\pg_dump;src\bin\psql;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\dropdb\ - .\Release\dropdb\ - .\Release\dropdb\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\dropdb\dropdb.exe - Release\libpq\libpq.lib;Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\dropdb\dropdb.pdb - false - .\Release\dropdb\dropdb.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - - - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/droplang.vcxproj b/droplang.vcxproj deleted file mode 100644 index 325d1291f..000000000 --- a/droplang.vcxproj +++ /dev/null @@ -1,146 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {F65D7F6D-A4F5-4D81-9C1A-4F0158E69ED2} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\droplang\ - .\Debug\droplang\ - false - .\Release\droplang\ - .\Release\droplang\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\bin\pg_dump;src\bin\psql;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\droplang\ - .\Debug\droplang\ - .\Debug\droplang\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\droplang\droplang.exe - Debug\libpq\libpq.lib;Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\droplang\droplang.pdb - false - .\Debug\droplang\droplang.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\bin\pg_dump;src\bin\psql;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\droplang\ - .\Release\droplang\ - .\Release\droplang\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\droplang\droplang.exe - Release\libpq\libpq.lib;Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\droplang\droplang.pdb - false - .\Release\droplang\droplang.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/dropuser.vcxproj b/dropuser.vcxproj deleted file mode 100644 index 7ba6e98c7..000000000 --- a/dropuser.vcxproj +++ /dev/null @@ -1,147 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {35516F4D-7763-49B3-AD9B-F7CF7A6CDD13} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\dropuser\ - .\Debug\dropuser\ - false - .\Release\dropuser\ - .\Release\dropuser\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\bin\pg_dump;src\bin\psql;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\dropuser\ - .\Debug\dropuser\ - .\Debug\dropuser\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\dropuser\dropuser.exe - Debug\libpq\libpq.lib;Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\dropuser\dropuser.pdb - false - .\Debug\dropuser\dropuser.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\bin\pg_dump;src\bin\psql;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\dropuser\ - .\Release\dropuser\ - .\Release\dropuser\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\dropuser\dropuser.exe - Release\libpq\libpq.lib;Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\dropuser\dropuser.pdb - false - .\Release\dropuser\dropuser.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - - - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/dummy_seclabel.vcxproj b/dummy_seclabel.vcxproj deleted file mode 100644 index 2c534cf1d..000000000 --- a/dummy_seclabel.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {C9A60C60-2ECB-4A49-B6A8-25A299284555} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\dummy_seclabel\ - .\Debug\dummy_seclabel\ - false - .\Release\dummy_seclabel\ - .\Release\dummy_seclabel\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\dummy_seclabel\ - .\Debug\dummy_seclabel\ - .\Debug\dummy_seclabel\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\dummy_seclabel\dummy_seclabel.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\dummy_seclabel\dummy_seclabel.pdb - false - .\Debug\dummy_seclabel\dummy_seclabel.map - Console - MachineX86 - Debug\dummy_seclabel\dummy_seclabel.lib - .\Debug\dummy_seclabel\dummy_seclabel.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\dummy_seclabel Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\dummy_seclabel\ - .\Release\dummy_seclabel\ - .\Release\dummy_seclabel\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\dummy_seclabel\dummy_seclabel.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\dummy_seclabel\dummy_seclabel.pdb - false - .\Release\dummy_seclabel\dummy_seclabel.map - Console - MachineX86 - Release\dummy_seclabel\dummy_seclabel.lib - .\Release\dummy_seclabel\dummy_seclabel.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\dummy_seclabel Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/earthdistance.vcxproj b/earthdistance.vcxproj deleted file mode 100644 index 503fe2cef..000000000 --- a/earthdistance.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {725BC9C5-2BC6-45A8-8F71-1F7EA82B3356} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\earthdistance\ - .\Debug\earthdistance\ - false - .\Release\earthdistance\ - .\Release\earthdistance\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\earthdistance\ - .\Debug\earthdistance\ - .\Debug\earthdistance\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\earthdistance\earthdistance.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\earthdistance\earthdistance.pdb - false - .\Debug\earthdistance\earthdistance.map - Console - MachineX86 - Debug\earthdistance\earthdistance.lib - .\Debug\earthdistance\earthdistance.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\earthdistance Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\earthdistance\ - .\Release\earthdistance\ - .\Release\earthdistance\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\earthdistance\earthdistance.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\earthdistance\earthdistance.pdb - false - .\Release\earthdistance\earthdistance.map - Console - MachineX86 - Release\earthdistance\earthdistance.lib - .\Release\earthdistance\earthdistance.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\earthdistance Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/ecpg.vcxproj b/ecpg.vcxproj deleted file mode 100644 index cf4503bda..000000000 --- a/ecpg.vcxproj +++ /dev/null @@ -1,173 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {35F09765-DF69-4B0F-91AA-8318B3A8CE74} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\ecpg\ - .\Debug\ecpg\ - false - .\Release\ecpg\ - .\Release\ecpg\ - false - - - - Disabled - src\interfaces\ecpg\preproc;src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\ecpg\include;src\interfaces\libpq;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;MAJOR_VERSION=4;MINOR_VERSION=2;PATCHLEVEL=1;ECPG_COMPILE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\ecpg\ - .\Debug\ecpg\ - .\Debug\ecpg\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\ecpg\ecpg.exe - Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\ecpg\ecpg.pdb - false - .\Debug\ecpg\ecpg.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src\interfaces\ecpg\preproc;src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\ecpg\include;src\interfaces\libpq;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;MAJOR_VERSION=4;MINOR_VERSION=2;PATCHLEVEL=1;ECPG_COMPILE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\ecpg\ - .\Release\ecpg\ - .\Release\ecpg\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\ecpg\ecpg.exe - Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\ecpg\ecpg.pdb - false - .\Release\ecpg\ecpg.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - - - - - - - - - Running flex on src\interfaces\ecpg\preproc\pgc.l - perl "src\tools\msvc\pgflex.pl" "src\interfaces\ecpg\preproc\pgc.l" - %(AdditionalInputs) - src\interfaces\ecpg\preproc\pgc.c;%(Outputs) - Running flex on src\interfaces\ecpg\preproc\pgc.l - perl "src\tools\msvc\pgflex.pl" "src\interfaces\ecpg\preproc\pgc.l" - %(AdditionalInputs) - src\interfaces\ecpg\preproc\pgc.c;%(Outputs) - - - Running bison on src\interfaces\ecpg\preproc\preproc.y - perl "src\tools\msvc\pgbison.pl" "src\interfaces\ecpg\preproc\preproc.y" - %(AdditionalInputs) - src\interfaces\ecpg\preproc\preproc.c;%(Outputs) - Running bison on src\interfaces\ecpg\preproc\preproc.y - perl "src\tools\msvc\pgbison.pl" "src\interfaces\ecpg\preproc\preproc.y" - %(AdditionalInputs) - src\interfaces\ecpg\preproc\preproc.c;%(Outputs) - - - - - - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/euc2004_sjis2004.vcxproj b/euc2004_sjis2004.vcxproj deleted file mode 100644 index 6d46d1ce1..000000000 --- a/euc2004_sjis2004.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {2C236354-6407-4C4B-B72D-1E2CBB65946C} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\euc2004_sjis2004\ - .\Debug\euc2004_sjis2004\ - false - .\Release\euc2004_sjis2004\ - .\Release\euc2004_sjis2004\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\euc2004_sjis2004\ - .\Debug\euc2004_sjis2004\ - .\Debug\euc2004_sjis2004\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\euc2004_sjis2004\euc2004_sjis2004.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\euc2004_sjis2004\euc2004_sjis2004.pdb - false - .\Debug\euc2004_sjis2004\euc2004_sjis2004.map - Console - MachineX86 - Debug\euc2004_sjis2004\euc2004_sjis2004.lib - .\Debug\euc2004_sjis2004\euc2004_sjis2004.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\euc2004_sjis2004 Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\euc2004_sjis2004\ - .\Release\euc2004_sjis2004\ - .\Release\euc2004_sjis2004\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\euc2004_sjis2004\euc2004_sjis2004.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\euc2004_sjis2004\euc2004_sjis2004.pdb - false - .\Release\euc2004_sjis2004\euc2004_sjis2004.map - Console - MachineX86 - Release\euc2004_sjis2004\euc2004_sjis2004.lib - .\Release\euc2004_sjis2004\euc2004_sjis2004.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\euc2004_sjis2004 Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/euc_cn_and_mic.vcxproj b/euc_cn_and_mic.vcxproj deleted file mode 100644 index 632e251b3..000000000 --- a/euc_cn_and_mic.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {0184B94E-D884-4B07-9914-9365A79659F7} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\euc_cn_and_mic\ - .\Debug\euc_cn_and_mic\ - false - .\Release\euc_cn_and_mic\ - .\Release\euc_cn_and_mic\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\euc_cn_and_mic\ - .\Debug\euc_cn_and_mic\ - .\Debug\euc_cn_and_mic\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\euc_cn_and_mic\euc_cn_and_mic.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\euc_cn_and_mic\euc_cn_and_mic.pdb - false - .\Debug\euc_cn_and_mic\euc_cn_and_mic.map - Console - MachineX86 - Debug\euc_cn_and_mic\euc_cn_and_mic.lib - .\Debug\euc_cn_and_mic\euc_cn_and_mic.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\euc_cn_and_mic Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\euc_cn_and_mic\ - .\Release\euc_cn_and_mic\ - .\Release\euc_cn_and_mic\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\euc_cn_and_mic\euc_cn_and_mic.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\euc_cn_and_mic\euc_cn_and_mic.pdb - false - .\Release\euc_cn_and_mic\euc_cn_and_mic.map - Console - MachineX86 - Release\euc_cn_and_mic\euc_cn_and_mic.lib - .\Release\euc_cn_and_mic\euc_cn_and_mic.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\euc_cn_and_mic Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/euc_jp_and_sjis.vcxproj b/euc_jp_and_sjis.vcxproj deleted file mode 100644 index 96819a9f1..000000000 --- a/euc_jp_and_sjis.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {6F111289-0EE0-4E7D-B30A-D86EB8DFEF64} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\euc_jp_and_sjis\ - .\Debug\euc_jp_and_sjis\ - false - .\Release\euc_jp_and_sjis\ - .\Release\euc_jp_and_sjis\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\euc_jp_and_sjis\ - .\Debug\euc_jp_and_sjis\ - .\Debug\euc_jp_and_sjis\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\euc_jp_and_sjis\euc_jp_and_sjis.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\euc_jp_and_sjis\euc_jp_and_sjis.pdb - false - .\Debug\euc_jp_and_sjis\euc_jp_and_sjis.map - Console - MachineX86 - Debug\euc_jp_and_sjis\euc_jp_and_sjis.lib - .\Debug\euc_jp_and_sjis\euc_jp_and_sjis.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\euc_jp_and_sjis Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\euc_jp_and_sjis\ - .\Release\euc_jp_and_sjis\ - .\Release\euc_jp_and_sjis\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\euc_jp_and_sjis\euc_jp_and_sjis.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\euc_jp_and_sjis\euc_jp_and_sjis.pdb - false - .\Release\euc_jp_and_sjis\euc_jp_and_sjis.map - Console - MachineX86 - Release\euc_jp_and_sjis\euc_jp_and_sjis.lib - .\Release\euc_jp_and_sjis\euc_jp_and_sjis.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\euc_jp_and_sjis Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/euc_kr_and_mic.vcxproj b/euc_kr_and_mic.vcxproj deleted file mode 100644 index 88ec25402..000000000 --- a/euc_kr_and_mic.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {6FB7FD72-C8C3-41F5-98FA-4F238A6C91F7} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\euc_kr_and_mic\ - .\Debug\euc_kr_and_mic\ - false - .\Release\euc_kr_and_mic\ - .\Release\euc_kr_and_mic\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\euc_kr_and_mic\ - .\Debug\euc_kr_and_mic\ - .\Debug\euc_kr_and_mic\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\euc_kr_and_mic\euc_kr_and_mic.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\euc_kr_and_mic\euc_kr_and_mic.pdb - false - .\Debug\euc_kr_and_mic\euc_kr_and_mic.map - Console - MachineX86 - Debug\euc_kr_and_mic\euc_kr_and_mic.lib - .\Debug\euc_kr_and_mic\euc_kr_and_mic.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\euc_kr_and_mic Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\euc_kr_and_mic\ - .\Release\euc_kr_and_mic\ - .\Release\euc_kr_and_mic\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\euc_kr_and_mic\euc_kr_and_mic.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\euc_kr_and_mic\euc_kr_and_mic.pdb - false - .\Release\euc_kr_and_mic\euc_kr_and_mic.map - Console - MachineX86 - Release\euc_kr_and_mic\euc_kr_and_mic.lib - .\Release\euc_kr_and_mic\euc_kr_and_mic.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\euc_kr_and_mic Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/euc_tw_and_big5.vcxproj b/euc_tw_and_big5.vcxproj deleted file mode 100644 index f329c3e32..000000000 --- a/euc_tw_and_big5.vcxproj +++ /dev/null @@ -1,150 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {53291745-0DE9-4E77-A515-372E19D0B272} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\euc_tw_and_big5\ - .\Debug\euc_tw_and_big5\ - false - .\Release\euc_tw_and_big5\ - .\Release\euc_tw_and_big5\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\euc_tw_and_big5\ - .\Debug\euc_tw_and_big5\ - .\Debug\euc_tw_and_big5\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\euc_tw_and_big5\euc_tw_and_big5.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\euc_tw_and_big5\euc_tw_and_big5.pdb - false - .\Debug\euc_tw_and_big5\euc_tw_and_big5.map - Console - MachineX86 - Debug\euc_tw_and_big5\euc_tw_and_big5.lib - .\Debug\euc_tw_and_big5\euc_tw_and_big5.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\euc_tw_and_big5 Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\euc_tw_and_big5\ - .\Release\euc_tw_and_big5\ - .\Release\euc_tw_and_big5\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\euc_tw_and_big5\euc_tw_and_big5.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\euc_tw_and_big5\euc_tw_and_big5.pdb - false - .\Release\euc_tw_and_big5\euc_tw_and_big5.map - Console - MachineX86 - Release\euc_tw_and_big5\euc_tw_and_big5.lib - .\Release\euc_tw_and_big5\euc_tw_and_big5.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\euc_tw_and_big5 Win32 - - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/file_fdw.vcxproj b/file_fdw.vcxproj deleted file mode 100644 index 69d2f6055..000000000 --- a/file_fdw.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {6A485F81-1C55-4EE9-AE03-1C256C1D307D} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\file_fdw\ - .\Debug\file_fdw\ - false - .\Release\file_fdw\ - .\Release\file_fdw\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\file_fdw\ - .\Debug\file_fdw\ - .\Debug\file_fdw\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\file_fdw\file_fdw.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\file_fdw\file_fdw.pdb - false - .\Debug\file_fdw\file_fdw.map - Console - MachineX86 - Debug\file_fdw\file_fdw.lib - .\Debug\file_fdw\file_fdw.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\file_fdw Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\file_fdw\ - .\Release\file_fdw\ - .\Release\file_fdw\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\file_fdw\file_fdw.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\file_fdw\file_fdw.pdb - false - .\Release\file_fdw\file_fdw.map - Console - MachineX86 - Release\file_fdw\file_fdw.lib - .\Release\file_fdw\file_fdw.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\file_fdw Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/fuzzystrmatch.vcxproj b/fuzzystrmatch.vcxproj deleted file mode 100644 index 93b048d7a..000000000 --- a/fuzzystrmatch.vcxproj +++ /dev/null @@ -1,150 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {BB768163-677B-4B15-8959-C09318C8DDC5} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\fuzzystrmatch\ - .\Debug\fuzzystrmatch\ - false - .\Release\fuzzystrmatch\ - .\Release\fuzzystrmatch\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\fuzzystrmatch\ - .\Debug\fuzzystrmatch\ - .\Debug\fuzzystrmatch\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\fuzzystrmatch\fuzzystrmatch.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\fuzzystrmatch\fuzzystrmatch.pdb - false - .\Debug\fuzzystrmatch\fuzzystrmatch.map - Console - MachineX86 - Debug\fuzzystrmatch\fuzzystrmatch.lib - .\Debug\fuzzystrmatch\fuzzystrmatch.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\fuzzystrmatch Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\fuzzystrmatch\ - .\Release\fuzzystrmatch\ - .\Release\fuzzystrmatch\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\fuzzystrmatch\fuzzystrmatch.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\fuzzystrmatch\fuzzystrmatch.pdb - false - .\Release\fuzzystrmatch\fuzzystrmatch.map - Console - MachineX86 - Release\fuzzystrmatch\fuzzystrmatch.lib - .\Release\fuzzystrmatch\fuzzystrmatch.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\fuzzystrmatch Win32 - - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/hstore.vcxproj b/hstore.vcxproj deleted file mode 100644 index 11724f581..000000000 --- a/hstore.vcxproj +++ /dev/null @@ -1,154 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {4683B3C1-CF18-4ADC-BE2E-E2A6F74D3F43} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\hstore\ - .\Debug\hstore\ - false - .\Release\hstore\ - .\Release\hstore\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\hstore\ - .\Debug\hstore\ - .\Debug\hstore\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\hstore\hstore.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\hstore\hstore.pdb - false - .\Debug\hstore\hstore.map - Console - MachineX86 - Debug\hstore\hstore.lib - .\Debug\hstore\hstore.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\hstore Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\hstore\ - .\Release\hstore\ - .\Release\hstore\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\hstore\hstore.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\hstore\hstore.pdb - false - .\Release\hstore\hstore.map - Console - MachineX86 - Release\hstore\hstore.lib - .\Release\hstore\hstore.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\hstore Win32 - - - - - - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/initdb.vcxproj b/initdb.vcxproj deleted file mode 100644 index 7a168cf82..000000000 --- a/initdb.vcxproj +++ /dev/null @@ -1,144 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {F911DA5F-C542-4D97-99A1-3E8B557EBDD7} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\initdb\ - .\Debug\initdb\ - false - .\Release\initdb\ - .\Release\initdb\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\timezone;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;FRONTEND;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\initdb\ - .\Debug\initdb\ - .\Debug\initdb\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\initdb\initdb.exe - Debug\libpgport\libpgport.lib;wsock32.lib;ws2_32.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\initdb\initdb.pdb - false - .\Debug\initdb\initdb.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\timezone;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;FRONTEND;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\initdb\ - .\Release\initdb\ - .\Release\initdb\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\initdb\initdb.exe - Release\libpgport\libpgport.lib;wsock32.lib;ws2_32.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\initdb\initdb.pdb - false - .\Release\initdb\initdb.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - - - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/insert_username.vcxproj b/insert_username.vcxproj deleted file mode 100644 index ca8216ea4..000000000 --- a/insert_username.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {41F471FA-2A52-4682-A6F4-E20592531FD1} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\insert_username\ - .\Debug\insert_username\ - false - .\Release\insert_username\ - .\Release\insert_username\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\insert_username\ - .\Debug\insert_username\ - .\Debug\insert_username\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\insert_username\insert_username.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\insert_username\insert_username.pdb - false - .\Debug\insert_username\insert_username.map - Console - MachineX86 - Debug\insert_username\insert_username.lib - .\Debug\insert_username\insert_username.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\insert_username Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\insert_username\ - .\Release\insert_username\ - .\Release\insert_username\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\insert_username\insert_username.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\insert_username\insert_username.pdb - false - .\Release\insert_username\insert_username.map - Console - MachineX86 - Release\insert_username\insert_username.lib - .\Release\insert_username\insert_username.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\insert_username Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/isn.vcxproj b/isn.vcxproj deleted file mode 100644 index af08b05d9..000000000 --- a/isn.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {0E13B1B6-BDCF-4608-98BA-8EB553A14006} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\isn\ - .\Debug\isn\ - false - .\Release\isn\ - .\Release\isn\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\isn\ - .\Debug\isn\ - .\Debug\isn\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\isn\isn.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\isn\isn.pdb - false - .\Debug\isn\isn.map - Console - MachineX86 - Debug\isn\isn.lib - .\Debug\isn\isn.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\isn Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\isn\ - .\Release\isn\ - .\Release\isn\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\isn\isn.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\isn\isn.pdb - false - .\Release\isn\isn.map - Console - MachineX86 - Release\isn\isn.lib - .\Release\isn\isn.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\isn Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/isolationtester.vcxproj b/isolationtester.vcxproj deleted file mode 100644 index c7e2e48eb..000000000 --- a/isolationtester.vcxproj +++ /dev/null @@ -1,163 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {58621CC2-3691-49AE-9AF0-C750C906C086} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\isolationtester\ - .\Debug\isolationtester\ - false - .\Release\isolationtester\ - .\Release\isolationtester\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\test\isolation;src\port;src\test\regress;src\interfaces\libpq;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;HOST_TUPLE="i686-pc-win32vc";FRONTEND;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\isolationtester\ - .\Debug\isolationtester\ - .\Debug\isolationtester\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\isolationtester\isolationtester.exe - wsock32.lib;Debug\libpq\libpq.lib;Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\isolationtester\isolationtester.pdb - false - .\Debug\isolationtester\isolationtester.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\test\isolation;src\port;src\test\regress;src\interfaces\libpq;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;HOST_TUPLE="i686-pc-win32vc";FRONTEND;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\isolationtester\ - .\Release\isolationtester\ - .\Release\isolationtester\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\isolationtester\isolationtester.exe - wsock32.lib;Release\libpq\libpq.lib;Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\isolationtester\isolationtester.pdb - false - .\Release\isolationtester\isolationtester.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - Running bison on src\test\isolation\specparse.y - perl "src\tools\msvc\pgbison.pl" "src\test\isolation\specparse.y" - %(AdditionalInputs) - src\test\isolation\specparse.c;%(Outputs) - Running bison on src\test\isolation\specparse.y - perl "src\tools\msvc\pgbison.pl" "src\test\isolation\specparse.y" - %(AdditionalInputs) - src\test\isolation\specparse.c;%(Outputs) - - - Running flex on src\test\isolation\specscanner.l - perl "src\tools\msvc\pgflex.pl" "src\test\isolation\specscanner.l" - %(AdditionalInputs) - src\test\isolation\specscanner.c;%(Outputs) - Running flex on src\test\isolation\specscanner.l - perl "src\tools\msvc\pgflex.pl" "src\test\isolation\specscanner.l" - %(AdditionalInputs) - src\test\isolation\specscanner.c;%(Outputs) - - - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/latin2_and_win1250.vcxproj b/latin2_and_win1250.vcxproj deleted file mode 100644 index 9f170991b..000000000 --- a/latin2_and_win1250.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {91042613-2A49-4724-88EB-DFA7123D44F0} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\latin2_and_win1250\ - .\Debug\latin2_and_win1250\ - false - .\Release\latin2_and_win1250\ - .\Release\latin2_and_win1250\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\latin2_and_win1250\ - .\Debug\latin2_and_win1250\ - .\Debug\latin2_and_win1250\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\latin2_and_win1250\latin2_and_win1250.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\latin2_and_win1250\latin2_and_win1250.pdb - false - .\Debug\latin2_and_win1250\latin2_and_win1250.map - Console - MachineX86 - Debug\latin2_and_win1250\latin2_and_win1250.lib - .\Debug\latin2_and_win1250\latin2_and_win1250.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\latin2_and_win1250 Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\latin2_and_win1250\ - .\Release\latin2_and_win1250\ - .\Release\latin2_and_win1250\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\latin2_and_win1250\latin2_and_win1250.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\latin2_and_win1250\latin2_and_win1250.pdb - false - .\Release\latin2_and_win1250\latin2_and_win1250.map - Console - MachineX86 - Release\latin2_and_win1250\latin2_and_win1250.lib - .\Release\latin2_and_win1250\latin2_and_win1250.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\latin2_and_win1250 Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/latin_and_mic.vcxproj b/latin_and_mic.vcxproj deleted file mode 100644 index c96b0cf51..000000000 --- a/latin_and_mic.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {4ECD970F-1FB5-4DB0-932C-A4C7D2366CF4} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\latin_and_mic\ - .\Debug\latin_and_mic\ - false - .\Release\latin_and_mic\ - .\Release\latin_and_mic\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\latin_and_mic\ - .\Debug\latin_and_mic\ - .\Debug\latin_and_mic\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\latin_and_mic\latin_and_mic.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\latin_and_mic\latin_and_mic.pdb - false - .\Debug\latin_and_mic\latin_and_mic.map - Console - MachineX86 - Debug\latin_and_mic\latin_and_mic.lib - .\Debug\latin_and_mic\latin_and_mic.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\latin_and_mic Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\latin_and_mic\ - .\Release\latin_and_mic\ - .\Release\latin_and_mic\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\latin_and_mic\latin_and_mic.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\latin_and_mic\latin_and_mic.pdb - false - .\Release\latin_and_mic\latin_and_mic.map - Console - MachineX86 - Release\latin_and_mic\latin_and_mic.lib - .\Release\latin_and_mic\latin_and_mic.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\latin_and_mic Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/libecpg.vcxproj b/libecpg.vcxproj deleted file mode 100644 index 879676450..000000000 --- a/libecpg.vcxproj +++ /dev/null @@ -1,157 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {9AA04C5D-B359-4FE6-9219-318486AB0C54} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\libecpg\ - .\Debug\libecpg\ - false - .\Release\libecpg\ - .\Release\libecpg\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\ecpg\include;src\interfaces\libpq;src\port;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;FRONTEND;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\libecpg\ - .\Debug\libecpg\ - .\Debug\libecpg\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\libecpg\libecpg.dll - wsock32.lib;Debug\libpq\libpq.lib;Debug\libpgtypes\libpgtypes.lib;Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\libecpg\libecpg.pdb - false - .\Debug\libecpg\libecpg.map - Console - MachineX86 - src\interfaces\ecpg\ecpglib\ecpglib.def - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\ecpg\include;src\interfaces\libpq;src\port;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;FRONTEND;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\libecpg\ - .\Release\libecpg\ - .\Release\libecpg\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\libecpg\libecpg.dll - wsock32.lib;Release\libpq\libpq.lib;Release\libpgtypes\libpgtypes.lib;Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\libecpg\libecpg.pdb - false - .\Release\libecpg\libecpg.map - Console - MachineX86 - src\interfaces\ecpg\ecpglib\ecpglib.def - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - - - - - - - - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - {618F2BB4-B603-4163-A9DB-49FA86577E4F} - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/libecpg_compat.vcxproj b/libecpg_compat.vcxproj deleted file mode 100644 index 0ea34ad58..000000000 --- a/libecpg_compat.vcxproj +++ /dev/null @@ -1,145 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {A2486867-814E-4B9C-A2DE-8D3164FA4DF8} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\libecpg_compat\ - .\Debug\libecpg_compat\ - false - .\Release\libecpg_compat\ - .\Release\libecpg_compat\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\ecpg\include;src\interfaces\libpq;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\libecpg_compat\ - .\Debug\libecpg_compat\ - .\Debug\libecpg_compat\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\libecpg_compat\libecpg_compat.dll - Debug\libpgtypes\libpgtypes.lib;Debug\libecpg\libecpg.lib;Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\libecpg_compat\libecpg_compat.pdb - false - .\Debug\libecpg_compat\libecpg_compat.map - Console - MachineX86 - src\interfaces\ecpg\compatlib\compatlib.def - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\ecpg\include;src\interfaces\libpq;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\libecpg_compat\ - .\Release\libecpg_compat\ - .\Release\libecpg_compat\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\libecpg_compat\libecpg_compat.dll - Release\libpgtypes\libpgtypes.lib;Release\libecpg\libecpg.lib;Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\libecpg_compat\libecpg_compat.pdb - false - .\Release\libecpg_compat\libecpg_compat.map - Console - MachineX86 - src\interfaces\ecpg\compatlib\compatlib.def - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - {618F2BB4-B603-4163-A9DB-49FA86577E4F} - - - {9AA04C5D-B359-4FE6-9219-318486AB0C54} - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/libpgport.vcxproj b/libpgport.vcxproj deleted file mode 100644 index f9f08379c..000000000 --- a/libpgport.vcxproj +++ /dev/null @@ -1,168 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - StaticLibrary - false - MultiByte - false - v110 - - - StaticLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\libpgport\ - .\Debug\libpgport\ - false - .\Release\libpgport\ - .\Release\libpgport\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;FRONTEND;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\libpgport\ - .\Debug\libpgport\ - .\Debug\libpgport\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\libpgport\libpgport.lib - ;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\libpgport\libpgport.pdb - false - .\Debug\libpgport\libpgport.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;FRONTEND;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\libpgport\ - .\Release\libpgport\ - .\Release\libpgport\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\libpgport\libpgport.lib - ;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\libpgport\libpgport.pdb - false - .\Release\libpgport\libpgport.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/libpgtypes.vcxproj b/libpgtypes.vcxproj deleted file mode 100644 index 35e090f4e..000000000 --- a/libpgtypes.vcxproj +++ /dev/null @@ -1,145 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {618F2BB4-B603-4163-A9DB-49FA86577E4F} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\libpgtypes\ - .\Debug\libpgtypes\ - false - .\Release\libpgtypes\ - .\Release\libpgtypes\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\ecpg\include;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;FRONTEND;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\libpgtypes\ - .\Debug\libpgtypes\ - .\Debug\libpgtypes\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\libpgtypes\libpgtypes.dll - Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\libpgtypes\libpgtypes.pdb - false - .\Debug\libpgtypes\libpgtypes.map - Console - MachineX86 - src\interfaces\ecpg\pgtypeslib\pgtypeslib.def - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\ecpg\include;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;FRONTEND;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\libpgtypes\ - .\Release\libpgtypes\ - .\Release\libpgtypes\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\libpgtypes\libpgtypes.dll - Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\libpgtypes\libpgtypes.pdb - false - .\Release\libpgtypes\libpgtypes.map - Console - MachineX86 - src\interfaces\ecpg\pgtypeslib\pgtypeslib.def - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/libpq.vcxproj b/libpq.vcxproj deleted file mode 100644 index 9d81f7709..000000000 --- a/libpq.vcxproj +++ /dev/null @@ -1,166 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\libpq\ - .\Debug\libpq\ - false - .\Release\libpq\ - .\Release\libpq\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\port;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;FRONTEND;UNSAFE_STAT_OK;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\libpq\ - .\Debug\libpq\ - .\Debug\libpq\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\libpq\libpq_debug.dll - wsock32.lib;secur32.lib;ws2_32.lib;wldap32.lib;Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\libpq\libpq_debug.pdb - false - .\Debug\libpq\libpq.map - Console - MachineX86 - src\interfaces\libpq\libpqdll.def - $(OutDir)$(TargetName)_debug.lib - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\port;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;FRONTEND;UNSAFE_STAT_OK;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\libpq\ - .\Release\libpq\ - .\Release\libpq\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\libpq\libpq.dll - wsock32.lib;secur32.lib;ws2_32.lib;wldap32.lib;Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\libpq\libpq.pdb - false - .\Release\libpq\libpq.map - Console - MachineX86 - src\interfaces\libpq\libpqdll.def - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/libpqwalreceiver.vcxproj b/libpqwalreceiver.vcxproj deleted file mode 100644 index 744b96e1e..000000000 --- a/libpqwalreceiver.vcxproj +++ /dev/null @@ -1,152 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {6CD427E7-447F-4238-A279-78119BB4FA2F} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\libpqwalreceiver\ - .\Debug\libpqwalreceiver\ - false - .\Release\libpqwalreceiver\ - .\Release\libpqwalreceiver\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\libpqwalreceiver\ - .\Debug\libpqwalreceiver\ - .\Debug\libpqwalreceiver\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\libpqwalreceiver\libpqwalreceiver.dll - Debug\postgres\postgres.lib;Debug\libpq\libpq.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\libpqwalreceiver\libpqwalreceiver.pdb - false - .\Debug\libpqwalreceiver\libpqwalreceiver.map - Console - MachineX86 - Debug\libpqwalreceiver\libpqwalreceiver.lib - .\Debug\libpqwalreceiver\libpqwalreceiver.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\libpqwalreceiver Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\libpqwalreceiver\ - .\Release\libpqwalreceiver\ - .\Release\libpqwalreceiver\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\libpqwalreceiver\libpqwalreceiver.dll - Release\postgres\postgres.lib;Release\libpq\libpq.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\libpqwalreceiver\libpqwalreceiver.pdb - false - .\Release\libpqwalreceiver\libpqwalreceiver.map - Console - MachineX86 - Release\libpqwalreceiver\libpqwalreceiver.lib - .\Release\libpqwalreceiver\libpqwalreceiver.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\libpqwalreceiver Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - - - - \ No newline at end of file diff --git a/lo.vcxproj b/lo.vcxproj deleted file mode 100644 index 5597161c4..000000000 --- a/lo.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {28300B4A-527D-4BB7-9116-4FA98227B060} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\lo\ - .\Debug\lo\ - false - .\Release\lo\ - .\Release\lo\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\lo\ - .\Debug\lo\ - .\Debug\lo\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\lo\lo.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\lo\lo.pdb - false - .\Debug\lo\lo.map - Console - MachineX86 - Debug\lo\lo.lib - .\Debug\lo\lo.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\lo Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\lo\ - .\Release\lo\ - .\Release\lo\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\lo\lo.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\lo\lo.pdb - false - .\Release\lo\lo.map - Console - MachineX86 - Release\lo\lo.lib - .\Release\lo\lo.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\lo Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/ltree.vcxproj b/ltree.vcxproj deleted file mode 100644 index 315d57a84..000000000 --- a/ltree.vcxproj +++ /dev/null @@ -1,157 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {F4D3FE2D-C8F8-45B4-B162-CE1D97257973} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\ltree\ - .\Debug\ltree\ - false - .\Release\ltree\ - .\Release\ltree\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\ltree\ - .\Debug\ltree\ - .\Debug\ltree\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\ltree\ltree.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\ltree\ltree.pdb - false - .\Debug\ltree\ltree.map - Console - MachineX86 - Debug\ltree\ltree.lib - .\Debug\ltree\ltree.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\ltree Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\ltree\ - .\Release\ltree\ - .\Release\ltree\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\ltree\ltree.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\ltree\ltree.pdb - false - .\Release\ltree\ltree.map - Console - MachineX86 - Release\ltree\ltree.lib - .\Release\ltree\ltree.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\ltree Win32 - - - - - - - - - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/moddatetime.vcxproj b/moddatetime.vcxproj deleted file mode 100644 index 602531ed3..000000000 --- a/moddatetime.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {C72E18E7-2798-4316-9D44-FBACBF81CA39} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\moddatetime\ - .\Debug\moddatetime\ - false - .\Release\moddatetime\ - .\Release\moddatetime\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\moddatetime\ - .\Debug\moddatetime\ - .\Debug\moddatetime\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\moddatetime\moddatetime.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\moddatetime\moddatetime.pdb - false - .\Debug\moddatetime\moddatetime.map - Console - MachineX86 - Debug\moddatetime\moddatetime.lib - .\Debug\moddatetime\moddatetime.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\moddatetime Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\moddatetime\ - .\Release\moddatetime\ - .\Release\moddatetime\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\moddatetime\moddatetime.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\moddatetime\moddatetime.pdb - false - .\Release\moddatetime\moddatetime.map - Console - MachineX86 - Release\moddatetime\moddatetime.lib - .\Release\moddatetime\moddatetime.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\moddatetime Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/oid2name.vcxproj b/oid2name.vcxproj deleted file mode 100644 index 653244fb8..000000000 --- a/oid2name.vcxproj +++ /dev/null @@ -1,140 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {2433452B-5895-4052-96CE-369490F64F4E} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\oid2name\ - .\Debug\oid2name\ - false - .\Release\oid2name\ - .\Release\oid2name\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\oid2name\ - .\Debug\oid2name\ - .\Debug\oid2name\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\oid2name\oid2name.exe - Debug\libpq\libpq.lib;Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\oid2name\oid2name.pdb - false - .\Debug\oid2name\oid2name.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\oid2name\ - .\Release\oid2name\ - .\Release\oid2name\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\oid2name\oid2name.exe - Release\libpq\libpq.lib;Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\oid2name\oid2name.pdb - false - .\Release\oid2name\oid2name.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/pageinspect.vcxproj b/pageinspect.vcxproj deleted file mode 100644 index 3fd3a745d..000000000 --- a/pageinspect.vcxproj +++ /dev/null @@ -1,152 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {11CC3BBB-402E-445B-AE6C-E96E46EA2245} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pageinspect\ - .\Debug\pageinspect\ - false - .\Release\pageinspect\ - .\Release\pageinspect\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pageinspect\ - .\Debug\pageinspect\ - .\Debug\pageinspect\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pageinspect\pageinspect.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pageinspect\pageinspect.pdb - false - .\Debug\pageinspect\pageinspect.map - Console - MachineX86 - Debug\pageinspect\pageinspect.lib - .\Debug\pageinspect\pageinspect.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\pageinspect Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pageinspect\ - .\Release\pageinspect\ - .\Release\pageinspect\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pageinspect\pageinspect.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pageinspect\pageinspect.pdb - false - .\Release\pageinspect\pageinspect.map - Console - MachineX86 - Release\pageinspect\pageinspect.lib - .\Release\pageinspect\pageinspect.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\pageinspect Win32 - - - - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/passwordcheck.vcxproj b/passwordcheck.vcxproj deleted file mode 100644 index 6d4d58589..000000000 --- a/passwordcheck.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {347747C8-5EE7-4997-86A7-2008CF07C2AB} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\passwordcheck\ - .\Debug\passwordcheck\ - false - .\Release\passwordcheck\ - .\Release\passwordcheck\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\passwordcheck\ - .\Debug\passwordcheck\ - .\Debug\passwordcheck\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\passwordcheck\passwordcheck.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\passwordcheck\passwordcheck.pdb - false - .\Debug\passwordcheck\passwordcheck.map - Console - MachineX86 - Debug\passwordcheck\passwordcheck.lib - .\Debug\passwordcheck\passwordcheck.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\passwordcheck Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\passwordcheck\ - .\Release\passwordcheck\ - .\Release\passwordcheck\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\passwordcheck\passwordcheck.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\passwordcheck\passwordcheck.pdb - false - .\Release\passwordcheck\passwordcheck.map - Console - MachineX86 - Release\passwordcheck\passwordcheck.lib - .\Release\passwordcheck\passwordcheck.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\passwordcheck Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/pg_archivecleanup.vcxproj b/pg_archivecleanup.vcxproj deleted file mode 100644 index 5d907bc5c..000000000 --- a/pg_archivecleanup.vcxproj +++ /dev/null @@ -1,137 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {F55B2A2B-65F4-4483-9BFC-B77FA49BB119} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pg_archivecleanup\ - .\Debug\pg_archivecleanup\ - false - .\Release\pg_archivecleanup\ - .\Release\pg_archivecleanup\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pg_archivecleanup\ - .\Debug\pg_archivecleanup\ - .\Debug\pg_archivecleanup\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pg_archivecleanup\pg_archivecleanup.exe - Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pg_archivecleanup\pg_archivecleanup.pdb - false - .\Debug\pg_archivecleanup\pg_archivecleanup.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pg_archivecleanup\ - .\Release\pg_archivecleanup\ - .\Release\pg_archivecleanup\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pg_archivecleanup\pg_archivecleanup.exe - Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pg_archivecleanup\pg_archivecleanup.pdb - false - .\Release\pg_archivecleanup\pg_archivecleanup.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/pg_basebackup.vcxproj b/pg_basebackup.vcxproj deleted file mode 100644 index ba439e334..000000000 --- a/pg_basebackup.vcxproj +++ /dev/null @@ -1,145 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {7661F783-3F96-45E1-80E7-49443443AA20} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pg_basebackup\ - .\Debug\pg_basebackup\ - false - .\Release\pg_basebackup\ - .\Release\pg_basebackup\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pg_basebackup\ - .\Debug\pg_basebackup\ - .\Debug\pg_basebackup\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pg_basebackup\pg_basebackup.exe - Debug\libpgport\libpgport.lib;Debug\libpq\libpq.lib;ws2_32.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pg_basebackup\pg_basebackup.pdb - false - .\Debug\pg_basebackup\pg_basebackup.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pg_basebackup\ - .\Release\pg_basebackup\ - .\Release\pg_basebackup\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pg_basebackup\pg_basebackup.exe - Release\libpgport\libpgport.lib;Release\libpq\libpq.lib;ws2_32.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pg_basebackup\pg_basebackup.pdb - false - .\Release\pg_basebackup\pg_basebackup.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - - - - \ No newline at end of file diff --git a/pg_buffercache.vcxproj b/pg_buffercache.vcxproj deleted file mode 100644 index 56010789b..000000000 --- a/pg_buffercache.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {2CB80B60-5D05-45A3-81AD-F9114E42EAB3} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pg_buffercache\ - .\Debug\pg_buffercache\ - false - .\Release\pg_buffercache\ - .\Release\pg_buffercache\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pg_buffercache\ - .\Debug\pg_buffercache\ - .\Debug\pg_buffercache\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pg_buffercache\pg_buffercache.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pg_buffercache\pg_buffercache.pdb - false - .\Debug\pg_buffercache\pg_buffercache.map - Console - MachineX86 - Debug\pg_buffercache\pg_buffercache.lib - .\Debug\pg_buffercache\pg_buffercache.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\pg_buffercache Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pg_buffercache\ - .\Release\pg_buffercache\ - .\Release\pg_buffercache\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pg_buffercache\pg_buffercache.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pg_buffercache\pg_buffercache.pdb - false - .\Release\pg_buffercache\pg_buffercache.map - Console - MachineX86 - Release\pg_buffercache\pg_buffercache.lib - .\Release\pg_buffercache\pg_buffercache.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\pg_buffercache Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/pg_config.vcxproj b/pg_config.vcxproj deleted file mode 100644 index 0b43b8b95..000000000 --- a/pg_config.vcxproj +++ /dev/null @@ -1,140 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {F6096EC4-0721-495B-8202-1800682F96BF} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pg_config\ - .\Debug\pg_config\ - false - .\Release\pg_config\ - .\Release\pg_config\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pg_config\ - .\Debug\pg_config\ - .\Debug\pg_config\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pg_config\pg_config.exe - Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pg_config\pg_config.pdb - false - .\Debug\pg_config\pg_config.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pg_config\ - .\Release\pg_config\ - .\Release\pg_config\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pg_config\pg_config.exe - Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pg_config\pg_config.pdb - false - .\Release\pg_config\pg_config.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/pg_controldata.vcxproj b/pg_controldata.vcxproj deleted file mode 100644 index 92b6c7332..000000000 --- a/pg_controldata.vcxproj +++ /dev/null @@ -1,140 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {4966F788-1EDB-4844-B245-65016EFDC9CA} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pg_controldata\ - .\Debug\pg_controldata\ - false - .\Release\pg_controldata\ - .\Release\pg_controldata\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pg_controldata\ - .\Debug\pg_controldata\ - .\Debug\pg_controldata\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pg_controldata\pg_controldata.exe - Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pg_controldata\pg_controldata.pdb - false - .\Debug\pg_controldata\pg_controldata.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pg_controldata\ - .\Release\pg_controldata\ - .\Release\pg_controldata\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pg_controldata\pg_controldata.exe - Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pg_controldata\pg_controldata.pdb - false - .\Release\pg_controldata\pg_controldata.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/pg_ctl.vcxproj b/pg_ctl.vcxproj deleted file mode 100644 index aa8e10554..000000000 --- a/pg_ctl.vcxproj +++ /dev/null @@ -1,143 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {94F2334E-E892-421F-896F-47BF5ED9B4D7} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pg_ctl\ - .\Debug\pg_ctl\ - false - .\Release\pg_ctl\ - .\Release\pg_ctl\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pg_ctl\ - .\Debug\pg_ctl\ - .\Debug\pg_ctl\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pg_ctl\pg_ctl.exe - Debug\libpgport\libpgport.lib;Debug\libpq\libpq.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pg_ctl\pg_ctl.pdb - false - .\Debug\pg_ctl\pg_ctl.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pg_ctl\ - .\Release\pg_ctl\ - .\Release\pg_ctl\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pg_ctl\pg_ctl.exe - Release\libpgport\libpgport.lib;Release\libpq\libpq.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pg_ctl\pg_ctl.pdb - false - .\Release\pg_ctl\pg_ctl.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - - - - \ No newline at end of file diff --git a/pg_dump.vcxproj b/pg_dump.vcxproj deleted file mode 100644 index 76fc5cf4e..000000000 --- a/pg_dump.vcxproj +++ /dev/null @@ -1,156 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {FEA58411-5CD9-41BE-A6E3-24B60B6087B2} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pg_dump\ - .\Debug\pg_dump\ - false - .\Release\pg_dump\ - .\Release\pg_dump\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\backend;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pg_dump\ - .\Debug\pg_dump\ - .\Debug\pg_dump\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pg_dump\pg_dump.exe - Debug\libpgport\libpgport.lib;Debug\libpq\libpq.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pg_dump\pg_dump.pdb - false - .\Debug\pg_dump\pg_dump.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\backend;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pg_dump\ - .\Release\pg_dump\ - .\Release\pg_dump\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pg_dump\pg_dump.exe - Release\libpgport\libpgport.lib;Release\libpq\libpq.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pg_dump\pg_dump.pdb - false - .\Release\pg_dump\pg_dump.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - - - - - - - - - - - - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - - - - \ No newline at end of file diff --git a/pg_dumpall.vcxproj b/pg_dumpall.vcxproj deleted file mode 100644 index a731722c2..000000000 --- a/pg_dumpall.vcxproj +++ /dev/null @@ -1,147 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {2C8A8B8C-72F5-4B9E-AB81-04D117DDB061} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pg_dumpall\ - .\Debug\pg_dumpall\ - false - .\Release\pg_dumpall\ - .\Release\pg_dumpall\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\backend;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pg_dumpall\ - .\Debug\pg_dumpall\ - .\Debug\pg_dumpall\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pg_dumpall\pg_dumpall.exe - Debug\libpgport\libpgport.lib;Debug\libpq\libpq.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pg_dumpall\pg_dumpall.pdb - false - .\Debug\pg_dumpall\pg_dumpall.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\backend;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pg_dumpall\ - .\Release\pg_dumpall\ - .\Release\pg_dumpall\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pg_dumpall\pg_dumpall.exe - Release\libpgport\libpgport.lib;Release\libpq\libpq.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pg_dumpall\pg_dumpall.pdb - false - .\Release\pg_dumpall\pg_dumpall.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - - - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - - - - \ No newline at end of file diff --git a/pg_freespacemap.vcxproj b/pg_freespacemap.vcxproj deleted file mode 100644 index 1b1cee0d0..000000000 --- a/pg_freespacemap.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {23654B58-D0B5-475A-9E96-7D69C3BD928B} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pg_freespacemap\ - .\Debug\pg_freespacemap\ - false - .\Release\pg_freespacemap\ - .\Release\pg_freespacemap\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pg_freespacemap\ - .\Debug\pg_freespacemap\ - .\Debug\pg_freespacemap\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pg_freespacemap\pg_freespacemap.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pg_freespacemap\pg_freespacemap.pdb - false - .\Debug\pg_freespacemap\pg_freespacemap.map - Console - MachineX86 - Debug\pg_freespacemap\pg_freespacemap.lib - .\Debug\pg_freespacemap\pg_freespacemap.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\pg_freespacemap Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pg_freespacemap\ - .\Release\pg_freespacemap\ - .\Release\pg_freespacemap\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pg_freespacemap\pg_freespacemap.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pg_freespacemap\pg_freespacemap.pdb - false - .\Release\pg_freespacemap\pg_freespacemap.map - Console - MachineX86 - Release\pg_freespacemap\pg_freespacemap.lib - .\Release\pg_freespacemap\pg_freespacemap.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\pg_freespacemap Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/pg_isolation_regress.vcxproj b/pg_isolation_regress.vcxproj deleted file mode 100644 index 72920e501..000000000 --- a/pg_isolation_regress.vcxproj +++ /dev/null @@ -1,138 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {F8AFC6F1-FC31-4265-A503-A06E6D802C0A} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pg_isolation_regress\ - .\Debug\pg_isolation_regress\ - false - .\Release\pg_isolation_regress\ - .\Release\pg_isolation_regress\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\port;src\test\regress;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;HOST_TUPLE="i686-pc-win32vc";FRONTEND;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pg_isolation_regress\ - .\Debug\pg_isolation_regress\ - .\Debug\pg_isolation_regress\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pg_isolation_regress\pg_isolation_regress.exe - Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pg_isolation_regress\pg_isolation_regress.pdb - false - .\Debug\pg_isolation_regress\pg_isolation_regress.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\port;src\test\regress;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;HOST_TUPLE="i686-pc-win32vc";FRONTEND;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pg_isolation_regress\ - .\Release\pg_isolation_regress\ - .\Release\pg_isolation_regress\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pg_isolation_regress\pg_isolation_regress.exe - Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pg_isolation_regress\pg_isolation_regress.pdb - false - .\Release\pg_isolation_regress\pg_isolation_regress.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/pg_receivexlog.vcxproj b/pg_receivexlog.vcxproj deleted file mode 100644 index 241fe456b..000000000 --- a/pg_receivexlog.vcxproj +++ /dev/null @@ -1,145 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {5B906F6D-9122-4886-B041-F43A1399A24A} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pg_receivexlog\ - .\Debug\pg_receivexlog\ - false - .\Release\pg_receivexlog\ - .\Release\pg_receivexlog\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pg_receivexlog\ - .\Debug\pg_receivexlog\ - .\Debug\pg_receivexlog\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pg_receivexlog\pg_receivexlog.exe - Debug\libpgport\libpgport.lib;Debug\libpq\libpq.lib;ws2_32.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pg_receivexlog\pg_receivexlog.pdb - false - .\Debug\pg_receivexlog\pg_receivexlog.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pg_receivexlog\ - .\Release\pg_receivexlog\ - .\Release\pg_receivexlog\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pg_receivexlog\pg_receivexlog.exe - Release\libpgport\libpgport.lib;Release\libpq\libpq.lib;ws2_32.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pg_receivexlog\pg_receivexlog.pdb - false - .\Release\pg_receivexlog\pg_receivexlog.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - - - - \ No newline at end of file diff --git a/pg_regress.vcxproj b/pg_regress.vcxproj deleted file mode 100644 index 792d3605d..000000000 --- a/pg_regress.vcxproj +++ /dev/null @@ -1,138 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {F2C81A91-E309-42DB-AEC4-BBC2F6A41A02} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pg_regress\ - .\Debug\pg_regress\ - false - .\Release\pg_regress\ - .\Release\pg_regress\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\port;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;HOST_TUPLE="i686-pc-win32vc";_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pg_regress\ - .\Debug\pg_regress\ - .\Debug\pg_regress\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pg_regress\pg_regress.exe - Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pg_regress\pg_regress.pdb - false - .\Debug\pg_regress\pg_regress.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\port;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;HOST_TUPLE="i686-pc-win32vc";_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pg_regress\ - .\Release\pg_regress\ - .\Release\pg_regress\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pg_regress\pg_regress.exe - Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pg_regress\pg_regress.pdb - false - .\Release\pg_regress\pg_regress.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/pg_regress_ecpg.vcxproj b/pg_regress_ecpg.vcxproj deleted file mode 100644 index a70d88566..000000000 --- a/pg_regress_ecpg.vcxproj +++ /dev/null @@ -1,138 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {6A480FCD-216D-4DC8-BB5D-6C91CBAC9501} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pg_regress_ecpg\ - .\Debug\pg_regress_ecpg\ - false - .\Release\pg_regress_ecpg\ - .\Release\pg_regress_ecpg\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\port;src\test\regress;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;HOST_TUPLE="i686-pc-win32vc";FRONTEND;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pg_regress_ecpg\ - .\Debug\pg_regress_ecpg\ - .\Debug\pg_regress_ecpg\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pg_regress_ecpg\pg_regress_ecpg.exe - Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pg_regress_ecpg\pg_regress_ecpg.pdb - false - .\Debug\pg_regress_ecpg\pg_regress_ecpg.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\port;src\test\regress;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;HOST_TUPLE="i686-pc-win32vc";FRONTEND;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pg_regress_ecpg\ - .\Release\pg_regress_ecpg\ - .\Release\pg_regress_ecpg\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pg_regress_ecpg\pg_regress_ecpg.exe - Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pg_regress_ecpg\pg_regress_ecpg.pdb - false - .\Release\pg_regress_ecpg\pg_regress_ecpg.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/pg_resetxlog.vcxproj b/pg_resetxlog.vcxproj deleted file mode 100644 index d0c061337..000000000 --- a/pg_resetxlog.vcxproj +++ /dev/null @@ -1,140 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {94935475-F701-4CA4-9B35-4378461F461E} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pg_resetxlog\ - .\Debug\pg_resetxlog\ - false - .\Release\pg_resetxlog\ - .\Release\pg_resetxlog\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pg_resetxlog\ - .\Debug\pg_resetxlog\ - .\Debug\pg_resetxlog\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pg_resetxlog\pg_resetxlog.exe - Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pg_resetxlog\pg_resetxlog.pdb - false - .\Debug\pg_resetxlog\pg_resetxlog.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pg_resetxlog\ - .\Release\pg_resetxlog\ - .\Release\pg_resetxlog\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pg_resetxlog\pg_resetxlog.exe - Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pg_resetxlog\pg_resetxlog.pdb - false - .\Release\pg_resetxlog\pg_resetxlog.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/pg_restore.vcxproj b/pg_restore.vcxproj deleted file mode 100644 index 14a1ffd65..000000000 --- a/pg_restore.vcxproj +++ /dev/null @@ -1,154 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {D0F796AB-91EF-4E80-BB30-2AA3B908F341} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pg_restore\ - .\Debug\pg_restore\ - false - .\Release\pg_restore\ - .\Release\pg_restore\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\backend;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pg_restore\ - .\Debug\pg_restore\ - .\Debug\pg_restore\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pg_restore\pg_restore.exe - Debug\libpgport\libpgport.lib;Debug\libpq\libpq.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pg_restore\pg_restore.pdb - false - .\Debug\pg_restore\pg_restore.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\backend;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pg_restore\ - .\Release\pg_restore\ - .\Release\pg_restore\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pg_restore\pg_restore.exe - Release\libpgport\libpgport.lib;Release\libpq\libpq.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pg_restore\pg_restore.pdb - false - .\Release\pg_restore\pg_restore.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - - - - - - - - - - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - - - - \ No newline at end of file diff --git a/pg_standby.vcxproj b/pg_standby.vcxproj deleted file mode 100644 index 5d0836b99..000000000 --- a/pg_standby.vcxproj +++ /dev/null @@ -1,137 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {B1FF92DE-48CA-406D-9118-E29BB9E8E819} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pg_standby\ - .\Debug\pg_standby\ - false - .\Release\pg_standby\ - .\Release\pg_standby\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pg_standby\ - .\Debug\pg_standby\ - .\Debug\pg_standby\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pg_standby\pg_standby.exe - Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pg_standby\pg_standby.pdb - false - .\Debug\pg_standby\pg_standby.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pg_standby\ - .\Release\pg_standby\ - .\Release\pg_standby\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pg_standby\pg_standby.exe - Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pg_standby\pg_standby.pdb - false - .\Release\pg_standby\pg_standby.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/pg_stat_statements.vcxproj b/pg_stat_statements.vcxproj deleted file mode 100644 index 533839068..000000000 --- a/pg_stat_statements.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {B6AF665A-AE84-4DC0-B533-E764057C4F71} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pg_stat_statements\ - .\Debug\pg_stat_statements\ - false - .\Release\pg_stat_statements\ - .\Release\pg_stat_statements\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pg_stat_statements\ - .\Debug\pg_stat_statements\ - .\Debug\pg_stat_statements\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pg_stat_statements\pg_stat_statements.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pg_stat_statements\pg_stat_statements.pdb - false - .\Debug\pg_stat_statements\pg_stat_statements.map - Console - MachineX86 - Debug\pg_stat_statements\pg_stat_statements.lib - .\Debug\pg_stat_statements\pg_stat_statements.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\pg_stat_statements Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pg_stat_statements\ - .\Release\pg_stat_statements\ - .\Release\pg_stat_statements\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pg_stat_statements\pg_stat_statements.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pg_stat_statements\pg_stat_statements.pdb - false - .\Release\pg_stat_statements\pg_stat_statements.map - Console - MachineX86 - Release\pg_stat_statements\pg_stat_statements.lib - .\Release\pg_stat_statements\pg_stat_statements.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\pg_stat_statements Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/pg_test_fsync.vcxproj b/pg_test_fsync.vcxproj deleted file mode 100644 index 9a27af4a4..000000000 --- a/pg_test_fsync.vcxproj +++ /dev/null @@ -1,137 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {3F4978A3-CC0C-4A5A-8520-E2D046539D83} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pg_test_fsync\ - .\Debug\pg_test_fsync\ - false - .\Release\pg_test_fsync\ - .\Release\pg_test_fsync\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pg_test_fsync\ - .\Debug\pg_test_fsync\ - .\Debug\pg_test_fsync\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pg_test_fsync\pg_test_fsync.exe - Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pg_test_fsync\pg_test_fsync.pdb - false - .\Debug\pg_test_fsync\pg_test_fsync.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pg_test_fsync\ - .\Release\pg_test_fsync\ - .\Release\pg_test_fsync\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pg_test_fsync\pg_test_fsync.exe - Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pg_test_fsync\pg_test_fsync.pdb - false - .\Release\pg_test_fsync\pg_test_fsync.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/pg_test_timing.vcxproj b/pg_test_timing.vcxproj deleted file mode 100644 index 8f3016a37..000000000 --- a/pg_test_timing.vcxproj +++ /dev/null @@ -1,137 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {D1064F31-099A-4C66-9219-EFF771EB069D} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pg_test_timing\ - .\Debug\pg_test_timing\ - false - .\Release\pg_test_timing\ - .\Release\pg_test_timing\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pg_test_timing\ - .\Debug\pg_test_timing\ - .\Debug\pg_test_timing\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pg_test_timing\pg_test_timing.exe - Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pg_test_timing\pg_test_timing.pdb - false - .\Debug\pg_test_timing\pg_test_timing.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pg_test_timing\ - .\Release\pg_test_timing\ - .\Release\pg_test_timing\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pg_test_timing\pg_test_timing.exe - Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pg_test_timing\pg_test_timing.pdb - false - .\Release\pg_test_timing\pg_test_timing.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/pg_trgm.vcxproj b/pg_trgm.vcxproj deleted file mode 100644 index 98b8e90c2..000000000 --- a/pg_trgm.vcxproj +++ /dev/null @@ -1,151 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {3480B244-37AD-4DB8-9C6C-C0A24B2F7DEB} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pg_trgm\ - .\Debug\pg_trgm\ - false - .\Release\pg_trgm\ - .\Release\pg_trgm\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pg_trgm\ - .\Debug\pg_trgm\ - .\Debug\pg_trgm\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pg_trgm\pg_trgm.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pg_trgm\pg_trgm.pdb - false - .\Debug\pg_trgm\pg_trgm.map - Console - MachineX86 - Debug\pg_trgm\pg_trgm.lib - .\Debug\pg_trgm\pg_trgm.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\pg_trgm Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pg_trgm\ - .\Release\pg_trgm\ - .\Release\pg_trgm\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pg_trgm\pg_trgm.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pg_trgm\pg_trgm.pdb - false - .\Release\pg_trgm\pg_trgm.map - Console - MachineX86 - Release\pg_trgm\pg_trgm.lib - .\Release\pg_trgm\pg_trgm.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\pg_trgm Win32 - - - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/pg_upgrade.vcxproj b/pg_upgrade.vcxproj deleted file mode 100644 index 84c59d5c6..000000000 --- a/pg_upgrade.vcxproj +++ /dev/null @@ -1,155 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {4B562B01-7B08-4B63-A1C8-01D8F1F9969D} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pg_upgrade\ - .\Debug\pg_upgrade\ - false - .\Release\pg_upgrade\ - .\Release\pg_upgrade\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pg_upgrade\ - .\Debug\pg_upgrade\ - .\Debug\pg_upgrade\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pg_upgrade\pg_upgrade.exe - Debug\libpq\libpq.lib;Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pg_upgrade\pg_upgrade.pdb - false - .\Debug\pg_upgrade\pg_upgrade.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pg_upgrade\ - .\Release\pg_upgrade\ - .\Release\pg_upgrade\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pg_upgrade\pg_upgrade.exe - Release\libpq\libpq.lib;Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pg_upgrade\pg_upgrade.pdb - false - .\Release\pg_upgrade\pg_upgrade.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - - - - - - - - - - - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/pg_upgrade_support.vcxproj b/pg_upgrade_support.vcxproj deleted file mode 100644 index fe2d9ca20..000000000 --- a/pg_upgrade_support.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {21368D6F-3672-46E6-BC6B-C1E8B8DB5882} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pg_upgrade_support\ - .\Debug\pg_upgrade_support\ - false - .\Release\pg_upgrade_support\ - .\Release\pg_upgrade_support\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pg_upgrade_support\ - .\Debug\pg_upgrade_support\ - .\Debug\pg_upgrade_support\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pg_upgrade_support\pg_upgrade_support.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pg_upgrade_support\pg_upgrade_support.pdb - false - .\Debug\pg_upgrade_support\pg_upgrade_support.map - Console - MachineX86 - Debug\pg_upgrade_support\pg_upgrade_support.lib - .\Debug\pg_upgrade_support\pg_upgrade_support.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\pg_upgrade_support Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pg_upgrade_support\ - .\Release\pg_upgrade_support\ - .\Release\pg_upgrade_support\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pg_upgrade_support\pg_upgrade_support.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pg_upgrade_support\pg_upgrade_support.pdb - false - .\Release\pg_upgrade_support\pg_upgrade_support.map - Console - MachineX86 - Release\pg_upgrade_support\pg_upgrade_support.lib - .\Release\pg_upgrade_support\pg_upgrade_support.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\pg_upgrade_support Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/pgbench.vcxproj b/pgbench.vcxproj deleted file mode 100644 index 6022590c8..000000000 --- a/pgbench.vcxproj +++ /dev/null @@ -1,140 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {202D3C84-B981-49D9-98D2-645E2A47BFA8} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pgbench\ - .\Debug\pgbench\ - false - .\Release\pgbench\ - .\Release\pgbench\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pgbench\ - .\Debug\pgbench\ - .\Debug\pgbench\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pgbench\pgbench.exe - Debug\libpq\libpq.lib;Debug\libpgport\libpgport.lib;wsock32.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pgbench\pgbench.pdb - false - .\Debug\pgbench\pgbench.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pgbench\ - .\Release\pgbench\ - .\Release\pgbench\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pgbench\pgbench.exe - Release\libpq\libpq.lib;Release\libpgport\libpgport.lib;wsock32.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pgbench\pgbench.pdb - false - .\Release\pgbench\pgbench.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/pgcrypto.vcxproj b/pgcrypto.vcxproj deleted file mode 100644 index 3459208f8..000000000 --- a/pgcrypto.vcxproj +++ /dev/null @@ -1,181 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {DD12548A-561F-49EC-8F8F-2BCC045339E2} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pgcrypto\ - .\Debug\pgcrypto\ - false - .\Release\pgcrypto\ - .\Release\pgcrypto\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pgcrypto\ - .\Debug\pgcrypto\ - .\Debug\pgcrypto\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pgcrypto\pgcrypto.dll - Debug\postgres\postgres.lib;wsock32.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pgcrypto\pgcrypto.pdb - false - .\Debug\pgcrypto\pgcrypto.map - Console - MachineX86 - Debug\pgcrypto\pgcrypto.lib - .\Debug\pgcrypto\pgcrypto.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\pgcrypto Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pgcrypto\ - .\Release\pgcrypto\ - .\Release\pgcrypto\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pgcrypto\pgcrypto.dll - Release\postgres\postgres.lib;wsock32.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pgcrypto\pgcrypto.pdb - false - .\Release\pgcrypto\pgcrypto.map - Console - MachineX86 - Release\pgcrypto\pgcrypto.lib - .\Release\pgcrypto\pgcrypto.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\pgcrypto Win32 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/pgevent.vcxproj b/pgevent.vcxproj deleted file mode 100644 index 1ea9b29a3..000000000 --- a/pgevent.vcxproj +++ /dev/null @@ -1,139 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {65AE7FA8-9E48-494D-A0FC-789C65847608} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pgevent\ - .\Debug\pgevent\ - false - .\Release\pgevent\ - .\Release\pgevent\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pgevent\ - .\Debug\pgevent\ - .\Debug\pgevent\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pgevent\pgevent.dll - ;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pgevent\pgevent.pdb - false - .\Debug\pgevent\pgevent.map - Console - MachineX86 - /ignore:4104 %(AdditionalOptions) - src\bin\pgevent\pgevent.def - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pgevent\ - .\Release\pgevent\ - .\Release\pgevent\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pgevent\pgevent.dll - ;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pgevent\pgevent.pdb - false - .\Release\pgevent\pgevent.map - Console - MachineX86 - /ignore:4104 %(AdditionalOptions) - src\bin\pgevent\pgevent.def - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - - \ No newline at end of file diff --git a/pgrowlocks.vcxproj b/pgrowlocks.vcxproj deleted file mode 100644 index 2991f91b4..000000000 --- a/pgrowlocks.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {D4FFEFC1-D9A7-4F54-813B-BD3DF1CEB4CA} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pgrowlocks\ - .\Debug\pgrowlocks\ - false - .\Release\pgrowlocks\ - .\Release\pgrowlocks\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pgrowlocks\ - .\Debug\pgrowlocks\ - .\Debug\pgrowlocks\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pgrowlocks\pgrowlocks.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pgrowlocks\pgrowlocks.pdb - false - .\Debug\pgrowlocks\pgrowlocks.map - Console - MachineX86 - Debug\pgrowlocks\pgrowlocks.lib - .\Debug\pgrowlocks\pgrowlocks.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\pgrowlocks Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pgrowlocks\ - .\Release\pgrowlocks\ - .\Release\pgrowlocks\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pgrowlocks\pgrowlocks.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pgrowlocks\pgrowlocks.pdb - false - .\Release\pgrowlocks\pgrowlocks.map - Console - MachineX86 - Release\pgrowlocks\pgrowlocks.lib - .\Release\pgrowlocks\pgrowlocks.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\pgrowlocks Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/pgstattuple.vcxproj b/pgstattuple.vcxproj deleted file mode 100644 index 82037ba5b..000000000 --- a/pgstattuple.vcxproj +++ /dev/null @@ -1,150 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {015920A8-39A9-47F0-80ED-EAAD34CB500C} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\pgstattuple\ - .\Debug\pgstattuple\ - false - .\Release\pgstattuple\ - .\Release\pgstattuple\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\pgstattuple\ - .\Debug\pgstattuple\ - .\Debug\pgstattuple\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\pgstattuple\pgstattuple.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\pgstattuple\pgstattuple.pdb - false - .\Debug\pgstattuple\pgstattuple.map - Console - MachineX86 - Debug\pgstattuple\pgstattuple.lib - .\Debug\pgstattuple\pgstattuple.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\pgstattuple Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\pgstattuple\ - .\Release\pgstattuple\ - .\Release\pgstattuple\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\pgstattuple\pgstattuple.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\pgstattuple\pgstattuple.pdb - false - .\Release\pgstattuple\pgstattuple.map - Console - MachineX86 - Release\pgstattuple\pgstattuple.lib - .\Release\pgstattuple\pgstattuple.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\pgstattuple Win32 - - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/plpgsql.vcxproj b/plpgsql.vcxproj deleted file mode 100644 index 13ff0fe38..000000000 --- a/plpgsql.vcxproj +++ /dev/null @@ -1,166 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {976D6975-60EB-4CA4-8729-16FC7BE2C7A4} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\plpgsql\ - .\Debug\plpgsql\ - false - .\Release\plpgsql\ - .\Release\plpgsql\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\plpgsql\ - .\Debug\plpgsql\ - .\Debug\plpgsql\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\plpgsql\plpgsql.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\plpgsql\plpgsql.pdb - false - .\Debug\plpgsql\plpgsql.map - Console - MachineX86 - Debug\plpgsql\plpgsql.lib - .\Debug\plpgsql\plpgsql.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\plpgsql Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\plpgsql\ - .\Release\plpgsql\ - .\Release\plpgsql\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\plpgsql\plpgsql.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\plpgsql\plpgsql.pdb - false - .\Release\plpgsql\plpgsql.map - Console - MachineX86 - Release\plpgsql\plpgsql.lib - .\Release\plpgsql\plpgsql.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\plpgsql Win32 - - - - - - - - - - - - - Running bison on src\pl\plpgsql\src\gram.y - perl "src\tools\msvc\pgbison.pl" "src\pl\plpgsql\src\gram.y" - %(AdditionalInputs) - src\pl\plpgsql\src\pl_gram.c;%(Outputs) - Running bison on src\pl\plpgsql\src\gram.y - perl "src\tools\msvc\pgbison.pl" "src\pl\plpgsql\src\gram.y" - %(AdditionalInputs) - src\pl\plpgsql\src\pl_gram.c;%(Outputs) - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/postgres.vcxproj b/postgres.vcxproj deleted file mode 100644 index 4208c46f0..000000000 --- a/postgres.vcxproj +++ /dev/null @@ -1,763 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\postgres\ - .\Debug\postgres\ - false - .\Release\postgres\ - .\Release\postgres\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\backend;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;BUILDING_DLL;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\postgres\ - .\Debug\postgres\ - .\Debug\postgres\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\postgres\postgres.exe - wsock32.lib;ws2_32.lib;secur32.lib;wldap32.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\postgres\postgres.pdb - false - .\Debug\postgres\postgres.map - Console - MachineX86 - Debug\postgres\postgres.lib - .\Debug\postgres\postgres.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\postgres Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\backend;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;BUILDING_DLL;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\postgres\ - .\Release\postgres\ - .\Release\postgres\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\postgres\postgres.exe - wsock32.lib;ws2_32.lib;secur32.lib;wldap32.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\postgres\postgres.pdb - false - .\Release\postgres\postgres.map - Console - MachineX86 - Release\postgres\postgres.lib - .\Release\postgres\postgres.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\postgres Win32 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - .\debug\postgres\src_backend_parser_analyze.obj - .\release\postgres\src_backend_parser_analyze.obj - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - .\debug\postgres\src_port_crypt.obj - .\release\postgres\src_port_crypt.obj - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Running bison on src\backend\bootstrap\bootparse.y - perl "src\tools\msvc\pgbison.pl" "src\backend\bootstrap\bootparse.y" - %(AdditionalInputs) - src\backend\bootstrap\bootparse.c;%(Outputs) - Running bison on src\backend\bootstrap\bootparse.y - perl "src\tools\msvc\pgbison.pl" "src\backend\bootstrap\bootparse.y" - %(AdditionalInputs) - src\backend\bootstrap\bootparse.c;%(Outputs) - - - Running flex on src\backend\bootstrap\bootscanner.l - perl "src\tools\msvc\pgflex.pl" "src\backend\bootstrap\bootscanner.l" - %(AdditionalInputs) - src\backend\bootstrap\bootscanner.c;%(Outputs) - Running flex on src\backend\bootstrap\bootscanner.l - perl "src\tools\msvc\pgflex.pl" "src\backend\bootstrap\bootscanner.l" - %(AdditionalInputs) - src\backend\bootstrap\bootscanner.c;%(Outputs) - - - Running bison on src\backend\parser\gram.y - perl "src\tools\msvc\pgbison.pl" "src\backend\parser\gram.y" - %(AdditionalInputs) - src\backend\parser\gram.c;%(Outputs) - Running bison on src\backend\parser\gram.y - perl "src\tools\msvc\pgbison.pl" "src\backend\parser\gram.y" - %(AdditionalInputs) - src\backend\parser\gram.c;%(Outputs) - - - Running flex on src\backend\parser\scan.l - perl "src\tools\msvc\pgflex.pl" "src\backend\parser\scan.l" - %(AdditionalInputs) - src\backend\parser\scan.c;%(Outputs) - Running flex on src\backend\parser\scan.l - perl "src\tools\msvc\pgflex.pl" "src\backend\parser\scan.l" - %(AdditionalInputs) - src\backend\parser\scan.c;%(Outputs) - - - Running bison on src\backend\replication\repl_gram.y - perl "src\tools\msvc\pgbison.pl" "src\backend\replication\repl_gram.y" - %(AdditionalInputs) - src\backend\replication\repl_gram.c;%(Outputs) - Running bison on src\backend\replication\repl_gram.y - perl "src\tools\msvc\pgbison.pl" "src\backend\replication\repl_gram.y" - %(AdditionalInputs) - src\backend\replication\repl_gram.c;%(Outputs) - - - Running flex on src\backend\replication\repl_scanner.l - perl "src\tools\msvc\pgflex.pl" "src\backend\replication\repl_scanner.l" - %(AdditionalInputs) - src\backend\replication\repl_scanner.c;%(Outputs) - Running flex on src\backend\replication\repl_scanner.l - perl "src\tools\msvc\pgflex.pl" "src\backend\replication\repl_scanner.l" - %(AdditionalInputs) - src\backend\replication\repl_scanner.c;%(Outputs) - - - Running flex on src\backend\utils\misc\guc-file.l - perl "src\tools\msvc\pgflex.pl" "src\backend\utils\misc\guc-file.l" - %(AdditionalInputs) - src\backend\utils\misc\guc-file.c;%(Outputs) - Running flex on src\backend\utils\misc\guc-file.l - perl "src\tools\msvc\pgflex.pl" "src\backend\utils\misc\guc-file.l" - %(AdditionalInputs) - src\backend\utils\misc\guc-file.c;%(Outputs) - - - - - - - - - \ No newline at end of file diff --git a/psql.vcxproj b/psql.vcxproj deleted file mode 100644 index 28fc05598..000000000 --- a/psql.vcxproj +++ /dev/null @@ -1,173 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {F51951C5-9C5F-40BB-9DE4-1DB2117EFD8B} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\psql\ - .\Debug\psql\ - false - .\Release\psql\ - .\Release\psql\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\bin\pg_dump;src\backend;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\psql\ - .\Debug\psql\ - .\Debug\psql\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\psql\psql.exe - Debug\libpgport\libpgport.lib;Debug\libpq\libpq.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\psql\psql.pdb - false - .\Debug\psql\psql.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\bin\pg_dump;src\backend;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\psql\ - .\Release\psql\ - .\Release\psql\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\psql\psql.exe - Release\libpgport\libpgport.lib;Release\libpq\libpq.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\psql\psql.pdb - false - .\Release\psql\psql.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - - - - - - - - - - - - - - - - Running flex on src\bin\psql\psqlscan.l - perl "src\tools\msvc\pgflex.pl" "src\bin\psql\psqlscan.l" - %(AdditionalInputs) - src\bin\psql\psqlscan.c;%(Outputs) - Running flex on src\bin\psql\psqlscan.l - perl "src\tools\msvc\pgflex.pl" "src\bin\psql\psqlscan.l" - %(AdditionalInputs) - src\bin\psql\psqlscan.c;%(Outputs) - - - - - - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - - - - \ No newline at end of file diff --git a/refint.vcxproj b/refint.vcxproj deleted file mode 100644 index 3b060c662..000000000 --- a/refint.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {E4DDF723-28FA-4654-BFF0-D01F97060D76} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\refint\ - .\Debug\refint\ - false - .\Release\refint\ - .\Release\refint\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;REFINT_VERBOSE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\refint\ - .\Debug\refint\ - .\Debug\refint\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\refint\refint.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\refint\refint.pdb - false - .\Debug\refint\refint.map - Console - MachineX86 - Debug\refint\refint.lib - .\Debug\refint\refint.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\refint Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;REFINT_VERBOSE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\refint\ - .\Release\refint\ - .\Release\refint\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\refint\refint.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\refint\refint.pdb - false - .\Release\refint\refint.map - Console - MachineX86 - Release\refint\refint.lib - .\Release\refint\refint.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\refint Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/regress.vcxproj b/regress.vcxproj deleted file mode 100644 index babb8a4cd..000000000 --- a/regress.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {A12788DE-92A0-4782-A03E-E1960D1F339D} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\regress\ - .\Debug\regress\ - false - .\Release\regress\ - .\Release\regress\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\regress\ - .\Debug\regress\ - .\Debug\regress\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\regress\regress.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\regress\regress.pdb - false - .\Debug\regress\regress.map - Console - MachineX86 - Debug\regress\regress.lib - .\Debug\regress\regress.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\regress Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\regress\ - .\Release\regress\ - .\Release\regress\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\regress\regress.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\regress\regress.pdb - false - .\Release\regress\regress.map - Console - MachineX86 - Release\regress\regress.lib - .\Release\regress\regress.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\regress Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/reindexdb.vcxproj b/reindexdb.vcxproj deleted file mode 100644 index 7ce8dd411..000000000 --- a/reindexdb.vcxproj +++ /dev/null @@ -1,147 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {AD330F96-FD94-4B92-A221-03A9AB9B7866} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\reindexdb\ - .\Debug\reindexdb\ - false - .\Release\reindexdb\ - .\Release\reindexdb\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\bin\pg_dump;src\bin\psql;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\reindexdb\ - .\Debug\reindexdb\ - .\Debug\reindexdb\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\reindexdb\reindexdb.exe - Debug\libpq\libpq.lib;Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\reindexdb\reindexdb.pdb - false - .\Debug\reindexdb\reindexdb.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\bin\pg_dump;src\bin\psql;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\reindexdb\ - .\Release\reindexdb\ - .\Release\reindexdb\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\reindexdb\reindexdb.exe - Release\libpq\libpq.lib;Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\reindexdb\reindexdb.pdb - false - .\Release\reindexdb\reindexdb.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - - - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/seg.vcxproj b/seg.vcxproj deleted file mode 100644 index e85301bfe..000000000 --- a/seg.vcxproj +++ /dev/null @@ -1,172 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {4B22AA5C-0D0F-493A-B5AA-2EBDD8B2DAD0} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\seg\ - .\Debug\seg\ - false - .\Release\seg\ - .\Release\seg\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\seg\ - .\Debug\seg\ - .\Debug\seg\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\seg\seg.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\seg\seg.pdb - false - .\Debug\seg\seg.map - Console - MachineX86 - Debug\seg\seg.lib - .\Debug\seg\seg.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\seg Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\seg\ - .\Release\seg\ - .\Release\seg\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\seg\seg.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\seg\seg.pdb - false - .\Release\seg\seg.map - Console - MachineX86 - Release\seg\seg.lib - .\Release\seg\seg.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\seg Win32 - - - - - - - - - Running bison on contrib\seg\segparse.y - perl "src\tools\msvc\pgbison.pl" "contrib\seg\segparse.y" - %(AdditionalInputs) - contrib\seg\segparse.c;%(Outputs) - Running bison on contrib\seg\segparse.y - perl "src\tools\msvc\pgbison.pl" "contrib\seg\segparse.y" - %(AdditionalInputs) - contrib\seg\segparse.c;%(Outputs) - - - Running flex on contrib\seg\segscan.l - perl "src\tools\msvc\pgflex.pl" "contrib\seg\segscan.l" - %(AdditionalInputs) - contrib\seg\segscan.c;%(Outputs) - Running flex on contrib\seg\segscan.l - perl "src\tools\msvc\pgflex.pl" "contrib\seg\segscan.l" - %(AdditionalInputs) - contrib\seg\segscan.c;%(Outputs) - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/src/.gitignore b/src/.gitignore deleted file mode 100644 index a66aac007..000000000 --- a/src/.gitignore +++ /dev/null @@ -1,3 +0,0 @@ -/Makefile.global -/Makefile.port -/Makefile.custom diff --git a/src/backend/.gitignore b/src/backend/.gitignore deleted file mode 100644 index 4e04ff057..000000000 --- a/src/backend/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -/postgres -/postgres.def diff --git a/src/backend/bootstrap/.gitignore b/src/backend/bootstrap/.gitignore deleted file mode 100644 index 1ffe8ca39..000000000 --- a/src/backend/bootstrap/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -/bootparse.c -/bootscanner.c diff --git a/src/backend/bootstrap/bootparse.c b/src/backend/bootstrap/bootparse.c new file mode 100644 index 000000000..bf41363a6 --- /dev/null +++ b/src/backend/bootstrap/bootparse.c @@ -0,0 +1,2164 @@ + +/* A Bison parser, made by GNU Bison 2.4.1. */ + +/* Skeleton implementation for Bison's Yacc-like parsers in C + + Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 + Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . */ + +/* As a special exception, you may create a larger work that contains + part or all of the Bison parser skeleton and distribute that work + under terms of your choice, so long as that work isn't itself a + parser generator using the skeleton or a modified version thereof + as a parser skeleton. Alternatively, if you modify or redistribute + the parser skeleton itself, you may (at your option) remove this + special exception, which will cause the skeleton and the resulting + Bison output files to be licensed under the GNU General Public + License without this special exception. + + This special exception was added by the Free Software Foundation in + version 2.2 of Bison. */ + +/* C LALR(1) parser skeleton written by Richard Stallman, by + simplifying the original so-called "semantic" parser. */ + +/* All symbols defined below should begin with yy or YY, to avoid + infringing on user name space. This should be done even for local + variables, as they might otherwise be expanded by user macros. + There are some unavoidable exceptions within include files to + define necessary library symbols; they are noted "INFRINGES ON + USER NAME SPACE" below. */ + +/* Identify Bison output. */ +#define YYBISON 1 + +/* Bison version. */ +#define YYBISON_VERSION "2.4.1" + +/* Skeleton name. */ +#define YYSKELETON_NAME "yacc.c" + +/* Pure parsers. */ +#define YYPURE 0 + +/* Push parsers. */ +#define YYPUSH 0 + +/* Pull parsers. */ +#define YYPULL 1 + +/* Using locations. */ +#define YYLSP_NEEDED 0 + +/* Substitute the variable and function names. */ +#define yyparse boot_yyparse +#define yylex boot_yylex +#define yyerror boot_yyerror +#define yylval boot_yylval +#define yychar boot_yychar +#define yydebug boot_yydebug +#define yynerrs boot_yynerrs + + +/* Copy the first part of user declarations. */ + +/* Line 189 of yacc.c */ +#line 1 "bootparse.y" + +/*------------------------------------------------------------------------- + * + * bootparse.y + * yacc grammar for the "bootstrap" mode (BKI file format) + * + * Portions Copyright (c) 1996-2012, PostgreSQL Global Development Group + * Portions Copyright (c) 1994, Regents of the University of California + * + * + * IDENTIFICATION + * src/backend/bootstrap/bootparse.y + * + *------------------------------------------------------------------------- + */ + +#include "postgres.h" + +#include + +#include "access/attnum.h" +#include "access/htup.h" +#include "access/itup.h" +#include "access/skey.h" +#include "access/tupdesc.h" +#include "access/xact.h" +#include "bootstrap/bootstrap.h" +#include "catalog/catalog.h" +#include "catalog/heap.h" +#include "catalog/pg_am.h" +#include "catalog/pg_attribute.h" +#include "catalog/pg_authid.h" +#include "catalog/pg_class.h" +#include "catalog/pg_namespace.h" +#include "catalog/pg_tablespace.h" +#include "catalog/toasting.h" +#include "commands/defrem.h" +#include "miscadmin.h" +#include "nodes/makefuncs.h" +#include "nodes/nodes.h" +#include "nodes/parsenodes.h" +#include "nodes/pg_list.h" +#include "nodes/primnodes.h" +#include "rewrite/prs2lock.h" +#include "storage/block.h" +#include "storage/fd.h" +#include "storage/ipc.h" +#include "storage/itemptr.h" +#include "storage/off.h" +#include "storage/smgr.h" +#include "tcop/dest.h" +#include "utils/rel.h" + +#define atooid(x) ((Oid) strtoul((x), NULL, 10)) + + +/* + * Bison doesn't allocate anything that needs to live across parser calls, + * so we can easily have it use palloc instead of malloc. This prevents + * memory leaks if we error out during parsing. Note this only works with + * bison >= 2.0. However, in bison 1.875 the default is to use alloca() + * if possible, so there's not really much problem anyhow, at least if + * you're building with gcc. + */ +#define YYMALLOC palloc +#define YYFREE pfree + +static void +do_start(void) +{ + StartTransactionCommand(); + elog(DEBUG4, "start transaction"); +} + + +static void +do_end(void) +{ + CommitTransactionCommand(); + elog(DEBUG4, "commit transaction"); + CHECK_FOR_INTERRUPTS(); /* allow SIGINT to kill bootstrap run */ + if (isatty(0)) + { + printf("bootstrap> "); + fflush(stdout); + } +} + + +static int num_columns_read = 0; + + + +/* Line 189 of yacc.c */ +#line 175 "bootparse.c" + +/* Enabling traces. */ +#ifndef YYDEBUG +# define YYDEBUG 0 +#endif + +/* Enabling verbose error messages. */ +#ifdef YYERROR_VERBOSE +# undef YYERROR_VERBOSE +# define YYERROR_VERBOSE 1 +#else +# define YYERROR_VERBOSE 0 +#endif + +/* Enabling the token table. */ +#ifndef YYTOKEN_TABLE +# define YYTOKEN_TABLE 0 +#endif + + +/* Tokens. */ +#ifndef YYTOKENTYPE +# define YYTOKENTYPE + /* Put the tokens into the symbol table, so that GDB and other debuggers + know about them. */ + enum yytokentype { + CONST_P = 258, + ID = 259, + OPEN = 260, + XCLOSE = 261, + XCREATE = 262, + INSERT_TUPLE = 263, + XDECLARE = 264, + INDEX = 265, + ON = 266, + USING = 267, + XBUILD = 268, + INDICES = 269, + UNIQUE = 270, + XTOAST = 271, + COMMA = 272, + EQUALS = 273, + LPAREN = 274, + RPAREN = 275, + OBJ_ID = 276, + XBOOTSTRAP = 277, + XSHARED_RELATION = 278, + XWITHOUT_OIDS = 279, + XROWTYPE_OID = 280, + NULLVAL = 281, + low = 282, + high = 283 + }; +#endif + + + +#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED +typedef union YYSTYPE +{ + +/* Line 214 of yacc.c */ +#line 98 "bootparse.y" + + List *list; + IndexElem *ielem; + char *str; + int ival; + Oid oidval; + + + +/* Line 214 of yacc.c */ +#line 249 "bootparse.c" +} YYSTYPE; +# define YYSTYPE_IS_TRIVIAL 1 +# define yystype YYSTYPE /* obsolescent; will be withdrawn */ +# define YYSTYPE_IS_DECLARED 1 +#endif + + +/* Copy the second part of user declarations. */ + + +/* Line 264 of yacc.c */ +#line 261 "bootparse.c" + +#ifdef short +# undef short +#endif + +#ifdef YYTYPE_UINT8 +typedef YYTYPE_UINT8 yytype_uint8; +#else +typedef unsigned char yytype_uint8; +#endif + +#ifdef YYTYPE_INT8 +typedef YYTYPE_INT8 yytype_int8; +#elif (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +typedef signed char yytype_int8; +#else +typedef short int yytype_int8; +#endif + +#ifdef YYTYPE_UINT16 +typedef YYTYPE_UINT16 yytype_uint16; +#else +typedef unsigned short int yytype_uint16; +#endif + +#ifdef YYTYPE_INT16 +typedef YYTYPE_INT16 yytype_int16; +#else +typedef short int yytype_int16; +#endif + +#ifndef YYSIZE_T +# ifdef __SIZE_TYPE__ +# define YYSIZE_T __SIZE_TYPE__ +# elif defined size_t +# define YYSIZE_T size_t +# elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +# include /* INFRINGES ON USER NAME SPACE */ +# define YYSIZE_T size_t +# else +# define YYSIZE_T unsigned int +# endif +#endif + +#define YYSIZE_MAXIMUM ((YYSIZE_T) -1) + +#ifndef YY_ +# if YYENABLE_NLS +# if ENABLE_NLS +# include /* INFRINGES ON USER NAME SPACE */ +# define YY_(msgid) dgettext ("bison-runtime", msgid) +# endif +# endif +# ifndef YY_ +# define YY_(msgid) msgid +# endif +#endif + +/* Suppress unused-variable warnings by "using" E. */ +#if ! defined lint || defined __GNUC__ +# define YYUSE(e) ((void) (e)) +#else +# define YYUSE(e) /* empty */ +#endif + +/* Identity function, used to suppress warnings about constant conditions. */ +#ifndef lint +# define YYID(n) (n) +#else +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static int +YYID (int yyi) +#else +static int +YYID (yyi) + int yyi; +#endif +{ + return yyi; +} +#endif + +#if ! defined yyoverflow || YYERROR_VERBOSE + +/* The parser invokes alloca or malloc; define the necessary symbols. */ + +# ifdef YYSTACK_USE_ALLOCA +# if YYSTACK_USE_ALLOCA +# ifdef __GNUC__ +# define YYSTACK_ALLOC __builtin_alloca +# elif defined __BUILTIN_VA_ARG_INCR +# include /* INFRINGES ON USER NAME SPACE */ +# elif defined _AIX +# define YYSTACK_ALLOC __alloca +# elif defined _MSC_VER +# include /* INFRINGES ON USER NAME SPACE */ +# define alloca _alloca +# else +# define YYSTACK_ALLOC alloca +# if ! defined _ALLOCA_H && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +# include /* INFRINGES ON USER NAME SPACE */ +# ifndef _STDLIB_H +# define _STDLIB_H 1 +# endif +# endif +# endif +# endif +# endif + +# ifdef YYSTACK_ALLOC + /* Pacify GCC's `empty if-body' warning. */ +# define YYSTACK_FREE(Ptr) do { /* empty */; } while (YYID (0)) +# ifndef YYSTACK_ALLOC_MAXIMUM + /* The OS might guarantee only one guard page at the bottom of the stack, + and a page size can be as small as 4096 bytes. So we cannot safely + invoke alloca (N) if N exceeds 4096. Use a slightly smaller number + to allow for a few compiler-allocated temporary stack slots. */ +# define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */ +# endif +# else +# define YYSTACK_ALLOC YYMALLOC +# define YYSTACK_FREE YYFREE +# ifndef YYSTACK_ALLOC_MAXIMUM +# define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM +# endif +# if (defined __cplusplus && ! defined _STDLIB_H \ + && ! ((defined YYMALLOC || defined malloc) \ + && (defined YYFREE || defined free))) +# include /* INFRINGES ON USER NAME SPACE */ +# ifndef _STDLIB_H +# define _STDLIB_H 1 +# endif +# endif +# ifndef YYMALLOC +# define YYMALLOC malloc +# if ! defined malloc && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */ +# endif +# endif +# ifndef YYFREE +# define YYFREE free +# if ! defined free && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +void free (void *); /* INFRINGES ON USER NAME SPACE */ +# endif +# endif +# endif +#endif /* ! defined yyoverflow || YYERROR_VERBOSE */ + + +#if (! defined yyoverflow \ + && (! defined __cplusplus \ + || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) + +/* A type that is properly aligned for any stack member. */ +union yyalloc +{ + yytype_int16 yyss_alloc; + YYSTYPE yyvs_alloc; +}; + +/* The size of the maximum gap between one aligned stack and the next. */ +# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1) + +/* The size of an array large to enough to hold all stacks, each with + N elements. */ +# define YYSTACK_BYTES(N) \ + ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \ + + YYSTACK_GAP_MAXIMUM) + +/* Copy COUNT objects from FROM to TO. The source and destination do + not overlap. */ +# ifndef YYCOPY +# if defined __GNUC__ && 1 < __GNUC__ +# define YYCOPY(To, From, Count) \ + __builtin_memcpy (To, From, (Count) * sizeof (*(From))) +# else +# define YYCOPY(To, From, Count) \ + do \ + { \ + YYSIZE_T yyi; \ + for (yyi = 0; yyi < (Count); yyi++) \ + (To)[yyi] = (From)[yyi]; \ + } \ + while (YYID (0)) +# endif +# endif + +/* Relocate STACK from its old location to the new one. The + local variables YYSIZE and YYSTACKSIZE give the old and new number of + elements in the stack, and YYPTR gives the new location of the + stack. Advance YYPTR to a properly aligned location for the next + stack. */ +# define YYSTACK_RELOCATE(Stack_alloc, Stack) \ + do \ + { \ + YYSIZE_T yynewbytes; \ + YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \ + Stack = &yyptr->Stack_alloc; \ + yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ + yyptr += yynewbytes / sizeof (*yyptr); \ + } \ + while (YYID (0)) + +#endif + +/* YYFINAL -- State number of the termination state. */ +#define YYFINAL 28 +/* YYLAST -- Last index in YYTABLE. */ +#define YYLAST 84 + +/* YYNTOKENS -- Number of terminals. */ +#define YYNTOKENS 29 +/* YYNNTS -- Number of nonterminals. */ +#define YYNNTS 29 +/* YYNRULES -- Number of rules. */ +#define YYNRULES 50 +/* YYNRULES -- Number of states. */ +#define YYNSTATES 94 + +/* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */ +#define YYUNDEFTOK 2 +#define YYMAXUTOK 283 + +#define YYTRANSLATE(YYX) \ + ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) + +/* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */ +static const yytype_uint8 yytranslate[] = +{ + 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 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 +}; + +#if YYDEBUG +/* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in + YYRHS. */ +static const yytype_uint8 yyprhs[] = +{ + 0, 0, 3, 5, 6, 8, 11, 13, 15, 17, + 19, 21, 23, 25, 27, 30, 33, 35, 36, 37, + 50, 51, 58, 70, 83, 90, 93, 97, 99, 102, + 104, 105, 107, 108, 110, 111, 114, 115, 117, 121, + 125, 127, 131, 132, 134, 137, 141, 143, 145, 147, + 149 +}; + +/* YYRHS -- A `-1'-separated list of the rules' RHS. */ +static const yytype_int8 yyrhs[] = +{ + 30, 0, -1, 31, -1, -1, 32, -1, 31, 32, + -1, 33, -1, 34, -1, 35, -1, 38, -1, 40, + -1, 41, -1, 42, -1, 43, -1, 5, 57, -1, + 6, 57, -1, 6, -1, -1, -1, 7, 57, 52, + 46, 47, 48, 49, 19, 36, 50, 37, 20, -1, + -1, 8, 53, 39, 19, 54, 20, -1, 9, 10, + 57, 52, 11, 57, 12, 57, 19, 44, 20, -1, + 9, 15, 10, 57, 52, 11, 57, 12, 57, 19, + 44, 20, -1, 9, 16, 52, 52, 11, 57, -1, + 13, 14, -1, 44, 17, 45, -1, 45, -1, 57, + 57, -1, 22, -1, -1, 23, -1, -1, 24, -1, + -1, 25, 52, -1, -1, 51, -1, 50, 17, 51, + -1, 57, 18, 57, -1, 57, -1, 21, 18, 52, + -1, -1, 55, -1, 54, 55, -1, 54, 17, 55, + -1, 57, -1, 56, -1, 26, -1, 3, -1, 4, + -1 +}; + +/* YYRLINE[YYN] -- source line where rule number YYN was defined. */ +static const yytype_uint16 yyrline[] = +{ + 0, 126, 126, 127, 131, 132, 136, 137, 138, 139, + 140, 141, 142, 143, 147, 156, 162, 172, 182, 171, + 260, 259, 281, 316, 351, 361, 371, 372, 376, 391, + 392, 396, 397, 401, 402, 406, 407, 411, 412, 416, + 425, 429, 430, 434, 435, 436, 440, 442, 444, 449, + 453 +}; +#endif + +#if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE +/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM. + First, the terminals, then, starting at YYNTOKENS, nonterminals. */ +static const char *const yytname[] = +{ + "$end", "error", "$undefined", "CONST_P", "ID", "OPEN", "XCLOSE", + "XCREATE", "INSERT_TUPLE", "XDECLARE", "INDEX", "ON", "USING", "XBUILD", + "INDICES", "UNIQUE", "XTOAST", "COMMA", "EQUALS", "LPAREN", "RPAREN", + "OBJ_ID", "XBOOTSTRAP", "XSHARED_RELATION", "XWITHOUT_OIDS", + "XROWTYPE_OID", "NULLVAL", "low", "high", "$accept", "TopLevel", + "Boot_Queries", "Boot_Query", "Boot_OpenStmt", "Boot_CloseStmt", + "Boot_CreateStmt", "$@1", "$@2", "Boot_InsertStmt", "$@3", + "Boot_DeclareIndexStmt", "Boot_DeclareUniqueIndexStmt", + "Boot_DeclareToastStmt", "Boot_BuildIndsStmt", "boot_index_params", + "boot_index_param", "optbootstrap", "optsharedrelation", + "optwithoutoids", "optrowtypeoid", "boot_column_list", "boot_column_def", + "oidspec", "optoideq", "boot_column_val_list", "boot_column_val", + "boot_const", "boot_ident", 0 +}; +#endif + +# ifdef YYPRINT +/* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to + token YYLEX-NUM. */ +static const yytype_uint16 yytoknum[] = +{ + 0, 256, 257, 258, 259, 260, 261, 262, 263, 264, + 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, + 275, 276, 277, 278, 279, 280, 281, 282, 283 +}; +# endif + +/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ +static const yytype_uint8 yyr1[] = +{ + 0, 29, 30, 30, 31, 31, 32, 32, 32, 32, + 32, 32, 32, 32, 33, 34, 34, 36, 37, 35, + 39, 38, 40, 41, 42, 43, 44, 44, 45, 46, + 46, 47, 47, 48, 48, 49, 49, 50, 50, 51, + 52, 53, 53, 54, 54, 54, 55, 55, 55, 56, + 57 +}; + +/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */ +static const yytype_uint8 yyr2[] = +{ + 0, 2, 1, 0, 1, 2, 1, 1, 1, 1, + 1, 1, 1, 1, 2, 2, 1, 0, 0, 12, + 0, 6, 11, 12, 6, 2, 3, 1, 2, 1, + 0, 1, 0, 1, 0, 2, 0, 1, 3, 3, + 1, 3, 0, 1, 2, 3, 1, 1, 1, 1, + 1 +}; + +/* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state + STATE-NUM when YYTABLE doesn't specify something else to do. Zero + means the default is an error. */ +static const yytype_uint8 yydefact[] = +{ + 3, 0, 16, 0, 42, 0, 0, 0, 2, 4, + 6, 7, 8, 9, 10, 11, 12, 13, 50, 14, + 15, 0, 0, 20, 0, 0, 0, 25, 1, 5, + 30, 40, 0, 0, 0, 0, 0, 29, 32, 41, + 0, 0, 0, 0, 31, 34, 49, 48, 0, 43, + 47, 46, 0, 0, 0, 33, 36, 0, 21, 44, + 0, 0, 24, 0, 0, 45, 0, 0, 35, 17, + 0, 0, 0, 0, 0, 18, 37, 0, 0, 27, + 0, 0, 0, 0, 0, 0, 22, 28, 0, 38, + 19, 39, 26, 23 +}; + +/* YYDEFGOTO[NTERM-NUM]. */ +static const yytype_int8 yydefgoto[] = +{ + -1, 7, 8, 9, 10, 11, 12, 72, 83, 13, + 33, 14, 15, 16, 17, 78, 79, 38, 45, 56, + 64, 75, 76, 30, 23, 48, 49, 50, 31 +}; + +/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing + STATE-NUM. */ +#define YYPACT_NINF -41 +static const yytype_int8 yypact[] = +{ + 36, 8, 8, 8, -7, 0, 6, 24, 36, -41, + -41, -41, -41, -41, -41, -41, -41, -41, -41, -41, + -41, 8, 12, -41, 8, 16, 8, -41, -41, -41, + 10, -41, 8, 14, 8, 8, 8, -41, 13, -41, + 3, 26, 8, 27, -41, 22, -41, -41, 1, -41, + -41, -41, 8, 37, 8, -41, 25, 3, -41, -41, + 23, 8, -41, 8, 33, -41, 8, 42, -41, -41, + 38, 8, 8, 8, 39, 44, -41, 41, 5, -41, + 8, 8, 8, 35, 8, 8, -41, -41, 11, -41, + -41, -41, -41, -41 +}; + +/* YYPGOTO[NTERM-NUM]. */ +static const yytype_int8 yypgoto[] = +{ + -41, -41, -41, 54, -41, -41, -41, -41, -41, -41, + -41, -41, -41, -41, -41, -18, -21, -41, -41, -41, + -41, -41, -16, -23, -41, -41, -40, -41, -1 +}; + +/* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If + positive, shift that token. If negative, reduce the rule which + number is the opposite. If zero, do what YYDEFACT says. + If YYTABLE_NINF, syntax error. */ +#define YYTABLE_NINF -1 +static const yytype_uint8 yytable[] = +{ + 19, 20, 21, 36, 46, 18, 46, 18, 59, 39, + 24, 41, 18, 43, 22, 25, 26, 65, 57, 53, + 27, 58, 85, 34, 28, 86, 35, 47, 85, 47, + 32, 93, 37, 40, 42, 66, 44, 52, 54, 51, + 68, 1, 2, 3, 4, 5, 55, 51, 61, 6, + 63, 60, 69, 62, 71, 90, 51, 73, 81, 84, + 67, 82, 29, 88, 92, 70, 89, 0, 0, 0, + 74, 77, 80, 0, 0, 0, 0, 0, 0, 87, + 80, 77, 0, 91, 80 +}; + +static const yytype_int8 yycheck[] = +{ + 1, 2, 3, 26, 3, 4, 3, 4, 48, 32, + 10, 34, 4, 36, 21, 15, 16, 57, 17, 42, + 14, 20, 17, 24, 0, 20, 10, 26, 17, 26, + 18, 20, 22, 19, 35, 12, 23, 11, 11, 40, + 63, 5, 6, 7, 8, 9, 24, 48, 11, 13, + 25, 52, 19, 54, 12, 20, 57, 19, 19, 18, + 61, 17, 8, 81, 85, 66, 82, -1, -1, -1, + 71, 72, 73, -1, -1, -1, -1, -1, -1, 80, + 81, 82, -1, 84, 85 +}; + +/* YYSTOS[STATE-NUM] -- The (internal number of the) accessing + symbol of state STATE-NUM. */ +static const yytype_uint8 yystos[] = +{ + 0, 5, 6, 7, 8, 9, 13, 30, 31, 32, + 33, 34, 35, 38, 40, 41, 42, 43, 4, 57, + 57, 57, 21, 53, 10, 15, 16, 14, 0, 32, + 52, 57, 18, 39, 57, 10, 52, 22, 46, 52, + 19, 52, 57, 52, 23, 47, 3, 26, 54, 55, + 56, 57, 11, 52, 11, 24, 48, 17, 20, 55, + 57, 11, 57, 25, 49, 55, 12, 57, 52, 19, + 57, 12, 36, 19, 57, 50, 51, 57, 44, 45, + 57, 19, 17, 37, 18, 17, 20, 57, 44, 51, + 20, 57, 45, 20 +}; + +#define yyerrok (yyerrstatus = 0) +#define yyclearin (yychar = YYEMPTY) +#define YYEMPTY (-2) +#define YYEOF 0 + +#define YYACCEPT goto yyacceptlab +#define YYABORT goto yyabortlab +#define YYERROR goto yyerrorlab + + +/* Like YYERROR except do call yyerror. This remains here temporarily + to ease the transition to the new meaning of YYERROR, for GCC. + Once GCC version 2 has supplanted version 1, this can go. */ + +#define YYFAIL goto yyerrlab + +#define YYRECOVERING() (!!yyerrstatus) + +#define YYBACKUP(Token, Value) \ +do \ + if (yychar == YYEMPTY && yylen == 1) \ + { \ + yychar = (Token); \ + yylval = (Value); \ + yytoken = YYTRANSLATE (yychar); \ + YYPOPSTACK (1); \ + goto yybackup; \ + } \ + else \ + { \ + yyerror (YY_("syntax error: cannot back up")); \ + YYERROR; \ + } \ +while (YYID (0)) + + +#define YYTERROR 1 +#define YYERRCODE 256 + + +/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N]. + If N is 0, then set CURRENT to the empty location which ends + the previous symbol: RHS[0] (always defined). */ + +#define YYRHSLOC(Rhs, K) ((Rhs)[K]) +#ifndef YYLLOC_DEFAULT +# define YYLLOC_DEFAULT(Current, Rhs, N) \ + do \ + if (YYID (N)) \ + { \ + (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \ + (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \ + (Current).last_line = YYRHSLOC (Rhs, N).last_line; \ + (Current).last_column = YYRHSLOC (Rhs, N).last_column; \ + } \ + else \ + { \ + (Current).first_line = (Current).last_line = \ + YYRHSLOC (Rhs, 0).last_line; \ + (Current).first_column = (Current).last_column = \ + YYRHSLOC (Rhs, 0).last_column; \ + } \ + while (YYID (0)) +#endif + + +/* YY_LOCATION_PRINT -- Print the location on the stream. + This macro was not mandated originally: define only if we know + we won't break user code: when these are the locations we know. */ + +#ifndef YY_LOCATION_PRINT +# if YYLTYPE_IS_TRIVIAL +# define YY_LOCATION_PRINT(File, Loc) \ + fprintf (File, "%d.%d-%d.%d", \ + (Loc).first_line, (Loc).first_column, \ + (Loc).last_line, (Loc).last_column) +# else +# define YY_LOCATION_PRINT(File, Loc) ((void) 0) +# endif +#endif + + +/* YYLEX -- calling `yylex' with the right arguments. */ + +#ifdef YYLEX_PARAM +# define YYLEX yylex (YYLEX_PARAM) +#else +# define YYLEX yylex () +#endif + +/* Enable debugging if requested. */ +#if YYDEBUG + +# ifndef YYFPRINTF +# include /* INFRINGES ON USER NAME SPACE */ +# define YYFPRINTF fprintf +# endif + +# define YYDPRINTF(Args) \ +do { \ + if (yydebug) \ + YYFPRINTF Args; \ +} while (YYID (0)) + +# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \ +do { \ + if (yydebug) \ + { \ + YYFPRINTF (stderr, "%s ", Title); \ + yy_symbol_print (stderr, \ + Type, Value); \ + YYFPRINTF (stderr, "\n"); \ + } \ +} while (YYID (0)) + + +/*--------------------------------. +| Print this symbol on YYOUTPUT. | +`--------------------------------*/ + +/*ARGSUSED*/ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep) +#else +static void +yy_symbol_value_print (yyoutput, yytype, yyvaluep) + FILE *yyoutput; + int yytype; + YYSTYPE const * const yyvaluep; +#endif +{ + if (!yyvaluep) + return; +# ifdef YYPRINT + if (yytype < YYNTOKENS) + YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep); +# else + YYUSE (yyoutput); +# endif + switch (yytype) + { + default: + break; + } +} + + +/*--------------------------------. +| Print this symbol on YYOUTPUT. | +`--------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep) +#else +static void +yy_symbol_print (yyoutput, yytype, yyvaluep) + FILE *yyoutput; + int yytype; + YYSTYPE const * const yyvaluep; +#endif +{ + if (yytype < YYNTOKENS) + YYFPRINTF (yyoutput, "token %s (", yytname[yytype]); + else + YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]); + + yy_symbol_value_print (yyoutput, yytype, yyvaluep); + YYFPRINTF (yyoutput, ")"); +} + +/*------------------------------------------------------------------. +| yy_stack_print -- Print the state stack from its BOTTOM up to its | +| TOP (included). | +`------------------------------------------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop) +#else +static void +yy_stack_print (yybottom, yytop) + yytype_int16 *yybottom; + yytype_int16 *yytop; +#endif +{ + YYFPRINTF (stderr, "Stack now"); + for (; yybottom <= yytop; yybottom++) + { + int yybot = *yybottom; + YYFPRINTF (stderr, " %d", yybot); + } + YYFPRINTF (stderr, "\n"); +} + +# define YY_STACK_PRINT(Bottom, Top) \ +do { \ + if (yydebug) \ + yy_stack_print ((Bottom), (Top)); \ +} while (YYID (0)) + + +/*------------------------------------------------. +| Report that the YYRULE is going to be reduced. | +`------------------------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_reduce_print (YYSTYPE *yyvsp, int yyrule) +#else +static void +yy_reduce_print (yyvsp, yyrule) + YYSTYPE *yyvsp; + int yyrule; +#endif +{ + int yynrhs = yyr2[yyrule]; + int yyi; + unsigned long int yylno = yyrline[yyrule]; + YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n", + yyrule - 1, yylno); + /* The symbols being reduced. */ + for (yyi = 0; yyi < yynrhs; yyi++) + { + YYFPRINTF (stderr, " $%d = ", yyi + 1); + yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi], + &(yyvsp[(yyi + 1) - (yynrhs)]) + ); + YYFPRINTF (stderr, "\n"); + } +} + +# define YY_REDUCE_PRINT(Rule) \ +do { \ + if (yydebug) \ + yy_reduce_print (yyvsp, Rule); \ +} while (YYID (0)) + +/* Nonzero means print parse trace. It is left uninitialized so that + multiple parsers can coexist. */ +int yydebug; +#else /* !YYDEBUG */ +# define YYDPRINTF(Args) +# define YY_SYMBOL_PRINT(Title, Type, Value, Location) +# define YY_STACK_PRINT(Bottom, Top) +# define YY_REDUCE_PRINT(Rule) +#endif /* !YYDEBUG */ + + +/* YYINITDEPTH -- initial size of the parser's stacks. */ +#ifndef YYINITDEPTH +# define YYINITDEPTH 200 +#endif + +/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only + if the built-in stack extension method is used). + + Do not make this value too large; the results are undefined if + YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH) + evaluated with infinite-precision integer arithmetic. */ + +#ifndef YYMAXDEPTH +# define YYMAXDEPTH 10000 +#endif + + + +#if YYERROR_VERBOSE + +# ifndef yystrlen +# if defined __GLIBC__ && defined _STRING_H +# define yystrlen strlen +# else +/* Return the length of YYSTR. */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static YYSIZE_T +yystrlen (const char *yystr) +#else +static YYSIZE_T +yystrlen (yystr) + const char *yystr; +#endif +{ + YYSIZE_T yylen; + for (yylen = 0; yystr[yylen]; yylen++) + continue; + return yylen; +} +# endif +# endif + +# ifndef yystpcpy +# if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE +# define yystpcpy stpcpy +# else +/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in + YYDEST. */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static char * +yystpcpy (char *yydest, const char *yysrc) +#else +static char * +yystpcpy (yydest, yysrc) + char *yydest; + const char *yysrc; +#endif +{ + char *yyd = yydest; + const char *yys = yysrc; + + while ((*yyd++ = *yys++) != '\0') + continue; + + return yyd - 1; +} +# endif +# endif + +# ifndef yytnamerr +/* Copy to YYRES the contents of YYSTR after stripping away unnecessary + quotes and backslashes, so that it's suitable for yyerror. The + heuristic is that double-quoting is unnecessary unless the string + contains an apostrophe, a comma, or backslash (other than + backslash-backslash). YYSTR is taken from yytname. If YYRES is + null, do not copy; instead, return the length of what the result + would have been. */ +static YYSIZE_T +yytnamerr (char *yyres, const char *yystr) +{ + if (*yystr == '"') + { + YYSIZE_T yyn = 0; + char const *yyp = yystr; + + for (;;) + switch (*++yyp) + { + case '\'': + case ',': + goto do_not_strip_quotes; + + case '\\': + if (*++yyp != '\\') + goto do_not_strip_quotes; + /* Fall through. */ + default: + if (yyres) + yyres[yyn] = *yyp; + yyn++; + break; + + case '"': + if (yyres) + yyres[yyn] = '\0'; + return yyn; + } + do_not_strip_quotes: ; + } + + if (! yyres) + return yystrlen (yystr); + + return yystpcpy (yyres, yystr) - yyres; +} +# endif + +/* Copy into YYRESULT an error message about the unexpected token + YYCHAR while in state YYSTATE. Return the number of bytes copied, + including the terminating null byte. If YYRESULT is null, do not + copy anything; just return the number of bytes that would be + copied. As a special case, return 0 if an ordinary "syntax error" + message will do. Return YYSIZE_MAXIMUM if overflow occurs during + size calculation. */ +static YYSIZE_T +yysyntax_error (char *yyresult, int yystate, int yychar) +{ + int yyn = yypact[yystate]; + + if (! (YYPACT_NINF < yyn && yyn <= YYLAST)) + return 0; + else + { + int yytype = YYTRANSLATE (yychar); + YYSIZE_T yysize0 = yytnamerr (0, yytname[yytype]); + YYSIZE_T yysize = yysize0; + YYSIZE_T yysize1; + int yysize_overflow = 0; + enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; + char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; + int yyx; + +# if 0 + /* This is so xgettext sees the translatable formats that are + constructed on the fly. */ + YY_("syntax error, unexpected %s"); + YY_("syntax error, unexpected %s, expecting %s"); + YY_("syntax error, unexpected %s, expecting %s or %s"); + YY_("syntax error, unexpected %s, expecting %s or %s or %s"); + YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"); +# endif + char *yyfmt; + char const *yyf; + static char const yyunexpected[] = "syntax error, unexpected %s"; + static char const yyexpecting[] = ", expecting %s"; + static char const yyor[] = " or %s"; + char yyformat[sizeof yyunexpected + + sizeof yyexpecting - 1 + + ((YYERROR_VERBOSE_ARGS_MAXIMUM - 2) + * (sizeof yyor - 1))]; + char const *yyprefix = yyexpecting; + + /* Start YYX at -YYN if negative to avoid negative indexes in + YYCHECK. */ + int yyxbegin = yyn < 0 ? -yyn : 0; + + /* Stay within bounds of both yycheck and yytname. */ + int yychecklim = YYLAST - yyn + 1; + int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; + int yycount = 1; + + yyarg[0] = yytname[yytype]; + yyfmt = yystpcpy (yyformat, yyunexpected); + + for (yyx = yyxbegin; yyx < yyxend; ++yyx) + if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR) + { + if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) + { + yycount = 1; + yysize = yysize0; + yyformat[sizeof yyunexpected - 1] = '\0'; + break; + } + yyarg[yycount++] = yytname[yyx]; + yysize1 = yysize + yytnamerr (0, yytname[yyx]); + yysize_overflow |= (yysize1 < yysize); + yysize = yysize1; + yyfmt = yystpcpy (yyfmt, yyprefix); + yyprefix = yyor; + } + + yyf = YY_(yyformat); + yysize1 = yysize + yystrlen (yyf); + yysize_overflow |= (yysize1 < yysize); + yysize = yysize1; + + if (yysize_overflow) + return YYSIZE_MAXIMUM; + + if (yyresult) + { + /* Avoid sprintf, as that infringes on the user's name space. + Don't have undefined behavior even if the translation + produced a string with the wrong number of "%s"s. */ + char *yyp = yyresult; + int yyi = 0; + while ((*yyp = *yyf) != '\0') + { + if (*yyp == '%' && yyf[1] == 's' && yyi < yycount) + { + yyp += yytnamerr (yyp, yyarg[yyi++]); + yyf += 2; + } + else + { + yyp++; + yyf++; + } + } + } + return yysize; + } +} +#endif /* YYERROR_VERBOSE */ + + +/*-----------------------------------------------. +| Release the memory associated to this symbol. | +`-----------------------------------------------*/ + +/*ARGSUSED*/ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep) +#else +static void +yydestruct (yymsg, yytype, yyvaluep) + const char *yymsg; + int yytype; + YYSTYPE *yyvaluep; +#endif +{ + YYUSE (yyvaluep); + + if (!yymsg) + yymsg = "Deleting"; + YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp); + + switch (yytype) + { + + default: + break; + } +} + +/* Prevent warnings from -Wmissing-prototypes. */ +#ifdef YYPARSE_PARAM +#if defined __STDC__ || defined __cplusplus +int yyparse (void *YYPARSE_PARAM); +#else +int yyparse (); +#endif +#else /* ! YYPARSE_PARAM */ +#if defined __STDC__ || defined __cplusplus +int yyparse (void); +#else +int yyparse (); +#endif +#endif /* ! YYPARSE_PARAM */ + + +/* The lookahead symbol. */ +int yychar; + +/* The semantic value of the lookahead symbol. */ +YYSTYPE yylval; + +/* Number of syntax errors so far. */ +int yynerrs; + + + +/*-------------------------. +| yyparse or yypush_parse. | +`-------------------------*/ + +#ifdef YYPARSE_PARAM +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +int +yyparse (void *YYPARSE_PARAM) +#else +int +yyparse (YYPARSE_PARAM) + void *YYPARSE_PARAM; +#endif +#else /* ! YYPARSE_PARAM */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +int +yyparse (void) +#else +int +yyparse () + +#endif +#endif +{ + + + int yystate; + /* Number of tokens to shift before error messages enabled. */ + int yyerrstatus; + + /* The stacks and their tools: + `yyss': related to states. + `yyvs': related to semantic values. + + Refer to the stacks thru separate pointers, to allow yyoverflow + to reallocate them elsewhere. */ + + /* The state stack. */ + yytype_int16 yyssa[YYINITDEPTH]; + yytype_int16 *yyss; + yytype_int16 *yyssp; + + /* The semantic value stack. */ + YYSTYPE yyvsa[YYINITDEPTH]; + YYSTYPE *yyvs; + YYSTYPE *yyvsp; + + YYSIZE_T yystacksize; + + int yyn; + int yyresult; + /* Lookahead token as an internal (translated) token number. */ + int yytoken; + /* The variables used to return semantic value and location from the + action routines. */ + YYSTYPE yyval; + +#if YYERROR_VERBOSE + /* Buffer for error messages, and its allocated size. */ + char yymsgbuf[128]; + char *yymsg = yymsgbuf; + YYSIZE_T yymsg_alloc = sizeof yymsgbuf; +#endif + +#define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N)) + + /* The number of symbols on the RHS of the reduced rule. + Keep to zero when no symbol should be popped. */ + int yylen = 0; + + yytoken = 0; + yyss = yyssa; + yyvs = yyvsa; + yystacksize = YYINITDEPTH; + + YYDPRINTF ((stderr, "Starting parse\n")); + + yystate = 0; + yyerrstatus = 0; + yynerrs = 0; + yychar = YYEMPTY; /* Cause a token to be read. */ + + /* Initialize stack pointers. + Waste one element of value and location stack + so that they stay on the same level as the state stack. + The wasted elements are never initialized. */ + yyssp = yyss; + yyvsp = yyvs; + + goto yysetstate; + +/*------------------------------------------------------------. +| yynewstate -- Push a new state, which is found in yystate. | +`------------------------------------------------------------*/ + yynewstate: + /* In all cases, when you get here, the value and location stacks + have just been pushed. So pushing a state here evens the stacks. */ + yyssp++; + + yysetstate: + *yyssp = yystate; + + if (yyss + yystacksize - 1 <= yyssp) + { + /* Get the current used size of the three stacks, in elements. */ + YYSIZE_T yysize = yyssp - yyss + 1; + +#ifdef yyoverflow + { + /* Give user a chance to reallocate the stack. Use copies of + these so that the &'s don't force the real ones into + memory. */ + YYSTYPE *yyvs1 = yyvs; + yytype_int16 *yyss1 = yyss; + + /* Each stack pointer address is followed by the size of the + data in use in that stack, in bytes. This used to be a + conditional around just the two extra args, but that might + be undefined if yyoverflow is a macro. */ + yyoverflow (YY_("memory exhausted"), + &yyss1, yysize * sizeof (*yyssp), + &yyvs1, yysize * sizeof (*yyvsp), + &yystacksize); + + yyss = yyss1; + yyvs = yyvs1; + } +#else /* no yyoverflow */ +# ifndef YYSTACK_RELOCATE + goto yyexhaustedlab; +# else + /* Extend the stack our own way. */ + if (YYMAXDEPTH <= yystacksize) + goto yyexhaustedlab; + yystacksize *= 2; + if (YYMAXDEPTH < yystacksize) + yystacksize = YYMAXDEPTH; + + { + yytype_int16 *yyss1 = yyss; + union yyalloc *yyptr = + (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize)); + if (! yyptr) + goto yyexhaustedlab; + YYSTACK_RELOCATE (yyss_alloc, yyss); + YYSTACK_RELOCATE (yyvs_alloc, yyvs); +# undef YYSTACK_RELOCATE + if (yyss1 != yyssa) + YYSTACK_FREE (yyss1); + } +# endif +#endif /* no yyoverflow */ + + yyssp = yyss + yysize - 1; + yyvsp = yyvs + yysize - 1; + + YYDPRINTF ((stderr, "Stack size increased to %lu\n", + (unsigned long int) yystacksize)); + + if (yyss + yystacksize - 1 <= yyssp) + YYABORT; + } + + YYDPRINTF ((stderr, "Entering state %d\n", yystate)); + + if (yystate == YYFINAL) + YYACCEPT; + + goto yybackup; + +/*-----------. +| yybackup. | +`-----------*/ +yybackup: + + /* Do appropriate processing given the current state. Read a + lookahead token if we need one and don't already have one. */ + + /* First try to decide what to do without reference to lookahead token. */ + yyn = yypact[yystate]; + if (yyn == YYPACT_NINF) + goto yydefault; + + /* Not known => get a lookahead token if don't already have one. */ + + /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */ + if (yychar == YYEMPTY) + { + YYDPRINTF ((stderr, "Reading a token: ")); + yychar = YYLEX; + } + + if (yychar <= YYEOF) + { + yychar = yytoken = YYEOF; + YYDPRINTF ((stderr, "Now at end of input.\n")); + } + else + { + yytoken = YYTRANSLATE (yychar); + YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc); + } + + /* If the proper action on seeing token YYTOKEN is to reduce or to + detect an error, take that action. */ + yyn += yytoken; + if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken) + goto yydefault; + yyn = yytable[yyn]; + if (yyn <= 0) + { + if (yyn == 0 || yyn == YYTABLE_NINF) + goto yyerrlab; + yyn = -yyn; + goto yyreduce; + } + + /* Count tokens shifted since error; after three, turn off error + status. */ + if (yyerrstatus) + yyerrstatus--; + + /* Shift the lookahead token. */ + YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc); + + /* Discard the shifted token. */ + yychar = YYEMPTY; + + yystate = yyn; + *++yyvsp = yylval; + + goto yynewstate; + + +/*-----------------------------------------------------------. +| yydefault -- do the default action for the current state. | +`-----------------------------------------------------------*/ +yydefault: + yyn = yydefact[yystate]; + if (yyn == 0) + goto yyerrlab; + goto yyreduce; + + +/*-----------------------------. +| yyreduce -- Do a reduction. | +`-----------------------------*/ +yyreduce: + /* yyn is the number of a rule to reduce with. */ + yylen = yyr2[yyn]; + + /* If YYLEN is nonzero, implement the default value of the action: + `$$ = $1'. + + Otherwise, the following line sets YYVAL to garbage. + This behavior is undocumented and Bison + users should not rely upon it. Assigning to YYVAL + unconditionally makes the parser a bit smaller, and it avoids a + GCC warning that YYVAL may be used uninitialized. */ + yyval = yyvsp[1-yylen]; + + + YY_REDUCE_PRINT (yyn); + switch (yyn) + { + case 14: + +/* Line 1455 of yacc.c */ +#line 148 "bootparse.y" + { + do_start(); + boot_openrel((yyvsp[(2) - (2)].str)); + do_end(); + ;} + break; + + case 15: + +/* Line 1455 of yacc.c */ +#line 157 "bootparse.y" + { + do_start(); + closerel((yyvsp[(2) - (2)].str)); + do_end(); + ;} + break; + + case 16: + +/* Line 1455 of yacc.c */ +#line 163 "bootparse.y" + { + do_start(); + closerel(NULL); + do_end(); + ;} + break; + + case 17: + +/* Line 1455 of yacc.c */ +#line 172 "bootparse.y" + { + do_start(); + numattr = 0; + elog(DEBUG4, "creating%s%s relation %s %u", + (yyvsp[(4) - (8)].ival) ? " bootstrap" : "", + (yyvsp[(5) - (8)].ival) ? " shared" : "", + (yyvsp[(2) - (8)].str), + (yyvsp[(3) - (8)].oidval)); + ;} + break; + + case 18: + +/* Line 1455 of yacc.c */ +#line 182 "bootparse.y" + { + do_end(); + ;} + break; + + case 19: + +/* Line 1455 of yacc.c */ +#line 186 "bootparse.y" + { + TupleDesc tupdesc; + bool shared_relation; + bool mapped_relation; + + do_start(); + + tupdesc = CreateTupleDesc(numattr, !((yyvsp[(6) - (12)].ival)), attrtypes); + + shared_relation = (yyvsp[(5) - (12)].ival); + + /* + * The catalogs that use the relation mapper are the + * bootstrap catalogs plus the shared catalogs. If this + * ever gets more complicated, we should invent a BKI + * keyword to mark the mapped catalogs, but for now a + * quick hack seems the most appropriate thing. Note in + * particular that all "nailed" heap rels (see formrdesc + * in relcache.c) must be mapped. + */ + mapped_relation = ((yyvsp[(4) - (12)].ival) || shared_relation); + + if ((yyvsp[(4) - (12)].ival)) + { + if (boot_reldesc) + { + elog(DEBUG4, "create bootstrap: warning, open relation exists, closing first"); + closerel(NULL); + } + + boot_reldesc = heap_create((yyvsp[(2) - (12)].str), + PG_CATALOG_NAMESPACE, + shared_relation ? GLOBALTABLESPACE_OID : 0, + (yyvsp[(3) - (12)].oidval), + InvalidOid, + tupdesc, + RELKIND_RELATION, + RELPERSISTENCE_PERMANENT, + shared_relation, + mapped_relation, + true); + elog(DEBUG4, "bootstrap relation created"); + } + else + { + Oid id; + + id = heap_create_with_catalog((yyvsp[(2) - (12)].str), + PG_CATALOG_NAMESPACE, + shared_relation ? GLOBALTABLESPACE_OID : 0, + (yyvsp[(3) - (12)].oidval), + (yyvsp[(7) - (12)].oidval), + InvalidOid, + BOOTSTRAP_SUPERUSERID, + tupdesc, + NIL, + RELKIND_RELATION, + RELPERSISTENCE_PERMANENT, + shared_relation, + mapped_relation, + true, + 0, + ONCOMMIT_NOOP, + (Datum) 0, + false, + true); + elog(DEBUG4, "relation created with OID %u", id); + } + do_end(); + ;} + break; + + case 20: + +/* Line 1455 of yacc.c */ +#line 260 "bootparse.y" + { + do_start(); + if ((yyvsp[(2) - (2)].oidval)) + elog(DEBUG4, "inserting row with oid %u", (yyvsp[(2) - (2)].oidval)); + else + elog(DEBUG4, "inserting row"); + num_columns_read = 0; + ;} + break; + + case 21: + +/* Line 1455 of yacc.c */ +#line 269 "bootparse.y" + { + if (num_columns_read != numattr) + elog(ERROR, "incorrect number of columns in row (expected %d, got %d)", + numattr, num_columns_read); + if (boot_reldesc == NULL) + elog(FATAL, "relation not open"); + InsertOneTuple((yyvsp[(2) - (6)].oidval)); + do_end(); + ;} + break; + + case 22: + +/* Line 1455 of yacc.c */ +#line 282 "bootparse.y" + { + IndexStmt *stmt = makeNode(IndexStmt); + + do_start(); + + stmt->idxname = (yyvsp[(3) - (11)].str); + stmt->relation = makeRangeVar(NULL, (yyvsp[(6) - (11)].str), -1); + stmt->accessMethod = (yyvsp[(8) - (11)].str); + stmt->tableSpace = NULL; + stmt->indexParams = (yyvsp[(10) - (11)].list); + stmt->options = NIL; + stmt->whereClause = NULL; + stmt->excludeOpNames = NIL; + stmt->idxcomment = NULL; + stmt->indexOid = InvalidOid; + stmt->oldNode = InvalidOid; + stmt->unique = false; + stmt->primary = false; + stmt->isconstraint = false; + stmt->deferrable = false; + stmt->initdeferred = false; + stmt->concurrent = false; + + DefineIndex(stmt, + (yyvsp[(4) - (11)].oidval), + false, + false, + true, /* skip_build */ + false); + do_end(); + ;} + break; + + case 23: + +/* Line 1455 of yacc.c */ +#line 317 "bootparse.y" + { + IndexStmt *stmt = makeNode(IndexStmt); + + do_start(); + + stmt->idxname = (yyvsp[(4) - (12)].str); + stmt->relation = makeRangeVar(NULL, (yyvsp[(7) - (12)].str), -1); + stmt->accessMethod = (yyvsp[(9) - (12)].str); + stmt->tableSpace = NULL; + stmt->indexParams = (yyvsp[(11) - (12)].list); + stmt->options = NIL; + stmt->whereClause = NULL; + stmt->excludeOpNames = NIL; + stmt->idxcomment = NULL; + stmt->indexOid = InvalidOid; + stmt->oldNode = InvalidOid; + stmt->unique = true; + stmt->primary = false; + stmt->isconstraint = false; + stmt->deferrable = false; + stmt->initdeferred = false; + stmt->concurrent = false; + + DefineIndex(stmt, + (yyvsp[(5) - (12)].oidval), + false, + false, + true, /* skip_build */ + false); + do_end(); + ;} + break; + + case 24: + +/* Line 1455 of yacc.c */ +#line 352 "bootparse.y" + { + do_start(); + + BootstrapToastTable((yyvsp[(6) - (6)].str), (yyvsp[(3) - (6)].oidval), (yyvsp[(4) - (6)].oidval)); + do_end(); + ;} + break; + + case 25: + +/* Line 1455 of yacc.c */ +#line 362 "bootparse.y" + { + do_start(); + build_indices(); + do_end(); + ;} + break; + + case 26: + +/* Line 1455 of yacc.c */ +#line 371 "bootparse.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].ielem)); ;} + break; + + case 27: + +/* Line 1455 of yacc.c */ +#line 372 "bootparse.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].ielem)); ;} + break; + + case 28: + +/* Line 1455 of yacc.c */ +#line 377 "bootparse.y" + { + IndexElem *n = makeNode(IndexElem); + n->name = (yyvsp[(1) - (2)].str); + n->expr = NULL; + n->indexcolname = NULL; + n->collation = NIL; + n->opclass = list_make1(makeString((yyvsp[(2) - (2)].str))); + n->ordering = SORTBY_DEFAULT; + n->nulls_ordering = SORTBY_NULLS_DEFAULT; + (yyval.ielem) = n; + ;} + break; + + case 29: + +/* Line 1455 of yacc.c */ +#line 391 "bootparse.y" + { (yyval.ival) = 1; ;} + break; + + case 30: + +/* Line 1455 of yacc.c */ +#line 392 "bootparse.y" + { (yyval.ival) = 0; ;} + break; + + case 31: + +/* Line 1455 of yacc.c */ +#line 396 "bootparse.y" + { (yyval.ival) = 1; ;} + break; + + case 32: + +/* Line 1455 of yacc.c */ +#line 397 "bootparse.y" + { (yyval.ival) = 0; ;} + break; + + case 33: + +/* Line 1455 of yacc.c */ +#line 401 "bootparse.y" + { (yyval.ival) = 1; ;} + break; + + case 34: + +/* Line 1455 of yacc.c */ +#line 402 "bootparse.y" + { (yyval.ival) = 0; ;} + break; + + case 35: + +/* Line 1455 of yacc.c */ +#line 406 "bootparse.y" + { (yyval.oidval) = (yyvsp[(2) - (2)].oidval); ;} + break; + + case 36: + +/* Line 1455 of yacc.c */ +#line 407 "bootparse.y" + { (yyval.oidval) = InvalidOid; ;} + break; + + case 39: + +/* Line 1455 of yacc.c */ +#line 417 "bootparse.y" + { + if (++numattr > MAXATTR) + elog(FATAL, "too many columns"); + DefineAttr((yyvsp[(1) - (3)].str), (yyvsp[(3) - (3)].str), numattr-1); + ;} + break; + + case 40: + +/* Line 1455 of yacc.c */ +#line 425 "bootparse.y" + { (yyval.oidval) = atooid((yyvsp[(1) - (1)].str)); ;} + break; + + case 41: + +/* Line 1455 of yacc.c */ +#line 429 "bootparse.y" + { (yyval.oidval) = (yyvsp[(3) - (3)].oidval); ;} + break; + + case 42: + +/* Line 1455 of yacc.c */ +#line 430 "bootparse.y" + { (yyval.oidval) = InvalidOid; ;} + break; + + case 46: + +/* Line 1455 of yacc.c */ +#line 441 "bootparse.y" + { InsertOneValue((yyvsp[(1) - (1)].str), num_columns_read++); ;} + break; + + case 47: + +/* Line 1455 of yacc.c */ +#line 443 "bootparse.y" + { InsertOneValue((yyvsp[(1) - (1)].str), num_columns_read++); ;} + break; + + case 48: + +/* Line 1455 of yacc.c */ +#line 445 "bootparse.y" + { InsertOneNull(num_columns_read++); ;} + break; + + case 49: + +/* Line 1455 of yacc.c */ +#line 449 "bootparse.y" + { (yyval.str) = yylval.str; ;} + break; + + case 50: + +/* Line 1455 of yacc.c */ +#line 453 "bootparse.y" + { (yyval.str) = yylval.str; ;} + break; + + + +/* Line 1455 of yacc.c */ +#line 1949 "bootparse.c" + default: break; + } + YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); + + YYPOPSTACK (yylen); + yylen = 0; + YY_STACK_PRINT (yyss, yyssp); + + *++yyvsp = yyval; + + /* Now `shift' the result of the reduction. Determine what state + that goes to, based on the state we popped back to and the rule + number reduced by. */ + + yyn = yyr1[yyn]; + + yystate = yypgoto[yyn - YYNTOKENS] + *yyssp; + if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp) + yystate = yytable[yystate]; + else + yystate = yydefgoto[yyn - YYNTOKENS]; + + goto yynewstate; + + +/*------------------------------------. +| yyerrlab -- here on detecting error | +`------------------------------------*/ +yyerrlab: + /* If not already recovering from an error, report this error. */ + if (!yyerrstatus) + { + ++yynerrs; +#if ! YYERROR_VERBOSE + yyerror (YY_("syntax error")); +#else + { + YYSIZE_T yysize = yysyntax_error (0, yystate, yychar); + if (yymsg_alloc < yysize && yymsg_alloc < YYSTACK_ALLOC_MAXIMUM) + { + YYSIZE_T yyalloc = 2 * yysize; + if (! (yysize <= yyalloc && yyalloc <= YYSTACK_ALLOC_MAXIMUM)) + yyalloc = YYSTACK_ALLOC_MAXIMUM; + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); + yymsg = (char *) YYSTACK_ALLOC (yyalloc); + if (yymsg) + yymsg_alloc = yyalloc; + else + { + yymsg = yymsgbuf; + yymsg_alloc = sizeof yymsgbuf; + } + } + + if (0 < yysize && yysize <= yymsg_alloc) + { + (void) yysyntax_error (yymsg, yystate, yychar); + yyerror (yymsg); + } + else + { + yyerror (YY_("syntax error")); + if (yysize != 0) + goto yyexhaustedlab; + } + } +#endif + } + + + + if (yyerrstatus == 3) + { + /* If just tried and failed to reuse lookahead token after an + error, discard it. */ + + if (yychar <= YYEOF) + { + /* Return failure if at end of input. */ + if (yychar == YYEOF) + YYABORT; + } + else + { + yydestruct ("Error: discarding", + yytoken, &yylval); + yychar = YYEMPTY; + } + } + + /* Else will try to reuse lookahead token after shifting the error + token. */ + goto yyerrlab1; + + +/*---------------------------------------------------. +| yyerrorlab -- error raised explicitly by YYERROR. | +`---------------------------------------------------*/ +yyerrorlab: + + /* Pacify compilers like GCC when the user code never invokes + YYERROR and the label yyerrorlab therefore never appears in user + code. */ + if (/*CONSTCOND*/ 0) + goto yyerrorlab; + + /* Do not reclaim the symbols of the rule which action triggered + this YYERROR. */ + YYPOPSTACK (yylen); + yylen = 0; + YY_STACK_PRINT (yyss, yyssp); + yystate = *yyssp; + goto yyerrlab1; + + +/*-------------------------------------------------------------. +| yyerrlab1 -- common code for both syntax error and YYERROR. | +`-------------------------------------------------------------*/ +yyerrlab1: + yyerrstatus = 3; /* Each real token shifted decrements this. */ + + for (;;) + { + yyn = yypact[yystate]; + if (yyn != YYPACT_NINF) + { + yyn += YYTERROR; + if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR) + { + yyn = yytable[yyn]; + if (0 < yyn) + break; + } + } + + /* Pop the current state because it cannot handle the error token. */ + if (yyssp == yyss) + YYABORT; + + + yydestruct ("Error: popping", + yystos[yystate], yyvsp); + YYPOPSTACK (1); + yystate = *yyssp; + YY_STACK_PRINT (yyss, yyssp); + } + + *++yyvsp = yylval; + + + /* Shift the error token. */ + YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp); + + yystate = yyn; + goto yynewstate; + + +/*-------------------------------------. +| yyacceptlab -- YYACCEPT comes here. | +`-------------------------------------*/ +yyacceptlab: + yyresult = 0; + goto yyreturn; + +/*-----------------------------------. +| yyabortlab -- YYABORT comes here. | +`-----------------------------------*/ +yyabortlab: + yyresult = 1; + goto yyreturn; + +#if !defined(yyoverflow) || YYERROR_VERBOSE +/*-------------------------------------------------. +| yyexhaustedlab -- memory exhaustion comes here. | +`-------------------------------------------------*/ +yyexhaustedlab: + yyerror (YY_("memory exhausted")); + yyresult = 2; + /* Fall through. */ +#endif + +yyreturn: + if (yychar != YYEMPTY) + yydestruct ("Cleanup: discarding lookahead", + yytoken, &yylval); + /* Do not reclaim the symbols of the rule which action triggered + this YYABORT or YYACCEPT. */ + YYPOPSTACK (yylen); + YY_STACK_PRINT (yyss, yyssp); + while (yyssp != yyss) + { + yydestruct ("Cleanup: popping", + yystos[*yyssp], yyvsp); + YYPOPSTACK (1); + } +#ifndef yyoverflow + if (yyss != yyssa) + YYSTACK_FREE (yyss); +#endif +#if YYERROR_VERBOSE + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); +#endif + /* Make sure YYID is used. */ + return YYID (yyresult); +} + + + +/* Line 1675 of yacc.c */ +#line 455 "bootparse.y" + + +#include "bootscanner.c" + diff --git a/src/backend/bootstrap/bootscanner.c b/src/backend/bootstrap/bootscanner.c new file mode 100644 index 000000000..7d629216d --- /dev/null +++ b/src/backend/bootstrap/bootscanner.c @@ -0,0 +1,2118 @@ +#line 2 "bootscanner.c" + +#line 4 "bootscanner.c" + +#define YY_INT_ALIGNED short int + +/* A lexical scanner generated by flex */ + +#define yy_create_buffer boot_yy_create_buffer +#define yy_delete_buffer boot_yy_delete_buffer +#define yy_flex_debug boot_yy_flex_debug +#define yy_init_buffer boot_yy_init_buffer +#define yy_flush_buffer boot_yy_flush_buffer +#define yy_load_buffer_state boot_yy_load_buffer_state +#define yy_switch_to_buffer boot_yy_switch_to_buffer +#define yyin boot_yyin +#define yyleng boot_yyleng +#define yylex boot_yylex +#define yylineno boot_yylineno +#define yyout boot_yyout +#define yyrestart boot_yyrestart +#define yytext boot_yytext +#define yywrap boot_yywrap +#define yyalloc boot_yyalloc +#define yyrealloc boot_yyrealloc +#define yyfree boot_yyfree + +#define FLEX_SCANNER +#define YY_FLEX_MAJOR_VERSION 2 +#define YY_FLEX_MINOR_VERSION 5 +#define YY_FLEX_SUBMINOR_VERSION 35 +#if YY_FLEX_SUBMINOR_VERSION > 0 +#define FLEX_BETA +#endif + +/* First, we deal with platform-specific or compiler-specific issues. */ + +/* begin standard C headers. */ +#include +#include +#include +#include + +/* end standard C headers. */ + +/* flex integer type definitions */ + +#ifndef FLEXINT_H +#define FLEXINT_H + +/* C99 systems have . Non-C99 systems may or may not. */ + +#if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L + +/* C99 says to define __STDC_LIMIT_MACROS before including stdint.h, + * if you want the limit (max/min) macros for int types. + */ +#ifndef __STDC_LIMIT_MACROS +#define __STDC_LIMIT_MACROS 1 +#endif + +#include +typedef int8_t flex_int8_t; +typedef uint8_t flex_uint8_t; +typedef int16_t flex_int16_t; +typedef uint16_t flex_uint16_t; +typedef int32_t flex_int32_t; +typedef uint32_t flex_uint32_t; +#else +typedef signed char flex_int8_t; +typedef short int flex_int16_t; +typedef int flex_int32_t; +typedef unsigned char flex_uint8_t; +typedef unsigned short int flex_uint16_t; +typedef unsigned int flex_uint32_t; + +/* Limits of integral types. */ +#ifndef INT8_MIN +#define INT8_MIN (-128) +#endif +#ifndef INT16_MIN +#define INT16_MIN (-32767-1) +#endif +#ifndef INT32_MIN +#define INT32_MIN (-2147483647-1) +#endif +#ifndef INT8_MAX +#define INT8_MAX (127) +#endif +#ifndef INT16_MAX +#define INT16_MAX (32767) +#endif +#ifndef INT32_MAX +#define INT32_MAX (2147483647) +#endif +#ifndef UINT8_MAX +#define UINT8_MAX (255U) +#endif +#ifndef UINT16_MAX +#define UINT16_MAX (65535U) +#endif +#ifndef UINT32_MAX +#define UINT32_MAX (4294967295U) +#endif + +#endif /* ! C99 */ + +#endif /* ! FLEXINT_H */ + +#ifdef __cplusplus + +/* The "const" storage-class-modifier is valid. */ +#define YY_USE_CONST + +#else /* ! __cplusplus */ + +/* C99 requires __STDC__ to be defined as 1. */ +#if defined (__STDC__) + +#define YY_USE_CONST + +#endif /* defined (__STDC__) */ +#endif /* ! __cplusplus */ + +#ifdef YY_USE_CONST +#define yyconst const +#else +#define yyconst +#endif + +/* Returned upon end-of-file. */ +#define YY_NULL 0 + +/* Promotes a possibly negative, possibly signed char to an unsigned + * integer for use as an array index. If the signed char is negative, + * we want to instead treat it as an 8-bit unsigned char, hence the + * double cast. + */ +#define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c) + +/* Enter a start condition. This macro really ought to take a parameter, + * but we do it the disgusting crufty way forced on us by the ()-less + * definition of BEGIN. + */ +#define BEGIN (yy_start) = 1 + 2 * + +/* Translate the current start state into a value that can be later handed + * to BEGIN to return to the state. The YYSTATE alias is for lex + * compatibility. + */ +#define YY_START (((yy_start) - 1) / 2) +#define YYSTATE YY_START + +/* Action number for EOF rule of a given start state. */ +#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1) + +/* Special action meaning "start processing a new file". */ +#define YY_NEW_FILE boot_yyrestart(boot_yyin ) + +#define YY_END_OF_BUFFER_CHAR 0 + +/* Size of default input buffer. */ +#ifndef YY_BUF_SIZE +#ifdef __ia64__ +/* On IA-64, the buffer size is 16k, not 8k. + * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case. + * Ditto for the __ia64__ case accordingly. + */ +#define YY_BUF_SIZE 32768 +#else +#define YY_BUF_SIZE 16384 +#endif /* __ia64__ */ +#endif + +/* The state buf must be large enough to hold one state per character in the main buffer. + */ +#define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type)) + +#ifndef YY_TYPEDEF_YY_BUFFER_STATE +#define YY_TYPEDEF_YY_BUFFER_STATE +typedef struct yy_buffer_state *YY_BUFFER_STATE; +#endif + +extern int boot_yyleng; + +extern FILE *boot_yyin, *boot_yyout; + +#define EOB_ACT_CONTINUE_SCAN 0 +#define EOB_ACT_END_OF_FILE 1 +#define EOB_ACT_LAST_MATCH 2 + + #define YY_LESS_LINENO(n) + +/* Return all but the first "n" matched characters back to the input stream. */ +#define yyless(n) \ + do \ + { \ + /* Undo effects of setting up boot_yytext. */ \ + int yyless_macro_arg = (n); \ + YY_LESS_LINENO(yyless_macro_arg);\ + *yy_cp = (yy_hold_char); \ + YY_RESTORE_YY_MORE_OFFSET \ + (yy_c_buf_p) = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \ + YY_DO_BEFORE_ACTION; /* set up boot_yytext again */ \ + } \ + while ( 0 ) + +#define unput(c) yyunput( c, (yytext_ptr) ) + +#ifndef YY_TYPEDEF_YY_SIZE_T +#define YY_TYPEDEF_YY_SIZE_T +typedef size_t yy_size_t; +#endif + +#ifndef YY_STRUCT_YY_BUFFER_STATE +#define YY_STRUCT_YY_BUFFER_STATE +struct yy_buffer_state + { + FILE *yy_input_file; + + char *yy_ch_buf; /* input buffer */ + char *yy_buf_pos; /* current position in input buffer */ + + /* Size of input buffer in bytes, not including room for EOB + * characters. + */ + yy_size_t yy_buf_size; + + /* Number of characters read into yy_ch_buf, not including EOB + * characters. + */ + int yy_n_chars; + + /* Whether we "own" the buffer - i.e., we know we created it, + * and can realloc() it to grow it, and should free() it to + * delete it. + */ + int yy_is_our_buffer; + + /* Whether this is an "interactive" input source; if so, and + * if we're using stdio for input, then we want to use getc() + * instead of fread(), to make sure we stop fetching input after + * each newline. + */ + int yy_is_interactive; + + /* Whether we're considered to be at the beginning of a line. + * If so, '^' rules will be active on the next match, otherwise + * not. + */ + int yy_at_bol; + + int yy_bs_lineno; /**< The line count. */ + int yy_bs_column; /**< The column count. */ + + /* Whether to try to fill the input buffer when we reach the + * end of it. + */ + int yy_fill_buffer; + + int yy_buffer_status; + +#define YY_BUFFER_NEW 0 +#define YY_BUFFER_NORMAL 1 + /* When an EOF's been seen but there's still some text to process + * then we mark the buffer as YY_EOF_PENDING, to indicate that we + * shouldn't try reading from the input source any more. We might + * still have a bunch of tokens to match, though, because of + * possible backing-up. + * + * When we actually see the EOF, we change the status to "new" + * (via boot_yyrestart()), so that the user can continue scanning by + * just pointing boot_yyin at a new input file. + */ +#define YY_BUFFER_EOF_PENDING 2 + + }; +#endif /* !YY_STRUCT_YY_BUFFER_STATE */ + +/* Stack of input buffers. */ +static size_t yy_buffer_stack_top = 0; /**< index of top of stack. */ +static size_t yy_buffer_stack_max = 0; /**< capacity of stack. */ +static YY_BUFFER_STATE * yy_buffer_stack = 0; /**< Stack as an array. */ + +/* We provide macros for accessing buffer states in case in the + * future we want to put the buffer states in a more general + * "scanner state". + * + * Returns the top of the stack, or NULL. + */ +#define YY_CURRENT_BUFFER ( (yy_buffer_stack) \ + ? (yy_buffer_stack)[(yy_buffer_stack_top)] \ + : NULL) + +/* Same as previous macro, but useful when we know that the buffer stack is not + * NULL or when we need an lvalue. For internal use only. + */ +#define YY_CURRENT_BUFFER_LVALUE (yy_buffer_stack)[(yy_buffer_stack_top)] + +/* yy_hold_char holds the character lost when boot_yytext is formed. */ +static char yy_hold_char; +static int yy_n_chars; /* number of characters read into yy_ch_buf */ +int boot_yyleng; + +/* Points to current character in buffer. */ +static char *yy_c_buf_p = (char *) 0; +static int yy_init = 0; /* whether we need to initialize */ +static int yy_start = 0; /* start state number */ + +/* Flag which is used to allow boot_yywrap()'s to do buffer switches + * instead of setting up a fresh boot_yyin. A bit of a hack ... + */ +static int yy_did_buffer_switch_on_eof; + +void boot_yyrestart (FILE *input_file ); +void boot_yy_switch_to_buffer (YY_BUFFER_STATE new_buffer ); +YY_BUFFER_STATE boot_yy_create_buffer (FILE *file,int size ); +void boot_yy_delete_buffer (YY_BUFFER_STATE b ); +void boot_yy_flush_buffer (YY_BUFFER_STATE b ); +void boot_yypush_buffer_state (YY_BUFFER_STATE new_buffer ); +void boot_yypop_buffer_state (void ); + +static void boot_yyensure_buffer_stack (void ); +static void boot_yy_load_buffer_state (void ); +static void boot_yy_init_buffer (YY_BUFFER_STATE b,FILE *file ); + +#define YY_FLUSH_BUFFER boot_yy_flush_buffer(YY_CURRENT_BUFFER ) + +YY_BUFFER_STATE boot_yy_scan_buffer (char *base,yy_size_t size ); +YY_BUFFER_STATE boot_yy_scan_string (yyconst char *yy_str ); +YY_BUFFER_STATE boot_yy_scan_bytes (yyconst char *bytes,int len ); + +void *boot_yyalloc (yy_size_t ); +void *boot_yyrealloc (void *,yy_size_t ); +void boot_yyfree (void * ); + +#define yy_new_buffer boot_yy_create_buffer + +#define yy_set_interactive(is_interactive) \ + { \ + if ( ! YY_CURRENT_BUFFER ){ \ + boot_yyensure_buffer_stack (); \ + YY_CURRENT_BUFFER_LVALUE = \ + boot_yy_create_buffer(boot_yyin,YY_BUF_SIZE ); \ + } \ + YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \ + } + +#define yy_set_bol(at_bol) \ + { \ + if ( ! YY_CURRENT_BUFFER ){\ + boot_yyensure_buffer_stack (); \ + YY_CURRENT_BUFFER_LVALUE = \ + boot_yy_create_buffer(boot_yyin,YY_BUF_SIZE ); \ + } \ + YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \ + } + +#define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol) + +/* Begin user sect3 */ + +#define boot_yywrap(n) 1 +#define YY_SKIP_YYWRAP + +typedef unsigned char YY_CHAR; + +FILE *boot_yyin = (FILE *) 0, *boot_yyout = (FILE *) 0; + +typedef int yy_state_type; + +extern int boot_yylineno; + +int boot_yylineno = 1; + +extern char *boot_yytext; +#define yytext_ptr boot_yytext + +static yy_state_type yy_get_previous_state (void ); +static yy_state_type yy_try_NUL_trans (yy_state_type current_state ); +static int yy_get_next_buffer (void ); +static void yy_fatal_error (yyconst char msg[] ); + +/* Done after the current pattern has been matched and before the + * corresponding action - sets up boot_yytext. + */ +#define YY_DO_BEFORE_ACTION \ + (yytext_ptr) = yy_bp; \ + boot_yyleng = (size_t) (yy_cp - yy_bp); \ + (yy_hold_char) = *yy_cp; \ + *yy_cp = '\0'; \ + (yy_c_buf_p) = yy_cp; + +#define YY_NUM_RULES 34 +#define YY_END_OF_BUFFER 35 +/* This struct is not used in this scanner, + but its presence is necessary. */ +struct yy_trans_info + { + flex_int32_t yy_verify; + flex_int32_t yy_nxt; + }; +static yyconst flex_int16_t yy_accept[163] = + { 0, + 0, 0, 35, 33, 16, 15, 17, 33, 13, 14, + 11, 28, 33, 28, 12, 28, 28, 33, 28, 28, + 28, 28, 28, 28, 28, 28, 28, 28, 28, 18, + 0, 29, 28, 0, 28, 0, 31, 30, 28, 28, + 28, 0, 28, 0, 28, 28, 28, 28, 28, 28, + 28, 24, 28, 28, 28, 28, 28, 28, 28, 18, + 28, 0, 30, 0, 0, 28, 28, 0, 27, 4, + 0, 28, 28, 28, 28, 28, 28, 28, 28, 28, + 28, 28, 28, 28, 28, 28, 28, 0, 31, 0, + 0, 30, 32, 28, 28, 28, 28, 28, 28, 28, + + 28, 28, 1, 28, 28, 28, 28, 28, 28, 0, + 30, 28, 28, 20, 2, 28, 28, 23, 28, 28, + 28, 28, 26, 28, 25, 28, 9, 28, 3, 28, + 28, 10, 28, 28, 22, 28, 28, 19, 21, 28, + 28, 28, 28, 28, 28, 28, 5, 28, 28, 28, + 28, 28, 28, 8, 28, 28, 28, 7, 28, 28, + 6, 0 + } ; + +static yyconst flex_int32_t yy_ec[256] = + { 0, + 1, 1, 1, 1, 1, 1, 1, 1, 2, 3, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 4, 1, 5, 6, 1, 1, 1, 1, 7, + 8, 1, 9, 10, 11, 12, 1, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 1, 1, 1, + 14, 1, 1, 1, 15, 15, 15, 16, 17, 15, + 15, 15, 18, 15, 15, 15, 15, 15, 19, 15, + 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, + 20, 21, 22, 1, 23, 1, 24, 25, 26, 27, + + 28, 15, 29, 30, 31, 15, 15, 32, 15, 33, + 34, 35, 36, 37, 38, 39, 40, 15, 41, 42, + 43, 15, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1 + } ; + +static yyconst flex_int32_t yy_meta[44] = + { 0, + 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, + 3, 3, 3, 1, 3, 3, 3, 3, 3, 4, + 3, 1, 3, 3, 3, 3, 3, 3, 3, 3, + 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, + 3, 3, 3 + } ; + +static yyconst flex_int16_t yy_base[167] = + { 0, + 0, 384, 332, 460, 460, 460, 460, 307, 460, 460, + 460, 32, 290, 43, 460, 37, 54, 273, 56, 58, + 48, 53, 50, 61, 12, 69, 57, 72, 73, 0, + 271, 460, 38, 249, 102, 247, 34, 103, 105, 68, + 115, 112, 95, 192, 87, 98, 106, 102, 113, 117, + 125, 110, 120, 127, 132, 140, 139, 144, 137, 0, + 174, 179, 176, 185, 189, 187, 169, 184, 460, 167, + 178, 178, 177, 181, 185, 190, 188, 198, 199, 201, + 197, 206, 210, 211, 219, 224, 244, 168, 156, 257, + 149, 145, 87, 229, 233, 215, 244, 240, 251, 247, + + 256, 258, 243, 254, 265, 267, 268, 275, 276, 73, + 60, 277, 279, 280, 287, 294, 289, 290, 297, 299, + 301, 313, 308, 315, 310, 311, 312, 320, 322, 330, + 325, 327, 338, 345, 335, 337, 349, 340, 347, 359, + 354, 361, 362, 352, 370, 366, 369, 374, 379, 381, + 389, 393, 391, 386, 396, 394, 406, 404, 405, 408, + 409, 460, 449, 58, 451, 455 + } ; + +static yyconst flex_int16_t yy_def[167] = + { 0, + 162, 1, 162, 162, 162, 162, 162, 163, 162, 162, + 162, 164, 162, 165, 162, 165, 165, 162, 165, 165, + 20, 20, 20, 20, 20, 20, 20, 20, 20, 166, + 163, 162, 164, 162, 164, 162, 162, 162, 20, 20, + 20, 162, 20, 162, 20, 20, 20, 20, 20, 20, + 20, 20, 20, 20, 20, 20, 20, 20, 20, 166, + 164, 162, 162, 162, 162, 164, 20, 162, 162, 20, + 162, 20, 20, 20, 20, 20, 20, 20, 20, 20, + 20, 20, 20, 20, 20, 20, 164, 162, 162, 162, + 162, 162, 162, 20, 20, 20, 20, 20, 20, 20, + + 20, 20, 20, 20, 20, 20, 20, 20, 20, 162, + 162, 20, 20, 20, 20, 20, 20, 20, 20, 20, + 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, + 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, + 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, + 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, + 20, 0, 162, 162, 162, 162 + } ; + +static yyconst flex_int16_t yy_nxt[504] = + { 0, + 4, 5, 6, 7, 8, 4, 9, 10, 4, 11, + 12, 13, 14, 15, 16, 16, 16, 16, 17, 4, + 18, 4, 19, 16, 20, 21, 22, 16, 16, 16, + 23, 16, 16, 24, 16, 16, 25, 26, 27, 28, + 29, 16, 16, 34, 35, 54, 37, 33, 162, 162, + 62, 40, 36, 33, 38, 39, 42, 36, 36, 41, + 33, 62, 42, 36, 33, 162, 33, 162, 33, 162, + 41, 43, 111, 42, 36, 42, 36, 42, 36, 48, + 50, 40, 51, 40, 49, 111, 40, 40, 45, 40, + 56, 46, 40, 52, 40, 53, 40, 47, 55, 93, + + 40, 40, 40, 59, 57, 40, 40, 40, 40, 58, + 70, 40, 40, 38, 35, 63, 38, 39, 61, 64, + 40, 41, 36, 65, 68, 66, 72, 67, 40, 61, + 64, 73, 41, 69, 40, 75, 74, 40, 40, 40, + 76, 40, 77, 40, 40, 40, 40, 80, 40, 40, + 40, 78, 40, 40, 40, 82, 40, 92, 40, 40, + 40, 92, 79, 83, 40, 40, 40, 81, 89, 84, + 40, 40, 40, 40, 85, 86, 40, 40, 40, 40, + 89, 67, 65, 40, 66, 162, 87, 88, 63, 88, + 33, 89, 90, 91, 36, 91, 68, 92, 162, 87, + + 40, 93, 40, 90, 71, 69, 40, 36, 40, 94, + 40, 40, 96, 98, 40, 95, 40, 40, 40, 99, + 40, 40, 97, 40, 40, 100, 102, 40, 101, 40, + 40, 40, 40, 103, 40, 104, 40, 40, 40, 40, + 40, 114, 105, 40, 40, 40, 107, 106, 40, 40, + 40, 108, 40, 109, 40, 162, 87, 40, 40, 44, + 112, 37, 40, 40, 36, 110, 40, 110, 40, 111, + 113, 115, 40, 40, 117, 32, 40, 40, 116, 40, + 40, 119, 40, 40, 40, 44, 40, 40, 118, 40, + 40, 40, 122, 40, 120, 40, 121, 40, 40, 127, + + 40, 40, 37, 125, 40, 123, 40, 124, 40, 126, + 40, 32, 40, 40, 40, 40, 40, 128, 40, 40, + 40, 129, 40, 40, 131, 130, 40, 40, 40, 40, + 40, 162, 40, 40, 40, 133, 40, 132, 40, 134, + 40, 40, 135, 40, 40, 40, 40, 40, 40, 40, + 136, 40, 40, 40, 40, 40, 137, 138, 40, 40, + 40, 40, 139, 40, 40, 140, 40, 141, 40, 40, + 40, 40, 143, 40, 40, 142, 40, 40, 40, 40, + 40, 144, 40, 146, 40, 148, 40, 40, 40, 30, + 145, 40, 40, 40, 40, 40, 147, 149, 40, 150, + + 40, 40, 40, 40, 151, 40, 162, 40, 40, 40, + 152, 153, 40, 40, 40, 154, 155, 156, 40, 40, + 40, 162, 40, 162, 40, 40, 40, 40, 40, 40, + 40, 158, 40, 40, 157, 40, 159, 40, 160, 40, + 161, 40, 40, 40, 40, 40, 162, 40, 40, 31, + 31, 31, 31, 40, 40, 60, 162, 60, 60, 3, + 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, + 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, + 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, + 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, + + 162, 162, 162 + } ; + +static yyconst flex_int16_t yy_chk[504] = + { 0, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 12, 12, 25, 37, 16, 16, 33, + 37, 25, 12, 14, 14, 14, 16, 16, 33, 14, + 164, 37, 14, 14, 17, 17, 19, 19, 20, 20, + 14, 17, 111, 17, 17, 19, 19, 20, 20, 21, + 22, 21, 23, 23, 21, 110, 22, 21, 19, 23, + 27, 20, 22, 24, 24, 24, 27, 20, 26, 93, + + 24, 40, 26, 29, 28, 28, 29, 40, 26, 28, + 43, 28, 29, 35, 35, 38, 39, 39, 35, 38, + 45, 39, 35, 41, 42, 41, 45, 41, 43, 35, + 38, 46, 39, 42, 43, 48, 47, 46, 39, 47, + 49, 48, 50, 52, 39, 47, 49, 53, 41, 52, + 50, 51, 49, 53, 41, 55, 50, 92, 51, 53, + 54, 91, 51, 56, 51, 55, 54, 54, 89, 57, + 59, 55, 57, 56, 58, 59, 59, 58, 57, 56, + 88, 67, 61, 58, 61, 61, 61, 62, 63, 62, + 71, 62, 63, 64, 61, 64, 68, 64, 66, 66, + + 70, 65, 67, 63, 44, 68, 70, 66, 67, 72, + 73, 72, 74, 76, 74, 73, 73, 72, 75, 77, + 74, 77, 75, 76, 75, 78, 79, 77, 78, 76, + 81, 78, 79, 80, 80, 81, 81, 78, 79, 82, + 80, 96, 82, 83, 84, 82, 84, 83, 96, 83, + 84, 85, 85, 86, 96, 87, 87, 86, 85, 36, + 94, 34, 94, 86, 87, 90, 95, 90, 94, 90, + 95, 97, 95, 98, 99, 31, 103, 97, 98, 98, + 100, 101, 103, 97, 99, 18, 100, 104, 100, 101, + 99, 102, 105, 104, 102, 101, 104, 102, 105, 112, + + 106, 107, 13, 108, 105, 106, 106, 107, 108, 109, + 112, 8, 113, 114, 108, 109, 112, 113, 113, 114, + 115, 116, 117, 118, 119, 117, 115, 116, 117, 118, + 119, 3, 120, 116, 121, 121, 119, 120, 120, 122, + 121, 123, 124, 125, 126, 127, 122, 123, 124, 125, + 126, 127, 122, 128, 124, 129, 128, 130, 131, 128, + 132, 129, 131, 130, 131, 133, 132, 134, 135, 130, + 136, 133, 137, 138, 135, 136, 136, 133, 134, 138, + 139, 140, 137, 142, 134, 144, 139, 141, 137, 2, + 141, 144, 140, 141, 142, 143, 143, 145, 140, 146, + + 142, 143, 147, 145, 148, 146, 0, 148, 147, 145, + 149, 150, 149, 148, 150, 151, 152, 153, 149, 154, + 150, 0, 151, 0, 153, 154, 152, 156, 151, 155, + 153, 156, 152, 156, 155, 155, 157, 158, 159, 157, + 160, 160, 161, 158, 159, 157, 0, 160, 161, 163, + 163, 163, 163, 165, 165, 166, 0, 166, 166, 162, + 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, + 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, + 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, + 162, 162, 162, 162, 162, 162, 162, 162, 162, 162, + + 162, 162, 162 + } ; + +static yy_state_type yy_last_accepting_state; +static char *yy_last_accepting_cpos; + +extern int boot_yy_flex_debug; +int boot_yy_flex_debug = 0; + +/* The intent behind this definition is that it'll catch + * any uses of REJECT which flex missed. + */ +#define REJECT reject_used_but_not_detected +#define yymore() yymore_used_but_not_detected +#define YY_MORE_ADJ 0 +#define YY_RESTORE_YY_MORE_OFFSET +char *boot_yytext; +#line 1 "bootscanner.l" +#line 2 "bootscanner.l" +/*------------------------------------------------------------------------- + * + * bootscanner.l + * a lexical scanner for the bootstrap parser + * + * Portions Copyright (c) 1996-2012, PostgreSQL Global Development Group + * Portions Copyright (c) 1994, Regents of the University of California + * + * + * IDENTIFICATION + * src/backend/bootstrap/bootscanner.l + * + *------------------------------------------------------------------------- + */ +#include "postgres.h" + +#include "access/attnum.h" +#include "access/htup.h" +#include "access/itup.h" +#include "access/skey.h" +#include "access/tupdesc.h" +#include "bootstrap/bootstrap.h" +#include "catalog/pg_am.h" +#include "catalog/pg_attribute.h" +#include "catalog/pg_class.h" +#include "nodes/nodes.h" +#include "nodes/parsenodes.h" +#include "nodes/pg_list.h" +#include "nodes/primnodes.h" +#include "parser/scansup.h" +#include "rewrite/prs2lock.h" +#include "storage/block.h" +#include "storage/fd.h" +#include "storage/itemptr.h" +#include "storage/off.h" +#include "utils/rel.h" + +/* Not needed now that this file is compiled as part of bootparse. */ +/* #include "bootparse.h" */ + + +/* Avoid exit() on fatal scanner errors (a bit ugly -- see yy_fatal_error) */ +#undef fprintf +#define fprintf(file, fmt, msg) ereport(ERROR, (errmsg_internal("%s", msg))) + + +static int yyline = 1; /* line number for error reporting */ + +#define YY_NO_INPUT 1 +#line 696 "bootscanner.c" + +#define INITIAL 0 + +#ifndef YY_NO_UNISTD_H +/* Special case for "unistd.h", since it is non-ANSI. We include it way + * down here because we want the user's section 1 to have been scanned first. + * The user has a chance to override it with an option. + */ +#include +#endif + +#ifndef YY_EXTRA_TYPE +#define YY_EXTRA_TYPE void * +#endif + +static int yy_init_globals (void ); + +/* Accessor methods to globals. + These are made visible to non-reentrant scanners for convenience. */ + +int boot_yylex_destroy (void ); + +int boot_yyget_debug (void ); + +void boot_yyset_debug (int debug_flag ); + +YY_EXTRA_TYPE boot_yyget_extra (void ); + +void boot_yyset_extra (YY_EXTRA_TYPE user_defined ); + +FILE *boot_yyget_in (void ); + +void boot_yyset_in (FILE * in_str ); + +FILE *boot_yyget_out (void ); + +void boot_yyset_out (FILE * out_str ); + +int boot_yyget_leng (void ); + +char *boot_yyget_text (void ); + +int boot_yyget_lineno (void ); + +void boot_yyset_lineno (int line_number ); + +/* Macros after this point can all be overridden by user definitions in + * section 1. + */ + +#ifndef YY_SKIP_YYWRAP +#ifdef __cplusplus +extern "C" int boot_yywrap (void ); +#else +extern int boot_yywrap (void ); +#endif +#endif + +#ifndef yytext_ptr +static void yy_flex_strncpy (char *,yyconst char *,int ); +#endif + +#ifdef YY_NEED_STRLEN +static int yy_flex_strlen (yyconst char * ); +#endif + +#ifndef YY_NO_INPUT + +#ifdef __cplusplus +static int yyinput (void ); +#else +static int input (void ); +#endif + +#endif + +/* Amount of stuff to slurp up with each read. */ +#ifndef YY_READ_BUF_SIZE +#ifdef __ia64__ +/* On IA-64, the buffer size is 16k, not 8k */ +#define YY_READ_BUF_SIZE 16384 +#else +#define YY_READ_BUF_SIZE 8192 +#endif /* __ia64__ */ +#endif + +/* Copy whatever the last rule matched to the standard output. */ +#ifndef ECHO +/* This used to be an fputs(), but since the string might contain NUL's, + * we now use fwrite(). + */ +#define ECHO do { if (fwrite( boot_yytext, boot_yyleng, 1, boot_yyout )) {} } while (0) +#endif + +/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL, + * is returned in "result". + */ +#ifndef YY_INPUT +#define YY_INPUT(buf,result,max_size) \ + if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \ + { \ + int c = '*'; \ + size_t n; \ + for ( n = 0; n < max_size && \ + (c = getc( boot_yyin )) != EOF && c != '\n'; ++n ) \ + buf[n] = (char) c; \ + if ( c == '\n' ) \ + buf[n++] = (char) c; \ + if ( c == EOF && ferror( boot_yyin ) ) \ + YY_FATAL_ERROR( "input in flex scanner failed" ); \ + result = n; \ + } \ + else \ + { \ + errno=0; \ + while ( (result = fread(buf, 1, max_size, boot_yyin))==0 && ferror(boot_yyin)) \ + { \ + if( errno != EINTR) \ + { \ + YY_FATAL_ERROR( "input in flex scanner failed" ); \ + break; \ + } \ + errno=0; \ + clearerr(boot_yyin); \ + } \ + }\ +\ + +#endif + +/* No semi-colon after return; correct usage is to write "yyterminate();" - + * we don't want an extra ';' after the "return" because that will cause + * some compilers to complain about unreachable statements. + */ +#ifndef yyterminate +#define yyterminate() return YY_NULL +#endif + +/* Number of entries by which start-condition stack grows. */ +#ifndef YY_START_STACK_INCR +#define YY_START_STACK_INCR 25 +#endif + +/* Report a fatal error. */ +#ifndef YY_FATAL_ERROR +#define YY_FATAL_ERROR(msg) yy_fatal_error( msg ) +#endif + +/* end tables serialization structures and prototypes */ + +/* Default declaration of generated scanner - a define so the user can + * easily add parameters. + */ +#ifndef YY_DECL +#define YY_DECL_IS_OURS 1 + +extern int boot_yylex (void); + +#define YY_DECL int boot_yylex (void) +#endif /* !YY_DECL */ + +/* Code executed at the beginning of each rule, after boot_yytext and boot_yyleng + * have been set up. + */ +#ifndef YY_USER_ACTION +#define YY_USER_ACTION +#endif + +/* Code executed at the end of each rule. */ +#ifndef YY_BREAK +#define YY_BREAK break; +#endif + +#define YY_RULE_SETUP \ + if ( boot_yyleng > 0 ) \ + YY_CURRENT_BUFFER_LVALUE->yy_at_bol = \ + (boot_yytext[boot_yyleng - 1] == '\n'); \ + YY_USER_ACTION + +/** The main scanner function which does all the work. + */ +YY_DECL +{ + register yy_state_type yy_current_state; + register char *yy_cp, *yy_bp; + register int yy_act; + +#line 69 "bootscanner.l" + + +#line 887 "bootscanner.c" + + if ( !(yy_init) ) + { + (yy_init) = 1; + +#ifdef YY_USER_INIT + YY_USER_INIT; +#endif + + if ( ! (yy_start) ) + (yy_start) = 1; /* first start state */ + + if ( ! boot_yyin ) + boot_yyin = stdin; + + if ( ! boot_yyout ) + boot_yyout = stdout; + + if ( ! YY_CURRENT_BUFFER ) { + boot_yyensure_buffer_stack (); + YY_CURRENT_BUFFER_LVALUE = + boot_yy_create_buffer(boot_yyin,YY_BUF_SIZE ); + } + + boot_yy_load_buffer_state( ); + } + + while ( 1 ) /* loops until end-of-file is reached */ + { + yy_cp = (yy_c_buf_p); + + /* Support of boot_yytext. */ + *yy_cp = (yy_hold_char); + + /* yy_bp points to the position in yy_ch_buf of the start of + * the current run. + */ + yy_bp = yy_cp; + + yy_current_state = (yy_start); + yy_current_state += YY_AT_BOL(); +yy_match: + do + { + register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)]; + if ( yy_accept[yy_current_state] ) + { + (yy_last_accepting_state) = yy_current_state; + (yy_last_accepting_cpos) = yy_cp; + } + while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) + { + yy_current_state = (int) yy_def[yy_current_state]; + if ( yy_current_state >= 163 ) + yy_c = yy_meta[(unsigned int) yy_c]; + } + yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; + ++yy_cp; + } + while ( yy_current_state != 162 ); + yy_cp = (yy_last_accepting_cpos); + yy_current_state = (yy_last_accepting_state); + +yy_find_action: + yy_act = yy_accept[yy_current_state]; + + YY_DO_BEFORE_ACTION; + +do_action: /* This label is used only to access EOF actions. */ + + switch ( yy_act ) + { /* beginning of action switch */ + case 0: /* must back up */ + /* undo the effects of YY_DO_BEFORE_ACTION */ + *yy_cp = (yy_hold_char); + yy_cp = (yy_last_accepting_cpos); + yy_current_state = (yy_last_accepting_state); + goto yy_find_action; + +case 1: +YY_RULE_SETUP +#line 71 "bootscanner.l" +{ return(OPEN); } + YY_BREAK +case 2: +YY_RULE_SETUP +#line 73 "bootscanner.l" +{ return(XCLOSE); } + YY_BREAK +case 3: +YY_RULE_SETUP +#line 75 "bootscanner.l" +{ return(XCREATE); } + YY_BREAK +case 4: +YY_RULE_SETUP +#line 77 "bootscanner.l" +{ return(OBJ_ID); } + YY_BREAK +case 5: +YY_RULE_SETUP +#line 78 "bootscanner.l" +{ return(XBOOTSTRAP); } + YY_BREAK +case 6: +YY_RULE_SETUP +#line 79 "bootscanner.l" +{ return(XSHARED_RELATION); } + YY_BREAK +case 7: +YY_RULE_SETUP +#line 80 "bootscanner.l" +{ return(XWITHOUT_OIDS); } + YY_BREAK +case 8: +YY_RULE_SETUP +#line 81 "bootscanner.l" +{ return(XROWTYPE_OID); } + YY_BREAK +case 9: +YY_RULE_SETUP +#line 82 "bootscanner.l" +{ return(NULLVAL); } + YY_BREAK +case 10: +YY_RULE_SETUP +#line 84 "bootscanner.l" +{ return(INSERT_TUPLE); } + YY_BREAK +case 11: +YY_RULE_SETUP +#line 86 "bootscanner.l" +{ return(COMMA); } + YY_BREAK +case 12: +YY_RULE_SETUP +#line 87 "bootscanner.l" +{ return(EQUALS); } + YY_BREAK +case 13: +YY_RULE_SETUP +#line 88 "bootscanner.l" +{ return(LPAREN); } + YY_BREAK +case 14: +YY_RULE_SETUP +#line 89 "bootscanner.l" +{ return(RPAREN); } + YY_BREAK +case 15: +/* rule 15 can match eol */ +YY_RULE_SETUP +#line 91 "bootscanner.l" +{ yyline++; } + YY_BREAK +case 16: +YY_RULE_SETUP +#line 92 "bootscanner.l" +; + YY_BREAK +case 17: +YY_RULE_SETUP +#line 93 "bootscanner.l" +; + YY_BREAK +case 18: +YY_RULE_SETUP +#line 95 "bootscanner.l" +; /* drop everything after "#" for comments */ + YY_BREAK +case 19: +YY_RULE_SETUP +#line 98 "bootscanner.l" +{ return(XDECLARE); } + YY_BREAK +case 20: +YY_RULE_SETUP +#line 99 "bootscanner.l" +{ return(XBUILD); } + YY_BREAK +case 21: +YY_RULE_SETUP +#line 100 "bootscanner.l" +{ return(INDICES); } + YY_BREAK +case 22: +YY_RULE_SETUP +#line 101 "bootscanner.l" +{ return(UNIQUE); } + YY_BREAK +case 23: +YY_RULE_SETUP +#line 102 "bootscanner.l" +{ return(INDEX); } + YY_BREAK +case 24: +YY_RULE_SETUP +#line 103 "bootscanner.l" +{ return(ON); } + YY_BREAK +case 25: +YY_RULE_SETUP +#line 104 "bootscanner.l" +{ return(USING); } + YY_BREAK +case 26: +YY_RULE_SETUP +#line 105 "bootscanner.l" +{ return(XTOAST); } + YY_BREAK +case 27: +YY_RULE_SETUP +#line 107 "bootscanner.l" +{ + yylval.str = pstrdup(MapArrayTypeName(boot_yytext)); + return(ID); + } + YY_BREAK +case 28: +YY_RULE_SETUP +#line 111 "bootscanner.l" +{ + yylval.str = scanstr(boot_yytext); + return(ID); + } + YY_BREAK +case 29: +/* rule 29 can match eol */ +YY_RULE_SETUP +#line 115 "bootscanner.l" +{ + boot_yytext[strlen(boot_yytext)-1] = '\0'; /* strip off quotes */ + yylval.str = scanstr(boot_yytext+1); + boot_yytext[strlen(boot_yytext)] = '"'; /* restore quotes */ + return(ID); + } + YY_BREAK +case 30: +#line 123 "bootscanner.l" +case 31: +#line 124 "bootscanner.l" +case 32: +YY_RULE_SETUP +#line 124 "bootscanner.l" +{ + yylval.str = pstrdup(boot_yytext); + return(CONST_P); + } + YY_BREAK +case 33: +YY_RULE_SETUP +#line 129 "bootscanner.l" +{ + elog(ERROR, "syntax error at line %d: unexpected character \"%s\"", yyline, boot_yytext); + } + YY_BREAK +case 34: +YY_RULE_SETUP +#line 135 "bootscanner.l" +YY_FATAL_ERROR( "flex scanner jammed" ); + YY_BREAK +#line 1149 "bootscanner.c" +case YY_STATE_EOF(INITIAL): + yyterminate(); + + case YY_END_OF_BUFFER: + { + /* Amount of text matched not including the EOB char. */ + int yy_amount_of_matched_text = (int) (yy_cp - (yytext_ptr)) - 1; + + /* Undo the effects of YY_DO_BEFORE_ACTION. */ + *yy_cp = (yy_hold_char); + YY_RESTORE_YY_MORE_OFFSET + + if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW ) + { + /* We're scanning a new file or input source. It's + * possible that this happened because the user + * just pointed boot_yyin at a new source and called + * boot_yylex(). If so, then we have to assure + * consistency between YY_CURRENT_BUFFER and our + * globals. Here is the right place to do so, because + * this is the first action (other than possibly a + * back-up) that will match for the new input source. + */ + (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars; + YY_CURRENT_BUFFER_LVALUE->yy_input_file = boot_yyin; + YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL; + } + + /* Note that here we test for yy_c_buf_p "<=" to the position + * of the first EOB in the buffer, since yy_c_buf_p will + * already have been incremented past the NUL character + * (since all states make transitions on EOB to the + * end-of-buffer state). Contrast this with the test + * in input(). + */ + if ( (yy_c_buf_p) <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] ) + { /* This was really a NUL. */ + yy_state_type yy_next_state; + + (yy_c_buf_p) = (yytext_ptr) + yy_amount_of_matched_text; + + yy_current_state = yy_get_previous_state( ); + + /* Okay, we're now positioned to make the NUL + * transition. We couldn't have + * yy_get_previous_state() go ahead and do it + * for us because it doesn't know how to deal + * with the possibility of jamming (and we don't + * want to build jamming into it because then it + * will run more slowly). + */ + + yy_next_state = yy_try_NUL_trans( yy_current_state ); + + yy_bp = (yytext_ptr) + YY_MORE_ADJ; + + if ( yy_next_state ) + { + /* Consume the NUL. */ + yy_cp = ++(yy_c_buf_p); + yy_current_state = yy_next_state; + goto yy_match; + } + + else + { + yy_cp = (yy_last_accepting_cpos); + yy_current_state = (yy_last_accepting_state); + goto yy_find_action; + } + } + + else switch ( yy_get_next_buffer( ) ) + { + case EOB_ACT_END_OF_FILE: + { + (yy_did_buffer_switch_on_eof) = 0; + + if ( boot_yywrap( ) ) + { + /* Note: because we've taken care in + * yy_get_next_buffer() to have set up + * boot_yytext, we can now set up + * yy_c_buf_p so that if some total + * hoser (like flex itself) wants to + * call the scanner after we return the + * YY_NULL, it'll still work - another + * YY_NULL will get returned. + */ + (yy_c_buf_p) = (yytext_ptr) + YY_MORE_ADJ; + + yy_act = YY_STATE_EOF(YY_START); + goto do_action; + } + + else + { + if ( ! (yy_did_buffer_switch_on_eof) ) + YY_NEW_FILE; + } + break; + } + + case EOB_ACT_CONTINUE_SCAN: + (yy_c_buf_p) = + (yytext_ptr) + yy_amount_of_matched_text; + + yy_current_state = yy_get_previous_state( ); + + yy_cp = (yy_c_buf_p); + yy_bp = (yytext_ptr) + YY_MORE_ADJ; + goto yy_match; + + case EOB_ACT_LAST_MATCH: + (yy_c_buf_p) = + &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)]; + + yy_current_state = yy_get_previous_state( ); + + yy_cp = (yy_c_buf_p); + yy_bp = (yytext_ptr) + YY_MORE_ADJ; + goto yy_find_action; + } + break; + } + + default: + YY_FATAL_ERROR( + "fatal flex scanner internal error--no action found" ); + } /* end of action switch */ + } /* end of scanning one token */ +} /* end of boot_yylex */ + +/* yy_get_next_buffer - try to read in a new buffer + * + * Returns a code representing an action: + * EOB_ACT_LAST_MATCH - + * EOB_ACT_CONTINUE_SCAN - continue scanning from current position + * EOB_ACT_END_OF_FILE - end of file + */ +static int yy_get_next_buffer (void) +{ + register char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf; + register char *source = (yytext_ptr); + register int number_to_move, i; + int ret_val; + + if ( (yy_c_buf_p) > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] ) + YY_FATAL_ERROR( + "fatal flex scanner internal error--end of buffer missed" ); + + if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 ) + { /* Don't try to fill the buffer, so this is an EOF. */ + if ( (yy_c_buf_p) - (yytext_ptr) - YY_MORE_ADJ == 1 ) + { + /* We matched a single character, the EOB, so + * treat this as a final EOF. + */ + return EOB_ACT_END_OF_FILE; + } + + else + { + /* We matched some text prior to the EOB, first + * process it. + */ + return EOB_ACT_LAST_MATCH; + } + } + + /* Try to read more data. */ + + /* First move last chars to start of buffer. */ + number_to_move = (int) ((yy_c_buf_p) - (yytext_ptr)) - 1; + + for ( i = 0; i < number_to_move; ++i ) + *(dest++) = *(source++); + + if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING ) + /* don't do the read, it's not guaranteed to return an EOF, + * just force an EOF + */ + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars) = 0; + + else + { + int num_to_read = + YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1; + + while ( num_to_read <= 0 ) + { /* Not enough room in the buffer - grow it. */ + + /* just a shorter name for the current buffer */ + YY_BUFFER_STATE b = YY_CURRENT_BUFFER; + + int yy_c_buf_p_offset = + (int) ((yy_c_buf_p) - b->yy_ch_buf); + + if ( b->yy_is_our_buffer ) + { + int new_size = b->yy_buf_size * 2; + + if ( new_size <= 0 ) + b->yy_buf_size += b->yy_buf_size / 8; + else + b->yy_buf_size *= 2; + + b->yy_ch_buf = (char *) + /* Include room in for 2 EOB chars. */ + boot_yyrealloc((void *) b->yy_ch_buf,b->yy_buf_size + 2 ); + } + else + /* Can't grow it, we don't own it. */ + b->yy_ch_buf = 0; + + if ( ! b->yy_ch_buf ) + YY_FATAL_ERROR( + "fatal error - scanner input buffer overflow" ); + + (yy_c_buf_p) = &b->yy_ch_buf[yy_c_buf_p_offset]; + + num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size - + number_to_move - 1; + + } + + if ( num_to_read > YY_READ_BUF_SIZE ) + num_to_read = YY_READ_BUF_SIZE; + + /* Read in more data. */ + YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]), + (yy_n_chars), (size_t) num_to_read ); + + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); + } + + if ( (yy_n_chars) == 0 ) + { + if ( number_to_move == YY_MORE_ADJ ) + { + ret_val = EOB_ACT_END_OF_FILE; + boot_yyrestart(boot_yyin ); + } + + else + { + ret_val = EOB_ACT_LAST_MATCH; + YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = + YY_BUFFER_EOF_PENDING; + } + } + + else + ret_val = EOB_ACT_CONTINUE_SCAN; + + if ((yy_size_t) ((yy_n_chars) + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) { + /* Extend the array by 50%, plus the number we really need. */ + yy_size_t new_size = (yy_n_chars) + number_to_move + ((yy_n_chars) >> 1); + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) boot_yyrealloc((void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,new_size ); + if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf ) + YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" ); + } + + (yy_n_chars) += number_to_move; + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] = YY_END_OF_BUFFER_CHAR; + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] = YY_END_OF_BUFFER_CHAR; + + (yytext_ptr) = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0]; + + return ret_val; +} + +/* yy_get_previous_state - get the state just before the EOB char was reached */ + + static yy_state_type yy_get_previous_state (void) +{ + register yy_state_type yy_current_state; + register char *yy_cp; + + yy_current_state = (yy_start); + yy_current_state += YY_AT_BOL(); + + for ( yy_cp = (yytext_ptr) + YY_MORE_ADJ; yy_cp < (yy_c_buf_p); ++yy_cp ) + { + register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1); + if ( yy_accept[yy_current_state] ) + { + (yy_last_accepting_state) = yy_current_state; + (yy_last_accepting_cpos) = yy_cp; + } + while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) + { + yy_current_state = (int) yy_def[yy_current_state]; + if ( yy_current_state >= 163 ) + yy_c = yy_meta[(unsigned int) yy_c]; + } + yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; + } + + return yy_current_state; +} + +/* yy_try_NUL_trans - try to make a transition on the NUL character + * + * synopsis + * next_state = yy_try_NUL_trans( current_state ); + */ + static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state ) +{ + register int yy_is_jam; + register char *yy_cp = (yy_c_buf_p); + + register YY_CHAR yy_c = 1; + if ( yy_accept[yy_current_state] ) + { + (yy_last_accepting_state) = yy_current_state; + (yy_last_accepting_cpos) = yy_cp; + } + while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) + { + yy_current_state = (int) yy_def[yy_current_state]; + if ( yy_current_state >= 163 ) + yy_c = yy_meta[(unsigned int) yy_c]; + } + yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; + yy_is_jam = (yy_current_state == 162); + + return yy_is_jam ? 0 : yy_current_state; +} + +#ifndef YY_NO_INPUT +#ifdef __cplusplus + static int yyinput (void) +#else + static int input (void) +#endif + +{ + int c; + + *(yy_c_buf_p) = (yy_hold_char); + + if ( *(yy_c_buf_p) == YY_END_OF_BUFFER_CHAR ) + { + /* yy_c_buf_p now points to the character we want to return. + * If this occurs *before* the EOB characters, then it's a + * valid NUL; if not, then we've hit the end of the buffer. + */ + if ( (yy_c_buf_p) < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] ) + /* This was really a NUL. */ + *(yy_c_buf_p) = '\0'; + + else + { /* need more input */ + int offset = (yy_c_buf_p) - (yytext_ptr); + ++(yy_c_buf_p); + + switch ( yy_get_next_buffer( ) ) + { + case EOB_ACT_LAST_MATCH: + /* This happens because yy_g_n_b() + * sees that we've accumulated a + * token and flags that we need to + * try matching the token before + * proceeding. But for input(), + * there's no matching to consider. + * So convert the EOB_ACT_LAST_MATCH + * to EOB_ACT_END_OF_FILE. + */ + + /* Reset buffer status. */ + boot_yyrestart(boot_yyin ); + + /*FALLTHROUGH*/ + + case EOB_ACT_END_OF_FILE: + { + if ( boot_yywrap( ) ) + return EOF; + + if ( ! (yy_did_buffer_switch_on_eof) ) + YY_NEW_FILE; +#ifdef __cplusplus + return yyinput(); +#else + return input(); +#endif + } + + case EOB_ACT_CONTINUE_SCAN: + (yy_c_buf_p) = (yytext_ptr) + offset; + break; + } + } + } + + c = *(unsigned char *) (yy_c_buf_p); /* cast for 8-bit char's */ + *(yy_c_buf_p) = '\0'; /* preserve boot_yytext */ + (yy_hold_char) = *++(yy_c_buf_p); + + YY_CURRENT_BUFFER_LVALUE->yy_at_bol = (c == '\n'); + + return c; +} +#endif /* ifndef YY_NO_INPUT */ + +/** Immediately switch to a different input stream. + * @param input_file A readable stream. + * + * @note This function does not reset the start condition to @c INITIAL . + */ + void boot_yyrestart (FILE * input_file ) +{ + + if ( ! YY_CURRENT_BUFFER ){ + boot_yyensure_buffer_stack (); + YY_CURRENT_BUFFER_LVALUE = + boot_yy_create_buffer(boot_yyin,YY_BUF_SIZE ); + } + + boot_yy_init_buffer(YY_CURRENT_BUFFER,input_file ); + boot_yy_load_buffer_state( ); +} + +/** Switch to a different input buffer. + * @param new_buffer The new input buffer. + * + */ + void boot_yy_switch_to_buffer (YY_BUFFER_STATE new_buffer ) +{ + + /* TODO. We should be able to replace this entire function body + * with + * boot_yypop_buffer_state(); + * boot_yypush_buffer_state(new_buffer); + */ + boot_yyensure_buffer_stack (); + if ( YY_CURRENT_BUFFER == new_buffer ) + return; + + if ( YY_CURRENT_BUFFER ) + { + /* Flush out information for old buffer. */ + *(yy_c_buf_p) = (yy_hold_char); + YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p); + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); + } + + YY_CURRENT_BUFFER_LVALUE = new_buffer; + boot_yy_load_buffer_state( ); + + /* We don't actually know whether we did this switch during + * EOF (boot_yywrap()) processing, but the only time this flag + * is looked at is after boot_yywrap() is called, so it's safe + * to go ahead and always set it. + */ + (yy_did_buffer_switch_on_eof) = 1; +} + +static void boot_yy_load_buffer_state (void) +{ + (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars; + (yytext_ptr) = (yy_c_buf_p) = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos; + boot_yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file; + (yy_hold_char) = *(yy_c_buf_p); +} + +/** Allocate and initialize an input buffer state. + * @param file A readable stream. + * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE. + * + * @return the allocated buffer state. + */ + YY_BUFFER_STATE boot_yy_create_buffer (FILE * file, int size ) +{ + YY_BUFFER_STATE b; + + b = (YY_BUFFER_STATE) boot_yyalloc(sizeof( struct yy_buffer_state ) ); + if ( ! b ) + YY_FATAL_ERROR( "out of dynamic memory in boot_yy_create_buffer()" ); + + b->yy_buf_size = size; + + /* yy_ch_buf has to be 2 characters longer than the size given because + * we need to put in 2 end-of-buffer characters. + */ + b->yy_ch_buf = (char *) boot_yyalloc(b->yy_buf_size + 2 ); + if ( ! b->yy_ch_buf ) + YY_FATAL_ERROR( "out of dynamic memory in boot_yy_create_buffer()" ); + + b->yy_is_our_buffer = 1; + + boot_yy_init_buffer(b,file ); + + return b; +} + +/** Destroy the buffer. + * @param b a buffer created with boot_yy_create_buffer() + * + */ + void boot_yy_delete_buffer (YY_BUFFER_STATE b ) +{ + + if ( ! b ) + return; + + if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */ + YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0; + + if ( b->yy_is_our_buffer ) + boot_yyfree((void *) b->yy_ch_buf ); + + boot_yyfree((void *) b ); +} + +/* Initializes or reinitializes a buffer. + * This function is sometimes called more than once on the same buffer, + * such as during a boot_yyrestart() or at EOF. + */ + static void boot_yy_init_buffer (YY_BUFFER_STATE b, FILE * file ) + +{ + int oerrno = errno; + + boot_yy_flush_buffer(b ); + + b->yy_input_file = file; + b->yy_fill_buffer = 1; + + /* If b is the current buffer, then boot_yy_init_buffer was _probably_ + * called from boot_yyrestart() or through yy_get_next_buffer. + * In that case, we don't want to reset the lineno or column. + */ + if (b != YY_CURRENT_BUFFER){ + b->yy_bs_lineno = 1; + b->yy_bs_column = 0; + } + + b->yy_is_interactive = 0; + + errno = oerrno; +} + +/** Discard all buffered characters. On the next scan, YY_INPUT will be called. + * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER. + * + */ + void boot_yy_flush_buffer (YY_BUFFER_STATE b ) +{ + if ( ! b ) + return; + + b->yy_n_chars = 0; + + /* We always need two end-of-buffer characters. The first causes + * a transition to the end-of-buffer state. The second causes + * a jam in that state. + */ + b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR; + b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR; + + b->yy_buf_pos = &b->yy_ch_buf[0]; + + b->yy_at_bol = 1; + b->yy_buffer_status = YY_BUFFER_NEW; + + if ( b == YY_CURRENT_BUFFER ) + boot_yy_load_buffer_state( ); +} + +/** Pushes the new state onto the stack. The new state becomes + * the current state. This function will allocate the stack + * if necessary. + * @param new_buffer The new state. + * + */ +void boot_yypush_buffer_state (YY_BUFFER_STATE new_buffer ) +{ + if (new_buffer == NULL) + return; + + boot_yyensure_buffer_stack(); + + /* This block is copied from boot_yy_switch_to_buffer. */ + if ( YY_CURRENT_BUFFER ) + { + /* Flush out information for old buffer. */ + *(yy_c_buf_p) = (yy_hold_char); + YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p); + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); + } + + /* Only push if top exists. Otherwise, replace top. */ + if (YY_CURRENT_BUFFER) + (yy_buffer_stack_top)++; + YY_CURRENT_BUFFER_LVALUE = new_buffer; + + /* copied from boot_yy_switch_to_buffer. */ + boot_yy_load_buffer_state( ); + (yy_did_buffer_switch_on_eof) = 1; +} + +/** Removes and deletes the top of the stack, if present. + * The next element becomes the new top. + * + */ +void boot_yypop_buffer_state (void) +{ + if (!YY_CURRENT_BUFFER) + return; + + boot_yy_delete_buffer(YY_CURRENT_BUFFER ); + YY_CURRENT_BUFFER_LVALUE = NULL; + if ((yy_buffer_stack_top) > 0) + --(yy_buffer_stack_top); + + if (YY_CURRENT_BUFFER) { + boot_yy_load_buffer_state( ); + (yy_did_buffer_switch_on_eof) = 1; + } +} + +/* Allocates the stack if it does not exist. + * Guarantees space for at least one push. + */ +static void boot_yyensure_buffer_stack (void) +{ + int num_to_alloc; + + if (!(yy_buffer_stack)) { + + /* First allocation is just for 2 elements, since we don't know if this + * scanner will even need a stack. We use 2 instead of 1 to avoid an + * immediate realloc on the next call. + */ + num_to_alloc = 1; + (yy_buffer_stack) = (struct yy_buffer_state**)boot_yyalloc + (num_to_alloc * sizeof(struct yy_buffer_state*) + ); + if ( ! (yy_buffer_stack) ) + YY_FATAL_ERROR( "out of dynamic memory in boot_yyensure_buffer_stack()" ); + + memset((yy_buffer_stack), 0, num_to_alloc * sizeof(struct yy_buffer_state*)); + + (yy_buffer_stack_max) = num_to_alloc; + (yy_buffer_stack_top) = 0; + return; + } + + if ((yy_buffer_stack_top) >= ((yy_buffer_stack_max)) - 1){ + + /* Increase the buffer to prepare for a possible push. */ + int grow_size = 8 /* arbitrary grow size */; + + num_to_alloc = (yy_buffer_stack_max) + grow_size; + (yy_buffer_stack) = (struct yy_buffer_state**)boot_yyrealloc + ((yy_buffer_stack), + num_to_alloc * sizeof(struct yy_buffer_state*) + ); + if ( ! (yy_buffer_stack) ) + YY_FATAL_ERROR( "out of dynamic memory in boot_yyensure_buffer_stack()" ); + + /* zero only the new slots.*/ + memset((yy_buffer_stack) + (yy_buffer_stack_max), 0, grow_size * sizeof(struct yy_buffer_state*)); + (yy_buffer_stack_max) = num_to_alloc; + } +} + +/** Setup the input buffer state to scan directly from a user-specified character buffer. + * @param base the character buffer + * @param size the size in bytes of the character buffer + * + * @return the newly allocated buffer state object. + */ +YY_BUFFER_STATE boot_yy_scan_buffer (char * base, yy_size_t size ) +{ + YY_BUFFER_STATE b; + + if ( size < 2 || + base[size-2] != YY_END_OF_BUFFER_CHAR || + base[size-1] != YY_END_OF_BUFFER_CHAR ) + /* They forgot to leave room for the EOB's. */ + return 0; + + b = (YY_BUFFER_STATE) boot_yyalloc(sizeof( struct yy_buffer_state ) ); + if ( ! b ) + YY_FATAL_ERROR( "out of dynamic memory in boot_yy_scan_buffer()" ); + + b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */ + b->yy_buf_pos = b->yy_ch_buf = base; + b->yy_is_our_buffer = 0; + b->yy_input_file = 0; + b->yy_n_chars = b->yy_buf_size; + b->yy_is_interactive = 0; + b->yy_at_bol = 1; + b->yy_fill_buffer = 0; + b->yy_buffer_status = YY_BUFFER_NEW; + + boot_yy_switch_to_buffer(b ); + + return b; +} + +/** Setup the input buffer state to scan a string. The next call to boot_yylex() will + * scan from a @e copy of @a str. + * @param yystr a NUL-terminated string to scan + * + * @return the newly allocated buffer state object. + * @note If you want to scan bytes that may contain NUL values, then use + * boot_yy_scan_bytes() instead. + */ +YY_BUFFER_STATE boot_yy_scan_string (yyconst char * yystr ) +{ + + return boot_yy_scan_bytes(yystr,strlen(yystr) ); +} + +/** Setup the input buffer state to scan the given bytes. The next call to boot_yylex() will + * scan from a @e copy of @a bytes. + * @param yybytes the byte buffer to scan + * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes. + * + * @return the newly allocated buffer state object. + */ +YY_BUFFER_STATE boot_yy_scan_bytes (yyconst char * yybytes, int _yybytes_len ) +{ + YY_BUFFER_STATE b; + char *buf; + yy_size_t n; + int i; + + /* Get memory for full buffer, including space for trailing EOB's. */ + n = _yybytes_len + 2; + buf = (char *) boot_yyalloc(n ); + if ( ! buf ) + YY_FATAL_ERROR( "out of dynamic memory in boot_yy_scan_bytes()" ); + + for ( i = 0; i < _yybytes_len; ++i ) + buf[i] = yybytes[i]; + + buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR; + + b = boot_yy_scan_buffer(buf,n ); + if ( ! b ) + YY_FATAL_ERROR( "bad buffer in boot_yy_scan_bytes()" ); + + /* It's okay to grow etc. this buffer, and we should throw it + * away when we're done. + */ + b->yy_is_our_buffer = 1; + + return b; +} + +#ifndef YY_EXIT_FAILURE +#define YY_EXIT_FAILURE 2 +#endif + +static void yy_fatal_error (yyconst char* msg ) +{ + (void) fprintf( stderr, "%s\n", msg ); + exit( YY_EXIT_FAILURE ); +} + +/* Redefine yyless() so it works in section 3 code. */ + +#undef yyless +#define yyless(n) \ + do \ + { \ + /* Undo effects of setting up boot_yytext. */ \ + int yyless_macro_arg = (n); \ + YY_LESS_LINENO(yyless_macro_arg);\ + boot_yytext[boot_yyleng] = (yy_hold_char); \ + (yy_c_buf_p) = boot_yytext + yyless_macro_arg; \ + (yy_hold_char) = *(yy_c_buf_p); \ + *(yy_c_buf_p) = '\0'; \ + boot_yyleng = yyless_macro_arg; \ + } \ + while ( 0 ) + +/* Accessor methods (get/set functions) to struct members. */ + +/** Get the current line number. + * + */ +int boot_yyget_lineno (void) +{ + + return boot_yylineno; +} + +/** Get the input stream. + * + */ +FILE *boot_yyget_in (void) +{ + return boot_yyin; +} + +/** Get the output stream. + * + */ +FILE *boot_yyget_out (void) +{ + return boot_yyout; +} + +/** Get the length of the current token. + * + */ +int boot_yyget_leng (void) +{ + return boot_yyleng; +} + +/** Get the current token. + * + */ + +char *boot_yyget_text (void) +{ + return boot_yytext; +} + +/** Set the current line number. + * @param line_number + * + */ +void boot_yyset_lineno (int line_number ) +{ + + boot_yylineno = line_number; +} + +/** Set the input stream. This does not discard the current + * input buffer. + * @param in_str A readable stream. + * + * @see boot_yy_switch_to_buffer + */ +void boot_yyset_in (FILE * in_str ) +{ + boot_yyin = in_str ; +} + +void boot_yyset_out (FILE * out_str ) +{ + boot_yyout = out_str ; +} + +int boot_yyget_debug (void) +{ + return boot_yy_flex_debug; +} + +void boot_yyset_debug (int bdebug ) +{ + boot_yy_flex_debug = bdebug ; +} + +static int yy_init_globals (void) +{ + /* Initialization is the same as for the non-reentrant scanner. + * This function is called from boot_yylex_destroy(), so don't allocate here. + */ + + (yy_buffer_stack) = 0; + (yy_buffer_stack_top) = 0; + (yy_buffer_stack_max) = 0; + (yy_c_buf_p) = (char *) 0; + (yy_init) = 0; + (yy_start) = 0; + +/* Defined in main.c */ +#ifdef YY_STDINIT + boot_yyin = stdin; + boot_yyout = stdout; +#else + boot_yyin = (FILE *) 0; + boot_yyout = (FILE *) 0; +#endif + + /* For future reference: Set errno on error, since we are called by + * boot_yylex_init() + */ + return 0; +} + +/* boot_yylex_destroy is for both reentrant and non-reentrant scanners. */ +int boot_yylex_destroy (void) +{ + + /* Pop the buffer stack, destroying each element. */ + while(YY_CURRENT_BUFFER){ + boot_yy_delete_buffer(YY_CURRENT_BUFFER ); + YY_CURRENT_BUFFER_LVALUE = NULL; + boot_yypop_buffer_state(); + } + + /* Destroy the stack itself. */ + boot_yyfree((yy_buffer_stack) ); + (yy_buffer_stack) = NULL; + + /* Reset the globals. This is important in a non-reentrant scanner so the next time + * boot_yylex() is called, initialization will occur. */ + yy_init_globals( ); + + return 0; +} + +/* + * Internal utility routines. + */ + +#ifndef yytext_ptr +static void yy_flex_strncpy (char* s1, yyconst char * s2, int n ) +{ + register int i; + for ( i = 0; i < n; ++i ) + s1[i] = s2[i]; +} +#endif + +#ifdef YY_NEED_STRLEN +static int yy_flex_strlen (yyconst char * s ) +{ + register int n; + for ( n = 0; s[n]; ++n ) + ; + + return n; +} +#endif + +void *boot_yyalloc (yy_size_t size ) +{ + return (void *) malloc( size ); +} + +void *boot_yyrealloc (void * ptr, yy_size_t size ) +{ + /* The cast to (char *) in the following accommodates both + * implementations that use char* generic pointers, and those + * that use void* generic pointers. It works with the latter + * because both ANSI C and C++ allow castless assignment from + * any pointer type to void*, and deal with argument conversions + * as though doing an assignment. + */ + return (void *) realloc( (char *) ptr, size ); +} + +void boot_yyfree (void * ptr ) +{ + free( (char *) ptr ); /* see boot_yyrealloc() for (char *) cast */ +} + +#define YYTABLES_NAME "yytables" + +#line 135 "bootscanner.l" + + + +void +yyerror(const char *message) +{ + elog(ERROR, "%s at line %d", message, yyline); +} + diff --git a/src/backend/catalog/.gitignore b/src/backend/catalog/.gitignore deleted file mode 100644 index 557af3c0e..000000000 --- a/src/backend/catalog/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -/postgres.bki -/postgres.description -/postgres.shdescription -/schemapg.h diff --git a/src/backend/catalog/postgres.bki b/src/backend/catalog/postgres.bki new file mode 100644 index 000000000..c4cf1e23c --- /dev/null +++ b/src/backend/catalog/postgres.bki @@ -0,0 +1,5443 @@ +# PostgreSQL 9.2 +create pg_proc 1255 bootstrap rowtype_oid 81 + ( + proname = name , + pronamespace = oid , + proowner = oid , + prolang = oid , + procost = float4 , + prorows = float4 , + provariadic = oid , + protransform = regproc , + proisagg = bool , + proiswindow = bool , + prosecdef = bool , + proleakproof = bool , + proisstrict = bool , + proretset = bool , + provolatile = char , + pronargs = int2 , + pronargdefaults = int2 , + prorettype = oid , + proargtypes = oidvector , + proallargtypes = oid[] , + proargmodes = char[] , + proargnames = text[] , + proargdefaults = pg_node_tree , + prosrc = text , + probin = text , + proconfig = text[] , + proacl = aclitem[] + ) +insert OID = 1242 ( boolin 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "2275" _null_ _null_ _null_ _null_ boolin _null_ _null_ _null_ ) +insert OID = 1243 ( boolout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "16" _null_ _null_ _null_ _null_ boolout _null_ _null_ _null_ ) +insert OID = 1244 ( byteain 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "2275" _null_ _null_ _null_ _null_ byteain _null_ _null_ _null_ ) +insert OID = 31 ( byteaout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "17" _null_ _null_ _null_ _null_ byteaout _null_ _null_ _null_ ) +insert OID = 1245 ( charin 11 10 12 1 0 0 0 f f f f t f i 1 0 18 "2275" _null_ _null_ _null_ _null_ charin _null_ _null_ _null_ ) +insert OID = 33 ( charout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "18" _null_ _null_ _null_ _null_ charout _null_ _null_ _null_ ) +insert OID = 34 ( namein 11 10 12 1 0 0 0 f f f f t f i 1 0 19 "2275" _null_ _null_ _null_ _null_ namein _null_ _null_ _null_ ) +insert OID = 35 ( nameout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "19" _null_ _null_ _null_ _null_ nameout _null_ _null_ _null_ ) +insert OID = 38 ( int2in 11 10 12 1 0 0 0 f f f f t f i 1 0 21 "2275" _null_ _null_ _null_ _null_ int2in _null_ _null_ _null_ ) +insert OID = 39 ( int2out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "21" _null_ _null_ _null_ _null_ int2out _null_ _null_ _null_ ) +insert OID = 40 ( int2vectorin 11 10 12 1 0 0 0 f f f f t f i 1 0 22 "2275" _null_ _null_ _null_ _null_ int2vectorin _null_ _null_ _null_ ) +insert OID = 41 ( int2vectorout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "22" _null_ _null_ _null_ _null_ int2vectorout _null_ _null_ _null_ ) +insert OID = 42 ( int4in 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "2275" _null_ _null_ _null_ _null_ int4in _null_ _null_ _null_ ) +insert OID = 43 ( int4out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "23" _null_ _null_ _null_ _null_ int4out _null_ _null_ _null_ ) +insert OID = 44 ( regprocin 11 10 12 1 0 0 0 f f f f t f s 1 0 24 "2275" _null_ _null_ _null_ _null_ regprocin _null_ _null_ _null_ ) +insert OID = 45 ( regprocout 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "24" _null_ _null_ _null_ _null_ regprocout _null_ _null_ _null_ ) +insert OID = 46 ( textin 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "2275" _null_ _null_ _null_ _null_ textin _null_ _null_ _null_ ) +insert OID = 47 ( textout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "25" _null_ _null_ _null_ _null_ textout _null_ _null_ _null_ ) +insert OID = 48 ( tidin 11 10 12 1 0 0 0 f f f f t f i 1 0 27 "2275" _null_ _null_ _null_ _null_ tidin _null_ _null_ _null_ ) +insert OID = 49 ( tidout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "27" _null_ _null_ _null_ _null_ tidout _null_ _null_ _null_ ) +insert OID = 50 ( xidin 11 10 12 1 0 0 0 f f f f t f i 1 0 28 "2275" _null_ _null_ _null_ _null_ xidin _null_ _null_ _null_ ) +insert OID = 51 ( xidout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "28" _null_ _null_ _null_ _null_ xidout _null_ _null_ _null_ ) +insert OID = 52 ( cidin 11 10 12 1 0 0 0 f f f f t f i 1 0 29 "2275" _null_ _null_ _null_ _null_ cidin _null_ _null_ _null_ ) +insert OID = 53 ( cidout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "29" _null_ _null_ _null_ _null_ cidout _null_ _null_ _null_ ) +insert OID = 54 ( oidvectorin 11 10 12 1 0 0 0 f f f f t f i 1 0 30 "2275" _null_ _null_ _null_ _null_ oidvectorin _null_ _null_ _null_ ) +insert OID = 55 ( oidvectorout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "30" _null_ _null_ _null_ _null_ oidvectorout _null_ _null_ _null_ ) +insert OID = 56 ( boollt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "16 16" _null_ _null_ _null_ _null_ boollt _null_ _null_ _null_ ) +insert OID = 57 ( boolgt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "16 16" _null_ _null_ _null_ _null_ boolgt _null_ _null_ _null_ ) +insert OID = 60 ( booleq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "16 16" _null_ _null_ _null_ _null_ booleq _null_ _null_ _null_ ) +insert OID = 61 ( chareq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "18 18" _null_ _null_ _null_ _null_ chareq _null_ _null_ _null_ ) +insert OID = 62 ( nameeq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "19 19" _null_ _null_ _null_ _null_ nameeq _null_ _null_ _null_ ) +insert OID = 63 ( int2eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "21 21" _null_ _null_ _null_ _null_ int2eq _null_ _null_ _null_ ) +insert OID = 64 ( int2lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "21 21" _null_ _null_ _null_ _null_ int2lt _null_ _null_ _null_ ) +insert OID = 65 ( int4eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "23 23" _null_ _null_ _null_ _null_ int4eq _null_ _null_ _null_ ) +insert OID = 66 ( int4lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "23 23" _null_ _null_ _null_ _null_ int4lt _null_ _null_ _null_ ) +insert OID = 67 ( texteq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "25 25" _null_ _null_ _null_ _null_ texteq _null_ _null_ _null_ ) +insert OID = 68 ( xideq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "28 28" _null_ _null_ _null_ _null_ xideq _null_ _null_ _null_ ) +insert OID = 69 ( cideq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "29 29" _null_ _null_ _null_ _null_ cideq _null_ _null_ _null_ ) +insert OID = 70 ( charne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "18 18" _null_ _null_ _null_ _null_ charne _null_ _null_ _null_ ) +insert OID = 1246 ( charlt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "18 18" _null_ _null_ _null_ _null_ charlt _null_ _null_ _null_ ) +insert OID = 72 ( charle 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "18 18" _null_ _null_ _null_ _null_ charle _null_ _null_ _null_ ) +insert OID = 73 ( chargt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "18 18" _null_ _null_ _null_ _null_ chargt _null_ _null_ _null_ ) +insert OID = 74 ( charge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "18 18" _null_ _null_ _null_ _null_ charge _null_ _null_ _null_ ) +insert OID = 77 ( int4 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "18" _null_ _null_ _null_ _null_ chartoi4 _null_ _null_ _null_ ) +insert OID = 78 ( char 11 10 12 1 0 0 0 f f f f t f i 1 0 18 "23" _null_ _null_ _null_ _null_ i4tochar _null_ _null_ _null_ ) +insert OID = 79 ( nameregexeq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "19 25" _null_ _null_ _null_ _null_ nameregexeq _null_ _null_ _null_ ) +insert OID = 1252 ( nameregexne 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "19 25" _null_ _null_ _null_ _null_ nameregexne _null_ _null_ _null_ ) +insert OID = 1254 ( textregexeq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "25 25" _null_ _null_ _null_ _null_ textregexeq _null_ _null_ _null_ ) +insert OID = 1256 ( textregexne 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "25 25" _null_ _null_ _null_ _null_ textregexne _null_ _null_ _null_ ) +insert OID = 1257 ( textlen 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "25" _null_ _null_ _null_ _null_ textlen _null_ _null_ _null_ ) +insert OID = 1258 ( textcat 11 10 12 1 0 0 0 f f f f t f i 2 0 25 "25 25" _null_ _null_ _null_ _null_ textcat _null_ _null_ _null_ ) +insert OID = 84 ( boolne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "16 16" _null_ _null_ _null_ _null_ boolne _null_ _null_ _null_ ) +insert OID = 89 ( version 11 10 12 1 0 0 0 f f f f t f s 0 0 25 "" _null_ _null_ _null_ _null_ pgsql_version _null_ _null_ _null_ ) +insert OID = 101 ( eqsel 11 10 12 1 0 0 0 f f f f t f s 4 0 701 "2281 26 2281 23" _null_ _null_ _null_ _null_ eqsel _null_ _null_ _null_ ) +insert OID = 102 ( neqsel 11 10 12 1 0 0 0 f f f f t f s 4 0 701 "2281 26 2281 23" _null_ _null_ _null_ _null_ neqsel _null_ _null_ _null_ ) +insert OID = 103 ( scalarltsel 11 10 12 1 0 0 0 f f f f t f s 4 0 701 "2281 26 2281 23" _null_ _null_ _null_ _null_ scalarltsel _null_ _null_ _null_ ) +insert OID = 104 ( scalargtsel 11 10 12 1 0 0 0 f f f f t f s 4 0 701 "2281 26 2281 23" _null_ _null_ _null_ _null_ scalargtsel _null_ _null_ _null_ ) +insert OID = 105 ( eqjoinsel 11 10 12 1 0 0 0 f f f f t f s 5 0 701 "2281 26 2281 21 2281" _null_ _null_ _null_ _null_ eqjoinsel _null_ _null_ _null_ ) +insert OID = 106 ( neqjoinsel 11 10 12 1 0 0 0 f f f f t f s 5 0 701 "2281 26 2281 21 2281" _null_ _null_ _null_ _null_ neqjoinsel _null_ _null_ _null_ ) +insert OID = 107 ( scalarltjoinsel 11 10 12 1 0 0 0 f f f f t f s 5 0 701 "2281 26 2281 21 2281" _null_ _null_ _null_ _null_ scalarltjoinsel _null_ _null_ _null_ ) +insert OID = 108 ( scalargtjoinsel 11 10 12 1 0 0 0 f f f f t f s 5 0 701 "2281 26 2281 21 2281" _null_ _null_ _null_ _null_ scalargtjoinsel _null_ _null_ _null_ ) +insert OID = 109 ( unknownin 11 10 12 1 0 0 0 f f f f t f i 1 0 705 "2275" _null_ _null_ _null_ _null_ unknownin _null_ _null_ _null_ ) +insert OID = 110 ( unknownout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "705" _null_ _null_ _null_ _null_ unknownout _null_ _null_ _null_ ) +insert OID = 111 ( numeric_fac 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "20" _null_ _null_ _null_ _null_ numeric_fac _null_ _null_ _null_ ) +insert OID = 115 ( box_above_eq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "603 603" _null_ _null_ _null_ _null_ box_above_eq _null_ _null_ _null_ ) +insert OID = 116 ( box_below_eq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "603 603" _null_ _null_ _null_ _null_ box_below_eq _null_ _null_ _null_ ) +insert OID = 117 ( point_in 11 10 12 1 0 0 0 f f f f t f i 1 0 600 "2275" _null_ _null_ _null_ _null_ point_in _null_ _null_ _null_ ) +insert OID = 118 ( point_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "600" _null_ _null_ _null_ _null_ point_out _null_ _null_ _null_ ) +insert OID = 119 ( lseg_in 11 10 12 1 0 0 0 f f f f t f i 1 0 601 "2275" _null_ _null_ _null_ _null_ lseg_in _null_ _null_ _null_ ) +insert OID = 120 ( lseg_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "601" _null_ _null_ _null_ _null_ lseg_out _null_ _null_ _null_ ) +insert OID = 121 ( path_in 11 10 12 1 0 0 0 f f f f t f i 1 0 602 "2275" _null_ _null_ _null_ _null_ path_in _null_ _null_ _null_ ) +insert OID = 122 ( path_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "602" _null_ _null_ _null_ _null_ path_out _null_ _null_ _null_ ) +insert OID = 123 ( box_in 11 10 12 1 0 0 0 f f f f t f i 1 0 603 "2275" _null_ _null_ _null_ _null_ box_in _null_ _null_ _null_ ) +insert OID = 124 ( box_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "603" _null_ _null_ _null_ _null_ box_out _null_ _null_ _null_ ) +insert OID = 125 ( box_overlap 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "603 603" _null_ _null_ _null_ _null_ box_overlap _null_ _null_ _null_ ) +insert OID = 126 ( box_ge 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "603 603" _null_ _null_ _null_ _null_ box_ge _null_ _null_ _null_ ) +insert OID = 127 ( box_gt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "603 603" _null_ _null_ _null_ _null_ box_gt _null_ _null_ _null_ ) +insert OID = 128 ( box_eq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "603 603" _null_ _null_ _null_ _null_ box_eq _null_ _null_ _null_ ) +insert OID = 129 ( box_lt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "603 603" _null_ _null_ _null_ _null_ box_lt _null_ _null_ _null_ ) +insert OID = 130 ( box_le 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "603 603" _null_ _null_ _null_ _null_ box_le _null_ _null_ _null_ ) +insert OID = 131 ( point_above 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "600 600" _null_ _null_ _null_ _null_ point_above _null_ _null_ _null_ ) +insert OID = 132 ( point_left 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "600 600" _null_ _null_ _null_ _null_ point_left _null_ _null_ _null_ ) +insert OID = 133 ( point_right 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "600 600" _null_ _null_ _null_ _null_ point_right _null_ _null_ _null_ ) +insert OID = 134 ( point_below 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "600 600" _null_ _null_ _null_ _null_ point_below _null_ _null_ _null_ ) +insert OID = 135 ( point_eq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "600 600" _null_ _null_ _null_ _null_ point_eq _null_ _null_ _null_ ) +insert OID = 136 ( on_pb 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "600 603" _null_ _null_ _null_ _null_ on_pb _null_ _null_ _null_ ) +insert OID = 137 ( on_ppath 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "600 602" _null_ _null_ _null_ _null_ on_ppath _null_ _null_ _null_ ) +insert OID = 138 ( box_center 11 10 12 1 0 0 0 f f f f t f i 1 0 600 "603" _null_ _null_ _null_ _null_ box_center _null_ _null_ _null_ ) +insert OID = 139 ( areasel 11 10 12 1 0 0 0 f f f f t f s 4 0 701 "2281 26 2281 23" _null_ _null_ _null_ _null_ areasel _null_ _null_ _null_ ) +insert OID = 140 ( areajoinsel 11 10 12 1 0 0 0 f f f f t f s 5 0 701 "2281 26 2281 21 2281" _null_ _null_ _null_ _null_ areajoinsel _null_ _null_ _null_ ) +insert OID = 141 ( int4mul 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "23 23" _null_ _null_ _null_ _null_ int4mul _null_ _null_ _null_ ) +insert OID = 144 ( int4ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "23 23" _null_ _null_ _null_ _null_ int4ne _null_ _null_ _null_ ) +insert OID = 145 ( int2ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "21 21" _null_ _null_ _null_ _null_ int2ne _null_ _null_ _null_ ) +insert OID = 146 ( int2gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "21 21" _null_ _null_ _null_ _null_ int2gt _null_ _null_ _null_ ) +insert OID = 147 ( int4gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "23 23" _null_ _null_ _null_ _null_ int4gt _null_ _null_ _null_ ) +insert OID = 148 ( int2le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "21 21" _null_ _null_ _null_ _null_ int2le _null_ _null_ _null_ ) +insert OID = 149 ( int4le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "23 23" _null_ _null_ _null_ _null_ int4le _null_ _null_ _null_ ) +insert OID = 150 ( int4ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "23 23" _null_ _null_ _null_ _null_ int4ge _null_ _null_ _null_ ) +insert OID = 151 ( int2ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "21 21" _null_ _null_ _null_ _null_ int2ge _null_ _null_ _null_ ) +insert OID = 152 ( int2mul 11 10 12 1 0 0 0 f f f f t f i 2 0 21 "21 21" _null_ _null_ _null_ _null_ int2mul _null_ _null_ _null_ ) +insert OID = 153 ( int2div 11 10 12 1 0 0 0 f f f f t f i 2 0 21 "21 21" _null_ _null_ _null_ _null_ int2div _null_ _null_ _null_ ) +insert OID = 154 ( int4div 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "23 23" _null_ _null_ _null_ _null_ int4div _null_ _null_ _null_ ) +insert OID = 155 ( int2mod 11 10 12 1 0 0 0 f f f f t f i 2 0 21 "21 21" _null_ _null_ _null_ _null_ int2mod _null_ _null_ _null_ ) +insert OID = 156 ( int4mod 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "23 23" _null_ _null_ _null_ _null_ int4mod _null_ _null_ _null_ ) +insert OID = 157 ( textne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "25 25" _null_ _null_ _null_ _null_ textne _null_ _null_ _null_ ) +insert OID = 158 ( int24eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "21 23" _null_ _null_ _null_ _null_ int24eq _null_ _null_ _null_ ) +insert OID = 159 ( int42eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "23 21" _null_ _null_ _null_ _null_ int42eq _null_ _null_ _null_ ) +insert OID = 160 ( int24lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "21 23" _null_ _null_ _null_ _null_ int24lt _null_ _null_ _null_ ) +insert OID = 161 ( int42lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "23 21" _null_ _null_ _null_ _null_ int42lt _null_ _null_ _null_ ) +insert OID = 162 ( int24gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "21 23" _null_ _null_ _null_ _null_ int24gt _null_ _null_ _null_ ) +insert OID = 163 ( int42gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "23 21" _null_ _null_ _null_ _null_ int42gt _null_ _null_ _null_ ) +insert OID = 164 ( int24ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "21 23" _null_ _null_ _null_ _null_ int24ne _null_ _null_ _null_ ) +insert OID = 165 ( int42ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "23 21" _null_ _null_ _null_ _null_ int42ne _null_ _null_ _null_ ) +insert OID = 166 ( int24le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "21 23" _null_ _null_ _null_ _null_ int24le _null_ _null_ _null_ ) +insert OID = 167 ( int42le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "23 21" _null_ _null_ _null_ _null_ int42le _null_ _null_ _null_ ) +insert OID = 168 ( int24ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "21 23" _null_ _null_ _null_ _null_ int24ge _null_ _null_ _null_ ) +insert OID = 169 ( int42ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "23 21" _null_ _null_ _null_ _null_ int42ge _null_ _null_ _null_ ) +insert OID = 170 ( int24mul 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "21 23" _null_ _null_ _null_ _null_ int24mul _null_ _null_ _null_ ) +insert OID = 171 ( int42mul 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "23 21" _null_ _null_ _null_ _null_ int42mul _null_ _null_ _null_ ) +insert OID = 172 ( int24div 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "21 23" _null_ _null_ _null_ _null_ int24div _null_ _null_ _null_ ) +insert OID = 173 ( int42div 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "23 21" _null_ _null_ _null_ _null_ int42div _null_ _null_ _null_ ) +insert OID = 176 ( int2pl 11 10 12 1 0 0 0 f f f f t f i 2 0 21 "21 21" _null_ _null_ _null_ _null_ int2pl _null_ _null_ _null_ ) +insert OID = 177 ( int4pl 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "23 23" _null_ _null_ _null_ _null_ int4pl _null_ _null_ _null_ ) +insert OID = 178 ( int24pl 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "21 23" _null_ _null_ _null_ _null_ int24pl _null_ _null_ _null_ ) +insert OID = 179 ( int42pl 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "23 21" _null_ _null_ _null_ _null_ int42pl _null_ _null_ _null_ ) +insert OID = 180 ( int2mi 11 10 12 1 0 0 0 f f f f t f i 2 0 21 "21 21" _null_ _null_ _null_ _null_ int2mi _null_ _null_ _null_ ) +insert OID = 181 ( int4mi 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "23 23" _null_ _null_ _null_ _null_ int4mi _null_ _null_ _null_ ) +insert OID = 182 ( int24mi 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "21 23" _null_ _null_ _null_ _null_ int24mi _null_ _null_ _null_ ) +insert OID = 183 ( int42mi 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "23 21" _null_ _null_ _null_ _null_ int42mi _null_ _null_ _null_ ) +insert OID = 184 ( oideq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "26 26" _null_ _null_ _null_ _null_ oideq _null_ _null_ _null_ ) +insert OID = 185 ( oidne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "26 26" _null_ _null_ _null_ _null_ oidne _null_ _null_ _null_ ) +insert OID = 186 ( box_same 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "603 603" _null_ _null_ _null_ _null_ box_same _null_ _null_ _null_ ) +insert OID = 187 ( box_contain 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "603 603" _null_ _null_ _null_ _null_ box_contain _null_ _null_ _null_ ) +insert OID = 188 ( box_left 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "603 603" _null_ _null_ _null_ _null_ box_left _null_ _null_ _null_ ) +insert OID = 189 ( box_overleft 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "603 603" _null_ _null_ _null_ _null_ box_overleft _null_ _null_ _null_ ) +insert OID = 190 ( box_overright 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "603 603" _null_ _null_ _null_ _null_ box_overright _null_ _null_ _null_ ) +insert OID = 191 ( box_right 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "603 603" _null_ _null_ _null_ _null_ box_right _null_ _null_ _null_ ) +insert OID = 192 ( box_contained 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "603 603" _null_ _null_ _null_ _null_ box_contained _null_ _null_ _null_ ) +insert OID = 193 ( box_contain_pt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "603 600" _null_ _null_ _null_ _null_ box_contain_pt _null_ _null_ _null_ ) +insert OID = 195 ( pg_node_tree_in 11 10 12 1 0 0 0 f f f f t f i 1 0 194 "2275" _null_ _null_ _null_ _null_ pg_node_tree_in _null_ _null_ _null_ ) +insert OID = 196 ( pg_node_tree_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "194" _null_ _null_ _null_ _null_ pg_node_tree_out _null_ _null_ _null_ ) +insert OID = 197 ( pg_node_tree_recv 11 10 12 1 0 0 0 f f f f t f s 1 0 194 "2281" _null_ _null_ _null_ _null_ pg_node_tree_recv _null_ _null_ _null_ ) +insert OID = 198 ( pg_node_tree_send 11 10 12 1 0 0 0 f f f f t f s 1 0 17 "194" _null_ _null_ _null_ _null_ pg_node_tree_send _null_ _null_ _null_ ) +insert OID = 200 ( float4in 11 10 12 1 0 0 0 f f f f t f i 1 0 700 "2275" _null_ _null_ _null_ _null_ float4in _null_ _null_ _null_ ) +insert OID = 201 ( float4out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "700" _null_ _null_ _null_ _null_ float4out _null_ _null_ _null_ ) +insert OID = 202 ( float4mul 11 10 12 1 0 0 0 f f f f t f i 2 0 700 "700 700" _null_ _null_ _null_ _null_ float4mul _null_ _null_ _null_ ) +insert OID = 203 ( float4div 11 10 12 1 0 0 0 f f f f t f i 2 0 700 "700 700" _null_ _null_ _null_ _null_ float4div _null_ _null_ _null_ ) +insert OID = 204 ( float4pl 11 10 12 1 0 0 0 f f f f t f i 2 0 700 "700 700" _null_ _null_ _null_ _null_ float4pl _null_ _null_ _null_ ) +insert OID = 205 ( float4mi 11 10 12 1 0 0 0 f f f f t f i 2 0 700 "700 700" _null_ _null_ _null_ _null_ float4mi _null_ _null_ _null_ ) +insert OID = 206 ( float4um 11 10 12 1 0 0 0 f f f f t f i 1 0 700 "700" _null_ _null_ _null_ _null_ float4um _null_ _null_ _null_ ) +insert OID = 207 ( float4abs 11 10 12 1 0 0 0 f f f f t f i 1 0 700 "700" _null_ _null_ _null_ _null_ float4abs _null_ _null_ _null_ ) +insert OID = 208 ( float4_accum 11 10 12 1 0 0 0 f f f f t f i 2 0 1022 "1022 700" _null_ _null_ _null_ _null_ float4_accum _null_ _null_ _null_ ) +insert OID = 209 ( float4larger 11 10 12 1 0 0 0 f f f f t f i 2 0 700 "700 700" _null_ _null_ _null_ _null_ float4larger _null_ _null_ _null_ ) +insert OID = 211 ( float4smaller 11 10 12 1 0 0 0 f f f f t f i 2 0 700 "700 700" _null_ _null_ _null_ _null_ float4smaller _null_ _null_ _null_ ) +insert OID = 212 ( int4um 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "23" _null_ _null_ _null_ _null_ int4um _null_ _null_ _null_ ) +insert OID = 213 ( int2um 11 10 12 1 0 0 0 f f f f t f i 1 0 21 "21" _null_ _null_ _null_ _null_ int2um _null_ _null_ _null_ ) +insert OID = 214 ( float8in 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "2275" _null_ _null_ _null_ _null_ float8in _null_ _null_ _null_ ) +insert OID = 215 ( float8out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "701" _null_ _null_ _null_ _null_ float8out _null_ _null_ _null_ ) +insert OID = 216 ( float8mul 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "701 701" _null_ _null_ _null_ _null_ float8mul _null_ _null_ _null_ ) +insert OID = 217 ( float8div 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "701 701" _null_ _null_ _null_ _null_ float8div _null_ _null_ _null_ ) +insert OID = 218 ( float8pl 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "701 701" _null_ _null_ _null_ _null_ float8pl _null_ _null_ _null_ ) +insert OID = 219 ( float8mi 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "701 701" _null_ _null_ _null_ _null_ float8mi _null_ _null_ _null_ ) +insert OID = 220 ( float8um 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ float8um _null_ _null_ _null_ ) +insert OID = 221 ( float8abs 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ float8abs _null_ _null_ _null_ ) +insert OID = 222 ( float8_accum 11 10 12 1 0 0 0 f f f f t f i 2 0 1022 "1022 701" _null_ _null_ _null_ _null_ float8_accum _null_ _null_ _null_ ) +insert OID = 223 ( float8larger 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "701 701" _null_ _null_ _null_ _null_ float8larger _null_ _null_ _null_ ) +insert OID = 224 ( float8smaller 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "701 701" _null_ _null_ _null_ _null_ float8smaller _null_ _null_ _null_ ) +insert OID = 225 ( lseg_center 11 10 12 1 0 0 0 f f f f t f i 1 0 600 "601" _null_ _null_ _null_ _null_ lseg_center _null_ _null_ _null_ ) +insert OID = 226 ( path_center 11 10 12 1 0 0 0 f f f f t f i 1 0 600 "602" _null_ _null_ _null_ _null_ path_center _null_ _null_ _null_ ) +insert OID = 227 ( poly_center 11 10 12 1 0 0 0 f f f f t f i 1 0 600 "604" _null_ _null_ _null_ _null_ poly_center _null_ _null_ _null_ ) +insert OID = 228 ( dround 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ dround _null_ _null_ _null_ ) +insert OID = 229 ( dtrunc 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ dtrunc _null_ _null_ _null_ ) +insert OID = 2308 ( ceil 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ dceil _null_ _null_ _null_ ) +insert OID = 2320 ( ceiling 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ dceil _null_ _null_ _null_ ) +insert OID = 2309 ( floor 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ dfloor _null_ _null_ _null_ ) +insert OID = 2310 ( sign 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ dsign _null_ _null_ _null_ ) +insert OID = 230 ( dsqrt 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ dsqrt _null_ _null_ _null_ ) +insert OID = 231 ( dcbrt 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ dcbrt _null_ _null_ _null_ ) +insert OID = 232 ( dpow 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "701 701" _null_ _null_ _null_ _null_ dpow _null_ _null_ _null_ ) +insert OID = 233 ( dexp 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ dexp _null_ _null_ _null_ ) +insert OID = 234 ( dlog1 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ dlog1 _null_ _null_ _null_ ) +insert OID = 235 ( float8 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "21" _null_ _null_ _null_ _null_ i2tod _null_ _null_ _null_ ) +insert OID = 236 ( float4 11 10 12 1 0 0 0 f f f f t f i 1 0 700 "21" _null_ _null_ _null_ _null_ i2tof _null_ _null_ _null_ ) +insert OID = 237 ( int2 11 10 12 1 0 0 0 f f f f t f i 1 0 21 "701" _null_ _null_ _null_ _null_ dtoi2 _null_ _null_ _null_ ) +insert OID = 238 ( int2 11 10 12 1 0 0 0 f f f f t f i 1 0 21 "700" _null_ _null_ _null_ _null_ ftoi2 _null_ _null_ _null_ ) +insert OID = 239 ( line_distance 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "628 628" _null_ _null_ _null_ _null_ line_distance _null_ _null_ _null_ ) +insert OID = 240 ( abstimein 11 10 12 1 0 0 0 f f f f t f s 1 0 702 "2275" _null_ _null_ _null_ _null_ abstimein _null_ _null_ _null_ ) +insert OID = 241 ( abstimeout 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "702" _null_ _null_ _null_ _null_ abstimeout _null_ _null_ _null_ ) +insert OID = 242 ( reltimein 11 10 12 1 0 0 0 f f f f t f s 1 0 703 "2275" _null_ _null_ _null_ _null_ reltimein _null_ _null_ _null_ ) +insert OID = 243 ( reltimeout 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "703" _null_ _null_ _null_ _null_ reltimeout _null_ _null_ _null_ ) +insert OID = 244 ( timepl 11 10 12 1 0 0 0 f f f f t f i 2 0 702 "702 703" _null_ _null_ _null_ _null_ timepl _null_ _null_ _null_ ) +insert OID = 245 ( timemi 11 10 12 1 0 0 0 f f f f t f i 2 0 702 "702 703" _null_ _null_ _null_ _null_ timemi _null_ _null_ _null_ ) +insert OID = 246 ( tintervalin 11 10 12 1 0 0 0 f f f f t f s 1 0 704 "2275" _null_ _null_ _null_ _null_ tintervalin _null_ _null_ _null_ ) +insert OID = 247 ( tintervalout 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "704" _null_ _null_ _null_ _null_ tintervalout _null_ _null_ _null_ ) +insert OID = 248 ( intinterval 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "702 704" _null_ _null_ _null_ _null_ intinterval _null_ _null_ _null_ ) +insert OID = 249 ( tintervalrel 11 10 12 1 0 0 0 f f f f t f i 1 0 703 "704" _null_ _null_ _null_ _null_ tintervalrel _null_ _null_ _null_ ) +insert OID = 250 ( timenow 11 10 12 1 0 0 0 f f f f t f s 0 0 702 "" _null_ _null_ _null_ _null_ timenow _null_ _null_ _null_ ) +insert OID = 251 ( abstimeeq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "702 702" _null_ _null_ _null_ _null_ abstimeeq _null_ _null_ _null_ ) +insert OID = 252 ( abstimene 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "702 702" _null_ _null_ _null_ _null_ abstimene _null_ _null_ _null_ ) +insert OID = 253 ( abstimelt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "702 702" _null_ _null_ _null_ _null_ abstimelt _null_ _null_ _null_ ) +insert OID = 254 ( abstimegt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "702 702" _null_ _null_ _null_ _null_ abstimegt _null_ _null_ _null_ ) +insert OID = 255 ( abstimele 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "702 702" _null_ _null_ _null_ _null_ abstimele _null_ _null_ _null_ ) +insert OID = 256 ( abstimege 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "702 702" _null_ _null_ _null_ _null_ abstimege _null_ _null_ _null_ ) +insert OID = 257 ( reltimeeq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "703 703" _null_ _null_ _null_ _null_ reltimeeq _null_ _null_ _null_ ) +insert OID = 258 ( reltimene 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "703 703" _null_ _null_ _null_ _null_ reltimene _null_ _null_ _null_ ) +insert OID = 259 ( reltimelt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "703 703" _null_ _null_ _null_ _null_ reltimelt _null_ _null_ _null_ ) +insert OID = 260 ( reltimegt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "703 703" _null_ _null_ _null_ _null_ reltimegt _null_ _null_ _null_ ) +insert OID = 261 ( reltimele 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "703 703" _null_ _null_ _null_ _null_ reltimele _null_ _null_ _null_ ) +insert OID = 262 ( reltimege 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "703 703" _null_ _null_ _null_ _null_ reltimege _null_ _null_ _null_ ) +insert OID = 263 ( tintervalsame 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "704 704" _null_ _null_ _null_ _null_ tintervalsame _null_ _null_ _null_ ) +insert OID = 264 ( tintervalct 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "704 704" _null_ _null_ _null_ _null_ tintervalct _null_ _null_ _null_ ) +insert OID = 265 ( tintervalov 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "704 704" _null_ _null_ _null_ _null_ tintervalov _null_ _null_ _null_ ) +insert OID = 266 ( tintervalleneq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "704 703" _null_ _null_ _null_ _null_ tintervalleneq _null_ _null_ _null_ ) +insert OID = 267 ( tintervallenne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "704 703" _null_ _null_ _null_ _null_ tintervallenne _null_ _null_ _null_ ) +insert OID = 268 ( tintervallenlt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "704 703" _null_ _null_ _null_ _null_ tintervallenlt _null_ _null_ _null_ ) +insert OID = 269 ( tintervallengt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "704 703" _null_ _null_ _null_ _null_ tintervallengt _null_ _null_ _null_ ) +insert OID = 270 ( tintervallenle 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "704 703" _null_ _null_ _null_ _null_ tintervallenle _null_ _null_ _null_ ) +insert OID = 271 ( tintervallenge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "704 703" _null_ _null_ _null_ _null_ tintervallenge _null_ _null_ _null_ ) +insert OID = 272 ( tintervalstart 11 10 12 1 0 0 0 f f f f t f i 1 0 702 "704" _null_ _null_ _null_ _null_ tintervalstart _null_ _null_ _null_ ) +insert OID = 273 ( tintervalend 11 10 12 1 0 0 0 f f f f t f i 1 0 702 "704" _null_ _null_ _null_ _null_ tintervalend _null_ _null_ _null_ ) +insert OID = 274 ( timeofday 11 10 12 1 0 0 0 f f f f t f v 0 0 25 "" _null_ _null_ _null_ _null_ timeofday _null_ _null_ _null_ ) +insert OID = 275 ( isfinite 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "702" _null_ _null_ _null_ _null_ abstime_finite _null_ _null_ _null_ ) +insert OID = 277 ( inter_sl 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "601 628" _null_ _null_ _null_ _null_ inter_sl _null_ _null_ _null_ ) +insert OID = 278 ( inter_lb 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "628 603" _null_ _null_ _null_ _null_ inter_lb _null_ _null_ _null_ ) +insert OID = 279 ( float48mul 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "700 701" _null_ _null_ _null_ _null_ float48mul _null_ _null_ _null_ ) +insert OID = 280 ( float48div 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "700 701" _null_ _null_ _null_ _null_ float48div _null_ _null_ _null_ ) +insert OID = 281 ( float48pl 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "700 701" _null_ _null_ _null_ _null_ float48pl _null_ _null_ _null_ ) +insert OID = 282 ( float48mi 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "700 701" _null_ _null_ _null_ _null_ float48mi _null_ _null_ _null_ ) +insert OID = 283 ( float84mul 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "701 700" _null_ _null_ _null_ _null_ float84mul _null_ _null_ _null_ ) +insert OID = 284 ( float84div 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "701 700" _null_ _null_ _null_ _null_ float84div _null_ _null_ _null_ ) +insert OID = 285 ( float84pl 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "701 700" _null_ _null_ _null_ _null_ float84pl _null_ _null_ _null_ ) +insert OID = 286 ( float84mi 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "701 700" _null_ _null_ _null_ _null_ float84mi _null_ _null_ _null_ ) +insert OID = 287 ( float4eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "700 700" _null_ _null_ _null_ _null_ float4eq _null_ _null_ _null_ ) +insert OID = 288 ( float4ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "700 700" _null_ _null_ _null_ _null_ float4ne _null_ _null_ _null_ ) +insert OID = 289 ( float4lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "700 700" _null_ _null_ _null_ _null_ float4lt _null_ _null_ _null_ ) +insert OID = 290 ( float4le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "700 700" _null_ _null_ _null_ _null_ float4le _null_ _null_ _null_ ) +insert OID = 291 ( float4gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "700 700" _null_ _null_ _null_ _null_ float4gt _null_ _null_ _null_ ) +insert OID = 292 ( float4ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "700 700" _null_ _null_ _null_ _null_ float4ge _null_ _null_ _null_ ) +insert OID = 293 ( float8eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "701 701" _null_ _null_ _null_ _null_ float8eq _null_ _null_ _null_ ) +insert OID = 294 ( float8ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "701 701" _null_ _null_ _null_ _null_ float8ne _null_ _null_ _null_ ) +insert OID = 295 ( float8lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "701 701" _null_ _null_ _null_ _null_ float8lt _null_ _null_ _null_ ) +insert OID = 296 ( float8le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "701 701" _null_ _null_ _null_ _null_ float8le _null_ _null_ _null_ ) +insert OID = 297 ( float8gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "701 701" _null_ _null_ _null_ _null_ float8gt _null_ _null_ _null_ ) +insert OID = 298 ( float8ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "701 701" _null_ _null_ _null_ _null_ float8ge _null_ _null_ _null_ ) +insert OID = 299 ( float48eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "700 701" _null_ _null_ _null_ _null_ float48eq _null_ _null_ _null_ ) +insert OID = 300 ( float48ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "700 701" _null_ _null_ _null_ _null_ float48ne _null_ _null_ _null_ ) +insert OID = 301 ( float48lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "700 701" _null_ _null_ _null_ _null_ float48lt _null_ _null_ _null_ ) +insert OID = 302 ( float48le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "700 701" _null_ _null_ _null_ _null_ float48le _null_ _null_ _null_ ) +insert OID = 303 ( float48gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "700 701" _null_ _null_ _null_ _null_ float48gt _null_ _null_ _null_ ) +insert OID = 304 ( float48ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "700 701" _null_ _null_ _null_ _null_ float48ge _null_ _null_ _null_ ) +insert OID = 305 ( float84eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "701 700" _null_ _null_ _null_ _null_ float84eq _null_ _null_ _null_ ) +insert OID = 306 ( float84ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "701 700" _null_ _null_ _null_ _null_ float84ne _null_ _null_ _null_ ) +insert OID = 307 ( float84lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "701 700" _null_ _null_ _null_ _null_ float84lt _null_ _null_ _null_ ) +insert OID = 308 ( float84le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "701 700" _null_ _null_ _null_ _null_ float84le _null_ _null_ _null_ ) +insert OID = 309 ( float84gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "701 700" _null_ _null_ _null_ _null_ float84gt _null_ _null_ _null_ ) +insert OID = 310 ( float84ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "701 700" _null_ _null_ _null_ _null_ float84ge _null_ _null_ _null_ ) +insert OID = 320 ( width_bucket 11 10 12 1 0 0 0 f f f f t f i 4 0 23 "701 701 701 23" _null_ _null_ _null_ _null_ width_bucket_float8 _null_ _null_ _null_ ) +insert OID = 311 ( float8 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "700" _null_ _null_ _null_ _null_ ftod _null_ _null_ _null_ ) +insert OID = 312 ( float4 11 10 12 1 0 0 0 f f f f t f i 1 0 700 "701" _null_ _null_ _null_ _null_ dtof _null_ _null_ _null_ ) +insert OID = 313 ( int4 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "21" _null_ _null_ _null_ _null_ i2toi4 _null_ _null_ _null_ ) +insert OID = 314 ( int2 11 10 12 1 0 0 0 f f f f t f i 1 0 21 "23" _null_ _null_ _null_ _null_ i4toi2 _null_ _null_ _null_ ) +insert OID = 315 ( int2vectoreq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "22 22" _null_ _null_ _null_ _null_ int2vectoreq _null_ _null_ _null_ ) +insert OID = 316 ( float8 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "23" _null_ _null_ _null_ _null_ i4tod _null_ _null_ _null_ ) +insert OID = 317 ( int4 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "701" _null_ _null_ _null_ _null_ dtoi4 _null_ _null_ _null_ ) +insert OID = 318 ( float4 11 10 12 1 0 0 0 f f f f t f i 1 0 700 "23" _null_ _null_ _null_ _null_ i4tof _null_ _null_ _null_ ) +insert OID = 319 ( int4 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "700" _null_ _null_ _null_ _null_ ftoi4 _null_ _null_ _null_ ) +insert OID = 330 ( btgettuple 11 10 12 1 0 0 0 f f f f t f v 2 0 16 "2281 2281" _null_ _null_ _null_ _null_ btgettuple _null_ _null_ _null_ ) +insert OID = 636 ( btgetbitmap 11 10 12 1 0 0 0 f f f f t f v 2 0 20 "2281 2281" _null_ _null_ _null_ _null_ btgetbitmap _null_ _null_ _null_ ) +insert OID = 331 ( btinsert 11 10 12 1 0 0 0 f f f f t f v 6 0 16 "2281 2281 2281 2281 2281 2281" _null_ _null_ _null_ _null_ btinsert _null_ _null_ _null_ ) +insert OID = 333 ( btbeginscan 11 10 12 1 0 0 0 f f f f t f v 3 0 2281 "2281 2281 2281" _null_ _null_ _null_ _null_ btbeginscan _null_ _null_ _null_ ) +insert OID = 334 ( btrescan 11 10 12 1 0 0 0 f f f f t f v 5 0 2278 "2281 2281 2281 2281 2281" _null_ _null_ _null_ _null_ btrescan _null_ _null_ _null_ ) +insert OID = 335 ( btendscan 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "2281" _null_ _null_ _null_ _null_ btendscan _null_ _null_ _null_ ) +insert OID = 336 ( btmarkpos 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "2281" _null_ _null_ _null_ _null_ btmarkpos _null_ _null_ _null_ ) +insert OID = 337 ( btrestrpos 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "2281" _null_ _null_ _null_ _null_ btrestrpos _null_ _null_ _null_ ) +insert OID = 338 ( btbuild 11 10 12 1 0 0 0 f f f f t f v 3 0 2281 "2281 2281 2281" _null_ _null_ _null_ _null_ btbuild _null_ _null_ _null_ ) +insert OID = 328 ( btbuildempty 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "2281" _null_ _null_ _null_ _null_ btbuildempty _null_ _null_ _null_ ) +insert OID = 332 ( btbulkdelete 11 10 12 1 0 0 0 f f f f t f v 4 0 2281 "2281 2281 2281 2281" _null_ _null_ _null_ _null_ btbulkdelete _null_ _null_ _null_ ) +insert OID = 972 ( btvacuumcleanup 11 10 12 1 0 0 0 f f f f t f v 2 0 2281 "2281 2281" _null_ _null_ _null_ _null_ btvacuumcleanup _null_ _null_ _null_ ) +insert OID = 276 ( btcanreturn 11 10 12 1 0 0 0 f f f f t f s 1 0 16 "2281" _null_ _null_ _null_ _null_ btcanreturn _null_ _null_ _null_ ) +insert OID = 1268 ( btcostestimate 11 10 12 1 0 0 0 f f f f t f v 7 0 2278 "2281 2281 2281 2281 2281 2281 2281" _null_ _null_ _null_ _null_ btcostestimate _null_ _null_ _null_ ) +insert OID = 2785 ( btoptions 11 10 12 1 0 0 0 f f f f t f s 2 0 17 "1009 16" _null_ _null_ _null_ _null_ btoptions _null_ _null_ _null_ ) +insert OID = 339 ( poly_same 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "604 604" _null_ _null_ _null_ _null_ poly_same _null_ _null_ _null_ ) +insert OID = 340 ( poly_contain 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "604 604" _null_ _null_ _null_ _null_ poly_contain _null_ _null_ _null_ ) +insert OID = 341 ( poly_left 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "604 604" _null_ _null_ _null_ _null_ poly_left _null_ _null_ _null_ ) +insert OID = 342 ( poly_overleft 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "604 604" _null_ _null_ _null_ _null_ poly_overleft _null_ _null_ _null_ ) +insert OID = 343 ( poly_overright 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "604 604" _null_ _null_ _null_ _null_ poly_overright _null_ _null_ _null_ ) +insert OID = 344 ( poly_right 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "604 604" _null_ _null_ _null_ _null_ poly_right _null_ _null_ _null_ ) +insert OID = 345 ( poly_contained 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "604 604" _null_ _null_ _null_ _null_ poly_contained _null_ _null_ _null_ ) +insert OID = 346 ( poly_overlap 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "604 604" _null_ _null_ _null_ _null_ poly_overlap _null_ _null_ _null_ ) +insert OID = 347 ( poly_in 11 10 12 1 0 0 0 f f f f t f i 1 0 604 "2275" _null_ _null_ _null_ _null_ poly_in _null_ _null_ _null_ ) +insert OID = 348 ( poly_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "604" _null_ _null_ _null_ _null_ poly_out _null_ _null_ _null_ ) +insert OID = 350 ( btint2cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "21 21" _null_ _null_ _null_ _null_ btint2cmp _null_ _null_ _null_ ) +insert OID = 3129 ( btint2sortsupport 11 10 12 1 0 0 0 f f f f t f i 1 0 2278 "2281" _null_ _null_ _null_ _null_ btint2sortsupport _null_ _null_ _null_ ) +insert OID = 351 ( btint4cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "23 23" _null_ _null_ _null_ _null_ btint4cmp _null_ _null_ _null_ ) +insert OID = 3130 ( btint4sortsupport 11 10 12 1 0 0 0 f f f f t f i 1 0 2278 "2281" _null_ _null_ _null_ _null_ btint4sortsupport _null_ _null_ _null_ ) +insert OID = 842 ( btint8cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "20 20" _null_ _null_ _null_ _null_ btint8cmp _null_ _null_ _null_ ) +insert OID = 3131 ( btint8sortsupport 11 10 12 1 0 0 0 f f f f t f i 1 0 2278 "2281" _null_ _null_ _null_ _null_ btint8sortsupport _null_ _null_ _null_ ) +insert OID = 354 ( btfloat4cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "700 700" _null_ _null_ _null_ _null_ btfloat4cmp _null_ _null_ _null_ ) +insert OID = 3132 ( btfloat4sortsupport 11 10 12 1 0 0 0 f f f f t f i 1 0 2278 "2281" _null_ _null_ _null_ _null_ btfloat4sortsupport _null_ _null_ _null_ ) +insert OID = 355 ( btfloat8cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "701 701" _null_ _null_ _null_ _null_ btfloat8cmp _null_ _null_ _null_ ) +insert OID = 3133 ( btfloat8sortsupport 11 10 12 1 0 0 0 f f f f t f i 1 0 2278 "2281" _null_ _null_ _null_ _null_ btfloat8sortsupport _null_ _null_ _null_ ) +insert OID = 356 ( btoidcmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "26 26" _null_ _null_ _null_ _null_ btoidcmp _null_ _null_ _null_ ) +insert OID = 3134 ( btoidsortsupport 11 10 12 1 0 0 0 f f f f t f i 1 0 2278 "2281" _null_ _null_ _null_ _null_ btoidsortsupport _null_ _null_ _null_ ) +insert OID = 404 ( btoidvectorcmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "30 30" _null_ _null_ _null_ _null_ btoidvectorcmp _null_ _null_ _null_ ) +insert OID = 357 ( btabstimecmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "702 702" _null_ _null_ _null_ _null_ btabstimecmp _null_ _null_ _null_ ) +insert OID = 358 ( btcharcmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "18 18" _null_ _null_ _null_ _null_ btcharcmp _null_ _null_ _null_ ) +insert OID = 359 ( btnamecmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "19 19" _null_ _null_ _null_ _null_ btnamecmp _null_ _null_ _null_ ) +insert OID = 3135 ( btnamesortsupport 11 10 12 1 0 0 0 f f f f t f i 1 0 2278 "2281" _null_ _null_ _null_ _null_ btnamesortsupport _null_ _null_ _null_ ) +insert OID = 360 ( bttextcmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "25 25" _null_ _null_ _null_ _null_ bttextcmp _null_ _null_ _null_ ) +insert OID = 377 ( cash_cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "790 790" _null_ _null_ _null_ _null_ cash_cmp _null_ _null_ _null_ ) +insert OID = 380 ( btreltimecmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "703 703" _null_ _null_ _null_ _null_ btreltimecmp _null_ _null_ _null_ ) +insert OID = 381 ( bttintervalcmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "704 704" _null_ _null_ _null_ _null_ bttintervalcmp _null_ _null_ _null_ ) +insert OID = 382 ( btarraycmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "2277 2277" _null_ _null_ _null_ _null_ btarraycmp _null_ _null_ _null_ ) +insert OID = 361 ( lseg_distance 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "601 601" _null_ _null_ _null_ _null_ lseg_distance _null_ _null_ _null_ ) +insert OID = 362 ( lseg_interpt 11 10 12 1 0 0 0 f f f f t f i 2 0 600 "601 601" _null_ _null_ _null_ _null_ lseg_interpt _null_ _null_ _null_ ) +insert OID = 363 ( dist_ps 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "600 601" _null_ _null_ _null_ _null_ dist_ps _null_ _null_ _null_ ) +insert OID = 364 ( dist_pb 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "600 603" _null_ _null_ _null_ _null_ dist_pb _null_ _null_ _null_ ) +insert OID = 365 ( dist_sb 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "601 603" _null_ _null_ _null_ _null_ dist_sb _null_ _null_ _null_ ) +insert OID = 366 ( close_ps 11 10 12 1 0 0 0 f f f f t f i 2 0 600 "600 601" _null_ _null_ _null_ _null_ close_ps _null_ _null_ _null_ ) +insert OID = 367 ( close_pb 11 10 12 1 0 0 0 f f f f t f i 2 0 600 "600 603" _null_ _null_ _null_ _null_ close_pb _null_ _null_ _null_ ) +insert OID = 368 ( close_sb 11 10 12 1 0 0 0 f f f f t f i 2 0 600 "601 603" _null_ _null_ _null_ _null_ close_sb _null_ _null_ _null_ ) +insert OID = 369 ( on_ps 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "600 601" _null_ _null_ _null_ _null_ on_ps _null_ _null_ _null_ ) +insert OID = 370 ( path_distance 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "602 602" _null_ _null_ _null_ _null_ path_distance _null_ _null_ _null_ ) +insert OID = 371 ( dist_ppath 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "600 602" _null_ _null_ _null_ _null_ dist_ppath _null_ _null_ _null_ ) +insert OID = 372 ( on_sb 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "601 603" _null_ _null_ _null_ _null_ on_sb _null_ _null_ _null_ ) +insert OID = 373 ( inter_sb 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "601 603" _null_ _null_ _null_ _null_ inter_sb _null_ _null_ _null_ ) +insert OID = 401 ( text 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "1042" _null_ _null_ _null_ _null_ rtrim1 _null_ _null_ _null_ ) +insert OID = 406 ( text 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "19" _null_ _null_ _null_ _null_ name_text _null_ _null_ _null_ ) +insert OID = 407 ( name 11 10 12 1 0 0 0 f f f f t f i 1 0 19 "25" _null_ _null_ _null_ _null_ text_name _null_ _null_ _null_ ) +insert OID = 408 ( bpchar 11 10 12 1 0 0 0 f f f f t f i 1 0 1042 "19" _null_ _null_ _null_ _null_ name_bpchar _null_ _null_ _null_ ) +insert OID = 409 ( name 11 10 12 1 0 0 0 f f f f t f i 1 0 19 "1042" _null_ _null_ _null_ _null_ bpchar_name _null_ _null_ _null_ ) +insert OID = 440 ( hashgettuple 11 10 12 1 0 0 0 f f f f t f v 2 0 16 "2281 2281" _null_ _null_ _null_ _null_ hashgettuple _null_ _null_ _null_ ) +insert OID = 637 ( hashgetbitmap 11 10 12 1 0 0 0 f f f f t f v 2 0 20 "2281 2281" _null_ _null_ _null_ _null_ hashgetbitmap _null_ _null_ _null_ ) +insert OID = 441 ( hashinsert 11 10 12 1 0 0 0 f f f f t f v 6 0 16 "2281 2281 2281 2281 2281 2281" _null_ _null_ _null_ _null_ hashinsert _null_ _null_ _null_ ) +insert OID = 443 ( hashbeginscan 11 10 12 1 0 0 0 f f f f t f v 3 0 2281 "2281 2281 2281" _null_ _null_ _null_ _null_ hashbeginscan _null_ _null_ _null_ ) +insert OID = 444 ( hashrescan 11 10 12 1 0 0 0 f f f f t f v 5 0 2278 "2281 2281 2281 2281 2281" _null_ _null_ _null_ _null_ hashrescan _null_ _null_ _null_ ) +insert OID = 445 ( hashendscan 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "2281" _null_ _null_ _null_ _null_ hashendscan _null_ _null_ _null_ ) +insert OID = 446 ( hashmarkpos 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "2281" _null_ _null_ _null_ _null_ hashmarkpos _null_ _null_ _null_ ) +insert OID = 447 ( hashrestrpos 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "2281" _null_ _null_ _null_ _null_ hashrestrpos _null_ _null_ _null_ ) +insert OID = 448 ( hashbuild 11 10 12 1 0 0 0 f f f f t f v 3 0 2281 "2281 2281 2281" _null_ _null_ _null_ _null_ hashbuild _null_ _null_ _null_ ) +insert OID = 327 ( hashbuildempty 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "2281" _null_ _null_ _null_ _null_ hashbuildempty _null_ _null_ _null_ ) +insert OID = 442 ( hashbulkdelete 11 10 12 1 0 0 0 f f f f t f v 4 0 2281 "2281 2281 2281 2281" _null_ _null_ _null_ _null_ hashbulkdelete _null_ _null_ _null_ ) +insert OID = 425 ( hashvacuumcleanup 11 10 12 1 0 0 0 f f f f t f v 2 0 2281 "2281 2281" _null_ _null_ _null_ _null_ hashvacuumcleanup _null_ _null_ _null_ ) +insert OID = 438 ( hashcostestimate 11 10 12 1 0 0 0 f f f f t f v 7 0 2278 "2281 2281 2281 2281 2281 2281 2281" _null_ _null_ _null_ _null_ hashcostestimate _null_ _null_ _null_ ) +insert OID = 2786 ( hashoptions 11 10 12 1 0 0 0 f f f f t f s 2 0 17 "1009 16" _null_ _null_ _null_ _null_ hashoptions _null_ _null_ _null_ ) +insert OID = 449 ( hashint2 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "21" _null_ _null_ _null_ _null_ hashint2 _null_ _null_ _null_ ) +insert OID = 450 ( hashint4 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "23" _null_ _null_ _null_ _null_ hashint4 _null_ _null_ _null_ ) +insert OID = 949 ( hashint8 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "20" _null_ _null_ _null_ _null_ hashint8 _null_ _null_ _null_ ) +insert OID = 451 ( hashfloat4 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "700" _null_ _null_ _null_ _null_ hashfloat4 _null_ _null_ _null_ ) +insert OID = 452 ( hashfloat8 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "701" _null_ _null_ _null_ _null_ hashfloat8 _null_ _null_ _null_ ) +insert OID = 453 ( hashoid 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "26" _null_ _null_ _null_ _null_ hashoid _null_ _null_ _null_ ) +insert OID = 454 ( hashchar 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "18" _null_ _null_ _null_ _null_ hashchar _null_ _null_ _null_ ) +insert OID = 455 ( hashname 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "19" _null_ _null_ _null_ _null_ hashname _null_ _null_ _null_ ) +insert OID = 400 ( hashtext 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "25" _null_ _null_ _null_ _null_ hashtext _null_ _null_ _null_ ) +insert OID = 456 ( hashvarlena 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "2281" _null_ _null_ _null_ _null_ hashvarlena _null_ _null_ _null_ ) +insert OID = 457 ( hashoidvector 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "30" _null_ _null_ _null_ _null_ hashoidvector _null_ _null_ _null_ ) +insert OID = 329 ( hash_aclitem 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1033" _null_ _null_ _null_ _null_ hash_aclitem _null_ _null_ _null_ ) +insert OID = 398 ( hashint2vector 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "22" _null_ _null_ _null_ _null_ hashint2vector _null_ _null_ _null_ ) +insert OID = 399 ( hashmacaddr 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "829" _null_ _null_ _null_ _null_ hashmacaddr _null_ _null_ _null_ ) +insert OID = 422 ( hashinet 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "869" _null_ _null_ _null_ _null_ hashinet _null_ _null_ _null_ ) +insert OID = 432 ( hash_numeric 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1700" _null_ _null_ _null_ _null_ hash_numeric _null_ _null_ _null_ ) +insert OID = 458 ( text_larger 11 10 12 1 0 0 0 f f f f t f i 2 0 25 "25 25" _null_ _null_ _null_ _null_ text_larger _null_ _null_ _null_ ) +insert OID = 459 ( text_smaller 11 10 12 1 0 0 0 f f f f t f i 2 0 25 "25 25" _null_ _null_ _null_ _null_ text_smaller _null_ _null_ _null_ ) +insert OID = 460 ( int8in 11 10 12 1 0 0 0 f f f f t f i 1 0 20 "2275" _null_ _null_ _null_ _null_ int8in _null_ _null_ _null_ ) +insert OID = 461 ( int8out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "20" _null_ _null_ _null_ _null_ int8out _null_ _null_ _null_ ) +insert OID = 462 ( int8um 11 10 12 1 0 0 0 f f f f t f i 1 0 20 "20" _null_ _null_ _null_ _null_ int8um _null_ _null_ _null_ ) +insert OID = 463 ( int8pl 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "20 20" _null_ _null_ _null_ _null_ int8pl _null_ _null_ _null_ ) +insert OID = 464 ( int8mi 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "20 20" _null_ _null_ _null_ _null_ int8mi _null_ _null_ _null_ ) +insert OID = 465 ( int8mul 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "20 20" _null_ _null_ _null_ _null_ int8mul _null_ _null_ _null_ ) +insert OID = 466 ( int8div 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "20 20" _null_ _null_ _null_ _null_ int8div _null_ _null_ _null_ ) +insert OID = 467 ( int8eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "20 20" _null_ _null_ _null_ _null_ int8eq _null_ _null_ _null_ ) +insert OID = 468 ( int8ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "20 20" _null_ _null_ _null_ _null_ int8ne _null_ _null_ _null_ ) +insert OID = 469 ( int8lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "20 20" _null_ _null_ _null_ _null_ int8lt _null_ _null_ _null_ ) +insert OID = 470 ( int8gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "20 20" _null_ _null_ _null_ _null_ int8gt _null_ _null_ _null_ ) +insert OID = 471 ( int8le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "20 20" _null_ _null_ _null_ _null_ int8le _null_ _null_ _null_ ) +insert OID = 472 ( int8ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "20 20" _null_ _null_ _null_ _null_ int8ge _null_ _null_ _null_ ) +insert OID = 474 ( int84eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "20 23" _null_ _null_ _null_ _null_ int84eq _null_ _null_ _null_ ) +insert OID = 475 ( int84ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "20 23" _null_ _null_ _null_ _null_ int84ne _null_ _null_ _null_ ) +insert OID = 476 ( int84lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "20 23" _null_ _null_ _null_ _null_ int84lt _null_ _null_ _null_ ) +insert OID = 477 ( int84gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "20 23" _null_ _null_ _null_ _null_ int84gt _null_ _null_ _null_ ) +insert OID = 478 ( int84le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "20 23" _null_ _null_ _null_ _null_ int84le _null_ _null_ _null_ ) +insert OID = 479 ( int84ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "20 23" _null_ _null_ _null_ _null_ int84ge _null_ _null_ _null_ ) +insert OID = 480 ( int4 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "20" _null_ _null_ _null_ _null_ int84 _null_ _null_ _null_ ) +insert OID = 481 ( int8 11 10 12 1 0 0 0 f f f f t f i 1 0 20 "23" _null_ _null_ _null_ _null_ int48 _null_ _null_ _null_ ) +insert OID = 482 ( float8 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "20" _null_ _null_ _null_ _null_ i8tod _null_ _null_ _null_ ) +insert OID = 483 ( int8 11 10 12 1 0 0 0 f f f f t f i 1 0 20 "701" _null_ _null_ _null_ _null_ dtoi8 _null_ _null_ _null_ ) +insert OID = 626 ( hash_array 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "2277" _null_ _null_ _null_ _null_ hash_array _null_ _null_ _null_ ) +insert OID = 652 ( float4 11 10 12 1 0 0 0 f f f f t f i 1 0 700 "20" _null_ _null_ _null_ _null_ i8tof _null_ _null_ _null_ ) +insert OID = 653 ( int8 11 10 12 1 0 0 0 f f f f t f i 1 0 20 "700" _null_ _null_ _null_ _null_ ftoi8 _null_ _null_ _null_ ) +insert OID = 714 ( int2 11 10 12 1 0 0 0 f f f f t f i 1 0 21 "20" _null_ _null_ _null_ _null_ int82 _null_ _null_ _null_ ) +insert OID = 754 ( int8 11 10 12 1 0 0 0 f f f f t f i 1 0 20 "21" _null_ _null_ _null_ _null_ int28 _null_ _null_ _null_ ) +insert OID = 655 ( namelt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "19 19" _null_ _null_ _null_ _null_ namelt _null_ _null_ _null_ ) +insert OID = 656 ( namele 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "19 19" _null_ _null_ _null_ _null_ namele _null_ _null_ _null_ ) +insert OID = 657 ( namegt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "19 19" _null_ _null_ _null_ _null_ namegt _null_ _null_ _null_ ) +insert OID = 658 ( namege 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "19 19" _null_ _null_ _null_ _null_ namege _null_ _null_ _null_ ) +insert OID = 659 ( namene 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "19 19" _null_ _null_ _null_ _null_ namene _null_ _null_ _null_ ) +insert OID = 668 ( bpchar 11 10 12 1 0 0 0 f f f f t f i 3 0 1042 "1042 23 16" _null_ _null_ _null_ _null_ bpchar _null_ _null_ _null_ ) +insert OID = 3097 ( varchar_transform 11 10 12 1 0 0 0 f f f f t f i 1 0 2281 "2281" _null_ _null_ _null_ _null_ varchar_transform _null_ _null_ _null_ ) +insert OID = 669 ( varchar 11 10 12 1 0 0 varchar_transform f f f f t f i 3 0 1043 "1043 23 16" _null_ _null_ _null_ _null_ varchar _null_ _null_ _null_ ) +insert OID = 676 ( mktinterval 11 10 12 1 0 0 0 f f f f t f i 2 0 704 "702 702" _null_ _null_ _null_ _null_ mktinterval _null_ _null_ _null_ ) +insert OID = 619 ( oidvectorne 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "30 30" _null_ _null_ _null_ _null_ oidvectorne _null_ _null_ _null_ ) +insert OID = 677 ( oidvectorlt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "30 30" _null_ _null_ _null_ _null_ oidvectorlt _null_ _null_ _null_ ) +insert OID = 678 ( oidvectorle 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "30 30" _null_ _null_ _null_ _null_ oidvectorle _null_ _null_ _null_ ) +insert OID = 679 ( oidvectoreq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "30 30" _null_ _null_ _null_ _null_ oidvectoreq _null_ _null_ _null_ ) +insert OID = 680 ( oidvectorge 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "30 30" _null_ _null_ _null_ _null_ oidvectorge _null_ _null_ _null_ ) +insert OID = 681 ( oidvectorgt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "30 30" _null_ _null_ _null_ _null_ oidvectorgt _null_ _null_ _null_ ) +insert OID = 710 ( getpgusername 11 10 12 1 0 0 0 f f f f t f s 0 0 19 "" _null_ _null_ _null_ _null_ current_user _null_ _null_ _null_ ) +insert OID = 716 ( oidlt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "26 26" _null_ _null_ _null_ _null_ oidlt _null_ _null_ _null_ ) +insert OID = 717 ( oidle 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "26 26" _null_ _null_ _null_ _null_ oidle _null_ _null_ _null_ ) +insert OID = 720 ( octet_length 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "17" _null_ _null_ _null_ _null_ byteaoctetlen _null_ _null_ _null_ ) +insert OID = 721 ( get_byte 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "17 23" _null_ _null_ _null_ _null_ byteaGetByte _null_ _null_ _null_ ) +insert OID = 722 ( set_byte 11 10 12 1 0 0 0 f f f f t f i 3 0 17 "17 23 23" _null_ _null_ _null_ _null_ byteaSetByte _null_ _null_ _null_ ) +insert OID = 723 ( get_bit 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "17 23" _null_ _null_ _null_ _null_ byteaGetBit _null_ _null_ _null_ ) +insert OID = 724 ( set_bit 11 10 12 1 0 0 0 f f f f t f i 3 0 17 "17 23 23" _null_ _null_ _null_ _null_ byteaSetBit _null_ _null_ _null_ ) +insert OID = 749 ( overlay 11 10 12 1 0 0 0 f f f f t f i 4 0 17 "17 17 23 23" _null_ _null_ _null_ _null_ byteaoverlay _null_ _null_ _null_ ) +insert OID = 752 ( overlay 11 10 12 1 0 0 0 f f f f t f i 3 0 17 "17 17 23" _null_ _null_ _null_ _null_ byteaoverlay_no_len _null_ _null_ _null_ ) +insert OID = 725 ( dist_pl 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "600 628" _null_ _null_ _null_ _null_ dist_pl _null_ _null_ _null_ ) +insert OID = 726 ( dist_lb 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "628 603" _null_ _null_ _null_ _null_ dist_lb _null_ _null_ _null_ ) +insert OID = 727 ( dist_sl 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "601 628" _null_ _null_ _null_ _null_ dist_sl _null_ _null_ _null_ ) +insert OID = 728 ( dist_cpoly 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "718 604" _null_ _null_ _null_ _null_ dist_cpoly _null_ _null_ _null_ ) +insert OID = 729 ( poly_distance 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "604 604" _null_ _null_ _null_ _null_ poly_distance _null_ _null_ _null_ ) +insert OID = 740 ( text_lt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "25 25" _null_ _null_ _null_ _null_ text_lt _null_ _null_ _null_ ) +insert OID = 741 ( text_le 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "25 25" _null_ _null_ _null_ _null_ text_le _null_ _null_ _null_ ) +insert OID = 742 ( text_gt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "25 25" _null_ _null_ _null_ _null_ text_gt _null_ _null_ _null_ ) +insert OID = 743 ( text_ge 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "25 25" _null_ _null_ _null_ _null_ text_ge _null_ _null_ _null_ ) +insert OID = 745 ( current_user 11 10 12 1 0 0 0 f f f f t f s 0 0 19 "" _null_ _null_ _null_ _null_ current_user _null_ _null_ _null_ ) +insert OID = 746 ( session_user 11 10 12 1 0 0 0 f f f f t f s 0 0 19 "" _null_ _null_ _null_ _null_ session_user _null_ _null_ _null_ ) +insert OID = 744 ( array_eq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "2277 2277" _null_ _null_ _null_ _null_ array_eq _null_ _null_ _null_ ) +insert OID = 390 ( array_ne 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "2277 2277" _null_ _null_ _null_ _null_ array_ne _null_ _null_ _null_ ) +insert OID = 391 ( array_lt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "2277 2277" _null_ _null_ _null_ _null_ array_lt _null_ _null_ _null_ ) +insert OID = 392 ( array_gt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "2277 2277" _null_ _null_ _null_ _null_ array_gt _null_ _null_ _null_ ) +insert OID = 393 ( array_le 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "2277 2277" _null_ _null_ _null_ _null_ array_le _null_ _null_ _null_ ) +insert OID = 396 ( array_ge 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "2277 2277" _null_ _null_ _null_ _null_ array_ge _null_ _null_ _null_ ) +insert OID = 747 ( array_dims 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "2277" _null_ _null_ _null_ _null_ array_dims _null_ _null_ _null_ ) +insert OID = 748 ( array_ndims 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "2277" _null_ _null_ _null_ _null_ array_ndims _null_ _null_ _null_ ) +insert OID = 750 ( array_in 11 10 12 1 0 0 0 f f f f t f s 3 0 2277 "2275 26 23" _null_ _null_ _null_ _null_ array_in _null_ _null_ _null_ ) +insert OID = 751 ( array_out 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "2277" _null_ _null_ _null_ _null_ array_out _null_ _null_ _null_ ) +insert OID = 2091 ( array_lower 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "2277 23" _null_ _null_ _null_ _null_ array_lower _null_ _null_ _null_ ) +insert OID = 2092 ( array_upper 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "2277 23" _null_ _null_ _null_ _null_ array_upper _null_ _null_ _null_ ) +insert OID = 2176 ( array_length 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "2277 23" _null_ _null_ _null_ _null_ array_length _null_ _null_ _null_ ) +insert OID = 378 ( array_append 11 10 12 1 0 0 0 f f f f f f i 2 0 2277 "2277 2283" _null_ _null_ _null_ _null_ array_push _null_ _null_ _null_ ) +insert OID = 379 ( array_prepend 11 10 12 1 0 0 0 f f f f f f i 2 0 2277 "2283 2277" _null_ _null_ _null_ _null_ array_push _null_ _null_ _null_ ) +insert OID = 383 ( array_cat 11 10 12 1 0 0 0 f f f f f f i 2 0 2277 "2277 2277" _null_ _null_ _null_ _null_ array_cat _null_ _null_ _null_ ) +insert OID = 394 ( string_to_array 11 10 12 1 0 0 0 f f f f f f i 2 0 1009 "25 25" _null_ _null_ _null_ _null_ text_to_array _null_ _null_ _null_ ) +insert OID = 395 ( array_to_string 11 10 12 1 0 0 0 f f f f t f s 2 0 25 "2277 25" _null_ _null_ _null_ _null_ array_to_text _null_ _null_ _null_ ) +insert OID = 376 ( string_to_array 11 10 12 1 0 0 0 f f f f f f i 3 0 1009 "25 25 25" _null_ _null_ _null_ _null_ text_to_array_null _null_ _null_ _null_ ) +insert OID = 384 ( array_to_string 11 10 12 1 0 0 0 f f f f f f s 3 0 25 "2277 25 25" _null_ _null_ _null_ _null_ array_to_text_null _null_ _null_ _null_ ) +insert OID = 515 ( array_larger 11 10 12 1 0 0 0 f f f f t f i 2 0 2277 "2277 2277" _null_ _null_ _null_ _null_ array_larger _null_ _null_ _null_ ) +insert OID = 516 ( array_smaller 11 10 12 1 0 0 0 f f f f t f i 2 0 2277 "2277 2277" _null_ _null_ _null_ _null_ array_smaller _null_ _null_ _null_ ) +insert OID = 1191 ( generate_subscripts 11 10 12 1 1000 0 0 f f f f t t i 3 0 23 "2277 23 16" _null_ _null_ _null_ _null_ generate_subscripts _null_ _null_ _null_ ) +insert OID = 1192 ( generate_subscripts 11 10 12 1 1000 0 0 f f f f t t i 2 0 23 "2277 23" _null_ _null_ _null_ _null_ generate_subscripts_nodir _null_ _null_ _null_ ) +insert OID = 1193 ( array_fill 11 10 12 1 0 0 0 f f f f f f i 2 0 2277 "2283 1007" _null_ _null_ _null_ _null_ array_fill _null_ _null_ _null_ ) +insert OID = 1286 ( array_fill 11 10 12 1 0 0 0 f f f f f f i 3 0 2277 "2283 1007 1007" _null_ _null_ _null_ _null_ array_fill_with_lower_bounds _null_ _null_ _null_ ) +insert OID = 2331 ( unnest 11 10 12 1 100 0 0 f f f f t t i 1 0 2283 "2277" _null_ _null_ _null_ _null_ array_unnest _null_ _null_ _null_ ) +insert OID = 2333 ( array_agg_transfn 11 10 12 1 0 0 0 f f f f f f i 2 0 2281 "2281 2283" _null_ _null_ _null_ _null_ array_agg_transfn _null_ _null_ _null_ ) +insert OID = 2334 ( array_agg_finalfn 11 10 12 1 0 0 0 f f f f f f i 1 0 2277 "2281" _null_ _null_ _null_ _null_ array_agg_finalfn _null_ _null_ _null_ ) +insert OID = 2335 ( array_agg 11 10 12 1 0 0 0 t f f f f f i 1 0 2277 "2283" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 3816 ( array_typanalyze 11 10 12 1 0 0 0 f f f f t f s 1 0 16 "2281" _null_ _null_ _null_ _null_ array_typanalyze _null_ _null_ _null_ ) +insert OID = 3817 ( arraycontsel 11 10 12 1 0 0 0 f f f f t f s 4 0 701 "2281 26 2281 23" _null_ _null_ _null_ _null_ arraycontsel _null_ _null_ _null_ ) +insert OID = 3818 ( arraycontjoinsel 11 10 12 1 0 0 0 f f f f t f s 5 0 701 "2281 26 2281 21 2281" _null_ _null_ _null_ _null_ arraycontjoinsel _null_ _null_ _null_ ) +insert OID = 760 ( smgrin 11 10 12 1 0 0 0 f f f f t f s 1 0 210 "2275" _null_ _null_ _null_ _null_ smgrin _null_ _null_ _null_ ) +insert OID = 761 ( smgrout 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "210" _null_ _null_ _null_ _null_ smgrout _null_ _null_ _null_ ) +insert OID = 762 ( smgreq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "210 210" _null_ _null_ _null_ _null_ smgreq _null_ _null_ _null_ ) +insert OID = 763 ( smgrne 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "210 210" _null_ _null_ _null_ _null_ smgrne _null_ _null_ _null_ ) +insert OID = 764 ( lo_import 11 10 12 1 0 0 0 f f f f t f v 1 0 26 "25" _null_ _null_ _null_ _null_ lo_import _null_ _null_ _null_ ) +insert OID = 767 ( lo_import 11 10 12 1 0 0 0 f f f f t f v 2 0 26 "25 26" _null_ _null_ _null_ _null_ lo_import_with_oid _null_ _null_ _null_ ) +insert OID = 765 ( lo_export 11 10 12 1 0 0 0 f f f f t f v 2 0 23 "26 25" _null_ _null_ _null_ _null_ lo_export _null_ _null_ _null_ ) +insert OID = 766 ( int4inc 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "23" _null_ _null_ _null_ _null_ int4inc _null_ _null_ _null_ ) +insert OID = 768 ( int4larger 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "23 23" _null_ _null_ _null_ _null_ int4larger _null_ _null_ _null_ ) +insert OID = 769 ( int4smaller 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "23 23" _null_ _null_ _null_ _null_ int4smaller _null_ _null_ _null_ ) +insert OID = 770 ( int2larger 11 10 12 1 0 0 0 f f f f t f i 2 0 21 "21 21" _null_ _null_ _null_ _null_ int2larger _null_ _null_ _null_ ) +insert OID = 771 ( int2smaller 11 10 12 1 0 0 0 f f f f t f i 2 0 21 "21 21" _null_ _null_ _null_ _null_ int2smaller _null_ _null_ _null_ ) +insert OID = 774 ( gistgettuple 11 10 12 1 0 0 0 f f f f t f v 2 0 16 "2281 2281" _null_ _null_ _null_ _null_ gistgettuple _null_ _null_ _null_ ) +insert OID = 638 ( gistgetbitmap 11 10 12 1 0 0 0 f f f f t f v 2 0 20 "2281 2281" _null_ _null_ _null_ _null_ gistgetbitmap _null_ _null_ _null_ ) +insert OID = 775 ( gistinsert 11 10 12 1 0 0 0 f f f f t f v 6 0 16 "2281 2281 2281 2281 2281 2281" _null_ _null_ _null_ _null_ gistinsert _null_ _null_ _null_ ) +insert OID = 777 ( gistbeginscan 11 10 12 1 0 0 0 f f f f t f v 3 0 2281 "2281 2281 2281" _null_ _null_ _null_ _null_ gistbeginscan _null_ _null_ _null_ ) +insert OID = 778 ( gistrescan 11 10 12 1 0 0 0 f f f f t f v 5 0 2278 "2281 2281 2281 2281 2281" _null_ _null_ _null_ _null_ gistrescan _null_ _null_ _null_ ) +insert OID = 779 ( gistendscan 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "2281" _null_ _null_ _null_ _null_ gistendscan _null_ _null_ _null_ ) +insert OID = 780 ( gistmarkpos 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "2281" _null_ _null_ _null_ _null_ gistmarkpos _null_ _null_ _null_ ) +insert OID = 781 ( gistrestrpos 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "2281" _null_ _null_ _null_ _null_ gistrestrpos _null_ _null_ _null_ ) +insert OID = 782 ( gistbuild 11 10 12 1 0 0 0 f f f f t f v 3 0 2281 "2281 2281 2281" _null_ _null_ _null_ _null_ gistbuild _null_ _null_ _null_ ) +insert OID = 326 ( gistbuildempty 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "2281" _null_ _null_ _null_ _null_ gistbuildempty _null_ _null_ _null_ ) +insert OID = 776 ( gistbulkdelete 11 10 12 1 0 0 0 f f f f t f v 4 0 2281 "2281 2281 2281 2281" _null_ _null_ _null_ _null_ gistbulkdelete _null_ _null_ _null_ ) +insert OID = 2561 ( gistvacuumcleanup 11 10 12 1 0 0 0 f f f f t f v 2 0 2281 "2281 2281" _null_ _null_ _null_ _null_ gistvacuumcleanup _null_ _null_ _null_ ) +insert OID = 772 ( gistcostestimate 11 10 12 1 0 0 0 f f f f t f v 7 0 2278 "2281 2281 2281 2281 2281 2281 2281" _null_ _null_ _null_ _null_ gistcostestimate _null_ _null_ _null_ ) +insert OID = 2787 ( gistoptions 11 10 12 1 0 0 0 f f f f t f s 2 0 17 "1009 16" _null_ _null_ _null_ _null_ gistoptions _null_ _null_ _null_ ) +insert OID = 784 ( tintervaleq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "704 704" _null_ _null_ _null_ _null_ tintervaleq _null_ _null_ _null_ ) +insert OID = 785 ( tintervalne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "704 704" _null_ _null_ _null_ _null_ tintervalne _null_ _null_ _null_ ) +insert OID = 786 ( tintervallt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "704 704" _null_ _null_ _null_ _null_ tintervallt _null_ _null_ _null_ ) +insert OID = 787 ( tintervalgt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "704 704" _null_ _null_ _null_ _null_ tintervalgt _null_ _null_ _null_ ) +insert OID = 788 ( tintervalle 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "704 704" _null_ _null_ _null_ _null_ tintervalle _null_ _null_ _null_ ) +insert OID = 789 ( tintervalge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "704 704" _null_ _null_ _null_ _null_ tintervalge _null_ _null_ _null_ ) +insert OID = 846 ( cash_mul_flt4 11 10 12 1 0 0 0 f f f f t f i 2 0 790 "790 700" _null_ _null_ _null_ _null_ cash_mul_flt4 _null_ _null_ _null_ ) +insert OID = 847 ( cash_div_flt4 11 10 12 1 0 0 0 f f f f t f i 2 0 790 "790 700" _null_ _null_ _null_ _null_ cash_div_flt4 _null_ _null_ _null_ ) +insert OID = 848 ( flt4_mul_cash 11 10 12 1 0 0 0 f f f f t f i 2 0 790 "700 790" _null_ _null_ _null_ _null_ flt4_mul_cash _null_ _null_ _null_ ) +insert OID = 849 ( position 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "25 25" _null_ _null_ _null_ _null_ textpos _null_ _null_ _null_ ) +insert OID = 850 ( textlike 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "25 25" _null_ _null_ _null_ _null_ textlike _null_ _null_ _null_ ) +insert OID = 851 ( textnlike 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "25 25" _null_ _null_ _null_ _null_ textnlike _null_ _null_ _null_ ) +insert OID = 852 ( int48eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "23 20" _null_ _null_ _null_ _null_ int48eq _null_ _null_ _null_ ) +insert OID = 853 ( int48ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "23 20" _null_ _null_ _null_ _null_ int48ne _null_ _null_ _null_ ) +insert OID = 854 ( int48lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "23 20" _null_ _null_ _null_ _null_ int48lt _null_ _null_ _null_ ) +insert OID = 855 ( int48gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "23 20" _null_ _null_ _null_ _null_ int48gt _null_ _null_ _null_ ) +insert OID = 856 ( int48le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "23 20" _null_ _null_ _null_ _null_ int48le _null_ _null_ _null_ ) +insert OID = 857 ( int48ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "23 20" _null_ _null_ _null_ _null_ int48ge _null_ _null_ _null_ ) +insert OID = 858 ( namelike 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "19 25" _null_ _null_ _null_ _null_ namelike _null_ _null_ _null_ ) +insert OID = 859 ( namenlike 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "19 25" _null_ _null_ _null_ _null_ namenlike _null_ _null_ _null_ ) +insert OID = 860 ( bpchar 11 10 12 1 0 0 0 f f f f t f i 1 0 1042 "18" _null_ _null_ _null_ _null_ char_bpchar _null_ _null_ _null_ ) +insert OID = 861 ( current_database 11 10 12 1 0 0 0 f f f f t f s 0 0 19 "" _null_ _null_ _null_ _null_ current_database _null_ _null_ _null_ ) +insert OID = 817 ( current_query 11 10 12 1 0 0 0 f f f f f f v 0 0 25 "" _null_ _null_ _null_ _null_ current_query _null_ _null_ _null_ ) +insert OID = 862 ( int4_mul_cash 11 10 12 1 0 0 0 f f f f t f i 2 0 790 "23 790" _null_ _null_ _null_ _null_ int4_mul_cash _null_ _null_ _null_ ) +insert OID = 863 ( int2_mul_cash 11 10 12 1 0 0 0 f f f f t f i 2 0 790 "21 790" _null_ _null_ _null_ _null_ int2_mul_cash _null_ _null_ _null_ ) +insert OID = 864 ( cash_mul_int4 11 10 12 1 0 0 0 f f f f t f i 2 0 790 "790 23" _null_ _null_ _null_ _null_ cash_mul_int4 _null_ _null_ _null_ ) +insert OID = 865 ( cash_div_int4 11 10 12 1 0 0 0 f f f f t f i 2 0 790 "790 23" _null_ _null_ _null_ _null_ cash_div_int4 _null_ _null_ _null_ ) +insert OID = 866 ( cash_mul_int2 11 10 12 1 0 0 0 f f f f t f i 2 0 790 "790 21" _null_ _null_ _null_ _null_ cash_mul_int2 _null_ _null_ _null_ ) +insert OID = 867 ( cash_div_int2 11 10 12 1 0 0 0 f f f f t f i 2 0 790 "790 21" _null_ _null_ _null_ _null_ cash_div_int2 _null_ _null_ _null_ ) +insert OID = 886 ( cash_in 11 10 12 1 0 0 0 f f f f t f s 1 0 790 "2275" _null_ _null_ _null_ _null_ cash_in _null_ _null_ _null_ ) +insert OID = 887 ( cash_out 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "790" _null_ _null_ _null_ _null_ cash_out _null_ _null_ _null_ ) +insert OID = 888 ( cash_eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "790 790" _null_ _null_ _null_ _null_ cash_eq _null_ _null_ _null_ ) +insert OID = 889 ( cash_ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "790 790" _null_ _null_ _null_ _null_ cash_ne _null_ _null_ _null_ ) +insert OID = 890 ( cash_lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "790 790" _null_ _null_ _null_ _null_ cash_lt _null_ _null_ _null_ ) +insert OID = 891 ( cash_le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "790 790" _null_ _null_ _null_ _null_ cash_le _null_ _null_ _null_ ) +insert OID = 892 ( cash_gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "790 790" _null_ _null_ _null_ _null_ cash_gt _null_ _null_ _null_ ) +insert OID = 893 ( cash_ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "790 790" _null_ _null_ _null_ _null_ cash_ge _null_ _null_ _null_ ) +insert OID = 894 ( cash_pl 11 10 12 1 0 0 0 f f f f t f i 2 0 790 "790 790" _null_ _null_ _null_ _null_ cash_pl _null_ _null_ _null_ ) +insert OID = 895 ( cash_mi 11 10 12 1 0 0 0 f f f f t f i 2 0 790 "790 790" _null_ _null_ _null_ _null_ cash_mi _null_ _null_ _null_ ) +insert OID = 896 ( cash_mul_flt8 11 10 12 1 0 0 0 f f f f t f i 2 0 790 "790 701" _null_ _null_ _null_ _null_ cash_mul_flt8 _null_ _null_ _null_ ) +insert OID = 897 ( cash_div_flt8 11 10 12 1 0 0 0 f f f f t f i 2 0 790 "790 701" _null_ _null_ _null_ _null_ cash_div_flt8 _null_ _null_ _null_ ) +insert OID = 898 ( cashlarger 11 10 12 1 0 0 0 f f f f t f i 2 0 790 "790 790" _null_ _null_ _null_ _null_ cashlarger _null_ _null_ _null_ ) +insert OID = 899 ( cashsmaller 11 10 12 1 0 0 0 f f f f t f i 2 0 790 "790 790" _null_ _null_ _null_ _null_ cashsmaller _null_ _null_ _null_ ) +insert OID = 919 ( flt8_mul_cash 11 10 12 1 0 0 0 f f f f t f i 2 0 790 "701 790" _null_ _null_ _null_ _null_ flt8_mul_cash _null_ _null_ _null_ ) +insert OID = 935 ( cash_words 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "790" _null_ _null_ _null_ _null_ cash_words _null_ _null_ _null_ ) +insert OID = 3822 ( cash_div_cash 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "790 790" _null_ _null_ _null_ _null_ cash_div_cash _null_ _null_ _null_ ) +insert OID = 3823 ( numeric 11 10 12 1 0 0 0 f f f f t f s 1 0 1700 "790" _null_ _null_ _null_ _null_ cash_numeric _null_ _null_ _null_ ) +insert OID = 3824 ( money 11 10 12 1 0 0 0 f f f f t f s 1 0 790 "1700" _null_ _null_ _null_ _null_ numeric_cash _null_ _null_ _null_ ) +insert OID = 3811 ( money 11 10 12 1 0 0 0 f f f f t f s 1 0 790 "23" _null_ _null_ _null_ _null_ int4_cash _null_ _null_ _null_ ) +insert OID = 3812 ( money 11 10 12 1 0 0 0 f f f f t f s 1 0 790 "20" _null_ _null_ _null_ _null_ int8_cash _null_ _null_ _null_ ) +insert OID = 940 ( mod 11 10 12 1 0 0 0 f f f f t f i 2 0 21 "21 21" _null_ _null_ _null_ _null_ int2mod _null_ _null_ _null_ ) +insert OID = 941 ( mod 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "23 23" _null_ _null_ _null_ _null_ int4mod _null_ _null_ _null_ ) +insert OID = 945 ( int8mod 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "20 20" _null_ _null_ _null_ _null_ int8mod _null_ _null_ _null_ ) +insert OID = 947 ( mod 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "20 20" _null_ _null_ _null_ _null_ int8mod _null_ _null_ _null_ ) +insert OID = 944 ( char 11 10 12 1 0 0 0 f f f f t f i 1 0 18 "25" _null_ _null_ _null_ _null_ text_char _null_ _null_ _null_ ) +insert OID = 946 ( text 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "18" _null_ _null_ _null_ _null_ char_text _null_ _null_ _null_ ) +insert OID = 952 ( lo_open 11 10 12 1 0 0 0 f f f f t f v 2 0 23 "26 23" _null_ _null_ _null_ _null_ lo_open _null_ _null_ _null_ ) +insert OID = 953 ( lo_close 11 10 12 1 0 0 0 f f f f t f v 1 0 23 "23" _null_ _null_ _null_ _null_ lo_close _null_ _null_ _null_ ) +insert OID = 954 ( loread 11 10 12 1 0 0 0 f f f f t f v 2 0 17 "23 23" _null_ _null_ _null_ _null_ loread _null_ _null_ _null_ ) +insert OID = 955 ( lowrite 11 10 12 1 0 0 0 f f f f t f v 2 0 23 "23 17" _null_ _null_ _null_ _null_ lowrite _null_ _null_ _null_ ) +insert OID = 956 ( lo_lseek 11 10 12 1 0 0 0 f f f f t f v 3 0 23 "23 23 23" _null_ _null_ _null_ _null_ lo_lseek _null_ _null_ _null_ ) +insert OID = 957 ( lo_creat 11 10 12 1 0 0 0 f f f f t f v 1 0 26 "23" _null_ _null_ _null_ _null_ lo_creat _null_ _null_ _null_ ) +insert OID = 715 ( lo_create 11 10 12 1 0 0 0 f f f f t f v 1 0 26 "26" _null_ _null_ _null_ _null_ lo_create _null_ _null_ _null_ ) +insert OID = 958 ( lo_tell 11 10 12 1 0 0 0 f f f f t f v 1 0 23 "23" _null_ _null_ _null_ _null_ lo_tell _null_ _null_ _null_ ) +insert OID = 1004 ( lo_truncate 11 10 12 1 0 0 0 f f f f t f v 2 0 23 "23 23" _null_ _null_ _null_ _null_ lo_truncate _null_ _null_ _null_ ) +insert OID = 959 ( on_pl 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "600 628" _null_ _null_ _null_ _null_ on_pl _null_ _null_ _null_ ) +insert OID = 960 ( on_sl 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "601 628" _null_ _null_ _null_ _null_ on_sl _null_ _null_ _null_ ) +insert OID = 961 ( close_pl 11 10 12 1 0 0 0 f f f f t f i 2 0 600 "600 628" _null_ _null_ _null_ _null_ close_pl _null_ _null_ _null_ ) +insert OID = 962 ( close_sl 11 10 12 1 0 0 0 f f f f t f i 2 0 600 "601 628" _null_ _null_ _null_ _null_ close_sl _null_ _null_ _null_ ) +insert OID = 963 ( close_lb 11 10 12 1 0 0 0 f f f f t f i 2 0 600 "628 603" _null_ _null_ _null_ _null_ close_lb _null_ _null_ _null_ ) +insert OID = 964 ( lo_unlink 11 10 12 1 0 0 0 f f f f t f v 1 0 23 "26" _null_ _null_ _null_ _null_ lo_unlink _null_ _null_ _null_ ) +insert OID = 973 ( path_inter 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "602 602" _null_ _null_ _null_ _null_ path_inter _null_ _null_ _null_ ) +insert OID = 975 ( area 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "603" _null_ _null_ _null_ _null_ box_area _null_ _null_ _null_ ) +insert OID = 976 ( width 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "603" _null_ _null_ _null_ _null_ box_width _null_ _null_ _null_ ) +insert OID = 977 ( height 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "603" _null_ _null_ _null_ _null_ box_height _null_ _null_ _null_ ) +insert OID = 978 ( box_distance 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "603 603" _null_ _null_ _null_ _null_ box_distance _null_ _null_ _null_ ) +insert OID = 979 ( area 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "602" _null_ _null_ _null_ _null_ path_area _null_ _null_ _null_ ) +insert OID = 980 ( box_intersect 11 10 12 1 0 0 0 f f f f t f i 2 0 603 "603 603" _null_ _null_ _null_ _null_ box_intersect _null_ _null_ _null_ ) +insert OID = 981 ( diagonal 11 10 12 1 0 0 0 f f f f t f i 1 0 601 "603" _null_ _null_ _null_ _null_ box_diagonal _null_ _null_ _null_ ) +insert OID = 982 ( path_n_lt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "602 602" _null_ _null_ _null_ _null_ path_n_lt _null_ _null_ _null_ ) +insert OID = 983 ( path_n_gt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "602 602" _null_ _null_ _null_ _null_ path_n_gt _null_ _null_ _null_ ) +insert OID = 984 ( path_n_eq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "602 602" _null_ _null_ _null_ _null_ path_n_eq _null_ _null_ _null_ ) +insert OID = 985 ( path_n_le 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "602 602" _null_ _null_ _null_ _null_ path_n_le _null_ _null_ _null_ ) +insert OID = 986 ( path_n_ge 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "602 602" _null_ _null_ _null_ _null_ path_n_ge _null_ _null_ _null_ ) +insert OID = 987 ( path_length 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "602" _null_ _null_ _null_ _null_ path_length _null_ _null_ _null_ ) +insert OID = 988 ( point_ne 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "600 600" _null_ _null_ _null_ _null_ point_ne _null_ _null_ _null_ ) +insert OID = 989 ( point_vert 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "600 600" _null_ _null_ _null_ _null_ point_vert _null_ _null_ _null_ ) +insert OID = 990 ( point_horiz 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "600 600" _null_ _null_ _null_ _null_ point_horiz _null_ _null_ _null_ ) +insert OID = 991 ( point_distance 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "600 600" _null_ _null_ _null_ _null_ point_distance _null_ _null_ _null_ ) +insert OID = 992 ( slope 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "600 600" _null_ _null_ _null_ _null_ point_slope _null_ _null_ _null_ ) +insert OID = 993 ( lseg 11 10 12 1 0 0 0 f f f f t f i 2 0 601 "600 600" _null_ _null_ _null_ _null_ lseg_construct _null_ _null_ _null_ ) +insert OID = 994 ( lseg_intersect 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "601 601" _null_ _null_ _null_ _null_ lseg_intersect _null_ _null_ _null_ ) +insert OID = 995 ( lseg_parallel 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "601 601" _null_ _null_ _null_ _null_ lseg_parallel _null_ _null_ _null_ ) +insert OID = 996 ( lseg_perp 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "601 601" _null_ _null_ _null_ _null_ lseg_perp _null_ _null_ _null_ ) +insert OID = 997 ( lseg_vertical 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "601" _null_ _null_ _null_ _null_ lseg_vertical _null_ _null_ _null_ ) +insert OID = 998 ( lseg_horizontal 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "601" _null_ _null_ _null_ _null_ lseg_horizontal _null_ _null_ _null_ ) +insert OID = 999 ( lseg_eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "601 601" _null_ _null_ _null_ _null_ lseg_eq _null_ _null_ _null_ ) +insert OID = 1026 ( timezone 11 10 12 1 0 0 0 f f f f t f i 2 0 1114 "1186 1184" _null_ _null_ _null_ _null_ timestamptz_izone _null_ _null_ _null_ ) +insert OID = 1031 ( aclitemin 11 10 12 1 0 0 0 f f f f t f s 1 0 1033 "2275" _null_ _null_ _null_ _null_ aclitemin _null_ _null_ _null_ ) +insert OID = 1032 ( aclitemout 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "1033" _null_ _null_ _null_ _null_ aclitemout _null_ _null_ _null_ ) +insert OID = 1035 ( aclinsert 11 10 12 1 0 0 0 f f f f t f i 2 0 1034 "1034 1033" _null_ _null_ _null_ _null_ aclinsert _null_ _null_ _null_ ) +insert OID = 1036 ( aclremove 11 10 12 1 0 0 0 f f f f t f i 2 0 1034 "1034 1033" _null_ _null_ _null_ _null_ aclremove _null_ _null_ _null_ ) +insert OID = 1037 ( aclcontains 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1034 1033" _null_ _null_ _null_ _null_ aclcontains _null_ _null_ _null_ ) +insert OID = 1062 ( aclitemeq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1033 1033" _null_ _null_ _null_ _null_ aclitem_eq _null_ _null_ _null_ ) +insert OID = 1365 ( makeaclitem 11 10 12 1 0 0 0 f f f f t f i 4 0 1033 "26 26 25 16" _null_ _null_ _null_ _null_ makeaclitem _null_ _null_ _null_ ) +insert OID = 3943 ( acldefault 11 10 12 1 0 0 0 f f f f t f i 2 0 1034 "18 26" _null_ _null_ _null_ _null_ acldefault_sql _null_ _null_ _null_ ) +insert OID = 1689 ( aclexplode 11 10 12 1 10 0 0 f f f f t t s 1 0 2249 "1034" "{1034,26,26,25,16}" "{i,o,o,o,o}" "{acl,grantor,grantee,privilege_type,is_grantable}" _null_ aclexplode _null_ _null_ _null_ ) +insert OID = 1044 ( bpcharin 11 10 12 1 0 0 0 f f f f t f i 3 0 1042 "2275 26 23" _null_ _null_ _null_ _null_ bpcharin _null_ _null_ _null_ ) +insert OID = 1045 ( bpcharout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "1042" _null_ _null_ _null_ _null_ bpcharout _null_ _null_ _null_ ) +insert OID = 2913 ( bpchartypmodin 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1263" _null_ _null_ _null_ _null_ bpchartypmodin _null_ _null_ _null_ ) +insert OID = 2914 ( bpchartypmodout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "23" _null_ _null_ _null_ _null_ bpchartypmodout _null_ _null_ _null_ ) +insert OID = 1046 ( varcharin 11 10 12 1 0 0 0 f f f f t f i 3 0 1043 "2275 26 23" _null_ _null_ _null_ _null_ varcharin _null_ _null_ _null_ ) +insert OID = 1047 ( varcharout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "1043" _null_ _null_ _null_ _null_ varcharout _null_ _null_ _null_ ) +insert OID = 2915 ( varchartypmodin 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1263" _null_ _null_ _null_ _null_ varchartypmodin _null_ _null_ _null_ ) +insert OID = 2916 ( varchartypmodout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "23" _null_ _null_ _null_ _null_ varchartypmodout _null_ _null_ _null_ ) +insert OID = 1048 ( bpchareq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1042 1042" _null_ _null_ _null_ _null_ bpchareq _null_ _null_ _null_ ) +insert OID = 1049 ( bpcharlt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1042 1042" _null_ _null_ _null_ _null_ bpcharlt _null_ _null_ _null_ ) +insert OID = 1050 ( bpcharle 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1042 1042" _null_ _null_ _null_ _null_ bpcharle _null_ _null_ _null_ ) +insert OID = 1051 ( bpchargt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1042 1042" _null_ _null_ _null_ _null_ bpchargt _null_ _null_ _null_ ) +insert OID = 1052 ( bpcharge 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1042 1042" _null_ _null_ _null_ _null_ bpcharge _null_ _null_ _null_ ) +insert OID = 1053 ( bpcharne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1042 1042" _null_ _null_ _null_ _null_ bpcharne _null_ _null_ _null_ ) +insert OID = 1063 ( bpchar_larger 11 10 12 1 0 0 0 f f f f t f i 2 0 1042 "1042 1042" _null_ _null_ _null_ _null_ bpchar_larger _null_ _null_ _null_ ) +insert OID = 1064 ( bpchar_smaller 11 10 12 1 0 0 0 f f f f t f i 2 0 1042 "1042 1042" _null_ _null_ _null_ _null_ bpchar_smaller _null_ _null_ _null_ ) +insert OID = 1078 ( bpcharcmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "1042 1042" _null_ _null_ _null_ _null_ bpcharcmp _null_ _null_ _null_ ) +insert OID = 1080 ( hashbpchar 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1042" _null_ _null_ _null_ _null_ hashbpchar _null_ _null_ _null_ ) +insert OID = 1081 ( format_type 11 10 12 1 0 0 0 f f f f f f s 2 0 25 "26 23" _null_ _null_ _null_ _null_ format_type _null_ _null_ _null_ ) +insert OID = 1084 ( date_in 11 10 12 1 0 0 0 f f f f t f s 1 0 1082 "2275" _null_ _null_ _null_ _null_ date_in _null_ _null_ _null_ ) +insert OID = 1085 ( date_out 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "1082" _null_ _null_ _null_ _null_ date_out _null_ _null_ _null_ ) +insert OID = 1086 ( date_eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1082 1082" _null_ _null_ _null_ _null_ date_eq _null_ _null_ _null_ ) +insert OID = 1087 ( date_lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1082 1082" _null_ _null_ _null_ _null_ date_lt _null_ _null_ _null_ ) +insert OID = 1088 ( date_le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1082 1082" _null_ _null_ _null_ _null_ date_le _null_ _null_ _null_ ) +insert OID = 1089 ( date_gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1082 1082" _null_ _null_ _null_ _null_ date_gt _null_ _null_ _null_ ) +insert OID = 1090 ( date_ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1082 1082" _null_ _null_ _null_ _null_ date_ge _null_ _null_ _null_ ) +insert OID = 1091 ( date_ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1082 1082" _null_ _null_ _null_ _null_ date_ne _null_ _null_ _null_ ) +insert OID = 1092 ( date_cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "1082 1082" _null_ _null_ _null_ _null_ date_cmp _null_ _null_ _null_ ) +insert OID = 3136 ( date_sortsupport 11 10 12 1 0 0 0 f f f f t f i 1 0 2278 "2281" _null_ _null_ _null_ _null_ date_sortsupport _null_ _null_ _null_ ) +insert OID = 1102 ( time_lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1083 1083" _null_ _null_ _null_ _null_ time_lt _null_ _null_ _null_ ) +insert OID = 1103 ( time_le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1083 1083" _null_ _null_ _null_ _null_ time_le _null_ _null_ _null_ ) +insert OID = 1104 ( time_gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1083 1083" _null_ _null_ _null_ _null_ time_gt _null_ _null_ _null_ ) +insert OID = 1105 ( time_ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1083 1083" _null_ _null_ _null_ _null_ time_ge _null_ _null_ _null_ ) +insert OID = 1106 ( time_ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1083 1083" _null_ _null_ _null_ _null_ time_ne _null_ _null_ _null_ ) +insert OID = 1107 ( time_cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "1083 1083" _null_ _null_ _null_ _null_ time_cmp _null_ _null_ _null_ ) +insert OID = 1138 ( date_larger 11 10 12 1 0 0 0 f f f f t f i 2 0 1082 "1082 1082" _null_ _null_ _null_ _null_ date_larger _null_ _null_ _null_ ) +insert OID = 1139 ( date_smaller 11 10 12 1 0 0 0 f f f f t f i 2 0 1082 "1082 1082" _null_ _null_ _null_ _null_ date_smaller _null_ _null_ _null_ ) +insert OID = 1140 ( date_mi 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "1082 1082" _null_ _null_ _null_ _null_ date_mi _null_ _null_ _null_ ) +insert OID = 1141 ( date_pli 11 10 12 1 0 0 0 f f f f t f i 2 0 1082 "1082 23" _null_ _null_ _null_ _null_ date_pli _null_ _null_ _null_ ) +insert OID = 1142 ( date_mii 11 10 12 1 0 0 0 f f f f t f i 2 0 1082 "1082 23" _null_ _null_ _null_ _null_ date_mii _null_ _null_ _null_ ) +insert OID = 1143 ( time_in 11 10 12 1 0 0 0 f f f f t f s 3 0 1083 "2275 26 23" _null_ _null_ _null_ _null_ time_in _null_ _null_ _null_ ) +insert OID = 1144 ( time_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "1083" _null_ _null_ _null_ _null_ time_out _null_ _null_ _null_ ) +insert OID = 2909 ( timetypmodin 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1263" _null_ _null_ _null_ _null_ timetypmodin _null_ _null_ _null_ ) +insert OID = 2910 ( timetypmodout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "23" _null_ _null_ _null_ _null_ timetypmodout _null_ _null_ _null_ ) +insert OID = 1145 ( time_eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1083 1083" _null_ _null_ _null_ _null_ time_eq _null_ _null_ _null_ ) +insert OID = 1146 ( circle_add_pt 11 10 12 1 0 0 0 f f f f t f i 2 0 718 "718 600" _null_ _null_ _null_ _null_ circle_add_pt _null_ _null_ _null_ ) +insert OID = 1147 ( circle_sub_pt 11 10 12 1 0 0 0 f f f f t f i 2 0 718 "718 600" _null_ _null_ _null_ _null_ circle_sub_pt _null_ _null_ _null_ ) +insert OID = 1148 ( circle_mul_pt 11 10 12 1 0 0 0 f f f f t f i 2 0 718 "718 600" _null_ _null_ _null_ _null_ circle_mul_pt _null_ _null_ _null_ ) +insert OID = 1149 ( circle_div_pt 11 10 12 1 0 0 0 f f f f t f i 2 0 718 "718 600" _null_ _null_ _null_ _null_ circle_div_pt _null_ _null_ _null_ ) +insert OID = 1150 ( timestamptz_in 11 10 12 1 0 0 0 f f f f t f s 3 0 1184 "2275 26 23" _null_ _null_ _null_ _null_ timestamptz_in _null_ _null_ _null_ ) +insert OID = 1151 ( timestamptz_out 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "1184" _null_ _null_ _null_ _null_ timestamptz_out _null_ _null_ _null_ ) +insert OID = 2907 ( timestamptztypmodin 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1263" _null_ _null_ _null_ _null_ timestamptztypmodin _null_ _null_ _null_ ) +insert OID = 2908 ( timestamptztypmodout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "23" _null_ _null_ _null_ _null_ timestamptztypmodout _null_ _null_ _null_ ) +insert OID = 1152 ( timestamptz_eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1184 1184" _null_ _null_ _null_ _null_ timestamp_eq _null_ _null_ _null_ ) +insert OID = 1153 ( timestamptz_ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1184 1184" _null_ _null_ _null_ _null_ timestamp_ne _null_ _null_ _null_ ) +insert OID = 1154 ( timestamptz_lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1184 1184" _null_ _null_ _null_ _null_ timestamp_lt _null_ _null_ _null_ ) +insert OID = 1155 ( timestamptz_le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1184 1184" _null_ _null_ _null_ _null_ timestamp_le _null_ _null_ _null_ ) +insert OID = 1156 ( timestamptz_ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1184 1184" _null_ _null_ _null_ _null_ timestamp_ge _null_ _null_ _null_ ) +insert OID = 1157 ( timestamptz_gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1184 1184" _null_ _null_ _null_ _null_ timestamp_gt _null_ _null_ _null_ ) +insert OID = 1158 ( to_timestamp 11 10 14 1 0 0 0 f f f f t f i 1 0 1184 "701" _null_ _null_ _null_ _null_ "select (''epoch''::pg_catalog.timestamptz + $1 * ''1 second''::pg_catalog.interval)" _null_ _null_ _null_ ) +insert OID = 1159 ( timezone 11 10 12 1 0 0 0 f f f f t f i 2 0 1114 "25 1184" _null_ _null_ _null_ _null_ timestamptz_zone _null_ _null_ _null_ ) +insert OID = 1160 ( interval_in 11 10 12 1 0 0 0 f f f f t f s 3 0 1186 "2275 26 23" _null_ _null_ _null_ _null_ interval_in _null_ _null_ _null_ ) +insert OID = 1161 ( interval_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "1186" _null_ _null_ _null_ _null_ interval_out _null_ _null_ _null_ ) +insert OID = 2903 ( intervaltypmodin 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1263" _null_ _null_ _null_ _null_ intervaltypmodin _null_ _null_ _null_ ) +insert OID = 2904 ( intervaltypmodout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "23" _null_ _null_ _null_ _null_ intervaltypmodout _null_ _null_ _null_ ) +insert OID = 1162 ( interval_eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1186 1186" _null_ _null_ _null_ _null_ interval_eq _null_ _null_ _null_ ) +insert OID = 1163 ( interval_ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1186 1186" _null_ _null_ _null_ _null_ interval_ne _null_ _null_ _null_ ) +insert OID = 1164 ( interval_lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1186 1186" _null_ _null_ _null_ _null_ interval_lt _null_ _null_ _null_ ) +insert OID = 1165 ( interval_le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1186 1186" _null_ _null_ _null_ _null_ interval_le _null_ _null_ _null_ ) +insert OID = 1166 ( interval_ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1186 1186" _null_ _null_ _null_ _null_ interval_ge _null_ _null_ _null_ ) +insert OID = 1167 ( interval_gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1186 1186" _null_ _null_ _null_ _null_ interval_gt _null_ _null_ _null_ ) +insert OID = 1168 ( interval_um 11 10 12 1 0 0 0 f f f f t f i 1 0 1186 "1186" _null_ _null_ _null_ _null_ interval_um _null_ _null_ _null_ ) +insert OID = 1169 ( interval_pl 11 10 12 1 0 0 0 f f f f t f i 2 0 1186 "1186 1186" _null_ _null_ _null_ _null_ interval_pl _null_ _null_ _null_ ) +insert OID = 1170 ( interval_mi 11 10 12 1 0 0 0 f f f f t f i 2 0 1186 "1186 1186" _null_ _null_ _null_ _null_ interval_mi _null_ _null_ _null_ ) +insert OID = 1171 ( date_part 11 10 12 1 0 0 0 f f f f t f s 2 0 701 "25 1184" _null_ _null_ _null_ _null_ timestamptz_part _null_ _null_ _null_ ) +insert OID = 1172 ( date_part 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "25 1186" _null_ _null_ _null_ _null_ interval_part _null_ _null_ _null_ ) +insert OID = 1173 ( timestamptz 11 10 12 1 0 0 0 f f f f t f i 1 0 1184 "702" _null_ _null_ _null_ _null_ abstime_timestamptz _null_ _null_ _null_ ) +insert OID = 1174 ( timestamptz 11 10 12 1 0 0 0 f f f f t f s 1 0 1184 "1082" _null_ _null_ _null_ _null_ date_timestamptz _null_ _null_ _null_ ) +insert OID = 2711 ( justify_interval 11 10 12 1 0 0 0 f f f f t f i 1 0 1186 "1186" _null_ _null_ _null_ _null_ interval_justify_interval _null_ _null_ _null_ ) +insert OID = 1175 ( justify_hours 11 10 12 1 0 0 0 f f f f t f i 1 0 1186 "1186" _null_ _null_ _null_ _null_ interval_justify_hours _null_ _null_ _null_ ) +insert OID = 1295 ( justify_days 11 10 12 1 0 0 0 f f f f t f i 1 0 1186 "1186" _null_ _null_ _null_ _null_ interval_justify_days _null_ _null_ _null_ ) +insert OID = 1176 ( timestamptz 11 10 14 1 0 0 0 f f f f t f s 2 0 1184 "1082 1083" _null_ _null_ _null_ _null_ "select cast(($1 + $2) as timestamp with time zone)" _null_ _null_ _null_ ) +insert OID = 1177 ( interval 11 10 12 1 0 0 0 f f f f t f i 1 0 1186 "703" _null_ _null_ _null_ _null_ reltime_interval _null_ _null_ _null_ ) +insert OID = 1178 ( date 11 10 12 1 0 0 0 f f f f t f s 1 0 1082 "1184" _null_ _null_ _null_ _null_ timestamptz_date _null_ _null_ _null_ ) +insert OID = 1179 ( date 11 10 12 1 0 0 0 f f f f t f s 1 0 1082 "702" _null_ _null_ _null_ _null_ abstime_date _null_ _null_ _null_ ) +insert OID = 1180 ( abstime 11 10 12 1 0 0 0 f f f f t f i 1 0 702 "1184" _null_ _null_ _null_ _null_ timestamptz_abstime _null_ _null_ _null_ ) +insert OID = 1181 ( age 11 10 12 1 0 0 0 f f f f t f s 1 0 23 "28" _null_ _null_ _null_ _null_ xid_age _null_ _null_ _null_ ) +insert OID = 1188 ( timestamptz_mi 11 10 12 1 0 0 0 f f f f t f i 2 0 1186 "1184 1184" _null_ _null_ _null_ _null_ timestamp_mi _null_ _null_ _null_ ) +insert OID = 1189 ( timestamptz_pl_interval 11 10 12 1 0 0 0 f f f f t f s 2 0 1184 "1184 1186" _null_ _null_ _null_ _null_ timestamptz_pl_interval _null_ _null_ _null_ ) +insert OID = 1190 ( timestamptz_mi_interval 11 10 12 1 0 0 0 f f f f t f s 2 0 1184 "1184 1186" _null_ _null_ _null_ _null_ timestamptz_mi_interval _null_ _null_ _null_ ) +insert OID = 1194 ( reltime 11 10 12 1 0 0 0 f f f f t f i 1 0 703 "1186" _null_ _null_ _null_ _null_ interval_reltime _null_ _null_ _null_ ) +insert OID = 1195 ( timestamptz_smaller 11 10 12 1 0 0 0 f f f f t f i 2 0 1184 "1184 1184" _null_ _null_ _null_ _null_ timestamp_smaller _null_ _null_ _null_ ) +insert OID = 1196 ( timestamptz_larger 11 10 12 1 0 0 0 f f f f t f i 2 0 1184 "1184 1184" _null_ _null_ _null_ _null_ timestamp_larger _null_ _null_ _null_ ) +insert OID = 1197 ( interval_smaller 11 10 12 1 0 0 0 f f f f t f i 2 0 1186 "1186 1186" _null_ _null_ _null_ _null_ interval_smaller _null_ _null_ _null_ ) +insert OID = 1198 ( interval_larger 11 10 12 1 0 0 0 f f f f t f i 2 0 1186 "1186 1186" _null_ _null_ _null_ _null_ interval_larger _null_ _null_ _null_ ) +insert OID = 1199 ( age 11 10 12 1 0 0 0 f f f f t f i 2 0 1186 "1184 1184" _null_ _null_ _null_ _null_ timestamptz_age _null_ _null_ _null_ ) +insert OID = 3918 ( interval_transform 11 10 12 1 0 0 0 f f f f t f i 1 0 2281 "2281" _null_ _null_ _null_ _null_ interval_transform _null_ _null_ _null_ ) +insert OID = 1200 ( interval 11 10 12 1 0 0 interval_transform f f f f t f i 2 0 1186 "1186 23" _null_ _null_ _null_ _null_ interval_scale _null_ _null_ _null_ ) +insert OID = 1215 ( obj_description 11 10 14 100 0 0 0 f f f f t f s 2 0 25 "26 19" _null_ _null_ _null_ _null_ "select description from pg_catalog.pg_description where objoid = $1 and classoid = (select oid from pg_catalog.pg_class where relname = $2 and relnamespace = 11) and objsubid = 0" _null_ _null_ _null_ ) +insert OID = 1216 ( col_description 11 10 14 100 0 0 0 f f f f t f s 2 0 25 "26 23" _null_ _null_ _null_ _null_ "select description from pg_catalog.pg_description where objoid = $1 and classoid = ''pg_catalog.pg_class''::pg_catalog.regclass and objsubid = $2" _null_ _null_ _null_ ) +insert OID = 1993 ( shobj_description 11 10 14 100 0 0 0 f f f f t f s 2 0 25 "26 19" _null_ _null_ _null_ _null_ "select description from pg_catalog.pg_shdescription where objoid = $1 and classoid = (select oid from pg_catalog.pg_class where relname = $2 and relnamespace = 11)" _null_ _null_ _null_ ) +insert OID = 1217 ( date_trunc 11 10 12 1 0 0 0 f f f f t f s 2 0 1184 "25 1184" _null_ _null_ _null_ _null_ timestamptz_trunc _null_ _null_ _null_ ) +insert OID = 1218 ( date_trunc 11 10 12 1 0 0 0 f f f f t f i 2 0 1186 "25 1186" _null_ _null_ _null_ _null_ interval_trunc _null_ _null_ _null_ ) +insert OID = 1219 ( int8inc 11 10 12 1 0 0 0 f f f f t f i 1 0 20 "20" _null_ _null_ _null_ _null_ int8inc _null_ _null_ _null_ ) +insert OID = 2804 ( int8inc_any 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "20 2276" _null_ _null_ _null_ _null_ int8inc_any _null_ _null_ _null_ ) +insert OID = 1230 ( int8abs 11 10 12 1 0 0 0 f f f f t f i 1 0 20 "20" _null_ _null_ _null_ _null_ int8abs _null_ _null_ _null_ ) +insert OID = 1236 ( int8larger 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "20 20" _null_ _null_ _null_ _null_ int8larger _null_ _null_ _null_ ) +insert OID = 1237 ( int8smaller 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "20 20" _null_ _null_ _null_ _null_ int8smaller _null_ _null_ _null_ ) +insert OID = 1238 ( texticregexeq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "25 25" _null_ _null_ _null_ _null_ texticregexeq _null_ _null_ _null_ ) +insert OID = 1239 ( texticregexne 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "25 25" _null_ _null_ _null_ _null_ texticregexne _null_ _null_ _null_ ) +insert OID = 1240 ( nameicregexeq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "19 25" _null_ _null_ _null_ _null_ nameicregexeq _null_ _null_ _null_ ) +insert OID = 1241 ( nameicregexne 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "19 25" _null_ _null_ _null_ _null_ nameicregexne _null_ _null_ _null_ ) +insert OID = 1251 ( int4abs 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "23" _null_ _null_ _null_ _null_ int4abs _null_ _null_ _null_ ) +insert OID = 1253 ( int2abs 11 10 12 1 0 0 0 f f f f t f i 1 0 21 "21" _null_ _null_ _null_ _null_ int2abs _null_ _null_ _null_ ) +insert OID = 1271 ( overlaps 11 10 12 1 0 0 0 f f f f f f i 4 0 16 "1266 1266 1266 1266" _null_ _null_ _null_ _null_ overlaps_timetz _null_ _null_ _null_ ) +insert OID = 1272 ( datetime_pl 11 10 12 1 0 0 0 f f f f t f i 2 0 1114 "1082 1083" _null_ _null_ _null_ _null_ datetime_timestamp _null_ _null_ _null_ ) +insert OID = 1273 ( date_part 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "25 1266" _null_ _null_ _null_ _null_ timetz_part _null_ _null_ _null_ ) +insert OID = 1274 ( int84pl 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "20 23" _null_ _null_ _null_ _null_ int84pl _null_ _null_ _null_ ) +insert OID = 1275 ( int84mi 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "20 23" _null_ _null_ _null_ _null_ int84mi _null_ _null_ _null_ ) +insert OID = 1276 ( int84mul 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "20 23" _null_ _null_ _null_ _null_ int84mul _null_ _null_ _null_ ) +insert OID = 1277 ( int84div 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "20 23" _null_ _null_ _null_ _null_ int84div _null_ _null_ _null_ ) +insert OID = 1278 ( int48pl 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "23 20" _null_ _null_ _null_ _null_ int48pl _null_ _null_ _null_ ) +insert OID = 1279 ( int48mi 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "23 20" _null_ _null_ _null_ _null_ int48mi _null_ _null_ _null_ ) +insert OID = 1280 ( int48mul 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "23 20" _null_ _null_ _null_ _null_ int48mul _null_ _null_ _null_ ) +insert OID = 1281 ( int48div 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "23 20" _null_ _null_ _null_ _null_ int48div _null_ _null_ _null_ ) +insert OID = 837 ( int82pl 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "20 21" _null_ _null_ _null_ _null_ int82pl _null_ _null_ _null_ ) +insert OID = 838 ( int82mi 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "20 21" _null_ _null_ _null_ _null_ int82mi _null_ _null_ _null_ ) +insert OID = 839 ( int82mul 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "20 21" _null_ _null_ _null_ _null_ int82mul _null_ _null_ _null_ ) +insert OID = 840 ( int82div 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "20 21" _null_ _null_ _null_ _null_ int82div _null_ _null_ _null_ ) +insert OID = 841 ( int28pl 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "21 20" _null_ _null_ _null_ _null_ int28pl _null_ _null_ _null_ ) +insert OID = 942 ( int28mi 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "21 20" _null_ _null_ _null_ _null_ int28mi _null_ _null_ _null_ ) +insert OID = 943 ( int28mul 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "21 20" _null_ _null_ _null_ _null_ int28mul _null_ _null_ _null_ ) +insert OID = 948 ( int28div 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "21 20" _null_ _null_ _null_ _null_ int28div _null_ _null_ _null_ ) +insert OID = 1287 ( oid 11 10 12 1 0 0 0 f f f f t f i 1 0 26 "20" _null_ _null_ _null_ _null_ i8tooid _null_ _null_ _null_ ) +insert OID = 1288 ( int8 11 10 12 1 0 0 0 f f f f t f i 1 0 20 "26" _null_ _null_ _null_ _null_ oidtoi8 _null_ _null_ _null_ ) +insert OID = 1291 ( suppress_redundant_updates_trigger 11 10 12 1 0 0 0 f f f f t f v 0 0 2279 "" _null_ _null_ _null_ _null_ suppress_redundant_updates_trigger _null_ _null_ _null_ ) +insert OID = 1292 ( tideq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "27 27" _null_ _null_ _null_ _null_ tideq _null_ _null_ _null_ ) +insert OID = 1293 ( currtid 11 10 12 1 0 0 0 f f f f t f v 2 0 27 "26 27" _null_ _null_ _null_ _null_ currtid_byreloid _null_ _null_ _null_ ) +insert OID = 1294 ( currtid2 11 10 12 1 0 0 0 f f f f t f v 2 0 27 "25 27" _null_ _null_ _null_ _null_ currtid_byrelname _null_ _null_ _null_ ) +insert OID = 1265 ( tidne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "27 27" _null_ _null_ _null_ _null_ tidne _null_ _null_ _null_ ) +insert OID = 2790 ( tidgt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "27 27" _null_ _null_ _null_ _null_ tidgt _null_ _null_ _null_ ) +insert OID = 2791 ( tidlt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "27 27" _null_ _null_ _null_ _null_ tidlt _null_ _null_ _null_ ) +insert OID = 2792 ( tidge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "27 27" _null_ _null_ _null_ _null_ tidge _null_ _null_ _null_ ) +insert OID = 2793 ( tidle 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "27 27" _null_ _null_ _null_ _null_ tidle _null_ _null_ _null_ ) +insert OID = 2794 ( bttidcmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "27 27" _null_ _null_ _null_ _null_ bttidcmp _null_ _null_ _null_ ) +insert OID = 2795 ( tidlarger 11 10 12 1 0 0 0 f f f f t f i 2 0 27 "27 27" _null_ _null_ _null_ _null_ tidlarger _null_ _null_ _null_ ) +insert OID = 2796 ( tidsmaller 11 10 12 1 0 0 0 f f f f t f i 2 0 27 "27 27" _null_ _null_ _null_ _null_ tidsmaller _null_ _null_ _null_ ) +insert OID = 1296 ( timedate_pl 11 10 14 1 0 0 0 f f f f t f i 2 0 1114 "1083 1082" _null_ _null_ _null_ _null_ "select ($2 + $1)" _null_ _null_ _null_ ) +insert OID = 1297 ( datetimetz_pl 11 10 12 1 0 0 0 f f f f t f i 2 0 1184 "1082 1266" _null_ _null_ _null_ _null_ datetimetz_timestamptz _null_ _null_ _null_ ) +insert OID = 1298 ( timetzdate_pl 11 10 14 1 0 0 0 f f f f t f i 2 0 1184 "1266 1082" _null_ _null_ _null_ _null_ "select ($2 + $1)" _null_ _null_ _null_ ) +insert OID = 1299 ( now 11 10 12 1 0 0 0 f f f f t f s 0 0 1184 "" _null_ _null_ _null_ _null_ now _null_ _null_ _null_ ) +insert OID = 2647 ( transaction_timestamp 11 10 12 1 0 0 0 f f f f t f s 0 0 1184 "" _null_ _null_ _null_ _null_ now _null_ _null_ _null_ ) +insert OID = 2648 ( statement_timestamp 11 10 12 1 0 0 0 f f f f t f s 0 0 1184 "" _null_ _null_ _null_ _null_ statement_timestamp _null_ _null_ _null_ ) +insert OID = 2649 ( clock_timestamp 11 10 12 1 0 0 0 f f f f t f v 0 0 1184 "" _null_ _null_ _null_ _null_ clock_timestamp _null_ _null_ _null_ ) +insert OID = 1300 ( positionsel 11 10 12 1 0 0 0 f f f f t f s 4 0 701 "2281 26 2281 23" _null_ _null_ _null_ _null_ positionsel _null_ _null_ _null_ ) +insert OID = 1301 ( positionjoinsel 11 10 12 1 0 0 0 f f f f t f s 5 0 701 "2281 26 2281 21 2281" _null_ _null_ _null_ _null_ positionjoinsel _null_ _null_ _null_ ) +insert OID = 1302 ( contsel 11 10 12 1 0 0 0 f f f f t f s 4 0 701 "2281 26 2281 23" _null_ _null_ _null_ _null_ contsel _null_ _null_ _null_ ) +insert OID = 1303 ( contjoinsel 11 10 12 1 0 0 0 f f f f t f s 5 0 701 "2281 26 2281 21 2281" _null_ _null_ _null_ _null_ contjoinsel _null_ _null_ _null_ ) +insert OID = 1304 ( overlaps 11 10 12 1 0 0 0 f f f f f f i 4 0 16 "1184 1184 1184 1184" _null_ _null_ _null_ _null_ overlaps_timestamp _null_ _null_ _null_ ) +insert OID = 1305 ( overlaps 11 10 14 1 0 0 0 f f f f f f s 4 0 16 "1184 1186 1184 1186" _null_ _null_ _null_ _null_ "select ($1, ($1 + $2)) overlaps ($3, ($3 + $4))" _null_ _null_ _null_ ) +insert OID = 1306 ( overlaps 11 10 14 1 0 0 0 f f f f f f s 4 0 16 "1184 1184 1184 1186" _null_ _null_ _null_ _null_ "select ($1, $2) overlaps ($3, ($3 + $4))" _null_ _null_ _null_ ) +insert OID = 1307 ( overlaps 11 10 14 1 0 0 0 f f f f f f s 4 0 16 "1184 1186 1184 1184" _null_ _null_ _null_ _null_ "select ($1, ($1 + $2)) overlaps ($3, $4)" _null_ _null_ _null_ ) +insert OID = 1308 ( overlaps 11 10 12 1 0 0 0 f f f f f f i 4 0 16 "1083 1083 1083 1083" _null_ _null_ _null_ _null_ overlaps_time _null_ _null_ _null_ ) +insert OID = 1309 ( overlaps 11 10 14 1 0 0 0 f f f f f f i 4 0 16 "1083 1186 1083 1186" _null_ _null_ _null_ _null_ "select ($1, ($1 + $2)) overlaps ($3, ($3 + $4))" _null_ _null_ _null_ ) +insert OID = 1310 ( overlaps 11 10 14 1 0 0 0 f f f f f f i 4 0 16 "1083 1083 1083 1186" _null_ _null_ _null_ _null_ "select ($1, $2) overlaps ($3, ($3 + $4))" _null_ _null_ _null_ ) +insert OID = 1311 ( overlaps 11 10 14 1 0 0 0 f f f f f f i 4 0 16 "1083 1186 1083 1083" _null_ _null_ _null_ _null_ "select ($1, ($1 + $2)) overlaps ($3, $4)" _null_ _null_ _null_ ) +insert OID = 1312 ( timestamp_in 11 10 12 1 0 0 0 f f f f t f s 3 0 1114 "2275 26 23" _null_ _null_ _null_ _null_ timestamp_in _null_ _null_ _null_ ) +insert OID = 1313 ( timestamp_out 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "1114" _null_ _null_ _null_ _null_ timestamp_out _null_ _null_ _null_ ) +insert OID = 2905 ( timestamptypmodin 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1263" _null_ _null_ _null_ _null_ timestamptypmodin _null_ _null_ _null_ ) +insert OID = 2906 ( timestamptypmodout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "23" _null_ _null_ _null_ _null_ timestamptypmodout _null_ _null_ _null_ ) +insert OID = 1314 ( timestamptz_cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "1184 1184" _null_ _null_ _null_ _null_ timestamp_cmp _null_ _null_ _null_ ) +insert OID = 1315 ( interval_cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "1186 1186" _null_ _null_ _null_ _null_ interval_cmp _null_ _null_ _null_ ) +insert OID = 1316 ( time 11 10 12 1 0 0 0 f f f f t f i 1 0 1083 "1114" _null_ _null_ _null_ _null_ timestamp_time _null_ _null_ _null_ ) +insert OID = 1317 ( length 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "25" _null_ _null_ _null_ _null_ textlen _null_ _null_ _null_ ) +insert OID = 1318 ( length 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1042" _null_ _null_ _null_ _null_ bpcharlen _null_ _null_ _null_ ) +insert OID = 1319 ( xideqint4 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "28 23" _null_ _null_ _null_ _null_ xideq _null_ _null_ _null_ ) +insert OID = 1326 ( interval_div 11 10 12 1 0 0 0 f f f f t f i 2 0 1186 "1186 701" _null_ _null_ _null_ _null_ interval_div _null_ _null_ _null_ ) +insert OID = 1339 ( dlog10 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ dlog10 _null_ _null_ _null_ ) +insert OID = 1340 ( log 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ dlog10 _null_ _null_ _null_ ) +insert OID = 1341 ( ln 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ dlog1 _null_ _null_ _null_ ) +insert OID = 1342 ( round 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ dround _null_ _null_ _null_ ) +insert OID = 1343 ( trunc 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ dtrunc _null_ _null_ _null_ ) +insert OID = 1344 ( sqrt 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ dsqrt _null_ _null_ _null_ ) +insert OID = 1345 ( cbrt 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ dcbrt _null_ _null_ _null_ ) +insert OID = 1346 ( pow 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "701 701" _null_ _null_ _null_ _null_ dpow _null_ _null_ _null_ ) +insert OID = 1368 ( power 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "701 701" _null_ _null_ _null_ _null_ dpow _null_ _null_ _null_ ) +insert OID = 1347 ( exp 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ dexp _null_ _null_ _null_ ) +insert OID = 1348 ( obj_description 11 10 14 100 0 0 0 f f f f t f s 1 0 25 "26" _null_ _null_ _null_ _null_ "select description from pg_catalog.pg_description where objoid = $1 and objsubid = 0" _null_ _null_ _null_ ) +insert OID = 1349 ( oidvectortypes 11 10 12 1 0 0 0 f f f f t f s 1 0 25 "30" _null_ _null_ _null_ _null_ oidvectortypes _null_ _null_ _null_ ) +insert OID = 1350 ( timetz_in 11 10 12 1 0 0 0 f f f f t f s 3 0 1266 "2275 26 23" _null_ _null_ _null_ _null_ timetz_in _null_ _null_ _null_ ) +insert OID = 1351 ( timetz_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "1266" _null_ _null_ _null_ _null_ timetz_out _null_ _null_ _null_ ) +insert OID = 2911 ( timetztypmodin 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1263" _null_ _null_ _null_ _null_ timetztypmodin _null_ _null_ _null_ ) +insert OID = 2912 ( timetztypmodout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "23" _null_ _null_ _null_ _null_ timetztypmodout _null_ _null_ _null_ ) +insert OID = 1352 ( timetz_eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1266 1266" _null_ _null_ _null_ _null_ timetz_eq _null_ _null_ _null_ ) +insert OID = 1353 ( timetz_ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1266 1266" _null_ _null_ _null_ _null_ timetz_ne _null_ _null_ _null_ ) +insert OID = 1354 ( timetz_lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1266 1266" _null_ _null_ _null_ _null_ timetz_lt _null_ _null_ _null_ ) +insert OID = 1355 ( timetz_le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1266 1266" _null_ _null_ _null_ _null_ timetz_le _null_ _null_ _null_ ) +insert OID = 1356 ( timetz_ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1266 1266" _null_ _null_ _null_ _null_ timetz_ge _null_ _null_ _null_ ) +insert OID = 1357 ( timetz_gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1266 1266" _null_ _null_ _null_ _null_ timetz_gt _null_ _null_ _null_ ) +insert OID = 1358 ( timetz_cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "1266 1266" _null_ _null_ _null_ _null_ timetz_cmp _null_ _null_ _null_ ) +insert OID = 1359 ( timestamptz 11 10 12 1 0 0 0 f f f f t f i 2 0 1184 "1082 1266" _null_ _null_ _null_ _null_ datetimetz_timestamptz _null_ _null_ _null_ ) +insert OID = 1364 ( time 11 10 14 1 0 0 0 f f f f t f s 1 0 1083 "702" _null_ _null_ _null_ _null_ "select cast(cast($1 as timestamp without time zone) as pg_catalog.time)" _null_ _null_ _null_ ) +insert OID = 1367 ( character_length 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1042" _null_ _null_ _null_ _null_ bpcharlen _null_ _null_ _null_ ) +insert OID = 1369 ( character_length 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "25" _null_ _null_ _null_ _null_ textlen _null_ _null_ _null_ ) +insert OID = 1370 ( interval 11 10 12 1 0 0 0 f f f f t f i 1 0 1186 "1083" _null_ _null_ _null_ _null_ time_interval _null_ _null_ _null_ ) +insert OID = 1372 ( char_length 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1042" _null_ _null_ _null_ _null_ bpcharlen _null_ _null_ _null_ ) +insert OID = 1374 ( octet_length 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "25" _null_ _null_ _null_ _null_ textoctetlen _null_ _null_ _null_ ) +insert OID = 1375 ( octet_length 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1042" _null_ _null_ _null_ _null_ bpcharoctetlen _null_ _null_ _null_ ) +insert OID = 1377 ( time_larger 11 10 12 1 0 0 0 f f f f t f i 2 0 1083 "1083 1083" _null_ _null_ _null_ _null_ time_larger _null_ _null_ _null_ ) +insert OID = 1378 ( time_smaller 11 10 12 1 0 0 0 f f f f t f i 2 0 1083 "1083 1083" _null_ _null_ _null_ _null_ time_smaller _null_ _null_ _null_ ) +insert OID = 1379 ( timetz_larger 11 10 12 1 0 0 0 f f f f t f i 2 0 1266 "1266 1266" _null_ _null_ _null_ _null_ timetz_larger _null_ _null_ _null_ ) +insert OID = 1380 ( timetz_smaller 11 10 12 1 0 0 0 f f f f t f i 2 0 1266 "1266 1266" _null_ _null_ _null_ _null_ timetz_smaller _null_ _null_ _null_ ) +insert OID = 1381 ( char_length 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "25" _null_ _null_ _null_ _null_ textlen _null_ _null_ _null_ ) +insert OID = 1382 ( date_part 11 10 14 1 0 0 0 f f f f t f s 2 0 701 "25 702" _null_ _null_ _null_ _null_ "select pg_catalog.date_part($1, cast($2 as timestamp with time zone))" _null_ _null_ _null_ ) +insert OID = 1383 ( date_part 11 10 14 1 0 0 0 f f f f t f s 2 0 701 "25 703" _null_ _null_ _null_ _null_ "select pg_catalog.date_part($1, cast($2 as pg_catalog.interval))" _null_ _null_ _null_ ) +insert OID = 1384 ( date_part 11 10 14 1 0 0 0 f f f f t f i 2 0 701 "25 1082" _null_ _null_ _null_ _null_ "select pg_catalog.date_part($1, cast($2 as timestamp without time zone))" _null_ _null_ _null_ ) +insert OID = 1385 ( date_part 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "25 1083" _null_ _null_ _null_ _null_ time_part _null_ _null_ _null_ ) +insert OID = 1386 ( age 11 10 14 1 0 0 0 f f f f t f s 1 0 1186 "1184" _null_ _null_ _null_ _null_ "select pg_catalog.age(cast(current_date as timestamp with time zone), $1)" _null_ _null_ _null_ ) +insert OID = 1388 ( timetz 11 10 12 1 0 0 0 f f f f t f s 1 0 1266 "1184" _null_ _null_ _null_ _null_ timestamptz_timetz _null_ _null_ _null_ ) +insert OID = 1373 ( isfinite 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "1082" _null_ _null_ _null_ _null_ date_finite _null_ _null_ _null_ ) +insert OID = 1389 ( isfinite 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "1184" _null_ _null_ _null_ _null_ timestamp_finite _null_ _null_ _null_ ) +insert OID = 1390 ( isfinite 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "1186" _null_ _null_ _null_ _null_ interval_finite _null_ _null_ _null_ ) +insert OID = 1376 ( factorial 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "20" _null_ _null_ _null_ _null_ numeric_fac _null_ _null_ _null_ ) +insert OID = 1394 ( abs 11 10 12 1 0 0 0 f f f f t f i 1 0 700 "700" _null_ _null_ _null_ _null_ float4abs _null_ _null_ _null_ ) +insert OID = 1395 ( abs 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ float8abs _null_ _null_ _null_ ) +insert OID = 1396 ( abs 11 10 12 1 0 0 0 f f f f t f i 1 0 20 "20" _null_ _null_ _null_ _null_ int8abs _null_ _null_ _null_ ) +insert OID = 1397 ( abs 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "23" _null_ _null_ _null_ _null_ int4abs _null_ _null_ _null_ ) +insert OID = 1398 ( abs 11 10 12 1 0 0 0 f f f f t f i 1 0 21 "21" _null_ _null_ _null_ _null_ int2abs _null_ _null_ _null_ ) +insert OID = 1400 ( name 11 10 12 1 0 0 0 f f f f t f i 1 0 19 "1043" _null_ _null_ _null_ _null_ text_name _null_ _null_ _null_ ) +insert OID = 1401 ( varchar 11 10 12 1 0 0 0 f f f f t f i 1 0 1043 "19" _null_ _null_ _null_ _null_ name_text _null_ _null_ _null_ ) +insert OID = 1402 ( current_schema 11 10 12 1 0 0 0 f f f f t f s 0 0 19 "" _null_ _null_ _null_ _null_ current_schema _null_ _null_ _null_ ) +insert OID = 1403 ( current_schemas 11 10 12 1 0 0 0 f f f f t f s 1 0 1003 "16" _null_ _null_ _null_ _null_ current_schemas _null_ _null_ _null_ ) +insert OID = 1404 ( overlay 11 10 12 1 0 0 0 f f f f t f i 4 0 25 "25 25 23 23" _null_ _null_ _null_ _null_ textoverlay _null_ _null_ _null_ ) +insert OID = 1405 ( overlay 11 10 12 1 0 0 0 f f f f t f i 3 0 25 "25 25 23" _null_ _null_ _null_ _null_ textoverlay_no_len _null_ _null_ _null_ ) +insert OID = 1406 ( isvertical 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "600 600" _null_ _null_ _null_ _null_ point_vert _null_ _null_ _null_ ) +insert OID = 1407 ( ishorizontal 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "600 600" _null_ _null_ _null_ _null_ point_horiz _null_ _null_ _null_ ) +insert OID = 1408 ( isparallel 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "601 601" _null_ _null_ _null_ _null_ lseg_parallel _null_ _null_ _null_ ) +insert OID = 1409 ( isperp 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "601 601" _null_ _null_ _null_ _null_ lseg_perp _null_ _null_ _null_ ) +insert OID = 1410 ( isvertical 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "601" _null_ _null_ _null_ _null_ lseg_vertical _null_ _null_ _null_ ) +insert OID = 1411 ( ishorizontal 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "601" _null_ _null_ _null_ _null_ lseg_horizontal _null_ _null_ _null_ ) +insert OID = 1412 ( isparallel 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "628 628" _null_ _null_ _null_ _null_ line_parallel _null_ _null_ _null_ ) +insert OID = 1413 ( isperp 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "628 628" _null_ _null_ _null_ _null_ line_perp _null_ _null_ _null_ ) +insert OID = 1414 ( isvertical 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "628" _null_ _null_ _null_ _null_ line_vertical _null_ _null_ _null_ ) +insert OID = 1415 ( ishorizontal 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "628" _null_ _null_ _null_ _null_ line_horizontal _null_ _null_ _null_ ) +insert OID = 1416 ( point 11 10 12 1 0 0 0 f f f f t f i 1 0 600 "718" _null_ _null_ _null_ _null_ circle_center _null_ _null_ _null_ ) +insert OID = 1419 ( time 11 10 12 1 0 0 0 f f f f t f i 1 0 1083 "1186" _null_ _null_ _null_ _null_ interval_time _null_ _null_ _null_ ) +insert OID = 1421 ( box 11 10 12 1 0 0 0 f f f f t f i 2 0 603 "600 600" _null_ _null_ _null_ _null_ points_box _null_ _null_ _null_ ) +insert OID = 1422 ( box_add 11 10 12 1 0 0 0 f f f f t f i 2 0 603 "603 600" _null_ _null_ _null_ _null_ box_add _null_ _null_ _null_ ) +insert OID = 1423 ( box_sub 11 10 12 1 0 0 0 f f f f t f i 2 0 603 "603 600" _null_ _null_ _null_ _null_ box_sub _null_ _null_ _null_ ) +insert OID = 1424 ( box_mul 11 10 12 1 0 0 0 f f f f t f i 2 0 603 "603 600" _null_ _null_ _null_ _null_ box_mul _null_ _null_ _null_ ) +insert OID = 1425 ( box_div 11 10 12 1 0 0 0 f f f f t f i 2 0 603 "603 600" _null_ _null_ _null_ _null_ box_div _null_ _null_ _null_ ) +insert OID = 1426 ( path_contain_pt 11 10 14 1 0 0 0 f f f f t f i 2 0 16 "602 600" _null_ _null_ _null_ _null_ "select pg_catalog.on_ppath($2, $1)" _null_ _null_ _null_ ) +insert OID = 1428 ( poly_contain_pt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "604 600" _null_ _null_ _null_ _null_ poly_contain_pt _null_ _null_ _null_ ) +insert OID = 1429 ( pt_contained_poly 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "600 604" _null_ _null_ _null_ _null_ pt_contained_poly _null_ _null_ _null_ ) +insert OID = 1430 ( isclosed 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "602" _null_ _null_ _null_ _null_ path_isclosed _null_ _null_ _null_ ) +insert OID = 1431 ( isopen 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "602" _null_ _null_ _null_ _null_ path_isopen _null_ _null_ _null_ ) +insert OID = 1432 ( path_npoints 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "602" _null_ _null_ _null_ _null_ path_npoints _null_ _null_ _null_ ) +insert OID = 1433 ( pclose 11 10 12 1 0 0 0 f f f f t f i 1 0 602 "602" _null_ _null_ _null_ _null_ path_close _null_ _null_ _null_ ) +insert OID = 1434 ( popen 11 10 12 1 0 0 0 f f f f t f i 1 0 602 "602" _null_ _null_ _null_ _null_ path_open _null_ _null_ _null_ ) +insert OID = 1435 ( path_add 11 10 12 1 0 0 0 f f f f t f i 2 0 602 "602 602" _null_ _null_ _null_ _null_ path_add _null_ _null_ _null_ ) +insert OID = 1436 ( path_add_pt 11 10 12 1 0 0 0 f f f f t f i 2 0 602 "602 600" _null_ _null_ _null_ _null_ path_add_pt _null_ _null_ _null_ ) +insert OID = 1437 ( path_sub_pt 11 10 12 1 0 0 0 f f f f t f i 2 0 602 "602 600" _null_ _null_ _null_ _null_ path_sub_pt _null_ _null_ _null_ ) +insert OID = 1438 ( path_mul_pt 11 10 12 1 0 0 0 f f f f t f i 2 0 602 "602 600" _null_ _null_ _null_ _null_ path_mul_pt _null_ _null_ _null_ ) +insert OID = 1439 ( path_div_pt 11 10 12 1 0 0 0 f f f f t f i 2 0 602 "602 600" _null_ _null_ _null_ _null_ path_div_pt _null_ _null_ _null_ ) +insert OID = 1440 ( point 11 10 12 1 0 0 0 f f f f t f i 2 0 600 "701 701" _null_ _null_ _null_ _null_ construct_point _null_ _null_ _null_ ) +insert OID = 1441 ( point_add 11 10 12 1 0 0 0 f f f f t f i 2 0 600 "600 600" _null_ _null_ _null_ _null_ point_add _null_ _null_ _null_ ) +insert OID = 1442 ( point_sub 11 10 12 1 0 0 0 f f f f t f i 2 0 600 "600 600" _null_ _null_ _null_ _null_ point_sub _null_ _null_ _null_ ) +insert OID = 1443 ( point_mul 11 10 12 1 0 0 0 f f f f t f i 2 0 600 "600 600" _null_ _null_ _null_ _null_ point_mul _null_ _null_ _null_ ) +insert OID = 1444 ( point_div 11 10 12 1 0 0 0 f f f f t f i 2 0 600 "600 600" _null_ _null_ _null_ _null_ point_div _null_ _null_ _null_ ) +insert OID = 1445 ( poly_npoints 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "604" _null_ _null_ _null_ _null_ poly_npoints _null_ _null_ _null_ ) +insert OID = 1446 ( box 11 10 12 1 0 0 0 f f f f t f i 1 0 603 "604" _null_ _null_ _null_ _null_ poly_box _null_ _null_ _null_ ) +insert OID = 1447 ( path 11 10 12 1 0 0 0 f f f f t f i 1 0 602 "604" _null_ _null_ _null_ _null_ poly_path _null_ _null_ _null_ ) +insert OID = 1448 ( polygon 11 10 12 1 0 0 0 f f f f t f i 1 0 604 "603" _null_ _null_ _null_ _null_ box_poly _null_ _null_ _null_ ) +insert OID = 1449 ( polygon 11 10 12 1 0 0 0 f f f f t f i 1 0 604 "602" _null_ _null_ _null_ _null_ path_poly _null_ _null_ _null_ ) +insert OID = 1450 ( circle_in 11 10 12 1 0 0 0 f f f f t f i 1 0 718 "2275" _null_ _null_ _null_ _null_ circle_in _null_ _null_ _null_ ) +insert OID = 1451 ( circle_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "718" _null_ _null_ _null_ _null_ circle_out _null_ _null_ _null_ ) +insert OID = 1452 ( circle_same 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "718 718" _null_ _null_ _null_ _null_ circle_same _null_ _null_ _null_ ) +insert OID = 1453 ( circle_contain 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "718 718" _null_ _null_ _null_ _null_ circle_contain _null_ _null_ _null_ ) +insert OID = 1454 ( circle_left 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "718 718" _null_ _null_ _null_ _null_ circle_left _null_ _null_ _null_ ) +insert OID = 1455 ( circle_overleft 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "718 718" _null_ _null_ _null_ _null_ circle_overleft _null_ _null_ _null_ ) +insert OID = 1456 ( circle_overright 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "718 718" _null_ _null_ _null_ _null_ circle_overright _null_ _null_ _null_ ) +insert OID = 1457 ( circle_right 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "718 718" _null_ _null_ _null_ _null_ circle_right _null_ _null_ _null_ ) +insert OID = 1458 ( circle_contained 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "718 718" _null_ _null_ _null_ _null_ circle_contained _null_ _null_ _null_ ) +insert OID = 1459 ( circle_overlap 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "718 718" _null_ _null_ _null_ _null_ circle_overlap _null_ _null_ _null_ ) +insert OID = 1460 ( circle_below 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "718 718" _null_ _null_ _null_ _null_ circle_below _null_ _null_ _null_ ) +insert OID = 1461 ( circle_above 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "718 718" _null_ _null_ _null_ _null_ circle_above _null_ _null_ _null_ ) +insert OID = 1462 ( circle_eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "718 718" _null_ _null_ _null_ _null_ circle_eq _null_ _null_ _null_ ) +insert OID = 1463 ( circle_ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "718 718" _null_ _null_ _null_ _null_ circle_ne _null_ _null_ _null_ ) +insert OID = 1464 ( circle_lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "718 718" _null_ _null_ _null_ _null_ circle_lt _null_ _null_ _null_ ) +insert OID = 1465 ( circle_gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "718 718" _null_ _null_ _null_ _null_ circle_gt _null_ _null_ _null_ ) +insert OID = 1466 ( circle_le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "718 718" _null_ _null_ _null_ _null_ circle_le _null_ _null_ _null_ ) +insert OID = 1467 ( circle_ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "718 718" _null_ _null_ _null_ _null_ circle_ge _null_ _null_ _null_ ) +insert OID = 1468 ( area 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "718" _null_ _null_ _null_ _null_ circle_area _null_ _null_ _null_ ) +insert OID = 1469 ( diameter 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "718" _null_ _null_ _null_ _null_ circle_diameter _null_ _null_ _null_ ) +insert OID = 1470 ( radius 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "718" _null_ _null_ _null_ _null_ circle_radius _null_ _null_ _null_ ) +insert OID = 1471 ( circle_distance 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "718 718" _null_ _null_ _null_ _null_ circle_distance _null_ _null_ _null_ ) +insert OID = 1472 ( circle_center 11 10 12 1 0 0 0 f f f f t f i 1 0 600 "718" _null_ _null_ _null_ _null_ circle_center _null_ _null_ _null_ ) +insert OID = 1473 ( circle 11 10 12 1 0 0 0 f f f f t f i 2 0 718 "600 701" _null_ _null_ _null_ _null_ cr_circle _null_ _null_ _null_ ) +insert OID = 1474 ( circle 11 10 12 1 0 0 0 f f f f t f i 1 0 718 "604" _null_ _null_ _null_ _null_ poly_circle _null_ _null_ _null_ ) +insert OID = 1475 ( polygon 11 10 12 1 0 0 0 f f f f t f i 2 0 604 "23 718" _null_ _null_ _null_ _null_ circle_poly _null_ _null_ _null_ ) +insert OID = 1476 ( dist_pc 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "600 718" _null_ _null_ _null_ _null_ dist_pc _null_ _null_ _null_ ) +insert OID = 1477 ( circle_contain_pt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "718 600" _null_ _null_ _null_ _null_ circle_contain_pt _null_ _null_ _null_ ) +insert OID = 1478 ( pt_contained_circle 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "600 718" _null_ _null_ _null_ _null_ pt_contained_circle _null_ _null_ _null_ ) +insert OID = 1479 ( circle 11 10 12 1 0 0 0 f f f f t f i 1 0 718 "603" _null_ _null_ _null_ _null_ box_circle _null_ _null_ _null_ ) +insert OID = 1480 ( box 11 10 12 1 0 0 0 f f f f t f i 1 0 603 "718" _null_ _null_ _null_ _null_ circle_box _null_ _null_ _null_ ) +insert OID = 1481 ( tinterval 11 10 12 1 0 0 0 f f f f t f i 2 0 704 "702 702" _null_ _null_ _null_ _null_ mktinterval _null_ _null_ _null_ ) +insert OID = 1482 ( lseg_ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "601 601" _null_ _null_ _null_ _null_ lseg_ne _null_ _null_ _null_ ) +insert OID = 1483 ( lseg_lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "601 601" _null_ _null_ _null_ _null_ lseg_lt _null_ _null_ _null_ ) +insert OID = 1484 ( lseg_le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "601 601" _null_ _null_ _null_ _null_ lseg_le _null_ _null_ _null_ ) +insert OID = 1485 ( lseg_gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "601 601" _null_ _null_ _null_ _null_ lseg_gt _null_ _null_ _null_ ) +insert OID = 1486 ( lseg_ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "601 601" _null_ _null_ _null_ _null_ lseg_ge _null_ _null_ _null_ ) +insert OID = 1487 ( lseg_length 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "601" _null_ _null_ _null_ _null_ lseg_length _null_ _null_ _null_ ) +insert OID = 1488 ( close_ls 11 10 12 1 0 0 0 f f f f t f i 2 0 600 "628 601" _null_ _null_ _null_ _null_ close_ls _null_ _null_ _null_ ) +insert OID = 1489 ( close_lseg 11 10 12 1 0 0 0 f f f f t f i 2 0 600 "601 601" _null_ _null_ _null_ _null_ close_lseg _null_ _null_ _null_ ) +insert OID = 1490 ( line_in 11 10 12 1 0 0 0 f f f f t f i 1 0 628 "2275" _null_ _null_ _null_ _null_ line_in _null_ _null_ _null_ ) +insert OID = 1491 ( line_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "628" _null_ _null_ _null_ _null_ line_out _null_ _null_ _null_ ) +insert OID = 1492 ( line_eq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "628 628" _null_ _null_ _null_ _null_ line_eq _null_ _null_ _null_ ) +insert OID = 1493 ( line 11 10 12 1 0 0 0 f f f f t f i 2 0 628 "600 600" _null_ _null_ _null_ _null_ line_construct_pp _null_ _null_ _null_ ) +insert OID = 1494 ( line_interpt 11 10 12 1 0 0 0 f f f f t f i 2 0 600 "628 628" _null_ _null_ _null_ _null_ line_interpt _null_ _null_ _null_ ) +insert OID = 1495 ( line_intersect 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "628 628" _null_ _null_ _null_ _null_ line_intersect _null_ _null_ _null_ ) +insert OID = 1496 ( line_parallel 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "628 628" _null_ _null_ _null_ _null_ line_parallel _null_ _null_ _null_ ) +insert OID = 1497 ( line_perp 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "628 628" _null_ _null_ _null_ _null_ line_perp _null_ _null_ _null_ ) +insert OID = 1498 ( line_vertical 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "628" _null_ _null_ _null_ _null_ line_vertical _null_ _null_ _null_ ) +insert OID = 1499 ( line_horizontal 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "628" _null_ _null_ _null_ _null_ line_horizontal _null_ _null_ _null_ ) +insert OID = 1530 ( length 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "601" _null_ _null_ _null_ _null_ lseg_length _null_ _null_ _null_ ) +insert OID = 1531 ( length 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "602" _null_ _null_ _null_ _null_ path_length _null_ _null_ _null_ ) +insert OID = 1532 ( point 11 10 12 1 0 0 0 f f f f t f i 1 0 600 "601" _null_ _null_ _null_ _null_ lseg_center _null_ _null_ _null_ ) +insert OID = 1533 ( point 11 10 12 1 0 0 0 f f f f t f i 1 0 600 "602" _null_ _null_ _null_ _null_ path_center _null_ _null_ _null_ ) +insert OID = 1534 ( point 11 10 12 1 0 0 0 f f f f t f i 1 0 600 "603" _null_ _null_ _null_ _null_ box_center _null_ _null_ _null_ ) +insert OID = 1540 ( point 11 10 12 1 0 0 0 f f f f t f i 1 0 600 "604" _null_ _null_ _null_ _null_ poly_center _null_ _null_ _null_ ) +insert OID = 1541 ( lseg 11 10 12 1 0 0 0 f f f f t f i 1 0 601 "603" _null_ _null_ _null_ _null_ box_diagonal _null_ _null_ _null_ ) +insert OID = 1542 ( center 11 10 12 1 0 0 0 f f f f t f i 1 0 600 "603" _null_ _null_ _null_ _null_ box_center _null_ _null_ _null_ ) +insert OID = 1543 ( center 11 10 12 1 0 0 0 f f f f t f i 1 0 600 "718" _null_ _null_ _null_ _null_ circle_center _null_ _null_ _null_ ) +insert OID = 1544 ( polygon 11 10 14 1 0 0 0 f f f f t f i 1 0 604 "718" _null_ _null_ _null_ _null_ "select pg_catalog.polygon(12, $1)" _null_ _null_ _null_ ) +insert OID = 1545 ( npoints 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "602" _null_ _null_ _null_ _null_ path_npoints _null_ _null_ _null_ ) +insert OID = 1556 ( npoints 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "604" _null_ _null_ _null_ _null_ poly_npoints _null_ _null_ _null_ ) +insert OID = 1564 ( bit_in 11 10 12 1 0 0 0 f f f f t f i 3 0 1560 "2275 26 23" _null_ _null_ _null_ _null_ bit_in _null_ _null_ _null_ ) +insert OID = 1565 ( bit_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "1560" _null_ _null_ _null_ _null_ bit_out _null_ _null_ _null_ ) +insert OID = 2919 ( bittypmodin 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1263" _null_ _null_ _null_ _null_ bittypmodin _null_ _null_ _null_ ) +insert OID = 2920 ( bittypmodout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "23" _null_ _null_ _null_ _null_ bittypmodout _null_ _null_ _null_ ) +insert OID = 1569 ( like 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "25 25" _null_ _null_ _null_ _null_ textlike _null_ _null_ _null_ ) +insert OID = 1570 ( notlike 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "25 25" _null_ _null_ _null_ _null_ textnlike _null_ _null_ _null_ ) +insert OID = 1571 ( like 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "19 25" _null_ _null_ _null_ _null_ namelike _null_ _null_ _null_ ) +insert OID = 1572 ( notlike 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "19 25" _null_ _null_ _null_ _null_ namenlike _null_ _null_ _null_ ) +insert OID = 1574 ( nextval 11 10 12 1 0 0 0 f f f f t f v 1 0 20 "2205" _null_ _null_ _null_ _null_ nextval_oid _null_ _null_ _null_ ) +insert OID = 1575 ( currval 11 10 12 1 0 0 0 f f f f t f v 1 0 20 "2205" _null_ _null_ _null_ _null_ currval_oid _null_ _null_ _null_ ) +insert OID = 1576 ( setval 11 10 12 1 0 0 0 f f f f t f v 2 0 20 "2205 20" _null_ _null_ _null_ _null_ setval_oid _null_ _null_ _null_ ) +insert OID = 1765 ( setval 11 10 12 1 0 0 0 f f f f t f v 3 0 20 "2205 20 16" _null_ _null_ _null_ _null_ setval3_oid _null_ _null_ _null_ ) +insert OID = 3078 ( pg_sequence_parameters 11 10 12 1 0 0 0 f f f f t f s 1 0 2249 "26" "{23,20,20,20,20,16}" "{i,o,o,o,o,o}" "{sequence_oid,start_value,minimum_value,maximum_value,increment,cycle_option}" _null_ pg_sequence_parameters _null_ _null_ _null_) +insert OID = 1579 ( varbit_in 11 10 12 1 0 0 0 f f f f t f i 3 0 1562 "2275 26 23" _null_ _null_ _null_ _null_ varbit_in _null_ _null_ _null_ ) +insert OID = 1580 ( varbit_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "1562" _null_ _null_ _null_ _null_ varbit_out _null_ _null_ _null_ ) +insert OID = 2902 ( varbittypmodin 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1263" _null_ _null_ _null_ _null_ varbittypmodin _null_ _null_ _null_ ) +insert OID = 2921 ( varbittypmodout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "23" _null_ _null_ _null_ _null_ varbittypmodout _null_ _null_ _null_ ) +insert OID = 1581 ( biteq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1560 1560" _null_ _null_ _null_ _null_ biteq _null_ _null_ _null_ ) +insert OID = 1582 ( bitne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1560 1560" _null_ _null_ _null_ _null_ bitne _null_ _null_ _null_ ) +insert OID = 1592 ( bitge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1560 1560" _null_ _null_ _null_ _null_ bitge _null_ _null_ _null_ ) +insert OID = 1593 ( bitgt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1560 1560" _null_ _null_ _null_ _null_ bitgt _null_ _null_ _null_ ) +insert OID = 1594 ( bitle 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1560 1560" _null_ _null_ _null_ _null_ bitle _null_ _null_ _null_ ) +insert OID = 1595 ( bitlt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1560 1560" _null_ _null_ _null_ _null_ bitlt _null_ _null_ _null_ ) +insert OID = 1596 ( bitcmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "1560 1560" _null_ _null_ _null_ _null_ bitcmp _null_ _null_ _null_ ) +insert OID = 1598 ( random 11 10 12 1 0 0 0 f f f f t f v 0 0 701 "" _null_ _null_ _null_ _null_ drandom _null_ _null_ _null_ ) +insert OID = 1599 ( setseed 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "701" _null_ _null_ _null_ _null_ setseed _null_ _null_ _null_ ) +insert OID = 1600 ( asin 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ dasin _null_ _null_ _null_ ) +insert OID = 1601 ( acos 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ dacos _null_ _null_ _null_ ) +insert OID = 1602 ( atan 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ datan _null_ _null_ _null_ ) +insert OID = 1603 ( atan2 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "701 701" _null_ _null_ _null_ _null_ datan2 _null_ _null_ _null_ ) +insert OID = 1604 ( sin 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ dsin _null_ _null_ _null_ ) +insert OID = 1605 ( cos 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ dcos _null_ _null_ _null_ ) +insert OID = 1606 ( tan 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ dtan _null_ _null_ _null_ ) +insert OID = 1607 ( cot 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ dcot _null_ _null_ _null_ ) +insert OID = 1608 ( degrees 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ degrees _null_ _null_ _null_ ) +insert OID = 1609 ( radians 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ radians _null_ _null_ _null_ ) +insert OID = 1610 ( pi 11 10 12 1 0 0 0 f f f f t f i 0 0 701 "" _null_ _null_ _null_ _null_ dpi _null_ _null_ _null_ ) +insert OID = 1618 ( interval_mul 11 10 12 1 0 0 0 f f f f t f i 2 0 1186 "1186 701" _null_ _null_ _null_ _null_ interval_mul _null_ _null_ _null_ ) +insert OID = 1620 ( ascii 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "25" _null_ _null_ _null_ _null_ ascii _null_ _null_ _null_ ) +insert OID = 1621 ( chr 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "23" _null_ _null_ _null_ _null_ chr _null_ _null_ _null_ ) +insert OID = 1622 ( repeat 11 10 12 1 0 0 0 f f f f t f i 2 0 25 "25 23" _null_ _null_ _null_ _null_ repeat _null_ _null_ _null_ ) +insert OID = 1623 ( similar_escape 11 10 12 1 0 0 0 f f f f f f i 2 0 25 "25 25" _null_ _null_ _null_ _null_ similar_escape _null_ _null_ _null_ ) +insert OID = 1624 ( mul_d_interval 11 10 12 1 0 0 0 f f f f t f i 2 0 1186 "701 1186" _null_ _null_ _null_ _null_ mul_d_interval _null_ _null_ _null_ ) +insert OID = 1631 ( bpcharlike 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1042 25" _null_ _null_ _null_ _null_ textlike _null_ _null_ _null_ ) +insert OID = 1632 ( bpcharnlike 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1042 25" _null_ _null_ _null_ _null_ textnlike _null_ _null_ _null_ ) +insert OID = 1633 ( texticlike 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "25 25" _null_ _null_ _null_ _null_ texticlike _null_ _null_ _null_ ) +insert OID = 1634 ( texticnlike 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "25 25" _null_ _null_ _null_ _null_ texticnlike _null_ _null_ _null_ ) +insert OID = 1635 ( nameiclike 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "19 25" _null_ _null_ _null_ _null_ nameiclike _null_ _null_ _null_ ) +insert OID = 1636 ( nameicnlike 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "19 25" _null_ _null_ _null_ _null_ nameicnlike _null_ _null_ _null_ ) +insert OID = 1637 ( like_escape 11 10 12 1 0 0 0 f f f f t f i 2 0 25 "25 25" _null_ _null_ _null_ _null_ like_escape _null_ _null_ _null_ ) +insert OID = 1656 ( bpcharicregexeq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1042 25" _null_ _null_ _null_ _null_ texticregexeq _null_ _null_ _null_ ) +insert OID = 1657 ( bpcharicregexne 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1042 25" _null_ _null_ _null_ _null_ texticregexne _null_ _null_ _null_ ) +insert OID = 1658 ( bpcharregexeq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1042 25" _null_ _null_ _null_ _null_ textregexeq _null_ _null_ _null_ ) +insert OID = 1659 ( bpcharregexne 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1042 25" _null_ _null_ _null_ _null_ textregexne _null_ _null_ _null_ ) +insert OID = 1660 ( bpchariclike 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1042 25" _null_ _null_ _null_ _null_ texticlike _null_ _null_ _null_ ) +insert OID = 1661 ( bpcharicnlike 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1042 25" _null_ _null_ _null_ _null_ texticnlike _null_ _null_ _null_ ) +insert OID = 868 ( strpos 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "25 25" _null_ _null_ _null_ _null_ textpos _null_ _null_ _null_ ) +insert OID = 870 ( lower 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "25" _null_ _null_ _null_ _null_ lower _null_ _null_ _null_ ) +insert OID = 871 ( upper 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "25" _null_ _null_ _null_ _null_ upper _null_ _null_ _null_ ) +insert OID = 872 ( initcap 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "25" _null_ _null_ _null_ _null_ initcap _null_ _null_ _null_ ) +insert OID = 873 ( lpad 11 10 12 1 0 0 0 f f f f t f i 3 0 25 "25 23 25" _null_ _null_ _null_ _null_ lpad _null_ _null_ _null_ ) +insert OID = 874 ( rpad 11 10 12 1 0 0 0 f f f f t f i 3 0 25 "25 23 25" _null_ _null_ _null_ _null_ rpad _null_ _null_ _null_ ) +insert OID = 875 ( ltrim 11 10 12 1 0 0 0 f f f f t f i 2 0 25 "25 25" _null_ _null_ _null_ _null_ ltrim _null_ _null_ _null_ ) +insert OID = 876 ( rtrim 11 10 12 1 0 0 0 f f f f t f i 2 0 25 "25 25" _null_ _null_ _null_ _null_ rtrim _null_ _null_ _null_ ) +insert OID = 877 ( substr 11 10 12 1 0 0 0 f f f f t f i 3 0 25 "25 23 23" _null_ _null_ _null_ _null_ text_substr _null_ _null_ _null_ ) +insert OID = 878 ( translate 11 10 12 1 0 0 0 f f f f t f i 3 0 25 "25 25 25" _null_ _null_ _null_ _null_ translate _null_ _null_ _null_ ) +insert OID = 879 ( lpad 11 10 14 1 0 0 0 f f f f t f i 2 0 25 "25 23" _null_ _null_ _null_ _null_ "select pg_catalog.lpad($1, $2, '' '')" _null_ _null_ _null_ ) +insert OID = 880 ( rpad 11 10 14 1 0 0 0 f f f f t f i 2 0 25 "25 23" _null_ _null_ _null_ _null_ "select pg_catalog.rpad($1, $2, '' '')" _null_ _null_ _null_ ) +insert OID = 881 ( ltrim 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "25" _null_ _null_ _null_ _null_ ltrim1 _null_ _null_ _null_ ) +insert OID = 882 ( rtrim 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "25" _null_ _null_ _null_ _null_ rtrim1 _null_ _null_ _null_ ) +insert OID = 883 ( substr 11 10 12 1 0 0 0 f f f f t f i 2 0 25 "25 23" _null_ _null_ _null_ _null_ text_substr_no_len _null_ _null_ _null_ ) +insert OID = 884 ( btrim 11 10 12 1 0 0 0 f f f f t f i 2 0 25 "25 25" _null_ _null_ _null_ _null_ btrim _null_ _null_ _null_ ) +insert OID = 885 ( btrim 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "25" _null_ _null_ _null_ _null_ btrim1 _null_ _null_ _null_ ) +insert OID = 936 ( substring 11 10 12 1 0 0 0 f f f f t f i 3 0 25 "25 23 23" _null_ _null_ _null_ _null_ text_substr _null_ _null_ _null_ ) +insert OID = 937 ( substring 11 10 12 1 0 0 0 f f f f t f i 2 0 25 "25 23" _null_ _null_ _null_ _null_ text_substr_no_len _null_ _null_ _null_ ) +insert OID = 2087 ( replace 11 10 12 1 0 0 0 f f f f t f i 3 0 25 "25 25 25" _null_ _null_ _null_ _null_ replace_text _null_ _null_ _null_ ) +insert OID = 2284 ( regexp_replace 11 10 12 1 0 0 0 f f f f t f i 3 0 25 "25 25 25" _null_ _null_ _null_ _null_ textregexreplace_noopt _null_ _null_ _null_ ) +insert OID = 2285 ( regexp_replace 11 10 12 1 0 0 0 f f f f t f i 4 0 25 "25 25 25 25" _null_ _null_ _null_ _null_ textregexreplace _null_ _null_ _null_ ) +insert OID = 2763 ( regexp_matches 11 10 12 1 1 0 0 f f f f t t i 2 0 1009 "25 25" _null_ _null_ _null_ _null_ regexp_matches_no_flags _null_ _null_ _null_ ) +insert OID = 2764 ( regexp_matches 11 10 12 1 10 0 0 f f f f t t i 3 0 1009 "25 25 25" _null_ _null_ _null_ _null_ regexp_matches _null_ _null_ _null_ ) +insert OID = 2088 ( split_part 11 10 12 1 0 0 0 f f f f t f i 3 0 25 "25 25 23" _null_ _null_ _null_ _null_ split_text _null_ _null_ _null_ ) +insert OID = 2765 ( regexp_split_to_table 11 10 12 1 1000 0 0 f f f f t t i 2 0 25 "25 25" _null_ _null_ _null_ _null_ regexp_split_to_table_no_flags _null_ _null_ _null_ ) +insert OID = 2766 ( regexp_split_to_table 11 10 12 1 1000 0 0 f f f f t t i 3 0 25 "25 25 25" _null_ _null_ _null_ _null_ regexp_split_to_table _null_ _null_ _null_ ) +insert OID = 2767 ( regexp_split_to_array 11 10 12 1 0 0 0 f f f f t f i 2 0 1009 "25 25" _null_ _null_ _null_ _null_ regexp_split_to_array_no_flags _null_ _null_ _null_ ) +insert OID = 2768 ( regexp_split_to_array 11 10 12 1 0 0 0 f f f f t f i 3 0 1009 "25 25 25" _null_ _null_ _null_ _null_ regexp_split_to_array _null_ _null_ _null_ ) +insert OID = 2089 ( to_hex 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "23" _null_ _null_ _null_ _null_ to_hex32 _null_ _null_ _null_ ) +insert OID = 2090 ( to_hex 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "20" _null_ _null_ _null_ _null_ to_hex64 _null_ _null_ _null_ ) +insert OID = 1039 ( getdatabaseencoding 11 10 12 1 0 0 0 f f f f t f s 0 0 19 "" _null_ _null_ _null_ _null_ getdatabaseencoding _null_ _null_ _null_ ) +insert OID = 810 ( pg_client_encoding 11 10 12 1 0 0 0 f f f f t f s 0 0 19 "" _null_ _null_ _null_ _null_ pg_client_encoding _null_ _null_ _null_ ) +insert OID = 1713 ( length 11 10 12 1 0 0 0 f f f f t f s 2 0 23 "17 19" _null_ _null_ _null_ _null_ length_in_encoding _null_ _null_ _null_ ) +insert OID = 1714 ( convert_from 11 10 12 1 0 0 0 f f f f t f s 2 0 25 "17 19" _null_ _null_ _null_ _null_ pg_convert_from _null_ _null_ _null_ ) +insert OID = 1717 ( convert_to 11 10 12 1 0 0 0 f f f f t f s 2 0 17 "25 19" _null_ _null_ _null_ _null_ pg_convert_to _null_ _null_ _null_ ) +insert OID = 1813 ( convert 11 10 12 1 0 0 0 f f f f t f s 3 0 17 "17 19 19" _null_ _null_ _null_ _null_ pg_convert _null_ _null_ _null_ ) +insert OID = 1264 ( pg_char_to_encoding 11 10 12 1 0 0 0 f f f f t f s 1 0 23 "19" _null_ _null_ _null_ _null_ PG_char_to_encoding _null_ _null_ _null_ ) +insert OID = 1597 ( pg_encoding_to_char 11 10 12 1 0 0 0 f f f f t f s 1 0 19 "23" _null_ _null_ _null_ _null_ PG_encoding_to_char _null_ _null_ _null_ ) +insert OID = 2319 ( pg_encoding_max_length 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "23" _null_ _null_ _null_ _null_ pg_encoding_max_length_sql _null_ _null_ _null_ ) +insert OID = 1638 ( oidgt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "26 26" _null_ _null_ _null_ _null_ oidgt _null_ _null_ _null_ ) +insert OID = 1639 ( oidge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "26 26" _null_ _null_ _null_ _null_ oidge _null_ _null_ _null_ ) +insert OID = 1573 ( pg_get_ruledef 11 10 12 1 0 0 0 f f f f t f s 1 0 25 "26" _null_ _null_ _null_ _null_ pg_get_ruledef _null_ _null_ _null_ ) +insert OID = 1640 ( pg_get_viewdef 11 10 12 1 0 0 0 f f f f t f s 1 0 25 "25" _null_ _null_ _null_ _null_ pg_get_viewdef_name _null_ _null_ _null_ ) +insert OID = 1641 ( pg_get_viewdef 11 10 12 1 0 0 0 f f f f t f s 1 0 25 "26" _null_ _null_ _null_ _null_ pg_get_viewdef _null_ _null_ _null_ ) +insert OID = 1642 ( pg_get_userbyid 11 10 12 1 0 0 0 f f f f t f s 1 0 19 "26" _null_ _null_ _null_ _null_ pg_get_userbyid _null_ _null_ _null_ ) +insert OID = 1643 ( pg_get_indexdef 11 10 12 1 0 0 0 f f f f t f s 1 0 25 "26" _null_ _null_ _null_ _null_ pg_get_indexdef _null_ _null_ _null_ ) +insert OID = 1662 ( pg_get_triggerdef 11 10 12 1 0 0 0 f f f f t f s 1 0 25 "26" _null_ _null_ _null_ _null_ pg_get_triggerdef _null_ _null_ _null_ ) +insert OID = 1387 ( pg_get_constraintdef 11 10 12 1 0 0 0 f f f f t f s 1 0 25 "26" _null_ _null_ _null_ _null_ pg_get_constraintdef _null_ _null_ _null_ ) +insert OID = 1716 ( pg_get_expr 11 10 12 1 0 0 0 f f f f t f s 2 0 25 "194 26" _null_ _null_ _null_ _null_ pg_get_expr _null_ _null_ _null_ ) +insert OID = 1665 ( pg_get_serial_sequence 11 10 12 1 0 0 0 f f f f t f s 2 0 25 "25 25" _null_ _null_ _null_ _null_ pg_get_serial_sequence _null_ _null_ _null_ ) +insert OID = 2098 ( pg_get_functiondef 11 10 12 1 0 0 0 f f f f t f s 1 0 25 "26" _null_ _null_ _null_ _null_ pg_get_functiondef _null_ _null_ _null_ ) +insert OID = 2162 ( pg_get_function_arguments 11 10 12 1 0 0 0 f f f f t f s 1 0 25 "26" _null_ _null_ _null_ _null_ pg_get_function_arguments _null_ _null_ _null_ ) +insert OID = 2232 ( pg_get_function_identity_arguments 11 10 12 1 0 0 0 f f f f t f s 1 0 25 "26" _null_ _null_ _null_ _null_ pg_get_function_identity_arguments _null_ _null_ _null_ ) +insert OID = 2165 ( pg_get_function_result 11 10 12 1 0 0 0 f f f f t f s 1 0 25 "26" _null_ _null_ _null_ _null_ pg_get_function_result _null_ _null_ _null_ ) +insert OID = 1686 ( pg_get_keywords 11 10 12 10 400 0 0 f f f f t t s 0 0 2249 "" "{25,18,25}" "{o,o,o}" "{word,catcode,catdesc}" _null_ pg_get_keywords _null_ _null_ _null_ ) +insert OID = 2289 ( pg_options_to_table 11 10 12 1 3 0 0 f f f f t t s 1 0 2249 "1009" "{1009,25,25}" "{i,o,o}" "{options_array,option_name,option_value}" _null_ pg_options_to_table _null_ _null_ _null_ ) +insert OID = 1619 ( pg_typeof 11 10 12 1 0 0 0 f f f f f f s 1 0 2206 "2276" _null_ _null_ _null_ _null_ pg_typeof _null_ _null_ _null_ ) +insert OID = 3162 ( pg_collation_for 11 10 12 1 0 0 0 f f f f f f s 1 0 25 "2276" _null_ _null_ _null_ _null_ pg_collation_for _null_ _null_ _null_ ) +insert OID = 1250 ( unique_key_recheck 11 10 12 1 0 0 0 f f f f t f v 0 0 2279 "" _null_ _null_ _null_ _null_ unique_key_recheck _null_ _null_ _null_ ) +insert OID = 1644 ( RI_FKey_check_ins 11 10 12 1 0 0 0 f f f f t f v 0 0 2279 "" _null_ _null_ _null_ _null_ RI_FKey_check_ins _null_ _null_ _null_ ) +insert OID = 1645 ( RI_FKey_check_upd 11 10 12 1 0 0 0 f f f f t f v 0 0 2279 "" _null_ _null_ _null_ _null_ RI_FKey_check_upd _null_ _null_ _null_ ) +insert OID = 1646 ( RI_FKey_cascade_del 11 10 12 1 0 0 0 f f f f t f v 0 0 2279 "" _null_ _null_ _null_ _null_ RI_FKey_cascade_del _null_ _null_ _null_ ) +insert OID = 1647 ( RI_FKey_cascade_upd 11 10 12 1 0 0 0 f f f f t f v 0 0 2279 "" _null_ _null_ _null_ _null_ RI_FKey_cascade_upd _null_ _null_ _null_ ) +insert OID = 1648 ( RI_FKey_restrict_del 11 10 12 1 0 0 0 f f f f t f v 0 0 2279 "" _null_ _null_ _null_ _null_ RI_FKey_restrict_del _null_ _null_ _null_ ) +insert OID = 1649 ( RI_FKey_restrict_upd 11 10 12 1 0 0 0 f f f f t f v 0 0 2279 "" _null_ _null_ _null_ _null_ RI_FKey_restrict_upd _null_ _null_ _null_ ) +insert OID = 1650 ( RI_FKey_setnull_del 11 10 12 1 0 0 0 f f f f t f v 0 0 2279 "" _null_ _null_ _null_ _null_ RI_FKey_setnull_del _null_ _null_ _null_ ) +insert OID = 1651 ( RI_FKey_setnull_upd 11 10 12 1 0 0 0 f f f f t f v 0 0 2279 "" _null_ _null_ _null_ _null_ RI_FKey_setnull_upd _null_ _null_ _null_ ) +insert OID = 1652 ( RI_FKey_setdefault_del 11 10 12 1 0 0 0 f f f f t f v 0 0 2279 "" _null_ _null_ _null_ _null_ RI_FKey_setdefault_del _null_ _null_ _null_ ) +insert OID = 1653 ( RI_FKey_setdefault_upd 11 10 12 1 0 0 0 f f f f t f v 0 0 2279 "" _null_ _null_ _null_ _null_ RI_FKey_setdefault_upd _null_ _null_ _null_ ) +insert OID = 1654 ( RI_FKey_noaction_del 11 10 12 1 0 0 0 f f f f t f v 0 0 2279 "" _null_ _null_ _null_ _null_ RI_FKey_noaction_del _null_ _null_ _null_ ) +insert OID = 1655 ( RI_FKey_noaction_upd 11 10 12 1 0 0 0 f f f f t f v 0 0 2279 "" _null_ _null_ _null_ _null_ RI_FKey_noaction_upd _null_ _null_ _null_ ) +insert OID = 1666 ( varbiteq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1562 1562" _null_ _null_ _null_ _null_ biteq _null_ _null_ _null_ ) +insert OID = 1667 ( varbitne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1562 1562" _null_ _null_ _null_ _null_ bitne _null_ _null_ _null_ ) +insert OID = 1668 ( varbitge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1562 1562" _null_ _null_ _null_ _null_ bitge _null_ _null_ _null_ ) +insert OID = 1669 ( varbitgt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1562 1562" _null_ _null_ _null_ _null_ bitgt _null_ _null_ _null_ ) +insert OID = 1670 ( varbitle 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1562 1562" _null_ _null_ _null_ _null_ bitle _null_ _null_ _null_ ) +insert OID = 1671 ( varbitlt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1562 1562" _null_ _null_ _null_ _null_ bitlt _null_ _null_ _null_ ) +insert OID = 1672 ( varbitcmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "1562 1562" _null_ _null_ _null_ _null_ bitcmp _null_ _null_ _null_ ) +insert OID = 1673 ( bitand 11 10 12 1 0 0 0 f f f f t f i 2 0 1560 "1560 1560" _null_ _null_ _null_ _null_ bit_and _null_ _null_ _null_ ) +insert OID = 1674 ( bitor 11 10 12 1 0 0 0 f f f f t f i 2 0 1560 "1560 1560" _null_ _null_ _null_ _null_ bit_or _null_ _null_ _null_ ) +insert OID = 1675 ( bitxor 11 10 12 1 0 0 0 f f f f t f i 2 0 1560 "1560 1560" _null_ _null_ _null_ _null_ bitxor _null_ _null_ _null_ ) +insert OID = 1676 ( bitnot 11 10 12 1 0 0 0 f f f f t f i 1 0 1560 "1560" _null_ _null_ _null_ _null_ bitnot _null_ _null_ _null_ ) +insert OID = 1677 ( bitshiftleft 11 10 12 1 0 0 0 f f f f t f i 2 0 1560 "1560 23" _null_ _null_ _null_ _null_ bitshiftleft _null_ _null_ _null_ ) +insert OID = 1678 ( bitshiftright 11 10 12 1 0 0 0 f f f f t f i 2 0 1560 "1560 23" _null_ _null_ _null_ _null_ bitshiftright _null_ _null_ _null_ ) +insert OID = 1679 ( bitcat 11 10 12 1 0 0 0 f f f f t f i 2 0 1562 "1562 1562" _null_ _null_ _null_ _null_ bitcat _null_ _null_ _null_ ) +insert OID = 1680 ( substring 11 10 12 1 0 0 0 f f f f t f i 3 0 1560 "1560 23 23" _null_ _null_ _null_ _null_ bitsubstr _null_ _null_ _null_ ) +insert OID = 1681 ( length 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1560" _null_ _null_ _null_ _null_ bitlength _null_ _null_ _null_ ) +insert OID = 1682 ( octet_length 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1560" _null_ _null_ _null_ _null_ bitoctetlength _null_ _null_ _null_ ) +insert OID = 1683 ( bit 11 10 12 1 0 0 0 f f f f t f i 2 0 1560 "23 23" _null_ _null_ _null_ _null_ bitfromint4 _null_ _null_ _null_ ) +insert OID = 1684 ( int4 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1560" _null_ _null_ _null_ _null_ bittoint4 _null_ _null_ _null_ ) +insert OID = 1685 ( bit 11 10 12 1 0 0 0 f f f f t f i 3 0 1560 "1560 23 16" _null_ _null_ _null_ _null_ bit _null_ _null_ _null_ ) +insert OID = 3158 ( varbit_transform 11 10 12 1 0 0 0 f f f f t f i 1 0 2281 "2281" _null_ _null_ _null_ _null_ varbit_transform _null_ _null_ _null_ ) +insert OID = 1687 ( varbit 11 10 12 1 0 0 varbit_transform f f f f t f i 3 0 1562 "1562 23 16" _null_ _null_ _null_ _null_ varbit _null_ _null_ _null_ ) +insert OID = 1698 ( position 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "1560 1560" _null_ _null_ _null_ _null_ bitposition _null_ _null_ _null_ ) +insert OID = 1699 ( substring 11 10 12 1 0 0 0 f f f f t f i 2 0 1560 "1560 23" _null_ _null_ _null_ _null_ bitsubstr_no_len _null_ _null_ _null_ ) +insert OID = 3030 ( overlay 11 10 12 1 0 0 0 f f f f t f i 4 0 1560 "1560 1560 23 23" _null_ _null_ _null_ _null_ bitoverlay _null_ _null_ _null_ ) +insert OID = 3031 ( overlay 11 10 12 1 0 0 0 f f f f t f i 3 0 1560 "1560 1560 23" _null_ _null_ _null_ _null_ bitoverlay_no_len _null_ _null_ _null_ ) +insert OID = 3032 ( get_bit 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "1560 23" _null_ _null_ _null_ _null_ bitgetbit _null_ _null_ _null_ ) +insert OID = 3033 ( set_bit 11 10 12 1 0 0 0 f f f f t f i 3 0 1560 "1560 23 23" _null_ _null_ _null_ _null_ bitsetbit _null_ _null_ _null_ ) +insert OID = 436 ( macaddr_in 11 10 12 1 0 0 0 f f f f t f i 1 0 829 "2275" _null_ _null_ _null_ _null_ macaddr_in _null_ _null_ _null_ ) +insert OID = 437 ( macaddr_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "829" _null_ _null_ _null_ _null_ macaddr_out _null_ _null_ _null_ ) +insert OID = 753 ( trunc 11 10 12 1 0 0 0 f f f f t f i 1 0 829 "829" _null_ _null_ _null_ _null_ macaddr_trunc _null_ _null_ _null_ ) +insert OID = 830 ( macaddr_eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "829 829" _null_ _null_ _null_ _null_ macaddr_eq _null_ _null_ _null_ ) +insert OID = 831 ( macaddr_lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "829 829" _null_ _null_ _null_ _null_ macaddr_lt _null_ _null_ _null_ ) +insert OID = 832 ( macaddr_le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "829 829" _null_ _null_ _null_ _null_ macaddr_le _null_ _null_ _null_ ) +insert OID = 833 ( macaddr_gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "829 829" _null_ _null_ _null_ _null_ macaddr_gt _null_ _null_ _null_ ) +insert OID = 834 ( macaddr_ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "829 829" _null_ _null_ _null_ _null_ macaddr_ge _null_ _null_ _null_ ) +insert OID = 835 ( macaddr_ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "829 829" _null_ _null_ _null_ _null_ macaddr_ne _null_ _null_ _null_ ) +insert OID = 836 ( macaddr_cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "829 829" _null_ _null_ _null_ _null_ macaddr_cmp _null_ _null_ _null_ ) +insert OID = 3144 ( macaddr_not 11 10 12 1 0 0 0 f f f f t f i 1 0 829 "829" _null_ _null_ _null_ _null_ macaddr_not _null_ _null_ _null_ ) +insert OID = 3145 ( macaddr_and 11 10 12 1 0 0 0 f f f f t f i 2 0 829 "829 829" _null_ _null_ _null_ _null_ macaddr_and _null_ _null_ _null_ ) +insert OID = 3146 ( macaddr_or 11 10 12 1 0 0 0 f f f f t f i 2 0 829 "829 829" _null_ _null_ _null_ _null_ macaddr_or _null_ _null_ _null_ ) +insert OID = 910 ( inet_in 11 10 12 1 0 0 0 f f f f t f i 1 0 869 "2275" _null_ _null_ _null_ _null_ inet_in _null_ _null_ _null_ ) +insert OID = 911 ( inet_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "869" _null_ _null_ _null_ _null_ inet_out _null_ _null_ _null_ ) +insert OID = 1267 ( cidr_in 11 10 12 1 0 0 0 f f f f t f i 1 0 650 "2275" _null_ _null_ _null_ _null_ cidr_in _null_ _null_ _null_ ) +insert OID = 1427 ( cidr_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "650" _null_ _null_ _null_ _null_ cidr_out _null_ _null_ _null_ ) +insert OID = 920 ( network_eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "869 869" _null_ _null_ _null_ _null_ network_eq _null_ _null_ _null_ ) +insert OID = 921 ( network_lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "869 869" _null_ _null_ _null_ _null_ network_lt _null_ _null_ _null_ ) +insert OID = 922 ( network_le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "869 869" _null_ _null_ _null_ _null_ network_le _null_ _null_ _null_ ) +insert OID = 923 ( network_gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "869 869" _null_ _null_ _null_ _null_ network_gt _null_ _null_ _null_ ) +insert OID = 924 ( network_ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "869 869" _null_ _null_ _null_ _null_ network_ge _null_ _null_ _null_ ) +insert OID = 925 ( network_ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "869 869" _null_ _null_ _null_ _null_ network_ne _null_ _null_ _null_ ) +insert OID = 926 ( network_cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "869 869" _null_ _null_ _null_ _null_ network_cmp _null_ _null_ _null_ ) +insert OID = 927 ( network_sub 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "869 869" _null_ _null_ _null_ _null_ network_sub _null_ _null_ _null_ ) +insert OID = 928 ( network_subeq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "869 869" _null_ _null_ _null_ _null_ network_subeq _null_ _null_ _null_ ) +insert OID = 929 ( network_sup 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "869 869" _null_ _null_ _null_ _null_ network_sup _null_ _null_ _null_ ) +insert OID = 930 ( network_supeq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "869 869" _null_ _null_ _null_ _null_ network_supeq _null_ _null_ _null_ ) +insert OID = 598 ( abbrev 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "869" _null_ _null_ _null_ _null_ inet_abbrev _null_ _null_ _null_ ) +insert OID = 599 ( abbrev 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "650" _null_ _null_ _null_ _null_ cidr_abbrev _null_ _null_ _null_ ) +insert OID = 605 ( set_masklen 11 10 12 1 0 0 0 f f f f t f i 2 0 869 "869 23" _null_ _null_ _null_ _null_ inet_set_masklen _null_ _null_ _null_ ) +insert OID = 635 ( set_masklen 11 10 12 1 0 0 0 f f f f t f i 2 0 650 "650 23" _null_ _null_ _null_ _null_ cidr_set_masklen _null_ _null_ _null_ ) +insert OID = 711 ( family 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "869" _null_ _null_ _null_ _null_ network_family _null_ _null_ _null_ ) +insert OID = 683 ( network 11 10 12 1 0 0 0 f f f f t f i 1 0 650 "869" _null_ _null_ _null_ _null_ network_network _null_ _null_ _null_ ) +insert OID = 696 ( netmask 11 10 12 1 0 0 0 f f f f t f i 1 0 869 "869" _null_ _null_ _null_ _null_ network_netmask _null_ _null_ _null_ ) +insert OID = 697 ( masklen 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "869" _null_ _null_ _null_ _null_ network_masklen _null_ _null_ _null_ ) +insert OID = 698 ( broadcast 11 10 12 1 0 0 0 f f f f t f i 1 0 869 "869" _null_ _null_ _null_ _null_ network_broadcast _null_ _null_ _null_ ) +insert OID = 699 ( host 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "869" _null_ _null_ _null_ _null_ network_host _null_ _null_ _null_ ) +insert OID = 730 ( text 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "869" _null_ _null_ _null_ _null_ network_show _null_ _null_ _null_ ) +insert OID = 1362 ( hostmask 11 10 12 1 0 0 0 f f f f t f i 1 0 869 "869" _null_ _null_ _null_ _null_ network_hostmask _null_ _null_ _null_ ) +insert OID = 1715 ( cidr 11 10 12 1 0 0 0 f f f f t f i 1 0 650 "869" _null_ _null_ _null_ _null_ inet_to_cidr _null_ _null_ _null_ ) +insert OID = 2196 ( inet_client_addr 11 10 12 1 0 0 0 f f f f f f s 0 0 869 "" _null_ _null_ _null_ _null_ inet_client_addr _null_ _null_ _null_ ) +insert OID = 2197 ( inet_client_port 11 10 12 1 0 0 0 f f f f f f s 0 0 23 "" _null_ _null_ _null_ _null_ inet_client_port _null_ _null_ _null_ ) +insert OID = 2198 ( inet_server_addr 11 10 12 1 0 0 0 f f f f f f s 0 0 869 "" _null_ _null_ _null_ _null_ inet_server_addr _null_ _null_ _null_ ) +insert OID = 2199 ( inet_server_port 11 10 12 1 0 0 0 f f f f f f s 0 0 23 "" _null_ _null_ _null_ _null_ inet_server_port _null_ _null_ _null_ ) +insert OID = 2627 ( inetnot 11 10 12 1 0 0 0 f f f f t f i 1 0 869 "869" _null_ _null_ _null_ _null_ inetnot _null_ _null_ _null_ ) +insert OID = 2628 ( inetand 11 10 12 1 0 0 0 f f f f t f i 2 0 869 "869 869" _null_ _null_ _null_ _null_ inetand _null_ _null_ _null_ ) +insert OID = 2629 ( inetor 11 10 12 1 0 0 0 f f f f t f i 2 0 869 "869 869" _null_ _null_ _null_ _null_ inetor _null_ _null_ _null_ ) +insert OID = 2630 ( inetpl 11 10 12 1 0 0 0 f f f f t f i 2 0 869 "869 20" _null_ _null_ _null_ _null_ inetpl _null_ _null_ _null_ ) +insert OID = 2631 ( int8pl_inet 11 10 14 1 0 0 0 f f f f t f i 2 0 869 "20 869" _null_ _null_ _null_ _null_ "select $2 + $1" _null_ _null_ _null_ ) +insert OID = 2632 ( inetmi_int8 11 10 12 1 0 0 0 f f f f t f i 2 0 869 "869 20" _null_ _null_ _null_ _null_ inetmi_int8 _null_ _null_ _null_ ) +insert OID = 2633 ( inetmi 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "869 869" _null_ _null_ _null_ _null_ inetmi _null_ _null_ _null_ ) +insert OID = 1690 ( time_mi_time 11 10 12 1 0 0 0 f f f f t f i 2 0 1186 "1083 1083" _null_ _null_ _null_ _null_ time_mi_time _null_ _null_ _null_ ) +insert OID = 1691 ( boolle 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "16 16" _null_ _null_ _null_ _null_ boolle _null_ _null_ _null_ ) +insert OID = 1692 ( boolge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "16 16" _null_ _null_ _null_ _null_ boolge _null_ _null_ _null_ ) +insert OID = 1693 ( btboolcmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "16 16" _null_ _null_ _null_ _null_ btboolcmp _null_ _null_ _null_ ) +insert OID = 1688 ( time_hash 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1083" _null_ _null_ _null_ _null_ time_hash _null_ _null_ _null_ ) +insert OID = 1696 ( timetz_hash 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1266" _null_ _null_ _null_ _null_ timetz_hash _null_ _null_ _null_ ) +insert OID = 1697 ( interval_hash 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1186" _null_ _null_ _null_ _null_ interval_hash _null_ _null_ _null_ ) +insert OID = 1701 ( numeric_in 11 10 12 1 0 0 0 f f f f t f i 3 0 1700 "2275 26 23" _null_ _null_ _null_ _null_ numeric_in _null_ _null_ _null_ ) +insert OID = 1702 ( numeric_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "1700" _null_ _null_ _null_ _null_ numeric_out _null_ _null_ _null_ ) +insert OID = 2917 ( numerictypmodin 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1263" _null_ _null_ _null_ _null_ numerictypmodin _null_ _null_ _null_ ) +insert OID = 2918 ( numerictypmodout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "23" _null_ _null_ _null_ _null_ numerictypmodout _null_ _null_ _null_ ) +insert OID = 3157 ( numeric_transform 11 10 12 1 0 0 0 f f f f t f i 1 0 2281 "2281" _null_ _null_ _null_ _null_ numeric_transform _null_ _null_ _null_ ) +insert OID = 1703 ( numeric 11 10 12 1 0 0 numeric_transform f f f f t f i 2 0 1700 "1700 23" _null_ _null_ _null_ _null_ numeric _null_ _null_ _null_ ) +insert OID = 1704 ( numeric_abs 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ numeric_abs _null_ _null_ _null_ ) +insert OID = 1705 ( abs 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ numeric_abs _null_ _null_ _null_ ) +insert OID = 1706 ( sign 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ numeric_sign _null_ _null_ _null_ ) +insert OID = 1707 ( round 11 10 12 1 0 0 0 f f f f t f i 2 0 1700 "1700 23" _null_ _null_ _null_ _null_ numeric_round _null_ _null_ _null_ ) +insert OID = 1708 ( round 11 10 14 1 0 0 0 f f f f t f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ "select pg_catalog.round($1,0)" _null_ _null_ _null_ ) +insert OID = 1709 ( trunc 11 10 12 1 0 0 0 f f f f t f i 2 0 1700 "1700 23" _null_ _null_ _null_ _null_ numeric_trunc _null_ _null_ _null_ ) +insert OID = 1710 ( trunc 11 10 14 1 0 0 0 f f f f t f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ "select pg_catalog.trunc($1,0)" _null_ _null_ _null_ ) +insert OID = 1711 ( ceil 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ numeric_ceil _null_ _null_ _null_ ) +insert OID = 2167 ( ceiling 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ numeric_ceil _null_ _null_ _null_ ) +insert OID = 1712 ( floor 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ numeric_floor _null_ _null_ _null_ ) +insert OID = 1718 ( numeric_eq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1700 1700" _null_ _null_ _null_ _null_ numeric_eq _null_ _null_ _null_ ) +insert OID = 1719 ( numeric_ne 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1700 1700" _null_ _null_ _null_ _null_ numeric_ne _null_ _null_ _null_ ) +insert OID = 1720 ( numeric_gt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1700 1700" _null_ _null_ _null_ _null_ numeric_gt _null_ _null_ _null_ ) +insert OID = 1721 ( numeric_ge 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1700 1700" _null_ _null_ _null_ _null_ numeric_ge _null_ _null_ _null_ ) +insert OID = 1722 ( numeric_lt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1700 1700" _null_ _null_ _null_ _null_ numeric_lt _null_ _null_ _null_ ) +insert OID = 1723 ( numeric_le 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1700 1700" _null_ _null_ _null_ _null_ numeric_le _null_ _null_ _null_ ) +insert OID = 1724 ( numeric_add 11 10 12 1 0 0 0 f f f f t f i 2 0 1700 "1700 1700" _null_ _null_ _null_ _null_ numeric_add _null_ _null_ _null_ ) +insert OID = 1725 ( numeric_sub 11 10 12 1 0 0 0 f f f f t f i 2 0 1700 "1700 1700" _null_ _null_ _null_ _null_ numeric_sub _null_ _null_ _null_ ) +insert OID = 1726 ( numeric_mul 11 10 12 1 0 0 0 f f f f t f i 2 0 1700 "1700 1700" _null_ _null_ _null_ _null_ numeric_mul _null_ _null_ _null_ ) +insert OID = 1727 ( numeric_div 11 10 12 1 0 0 0 f f f f t f i 2 0 1700 "1700 1700" _null_ _null_ _null_ _null_ numeric_div _null_ _null_ _null_ ) +insert OID = 1728 ( mod 11 10 12 1 0 0 0 f f f f t f i 2 0 1700 "1700 1700" _null_ _null_ _null_ _null_ numeric_mod _null_ _null_ _null_ ) +insert OID = 1729 ( numeric_mod 11 10 12 1 0 0 0 f f f f t f i 2 0 1700 "1700 1700" _null_ _null_ _null_ _null_ numeric_mod _null_ _null_ _null_ ) +insert OID = 1730 ( sqrt 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ numeric_sqrt _null_ _null_ _null_ ) +insert OID = 1731 ( numeric_sqrt 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ numeric_sqrt _null_ _null_ _null_ ) +insert OID = 1732 ( exp 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ numeric_exp _null_ _null_ _null_ ) +insert OID = 1733 ( numeric_exp 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ numeric_exp _null_ _null_ _null_ ) +insert OID = 1734 ( ln 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ numeric_ln _null_ _null_ _null_ ) +insert OID = 1735 ( numeric_ln 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ numeric_ln _null_ _null_ _null_ ) +insert OID = 1736 ( log 11 10 12 1 0 0 0 f f f f t f i 2 0 1700 "1700 1700" _null_ _null_ _null_ _null_ numeric_log _null_ _null_ _null_ ) +insert OID = 1737 ( numeric_log 11 10 12 1 0 0 0 f f f f t f i 2 0 1700 "1700 1700" _null_ _null_ _null_ _null_ numeric_log _null_ _null_ _null_ ) +insert OID = 1738 ( pow 11 10 12 1 0 0 0 f f f f t f i 2 0 1700 "1700 1700" _null_ _null_ _null_ _null_ numeric_power _null_ _null_ _null_ ) +insert OID = 2169 ( power 11 10 12 1 0 0 0 f f f f t f i 2 0 1700 "1700 1700" _null_ _null_ _null_ _null_ numeric_power _null_ _null_ _null_ ) +insert OID = 1739 ( numeric_power 11 10 12 1 0 0 0 f f f f t f i 2 0 1700 "1700 1700" _null_ _null_ _null_ _null_ numeric_power _null_ _null_ _null_ ) +insert OID = 1740 ( numeric 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "23" _null_ _null_ _null_ _null_ int4_numeric _null_ _null_ _null_ ) +insert OID = 1741 ( log 11 10 14 1 0 0 0 f f f f t f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ "select pg_catalog.log(10, $1)" _null_ _null_ _null_ ) +insert OID = 1742 ( numeric 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "700" _null_ _null_ _null_ _null_ float4_numeric _null_ _null_ _null_ ) +insert OID = 1743 ( numeric 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "701" _null_ _null_ _null_ _null_ float8_numeric _null_ _null_ _null_ ) +insert OID = 1744 ( int4 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1700" _null_ _null_ _null_ _null_ numeric_int4 _null_ _null_ _null_ ) +insert OID = 1745 ( float4 11 10 12 1 0 0 0 f f f f t f i 1 0 700 "1700" _null_ _null_ _null_ _null_ numeric_float4 _null_ _null_ _null_ ) +insert OID = 1746 ( float8 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "1700" _null_ _null_ _null_ _null_ numeric_float8 _null_ _null_ _null_ ) +insert OID = 1973 ( div 11 10 12 1 0 0 0 f f f f t f i 2 0 1700 "1700 1700" _null_ _null_ _null_ _null_ numeric_div_trunc _null_ _null_ _null_ ) +insert OID = 1980 ( numeric_div_trunc 11 10 12 1 0 0 0 f f f f t f i 2 0 1700 "1700 1700" _null_ _null_ _null_ _null_ numeric_div_trunc _null_ _null_ _null_ ) +insert OID = 2170 ( width_bucket 11 10 12 1 0 0 0 f f f f t f i 4 0 23 "1700 1700 1700 23" _null_ _null_ _null_ _null_ width_bucket_numeric _null_ _null_ _null_ ) +insert OID = 1747 ( time_pl_interval 11 10 12 1 0 0 0 f f f f t f i 2 0 1083 "1083 1186" _null_ _null_ _null_ _null_ time_pl_interval _null_ _null_ _null_ ) +insert OID = 1748 ( time_mi_interval 11 10 12 1 0 0 0 f f f f t f i 2 0 1083 "1083 1186" _null_ _null_ _null_ _null_ time_mi_interval _null_ _null_ _null_ ) +insert OID = 1749 ( timetz_pl_interval 11 10 12 1 0 0 0 f f f f t f i 2 0 1266 "1266 1186" _null_ _null_ _null_ _null_ timetz_pl_interval _null_ _null_ _null_ ) +insert OID = 1750 ( timetz_mi_interval 11 10 12 1 0 0 0 f f f f t f i 2 0 1266 "1266 1186" _null_ _null_ _null_ _null_ timetz_mi_interval _null_ _null_ _null_ ) +insert OID = 1764 ( numeric_inc 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ numeric_inc _null_ _null_ _null_ ) +insert OID = 1766 ( numeric_smaller 11 10 12 1 0 0 0 f f f f t f i 2 0 1700 "1700 1700" _null_ _null_ _null_ _null_ numeric_smaller _null_ _null_ _null_ ) +insert OID = 1767 ( numeric_larger 11 10 12 1 0 0 0 f f f f t f i 2 0 1700 "1700 1700" _null_ _null_ _null_ _null_ numeric_larger _null_ _null_ _null_ ) +insert OID = 1769 ( numeric_cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "1700 1700" _null_ _null_ _null_ _null_ numeric_cmp _null_ _null_ _null_ ) +insert OID = 1771 ( numeric_uminus 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ numeric_uminus _null_ _null_ _null_ ) +insert OID = 1779 ( int8 11 10 12 1 0 0 0 f f f f t f i 1 0 20 "1700" _null_ _null_ _null_ _null_ numeric_int8 _null_ _null_ _null_ ) +insert OID = 1781 ( numeric 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "20" _null_ _null_ _null_ _null_ int8_numeric _null_ _null_ _null_ ) +insert OID = 1782 ( numeric 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "21" _null_ _null_ _null_ _null_ int2_numeric _null_ _null_ _null_ ) +insert OID = 1783 ( int2 11 10 12 1 0 0 0 f f f f t f i 1 0 21 "1700" _null_ _null_ _null_ _null_ numeric_int2 _null_ _null_ _null_ ) +insert OID = 1770 ( to_char 11 10 12 1 0 0 0 f f f f t f s 2 0 25 "1184 25" _null_ _null_ _null_ _null_ timestamptz_to_char _null_ _null_ _null_ ) +insert OID = 1772 ( to_char 11 10 12 1 0 0 0 f f f f t f s 2 0 25 "1700 25" _null_ _null_ _null_ _null_ numeric_to_char _null_ _null_ _null_ ) +insert OID = 1773 ( to_char 11 10 12 1 0 0 0 f f f f t f s 2 0 25 "23 25" _null_ _null_ _null_ _null_ int4_to_char _null_ _null_ _null_ ) +insert OID = 1774 ( to_char 11 10 12 1 0 0 0 f f f f t f s 2 0 25 "20 25" _null_ _null_ _null_ _null_ int8_to_char _null_ _null_ _null_ ) +insert OID = 1775 ( to_char 11 10 12 1 0 0 0 f f f f t f s 2 0 25 "700 25" _null_ _null_ _null_ _null_ float4_to_char _null_ _null_ _null_ ) +insert OID = 1776 ( to_char 11 10 12 1 0 0 0 f f f f t f s 2 0 25 "701 25" _null_ _null_ _null_ _null_ float8_to_char _null_ _null_ _null_ ) +insert OID = 1777 ( to_number 11 10 12 1 0 0 0 f f f f t f s 2 0 1700 "25 25" _null_ _null_ _null_ _null_ numeric_to_number _null_ _null_ _null_ ) +insert OID = 1778 ( to_timestamp 11 10 12 1 0 0 0 f f f f t f s 2 0 1184 "25 25" _null_ _null_ _null_ _null_ to_timestamp _null_ _null_ _null_ ) +insert OID = 1780 ( to_date 11 10 12 1 0 0 0 f f f f t f s 2 0 1082 "25 25" _null_ _null_ _null_ _null_ to_date _null_ _null_ _null_ ) +insert OID = 1768 ( to_char 11 10 12 1 0 0 0 f f f f t f s 2 0 25 "1186 25" _null_ _null_ _null_ _null_ interval_to_char _null_ _null_ _null_ ) +insert OID = 1282 ( quote_ident 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "25" _null_ _null_ _null_ _null_ quote_ident _null_ _null_ _null_ ) +insert OID = 1283 ( quote_literal 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "25" _null_ _null_ _null_ _null_ quote_literal _null_ _null_ _null_ ) +insert OID = 1285 ( quote_literal 11 10 14 1 0 0 0 f f f f t f s 1 0 25 "2283" _null_ _null_ _null_ _null_ "select pg_catalog.quote_literal($1::pg_catalog.text)" _null_ _null_ _null_ ) +insert OID = 1289 ( quote_nullable 11 10 12 1 0 0 0 f f f f f f i 1 0 25 "25" _null_ _null_ _null_ _null_ quote_nullable _null_ _null_ _null_ ) +insert OID = 1290 ( quote_nullable 11 10 14 1 0 0 0 f f f f f f s 1 0 25 "2283" _null_ _null_ _null_ _null_ "select pg_catalog.quote_nullable($1::pg_catalog.text)" _null_ _null_ _null_ ) +insert OID = 1798 ( oidin 11 10 12 1 0 0 0 f f f f t f i 1 0 26 "2275" _null_ _null_ _null_ _null_ oidin _null_ _null_ _null_ ) +insert OID = 1799 ( oidout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "26" _null_ _null_ _null_ _null_ oidout _null_ _null_ _null_ ) +insert OID = 3058 ( concat 11 10 12 1 0 2276 0 f f f f f f s 1 0 25 "2276" "{2276}" "{v}" _null_ _null_ text_concat _null_ _null_ _null_ ) +insert OID = 3059 ( concat_ws 11 10 12 1 0 2276 0 f f f f f f s 2 0 25 "25 2276" "{25,2276}" "{i,v}" _null_ _null_ text_concat_ws _null_ _null_ _null_ ) +insert OID = 3060 ( left 11 10 12 1 0 0 0 f f f f t f i 2 0 25 "25 23" _null_ _null_ _null_ _null_ text_left _null_ _null_ _null_ ) +insert OID = 3061 ( right 11 10 12 1 0 0 0 f f f f t f i 2 0 25 "25 23" _null_ _null_ _null_ _null_ text_right _null_ _null_ _null_ ) +insert OID = 3062 ( reverse 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "25" _null_ _null_ _null_ _null_ text_reverse _null_ _null_ _null_ ) +insert OID = 3539 ( format 11 10 12 1 0 2276 0 f f f f f f s 2 0 25 "25 2276" "{25,2276}" "{i,v}" _null_ _null_ text_format _null_ _null_ _null_ ) +insert OID = 3540 ( format 11 10 12 1 0 0 0 f f f f f f s 1 0 25 "25" _null_ _null_ _null_ _null_ text_format_nv _null_ _null_ _null_ ) +insert OID = 1810 ( bit_length 11 10 14 1 0 0 0 f f f f t f i 1 0 23 "17" _null_ _null_ _null_ _null_ "select pg_catalog.octet_length($1) * 8" _null_ _null_ _null_ ) +insert OID = 1811 ( bit_length 11 10 14 1 0 0 0 f f f f t f i 1 0 23 "25" _null_ _null_ _null_ _null_ "select pg_catalog.octet_length($1) * 8" _null_ _null_ _null_ ) +insert OID = 1812 ( bit_length 11 10 14 1 0 0 0 f f f f t f i 1 0 23 "1560" _null_ _null_ _null_ _null_ "select pg_catalog.length($1)" _null_ _null_ _null_ ) +insert OID = 1814 ( iclikesel 11 10 12 1 0 0 0 f f f f t f s 4 0 701 "2281 26 2281 23" _null_ _null_ _null_ _null_ iclikesel _null_ _null_ _null_ ) +insert OID = 1815 ( icnlikesel 11 10 12 1 0 0 0 f f f f t f s 4 0 701 "2281 26 2281 23" _null_ _null_ _null_ _null_ icnlikesel _null_ _null_ _null_ ) +insert OID = 1816 ( iclikejoinsel 11 10 12 1 0 0 0 f f f f t f s 5 0 701 "2281 26 2281 21 2281" _null_ _null_ _null_ _null_ iclikejoinsel _null_ _null_ _null_ ) +insert OID = 1817 ( icnlikejoinsel 11 10 12 1 0 0 0 f f f f t f s 5 0 701 "2281 26 2281 21 2281" _null_ _null_ _null_ _null_ icnlikejoinsel _null_ _null_ _null_ ) +insert OID = 1818 ( regexeqsel 11 10 12 1 0 0 0 f f f f t f s 4 0 701 "2281 26 2281 23" _null_ _null_ _null_ _null_ regexeqsel _null_ _null_ _null_ ) +insert OID = 1819 ( likesel 11 10 12 1 0 0 0 f f f f t f s 4 0 701 "2281 26 2281 23" _null_ _null_ _null_ _null_ likesel _null_ _null_ _null_ ) +insert OID = 1820 ( icregexeqsel 11 10 12 1 0 0 0 f f f f t f s 4 0 701 "2281 26 2281 23" _null_ _null_ _null_ _null_ icregexeqsel _null_ _null_ _null_ ) +insert OID = 1821 ( regexnesel 11 10 12 1 0 0 0 f f f f t f s 4 0 701 "2281 26 2281 23" _null_ _null_ _null_ _null_ regexnesel _null_ _null_ _null_ ) +insert OID = 1822 ( nlikesel 11 10 12 1 0 0 0 f f f f t f s 4 0 701 "2281 26 2281 23" _null_ _null_ _null_ _null_ nlikesel _null_ _null_ _null_ ) +insert OID = 1823 ( icregexnesel 11 10 12 1 0 0 0 f f f f t f s 4 0 701 "2281 26 2281 23" _null_ _null_ _null_ _null_ icregexnesel _null_ _null_ _null_ ) +insert OID = 1824 ( regexeqjoinsel 11 10 12 1 0 0 0 f f f f t f s 5 0 701 "2281 26 2281 21 2281" _null_ _null_ _null_ _null_ regexeqjoinsel _null_ _null_ _null_ ) +insert OID = 1825 ( likejoinsel 11 10 12 1 0 0 0 f f f f t f s 5 0 701 "2281 26 2281 21 2281" _null_ _null_ _null_ _null_ likejoinsel _null_ _null_ _null_ ) +insert OID = 1826 ( icregexeqjoinsel 11 10 12 1 0 0 0 f f f f t f s 5 0 701 "2281 26 2281 21 2281" _null_ _null_ _null_ _null_ icregexeqjoinsel _null_ _null_ _null_ ) +insert OID = 1827 ( regexnejoinsel 11 10 12 1 0 0 0 f f f f t f s 5 0 701 "2281 26 2281 21 2281" _null_ _null_ _null_ _null_ regexnejoinsel _null_ _null_ _null_ ) +insert OID = 1828 ( nlikejoinsel 11 10 12 1 0 0 0 f f f f t f s 5 0 701 "2281 26 2281 21 2281" _null_ _null_ _null_ _null_ nlikejoinsel _null_ _null_ _null_ ) +insert OID = 1829 ( icregexnejoinsel 11 10 12 1 0 0 0 f f f f t f s 5 0 701 "2281 26 2281 21 2281" _null_ _null_ _null_ _null_ icregexnejoinsel _null_ _null_ _null_ ) +insert OID = 1830 ( float8_avg 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "1022" _null_ _null_ _null_ _null_ float8_avg _null_ _null_ _null_ ) +insert OID = 2512 ( float8_var_pop 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "1022" _null_ _null_ _null_ _null_ float8_var_pop _null_ _null_ _null_ ) +insert OID = 1831 ( float8_var_samp 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "1022" _null_ _null_ _null_ _null_ float8_var_samp _null_ _null_ _null_ ) +insert OID = 2513 ( float8_stddev_pop 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "1022" _null_ _null_ _null_ _null_ float8_stddev_pop _null_ _null_ _null_ ) +insert OID = 1832 ( float8_stddev_samp 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "1022" _null_ _null_ _null_ _null_ float8_stddev_samp _null_ _null_ _null_ ) +insert OID = 1833 ( numeric_accum 11 10 12 1 0 0 0 f f f f t f i 2 0 1231 "1231 1700" _null_ _null_ _null_ _null_ numeric_accum _null_ _null_ _null_ ) +insert OID = 2858 ( numeric_avg_accum 11 10 12 1 0 0 0 f f f f t f i 2 0 1231 "1231 1700" _null_ _null_ _null_ _null_ numeric_avg_accum _null_ _null_ _null_ ) +insert OID = 1834 ( int2_accum 11 10 12 1 0 0 0 f f f f t f i 2 0 1231 "1231 21" _null_ _null_ _null_ _null_ int2_accum _null_ _null_ _null_ ) +insert OID = 1835 ( int4_accum 11 10 12 1 0 0 0 f f f f t f i 2 0 1231 "1231 23" _null_ _null_ _null_ _null_ int4_accum _null_ _null_ _null_ ) +insert OID = 1836 ( int8_accum 11 10 12 1 0 0 0 f f f f t f i 2 0 1231 "1231 20" _null_ _null_ _null_ _null_ int8_accum _null_ _null_ _null_ ) +insert OID = 2746 ( int8_avg_accum 11 10 12 1 0 0 0 f f f f t f i 2 0 1231 "1231 20" _null_ _null_ _null_ _null_ int8_avg_accum _null_ _null_ _null_ ) +insert OID = 1837 ( numeric_avg 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "1231" _null_ _null_ _null_ _null_ numeric_avg _null_ _null_ _null_ ) +insert OID = 2514 ( numeric_var_pop 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "1231" _null_ _null_ _null_ _null_ numeric_var_pop _null_ _null_ _null_ ) +insert OID = 1838 ( numeric_var_samp 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "1231" _null_ _null_ _null_ _null_ numeric_var_samp _null_ _null_ _null_ ) +insert OID = 2596 ( numeric_stddev_pop 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "1231" _null_ _null_ _null_ _null_ numeric_stddev_pop _null_ _null_ _null_ ) +insert OID = 1839 ( numeric_stddev_samp 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "1231" _null_ _null_ _null_ _null_ numeric_stddev_samp _null_ _null_ _null_ ) +insert OID = 1840 ( int2_sum 11 10 12 1 0 0 0 f f f f f f i 2 0 20 "20 21" _null_ _null_ _null_ _null_ int2_sum _null_ _null_ _null_ ) +insert OID = 1841 ( int4_sum 11 10 12 1 0 0 0 f f f f f f i 2 0 20 "20 23" _null_ _null_ _null_ _null_ int4_sum _null_ _null_ _null_ ) +insert OID = 1842 ( int8_sum 11 10 12 1 0 0 0 f f f f f f i 2 0 1700 "1700 20" _null_ _null_ _null_ _null_ int8_sum _null_ _null_ _null_ ) +insert OID = 1843 ( interval_accum 11 10 12 1 0 0 0 f f f f t f i 2 0 1187 "1187 1186" _null_ _null_ _null_ _null_ interval_accum _null_ _null_ _null_ ) +insert OID = 1844 ( interval_avg 11 10 12 1 0 0 0 f f f f t f i 1 0 1186 "1187" _null_ _null_ _null_ _null_ interval_avg _null_ _null_ _null_ ) +insert OID = 1962 ( int2_avg_accum 11 10 12 1 0 0 0 f f f f t f i 2 0 1016 "1016 21" _null_ _null_ _null_ _null_ int2_avg_accum _null_ _null_ _null_ ) +insert OID = 1963 ( int4_avg_accum 11 10 12 1 0 0 0 f f f f t f i 2 0 1016 "1016 23" _null_ _null_ _null_ _null_ int4_avg_accum _null_ _null_ _null_ ) +insert OID = 1964 ( int8_avg 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "1016" _null_ _null_ _null_ _null_ int8_avg _null_ _null_ _null_ ) +insert OID = 2805 ( int8inc_float8_float8 11 10 12 1 0 0 0 f f f f t f i 3 0 20 "20 701 701" _null_ _null_ _null_ _null_ int8inc_float8_float8 _null_ _null_ _null_ ) +insert OID = 2806 ( float8_regr_accum 11 10 12 1 0 0 0 f f f f t f i 3 0 1022 "1022 701 701" _null_ _null_ _null_ _null_ float8_regr_accum _null_ _null_ _null_ ) +insert OID = 2807 ( float8_regr_sxx 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "1022" _null_ _null_ _null_ _null_ float8_regr_sxx _null_ _null_ _null_ ) +insert OID = 2808 ( float8_regr_syy 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "1022" _null_ _null_ _null_ _null_ float8_regr_syy _null_ _null_ _null_ ) +insert OID = 2809 ( float8_regr_sxy 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "1022" _null_ _null_ _null_ _null_ float8_regr_sxy _null_ _null_ _null_ ) +insert OID = 2810 ( float8_regr_avgx 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "1022" _null_ _null_ _null_ _null_ float8_regr_avgx _null_ _null_ _null_ ) +insert OID = 2811 ( float8_regr_avgy 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "1022" _null_ _null_ _null_ _null_ float8_regr_avgy _null_ _null_ _null_ ) +insert OID = 2812 ( float8_regr_r2 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "1022" _null_ _null_ _null_ _null_ float8_regr_r2 _null_ _null_ _null_ ) +insert OID = 2813 ( float8_regr_slope 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "1022" _null_ _null_ _null_ _null_ float8_regr_slope _null_ _null_ _null_ ) +insert OID = 2814 ( float8_regr_intercept 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "1022" _null_ _null_ _null_ _null_ float8_regr_intercept _null_ _null_ _null_ ) +insert OID = 2815 ( float8_covar_pop 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "1022" _null_ _null_ _null_ _null_ float8_covar_pop _null_ _null_ _null_ ) +insert OID = 2816 ( float8_covar_samp 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "1022" _null_ _null_ _null_ _null_ float8_covar_samp _null_ _null_ _null_ ) +insert OID = 2817 ( float8_corr 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "1022" _null_ _null_ _null_ _null_ float8_corr _null_ _null_ _null_ ) +insert OID = 3535 ( string_agg_transfn 11 10 12 1 0 0 0 f f f f f f i 3 0 2281 "2281 25 25" _null_ _null_ _null_ _null_ string_agg_transfn _null_ _null_ _null_ ) +insert OID = 3536 ( string_agg_finalfn 11 10 12 1 0 0 0 f f f f f f i 1 0 25 "2281" _null_ _null_ _null_ _null_ string_agg_finalfn _null_ _null_ _null_ ) +insert OID = 3538 ( string_agg 11 10 12 1 0 0 0 t f f f f f i 2 0 25 "25 25" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 3543 ( bytea_string_agg_transfn 11 10 12 1 0 0 0 f f f f f f i 3 0 2281 "2281 17 17" _null_ _null_ _null_ _null_ bytea_string_agg_transfn _null_ _null_ _null_ ) +insert OID = 3544 ( bytea_string_agg_finalfn 11 10 12 1 0 0 0 f f f f f f i 1 0 17 "2281" _null_ _null_ _null_ _null_ bytea_string_agg_finalfn _null_ _null_ _null_ ) +insert OID = 3545 ( string_agg 11 10 12 1 0 0 0 t f f f f f i 2 0 17 "17 17" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 1845 ( to_ascii 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "25" _null_ _null_ _null_ _null_ to_ascii_default _null_ _null_ _null_ ) +insert OID = 1846 ( to_ascii 11 10 12 1 0 0 0 f f f f t f i 2 0 25 "25 23" _null_ _null_ _null_ _null_ to_ascii_enc _null_ _null_ _null_ ) +insert OID = 1847 ( to_ascii 11 10 12 1 0 0 0 f f f f t f i 2 0 25 "25 19" _null_ _null_ _null_ _null_ to_ascii_encname _null_ _null_ _null_ ) +insert OID = 1848 ( interval_pl_time 11 10 14 1 0 0 0 f f f f t f i 2 0 1083 "1186 1083" _null_ _null_ _null_ _null_ "select $2 + $1" _null_ _null_ _null_ ) +insert OID = 1850 ( int28eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "21 20" _null_ _null_ _null_ _null_ int28eq _null_ _null_ _null_ ) +insert OID = 1851 ( int28ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "21 20" _null_ _null_ _null_ _null_ int28ne _null_ _null_ _null_ ) +insert OID = 1852 ( int28lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "21 20" _null_ _null_ _null_ _null_ int28lt _null_ _null_ _null_ ) +insert OID = 1853 ( int28gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "21 20" _null_ _null_ _null_ _null_ int28gt _null_ _null_ _null_ ) +insert OID = 1854 ( int28le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "21 20" _null_ _null_ _null_ _null_ int28le _null_ _null_ _null_ ) +insert OID = 1855 ( int28ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "21 20" _null_ _null_ _null_ _null_ int28ge _null_ _null_ _null_ ) +insert OID = 1856 ( int82eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "20 21" _null_ _null_ _null_ _null_ int82eq _null_ _null_ _null_ ) +insert OID = 1857 ( int82ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "20 21" _null_ _null_ _null_ _null_ int82ne _null_ _null_ _null_ ) +insert OID = 1858 ( int82lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "20 21" _null_ _null_ _null_ _null_ int82lt _null_ _null_ _null_ ) +insert OID = 1859 ( int82gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "20 21" _null_ _null_ _null_ _null_ int82gt _null_ _null_ _null_ ) +insert OID = 1860 ( int82le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "20 21" _null_ _null_ _null_ _null_ int82le _null_ _null_ _null_ ) +insert OID = 1861 ( int82ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "20 21" _null_ _null_ _null_ _null_ int82ge _null_ _null_ _null_ ) +insert OID = 1892 ( int2and 11 10 12 1 0 0 0 f f f f t f i 2 0 21 "21 21" _null_ _null_ _null_ _null_ int2and _null_ _null_ _null_ ) +insert OID = 1893 ( int2or 11 10 12 1 0 0 0 f f f f t f i 2 0 21 "21 21" _null_ _null_ _null_ _null_ int2or _null_ _null_ _null_ ) +insert OID = 1894 ( int2xor 11 10 12 1 0 0 0 f f f f t f i 2 0 21 "21 21" _null_ _null_ _null_ _null_ int2xor _null_ _null_ _null_ ) +insert OID = 1895 ( int2not 11 10 12 1 0 0 0 f f f f t f i 1 0 21 "21" _null_ _null_ _null_ _null_ int2not _null_ _null_ _null_ ) +insert OID = 1896 ( int2shl 11 10 12 1 0 0 0 f f f f t f i 2 0 21 "21 23" _null_ _null_ _null_ _null_ int2shl _null_ _null_ _null_ ) +insert OID = 1897 ( int2shr 11 10 12 1 0 0 0 f f f f t f i 2 0 21 "21 23" _null_ _null_ _null_ _null_ int2shr _null_ _null_ _null_ ) +insert OID = 1898 ( int4and 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "23 23" _null_ _null_ _null_ _null_ int4and _null_ _null_ _null_ ) +insert OID = 1899 ( int4or 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "23 23" _null_ _null_ _null_ _null_ int4or _null_ _null_ _null_ ) +insert OID = 1900 ( int4xor 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "23 23" _null_ _null_ _null_ _null_ int4xor _null_ _null_ _null_ ) +insert OID = 1901 ( int4not 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "23" _null_ _null_ _null_ _null_ int4not _null_ _null_ _null_ ) +insert OID = 1902 ( int4shl 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "23 23" _null_ _null_ _null_ _null_ int4shl _null_ _null_ _null_ ) +insert OID = 1903 ( int4shr 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "23 23" _null_ _null_ _null_ _null_ int4shr _null_ _null_ _null_ ) +insert OID = 1904 ( int8and 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "20 20" _null_ _null_ _null_ _null_ int8and _null_ _null_ _null_ ) +insert OID = 1905 ( int8or 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "20 20" _null_ _null_ _null_ _null_ int8or _null_ _null_ _null_ ) +insert OID = 1906 ( int8xor 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "20 20" _null_ _null_ _null_ _null_ int8xor _null_ _null_ _null_ ) +insert OID = 1907 ( int8not 11 10 12 1 0 0 0 f f f f t f i 1 0 20 "20" _null_ _null_ _null_ _null_ int8not _null_ _null_ _null_ ) +insert OID = 1908 ( int8shl 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "20 23" _null_ _null_ _null_ _null_ int8shl _null_ _null_ _null_ ) +insert OID = 1909 ( int8shr 11 10 12 1 0 0 0 f f f f t f i 2 0 20 "20 23" _null_ _null_ _null_ _null_ int8shr _null_ _null_ _null_ ) +insert OID = 1910 ( int8up 11 10 12 1 0 0 0 f f f f t f i 1 0 20 "20" _null_ _null_ _null_ _null_ int8up _null_ _null_ _null_ ) +insert OID = 1911 ( int2up 11 10 12 1 0 0 0 f f f f t f i 1 0 21 "21" _null_ _null_ _null_ _null_ int2up _null_ _null_ _null_ ) +insert OID = 1912 ( int4up 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "23" _null_ _null_ _null_ _null_ int4up _null_ _null_ _null_ ) +insert OID = 1913 ( float4up 11 10 12 1 0 0 0 f f f f t f i 1 0 700 "700" _null_ _null_ _null_ _null_ float4up _null_ _null_ _null_ ) +insert OID = 1914 ( float8up 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "701" _null_ _null_ _null_ _null_ float8up _null_ _null_ _null_ ) +insert OID = 1915 ( numeric_uplus 11 10 12 1 0 0 0 f f f f t f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ numeric_uplus _null_ _null_ _null_ ) +insert OID = 1922 ( has_table_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "19 25 25" _null_ _null_ _null_ _null_ has_table_privilege_name_name _null_ _null_ _null_ ) +insert OID = 1923 ( has_table_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "19 26 25" _null_ _null_ _null_ _null_ has_table_privilege_name_id _null_ _null_ _null_ ) +insert OID = 1924 ( has_table_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "26 25 25" _null_ _null_ _null_ _null_ has_table_privilege_id_name _null_ _null_ _null_ ) +insert OID = 1925 ( has_table_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "26 26 25" _null_ _null_ _null_ _null_ has_table_privilege_id_id _null_ _null_ _null_ ) +insert OID = 1926 ( has_table_privilege 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "25 25" _null_ _null_ _null_ _null_ has_table_privilege_name _null_ _null_ _null_ ) +insert OID = 1927 ( has_table_privilege 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "26 25" _null_ _null_ _null_ _null_ has_table_privilege_id _null_ _null_ _null_ ) +insert OID = 2181 ( has_sequence_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "19 25 25" _null_ _null_ _null_ _null_ has_sequence_privilege_name_name _null_ _null_ _null_ ) +insert OID = 2182 ( has_sequence_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "19 26 25" _null_ _null_ _null_ _null_ has_sequence_privilege_name_id _null_ _null_ _null_ ) +insert OID = 2183 ( has_sequence_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "26 25 25" _null_ _null_ _null_ _null_ has_sequence_privilege_id_name _null_ _null_ _null_ ) +insert OID = 2184 ( has_sequence_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "26 26 25" _null_ _null_ _null_ _null_ has_sequence_privilege_id_id _null_ _null_ _null_ ) +insert OID = 2185 ( has_sequence_privilege 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "25 25" _null_ _null_ _null_ _null_ has_sequence_privilege_name _null_ _null_ _null_ ) +insert OID = 2186 ( has_sequence_privilege 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "26 25" _null_ _null_ _null_ _null_ has_sequence_privilege_id _null_ _null_ _null_ ) +insert OID = 3012 ( has_column_privilege 11 10 12 1 0 0 0 f f f f t f s 4 0 16 "19 25 25 25" _null_ _null_ _null_ _null_ has_column_privilege_name_name_name _null_ _null_ _null_ ) +insert OID = 3013 ( has_column_privilege 11 10 12 1 0 0 0 f f f f t f s 4 0 16 "19 25 21 25" _null_ _null_ _null_ _null_ has_column_privilege_name_name_attnum _null_ _null_ _null_ ) +insert OID = 3014 ( has_column_privilege 11 10 12 1 0 0 0 f f f f t f s 4 0 16 "19 26 25 25" _null_ _null_ _null_ _null_ has_column_privilege_name_id_name _null_ _null_ _null_ ) +insert OID = 3015 ( has_column_privilege 11 10 12 1 0 0 0 f f f f t f s 4 0 16 "19 26 21 25" _null_ _null_ _null_ _null_ has_column_privilege_name_id_attnum _null_ _null_ _null_ ) +insert OID = 3016 ( has_column_privilege 11 10 12 1 0 0 0 f f f f t f s 4 0 16 "26 25 25 25" _null_ _null_ _null_ _null_ has_column_privilege_id_name_name _null_ _null_ _null_ ) +insert OID = 3017 ( has_column_privilege 11 10 12 1 0 0 0 f f f f t f s 4 0 16 "26 25 21 25" _null_ _null_ _null_ _null_ has_column_privilege_id_name_attnum _null_ _null_ _null_ ) +insert OID = 3018 ( has_column_privilege 11 10 12 1 0 0 0 f f f f t f s 4 0 16 "26 26 25 25" _null_ _null_ _null_ _null_ has_column_privilege_id_id_name _null_ _null_ _null_ ) +insert OID = 3019 ( has_column_privilege 11 10 12 1 0 0 0 f f f f t f s 4 0 16 "26 26 21 25" _null_ _null_ _null_ _null_ has_column_privilege_id_id_attnum _null_ _null_ _null_ ) +insert OID = 3020 ( has_column_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "25 25 25" _null_ _null_ _null_ _null_ has_column_privilege_name_name _null_ _null_ _null_ ) +insert OID = 3021 ( has_column_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "25 21 25" _null_ _null_ _null_ _null_ has_column_privilege_name_attnum _null_ _null_ _null_ ) +insert OID = 3022 ( has_column_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "26 25 25" _null_ _null_ _null_ _null_ has_column_privilege_id_name _null_ _null_ _null_ ) +insert OID = 3023 ( has_column_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "26 21 25" _null_ _null_ _null_ _null_ has_column_privilege_id_attnum _null_ _null_ _null_ ) +insert OID = 3024 ( has_any_column_privilege 11 10 12 10 0 0 0 f f f f t f s 3 0 16 "19 25 25" _null_ _null_ _null_ _null_ has_any_column_privilege_name_name _null_ _null_ _null_ ) +insert OID = 3025 ( has_any_column_privilege 11 10 12 10 0 0 0 f f f f t f s 3 0 16 "19 26 25" _null_ _null_ _null_ _null_ has_any_column_privilege_name_id _null_ _null_ _null_ ) +insert OID = 3026 ( has_any_column_privilege 11 10 12 10 0 0 0 f f f f t f s 3 0 16 "26 25 25" _null_ _null_ _null_ _null_ has_any_column_privilege_id_name _null_ _null_ _null_ ) +insert OID = 3027 ( has_any_column_privilege 11 10 12 10 0 0 0 f f f f t f s 3 0 16 "26 26 25" _null_ _null_ _null_ _null_ has_any_column_privilege_id_id _null_ _null_ _null_ ) +insert OID = 3028 ( has_any_column_privilege 11 10 12 10 0 0 0 f f f f t f s 2 0 16 "25 25" _null_ _null_ _null_ _null_ has_any_column_privilege_name _null_ _null_ _null_ ) +insert OID = 3029 ( has_any_column_privilege 11 10 12 10 0 0 0 f f f f t f s 2 0 16 "26 25" _null_ _null_ _null_ _null_ has_any_column_privilege_id _null_ _null_ _null_ ) +insert OID = 1928 ( pg_stat_get_numscans 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_numscans _null_ _null_ _null_ ) +insert OID = 1929 ( pg_stat_get_tuples_returned 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_tuples_returned _null_ _null_ _null_ ) +insert OID = 1930 ( pg_stat_get_tuples_fetched 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_tuples_fetched _null_ _null_ _null_ ) +insert OID = 1931 ( pg_stat_get_tuples_inserted 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_tuples_inserted _null_ _null_ _null_ ) +insert OID = 1932 ( pg_stat_get_tuples_updated 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_tuples_updated _null_ _null_ _null_ ) +insert OID = 1933 ( pg_stat_get_tuples_deleted 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_tuples_deleted _null_ _null_ _null_ ) +insert OID = 1972 ( pg_stat_get_tuples_hot_updated 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_tuples_hot_updated _null_ _null_ _null_ ) +insert OID = 2878 ( pg_stat_get_live_tuples 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_live_tuples _null_ _null_ _null_ ) +insert OID = 2879 ( pg_stat_get_dead_tuples 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_dead_tuples _null_ _null_ _null_ ) +insert OID = 1934 ( pg_stat_get_blocks_fetched 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_blocks_fetched _null_ _null_ _null_ ) +insert OID = 1935 ( pg_stat_get_blocks_hit 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_blocks_hit _null_ _null_ _null_ ) +insert OID = 2781 ( pg_stat_get_last_vacuum_time 11 10 12 1 0 0 0 f f f f t f s 1 0 1184 "26" _null_ _null_ _null_ _null_ pg_stat_get_last_vacuum_time _null_ _null_ _null_ ) +insert OID = 2782 ( pg_stat_get_last_autovacuum_time 11 10 12 1 0 0 0 f f f f t f s 1 0 1184 "26" _null_ _null_ _null_ _null_ pg_stat_get_last_autovacuum_time _null_ _null_ _null_ ) +insert OID = 2783 ( pg_stat_get_last_analyze_time 11 10 12 1 0 0 0 f f f f t f s 1 0 1184 "26" _null_ _null_ _null_ _null_ pg_stat_get_last_analyze_time _null_ _null_ _null_ ) +insert OID = 2784 ( pg_stat_get_last_autoanalyze_time 11 10 12 1 0 0 0 f f f f t f s 1 0 1184 "26" _null_ _null_ _null_ _null_ pg_stat_get_last_autoanalyze_time _null_ _null_ _null_ ) +insert OID = 3054 ( pg_stat_get_vacuum_count 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_vacuum_count _null_ _null_ _null_ ) +insert OID = 3055 ( pg_stat_get_autovacuum_count 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_autovacuum_count _null_ _null_ _null_ ) +insert OID = 3056 ( pg_stat_get_analyze_count 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_analyze_count _null_ _null_ _null_ ) +insert OID = 3057 ( pg_stat_get_autoanalyze_count 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_autoanalyze_count _null_ _null_ _null_ ) +insert OID = 1936 ( pg_stat_get_backend_idset 11 10 12 1 100 0 0 f f f f t t s 0 0 23 "" _null_ _null_ _null_ _null_ pg_stat_get_backend_idset _null_ _null_ _null_ ) +insert OID = 2022 ( pg_stat_get_activity 11 10 12 1 100 0 0 f f f f f t s 1 0 2249 "23" "{23,26,23,26,25,25,25,16,1184,1184,1184,1184,869,25,23}" "{i,o,o,o,o,o,o,o,o,o,o,o,o,o,o}" "{pid,datid,pid,usesysid,application_name,state,query,waiting,xact_start,query_start,backend_start,state_change,client_addr,client_hostname,client_port}" _null_ pg_stat_get_activity _null_ _null_ _null_ ) +insert OID = 3099 ( pg_stat_get_wal_senders 11 10 12 1 10 0 0 f f f f f t s 0 0 2249 "" "{23,25,25,25,25,25,23,25}" "{o,o,o,o,o,o,o,o}" "{pid,state,sent_location,write_location,flush_location,replay_location,sync_priority,sync_state}" _null_ pg_stat_get_wal_senders _null_ _null_ _null_ ) +insert OID = 2026 ( pg_backend_pid 11 10 12 1 0 0 0 f f f f t f s 0 0 23 "" _null_ _null_ _null_ _null_ pg_backend_pid _null_ _null_ _null_ ) +insert OID = 1937 ( pg_stat_get_backend_pid 11 10 12 1 0 0 0 f f f f t f s 1 0 23 "23" _null_ _null_ _null_ _null_ pg_stat_get_backend_pid _null_ _null_ _null_ ) +insert OID = 1938 ( pg_stat_get_backend_dbid 11 10 12 1 0 0 0 f f f f t f s 1 0 26 "23" _null_ _null_ _null_ _null_ pg_stat_get_backend_dbid _null_ _null_ _null_ ) +insert OID = 1939 ( pg_stat_get_backend_userid 11 10 12 1 0 0 0 f f f f t f s 1 0 26 "23" _null_ _null_ _null_ _null_ pg_stat_get_backend_userid _null_ _null_ _null_ ) +insert OID = 1940 ( pg_stat_get_backend_activity 11 10 12 1 0 0 0 f f f f t f s 1 0 25 "23" _null_ _null_ _null_ _null_ pg_stat_get_backend_activity _null_ _null_ _null_ ) +insert OID = 2853 ( pg_stat_get_backend_waiting 11 10 12 1 0 0 0 f f f f t f s 1 0 16 "23" _null_ _null_ _null_ _null_ pg_stat_get_backend_waiting _null_ _null_ _null_ ) +insert OID = 2094 ( pg_stat_get_backend_activity_start 11 10 12 1 0 0 0 f f f f t f s 1 0 1184 "23" _null_ _null_ _null_ _null_ pg_stat_get_backend_activity_start _null_ _null_ _null_ ) +insert OID = 2857 ( pg_stat_get_backend_xact_start 11 10 12 1 0 0 0 f f f f t f s 1 0 1184 "23" _null_ _null_ _null_ _null_ pg_stat_get_backend_xact_start _null_ _null_ _null_ ) +insert OID = 1391 ( pg_stat_get_backend_start 11 10 12 1 0 0 0 f f f f t f s 1 0 1184 "23" _null_ _null_ _null_ _null_ pg_stat_get_backend_start _null_ _null_ _null_ ) +insert OID = 1392 ( pg_stat_get_backend_client_addr 11 10 12 1 0 0 0 f f f f t f s 1 0 869 "23" _null_ _null_ _null_ _null_ pg_stat_get_backend_client_addr _null_ _null_ _null_ ) +insert OID = 1393 ( pg_stat_get_backend_client_port 11 10 12 1 0 0 0 f f f f t f s 1 0 23 "23" _null_ _null_ _null_ _null_ pg_stat_get_backend_client_port _null_ _null_ _null_ ) +insert OID = 1941 ( pg_stat_get_db_numbackends 11 10 12 1 0 0 0 f f f f t f s 1 0 23 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_numbackends _null_ _null_ _null_ ) +insert OID = 1942 ( pg_stat_get_db_xact_commit 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_xact_commit _null_ _null_ _null_ ) +insert OID = 1943 ( pg_stat_get_db_xact_rollback 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_xact_rollback _null_ _null_ _null_ ) +insert OID = 1944 ( pg_stat_get_db_blocks_fetched 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_blocks_fetched _null_ _null_ _null_ ) +insert OID = 1945 ( pg_stat_get_db_blocks_hit 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_blocks_hit _null_ _null_ _null_ ) +insert OID = 2758 ( pg_stat_get_db_tuples_returned 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_tuples_returned _null_ _null_ _null_ ) +insert OID = 2759 ( pg_stat_get_db_tuples_fetched 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_tuples_fetched _null_ _null_ _null_ ) +insert OID = 2760 ( pg_stat_get_db_tuples_inserted 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_tuples_inserted _null_ _null_ _null_ ) +insert OID = 2761 ( pg_stat_get_db_tuples_updated 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_tuples_updated _null_ _null_ _null_ ) +insert OID = 2762 ( pg_stat_get_db_tuples_deleted 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_tuples_deleted _null_ _null_ _null_ ) +insert OID = 3065 ( pg_stat_get_db_conflict_tablespace 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_conflict_tablespace _null_ _null_ _null_ ) +insert OID = 3066 ( pg_stat_get_db_conflict_lock 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_conflict_lock _null_ _null_ _null_ ) +insert OID = 3067 ( pg_stat_get_db_conflict_snapshot 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_conflict_snapshot _null_ _null_ _null_ ) +insert OID = 3068 ( pg_stat_get_db_conflict_bufferpin 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_conflict_bufferpin _null_ _null_ _null_ ) +insert OID = 3069 ( pg_stat_get_db_conflict_startup_deadlock 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_conflict_startup_deadlock _null_ _null_ _null_ ) +insert OID = 3070 ( pg_stat_get_db_conflict_all 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_conflict_all _null_ _null_ _null_ ) +insert OID = 3152 ( pg_stat_get_db_deadlocks 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_deadlocks _null_ _null_ _null_ ) +insert OID = 3074 ( pg_stat_get_db_stat_reset_time 11 10 12 1 0 0 0 f f f f t f s 1 0 1184 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_stat_reset_time _null_ _null_ _null_ ) +insert OID = 3150 ( pg_stat_get_db_temp_files 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_temp_files _null_ _null_ _null_ ) +insert OID = 3151 ( pg_stat_get_db_temp_bytes 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_temp_bytes _null_ _null_ _null_ ) +insert OID = 2844 ( pg_stat_get_db_blk_read_time 11 10 12 1 0 0 0 f f f f t f s 1 0 701 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_blk_read_time _null_ _null_ _null_ ) +insert OID = 2845 ( pg_stat_get_db_blk_write_time 11 10 12 1 0 0 0 f f f f t f s 1 0 701 "26" _null_ _null_ _null_ _null_ pg_stat_get_db_blk_write_time _null_ _null_ _null_ ) +insert OID = 2769 ( pg_stat_get_bgwriter_timed_checkpoints 11 10 12 1 0 0 0 f f f f t f s 0 0 20 "" _null_ _null_ _null_ _null_ pg_stat_get_bgwriter_timed_checkpoints _null_ _null_ _null_ ) +insert OID = 2770 ( pg_stat_get_bgwriter_requested_checkpoints 11 10 12 1 0 0 0 f f f f t f s 0 0 20 "" _null_ _null_ _null_ _null_ pg_stat_get_bgwriter_requested_checkpoints _null_ _null_ _null_ ) +insert OID = 2771 ( pg_stat_get_bgwriter_buf_written_checkpoints 11 10 12 1 0 0 0 f f f f t f s 0 0 20 "" _null_ _null_ _null_ _null_ pg_stat_get_bgwriter_buf_written_checkpoints _null_ _null_ _null_ ) +insert OID = 2772 ( pg_stat_get_bgwriter_buf_written_clean 11 10 12 1 0 0 0 f f f f t f s 0 0 20 "" _null_ _null_ _null_ _null_ pg_stat_get_bgwriter_buf_written_clean _null_ _null_ _null_ ) +insert OID = 2773 ( pg_stat_get_bgwriter_maxwritten_clean 11 10 12 1 0 0 0 f f f f t f s 0 0 20 "" _null_ _null_ _null_ _null_ pg_stat_get_bgwriter_maxwritten_clean _null_ _null_ _null_ ) +insert OID = 3075 ( pg_stat_get_bgwriter_stat_reset_time 11 10 12 1 0 0 0 f f f f t f s 0 0 1184 "" _null_ _null_ _null_ _null_ pg_stat_get_bgwriter_stat_reset_time _null_ _null_ _null_ ) +insert OID = 3160 ( pg_stat_get_checkpoint_write_time 11 10 12 1 0 0 0 f f f f t f s 0 0 701 "" _null_ _null_ _null_ _null_ pg_stat_get_checkpoint_write_time _null_ _null_ _null_ ) +insert OID = 3161 ( pg_stat_get_checkpoint_sync_time 11 10 12 1 0 0 0 f f f f t f s 0 0 701 "" _null_ _null_ _null_ _null_ pg_stat_get_checkpoint_sync_time _null_ _null_ _null_ ) +insert OID = 2775 ( pg_stat_get_buf_written_backend 11 10 12 1 0 0 0 f f f f t f s 0 0 20 "" _null_ _null_ _null_ _null_ pg_stat_get_buf_written_backend _null_ _null_ _null_ ) +insert OID = 3063 ( pg_stat_get_buf_fsync_backend 11 10 12 1 0 0 0 f f f f t f s 0 0 20 "" _null_ _null_ _null_ _null_ pg_stat_get_buf_fsync_backend _null_ _null_ _null_ ) +insert OID = 2859 ( pg_stat_get_buf_alloc 11 10 12 1 0 0 0 f f f f t f s 0 0 20 "" _null_ _null_ _null_ _null_ pg_stat_get_buf_alloc _null_ _null_ _null_ ) +insert OID = 2978 ( pg_stat_get_function_calls 11 10 12 1 0 0 0 f f f f t f s 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_function_calls _null_ _null_ _null_ ) +insert OID = 2979 ( pg_stat_get_function_total_time 11 10 12 1 0 0 0 f f f f t f s 1 0 701 "26" _null_ _null_ _null_ _null_ pg_stat_get_function_total_time _null_ _null_ _null_ ) +insert OID = 2980 ( pg_stat_get_function_self_time 11 10 12 1 0 0 0 f f f f t f s 1 0 701 "26" _null_ _null_ _null_ _null_ pg_stat_get_function_self_time _null_ _null_ _null_ ) +insert OID = 3037 ( pg_stat_get_xact_numscans 11 10 12 1 0 0 0 f f f f t f v 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_xact_numscans _null_ _null_ _null_ ) +insert OID = 3038 ( pg_stat_get_xact_tuples_returned 11 10 12 1 0 0 0 f f f f t f v 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_xact_tuples_returned _null_ _null_ _null_ ) +insert OID = 3039 ( pg_stat_get_xact_tuples_fetched 11 10 12 1 0 0 0 f f f f t f v 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_xact_tuples_fetched _null_ _null_ _null_ ) +insert OID = 3040 ( pg_stat_get_xact_tuples_inserted 11 10 12 1 0 0 0 f f f f t f v 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_xact_tuples_inserted _null_ _null_ _null_ ) +insert OID = 3041 ( pg_stat_get_xact_tuples_updated 11 10 12 1 0 0 0 f f f f t f v 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_xact_tuples_updated _null_ _null_ _null_ ) +insert OID = 3042 ( pg_stat_get_xact_tuples_deleted 11 10 12 1 0 0 0 f f f f t f v 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_xact_tuples_deleted _null_ _null_ _null_ ) +insert OID = 3043 ( pg_stat_get_xact_tuples_hot_updated 11 10 12 1 0 0 0 f f f f t f v 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_xact_tuples_hot_updated _null_ _null_ _null_ ) +insert OID = 3044 ( pg_stat_get_xact_blocks_fetched 11 10 12 1 0 0 0 f f f f t f v 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_xact_blocks_fetched _null_ _null_ _null_ ) +insert OID = 3045 ( pg_stat_get_xact_blocks_hit 11 10 12 1 0 0 0 f f f f t f v 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_xact_blocks_hit _null_ _null_ _null_ ) +insert OID = 3046 ( pg_stat_get_xact_function_calls 11 10 12 1 0 0 0 f f f f t f v 1 0 20 "26" _null_ _null_ _null_ _null_ pg_stat_get_xact_function_calls _null_ _null_ _null_ ) +insert OID = 3047 ( pg_stat_get_xact_function_total_time 11 10 12 1 0 0 0 f f f f t f v 1 0 701 "26" _null_ _null_ _null_ _null_ pg_stat_get_xact_function_total_time _null_ _null_ _null_ ) +insert OID = 3048 ( pg_stat_get_xact_function_self_time 11 10 12 1 0 0 0 f f f f t f v 1 0 701 "26" _null_ _null_ _null_ _null_ pg_stat_get_xact_function_self_time _null_ _null_ _null_ ) +insert OID = 2230 ( pg_stat_clear_snapshot 11 10 12 1 0 0 0 f f f f f f v 0 0 2278 "" _null_ _null_ _null_ _null_ pg_stat_clear_snapshot _null_ _null_ _null_ ) +insert OID = 2274 ( pg_stat_reset 11 10 12 1 0 0 0 f f f f f f v 0 0 2278 "" _null_ _null_ _null_ _null_ pg_stat_reset _null_ _null_ _null_ ) +insert OID = 3775 ( pg_stat_reset_shared 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "25" _null_ _null_ _null_ _null_ pg_stat_reset_shared _null_ _null_ _null_ ) +insert OID = 3776 ( pg_stat_reset_single_table_counters 11 10 12 1 0 0 0 f f f f f f v 1 0 2278 "26" _null_ _null_ _null_ _null_ pg_stat_reset_single_table_counters _null_ _null_ _null_ ) +insert OID = 3777 ( pg_stat_reset_single_function_counters 11 10 12 1 0 0 0 f f f f f f v 1 0 2278 "26" _null_ _null_ _null_ _null_ pg_stat_reset_single_function_counters _null_ _null_ _null_ ) +insert OID = 3163 ( pg_trigger_depth 11 10 12 1 0 0 0 f f f f t f s 0 0 23 "" _null_ _null_ _null_ _null_ pg_trigger_depth _null_ _null_ _null_ ) +insert OID = 3778 ( pg_tablespace_location 11 10 12 1 0 0 0 f f f f t f s 1 0 25 "26" _null_ _null_ _null_ _null_ pg_tablespace_location _null_ _null_ _null_ ) +insert OID = 1946 ( encode 11 10 12 1 0 0 0 f f f f t f i 2 0 25 "17 25" _null_ _null_ _null_ _null_ binary_encode _null_ _null_ _null_ ) +insert OID = 1947 ( decode 11 10 12 1 0 0 0 f f f f t f i 2 0 17 "25 25" _null_ _null_ _null_ _null_ binary_decode _null_ _null_ _null_ ) +insert OID = 1948 ( byteaeq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "17 17" _null_ _null_ _null_ _null_ byteaeq _null_ _null_ _null_ ) +insert OID = 1949 ( bytealt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "17 17" _null_ _null_ _null_ _null_ bytealt _null_ _null_ _null_ ) +insert OID = 1950 ( byteale 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "17 17" _null_ _null_ _null_ _null_ byteale _null_ _null_ _null_ ) +insert OID = 1951 ( byteagt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "17 17" _null_ _null_ _null_ _null_ byteagt _null_ _null_ _null_ ) +insert OID = 1952 ( byteage 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "17 17" _null_ _null_ _null_ _null_ byteage _null_ _null_ _null_ ) +insert OID = 1953 ( byteane 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "17 17" _null_ _null_ _null_ _null_ byteane _null_ _null_ _null_ ) +insert OID = 1954 ( byteacmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "17 17" _null_ _null_ _null_ _null_ byteacmp _null_ _null_ _null_ ) +insert OID = 3917 ( timestamp_transform 11 10 12 1 0 0 0 f f f f t f i 1 0 2281 "2281" _null_ _null_ _null_ _null_ timestamp_transform _null_ _null_ _null_ ) +insert OID = 3944 ( time_transform 11 10 12 1 0 0 0 f f f f t f i 1 0 2281 "2281" _null_ _null_ _null_ _null_ time_transform _null_ _null_ _null_ ) +insert OID = 1961 ( timestamp 11 10 12 1 0 0 timestamp_transform f f f f t f i 2 0 1114 "1114 23" _null_ _null_ _null_ _null_ timestamp_scale _null_ _null_ _null_ ) +insert OID = 1965 ( oidlarger 11 10 12 1 0 0 0 f f f f t f i 2 0 26 "26 26" _null_ _null_ _null_ _null_ oidlarger _null_ _null_ _null_ ) +insert OID = 1966 ( oidsmaller 11 10 12 1 0 0 0 f f f f t f i 2 0 26 "26 26" _null_ _null_ _null_ _null_ oidsmaller _null_ _null_ _null_ ) +insert OID = 1967 ( timestamptz 11 10 12 1 0 0 timestamp_transform f f f f t f i 2 0 1184 "1184 23" _null_ _null_ _null_ _null_ timestamptz_scale _null_ _null_ _null_ ) +insert OID = 1968 ( time 11 10 12 1 0 0 time_transform f f f f t f i 2 0 1083 "1083 23" _null_ _null_ _null_ _null_ time_scale _null_ _null_ _null_ ) +insert OID = 1969 ( timetz 11 10 12 1 0 0 time_transform f f f f t f i 2 0 1266 "1266 23" _null_ _null_ _null_ _null_ timetz_scale _null_ _null_ _null_ ) +insert OID = 2003 ( textanycat 11 10 14 1 0 0 0 f f f f t f s 2 0 25 "25 2776" _null_ _null_ _null_ _null_ "select $1 || $2::pg_catalog.text" _null_ _null_ _null_ ) +insert OID = 2004 ( anytextcat 11 10 14 1 0 0 0 f f f f t f s 2 0 25 "2776 25" _null_ _null_ _null_ _null_ "select $1::pg_catalog.text || $2" _null_ _null_ _null_ ) +insert OID = 2005 ( bytealike 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "17 17" _null_ _null_ _null_ _null_ bytealike _null_ _null_ _null_ ) +insert OID = 2006 ( byteanlike 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "17 17" _null_ _null_ _null_ _null_ byteanlike _null_ _null_ _null_ ) +insert OID = 2007 ( like 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "17 17" _null_ _null_ _null_ _null_ bytealike _null_ _null_ _null_ ) +insert OID = 2008 ( notlike 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "17 17" _null_ _null_ _null_ _null_ byteanlike _null_ _null_ _null_ ) +insert OID = 2009 ( like_escape 11 10 12 1 0 0 0 f f f f t f i 2 0 17 "17 17" _null_ _null_ _null_ _null_ like_escape_bytea _null_ _null_ _null_ ) +insert OID = 2010 ( length 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "17" _null_ _null_ _null_ _null_ byteaoctetlen _null_ _null_ _null_ ) +insert OID = 2011 ( byteacat 11 10 12 1 0 0 0 f f f f t f i 2 0 17 "17 17" _null_ _null_ _null_ _null_ byteacat _null_ _null_ _null_ ) +insert OID = 2012 ( substring 11 10 12 1 0 0 0 f f f f t f i 3 0 17 "17 23 23" _null_ _null_ _null_ _null_ bytea_substr _null_ _null_ _null_ ) +insert OID = 2013 ( substring 11 10 12 1 0 0 0 f f f f t f i 2 0 17 "17 23" _null_ _null_ _null_ _null_ bytea_substr_no_len _null_ _null_ _null_ ) +insert OID = 2085 ( substr 11 10 12 1 0 0 0 f f f f t f i 3 0 17 "17 23 23" _null_ _null_ _null_ _null_ bytea_substr _null_ _null_ _null_ ) +insert OID = 2086 ( substr 11 10 12 1 0 0 0 f f f f t f i 2 0 17 "17 23" _null_ _null_ _null_ _null_ bytea_substr_no_len _null_ _null_ _null_ ) +insert OID = 2014 ( position 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "17 17" _null_ _null_ _null_ _null_ byteapos _null_ _null_ _null_ ) +insert OID = 2015 ( btrim 11 10 12 1 0 0 0 f f f f t f i 2 0 17 "17 17" _null_ _null_ _null_ _null_ byteatrim _null_ _null_ _null_ ) +insert OID = 2019 ( time 11 10 12 1 0 0 0 f f f f t f s 1 0 1083 "1184" _null_ _null_ _null_ _null_ timestamptz_time _null_ _null_ _null_ ) +insert OID = 2020 ( date_trunc 11 10 12 1 0 0 0 f f f f t f i 2 0 1114 "25 1114" _null_ _null_ _null_ _null_ timestamp_trunc _null_ _null_ _null_ ) +insert OID = 2021 ( date_part 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "25 1114" _null_ _null_ _null_ _null_ timestamp_part _null_ _null_ _null_ ) +insert OID = 2023 ( timestamp 11 10 12 1 0 0 0 f f f f t f s 1 0 1114 "702" _null_ _null_ _null_ _null_ abstime_timestamp _null_ _null_ _null_ ) +insert OID = 2024 ( timestamp 11 10 12 1 0 0 0 f f f f t f i 1 0 1114 "1082" _null_ _null_ _null_ _null_ date_timestamp _null_ _null_ _null_ ) +insert OID = 2025 ( timestamp 11 10 12 1 0 0 0 f f f f t f i 2 0 1114 "1082 1083" _null_ _null_ _null_ _null_ datetime_timestamp _null_ _null_ _null_ ) +insert OID = 2027 ( timestamp 11 10 12 1 0 0 0 f f f f t f s 1 0 1114 "1184" _null_ _null_ _null_ _null_ timestamptz_timestamp _null_ _null_ _null_ ) +insert OID = 2028 ( timestamptz 11 10 12 1 0 0 0 f f f f t f s 1 0 1184 "1114" _null_ _null_ _null_ _null_ timestamp_timestamptz _null_ _null_ _null_ ) +insert OID = 2029 ( date 11 10 12 1 0 0 0 f f f f t f i 1 0 1082 "1114" _null_ _null_ _null_ _null_ timestamp_date _null_ _null_ _null_ ) +insert OID = 2030 ( abstime 11 10 12 1 0 0 0 f f f f t f s 1 0 702 "1114" _null_ _null_ _null_ _null_ timestamp_abstime _null_ _null_ _null_ ) +insert OID = 2031 ( timestamp_mi 11 10 12 1 0 0 0 f f f f t f i 2 0 1186 "1114 1114" _null_ _null_ _null_ _null_ timestamp_mi _null_ _null_ _null_ ) +insert OID = 2032 ( timestamp_pl_interval 11 10 12 1 0 0 0 f f f f t f i 2 0 1114 "1114 1186" _null_ _null_ _null_ _null_ timestamp_pl_interval _null_ _null_ _null_ ) +insert OID = 2033 ( timestamp_mi_interval 11 10 12 1 0 0 0 f f f f t f i 2 0 1114 "1114 1186" _null_ _null_ _null_ _null_ timestamp_mi_interval _null_ _null_ _null_ ) +insert OID = 2035 ( timestamp_smaller 11 10 12 1 0 0 0 f f f f t f i 2 0 1114 "1114 1114" _null_ _null_ _null_ _null_ timestamp_smaller _null_ _null_ _null_ ) +insert OID = 2036 ( timestamp_larger 11 10 12 1 0 0 0 f f f f t f i 2 0 1114 "1114 1114" _null_ _null_ _null_ _null_ timestamp_larger _null_ _null_ _null_ ) +insert OID = 2037 ( timezone 11 10 12 1 0 0 0 f f f f t f v 2 0 1266 "25 1266" _null_ _null_ _null_ _null_ timetz_zone _null_ _null_ _null_ ) +insert OID = 2038 ( timezone 11 10 12 1 0 0 0 f f f f t f i 2 0 1266 "1186 1266" _null_ _null_ _null_ _null_ timetz_izone _null_ _null_ _null_ ) +insert OID = 2039 ( timestamp_hash 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "1114" _null_ _null_ _null_ _null_ timestamp_hash _null_ _null_ _null_ ) +insert OID = 2041 ( overlaps 11 10 12 1 0 0 0 f f f f f f i 4 0 16 "1114 1114 1114 1114" _null_ _null_ _null_ _null_ overlaps_timestamp _null_ _null_ _null_ ) +insert OID = 2042 ( overlaps 11 10 14 1 0 0 0 f f f f f f i 4 0 16 "1114 1186 1114 1186" _null_ _null_ _null_ _null_ "select ($1, ($1 + $2)) overlaps ($3, ($3 + $4))" _null_ _null_ _null_ ) +insert OID = 2043 ( overlaps 11 10 14 1 0 0 0 f f f f f f i 4 0 16 "1114 1114 1114 1186" _null_ _null_ _null_ _null_ "select ($1, $2) overlaps ($3, ($3 + $4))" _null_ _null_ _null_ ) +insert OID = 2044 ( overlaps 11 10 14 1 0 0 0 f f f f f f i 4 0 16 "1114 1186 1114 1114" _null_ _null_ _null_ _null_ "select ($1, ($1 + $2)) overlaps ($3, $4)" _null_ _null_ _null_ ) +insert OID = 2045 ( timestamp_cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "1114 1114" _null_ _null_ _null_ _null_ timestamp_cmp _null_ _null_ _null_ ) +insert OID = 3137 ( timestamp_sortsupport 11 10 12 1 0 0 0 f f f f t f i 1 0 2278 "2281" _null_ _null_ _null_ _null_ timestamp_sortsupport _null_ _null_ _null_ ) +insert OID = 2046 ( time 11 10 12 1 0 0 0 f f f f t f i 1 0 1083 "1266" _null_ _null_ _null_ _null_ timetz_time _null_ _null_ _null_ ) +insert OID = 2047 ( timetz 11 10 12 1 0 0 0 f f f f t f s 1 0 1266 "1083" _null_ _null_ _null_ _null_ time_timetz _null_ _null_ _null_ ) +insert OID = 2048 ( isfinite 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "1114" _null_ _null_ _null_ _null_ timestamp_finite _null_ _null_ _null_ ) +insert OID = 2049 ( to_char 11 10 12 1 0 0 0 f f f f t f s 2 0 25 "1114 25" _null_ _null_ _null_ _null_ timestamp_to_char _null_ _null_ _null_ ) +insert OID = 2052 ( timestamp_eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1114 1114" _null_ _null_ _null_ _null_ timestamp_eq _null_ _null_ _null_ ) +insert OID = 2053 ( timestamp_ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1114 1114" _null_ _null_ _null_ _null_ timestamp_ne _null_ _null_ _null_ ) +insert OID = 2054 ( timestamp_lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1114 1114" _null_ _null_ _null_ _null_ timestamp_lt _null_ _null_ _null_ ) +insert OID = 2055 ( timestamp_le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1114 1114" _null_ _null_ _null_ _null_ timestamp_le _null_ _null_ _null_ ) +insert OID = 2056 ( timestamp_ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1114 1114" _null_ _null_ _null_ _null_ timestamp_ge _null_ _null_ _null_ ) +insert OID = 2057 ( timestamp_gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "1114 1114" _null_ _null_ _null_ _null_ timestamp_gt _null_ _null_ _null_ ) +insert OID = 2058 ( age 11 10 12 1 0 0 0 f f f f t f i 2 0 1186 "1114 1114" _null_ _null_ _null_ _null_ timestamp_age _null_ _null_ _null_ ) +insert OID = 2059 ( age 11 10 14 1 0 0 0 f f f f t f s 1 0 1186 "1114" _null_ _null_ _null_ _null_ "select pg_catalog.age(cast(current_date as timestamp without time zone), $1)" _null_ _null_ _null_ ) +insert OID = 2069 ( timezone 11 10 12 1 0 0 0 f f f f t f i 2 0 1184 "25 1114" _null_ _null_ _null_ _null_ timestamp_zone _null_ _null_ _null_ ) +insert OID = 2070 ( timezone 11 10 12 1 0 0 0 f f f f t f i 2 0 1184 "1186 1114" _null_ _null_ _null_ _null_ timestamp_izone _null_ _null_ _null_ ) +insert OID = 2071 ( date_pl_interval 11 10 12 1 0 0 0 f f f f t f i 2 0 1114 "1082 1186" _null_ _null_ _null_ _null_ date_pl_interval _null_ _null_ _null_ ) +insert OID = 2072 ( date_mi_interval 11 10 12 1 0 0 0 f f f f t f i 2 0 1114 "1082 1186" _null_ _null_ _null_ _null_ date_mi_interval _null_ _null_ _null_ ) +insert OID = 2073 ( substring 11 10 12 1 0 0 0 f f f f t f i 2 0 25 "25 25" _null_ _null_ _null_ _null_ textregexsubstr _null_ _null_ _null_ ) +insert OID = 2074 ( substring 11 10 14 1 0 0 0 f f f f t f i 3 0 25 "25 25 25" _null_ _null_ _null_ _null_ "select pg_catalog.substring($1, pg_catalog.similar_escape($2, $3))" _null_ _null_ _null_ ) +insert OID = 2075 ( bit 11 10 12 1 0 0 0 f f f f t f i 2 0 1560 "20 23" _null_ _null_ _null_ _null_ bitfromint8 _null_ _null_ _null_ ) +insert OID = 2076 ( int8 11 10 12 1 0 0 0 f f f f t f i 1 0 20 "1560" _null_ _null_ _null_ _null_ bittoint8 _null_ _null_ _null_ ) +insert OID = 2077 ( current_setting 11 10 12 1 0 0 0 f f f f t f s 1 0 25 "25" _null_ _null_ _null_ _null_ show_config_by_name _null_ _null_ _null_ ) +insert OID = 2078 ( set_config 11 10 12 1 0 0 0 f f f f f f v 3 0 25 "25 25 16" _null_ _null_ _null_ _null_ set_config_by_name _null_ _null_ _null_ ) +insert OID = 2084 ( pg_show_all_settings 11 10 12 1 1000 0 0 f f f f t t s 0 0 2249 "" "{25,25,25,25,25,25,25,25,25,25,25,1009,25,25,25,23}" "{o,o,o,o,o,o,o,o,o,o,o,o,o,o,o,o}" "{name,setting,unit,category,short_desc,extra_desc,context,vartype,source,min_val,max_val,enumvals,boot_val,reset_val,sourcefile,sourceline}" _null_ show_all_settings _null_ _null_ _null_ ) +insert OID = 1371 ( pg_lock_status 11 10 12 1 1000 0 0 f f f f t t v 0 0 2249 "" "{25,26,26,23,21,25,28,26,26,21,25,23,25,16,16}" "{o,o,o,o,o,o,o,o,o,o,o,o,o,o,o}" "{locktype,database,relation,page,tuple,virtualxid,transactionid,classid,objid,objsubid,virtualtransaction,pid,mode,granted,fastpath}" _null_ pg_lock_status _null_ _null_ _null_ ) +insert OID = 1065 ( pg_prepared_xact 11 10 12 1 1000 0 0 f f f f t t v 0 0 2249 "" "{28,25,1184,26,26}" "{o,o,o,o,o}" "{transaction,gid,prepared,ownerid,dbid}" _null_ pg_prepared_xact _null_ _null_ _null_ ) +insert OID = 3537 ( pg_describe_object 11 10 12 1 0 0 0 f f f f t f s 3 0 25 "26 26 23" _null_ _null_ _null_ _null_ pg_describe_object _null_ _null_ _null_ ) +insert OID = 2079 ( pg_table_is_visible 11 10 12 1 0 0 0 f f f f t f s 1 0 16 "26" _null_ _null_ _null_ _null_ pg_table_is_visible _null_ _null_ _null_ ) +insert OID = 2080 ( pg_type_is_visible 11 10 12 1 0 0 0 f f f f t f s 1 0 16 "26" _null_ _null_ _null_ _null_ pg_type_is_visible _null_ _null_ _null_ ) +insert OID = 2081 ( pg_function_is_visible 11 10 12 1 0 0 0 f f f f t f s 1 0 16 "26" _null_ _null_ _null_ _null_ pg_function_is_visible _null_ _null_ _null_ ) +insert OID = 2082 ( pg_operator_is_visible 11 10 12 1 0 0 0 f f f f t f s 1 0 16 "26" _null_ _null_ _null_ _null_ pg_operator_is_visible _null_ _null_ _null_ ) +insert OID = 2083 ( pg_opclass_is_visible 11 10 12 1 0 0 0 f f f f t f s 1 0 16 "26" _null_ _null_ _null_ _null_ pg_opclass_is_visible _null_ _null_ _null_ ) +insert OID = 3829 ( pg_opfamily_is_visible 11 10 12 1 0 0 0 f f f f t f s 1 0 16 "26" _null_ _null_ _null_ _null_ pg_opfamily_is_visible _null_ _null_ _null_ ) +insert OID = 2093 ( pg_conversion_is_visible 11 10 12 1 0 0 0 f f f f t f s 1 0 16 "26" _null_ _null_ _null_ _null_ pg_conversion_is_visible _null_ _null_ _null_ ) +insert OID = 3756 ( pg_ts_parser_is_visible 11 10 12 1 0 0 0 f f f f t f s 1 0 16 "26" _null_ _null_ _null_ _null_ pg_ts_parser_is_visible _null_ _null_ _null_ ) +insert OID = 3757 ( pg_ts_dict_is_visible 11 10 12 1 0 0 0 f f f f t f s 1 0 16 "26" _null_ _null_ _null_ _null_ pg_ts_dict_is_visible _null_ _null_ _null_ ) +insert OID = 3768 ( pg_ts_template_is_visible 11 10 12 1 0 0 0 f f f f t f s 1 0 16 "26" _null_ _null_ _null_ _null_ pg_ts_template_is_visible _null_ _null_ _null_ ) +insert OID = 3758 ( pg_ts_config_is_visible 11 10 12 1 0 0 0 f f f f t f s 1 0 16 "26" _null_ _null_ _null_ _null_ pg_ts_config_is_visible _null_ _null_ _null_ ) +insert OID = 3815 ( pg_collation_is_visible 11 10 12 1 0 0 0 f f f f t f s 1 0 16 "26" _null_ _null_ _null_ _null_ pg_collation_is_visible _null_ _null_ _null_ ) +insert OID = 2854 ( pg_my_temp_schema 11 10 12 1 0 0 0 f f f f t f s 0 0 26 "" _null_ _null_ _null_ _null_ pg_my_temp_schema _null_ _null_ _null_ ) +insert OID = 2855 ( pg_is_other_temp_schema 11 10 12 1 0 0 0 f f f f t f s 1 0 16 "26" _null_ _null_ _null_ _null_ pg_is_other_temp_schema _null_ _null_ _null_ ) +insert OID = 2171 ( pg_cancel_backend 11 10 12 1 0 0 0 f f f f t f v 1 0 16 "23" _null_ _null_ _null_ _null_ pg_cancel_backend _null_ _null_ _null_ ) +insert OID = 2096 ( pg_terminate_backend 11 10 12 1 0 0 0 f f f f t f v 1 0 16 "23" _null_ _null_ _null_ _null_ pg_terminate_backend _null_ _null_ _null_ ) +insert OID = 2172 ( pg_start_backup 11 10 12 1 0 0 0 f f f f t f v 2 0 25 "25 16" _null_ _null_ _null_ _null_ pg_start_backup _null_ _null_ _null_ ) +insert OID = 2173 ( pg_stop_backup 11 10 12 1 0 0 0 f f f f t f v 0 0 25 "" _null_ _null_ _null_ _null_ pg_stop_backup _null_ _null_ _null_ ) +insert OID = 2848 ( pg_switch_xlog 11 10 12 1 0 0 0 f f f f t f v 0 0 25 "" _null_ _null_ _null_ _null_ pg_switch_xlog _null_ _null_ _null_ ) +insert OID = 3098 ( pg_create_restore_point 11 10 12 1 0 0 0 f f f f t f v 1 0 25 "25" _null_ _null_ _null_ _null_ pg_create_restore_point _null_ _null_ _null_ ) +insert OID = 2849 ( pg_current_xlog_location 11 10 12 1 0 0 0 f f f f t f v 0 0 25 "" _null_ _null_ _null_ _null_ pg_current_xlog_location _null_ _null_ _null_ ) +insert OID = 2852 ( pg_current_xlog_insert_location 11 10 12 1 0 0 0 f f f f t f v 0 0 25 "" _null_ _null_ _null_ _null_ pg_current_xlog_insert_location _null_ _null_ _null_ ) +insert OID = 2850 ( pg_xlogfile_name_offset 11 10 12 1 0 0 0 f f f f t f i 1 0 2249 "25" "{25,25,23}" "{i,o,o}" "{wal_location,file_name,file_offset}" _null_ pg_xlogfile_name_offset _null_ _null_ _null_ ) +insert OID = 2851 ( pg_xlogfile_name 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "25" _null_ _null_ _null_ _null_ pg_xlogfile_name _null_ _null_ _null_ ) +insert OID = 3165 ( pg_xlog_location_diff 11 10 12 1 0 0 0 f f f f t f i 2 0 1700 "25 25" _null_ _null_ _null_ _null_ pg_xlog_location_diff _null_ _null_ _null_ ) +insert OID = 3809 ( pg_export_snapshot 11 10 12 1 0 0 0 f f f f t f v 0 0 25 "" _null_ _null_ _null_ _null_ pg_export_snapshot _null_ _null_ _null_ ) +insert OID = 3810 ( pg_is_in_recovery 11 10 12 1 0 0 0 f f f f t f v 0 0 16 "" _null_ _null_ _null_ _null_ pg_is_in_recovery _null_ _null_ _null_ ) +insert OID = 3820 ( pg_last_xlog_receive_location 11 10 12 1 0 0 0 f f f f t f v 0 0 25 "" _null_ _null_ _null_ _null_ pg_last_xlog_receive_location _null_ _null_ _null_ ) +insert OID = 3821 ( pg_last_xlog_replay_location 11 10 12 1 0 0 0 f f f f t f v 0 0 25 "" _null_ _null_ _null_ _null_ pg_last_xlog_replay_location _null_ _null_ _null_ ) +insert OID = 3830 ( pg_last_xact_replay_timestamp 11 10 12 1 0 0 0 f f f f t f v 0 0 1184 "" _null_ _null_ _null_ _null_ pg_last_xact_replay_timestamp _null_ _null_ _null_ ) +insert OID = 3071 ( pg_xlog_replay_pause 11 10 12 1 0 0 0 f f f f t f v 0 0 2278 "" _null_ _null_ _null_ _null_ pg_xlog_replay_pause _null_ _null_ _null_ ) +insert OID = 3072 ( pg_xlog_replay_resume 11 10 12 1 0 0 0 f f f f t f v 0 0 2278 "" _null_ _null_ _null_ _null_ pg_xlog_replay_resume _null_ _null_ _null_ ) +insert OID = 3073 ( pg_is_xlog_replay_paused 11 10 12 1 0 0 0 f f f f t f v 0 0 16 "" _null_ _null_ _null_ _null_ pg_is_xlog_replay_paused _null_ _null_ _null_ ) +insert OID = 2621 ( pg_reload_conf 11 10 12 1 0 0 0 f f f f t f v 0 0 16 "" _null_ _null_ _null_ _null_ pg_reload_conf _null_ _null_ _null_ ) +insert OID = 2622 ( pg_rotate_logfile 11 10 12 1 0 0 0 f f f f t f v 0 0 16 "" _null_ _null_ _null_ _null_ pg_rotate_logfile _null_ _null_ _null_ ) +insert OID = 2623 ( pg_stat_file 11 10 12 1 0 0 0 f f f f t f v 1 0 2249 "25" "{25,20,1184,1184,1184,1184,16}" "{i,o,o,o,o,o,o}" "{filename,size,access,modification,change,creation,isdir}" _null_ pg_stat_file _null_ _null_ _null_ ) +insert OID = 2624 ( pg_read_file 11 10 12 1 0 0 0 f f f f t f v 3 0 25 "25 20 20" _null_ _null_ _null_ _null_ pg_read_file _null_ _null_ _null_ ) +insert OID = 3826 ( pg_read_file 11 10 12 1 0 0 0 f f f f t f v 1 0 25 "25" _null_ _null_ _null_ _null_ pg_read_file_all _null_ _null_ _null_ ) +insert OID = 3827 ( pg_read_binary_file 11 10 12 1 0 0 0 f f f f t f v 3 0 17 "25 20 20" _null_ _null_ _null_ _null_ pg_read_binary_file _null_ _null_ _null_ ) +insert OID = 3828 ( pg_read_binary_file 11 10 12 1 0 0 0 f f f f t f v 1 0 17 "25" _null_ _null_ _null_ _null_ pg_read_binary_file_all _null_ _null_ _null_ ) +insert OID = 2625 ( pg_ls_dir 11 10 12 1 1000 0 0 f f f f t t v 1 0 25 "25" _null_ _null_ _null_ _null_ pg_ls_dir _null_ _null_ _null_ ) +insert OID = 2626 ( pg_sleep 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "701" _null_ _null_ _null_ _null_ pg_sleep _null_ _null_ _null_ ) +insert OID = 2971 ( text 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "16" _null_ _null_ _null_ _null_ booltext _null_ _null_ _null_ ) +insert OID = 2100 ( avg 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "20" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2101 ( avg 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "23" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2102 ( avg 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "21" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2103 ( avg 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2104 ( avg 11 10 12 1 0 0 0 t f f f f f i 1 0 701 "700" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2105 ( avg 11 10 12 1 0 0 0 t f f f f f i 1 0 701 "701" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2106 ( avg 11 10 12 1 0 0 0 t f f f f f i 1 0 1186 "1186" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2107 ( sum 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "20" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2108 ( sum 11 10 12 1 0 0 0 t f f f f f i 1 0 20 "23" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2109 ( sum 11 10 12 1 0 0 0 t f f f f f i 1 0 20 "21" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2110 ( sum 11 10 12 1 0 0 0 t f f f f f i 1 0 700 "700" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2111 ( sum 11 10 12 1 0 0 0 t f f f f f i 1 0 701 "701" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2112 ( sum 11 10 12 1 0 0 0 t f f f f f i 1 0 790 "790" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2113 ( sum 11 10 12 1 0 0 0 t f f f f f i 1 0 1186 "1186" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2114 ( sum 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2115 ( max 11 10 12 1 0 0 0 t f f f f f i 1 0 20 "20" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2116 ( max 11 10 12 1 0 0 0 t f f f f f i 1 0 23 "23" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2117 ( max 11 10 12 1 0 0 0 t f f f f f i 1 0 21 "21" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2118 ( max 11 10 12 1 0 0 0 t f f f f f i 1 0 26 "26" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2119 ( max 11 10 12 1 0 0 0 t f f f f f i 1 0 700 "700" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2120 ( max 11 10 12 1 0 0 0 t f f f f f i 1 0 701 "701" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2121 ( max 11 10 12 1 0 0 0 t f f f f f i 1 0 702 "702" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2122 ( max 11 10 12 1 0 0 0 t f f f f f i 1 0 1082 "1082" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2123 ( max 11 10 12 1 0 0 0 t f f f f f i 1 0 1083 "1083" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2124 ( max 11 10 12 1 0 0 0 t f f f f f i 1 0 1266 "1266" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2125 ( max 11 10 12 1 0 0 0 t f f f f f i 1 0 790 "790" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2126 ( max 11 10 12 1 0 0 0 t f f f f f i 1 0 1114 "1114" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2127 ( max 11 10 12 1 0 0 0 t f f f f f i 1 0 1184 "1184" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2128 ( max 11 10 12 1 0 0 0 t f f f f f i 1 0 1186 "1186" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2129 ( max 11 10 12 1 0 0 0 t f f f f f i 1 0 25 "25" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2130 ( max 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2050 ( max 11 10 12 1 0 0 0 t f f f f f i 1 0 2277 "2277" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2244 ( max 11 10 12 1 0 0 0 t f f f f f i 1 0 1042 "1042" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2797 ( max 11 10 12 1 0 0 0 t f f f f f i 1 0 27 "27" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2131 ( min 11 10 12 1 0 0 0 t f f f f f i 1 0 20 "20" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2132 ( min 11 10 12 1 0 0 0 t f f f f f i 1 0 23 "23" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2133 ( min 11 10 12 1 0 0 0 t f f f f f i 1 0 21 "21" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2134 ( min 11 10 12 1 0 0 0 t f f f f f i 1 0 26 "26" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2135 ( min 11 10 12 1 0 0 0 t f f f f f i 1 0 700 "700" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2136 ( min 11 10 12 1 0 0 0 t f f f f f i 1 0 701 "701" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2137 ( min 11 10 12 1 0 0 0 t f f f f f i 1 0 702 "702" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2138 ( min 11 10 12 1 0 0 0 t f f f f f i 1 0 1082 "1082" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2139 ( min 11 10 12 1 0 0 0 t f f f f f i 1 0 1083 "1083" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2140 ( min 11 10 12 1 0 0 0 t f f f f f i 1 0 1266 "1266" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2141 ( min 11 10 12 1 0 0 0 t f f f f f i 1 0 790 "790" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2142 ( min 11 10 12 1 0 0 0 t f f f f f i 1 0 1114 "1114" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2143 ( min 11 10 12 1 0 0 0 t f f f f f i 1 0 1184 "1184" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2144 ( min 11 10 12 1 0 0 0 t f f f f f i 1 0 1186 "1186" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2145 ( min 11 10 12 1 0 0 0 t f f f f f i 1 0 25 "25" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2146 ( min 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2051 ( min 11 10 12 1 0 0 0 t f f f f f i 1 0 2277 "2277" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2245 ( min 11 10 12 1 0 0 0 t f f f f f i 1 0 1042 "1042" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2798 ( min 11 10 12 1 0 0 0 t f f f f f i 1 0 27 "27" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2147 ( count 11 10 12 1 0 0 0 t f f f f f i 1 0 20 "2276" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2803 ( count 11 10 12 1 0 0 0 t f f f f f i 0 0 20 "" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2718 ( var_pop 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "20" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2719 ( var_pop 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "23" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2720 ( var_pop 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "21" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2721 ( var_pop 11 10 12 1 0 0 0 t f f f f f i 1 0 701 "700" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2722 ( var_pop 11 10 12 1 0 0 0 t f f f f f i 1 0 701 "701" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2723 ( var_pop 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2641 ( var_samp 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "20" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2642 ( var_samp 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "23" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2643 ( var_samp 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "21" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2644 ( var_samp 11 10 12 1 0 0 0 t f f f f f i 1 0 701 "700" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2645 ( var_samp 11 10 12 1 0 0 0 t f f f f f i 1 0 701 "701" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2646 ( var_samp 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2148 ( variance 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "20" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2149 ( variance 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "23" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2150 ( variance 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "21" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2151 ( variance 11 10 12 1 0 0 0 t f f f f f i 1 0 701 "700" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2152 ( variance 11 10 12 1 0 0 0 t f f f f f i 1 0 701 "701" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2153 ( variance 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2724 ( stddev_pop 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "20" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2725 ( stddev_pop 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "23" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2726 ( stddev_pop 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "21" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2727 ( stddev_pop 11 10 12 1 0 0 0 t f f f f f i 1 0 701 "700" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2728 ( stddev_pop 11 10 12 1 0 0 0 t f f f f f i 1 0 701 "701" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2729 ( stddev_pop 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2712 ( stddev_samp 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "20" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2713 ( stddev_samp 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "23" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2714 ( stddev_samp 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "21" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2715 ( stddev_samp 11 10 12 1 0 0 0 t f f f f f i 1 0 701 "700" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2716 ( stddev_samp 11 10 12 1 0 0 0 t f f f f f i 1 0 701 "701" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2717 ( stddev_samp 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2154 ( stddev 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "20" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2155 ( stddev 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "23" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2156 ( stddev 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "21" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2157 ( stddev 11 10 12 1 0 0 0 t f f f f f i 1 0 701 "700" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2158 ( stddev 11 10 12 1 0 0 0 t f f f f f i 1 0 701 "701" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2159 ( stddev 11 10 12 1 0 0 0 t f f f f f i 1 0 1700 "1700" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2818 ( regr_count 11 10 12 1 0 0 0 t f f f f f i 2 0 20 "701 701" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2819 ( regr_sxx 11 10 12 1 0 0 0 t f f f f f i 2 0 701 "701 701" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2820 ( regr_syy 11 10 12 1 0 0 0 t f f f f f i 2 0 701 "701 701" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2821 ( regr_sxy 11 10 12 1 0 0 0 t f f f f f i 2 0 701 "701 701" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2822 ( regr_avgx 11 10 12 1 0 0 0 t f f f f f i 2 0 701 "701 701" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2823 ( regr_avgy 11 10 12 1 0 0 0 t f f f f f i 2 0 701 "701 701" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2824 ( regr_r2 11 10 12 1 0 0 0 t f f f f f i 2 0 701 "701 701" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2825 ( regr_slope 11 10 12 1 0 0 0 t f f f f f i 2 0 701 "701 701" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2826 ( regr_intercept 11 10 12 1 0 0 0 t f f f f f i 2 0 701 "701 701" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2827 ( covar_pop 11 10 12 1 0 0 0 t f f f f f i 2 0 701 "701 701" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2828 ( covar_samp 11 10 12 1 0 0 0 t f f f f f i 2 0 701 "701 701" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2829 ( corr 11 10 12 1 0 0 0 t f f f f f i 2 0 701 "701 701" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2160 ( text_pattern_lt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "25 25" _null_ _null_ _null_ _null_ text_pattern_lt _null_ _null_ _null_ ) +insert OID = 2161 ( text_pattern_le 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "25 25" _null_ _null_ _null_ _null_ text_pattern_le _null_ _null_ _null_ ) +insert OID = 2163 ( text_pattern_ge 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "25 25" _null_ _null_ _null_ _null_ text_pattern_ge _null_ _null_ _null_ ) +insert OID = 2164 ( text_pattern_gt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "25 25" _null_ _null_ _null_ _null_ text_pattern_gt _null_ _null_ _null_ ) +insert OID = 2166 ( bttext_pattern_cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "25 25" _null_ _null_ _null_ _null_ bttext_pattern_cmp _null_ _null_ _null_ ) +insert OID = 2174 ( bpchar_pattern_lt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1042 1042" _null_ _null_ _null_ _null_ bpchar_pattern_lt _null_ _null_ _null_ ) +insert OID = 2175 ( bpchar_pattern_le 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1042 1042" _null_ _null_ _null_ _null_ bpchar_pattern_le _null_ _null_ _null_ ) +insert OID = 2177 ( bpchar_pattern_ge 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1042 1042" _null_ _null_ _null_ _null_ bpchar_pattern_ge _null_ _null_ _null_ ) +insert OID = 2178 ( bpchar_pattern_gt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1042 1042" _null_ _null_ _null_ _null_ bpchar_pattern_gt _null_ _null_ _null_ ) +insert OID = 2180 ( btbpchar_pattern_cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "1042 1042" _null_ _null_ _null_ _null_ btbpchar_pattern_cmp _null_ _null_ _null_ ) +insert OID = 2188 ( btint48cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "23 20" _null_ _null_ _null_ _null_ btint48cmp _null_ _null_ _null_ ) +insert OID = 2189 ( btint84cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "20 23" _null_ _null_ _null_ _null_ btint84cmp _null_ _null_ _null_ ) +insert OID = 2190 ( btint24cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "21 23" _null_ _null_ _null_ _null_ btint24cmp _null_ _null_ _null_ ) +insert OID = 2191 ( btint42cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "23 21" _null_ _null_ _null_ _null_ btint42cmp _null_ _null_ _null_ ) +insert OID = 2192 ( btint28cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "21 20" _null_ _null_ _null_ _null_ btint28cmp _null_ _null_ _null_ ) +insert OID = 2193 ( btint82cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "20 21" _null_ _null_ _null_ _null_ btint82cmp _null_ _null_ _null_ ) +insert OID = 2194 ( btfloat48cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "700 701" _null_ _null_ _null_ _null_ btfloat48cmp _null_ _null_ _null_ ) +insert OID = 2195 ( btfloat84cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "701 700" _null_ _null_ _null_ _null_ btfloat84cmp _null_ _null_ _null_ ) +insert OID = 2212 ( regprocedurein 11 10 12 1 0 0 0 f f f f t f s 1 0 2202 "2275" _null_ _null_ _null_ _null_ regprocedurein _null_ _null_ _null_ ) +insert OID = 2213 ( regprocedureout 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "2202" _null_ _null_ _null_ _null_ regprocedureout _null_ _null_ _null_ ) +insert OID = 2214 ( regoperin 11 10 12 1 0 0 0 f f f f t f s 1 0 2203 "2275" _null_ _null_ _null_ _null_ regoperin _null_ _null_ _null_ ) +insert OID = 2215 ( regoperout 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "2203" _null_ _null_ _null_ _null_ regoperout _null_ _null_ _null_ ) +insert OID = 2216 ( regoperatorin 11 10 12 1 0 0 0 f f f f t f s 1 0 2204 "2275" _null_ _null_ _null_ _null_ regoperatorin _null_ _null_ _null_ ) +insert OID = 2217 ( regoperatorout 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "2204" _null_ _null_ _null_ _null_ regoperatorout _null_ _null_ _null_ ) +insert OID = 2218 ( regclassin 11 10 12 1 0 0 0 f f f f t f s 1 0 2205 "2275" _null_ _null_ _null_ _null_ regclassin _null_ _null_ _null_ ) +insert OID = 2219 ( regclassout 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "2205" _null_ _null_ _null_ _null_ regclassout _null_ _null_ _null_ ) +insert OID = 2220 ( regtypein 11 10 12 1 0 0 0 f f f f t f s 1 0 2206 "2275" _null_ _null_ _null_ _null_ regtypein _null_ _null_ _null_ ) +insert OID = 2221 ( regtypeout 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "2206" _null_ _null_ _null_ _null_ regtypeout _null_ _null_ _null_ ) +insert OID = 1079 ( regclass 11 10 12 1 0 0 0 f f f f t f s 1 0 2205 "25" _null_ _null_ _null_ _null_ text_regclass _null_ _null_ _null_ ) +insert OID = 2246 ( fmgr_internal_validator 11 10 12 1 0 0 0 f f f f t f s 1 0 2278 "26" _null_ _null_ _null_ _null_ fmgr_internal_validator _null_ _null_ _null_ ) +insert OID = 2247 ( fmgr_c_validator 11 10 12 1 0 0 0 f f f f t f s 1 0 2278 "26" _null_ _null_ _null_ _null_ fmgr_c_validator _null_ _null_ _null_ ) +insert OID = 2248 ( fmgr_sql_validator 11 10 12 1 0 0 0 f f f f t f s 1 0 2278 "26" _null_ _null_ _null_ _null_ fmgr_sql_validator _null_ _null_ _null_ ) +insert OID = 2250 ( has_database_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "19 25 25" _null_ _null_ _null_ _null_ has_database_privilege_name_name _null_ _null_ _null_ ) +insert OID = 2251 ( has_database_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "19 26 25" _null_ _null_ _null_ _null_ has_database_privilege_name_id _null_ _null_ _null_ ) +insert OID = 2252 ( has_database_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "26 25 25" _null_ _null_ _null_ _null_ has_database_privilege_id_name _null_ _null_ _null_ ) +insert OID = 2253 ( has_database_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "26 26 25" _null_ _null_ _null_ _null_ has_database_privilege_id_id _null_ _null_ _null_ ) +insert OID = 2254 ( has_database_privilege 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "25 25" _null_ _null_ _null_ _null_ has_database_privilege_name _null_ _null_ _null_ ) +insert OID = 2255 ( has_database_privilege 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "26 25" _null_ _null_ _null_ _null_ has_database_privilege_id _null_ _null_ _null_ ) +insert OID = 2256 ( has_function_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "19 25 25" _null_ _null_ _null_ _null_ has_function_privilege_name_name _null_ _null_ _null_ ) +insert OID = 2257 ( has_function_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "19 26 25" _null_ _null_ _null_ _null_ has_function_privilege_name_id _null_ _null_ _null_ ) +insert OID = 2258 ( has_function_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "26 25 25" _null_ _null_ _null_ _null_ has_function_privilege_id_name _null_ _null_ _null_ ) +insert OID = 2259 ( has_function_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "26 26 25" _null_ _null_ _null_ _null_ has_function_privilege_id_id _null_ _null_ _null_ ) +insert OID = 2260 ( has_function_privilege 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "25 25" _null_ _null_ _null_ _null_ has_function_privilege_name _null_ _null_ _null_ ) +insert OID = 2261 ( has_function_privilege 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "26 25" _null_ _null_ _null_ _null_ has_function_privilege_id _null_ _null_ _null_ ) +insert OID = 2262 ( has_language_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "19 25 25" _null_ _null_ _null_ _null_ has_language_privilege_name_name _null_ _null_ _null_ ) +insert OID = 2263 ( has_language_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "19 26 25" _null_ _null_ _null_ _null_ has_language_privilege_name_id _null_ _null_ _null_ ) +insert OID = 2264 ( has_language_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "26 25 25" _null_ _null_ _null_ _null_ has_language_privilege_id_name _null_ _null_ _null_ ) +insert OID = 2265 ( has_language_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "26 26 25" _null_ _null_ _null_ _null_ has_language_privilege_id_id _null_ _null_ _null_ ) +insert OID = 2266 ( has_language_privilege 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "25 25" _null_ _null_ _null_ _null_ has_language_privilege_name _null_ _null_ _null_ ) +insert OID = 2267 ( has_language_privilege 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "26 25" _null_ _null_ _null_ _null_ has_language_privilege_id _null_ _null_ _null_ ) +insert OID = 2268 ( has_schema_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "19 25 25" _null_ _null_ _null_ _null_ has_schema_privilege_name_name _null_ _null_ _null_ ) +insert OID = 2269 ( has_schema_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "19 26 25" _null_ _null_ _null_ _null_ has_schema_privilege_name_id _null_ _null_ _null_ ) +insert OID = 2270 ( has_schema_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "26 25 25" _null_ _null_ _null_ _null_ has_schema_privilege_id_name _null_ _null_ _null_ ) +insert OID = 2271 ( has_schema_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "26 26 25" _null_ _null_ _null_ _null_ has_schema_privilege_id_id _null_ _null_ _null_ ) +insert OID = 2272 ( has_schema_privilege 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "25 25" _null_ _null_ _null_ _null_ has_schema_privilege_name _null_ _null_ _null_ ) +insert OID = 2273 ( has_schema_privilege 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "26 25" _null_ _null_ _null_ _null_ has_schema_privilege_id _null_ _null_ _null_ ) +insert OID = 2390 ( has_tablespace_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "19 25 25" _null_ _null_ _null_ _null_ has_tablespace_privilege_name_name _null_ _null_ _null_ ) +insert OID = 2391 ( has_tablespace_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "19 26 25" _null_ _null_ _null_ _null_ has_tablespace_privilege_name_id _null_ _null_ _null_ ) +insert OID = 2392 ( has_tablespace_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "26 25 25" _null_ _null_ _null_ _null_ has_tablespace_privilege_id_name _null_ _null_ _null_ ) +insert OID = 2393 ( has_tablespace_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "26 26 25" _null_ _null_ _null_ _null_ has_tablespace_privilege_id_id _null_ _null_ _null_ ) +insert OID = 2394 ( has_tablespace_privilege 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "25 25" _null_ _null_ _null_ _null_ has_tablespace_privilege_name _null_ _null_ _null_ ) +insert OID = 2395 ( has_tablespace_privilege 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "26 25" _null_ _null_ _null_ _null_ has_tablespace_privilege_id _null_ _null_ _null_ ) +insert OID = 3000 ( has_foreign_data_wrapper_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "19 25 25" _null_ _null_ _null_ _null_ has_foreign_data_wrapper_privilege_name_name _null_ _null_ _null_ ) +insert OID = 3001 ( has_foreign_data_wrapper_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "19 26 25" _null_ _null_ _null_ _null_ has_foreign_data_wrapper_privilege_name_id _null_ _null_ _null_ ) +insert OID = 3002 ( has_foreign_data_wrapper_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "26 25 25" _null_ _null_ _null_ _null_ has_foreign_data_wrapper_privilege_id_name _null_ _null_ _null_ ) +insert OID = 3003 ( has_foreign_data_wrapper_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "26 26 25" _null_ _null_ _null_ _null_ has_foreign_data_wrapper_privilege_id_id _null_ _null_ _null_ ) +insert OID = 3004 ( has_foreign_data_wrapper_privilege 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "25 25" _null_ _null_ _null_ _null_ has_foreign_data_wrapper_privilege_name _null_ _null_ _null_ ) +insert OID = 3005 ( has_foreign_data_wrapper_privilege 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "26 25" _null_ _null_ _null_ _null_ has_foreign_data_wrapper_privilege_id _null_ _null_ _null_ ) +insert OID = 3006 ( has_server_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "19 25 25" _null_ _null_ _null_ _null_ has_server_privilege_name_name _null_ _null_ _null_ ) +insert OID = 3007 ( has_server_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "19 26 25" _null_ _null_ _null_ _null_ has_server_privilege_name_id _null_ _null_ _null_ ) +insert OID = 3008 ( has_server_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "26 25 25" _null_ _null_ _null_ _null_ has_server_privilege_id_name _null_ _null_ _null_ ) +insert OID = 3009 ( has_server_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "26 26 25" _null_ _null_ _null_ _null_ has_server_privilege_id_id _null_ _null_ _null_ ) +insert OID = 3010 ( has_server_privilege 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "25 25" _null_ _null_ _null_ _null_ has_server_privilege_name _null_ _null_ _null_ ) +insert OID = 3011 ( has_server_privilege 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "26 25" _null_ _null_ _null_ _null_ has_server_privilege_id _null_ _null_ _null_ ) +insert OID = 3138 ( has_type_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "19 25 25" _null_ _null_ _null_ _null_ has_type_privilege_name_name _null_ _null_ _null_ ) +insert OID = 3139 ( has_type_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "19 26 25" _null_ _null_ _null_ _null_ has_type_privilege_name_id _null_ _null_ _null_ ) +insert OID = 3140 ( has_type_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "26 25 25" _null_ _null_ _null_ _null_ has_type_privilege_id_name _null_ _null_ _null_ ) +insert OID = 3141 ( has_type_privilege 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "26 26 25" _null_ _null_ _null_ _null_ has_type_privilege_id_id _null_ _null_ _null_ ) +insert OID = 3142 ( has_type_privilege 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "25 25" _null_ _null_ _null_ _null_ has_type_privilege_name _null_ _null_ _null_ ) +insert OID = 3143 ( has_type_privilege 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "26 25" _null_ _null_ _null_ _null_ has_type_privilege_id _null_ _null_ _null_ ) +insert OID = 2705 ( pg_has_role 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "19 19 25" _null_ _null_ _null_ _null_ pg_has_role_name_name _null_ _null_ _null_ ) +insert OID = 2706 ( pg_has_role 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "19 26 25" _null_ _null_ _null_ _null_ pg_has_role_name_id _null_ _null_ _null_ ) +insert OID = 2707 ( pg_has_role 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "26 19 25" _null_ _null_ _null_ _null_ pg_has_role_id_name _null_ _null_ _null_ ) +insert OID = 2708 ( pg_has_role 11 10 12 1 0 0 0 f f f f t f s 3 0 16 "26 26 25" _null_ _null_ _null_ _null_ pg_has_role_id_id _null_ _null_ _null_ ) +insert OID = 2709 ( pg_has_role 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "19 25" _null_ _null_ _null_ _null_ pg_has_role_name _null_ _null_ _null_ ) +insert OID = 2710 ( pg_has_role 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "26 25" _null_ _null_ _null_ _null_ pg_has_role_id _null_ _null_ _null_ ) +insert OID = 1269 ( pg_column_size 11 10 12 1 0 0 0 f f f f t f s 1 0 23 "2276" _null_ _null_ _null_ _null_ pg_column_size _null_ _null_ _null_ ) +insert OID = 2322 ( pg_tablespace_size 11 10 12 1 0 0 0 f f f f t f v 1 0 20 "26" _null_ _null_ _null_ _null_ pg_tablespace_size_oid _null_ _null_ _null_ ) +insert OID = 2323 ( pg_tablespace_size 11 10 12 1 0 0 0 f f f f t f v 1 0 20 "19" _null_ _null_ _null_ _null_ pg_tablespace_size_name _null_ _null_ _null_ ) +insert OID = 2324 ( pg_database_size 11 10 12 1 0 0 0 f f f f t f v 1 0 20 "26" _null_ _null_ _null_ _null_ pg_database_size_oid _null_ _null_ _null_ ) +insert OID = 2168 ( pg_database_size 11 10 12 1 0 0 0 f f f f t f v 1 0 20 "19" _null_ _null_ _null_ _null_ pg_database_size_name _null_ _null_ _null_ ) +insert OID = 2325 ( pg_relation_size 11 10 14 1 0 0 0 f f f f t f v 1 0 20 "2205" _null_ _null_ _null_ _null_ "select pg_catalog.pg_relation_size($1, ''main'')" _null_ _null_ _null_ ) +insert OID = 2332 ( pg_relation_size 11 10 12 1 0 0 0 f f f f t f v 2 0 20 "2205 25" _null_ _null_ _null_ _null_ pg_relation_size _null_ _null_ _null_ ) +insert OID = 2286 ( pg_total_relation_size 11 10 12 1 0 0 0 f f f f t f v 1 0 20 "2205" _null_ _null_ _null_ _null_ pg_total_relation_size _null_ _null_ _null_ ) +insert OID = 2288 ( pg_size_pretty 11 10 12 1 0 0 0 f f f f t f v 1 0 25 "20" _null_ _null_ _null_ _null_ pg_size_pretty _null_ _null_ _null_ ) +insert OID = 3166 ( pg_size_pretty 11 10 12 1 0 0 0 f f f f t f v 1 0 25 "1700" _null_ _null_ _null_ _null_ pg_size_pretty_numeric _null_ _null_ _null_ ) +insert OID = 2997 ( pg_table_size 11 10 12 1 0 0 0 f f f f t f v 1 0 20 "2205" _null_ _null_ _null_ _null_ pg_table_size _null_ _null_ _null_ ) +insert OID = 2998 ( pg_indexes_size 11 10 12 1 0 0 0 f f f f t f v 1 0 20 "2205" _null_ _null_ _null_ _null_ pg_indexes_size _null_ _null_ _null_ ) +insert OID = 2999 ( pg_relation_filenode 11 10 12 1 0 0 0 f f f f t f s 1 0 26 "2205" _null_ _null_ _null_ _null_ pg_relation_filenode _null_ _null_ _null_ ) +insert OID = 3034 ( pg_relation_filepath 11 10 12 1 0 0 0 f f f f t f s 1 0 25 "2205" _null_ _null_ _null_ _null_ pg_relation_filepath _null_ _null_ _null_ ) +insert OID = 2316 ( postgresql_fdw_validator 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1009 26" _null_ _null_ _null_ _null_ postgresql_fdw_validator _null_ _null_ _null_) +insert OID = 2290 ( record_in 11 10 12 1 0 0 0 f f f f t f s 3 0 2249 "2275 26 23" _null_ _null_ _null_ _null_ record_in _null_ _null_ _null_ ) +insert OID = 2291 ( record_out 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "2249" _null_ _null_ _null_ _null_ record_out _null_ _null_ _null_ ) +insert OID = 2292 ( cstring_in 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "2275" _null_ _null_ _null_ _null_ cstring_in _null_ _null_ _null_ ) +insert OID = 2293 ( cstring_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "2275" _null_ _null_ _null_ _null_ cstring_out _null_ _null_ _null_ ) +insert OID = 2294 ( any_in 11 10 12 1 0 0 0 f f f f t f i 1 0 2276 "2275" _null_ _null_ _null_ _null_ any_in _null_ _null_ _null_ ) +insert OID = 2295 ( any_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "2276" _null_ _null_ _null_ _null_ any_out _null_ _null_ _null_ ) +insert OID = 2296 ( anyarray_in 11 10 12 1 0 0 0 f f f f t f i 1 0 2277 "2275" _null_ _null_ _null_ _null_ anyarray_in _null_ _null_ _null_ ) +insert OID = 2297 ( anyarray_out 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "2277" _null_ _null_ _null_ _null_ anyarray_out _null_ _null_ _null_ ) +insert OID = 2298 ( void_in 11 10 12 1 0 0 0 f f f f t f i 1 0 2278 "2275" _null_ _null_ _null_ _null_ void_in _null_ _null_ _null_ ) +insert OID = 2299 ( void_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "2278" _null_ _null_ _null_ _null_ void_out _null_ _null_ _null_ ) +insert OID = 2300 ( trigger_in 11 10 12 1 0 0 0 f f f f f f i 1 0 2279 "2275" _null_ _null_ _null_ _null_ trigger_in _null_ _null_ _null_ ) +insert OID = 2301 ( trigger_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "2279" _null_ _null_ _null_ _null_ trigger_out _null_ _null_ _null_ ) +insert OID = 2302 ( language_handler_in 11 10 12 1 0 0 0 f f f f f f i 1 0 2280 "2275" _null_ _null_ _null_ _null_ language_handler_in _null_ _null_ _null_ ) +insert OID = 2303 ( language_handler_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "2280" _null_ _null_ _null_ _null_ language_handler_out _null_ _null_ _null_ ) +insert OID = 2304 ( internal_in 11 10 12 1 0 0 0 f f f f f f i 1 0 2281 "2275" _null_ _null_ _null_ _null_ internal_in _null_ _null_ _null_ ) +insert OID = 2305 ( internal_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "2281" _null_ _null_ _null_ _null_ internal_out _null_ _null_ _null_ ) +insert OID = 2306 ( opaque_in 11 10 12 1 0 0 0 f f f f f f i 1 0 2282 "2275" _null_ _null_ _null_ _null_ opaque_in _null_ _null_ _null_ ) +insert OID = 2307 ( opaque_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "2282" _null_ _null_ _null_ _null_ opaque_out _null_ _null_ _null_ ) +insert OID = 2312 ( anyelement_in 11 10 12 1 0 0 0 f f f f t f i 1 0 2283 "2275" _null_ _null_ _null_ _null_ anyelement_in _null_ _null_ _null_ ) +insert OID = 2313 ( anyelement_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "2283" _null_ _null_ _null_ _null_ anyelement_out _null_ _null_ _null_ ) +insert OID = 2398 ( shell_in 11 10 12 1 0 0 0 f f f f f f i 1 0 2282 "2275" _null_ _null_ _null_ _null_ shell_in _null_ _null_ _null_ ) +insert OID = 2399 ( shell_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "2282" _null_ _null_ _null_ _null_ shell_out _null_ _null_ _null_ ) +insert OID = 2597 ( domain_in 11 10 12 1 0 0 0 f f f f f f s 3 0 2276 "2275 26 23" _null_ _null_ _null_ _null_ domain_in _null_ _null_ _null_ ) +insert OID = 2598 ( domain_recv 11 10 12 1 0 0 0 f f f f f f s 3 0 2276 "2281 26 23" _null_ _null_ _null_ _null_ domain_recv _null_ _null_ _null_ ) +insert OID = 2777 ( anynonarray_in 11 10 12 1 0 0 0 f f f f t f i 1 0 2776 "2275" _null_ _null_ _null_ _null_ anynonarray_in _null_ _null_ _null_ ) +insert OID = 2778 ( anynonarray_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "2776" _null_ _null_ _null_ _null_ anynonarray_out _null_ _null_ _null_ ) +insert OID = 3116 ( fdw_handler_in 11 10 12 1 0 0 0 f f f f f f i 1 0 3115 "2275" _null_ _null_ _null_ _null_ fdw_handler_in _null_ _null_ _null_ ) +insert OID = 3117 ( fdw_handler_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "3115" _null_ _null_ _null_ _null_ fdw_handler_out _null_ _null_ _null_ ) +insert OID = 2311 ( md5 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "25" _null_ _null_ _null_ _null_ md5_text _null_ _null_ _null_ ) +insert OID = 2321 ( md5 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "17" _null_ _null_ _null_ _null_ md5_bytea _null_ _null_ _null_ ) +insert OID = 2338 ( date_lt_timestamp 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1082 1114" _null_ _null_ _null_ _null_ date_lt_timestamp _null_ _null_ _null_ ) +insert OID = 2339 ( date_le_timestamp 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1082 1114" _null_ _null_ _null_ _null_ date_le_timestamp _null_ _null_ _null_ ) +insert OID = 2340 ( date_eq_timestamp 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1082 1114" _null_ _null_ _null_ _null_ date_eq_timestamp _null_ _null_ _null_ ) +insert OID = 2341 ( date_gt_timestamp 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1082 1114" _null_ _null_ _null_ _null_ date_gt_timestamp _null_ _null_ _null_ ) +insert OID = 2342 ( date_ge_timestamp 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1082 1114" _null_ _null_ _null_ _null_ date_ge_timestamp _null_ _null_ _null_ ) +insert OID = 2343 ( date_ne_timestamp 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1082 1114" _null_ _null_ _null_ _null_ date_ne_timestamp _null_ _null_ _null_ ) +insert OID = 2344 ( date_cmp_timestamp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "1082 1114" _null_ _null_ _null_ _null_ date_cmp_timestamp _null_ _null_ _null_ ) +insert OID = 2351 ( date_lt_timestamptz 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "1082 1184" _null_ _null_ _null_ _null_ date_lt_timestamptz _null_ _null_ _null_ ) +insert OID = 2352 ( date_le_timestamptz 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "1082 1184" _null_ _null_ _null_ _null_ date_le_timestamptz _null_ _null_ _null_ ) +insert OID = 2353 ( date_eq_timestamptz 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "1082 1184" _null_ _null_ _null_ _null_ date_eq_timestamptz _null_ _null_ _null_ ) +insert OID = 2354 ( date_gt_timestamptz 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "1082 1184" _null_ _null_ _null_ _null_ date_gt_timestamptz _null_ _null_ _null_ ) +insert OID = 2355 ( date_ge_timestamptz 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "1082 1184" _null_ _null_ _null_ _null_ date_ge_timestamptz _null_ _null_ _null_ ) +insert OID = 2356 ( date_ne_timestamptz 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "1082 1184" _null_ _null_ _null_ _null_ date_ne_timestamptz _null_ _null_ _null_ ) +insert OID = 2357 ( date_cmp_timestamptz 11 10 12 1 0 0 0 f f f f t f s 2 0 23 "1082 1184" _null_ _null_ _null_ _null_ date_cmp_timestamptz _null_ _null_ _null_ ) +insert OID = 2364 ( timestamp_lt_date 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1114 1082" _null_ _null_ _null_ _null_ timestamp_lt_date _null_ _null_ _null_ ) +insert OID = 2365 ( timestamp_le_date 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1114 1082" _null_ _null_ _null_ _null_ timestamp_le_date _null_ _null_ _null_ ) +insert OID = 2366 ( timestamp_eq_date 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1114 1082" _null_ _null_ _null_ _null_ timestamp_eq_date _null_ _null_ _null_ ) +insert OID = 2367 ( timestamp_gt_date 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1114 1082" _null_ _null_ _null_ _null_ timestamp_gt_date _null_ _null_ _null_ ) +insert OID = 2368 ( timestamp_ge_date 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1114 1082" _null_ _null_ _null_ _null_ timestamp_ge_date _null_ _null_ _null_ ) +insert OID = 2369 ( timestamp_ne_date 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "1114 1082" _null_ _null_ _null_ _null_ timestamp_ne_date _null_ _null_ _null_ ) +insert OID = 2370 ( timestamp_cmp_date 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "1114 1082" _null_ _null_ _null_ _null_ timestamp_cmp_date _null_ _null_ _null_ ) +insert OID = 2377 ( timestamptz_lt_date 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "1184 1082" _null_ _null_ _null_ _null_ timestamptz_lt_date _null_ _null_ _null_ ) +insert OID = 2378 ( timestamptz_le_date 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "1184 1082" _null_ _null_ _null_ _null_ timestamptz_le_date _null_ _null_ _null_ ) +insert OID = 2379 ( timestamptz_eq_date 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "1184 1082" _null_ _null_ _null_ _null_ timestamptz_eq_date _null_ _null_ _null_ ) +insert OID = 2380 ( timestamptz_gt_date 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "1184 1082" _null_ _null_ _null_ _null_ timestamptz_gt_date _null_ _null_ _null_ ) +insert OID = 2381 ( timestamptz_ge_date 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "1184 1082" _null_ _null_ _null_ _null_ timestamptz_ge_date _null_ _null_ _null_ ) +insert OID = 2382 ( timestamptz_ne_date 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "1184 1082" _null_ _null_ _null_ _null_ timestamptz_ne_date _null_ _null_ _null_ ) +insert OID = 2383 ( timestamptz_cmp_date 11 10 12 1 0 0 0 f f f f t f s 2 0 23 "1184 1082" _null_ _null_ _null_ _null_ timestamptz_cmp_date _null_ _null_ _null_ ) +insert OID = 2520 ( timestamp_lt_timestamptz 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "1114 1184" _null_ _null_ _null_ _null_ timestamp_lt_timestamptz _null_ _null_ _null_ ) +insert OID = 2521 ( timestamp_le_timestamptz 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "1114 1184" _null_ _null_ _null_ _null_ timestamp_le_timestamptz _null_ _null_ _null_ ) +insert OID = 2522 ( timestamp_eq_timestamptz 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "1114 1184" _null_ _null_ _null_ _null_ timestamp_eq_timestamptz _null_ _null_ _null_ ) +insert OID = 2523 ( timestamp_gt_timestamptz 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "1114 1184" _null_ _null_ _null_ _null_ timestamp_gt_timestamptz _null_ _null_ _null_ ) +insert OID = 2524 ( timestamp_ge_timestamptz 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "1114 1184" _null_ _null_ _null_ _null_ timestamp_ge_timestamptz _null_ _null_ _null_ ) +insert OID = 2525 ( timestamp_ne_timestamptz 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "1114 1184" _null_ _null_ _null_ _null_ timestamp_ne_timestamptz _null_ _null_ _null_ ) +insert OID = 2526 ( timestamp_cmp_timestamptz 11 10 12 1 0 0 0 f f f f t f s 2 0 23 "1114 1184" _null_ _null_ _null_ _null_ timestamp_cmp_timestamptz _null_ _null_ _null_ ) +insert OID = 2527 ( timestamptz_lt_timestamp 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "1184 1114" _null_ _null_ _null_ _null_ timestamptz_lt_timestamp _null_ _null_ _null_ ) +insert OID = 2528 ( timestamptz_le_timestamp 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "1184 1114" _null_ _null_ _null_ _null_ timestamptz_le_timestamp _null_ _null_ _null_ ) +insert OID = 2529 ( timestamptz_eq_timestamp 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "1184 1114" _null_ _null_ _null_ _null_ timestamptz_eq_timestamp _null_ _null_ _null_ ) +insert OID = 2530 ( timestamptz_gt_timestamp 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "1184 1114" _null_ _null_ _null_ _null_ timestamptz_gt_timestamp _null_ _null_ _null_ ) +insert OID = 2531 ( timestamptz_ge_timestamp 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "1184 1114" _null_ _null_ _null_ _null_ timestamptz_ge_timestamp _null_ _null_ _null_ ) +insert OID = 2532 ( timestamptz_ne_timestamp 11 10 12 1 0 0 0 f f f f t f s 2 0 16 "1184 1114" _null_ _null_ _null_ _null_ timestamptz_ne_timestamp _null_ _null_ _null_ ) +insert OID = 2533 ( timestamptz_cmp_timestamp 11 10 12 1 0 0 0 f f f f t f s 2 0 23 "1184 1114" _null_ _null_ _null_ _null_ timestamptz_cmp_timestamp _null_ _null_ _null_ ) +insert OID = 2400 ( array_recv 11 10 12 1 0 0 0 f f f f t f s 3 0 2277 "2281 26 23" _null_ _null_ _null_ _null_ array_recv _null_ _null_ _null_ ) +insert OID = 2401 ( array_send 11 10 12 1 0 0 0 f f f f t f s 1 0 17 "2277" _null_ _null_ _null_ _null_ array_send _null_ _null_ _null_ ) +insert OID = 2402 ( record_recv 11 10 12 1 0 0 0 f f f f t f s 3 0 2249 "2281 26 23" _null_ _null_ _null_ _null_ record_recv _null_ _null_ _null_ ) +insert OID = 2403 ( record_send 11 10 12 1 0 0 0 f f f f t f s 1 0 17 "2249" _null_ _null_ _null_ _null_ record_send _null_ _null_ _null_ ) +insert OID = 2404 ( int2recv 11 10 12 1 0 0 0 f f f f t f i 1 0 21 "2281" _null_ _null_ _null_ _null_ int2recv _null_ _null_ _null_ ) +insert OID = 2405 ( int2send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "21" _null_ _null_ _null_ _null_ int2send _null_ _null_ _null_ ) +insert OID = 2406 ( int4recv 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "2281" _null_ _null_ _null_ _null_ int4recv _null_ _null_ _null_ ) +insert OID = 2407 ( int4send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "23" _null_ _null_ _null_ _null_ int4send _null_ _null_ _null_ ) +insert OID = 2408 ( int8recv 11 10 12 1 0 0 0 f f f f t f i 1 0 20 "2281" _null_ _null_ _null_ _null_ int8recv _null_ _null_ _null_ ) +insert OID = 2409 ( int8send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "20" _null_ _null_ _null_ _null_ int8send _null_ _null_ _null_ ) +insert OID = 2410 ( int2vectorrecv 11 10 12 1 0 0 0 f f f f t f i 1 0 22 "2281" _null_ _null_ _null_ _null_ int2vectorrecv _null_ _null_ _null_ ) +insert OID = 2411 ( int2vectorsend 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "22" _null_ _null_ _null_ _null_ int2vectorsend _null_ _null_ _null_ ) +insert OID = 2412 ( bytearecv 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "2281" _null_ _null_ _null_ _null_ bytearecv _null_ _null_ _null_ ) +insert OID = 2413 ( byteasend 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "17" _null_ _null_ _null_ _null_ byteasend _null_ _null_ _null_ ) +insert OID = 2414 ( textrecv 11 10 12 1 0 0 0 f f f f t f s 1 0 25 "2281" _null_ _null_ _null_ _null_ textrecv _null_ _null_ _null_ ) +insert OID = 2415 ( textsend 11 10 12 1 0 0 0 f f f f t f s 1 0 17 "25" _null_ _null_ _null_ _null_ textsend _null_ _null_ _null_ ) +insert OID = 2416 ( unknownrecv 11 10 12 1 0 0 0 f f f f t f i 1 0 705 "2281" _null_ _null_ _null_ _null_ unknownrecv _null_ _null_ _null_ ) +insert OID = 2417 ( unknownsend 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "705" _null_ _null_ _null_ _null_ unknownsend _null_ _null_ _null_ ) +insert OID = 2418 ( oidrecv 11 10 12 1 0 0 0 f f f f t f i 1 0 26 "2281" _null_ _null_ _null_ _null_ oidrecv _null_ _null_ _null_ ) +insert OID = 2419 ( oidsend 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "26" _null_ _null_ _null_ _null_ oidsend _null_ _null_ _null_ ) +insert OID = 2420 ( oidvectorrecv 11 10 12 1 0 0 0 f f f f t f i 1 0 30 "2281" _null_ _null_ _null_ _null_ oidvectorrecv _null_ _null_ _null_ ) +insert OID = 2421 ( oidvectorsend 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "30" _null_ _null_ _null_ _null_ oidvectorsend _null_ _null_ _null_ ) +insert OID = 2422 ( namerecv 11 10 12 1 0 0 0 f f f f t f s 1 0 19 "2281" _null_ _null_ _null_ _null_ namerecv _null_ _null_ _null_ ) +insert OID = 2423 ( namesend 11 10 12 1 0 0 0 f f f f t f s 1 0 17 "19" _null_ _null_ _null_ _null_ namesend _null_ _null_ _null_ ) +insert OID = 2424 ( float4recv 11 10 12 1 0 0 0 f f f f t f i 1 0 700 "2281" _null_ _null_ _null_ _null_ float4recv _null_ _null_ _null_ ) +insert OID = 2425 ( float4send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "700" _null_ _null_ _null_ _null_ float4send _null_ _null_ _null_ ) +insert OID = 2426 ( float8recv 11 10 12 1 0 0 0 f f f f t f i 1 0 701 "2281" _null_ _null_ _null_ _null_ float8recv _null_ _null_ _null_ ) +insert OID = 2427 ( float8send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "701" _null_ _null_ _null_ _null_ float8send _null_ _null_ _null_ ) +insert OID = 2428 ( point_recv 11 10 12 1 0 0 0 f f f f t f i 1 0 600 "2281" _null_ _null_ _null_ _null_ point_recv _null_ _null_ _null_ ) +insert OID = 2429 ( point_send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "600" _null_ _null_ _null_ _null_ point_send _null_ _null_ _null_ ) +insert OID = 2430 ( bpcharrecv 11 10 12 1 0 0 0 f f f f t f s 3 0 1042 "2281 26 23" _null_ _null_ _null_ _null_ bpcharrecv _null_ _null_ _null_ ) +insert OID = 2431 ( bpcharsend 11 10 12 1 0 0 0 f f f f t f s 1 0 17 "1042" _null_ _null_ _null_ _null_ bpcharsend _null_ _null_ _null_ ) +insert OID = 2432 ( varcharrecv 11 10 12 1 0 0 0 f f f f t f s 3 0 1043 "2281 26 23" _null_ _null_ _null_ _null_ varcharrecv _null_ _null_ _null_ ) +insert OID = 2433 ( varcharsend 11 10 12 1 0 0 0 f f f f t f s 1 0 17 "1043" _null_ _null_ _null_ _null_ varcharsend _null_ _null_ _null_ ) +insert OID = 2434 ( charrecv 11 10 12 1 0 0 0 f f f f t f i 1 0 18 "2281" _null_ _null_ _null_ _null_ charrecv _null_ _null_ _null_ ) +insert OID = 2435 ( charsend 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "18" _null_ _null_ _null_ _null_ charsend _null_ _null_ _null_ ) +insert OID = 2436 ( boolrecv 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "2281" _null_ _null_ _null_ _null_ boolrecv _null_ _null_ _null_ ) +insert OID = 2437 ( boolsend 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "16" _null_ _null_ _null_ _null_ boolsend _null_ _null_ _null_ ) +insert OID = 2438 ( tidrecv 11 10 12 1 0 0 0 f f f f t f i 1 0 27 "2281" _null_ _null_ _null_ _null_ tidrecv _null_ _null_ _null_ ) +insert OID = 2439 ( tidsend 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "27" _null_ _null_ _null_ _null_ tidsend _null_ _null_ _null_ ) +insert OID = 2440 ( xidrecv 11 10 12 1 0 0 0 f f f f t f i 1 0 28 "2281" _null_ _null_ _null_ _null_ xidrecv _null_ _null_ _null_ ) +insert OID = 2441 ( xidsend 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "28" _null_ _null_ _null_ _null_ xidsend _null_ _null_ _null_ ) +insert OID = 2442 ( cidrecv 11 10 12 1 0 0 0 f f f f t f i 1 0 29 "2281" _null_ _null_ _null_ _null_ cidrecv _null_ _null_ _null_ ) +insert OID = 2443 ( cidsend 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "29" _null_ _null_ _null_ _null_ cidsend _null_ _null_ _null_ ) +insert OID = 2444 ( regprocrecv 11 10 12 1 0 0 0 f f f f t f i 1 0 24 "2281" _null_ _null_ _null_ _null_ regprocrecv _null_ _null_ _null_ ) +insert OID = 2445 ( regprocsend 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "24" _null_ _null_ _null_ _null_ regprocsend _null_ _null_ _null_ ) +insert OID = 2446 ( regprocedurerecv 11 10 12 1 0 0 0 f f f f t f i 1 0 2202 "2281" _null_ _null_ _null_ _null_ regprocedurerecv _null_ _null_ _null_ ) +insert OID = 2447 ( regproceduresend 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "2202" _null_ _null_ _null_ _null_ regproceduresend _null_ _null_ _null_ ) +insert OID = 2448 ( regoperrecv 11 10 12 1 0 0 0 f f f f t f i 1 0 2203 "2281" _null_ _null_ _null_ _null_ regoperrecv _null_ _null_ _null_ ) +insert OID = 2449 ( regopersend 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "2203" _null_ _null_ _null_ _null_ regopersend _null_ _null_ _null_ ) +insert OID = 2450 ( regoperatorrecv 11 10 12 1 0 0 0 f f f f t f i 1 0 2204 "2281" _null_ _null_ _null_ _null_ regoperatorrecv _null_ _null_ _null_ ) +insert OID = 2451 ( regoperatorsend 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "2204" _null_ _null_ _null_ _null_ regoperatorsend _null_ _null_ _null_ ) +insert OID = 2452 ( regclassrecv 11 10 12 1 0 0 0 f f f f t f i 1 0 2205 "2281" _null_ _null_ _null_ _null_ regclassrecv _null_ _null_ _null_ ) +insert OID = 2453 ( regclasssend 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "2205" _null_ _null_ _null_ _null_ regclasssend _null_ _null_ _null_ ) +insert OID = 2454 ( regtyperecv 11 10 12 1 0 0 0 f f f f t f i 1 0 2206 "2281" _null_ _null_ _null_ _null_ regtyperecv _null_ _null_ _null_ ) +insert OID = 2455 ( regtypesend 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "2206" _null_ _null_ _null_ _null_ regtypesend _null_ _null_ _null_ ) +insert OID = 2456 ( bit_recv 11 10 12 1 0 0 0 f f f f t f i 3 0 1560 "2281 26 23" _null_ _null_ _null_ _null_ bit_recv _null_ _null_ _null_ ) +insert OID = 2457 ( bit_send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "1560" _null_ _null_ _null_ _null_ bit_send _null_ _null_ _null_ ) +insert OID = 2458 ( varbit_recv 11 10 12 1 0 0 0 f f f f t f i 3 0 1562 "2281 26 23" _null_ _null_ _null_ _null_ varbit_recv _null_ _null_ _null_ ) +insert OID = 2459 ( varbit_send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "1562" _null_ _null_ _null_ _null_ varbit_send _null_ _null_ _null_ ) +insert OID = 2460 ( numeric_recv 11 10 12 1 0 0 0 f f f f t f i 3 0 1700 "2281 26 23" _null_ _null_ _null_ _null_ numeric_recv _null_ _null_ _null_ ) +insert OID = 2461 ( numeric_send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "1700" _null_ _null_ _null_ _null_ numeric_send _null_ _null_ _null_ ) +insert OID = 2462 ( abstimerecv 11 10 12 1 0 0 0 f f f f t f i 1 0 702 "2281" _null_ _null_ _null_ _null_ abstimerecv _null_ _null_ _null_ ) +insert OID = 2463 ( abstimesend 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "702" _null_ _null_ _null_ _null_ abstimesend _null_ _null_ _null_ ) +insert OID = 2464 ( reltimerecv 11 10 12 1 0 0 0 f f f f t f i 1 0 703 "2281" _null_ _null_ _null_ _null_ reltimerecv _null_ _null_ _null_ ) +insert OID = 2465 ( reltimesend 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "703" _null_ _null_ _null_ _null_ reltimesend _null_ _null_ _null_ ) +insert OID = 2466 ( tintervalrecv 11 10 12 1 0 0 0 f f f f t f i 1 0 704 "2281" _null_ _null_ _null_ _null_ tintervalrecv _null_ _null_ _null_ ) +insert OID = 2467 ( tintervalsend 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "704" _null_ _null_ _null_ _null_ tintervalsend _null_ _null_ _null_ ) +insert OID = 2468 ( date_recv 11 10 12 1 0 0 0 f f f f t f i 1 0 1082 "2281" _null_ _null_ _null_ _null_ date_recv _null_ _null_ _null_ ) +insert OID = 2469 ( date_send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "1082" _null_ _null_ _null_ _null_ date_send _null_ _null_ _null_ ) +insert OID = 2470 ( time_recv 11 10 12 1 0 0 0 f f f f t f i 3 0 1083 "2281 26 23" _null_ _null_ _null_ _null_ time_recv _null_ _null_ _null_ ) +insert OID = 2471 ( time_send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "1083" _null_ _null_ _null_ _null_ time_send _null_ _null_ _null_ ) +insert OID = 2472 ( timetz_recv 11 10 12 1 0 0 0 f f f f t f i 3 0 1266 "2281 26 23" _null_ _null_ _null_ _null_ timetz_recv _null_ _null_ _null_ ) +insert OID = 2473 ( timetz_send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "1266" _null_ _null_ _null_ _null_ timetz_send _null_ _null_ _null_ ) +insert OID = 2474 ( timestamp_recv 11 10 12 1 0 0 0 f f f f t f i 3 0 1114 "2281 26 23" _null_ _null_ _null_ _null_ timestamp_recv _null_ _null_ _null_ ) +insert OID = 2475 ( timestamp_send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "1114" _null_ _null_ _null_ _null_ timestamp_send _null_ _null_ _null_ ) +insert OID = 2476 ( timestamptz_recv 11 10 12 1 0 0 0 f f f f t f i 3 0 1184 "2281 26 23" _null_ _null_ _null_ _null_ timestamptz_recv _null_ _null_ _null_ ) +insert OID = 2477 ( timestamptz_send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "1184" _null_ _null_ _null_ _null_ timestamptz_send _null_ _null_ _null_ ) +insert OID = 2478 ( interval_recv 11 10 12 1 0 0 0 f f f f t f i 3 0 1186 "2281 26 23" _null_ _null_ _null_ _null_ interval_recv _null_ _null_ _null_ ) +insert OID = 2479 ( interval_send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "1186" _null_ _null_ _null_ _null_ interval_send _null_ _null_ _null_ ) +insert OID = 2480 ( lseg_recv 11 10 12 1 0 0 0 f f f f t f i 1 0 601 "2281" _null_ _null_ _null_ _null_ lseg_recv _null_ _null_ _null_ ) +insert OID = 2481 ( lseg_send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "601" _null_ _null_ _null_ _null_ lseg_send _null_ _null_ _null_ ) +insert OID = 2482 ( path_recv 11 10 12 1 0 0 0 f f f f t f i 1 0 602 "2281" _null_ _null_ _null_ _null_ path_recv _null_ _null_ _null_ ) +insert OID = 2483 ( path_send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "602" _null_ _null_ _null_ _null_ path_send _null_ _null_ _null_ ) +insert OID = 2484 ( box_recv 11 10 12 1 0 0 0 f f f f t f i 1 0 603 "2281" _null_ _null_ _null_ _null_ box_recv _null_ _null_ _null_ ) +insert OID = 2485 ( box_send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "603" _null_ _null_ _null_ _null_ box_send _null_ _null_ _null_ ) +insert OID = 2486 ( poly_recv 11 10 12 1 0 0 0 f f f f t f i 1 0 604 "2281" _null_ _null_ _null_ _null_ poly_recv _null_ _null_ _null_ ) +insert OID = 2487 ( poly_send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "604" _null_ _null_ _null_ _null_ poly_send _null_ _null_ _null_ ) +insert OID = 2488 ( line_recv 11 10 12 1 0 0 0 f f f f t f i 1 0 628 "2281" _null_ _null_ _null_ _null_ line_recv _null_ _null_ _null_ ) +insert OID = 2489 ( line_send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "628" _null_ _null_ _null_ _null_ line_send _null_ _null_ _null_ ) +insert OID = 2490 ( circle_recv 11 10 12 1 0 0 0 f f f f t f i 1 0 718 "2281" _null_ _null_ _null_ _null_ circle_recv _null_ _null_ _null_ ) +insert OID = 2491 ( circle_send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "718" _null_ _null_ _null_ _null_ circle_send _null_ _null_ _null_ ) +insert OID = 2492 ( cash_recv 11 10 12 1 0 0 0 f f f f t f i 1 0 790 "2281" _null_ _null_ _null_ _null_ cash_recv _null_ _null_ _null_ ) +insert OID = 2493 ( cash_send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "790" _null_ _null_ _null_ _null_ cash_send _null_ _null_ _null_ ) +insert OID = 2494 ( macaddr_recv 11 10 12 1 0 0 0 f f f f t f i 1 0 829 "2281" _null_ _null_ _null_ _null_ macaddr_recv _null_ _null_ _null_ ) +insert OID = 2495 ( macaddr_send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "829" _null_ _null_ _null_ _null_ macaddr_send _null_ _null_ _null_ ) +insert OID = 2496 ( inet_recv 11 10 12 1 0 0 0 f f f f t f i 1 0 869 "2281" _null_ _null_ _null_ _null_ inet_recv _null_ _null_ _null_ ) +insert OID = 2497 ( inet_send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "869" _null_ _null_ _null_ _null_ inet_send _null_ _null_ _null_ ) +insert OID = 2498 ( cidr_recv 11 10 12 1 0 0 0 f f f f t f i 1 0 650 "2281" _null_ _null_ _null_ _null_ cidr_recv _null_ _null_ _null_ ) +insert OID = 2499 ( cidr_send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "650" _null_ _null_ _null_ _null_ cidr_send _null_ _null_ _null_ ) +insert OID = 2500 ( cstring_recv 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "2281" _null_ _null_ _null_ _null_ cstring_recv _null_ _null_ _null_ ) +insert OID = 2501 ( cstring_send 11 10 12 1 0 0 0 f f f f t f s 1 0 17 "2275" _null_ _null_ _null_ _null_ cstring_send _null_ _null_ _null_ ) +insert OID = 2502 ( anyarray_recv 11 10 12 1 0 0 0 f f f f t f s 1 0 2277 "2281" _null_ _null_ _null_ _null_ anyarray_recv _null_ _null_ _null_ ) +insert OID = 2503 ( anyarray_send 11 10 12 1 0 0 0 f f f f t f s 1 0 17 "2277" _null_ _null_ _null_ _null_ anyarray_send _null_ _null_ _null_ ) +insert OID = 3120 ( void_recv 11 10 12 1 0 0 0 f f f f t f i 1 0 2278 "2281" _null_ _null_ _null_ _null_ void_recv _null_ _null_ _null_ ) +insert OID = 3121 ( void_send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "2278" _null_ _null_ _null_ _null_ void_send _null_ _null_ _null_ ) +insert OID = 2504 ( pg_get_ruledef 11 10 12 1 0 0 0 f f f f t f s 2 0 25 "26 16" _null_ _null_ _null_ _null_ pg_get_ruledef_ext _null_ _null_ _null_ ) +insert OID = 2505 ( pg_get_viewdef 11 10 12 1 0 0 0 f f f f t f s 2 0 25 "25 16" _null_ _null_ _null_ _null_ pg_get_viewdef_name_ext _null_ _null_ _null_ ) +insert OID = 2506 ( pg_get_viewdef 11 10 12 1 0 0 0 f f f f t f s 2 0 25 "26 16" _null_ _null_ _null_ _null_ pg_get_viewdef_ext _null_ _null_ _null_ ) +insert OID = 3159 ( pg_get_viewdef 11 10 12 1 0 0 0 f f f f t f s 2 0 25 "26 23" _null_ _null_ _null_ _null_ pg_get_viewdef_wrap _null_ _null_ _null_ ) +insert OID = 2507 ( pg_get_indexdef 11 10 12 1 0 0 0 f f f f t f s 3 0 25 "26 23 16" _null_ _null_ _null_ _null_ pg_get_indexdef_ext _null_ _null_ _null_ ) +insert OID = 2508 ( pg_get_constraintdef 11 10 12 1 0 0 0 f f f f t f s 2 0 25 "26 16" _null_ _null_ _null_ _null_ pg_get_constraintdef_ext _null_ _null_ _null_ ) +insert OID = 2509 ( pg_get_expr 11 10 12 1 0 0 0 f f f f t f s 3 0 25 "194 26 16" _null_ _null_ _null_ _null_ pg_get_expr_ext _null_ _null_ _null_ ) +insert OID = 2510 ( pg_prepared_statement 11 10 12 1 1000 0 0 f f f f t t s 0 0 2249 "" "{25,25,1184,2211,16}" "{o,o,o,o,o}" "{name,statement,prepare_time,parameter_types,from_sql}" _null_ pg_prepared_statement _null_ _null_ _null_ ) +insert OID = 2511 ( pg_cursor 11 10 12 1 1000 0 0 f f f f t t s 0 0 2249 "" "{25,25,16,16,16,1184}" "{o,o,o,o,o,o}" "{name,statement,is_holdable,is_binary,is_scrollable,creation_time}" _null_ pg_cursor _null_ _null_ _null_ ) +insert OID = 2599 ( pg_timezone_abbrevs 11 10 12 1 1000 0 0 f f f f t t s 0 0 2249 "" "{25,1186,16}" "{o,o,o}" "{abbrev,utc_offset,is_dst}" _null_ pg_timezone_abbrevs _null_ _null_ _null_ ) +insert OID = 2856 ( pg_timezone_names 11 10 12 1 1000 0 0 f f f f t t s 0 0 2249 "" "{25,25,1186,16}" "{o,o,o,o}" "{name,abbrev,utc_offset,is_dst}" _null_ pg_timezone_names _null_ _null_ _null_ ) +insert OID = 2730 ( pg_get_triggerdef 11 10 12 1 0 0 0 f f f f t f s 2 0 25 "26 16" _null_ _null_ _null_ _null_ pg_get_triggerdef_ext _null_ _null_ _null_ ) +insert OID = 3035 ( pg_listening_channels 11 10 12 1 10 0 0 f f f f t t s 0 0 25 "" _null_ _null_ _null_ _null_ pg_listening_channels _null_ _null_ _null_ ) +insert OID = 3036 ( pg_notify 11 10 12 1 0 0 0 f f f f f f v 2 0 2278 "25 25" _null_ _null_ _null_ _null_ pg_notify _null_ _null_ _null_ ) +insert OID = 1066 ( generate_series 11 10 12 1 1000 0 0 f f f f t t i 3 0 23 "23 23 23" _null_ _null_ _null_ _null_ generate_series_step_int4 _null_ _null_ _null_ ) +insert OID = 1067 ( generate_series 11 10 12 1 1000 0 0 f f f f t t i 2 0 23 "23 23" _null_ _null_ _null_ _null_ generate_series_int4 _null_ _null_ _null_ ) +insert OID = 1068 ( generate_series 11 10 12 1 1000 0 0 f f f f t t i 3 0 20 "20 20 20" _null_ _null_ _null_ _null_ generate_series_step_int8 _null_ _null_ _null_ ) +insert OID = 1069 ( generate_series 11 10 12 1 1000 0 0 f f f f t t i 2 0 20 "20 20" _null_ _null_ _null_ _null_ generate_series_int8 _null_ _null_ _null_ ) +insert OID = 938 ( generate_series 11 10 12 1 1000 0 0 f f f f t t i 3 0 1114 "1114 1114 1186" _null_ _null_ _null_ _null_ generate_series_timestamp _null_ _null_ _null_ ) +insert OID = 939 ( generate_series 11 10 12 1 1000 0 0 f f f f t t s 3 0 1184 "1184 1184 1186" _null_ _null_ _null_ _null_ generate_series_timestamptz _null_ _null_ _null_ ) +insert OID = 2515 ( booland_statefunc 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "16 16" _null_ _null_ _null_ _null_ booland_statefunc _null_ _null_ _null_ ) +insert OID = 2516 ( boolor_statefunc 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "16 16" _null_ _null_ _null_ _null_ boolor_statefunc _null_ _null_ _null_ ) +insert OID = 2517 ( bool_and 11 10 12 1 0 0 0 t f f f f f i 1 0 16 "16" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2518 ( bool_or 11 10 12 1 0 0 0 t f f f f f i 1 0 16 "16" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2519 ( every 11 10 12 1 0 0 0 t f f f f f i 1 0 16 "16" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2236 ( bit_and 11 10 12 1 0 0 0 t f f f f f i 1 0 21 "21" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2237 ( bit_or 11 10 12 1 0 0 0 t f f f f f i 1 0 21 "21" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2238 ( bit_and 11 10 12 1 0 0 0 t f f f f f i 1 0 23 "23" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2239 ( bit_or 11 10 12 1 0 0 0 t f f f f f i 1 0 23 "23" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2240 ( bit_and 11 10 12 1 0 0 0 t f f f f f i 1 0 20 "20" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2241 ( bit_or 11 10 12 1 0 0 0 t f f f f f i 1 0 20 "20" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2242 ( bit_and 11 10 12 1 0 0 0 t f f f f f i 1 0 1560 "1560" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2243 ( bit_or 11 10 12 1 0 0 0 t f f f f f i 1 0 1560 "1560" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2546 ( interval_pl_date 11 10 14 1 0 0 0 f f f f t f i 2 0 1114 "1186 1082" _null_ _null_ _null_ _null_ "select $2 + $1" _null_ _null_ _null_ ) +insert OID = 2547 ( interval_pl_timetz 11 10 14 1 0 0 0 f f f f t f i 2 0 1266 "1186 1266" _null_ _null_ _null_ _null_ "select $2 + $1" _null_ _null_ _null_ ) +insert OID = 2548 ( interval_pl_timestamp 11 10 14 1 0 0 0 f f f f t f i 2 0 1114 "1186 1114" _null_ _null_ _null_ _null_ "select $2 + $1" _null_ _null_ _null_ ) +insert OID = 2549 ( interval_pl_timestamptz 11 10 14 1 0 0 0 f f f f t f s 2 0 1184 "1186 1184" _null_ _null_ _null_ _null_ "select $2 + $1" _null_ _null_ _null_ ) +insert OID = 2550 ( integer_pl_date 11 10 14 1 0 0 0 f f f f t f i 2 0 1082 "23 1082" _null_ _null_ _null_ _null_ "select $2 + $1" _null_ _null_ _null_ ) +insert OID = 2556 ( pg_tablespace_databases 11 10 12 1 1000 0 0 f f f f t t s 1 0 26 "26" _null_ _null_ _null_ _null_ pg_tablespace_databases _null_ _null_ _null_ ) +insert OID = 2557 ( bool 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "23" _null_ _null_ _null_ _null_ int4_bool _null_ _null_ _null_ ) +insert OID = 2558 ( int4 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "16" _null_ _null_ _null_ _null_ bool_int4 _null_ _null_ _null_ ) +insert OID = 2559 ( lastval 11 10 12 1 0 0 0 f f f f t f v 0 0 20 "" _null_ _null_ _null_ _null_ lastval _null_ _null_ _null_ ) +insert OID = 2560 ( pg_postmaster_start_time 11 10 12 1 0 0 0 f f f f t f s 0 0 1184 "" _null_ _null_ _null_ _null_ pg_postmaster_start_time _null_ _null_ _null_ ) +insert OID = 2034 ( pg_conf_load_time 11 10 12 1 0 0 0 f f f f t f s 0 0 1184 "" _null_ _null_ _null_ _null_ pg_conf_load_time _null_ _null_ _null_ ) +insert OID = 2562 ( box_below 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "603 603" _null_ _null_ _null_ _null_ box_below _null_ _null_ _null_ ) +insert OID = 2563 ( box_overbelow 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "603 603" _null_ _null_ _null_ _null_ box_overbelow _null_ _null_ _null_ ) +insert OID = 2564 ( box_overabove 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "603 603" _null_ _null_ _null_ _null_ box_overabove _null_ _null_ _null_ ) +insert OID = 2565 ( box_above 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "603 603" _null_ _null_ _null_ _null_ box_above _null_ _null_ _null_ ) +insert OID = 2566 ( poly_below 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "604 604" _null_ _null_ _null_ _null_ poly_below _null_ _null_ _null_ ) +insert OID = 2567 ( poly_overbelow 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "604 604" _null_ _null_ _null_ _null_ poly_overbelow _null_ _null_ _null_ ) +insert OID = 2568 ( poly_overabove 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "604 604" _null_ _null_ _null_ _null_ poly_overabove _null_ _null_ _null_ ) +insert OID = 2569 ( poly_above 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "604 604" _null_ _null_ _null_ _null_ poly_above _null_ _null_ _null_ ) +insert OID = 2587 ( circle_overbelow 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "718 718" _null_ _null_ _null_ _null_ circle_overbelow _null_ _null_ _null_ ) +insert OID = 2588 ( circle_overabove 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "718 718" _null_ _null_ _null_ _null_ circle_overabove _null_ _null_ _null_ ) +insert OID = 2578 ( gist_box_consistent 11 10 12 1 0 0 0 f f f f t f i 5 0 16 "2281 603 23 26 2281" _null_ _null_ _null_ _null_ gist_box_consistent _null_ _null_ _null_ ) +insert OID = 2579 ( gist_box_compress 11 10 12 1 0 0 0 f f f f t f i 1 0 2281 "2281" _null_ _null_ _null_ _null_ gist_box_compress _null_ _null_ _null_ ) +insert OID = 2580 ( gist_box_decompress 11 10 12 1 0 0 0 f f f f t f i 1 0 2281 "2281" _null_ _null_ _null_ _null_ gist_box_decompress _null_ _null_ _null_ ) +insert OID = 2581 ( gist_box_penalty 11 10 12 1 0 0 0 f f f f t f i 3 0 2281 "2281 2281 2281" _null_ _null_ _null_ _null_ gist_box_penalty _null_ _null_ _null_ ) +insert OID = 2582 ( gist_box_picksplit 11 10 12 1 0 0 0 f f f f t f i 2 0 2281 "2281 2281" _null_ _null_ _null_ _null_ gist_box_picksplit _null_ _null_ _null_ ) +insert OID = 2583 ( gist_box_union 11 10 12 1 0 0 0 f f f f t f i 2 0 603 "2281 2281" _null_ _null_ _null_ _null_ gist_box_union _null_ _null_ _null_ ) +insert OID = 2584 ( gist_box_same 11 10 12 1 0 0 0 f f f f t f i 3 0 2281 "603 603 2281" _null_ _null_ _null_ _null_ gist_box_same _null_ _null_ _null_ ) +insert OID = 2585 ( gist_poly_consistent 11 10 12 1 0 0 0 f f f f t f i 5 0 16 "2281 604 23 26 2281" _null_ _null_ _null_ _null_ gist_poly_consistent _null_ _null_ _null_ ) +insert OID = 2586 ( gist_poly_compress 11 10 12 1 0 0 0 f f f f t f i 1 0 2281 "2281" _null_ _null_ _null_ _null_ gist_poly_compress _null_ _null_ _null_ ) +insert OID = 2591 ( gist_circle_consistent 11 10 12 1 0 0 0 f f f f t f i 5 0 16 "2281 718 23 26 2281" _null_ _null_ _null_ _null_ gist_circle_consistent _null_ _null_ _null_ ) +insert OID = 2592 ( gist_circle_compress 11 10 12 1 0 0 0 f f f f t f i 1 0 2281 "2281" _null_ _null_ _null_ _null_ gist_circle_compress _null_ _null_ _null_ ) +insert OID = 1030 ( gist_point_compress 11 10 12 1 0 0 0 f f f f t f i 1 0 2281 "2281" _null_ _null_ _null_ _null_ gist_point_compress _null_ _null_ _null_ ) +insert OID = 2179 ( gist_point_consistent 11 10 12 1 0 0 0 f f f f t f i 5 0 16 "2281 600 23 26 2281" _null_ _null_ _null_ _null_ gist_point_consistent _null_ _null_ _null_ ) +insert OID = 3064 ( gist_point_distance 11 10 12 1 0 0 0 f f f f t f i 4 0 701 "2281 600 23 26" _null_ _null_ _null_ _null_ gist_point_distance _null_ _null_ _null_ ) +insert OID = 2731 ( gingetbitmap 11 10 12 1 0 0 0 f f f f t f v 2 0 20 "2281 2281" _null_ _null_ _null_ _null_ gingetbitmap _null_ _null_ _null_ ) +insert OID = 2732 ( gininsert 11 10 12 1 0 0 0 f f f f t f v 6 0 16 "2281 2281 2281 2281 2281 2281" _null_ _null_ _null_ _null_ gininsert _null_ _null_ _null_ ) +insert OID = 2733 ( ginbeginscan 11 10 12 1 0 0 0 f f f f t f v 3 0 2281 "2281 2281 2281" _null_ _null_ _null_ _null_ ginbeginscan _null_ _null_ _null_ ) +insert OID = 2734 ( ginrescan 11 10 12 1 0 0 0 f f f f t f v 5 0 2278 "2281 2281 2281 2281 2281" _null_ _null_ _null_ _null_ ginrescan _null_ _null_ _null_ ) +insert OID = 2735 ( ginendscan 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "2281" _null_ _null_ _null_ _null_ ginendscan _null_ _null_ _null_ ) +insert OID = 2736 ( ginmarkpos 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "2281" _null_ _null_ _null_ _null_ ginmarkpos _null_ _null_ _null_ ) +insert OID = 2737 ( ginrestrpos 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "2281" _null_ _null_ _null_ _null_ ginrestrpos _null_ _null_ _null_ ) +insert OID = 2738 ( ginbuild 11 10 12 1 0 0 0 f f f f t f v 3 0 2281 "2281 2281 2281" _null_ _null_ _null_ _null_ ginbuild _null_ _null_ _null_ ) +insert OID = 325 ( ginbuildempty 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "2281" _null_ _null_ _null_ _null_ ginbuildempty _null_ _null_ _null_ ) +insert OID = 2739 ( ginbulkdelete 11 10 12 1 0 0 0 f f f f t f v 4 0 2281 "2281 2281 2281 2281" _null_ _null_ _null_ _null_ ginbulkdelete _null_ _null_ _null_ ) +insert OID = 2740 ( ginvacuumcleanup 11 10 12 1 0 0 0 f f f f t f v 2 0 2281 "2281 2281" _null_ _null_ _null_ _null_ ginvacuumcleanup _null_ _null_ _null_ ) +insert OID = 2741 ( gincostestimate 11 10 12 1 0 0 0 f f f f t f v 7 0 2278 "2281 2281 2281 2281 2281 2281 2281" _null_ _null_ _null_ _null_ gincostestimate _null_ _null_ _null_ ) +insert OID = 2788 ( ginoptions 11 10 12 1 0 0 0 f f f f t f s 2 0 17 "1009 16" _null_ _null_ _null_ _null_ ginoptions _null_ _null_ _null_ ) +insert OID = 2743 ( ginarrayextract 11 10 12 1 0 0 0 f f f f t f i 3 0 2281 "2277 2281 2281" _null_ _null_ _null_ _null_ ginarrayextract _null_ _null_ _null_ ) +insert OID = 2774 ( ginqueryarrayextract 11 10 12 1 0 0 0 f f f f t f i 7 0 2281 "2277 2281 21 2281 2281 2281 2281" _null_ _null_ _null_ _null_ ginqueryarrayextract _null_ _null_ _null_ ) +insert OID = 2744 ( ginarrayconsistent 11 10 12 1 0 0 0 f f f f t f i 8 0 16 "2281 21 2277 23 2281 2281 2281 2281" _null_ _null_ _null_ _null_ ginarrayconsistent _null_ _null_ _null_ ) +insert OID = 3076 ( ginarrayextract 11 10 12 1 0 0 0 f f f f t f i 2 0 2281 "2277 2281" _null_ _null_ _null_ _null_ ginarrayextract_2args _null_ _null_ _null_ ) +insert OID = 2747 ( arrayoverlap 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "2277 2277" _null_ _null_ _null_ _null_ arrayoverlap _null_ _null_ _null_ ) +insert OID = 2748 ( arraycontains 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "2277 2277" _null_ _null_ _null_ _null_ arraycontains _null_ _null_ _null_ ) +insert OID = 2749 ( arraycontained 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "2277 2277" _null_ _null_ _null_ _null_ arraycontained _null_ _null_ _null_ ) +insert OID = 2880 ( pg_advisory_lock 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "20" _null_ _null_ _null_ _null_ pg_advisory_lock_int8 _null_ _null_ _null_ ) +insert OID = 3089 ( pg_advisory_xact_lock 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "20" _null_ _null_ _null_ _null_ pg_advisory_xact_lock_int8 _null_ _null_ _null_ ) +insert OID = 2881 ( pg_advisory_lock_shared 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "20" _null_ _null_ _null_ _null_ pg_advisory_lock_shared_int8 _null_ _null_ _null_ ) +insert OID = 3090 ( pg_advisory_xact_lock_shared 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "20" _null_ _null_ _null_ _null_ pg_advisory_xact_lock_shared_int8 _null_ _null_ _null_ ) +insert OID = 2882 ( pg_try_advisory_lock 11 10 12 1 0 0 0 f f f f t f v 1 0 16 "20" _null_ _null_ _null_ _null_ pg_try_advisory_lock_int8 _null_ _null_ _null_ ) +insert OID = 3091 ( pg_try_advisory_xact_lock 11 10 12 1 0 0 0 f f f f t f v 1 0 16 "20" _null_ _null_ _null_ _null_ pg_try_advisory_xact_lock_int8 _null_ _null_ _null_ ) +insert OID = 2883 ( pg_try_advisory_lock_shared 11 10 12 1 0 0 0 f f f f t f v 1 0 16 "20" _null_ _null_ _null_ _null_ pg_try_advisory_lock_shared_int8 _null_ _null_ _null_ ) +insert OID = 3092 ( pg_try_advisory_xact_lock_shared 11 10 12 1 0 0 0 f f f f t f v 1 0 16 "20" _null_ _null_ _null_ _null_ pg_try_advisory_xact_lock_shared_int8 _null_ _null_ _null_ ) +insert OID = 2884 ( pg_advisory_unlock 11 10 12 1 0 0 0 f f f f t f v 1 0 16 "20" _null_ _null_ _null_ _null_ pg_advisory_unlock_int8 _null_ _null_ _null_ ) +insert OID = 2885 ( pg_advisory_unlock_shared 11 10 12 1 0 0 0 f f f f t f v 1 0 16 "20" _null_ _null_ _null_ _null_ pg_advisory_unlock_shared_int8 _null_ _null_ _null_ ) +insert OID = 2886 ( pg_advisory_lock 11 10 12 1 0 0 0 f f f f t f v 2 0 2278 "23 23" _null_ _null_ _null_ _null_ pg_advisory_lock_int4 _null_ _null_ _null_ ) +insert OID = 3093 ( pg_advisory_xact_lock 11 10 12 1 0 0 0 f f f f t f v 2 0 2278 "23 23" _null_ _null_ _null_ _null_ pg_advisory_xact_lock_int4 _null_ _null_ _null_ ) +insert OID = 2887 ( pg_advisory_lock_shared 11 10 12 1 0 0 0 f f f f t f v 2 0 2278 "23 23" _null_ _null_ _null_ _null_ pg_advisory_lock_shared_int4 _null_ _null_ _null_ ) +insert OID = 3094 ( pg_advisory_xact_lock_shared 11 10 12 1 0 0 0 f f f f t f v 2 0 2278 "23 23" _null_ _null_ _null_ _null_ pg_advisory_xact_lock_shared_int4 _null_ _null_ _null_ ) +insert OID = 2888 ( pg_try_advisory_lock 11 10 12 1 0 0 0 f f f f t f v 2 0 16 "23 23" _null_ _null_ _null_ _null_ pg_try_advisory_lock_int4 _null_ _null_ _null_ ) +insert OID = 3095 ( pg_try_advisory_xact_lock 11 10 12 1 0 0 0 f f f f t f v 2 0 16 "23 23" _null_ _null_ _null_ _null_ pg_try_advisory_xact_lock_int4 _null_ _null_ _null_ ) +insert OID = 2889 ( pg_try_advisory_lock_shared 11 10 12 1 0 0 0 f f f f t f v 2 0 16 "23 23" _null_ _null_ _null_ _null_ pg_try_advisory_lock_shared_int4 _null_ _null_ _null_ ) +insert OID = 3096 ( pg_try_advisory_xact_lock_shared 11 10 12 1 0 0 0 f f f f t f v 2 0 16 "23 23" _null_ _null_ _null_ _null_ pg_try_advisory_xact_lock_shared_int4 _null_ _null_ _null_ ) +insert OID = 2890 ( pg_advisory_unlock 11 10 12 1 0 0 0 f f f f t f v 2 0 16 "23 23" _null_ _null_ _null_ _null_ pg_advisory_unlock_int4 _null_ _null_ _null_ ) +insert OID = 2891 ( pg_advisory_unlock_shared 11 10 12 1 0 0 0 f f f f t f v 2 0 16 "23 23" _null_ _null_ _null_ _null_ pg_advisory_unlock_shared_int4 _null_ _null_ _null_ ) +insert OID = 2892 ( pg_advisory_unlock_all 11 10 12 1 0 0 0 f f f f t f v 0 0 2278 "" _null_ _null_ _null_ _null_ pg_advisory_unlock_all _null_ _null_ _null_ ) +insert OID = 2893 ( xml_in 11 10 12 1 0 0 0 f f f f t f s 1 0 142 "2275" _null_ _null_ _null_ _null_ xml_in _null_ _null_ _null_ ) +insert OID = 2894 ( xml_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "142" _null_ _null_ _null_ _null_ xml_out _null_ _null_ _null_ ) +insert OID = 2895 ( xmlcomment 11 10 12 1 0 0 0 f f f f t f i 1 0 142 "25" _null_ _null_ _null_ _null_ xmlcomment _null_ _null_ _null_ ) +insert OID = 2896 ( xml 11 10 12 1 0 0 0 f f f f t f s 1 0 142 "25" _null_ _null_ _null_ _null_ texttoxml _null_ _null_ _null_ ) +insert OID = 2897 ( xmlvalidate 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "142 25" _null_ _null_ _null_ _null_ xmlvalidate _null_ _null_ _null_ ) +insert OID = 2898 ( xml_recv 11 10 12 1 0 0 0 f f f f t f s 1 0 142 "2281" _null_ _null_ _null_ _null_ xml_recv _null_ _null_ _null_ ) +insert OID = 2899 ( xml_send 11 10 12 1 0 0 0 f f f f t f s 1 0 17 "142" _null_ _null_ _null_ _null_ xml_send _null_ _null_ _null_ ) +insert OID = 2900 ( xmlconcat2 11 10 12 1 0 0 0 f f f f f f i 2 0 142 "142 142" _null_ _null_ _null_ _null_ xmlconcat2 _null_ _null_ _null_ ) +insert OID = 2901 ( xmlagg 11 10 12 1 0 0 0 t f f f f f i 1 0 142 "142" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 2922 ( text 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "142" _null_ _null_ _null_ _null_ xmltotext _null_ _null_ _null_ ) +insert OID = 2923 ( table_to_xml 11 10 12 100 0 0 0 f f f f t f s 4 0 142 "2205 16 16 25" _null_ _null_ "{tbl,nulls,tableforest,targetns}" _null_ table_to_xml _null_ _null_ _null_ ) +insert OID = 2924 ( query_to_xml 11 10 12 100 0 0 0 f f f f t f s 4 0 142 "25 16 16 25" _null_ _null_ "{query,nulls,tableforest,targetns}" _null_ query_to_xml _null_ _null_ _null_ ) +insert OID = 2925 ( cursor_to_xml 11 10 12 100 0 0 0 f f f f t f s 5 0 142 "1790 23 16 16 25" _null_ _null_ "{cursor,count,nulls,tableforest,targetns}" _null_ cursor_to_xml _null_ _null_ _null_ ) +insert OID = 2926 ( table_to_xmlschema 11 10 12 100 0 0 0 f f f f t f s 4 0 142 "2205 16 16 25" _null_ _null_ "{tbl,nulls,tableforest,targetns}" _null_ table_to_xmlschema _null_ _null_ _null_ ) +insert OID = 2927 ( query_to_xmlschema 11 10 12 100 0 0 0 f f f f t f s 4 0 142 "25 16 16 25" _null_ _null_ "{query,nulls,tableforest,targetns}" _null_ query_to_xmlschema _null_ _null_ _null_ ) +insert OID = 2928 ( cursor_to_xmlschema 11 10 12 100 0 0 0 f f f f t f s 4 0 142 "1790 16 16 25" _null_ _null_ "{cursor,nulls,tableforest,targetns}" _null_ cursor_to_xmlschema _null_ _null_ _null_ ) +insert OID = 2929 ( table_to_xml_and_xmlschema 11 10 12 100 0 0 0 f f f f t f s 4 0 142 "2205 16 16 25" _null_ _null_ "{tbl,nulls,tableforest,targetns}" _null_ table_to_xml_and_xmlschema _null_ _null_ _null_ ) +insert OID = 2930 ( query_to_xml_and_xmlschema 11 10 12 100 0 0 0 f f f f t f s 4 0 142 "25 16 16 25" _null_ _null_ "{query,nulls,tableforest,targetns}" _null_ query_to_xml_and_xmlschema _null_ _null_ _null_ ) +insert OID = 2933 ( schema_to_xml 11 10 12 100 0 0 0 f f f f t f s 4 0 142 "19 16 16 25" _null_ _null_ "{schema,nulls,tableforest,targetns}" _null_ schema_to_xml _null_ _null_ _null_ ) +insert OID = 2934 ( schema_to_xmlschema 11 10 12 100 0 0 0 f f f f t f s 4 0 142 "19 16 16 25" _null_ _null_ "{schema,nulls,tableforest,targetns}" _null_ schema_to_xmlschema _null_ _null_ _null_ ) +insert OID = 2935 ( schema_to_xml_and_xmlschema 11 10 12 100 0 0 0 f f f f t f s 4 0 142 "19 16 16 25" _null_ _null_ "{schema,nulls,tableforest,targetns}" _null_ schema_to_xml_and_xmlschema _null_ _null_ _null_ ) +insert OID = 2936 ( database_to_xml 11 10 12 100 0 0 0 f f f f t f s 3 0 142 "16 16 25" _null_ _null_ "{nulls,tableforest,targetns}" _null_ database_to_xml _null_ _null_ _null_ ) +insert OID = 2937 ( database_to_xmlschema 11 10 12 100 0 0 0 f f f f t f s 3 0 142 "16 16 25" _null_ _null_ "{nulls,tableforest,targetns}" _null_ database_to_xmlschema _null_ _null_ _null_ ) +insert OID = 2938 ( database_to_xml_and_xmlschema 11 10 12 100 0 0 0 f f f f t f s 3 0 142 "16 16 25" _null_ _null_ "{nulls,tableforest,targetns}" _null_ database_to_xml_and_xmlschema _null_ _null_ _null_ ) +insert OID = 2931 ( xpath 11 10 12 1 0 0 0 f f f f t f i 3 0 143 "25 142 1009" _null_ _null_ _null_ _null_ xpath _null_ _null_ _null_ ) +insert OID = 2932 ( xpath 11 10 14 1 0 0 0 f f f f t f i 2 0 143 "25 142" _null_ _null_ _null_ _null_ "select pg_catalog.xpath($1, $2, ''{}''::pg_catalog.text[])" _null_ _null_ _null_ ) +insert OID = 2614 ( xmlexists 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "25 142" _null_ _null_ _null_ _null_ xmlexists _null_ _null_ _null_ ) +insert OID = 3049 ( xpath_exists 11 10 12 1 0 0 0 f f f f t f i 3 0 16 "25 142 1009" _null_ _null_ _null_ _null_ xpath_exists _null_ _null_ _null_ ) +insert OID = 3050 ( xpath_exists 11 10 14 1 0 0 0 f f f f t f i 2 0 16 "25 142" _null_ _null_ _null_ _null_ "select pg_catalog.xpath_exists($1, $2, ''{}''::pg_catalog.text[])" _null_ _null_ _null_ ) +insert OID = 3051 ( xml_is_well_formed 11 10 12 1 0 0 0 f f f f t f s 1 0 16 "25" _null_ _null_ _null_ _null_ xml_is_well_formed _null_ _null_ _null_ ) +insert OID = 3052 ( xml_is_well_formed_document 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "25" _null_ _null_ _null_ _null_ xml_is_well_formed_document _null_ _null_ _null_ ) +insert OID = 3053 ( xml_is_well_formed_content 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "25" _null_ _null_ _null_ _null_ xml_is_well_formed_content _null_ _null_ _null_ ) +insert OID = 321 ( json_in 11 10 12 1 0 0 0 f f f f t f s 1 0 114 "2275" _null_ _null_ _null_ _null_ json_in _null_ _null_ _null_ ) +insert OID = 322 ( json_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "114" _null_ _null_ _null_ _null_ json_out _null_ _null_ _null_ ) +insert OID = 323 ( json_recv 11 10 12 1 0 0 0 f f f f t f s 1 0 114 "2281" _null_ _null_ _null_ _null_ json_recv _null_ _null_ _null_ ) +insert OID = 324 ( json_send 11 10 12 1 0 0 0 f f f f t f s 1 0 17 "114" _null_ _null_ _null_ _null_ json_send _null_ _null_ _null_ ) +insert OID = 3153 ( array_to_json 11 10 12 1 0 0 0 f f f f t f s 1 0 114 "2277" _null_ _null_ _null_ _null_ array_to_json _null_ _null_ _null_ ) +insert OID = 3154 ( array_to_json 11 10 12 1 0 0 0 f f f f t f s 2 0 114 "2277 16" _null_ _null_ _null_ _null_ array_to_json_pretty _null_ _null_ _null_ ) +insert OID = 3155 ( row_to_json 11 10 12 1 0 0 0 f f f f t f s 1 0 114 "2249" _null_ _null_ _null_ _null_ row_to_json _null_ _null_ _null_ ) +insert OID = 3156 ( row_to_json 11 10 12 1 0 0 0 f f f f t f s 2 0 114 "2249 16" _null_ _null_ _null_ _null_ row_to_json_pretty _null_ _null_ _null_ ) +insert OID = 2952 ( uuid_in 11 10 12 1 0 0 0 f f f f t f i 1 0 2950 "2275" _null_ _null_ _null_ _null_ uuid_in _null_ _null_ _null_ ) +insert OID = 2953 ( uuid_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "2950" _null_ _null_ _null_ _null_ uuid_out _null_ _null_ _null_ ) +insert OID = 2954 ( uuid_lt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "2950 2950" _null_ _null_ _null_ _null_ uuid_lt _null_ _null_ _null_ ) +insert OID = 2955 ( uuid_le 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "2950 2950" _null_ _null_ _null_ _null_ uuid_le _null_ _null_ _null_ ) +insert OID = 2956 ( uuid_eq 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "2950 2950" _null_ _null_ _null_ _null_ uuid_eq _null_ _null_ _null_ ) +insert OID = 2957 ( uuid_ge 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "2950 2950" _null_ _null_ _null_ _null_ uuid_ge _null_ _null_ _null_ ) +insert OID = 2958 ( uuid_gt 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "2950 2950" _null_ _null_ _null_ _null_ uuid_gt _null_ _null_ _null_ ) +insert OID = 2959 ( uuid_ne 11 10 12 1 0 0 0 f f f t t f i 2 0 16 "2950 2950" _null_ _null_ _null_ _null_ uuid_ne _null_ _null_ _null_ ) +insert OID = 2960 ( uuid_cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "2950 2950" _null_ _null_ _null_ _null_ uuid_cmp _null_ _null_ _null_ ) +insert OID = 2961 ( uuid_recv 11 10 12 1 0 0 0 f f f f t f i 1 0 2950 "2281" _null_ _null_ _null_ _null_ uuid_recv _null_ _null_ _null_ ) +insert OID = 2962 ( uuid_send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "2950" _null_ _null_ _null_ _null_ uuid_send _null_ _null_ _null_ ) +insert OID = 2963 ( uuid_hash 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "2950" _null_ _null_ _null_ _null_ uuid_hash _null_ _null_ _null_ ) +insert OID = 3504 ( anyenum_in 11 10 12 1 0 0 0 f f f f t f i 1 0 3500 "2275" _null_ _null_ _null_ _null_ anyenum_in _null_ _null_ _null_ ) +insert OID = 3505 ( anyenum_out 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "3500" _null_ _null_ _null_ _null_ anyenum_out _null_ _null_ _null_ ) +insert OID = 3506 ( enum_in 11 10 12 1 0 0 0 f f f f t f s 2 0 3500 "2275 26" _null_ _null_ _null_ _null_ enum_in _null_ _null_ _null_ ) +insert OID = 3507 ( enum_out 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "3500" _null_ _null_ _null_ _null_ enum_out _null_ _null_ _null_ ) +insert OID = 3508 ( enum_eq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3500 3500" _null_ _null_ _null_ _null_ enum_eq _null_ _null_ _null_ ) +insert OID = 3509 ( enum_ne 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3500 3500" _null_ _null_ _null_ _null_ enum_ne _null_ _null_ _null_ ) +insert OID = 3510 ( enum_lt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3500 3500" _null_ _null_ _null_ _null_ enum_lt _null_ _null_ _null_ ) +insert OID = 3511 ( enum_gt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3500 3500" _null_ _null_ _null_ _null_ enum_gt _null_ _null_ _null_ ) +insert OID = 3512 ( enum_le 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3500 3500" _null_ _null_ _null_ _null_ enum_le _null_ _null_ _null_ ) +insert OID = 3513 ( enum_ge 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3500 3500" _null_ _null_ _null_ _null_ enum_ge _null_ _null_ _null_ ) +insert OID = 3514 ( enum_cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "3500 3500" _null_ _null_ _null_ _null_ enum_cmp _null_ _null_ _null_ ) +insert OID = 3515 ( hashenum 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "3500" _null_ _null_ _null_ _null_ hashenum _null_ _null_ _null_ ) +insert OID = 3524 ( enum_smaller 11 10 12 1 0 0 0 f f f f t f i 2 0 3500 "3500 3500" _null_ _null_ _null_ _null_ enum_smaller _null_ _null_ _null_ ) +insert OID = 3525 ( enum_larger 11 10 12 1 0 0 0 f f f f t f i 2 0 3500 "3500 3500" _null_ _null_ _null_ _null_ enum_larger _null_ _null_ _null_ ) +insert OID = 3526 ( max 11 10 12 1 0 0 0 t f f f f f i 1 0 3500 "3500" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 3527 ( min 11 10 12 1 0 0 0 t f f f f f i 1 0 3500 "3500" _null_ _null_ _null_ _null_ aggregate_dummy _null_ _null_ _null_ ) +insert OID = 3528 ( enum_first 11 10 12 1 0 0 0 f f f f f f s 1 0 3500 "3500" _null_ _null_ _null_ _null_ enum_first _null_ _null_ _null_ ) +insert OID = 3529 ( enum_last 11 10 12 1 0 0 0 f f f f f f s 1 0 3500 "3500" _null_ _null_ _null_ _null_ enum_last _null_ _null_ _null_ ) +insert OID = 3530 ( enum_range 11 10 12 1 0 0 0 f f f f f f s 2 0 2277 "3500 3500" _null_ _null_ _null_ _null_ enum_range_bounds _null_ _null_ _null_ ) +insert OID = 3531 ( enum_range 11 10 12 1 0 0 0 f f f f f f s 1 0 2277 "3500" _null_ _null_ _null_ _null_ enum_range_all _null_ _null_ _null_ ) +insert OID = 3532 ( enum_recv 11 10 12 1 0 0 0 f f f f t f s 2 0 3500 "2275 26" _null_ _null_ _null_ _null_ enum_recv _null_ _null_ _null_ ) +insert OID = 3533 ( enum_send 11 10 12 1 0 0 0 f f f f t f s 1 0 17 "3500" _null_ _null_ _null_ _null_ enum_send _null_ _null_ _null_ ) +insert OID = 3610 ( tsvectorin 11 10 12 1 0 0 0 f f f f t f i 1 0 3614 "2275" _null_ _null_ _null_ _null_ tsvectorin _null_ _null_ _null_ ) +insert OID = 3639 ( tsvectorrecv 11 10 12 1 0 0 0 f f f f t f i 1 0 3614 "2281" _null_ _null_ _null_ _null_ tsvectorrecv _null_ _null_ _null_ ) +insert OID = 3611 ( tsvectorout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "3614" _null_ _null_ _null_ _null_ tsvectorout _null_ _null_ _null_ ) +insert OID = 3638 ( tsvectorsend 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "3614" _null_ _null_ _null_ _null_ tsvectorsend _null_ _null_ _null_ ) +insert OID = 3612 ( tsqueryin 11 10 12 1 0 0 0 f f f f t f i 1 0 3615 "2275" _null_ _null_ _null_ _null_ tsqueryin _null_ _null_ _null_ ) +insert OID = 3641 ( tsqueryrecv 11 10 12 1 0 0 0 f f f f t f i 1 0 3615 "2281" _null_ _null_ _null_ _null_ tsqueryrecv _null_ _null_ _null_ ) +insert OID = 3613 ( tsqueryout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "3615" _null_ _null_ _null_ _null_ tsqueryout _null_ _null_ _null_ ) +insert OID = 3640 ( tsquerysend 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "3615" _null_ _null_ _null_ _null_ tsquerysend _null_ _null_ _null_ ) +insert OID = 3646 ( gtsvectorin 11 10 12 1 0 0 0 f f f f t f i 1 0 3642 "2275" _null_ _null_ _null_ _null_ gtsvectorin _null_ _null_ _null_ ) +insert OID = 3647 ( gtsvectorout 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "3642" _null_ _null_ _null_ _null_ gtsvectorout _null_ _null_ _null_ ) +insert OID = 3616 ( tsvector_lt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3614 3614" _null_ _null_ _null_ _null_ tsvector_lt _null_ _null_ _null_ ) +insert OID = 3617 ( tsvector_le 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3614 3614" _null_ _null_ _null_ _null_ tsvector_le _null_ _null_ _null_ ) +insert OID = 3618 ( tsvector_eq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3614 3614" _null_ _null_ _null_ _null_ tsvector_eq _null_ _null_ _null_ ) +insert OID = 3619 ( tsvector_ne 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3614 3614" _null_ _null_ _null_ _null_ tsvector_ne _null_ _null_ _null_ ) +insert OID = 3620 ( tsvector_ge 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3614 3614" _null_ _null_ _null_ _null_ tsvector_ge _null_ _null_ _null_ ) +insert OID = 3621 ( tsvector_gt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3614 3614" _null_ _null_ _null_ _null_ tsvector_gt _null_ _null_ _null_ ) +insert OID = 3622 ( tsvector_cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "3614 3614" _null_ _null_ _null_ _null_ tsvector_cmp _null_ _null_ _null_ ) +insert OID = 3711 ( length 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "3614" _null_ _null_ _null_ _null_ tsvector_length _null_ _null_ _null_ ) +insert OID = 3623 ( strip 11 10 12 1 0 0 0 f f f f t f i 1 0 3614 "3614" _null_ _null_ _null_ _null_ tsvector_strip _null_ _null_ _null_ ) +insert OID = 3624 ( setweight 11 10 12 1 0 0 0 f f f f t f i 2 0 3614 "3614 18" _null_ _null_ _null_ _null_ tsvector_setweight _null_ _null_ _null_ ) +insert OID = 3625 ( tsvector_concat 11 10 12 1 0 0 0 f f f f t f i 2 0 3614 "3614 3614" _null_ _null_ _null_ _null_ tsvector_concat _null_ _null_ _null_ ) +insert OID = 3634 ( ts_match_vq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3614 3615" _null_ _null_ _null_ _null_ ts_match_vq _null_ _null_ _null_ ) +insert OID = 3635 ( ts_match_qv 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3615 3614" _null_ _null_ _null_ _null_ ts_match_qv _null_ _null_ _null_ ) +insert OID = 3760 ( ts_match_tt 11 10 12 3 0 0 0 f f f f t f s 2 0 16 "25 25" _null_ _null_ _null_ _null_ ts_match_tt _null_ _null_ _null_ ) +insert OID = 3761 ( ts_match_tq 11 10 12 2 0 0 0 f f f f t f s 2 0 16 "25 3615" _null_ _null_ _null_ _null_ ts_match_tq _null_ _null_ _null_ ) +insert OID = 3648 ( gtsvector_compress 11 10 12 1 0 0 0 f f f f t f i 1 0 2281 "2281" _null_ _null_ _null_ _null_ gtsvector_compress _null_ _null_ _null_ ) +insert OID = 3649 ( gtsvector_decompress 11 10 12 1 0 0 0 f f f f t f i 1 0 2281 "2281" _null_ _null_ _null_ _null_ gtsvector_decompress _null_ _null_ _null_ ) +insert OID = 3650 ( gtsvector_picksplit 11 10 12 1 0 0 0 f f f f t f i 2 0 2281 "2281 2281" _null_ _null_ _null_ _null_ gtsvector_picksplit _null_ _null_ _null_ ) +insert OID = 3651 ( gtsvector_union 11 10 12 1 0 0 0 f f f f t f i 2 0 2281 "2281 2281" _null_ _null_ _null_ _null_ gtsvector_union _null_ _null_ _null_ ) +insert OID = 3652 ( gtsvector_same 11 10 12 1 0 0 0 f f f f t f i 3 0 2281 "3642 3642 2281" _null_ _null_ _null_ _null_ gtsvector_same _null_ _null_ _null_ ) +insert OID = 3653 ( gtsvector_penalty 11 10 12 1 0 0 0 f f f f t f i 3 0 2281 "2281 2281 2281" _null_ _null_ _null_ _null_ gtsvector_penalty _null_ _null_ _null_ ) +insert OID = 3654 ( gtsvector_consistent 11 10 12 1 0 0 0 f f f f t f i 5 0 16 "2281 3642 23 26 2281" _null_ _null_ _null_ _null_ gtsvector_consistent _null_ _null_ _null_ ) +insert OID = 3656 ( gin_extract_tsvector 11 10 12 1 0 0 0 f f f f t f i 3 0 2281 "3614 2281 2281" _null_ _null_ _null_ _null_ gin_extract_tsvector _null_ _null_ _null_ ) +insert OID = 3657 ( gin_extract_tsquery 11 10 12 1 0 0 0 f f f f t f i 7 0 2281 "3615 2281 21 2281 2281 2281 2281" _null_ _null_ _null_ _null_ gin_extract_tsquery _null_ _null_ _null_ ) +insert OID = 3658 ( gin_tsquery_consistent 11 10 12 1 0 0 0 f f f f t f i 8 0 16 "2281 21 3615 23 2281 2281 2281 2281" _null_ _null_ _null_ _null_ gin_tsquery_consistent _null_ _null_ _null_ ) +insert OID = 3724 ( gin_cmp_tslexeme 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "25 25" _null_ _null_ _null_ _null_ gin_cmp_tslexeme _null_ _null_ _null_ ) +insert OID = 2700 ( gin_cmp_prefix 11 10 12 1 0 0 0 f f f f t f i 4 0 23 "25 25 21 2281" _null_ _null_ _null_ _null_ gin_cmp_prefix _null_ _null_ _null_ ) +insert OID = 3077 ( gin_extract_tsvector 11 10 12 1 0 0 0 f f f f t f i 2 0 2281 "3614 2281" _null_ _null_ _null_ _null_ gin_extract_tsvector_2args _null_ _null_ _null_ ) +insert OID = 3087 ( gin_extract_tsquery 11 10 12 1 0 0 0 f f f f t f i 5 0 2281 "3615 2281 21 2281 2281" _null_ _null_ _null_ _null_ gin_extract_tsquery_5args _null_ _null_ _null_ ) +insert OID = 3088 ( gin_tsquery_consistent 11 10 12 1 0 0 0 f f f f t f i 6 0 16 "2281 21 3615 23 2281 2281" _null_ _null_ _null_ _null_ gin_tsquery_consistent_6args _null_ _null_ _null_ ) +insert OID = 3662 ( tsquery_lt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3615 3615" _null_ _null_ _null_ _null_ tsquery_lt _null_ _null_ _null_ ) +insert OID = 3663 ( tsquery_le 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3615 3615" _null_ _null_ _null_ _null_ tsquery_le _null_ _null_ _null_ ) +insert OID = 3664 ( tsquery_eq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3615 3615" _null_ _null_ _null_ _null_ tsquery_eq _null_ _null_ _null_ ) +insert OID = 3665 ( tsquery_ne 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3615 3615" _null_ _null_ _null_ _null_ tsquery_ne _null_ _null_ _null_ ) +insert OID = 3666 ( tsquery_ge 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3615 3615" _null_ _null_ _null_ _null_ tsquery_ge _null_ _null_ _null_ ) +insert OID = 3667 ( tsquery_gt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3615 3615" _null_ _null_ _null_ _null_ tsquery_gt _null_ _null_ _null_ ) +insert OID = 3668 ( tsquery_cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "3615 3615" _null_ _null_ _null_ _null_ tsquery_cmp _null_ _null_ _null_ ) +insert OID = 3669 ( tsquery_and 11 10 12 1 0 0 0 f f f f t f i 2 0 3615 "3615 3615" _null_ _null_ _null_ _null_ tsquery_and _null_ _null_ _null_ ) +insert OID = 3670 ( tsquery_or 11 10 12 1 0 0 0 f f f f t f i 2 0 3615 "3615 3615" _null_ _null_ _null_ _null_ tsquery_or _null_ _null_ _null_ ) +insert OID = 3671 ( tsquery_not 11 10 12 1 0 0 0 f f f f t f i 1 0 3615 "3615" _null_ _null_ _null_ _null_ tsquery_not _null_ _null_ _null_ ) +insert OID = 3691 ( tsq_mcontains 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3615 3615" _null_ _null_ _null_ _null_ tsq_mcontains _null_ _null_ _null_ ) +insert OID = 3692 ( tsq_mcontained 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3615 3615" _null_ _null_ _null_ _null_ tsq_mcontained _null_ _null_ _null_ ) +insert OID = 3672 ( numnode 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "3615" _null_ _null_ _null_ _null_ tsquery_numnode _null_ _null_ _null_ ) +insert OID = 3673 ( querytree 11 10 12 1 0 0 0 f f f f t f i 1 0 25 "3615" _null_ _null_ _null_ _null_ tsquerytree _null_ _null_ _null_ ) +insert OID = 3684 ( ts_rewrite 11 10 12 1 0 0 0 f f f f t f i 3 0 3615 "3615 3615 3615" _null_ _null_ _null_ _null_ tsquery_rewrite _null_ _null_ _null_ ) +insert OID = 3685 ( ts_rewrite 11 10 12 1 0 0 0 f f f f t f v 2 0 3615 "3615 25" _null_ _null_ _null_ _null_ tsquery_rewrite_query _null_ _null_ _null_ ) +insert OID = 3695 ( gtsquery_compress 11 10 12 1 0 0 0 f f f f t f i 1 0 2281 "2281" _null_ _null_ _null_ _null_ gtsquery_compress _null_ _null_ _null_ ) +insert OID = 3696 ( gtsquery_decompress 11 10 12 1 0 0 0 f f f f t f i 1 0 2281 "2281" _null_ _null_ _null_ _null_ gtsquery_decompress _null_ _null_ _null_ ) +insert OID = 3697 ( gtsquery_picksplit 11 10 12 1 0 0 0 f f f f t f i 2 0 2281 "2281 2281" _null_ _null_ _null_ _null_ gtsquery_picksplit _null_ _null_ _null_ ) +insert OID = 3698 ( gtsquery_union 11 10 12 1 0 0 0 f f f f t f i 2 0 2281 "2281 2281" _null_ _null_ _null_ _null_ gtsquery_union _null_ _null_ _null_ ) +insert OID = 3699 ( gtsquery_same 11 10 12 1 0 0 0 f f f f t f i 3 0 2281 "20 20 2281" _null_ _null_ _null_ _null_ gtsquery_same _null_ _null_ _null_ ) +insert OID = 3700 ( gtsquery_penalty 11 10 12 1 0 0 0 f f f f t f i 3 0 2281 "2281 2281 2281" _null_ _null_ _null_ _null_ gtsquery_penalty _null_ _null_ _null_ ) +insert OID = 3701 ( gtsquery_consistent 11 10 12 1 0 0 0 f f f f t f i 5 0 16 "2281 2281 23 26 2281" _null_ _null_ _null_ _null_ gtsquery_consistent _null_ _null_ _null_ ) +insert OID = 3686 ( tsmatchsel 11 10 12 1 0 0 0 f f f f t f s 4 0 701 "2281 26 2281 23" _null_ _null_ _null_ _null_ tsmatchsel _null_ _null_ _null_ ) +insert OID = 3687 ( tsmatchjoinsel 11 10 12 1 0 0 0 f f f f t f s 5 0 701 "2281 26 2281 21 2281" _null_ _null_ _null_ _null_ tsmatchjoinsel _null_ _null_ _null_ ) +insert OID = 3688 ( ts_typanalyze 11 10 12 1 0 0 0 f f f f t f s 1 0 16 "2281" _null_ _null_ _null_ _null_ ts_typanalyze _null_ _null_ _null_ ) +insert OID = 3689 ( ts_stat 11 10 12 10 10000 0 0 f f f f t t v 1 0 2249 "25" "{25,25,23,23}" "{i,o,o,o}" "{query,word,ndoc,nentry}" _null_ ts_stat1 _null_ _null_ _null_ ) +insert OID = 3690 ( ts_stat 11 10 12 10 10000 0 0 f f f f t t v 2 0 2249 "25 25" "{25,25,25,23,23}" "{i,i,o,o,o}" "{query,weights,word,ndoc,nentry}" _null_ ts_stat2 _null_ _null_ _null_ ) +insert OID = 3703 ( ts_rank 11 10 12 1 0 0 0 f f f f t f i 4 0 700 "1021 3614 3615 23" _null_ _null_ _null_ _null_ ts_rank_wttf _null_ _null_ _null_ ) +insert OID = 3704 ( ts_rank 11 10 12 1 0 0 0 f f f f t f i 3 0 700 "1021 3614 3615" _null_ _null_ _null_ _null_ ts_rank_wtt _null_ _null_ _null_ ) +insert OID = 3705 ( ts_rank 11 10 12 1 0 0 0 f f f f t f i 3 0 700 "3614 3615 23" _null_ _null_ _null_ _null_ ts_rank_ttf _null_ _null_ _null_ ) +insert OID = 3706 ( ts_rank 11 10 12 1 0 0 0 f f f f t f i 2 0 700 "3614 3615" _null_ _null_ _null_ _null_ ts_rank_tt _null_ _null_ _null_ ) +insert OID = 3707 ( ts_rank_cd 11 10 12 1 0 0 0 f f f f t f i 4 0 700 "1021 3614 3615 23" _null_ _null_ _null_ _null_ ts_rankcd_wttf _null_ _null_ _null_ ) +insert OID = 3708 ( ts_rank_cd 11 10 12 1 0 0 0 f f f f t f i 3 0 700 "1021 3614 3615" _null_ _null_ _null_ _null_ ts_rankcd_wtt _null_ _null_ _null_ ) +insert OID = 3709 ( ts_rank_cd 11 10 12 1 0 0 0 f f f f t f i 3 0 700 "3614 3615 23" _null_ _null_ _null_ _null_ ts_rankcd_ttf _null_ _null_ _null_ ) +insert OID = 3710 ( ts_rank_cd 11 10 12 1 0 0 0 f f f f t f i 2 0 700 "3614 3615" _null_ _null_ _null_ _null_ ts_rankcd_tt _null_ _null_ _null_ ) +insert OID = 3713 ( ts_token_type 11 10 12 1 16 0 0 f f f f t t i 1 0 2249 "26" "{26,23,25,25}" "{i,o,o,o}" "{parser_oid,tokid,alias,description}" _null_ ts_token_type_byid _null_ _null_ _null_ ) +insert OID = 3714 ( ts_token_type 11 10 12 1 16 0 0 f f f f t t s 1 0 2249 "25" "{25,23,25,25}" "{i,o,o,o}" "{parser_name,tokid,alias,description}" _null_ ts_token_type_byname _null_ _null_ _null_ ) +insert OID = 3715 ( ts_parse 11 10 12 1 1000 0 0 f f f f t t i 2 0 2249 "26 25" "{26,25,23,25}" "{i,i,o,o}" "{parser_oid,txt,tokid,token}" _null_ ts_parse_byid _null_ _null_ _null_ ) +insert OID = 3716 ( ts_parse 11 10 12 1 1000 0 0 f f f f t t s 2 0 2249 "25 25" "{25,25,23,25}" "{i,i,o,o}" "{parser_name,txt,tokid,token}" _null_ ts_parse_byname _null_ _null_ _null_ ) +insert OID = 3717 ( prsd_start 11 10 12 1 0 0 0 f f f f t f i 2 0 2281 "2281 23" _null_ _null_ _null_ _null_ prsd_start _null_ _null_ _null_ ) +insert OID = 3718 ( prsd_nexttoken 11 10 12 1 0 0 0 f f f f t f i 3 0 2281 "2281 2281 2281" _null_ _null_ _null_ _null_ prsd_nexttoken _null_ _null_ _null_ ) +insert OID = 3719 ( prsd_end 11 10 12 1 0 0 0 f f f f t f i 1 0 2278 "2281" _null_ _null_ _null_ _null_ prsd_end _null_ _null_ _null_ ) +insert OID = 3720 ( prsd_headline 11 10 12 1 0 0 0 f f f f t f i 3 0 2281 "2281 2281 3615" _null_ _null_ _null_ _null_ prsd_headline _null_ _null_ _null_ ) +insert OID = 3721 ( prsd_lextype 11 10 12 1 0 0 0 f f f f t f i 1 0 2281 "2281" _null_ _null_ _null_ _null_ prsd_lextype _null_ _null_ _null_ ) +insert OID = 3723 ( ts_lexize 11 10 12 1 0 0 0 f f f f t f i 2 0 1009 "3769 25" _null_ _null_ _null_ _null_ ts_lexize _null_ _null_ _null_ ) +insert OID = 3725 ( dsimple_init 11 10 12 1 0 0 0 f f f f t f i 1 0 2281 "2281" _null_ _null_ _null_ _null_ dsimple_init _null_ _null_ _null_ ) +insert OID = 3726 ( dsimple_lexize 11 10 12 1 0 0 0 f f f f t f i 4 0 2281 "2281 2281 2281 2281" _null_ _null_ _null_ _null_ dsimple_lexize _null_ _null_ _null_ ) +insert OID = 3728 ( dsynonym_init 11 10 12 1 0 0 0 f f f f t f i 1 0 2281 "2281" _null_ _null_ _null_ _null_ dsynonym_init _null_ _null_ _null_ ) +insert OID = 3729 ( dsynonym_lexize 11 10 12 1 0 0 0 f f f f t f i 4 0 2281 "2281 2281 2281 2281" _null_ _null_ _null_ _null_ dsynonym_lexize _null_ _null_ _null_ ) +insert OID = 3731 ( dispell_init 11 10 12 1 0 0 0 f f f f t f i 1 0 2281 "2281" _null_ _null_ _null_ _null_ dispell_init _null_ _null_ _null_ ) +insert OID = 3732 ( dispell_lexize 11 10 12 1 0 0 0 f f f f t f i 4 0 2281 "2281 2281 2281 2281" _null_ _null_ _null_ _null_ dispell_lexize _null_ _null_ _null_ ) +insert OID = 3740 ( thesaurus_init 11 10 12 1 0 0 0 f f f f t f i 1 0 2281 "2281" _null_ _null_ _null_ _null_ thesaurus_init _null_ _null_ _null_ ) +insert OID = 3741 ( thesaurus_lexize 11 10 12 1 0 0 0 f f f f t f i 4 0 2281 "2281 2281 2281 2281" _null_ _null_ _null_ _null_ thesaurus_lexize _null_ _null_ _null_ ) +insert OID = 3743 ( ts_headline 11 10 12 1 0 0 0 f f f f t f i 4 0 25 "3734 25 3615 25" _null_ _null_ _null_ _null_ ts_headline_byid_opt _null_ _null_ _null_ ) +insert OID = 3744 ( ts_headline 11 10 12 1 0 0 0 f f f f t f i 3 0 25 "3734 25 3615" _null_ _null_ _null_ _null_ ts_headline_byid _null_ _null_ _null_ ) +insert OID = 3754 ( ts_headline 11 10 12 1 0 0 0 f f f f t f s 3 0 25 "25 3615 25" _null_ _null_ _null_ _null_ ts_headline_opt _null_ _null_ _null_ ) +insert OID = 3755 ( ts_headline 11 10 12 1 0 0 0 f f f f t f s 2 0 25 "25 3615" _null_ _null_ _null_ _null_ ts_headline _null_ _null_ _null_ ) +insert OID = 3745 ( to_tsvector 11 10 12 1 0 0 0 f f f f t f i 2 0 3614 "3734 25" _null_ _null_ _null_ _null_ to_tsvector_byid _null_ _null_ _null_ ) +insert OID = 3746 ( to_tsquery 11 10 12 1 0 0 0 f f f f t f i 2 0 3615 "3734 25" _null_ _null_ _null_ _null_ to_tsquery_byid _null_ _null_ _null_ ) +insert OID = 3747 ( plainto_tsquery 11 10 12 1 0 0 0 f f f f t f i 2 0 3615 "3734 25" _null_ _null_ _null_ _null_ plainto_tsquery_byid _null_ _null_ _null_ ) +insert OID = 3749 ( to_tsvector 11 10 12 1 0 0 0 f f f f t f s 1 0 3614 "25" _null_ _null_ _null_ _null_ to_tsvector _null_ _null_ _null_ ) +insert OID = 3750 ( to_tsquery 11 10 12 1 0 0 0 f f f f t f s 1 0 3615 "25" _null_ _null_ _null_ _null_ to_tsquery _null_ _null_ _null_ ) +insert OID = 3751 ( plainto_tsquery 11 10 12 1 0 0 0 f f f f t f s 1 0 3615 "25" _null_ _null_ _null_ _null_ plainto_tsquery _null_ _null_ _null_ ) +insert OID = 3752 ( tsvector_update_trigger 11 10 12 1 0 0 0 f f f f f f v 0 0 2279 "" _null_ _null_ _null_ _null_ tsvector_update_trigger_byid _null_ _null_ _null_ ) +insert OID = 3753 ( tsvector_update_trigger_column 11 10 12 1 0 0 0 f f f f f f v 0 0 2279 "" _null_ _null_ _null_ _null_ tsvector_update_trigger_bycolumn _null_ _null_ _null_ ) +insert OID = 3759 ( get_current_ts_config 11 10 12 1 0 0 0 f f f f t f s 0 0 3734 "" _null_ _null_ _null_ _null_ get_current_ts_config _null_ _null_ _null_ ) +insert OID = 3736 ( regconfigin 11 10 12 1 0 0 0 f f f f t f s 1 0 3734 "2275" _null_ _null_ _null_ _null_ regconfigin _null_ _null_ _null_ ) +insert OID = 3737 ( regconfigout 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "3734" _null_ _null_ _null_ _null_ regconfigout _null_ _null_ _null_ ) +insert OID = 3738 ( regconfigrecv 11 10 12 1 0 0 0 f f f f t f i 1 0 3734 "2281" _null_ _null_ _null_ _null_ regconfigrecv _null_ _null_ _null_ ) +insert OID = 3739 ( regconfigsend 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "3734" _null_ _null_ _null_ _null_ regconfigsend _null_ _null_ _null_ ) +insert OID = 3771 ( regdictionaryin 11 10 12 1 0 0 0 f f f f t f s 1 0 3769 "2275" _null_ _null_ _null_ _null_ regdictionaryin _null_ _null_ _null_ ) +insert OID = 3772 ( regdictionaryout 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "3769" _null_ _null_ _null_ _null_ regdictionaryout _null_ _null_ _null_ ) +insert OID = 3773 ( regdictionaryrecv 11 10 12 1 0 0 0 f f f f t f i 1 0 3769 "2281" _null_ _null_ _null_ _null_ regdictionaryrecv _null_ _null_ _null_ ) +insert OID = 3774 ( regdictionarysend 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "3769" _null_ _null_ _null_ _null_ regdictionarysend _null_ _null_ _null_ ) +insert OID = 2939 ( txid_snapshot_in 11 10 12 1 0 0 0 f f f f t f i 1 0 2970 "2275" _null_ _null_ _null_ _null_ txid_snapshot_in _null_ _null_ _null_ ) +insert OID = 2940 ( txid_snapshot_out 11 10 12 1 0 0 0 f f f f t f i 1 0 2275 "2970" _null_ _null_ _null_ _null_ txid_snapshot_out _null_ _null_ _null_ ) +insert OID = 2941 ( txid_snapshot_recv 11 10 12 1 0 0 0 f f f f t f i 1 0 2970 "2281" _null_ _null_ _null_ _null_ txid_snapshot_recv _null_ _null_ _null_ ) +insert OID = 2942 ( txid_snapshot_send 11 10 12 1 0 0 0 f f f f t f i 1 0 17 "2970" _null_ _null_ _null_ _null_ txid_snapshot_send _null_ _null_ _null_ ) +insert OID = 2943 ( txid_current 11 10 12 1 0 0 0 f f f f t f s 0 0 20 "" _null_ _null_ _null_ _null_ txid_current _null_ _null_ _null_ ) +insert OID = 2944 ( txid_current_snapshot 11 10 12 1 0 0 0 f f f f t f s 0 0 2970 "" _null_ _null_ _null_ _null_ txid_current_snapshot _null_ _null_ _null_ ) +insert OID = 2945 ( txid_snapshot_xmin 11 10 12 1 0 0 0 f f f f t f i 1 0 20 "2970" _null_ _null_ _null_ _null_ txid_snapshot_xmin _null_ _null_ _null_ ) +insert OID = 2946 ( txid_snapshot_xmax 11 10 12 1 0 0 0 f f f f t f i 1 0 20 "2970" _null_ _null_ _null_ _null_ txid_snapshot_xmax _null_ _null_ _null_ ) +insert OID = 2947 ( txid_snapshot_xip 11 10 12 1 50 0 0 f f f f t t i 1 0 20 "2970" _null_ _null_ _null_ _null_ txid_snapshot_xip _null_ _null_ _null_ ) +insert OID = 2948 ( txid_visible_in_snapshot 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "20 2970" _null_ _null_ _null_ _null_ txid_visible_in_snapshot _null_ _null_ _null_ ) +insert OID = 2981 ( record_eq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "2249 2249" _null_ _null_ _null_ _null_ record_eq _null_ _null_ _null_ ) +insert OID = 2982 ( record_ne 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "2249 2249" _null_ _null_ _null_ _null_ record_ne _null_ _null_ _null_ ) +insert OID = 2983 ( record_lt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "2249 2249" _null_ _null_ _null_ _null_ record_lt _null_ _null_ _null_ ) +insert OID = 2984 ( record_gt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "2249 2249" _null_ _null_ _null_ _null_ record_gt _null_ _null_ _null_ ) +insert OID = 2985 ( record_le 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "2249 2249" _null_ _null_ _null_ _null_ record_le _null_ _null_ _null_ ) +insert OID = 2986 ( record_ge 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "2249 2249" _null_ _null_ _null_ _null_ record_ge _null_ _null_ _null_ ) +insert OID = 2987 ( btrecordcmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "2249 2249" _null_ _null_ _null_ _null_ btrecordcmp _null_ _null_ _null_ ) +insert OID = 3082 ( pg_available_extensions 11 10 12 10 100 0 0 f f f f t t s 0 0 2249 "" "{19,25,25}" "{o,o,o}" "{name,default_version,comment}" _null_ pg_available_extensions _null_ _null_ _null_ ) +insert OID = 3083 ( pg_available_extension_versions 11 10 12 10 100 0 0 f f f f t t s 0 0 2249 "" "{19,25,16,16,19,1003,25}" "{o,o,o,o,o,o,o}" "{name,version,superuser,relocatable,schema,requires,comment}" _null_ pg_available_extension_versions _null_ _null_ _null_ ) +insert OID = 3084 ( pg_extension_update_paths 11 10 12 10 100 0 0 f f f f t t s 1 0 2249 "19" "{19,25,25,25}" "{i,o,o,o}" "{name,source,target,path}" _null_ pg_extension_update_paths _null_ _null_ _null_ ) +insert OID = 3086 ( pg_extension_config_dump 11 10 12 1 0 0 0 f f f f t f v 2 0 2278 "2205 25" _null_ _null_ _null_ _null_ pg_extension_config_dump _null_ _null_ _null_ ) +insert OID = 3100 ( row_number 11 10 12 1 0 0 0 f t f f f f i 0 0 20 "" _null_ _null_ _null_ _null_ window_row_number _null_ _null_ _null_ ) +insert OID = 3101 ( rank 11 10 12 1 0 0 0 f t f f f f i 0 0 20 "" _null_ _null_ _null_ _null_ window_rank _null_ _null_ _null_ ) +insert OID = 3102 ( dense_rank 11 10 12 1 0 0 0 f t f f f f i 0 0 20 "" _null_ _null_ _null_ _null_ window_dense_rank _null_ _null_ _null_ ) +insert OID = 3103 ( percent_rank 11 10 12 1 0 0 0 f t f f f f i 0 0 701 "" _null_ _null_ _null_ _null_ window_percent_rank _null_ _null_ _null_ ) +insert OID = 3104 ( cume_dist 11 10 12 1 0 0 0 f t f f f f i 0 0 701 "" _null_ _null_ _null_ _null_ window_cume_dist _null_ _null_ _null_ ) +insert OID = 3105 ( ntile 11 10 12 1 0 0 0 f t f f t f i 1 0 23 "23" _null_ _null_ _null_ _null_ window_ntile _null_ _null_ _null_ ) +insert OID = 3106 ( lag 11 10 12 1 0 0 0 f t f f t f i 1 0 2283 "2283" _null_ _null_ _null_ _null_ window_lag _null_ _null_ _null_ ) +insert OID = 3107 ( lag 11 10 12 1 0 0 0 f t f f t f i 2 0 2283 "2283 23" _null_ _null_ _null_ _null_ window_lag_with_offset _null_ _null_ _null_ ) +insert OID = 3108 ( lag 11 10 12 1 0 0 0 f t f f t f i 3 0 2283 "2283 23 2283" _null_ _null_ _null_ _null_ window_lag_with_offset_and_default _null_ _null_ _null_ ) +insert OID = 3109 ( lead 11 10 12 1 0 0 0 f t f f t f i 1 0 2283 "2283" _null_ _null_ _null_ _null_ window_lead _null_ _null_ _null_ ) +insert OID = 3110 ( lead 11 10 12 1 0 0 0 f t f f t f i 2 0 2283 "2283 23" _null_ _null_ _null_ _null_ window_lead_with_offset _null_ _null_ _null_ ) +insert OID = 3111 ( lead 11 10 12 1 0 0 0 f t f f t f i 3 0 2283 "2283 23 2283" _null_ _null_ _null_ _null_ window_lead_with_offset_and_default _null_ _null_ _null_ ) +insert OID = 3112 ( first_value 11 10 12 1 0 0 0 f t f f t f i 1 0 2283 "2283" _null_ _null_ _null_ _null_ window_first_value _null_ _null_ _null_ ) +insert OID = 3113 ( last_value 11 10 12 1 0 0 0 f t f f t f i 1 0 2283 "2283" _null_ _null_ _null_ _null_ window_last_value _null_ _null_ _null_ ) +insert OID = 3114 ( nth_value 11 10 12 1 0 0 0 f t f f t f i 2 0 2283 "2283 23" _null_ _null_ _null_ _null_ window_nth_value _null_ _null_ _null_ ) +insert OID = 3832 ( anyrange_in 11 10 12 1 0 0 0 f f f f t f s 3 0 3831 "2275 26 23" _null_ _null_ _null_ _null_ anyrange_in _null_ _null_ _null_ ) +insert OID = 3833 ( anyrange_out 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "3831" _null_ _null_ _null_ _null_ anyrange_out _null_ _null_ _null_ ) +insert OID = 3834 ( range_in 11 10 12 1 0 0 0 f f f f t f s 3 0 3831 "2275 26 23" _null_ _null_ _null_ _null_ range_in _null_ _null_ _null_ ) +insert OID = 3835 ( range_out 11 10 12 1 0 0 0 f f f f t f s 1 0 2275 "3831" _null_ _null_ _null_ _null_ range_out _null_ _null_ _null_ ) +insert OID = 3836 ( range_recv 11 10 12 1 0 0 0 f f f f t f s 3 0 3831 "2281 26 23" _null_ _null_ _null_ _null_ range_recv _null_ _null_ _null_ ) +insert OID = 3837 ( range_send 11 10 12 1 0 0 0 f f f f t f s 1 0 17 "3831" _null_ _null_ _null_ _null_ range_send _null_ _null_ _null_ ) +insert OID = 3848 ( lower 11 10 12 1 0 0 0 f f f f t f i 1 0 2283 "3831" _null_ _null_ _null_ _null_ range_lower _null_ _null_ _null_ ) +insert OID = 3849 ( upper 11 10 12 1 0 0 0 f f f f t f i 1 0 2283 "3831" _null_ _null_ _null_ _null_ range_upper _null_ _null_ _null_ ) +insert OID = 3850 ( isempty 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "3831" _null_ _null_ _null_ _null_ range_empty _null_ _null_ _null_ ) +insert OID = 3851 ( lower_inc 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "3831" _null_ _null_ _null_ _null_ range_lower_inc _null_ _null_ _null_ ) +insert OID = 3852 ( upper_inc 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "3831" _null_ _null_ _null_ _null_ range_upper_inc _null_ _null_ _null_ ) +insert OID = 3853 ( lower_inf 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "3831" _null_ _null_ _null_ _null_ range_lower_inf _null_ _null_ _null_ ) +insert OID = 3854 ( upper_inf 11 10 12 1 0 0 0 f f f f t f i 1 0 16 "3831" _null_ _null_ _null_ _null_ range_upper_inf _null_ _null_ _null_ ) +insert OID = 3855 ( range_eq 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3831 3831" _null_ _null_ _null_ _null_ range_eq _null_ _null_ _null_ ) +insert OID = 3856 ( range_ne 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3831 3831" _null_ _null_ _null_ _null_ range_ne _null_ _null_ _null_ ) +insert OID = 3857 ( range_overlaps 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3831 3831" _null_ _null_ _null_ _null_ range_overlaps _null_ _null_ _null_ ) +insert OID = 3858 ( range_contains_elem 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3831 2283" _null_ _null_ _null_ _null_ range_contains_elem _null_ _null_ _null_ ) +insert OID = 3859 ( range_contains 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3831 3831" _null_ _null_ _null_ _null_ range_contains _null_ _null_ _null_ ) +insert OID = 3860 ( elem_contained_by_range 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "2283 3831" _null_ _null_ _null_ _null_ elem_contained_by_range _null_ _null_ _null_ ) +insert OID = 3861 ( range_contained_by 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3831 3831" _null_ _null_ _null_ _null_ range_contained_by _null_ _null_ _null_ ) +insert OID = 3862 ( range_adjacent 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3831 3831" _null_ _null_ _null_ _null_ range_adjacent _null_ _null_ _null_ ) +insert OID = 3863 ( range_before 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3831 3831" _null_ _null_ _null_ _null_ range_before _null_ _null_ _null_ ) +insert OID = 3864 ( range_after 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3831 3831" _null_ _null_ _null_ _null_ range_after _null_ _null_ _null_ ) +insert OID = 3865 ( range_overleft 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3831 3831" _null_ _null_ _null_ _null_ range_overleft _null_ _null_ _null_ ) +insert OID = 3866 ( range_overright 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3831 3831" _null_ _null_ _null_ _null_ range_overright _null_ _null_ _null_ ) +insert OID = 3867 ( range_union 11 10 12 1 0 0 0 f f f f t f i 2 0 3831 "3831 3831" _null_ _null_ _null_ _null_ range_union _null_ _null_ _null_ ) +insert OID = 3868 ( range_intersect 11 10 12 1 0 0 0 f f f f t f i 2 0 3831 "3831 3831" _null_ _null_ _null_ _null_ range_intersect _null_ _null_ _null_ ) +insert OID = 3869 ( range_minus 11 10 12 1 0 0 0 f f f f t f i 2 0 3831 "3831 3831" _null_ _null_ _null_ _null_ range_minus _null_ _null_ _null_ ) +insert OID = 3870 ( range_cmp 11 10 12 1 0 0 0 f f f f t f i 2 0 23 "3831 3831" _null_ _null_ _null_ _null_ range_cmp _null_ _null_ _null_ ) +insert OID = 3871 ( range_lt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3831 3831" _null_ _null_ _null_ _null_ range_lt _null_ _null_ _null_ ) +insert OID = 3872 ( range_le 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3831 3831" _null_ _null_ _null_ _null_ range_le _null_ _null_ _null_ ) +insert OID = 3873 ( range_ge 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3831 3831" _null_ _null_ _null_ _null_ range_ge _null_ _null_ _null_ ) +insert OID = 3874 ( range_gt 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "3831 3831" _null_ _null_ _null_ _null_ range_gt _null_ _null_ _null_ ) +insert OID = 3875 ( range_gist_consistent 11 10 12 1 0 0 0 f f f f t f i 5 0 16 "2281 3831 23 26 2281" _null_ _null_ _null_ _null_ range_gist_consistent _null_ _null_ _null_ ) +insert OID = 3876 ( range_gist_union 11 10 12 1 0 0 0 f f f f t f i 2 0 2281 "2281 2281" _null_ _null_ _null_ _null_ range_gist_union _null_ _null_ _null_ ) +insert OID = 3877 ( range_gist_compress 11 10 12 1 0 0 0 f f f f t f i 1 0 2281 "2281" _null_ _null_ _null_ _null_ range_gist_compress _null_ _null_ _null_ ) +insert OID = 3878 ( range_gist_decompress 11 10 12 1 0 0 0 f f f f t f i 1 0 2281 "2281" _null_ _null_ _null_ _null_ range_gist_decompress _null_ _null_ _null_ ) +insert OID = 3879 ( range_gist_penalty 11 10 12 1 0 0 0 f f f f t f i 3 0 2281 "2281 2281 2281" _null_ _null_ _null_ _null_ range_gist_penalty _null_ _null_ _null_ ) +insert OID = 3880 ( range_gist_picksplit 11 10 12 1 0 0 0 f f f f t f i 2 0 2281 "2281 2281" _null_ _null_ _null_ _null_ range_gist_picksplit _null_ _null_ _null_ ) +insert OID = 3881 ( range_gist_same 11 10 12 1 0 0 0 f f f f t f i 3 0 2281 "3831 3831 2281" _null_ _null_ _null_ _null_ range_gist_same _null_ _null_ _null_ ) +insert OID = 3902 ( hash_range 11 10 12 1 0 0 0 f f f f t f i 1 0 23 "3831" _null_ _null_ _null_ _null_ hash_range _null_ _null_ _null_ ) +insert OID = 3916 ( range_typanalyze 11 10 12 1 0 0 0 f f f f t f s 1 0 16 "2281" _null_ _null_ _null_ _null_ range_typanalyze _null_ _null_ _null_ ) +insert OID = 3914 ( int4range_canonical 11 10 12 1 0 0 0 f f f f t f i 1 0 3904 "3904" _null_ _null_ _null_ _null_ int4range_canonical _null_ _null_ _null_ ) +insert OID = 3928 ( int8range_canonical 11 10 12 1 0 0 0 f f f f t f i 1 0 3926 "3926" _null_ _null_ _null_ _null_ int8range_canonical _null_ _null_ _null_ ) +insert OID = 3915 ( daterange_canonical 11 10 12 1 0 0 0 f f f f t f i 1 0 3912 "3912" _null_ _null_ _null_ _null_ daterange_canonical _null_ _null_ _null_ ) +insert OID = 3922 ( int4range_subdiff 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "23 23" _null_ _null_ _null_ _null_ int4range_subdiff _null_ _null_ _null_ ) +insert OID = 3923 ( int8range_subdiff 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "20 20" _null_ _null_ _null_ _null_ int8range_subdiff _null_ _null_ _null_ ) +insert OID = 3924 ( numrange_subdiff 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "1700 1700" _null_ _null_ _null_ _null_ numrange_subdiff _null_ _null_ _null_ ) +insert OID = 3925 ( daterange_subdiff 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "1082 1082" _null_ _null_ _null_ _null_ daterange_subdiff _null_ _null_ _null_ ) +insert OID = 3929 ( tsrange_subdiff 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "1114 1114" _null_ _null_ _null_ _null_ tsrange_subdiff _null_ _null_ _null_ ) +insert OID = 3930 ( tstzrange_subdiff 11 10 12 1 0 0 0 f f f f t f i 2 0 701 "1184 1184" _null_ _null_ _null_ _null_ tstzrange_subdiff _null_ _null_ _null_ ) +insert OID = 3840 ( int4range 11 10 12 1 0 0 0 f f f f f f i 2 0 3904 "23 23" _null_ _null_ _null_ _null_ range_constructor2 _null_ _null_ _null_ ) +insert OID = 3841 ( int4range 11 10 12 1 0 0 0 f f f f f f i 3 0 3904 "23 23 25" _null_ _null_ _null_ _null_ range_constructor3 _null_ _null_ _null_ ) +insert OID = 3844 ( numrange 11 10 12 1 0 0 0 f f f f f f i 2 0 3906 "1700 1700" _null_ _null_ _null_ _null_ range_constructor2 _null_ _null_ _null_ ) +insert OID = 3845 ( numrange 11 10 12 1 0 0 0 f f f f f f i 3 0 3906 "1700 1700 25" _null_ _null_ _null_ _null_ range_constructor3 _null_ _null_ _null_ ) +insert OID = 3933 ( tsrange 11 10 12 1 0 0 0 f f f f f f i 2 0 3908 "1114 1114" _null_ _null_ _null_ _null_ range_constructor2 _null_ _null_ _null_ ) +insert OID = 3934 ( tsrange 11 10 12 1 0 0 0 f f f f f f i 3 0 3908 "1114 1114 25" _null_ _null_ _null_ _null_ range_constructor3 _null_ _null_ _null_ ) +insert OID = 3937 ( tstzrange 11 10 12 1 0 0 0 f f f f f f i 2 0 3910 "1184 1184" _null_ _null_ _null_ _null_ range_constructor2 _null_ _null_ _null_ ) +insert OID = 3938 ( tstzrange 11 10 12 1 0 0 0 f f f f f f i 3 0 3910 "1184 1184 25" _null_ _null_ _null_ _null_ range_constructor3 _null_ _null_ _null_ ) +insert OID = 3941 ( daterange 11 10 12 1 0 0 0 f f f f f f i 2 0 3912 "1082 1082" _null_ _null_ _null_ _null_ range_constructor2 _null_ _null_ _null_ ) +insert OID = 3942 ( daterange 11 10 12 1 0 0 0 f f f f f f i 3 0 3912 "1082 1082 25" _null_ _null_ _null_ _null_ range_constructor3 _null_ _null_ _null_ ) +insert OID = 3945 ( int8range 11 10 12 1 0 0 0 f f f f f f i 2 0 3926 "20 20" _null_ _null_ _null_ _null_ range_constructor2 _null_ _null_ _null_ ) +insert OID = 3946 ( int8range 11 10 12 1 0 0 0 f f f f f f i 3 0 3926 "20 20 25" _null_ _null_ _null_ _null_ range_constructor3 _null_ _null_ _null_ ) +insert OID = 4001 ( spggettuple 11 10 12 1 0 0 0 f f f f t f v 2 0 16 "2281 2281" _null_ _null_ _null_ _null_ spggettuple _null_ _null_ _null_ ) +insert OID = 4002 ( spggetbitmap 11 10 12 1 0 0 0 f f f f t f v 2 0 20 "2281 2281" _null_ _null_ _null_ _null_ spggetbitmap _null_ _null_ _null_ ) +insert OID = 4003 ( spginsert 11 10 12 1 0 0 0 f f f f t f v 6 0 16 "2281 2281 2281 2281 2281 2281" _null_ _null_ _null_ _null_ spginsert _null_ _null_ _null_ ) +insert OID = 4004 ( spgbeginscan 11 10 12 1 0 0 0 f f f f t f v 3 0 2281 "2281 2281 2281" _null_ _null_ _null_ _null_ spgbeginscan _null_ _null_ _null_ ) +insert OID = 4005 ( spgrescan 11 10 12 1 0 0 0 f f f f t f v 5 0 2278 "2281 2281 2281 2281 2281" _null_ _null_ _null_ _null_ spgrescan _null_ _null_ _null_ ) +insert OID = 4006 ( spgendscan 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "2281" _null_ _null_ _null_ _null_ spgendscan _null_ _null_ _null_ ) +insert OID = 4007 ( spgmarkpos 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "2281" _null_ _null_ _null_ _null_ spgmarkpos _null_ _null_ _null_ ) +insert OID = 4008 ( spgrestrpos 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "2281" _null_ _null_ _null_ _null_ spgrestrpos _null_ _null_ _null_ ) +insert OID = 4009 ( spgbuild 11 10 12 1 0 0 0 f f f f t f v 3 0 2281 "2281 2281 2281" _null_ _null_ _null_ _null_ spgbuild _null_ _null_ _null_ ) +insert OID = 4010 ( spgbuildempty 11 10 12 1 0 0 0 f f f f t f v 1 0 2278 "2281" _null_ _null_ _null_ _null_ spgbuildempty _null_ _null_ _null_ ) +insert OID = 4011 ( spgbulkdelete 11 10 12 1 0 0 0 f f f f t f v 4 0 2281 "2281 2281 2281 2281" _null_ _null_ _null_ _null_ spgbulkdelete _null_ _null_ _null_ ) +insert OID = 4012 ( spgvacuumcleanup 11 10 12 1 0 0 0 f f f f t f v 2 0 2281 "2281 2281" _null_ _null_ _null_ _null_ spgvacuumcleanup _null_ _null_ _null_ ) +insert OID = 4032 ( spgcanreturn 11 10 12 1 0 0 0 f f f f t f s 1 0 16 "2281" _null_ _null_ _null_ _null_ spgcanreturn _null_ _null_ _null_ ) +insert OID = 4013 ( spgcostestimate 11 10 12 1 0 0 0 f f f f t f v 7 0 2278 "2281 2281 2281 2281 2281 2281 2281" _null_ _null_ _null_ _null_ spgcostestimate _null_ _null_ _null_ ) +insert OID = 4014 ( spgoptions 11 10 12 1 0 0 0 f f f f t f s 2 0 17 "1009 16" _null_ _null_ _null_ _null_ spgoptions _null_ _null_ _null_ ) +insert OID = 4018 ( spg_quad_config 11 10 12 1 0 0 0 f f f f t f i 2 0 2278 "2281 2281" _null_ _null_ _null_ _null_ spg_quad_config _null_ _null_ _null_ ) +insert OID = 4019 ( spg_quad_choose 11 10 12 1 0 0 0 f f f f t f i 2 0 2278 "2281 2281" _null_ _null_ _null_ _null_ spg_quad_choose _null_ _null_ _null_ ) +insert OID = 4020 ( spg_quad_picksplit 11 10 12 1 0 0 0 f f f f t f i 2 0 2278 "2281 2281" _null_ _null_ _null_ _null_ spg_quad_picksplit _null_ _null_ _null_ ) +insert OID = 4021 ( spg_quad_inner_consistent 11 10 12 1 0 0 0 f f f f t f i 2 0 2278 "2281 2281" _null_ _null_ _null_ _null_ spg_quad_inner_consistent _null_ _null_ _null_ ) +insert OID = 4022 ( spg_quad_leaf_consistent 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "2281 2281" _null_ _null_ _null_ _null_ spg_quad_leaf_consistent _null_ _null_ _null_ ) +insert OID = 4023 ( spg_kd_config 11 10 12 1 0 0 0 f f f f t f i 2 0 2278 "2281 2281" _null_ _null_ _null_ _null_ spg_kd_config _null_ _null_ _null_ ) +insert OID = 4024 ( spg_kd_choose 11 10 12 1 0 0 0 f f f f t f i 2 0 2278 "2281 2281" _null_ _null_ _null_ _null_ spg_kd_choose _null_ _null_ _null_ ) +insert OID = 4025 ( spg_kd_picksplit 11 10 12 1 0 0 0 f f f f t f i 2 0 2278 "2281 2281" _null_ _null_ _null_ _null_ spg_kd_picksplit _null_ _null_ _null_ ) +insert OID = 4026 ( spg_kd_inner_consistent 11 10 12 1 0 0 0 f f f f t f i 2 0 2278 "2281 2281" _null_ _null_ _null_ _null_ spg_kd_inner_consistent _null_ _null_ _null_ ) +insert OID = 4027 ( spg_text_config 11 10 12 1 0 0 0 f f f f t f i 2 0 2278 "2281 2281" _null_ _null_ _null_ _null_ spg_text_config _null_ _null_ _null_ ) +insert OID = 4028 ( spg_text_choose 11 10 12 1 0 0 0 f f f f t f i 2 0 2278 "2281 2281" _null_ _null_ _null_ _null_ spg_text_choose _null_ _null_ _null_ ) +insert OID = 4029 ( spg_text_picksplit 11 10 12 1 0 0 0 f f f f t f i 2 0 2278 "2281 2281" _null_ _null_ _null_ _null_ spg_text_picksplit _null_ _null_ _null_ ) +insert OID = 4030 ( spg_text_inner_consistent 11 10 12 1 0 0 0 f f f f t f i 2 0 2278 "2281 2281" _null_ _null_ _null_ _null_ spg_text_inner_consistent _null_ _null_ _null_ ) +insert OID = 4031 ( spg_text_leaf_consistent 11 10 12 1 0 0 0 f f f f t f i 2 0 16 "2281 2281" _null_ _null_ _null_ _null_ spg_text_leaf_consistent _null_ _null_ _null_ ) +close pg_proc +create pg_type 1247 bootstrap rowtype_oid 71 + ( + typname = name , + typnamespace = oid , + typowner = oid , + typlen = int2 , + typbyval = bool , + typtype = char , + typcategory = char , + typispreferred = bool , + typisdefined = bool , + typdelim = char , + typrelid = oid , + typelem = oid , + typarray = oid , + typinput = regproc , + typoutput = regproc , + typreceive = regproc , + typsend = regproc , + typmodin = regproc , + typmodout = regproc , + typanalyze = regproc , + typalign = char , + typstorage = char , + typnotnull = bool , + typbasetype = oid , + typtypmod = int4 , + typndims = int4 , + typcollation = oid , + typdefaultbin = pg_node_tree , + typdefault = text , + typacl = aclitem[] + ) +insert OID = 16 ( bool 11 10 1 t b B t t \054 0 0 1000 boolin boolout boolrecv boolsend - - - c p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 17 ( bytea 11 10 -1 f b U f t \054 0 0 1001 byteain byteaout bytearecv byteasend - - - i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 18 ( char 11 10 1 t b S f t \054 0 0 1002 charin charout charrecv charsend - - - c p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 19 ( name 11 10 NAMEDATALEN f b S f t \054 0 18 1003 namein nameout namerecv namesend - - - c p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 20 ( int8 11 10 8 FLOAT8PASSBYVAL b N f t \054 0 0 1016 int8in int8out int8recv int8send - - - d p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 21 ( int2 11 10 2 t b N f t \054 0 0 1005 int2in int2out int2recv int2send - - - s p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 22 ( int2vector 11 10 -1 f b A f t \054 0 21 1006 int2vectorin int2vectorout int2vectorrecv int2vectorsend - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 23 ( int4 11 10 4 t b N f t \054 0 0 1007 int4in int4out int4recv int4send - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 24 ( regproc 11 10 4 t b N f t \054 0 0 1008 regprocin regprocout regprocrecv regprocsend - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 25 ( text 11 10 -1 f b S t t \054 0 0 1009 textin textout textrecv textsend - - - i x f 0 -1 0 100 _null_ _null_ _null_ ) +insert OID = 26 ( oid 11 10 4 t b N t t \054 0 0 1028 oidin oidout oidrecv oidsend - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 27 ( tid 11 10 6 f b U f t \054 0 0 1010 tidin tidout tidrecv tidsend - - - s p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 28 ( xid 11 10 4 t b U f t \054 0 0 1011 xidin xidout xidrecv xidsend - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 29 ( cid 11 10 4 t b U f t \054 0 0 1012 cidin cidout cidrecv cidsend - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 30 ( oidvector 11 10 -1 f b A f t \054 0 26 1013 oidvectorin oidvectorout oidvectorrecv oidvectorsend - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 71 ( pg_type 11 10 -1 f c C f t \054 1247 0 0 record_in record_out record_recv record_send - - - d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 75 ( pg_attribute 11 10 -1 f c C f t \054 1249 0 0 record_in record_out record_recv record_send - - - d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 81 ( pg_proc 11 10 -1 f c C f t \054 1255 0 0 record_in record_out record_recv record_send - - - d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 83 ( pg_class 11 10 -1 f c C f t \054 1259 0 0 record_in record_out record_recv record_send - - - d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 114 ( json 11 10 -1 f b U f t \054 0 0 199 json_in json_out json_recv json_send - - - i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 142 ( xml 11 10 -1 f b U f t \054 0 0 143 xml_in xml_out xml_recv xml_send - - - i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 143 ( _xml 11 10 -1 f b A f t \054 0 142 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 199 ( _json 11 10 -1 f b A f t \054 0 114 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 194 ( pg_node_tree 11 10 -1 f b S f t \054 0 0 0 pg_node_tree_in pg_node_tree_out pg_node_tree_recv pg_node_tree_send - - - i x f 0 -1 0 100 _null_ _null_ _null_ ) +insert OID = 210 ( smgr 11 10 2 t b U f t \054 0 0 0 smgrin smgrout - - - - - s p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 600 ( point 11 10 16 f b G f t \054 0 701 1017 point_in point_out point_recv point_send - - - d p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 601 ( lseg 11 10 32 f b G f t \054 0 600 1018 lseg_in lseg_out lseg_recv lseg_send - - - d p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 602 ( path 11 10 -1 f b G f t \054 0 0 1019 path_in path_out path_recv path_send - - - d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 603 ( box 11 10 32 f b G f t \073 0 600 1020 box_in box_out box_recv box_send - - - d p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 604 ( polygon 11 10 -1 f b G f t \054 0 0 1027 poly_in poly_out poly_recv poly_send - - - d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 628 ( line 11 10 32 f b G f t \054 0 701 629 line_in line_out line_recv line_send - - - d p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 629 ( _line 11 10 -1 f b A f t \054 0 628 0 array_in array_out array_recv array_send - - array_typanalyze d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 700 ( float4 11 10 4 FLOAT4PASSBYVAL b N f t \054 0 0 1021 float4in float4out float4recv float4send - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 701 ( float8 11 10 8 FLOAT8PASSBYVAL b N t t \054 0 0 1022 float8in float8out float8recv float8send - - - d p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 702 ( abstime 11 10 4 t b D f t \054 0 0 1023 abstimein abstimeout abstimerecv abstimesend - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 703 ( reltime 11 10 4 t b T f t \054 0 0 1024 reltimein reltimeout reltimerecv reltimesend - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 704 ( tinterval 11 10 12 f b T f t \054 0 0 1025 tintervalin tintervalout tintervalrecv tintervalsend - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 705 ( unknown 11 10 -2 f b X f t \054 0 0 0 unknownin unknownout unknownrecv unknownsend - - - c p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 718 ( circle 11 10 24 f b G f t \054 0 0 719 circle_in circle_out circle_recv circle_send - - - d p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 719 ( _circle 11 10 -1 f b A f t \054 0 718 0 array_in array_out array_recv array_send - - array_typanalyze d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 790 ( money 11 10 8 FLOAT8PASSBYVAL b N f t \054 0 0 791 cash_in cash_out cash_recv cash_send - - - d p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 791 ( _money 11 10 -1 f b A f t \054 0 790 0 array_in array_out array_recv array_send - - array_typanalyze d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 829 ( macaddr 11 10 6 f b U f t \054 0 0 1040 macaddr_in macaddr_out macaddr_recv macaddr_send - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 869 ( inet 11 10 -1 f b I t t \054 0 0 1041 inet_in inet_out inet_recv inet_send - - - i m f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 650 ( cidr 11 10 -1 f b I f t \054 0 0 651 cidr_in cidr_out cidr_recv cidr_send - - - i m f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1000 ( _bool 11 10 -1 f b A f t \054 0 16 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1001 ( _bytea 11 10 -1 f b A f t \054 0 17 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1002 ( _char 11 10 -1 f b A f t \054 0 18 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1003 ( _name 11 10 -1 f b A f t \054 0 19 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1005 ( _int2 11 10 -1 f b A f t \054 0 21 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1006 ( _int2vector 11 10 -1 f b A f t \054 0 22 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1007 ( _int4 11 10 -1 f b A f t \054 0 23 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1008 ( _regproc 11 10 -1 f b A f t \054 0 24 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1009 ( _text 11 10 -1 f b A f t \054 0 25 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 100 _null_ _null_ _null_ ) +insert OID = 1028 ( _oid 11 10 -1 f b A f t \054 0 26 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1010 ( _tid 11 10 -1 f b A f t \054 0 27 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1011 ( _xid 11 10 -1 f b A f t \054 0 28 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1012 ( _cid 11 10 -1 f b A f t \054 0 29 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1013 ( _oidvector 11 10 -1 f b A f t \054 0 30 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1014 ( _bpchar 11 10 -1 f b A f t \054 0 1042 0 array_in array_out array_recv array_send bpchartypmodin bpchartypmodout array_typanalyze i x f 0 -1 0 100 _null_ _null_ _null_ ) +insert OID = 1015 ( _varchar 11 10 -1 f b A f t \054 0 1043 0 array_in array_out array_recv array_send varchartypmodin varchartypmodout array_typanalyze i x f 0 -1 0 100 _null_ _null_ _null_ ) +insert OID = 1016 ( _int8 11 10 -1 f b A f t \054 0 20 0 array_in array_out array_recv array_send - - array_typanalyze d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1017 ( _point 11 10 -1 f b A f t \054 0 600 0 array_in array_out array_recv array_send - - array_typanalyze d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1018 ( _lseg 11 10 -1 f b A f t \054 0 601 0 array_in array_out array_recv array_send - - array_typanalyze d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1019 ( _path 11 10 -1 f b A f t \054 0 602 0 array_in array_out array_recv array_send - - array_typanalyze d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1020 ( _box 11 10 -1 f b A f t \073 0 603 0 array_in array_out array_recv array_send - - array_typanalyze d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1021 ( _float4 11 10 -1 f b A f t \054 0 700 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1022 ( _float8 11 10 -1 f b A f t \054 0 701 0 array_in array_out array_recv array_send - - array_typanalyze d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1023 ( _abstime 11 10 -1 f b A f t \054 0 702 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1024 ( _reltime 11 10 -1 f b A f t \054 0 703 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1025 ( _tinterval 11 10 -1 f b A f t \054 0 704 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1027 ( _polygon 11 10 -1 f b A f t \054 0 604 0 array_in array_out array_recv array_send - - array_typanalyze d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1033 ( aclitem 11 10 12 f b U f t \054 0 0 1034 aclitemin aclitemout - - - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1034 ( _aclitem 11 10 -1 f b A f t \054 0 1033 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1040 ( _macaddr 11 10 -1 f b A f t \054 0 829 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1041 ( _inet 11 10 -1 f b A f t \054 0 869 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 651 ( _cidr 11 10 -1 f b A f t \054 0 650 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1263 ( _cstring 11 10 -1 f b A f t \054 0 2275 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1042 ( bpchar 11 10 -1 f b S f t \054 0 0 1014 bpcharin bpcharout bpcharrecv bpcharsend bpchartypmodin bpchartypmodout - i x f 0 -1 0 100 _null_ _null_ _null_ ) +insert OID = 1043 ( varchar 11 10 -1 f b S f t \054 0 0 1015 varcharin varcharout varcharrecv varcharsend varchartypmodin varchartypmodout - i x f 0 -1 0 100 _null_ _null_ _null_ ) +insert OID = 1082 ( date 11 10 4 t b D f t \054 0 0 1182 date_in date_out date_recv date_send - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1083 ( time 11 10 8 FLOAT8PASSBYVAL b D f t \054 0 0 1183 time_in time_out time_recv time_send timetypmodin timetypmodout - d p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1114 ( timestamp 11 10 8 FLOAT8PASSBYVAL b D f t \054 0 0 1115 timestamp_in timestamp_out timestamp_recv timestamp_send timestamptypmodin timestamptypmodout - d p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1115 ( _timestamp 11 10 -1 f b A f t \054 0 1114 0 array_in array_out array_recv array_send timestamptypmodin timestamptypmodout array_typanalyze d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1182 ( _date 11 10 -1 f b A f t \054 0 1082 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1183 ( _time 11 10 -1 f b A f t \054 0 1083 0 array_in array_out array_recv array_send timetypmodin timetypmodout array_typanalyze d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1184 ( timestamptz 11 10 8 FLOAT8PASSBYVAL b D t t \054 0 0 1185 timestamptz_in timestamptz_out timestamptz_recv timestamptz_send timestamptztypmodin timestamptztypmodout - d p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1185 ( _timestamptz 11 10 -1 f b A f t \054 0 1184 0 array_in array_out array_recv array_send timestamptztypmodin timestamptztypmodout array_typanalyze d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1186 ( interval 11 10 16 f b T t t \054 0 0 1187 interval_in interval_out interval_recv interval_send intervaltypmodin intervaltypmodout - d p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1187 ( _interval 11 10 -1 f b A f t \054 0 1186 0 array_in array_out array_recv array_send intervaltypmodin intervaltypmodout array_typanalyze d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1231 ( _numeric 11 10 -1 f b A f t \054 0 1700 0 array_in array_out array_recv array_send numerictypmodin numerictypmodout array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1266 ( timetz 11 10 12 f b D f t \054 0 0 1270 timetz_in timetz_out timetz_recv timetz_send timetztypmodin timetztypmodout - d p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1270 ( _timetz 11 10 -1 f b A f t \054 0 1266 0 array_in array_out array_recv array_send timetztypmodin timetztypmodout array_typanalyze d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1560 ( bit 11 10 -1 f b V f t \054 0 0 1561 bit_in bit_out bit_recv bit_send bittypmodin bittypmodout - i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1561 ( _bit 11 10 -1 f b A f t \054 0 1560 0 array_in array_out array_recv array_send bittypmodin bittypmodout array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1562 ( varbit 11 10 -1 f b V t t \054 0 0 1563 varbit_in varbit_out varbit_recv varbit_send varbittypmodin varbittypmodout - i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1563 ( _varbit 11 10 -1 f b A f t \054 0 1562 0 array_in array_out array_recv array_send varbittypmodin varbittypmodout array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1700 ( numeric 11 10 -1 f b N f t \054 0 0 1231 numeric_in numeric_out numeric_recv numeric_send numerictypmodin numerictypmodout - i m f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 1790 ( refcursor 11 10 -1 f b U f t \054 0 0 2201 textin textout textrecv textsend - - - i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2201 ( _refcursor 11 10 -1 f b A f t \054 0 1790 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2202 ( regprocedure 11 10 4 t b N f t \054 0 0 2207 regprocedurein regprocedureout regprocedurerecv regproceduresend - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2203 ( regoper 11 10 4 t b N f t \054 0 0 2208 regoperin regoperout regoperrecv regopersend - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2204 ( regoperator 11 10 4 t b N f t \054 0 0 2209 regoperatorin regoperatorout regoperatorrecv regoperatorsend - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2205 ( regclass 11 10 4 t b N f t \054 0 0 2210 regclassin regclassout regclassrecv regclasssend - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2206 ( regtype 11 10 4 t b N f t \054 0 0 2211 regtypein regtypeout regtyperecv regtypesend - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2207 ( _regprocedure 11 10 -1 f b A f t \054 0 2202 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2208 ( _regoper 11 10 -1 f b A f t \054 0 2203 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2209 ( _regoperator 11 10 -1 f b A f t \054 0 2204 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2210 ( _regclass 11 10 -1 f b A f t \054 0 2205 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2211 ( _regtype 11 10 -1 f b A f t \054 0 2206 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2950 ( uuid 11 10 16 f b U f t \054 0 0 2951 uuid_in uuid_out uuid_recv uuid_send - - - c p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2951 ( _uuid 11 10 -1 f b A f t \054 0 2950 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3614 ( tsvector 11 10 -1 f b U f t \054 0 0 3643 tsvectorin tsvectorout tsvectorrecv tsvectorsend - - ts_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3642 ( gtsvector 11 10 -1 f b U f t \054 0 0 3644 gtsvectorin gtsvectorout - - - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3615 ( tsquery 11 10 -1 f b U f t \054 0 0 3645 tsqueryin tsqueryout tsqueryrecv tsquerysend - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3734 ( regconfig 11 10 4 t b N f t \054 0 0 3735 regconfigin regconfigout regconfigrecv regconfigsend - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3769 ( regdictionary 11 10 4 t b N f t \054 0 0 3770 regdictionaryin regdictionaryout regdictionaryrecv regdictionarysend - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3643 ( _tsvector 11 10 -1 f b A f t \054 0 3614 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3644 ( _gtsvector 11 10 -1 f b A f t \054 0 3642 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3645 ( _tsquery 11 10 -1 f b A f t \054 0 3615 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3735 ( _regconfig 11 10 -1 f b A f t \054 0 3734 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3770 ( _regdictionary 11 10 -1 f b A f t \054 0 3769 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2970 ( txid_snapshot 11 10 -1 f b U f t \054 0 0 2949 txid_snapshot_in txid_snapshot_out txid_snapshot_recv txid_snapshot_send - - - d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2949 ( _txid_snapshot 11 10 -1 f b A f t \054 0 2970 0 array_in array_out array_recv array_send - - array_typanalyze d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3904 ( int4range 11 10 -1 f r R f t \054 0 0 3905 range_in range_out range_recv range_send - - range_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3905 ( _int4range 11 10 -1 f b A f t \054 0 3904 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3906 ( numrange 11 10 -1 f r R f t \054 0 0 3907 range_in range_out range_recv range_send - - range_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3907 ( _numrange 11 10 -1 f b A f t \054 0 3906 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3908 ( tsrange 11 10 -1 f r R f t \054 0 0 3909 range_in range_out range_recv range_send - - range_typanalyze d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3909 ( _tsrange 11 10 -1 f b A f t \054 0 3908 0 array_in array_out array_recv array_send - - array_typanalyze d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3910 ( tstzrange 11 10 -1 f r R f t \054 0 0 3911 range_in range_out range_recv range_send - - range_typanalyze d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3911 ( _tstzrange 11 10 -1 f b A f t \054 0 3910 0 array_in array_out array_recv array_send - - array_typanalyze d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3912 ( daterange 11 10 -1 f r R f t \054 0 0 3913 range_in range_out range_recv range_send - - range_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3913 ( _daterange 11 10 -1 f b A f t \054 0 3912 0 array_in array_out array_recv array_send - - array_typanalyze i x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3926 ( int8range 11 10 -1 f r R f t \054 0 0 3927 range_in range_out range_recv range_send - - range_typanalyze d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3927 ( _int8range 11 10 -1 f b A f t \054 0 3926 0 array_in array_out array_recv array_send - - array_typanalyze d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2249 ( record 11 10 -1 f p P f t \054 0 0 2287 record_in record_out record_recv record_send - - - d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2287 ( _record 11 10 -1 f p P f t \054 0 2249 0 array_in array_out array_recv array_send - - array_typanalyze d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2275 ( cstring 11 10 -2 f p P f t \054 0 0 1263 cstring_in cstring_out cstring_recv cstring_send - - - c p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2276 ( any 11 10 4 t p P f t \054 0 0 0 any_in any_out - - - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2277 ( anyarray 11 10 -1 f p P f t \054 0 0 0 anyarray_in anyarray_out anyarray_recv anyarray_send - - - d x f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2278 ( void 11 10 4 t p P f t \054 0 0 0 void_in void_out void_recv void_send - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2279 ( trigger 11 10 4 t p P f t \054 0 0 0 trigger_in trigger_out - - - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2280 ( language_handler 11 10 4 t p P f t \054 0 0 0 language_handler_in language_handler_out - - - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2281 ( internal 11 10 SIZEOF_POINTER t p P f t \054 0 0 0 internal_in internal_out - - - - - ALIGNOF_POINTER p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2282 ( opaque 11 10 4 t p P f t \054 0 0 0 opaque_in opaque_out - - - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2283 ( anyelement 11 10 4 t p P f t \054 0 0 0 anyelement_in anyelement_out - - - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 2776 ( anynonarray 11 10 4 t p P f t \054 0 0 0 anynonarray_in anynonarray_out - - - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3500 ( anyenum 11 10 4 t p P f t \054 0 0 0 anyenum_in anyenum_out - - - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3115 ( fdw_handler 11 10 4 t p P f t \054 0 0 0 fdw_handler_in fdw_handler_out - - - - - i p f 0 -1 0 0 _null_ _null_ _null_ ) +insert OID = 3831 ( anyrange 11 10 -1 f p P f t \054 0 0 0 anyrange_in anyrange_out - - - - - d x f 0 -1 0 0 _null_ _null_ _null_ ) +close pg_type +create pg_attribute 1249 bootstrap without_oids rowtype_oid 75 + ( + attrelid = oid , + attname = name , + atttypid = oid , + attstattarget = int4 , + attlen = int2 , + attnum = int2 , + attndims = int4 , + attcacheoff = int4 , + atttypmod = int4 , + attbyval = bool , + attstorage = char , + attalign = char , + attnotnull = bool , + atthasdef = bool , + attisdropped = bool , + attislocal = bool , + attinhcount = int4 , + attcollation = oid , + attacl = aclitem[] , + attoptions = text[] , + attfdwoptions = text[] + ) +insert ( 1255 proname 19 -1 NAMEDATALEN 1 0 -1 -1 f p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 pronamespace 26 -1 4 2 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 proowner 26 -1 4 3 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 prolang 26 -1 4 4 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 procost 700 -1 4 5 0 -1 -1 FLOAT4PASSBYVAL p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 prorows 700 -1 4 6 0 -1 -1 FLOAT4PASSBYVAL p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 provariadic 26 -1 4 7 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 protransform 24 -1 4 8 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 proisagg 16 -1 1 9 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 proiswindow 16 -1 1 10 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 prosecdef 16 -1 1 11 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 proleakproof 16 -1 1 12 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 proisstrict 16 -1 1 13 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 proretset 16 -1 1 14 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 provolatile 18 -1 1 15 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 pronargs 21 -1 2 16 0 -1 -1 t p s t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 pronargdefaults 21 -1 2 17 0 -1 -1 t p s t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 prorettype 26 -1 4 18 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 proargtypes 30 -1 -1 19 1 -1 -1 f p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 proallargtypes 1028 -1 -1 20 1 -1 -1 f x i f f f t 0 0 _null_ _null_ _null_) +insert ( 1255 proargmodes 1002 -1 -1 21 1 -1 -1 f x i f f f t 0 0 _null_ _null_ _null_) +insert ( 1255 proargnames 1009 -1 -1 22 1 -1 -1 f x i f f f t 0 100 _null_ _null_ _null_) +insert ( 1255 proargdefaults 194 -1 -1 23 0 -1 -1 f x i f f f t 0 100 _null_ _null_ _null_) +insert ( 1255 prosrc 25 -1 -1 24 0 -1 -1 f x i f f f t 0 100 _null_ _null_ _null_) +insert ( 1255 probin 25 -1 -1 25 0 -1 -1 f x i f f f t 0 100 _null_ _null_ _null_) +insert ( 1255 proconfig 1009 -1 -1 26 1 -1 -1 f x i f f f t 0 100 _null_ _null_ _null_) +insert ( 1255 proacl 1034 -1 -1 27 1 -1 -1 f x i f f f t 0 0 _null_ _null_ _null_) +insert ( 1255 ctid 27 0 6 -1 0 -1 -1 f p s t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 oid 26 0 4 -2 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 xmin 28 0 4 -3 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 cmin 29 0 4 -4 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 xmax 28 0 4 -5 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 cmax 29 0 4 -6 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1255 tableoid 26 0 4 -7 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typname 19 -1 NAMEDATALEN 1 0 -1 -1 f p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typnamespace 26 -1 4 2 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typowner 26 -1 4 3 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typlen 21 -1 2 4 0 -1 -1 t p s t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typbyval 16 -1 1 5 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typtype 18 -1 1 6 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typcategory 18 -1 1 7 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typispreferred 16 -1 1 8 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typisdefined 16 -1 1 9 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typdelim 18 -1 1 10 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typrelid 26 -1 4 11 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typelem 26 -1 4 12 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typarray 26 -1 4 13 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typinput 24 -1 4 14 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typoutput 24 -1 4 15 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typreceive 24 -1 4 16 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typsend 24 -1 4 17 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typmodin 24 -1 4 18 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typmodout 24 -1 4 19 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typanalyze 24 -1 4 20 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typalign 18 -1 1 21 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typstorage 18 -1 1 22 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typnotnull 16 -1 1 23 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typbasetype 26 -1 4 24 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typtypmod 23 -1 4 25 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typndims 23 -1 4 26 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typcollation 26 -1 4 27 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 typdefaultbin 194 -1 -1 28 0 -1 -1 f x i f f f t 0 100 _null_ _null_ _null_) +insert ( 1247 typdefault 25 -1 -1 29 0 -1 -1 f x i f f f t 0 100 _null_ _null_ _null_) +insert ( 1247 typacl 1034 -1 -1 30 1 -1 -1 f x i f f f t 0 0 _null_ _null_ _null_) +insert ( 1247 ctid 27 0 6 -1 0 -1 -1 f p s t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 oid 26 0 4 -2 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 xmin 28 0 4 -3 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 cmin 29 0 4 -4 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 xmax 28 0 4 -5 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 cmax 29 0 4 -6 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1247 tableoid 26 0 4 -7 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1249 attrelid 26 -1 4 1 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1249 attname 19 -1 NAMEDATALEN 2 0 -1 -1 f p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1249 atttypid 26 -1 4 3 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1249 attstattarget 23 -1 4 4 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1249 attlen 21 -1 2 5 0 -1 -1 t p s t f f t 0 0 _null_ _null_ _null_) +insert ( 1249 attnum 21 -1 2 6 0 -1 -1 t p s t f f t 0 0 _null_ _null_ _null_) +insert ( 1249 attndims 23 -1 4 7 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1249 attcacheoff 23 -1 4 8 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1249 atttypmod 23 -1 4 9 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1249 attbyval 16 -1 1 10 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1249 attstorage 18 -1 1 11 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1249 attalign 18 -1 1 12 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1249 attnotnull 16 -1 1 13 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1249 atthasdef 16 -1 1 14 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1249 attisdropped 16 -1 1 15 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1249 attislocal 16 -1 1 16 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1249 attinhcount 23 -1 4 17 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1249 attcollation 26 -1 4 18 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1249 attacl 1034 -1 -1 19 1 -1 -1 f x i f f f t 0 0 _null_ _null_ _null_) +insert ( 1249 attoptions 1009 -1 -1 20 1 -1 -1 f x i f f f t 0 100 _null_ _null_ _null_) +insert ( 1249 attfdwoptions 1009 -1 -1 21 1 -1 -1 f x i f f f t 0 100 _null_ _null_ _null_) +insert ( 1249 ctid 27 0 6 -1 0 -1 -1 f p s t f f t 0 0 _null_ _null_ _null_) +insert ( 1249 xmin 28 0 4 -3 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1249 cmin 29 0 4 -4 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1249 xmax 28 0 4 -5 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1249 cmax 29 0 4 -6 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1249 tableoid 26 0 4 -7 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 relname 19 -1 NAMEDATALEN 1 0 -1 -1 f p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 relnamespace 26 -1 4 2 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 reltype 26 -1 4 3 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 reloftype 26 -1 4 4 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 relowner 26 -1 4 5 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 relam 26 -1 4 6 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 relfilenode 26 -1 4 7 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 reltablespace 26 -1 4 8 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 relpages 23 -1 4 9 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 reltuples 700 -1 4 10 0 -1 -1 FLOAT4PASSBYVAL p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 relallvisible 23 -1 4 11 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 reltoastrelid 26 -1 4 12 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 reltoastidxid 26 -1 4 13 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 relhasindex 16 -1 1 14 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 relisshared 16 -1 1 15 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 relpersistence 18 -1 1 16 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 relkind 18 -1 1 17 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 relnatts 21 -1 2 18 0 -1 -1 t p s t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 relchecks 21 -1 2 19 0 -1 -1 t p s t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 relhasoids 16 -1 1 20 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 relhaspkey 16 -1 1 21 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 relhasrules 16 -1 1 22 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 relhastriggers 16 -1 1 23 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 relhassubclass 16 -1 1 24 0 -1 -1 t p c t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 relfrozenxid 28 -1 4 25 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 relacl 1034 -1 -1 26 1 -1 -1 f x i f f f t 0 0 _null_ _null_ _null_) +insert ( 1259 reloptions 1009 -1 -1 27 1 -1 -1 f x i f f f t 0 100 _null_ _null_ _null_) +insert ( 1259 ctid 27 0 6 -1 0 -1 -1 f p s t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 oid 26 0 4 -2 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 xmin 28 0 4 -3 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 cmin 29 0 4 -4 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 xmax 28 0 4 -5 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 cmax 29 0 4 -6 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +insert ( 1259 tableoid 26 0 4 -7 0 -1 -1 t p i t f f t 0 0 _null_ _null_ _null_) +close pg_attribute +create pg_class 1259 bootstrap rowtype_oid 83 + ( + relname = name , + relnamespace = oid , + reltype = oid , + reloftype = oid , + relowner = oid , + relam = oid , + relfilenode = oid , + reltablespace = oid , + relpages = int4 , + reltuples = float4 , + relallvisible = int4 , + reltoastrelid = oid , + reltoastidxid = oid , + relhasindex = bool , + relisshared = bool , + relpersistence = char , + relkind = char , + relnatts = int2 , + relchecks = int2 , + relhasoids = bool , + relhaspkey = bool , + relhasrules = bool , + relhastriggers = bool , + relhassubclass = bool , + relfrozenxid = xid , + relacl = aclitem[] , + reloptions = text[] + ) +insert OID = 1247 ( pg_type 11 71 0 10 0 0 0 0 0 0 0 0 f f p r 30 0 t f f f f 3 _null_ _null_ ) +insert OID = 1249 ( pg_attribute 11 75 0 10 0 0 0 0 0 0 0 0 f f p r 21 0 f f f f f 3 _null_ _null_ ) +insert OID = 1255 ( pg_proc 11 81 0 10 0 0 0 0 0 0 0 0 f f p r 27 0 t f f f f 3 _null_ _null_ ) +insert OID = 1259 ( pg_class 11 83 0 10 0 0 0 0 0 0 0 0 f f p r 27 0 t f f f f 3 _null_ _null_ ) +close pg_class +create pg_attrdef 2604 + ( + adrelid = oid , + adnum = int2 , + adbin = pg_node_tree , + adsrc = text + ) +open pg_attrdef +close pg_attrdef +create pg_constraint 2606 + ( + conname = name , + connamespace = oid , + contype = char , + condeferrable = bool , + condeferred = bool , + convalidated = bool , + conrelid = oid , + contypid = oid , + conindid = oid , + confrelid = oid , + confupdtype = char , + confdeltype = char , + confmatchtype = char , + conislocal = bool , + coninhcount = int4 , + connoinherit = bool , + conkey = int2[] , + confkey = int2[] , + conpfeqop = oid[] , + conppeqop = oid[] , + conffeqop = oid[] , + conexclop = oid[] , + conbin = pg_node_tree , + consrc = text + ) +open pg_constraint +close pg_constraint +create pg_inherits 2611 without_oids + ( + inhrelid = oid , + inhparent = oid , + inhseqno = int4 + ) +open pg_inherits +close pg_inherits +create pg_index 2610 without_oids + ( + indexrelid = oid , + indrelid = oid , + indnatts = int2 , + indisunique = bool , + indisprimary = bool , + indisexclusion = bool , + indimmediate = bool , + indisclustered = bool , + indisvalid = bool , + indcheckxmin = bool , + indisready = bool , + indkey = int2vector , + indcollation = oidvector , + indclass = oidvector , + indoption = int2vector , + indexprs = pg_node_tree , + indpred = pg_node_tree + ) +open pg_index +close pg_index +create pg_operator 2617 + ( + oprname = name , + oprnamespace = oid , + oprowner = oid , + oprkind = char , + oprcanmerge = bool , + oprcanhash = bool , + oprleft = oid , + oprright = oid , + oprresult = oid , + oprcom = oid , + oprnegate = oid , + oprcode = regproc , + oprrest = regproc , + oprjoin = regproc + ) +open pg_operator +insert OID = 15 ( "=" 11 10 b t t 23 20 16 416 36 int48eq eqsel eqjoinsel ) +insert OID = 36 ( "<>" 11 10 b f f 23 20 16 417 15 int48ne neqsel neqjoinsel ) +insert OID = 37 ( "<" 11 10 b f f 23 20 16 419 82 int48lt scalarltsel scalarltjoinsel ) +insert OID = 76 ( ">" 11 10 b f f 23 20 16 418 80 int48gt scalargtsel scalargtjoinsel ) +insert OID = 80 ( "<=" 11 10 b f f 23 20 16 430 76 int48le scalarltsel scalarltjoinsel ) +insert OID = 82 ( ">=" 11 10 b f f 23 20 16 420 37 int48ge scalargtsel scalargtjoinsel ) +insert OID = 58 ( "<" 11 10 b f f 16 16 16 59 1695 boollt scalarltsel scalarltjoinsel ) +insert OID = 59 ( ">" 11 10 b f f 16 16 16 58 1694 boolgt scalargtsel scalargtjoinsel ) +insert OID = 85 ( "<>" 11 10 b f f 16 16 16 85 91 boolne neqsel neqjoinsel ) +insert OID = 91 ( "=" 11 10 b t t 16 16 16 91 85 booleq eqsel eqjoinsel ) +insert OID = 1694 ( "<=" 11 10 b f f 16 16 16 1695 59 boolle scalarltsel scalarltjoinsel ) +insert OID = 1695 ( ">=" 11 10 b f f 16 16 16 1694 58 boolge scalargtsel scalargtjoinsel ) +insert OID = 92 ( "=" 11 10 b t t 18 18 16 92 630 chareq eqsel eqjoinsel ) +insert OID = 93 ( "=" 11 10 b t t 19 19 16 93 643 nameeq eqsel eqjoinsel ) +insert OID = 94 ( "=" 11 10 b t t 21 21 16 94 519 int2eq eqsel eqjoinsel ) +insert OID = 95 ( "<" 11 10 b f f 21 21 16 520 524 int2lt scalarltsel scalarltjoinsel ) +insert OID = 96 ( "=" 11 10 b t t 23 23 16 96 518 int4eq eqsel eqjoinsel ) +insert OID = 97 ( "<" 11 10 b f f 23 23 16 521 525 int4lt scalarltsel scalarltjoinsel ) +insert OID = 98 ( "=" 11 10 b t t 25 25 16 98 531 texteq eqsel eqjoinsel ) +insert OID = 349 ( "||" 11 10 b f f 2277 2283 2277 0 0 array_append - - ) +insert OID = 374 ( "||" 11 10 b f f 2283 2277 2277 0 0 array_prepend - - ) +insert OID = 375 ( "||" 11 10 b f f 2277 2277 2277 0 0 array_cat - - ) +insert OID = 352 ( "=" 11 10 b f t 28 28 16 352 0 xideq eqsel eqjoinsel ) +insert OID = 353 ( "=" 11 10 b f f 28 23 16 0 0 xideqint4 eqsel eqjoinsel ) +insert OID = 388 ( "!" 11 10 r f f 20 0 1700 0 0 numeric_fac - - ) +insert OID = 389 ( "!!" 11 10 l f f 0 20 1700 0 0 numeric_fac - - ) +insert OID = 385 ( "=" 11 10 b f t 29 29 16 385 0 cideq eqsel eqjoinsel ) +insert OID = 386 ( "=" 11 10 b f t 22 22 16 386 0 int2vectoreq eqsel eqjoinsel ) +insert OID = 387 ( "=" 11 10 b t f 27 27 16 387 402 tideq eqsel eqjoinsel ) +insert OID = 402 ( "<>" 11 10 b f f 27 27 16 402 387 tidne neqsel neqjoinsel ) +insert OID = 2799 ( "<" 11 10 b f f 27 27 16 2800 2802 tidlt scalarltsel scalarltjoinsel ) +insert OID = 2800 ( ">" 11 10 b f f 27 27 16 2799 2801 tidgt scalargtsel scalargtjoinsel ) +insert OID = 2801 ( "<=" 11 10 b f f 27 27 16 2802 2800 tidle scalarltsel scalarltjoinsel ) +insert OID = 2802 ( ">=" 11 10 b f f 27 27 16 2801 2799 tidge scalargtsel scalargtjoinsel ) +insert OID = 410 ( "=" 11 10 b t t 20 20 16 410 411 int8eq eqsel eqjoinsel ) +insert OID = 411 ( "<>" 11 10 b f f 20 20 16 411 410 int8ne neqsel neqjoinsel ) +insert OID = 412 ( "<" 11 10 b f f 20 20 16 413 415 int8lt scalarltsel scalarltjoinsel ) +insert OID = 413 ( ">" 11 10 b f f 20 20 16 412 414 int8gt scalargtsel scalargtjoinsel ) +insert OID = 414 ( "<=" 11 10 b f f 20 20 16 415 413 int8le scalarltsel scalarltjoinsel ) +insert OID = 415 ( ">=" 11 10 b f f 20 20 16 414 412 int8ge scalargtsel scalargtjoinsel ) +insert OID = 416 ( "=" 11 10 b t t 20 23 16 15 417 int84eq eqsel eqjoinsel ) +insert OID = 417 ( "<>" 11 10 b f f 20 23 16 36 416 int84ne neqsel neqjoinsel ) +insert OID = 418 ( "<" 11 10 b f f 20 23 16 76 430 int84lt scalarltsel scalarltjoinsel ) +insert OID = 419 ( ">" 11 10 b f f 20 23 16 37 420 int84gt scalargtsel scalargtjoinsel ) +insert OID = 420 ( "<=" 11 10 b f f 20 23 16 82 419 int84le scalarltsel scalarltjoinsel ) +insert OID = 430 ( ">=" 11 10 b f f 20 23 16 80 418 int84ge scalargtsel scalargtjoinsel ) +insert OID = 439 ( "%" 11 10 b f f 20 20 20 0 0 int8mod - - ) +insert OID = 473 ( "@" 11 10 l f f 0 20 20 0 0 int8abs - - ) +insert OID = 484 ( "-" 11 10 l f f 0 20 20 0 0 int8um - - ) +insert OID = 485 ( "<<" 11 10 b f f 604 604 16 0 0 poly_left positionsel positionjoinsel ) +insert OID = 486 ( "&<" 11 10 b f f 604 604 16 0 0 poly_overleft positionsel positionjoinsel ) +insert OID = 487 ( "&>" 11 10 b f f 604 604 16 0 0 poly_overright positionsel positionjoinsel ) +insert OID = 488 ( ">>" 11 10 b f f 604 604 16 0 0 poly_right positionsel positionjoinsel ) +insert OID = 489 ( "<@" 11 10 b f f 604 604 16 490 0 poly_contained contsel contjoinsel ) +insert OID = 490 ( "@>" 11 10 b f f 604 604 16 489 0 poly_contain contsel contjoinsel ) +insert OID = 491 ( "~=" 11 10 b f f 604 604 16 491 0 poly_same eqsel eqjoinsel ) +insert OID = 492 ( "&&" 11 10 b f f 604 604 16 492 0 poly_overlap areasel areajoinsel ) +insert OID = 493 ( "<<" 11 10 b f f 603 603 16 0 0 box_left positionsel positionjoinsel ) +insert OID = 494 ( "&<" 11 10 b f f 603 603 16 0 0 box_overleft positionsel positionjoinsel ) +insert OID = 495 ( "&>" 11 10 b f f 603 603 16 0 0 box_overright positionsel positionjoinsel ) +insert OID = 496 ( ">>" 11 10 b f f 603 603 16 0 0 box_right positionsel positionjoinsel ) +insert OID = 497 ( "<@" 11 10 b f f 603 603 16 498 0 box_contained contsel contjoinsel ) +insert OID = 498 ( "@>" 11 10 b f f 603 603 16 497 0 box_contain contsel contjoinsel ) +insert OID = 499 ( "~=" 11 10 b f f 603 603 16 499 0 box_same eqsel eqjoinsel ) +insert OID = 500 ( "&&" 11 10 b f f 603 603 16 500 0 box_overlap areasel areajoinsel ) +insert OID = 501 ( ">=" 11 10 b f f 603 603 16 505 504 box_ge areasel areajoinsel ) +insert OID = 502 ( ">" 11 10 b f f 603 603 16 504 505 box_gt areasel areajoinsel ) +insert OID = 503 ( "=" 11 10 b f f 603 603 16 503 0 box_eq eqsel eqjoinsel ) +insert OID = 504 ( "<" 11 10 b f f 603 603 16 502 501 box_lt areasel areajoinsel ) +insert OID = 505 ( "<=" 11 10 b f f 603 603 16 501 502 box_le areasel areajoinsel ) +insert OID = 506 ( ">^" 11 10 b f f 600 600 16 0 0 point_above positionsel positionjoinsel ) +insert OID = 507 ( "<<" 11 10 b f f 600 600 16 0 0 point_left positionsel positionjoinsel ) +insert OID = 508 ( ">>" 11 10 b f f 600 600 16 0 0 point_right positionsel positionjoinsel ) +insert OID = 509 ( "<^" 11 10 b f f 600 600 16 0 0 point_below positionsel positionjoinsel ) +insert OID = 510 ( "~=" 11 10 b f f 600 600 16 510 713 point_eq eqsel eqjoinsel ) +insert OID = 511 ( "<@" 11 10 b f f 600 603 16 433 0 on_pb contsel contjoinsel ) +insert OID = 433 ( "@>" 11 10 b f f 603 600 16 511 0 box_contain_pt contsel contjoinsel ) +insert OID = 512 ( "<@" 11 10 b f f 600 602 16 755 0 on_ppath - - ) +insert OID = 513 ( "@@" 11 10 l f f 0 603 600 0 0 box_center - - ) +insert OID = 514 ( "*" 11 10 b f f 23 23 23 514 0 int4mul - - ) +insert OID = 517 ( "<->" 11 10 b f f 600 600 701 517 0 point_distance - - ) +insert OID = 518 ( "<>" 11 10 b f f 23 23 16 518 96 int4ne neqsel neqjoinsel ) +insert OID = 519 ( "<>" 11 10 b f f 21 21 16 519 94 int2ne neqsel neqjoinsel ) +insert OID = 520 ( ">" 11 10 b f f 21 21 16 95 522 int2gt scalargtsel scalargtjoinsel ) +insert OID = 521 ( ">" 11 10 b f f 23 23 16 97 523 int4gt scalargtsel scalargtjoinsel ) +insert OID = 522 ( "<=" 11 10 b f f 21 21 16 524 520 int2le scalarltsel scalarltjoinsel ) +insert OID = 523 ( "<=" 11 10 b f f 23 23 16 525 521 int4le scalarltsel scalarltjoinsel ) +insert OID = 524 ( ">=" 11 10 b f f 21 21 16 522 95 int2ge scalargtsel scalargtjoinsel ) +insert OID = 525 ( ">=" 11 10 b f f 23 23 16 523 97 int4ge scalargtsel scalargtjoinsel ) +insert OID = 526 ( "*" 11 10 b f f 21 21 21 526 0 int2mul - - ) +insert OID = 527 ( "/" 11 10 b f f 21 21 21 0 0 int2div - - ) +insert OID = 528 ( "/" 11 10 b f f 23 23 23 0 0 int4div - - ) +insert OID = 529 ( "%" 11 10 b f f 21 21 21 0 0 int2mod - - ) +insert OID = 530 ( "%" 11 10 b f f 23 23 23 0 0 int4mod - - ) +insert OID = 531 ( "<>" 11 10 b f f 25 25 16 531 98 textne neqsel neqjoinsel ) +insert OID = 532 ( "=" 11 10 b t t 21 23 16 533 538 int24eq eqsel eqjoinsel ) +insert OID = 533 ( "=" 11 10 b t t 23 21 16 532 539 int42eq eqsel eqjoinsel ) +insert OID = 534 ( "<" 11 10 b f f 21 23 16 537 542 int24lt scalarltsel scalarltjoinsel ) +insert OID = 535 ( "<" 11 10 b f f 23 21 16 536 543 int42lt scalarltsel scalarltjoinsel ) +insert OID = 536 ( ">" 11 10 b f f 21 23 16 535 540 int24gt scalargtsel scalargtjoinsel ) +insert OID = 537 ( ">" 11 10 b f f 23 21 16 534 541 int42gt scalargtsel scalargtjoinsel ) +insert OID = 538 ( "<>" 11 10 b f f 21 23 16 539 532 int24ne neqsel neqjoinsel ) +insert OID = 539 ( "<>" 11 10 b f f 23 21 16 538 533 int42ne neqsel neqjoinsel ) +insert OID = 540 ( "<=" 11 10 b f f 21 23 16 543 536 int24le scalarltsel scalarltjoinsel ) +insert OID = 541 ( "<=" 11 10 b f f 23 21 16 542 537 int42le scalarltsel scalarltjoinsel ) +insert OID = 542 ( ">=" 11 10 b f f 21 23 16 541 534 int24ge scalargtsel scalargtjoinsel ) +insert OID = 543 ( ">=" 11 10 b f f 23 21 16 540 535 int42ge scalargtsel scalargtjoinsel ) +insert OID = 544 ( "*" 11 10 b f f 21 23 23 545 0 int24mul - - ) +insert OID = 545 ( "*" 11 10 b f f 23 21 23 544 0 int42mul - - ) +insert OID = 546 ( "/" 11 10 b f f 21 23 23 0 0 int24div - - ) +insert OID = 547 ( "/" 11 10 b f f 23 21 23 0 0 int42div - - ) +insert OID = 550 ( "+" 11 10 b f f 21 21 21 550 0 int2pl - - ) +insert OID = 551 ( "+" 11 10 b f f 23 23 23 551 0 int4pl - - ) +insert OID = 552 ( "+" 11 10 b f f 21 23 23 553 0 int24pl - - ) +insert OID = 553 ( "+" 11 10 b f f 23 21 23 552 0 int42pl - - ) +insert OID = 554 ( "-" 11 10 b f f 21 21 21 0 0 int2mi - - ) +insert OID = 555 ( "-" 11 10 b f f 23 23 23 0 0 int4mi - - ) +insert OID = 556 ( "-" 11 10 b f f 21 23 23 0 0 int24mi - - ) +insert OID = 557 ( "-" 11 10 b f f 23 21 23 0 0 int42mi - - ) +insert OID = 558 ( "-" 11 10 l f f 0 23 23 0 0 int4um - - ) +insert OID = 559 ( "-" 11 10 l f f 0 21 21 0 0 int2um - - ) +insert OID = 560 ( "=" 11 10 b t t 702 702 16 560 561 abstimeeq eqsel eqjoinsel ) +insert OID = 561 ( "<>" 11 10 b f f 702 702 16 561 560 abstimene neqsel neqjoinsel ) +insert OID = 562 ( "<" 11 10 b f f 702 702 16 563 565 abstimelt scalarltsel scalarltjoinsel ) +insert OID = 563 ( ">" 11 10 b f f 702 702 16 562 564 abstimegt scalargtsel scalargtjoinsel ) +insert OID = 564 ( "<=" 11 10 b f f 702 702 16 565 563 abstimele scalarltsel scalarltjoinsel ) +insert OID = 565 ( ">=" 11 10 b f f 702 702 16 564 562 abstimege scalargtsel scalargtjoinsel ) +insert OID = 566 ( "=" 11 10 b t t 703 703 16 566 567 reltimeeq eqsel eqjoinsel ) +insert OID = 567 ( "<>" 11 10 b f f 703 703 16 567 566 reltimene neqsel neqjoinsel ) +insert OID = 568 ( "<" 11 10 b f f 703 703 16 569 571 reltimelt scalarltsel scalarltjoinsel ) +insert OID = 569 ( ">" 11 10 b f f 703 703 16 568 570 reltimegt scalargtsel scalargtjoinsel ) +insert OID = 570 ( "<=" 11 10 b f f 703 703 16 571 569 reltimele scalarltsel scalarltjoinsel ) +insert OID = 571 ( ">=" 11 10 b f f 703 703 16 570 568 reltimege scalargtsel scalargtjoinsel ) +insert OID = 572 ( "~=" 11 10 b f f 704 704 16 572 0 tintervalsame eqsel eqjoinsel ) +insert OID = 573 ( "<<" 11 10 b f f 704 704 16 0 0 tintervalct - - ) +insert OID = 574 ( "&&" 11 10 b f f 704 704 16 574 0 tintervalov - - ) +insert OID = 575 ( "#=" 11 10 b f f 704 703 16 0 576 tintervalleneq - - ) +insert OID = 576 ( "#<>" 11 10 b f f 704 703 16 0 575 tintervallenne - - ) +insert OID = 577 ( "#<" 11 10 b f f 704 703 16 0 580 tintervallenlt - - ) +insert OID = 578 ( "#>" 11 10 b f f 704 703 16 0 579 tintervallengt - - ) +insert OID = 579 ( "#<=" 11 10 b f f 704 703 16 0 578 tintervallenle - - ) +insert OID = 580 ( "#>=" 11 10 b f f 704 703 16 0 577 tintervallenge - - ) +insert OID = 581 ( "+" 11 10 b f f 702 703 702 0 0 timepl - - ) +insert OID = 582 ( "-" 11 10 b f f 702 703 702 0 0 timemi - - ) +insert OID = 583 ( "" 11 10 b f f 702 704 16 0 0 intinterval - - ) +insert OID = 584 ( "-" 11 10 l f f 0 700 700 0 0 float4um - - ) +insert OID = 585 ( "-" 11 10 l f f 0 701 701 0 0 float8um - - ) +insert OID = 586 ( "+" 11 10 b f f 700 700 700 586 0 float4pl - - ) +insert OID = 587 ( "-" 11 10 b f f 700 700 700 0 0 float4mi - - ) +insert OID = 588 ( "/" 11 10 b f f 700 700 700 0 0 float4div - - ) +insert OID = 589 ( "*" 11 10 b f f 700 700 700 589 0 float4mul - - ) +insert OID = 590 ( "@" 11 10 l f f 0 700 700 0 0 float4abs - - ) +insert OID = 591 ( "+" 11 10 b f f 701 701 701 591 0 float8pl - - ) +insert OID = 592 ( "-" 11 10 b f f 701 701 701 0 0 float8mi - - ) +insert OID = 593 ( "/" 11 10 b f f 701 701 701 0 0 float8div - - ) +insert OID = 594 ( "*" 11 10 b f f 701 701 701 594 0 float8mul - - ) +insert OID = 595 ( "@" 11 10 l f f 0 701 701 0 0 float8abs - - ) +insert OID = 596 ( "|/" 11 10 l f f 0 701 701 0 0 dsqrt - - ) +insert OID = 597 ( "||/" 11 10 l f f 0 701 701 0 0 dcbrt - - ) +insert OID = 1284 ( "|" 11 10 l f f 0 704 702 0 0 tintervalstart - - ) +insert OID = 606 ( "<#>" 11 10 b f f 702 702 704 0 0 mktinterval - - ) +insert OID = 607 ( "=" 11 10 b t t 26 26 16 607 608 oideq eqsel eqjoinsel ) +insert OID = 608 ( "<>" 11 10 b f f 26 26 16 608 607 oidne neqsel neqjoinsel ) +insert OID = 609 ( "<" 11 10 b f f 26 26 16 610 612 oidlt scalarltsel scalarltjoinsel ) +insert OID = 610 ( ">" 11 10 b f f 26 26 16 609 611 oidgt scalargtsel scalargtjoinsel ) +insert OID = 611 ( "<=" 11 10 b f f 26 26 16 612 610 oidle scalarltsel scalarltjoinsel ) +insert OID = 612 ( ">=" 11 10 b f f 26 26 16 611 609 oidge scalargtsel scalargtjoinsel ) +insert OID = 644 ( "<>" 11 10 b f f 30 30 16 644 649 oidvectorne neqsel neqjoinsel ) +insert OID = 645 ( "<" 11 10 b f f 30 30 16 646 648 oidvectorlt scalarltsel scalarltjoinsel ) +insert OID = 646 ( ">" 11 10 b f f 30 30 16 645 647 oidvectorgt scalargtsel scalargtjoinsel ) +insert OID = 647 ( "<=" 11 10 b f f 30 30 16 648 646 oidvectorle scalarltsel scalarltjoinsel ) +insert OID = 648 ( ">=" 11 10 b f f 30 30 16 647 645 oidvectorge scalargtsel scalargtjoinsel ) +insert OID = 649 ( "=" 11 10 b t t 30 30 16 649 644 oidvectoreq eqsel eqjoinsel ) +insert OID = 613 ( "<->" 11 10 b f f 600 628 701 0 0 dist_pl - - ) +insert OID = 614 ( "<->" 11 10 b f f 600 601 701 0 0 dist_ps - - ) +insert OID = 615 ( "<->" 11 10 b f f 600 603 701 0 0 dist_pb - - ) +insert OID = 616 ( "<->" 11 10 b f f 601 628 701 0 0 dist_sl - - ) +insert OID = 617 ( "<->" 11 10 b f f 601 603 701 0 0 dist_sb - - ) +insert OID = 618 ( "<->" 11 10 b f f 600 602 701 0 0 dist_ppath - - ) +insert OID = 620 ( "=" 11 10 b t t 700 700 16 620 621 float4eq eqsel eqjoinsel ) +insert OID = 621 ( "<>" 11 10 b f f 700 700 16 621 620 float4ne neqsel neqjoinsel ) +insert OID = 622 ( "<" 11 10 b f f 700 700 16 623 625 float4lt scalarltsel scalarltjoinsel ) +insert OID = 623 ( ">" 11 10 b f f 700 700 16 622 624 float4gt scalargtsel scalargtjoinsel ) +insert OID = 624 ( "<=" 11 10 b f f 700 700 16 625 623 float4le scalarltsel scalarltjoinsel ) +insert OID = 625 ( ">=" 11 10 b f f 700 700 16 624 622 float4ge scalargtsel scalargtjoinsel ) +insert OID = 630 ( "<>" 11 10 b f f 18 18 16 630 92 charne neqsel neqjoinsel ) +insert OID = 631 ( "<" 11 10 b f f 18 18 16 633 634 charlt scalarltsel scalarltjoinsel ) +insert OID = 632 ( "<=" 11 10 b f f 18 18 16 634 633 charle scalarltsel scalarltjoinsel ) +insert OID = 633 ( ">" 11 10 b f f 18 18 16 631 632 chargt scalargtsel scalargtjoinsel ) +insert OID = 634 ( ">=" 11 10 b f f 18 18 16 632 631 charge scalargtsel scalargtjoinsel ) +insert OID = 639 ( "~" 11 10 b f f 19 25 16 0 640 nameregexeq regexeqsel regexeqjoinsel ) +insert OID = 640 ( "!~" 11 10 b f f 19 25 16 0 639 nameregexne regexnesel regexnejoinsel ) +insert OID = 641 ( "~" 11 10 b f f 25 25 16 0 642 textregexeq regexeqsel regexeqjoinsel ) +insert OID = 642 ( "!~" 11 10 b f f 25 25 16 0 641 textregexne regexnesel regexnejoinsel ) +insert OID = 643 ( "<>" 11 10 b f f 19 19 16 643 93 namene neqsel neqjoinsel ) +insert OID = 654 ( "||" 11 10 b f f 25 25 25 0 0 textcat - - ) +insert OID = 660 ( "<" 11 10 b f f 19 19 16 662 663 namelt scalarltsel scalarltjoinsel ) +insert OID = 661 ( "<=" 11 10 b f f 19 19 16 663 662 namele scalarltsel scalarltjoinsel ) +insert OID = 662 ( ">" 11 10 b f f 19 19 16 660 661 namegt scalargtsel scalargtjoinsel ) +insert OID = 663 ( ">=" 11 10 b f f 19 19 16 661 660 namege scalargtsel scalargtjoinsel ) +insert OID = 664 ( "<" 11 10 b f f 25 25 16 666 667 text_lt scalarltsel scalarltjoinsel ) +insert OID = 665 ( "<=" 11 10 b f f 25 25 16 667 666 text_le scalarltsel scalarltjoinsel ) +insert OID = 666 ( ">" 11 10 b f f 25 25 16 664 665 text_gt scalargtsel scalargtjoinsel ) +insert OID = 667 ( ">=" 11 10 b f f 25 25 16 665 664 text_ge scalargtsel scalargtjoinsel ) +insert OID = 670 ( "=" 11 10 b t t 701 701 16 670 671 float8eq eqsel eqjoinsel ) +insert OID = 671 ( "<>" 11 10 b f f 701 701 16 671 670 float8ne neqsel neqjoinsel ) +insert OID = 672 ( "<" 11 10 b f f 701 701 16 674 675 float8lt scalarltsel scalarltjoinsel ) +insert OID = 673 ( "<=" 11 10 b f f 701 701 16 675 674 float8le scalarltsel scalarltjoinsel ) +insert OID = 674 ( ">" 11 10 b f f 701 701 16 672 673 float8gt scalargtsel scalargtjoinsel ) +insert OID = 675 ( ">=" 11 10 b f f 701 701 16 673 672 float8ge scalargtsel scalargtjoinsel ) +insert OID = 682 ( "@" 11 10 l f f 0 21 21 0 0 int2abs - - ) +insert OID = 684 ( "+" 11 10 b f f 20 20 20 684 0 int8pl - - ) +insert OID = 685 ( "-" 11 10 b f f 20 20 20 0 0 int8mi - - ) +insert OID = 686 ( "*" 11 10 b f f 20 20 20 686 0 int8mul - - ) +insert OID = 687 ( "/" 11 10 b f f 20 20 20 0 0 int8div - - ) +insert OID = 688 ( "+" 11 10 b f f 20 23 20 692 0 int84pl - - ) +insert OID = 689 ( "-" 11 10 b f f 20 23 20 0 0 int84mi - - ) +insert OID = 690 ( "*" 11 10 b f f 20 23 20 694 0 int84mul - - ) +insert OID = 691 ( "/" 11 10 b f f 20 23 20 0 0 int84div - - ) +insert OID = 692 ( "+" 11 10 b f f 23 20 20 688 0 int48pl - - ) +insert OID = 693 ( "-" 11 10 b f f 23 20 20 0 0 int48mi - - ) +insert OID = 694 ( "*" 11 10 b f f 23 20 20 690 0 int48mul - - ) +insert OID = 695 ( "/" 11 10 b f f 23 20 20 0 0 int48div - - ) +insert OID = 818 ( "+" 11 10 b f f 20 21 20 822 0 int82pl - - ) +insert OID = 819 ( "-" 11 10 b f f 20 21 20 0 0 int82mi - - ) +insert OID = 820 ( "*" 11 10 b f f 20 21 20 824 0 int82mul - - ) +insert OID = 821 ( "/" 11 10 b f f 20 21 20 0 0 int82div - - ) +insert OID = 822 ( "+" 11 10 b f f 21 20 20 818 0 int28pl - - ) +insert OID = 823 ( "-" 11 10 b f f 21 20 20 0 0 int28mi - - ) +insert OID = 824 ( "*" 11 10 b f f 21 20 20 820 0 int28mul - - ) +insert OID = 825 ( "/" 11 10 b f f 21 20 20 0 0 int28div - - ) +insert OID = 706 ( "<->" 11 10 b f f 603 603 701 706 0 box_distance - - ) +insert OID = 707 ( "<->" 11 10 b f f 602 602 701 707 0 path_distance - - ) +insert OID = 708 ( "<->" 11 10 b f f 628 628 701 708 0 line_distance - - ) +insert OID = 709 ( "<->" 11 10 b f f 601 601 701 709 0 lseg_distance - - ) +insert OID = 712 ( "<->" 11 10 b f f 604 604 701 712 0 poly_distance - - ) +insert OID = 713 ( "<>" 11 10 b f f 600 600 16 713 510 point_ne neqsel neqjoinsel ) +insert OID = 731 ( "+" 11 10 b f f 600 600 600 731 0 point_add - - ) +insert OID = 732 ( "-" 11 10 b f f 600 600 600 0 0 point_sub - - ) +insert OID = 733 ( "*" 11 10 b f f 600 600 600 733 0 point_mul - - ) +insert OID = 734 ( "/" 11 10 b f f 600 600 600 0 0 point_div - - ) +insert OID = 735 ( "+" 11 10 b f f 602 602 602 735 0 path_add - - ) +insert OID = 736 ( "+" 11 10 b f f 602 600 602 0 0 path_add_pt - - ) +insert OID = 737 ( "-" 11 10 b f f 602 600 602 0 0 path_sub_pt - - ) +insert OID = 738 ( "*" 11 10 b f f 602 600 602 0 0 path_mul_pt - - ) +insert OID = 739 ( "/" 11 10 b f f 602 600 602 0 0 path_div_pt - - ) +insert OID = 755 ( "@>" 11 10 b f f 602 600 16 512 0 path_contain_pt - - ) +insert OID = 756 ( "<@" 11 10 b f f 600 604 16 757 0 pt_contained_poly contsel contjoinsel ) +insert OID = 757 ( "@>" 11 10 b f f 604 600 16 756 0 poly_contain_pt contsel contjoinsel ) +insert OID = 758 ( "<@" 11 10 b f f 600 718 16 759 0 pt_contained_circle contsel contjoinsel ) +insert OID = 759 ( "@>" 11 10 b f f 718 600 16 758 0 circle_contain_pt contsel contjoinsel ) +insert OID = 773 ( "@" 11 10 l f f 0 23 23 0 0 int4abs - - ) +insert OID = 792 ( "=" 11 10 b f f 602 602 16 792 0 path_n_eq eqsel eqjoinsel ) +insert OID = 793 ( "<" 11 10 b f f 602 602 16 794 0 path_n_lt - - ) +insert OID = 794 ( ">" 11 10 b f f 602 602 16 793 0 path_n_gt - - ) +insert OID = 795 ( "<=" 11 10 b f f 602 602 16 796 0 path_n_le - - ) +insert OID = 796 ( ">=" 11 10 b f f 602 602 16 795 0 path_n_ge - - ) +insert OID = 797 ( "#" 11 10 l f f 0 602 23 0 0 path_npoints - - ) +insert OID = 798 ( "?#" 11 10 b f f 602 602 16 0 0 path_inter - - ) +insert OID = 799 ( "@-@" 11 10 l f f 0 602 701 0 0 path_length - - ) +insert OID = 800 ( ">^" 11 10 b f f 603 603 16 0 0 box_above_eq positionsel positionjoinsel ) +insert OID = 801 ( "<^" 11 10 b f f 603 603 16 0 0 box_below_eq positionsel positionjoinsel ) +insert OID = 802 ( "?#" 11 10 b f f 603 603 16 0 0 box_overlap areasel areajoinsel ) +insert OID = 803 ( "#" 11 10 b f f 603 603 603 0 0 box_intersect - - ) +insert OID = 804 ( "+" 11 10 b f f 603 600 603 0 0 box_add - - ) +insert OID = 805 ( "-" 11 10 b f f 603 600 603 0 0 box_sub - - ) +insert OID = 806 ( "*" 11 10 b f f 603 600 603 0 0 box_mul - - ) +insert OID = 807 ( "/" 11 10 b f f 603 600 603 0 0 box_div - - ) +insert OID = 808 ( "?-" 11 10 b f f 600 600 16 808 0 point_horiz - - ) +insert OID = 809 ( "?|" 11 10 b f f 600 600 16 809 0 point_vert - - ) +insert OID = 811 ( "=" 11 10 b t f 704 704 16 811 812 tintervaleq eqsel eqjoinsel ) +insert OID = 812 ( "<>" 11 10 b f f 704 704 16 812 811 tintervalne neqsel neqjoinsel ) +insert OID = 813 ( "<" 11 10 b f f 704 704 16 814 816 tintervallt scalarltsel scalarltjoinsel ) +insert OID = 814 ( ">" 11 10 b f f 704 704 16 813 815 tintervalgt scalargtsel scalargtjoinsel ) +insert OID = 815 ( "<=" 11 10 b f f 704 704 16 816 814 tintervalle scalarltsel scalarltjoinsel ) +insert OID = 816 ( ">=" 11 10 b f f 704 704 16 815 813 tintervalge scalargtsel scalargtjoinsel ) +insert OID = 843 ( "*" 11 10 b f f 790 700 790 845 0 cash_mul_flt4 - - ) +insert OID = 844 ( "/" 11 10 b f f 790 700 790 0 0 cash_div_flt4 - - ) +insert OID = 845 ( "*" 11 10 b f f 700 790 790 843 0 flt4_mul_cash - - ) +insert OID = 900 ( "=" 11 10 b t f 790 790 16 900 901 cash_eq eqsel eqjoinsel ) +insert OID = 901 ( "<>" 11 10 b f f 790 790 16 901 900 cash_ne neqsel neqjoinsel ) +insert OID = 902 ( "<" 11 10 b f f 790 790 16 903 905 cash_lt scalarltsel scalarltjoinsel ) +insert OID = 903 ( ">" 11 10 b f f 790 790 16 902 904 cash_gt scalargtsel scalargtjoinsel ) +insert OID = 904 ( "<=" 11 10 b f f 790 790 16 905 903 cash_le scalarltsel scalarltjoinsel ) +insert OID = 905 ( ">=" 11 10 b f f 790 790 16 904 902 cash_ge scalargtsel scalargtjoinsel ) +insert OID = 906 ( "+" 11 10 b f f 790 790 790 906 0 cash_pl - - ) +insert OID = 907 ( "-" 11 10 b f f 790 790 790 0 0 cash_mi - - ) +insert OID = 908 ( "*" 11 10 b f f 790 701 790 916 0 cash_mul_flt8 - - ) +insert OID = 909 ( "/" 11 10 b f f 790 701 790 0 0 cash_div_flt8 - - ) +insert OID = 912 ( "*" 11 10 b f f 790 23 790 917 0 cash_mul_int4 - - ) +insert OID = 913 ( "/" 11 10 b f f 790 23 790 0 0 cash_div_int4 - - ) +insert OID = 914 ( "*" 11 10 b f f 790 21 790 918 0 cash_mul_int2 - - ) +insert OID = 915 ( "/" 11 10 b f f 790 21 790 0 0 cash_div_int2 - - ) +insert OID = 916 ( "*" 11 10 b f f 701 790 790 908 0 flt8_mul_cash - - ) +insert OID = 917 ( "*" 11 10 b f f 23 790 790 912 0 int4_mul_cash - - ) +insert OID = 918 ( "*" 11 10 b f f 21 790 790 914 0 int2_mul_cash - - ) +insert OID = 3825 ( "/" 11 10 b f f 790 790 701 0 0 cash_div_cash - - ) +insert OID = 965 ( "^" 11 10 b f f 701 701 701 0 0 dpow - - ) +insert OID = 966 ( "+" 11 10 b f f 1034 1033 1034 0 0 aclinsert - - ) +insert OID = 967 ( "-" 11 10 b f f 1034 1033 1034 0 0 aclremove - - ) +insert OID = 968 ( "@>" 11 10 b f f 1034 1033 16 0 0 aclcontains - - ) +insert OID = 974 ( "=" 11 10 b f t 1033 1033 16 974 0 aclitemeq eqsel eqjoinsel ) +insert OID = 969 ( "@@" 11 10 l f f 0 601 600 0 0 lseg_center - - ) +insert OID = 970 ( "@@" 11 10 l f f 0 602 600 0 0 path_center - - ) +insert OID = 971 ( "@@" 11 10 l f f 0 604 600 0 0 poly_center - - ) +insert OID = 1054 ( "=" 11 10 b t t 1042 1042 16 1054 1057 bpchareq eqsel eqjoinsel ) +insert OID = 1055 ( "~" 11 10 b f f 1042 25 16 0 1056 bpcharregexeq regexeqsel regexeqjoinsel ) +insert OID = 1056 ( "!~" 11 10 b f f 1042 25 16 0 1055 bpcharregexne regexnesel regexnejoinsel ) +insert OID = 1057 ( "<>" 11 10 b f f 1042 1042 16 1057 1054 bpcharne neqsel neqjoinsel ) +insert OID = 1058 ( "<" 11 10 b f f 1042 1042 16 1060 1061 bpcharlt scalarltsel scalarltjoinsel ) +insert OID = 1059 ( "<=" 11 10 b f f 1042 1042 16 1061 1060 bpcharle scalarltsel scalarltjoinsel ) +insert OID = 1060 ( ">" 11 10 b f f 1042 1042 16 1058 1059 bpchargt scalargtsel scalargtjoinsel ) +insert OID = 1061 ( ">=" 11 10 b f f 1042 1042 16 1059 1058 bpcharge scalargtsel scalargtjoinsel ) +insert OID = 1070 ( "=" 11 10 b t t 2277 2277 16 1070 1071 array_eq eqsel eqjoinsel ) +insert OID = 1071 ( "<>" 11 10 b f f 2277 2277 16 1071 1070 array_ne neqsel neqjoinsel ) +insert OID = 1072 ( "<" 11 10 b f f 2277 2277 16 1073 1075 array_lt scalarltsel scalarltjoinsel ) +insert OID = 1073 ( ">" 11 10 b f f 2277 2277 16 1072 1074 array_gt scalargtsel scalargtjoinsel ) +insert OID = 1074 ( "<=" 11 10 b f f 2277 2277 16 1075 1073 array_le scalarltsel scalarltjoinsel ) +insert OID = 1075 ( ">=" 11 10 b f f 2277 2277 16 1074 1072 array_ge scalargtsel scalargtjoinsel ) +insert OID = 1076 ( "+" 11 10 b f f 1082 1186 1114 2551 0 date_pl_interval - - ) +insert OID = 1077 ( "-" 11 10 b f f 1082 1186 1114 0 0 date_mi_interval - - ) +insert OID = 1093 ( "=" 11 10 b t t 1082 1082 16 1093 1094 date_eq eqsel eqjoinsel ) +insert OID = 1094 ( "<>" 11 10 b f f 1082 1082 16 1094 1093 date_ne neqsel neqjoinsel ) +insert OID = 1095 ( "<" 11 10 b f f 1082 1082 16 1097 1098 date_lt scalarltsel scalarltjoinsel ) +insert OID = 1096 ( "<=" 11 10 b f f 1082 1082 16 1098 1097 date_le scalarltsel scalarltjoinsel ) +insert OID = 1097 ( ">" 11 10 b f f 1082 1082 16 1095 1096 date_gt scalargtsel scalargtjoinsel ) +insert OID = 1098 ( ">=" 11 10 b f f 1082 1082 16 1096 1095 date_ge scalargtsel scalargtjoinsel ) +insert OID = 1099 ( "-" 11 10 b f f 1082 1082 23 0 0 date_mi - - ) +insert OID = 1100 ( "+" 11 10 b f f 1082 23 1082 2555 0 date_pli - - ) +insert OID = 1101 ( "-" 11 10 b f f 1082 23 1082 0 0 date_mii - - ) +insert OID = 1108 ( "=" 11 10 b t t 1083 1083 16 1108 1109 time_eq eqsel eqjoinsel ) +insert OID = 1109 ( "<>" 11 10 b f f 1083 1083 16 1109 1108 time_ne neqsel neqjoinsel ) +insert OID = 1110 ( "<" 11 10 b f f 1083 1083 16 1112 1113 time_lt scalarltsel scalarltjoinsel ) +insert OID = 1111 ( "<=" 11 10 b f f 1083 1083 16 1113 1112 time_le scalarltsel scalarltjoinsel ) +insert OID = 1112 ( ">" 11 10 b f f 1083 1083 16 1110 1111 time_gt scalargtsel scalargtjoinsel ) +insert OID = 1113 ( ">=" 11 10 b f f 1083 1083 16 1111 1110 time_ge scalargtsel scalargtjoinsel ) +insert OID = 1550 ( "=" 11 10 b t t 1266 1266 16 1550 1551 timetz_eq eqsel eqjoinsel ) +insert OID = 1551 ( "<>" 11 10 b f f 1266 1266 16 1551 1550 timetz_ne neqsel neqjoinsel ) +insert OID = 1552 ( "<" 11 10 b f f 1266 1266 16 1554 1555 timetz_lt scalarltsel scalarltjoinsel ) +insert OID = 1553 ( "<=" 11 10 b f f 1266 1266 16 1555 1554 timetz_le scalarltsel scalarltjoinsel ) +insert OID = 1554 ( ">" 11 10 b f f 1266 1266 16 1552 1553 timetz_gt scalargtsel scalargtjoinsel ) +insert OID = 1555 ( ">=" 11 10 b f f 1266 1266 16 1553 1552 timetz_ge scalargtsel scalargtjoinsel ) +insert OID = 1116 ( "+" 11 10 b f f 700 701 701 1126 0 float48pl - - ) +insert OID = 1117 ( "-" 11 10 b f f 700 701 701 0 0 float48mi - - ) +insert OID = 1118 ( "/" 11 10 b f f 700 701 701 0 0 float48div - - ) +insert OID = 1119 ( "*" 11 10 b f f 700 701 701 1129 0 float48mul - - ) +insert OID = 1120 ( "=" 11 10 b t t 700 701 16 1130 1121 float48eq eqsel eqjoinsel ) +insert OID = 1121 ( "<>" 11 10 b f f 700 701 16 1131 1120 float48ne neqsel neqjoinsel ) +insert OID = 1122 ( "<" 11 10 b f f 700 701 16 1133 1125 float48lt scalarltsel scalarltjoinsel ) +insert OID = 1123 ( ">" 11 10 b f f 700 701 16 1132 1124 float48gt scalargtsel scalargtjoinsel ) +insert OID = 1124 ( "<=" 11 10 b f f 700 701 16 1135 1123 float48le scalarltsel scalarltjoinsel ) +insert OID = 1125 ( ">=" 11 10 b f f 700 701 16 1134 1122 float48ge scalargtsel scalargtjoinsel ) +insert OID = 1126 ( "+" 11 10 b f f 701 700 701 1116 0 float84pl - - ) +insert OID = 1127 ( "-" 11 10 b f f 701 700 701 0 0 float84mi - - ) +insert OID = 1128 ( "/" 11 10 b f f 701 700 701 0 0 float84div - - ) +insert OID = 1129 ( "*" 11 10 b f f 701 700 701 1119 0 float84mul - - ) +insert OID = 1130 ( "=" 11 10 b t t 701 700 16 1120 1131 float84eq eqsel eqjoinsel ) +insert OID = 1131 ( "<>" 11 10 b f f 701 700 16 1121 1130 float84ne neqsel neqjoinsel ) +insert OID = 1132 ( "<" 11 10 b f f 701 700 16 1123 1135 float84lt scalarltsel scalarltjoinsel ) +insert OID = 1133 ( ">" 11 10 b f f 701 700 16 1122 1134 float84gt scalargtsel scalargtjoinsel ) +insert OID = 1134 ( "<=" 11 10 b f f 701 700 16 1125 1133 float84le scalarltsel scalarltjoinsel ) +insert OID = 1135 ( ">=" 11 10 b f f 701 700 16 1124 1132 float84ge scalargtsel scalargtjoinsel ) +insert OID = 1207 ( "~~" 11 10 b f f 19 25 16 0 1208 namelike likesel likejoinsel ) +insert OID = 1208 ( "!~~" 11 10 b f f 19 25 16 0 1207 namenlike nlikesel nlikejoinsel ) +insert OID = 1209 ( "~~" 11 10 b f f 25 25 16 0 1210 textlike likesel likejoinsel ) +insert OID = 1210 ( "!~~" 11 10 b f f 25 25 16 0 1209 textnlike nlikesel nlikejoinsel ) +insert OID = 1211 ( "~~" 11 10 b f f 1042 25 16 0 1212 bpcharlike likesel likejoinsel ) +insert OID = 1212 ( "!~~" 11 10 b f f 1042 25 16 0 1211 bpcharnlike nlikesel nlikejoinsel ) +insert OID = 1226 ( "~*" 11 10 b f f 19 25 16 0 1227 nameicregexeq icregexeqsel icregexeqjoinsel ) +insert OID = 1227 ( "!~*" 11 10 b f f 19 25 16 0 1226 nameicregexne icregexnesel icregexnejoinsel ) +insert OID = 1228 ( "~*" 11 10 b f f 25 25 16 0 1229 texticregexeq icregexeqsel icregexeqjoinsel ) +insert OID = 1229 ( "!~*" 11 10 b f f 25 25 16 0 1228 texticregexne icregexnesel icregexnejoinsel ) +insert OID = 1234 ( "~*" 11 10 b f f 1042 25 16 0 1235 bpcharicregexeq icregexeqsel icregexeqjoinsel ) +insert OID = 1235 ( "!~*" 11 10 b f f 1042 25 16 0 1234 bpcharicregexne icregexnesel icregexnejoinsel ) +insert OID = 1320 ( "=" 11 10 b t t 1184 1184 16 1320 1321 timestamptz_eq eqsel eqjoinsel ) +insert OID = 1321 ( "<>" 11 10 b f f 1184 1184 16 1321 1320 timestamptz_ne neqsel neqjoinsel ) +insert OID = 1322 ( "<" 11 10 b f f 1184 1184 16 1324 1325 timestamptz_lt scalarltsel scalarltjoinsel ) +insert OID = 1323 ( "<=" 11 10 b f f 1184 1184 16 1325 1324 timestamptz_le scalarltsel scalarltjoinsel ) +insert OID = 1324 ( ">" 11 10 b f f 1184 1184 16 1322 1323 timestamptz_gt scalargtsel scalargtjoinsel ) +insert OID = 1325 ( ">=" 11 10 b f f 1184 1184 16 1323 1322 timestamptz_ge scalargtsel scalargtjoinsel ) +insert OID = 1327 ( "+" 11 10 b f f 1184 1186 1184 2554 0 timestamptz_pl_interval - - ) +insert OID = 1328 ( "-" 11 10 b f f 1184 1184 1186 0 0 timestamptz_mi - - ) +insert OID = 1329 ( "-" 11 10 b f f 1184 1186 1184 0 0 timestamptz_mi_interval - - ) +insert OID = 1330 ( "=" 11 10 b t t 1186 1186 16 1330 1331 interval_eq eqsel eqjoinsel ) +insert OID = 1331 ( "<>" 11 10 b f f 1186 1186 16 1331 1330 interval_ne neqsel neqjoinsel ) +insert OID = 1332 ( "<" 11 10 b f f 1186 1186 16 1334 1335 interval_lt scalarltsel scalarltjoinsel ) +insert OID = 1333 ( "<=" 11 10 b f f 1186 1186 16 1335 1334 interval_le scalarltsel scalarltjoinsel ) +insert OID = 1334 ( ">" 11 10 b f f 1186 1186 16 1332 1333 interval_gt scalargtsel scalargtjoinsel ) +insert OID = 1335 ( ">=" 11 10 b f f 1186 1186 16 1333 1332 interval_ge scalargtsel scalargtjoinsel ) +insert OID = 1336 ( "-" 11 10 l f f 0 1186 1186 0 0 interval_um - - ) +insert OID = 1337 ( "+" 11 10 b f f 1186 1186 1186 1337 0 interval_pl - - ) +insert OID = 1338 ( "-" 11 10 b f f 1186 1186 1186 0 0 interval_mi - - ) +insert OID = 1360 ( "+" 11 10 b f f 1082 1083 1114 1363 0 datetime_pl - - ) +insert OID = 1361 ( "+" 11 10 b f f 1082 1266 1184 1366 0 datetimetz_pl - - ) +insert OID = 1363 ( "+" 11 10 b f f 1083 1082 1114 1360 0 timedate_pl - - ) +insert OID = 1366 ( "+" 11 10 b f f 1266 1082 1184 1361 0 timetzdate_pl - - ) +insert OID = 1399 ( "-" 11 10 b f f 1083 1083 1186 0 0 time_mi_time - - ) +insert OID = 1420 ( "@@" 11 10 l f f 0 718 600 0 0 circle_center - - ) +insert OID = 1500 ( "=" 11 10 b f f 718 718 16 1500 1501 circle_eq eqsel eqjoinsel ) +insert OID = 1501 ( "<>" 11 10 b f f 718 718 16 1501 1500 circle_ne neqsel neqjoinsel ) +insert OID = 1502 ( "<" 11 10 b f f 718 718 16 1503 1505 circle_lt areasel areajoinsel ) +insert OID = 1503 ( ">" 11 10 b f f 718 718 16 1502 1504 circle_gt areasel areajoinsel ) +insert OID = 1504 ( "<=" 11 10 b f f 718 718 16 1505 1503 circle_le areasel areajoinsel ) +insert OID = 1505 ( ">=" 11 10 b f f 718 718 16 1504 1502 circle_ge areasel areajoinsel ) +insert OID = 1506 ( "<<" 11 10 b f f 718 718 16 0 0 circle_left positionsel positionjoinsel ) +insert OID = 1507 ( "&<" 11 10 b f f 718 718 16 0 0 circle_overleft positionsel positionjoinsel ) +insert OID = 1508 ( "&>" 11 10 b f f 718 718 16 0 0 circle_overright positionsel positionjoinsel ) +insert OID = 1509 ( ">>" 11 10 b f f 718 718 16 0 0 circle_right positionsel positionjoinsel ) +insert OID = 1510 ( "<@" 11 10 b f f 718 718 16 1511 0 circle_contained contsel contjoinsel ) +insert OID = 1511 ( "@>" 11 10 b f f 718 718 16 1510 0 circle_contain contsel contjoinsel ) +insert OID = 1512 ( "~=" 11 10 b f f 718 718 16 1512 0 circle_same eqsel eqjoinsel ) +insert OID = 1513 ( "&&" 11 10 b f f 718 718 16 1513 0 circle_overlap areasel areajoinsel ) +insert OID = 1514 ( "|>>" 11 10 b f f 718 718 16 0 0 circle_above positionsel positionjoinsel ) +insert OID = 1515 ( "<<|" 11 10 b f f 718 718 16 0 0 circle_below positionsel positionjoinsel ) +insert OID = 1516 ( "+" 11 10 b f f 718 600 718 0 0 circle_add_pt - - ) +insert OID = 1517 ( "-" 11 10 b f f 718 600 718 0 0 circle_sub_pt - - ) +insert OID = 1518 ( "*" 11 10 b f f 718 600 718 0 0 circle_mul_pt - - ) +insert OID = 1519 ( "/" 11 10 b f f 718 600 718 0 0 circle_div_pt - - ) +insert OID = 1520 ( "<->" 11 10 b f f 718 718 701 1520 0 circle_distance - - ) +insert OID = 1521 ( "#" 11 10 l f f 0 604 23 0 0 poly_npoints - - ) +insert OID = 1522 ( "<->" 11 10 b f f 600 718 701 0 0 dist_pc - - ) +insert OID = 1523 ( "<->" 11 10 b f f 718 604 701 0 0 dist_cpoly - - ) +insert OID = 1524 ( "<->" 11 10 b f f 628 603 701 0 0 dist_lb - - ) +insert OID = 1525 ( "?#" 11 10 b f f 601 601 16 1525 0 lseg_intersect - - ) +insert OID = 1526 ( "?||" 11 10 b f f 601 601 16 1526 0 lseg_parallel - - ) +insert OID = 1527 ( "?-|" 11 10 b f f 601 601 16 1527 0 lseg_perp - - ) +insert OID = 1528 ( "?-" 11 10 l f f 0 601 16 0 0 lseg_horizontal - - ) +insert OID = 1529 ( "?|" 11 10 l f f 0 601 16 0 0 lseg_vertical - - ) +insert OID = 1535 ( "=" 11 10 b f f 601 601 16 1535 1586 lseg_eq eqsel eqjoinsel ) +insert OID = 1536 ( "#" 11 10 b f f 601 601 600 1536 0 lseg_interpt - - ) +insert OID = 1537 ( "?#" 11 10 b f f 601 628 16 0 0 inter_sl - - ) +insert OID = 1538 ( "?#" 11 10 b f f 601 603 16 0 0 inter_sb - - ) +insert OID = 1539 ( "?#" 11 10 b f f 628 603 16 0 0 inter_lb - - ) +insert OID = 1546 ( "<@" 11 10 b f f 600 628 16 0 0 on_pl - - ) +insert OID = 1547 ( "<@" 11 10 b f f 600 601 16 0 0 on_ps - - ) +insert OID = 1548 ( "<@" 11 10 b f f 601 628 16 0 0 on_sl - - ) +insert OID = 1549 ( "<@" 11 10 b f f 601 603 16 0 0 on_sb - - ) +insert OID = 1557 ( "##" 11 10 b f f 600 628 600 0 0 close_pl - - ) +insert OID = 1558 ( "##" 11 10 b f f 600 601 600 0 0 close_ps - - ) +insert OID = 1559 ( "##" 11 10 b f f 600 603 600 0 0 close_pb - - ) +insert OID = 1566 ( "##" 11 10 b f f 601 628 600 0 0 close_sl - - ) +insert OID = 1567 ( "##" 11 10 b f f 601 603 600 0 0 close_sb - - ) +insert OID = 1568 ( "##" 11 10 b f f 628 603 600 0 0 close_lb - - ) +insert OID = 1577 ( "##" 11 10 b f f 628 601 600 0 0 close_ls - - ) +insert OID = 1578 ( "##" 11 10 b f f 601 601 600 0 0 close_lseg - - ) +insert OID = 1583 ( "*" 11 10 b f f 1186 701 1186 1584 0 interval_mul - - ) +insert OID = 1584 ( "*" 11 10 b f f 701 1186 1186 1583 0 mul_d_interval - - ) +insert OID = 1585 ( "/" 11 10 b f f 1186 701 1186 0 0 interval_div - - ) +insert OID = 1586 ( "<>" 11 10 b f f 601 601 16 1586 1535 lseg_ne neqsel neqjoinsel ) +insert OID = 1587 ( "<" 11 10 b f f 601 601 16 1589 1590 lseg_lt - - ) +insert OID = 1588 ( "<=" 11 10 b f f 601 601 16 1590 1589 lseg_le - - ) +insert OID = 1589 ( ">" 11 10 b f f 601 601 16 1587 1588 lseg_gt - - ) +insert OID = 1590 ( ">=" 11 10 b f f 601 601 16 1588 1587 lseg_ge - - ) +insert OID = 1591 ( "@-@" 11 10 l f f 0 601 701 0 0 lseg_length - - ) +insert OID = 1611 ( "?#" 11 10 b f f 628 628 16 1611 0 line_intersect - - ) +insert OID = 1612 ( "?||" 11 10 b f f 628 628 16 1612 0 line_parallel - - ) +insert OID = 1613 ( "?-|" 11 10 b f f 628 628 16 1613 0 line_perp - - ) +insert OID = 1614 ( "?-" 11 10 l f f 0 628 16 0 0 line_horizontal - - ) +insert OID = 1615 ( "?|" 11 10 l f f 0 628 16 0 0 line_vertical - - ) +insert OID = 1616 ( "=" 11 10 b f f 628 628 16 1616 0 line_eq eqsel eqjoinsel ) +insert OID = 1617 ( "#" 11 10 b f f 628 628 600 1617 0 line_interpt - - ) +insert OID = 1220 ( "=" 11 10 b t t 829 829 16 1220 1221 macaddr_eq eqsel eqjoinsel ) +insert OID = 1221 ( "<>" 11 10 b f f 829 829 16 1221 1220 macaddr_ne neqsel neqjoinsel ) +insert OID = 1222 ( "<" 11 10 b f f 829 829 16 1224 1225 macaddr_lt scalarltsel scalarltjoinsel ) +insert OID = 1223 ( "<=" 11 10 b f f 829 829 16 1225 1224 macaddr_le scalarltsel scalarltjoinsel ) +insert OID = 1224 ( ">" 11 10 b f f 829 829 16 1222 1223 macaddr_gt scalargtsel scalargtjoinsel ) +insert OID = 1225 ( ">=" 11 10 b f f 829 829 16 1223 1222 macaddr_ge scalargtsel scalargtjoinsel ) +insert OID = 3147 ( "~" 11 10 l f f 0 829 829 0 0 macaddr_not - - ) +insert OID = 3148 ( "&" 11 10 b f f 829 829 829 0 0 macaddr_and - - ) +insert OID = 3149 ( "|" 11 10 b f f 829 829 829 0 0 macaddr_or - - ) +insert OID = 1201 ( "=" 11 10 b t t 869 869 16 1201 1202 network_eq eqsel eqjoinsel ) +insert OID = 1202 ( "<>" 11 10 b f f 869 869 16 1202 1201 network_ne neqsel neqjoinsel ) +insert OID = 1203 ( "<" 11 10 b f f 869 869 16 1205 1206 network_lt scalarltsel scalarltjoinsel ) +insert OID = 1204 ( "<=" 11 10 b f f 869 869 16 1206 1205 network_le scalarltsel scalarltjoinsel ) +insert OID = 1205 ( ">" 11 10 b f f 869 869 16 1203 1204 network_gt scalargtsel scalargtjoinsel ) +insert OID = 1206 ( ">=" 11 10 b f f 869 869 16 1204 1203 network_ge scalargtsel scalargtjoinsel ) +insert OID = 931 ( "<<" 11 10 b f f 869 869 16 933 0 network_sub - - ) +insert OID = 932 ( "<<=" 11 10 b f f 869 869 16 934 0 network_subeq - - ) +insert OID = 933 ( ">>" 11 10 b f f 869 869 16 931 0 network_sup - - ) +insert OID = 934 ( ">>=" 11 10 b f f 869 869 16 932 0 network_supeq - - ) +insert OID = 2634 ( "~" 11 10 l f f 0 869 869 0 0 inetnot - - ) +insert OID = 2635 ( "&" 11 10 b f f 869 869 869 0 0 inetand - - ) +insert OID = 2636 ( "|" 11 10 b f f 869 869 869 0 0 inetor - - ) +insert OID = 2637 ( "+" 11 10 b f f 869 20 869 2638 0 inetpl - - ) +insert OID = 2638 ( "+" 11 10 b f f 20 869 869 2637 0 int8pl_inet - - ) +insert OID = 2639 ( "-" 11 10 b f f 869 20 869 0 0 inetmi_int8 - - ) +insert OID = 2640 ( "-" 11 10 b f f 869 869 20 0 0 inetmi - - ) +insert OID = 1625 ( "~~*" 11 10 b f f 19 25 16 0 1626 nameiclike iclikesel iclikejoinsel ) +insert OID = 1626 ( "!~~*" 11 10 b f f 19 25 16 0 1625 nameicnlike icnlikesel icnlikejoinsel ) +insert OID = 1627 ( "~~*" 11 10 b f f 25 25 16 0 1628 texticlike iclikesel iclikejoinsel ) +insert OID = 1628 ( "!~~*" 11 10 b f f 25 25 16 0 1627 texticnlike icnlikesel icnlikejoinsel ) +insert OID = 1629 ( "~~*" 11 10 b f f 1042 25 16 0 1630 bpchariclike iclikesel iclikejoinsel ) +insert OID = 1630 ( "!~~*" 11 10 b f f 1042 25 16 0 1629 bpcharicnlike icnlikesel icnlikejoinsel ) +insert OID = 1751 ( "-" 11 10 l f f 0 1700 1700 0 0 numeric_uminus - - ) +insert OID = 1752 ( "=" 11 10 b t t 1700 1700 16 1752 1753 numeric_eq eqsel eqjoinsel ) +insert OID = 1753 ( "<>" 11 10 b f f 1700 1700 16 1753 1752 numeric_ne neqsel neqjoinsel ) +insert OID = 1754 ( "<" 11 10 b f f 1700 1700 16 1756 1757 numeric_lt scalarltsel scalarltjoinsel ) +insert OID = 1755 ( "<=" 11 10 b f f 1700 1700 16 1757 1756 numeric_le scalarltsel scalarltjoinsel ) +insert OID = 1756 ( ">" 11 10 b f f 1700 1700 16 1754 1755 numeric_gt scalargtsel scalargtjoinsel ) +insert OID = 1757 ( ">=" 11 10 b f f 1700 1700 16 1755 1754 numeric_ge scalargtsel scalargtjoinsel ) +insert OID = 1758 ( "+" 11 10 b f f 1700 1700 1700 1758 0 numeric_add - - ) +insert OID = 1759 ( "-" 11 10 b f f 1700 1700 1700 0 0 numeric_sub - - ) +insert OID = 1760 ( "*" 11 10 b f f 1700 1700 1700 1760 0 numeric_mul - - ) +insert OID = 1761 ( "/" 11 10 b f f 1700 1700 1700 0 0 numeric_div - - ) +insert OID = 1762 ( "%" 11 10 b f f 1700 1700 1700 0 0 numeric_mod - - ) +insert OID = 1038 ( "^" 11 10 b f f 1700 1700 1700 0 0 numeric_power - - ) +insert OID = 1763 ( "@" 11 10 l f f 0 1700 1700 0 0 numeric_abs - - ) +insert OID = 1784 ( "=" 11 10 b t f 1560 1560 16 1784 1785 biteq eqsel eqjoinsel ) +insert OID = 1785 ( "<>" 11 10 b f f 1560 1560 16 1785 1784 bitne neqsel neqjoinsel ) +insert OID = 1786 ( "<" 11 10 b f f 1560 1560 16 1787 1789 bitlt scalarltsel scalarltjoinsel ) +insert OID = 1787 ( ">" 11 10 b f f 1560 1560 16 1786 1788 bitgt scalargtsel scalargtjoinsel ) +insert OID = 1788 ( "<=" 11 10 b f f 1560 1560 16 1789 1787 bitle scalarltsel scalarltjoinsel ) +insert OID = 1789 ( ">=" 11 10 b f f 1560 1560 16 1788 1786 bitge scalargtsel scalargtjoinsel ) +insert OID = 1791 ( "&" 11 10 b f f 1560 1560 1560 1791 0 bitand - - ) +insert OID = 1792 ( "|" 11 10 b f f 1560 1560 1560 1792 0 bitor - - ) +insert OID = 1793 ( "#" 11 10 b f f 1560 1560 1560 1793 0 bitxor - - ) +insert OID = 1794 ( "~" 11 10 l f f 0 1560 1560 0 0 bitnot - - ) +insert OID = 1795 ( "<<" 11 10 b f f 1560 23 1560 0 0 bitshiftleft - - ) +insert OID = 1796 ( ">>" 11 10 b f f 1560 23 1560 0 0 bitshiftright - - ) +insert OID = 1797 ( "||" 11 10 b f f 1562 1562 1562 0 0 bitcat - - ) +insert OID = 1800 ( "+" 11 10 b f f 1083 1186 1083 1849 0 time_pl_interval - - ) +insert OID = 1801 ( "-" 11 10 b f f 1083 1186 1083 0 0 time_mi_interval - - ) +insert OID = 1802 ( "+" 11 10 b f f 1266 1186 1266 2552 0 timetz_pl_interval - - ) +insert OID = 1803 ( "-" 11 10 b f f 1266 1186 1266 0 0 timetz_mi_interval - - ) +insert OID = 1804 ( "=" 11 10 b t f 1562 1562 16 1804 1805 varbiteq eqsel eqjoinsel ) +insert OID = 1805 ( "<>" 11 10 b f f 1562 1562 16 1805 1804 varbitne neqsel neqjoinsel ) +insert OID = 1806 ( "<" 11 10 b f f 1562 1562 16 1807 1809 varbitlt scalarltsel scalarltjoinsel ) +insert OID = 1807 ( ">" 11 10 b f f 1562 1562 16 1806 1808 varbitgt scalargtsel scalargtjoinsel ) +insert OID = 1808 ( "<=" 11 10 b f f 1562 1562 16 1809 1807 varbitle scalarltsel scalarltjoinsel ) +insert OID = 1809 ( ">=" 11 10 b f f 1562 1562 16 1808 1806 varbitge scalargtsel scalargtjoinsel ) +insert OID = 1849 ( "+" 11 10 b f f 1186 1083 1083 1800 0 interval_pl_time - - ) +insert OID = 1862 ( "=" 11 10 b t t 21 20 16 1868 1863 int28eq eqsel eqjoinsel ) +insert OID = 1863 ( "<>" 11 10 b f f 21 20 16 1869 1862 int28ne neqsel neqjoinsel ) +insert OID = 1864 ( "<" 11 10 b f f 21 20 16 1871 1867 int28lt scalarltsel scalarltjoinsel ) +insert OID = 1865 ( ">" 11 10 b f f 21 20 16 1870 1866 int28gt scalargtsel scalargtjoinsel ) +insert OID = 1866 ( "<=" 11 10 b f f 21 20 16 1873 1865 int28le scalarltsel scalarltjoinsel ) +insert OID = 1867 ( ">=" 11 10 b f f 21 20 16 1872 1864 int28ge scalargtsel scalargtjoinsel ) +insert OID = 1868 ( "=" 11 10 b t t 20 21 16 1862 1869 int82eq eqsel eqjoinsel ) +insert OID = 1869 ( "<>" 11 10 b f f 20 21 16 1863 1868 int82ne neqsel neqjoinsel ) +insert OID = 1870 ( "<" 11 10 b f f 20 21 16 1865 1873 int82lt scalarltsel scalarltjoinsel ) +insert OID = 1871 ( ">" 11 10 b f f 20 21 16 1864 1872 int82gt scalargtsel scalargtjoinsel ) +insert OID = 1872 ( "<=" 11 10 b f f 20 21 16 1867 1871 int82le scalarltsel scalarltjoinsel ) +insert OID = 1873 ( ">=" 11 10 b f f 20 21 16 1866 1870 int82ge scalargtsel scalargtjoinsel ) +insert OID = 1874 ( "&" 11 10 b f f 21 21 21 1874 0 int2and - - ) +insert OID = 1875 ( "|" 11 10 b f f 21 21 21 1875 0 int2or - - ) +insert OID = 1876 ( "#" 11 10 b f f 21 21 21 1876 0 int2xor - - ) +insert OID = 1877 ( "~" 11 10 l f f 0 21 21 0 0 int2not - - ) +insert OID = 1878 ( "<<" 11 10 b f f 21 23 21 0 0 int2shl - - ) +insert OID = 1879 ( ">>" 11 10 b f f 21 23 21 0 0 int2shr - - ) +insert OID = 1880 ( "&" 11 10 b f f 23 23 23 1880 0 int4and - - ) +insert OID = 1881 ( "|" 11 10 b f f 23 23 23 1881 0 int4or - - ) +insert OID = 1882 ( "#" 11 10 b f f 23 23 23 1882 0 int4xor - - ) +insert OID = 1883 ( "~" 11 10 l f f 0 23 23 0 0 int4not - - ) +insert OID = 1884 ( "<<" 11 10 b f f 23 23 23 0 0 int4shl - - ) +insert OID = 1885 ( ">>" 11 10 b f f 23 23 23 0 0 int4shr - - ) +insert OID = 1886 ( "&" 11 10 b f f 20 20 20 1886 0 int8and - - ) +insert OID = 1887 ( "|" 11 10 b f f 20 20 20 1887 0 int8or - - ) +insert OID = 1888 ( "#" 11 10 b f f 20 20 20 1888 0 int8xor - - ) +insert OID = 1889 ( "~" 11 10 l f f 0 20 20 0 0 int8not - - ) +insert OID = 1890 ( "<<" 11 10 b f f 20 23 20 0 0 int8shl - - ) +insert OID = 1891 ( ">>" 11 10 b f f 20 23 20 0 0 int8shr - - ) +insert OID = 1916 ( "+" 11 10 l f f 0 20 20 0 0 int8up - - ) +insert OID = 1917 ( "+" 11 10 l f f 0 21 21 0 0 int2up - - ) +insert OID = 1918 ( "+" 11 10 l f f 0 23 23 0 0 int4up - - ) +insert OID = 1919 ( "+" 11 10 l f f 0 700 700 0 0 float4up - - ) +insert OID = 1920 ( "+" 11 10 l f f 0 701 701 0 0 float8up - - ) +insert OID = 1921 ( "+" 11 10 l f f 0 1700 1700 0 0 numeric_uplus - - ) +insert OID = 1955 ( "=" 11 10 b t t 17 17 16 1955 1956 byteaeq eqsel eqjoinsel ) +insert OID = 1956 ( "<>" 11 10 b f f 17 17 16 1956 1955 byteane neqsel neqjoinsel ) +insert OID = 1957 ( "<" 11 10 b f f 17 17 16 1959 1960 bytealt scalarltsel scalarltjoinsel ) +insert OID = 1958 ( "<=" 11 10 b f f 17 17 16 1960 1959 byteale scalarltsel scalarltjoinsel ) +insert OID = 1959 ( ">" 11 10 b f f 17 17 16 1957 1958 byteagt scalargtsel scalargtjoinsel ) +insert OID = 1960 ( ">=" 11 10 b f f 17 17 16 1958 1957 byteage scalargtsel scalargtjoinsel ) +insert OID = 2016 ( "~~" 11 10 b f f 17 17 16 0 2017 bytealike likesel likejoinsel ) +insert OID = 2017 ( "!~~" 11 10 b f f 17 17 16 0 2016 byteanlike nlikesel nlikejoinsel ) +insert OID = 2018 ( "||" 11 10 b f f 17 17 17 0 0 byteacat - - ) +insert OID = 2060 ( "=" 11 10 b t t 1114 1114 16 2060 2061 timestamp_eq eqsel eqjoinsel ) +insert OID = 2061 ( "<>" 11 10 b f f 1114 1114 16 2061 2060 timestamp_ne neqsel neqjoinsel ) +insert OID = 2062 ( "<" 11 10 b f f 1114 1114 16 2064 2065 timestamp_lt scalarltsel scalarltjoinsel ) +insert OID = 2063 ( "<=" 11 10 b f f 1114 1114 16 2065 2064 timestamp_le scalarltsel scalarltjoinsel ) +insert OID = 2064 ( ">" 11 10 b f f 1114 1114 16 2062 2063 timestamp_gt scalargtsel scalargtjoinsel ) +insert OID = 2065 ( ">=" 11 10 b f f 1114 1114 16 2063 2062 timestamp_ge scalargtsel scalargtjoinsel ) +insert OID = 2066 ( "+" 11 10 b f f 1114 1186 1114 2553 0 timestamp_pl_interval - - ) +insert OID = 2067 ( "-" 11 10 b f f 1114 1114 1186 0 0 timestamp_mi - - ) +insert OID = 2068 ( "-" 11 10 b f f 1114 1186 1114 0 0 timestamp_mi_interval - - ) +insert OID = 2314 ( "~<~" 11 10 b f f 25 25 16 2318 2317 text_pattern_lt scalarltsel scalarltjoinsel ) +insert OID = 2315 ( "~<=~" 11 10 b f f 25 25 16 2317 2318 text_pattern_le scalarltsel scalarltjoinsel ) +insert OID = 2317 ( "~>=~" 11 10 b f f 25 25 16 2315 2314 text_pattern_ge scalargtsel scalargtjoinsel ) +insert OID = 2318 ( "~>~" 11 10 b f f 25 25 16 2314 2315 text_pattern_gt scalargtsel scalargtjoinsel ) +insert OID = 2326 ( "~<~" 11 10 b f f 1042 1042 16 2330 2329 bpchar_pattern_lt scalarltsel scalarltjoinsel ) +insert OID = 2327 ( "~<=~" 11 10 b f f 1042 1042 16 2329 2330 bpchar_pattern_le scalarltsel scalarltjoinsel ) +insert OID = 2329 ( "~>=~" 11 10 b f f 1042 1042 16 2327 2326 bpchar_pattern_ge scalargtsel scalargtjoinsel ) +insert OID = 2330 ( "~>~" 11 10 b f f 1042 1042 16 2326 2327 bpchar_pattern_gt scalargtsel scalargtjoinsel ) +insert OID = 2345 ( "<" 11 10 b f f 1082 1114 16 2375 2348 date_lt_timestamp scalarltsel scalarltjoinsel ) +insert OID = 2346 ( "<=" 11 10 b f f 1082 1114 16 2374 2349 date_le_timestamp scalarltsel scalarltjoinsel ) +insert OID = 2347 ( "=" 11 10 b t f 1082 1114 16 2373 2350 date_eq_timestamp eqsel eqjoinsel ) +insert OID = 2348 ( ">=" 11 10 b f f 1082 1114 16 2372 2345 date_ge_timestamp scalargtsel scalargtjoinsel ) +insert OID = 2349 ( ">" 11 10 b f f 1082 1114 16 2371 2346 date_gt_timestamp scalargtsel scalargtjoinsel ) +insert OID = 2350 ( "<>" 11 10 b f f 1082 1114 16 2376 2347 date_ne_timestamp neqsel neqjoinsel ) +insert OID = 2358 ( "<" 11 10 b f f 1082 1184 16 2388 2361 date_lt_timestamptz scalarltsel scalarltjoinsel ) +insert OID = 2359 ( "<=" 11 10 b f f 1082 1184 16 2387 2362 date_le_timestamptz scalarltsel scalarltjoinsel ) +insert OID = 2360 ( "=" 11 10 b t f 1082 1184 16 2386 2363 date_eq_timestamptz eqsel eqjoinsel ) +insert OID = 2361 ( ">=" 11 10 b f f 1082 1184 16 2385 2358 date_ge_timestamptz scalargtsel scalargtjoinsel ) +insert OID = 2362 ( ">" 11 10 b f f 1082 1184 16 2384 2359 date_gt_timestamptz scalargtsel scalargtjoinsel ) +insert OID = 2363 ( "<>" 11 10 b f f 1082 1184 16 2389 2360 date_ne_timestamptz neqsel neqjoinsel ) +insert OID = 2371 ( "<" 11 10 b f f 1114 1082 16 2349 2374 timestamp_lt_date scalarltsel scalarltjoinsel ) +insert OID = 2372 ( "<=" 11 10 b f f 1114 1082 16 2348 2375 timestamp_le_date scalarltsel scalarltjoinsel ) +insert OID = 2373 ( "=" 11 10 b t f 1114 1082 16 2347 2376 timestamp_eq_date eqsel eqjoinsel ) +insert OID = 2374 ( ">=" 11 10 b f f 1114 1082 16 2346 2371 timestamp_ge_date scalargtsel scalargtjoinsel ) +insert OID = 2375 ( ">" 11 10 b f f 1114 1082 16 2345 2372 timestamp_gt_date scalargtsel scalargtjoinsel ) +insert OID = 2376 ( "<>" 11 10 b f f 1114 1082 16 2350 2373 timestamp_ne_date neqsel neqjoinsel ) +insert OID = 2384 ( "<" 11 10 b f f 1184 1082 16 2362 2387 timestamptz_lt_date scalarltsel scalarltjoinsel ) +insert OID = 2385 ( "<=" 11 10 b f f 1184 1082 16 2361 2388 timestamptz_le_date scalarltsel scalarltjoinsel ) +insert OID = 2386 ( "=" 11 10 b t f 1184 1082 16 2360 2389 timestamptz_eq_date eqsel eqjoinsel ) +insert OID = 2387 ( ">=" 11 10 b f f 1184 1082 16 2359 2384 timestamptz_ge_date scalargtsel scalargtjoinsel ) +insert OID = 2388 ( ">" 11 10 b f f 1184 1082 16 2358 2385 timestamptz_gt_date scalargtsel scalargtjoinsel ) +insert OID = 2389 ( "<>" 11 10 b f f 1184 1082 16 2363 2386 timestamptz_ne_date neqsel neqjoinsel ) +insert OID = 2534 ( "<" 11 10 b f f 1114 1184 16 2544 2537 timestamp_lt_timestamptz scalarltsel scalarltjoinsel ) +insert OID = 2535 ( "<=" 11 10 b f f 1114 1184 16 2543 2538 timestamp_le_timestamptz scalarltsel scalarltjoinsel ) +insert OID = 2536 ( "=" 11 10 b t f 1114 1184 16 2542 2539 timestamp_eq_timestamptz eqsel eqjoinsel ) +insert OID = 2537 ( ">=" 11 10 b f f 1114 1184 16 2541 2534 timestamp_ge_timestamptz scalargtsel scalargtjoinsel ) +insert OID = 2538 ( ">" 11 10 b f f 1114 1184 16 2540 2535 timestamp_gt_timestamptz scalargtsel scalargtjoinsel ) +insert OID = 2539 ( "<>" 11 10 b f f 1114 1184 16 2545 2536 timestamp_ne_timestamptz neqsel neqjoinsel ) +insert OID = 2540 ( "<" 11 10 b f f 1184 1114 16 2538 2543 timestamptz_lt_timestamp scalarltsel scalarltjoinsel ) +insert OID = 2541 ( "<=" 11 10 b f f 1184 1114 16 2537 2544 timestamptz_le_timestamp scalarltsel scalarltjoinsel ) +insert OID = 2542 ( "=" 11 10 b t f 1184 1114 16 2536 2545 timestamptz_eq_timestamp eqsel eqjoinsel ) +insert OID = 2543 ( ">=" 11 10 b f f 1184 1114 16 2535 2540 timestamptz_ge_timestamp scalargtsel scalargtjoinsel ) +insert OID = 2544 ( ">" 11 10 b f f 1184 1114 16 2534 2541 timestamptz_gt_timestamp scalargtsel scalargtjoinsel ) +insert OID = 2545 ( "<>" 11 10 b f f 1184 1114 16 2539 2542 timestamptz_ne_timestamp neqsel neqjoinsel ) +insert OID = 2551 ( "+" 11 10 b f f 1186 1082 1114 1076 0 interval_pl_date - - ) +insert OID = 2552 ( "+" 11 10 b f f 1186 1266 1266 1802 0 interval_pl_timetz - - ) +insert OID = 2553 ( "+" 11 10 b f f 1186 1114 1114 2066 0 interval_pl_timestamp - - ) +insert OID = 2554 ( "+" 11 10 b f f 1186 1184 1184 1327 0 interval_pl_timestamptz - - ) +insert OID = 2555 ( "+" 11 10 b f f 23 1082 1082 1100 0 integer_pl_date - - ) +insert OID = 2570 ( "<<|" 11 10 b f f 603 603 16 0 0 box_below positionsel positionjoinsel ) +insert OID = 2571 ( "&<|" 11 10 b f f 603 603 16 0 0 box_overbelow positionsel positionjoinsel ) +insert OID = 2572 ( "|&>" 11 10 b f f 603 603 16 0 0 box_overabove positionsel positionjoinsel ) +insert OID = 2573 ( "|>>" 11 10 b f f 603 603 16 0 0 box_above positionsel positionjoinsel ) +insert OID = 2574 ( "<<|" 11 10 b f f 604 604 16 0 0 poly_below positionsel positionjoinsel ) +insert OID = 2575 ( "&<|" 11 10 b f f 604 604 16 0 0 poly_overbelow positionsel positionjoinsel ) +insert OID = 2576 ( "|&>" 11 10 b f f 604 604 16 0 0 poly_overabove positionsel positionjoinsel ) +insert OID = 2577 ( "|>>" 11 10 b f f 604 604 16 0 0 poly_above positionsel positionjoinsel ) +insert OID = 2589 ( "&<|" 11 10 b f f 718 718 16 0 0 circle_overbelow positionsel positionjoinsel ) +insert OID = 2590 ( "|&>" 11 10 b f f 718 718 16 0 0 circle_overabove positionsel positionjoinsel ) +insert OID = 2750 ( "&&" 11 10 b f f 2277 2277 16 2750 0 arrayoverlap arraycontsel arraycontjoinsel ) +insert OID = 2751 ( "@>" 11 10 b f f 2277 2277 16 2752 0 arraycontains arraycontsel arraycontjoinsel ) +insert OID = 2752 ( "<@" 11 10 b f f 2277 2277 16 2751 0 arraycontained arraycontsel arraycontjoinsel ) +insert OID = 2779 ( "||" 11 10 b f f 25 2776 25 0 0 textanycat - - ) +insert OID = 2780 ( "||" 11 10 b f f 2776 25 25 0 0 anytextcat - - ) +insert OID = 2860 ( "@" 11 10 b f f 604 604 16 2861 0 poly_contained contsel contjoinsel ) +insert OID = 2861 ( "~" 11 10 b f f 604 604 16 2860 0 poly_contain contsel contjoinsel ) +insert OID = 2862 ( "@" 11 10 b f f 603 603 16 2863 0 box_contained contsel contjoinsel ) +insert OID = 2863 ( "~" 11 10 b f f 603 603 16 2862 0 box_contain contsel contjoinsel ) +insert OID = 2864 ( "@" 11 10 b f f 718 718 16 2865 0 circle_contained contsel contjoinsel ) +insert OID = 2865 ( "~" 11 10 b f f 718 718 16 2864 0 circle_contain contsel contjoinsel ) +insert OID = 2866 ( "@" 11 10 b f f 600 603 16 0 0 on_pb - - ) +insert OID = 2867 ( "@" 11 10 b f f 600 602 16 2868 0 on_ppath - - ) +insert OID = 2868 ( "~" 11 10 b f f 602 600 16 2867 0 path_contain_pt - - ) +insert OID = 2869 ( "@" 11 10 b f f 600 604 16 2870 0 pt_contained_poly - - ) +insert OID = 2870 ( "~" 11 10 b f f 604 600 16 2869 0 poly_contain_pt - - ) +insert OID = 2871 ( "@" 11 10 b f f 600 718 16 2872 0 pt_contained_circle - - ) +insert OID = 2872 ( "~" 11 10 b f f 718 600 16 2871 0 circle_contain_pt - - ) +insert OID = 2873 ( "@" 11 10 b f f 600 628 16 0 0 on_pl - - ) +insert OID = 2874 ( "@" 11 10 b f f 600 601 16 0 0 on_ps - - ) +insert OID = 2875 ( "@" 11 10 b f f 601 628 16 0 0 on_sl - - ) +insert OID = 2876 ( "@" 11 10 b f f 601 603 16 0 0 on_sb - - ) +insert OID = 2877 ( "~" 11 10 b f f 1034 1033 16 0 0 aclcontains - - ) +insert OID = 2972 ( "=" 11 10 b t t 2950 2950 16 2972 2973 uuid_eq eqsel eqjoinsel ) +insert OID = 2973 ( "<>" 11 10 b f f 2950 2950 16 2973 2972 uuid_ne neqsel neqjoinsel ) +insert OID = 2974 ( "<" 11 10 b f f 2950 2950 16 2975 2977 uuid_lt scalarltsel scalarltjoinsel ) +insert OID = 2975 ( ">" 11 10 b f f 2950 2950 16 2974 2976 uuid_gt scalargtsel scalargtjoinsel ) +insert OID = 2976 ( "<=" 11 10 b f f 2950 2950 16 2977 2975 uuid_le scalarltsel scalarltjoinsel ) +insert OID = 2977 ( ">=" 11 10 b f f 2950 2950 16 2976 2974 uuid_ge scalargtsel scalargtjoinsel ) +insert OID = 3516 ( "=" 11 10 b t t 3500 3500 16 3516 3517 enum_eq eqsel eqjoinsel ) +insert OID = 3517 ( "<>" 11 10 b f f 3500 3500 16 3517 3516 enum_ne neqsel neqjoinsel ) +insert OID = 3518 ( "<" 11 10 b f f 3500 3500 16 3519 3521 enum_lt scalarltsel scalarltjoinsel ) +insert OID = 3519 ( ">" 11 10 b f f 3500 3500 16 3518 3520 enum_gt scalargtsel scalargtjoinsel ) +insert OID = 3520 ( "<=" 11 10 b f f 3500 3500 16 3521 3519 enum_le scalarltsel scalarltjoinsel ) +insert OID = 3521 ( ">=" 11 10 b f f 3500 3500 16 3520 3518 enum_ge scalargtsel scalargtjoinsel ) +insert OID = 3627 ( "<" 11 10 b f f 3614 3614 16 3632 3631 tsvector_lt scalarltsel scalarltjoinsel ) +insert OID = 3628 ( "<=" 11 10 b f f 3614 3614 16 3631 3632 tsvector_le scalarltsel scalarltjoinsel ) +insert OID = 3629 ( "=" 11 10 b t f 3614 3614 16 3629 3630 tsvector_eq eqsel eqjoinsel ) +insert OID = 3630 ( "<>" 11 10 b f f 3614 3614 16 3630 3629 tsvector_ne neqsel neqjoinsel ) +insert OID = 3631 ( ">=" 11 10 b f f 3614 3614 16 3628 3627 tsvector_ge scalargtsel scalargtjoinsel ) +insert OID = 3632 ( ">" 11 10 b f f 3614 3614 16 3627 3628 tsvector_gt scalargtsel scalargtjoinsel ) +insert OID = 3633 ( "||" 11 10 b f f 3614 3614 3614 0 0 tsvector_concat - - ) +insert OID = 3636 ( "@@" 11 10 b f f 3614 3615 16 3637 0 ts_match_vq tsmatchsel tsmatchjoinsel ) +insert OID = 3637 ( "@@" 11 10 b f f 3615 3614 16 3636 0 ts_match_qv tsmatchsel tsmatchjoinsel ) +insert OID = 3660 ( "@@@" 11 10 b f f 3614 3615 16 3661 0 ts_match_vq tsmatchsel tsmatchjoinsel ) +insert OID = 3661 ( "@@@" 11 10 b f f 3615 3614 16 3660 0 ts_match_qv tsmatchsel tsmatchjoinsel ) +insert OID = 3674 ( "<" 11 10 b f f 3615 3615 16 3679 3678 tsquery_lt scalarltsel scalarltjoinsel ) +insert OID = 3675 ( "<=" 11 10 b f f 3615 3615 16 3678 3679 tsquery_le scalarltsel scalarltjoinsel ) +insert OID = 3676 ( "=" 11 10 b t f 3615 3615 16 3676 3677 tsquery_eq eqsel eqjoinsel ) +insert OID = 3677 ( "<>" 11 10 b f f 3615 3615 16 3677 3676 tsquery_ne neqsel neqjoinsel ) +insert OID = 3678 ( ">=" 11 10 b f f 3615 3615 16 3675 3674 tsquery_ge scalargtsel scalargtjoinsel ) +insert OID = 3679 ( ">" 11 10 b f f 3615 3615 16 3674 3675 tsquery_gt scalargtsel scalargtjoinsel ) +insert OID = 3680 ( "&&" 11 10 b f f 3615 3615 3615 0 0 tsquery_and - - ) +insert OID = 3681 ( "||" 11 10 b f f 3615 3615 3615 0 0 tsquery_or - - ) +insert OID = 3682 ( "!!" 11 10 l f f 0 3615 3615 0 0 tsquery_not - - ) +insert OID = 3693 ( "@>" 11 10 b f f 3615 3615 16 3694 0 tsq_mcontains contsel contjoinsel ) +insert OID = 3694 ( "<@" 11 10 b f f 3615 3615 16 3693 0 tsq_mcontained contsel contjoinsel ) +insert OID = 3762 ( "@@" 11 10 b f f 25 25 16 0 0 ts_match_tt contsel contjoinsel ) +insert OID = 3763 ( "@@" 11 10 b f f 25 3615 16 0 0 ts_match_tq contsel contjoinsel ) +insert OID = 2988 ( "=" 11 10 b t f 2249 2249 16 2988 2989 record_eq eqsel eqjoinsel ) +insert OID = 2989 ( "<>" 11 10 b f f 2249 2249 16 2989 2988 record_ne neqsel neqjoinsel ) +insert OID = 2990 ( "<" 11 10 b f f 2249 2249 16 2991 2993 record_lt scalarltsel scalarltjoinsel ) +insert OID = 2991 ( ">" 11 10 b f f 2249 2249 16 2990 2992 record_gt scalargtsel scalargtjoinsel ) +insert OID = 2992 ( "<=" 11 10 b f f 2249 2249 16 2993 2991 record_le scalarltsel scalarltjoinsel ) +insert OID = 2993 ( ">=" 11 10 b f f 2249 2249 16 2992 2990 record_ge scalargtsel scalargtjoinsel ) +insert OID = 3882 ( "=" 11 10 b t t 3831 3831 16 3882 3883 range_eq eqsel eqjoinsel ) +insert OID = 3883 ( "<>" 11 10 b f f 3831 3831 16 3883 3882 range_ne neqsel neqjoinsel ) +insert OID = 3884 ( "<" 11 10 b f f 3831 3831 16 3887 3886 range_lt scalarltsel scalarltjoinsel ) +insert OID = 3885 ( "<=" 11 10 b f f 3831 3831 16 3886 3887 range_le scalarltsel scalarltjoinsel ) +insert OID = 3886 ( ">=" 11 10 b f f 3831 3831 16 3885 3884 range_ge scalargtsel scalargtjoinsel ) +insert OID = 3887 ( ">" 11 10 b f f 3831 3831 16 3884 3885 range_gt scalargtsel scalargtjoinsel ) +insert OID = 3888 ( "&&" 11 10 b f f 3831 3831 16 3888 0 range_overlaps areasel areajoinsel ) +insert OID = 3889 ( "@>" 11 10 b f f 3831 2283 16 3891 0 range_contains_elem contsel contjoinsel ) +insert OID = 3890 ( "@>" 11 10 b f f 3831 3831 16 3892 0 range_contains contsel contjoinsel ) +insert OID = 3891 ( "<@" 11 10 b f f 2283 3831 16 3889 0 elem_contained_by_range contsel contjoinsel ) +insert OID = 3892 ( "<@" 11 10 b f f 3831 3831 16 3890 0 range_contained_by contsel contjoinsel ) +insert OID = 3893 ( "<<" 11 10 b f f 3831 3831 16 3894 0 range_before scalarltsel scalarltjoinsel ) +insert OID = 3894 ( ">>" 11 10 b f f 3831 3831 16 3893 0 range_after scalargtsel scalargtjoinsel ) +insert OID = 3895 ( "&<" 11 10 b f f 3831 3831 16 0 0 range_overleft scalarltsel scalarltjoinsel ) +insert OID = 3896 ( "&>" 11 10 b f f 3831 3831 16 0 0 range_overright scalargtsel scalargtjoinsel ) +insert OID = 3897 ( "-|-" 11 10 b f f 3831 3831 16 3897 0 range_adjacent contsel contjoinsel ) +insert OID = 3898 ( "+" 11 10 b f f 3831 3831 3831 3898 0 range_union - - ) +insert OID = 3899 ( "-" 11 10 b f f 3831 3831 3831 0 0 range_minus - - ) +insert OID = 3900 ( "*" 11 10 b f f 3831 3831 3831 3900 0 range_intersect - - ) +close pg_operator +create pg_opfamily 2753 + ( + opfmethod = oid , + opfname = name , + opfnamespace = oid , + opfowner = oid + ) +open pg_opfamily +insert OID = 421 ( 403 abstime_ops 11 10 ) +insert OID = 397 ( 403 array_ops 11 10 ) +insert OID = 627 ( 405 array_ops 11 10 ) +insert OID = 423 ( 403 bit_ops 11 10 ) +insert OID = 424 ( 403 bool_ops 11 10 ) +insert OID = 426 ( 403 bpchar_ops 11 10 ) +insert OID = 427 ( 405 bpchar_ops 11 10 ) +insert OID = 428 ( 403 bytea_ops 11 10 ) +insert OID = 429 ( 403 char_ops 11 10 ) +insert OID = 431 ( 405 char_ops 11 10 ) +insert OID = 434 ( 403 datetime_ops 11 10 ) +insert OID = 435 ( 405 date_ops 11 10 ) +insert OID = 1970 ( 403 float_ops 11 10 ) +insert OID = 1971 ( 405 float_ops 11 10 ) +insert OID = 1974 ( 403 network_ops 11 10 ) +insert OID = 1975 ( 405 network_ops 11 10 ) +insert OID = 1976 ( 403 integer_ops 11 10 ) +insert OID = 1977 ( 405 integer_ops 11 10 ) +insert OID = 1982 ( 403 interval_ops 11 10 ) +insert OID = 1983 ( 405 interval_ops 11 10 ) +insert OID = 1984 ( 403 macaddr_ops 11 10 ) +insert OID = 1985 ( 405 macaddr_ops 11 10 ) +insert OID = 1986 ( 403 name_ops 11 10 ) +insert OID = 1987 ( 405 name_ops 11 10 ) +insert OID = 1988 ( 403 numeric_ops 11 10 ) +insert OID = 1998 ( 405 numeric_ops 11 10 ) +insert OID = 1989 ( 403 oid_ops 11 10 ) +insert OID = 1990 ( 405 oid_ops 11 10 ) +insert OID = 1991 ( 403 oidvector_ops 11 10 ) +insert OID = 1992 ( 405 oidvector_ops 11 10 ) +insert OID = 2994 ( 403 record_ops 11 10 ) +insert OID = 1994 ( 403 text_ops 11 10 ) +insert OID = 1995 ( 405 text_ops 11 10 ) +insert OID = 1996 ( 403 time_ops 11 10 ) +insert OID = 1997 ( 405 time_ops 11 10 ) +insert OID = 1999 ( 405 timestamptz_ops 11 10 ) +insert OID = 2000 ( 403 timetz_ops 11 10 ) +insert OID = 2001 ( 405 timetz_ops 11 10 ) +insert OID = 2002 ( 403 varbit_ops 11 10 ) +insert OID = 2040 ( 405 timestamp_ops 11 10 ) +insert OID = 2095 ( 403 text_pattern_ops 11 10 ) +insert OID = 2097 ( 403 bpchar_pattern_ops 11 10 ) +insert OID = 2099 ( 403 money_ops 11 10 ) +insert OID = 2222 ( 405 bool_ops 11 10 ) +insert OID = 2223 ( 405 bytea_ops 11 10 ) +insert OID = 2224 ( 405 int2vector_ops 11 10 ) +insert OID = 2789 ( 403 tid_ops 11 10 ) +insert OID = 2225 ( 405 xid_ops 11 10 ) +insert OID = 2226 ( 405 cid_ops 11 10 ) +insert OID = 2227 ( 405 abstime_ops 11 10 ) +insert OID = 2228 ( 405 reltime_ops 11 10 ) +insert OID = 2229 ( 405 text_pattern_ops 11 10 ) +insert OID = 2231 ( 405 bpchar_pattern_ops 11 10 ) +insert OID = 2233 ( 403 reltime_ops 11 10 ) +insert OID = 2234 ( 403 tinterval_ops 11 10 ) +insert OID = 2235 ( 405 aclitem_ops 11 10 ) +insert OID = 2593 ( 783 box_ops 11 10 ) +insert OID = 2594 ( 783 poly_ops 11 10 ) +insert OID = 2595 ( 783 circle_ops 11 10 ) +insert OID = 1029 ( 783 point_ops 11 10 ) +insert OID = 2745 ( 2742 array_ops 11 10 ) +insert OID = 2968 ( 403 uuid_ops 11 10 ) +insert OID = 2969 ( 405 uuid_ops 11 10 ) +insert OID = 3522 ( 403 enum_ops 11 10 ) +insert OID = 3523 ( 405 enum_ops 11 10 ) +insert OID = 3626 ( 403 tsvector_ops 11 10 ) +insert OID = 3655 ( 783 tsvector_ops 11 10 ) +insert OID = 3659 ( 2742 tsvector_ops 11 10 ) +insert OID = 3683 ( 403 tsquery_ops 11 10 ) +insert OID = 3702 ( 783 tsquery_ops 11 10 ) +insert OID = 3901 ( 403 range_ops 11 10 ) +insert OID = 3903 ( 405 range_ops 11 10 ) +insert OID = 3919 ( 783 range_ops 11 10 ) +insert OID = 4015 ( 4000 quad_point_ops 11 10 ) +insert OID = 4016 ( 4000 kd_point_ops 11 10 ) +insert OID = 4017 ( 4000 text_ops 11 10 ) +close pg_opfamily +create pg_opclass 2616 + ( + opcmethod = oid , + opcname = name , + opcnamespace = oid , + opcowner = oid , + opcfamily = oid , + opcintype = oid , + opcdefault = bool , + opckeytype = oid + ) +open pg_opclass +insert ( 403 abstime_ops 11 10 421 702 t 0 ) +insert ( 403 array_ops 11 10 397 2277 t 0 ) +insert ( 405 array_ops 11 10 627 2277 t 0 ) +insert ( 403 bit_ops 11 10 423 1560 t 0 ) +insert ( 403 bool_ops 11 10 424 16 t 0 ) +insert ( 403 bpchar_ops 11 10 426 1042 t 0 ) +insert ( 405 bpchar_ops 11 10 427 1042 t 0 ) +insert ( 403 bytea_ops 11 10 428 17 t 0 ) +insert ( 403 char_ops 11 10 429 18 t 0 ) +insert ( 405 char_ops 11 10 431 18 t 0 ) +insert ( 403 cidr_ops 11 10 1974 869 f 0 ) +insert ( 405 cidr_ops 11 10 1975 869 f 0 ) +insert OID = 3122 ( 403 date_ops 11 10 434 1082 t 0 ) +insert ( 405 date_ops 11 10 435 1082 t 0 ) +insert ( 403 float4_ops 11 10 1970 700 t 0 ) +insert ( 405 float4_ops 11 10 1971 700 t 0 ) +insert OID = 3123 ( 403 float8_ops 11 10 1970 701 t 0 ) +insert ( 405 float8_ops 11 10 1971 701 t 0 ) +insert ( 403 inet_ops 11 10 1974 869 t 0 ) +insert ( 405 inet_ops 11 10 1975 869 t 0 ) +insert OID = 1979 ( 403 int2_ops 11 10 1976 21 t 0 ) +insert ( 405 int2_ops 11 10 1977 21 t 0 ) +insert OID = 1978 ( 403 int4_ops 11 10 1976 23 t 0 ) +insert ( 405 int4_ops 11 10 1977 23 t 0 ) +insert OID = 3124 ( 403 int8_ops 11 10 1976 20 t 0 ) +insert ( 405 int8_ops 11 10 1977 20 t 0 ) +insert ( 403 interval_ops 11 10 1982 1186 t 0 ) +insert ( 405 interval_ops 11 10 1983 1186 t 0 ) +insert ( 403 macaddr_ops 11 10 1984 829 t 0 ) +insert ( 405 macaddr_ops 11 10 1985 829 t 0 ) +insert ( 403 name_ops 11 10 1986 19 t 2275 ) +insert ( 405 name_ops 11 10 1987 19 t 0 ) +insert OID = 3125 ( 403 numeric_ops 11 10 1988 1700 t 0 ) +insert ( 405 numeric_ops 11 10 1998 1700 t 0 ) +insert OID = 1981 ( 403 oid_ops 11 10 1989 26 t 0 ) +insert ( 405 oid_ops 11 10 1990 26 t 0 ) +insert ( 403 oidvector_ops 11 10 1991 30 t 0 ) +insert ( 405 oidvector_ops 11 10 1992 30 t 0 ) +insert ( 403 record_ops 11 10 2994 2249 t 0 ) +insert OID = 3126 ( 403 text_ops 11 10 1994 25 t 0 ) +insert ( 405 text_ops 11 10 1995 25 t 0 ) +insert ( 403 time_ops 11 10 1996 1083 t 0 ) +insert ( 405 time_ops 11 10 1997 1083 t 0 ) +insert OID = 3127 ( 403 timestamptz_ops 11 10 434 1184 t 0 ) +insert ( 405 timestamptz_ops 11 10 1999 1184 t 0 ) +insert ( 403 timetz_ops 11 10 2000 1266 t 0 ) +insert ( 405 timetz_ops 11 10 2001 1266 t 0 ) +insert ( 403 varbit_ops 11 10 2002 1562 t 0 ) +insert ( 403 varchar_ops 11 10 1994 25 f 0 ) +insert ( 405 varchar_ops 11 10 1995 25 f 0 ) +insert OID = 3128 ( 403 timestamp_ops 11 10 434 1114 t 0 ) +insert ( 405 timestamp_ops 11 10 2040 1114 t 0 ) +insert ( 403 text_pattern_ops 11 10 2095 25 f 0 ) +insert ( 403 varchar_pattern_ops 11 10 2095 25 f 0 ) +insert ( 403 bpchar_pattern_ops 11 10 2097 1042 f 0 ) +insert ( 403 money_ops 11 10 2099 790 t 0 ) +insert ( 405 bool_ops 11 10 2222 16 t 0 ) +insert ( 405 bytea_ops 11 10 2223 17 t 0 ) +insert ( 405 int2vector_ops 11 10 2224 22 t 0 ) +insert ( 403 tid_ops 11 10 2789 27 t 0 ) +insert ( 405 xid_ops 11 10 2225 28 t 0 ) +insert ( 405 cid_ops 11 10 2226 29 t 0 ) +insert ( 405 abstime_ops 11 10 2227 702 t 0 ) +insert ( 405 reltime_ops 11 10 2228 703 t 0 ) +insert ( 405 text_pattern_ops 11 10 2229 25 f 0 ) +insert ( 405 varchar_pattern_ops 11 10 2229 25 f 0 ) +insert ( 405 bpchar_pattern_ops 11 10 2231 1042 f 0 ) +insert ( 403 reltime_ops 11 10 2233 703 t 0 ) +insert ( 403 tinterval_ops 11 10 2234 704 t 0 ) +insert ( 405 aclitem_ops 11 10 2235 1033 t 0 ) +insert ( 783 box_ops 11 10 2593 603 t 0 ) +insert ( 783 point_ops 11 10 1029 600 t 603 ) +insert ( 783 poly_ops 11 10 2594 604 t 603 ) +insert ( 783 circle_ops 11 10 2595 718 t 603 ) +insert ( 2742 _int4_ops 11 10 2745 1007 t 23 ) +insert ( 2742 _text_ops 11 10 2745 1009 t 25 ) +insert ( 2742 _abstime_ops 11 10 2745 1023 t 702 ) +insert ( 2742 _bit_ops 11 10 2745 1561 t 1560 ) +insert ( 2742 _bool_ops 11 10 2745 1000 t 16 ) +insert ( 2742 _bpchar_ops 11 10 2745 1014 t 1042 ) +insert ( 2742 _bytea_ops 11 10 2745 1001 t 17 ) +insert ( 2742 _char_ops 11 10 2745 1002 t 18 ) +insert ( 2742 _cidr_ops 11 10 2745 651 t 650 ) +insert ( 2742 _date_ops 11 10 2745 1182 t 1082 ) +insert ( 2742 _float4_ops 11 10 2745 1021 t 700 ) +insert ( 2742 _float8_ops 11 10 2745 1022 t 701 ) +insert ( 2742 _inet_ops 11 10 2745 1041 t 869 ) +insert ( 2742 _int2_ops 11 10 2745 1005 t 21 ) +insert ( 2742 _int8_ops 11 10 2745 1016 t 20 ) +insert ( 2742 _interval_ops 11 10 2745 1187 t 1186 ) +insert ( 2742 _macaddr_ops 11 10 2745 1040 t 829 ) +insert ( 2742 _name_ops 11 10 2745 1003 t 19 ) +insert ( 2742 _numeric_ops 11 10 2745 1231 t 1700 ) +insert ( 2742 _oid_ops 11 10 2745 1028 t 26 ) +insert ( 2742 _oidvector_ops 11 10 2745 1013 t 30 ) +insert ( 2742 _time_ops 11 10 2745 1183 t 1083 ) +insert ( 2742 _timestamptz_ops 11 10 2745 1185 t 1184 ) +insert ( 2742 _timetz_ops 11 10 2745 1270 t 1266 ) +insert ( 2742 _varbit_ops 11 10 2745 1563 t 1562 ) +insert ( 2742 _varchar_ops 11 10 2745 1015 t 1043 ) +insert ( 2742 _timestamp_ops 11 10 2745 1115 t 1114 ) +insert ( 2742 _money_ops 11 10 2745 791 t 790 ) +insert ( 2742 _reltime_ops 11 10 2745 1024 t 703 ) +insert ( 2742 _tinterval_ops 11 10 2745 1025 t 704 ) +insert ( 403 uuid_ops 11 10 2968 2950 t 0 ) +insert ( 405 uuid_ops 11 10 2969 2950 t 0 ) +insert ( 403 enum_ops 11 10 3522 3500 t 0 ) +insert ( 405 enum_ops 11 10 3523 3500 t 0 ) +insert ( 403 tsvector_ops 11 10 3626 3614 t 0 ) +insert ( 783 tsvector_ops 11 10 3655 3614 t 3642 ) +insert ( 2742 tsvector_ops 11 10 3659 3614 t 25 ) +insert ( 403 tsquery_ops 11 10 3683 3615 t 0 ) +insert ( 783 tsquery_ops 11 10 3702 3615 t 20 ) +insert ( 403 range_ops 11 10 3901 3831 t 0 ) +insert ( 405 range_ops 11 10 3903 3831 t 0 ) +insert ( 783 range_ops 11 10 3919 3831 t 0 ) +insert ( 4000 quad_point_ops 11 10 4015 600 t 0 ) +insert ( 4000 kd_point_ops 11 10 4016 600 f 0 ) +insert ( 4000 text_ops 11 10 4017 25 t 0 ) +close pg_opclass +create pg_am 2601 + ( + amname = name , + amstrategies = int2 , + amsupport = int2 , + amcanorder = bool , + amcanorderbyop = bool , + amcanbackward = bool , + amcanunique = bool , + amcanmulticol = bool , + amoptionalkey = bool , + amsearcharray = bool , + amsearchnulls = bool , + amstorage = bool , + amclusterable = bool , + ampredlocks = bool , + amkeytype = oid , + aminsert = regproc , + ambeginscan = regproc , + amgettuple = regproc , + amgetbitmap = regproc , + amrescan = regproc , + amendscan = regproc , + ammarkpos = regproc , + amrestrpos = regproc , + ambuild = regproc , + ambuildempty = regproc , + ambulkdelete = regproc , + amvacuumcleanup = regproc , + amcanreturn = regproc , + amcostestimate = regproc , + amoptions = regproc + ) +open pg_am +insert OID = 403 ( btree 5 2 t f t t t t t t f t t 0 btinsert btbeginscan btgettuple btgetbitmap btrescan btendscan btmarkpos btrestrpos btbuild btbuildempty btbulkdelete btvacuumcleanup btcanreturn btcostestimate btoptions ) +insert OID = 405 ( hash 1 1 f f t f f f f f f f f 23 hashinsert hashbeginscan hashgettuple hashgetbitmap hashrescan hashendscan hashmarkpos hashrestrpos hashbuild hashbuildempty hashbulkdelete hashvacuumcleanup - hashcostestimate hashoptions ) +insert OID = 783 ( gist 0 8 f t f f t t f t t t f 0 gistinsert gistbeginscan gistgettuple gistgetbitmap gistrescan gistendscan gistmarkpos gistrestrpos gistbuild gistbuildempty gistbulkdelete gistvacuumcleanup - gistcostestimate gistoptions ) +insert OID = 2742 ( gin 0 5 f f f f t t f f t f f 0 gininsert ginbeginscan - gingetbitmap ginrescan ginendscan ginmarkpos ginrestrpos ginbuild ginbuildempty ginbulkdelete ginvacuumcleanup - gincostestimate ginoptions ) +insert OID = 4000 ( spgist 0 5 f f f f f t f t f f f 0 spginsert spgbeginscan spggettuple spggetbitmap spgrescan spgendscan spgmarkpos spgrestrpos spgbuild spgbuildempty spgbulkdelete spgvacuumcleanup spgcanreturn spgcostestimate spgoptions ) +close pg_am +create pg_amop 2602 + ( + amopfamily = oid , + amoplefttype = oid , + amoprighttype = oid , + amopstrategy = int2 , + amoppurpose = char , + amopopr = oid , + amopmethod = oid , + amopsortfamily = oid + ) +open pg_amop +insert ( 1976 21 21 1 s 95 403 0 ) +insert ( 1976 21 21 2 s 522 403 0 ) +insert ( 1976 21 21 3 s 94 403 0 ) +insert ( 1976 21 21 4 s 524 403 0 ) +insert ( 1976 21 21 5 s 520 403 0 ) +insert ( 1976 21 23 1 s 534 403 0 ) +insert ( 1976 21 23 2 s 540 403 0 ) +insert ( 1976 21 23 3 s 532 403 0 ) +insert ( 1976 21 23 4 s 542 403 0 ) +insert ( 1976 21 23 5 s 536 403 0 ) +insert ( 1976 21 20 1 s 1864 403 0 ) +insert ( 1976 21 20 2 s 1866 403 0 ) +insert ( 1976 21 20 3 s 1862 403 0 ) +insert ( 1976 21 20 4 s 1867 403 0 ) +insert ( 1976 21 20 5 s 1865 403 0 ) +insert ( 1976 23 23 1 s 97 403 0 ) +insert ( 1976 23 23 2 s 523 403 0 ) +insert ( 1976 23 23 3 s 96 403 0 ) +insert ( 1976 23 23 4 s 525 403 0 ) +insert ( 1976 23 23 5 s 521 403 0 ) +insert ( 1976 23 21 1 s 535 403 0 ) +insert ( 1976 23 21 2 s 541 403 0 ) +insert ( 1976 23 21 3 s 533 403 0 ) +insert ( 1976 23 21 4 s 543 403 0 ) +insert ( 1976 23 21 5 s 537 403 0 ) +insert ( 1976 23 20 1 s 37 403 0 ) +insert ( 1976 23 20 2 s 80 403 0 ) +insert ( 1976 23 20 3 s 15 403 0 ) +insert ( 1976 23 20 4 s 82 403 0 ) +insert ( 1976 23 20 5 s 76 403 0 ) +insert ( 1976 20 20 1 s 412 403 0 ) +insert ( 1976 20 20 2 s 414 403 0 ) +insert ( 1976 20 20 3 s 410 403 0 ) +insert ( 1976 20 20 4 s 415 403 0 ) +insert ( 1976 20 20 5 s 413 403 0 ) +insert ( 1976 20 21 1 s 1870 403 0 ) +insert ( 1976 20 21 2 s 1872 403 0 ) +insert ( 1976 20 21 3 s 1868 403 0 ) +insert ( 1976 20 21 4 s 1873 403 0 ) +insert ( 1976 20 21 5 s 1871 403 0 ) +insert ( 1976 20 23 1 s 418 403 0 ) +insert ( 1976 20 23 2 s 420 403 0 ) +insert ( 1976 20 23 3 s 416 403 0 ) +insert ( 1976 20 23 4 s 430 403 0 ) +insert ( 1976 20 23 5 s 419 403 0 ) +insert ( 1989 26 26 1 s 609 403 0 ) +insert ( 1989 26 26 2 s 611 403 0 ) +insert ( 1989 26 26 3 s 607 403 0 ) +insert ( 1989 26 26 4 s 612 403 0 ) +insert ( 1989 26 26 5 s 610 403 0 ) +insert ( 2789 27 27 1 s 2799 403 0 ) +insert ( 2789 27 27 2 s 2801 403 0 ) +insert ( 2789 27 27 3 s 387 403 0 ) +insert ( 2789 27 27 4 s 2802 403 0 ) +insert ( 2789 27 27 5 s 2800 403 0 ) +insert ( 1991 30 30 1 s 645 403 0 ) +insert ( 1991 30 30 2 s 647 403 0 ) +insert ( 1991 30 30 3 s 649 403 0 ) +insert ( 1991 30 30 4 s 648 403 0 ) +insert ( 1991 30 30 5 s 646 403 0 ) +insert ( 1970 700 700 1 s 622 403 0 ) +insert ( 1970 700 700 2 s 624 403 0 ) +insert ( 1970 700 700 3 s 620 403 0 ) +insert ( 1970 700 700 4 s 625 403 0 ) +insert ( 1970 700 700 5 s 623 403 0 ) +insert ( 1970 700 701 1 s 1122 403 0 ) +insert ( 1970 700 701 2 s 1124 403 0 ) +insert ( 1970 700 701 3 s 1120 403 0 ) +insert ( 1970 700 701 4 s 1125 403 0 ) +insert ( 1970 700 701 5 s 1123 403 0 ) +insert ( 1970 701 701 1 s 672 403 0 ) +insert ( 1970 701 701 2 s 673 403 0 ) +insert ( 1970 701 701 3 s 670 403 0 ) +insert ( 1970 701 701 4 s 675 403 0 ) +insert ( 1970 701 701 5 s 674 403 0 ) +insert ( 1970 701 700 1 s 1132 403 0 ) +insert ( 1970 701 700 2 s 1134 403 0 ) +insert ( 1970 701 700 3 s 1130 403 0 ) +insert ( 1970 701 700 4 s 1135 403 0 ) +insert ( 1970 701 700 5 s 1133 403 0 ) +insert ( 429 18 18 1 s 631 403 0 ) +insert ( 429 18 18 2 s 632 403 0 ) +insert ( 429 18 18 3 s 92 403 0 ) +insert ( 429 18 18 4 s 634 403 0 ) +insert ( 429 18 18 5 s 633 403 0 ) +insert ( 1986 19 19 1 s 660 403 0 ) +insert ( 1986 19 19 2 s 661 403 0 ) +insert ( 1986 19 19 3 s 93 403 0 ) +insert ( 1986 19 19 4 s 663 403 0 ) +insert ( 1986 19 19 5 s 662 403 0 ) +insert ( 1994 25 25 1 s 664 403 0 ) +insert ( 1994 25 25 2 s 665 403 0 ) +insert ( 1994 25 25 3 s 98 403 0 ) +insert ( 1994 25 25 4 s 667 403 0 ) +insert ( 1994 25 25 5 s 666 403 0 ) +insert ( 426 1042 1042 1 s 1058 403 0 ) +insert ( 426 1042 1042 2 s 1059 403 0 ) +insert ( 426 1042 1042 3 s 1054 403 0 ) +insert ( 426 1042 1042 4 s 1061 403 0 ) +insert ( 426 1042 1042 5 s 1060 403 0 ) +insert ( 428 17 17 1 s 1957 403 0 ) +insert ( 428 17 17 2 s 1958 403 0 ) +insert ( 428 17 17 3 s 1955 403 0 ) +insert ( 428 17 17 4 s 1960 403 0 ) +insert ( 428 17 17 5 s 1959 403 0 ) +insert ( 421 702 702 1 s 562 403 0 ) +insert ( 421 702 702 2 s 564 403 0 ) +insert ( 421 702 702 3 s 560 403 0 ) +insert ( 421 702 702 4 s 565 403 0 ) +insert ( 421 702 702 5 s 563 403 0 ) +insert ( 434 1082 1082 1 s 1095 403 0 ) +insert ( 434 1082 1082 2 s 1096 403 0 ) +insert ( 434 1082 1082 3 s 1093 403 0 ) +insert ( 434 1082 1082 4 s 1098 403 0 ) +insert ( 434 1082 1082 5 s 1097 403 0 ) +insert ( 434 1082 1114 1 s 2345 403 0 ) +insert ( 434 1082 1114 2 s 2346 403 0 ) +insert ( 434 1082 1114 3 s 2347 403 0 ) +insert ( 434 1082 1114 4 s 2348 403 0 ) +insert ( 434 1082 1114 5 s 2349 403 0 ) +insert ( 434 1082 1184 1 s 2358 403 0 ) +insert ( 434 1082 1184 2 s 2359 403 0 ) +insert ( 434 1082 1184 3 s 2360 403 0 ) +insert ( 434 1082 1184 4 s 2361 403 0 ) +insert ( 434 1082 1184 5 s 2362 403 0 ) +insert ( 434 1114 1114 1 s 2062 403 0 ) +insert ( 434 1114 1114 2 s 2063 403 0 ) +insert ( 434 1114 1114 3 s 2060 403 0 ) +insert ( 434 1114 1114 4 s 2065 403 0 ) +insert ( 434 1114 1114 5 s 2064 403 0 ) +insert ( 434 1114 1082 1 s 2371 403 0 ) +insert ( 434 1114 1082 2 s 2372 403 0 ) +insert ( 434 1114 1082 3 s 2373 403 0 ) +insert ( 434 1114 1082 4 s 2374 403 0 ) +insert ( 434 1114 1082 5 s 2375 403 0 ) +insert ( 434 1114 1184 1 s 2534 403 0 ) +insert ( 434 1114 1184 2 s 2535 403 0 ) +insert ( 434 1114 1184 3 s 2536 403 0 ) +insert ( 434 1114 1184 4 s 2537 403 0 ) +insert ( 434 1114 1184 5 s 2538 403 0 ) +insert ( 434 1184 1184 1 s 1322 403 0 ) +insert ( 434 1184 1184 2 s 1323 403 0 ) +insert ( 434 1184 1184 3 s 1320 403 0 ) +insert ( 434 1184 1184 4 s 1325 403 0 ) +insert ( 434 1184 1184 5 s 1324 403 0 ) +insert ( 434 1184 1082 1 s 2384 403 0 ) +insert ( 434 1184 1082 2 s 2385 403 0 ) +insert ( 434 1184 1082 3 s 2386 403 0 ) +insert ( 434 1184 1082 4 s 2387 403 0 ) +insert ( 434 1184 1082 5 s 2388 403 0 ) +insert ( 434 1184 1114 1 s 2540 403 0 ) +insert ( 434 1184 1114 2 s 2541 403 0 ) +insert ( 434 1184 1114 3 s 2542 403 0 ) +insert ( 434 1184 1114 4 s 2543 403 0 ) +insert ( 434 1184 1114 5 s 2544 403 0 ) +insert ( 1996 1083 1083 1 s 1110 403 0 ) +insert ( 1996 1083 1083 2 s 1111 403 0 ) +insert ( 1996 1083 1083 3 s 1108 403 0 ) +insert ( 1996 1083 1083 4 s 1113 403 0 ) +insert ( 1996 1083 1083 5 s 1112 403 0 ) +insert ( 2000 1266 1266 1 s 1552 403 0 ) +insert ( 2000 1266 1266 2 s 1553 403 0 ) +insert ( 2000 1266 1266 3 s 1550 403 0 ) +insert ( 2000 1266 1266 4 s 1555 403 0 ) +insert ( 2000 1266 1266 5 s 1554 403 0 ) +insert ( 1982 1186 1186 1 s 1332 403 0 ) +insert ( 1982 1186 1186 2 s 1333 403 0 ) +insert ( 1982 1186 1186 3 s 1330 403 0 ) +insert ( 1982 1186 1186 4 s 1335 403 0 ) +insert ( 1982 1186 1186 5 s 1334 403 0 ) +insert ( 1984 829 829 1 s 1222 403 0 ) +insert ( 1984 829 829 2 s 1223 403 0 ) +insert ( 1984 829 829 3 s 1220 403 0 ) +insert ( 1984 829 829 4 s 1225 403 0 ) +insert ( 1984 829 829 5 s 1224 403 0 ) +insert ( 1974 869 869 1 s 1203 403 0 ) +insert ( 1974 869 869 2 s 1204 403 0 ) +insert ( 1974 869 869 3 s 1201 403 0 ) +insert ( 1974 869 869 4 s 1206 403 0 ) +insert ( 1974 869 869 5 s 1205 403 0 ) +insert ( 1988 1700 1700 1 s 1754 403 0 ) +insert ( 1988 1700 1700 2 s 1755 403 0 ) +insert ( 1988 1700 1700 3 s 1752 403 0 ) +insert ( 1988 1700 1700 4 s 1757 403 0 ) +insert ( 1988 1700 1700 5 s 1756 403 0 ) +insert ( 424 16 16 1 s 58 403 0 ) +insert ( 424 16 16 2 s 1694 403 0 ) +insert ( 424 16 16 3 s 91 403 0 ) +insert ( 424 16 16 4 s 1695 403 0 ) +insert ( 424 16 16 5 s 59 403 0 ) +insert ( 423 1560 1560 1 s 1786 403 0 ) +insert ( 423 1560 1560 2 s 1788 403 0 ) +insert ( 423 1560 1560 3 s 1784 403 0 ) +insert ( 423 1560 1560 4 s 1789 403 0 ) +insert ( 423 1560 1560 5 s 1787 403 0 ) +insert ( 2002 1562 1562 1 s 1806 403 0 ) +insert ( 2002 1562 1562 2 s 1808 403 0 ) +insert ( 2002 1562 1562 3 s 1804 403 0 ) +insert ( 2002 1562 1562 4 s 1809 403 0 ) +insert ( 2002 1562 1562 5 s 1807 403 0 ) +insert ( 2095 25 25 1 s 2314 403 0 ) +insert ( 2095 25 25 2 s 2315 403 0 ) +insert ( 2095 25 25 3 s 98 403 0 ) +insert ( 2095 25 25 4 s 2317 403 0 ) +insert ( 2095 25 25 5 s 2318 403 0 ) +insert ( 2097 1042 1042 1 s 2326 403 0 ) +insert ( 2097 1042 1042 2 s 2327 403 0 ) +insert ( 2097 1042 1042 3 s 1054 403 0 ) +insert ( 2097 1042 1042 4 s 2329 403 0 ) +insert ( 2097 1042 1042 5 s 2330 403 0 ) +insert ( 2099 790 790 1 s 902 403 0 ) +insert ( 2099 790 790 2 s 904 403 0 ) +insert ( 2099 790 790 3 s 900 403 0 ) +insert ( 2099 790 790 4 s 905 403 0 ) +insert ( 2099 790 790 5 s 903 403 0 ) +insert ( 2233 703 703 1 s 568 403 0 ) +insert ( 2233 703 703 2 s 570 403 0 ) +insert ( 2233 703 703 3 s 566 403 0 ) +insert ( 2233 703 703 4 s 571 403 0 ) +insert ( 2233 703 703 5 s 569 403 0 ) +insert ( 2234 704 704 1 s 813 403 0 ) +insert ( 2234 704 704 2 s 815 403 0 ) +insert ( 2234 704 704 3 s 811 403 0 ) +insert ( 2234 704 704 4 s 816 403 0 ) +insert ( 2234 704 704 5 s 814 403 0 ) +insert ( 397 2277 2277 1 s 1072 403 0 ) +insert ( 397 2277 2277 2 s 1074 403 0 ) +insert ( 397 2277 2277 3 s 1070 403 0 ) +insert ( 397 2277 2277 4 s 1075 403 0 ) +insert ( 397 2277 2277 5 s 1073 403 0 ) +insert ( 2994 2249 2249 1 s 2990 403 0 ) +insert ( 2994 2249 2249 2 s 2992 403 0 ) +insert ( 2994 2249 2249 3 s 2988 403 0 ) +insert ( 2994 2249 2249 4 s 2993 403 0 ) +insert ( 2994 2249 2249 5 s 2991 403 0 ) +insert ( 2968 2950 2950 1 s 2974 403 0 ) +insert ( 2968 2950 2950 2 s 2976 403 0 ) +insert ( 2968 2950 2950 3 s 2972 403 0 ) +insert ( 2968 2950 2950 4 s 2977 403 0 ) +insert ( 2968 2950 2950 5 s 2975 403 0 ) +insert ( 427 1042 1042 1 s 1054 405 0 ) +insert ( 431 18 18 1 s 92 405 0 ) +insert ( 435 1082 1082 1 s 1093 405 0 ) +insert ( 1971 700 700 1 s 620 405 0 ) +insert ( 1971 701 701 1 s 670 405 0 ) +insert ( 1971 700 701 1 s 1120 405 0 ) +insert ( 1971 701 700 1 s 1130 405 0 ) +insert ( 1975 869 869 1 s 1201 405 0 ) +insert ( 1977 21 21 1 s 94 405 0 ) +insert ( 1977 23 23 1 s 96 405 0 ) +insert ( 1977 20 20 1 s 410 405 0 ) +insert ( 1977 21 23 1 s 532 405 0 ) +insert ( 1977 21 20 1 s 1862 405 0 ) +insert ( 1977 23 21 1 s 533 405 0 ) +insert ( 1977 23 20 1 s 15 405 0 ) +insert ( 1977 20 21 1 s 1868 405 0 ) +insert ( 1977 20 23 1 s 416 405 0 ) +insert ( 1983 1186 1186 1 s 1330 405 0 ) +insert ( 1985 829 829 1 s 1220 405 0 ) +insert ( 1987 19 19 1 s 93 405 0 ) +insert ( 1990 26 26 1 s 607 405 0 ) +insert ( 1992 30 30 1 s 649 405 0 ) +insert ( 1995 25 25 1 s 98 405 0 ) +insert ( 1997 1083 1083 1 s 1108 405 0 ) +insert ( 1999 1184 1184 1 s 1320 405 0 ) +insert ( 2001 1266 1266 1 s 1550 405 0 ) +insert ( 2040 1114 1114 1 s 2060 405 0 ) +insert ( 2222 16 16 1 s 91 405 0 ) +insert ( 2223 17 17 1 s 1955 405 0 ) +insert ( 2224 22 22 1 s 386 405 0 ) +insert ( 2225 28 28 1 s 352 405 0 ) +insert ( 2226 29 29 1 s 385 405 0 ) +insert ( 2227 702 702 1 s 560 405 0 ) +insert ( 2228 703 703 1 s 566 405 0 ) +insert ( 2229 25 25 1 s 98 405 0 ) +insert ( 2231 1042 1042 1 s 1054 405 0 ) +insert ( 2235 1033 1033 1 s 974 405 0 ) +insert ( 2969 2950 2950 1 s 2972 405 0 ) +insert ( 1998 1700 1700 1 s 1752 405 0 ) +insert ( 627 2277 2277 1 s 1070 405 0 ) +insert ( 2593 603 603 1 s 493 783 0 ) +insert ( 2593 603 603 2 s 494 783 0 ) +insert ( 2593 603 603 3 s 500 783 0 ) +insert ( 2593 603 603 4 s 495 783 0 ) +insert ( 2593 603 603 5 s 496 783 0 ) +insert ( 2593 603 603 6 s 499 783 0 ) +insert ( 2593 603 603 7 s 498 783 0 ) +insert ( 2593 603 603 8 s 497 783 0 ) +insert ( 2593 603 603 9 s 2571 783 0 ) +insert ( 2593 603 603 10 s 2570 783 0 ) +insert ( 2593 603 603 11 s 2573 783 0 ) +insert ( 2593 603 603 12 s 2572 783 0 ) +insert ( 2593 603 603 13 s 2863 783 0 ) +insert ( 2593 603 603 14 s 2862 783 0 ) +insert ( 1029 600 600 11 s 506 783 0 ) +insert ( 1029 600 600 1 s 507 783 0 ) +insert ( 1029 600 600 5 s 508 783 0 ) +insert ( 1029 600 600 10 s 509 783 0 ) +insert ( 1029 600 600 6 s 510 783 0 ) +insert ( 1029 600 600 15 o 517 783 1970 ) +insert ( 1029 600 603 28 s 511 783 0 ) +insert ( 1029 600 604 48 s 756 783 0 ) +insert ( 1029 600 718 68 s 758 783 0 ) +insert ( 2594 604 604 1 s 485 783 0 ) +insert ( 2594 604 604 2 s 486 783 0 ) +insert ( 2594 604 604 3 s 492 783 0 ) +insert ( 2594 604 604 4 s 487 783 0 ) +insert ( 2594 604 604 5 s 488 783 0 ) +insert ( 2594 604 604 6 s 491 783 0 ) +insert ( 2594 604 604 7 s 490 783 0 ) +insert ( 2594 604 604 8 s 489 783 0 ) +insert ( 2594 604 604 9 s 2575 783 0 ) +insert ( 2594 604 604 10 s 2574 783 0 ) +insert ( 2594 604 604 11 s 2577 783 0 ) +insert ( 2594 604 604 12 s 2576 783 0 ) +insert ( 2594 604 604 13 s 2861 783 0 ) +insert ( 2594 604 604 14 s 2860 783 0 ) +insert ( 2595 718 718 1 s 1506 783 0 ) +insert ( 2595 718 718 2 s 1507 783 0 ) +insert ( 2595 718 718 3 s 1513 783 0 ) +insert ( 2595 718 718 4 s 1508 783 0 ) +insert ( 2595 718 718 5 s 1509 783 0 ) +insert ( 2595 718 718 6 s 1512 783 0 ) +insert ( 2595 718 718 7 s 1511 783 0 ) +insert ( 2595 718 718 8 s 1510 783 0 ) +insert ( 2595 718 718 9 s 2589 783 0 ) +insert ( 2595 718 718 10 s 1515 783 0 ) +insert ( 2595 718 718 11 s 1514 783 0 ) +insert ( 2595 718 718 12 s 2590 783 0 ) +insert ( 2595 718 718 13 s 2865 783 0 ) +insert ( 2595 718 718 14 s 2864 783 0 ) +insert ( 2745 2277 2277 1 s 2750 2742 0 ) +insert ( 2745 2277 2277 2 s 2751 2742 0 ) +insert ( 2745 2277 2277 3 s 2752 2742 0 ) +insert ( 2745 2277 2277 4 s 1070 2742 0 ) +insert ( 3522 3500 3500 1 s 3518 403 0 ) +insert ( 3522 3500 3500 2 s 3520 403 0 ) +insert ( 3522 3500 3500 3 s 3516 403 0 ) +insert ( 3522 3500 3500 4 s 3521 403 0 ) +insert ( 3522 3500 3500 5 s 3519 403 0 ) +insert ( 3523 3500 3500 1 s 3516 405 0 ) +insert ( 3626 3614 3614 1 s 3627 403 0 ) +insert ( 3626 3614 3614 2 s 3628 403 0 ) +insert ( 3626 3614 3614 3 s 3629 403 0 ) +insert ( 3626 3614 3614 4 s 3631 403 0 ) +insert ( 3626 3614 3614 5 s 3632 403 0 ) +insert ( 3655 3614 3615 1 s 3636 783 0 ) +insert ( 3659 3614 3615 1 s 3636 2742 0 ) +insert ( 3659 3614 3615 2 s 3660 2742 0 ) +insert ( 3683 3615 3615 1 s 3674 403 0 ) +insert ( 3683 3615 3615 2 s 3675 403 0 ) +insert ( 3683 3615 3615 3 s 3676 403 0 ) +insert ( 3683 3615 3615 4 s 3678 403 0 ) +insert ( 3683 3615 3615 5 s 3679 403 0 ) +insert ( 3702 3615 3615 7 s 3693 783 0 ) +insert ( 3702 3615 3615 8 s 3694 783 0 ) +insert ( 3901 3831 3831 1 s 3884 403 0 ) +insert ( 3901 3831 3831 2 s 3885 403 0 ) +insert ( 3901 3831 3831 3 s 3882 403 0 ) +insert ( 3901 3831 3831 4 s 3886 403 0 ) +insert ( 3901 3831 3831 5 s 3887 403 0 ) +insert ( 3903 3831 3831 1 s 3882 405 0 ) +insert ( 3919 3831 3831 1 s 3893 783 0 ) +insert ( 3919 3831 3831 2 s 3895 783 0 ) +insert ( 3919 3831 3831 3 s 3888 783 0 ) +insert ( 3919 3831 3831 4 s 3896 783 0 ) +insert ( 3919 3831 3831 5 s 3894 783 0 ) +insert ( 3919 3831 3831 6 s 3897 783 0 ) +insert ( 3919 3831 3831 7 s 3890 783 0 ) +insert ( 3919 3831 3831 8 s 3892 783 0 ) +insert ( 3919 3831 2283 16 s 3889 783 0 ) +insert ( 3919 3831 3831 18 s 3882 783 0 ) +insert ( 4015 600 600 11 s 506 4000 0 ) +insert ( 4015 600 600 1 s 507 4000 0 ) +insert ( 4015 600 600 5 s 508 4000 0 ) +insert ( 4015 600 600 10 s 509 4000 0 ) +insert ( 4015 600 600 6 s 510 4000 0 ) +insert ( 4015 600 603 8 s 511 4000 0 ) +insert ( 4016 600 600 11 s 506 4000 0 ) +insert ( 4016 600 600 1 s 507 4000 0 ) +insert ( 4016 600 600 5 s 508 4000 0 ) +insert ( 4016 600 600 10 s 509 4000 0 ) +insert ( 4016 600 600 6 s 510 4000 0 ) +insert ( 4016 600 603 8 s 511 4000 0 ) +insert ( 4017 25 25 1 s 2314 4000 0 ) +insert ( 4017 25 25 2 s 2315 4000 0 ) +insert ( 4017 25 25 3 s 98 4000 0 ) +insert ( 4017 25 25 4 s 2317 4000 0 ) +insert ( 4017 25 25 5 s 2318 4000 0 ) +insert ( 4017 25 25 11 s 664 4000 0 ) +insert ( 4017 25 25 12 s 665 4000 0 ) +insert ( 4017 25 25 14 s 667 4000 0 ) +insert ( 4017 25 25 15 s 666 4000 0 ) +close pg_amop +create pg_amproc 2603 + ( + amprocfamily = oid , + amproclefttype = oid , + amprocrighttype = oid , + amprocnum = int2 , + amproc = regproc + ) +open pg_amproc +insert ( 397 2277 2277 1 382 ) +insert ( 421 702 702 1 357 ) +insert ( 423 1560 1560 1 1596 ) +insert ( 424 16 16 1 1693 ) +insert ( 426 1042 1042 1 1078 ) +insert ( 428 17 17 1 1954 ) +insert ( 429 18 18 1 358 ) +insert ( 434 1082 1082 1 1092 ) +insert ( 434 1082 1082 2 3136 ) +insert ( 434 1082 1114 1 2344 ) +insert ( 434 1082 1184 1 2357 ) +insert ( 434 1114 1114 1 2045 ) +insert ( 434 1114 1114 2 3137 ) +insert ( 434 1114 1082 1 2370 ) +insert ( 434 1114 1184 1 2526 ) +insert ( 434 1184 1184 1 1314 ) +insert ( 434 1184 1184 2 3137 ) +insert ( 434 1184 1082 1 2383 ) +insert ( 434 1184 1114 1 2533 ) +insert ( 1970 700 700 1 354 ) +insert ( 1970 700 700 2 3132 ) +insert ( 1970 700 701 1 2194 ) +insert ( 1970 701 701 1 355 ) +insert ( 1970 701 701 2 3133 ) +insert ( 1970 701 700 1 2195 ) +insert ( 1974 869 869 1 926 ) +insert ( 1976 21 21 1 350 ) +insert ( 1976 21 21 2 3129 ) +insert ( 1976 21 23 1 2190 ) +insert ( 1976 21 20 1 2192 ) +insert ( 1976 23 23 1 351 ) +insert ( 1976 23 23 2 3130 ) +insert ( 1976 23 20 1 2188 ) +insert ( 1976 23 21 1 2191 ) +insert ( 1976 20 20 1 842 ) +insert ( 1976 20 20 2 3131 ) +insert ( 1976 20 23 1 2189 ) +insert ( 1976 20 21 1 2193 ) +insert ( 1982 1186 1186 1 1315 ) +insert ( 1984 829 829 1 836 ) +insert ( 1986 19 19 1 359 ) +insert ( 1986 19 19 2 3135 ) +insert ( 1988 1700 1700 1 1769 ) +insert ( 1989 26 26 1 356 ) +insert ( 1989 26 26 2 3134 ) +insert ( 1991 30 30 1 404 ) +insert ( 2994 2249 2249 1 2987 ) +insert ( 1994 25 25 1 360 ) +insert ( 1996 1083 1083 1 1107 ) +insert ( 2000 1266 1266 1 1358 ) +insert ( 2002 1562 1562 1 1672 ) +insert ( 2095 25 25 1 2166 ) +insert ( 2097 1042 1042 1 2180 ) +insert ( 2099 790 790 1 377 ) +insert ( 2233 703 703 1 380 ) +insert ( 2234 704 704 1 381 ) +insert ( 2789 27 27 1 2794 ) +insert ( 2968 2950 2950 1 2960 ) +insert ( 3522 3500 3500 1 3514 ) +insert ( 427 1042 1042 1 1080 ) +insert ( 431 18 18 1 454 ) +insert ( 435 1082 1082 1 450 ) +insert ( 627 2277 2277 1 626 ) +insert ( 1971 700 700 1 451 ) +insert ( 1971 701 701 1 452 ) +insert ( 1975 869 869 1 422 ) +insert ( 1977 21 21 1 449 ) +insert ( 1977 23 23 1 450 ) +insert ( 1977 20 20 1 949 ) +insert ( 1983 1186 1186 1 1697 ) +insert ( 1985 829 829 1 399 ) +insert ( 1987 19 19 1 455 ) +insert ( 1990 26 26 1 453 ) +insert ( 1992 30 30 1 457 ) +insert ( 1995 25 25 1 400 ) +insert ( 1997 1083 1083 1 1688 ) +insert ( 1998 1700 1700 1 432 ) +insert ( 1999 1184 1184 1 2039 ) +insert ( 2001 1266 1266 1 1696 ) +insert ( 2040 1114 1114 1 2039 ) +insert ( 2222 16 16 1 454 ) +insert ( 2223 17 17 1 456 ) +insert ( 2224 22 22 1 398 ) +insert ( 2225 28 28 1 450 ) +insert ( 2226 29 29 1 450 ) +insert ( 2227 702 702 1 450 ) +insert ( 2228 703 703 1 450 ) +insert ( 2229 25 25 1 400 ) +insert ( 2231 1042 1042 1 1080 ) +insert ( 2235 1033 1033 1 329 ) +insert ( 2969 2950 2950 1 2963 ) +insert ( 3523 3500 3500 1 3515 ) +insert ( 2593 603 603 1 2578 ) +insert ( 2593 603 603 2 2583 ) +insert ( 2593 603 603 3 2579 ) +insert ( 2593 603 603 4 2580 ) +insert ( 2593 603 603 5 2581 ) +insert ( 2593 603 603 6 2582 ) +insert ( 2593 603 603 7 2584 ) +insert ( 2594 604 604 1 2585 ) +insert ( 2594 604 604 2 2583 ) +insert ( 2594 604 604 3 2586 ) +insert ( 2594 604 604 4 2580 ) +insert ( 2594 604 604 5 2581 ) +insert ( 2594 604 604 6 2582 ) +insert ( 2594 604 604 7 2584 ) +insert ( 2595 718 718 1 2591 ) +insert ( 2595 718 718 2 2583 ) +insert ( 2595 718 718 3 2592 ) +insert ( 2595 718 718 4 2580 ) +insert ( 2595 718 718 5 2581 ) +insert ( 2595 718 718 6 2582 ) +insert ( 2595 718 718 7 2584 ) +insert ( 3655 3614 3614 1 3654 ) +insert ( 3655 3614 3614 2 3651 ) +insert ( 3655 3614 3614 3 3648 ) +insert ( 3655 3614 3614 4 3649 ) +insert ( 3655 3614 3614 5 3653 ) +insert ( 3655 3614 3614 6 3650 ) +insert ( 3655 3614 3614 7 3652 ) +insert ( 3702 3615 3615 1 3701 ) +insert ( 3702 3615 3615 2 3698 ) +insert ( 3702 3615 3615 3 3695 ) +insert ( 3702 3615 3615 4 3696 ) +insert ( 3702 3615 3615 5 3700 ) +insert ( 3702 3615 3615 6 3697 ) +insert ( 3702 3615 3615 7 3699 ) +insert ( 1029 600 600 1 2179 ) +insert ( 1029 600 600 2 2583 ) +insert ( 1029 600 600 3 1030 ) +insert ( 1029 600 600 4 2580 ) +insert ( 1029 600 600 5 2581 ) +insert ( 1029 600 600 6 2582 ) +insert ( 1029 600 600 7 2584 ) +insert ( 1029 600 600 8 3064 ) +insert ( 2745 1007 1007 1 351 ) +insert ( 2745 1007 1007 2 2743 ) +insert ( 2745 1007 1007 3 2774 ) +insert ( 2745 1007 1007 4 2744 ) +insert ( 2745 1009 1009 1 360 ) +insert ( 2745 1009 1009 2 2743 ) +insert ( 2745 1009 1009 3 2774 ) +insert ( 2745 1009 1009 4 2744 ) +insert ( 2745 1015 1015 1 360 ) +insert ( 2745 1015 1015 2 2743 ) +insert ( 2745 1015 1015 3 2774 ) +insert ( 2745 1015 1015 4 2744 ) +insert ( 2745 1023 1023 1 357 ) +insert ( 2745 1023 1023 2 2743 ) +insert ( 2745 1023 1023 3 2774 ) +insert ( 2745 1023 1023 4 2744 ) +insert ( 2745 1561 1561 1 1596 ) +insert ( 2745 1561 1561 2 2743 ) +insert ( 2745 1561 1561 3 2774 ) +insert ( 2745 1561 1561 4 2744 ) +insert ( 2745 1000 1000 1 1693 ) +insert ( 2745 1000 1000 2 2743 ) +insert ( 2745 1000 1000 3 2774 ) +insert ( 2745 1000 1000 4 2744 ) +insert ( 2745 1014 1014 1 1078 ) +insert ( 2745 1014 1014 2 2743 ) +insert ( 2745 1014 1014 3 2774 ) +insert ( 2745 1014 1014 4 2744 ) +insert ( 2745 1001 1001 1 1954 ) +insert ( 2745 1001 1001 2 2743 ) +insert ( 2745 1001 1001 3 2774 ) +insert ( 2745 1001 1001 4 2744 ) +insert ( 2745 1002 1002 1 358 ) +insert ( 2745 1002 1002 2 2743 ) +insert ( 2745 1002 1002 3 2774 ) +insert ( 2745 1002 1002 4 2744 ) +insert ( 2745 1182 1182 1 1092 ) +insert ( 2745 1182 1182 2 2743 ) +insert ( 2745 1182 1182 3 2774 ) +insert ( 2745 1182 1182 4 2744 ) +insert ( 2745 1021 1021 1 354 ) +insert ( 2745 1021 1021 2 2743 ) +insert ( 2745 1021 1021 3 2774 ) +insert ( 2745 1021 1021 4 2744 ) +insert ( 2745 1022 1022 1 355 ) +insert ( 2745 1022 1022 2 2743 ) +insert ( 2745 1022 1022 3 2774 ) +insert ( 2745 1022 1022 4 2744 ) +insert ( 2745 1041 1041 1 926 ) +insert ( 2745 1041 1041 2 2743 ) +insert ( 2745 1041 1041 3 2774 ) +insert ( 2745 1041 1041 4 2744 ) +insert ( 2745 651 651 1 926 ) +insert ( 2745 651 651 2 2743 ) +insert ( 2745 651 651 3 2774 ) +insert ( 2745 651 651 4 2744 ) +insert ( 2745 1005 1005 1 350 ) +insert ( 2745 1005 1005 2 2743 ) +insert ( 2745 1005 1005 3 2774 ) +insert ( 2745 1005 1005 4 2744 ) +insert ( 2745 1016 1016 1 842 ) +insert ( 2745 1016 1016 2 2743 ) +insert ( 2745 1016 1016 3 2774 ) +insert ( 2745 1016 1016 4 2744 ) +insert ( 2745 1187 1187 1 1315 ) +insert ( 2745 1187 1187 2 2743 ) +insert ( 2745 1187 1187 3 2774 ) +insert ( 2745 1187 1187 4 2744 ) +insert ( 2745 1040 1040 1 836 ) +insert ( 2745 1040 1040 2 2743 ) +insert ( 2745 1040 1040 3 2774 ) +insert ( 2745 1040 1040 4 2744 ) +insert ( 2745 1003 1003 1 359 ) +insert ( 2745 1003 1003 2 2743 ) +insert ( 2745 1003 1003 3 2774 ) +insert ( 2745 1003 1003 4 2744 ) +insert ( 2745 1231 1231 1 1769 ) +insert ( 2745 1231 1231 2 2743 ) +insert ( 2745 1231 1231 3 2774 ) +insert ( 2745 1231 1231 4 2744 ) +insert ( 2745 1028 1028 1 356 ) +insert ( 2745 1028 1028 2 2743 ) +insert ( 2745 1028 1028 3 2774 ) +insert ( 2745 1028 1028 4 2744 ) +insert ( 2745 1013 1013 1 404 ) +insert ( 2745 1013 1013 2 2743 ) +insert ( 2745 1013 1013 3 2774 ) +insert ( 2745 1013 1013 4 2744 ) +insert ( 2745 1183 1183 1 1107 ) +insert ( 2745 1183 1183 2 2743 ) +insert ( 2745 1183 1183 3 2774 ) +insert ( 2745 1183 1183 4 2744 ) +insert ( 2745 1185 1185 1 1314 ) +insert ( 2745 1185 1185 2 2743 ) +insert ( 2745 1185 1185 3 2774 ) +insert ( 2745 1185 1185 4 2744 ) +insert ( 2745 1270 1270 1 1358 ) +insert ( 2745 1270 1270 2 2743 ) +insert ( 2745 1270 1270 3 2774 ) +insert ( 2745 1270 1270 4 2744 ) +insert ( 2745 1563 1563 1 1672 ) +insert ( 2745 1563 1563 2 2743 ) +insert ( 2745 1563 1563 3 2774 ) +insert ( 2745 1563 1563 4 2744 ) +insert ( 2745 1115 1115 1 2045 ) +insert ( 2745 1115 1115 2 2743 ) +insert ( 2745 1115 1115 3 2774 ) +insert ( 2745 1115 1115 4 2744 ) +insert ( 2745 791 791 1 377 ) +insert ( 2745 791 791 2 2743 ) +insert ( 2745 791 791 3 2774 ) +insert ( 2745 791 791 4 2744 ) +insert ( 2745 1024 1024 1 380 ) +insert ( 2745 1024 1024 2 2743 ) +insert ( 2745 1024 1024 3 2774 ) +insert ( 2745 1024 1024 4 2744 ) +insert ( 2745 1025 1025 1 381 ) +insert ( 2745 1025 1025 2 2743 ) +insert ( 2745 1025 1025 3 2774 ) +insert ( 2745 1025 1025 4 2744 ) +insert ( 3659 3614 3614 1 3724 ) +insert ( 3659 3614 3614 2 3656 ) +insert ( 3659 3614 3614 3 3657 ) +insert ( 3659 3614 3614 4 3658 ) +insert ( 3659 3614 3614 5 2700 ) +insert ( 3626 3614 3614 1 3622 ) +insert ( 3683 3615 3615 1 3668 ) +insert ( 3901 3831 3831 1 3870 ) +insert ( 3903 3831 3831 1 3902 ) +insert ( 3919 3831 3831 1 3875 ) +insert ( 3919 3831 3831 2 3876 ) +insert ( 3919 3831 3831 3 3877 ) +insert ( 3919 3831 3831 4 3878 ) +insert ( 3919 3831 3831 5 3879 ) +insert ( 3919 3831 3831 6 3880 ) +insert ( 3919 3831 3831 7 3881 ) +insert ( 4015 600 600 1 4018 ) +insert ( 4015 600 600 2 4019 ) +insert ( 4015 600 600 3 4020 ) +insert ( 4015 600 600 4 4021 ) +insert ( 4015 600 600 5 4022 ) +insert ( 4016 600 600 1 4023 ) +insert ( 4016 600 600 2 4024 ) +insert ( 4016 600 600 3 4025 ) +insert ( 4016 600 600 4 4026 ) +insert ( 4016 600 600 5 4022 ) +insert ( 4017 25 25 1 4027 ) +insert ( 4017 25 25 2 4028 ) +insert ( 4017 25 25 3 4029 ) +insert ( 4017 25 25 4 4030 ) +insert ( 4017 25 25 5 4031 ) +close pg_amproc +create pg_language 2612 + ( + lanname = name , + lanowner = oid , + lanispl = bool , + lanpltrusted = bool , + lanplcallfoid = oid , + laninline = oid , + lanvalidator = oid , + lanacl = aclitem[] + ) +open pg_language +insert OID = 12 ( "internal" 10 f f 0 0 2246 _null_ ) +insert OID = 13 ( "c" 10 f f 0 0 2247 _null_ ) +insert OID = 14 ( "sql" 10 f t 0 0 2248 _null_ ) +close pg_language +create pg_largeobject_metadata 2995 + ( + lomowner = oid , + lomacl = aclitem[] + ) +open pg_largeobject_metadata +close pg_largeobject_metadata +create pg_largeobject 2613 without_oids + ( + loid = oid , + pageno = int4 , + data = bytea + ) +open pg_largeobject +close pg_largeobject +create pg_aggregate 2600 without_oids + ( + aggfnoid = regproc , + aggtransfn = regproc , + aggfinalfn = regproc , + aggsortop = oid , + aggtranstype = oid , + agginitval = text + ) +open pg_aggregate +insert ( 2100 int8_avg_accum numeric_avg 0 1231 "{0,0}" ) +insert ( 2101 int4_avg_accum int8_avg 0 1016 "{0,0}" ) +insert ( 2102 int2_avg_accum int8_avg 0 1016 "{0,0}" ) +insert ( 2103 numeric_avg_accum numeric_avg 0 1231 "{0,0}" ) +insert ( 2104 float4_accum float8_avg 0 1022 "{0,0,0}" ) +insert ( 2105 float8_accum float8_avg 0 1022 "{0,0,0}" ) +insert ( 2106 interval_accum interval_avg 0 1187 "{0 second,0 second}" ) +insert ( 2107 int8_sum - 0 1700 _null_ ) +insert ( 2108 int4_sum - 0 20 _null_ ) +insert ( 2109 int2_sum - 0 20 _null_ ) +insert ( 2110 float4pl - 0 700 _null_ ) +insert ( 2111 float8pl - 0 701 _null_ ) +insert ( 2112 cash_pl - 0 790 _null_ ) +insert ( 2113 interval_pl - 0 1186 _null_ ) +insert ( 2114 numeric_add - 0 1700 _null_ ) +insert ( 2115 int8larger - 413 20 _null_ ) +insert ( 2116 int4larger - 521 23 _null_ ) +insert ( 2117 int2larger - 520 21 _null_ ) +insert ( 2118 oidlarger - 610 26 _null_ ) +insert ( 2119 float4larger - 623 700 _null_ ) +insert ( 2120 float8larger - 674 701 _null_ ) +insert ( 2121 int4larger - 563 702 _null_ ) +insert ( 2122 date_larger - 1097 1082 _null_ ) +insert ( 2123 time_larger - 1112 1083 _null_ ) +insert ( 2124 timetz_larger - 1554 1266 _null_ ) +insert ( 2125 cashlarger - 903 790 _null_ ) +insert ( 2126 timestamp_larger - 2064 1114 _null_ ) +insert ( 2127 timestamptz_larger - 1324 1184 _null_ ) +insert ( 2128 interval_larger - 1334 1186 _null_ ) +insert ( 2129 text_larger - 666 25 _null_ ) +insert ( 2130 numeric_larger - 1756 1700 _null_ ) +insert ( 2050 array_larger - 1073 2277 _null_ ) +insert ( 2244 bpchar_larger - 1060 1042 _null_ ) +insert ( 2797 tidlarger - 2800 27 _null_ ) +insert ( 3526 enum_larger - 3519 3500 _null_ ) +insert ( 2131 int8smaller - 412 20 _null_ ) +insert ( 2132 int4smaller - 97 23 _null_ ) +insert ( 2133 int2smaller - 95 21 _null_ ) +insert ( 2134 oidsmaller - 609 26 _null_ ) +insert ( 2135 float4smaller - 622 700 _null_ ) +insert ( 2136 float8smaller - 672 701 _null_ ) +insert ( 2137 int4smaller - 562 702 _null_ ) +insert ( 2138 date_smaller - 1095 1082 _null_ ) +insert ( 2139 time_smaller - 1110 1083 _null_ ) +insert ( 2140 timetz_smaller - 1552 1266 _null_ ) +insert ( 2141 cashsmaller - 902 790 _null_ ) +insert ( 2142 timestamp_smaller - 2062 1114 _null_ ) +insert ( 2143 timestamptz_smaller - 1322 1184 _null_ ) +insert ( 2144 interval_smaller - 1332 1186 _null_ ) +insert ( 2145 text_smaller - 664 25 _null_ ) +insert ( 2146 numeric_smaller - 1754 1700 _null_ ) +insert ( 2051 array_smaller - 1072 2277 _null_ ) +insert ( 2245 bpchar_smaller - 1058 1042 _null_ ) +insert ( 2798 tidsmaller - 2799 27 _null_ ) +insert ( 3527 enum_smaller - 3518 3500 _null_ ) +insert ( 2147 int8inc_any - 0 20 "0" ) +insert ( 2803 int8inc - 0 20 "0" ) +insert ( 2718 int8_accum numeric_var_pop 0 1231 "{0,0,0}" ) +insert ( 2719 int4_accum numeric_var_pop 0 1231 "{0,0,0}" ) +insert ( 2720 int2_accum numeric_var_pop 0 1231 "{0,0,0}" ) +insert ( 2721 float4_accum float8_var_pop 0 1022 "{0,0,0}" ) +insert ( 2722 float8_accum float8_var_pop 0 1022 "{0,0,0}" ) +insert ( 2723 numeric_accum numeric_var_pop 0 1231 "{0,0,0}" ) +insert ( 2641 int8_accum numeric_var_samp 0 1231 "{0,0,0}" ) +insert ( 2642 int4_accum numeric_var_samp 0 1231 "{0,0,0}" ) +insert ( 2643 int2_accum numeric_var_samp 0 1231 "{0,0,0}" ) +insert ( 2644 float4_accum float8_var_samp 0 1022 "{0,0,0}" ) +insert ( 2645 float8_accum float8_var_samp 0 1022 "{0,0,0}" ) +insert ( 2646 numeric_accum numeric_var_samp 0 1231 "{0,0,0}" ) +insert ( 2148 int8_accum numeric_var_samp 0 1231 "{0,0,0}" ) +insert ( 2149 int4_accum numeric_var_samp 0 1231 "{0,0,0}" ) +insert ( 2150 int2_accum numeric_var_samp 0 1231 "{0,0,0}" ) +insert ( 2151 float4_accum float8_var_samp 0 1022 "{0,0,0}" ) +insert ( 2152 float8_accum float8_var_samp 0 1022 "{0,0,0}" ) +insert ( 2153 numeric_accum numeric_var_samp 0 1231 "{0,0,0}" ) +insert ( 2724 int8_accum numeric_stddev_pop 0 1231 "{0,0,0}" ) +insert ( 2725 int4_accum numeric_stddev_pop 0 1231 "{0,0,0}" ) +insert ( 2726 int2_accum numeric_stddev_pop 0 1231 "{0,0,0}" ) +insert ( 2727 float4_accum float8_stddev_pop 0 1022 "{0,0,0}" ) +insert ( 2728 float8_accum float8_stddev_pop 0 1022 "{0,0,0}" ) +insert ( 2729 numeric_accum numeric_stddev_pop 0 1231 "{0,0,0}" ) +insert ( 2712 int8_accum numeric_stddev_samp 0 1231 "{0,0,0}" ) +insert ( 2713 int4_accum numeric_stddev_samp 0 1231 "{0,0,0}" ) +insert ( 2714 int2_accum numeric_stddev_samp 0 1231 "{0,0,0}" ) +insert ( 2715 float4_accum float8_stddev_samp 0 1022 "{0,0,0}" ) +insert ( 2716 float8_accum float8_stddev_samp 0 1022 "{0,0,0}" ) +insert ( 2717 numeric_accum numeric_stddev_samp 0 1231 "{0,0,0}" ) +insert ( 2154 int8_accum numeric_stddev_samp 0 1231 "{0,0,0}" ) +insert ( 2155 int4_accum numeric_stddev_samp 0 1231 "{0,0,0}" ) +insert ( 2156 int2_accum numeric_stddev_samp 0 1231 "{0,0,0}" ) +insert ( 2157 float4_accum float8_stddev_samp 0 1022 "{0,0,0}" ) +insert ( 2158 float8_accum float8_stddev_samp 0 1022 "{0,0,0}" ) +insert ( 2159 numeric_accum numeric_stddev_samp 0 1231 "{0,0,0}" ) +insert ( 2818 int8inc_float8_float8 - 0 20 "0" ) +insert ( 2819 float8_regr_accum float8_regr_sxx 0 1022 "{0,0,0,0,0,0}" ) +insert ( 2820 float8_regr_accum float8_regr_syy 0 1022 "{0,0,0,0,0,0}" ) +insert ( 2821 float8_regr_accum float8_regr_sxy 0 1022 "{0,0,0,0,0,0}" ) +insert ( 2822 float8_regr_accum float8_regr_avgx 0 1022 "{0,0,0,0,0,0}" ) +insert ( 2823 float8_regr_accum float8_regr_avgy 0 1022 "{0,0,0,0,0,0}" ) +insert ( 2824 float8_regr_accum float8_regr_r2 0 1022 "{0,0,0,0,0,0}" ) +insert ( 2825 float8_regr_accum float8_regr_slope 0 1022 "{0,0,0,0,0,0}" ) +insert ( 2826 float8_regr_accum float8_regr_intercept 0 1022 "{0,0,0,0,0,0}" ) +insert ( 2827 float8_regr_accum float8_covar_pop 0 1022 "{0,0,0,0,0,0}" ) +insert ( 2828 float8_regr_accum float8_covar_samp 0 1022 "{0,0,0,0,0,0}" ) +insert ( 2829 float8_regr_accum float8_corr 0 1022 "{0,0,0,0,0,0}" ) +insert ( 2517 booland_statefunc - 58 16 _null_ ) +insert ( 2518 boolor_statefunc - 59 16 _null_ ) +insert ( 2519 booland_statefunc - 58 16 _null_ ) +insert ( 2236 int2and - 0 21 _null_ ) +insert ( 2237 int2or - 0 21 _null_ ) +insert ( 2238 int4and - 0 23 _null_ ) +insert ( 2239 int4or - 0 23 _null_ ) +insert ( 2240 int8and - 0 20 _null_ ) +insert ( 2241 int8or - 0 20 _null_ ) +insert ( 2242 bitand - 0 1560 _null_ ) +insert ( 2243 bitor - 0 1560 _null_ ) +insert ( 2901 xmlconcat2 - 0 142 _null_ ) +insert ( 2335 array_agg_transfn array_agg_finalfn 0 2281 _null_ ) +insert ( 3538 string_agg_transfn string_agg_finalfn 0 2281 _null_ ) +insert ( 3545 bytea_string_agg_transfn bytea_string_agg_finalfn 0 2281 _null_ ) +close pg_aggregate +create pg_statistic 2619 without_oids + ( + starelid = oid , + staattnum = int2 , + stainherit = bool , + stanullfrac = float4 , + stawidth = int4 , + stadistinct = float4 , + stakind1 = int2 , + stakind2 = int2 , + stakind3 = int2 , + stakind4 = int2 , + stakind5 = int2 , + staop1 = oid , + staop2 = oid , + staop3 = oid , + staop4 = oid , + staop5 = oid , + stanumbers1 = float4[] , + stanumbers2 = float4[] , + stanumbers3 = float4[] , + stanumbers4 = float4[] , + stanumbers5 = float4[] , + stavalues1 = anyarray , + stavalues2 = anyarray , + stavalues3 = anyarray , + stavalues4 = anyarray , + stavalues5 = anyarray + ) +open pg_statistic +close pg_statistic +create pg_rewrite 2618 + ( + rulename = name , + ev_class = oid , + ev_attr = int2 , + ev_type = char , + ev_enabled = char , + is_instead = bool , + ev_qual = pg_node_tree , + ev_action = pg_node_tree + ) +open pg_rewrite +close pg_rewrite +create pg_trigger 2620 + ( + tgrelid = oid , + tgname = name , + tgfoid = oid , + tgtype = int2 , + tgenabled = char , + tgisinternal = bool , + tgconstrrelid = oid , + tgconstrindid = oid , + tgconstraint = oid , + tgdeferrable = bool , + tginitdeferred = bool , + tgnargs = int2 , + tgattr = int2vector , + tgargs = bytea , + tgqual = pg_node_tree + ) +open pg_trigger +close pg_trigger +create pg_description 2609 without_oids + ( + objoid = oid , + classoid = oid , + objsubid = int4 , + description = text + ) +open pg_description +close pg_description +create pg_cast 2605 + ( + castsource = oid , + casttarget = oid , + castfunc = oid , + castcontext = char , + castmethod = char + ) +open pg_cast +insert ( 20 21 714 a f ) +insert ( 20 23 480 a f ) +insert ( 20 700 652 i f ) +insert ( 20 701 482 i f ) +insert ( 20 1700 1781 i f ) +insert ( 21 20 754 i f ) +insert ( 21 23 313 i f ) +insert ( 21 700 236 i f ) +insert ( 21 701 235 i f ) +insert ( 21 1700 1782 i f ) +insert ( 23 20 481 i f ) +insert ( 23 21 314 a f ) +insert ( 23 700 318 i f ) +insert ( 23 701 316 i f ) +insert ( 23 1700 1740 i f ) +insert ( 700 20 653 a f ) +insert ( 700 21 238 a f ) +insert ( 700 23 319 a f ) +insert ( 700 701 311 i f ) +insert ( 700 1700 1742 a f ) +insert ( 701 20 483 a f ) +insert ( 701 21 237 a f ) +insert ( 701 23 317 a f ) +insert ( 701 700 312 a f ) +insert ( 701 1700 1743 a f ) +insert ( 1700 20 1779 a f ) +insert ( 1700 21 1783 a f ) +insert ( 1700 23 1744 a f ) +insert ( 1700 700 1745 i f ) +insert ( 1700 701 1746 i f ) +insert ( 790 1700 3823 a f ) +insert ( 1700 790 3824 a f ) +insert ( 23 790 3811 a f ) +insert ( 20 790 3812 a f ) +insert ( 23 16 2557 e f ) +insert ( 16 23 2558 e f ) +insert ( 20 26 1287 i f ) +insert ( 21 26 313 i f ) +insert ( 23 26 0 i b ) +insert ( 26 20 1288 a f ) +insert ( 26 23 0 a b ) +insert ( 26 24 0 i b ) +insert ( 24 26 0 i b ) +insert ( 20 24 1287 i f ) +insert ( 21 24 313 i f ) +insert ( 23 24 0 i b ) +insert ( 24 20 1288 a f ) +insert ( 24 23 0 a b ) +insert ( 24 2202 0 i b ) +insert ( 2202 24 0 i b ) +insert ( 26 2202 0 i b ) +insert ( 2202 26 0 i b ) +insert ( 20 2202 1287 i f ) +insert ( 21 2202 313 i f ) +insert ( 23 2202 0 i b ) +insert ( 2202 20 1288 a f ) +insert ( 2202 23 0 a b ) +insert ( 26 2203 0 i b ) +insert ( 2203 26 0 i b ) +insert ( 20 2203 1287 i f ) +insert ( 21 2203 313 i f ) +insert ( 23 2203 0 i b ) +insert ( 2203 20 1288 a f ) +insert ( 2203 23 0 a b ) +insert ( 2203 2204 0 i b ) +insert ( 2204 2203 0 i b ) +insert ( 26 2204 0 i b ) +insert ( 2204 26 0 i b ) +insert ( 20 2204 1287 i f ) +insert ( 21 2204 313 i f ) +insert ( 23 2204 0 i b ) +insert ( 2204 20 1288 a f ) +insert ( 2204 23 0 a b ) +insert ( 26 2205 0 i b ) +insert ( 2205 26 0 i b ) +insert ( 20 2205 1287 i f ) +insert ( 21 2205 313 i f ) +insert ( 23 2205 0 i b ) +insert ( 2205 20 1288 a f ) +insert ( 2205 23 0 a b ) +insert ( 26 2206 0 i b ) +insert ( 2206 26 0 i b ) +insert ( 20 2206 1287 i f ) +insert ( 21 2206 313 i f ) +insert ( 23 2206 0 i b ) +insert ( 2206 20 1288 a f ) +insert ( 2206 23 0 a b ) +insert ( 26 3734 0 i b ) +insert ( 3734 26 0 i b ) +insert ( 20 3734 1287 i f ) +insert ( 21 3734 313 i f ) +insert ( 23 3734 0 i b ) +insert ( 3734 20 1288 a f ) +insert ( 3734 23 0 a b ) +insert ( 26 3769 0 i b ) +insert ( 3769 26 0 i b ) +insert ( 20 3769 1287 i f ) +insert ( 21 3769 313 i f ) +insert ( 23 3769 0 i b ) +insert ( 3769 20 1288 a f ) +insert ( 3769 23 0 a b ) +insert ( 25 2205 1079 i f ) +insert ( 1043 2205 1079 i f ) +insert ( 25 1042 0 i b ) +insert ( 25 1043 0 i b ) +insert ( 1042 25 401 i f ) +insert ( 1042 1043 401 i f ) +insert ( 1043 25 0 i b ) +insert ( 1043 1042 0 i b ) +insert ( 18 25 946 i f ) +insert ( 18 1042 860 a f ) +insert ( 18 1043 946 a f ) +insert ( 19 25 406 i f ) +insert ( 19 1042 408 a f ) +insert ( 19 1043 1401 a f ) +insert ( 25 18 944 a f ) +insert ( 1042 18 944 a f ) +insert ( 1043 18 944 a f ) +insert ( 25 19 407 i f ) +insert ( 1042 19 409 i f ) +insert ( 1043 19 1400 i f ) +insert ( 18 23 77 e f ) +insert ( 23 18 78 e f ) +insert ( 194 25 0 i b ) +insert ( 702 1082 1179 a f ) +insert ( 702 1083 1364 a f ) +insert ( 702 1114 2023 i f ) +insert ( 702 1184 1173 i f ) +insert ( 703 1186 1177 i f ) +insert ( 1082 1114 2024 i f ) +insert ( 1082 1184 1174 i f ) +insert ( 1083 1186 1370 i f ) +insert ( 1083 1266 2047 i f ) +insert ( 1114 702 2030 a f ) +insert ( 1114 1082 2029 a f ) +insert ( 1114 1083 1316 a f ) +insert ( 1114 1184 2028 i f ) +insert ( 1184 702 1180 a f ) +insert ( 1184 1082 1178 a f ) +insert ( 1184 1083 2019 a f ) +insert ( 1184 1114 2027 a f ) +insert ( 1184 1266 1388 a f ) +insert ( 1186 703 1194 a f ) +insert ( 1186 1083 1419 a f ) +insert ( 1266 1083 2046 a f ) +insert ( 23 702 0 e b ) +insert ( 702 23 0 e b ) +insert ( 23 703 0 e b ) +insert ( 703 23 0 e b ) +insert ( 601 600 1532 e f ) +insert ( 602 600 1533 e f ) +insert ( 602 604 1449 a f ) +insert ( 603 600 1534 e f ) +insert ( 603 601 1541 e f ) +insert ( 603 604 1448 a f ) +insert ( 603 718 1479 e f ) +insert ( 604 600 1540 e f ) +insert ( 604 602 1447 a f ) +insert ( 604 603 1446 e f ) +insert ( 604 718 1474 e f ) +insert ( 718 600 1416 e f ) +insert ( 718 603 1480 e f ) +insert ( 718 604 1544 e f ) +insert ( 650 869 0 i b ) +insert ( 869 650 1715 a f ) +insert ( 1560 1562 0 i b ) +insert ( 1562 1560 0 i b ) +insert ( 20 1560 2075 e f ) +insert ( 23 1560 1683 e f ) +insert ( 1560 20 2076 e f ) +insert ( 1560 23 1684 e f ) +insert ( 650 25 730 a f ) +insert ( 869 25 730 a f ) +insert ( 16 25 2971 a f ) +insert ( 142 25 0 a b ) +insert ( 25 142 2896 e f ) +insert ( 650 1043 730 a f ) +insert ( 869 1043 730 a f ) +insert ( 16 1043 2971 a f ) +insert ( 142 1043 0 a b ) +insert ( 1043 142 2896 e f ) +insert ( 650 1042 730 a f ) +insert ( 869 1042 730 a f ) +insert ( 16 1042 2971 a f ) +insert ( 142 1042 0 a b ) +insert ( 1042 142 2896 e f ) +insert ( 1042 1042 668 i f ) +insert ( 1043 1043 669 i f ) +insert ( 1083 1083 1968 i f ) +insert ( 1114 1114 1961 i f ) +insert ( 1184 1184 1967 i f ) +insert ( 1186 1186 1200 i f ) +insert ( 1266 1266 1969 i f ) +insert ( 1560 1560 1685 i f ) +insert ( 1562 1562 1687 i f ) +insert ( 1700 1700 1703 i f ) +close pg_cast +create pg_enum 3501 + ( + enumtypid = oid , + enumsortorder = float4 , + enumlabel = name + ) +open pg_enum +close pg_enum +create pg_namespace 2615 + ( + nspname = name , + nspowner = oid , + nspacl = aclitem[] + ) +open pg_namespace +insert OID = 11 ( "pg_catalog" 10 _null_ ) +insert OID = 99 ( "pg_toast" 10 _null_ ) +insert OID = 2200 ( "public" 10 _null_ ) +close pg_namespace +create pg_conversion 2607 + ( + conname = name , + connamespace = oid , + conowner = oid , + conforencoding = int4 , + contoencoding = int4 , + conproc = regproc , + condefault = bool + ) +open pg_conversion +close pg_conversion +create pg_depend 2608 without_oids + ( + classid = oid , + objid = oid , + objsubid = int4 , + refclassid = oid , + refobjid = oid , + refobjsubid = int4 , + deptype = char + ) +open pg_depend +close pg_depend +create pg_database 1262 shared_relation rowtype_oid 1248 + ( + datname = name , + datdba = oid , + encoding = int4 , + datcollate = name , + datctype = name , + datistemplate = bool , + datallowconn = bool , + datconnlimit = int4 , + datlastsysoid = oid , + datfrozenxid = xid , + dattablespace = oid , + datacl = aclitem[] + ) +open pg_database +insert OID = 1 ( template1 10 ENCODING "LC_COLLATE" "LC_CTYPE" t t -1 0 0 1663 _null_) +close pg_database +create pg_db_role_setting 2964 shared_relation without_oids + ( + setdatabase = oid , + setrole = oid , + setconfig = text[] + ) +open pg_db_role_setting +close pg_db_role_setting +create pg_tablespace 1213 shared_relation + ( + spcname = name , + spcowner = oid , + spcacl = aclitem[] , + spcoptions = text[] + ) +open pg_tablespace +insert OID = 1663 ( pg_default 10 _null_ _null_ ) +insert OID = 1664 ( pg_global 10 _null_ _null_ ) +close pg_tablespace +create pg_pltemplate 1136 shared_relation without_oids + ( + tmplname = name , + tmpltrusted = bool , + tmpldbacreate = bool , + tmplhandler = text , + tmplinline = text , + tmplvalidator = text , + tmpllibrary = text , + tmplacl = aclitem[] + ) +open pg_pltemplate +insert ( "plpgsql" t t "plpgsql_call_handler" "plpgsql_inline_handler" "plpgsql_validator" "$libdir/plpgsql" _null_ ) +insert ( "pltcl" t t "pltcl_call_handler" _null_ _null_ "$libdir/pltcl" _null_ ) +insert ( "pltclu" f f "pltclu_call_handler" _null_ _null_ "$libdir/pltcl" _null_ ) +insert ( "plperl" t t "plperl_call_handler" "plperl_inline_handler" "plperl_validator" "$libdir/plperl" _null_ ) +insert ( "plperlu" f f "plperlu_call_handler" "plperlu_inline_handler" "plperlu_validator" "$libdir/plperl" _null_ ) +insert ( "plpythonu" f f "plpython_call_handler" "plpython_inline_handler" "plpython_validator" "$libdir/plpython2" _null_ ) +insert ( "plpython2u" f f "plpython2_call_handler" "plpython2_inline_handler" "plpython2_validator" "$libdir/plpython2" _null_ ) +insert ( "plpython3u" f f "plpython3_call_handler" "plpython3_inline_handler" "plpython3_validator" "$libdir/plpython3" _null_ ) +close pg_pltemplate +create pg_authid 1260 shared_relation rowtype_oid 2842 + ( + rolname = name , + rolsuper = bool , + rolinherit = bool , + rolcreaterole = bool , + rolcreatedb = bool , + rolcatupdate = bool , + rolcanlogin = bool , + rolreplication = bool , + rolconnlimit = int4 , + rolpassword = text , + rolvaliduntil = timestamptz + ) +open pg_authid +insert OID = 10 ( "POSTGRES" t t t t t t t -1 _null_ _null_ ) +close pg_authid +create pg_auth_members 1261 shared_relation without_oids rowtype_oid 2843 + ( + roleid = oid , + member = oid , + grantor = oid , + admin_option = bool + ) +open pg_auth_members +close pg_auth_members +create pg_shdepend 1214 shared_relation without_oids + ( + dbid = oid , + classid = oid , + objid = oid , + objsubid = int4 , + refclassid = oid , + refobjid = oid , + deptype = char + ) +open pg_shdepend +close pg_shdepend +create pg_shdescription 2396 shared_relation without_oids + ( + objoid = oid , + classoid = oid , + description = text + ) +open pg_shdescription +close pg_shdescription +create pg_ts_config 3602 + ( + cfgname = name , + cfgnamespace = oid , + cfgowner = oid , + cfgparser = oid + ) +open pg_ts_config +insert OID = 3748 ( "simple" 11 10 3722 ) +close pg_ts_config +create pg_ts_config_map 3603 without_oids + ( + mapcfg = oid , + maptokentype = int4 , + mapseqno = int4 , + mapdict = oid + ) +open pg_ts_config_map +insert ( 3748 1 1 3765 ) +insert ( 3748 2 1 3765 ) +insert ( 3748 3 1 3765 ) +insert ( 3748 4 1 3765 ) +insert ( 3748 5 1 3765 ) +insert ( 3748 6 1 3765 ) +insert ( 3748 7 1 3765 ) +insert ( 3748 8 1 3765 ) +insert ( 3748 9 1 3765 ) +insert ( 3748 10 1 3765 ) +insert ( 3748 11 1 3765 ) +insert ( 3748 15 1 3765 ) +insert ( 3748 16 1 3765 ) +insert ( 3748 17 1 3765 ) +insert ( 3748 18 1 3765 ) +insert ( 3748 19 1 3765 ) +insert ( 3748 20 1 3765 ) +insert ( 3748 21 1 3765 ) +insert ( 3748 22 1 3765 ) +close pg_ts_config_map +create pg_ts_dict 3600 + ( + dictname = name , + dictnamespace = oid , + dictowner = oid , + dicttemplate = oid , + dictinitoption = text + ) +open pg_ts_dict +insert OID = 3765 ( "simple" 11 10 3727 _null_) +close pg_ts_dict +create pg_ts_parser 3601 + ( + prsname = name , + prsnamespace = oid , + prsstart = regproc , + prstoken = regproc , + prsend = regproc , + prsheadline = regproc , + prslextype = regproc + ) +open pg_ts_parser +insert OID = 3722 ( "default" 11 prsd_start prsd_nexttoken prsd_end prsd_headline prsd_lextype ) +close pg_ts_parser +create pg_ts_template 3764 + ( + tmplname = name , + tmplnamespace = oid , + tmplinit = regproc , + tmpllexize = regproc + ) +open pg_ts_template +insert OID = 3727 ( "simple" 11 dsimple_init dsimple_lexize ) +insert OID = 3730 ( "synonym" 11 dsynonym_init dsynonym_lexize ) +insert OID = 3733 ( "ispell" 11 dispell_init dispell_lexize ) +insert OID = 3742 ( "thesaurus" 11 thesaurus_init thesaurus_lexize ) +close pg_ts_template +create pg_extension 3079 + ( + extname = name , + extowner = oid , + extnamespace = oid , + extrelocatable = bool , + extversion = text , + extconfig = oid[] , + extcondition = text[] + ) +open pg_extension +close pg_extension +create pg_foreign_data_wrapper 2328 + ( + fdwname = name , + fdwowner = oid , + fdwhandler = oid , + fdwvalidator = oid , + fdwacl = aclitem[] , + fdwoptions = text[] + ) +open pg_foreign_data_wrapper +close pg_foreign_data_wrapper +create pg_foreign_server 1417 + ( + srvname = name , + srvowner = oid , + srvfdw = oid , + srvtype = text , + srvversion = text , + srvacl = aclitem[] , + srvoptions = text[] + ) +open pg_foreign_server +close pg_foreign_server +create pg_user_mapping 1418 + ( + umuser = oid , + umserver = oid , + umoptions = text[] + ) +open pg_user_mapping +close pg_user_mapping +create pg_foreign_table 3118 without_oids + ( + ftrelid = oid , + ftserver = oid , + ftoptions = text[] + ) +open pg_foreign_table +close pg_foreign_table +create pg_default_acl 826 + ( + defaclrole = oid , + defaclnamespace = oid , + defaclobjtype = char , + defaclacl = aclitem[] + ) +open pg_default_acl +close pg_default_acl +create pg_seclabel 3596 without_oids + ( + objoid = oid , + classoid = oid , + objsubid = int4 , + provider = text , + label = text + ) +open pg_seclabel +close pg_seclabel +create pg_shseclabel 3592 shared_relation without_oids + ( + objoid = oid , + classoid = oid , + provider = text , + label = text + ) +open pg_shseclabel +close pg_shseclabel +create pg_collation 3456 + ( + collname = name , + collnamespace = oid , + collowner = oid , + collencoding = int4 , + collcollate = name , + collctype = name + ) +open pg_collation +insert OID = 100 ( default 11 10 -1 "" "" ) +insert OID = 950 ( C 11 10 -1 "C" "C" ) +insert OID = 951 ( POSIX 11 10 -1 "POSIX" "POSIX" ) +close pg_collation +create pg_range 3541 without_oids + ( + rngtypid = oid , + rngsubtype = oid , + rngcollation = oid , + rngsubopc = oid , + rngcanonical = regproc , + rngsubdiff = regproc + ) +open pg_range +insert ( 3904 23 0 1978 int4range_canonical int4range_subdiff) +insert ( 3906 1700 0 3125 - numrange_subdiff) +insert ( 3908 1114 0 3128 - tsrange_subdiff) +insert ( 3910 1184 0 3127 - tstzrange_subdiff) +insert ( 3912 1082 0 3122 daterange_canonical daterange_subdiff) +insert ( 3926 20 0 3124 int8range_canonical int8range_subdiff) +close pg_range +declare toast 2830 2831 on pg_attrdef +declare toast 2832 2833 on pg_constraint +declare toast 2834 2835 on pg_description +declare toast 2836 2837 on pg_proc +declare toast 2838 2839 on pg_rewrite +declare toast 3598 3599 on pg_seclabel +declare toast 2840 2841 on pg_statistic +declare toast 2336 2337 on pg_trigger +declare toast 2846 2847 on pg_shdescription +declare toast 2966 2967 on pg_db_role_setting +declare unique index pg_aggregate_fnoid_index 2650 on pg_aggregate using btree(aggfnoid oid_ops) +declare unique index pg_am_name_index 2651 on pg_am using btree(amname name_ops) +declare unique index pg_am_oid_index 2652 on pg_am using btree(oid oid_ops) +declare unique index pg_amop_fam_strat_index 2653 on pg_amop using btree(amopfamily oid_ops, amoplefttype oid_ops, amoprighttype oid_ops, amopstrategy int2_ops) +declare unique index pg_amop_opr_fam_index 2654 on pg_amop using btree(amopopr oid_ops, amoppurpose char_ops, amopfamily oid_ops) +declare unique index pg_amop_oid_index 2756 on pg_amop using btree(oid oid_ops) +declare unique index pg_amproc_fam_proc_index 2655 on pg_amproc using btree(amprocfamily oid_ops, amproclefttype oid_ops, amprocrighttype oid_ops, amprocnum int2_ops) +declare unique index pg_amproc_oid_index 2757 on pg_amproc using btree(oid oid_ops) +declare unique index pg_attrdef_adrelid_adnum_index 2656 on pg_attrdef using btree(adrelid oid_ops, adnum int2_ops) +declare unique index pg_attrdef_oid_index 2657 on pg_attrdef using btree(oid oid_ops) +declare unique index pg_attribute_relid_attnam_index 2658 on pg_attribute using btree(attrelid oid_ops, attname name_ops) +declare unique index pg_attribute_relid_attnum_index 2659 on pg_attribute using btree(attrelid oid_ops, attnum int2_ops) +declare unique index pg_authid_rolname_index 2676 on pg_authid using btree(rolname name_ops) +declare unique index pg_authid_oid_index 2677 on pg_authid using btree(oid oid_ops) +declare unique index pg_auth_members_role_member_index 2694 on pg_auth_members using btree(roleid oid_ops, member oid_ops) +declare unique index pg_auth_members_member_role_index 2695 on pg_auth_members using btree(member oid_ops, roleid oid_ops) +declare unique index pg_cast_oid_index 2660 on pg_cast using btree(oid oid_ops) +declare unique index pg_cast_source_target_index 2661 on pg_cast using btree(castsource oid_ops, casttarget oid_ops) +declare unique index pg_class_oid_index 2662 on pg_class using btree(oid oid_ops) +declare unique index pg_class_relname_nsp_index 2663 on pg_class using btree(relname name_ops, relnamespace oid_ops) +declare unique index pg_collation_name_enc_nsp_index 3164 on pg_collation using btree(collname name_ops, collencoding int4_ops, collnamespace oid_ops) +declare unique index pg_collation_oid_index 3085 on pg_collation using btree(oid oid_ops) +declare index pg_constraint_conname_nsp_index 2664 on pg_constraint using btree(conname name_ops, connamespace oid_ops) +declare index pg_constraint_conrelid_index 2665 on pg_constraint using btree(conrelid oid_ops) +declare index pg_constraint_contypid_index 2666 on pg_constraint using btree(contypid oid_ops) +declare unique index pg_constraint_oid_index 2667 on pg_constraint using btree(oid oid_ops) +declare unique index pg_conversion_default_index 2668 on pg_conversion using btree(connamespace oid_ops, conforencoding int4_ops, contoencoding int4_ops, oid oid_ops) +declare unique index pg_conversion_name_nsp_index 2669 on pg_conversion using btree(conname name_ops, connamespace oid_ops) +declare unique index pg_conversion_oid_index 2670 on pg_conversion using btree(oid oid_ops) +declare unique index pg_database_datname_index 2671 on pg_database using btree(datname name_ops) +declare unique index pg_database_oid_index 2672 on pg_database using btree(oid oid_ops) +declare index pg_depend_depender_index 2673 on pg_depend using btree(classid oid_ops, objid oid_ops, objsubid int4_ops) +declare index pg_depend_reference_index 2674 on pg_depend using btree(refclassid oid_ops, refobjid oid_ops, refobjsubid int4_ops) +declare unique index pg_description_o_c_o_index 2675 on pg_description using btree(objoid oid_ops, classoid oid_ops, objsubid int4_ops) +declare unique index pg_shdescription_o_c_index 2397 on pg_shdescription using btree(objoid oid_ops, classoid oid_ops) +declare unique index pg_enum_oid_index 3502 on pg_enum using btree(oid oid_ops) +declare unique index pg_enum_typid_label_index 3503 on pg_enum using btree(enumtypid oid_ops, enumlabel name_ops) +declare unique index pg_enum_typid_sortorder_index 3534 on pg_enum using btree(enumtypid oid_ops, enumsortorder float4_ops) +declare index pg_index_indrelid_index 2678 on pg_index using btree(indrelid oid_ops) +declare unique index pg_index_indexrelid_index 2679 on pg_index using btree(indexrelid oid_ops) +declare unique index pg_inherits_relid_seqno_index 2680 on pg_inherits using btree(inhrelid oid_ops, inhseqno int4_ops) +declare index pg_inherits_parent_index 2187 on pg_inherits using btree(inhparent oid_ops) +declare unique index pg_language_name_index 2681 on pg_language using btree(lanname name_ops) +declare unique index pg_language_oid_index 2682 on pg_language using btree(oid oid_ops) +declare unique index pg_largeobject_loid_pn_index 2683 on pg_largeobject using btree(loid oid_ops, pageno int4_ops) +declare unique index pg_largeobject_metadata_oid_index 2996 on pg_largeobject_metadata using btree(oid oid_ops) +declare unique index pg_namespace_nspname_index 2684 on pg_namespace using btree(nspname name_ops) +declare unique index pg_namespace_oid_index 2685 on pg_namespace using btree(oid oid_ops) +declare unique index pg_opclass_am_name_nsp_index 2686 on pg_opclass using btree(opcmethod oid_ops, opcname name_ops, opcnamespace oid_ops) +declare unique index pg_opclass_oid_index 2687 on pg_opclass using btree(oid oid_ops) +declare unique index pg_operator_oid_index 2688 on pg_operator using btree(oid oid_ops) +declare unique index pg_operator_oprname_l_r_n_index 2689 on pg_operator using btree(oprname name_ops, oprleft oid_ops, oprright oid_ops, oprnamespace oid_ops) +declare unique index pg_opfamily_am_name_nsp_index 2754 on pg_opfamily using btree(opfmethod oid_ops, opfname name_ops, opfnamespace oid_ops) +declare unique index pg_opfamily_oid_index 2755 on pg_opfamily using btree(oid oid_ops) +declare unique index pg_pltemplate_name_index 1137 on pg_pltemplate using btree(tmplname name_ops) +declare unique index pg_proc_oid_index 2690 on pg_proc using btree(oid oid_ops) +declare unique index pg_proc_proname_args_nsp_index 2691 on pg_proc using btree(proname name_ops, proargtypes oidvector_ops, pronamespace oid_ops) +declare unique index pg_rewrite_oid_index 2692 on pg_rewrite using btree(oid oid_ops) +declare unique index pg_rewrite_rel_rulename_index 2693 on pg_rewrite using btree(ev_class oid_ops, rulename name_ops) +declare index pg_shdepend_depender_index 1232 on pg_shdepend using btree(dbid oid_ops, classid oid_ops, objid oid_ops, objsubid int4_ops) +declare index pg_shdepend_reference_index 1233 on pg_shdepend using btree(refclassid oid_ops, refobjid oid_ops) +declare unique index pg_statistic_relid_att_inh_index 2696 on pg_statistic using btree(starelid oid_ops, staattnum int2_ops, stainherit bool_ops) +declare unique index pg_tablespace_oid_index 2697 on pg_tablespace using btree(oid oid_ops) +declare unique index pg_tablespace_spcname_index 2698 on pg_tablespace using btree(spcname name_ops) +declare index pg_trigger_tgconstraint_index 2699 on pg_trigger using btree(tgconstraint oid_ops) +declare unique index pg_trigger_tgrelid_tgname_index 2701 on pg_trigger using btree(tgrelid oid_ops, tgname name_ops) +declare unique index pg_trigger_oid_index 2702 on pg_trigger using btree(oid oid_ops) +declare unique index pg_ts_config_cfgname_index 3608 on pg_ts_config using btree(cfgname name_ops, cfgnamespace oid_ops) +declare unique index pg_ts_config_oid_index 3712 on pg_ts_config using btree(oid oid_ops) +declare unique index pg_ts_config_map_index 3609 on pg_ts_config_map using btree(mapcfg oid_ops, maptokentype int4_ops, mapseqno int4_ops) +declare unique index pg_ts_dict_dictname_index 3604 on pg_ts_dict using btree(dictname name_ops, dictnamespace oid_ops) +declare unique index pg_ts_dict_oid_index 3605 on pg_ts_dict using btree(oid oid_ops) +declare unique index pg_ts_parser_prsname_index 3606 on pg_ts_parser using btree(prsname name_ops, prsnamespace oid_ops) +declare unique index pg_ts_parser_oid_index 3607 on pg_ts_parser using btree(oid oid_ops) +declare unique index pg_ts_template_tmplname_index 3766 on pg_ts_template using btree(tmplname name_ops, tmplnamespace oid_ops) +declare unique index pg_ts_template_oid_index 3767 on pg_ts_template using btree(oid oid_ops) +declare unique index pg_type_oid_index 2703 on pg_type using btree(oid oid_ops) +declare unique index pg_type_typname_nsp_index 2704 on pg_type using btree(typname name_ops, typnamespace oid_ops) +declare unique index pg_foreign_data_wrapper_oid_index 112 on pg_foreign_data_wrapper using btree(oid oid_ops) +declare unique index pg_foreign_data_wrapper_name_index 548 on pg_foreign_data_wrapper using btree(fdwname name_ops) +declare unique index pg_foreign_server_oid_index 113 on pg_foreign_server using btree(oid oid_ops) +declare unique index pg_foreign_server_name_index 549 on pg_foreign_server using btree(srvname name_ops) +declare unique index pg_user_mapping_oid_index 174 on pg_user_mapping using btree(oid oid_ops) +declare unique index pg_user_mapping_user_server_index 175 on pg_user_mapping using btree(umuser oid_ops, umserver oid_ops) +declare unique index pg_foreign_table_relid_index 3119 on pg_foreign_table using btree(ftrelid oid_ops) +declare unique index pg_default_acl_role_nsp_obj_index 827 on pg_default_acl using btree(defaclrole oid_ops, defaclnamespace oid_ops, defaclobjtype char_ops) +declare unique index pg_default_acl_oid_index 828 on pg_default_acl using btree(oid oid_ops) +declare unique index pg_db_role_setting_databaseid_rol_index 2965 on pg_db_role_setting using btree(setdatabase oid_ops, setrole oid_ops) +declare unique index pg_seclabel_object_index 3597 on pg_seclabel using btree(objoid oid_ops, classoid oid_ops, objsubid int4_ops, provider text_ops) +declare unique index pg_shseclabel_object_index 3593 on pg_shseclabel using btree(objoid oid_ops, classoid oid_ops, provider text_ops) +declare unique index pg_extension_oid_index 3080 on pg_extension using btree(oid oid_ops) +declare unique index pg_extension_name_index 3081 on pg_extension using btree(extname name_ops) +declare unique index pg_range_rngtypid_index 3542 on pg_range using btree(rngtypid oid_ops) +build indices diff --git a/src/backend/catalog/postgres.description b/src/backend/catalog/postgres.description new file mode 100644 index 000000000..7028f8513 --- /dev/null +++ b/src/backend/catalog/postgres.description @@ -0,0 +1,2511 @@ +1242 pg_proc 0 I/O +1243 pg_proc 0 I/O +1244 pg_proc 0 I/O +31 pg_proc 0 I/O +1245 pg_proc 0 I/O +33 pg_proc 0 I/O +34 pg_proc 0 I/O +35 pg_proc 0 I/O +38 pg_proc 0 I/O +39 pg_proc 0 I/O +40 pg_proc 0 I/O +41 pg_proc 0 I/O +42 pg_proc 0 I/O +43 pg_proc 0 I/O +44 pg_proc 0 I/O +45 pg_proc 0 I/O +46 pg_proc 0 I/O +47 pg_proc 0 I/O +48 pg_proc 0 I/O +49 pg_proc 0 I/O +50 pg_proc 0 I/O +51 pg_proc 0 I/O +52 pg_proc 0 I/O +53 pg_proc 0 I/O +54 pg_proc 0 I/O +55 pg_proc 0 I/O +77 pg_proc 0 convert char to int4 +78 pg_proc 0 convert int4 to char +1257 pg_proc 0 length +89 pg_proc 0 PostgreSQL version string +101 pg_proc 0 restriction selectivity of = and related operators +102 pg_proc 0 restriction selectivity of <> and related operators +103 pg_proc 0 restriction selectivity of < and related operators on scalar datatypes +104 pg_proc 0 restriction selectivity of > and related operators on scalar datatypes +105 pg_proc 0 join selectivity of = and related operators +106 pg_proc 0 join selectivity of <> and related operators +107 pg_proc 0 join selectivity of < and related operators on scalar datatypes +108 pg_proc 0 join selectivity of > and related operators on scalar datatypes +109 pg_proc 0 I/O +110 pg_proc 0 I/O +117 pg_proc 0 I/O +118 pg_proc 0 I/O +119 pg_proc 0 I/O +120 pg_proc 0 I/O +121 pg_proc 0 I/O +122 pg_proc 0 I/O +123 pg_proc 0 I/O +124 pg_proc 0 I/O +139 pg_proc 0 restriction selectivity for area-comparison operators +140 pg_proc 0 join selectivity for area-comparison operators +195 pg_proc 0 I/O +196 pg_proc 0 I/O +197 pg_proc 0 I/O +198 pg_proc 0 I/O +200 pg_proc 0 I/O +201 pg_proc 0 I/O +208 pg_proc 0 aggregate transition function +209 pg_proc 0 larger of two +211 pg_proc 0 smaller of two +214 pg_proc 0 I/O +215 pg_proc 0 I/O +222 pg_proc 0 aggregate transition function +223 pg_proc 0 larger of two +224 pg_proc 0 smaller of two +228 pg_proc 0 round to nearest integer +229 pg_proc 0 truncate to integer +2308 pg_proc 0 smallest integer >= value +2320 pg_proc 0 smallest integer >= value +2309 pg_proc 0 largest integer <= value +2310 pg_proc 0 sign of value +233 pg_proc 0 natural exponential (e^x) +234 pg_proc 0 natural logarithm +235 pg_proc 0 convert int2 to float8 +236 pg_proc 0 convert int2 to float4 +237 pg_proc 0 convert float8 to int2 +238 pg_proc 0 convert float4 to int2 +240 pg_proc 0 I/O +241 pg_proc 0 I/O +242 pg_proc 0 I/O +243 pg_proc 0 I/O +246 pg_proc 0 I/O +247 pg_proc 0 I/O +249 pg_proc 0 tinterval to reltime +250 pg_proc 0 current date and time (abstime) +273 pg_proc 0 end of interval +274 pg_proc 0 current date and time - increments during transactions +275 pg_proc 0 finite abstime? +320 pg_proc 0 bucket number of operand in equidepth histogram +311 pg_proc 0 convert float4 to float8 +312 pg_proc 0 convert float8 to float4 +313 pg_proc 0 convert int2 to int4 +314 pg_proc 0 convert int4 to int2 +316 pg_proc 0 convert int4 to float8 +317 pg_proc 0 convert float8 to int4 +318 pg_proc 0 convert int4 to float4 +319 pg_proc 0 convert float4 to int4 +330 pg_proc 0 btree(internal) +636 pg_proc 0 btree(internal) +331 pg_proc 0 btree(internal) +333 pg_proc 0 btree(internal) +334 pg_proc 0 btree(internal) +335 pg_proc 0 btree(internal) +336 pg_proc 0 btree(internal) +337 pg_proc 0 btree(internal) +338 pg_proc 0 btree(internal) +328 pg_proc 0 btree(internal) +332 pg_proc 0 btree(internal) +972 pg_proc 0 btree(internal) +276 pg_proc 0 btree(internal) +1268 pg_proc 0 btree(internal) +2785 pg_proc 0 btree(internal) +347 pg_proc 0 I/O +348 pg_proc 0 I/O +350 pg_proc 0 less-equal-greater +3129 pg_proc 0 sort support +351 pg_proc 0 less-equal-greater +3130 pg_proc 0 sort support +842 pg_proc 0 less-equal-greater +3131 pg_proc 0 sort support +354 pg_proc 0 less-equal-greater +3132 pg_proc 0 sort support +355 pg_proc 0 less-equal-greater +3133 pg_proc 0 sort support +356 pg_proc 0 less-equal-greater +3134 pg_proc 0 sort support +404 pg_proc 0 less-equal-greater +357 pg_proc 0 less-equal-greater +358 pg_proc 0 less-equal-greater +359 pg_proc 0 less-equal-greater +3135 pg_proc 0 sort support +360 pg_proc 0 less-equal-greater +377 pg_proc 0 less-equal-greater +380 pg_proc 0 less-equal-greater +381 pg_proc 0 less-equal-greater +382 pg_proc 0 less-equal-greater +401 pg_proc 0 convert char(n) to text +406 pg_proc 0 convert name to text +407 pg_proc 0 convert text to name +408 pg_proc 0 convert name to char(n) +409 pg_proc 0 convert char(n) to name +440 pg_proc 0 hash(internal) +637 pg_proc 0 hash(internal) +441 pg_proc 0 hash(internal) +443 pg_proc 0 hash(internal) +444 pg_proc 0 hash(internal) +445 pg_proc 0 hash(internal) +446 pg_proc 0 hash(internal) +447 pg_proc 0 hash(internal) +448 pg_proc 0 hash(internal) +327 pg_proc 0 hash(internal) +442 pg_proc 0 hash(internal) +425 pg_proc 0 hash(internal) +438 pg_proc 0 hash(internal) +2786 pg_proc 0 hash(internal) +449 pg_proc 0 hash +450 pg_proc 0 hash +949 pg_proc 0 hash +451 pg_proc 0 hash +452 pg_proc 0 hash +453 pg_proc 0 hash +454 pg_proc 0 hash +455 pg_proc 0 hash +400 pg_proc 0 hash +456 pg_proc 0 hash +457 pg_proc 0 hash +329 pg_proc 0 hash +398 pg_proc 0 hash +399 pg_proc 0 hash +422 pg_proc 0 hash +432 pg_proc 0 hash +458 pg_proc 0 larger of two +459 pg_proc 0 smaller of two +460 pg_proc 0 I/O +461 pg_proc 0 I/O +480 pg_proc 0 convert int8 to int4 +481 pg_proc 0 convert int4 to int8 +482 pg_proc 0 convert int8 to float8 +483 pg_proc 0 convert float8 to int8 +626 pg_proc 0 hash +652 pg_proc 0 convert int8 to float4 +653 pg_proc 0 convert float4 to int8 +714 pg_proc 0 convert int8 to int2 +754 pg_proc 0 convert int2 to int8 +668 pg_proc 0 adjust char() to typmod length +3097 pg_proc 0 transform a varchar length coercion +669 pg_proc 0 adjust varchar() to typmod length +710 pg_proc 0 deprecated, use current_user instead +720 pg_proc 0 octet length +721 pg_proc 0 get byte +722 pg_proc 0 set byte +723 pg_proc 0 get bit +724 pg_proc 0 set bit +749 pg_proc 0 substitute portion of string +752 pg_proc 0 substitute portion of string +745 pg_proc 0 current user name +746 pg_proc 0 session user name +747 pg_proc 0 array dimensions +748 pg_proc 0 number of array dimensions +750 pg_proc 0 I/O +751 pg_proc 0 I/O +2091 pg_proc 0 array lower dimension +2092 pg_proc 0 array upper dimension +2176 pg_proc 0 array length +378 pg_proc 0 append element onto end of array +379 pg_proc 0 prepend element onto front of array +394 pg_proc 0 split delimited text into text[] +395 pg_proc 0 concatenate array elements, using delimiter, into text +376 pg_proc 0 split delimited text into text[], with null string +384 pg_proc 0 concatenate array elements, using delimiter and null string, into text +515 pg_proc 0 larger of two +516 pg_proc 0 smaller of two +1191 pg_proc 0 array subscripts generator +1192 pg_proc 0 array subscripts generator +1193 pg_proc 0 array constructor with value +1286 pg_proc 0 array constructor with value +2331 pg_proc 0 expand array to set of rows +2333 pg_proc 0 aggregate transition function +2334 pg_proc 0 aggregate final function +2335 pg_proc 0 concatenate aggregate input into an array +3816 pg_proc 0 array typanalyze +3817 pg_proc 0 restriction selectivity for array-containment operators +3818 pg_proc 0 join selectivity for array-containment operators +760 pg_proc 0 I/O +761 pg_proc 0 I/O +762 pg_proc 0 storage manager +763 pg_proc 0 storage manager +764 pg_proc 0 large object import +767 pg_proc 0 large object import +765 pg_proc 0 large object export +766 pg_proc 0 increment +768 pg_proc 0 larger of two +769 pg_proc 0 smaller of two +770 pg_proc 0 larger of two +771 pg_proc 0 smaller of two +774 pg_proc 0 gist(internal) +638 pg_proc 0 gist(internal) +775 pg_proc 0 gist(internal) +777 pg_proc 0 gist(internal) +778 pg_proc 0 gist(internal) +779 pg_proc 0 gist(internal) +780 pg_proc 0 gist(internal) +781 pg_proc 0 gist(internal) +782 pg_proc 0 gist(internal) +326 pg_proc 0 gist(internal) +776 pg_proc 0 gist(internal) +2561 pg_proc 0 gist(internal) +772 pg_proc 0 gist(internal) +2787 pg_proc 0 gist(internal) +849 pg_proc 0 position of substring +860 pg_proc 0 convert char to char(n) +861 pg_proc 0 name of the current database +817 pg_proc 0 get the currently executing query +886 pg_proc 0 I/O +887 pg_proc 0 I/O +898 pg_proc 0 larger of two +899 pg_proc 0 smaller of two +935 pg_proc 0 output money amount as words +3823 pg_proc 0 convert money to numeric +3824 pg_proc 0 convert numeric to money +3811 pg_proc 0 convert int4 to money +3812 pg_proc 0 convert int8 to money +940 pg_proc 0 modulus +941 pg_proc 0 modulus +947 pg_proc 0 modulus +944 pg_proc 0 convert text to char +946 pg_proc 0 convert char to text +952 pg_proc 0 large object open +953 pg_proc 0 large object close +954 pg_proc 0 large object read +955 pg_proc 0 large object write +956 pg_proc 0 large object seek +957 pg_proc 0 large object create +715 pg_proc 0 large object create +958 pg_proc 0 large object position +1004 pg_proc 0 truncate large object +964 pg_proc 0 large object unlink (delete) +975 pg_proc 0 box area +976 pg_proc 0 box width +977 pg_proc 0 box height +979 pg_proc 0 area of a closed path +981 pg_proc 0 box diagonal +992 pg_proc 0 slope between points +993 pg_proc 0 convert points to line segment +1026 pg_proc 0 adjust timestamp to new time zone +1031 pg_proc 0 I/O +1032 pg_proc 0 I/O +1035 pg_proc 0 add/update ACL item +1036 pg_proc 0 remove ACL item +1037 pg_proc 0 contains +1365 pg_proc 0 make ACL item +3943 pg_proc 0 TODO +1689 pg_proc 0 convert ACL item array to table, for use by information schema +1044 pg_proc 0 I/O +1045 pg_proc 0 I/O +2913 pg_proc 0 I/O typmod +2914 pg_proc 0 I/O typmod +1046 pg_proc 0 I/O +1047 pg_proc 0 I/O +2915 pg_proc 0 I/O typmod +2916 pg_proc 0 I/O typmod +1063 pg_proc 0 larger of two +1064 pg_proc 0 smaller of two +1078 pg_proc 0 less-equal-greater +1080 pg_proc 0 hash +1081 pg_proc 0 format a type oid and atttypmod to canonical SQL +1084 pg_proc 0 I/O +1085 pg_proc 0 I/O +1092 pg_proc 0 less-equal-greater +3136 pg_proc 0 sort support +1107 pg_proc 0 less-equal-greater +1138 pg_proc 0 larger of two +1139 pg_proc 0 smaller of two +1143 pg_proc 0 I/O +1144 pg_proc 0 I/O +2909 pg_proc 0 I/O typmod +2910 pg_proc 0 I/O typmod +1150 pg_proc 0 I/O +1151 pg_proc 0 I/O +2907 pg_proc 0 I/O typmod +2908 pg_proc 0 I/O typmod +1158 pg_proc 0 convert UNIX epoch to timestamptz +1159 pg_proc 0 adjust timestamp to new time zone +1160 pg_proc 0 I/O +1161 pg_proc 0 I/O +2903 pg_proc 0 I/O typmod +2904 pg_proc 0 I/O typmod +1171 pg_proc 0 extract field from timestamp with time zone +1172 pg_proc 0 extract field from interval +1173 pg_proc 0 convert abstime to timestamp with time zone +1174 pg_proc 0 convert date to timestamp with time zone +2711 pg_proc 0 promote groups of 24 hours to numbers of days and promote groups of 30 days to numbers of months +1175 pg_proc 0 promote groups of 24 hours to numbers of days +1295 pg_proc 0 promote groups of 30 days to numbers of months +1176 pg_proc 0 convert date and time to timestamp with time zone +1177 pg_proc 0 convert reltime to interval +1178 pg_proc 0 convert timestamp with time zone to date +1179 pg_proc 0 convert abstime to date +1180 pg_proc 0 convert timestamp with time zone to abstime +1181 pg_proc 0 age of a transaction ID, in transactions before current transaction +1194 pg_proc 0 convert interval to reltime +1195 pg_proc 0 smaller of two +1196 pg_proc 0 larger of two +1197 pg_proc 0 smaller of two +1198 pg_proc 0 larger of two +1199 pg_proc 0 date difference preserving months and years +3918 pg_proc 0 transform an interval length coercion +1200 pg_proc 0 adjust interval precision +1215 pg_proc 0 get description for object id and catalog name +1216 pg_proc 0 get description for table column +1993 pg_proc 0 get description for object id and shared catalog name +1217 pg_proc 0 truncate timestamp with time zone to specified units +1218 pg_proc 0 truncate interval to specified units +1219 pg_proc 0 increment +2804 pg_proc 0 increment, ignores second argument +1236 pg_proc 0 larger of two +1237 pg_proc 0 smaller of two +1271 pg_proc 0 intervals overlap? +1273 pg_proc 0 extract field from time with time zone +1287 pg_proc 0 convert int8 to oid +1288 pg_proc 0 convert oid to int8 +1291 pg_proc 0 trigger to suppress updates when new and old records match +1293 pg_proc 0 latest tid of a tuple +1294 pg_proc 0 latest tid of a tuple +2794 pg_proc 0 less-equal-greater +2795 pg_proc 0 larger of two +2796 pg_proc 0 smaller of two +1299 pg_proc 0 current transaction time +2647 pg_proc 0 current transaction time +2648 pg_proc 0 current statement time +2649 pg_proc 0 current clock time +1300 pg_proc 0 restriction selectivity for position-comparison operators +1301 pg_proc 0 join selectivity for position-comparison operators +1302 pg_proc 0 restriction selectivity for containment comparison operators +1303 pg_proc 0 join selectivity for containment comparison operators +1304 pg_proc 0 intervals overlap? +1305 pg_proc 0 intervals overlap? +1306 pg_proc 0 intervals overlap? +1307 pg_proc 0 intervals overlap? +1308 pg_proc 0 intervals overlap? +1309 pg_proc 0 intervals overlap? +1310 pg_proc 0 intervals overlap? +1311 pg_proc 0 intervals overlap? +1312 pg_proc 0 I/O +1313 pg_proc 0 I/O +2905 pg_proc 0 I/O typmod +2906 pg_proc 0 I/O typmod +1314 pg_proc 0 less-equal-greater +1315 pg_proc 0 less-equal-greater +1316 pg_proc 0 convert timestamp to time +1317 pg_proc 0 length +1318 pg_proc 0 character length +1339 pg_proc 0 base 10 logarithm +1340 pg_proc 0 base 10 logarithm +1341 pg_proc 0 natural logarithm +1342 pg_proc 0 round to nearest integer +1343 pg_proc 0 truncate to integer +1344 pg_proc 0 square root +1345 pg_proc 0 cube root +1346 pg_proc 0 exponentiation +1368 pg_proc 0 exponentiation +1347 pg_proc 0 natural exponential (e^x) +1348 pg_proc 0 deprecated, use two-argument form instead +1349 pg_proc 0 print type names of oidvector field +1350 pg_proc 0 I/O +1351 pg_proc 0 I/O +2911 pg_proc 0 I/O typmod +2912 pg_proc 0 I/O typmod +1358 pg_proc 0 less-equal-greater +1359 pg_proc 0 convert date and time with time zone to timestamp with time zone +1364 pg_proc 0 convert abstime to time +1367 pg_proc 0 character length +1369 pg_proc 0 character length +1370 pg_proc 0 convert time to interval +1372 pg_proc 0 character length +1374 pg_proc 0 octet length +1375 pg_proc 0 octet length +1377 pg_proc 0 larger of two +1378 pg_proc 0 smaller of two +1379 pg_proc 0 larger of two +1380 pg_proc 0 smaller of two +1381 pg_proc 0 character length +1382 pg_proc 0 extract field from abstime +1383 pg_proc 0 extract field from reltime +1384 pg_proc 0 extract field from date +1385 pg_proc 0 extract field from time +1386 pg_proc 0 date difference from today preserving months and years +1388 pg_proc 0 convert timestamp with time zone to time with time zone +1373 pg_proc 0 finite date? +1389 pg_proc 0 finite timestamp? +1390 pg_proc 0 finite interval? +1376 pg_proc 0 factorial +1394 pg_proc 0 absolute value +1395 pg_proc 0 absolute value +1396 pg_proc 0 absolute value +1397 pg_proc 0 absolute value +1398 pg_proc 0 absolute value +1400 pg_proc 0 convert varchar to name +1401 pg_proc 0 convert name to varchar +1402 pg_proc 0 current schema name +1403 pg_proc 0 current schema search list +1404 pg_proc 0 substitute portion of string +1405 pg_proc 0 substitute portion of string +1406 pg_proc 0 vertically aligned +1407 pg_proc 0 horizontally aligned +1408 pg_proc 0 parallel +1409 pg_proc 0 perpendicular +1410 pg_proc 0 vertical +1411 pg_proc 0 horizontal +1412 pg_proc 0 parallel +1413 pg_proc 0 perpendicular +1414 pg_proc 0 vertical +1415 pg_proc 0 horizontal +1416 pg_proc 0 center of +1419 pg_proc 0 convert interval to time +1421 pg_proc 0 convert points to box +1430 pg_proc 0 path closed? +1431 pg_proc 0 path open? +1433 pg_proc 0 close path +1434 pg_proc 0 open path +1440 pg_proc 0 convert x, y to point +1446 pg_proc 0 convert polygon to bounding box +1447 pg_proc 0 convert polygon to path +1448 pg_proc 0 convert box to polygon +1449 pg_proc 0 convert path to polygon +1450 pg_proc 0 I/O +1451 pg_proc 0 I/O +1468 pg_proc 0 area of circle +1469 pg_proc 0 diameter of circle +1470 pg_proc 0 radius of circle +1473 pg_proc 0 convert point and radius to circle +1474 pg_proc 0 convert polygon to circle +1475 pg_proc 0 convert vertex count and circle to polygon +1479 pg_proc 0 convert box to circle +1480 pg_proc 0 convert circle to box +1481 pg_proc 0 convert to tinterval +1490 pg_proc 0 I/O +1491 pg_proc 0 I/O +1493 pg_proc 0 construct line from points +1530 pg_proc 0 distance between endpoints +1531 pg_proc 0 sum of path segments +1532 pg_proc 0 center of +1533 pg_proc 0 center of +1534 pg_proc 0 center of +1540 pg_proc 0 center of +1541 pg_proc 0 diagonal of +1542 pg_proc 0 center of +1543 pg_proc 0 center of +1544 pg_proc 0 convert circle to 12-vertex polygon +1545 pg_proc 0 number of points +1556 pg_proc 0 number of points +1564 pg_proc 0 I/O +1565 pg_proc 0 I/O +2919 pg_proc 0 I/O typmod +2920 pg_proc 0 I/O typmod +1569 pg_proc 0 matches LIKE expression +1570 pg_proc 0 does not match LIKE expression +1571 pg_proc 0 matches LIKE expression +1572 pg_proc 0 does not match LIKE expression +1574 pg_proc 0 sequence next value +1575 pg_proc 0 sequence current value +1576 pg_proc 0 set sequence value +1765 pg_proc 0 set sequence value and is_called status +3078 pg_proc 0 sequence parameters, for use by information schema +1579 pg_proc 0 I/O +1580 pg_proc 0 I/O +2902 pg_proc 0 I/O typmod +2921 pg_proc 0 I/O typmod +1596 pg_proc 0 less-equal-greater +1598 pg_proc 0 random value +1599 pg_proc 0 set random seed +1600 pg_proc 0 arcsine +1601 pg_proc 0 arccosine +1602 pg_proc 0 arctangent +1603 pg_proc 0 arctangent, two arguments +1604 pg_proc 0 sine +1605 pg_proc 0 cosine +1606 pg_proc 0 tangent +1607 pg_proc 0 cotangent +1608 pg_proc 0 radians to degrees +1609 pg_proc 0 degrees to radians +1610 pg_proc 0 PI +1620 pg_proc 0 convert first char to int4 +1621 pg_proc 0 convert int4 to char +1622 pg_proc 0 replicate string n times +1623 pg_proc 0 convert SQL99 regexp pattern to POSIX style +1637 pg_proc 0 convert LIKE pattern to use backslash escapes +868 pg_proc 0 position of substring +870 pg_proc 0 lowercase +871 pg_proc 0 uppercase +872 pg_proc 0 capitalize each word +873 pg_proc 0 left-pad string to length +874 pg_proc 0 right-pad string to length +875 pg_proc 0 trim selected characters from left end of string +876 pg_proc 0 trim selected characters from right end of string +877 pg_proc 0 extract portion of string +878 pg_proc 0 map a set of characters appearing in string +879 pg_proc 0 left-pad string to length +880 pg_proc 0 right-pad string to length +881 pg_proc 0 trim spaces from left end of string +882 pg_proc 0 trim spaces from right end of string +883 pg_proc 0 extract portion of string +884 pg_proc 0 trim selected characters from both ends of string +885 pg_proc 0 trim spaces from both ends of string +936 pg_proc 0 extract portion of string +937 pg_proc 0 extract portion of string +2087 pg_proc 0 replace all occurrences in string of old_substr with new_substr +2284 pg_proc 0 replace text using regexp +2285 pg_proc 0 replace text using regexp +2763 pg_proc 0 find all match groups for regexp +2764 pg_proc 0 find all match groups for regexp +2088 pg_proc 0 split string by field_sep and return field_num +2765 pg_proc 0 split string by pattern +2766 pg_proc 0 split string by pattern +2767 pg_proc 0 split string by pattern +2768 pg_proc 0 split string by pattern +2089 pg_proc 0 convert int4 number to hex +2090 pg_proc 0 convert int8 number to hex +1039 pg_proc 0 encoding name of current database +810 pg_proc 0 encoding name of current database +1713 pg_proc 0 length of string in specified encoding +1714 pg_proc 0 convert string with specified source encoding name +1717 pg_proc 0 convert string with specified destination encoding name +1813 pg_proc 0 convert string with specified encoding names +1264 pg_proc 0 convert encoding name to encoding id +1597 pg_proc 0 convert encoding id to encoding name +2319 pg_proc 0 maximum octet length of a character in given encoding +1573 pg_proc 0 source text of a rule +1640 pg_proc 0 select statement of a view +1641 pg_proc 0 select statement of a view +1642 pg_proc 0 role name by OID (with fallback) +1643 pg_proc 0 index description +1662 pg_proc 0 trigger description +1387 pg_proc 0 constraint description +1716 pg_proc 0 deparse an encoded expression +1665 pg_proc 0 name of sequence for a serial column +2098 pg_proc 0 definition of a function +2162 pg_proc 0 argument list of a function +2232 pg_proc 0 identity argument list of a function +2165 pg_proc 0 result type of a function +1686 pg_proc 0 list of SQL keywords +2289 pg_proc 0 convert generic options array to name/value table +1619 pg_proc 0 type of the argument +3162 pg_proc 0 collation of the argument; implementation of the COLLATION FOR expression +1250 pg_proc 0 deferred UNIQUE constraint check +1644 pg_proc 0 referential integrity FOREIGN KEY ... REFERENCES +1645 pg_proc 0 referential integrity FOREIGN KEY ... REFERENCES +1646 pg_proc 0 referential integrity ON DELETE CASCADE +1647 pg_proc 0 referential integrity ON UPDATE CASCADE +1648 pg_proc 0 referential integrity ON DELETE RESTRICT +1649 pg_proc 0 referential integrity ON UPDATE RESTRICT +1650 pg_proc 0 referential integrity ON DELETE SET NULL +1651 pg_proc 0 referential integrity ON UPDATE SET NULL +1652 pg_proc 0 referential integrity ON DELETE SET DEFAULT +1653 pg_proc 0 referential integrity ON UPDATE SET DEFAULT +1654 pg_proc 0 referential integrity ON DELETE NO ACTION +1655 pg_proc 0 referential integrity ON UPDATE NO ACTION +1672 pg_proc 0 less-equal-greater +1680 pg_proc 0 extract portion of bitstring +1681 pg_proc 0 bitstring length +1682 pg_proc 0 octet length +1683 pg_proc 0 convert int4 to bitstring +1684 pg_proc 0 convert bitstring to int4 +1685 pg_proc 0 adjust bit() to typmod length +3158 pg_proc 0 transform a varbit length coercion +1687 pg_proc 0 adjust varbit() to typmod length +1698 pg_proc 0 position of sub-bitstring +1699 pg_proc 0 extract portion of bitstring +3030 pg_proc 0 substitute portion of bitstring +3031 pg_proc 0 substitute portion of bitstring +3032 pg_proc 0 get bit +3033 pg_proc 0 set bit +436 pg_proc 0 I/O +437 pg_proc 0 I/O +753 pg_proc 0 MAC manufacturer fields +836 pg_proc 0 less-equal-greater +910 pg_proc 0 I/O +911 pg_proc 0 I/O +1267 pg_proc 0 I/O +1427 pg_proc 0 I/O +926 pg_proc 0 less-equal-greater +598 pg_proc 0 abbreviated display of inet value +599 pg_proc 0 abbreviated display of cidr value +605 pg_proc 0 change netmask of inet +635 pg_proc 0 change netmask of cidr +711 pg_proc 0 address family (4 for IPv4, 6 for IPv6) +683 pg_proc 0 network part of address +696 pg_proc 0 netmask of address +697 pg_proc 0 netmask length +698 pg_proc 0 broadcast address of network +699 pg_proc 0 show address octets only +730 pg_proc 0 show all parts of inet/cidr value +1362 pg_proc 0 hostmask of address +1715 pg_proc 0 convert inet to cidr +2196 pg_proc 0 inet address of the client +2197 pg_proc 0 client's port number for this connection +2198 pg_proc 0 inet address of the server +2199 pg_proc 0 server's port number for this connection +1693 pg_proc 0 less-equal-greater +1688 pg_proc 0 hash +1696 pg_proc 0 hash +1697 pg_proc 0 hash +1701 pg_proc 0 I/O +1702 pg_proc 0 I/O +2917 pg_proc 0 I/O typmod +2918 pg_proc 0 I/O typmod +3157 pg_proc 0 transform a numeric length coercion +1703 pg_proc 0 adjust numeric to typmod precision/scale +1705 pg_proc 0 absolute value +1706 pg_proc 0 sign of value +1707 pg_proc 0 value rounded to 'scale' +1708 pg_proc 0 value rounded to 'scale' of zero +1709 pg_proc 0 value truncated to 'scale' +1710 pg_proc 0 value truncated to 'scale' of zero +1711 pg_proc 0 smallest integer >= value +2167 pg_proc 0 smallest integer >= value +1712 pg_proc 0 largest integer <= value +1728 pg_proc 0 modulus +1730 pg_proc 0 square root +1731 pg_proc 0 square root +1732 pg_proc 0 natural exponential (e^x) +1733 pg_proc 0 natural exponential (e^x) +1734 pg_proc 0 natural logarithm +1735 pg_proc 0 natural logarithm +1736 pg_proc 0 logarithm base m of n +1737 pg_proc 0 logarithm base m of n +1738 pg_proc 0 exponentiation +2169 pg_proc 0 exponentiation +1740 pg_proc 0 convert int4 to numeric +1741 pg_proc 0 base 10 logarithm +1742 pg_proc 0 convert float4 to numeric +1743 pg_proc 0 convert float8 to numeric +1744 pg_proc 0 convert numeric to int4 +1745 pg_proc 0 convert numeric to float4 +1746 pg_proc 0 convert numeric to float8 +1973 pg_proc 0 trunc(x/y) +1980 pg_proc 0 trunc(x/y) +2170 pg_proc 0 bucket number of operand in equidepth histogram +1764 pg_proc 0 increment by one +1766 pg_proc 0 smaller of two +1767 pg_proc 0 larger of two +1769 pg_proc 0 less-equal-greater +1779 pg_proc 0 convert numeric to int8 +1781 pg_proc 0 convert int8 to numeric +1782 pg_proc 0 convert int2 to numeric +1783 pg_proc 0 convert numeric to int2 +1770 pg_proc 0 format timestamp with time zone to text +1772 pg_proc 0 format numeric to text +1773 pg_proc 0 format int4 to text +1774 pg_proc 0 format int8 to text +1775 pg_proc 0 format float4 to text +1776 pg_proc 0 format float8 to text +1777 pg_proc 0 convert text to numeric +1778 pg_proc 0 convert text to timestamp with time zone +1780 pg_proc 0 convert text to date +1768 pg_proc 0 format interval to text +1282 pg_proc 0 quote an identifier for usage in a querystring +1283 pg_proc 0 quote a literal for usage in a querystring +1285 pg_proc 0 quote a data value for usage in a querystring +1289 pg_proc 0 quote a possibly-null literal for usage in a querystring +1290 pg_proc 0 quote a possibly-null data value for usage in a querystring +1798 pg_proc 0 I/O +1799 pg_proc 0 I/O +3058 pg_proc 0 concatenate values +3059 pg_proc 0 concatenate values with separators +3060 pg_proc 0 extract the first n characters +3061 pg_proc 0 extract the last n characters +3062 pg_proc 0 reverse text +3539 pg_proc 0 format text message +3540 pg_proc 0 format text message +1810 pg_proc 0 length in bits +1811 pg_proc 0 length in bits +1812 pg_proc 0 length in bits +1814 pg_proc 0 restriction selectivity of ILIKE +1815 pg_proc 0 restriction selectivity of NOT ILIKE +1816 pg_proc 0 join selectivity of ILIKE +1817 pg_proc 0 join selectivity of NOT ILIKE +1818 pg_proc 0 restriction selectivity of regex match +1819 pg_proc 0 restriction selectivity of LIKE +1820 pg_proc 0 restriction selectivity of case-insensitive regex match +1821 pg_proc 0 restriction selectivity of regex non-match +1822 pg_proc 0 restriction selectivity of NOT LIKE +1823 pg_proc 0 restriction selectivity of case-insensitive regex non-match +1824 pg_proc 0 join selectivity of regex match +1825 pg_proc 0 join selectivity of LIKE +1826 pg_proc 0 join selectivity of case-insensitive regex match +1827 pg_proc 0 join selectivity of regex non-match +1828 pg_proc 0 join selectivity of NOT LIKE +1829 pg_proc 0 join selectivity of case-insensitive regex non-match +1830 pg_proc 0 aggregate final function +2512 pg_proc 0 aggregate final function +1831 pg_proc 0 aggregate final function +2513 pg_proc 0 aggregate final function +1832 pg_proc 0 aggregate final function +1833 pg_proc 0 aggregate transition function +2858 pg_proc 0 aggregate transition function +1834 pg_proc 0 aggregate transition function +1835 pg_proc 0 aggregate transition function +1836 pg_proc 0 aggregate transition function +2746 pg_proc 0 aggregate transition function +1837 pg_proc 0 aggregate final function +2514 pg_proc 0 aggregate final function +1838 pg_proc 0 aggregate final function +2596 pg_proc 0 aggregate final function +1839 pg_proc 0 aggregate final function +1840 pg_proc 0 aggregate transition function +1841 pg_proc 0 aggregate transition function +1842 pg_proc 0 aggregate transition function +1843 pg_proc 0 aggregate transition function +1844 pg_proc 0 aggregate final function +1962 pg_proc 0 aggregate transition function +1963 pg_proc 0 aggregate transition function +1964 pg_proc 0 aggregate final function +2805 pg_proc 0 aggregate transition function +2806 pg_proc 0 aggregate transition function +2807 pg_proc 0 aggregate final function +2808 pg_proc 0 aggregate final function +2809 pg_proc 0 aggregate final function +2810 pg_proc 0 aggregate final function +2811 pg_proc 0 aggregate final function +2812 pg_proc 0 aggregate final function +2813 pg_proc 0 aggregate final function +2814 pg_proc 0 aggregate final function +2815 pg_proc 0 aggregate final function +2816 pg_proc 0 aggregate final function +2817 pg_proc 0 aggregate final function +3535 pg_proc 0 aggregate transition function +3536 pg_proc 0 aggregate final function +3538 pg_proc 0 concatenate aggregate input into a string +3543 pg_proc 0 aggregate transition function +3544 pg_proc 0 aggregate final function +3545 pg_proc 0 concatenate aggregate input into a bytea +1845 pg_proc 0 encode text from DB encoding to ASCII text +1846 pg_proc 0 encode text from encoding to ASCII text +1847 pg_proc 0 encode text from encoding to ASCII text +1922 pg_proc 0 user privilege on relation by username, rel name +1923 pg_proc 0 user privilege on relation by username, rel oid +1924 pg_proc 0 user privilege on relation by user oid, rel name +1925 pg_proc 0 user privilege on relation by user oid, rel oid +1926 pg_proc 0 current user privilege on relation by rel name +1927 pg_proc 0 current user privilege on relation by rel oid +2181 pg_proc 0 user privilege on sequence by username, seq name +2182 pg_proc 0 user privilege on sequence by username, seq oid +2183 pg_proc 0 user privilege on sequence by user oid, seq name +2184 pg_proc 0 user privilege on sequence by user oid, seq oid +2185 pg_proc 0 current user privilege on sequence by seq name +2186 pg_proc 0 current user privilege on sequence by seq oid +3012 pg_proc 0 user privilege on column by username, rel name, col name +3013 pg_proc 0 user privilege on column by username, rel name, col attnum +3014 pg_proc 0 user privilege on column by username, rel oid, col name +3015 pg_proc 0 user privilege on column by username, rel oid, col attnum +3016 pg_proc 0 user privilege on column by user oid, rel name, col name +3017 pg_proc 0 user privilege on column by user oid, rel name, col attnum +3018 pg_proc 0 user privilege on column by user oid, rel oid, col name +3019 pg_proc 0 user privilege on column by user oid, rel oid, col attnum +3020 pg_proc 0 current user privilege on column by rel name, col name +3021 pg_proc 0 current user privilege on column by rel name, col attnum +3022 pg_proc 0 current user privilege on column by rel oid, col name +3023 pg_proc 0 current user privilege on column by rel oid, col attnum +3024 pg_proc 0 user privilege on any column by username, rel name +3025 pg_proc 0 user privilege on any column by username, rel oid +3026 pg_proc 0 user privilege on any column by user oid, rel name +3027 pg_proc 0 user privilege on any column by user oid, rel oid +3028 pg_proc 0 current user privilege on any column by rel name +3029 pg_proc 0 current user privilege on any column by rel oid +1928 pg_proc 0 statistics: number of scans done for table/index +1929 pg_proc 0 statistics: number of tuples read by seqscan +1930 pg_proc 0 statistics: number of tuples fetched by idxscan +1931 pg_proc 0 statistics: number of tuples inserted +1932 pg_proc 0 statistics: number of tuples updated +1933 pg_proc 0 statistics: number of tuples deleted +1972 pg_proc 0 statistics: number of tuples hot updated +2878 pg_proc 0 statistics: number of live tuples +2879 pg_proc 0 statistics: number of dead tuples +1934 pg_proc 0 statistics: number of blocks fetched +1935 pg_proc 0 statistics: number of blocks found in cache +2781 pg_proc 0 statistics: last manual vacuum time for a table +2782 pg_proc 0 statistics: last auto vacuum time for a table +2783 pg_proc 0 statistics: last manual analyze time for a table +2784 pg_proc 0 statistics: last auto analyze time for a table +3054 pg_proc 0 statistics: number of manual vacuums for a table +3055 pg_proc 0 statistics: number of auto vacuums for a table +3056 pg_proc 0 statistics: number of manual analyzes for a table +3057 pg_proc 0 statistics: number of auto analyzes for a table +1936 pg_proc 0 statistics: currently active backend IDs +2022 pg_proc 0 statistics: information about currently active backends +3099 pg_proc 0 statistics: information about currently active replication +2026 pg_proc 0 statistics: current backend PID +1937 pg_proc 0 statistics: PID of backend +1938 pg_proc 0 statistics: database ID of backend +1939 pg_proc 0 statistics: user ID of backend +1940 pg_proc 0 statistics: current query of backend +2853 pg_proc 0 statistics: is backend currently waiting for a lock +2094 pg_proc 0 statistics: start time for current query of backend +2857 pg_proc 0 statistics: start time for backend's current transaction +1391 pg_proc 0 statistics: start time for current backend session +1392 pg_proc 0 statistics: address of client connected to backend +1393 pg_proc 0 statistics: port number of client connected to backend +1941 pg_proc 0 statistics: number of backends in database +1942 pg_proc 0 statistics: transactions committed +1943 pg_proc 0 statistics: transactions rolled back +1944 pg_proc 0 statistics: blocks fetched for database +1945 pg_proc 0 statistics: blocks found in cache for database +2758 pg_proc 0 statistics: tuples returned for database +2759 pg_proc 0 statistics: tuples fetched for database +2760 pg_proc 0 statistics: tuples inserted in database +2761 pg_proc 0 statistics: tuples updated in database +2762 pg_proc 0 statistics: tuples deleted in database +3065 pg_proc 0 statistics: recovery conflicts in database caused by drop tablespace +3066 pg_proc 0 statistics: recovery conflicts in database caused by relation lock +3067 pg_proc 0 statistics: recovery conflicts in database caused by snapshot expiry +3068 pg_proc 0 statistics: recovery conflicts in database caused by shared buffer pin +3069 pg_proc 0 statistics: recovery conflicts in database caused by buffer deadlock +3070 pg_proc 0 statistics: recovery conflicts in database +3152 pg_proc 0 statistics: deadlocks detected in database +3074 pg_proc 0 statistics: last reset for a database +3150 pg_proc 0 statistics: number of temporary files written +3151 pg_proc 0 statistics: number of bytes in temporary files written +2844 pg_proc 0 statistics: block read time, in msec +2845 pg_proc 0 statistics: block write time, in msec +2769 pg_proc 0 statistics: number of timed checkpoints started by the bgwriter +2770 pg_proc 0 statistics: number of backend requested checkpoints started by the bgwriter +2771 pg_proc 0 statistics: number of buffers written by the bgwriter during checkpoints +2772 pg_proc 0 statistics: number of buffers written by the bgwriter for cleaning dirty buffers +2773 pg_proc 0 statistics: number of times the bgwriter stopped processing when it had written too many buffers while cleaning +3075 pg_proc 0 statistics: last reset for the bgwriter +3160 pg_proc 0 statistics: checkpoint time spent writing buffers to disk, in msec +3161 pg_proc 0 statistics: checkpoint time spent synchronizing buffers to disk, in msec +2775 pg_proc 0 statistics: number of buffers written by backends +3063 pg_proc 0 statistics: number of backend buffer writes that did their own fsync +2859 pg_proc 0 statistics: number of buffer allocations +2978 pg_proc 0 statistics: number of function calls +2979 pg_proc 0 statistics: total execution time of function, in msec +2980 pg_proc 0 statistics: self execution time of function, in msec +3037 pg_proc 0 statistics: number of scans done for table/index in current transaction +3038 pg_proc 0 statistics: number of tuples read by seqscan in current transaction +3039 pg_proc 0 statistics: number of tuples fetched by idxscan in current transaction +3040 pg_proc 0 statistics: number of tuples inserted in current transaction +3041 pg_proc 0 statistics: number of tuples updated in current transaction +3042 pg_proc 0 statistics: number of tuples deleted in current transaction +3043 pg_proc 0 statistics: number of tuples hot updated in current transaction +3044 pg_proc 0 statistics: number of blocks fetched in current transaction +3045 pg_proc 0 statistics: number of blocks found in cache in current transaction +3046 pg_proc 0 statistics: number of function calls in current transaction +3047 pg_proc 0 statistics: total execution time of function in current transaction, in msec +3048 pg_proc 0 statistics: self execution time of function in current transaction, in msec +2230 pg_proc 0 statistics: discard current transaction's statistics snapshot +2274 pg_proc 0 statistics: reset collected statistics for current database +3775 pg_proc 0 statistics: reset collected statistics shared across the cluster +3776 pg_proc 0 statistics: reset collected statistics for a single table or index in the current database +3777 pg_proc 0 statistics: reset collected statistics for a single function in the current database +3163 pg_proc 0 current trigger depth +3778 pg_proc 0 tablespace location +1946 pg_proc 0 convert bytea value into some ascii-only text string +1947 pg_proc 0 convert ascii-encoded text string into bytea value +1954 pg_proc 0 less-equal-greater +3917 pg_proc 0 transform a timestamp length coercion +3944 pg_proc 0 transform a time length coercion +1961 pg_proc 0 adjust timestamp precision +1965 pg_proc 0 larger of two +1966 pg_proc 0 smaller of two +1967 pg_proc 0 adjust timestamptz precision +1968 pg_proc 0 adjust time precision +1969 pg_proc 0 adjust time with time zone precision +2007 pg_proc 0 matches LIKE expression +2008 pg_proc 0 does not match LIKE expression +2009 pg_proc 0 convert LIKE pattern to use backslash escapes +2010 pg_proc 0 octet length +2012 pg_proc 0 extract portion of string +2013 pg_proc 0 extract portion of string +2085 pg_proc 0 extract portion of string +2086 pg_proc 0 extract portion of string +2014 pg_proc 0 position of substring +2015 pg_proc 0 trim both ends of string +2019 pg_proc 0 convert timestamp with time zone to time +2020 pg_proc 0 truncate timestamp to specified units +2021 pg_proc 0 extract field from timestamp +2023 pg_proc 0 convert abstime to timestamp +2024 pg_proc 0 convert date to timestamp +2025 pg_proc 0 convert date and time to timestamp +2027 pg_proc 0 convert timestamp with time zone to timestamp +2028 pg_proc 0 convert timestamp to timestamp with time zone +2029 pg_proc 0 convert timestamp to date +2030 pg_proc 0 convert timestamp to abstime +2035 pg_proc 0 smaller of two +2036 pg_proc 0 larger of two +2037 pg_proc 0 adjust time with time zone to new zone +2038 pg_proc 0 adjust time with time zone to new zone +2039 pg_proc 0 hash +2041 pg_proc 0 intervals overlap? +2042 pg_proc 0 intervals overlap? +2043 pg_proc 0 intervals overlap? +2044 pg_proc 0 intervals overlap? +2045 pg_proc 0 less-equal-greater +3137 pg_proc 0 sort support +2046 pg_proc 0 convert time with time zone to time +2047 pg_proc 0 convert time to time with time zone +2048 pg_proc 0 finite timestamp? +2049 pg_proc 0 format timestamp to text +2058 pg_proc 0 date difference preserving months and years +2059 pg_proc 0 date difference from today preserving months and years +2069 pg_proc 0 adjust timestamp to new time zone +2070 pg_proc 0 adjust timestamp to new time zone +2073 pg_proc 0 extract text matching regular expression +2074 pg_proc 0 extract text matching SQL99 regular expression +2075 pg_proc 0 convert int8 to bitstring +2076 pg_proc 0 convert bitstring to int8 +2077 pg_proc 0 SHOW X as a function +2078 pg_proc 0 SET X as a function +2084 pg_proc 0 SHOW ALL as a function +1371 pg_proc 0 view system lock information +1065 pg_proc 0 view two-phase transactions +3537 pg_proc 0 get identification of SQL object +2079 pg_proc 0 is table visible in search path? +2080 pg_proc 0 is type visible in search path? +2081 pg_proc 0 is function visible in search path? +2082 pg_proc 0 is operator visible in search path? +2083 pg_proc 0 is opclass visible in search path? +3829 pg_proc 0 is opfamily visible in search path? +2093 pg_proc 0 is conversion visible in search path? +3756 pg_proc 0 is text search parser visible in search path? +3757 pg_proc 0 is text search dictionary visible in search path? +3768 pg_proc 0 is text search template visible in search path? +3758 pg_proc 0 is text search configuration visible in search path? +3815 pg_proc 0 is collation visible in search path? +2854 pg_proc 0 get OID of current session's temp schema, if any +2855 pg_proc 0 is schema another session's temp schema? +2171 pg_proc 0 cancel a server process' current query +2096 pg_proc 0 terminate a server process +2172 pg_proc 0 prepare for taking an online backup +2173 pg_proc 0 finish taking an online backup +2848 pg_proc 0 switch to new xlog file +3098 pg_proc 0 create a named restore point +2849 pg_proc 0 current xlog write location +2852 pg_proc 0 current xlog insert location +2850 pg_proc 0 xlog filename and byte offset, given an xlog location +2851 pg_proc 0 xlog filename, given an xlog location +3165 pg_proc 0 difference in bytes, given two xlog locations +3809 pg_proc 0 export a snapshot +3810 pg_proc 0 true if server is in recovery +3820 pg_proc 0 current xlog flush location +3821 pg_proc 0 last xlog replay location +3830 pg_proc 0 timestamp of last replay xact +3071 pg_proc 0 pause xlog replay +3072 pg_proc 0 resume xlog replay, if it was paused +3073 pg_proc 0 true if xlog replay is paused +2621 pg_proc 0 reload configuration files +2622 pg_proc 0 rotate log file +2623 pg_proc 0 get information about file +2624 pg_proc 0 read text from a file +3826 pg_proc 0 read text from a file +3827 pg_proc 0 read bytea from a file +3828 pg_proc 0 read bytea from a file +2625 pg_proc 0 list all files in a directory +2626 pg_proc 0 sleep for the specified time in seconds +2971 pg_proc 0 convert boolean to text +2100 pg_proc 0 the average (arithmetic mean) as numeric of all bigint values +2101 pg_proc 0 the average (arithmetic mean) as numeric of all integer values +2102 pg_proc 0 the average (arithmetic mean) as numeric of all smallint values +2103 pg_proc 0 the average (arithmetic mean) as numeric of all numeric values +2104 pg_proc 0 the average (arithmetic mean) as float8 of all float4 values +2105 pg_proc 0 the average (arithmetic mean) as float8 of all float8 values +2106 pg_proc 0 the average (arithmetic mean) as interval of all interval values +2107 pg_proc 0 sum as numeric across all bigint input values +2108 pg_proc 0 sum as bigint across all integer input values +2109 pg_proc 0 sum as bigint across all smallint input values +2110 pg_proc 0 sum as float4 across all float4 input values +2111 pg_proc 0 sum as float8 across all float8 input values +2112 pg_proc 0 sum as money across all money input values +2113 pg_proc 0 sum as interval across all interval input values +2114 pg_proc 0 sum as numeric across all numeric input values +2115 pg_proc 0 maximum value of all bigint input values +2116 pg_proc 0 maximum value of all integer input values +2117 pg_proc 0 maximum value of all smallint input values +2118 pg_proc 0 maximum value of all oid input values +2119 pg_proc 0 maximum value of all float4 input values +2120 pg_proc 0 maximum value of all float8 input values +2121 pg_proc 0 maximum value of all abstime input values +2122 pg_proc 0 maximum value of all date input values +2123 pg_proc 0 maximum value of all time input values +2124 pg_proc 0 maximum value of all time with time zone input values +2125 pg_proc 0 maximum value of all money input values +2126 pg_proc 0 maximum value of all timestamp input values +2127 pg_proc 0 maximum value of all timestamp with time zone input values +2128 pg_proc 0 maximum value of all interval input values +2129 pg_proc 0 maximum value of all text input values +2130 pg_proc 0 maximum value of all numeric input values +2050 pg_proc 0 maximum value of all anyarray input values +2244 pg_proc 0 maximum value of all bpchar input values +2797 pg_proc 0 maximum value of all tid input values +2131 pg_proc 0 minimum value of all bigint input values +2132 pg_proc 0 minimum value of all integer input values +2133 pg_proc 0 minimum value of all smallint input values +2134 pg_proc 0 minimum value of all oid input values +2135 pg_proc 0 minimum value of all float4 input values +2136 pg_proc 0 minimum value of all float8 input values +2137 pg_proc 0 minimum value of all abstime input values +2138 pg_proc 0 minimum value of all date input values +2139 pg_proc 0 minimum value of all time input values +2140 pg_proc 0 minimum value of all time with time zone input values +2141 pg_proc 0 minimum value of all money input values +2142 pg_proc 0 minimum value of all timestamp input values +2143 pg_proc 0 minimum value of all timestamp with time zone input values +2144 pg_proc 0 minimum value of all interval input values +2145 pg_proc 0 minimum value of all text values +2146 pg_proc 0 minimum value of all numeric input values +2051 pg_proc 0 minimum value of all anyarray input values +2245 pg_proc 0 minimum value of all bpchar input values +2798 pg_proc 0 minimum value of all tid input values +2147 pg_proc 0 number of input rows for which the input expression is not null +2803 pg_proc 0 number of input rows +2718 pg_proc 0 population variance of bigint input values (square of the population standard deviation) +2719 pg_proc 0 population variance of integer input values (square of the population standard deviation) +2720 pg_proc 0 population variance of smallint input values (square of the population standard deviation) +2721 pg_proc 0 population variance of float4 input values (square of the population standard deviation) +2722 pg_proc 0 population variance of float8 input values (square of the population standard deviation) +2723 pg_proc 0 population variance of numeric input values (square of the population standard deviation) +2641 pg_proc 0 sample variance of bigint input values (square of the sample standard deviation) +2642 pg_proc 0 sample variance of integer input values (square of the sample standard deviation) +2643 pg_proc 0 sample variance of smallint input values (square of the sample standard deviation) +2644 pg_proc 0 sample variance of float4 input values (square of the sample standard deviation) +2645 pg_proc 0 sample variance of float8 input values (square of the sample standard deviation) +2646 pg_proc 0 sample variance of numeric input values (square of the sample standard deviation) +2148 pg_proc 0 historical alias for var_samp +2149 pg_proc 0 historical alias for var_samp +2150 pg_proc 0 historical alias for var_samp +2151 pg_proc 0 historical alias for var_samp +2152 pg_proc 0 historical alias for var_samp +2153 pg_proc 0 historical alias for var_samp +2724 pg_proc 0 population standard deviation of bigint input values +2725 pg_proc 0 population standard deviation of integer input values +2726 pg_proc 0 population standard deviation of smallint input values +2727 pg_proc 0 population standard deviation of float4 input values +2728 pg_proc 0 population standard deviation of float8 input values +2729 pg_proc 0 population standard deviation of numeric input values +2712 pg_proc 0 sample standard deviation of bigint input values +2713 pg_proc 0 sample standard deviation of integer input values +2714 pg_proc 0 sample standard deviation of smallint input values +2715 pg_proc 0 sample standard deviation of float4 input values +2716 pg_proc 0 sample standard deviation of float8 input values +2717 pg_proc 0 sample standard deviation of numeric input values +2154 pg_proc 0 historical alias for stddev_samp +2155 pg_proc 0 historical alias for stddev_samp +2156 pg_proc 0 historical alias for stddev_samp +2157 pg_proc 0 historical alias for stddev_samp +2158 pg_proc 0 historical alias for stddev_samp +2159 pg_proc 0 historical alias for stddev_samp +2818 pg_proc 0 number of input rows in which both expressions are not null +2819 pg_proc 0 sum of squares of the independent variable (sum(X^2) - sum(X)^2/N) +2820 pg_proc 0 sum of squares of the dependent variable (sum(Y^2) - sum(Y)^2/N) +2821 pg_proc 0 sum of products of independent times dependent variable (sum(X*Y) - sum(X) * sum(Y)/N) +2822 pg_proc 0 average of the independent variable (sum(X)/N) +2823 pg_proc 0 average of the dependent variable (sum(Y)/N) +2824 pg_proc 0 square of the correlation coefficient +2825 pg_proc 0 slope of the least-squares-fit linear equation determined by the (X, Y) pairs +2826 pg_proc 0 y-intercept of the least-squares-fit linear equation determined by the (X, Y) pairs +2827 pg_proc 0 population covariance +2828 pg_proc 0 sample covariance +2829 pg_proc 0 correlation coefficient +2166 pg_proc 0 less-equal-greater +2180 pg_proc 0 less-equal-greater +2188 pg_proc 0 less-equal-greater +2189 pg_proc 0 less-equal-greater +2190 pg_proc 0 less-equal-greater +2191 pg_proc 0 less-equal-greater +2192 pg_proc 0 less-equal-greater +2193 pg_proc 0 less-equal-greater +2194 pg_proc 0 less-equal-greater +2195 pg_proc 0 less-equal-greater +2212 pg_proc 0 I/O +2213 pg_proc 0 I/O +2214 pg_proc 0 I/O +2215 pg_proc 0 I/O +2216 pg_proc 0 I/O +2217 pg_proc 0 I/O +2218 pg_proc 0 I/O +2219 pg_proc 0 I/O +2220 pg_proc 0 I/O +2221 pg_proc 0 I/O +1079 pg_proc 0 convert text to regclass +2246 pg_proc 0 (internal) +2247 pg_proc 0 (internal) +2248 pg_proc 0 (internal) +2250 pg_proc 0 user privilege on database by username, database name +2251 pg_proc 0 user privilege on database by username, database oid +2252 pg_proc 0 user privilege on database by user oid, database name +2253 pg_proc 0 user privilege on database by user oid, database oid +2254 pg_proc 0 current user privilege on database by database name +2255 pg_proc 0 current user privilege on database by database oid +2256 pg_proc 0 user privilege on function by username, function name +2257 pg_proc 0 user privilege on function by username, function oid +2258 pg_proc 0 user privilege on function by user oid, function name +2259 pg_proc 0 user privilege on function by user oid, function oid +2260 pg_proc 0 current user privilege on function by function name +2261 pg_proc 0 current user privilege on function by function oid +2262 pg_proc 0 user privilege on language by username, language name +2263 pg_proc 0 user privilege on language by username, language oid +2264 pg_proc 0 user privilege on language by user oid, language name +2265 pg_proc 0 user privilege on language by user oid, language oid +2266 pg_proc 0 current user privilege on language by language name +2267 pg_proc 0 current user privilege on language by language oid +2268 pg_proc 0 user privilege on schema by username, schema name +2269 pg_proc 0 user privilege on schema by username, schema oid +2270 pg_proc 0 user privilege on schema by user oid, schema name +2271 pg_proc 0 user privilege on schema by user oid, schema oid +2272 pg_proc 0 current user privilege on schema by schema name +2273 pg_proc 0 current user privilege on schema by schema oid +2390 pg_proc 0 user privilege on tablespace by username, tablespace name +2391 pg_proc 0 user privilege on tablespace by username, tablespace oid +2392 pg_proc 0 user privilege on tablespace by user oid, tablespace name +2393 pg_proc 0 user privilege on tablespace by user oid, tablespace oid +2394 pg_proc 0 current user privilege on tablespace by tablespace name +2395 pg_proc 0 current user privilege on tablespace by tablespace oid +3000 pg_proc 0 user privilege on foreign data wrapper by username, foreign data wrapper name +3001 pg_proc 0 user privilege on foreign data wrapper by username, foreign data wrapper oid +3002 pg_proc 0 user privilege on foreign data wrapper by user oid, foreign data wrapper name +3003 pg_proc 0 user privilege on foreign data wrapper by user oid, foreign data wrapper oid +3004 pg_proc 0 current user privilege on foreign data wrapper by foreign data wrapper name +3005 pg_proc 0 current user privilege on foreign data wrapper by foreign data wrapper oid +3006 pg_proc 0 user privilege on server by username, server name +3007 pg_proc 0 user privilege on server by username, server oid +3008 pg_proc 0 user privilege on server by user oid, server name +3009 pg_proc 0 user privilege on server by user oid, server oid +3010 pg_proc 0 current user privilege on server by server name +3011 pg_proc 0 current user privilege on server by server oid +3138 pg_proc 0 user privilege on type by username, type name +3139 pg_proc 0 user privilege on type by username, type oid +3140 pg_proc 0 user privilege on type by user oid, type name +3141 pg_proc 0 user privilege on type by user oid, type oid +3142 pg_proc 0 current user privilege on type by type name +3143 pg_proc 0 current user privilege on type by type oid +2705 pg_proc 0 user privilege on role by username, role name +2706 pg_proc 0 user privilege on role by username, role oid +2707 pg_proc 0 user privilege on role by user oid, role name +2708 pg_proc 0 user privilege on role by user oid, role oid +2709 pg_proc 0 current user privilege on role by role name +2710 pg_proc 0 current user privilege on role by role oid +1269 pg_proc 0 bytes required to store the value, perhaps with compression +2322 pg_proc 0 total disk space usage for the specified tablespace +2323 pg_proc 0 total disk space usage for the specified tablespace +2324 pg_proc 0 total disk space usage for the specified database +2168 pg_proc 0 total disk space usage for the specified database +2325 pg_proc 0 disk space usage for the main fork of the specified table or index +2332 pg_proc 0 disk space usage for the specified fork of a table or index +2286 pg_proc 0 total disk space usage for the specified table and associated indexes +2288 pg_proc 0 convert a long int to a human readable text using size units +3166 pg_proc 0 convert a numeric to a human readable text using size units +2997 pg_proc 0 disk space usage for the specified table, including TOAST, free space and visibility map +2998 pg_proc 0 disk space usage for all indexes attached to the specified table +2999 pg_proc 0 filenode identifier of relation +3034 pg_proc 0 file path of relation +2316 pg_proc 0 (internal) +2290 pg_proc 0 I/O +2291 pg_proc 0 I/O +2292 pg_proc 0 I/O +2293 pg_proc 0 I/O +2294 pg_proc 0 I/O +2295 pg_proc 0 I/O +2296 pg_proc 0 I/O +2297 pg_proc 0 I/O +2298 pg_proc 0 I/O +2299 pg_proc 0 I/O +2300 pg_proc 0 I/O +2301 pg_proc 0 I/O +2302 pg_proc 0 I/O +2303 pg_proc 0 I/O +2304 pg_proc 0 I/O +2305 pg_proc 0 I/O +2306 pg_proc 0 I/O +2307 pg_proc 0 I/O +2312 pg_proc 0 I/O +2313 pg_proc 0 I/O +2398 pg_proc 0 I/O +2399 pg_proc 0 I/O +2597 pg_proc 0 I/O +2598 pg_proc 0 I/O +2777 pg_proc 0 I/O +2778 pg_proc 0 I/O +3116 pg_proc 0 I/O +3117 pg_proc 0 I/O +2311 pg_proc 0 MD5 hash +2321 pg_proc 0 MD5 hash +2344 pg_proc 0 less-equal-greater +2357 pg_proc 0 less-equal-greater +2370 pg_proc 0 less-equal-greater +2383 pg_proc 0 less-equal-greater +2526 pg_proc 0 less-equal-greater +2533 pg_proc 0 less-equal-greater +2400 pg_proc 0 I/O +2401 pg_proc 0 I/O +2402 pg_proc 0 I/O +2403 pg_proc 0 I/O +2404 pg_proc 0 I/O +2405 pg_proc 0 I/O +2406 pg_proc 0 I/O +2407 pg_proc 0 I/O +2408 pg_proc 0 I/O +2409 pg_proc 0 I/O +2410 pg_proc 0 I/O +2411 pg_proc 0 I/O +2412 pg_proc 0 I/O +2413 pg_proc 0 I/O +2414 pg_proc 0 I/O +2415 pg_proc 0 I/O +2416 pg_proc 0 I/O +2417 pg_proc 0 I/O +2418 pg_proc 0 I/O +2419 pg_proc 0 I/O +2420 pg_proc 0 I/O +2421 pg_proc 0 I/O +2422 pg_proc 0 I/O +2423 pg_proc 0 I/O +2424 pg_proc 0 I/O +2425 pg_proc 0 I/O +2426 pg_proc 0 I/O +2427 pg_proc 0 I/O +2428 pg_proc 0 I/O +2429 pg_proc 0 I/O +2430 pg_proc 0 I/O +2431 pg_proc 0 I/O +2432 pg_proc 0 I/O +2433 pg_proc 0 I/O +2434 pg_proc 0 I/O +2435 pg_proc 0 I/O +2436 pg_proc 0 I/O +2437 pg_proc 0 I/O +2438 pg_proc 0 I/O +2439 pg_proc 0 I/O +2440 pg_proc 0 I/O +2441 pg_proc 0 I/O +2442 pg_proc 0 I/O +2443 pg_proc 0 I/O +2444 pg_proc 0 I/O +2445 pg_proc 0 I/O +2446 pg_proc 0 I/O +2447 pg_proc 0 I/O +2448 pg_proc 0 I/O +2449 pg_proc 0 I/O +2450 pg_proc 0 I/O +2451 pg_proc 0 I/O +2452 pg_proc 0 I/O +2453 pg_proc 0 I/O +2454 pg_proc 0 I/O +2455 pg_proc 0 I/O +2456 pg_proc 0 I/O +2457 pg_proc 0 I/O +2458 pg_proc 0 I/O +2459 pg_proc 0 I/O +2460 pg_proc 0 I/O +2461 pg_proc 0 I/O +2462 pg_proc 0 I/O +2463 pg_proc 0 I/O +2464 pg_proc 0 I/O +2465 pg_proc 0 I/O +2466 pg_proc 0 I/O +2467 pg_proc 0 I/O +2468 pg_proc 0 I/O +2469 pg_proc 0 I/O +2470 pg_proc 0 I/O +2471 pg_proc 0 I/O +2472 pg_proc 0 I/O +2473 pg_proc 0 I/O +2474 pg_proc 0 I/O +2475 pg_proc 0 I/O +2476 pg_proc 0 I/O +2477 pg_proc 0 I/O +2478 pg_proc 0 I/O +2479 pg_proc 0 I/O +2480 pg_proc 0 I/O +2481 pg_proc 0 I/O +2482 pg_proc 0 I/O +2483 pg_proc 0 I/O +2484 pg_proc 0 I/O +2485 pg_proc 0 I/O +2486 pg_proc 0 I/O +2487 pg_proc 0 I/O +2488 pg_proc 0 I/O +2489 pg_proc 0 I/O +2490 pg_proc 0 I/O +2491 pg_proc 0 I/O +2492 pg_proc 0 I/O +2493 pg_proc 0 I/O +2494 pg_proc 0 I/O +2495 pg_proc 0 I/O +2496 pg_proc 0 I/O +2497 pg_proc 0 I/O +2498 pg_proc 0 I/O +2499 pg_proc 0 I/O +2500 pg_proc 0 I/O +2501 pg_proc 0 I/O +2502 pg_proc 0 I/O +2503 pg_proc 0 I/O +3120 pg_proc 0 I/O +3121 pg_proc 0 I/O +2504 pg_proc 0 source text of a rule with pretty-print option +2505 pg_proc 0 select statement of a view with pretty-print option +2506 pg_proc 0 select statement of a view with pretty-print option +3159 pg_proc 0 select statement of a view with pretty-printing and specified line wrapping +2507 pg_proc 0 index description (full create statement or single expression) with pretty-print option +2508 pg_proc 0 constraint description with pretty-print option +2509 pg_proc 0 deparse an encoded expression with pretty-print option +2510 pg_proc 0 get the prepared statements for this session +2511 pg_proc 0 get the open cursors for this session +2599 pg_proc 0 get the available time zone abbreviations +2856 pg_proc 0 get the available time zone names +2730 pg_proc 0 trigger description with pretty-print option +3035 pg_proc 0 get the channels that the current backend listens to +3036 pg_proc 0 send a notification event +1066 pg_proc 0 non-persistent series generator +1067 pg_proc 0 non-persistent series generator +1068 pg_proc 0 non-persistent series generator +1069 pg_proc 0 non-persistent series generator +938 pg_proc 0 non-persistent series generator +939 pg_proc 0 non-persistent series generator +2515 pg_proc 0 aggregate transition function +2516 pg_proc 0 aggregate transition function +2517 pg_proc 0 boolean-and aggregate +2518 pg_proc 0 boolean-or aggregate +2519 pg_proc 0 boolean-and aggregate +2236 pg_proc 0 bitwise-and smallint aggregate +2237 pg_proc 0 bitwise-or smallint aggregate +2238 pg_proc 0 bitwise-and integer aggregate +2239 pg_proc 0 bitwise-or integer aggregate +2240 pg_proc 0 bitwise-and bigint aggregate +2241 pg_proc 0 bitwise-or bigint aggregate +2242 pg_proc 0 bitwise-and bit aggregate +2243 pg_proc 0 bitwise-or bit aggregate +2556 pg_proc 0 get OIDs of databases in a tablespace +2557 pg_proc 0 convert int4 to boolean +2558 pg_proc 0 convert boolean to int4 +2559 pg_proc 0 current value from last used sequence +2560 pg_proc 0 postmaster start time +2034 pg_proc 0 configuration load time +2578 pg_proc 0 GiST support +2579 pg_proc 0 GiST support +2580 pg_proc 0 GiST support +2581 pg_proc 0 GiST support +2582 pg_proc 0 GiST support +2583 pg_proc 0 GiST support +2584 pg_proc 0 GiST support +2585 pg_proc 0 GiST support +2586 pg_proc 0 GiST support +2591 pg_proc 0 GiST support +2592 pg_proc 0 GiST support +1030 pg_proc 0 GiST support +2179 pg_proc 0 GiST support +3064 pg_proc 0 GiST support +2731 pg_proc 0 gin(internal) +2732 pg_proc 0 gin(internal) +2733 pg_proc 0 gin(internal) +2734 pg_proc 0 gin(internal) +2735 pg_proc 0 gin(internal) +2736 pg_proc 0 gin(internal) +2737 pg_proc 0 gin(internal) +2738 pg_proc 0 gin(internal) +325 pg_proc 0 gin(internal) +2739 pg_proc 0 gin(internal) +2740 pg_proc 0 gin(internal) +2741 pg_proc 0 gin(internal) +2788 pg_proc 0 gin(internal) +2743 pg_proc 0 GIN array support +2774 pg_proc 0 GIN array support +2744 pg_proc 0 GIN array support +3076 pg_proc 0 GIN array support (obsolete) +2880 pg_proc 0 obtain exclusive advisory lock +3089 pg_proc 0 obtain exclusive advisory lock +2881 pg_proc 0 obtain shared advisory lock +3090 pg_proc 0 obtain shared advisory lock +2882 pg_proc 0 obtain exclusive advisory lock if available +3091 pg_proc 0 obtain exclusive advisory lock if available +2883 pg_proc 0 obtain shared advisory lock if available +3092 pg_proc 0 obtain shared advisory lock if available +2884 pg_proc 0 release exclusive advisory lock +2885 pg_proc 0 release shared advisory lock +2886 pg_proc 0 obtain exclusive advisory lock +3093 pg_proc 0 obtain exclusive advisory lock +2887 pg_proc 0 obtain shared advisory lock +3094 pg_proc 0 obtain shared advisory lock +2888 pg_proc 0 obtain exclusive advisory lock if available +3095 pg_proc 0 obtain exclusive advisory lock if available +2889 pg_proc 0 obtain shared advisory lock if available +3096 pg_proc 0 obtain shared advisory lock if available +2890 pg_proc 0 release exclusive advisory lock +2891 pg_proc 0 release shared advisory lock +2892 pg_proc 0 release all advisory locks +2893 pg_proc 0 I/O +2894 pg_proc 0 I/O +2895 pg_proc 0 generate XML comment +2896 pg_proc 0 perform a non-validating parse of a character string to produce an XML value +2897 pg_proc 0 validate an XML value +2898 pg_proc 0 I/O +2899 pg_proc 0 I/O +2900 pg_proc 0 aggregate transition function +2901 pg_proc 0 concatenate XML values +2922 pg_proc 0 serialize an XML value to a character string +2923 pg_proc 0 map table contents to XML +2924 pg_proc 0 map query result to XML +2925 pg_proc 0 map rows from cursor to XML +2926 pg_proc 0 map table structure to XML Schema +2927 pg_proc 0 map query result structure to XML Schema +2928 pg_proc 0 map cursor structure to XML Schema +2929 pg_proc 0 map table contents and structure to XML and XML Schema +2930 pg_proc 0 map query result and structure to XML and XML Schema +2933 pg_proc 0 map schema contents to XML +2934 pg_proc 0 map schema structure to XML Schema +2935 pg_proc 0 map schema contents and structure to XML and XML Schema +2936 pg_proc 0 map database contents to XML +2937 pg_proc 0 map database structure to XML Schema +2938 pg_proc 0 map database contents and structure to XML and XML Schema +2931 pg_proc 0 evaluate XPath expression, with namespaces support +2932 pg_proc 0 evaluate XPath expression +2614 pg_proc 0 test XML value against XPath expression +3049 pg_proc 0 test XML value against XPath expression, with namespace support +3050 pg_proc 0 test XML value against XPath expression +3051 pg_proc 0 determine if a string is well formed XML +3052 pg_proc 0 determine if a string is well formed XML document +3053 pg_proc 0 determine if a string is well formed XML content +321 pg_proc 0 I/O +322 pg_proc 0 I/O +323 pg_proc 0 I/O +324 pg_proc 0 I/O +3153 pg_proc 0 map array to json +3154 pg_proc 0 map array to json with optional pretty printing +3155 pg_proc 0 map row to json +3156 pg_proc 0 map row to json with optional pretty printing +2952 pg_proc 0 I/O +2953 pg_proc 0 I/O +2960 pg_proc 0 less-equal-greater +2961 pg_proc 0 I/O +2962 pg_proc 0 I/O +2963 pg_proc 0 hash +3504 pg_proc 0 I/O +3505 pg_proc 0 I/O +3506 pg_proc 0 I/O +3507 pg_proc 0 I/O +3514 pg_proc 0 less-equal-greater +3515 pg_proc 0 hash +3524 pg_proc 0 smaller of two +3525 pg_proc 0 larger of two +3526 pg_proc 0 maximum value of all enum input values +3527 pg_proc 0 minimum value of all enum input values +3528 pg_proc 0 first value of the input enum type +3529 pg_proc 0 last value of the input enum type +3530 pg_proc 0 range between the two given enum values, as an ordered array +3531 pg_proc 0 range of the given enum type, as an ordered array +3532 pg_proc 0 I/O +3533 pg_proc 0 I/O +3610 pg_proc 0 I/O +3639 pg_proc 0 I/O +3611 pg_proc 0 I/O +3638 pg_proc 0 I/O +3612 pg_proc 0 I/O +3641 pg_proc 0 I/O +3613 pg_proc 0 I/O +3640 pg_proc 0 I/O +3646 pg_proc 0 I/O +3647 pg_proc 0 I/O +3622 pg_proc 0 less-equal-greater +3711 pg_proc 0 number of lexemes +3623 pg_proc 0 strip position information +3624 pg_proc 0 set weight of lexeme's entries +3648 pg_proc 0 GiST tsvector support +3649 pg_proc 0 GiST tsvector support +3650 pg_proc 0 GiST tsvector support +3651 pg_proc 0 GiST tsvector support +3652 pg_proc 0 GiST tsvector support +3653 pg_proc 0 GiST tsvector support +3654 pg_proc 0 GiST tsvector support +3656 pg_proc 0 GIN tsvector support +3657 pg_proc 0 GIN tsvector support +3658 pg_proc 0 GIN tsvector support +3724 pg_proc 0 GIN tsvector support +2700 pg_proc 0 GIN tsvector support +3077 pg_proc 0 GIN tsvector support (obsolete) +3087 pg_proc 0 GIN tsvector support (obsolete) +3088 pg_proc 0 GIN tsvector support (obsolete) +3668 pg_proc 0 less-equal-greater +3672 pg_proc 0 number of nodes +3673 pg_proc 0 show real useful query for GiST index +3684 pg_proc 0 rewrite tsquery +3685 pg_proc 0 rewrite tsquery +3695 pg_proc 0 GiST tsquery support +3696 pg_proc 0 GiST tsquery support +3697 pg_proc 0 GiST tsquery support +3698 pg_proc 0 GiST tsquery support +3699 pg_proc 0 GiST tsquery support +3700 pg_proc 0 GiST tsquery support +3701 pg_proc 0 GiST tsquery support +3686 pg_proc 0 restriction selectivity of tsvector @@ tsquery +3687 pg_proc 0 join selectivity of tsvector @@ tsquery +3688 pg_proc 0 tsvector typanalyze +3689 pg_proc 0 statistics of tsvector column +3690 pg_proc 0 statistics of tsvector column +3703 pg_proc 0 relevance +3704 pg_proc 0 relevance +3705 pg_proc 0 relevance +3706 pg_proc 0 relevance +3707 pg_proc 0 relevance +3708 pg_proc 0 relevance +3709 pg_proc 0 relevance +3710 pg_proc 0 relevance +3713 pg_proc 0 get parser's token types +3714 pg_proc 0 get parser's token types +3715 pg_proc 0 parse text to tokens +3716 pg_proc 0 parse text to tokens +3717 pg_proc 0 (internal) +3718 pg_proc 0 (internal) +3719 pg_proc 0 (internal) +3720 pg_proc 0 (internal) +3721 pg_proc 0 (internal) +3723 pg_proc 0 normalize one word by dictionary +3725 pg_proc 0 (internal) +3726 pg_proc 0 (internal) +3728 pg_proc 0 (internal) +3729 pg_proc 0 (internal) +3731 pg_proc 0 (internal) +3732 pg_proc 0 (internal) +3740 pg_proc 0 (internal) +3741 pg_proc 0 (internal) +3743 pg_proc 0 generate headline +3744 pg_proc 0 generate headline +3754 pg_proc 0 generate headline +3755 pg_proc 0 generate headline +3745 pg_proc 0 transform to tsvector +3746 pg_proc 0 make tsquery +3747 pg_proc 0 transform to tsquery +3749 pg_proc 0 transform to tsvector +3750 pg_proc 0 make tsquery +3751 pg_proc 0 transform to tsquery +3752 pg_proc 0 trigger for automatic update of tsvector column +3753 pg_proc 0 trigger for automatic update of tsvector column +3759 pg_proc 0 get current tsearch configuration +3736 pg_proc 0 I/O +3737 pg_proc 0 I/O +3738 pg_proc 0 I/O +3739 pg_proc 0 I/O +3771 pg_proc 0 I/O +3772 pg_proc 0 I/O +3773 pg_proc 0 I/O +3774 pg_proc 0 I/O +2939 pg_proc 0 I/O +2940 pg_proc 0 I/O +2941 pg_proc 0 I/O +2942 pg_proc 0 I/O +2943 pg_proc 0 get current transaction ID +2944 pg_proc 0 get current snapshot +2945 pg_proc 0 get xmin of snapshot +2946 pg_proc 0 get xmax of snapshot +2947 pg_proc 0 get set of in-progress txids in snapshot +2948 pg_proc 0 is txid visible in snapshot? +2987 pg_proc 0 less-equal-greater +3082 pg_proc 0 list available extensions +3083 pg_proc 0 list available extension versions +3084 pg_proc 0 list an extension's version update paths +3086 pg_proc 0 flag an extension's table contents to be emitted by pg_dump +3100 pg_proc 0 row number within partition +3101 pg_proc 0 integer rank with gaps +3102 pg_proc 0 integer rank without gaps +3103 pg_proc 0 fractional rank within partition +3104 pg_proc 0 fractional row number within partition +3105 pg_proc 0 split rows into N groups +3106 pg_proc 0 fetch the preceding row value +3107 pg_proc 0 fetch the Nth preceding row value +3108 pg_proc 0 fetch the Nth preceding row value with default +3109 pg_proc 0 fetch the following row value +3110 pg_proc 0 fetch the Nth following row value +3111 pg_proc 0 fetch the Nth following row value with default +3112 pg_proc 0 fetch the first row value +3113 pg_proc 0 fetch the last row value +3114 pg_proc 0 fetch the Nth row value +3832 pg_proc 0 I/O +3833 pg_proc 0 I/O +3834 pg_proc 0 I/O +3835 pg_proc 0 I/O +3836 pg_proc 0 I/O +3837 pg_proc 0 I/O +3848 pg_proc 0 lower bound of range +3849 pg_proc 0 upper bound of range +3850 pg_proc 0 is the range empty? +3851 pg_proc 0 is the range's lower bound inclusive? +3852 pg_proc 0 is the range's upper bound inclusive? +3853 pg_proc 0 is the range's lower bound infinite? +3854 pg_proc 0 is the range's upper bound infinite? +3855 pg_proc 0 implementation of = operator +3856 pg_proc 0 implementation of <> operator +3857 pg_proc 0 implementation of && operator +3858 pg_proc 0 implementation of @> operator +3859 pg_proc 0 implementation of @> operator +3860 pg_proc 0 implementation of <@ operator +3861 pg_proc 0 implementation of <@ operator +3862 pg_proc 0 implementation of -|- operator +3863 pg_proc 0 implementation of << operator +3864 pg_proc 0 implementation of >> operator +3865 pg_proc 0 implementation of &< operator +3866 pg_proc 0 implementation of &> operator +3867 pg_proc 0 implementation of + operator +3868 pg_proc 0 implementation of * operator +3869 pg_proc 0 implementation of - operator +3870 pg_proc 0 less-equal-greater +3875 pg_proc 0 GiST support +3876 pg_proc 0 GiST support +3877 pg_proc 0 GiST support +3878 pg_proc 0 GiST support +3879 pg_proc 0 GiST support +3880 pg_proc 0 GiST support +3881 pg_proc 0 GiST support +3902 pg_proc 0 hash a range +3916 pg_proc 0 range typanalyze +3914 pg_proc 0 convert an int4 range to canonical form +3928 pg_proc 0 convert an int8 range to canonical form +3915 pg_proc 0 convert a date range to canonical form +3922 pg_proc 0 float8 difference of two int4 values +3923 pg_proc 0 float8 difference of two int8 values +3924 pg_proc 0 float8 difference of two numeric values +3925 pg_proc 0 float8 difference of two date values +3929 pg_proc 0 float8 difference of two timestamp values +3930 pg_proc 0 float8 difference of two timestamp with time zone values +3840 pg_proc 0 int4range constructor +3841 pg_proc 0 int4range constructor +3844 pg_proc 0 numrange constructor +3845 pg_proc 0 numrange constructor +3933 pg_proc 0 tsrange constructor +3934 pg_proc 0 tsrange constructor +3937 pg_proc 0 tstzrange constructor +3938 pg_proc 0 tstzrange constructor +3941 pg_proc 0 daterange constructor +3942 pg_proc 0 daterange constructor +3945 pg_proc 0 int8range constructor +3946 pg_proc 0 int8range constructor +4001 pg_proc 0 spgist(internal) +4002 pg_proc 0 spgist(internal) +4003 pg_proc 0 spgist(internal) +4004 pg_proc 0 spgist(internal) +4005 pg_proc 0 spgist(internal) +4006 pg_proc 0 spgist(internal) +4007 pg_proc 0 spgist(internal) +4008 pg_proc 0 spgist(internal) +4009 pg_proc 0 spgist(internal) +4010 pg_proc 0 spgist(internal) +4011 pg_proc 0 spgist(internal) +4012 pg_proc 0 spgist(internal) +4032 pg_proc 0 spgist(internal) +4013 pg_proc 0 spgist(internal) +4014 pg_proc 0 spgist(internal) +4018 pg_proc 0 SP-GiST support for quad tree over point +4019 pg_proc 0 SP-GiST support for quad tree over point +4020 pg_proc 0 SP-GiST support for quad tree over point +4021 pg_proc 0 SP-GiST support for quad tree over point +4022 pg_proc 0 SP-GiST support for quad tree and k-d tree over point +4023 pg_proc 0 SP-GiST support for k-d tree over point +4024 pg_proc 0 SP-GiST support for k-d tree over point +4025 pg_proc 0 SP-GiST support for k-d tree over point +4026 pg_proc 0 SP-GiST support for k-d tree over point +4027 pg_proc 0 SP-GiST support for suffix tree over text +4028 pg_proc 0 SP-GiST support for suffix tree over text +4029 pg_proc 0 SP-GiST support for suffix tree over text +4030 pg_proc 0 SP-GiST support for suffix tree over text +4031 pg_proc 0 SP-GiST support for suffix tree over text +16 pg_type 0 boolean, 'true'/'false' +17 pg_type 0 variable-length string, binary values escaped +18 pg_type 0 single character +19 pg_type 0 63-byte type for storing system identifiers +20 pg_type 0 ~18 digit integer, 8-byte storage +21 pg_type 0 -32 thousand to 32 thousand, 2-byte storage +22 pg_type 0 array of int2, used in system tables +23 pg_type 0 -2 billion to 2 billion integer, 4-byte storage +24 pg_type 0 registered procedure +25 pg_type 0 variable-length string, no limit specified +26 pg_type 0 object identifier(oid), maximum 4 billion +27 pg_type 0 (block, offset), physical location of tuple +28 pg_type 0 transaction id +29 pg_type 0 command identifier type, sequence in transaction id +30 pg_type 0 array of oids, used in system tables +142 pg_type 0 XML content +194 pg_type 0 string representing an internal node tree +210 pg_type 0 storage manager +600 pg_type 0 geometric point '(x, y)' +601 pg_type 0 geometric line segment '(pt1,pt2)' +602 pg_type 0 geometric path '(pt1,...)' +603 pg_type 0 geometric box '(lower left,upper right)' +604 pg_type 0 geometric polygon '(pt1,...)' +628 pg_type 0 geometric line (not implemented) +700 pg_type 0 single-precision floating point number, 4-byte storage +701 pg_type 0 double-precision floating point number, 8-byte storage +702 pg_type 0 absolute, limited-range date and time (Unix system time) +703 pg_type 0 relative, limited-range time interval (Unix delta time) +704 pg_type 0 (abstime,abstime), time interval +718 pg_type 0 geometric circle '(center,radius)' +790 pg_type 0 monetary amounts, $d,ddd.cc +829 pg_type 0 XX:XX:XX:XX:XX:XX, MAC address +869 pg_type 0 IP address/netmask, host address, netmask optional +650 pg_type 0 network IP address/netmask, network address +1033 pg_type 0 access control list +1042 pg_type 0 char(length), blank-padded string, fixed storage length +1043 pg_type 0 varchar(length), non-blank-padded string, variable storage length +1082 pg_type 0 date +1083 pg_type 0 time of day +1114 pg_type 0 date and time +1184 pg_type 0 date and time with time zone +1186 pg_type 0 @ , time interval +1266 pg_type 0 time of day with time zone +1560 pg_type 0 fixed-length bit string +1562 pg_type 0 variable-length bit string +1700 pg_type 0 numeric(precision, decimal), arbitrary precision number +1790 pg_type 0 reference to cursor (portal name) +2202 pg_type 0 registered procedure (with args) +2203 pg_type 0 registered operator +2204 pg_type 0 registered operator (with args) +2205 pg_type 0 registered class +2206 pg_type 0 registered type +2950 pg_type 0 UUID datatype +3614 pg_type 0 text representation for text search +3642 pg_type 0 GiST index internal text representation for text search +3615 pg_type 0 query representation for text search +3734 pg_type 0 registered text search configuration +3769 pg_type 0 registered text search dictionary +2970 pg_type 0 txid snapshot +3904 pg_type 0 range of integers +3906 pg_type 0 range of numerics +3908 pg_type 0 range of timestamps without time zone +3910 pg_type 0 range of timestamps with time zone +3912 pg_type 0 range of dates +3926 pg_type 0 range of bigints +15 pg_operator 0 equal +36 pg_operator 0 not equal +37 pg_operator 0 less than +76 pg_operator 0 greater than +80 pg_operator 0 less than or equal +82 pg_operator 0 greater than or equal +58 pg_operator 0 less than +59 pg_operator 0 greater than +85 pg_operator 0 not equal +91 pg_operator 0 equal +1694 pg_operator 0 less than or equal +1695 pg_operator 0 greater than or equal +92 pg_operator 0 equal +93 pg_operator 0 equal +94 pg_operator 0 equal +95 pg_operator 0 less than +96 pg_operator 0 equal +97 pg_operator 0 less than +98 pg_operator 0 equal +349 pg_operator 0 append element onto end of array +374 pg_operator 0 prepend element onto front of array +375 pg_operator 0 concatenate +352 pg_operator 0 equal +353 pg_operator 0 equal +388 pg_operator 0 factorial +389 pg_operator 0 deprecated, use ! instead +385 pg_operator 0 equal +386 pg_operator 0 equal +387 pg_operator 0 equal +402 pg_operator 0 not equal +2799 pg_operator 0 less than +2800 pg_operator 0 greater than +2801 pg_operator 0 less than or equal +2802 pg_operator 0 greater than or equal +410 pg_operator 0 equal +411 pg_operator 0 not equal +412 pg_operator 0 less than +413 pg_operator 0 greater than +414 pg_operator 0 less than or equal +415 pg_operator 0 greater than or equal +416 pg_operator 0 equal +417 pg_operator 0 not equal +418 pg_operator 0 less than +419 pg_operator 0 greater than +420 pg_operator 0 less than or equal +430 pg_operator 0 greater than or equal +439 pg_operator 0 modulus +473 pg_operator 0 absolute value +484 pg_operator 0 negate +485 pg_operator 0 is left of +486 pg_operator 0 overlaps or is left of +487 pg_operator 0 overlaps or is right of +488 pg_operator 0 is right of +489 pg_operator 0 is contained by +490 pg_operator 0 contains +491 pg_operator 0 same as +492 pg_operator 0 overlaps +493 pg_operator 0 is left of +494 pg_operator 0 overlaps or is left of +495 pg_operator 0 overlaps or is right of +496 pg_operator 0 is right of +497 pg_operator 0 is contained by +498 pg_operator 0 contains +499 pg_operator 0 same as +500 pg_operator 0 overlaps +501 pg_operator 0 greater than or equal by area +502 pg_operator 0 greater than by area +503 pg_operator 0 equal by area +504 pg_operator 0 less than by area +505 pg_operator 0 less than or equal by area +506 pg_operator 0 is above +507 pg_operator 0 is left of +508 pg_operator 0 is right of +509 pg_operator 0 is below +510 pg_operator 0 same as +511 pg_operator 0 point inside box +433 pg_operator 0 contains +512 pg_operator 0 point within closed path, or point on open path +513 pg_operator 0 center of +514 pg_operator 0 multiply +517 pg_operator 0 distance between +518 pg_operator 0 not equal +519 pg_operator 0 not equal +520 pg_operator 0 greater than +521 pg_operator 0 greater than +522 pg_operator 0 less than or equal +523 pg_operator 0 less than or equal +524 pg_operator 0 greater than or equal +525 pg_operator 0 greater than or equal +526 pg_operator 0 multiply +527 pg_operator 0 divide +528 pg_operator 0 divide +529 pg_operator 0 modulus +530 pg_operator 0 modulus +531 pg_operator 0 not equal +532 pg_operator 0 equal +533 pg_operator 0 equal +534 pg_operator 0 less than +535 pg_operator 0 less than +536 pg_operator 0 greater than +537 pg_operator 0 greater than +538 pg_operator 0 not equal +539 pg_operator 0 not equal +540 pg_operator 0 less than or equal +541 pg_operator 0 less than or equal +542 pg_operator 0 greater than or equal +543 pg_operator 0 greater than or equal +544 pg_operator 0 multiply +545 pg_operator 0 multiply +546 pg_operator 0 divide +547 pg_operator 0 divide +550 pg_operator 0 add +551 pg_operator 0 add +552 pg_operator 0 add +553 pg_operator 0 add +554 pg_operator 0 subtract +555 pg_operator 0 subtract +556 pg_operator 0 subtract +557 pg_operator 0 subtract +558 pg_operator 0 negate +559 pg_operator 0 negate +560 pg_operator 0 equal +561 pg_operator 0 not equal +562 pg_operator 0 less than +563 pg_operator 0 greater than +564 pg_operator 0 less than or equal +565 pg_operator 0 greater than or equal +566 pg_operator 0 equal +567 pg_operator 0 not equal +568 pg_operator 0 less than +569 pg_operator 0 greater than +570 pg_operator 0 less than or equal +571 pg_operator 0 greater than or equal +572 pg_operator 0 same as +573 pg_operator 0 contains +574 pg_operator 0 overlaps +575 pg_operator 0 equal by length +576 pg_operator 0 not equal by length +577 pg_operator 0 less than by length +578 pg_operator 0 greater than by length +579 pg_operator 0 less than or equal by length +580 pg_operator 0 greater than or equal by length +581 pg_operator 0 add +582 pg_operator 0 subtract +583 pg_operator 0 is contained by +584 pg_operator 0 negate +585 pg_operator 0 negate +586 pg_operator 0 add +587 pg_operator 0 subtract +588 pg_operator 0 divide +589 pg_operator 0 multiply +590 pg_operator 0 absolute value +591 pg_operator 0 add +592 pg_operator 0 subtract +593 pg_operator 0 divide +594 pg_operator 0 multiply +595 pg_operator 0 absolute value +596 pg_operator 0 square root +597 pg_operator 0 cube root +1284 pg_operator 0 start of interval +606 pg_operator 0 convert to tinterval +607 pg_operator 0 equal +608 pg_operator 0 not equal +609 pg_operator 0 less than +610 pg_operator 0 greater than +611 pg_operator 0 less than or equal +612 pg_operator 0 greater than or equal +644 pg_operator 0 not equal +645 pg_operator 0 less than +646 pg_operator 0 greater than +647 pg_operator 0 less than or equal +648 pg_operator 0 greater than or equal +649 pg_operator 0 equal +613 pg_operator 0 distance between +614 pg_operator 0 distance between +615 pg_operator 0 distance between +616 pg_operator 0 distance between +617 pg_operator 0 distance between +618 pg_operator 0 distance between +620 pg_operator 0 equal +621 pg_operator 0 not equal +622 pg_operator 0 less than +623 pg_operator 0 greater than +624 pg_operator 0 less than or equal +625 pg_operator 0 greater than or equal +630 pg_operator 0 not equal +631 pg_operator 0 less than +632 pg_operator 0 less than or equal +633 pg_operator 0 greater than +634 pg_operator 0 greater than or equal +639 pg_operator 0 matches regular expression, case-sensitive +640 pg_operator 0 does not match regular expression, case-sensitive +641 pg_operator 0 matches regular expression, case-sensitive +642 pg_operator 0 does not match regular expression, case-sensitive +643 pg_operator 0 not equal +654 pg_operator 0 concatenate +660 pg_operator 0 less than +661 pg_operator 0 less than or equal +662 pg_operator 0 greater than +663 pg_operator 0 greater than or equal +664 pg_operator 0 less than +665 pg_operator 0 less than or equal +666 pg_operator 0 greater than +667 pg_operator 0 greater than or equal +670 pg_operator 0 equal +671 pg_operator 0 not equal +672 pg_operator 0 less than +673 pg_operator 0 less than or equal +674 pg_operator 0 greater than +675 pg_operator 0 greater than or equal +682 pg_operator 0 absolute value +684 pg_operator 0 add +685 pg_operator 0 subtract +686 pg_operator 0 multiply +687 pg_operator 0 divide +688 pg_operator 0 add +689 pg_operator 0 subtract +690 pg_operator 0 multiply +691 pg_operator 0 divide +692 pg_operator 0 add +693 pg_operator 0 subtract +694 pg_operator 0 multiply +695 pg_operator 0 divide +818 pg_operator 0 add +819 pg_operator 0 subtract +820 pg_operator 0 multiply +821 pg_operator 0 divide +822 pg_operator 0 add +823 pg_operator 0 subtract +824 pg_operator 0 multiply +825 pg_operator 0 divide +706 pg_operator 0 distance between +707 pg_operator 0 distance between +708 pg_operator 0 distance between +709 pg_operator 0 distance between +712 pg_operator 0 distance between +713 pg_operator 0 not equal +731 pg_operator 0 add points (translate) +732 pg_operator 0 subtract points (translate) +733 pg_operator 0 multiply points (scale/rotate) +734 pg_operator 0 divide points (scale/rotate) +735 pg_operator 0 concatenate +736 pg_operator 0 add (translate path) +737 pg_operator 0 subtract (translate path) +738 pg_operator 0 multiply (rotate/scale path) +739 pg_operator 0 divide (rotate/scale path) +755 pg_operator 0 contains +756 pg_operator 0 is contained by +757 pg_operator 0 contains +758 pg_operator 0 is contained by +759 pg_operator 0 contains +773 pg_operator 0 absolute value +792 pg_operator 0 equal +793 pg_operator 0 less than +794 pg_operator 0 greater than +795 pg_operator 0 less than or equal +796 pg_operator 0 greater than or equal +797 pg_operator 0 number of points +798 pg_operator 0 intersect +799 pg_operator 0 sum of path segment lengths +800 pg_operator 0 is above (allows touching) +801 pg_operator 0 is below (allows touching) +802 pg_operator 0 deprecated, use && instead +803 pg_operator 0 box intersection +804 pg_operator 0 add point to box (translate) +805 pg_operator 0 subtract point from box (translate) +806 pg_operator 0 multiply box by point (scale) +807 pg_operator 0 divide box by point (scale) +808 pg_operator 0 horizontally aligned +809 pg_operator 0 vertically aligned +811 pg_operator 0 equal +812 pg_operator 0 not equal +813 pg_operator 0 less than +814 pg_operator 0 greater than +815 pg_operator 0 less than or equal +816 pg_operator 0 greater than or equal +843 pg_operator 0 multiply +844 pg_operator 0 divide +845 pg_operator 0 multiply +900 pg_operator 0 equal +901 pg_operator 0 not equal +902 pg_operator 0 less than +903 pg_operator 0 greater than +904 pg_operator 0 less than or equal +905 pg_operator 0 greater than or equal +906 pg_operator 0 add +907 pg_operator 0 subtract +908 pg_operator 0 multiply +909 pg_operator 0 divide +912 pg_operator 0 multiply +913 pg_operator 0 divide +914 pg_operator 0 multiply +915 pg_operator 0 divide +916 pg_operator 0 multiply +917 pg_operator 0 multiply +918 pg_operator 0 multiply +3825 pg_operator 0 divide +965 pg_operator 0 exponentiation +966 pg_operator 0 add/update ACL item +967 pg_operator 0 remove ACL item +968 pg_operator 0 contains +974 pg_operator 0 equal +969 pg_operator 0 center of +970 pg_operator 0 center of +971 pg_operator 0 center of +1054 pg_operator 0 equal +1055 pg_operator 0 matches regular expression, case-sensitive +1056 pg_operator 0 does not match regular expression, case-sensitive +1057 pg_operator 0 not equal +1058 pg_operator 0 less than +1059 pg_operator 0 less than or equal +1060 pg_operator 0 greater than +1061 pg_operator 0 greater than or equal +1070 pg_operator 0 equal +1071 pg_operator 0 not equal +1072 pg_operator 0 less than +1073 pg_operator 0 greater than +1074 pg_operator 0 less than or equal +1075 pg_operator 0 greater than or equal +1076 pg_operator 0 add +1077 pg_operator 0 subtract +1093 pg_operator 0 equal +1094 pg_operator 0 not equal +1095 pg_operator 0 less than +1096 pg_operator 0 less than or equal +1097 pg_operator 0 greater than +1098 pg_operator 0 greater than or equal +1099 pg_operator 0 subtract +1100 pg_operator 0 add +1101 pg_operator 0 subtract +1108 pg_operator 0 equal +1109 pg_operator 0 not equal +1110 pg_operator 0 less than +1111 pg_operator 0 less than or equal +1112 pg_operator 0 greater than +1113 pg_operator 0 greater than or equal +1550 pg_operator 0 equal +1551 pg_operator 0 not equal +1552 pg_operator 0 less than +1553 pg_operator 0 less than or equal +1554 pg_operator 0 greater than +1555 pg_operator 0 greater than or equal +1116 pg_operator 0 add +1117 pg_operator 0 subtract +1118 pg_operator 0 divide +1119 pg_operator 0 multiply +1120 pg_operator 0 equal +1121 pg_operator 0 not equal +1122 pg_operator 0 less than +1123 pg_operator 0 greater than +1124 pg_operator 0 less than or equal +1125 pg_operator 0 greater than or equal +1126 pg_operator 0 add +1127 pg_operator 0 subtract +1128 pg_operator 0 divide +1129 pg_operator 0 multiply +1130 pg_operator 0 equal +1131 pg_operator 0 not equal +1132 pg_operator 0 less than +1133 pg_operator 0 greater than +1134 pg_operator 0 less than or equal +1135 pg_operator 0 greater than or equal +1207 pg_operator 0 matches LIKE expression +1208 pg_operator 0 does not match LIKE expression +1209 pg_operator 0 matches LIKE expression +1210 pg_operator 0 does not match LIKE expression +1211 pg_operator 0 matches LIKE expression +1212 pg_operator 0 does not match LIKE expression +1226 pg_operator 0 matches regular expression, case-insensitive +1227 pg_operator 0 does not match regular expression, case-insensitive +1228 pg_operator 0 matches regular expression, case-insensitive +1229 pg_operator 0 does not match regular expression, case-insensitive +1234 pg_operator 0 matches regular expression, case-insensitive +1235 pg_operator 0 does not match regular expression, case-insensitive +1320 pg_operator 0 equal +1321 pg_operator 0 not equal +1322 pg_operator 0 less than +1323 pg_operator 0 less than or equal +1324 pg_operator 0 greater than +1325 pg_operator 0 greater than or equal +1327 pg_operator 0 add +1328 pg_operator 0 subtract +1329 pg_operator 0 subtract +1330 pg_operator 0 equal +1331 pg_operator 0 not equal +1332 pg_operator 0 less than +1333 pg_operator 0 less than or equal +1334 pg_operator 0 greater than +1335 pg_operator 0 greater than or equal +1336 pg_operator 0 negate +1337 pg_operator 0 add +1338 pg_operator 0 subtract +1360 pg_operator 0 convert date and time to timestamp +1361 pg_operator 0 convert date and time with time zone to timestamp with time zone +1363 pg_operator 0 convert time and date to timestamp +1366 pg_operator 0 convert time with time zone and date to timestamp with time zone +1399 pg_operator 0 subtract +1420 pg_operator 0 center of +1500 pg_operator 0 equal by area +1501 pg_operator 0 not equal by area +1502 pg_operator 0 less than by area +1503 pg_operator 0 greater than by area +1504 pg_operator 0 less than or equal by area +1505 pg_operator 0 greater than or equal by area +1506 pg_operator 0 is left of +1507 pg_operator 0 overlaps or is left of +1508 pg_operator 0 overlaps or is right of +1509 pg_operator 0 is right of +1510 pg_operator 0 is contained by +1511 pg_operator 0 contains +1512 pg_operator 0 same as +1513 pg_operator 0 overlaps +1514 pg_operator 0 is above +1515 pg_operator 0 is below +1516 pg_operator 0 add +1517 pg_operator 0 subtract +1518 pg_operator 0 multiply +1519 pg_operator 0 divide +1520 pg_operator 0 distance between +1521 pg_operator 0 number of points +1522 pg_operator 0 distance between +1523 pg_operator 0 distance between +1524 pg_operator 0 distance between +1525 pg_operator 0 intersect +1526 pg_operator 0 parallel +1527 pg_operator 0 perpendicular +1528 pg_operator 0 horizontal +1529 pg_operator 0 vertical +1535 pg_operator 0 equal +1536 pg_operator 0 intersection point +1537 pg_operator 0 intersect +1538 pg_operator 0 intersect +1539 pg_operator 0 intersect +1546 pg_operator 0 point on line +1547 pg_operator 0 is contained by +1548 pg_operator 0 lseg on line +1549 pg_operator 0 is contained by +1557 pg_operator 0 closest point to A on B +1558 pg_operator 0 closest point to A on B +1559 pg_operator 0 closest point to A on B +1566 pg_operator 0 closest point to A on B +1567 pg_operator 0 closest point to A on B +1568 pg_operator 0 closest point to A on B +1577 pg_operator 0 closest point to A on B +1578 pg_operator 0 closest point to A on B +1583 pg_operator 0 multiply +1584 pg_operator 0 multiply +1585 pg_operator 0 divide +1586 pg_operator 0 not equal +1587 pg_operator 0 less than by length +1588 pg_operator 0 less than or equal by length +1589 pg_operator 0 greater than by length +1590 pg_operator 0 greater than or equal by length +1591 pg_operator 0 distance between endpoints +1611 pg_operator 0 intersect +1612 pg_operator 0 parallel +1613 pg_operator 0 perpendicular +1614 pg_operator 0 horizontal +1615 pg_operator 0 vertical +1616 pg_operator 0 equal +1617 pg_operator 0 intersection point +1220 pg_operator 0 equal +1221 pg_operator 0 not equal +1222 pg_operator 0 less than +1223 pg_operator 0 less than or equal +1224 pg_operator 0 greater than +1225 pg_operator 0 greater than or equal +3147 pg_operator 0 bitwise not +3148 pg_operator 0 bitwise and +3149 pg_operator 0 bitwise or +1201 pg_operator 0 equal +1202 pg_operator 0 not equal +1203 pg_operator 0 less than +1204 pg_operator 0 less than or equal +1205 pg_operator 0 greater than +1206 pg_operator 0 greater than or equal +931 pg_operator 0 is subnet +932 pg_operator 0 is subnet or equal +933 pg_operator 0 is supernet +934 pg_operator 0 is supernet or equal +2634 pg_operator 0 bitwise not +2635 pg_operator 0 bitwise and +2636 pg_operator 0 bitwise or +2637 pg_operator 0 add +2638 pg_operator 0 add +2639 pg_operator 0 subtract +2640 pg_operator 0 subtract +1625 pg_operator 0 matches LIKE expression, case-insensitive +1626 pg_operator 0 does not match LIKE expression, case-insensitive +1627 pg_operator 0 matches LIKE expression, case-insensitive +1628 pg_operator 0 does not match LIKE expression, case-insensitive +1629 pg_operator 0 matches LIKE expression, case-insensitive +1630 pg_operator 0 does not match LIKE expression, case-insensitive +1751 pg_operator 0 negate +1752 pg_operator 0 equal +1753 pg_operator 0 not equal +1754 pg_operator 0 less than +1755 pg_operator 0 less than or equal +1756 pg_operator 0 greater than +1757 pg_operator 0 greater than or equal +1758 pg_operator 0 add +1759 pg_operator 0 subtract +1760 pg_operator 0 multiply +1761 pg_operator 0 divide +1762 pg_operator 0 modulus +1038 pg_operator 0 exponentiation +1763 pg_operator 0 absolute value +1784 pg_operator 0 equal +1785 pg_operator 0 not equal +1786 pg_operator 0 less than +1787 pg_operator 0 greater than +1788 pg_operator 0 less than or equal +1789 pg_operator 0 greater than or equal +1791 pg_operator 0 bitwise and +1792 pg_operator 0 bitwise or +1793 pg_operator 0 bitwise exclusive or +1794 pg_operator 0 bitwise not +1795 pg_operator 0 bitwise shift left +1796 pg_operator 0 bitwise shift right +1797 pg_operator 0 concatenate +1800 pg_operator 0 add +1801 pg_operator 0 subtract +1802 pg_operator 0 add +1803 pg_operator 0 subtract +1804 pg_operator 0 equal +1805 pg_operator 0 not equal +1806 pg_operator 0 less than +1807 pg_operator 0 greater than +1808 pg_operator 0 less than or equal +1809 pg_operator 0 greater than or equal +1849 pg_operator 0 add +1862 pg_operator 0 equal +1863 pg_operator 0 not equal +1864 pg_operator 0 less than +1865 pg_operator 0 greater than +1866 pg_operator 0 less than or equal +1867 pg_operator 0 greater than or equal +1868 pg_operator 0 equal +1869 pg_operator 0 not equal +1870 pg_operator 0 less than +1871 pg_operator 0 greater than +1872 pg_operator 0 less than or equal +1873 pg_operator 0 greater than or equal +1874 pg_operator 0 bitwise and +1875 pg_operator 0 bitwise or +1876 pg_operator 0 bitwise exclusive or +1877 pg_operator 0 bitwise not +1878 pg_operator 0 bitwise shift left +1879 pg_operator 0 bitwise shift right +1880 pg_operator 0 bitwise and +1881 pg_operator 0 bitwise or +1882 pg_operator 0 bitwise exclusive or +1883 pg_operator 0 bitwise not +1884 pg_operator 0 bitwise shift left +1885 pg_operator 0 bitwise shift right +1886 pg_operator 0 bitwise and +1887 pg_operator 0 bitwise or +1888 pg_operator 0 bitwise exclusive or +1889 pg_operator 0 bitwise not +1890 pg_operator 0 bitwise shift left +1891 pg_operator 0 bitwise shift right +1916 pg_operator 0 unary plus +1917 pg_operator 0 unary plus +1918 pg_operator 0 unary plus +1919 pg_operator 0 unary plus +1920 pg_operator 0 unary plus +1921 pg_operator 0 unary plus +1955 pg_operator 0 equal +1956 pg_operator 0 not equal +1957 pg_operator 0 less than +1958 pg_operator 0 less than or equal +1959 pg_operator 0 greater than +1960 pg_operator 0 greater than or equal +2016 pg_operator 0 matches LIKE expression +2017 pg_operator 0 does not match LIKE expression +2018 pg_operator 0 concatenate +2060 pg_operator 0 equal +2061 pg_operator 0 not equal +2062 pg_operator 0 less than +2063 pg_operator 0 less than or equal +2064 pg_operator 0 greater than +2065 pg_operator 0 greater than or equal +2066 pg_operator 0 add +2067 pg_operator 0 subtract +2068 pg_operator 0 subtract +2314 pg_operator 0 less than +2315 pg_operator 0 less than or equal +2317 pg_operator 0 greater than or equal +2318 pg_operator 0 greater than +2326 pg_operator 0 less than +2327 pg_operator 0 less than or equal +2329 pg_operator 0 greater than or equal +2330 pg_operator 0 greater than +2345 pg_operator 0 less than +2346 pg_operator 0 less than or equal +2347 pg_operator 0 equal +2348 pg_operator 0 greater than or equal +2349 pg_operator 0 greater than +2350 pg_operator 0 not equal +2358 pg_operator 0 less than +2359 pg_operator 0 less than or equal +2360 pg_operator 0 equal +2361 pg_operator 0 greater than or equal +2362 pg_operator 0 greater than +2363 pg_operator 0 not equal +2371 pg_operator 0 less than +2372 pg_operator 0 less than or equal +2373 pg_operator 0 equal +2374 pg_operator 0 greater than or equal +2375 pg_operator 0 greater than +2376 pg_operator 0 not equal +2384 pg_operator 0 less than +2385 pg_operator 0 less than or equal +2386 pg_operator 0 equal +2387 pg_operator 0 greater than or equal +2388 pg_operator 0 greater than +2389 pg_operator 0 not equal +2534 pg_operator 0 less than +2535 pg_operator 0 less than or equal +2536 pg_operator 0 equal +2537 pg_operator 0 greater than or equal +2538 pg_operator 0 greater than +2539 pg_operator 0 not equal +2540 pg_operator 0 less than +2541 pg_operator 0 less than or equal +2542 pg_operator 0 equal +2543 pg_operator 0 greater than or equal +2544 pg_operator 0 greater than +2545 pg_operator 0 not equal +2551 pg_operator 0 add +2552 pg_operator 0 add +2553 pg_operator 0 add +2554 pg_operator 0 add +2555 pg_operator 0 add +2570 pg_operator 0 is below +2571 pg_operator 0 overlaps or is below +2572 pg_operator 0 overlaps or is above +2573 pg_operator 0 is above +2574 pg_operator 0 is below +2575 pg_operator 0 overlaps or is below +2576 pg_operator 0 overlaps or is above +2577 pg_operator 0 is above +2589 pg_operator 0 overlaps or is below +2590 pg_operator 0 overlaps or is above +2750 pg_operator 0 overlaps +2751 pg_operator 0 contains +2752 pg_operator 0 is contained by +2779 pg_operator 0 concatenate +2780 pg_operator 0 concatenate +2860 pg_operator 0 deprecated, use <@ instead +2861 pg_operator 0 deprecated, use @> instead +2862 pg_operator 0 deprecated, use <@ instead +2863 pg_operator 0 deprecated, use @> instead +2864 pg_operator 0 deprecated, use <@ instead +2865 pg_operator 0 deprecated, use @> instead +2866 pg_operator 0 deprecated, use <@ instead +2867 pg_operator 0 deprecated, use <@ instead +2868 pg_operator 0 deprecated, use @> instead +2869 pg_operator 0 deprecated, use <@ instead +2870 pg_operator 0 deprecated, use @> instead +2871 pg_operator 0 deprecated, use <@ instead +2872 pg_operator 0 deprecated, use @> instead +2873 pg_operator 0 deprecated, use <@ instead +2874 pg_operator 0 deprecated, use <@ instead +2875 pg_operator 0 deprecated, use <@ instead +2876 pg_operator 0 deprecated, use <@ instead +2877 pg_operator 0 deprecated, use @> instead +2972 pg_operator 0 equal +2973 pg_operator 0 not equal +2974 pg_operator 0 less than +2975 pg_operator 0 greater than +2976 pg_operator 0 less than or equal +2977 pg_operator 0 greater than or equal +3516 pg_operator 0 equal +3517 pg_operator 0 not equal +3518 pg_operator 0 less than +3519 pg_operator 0 greater than +3520 pg_operator 0 less than or equal +3521 pg_operator 0 greater than or equal +3627 pg_operator 0 less than +3628 pg_operator 0 less than or equal +3629 pg_operator 0 equal +3630 pg_operator 0 not equal +3631 pg_operator 0 greater than or equal +3632 pg_operator 0 greater than +3633 pg_operator 0 concatenate +3636 pg_operator 0 text search match +3637 pg_operator 0 text search match +3660 pg_operator 0 deprecated, use @@ instead +3661 pg_operator 0 deprecated, use @@ instead +3674 pg_operator 0 less than +3675 pg_operator 0 less than or equal +3676 pg_operator 0 equal +3677 pg_operator 0 not equal +3678 pg_operator 0 greater than or equal +3679 pg_operator 0 greater than +3680 pg_operator 0 AND-concatenate +3681 pg_operator 0 OR-concatenate +3682 pg_operator 0 NOT tsquery +3693 pg_operator 0 contains +3694 pg_operator 0 is contained by +3762 pg_operator 0 text search match +3763 pg_operator 0 text search match +2988 pg_operator 0 equal +2989 pg_operator 0 not equal +2990 pg_operator 0 less than +2991 pg_operator 0 greater than +2992 pg_operator 0 less than or equal +2993 pg_operator 0 greater than or equal +3882 pg_operator 0 equal +3883 pg_operator 0 not equal +3884 pg_operator 0 less than +3885 pg_operator 0 less than or equal +3886 pg_operator 0 greater than or equal +3887 pg_operator 0 greater than +3888 pg_operator 0 overlaps +3889 pg_operator 0 contains +3890 pg_operator 0 contains +3891 pg_operator 0 is contained by +3892 pg_operator 0 is contained by +3893 pg_operator 0 is left of +3894 pg_operator 0 is right of +3895 pg_operator 0 overlaps or is left of +3896 pg_operator 0 overlaps or is right of +3897 pg_operator 0 is adjacent to +3898 pg_operator 0 range union +3899 pg_operator 0 range difference +3900 pg_operator 0 range intersection +403 pg_am 0 b-tree index access method +405 pg_am 0 hash index access method +783 pg_am 0 GiST index access method +2742 pg_am 0 GIN index access method +4000 pg_am 0 SP-GiST index access method +12 pg_language 0 built-in functions +13 pg_language 0 dynamically-loaded C functions +14 pg_language 0 SQL-language functions +11 pg_namespace 0 system catalog schema +99 pg_namespace 0 reserved schema for TOAST tables +2200 pg_namespace 0 standard public schema +3748 pg_ts_config 0 simple configuration +3765 pg_ts_dict 0 simple dictionary: just lower case and check for stopword +3722 pg_ts_parser 0 default word parser +3727 pg_ts_template 0 simple dictionary: just lower case and check for stopword +3730 pg_ts_template 0 synonym dictionary: replace word by its synonym +3733 pg_ts_template 0 ispell dictionary +3742 pg_ts_template 0 thesaurus dictionary: phrase by phrase substitution +100 pg_collation 0 database's default collation +950 pg_collation 0 standard C collation +951 pg_collation 0 standard POSIX collation diff --git a/src/backend/catalog/postgres.shdescription b/src/backend/catalog/postgres.shdescription new file mode 100644 index 000000000..fcd84a22f --- /dev/null +++ b/src/backend/catalog/postgres.shdescription @@ -0,0 +1 @@ +1 pg_database default template for new databases diff --git a/src/backend/catalog/schemapg.h b/src/backend/catalog/schemapg.h new file mode 100644 index 000000000..f937213c7 --- /dev/null +++ b/src/backend/catalog/schemapg.h @@ -0,0 +1,186 @@ +/*------------------------------------------------------------------------- + * + * schemapg.h + * Schema_pg_xxx macros for use by relcache.c + * + * Portions Copyright (c) 1996-2012, PostgreSQL Global Development Group + * Portions Copyright (c) 1994, Regents of the University of California + * + * NOTES + * ****************************** + * *** DO NOT EDIT THIS FILE! *** + * ****************************** + * + * It has been GENERATED by genbki.pl + * + *------------------------------------------------------------------------- + */ +#ifndef SCHEMAPG_H +#define SCHEMAPG_H + +#define Schema_pg_proc \ +{ 1255, {"proname"}, 19, -1, NAMEDATALEN, 1, 0, -1, -1, false, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1255, {"pronamespace"}, 26, -1, 4, 2, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1255, {"proowner"}, 26, -1, 4, 3, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1255, {"prolang"}, 26, -1, 4, 4, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1255, {"procost"}, 700, -1, 4, 5, 0, -1, -1, FLOAT4PASSBYVAL, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1255, {"prorows"}, 700, -1, 4, 6, 0, -1, -1, FLOAT4PASSBYVAL, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1255, {"provariadic"}, 26, -1, 4, 7, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1255, {"protransform"}, 24, -1, 4, 8, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1255, {"proisagg"}, 16, -1, 1, 9, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1255, {"proiswindow"}, 16, -1, 1, 10, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1255, {"prosecdef"}, 16, -1, 1, 11, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1255, {"proleakproof"}, 16, -1, 1, 12, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1255, {"proisstrict"}, 16, -1, 1, 13, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1255, {"proretset"}, 16, -1, 1, 14, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1255, {"provolatile"}, 18, -1, 1, 15, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1255, {"pronargs"}, 21, -1, 2, 16, 0, -1, -1, true, 'p', 's', true, false, false, true, 0, 0 }, \ +{ 1255, {"pronargdefaults"}, 21, -1, 2, 17, 0, -1, -1, true, 'p', 's', true, false, false, true, 0, 0 }, \ +{ 1255, {"prorettype"}, 26, -1, 4, 18, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1255, {"proargtypes"}, 30, -1, -1, 19, 1, -1, -1, false, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1255, {"proallargtypes"}, 1028, -1, -1, 20, 1, -1, -1, false, 'x', 'i', false, false, false, true, 0, 0 }, \ +{ 1255, {"proargmodes"}, 1002, -1, -1, 21, 1, -1, -1, false, 'x', 'i', false, false, false, true, 0, 0 }, \ +{ 1255, {"proargnames"}, 1009, -1, -1, 22, 1, -1, -1, false, 'x', 'i', false, false, false, true, 0, 100 }, \ +{ 1255, {"proargdefaults"}, 194, -1, -1, 23, 0, -1, -1, false, 'x', 'i', false, false, false, true, 0, 100 }, \ +{ 1255, {"prosrc"}, 25, -1, -1, 24, 0, -1, -1, false, 'x', 'i', false, false, false, true, 0, 100 }, \ +{ 1255, {"probin"}, 25, -1, -1, 25, 0, -1, -1, false, 'x', 'i', false, false, false, true, 0, 100 }, \ +{ 1255, {"proconfig"}, 1009, -1, -1, 26, 1, -1, -1, false, 'x', 'i', false, false, false, true, 0, 100 }, \ +{ 1255, {"proacl"}, 1034, -1, -1, 27, 1, -1, -1, false, 'x', 'i', false, false, false, true, 0, 0 } + +#define Schema_pg_type \ +{ 1247, {"typname"}, 19, -1, NAMEDATALEN, 1, 0, -1, -1, false, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1247, {"typnamespace"}, 26, -1, 4, 2, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1247, {"typowner"}, 26, -1, 4, 3, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1247, {"typlen"}, 21, -1, 2, 4, 0, -1, -1, true, 'p', 's', true, false, false, true, 0, 0 }, \ +{ 1247, {"typbyval"}, 16, -1, 1, 5, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1247, {"typtype"}, 18, -1, 1, 6, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1247, {"typcategory"}, 18, -1, 1, 7, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1247, {"typispreferred"}, 16, -1, 1, 8, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1247, {"typisdefined"}, 16, -1, 1, 9, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1247, {"typdelim"}, 18, -1, 1, 10, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1247, {"typrelid"}, 26, -1, 4, 11, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1247, {"typelem"}, 26, -1, 4, 12, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1247, {"typarray"}, 26, -1, 4, 13, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1247, {"typinput"}, 24, -1, 4, 14, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1247, {"typoutput"}, 24, -1, 4, 15, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1247, {"typreceive"}, 24, -1, 4, 16, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1247, {"typsend"}, 24, -1, 4, 17, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1247, {"typmodin"}, 24, -1, 4, 18, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1247, {"typmodout"}, 24, -1, 4, 19, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1247, {"typanalyze"}, 24, -1, 4, 20, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1247, {"typalign"}, 18, -1, 1, 21, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1247, {"typstorage"}, 18, -1, 1, 22, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1247, {"typnotnull"}, 16, -1, 1, 23, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1247, {"typbasetype"}, 26, -1, 4, 24, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1247, {"typtypmod"}, 23, -1, 4, 25, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1247, {"typndims"}, 23, -1, 4, 26, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1247, {"typcollation"}, 26, -1, 4, 27, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1247, {"typdefaultbin"}, 194, -1, -1, 28, 0, -1, -1, false, 'x', 'i', false, false, false, true, 0, 100 }, \ +{ 1247, {"typdefault"}, 25, -1, -1, 29, 0, -1, -1, false, 'x', 'i', false, false, false, true, 0, 100 }, \ +{ 1247, {"typacl"}, 1034, -1, -1, 30, 1, -1, -1, false, 'x', 'i', false, false, false, true, 0, 0 } + +#define Schema_pg_attribute \ +{ 1249, {"attrelid"}, 26, -1, 4, 1, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1249, {"attname"}, 19, -1, NAMEDATALEN, 2, 0, -1, -1, false, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1249, {"atttypid"}, 26, -1, 4, 3, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1249, {"attstattarget"}, 23, -1, 4, 4, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1249, {"attlen"}, 21, -1, 2, 5, 0, -1, -1, true, 'p', 's', true, false, false, true, 0, 0 }, \ +{ 1249, {"attnum"}, 21, -1, 2, 6, 0, -1, -1, true, 'p', 's', true, false, false, true, 0, 0 }, \ +{ 1249, {"attndims"}, 23, -1, 4, 7, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1249, {"attcacheoff"}, 23, -1, 4, 8, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1249, {"atttypmod"}, 23, -1, 4, 9, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1249, {"attbyval"}, 16, -1, 1, 10, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1249, {"attstorage"}, 18, -1, 1, 11, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1249, {"attalign"}, 18, -1, 1, 12, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1249, {"attnotnull"}, 16, -1, 1, 13, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1249, {"atthasdef"}, 16, -1, 1, 14, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1249, {"attisdropped"}, 16, -1, 1, 15, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1249, {"attislocal"}, 16, -1, 1, 16, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1249, {"attinhcount"}, 23, -1, 4, 17, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1249, {"attcollation"}, 26, -1, 4, 18, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1249, {"attacl"}, 1034, -1, -1, 19, 1, -1, -1, false, 'x', 'i', false, false, false, true, 0, 0 }, \ +{ 1249, {"attoptions"}, 1009, -1, -1, 20, 1, -1, -1, false, 'x', 'i', false, false, false, true, 0, 100 }, \ +{ 1249, {"attfdwoptions"}, 1009, -1, -1, 21, 1, -1, -1, false, 'x', 'i', false, false, false, true, 0, 100 } + +#define Schema_pg_class \ +{ 1259, {"relname"}, 19, -1, NAMEDATALEN, 1, 0, -1, -1, false, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1259, {"relnamespace"}, 26, -1, 4, 2, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1259, {"reltype"}, 26, -1, 4, 3, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1259, {"reloftype"}, 26, -1, 4, 4, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1259, {"relowner"}, 26, -1, 4, 5, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1259, {"relam"}, 26, -1, 4, 6, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1259, {"relfilenode"}, 26, -1, 4, 7, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1259, {"reltablespace"}, 26, -1, 4, 8, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1259, {"relpages"}, 23, -1, 4, 9, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1259, {"reltuples"}, 700, -1, 4, 10, 0, -1, -1, FLOAT4PASSBYVAL, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1259, {"relallvisible"}, 23, -1, 4, 11, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1259, {"reltoastrelid"}, 26, -1, 4, 12, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1259, {"reltoastidxid"}, 26, -1, 4, 13, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1259, {"relhasindex"}, 16, -1, 1, 14, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1259, {"relisshared"}, 16, -1, 1, 15, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1259, {"relpersistence"}, 18, -1, 1, 16, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1259, {"relkind"}, 18, -1, 1, 17, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1259, {"relnatts"}, 21, -1, 2, 18, 0, -1, -1, true, 'p', 's', true, false, false, true, 0, 0 }, \ +{ 1259, {"relchecks"}, 21, -1, 2, 19, 0, -1, -1, true, 'p', 's', true, false, false, true, 0, 0 }, \ +{ 1259, {"relhasoids"}, 16, -1, 1, 20, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1259, {"relhaspkey"}, 16, -1, 1, 21, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1259, {"relhasrules"}, 16, -1, 1, 22, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1259, {"relhastriggers"}, 16, -1, 1, 23, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1259, {"relhassubclass"}, 16, -1, 1, 24, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1259, {"relfrozenxid"}, 28, -1, 4, 25, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1259, {"relacl"}, 1034, -1, -1, 26, 1, -1, -1, false, 'x', 'i', false, false, false, true, 0, 0 }, \ +{ 1259, {"reloptions"}, 1009, -1, -1, 27, 1, -1, -1, false, 'x', 'i', false, false, false, true, 0, 100 } + +#define Schema_pg_index \ +{ 2610, {"indexrelid"}, 26, -1, 4, 1, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 2610, {"indrelid"}, 26, -1, 4, 2, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 2610, {"indnatts"}, 21, -1, 2, 3, 0, -1, -1, true, 'p', 's', true, false, false, true, 0, 0 }, \ +{ 2610, {"indisunique"}, 16, -1, 1, 4, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 2610, {"indisprimary"}, 16, -1, 1, 5, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 2610, {"indisexclusion"}, 16, -1, 1, 6, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 2610, {"indimmediate"}, 16, -1, 1, 7, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 2610, {"indisclustered"}, 16, -1, 1, 8, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 2610, {"indisvalid"}, 16, -1, 1, 9, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 2610, {"indcheckxmin"}, 16, -1, 1, 10, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 2610, {"indisready"}, 16, -1, 1, 11, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 2610, {"indkey"}, 22, -1, -1, 12, 1, -1, -1, false, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 2610, {"indcollation"}, 30, -1, -1, 13, 1, -1, -1, false, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 2610, {"indclass"}, 30, -1, -1, 14, 1, -1, -1, false, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 2610, {"indoption"}, 22, -1, -1, 15, 1, -1, -1, false, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 2610, {"indexprs"}, 194, -1, -1, 16, 0, -1, -1, false, 'x', 'i', false, false, false, true, 0, 100 }, \ +{ 2610, {"indpred"}, 194, -1, -1, 17, 0, -1, -1, false, 'x', 'i', false, false, false, true, 0, 100 } + +#define Schema_pg_database \ +{ 1262, {"datname"}, 19, -1, NAMEDATALEN, 1, 0, -1, -1, false, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1262, {"datdba"}, 26, -1, 4, 2, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1262, {"encoding"}, 23, -1, 4, 3, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1262, {"datcollate"}, 19, -1, NAMEDATALEN, 4, 0, -1, -1, false, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1262, {"datctype"}, 19, -1, NAMEDATALEN, 5, 0, -1, -1, false, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1262, {"datistemplate"}, 16, -1, 1, 6, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1262, {"datallowconn"}, 16, -1, 1, 7, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1262, {"datconnlimit"}, 23, -1, 4, 8, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1262, {"datlastsysoid"}, 26, -1, 4, 9, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1262, {"datfrozenxid"}, 28, -1, 4, 10, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1262, {"dattablespace"}, 26, -1, 4, 11, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1262, {"datacl"}, 1034, -1, -1, 12, 1, -1, -1, false, 'x', 'i', false, false, false, true, 0, 0 } + +#define Schema_pg_authid \ +{ 1260, {"rolname"}, 19, -1, NAMEDATALEN, 1, 0, -1, -1, false, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1260, {"rolsuper"}, 16, -1, 1, 2, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1260, {"rolinherit"}, 16, -1, 1, 3, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1260, {"rolcreaterole"}, 16, -1, 1, 4, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1260, {"rolcreatedb"}, 16, -1, 1, 5, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1260, {"rolcatupdate"}, 16, -1, 1, 6, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1260, {"rolcanlogin"}, 16, -1, 1, 7, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1260, {"rolreplication"}, 16, -1, 1, 8, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 }, \ +{ 1260, {"rolconnlimit"}, 23, -1, 4, 9, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1260, {"rolpassword"}, 25, -1, -1, 10, 0, -1, -1, false, 'x', 'i', false, false, false, true, 0, 100 }, \ +{ 1260, {"rolvaliduntil"}, 1184, -1, 8, 11, 0, -1, -1, FLOAT8PASSBYVAL, 'p', 'd', false, false, false, true, 0, 0 } + +#define Schema_pg_auth_members \ +{ 1261, {"roleid"}, 26, -1, 4, 1, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1261, {"member"}, 26, -1, 4, 2, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1261, {"grantor"}, 26, -1, 4, 3, 0, -1, -1, true, 'p', 'i', true, false, false, true, 0, 0 }, \ +{ 1261, {"admin_option"}, 16, -1, 1, 4, 0, -1, -1, true, 'p', 'c', true, false, false, true, 0, 0 } + +#endif /* SCHEMAPG_H */ diff --git a/src/backend/parser/.gitignore b/src/backend/parser/.gitignore deleted file mode 100644 index 16ac68d25..000000000 --- a/src/backend/parser/.gitignore +++ /dev/null @@ -1,3 +0,0 @@ -/gram.h -/gram.c -/scan.c diff --git a/src/backend/parser/gram.c b/src/backend/parser/gram.c new file mode 100644 index 000000000..293b5f24d --- /dev/null +++ b/src/backend/parser/gram.c @@ -0,0 +1,38592 @@ + +/* A Bison parser, made by GNU Bison 2.4.1. */ + +/* Skeleton implementation for Bison's Yacc-like parsers in C + + Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 + Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . */ + +/* As a special exception, you may create a larger work that contains + part or all of the Bison parser skeleton and distribute that work + under terms of your choice, so long as that work isn't itself a + parser generator using the skeleton or a modified version thereof + as a parser skeleton. Alternatively, if you modify or redistribute + the parser skeleton itself, you may (at your option) remove this + special exception, which will cause the skeleton and the resulting + Bison output files to be licensed under the GNU General Public + License without this special exception. + + This special exception was added by the Free Software Foundation in + version 2.2 of Bison. */ + +/* C LALR(1) parser skeleton written by Richard Stallman, by + simplifying the original so-called "semantic" parser. */ + +/* All symbols defined below should begin with yy or YY, to avoid + infringing on user name space. This should be done even for local + variables, as they might otherwise be expanded by user macros. + There are some unavoidable exceptions within include files to + define necessary library symbols; they are noted "INFRINGES ON + USER NAME SPACE" below. */ + +/* Identify Bison output. */ +#define YYBISON 1 + +/* Bison version. */ +#define YYBISON_VERSION "2.4.1" + +/* Skeleton name. */ +#define YYSKELETON_NAME "yacc.c" + +/* Pure parsers. */ +#define YYPURE 1 + +/* Push parsers. */ +#define YYPUSH 0 + +/* Pull parsers. */ +#define YYPULL 1 + +/* Using locations. */ +#define YYLSP_NEEDED 1 + +/* Substitute the variable and function names. */ +#define yyparse base_yyparse +#define yylex base_yylex +#define yyerror base_yyerror +#define yylval base_yylval +#define yychar base_yychar +#define yydebug base_yydebug +#define yynerrs base_yynerrs +#define yylloc base_yylloc + +/* Copy the first part of user declarations. */ + +/* Line 189 of yacc.c */ +#line 1 "gram.y" + + +/*#define YYDEBUG 1*/ +/*------------------------------------------------------------------------- + * + * gram.y + * POSTGRESQL BISON rules/actions + * + * Portions Copyright (c) 1996-2012, PostgreSQL Global Development Group + * Portions Copyright (c) 1994, Regents of the University of California + * + * + * IDENTIFICATION + * src/backend/parser/gram.y + * + * HISTORY + * AUTHOR DATE MAJOR EVENT + * Andrew Yu Sept, 1994 POSTQUEL to SQL conversion + * Andrew Yu Oct, 1994 lispy code conversion + * + * NOTES + * CAPITALS are used to represent terminal symbols. + * non-capitals are used to represent non-terminals. + * SQL92-specific syntax is separated from plain SQL/Postgres syntax + * to help isolate the non-extensible portions of the parser. + * + * In general, nothing in this file should initiate database accesses + * nor depend on changeable state (such as SET variables). If you do + * database accesses, your code will fail when we have aborted the + * current transaction and are just parsing commands to find the next + * ROLLBACK or COMMIT. If you make use of SET variables, then you + * will do the wrong thing in multi-query strings like this: + * SET SQL_inheritance TO off; SELECT * FROM foo; + * because the entire string is parsed by gram.y before the SET gets + * executed. Anything that depends on the database or changeable state + * should be handled during parse analysis so that it happens at the + * right time not the wrong time. The handling of SQL_inheritance is + * a good example. + * + * WARNINGS + * If you use a list, make sure the datum is a node so that the printing + * routines work. + * + * Sometimes we assign constants to makeStrings. Make sure we don't free + * those. + * + *------------------------------------------------------------------------- + */ +#include "postgres.h" + +#include +#include + +#include "catalog/index.h" +#include "catalog/namespace.h" +#include "catalog/pg_trigger.h" +#include "commands/defrem.h" +#include "nodes/makefuncs.h" +#include "nodes/nodeFuncs.h" +#include "parser/gramparse.h" +#include "parser/parser.h" +#include "storage/lmgr.h" +#include "utils/date.h" +#include "utils/datetime.h" +#include "utils/numeric.h" +#include "utils/xml.h" + + +/* Location tracking support --- simpler than bison's default */ +#define YYLLOC_DEFAULT(Current, Rhs, N) \ + do { \ + if (N) \ + (Current) = (Rhs)[1]; \ + else \ + (Current) = (Rhs)[0]; \ + } while (0) + +/* + * Bison doesn't allocate anything that needs to live across parser calls, + * so we can easily have it use palloc instead of malloc. This prevents + * memory leaks if we error out during parsing. Note this only works with + * bison >= 2.0. However, in bison 1.875 the default is to use alloca() + * if possible, so there's not really much problem anyhow, at least if + * you're building with gcc. + */ +#define YYMALLOC palloc +#define YYFREE pfree + +/* Private struct for the result of privilege_target production */ +typedef struct PrivTarget +{ + GrantTargetType targtype; + GrantObjectType objtype; + List *objs; +} PrivTarget; + +/* ConstraintAttributeSpec yields an integer bitmask of these flags: */ +#define CAS_NOT_DEFERRABLE 0x01 +#define CAS_DEFERRABLE 0x02 +#define CAS_INITIALLY_IMMEDIATE 0x04 +#define CAS_INITIALLY_DEFERRED 0x08 +#define CAS_NOT_VALID 0x10 +#define CAS_NO_INHERIT 0x20 + + +#define parser_yyerror(msg) scanner_yyerror(msg, yyscanner) +#define parser_errposition(pos) scanner_errposition(pos, yyscanner) + +static void base_yyerror(YYLTYPE *yylloc, core_yyscan_t yyscanner, + const char *msg); +static Node *makeColumnRef(char *colname, List *indirection, + int location, core_yyscan_t yyscanner); +static Node *makeTypeCast(Node *arg, TypeName *typename, int location); +static Node *makeStringConst(char *str, int location); +static Node *makeStringConstCast(char *str, int location, TypeName *typename); +static Node *makeIntConst(int val, int location); +static Node *makeFloatConst(char *str, int location); +static Node *makeBitStringConst(char *str, int location); +static Node *makeNullAConst(int location); +static Node *makeAConst(Value *v, int location); +static Node *makeBoolAConst(bool state, int location); +static FuncCall *makeOverlaps(List *largs, List *rargs, + int location, core_yyscan_t yyscanner); +static void check_qualified_name(List *names, core_yyscan_t yyscanner); +static List *check_func_name(List *names, core_yyscan_t yyscanner); +static List *check_indirection(List *indirection, core_yyscan_t yyscanner); +static List *extractArgTypes(List *parameters); +static void insertSelectOptions(SelectStmt *stmt, + List *sortClause, List *lockingClause, + Node *limitOffset, Node *limitCount, + WithClause *withClause, + core_yyscan_t yyscanner); +static Node *makeSetOp(SetOperation op, bool all, Node *larg, Node *rarg); +static Node *doNegate(Node *n, int location); +static void doNegateFloat(Value *v); +static Node *makeAArrayExpr(List *elements, int location); +static Node *makeXmlExpr(XmlExprOp op, char *name, List *named_args, + List *args, int location); +static List *mergeTableFuncParameters(List *func_args, List *columns); +static TypeName *TableFuncTypeName(List *columns); +static RangeVar *makeRangeVarFromAnyName(List *names, int position, core_yyscan_t yyscanner); +static void SplitColQualList(List *qualList, + List **constraintList, CollateClause **collClause, + core_yyscan_t yyscanner); +static void processCASbits(int cas_bits, int location, const char *constrType, + bool *deferrable, bool *initdeferred, bool *not_valid, + bool *no_inherit, core_yyscan_t yyscanner); + + + +/* Line 189 of yacc.c */ +#line 232 "gram.c" + +/* Enabling traces. */ +#ifndef YYDEBUG +# define YYDEBUG 0 +#endif + +/* Enabling verbose error messages. */ +#ifdef YYERROR_VERBOSE +# undef YYERROR_VERBOSE +# define YYERROR_VERBOSE 1 +#else +# define YYERROR_VERBOSE 0 +#endif + +/* Enabling the token table. */ +#ifndef YYTOKEN_TABLE +# define YYTOKEN_TABLE 0 +#endif + + +/* Tokens. */ +#ifndef YYTOKENTYPE +# define YYTOKENTYPE + /* Put the tokens into the symbol table, so that GDB and other debuggers + know about them. */ + enum yytokentype { + IDENT = 258, + FCONST = 259, + SCONST = 260, + BCONST = 261, + XCONST = 262, + Op = 263, + ICONST = 264, + PARAM = 265, + TYPECAST = 266, + DOT_DOT = 267, + COLON_EQUALS = 268, + ABORT_P = 269, + ABSOLUTE_P = 270, + ACCESS = 271, + ACTION = 272, + ADD_P = 273, + ADMIN = 274, + AFTER = 275, + AGGREGATE = 276, + ALL = 277, + ALSO = 278, + ALTER = 279, + ALWAYS = 280, + ANALYSE = 281, + ANALYZE = 282, + AND = 283, + ANY = 284, + ARRAY = 285, + AS = 286, + ASC = 287, + ASSERTION = 288, + ASSIGNMENT = 289, + ASYMMETRIC = 290, + AT = 291, + ATTRIBUTE = 292, + AUTHORIZATION = 293, + BACKWARD = 294, + BEFORE = 295, + BEGIN_P = 296, + BETWEEN = 297, + BIGINT = 298, + BINARY = 299, + BIT = 300, + BOOLEAN_P = 301, + BOTH = 302, + BY = 303, + CACHE = 304, + CALLED = 305, + CASCADE = 306, + CASCADED = 307, + CASE = 308, + CAST = 309, + CATALOG_P = 310, + CHAIN = 311, + CHAR_P = 312, + CHARACTER = 313, + CHARACTERISTICS = 314, + CHECK = 315, + CHECKPOINT = 316, + CLASS = 317, + CLOSE = 318, + CLUSTER = 319, + COALESCE = 320, + COLLATE = 321, + COLLATION = 322, + COLUMN = 323, + COMMENT = 324, + COMMENTS = 325, + COMMIT = 326, + COMMITTED = 327, + CONCURRENTLY = 328, + CONFIGURATION = 329, + CONNECTION = 330, + CONSTRAINT = 331, + CONSTRAINTS = 332, + CONTENT_P = 333, + CONTINUE_P = 334, + CONVERSION_P = 335, + COPY = 336, + COST = 337, + CREATE = 338, + CROSS = 339, + CSV = 340, + CURRENT_P = 341, + CURRENT_CATALOG = 342, + CURRENT_DATE = 343, + CURRENT_ROLE = 344, + CURRENT_SCHEMA = 345, + CURRENT_TIME = 346, + CURRENT_TIMESTAMP = 347, + CURRENT_USER = 348, + CURSOR = 349, + CYCLE = 350, + DATA_P = 351, + DATABASE = 352, + DAY_P = 353, + DEALLOCATE = 354, + DEC = 355, + DECIMAL_P = 356, + DECLARE = 357, + DEFAULT = 358, + DEFAULTS = 359, + DEFERRABLE = 360, + DEFERRED = 361, + DEFINER = 362, + DELETE_P = 363, + DELIMITER = 364, + DELIMITERS = 365, + DESC = 366, + DICTIONARY = 367, + DISABLE_P = 368, + DISCARD = 369, + DISTINCT = 370, + DO = 371, + DOCUMENT_P = 372, + DOMAIN_P = 373, + DOUBLE_P = 374, + DROP = 375, + EACH = 376, + ELSE = 377, + ENABLE_P = 378, + ENCODING = 379, + ENCRYPTED = 380, + END_P = 381, + ENUM_P = 382, + ESCAPE = 383, + EXCEPT = 384, + EXCLUDE = 385, + EXCLUDING = 386, + EXCLUSIVE = 387, + EXECUTE = 388, + EXISTS = 389, + EXPLAIN = 390, + EXTENSION = 391, + EXTERNAL = 392, + EXTRACT = 393, + FALSE_P = 394, + FAMILY = 395, + FETCH = 396, + FIRST_P = 397, + FLOAT_P = 398, + FOLLOWING = 399, + FOR = 400, + FORCE = 401, + FOREIGN = 402, + FORWARD = 403, + FREEZE = 404, + FROM = 405, + FULL = 406, + FUNCTION = 407, + FUNCTIONS = 408, + GLOBAL = 409, + GRANT = 410, + GRANTED = 411, + GREATEST = 412, + GROUP_P = 413, + HANDLER = 414, + HAVING = 415, + HEADER_P = 416, + HOLD = 417, + HOUR_P = 418, + IDENTITY_P = 419, + IF_P = 420, + ILIKE = 421, + IMMEDIATE = 422, + IMMUTABLE = 423, + IMPLICIT_P = 424, + IN_P = 425, + INCLUDING = 426, + INCREMENT = 427, + INDEX = 428, + INDEXES = 429, + INHERIT = 430, + INHERITS = 431, + INITIALLY = 432, + INLINE_P = 433, + INNER_P = 434, + INOUT = 435, + INPUT_P = 436, + INSENSITIVE = 437, + INSERT = 438, + INSTEAD = 439, + INT_P = 440, + INTEGER = 441, + INTERSECT = 442, + INTERVAL = 443, + INTO = 444, + INVOKER = 445, + IS = 446, + ISNULL = 447, + ISOLATION = 448, + JOIN = 449, + KEY = 450, + LABEL = 451, + LANGUAGE = 452, + LARGE_P = 453, + LAST_P = 454, + LC_COLLATE_P = 455, + LC_CTYPE_P = 456, + LEADING = 457, + LEAKPROOF = 458, + LEAST = 459, + LEFT = 460, + LEVEL = 461, + LIKE = 462, + LIMIT = 463, + LISTEN = 464, + LOAD = 465, + LOCAL = 466, + LOCALTIME = 467, + LOCALTIMESTAMP = 468, + LOCATION = 469, + LOCK_P = 470, + MAPPING = 471, + MATCH = 472, + MAXVALUE = 473, + MINUTE_P = 474, + MINVALUE = 475, + MODE = 476, + MONTH_P = 477, + MOVE = 478, + NAME_P = 479, + NAMES = 480, + NATIONAL = 481, + NATURAL = 482, + NCHAR = 483, + NEXT = 484, + NO = 485, + NONE = 486, + NOT = 487, + NOTHING = 488, + NOTIFY = 489, + NOTNULL = 490, + NOWAIT = 491, + NULL_P = 492, + NULLIF = 493, + NULLS_P = 494, + NUMERIC = 495, + OBJECT_P = 496, + OF = 497, + OFF = 498, + OFFSET = 499, + OIDS = 500, + ON = 501, + ONLY = 502, + OPERATOR = 503, + OPTION = 504, + OPTIONS = 505, + OR = 506, + ORDER = 507, + OUT_P = 508, + OUTER_P = 509, + OVER = 510, + OVERLAPS = 511, + OVERLAY = 512, + OWNED = 513, + OWNER = 514, + PARSER = 515, + PARTIAL = 516, + PARTITION = 517, + PASSING = 518, + PASSWORD = 519, + PLACING = 520, + PLANS = 521, + POSITION = 522, + PRECEDING = 523, + PRECISION = 524, + PRESERVE = 525, + PREPARE = 526, + PREPARED = 527, + PRIMARY = 528, + PRIOR = 529, + PRIVILEGES = 530, + PROCEDURAL = 531, + PROCEDURE = 532, + QUOTE = 533, + RANGE = 534, + READ = 535, + REAL = 536, + REASSIGN = 537, + RECHECK = 538, + RECURSIVE = 539, + REF = 540, + REFERENCES = 541, + REINDEX = 542, + RELATIVE_P = 543, + RELEASE = 544, + RENAME = 545, + REPEATABLE = 546, + REPLACE = 547, + REPLICA = 548, + RESET = 549, + RESTART = 550, + RESTRICT = 551, + RETURNING = 552, + RETURNS = 553, + REVOKE = 554, + RIGHT = 555, + ROLE = 556, + ROLLBACK = 557, + ROW = 558, + ROWS = 559, + RULE = 560, + SAVEPOINT = 561, + SCHEMA = 562, + SCROLL = 563, + SEARCH = 564, + SECOND_P = 565, + SECURITY = 566, + SELECT = 567, + SEQUENCE = 568, + SEQUENCES = 569, + SERIALIZABLE = 570, + SERVER = 571, + SESSION = 572, + SESSION_USER = 573, + SET = 574, + SETOF = 575, + SHARE = 576, + SHOW = 577, + SIMILAR = 578, + SIMPLE = 579, + SMALLINT = 580, + SNAPSHOT = 581, + SOME = 582, + STABLE = 583, + STANDALONE_P = 584, + START = 585, + STATEMENT = 586, + STATISTICS = 587, + STDIN = 588, + STDOUT = 589, + STORAGE = 590, + STRICT_P = 591, + STRIP_P = 592, + SUBSTRING = 593, + SYMMETRIC = 594, + SYSID = 595, + SYSTEM_P = 596, + TABLE = 597, + TABLES = 598, + TABLESPACE = 599, + TEMP = 600, + TEMPLATE = 601, + TEMPORARY = 602, + TEXT_P = 603, + THEN = 604, + TIME = 605, + TIMESTAMP = 606, + TO = 607, + TRAILING = 608, + TRANSACTION = 609, + TREAT = 610, + TRIGGER = 611, + TRIM = 612, + TRUE_P = 613, + TRUNCATE = 614, + TRUSTED = 615, + TYPE_P = 616, + TYPES_P = 617, + UNBOUNDED = 618, + UNCOMMITTED = 619, + UNENCRYPTED = 620, + UNION = 621, + UNIQUE = 622, + UNKNOWN = 623, + UNLISTEN = 624, + UNLOGGED = 625, + UNTIL = 626, + UPDATE = 627, + USER = 628, + USING = 629, + VACUUM = 630, + VALID = 631, + VALIDATE = 632, + VALIDATOR = 633, + VALUE_P = 634, + VALUES = 635, + VARCHAR = 636, + VARIADIC = 637, + VARYING = 638, + VERBOSE = 639, + VERSION_P = 640, + VIEW = 641, + VOLATILE = 642, + WHEN = 643, + WHERE = 644, + WHITESPACE_P = 645, + WINDOW = 646, + WITH = 647, + WITHOUT = 648, + WORK = 649, + WRAPPER = 650, + WRITE = 651, + XML_P = 652, + XMLATTRIBUTES = 653, + XMLCONCAT = 654, + XMLELEMENT = 655, + XMLEXISTS = 656, + XMLFOREST = 657, + XMLPARSE = 658, + XMLPI = 659, + XMLROOT = 660, + XMLSERIALIZE = 661, + YEAR_P = 662, + YES_P = 663, + ZONE = 664, + NULLS_FIRST = 665, + NULLS_LAST = 666, + WITH_TIME = 667, + POSTFIXOP = 668, + UMINUS = 669 + }; +#endif + + + +#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED +typedef union YYSTYPE +{ + +/* Line 214 of yacc.c */ +#line 160 "gram.y" + + core_YYSTYPE core_yystype; + /* these fields must match core_YYSTYPE: */ + int ival; + char *str; + const char *keyword; + + char chr; + bool boolean; + JoinType jtype; + DropBehavior dbehavior; + OnCommitAction oncommit; + List *list; + Node *node; + Value *value; + ObjectType objtype; + TypeName *typnam; + FunctionParameter *fun_param; + FunctionParameterMode fun_param_mode; + FuncWithArgs *funwithargs; + DefElem *defelt; + SortBy *sortby; + WindowDef *windef; + JoinExpr *jexpr; + IndexElem *ielem; + Alias *alias; + RangeVar *range; + IntoClause *into; + WithClause *with; + A_Indices *aind; + ResTarget *target; + struct PrivTarget *privtarget; + AccessPriv *accesspriv; + InsertStmt *istmt; + VariableSetStmt *vsetstmt; + + + +/* Line 214 of yacc.c */ +#line 721 "gram.c" +} YYSTYPE; +# define YYSTYPE_IS_TRIVIAL 1 +# define yystype YYSTYPE /* obsolescent; will be withdrawn */ +# define YYSTYPE_IS_DECLARED 1 +#endif + +#if ! defined YYLTYPE && ! defined YYLTYPE_IS_DECLARED +typedef struct YYLTYPE +{ + int first_line; + int first_column; + int last_line; + int last_column; +} YYLTYPE; +# define yyltype YYLTYPE /* obsolescent; will be withdrawn */ +# define YYLTYPE_IS_DECLARED 1 +# define YYLTYPE_IS_TRIVIAL 1 +#endif + + +/* Copy the second part of user declarations. */ + + +/* Line 264 of yacc.c */ +#line 746 "gram.c" + +#ifdef short +# undef short +#endif + +#ifdef YYTYPE_UINT8 +typedef YYTYPE_UINT8 yytype_uint8; +#else +typedef unsigned char yytype_uint8; +#endif + +#ifdef YYTYPE_INT8 +typedef YYTYPE_INT8 yytype_int8; +#elif (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +typedef signed char yytype_int8; +#else +typedef short int yytype_int8; +#endif + +#ifdef YYTYPE_UINT16 +typedef YYTYPE_UINT16 yytype_uint16; +#else +typedef unsigned short int yytype_uint16; +#endif + +#ifdef YYTYPE_INT16 +typedef YYTYPE_INT16 yytype_int16; +#else +typedef short int yytype_int16; +#endif + +#ifndef YYSIZE_T +# ifdef __SIZE_TYPE__ +# define YYSIZE_T __SIZE_TYPE__ +# elif defined size_t +# define YYSIZE_T size_t +# elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +# include /* INFRINGES ON USER NAME SPACE */ +# define YYSIZE_T size_t +# else +# define YYSIZE_T unsigned int +# endif +#endif + +#define YYSIZE_MAXIMUM ((YYSIZE_T) -1) + +#ifndef YY_ +# if YYENABLE_NLS +# if ENABLE_NLS +# include /* INFRINGES ON USER NAME SPACE */ +# define YY_(msgid) dgettext ("bison-runtime", msgid) +# endif +# endif +# ifndef YY_ +# define YY_(msgid) msgid +# endif +#endif + +/* Suppress unused-variable warnings by "using" E. */ +#if ! defined lint || defined __GNUC__ +# define YYUSE(e) ((void) (e)) +#else +# define YYUSE(e) /* empty */ +#endif + +/* Identity function, used to suppress warnings about constant conditions. */ +#ifndef lint +# define YYID(n) (n) +#else +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static int +YYID (int yyi) +#else +static int +YYID (yyi) + int yyi; +#endif +{ + return yyi; +} +#endif + +#if ! defined yyoverflow || YYERROR_VERBOSE + +/* The parser invokes alloca or malloc; define the necessary symbols. */ + +# ifdef YYSTACK_USE_ALLOCA +# if YYSTACK_USE_ALLOCA +# ifdef __GNUC__ +# define YYSTACK_ALLOC __builtin_alloca +# elif defined __BUILTIN_VA_ARG_INCR +# include /* INFRINGES ON USER NAME SPACE */ +# elif defined _AIX +# define YYSTACK_ALLOC __alloca +# elif defined _MSC_VER +# include /* INFRINGES ON USER NAME SPACE */ +# define alloca _alloca +# else +# define YYSTACK_ALLOC alloca +# if ! defined _ALLOCA_H && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +# include /* INFRINGES ON USER NAME SPACE */ +# ifndef _STDLIB_H +# define _STDLIB_H 1 +# endif +# endif +# endif +# endif +# endif + +# ifdef YYSTACK_ALLOC + /* Pacify GCC's `empty if-body' warning. */ +# define YYSTACK_FREE(Ptr) do { /* empty */; } while (YYID (0)) +# ifndef YYSTACK_ALLOC_MAXIMUM + /* The OS might guarantee only one guard page at the bottom of the stack, + and a page size can be as small as 4096 bytes. So we cannot safely + invoke alloca (N) if N exceeds 4096. Use a slightly smaller number + to allow for a few compiler-allocated temporary stack slots. */ +# define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */ +# endif +# else +# define YYSTACK_ALLOC YYMALLOC +# define YYSTACK_FREE YYFREE +# ifndef YYSTACK_ALLOC_MAXIMUM +# define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM +# endif +# if (defined __cplusplus && ! defined _STDLIB_H \ + && ! ((defined YYMALLOC || defined malloc) \ + && (defined YYFREE || defined free))) +# include /* INFRINGES ON USER NAME SPACE */ +# ifndef _STDLIB_H +# define _STDLIB_H 1 +# endif +# endif +# ifndef YYMALLOC +# define YYMALLOC malloc +# if ! defined malloc && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */ +# endif +# endif +# ifndef YYFREE +# define YYFREE free +# if ! defined free && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +void free (void *); /* INFRINGES ON USER NAME SPACE */ +# endif +# endif +# endif +#endif /* ! defined yyoverflow || YYERROR_VERBOSE */ + + +#if (! defined yyoverflow \ + && (! defined __cplusplus \ + || (defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL \ + && defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) + +/* A type that is properly aligned for any stack member. */ +union yyalloc +{ + yytype_int16 yyss_alloc; + YYSTYPE yyvs_alloc; + YYLTYPE yyls_alloc; +}; + +/* The size of the maximum gap between one aligned stack and the next. */ +# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1) + +/* The size of an array large to enough to hold all stacks, each with + N elements. */ +# define YYSTACK_BYTES(N) \ + ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE) + sizeof (YYLTYPE)) \ + + 2 * YYSTACK_GAP_MAXIMUM) + +/* Copy COUNT objects from FROM to TO. The source and destination do + not overlap. */ +# ifndef YYCOPY +# if defined __GNUC__ && 1 < __GNUC__ +# define YYCOPY(To, From, Count) \ + __builtin_memcpy (To, From, (Count) * sizeof (*(From))) +# else +# define YYCOPY(To, From, Count) \ + do \ + { \ + YYSIZE_T yyi; \ + for (yyi = 0; yyi < (Count); yyi++) \ + (To)[yyi] = (From)[yyi]; \ + } \ + while (YYID (0)) +# endif +# endif + +/* Relocate STACK from its old location to the new one. The + local variables YYSIZE and YYSTACKSIZE give the old and new number of + elements in the stack, and YYPTR gives the new location of the + stack. Advance YYPTR to a properly aligned location for the next + stack. */ +# define YYSTACK_RELOCATE(Stack_alloc, Stack) \ + do \ + { \ + YYSIZE_T yynewbytes; \ + YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \ + Stack = &yyptr->Stack_alloc; \ + yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ + yyptr += yynewbytes / sizeof (*yyptr); \ + } \ + while (YYID (0)) + +#endif + +/* YYFINAL -- State number of the termination state. */ +#define YYFINAL 696 +/* YYLAST -- Last index in YYTABLE. */ +#define YYLAST 72515 + +/* YYNTOKENS -- Number of terminals. */ +#define YYNTOKENS 432 +/* YYNNTS -- Number of nonterminals. */ +#define YYNNTS 544 +/* YYNRULES -- Number of rules. */ +#define YYNRULES 2254 +/* YYNRULES -- Number of states. */ +#define YYNSTATES 4291 + +/* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */ +#define YYUNDEFTOK 2 +#define YYMAXUTOK 669 + +#define YYTRANSLATE(YYX) \ + ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) + +/* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */ +static const yytype_uint16 yytranslate[] = +{ + 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 421, 2, 2, + 426, 427, 419, 417, 430, 418, 428, 420, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 431, 429, + 414, 413, 415, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 424, 2, 425, 422, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 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, 92, 93, 94, + 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, + 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, + 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, + 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, + 135, 136, 137, 138, 139, 140, 141, 142, 143, 144, + 145, 146, 147, 148, 149, 150, 151, 152, 153, 154, + 155, 156, 157, 158, 159, 160, 161, 162, 163, 164, + 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, + 175, 176, 177, 178, 179, 180, 181, 182, 183, 184, + 185, 186, 187, 188, 189, 190, 191, 192, 193, 194, + 195, 196, 197, 198, 199, 200, 201, 202, 203, 204, + 205, 206, 207, 208, 209, 210, 211, 212, 213, 214, + 215, 216, 217, 218, 219, 220, 221, 222, 223, 224, + 225, 226, 227, 228, 229, 230, 231, 232, 233, 234, + 235, 236, 237, 238, 239, 240, 241, 242, 243, 244, + 245, 246, 247, 248, 249, 250, 251, 252, 253, 254, + 255, 256, 257, 258, 259, 260, 261, 262, 263, 264, + 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, + 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, + 285, 286, 287, 288, 289, 290, 291, 292, 293, 294, + 295, 296, 297, 298, 299, 300, 301, 302, 303, 304, + 305, 306, 307, 308, 309, 310, 311, 312, 313, 314, + 315, 316, 317, 318, 319, 320, 321, 322, 323, 324, + 325, 326, 327, 328, 329, 330, 331, 332, 333, 334, + 335, 336, 337, 338, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 351, 352, 353, 354, + 355, 356, 357, 358, 359, 360, 361, 362, 363, 364, + 365, 366, 367, 368, 369, 370, 371, 372, 373, 374, + 375, 376, 377, 378, 379, 380, 381, 382, 383, 384, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 407, 408, 409, 410, 411, 412, 416, 423 +}; + +#if YYDEBUG +/* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in + YYRHS. */ +static const yytype_uint16 yyprhs[] = +{ + 0, 0, 3, 5, 9, 11, 13, 15, 17, 19, + 21, 23, 25, 27, 29, 31, 33, 35, 37, 39, + 41, 43, 45, 47, 49, 51, 53, 55, 57, 59, + 61, 63, 65, 67, 69, 71, 73, 75, 77, 79, + 81, 83, 85, 87, 89, 91, 93, 95, 97, 99, + 101, 103, 105, 107, 109, 111, 113, 115, 117, 119, + 121, 123, 125, 127, 129, 131, 133, 135, 137, 139, + 141, 143, 145, 147, 149, 151, 153, 155, 157, 159, + 161, 163, 165, 167, 169, 171, 173, 175, 177, 179, + 181, 183, 185, 187, 189, 191, 193, 195, 197, 199, + 201, 203, 205, 207, 209, 211, 213, 215, 217, 219, + 221, 223, 225, 227, 229, 231, 232, 238, 240, 241, + 244, 245, 248, 249, 252, 255, 259, 263, 265, 269, + 273, 276, 278, 280, 283, 286, 289, 293, 297, 303, + 309, 310, 314, 320, 326, 331, 335, 341, 345, 351, + 357, 364, 366, 368, 372, 378, 385, 390, 392, 393, + 396, 397, 399, 401, 403, 405, 407, 409, 412, 416, + 420, 423, 429, 431, 435, 439, 443, 447, 451, 455, + 458, 461, 464, 467, 471, 475, 479, 483, 485, 489, + 491, 495, 497, 499, 502, 505, 508, 510, 512, 514, + 516, 518, 520, 522, 526, 533, 535, 537, 539, 541, + 543, 544, 546, 548, 551, 555, 560, 564, 567, 570, + 572, 575, 577, 580, 584, 589, 593, 596, 601, 603, + 605, 607, 609, 611, 614, 617, 620, 623, 628, 635, + 640, 647, 652, 659, 664, 671, 673, 677, 680, 684, + 689, 696, 703, 710, 716, 722, 729, 736, 741, 750, + 755, 758, 762, 769, 774, 778, 782, 786, 790, 794, + 799, 804, 808, 812, 816, 820, 824, 828, 833, 838, + 842, 845, 849, 852, 855, 859, 863, 866, 869, 871, + 875, 878, 880, 882, 883, 886, 887, 890, 891, 895, + 898, 899, 901, 905, 909, 911, 917, 921, 926, 928, + 932, 937, 944, 949, 958, 961, 964, 975, 982, 984, + 986, 988, 990, 992, 994, 998, 1001, 1002, 1004, 1006, + 1010, 1014, 1016, 1018, 1022, 1026, 1030, 1034, 1039, 1042, + 1044, 1045, 1048, 1049, 1053, 1054, 1056, 1057, 1059, 1063, + 1066, 1068, 1070, 1072, 1076, 1077, 1079, 1083, 1085, 1097, + 1112, 1123, 1137, 1139, 1141, 1144, 1147, 1150, 1153, 1155, + 1156, 1158, 1159, 1163, 1164, 1166, 1170, 1172, 1176, 1178, + 1180, 1182, 1184, 1186, 1191, 1196, 1199, 1200, 1204, 1206, + 1208, 1211, 1214, 1216, 1220, 1225, 1231, 1234, 1240, 1242, + 1245, 1248, 1251, 1255, 1259, 1263, 1264, 1266, 1268, 1270, + 1272, 1274, 1276, 1280, 1282, 1288, 1296, 1300, 1309, 1314, + 1324, 1336, 1339, 1340, 1344, 1345, 1347, 1351, 1353, 1356, + 1359, 1362, 1363, 1365, 1369, 1373, 1380, 1385, 1386, 1388, + 1390, 1393, 1396, 1397, 1401, 1405, 1408, 1410, 1412, 1415, + 1418, 1423, 1424, 1427, 1430, 1433, 1434, 1438, 1443, 1448, + 1449, 1452, 1453, 1458, 1459, 1463, 1471, 1477, 1480, 1484, + 1485, 1491, 1496, 1503, 1505, 1506, 1508, 1511, 1514, 1516, + 1519, 1523, 1526, 1529, 1532, 1535, 1539, 1543, 1545, 1549, + 1551, 1552, 1554, 1557, 1559, 1561, 1565, 1572, 1583, 1585, + 1586, 1588, 1591, 1594, 1595, 1598, 1601, 1603, 1604, 1610, + 1618, 1620, 1621, 1628, 1631, 1632, 1636, 1642, 1648, 1657, + 1660, 1661, 1664, 1667, 1670, 1676, 1679, 1680, 1683, 1691, + 1702, 1709, 1716, 1723, 1730, 1738, 1746, 1756, 1766, 1773, + 1780, 1789, 1798, 1807, 1816, 1823, 1830, 1838, 1847, 1854, + 1861, 1869, 1872, 1875, 1878, 1881, 1883, 1886, 1888, 1889, + 1896, 1905, 1913, 1920, 1925, 1926, 1928, 1932, 1937, 1939, + 1943, 1945, 1948, 1951, 1954, 1957, 1959, 1961, 1972, 1975, + 1976, 1979, 1982, 1984, 1985, 1990, 1997, 2003, 2008, 2013, + 2022, 2034, 2038, 2041, 2043, 2047, 2049, 2055, 2063, 2072, + 2074, 2076, 2078, 2086, 2096, 2105, 2121, 2142, 2144, 2146, + 2149, 2151, 2155, 2157, 2159, 2161, 2165, 2167, 2171, 2172, + 2174, 2175, 2177, 2179, 2184, 2185, 2187, 2191, 2192, 2194, + 2196, 2198, 2200, 2203, 2204, 2205, 2208, 2211, 2213, 2216, + 2219, 2222, 2225, 2232, 2241, 2250, 2255, 2261, 2266, 2271, + 2276, 2280, 2288, 2297, 2304, 2311, 2318, 2325, 2332, 2337, + 2343, 2347, 2349, 2353, 2357, 2359, 2361, 2363, 2365, 2367, + 2369, 2373, 2377, 2381, 2383, 2387, 2391, 2393, 2394, 2396, + 2400, 2407, 2416, 2425, 2439, 2441, 2445, 2451, 2458, 2463, + 2471, 2474, 2476, 2477, 2480, 2481, 2484, 2489, 2490, 2492, + 2493, 2500, 2509, 2518, 2520, 2524, 2530, 2536, 2544, 2554, + 2562, 2572, 2578, 2585, 2592, 2597, 2603, 2611, 2613, 2615, + 2617, 2619, 2622, 2624, 2626, 2628, 2630, 2632, 2634, 2638, + 2642, 2646, 2650, 2652, 2656, 2658, 2661, 2664, 2668, 2674, + 2677, 2680, 2681, 2688, 2696, 2704, 2712, 2721, 2730, 2737, + 2746, 2756, 2766, 2774, 2785, 2793, 2802, 2811, 2820, 2829, + 2831, 2833, 2835, 2837, 2839, 2841, 2843, 2845, 2847, 2849, + 2851, 2853, 2855, 2857, 2860, 2862, 2866, 2868, 2870, 2879, + 2889, 2899, 2909, 2919, 2922, 2923, 2925, 2927, 2930, 2932, + 2934, 2936, 2938, 2940, 2942, 2944, 2946, 2948, 2950, 2953, + 2956, 2958, 2961, 2965, 2969, 2973, 2977, 2982, 2987, 2991, + 2995, 2999, 3004, 3009, 3013, 3018, 3023, 3025, 3027, 3029, + 3030, 3038, 3046, 3057, 3059, 3061, 3064, 3069, 3075, 3077, + 3081, 3084, 3087, 3090, 3093, 3095, 3098, 3101, 3106, 3110, + 3113, 3116, 3119, 3122, 3126, 3129, 3132, 3135, 3141, 3147, + 3153, 3155, 3159, 3161, 3164, 3168, 3169, 3171, 3175, 3178, + 3185, 3192, 3202, 3206, 3207, 3211, 3212, 3218, 3221, 3222, + 3226, 3230, 3234, 3242, 3250, 3261, 3263, 3265, 3267, 3269, + 3284, 3286, 3287, 3289, 3290, 3292, 3293, 3296, 3297, 3299, + 3303, 3309, 3315, 3323, 3326, 3327, 3329, 3332, 3333, 3335, + 3337, 3338, 3340, 3342, 3343, 3353, 3366, 3374, 3377, 3378, + 3382, 3385, 3387, 3391, 3395, 3398, 3400, 3404, 3408, 3412, + 3415, 3418, 3420, 3422, 3424, 3426, 3429, 3431, 3433, 3435, + 3437, 3442, 3448, 3450, 3454, 3458, 3460, 3463, 3468, 3474, + 3476, 3478, 3480, 3482, 3486, 3490, 3493, 3496, 3498, 3501, + 3504, 3507, 3509, 3512, 3515, 3517, 3519, 3521, 3525, 3528, + 3529, 3532, 3534, 3538, 3544, 3546, 3549, 3551, 3552, 3558, + 3566, 3572, 3580, 3586, 3594, 3598, 3604, 3610, 3616, 3618, + 3622, 3625, 3627, 3630, 3632, 3635, 3647, 3658, 3669, 3672, + 3675, 3676, 3686, 3689, 3690, 3695, 3700, 3705, 3707, 3709, + 3711, 3712, 3720, 3727, 3734, 3741, 3748, 3757, 3766, 3773, + 3780, 3788, 3798, 3808, 3815, 3822, 3829, 3838, 3845, 3854, + 3861, 3870, 3877, 3886, 3894, 3904, 3913, 3924, 3933, 3943, + 3955, 3964, 3971, 3978, 3985, 3991, 3997, 4006, 4015, 4024, + 4033, 4040, 4050, 4052, 4053, 4056, 4057, 4065, 4072, 4079, + 4086, 4093, 4100, 4108, 4118, 4128, 4135, 4144, 4153, 4162, + 4171, 4180, 4187, 4196, 4203, 4212, 4220, 4230, 4237, 4245, + 4252, 4259, 4266, 4273, 4280, 4288, 4296, 4304, 4314, 4324, + 4331, 4338, 4345, 4354, 4363, 4372, 4379, 4393, 4395, 4397, + 4401, 4405, 4407, 4409, 4411, 4413, 4415, 4417, 4419, 4420, + 4422, 4424, 4426, 4428, 4430, 4432, 4433, 4440, 4449, 4453, + 4456, 4457, 4460, 4463, 4466, 4469, 4473, 4477, 4480, 4483, + 4486, 4489, 4493, 4496, 4502, 4507, 4511, 4515, 4519, 4521, + 4523, 4524, 4528, 4531, 4534, 4536, 4539, 4541, 4545, 4548, + 4550, 4551, 4561, 4573, 4577, 4582, 4587, 4588, 4591, 4597, + 4600, 4601, 4605, 4609, 4613, 4617, 4621, 4625, 4629, 4633, + 4637, 4641, 4645, 4649, 4653, 4658, 4662, 4666, 4668, 4669, + 4675, 4682, 4687, 4690, 4691, 4696, 4700, 4706, 4713, 4718, + 4725, 4732, 4738, 4746, 4756, 4763, 4765, 4766, 4773, 4785, + 4797, 4809, 4823, 4833, 4845, 4856, 4861, 4864, 4870, 4873, + 4874, 4879, 4885, 4891, 4896, 4903, 4905, 4909, 4911, 4913, + 4915, 4917, 4920, 4925, 4927, 4929, 4931, 4932, 4934, 4935, + 4937, 4938, 4942, 4943, 4946, 4951, 4955, 4961, 4963, 4965, + 4967, 4969, 4971, 4973, 4975, 4977, 4981, 4984, 4986, 4988, + 4990, 4992, 4994, 4995, 5001, 5005, 5006, 5008, 5010, 5012, + 5014, 5018, 5028, 5032, 5033, 5036, 5040, 5043, 5047, 5054, + 5056, 5061, 5064, 5066, 5070, 5073, 5076, 5077, 5085, 5088, + 5089, 5095, 5099, 5100, 5103, 5106, 5109, 5113, 5115, 5119, + 5121, 5124, 5126, 5127, 5136, 5138, 5142, 5144, 5146, 5150, + 5156, 5159, 5161, 5165, 5173, 5175, 5176, 5180, 5183, 5186, + 5189, 5190, 5193, 5196, 5198, 5200, 5204, 5208, 5210, 5213, + 5218, 5223, 5226, 5230, 5236, 5242, 5244, 5246, 5256, 5258, + 5261, 5266, 5271, 5276, 5279, 5283, 5285, 5289, 5296, 5298, + 5299, 5302, 5303, 5307, 5311, 5316, 5321, 5326, 5331, 5335, + 5338, 5340, 5342, 5343, 5345, 5347, 5348, 5350, 5356, 5358, + 5359, 5361, 5362, 5366, 5368, 5372, 5377, 5381, 5384, 5387, + 5389, 5391, 5393, 5394, 5397, 5402, 5408, 5411, 5415, 5417, + 5419, 5421, 5423, 5427, 5428, 5430, 5432, 5434, 5436, 5438, + 5442, 5443, 5446, 5447, 5449, 5453, 5455, 5456, 5458, 5461, + 5466, 5471, 5474, 5475, 5478, 5482, 5485, 5486, 5488, 5492, + 5494, 5497, 5499, 5502, 5508, 5515, 5521, 5523, 5526, 5528, + 5533, 5537, 5542, 5548, 5553, 5559, 5564, 5570, 5573, 5578, + 5580, 5583, 5586, 5589, 5591, 5593, 5594, 5599, 5602, 5604, + 5607, 5610, 5615, 5617, 5621, 5623, 5626, 5630, 5632, 5635, + 5636, 5639, 5644, 5645, 5647, 5648, 5650, 5654, 5658, 5661, + 5665, 5671, 5678, 5681, 5685, 5689, 5694, 5695, 5697, 5699, + 5701, 5703, 5705, 5708, 5714, 5716, 5718, 5720, 5722, 5725, + 5729, 5733, 5734, 5736, 5738, 5740, 5742, 5744, 5747, 5750, + 5753, 5756, 5759, 5761, 5765, 5766, 5768, 5770, 5772, 5774, + 5780, 5783, 5785, 5787, 5789, 5791, 5797, 5800, 5803, 5806, + 5808, 5812, 5816, 5819, 5821, 5822, 5826, 5827, 5833, 5836, + 5842, 5845, 5847, 5850, 5854, 5855, 5857, 5859, 5861, 5863, + 5865, 5867, 5871, 5875, 5879, 5883, 5887, 5891, 5895, 5896, + 5898, 5903, 5905, 5909, 5913, 5919, 5922, 5925, 5929, 5933, + 5937, 5941, 5945, 5949, 5953, 5957, 5961, 5965, 5968, 5971, + 5975, 5979, 5982, 5986, 5992, 5997, 6004, 6008, 6014, 6019, + 6026, 6031, 6038, 6044, 6052, 6056, 6059, 6064, 6067, 6071, + 6075, 6080, 6084, 6089, 6093, 6098, 6104, 6111, 6118, 6126, + 6133, 6141, 6148, 6156, 6160, 6165, 6170, 6177, 6180, 6184, + 6189, 6191, 6195, 6198, 6201, 6205, 6209, 6213, 6217, 6221, + 6225, 6229, 6233, 6237, 6241, 6244, 6247, 6253, 6260, 6267, + 6275, 6279, 6284, 6286, 6288, 6291, 6296, 6298, 6300, 6302, + 6305, 6308, 6311, 6313, 6318, 6324, 6331, 6340, 6347, 6355, + 6363, 6369, 6375, 6377, 6379, 6384, 6386, 6391, 6393, 6398, + 6400, 6405, 6407, 6409, 6411, 6413, 6415, 6417, 6424, 6429, + 6434, 6439, 6444, 6451, 6457, 6463, 6469, 6474, 6481, 6486, + 6491, 6496, 6501, 6507, 6515, 6523, 6533, 6539, 6544, 6551, + 6557, 6565, 6573, 6581, 6584, 6588, 6592, 6596, 6601, 6602, + 6607, 6609, 6613, 6617, 6619, 6621, 6623, 6626, 6629, 6630, + 6633, 6638, 6643, 6650, 6653, 6654, 6656, 6660, 6664, 6667, + 6670, 6671, 6678, 6680, 6681, 6685, 6686, 6689, 6692, 6693, + 6695, 6700, 6703, 6706, 6709, 6712, 6715, 6720, 6724, 6730, + 6732, 6734, 6736, 6738, 6740, 6742, 6744, 6746, 6748, 6750, + 6752, 6754, 6756, 6758, 6760, 6765, 6767, 6772, 6774, 6779, + 6781, 6784, 6786, 6789, 6791, 6795, 6797, 6801, 6803, 6807, + 6809, 6813, 6817, 6821, 6824, 6826, 6830, 6834, 6835, 6837, + 6839, 6841, 6843, 6845, 6847, 6849, 6851, 6856, 6860, 6863, + 6867, 6868, 6872, 6876, 6879, 6882, 6884, 6885, 6888, 6891, + 6895, 6898, 6900, 6902, 6906, 6912, 6914, 6917, 6922, 6925, + 6926, 6928, 6929, 6931, 6934, 6937, 6940, 6944, 6950, 6952, + 6955, 6956, 6959, 6961, 6962, 6964, 6966, 6968, 6972, 6976, + 6978, 6982, 6986, 6989, 6991, 6993, 6995, 6999, 7001, 7004, + 7006, 7010, 7012, 7014, 7016, 7018, 7020, 7022, 7024, 7027, + 7029, 7031, 7033, 7035, 7037, 7040, 7046, 7049, 7053, 7060, + 7062, 7064, 7066, 7068, 7070, 7072, 7074, 7077, 7080, 7082, + 7084, 7086, 7088, 7090, 7092, 7094, 7096, 7098, 7100, 7102, + 7104, 7106, 7108, 7110, 7112, 7114, 7116, 7118, 7120, 7122, + 7124, 7126, 7128, 7130, 7132, 7134, 7136, 7138, 7140, 7142, + 7144, 7146, 7148, 7150, 7152, 7154, 7156, 7158, 7160, 7162, + 7164, 7166, 7168, 7170, 7172, 7174, 7176, 7178, 7180, 7182, + 7184, 7186, 7188, 7190, 7192, 7194, 7196, 7198, 7200, 7202, + 7204, 7206, 7208, 7210, 7212, 7214, 7216, 7218, 7220, 7222, + 7224, 7226, 7228, 7230, 7232, 7234, 7236, 7238, 7240, 7242, + 7244, 7246, 7248, 7250, 7252, 7254, 7256, 7258, 7260, 7262, + 7264, 7266, 7268, 7270, 7272, 7274, 7276, 7278, 7280, 7282, + 7284, 7286, 7288, 7290, 7292, 7294, 7296, 7298, 7300, 7302, + 7304, 7306, 7308, 7310, 7312, 7314, 7316, 7318, 7320, 7322, + 7324, 7326, 7328, 7330, 7332, 7334, 7336, 7338, 7340, 7342, + 7344, 7346, 7348, 7350, 7352, 7354, 7356, 7358, 7360, 7362, + 7364, 7366, 7368, 7370, 7372, 7374, 7376, 7378, 7380, 7382, + 7384, 7386, 7388, 7390, 7392, 7394, 7396, 7398, 7400, 7402, + 7404, 7406, 7408, 7410, 7412, 7414, 7416, 7418, 7420, 7422, + 7424, 7426, 7428, 7430, 7432, 7434, 7436, 7438, 7440, 7442, + 7444, 7446, 7448, 7450, 7452, 7454, 7456, 7458, 7460, 7462, + 7464, 7466, 7468, 7470, 7472, 7474, 7476, 7478, 7480, 7482, + 7484, 7486, 7488, 7490, 7492, 7494, 7496, 7498, 7500, 7502, + 7504, 7506, 7508, 7510, 7512, 7514, 7516, 7518, 7520, 7522, + 7524, 7526, 7528, 7530, 7532, 7534, 7536, 7538, 7540, 7542, + 7544, 7546, 7548, 7550, 7552, 7554, 7556, 7558, 7560, 7562, + 7564, 7566, 7568, 7570, 7572, 7574, 7576, 7578, 7580, 7582, + 7584, 7586, 7588, 7590, 7592, 7594, 7596, 7598, 7600, 7602, + 7604, 7606, 7608, 7610, 7612, 7614, 7616, 7618, 7620, 7622, + 7624, 7626, 7628, 7630, 7632, 7634, 7636, 7638, 7640, 7642, + 7644, 7646, 7648, 7650, 7652, 7654, 7656, 7658, 7660, 7662, + 7664, 7666, 7668, 7670, 7672, 7674, 7676, 7678, 7680, 7682, + 7684, 7686, 7688, 7690, 7692, 7694, 7696, 7698, 7700, 7702, + 7704, 7706, 7708, 7710, 7712, 7714, 7716, 7718, 7720, 7722, + 7724, 7726, 7728, 7730, 7732, 7734, 7736, 7738, 7740, 7742, + 7744, 7746, 7748, 7750, 7752, 7754, 7756, 7758, 7760, 7762, + 7764, 7766, 7768, 7770, 7772, 7774, 7776, 7778, 7780, 7782, + 7784, 7786, 7788, 7790, 7792, 7794, 7796, 7798, 7800, 7802, + 7804, 7806, 7808, 7810, 7812, 7814, 7816, 7818, 7820, 7822, + 7824, 7826, 7828, 7830, 7832, 7834, 7836, 7838, 7840, 7842, + 7844, 7846, 7848, 7850, 7852, 7854, 7856, 7858, 7860, 7862, + 7864, 7866, 7868, 7870, 7872, 7874, 7876, 7878, 7880, 7882, + 7884, 7886, 7888, 7890, 7892 +}; + +/* YYRHS -- A `-1'-separated list of the rules' RHS. */ +static const yytype_int16 yyrhs[] = +{ + 433, 0, -1, 434, -1, 434, 429, 435, -1, 435, + -1, 761, -1, 762, -1, 679, -1, 767, -1, 630, + -1, 570, -1, 573, -1, 579, -1, 593, -1, 598, + -1, 714, -1, 451, -1, 735, -1, 736, -1, 549, + -1, 478, -1, 489, -1, 445, -1, 443, -1, 770, + -1, 769, -1, 602, -1, 447, -1, 446, -1, 777, + -1, 476, -1, 492, -1, 772, -1, 653, -1, 473, + -1, 493, -1, 545, -1, 617, -1, 725, -1, 771, + -1, 766, -1, 567, -1, 574, -1, 588, -1, 594, + -1, 695, -1, 450, -1, 631, -1, 638, -1, 639, + -1, 556, -1, 454, -1, 548, -1, 508, -1, 564, + -1, 603, -1, 436, -1, 442, -1, 599, -1, 757, + -1, 794, -1, 813, -1, 619, -1, 800, -1, 477, + -1, 722, -1, 618, -1, 727, -1, 578, -1, 592, + -1, 453, -1, 642, -1, 643, -1, 644, -1, 562, + -1, 744, -1, 646, -1, 566, -1, 616, -1, 448, + -1, 449, -1, 601, -1, 765, -1, 792, -1, 783, + -1, 660, -1, 664, -1, 675, -1, 684, -1, 795, + -1, 747, -1, 756, -1, 802, -1, 745, -1, 789, + -1, 645, -1, 729, -1, 718, -1, 717, -1, 719, + -1, 732, -1, 665, -1, 676, -1, 737, -1, 656, + -1, 817, -1, 749, -1, 651, -1, 748, -1, 806, + -1, 774, -1, 469, -1, 458, -1, 472, -1, 754, + -1, -1, 83, 301, 967, 437, 438, -1, 392, -1, + -1, 438, 441, -1, -1, 439, 440, -1, -1, 264, + 966, -1, 264, 237, -1, 125, 264, 966, -1, 365, + 264, 966, -1, 175, -1, 75, 208, 968, -1, 376, + 371, 966, -1, 373, 956, -1, 3, -1, 440, -1, + 340, 965, -1, 19, 956, -1, 301, 956, -1, 170, + 301, 956, -1, 170, 158, 956, -1, 83, 373, 967, + 437, 438, -1, 24, 301, 967, 437, 439, -1, -1, + 170, 97, 958, -1, 24, 301, 967, 444, 470, -1, + 24, 373, 967, 437, 439, -1, 24, 373, 967, 470, + -1, 120, 301, 956, -1, 120, 301, 165, 134, 956, + -1, 120, 373, 956, -1, 120, 373, 165, 134, 956, + -1, 83, 158, 967, 437, 438, -1, 24, 158, 967, + 452, 373, 956, -1, 18, -1, 120, -1, 120, 158, + 956, -1, 120, 158, 165, 134, 956, -1, 83, 307, + 455, 38, 967, 456, -1, 83, 307, 969, 456, -1, + 969, -1, -1, 456, 457, -1, -1, 508, -1, 684, + -1, 548, -1, 603, -1, 664, -1, 754, -1, 319, + 459, -1, 319, 211, 459, -1, 319, 317, 459, -1, + 354, 752, -1, 317, 59, 31, 354, 752, -1, 460, + -1, 461, 352, 462, -1, 461, 413, 462, -1, 461, + 352, 103, -1, 461, 413, 103, -1, 461, 150, 86, + -1, 350, 409, 466, -1, 55, 966, -1, 307, 966, + -1, 225, 467, -1, 301, 468, -1, 317, 38, 468, + -1, 317, 38, 103, -1, 397, 249, 903, -1, 354, + 326, 966, -1, 969, -1, 461, 428, 969, -1, 463, + -1, 462, 430, 463, -1, 465, -1, 554, -1, 280, + 364, -1, 280, 72, -1, 291, 280, -1, 315, -1, + 358, -1, 139, -1, 246, -1, 468, -1, 966, -1, + 3, -1, 890, 966, 892, -1, 890, 426, 965, 427, + 966, 892, -1, 554, -1, 103, -1, 211, -1, 966, + -1, 103, -1, -1, 969, -1, 966, -1, 294, 461, + -1, 294, 350, 409, -1, 294, 354, 193, 206, -1, + 294, 317, 38, -1, 294, 22, -1, 319, 459, -1, + 469, -1, 319, 460, -1, 469, -1, 322, 461, -1, + 322, 350, 409, -1, 322, 354, 193, 206, -1, 322, + 317, 38, -1, 322, 22, -1, 319, 77, 474, 475, + -1, 22, -1, 954, -1, 106, -1, 167, -1, 61, + -1, 114, 22, -1, 114, 345, -1, 114, 347, -1, + 114, 266, -1, 24, 342, 861, 479, -1, 24, 342, + 165, 134, 861, 479, -1, 24, 173, 955, 479, -1, + 24, 173, 165, 134, 955, 479, -1, 24, 313, 955, + 479, -1, 24, 313, 165, 134, 955, 479, -1, 24, + 386, 955, 479, -1, 24, 386, 165, 134, 955, 479, + -1, 480, -1, 479, 430, 480, -1, 18, 516, -1, + 18, 68, 516, -1, 24, 733, 969, 481, -1, 24, + 733, 969, 120, 232, 237, -1, 24, 733, 969, 319, + 232, 237, -1, 24, 733, 969, 319, 332, 968, -1, + 24, 733, 969, 319, 485, -1, 24, 733, 969, 294, + 485, -1, 24, 733, 969, 319, 335, 969, -1, 120, + 733, 165, 134, 969, 482, -1, 120, 733, 969, 482, + -1, 24, 733, 969, 734, 361, 870, 483, 484, -1, + 24, 733, 969, 582, -1, 18, 525, -1, 377, 76, + 957, -1, 120, 76, 165, 134, 957, 482, -1, 120, + 76, 957, 482, -1, 319, 392, 245, -1, 319, 393, + 245, -1, 64, 246, 957, -1, 319, 393, 64, -1, + 123, 356, 957, -1, 123, 25, 356, 957, -1, 123, + 293, 356, 957, -1, 123, 356, 22, -1, 123, 356, + 373, -1, 113, 356, 957, -1, 113, 356, 22, -1, + 113, 356, 373, -1, 123, 305, 957, -1, 123, 25, + 305, 957, -1, 123, 293, 305, 957, -1, 113, 305, + 957, -1, 175, 955, -1, 230, 175, 955, -1, 242, + 649, -1, 232, 242, -1, 259, 352, 967, -1, 319, + 344, 957, -1, 319, 485, -1, 294, 485, -1, 582, + -1, 319, 103, 894, -1, 120, 103, -1, 51, -1, + 296, -1, -1, 66, 649, -1, -1, 374, 894, -1, + -1, 426, 487, 427, -1, 392, 485, -1, -1, 488, + -1, 487, 430, 488, -1, 971, 413, 623, -1, 971, + -1, 971, 428, 971, 413, 623, -1, 971, 428, 971, + -1, 24, 361, 649, 490, -1, 491, -1, 490, 430, + 491, -1, 18, 37, 869, 482, -1, 120, 37, 165, + 134, 969, 482, -1, 120, 37, 969, 482, -1, 24, + 37, 969, 734, 361, 870, 483, 482, -1, 63, 814, + -1, 63, 22, -1, 81, 499, 955, 528, 500, 494, + 495, 501, 437, 496, -1, 81, 818, 352, 495, 437, + 496, -1, 150, -1, 352, -1, 966, -1, 333, -1, + 334, -1, 497, -1, 426, 503, 427, -1, 497, 498, + -1, -1, 44, -1, 245, -1, 109, 768, 966, -1, + 237, 768, 966, -1, 85, -1, 161, -1, 278, 768, + 966, -1, 128, 768, 966, -1, 146, 278, 529, -1, + 146, 278, 419, -1, 146, 232, 237, 529, -1, 124, + 966, -1, 44, -1, -1, 392, 245, -1, -1, 502, + 110, 966, -1, -1, 374, -1, -1, 504, -1, 503, + 430, 504, -1, 971, 505, -1, 465, -1, 554, -1, + 419, -1, 426, 506, 427, -1, -1, 507, -1, 506, + 430, 507, -1, 465, -1, 83, 509, 342, 955, 426, + 510, 427, 539, 540, 541, 542, -1, 83, 509, 342, + 165, 232, 134, 955, 426, 510, 427, 539, 540, 541, + 542, -1, 83, 509, 342, 955, 242, 649, 511, 540, + 541, 542, -1, 83, 509, 342, 165, 232, 134, 955, + 242, 649, 511, 540, 541, 542, -1, 347, -1, 345, + -1, 211, 347, -1, 211, 345, -1, 154, 347, -1, + 154, 345, -1, 370, -1, -1, 512, -1, -1, 426, + 513, 427, -1, -1, 514, -1, 512, 430, 514, -1, + 515, -1, 513, 430, 515, -1, 516, -1, 522, -1, + 525, -1, 517, -1, 525, -1, 969, 870, 580, 518, + -1, 969, 392, 250, 518, -1, 518, 519, -1, -1, + 76, 957, 520, -1, 520, -1, 521, -1, 66, 649, + -1, 232, 237, -1, 237, -1, 367, 711, 543, -1, + 273, 195, 711, 543, -1, 60, 426, 894, 427, 527, + -1, 103, 895, -1, 286, 955, 528, 531, 535, -1, + 105, -1, 232, 105, -1, 177, 106, -1, 177, 167, + -1, 207, 955, 523, -1, 523, 171, 524, -1, 523, + 131, 524, -1, -1, 104, -1, 77, -1, 174, -1, + 335, -1, 70, -1, 22, -1, 76, 957, 526, -1, + 526, -1, 60, 426, 894, 427, 614, -1, 367, 426, + 529, 427, 711, 543, 614, -1, 367, 544, 614, -1, + 273, 195, 426, 529, 427, 711, 543, 614, -1, 273, + 195, 544, 614, -1, 130, 688, 426, 532, 427, 711, + 543, 534, 614, -1, 147, 195, 426, 529, 427, 286, + 955, 528, 531, 535, 614, -1, 230, 175, -1, -1, + 426, 529, 427, -1, -1, 530, -1, 529, 430, 530, + -1, 969, -1, 217, 151, -1, 217, 261, -1, 217, + 324, -1, -1, 533, -1, 532, 430, 533, -1, 690, + 392, 721, -1, 690, 392, 248, 426, 721, 427, -1, + 389, 426, 894, 427, -1, -1, 536, -1, 537, -1, + 536, 537, -1, 537, 536, -1, -1, 246, 372, 538, + -1, 246, 108, 538, -1, 230, 17, -1, 296, -1, + 51, -1, 319, 237, -1, 319, 103, -1, 176, 426, + 954, 427, -1, -1, 392, 485, -1, 392, 245, -1, + 393, 245, -1, -1, 246, 71, 120, -1, 246, 71, + 108, 304, -1, 246, 71, 270, 304, -1, -1, 344, + 957, -1, -1, 374, 173, 344, 957, -1, -1, 374, + 173, 961, -1, 83, 509, 342, 546, 31, 817, 547, + -1, 955, 528, 540, 541, 542, -1, 392, 96, -1, + 392, 230, 96, -1, -1, 83, 509, 313, 955, 550, + -1, 24, 313, 955, 551, -1, 24, 313, 165, 134, + 955, 551, -1, 551, -1, -1, 552, -1, 551, 552, + -1, 49, 554, -1, 95, -1, 230, 95, -1, 172, + 553, 554, -1, 218, 554, -1, 220, 554, -1, 230, + 218, -1, 230, 220, -1, 258, 48, 649, -1, 330, + 437, 554, -1, 295, -1, 295, 437, 554, -1, 48, + -1, -1, 4, -1, 418, 4, -1, 968, -1, 554, + -1, 555, 430, 554, -1, 83, 696, 557, 563, 197, + 468, -1, 83, 696, 557, 563, 197, 468, 159, 558, + 559, 561, -1, 360, -1, -1, 957, -1, 957, 650, + -1, 178, 558, -1, -1, 378, 558, -1, 230, 378, + -1, 560, -1, -1, 120, 563, 197, 468, 482, -1, + 120, 563, 197, 165, 134, 468, 482, -1, 276, -1, + -1, 83, 344, 957, 565, 214, 966, -1, 259, 957, + -1, -1, 120, 344, 957, -1, 120, 344, 165, 134, + 957, -1, 83, 136, 957, 437, 568, -1, 83, 136, + 165, 232, 134, 957, 437, 568, -1, 568, 569, -1, + -1, 307, 957, -1, 385, 468, -1, 150, 468, -1, + 24, 136, 957, 372, 571, -1, 571, 572, -1, -1, + 352, 468, -1, 24, 136, 957, 452, 21, 963, 624, + -1, 24, 136, 957, 452, 54, 426, 870, 31, 870, + 427, -1, 24, 136, 957, 452, 67, 649, -1, 24, + 136, 957, 452, 80, 649, -1, 24, 136, 957, 452, + 118, 649, -1, 24, 136, 957, 452, 152, 674, -1, + 24, 136, 957, 452, 563, 197, 957, -1, 24, 136, + 957, 452, 248, 721, 720, -1, 24, 136, 957, 452, + 248, 62, 649, 374, 959, -1, 24, 136, 957, 452, + 248, 140, 649, 374, 959, -1, 24, 136, 957, 452, + 307, 957, -1, 24, 136, 957, 452, 342, 649, -1, + 24, 136, 957, 452, 348, 309, 260, 649, -1, 24, + 136, 957, 452, 348, 309, 112, 649, -1, 24, 136, + 957, 452, 348, 309, 346, 649, -1, 24, 136, 957, + 452, 348, 309, 74, 649, -1, 24, 136, 957, 452, + 313, 649, -1, 24, 136, 957, 452, 386, 649, -1, + 24, 136, 957, 452, 147, 342, 649, -1, 24, 136, + 957, 452, 147, 96, 395, 957, -1, 24, 136, 957, + 452, 316, 957, -1, 24, 136, 957, 452, 361, 649, + -1, 83, 147, 96, 395, 957, 577, 580, -1, 159, + 558, -1, 230, 159, -1, 378, 558, -1, 230, 378, + -1, 575, -1, 576, 575, -1, 576, -1, -1, 120, + 147, 96, 395, 957, 482, -1, 120, 147, 96, 395, + 165, 134, 957, 482, -1, 24, 147, 96, 395, 957, + 577, 582, -1, 24, 147, 96, 395, 957, 576, -1, + 250, 426, 581, 427, -1, -1, 585, -1, 581, 430, + 585, -1, 250, 426, 583, 427, -1, 584, -1, 583, + 430, 584, -1, 585, -1, 319, 585, -1, 18, 585, + -1, 120, 586, -1, 586, 587, -1, 971, -1, 966, + -1, 83, 316, 957, 589, 591, 147, 96, 395, 957, + 580, -1, 361, 966, -1, -1, 385, 966, -1, 385, + 237, -1, 590, -1, -1, 120, 316, 957, 482, -1, + 120, 316, 165, 134, 957, 482, -1, 24, 316, 957, + 590, 582, -1, 24, 316, 957, 590, -1, 24, 316, + 957, 582, -1, 83, 147, 342, 955, 595, 316, 957, + 580, -1, 83, 147, 342, 165, 232, 134, 955, 595, + 316, 957, 580, -1, 426, 596, 427, -1, 426, 427, + -1, 597, -1, 596, 430, 597, -1, 516, -1, 24, + 147, 342, 861, 479, -1, 24, 147, 342, 165, 134, + 861, 479, -1, 83, 373, 216, 145, 600, 316, 957, + 580, -1, 93, -1, 373, -1, 967, -1, 120, 373, + 216, 145, 600, 316, 957, -1, 120, 373, 216, 165, + 134, 145, 600, 316, 957, -1, 24, 373, 216, 145, + 600, 316, 957, 582, -1, 83, 356, 957, 604, 605, + 246, 955, 607, 610, 133, 277, 963, 426, 611, 427, + -1, 83, 76, 356, 957, 20, 605, 246, 955, 613, + 614, 145, 121, 303, 610, 133, 277, 963, 426, 611, + 427, -1, 40, -1, 20, -1, 184, 242, -1, 606, + -1, 605, 251, 606, -1, 183, -1, 108, -1, 372, + -1, 372, 242, 529, -1, 359, -1, 145, 608, 609, + -1, -1, 121, -1, -1, 303, -1, 331, -1, 388, + 426, 894, 427, -1, -1, 612, -1, 611, 430, 612, + -1, -1, 965, -1, 4, -1, 966, -1, 971, -1, + 150, 955, -1, -1, -1, 614, 615, -1, 232, 105, + -1, 105, -1, 177, 167, -1, 177, 106, -1, 232, + 376, -1, 230, 175, -1, 120, 356, 957, 246, 649, + 482, -1, 120, 356, 165, 134, 957, 246, 649, 482, + -1, 83, 33, 957, 60, 426, 894, 427, 614, -1, + 120, 33, 957, 482, -1, 83, 21, 963, 624, 620, + -1, 83, 21, 963, 625, -1, 83, 248, 721, 620, + -1, 83, 361, 649, 620, -1, 83, 361, 649, -1, + 83, 361, 649, 31, 426, 867, 427, -1, 83, 361, + 649, 31, 127, 426, 628, 427, -1, 83, 361, 649, + 31, 279, 620, -1, 83, 348, 309, 260, 649, 620, + -1, 83, 348, 309, 112, 649, 620, -1, 83, 348, + 309, 346, 649, 620, -1, 83, 348, 309, 74, 649, + 620, -1, 83, 67, 649, 620, -1, 83, 67, 649, + 150, 649, -1, 426, 621, 427, -1, 622, -1, 621, + 430, 622, -1, 971, 413, 623, -1, 971, -1, 705, + -1, 975, -1, 921, -1, 554, -1, 966, -1, 426, + 926, 427, -1, 426, 419, 427, -1, 426, 626, 427, + -1, 627, -1, 626, 430, 627, -1, 3, 413, 623, + -1, 629, -1, -1, 966, -1, 629, 430, 966, -1, + 24, 361, 649, 18, 379, 966, -1, 24, 361, 649, + 18, 379, 966, 40, 966, -1, 24, 361, 649, 18, + 379, 966, 20, 966, -1, 83, 248, 62, 649, 634, + 145, 361, 870, 374, 959, 635, 31, 632, -1, 633, + -1, 632, 430, 633, -1, 248, 965, 721, 636, 637, + -1, 248, 965, 721, 720, 636, 637, -1, 152, 965, + 963, 697, -1, 152, 965, 426, 926, 427, 963, 697, + -1, 335, 870, -1, 103, -1, -1, 140, 649, -1, + -1, 145, 309, -1, 145, 252, 48, 649, -1, -1, + 283, -1, -1, 83, 248, 140, 649, 374, 959, -1, + 24, 248, 140, 649, 374, 959, 18, 632, -1, 24, + 248, 140, 649, 374, 959, 120, 640, -1, 641, -1, + 640, 430, 641, -1, 248, 965, 426, 926, 427, -1, + 152, 965, 426, 926, 427, -1, 120, 248, 62, 649, + 374, 959, 482, -1, 120, 248, 62, 165, 134, 649, + 374, 959, 482, -1, 120, 248, 140, 649, 374, 959, + 482, -1, 120, 248, 140, 165, 134, 649, 374, 959, + 482, -1, 120, 258, 48, 956, 482, -1, 282, 258, + 48, 956, 352, 957, -1, 120, 647, 165, 134, 648, + 482, -1, 120, 647, 648, 482, -1, 120, 173, 73, + 648, 482, -1, 120, 173, 73, 165, 134, 648, 482, + -1, 342, -1, 313, -1, 386, -1, 173, -1, 147, + 342, -1, 361, -1, 118, -1, 67, -1, 80, -1, + 307, -1, 136, -1, 348, 309, 260, -1, 348, 309, + 112, -1, 348, 309, 346, -1, 348, 309, 74, -1, + 649, -1, 648, 430, 649, -1, 969, -1, 969, 650, + -1, 428, 960, -1, 650, 428, 960, -1, 359, 828, + 862, 652, 482, -1, 79, 164, -1, 295, 164, -1, + -1, 69, 246, 654, 649, 191, 655, -1, 69, 246, + 21, 963, 624, 191, 655, -1, 69, 246, 152, 963, + 697, 191, 655, -1, 69, 246, 248, 721, 720, 191, + 655, -1, 69, 246, 76, 957, 246, 649, 191, 655, + -1, 69, 246, 305, 957, 246, 649, 191, 655, -1, + 69, 246, 305, 957, 191, 655, -1, 69, 246, 356, + 957, 246, 649, 191, 655, -1, 69, 246, 248, 62, + 649, 374, 959, 191, 655, -1, 69, 246, 248, 140, + 649, 374, 959, 191, 655, -1, 69, 246, 198, 241, + 554, 191, 655, -1, 69, 246, 54, 426, 870, 31, + 870, 427, 191, 655, -1, 69, 246, 563, 197, 649, + 191, 655, -1, 69, 246, 348, 309, 260, 649, 191, + 655, -1, 69, 246, 348, 309, 112, 649, 191, 655, + -1, 69, 246, 348, 309, 346, 649, 191, 655, -1, + 69, 246, 348, 309, 74, 649, 191, 655, -1, 68, + -1, 97, -1, 307, -1, 173, -1, 313, -1, 342, + -1, 118, -1, 361, -1, 386, -1, 67, -1, 80, + -1, 344, -1, 136, -1, 301, -1, 147, 342, -1, + 316, -1, 147, 96, 395, -1, 966, -1, 237, -1, + 311, 196, 657, 246, 658, 649, 191, 659, -1, 311, + 196, 657, 246, 21, 963, 624, 191, 659, -1, 311, + 196, 657, 246, 152, 963, 697, 191, 659, -1, 311, + 196, 657, 246, 198, 241, 554, 191, 659, -1, 311, + 196, 657, 246, 563, 197, 649, 191, 659, -1, 145, + 468, -1, -1, 68, -1, 97, -1, 147, 342, -1, + 307, -1, 313, -1, 342, -1, 118, -1, 301, -1, + 344, -1, 361, -1, 386, -1, 966, -1, 237, -1, + 141, 661, -1, 223, 661, -1, 814, -1, 662, 814, + -1, 229, 663, 814, -1, 274, 663, 814, -1, 142, + 663, 814, -1, 199, 663, 814, -1, 15, 968, 663, + 814, -1, 288, 968, 663, 814, -1, 968, 663, 814, + -1, 22, 663, 814, -1, 148, 663, 814, -1, 148, + 968, 663, 814, -1, 148, 22, 663, 814, -1, 39, + 663, 814, -1, 39, 968, 663, 814, -1, 39, 22, + 663, 814, -1, 150, -1, 170, -1, 662, -1, -1, + 155, 666, 246, 669, 352, 670, 672, -1, 299, 666, + 246, 669, 150, 670, 482, -1, 299, 155, 249, 145, + 666, 246, 669, 150, 670, 482, -1, 667, -1, 22, + -1, 22, 275, -1, 22, 426, 529, 427, -1, 22, + 275, 426, 529, 427, -1, 668, -1, 667, 430, 668, + -1, 312, 528, -1, 286, 528, -1, 83, 528, -1, + 969, 528, -1, 954, -1, 342, 954, -1, 313, 954, + -1, 147, 96, 395, 956, -1, 147, 316, 956, -1, + 152, 673, -1, 97, 956, -1, 118, 648, -1, 197, + 956, -1, 198, 241, 555, -1, 307, 956, -1, 344, + 956, -1, 361, 648, -1, 22, 343, 170, 307, 956, + -1, 22, 314, 170, 307, 956, -1, 22, 153, 170, + 307, 956, -1, 671, -1, 670, 430, 671, -1, 967, + -1, 158, 967, -1, 392, 155, 249, -1, -1, 674, + -1, 673, 430, 674, -1, 963, 697, -1, 155, 667, + 352, 956, 677, 678, -1, 299, 667, 150, 956, 678, + 482, -1, 299, 19, 249, 145, 667, 150, 956, 678, + 482, -1, 392, 19, 249, -1, -1, 156, 48, 967, + -1, -1, 24, 103, 275, 680, 682, -1, 680, 681, + -1, -1, 170, 307, 956, -1, 145, 301, 956, -1, + 145, 373, 956, -1, 155, 666, 246, 683, 352, 670, + 672, -1, 299, 666, 246, 683, 150, 670, 482, -1, + 299, 155, 249, 145, 666, 246, 683, 150, 670, 482, + -1, 343, -1, 153, -1, 314, -1, 362, -1, 83, + 685, 173, 686, 687, 246, 955, 688, 426, 689, 427, + 486, 542, 865, -1, 367, -1, -1, 73, -1, -1, + 961, -1, -1, 374, 959, -1, -1, 690, -1, 689, + 430, 690, -1, 969, 691, 692, 693, 694, -1, 897, + 691, 692, 693, 694, -1, 426, 894, 427, 691, 692, + 693, 694, -1, 66, 649, -1, -1, 649, -1, 374, + 649, -1, -1, 32, -1, 111, -1, -1, 410, -1, + 411, -1, -1, 83, 696, 152, 963, 699, 298, 704, + 707, 711, -1, 83, 696, 152, 963, 699, 298, 342, + 426, 713, 427, 707, 711, -1, 83, 696, 152, 963, + 699, 707, 711, -1, 251, 292, -1, -1, 426, 698, + 427, -1, 426, 427, -1, 701, -1, 698, 430, 701, + -1, 426, 700, 427, -1, 426, 427, -1, 706, -1, + 700, 430, 706, -1, 702, 703, 705, -1, 703, 702, + 705, -1, 703, 705, -1, 702, 705, -1, 705, -1, + 170, -1, 253, -1, 180, -1, 170, 253, -1, 382, + -1, 970, -1, 705, -1, 870, -1, 970, 650, 421, + 361, -1, 320, 970, 650, 421, 361, -1, 701, -1, + 701, 103, 894, -1, 701, 413, 894, -1, 709, -1, + 707, 709, -1, 50, 246, 237, 181, -1, 298, 237, + 246, 237, 181, -1, 336, -1, 168, -1, 328, -1, + 387, -1, 137, 311, 107, -1, 137, 311, 190, -1, + 311, 107, -1, 311, 190, -1, 203, -1, 232, 203, + -1, 82, 554, -1, 304, 554, -1, 471, -1, 31, + 710, -1, 197, 468, -1, 391, -1, 708, -1, 966, + -1, 966, 430, 966, -1, 392, 620, -1, -1, 703, + 705, -1, 712, -1, 713, 430, 712, -1, 24, 152, + 674, 715, 716, -1, 708, -1, 715, 708, -1, 296, + -1, -1, 120, 152, 963, 697, 482, -1, 120, 152, + 165, 134, 963, 697, 482, -1, 120, 21, 963, 624, + 482, -1, 120, 21, 165, 134, 963, 624, 482, -1, + 120, 248, 721, 720, 482, -1, 120, 248, 165, 134, + 721, 720, 482, -1, 426, 870, 427, -1, 426, 870, + 430, 870, 427, -1, 426, 231, 430, 870, 427, -1, + 426, 870, 430, 231, 427, -1, 918, -1, 969, 428, + 721, -1, 116, 723, -1, 724, -1, 723, 724, -1, + 966, -1, 197, 468, -1, 83, 54, 426, 870, 31, + 870, 427, 392, 152, 674, 726, -1, 83, 54, 426, + 870, 31, 870, 427, 393, 152, 726, -1, 83, 54, + 426, 870, 31, 870, 427, 392, 180, 726, -1, 31, + 169, -1, 31, 34, -1, -1, 120, 54, 728, 426, + 870, 31, 870, 427, 482, -1, 165, 134, -1, -1, + 287, 730, 955, 731, -1, 287, 341, 957, 731, -1, + 287, 97, 957, 731, -1, 173, -1, 342, -1, 146, + -1, -1, 24, 21, 963, 624, 290, 352, 957, -1, + 24, 67, 649, 290, 352, 957, -1, 24, 80, 649, + 290, 352, 957, -1, 24, 97, 958, 290, 352, 958, + -1, 24, 118, 649, 290, 352, 957, -1, 24, 118, + 649, 290, 76, 957, 352, 957, -1, 24, 147, 96, + 395, 957, 290, 352, 957, -1, 24, 152, 674, 290, + 352, 957, -1, 24, 158, 967, 290, 352, 967, -1, + 24, 563, 197, 957, 290, 352, 957, -1, 24, 248, + 62, 649, 374, 959, 290, 352, 957, -1, 24, 248, + 140, 649, 374, 959, 290, 352, 957, -1, 24, 307, + 957, 290, 352, 957, -1, 24, 316, 957, 290, 352, + 957, -1, 24, 342, 861, 290, 352, 957, -1, 24, + 342, 165, 134, 861, 290, 352, 957, -1, 24, 313, + 955, 290, 352, 957, -1, 24, 313, 165, 134, 955, + 290, 352, 957, -1, 24, 386, 955, 290, 352, 957, + -1, 24, 386, 165, 134, 955, 290, 352, 957, -1, + 24, 173, 955, 290, 352, 957, -1, 24, 173, 165, + 134, 955, 290, 352, 957, -1, 24, 147, 342, 861, + 290, 352, 957, -1, 24, 147, 342, 165, 134, 861, + 290, 352, 957, -1, 24, 342, 861, 290, 733, 957, + 352, 957, -1, 24, 342, 165, 134, 861, 290, 733, + 957, 352, 957, -1, 24, 342, 861, 290, 76, 957, + 352, 957, -1, 24, 147, 342, 861, 290, 733, 957, + 352, 957, -1, 24, 147, 342, 165, 134, 861, 290, + 733, 957, 352, 957, -1, 24, 356, 957, 246, 955, + 290, 352, 957, -1, 24, 301, 967, 290, 352, 967, + -1, 24, 373, 967, 290, 352, 967, -1, 24, 344, + 957, 290, 352, 957, -1, 24, 344, 957, 319, 485, + -1, 24, 344, 957, 294, 485, -1, 24, 348, 309, + 260, 649, 290, 352, 957, -1, 24, 348, 309, 112, + 649, 290, 352, 957, -1, 24, 348, 309, 346, 649, + 290, 352, 957, -1, 24, 348, 309, 74, 649, 290, + 352, 957, -1, 24, 361, 649, 290, 352, 957, -1, + 24, 361, 649, 290, 37, 957, 352, 957, 482, -1, + 68, -1, -1, 319, 96, -1, -1, 24, 21, 963, + 624, 319, 307, 957, -1, 24, 67, 649, 319, 307, + 957, -1, 24, 80, 649, 319, 307, 957, -1, 24, + 118, 649, 319, 307, 957, -1, 24, 136, 649, 319, + 307, 957, -1, 24, 152, 674, 319, 307, 957, -1, + 24, 248, 721, 720, 319, 307, 957, -1, 24, 248, + 62, 649, 374, 959, 319, 307, 957, -1, 24, 248, + 140, 649, 374, 959, 319, 307, 957, -1, 24, 342, + 861, 319, 307, 957, -1, 24, 342, 165, 134, 861, + 319, 307, 957, -1, 24, 348, 309, 260, 649, 319, + 307, 957, -1, 24, 348, 309, 112, 649, 319, 307, + 957, -1, 24, 348, 309, 346, 649, 319, 307, 957, + -1, 24, 348, 309, 74, 649, 319, 307, 957, -1, + 24, 313, 955, 319, 307, 957, -1, 24, 313, 165, + 134, 955, 319, 307, 957, -1, 24, 386, 955, 319, + 307, 957, -1, 24, 386, 165, 134, 955, 319, 307, + 957, -1, 24, 147, 342, 861, 319, 307, 957, -1, + 24, 147, 342, 165, 134, 861, 319, 307, 957, -1, + 24, 361, 649, 319, 307, 957, -1, 24, 21, 963, + 624, 259, 352, 967, -1, 24, 67, 649, 259, 352, + 967, -1, 24, 80, 649, 259, 352, 967, -1, 24, + 97, 958, 259, 352, 967, -1, 24, 118, 649, 259, + 352, 967, -1, 24, 152, 674, 259, 352, 967, -1, + 24, 563, 197, 957, 259, 352, 967, -1, 24, 198, + 241, 554, 259, 352, 967, -1, 24, 248, 721, 720, + 259, 352, 967, -1, 24, 248, 62, 649, 374, 959, + 259, 352, 967, -1, 24, 248, 140, 649, 374, 959, + 259, 352, 967, -1, 24, 307, 957, 259, 352, 967, + -1, 24, 361, 649, 259, 352, 967, -1, 24, 344, + 957, 259, 352, 967, -1, 24, 348, 309, 112, 649, + 259, 352, 967, -1, 24, 348, 309, 74, 649, 259, + 352, 967, -1, 24, 147, 96, 395, 957, 259, 352, + 967, -1, 24, 316, 957, 259, 352, 967, -1, 83, + 696, 305, 957, 31, 246, 742, 352, 955, 865, 116, + 743, 738, -1, 233, -1, 740, -1, 426, 739, 427, + -1, 739, 429, 741, -1, 741, -1, 817, -1, 795, + -1, 806, -1, 800, -1, 745, -1, 740, -1, -1, + 312, -1, 372, -1, 108, -1, 183, -1, 184, -1, + 23, -1, -1, 120, 305, 957, 246, 649, 482, -1, + 120, 305, 165, 134, 957, 246, 649, 482, -1, 234, + 969, 746, -1, 430, 966, -1, -1, 209, 969, -1, + 369, 969, -1, 369, 419, -1, 14, 750, -1, 41, + 750, 753, -1, 330, 354, 753, -1, 71, 750, -1, + 126, 750, -1, 302, 750, -1, 306, 969, -1, 289, + 306, 969, -1, 289, 969, -1, 302, 750, 352, 306, + 969, -1, 302, 750, 352, 969, -1, 271, 354, 966, + -1, 71, 272, 966, -1, 302, 272, 966, -1, 394, + -1, 354, -1, -1, 193, 206, 464, -1, 280, 247, + -1, 280, 396, -1, 105, -1, 232, 105, -1, 751, + -1, 752, 430, 751, -1, 752, 751, -1, 752, -1, + -1, 83, 509, 386, 955, 528, 486, 31, 817, 755, + -1, 83, 251, 292, 509, 386, 955, 528, 486, 31, + 817, 755, -1, 392, 60, 249, -1, 392, 52, 60, + 249, -1, 392, 211, 60, 249, -1, -1, 210, 962, + -1, 83, 97, 958, 437, 758, -1, 758, 759, -1, + -1, 344, 760, 957, -1, 344, 760, 103, -1, 214, + 760, 966, -1, 214, 760, 103, -1, 346, 760, 957, + -1, 346, 760, 103, -1, 124, 760, 966, -1, 124, + 760, 965, -1, 124, 760, 103, -1, 200, 760, 966, + -1, 200, 760, 103, -1, 201, 760, 966, -1, 201, + 760, 103, -1, 75, 208, 760, 968, -1, 259, 760, + 957, -1, 259, 760, 103, -1, 413, -1, -1, 24, + 97, 958, 437, 763, -1, 24, 97, 958, 319, 344, + 957, -1, 24, 97, 958, 470, -1, 763, 764, -1, + -1, 75, 208, 760, 968, -1, 120, 97, 958, -1, + 120, 97, 165, 134, 958, -1, 83, 118, 649, 768, + 870, 518, -1, 24, 118, 649, 481, -1, 24, 118, + 649, 120, 232, 237, -1, 24, 118, 649, 319, 232, + 237, -1, 24, 118, 649, 18, 525, -1, 24, 118, + 649, 120, 76, 957, 482, -1, 24, 118, 649, 120, + 76, 165, 134, 957, 482, -1, 24, 118, 649, 377, + 76, 957, -1, 31, -1, -1, 24, 348, 309, 112, + 649, 620, -1, 24, 348, 309, 74, 649, 18, 216, + 145, 956, 392, 648, -1, 24, 348, 309, 74, 649, + 24, 216, 145, 956, 392, 648, -1, 24, 348, 309, + 74, 649, 24, 216, 292, 649, 392, 649, -1, 24, + 348, 309, 74, 649, 24, 216, 145, 956, 292, 649, + 392, 649, -1, 24, 348, 309, 74, 649, 120, 216, + 145, 956, -1, 24, 348, 309, 74, 649, 120, 216, + 165, 134, 145, 956, -1, 83, 634, 80, 649, 145, + 966, 352, 966, 150, 649, -1, 64, 779, 955, 773, + -1, 64, 779, -1, 64, 779, 961, 246, 955, -1, + 374, 961, -1, -1, 375, 780, 781, 779, -1, 375, + 780, 781, 779, 955, -1, 375, 780, 781, 779, 777, + -1, 375, 426, 775, 427, -1, 375, 426, 775, 427, + 955, 782, -1, 776, -1, 775, 430, 776, -1, 778, + -1, 384, -1, 149, -1, 151, -1, 778, 779, -1, + 778, 779, 955, 782, -1, 27, -1, 26, -1, 384, + -1, -1, 151, -1, -1, 149, -1, -1, 426, 956, + 427, -1, -1, 135, 784, -1, 135, 778, 779, 784, + -1, 135, 384, 784, -1, 135, 426, 785, 427, 784, + -1, 817, -1, 795, -1, 806, -1, 800, -1, 813, + -1, 545, -1, 792, -1, 786, -1, 785, 430, 786, + -1, 787, 788, -1, 969, -1, 778, -1, 384, -1, + 465, -1, 554, -1, -1, 271, 957, 790, 31, 791, + -1, 426, 926, 427, -1, -1, 817, -1, 795, -1, + 806, -1, 800, -1, 133, 957, 793, -1, 83, 509, + 342, 546, 31, 133, 957, 793, 547, -1, 426, 923, + 427, -1, -1, 99, 957, -1, 99, 271, 957, -1, + 99, 22, -1, 99, 271, 22, -1, 825, 183, 189, + 955, 796, 799, -1, 817, -1, 426, 797, 427, 817, + -1, 103, 380, -1, 798, -1, 797, 430, 798, -1, + 969, 947, -1, 297, 952, -1, -1, 825, 108, 150, + 863, 801, 866, 799, -1, 374, 854, -1, -1, 215, + 828, 862, 803, 805, -1, 170, 804, 221, -1, -1, + 16, 321, -1, 303, 321, -1, 303, 132, -1, 321, + 372, 132, -1, 321, -1, 321, 303, 132, -1, 132, + -1, 16, 132, -1, 236, -1, -1, 825, 372, 863, + 319, 807, 853, 866, 799, -1, 808, -1, 807, 430, + 808, -1, 809, -1, 810, -1, 811, 413, 949, -1, + 426, 812, 427, 413, 951, -1, 969, 947, -1, 811, + -1, 812, 430, 811, -1, 102, 814, 815, 94, 816, + 145, 817, -1, 957, -1, -1, 815, 230, 308, -1, + 815, 308, -1, 815, 44, -1, 815, 182, -1, -1, + 392, 162, -1, 393, 162, -1, 819, -1, 818, -1, + 426, 819, 427, -1, 426, 818, 427, -1, 821, -1, + 820, 832, -1, 820, 831, 847, 836, -1, 820, 831, + 835, 848, -1, 822, 820, -1, 822, 820, 832, -1, + 822, 820, 831, 847, 836, -1, 822, 820, 831, 835, + 848, -1, 821, -1, 818, -1, 312, 830, 952, 826, + 853, 865, 845, 846, 906, -1, 852, -1, 342, 861, + -1, 820, 366, 829, 820, -1, 820, 187, 829, 820, + -1, 820, 129, 829, 820, -1, 392, 823, -1, 392, + 284, 823, -1, 824, -1, 823, 430, 824, -1, 957, + 782, 31, 426, 791, 427, -1, 822, -1, -1, 189, + 827, -1, -1, 347, 828, 955, -1, 345, 828, 955, + -1, 211, 347, 828, 955, -1, 211, 345, 828, 955, + -1, 154, 347, 828, 955, -1, 154, 345, 828, 955, + -1, 370, 828, 955, -1, 342, 955, -1, 955, -1, + 342, -1, -1, 22, -1, 115, -1, -1, 115, -1, + 115, 246, 426, 923, 427, -1, 22, -1, -1, 832, + -1, -1, 252, 48, 833, -1, 834, -1, 833, 430, + 834, -1, 894, 374, 921, 694, -1, 894, 693, 694, + -1, 837, 838, -1, 838, 837, -1, 837, -1, 838, + -1, 835, -1, -1, 208, 839, -1, 208, 839, 430, + 840, -1, 141, 844, 841, 843, 247, -1, 244, 840, + -1, 244, 842, 843, -1, 894, -1, 22, -1, 894, + -1, 968, -1, 426, 894, 427, -1, -1, 896, -1, + 303, -1, 304, -1, 142, -1, 229, -1, 158, 48, + 923, -1, -1, 160, 894, -1, -1, 849, -1, 145, + 280, 247, -1, 847, -1, -1, 850, -1, 849, 850, + -1, 145, 372, 851, 805, -1, 145, 321, 851, 805, + -1, 242, 954, -1, -1, 380, 951, -1, 852, 430, + 951, -1, 150, 854, -1, -1, 855, -1, 854, 430, + 855, -1, 861, -1, 861, 857, -1, 864, -1, 864, + 857, -1, 864, 31, 426, 868, 427, -1, 864, 31, + 969, 426, 868, 427, -1, 864, 969, 426, 868, 427, + -1, 818, -1, 818, 857, -1, 856, -1, 426, 856, + 427, 857, -1, 426, 856, 427, -1, 855, 84, 194, + 855, -1, 855, 858, 194, 855, 860, -1, 855, 194, + 855, 860, -1, 855, 227, 858, 194, 855, -1, 855, + 227, 194, 855, -1, 31, 969, 426, 956, 427, -1, + 31, 969, -1, 969, 426, 956, 427, -1, 969, -1, + 151, 859, -1, 205, 859, -1, 300, 859, -1, 179, + -1, 254, -1, -1, 374, 426, 956, 427, -1, 246, + 894, -1, 955, -1, 955, 419, -1, 247, 955, -1, + 247, 426, 955, 427, -1, 861, -1, 862, 430, 861, + -1, 861, -1, 861, 969, -1, 861, 31, 969, -1, + 897, -1, 389, 894, -1, -1, 389, 894, -1, 389, + 86, 242, 814, -1, -1, 868, -1, -1, 869, -1, + 868, 430, 869, -1, 969, 870, 483, -1, 872, 871, + -1, 320, 872, 871, -1, 872, 30, 424, 965, 425, + -1, 320, 872, 30, 424, 965, 425, -1, 872, 30, + -1, 320, 872, 30, -1, 871, 424, 425, -1, 871, + 424, 965, 425, -1, -1, 874, -1, 876, -1, 878, + -1, 882, -1, 889, -1, 890, 892, -1, 890, 426, + 965, 427, 892, -1, 876, -1, 879, -1, 883, -1, + 889, -1, 970, 875, -1, 970, 650, 875, -1, 426, + 923, 427, -1, -1, 185, -1, 186, -1, 325, -1, + 43, -1, 281, -1, 143, 877, -1, 119, 269, -1, + 101, 875, -1, 100, 875, -1, 240, 875, -1, 46, + -1, 426, 965, 427, -1, -1, 880, -1, 881, -1, + 880, -1, 881, -1, 45, 887, 426, 923, 427, -1, + 45, 887, -1, 884, -1, 885, -1, 884, -1, 885, + -1, 886, 426, 965, 427, 888, -1, 886, 888, -1, + 58, 887, -1, 57, 887, -1, 381, -1, 226, 58, + 887, -1, 226, 57, 887, -1, 228, 887, -1, 383, + -1, -1, 58, 319, 969, -1, -1, 351, 426, 965, + 427, 891, -1, 351, 891, -1, 350, 426, 965, 427, + 891, -1, 350, 891, -1, 188, -1, 412, 409, -1, + 393, 350, 409, -1, -1, 407, -1, 222, -1, 98, + -1, 163, -1, 219, -1, 893, -1, 407, 352, 222, + -1, 98, 352, 163, -1, 98, 352, 219, -1, 98, + 352, 893, -1, 163, 352, 219, -1, 163, 352, 893, + -1, 219, 352, 893, -1, -1, 310, -1, 310, 426, + 965, 427, -1, 896, -1, 894, 11, 870, -1, 894, + 66, 649, -1, 894, 36, 350, 409, 894, -1, 417, + 894, -1, 418, 894, -1, 894, 417, 894, -1, 894, + 418, 894, -1, 894, 419, 894, -1, 894, 420, 894, + -1, 894, 421, 894, -1, 894, 422, 894, -1, 894, + 414, 894, -1, 894, 415, 894, -1, 894, 413, 894, + -1, 894, 920, 894, -1, 920, 894, -1, 894, 920, + -1, 894, 28, 894, -1, 894, 251, 894, -1, 232, + 894, -1, 894, 207, 894, -1, 894, 207, 894, 128, + 894, -1, 894, 232, 207, 894, -1, 894, 232, 207, + 894, 128, 894, -1, 894, 166, 894, -1, 894, 166, + 894, 128, 894, -1, 894, 232, 166, 894, -1, 894, + 232, 166, 894, 128, 894, -1, 894, 323, 352, 894, + -1, 894, 323, 352, 894, 128, 894, -1, 894, 232, + 323, 352, 894, -1, 894, 232, 323, 352, 894, 128, + 894, -1, 894, 191, 237, -1, 894, 192, -1, 894, + 191, 232, 237, -1, 894, 235, -1, 916, 256, 916, + -1, 894, 191, 358, -1, 894, 191, 232, 358, -1, + 894, 191, 139, -1, 894, 191, 232, 139, -1, 894, + 191, 368, -1, 894, 191, 232, 368, -1, 894, 191, + 115, 150, 894, -1, 894, 191, 232, 115, 150, 894, + -1, 894, 191, 242, 426, 926, 427, -1, 894, 191, + 232, 242, 426, 926, 427, -1, 894, 42, 948, 895, + 28, 895, -1, 894, 232, 42, 948, 895, 28, 895, + -1, 894, 42, 339, 895, 28, 895, -1, 894, 232, + 42, 339, 895, 28, 895, -1, 894, 170, 938, -1, + 894, 232, 170, 938, -1, 894, 922, 917, 818, -1, + 894, 922, 917, 426, 894, 427, -1, 367, 818, -1, + 894, 191, 117, -1, 894, 191, 232, 117, -1, 896, + -1, 895, 11, 870, -1, 417, 895, -1, 418, 895, + -1, 895, 417, 895, -1, 895, 418, 895, -1, 895, + 419, 895, -1, 895, 420, 895, -1, 895, 421, 895, + -1, 895, 422, 895, -1, 895, 414, 895, -1, 895, + 415, 895, -1, 895, 413, 895, -1, 895, 920, 895, + -1, 920, 895, -1, 895, 920, -1, 895, 191, 115, + 150, 895, -1, 895, 191, 232, 115, 150, 895, -1, + 895, 191, 242, 426, 926, 427, -1, 895, 191, 232, + 242, 426, 926, 427, -1, 895, 191, 117, -1, 895, + 191, 232, 117, -1, 944, -1, 964, -1, 10, 947, + -1, 426, 894, 427, 947, -1, 939, -1, 897, -1, + 818, -1, 134, 818, -1, 30, 818, -1, 30, 927, + -1, 916, -1, 963, 426, 427, 909, -1, 963, 426, + 924, 427, 909, -1, 963, 426, 382, 925, 427, 909, + -1, 963, 426, 924, 430, 382, 925, 427, 909, -1, + 963, 426, 924, 832, 427, 909, -1, 963, 426, 22, + 924, 831, 427, 909, -1, 963, 426, 115, 924, 831, + 427, 909, -1, 963, 426, 419, 427, 909, -1, 67, + 145, 426, 894, 427, -1, 88, -1, 91, -1, 91, + 426, 965, 427, -1, 92, -1, 92, 426, 965, 427, + -1, 212, -1, 212, 426, 965, 427, -1, 213, -1, + 213, 426, 965, 427, -1, 89, -1, 93, -1, 318, + -1, 373, -1, 87, -1, 90, -1, 54, 426, 894, + 31, 870, 427, -1, 138, 426, 929, 427, -1, 257, + 426, 931, 427, -1, 267, 426, 933, 427, -1, 338, + 426, 934, 427, -1, 355, 426, 894, 31, 870, 427, + -1, 357, 426, 47, 937, 427, -1, 357, 426, 202, + 937, 427, -1, 357, 426, 353, 937, 427, -1, 357, + 426, 937, 427, -1, 238, 426, 894, 430, 894, 427, + -1, 65, 426, 923, 427, -1, 157, 426, 923, 427, + -1, 204, 426, 923, 427, -1, 399, 426, 923, 427, + -1, 400, 426, 224, 971, 427, -1, 400, 426, 224, + 971, 430, 900, 427, -1, 400, 426, 224, 971, 430, + 923, 427, -1, 400, 426, 224, 971, 430, 900, 430, + 923, 427, -1, 401, 426, 896, 905, 427, -1, 402, + 426, 901, 427, -1, 403, 426, 903, 894, 904, 427, + -1, 404, 426, 224, 971, 427, -1, 404, 426, 224, + 971, 430, 894, 427, -1, 405, 426, 894, 430, 898, + 899, 427, -1, 406, 426, 903, 894, 31, 872, 427, + -1, 385, 894, -1, 385, 230, 379, -1, 430, 329, + 408, -1, 430, 329, 230, -1, 430, 329, 230, 379, + -1, -1, 398, 426, 901, 427, -1, 902, -1, 901, + 430, 902, -1, 894, 31, 971, -1, 894, -1, 117, + -1, 78, -1, 270, 390, -1, 337, 390, -1, -1, + 263, 896, -1, 263, 896, 48, 285, -1, 263, 48, + 285, 896, -1, 263, 48, 285, 896, 48, 285, -1, + 391, 907, -1, -1, 908, -1, 907, 430, 908, -1, + 969, 31, 910, -1, 255, 910, -1, 255, 969, -1, + -1, 426, 911, 912, 831, 913, 427, -1, 969, -1, + -1, 262, 48, 923, -1, -1, 279, 914, -1, 304, + 914, -1, -1, 915, -1, 42, 915, 28, 915, -1, + 363, 268, -1, 363, 144, -1, 86, 303, -1, 894, + 268, -1, 894, 144, -1, 303, 426, 923, 427, -1, + 303, 426, 427, -1, 426, 923, 430, 894, 427, -1, + 29, -1, 327, -1, 22, -1, 8, -1, 919, -1, + 417, -1, 418, -1, 419, -1, 420, -1, 421, -1, + 422, -1, 414, -1, 415, -1, 413, -1, 8, -1, + 248, 426, 721, 427, -1, 918, -1, 248, 426, 721, + 427, -1, 918, -1, 248, 426, 721, 427, -1, 207, + -1, 232, 207, -1, 166, -1, 232, 166, -1, 894, + -1, 923, 430, 894, -1, 925, -1, 924, 430, 925, + -1, 894, -1, 703, 13, 894, -1, 870, -1, 926, + 430, 870, -1, 424, 923, 425, -1, 424, 928, 425, + -1, 424, 425, -1, 927, -1, 928, 430, 927, -1, + 930, 150, 894, -1, -1, 3, -1, 407, -1, 222, + -1, 98, -1, 163, -1, 219, -1, 310, -1, 966, + -1, 894, 932, 935, 936, -1, 894, 932, 935, -1, + 265, 894, -1, 895, 170, 895, -1, -1, 894, 935, + 936, -1, 894, 936, 935, -1, 894, 935, -1, 894, + 936, -1, 923, -1, -1, 150, 894, -1, 145, 894, + -1, 894, 150, 923, -1, 150, 923, -1, 923, -1, + 818, -1, 426, 923, 427, -1, 53, 943, 940, 942, + 126, -1, 941, -1, 940, 941, -1, 388, 894, 349, + 894, -1, 122, 894, -1, -1, 894, -1, -1, 969, + -1, 969, 946, -1, 428, 960, -1, 428, 419, -1, + 424, 894, 425, -1, 424, 894, 431, 894, 425, -1, + 945, -1, 946, 945, -1, -1, 947, 945, -1, 35, + -1, -1, 894, -1, 103, -1, 949, -1, 950, 430, + 949, -1, 426, 950, 427, -1, 953, -1, 952, 430, + 953, -1, 894, 31, 971, -1, 894, 3, -1, 894, + -1, 419, -1, 955, -1, 954, 430, 955, -1, 969, + -1, 969, 946, -1, 957, -1, 956, 430, 957, -1, + 969, -1, 969, -1, 969, -1, 971, -1, 969, -1, + 966, -1, 970, -1, 969, 946, -1, 965, -1, 4, + -1, 966, -1, 6, -1, 7, -1, 963, 966, -1, + 963, 426, 924, 427, 966, -1, 873, 966, -1, 890, + 966, 892, -1, 890, 426, 965, 427, 966, 892, -1, + 358, -1, 139, -1, 237, -1, 9, -1, 5, -1, + 969, -1, 965, -1, 417, 965, -1, 418, 965, -1, + 3, -1, 972, -1, 973, -1, 3, -1, 972, -1, + 974, -1, 3, -1, 972, -1, 973, -1, 974, -1, + 975, -1, 14, -1, 15, -1, 16, -1, 17, -1, + 18, -1, 19, -1, 20, -1, 21, -1, 23, -1, + 24, -1, 25, -1, 33, -1, 34, -1, 36, -1, + 37, -1, 39, -1, 40, -1, 41, -1, 48, -1, + 49, -1, 50, -1, 51, -1, 52, -1, 55, -1, + 56, -1, 59, -1, 61, -1, 62, -1, 63, -1, + 64, -1, 69, -1, 70, -1, 71, -1, 72, -1, + 74, -1, 75, -1, 77, -1, 78, -1, 79, -1, + 80, -1, 81, -1, 82, -1, 85, -1, 86, -1, + 94, -1, 95, -1, 96, -1, 97, -1, 98, -1, + 99, -1, 102, -1, 104, -1, 106, -1, 107, -1, + 108, -1, 109, -1, 110, -1, 112, -1, 113, -1, + 114, -1, 117, -1, 118, -1, 119, -1, 120, -1, + 121, -1, 123, -1, 124, -1, 125, -1, 127, -1, + 128, -1, 130, -1, 131, -1, 132, -1, 133, -1, + 135, -1, 136, -1, 137, -1, 140, -1, 142, -1, + 144, -1, 146, -1, 148, -1, 152, -1, 153, -1, + 154, -1, 156, -1, 159, -1, 161, -1, 162, -1, + 163, -1, 164, -1, 165, -1, 167, -1, 168, -1, + 169, -1, 171, -1, 172, -1, 173, -1, 174, -1, + 175, -1, 176, -1, 178, -1, 181, -1, 182, -1, + 183, -1, 184, -1, 190, -1, 193, -1, 195, -1, + 196, -1, 197, -1, 198, -1, 199, -1, 200, -1, + 201, -1, 203, -1, 206, -1, 209, -1, 210, -1, + 211, -1, 214, -1, 215, -1, 216, -1, 217, -1, + 218, -1, 219, -1, 220, -1, 221, -1, 222, -1, + 223, -1, 224, -1, 225, -1, 229, -1, 230, -1, + 233, -1, 234, -1, 236, -1, 239, -1, 241, -1, + 242, -1, 243, -1, 245, -1, 248, -1, 249, -1, + 250, -1, 258, -1, 259, -1, 260, -1, 261, -1, + 262, -1, 263, -1, 264, -1, 266, -1, 268, -1, + 271, -1, 272, -1, 270, -1, 274, -1, 275, -1, + 276, -1, 277, -1, 278, -1, 279, -1, 280, -1, + 282, -1, 283, -1, 284, -1, 285, -1, 287, -1, + 288, -1, 289, -1, 290, -1, 291, -1, 292, -1, + 293, -1, 294, -1, 295, -1, 296, -1, 298, -1, + 299, -1, 301, -1, 302, -1, 304, -1, 305, -1, + 306, -1, 307, -1, 308, -1, 309, -1, 310, -1, + 311, -1, 313, -1, 314, -1, 315, -1, 316, -1, + 317, -1, 319, -1, 321, -1, 322, -1, 324, -1, + 326, -1, 328, -1, 329, -1, 330, -1, 331, -1, + 332, -1, 333, -1, 334, -1, 335, -1, 336, -1, + 337, -1, 340, -1, 341, -1, 343, -1, 344, -1, + 345, -1, 346, -1, 347, -1, 348, -1, 354, -1, + 356, -1, 359, -1, 360, -1, 361, -1, 362, -1, + 363, -1, 364, -1, 365, -1, 368, -1, 369, -1, + 370, -1, 371, -1, 372, -1, 375, -1, 376, -1, + 377, -1, 378, -1, 379, -1, 383, -1, 385, -1, + 386, -1, 387, -1, 390, -1, 393, -1, 394, -1, + 395, -1, 396, -1, 397, -1, 407, -1, 408, -1, + 409, -1, 42, -1, 43, -1, 45, -1, 46, -1, + 57, -1, 58, -1, 65, -1, 100, -1, 101, -1, + 134, -1, 138, -1, 143, -1, 157, -1, 180, -1, + 185, -1, 186, -1, 188, -1, 204, -1, 226, -1, + 228, -1, 231, -1, 238, -1, 240, -1, 253, -1, + 257, -1, 267, -1, 269, -1, 281, -1, 303, -1, + 320, -1, 325, -1, 338, -1, 350, -1, 351, -1, + 355, -1, 357, -1, 380, -1, 381, -1, 398, -1, + 399, -1, 400, -1, 401, -1, 402, -1, 403, -1, + 404, -1, 405, -1, 406, -1, 38, -1, 44, -1, + 67, -1, 73, -1, 84, -1, 90, -1, 149, -1, + 151, -1, 166, -1, 179, -1, 191, -1, 192, -1, + 194, -1, 205, -1, 207, -1, 227, -1, 235, -1, + 254, -1, 255, -1, 256, -1, 300, -1, 323, -1, + 384, -1, 22, -1, 26, -1, 27, -1, 28, -1, + 29, -1, 30, -1, 31, -1, 32, -1, 35, -1, + 47, -1, 53, -1, 54, -1, 60, -1, 66, -1, + 68, -1, 76, -1, 83, -1, 87, -1, 88, -1, + 89, -1, 91, -1, 92, -1, 93, -1, 103, -1, + 105, -1, 111, -1, 115, -1, 116, -1, 122, -1, + 126, -1, 129, -1, 139, -1, 141, -1, 145, -1, + 147, -1, 150, -1, 155, -1, 158, -1, 160, -1, + 170, -1, 177, -1, 187, -1, 189, -1, 202, -1, + 208, -1, 212, -1, 213, -1, 232, -1, 237, -1, + 244, -1, 246, -1, 247, -1, 251, -1, 252, -1, + 265, -1, 273, -1, 286, -1, 297, -1, 312, -1, + 318, -1, 327, -1, 339, -1, 342, -1, 349, -1, + 352, -1, 353, -1, 358, -1, 366, -1, 367, -1, + 373, -1, 374, -1, 382, -1, 388, -1, 389, -1, + 391, -1, 392, -1 +}; + +/* YYRLINE[YYN] -- source line where rule number YYN was defined. */ +static const yytype_uint16 yyrline[] = +{ + 0, 654, 654, 661, 668, 678, 679, 680, 681, 682, + 683, 684, 685, 686, 687, 688, 689, 690, 691, 692, + 693, 694, 695, 696, 697, 698, 699, 700, 701, 702, + 703, 704, 705, 706, 707, 708, 709, 710, 711, 712, + 713, 714, 715, 716, 717, 718, 719, 720, 721, 722, + 723, 724, 725, 726, 727, 728, 729, 730, 731, 732, + 733, 734, 735, 736, 737, 738, 739, 740, 741, 742, + 743, 744, 745, 746, 747, 748, 749, 750, 751, 752, + 753, 754, 755, 756, 757, 758, 759, 760, 761, 762, + 763, 764, 765, 766, 767, 768, 769, 770, 771, 772, + 773, 774, 775, 776, 777, 778, 779, 780, 781, 782, + 783, 784, 785, 786, 787, 789, 799, 810, 811, 820, + 821, 825, 826, 830, 835, 839, 844, 849, 853, 857, + 862, 866, 920, 922, 926, 930, 934, 938, 952, 970, + 981, 982, 986, 1004, 1016, 1037, 1044, 1063, 1070, 1087, + 1105, 1116, 1117, 1129, 1136, 1153, 1165, 1177, 1178, 1182, + 1183, 1191, 1192, 1193, 1194, 1195, 1196, 1210, 1216, 1222, + 1231, 1239, 1247, 1251, 1259, 1267, 1274, 1281, 1289, 1300, + 1308, 1316, 1327, 1335, 1343, 1350, 1359, 1369, 1370, 1377, + 1378, 1381, 1383, 1387, 1388, 1389, 1390, 1394, 1395, 1396, + 1402, 1414, 1418, 1422, 1437, 1460, 1461, 1462, 1466, 1467, + 1468, 1472, 1473, 1477, 1484, 1491, 1498, 1505, 1515, 1516, + 1521, 1522, 1527, 1533, 1539, 1545, 1551, 1561, 1571, 1572, + 1576, 1577, 1585, 1600, 1606, 1612, 1618, 1636, 1645, 1654, + 1663, 1672, 1681, 1690, 1699, 1711, 1712, 1717, 1725, 1733, + 1742, 1750, 1758, 1767, 1776, 1785, 1794, 1804, 1817, 1831, + 1840, 1848, 1856, 1866, 1876, 1883, 1890, 1898, 1906, 1914, + 1922, 1930, 1937, 1944, 1952, 1959, 1966, 1974, 1982, 1990, + 1998, 2006, 2014, 2024, 2031, 2039, 2047, 2055, 2062, 2072, + 2073, 2077, 2078, 2079, 2083, 2091, 2095, 2096, 2100, 2103, + 2104, 2108, 2109, 2114, 2118, 2122, 2127, 2142, 2155, 2156, + 2161, 2170, 2180, 2190, 2215, 2221, 2248, 2270, 2284, 2285, + 2294, 2295, 2296, 2299, 2300, 2305, 2306, 2310, 2314, 2318, + 2322, 2326, 2330, 2334, 2338, 2342, 2346, 2350, 2354, 2363, + 2367, 2371, 2375, 2379, 2383, 2387, 2388, 2393, 2397, 2404, + 2411, 2412, 2413, 2414, 2415, 2419, 2423, 2431, 2442, 2457, + 2473, 2489, 2518, 2519, 2520, 2521, 2522, 2529, 2536, 2537, + 2541, 2542, 2546, 2547, 2551, 2555, 2562, 2566, 2573, 2574, + 2575, 2579, 2580, 2583, 2603, 2623, 2624, 2628, 2636, 2637, + 2638, 2669, 2676, 2683, 2694, 2705, 2715, 2724, 2757, 2764, + 2771, 2778, 2789, 2799, 2800, 2801, 2805, 2806, 2807, 2808, + 2809, 2810, 2819, 2827, 2831, 2844, 2859, 2873, 2888, 2902, + 2920, 2941, 2942, 2946, 2947, 2951, 2952, 2955, 2961, 2965, + 2973, 2978, 2984, 2985, 2989, 2994, 3001, 3002, 3012, 3014, + 3016, 3018, 3021, 3024, 3027, 3031, 3032, 3033, 3034, 3035, + 3038, 3039, 3044, 3045, 3046, 3047, 3050, 3051, 3052, 3053, + 3056, 3057, 3060, 3061, 3064, 3079, 3093, 3106, 3107, 3108, + 3121, 3133, 3141, 3152, 3153, 3156, 3157, 3160, 3164, 3168, + 3172, 3176, 3180, 3184, 3188, 3192, 3196, 3200, 3204, 3210, + 3211, 3215, 3216, 3221, 3224, 3225, 3237, 3249, 3264, 3265, + 3273, 3274, 3278, 3279, 3283, 3284, 3288, 3289, 3293, 3304, + 3317, 3318, 3328, 3338, 3339, 3352, 3359, 3376, 3384, 3395, + 3398, 3402, 3406, 3410, 3422, 3432, 3435, 3439, 3452, 3462, + 3472, 3481, 3490, 3499, 3509, 3518, 3528, 3538, 3548, 3557, + 3566, 3575, 3584, 3593, 3602, 3611, 3620, 3629, 3638, 3647, + 3665, 3676, 3677, 3678, 3679, 3683, 3684, 3688, 3689, 3699, + 3710, 3730, 3738, 3750, 3751, 3755, 3759, 3767, 3771, 3775, + 3782, 3786, 3791, 3796, 3803, 3810, 3815, 3825, 3839, 3840, + 3845, 3846, 3850, 3851, 3861, 3872, 3892, 3901, 3909, 3926, + 3941, 3959, 3960, 3964, 3968, 3975, 3986, 3995, 4013, 4025, + 4026, 4027, 4037, 4045, 4062, 4081, 4101, 4126, 4127, 4128, + 4132, 4134, 4156, 4158, 4160, 4162, 4164, 4169, 4174, 4184, + 4185, 4189, 4190, 4194, 4195, 4199, 4200, 4201, 4205, 4211, + 4212, 4213, 4217, 4218, 4223, 4224, 4251, 4252, 4253, 4254, + 4255, 4256, 4261, 4272, 4295, 4315, 4338, 4348, 4359, 4369, + 4379, 4390, 4399, 4406, 4413, 4422, 4431, 4440, 4449, 4458, + 4469, 4472, 4473, 4476, 4480, 4487, 4488, 4489, 4490, 4491, + 4494, 4495, 4498, 4501, 4502, 4510, 4517, 4518, 4521, 4523, + 4534, 4543, 4552, 4576, 4591, 4592, 4596, 4606, 4617, 4626, + 4636, 4645, 4646, 4649, 4650, 4653, 4654, 4655, 4658, 4672, + 4677, 4687, 4696, 4708, 4709, 4713, 4721, 4733, 4744, 4758, + 4769, 4792, 4802, 4820, 4831, 4842, 4853, 4867, 4868, 4869, + 4870, 4871, 4872, 4873, 4874, 4875, 4876, 4877, 4878, 4879, + 4880, 4881, 4885, 4886, 4889, 4890, 4893, 4895, 4908, 4919, + 4920, 4921, 4947, 4956, 4965, 4974, 4983, 4992, 5001, 5011, + 5020, 5029, 5038, 5047, 5056, 5065, 5073, 5081, 5089, 5100, + 5101, 5102, 5103, 5104, 5105, 5106, 5107, 5108, 5109, 5110, + 5111, 5112, 5113, 5114, 5115, 5116, 5120, 5121, 5135, 5146, + 5157, 5168, 5179, 5192, 5193, 5197, 5198, 5199, 5200, 5201, + 5202, 5203, 5204, 5205, 5206, 5207, 5210, 5211, 5221, 5227, + 5235, 5243, 5251, 5259, 5267, 5275, 5283, 5291, 5299, 5307, + 5315, 5323, 5331, 5339, 5347, 5355, 5365, 5366, 5369, 5370, + 5380, 5396, 5410, 5436, 5438, 5440, 5442, 5449, 5458, 5459, + 5462, 5469, 5476, 5483, 5497, 5505, 5513, 5521, 5529, 5537, + 5545, 5553, 5561, 5569, 5577, 5585, 5593, 5601, 5609, 5617, + 5629, 5630, 5633, 5643, 5657, 5658, 5662, 5663, 5668, 5684, + 5697, 5707, 5719, 5720, 5723, 5724, 5734, 5744, 5745, 5749, + 5753, 5757, 5768, 5781, 5795, 5812, 5813, 5814, 5815, 5827, + 5854, 5855, 5859, 5860, 5864, 5865, 5869, 5870, 5873, 5874, + 5882, 5893, 5904, 5917, 5918, 5921, 5922, 5923, 5926, 5927, + 5928, 5931, 5932, 5933, 5949, 5961, 5974, 5989, 5990, 5993, + 5994, 5998, 5999, 6007, 6008, 6012, 6013, 6028, 6037, 6046, + 6055, 6064, 6076, 6077, 6078, 6079, 6080, 6086, 6090, 6105, + 6106, 6112, 6122, 6126, 6131, 6141, 6142, 6149, 6153, 6157, + 6161, 6165, 6169, 6173, 6177, 6181, 6185, 6189, 6193, 6197, + 6201, 6205, 6213, 6217, 6221, 6225, 6231, 6232, 6239, 6240, + 6243, 6255, 6259, 6274, 6285, 6286, 6291, 6292, 6307, 6318, + 6332, 6343, 6357, 6368, 6382, 6390, 6392, 6394, 6399, 6401, + 6414, 6423, 6424, 6428, 6432, 6444, 6455, 6466, 6479, 6480, + 6481, 6485, 6498, 6499, 6513, 6521, 6531, 6544, 6545, 6548, + 6549, 6559, 6569, 6578, 6587, 6596, 6605, 6615, 6624, 6634, + 6643, 6652, 6662, 6672, 6681, 6690, 6700, 6710, 6720, 6730, + 6740, 6750, 6760, 6770, 6780, 6790, 6801, 6812, 6822, 6833, + 6844, 6854, 6863, 6872, 6881, 6890, 6899, 6908, 6917, 6926, + 6935, 6944, 6958, 6959, 6962, 6963, 6973, 6983, 6992, 7001, + 7010, 7019, 7029, 7039, 7049, 7059, 7068, 7077, 7086, 7095, + 7104, 7113, 7122, 7131, 7140, 7149, 7158, 7167, 7184, 7193, + 7201, 7209, 7217, 7225, 7234, 7242, 7250, 7259, 7268, 7277, + 7285, 7293, 7301, 7309, 7317, 7325, 7342, 7359, 7360, 7361, + 7366, 7372, 7381, 7382, 7383, 7384, 7385, 7389, 7390, 7393, + 7394, 7395, 7396, 7400, 7401, 7402, 7407, 7418, 7440, 7450, + 7451, 7454, 7463, 7469, 7488, 7495, 7502, 7509, 7516, 7523, + 7530, 7538, 7546, 7554, 7562, 7570, 7577, 7584, 7593, 7594, + 7595, 7599, 7602, 7605, 7608, 7611, 7618, 7620, 7622, 7627, + 7629, 7641, 7653, 7668, 7674, 7680, 7686, 7696, 7712, 7722, + 7723, 7727, 7731, 7735, 7739, 7743, 7747, 7751, 7755, 7759, + 7763, 7767, 7771, 7775, 7779, 7783, 7787, 7797, 7798, 7809, + 7816, 7827, 7838, 7839, 7843, 7857, 7864, 7881, 7894, 7903, + 7911, 7919, 7928, 7939, 7950, 7960, 7961, 7972, 7982, 7992, + 8002, 8012, 8022, 8030, 8051, 8074, 8082, 8091, 8102, 8103, + 8115, 8129, 8143, 8155, 8167, 8184, 8185, 8189, 8190, 8191, + 8192, 8196, 8208, 8223, 8224, 8228, 8229, 8232, 8233, 8236, + 8237, 8241, 8242, 8255, 8262, 8272, 8279, 8289, 8290, 8291, + 8292, 8293, 8294, 8295, 8299, 8303, 8310, 8317, 8318, 8319, + 8323, 8324, 8325, 8335, 8345, 8346, 8350, 8351, 8352, 8353, + 8363, 8370, 8387, 8388, 8398, 8404, 8410, 8416, 8432, 8442, + 8448, 8454, 8463, 8465, 8470, 8481, 8482, 8493, 8507, 8508, + 8519, 8530, 8531, 8534, 8535, 8536, 8537, 8538, 8539, 8540, + 8541, 8544, 8545, 8556, 8574, 8575, 8579, 8580, 8584, 8592, + 8620, 8631, 8632, 8642, 8653, 8656, 8657, 8658, 8659, 8660, + 8663, 8664, 8665, 8713, 8714, 8718, 8719, 8733, 8734, 8741, + 8749, 8757, 8765, 8773, 8781, 8792, 8793, 8820, 8835, 8836, + 8855, 8859, 8863, 8878, 8885, 8895, 8896, 8899, 8911, 8912, + 8916, 8927, 8935, 8940, 8945, 8950, 8955, 8963, 8971, 8976, + 8981, 8988, 8989, 8992, 8993, 8994, 9001, 9002, 9003, 9004, + 9008, 9009, 9013, 9017, 9018, 9021, 9030, 9043, 9044, 9045, + 9046, 9050, 9051, 9055, 9057, 9067, 9072, 9075, 9080, 9081, + 9089, 9099, 9100, 9101, 9109, 9113, 9114, 9117, 9118, 9123, + 9124, 9128, 9129, 9133, 9134, 9138, 9139, 9143, 9144, 9148, + 9156, 9167, 9168, 9173, 9179, 9197, 9198, 9202, 9203, 9213, + 9217, 9222, 9229, 9237, 9244, 9254, 9264, 9292, 9299, 9303, + 9329, 9333, 9345, 9358, 9372, 9383, 9398, 9404, 9409, 9415, + 9422, 9423, 9424, 9425, 9429, 9430, 9442, 9443, 9448, 9455, + 9462, 9469, 9480, 9481, 9494, 9498, 9505, 9515, 9520, 9521, + 9526, 9527, 9535, 9540, 9541, 9545, 9549, 9555, 9584, 9589, + 9596, 9601, 9607, 9612, 9621, 9623, 9626, 9630, 9631, 9632, + 9633, 9634, 9635, 9640, 9670, 9671, 9672, 9673, 9684, 9690, + 9698, 9699, 9705, 9710, 9715, 9720, 9725, 9730, 9735, 9740, + 9746, 9752, 9758, 9765, 9787, 9796, 9800, 9808, 9812, 9820, + 9832, 9853, 9857, 9863, 9867, 9880, 9899, 9922, 9924, 9926, + 9928, 9930, 9932, 9937, 9938, 9942, 9943, 9950, 9959, 9967, + 9976, 9987, 9995, 9996, 9997, 10001, 10003, 10005, 10007, 10009, + 10011, 10013, 10018, 10023, 10029, 10037, 10042, 10049, 10056, 10060, + 10064, 10094, 10095, 10097, 10105, 10127, 10129, 10131, 10133, 10135, + 10137, 10139, 10141, 10143, 10145, 10147, 10150, 10152, 10154, 10157, + 10159, 10161, 10164, 10166, 10179, 10181, 10194, 10196, 10209, 10211, + 10225, 10238, 10251, 10264, 10287, 10294, 10301, 10308, 10315, 10319, + 10326, 10333, 10340, 10347, 10354, 10361, 10365, 10373, 10377, 10387, + 10394, 10401, 10414, 10427, 10446, 10467, 10477, 10484, 10500, 10505, + 10523, 10525, 10527, 10529, 10531, 10533, 10535, 10537, 10539, 10541, + 10543, 10545, 10547, 10549, 10551, 10553, 10555, 10559, 10564, 10568, + 10572, 10577, 10594, 10595, 10596, 10611, 10623, 10625, 10627, 10637, + 10647, 10657, 10665, 10684, 10697, 10710, 10723, 10736, 10749, 10766, + 10779, 10802, 10815, 10836, 10846, 10859, 10876, 10889, 10899, 10912, + 10922, 10935, 10948, 10961, 10974, 10987, 11000, 11013, 11015, 11028, + 11046, 11060, 11076, 11098, 11114, 11127, 11140, 11153, 11157, 11164, + 11172, 11180, 11184, 11188, 11192, 11196, 11200, 11215, 11219, 11228, + 11232, 11236, 11241, 11255, 11257, 11261, 11263, 11265, 11268, 11271, + 11274, 11275, 11278, 11286, 11296, 11297, 11300, 11301, 11302, 11307, + 11311, 11315, 11319, 11330, 11331, 11335, 11336, 11341, 11349, 11351, + 11365, 11368, 11395, 11396, 11399, 11400, 11411, 11429, 11436, 11445, + 11462, 11507, 11515, 11523, 11531, 11539, 11560, 11561, 11562, 11565, + 11566, 11567, 11570, 11571, 11574, 11575, 11576, 11577, 11578, 11579, + 11580, 11581, 11582, 11585, 11587, 11592, 11594, 11599, 11601, 11603, + 11605, 11607, 11609, 11621, 11625, 11632, 11636, 11642, 11646, 11657, + 11658, 11661, 11665, 11669, 11675, 11676, 11681, 11685, 11692, 11693, + 11694, 11695, 11696, 11697, 11698, 11699, 11709, 11713, 11720, 11727, + 11728, 11744, 11748, 11753, 11757, 11772, 11777, 11781, 11784, 11787, + 11788, 11789, 11792, 11799, 11809, 11823, 11824, 11828, 11839, 11840, + 11843, 11844, 11847, 11851, 11858, 11862, 11866, 11873, 11883, 11884, + 11888, 11889, 11892, 11893, 11904, 11905, 11914, 11915, 11923, 11934, + 11935, 11938, 11954, 11962, 11970, 11992, 11993, 12004, 12008, 12035, + 12037, 12042, 12045, 12048, 12050, 12052, 12054, 12064, 12066, 12077, + 12081, 12085, 12089, 12093, 12102, 12109, 12134, 12138, 12144, 12161, + 12165, 12169, 12175, 12176, 12177, 12179, 12180, 12181, 12197, 12198, + 12199, 12204, 12205, 12206, 12212, 12213, 12214, 12215, 12216, 12236, + 12237, 12238, 12239, 12240, 12241, 12242, 12243, 12244, 12245, 12246, + 12247, 12248, 12249, 12250, 12251, 12252, 12253, 12254, 12255, 12256, + 12257, 12258, 12259, 12260, 12261, 12262, 12263, 12264, 12265, 12266, + 12267, 12268, 12269, 12270, 12271, 12272, 12273, 12274, 12275, 12276, + 12277, 12278, 12279, 12280, 12281, 12282, 12283, 12284, 12285, 12286, + 12287, 12288, 12289, 12290, 12291, 12292, 12293, 12294, 12295, 12296, + 12297, 12298, 12299, 12300, 12301, 12302, 12303, 12304, 12305, 12306, + 12307, 12308, 12309, 12310, 12311, 12312, 12313, 12314, 12315, 12316, + 12317, 12318, 12319, 12320, 12321, 12322, 12323, 12324, 12325, 12326, + 12327, 12328, 12329, 12330, 12331, 12332, 12333, 12334, 12335, 12336, + 12337, 12338, 12339, 12340, 12341, 12342, 12343, 12344, 12345, 12346, + 12347, 12348, 12349, 12350, 12351, 12352, 12353, 12354, 12355, 12356, + 12357, 12358, 12359, 12360, 12361, 12362, 12363, 12364, 12365, 12366, + 12367, 12368, 12369, 12370, 12371, 12372, 12373, 12374, 12375, 12376, + 12377, 12378, 12379, 12380, 12381, 12382, 12383, 12384, 12385, 12386, + 12387, 12388, 12389, 12390, 12391, 12392, 12393, 12394, 12395, 12396, + 12397, 12398, 12399, 12400, 12401, 12402, 12403, 12404, 12405, 12406, + 12407, 12408, 12409, 12410, 12411, 12412, 12413, 12414, 12415, 12416, + 12417, 12418, 12419, 12420, 12421, 12422, 12423, 12424, 12425, 12426, + 12427, 12428, 12429, 12430, 12431, 12432, 12433, 12434, 12435, 12436, + 12437, 12438, 12439, 12440, 12441, 12442, 12443, 12444, 12445, 12446, + 12447, 12448, 12449, 12450, 12451, 12452, 12453, 12454, 12455, 12456, + 12457, 12458, 12459, 12460, 12461, 12462, 12463, 12464, 12465, 12466, + 12467, 12468, 12469, 12470, 12471, 12472, 12473, 12474, 12475, 12476, + 12477, 12478, 12479, 12480, 12481, 12482, 12483, 12484, 12485, 12499, + 12500, 12501, 12502, 12503, 12504, 12505, 12506, 12507, 12508, 12509, + 12510, 12511, 12512, 12513, 12514, 12515, 12516, 12517, 12518, 12519, + 12520, 12521, 12522, 12523, 12524, 12525, 12526, 12527, 12528, 12529, + 12530, 12531, 12532, 12533, 12534, 12535, 12536, 12537, 12538, 12539, + 12540, 12541, 12542, 12543, 12544, 12545, 12559, 12560, 12561, 12562, + 12563, 12564, 12565, 12566, 12567, 12568, 12569, 12570, 12571, 12572, + 12573, 12574, 12575, 12576, 12577, 12578, 12579, 12580, 12581, 12591, + 12592, 12593, 12594, 12595, 12596, 12597, 12598, 12599, 12600, 12601, + 12602, 12603, 12604, 12605, 12606, 12607, 12608, 12609, 12610, 12611, + 12612, 12613, 12614, 12615, 12616, 12617, 12618, 12619, 12620, 12621, + 12622, 12623, 12624, 12625, 12626, 12627, 12628, 12629, 12630, 12631, + 12632, 12633, 12634, 12635, 12636, 12637, 12638, 12639, 12640, 12641, + 12642, 12643, 12644, 12645, 12646, 12647, 12648, 12649, 12650, 12651, + 12652, 12653, 12654, 12655, 12656, 12657, 12658, 12659, 12660, 12661, + 12662, 12663, 12664, 12665, 12666 +}; +#endif + +#if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE +/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM. + First, the terminals, then, starting at YYNTOKENS, nonterminals. */ +static const char *const yytname[] = +{ + "$end", "error", "$undefined", "IDENT", "FCONST", "SCONST", "BCONST", + "XCONST", "Op", "ICONST", "PARAM", "TYPECAST", "DOT_DOT", "COLON_EQUALS", + "ABORT_P", "ABSOLUTE_P", "ACCESS", "ACTION", "ADD_P", "ADMIN", "AFTER", + "AGGREGATE", "ALL", "ALSO", "ALTER", "ALWAYS", "ANALYSE", "ANALYZE", + "AND", "ANY", "ARRAY", "AS", "ASC", "ASSERTION", "ASSIGNMENT", + "ASYMMETRIC", "AT", "ATTRIBUTE", "AUTHORIZATION", "BACKWARD", "BEFORE", + "BEGIN_P", "BETWEEN", "BIGINT", "BINARY", "BIT", "BOOLEAN_P", "BOTH", + "BY", "CACHE", "CALLED", "CASCADE", "CASCADED", "CASE", "CAST", + "CATALOG_P", "CHAIN", "CHAR_P", "CHARACTER", "CHARACTERISTICS", "CHECK", + "CHECKPOINT", "CLASS", "CLOSE", "CLUSTER", "COALESCE", "COLLATE", + "COLLATION", "COLUMN", "COMMENT", "COMMENTS", "COMMIT", "COMMITTED", + "CONCURRENTLY", "CONFIGURATION", "CONNECTION", "CONSTRAINT", + "CONSTRAINTS", "CONTENT_P", "CONTINUE_P", "CONVERSION_P", "COPY", "COST", + "CREATE", "CROSS", "CSV", "CURRENT_P", "CURRENT_CATALOG", "CURRENT_DATE", + "CURRENT_ROLE", "CURRENT_SCHEMA", "CURRENT_TIME", "CURRENT_TIMESTAMP", + "CURRENT_USER", "CURSOR", "CYCLE", "DATA_P", "DATABASE", "DAY_P", + "DEALLOCATE", "DEC", "DECIMAL_P", "DECLARE", "DEFAULT", "DEFAULTS", + "DEFERRABLE", "DEFERRED", "DEFINER", "DELETE_P", "DELIMITER", + "DELIMITERS", "DESC", "DICTIONARY", "DISABLE_P", "DISCARD", "DISTINCT", + "DO", "DOCUMENT_P", "DOMAIN_P", "DOUBLE_P", "DROP", "EACH", "ELSE", + "ENABLE_P", "ENCODING", "ENCRYPTED", "END_P", "ENUM_P", "ESCAPE", + "EXCEPT", "EXCLUDE", "EXCLUDING", "EXCLUSIVE", "EXECUTE", "EXISTS", + "EXPLAIN", "EXTENSION", "EXTERNAL", "EXTRACT", "FALSE_P", "FAMILY", + "FETCH", "FIRST_P", "FLOAT_P", "FOLLOWING", "FOR", "FORCE", "FOREIGN", + "FORWARD", "FREEZE", "FROM", "FULL", "FUNCTION", "FUNCTIONS", "GLOBAL", + "GRANT", "GRANTED", "GREATEST", "GROUP_P", "HANDLER", "HAVING", + "HEADER_P", "HOLD", "HOUR_P", "IDENTITY_P", "IF_P", "ILIKE", "IMMEDIATE", + "IMMUTABLE", "IMPLICIT_P", "IN_P", "INCLUDING", "INCREMENT", "INDEX", + "INDEXES", "INHERIT", "INHERITS", "INITIALLY", "INLINE_P", "INNER_P", + "INOUT", "INPUT_P", "INSENSITIVE", "INSERT", "INSTEAD", "INT_P", + "INTEGER", "INTERSECT", "INTERVAL", "INTO", "INVOKER", "IS", "ISNULL", + "ISOLATION", "JOIN", "KEY", "LABEL", "LANGUAGE", "LARGE_P", "LAST_P", + "LC_COLLATE_P", "LC_CTYPE_P", "LEADING", "LEAKPROOF", "LEAST", "LEFT", + "LEVEL", "LIKE", "LIMIT", "LISTEN", "LOAD", "LOCAL", "LOCALTIME", + "LOCALTIMESTAMP", "LOCATION", "LOCK_P", "MAPPING", "MATCH", "MAXVALUE", + "MINUTE_P", "MINVALUE", "MODE", "MONTH_P", "MOVE", "NAME_P", "NAMES", + "NATIONAL", "NATURAL", "NCHAR", "NEXT", "NO", "NONE", "NOT", "NOTHING", + "NOTIFY", "NOTNULL", "NOWAIT", "NULL_P", "NULLIF", "NULLS_P", "NUMERIC", + "OBJECT_P", "OF", "OFF", "OFFSET", "OIDS", "ON", "ONLY", "OPERATOR", + "OPTION", "OPTIONS", "OR", "ORDER", "OUT_P", "OUTER_P", "OVER", + "OVERLAPS", "OVERLAY", "OWNED", "OWNER", "PARSER", "PARTIAL", + "PARTITION", "PASSING", "PASSWORD", "PLACING", "PLANS", "POSITION", + "PRECEDING", "PRECISION", "PRESERVE", "PREPARE", "PREPARED", "PRIMARY", + "PRIOR", "PRIVILEGES", "PROCEDURAL", "PROCEDURE", "QUOTE", "RANGE", + "READ", "REAL", "REASSIGN", "RECHECK", "RECURSIVE", "REF", "REFERENCES", + "REINDEX", "RELATIVE_P", "RELEASE", "RENAME", "REPEATABLE", "REPLACE", + "REPLICA", "RESET", "RESTART", "RESTRICT", "RETURNING", "RETURNS", + "REVOKE", "RIGHT", "ROLE", "ROLLBACK", "ROW", "ROWS", "RULE", + "SAVEPOINT", "SCHEMA", "SCROLL", "SEARCH", "SECOND_P", "SECURITY", + "SELECT", "SEQUENCE", "SEQUENCES", "SERIALIZABLE", "SERVER", "SESSION", + "SESSION_USER", "SET", "SETOF", "SHARE", "SHOW", "SIMILAR", "SIMPLE", + "SMALLINT", "SNAPSHOT", "SOME", "STABLE", "STANDALONE_P", "START", + "STATEMENT", "STATISTICS", "STDIN", "STDOUT", "STORAGE", "STRICT_P", + "STRIP_P", "SUBSTRING", "SYMMETRIC", "SYSID", "SYSTEM_P", "TABLE", + "TABLES", "TABLESPACE", "TEMP", "TEMPLATE", "TEMPORARY", "TEXT_P", + "THEN", "TIME", "TIMESTAMP", "TO", "TRAILING", "TRANSACTION", "TREAT", + "TRIGGER", "TRIM", "TRUE_P", "TRUNCATE", "TRUSTED", "TYPE_P", "TYPES_P", + "UNBOUNDED", "UNCOMMITTED", "UNENCRYPTED", "UNION", "UNIQUE", "UNKNOWN", + "UNLISTEN", "UNLOGGED", "UNTIL", "UPDATE", "USER", "USING", "VACUUM", + "VALID", "VALIDATE", "VALIDATOR", "VALUE_P", "VALUES", "VARCHAR", + "VARIADIC", "VARYING", "VERBOSE", "VERSION_P", "VIEW", "VOLATILE", + "WHEN", "WHERE", "WHITESPACE_P", "WINDOW", "WITH", "WITHOUT", "WORK", + "WRAPPER", "WRITE", "XML_P", "XMLATTRIBUTES", "XMLCONCAT", "XMLELEMENT", + "XMLEXISTS", "XMLFOREST", "XMLPARSE", "XMLPI", "XMLROOT", "XMLSERIALIZE", + "YEAR_P", "YES_P", "ZONE", "NULLS_FIRST", "NULLS_LAST", "WITH_TIME", + "'='", "'<'", "'>'", "POSTFIXOP", "'+'", "'-'", "'*'", "'/'", "'%'", + "'^'", "UMINUS", "'['", "']'", "'('", "')'", "'.'", "';'", "','", "':'", + "$accept", "stmtblock", "stmtmulti", "stmt", "CreateRoleStmt", + "opt_with", "OptRoleList", "AlterOptRoleList", "AlterOptRoleElem", + "CreateOptRoleElem", "CreateUserStmt", "AlterRoleStmt", + "opt_in_database", "AlterRoleSetStmt", "AlterUserStmt", + "AlterUserSetStmt", "DropRoleStmt", "DropUserStmt", "CreateGroupStmt", + "AlterGroupStmt", "add_drop", "DropGroupStmt", "CreateSchemaStmt", + "OptSchemaName", "OptSchemaEltList", "schema_stmt", "VariableSetStmt", + "set_rest", "set_rest_more", "var_name", "var_list", "var_value", + "iso_level", "opt_boolean_or_string", "zone_value", "opt_encoding", + "ColId_or_Sconst", "VariableResetStmt", "SetResetClause", + "FunctionSetResetClause", "VariableShowStmt", "ConstraintsSetStmt", + "constraints_set_list", "constraints_set_mode", "CheckPointStmt", + "DiscardStmt", "AlterTableStmt", "alter_table_cmds", "alter_table_cmd", + "alter_column_default", "opt_drop_behavior", "opt_collate_clause", + "alter_using", "reloptions", "opt_reloptions", "reloption_list", + "reloption_elem", "AlterCompositeTypeStmt", "alter_type_cmds", + "alter_type_cmd", "ClosePortalStmt", "CopyStmt", "copy_from", + "copy_file_name", "copy_options", "copy_opt_list", "copy_opt_item", + "opt_binary", "opt_oids", "copy_delimiter", "opt_using", + "copy_generic_opt_list", "copy_generic_opt_elem", "copy_generic_opt_arg", + "copy_generic_opt_arg_list", "copy_generic_opt_arg_list_item", + "CreateStmt", "OptTemp", "OptTableElementList", + "OptTypedTableElementList", "TableElementList", "TypedTableElementList", + "TableElement", "TypedTableElement", "columnDef", "columnOptions", + "ColQualList", "ColConstraint", "ColConstraintElem", "ConstraintAttr", + "TableLikeClause", "TableLikeOptionList", "TableLikeOption", + "TableConstraint", "ConstraintElem", "opt_no_inherit", "opt_column_list", + "columnList", "columnElem", "key_match", "ExclusionConstraintList", + "ExclusionConstraintElem", "ExclusionWhereClause", "key_actions", + "key_update", "key_delete", "key_action", "OptInherit", "OptWith", + "OnCommitOption", "OptTableSpace", "OptConsTableSpace", "ExistingIndex", + "CreateAsStmt", "create_as_target", "opt_with_data", "CreateSeqStmt", + "AlterSeqStmt", "OptSeqOptList", "SeqOptList", "SeqOptElem", "opt_by", + "NumericOnly", "NumericOnly_list", "CreatePLangStmt", "opt_trusted", + "handler_name", "opt_inline_handler", "validator_clause", + "opt_validator", "DropPLangStmt", "opt_procedural", + "CreateTableSpaceStmt", "OptTableSpaceOwner", "DropTableSpaceStmt", + "CreateExtensionStmt", "create_extension_opt_list", + "create_extension_opt_item", "AlterExtensionStmt", + "alter_extension_opt_list", "alter_extension_opt_item", + "AlterExtensionContentsStmt", "CreateFdwStmt", "fdw_option", + "fdw_options", "opt_fdw_options", "DropFdwStmt", "AlterFdwStmt", + "create_generic_options", "generic_option_list", "alter_generic_options", + "alter_generic_option_list", "alter_generic_option_elem", + "generic_option_elem", "generic_option_name", "generic_option_arg", + "CreateForeignServerStmt", "opt_type", "foreign_server_version", + "opt_foreign_server_version", "DropForeignServerStmt", + "AlterForeignServerStmt", "CreateForeignTableStmt", + "OptForeignTableElementList", "ForeignTableElementList", + "ForeignTableElement", "AlterForeignTableStmt", "CreateUserMappingStmt", + "auth_ident", "DropUserMappingStmt", "AlterUserMappingStmt", + "CreateTrigStmt", "TriggerActionTime", "TriggerEvents", + "TriggerOneEvent", "TriggerForSpec", "TriggerForOptEach", + "TriggerForType", "TriggerWhen", "TriggerFuncArgs", "TriggerFuncArg", + "OptConstrFromTable", "ConstraintAttributeSpec", + "ConstraintAttributeElem", "DropTrigStmt", "CreateAssertStmt", + "DropAssertStmt", "DefineStmt", "definition", "def_list", "def_elem", + "def_arg", "aggr_args", "old_aggr_definition", "old_aggr_list", + "old_aggr_elem", "opt_enum_val_list", "enum_val_list", "AlterEnumStmt", + "CreateOpClassStmt", "opclass_item_list", "opclass_item", "opt_default", + "opt_opfamily", "opclass_purpose", "opt_recheck", "CreateOpFamilyStmt", + "AlterOpFamilyStmt", "opclass_drop_list", "opclass_drop", + "DropOpClassStmt", "DropOpFamilyStmt", "DropOwnedStmt", + "ReassignOwnedStmt", "DropStmt", "drop_type", "any_name_list", + "any_name", "attrs", "TruncateStmt", "opt_restart_seqs", "CommentStmt", + "comment_type", "comment_text", "SecLabelStmt", "opt_provider", + "security_label_type", "security_label", "FetchStmt", "fetch_args", + "from_in", "opt_from_in", "GrantStmt", "RevokeStmt", "privileges", + "privilege_list", "privilege", "privilege_target", "grantee_list", + "grantee", "opt_grant_grant_option", "function_with_argtypes_list", + "function_with_argtypes", "GrantRoleStmt", "RevokeRoleStmt", + "opt_grant_admin_option", "opt_granted_by", "AlterDefaultPrivilegesStmt", + "DefACLOptionList", "DefACLOption", "DefACLAction", + "defacl_privilege_target", "IndexStmt", "opt_unique", "opt_concurrently", + "opt_index_name", "access_method_clause", "index_params", "index_elem", + "opt_collate", "opt_class", "opt_asc_desc", "opt_nulls_order", + "CreateFunctionStmt", "opt_or_replace", "func_args", "func_args_list", + "func_args_with_defaults", "func_args_with_defaults_list", "func_arg", + "arg_class", "param_name", "func_return", "func_type", + "func_arg_with_default", "createfunc_opt_list", "common_func_opt_item", + "createfunc_opt_item", "func_as", "opt_definition", "table_func_column", + "table_func_column_list", "AlterFunctionStmt", "alterfunc_opt_list", + "opt_restrict", "RemoveFuncStmt", "RemoveAggrStmt", "RemoveOperStmt", + "oper_argtypes", "any_operator", "DoStmt", "dostmt_opt_list", + "dostmt_opt_item", "CreateCastStmt", "cast_context", "DropCastStmt", + "opt_if_exists", "ReindexStmt", "reindex_type", "opt_force", + "RenameStmt", "opt_column", "opt_set_data", "AlterObjectSchemaStmt", + "AlterOwnerStmt", "RuleStmt", "RuleActionList", "RuleActionMulti", + "RuleActionStmt", "RuleActionStmtOrEmpty", "event", "opt_instead", + "DropRuleStmt", "NotifyStmt", "notify_payload", "ListenStmt", + "UnlistenStmt", "TransactionStmt", "opt_transaction", + "transaction_mode_item", "transaction_mode_list", + "transaction_mode_list_or_empty", "ViewStmt", "opt_check_option", + "LoadStmt", "CreatedbStmt", "createdb_opt_list", "createdb_opt_item", + "opt_equal", "AlterDatabaseStmt", "AlterDatabaseSetStmt", + "alterdb_opt_list", "alterdb_opt_item", "DropdbStmt", "CreateDomainStmt", + "AlterDomainStmt", "opt_as", "AlterTSDictionaryStmt", + "AlterTSConfigurationStmt", "CreateConversionStmt", "ClusterStmt", + "cluster_index_specification", "VacuumStmt", "vacuum_option_list", + "vacuum_option_elem", "AnalyzeStmt", "analyze_keyword", "opt_verbose", + "opt_full", "opt_freeze", "opt_name_list", "ExplainStmt", + "ExplainableStmt", "explain_option_list", "explain_option_elem", + "explain_option_name", "explain_option_arg", "PrepareStmt", + "prep_type_clause", "PreparableStmt", "ExecuteStmt", + "execute_param_clause", "DeallocateStmt", "InsertStmt", "insert_rest", + "insert_column_list", "insert_column_item", "returning_clause", + "DeleteStmt", "using_clause", "LockStmt", "opt_lock", "lock_type", + "opt_nowait", "UpdateStmt", "set_clause_list", "set_clause", + "single_set_clause", "multiple_set_clause", "set_target", + "set_target_list", "DeclareCursorStmt", "cursor_name", "cursor_options", + "opt_hold", "SelectStmt", "select_with_parens", "select_no_parens", + "select_clause", "simple_select", "with_clause", "cte_list", + "common_table_expr", "opt_with_clause", "into_clause", + "OptTempTableName", "opt_table", "opt_all", "opt_distinct", + "opt_sort_clause", "sort_clause", "sortby_list", "sortby", + "select_limit", "opt_select_limit", "limit_clause", "offset_clause", + "select_limit_value", "select_offset_value", + "opt_select_fetch_first_value", "select_offset_value2", "row_or_rows", + "first_or_next", "group_clause", "having_clause", "for_locking_clause", + "opt_for_locking_clause", "for_locking_items", "for_locking_item", + "locked_rels_list", "values_clause", "from_clause", "from_list", + "table_ref", "joined_table", "alias_clause", "join_type", "join_outer", + "join_qual", "relation_expr", "relation_expr_list", + "relation_expr_opt_alias", "func_table", "where_clause", + "where_or_current_clause", "OptTableFuncElementList", + "TableFuncElementList", "TableFuncElement", "Typename", + "opt_array_bounds", "SimpleTypename", "ConstTypename", "GenericType", + "opt_type_modifiers", "Numeric", "opt_float", "Bit", "ConstBit", + "BitWithLength", "BitWithoutLength", "Character", "ConstCharacter", + "CharacterWithLength", "CharacterWithoutLength", "character", + "opt_varying", "opt_charset", "ConstDatetime", "ConstInterval", + "opt_timezone", "opt_interval", "interval_second", "a_expr", "b_expr", + "c_expr", "func_expr", "xml_root_version", "opt_xml_root_standalone", + "xml_attributes", "xml_attribute_list", "xml_attribute_el", + "document_or_content", "xml_whitespace_option", "xmlexists_argument", + "window_clause", "window_definition_list", "window_definition", + "over_clause", "window_specification", "opt_existing_window_name", + "opt_partition_clause", "opt_frame_clause", "frame_extent", + "frame_bound", "row", "sub_type", "all_Op", "MathOp", "qual_Op", + "qual_all_Op", "subquery_Op", "expr_list", "func_arg_list", + "func_arg_expr", "type_list", "array_expr", "array_expr_list", + "extract_list", "extract_arg", "overlay_list", "overlay_placing", + "position_list", "substr_list", "substr_from", "substr_for", "trim_list", + "in_expr", "case_expr", "when_clause_list", "when_clause", + "case_default", "case_arg", "columnref", "indirection_el", "indirection", + "opt_indirection", "opt_asymmetric", "ctext_expr", "ctext_expr_list", + "ctext_row", "target_list", "target_el", "qualified_name_list", + "qualified_name", "name_list", "name", "database_name", "access_method", + "attr_name", "index_name", "file_name", "func_name", "AexprConst", + "Iconst", "Sconst", "RoleId", "SignedIconst", "ColId", + "type_function_name", "ColLabel", "unreserved_keyword", + "col_name_keyword", "type_func_name_keyword", "reserved_keyword", 0 +}; +#endif + +# ifdef YYPRINT +/* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to + token YYLEX-NUM. */ +static const yytype_uint16 yytoknum[] = +{ + 0, 256, 257, 258, 259, 260, 261, 262, 263, 264, + 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, + 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, + 285, 286, 287, 288, 289, 290, 291, 292, 293, 294, + 295, 296, 297, 298, 299, 300, 301, 302, 303, 304, + 305, 306, 307, 308, 309, 310, 311, 312, 313, 314, + 315, 316, 317, 318, 319, 320, 321, 322, 323, 324, + 325, 326, 327, 328, 329, 330, 331, 332, 333, 334, + 335, 336, 337, 338, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 351, 352, 353, 354, + 355, 356, 357, 358, 359, 360, 361, 362, 363, 364, + 365, 366, 367, 368, 369, 370, 371, 372, 373, 374, + 375, 376, 377, 378, 379, 380, 381, 382, 383, 384, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, + 415, 416, 417, 418, 419, 420, 421, 422, 423, 424, + 425, 426, 427, 428, 429, 430, 431, 432, 433, 434, + 435, 436, 437, 438, 439, 440, 441, 442, 443, 444, + 445, 446, 447, 448, 449, 450, 451, 452, 453, 454, + 455, 456, 457, 458, 459, 460, 461, 462, 463, 464, + 465, 466, 467, 468, 469, 470, 471, 472, 473, 474, + 475, 476, 477, 478, 479, 480, 481, 482, 483, 484, + 485, 486, 487, 488, 489, 490, 491, 492, 493, 494, + 495, 496, 497, 498, 499, 500, 501, 502, 503, 504, + 505, 506, 507, 508, 509, 510, 511, 512, 513, 514, + 515, 516, 517, 518, 519, 520, 521, 522, 523, 524, + 525, 526, 527, 528, 529, 530, 531, 532, 533, 534, + 535, 536, 537, 538, 539, 540, 541, 542, 543, 544, + 545, 546, 547, 548, 549, 550, 551, 552, 553, 554, + 555, 556, 557, 558, 559, 560, 561, 562, 563, 564, + 565, 566, 567, 568, 569, 570, 571, 572, 573, 574, + 575, 576, 577, 578, 579, 580, 581, 582, 583, 584, + 585, 586, 587, 588, 589, 590, 591, 592, 593, 594, + 595, 596, 597, 598, 599, 600, 601, 602, 603, 604, + 605, 606, 607, 608, 609, 610, 611, 612, 613, 614, + 615, 616, 617, 618, 619, 620, 621, 622, 623, 624, + 625, 626, 627, 628, 629, 630, 631, 632, 633, 634, + 635, 636, 637, 638, 639, 640, 641, 642, 643, 644, + 645, 646, 647, 648, 649, 650, 651, 652, 653, 654, + 655, 656, 657, 658, 659, 660, 661, 662, 663, 664, + 665, 666, 667, 61, 60, 62, 668, 43, 45, 42, + 47, 37, 94, 669, 91, 93, 40, 41, 46, 59, + 44, 58 +}; +# endif + +/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ +static const yytype_uint16 yyr1[] = +{ + 0, 432, 433, 434, 434, 435, 435, 435, 435, 435, + 435, 435, 435, 435, 435, 435, 435, 435, 435, 435, + 435, 435, 435, 435, 435, 435, 435, 435, 435, 435, + 435, 435, 435, 435, 435, 435, 435, 435, 435, 435, + 435, 435, 435, 435, 435, 435, 435, 435, 435, 435, + 435, 435, 435, 435, 435, 435, 435, 435, 435, 435, + 435, 435, 435, 435, 435, 435, 435, 435, 435, 435, + 435, 435, 435, 435, 435, 435, 435, 435, 435, 435, + 435, 435, 435, 435, 435, 435, 435, 435, 435, 435, + 435, 435, 435, 435, 435, 435, 435, 435, 435, 435, + 435, 435, 435, 435, 435, 435, 435, 435, 435, 435, + 435, 435, 435, 435, 435, 435, 436, 437, 437, 438, + 438, 439, 439, 440, 440, 440, 440, 440, 440, 440, + 440, 440, 441, 441, 441, 441, 441, 441, 442, 443, + 444, 444, 445, 446, 447, 448, 448, 449, 449, 450, + 451, 452, 452, 453, 453, 454, 454, 455, 455, 456, + 456, 457, 457, 457, 457, 457, 457, 458, 458, 458, + 459, 459, 459, 460, 460, 460, 460, 460, 460, 460, + 460, 460, 460, 460, 460, 460, 460, 461, 461, 462, + 462, 463, 463, 464, 464, 464, 464, 465, 465, 465, + 465, 466, 466, 466, 466, 466, 466, 466, 467, 467, + 467, 468, 468, 469, 469, 469, 469, 469, 470, 470, + 471, 471, 472, 472, 472, 472, 472, 473, 474, 474, + 475, 475, 476, 477, 477, 477, 477, 478, 478, 478, + 478, 478, 478, 478, 478, 479, 479, 480, 480, 480, + 480, 480, 480, 480, 480, 480, 480, 480, 480, 480, + 480, 480, 480, 480, 480, 480, 480, 480, 480, 480, + 480, 480, 480, 480, 480, 480, 480, 480, 480, 480, + 480, 480, 480, 480, 480, 480, 480, 480, 480, 481, + 481, 482, 482, 482, 483, 483, 484, 484, 485, 486, + 486, 487, 487, 488, 488, 488, 488, 489, 490, 490, + 491, 491, 491, 491, 492, 492, 493, 493, 494, 494, + 495, 495, 495, 496, 496, 497, 497, 498, 498, 498, + 498, 498, 498, 498, 498, 498, 498, 498, 498, 499, + 499, 500, 500, 501, 501, 502, 502, 503, 503, 504, + 505, 505, 505, 505, 505, 506, 506, 507, 508, 508, + 508, 508, 509, 509, 509, 509, 509, 509, 509, 509, + 510, 510, 511, 511, 512, 512, 513, 513, 514, 514, + 514, 515, 515, 516, 517, 518, 518, 519, 519, 519, + 519, 520, 520, 520, 520, 520, 520, 520, 521, 521, + 521, 521, 522, 523, 523, 523, 524, 524, 524, 524, + 524, 524, 525, 525, 526, 526, 526, 526, 526, 526, + 526, 527, 527, 528, 528, 529, 529, 530, 531, 531, + 531, 531, 532, 532, 533, 533, 534, 534, 535, 535, + 535, 535, 535, 536, 537, 538, 538, 538, 538, 538, + 539, 539, 540, 540, 540, 540, 541, 541, 541, 541, + 542, 542, 543, 543, 544, 545, 546, 547, 547, 547, + 548, 549, 549, 550, 550, 551, 551, 552, 552, 552, + 552, 552, 552, 552, 552, 552, 552, 552, 552, 553, + 553, 554, 554, 554, 555, 555, 556, 556, 557, 557, + 558, 558, 559, 559, 560, 560, 561, 561, 562, 562, + 563, 563, 564, 565, 565, 566, 566, 567, 567, 568, + 568, 569, 569, 569, 570, 571, 571, 572, 573, 573, + 573, 573, 573, 573, 573, 573, 573, 573, 573, 573, + 573, 573, 573, 573, 573, 573, 573, 573, 573, 573, + 574, 575, 575, 575, 575, 576, 576, 577, 577, 578, + 578, 579, 579, 580, 580, 581, 581, 582, 583, 583, + 584, 584, 584, 584, 585, 586, 587, 588, 589, 589, + 590, 590, 591, 591, 592, 592, 593, 593, 593, 594, + 594, 595, 595, 596, 596, 597, 598, 598, 599, 600, + 600, 600, 601, 601, 602, 603, 603, 604, 604, 604, + 605, 605, 606, 606, 606, 606, 606, 607, 607, 608, + 608, 609, 609, 610, 610, 611, 611, 611, 612, 612, + 612, 612, 613, 613, 614, 614, 615, 615, 615, 615, + 615, 615, 616, 616, 617, 618, 619, 619, 619, 619, + 619, 619, 619, 619, 619, 619, 619, 619, 619, 619, + 620, 621, 621, 622, 622, 623, 623, 623, 623, 623, + 624, 624, 625, 626, 626, 627, 628, 628, 629, 629, + 630, 630, 630, 631, 632, 632, 633, 633, 633, 633, + 633, 634, 634, 635, 635, 636, 636, 636, 637, 637, + 638, 639, 639, 640, 640, 641, 641, 642, 642, 643, + 643, 644, 645, 646, 646, 646, 646, 647, 647, 647, + 647, 647, 647, 647, 647, 647, 647, 647, 647, 647, + 647, 647, 648, 648, 649, 649, 650, 650, 651, 652, + 652, 652, 653, 653, 653, 653, 653, 653, 653, 653, + 653, 653, 653, 653, 653, 653, 653, 653, 653, 654, + 654, 654, 654, 654, 654, 654, 654, 654, 654, 654, + 654, 654, 654, 654, 654, 654, 655, 655, 656, 656, + 656, 656, 656, 657, 657, 658, 658, 658, 658, 658, + 658, 658, 658, 658, 658, 658, 659, 659, 660, 660, + 661, 661, 661, 661, 661, 661, 661, 661, 661, 661, + 661, 661, 661, 661, 661, 661, 662, 662, 663, 663, + 664, 665, 665, 666, 666, 666, 666, 666, 667, 667, + 668, 668, 668, 668, 669, 669, 669, 669, 669, 669, + 669, 669, 669, 669, 669, 669, 669, 669, 669, 669, + 670, 670, 671, 671, 672, 672, 673, 673, 674, 675, + 676, 676, 677, 677, 678, 678, 679, 680, 680, 681, + 681, 681, 682, 682, 682, 683, 683, 683, 683, 684, + 685, 685, 686, 686, 687, 687, 688, 688, 689, 689, + 690, 690, 690, 691, 691, 692, 692, 692, 693, 693, + 693, 694, 694, 694, 695, 695, 695, 696, 696, 697, + 697, 698, 698, 699, 699, 700, 700, 701, 701, 701, + 701, 701, 702, 702, 702, 702, 702, 703, 704, 705, + 705, 705, 706, 706, 706, 707, 707, 708, 708, 708, + 708, 708, 708, 708, 708, 708, 708, 708, 708, 708, + 708, 708, 709, 709, 709, 709, 710, 710, 711, 711, + 712, 713, 713, 714, 715, 715, 716, 716, 717, 717, + 718, 718, 719, 719, 720, 720, 720, 720, 721, 721, + 722, 723, 723, 724, 724, 725, 725, 725, 726, 726, + 726, 727, 728, 728, 729, 729, 729, 730, 730, 731, + 731, 732, 732, 732, 732, 732, 732, 732, 732, 732, + 732, 732, 732, 732, 732, 732, 732, 732, 732, 732, + 732, 732, 732, 732, 732, 732, 732, 732, 732, 732, + 732, 732, 732, 732, 732, 732, 732, 732, 732, 732, + 732, 732, 733, 733, 734, 734, 735, 735, 735, 735, + 735, 735, 735, 735, 735, 735, 735, 735, 735, 735, + 735, 735, 735, 735, 735, 735, 735, 735, 736, 736, + 736, 736, 736, 736, 736, 736, 736, 736, 736, 736, + 736, 736, 736, 736, 736, 736, 737, 738, 738, 738, + 739, 739, 740, 740, 740, 740, 740, 741, 741, 742, + 742, 742, 742, 743, 743, 743, 744, 744, 745, 746, + 746, 747, 748, 748, 749, 749, 749, 749, 749, 749, + 749, 749, 749, 749, 749, 749, 749, 749, 750, 750, + 750, 751, 751, 751, 751, 751, 752, 752, 752, 753, + 753, 754, 754, 755, 755, 755, 755, 756, 757, 758, + 758, 759, 759, 759, 759, 759, 759, 759, 759, 759, + 759, 759, 759, 759, 759, 759, 759, 760, 760, 761, + 761, 762, 763, 763, 764, 765, 765, 766, 767, 767, + 767, 767, 767, 767, 767, 768, 768, 769, 770, 770, + 770, 770, 770, 770, 771, 772, 772, 772, 773, 773, + 774, 774, 774, 774, 774, 775, 775, 776, 776, 776, + 776, 777, 777, 778, 778, 779, 779, 780, 780, 781, + 781, 782, 782, 783, 783, 783, 783, 784, 784, 784, + 784, 784, 784, 784, 785, 785, 786, 787, 787, 787, + 788, 788, 788, 789, 790, 790, 791, 791, 791, 791, + 792, 792, 793, 793, 794, 794, 794, 794, 795, 796, + 796, 796, 797, 797, 798, 799, 799, 800, 801, 801, + 802, 803, 803, 804, 804, 804, 804, 804, 804, 804, + 804, 805, 805, 806, 807, 807, 808, 808, 809, 810, + 811, 812, 812, 813, 814, 815, 815, 815, 815, 815, + 816, 816, 816, 817, 817, 818, 818, 819, 819, 819, + 819, 819, 819, 819, 819, 820, 820, 821, 821, 821, + 821, 821, 821, 822, 822, 823, 823, 824, 825, 825, + 826, 826, 827, 827, 827, 827, 827, 827, 827, 827, + 827, 828, 828, 829, 829, 829, 830, 830, 830, 830, + 831, 831, 832, 833, 833, 834, 834, 835, 835, 835, + 835, 836, 836, 837, 837, 837, 838, 838, 839, 839, + 840, 841, 841, 841, 842, 843, 843, 844, 844, 845, + 845, 846, 846, 847, 847, 848, 848, 849, 849, 850, + 850, 851, 851, 852, 852, 853, 853, 854, 854, 855, + 855, 855, 855, 855, 855, 855, 855, 855, 855, 855, + 856, 856, 856, 856, 856, 856, 857, 857, 857, 857, + 858, 858, 858, 858, 859, 859, 860, 860, 861, 861, + 861, 861, 862, 862, 863, 863, 863, 864, 865, 865, + 866, 866, 866, 867, 867, 868, 868, 869, 870, 870, + 870, 870, 870, 870, 871, 871, 871, 872, 872, 872, + 872, 872, 872, 872, 873, 873, 873, 873, 874, 874, + 875, 875, 876, 876, 876, 876, 876, 876, 876, 876, + 876, 876, 876, 877, 877, 878, 878, 879, 879, 880, + 881, 882, 882, 883, 883, 884, 885, 886, 886, 886, + 886, 886, 886, 887, 887, 888, 888, 889, 889, 889, + 889, 890, 891, 891, 891, 892, 892, 892, 892, 892, + 892, 892, 892, 892, 892, 892, 892, 892, 892, 893, + 893, 894, 894, 894, 894, 894, 894, 894, 894, 894, + 894, 894, 894, 894, 894, 894, 894, 894, 894, 894, + 894, 894, 894, 894, 894, 894, 894, 894, 894, 894, + 894, 894, 894, 894, 894, 894, 894, 894, 894, 894, + 894, 894, 894, 894, 894, 894, 894, 894, 894, 894, + 894, 894, 894, 894, 894, 894, 894, 894, 894, 894, + 895, 895, 895, 895, 895, 895, 895, 895, 895, 895, + 895, 895, 895, 895, 895, 895, 895, 895, 895, 895, + 895, 895, 896, 896, 896, 896, 896, 896, 896, 896, + 896, 896, 896, 897, 897, 897, 897, 897, 897, 897, + 897, 897, 897, 897, 897, 897, 897, 897, 897, 897, + 897, 897, 897, 897, 897, 897, 897, 897, 897, 897, + 897, 897, 897, 897, 897, 897, 897, 897, 897, 897, + 897, 897, 897, 897, 897, 897, 897, 897, 897, 897, + 897, 897, 897, 898, 898, 899, 899, 899, 899, 900, + 901, 901, 902, 902, 903, 903, 904, 904, 904, 905, + 905, 905, 905, 906, 906, 907, 907, 908, 909, 909, + 909, 910, 911, 911, 912, 912, 913, 913, 913, 914, + 914, 915, 915, 915, 915, 915, 916, 916, 916, 917, + 917, 917, 918, 918, 919, 919, 919, 919, 919, 919, + 919, 919, 919, 920, 920, 921, 921, 922, 922, 922, + 922, 922, 922, 923, 923, 924, 924, 925, 925, 926, + 926, 927, 927, 927, 928, 928, 929, 929, 930, 930, + 930, 930, 930, 930, 930, 930, 931, 931, 932, 933, + 933, 934, 934, 934, 934, 934, 934, 935, 936, 937, + 937, 937, 938, 938, 939, 940, 940, 941, 942, 942, + 943, 943, 944, 944, 945, 945, 945, 945, 946, 946, + 947, 947, 948, 948, 949, 949, 950, 950, 951, 952, + 952, 953, 953, 953, 953, 954, 954, 955, 955, 956, + 956, 957, 958, 959, 960, 961, 962, 963, 963, 964, + 964, 964, 964, 964, 964, 964, 964, 964, 964, 964, + 964, 964, 965, 966, 967, 968, 968, 968, 969, 969, + 969, 970, 970, 970, 971, 971, 971, 971, 971, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 972, 972, 972, 972, 973, + 973, 973, 973, 973, 973, 973, 973, 973, 973, 973, + 973, 973, 973, 973, 973, 973, 973, 973, 973, 973, + 973, 973, 973, 973, 973, 973, 973, 973, 973, 973, + 973, 973, 973, 973, 973, 973, 973, 973, 973, 973, + 973, 973, 973, 973, 973, 973, 974, 974, 974, 974, + 974, 974, 974, 974, 974, 974, 974, 974, 974, 974, + 974, 974, 974, 974, 974, 974, 974, 974, 974, 975, + 975, 975, 975, 975, 975, 975, 975, 975, 975, 975, + 975, 975, 975, 975, 975, 975, 975, 975, 975, 975, + 975, 975, 975, 975, 975, 975, 975, 975, 975, 975, + 975, 975, 975, 975, 975, 975, 975, 975, 975, 975, + 975, 975, 975, 975, 975, 975, 975, 975, 975, 975, + 975, 975, 975, 975, 975, 975, 975, 975, 975, 975, + 975, 975, 975, 975, 975, 975, 975, 975, 975, 975, + 975, 975, 975, 975, 975 +}; + +/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */ +static const yytype_uint8 yyr2[] = +{ + 0, 2, 1, 3, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 0, 5, 1, 0, 2, + 0, 2, 0, 2, 2, 3, 3, 1, 3, 3, + 2, 1, 1, 2, 2, 2, 3, 3, 5, 5, + 0, 3, 5, 5, 4, 3, 5, 3, 5, 5, + 6, 1, 1, 3, 5, 6, 4, 1, 0, 2, + 0, 1, 1, 1, 1, 1, 1, 2, 3, 3, + 2, 5, 1, 3, 3, 3, 3, 3, 3, 2, + 2, 2, 2, 3, 3, 3, 3, 1, 3, 1, + 3, 1, 1, 2, 2, 2, 1, 1, 1, 1, + 1, 1, 1, 3, 6, 1, 1, 1, 1, 1, + 0, 1, 1, 2, 3, 4, 3, 2, 2, 1, + 2, 1, 2, 3, 4, 3, 2, 4, 1, 1, + 1, 1, 1, 2, 2, 2, 2, 4, 6, 4, + 6, 4, 6, 4, 6, 1, 3, 2, 3, 4, + 6, 6, 6, 5, 5, 6, 6, 4, 8, 4, + 2, 3, 6, 4, 3, 3, 3, 3, 3, 4, + 4, 3, 3, 3, 3, 3, 3, 4, 4, 3, + 2, 3, 2, 2, 3, 3, 2, 2, 1, 3, + 2, 1, 1, 0, 2, 0, 2, 0, 3, 2, + 0, 1, 3, 3, 1, 5, 3, 4, 1, 3, + 4, 6, 4, 8, 2, 2, 10, 6, 1, 1, + 1, 1, 1, 1, 3, 2, 0, 1, 1, 3, + 3, 1, 1, 3, 3, 3, 3, 4, 2, 1, + 0, 2, 0, 3, 0, 1, 0, 1, 3, 2, + 1, 1, 1, 3, 0, 1, 3, 1, 11, 14, + 10, 13, 1, 1, 2, 2, 2, 2, 1, 0, + 1, 0, 3, 0, 1, 3, 1, 3, 1, 1, + 1, 1, 1, 4, 4, 2, 0, 3, 1, 1, + 2, 2, 1, 3, 4, 5, 2, 5, 1, 2, + 2, 2, 3, 3, 3, 0, 1, 1, 1, 1, + 1, 1, 3, 1, 5, 7, 3, 8, 4, 9, + 11, 2, 0, 3, 0, 1, 3, 1, 2, 2, + 2, 0, 1, 3, 3, 6, 4, 0, 1, 1, + 2, 2, 0, 3, 3, 2, 1, 1, 2, 2, + 4, 0, 2, 2, 2, 0, 3, 4, 4, 0, + 2, 0, 4, 0, 3, 7, 5, 2, 3, 0, + 5, 4, 6, 1, 0, 1, 2, 2, 1, 2, + 3, 2, 2, 2, 2, 3, 3, 1, 3, 1, + 0, 1, 2, 1, 1, 3, 6, 10, 1, 0, + 1, 2, 2, 0, 2, 2, 1, 0, 5, 7, + 1, 0, 6, 2, 0, 3, 5, 5, 8, 2, + 0, 2, 2, 2, 5, 2, 0, 2, 7, 10, + 6, 6, 6, 6, 7, 7, 9, 9, 6, 6, + 8, 8, 8, 8, 6, 6, 7, 8, 6, 6, + 7, 2, 2, 2, 2, 1, 2, 1, 0, 6, + 8, 7, 6, 4, 0, 1, 3, 4, 1, 3, + 1, 2, 2, 2, 2, 1, 1, 10, 2, 0, + 2, 2, 1, 0, 4, 6, 5, 4, 4, 8, + 11, 3, 2, 1, 3, 1, 5, 7, 8, 1, + 1, 1, 7, 9, 8, 15, 20, 1, 1, 2, + 1, 3, 1, 1, 1, 3, 1, 3, 0, 1, + 0, 1, 1, 4, 0, 1, 3, 0, 1, 1, + 1, 1, 2, 0, 0, 2, 2, 1, 2, 2, + 2, 2, 6, 8, 8, 4, 5, 4, 4, 4, + 3, 7, 8, 6, 6, 6, 6, 6, 4, 5, + 3, 1, 3, 3, 1, 1, 1, 1, 1, 1, + 3, 3, 3, 1, 3, 3, 1, 0, 1, 3, + 6, 8, 8, 13, 1, 3, 5, 6, 4, 7, + 2, 1, 0, 2, 0, 2, 4, 0, 1, 0, + 6, 8, 8, 1, 3, 5, 5, 7, 9, 7, + 9, 5, 6, 6, 4, 5, 7, 1, 1, 1, + 1, 2, 1, 1, 1, 1, 1, 1, 3, 3, + 3, 3, 1, 3, 1, 2, 2, 3, 5, 2, + 2, 0, 6, 7, 7, 7, 8, 8, 6, 8, + 9, 9, 7, 10, 7, 8, 8, 8, 8, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 2, 1, 3, 1, 1, 8, 9, + 9, 9, 9, 2, 0, 1, 1, 2, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, + 1, 2, 3, 3, 3, 3, 4, 4, 3, 3, + 3, 4, 4, 3, 4, 4, 1, 1, 1, 0, + 7, 7, 10, 1, 1, 2, 4, 5, 1, 3, + 2, 2, 2, 2, 1, 2, 2, 4, 3, 2, + 2, 2, 2, 3, 2, 2, 2, 5, 5, 5, + 1, 3, 1, 2, 3, 0, 1, 3, 2, 6, + 6, 9, 3, 0, 3, 0, 5, 2, 0, 3, + 3, 3, 7, 7, 10, 1, 1, 1, 1, 14, + 1, 0, 1, 0, 1, 0, 2, 0, 1, 3, + 5, 5, 7, 2, 0, 1, 2, 0, 1, 1, + 0, 1, 1, 0, 9, 12, 7, 2, 0, 3, + 2, 1, 3, 3, 2, 1, 3, 3, 3, 2, + 2, 1, 1, 1, 1, 2, 1, 1, 1, 1, + 4, 5, 1, 3, 3, 1, 2, 4, 5, 1, + 1, 1, 1, 3, 3, 2, 2, 1, 2, 2, + 2, 1, 2, 2, 1, 1, 1, 3, 2, 0, + 2, 1, 3, 5, 1, 2, 1, 0, 5, 7, + 5, 7, 5, 7, 3, 5, 5, 5, 1, 3, + 2, 1, 2, 1, 2, 11, 10, 10, 2, 2, + 0, 9, 2, 0, 4, 4, 4, 1, 1, 1, + 0, 7, 6, 6, 6, 6, 8, 8, 6, 6, + 7, 9, 9, 6, 6, 6, 8, 6, 8, 6, + 8, 6, 8, 7, 9, 8, 10, 8, 9, 11, + 8, 6, 6, 6, 5, 5, 8, 8, 8, 8, + 6, 9, 1, 0, 2, 0, 7, 6, 6, 6, + 6, 6, 7, 9, 9, 6, 8, 8, 8, 8, + 8, 6, 8, 6, 8, 7, 9, 6, 7, 6, + 6, 6, 6, 6, 7, 7, 7, 9, 9, 6, + 6, 6, 8, 8, 8, 6, 13, 1, 1, 3, + 3, 1, 1, 1, 1, 1, 1, 1, 0, 1, + 1, 1, 1, 1, 1, 0, 6, 8, 3, 2, + 0, 2, 2, 2, 2, 3, 3, 2, 2, 2, + 2, 3, 2, 5, 4, 3, 3, 3, 1, 1, + 0, 3, 2, 2, 1, 2, 1, 3, 2, 1, + 0, 9, 11, 3, 4, 4, 0, 2, 5, 2, + 0, 3, 3, 3, 3, 3, 3, 3, 3, 3, + 3, 3, 3, 3, 4, 3, 3, 1, 0, 5, + 6, 4, 2, 0, 4, 3, 5, 6, 4, 6, + 6, 5, 7, 9, 6, 1, 0, 6, 11, 11, + 11, 13, 9, 11, 10, 4, 2, 5, 2, 0, + 4, 5, 5, 4, 6, 1, 3, 1, 1, 1, + 1, 2, 4, 1, 1, 1, 0, 1, 0, 1, + 0, 3, 0, 2, 4, 3, 5, 1, 1, 1, + 1, 1, 1, 1, 1, 3, 2, 1, 1, 1, + 1, 1, 0, 5, 3, 0, 1, 1, 1, 1, + 3, 9, 3, 0, 2, 3, 2, 3, 6, 1, + 4, 2, 1, 3, 2, 2, 0, 7, 2, 0, + 5, 3, 0, 2, 2, 2, 3, 1, 3, 1, + 2, 1, 0, 8, 1, 3, 1, 1, 3, 5, + 2, 1, 3, 7, 1, 0, 3, 2, 2, 2, + 0, 2, 2, 1, 1, 3, 3, 1, 2, 4, + 4, 2, 3, 5, 5, 1, 1, 9, 1, 2, + 4, 4, 4, 2, 3, 1, 3, 6, 1, 0, + 2, 0, 3, 3, 4, 4, 4, 4, 3, 2, + 1, 1, 0, 1, 1, 0, 1, 5, 1, 0, + 1, 0, 3, 1, 3, 4, 3, 2, 2, 1, + 1, 1, 0, 2, 4, 5, 2, 3, 1, 1, + 1, 1, 3, 0, 1, 1, 1, 1, 1, 3, + 0, 2, 0, 1, 3, 1, 0, 1, 2, 4, + 4, 2, 0, 2, 3, 2, 0, 1, 3, 1, + 2, 1, 2, 5, 6, 5, 1, 2, 1, 4, + 3, 4, 5, 4, 5, 4, 5, 2, 4, 1, + 2, 2, 2, 1, 1, 0, 4, 2, 1, 2, + 2, 4, 1, 3, 1, 2, 3, 1, 2, 0, + 2, 4, 0, 1, 0, 1, 3, 3, 2, 3, + 5, 6, 2, 3, 3, 4, 0, 1, 1, 1, + 1, 1, 2, 5, 1, 1, 1, 1, 2, 3, + 3, 0, 1, 1, 1, 1, 1, 2, 2, 2, + 2, 2, 1, 3, 0, 1, 1, 1, 1, 5, + 2, 1, 1, 1, 1, 5, 2, 2, 2, 1, + 3, 3, 2, 1, 0, 3, 0, 5, 2, 5, + 2, 1, 2, 3, 0, 1, 1, 1, 1, 1, + 1, 3, 3, 3, 3, 3, 3, 3, 0, 1, + 4, 1, 3, 3, 5, 2, 2, 3, 3, 3, + 3, 3, 3, 3, 3, 3, 3, 2, 2, 3, + 3, 2, 3, 5, 4, 6, 3, 5, 4, 6, + 4, 6, 5, 7, 3, 2, 4, 2, 3, 3, + 4, 3, 4, 3, 4, 5, 6, 6, 7, 6, + 7, 6, 7, 3, 4, 4, 6, 2, 3, 4, + 1, 3, 2, 2, 3, 3, 3, 3, 3, 3, + 3, 3, 3, 3, 2, 2, 5, 6, 6, 7, + 3, 4, 1, 1, 2, 4, 1, 1, 1, 2, + 2, 2, 1, 4, 5, 6, 8, 6, 7, 7, + 5, 5, 1, 1, 4, 1, 4, 1, 4, 1, + 4, 1, 1, 1, 1, 1, 1, 6, 4, 4, + 4, 4, 6, 5, 5, 5, 4, 6, 4, 4, + 4, 4, 5, 7, 7, 9, 5, 4, 6, 5, + 7, 7, 7, 2, 3, 3, 3, 4, 0, 4, + 1, 3, 3, 1, 1, 1, 2, 2, 0, 2, + 4, 4, 6, 2, 0, 1, 3, 3, 2, 2, + 0, 6, 1, 0, 3, 0, 2, 2, 0, 1, + 4, 2, 2, 2, 2, 2, 4, 3, 5, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 4, 1, 4, 1, 4, 1, + 2, 1, 2, 1, 3, 1, 3, 1, 3, 1, + 3, 3, 3, 2, 1, 3, 3, 0, 1, 1, + 1, 1, 1, 1, 1, 1, 4, 3, 2, 3, + 0, 3, 3, 2, 2, 1, 0, 2, 2, 3, + 2, 1, 1, 3, 5, 1, 2, 4, 2, 0, + 1, 0, 1, 2, 2, 2, 3, 5, 1, 2, + 0, 2, 1, 0, 1, 1, 1, 3, 3, 1, + 3, 3, 2, 1, 1, 1, 3, 1, 2, 1, + 3, 1, 1, 1, 1, 1, 1, 1, 2, 1, + 1, 1, 1, 1, 2, 5, 2, 3, 6, 1, + 1, 1, 1, 1, 1, 1, 2, 2, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1 +}; + +/* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state + STATE-NUM when YYTABLE doesn't specify something else to do. Zero + means the default is an error. */ +static const yytype_uint16 yydefact[] = +{ + 1329, 1130, 511, 1214, 1213, 1130, 232, 0, 1216, 0, + 1130, 340, 908, 0, 0, 0, 0, 511, 1130, 0, + 1329, 0, 0, 0, 0, 1342, 0, 0, 0, 0, + 0, 0, 0, 0, 1130, 0, 0, 1349, 0, 0, + 0, 0, 1342, 0, 1218, 0, 0, 0, 0, 2, + 4, 56, 57, 23, 22, 28, 27, 79, 80, 46, + 16, 70, 51, 112, 111, 113, 34, 30, 64, 20, + 21, 31, 35, 53, 36, 52, 19, 50, 74, 54, + 77, 41, 10, 11, 42, 68, 12, 43, 69, 13, + 44, 14, 58, 81, 26, 55, 78, 37, 66, 62, + 9, 47, 48, 49, 71, 72, 73, 95, 76, 107, + 33, 104, 85, 86, 101, 87, 102, 7, 88, 45, + 15, 98, 97, 99, 65, 38, 67, 96, 100, 17, + 18, 103, 75, 93, 90, 108, 106, 114, 91, 59, + 5, 6, 82, 40, 8, 25, 24, 39, 32, 110, + 29, 1216, 84, 94, 83, 60, 89, 63, 92, 109, + 61, 105, 1316, 1303, 1351, 1315, 1328, 0, 1318, 1129, + 1128, 1114, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 510, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1140, 1848, + 1859, 1860, 1861, 1862, 1863, 1864, 1865, 1866, 315, 1867, + 1868, 1869, 1870, 1871, 1872, 1873, 1874, 1875, 1876, 2109, + 2110, 2111, 2112, 1877, 1878, 1879, 1880, 1881, 1882, 1883, + 2113, 2114, 1884, 1885, 1886, 1887, 1888, 2115, 1889, 1890, + 1891, 1892, 1893, 1894, 1895, 1896, 1897, 1898, 1899, 1900, + 1901, 1902, 1903, 1904, 1905, 1906, 1907, 1908, 2116, 2117, + 1909, 1910, 1911, 1912, 1913, 1914, 1915, 1916, 1917, 1918, + 1919, 1920, 1921, 1922, 1923, 1924, 1925, 1926, 1927, 1928, + 1929, 1930, 1931, 1932, 2118, 1933, 1934, 1935, 2119, 1936, + 1937, 2120, 1938, 1939, 1940, 1941, 1942, 1943, 1944, 2121, + 1945, 1946, 1947, 1948, 1949, 1950, 1951, 1952, 1953, 1954, + 1955, 1956, 1957, 1958, 1959, 1960, 2122, 1961, 1962, 1963, + 1964, 2123, 2124, 2125, 1965, 1966, 1967, 1968, 1969, 1970, + 1971, 1972, 1973, 1974, 2126, 1975, 1976, 1977, 1978, 1979, + 1980, 1981, 1982, 1983, 1984, 1985, 1986, 1987, 1988, 1989, + 1990, 2127, 2128, 1991, 1992, 2129, 1993, 1994, 1995, 2130, + 1996, 2131, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2132, + 2133, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2134, + 2012, 2135, 2015, 2013, 2014, 2016, 2017, 2018, 2019, 2020, + 2021, 2022, 2136, 2023, 2024, 2025, 2026, 2027, 2028, 2029, + 2030, 2031, 2032, 2033, 2034, 2035, 2036, 2037, 2038, 2039, + 2040, 2137, 2041, 2042, 2043, 2044, 2045, 2046, 2047, 2048, + 2049, 2050, 2051, 2052, 2053, 2054, 2138, 2055, 2056, 2057, + 2139, 2058, 2059, 2060, 2061, 2062, 2063, 2064, 2065, 2066, + 2067, 2068, 2140, 2069, 2070, 2071, 2072, 2073, 2074, 2075, + 2076, 2141, 2142, 2077, 2143, 2078, 2144, 2079, 2080, 2081, + 2082, 2083, 2084, 2085, 2086, 2087, 2088, 2089, 2090, 2091, + 2092, 2093, 2094, 2095, 2145, 2146, 2096, 2097, 2098, 2099, + 2100, 2101, 2102, 2103, 2104, 2105, 2147, 2148, 2149, 2150, + 2151, 2152, 2153, 2154, 2155, 2106, 2107, 2108, 314, 1294, + 1821, 1849, 1850, 1215, 1196, 511, 0, 1117, 339, 0, + 0, 0, 0, 0, 0, 0, 0, 691, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 158, 0, 0, + 363, 362, 0, 0, 0, 880, 368, 0, 0, 0, + 0, 499, 1256, 2013, 1254, 1295, 233, 236, 234, 235, + 1843, 0, 980, 981, 983, 0, 0, 993, 724, 725, + 0, 723, 727, 0, 0, 0, 720, 0, 0, 0, + 0, 726, 718, 0, 717, 0, 0, 0, 722, 0, + 719, 0, 0, 1118, 1253, 369, 1329, 0, 1232, 1216, + 1223, 1233, 1228, 1230, 1229, 1231, 1227, 1842, 1860, 819, + 819, 819, 819, 816, 817, 819, 819, 819, 2028, 0, + 0, 798, 0, 800, 1845, 819, 824, 424, 424, 424, + 0, 823, 828, 424, 1111, 1147, 1826, 1341, 0, 799, + 1110, 2077, 1245, 0, 0, 997, 0, 998, 0, 2043, + 1122, 217, 2053, 2141, 2077, 213, 187, 1864, 0, 0, + 823, 0, 1119, 1120, 784, 1348, 1346, 0, 1882, 1895, + 1978, 210, 2039, 2044, 2053, 2141, 2077, 2105, 167, 172, + 0, 226, 2053, 2141, 2077, 222, 1140, 0, 1319, 1428, + 1817, 0, 1113, 1112, 1217, 0, 1220, 0, 1393, 2025, + 1323, 1325, 1222, 1316, 0, 0, 1, 1329, 1211, 1345, + 1345, 0, 1345, 0, 1308, 1316, 1311, 1315, 0, 0, + 0, 0, 1848, 2156, 2157, 2158, 2159, 2160, 2161, 2162, + 2163, 2164, 2165, 2166, 2167, 2168, 2169, 2170, 2171, 2172, + 2173, 2174, 2175, 2176, 2177, 2178, 0, 0, 1827, 1849, + 1853, 0, 734, 0, 118, 1822, 868, 0, 0, 0, + 1821, 0, 0, 0, 0, 0, 1844, 1950, 0, 0, + 1722, 1886, 1936, 1732, 1730, 1731, 1724, 1725, 1726, 1727, + 1728, 1729, 0, 978, 1723, 0, 118, 0, 1950, 0, + 0, 1950, 0, 0, 0, 0, 0, 1981, 118, 1950, + 0, 0, 1134, 0, 0, 0, 1136, 1139, 1115, 1199, + 0, 1817, 0, 0, 768, 759, 0, 769, 760, 765, + 771, 0, 0, 762, 0, 0, 772, 0, 761, 763, + 774, 764, 770, 0, 0, 766, 767, 0, 0, 1126, + 424, 0, 0, 0, 0, 0, 0, 118, 1186, 1950, + 118, 0, 0, 367, 366, 118, 365, 364, 1886, 1936, + 0, 907, 118, 0, 160, 579, 514, 0, 0, 650, + 1981, 118, 0, 0, 0, 0, 883, 0, 0, 498, + 511, 1257, 1255, 0, 984, 212, 211, 982, 1950, 0, + 293, 0, 0, 1950, 1175, 0, 721, 1950, 0, 1950, + 153, 1819, 0, 1886, 1936, 1950, 0, 0, 1950, 145, + 1950, 0, 1950, 293, 1950, 515, 0, 1950, 0, 1950, + 1981, 147, 0, 1950, 293, 732, 0, 1250, 0, 1225, + 2145, 1239, 1238, 0, 1234, 1242, 1237, 1329, 819, 818, + 0, 819, 0, 819, 0, 819, 0, 819, 0, 0, + 0, 819, 1846, 1847, 801, 0, 825, 0, 0, 832, + 831, 830, 0, 0, 0, 833, 1432, 1272, 0, 1108, + 1125, 0, 0, 0, 1000, 1000, 1000, 1121, 216, 214, + 0, 0, 0, 0, 0, 0, 1127, 0, 0, 0, + 0, 1830, 1832, 1833, 1733, 1800, 0, 2110, 2111, 2112, + 1791, 0, 2113, 2114, 2115, 2158, 1645, 1632, 1641, 1646, + 1633, 1635, 1642, 2116, 2117, 1921, 2118, 2119, 1840, 2120, + 2121, 2123, 2124, 2125, 2126, 1637, 1639, 2127, 2128, 0, + 1841, 2130, 2131, 2001, 2133, 2134, 2136, 2137, 1643, 2139, + 2140, 2141, 2142, 2143, 2144, 1839, 0, 1644, 2146, 2148, + 2149, 2150, 2151, 2152, 2153, 2154, 2155, 0, 0, 1814, + 0, 1618, 0, 1464, 1465, 1487, 1488, 1466, 1493, 1494, + 1506, 1467, 0, 1813, 1531, 1617, 1622, 0, 1616, 1612, + 1331, 1809, 0, 1613, 1829, 1831, 1792, 179, 228, 0, + 229, 1815, 2053, 168, 209, 181, 208, 182, 180, 0, + 1884, 169, 0, 0, 170, 0, 0, 0, 0, 225, + 223, 0, 1116, 0, 1430, 1429, 0, 0, 1798, 1818, + 741, 1209, 1210, 1208, 0, 1205, 1207, 1219, 1216, 1805, + 1804, 1806, 0, 1324, 0, 0, 0, 1306, 1305, 3, + 1222, 1343, 1344, 0, 0, 0, 0, 0, 0, 0, + 0, 1386, 1359, 1360, 1362, 1383, 1387, 0, 1312, 0, + 0, 1434, 0, 1394, 0, 0, 1828, 0, 0, 0, + 0, 735, 0, 0, 0, 0, 0, 0, 117, 1173, + 219, 1171, 0, 0, 0, 0, 0, 0, 0, 1178, + 0, 151, 152, 526, 511, 0, 1950, 0, 0, 0, + 0, 940, 947, 0, 0, 0, 0, 0, 0, 0, + 941, 939, 942, 221, 951, 964, 967, 0, 858, 0, + 0, 0, 0, 1043, 0, 0, 1043, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 239, 245, + 288, 491, 0, 0, 493, 0, 0, 0, 0, 0, + 0, 0, 122, 0, 0, 0, 0, 0, 478, 490, + 0, 0, 0, 0, 0, 487, 0, 118, 241, 471, + 475, 0, 0, 0, 588, 587, 0, 1043, 0, 237, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 307, 308, 0, 0, 0, + 122, 144, 0, 0, 0, 243, 0, 0, 1135, 1132, + 1133, 0, 1138, 0, 1195, 0, 0, 0, 0, 0, + 773, 0, 0, 1886, 1936, 0, 0, 0, 0, 0, + 0, 342, 321, 322, 118, 320, 0, 0, 647, 0, + 1851, 1475, 1504, 1482, 1504, 1504, 1471, 1471, 1484, 1472, + 1473, 1511, 0, 1504, 1471, 1476, 0, 1474, 1514, 1514, + 1499, 0, 1456, 1457, 1458, 1459, 1485, 1486, 1460, 1491, + 1492, 1461, 1528, 1471, 1852, 0, 0, 658, 0, 1150, + 1185, 0, 0, 520, 0, 1950, 0, 120, 692, 0, + 648, 0, 120, 0, 156, 0, 583, 0, 0, 0, + 0, 0, 0, 608, 607, 0, 0, 0, 649, 0, + 120, 474, 1950, 0, 424, 424, 0, 882, 885, 0, + 0, 0, 1298, 1300, 1299, 0, 1297, 0, 293, 291, + 292, 645, 992, 0, 0, 0, 0, 293, 0, 0, + 1950, 293, 1950, 0, 1950, 0, 0, 293, 293, 0, + 0, 0, 0, 584, 0, 731, 729, 728, 730, 0, + 0, 0, 0, 0, 1950, 293, 0, 0, 714, 1743, + 0, 0, 1329, 0, 198, 199, 197, 1240, 200, 1241, + 1236, 1224, 0, 809, 0, 813, 0, 804, 0, 810, + 0, 805, 802, 803, 0, 808, 0, 0, 425, 427, + 0, 0, 1906, 1920, 0, 1941, 1969, 1970, 2044, 2049, + 0, 2072, 2081, 0, 834, 863, 829, 0, 0, 1282, + 1109, 1749, 0, 1329, 0, 999, 996, 995, 994, 215, + 188, 0, 0, 0, 865, 2043, 1124, 783, 511, 0, + 1614, 0, 1620, 1621, 1503, 1490, 1790, 0, 0, 1498, + 1497, 0, 0, 0, 0, 0, 1480, 1479, 1478, 1619, + 1757, 0, 1477, 0, 0, 0, 0, 1504, 1504, 1502, + 1551, 0, 1481, 0, 0, 1770, 0, 1776, 0, 0, + 0, 1510, 0, 1508, 0, 0, 1587, 0, 0, 0, + 0, 0, 0, 0, 0, 1535, 1536, 1618, 1743, 0, + 1836, 0, 0, 1496, 0, 1528, 1812, 1733, 0, 0, + 0, 0, 1803, 0, 1741, 0, 0, 1565, 1739, 0, + 1567, 0, 0, 0, 1732, 1730, 1731, 1724, 1725, 1726, + 1727, 1728, 1729, 1737, 1548, 0, 0, 1547, 0, 0, + 1396, 0, 1834, 1793, 230, 231, 227, 0, 0, 184, + 183, 0, 202, 206, 207, 178, 205, 0, 201, 186, + 1685, 1684, 185, 177, 175, 173, 189, 191, 192, 176, + 174, 224, 0, 0, 1854, 2179, 2180, 2181, 2182, 2183, + 2184, 2185, 2186, 2187, 2188, 2189, 2190, 2191, 2192, 2193, + 2194, 2195, 2196, 2197, 2198, 2199, 2200, 2201, 2202, 2203, + 2204, 2205, 2206, 2207, 2208, 2209, 2210, 2211, 2212, 2213, + 2214, 2215, 2216, 2217, 2218, 2219, 2220, 2221, 2222, 2223, + 2224, 2225, 2226, 2227, 2228, 2229, 2230, 2231, 2232, 2233, + 2234, 2235, 2236, 2237, 2238, 2239, 2240, 2241, 2242, 2243, + 2244, 2245, 2246, 2247, 2248, 2249, 2250, 2251, 2252, 2253, + 2254, 1795, 1794, 1824, 1855, 1856, 1857, 1858, 1799, 0, + 0, 293, 1203, 0, 1200, 1808, 0, 1326, 0, 0, + 1212, 1322, 1321, 1352, 1353, 900, 1320, 1377, 1378, 1373, + 0, 1392, 1392, 1369, 1363, 1368, 1366, 0, 1370, 1531, + 1385, 1310, 1357, 1358, 1361, 1309, 0, 1388, 1386, 1362, + 1269, 0, 0, 1435, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 736, 0, 0, 0, 0, 0, 0, + 2072, 218, 1169, 0, 0, 0, 0, 867, 866, 0, + 0, 887, 0, 0, 0, 1181, 413, 0, 290, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 524, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 558, 0, 1043, 0, 596, + 0, 949, 0, 948, 0, 0, 0, 950, 945, 946, + 2044, 2053, 2077, 220, 966, 0, 965, 963, 922, 924, + 923, 0, 926, 910, 0, 911, 0, 0, 921, 929, + 927, 0, 0, 0, 0, 1929, 247, 260, 0, 1042, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 280, 0, 283, 282, 0, 0, 0, 0, 287, 0, + 0, 0, 286, 0, 0, 492, 0, 0, 0, 0, + 0, 0, 0, 979, 0, 0, 139, 142, 0, 0, + 0, 477, 489, 0, 481, 482, 479, 483, 484, 0, + 0, 0, 0, 0, 0, 476, 0, 0, 581, 580, + 586, 0, 0, 0, 0, 0, 0, 0, 1035, 1034, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 599, 600, 0, 601, 0, 143, + 0, 0, 0, 0, 0, 0, 0, 196, 1131, 1137, + 1198, 1825, 1197, 0, 0, 0, 775, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 326, 1851, 0, 673, 646, 0, 1456, + 0, 1452, 1448, 1517, 1518, 1519, 1516, 1529, 1515, 0, + 1462, 1520, 1471, 1468, 659, 0, 661, 664, 0, 1148, + 386, 0, 517, 558, 0, 0, 0, 149, 0, 0, + 0, 116, 160, 369, 0, 159, 161, 163, 164, 165, + 162, 166, 578, 582, 0, 513, 0, 0, 0, 0, + 0, 609, 613, 612, 616, 614, 0, 610, 0, 0, + 1444, 0, 138, 470, 473, 0, 0, 0, 371, 455, + 300, 0, 0, 884, 0, 0, 0, 0, 0, 0, + 0, 1296, 0, 970, 0, 1176, 1950, 293, 0, 968, + 154, 1820, 0, 715, 0, 0, 0, 0, 0, 972, + 711, 146, 0, 293, 293, 516, 0, 293, 148, 0, + 0, 0, 508, 293, 733, 1252, 0, 424, 1226, 1235, + 806, 815, 814, 812, 811, 807, 0, 826, 0, 423, + 0, 0, 0, 840, 841, 0, 0, 839, 856, 842, + 0, 844, 836, 835, 845, 846, 0, 0, 865, 0, + 1279, 0, 1277, 0, 1433, 1281, 1270, 1244, 0, 1243, + 1247, 1249, 1248, 1246, 0, 0, 0, 823, 0, 0, + 293, 1123, 0, 785, 786, 791, 0, 0, 0, 792, + 788, 789, 790, 793, 794, 795, 0, 0, 0, 1801, + 1753, 0, 1754, 0, 0, 0, 1789, 1785, 0, 0, + 0, 0, 0, 0, 1758, 1761, 1762, 1763, 1760, 1764, + 1759, 0, 0, 1765, 0, 0, 0, 0, 0, 1501, + 1500, 0, 0, 0, 0, 0, 0, 0, 1590, 1622, + 0, 0, 1717, 0, 1743, 1775, 0, 0, 1512, 0, + 0, 0, 0, 0, 0, 0, 1743, 1781, 0, 0, + 0, 0, 1683, 0, 1680, 0, 0, 0, 0, 1800, + 0, 0, 0, 0, 1837, 1532, 1549, 1811, 0, 1802, + 0, 0, 1533, 1556, 0, 1782, 1583, 0, 1588, 1571, + 0, 1564, 0, 1569, 1573, 1552, 1803, 1742, 0, 1740, + 0, 0, 1550, 0, 1545, 1543, 1544, 1537, 1538, 1539, + 1540, 1541, 1542, 1546, 1721, 1719, 1720, 0, 0, 0, + 1568, 1943, 1978, 0, 1342, 1342, 1342, 1330, 1340, 1810, + 0, 1439, 0, 0, 0, 0, 1700, 0, 1747, 0, + 1745, 1827, 1816, 0, 0, 1528, 0, 1431, 1796, 0, + 739, 740, 738, 1222, 1206, 1202, 1201, 1807, 1221, 1329, + 0, 898, 899, 0, 903, 0, 0, 1371, 1384, 0, + 1282, 1282, 0, 1375, 1376, 1367, 1314, 1313, 0, 1442, + 0, 0, 1266, 1259, 1436, 0, 1396, 1284, 1286, 1287, + 0, 1800, 671, 670, 0, 0, 0, 1069, 1002, 1047, + 737, 1070, 1003, 1048, 1071, 1004, 1170, 0, 1172, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 634, 1950, 293, 1179, 1072, 0, 1005, + 289, 1180, 1049, 1184, 1050, 0, 525, 0, 0, 530, + 531, 532, 0, 0, 533, 1886, 1936, 0, 538, 544, + 548, 539, 0, 549, 545, 0, 0, 0, 0, 0, + 0, 555, 562, 0, 0, 0, 0, 0, 0, 943, + 944, 1073, 1008, 0, 1051, 925, 1471, 909, 0, 0, + 920, 0, 919, 1471, 1471, 1009, 150, 0, 240, 248, + 564, 1045, 266, 279, 274, 275, 273, 1950, 293, 1950, + 293, 0, 0, 0, 0, 276, 271, 272, 268, 281, + 1863, 1922, 2054, 0, 568, 570, 0, 575, 284, 1021, + 0, 301, 304, 285, 264, 267, 265, 261, 246, 0, + 0, 1823, 0, 0, 974, 0, 0, 0, 141, 1031, + 131, 0, 0, 127, 0, 0, 0, 0, 121, 1079, + 1013, 0, 0, 242, 472, 480, 485, 1017, 488, 1061, + 486, 1085, 1014, 1043, 0, 238, 0, 1015, 0, 1055, + 1081, 1033, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1187, 0, 0, 0, 0, 0, 293, 0, 680, + 1045, 1950, 293, 1080, 0, 1040, 1067, 0, 309, 0, + 1032, 0, 0, 244, 1019, 1063, 0, 0, 194, 193, + 195, 0, 0, 0, 0, 0, 0, 0, 0, 777, + 748, 776, 0, 0, 0, 0, 0, 0, 0, 742, + 341, 318, 319, 0, 0, 317, 323, 0, 672, 0, + 0, 1453, 1449, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1469, 660, 0, 0, 0, 0, 1168, 1168, + 1168, 1168, 1168, 1168, 1168, 1149, 1177, 118, 0, 0, + 0, 519, 557, 564, 0, 592, 595, 0, 593, 0, + 0, 0, 0, 0, 132, 119, 0, 700, 424, 155, + 0, 0, 0, 512, 657, 655, 654, 656, 0, 0, + 0, 677, 653, 0, 1443, 1445, 0, 0, 0, 469, + 373, 0, 0, 370, 374, 378, 379, 380, 427, 0, + 0, 459, 0, 0, 0, 0, 914, 0, 932, 915, + 0, 0, 0, 954, 959, 955, 935, 0, 496, 1301, + 1302, 0, 293, 0, 0, 559, 293, 293, 0, 293, + 0, 293, 293, 0, 1106, 585, 0, 642, 0, 0, + 293, 713, 1744, 827, 426, 0, 0, 0, 0, 838, + 0, 494, 843, 0, 855, 850, 852, 0, 859, 1280, + 1273, 1275, 1274, 0, 0, 1271, 1750, 712, 0, 0, + 293, 0, 860, 0, 787, 0, 0, 0, 0, 1347, + 1751, 1752, 0, 0, 0, 0, 1786, 0, 0, 1658, + 0, 1634, 1636, 1470, 1648, 0, 1483, 1659, 1660, 1638, + 1640, 0, 1734, 0, 0, 1649, 1592, 1593, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1605, 1604, 1650, 1716, 0, 0, 1773, 1774, 1651, + 1513, 1514, 1514, 0, 0, 1780, 0, 0, 0, 1656, + 1661, 0, 0, 0, 0, 1667, 0, 1688, 0, 0, + 0, 1615, 1744, 1505, 1506, 0, 0, 0, 0, 0, + 0, 0, 0, 1589, 1572, 1566, 0, 1570, 1574, 0, + 0, 0, 0, 1558, 1584, 1554, 0, 0, 1560, 0, + 1585, 1342, 1342, 1342, 1342, 1339, 0, 0, 0, 0, + 1406, 1395, 1397, 1408, 1399, 1401, 1437, 0, 1817, 0, + 1380, 1351, 1351, 0, 1700, 0, 1623, 0, 1700, 0, + 0, 171, 0, 203, 190, 0, 1204, 0, 1354, 0, + 1735, 903, 901, 902, 1356, 0, 0, 1391, 1390, 1389, + 1364, 1268, 0, 1266, 1261, 0, 1262, 1800, 0, 1258, + 1291, 0, 0, 1442, 0, 1290, 1068, 1001, 1046, 1168, + 870, 871, 0, 869, 0, 0, 0, 412, 886, 0, + 0, 0, 634, 0, 0, 416, 0, 1182, 0, 527, + 528, 0, 0, 546, 0, 0, 535, 0, 0, 0, + 0, 534, 551, 500, 552, 554, 0, 0, 553, 556, + 561, 1043, 0, 597, 1023, 0, 1065, 937, 0, 1471, + 912, 917, 918, 0, 0, 0, 386, 0, 0, 0, + 249, 259, 0, 0, 263, 0, 257, 277, 269, 278, + 270, 572, 573, 571, 567, 0, 574, 576, 298, 0, + 0, 0, 1075, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1076, 1052, 0, 0, 124, 123, + 0, 130, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 310, 295, 0, 0, 0, 0, + 0, 312, 0, 0, 0, 0, 1074, 1010, 743, 0, + 0, 744, 752, 0, 0, 745, 0, 0, 0, 0, + 0, 0, 754, 344, 0, 347, 354, 327, 331, 1186, + 0, 1186, 0, 332, 1186, 328, 1186, 325, 2001, 1724, + 1725, 668, 675, 665, 667, 669, 666, 0, 674, 634, + 0, 0, 0, 1454, 0, 1522, 1523, 1524, 1525, 1526, + 1527, 0, 1521, 1528, 662, 663, 0, 1168, 1167, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 398, 0, 0, 392, 0, 0, 959, 385, 388, 389, + 520, 523, 521, 522, 550, 0, 591, 0, 564, 134, + 0, 0, 135, 133, 0, 300, 369, 0, 0, 615, + 618, 611, 0, 676, 678, 651, 0, 564, 0, 1253, + 0, 465, 0, 455, 405, 451, 0, 453, 452, 454, + 0, 461, 299, 0, 0, 887, 913, 0, 0, 0, + 952, 956, 953, 0, 0, 928, 0, 936, 906, 1101, + 1102, 1099, 1100, 0, 0, 1293, 971, 0, 293, 969, + 716, 0, 707, 0, 709, 973, 293, 293, 602, 0, + 509, 0, 0, 0, 837, 857, 0, 853, 0, 0, + 820, 862, 1278, 1276, 865, 0, 821, 864, 0, 0, + 0, 0, 0, 1755, 1489, 0, 1788, 1784, 0, 1631, + 1756, 0, 1768, 1767, 1591, 1769, 0, 1610, 0, 0, + 1602, 1600, 1601, 1594, 1595, 1596, 1597, 1598, 1599, 1603, + 1778, 1777, 1771, 1772, 1509, 1507, 0, 1653, 1654, 1655, + 1779, 1662, 0, 1877, 1689, 1666, 1682, 1681, 0, 0, + 0, 1669, 0, 0, 1678, 0, 1718, 1495, 1528, 1534, + 0, 0, 1557, 1783, 1575, 0, 0, 0, 1553, 0, + 0, 0, 0, 1562, 1734, 0, 0, 0, 0, 0, + 0, 1333, 1332, 1338, 1316, 0, 1408, 0, 1407, 1419, + 0, 0, 1425, 1423, 0, 1425, 0, 1425, 0, 1400, + 0, 1402, 1419, 0, 1818, 1438, 0, 1382, 0, 0, + 1350, 0, 1700, 1630, 1703, 1698, 1699, 1748, 1624, 1835, + 0, 1746, 1700, 0, 1797, 1327, 0, 1355, 1372, 1365, + 1902, 1440, 1267, 0, 0, 1264, 1265, 0, 0, 1285, + 1266, 1288, 0, 876, 877, 875, 878, 0, 0, 0, + 634, 0, 0, 432, 0, 894, 894, 0, 0, 418, + 464, 959, 637, 0, 0, 0, 635, 293, 1006, 0, + 547, 0, 0, 543, 541, 540, 542, 501, 1084, 1007, + 0, 0, 0, 0, 938, 0, 930, 1022, 0, 383, + 0, 254, 1044, 0, 0, 0, 253, 0, 293, 293, + 569, 302, 303, 306, 0, 0, 0, 0, 0, 0, + 701, 684, 0, 0, 702, 703, 0, 0, 0, 976, + 977, 975, 128, 125, 126, 129, 1018, 1062, 1016, 0, + 1056, 1027, 1025, 0, 0, 0, 0, 0, 1083, 1039, + 1060, 1082, 1037, 1058, 1036, 1057, 1038, 1059, 1030, 0, + 1447, 682, 681, 0, 293, 293, 604, 1020, 1064, 0, + 746, 0, 0, 747, 758, 756, 755, 757, 749, 345, + 118, 0, 324, 0, 352, 0, 350, 349, 351, 0, + 338, 0, 0, 0, 0, 0, 644, 0, 0, 0, + 1450, 1455, 1530, 1463, 633, 0, 1159, 1158, 1157, 1161, + 1160, 1163, 1162, 1154, 1153, 1166, 1165, 1152, 1151, 1156, + 1155, 0, 390, 0, 396, 400, 401, 399, 391, 959, + 424, 463, 518, 0, 594, 589, 137, 136, 0, 0, + 0, 0, 620, 624, 652, 0, 1446, 598, 0, 371, + 469, 467, 0, 0, 376, 381, 382, 0, 459, 402, + 0, 455, 375, 0, 0, 466, 1146, 0, 0, 916, + 933, 934, 0, 0, 959, 958, 0, 503, 293, 560, + 293, 293, 1107, 643, 0, 849, 848, 847, 495, 0, + 851, 293, 0, 0, 0, 0, 0, 797, 778, 796, + 1787, 1647, 1657, 1766, 0, 0, 1611, 0, 0, 1652, + 2147, 0, 0, 0, 0, 1686, 1687, 1668, 0, 1992, + 1673, 0, 0, 0, 1838, 1581, 1579, 1576, 0, 1577, + 0, 0, 1559, 1555, 0, 1561, 1586, 1337, 1336, 1335, + 1334, 1410, 1417, 0, 1398, 0, 1424, 1420, 0, 1421, + 0, 0, 1422, 0, 0, 1417, 0, 0, 0, 0, + 1694, 1700, 1700, 1625, 1705, 1702, 0, 1627, 1528, 0, + 0, 1260, 1263, 0, 1292, 1283, 1174, 0, 0, 0, + 414, 0, 959, 0, 0, 0, 897, 897, 0, 959, + 463, 639, 638, 641, 636, 640, 1183, 0, 536, 537, + 1024, 0, 1066, 1028, 931, 0, 565, 250, 251, 252, + 255, 295, 262, 256, 0, 1077, 1011, 1053, 0, 0, + 690, 0, 0, 0, 0, 1078, 1012, 1054, 0, 0, + 0, 0, 1192, 0, 294, 295, 311, 1041, 0, 750, + 751, 326, 0, 348, 357, 0, 355, 329, 334, 0, + 336, 335, 330, 333, 1451, 0, 990, 990, 0, 634, + 1164, 0, 0, 387, 463, 431, 0, 393, 0, 0, + 0, 371, 564, 619, 0, 0, 0, 679, 373, 0, + 1251, 468, 372, 0, 0, 461, 0, 0, 0, 459, + 0, 456, 0, 460, 0, 1141, 0, 0, 957, 0, + 961, 0, 927, 904, 1439, 0, 507, 991, 708, 710, + 603, 854, 861, 293, 779, 780, 781, 782, 1606, 0, + 0, 0, 0, 1663, 0, 1664, 1691, 1690, 1670, 1674, + 0, 1671, 1672, 1578, 1582, 1580, 1563, 1409, 0, 0, + 1411, 0, 0, 1413, 1415, 0, 0, 0, 0, 0, + 1821, 1700, 1379, 1381, 0, 1317, 1628, 1629, 0, 1351, + 1700, 204, 1736, 1441, 1289, 855, 0, 293, 894, 463, + 433, 2001, 434, 893, 0, 895, 900, 900, 0, 463, + 634, 529, 0, 563, 0, 297, 305, 0, 0, 697, + 685, 0, 0, 704, 1026, 0, 0, 0, 0, 0, + 293, 753, 316, 343, 353, 0, 337, 990, 0, 987, + 986, 632, 0, 422, 394, 0, 442, 0, 564, 694, + 1146, 577, 621, 622, 617, 0, 0, 455, 451, 377, + 386, 360, 411, 410, 407, 406, 408, 409, 404, 403, + 0, 461, 457, 458, 0, 0, 0, 1194, 0, 888, + 960, 0, 0, 0, 502, 0, 0, 506, 497, 822, + 1607, 0, 1608, 0, 0, 0, 1676, 1675, 0, 1418, + 1427, 0, 1414, 1412, 1403, 0, 1405, 1693, 1695, 0, + 0, 1708, 1626, 872, 0, 873, 897, 437, 0, 896, + 903, 903, 424, 634, 415, 1029, 566, 0, 258, 0, + 688, 0, 699, 697, 0, 0, 1188, 0, 1189, 1190, + 1193, 313, 356, 985, 989, 988, 0, 0, 395, 428, + 429, 430, 0, 397, 438, 439, 0, 590, 0, 0, + 1142, 0, 0, 459, 455, 384, 450, 358, 0, 1143, + 0, 300, 0, 959, 962, 1105, 505, 504, 1609, 1679, + 1665, 1692, 1677, 1416, 0, 1404, 0, 0, 1704, 0, + 0, 0, 0, 900, 0, 634, 0, 891, 890, 431, + 417, 296, 0, 0, 695, 698, 686, 699, 706, 705, + 0, 0, 421, 0, 0, 0, 440, 0, 441, 462, + 693, 0, 623, 0, 461, 459, 1144, 1145, 461, 889, + 905, 1104, 1103, 1329, 1426, 1696, 1697, 2109, 1902, 2083, + 0, 1706, 1709, 1707, 1701, 293, 903, 0, 419, 435, + 442, 0, 0, 687, 1191, 624, 447, 0, 446, 0, + 444, 443, 683, 627, 361, 461, 1439, 1087, 1329, 1086, + 1088, 1096, 1093, 1095, 1094, 1092, 0, 1713, 1712, 1711, + 1715, 1714, 874, 892, 0, 634, 689, 696, 0, 445, + 449, 448, 629, 0, 625, 628, 630, 631, 359, 879, + 0, 1097, 1091, 1316, 1303, 0, 436, 420, 0, 605, + 0, 1089, 1329, 1710, 0, 626, 1090, 0, 627, 0, + 606 +}; + +/* YYDEFGOTO[NTERM-NUM]. */ +static const yytype_int16 yydefgoto[] = +{ + -1, 48, 49, 50, 51, 1169, 2057, 1936, 2704, 2705, + 52, 53, 1243, 54, 55, 56, 57, 58, 59, 60, + 1184, 61, 62, 853, 1384, 2065, 63, 1811, 669, 670, + 1655, 1656, 1998, 1657, 1645, 1085, 1468, 1203, 1171, 1204, + 65, 66, 1079, 1636, 67, 68, 69, 1228, 1229, 1179, + 1421, 3560, 4098, 1922, 2743, 2540, 2541, 70, 1285, 1286, + 71, 72, 2653, 1324, 2655, 2656, 3157, 509, 2022, 3580, + 3581, 3144, 3145, 3587, 3845, 3846, 73, 1381, 2732, 3243, + 2733, 3653, 2734, 3654, 2735, 3655, 2686, 3207, 3208, 3209, + 2736, 3659, 4038, 2737, 1826, 4118, 2099, 1490, 1488, 4016, + 3462, 3463, 4165, 4123, 4124, 4125, 4230, 3661, 2741, 3251, + 3665, 3867, 2443, 588, 1403, 3241, 75, 76, 2093, 1259, + 1260, 1943, 3161, 2792, 77, 870, 3022, 3906, 4057, 4058, + 78, 197, 79, 1388, 80, 81, 2052, 2691, 82, 1838, + 2456, 83, 84, 2481, 2482, 2483, 85, 86, 3046, 3805, + 1230, 2533, 2534, 2535, 2536, 3066, 87, 1386, 1265, 2074, + 88, 89, 90, 2056, 2697, 2698, 91, 92, 1986, 93, + 94, 95, 1396, 2086, 2087, 3643, 3874, 4024, 3876, 4263, + 4264, 3859, 3005, 3476, 96, 97, 98, 99, 1367, 2045, + 2046, 3162, 1155, 1328, 2025, 2026, 3232, 3233, 100, 101, + 3520, 3521, 539, 4129, 4102, 4176, 102, 103, 3524, 3525, + 104, 105, 106, 107, 108, 582, 914, 915, 1161, 109, + 1751, 110, 828, 2640, 111, 979, 2217, 3698, 112, 611, + 929, 930, 113, 114, 620, 2197, 622, 1503, 2794, 2795, + 3300, 2167, 753, 115, 116, 2178, 2200, 117, 1172, 1817, + 1818, 3457, 118, 540, 1408, 2102, 2438, 4048, 3464, 3786, + 3976, 2384, 2964, 119, 541, 1208, 1884, 2105, 2747, 2748, + 1886, 2357, 3264, 1888, 2749, 2754, 2755, 2756, 3260, 3268, + 3900, 3901, 120, 1206, 1877, 121, 122, 123, 1238, 772, + 124, 552, 553, 125, 4009, 126, 882, 127, 638, 1516, + 128, 1900, 3052, 129, 130, 131, 4239, 4270, 4271, 4272, + 3273, 4203, 132, 4241, 959, 134, 135, 136, 171, 796, + 797, 798, 137, 3895, 138, 139, 2049, 2685, 3189, 140, + 141, 1812, 2428, 142, 143, 144, 1371, 145, 146, 147, + 148, 1304, 149, 1114, 1115, 150, 151, 504, 686, 1118, + 1126, 152, 590, 923, 924, 925, 1470, 153, 962, 2189, + 591, 917, 155, 592, 2402, 2975, 2976, 2979, 593, 2399, + 158, 1509, 2183, 2186, 594, 2406, 2407, 2408, 2409, 2410, + 2981, 595, 613, 873, 2110, 596, 1051, 163, 164, 165, + 695, 690, 691, 167, 1630, 2347, 628, 1133, 657, 703, + 3420, 1763, 1764, 1784, 1785, 1142, 1143, 1774, 1776, 2386, + 1777, 2395, 1769, 3417, 3760, 1780, 1781, 1145, 1146, 2390, + 168, 2351, 2931, 2932, 2933, 3398, 3408, 3747, 3943, 2934, + 957, 1152, 2935, 2940, 2973, 2723, 2724, 2725, 1889, 2032, + 1352, 1052, 1353, 2043, 1053, 1552, 1355, 1054, 1055, 1056, + 1358, 1057, 1058, 1059, 1060, 1535, 1593, 1061, 1062, 1571, + 2040, 2041, 1459, 2257, 1064, 1065, 3364, 3722, 3711, 2283, + 2284, 1652, 3360, 2883, 3955, 4077, 4078, 3428, 3425, 3764, + 3959, 4161, 4211, 4212, 1066, 2337, 1623, 774, 1067, 3164, + 1625, 2277, 2359, 2360, 1796, 1533, 2223, 2241, 2242, 2254, + 2844, 2261, 2266, 2867, 2868, 2278, 2306, 1068, 2226, 2227, + 2827, 1537, 1069, 1108, 1109, 1530, 2301, 1121, 1122, 688, + 1070, 1071, 1504, 679, 3939, 891, 744, 2550, 1742, 800, + 625, 1072, 1073, 1074, 1075, 2796, 1234, 500, 738, 2537, + 501, 502, 740, 1747 +}; + +/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing + STATE-NUM. */ +#define YYPACT_NINF -3886 +static const int yypact[] = +{ + 6786, 938, 7718, -3886, -3886, 938, -3886, 46135, -25, 575, + 993, 136, 12006, 46542, 54275, 166, 243, 3646, 938, 54275, + 1856, 37181, 42065, 54275, 930, 729, 37181, 54275, 54682, 854, + 802, 55089, 46949, 40844, 1048, 54275, 965, 283, 55496, 47356, + 943, 47763, 729, 34352, 107, 936, 55903, 1500, 1366, 1059, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -25, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, 339, -3886, 709, 366, 1182, 659, 1126, -3886, + -3886, -3886, 38809, 54275, 54275, 54275, 1296, 54275, 54275, 145, + 38809, 54275, 56310, 1383, 31016, -3886, 54275, 54275, 56717, 54275, + 48170, 54275, 1343, 54275, 54275, 57124, 57531, 1469, 1098, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, 54275, 7096, 930, -3886, -3886, 54275, + 1349, 38809, 54275, 1312, 54275, 1391, 54275, -3886, 54275, 57938, + 223, 1363, 54275, 1454, 31436, 1452, 54275, 54275, 54275, 54275, + -3886, -3886, 1467, 54275, 54275, -3886, -3886, 58345, 1050, 1681, + 1670, 733, -3886, 48577, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, 48984, 243, -3886, -3886, 39216, 54275, 1772, -3886, -3886, + 58752, -3886, -3886, 235, 39623, 59159, 1872, 31856, 1939, 59566, + 59973, -3886, -3886, 60380, -3886, 60787, 1688, 61194, -3886, 61601, + -3886, 1809, 62008, -3886, 1584, 1174, 749, 28118, -3886, -25, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, 388, 996, + 186, 182, 192, -3886, -3886, 185, 215, 218, 388, 2006, + 2006, -3886, 54275, -3886, -3886, 996, 17, 1607, 1607, 1607, + 1791, -34, -3886, 1607, -3886, -3886, -3886, -3886, 47763, -3886, + 1611, 930, 1619, 2013, 54275, -3886, 54275, -3886, 54275, 54275, + -3886, -3886, 2027, 1668, 1897, 1666, -3886, 1850, 1863, 1899, + 66, 930, 1800, -3886, 2011, -3886, 1923, 18884, 930, 49391, + 62415, 359, 48984, 930, 49798, 1777, 1177, 1932, -3886, -3886, + 395, -3886, 2161, 1812, 2020, 1666, 1098, 28944, -3886, 1798, + 1390, 47763, -3886, -3886, -3886, 212, 2093, 19308, -3886, 54275, + 1836, -3886, 1855, 1866, 1890, 1182, -3886, 6786, 54275, 298, + 298, 2271, 298, 983, 1477, -3886, 1480, -3886, 2191, 2156, + 47763, 936, 194, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, 1921, 1390, -3886, 198, + -3886, 1409, 1934, 1548, 1147, -3886, -3886, 179, 2032, 188, + 828, 1981, 50205, 3255, 1969, 224, -3886, 2263, 4857, 368, + -3886, 54275, 54275, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, 1995, -3886, -3886, 1987, 81, 711, 2278, 3188, + 1091, 2290, 4945, 1388, 708, 2187, 826, 2293, 1412, 2301, + 5697, 54275, -3886, 2233, 2336, 56, -3886, 176, -3886, 2069, + 2198, 563, 38809, 2019, -3886, -3886, 54275, -3886, -3886, -3886, + -3886, 354, 38809, -3886, 2207, 32276, -3886, 54275, -3886, -3886, + -3886, -3886, -3886, 2140, 54275, -3886, -3886, 2255, 54275, -3886, + 1607, 214, 2028, 2393, 70918, 140, 54275, 2065, 2427, 2227, + 2065, 2076, 62822, -3886, -3886, 2065, -3886, -3886, 54275, 54275, + 2034, 1125, 2065, 2434, 2435, 2113, 2217, 722, 271, 143, + 2332, 2065, 54275, 63229, 54275, 54275, 2406, 38809, 54275, -3886, + 2214, -3886, -3886, 1130, -3886, -3886, -3886, -3886, 2359, 1921, + 640, 2360, 2070, 2364, -3886, 2104, -3886, 2366, 1969, 2371, + 2078, -3886, 63636, 64043, 64450, 2375, 1995, 54275, 2376, 2078, + 2377, 2267, 2380, 640, 2382, -3886, 992, 2383, 2272, 2387, + 1471, 2078, 50612, 2388, 189, -3886, 21004, -3886, 2181, -3886, + 936, -3886, -3886, -43, -3886, 36774, -3886, 749, 996, -3886, + 54275, 996, 54275, 996, 54275, 996, 54275, 996, 54275, 54275, + 54275, 996, -3886, -3886, -3886, 54275, 2098, 54275, 54275, -3886, + -3886, -3886, 42879, 54275, 43286, -3886, -3886, 80, 930, -3886, + -3886, 70918, 2494, 54275, 2384, 2384, 2384, -3886, -3886, -3886, + 2322, 54275, 2386, 2391, 42879, 54275, -3886, 64857, 48984, 2298, + 2119, -3886, -3886, -3886, -3886, -3886, 1440, 2543, 260, 2544, + 21004, 2125, 174, 174, 2126, 2412, -3886, -3886, -3886, 222, + 2133, 2135, -3886, 219, 219, 2295, 2136, 2139, -3886, 238, + 2141, 2561, 2563, 242, 2144, 2145, 2146, 1417, 174, 21004, + -3886, 2148, 219, 2153, 2155, 2157, 2577, 2162, -3886, 2584, + 2164, 225, 344, 2165, 2166, -3886, 2136, -3886, 159, 2167, + 2169, 2171, 2172, 2173, 2174, 2175, 2176, 21004, 21004, -3886, + 18036, -3886, 930, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + 123, -3886, 244, 4128, -3886, -3886, 2347, 21004, -3886, -3886, + 36, -3886, 248, -3886, -3886, -3886, 1390, -3886, -3886, 252, + 2179, -3886, 1281, -3886, -3886, -3886, -3886, -3886, -3886, 44100, + 2573, -3886, 342, 930, 176, 1103, 2528, 35960, 36367, -3886, + -3886, 2409, -3886, 54275, -3886, -3886, 21004, 33945, -3886, 1390, + 125, -3886, -3886, -3886, 1333, -3886, -3886, -3886, -25, -3886, + 10197, -3886, 1404, 1836, 54275, 54275, 2585, -3886, -3886, -3886, + 1855, -3886, -3886, 1182, 1182, 21004, 1182, 195, 1003, 19732, + 21004, 2472, 2379, 184, 187, 2474, -3886, 983, 1477, 47763, + 54275, 65264, 2305, -3886, 35166, 1582, 1390, 2268, 2275, 2321, + 37995, 2202, 2279, 2282, 2329, 2286, 2288, 65671, -3886, -3886, + -3886, -3886, 1250, 753, 207, 2291, 335, 823, 2566, -3886, + 2340, -3886, -3886, -3886, 3831, 54275, 2511, 5731, 2404, 368, + 2341, -3886, -3886, 2448, 2302, 2304, 2416, 368, 1135, 66078, + -3886, -3886, -3886, -3886, -3886, -3886, 1806, 16406, -3886, 2309, + 2284, 54275, 40030, 2595, 2421, 43, 1577, 175, 54275, 2496, + 2430, 54275, 2247, 2324, 2325, 2252, 1458, 2607, 2254, -3886, + -3886, -3886, 1534, 2426, -3886, 2313, 2314, 69719, 1035, 32696, + 2589, 2339, -3886, 1265, 2344, 2345, 54275, 368, -3886, 2645, + 368, 368, 1317, 2650, 2349, 297, 1140, 2065, 2254, 1370, + -3886, 2350, 2351, 797, -3886, 2449, 47763, 220, 1647, 2254, + 2353, 2354, 2252, 2252, 54275, 54275, 54275, 54275, 54275, 165, + 2670, 2671, 2357, 156, 2403, 2281, -3886, 44507, 2361, 62415, + -3886, -3886, 54275, 2362, 1782, 2254, 1289, 1407, -3886, -3886, + -3886, 1098, -3886, 54275, -3886, 54275, 1921, 70918, 2470, 2323, + -3886, 1969, 368, 54275, 54275, 1995, 1007, 1051, 2471, 54275, + 2529, 2327, -3886, -3886, 2065, -3886, 35563, 2034, -3886, 2296, + -3886, -3886, 2352, -3886, 2352, 2352, 2297, 2297, 2310, -3886, + -3886, -3886, 1417, 2352, 2297, -3886, 71710, -3886, 1303, 1327, + -3886, 2696, 2708, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, 154, 1449, -3886, 54275, 37995, -3886, 2719, -3886, + -3886, 70918, 2606, -3886, 54275, 2512, 2317, -3886, 2642, 2389, + -3886, 2363, -3886, 54275, 247, 930, 2381, 54275, 2551, 54275, + 54275, 54275, 54275, -3886, -3886, 2525, 810, 137, -3886, 44507, + -3886, 1370, 2538, 2741, 607, 1607, 2628, -3886, 54275, 2355, + 2744, 2579, -3886, 1462, -3886, 2469, -3886, 38809, 640, -3886, + -3886, -3886, -3886, 70918, 54275, 66485, 38809, 640, 54275, 54275, + 2644, 189, 2646, 2408, 2652, 2410, 32696, 640, 258, 54275, + 54275, 54275, 54275, -3886, 54275, -3886, -3886, -3886, -3886, 54275, + 54275, 54275, 44507, 2654, 2655, 640, 54275, 54275, -3886, 10197, + 1498, 54275, 749, 43693, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, 54275, -3886, 54275, -3886, 54275, -3886, 54275, -3886, + 54275, -3886, -3886, -3886, 54275, -3886, 54275, 1505, -3886, -3886, + 1514, 133, 54275, 54275, 682, 38809, 54275, 2549, 54275, 54275, + 54275, 54275, 54275, 2433, 2179, 1131, -3886, 798, 47763, 2555, + -3886, -3886, 1519, 1500, 922, -3886, -3886, -3886, -3886, -3886, + -3886, 43286, 42065, 2648, 73, 54275, -3886, -3886, 2972, 21004, + 1390, 18460, -3886, -3886, -3886, 2378, 10197, 2413, 21004, -3886, + -3886, 21004, 2385, 2006, 2006, 21004, -3886, -3886, -3886, -3886, + 789, 2006, -3886, 21004, 21004, 2006, 2006, 2352, 2352, -3886, + 3608, 21004, -3886, 32696, 21004, 23548, 15576, 21004, 2442, 2394, + 2006, -3886, 2006, -3886, 21004, 17612, -3886, 21004, 2586, 24390, + 21004, 1103, 2588, 21004, 1103, 2797, 2797, 1282, 4430, 2395, + -3886, 2497, 2006, -3886, 2006, 164, -3886, 191, 70918, 21004, + 37995, 2463, 152, 54275, 21004, 2392, 1315, -3886, 21004, 833, + -3886, 2397, 21004, 2465, 21004, 21004, 21004, 21004, 21004, 21004, + 21004, 21004, 21004, -3886, 25216, 237, 578, 1851, 51019, 18884, + 2665, 15151, -3886, 251, -3886, -3886, -3886, 54275, 2573, -3886, + -3886, 2467, -3886, -3886, -3886, -3886, -3886, 256, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, 2400, -3886, -3886, -3886, -3886, + 2400, -3886, 2411, 3106, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, 2673, + 2675, 640, 54275, 212, 44914, -3886, 19308, -3886, 1555, 2417, + -3886, 2653, -3886, 2418, -3886, 7858, 2653, -3886, -3886, 266, + 2599, 2600, 2600, -3886, 2419, 10197, -3886, 1609, 10197, 1662, + -3886, -3886, -3886, -3886, -3886, -3886, 718, -3886, 2472, 187, + 2476, 672, 54275, -3886, 29357, 2425, 1565, 2501, 2502, 2550, + 54275, 54275, 54275, -3886, 37995, 54275, 54275, 54275, 54275, 54275, + 54275, -3886, 2783, 443, 42065, 2552, 41251, -3886, -3886, 2436, + 54275, 2486, 2666, 2668, 981, -3886, -3886, 66892, -3886, 2627, + 54275, 54275, 54275, 21004, 2629, 54275, 54275, 54275, 2513, 38809, + 2441, 54275, 54275, 54275, 399, 38809, 33116, 54275, 54275, 54275, + 54275, 2559, 54275, 54275, 2672, 1445, 47763, 326, 1786, 2254, + 2633, -3886, 1194, -3886, 54275, 54275, 2634, -3886, -3886, -3886, + 48984, 2835, 2548, -3886, -3886, 67299, -3886, -3886, 2622, -3886, + -3886, 71710, -3886, -3886, 1578, -3886, 71314, 67706, -3886, -3886, + 327, 54275, 54275, 6181, 54275, 1030, -3886, -3886, 70918, -3886, + 54275, 54275, 54275, 45321, 68102, 68509, 1166, 1226, 54275, 45728, + -3886, 54275, -3886, -3886, 38402, 54275, 54275, 37995, -3886, 54275, + 2637, 206, -3886, 54275, 2651, -3886, 2527, 54275, 54275, 2455, + 1589, 2537, 2580, -3886, 54275, 54275, 766, -3886, 54275, 54275, + 10528, -3886, -3886, 368, -3886, -3886, -3886, -3886, -3886, 54275, + 54275, 368, 54275, 368, 1168, -3886, 54275, 54275, -3886, -3886, + -3886, 6218, 54275, 54275, 54275, 54275, 54275, 54275, -3886, -3886, + 927, 931, 1049, 1149, 2601, 54275, 930, 54275, 68916, 54275, + 54275, 54275, 54275, 1376, -3886, -3886, 2574, -3886, 54275, 766, + 6743, 54275, 54275, 2540, 2542, 138, 2615, -3886, -3886, -3886, + -3886, -3886, -3886, 2706, 2868, 54275, -3886, 2709, 2711, 2530, + 2531, 2715, 814, 54275, 54275, 54275, 54275, 54275, 54275, 2718, + 814, 2667, 96, 2485, 2504, 1599, -3886, -3886, 21004, 2884, + 70918, 2491, 2498, 2568, 2571, 2572, -3886, 2492, 2575, 2006, + -3886, -3886, 1463, -3886, -3886, 1605, -3886, 2515, 810, 1769, + -3886, 54275, 105, 667, 2791, 16802, 2610, 1025, 2785, 54275, + 54275, 1025, -3886, 2240, 42065, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, 2784, -3886, 930, 2034, 2034, 2034, + 2034, -3886, -3886, -3886, -3886, 2690, 1606, -3886, 2507, 2034, + 54275, 2618, 1025, -3886, 1370, 2801, 809, 54275, 40437, 1558, + 2545, 930, 2692, -3886, 17216, 1986, 2698, 48984, 2789, 2796, + 2802, -3886, 1921, -3886, 2915, -3886, 2825, 640, 1969, -3886, + 2078, -3886, 54275, -3886, 54275, 54275, 54275, 54275, 1995, -3886, + -3886, 2078, 2716, 640, 640, -3886, 2720, 640, 2078, 2649, + 2819, 48984, -3886, 189, -3886, -3886, 21004, 1607, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, 1622, -3886, 54275, -3886, + 2798, 2803, 2804, 2078, 2546, 2582, 54275, 2553, -3886, 2078, + 368, 2078, 2179, 2179, 2078, 2546, 51426, 2948, 2822, 144, + -3886, 161, 901, 2754, -3886, -3886, -3886, -3886, 70918, -3886, + -3886, -3886, -3886, -3886, 54275, 87, 2734, 2556, 51426, 2933, + 640, -3886, 38809, -3886, -3886, -3886, 2647, 38809, 2749, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, 2795, 54275, 1642, -3886, + -3886, 1428, -3886, 1456, 21004, 21004, 269, -3886, 9151, 1652, + 21004, 2569, 2570, 1713, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, 2578, 2848, -3886, 2581, 1714, 1719, 2583, 2587, -3886, + -3886, 2414, 2590, 9434, 2592, 23548, 23548, 1337, -3886, -3886, + 23548, 2593, -3886, 1723, 8164, 2591, 2598, 2602, -3886, 2604, + 2605, 9479, 20156, 21004, 20156, 20156, 8784, 2591, 2608, 1730, + 37995, 2736, 10058, 1731, -3886, 21004, 37995, 3910, 21004, -3886, + 21004, 54275, 2611, 2612, -3886, -3886, 3608, -3886, 2603, -3886, + 23548, 23548, -3886, 2312, 18036, -3886, -3886, 2850, -3886, -3886, + 1580, -3886, 2616, -3886, -3886, 3809, 199, 21004, 2392, 21004, + 2657, 32696, 10851, 21004, 2952, 1985, 1985, 343, 343, 304, + 304, 304, 1764, 1851, -3886, -3886, -3886, 2617, 2162, 21004, + -3886, 1657, 1675, 54275, 1482, 2184, 2664, -3886, -3886, -3886, + 26466, 2624, 21004, 21004, 21004, 2614, 2752, 2991, 10197, 743, + -3886, 3002, -3886, 1098, 2006, 164, 36774, -3886, -3886, 21004, + -3886, -3886, -3886, 1855, -3886, -3886, -3886, -3886, -3886, 1500, + 21004, -3886, -3886, 491, 1562, 21004, 1609, -3886, -3886, 54275, + 2555, 2555, 21004, -3886, -3886, -3886, -3886, -3886, 26466, 2638, + 2636, 28531, 2729, -3886, -3886, 54275, 128, -3886, -3886, -3886, + 2620, -3886, -3886, -3886, 54275, 54275, 54275, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, 2821, -3886, 54275, + 54275, 2788, 54275, 2800, 2799, 21004, 768, 54275, 2625, 2626, + 1041, 2864, 54275, -3886, 2910, 640, -3886, -3886, 2694, -3886, + 10197, -3886, -3886, -3886, -3886, 48984, -3886, 1921, 70918, -3886, + -3886, -3886, 2659, 54275, -3886, 54275, 54275, 1995, -3886, -3886, + -3886, -3886, 1075, -3886, -3886, 54275, 54275, 110, 2705, 2707, + 54275, -3886, 1021, 2449, 7378, 54275, 54275, 54275, 2879, -3886, + -3886, -3886, -3886, 2828, -3886, -3886, 1449, -3886, 67706, 71314, + -3886, 71314, -3886, 1449, 1345, -3886, 2078, 2714, 2254, -3886, + 2817, 1052, -3886, -3886, -3886, -3886, -3886, 2934, 640, 2936, + 640, 54275, 54275, 54275, 54275, -3886, -3886, -3886, -3886, -3886, + 37995, 37995, 37995, 1735, -3886, -3886, 930, -3886, -3886, -3886, + 1736, -3886, 646, -3886, -3886, -3886, -3886, -3886, -3886, 54275, + 1586, -3886, 698, 70918, -3886, 70115, 54275, 54275, -3886, -3886, + -3886, 2863, 2808, -3886, 832, 2809, 54275, 2703, -3886, -3886, + -3886, 2723, 1804, 2254, 1370, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, 386, 1857, 2254, 2724, -3886, 2725, -3886, + -3886, -3886, 2866, 2869, 2870, 2728, 2732, 2780, 2742, 2745, + 2792, -3886, 2746, 2793, 2750, 2794, 2751, 640, 70918, 1685, + 2786, 2970, 640, -3886, 2758, -3886, -3886, 3069, -3886, 54275, + -3886, 2760, 1982, 2254, -3886, -3886, 54275, 54275, -3886, -3886, + -3886, 814, 70918, 2925, 814, 814, 54275, 54275, 814, -3886, + -3886, -3886, 2929, 2932, 2945, 2947, 2949, 2954, 814, -3886, + -3886, -3886, -3886, 214, 37995, -3886, 2509, 30596, -3886, 3122, + 4465, 2722, 2498, 2712, 2006, 167, 1039, 95, 2837, 2006, + 2927, 2726, -3886, -3886, 37995, 30596, 1639, 2942, 2747, 2747, + 2747, 2747, 2747, 2747, 2747, -3886, 2919, 2065, 48984, 54275, + 48984, -3886, 667, 2817, 54275, -3886, -3886, 1740, -3886, 54275, + 54275, 158, 54275, 2006, -3886, -3886, 2806, -3886, 1607, 247, + 2865, 1293, 3059, -3886, -3886, -3886, -3886, -3886, 54275, 54275, + 810, 930, -3886, 2731, 2733, -3886, 54275, 54275, 54275, 2769, + 2738, 54275, 2748, 2735, -3886, -3886, -3886, -3886, 70918, 35, + 2923, 2928, 2252, 3138, 2824, 54275, -3886, 1758, 119, -3886, + 930, 48984, 69323, -3886, 4225, -3886, -3886, 707, 3014, -3886, + -3886, 1500, 640, 70918, 54275, -3886, 640, 189, 2805, 640, + 2812, 640, 640, 54275, -3886, -3886, 54275, -3886, 54275, 44507, + 640, -3886, 10197, -3886, -3886, 2871, 2881, 2882, 54275, 2078, + 38809, -3886, 2761, 54275, 1172, -3886, -3886, 2941, -3886, -3886, + -3886, -3886, -3886, 3045, 3061, -3886, -3886, -3886, 54275, 42879, + 278, 54275, -3886, 1921, -3886, 1969, 368, 54275, 3003, -3886, + -3886, -3886, 2772, 1760, 10111, 21004, -3886, 3071, 70918, -3886, + 4743, -3886, -3886, -3886, -3886, 21004, -3886, -3886, -3886, -3886, + -3886, 21004, -3886, 21004, 3048, -3886, 3190, 3190, 70918, 23548, + 1495, 2153, 23548, 23548, 23548, 23548, 23548, 23548, 23548, 23548, + 23548, 25640, 559, -3886, -3886, 21004, 21004, 3057, 3048, -3886, + -3886, -69, -69, 70918, 2776, 2591, 2813, 2816, 21004, -3886, + -3886, 1780, 24803, 2823, 37995, -3886, 21004, 8752, 1784, 2826, + 10700, 1390, 5277, -3886, 3155, 930, 21004, 1542, 2048, 21004, + 1789, 21004, 3065, -3886, -3886, -3886, 2790, -3886, -3886, 70918, + 21004, 23548, 23548, 5018, -3886, 5415, 21004, 2829, 6306, 18036, + -3886, 729, 729, 729, 729, -3886, 54275, 54275, 54275, 26053, + 51833, 2827, 1748, -3886, 51833, 52240, -3886, 2807, 1390, 21004, + 3060, 42, 42, 2832, 2752, 29770, -3886, 21004, 228, 20580, + 2833, 176, 2838, -3886, -3886, 8019, -3886, 2839, -3886, 2841, + -3886, 1562, -3886, -3886, -3886, 5326, 2974, 2179, -3886, -3886, + -3886, 2827, 21428, 2729, -3886, 1796, -3886, -3886, 18884, -3886, + -3886, 1802, 29357, 2638, 19308, 1390, -3886, -3886, -3886, 2747, + 2078, 2078, 101, 2078, 3074, 101, 5379, -3886, -3886, 26879, + 54275, 54275, -3886, 54275, 1808, 932, 54275, -3886, 54275, -3886, + -3886, 3191, 54275, -3886, 2849, 2853, -3886, 54275, 54275, 54275, + 54275, -3886, -3886, 1934, -3886, -3886, 54275, 54275, -3886, -3886, + -3886, 390, 1994, 2254, -3886, 2872, -3886, -3886, 3047, 1474, + -3886, -3886, -3886, 2878, 54275, 2842, -3886, 791, 2252, 844, + -3886, -3886, 2888, 54275, -3886, 54275, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, 38402, -3886, -3886, -3886, 37995, + 30596, 37995, -3886, 2877, 2880, 2924, 628, 631, 2899, 2912, + 2964, 2847, 2854, 2857, -3886, -3886, 388, 930, -3886, -3886, + 930, 2078, 930, 54275, 54275, 54275, 54275, 54275, 54275, 54275, + 3132, 845, 1663, 54275, 54275, 54275, 54275, 54275, 54275, 54275, + 54275, 54275, 54275, 54275, -3886, 3221, 930, 930, 3192, 2931, + 54275, -3886, 54275, 2449, 54275, 54275, -3886, -3886, -3886, 2862, + 814, -3886, -3886, 3099, 3102, -3886, 814, 814, 814, 814, + 814, 814, -3886, 163, 1814, -3886, 27705, -3886, -3886, 2427, + 930, 2427, 1208, -3886, 2427, -3886, 2427, -3886, 2841, 2006, + 1534, -3886, -3886, -3886, -3886, -3886, -3886, 2504, -3886, -3886, + 2006, 1691, 2874, -3886, 2875, -3886, -3886, -3886, -3886, -3886, + -3886, 2867, -3886, 164, -3886, -3886, 54275, 2747, -3886, 1443, + 318, 771, 1089, 52647, 53054, 53461, 2883, 54275, 54275, 23548, + -3886, 853, 216, -3886, 3100, 54275, 2904, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, 2317, -3886, 54275, 2817, 2078, + 54275, 54275, 2078, -3886, 70918, 2545, 1174, 63229, 2911, 2885, + 3162, -3886, 2890, 2889, -3886, -3886, 54275, 2817, 620, 1584, + 230, -3886, 41658, 1558, -3886, 3134, 40437, -3886, -3886, -3886, + 3241, 2976, -3886, 1500, 930, 2486, -3886, 67706, 21004, 21004, + -3886, 2892, -3886, 2897, 3598, -3886, 2034, -3886, -3886, -3886, + -3886, -3886, -3886, 2966, 54275, -3886, -3886, 2898, 640, -3886, + -3886, 54275, -3886, 54275, -3886, -3886, 640, 640, -3886, 3008, + -3886, 54275, 54275, 54275, 2078, -3886, 368, -3886, 3171, 51426, + -3886, -3886, -3886, -3886, 73, 3177, -3886, -3886, 3137, 3139, + 3140, 3141, 855, -3886, -3886, 21004, 10197, -3886, 2902, -3886, + 10197, 5835, 10197, 3057, -3886, 1501, 3184, -3886, 1101, 2909, + 1501, 2120, 2120, 369, 369, 234, 234, 234, 3190, 559, + 10197, 10197, -3886, -3886, -3886, -3886, 2913, -3886, -3886, -3886, + 2591, -3886, 21852, 3051, 3291, -3886, -3886, -3886, 2953, 2955, + 2917, -3886, 21004, 22276, 2918, 71710, -3886, -3886, 164, 1415, + 23548, 23548, 2067, -3886, 435, 21004, 70918, 1824, 2067, 2338, + 2535, 21004, 21004, 6335, 255, 21004, 6627, 54275, 54275, 54275, + 54275, -3886, -3886, -3886, 15992, 1748, 2920, 54275, -3886, 2916, + 26466, 3156, 3095, -3886, 26466, 3095, 1346, 3095, 3157, -3886, + 30183, -3886, 2926, 15151, 1553, 10197, 3305, 3196, 21004, 2935, + -3886, 2937, 2752, -3886, 70511, -3886, -3886, 10197, -3886, -3886, + 21004, -3886, 2752, 930, -3886, -3886, 32696, -3886, -3886, -3886, + 3117, 10197, -3886, 1500, 54275, 1390, 2938, 2969, 54275, -3886, + 2729, -3886, 388, -3886, -3886, -3886, -3886, 3009, 42065, 3229, + -3886, 21004, 1830, -3886, 2994, 3322, 112, 1834, 1835, 932, + -3886, 2904, -3886, 1117, 3215, 336, -3886, 640, -3886, 70918, + -3886, 54275, 54275, -3886, -3886, -3886, -3886, 2202, -3886, -3886, + 54275, 54275, 54275, 54275, -3886, 3033, -3886, -3886, 37995, 2919, + 3159, -3886, -3886, 3164, 388, 54275, -3886, 70918, 640, 640, + -3886, -3886, -3886, 2989, 54275, 54275, 54275, 2006, 2006, 70918, + 2973, -3886, 2006, 2006, 2975, -3886, 54275, 54275, 54275, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, 3058, + -3886, -3886, -3886, 54275, 54275, 54275, 54275, 3275, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, 54275, + -3886, -3886, -3886, 70918, 640, 640, -3886, -3886, -3886, 3220, + -3886, 814, 814, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + 2065, 3302, -3886, 37995, -3886, 42472, -3886, -3886, -3886, 930, + -3886, 930, 3176, 34759, 930, 930, 932, 2990, 734, 3262, + -3886, -3886, -3886, -3886, 3266, 388, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + -3886, 21004, -3886, 841, 1501, -3886, -3886, -3886, -3886, 2904, + 1607, 3043, 105, 3103, -3886, -3886, 2078, 2078, 3052, 3390, + 660, 54275, 3301, 3037, -3886, 930, -3886, -3886, 54275, 40437, + 2769, -3886, 3331, 1847, -3886, -3886, -3886, 3036, 2928, 1287, + 3005, 1558, -3886, 811, 54275, -3886, 3040, 3283, 3010, -3886, + 10197, 10197, 930, 72106, 4225, -3886, 54275, 3256, 640, -3886, + 640, 640, -3886, -3886, 54275, 2078, 2078, 2078, -3886, 3186, + -3886, 640, 51426, 855, 855, 855, 855, -3886, -3886, -3886, + 10197, -3886, -3886, -3886, 23548, 3289, -3886, 3015, 70918, -3886, + 3022, 1848, 1858, 24390, 3165, -3886, -3886, -3886, 7101, 3070, + 10197, 3111, 3024, 3026, -3886, 819, 819, 435, 1864, -3886, + 23548, 23548, 2067, 2067, 21004, 2067, -3886, -3886, -3886, -3886, + -3886, 51833, 3028, 54275, 1748, 26466, -3886, -3886, 1820, -3886, + 26466, 3261, -3886, 26466, 54275, 3030, 54275, 783, 21004, 21004, + 3066, 2752, 2752, -3886, 3197, -3886, 3034, -3886, 164, 3039, + 54275, -3886, -3886, 936, -3886, -3886, -3886, 51426, 3214, 51426, + 932, 7411, 2904, 26879, 33536, 54275, 53868, 53868, 3181, 2904, + 3043, -3886, -3886, -3886, -3886, -3886, -3886, 3041, -3886, -3886, + -3886, 3118, -3886, -3886, -3886, 1873, -3886, -3886, -3886, -3886, + -3886, 3221, -3886, -3886, 30596, -3886, -3886, -3886, 27292, 32696, + -3886, 628, 3046, 3049, 631, -3886, -3886, -3886, 54275, 1185, + 942, 3077, 2078, 3326, -3886, 3221, -3886, -3886, 814, -3886, + -3886, 2485, 930, -3886, -3886, 1879, -3886, -3886, -3886, 54275, + -3886, 2885, -3886, -3886, -3886, 38809, 3442, 3442, 54275, -3886, + -3886, 7460, 3237, -3886, 3043, 3259, 3306, -3886, 54275, 54275, + 1500, 40437, 2817, -3886, 1224, 3054, 3348, -3886, 2738, 3062, + -3886, -3886, -3886, 41658, 3234, 2976, 952, 952, 54275, 2928, + 3182, -3886, 3187, -3886, 1133, -3886, 54275, 26879, -3886, 71314, + -3886, 1880, -3886, -3886, 2624, 54275, 762, -3886, -3886, -3886, + -3886, -3886, -3886, 278, -3886, -3886, -3886, -3886, 896, 23548, + 70918, 1894, 21004, -3886, 21004, -3886, 3437, -3886, -3886, -3886, + 605, -3886, -3886, -3886, 819, 819, 2067, -3886, 54275, 1900, + -3886, 21004, 3064, -3886, -3886, 26466, 1820, 1901, 54275, 1905, + 70918, 2752, 2591, 10197, 54275, -3886, -3886, -3886, 3440, 3240, + 2752, -3886, -3886, -3886, -3886, 1172, 101, 278, 3322, 3043, + -3886, 3067, -3886, -3886, 54275, -3886, 306, 306, 54275, 3043, + -3886, -3886, 54275, -3886, 37995, 3120, -3886, 70918, 1969, 78, + -3886, 70918, 70918, -3886, -3886, 54275, 54275, 54275, 54275, 54275, + 640, -3886, -3886, -3886, -3886, 42472, 2885, 3442, 268, -3886, + -3886, -3886, 1328, 3265, -3886, 153, 3250, 3158, 2817, 3359, + 3040, -3886, -3886, -3886, -3886, 21004, 3223, 1558, 3134, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + 1906, 2976, -3886, -3886, 3441, 3260, 3444, -3886, 1913, -3886, + -3886, 3598, 72106, 3389, -3886, 3130, 54275, -3886, -3886, -3886, + 896, 1925, -3886, 1926, 1931, 3225, 3133, -3886, 1940, -3886, + 10197, 54275, -3886, -3886, -3886, 1942, -3886, 3081, -3886, 3482, + 21004, 1288, -3886, -3886, 3365, -3886, 53868, 3127, 32696, -3886, + 1562, 1562, 1607, -3886, 932, -3886, -3886, 21004, -3886, 1966, + -3886, 903, 3239, 3372, 1984, 1989, 2546, 3142, 2546, -3886, + 2078, -3886, -3886, -3886, -3886, -3886, 3409, 3357, -3886, -3886, + -3886, -3886, 653, -3886, 3287, 3290, 54275, -3886, 54275, 3504, + -3886, 7524, 38809, 2928, 1558, 2919, -3886, -3886, 3292, -3886, + 3295, 2545, 26879, 4225, -3886, 840, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, 1996, -3886, 54275, 3112, 2591, 22700, + 22700, 3113, 51426, 306, 3124, -3886, 3119, -3886, -3886, 3259, + 932, 10197, 38809, 3491, -3886, -3886, -3886, 3239, -3886, -3886, + 54275, 3248, -3886, 193, 193, 3446, -3886, 3180, -3886, -3886, + -3886, 628, -3886, 3129, 2976, 2928, -3886, -3886, 2976, -3886, + -3886, -3886, -3886, 1779, -3886, -3886, -3886, 23972, 3253, 680, + 8710, -3886, -3886, -3886, -3886, 278, 1562, 21004, 932, -3886, + 3250, 1969, 54275, -3886, -3886, 3037, -3886, 3540, -3886, 1012, + -3886, -3886, 2973, 37588, -3886, 2976, 2624, -3886, 1338, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, 3530, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, 7722, -3886, -3886, -3886, 3427, -3886, + -3886, -3886, -3886, 2002, -3886, -3886, -3886, -3886, -3886, -3886, + 1679, -3886, -3886, 1689, 1890, 23124, -3886, 932, 3284, -3886, + 37588, -3886, 1338, -3886, 38809, -3886, -3886, 3143, 37588, 2004, + -3886 +}; + +/* YYPGOTO[NTERM-NUM]. */ +static const yytype_int16 yypgoto[] = +{ + -3886, -3886, -3886, 2873, -3886, -735, 53, 2274, -1583, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -3886, + 2834, -3886, -3886, -3886, 1506, -3886, -3886, 117, -1050, 1575, + 2473, 1206, -3886, -890, -3886, -3886, -508, 134, -627, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -3886, -663, 1653, 1067, + -709, -2222, -3886, -1141, -3081, -3886, 510, -3886, -3886, 1598, + -3886, -3886, -3886, 934, -257, -3886, -3886, -3886, -3886, -3886, + -3886, -3886, 7, -3886, -3886, -417, -1306, 32, -57, -285, + -3886, -3886, 348, -288, -1167, -3886, -2923, -3886, -27, -3886, + -3886, -3886, -287, -1135, 1163, -3886, -594, -913, 1444, -566, + -3886, -179, -3886, -615, -519, -517, -575, -420, -3102, -3460, + -3659, -2897, 1171, 142, -3886, -38, -1299, -3886, -3886, -1236, + -1160, -3886, -592, -3886, -3886, -3886, -2385, -3886, -3886, -3886, + -3886, 63, -3886, -3886, -3886, -3886, 403, -3886, -3886, -3886, + -3886, -3886, -3886, -2200, 1561, 1564, -3886, -3886, -2572, -3886, + -714, -3886, 550, -2421, 1087, -3886, -3886, -3886, 2234, -3886, + -3886, -3886, -3886, 406, -3886, 405, -3886, -3886, -1324, -3886, + -3886, -1293, -3886, 1576, 905, -3886, -3886, -3886, -599, -661, + -648, -3886, -2862, -3886, -3886, -3886, -3886, -3886, -811, -3886, + 959, -2555, -783, -3886, -3886, 976, -3886, -3886, -3886, -3886, + -554, -180, 2265, -3886, -457, -530, -3886, -3886, -3886, -175, + -3886, -3886, -3886, -3886, -3886, -3886, -862, 6542, -1277, -3886, + -3886, -3886, -3886, -1831, -3886, -3886, -3886, -1557, -3886, 3625, + 1903, 552, -1292, -3886, -21, 65, 2699, -915, -2138, 353, + -311, -3886, -1467, -3886, -3886, -3886, -2060, -3886, -3886, -3886, + -3886, -2871, -1287, -3886, -3886, -3886, 400, -3886, -3126, -3307, + -3559, -3679, -2858, -3886, -3886, -875, -3886, -3886, -3886, -1119, + 1770, -1176, -3886, -1780, 401, -3131, -576, -2680, -3886, -3046, + -396, -3886, -3886, -3886, -3886, -3886, -3886, -3886, -880, -515, + -3886, -3886, 3107, -3886, -3597, -3886, -3886, -3886, -3886, 1321, + -3886, -1152, 1054, -3886, -3886, -3886, -3886, -3886, -543, -620, + -3886, -3886, -3886, 148, -3886, -3886, -3886, -3886, 1815, -760, + -595, 2992, -1280, -355, -3886, -3886, -3886, -3886, -2511, -3886, + -3886, -3886, -3886, -3886, -3886, -3886, -1286, -3886, -3886, -3886, + -3886, -3886, -3886, -3886, 1916, 1912, 45, -22, -3886, -3886, + -1017, -3886, -441, -3886, 2208, -3886, -3886, -3886, -3886, 1291, + 150, 433, -3886, 3, -3886, -3886, 229, -2811, 4, -3886, + -3886, -3886, -3886, -336, 5, -3886, 693, -3886, -3886, -2283, + -3886, 151, 26, -3886, -3886, 1, 0, -41, -28, -23, + 2, 2987, 2554, -3886, -3886, -3886, 19, 1422, -3886, -689, + -156, -3886, 1297, -545, 1892, 2539, 2541, -3886, 1298, -3886, + -3886, 1302, -3886, -3886, -3886, -540, 1904, -3886, 2557, 1917, + -3886, 1285, 1295, -2738, 765, -2788, 289, -1180, -249, 22, + 3017, 2560, -3886, -3708, 716, -3886, -2771, -1867, -353, 1672, + -1291, -3886, -3886, -910, 9648, -3886, -3886, -3886, 10147, 10361, + -3886, -3886, 10485, 10692, -3886, -809, 812, 11191, 8131, -975, + -1553, -421, 7435, -1988, -1072, -2119, -3886, -3886, -3886, -219, + 818, 650, -3886, -3886, -3886, -3886, -451, -2284, -449, -3886, + -3886, -3886, -450, -3885, -1198, -3886, -174, -3886, 9111, 1332, + -3886, -860, -2216, -2224, -929, -1431, -3886, -3886, -3886, -3886, + -3886, -3886, -3886, -1248, -2711, -581, 1393, -3886, -3886, 1490, + -3886, -3886, -3886, -1055, -716, -2137, 1402, -1642, -3886, -684, + 742, 2094, -641, 75, -496, 5762, -435, -1838, -1007, -1233, + -3886, -122, -3886, 25, -9, -119, -7, 3203, 8282, -1025, + 7081, -1081, -1071, -2518 +}; + +/* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If + positive, shift that token. If negative, reduce the rule which + number is the opposite. If zero, do what YYDEFACT says. + If YYTABLE_NINF, syntax error. */ +#define YYTABLE_NINF -2162 +static const yytype_int16 yytable[] = +{ + 162, 161, 166, 156, 157, 159, 694, 554, 704, 850, + 773, 510, 649, 1427, 615, 626, 1437, 1147, 1080, 615, + 162, 1156, 166, 949, 950, 951, 1745, 1153, 2168, 955, + 1431, 1887, 1512, 498, 1487, 1467, 1746, 1302, 1825, 1380, + 545, 1242, 2294, 874, 538, 1896, 614, 693, 1398, 1327, + 736, 614, 896, 1290, 1748, 2029, 1460, 1573, 754, 1523, + 2810, 681, 755, 678, 1905, 589, 1264, 776, 1779, 890, + 2000, 1094, 2946, 899, 3267, 2091, 788, 1897, 2066, 1745, + 581, 837, 1743, 911, 1918, 2067, 2042, 621, 1885, 1746, + 2552, 2068, 2069, 1546, 1547, 3028, 1418, 2070, 650, 1955, + 2222, 1748, 1369, 3437, 2071, 1373, 2500, 2502, 2607, 3061, + 1377, 3063, 1562, 1760, 2377, 1964, 1258, 1382, 2798, 1269, + 3185, 3214, 2980, 3499, 3459, 884, 1400, 1295, 2139, 698, + 2943, 1968, 1969, 3674, 64, 1743, 2941, 2942, 706, 3166, + 3469, 3658, 74, 707, 3639, 919, 3409, 3411, 133, 1873, + 154, 160, 2891, 1803, 1087, 668, 3342, 3166, 1141, 3787, + 3631, 1291, 3442, 1144, -1499, 2094, 705, 1233, 3190, 3191, + 3192, 3193, 3194, 3195, 1397, 2103, 597, 1205, 3785, -1504, + 508, 1591, -1937, 1539, 1540, -1971, -1874, 2299, 546, 2649, + 1589, 3395, -1940, 1980, 1443, 597, 4053, 1173, 3885, -1851, + 1906, 597, 1975, -1852, 1749, 1458, 1181, -1851, 931, 1559, + 2628, -1852, 782, -1722, 935, -1991, 975, -1499, -2016, 550, + -1722, 2707, 3258, 4101, -1471, 1628, 4031, -2161, 3977, 2199, + -1514, 2936, -1504, 550, 2299, -2161, 1321, 2808, 3, 4, + 1419, 751, 1181, -1484, 4226, 2848, 2651, -1511, 550, 550, + 1507, 1240, 2033, 550, 3453, 2688, -1828, 758, 684, 2334, + 4010, 550, 2033, 779, 2088, -1504, 2335, 2846, 2847, 3024, + 2545, 790, 2862, -346, 2985, 597, 2799, -1738, 2350, 2936, + 3247, 792, 3029, 1827, -1738, 1745, 2160, 2769, 1899, 2771, + 1365, 1393, 946, 2801, 701, 1746, 1962, 4090, 4091, 1174, + 1315, -118, 4114, 1299, 4119, 655, -118, 3596, 1182, 1419, + 1828, 1394, 2897, 2898, 3178, 1598, 3220, 2034, 953, 841, + 1131, 3627, 4246, 550, 1568, 1137, 3651, 2034, 1137, 1419, + 2063, 885, 603, 1469, 1302, 603, 603, 1767, 2381, -1304, + 1601, 2047, 603, 1569, 1182, 1642, 1231, 550, 1902, -1514, + 773, 597, 604, 2568, 1598, 604, 604, -1471, 1634, 503, + 1633, 1111, 604, 1112, 550, 603, -1307, 2259, 603, 793, + 1603, 1241, 1231, 2035, 1573, -140, 2036, 597, 2464, 1601, + 2848, 2259, 4137, 2035, 1462, 604, 2036, 1463, 604, 832, + 4283, 2825, 1139, 773, 1899, 1139, 954, 597, 656, 1903, + -140, 1438, 2064, 845, 1455, 2037, 2568, 852, 794, 1603, + 4113, 1831, 2689, 1132, 4120, 3454, 2089, 2382, 861, 1635, + 1750, 3609, -1304, 4227, 1768, 3790, 1546, 1547, 2340, 4041, + -1471, 1140, 547, 879, 1562, 2011, 2007, 4115, 1175, 1829, + 551, 3794, 888, 947, 3455, 1643, 1598, 2161, 2652, -1307, + 1309, 2546, 1300, 3628, 1899, 1395, 795, 1505, 1899, 3221, + 3652, 1917, 1084, 3456, 2037, 2800, 1629, 1514, 1907, 1176, + 1527, 1601, 3418, 1168, 2037, 2219, 2162, 4121, 3452, 1524, + 1908, 1351, 2802, 2945, 4216, 1420, 1471, 752, 3025, 4228, + 2690, 2300, 3029, 2258, -1304, 2462, 954, 829, 1177, 760, + 1646, 1603, 2629, 1429, 1237, 1658, 1658, 2281, 1981, -1990, + 1508, 548, 4229, 549, 1209, 3512, 2027, 954, -1722, 1745, + 1951, -1307, 1953, 2003, 1859, 1539, 1540, 4163, 4269, 1746, + 1341, 1909, 3259, 685, 1559, 4234, 1106, 3579, 2911, 4236, + 1107, 1999, 875, 554, 1976, 1096, 694, 1322, 1323, 1592, + 1148, 1960, 3166, 1644, 1420, 1508, 1178, 1534, 2982, 3889, + 1183, 2038, 47, 2090, 2336, 842, 1366, 927, 827, 1366, + 2848, 2038, 1963, 2156, 1420, 2297, 4268, 886, 1748, 799, + 2039, 1640, -1738, 3864, 830, -1499, 162, 693, 166, 2023, + 2029, 928, 3173, 933, 2143, 937, 1113, 1861, 3780, 2998, + -1504, 941, 1788, 609, 610, 1867, 1301, 1789, 1511, 609, + 610, -1937, 3703, 2504, -1971, -1874, 1937, 918, 1568, 1457, + -1851, -1940, 960, 614, -1852, 614, -2162, 614, 3903, 1758, + 1876, 2164, 922, 614, 942, 943, -1304, 1569, 944, 3775, + 2175, 773, 976, 1534, -1991, 1545, 3635, -2016, -2161, 1077, + 956, 1570, 1086, 875, 1088, 1941, 2860, 2225, 1944, 1945, + 3423, 4086, 3744, -1307, 1551, 3647, 3748, 706, -1511, 2218, + 1594, 2221, 707, 4194, 1631, 1106, 3605, -1828, 2485, 1107, + 1306, 2229, 2364, 609, 610, 2233, -1504, 1832, 1429, 1168, + 1311, 1419, 2385, 2245, 2246, 705, 1310, 162, 161, 166, + 156, 157, 159, 956, 2574, 2486, 2263, 2265, 3299, 2113, + 2499, -1990, 3795, 966, -118, -118, 3076, 2279, 2119, 3041, + 2008, 3042, 2123, 1745, 1933, 3431, 1622, 2509, 2129, 2130, + 1116, -1304, 1151, 1746, 1081, 4235, 3969, 1568, 3095, 2959, + -1471, 2463, 3490, 3979, 2429, 1409, 2142, 1097, 2249, 2250, + 2850, -1471, 1104, 1545, -1471, 1160, 1569, -1471, -1307, 609, + 1232, 4183, 1619, 1620, 1621, 1622, -1304, 708, -1304, 2560, + 1572, 4049, -1990, 1130, 1187, 2400, 550, 1083, 2165, 1743, + 3517, 1091, 1274, 3522, 614, 609, 1232, -1990, 2857, 2858, + 2859, 2860, 2234, -1307, 550, -1307, 1389, 2420, 3133, 3134, + 3128, 1511, 550, 3131, 3132, 609, 610, 3135, 1098, -1825, + 2936, 2100, 2953, 1819, 2179, 3269, 2430, 3142, 3077, 550, + 1275, 505, 1325, 971, 4248, 1873, 2476, 984, 1819, 1820, + 2848, 64, 585, 1745, 1390, 4066, 1745, 550, 699, 74, + 3445, 2561, 709, 1746, 1279, 133, 1746, 154, 160, 2097, + 1280, 14, 1617, 1618, 1619, 1620, 1621, 1622, 2172, 2173, + 550, 3325, 3648, 4201, 3330, 3331, 3332, 3333, 3334, 3335, + 3336, 3337, 3338, 3339, 3611, 2316, 3518, 3163, 1170, 3523, + 3465, 2338, 19, 1821, 1930, 867, 3855, 2235, 2696, 3677, + 3270, 2562, 2542, 3980, 1828, 3163, 700, 2477, 1821, 634, + 1822, 3196, 2097, 875, 763, 764, 765, 2848, 766, 767, + 768, 769, 770, 771, 3856, 1822, 875, 1376, 2082, 3890, + 4143, 2128, 1170, 3379, 3380, 4133, 1833, 162, 1887, 166, + 2180, 3891, 2120, 1411, 1955, 550, 1420, 1401, 1404, 1405, + 3502, 2563, 2728, 2131, 3199, 2592, 1281, 1833, 4249, 1510, + 614, 2593, 2236, 3937, 2004, 2138, 1473, 3078, 1475, 3625, + 1477, 701, 1479, 3519, 1481, 1482, 1483, 4014, 1276, 875, + 1244, 1485, 3265, 1511, 4032, 635, 2855, 2856, 2857, 2858, + 2859, 2860, 1391, 3947, 37, 3949, 1532, 1106, 3079, 2115, + 3544, 1107, 4055, 2083, 3267, 701, 2163, 4012, 2166, 2317, + 2169, 1245, 2171, 2318, 2339, 2174, 1549, 3940, 2237, 694, + 2850, 2238, 3944, 4067, 41, 3946, 4199, 3080, 2050, 3271, + 3626, 2148, 4033, 3500, 4202, 4184, 1823, 1081, 2560, 4034, + 2564, 710, 4195, 2098, 1958, 701, 1576, 3472, 868, 1771, + 2319, 1823, 2372, 1590, 2700, 2480, 3649, 2594, 2252, 1081, + 1587, 2639, 45, 1595, 1277, 1834, 4035, 2259, 2259, 3070, + 4198, 37, 2259, 1632, 46, 773, 1445, 2851, 1392, 3088, + 2114, 627, 4087, 3862, 3071, 702, 3503, 3806, 3203, 3272, + 875, 3892, 4093, 1648, 1649, 1282, 3871, -2162, 875, 875, + 1772, 41, 3697, 869, 550, 4084, 1754, 4200, 2401, 2239, + 2561, 2181, 2259, 2259, 1446, 1761, 1762, 4135, 1766, 3473, + 707, 707, 633, 707, 3204, 4260, 1283, 614, 4094, 2182, + 1824, 37, 614, 614, 1137, 2014, 4036, 3205, 1138, 45, + 1835, 2565, 2672, 705, 705, 1824, 705, 3545, 3763, 2566, + 4056, 46, 2567, 636, 637, 1284, 603, -734, 3767, 3017, + 2562, 41, 932, 934, 936, 4173, 2320, 938, 939, 940, + 2601, 654, 3474, 2015, 3475, 3774, 604, 945, 1987, 2084, + 2948, 1151, 3047, 2949, 1412, 47, 3504, 4075, 1662, 3505, + 2476, 1650, 2085, 2258, 2258, 4044, 2595, 3018, 2258, 45, + 2598, 1139, 3613, 4045, 3431, 2701, 2240, 3757, 2012, 1745, + 2563, 46, 3175, 792, 2803, 1745, 3766, 4072, 3206, 1746, + 3951, 3624, 4174, 2949, 614, 1746, 3705, 2596, 3706, 3039, + 1651, 2599, 614, 3791, 1413, 1791, 2504, 1140, 2258, 2258, + 2508, 4170, 4167, 4168, 3996, 47, 2855, 2856, 2857, 2858, + 2859, 2860, 1868, 2766, 3691, 2295, 2597, 1854, 2772, 4261, + 2600, 2477, 1447, 2013, 1959, 2881, 1160, 943, 3176, 3986, + 2767, 2888, 773, 1946, 2062, 506, 2714, 2715, 2716, 2717, + 1917, -557, 614, 2804, 2194, 614, 614, 2573, 2722, 521, + 1987, 2936, 792, 1770, 3792, 2936, 1893, 4037, 1961, 2564, + 3163, 793, 169, 1910, 1931, 2112, 3166, 676, 2585, 3570, + 4021, 2489, 1222, 4218, 2118, 3573, 3574, 3575, 3576, 3577, + 3578, 2016, 1414, 2855, 2856, 2857, 2858, 2859, 2860, 1089, + 651, 1940, 1887, 3295, 1771, 1869, 2702, 2623, 521, 2762, + 794, 2467, 170, 1987, 3997, 3019, 523, 614, 1448, 2602, + 1638, 1222, 3451, 3707, 4046, 984, 3048, 169, 2848, 2037, + 1261, 2575, 1429, 1974, 1932, 2441, 2956, 1366, 4253, 2578, + 1415, 2580, 687, 862, 2823, 2703, 696, 1990, 2603, 3646, + 793, 3049, 1429, 754, 2425, 1772, 2072, 1170, 795, 3040, + 2002, 1262, 3725, 3726, 2490, 523, 1947, 170, 1948, 773, + 2565, 3313, 863, 4277, 2617, 1813, 2506, 2017, 2566, 2480, + 1280, 2567, 169, 2066, 2437, 1814, 1165, 2442, 2765, 794, + 2067, -1316, 1946, 2875, 1955, 2441, 2068, 2069, 3886, 1247, + 1815, 3020, 2070, -1316, 2774, 2775, 1598, -1316, 2777, 2071, + 2307, 3096, 2308, 3472, 2781, 2061, 864, 1166, 1416, 2604, + 3592, 32, 170, 3680, 2900, 3681, 4127, 1952, 550, 1745, + 1745, 1745, 597, 2092, 2309, 3289, -887, 795, 3887, 1746, + 1746, 1746, 162, 3267, 166, 1248, 1167, 3001, 2605, -1316, + 530, 2521, 531, 4116, 1557, 1558, 1263, 3956, 3957, 1589, + 1472, 1603, -2073, 1474, 1919, 1476, 3593, 1478, 697, 1480, + -1316, 2812, 1911, 1484, 37, 536, 1281, 3402, 2150, 2558, + 2151, 2196, 2152, 1093, 2153, 3473, 2154, 2849, 922, 984, + 2155, -369, 2848, 162, 2193, 166, 2190, 2191, 2192, 530, + 4054, 531, 2522, 2177, 41, 3403, -1316, 4022, 2850, 3004, + 2184, 2523, 1920, 1921, -1316, 1947, 2147, 1948, 1925, 1168, + 3750, 2243, 1249, 597, 536, 2510, 3606, 2310, 1993, 1816, + 984, 3405, 2311, 2848, 3913, 4023, 711, 2312, 3474, 32, + 3475, 1429, 45, 4096, 3298, -2073, 1917, 4159, 2231, 2232, + 3370, 746, 27, 1745, 1081, 1081, 2244, 3995, 2791, 1994, + 2247, 2248, 2524, 1746, 1289, 2851, 2195, 3016, 1250, 3985, + 1251, 2216, 4160, 1745, 2672, 2269, 3323, 2270, 3248, 2758, + 1954, 3252, 3299, 1746, 2476, 2305, 862, 645, 47, 699, + 3326, -2073, 3327, 4000, 675, 1429, 1452, 2292, -1350, 2293, + 3343, -1351, -1350, -2073, 759, -1351, 2936, -2073, 1253, 3146, + 3603, 2936, -2073, 2780, 2936, 3227, 1453, -2073, 2365, 3965, + -2073, 3967, -2073, 3798, 3799, 1899, 3407, 1270, -1316, 2047, + 37, 2259, 784, 1904, 2259, 2259, 2259, 2259, 2259, 2259, + 2259, 2259, 2259, 2259, 3465, 1255, 791, 700, 1157, -2073, + 2789, 4147, 773, 2313, 3010, 2477, 4082, 2663, 1271, 864, + 41, 2417, 1272, 2314, 2259, -1350, 2421, 1995, -1351, 2424, + -2073, 2874, 2850, 2876, 2877, 2902, 1568, 2903, 1996, 1158, + 1257, 831, 1288, 2348, 2478, 3116, 32, 1273, 843, 1127, + 844, 2447, 2362, 2259, 2259, 1569, 3918, 2457, 45, 2904, + 1568, -1350, 1997, 754, -1351, 3117, -2073, 3328, 1159, 1570, + 46, 1289, 701, 2850, -2073, 2479, 3007, 3329, 834, 1569, + 3839, 3840, 3934, 3935, 851, 2491, 3487, 836, 2967, 2851, + 2852, 2853, 2854, 1572, 2855, 2856, 2857, 2858, 2859, 2860, + 1752, 865, 2387, 1753, 47, -1098, 3043, -1098, 2951, 3030, + 3470, 1545, 2505, 1804, 1658, 1598, 857, 2258, 3465, -2073, + 2258, 2258, 2258, 2258, 2258, 2258, 2258, 2258, 2258, 2258, + 2851, 162, 2403, 2431, 614, 2434, 2538, 3051, 1116, 846, + 1601, 847, 1919, 1745, 1168, 3229, 2917, 1162, 3546, 3054, + 3354, 3056, 37, 1746, 1106, 3724, 2559, 2905, 1107, 2569, + 198, 3033, 2906, 2480, 627, 507, 2936, 2373, 3547, 2376, + 1603, 1755, 3401, 583, 1756, 2806, 2219, 2581, 1163, 2258, + 2258, 1797, 41, 866, 2677, 3073, 702, 2590, -2073, 652, + 1920, 1921, 2719, 2820, 2108, 2109, 1188, 2720, 2146, 3356, + 2613, 1088, 1598, 3589, 1531, 3591, 47, 1164, 3594, 2620, + 3595, -2073, 1798, -2073, -2073, 1545, 3074, 1160, 2484, 3491, + 45, 2821, 3, 4, 1917, 3186, 2822, 1601, 1189, 1545, + 2720, 1804, 46, 2678, 3305, 3495, 3344, 3345, 3114, 3402, + 1545, 1799, 1804, 3121, 3401, 3075, -2073, 3501, 3506, -2073, + -2073, -2073, 2393, 2394, 2852, 2853, 2854, 1603, 2855, 2856, + 2857, 2858, 2859, 2860, 612, 2145, 47, 3403, 2146, 612, + 2219, 4060, 2157, 2990, 2991, 2158, 2993, 881, 2907, 585, + 3309, 2159, 3404, 1190, 2158, 892, 2187, 3009, 2908, 2188, + 2739, 2740, 3210, 3405, 1965, 2852, 2853, 2854, 14, 2855, + 2856, 2857, 2858, 2859, 2860, -1374, -1374, 2609, 614, 2679, + 2680, 3402, 2962, 2963, 1191, 3406, 614, 1106, 614, -1828, + 3377, 1107, 2378, 2681, 1745, 1429, 2529, 897, 1745, 19, + 1745, 1919, 2413, 1597, 1746, 2188, 1598, 906, 1746, 3403, + 1746, 2259, 2921, 2641, 2922, 2497, 912, 4001, 2498, 1192, + 916, 2641, 4237, 27, 3404, 597, 2554, 2750, 3350, 2555, + 2923, 1601, 2924, 3465, 4215, 3405, 2658, 1602, 2682, 2659, + 3308, 4019, 2673, 948, 3163, 2674, 1188, 952, 1193, 1920, + 1921, 958, 1606, 1607, 2542, 961, 3513, 3406, 3407, 2783, + 2696, 1603, 2158, 3276, 2968, 2969, 984, 3279, 3280, 2848, + 3282, 963, 3284, 3285, 2671, 968, 3941, 2713, 1189, 2819, + 3091, 3290, 2146, 1917, 3723, 1597, 3371, 969, 1598, 2829, + 2813, 1887, 2146, 3598, 3599, 2815, 1610, 3467, 3468, 1992, + 970, 37, 2744, 2487, 971, 2711, 162, 2729, 875, 972, + 32, 3306, 1874, 1601, 1196, 3011, 4281, 3656, 4282, 1602, + 1197, 3094, 973, 2683, 3225, 2684, 1127, 1198, -1304, 4050, + 3407, 41, 1134, 1190, 1136, 1875, 1919, 2258, 984, 2672, + 1919, 2848, 875, 1603, 1200, 2708, 3914, 3915, 3916, 3917, + 2833, 2837, 1201, 2146, 2146, 974, 2838, 773, 1919, 2146, + 2864, 1604, 977, 2146, 1191, 1605, 978, 2880, 2885, 45, + 2146, 2886, 3064, 3068, 3097, 3065, 3069, 3216, 37, 980, + 3217, 46, 2259, 2259, 1920, 1921, 1606, 1607, 1920, 1921, + 3211, 1095, 3213, 2751, -2075, 3256, 1092, 3314, 3257, 1192, + 2146, 1302, 1608, 1202, 3942, 614, 1920, 1921, 41, 1099, + 3081, 1919, 3083, 2950, 3219, 4238, 3222, 3351, 1917, 2960, + 3352, 3361, 1917, 1101, 3362, 3961, 3373, 1105, 1193, 2146, + 1610, 1100, 3414, 3443, 3310, 3749, 3444, 3752, 2937, 3447, + 1917, 2285, 3448, 1611, 2288, 3471, 45, 1605, 2158, 2850, + 586, 3582, 1117, 3262, 3583, 3177, 3179, 3180, 46, 1920, + 1921, 3729, 3419, 3421, 2188, 3115, 3586, 3782, 1606, 1607, + 3783, 3788, 3789, 694, 2158, 2158, 1124, -2075, 1617, 1618, + 1619, 1620, 1621, 1622, 3882, 3923, 2937, 3883, 3924, 3129, + 32, 1125, 587, 1917, 2752, 3925, 1517, 1518, 2146, 3125, + 1197, 3933, 3294, 1127, 2188, 2986, 2851, 1198, 2258, 2258, + 3983, 3492, 1610, 3984, 1587, 1875, 4004, 4051, 1613, 4005, + 4052, 2850, 3304, -2075, 1200, 1611, 515, 1128, 2305, 1135, + 1597, 4062, 1201, 1598, 2188, -2075, 1919, 4069, 4074, -2075, + 1429, 3236, 4076, 4136, -2075, 3236, 1637, 2920, 1919, -2075, + 4141, 1149, -2075, 4142, -2075, 1150, 984, 1154, 1601, 2848, + 2930, 1180, 4148, 4149, 1602, 2188, 2886, 875, 4150, 1748, + 694, 2146, 1160, 2926, 2927, 2928, 3730, 4153, 2851, 4155, + 1429, -2075, 3236, 1202, 1920, 1921, 1185, 2753, 1603, 162, + 2193, 166, 2190, 2191, 2192, 2510, 1920, 1921, 4007, 2952, + 2219, 614, -2075, 4172, 521, 1207, 2188, 1211, 2930, -2162, + -2162, 693, 1617, 1618, 1619, 1620, 1621, 1622, 1917, 3566, + 3277, 4178, 1246, -881, 2188, 1239, 4179, 1745, 2925, 2188, + 1917, 1237, 1597, 4204, 1266, 1598, 1429, 1746, -2075, 4279, + 3072, 4290, 4280, 1278, 4280, 1292, -2075, 3084, 1287, 1297, + 2899, 1298, 1599, 1303, 1305, 1307, 875, 3728, 1312, 1317, + 1601, 523, 1319, 1329, 1326, 3675, 1602, 1168, 1370, 1372, + 1366, 2852, 2853, 2854, 1081, 2855, 2856, 2857, 2858, 2859, + 2860, 1374, 1383, -157, 1385, 3318, 1387, 1399, -2162, 1407, + 1603, -2075, 1605, 2960, 1617, 1618, 1619, 1620, 1621, 1622, + 185, 2710, 3712, 1417, 1422, 3324, 1423, 3899, 1424, 1425, + 1426, 2960, 1745, 1606, 1607, 1428, 2259, 3126, 1429, 1436, + 1439, 1440, 1746, 1441, 1442, 2259, 1444, 1449, 1450, -2162, + 3346, 1451, 1456, 1461, 1486, 1513, 627, 3067, 1519, 2850, + 1515, 1521, 2259, 2259, -2162, -2162, 1522, 2855, 2856, 2857, + 2858, 2859, 2860, 984, 1528, 1529, 2848, 1610, -1475, -1482, + -2075, 1538, 1541, 3147, 3588, 3089, 1511, 1542, 3146, 1543, + 1611, 1544, 47, 3731, 1548, 1550, -1472, 1553, -1473, 3679, + 1554, 1555, 1556, -2075, 1561, -2075, -2075, 3682, 3683, 1563, + 1604, 1564, -1476, 1565, 1605, 530, 2851, 531, 1566, -1474, + 1567, 1574, 1575, 1577, 3148, 1578, 533, 1579, 1580, 1581, + 1582, 1583, 1584, 1626, 1641, 1606, 1607, 535, -2075, 1637, + 536, -2075, -2075, -2075, 1653, 1661, 1759, 1138, 3149, 1786, + 1800, 1608, 2641, 1140, 1794, 2641, 2641, 1801, 1802, 2641, + 1804, 1805, 2258, 3150, 1806, -2162, 1807, 3151, 1808, 2641, + 1809, 3926, 1836, 1830, 1325, 1856, 1609, 1837, 3165, 1610, + 1860, 1863, 1862, 1866, 1864, 3152, 1865, 1892, 2258, 2258, + 1987, 1891, 1611, 1899, -2088, 1612, 3165, 1901, 754, 1212, + 3153, 1911, 1912, 1914, 3297, 1213, 1915, 1916, 1917, 875, + 3851, 875, 614, 1923, 1924, 1926, 1934, 1927, 1928, 3172, + 3174, 1935, 3307, 1942, 3181, 3844, 1938, 1939, 1949, 1222, + 614, 1950, 1956, 1957, 3688, 1966, 1967, 1977, 1978, 1979, + 1982, 1983, 3234, 1988, 1991, 1214, 2005, 2018, 2006, 2021, + 2020, 2259, 2028, 1545, 3636, 3637, 2850, 2030, 3223, 1617, + 1618, 1619, 1620, 1621, 1622, 1534, 1551, 1613, 2031, 2048, + 2051, 3261, 875, 2055, 2054, 517, 3154, -2088, 3656, 2060, + 1156, 2852, 2853, 2854, 3155, 2855, 2856, 2857, 2858, 2859, + 2860, 162, 3275, 2059, 1215, 2076, 1263, 2081, 3796, 3215, + 2095, 1216, 2096, 2101, 1217, 2106, 2107, 2111, 2122, 3921, + 2124, 2104, 2125, 2851, 2127, 2176, 2126, 3156, 2140, 2141, + 2170, 2185, 2267, -2088, 3230, 3685, 3686, 3687, 2198, 3812, + 3813, 2225, 3238, 2268, 2224, -2088, 3244, 2937, 1598, -2088, + 2280, 2230, 2286, 2298, -2088, 2350, 2291, 2323, 2304, -2088, + 3255, 2363, -2088, 2321, -2088, 2290, 1218, 1614, 1615, 1616, + 2366, 1617, 1618, 1619, 1620, 1621, 1622, 2370, 2367, 2371, + 700, 614, 2389, 2379, 2841, 3841, 2388, 2258, 2380, 2392, + 2398, -2088, 2412, 2414, 2415, 3836, 3837, 2416, 2427, 2432, + 2437, 2439, 2435, 2440, 2446, 2455, 2451, 2458, 2472, 2475, + 2488, 3638, -2088, 1089, 1093, 2495, 3899, 2937, 694, 2549, + 2493, 1219, 2544, 1220, 1081, 2553, 3368, 2557, 694, 2556, + 2619, 2606, 2626, 1221, 2627, 2630, 2960, 2631, 3952, 2632, + 2634, 1222, 2635, 1745, 2636, 2637, 2638, 3488, -2088, 2648, + 1223, 2654, 2650, 1746, 2661, 2664, -2088, 2657, 2669, 1587, + 2666, 3769, 2665, 2667, 2668, 2694, 2699, 2670, 2675, 3394, + 2706, 2712, 2718, 2721, 2726, 2727, 4006, 2742, 2745, 3429, + 3387, 3388, 3389, 3390, 2757, 1225, 2763, 2761, 2852, 2853, + 2854, 2759, 2855, 2856, 2857, 2858, 2859, 2860, 2760, 2764, + 1597, -2088, 2773, 1598, 2779, 2778, 2776, 2797, 2785, 3907, + 1226, 3908, 3909, 2786, 2787, 2805, 1457, 2788, 2199, 3196, + 2809, 2811, 3912, 2790, 3548, 3197, 954, 3551, 1601, 2814, + 2816, 4061, 2817, 2202, 1602, 3198, 2831, 2832, 2835, 2882, + 2901, 3391, 3392, 3393, 2947, 2834, 627, 2945, 2836, 2916, + 2839, 2870, 2896, 2939, 2840, -927, 2974, 2842, 1603, 2845, + 2863, 2146, 3199, 1511, 3200, 2869, 2978, 2972, 1227, 2989, + -2088, 2871, 2872, 2984, 2992, 2879, 3865, 3003, 2894, 2895, + 2203, 2944, 2909, 2919, 3006, 2995, 3008, 3829, 3830, 2994, + 3832, 2999, 3000, -2088, 3012, -2088, -2088, 3026, 4099, 3027, + 3037, 3165, 4104, 4105, 4064, 3038, 3044, 3045, 3053, 2204, + 3055, 3086, 3087, 3090, 3092, 3093, 3098, 3099, 3533, 3532, + 3103, 3534, 3100, 3535, 3104, 3101, 3102, 3105, -2088, 3964, + 2205, -2088, -2088, -2088, 3106, 614, 3201, 3107, 3109, 3108, + 3110, 3112, 3111, 3113, 3120, 3118, 1975, 3561, 3562, 4103, + 3122, 614, 3124, 4100, 1597, 3844, 3130, 1598, 1604, 2206, + 3136, 2641, 1605, 3137, 2207, 3167, 3797, 2641, 2641, 2641, + 2641, 2641, 2641, 4106, 1599, 4108, 3138, 875, 3139, 3171, + 3140, 3590, 1601, 1606, 1607, 3141, 3170, 2037, 1602, 3182, + 3187, 3202, 1745, 3183, 3811, 3228, 3203, 3226, 3235, 1608, + 3188, 3240, 1746, 3236, 3242, 3246, 3820, 3224, 3249, 3253, + 2208, 614, 1603, 3274, 3250, 3245, 3254, 3302, 3291, 3281, + 3608, 3610, 3612, 3614, 942, 943, 3283, 1610, 3292, 3293, + 3301, 3296, 3204, 3303, 3312, 3597, 1531, 3317, 2866, 1745, + 1611, 2848, 2865, 3347, 4059, 3205, 1212, 1745, 4267, 1746, + 3835, 3363, 1213, 1591, 3607, 3375, 3376, 1746, 3416, 3458, + 4158, 3439, 3479, 3481, 3493, 623, 624, 3482, 3494, 3514, + 630, 3516, 3515, 3413, 640, 646, 623, 1247, 653, 3496, + 3348, 646, 646, 3349, 680, 3667, 683, 4040, 185, 3507, + 3355, 3526, 1214, 162, 3666, 4267, 3384, 3400, 4085, 3422, + 3432, 3604, 773, 4267, 3527, 3433, 3435, 3436, 3498, 3972, + 4081, 3528, 1604, 2209, 3529, 1613, 1605, 3543, 2937, 2210, + 3630, 3530, 2937, 1248, 3531, 2211, 3206, 3559, 3502, 3569, + 3571, 4111, 3563, 3572, 3602, 3629, 3266, 1606, 1607, 3600, + 3601, 1215, 3640, 3699, 3989, 1188, 3641, 3642, 1216, 3621, + 3660, 1217, 3663, 1608, 2212, 2158, 2213, 3644, 3676, 3645, + 3664, 614, 3672, 3673, 3684, 3678, 3689, 3692, 3693, 3701, + 3694, 3695, 3696, 2214, 3704, 3708, 3713, 1189, 1609, 3714, + 3709, 1610, 3743, 3715, 3717, 3716, 4256, 3741, 3721, 3746, + 3745, 3753, 3756, 3758, 1611, 1511, 3759, 1612, 2215, 3770, + 1249, 3777, 3761, 1218, 3762, 1614, 1615, 1616, 1629, 1617, + 1618, 1619, 1620, 1621, 1622, 737, 742, 742, 745, 3779, + 742, 750, 3773, 737, 756, 680, 3784, 775, 3785, 756, + 3793, 680, 1190, 680, 3804, 3815, 3807, 742, 756, 680, + 2930, 3808, 3814, 3821, 2930, 3824, 1250, 3825, 1251, 3833, + 3828, 3838, 3842, 3849, 3857, 3854, 3858, 3866, 1252, 3868, + 1220, 3870, 3873, 1191, 3768, 3875, 3869, 3881, 3884, 1613, + 1221, 3888, 3894, 3896, 3905, 3911, 3897, 3778, 1222, 3919, + 3930, 3920, 4068, 162, 3771, 3776, 1253, 1223, 3922, 3929, + 3927, 3931, 4068, 3932, 3938, 3945, 3948, 3954, 1192, 3958, + 3966, 3960, 3737, 3738, 3739, 3740, 3962, 3978, 3981, 3998, + 3982, 3999, 3991, 4008, 3628, 3992, 4015, 614, 1254, 4017, + 4025, 4026, 1225, 1255, 4030, 4065, 4042, 1193, 4080, 4028, + 4071, 4043, 701, 4088, 4097, 4117, 4122, 3809, 4169, 4128, + 4132, 4138, 4126, 4110, 4140, 4145, 4252, 1256, 4146, 4139, + 4151, 4156, 4152, 4157, 1194, 4162, 4164, 4101, 1257, 1614, + 1615, 1616, 4175, 1617, 1618, 1619, 1620, 1621, 1622, 614, + 4181, 2368, 4182, 4185, 4180, 4191, 4187, 2369, 3424, 4222, + 4214, 4196, 3818, 3819, 4197, 1195, 4219, 3822, 3823, 32, + 4217, 4225, 4184, 1196, 4183, 4233, 4247, 4259, 4275, 1197, + 4278, 4284, 2641, 2641, 1989, 1227, 1198, 1511, 2709, 4288, + 1129, 1660, 2954, 4166, 1199, 4154, 875, 2548, 3050, 3511, + 3847, 2618, 3848, 1200, 4002, 3852, 3853, 3143, 4112, 1210, + 3843, 1201, 3879, 4027, 3662, 4029, 3863, 3115, 3860, 2997, + 4039, 2950, 2784, 4220, 3970, 4255, 4188, 4186, 4134, 4231, + 773, 3002, 3880, 3632, 2692, 3510, 1597, 2693, 3062, 1598, + 2073, 3633, 3634, 2937, 2676, 3231, 4258, 4289, 2937, 2750, + 614, 2937, 4285, 3184, 1511, 3168, 3877, 4232, 1511, 1511, + 2960, 3990, 1202, 2058, 1601, 773, 4177, 4223, 1188, 3993, + 1602, 629, 3690, 1506, 4083, 3668, 4144, 2501, 3669, 877, + 4240, 2937, 4286, 3898, 3119, 4130, 2375, 555, 1102, 2374, + 2957, 2149, 3650, 3772, 1603, 3449, 1123, 2958, 1757, 556, + 1189, 2397, 1783, 1782, 3699, 3699, 3699, 3699, 2966, 2391, + 2970, 2983, 2396, 2971, 3396, 3751, 3988, 4073, 1110, 3450, + 557, 2662, 1787, 4063, 3357, 4205, 3367, 801, 4206, 1790, + 4213, 2914, 680, 558, 737, 2961, 2826, 742, 2912, 745, + 3446, 742, 0, 2349, 0, 756, 559, 775, 0, 756, + 854, 0, 0, 754, 0, 1190, 0, 742, 0, 0, + 756, 0, 0, 560, 0, 2930, 0, 0, 0, 0, + 2930, 3904, 0, 2930, 876, 0, 0, 0, 737, 0, + 0, 0, 0, 745, 561, 0, 1191, 737, 0, 0, + 775, 0, 0, 0, 1604, 2937, 0, 0, 1605, 0, + 0, 0, 562, 0, 0, 742, 0, 0, 0, 0, + 926, 0, 0, 563, 0, 2751, 3963, 0, 564, 1606, + 1607, 1192, 0, 0, 565, 3165, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1608, 0, 1597, 0, 566, + 1598, 0, 0, 2937, 0, 0, 0, 0, 0, 2641, + 1193, 680, 0, 4003, 0, 0, 0, 0, 0, 614, + 1609, 680, 967, 1610, 0, 1601, 0, 0, 0, 0, + 0, 1602, 1839, 0, 0, 0, 1611, 0, 0, 0, + 1076, 0, 680, 646, 0, 876, 0, 646, 0, 0, + 162, 4020, 0, 0, 0, 1603, 0, 0, 0, 0, + 680, 0, 0, 0, 680, 1840, 0, 0, 0, 0, + 1076, 0, 32, 0, 567, 0, 1196, 0, 1841, 0, + 0, 680, 1197, 0, 568, 0, 0, 0, 0, 1198, + 0, 1842, 0, 680, 773, 0, 0, 1875, 1597, 0, + 0, 1598, 185, 0, 0, 0, 1200, 0, 0, 0, + 0, 1613, 0, 4011, 1201, 0, 0, 2910, 1599, 0, + 0, 0, 0, 0, 0, 2930, 1601, 569, 0, 1843, + 0, 570, 1602, 571, 0, 680, 0, 0, 0, 572, + 0, 0, 573, 1081, 742, 742, 0, 0, 0, 0, + 0, 0, 0, 0, 0, -2162, 1603, 0, 1844, 1605, + 0, 0, 0, 1845, 0, 1202, 0, 0, 574, 2753, + 575, 0, 0, 0, 576, 0, 875, 0, 0, 0, + 1606, 1607, 577, 0, 0, 737, 0, 578, 0, 0, + 4193, 0, 0, 0, 0, 737, -2162, 0, 775, 579, + 2937, 1614, 1615, 1616, 0, 1617, 1618, 1619, 1620, 1621, + 1622, 742, 580, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1610, 680, 0, 0, 0, 0, + 4221, 742, 742, 4092, 0, 0, 0, 1611, 0, 0, + 0, 0, 0, 0, 0, 680, 680, 680, 742, 0, + 737, 0, 0, 0, 0, 0, 1604, 0, 0, 1846, + 1605, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 742, 742, 742, 0, 0, + 0, 1606, 1607, 0, 0, 0, 0, 185, 0, 0, + 0, 0, 0, 0, 0, 876, 0, 1608, 0, 1076, + 0, 0, 0, 0, 0, 0, 0, 0, 876, 0, + 0, 1596, -2162, 0, 0, 0, 1597, 0, 1847, 1598, + 0, 0, 1609, 0, 1848, 1610, 0, 1849, 0, 0, + 1489, 1489, 0, 0, 0, 680, 1599, 623, 1611, 1600, + 0, 1612, 4287, 0, 1601, 0, 0, 0, 0, 0, + 1602, 0, 0, 1850, 1520, 0, 0, 680, 0, 1851, + 1526, 876, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1852, 1076, 1603, 0, 0, 4274, 0, 0, + 0, 0, 0, 162, 4245, 166, 4242, 4243, 4244, 0, + 0, 0, 0, 0, 0, 0, 0, 1853, 0, 0, + 0, 0, 1076, 0, 4266, 0, 1617, 1618, 1619, 1620, + 1621, 1622, 0, 1613, 0, 0, 0, 0, 4273, 4245, + 166, 4242, 4243, 4244, 0, 0, 0, 0, 0, 0, + 1076, 1076, 0, 1076, 0, 0, 2750, 0, 4265, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1076, 4266, 0, 0, 0, 1188, 0, 0, 0, 4266, + 0, 0, 162, 4245, 166, 4242, 4243, 4244, 0, 0, + 0, 0, 876, 0, 1604, 0, 0, 0, 1605, 0, + 876, 876, 0, 0, 0, 4265, 680, 1189, 0, 1076, + 0, 0, 0, 4265, 0, 0, 0, 0, 0, 1606, + 1607, 0, 0, 1614, 1615, 1616, 0, 1617, 1618, 1619, + 1620, 1621, 1622, 0, 0, 1608, 0, 0, 1076, 0, + 2889, 0, 1076, 1076, 0, 0, 0, 0, 0, 0, + 0, 0, 680, 680, 1793, 0, 0, 0, 0, 0, + 1609, 0, 1190, 1610, 0, 0, 0, 0, 0, 0, + 646, 0, 0, 0, 0, 0, 1611, 0, 0, 1612, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1191, 0, 0, 0, 0, 0, 0, + 0, 0, 646, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 680, 1898, 0, 0, 0, 0, + 0, 680, 2751, 0, 742, 0, 0, 0, 1192, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1597, 0, + 0, 1598, 775, 0, 0, 0, 0, 0, 0, 680, + 0, 1613, 0, 0, 0, 0, 0, 1193, 1599, 0, + 0, 0, 0, 0, 0, 0, 1601, 0, 0, 680, + 0, 0, 1602, 1597, 0, 0, 1598, 742, 742, 742, + 742, 680, 0, 0, 0, 0, 0, 0, 0, 0, + 756, 0, 646, 1599, 0, 680, 1603, 0, 0, 0, + 0, 1601, 0, 0, 0, 0, 2001, 1602, 680, 0, + 0, 0, 0, 0, 0, 0, 742, 742, 0, 32, + 0, 0, 742, 1196, 0, 0, 0, 0, 0, 1197, + 0, 1603, 0, 0, 0, 0, 1198, 0, 0, 0, + 0, 1614, 1615, 1616, 1875, 1617, 1618, 1619, 1620, 1621, + 1622, 0, 0, 1200, 0, 0, 0, 0, 0, 0, + 0, 1201, 0, 0, 0, 0, 0, 0, 742, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 756, 0, 0, 0, + 0, 0, 742, 742, 742, 742, 1604, 0, 0, 0, + 1605, 0, 756, 0, 0, 0, 0, 0, 0, 0, + 0, 2001, 1202, 0, 0, 0, 2753, 3266, 0, 0, + 737, 1606, 1607, 0, 0, 0, 0, 745, 0, 737, + 0, 1604, 0, 0, 0, 1605, 0, 1608, 0, 775, + 0, 0, 0, 0, 742, 0, 0, 0, 0, 0, + 0, 0, 0, 742, 0, 756, 1606, 1607, 0, 742, + 742, 0, 1609, 0, 680, 1610, 926, 0, 0, 0, + 0, 0, 1608, 0, 0, 0, 0, 0, 1611, 0, + 0, 1612, 0, 0, 0, 0, 0, 0, 0, 1489, + 0, 0, 0, 0, 0, 0, 742, 1609, 737, 0, + 1610, 0, 680, 680, 0, 742, 0, 0, 0, 0, + 0, 680, 0, 1611, 0, 0, 1612, 0, 0, 0, + 0, 0, 0, 0, 623, 623, 0, 0, 2201, 0, + 0, 0, 1076, 0, 1076, 0, 0, 0, 0, 0, + 0, 1076, 0, 0, 1076, 0, 0, 0, 1076, 0, + 0, 1597, 0, 1613, 1598, 0, 1076, 1076, 0, 0, + 0, 0, 0, 0, 1076, 0, 775, 1076, 1076, 1076, + 1076, 1599, 0, 0, 0, 0, 0, 1076, 1076, 1601, + 1076, 0, 1076, 1076, 0, 1602, 1076, 0, 1613, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1076, 0, 0, 0, 742, 1076, 0, 1603, + 0, 1076, 0, 0, 0, 1076, 0, 1076, 1076, 1076, + 1076, 1076, 1076, 1076, 1076, 1076, 0, 1076, 0, 0, + 0, 680, 1076, 0, 1076, 0, 0, 0, 0, 0, + 680, 0, 0, 1614, 1615, 1616, 0, 1617, 1618, 1619, + 1620, 1621, 1622, 0, 0, 0, 0, 2289, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1212, 0, 0, 1614, 1615, + 1616, 1213, 1617, 1618, 1619, 1620, 1621, 1622, 0, 0, + 0, 0, 3169, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1604, + 0, 0, 0, 1605, 0, 0, 0, 0, 0, 0, + 0, 1214, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1606, 1607, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1608, 0, 0, 0, 0, 680, 0, 680, 0, 1076, + 0, 0, 0, 1212, 0, 0, 0, 0, 0, 1213, + 1215, 0, 0, 0, 0, 1609, 0, 1216, 1610, 0, + 1217, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1611, 0, 0, 1612, 2404, 0, 2411, 0, 0, + 0, 0, 0, 756, 0, 0, 0, 0, 756, 1214, + 0, 756, 745, 0, 0, 0, 0, 623, 0, 623, + 0, 0, 0, 0, 0, 0, 1597, 0, 0, 1598, + 0, 0, 1218, 756, 0, 0, 1076, 0, 0, 0, + 0, 0, 737, 0, 742, 742, 742, 0, 737, 775, + 0, 742, 0, 742, 1601, 742, 742, 0, 1215, 680, + 1602, 0, 0, 0, 0, 1216, 1613, 756, 1217, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 646, 0, + 0, 0, 0, 0, 1603, 0, 0, 1219, 0, 1220, + 0, 0, 0, 0, 756, 0, 0, 1898, 0, 1221, + 0, 0, 0, 2511, 0, 0, 0, 1222, 2520, 0, + 0, 0, 0, 0, 680, 0, 1223, 0, 756, 0, + 1218, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 2551, 2551, 0, 0, 0, 0, 0, 745, 756, 0, + 0, 756, 0, 0, 0, 0, 3381, 1224, 0, 0, + 0, 1225, 742, 0, 0, 0, 1614, 1615, 1616, 756, + 1617, 1618, 1619, 1620, 1621, 1622, 0, 0, 0, 756, + 3319, 0, 0, 0, 0, 1219, 1226, 1220, 2608, 0, + 2610, 2612, 756, 0, -2162, 0, 0, 1221, 1605, 0, + 0, 756, 0, 0, 0, 1222, 0, 0, 0, 0, + 0, 0, 0, 0, 1223, 0, 0, 0, 742, 1606, + 1607, 0, 0, 0, 0, 0, 742, 742, 742, 742, + 742, 742, 0, 0, 0, -2162, 0, 0, 0, 0, + 0, 1076, 0, 0, 1227, 1267, 0, 0, 0, 1225, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1610, 0, 0, 0, 0, 1898, 0, + 0, 0, 2551, 680, 1268, 0, 1611, 623, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1597, 0, 0, 1598, 0, + 0, 0, 0, 2608, 0, 0, 0, 0, 0, 0, + 742, 2738, 0, 0, 0, 1599, 0, 0, 0, 0, + 876, 0, 0, 1601, 0, 0, 0, 0, 0, 1602, + 0, 0, 1227, 0, 0, 742, 0, 742, 2551, 742, + 2551, 0, 0, 0, 1597, 0, 0, 1598, 0, 0, + 0, -2162, 0, 1603, 876, 0, 0, 0, 0, 1076, + 0, 0, 0, 0, 1599, 0, 0, 0, 0, 0, + 0, 1489, 1601, 0, 0, 0, 0, 0, 1602, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 756, + 0, 0, 0, 0, 0, 0, 0, 1597, 0, 0, + 1598, 0, 1603, 0, 0, 0, 0, 0, 0, 0, + 0, 756, 0, 0, 0, 737, 0, 1599, 0, 0, + 737, 0, 0, 0, 0, 1601, 0, 0, 0, 0, + 742, 1602, 0, 1597, 0, 0, 1598, 1076, 1076, 0, + 0, 0, 0, 1076, 0, 1617, 1618, 1619, 1620, 1621, + 1622, 0, 0, 1604, 0, 1603, 0, 1605, 0, 0, + 0, 1601, 0, 0, 0, 0, 0, 1602, 1076, 1076, + 0, 0, 0, 1076, 0, 0, 0, 0, 1606, 1607, + 0, 0, 0, 0, 0, 1076, 1076, 1076, 1076, 0, + 0, 1603, 0, 0, 1608, 0, 0, 0, 1076, 0, + 0, 1076, 1604, 1076, 2893, 0, 1605, 0, 0, 0, + 0, 0, 0, 1076, 1076, 0, 0, 1076, 0, 1609, + 0, 0, 1610, 0, 0, 0, 0, 1606, 1607, 0, + 1076, 0, 1076, 0, 775, 1611, 1076, 0, 1612, 0, + 0, 0, 0, 1608, 0, 0, 0, 0, 0, 0, + 0, 0, 1076, 3382, 0, 1604, 680, 0, 0, 1605, + 0, 0, 0, 2938, 0, 1076, 1076, 1076, 1609, 0, + 0, 1610, 0, 0, 0, 0, 0, 0, 0, 876, + 1606, 1607, 1076, 0, 1611, 0, 0, 1612, 0, 0, + 0, -2162, 0, 1076, 0, 1605, 1608, 0, 1076, 0, + 0, 0, 680, 0, 0, 1076, 0, 0, 0, 0, + 1613, 2938, 0, 0, 2977, 0, 1606, 1607, 2411, 0, + 0, 1609, 0, 0, 1610, 0, 0, 756, 0, 0, + 0, 0, -2162, 0, 0, 0, 0, 1611, 0, 0, + 1612, 0, 0, 0, 0, 0, 0, 0, 1076, 0, + 2551, 0, 0, 0, 0, 1489, 0, 0, 0, 1613, + 1610, 0, 0, 0, 0, 0, 0, 0, 876, 0, + 0, 0, 0, 1611, 0, 0, 742, 0, 742, 742, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1614, 1615, 1616, 0, 1617, 1618, 1619, 1620, 1621, 1622, + 0, 0, 1613, 0, 3366, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1212, 0, 0, 0, 0, + 0, 1213, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, -2162, 1614, + 1615, 1616, 0, 1617, 1618, 1619, 1620, 1621, 1622, 1212, + 0, 0, 756, 3438, 0, 1213, 0, 0, 0, 756, + 0, 1214, 0, 0, 0, 0, 0, 0, 0, 499, + 0, 0, 0, 0, 0, 544, 499, 0, 0, 0, + 0, 584, 0, 499, 0, 0, 0, 0, 499, 0, + 632, 0, 1614, 1615, 1616, 1214, 1617, 1618, 1619, 1620, + 1621, 1622, 0, 0, 0, 0, 3460, 0, 692, 0, + 1215, 0, 0, 0, 0, 0, 0, 1216, 0, 0, + 1217, 0, 0, 0, 0, 0, 0, 0, 0, 756, + 0, 0, 1617, 1618, 1619, 1620, 1621, 1622, 0, 2551, + 2551, 0, 0, 1597, 1215, 0, 1598, 0, 0, 0, + 0, 1216, 0, 0, 1217, 0, 0, 0, 0, 0, + 0, 0, 0, 1599, 0, 0, 0, 0, 0, 0, + 0, 1601, 1218, 0, 0, 0, 0, 1602, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 876, 0, 876, 0, 0, 0, 680, 0, 0, + 0, 1603, 0, 0, 0, 0, 1218, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1489, 680, 0, 0, 0, 0, 1219, 0, 1220, + 680, 0, 0, 0, 680, 0, 0, 0, 0, 1221, + 749, 0, 0, 0, 0, 0, 0, 1222, 680, 777, + 0, 780, 0, 783, 876, 785, 1223, 0, 0, 0, + 0, 1219, 0, 1220, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1221, 0, 0, 742, 0, 0, 742, + 0, 1222, 756, 0, 0, 0, 0, 1293, 0, 0, + 1223, 1225, 0, 737, 0, 0, 756, 0, 0, 0, + 0, 1604, 0, 0, 0, 1605, 0, 0, 0, 0, + 0, 0, 680, 0, 756, 0, 1294, 0, 0, 0, + 742, 1857, 0, 0, 0, 1225, 1606, 1607, 1076, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1076, 0, + 0, 0, 1608, 0, 1076, 0, 1076, 0, 0, 0, + 1858, 0, 1076, 0, 0, 1076, 1076, 1076, 1076, 1076, + 1076, 1076, 1076, 1076, 1076, 0, 0, 1609, 1076, 1076, + 1610, 0, 0, 0, 1227, 0, 0, 0, 0, 0, + 0, 1076, 0, 1611, 0, 1076, 1612, 0, 0, 1076, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1076, + 0, 0, 1076, 0, 1076, 0, 0, 0, 1227, 0, + 0, 0, 0, 1076, 1076, 1076, 0, 0, 0, 1076, + 0, 0, 1076, 0, 0, 0, 0, 0, 0, 680, + 680, 680, 2938, 3399, 0, 0, 0, 3399, 3412, 0, + 0, 0, 1076, 0, 0, 0, 0, 0, 3426, 0, + 1076, 0, 1076, 0, 0, 0, 0, 0, 1613, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1076, 0, 0, 0, 0, + 0, 1076, 0, 0, 0, 2411, 0, 1076, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1212, + 0, 0, 3466, 1489, 1489, 1213, 2001, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 742, 742, 742, 742, 0, 0, 0, 0, 0, 756, + 0, 0, 0, 0, 0, 0, 1212, 0, 0, 0, + 0, 0, 1213, 0, 0, 1214, 0, 0, 1614, 1615, + 1616, 0, 1617, 1618, 1619, 1620, 1621, 1622, 3509, 0, + 0, 0, 3702, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 833, 0, 0, 0, 0, 0, + 0, 840, 1214, 0, 0, 0, 0, 0, 0, 0, + 855, 856, 0, 0, 1215, 858, 0, 0, 0, 0, + 0, 1216, 0, 0, 1217, 872, 756, 0, 0, 756, + 0, 0, 0, 0, 1597, 0, 0, 1598, 880, 0, + 0, 0, 0, 3564, 0, 0, 0, 0, 0, 0, + 0, 1215, 901, 0, 0, 903, 0, 905, 1216, 908, + 0, 1217, 1601, 1597, 0, 0, 1598, 0, 1602, 876, + 0, 0, 0, 0, 0, 0, 1218, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1601, 1603, 0, 499, 0, 0, 1602, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 680, + 0, 0, 0, 1218, 0, 0, 964, 0, 965, 0, + 742, 1603, 1076, 0, 0, 0, 0, 0, 680, 0, + 0, 1219, 0, 1220, 0, 0, 0, 0, 0, 0, + 1898, 0, 0, 1221, 0, 0, 0, 0, 0, 0, + 680, 1222, 0, 0, 3385, 0, 0, 0, 0, 2608, + 1223, 0, 0, 0, 0, 3657, 0, 0, 1219, 1898, + 1220, 692, 0, 0, 0, 0, 0, 0, 0, 0, + 1221, 1076, 1076, 3734, 0, 0, 0, 0, 1222, 0, + 0, 2507, -2162, 0, 0, 1225, 1605, 1223, 0, 0, + 0, 0, 0, 0, 2551, 0, 2551, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 1606, 1607, 0, + 1226, -2162, 756, 0, 0, 1605, 0, 0, 2583, 0, + 0, 0, 1225, -2162, 0, 0, 0, 0, 1076, 0, + 0, 0, 0, 0, 0, 0, 1606, 1607, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 2584, 0, 0, + 0, 1610, -2162, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1296, 1611, 1076, 0, 0, 1227, 0, + 0, 0, 0, 0, 0, 1076, 1076, 0, 1308, 0, + 1610, 0, 0, 1076, 1076, 0, 0, 0, 1076, 1316, + 0, 0, 0, 1611, 1076, 1076, 1318, 0, 1076, 0, + 680, 680, 680, 680, 0, 1227, 0, 3399, 1368, 0, + 3742, 0, 0, 2938, 0, 0, 0, 2938, 0, 0, + 0, 0, 0, 3755, 0, 0, 1076, 0, 0, 0, + 0, 1076, 0, 0, 0, 0, 0, 3765, 0, -2162, + 1410, 0, 0, 1076, 0, 1597, 0, 0, 1598, 775, + 0, 0, 0, 0, 0, 0, 0, 2977, 0, 0, + 0, 2411, 0, 0, 0, 1599, 0, 0, -2162, 0, + 0, 623, 0, 1601, 1076, 0, 0, 0, 0, 1602, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 2551, 2551, 0, 0, 0, 0, + 0, 0, 499, 1603, 499, 0, 499, 0, 499, 0, + 499, 499, 499, 0, 0, 0, 0, 499, 3810, 0, + 0, 0, 0, 0, 0, 741, 743, 756, 0, 747, + 748, 0, 0, 1617, 1618, 1619, 1620, 1621, 1622, 756, + 0, 0, 0, 0, 0, 0, 786, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 742, 0, + 0, 0, 1617, 1618, 1619, 1620, 1621, 1622, 0, 0, + 0, 1212, 742, 0, 0, 0, 0, 1213, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, -115, 0, 876, 0, + 0, 0, 0, 1604, 0, 0, 1489, 1605, 0, 0, + 1, 0, 0, 0, 0, 0, 0, 1214, 0, 0, + 2, 0, 3, 4, 0, 0, 0, 0, 1606, 1607, + 0, 0, 0, 0, 1076, 0, 0, 5, 0, 0, + 0, 0, 0, 0, 1608, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 6, 0, 7, + 8, 742, 1898, 0, 0, 9, 1215, 10, 0, 1609, + 0, 0, 1610, 1216, 0, 0, 1217, 11, 0, 12, + 0, 0, 0, 0, 0, 1611, 0, 0, 1612, 680, + 0, 0, 0, 0, 0, 13, 692, 0, 14, 0, + 0, 0, 0, 0, 0, 756, 0, 0, 0, 0, + 15, 0, 16, 0, 0, 0, 17, 1076, 0, 0, + 0, 0, 18, 0, 0, 0, 1076, 0, 1218, 19, + 0, 20, 0, 0, 0, 0, 0, 21, 0, 0, + 0, 0, 0, 1076, 1076, 0, 0, 1076, 0, 0, + 0, 22, 0, 0, 3399, 0, 0, 1855, 2938, 0, + 1613, 0, 0, 2938, 0, 0, 2938, 2608, 0, 3950, + 0, 1076, 1076, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1219, 0, 1220, 0, 0, 0, 0, + 756, 0, 756, 0, 0, 1221, 3466, 775, 742, 742, + 742, 0, 0, 1222, 0, 23, 24, 0, 0, 0, + 0, 25, 1223, 0, 0, 0, 0, 0, 0, 26, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 27, 737, 775, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 2621, 0, 0, 0, 1225, 0, 0, + 1614, 1615, 1616, 0, 1617, 1618, 1619, 1620, 1621, 1622, + 0, 0, 1489, 0, 3736, 0, 835, 28, 737, 0, + 838, 680, 2622, 0, 0, 0, 0, 0, 29, 0, + 0, 0, 2551, 30, 1898, 31, 859, 0, 0, 0, + 32, 0, 0, 0, 0, 33, 3657, 0, 34, 0, + 0, 680, 35, 0, 0, 0, 0, 36, 37, 742, + 3466, 0, 0, 0, 0, 38, 0, 0, 39, 1597, + 0, 0, 1598, 0, 0, 0, 40, 802, 0, 0, + 1227, 0, 1076, 0, 0, 1076, 0, 1076, 41, 1599, + 0, 0, 0, 0, 0, 0, 2053, 1601, 0, 0, + 0, 0, 0, 1602, 1076, 42, 0, 0, 2938, 2075, + 803, 3950, 0, 0, 0, 43, 0, 4079, 0, 0, + 0, 44, 0, 804, 805, 0, 45, 1603, 0, 0, + 0, 0, 806, 0, 0, 0, 807, 742, 46, 0, + 0, 680, 0, 0, 0, 0, 0, 2117, 0, 0, + 0, 2121, 0, 808, 0, 0, 0, 0, 742, 742, + 742, 742, 2132, 0, 2134, 0, 2135, 0, 876, 0, + 0, 2136, 47, 0, 809, -115, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1076, 0, + 0, 0, 810, 0, 499, 0, 499, 0, 499, 0, + 499, 0, 499, 811, 0, 0, 499, 0, 812, 0, + 0, 0, 0, 739, 0, 0, 0, 0, 0, 0, + 0, 739, 0, 0, 0, 0, 0, 1604, 0, 813, + 0, 1605, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1076, 0, 0, 0, 0, 0, 742, + 0, 775, 1606, 1607, 814, 0, 0, 0, 0, 0, + 1076, 0, 0, 1235, 1236, 0, 0, 0, 1608, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 742, 0, 1609, 0, 737, 1610, 0, 0, 0, + 0, 0, 0, 0, 815, 3466, 0, 0, 0, 1611, + 0, 0, 1612, 0, 0, 0, 0, 0, 0, 4079, + 0, 0, 1076, 1076, 0, 756, 0, 0, 0, 0, + 1320, 0, 185, 0, 0, 737, 0, 0, 0, 0, + 0, 0, 0, 742, 0, 0, 0, 0, 0, 0, + 1378, 1379, 0, 0, 0, 0, 1212, 816, 0, 0, + 0, 817, 1213, 818, 0, 0, 0, 1406, 0, 819, + 1076, 0, 820, 0, 0, 0, 0, 0, 0, 1597, + 1076, 0, 1598, 0, 1613, 742, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1433, 1435, 0, 821, 1599, + 822, 0, 1214, 0, 823, 0, 0, 1601, 0, 0, + 0, 0, 824, 1602, 0, 0, 0, 825, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1597, 0, + 0, 1598, 0, 0, 0, 0, 0, 1603, 1076, 0, + 0, 0, 826, 0, 0, 0, 0, 737, 1599, 0, + 0, 1215, 0, 0, 0, 0, 1601, 0, 1216, 0, + 0, 1217, 1602, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1614, 1615, 1616, 0, 1617, 1618, + 1619, 1620, 1621, 1622, 0, 0, 1603, 0, 3928, 0, + 0, 0, 1597, 0, 0, 1598, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1599, 1218, 0, 0, 0, 0, 0, 0, + 1601, 0, 0, 2418, 2419, 0, 1602, 0, 2422, 2423, + 0, 0, 2426, 0, 0, 0, 0, 1604, 0, 0, + 0, 1605, 2436, 0, 0, 0, 0, 0, 0, 2445, + 1603, 0, 739, 2448, 2449, 0, 0, 2452, 2453, 2454, + 0, 0, 1606, 1607, 0, 0, 0, 0, 1219, 2468, + 1220, 2470, 0, 0, 0, 0, 0, 0, 1608, 0, + 1221, 0, 0, 0, 0, 0, 1604, 2492, 1222, 0, + 1605, 0, 2494, 0, 0, 0, 739, 1223, 0, 0, + 0, 0, 0, 1609, 0, 739, 1610, 0, 0, 0, + 0, 1606, 1607, 0, 0, 0, 0, 0, 0, 1611, + 0, 0, 1612, 2512, 2513, 2516, 2518, 1608, 3031, 0, + 2525, 2528, 1225, 0, 0, 0, 0, 0, 2539, 0, + 0, 2543, 0, 0, 0, 2547, 0, 0, 0, 0, + 1604, 0, 1609, 0, 1605, 1610, 0, 3032, 0, 0, + 0, 2570, 0, 0, 0, 0, 0, 0, 1611, 0, + 0, 1612, 2577, 0, 2579, 1606, 1607, 0, 0, 2582, + 0, 0, 0, 0, 2586, 2587, 2588, 2589, 0, 2591, + 1597, 1608, 0, 1598, 1613, 0, 0, 0, 739, 172, + 0, 0, 2614, 2615, 2616, 0, 0, 0, 0, 0, + 1599, 0, 0, 2624, 2625, 1227, 1609, 0, 1601, 1610, + 0, 0, 0, 1913, 1602, 0, 0, 0, 739, 0, + 0, 0, 1611, 0, 0, 1612, 0, 0, 0, 0, + 0, 0, 0, 1613, 0, 173, 0, 0, 1603, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 174, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 2687, 0, 175, 1970, 1971, 1972, 1973, + 0, 176, 0, 0, 1614, 1615, 1616, 0, 1617, 1618, + 1619, 1620, 1621, 1622, 0, 0, 177, 0, 3968, 0, + 0, 0, 0, 0, 0, 0, 0, 1613, 0, 0, + 0, 0, 0, 0, 178, 2009, 2010, 0, 0, 0, + 0, 2019, 0, 0, 0, 179, 1597, 0, 0, 1598, + 180, 0, 0, 1614, 1615, 1616, 181, 1617, 1618, 1619, + 1620, 1621, 1622, 739, 0, 0, 1599, 4013, 1604, 0, + 2381, 182, 1605, 739, 1601, 0, 0, 0, 0, 0, + 1602, 0, 0, 0, 0, 0, 0, 2044, 0, 0, + 0, 0, 0, 1606, 1607, 1364, 183, 0, 0, 0, + 0, 0, 0, 0, 1603, 0, 0, 0, 0, 1608, + 0, 2077, 2078, 2079, 2080, 0, 0, 1614, 1615, 1616, + 0, 1617, 1618, 1619, 1620, 1621, 1622, 0, 739, 0, + 0, 4192, 0, 0, 1609, 0, 2807, 1610, 0, 0, + 0, 0, 0, 0, 0, 0, 184, 0, 0, 2382, + 1611, 0, 0, 1612, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 2133, 0, 0, 0, 0, 0, 0, + 0, 0, 2137, 0, 185, 0, 0, 739, 0, 2144, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 186, + 0, 0, 0, 0, 1604, 187, 0, 1597, 1605, 0, + 1598, 188, 0, 0, 189, 0, 0, 0, 0, 0, + 0, 0, 1364, 0, 0, 1613, 0, 1599, 0, 1606, + 1607, 0, 0, 0, 0, 1601, 0, 0, 0, 0, + 190, 1602, 191, 0, 0, 1608, 192, 0, 0, 0, + 0, 739, 0, 0, 193, 0, 0, 0, 0, 194, + 0, 0, 0, 0, 0, 1603, 0, 0, 0, 0, + 1609, 195, 1063, 1610, 0, 0, 0, 0, 0, 0, + 739, 0, 0, 0, 196, 0, 1611, 0, 0, 1612, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1120, 0, 0, 0, 0, 0, 739, 739, + 0, 739, 0, 0, 0, 1614, 1615, 1616, 0, 1617, + 1618, 1619, 1620, 1621, 1622, 2302, 0, 0, 739, 4276, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1597, 0, 0, 1598, 0, 2987, 2988, 0, + 0, 1613, 0, 0, 0, 1604, 0, 739, 1744, 1605, + 0, 0, 1599, 0, 0, 0, 0, 0, 0, 0, + 1601, 0, 0, 0, 0, 0, 1602, 0, 0, 0, + 1606, 1607, 0, 0, 0, 0, 739, 0, 0, 0, + 739, 739, 0, 0, 0, 0, 1608, 0, 0, 0, + 1603, 0, 2383, 0, 0, 1364, 0, 3021, 3023, 0, + 0, 1744, 3023, 0, 0, 0, 0, 3034, 3035, 3036, + 0, 1609, 0, 0, 1610, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 1611, 0, 0, + 1612, 1614, 1615, 1616, 0, 1617, 1618, 1619, 1620, 1621, + 1622, 0, 0, 3057, 3058, 3059, 3060, 0, 1364, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 2865, + 0, 0, 0, 0, 2866, 0, 0, 0, 1364, 3085, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1604, 0, 0, 0, 1605, 0, 0, 0, 0, 0, + 0, 0, 1613, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1606, 1607, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1608, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 3123, 0, 2459, 2460, 2461, 0, 0, 1364, 3127, + 2469, 0, 2471, 0, 2473, 2474, 1609, 0, 0, 1610, + 0, 0, 0, 0, 0, 0, 0, 1364, 0, 0, + 0, 0, 1611, 0, 0, 1612, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1536, 0, 1364, 0, 0, + 0, 0, 1614, 1615, 1616, 0, 1617, 1618, 1619, 1620, + 1621, 1622, 0, 0, 3434, 0, 0, 1744, 0, 0, + 0, 3212, 1364, 0, 1560, 0, 0, 0, 0, 0, + 0, 3218, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1585, 1586, 0, 1588, 0, 1613, 3237, 0, + 3239, 2576, 0, 0, 0, 0, 0, 0, 739, 0, + 0, 0, 1627, 0, 1364, 0, 0, 739, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 3278, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 3288, 1663, 0, 0, 0, 0, 0, 2633, 0, 0, + 0, 0, 0, 0, 0, 2642, 2643, 2644, 2645, 2646, + 2647, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1765, 0, 0, 0, 1775, 1778, 739, 1614, 1615, 1616, + 0, 1617, 1618, 1619, 1620, 1621, 1622, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 739, 0, 739, 0, 0, 0, 0, 0, 0, 739, + 0, 0, 739, 0, 0, 0, 739, 0, 0, 0, + 0, 0, 0, 0, 739, 739, 0, 0, 0, 2730, + 0, 0, 739, 0, 0, 739, 739, 739, 739, 0, + 0, 0, 0, 0, 0, 739, 739, 0, 739, 0, + 739, 739, 0, 0, 739, 0, 2768, 0, 2770, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1364, + 739, 1744, 0, 0, 0, 739, 0, 0, 0, 739, + 0, 0, 0, 739, 0, 739, 739, 739, 739, 739, + 739, 739, 739, 739, 0, 739, 0, 0, 0, 0, + 739, 0, 739, 0, 0, 0, 0, 0, 1597, 0, + 0, 1598, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1599, 0, + 0, 0, 0, 0, 0, 0, 1601, 0, 0, 0, + 0, 0, 1602, 0, 0, 0, 0, 0, 0, 2818, + 1597, 0, 0, 1598, 0, 0, 0, 0, 3477, 0, + 3478, 0, 0, 0, 3480, 0, 1603, 0, 0, 0, + 1599, 0, 0, 0, 0, 0, 0, 0, 1601, 3489, + 0, 0, 1597, 0, 1602, 1598, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 3497, 0, 0, 0, + 0, 0, 1599, 0, 0, 3508, 0, 0, 1603, 0, + 1601, 0, 0, 0, 0, 0, 1602, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 739, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1603, 0, 0, 0, 4250, 3536, 3537, 3538, 3539, 3540, + 3541, 3542, 0, 0, 0, 0, 3549, 3550, 0, 3552, + 3553, 3554, 3555, 3556, 3557, 3558, 1604, 0, 0, 0, + 1605, 0, 0, 0, 3565, 1744, 3567, 3568, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1606, 1607, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 739, 0, 0, 1608, 1604, 0, + 739, 0, 1605, 0, 0, 0, 739, 0, 0, 0, + 0, 0, 0, 0, 2878, 0, 0, 0, 0, 0, + 0, 0, 1609, 1606, 1607, 1610, 0, 0, 0, 0, + 1604, 0, 0, 0, 1605, 3616, 3618, 3620, 1611, 1608, + 3623, 1612, 1364, 0, 0, 1362, 0, 1364, 1364, 0, + 0, 0, 0, 2228, 0, 1606, 1607, 0, 4251, 1364, + 0, 0, 0, 0, 1609, 0, 0, 1610, 0, 0, + 0, 1608, 0, 0, 0, 1744, 2251, 0, 1744, 2253, + 1611, 0, 2264, 1612, 0, 3013, 0, 3014, 3015, 2271, + 2276, 0, 0, 0, 0, 2282, 1609, 0, 2287, 1610, + 0, 0, 3358, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1611, 1613, 2296, 1612, 3023, 0, 0, 2303, + 0, 0, 0, 2315, 0, 0, 0, 2322, 0, 2324, + 2325, 2326, 2327, 2328, 2329, 2330, 2331, 2332, 0, 2333, + 0, 0, 0, 0, 1063, 0, 2358, 0, 0, 0, + 0, 0, 0, 0, 0, 1613, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 3359, + 0, 0, 1362, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 1613, 0, 739, + 0, 1364, 0, 0, 0, 0, 1363, 0, 0, 0, + 0, 0, 0, 1614, 1615, 1616, 0, 1617, 1618, 1619, + 1620, 1621, 1622, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1597, + 0, 0, 1598, 0, 0, 1614, 1615, 1616, 0, 1617, + 1618, 1619, 1620, 1621, 1622, 0, 0, 0, 0, 1599, + 0, 0, 2828, 0, 0, 1364, 0, 1601, 0, 0, + 0, 1120, 0, 1602, 0, 0, 0, 1614, 1615, 1616, + 0, 1617, 1618, 1619, 1620, 1621, 1622, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 1603, 0, 0, + 0, 0, 0, 1647, 0, 0, 0, 739, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1363, 0, 0, 0, 0, 0, 0, + 0, 0, 3800, 3801, 3802, 3803, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 2450, 1364, + 0, 0, 0, 0, 0, 0, 0, 3816, 3817, 0, + 0, 0, 0, 739, 0, 1362, 0, 0, 739, 3826, + 3827, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 739, 739, 0, 0, 0, + 0, 739, 0, 0, 0, 3286, 0, 1604, 3287, 0, + 0, 1605, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 739, 739, 1362, 0, + 0, 739, 1606, 1607, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 739, 739, 739, 739, 0, 1608, 3311, + 0, 1744, 0, 0, 0, 0, 739, 1744, 1362, 739, + 0, 739, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 739, 739, 1609, 0, 739, 1610, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 739, 1611, + 739, 0, 1612, 3872, 739, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 739, 0, 0, 0, 0, 0, 3893, 0, 0, 0, + 0, 739, 0, 739, 739, 739, 1363, 0, 1362, 0, + 0, 0, 1597, 0, 0, 1598, 3910, 0, 0, 0, + 739, 0, 0, 0, 0, 0, 0, 1362, 0, 0, + 0, 739, 1599, 2660, 0, 0, 739, 0, 0, 0, + 1601, 0, 0, 739, 1613, 0, 1602, 1362, 0, 739, + 0, 0, 0, 0, 0, 0, 0, 1597, 0, 1890, + 1598, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1603, 0, 1362, 0, 0, 0, 0, 1599, 0, 0, + 2873, 0, 0, 0, 0, 1601, 739, 0, 0, 1363, + 0, 1602, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 499, 0, 0, 0, 0, 0, 0, 1364, + 0, 0, 0, 0, 0, 1603, 0, 0, 0, 0, + 0, 0, 0, 0, 1362, 0, 0, 0, 0, 3483, + 3484, 3485, 3486, 0, 1614, 1615, 1616, 0, 1617, 1618, + 1619, 1620, 1621, 1622, 0, 0, 0, 0, 0, 1364, + 1364, 2782, 1364, 0, 0, 0, 0, 0, 0, 1363, + 3994, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1604, 0, 0, 0, 1605, 0, 0, 0, 1363, 0, + 0, 1744, 1744, 1744, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1606, 1607, 0, 1363, 0, + 4018, 0, 0, 0, 1364, 0, 1364, 0, 0, 0, + 0, 1608, 0, 0, 0, 1604, 0, 0, 0, 1605, + 0, 0, 0, 1363, 0, 0, 0, 0, 0, 0, + 2824, 0, 0, 0, 0, 2830, 1609, 3023, 0, 1610, + 1606, 1607, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1611, 0, 0, 1612, 1608, 0, 0, 1364, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 2843, + 0, 0, 0, 0, 0, 1363, 0, 2276, 0, 2276, + 2276, 1609, 0, 1364, 1610, 0, 0, 0, 0, 0, + 2887, 0, 0, 2890, 0, 2892, 0, 1611, 0, 1362, + 1612, 0, 0, 0, 0, 1744, 0, 0, 1364, 3622, + 0, 0, 0, 0, 4095, 0, 0, 0, 0, 0, + 0, 0, 2913, 0, 2915, 1744, 1364, 1613, 2918, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 2358, 2358, 2358, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1613, 0, 2955, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1765, 0, 0, 3023, 1364, + 2965, 0, 0, 0, 0, 0, 0, 1778, 0, 0, + 0, 0, 0, 1364, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1364, 0, 0, 1614, 1615, 1616, + 0, 1617, 1618, 1619, 1620, 1621, 1622, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 2996, 739, 0, 0, 0, 0, 0, 0, 0, 0, + 1363, 0, 0, 0, 0, 0, 0, 0, 4189, 0, + 0, 0, 1614, 1615, 1616, 0, 1617, 1618, 1619, 1620, + 1621, 1622, 0, 0, 0, 0, 739, 0, 0, 1364, + 0, 0, 0, 2361, 0, 0, 739, 0, 0, 0, + 0, 0, 739, 0, 739, 0, 0, 0, 0, 1364, + 739, 0, 0, 739, 739, 739, 739, 739, 739, 739, + 739, 739, 739, 0, 0, 0, 739, 739, 0, 0, + 0, 0, 0, 0, 1364, 0, 0, 0, 0, 739, + 0, 0, 0, 739, 0, 1744, 0, 739, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 739, 0, 0, + 739, 0, 739, 0, 0, 0, 0, 0, 0, 0, + 1364, 739, 739, 739, 0, 0, 0, 739, 0, 0, + 739, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 739, 0, 1362, 0, 0, 0, 0, 1362, 1362, 0, + 739, 0, 0, 0, 0, 0, 0, 0, 739, 1362, + 739, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 739, 0, 0, 0, 0, 0, 739, + 0, 0, 0, 0, 0, 739, 1597, 0, 0, 1598, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 739, 0, 0, 0, 0, 0, 1599, 3831, 0, 2884, + 0, 0, 0, 0, 1601, 0, 0, 0, 0, 0, + 1602, 3834, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1597, + 0, 0, 1598, 0, 1603, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1599, + 0, 0, 0, 0, 0, 0, 1744, 1601, 0, 0, + 1744, 1364, 1744, 1602, 0, 0, 0, 0, 0, 0, + 0, 1362, 0, 2496, 0, 0, 0, 0, 1890, 2503, + 0, 0, 0, 0, 1624, 0, 0, 1603, 0, 0, + 1363, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 3878, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1597, 0, 0, 1598, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1604, 1599, 0, 0, 1605, 0, + 0, 1624, 0, 1601, 0, 1362, 0, 0, 0, 1602, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1606, + 1607, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 3316, 0, 0, 1603, 0, 1608, 0, 0, 0, 0, + 3320, 0, 0, 0, 0, 0, 3321, 1604, 3322, 0, + 739, 1605, 0, 0, 0, 0, 0, 0, 0, 0, + 1609, 0, 0, 1610, 0, 0, 0, 0, 0, 0, + 3340, 3341, 1606, 1607, 0, 1364, 1611, 0, 0, 1612, + 0, 0, 1363, 0, 0, 0, 0, 0, 1608, 1362, + 0, 2282, 0, 0, 0, 0, 0, 3973, 3975, 3975, + 0, 3369, 0, 0, 3372, 0, 3374, 0, 1364, 739, + 739, 0, 0, 1609, 0, 3378, 1610, 0, 0, 0, + 0, 3383, 0, 0, 3386, 0, 0, 0, 0, 1611, + 0, 0, 1612, 1604, 0, 0, 0, 1605, 0, 0, + 0, 0, 0, 0, 3415, 0, 0, 0, 0, 0, + 0, 1613, 3427, 0, 2358, 0, 1890, 0, 1606, 1607, + 0, 0, 0, 0, 0, 0, 739, 0, 0, 0, + 0, 0, 0, 0, 1608, 0, 0, 3441, 0, 0, + 0, 0, 0, 1063, 0, 0, 0, 0, 0, 1120, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1609, + 0, 0, 1610, 739, 1613, 0, 0, 0, 4047, 0, + 0, 0, 0, 739, 739, 1611, 1364, 0, 1612, 0, + 0, 739, 739, 0, 0, 0, 739, 1364, 0, 0, + 3315, 0, 739, 739, 0, 0, 739, 0, 0, 0, + 1363, 1614, 1615, 1616, 0, 1617, 1618, 1619, 1620, 1621, + 1622, 739, 1354, 0, 0, 739, 0, 0, 0, 0, + 0, 0, 0, 0, 739, 0, 0, 0, 0, 739, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 739, 0, 0, 0, 0, 4089, 0, 0, 0, + 1613, 0, 0, 0, 1614, 1615, 1616, 0, 1617, 1618, + 1619, 1620, 1621, 1622, 0, 0, 0, 0, 4107, 0, + 4109, 0, 739, 0, 0, 0, 1212, 0, 0, 0, + 0, 0, 1213, 0, 0, 0, 0, 0, 0, 0, + 1364, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1624, 0, 0, 0, 0, 0, 0, 1247, 0, 1744, + 0, 0, 0, 0, 0, 0, 0, 0, 1364, 1362, + 0, 0, 1214, 0, 0, 0, 0, 0, 0, 0, + 1364, 0, 0, 0, 0, 0, 0, 0, 0, 1354, + 1614, 1615, 1616, 0, 1617, 1618, 1619, 1620, 1621, 1622, + 0, 0, 0, 1248, 0, 0, 0, 0, 3975, 1362, + 1362, 0, 1362, 0, 2361, 2361, 2361, 0, 0, 0, + 0, 1215, 0, 0, 1364, 0, 0, 1624, 1216, 0, + 0, 1217, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1744, 0, 0, 0, 0, 0, + 4190, 1624, 0, 0, 0, 0, 2260, 0, 0, 0, + 0, 0, 0, 0, 1362, 0, 1362, 0, 0, 0, + 0, 0, 0, 3670, 3671, 0, 1624, 1624, 0, 1624, + 1249, 0, 739, 1218, 0, 0, 0, 0, 1597, 0, + 0, 1598, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 4224, 0, 0, 0, 0, 0, 1599, 0, + 0, 3365, 0, 0, 0, 0, 1601, 0, 1624, 1362, + 1363, 0, 1602, 0, 0, 0, 1250, 0, 1251, 0, + 3700, 0, 0, 0, 1364, 0, 0, 0, 1252, 0, + 1220, 0, 0, 1362, 4257, 0, 1603, 0, 0, 0, + 1221, 0, 0, 0, 1624, 0, 0, 0, 1222, 0, + 1890, 2503, 0, 2503, 0, 739, 1253, 1223, 1362, 1364, + 0, 0, 0, 0, 739, 0, 0, 3718, 3720, 0, + 0, 0, 1354, 0, 0, 0, 1362, 0, 0, 0, + 3727, 739, 739, 0, 0, 739, 3732, 3733, 2571, 0, + 3735, 0, 1225, 1255, 0, 0, 739, 0, 0, 0, + 0, 739, 0, 0, 739, 1363, 0, 1363, 0, 739, + 739, 0, 0, 0, 0, 0, 0, 2572, 2358, 0, + 0, 0, 0, 2358, 0, 1354, 0, 0, 1257, 1597, + 0, 0, 1598, 0, 739, 2358, 1604, 0, 0, 1362, + 1605, 0, 0, 0, 0, 0, 1624, 0, 0, 1599, + 0, 0, 0, 1362, 0, 1354, 1624, 1601, 0, 1624, + 1363, 1606, 1607, 1602, 1362, 1364, 3781, 0, 0, 739, + 0, 0, 0, 0, 0, 1227, 0, 1608, 0, 0, + 0, 0, 0, 0, 1363, 0, 0, 1603, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1609, 0, 0, 1610, 739, 0, 0, 2503, + 0, 0, 0, 0, 0, 0, 0, 0, 1611, 0, + 0, 1612, 0, 0, 0, 1354, 0, 2503, 0, 1362, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1354, 0, 0, 0, 739, 1362, + 1364, 1356, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1354, 0, 0, 0, 0, 0, + 739, 1364, 0, 739, 1362, 739, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 1604, 0, 1354, + 1363, 1605, 739, 1613, 0, 0, 739, 0, 0, 0, + 0, 1364, 0, 0, 2503, 0, 0, 0, 0, 0, + 1362, 0, 1606, 1607, 0, 1363, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 3861, 0, 1608, 0, + 0, 0, 0, 0, 0, 1744, 0, 0, 1364, 0, + 0, 1354, 1364, 1364, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1609, 0, 0, 1610, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1611, + 0, 0, 0, 0, 0, 0, 739, 0, 1356, 0, + 1363, 0, 0, 1614, 1615, 1616, 0, 1617, 1618, 1619, + 1620, 1621, 1622, 0, 0, 0, 0, 0, 0, 0, + 1363, 0, 0, 1364, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1363, 0, 0, 0, 0, + 0, 739, 0, 0, 0, 0, 0, 0, 0, 3936, + 0, 0, 0, 0, 1613, 0, 0, 0, 739, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1363, 0, 0, 3953, 1357, 0, 0, 0, 0, + 0, 1362, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 739, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 739, 0, 0, 0, 0, 0, 0, + 0, 2361, 0, 0, 0, 0, 0, 0, 0, 0, + 739, 739, 0, 0, 0, 0, 1354, 0, 0, 0, + 0, 0, 0, 739, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1614, 1615, 1616, 0, 1617, 1618, + 1619, 1620, 1621, 1622, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 739, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 739, 0, + 0, 1356, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1744, 0, 0, 0, 0, 1359, + 0, 0, 1357, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1624, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 2503, 0, 1356, 1362, 739, 2282, 0, 0, + 0, 1744, 1624, 0, 1624, 739, 2260, 2260, 2861, 1744, + 0, 2260, 0, 0, 0, 1624, 4070, 0, 0, 0, + 0, 0, 1624, 0, 1356, 0, 0, 1624, 1362, 0, + 0, 0, 0, 1624, 0, 0, 0, 0, 1624, 0, + 0, 0, 0, 0, 0, 0, 0, 1624, 0, 0, + 0, 2260, 2260, 0, 1624, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1624, 0, 0, 0, + 0, 0, 0, 1624, 0, 1624, 1624, 1624, 1624, 1624, + 1624, 1624, 1624, 1624, 1624, 0, 1359, 0, 0, 0, + 0, 0, 0, 0, 1356, 0, 0, 0, 0, 0, + 4131, 0, 0, 0, 0, 0, 0, 0, 0, 1624, + 0, 0, 0, 1356, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1356, 0, 0, 1362, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1363, 1362, 0, 0, + 0, 0, 0, 0, 0, 1357, 0, 0, 1356, 0, + 0, 0, 0, 0, 0, 0, 1360, 0, 0, 1354, + 0, 0, 4171, 0, 1354, 1354, 0, 0, 0, 1890, + 0, 0, 0, 0, 0, 0, 1354, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1624, 0, 0, 0, 0, 0, 0, 1357, 0, + 1356, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 4210, 4210, 0, 0, 1357, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1362, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1362, 1359, + 0, 0, 4210, 0, 0, 0, 0, 1363, 0, 0, + 1362, 0, 4254, 1360, 0, 0, 0, 0, 1363, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1357, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1354, 0, + 0, 0, 0, 0, 0, 0, 0, 1357, 0, 0, + 0, 0, 1359, 0, 1362, 2361, 0, 0, 0, 0, + 2361, 0, 0, 0, 0, 0, 0, 1357, 0, 0, + 4210, 0, 2361, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1359, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1357, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1356, 0, 0, 0, 0, + 0, 0, 1354, 0, 0, 0, 0, 0, 0, 0, + 0, 1363, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1624, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1357, 0, 0, 0, 0, 1363, + 0, 0, 1359, 0, 0, 0, 0, 0, 0, 0, + 0, 1363, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1359, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1359, 0, 0, 0, 0, 1354, 0, 0, 1362, + 0, 0, 0, 0, 0, 1363, 1360, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1359, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1624, 0, 0, 0, 0, 0, 1360, + 0, 0, 0, 0, 0, 0, 0, 0, 1359, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1360, + 0, 0, 0, 0, 0, 1624, 0, 0, 0, 0, + 0, 1624, 0, 0, 0, 1362, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 3902, 0, 2861, 2861, 1357, + 2260, 0, 0, 2260, 2260, 2260, 2260, 2260, 2260, 2260, + 2260, 2260, 2260, 2861, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1363, 0, 0, 0, 0, 0, 0, 0, 1624, 1360, + 0, 1624, 0, 1624, 0, 0, 0, 0, 2861, 2861, + 0, 0, 0, 0, 0, 0, 0, 0, 1360, 0, + 0, 0, 2260, 2260, 1624, 1361, 1624, 511, 1356, 1624, + 1362, 0, 0, 1356, 1356, 0, 0, 0, 1360, 512, + 0, 0, 0, 0, 0, 1356, 0, 0, 0, 0, + 0, 1362, 0, 0, 0, 0, 0, 0, 0, 0, + 513, 0, 0, 1360, 0, 0, 1624, 0, 0, 0, + 0, 0, 0, 514, 0, 0, 1624, 0, 0, 0, + 0, 1362, 515, 1359, 0, 0, -692, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 2503, 0, 0, 0, + 0, 0, 0, 516, 0, 0, 1354, 1624, 0, 517, + 0, 0, 0, 0, 0, 1360, 0, 0, 1362, 0, + 0, 0, 1362, 1362, 518, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 519, 0, 0, 0, 1354, 1354, 0, 1354, + 0, 0, 1361, 520, 0, 0, 0, 0, 0, 0, + 521, 0, 0, 0, 522, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 1356, 0, -881, + 0, 2503, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1354, 1363, 1354, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 523, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1363, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1357, 0, 0, 0, 0, 1357, 1357, 0, + 0, 1356, 0, 0, 524, 0, 1354, 525, 0, 1357, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1363, + 0, 0, 0, 1363, 1363, 0, 0, 0, 0, 0, + 1354, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1360, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1354, 0, 526, 0, 0, + 2260, 0, 0, 527, 0, 0, 0, 0, 0, -369, + 0, 0, 528, 1354, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 3902, 1356, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1361, 0, 0, -369, 0, + 529, 530, 0, 531, 532, 0, 0, 0, 0, 0, + 0, 0, 533, 0, 0, 0, 1359, 534, 0, 0, + 0, 1359, 1359, 535, 0, 0, 536, 0, 0, 537, + 0, 0, 0, 1359, 0, 0, 1354, 0, 0, 0, + 0, 1357, -369, 0, 0, 0, 0, 0, 1361, 0, + 1354, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1354, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 1624, 1361, 0, + 0, 1624, 1624, 1624, 0, 0, 2861, 0, 0, 0, + 0, 2861, 2861, 2861, 2861, 2861, 2861, 2861, 2861, 2861, + 2861, 1624, 1624, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1357, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1354, 0, 0, 0, + 1624, 2260, 2260, 1624, 0, 1624, 0, 0, 0, 1624, + 2861, 2861, 0, 0, 1624, 0, 1354, 1624, 1361, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1359, 0, 1361, 0, 0, + 0, 1354, 0, 0, 0, 0, 1624, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 1361, 1624, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1357, + 0, 0, 1624, 0, 0, 0, 0, 1354, 0, 0, + 0, 0, 1361, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1360, 0, 0, 0, 0, 1360, 1360, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1359, + 1360, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1356, 0, 0, 0, 0, + 0, 0, 0, 0, 1361, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1356, 1356, 0, 1356, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1359, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1356, 0, 1356, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1354, 0, + 0, 0, 1360, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 2861, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1356, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1356, + 0, 1624, 1624, 0, 0, 0, 0, 0, 0, 1361, + 0, 0, 0, 0, 0, 0, 1360, 0, 0, 0, + 0, 0, 0, 0, 1356, 0, 0, 0, 0, 0, + 0, 1624, 0, 0, 0, 2260, 0, 0, 0, 1357, + 0, 0, 1356, 0, 0, 0, 0, 0, 0, 1624, + 0, 1624, 0, 0, 0, 0, 2861, 2861, 1624, 0, + 0, 2260, 2260, 1624, 1624, 0, 1624, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1357, + 1357, 0, 1357, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1354, 0, 0, 0, 0, 0, 0, 0, + 1360, 0, 0, 0, 0, 1356, 0, 0, 0, 0, + 0, 0, 1624, 0, 0, 0, 0, 0, 0, 1356, + 0, 0, 0, 0, 0, 1354, 0, 0, 0, 0, + 1356, 0, 0, 0, 1357, 0, 1357, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1359, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1357, + 0, 0, 1624, 0, 0, 1356, 0, 0, 0, 0, + 0, 0, 0, 1359, 1359, 0, 1359, 0, 0, 0, + 0, 0, 0, 1357, 0, 1356, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1354, 0, 0, 0, 0, 1357, 0, + 1356, 0, 0, 0, 1354, 0, 0, 0, 0, 2861, + 2260, 0, 0, 0, 0, 0, 1357, 0, 1359, 0, + 1359, 0, 0, 0, 0, 2861, 2861, 1624, 0, 0, + 0, 0, 0, 0, 0, 0, 1356, 0, 0, 0, + 0, 0, 0, 0, 1624, 0, 0, 0, 0, 0, + 0, 0, 1361, 0, 0, 0, 0, 1361, 1361, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1361, + 0, 0, 0, 1359, 0, 0, 0, 0, 0, 1357, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1357, 0, 0, 0, 1359, 0, 0, + 0, 0, 0, 0, 1357, 0, 0, 1354, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1359, 0, 0, 0, 0, 0, 0, 0, + 1360, 0, 0, 0, 0, 1354, 0, 0, 0, 0, + 1359, 0, 0, 0, 0, 0, 0, 1354, 0, 0, + 0, 2861, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1624, 0, 0, 0, 0, 0, 0, 0, 1357, + 1360, 1360, 0, 1360, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1357, + 0, 1354, 0, 0, 0, 0, 0, 1356, 0, 0, + 0, 1361, 0, 1359, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1357, 0, 0, 1359, 0, 0, + 0, 0, 1624, 0, 0, 1360, 0, 1360, 1359, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1357, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1624, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1361, 0, 0, 0, 0, + 1360, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1359, 0, 0, 0, 0, 0, 0, + 0, 1624, 0, 0, 1360, 0, 0, 0, 0, 0, + 0, 0, 0, 1359, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1360, + 0, 0, 0, 0, 0, 0, 1354, 0, 1359, 0, + 0, 0, 0, 0, 0, 1624, 0, 1360, 0, 0, + 0, 1356, 0, 0, 0, 0, 0, 0, 0, 1361, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1359, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1356, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1360, 1357, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1360, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1360, 0, 0, 0, 0, + 0, 0, 1354, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1356, 0, 0, 0, 0, 0, 0, 0, + 1360, 0, 0, 1356, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1360, 0, 0, 0, 0, 0, 0, 1354, 0, 0, + 0, 0, 0, 0, 0, 1359, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1360, 0, 0, 1354, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1357, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1354, 0, + 0, 1360, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1357, 0, + 0, 0, 0, 0, 0, 0, 1356, 0, 0, 0, + 0, 0, 0, 0, 0, 1354, 0, 0, 0, 1354, + 1354, 0, 0, 0, 0, 0, 0, 0, 0, 1361, + 0, 0, 0, 0, 1356, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1356, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1361, + 1361, 0, 1361, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1359, + 1356, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1357, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 1357, 0, 0, + 0, 0, 1359, 0, 1361, 0, 1361, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1360, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1361, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1361, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1357, 0, 0, 0, 0, 0, 0, 0, 1361, 0, + 1359, 0, 0, 0, 0, 1356, 0, 0, 0, 0, + 0, 1359, 0, 0, 0, 0, 1361, 0, 1357, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1357, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1360, 0, 0, 0, + 0, 0, 0, 0, 1357, 0, 0, 0, 0, 1361, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1361, 0, 0, 0, 0, 0, 1360, + 0, 0, 0, 0, 1361, 0, 0, 0, 0, 0, + 0, 1356, 0, 0, 1359, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1359, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1359, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1361, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1361, + 0, 0, 0, 0, 0, 0, 1356, 0, 1359, 0, + 0, 0, 0, 0, 0, 0, 0, 1360, 0, 0, + 0, 0, 0, 0, 1361, 0, 0, 1356, 1360, 1357, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 1356, 0, 0, + 1361, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1356, 0, 0, 0, 1356, 1356, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1360, 0, 0, 0, 1357, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1359, 0, 0, 0, 0, 0, 1360, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1360, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1360, 0, 0, 0, 0, + 1357, 1361, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1357, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1359, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1357, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1357, 0, + 0, 0, 1357, 1357, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1359, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1360, 0, 0, 0, 0, 1359, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1361, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1359, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1361, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1359, 0, 0, 0, 1359, 1359, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1360, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1361, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 1361, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1360, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1360, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1360, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1361, 0, 0, 0, 0, 0, 0, 0, 0, 1360, + 0, 0, 0, 1360, 1360, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1361, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1361, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1361, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1361, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1361, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1361, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1361, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1361, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 712, 981, 550, 982, 983, 984, + 597, 985, 0, 0, 0, 200, 201, 202, 203, 204, + 205, 206, 207, 2352, 209, 210, 211, 0, 1361, 0, + 0, 986, 1361, 1361, 212, 213, 0, 214, 215, 713, + 216, 217, 218, 219, 987, 714, 988, 989, 0, 223, + 224, 225, 226, 227, 990, 991, 228, 229, 992, 993, + 232, 0, 233, 234, 235, 236, 994, 0, 995, 0, + 238, 239, 240, 241, 716, 242, 243, 0, 244, 245, + 246, 247, 248, 249, 0, 717, 250, 251, 996, 997, + 998, 999, 1000, 1001, 1002, 252, 253, 254, 255, 256, + 257, 1003, 1004, 260, 0, 261, 0, 262, 263, 264, + 265, 266, 0, 267, 268, 269, 2353, 0, 270, 271, + 1005, 273, 274, 0, 275, 276, 277, 0, 278, 279, + 0, 280, 281, 282, 283, 1006, 285, 286, 287, 1007, + 1008, 289, 0, 290, 1009, 292, 0, 293, 0, 294, + 719, 0, 720, 295, 296, 297, 0, 298, 1010, 0, + 300, 0, 301, 302, 303, 304, 305, 721, 306, 307, + 308, 0, 309, 310, 311, 312, 313, 314, 0, 315, + 722, 316, 317, 318, 319, 320, 1011, 1012, 0, 1013, + 0, 324, 723, 724, 325, 725, 326, 327, 328, 329, + 330, 331, 332, 0, 333, 1014, 726, 335, 727, 0, + 336, 337, 338, 1015, 1016, 339, 340, 341, 342, 343, + 344, 345, 346, 347, 348, 349, 350, 1017, 728, 1018, + 353, 354, 355, 1019, 356, 357, 729, 358, 1020, 1021, + 360, 1022, 362, 363, 364, 0, 365, 0, 0, 1023, + 367, 368, 0, 0, 369, 730, 731, 732, 1024, 371, + 372, 373, 374, 375, 376, 377, 0, 378, 1025, 380, + 381, 382, 383, 384, 0, 385, 386, 387, 388, 389, + 390, 391, 1026, 393, 394, 395, 396, 0, 397, 398, + 399, 400, 401, 402, 403, 404, 405, 406, 0, 407, + 408, 733, 409, 410, 1027, 412, 413, 414, 415, 416, + 417, 418, 419, 0, 420, 421, 422, 423, 424, 1028, + 425, 426, 427, 428, 734, 429, 1029, 431, 0, 432, + 433, 434, 435, 436, 437, 438, 439, 440, 441, 1030, + 0, 443, 444, 0, 445, 446, 447, 448, 449, 450, + 0, 1031, 1032, 0, 0, 453, 1033, 455, 1034, 1035, + 457, 458, 459, 460, 461, 462, 463, 0, 1036, 464, + 465, 466, 467, 468, 1037, 0, 469, 470, 471, 472, + 473, 474, 1038, 2354, 476, 735, 477, 478, 479, 0, + 0, 480, 0, 0, 481, 482, 483, 484, 485, 486, + 1039, 1040, 1041, 1042, 1043, 1044, 1045, 1046, 495, 496, + 497, 0, 0, 0, 0, 0, 0, 0, 1047, 1048, + 2355, 0, 0, 0, 0, 0, 0, 1050, 2356, 712, + 981, 550, 982, 983, 984, 597, 985, 0, 0, 0, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 986, 0, 0, 212, + 213, 0, 214, 215, 713, 216, 217, 218, 219, 987, + 714, 988, 989, 0, 223, 224, 225, 226, 227, 990, + 991, 228, 229, 992, 993, 232, 0, 233, 234, 235, + 236, 994, 0, 995, 0, 238, 239, 240, 241, 716, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 0, + 717, 250, 251, 996, 997, 998, 999, 1000, 1001, 1002, + 252, 253, 254, 255, 256, 257, 1003, 1004, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 1005, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 1006, 285, 286, 287, 1007, 1008, 289, 0, 290, 1009, + 292, 0, 293, 0, 294, 719, 0, 720, 295, 296, + 297, 0, 298, 1010, 0, 300, 0, 301, 302, 303, + 304, 305, 721, 306, 307, 308, 0, 309, 310, 311, + 312, 313, 314, 0, 315, 722, 316, 317, 318, 319, + 320, 1011, 1012, 0, 1013, 0, 324, 723, 724, 325, + 725, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 1014, 726, 335, 727, 0, 336, 337, 338, 1015, 1016, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 1017, 728, 1018, 353, 354, 355, 1019, 356, + 357, 729, 358, 1020, 1021, 360, 1022, 362, 363, 364, + 0, 365, 0, 0, 1023, 367, 368, 0, 0, 369, + 730, 731, 732, 1024, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 1025, 380, 381, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 1026, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 733, 409, 410, 1027, + 412, 413, 414, 415, 416, 417, 418, 419, 0, 420, + 421, 422, 423, 424, 1028, 425, 426, 427, 428, 734, + 429, 1029, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 1030, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 1031, 1032, 0, 0, + 453, 1033, 455, 1034, 1035, 457, 458, 459, 460, 461, + 462, 463, 0, 1036, 464, 465, 466, 467, 468, 1037, + 0, 469, 470, 471, 472, 473, 474, 1038, 0, 476, + 735, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 485, 486, 1039, 1040, 1041, 1042, 1043, + 1044, 1045, 1046, 495, 496, 497, 0, 0, 0, 0, + 0, 0, 0, 1047, 1048, 199, 0, 0, 0, 0, + 0, 0, 1050, 2262, 0, 0, 200, 201, 202, 203, + 204, 205, 206, 207, 0, 209, 210, 211, 0, 0, + 0, 0, 0, 3397, 0, 212, 213, 0, 214, 215, + 0, 216, 217, 218, 219, 220, 0, 221, 222, 0, + 223, 224, 225, 226, 227, 0, 0, 228, 229, 230, + 231, 232, 0, 233, 234, 235, 236, 237, 0, 0, + 0, 238, 239, 240, 241, 0, 242, 243, 0, 244, + 245, 246, 247, 248, 249, 0, -1406, 250, 251, 0, + 0, 0, 0, 0, 0, 0, 252, 253, 254, 255, + 256, 257, 258, 259, 260, 0, 261, 0, 262, 263, + 264, 265, 266, 0, 267, 268, 269, 0, 0, 270, + 271, 272, 273, 274, 0, 275, 276, 277, 0, 278, + 279, 0, 280, 281, 282, 283, 284, 285, 286, 287, + 288, 0, 289, 0, 290, 291, 292, 0, 293, 0, + 294, 0, 0, -1406, 295, 296, 297, 0, 298, 299, + 0, 300, 0, 301, 302, 303, 304, 305, 0, 306, + 307, 308, 0, 309, 310, 311, 312, 313, 314, 0, + 315, -1406, 316, 317, 318, 319, 320, 321, 322, 0, + 323, 0, 324, 0, 0, 325, -1406, 326, 327, 328, + 329, 330, 331, 332, 0, 333, 334, -1406, 335, 0, + 0, 336, 337, 338, 0, 0, 339, 340, 341, 342, + 343, 344, 345, 346, 347, 348, 349, 350, 351, -1406, + 352, 353, 354, 355, 0, 356, 357, 0, 358, 0, + 359, 360, 361, 362, 363, 364, 0, 365, 0, 0, + 366, 367, 368, 0, 0, 369, 0, 0, 0, 370, + 371, 372, 373, 374, 375, 376, 377, 0, 378, 379, + 380, 381, 382, 383, 384, 0, 385, 386, 387, 388, + 389, 390, 391, 392, 393, 394, 395, 396, 0, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 0, + 407, 408, -1406, 409, 410, 411, 412, 413, 414, 415, + 416, 417, 418, 419, 0, 420, 421, 422, 423, 424, + 0, 425, 426, 427, 428, 0, 429, 430, 431, 0, + 432, 433, 434, 435, 436, 437, 438, 439, 440, 441, + 442, 0, 443, 444, 0, 445, 446, 447, 448, 449, + 450, 0, 451, 452, 0, 0, 453, 454, 455, 456, + 0, 457, 458, 459, 460, 461, 462, 463, 0, 0, + 464, 465, 466, 467, 468, 0, 0, 469, 470, 471, + 472, 473, 474, 475, 0, 476, 0, 477, 478, 479, + 0, 0, 480, 0, 0, 481, 482, 483, 484, 485, + 486, 487, 488, 489, 490, 491, 492, 493, 494, 495, + 496, 497, 0, 0, 0, 0, 0, 0, 0, 1330, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1127, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 0, 0, 0, 212, + 213, 0, 214, 215, 713, 216, 217, 218, 0, 1331, + 714, 1332, 1333, 0, 223, 224, 225, 226, 227, 0, + 0, 228, 229, 1334, 1335, 232, 0, 233, 234, 235, + 236, 0, 0, 715, 0, 238, 239, 240, 241, 716, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 0, + 717, 250, 251, 0, 0, 0, 718, 0, 0, 0, + 252, 253, 254, 255, 256, 257, 1336, 1337, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 1005, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 0, 285, 286, 287, 0, 0, 289, 0, 290, 1338, + 292, 0, 293, 0, 294, 719, 0, 720, 295, 296, + 297, 0, 298, 0, 0, 300, 0, 301, 302, 303, + 304, 305, 721, 306, 307, 308, 1878, 309, 310, 311, + 312, 313, 314, 0, 315, 722, 1879, 317, 318, 319, + 320, 1339, 1340, 0, 1341, 0, 324, 723, 724, 325, + 725, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 0, 726, 335, 727, 0, 336, 337, 338, 0, 0, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 1342, 728, 1343, 353, 354, 0, 0, 356, + 357, 729, 358, 0, 0, 360, 1344, 362, 363, 364, + 0, 365, 0, 0, 366, 367, 368, 0, 0, 1880, + 730, 731, 732, 0, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 0, 380, 0, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 1345, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 733, 409, 410, 0, + 412, 413, 414, 415, 416, 417, 418, 419, 0, 420, + 421, 422, 423, 424, 0, 425, 1881, 427, 428, 734, + 429, 1347, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 0, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 1348, 1349, 0, 0, + 453, 0, 455, 0, 0, 457, 458, 459, 460, 461, + 462, 463, 0, 0, 464, 465, 466, 467, 468, 0, + 0, 469, 470, 471, 472, 473, 0, 1350, 1882, 476, + 735, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 485, 0, 199, 0, 0, 0, 0, + 0, 0, 0, 495, 496, 497, 200, 201, 202, 203, + 204, 205, 206, 207, 0, 209, 210, 211, 0, 0, + 0, 0, 0, 1883, 0, 212, 213, 0, 214, 215, + 0, 216, 217, 218, 219, 220, 0, 221, 222, 0, + 223, 224, 225, 226, 227, 0, 0, 228, 229, 230, + 231, 232, 0, 233, 234, 235, 236, 237, 0, 0, + 0, 238, 239, 240, 241, 0, 242, 243, 0, 244, + 245, 246, 247, 248, 249, 0, 0, 250, 251, 0, + 0, 0, 0, 0, 0, 0, 252, 253, 254, 255, + 256, 257, 258, 259, 260, 0, 261, 0, 262, 263, + 264, 265, 266, 0, 267, 268, 269, 0, 0, 270, + 271, 272, 273, 274, 0, 275, 276, 277, 0, 278, + 279, 0, 280, 281, 282, 283, 284, 285, 286, 287, + 288, 0, 289, 0, 290, 291, 292, 0, 293, 0, + 294, 0, 0, 0, 295, 296, 297, 0, 298, 299, + 0, 300, 0, 301, 302, 303, 304, 305, 0, 306, + 307, 308, 0, 309, 310, 311, 312, 313, 314, 0, + 315, 0, 316, 317, 318, 319, 320, 321, 322, 0, + 323, 0, 324, 0, 0, 325, 0, 326, 327, 328, + 329, 330, 331, 332, 0, 333, 334, 0, 335, 0, + 0, 336, 337, 338, 0, 0, 339, 340, 341, 342, + 343, 344, 345, 346, 347, 348, 349, 350, 351, 0, + 352, 353, 354, 355, 0, 356, 357, 0, 358, 0, + 359, 360, 361, 362, 363, 364, 0, 365, 0, 0, + 366, 367, 368, 0, 0, 369, 0, 0, 0, 370, + 371, 372, 373, 374, 375, 376, 377, 0, 378, 379, + 380, 381, 382, 383, 384, 0, 385, 386, 387, 388, + 389, 390, 391, 392, 393, 394, 395, 396, 0, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 0, + 407, 408, 0, 409, 410, 411, 412, 413, 414, 415, + 416, 417, 418, 419, 0, 420, 421, 422, 423, 424, + 0, 425, 426, 427, 428, 0, 429, 430, 431, 0, + 432, 433, 434, 435, 436, 437, 438, 439, 440, 441, + 442, 0, 443, 444, 0, 445, 446, 447, 448, 449, + 450, 0, 451, 452, 0, 0, 453, 454, 455, 456, + 0, 457, 458, 459, 460, 461, 462, 463, 0, 0, + 464, 465, 466, 467, 468, 0, 0, 469, 470, 471, + 472, 473, 474, 475, 0, 476, 0, 477, 478, 479, + 0, 0, 480, 0, 0, 481, 482, 483, 484, 485, + 486, 487, 488, 489, 490, 491, 492, 493, 494, 495, + 496, 497, 0, 0, 0, 0, 0, 0, 0, 1330, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 2695, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 0, 0, 0, 212, + 213, 0, 214, 215, 713, 216, 217, 218, 0, 1331, + 714, 1332, 1333, 0, 223, 224, 225, 226, 227, 0, + 0, 228, 229, 1334, 1335, 232, 0, 233, 234, 235, + 236, 0, 0, 715, 0, 238, 239, 240, 241, 716, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 0, + 717, 250, 251, 0, 0, 0, 718, 0, 0, 0, + 252, 253, 254, 255, 256, 257, 1336, 1337, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 1005, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 0, 285, 286, 287, 0, 0, 289, 0, 290, 1338, + 292, 0, 293, 0, 294, 719, 0, 720, 295, 296, + 297, 0, 298, 0, 0, 300, 0, 301, 302, 303, + 304, 305, 721, 306, 307, 308, 1878, 309, 310, 311, + 312, 313, 314, 0, 315, 722, 1879, 317, 318, 319, + 320, 1339, 1340, 0, 1341, 0, 324, 723, 724, 325, + 725, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 0, 726, 335, 727, 0, 336, 337, 338, 0, 0, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 1342, 728, 1343, 353, 354, 0, 0, 356, + 357, 729, 358, 0, 0, 360, 1344, 362, 363, 364, + 0, 365, 0, 0, 366, 367, 368, 0, 0, 1880, + 730, 731, 732, 0, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 0, 380, 0, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 1345, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 733, 409, 410, 0, + 412, 413, 414, 415, 416, 417, 418, 419, 0, 420, + 421, 422, 423, 424, 0, 425, 1881, 427, 428, 734, + 429, 1347, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 0, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 1348, 1349, 0, 0, + 453, 0, 455, 0, 0, 457, 458, 459, 460, 461, + 462, 463, 0, 0, 464, 465, 466, 467, 468, 0, + 0, 469, 470, 471, 472, 473, 0, 1350, 1882, 476, + 735, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 485, 0, 712, 981, 550, 982, 983, + 984, 597, 985, 495, 496, 497, 200, 201, 202, 203, + 204, 205, 206, 207, 0, 209, 210, 211, 0, 0, + 0, 0, 986, 2746, 0, 212, 213, 0, 214, 215, + 713, 216, 217, 218, 219, 987, 714, 988, 989, 2272, + 223, 224, 225, 226, 227, 990, 991, 228, 229, 992, + 993, 232, 0, 233, 234, 235, 236, 994, 0, 995, + 0, 238, 239, 240, 241, 716, 242, 243, 0, 244, + 245, 246, 247, 248, 249, 0, 717, 250, 251, 996, + 997, 998, 999, 1000, 1001, 1002, 252, 253, 254, 255, + 256, 257, 1003, 1004, 260, 0, 261, 0, 262, 263, + 264, 265, 266, 0, 267, 268, 269, 0, 0, 270, + 271, 1005, 273, 274, 0, 275, 276, 277, 0, 278, + 279, 0, 280, 281, 282, 283, 1006, 285, 286, 287, + 1007, 1008, 289, 0, 290, 1009, 292, 0, 293, 0, + 294, 719, 2273, 720, 295, 296, 297, 0, 298, 1010, + 0, 300, 0, 301, 302, 303, 304, 305, 721, 306, + 307, 308, 0, 309, 310, 311, 312, 313, 314, 0, + 315, 722, 316, 317, 318, 319, 320, 1011, 1012, 0, + 1013, 0, 324, 723, 724, 325, 725, 326, 327, 328, + 329, 330, 331, 332, 2274, 333, 1014, 726, 335, 727, + 0, 336, 337, 338, 1015, 1016, 339, 340, 341, 342, + 343, 344, 345, 346, 347, 348, 349, 350, 1017, 728, + 1018, 353, 354, 355, 1019, 356, 357, 729, 358, 1020, + 1021, 360, 1022, 362, 363, 364, 0, 365, 0, 0, + 1023, 367, 368, 0, 0, 369, 730, 731, 732, 1024, + 371, 372, 373, 374, 375, 376, 377, 0, 378, 1025, + 380, 381, 382, 383, 384, 0, 385, 386, 387, 388, + 389, 390, 391, 1026, 393, 394, 395, 396, 0, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 0, + 407, 408, 733, 409, 410, 1027, 412, 413, 414, 415, + 416, 417, 418, 419, 0, 420, 421, 422, 423, 424, + 1028, 425, 426, 427, 428, 734, 429, 1029, 431, 0, + 432, 433, 434, 435, 436, 437, 438, 439, 440, 441, + 1030, 0, 443, 444, 0, 445, 446, 447, 448, 449, + 450, 0, 1031, 1032, 0, 2275, 453, 1033, 455, 1034, + 1035, 457, 458, 459, 460, 461, 462, 463, 0, 1036, + 464, 465, 466, 467, 468, 1037, 0, 469, 470, 471, + 472, 473, 474, 1038, 0, 476, 735, 477, 478, 479, + 0, 0, 480, 0, 0, 481, 482, 483, 484, 485, + 486, 1039, 1040, 1041, 1042, 1043, 1044, 1045, 1046, 495, + 496, 497, 0, 0, 0, 0, 0, 0, 0, 1047, + 1048, 0, 0, 0, 0, 0, 0, 0, 1050, 712, + 981, 550, 982, 983, 984, 597, 985, 0, 0, 0, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 986, 0, 0, 212, + 213, 0, 214, 215, 713, 216, 217, 218, 219, 987, + 714, 988, 989, 0, 223, 224, 225, 226, 227, 990, + 991, 228, 229, 992, 993, 232, 0, 233, 234, 235, + 236, 994, 0, 995, 0, 238, 239, 240, 241, 716, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 0, + 717, 250, 251, 996, 997, 998, 999, 1000, 1001, 1002, + 252, 253, 254, 255, 256, 257, 1003, 1004, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 1005, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 1006, 285, 286, 287, 1007, 1008, 289, 0, 290, 1009, + 292, 0, 293, 0, 294, 719, 0, 720, 295, 296, + 297, 0, 298, 1010, 0, 300, 0, 301, 302, 303, + 304, 305, 721, 306, 307, 308, 0, 309, 310, 311, + 312, 313, 314, 0, 315, 722, 316, 317, 318, 319, + 320, 1011, 1012, 0, 1013, 0, 324, 723, 724, 325, + 725, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 1014, 726, 335, 727, 0, 336, 337, 338, 1015, 1016, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 1017, 728, 1018, 353, 354, 355, 1019, 356, + 357, 729, 358, 1020, 1021, 360, 1022, 362, 363, 364, + 0, 365, 0, 0, 1023, 367, 368, 0, 0, 369, + 730, 731, 732, 1024, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 1025, 380, 381, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 1026, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 733, 409, 410, 1027, + 412, 413, 414, 415, 416, 417, 418, 419, 37, 420, + 421, 422, 423, 424, 1028, 425, 426, 427, 428, 734, + 429, 1029, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 1030, 0, 443, 444, 41, 445, + 446, 447, 448, 449, 450, 0, 1031, 1032, 0, 0, + 453, 1033, 455, 1034, 1035, 457, 458, 459, 460, 461, + 462, 463, 0, 1036, 464, 465, 466, 467, 468, 1037, + 0, 469, 470, 471, 472, 473, 920, 1038, 0, 476, + 735, 477, 478, 479, 0, 0, 480, 0, 46, 481, + 482, 483, 484, 485, 486, 1039, 1040, 1041, 1042, 1043, + 1044, 1045, 1046, 495, 496, 497, 0, 0, 0, 0, + 0, 0, 0, 1047, 1048, 0, 0, 0, 0, 0, + 0, 0, 1050, 712, 981, 550, 982, 983, 984, 597, + 985, 0, 0, 0, 200, 201, 202, 203, 204, 205, + 206, 207, 0, 209, 210, 211, 0, 0, 0, 0, + 986, 0, 0, 212, 213, 0, 214, 215, 713, 216, + 217, 218, 219, 987, 714, 988, 989, 0, 223, 224, + 225, 226, 227, 990, 991, 228, 229, 992, 993, 232, + 0, 233, 234, 235, 236, 994, 0, 995, 0, 238, + 239, 240, 241, 716, 242, 243, 0, 244, 245, 246, + 247, 248, 249, 0, 717, 250, 251, 996, 997, 998, + 999, 1000, 1001, 1002, 252, 253, 254, 255, 256, 257, + 1003, 1004, 260, 0, 261, 0, 262, 263, 264, 265, + 266, 0, 267, 268, 269, 0, 0, 270, 271, 1005, + 273, 274, 0, 275, 276, 277, 0, 278, 279, 0, + 280, 281, 282, 283, 1006, 285, 286, 287, 1007, 1008, + 289, 0, 290, 1009, 292, 0, 293, 0, 294, 719, + 0, 720, 295, 296, 297, 0, 298, 1010, 0, 300, + 0, 301, 302, 303, 304, 305, 721, 306, 307, 308, + 0, 309, 310, 311, 312, 313, 314, 0, 315, 722, + 316, 317, 318, 319, 320, 1011, 1012, 0, 1013, 0, + 324, 723, 724, 325, 725, 326, 327, 328, 329, 330, + 331, 332, 0, 333, 1014, 726, 335, 727, 0, 336, + 337, 338, 1015, 1016, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 1017, 728, 1018, 353, + 354, 355, 1019, 356, 357, 729, 358, 1020, 1021, 360, + 1022, 362, 363, 364, 0, 365, 0, 0, 1023, 367, + 368, 0, 0, 369, 730, 731, 732, 1024, 371, 372, + 373, 374, 375, 376, 377, 0, 378, 1025, 380, 381, + 382, 383, 384, 0, 385, 386, 387, 388, 389, 390, + 391, 1026, 393, 394, 395, 396, 0, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 0, 407, 408, + 733, 409, 410, 1027, 412, 413, 414, 415, 416, 417, + 418, 419, 0, 420, 421, 422, 423, 424, 1028, 425, + 426, 427, 428, 734, 429, 1029, 431, 0, 432, 433, + 434, 435, 436, 437, 438, 439, 440, 441, 1030, 0, + 443, 444, 0, 445, 446, 447, 448, 449, 450, 0, + 1031, 1032, 0, 0, 453, 1033, 455, 1034, 1035, 457, + 458, 459, 460, 461, 462, 463, 0, 1036, 464, 465, + 466, 467, 468, 1037, 0, 469, 470, 471, 472, 473, + 474, 1038, 0, 476, 735, 477, 478, 479, 0, 0, + 480, 0, 0, 481, 482, 483, 484, 485, 486, 1039, + 1040, 1041, 1042, 1043, 1044, 1045, 1046, 495, 496, 497, + 0, 0, 0, 0, 0, 0, 0, 1047, 1048, 0, + 0, 0, 0, 0, 1531, 2220, 1050, 712, 981, 550, + 982, 983, 984, 597, 985, 0, 0, 0, 200, 201, + 202, 203, 204, 205, 206, 207, 0, 209, 210, 211, + 0, 0, 0, 0, 986, 0, 0, 212, 213, 0, + 214, 215, 713, 216, 217, 218, 219, 987, 714, 988, + 989, 0, 223, 224, 225, 226, 227, 990, 991, 228, + 229, 992, 993, 232, 0, 233, 234, 235, 236, 994, + 0, 995, 0, 238, 239, 240, 241, 716, 242, 243, + 0, 244, 245, 246, 247, 248, 249, 0, 717, 250, + 251, 996, 997, 998, 999, 1000, 1001, 1002, 252, 253, + 254, 255, 256, 257, 1003, 1004, 260, 0, 261, 0, + 262, 263, 264, 265, 266, 0, 267, 268, 269, 0, + 0, 270, 271, 1005, 273, 274, 0, 275, 276, 277, + 0, 278, 279, 0, 280, 281, 282, 283, 1006, 285, + 286, 287, 1007, 1008, 289, 0, 290, 1009, 292, 0, + 293, 0, 294, 719, 0, 720, 295, 296, 297, 0, + 298, 1010, 0, 300, 0, 301, 302, 303, 304, 305, + 721, 306, 307, 308, 0, 309, 310, 311, 312, 313, + 314, 0, 315, 722, 316, 317, 318, 319, 320, 1011, + 1012, 0, 1013, 0, 324, 723, 724, 325, 725, 326, + 327, 328, 329, 330, 331, 332, 0, 333, 1014, 726, + 335, 727, 0, 336, 337, 338, 1015, 1016, 339, 340, + 341, 342, 343, 344, 345, 346, 347, 348, 349, 350, + 1017, 728, 1018, 353, 354, 355, 1019, 356, 357, 729, + 358, 1020, 1021, 360, 1022, 362, 363, 364, 0, 365, + 0, 0, 1023, 367, 368, 0, 0, 369, 730, 731, + 732, 1024, 371, 372, 373, 374, 375, 376, 377, 0, + 378, 1025, 380, 381, 382, 383, 384, 0, 385, 386, + 387, 388, 389, 390, 391, 1026, 393, 394, 395, 396, + 0, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 0, 407, 408, 733, 409, 410, 1027, 412, 413, + 414, 415, 416, 417, 418, 419, 0, 420, 421, 422, + 423, 424, 1028, 425, 426, 427, 428, 734, 429, 1029, + 431, 0, 432, 433, 434, 435, 436, 437, 438, 439, + 440, 441, 1030, 0, 443, 444, 0, 445, 446, 447, + 448, 449, 450, 0, 1031, 1032, 0, 0, 453, 1033, + 455, 1034, 1035, 457, 458, 459, 460, 461, 462, 463, + 0, 1036, 464, 465, 466, 467, 468, 1037, 0, 469, + 470, 471, 472, 473, 474, 1038, 0, 476, 735, 477, + 478, 479, 0, 0, 480, 0, 0, 481, 482, 483, + 484, 485, 486, 1039, 1040, 1041, 1042, 1043, 1044, 1045, + 1046, 495, 496, 497, 0, 0, 0, 0, 0, 0, + 0, 1047, 1048, 1049, 0, 0, 0, 0, 0, 0, + 1050, 712, 981, 550, 982, 983, 984, 597, 985, 0, + 0, 0, 200, 201, 202, 203, 204, 205, 206, 207, + 0, 209, 210, 211, 0, 0, 0, 0, 986, 0, + 0, 212, 213, 0, 214, 215, 713, 216, 217, 218, + 219, 987, 714, 988, 989, 0, 223, 224, 225, 226, + 227, 990, 991, 228, 229, 992, 993, 232, 0, 233, + 234, 235, 236, 994, 0, 995, 0, 238, 239, 240, + 241, 716, 242, 243, 0, 244, 245, 246, 247, 248, + 249, 0, 717, 250, 251, 996, 997, 998, 999, 1000, + 1001, 1002, 252, 253, 254, 255, 256, 257, 1003, 1004, + 260, 1119, 261, 0, 262, 263, 264, 265, 266, 0, + 267, 268, 269, 0, 0, 270, 271, 1005, 273, 274, + 0, 275, 276, 277, 0, 278, 279, 0, 280, 281, + 282, 283, 1006, 285, 286, 287, 1007, 1008, 289, 0, + 290, 1009, 292, 0, 293, 0, 294, 719, 0, 720, + 295, 296, 297, 0, 298, 1010, 0, 300, 0, 301, + 302, 303, 304, 305, 721, 306, 307, 308, 0, 309, + 310, 311, 312, 313, 314, 0, 315, 722, 316, 317, + 318, 319, 320, 1011, 1012, 0, 1013, 0, 324, 723, + 724, 325, 725, 326, 327, 328, 329, 330, 331, 332, + 0, 333, 1014, 726, 335, 727, 0, 336, 337, 338, + 1015, 1016, 339, 340, 341, 342, 343, 344, 345, 346, + 347, 348, 349, 350, 1017, 728, 1018, 353, 354, 355, + 1019, 356, 357, 729, 358, 1020, 1021, 360, 1022, 362, + 363, 364, 0, 365, 0, 0, 1023, 367, 368, 0, + 0, 369, 730, 731, 732, 1024, 371, 372, 373, 374, + 375, 376, 377, 0, 378, 1025, 380, 381, 382, 383, + 384, 0, 385, 386, 387, 388, 389, 390, 391, 1026, + 393, 394, 395, 396, 0, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 0, 407, 408, 733, 409, + 410, 1027, 412, 413, 414, 415, 416, 417, 418, 419, + 0, 420, 421, 422, 423, 424, 1028, 425, 426, 427, + 428, 734, 429, 1029, 431, 0, 432, 433, 434, 435, + 436, 437, 438, 439, 440, 441, 1030, 0, 443, 444, + 0, 445, 446, 447, 448, 449, 450, 0, 1031, 1032, + 0, 0, 453, 1033, 455, 1034, 1035, 457, 458, 459, + 460, 461, 462, 463, 0, 1036, 464, 465, 466, 467, + 468, 1037, 0, 469, 470, 471, 472, 473, 474, 1038, + 0, 476, 735, 477, 478, 479, 0, 0, 480, 0, + 0, 481, 482, 483, 484, 485, 486, 1039, 1040, 1041, + 1042, 1043, 1044, 1045, 1046, 495, 496, 497, 0, 0, + 0, 0, 0, 0, 0, 1047, 1048, 0, 0, 0, + 0, 0, 0, 0, 1050, 712, 981, 550, 982, 983, + 984, 597, 985, 0, 0, 0, 200, 201, 202, 203, + 204, 205, 206, 207, 1773, 209, 210, 211, 0, 0, + 0, 0, 986, 0, 0, 212, 213, 0, 214, 215, + 713, 216, 217, 218, 219, 987, 714, 988, 989, 0, + 223, 224, 225, 226, 227, 990, 991, 228, 229, 992, + 993, 232, 0, 233, 234, 235, 236, 994, 0, 995, + 0, 238, 239, 240, 241, 716, 242, 243, 0, 244, + 245, 246, 247, 248, 249, 0, 717, 250, 251, 996, + 997, 998, 999, 1000, 1001, 1002, 252, 253, 254, 255, + 256, 257, 1003, 1004, 260, 0, 261, 0, 262, 263, + 264, 265, 266, 0, 267, 268, 269, 0, 0, 270, + 271, 1005, 273, 274, 0, 275, 276, 277, 0, 278, + 279, 0, 280, 281, 282, 283, 1006, 285, 286, 287, + 1007, 1008, 289, 0, 290, 1009, 292, 0, 293, 0, + 294, 719, 0, 720, 295, 296, 297, 0, 298, 1010, + 0, 300, 0, 301, 302, 303, 304, 305, 721, 306, + 307, 308, 0, 309, 310, 311, 312, 313, 314, 0, + 315, 722, 316, 317, 318, 319, 320, 1011, 1012, 0, + 1013, 0, 324, 723, 724, 325, 725, 326, 327, 328, + 329, 330, 331, 332, 0, 333, 1014, 726, 335, 727, + 0, 336, 337, 338, 1015, 1016, 339, 340, 341, 342, + 343, 344, 345, 346, 347, 348, 349, 350, 1017, 728, + 1018, 353, 354, 355, 1019, 356, 357, 729, 358, 1020, + 1021, 360, 1022, 362, 363, 364, 0, 365, 0, 0, + 1023, 367, 368, 0, 0, 369, 730, 731, 732, 1024, + 371, 372, 373, 374, 375, 376, 377, 0, 378, 1025, + 380, 381, 382, 383, 384, 0, 385, 386, 387, 388, + 389, 390, 391, 1026, 393, 394, 395, 396, 0, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 0, + 407, 408, 733, 409, 410, 1027, 412, 413, 414, 415, + 416, 417, 418, 419, 0, 420, 421, 422, 423, 424, + 1028, 425, 426, 427, 428, 734, 429, 1029, 431, 0, + 432, 433, 434, 435, 436, 437, 438, 439, 440, 441, + 1030, 0, 443, 444, 0, 445, 446, 447, 448, 449, + 450, 0, 1031, 1032, 0, 0, 453, 1033, 455, 1034, + 1035, 457, 458, 459, 460, 461, 462, 463, 0, 1036, + 464, 465, 466, 467, 468, 1037, 0, 469, 470, 471, + 472, 473, 474, 1038, 0, 476, 735, 477, 478, 479, + 0, 0, 480, 0, 0, 481, 482, 483, 484, 485, + 486, 1039, 1040, 1041, 1042, 1043, 1044, 1045, 1046, 495, + 496, 497, 0, 0, 0, 0, 0, 0, 0, 1047, + 1048, 0, 0, 0, 0, 0, 0, 0, 1050, 712, + 981, 550, 982, 983, 984, 597, 985, 0, 0, 0, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 986, 0, 0, 212, + 213, 0, 214, 215, 713, 216, 217, 218, 219, 987, + 714, 988, 989, 0, 223, 224, 225, 226, 227, 990, + 991, 228, 229, 992, 993, 232, 0, 233, 234, 235, + 236, 994, 0, 995, 0, 238, 239, 240, 241, 716, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 0, + 717, 250, 251, 996, 997, 998, 999, 1000, 1001, 1002, + 252, 253, 254, 255, 256, 257, 1003, 1004, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 1005, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 1006, 285, 286, 287, 1007, 1008, 289, 0, 290, 1009, + 292, 0, 293, 0, 294, 719, 2273, 720, 295, 296, + 297, 0, 298, 1010, 0, 300, 0, 301, 302, 303, + 304, 305, 721, 306, 307, 308, 0, 309, 310, 311, + 312, 313, 314, 0, 315, 722, 316, 317, 318, 319, + 320, 1011, 1012, 0, 1013, 0, 324, 723, 724, 325, + 725, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 1014, 726, 335, 727, 0, 336, 337, 338, 1015, 1016, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 1017, 728, 1018, 353, 354, 355, 1019, 356, + 357, 729, 358, 1020, 1021, 360, 1022, 362, 363, 364, + 0, 365, 0, 0, 1023, 367, 368, 0, 0, 369, + 730, 731, 732, 1024, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 1025, 380, 381, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 1026, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 733, 409, 410, 1027, + 412, 413, 414, 415, 416, 417, 418, 419, 0, 420, + 421, 422, 423, 424, 1028, 425, 426, 427, 428, 734, + 429, 1029, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 1030, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 1031, 1032, 0, 0, + 453, 1033, 455, 1034, 1035, 457, 458, 459, 460, 461, + 462, 463, 0, 1036, 464, 465, 466, 467, 468, 1037, + 0, 469, 470, 471, 472, 473, 474, 1038, 0, 476, + 735, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 485, 486, 1039, 1040, 1041, 1042, 1043, + 1044, 1045, 1046, 495, 496, 497, 0, 0, 0, 0, + 0, 0, 0, 1047, 1048, 0, 0, 0, 0, 0, + 0, 0, 1050, 712, 981, 550, 982, 983, 984, 597, + 985, 0, 0, 0, 200, 201, 202, 203, 204, 205, + 206, 207, 0, 209, 210, 211, 0, 0, 0, 0, + 986, 0, 0, 212, 213, 0, 214, 215, 713, 216, + 217, 218, 219, 987, 714, 988, 989, 0, 223, 224, + 225, 226, 227, 990, 991, 228, 229, 992, 993, 232, + 0, 233, 234, 235, 236, 994, 0, 995, 0, 238, + 239, 240, 241, 716, 242, 243, 0, 244, 245, 246, + 247, 248, 249, 0, 717, 250, 251, 996, 997, 998, + 999, 1000, 1001, 1002, 252, 253, 254, 255, 256, 257, + 1003, 1004, 260, 0, 261, 0, 262, 263, 264, 265, + 266, 0, 267, 268, 269, 0, 0, 270, 271, 1005, + 273, 274, 0, 275, 276, 277, 0, 278, 279, 0, + 280, 281, 282, 283, 1006, 285, 286, 287, 1007, 1008, + 289, 0, 290, 1009, 292, 0, 293, 0, 294, 719, + 0, 720, 295, 296, 297, 0, 298, 1010, 0, 300, + 0, 301, 302, 303, 304, 305, 721, 306, 307, 308, + 0, 309, 310, 311, 312, 313, 314, 0, 315, 722, + 316, 317, 318, 319, 320, 1011, 1012, 0, 1013, 0, + 324, 723, 724, 325, 725, 326, 327, 328, 329, 330, + 331, 332, 0, 333, 1014, 726, 335, 727, 0, 336, + 337, 338, 1015, 1016, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 1017, 728, 1018, 353, + 354, 355, 1019, 356, 357, 729, 358, 1020, 1021, 360, + 1022, 362, 363, 364, 0, 365, 0, 0, 1023, 367, + 368, 0, 0, 369, 730, 731, 732, 1024, 371, 372, + 373, 374, 375, 376, 377, 0, 378, 1025, 380, 381, + 382, 383, 384, 0, 385, 386, 387, 388, 389, 390, + 391, 1026, 393, 394, 395, 396, 0, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 0, 407, 408, + 733, 409, 410, 1027, 412, 413, 414, 415, 416, 417, + 418, 419, 0, 420, 421, 422, 423, 424, 1028, 425, + 426, 427, 428, 734, 429, 1029, 431, 0, 432, 433, + 434, 435, 436, 437, 438, 439, 440, 441, 1030, 0, + 443, 444, 0, 445, 446, 447, 448, 449, 450, 0, + 1031, 1032, 0, 0, 453, 1033, 455, 1034, 1035, 457, + 458, 459, 460, 461, 462, 463, 0, 1036, 464, 465, + 466, 467, 468, 1037, 0, 469, 470, 471, 472, 473, + 474, 1038, 3430, 476, 735, 477, 478, 479, 0, 0, + 480, 0, 0, 481, 482, 483, 484, 485, 486, 1039, + 1040, 1041, 1042, 1043, 1044, 1045, 1046, 495, 496, 497, + 0, 0, 0, 0, 0, 0, 0, 1047, 1048, 0, + 0, 0, 0, 0, 0, 0, 1050, 712, 981, 550, + 982, 983, 984, 597, 985, 0, 0, 0, 200, 201, + 202, 203, 204, 205, 206, 207, 0, 209, 210, 211, + 0, 0, 0, 0, 986, 0, 0, 212, 213, 0, + 214, 215, 713, 216, 217, 218, 219, 987, 714, 988, + 989, 0, 223, 224, 225, 226, 227, 990, 991, 228, + 229, 992, 993, 232, 0, 233, 234, 235, 236, 994, + 0, 995, 0, 238, 239, 240, 241, 716, 242, 243, + 0, 244, 245, 246, 247, 248, 249, 0, 717, 250, + 251, 996, 997, 998, 999, 1000, 1001, 1002, 252, 253, + 254, 255, 256, 257, 1003, 1004, 260, 0, 261, 0, + 262, 263, 264, 265, 266, 0, 267, 268, 269, 0, + 0, 270, 271, 1005, 273, 274, 0, 275, 276, 277, + 0, 278, 279, 0, 280, 281, 282, 283, 1006, 285, + 286, 287, 1007, 1008, 289, 0, 290, 1009, 292, 0, + 293, 0, 294, 719, 0, 720, 295, 296, 297, 0, + 298, 1010, 0, 300, 0, 301, 302, 303, 304, 305, + 721, 306, 307, 308, 0, 309, 310, 311, 312, 313, + 314, 0, 315, 722, 316, 317, 318, 319, 320, 1011, + 1012, 0, 1013, 0, 324, 723, 724, 325, 725, 326, + 327, 328, 329, 330, 331, 332, 0, 333, 1014, 726, + 335, 727, 0, 336, 337, 338, 1015, 1016, 339, 340, + 341, 342, 343, 344, 345, 346, 347, 348, 349, 350, + 1017, 728, 1018, 353, 354, 355, 1019, 356, 357, 729, + 358, 1020, 1021, 360, 1022, 362, 363, 364, 0, 365, + 0, 0, 1023, 367, 368, 0, 0, 369, 730, 731, + 732, 1024, 371, 372, 373, 374, 375, 376, 377, 0, + 378, 1025, 380, 381, 382, 383, 384, 0, 385, 386, + 387, 388, 389, 390, 391, 1026, 393, 394, 395, 396, + 0, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 0, 407, 408, 733, 409, 410, 1027, 412, 413, + 414, 415, 416, 417, 418, 419, 0, 420, 421, 422, + 423, 424, 1028, 425, 426, 427, 428, 734, 429, 1029, + 431, 0, 432, 433, 434, 435, 436, 437, 438, 439, + 440, 441, 1030, 0, 443, 444, 0, 445, 446, 447, + 448, 449, 450, 0, 1031, 1032, 0, 0, 453, 1033, + 455, 1034, 1035, 457, 458, 459, 460, 461, 462, 463, + 0, 1036, 464, 465, 466, 467, 468, 1037, 0, 469, + 470, 471, 472, 473, 474, 1038, 0, 476, 735, 477, + 478, 479, 0, 0, 480, 0, 0, 481, 482, 483, + 484, 485, 486, 1039, 1040, 1041, 1042, 1043, 1044, 1045, + 1046, 495, 496, 497, 0, 0, 0, 0, 0, 0, + 0, 1047, 1048, 0, 0, 0, 0, 0, 0, 0, + 1050, 712, 981, 550, 982, 983, 984, 597, 985, 0, + 0, 0, 200, 201, 202, 203, 204, 205, 206, 207, + 0, 209, 210, 211, 0, 0, 0, 0, 986, 0, + 0, 212, 213, 0, 214, 215, 713, 216, 217, 218, + 219, 987, 714, 988, 989, 0, 223, 224, 225, 226, + 227, 990, 991, 228, 229, 992, 993, 232, 0, 233, + 234, 235, 236, 994, 0, 995, 0, 238, 239, 240, + 241, 716, 242, 243, 0, 244, 245, 246, 247, 248, + 249, 0, 717, 250, 3440, 996, 997, 998, 999, 1000, + 1001, 1002, 252, 253, 254, 255, 256, 257, 1003, 1004, + 260, 0, 261, 0, 262, 263, 264, 265, 266, 0, + 267, 268, 269, 0, 0, 270, 271, 1005, 273, 274, + 0, 275, 276, 277, 0, 278, 279, 0, 280, 281, + 282, 283, 1006, 285, 286, 287, 1007, 1008, 289, 0, + 290, 1009, 292, 0, 293, 0, 294, 719, 0, 720, + 295, 296, 297, 0, 298, 1010, 0, 300, 0, 301, + 302, 303, 304, 305, 721, 306, 307, 308, 0, 309, + 310, 311, 312, 313, 314, 0, 315, 722, 316, 317, + 318, 319, 320, 1011, 1012, 0, 1013, 0, 324, 723, + 724, 325, 725, 326, 327, 328, 329, 330, 331, 332, + 0, 333, 1014, 726, 335, 727, 0, 336, 337, 338, + 1015, 1016, 339, 340, 341, 342, 343, 344, 345, 346, + 347, 348, 349, 350, 1017, 728, 1018, 353, 354, 355, + 1019, 356, 357, 729, 358, 1020, 1021, 360, 1022, 362, + 363, 364, 0, 365, 0, 0, 1023, 367, 368, 0, + 0, 369, 730, 731, 732, 1024, 371, 372, 373, 374, + 375, 376, 377, 0, 378, 1025, 380, 381, 382, 383, + 384, 0, 385, 386, 387, 388, 389, 390, 391, 1026, + 393, 394, 395, 396, 0, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 0, 407, 408, 733, 409, + 410, 1027, 412, 413, 414, 415, 416, 417, 418, 419, + 0, 420, 421, 422, 423, 424, 1028, 425, 426, 427, + 428, 734, 429, 1029, 431, 0, 432, 433, 434, 435, + 436, 437, 438, 439, 440, 441, 1030, 0, 443, 444, + 0, 445, 446, 447, 448, 449, 450, 0, 1031, 1032, + 0, 0, 453, 1033, 455, 1034, 1035, 457, 458, 459, + 460, 461, 462, 463, 0, 1036, 464, 465, 466, 467, + 468, 1037, 0, 469, 470, 471, 472, 473, 474, 1038, + 0, 476, 735, 477, 478, 479, 0, 0, 480, 0, + 0, 481, 482, 483, 484, 485, 486, 1039, 1040, 1041, + 1042, 1043, 1044, 1045, 1046, 495, 496, 497, 0, 0, + 0, 0, 0, 0, 0, 1047, 1048, 0, 0, 0, + 0, 0, 0, 0, 1050, 712, 981, 550, 982, 983, + 984, 597, 985, 0, 0, 0, 200, 201, 202, 203, + 204, 205, 206, 207, 0, 209, 210, 211, 0, 0, + 0, 0, 986, 0, 0, 212, 213, 0, 214, 215, + 713, 216, 217, 218, 219, 987, 714, 988, 989, 0, + 223, 224, 225, 226, 227, 990, 991, 228, 229, 992, + 993, 232, 0, 233, 234, 235, 236, 994, 0, 995, + 0, 238, 239, 240, 241, 716, 242, 243, 0, 244, + 245, 246, 247, 248, 249, 0, 717, 250, 251, 996, + 997, 998, 999, 1000, 1001, 1002, 252, 253, 254, 255, + 256, 257, 1003, 1004, 260, 0, 261, 0, 262, 263, + 264, 265, 266, 0, 267, 268, 269, 0, 0, 270, + 271, 1005, 273, 274, 0, 275, 276, 277, 0, 278, + 279, 0, 280, 281, 282, 283, 1006, 285, 286, 287, + 1007, 1008, 289, 0, 290, 1009, 292, 0, 293, 0, + 294, 719, 0, 720, 295, 296, 297, 0, 298, 1010, + 0, 300, 0, 301, 302, 303, 304, 305, 721, 306, + 307, 308, 0, 309, 310, 311, 312, 313, 314, 0, + 315, 722, 316, 317, 318, 319, 320, 1011, 1012, 0, + 1013, 0, 324, 723, 724, 325, 725, 326, 327, 328, + 329, 330, 331, 332, 0, 333, 1014, 726, 335, 727, + 0, 336, 337, 338, 1015, 1016, 339, 340, 341, 342, + 343, 344, 345, 346, 347, 348, 349, 350, 1017, 728, + 1018, 353, 354, 355, 1019, 356, 357, 729, 358, 1020, + 1021, 360, 1022, 362, 363, 364, 0, 365, 0, 0, + 1023, 367, 368, 0, 0, 369, 730, 731, 732, 1024, + 371, 372, 373, 374, 375, 376, 377, 0, 378, 1025, + 380, 381, 382, 383, 384, 0, 385, 386, 387, 388, + 389, 390, 391, 1026, 393, 394, 395, 396, 0, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 0, + 407, 408, 733, 409, 410, 1027, 412, 413, 414, 415, + 416, 417, 418, 419, 0, 420, 421, 422, 423, 424, + 1028, 425, 426, 427, 428, 734, 429, 1029, 431, 0, + 432, 433, 434, 435, 436, 437, 438, 439, 440, 441, + 1030, 0, 443, 444, 0, 445, 446, 447, 448, 449, + 450, 0, 1031, 1032, 0, 0, 453, 1033, 455, 1034, + 1035, 457, 458, 459, 460, 461, 462, 463, 0, 1036, + 464, 465, 466, 467, 468, 1037, 0, 469, 470, 471, + 472, 473, 474, 1038, 0, 476, 735, 477, 478, 479, + 0, 0, 480, 0, 0, 481, 482, 483, 484, 485, + 3710, 1039, 1040, 1041, 1042, 1043, 1044, 1045, 1046, 495, + 496, 497, 0, 0, 0, 0, 0, 0, 0, 1047, + 1048, 0, 0, 0, 0, 0, 0, 0, 1050, 712, + 981, 550, 982, 983, 984, 597, 985, 0, 0, 0, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 986, 0, 0, 212, + 213, 0, 214, 215, 713, 216, 217, 218, 219, 987, + 714, 988, 989, 0, 223, 224, 225, 226, 227, 990, + 991, 228, 229, 992, 993, 232, 0, 233, 234, 235, + 236, 994, 0, 995, 0, 238, 239, 240, 241, 716, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 0, + 717, 250, 251, 996, 997, 998, 999, 1000, 1001, 1002, + 252, 253, 254, 255, 256, 257, 1003, 1004, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 1005, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 1006, 285, 286, 287, 1007, 1008, 289, 0, 290, 1009, + 292, 0, 293, 0, 294, 719, 0, 720, 295, 296, + 297, 0, 298, 1010, 0, 300, 0, 301, 302, 303, + 304, 305, 721, 306, 307, 308, 0, 309, 310, 311, + 312, 313, 314, 0, 315, 722, 316, 317, 318, 319, + 320, 1011, 1012, 0, 1013, 0, 324, 723, 724, 325, + 725, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 1014, 726, 335, 727, 0, 336, 337, 338, 1015, 1016, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 1017, 728, 1018, 353, 3719, 355, 1019, 356, + 357, 729, 358, 1020, 1021, 360, 1022, 362, 363, 364, + 0, 365, 0, 0, 1023, 367, 368, 0, 0, 369, + 730, 731, 732, 1024, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 1025, 380, 381, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 1026, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 733, 409, 410, 1027, + 412, 413, 414, 415, 416, 417, 418, 419, 0, 420, + 421, 422, 423, 424, 1028, 425, 426, 427, 428, 734, + 429, 1029, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 1030, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 1031, 1032, 0, 0, + 453, 1033, 455, 1034, 1035, 457, 458, 459, 460, 461, + 462, 463, 0, 1036, 464, 465, 466, 467, 468, 1037, + 0, 469, 470, 471, 472, 473, 474, 1038, 0, 476, + 735, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 485, 486, 1039, 1040, 1041, 1042, 1043, + 1044, 1045, 1046, 495, 496, 497, 0, 0, 0, 0, + 0, 0, 0, 1047, 1048, 0, 0, 0, 0, 0, + 0, 0, 1050, 712, 981, 550, 982, 983, 984, 597, + 985, 0, 0, 0, 200, 201, 202, 203, 204, 205, + 206, 207, 0, 209, 210, 211, 0, 0, 0, 0, + 986, 0, 0, 212, 213, 0, 214, 215, 713, 216, + 217, 218, 4207, 987, 714, 988, 989, 0, 223, 224, + 225, 226, 227, 990, 991, 228, 229, 992, 993, 232, + 0, 233, 234, 235, 236, 994, 0, 995, 0, 238, + 239, 240, 241, 716, 242, 243, 0, 244, 245, 246, + 247, 248, 249, 0, 717, 250, 4208, 996, 997, 998, + 999, 1000, 1001, 1002, 252, 253, 254, 255, 256, 257, + 1003, 1004, 260, 0, 261, 0, 262, 263, 264, 265, + 266, 0, 267, 268, 269, 0, 0, 270, 271, 1005, + 273, 274, 0, 275, 276, 277, 0, 278, 279, 0, + 280, 281, 282, 283, 1006, 285, 286, 287, 1007, 1008, + 289, 0, 290, 1009, 292, 0, 293, 0, 294, 719, + 0, 720, 295, 296, 297, 0, 298, 1010, 0, 300, + 0, 301, 302, 303, 304, 305, 721, 306, 307, 308, + 0, 309, 310, 311, 312, 313, 314, 0, 315, 722, + 316, 317, 318, 319, 320, 1011, 1012, 0, 1013, 0, + 324, 723, 724, 325, 725, 326, 327, 328, 329, 330, + 331, 332, 0, 333, 1014, 726, 335, 727, 0, 336, + 337, 338, 1015, 1016, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 1017, 728, 1018, 353, + 354, 355, 1019, 356, 357, 729, 358, 1020, 1021, 360, + 1022, 362, 363, 364, 0, 365, 0, 0, 1023, 367, + 368, 0, 0, 369, 730, 731, 732, 1024, 371, 372, + 373, 374, 375, 376, 377, 0, 378, 1025, 380, 381, + 382, 383, 384, 0, 385, 386, 387, 388, 389, 390, + 391, 1026, 393, 394, 395, 396, 0, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 0, 407, 408, + 733, 409, 410, 1027, 412, 413, 414, 415, 416, 417, + 418, 419, 0, 420, 421, 422, 423, 424, 1028, 425, + 426, 427, 428, 734, 429, 1029, 431, 0, 432, 433, + 434, 435, 436, 437, 438, 439, 440, 441, 1030, 0, + 443, 444, 0, 445, 446, 447, 448, 449, 450, 0, + 1031, 1032, 0, 0, 453, 1033, 455, 1034, 1035, 457, + 458, 459, 460, 4209, 462, 463, 0, 1036, 464, 465, + 466, 467, 468, 1037, 0, 469, 470, 471, 472, 473, + 474, 1038, 0, 476, 735, 477, 478, 479, 0, 0, + 480, 0, 0, 481, 482, 483, 484, 485, 486, 1039, + 1040, 1041, 1042, 1043, 1044, 1045, 1046, 495, 496, 497, + 0, 0, 0, 0, 0, 0, 0, 1047, 1048, 0, + 0, 0, 0, 0, 0, 0, 1050, 712, 981, 550, + 982, 983, 984, 597, 985, 0, 0, 0, 200, 201, + 202, 203, 204, 205, 206, 207, 0, 209, 210, 211, + 0, 0, 0, 0, 986, 0, 0, 212, 213, 0, + 214, 215, 713, 216, 217, 218, 219, 987, 714, 988, + 989, 0, 223, 224, 225, 226, 227, 990, 991, 228, + 229, 992, 993, 232, 0, 233, 234, 235, 236, 994, + 0, 995, 0, 238, 239, 240, 241, 716, 242, 243, + 0, 244, 245, 246, 247, 248, 249, 0, 717, 250, + 4208, 996, 997, 998, 999, 1000, 1001, 1002, 252, 253, + 254, 255, 256, 257, 1003, 1004, 260, 0, 261, 0, + 262, 263, 264, 265, 266, 0, 267, 268, 269, 0, + 0, 270, 271, 1005, 273, 274, 0, 275, 276, 277, + 0, 278, 279, 0, 280, 281, 282, 283, 1006, 285, + 286, 287, 1007, 1008, 289, 0, 290, 1009, 292, 0, + 293, 0, 294, 719, 0, 720, 295, 296, 297, 0, + 298, 1010, 0, 300, 0, 301, 302, 303, 304, 305, + 721, 306, 307, 308, 0, 309, 310, 311, 312, 313, + 314, 0, 315, 722, 316, 317, 318, 319, 320, 1011, + 1012, 0, 1013, 0, 324, 723, 724, 325, 725, 326, + 327, 328, 329, 330, 331, 332, 0, 333, 1014, 726, + 335, 727, 0, 336, 337, 338, 1015, 1016, 339, 340, + 341, 342, 343, 344, 345, 346, 347, 348, 349, 350, + 1017, 728, 1018, 353, 354, 355, 1019, 356, 357, 729, + 358, 1020, 1021, 360, 1022, 362, 363, 364, 0, 365, + 0, 0, 1023, 367, 368, 0, 0, 369, 730, 731, + 732, 1024, 371, 372, 373, 374, 375, 376, 377, 0, + 378, 1025, 380, 381, 382, 383, 384, 0, 385, 386, + 387, 388, 389, 390, 391, 1026, 393, 394, 395, 396, + 0, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 0, 407, 408, 733, 409, 410, 1027, 412, 413, + 414, 415, 416, 417, 418, 419, 0, 420, 421, 422, + 423, 424, 1028, 425, 426, 427, 428, 734, 429, 1029, + 431, 0, 432, 433, 434, 435, 436, 437, 438, 439, + 440, 441, 1030, 0, 443, 444, 0, 445, 446, 447, + 448, 449, 450, 0, 1031, 1032, 0, 0, 453, 1033, + 455, 1034, 1035, 457, 458, 459, 460, 4209, 462, 463, + 0, 1036, 464, 465, 466, 467, 468, 1037, 0, 469, + 470, 471, 472, 473, 474, 1038, 0, 476, 735, 477, + 478, 479, 0, 0, 480, 0, 0, 481, 482, 483, + 484, 485, 486, 1039, 1040, 1041, 1042, 1043, 1044, 1045, + 1046, 495, 496, 497, 0, 0, 0, 0, 0, 0, + 0, 1047, 1048, 0, 0, 0, 0, 0, 0, 0, + 1050, 712, 981, 550, 982, 983, 984, 597, 985, 0, + 0, 0, 200, 201, 202, 203, 204, 205, 206, 207, + 0, 209, 210, 211, 0, 0, 0, 0, 986, 0, + 0, 212, 213, 0, 214, 215, 713, 216, 217, 218, + 219, 987, 714, 988, 989, 0, 223, 224, 225, 226, + 227, 990, 991, 228, 229, 992, 993, 232, 0, 233, + 234, 235, 236, 994, 0, 995, 0, 238, 239, 240, + 241, 716, 242, 243, 0, 244, 245, 246, 247, 248, + 249, 0, 717, 250, 251, 996, 997, 998, 999, 1000, + 1001, 1002, 252, 253, 254, 255, 256, 257, 1003, 1004, + 260, 0, 261, 0, 262, 263, 264, 265, 266, 0, + 267, 268, 269, 0, 0, 270, 271, 1005, 273, 274, + 0, 275, 276, 277, 0, 278, 279, 0, 280, 281, + 282, 283, 1006, 285, 286, 287, 1007, 1008, 289, 0, + 290, 1009, 292, 0, 293, 0, 294, 719, 0, 720, + 295, 296, 297, 0, 298, 1010, 0, 300, 0, 301, + 302, 303, 304, 305, 721, 306, 307, 308, 0, 309, + 310, 311, 312, 313, 314, 0, 315, 722, 316, 317, + 318, 319, 320, 1011, 1012, 0, 1013, 0, 324, 723, + 724, 325, 725, 326, 327, 328, 329, 330, 331, 332, + 0, 333, 1014, 726, 335, 727, 0, 336, 337, 338, + 1015, 1016, 339, 340, 341, 342, 343, 344, 345, 346, + 347, 348, 349, 350, 1017, 728, 1018, 353, 354, 355, + 0, 356, 357, 729, 358, 1020, 1021, 360, 1022, 362, + 363, 364, 0, 365, 0, 0, 1023, 367, 368, 0, + 0, 369, 730, 731, 732, 1024, 371, 372, 373, 374, + 375, 376, 377, 0, 378, 1025, 380, 381, 382, 383, + 384, 0, 385, 386, 387, 388, 389, 390, 391, 1026, + 393, 394, 395, 396, 0, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 0, 407, 408, 733, 409, + 410, 1027, 412, 413, 414, 415, 416, 417, 418, 419, + 0, 420, 421, 422, 423, 424, 1028, 425, 426, 427, + 428, 734, 429, 1029, 431, 0, 432, 433, 434, 435, + 436, 437, 438, 439, 440, 441, 1030, 0, 443, 444, + 0, 445, 446, 447, 448, 449, 450, 0, 1031, 1032, + 0, 0, 453, 1033, 455, 1034, 1035, 457, 458, 459, + 460, 461, 462, 463, 0, 0, 464, 465, 466, 467, + 468, 1037, 0, 469, 470, 471, 472, 473, 474, 1038, + 0, 476, 735, 477, 478, 479, 0, 0, 480, 0, + 0, 481, 482, 483, 484, 485, 486, 1039, 1040, 1041, + 1042, 1043, 1044, 1045, 1046, 495, 496, 497, 0, 0, + 0, 0, 0, 0, 0, 2255, 2256, 0, 0, 0, + 0, 0, 0, 0, 1050, 712, 981, 550, 982, 983, + 984, 597, 985, 0, 0, 0, 200, 201, 202, 203, + 204, 205, 206, 207, 0, 209, 210, 211, 0, 0, + 0, 0, 986, 0, 0, 212, 213, 0, 214, 215, + 713, 216, 217, 218, -2162, 987, 714, 988, 989, 0, + 223, 224, 225, 226, 227, 990, 991, 228, 229, 992, + 993, 232, 0, 233, 234, 235, 236, 994, 0, 995, + 0, 238, 239, 240, 241, 716, 242, 243, 0, 244, + 245, 246, 247, 248, 249, 0, 717, 250, 4208, 996, + 997, 998, 999, 1000, 1001, 1002, 252, 253, 254, 255, + 256, 257, 1003, 1004, 260, 0, 261, 0, 262, 263, + 264, 265, 266, 0, 267, 268, 269, 0, 0, 270, + 271, 1005, 273, 274, 0, 275, 276, 277, 0, 278, + 279, 0, 280, 281, 282, 283, 1006, 285, 286, 287, + 1007, 1008, 289, 0, 290, 1009, 292, 0, 293, 0, + 294, 719, 0, 720, 295, 296, 297, 0, 298, 1010, + 0, 300, 0, 301, 302, 303, 304, 305, 0, 306, + 307, 308, 0, 309, 310, 311, 312, 313, 314, 0, + 315, 722, 316, 317, 318, 319, 320, 1011, 1012, 0, + 1013, 0, 324, 723, 724, 325, 725, 326, 327, 328, + 329, 330, 331, 332, 0, 333, 1014, 726, 335, 0, + 0, 336, 337, 338, 1015, 1016, 339, 340, 341, 342, + 343, 344, 345, 346, 347, 348, 349, 350, 1017, 728, + 1018, 353, 354, 355, 0, 356, 357, 729, 358, 1020, + 1021, 360, 1022, 362, 363, 364, 0, 365, 0, 0, + 1023, 367, 368, 0, 0, 369, 730, 731, 732, 1024, + 371, 372, 373, 374, 375, 376, 377, 0, 378, 1025, + 380, 381, 382, 383, 384, 0, 385, 386, 387, 388, + 389, 390, 391, 1026, 393, 394, 395, 396, 0, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 0, + 407, 408, 733, 409, 410, 1027, 412, 413, 414, 415, + 416, 417, 418, 419, 0, 420, 421, 422, 423, 424, + 1028, 425, 426, 427, 428, 0, 429, 1029, 431, 0, + 432, 433, 434, 435, 436, 437, 438, 439, 440, 441, + 1030, 0, 443, 444, 0, 445, 446, 447, 448, 449, + 450, 0, 1031, 1032, 0, 0, 453, 1033, 455, 1034, + 1035, 457, 458, 459, 460, 4209, 462, 463, 0, 1036, + 464, 465, 466, 467, 468, 1037, 0, 469, 470, 471, + 472, 473, 474, 1038, 0, 476, 735, 477, 478, 479, + 0, 0, 480, 0, 0, 481, 482, 483, 484, 485, + 486, 1039, 1040, 1041, 1042, 1043, 1044, 1045, 1046, 495, + 496, 497, 0, 0, 0, 0, 0, 0, 0, 1047, + 1048, 0, 0, 712, 981, 550, 982, 983, 1050, 597, + 985, 0, 0, 0, 200, 201, 202, 203, 204, 205, + 206, 207, 0, 209, 210, 211, 0, 0, 0, 0, + 986, 0, 0, 212, 213, 0, 214, 215, 713, 216, + 217, 218, 219, 987, 714, 988, 989, 0, 223, 224, + 225, 226, 227, 990, 991, 228, 229, 992, 993, 232, + 0, 233, 234, 235, 236, 994, 0, 995, 0, 238, + 239, 240, 241, 716, 242, 243, 0, 244, 245, 246, + 247, 248, 249, 0, 717, 250, 251, 996, 997, 998, + 999, 1000, 1001, 1002, 252, 253, 254, 255, 256, 257, + 1003, 1004, 260, 0, 261, 0, 262, 263, 264, 265, + 266, 0, 267, 268, 269, 0, 0, 270, 271, 1005, + 273, 274, 0, 275, 276, 277, 0, 278, 279, 0, + 280, 281, 282, 283, 1006, 285, 286, 287, 1007, 1008, + 289, 0, 290, 1009, 292, 0, 293, 0, 294, 719, + 0, 720, 295, 296, 297, 0, 298, 1010, 0, 300, + 0, 301, 302, 303, 304, 305, 721, 306, 307, 308, + 0, 309, 310, 311, 312, 313, 314, 0, 315, 722, + 316, 317, 318, 319, 320, 1011, 1012, 0, 1013, 0, + 324, 723, 724, 325, 725, 326, 327, 328, 329, 330, + 331, 332, 0, 333, 1014, 726, 335, 727, 0, 336, + 337, 338, 1015, 1016, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 1017, 728, 1018, 353, + 354, 355, 0, 356, 357, 729, 358, 1020, 1021, 360, + 1022, 362, 363, 364, 0, 365, 0, 0, 366, 367, + 368, 0, 0, 369, 730, 731, 732, 1024, 371, 372, + 373, 374, 375, 376, 377, 0, 378, 1025, 380, 381, + 382, 383, 384, 0, 385, 386, 387, 388, 389, 390, + 391, 1026, 393, 394, 395, 396, 0, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 0, 407, 408, + 733, 409, 410, 1027, 412, 413, 414, 415, 416, 417, + 418, 419, 0, 420, 421, 422, 423, 424, 1028, 425, + 426, 427, 428, 734, 429, 1029, 431, 0, 432, 433, + 434, 435, 436, 437, 438, 439, 440, 441, 1030, 0, + 443, 444, 0, 445, 446, 447, 448, 449, 450, 0, + 1031, 1032, 0, 0, 453, 1033, 455, 1034, 1035, 457, + 458, 459, 460, 461, 462, 463, 0, 0, 464, 465, + 466, 467, 468, 1037, 0, 469, 470, 471, 472, 473, + 474, 1038, 0, 476, 735, 477, 478, 479, 0, 0, + 480, 0, 0, 481, 482, 483, 484, 485, 486, 1039, + 1040, 1041, 1042, 1043, 1044, 1045, 1046, 495, 496, 497, + 0, 0, 0, 0, 0, 0, 712, 981, 550, 982, + 983, 0, 597, 985, 0, 0, 1050, 200, 201, 202, + 203, 204, 205, 206, 207, 0, 209, 210, 211, 0, + 0, 0, 0, 986, 0, 0, 212, 213, 0, 214, + 215, 713, 216, 217, 218, 219, 987, 714, 988, 989, + 0, 3353, 224, 225, 226, 227, 990, 991, 228, 229, + 992, 993, 232, 0, 233, 234, 235, 236, 994, 0, + 995, 0, 238, 239, 240, 241, 716, 242, 243, 0, + 244, 245, 246, 247, 248, 249, 0, 717, 250, 251, + 996, 997, 998, 999, 1000, 1001, 1002, 252, 253, 254, + 255, 256, 257, 1003, 1004, 260, 0, 261, 0, 262, + 263, 264, 265, 266, 0, 267, 268, 269, 0, 0, + 270, 271, 1005, 273, 274, 0, 275, 276, 277, 0, + 278, 279, 0, 280, 281, 282, 283, 1006, 285, 286, + 287, 1007, 1008, 289, 0, 290, 1009, 292, 0, 293, + 0, 294, 719, 0, 720, 295, 296, 297, 0, 298, + 1010, 0, 300, 0, 301, 302, 303, 304, 305, 721, + 306, 307, 308, 0, 309, 310, 311, 312, 313, 314, + 0, 315, 722, 316, 317, 318, 319, 320, 1011, 1012, + 0, 1013, 0, 324, 723, 724, 325, 725, 326, 327, + 328, 329, 330, 331, 332, 0, 333, 1014, 726, 335, + 727, 0, 336, 337, 338, 1015, 1016, 339, 340, 341, + 342, 343, 344, 345, 346, 347, 348, 349, 350, 1017, + 728, 1018, 353, 354, 355, 0, 356, 357, 729, 358, + 1020, 1021, 360, 1022, 362, 363, 364, 0, 365, 0, + 0, 366, 367, 368, 0, 0, 369, 730, 731, 732, + 1024, 371, 372, 373, 374, 375, 376, 377, 0, 378, + 1025, 380, 381, 382, 383, 384, 0, 385, 386, 387, + 388, 389, 390, 391, 1026, 393, 394, 395, 396, 0, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 0, 407, 408, 733, 409, 410, 1027, 412, 413, 414, + 415, 416, 417, 418, 419, 0, 420, 421, 422, 423, + 424, 1028, 425, 426, 427, 428, 734, 429, 1029, 431, + 0, 432, 433, 434, 435, 436, 437, 438, 439, 440, + 441, 1030, 0, 443, 444, 0, 445, 446, 447, 448, + 449, 450, 0, 1031, 1032, 0, 0, 453, 1033, 455, + 1034, 1035, 457, 458, 459, 460, 461, 462, 463, 0, + 0, 464, 465, 466, 467, 468, 1037, 0, 469, 470, + 471, 472, 473, 474, 1038, 0, 476, 735, 477, 478, + 479, 0, 0, 480, 0, 0, 481, 482, 483, 484, + 485, 486, 1039, 1040, 1041, 1042, 1043, 1044, 1045, 1046, + 495, 496, 497, 0, 0, 0, 0, 0, 0, 712, + 981, 550, 982, 983, 984, 597, 985, 0, 0, 1050, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 986, 0, 0, 212, + 213, 0, 214, 215, 713, 216, 217, 218, 0, 987, + 714, 988, 989, 0, 223, 224, 225, 226, 227, 990, + 991, 228, 229, 992, 993, 232, 0, 233, 234, 235, + 236, 994, 0, 995, 0, 238, 239, 240, 241, 716, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 0, + 717, 250, 251, 996, 997, 998, 999, 1000, 1001, 1002, + 252, 253, 254, 255, 256, 257, 1003, 1004, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 1005, 273, 274, 0, 275, + 276, 277, 0, 278, 0, 0, 280, 281, 282, 283, + 1006, 285, 286, 287, 1007, 1008, 289, 0, 290, 1009, + 292, 0, 293, 0, 294, 719, 0, 720, 295, 296, + 297, 0, 298, 1010, 0, 300, 0, 301, 302, 303, + 304, 305, 0, 306, 307, 308, 0, 309, 310, 311, + 312, 313, 314, 0, 315, 722, 316, 317, 318, 319, + 320, 1011, 1012, 0, 1013, 0, 324, 723, 724, 325, + 725, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 1014, 726, 335, 0, 0, 336, 337, 338, 1015, 1016, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 1017, 728, 1018, 353, 354, 355, 0, 356, + 357, 729, 358, 1020, 1021, 360, 1022, 362, 363, 364, + 0, 365, 0, 0, 1023, 367, 368, 0, 0, 369, + 730, 731, 732, 1024, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 1025, 380, 381, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 1026, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 733, 409, 410, 1027, + 412, 413, 414, 415, 416, 417, 418, 419, 0, 420, + 421, 422, 423, 424, 1028, 425, 426, 427, 428, 0, + 429, 1029, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 1030, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 1031, 1032, 0, 0, + 453, 1033, 455, 1034, 1035, 457, 458, 459, 460, 461, + 462, 463, 0, 1036, 464, 465, 466, 467, 468, 1037, + 0, 469, 470, 471, 472, 473, 474, 1038, 0, 476, + 735, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 485, 486, 1039, 1040, 1041, 1042, 1043, + 1044, 1045, 1046, 495, 496, 497, 0, 0, 0, 0, + 0, 0, 0, 1047, 1048, 0, 0, 0, 0, 0, + 0, 0, 1050, 712, 981, 550, 982, 983, 984, 597, + 985, 0, 0, 0, 200, 201, 202, 203, 204, 205, + 206, 207, 0, 209, 210, 211, 0, 0, 0, 0, + 986, 0, 0, 212, 213, 0, 214, 215, 713, 216, + 217, 218, 0, 987, 714, 988, 989, 0, 223, 224, + 225, 226, 227, 990, 991, 228, 229, 992, 993, 232, + 0, 233, 234, 235, 236, 994, 0, 995, 0, 238, + 239, 240, 241, 716, 242, 243, 0, 244, 245, 246, + 247, 248, 249, 0, 717, 250, 251, 996, 997, 998, + 999, 1000, 1001, 1002, 252, 253, 254, 255, 256, 257, + 1003, 1004, 260, 0, 261, 0, 262, 263, 264, 265, + 266, 0, 267, 268, 269, 0, 0, 270, 271, 1005, + 273, 274, 0, 275, 276, 277, 0, 278, 0, 0, + 280, 281, 282, 283, 1006, 285, 286, 287, 1007, 1008, + 289, 0, 290, 1009, 292, 0, 293, 0, 294, 719, + 0, 720, 295, 296, 297, 0, 298, 1010, 0, 300, + 0, 301, 302, 303, 304, 305, 0, 306, 307, 308, + 0, 309, 310, 311, 312, 313, 314, 0, 315, 722, + 316, 317, 318, 319, 320, 1011, 1012, 0, 1013, 0, + 324, 723, 724, 325, 725, 326, 327, 328, 329, 330, + 331, 332, 0, 333, 1014, 726, 335, 0, 0, 336, + 337, 338, 1015, 1016, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 1017, 728, 1018, 353, + 354, 355, 0, 356, 357, 729, 358, 1020, 1021, 360, + 1022, 362, 363, 364, 0, 365, 0, 0, 1023, 367, + 368, 0, 0, 369, 730, 731, 732, 1024, 371, 372, + 373, 374, 375, 376, 377, 0, 378, 1025, 380, 381, + 382, 383, 384, 0, 385, 386, 387, 388, 389, 390, + 391, 1026, 393, 394, 395, 396, 0, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 0, 407, 408, + 733, 409, 410, 1027, 412, 413, 414, 415, 416, 417, + 418, 419, 0, 420, 421, 422, 423, 424, 1028, 425, + 426, 427, 428, 0, 429, 1029, 431, 0, 432, 433, + 434, 435, 436, 437, 438, 439, 440, 441, 1030, 0, + 443, 444, 0, 445, 446, 447, 448, 449, 450, 0, + 1031, 1032, 0, 0, 453, 1033, 455, 1034, 1035, 457, + 458, 459, 460, 461, 462, 463, 0, 0, 464, 465, + 466, 467, 468, 1037, 0, 469, 470, 471, 472, 473, + 474, 1038, 0, 476, 735, 477, 478, 479, 0, 0, + 480, 0, 0, 481, 482, 483, 484, 485, 486, 1039, + 1040, 1041, 1042, 1043, 1044, 1045, 1046, 495, 496, 497, + 0, 0, 0, 0, 0, 0, 712, 2255, 2256, 0, + 0, 0, 0, 0, 0, 0, 1050, 200, 201, 202, + 203, 204, 205, 206, 207, 0, 209, 210, 211, 0, + 0, 0, 0, 0, 0, 0, 212, 213, 0, 214, + 215, 713, 216, 217, 218, 219, 220, 714, 221, 222, + 0, 223, 224, 225, 226, 227, 0, 991, 228, 229, + 230, 231, 232, 0, 233, 234, 235, 236, 994, 0, + 995, 0, 238, 239, 240, 241, 716, 242, 243, 0, + 244, 245, 246, 247, 248, 249, 0, 717, 250, 251, + 996, 997, 998, 999, 1000, 1001, 1002, 252, 253, 254, + 255, 256, 257, 258, 259, 260, 0, 261, 0, 262, + 263, 264, 265, 266, 0, 267, 268, 269, 0, 0, + 270, 271, 272, 273, 274, 0, 275, 276, 277, 0, + 278, 279, 0, 280, 281, 282, 283, 284, 285, 286, + 287, 1007, 0, 289, 0, 290, 291, 292, 0, 293, + 0, 294, 719, 0, 720, 295, 296, 297, 0, 298, + 1010, 0, 300, 0, 301, 302, 303, 304, 305, 721, + 306, 307, 308, 0, 309, 310, 311, 312, 313, 314, + 0, 315, 722, 316, 317, 318, 319, 320, 321, 322, + 0, 323, 0, 324, 723, 724, 325, 725, 326, 327, + 328, 329, 330, 331, 332, 0, 333, 1014, 726, 335, + 727, 0, 336, 337, 338, 1015, 1016, 339, 340, 341, + 342, 343, 344, 345, 346, 347, 348, 349, 350, 351, + 728, 352, 353, 354, 355, 0, 356, 357, 729, 358, + 0, 1021, 360, 361, 362, 363, 364, 0, 365, 0, + 677, 366, 367, 368, 0, 0, 369, 730, 731, 732, + 1024, 371, 372, 373, 374, 375, 376, 377, 0, 378, + 1025, 380, 381, 382, 383, 384, 0, 385, 386, 387, + 388, 389, 390, 391, 392, 393, 394, 395, 396, 0, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 0, 407, 408, 733, 409, 410, 411, 412, 413, 414, + 415, 416, 417, 418, 419, 37, 420, 421, 422, 423, + 424, 1028, 425, 426, 427, 428, 734, 429, 430, 431, + 0, 432, 433, 434, 435, 436, 437, 438, 439, 440, + 441, 1030, 0, 443, 444, 41, 445, 446, 447, 448, + 449, 450, 0, 451, 452, 0, 0, 453, 1033, 455, + 1034, 0, 457, 458, 459, 460, 461, 462, 463, 0, + 0, 464, 465, 466, 467, 468, 1037, 0, 469, 470, + 471, 472, 473, 920, 475, 0, 476, 735, 477, 478, + 479, 0, 0, 480, 0, 46, 481, 482, 483, 484, + 485, 486, 1039, 1040, 1041, 1042, 1043, 1044, 1045, 1046, + 495, 496, 497, 0, 0, 0, 0, 0, 0, 712, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 2929, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 0, 0, 0, 212, + 213, 0, 214, 215, 713, 216, 217, 218, 219, 220, + 714, 221, 222, 0, 223, 224, 225, 226, 227, 0, + 991, 228, 229, 230, 231, 232, 0, 233, 234, 235, + 236, 994, 0, 995, 0, 238, 239, 240, 241, 716, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 0, + 717, 250, 251, 996, 997, 998, 999, 1000, 1001, 1002, + 252, 253, 254, 255, 256, 257, 258, 259, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 272, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 284, 285, 286, 287, 1007, 0, 289, 0, 290, 291, + 292, 0, 293, 0, 294, 719, 0, 720, 295, 296, + 297, 0, 298, 1010, 0, 300, 0, 301, 302, 303, + 304, 305, 721, 306, 307, 308, 0, 309, 310, 311, + 312, 313, 314, 0, 315, 722, 316, 317, 318, 319, + 320, 321, 322, 0, 323, 0, 324, 723, 724, 325, + 725, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 1014, 726, 335, 727, 0, 336, 337, 338, 1015, 1016, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 351, 728, 352, 353, 354, 355, 0, 356, + 357, 729, 358, 0, 1021, 360, 361, 362, 363, 364, + 0, 365, 0, 677, 366, 367, 368, 0, 0, 369, + 730, 731, 732, 1024, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 1025, 380, 381, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 733, 409, 410, 411, + 412, 413, 414, 415, 416, 417, 418, 419, 0, 420, + 421, 422, 423, 424, 1028, 425, 426, 427, 428, 734, + 429, 430, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 1030, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 451, 452, 0, 0, + 453, 1033, 455, 1034, 0, 457, 458, 459, 460, 461, + 462, 463, 0, 0, 464, 465, 466, 467, 468, 1037, + 0, 469, 470, 471, 472, 473, 474, 475, 0, 476, + 735, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 485, 486, 1039, 1040, 1041, 1042, 1043, + 1044, 1045, 1046, 495, 496, 497, 0, 0, 0, 0, + 0, 0, 712, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 2929, 200, 201, 202, 203, 204, 205, 206, + 207, 0, 209, 210, 211, 0, 0, 0, 0, 0, + 0, 0, 212, 213, 0, 214, 215, 713, 216, 217, + 218, 219, 220, 714, 221, 222, 0, 223, 224, 225, + 226, 227, 0, 991, 228, 229, 230, 231, 232, 0, + 233, 234, 235, 236, 994, 0, 995, 0, 238, 239, + 240, 241, 716, 242, 243, 0, 244, 245, 246, 247, + 248, 249, 0, 717, 250, 251, 996, 997, 998, 999, + 1000, 1001, 1002, 252, 253, 254, 255, 256, 257, 258, + 259, 260, 0, 261, 0, 262, 263, 264, 265, 266, + 0, 267, 268, 269, 0, 0, 270, 271, 272, 273, + 274, 0, 275, 276, 277, 0, 278, 279, 0, 280, + 281, 282, 283, 284, 285, 286, 287, 1007, 0, 289, + 0, 290, 291, 292, 0, 293, 0, 294, 719, 0, + 720, 295, 296, 297, 0, 298, 1010, 0, 300, 0, + 301, 302, 303, 304, 305, 721, 306, 307, 308, 0, + 309, 310, 311, 312, 313, 314, 0, 315, 722, 316, + 317, 318, 319, 320, 321, 322, 0, 323, 0, 324, + 723, 724, 325, 725, 326, 327, 328, 329, 330, 331, + 332, 0, 333, 1014, 726, 335, 727, 0, 336, 337, + 338, 1015, 1016, 339, 340, 341, 342, 343, 344, 345, + 346, 347, 348, 349, 350, 351, 728, 352, 353, 354, + 355, 0, 356, 357, 729, 358, 0, 1021, 360, 361, + 362, 363, 364, 0, 365, 0, 0, 366, 367, 368, + 0, 0, 369, 730, 731, 732, 1024, 371, 372, 373, + 374, 375, 376, 377, 0, 378, 1025, 380, 381, 382, + 383, 384, 0, 385, 386, 387, 388, 389, 390, 391, + 392, 393, 394, 395, 396, 0, 397, 398, 399, 400, + 401, 402, 403, 404, 405, 406, 0, 407, 408, 733, + 409, 410, 411, 412, 413, 414, 415, 416, 417, 418, + 419, 0, 420, 421, 422, 423, 424, 1028, 425, 426, + 427, 428, 734, 429, 430, 431, 0, 432, 433, 434, + 435, 436, 437, 438, 439, 440, 441, 1030, 0, 443, + 444, 0, 445, 446, 447, 448, 449, 450, 0, 451, + 452, 0, 0, 453, 1033, 455, 1034, 0, 457, 458, + 459, 460, 461, 462, 463, 0, 0, 464, 465, 466, + 467, 468, 1037, 0, 469, 470, 471, 472, 473, 474, + 475, 0, 476, 735, 477, 478, 479, 0, 0, 480, + 0, 0, 481, 482, 483, 484, 485, 486, 1039, 1040, + 1041, 1042, 1043, 1044, 1045, 1046, 495, 496, 497, 0, + 0, 0, 0, 0, 0, 712, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 3461, 200, 201, 202, 203, + 204, 205, 206, 207, 0, 209, 210, 211, 0, 0, + 0, 0, 0, 0, 0, 212, 213, 0, 214, 215, + 713, 216, 217, 218, 219, 220, 714, 221, 222, 0, + 223, 224, 225, 226, 227, 0, 0, 228, 229, 230, + 231, 232, 0, 233, 234, 235, 236, 237, 0, 715, + 0, 238, 239, 240, 241, 716, 242, 243, 0, 244, + 245, 246, 247, 248, 249, 0, 717, 250, 251, 0, + 0, 0, 718, 0, 0, 0, 252, 253, 254, 255, + 256, 257, 258, 259, 260, 0, 261, 0, 262, 263, + 264, 265, 266, 0, 267, 268, 269, 0, 0, 270, + 271, 272, 273, 274, 0, 275, 276, 277, 0, 278, + 279, 0, 280, 281, 282, 283, 284, 285, 286, 287, + 288, 0, 289, 0, 290, 291, 292, 0, 293, 0, + 294, 719, 0, 720, 295, 296, 297, 0, 298, 299, + 0, 300, 0, 301, 302, 303, 304, 305, 721, 306, + 307, 308, 0, 309, 310, 311, 312, 313, 314, 0, + 315, 722, 316, 317, 318, 319, 320, 321, 322, 0, + 323, 0, 324, 723, 724, 325, 725, 326, 327, 328, + 329, 330, 331, 332, 0, 333, 334, 726, 335, 727, + 0, 336, 337, 338, 0, 0, 339, 340, 341, 342, + 343, 344, 345, 346, 347, 348, 349, 350, 351, 728, + 352, 353, 354, 355, 0, 356, 357, 729, 358, 0, + 359, 360, 361, 362, 363, 364, 0, 365, 0, 0, + 366, 367, 368, 0, 0, 369, 730, 731, 732, 370, + 371, 372, 373, 374, 375, 376, 377, 0, 378, 379, + 380, 381, 382, 383, 384, 0, 385, 386, 387, 388, + 389, 390, 391, 392, 393, 394, 395, 396, 0, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 0, + 407, 408, 733, 409, 410, 411, 412, 413, 414, 415, + 416, 417, 418, 419, 0, 420, 421, 422, 423, 424, + 0, 425, 426, 427, 428, 734, 429, 430, 431, 0, + 432, 433, 434, 435, 436, 437, 438, 439, 440, 441, + 442, 0, 443, 444, 0, 445, 446, 447, 448, 449, + 450, 0, 451, 452, 0, 0, 453, 454, 455, 456, + 0, 457, 458, 459, 460, 461, 462, 463, 0, 0, + 464, 465, 466, 467, 468, 0, 0, 469, 470, 471, + 472, 473, 474, 475, 0, 476, 735, 477, 478, 479, + 0, 0, 480, 0, 0, 481, 482, 483, 484, 485, + 486, 487, 488, 489, 490, 491, 492, 493, 494, 495, + 496, 497, 0, 0, 0, 0, 0, 0, 199, 1231, + 550, 0, 0, 0, 597, 0, 0, 0, 3987, 200, + 201, 202, 203, 204, 205, 206, 207, 0, 209, 210, + 211, 0, 0, 0, 0, 0, 0, 0, 212, 213, + 0, 214, 215, 0, 216, 217, 218, 219, 220, 0, + 221, 222, 0, 223, 224, 225, 226, 227, 0, 0, + 228, 229, 230, 231, 232, 0, 233, 234, 235, 236, + 237, 0, 0, 0, 238, 239, 240, 241, 0, 242, + 243, 0, 244, 245, 246, 247, 248, 249, 0, 0, + 250, 251, 0, 0, 0, 0, 0, 0, 0, 252, + 253, 254, 255, 256, 257, 258, 259, 260, 0, 261, + 0, 262, 263, 264, 265, 266, 0, 267, 268, 269, + 0, 0, 270, 271, 272, 273, 274, 0, 275, 276, + 277, 0, 278, 279, 0, 280, 281, 282, 283, 284, + 285, 286, 287, 288, 1464, 289, 0, 290, 291, 292, + 0, 293, 0, 294, 0, 0, 0, 295, 296, 297, + 0, 298, 299, 0, 300, 0, 301, 302, 303, 304, + 305, 0, 306, 307, 308, 0, 309, 310, 311, 312, + 313, 314, 0, 315, 0, 316, 317, 318, 319, 320, + 321, 322, 0, 323, 0, 324, 0, 0, 325, 0, + 326, 327, 328, 329, 330, 331, 332, 0, 333, 334, + 0, 335, 0, 0, 336, 337, 338, 0, 0, 339, + 340, 341, 342, 343, 344, 345, 346, 347, 348, 349, + 350, 351, 0, 352, 353, 354, 355, 0, 356, 357, + 0, 358, 0, 359, 360, 361, 362, 363, 364, 0, + 365, 1465, 0, 366, 367, 368, 0, 0, 369, 0, + 0, 0, 370, 371, 372, 373, 374, 375, 376, 377, + 0, 378, 379, 380, 381, 382, 383, 384, 0, 385, + 386, 387, 388, 389, 390, 391, 392, 393, 394, 395, + 396, 0, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 0, 407, 408, 0, 409, 410, 411, 412, + 413, 414, 415, 416, 417, 418, 419, 0, 420, 421, + 422, 423, 424, 0, 425, 426, 427, 428, 0, 429, + 430, 431, 0, 432, 433, 434, 435, 436, 437, 438, + 439, 440, 441, 442, 0, 443, 444, 0, 445, 446, + 447, 448, 449, 450, 0, 451, 452, 0, 0, 453, + 454, 455, 456, 1466, 457, 458, 459, 460, 461, 462, + 463, 0, 0, 464, 465, 466, 467, 468, 0, 0, + 469, 470, 471, 472, 473, 474, 475, 0, 476, 0, + 477, 478, 479, 0, 0, 480, 0, 0, 481, 482, + 483, 484, 485, 486, 487, 488, 489, 490, 491, 492, + 493, 494, 495, 496, 497, 0, 0, 0, 0, 0, + 0, 199, 609, 1232, 3584, 0, 0, 0, 0, 0, + 0, 3585, 200, 201, 202, 203, 204, 205, 206, 207, + 0, 209, 210, 211, 3, 4, 0, 0, 0, 0, + 0, 212, 213, 0, 214, 215, 0, 216, 217, 218, + 219, 220, 0, 221, 222, 0, 223, 224, 225, 226, + 227, 0, 0, 228, 229, 230, 231, 232, 0, 233, + 234, 235, 236, 237, 0, 0, 0, 238, 239, 240, + 241, 0, 242, 243, 0, 244, 245, 246, 247, 248, + 249, 0, 0, 250, 251, 0, 0, 0, 0, 0, + 0, 0, 252, 253, 254, 255, 256, 257, 258, 259, + 260, 0, 261, 0, 262, 263, 264, 265, 266, 0, + 267, 268, 269, 0, 0, 270, 271, 272, 273, 274, + 0, 275, 276, 277, 0, 278, 279, 0, 280, 281, + 282, 283, 284, 285, 286, 287, 288, 0, 289, 0, + 290, 291, 292, 0, 293, 0, 294, 0, 0, 0, + 295, 296, 297, 0, 298, 299, 0, 300, 0, 301, + 302, 303, 304, 305, 0, 306, 307, 308, 0, 309, + 310, 311, 312, 313, 314, 0, 315, 0, 316, 317, + 318, 319, 320, 321, 322, 0, 323, 0, 324, 0, + 0, 325, 0, 326, 327, 328, 329, 330, 331, 332, + 0, 333, 334, 0, 335, 0, 0, 336, 337, 338, + 0, 0, 339, 340, 341, 342, 343, 344, 345, 346, + 347, 348, 349, 350, 351, 0, 352, 353, 354, 355, + 0, 356, 357, 0, 358, 0, 359, 360, 361, 362, + 363, 364, 0, 365, 0, 0, 366, 367, 368, 0, + 0, 369, 0, 0, 0, 370, 371, 372, 373, 374, + 375, 376, 377, 0, 378, 379, 380, 381, 382, 383, + 384, 0, 385, 386, 387, 388, 389, 390, 391, 392, + 393, 394, 395, 396, 0, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 0, 407, 408, 0, 409, + 410, 411, 412, 413, 414, 415, 416, 417, 418, 419, + 37, 420, 421, 422, 423, 424, 0, 425, 426, 427, + 428, 0, 429, 430, 431, 0, 432, 433, 434, 435, + 436, 437, 438, 439, 440, 441, 442, 0, 443, 444, + 41, 445, 446, 447, 448, 449, 450, 0, 451, 452, + 0, 0, 453, 454, 455, 456, 0, 457, 458, 459, + 460, 461, 462, 463, 0, 0, 464, 465, 466, 467, + 468, 0, 0, 469, 470, 471, 472, 473, 920, 475, + 0, 476, 921, 477, 478, 479, 0, 0, 480, 0, + 46, 481, 482, 483, 484, 485, 486, 487, 488, 489, + 490, 491, 492, 493, 494, 495, 496, 497, 0, 0, + 0, 0, 0, 0, 199, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 47, 200, 201, 202, 203, 204, + 205, 206, 207, 0, 209, 210, 211, 0, 0, 0, + 0, 0, 0, 0, 212, 213, 0, 214, 215, 0, + 216, 217, 218, 219, 220, 0, 221, 222, 0, 223, + 224, 225, 226, 227, 0, 0, 228, 229, 230, 231, + 232, 0, 233, 234, 235, 236, 237, 0, 0, 0, + 238, 239, 240, 241, 0, 242, 243, 0, 244, 245, + 246, 247, 248, 249, 0, 0, 250, 251, 0, 0, + 0, 0, 0, 0, 0, 252, 253, 254, 255, 256, + 257, 258, 259, 260, 0, 261, 0, 262, 263, 264, + 265, 266, 0, 267, 268, 269, 0, 0, 270, 271, + 272, 273, 274, 0, 275, 276, 277, 0, 278, 279, + 0, 280, 281, 282, 283, 284, 285, 286, 287, 288, + 0, 289, 0, 290, 291, 292, 0, 293, 0, 294, + 0, 0, 0, 295, 296, 297, 0, 298, 299, 0, + 300, 0, 301, 302, 303, 304, 305, 0, 306, 307, + 308, 0, 309, 310, 311, 312, 313, 314, 0, 315, + 0, 316, 317, 318, 319, 320, 321, 322, 0, 323, + 0, 324, 0, 0, 325, 0, 326, 327, 328, 329, + 330, 331, 332, 0, 333, 334, 0, 335, 0, 0, + 336, 337, 338, 0, 0, 339, 340, 341, 342, 343, + 344, 345, 346, 347, 348, 349, 350, 351, 0, 352, + 353, 354, 355, 0, 356, 357, 0, 358, 0, 359, + 360, 361, 362, 363, 364, 0, 365, 0, 0, 366, + 367, 368, 0, 0, 369, 0, 0, 0, 370, 371, + 372, 373, 374, 375, 376, 377, 0, 378, 379, 380, + 381, 382, 383, 384, 0, 385, 386, 387, 388, 389, + 390, 391, 392, 393, 394, 395, 396, 0, 397, 398, + 399, 400, 401, 402, 403, 404, 405, 406, 0, 407, + 408, 0, 409, 410, 411, 412, 413, 414, 415, 416, + 417, 418, 419, 37, 420, 421, 422, 423, 424, 0, + 425, 426, 427, 428, 0, 429, 430, 431, 0, 432, + 433, 434, 435, 436, 437, 438, 439, 440, 441, 442, + 0, 443, 444, 41, 445, 446, 447, 448, 449, 450, + 0, 451, 452, 0, 0, 453, 454, 455, 456, 0, + 457, 458, 459, 460, 461, 462, 463, 0, 0, 464, + 465, 466, 467, 468, 0, 0, 469, 470, 471, 472, + 473, 920, 475, 0, 476, 0, 477, 478, 479, 0, + 0, 480, 0, 46, 481, 482, 483, 484, 485, 486, + 487, 488, 489, 490, 491, 492, 493, 494, 495, 496, + 497, 0, 0, 0, 0, 0, 0, 199, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 47, 200, 201, + 202, 203, 204, 205, 206, 207, 0, 209, 210, 211, + 0, 0, 0, 0, 0, 0, 0, 212, 213, 0, + 214, 215, 0, 216, 217, 218, 219, 220, 0, 221, + 222, 0, 223, 224, 225, 226, 227, 0, 0, 228, + 229, 230, 231, 232, 0, 233, 234, 235, 236, 237, + 0, 0, 0, 238, 239, 240, 241, 0, 242, 243, + 0, 244, 245, 246, 247, 248, 249, 0, 0, 250, + 251, 0, 0, 0, 0, 0, 0, 0, 252, 253, + 254, 255, 256, 257, 258, 259, 260, 0, 261, 0, + 262, 263, 264, 265, 266, 0, 267, 268, 269, 0, + 0, 270, 271, 272, 273, 274, 0, 275, 276, 277, + 0, 278, 279, 0, 280, 281, 282, 283, 284, 285, + 286, 287, 288, 0, 289, 0, 290, 291, 292, 0, + 293, 0, 294, 0, 0, 0, 295, 296, 297, 0, + 298, 299, 0, 300, 0, 301, 302, 303, 304, 305, + 0, 306, 307, 308, 0, 309, 310, 311, 312, 313, + 314, 0, 315, 0, 316, 317, 318, 319, 320, 321, + 322, 0, 323, 0, 324, 0, 0, 325, 0, 326, + 327, 328, 329, 330, 331, 332, 0, 333, 334, 0, + 335, 0, 0, 336, 337, 338, 0, 0, 339, 340, + 341, 342, 343, 344, 345, 346, 347, 348, 349, 350, + 351, 0, 352, 353, 354, 355, 0, 356, 357, 0, + 358, 0, 359, 360, 361, 362, 363, 364, 0, 365, + 0, 0, 366, 367, 368, 0, 0, 369, 0, 0, + 0, 370, 371, 372, 373, 374, 375, 376, 377, 0, + 378, 379, 380, 381, 382, 383, 384, 0, 385, 386, + 387, 388, 389, 390, 391, 392, 393, 394, 395, 396, + 0, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 0, 407, 408, 0, 409, 410, 411, 412, 413, + 414, 415, 416, 417, 418, 419, 0, 420, 421, 422, + 423, 424, 0, 425, 426, 427, 428, 0, 429, 430, + 431, 0, 432, 433, 434, 435, 436, 437, 438, 439, + 440, 441, 442, 0, 443, 444, 0, 445, 446, 447, + 448, 449, 450, 0, 451, 452, 0, 0, 453, 454, + 455, 456, 0, 457, 458, 459, 460, 461, 462, 463, + 0, 0, 464, 465, 466, 467, 468, 0, 0, 469, + 470, 471, 472, 473, 474, 475, 0, 476, 0, 477, + 478, 479, 0, 0, 480, 0, 0, 481, 482, 483, + 484, 485, 486, 487, 488, 489, 490, 491, 492, 493, + 494, 495, 496, 497, 0, 0, 0, 0, 0, 0, + 199, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1103, 200, 201, 202, 203, 204, 205, 206, 207, 0, + 209, 210, 211, 0, 0, 0, 0, 0, 0, 0, + 212, 213, 0, 214, 215, 0, 216, 217, 218, 219, + 220, 0, 221, 222, 0, 223, 224, 225, 226, 227, + 0, 0, 228, 229, 230, 231, 232, 0, 233, 234, + 235, 236, 237, 0, 0, 0, 238, 239, 240, 241, + 0, 242, 243, 0, 244, 245, 246, 247, 248, 249, + 0, 0, 250, 251, 0, 0, 0, 0, 0, 0, + 0, 252, 253, 254, 255, 256, 257, 258, 259, 260, + 0, 261, 0, 262, 263, 264, 265, 266, 0, 267, + 268, 269, 0, 0, 270, 271, 272, 273, 274, 0, + 275, 276, 277, 0, 278, 279, 0, 280, 281, 282, + 283, 284, 285, 286, 287, 288, 0, 289, 0, 290, + 291, 292, 0, 293, 0, 294, 0, 0, 0, 295, + 296, 297, 0, 298, 299, 0, 300, 0, 301, 302, + 303, 304, 305, 0, 306, 307, 308, 0, 309, 310, + 311, 312, 313, 314, 0, 315, 0, 316, 317, 318, + 319, 320, 321, 322, 0, 323, 0, 324, 0, 0, + 325, 0, 326, 327, 328, 329, 330, 331, 332, 0, + 333, 334, 0, 335, 0, 0, 336, 337, 338, 0, + 0, 339, 340, 341, 342, 343, 344, 345, 346, 347, + 348, 349, 350, 351, 0, 352, 353, 354, 355, 0, + 356, 357, 0, 358, 0, 359, 360, 361, 362, 363, + 364, 0, 365, 0, 0, 366, 367, 368, 0, 0, + 369, 0, 0, 0, 370, 371, 372, 373, 374, 375, + 376, 377, 0, 378, 379, 380, 381, 382, 383, 384, + 0, 385, 386, 387, 388, 389, 390, 391, 392, 393, + 394, 395, 396, 0, 397, 398, 399, 400, 401, 402, + 403, 404, 405, 406, 0, 407, 408, 0, 409, 410, + 411, 412, 413, 414, 415, 416, 417, 418, 419, 0, + 420, 421, 422, 423, 424, 0, 425, 426, 427, 428, + 0, 429, 430, 431, 0, 432, 433, 434, 435, 436, + 437, 438, 439, 440, 441, 442, 0, 443, 444, 0, + 445, 446, 447, 448, 449, 450, 0, 451, 452, 0, + 0, 453, 454, 455, 456, 0, 457, 458, 459, 460, + 461, 462, 463, 0, 0, 464, 465, 466, 467, 468, + 0, 0, 469, 470, 471, 472, 473, 474, 475, 0, + 476, 0, 477, 478, 479, 0, 0, 480, 0, 0, + 481, 482, 483, 484, 485, 486, 487, 488, 489, 490, + 491, 492, 493, 494, 495, 496, 497, 0, 0, 0, + 0, 0, 0, 199, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 2405, 200, 201, 202, 203, 204, 205, + 206, 207, 0, 209, 210, 211, 0, 0, 0, 0, + 0, 0, 0, 212, 213, 0, 214, 215, 0, 216, + 217, 218, 219, 220, 0, 221, 222, 0, 223, 224, + 225, 226, 227, 0, 0, 228, 229, 230, 231, 232, + 0, 233, 234, 235, 236, 237, 0, 0, 0, 238, + 239, 240, 241, 0, 242, 243, 0, 244, 245, 246, + 247, 248, 249, 0, 0, 250, 251, 0, 0, 0, + 0, 0, 0, 0, 252, 253, 254, 255, 256, 257, + 258, 259, 260, 0, 261, 0, 262, 263, 264, 265, + 266, 0, 267, 268, 269, 0, 0, 270, 271, 272, + 273, 274, 0, 275, 276, 277, 0, 278, 279, 0, + 280, 281, 282, 283, 284, 285, 286, 287, 288, 0, + 289, 0, 290, 291, 292, 0, 293, 0, 294, 0, + 0, 0, 295, 296, 297, 0, 298, 299, 0, 300, + 0, 301, 302, 303, 304, 305, 0, 306, 307, 308, + 0, 309, 310, 311, 312, 313, 314, 0, 315, 0, + 316, 317, 318, 319, 320, 321, 322, 0, 323, 0, + 324, 0, 0, 325, 0, 326, 327, 328, 329, 330, + 331, 332, 0, 333, 334, 0, 335, 0, 0, 336, + 337, 338, 0, 0, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 351, 0, 352, 353, + 354, 355, 0, 356, 357, 0, 358, 0, 359, 360, + 361, 362, 363, 364, 0, 365, 0, 0, 366, 367, + 368, 0, 0, 369, 0, 0, 0, 370, 371, 372, + 373, 374, 375, 376, 377, 0, 378, 379, 380, 381, + 382, 383, 384, 0, 385, 386, 387, 388, 389, 390, + 391, 392, 393, 394, 395, 396, 0, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 0, 407, 408, + 0, 409, 410, 411, 412, 413, 414, 415, 416, 417, + 418, 419, 0, 420, 421, 422, 423, 424, 0, 425, + 426, 427, 428, 0, 429, 430, 431, 0, 432, 433, + 434, 435, 436, 437, 438, 439, 440, 441, 442, 0, + 443, 444, 0, 445, 446, 447, 448, 449, 450, 0, + 451, 452, 0, 0, 453, 454, 455, 456, 0, 457, + 458, 459, 460, 461, 462, 463, 0, 0, 464, 465, + 466, 467, 468, 0, 0, 469, 470, 471, 472, 473, + 474, 475, 0, 476, 0, 477, 478, 479, 0, 0, + 480, 0, 0, 481, 482, 483, 484, 485, 486, 487, + 488, 489, 490, 491, 492, 493, 494, 495, 496, 497, + 0, 0, 0, 0, 0, 0, 199, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 3424, 200, 201, 202, + 203, 204, 205, 206, 207, 0, 209, 210, 211, 0, + 0, 0, 0, 0, 0, 0, 212, 213, 0, 214, + 215, 0, 216, 217, 218, 219, 220, 0, 221, 222, + 0, 223, 224, 225, 226, 227, 0, 0, 228, 229, + 230, 231, 232, 0, 233, 234, 235, 236, 237, 0, + 0, 0, 238, 239, 240, 241, 0, 242, 243, 0, + 244, 245, 246, 247, 248, 249, 0, 0, 250, 251, + 0, 0, 0, 0, 0, 0, 0, 252, 253, 254, + 255, 256, 257, 258, 259, 260, 0, 261, 0, 262, + 263, 264, 265, 266, 0, 267, 268, 269, 0, 0, + 270, 271, 272, 273, 274, 0, 275, 276, 277, 0, + 278, 279, 0, 280, 281, 282, 283, 284, 285, 286, + 287, 288, 0, 289, 0, 290, 291, 292, 0, 293, + 0, 294, 0, 0, 0, 295, 296, 297, 0, 298, + 299, 0, 300, 0, 301, 302, 303, 304, 305, 0, + 306, 307, 308, 0, 309, 310, 311, 312, 313, 314, + 0, 315, 0, 316, 317, 318, 319, 320, 321, 322, + 0, 323, 0, 324, 0, 0, 325, 0, 326, 327, + 328, 329, 330, 331, 332, 0, 333, 334, 0, 335, + 0, 0, 336, 337, 338, 0, 0, 339, 340, 341, + 342, 343, 344, 345, 346, 347, 348, 349, 350, 351, + 0, 352, 353, 354, 355, 0, 356, 357, 0, 358, + 0, 359, 360, 361, 362, 363, 364, 0, 365, 0, + 0, 366, 367, 368, 0, 0, 369, 0, 0, 0, + 370, 371, 372, 373, 374, 375, 376, 377, 0, 378, + 379, 380, 381, 382, 383, 384, 0, 385, 386, 387, + 388, 389, 390, 391, 392, 393, 394, 395, 396, 0, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 0, 407, 408, 0, 409, 410, 411, 412, 413, 414, + 415, 416, 417, 418, 419, 0, 420, 421, 422, 423, + 424, 0, 425, 426, 427, 428, 0, 429, 430, 431, + 0, 432, 433, 434, 435, 436, 437, 438, 439, 440, + 441, 442, 0, 443, 444, 0, 445, 446, 447, 448, + 449, 450, 0, 451, 452, 0, 0, 453, 454, 455, + 456, 0, 457, 458, 459, 460, 461, 462, 463, 0, + 0, 464, 465, 466, 467, 468, 0, 0, 469, 470, + 471, 472, 473, 474, 475, 0, 476, 0, 477, 478, + 479, 0, 0, 480, 0, 0, 481, 482, 483, 484, + 485, 486, 487, 488, 489, 490, 491, 492, 493, 494, + 495, 496, 497, 0, 0, 0, 0, 0, 0, 1330, + 1231, 550, 0, 0, 760, 597, 0, 0, 0, 3754, + 200, 201, 202, 203, 204, 205, 206, 207, 1665, 209, + 210, 211, 1666, 1667, 1668, 1669, 1670, 1671, 1672, 212, + 213, 1673, 214, 215, 713, 216, 217, 218, 0, 1331, + 714, 1332, 1333, 1674, 223, 224, 225, 226, 227, 1675, + 1676, 228, 229, 1334, 1335, 232, 1677, 233, 234, 235, + 236, 0, 1678, 715, 1679, 238, 239, 240, 241, 716, + 242, 243, 1680, 244, 245, 246, 247, 248, 249, 1681, + 717, 250, 251, 1682, 1683, 1684, 718, 1685, 1686, 1687, + 252, 253, 254, 255, 256, 257, 1336, 1337, 260, 1688, + 261, 1689, 262, 263, 264, 265, 266, 1690, 267, 268, + 269, 1691, 1692, 270, 271, 1005, 273, 274, 1693, 275, + 276, 277, 1694, 278, 279, 1695, 280, 281, 282, 283, + 0, 285, 286, 287, 0, 1696, 289, 1697, 290, 1338, + 292, 1698, 293, 1699, 294, 719, 1700, 720, 295, 296, + 297, 1701, 298, 0, 1702, 300, 1703, 301, 302, 303, + 304, 305, 721, 306, 307, 308, 1704, 309, 310, 311, + 312, 313, 314, 1705, 315, 722, 0, 317, 318, 319, + 320, 1339, 1340, 1706, 1341, 1707, 324, 723, 724, 325, + 725, 326, 327, 328, 329, 330, 331, 332, 1708, 333, + 0, 726, 335, 727, 1709, 336, 337, 338, 1710, 1711, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 1342, 728, 1343, 353, 354, 0, 1712, 356, + 357, 729, 358, 1713, 0, 360, 1344, 362, 363, 364, + 1714, 365, 1715, 1716, 3158, 367, 368, 1717, 1718, 0, + 730, 731, 732, 0, 371, 372, 373, 374, 375, 376, + 377, 1719, 378, 0, 380, 0, 382, 383, 384, 1720, + 385, 386, 387, 388, 389, 390, 391, 1345, 393, 394, + 395, 396, 1721, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 1722, 407, 408, 733, 409, 410, 0, + 412, 413, 414, 415, 416, 417, 418, 419, 1723, 420, + 421, 422, 423, 424, 1724, 425, 1881, 427, 428, 734, + 429, 1347, 431, 1725, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 0, 1726, 443, 444, 1727, 445, + 446, 447, 448, 449, 450, 1728, 1348, 1349, 1729, 1730, + 453, 0, 455, 0, 1731, 457, 458, 459, 460, 461, + 462, 463, 1732, 1733, 464, 465, 466, 467, 468, 1734, + 1735, 469, 470, 471, 472, 473, 0, 1350, 1736, 476, + 735, 477, 478, 479, 1737, 1738, 480, 1739, 1740, 481, + 482, 483, 484, 485, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 495, 496, 497, 0, 0, 0, 763, + 764, 765, 0, 3159, 3160, 768, 769, 770, 771, 199, + 0, 0, 0, 0, 760, 0, 0, 0, 0, 0, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 0, 0, 0, 212, + 213, 0, 214, 215, 0, 216, 217, 218, 219, 220, + 0, 221, 222, 0, 223, 224, 225, 226, 227, 0, + 0, 228, 229, 230, 231, 232, 0, 233, 761, 235, + 236, 237, 0, 0, 0, 238, 239, 240, 241, 0, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 0, + 0, 250, 251, 0, 0, 0, 0, 0, 0, 0, + 252, 253, 254, 255, 256, 257, 258, 259, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 272, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 284, 285, 286, 287, 288, 0, 762, 0, 290, 291, + 292, 0, 293, 0, 294, 0, 0, 0, 295, 296, + 297, 0, 298, 299, 0, 300, 0, 301, 302, 303, + 304, 305, 0, 306, 307, 308, 0, 309, 310, 311, + 312, 313, 314, 0, 315, 0, 316, 317, 318, 319, + 320, 321, 322, 0, 323, 0, 324, 0, 0, 325, + 0, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 334, 0, 335, 0, 0, 336, 337, 338, 0, 0, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 351, 0, 352, 353, 354, 355, 0, 356, + 357, 0, 358, 0, 359, 360, 361, 362, 363, 364, + 0, 365, 0, 0, 366, 367, 368, 0, 0, 369, + 0, 0, 0, 370, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 379, 380, 381, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 0, 409, 410, 411, + 412, 413, 414, 415, 416, 417, 418, 419, 0, 420, + 421, 422, 423, 424, 0, 425, 426, 427, 428, 0, + 429, 430, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 442, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 451, 452, 0, 0, + 453, 454, 455, 456, 0, 457, 458, 459, 460, 461, + 462, 463, 0, 0, 464, 465, 466, 467, 468, 0, + 0, 469, 470, 471, 472, 473, 474, 475, 0, 476, + 0, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 485, 486, 487, 488, 489, 490, 491, + 492, 493, 494, 495, 496, 497, 0, 0, 0, 763, + 764, 765, 0, 766, 767, 768, 769, 770, 771, 199, + 0, 0, 0, 0, 760, 0, 0, 0, 0, 0, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 0, 0, 0, 212, + 213, 0, 214, 215, 0, 216, 217, 218, 219, 220, + 0, 221, 222, 0, 223, 224, 225, 226, 227, 0, + 0, 228, 229, 230, 231, 232, 0, 233, 848, 235, + 236, 237, 0, 0, 0, 238, 239, 240, 241, 0, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 0, + 0, 250, 251, 0, 0, 0, 0, 0, 0, 0, + 252, 253, 254, 255, 256, 257, 258, 259, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 272, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 284, 285, 286, 287, 288, 0, 849, 0, 290, 291, + 292, 0, 293, 0, 294, 0, 0, 0, 295, 296, + 297, 0, 298, 299, 0, 300, 0, 301, 302, 303, + 304, 305, 0, 306, 307, 308, 0, 309, 310, 311, + 312, 313, 314, 0, 315, 0, 316, 317, 318, 319, + 320, 321, 322, 0, 323, 0, 324, 0, 0, 325, + 0, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 334, 0, 335, 0, 0, 336, 337, 338, 0, 0, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 351, 0, 352, 353, 354, 355, 0, 356, + 357, 0, 358, 0, 359, 360, 361, 362, 363, 364, + 0, 365, 0, 0, 366, 367, 368, 0, 0, 369, + 0, 0, 0, 370, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 379, 380, 381, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 0, 409, 410, 411, + 412, 413, 414, 415, 416, 417, 418, 419, 0, 420, + 421, 422, 423, 424, 0, 425, 426, 427, 428, 0, + 429, 430, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 442, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 451, 452, 0, 0, + 453, 454, 455, 456, 0, 457, 458, 459, 460, 461, + 462, 463, 0, 0, 464, 465, 466, 467, 468, 0, + 0, 469, 470, 471, 472, 473, 474, 475, 0, 476, + 0, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 485, 486, 487, 488, 489, 490, 491, + 492, 493, 494, 495, 496, 497, 0, 0, 0, 763, + 764, 765, 0, 766, 767, 768, 769, 770, 771, 199, + 0, 0, 0, 0, 760, 0, 0, 0, 0, 0, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 0, 0, 0, 212, + 213, 0, 214, 215, 0, 216, 217, 218, 219, 220, + 0, 221, 222, 0, 223, 224, 225, 226, 227, 0, + 0, 228, 229, 230, 231, 232, 0, 233, 893, 235, + 236, 237, 0, 0, 0, 238, 239, 240, 241, 0, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 0, + 0, 250, 251, 0, 0, 0, 0, 0, 0, 0, + 252, 253, 254, 255, 256, 257, 258, 259, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 272, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 284, 285, 286, 287, 288, 0, 894, 0, 290, 291, + 292, 0, 293, 0, 294, 0, 0, 0, 295, 296, + 297, 0, 298, 299, 0, 300, 0, 301, 302, 303, + 304, 895, 0, 306, 307, 308, 0, 309, 310, 311, + 312, 313, 314, 0, 315, 0, 316, 317, 318, 319, + 320, 321, 322, 0, 323, 0, 324, 0, 0, 325, + 0, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 334, 0, 335, 0, 0, 336, 337, 338, 0, 0, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 351, 0, 352, 353, 354, 355, 0, 356, + 357, 0, 358, 0, 359, 360, 361, 362, 363, 364, + 0, 365, 0, 0, 366, 367, 368, 0, 0, 369, + 0, 0, 0, 370, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 379, 380, 381, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 0, 409, 410, 411, + 412, 413, 414, 415, 416, 417, 418, 419, 0, 420, + 421, 422, 423, 424, 0, 425, 426, 427, 428, 0, + 429, 430, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 442, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 451, 452, 0, 0, + 453, 454, 455, 456, 0, 457, 458, 459, 460, 461, + 462, 463, 0, 0, 464, 465, 466, 467, 468, 0, + 0, 469, 470, 471, 472, 473, 474, 475, 0, 476, + 0, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 485, 486, 487, 488, 489, 490, 491, + 492, 493, 494, 495, 496, 497, 0, 0, 0, 763, + 764, 765, 0, 766, 767, 768, 769, 770, 771, 199, + 0, 0, 0, 0, 760, 0, 0, 0, 0, 0, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 0, 0, 0, 212, + 213, 0, 214, 215, 0, 216, 217, 218, 219, 220, + 0, 221, 222, 0, 223, 224, 225, 226, 227, 0, + 0, 228, 229, 230, 231, 232, 0, 233, 1313, 235, + 236, 237, 0, 0, 0, 238, 239, 240, 241, 0, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 0, + 0, 250, 251, 0, 0, 0, 0, 0, 0, 0, + 252, 253, 254, 255, 256, 257, 258, 259, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 272, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 284, 285, 286, 287, 288, 0, 1314, 0, 290, 291, + 292, 0, 293, 0, 294, 0, 0, 0, 295, 296, + 297, 0, 298, 299, 0, 300, 0, 301, 302, 303, + 304, 305, 0, 306, 307, 308, 0, 309, 310, 311, + 312, 313, 314, 0, 315, 0, 316, 317, 318, 319, + 320, 321, 322, 0, 323, 0, 324, 0, 0, 325, + 0, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 334, 0, 335, 0, 0, 336, 337, 338, 0, 0, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 351, 0, 352, 353, 354, 355, 0, 356, + 357, 0, 358, 0, 359, 360, 361, 362, 363, 364, + 0, 365, 0, 0, 366, 367, 368, 0, 0, 369, + 0, 0, 0, 370, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 379, 380, 381, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 0, 409, 410, 411, + 412, 413, 414, 415, 416, 417, 418, 419, 0, 420, + 421, 422, 423, 424, 0, 425, 426, 427, 428, 0, + 429, 430, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 442, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 451, 452, 0, 0, + 453, 454, 455, 456, 0, 457, 458, 459, 460, 461, + 462, 463, 0, 0, 464, 465, 466, 467, 468, 0, + 0, 469, 470, 471, 472, 473, 474, 475, 0, 476, + 0, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 485, 486, 487, 488, 489, 490, 491, + 492, 493, 494, 495, 496, 497, 0, 0, 0, 763, + 764, 765, 0, 766, 767, 768, 769, 770, 771, 199, + 0, 0, 0, 0, 760, 0, 0, 0, 0, 0, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 0, 0, 0, 212, + 213, 0, 214, 215, 0, 216, 217, 218, 219, 220, + 0, 221, 222, 0, 223, 224, 225, 226, 227, 0, + 0, 228, 229, 230, 231, 232, 0, 233, 234, 235, + 236, 237, 0, 0, 0, 238, 239, 240, 241, 0, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 0, + 0, 250, 251, 0, 0, 0, 0, 0, 0, 0, + 252, 253, 254, 255, 256, 257, 258, 259, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 272, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 284, 285, 286, 287, 288, 0, 289, 0, 290, 291, + 292, 0, 293, 0, 294, 0, 0, 0, 295, 296, + 297, 0, 298, 299, 0, 300, 0, 301, 302, 303, + 304, 305, 0, 306, 307, 308, 0, 309, 310, 311, + 312, 313, 314, 0, 315, 0, 316, 317, 318, 319, + 320, 321, 322, 0, 323, 0, 324, 0, 0, 325, + 0, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 334, 0, 335, 0, 0, 336, 337, 338, 0, 0, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 351, 0, 352, 353, 354, 355, 0, 356, + 357, 0, 358, 0, 359, 360, 361, 362, 363, 364, + 0, 365, 0, 0, 366, 367, 368, 0, 0, 369, + 0, 0, 0, 370, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 379, 380, 381, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 0, 409, 410, 411, + 412, 413, 414, 415, 416, 417, 418, 419, 0, 420, + 421, 422, 423, 424, 0, 425, 426, 427, 428, 0, + 429, 430, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 442, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 451, 452, 0, 0, + 453, 454, 455, 456, 0, 457, 458, 459, 460, 461, + 462, 463, 0, 0, 464, 465, 466, 467, 468, 0, + 0, 469, 470, 471, 472, 473, 474, 475, 0, 476, + 0, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 485, 486, 487, 488, 489, 490, 491, + 492, 493, 494, 495, 496, 497, 0, 0, 0, 763, + 764, 765, 0, 766, 767, 768, 769, 770, 771, 199, + 0, 0, 0, 0, 760, 0, 0, 0, 0, 0, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 0, 0, 0, 212, + 213, 0, 214, 215, 0, 216, 217, 218, 219, 220, + 0, 221, 222, 0, 223, 224, 225, 226, 227, 0, + 0, 228, 229, 230, 231, 232, 0, 233, 2465, 235, + 236, 237, 0, 0, 0, 238, 239, 240, 241, 0, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 0, + 0, 250, 251, 0, 0, 0, 0, 0, 0, 0, + 252, 253, 254, 255, 256, 257, 258, 259, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 272, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 284, 285, 286, 287, 288, 0, 2466, 0, 290, 291, + 292, 0, 293, 0, 294, 0, 0, 0, 295, 296, + 297, 0, 298, 299, 0, 300, 0, 301, 302, 303, + 304, 305, 0, 306, 307, 308, 0, 309, 310, 311, + 312, 313, 314, 0, 315, 0, 316, 317, 318, 319, + 320, 321, 322, 0, 323, 0, 324, 0, 0, 325, + 0, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 334, 0, 335, 0, 0, 336, 337, 338, 0, 0, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 351, 0, 352, 353, 354, 355, 0, 356, + 357, 0, 358, 0, 359, 360, 361, 362, 363, 364, + 0, 365, 0, 0, 366, 367, 368, 0, 0, 369, + 0, 0, 0, 370, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 379, 380, 381, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 0, 409, 410, 411, + 412, 413, 414, 415, 416, 417, 418, 419, 0, 420, + 421, 422, 423, 424, 0, 425, 426, 427, 428, 0, + 429, 430, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 442, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 451, 452, 0, 0, + 453, 454, 455, 456, 0, 457, 458, 459, 460, 461, + 462, 463, 0, 0, 464, 465, 466, 467, 468, 0, + 0, 469, 470, 471, 472, 473, 474, 475, 0, 476, + 0, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 485, 486, 487, 488, 489, 490, 491, + 492, 493, 494, 495, 496, 497, 0, 0, 0, 763, + 764, 765, 0, 766, 767, 768, 769, 770, 771, 199, + 0, 0, 0, 0, 760, 0, 0, 0, 0, 0, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 0, 0, 0, 212, + 213, 0, 214, 215, 0, 216, 217, 218, 219, 220, + 0, 221, 222, 0, 223, 224, 225, 226, 227, 0, + 0, 228, 229, 230, 231, 232, 0, 233, 234, 235, + 236, 237, 0, 0, 0, 238, 239, 240, 241, 0, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 0, + 0, 250, 251, 0, 0, 0, 0, 0, 0, 0, + 252, 253, 254, 255, 256, 257, 258, 259, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 272, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 284, 285, 286, 287, 288, 0, 289, 0, 290, 291, + 292, 0, 293, 0, 294, 0, 0, 0, 295, 296, + 297, 0, 298, 299, 0, 300, 0, 301, 302, 303, + 304, 305, 0, 306, 307, 308, 0, 309, 310, 311, + 312, 313, 314, 0, 315, 0, 316, 317, 318, 319, + 320, 321, 322, 0, 323, 0, 324, 0, 0, 325, + 0, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 334, 0, 335, 0, 0, 336, 337, 338, 0, 0, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 351, 0, 352, 353, 354, 355, 0, 356, + 357, 0, 358, 0, 359, 360, 361, 362, 363, 364, + 0, 365, 0, 0, 3971, 367, 368, 0, 0, 369, + 0, 0, 0, 370, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 379, 380, 381, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 0, 409, 410, 411, + 412, 413, 414, 415, 416, 417, 418, 419, 0, 420, + 421, 422, 423, 424, 0, 425, 426, 427, 428, 0, + 429, 430, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 442, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 451, 452, 0, 0, + 453, 454, 455, 456, 0, 457, 458, 459, 460, 461, + 462, 463, 0, 0, 464, 465, 466, 467, 468, 0, + 0, 469, 470, 471, 472, 473, 474, 475, 0, 476, + 0, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 485, 486, 487, 488, 489, 490, 491, + 492, 493, 494, 495, 496, 497, 0, 0, 1664, 763, + 764, 765, 0, 766, 767, 768, 769, 770, 771, 200, + 201, 202, 203, 204, 205, 206, 207, 1665, 209, 210, + 211, 1666, 1667, 1668, 1669, 1670, 1671, 1672, 212, 213, + 1673, 214, 215, 713, 216, 217, 218, 219, 220, 714, + 221, 222, 1674, 223, 224, 225, 226, 227, 1675, 1676, + 228, 229, 230, 231, 232, 1677, 233, 234, 235, 236, + 237, 1678, 715, 1679, 238, 239, 240, 241, 716, 242, + 243, 1680, 244, 245, 246, 247, 248, 249, 1681, 717, + 250, 251, 1682, 1683, 1684, 718, 1685, 1686, 1687, 252, + 253, 254, 255, 256, 257, 258, 259, 260, 1688, 261, + 1689, 262, 263, 264, 265, 266, 1690, 267, 268, 269, + 1691, 1692, 270, 271, 272, 273, 274, 1693, 275, 276, + 277, 1694, 278, 279, 1695, 280, 281, 282, 283, 284, + 285, 286, 287, 288, 1696, 289, 1697, 290, 291, 292, + 1698, 293, 1699, 294, 719, 1700, 720, 295, 296, 297, + 1701, 298, 299, 1702, 300, 1703, 301, 302, 303, 304, + 305, 721, 306, 307, 308, 1704, 309, 310, 311, 312, + 313, 314, 1705, 315, 722, 316, 317, 318, 319, 320, + 321, 322, 1706, 323, 1707, 324, 723, 724, 325, 725, + 326, 327, 328, 329, 330, 331, 332, 1708, 333, 334, + 726, 335, 727, 1709, 336, 337, 338, 1710, 1711, 339, + 340, 341, 342, 343, 344, 345, 346, 347, 348, 349, + 350, 351, 728, 352, 353, 354, 355, 1712, 356, 357, + 729, 358, 1713, 359, 360, 361, 362, 363, 364, 1714, + 365, 1715, 1716, 366, 367, 368, 1717, 1718, 369, 730, + 731, 732, 370, 371, 372, 373, 374, 375, 376, 377, + 1719, 378, 379, 380, 381, 382, 383, 384, 1720, 385, + 386, 387, 388, 389, 390, 391, 392, 393, 394, 395, + 396, 1721, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 1722, 407, 408, 733, 409, 410, 411, 412, + 413, 414, 415, 416, 417, 418, 419, 1723, 420, 421, + 422, 423, 424, 1724, 425, 426, 427, 428, 734, 429, + 430, 431, 1725, 432, 433, 434, 435, 436, 437, 438, + 439, 440, 441, 442, 1726, 443, 444, 1727, 445, 446, + 447, 448, 449, 450, 1728, 451, 452, 1729, 1730, 453, + 454, 455, 456, 1731, 457, 458, 459, 460, 461, 462, + 463, 1732, 1733, 464, 465, 466, 467, 468, 1734, 1735, + 469, 470, 471, 472, 473, 474, 475, 1736, 476, 735, + 477, 478, 479, 1737, 1738, 480, 1739, 1740, 481, 482, + 483, 484, 485, 486, 487, 488, 489, 490, 491, 492, + 493, 494, 495, 496, 497, 199, 0, 0, 0, 0, + 0, 0, 0, 0, 1741, 0, 200, 201, 202, 203, + 204, 205, 206, 207, 0, 209, 210, 211, 0, 0, + 0, 0, 0, 0, 0, 212, 213, 0, 214, 215, + 0, 216, 217, 218, 219, 220, 0, 221, 222, 0, + 223, 224, 225, 226, 227, 0, 0, 228, 229, 230, + 231, 232, 0, 233, 234, 235, 236, 237, 0, 0, + 0, 238, 239, 240, 241, 0, 242, 243, 0, 244, + 245, 246, 247, 248, 249, 0, 0, 250, 251, 0, + 0, 0, 0, 0, 0, 0, 252, 253, 254, 255, + 256, 257, 258, 259, 260, 0, 261, 0, 262, 263, + 264, 265, 266, 0, 267, 268, 269, 0, 0, 270, + 271, 272, 273, 274, 0, 275, 276, 277, 0, 278, + 279, 0, 280, 281, 282, 283, 284, 285, 286, 287, + 288, 0, 289, 0, 290, 291, 292, 0, 293, 0, + 294, 0, 0, 0, 295, 296, 297, 0, 298, 299, + 0, 300, 0, 301, 302, 303, 304, 305, 0, 306, + 307, 308, 0, 309, 310, 311, 312, 313, 314, 0, + 315, 0, 316, 317, 318, 319, 320, 321, 322, 0, + 323, 0, 324, 0, 0, 325, 0, 326, 327, 328, + 329, 330, 331, 332, 0, 333, 334, 0, 335, 0, + 0, 336, 337, 338, 0, 0, 339, 340, 341, 342, + 343, 344, 345, 346, 347, 348, 349, 350, 351, 0, + 352, 353, 354, 355, 0, 356, 357, 0, 358, 0, + 359, 360, 361, 362, 363, 364, 0, 365, 0, 0, + 366, 367, 368, 0, 0, 369, 0, 0, 0, 370, + 371, 372, 373, 374, 375, 376, 377, 0, 378, 379, + 380, 381, 382, 383, 384, 0, 385, 386, 387, 388, + 389, 390, 391, 392, 393, 394, 395, 396, 0, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 0, + 407, 408, 0, 409, 410, 411, 412, 413, 414, 415, + 416, 417, 418, 419, 0, 420, 421, 422, 423, 424, + 0, 425, 426, 427, 428, 0, 429, 430, 431, 0, + 432, 433, 434, 435, 436, 437, 438, 439, 440, 441, + 442, 0, 443, 444, 0, 445, 446, 447, 448, 449, + 450, 0, 451, 452, 0, 0, 453, 454, 455, 456, + 0, 457, 458, 459, 460, 461, 462, 463, 0, 0, + 464, 465, 466, 467, 468, 0, 0, 469, 470, 471, + 472, 473, 474, 475, 0, 476, 0, 477, 478, 479, + 0, 0, 480, 0, 0, 481, 482, 483, 484, 485, + 486, 487, 488, 489, 490, 491, 492, 493, 494, 495, + 496, 497, 199, 0, 0, 0, 0, 0, 0, 0, + 0, 682, 0, 200, 201, 202, 203, 204, 205, 206, + 207, 0, 209, 210, 211, 0, 0, 0, 0, 0, + 0, 0, 212, 213, 0, 214, 215, 0, 216, 217, + 218, 219, 220, 0, 221, 222, 0, 223, 224, 225, + 226, 227, 0, 0, 228, 229, 230, 231, 232, 0, + 233, 234, 235, 236, 237, 0, 0, 0, 238, 239, + 240, 241, 0, 242, 243, 0, 244, 245, 246, 247, + 248, 249, 0, 0, 250, 251, 0, 0, 0, 0, + 0, 0, 0, 252, 253, 254, 255, 256, 257, 258, + 259, 260, 0, 261, 0, 262, 263, 264, 265, 266, + 0, 267, 268, 269, 0, 0, 270, 271, 272, 273, + 274, 0, 275, 276, 277, 0, 278, 279, 0, 280, + 281, 282, 283, 284, 285, 286, 287, 288, 0, 289, + 0, 290, 291, 292, 0, 293, 0, 294, 0, 0, + 0, 295, 296, 297, 0, 298, 299, 0, 300, 0, + 301, 302, 303, 304, 305, 0, 306, 307, 308, 0, + 309, 310, 311, 312, 313, 314, 0, 315, 0, 316, + 317, 318, 319, 320, 321, 322, 0, 323, 0, 324, + 0, 0, 325, 0, 326, 327, 328, 329, 330, 331, + 332, 0, 333, 334, 0, 335, 0, 0, 336, 337, + 338, 0, 0, 339, 340, 341, 342, 343, 344, 345, + 346, 347, 348, 349, 350, 351, 0, 352, 353, 354, + 355, 0, 356, 357, 0, 358, 0, 359, 360, 361, + 362, 363, 364, 0, 365, 0, 0, 366, 367, 368, + 0, 0, 369, 0, 0, 0, 370, 371, 372, 373, + 374, 375, 376, 377, 0, 378, 379, 380, 381, 382, + 383, 384, 0, 385, 386, 387, 388, 389, 390, 391, + 392, 393, 394, 395, 396, 0, 397, 398, 399, 400, + 401, 402, 403, 404, 405, 406, 0, 407, 408, 0, + 409, 410, 411, 412, 413, 414, 415, 416, 417, 418, + 419, 0, 420, 421, 422, 423, 424, 0, 425, 426, + 427, 428, 0, 429, 430, 431, 0, 432, 433, 434, + 435, 436, 437, 438, 439, 440, 441, 442, 0, 443, + 444, 0, 445, 446, 447, 448, 449, 450, 0, 451, + 452, 0, 0, 453, 454, 455, 456, 0, 457, 458, + 459, 460, 461, 462, 463, 0, 0, 464, 465, 466, + 467, 468, 0, 0, 469, 470, 471, 472, 473, 474, + 475, 0, 476, 0, 477, 478, 479, 0, 0, 480, + 0, 0, 481, 482, 483, 484, 485, 486, 487, 488, + 489, 490, 491, 492, 493, 494, 495, 496, 497, 1330, + 0, 0, 0, 0, 0, 0, 0, 0, 3850, 0, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 0, 0, 0, 212, + 213, 0, 214, 215, 713, 216, 217, 218, 0, 1331, + 714, 1332, 1333, 0, 223, 224, 225, 226, 227, 0, + 0, 228, 229, 1334, 1335, 232, 0, 233, 234, 235, + 236, 0, 0, 715, 0, 238, 239, 240, 241, 716, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 0, + 717, 250, 251, 0, 0, 0, 718, 0, 0, 0, + 252, 253, 254, 255, 256, 257, 1336, 1337, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 1005, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 0, 285, 286, 287, 0, 0, 289, 0, 290, 1338, + 292, 0, 293, 0, 294, 719, 0, 720, 295, 296, + 297, 0, 298, 0, 0, 300, 0, 301, 302, 303, + 304, 305, 721, 306, 307, 308, 0, 309, 310, 311, + 312, 313, 314, 0, 315, 722, 0, 317, 318, 319, + 320, 1339, 1340, 0, 1341, 0, 324, 723, 724, 325, + 725, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 0, 726, 335, 727, 0, 336, 337, 338, 0, 0, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 1342, 728, 1343, 353, 354, 0, 0, 356, + 357, 729, 358, 0, 0, 360, 1344, 362, 363, 364, + 0, 365, 0, 0, 366, 367, 368, 0, 0, 0, + 730, 731, 732, 0, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 0, 380, 0, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 1345, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 733, 409, 410, 0, + 412, 413, 414, 415, 416, 417, 418, 419, 0, 420, + 421, 422, 423, 424, 0, 425, 1346, 427, 428, 734, + 429, 1347, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 0, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 1348, 1349, 0, 0, + 453, 0, 455, 0, 0, 457, 458, 459, 460, 461, + 462, 463, 0, 0, 464, 465, 466, 467, 468, 0, + 0, 469, 470, 471, 472, 473, 0, 1350, 0, 476, + 735, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 485, 0, 0, 2024, 0, 0, 0, + 0, 0, 0, 495, 496, 497, 0, 200, 201, 202, + 203, 204, 205, 206, 207, 1795, 209, 210, 211, 0, + 0, 0, 0, 0, 0, 0, 212, 213, 0, 214, + 215, 713, 216, 217, 218, 0, 1331, 714, 1332, 1333, + 0, 223, 224, 225, 226, 227, 0, 0, 228, 229, + 1334, 1335, 232, 0, 233, 234, 235, 236, 0, 0, + 715, 0, 238, 239, 240, 241, 716, 242, 243, 0, + 244, 245, 246, 247, 248, 249, 0, 717, 250, 251, + 0, 0, 0, 718, 0, 0, 0, 252, 253, 254, + 255, 256, 257, 1336, 1337, 260, 0, 261, 0, 262, + 263, 264, 265, 266, 0, 267, 268, 269, 0, 0, + 270, 271, 1005, 273, 274, 0, 275, 276, 277, 0, + 278, 279, 0, 280, 281, 282, 283, 0, 285, 286, + 287, 0, 0, 289, 0, 290, 1338, 292, 0, 293, + 0, 294, 719, 0, 720, 295, 296, 297, 0, 298, + 0, 0, 300, 0, 301, 302, 303, 304, 305, 721, + 306, 307, 308, 0, 309, 310, 311, 312, 313, 314, + 0, 315, 722, 0, 317, 318, 319, 320, 1339, 1340, + 0, 1341, 0, 324, 723, 724, 325, 725, 326, 327, + 328, 329, 330, 331, 332, 0, 333, 0, 726, 335, + 727, 0, 336, 337, 338, 0, 0, 339, 340, 341, + 342, 343, 344, 345, 346, 347, 348, 349, 350, 1342, + 728, 1343, 353, 354, 0, 0, 356, 357, 729, 358, + 0, 0, 360, 1344, 362, 363, 364, 0, 365, 0, + 0, 366, 367, 368, 0, 0, 0, 730, 731, 732, + 0, 371, 372, 373, 374, 375, 376, 377, 0, 378, + 0, 380, 0, 382, 383, 384, 0, 385, 386, 387, + 388, 389, 390, 391, 1345, 393, 394, 395, 396, 0, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 0, 407, 408, 733, 409, 410, 0, 412, 413, 414, + 415, 416, 417, 418, 419, 0, 420, 421, 422, 423, + 424, 0, 425, 1346, 427, 428, 734, 429, 1347, 431, + 0, 432, 433, 434, 435, 436, 437, 438, 439, 440, + 441, 0, 0, 443, 444, 0, 445, 446, 447, 448, + 449, 450, 0, 1348, 1349, 0, 0, 453, 0, 455, + 0, 0, 457, 458, 459, 460, 461, 462, 463, 0, + 0, 464, 465, 466, 467, 468, 0, 0, 469, 470, + 471, 472, 473, 0, 1350, 0, 476, 735, 477, 478, + 479, 0, 0, 480, 0, 0, 481, 482, 483, 484, + 485, 0, 0, 199, 1231, 550, 0, 0, 0, 597, + 495, 496, 497, 0, 200, 201, 202, 203, 204, 205, + 206, 207, 1795, 209, 210, 211, 0, 0, 0, 0, + 0, 0, 0, 212, 213, 0, 214, 215, 0, 216, + 217, 218, 219, 220, 0, 221, 222, 0, 223, 224, + 225, 226, 227, 0, 0, 228, 229, 230, 231, 232, + 0, 233, 234, 235, 236, 237, 0, 0, 0, 238, + 239, 240, 241, 0, 242, 243, 0, 244, 245, 246, + 247, 248, 249, 0, 0, 250, 251, 0, 0, 0, + 0, 0, 0, 0, 252, 253, 254, 255, 256, 257, + 258, 259, 260, 1654, 261, 0, 262, 263, 264, 265, + 266, 0, 267, 268, 269, 0, 0, 270, 271, 272, + 273, 274, 0, 275, 276, 277, 0, 278, 279, 0, + 280, 281, 282, 283, 284, 285, 286, 287, 288, 1464, + 289, 0, 290, 291, 292, 0, 293, 0, 294, 0, + 0, 0, 295, 296, 297, 0, 298, 299, 0, 300, + 0, 301, 302, 303, 304, 305, 0, 306, 307, 308, + 0, 309, 310, 311, 312, 313, 314, 0, 315, 0, + 316, 317, 318, 319, 320, 321, 322, 0, 323, 0, + 324, 0, 0, 325, 0, 326, 327, 328, 329, 330, + 331, 332, 0, 333, 334, 0, 335, 0, 0, 336, + 337, 338, 0, 0, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 351, 0, 352, 353, + 354, 355, 0, 356, 357, 0, 358, 0, 359, 360, + 361, 362, 363, 364, 0, 365, 1465, 0, 366, 367, + 368, 0, 0, 369, 0, 0, 0, 370, 371, 372, + 373, 374, 375, 376, 377, 0, 378, 379, 380, 381, + 382, 383, 384, 0, 385, 386, 387, 388, 389, 390, + 391, 392, 393, 394, 395, 396, 0, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 0, 407, 408, + 0, 409, 410, 411, 412, 413, 414, 415, 416, 417, + 418, 419, 0, 420, 421, 422, 423, 424, 0, 425, + 426, 427, 428, 0, 429, 430, 431, 0, 432, 433, + 434, 435, 436, 437, 438, 439, 440, 441, 442, 0, + 443, 444, 0, 445, 446, 447, 448, 449, 450, 0, + 451, 452, 0, 0, 453, 454, 455, 456, 1466, 457, + 458, 459, 460, 461, 462, 463, 0, 0, 464, 465, + 466, 467, 468, 0, 0, 469, 470, 471, 472, 473, + 474, 475, 0, 476, 0, 477, 478, 479, 0, 0, + 480, 0, 0, 481, 482, 483, 484, 485, 486, 487, + 488, 489, 490, 491, 492, 493, 494, 495, 496, 497, + 199, 1231, 550, 0, 0, 0, 597, 609, 1232, 0, + 0, 200, 201, 202, 203, 204, 205, 206, 207, 0, + 209, 210, 211, 0, 0, 0, 0, 0, 0, 0, + 212, 213, 0, 214, 215, 0, 216, 217, 218, 219, + 220, 0, 221, 222, 0, 223, 224, 225, 226, 227, + 0, 0, 228, 229, 230, 231, 232, 0, 233, 234, + 235, 236, 237, 0, 0, 0, 238, 239, 240, 241, + 0, 242, 243, 0, 244, 245, 246, 247, 248, 249, + 0, 0, 250, 251, 0, 0, 0, 0, 0, 0, + 0, 252, 253, 254, 255, 256, 257, 258, 259, 260, + 1659, 261, 0, 262, 263, 264, 265, 266, 0, 267, + 268, 269, 0, 0, 270, 271, 272, 273, 274, 0, + 275, 276, 277, 0, 278, 279, 0, 280, 281, 282, + 283, 284, 285, 286, 287, 288, 1464, 289, 0, 290, + 291, 292, 0, 293, 0, 294, 0, 0, 0, 295, + 296, 297, 0, 298, 299, 0, 300, 0, 301, 302, + 303, 304, 305, 0, 306, 307, 308, 0, 309, 310, + 311, 312, 313, 314, 0, 315, 0, 316, 317, 318, + 319, 320, 321, 322, 0, 323, 0, 324, 0, 0, + 325, 0, 326, 327, 328, 329, 330, 331, 332, 0, + 333, 334, 0, 335, 0, 0, 336, 337, 338, 0, + 0, 339, 340, 341, 342, 343, 344, 345, 346, 347, + 348, 349, 350, 351, 0, 352, 353, 354, 355, 0, + 356, 357, 0, 358, 0, 359, 360, 361, 362, 363, + 364, 0, 365, 1465, 0, 366, 367, 368, 0, 0, + 369, 0, 0, 0, 370, 371, 372, 373, 374, 375, + 376, 377, 0, 378, 379, 380, 381, 382, 383, 384, + 0, 385, 386, 387, 388, 389, 390, 391, 392, 393, + 394, 395, 396, 0, 397, 398, 399, 400, 401, 402, + 403, 404, 405, 406, 0, 407, 408, 0, 409, 410, + 411, 412, 413, 414, 415, 416, 417, 418, 419, 0, + 420, 421, 422, 423, 424, 0, 425, 426, 427, 428, + 0, 429, 430, 431, 0, 432, 433, 434, 435, 436, + 437, 438, 439, 440, 441, 442, 0, 443, 444, 0, + 445, 446, 447, 448, 449, 450, 0, 451, 452, 0, + 0, 453, 454, 455, 456, 1466, 457, 458, 459, 460, + 461, 462, 463, 0, 0, 464, 465, 466, 467, 468, + 0, 0, 469, 470, 471, 472, 473, 474, 475, 0, + 476, 0, 477, 478, 479, 0, 0, 480, 0, 0, + 481, 482, 483, 484, 485, 486, 487, 488, 489, 490, + 491, 492, 493, 494, 495, 496, 497, 199, 1231, 550, + 0, 0, 0, 597, 609, 1232, 0, 0, 200, 201, + 202, 203, 204, 205, 206, 207, 0, 209, 210, 211, + 0, 0, 0, 0, 0, 0, 0, 212, 213, 0, + 214, 215, 0, 216, 217, 218, 219, 220, 0, 221, + 222, 0, 223, 224, 225, 226, 227, 0, 0, 228, + 229, 230, 231, 232, 0, 233, 234, 235, 236, 237, + 0, 0, 0, 238, 239, 240, 241, 0, 242, 243, + 0, 244, 245, 246, 247, 248, 249, 0, 0, 250, + 251, 0, 0, 0, 0, 0, 0, 0, 252, 253, + 254, 255, 256, 257, 258, 259, 260, 0, 261, 0, + 262, 263, 264, 265, 266, 0, 267, 268, 269, 0, + 0, 270, 271, 272, 273, 274, 0, 275, 276, 277, + 0, 278, 279, 0, 280, 281, 282, 283, 284, 285, + 286, 287, 288, 1464, 289, 0, 290, 291, 292, 0, + 293, 0, 294, 0, 0, 0, 295, 296, 297, 0, + 298, 299, 0, 300, 0, 301, 302, 303, 304, 305, + 0, 306, 307, 308, 0, 309, 310, 311, 312, 313, + 314, 0, 315, 0, 316, 317, 318, 319, 320, 321, + 322, 0, 323, 0, 324, 0, 0, 325, 0, 326, + 327, 328, 329, 330, 331, 332, 0, 333, 334, 0, + 335, 0, 0, 336, 337, 338, 0, 0, 339, 340, + 341, 342, 343, 344, 345, 346, 347, 348, 349, 350, + 351, 0, 352, 353, 354, 355, 0, 356, 357, 0, + 358, 0, 359, 360, 361, 362, 363, 364, 0, 365, + 1465, 0, 366, 367, 368, 0, 0, 369, 0, 0, + 0, 370, 371, 372, 373, 374, 375, 376, 377, 0, + 378, 379, 380, 381, 382, 383, 384, 0, 385, 386, + 387, 388, 389, 390, 391, 392, 393, 394, 395, 396, + 0, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 0, 407, 408, 0, 409, 410, 411, 412, 413, + 414, 415, 416, 417, 418, 419, 0, 420, 421, 422, + 423, 424, 0, 425, 426, 427, 428, 0, 429, 430, + 431, 0, 432, 433, 434, 435, 436, 437, 438, 439, + 440, 441, 442, 0, 443, 444, 0, 445, 446, 447, + 448, 449, 450, 0, 451, 452, 0, 0, 453, 454, + 455, 456, 1466, 457, 458, 459, 460, 461, 462, 463, + 0, 0, 464, 465, 466, 467, 468, 0, 0, 469, + 470, 471, 472, 473, 474, 475, 0, 476, 0, 477, + 478, 479, 0, 0, 480, 0, 0, 481, 482, 483, + 484, 485, 486, 487, 488, 489, 490, 491, 492, 493, + 494, 495, 496, 497, 199, 0, 0, 0, 0, 0, + 597, 609, 1232, 0, 0, 200, 598, 202, 203, 204, + 205, 206, 207, 599, 209, 210, 211, 0, 0, 0, + 0, 0, 0, 0, 212, 213, 0, 214, 215, 0, + 600, 217, 218, 219, 220, 0, 221, 222, 0, 223, + 224, 225, 226, 227, 0, 0, 228, 229, 230, 231, + 232, 0, 233, 234, 235, 236, 237, 0, 0, 0, + 238, 239, 240, 241, 0, 242, 243, 0, 244, 245, + 246, 247, 248, 249, 0, 0, 250, 251, 0, 0, + 0, 0, 0, 0, 0, 252, 253, 254, 255, 256, + 257, 258, 259, 260, 0, 261, 0, 262, 263, 264, + 265, 266, 0, 267, 268, 269, 0, 0, 270, 271, + 272, 273, 274, 0, 275, 276, 277, 0, 278, 279, + 0, 280, 281, 282, 283, 284, 285, 286, 287, 288, + 0, 289, 0, 601, 291, 292, 0, 293, 0, 602, + 0, 603, 0, 295, 296, 297, 0, 298, 299, 0, + 300, 0, 301, 302, 303, 304, 305, 0, 306, 307, + 308, 604, 309, 310, 311, 312, 313, 314, 0, 315, + 0, 316, 317, 318, 319, 320, 321, 322, 0, 323, + 0, 324, 0, 0, 325, 0, 326, 327, 328, 329, + 605, 331, 332, 0, 333, 334, 0, 335, 0, 0, + 336, 337, 338, 0, 0, 339, 340, 341, 342, 343, + 344, 345, 346, 347, 348, 349, 350, 351, 0, 352, + 606, 354, 355, 0, 356, 357, 0, 358, 0, 359, + 360, 361, 362, 363, 364, 0, 365, 0, 0, 366, + 367, 368, 0, 0, 369, 0, 0, 0, 370, 371, + 372, 373, 374, 375, 376, 377, 0, 378, 379, 380, + 381, 382, 383, 384, 0, 607, 386, 387, 388, 389, + 390, 391, 392, 393, 394, 395, 396, 0, 397, 608, + 399, 400, 401, 402, 403, 404, 405, 406, 0, 407, + 408, 0, 409, 410, 411, 412, 413, 414, 415, 416, + 417, 418, 419, 0, 420, 421, 422, 423, 424, 0, + 425, 426, 427, 428, 0, 429, 430, 431, 0, 432, + 433, 434, 435, 436, 437, 438, 439, 440, 441, 442, + 0, 443, 444, 0, 445, 446, 447, 448, 449, 450, + 0, 451, 452, 0, 0, 453, 454, 455, 456, 0, + 457, 458, 459, 460, 461, 462, 463, 0, 0, 464, + 465, 466, 467, 468, 0, 0, 469, 470, 471, 472, + 473, 474, 475, 0, 476, 0, 477, 478, 479, 0, + 0, 480, 0, 0, 481, 482, 483, 484, 485, 486, + 487, 488, 489, 490, 491, 492, 493, 494, 495, 496, + 497, 1664, 4262, 550, 0, 0, 0, 597, 609, 610, + 0, 0, 200, 201, 202, 203, 204, 205, 206, 207, + 1665, 209, 210, 211, 1666, 1667, 1668, 1669, 1670, 1671, + 1672, 212, 213, 1673, 214, 215, 713, 216, 217, 218, + 219, 220, 714, 221, 222, 1674, 223, 224, 225, 226, + 227, 1675, 1676, 228, 229, 230, 231, 232, 1677, 233, + 234, 235, 236, 237, 1678, 715, 1679, 238, 239, 240, + 241, 716, 242, 243, 1680, 244, 245, 246, 247, 248, + 249, 1681, 717, 250, 251, 1682, 1683, 1684, 718, 1685, + 1686, 1687, 252, 253, 254, 255, 256, 257, 258, 259, + 260, 1688, 261, 1689, 262, 263, 264, 265, 266, 1690, + 267, 268, 269, 1691, 1692, 270, 271, 272, 273, 274, + 1693, 275, 276, 277, 1694, 278, 279, 1695, 280, 281, + 282, 283, 284, 285, 286, 287, 288, 1696, 289, 1697, + 290, 291, 292, 1698, 293, 1699, 294, 719, 1700, 720, + 295, 296, 297, 1701, 298, 299, 1702, 300, 1703, 301, + 302, 303, 304, 305, 721, 306, 307, 308, 1704, 309, + 310, 311, 312, 313, 314, 1705, 315, 722, 316, 317, + 318, 319, 320, 321, 322, 1706, 323, 1707, 324, 723, + 724, 325, 725, 326, 327, 328, 329, 330, 331, 332, + 1708, 333, 334, 726, 335, 727, 1709, 336, 337, 338, + 1710, 1711, 339, 340, 341, 342, 343, 344, 345, 346, + 347, 348, 349, 350, 351, 728, 352, 353, 354, 355, + 1712, 356, 357, 729, 358, 1713, 359, 360, 361, 362, + 363, 364, 1714, 365, 1715, 1716, 366, 367, 368, 1717, + 1718, 369, 730, 731, 732, 370, 371, 372, 373, 374, + 375, 376, 377, 1719, 378, 379, 380, 381, 382, 383, + 384, 1720, 385, 386, 387, 388, 389, 390, 391, 392, + 393, 394, 395, 396, 1721, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 1722, 407, 408, 733, 409, + 410, 411, 412, 413, 414, 415, 416, 417, 418, 419, + 1723, 420, 421, 422, 423, 424, 1724, 425, 426, 427, + 428, 734, 429, 430, 431, 1725, 432, 433, 434, 435, + 436, 437, 438, 439, 440, 441, 442, 1726, 443, 444, + 1727, 445, 446, 447, 448, 449, 450, 1728, 451, 452, + 1729, 1730, 453, 454, 455, 456, 1731, 457, 458, 459, + 460, 461, 462, 463, 1732, 1733, 464, 465, 466, 467, + 468, 1734, 1735, 469, 470, 471, 472, 473, 474, 475, + 1736, 476, 735, 477, 478, 479, 1737, 1738, 480, 1739, + 1740, 481, 482, 483, 484, 485, 486, 487, 488, 489, + 490, 491, 492, 493, 494, 495, 496, 497, 1664, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 200, + 201, 202, 203, 204, 205, 206, 207, 1665, 209, 210, + 211, 1666, 1667, 1668, 1669, 1670, 1671, 1672, 212, 213, + 1673, 214, 215, 713, 216, 217, 218, 219, 220, 714, + 221, 222, 1674, 223, 224, 225, 226, 227, 1675, 1676, + 228, 229, 230, 231, 232, 1677, 233, 234, 235, 236, + 237, 1678, 715, 1679, 238, 239, 240, 241, 716, 242, + 243, 1680, 244, 245, 246, 247, 248, 249, 1681, 717, + 250, 251, 1682, 1683, 1684, 718, 1685, 1686, 1687, 252, + 253, 254, 255, 256, 257, 258, 259, 260, 1688, 261, + 1689, 262, 263, 264, 265, 266, 1690, 267, 268, 269, + 1691, 1692, 270, 271, 272, 273, 274, 1693, 275, 276, + 277, 1694, 278, 279, 1695, 280, 281, 282, 283, 284, + 285, 286, 287, 288, 1696, 289, 1697, 290, 291, 292, + 1698, 293, 1699, 294, 719, 1700, 720, 295, 296, 297, + 1701, 298, 299, 1702, 300, 1703, 301, 302, 303, 304, + 305, 721, 306, 307, 308, 1704, 309, 310, 311, 312, + 313, 314, 1705, 315, 722, 316, 317, 318, 319, 320, + 321, 322, 1706, 323, 1707, 324, 723, 724, 325, 725, + 326, 327, 328, 329, 330, 331, 332, 1708, 333, 334, + 726, 335, 727, 1709, 336, 337, 338, 1710, 1711, 339, + 340, 341, 342, 343, 344, 345, 346, 347, 348, 349, + 350, 351, 728, 352, 353, 354, 355, 1712, 356, 357, + 729, 358, 1713, 359, 360, 361, 362, 363, 364, 1714, + 365, 1715, 1716, 366, 367, 368, 1717, 1718, 369, 730, + 731, 732, 370, 371, 372, 373, 374, 375, 376, 377, + 1719, 378, 379, 380, 381, 382, 383, 384, 1720, 385, + 386, 387, 388, 389, 390, 391, 392, 393, 394, 395, + 396, 1721, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 1722, 407, 408, 733, 409, 410, 411, 412, + 413, 414, 415, 416, 417, 418, 419, 1723, 420, 421, + 422, 423, 424, 1724, 425, 426, 427, 428, 734, 429, + 430, 431, 1725, 432, 433, 434, 435, 436, 437, 438, + 439, 440, 441, 442, 1726, 443, 444, 1727, 445, 446, + 447, 448, 449, 450, 1728, 451, 452, 1729, 1730, 453, + 454, 455, 456, 1731, 457, 458, 459, 460, 461, 462, + 463, 1732, 1733, 464, 465, 466, 467, 468, 1734, 1735, + 469, 470, 471, 472, 473, 474, 475, 1736, 476, 735, + 477, 478, 479, 1737, 1738, 480, 1739, 1740, 481, 482, + 483, 484, 485, 486, 487, 488, 489, 490, 491, 492, + 493, 494, 495, 496, 497, 1664, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 200, 201, 202, 203, + 2530, 205, 206, 207, 1665, 209, 210, 211, 1666, 1667, + 1668, 1669, 1670, 1671, 1672, 212, 213, 1673, 214, 215, + 713, 216, 217, 218, 219, 220, 714, 221, 222, 1674, + 223, 224, 225, 226, 227, 1675, 1676, 228, 229, 230, + 231, 232, 1677, 233, 234, 235, 236, 237, 1678, 715, + 1679, 238, 239, 240, 241, 716, 242, 243, 1680, 244, + 245, 246, 247, 248, 249, 1681, 717, 250, 251, 1682, + 1683, 1684, 718, 1685, 1686, 1687, 252, 253, 254, 255, + 256, 257, 258, 259, 260, 1688, 261, 1689, 262, 263, + 264, 265, 266, 1690, 267, 268, 269, 1691, 1692, 270, + 271, 272, 2531, 274, 1693, 275, 276, 277, 1694, 278, + 279, 1695, 280, 281, 282, 283, 284, 285, 286, 287, + 288, 1696, 289, 1697, 290, 291, 292, 1698, 293, 1699, + 294, 719, 1700, 720, 295, 296, 297, 1701, 298, 299, + 1702, 300, 1703, 301, 302, 303, 304, 305, 721, 306, + 307, 308, 1704, 309, 310, 311, 312, 313, 314, 1705, + 315, 722, 316, 317, 318, 319, 320, 321, 322, 1706, + 323, 1707, 324, 723, 724, 325, 725, 326, 327, 328, + 329, 330, 331, 332, 1708, 333, 334, 726, 335, 727, + 1709, 336, 337, 338, 1710, 1711, 339, 340, 341, 342, + 343, 344, 345, 346, 347, 348, 349, 350, 351, 728, + 352, 353, 354, 355, 1712, 356, 357, 729, 358, 1713, + 359, 360, 361, 362, 363, 364, 1714, 365, 1715, 1716, + 366, 367, 368, 1717, 1718, 369, 730, 731, 732, 370, + 371, 372, 373, 374, 375, 376, 377, 1719, 378, 379, + 380, 381, 382, 383, 384, 1720, 385, 386, 387, 388, + 389, 390, 391, 392, 393, 394, 395, 396, 1721, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 1722, + 407, 408, 733, 409, 410, 411, 412, 413, 414, 415, + 416, 417, 418, 419, 1723, 420, 421, 422, 423, 424, + 1724, 2532, 426, 427, 428, 734, 429, 430, 431, 1725, + 432, 433, 434, 435, 436, 437, 438, 439, 440, 441, + 442, 1726, 443, 444, 1727, 445, 446, 447, 448, 449, + 450, 1728, 451, 452, 1729, 1730, 453, 454, 455, 456, + 1731, 457, 458, 459, 460, 461, 462, 463, 1732, 1733, + 464, 465, 466, 467, 468, 1734, 1735, 469, 470, 471, + 472, 473, 474, 475, 1736, 476, 735, 477, 478, 479, + 1737, 1738, 480, 1739, 1740, 481, 482, 483, 484, 485, + 486, 487, 488, 489, 490, 491, 492, 493, 494, 495, + 496, 497, 712, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 200, 201, 202, 203, 204, 205, 206, + 207, 0, 209, 210, 211, 0, 0, 0, 0, 0, + 0, 0, 212, 213, 0, 214, 215, 713, 216, 217, + 218, 219, 220, 714, 221, 222, 0, 223, 224, 225, + 226, 227, 0, 0, 228, 229, 230, 231, 232, 0, + 233, 234, 235, 236, 237, 0, 715, 0, 238, 239, + 240, 241, 716, 242, 243, 0, 244, 245, 246, 247, + 248, 249, 0, 717, 250, 251, 0, 0, 0, 718, + 0, 0, 0, 252, 253, 254, 255, 256, 257, 258, + 259, 260, 0, 261, 0, 262, 263, 264, 265, 266, + 0, 267, 268, 269, 0, 0, 270, 271, 272, 273, + 274, 0, 275, 276, 277, 0, 278, 279, 0, 280, + 281, 282, 283, 284, 285, 286, 287, 288, 0, 289, + 0, 290, 291, 292, 0, 293, 0, 294, 719, 0, + 720, 295, 296, 297, 0, 298, 299, 0, 300, 0, + 301, 302, 303, 304, 305, 721, 306, 307, 308, 0, + 309, 310, 311, 312, 313, 314, 0, 315, 722, 316, + 317, 318, 319, 320, 321, 322, 0, 323, 0, 324, + 723, 724, 325, 725, 326, 327, 328, 329, 330, 331, + 332, 0, 333, 334, 726, 335, 727, 0, 336, 337, + 338, 0, 0, 339, 340, 341, 342, 343, 344, 345, + 346, 347, 348, 349, 350, 351, 728, 352, 353, 354, + 355, 0, 356, 357, 729, 358, 0, 359, 360, 361, + 362, 363, 364, 0, 365, 0, 0, 366, 367, 368, + 0, 0, 369, 730, 731, 732, 370, 371, 372, 373, + 374, 375, 376, 377, 0, 378, 379, 380, 381, 382, + 383, 384, 0, 385, 386, 387, 388, 389, 390, 391, + 392, 393, 394, 395, 396, 0, 397, 398, 399, 400, + 401, 402, 403, 404, 405, 406, 0, 407, 408, 733, + 409, 410, 411, 412, 413, 414, 415, 416, 417, 418, + 419, 0, 420, 421, 422, 423, 424, 0, 425, 426, + 427, 428, 734, 429, 430, 431, 0, 432, 433, 434, + 435, 436, 437, 438, 439, 440, 441, 442, 0, 443, + 444, 0, 445, 446, 447, 448, 449, 450, 0, 451, + 452, 0, 0, 453, 454, 455, 456, 0, 457, 458, + 459, 460, 461, 462, 463, 0, 0, 464, 465, 466, + 467, 468, 0, 0, 469, 470, 471, 472, 473, 474, + 475, 0, 476, 735, 477, 478, 479, 0, 0, 480, + 0, 0, 481, 482, 483, 484, 485, 486, 487, 488, + 489, 490, 491, 492, 493, 494, 495, 496, 497, 712, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 0, 0, 0, 212, + 213, 0, 214, 215, 713, 216, 217, 218, 219, 220, + 714, 221, 222, 0, 223, 224, 225, 226, 227, 0, + 0, 228, 229, 230, 231, 232, 0, 233, 234, 235, + 236, 237, 0, 715, 0, 238, 239, 240, 241, 716, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 0, + 717, 250, 251, 0, 0, 0, 718, 0, 0, 0, + 252, 253, 254, 255, 256, 257, 258, 259, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 272, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 284, 285, 286, 287, 288, 0, 289, 0, 290, 291, + 292, 0, 293, 0, 294, 719, 0, 720, 295, 296, + 297, 0, 298, 299, 0, 300, 0, 301, 302, 303, + 304, 878, 721, 306, 307, 308, 0, 309, 310, 311, + 312, 313, 314, 0, 315, 722, 316, 317, 318, 319, + 320, 321, 322, 0, 323, 0, 324, 723, 724, 325, + 725, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 334, 726, 335, 727, 0, 336, 337, 338, 0, 0, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 351, 728, 352, 353, 354, 355, 0, 356, + 357, 729, 358, 0, 359, 360, 361, 362, 363, 364, + 0, 365, 0, 0, 366, 367, 368, 0, 0, 369, + 730, 731, 732, 370, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 379, 380, 381, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 733, 409, 410, 411, + 412, 413, 414, 415, 416, 417, 418, 419, 0, 420, + 421, 422, 423, 424, 0, 425, 426, 427, 428, 734, + 429, 430, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 442, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 451, 452, 0, 0, + 453, 454, 455, 456, 0, 457, 458, 459, 460, 461, + 462, 463, 0, 0, 464, 465, 466, 467, 468, 0, + 0, 469, 470, 471, 472, 473, 474, 475, 0, 476, + 735, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 485, 486, 487, 488, 489, 490, 491, + 492, 493, 494, 495, 496, 497, 712, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 200, 201, 202, + 203, 204, 205, 206, 207, 0, 209, 210, 211, 0, + 0, 0, 0, 0, 0, 0, 212, 213, 0, 214, + 215, 713, 216, 217, 218, 219, 220, 714, 221, 222, + 0, 223, 224, 225, 226, 227, 0, 0, 228, 229, + 230, 231, 232, 0, 233, 234, 235, 236, 237, 0, + 715, 0, 238, 239, 240, 241, 716, 242, 243, 0, + 244, 245, 246, 247, 248, 249, 0, 717, 250, 251, + 0, 0, 0, 718, 0, 0, 0, 252, 253, 254, + 255, 256, 257, 258, 259, 260, 0, 261, 0, 262, + 263, 264, 265, 266, 0, 267, 268, 269, 0, 0, + 270, 271, 272, 273, 274, 0, 275, 276, 277, 0, + 278, 279, 0, 280, 281, 282, 283, 284, 285, 286, + 287, 288, 0, 289, 0, 290, 291, 292, 0, 293, + 0, 294, 719, 0, 720, 295, 296, 297, 0, 298, + 299, 0, 300, 0, 301, 302, 303, 304, 887, 721, + 306, 307, 308, 0, 309, 310, 311, 312, 313, 314, + 0, 315, 722, 316, 317, 318, 319, 320, 321, 322, + 0, 323, 0, 324, 723, 724, 325, 725, 326, 327, + 328, 329, 330, 331, 332, 0, 333, 334, 726, 335, + 727, 0, 336, 337, 338, 0, 0, 339, 340, 341, + 342, 343, 344, 345, 346, 347, 348, 349, 350, 351, + 728, 352, 353, 354, 355, 0, 356, 357, 729, 358, + 0, 359, 360, 361, 362, 363, 364, 0, 365, 0, + 0, 366, 367, 368, 0, 0, 369, 730, 731, 732, + 370, 371, 372, 373, 374, 375, 376, 377, 0, 378, + 379, 380, 381, 382, 383, 384, 0, 385, 386, 387, + 388, 389, 390, 391, 392, 393, 394, 395, 396, 0, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 0, 407, 408, 733, 409, 410, 411, 412, 413, 414, + 415, 416, 417, 418, 419, 0, 420, 421, 422, 423, + 424, 0, 425, 426, 427, 428, 734, 429, 430, 431, + 0, 432, 433, 434, 435, 436, 437, 438, 439, 440, + 441, 442, 0, 443, 444, 0, 445, 446, 447, 448, + 449, 450, 0, 451, 452, 0, 0, 453, 454, 455, + 456, 0, 457, 458, 459, 460, 461, 462, 463, 0, + 0, 464, 465, 466, 467, 468, 0, 0, 469, 470, + 471, 472, 473, 474, 475, 0, 476, 735, 477, 478, + 479, 0, 0, 480, 0, 0, 481, 482, 483, 484, + 485, 486, 487, 488, 489, 490, 491, 492, 493, 494, + 495, 496, 497, 199, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 200, 201, 202, 203, 204, 205, + 206, 207, 0, 209, 210, 211, 0, 0, 0, 0, + 0, 0, 0, 212, 213, 0, 214, 215, 0, 216, + 217, 218, 219, 220, 0, 221, 222, 0, 223, 224, + 225, 226, 227, 0, 0, 228, 229, 230, 231, 232, + 1819, 233, 234, 235, 236, 237, 0, 0, 1894, 238, + 239, 240, 241, 0, 242, 243, 1820, 244, 245, 246, + 247, 248, 249, 0, 0, 250, 251, 0, 0, 0, + 0, 0, 0, 0, 252, 253, 254, 255, 256, 257, + 258, 259, 260, 0, 261, 0, 262, 263, 264, 265, + 266, 0, 267, 268, 269, 0, 0, 270, 271, 272, + 273, 274, 0, 275, 276, 277, 0, 278, 279, 0, + 1895, 281, 282, 283, 284, 285, 286, 287, 288, 0, + 289, 0, 290, 291, 292, 0, 293, 1822, 294, 0, + 0, 0, 295, 296, 297, 0, 298, 299, 0, 300, + 0, 301, 302, 303, 304, 305, 0, 306, 307, 308, + 0, 309, 310, 311, 312, 313, 314, 0, 315, 0, + 316, 317, 318, 319, 320, 321, 322, 0, 323, 0, + 324, 0, 0, 325, 0, 326, 327, 328, 329, 330, + 331, 332, 0, 333, 334, 0, 335, 0, 0, 336, + 337, 338, 0, 0, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 351, 0, 352, 353, + 354, 355, 0, 356, 357, 0, 358, 0, 359, 360, + 361, 362, 363, 364, 0, 365, 0, 0, 366, 367, + 368, 0, 0, 369, 0, 0, 0, 370, 371, 372, + 373, 374, 375, 376, 377, 0, 378, 379, 380, 381, + 382, 383, 384, 1823, 385, 386, 387, 388, 389, 390, + 391, 392, 393, 394, 395, 396, 0, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 0, 407, 408, + 0, 409, 410, 411, 412, 413, 414, 415, 416, 417, + 418, 419, 0, 420, 421, 422, 423, 424, 0, 425, + 426, 427, 428, 0, 429, 430, 431, 0, 432, 433, + 434, 435, 436, 437, 438, 439, 440, 441, 442, 0, + 443, 444, 0, 445, 446, 447, 448, 449, 450, 0, + 451, 452, 0, 0, 453, 454, 455, 456, 0, 457, + 458, 459, 460, 461, 462, 463, 0, 1824, 464, 465, + 466, 467, 468, 0, 0, 469, 470, 471, 472, 473, + 474, 475, 0, 476, 0, 477, 478, 479, 0, 0, + 480, 0, 0, 481, 482, 483, 484, 485, 486, 487, + 488, 489, 490, 491, 492, 493, 494, 495, 496, 497, + 199, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 200, 201, 202, 203, 204, 205, 206, 207, 0, + 209, 210, 211, 0, 0, 0, 0, 0, 0, 0, + 212, 213, 0, 214, 215, 0, 216, 217, 218, 219, + 220, 0, 221, 222, 0, 223, 224, 225, 226, 227, + 0, 0, 228, 229, 230, 231, 232, 1819, 233, 234, + 235, 236, 237, 0, 0, 0, 238, 239, 240, 241, + 0, 242, 243, 1820, 244, 245, 246, 247, 248, 249, + 0, 0, 250, 251, 0, 0, 0, 0, 0, 0, + 0, 252, 253, 254, 255, 256, 257, 258, 259, 260, + 0, 261, 0, 262, 263, 264, 265, 266, 0, 267, + 268, 269, 0, 0, 270, 271, 272, 273, 274, 0, + 275, 276, 277, 0, 278, 279, 0, 1895, 281, 282, + 283, 284, 285, 286, 287, 288, 0, 289, 0, 290, + 291, 292, 0, 293, 1822, 294, 0, 0, 0, 295, + 296, 297, 0, 298, 299, 0, 300, 0, 301, 302, + 303, 304, 305, 0, 306, 307, 308, 0, 309, 310, + 311, 312, 313, 314, 0, 315, 0, 316, 317, 318, + 319, 320, 321, 322, 0, 323, 0, 324, 0, 0, + 325, 0, 326, 327, 328, 329, 330, 331, 332, 0, + 333, 334, 0, 335, 2731, 0, 336, 337, 338, 0, + 0, 339, 340, 341, 342, 343, 344, 345, 346, 347, + 348, 349, 350, 351, 0, 352, 353, 354, 355, 0, + 356, 357, 0, 358, 0, 359, 360, 361, 362, 363, + 364, 0, 365, 0, 0, 366, 367, 368, 0, 0, + 369, 0, 0, 0, 370, 371, 372, 373, 374, 375, + 376, 377, 0, 378, 379, 380, 381, 382, 383, 384, + 1823, 385, 386, 387, 388, 389, 390, 391, 392, 393, + 394, 395, 396, 0, 397, 398, 399, 400, 401, 402, + 403, 404, 405, 406, 0, 407, 408, 0, 409, 410, + 411, 412, 413, 414, 415, 416, 417, 418, 419, 0, + 420, 421, 422, 423, 424, 0, 425, 426, 427, 428, + 0, 429, 430, 431, 0, 432, 433, 434, 435, 436, + 437, 438, 439, 440, 441, 442, 0, 443, 444, 0, + 445, 446, 447, 448, 449, 450, 0, 451, 452, 0, + 0, 453, 454, 455, 456, 0, 457, 458, 459, 460, + 461, 462, 463, 0, 1824, 464, 465, 466, 467, 468, + 0, 0, 469, 470, 471, 472, 473, 474, 475, 0, + 476, 0, 477, 478, 479, 0, 0, 480, 0, 0, + 481, 482, 483, 484, 485, 486, 487, 488, 489, 490, + 491, 492, 493, 494, 495, 496, 497, 199, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 200, 201, + 202, 203, 204, 647, 206, 207, 616, 209, 210, 211, + 0, 0, 0, 0, 0, 0, 0, 212, 213, 0, + 214, 215, 0, 216, 217, 218, 219, 220, 0, 221, + 222, 0, 223, 224, 225, 226, 227, 0, 0, 228, + 229, 230, 231, 232, 0, 233, 234, 235, 236, 237, + 0, 0, 0, 238, 239, 240, 241, 0, 242, 243, + 0, 244, 245, 246, 247, 248, 249, 617, 0, 250, + 251, 0, 0, 0, 0, 0, 0, 0, 252, 253, + 254, 255, 256, 257, 258, 259, 260, 0, 261, 0, + 262, 263, 264, 265, 266, 0, 267, 268, 269, 0, + 0, 270, 271, 272, 273, 274, 0, 275, 276, 277, + 0, 278, 279, 0, 280, 281, 282, 283, 284, 285, + 286, 287, 288, 0, 289, 0, 290, 291, 292, 0, + 293, 0, 294, 0, 0, 0, 295, 296, 297, 648, + 298, 299, 0, 300, 0, 301, 302, 303, 304, 305, + 0, 306, 307, 308, 0, 309, 310, 311, 312, 313, + 314, 0, 315, 0, 316, 317, 318, 319, 320, 321, + 322, 0, 323, 0, 324, 0, 0, 325, 0, 326, + 327, 328, 329, 330, 331, 332, 0, 333, 334, 0, + 335, 0, 0, 336, 337, 338, 0, 0, 339, 340, + 341, 342, 343, 344, 345, 346, 347, 348, 349, 350, + 351, 0, 352, 353, 354, 355, 0, 356, 357, 0, + 358, 0, 359, 360, 361, 362, 363, 364, 0, 365, + 0, 0, 366, 367, 368, 0, 0, 369, 0, 0, + 0, 370, 371, 372, 373, 374, 375, 376, 377, 0, + 378, 379, 380, 381, 382, 383, 384, 0, 385, 386, + 387, 388, 389, 390, 391, 392, 393, 394, 395, 396, + 618, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 0, 407, 408, 0, 409, 410, 411, 412, 413, + 414, 415, 416, 417, 418, 419, 619, 420, 421, 422, + 423, 424, 0, 425, 426, 427, 428, 0, 429, 430, + 431, 0, 432, 433, 434, 435, 436, 437, 438, 439, + 440, 441, 442, 0, 443, 444, 0, 445, 446, 447, + 448, 449, 450, 0, 451, 452, 0, 0, 453, 454, + 455, 456, 0, 457, 458, 459, 460, 461, 462, 463, + 0, 0, 464, 465, 466, 467, 468, 0, 0, 469, + 470, 471, 472, 473, 474, 475, 0, 476, 0, 477, + 478, 479, 0, 0, 480, 0, 0, 481, 482, 483, + 484, 485, 486, 487, 488, 489, 490, 491, 492, 493, + 494, 495, 496, 497, 199, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 200, 201, 202, 203, 204, + 205, 206, 207, 616, 209, 210, 211, 0, 0, 0, + 0, 0, 0, 0, 212, 213, 0, 214, 215, 0, + 216, 217, 218, 219, 220, 0, 221, 222, 0, 223, + 224, 225, 226, 227, 0, 0, 228, 229, 230, 231, + 232, 0, 233, 234, 235, 236, 237, 0, 0, 0, + 238, 239, 240, 241, 0, 242, 243, 0, 244, 245, + 246, 247, 248, 249, 617, 0, 250, 251, 0, 0, + 0, 0, 0, 0, 0, 252, 253, 254, 255, 256, + 257, 258, 259, 260, 0, 261, 0, 262, 263, 264, + 265, 266, 0, 267, 268, 269, 0, 0, 270, 271, + 272, 273, 274, 0, 275, 276, 277, 0, 278, 279, + 0, 280, 281, 282, 283, 284, 285, 286, 287, 288, + 0, 289, 0, 290, 291, 292, 0, 293, 0, 294, + 0, 0, 0, 295, 296, 297, 2433, 298, 299, 0, + 300, 0, 301, 302, 303, 304, 305, 0, 306, 307, + 308, 0, 309, 310, 311, 312, 313, 314, 0, 315, + 0, 316, 317, 318, 319, 320, 321, 322, 0, 323, + 0, 324, 0, 0, 325, 0, 326, 327, 328, 329, + 330, 331, 332, 0, 333, 334, 0, 335, 0, 0, + 336, 337, 338, 0, 0, 339, 340, 341, 342, 343, + 344, 345, 346, 347, 348, 349, 350, 351, 0, 352, + 353, 354, 355, 0, 356, 357, 0, 358, 0, 359, + 360, 361, 362, 363, 364, 0, 365, 0, 0, 366, + 367, 368, 0, 0, 369, 0, 0, 0, 370, 371, + 372, 373, 374, 375, 376, 377, 0, 378, 379, 380, + 381, 382, 383, 384, 0, 385, 386, 387, 388, 389, + 390, 391, 392, 393, 394, 395, 396, 618, 397, 398, + 399, 400, 401, 402, 403, 404, 405, 406, 0, 407, + 408, 0, 409, 410, 411, 412, 413, 414, 415, 416, + 417, 418, 419, 619, 420, 421, 422, 423, 424, 0, + 425, 426, 427, 428, 0, 429, 430, 431, 0, 432, + 433, 434, 435, 436, 437, 438, 439, 440, 441, 442, + 0, 443, 444, 0, 445, 446, 447, 448, 449, 450, + 0, 451, 452, 0, 0, 453, 454, 455, 456, 0, + 457, 458, 459, 460, 461, 462, 463, 0, 0, 464, + 465, 466, 467, 468, 0, 0, 469, 470, 471, 472, + 473, 474, 475, 0, 476, 0, 477, 478, 479, 0, + 0, 480, 0, 0, 481, 482, 483, 484, 485, 486, + 487, 488, 489, 490, 491, 492, 493, 494, 495, 496, + 497, 199, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 200, 201, 202, 203, 204, 205, 206, 207, + 0, 209, 210, 211, 0, 0, 0, 0, 0, 0, + 0, 212, 213, 0, 214, 215, 0, 216, 217, 218, + 219, 220, 0, 221, 222, 0, 223, 224, 225, 226, + 227, 0, 0, 228, 229, 230, 231, 232, 1819, 233, + 234, 235, 236, 237, 0, 0, 0, 238, 239, 240, + 241, 0, 242, 243, 1820, 244, 245, 246, 247, 248, + 249, 0, 0, 250, 251, 0, 0, 0, 0, 0, + 0, 0, 252, 253, 254, 255, 256, 257, 258, 259, + 260, 0, 261, 0, 262, 263, 264, 265, 266, 0, + 267, 268, 269, 0, 0, 270, 271, 272, 273, 274, + 0, 275, 276, 277, 0, 278, 279, 0, 1895, 281, + 282, 283, 284, 285, 286, 287, 288, 0, 289, 0, + 290, 291, 292, 0, 293, 1822, 294, 0, 0, 0, + 295, 296, 297, 0, 298, 299, 0, 300, 0, 301, + 302, 303, 304, 305, 0, 306, 307, 308, 0, 309, + 310, 311, 312, 313, 314, 0, 315, 0, 316, 317, + 318, 319, 320, 321, 322, 0, 323, 0, 324, 0, + 0, 325, 0, 326, 327, 328, 329, 330, 331, 332, + 0, 333, 334, 0, 335, 0, 0, 336, 337, 338, + 0, 0, 339, 340, 341, 342, 343, 344, 345, 346, + 347, 348, 349, 350, 351, 0, 352, 353, 354, 355, + 0, 356, 357, 0, 358, 0, 359, 360, 361, 362, + 363, 364, 0, 365, 0, 0, 366, 367, 368, 0, + 0, 369, 0, 0, 0, 370, 371, 372, 373, 374, + 375, 376, 377, 0, 378, 379, 380, 381, 382, 383, + 384, 1823, 385, 386, 387, 388, 389, 390, 391, 392, + 393, 394, 395, 396, 0, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 0, 407, 408, 0, 409, + 410, 411, 412, 413, 414, 415, 416, 417, 418, 419, + 0, 420, 421, 422, 423, 424, 0, 425, 426, 427, + 428, 0, 429, 430, 431, 0, 432, 433, 434, 435, + 436, 437, 438, 439, 440, 441, 442, 0, 443, 444, + 0, 445, 446, 447, 448, 449, 450, 0, 451, 452, + 0, 0, 453, 454, 455, 456, 0, 457, 458, 459, + 460, 461, 462, 463, 0, 1824, 464, 465, 466, 467, + 468, 0, 0, 469, 470, 471, 472, 473, 474, 475, + 0, 476, 0, 477, 478, 479, 0, 0, 480, 0, + 0, 481, 482, 483, 484, 485, 486, 487, 488, 489, + 490, 491, 492, 493, 494, 495, 496, 497, 199, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 200, + 201, 202, 203, 204, 205, 206, 207, 616, 209, 210, + 211, 0, 0, 0, 0, 0, 0, 0, 212, 213, + 0, 214, 215, 0, 216, 217, 218, 219, 220, 0, + 221, 222, 0, 223, 224, 225, 226, 227, 0, 0, + 228, 229, 230, 231, 232, 0, 233, 234, 235, 236, + 237, 0, 0, 0, 238, 239, 240, 241, 0, 242, + 243, 0, 244, 245, 246, 247, 248, 249, 617, 0, + 250, 251, 0, 0, 0, 0, 0, 0, 0, 252, + 253, 254, 255, 256, 257, 258, 259, 260, 0, 261, + 0, 262, 263, 264, 265, 266, 0, 267, 268, 269, + 0, 0, 270, 271, 272, 273, 274, 0, 275, 276, + 277, 0, 278, 279, 0, 280, 281, 282, 283, 284, + 285, 286, 287, 288, 0, 289, 0, 290, 291, 292, + 0, 293, 0, 294, 0, 0, 0, 295, 296, 297, + 0, 298, 299, 0, 300, 0, 301, 302, 303, 304, + 305, 0, 306, 307, 308, 0, 309, 310, 311, 312, + 313, 314, 0, 315, 0, 316, 317, 318, 319, 320, + 321, 322, 0, 323, 0, 324, 0, 0, 325, 0, + 326, 327, 328, 329, 330, 331, 332, 0, 333, 334, + 0, 335, 0, 0, 336, 337, 338, 0, 0, 339, + 340, 341, 342, 343, 344, 345, 346, 347, 348, 349, + 350, 351, 0, 352, 353, 354, 355, 0, 356, 357, + 0, 358, 0, 359, 360, 361, 362, 363, 364, 0, + 365, 0, 0, 366, 367, 368, 0, 0, 369, 0, + 0, 0, 370, 371, 372, 373, 374, 375, 376, 377, + 0, 378, 379, 380, 381, 382, 383, 384, 0, 385, + 386, 387, 388, 389, 390, 391, 392, 393, 394, 395, + 396, 618, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 0, 407, 408, 0, 409, 410, 411, 412, + 413, 414, 415, 416, 417, 418, 419, 619, 420, 421, + 422, 423, 424, 0, 425, 426, 427, 428, 0, 429, + 430, 431, 0, 432, 433, 434, 435, 436, 437, 438, + 439, 440, 441, 442, 0, 443, 444, 0, 445, 446, + 447, 448, 449, 450, 0, 451, 452, 0, 0, 453, + 454, 455, 456, 0, 457, 458, 459, 460, 461, 462, + 463, 0, 0, 464, 465, 466, 467, 468, 0, 0, + 469, 470, 471, 472, 473, 474, 475, 0, 476, 0, + 477, 478, 479, 0, 0, 480, 0, 0, 481, 482, + 483, 484, 485, 486, 487, 488, 489, 490, 491, 492, + 493, 494, 495, 496, 497, 199, 0, 550, 0, 0, + 0, 0, 0, 0, 0, 0, 200, 201, 202, 203, + 204, 205, 206, 207, 0, 209, 210, 211, 0, 0, + 0, 0, 0, 0, 0, 212, 213, 0, 214, 215, + 0, 216, 217, 218, 219, 220, 0, 221, 222, 0, + 223, 224, 225, 226, 227, 0, 0, 228, 229, 230, + 231, 232, 0, 233, 234, 235, 236, 237, 0, 0, + 0, 238, 239, 240, 241, 0, 242, 243, 0, 244, + 245, 246, 247, 248, 249, 0, 0, 250, 251, 0, + 0, 0, 0, 0, 0, 0, 252, 253, 254, 255, + 256, 257, 258, 259, 260, 0, 261, 0, 262, 263, + 264, 265, 266, 0, 267, 268, 269, 0, 0, 270, + 271, 272, 273, 274, 0, 275, 276, 277, 0, 278, + 279, 0, 280, 281, 282, 283, 284, 285, 286, 287, + 288, 1464, 289, 0, 290, 291, 292, 0, 293, 0, + 294, 0, 0, 0, 295, 296, 297, 0, 298, 299, + 0, 300, 0, 301, 302, 303, 304, 305, 0, 306, + 307, 308, 0, 309, 310, 311, 312, 313, 314, 0, + 315, 0, 316, 317, 318, 319, 320, 321, 322, 0, + 323, 0, 324, 0, 0, 325, 0, 326, 327, 328, + 329, 330, 331, 332, 0, 333, 334, 0, 335, 0, + 0, 336, 337, 338, 0, 0, 339, 340, 341, 342, + 343, 344, 345, 346, 347, 348, 349, 350, 351, 0, + 352, 353, 354, 355, 0, 356, 357, 0, 358, 0, + 359, 360, 361, 362, 363, 364, 0, 365, 1465, 0, + 366, 367, 368, 0, 0, 369, 0, 0, 0, 370, + 371, 372, 373, 374, 375, 376, 377, 0, 378, 379, + 380, 381, 382, 383, 384, 0, 385, 386, 387, 388, + 389, 390, 391, 392, 393, 394, 395, 396, 0, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 0, + 407, 408, 0, 409, 410, 411, 412, 413, 414, 415, + 416, 417, 418, 419, 0, 420, 421, 422, 423, 424, + 0, 425, 426, 427, 428, 0, 429, 430, 431, 0, + 432, 433, 434, 435, 436, 437, 438, 439, 440, 441, + 442, 0, 443, 444, 0, 445, 446, 447, 448, 449, + 450, 0, 451, 452, 0, 0, 453, 454, 455, 456, + 1466, 457, 458, 459, 460, 461, 462, 463, 0, 0, + 464, 465, 466, 467, 468, 0, 0, 469, 470, 471, + 472, 473, 474, 475, 0, 476, 0, 477, 478, 479, + 0, 0, 480, 0, 0, 481, 482, 483, 484, 485, + 486, 487, 488, 489, 490, 491, 492, 493, 494, 495, + 496, 497, 199, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 200, 201, 202, 203, 204, 205, 206, + 207, 1491, 209, 210, 211, 0, 0, 0, 0, 0, + 0, 0, 212, 213, 0, 214, 215, 0, 216, 217, + 218, 219, 220, 0, 221, 222, 0, 223, 224, 225, + 226, 227, 0, 0, 228, 229, 230, 231, 232, 0, + 233, 234, 235, 236, 237, 0, 0, 0, 238, 239, + 240, 241, 0, 242, 243, 0, 244, 245, 246, 247, + 248, 249, 0, 0, 250, 251, 0, 0, 0, 0, + 0, 0, 0, 252, 253, 254, 1492, 256, 257, 258, + 259, 260, 0, 261, 0, 262, 263, 264, 265, 266, + 0, 267, 268, 269, 0, 0, 270, 1493, 272, 273, + 274, 0, 275, 276, 277, 0, 278, 279, 0, 280, + 281, 282, 283, 284, 285, 286, 287, 288, 0, 289, + 0, 290, 291, 292, 0, 293, 1494, 294, 0, 0, + 0, 1495, 296, 297, 0, 298, 299, 0, 300, 0, + 301, 302, 303, 304, 305, 0, 306, 307, 308, 0, + 309, 310, 311, 312, 313, 314, 0, 315, 0, 316, + 317, 318, 319, 320, 321, 322, 0, 323, 0, 324, + 0, 0, 325, 0, 326, 327, 1496, 1497, 330, 331, + 332, 0, 333, 334, 0, 335, 0, 0, 336, 337, + 338, 0, 0, 339, 340, 341, 342, 343, 344, 345, + 346, 347, 348, 349, 350, 351, 0, 352, 353, 354, + 355, 0, 356, 357, 0, 358, 0, 359, 360, 361, + 362, 363, 364, 0, 365, 0, 0, 366, 367, 368, + 0, 0, 369, 0, 0, 0, 370, 371, 372, 373, + 374, 375, 376, 377, 0, 378, 379, 380, 381, 382, + 383, 384, 0, 385, 386, 387, 388, 389, 390, 391, + 392, 393, 394, 395, 396, 0, 397, 398, 399, 400, + 401, 402, 403, 404, 405, 406, 0, 407, 408, 0, + 409, 410, 411, 412, 413, 414, 1498, 416, 417, 418, + 419, 0, 1499, 421, 422, 423, 424, 0, 425, 426, + 427, 428, 0, 429, 430, 431, 0, 432, 433, 434, + 435, 436, 437, 438, 439, 440, 441, 442, 0, 443, + 444, 1500, 445, 1501, 447, 448, 449, 450, 0, 451, + 452, 0, 0, 453, 454, 455, 456, 0, 457, 458, + 1502, 460, 461, 462, 463, 0, 0, 464, 465, 466, + 467, 468, 0, 0, 469, 470, 471, 472, 473, 474, + 475, 0, 476, 0, 477, 478, 479, 0, 0, 480, + 0, 0, 481, 482, 483, 484, 485, 486, 487, 488, + 489, 490, 491, 492, 493, 494, 495, 496, 497, 199, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 0, 0, 0, 212, + 213, 0, 214, 215, 0, 216, 217, 218, 219, 220, + 0, 221, 222, 0, 223, 224, 225, 226, 227, 0, + 0, 228, 229, 230, 231, 232, 0, 233, 234, 235, + 236, 237, 0, 0, 0, 238, 239, 240, 241, 0, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 617, + 0, 250, 251, 0, 0, 0, 0, 0, 0, 0, + 252, 253, 254, 255, 256, 257, 258, 259, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 272, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 284, 285, 286, 287, 288, 0, 289, 0, 290, 291, + 292, 0, 293, 0, 294, 0, 0, 0, 295, 296, + 297, 0, 298, 299, 0, 300, 0, 301, 302, 303, + 304, 305, 0, 306, 307, 308, 0, 309, 310, 311, + 312, 313, 314, 0, 315, 0, 316, 317, 318, 319, + 320, 321, 322, 0, 323, 0, 324, 0, 0, 325, + 0, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 334, 0, 335, 0, 0, 336, 337, 338, 0, 0, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 351, 0, 352, 353, 354, 355, 0, 356, + 357, 0, 358, 0, 359, 360, 361, 362, 363, 364, + 0, 365, 0, 0, 366, 367, 368, 0, 0, 369, + 0, 0, 0, 370, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 379, 380, 381, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 618, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 0, 409, 410, 411, + 412, 413, 414, 415, 416, 417, 418, 419, 619, 420, + 421, 422, 423, 424, 0, 425, 426, 427, 428, 0, + 429, 430, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 442, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 451, 452, 0, 0, + 453, 454, 455, 456, 0, 457, 458, 459, 460, 461, + 462, 463, 0, 0, 464, 465, 466, 467, 468, 0, + 0, 469, 470, 471, 472, 473, 474, 475, 0, 476, + 0, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 485, 486, 487, 488, 489, 490, 491, + 492, 493, 494, 495, 496, 497, 199, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 200, 201, 202, + 203, 204, 205, 206, 207, 0, 209, 210, 211, 3, + 4, 0, 0, 0, 0, 0, 212, 213, 0, 214, + 215, 0, 216, 217, 218, 219, 220, 0, 221, 222, + 0, 223, 224, 225, 226, 227, 0, 0, 228, 229, + 230, 231, 232, 0, 233, 234, 235, 236, 237, 0, + 0, 0, 238, 239, 240, 241, 0, 242, 243, 0, + 244, 245, 246, 247, 248, 249, 0, 0, 250, 251, + 0, 0, 0, 0, 0, 0, 0, 252, 253, 254, + 255, 256, 257, 258, 259, 260, 0, 261, 0, 262, + 263, 264, 265, 266, 0, 267, 268, 269, 0, 0, + 270, 271, 272, 273, 274, 0, 275, 276, 277, 0, + 278, 279, 0, 280, 281, 282, 283, 284, 285, 286, + 287, 288, 0, 289, 0, 290, 291, 292, 0, 293, + 0, 294, 0, 0, 0, 295, 296, 297, 0, 298, + 299, 0, 300, 0, 301, 302, 303, 304, 305, 0, + 306, 307, 308, 0, 309, 310, 311, 312, 313, 314, + 0, 315, 0, 316, 317, 318, 319, 320, 321, 322, + 0, 323, 0, 324, 0, 0, 325, 0, 326, 327, + 328, 329, 330, 331, 332, 0, 333, 334, 0, 335, + 0, 0, 336, 337, 338, 0, 0, 339, 340, 341, + 342, 343, 344, 345, 346, 347, 348, 349, 350, 351, + 0, 352, 353, 354, 355, 0, 356, 357, 0, 358, + 0, 359, 360, 361, 362, 363, 364, 0, 365, 0, + 0, 366, 367, 368, 0, 0, 369, 0, 0, 0, + 370, 371, 372, 373, 374, 375, 376, 377, 0, 378, + 379, 380, 381, 382, 383, 384, 0, 385, 386, 387, + 388, 389, 390, 391, 392, 393, 394, 395, 396, 0, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 0, 407, 408, 0, 409, 410, 411, 412, 413, 414, + 415, 416, 417, 418, 419, 0, 420, 421, 422, 423, + 424, 0, 425, 426, 427, 428, 0, 429, 430, 431, + 0, 432, 433, 434, 435, 436, 437, 438, 439, 440, + 441, 442, 0, 443, 444, 0, 445, 446, 447, 448, + 449, 450, 0, 451, 452, 0, 0, 453, 454, 455, + 456, 0, 457, 458, 459, 460, 461, 462, 463, 0, + 0, 464, 465, 466, 467, 468, 0, 0, 469, 470, + 471, 472, 473, 474, 475, 0, 476, 921, 477, 478, + 479, 0, 0, 480, 0, 0, 481, 482, 483, 484, + 485, 486, 487, 488, 489, 490, 491, 492, 493, 494, + 495, 496, 497, 199, 0, 550, 0, 0, 0, 0, + 0, 0, 0, 0, 200, 201, 202, 203, 204, 205, + 206, 207, 0, 209, 210, 211, 0, 0, 0, 0, + 0, 0, 0, 212, 213, 0, 214, 215, 0, 216, + 217, 218, 219, 220, 0, 221, 222, 0, 223, 224, + 225, 226, 227, 0, 0, 228, 229, 230, 231, 232, + 0, 233, 234, 235, 236, 237, 0, 0, 0, 238, + 239, 240, 241, 0, 242, 243, 0, 244, 245, 246, + 247, 248, 249, 0, 0, 250, 251, 0, 0, 0, + 0, 0, 0, 0, 252, 253, 254, 255, 256, 257, + 258, 259, 260, 1639, 261, 0, 262, 263, 264, 265, + 266, 0, 267, 268, 269, 0, 0, 270, 271, 272, + 273, 274, 0, 275, 276, 277, 0, 278, 279, 0, + 280, 281, 282, 283, 284, 285, 286, 287, 288, 0, + 289, 0, 290, 291, 292, 0, 293, 0, 294, 0, + 0, 0, 295, 296, 297, 0, 298, 299, 0, 300, + 0, 301, 302, 303, 304, 305, 0, 306, 307, 308, + 0, 309, 310, 311, 312, 313, 314, 0, 315, 0, + 316, 317, 318, 319, 320, 321, 322, 0, 323, 0, + 324, 0, 0, 325, 0, 326, 327, 328, 329, 330, + 331, 332, 0, 333, 334, 0, 335, 0, 0, 336, + 337, 338, 0, 0, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 351, 0, 352, 353, + 354, 355, 0, 356, 357, 0, 358, 0, 359, 360, + 361, 362, 363, 364, 0, 365, 0, 0, 366, 367, + 368, 0, 0, 369, 0, 0, 0, 370, 371, 372, + 373, 374, 375, 376, 377, 0, 378, 379, 380, 381, + 382, 383, 384, 0, 385, 386, 387, 388, 389, 390, + 391, 392, 393, 394, 395, 396, 0, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 0, 407, 408, + 0, 409, 410, 411, 412, 413, 414, 415, 416, 417, + 418, 419, 0, 420, 421, 422, 423, 424, 0, 425, + 426, 427, 428, 0, 429, 430, 431, 0, 432, 433, + 434, 435, 436, 437, 438, 439, 440, 441, 442, 0, + 443, 444, 0, 445, 446, 447, 448, 449, 450, 0, + 451, 452, 0, 0, 453, 454, 455, 456, 0, 457, + 458, 459, 460, 461, 462, 463, 0, 0, 464, 465, + 466, 467, 468, 0, 0, 469, 470, 471, 472, 473, + 474, 475, 0, 476, 0, 477, 478, 479, 0, 0, + 480, 0, 0, 481, 482, 483, 484, 485, 486, 487, + 488, 489, 490, 491, 492, 493, 494, 495, 496, 497, + 199, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 200, 201, 202, 203, 204, 205, 206, 207, 0, + 209, 210, 211, 0, 0, 0, 0, 0, 0, 0, + 212, 213, 0, 214, 215, 0, 216, 217, 218, 219, + 220, 0, 221, 222, 0, 223, 224, 225, 226, 227, + 0, 0, 228, 229, 230, 231, 232, 0, 233, 234, + 235, 236, 237, 0, 0, 0, 238, 239, 240, 241, + 0, 242, 243, 0, 244, 245, 246, 247, 248, 249, + 0, 0, 250, 251, 0, 0, 0, 0, 0, 0, + 1984, 252, 253, 254, 255, 256, 257, 258, 259, 260, + 0, 261, 0, 262, 263, 264, 265, 266, 0, 267, + 268, 269, 0, 0, 270, 271, 272, 273, 274, 0, + 275, 276, 277, 0, 278, 279, 0, 280, 281, 282, + 283, 284, 285, 286, 287, 288, 0, 289, 0, 290, + 291, 292, 0, 293, 0, 294, 0, 0, 0, 295, + 296, 297, 0, 298, 299, 0, 300, 0, 301, 302, + 303, 304, 305, 0, 306, 307, 308, 0, 309, 310, + 311, 312, 313, 314, 0, 315, 0, 316, 317, 318, + 319, 320, 321, 322, 0, 323, 0, 324, 0, 0, + 325, 0, 326, 327, 328, 329, 330, 331, 332, 0, + 333, 334, 0, 335, 0, 0, 336, 337, 338, 0, + 0, 339, 340, 341, 342, 343, 344, 345, 346, 347, + 348, 349, 350, 351, 0, 352, 353, 354, 355, 0, + 356, 357, 0, 358, 0, 359, 360, 361, 362, 363, + 364, 0, 365, 0, 0, 366, 367, 368, 0, 0, + 369, 0, 0, 0, 370, 371, 372, 373, 374, 375, + 376, 377, 0, 378, 379, 380, 381, 382, 383, 384, + 0, 385, 386, 387, 388, 389, 390, 391, 392, 393, + 394, 395, 396, 0, 397, 398, 399, 400, 401, 402, + 403, 404, 405, 406, 0, 407, 408, 0, 409, 410, + 411, 412, 413, 414, 415, 416, 417, 418, 419, 0, + 420, 421, 422, 423, 424, 0, 425, 426, 427, 428, + 0, 429, 430, 431, 0, 432, 433, 434, 435, 436, + 437, 438, 439, 440, 441, 442, 0, 443, 444, 0, + 445, 446, 447, 448, 449, 450, 0, 451, 452, 0, + 0, 453, 454, 455, 456, 0, 457, 458, 459, 460, + 461, 462, 463, 0, 0, 464, 465, 466, 467, 468, + 1985, 0, 469, 470, 471, 472, 473, 474, 475, 0, + 476, 0, 477, 478, 479, 0, 0, 480, 0, 0, + 481, 482, 483, 484, 485, 486, 487, 488, 489, 490, + 491, 492, 493, 494, 495, 496, 497, 199, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 200, 201, + 202, 203, 204, 205, 206, 207, 0, 209, 210, 211, + 3, 4, 0, 0, 0, 0, 0, 212, 213, 0, + 214, 215, 0, 216, 217, 218, 219, 220, 0, 221, + 222, 0, 223, 224, 225, 226, 227, 0, 0, 228, + 229, 230, 231, 232, 0, 233, 234, 235, 236, 237, + 0, 0, 0, 238, 239, 240, 241, 0, 242, 243, + 0, 244, 245, 246, 247, 248, 249, 0, 0, 250, + 251, 0, 0, 0, 0, 0, 0, 0, 252, 253, + 254, 255, 256, 257, 258, 259, 260, 0, 261, 0, + 262, 263, 264, 265, 266, 0, 267, 268, 269, 0, + 0, 270, 271, 272, 273, 274, 0, 275, 276, 277, + 0, 278, 279, 0, 280, 281, 282, 283, 284, 285, + 286, 287, 288, 0, 289, 0, 290, 291, 292, 0, + 293, 0, 294, 0, 0, 0, 295, 296, 297, 0, + 298, 299, 0, 300, 0, 301, 302, 303, 304, 305, + 0, 306, 307, 308, 0, 309, 310, 311, 312, 313, + 314, 0, 315, 0, 316, 317, 318, 319, 320, 321, + 322, 0, 323, 0, 324, 0, 0, 325, 0, 326, + 327, 328, 329, 330, 331, 332, 0, 333, 334, 0, + 335, 0, 0, 336, 337, 338, 0, 0, 339, 340, + 341, 342, 343, 344, 345, 346, 347, 348, 349, 350, + 351, 0, 352, 353, 354, 355, 0, 356, 357, 0, + 358, 0, 359, 360, 361, 362, 363, 364, 0, 365, + 0, 0, 366, 367, 368, 0, 0, 369, 0, 0, + 0, 370, 371, 372, 373, 374, 375, 376, 377, 0, + 378, 379, 380, 381, 382, 383, 384, 0, 385, 386, + 387, 388, 389, 390, 391, 392, 393, 394, 395, 396, + 0, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 0, 407, 408, 0, 409, 410, 411, 412, 413, + 414, 415, 416, 417, 418, 419, 0, 420, 421, 422, + 423, 424, 0, 425, 426, 427, 428, 0, 429, 430, + 431, 0, 432, 433, 434, 435, 436, 437, 438, 439, + 440, 441, 442, 0, 443, 444, 0, 445, 446, 447, + 448, 449, 450, 0, 451, 452, 0, 0, 453, 454, + 455, 456, 0, 457, 458, 459, 460, 461, 462, 463, + 0, 0, 464, 465, 466, 467, 468, 0, 0, 469, + 470, 471, 472, 473, 474, 475, 0, 476, 0, 477, + 478, 479, 0, 0, 480, 0, 0, 481, 482, 483, + 484, 485, 486, 487, 488, 489, 490, 491, 492, 493, + 494, 495, 496, 497, 199, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 200, 201, 202, 203, 204, + 205, 206, 207, 2514, 209, 210, 211, 0, 0, 0, + 0, 0, 0, 0, 212, 213, 0, 214, 215, 0, + 216, 217, 218, 219, 220, 0, 221, 222, 0, 223, + 224, 225, 226, 227, 0, 0, 228, 229, 230, 231, + 232, 0, 233, 234, 235, 236, 237, 0, 0, 0, + 238, 239, 240, 241, 0, 242, 243, 0, 244, 245, + 246, 247, 248, 249, 0, 0, 250, 251, 0, 0, + 0, 0, 0, 0, 0, 252, 253, 254, 255, 256, + 257, 258, 259, 260, 0, 261, 0, 262, 263, 264, + 265, 266, 0, 267, 268, 269, 0, 0, 270, 271, + 272, 273, 274, 0, 275, 276, 277, 0, 278, 279, + 0, 280, 281, 282, 283, 284, 285, 286, 287, 288, + 0, 289, 0, 290, 291, 292, 0, 293, 0, 294, + 0, 0, 0, 295, 296, 297, 0, 298, 299, 0, + 300, 0, 301, 302, 303, 304, 305, 0, 306, 307, + 308, 0, 309, 310, 311, 312, 313, 314, 0, 315, + 0, 316, 317, 318, 319, 320, 321, 322, 0, 323, + 0, 324, 0, 0, 325, 0, 326, 327, 328, 329, + 330, 331, 332, 0, 333, 334, 0, 335, 0, 0, + 336, 337, 338, 0, 0, 339, 340, 341, 342, 343, + 344, 345, 346, 347, 348, 349, 350, 351, 0, 352, + 353, 354, 355, 0, 356, 357, 0, 358, 0, 359, + 360, 361, 362, 363, 364, 0, 365, 0, 0, 366, + 367, 368, 0, 0, 369, 0, 0, 0, 370, 371, + 372, 373, 374, 375, 376, 377, 0, 378, 379, 380, + 381, 382, 383, 384, 0, 385, 386, 387, 388, 389, + 390, 391, 392, 393, 394, 395, 396, 0, 397, 398, + 399, 400, 401, 402, 403, 404, 405, 406, 0, 407, + 408, 0, 409, 410, 411, 412, 413, 414, 415, 416, + 417, 418, 419, 0, 420, 421, 422, 423, 424, 0, + 425, 426, 427, 428, 0, 429, 430, 431, 0, 432, + 433, 434, 435, 436, 437, 438, 439, 440, 441, 442, + 0, 443, 444, 0, 445, 446, 447, 448, 449, 450, + 0, 451, 452, 0, 0, 453, 454, 455, 456, 0, + 457, 458, 459, 460, 461, 462, 463, 0, 0, 464, + 465, 466, 467, 468, 2515, 0, 469, 470, 471, 472, + 473, 474, 475, 0, 476, 0, 477, 478, 479, 0, + 0, 480, 0, 0, 481, 482, 483, 484, 485, 486, + 487, 488, 489, 490, 491, 492, 493, 494, 495, 496, + 497, 199, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 200, 201, 202, 203, 204, 205, 206, 207, + 2526, 209, 210, 211, 0, 0, 0, 0, 0, 0, + 0, 212, 213, 0, 214, 215, 0, 216, 217, 218, + 219, 220, 0, 221, 222, 0, 223, 224, 225, 226, + 227, 0, 0, 228, 229, 230, 231, 232, 0, 233, + 234, 235, 236, 237, 0, 0, 0, 238, 239, 240, + 241, 0, 242, 243, 0, 244, 245, 246, 247, 248, + 249, 0, 0, 250, 251, 0, 0, 0, 0, 0, + 0, 0, 252, 253, 254, 255, 256, 257, 258, 259, + 260, 0, 261, 0, 262, 263, 264, 265, 266, 0, + 267, 268, 269, 0, 0, 270, 271, 272, 273, 274, + 0, 275, 276, 277, 0, 278, 279, 0, 280, 281, + 282, 283, 284, 285, 286, 287, 288, 0, 289, 0, + 290, 291, 292, 0, 293, 0, 294, 0, 0, 0, + 295, 296, 297, 0, 298, 299, 0, 300, 0, 301, + 302, 303, 304, 305, 0, 306, 307, 308, 0, 309, + 310, 311, 312, 313, 314, 0, 315, 0, 316, 317, + 318, 319, 320, 321, 322, 0, 323, 0, 324, 0, + 0, 325, 0, 326, 327, 328, 329, 330, 331, 332, + 0, 333, 334, 0, 335, 0, 0, 336, 337, 338, + 0, 0, 339, 340, 341, 342, 343, 344, 345, 346, + 347, 348, 349, 350, 351, 0, 352, 353, 354, 355, + 0, 356, 357, 0, 358, 0, 359, 360, 361, 362, + 363, 364, 0, 365, 0, 0, 366, 367, 368, 0, + 0, 369, 0, 0, 0, 370, 371, 372, 373, 374, + 375, 376, 377, 0, 378, 379, 380, 381, 382, 383, + 384, 0, 385, 386, 387, 388, 389, 390, 391, 392, + 393, 394, 395, 396, 0, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 0, 407, 408, 0, 409, + 410, 411, 412, 413, 414, 415, 416, 417, 418, 419, + 0, 420, 421, 422, 423, 424, 0, 425, 426, 427, + 428, 0, 429, 430, 431, 0, 432, 433, 434, 435, + 436, 437, 438, 439, 440, 441, 442, 0, 443, 444, + 0, 445, 446, 447, 448, 449, 450, 0, 451, 452, + 0, 0, 453, 454, 455, 456, 0, 457, 458, 459, + 460, 461, 462, 463, 0, 0, 464, 465, 466, 467, + 468, 2527, 0, 469, 470, 471, 472, 473, 474, 475, + 0, 476, 0, 477, 478, 479, 0, 0, 480, 0, + 0, 481, 482, 483, 484, 485, 486, 487, 488, 489, + 490, 491, 492, 493, 494, 495, 496, 497, 199, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 200, + 201, 202, 203, 204, 205, 206, 207, 208, 209, 210, + 211, 0, 0, 0, 0, 0, 0, 0, 212, 213, + 0, 214, 215, 0, 216, 217, 218, 219, 220, 0, + 221, 222, 0, 223, 224, 225, 226, 227, 0, 0, + 228, 229, 230, 231, 232, 0, 233, 234, 235, 236, + 237, 0, 0, 0, 238, 239, 240, 241, 0, 242, + 243, 0, 244, 245, 246, 247, 248, 249, 0, 0, + 250, 251, 0, 0, 0, 0, 0, 0, 0, 252, + 253, 254, 255, 256, 257, 258, 259, 260, 0, 261, + 0, 262, 263, 264, 265, 266, 0, 267, 268, 269, + 0, 0, 270, 271, 272, 273, 274, 0, 275, 276, + 277, 0, 278, 279, 0, 280, 281, 282, 283, 284, + 285, 286, 287, 288, 0, 289, 0, 290, 291, 292, + 0, 293, 0, 294, 0, 0, 0, 295, 296, 297, + 0, 298, 299, 0, 300, 0, 301, 302, 303, 304, + 305, 0, 306, 307, 308, 0, 309, 310, 311, 312, + 313, 314, 0, 315, 0, 316, 317, 318, 319, 320, + 321, 322, 0, 323, 0, 324, 0, 0, 325, 0, + 326, 327, 328, 329, 330, 331, 332, 0, 333, 334, + 0, 335, 0, 0, 336, 337, 338, 0, 0, 339, + 340, 341, 342, 343, 344, 345, 346, 347, 348, 349, + 350, 351, 0, 352, 353, 354, 355, 0, 356, 357, + 0, 358, 0, 359, 360, 361, 362, 363, 364, 0, + 365, 0, 0, 366, 367, 368, 0, 0, 369, 0, + 0, 0, 370, 371, 372, 373, 374, 375, 376, 377, + 0, 378, 379, 380, 381, 382, 383, 384, 0, 385, + 386, 387, 388, 389, 390, 391, 392, 393, 394, 395, + 396, 0, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 0, 407, 408, 0, 409, 410, 411, 412, + 413, 414, 415, 416, 417, 418, 419, 0, 420, 421, + 422, 423, 424, 0, 425, 426, 427, 428, 0, 429, + 430, 431, 0, 432, 433, 434, 435, 436, 437, 438, + 439, 440, 441, 442, 0, 443, 444, 0, 445, 446, + 447, 448, 449, 450, 0, 451, 452, 0, 0, 453, + 454, 455, 456, 0, 457, 458, 459, 460, 461, 462, + 463, 0, 0, 464, 465, 466, 467, 468, 0, 0, + 469, 470, 471, 472, 473, 474, 475, 0, 476, 0, + 477, 478, 479, 0, 0, 480, 0, 0, 481, 482, + 483, 484, 485, 486, 487, 488, 489, 490, 491, 492, + 493, 494, 495, 496, 497, 199, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 200, 201, 202, 203, + 204, 205, 206, 207, 542, 209, 210, 211, 0, 0, + 0, 0, 0, 0, 0, 212, 213, 0, 214, 215, + 0, 216, 217, 218, 219, 220, 0, 221, 222, 0, + 223, 224, 225, 226, 227, 0, 0, 228, 229, 230, + 231, 232, 0, 233, 234, 235, 236, 237, 0, 0, + 0, 238, 239, 240, 241, 0, 242, 243, 0, 244, + 245, 246, 247, 248, 249, 0, 0, 250, 251, 0, + 0, 0, 0, 0, 0, 0, 252, 253, 254, 255, + 256, 257, 258, 259, 260, 0, 261, 0, 262, 263, + 264, 265, 266, 0, 267, 268, 269, 0, 0, 270, + 271, 272, 273, 274, 0, 275, 276, 277, 0, 278, + 279, 0, 280, 281, 282, 283, 284, 285, 286, 287, + 288, 0, 289, 0, 290, 291, 292, 0, 293, 0, + 294, 0, 0, 0, 295, 296, 297, 0, 298, 299, + 0, 300, 0, 301, 302, 303, 304, 305, 0, 306, + 307, 308, 0, 309, 310, 311, 312, 313, 314, 0, + 315, 0, 316, 317, 318, 319, 320, 321, 322, 0, + 323, 0, 324, 0, 0, 325, 0, 326, 327, 328, + 329, 330, 331, 332, 0, 333, 334, 0, 335, 0, + 0, 336, 337, 338, 0, 0, 339, 340, 341, 342, + 343, 344, 345, 346, 347, 348, 349, 350, 351, 0, + 352, 353, 354, 355, 0, 356, 357, 0, 358, 0, + 359, 360, 361, 362, 363, 364, 0, 365, 0, 0, + 366, 367, 368, 0, 0, 369, 0, 0, 0, 370, + 371, 372, 373, 374, 375, 376, 377, 0, 378, 379, + 380, 381, 382, 543, 384, 0, 385, 386, 387, 388, + 389, 390, 391, 392, 393, 394, 395, 396, 0, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 0, + 407, 408, 0, 409, 410, 411, 412, 413, 414, 415, + 416, 417, 418, 419, 0, 420, 421, 422, 423, 424, + 0, 425, 426, 427, 428, 0, 429, 430, 431, 0, + 432, 433, 434, 435, 436, 437, 438, 439, 440, 441, + 442, 0, 443, 444, 0, 445, 446, 447, 448, 449, + 450, 0, 451, 452, 0, 0, 453, 454, 455, 456, + 0, 457, 458, 459, 460, 461, 462, 463, 0, 0, + 464, 465, 466, 467, 468, 0, 0, 469, 470, 471, + 472, 473, 474, 475, 0, 476, 0, 477, 478, 479, + 0, 0, 480, 0, 0, 481, 482, 483, 484, 485, + 486, 487, 488, 489, 490, 491, 492, 493, 494, 495, + 496, 497, 199, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 200, 201, 202, 203, 204, 205, 206, + 207, 641, 209, 210, 211, 0, 0, 0, 0, 0, + 0, 0, 212, 213, 0, 214, 215, 0, 216, 217, + 218, 219, 220, 0, 221, 222, 0, 223, 224, 225, + 226, 227, 0, 0, 228, 229, 230, 231, 232, 0, + 233, 234, 235, 236, 237, 0, 0, 0, 238, 239, + 240, 241, 0, 242, 243, 0, 244, 245, 246, 247, + 248, 249, 0, 0, 250, 251, 0, 0, 0, 0, + 0, 0, 0, 252, 253, 254, 255, 256, 257, 258, + 259, 260, 0, 261, 0, 262, 263, 264, 265, 266, + 0, 267, 268, 269, 0, 0, 270, 271, 272, 273, + 274, 0, 275, 276, 277, 0, 278, 279, 0, 280, + 281, 282, 283, 284, 285, 286, 287, 288, 0, 289, + 0, 290, 291, 292, 0, 293, 0, 294, 0, 0, + 0, 295, 296, 297, 0, 298, 299, 0, 300, 0, + 301, 302, 303, 304, 305, 0, 306, 307, 308, 0, + 309, 310, 311, 312, 313, 314, 0, 315, 0, 316, + 317, 318, 319, 320, 321, 322, 0, 323, 0, 324, + 0, 0, 325, 0, 326, 327, 328, 329, 330, 331, + 332, 0, 333, 334, 0, 335, 0, 0, 336, 337, + 338, 0, 0, 339, 340, 341, 342, 343, 344, 345, + 346, 347, 348, 349, 350, 351, 0, 352, 353, 354, + 355, 0, 356, 357, 0, 358, 0, 359, 360, 361, + 362, 363, 364, 0, 365, 0, 0, 366, 367, 368, + 0, 0, 369, 0, 0, 0, 370, 371, 372, 373, + 374, 375, 376, 377, 0, 378, 379, 380, 381, 382, + 383, 384, 0, 385, 386, 387, 388, 389, 390, 391, + 392, 393, 394, 395, 396, 0, 397, 398, 399, 400, + 401, 402, 403, 404, 405, 406, 0, 407, 408, 0, + 409, 410, 411, 412, 413, 414, 415, 416, 417, 418, + 419, 0, 420, 421, 422, 423, 642, 0, 425, 426, + 427, 428, 0, 429, 430, 431, 0, 432, 433, 434, + 435, 436, 437, 438, 439, 440, 441, 442, 0, 443, + 444, 0, 445, 446, 447, 448, 449, 450, 0, 643, + 452, 0, 0, 644, 454, 455, 456, 0, 457, 458, + 459, 460, 461, 462, 463, 0, 0, 464, 465, 466, + 467, 468, 0, 0, 469, 470, 471, 472, 473, 474, + 475, 0, 476, 0, 477, 478, 479, 0, 0, 480, + 0, 0, 481, 482, 483, 484, 485, 486, 487, 488, + 489, 490, 491, 492, 493, 494, 495, 496, 497, 199, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 200, 201, 202, 203, 204, 205, 206, 207, 671, 209, + 210, 211, 0, 0, 0, 0, 0, 0, 0, 212, + 213, 0, 214, 215, 0, 216, 217, 218, 219, 220, + 0, 221, 222, 0, 223, 224, 225, 226, 227, 0, + 0, 228, 229, 230, 231, 232, 0, 233, 234, 235, + 236, 237, 0, 0, 0, 238, 239, 240, 241, 0, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 0, + 0, 250, 251, 0, 0, 0, 0, 0, 0, 0, + 252, 253, 254, 255, 256, 257, 258, 259, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 272, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 284, 285, 286, 287, 288, 0, 289, 0, 290, 291, + 292, 0, 293, 0, 294, 0, 0, 0, 295, 296, + 297, 0, 298, 299, 0, 300, 0, 301, 302, 303, + 304, 305, 0, 306, 307, 308, 0, 309, 310, 311, + 312, 313, 314, 0, 315, 0, 316, 317, 318, 319, + 320, 321, 322, 0, 323, 0, 324, 0, 0, 325, + 0, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 334, 0, 335, 0, 0, 336, 337, 338, 0, 0, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 351, 0, 352, 353, 354, 355, 0, 356, + 357, 0, 358, 0, 359, 360, 361, 362, 363, 364, + 0, 365, 0, 0, 366, 367, 368, 0, 0, 369, + 0, 0, 0, 370, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 379, 380, 381, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 0, 409, 410, 411, + 412, 413, 414, 415, 416, 417, 418, 419, 0, 420, + 421, 422, 423, 672, 0, 425, 426, 427, 428, 0, + 429, 430, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 442, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 673, 452, 0, 0, + 674, 454, 455, 456, 0, 457, 458, 459, 460, 461, + 462, 463, 0, 0, 464, 465, 466, 467, 468, 0, + 0, 469, 470, 471, 472, 473, 474, 475, 0, 476, + 0, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 485, 486, 487, 488, 489, 490, 491, + 492, 493, 494, 495, 496, 497, 199, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 200, 201, 202, + 203, 204, 205, 206, 207, 0, 209, 210, 211, 0, + 0, 0, 0, 0, 0, 0, 212, 213, 0, 214, + 215, 0, 216, 217, 218, 219, 220, 0, 221, 222, + 0, 223, 224, 225, 226, 227, 0, 0, 228, 229, + 230, 231, 232, 0, 233, 234, 235, 236, 237, 0, + 0, 0, 238, 239, 240, 241, 0, 242, 243, 0, + 244, 245, 246, 247, 248, 249, 0, 0, 250, 251, + 0, 0, 0, 0, 0, 0, 0, 252, 253, 254, + 255, 256, 257, 258, 259, 260, 0, 261, 0, 262, + 263, 264, 265, 266, 0, 267, 268, 269, 0, 0, + 270, 271, 272, 273, 274, 0, 275, 276, 277, 0, + 278, 279, 0, 280, 281, 282, 283, 284, 285, 286, + 287, 288, 0, 289, 0, 290, 291, 292, 0, 293, + 0, 294, 0, 0, 0, 295, 296, 297, 0, 298, + 299, 0, 300, 0, 301, 302, 303, 304, 305, 0, + 306, 307, 308, 0, 309, 310, 311, 312, 313, 314, + 0, 315, 0, 316, 317, 318, 319, 320, 321, 322, + 0, 323, 0, 324, 0, 0, 325, 0, 326, 327, + 328, 329, 330, 331, 332, 0, 333, 334, 0, 335, + 0, 0, 336, 337, 338, 0, 0, 339, 340, 341, + 342, 343, 344, 345, 346, 347, 348, 349, 350, 351, + 0, 352, 353, 354, 355, 0, 356, 357, 0, 358, + 0, 359, 360, 361, 362, 363, 364, 0, 365, 0, + 677, 366, 367, 368, 0, 0, 369, 0, 0, 0, + 370, 371, 372, 373, 374, 375, 376, 377, 0, 378, + 379, 380, 381, 382, 383, 384, 0, 385, 386, 387, + 388, 389, 390, 391, 392, 393, 394, 395, 396, 0, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 0, 407, 408, 0, 409, 410, 411, 412, 413, 414, + 415, 416, 417, 418, 419, 0, 420, 421, 422, 423, + 424, 0, 425, 426, 427, 428, 0, 429, 430, 431, + 0, 432, 433, 434, 435, 436, 437, 438, 439, 440, + 441, 442, 0, 443, 444, 0, 445, 446, 447, 448, + 449, 450, 0, 451, 452, 0, 0, 453, 454, 455, + 456, 0, 457, 458, 459, 460, 461, 462, 463, 0, + 0, 464, 465, 466, 467, 468, 0, 0, 469, 470, + 471, 472, 473, 474, 475, 0, 476, 0, 477, 478, + 479, 0, 0, 480, 0, 0, 481, 482, 483, 484, + 485, 486, 487, 488, 489, 490, 491, 492, 493, 494, + 495, 496, 497, 199, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 200, 201, 202, 203, 204, 205, + 206, 207, 0, 209, 210, 211, 0, 0, 0, 0, + 0, 0, 0, 212, 213, 0, 214, 215, 0, 216, + 217, 218, 219, 220, 0, 221, 222, 0, 223, 224, + 225, 226, 227, 0, 0, 228, 229, 230, 231, 232, + 0, 233, 234, 235, 236, 237, 0, 0, 0, 238, + 239, 240, 241, 0, 242, 243, 0, 244, 245, 246, + 247, 248, 249, 0, 0, 250, 251, 0, 0, 0, + 0, 0, 0, 0, 252, 253, 254, 255, 256, 257, + 258, 259, 260, 0, 261, 0, 262, 263, 264, 265, + 266, 0, 267, 268, 269, 0, 0, 270, 271, 272, + 273, 274, 0, 275, 276, 277, 0, 278, 279, 0, + 280, 281, 282, 283, 284, 285, 286, 287, 288, 0, + 289, 0, 290, 291, 292, 0, 293, 0, 294, 0, + 0, 0, 295, 296, 297, 0, 298, 299, 0, 300, + 0, 301, 302, 303, 304, 781, 0, 306, 307, 308, + 0, 309, 310, 311, 312, 313, 314, 0, 315, 0, + 316, 317, 318, 319, 320, 321, 322, 0, 323, 0, + 324, 0, 0, 325, 0, 326, 327, 328, 329, 330, + 331, 332, 0, 333, 334, 0, 335, 0, 0, 336, + 337, 338, 0, 0, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 351, 0, 352, 353, + 354, 355, 0, 356, 357, 0, 358, 0, 359, 360, + 361, 362, 363, 364, 0, 365, 0, 677, 366, 367, + 368, 0, 0, 369, 0, 0, 0, 370, 371, 372, + 373, 374, 375, 376, 377, 0, 378, 379, 380, 381, + 382, 383, 384, 0, 385, 386, 387, 388, 389, 390, + 391, 392, 393, 394, 395, 396, 0, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 0, 407, 408, + 0, 409, 410, 411, 412, 413, 414, 415, 416, 417, + 418, 419, 0, 420, 421, 422, 423, 424, 0, 425, + 426, 427, 428, 0, 429, 430, 431, 0, 432, 433, + 434, 435, 436, 437, 438, 439, 440, 441, 442, 0, + 443, 444, 0, 445, 446, 447, 448, 449, 450, 0, + 451, 452, 0, 0, 453, 454, 455, 456, 0, 457, + 458, 459, 460, 461, 462, 463, 0, 0, 464, 465, + 466, 467, 468, 0, 0, 469, 470, 471, 472, 473, + 474, 475, 0, 476, 0, 477, 478, 479, 0, 0, + 480, 0, 0, 481, 482, 483, 484, 485, 486, 487, + 488, 489, 490, 491, 492, 493, 494, 495, 496, 497, + 199, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 200, 201, 202, 203, 204, 205, 206, 207, 871, + 209, 210, 211, 0, 0, 0, 0, 0, 0, 0, + 212, 213, 0, 214, 215, 0, 216, 217, 218, 219, + 220, 0, 221, 222, 0, 223, 224, 225, 226, 227, + 0, 0, 228, 229, 230, 231, 232, 0, 233, 234, + 235, 236, 237, 0, 0, 0, 238, 239, 240, 241, + 0, 242, 243, 0, 244, 245, 246, 247, 248, 249, + 0, 0, 250, 251, 0, 0, 0, 0, 0, 0, + 0, 252, 253, 254, 255, 256, 257, 258, 259, 260, + 0, 261, 0, 262, 263, 264, 265, 266, 0, 267, + 268, 269, 0, 0, 270, 271, 272, 273, 274, 0, + 275, 276, 277, 0, 278, 279, 0, 280, 281, 282, + 283, 284, 285, 286, 287, 288, 0, 289, 0, 290, + 291, 292, 0, 293, 0, 294, 0, 0, 0, 295, + 296, 297, 0, 298, 299, 0, 300, 0, 301, 302, + 303, 304, 305, 0, 306, 307, 308, 0, 309, 310, + 311, 312, 313, 314, 0, 315, 0, 316, 317, 318, + 319, 320, 321, 322, 0, 323, 0, 324, 0, 0, + 325, 0, 326, 327, 328, 329, 330, 331, 332, 0, + 333, 334, 0, 335, 0, 0, 336, 337, 338, 0, + 0, 339, 340, 341, 342, 343, 344, 345, 346, 347, + 348, 349, 350, 351, 0, 352, 353, 354, 355, 0, + 356, 357, 0, 358, 0, 359, 360, 361, 362, 363, + 364, 0, 365, 0, 0, 366, 367, 368, 0, 0, + 369, 0, 0, 0, 370, 371, 372, 373, 374, 375, + 376, 377, 0, 378, 379, 380, 381, 382, 383, 384, + 0, 385, 386, 387, 388, 389, 390, 391, 392, 393, + 394, 395, 396, 0, 397, 398, 399, 400, 401, 402, + 403, 404, 405, 406, 0, 407, 408, 0, 409, 410, + 411, 412, 413, 414, 415, 416, 417, 418, 419, 0, + 420, 421, 422, 423, 424, 0, 425, 426, 427, 428, + 0, 429, 430, 431, 0, 432, 433, 434, 435, 436, + 437, 438, 439, 440, 441, 442, 0, 443, 444, 0, + 445, 446, 447, 448, 449, 450, 0, 451, 452, 0, + 0, 453, 454, 455, 456, 0, 457, 458, 459, 460, + 461, 462, 463, 0, 0, 464, 465, 466, 467, 468, + 0, 0, 469, 470, 471, 472, 473, 474, 475, 0, + 476, 0, 477, 478, 479, 0, 0, 480, 0, 0, + 481, 482, 483, 484, 485, 486, 487, 488, 489, 490, + 491, 492, 493, 494, 495, 496, 497, 199, 0, 550, + 0, 0, 0, 0, 0, 0, 0, 0, 200, 201, + 202, 203, 204, 205, 206, 207, 0, 209, 210, 211, + 0, 0, 0, 0, 0, 0, 0, 212, 213, 0, + 214, 215, 0, 216, 217, 218, 219, 220, 0, 221, + 222, 0, 223, 224, 225, 226, 227, 0, 0, 228, + 229, 230, 231, 232, 0, 233, 234, 235, 236, 237, + 0, 0, 0, 238, 239, 240, 241, 0, 242, 243, + 0, 244, 245, 246, 247, 248, 249, 0, 0, 250, + 251, 0, 0, 0, 0, 0, 0, 0, 252, 253, + 254, 255, 256, 257, 258, 259, 260, 0, 261, 0, + 262, 263, 264, 265, 266, 0, 267, 268, 269, 0, + 0, 270, 271, 272, 273, 274, 0, 275, 276, 277, + 0, 278, 279, 0, 280, 281, 282, 283, 284, 285, + 286, 287, 288, 0, 289, 0, 290, 291, 292, 0, + 293, 0, 294, 0, 0, 0, 295, 296, 297, 0, + 298, 299, 0, 300, 0, 301, 302, 303, 304, 305, + 0, 306, 307, 308, 0, 309, 310, 311, 312, 313, + 314, 0, 315, 0, 316, 317, 318, 319, 320, 321, + 322, 0, 323, 0, 324, 0, 0, 325, 0, 326, + 327, 328, 329, 330, 331, 332, 0, 333, 334, 0, + 335, 0, 0, 336, 337, 338, 0, 0, 339, 340, + 341, 342, 343, 344, 345, 346, 347, 348, 349, 350, + 351, 0, 352, 353, 354, 355, 0, 356, 357, 0, + 358, 0, 359, 360, 361, 362, 363, 364, 0, 365, + 0, 0, 366, 367, 368, 0, 0, 369, 0, 0, + 0, 370, 371, 372, 373, 374, 375, 376, 377, 0, + 378, 379, 380, 381, 382, 383, 384, 0, 385, 386, + 387, 388, 389, 390, 391, 392, 393, 394, 395, 396, + 0, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 0, 407, 408, 0, 409, 410, 411, 412, 413, + 414, 415, 416, 417, 418, 419, 0, 420, 421, 422, + 423, 424, 0, 425, 426, 427, 428, 0, 429, 430, + 431, 0, 432, 433, 434, 435, 436, 437, 438, 439, + 440, 441, 442, 0, 443, 444, 0, 445, 446, 447, + 448, 449, 450, 0, 451, 452, 0, 0, 453, 454, + 455, 456, 0, 457, 458, 459, 460, 461, 462, 463, + 0, 0, 464, 465, 466, 467, 468, 0, 0, 469, + 470, 471, 472, 473, 474, 475, 0, 476, 0, 477, + 478, 479, 0, 0, 480, 0, 0, 481, 482, 483, + 484, 485, 486, 487, 488, 489, 490, 491, 492, 493, + 494, 495, 496, 497, 199, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 200, 201, 202, 203, 204, + 205, 206, 207, 1078, 209, 210, 211, 0, 0, 0, + 0, 0, 0, 0, 212, 213, 0, 214, 215, 0, + 216, 217, 218, 219, 220, 0, 221, 222, 0, 223, + 224, 225, 226, 227, 0, 0, 228, 229, 230, 231, + 232, 0, 233, 234, 235, 236, 237, 0, 0, 0, + 238, 239, 240, 241, 0, 242, 243, 0, 244, 245, + 246, 247, 248, 249, 0, 0, 250, 251, 0, 0, + 0, 0, 0, 0, 0, 252, 253, 254, 255, 256, + 257, 258, 259, 260, 0, 261, 0, 262, 263, 264, + 265, 266, 0, 267, 268, 269, 0, 0, 270, 271, + 272, 273, 274, 0, 275, 276, 277, 0, 278, 279, + 0, 280, 281, 282, 283, 284, 285, 286, 287, 288, + 0, 289, 0, 290, 291, 292, 0, 293, 0, 294, + 0, 0, 0, 295, 296, 297, 0, 298, 299, 0, + 300, 0, 301, 302, 303, 304, 305, 0, 306, 307, + 308, 0, 309, 310, 311, 312, 313, 314, 0, 315, + 0, 316, 317, 318, 319, 320, 321, 322, 0, 323, + 0, 324, 0, 0, 325, 0, 326, 327, 328, 329, + 330, 331, 332, 0, 333, 334, 0, 335, 0, 0, + 336, 337, 338, 0, 0, 339, 340, 341, 342, 343, + 344, 345, 346, 347, 348, 349, 350, 351, 0, 352, + 353, 354, 355, 0, 356, 357, 0, 358, 0, 359, + 360, 361, 362, 363, 364, 0, 365, 0, 0, 366, + 367, 368, 0, 0, 369, 0, 0, 0, 370, 371, + 372, 373, 374, 375, 376, 377, 0, 378, 379, 380, + 381, 382, 383, 384, 0, 385, 386, 387, 388, 389, + 390, 391, 392, 393, 394, 395, 396, 0, 397, 398, + 399, 400, 401, 402, 403, 404, 405, 406, 0, 407, + 408, 0, 409, 410, 411, 412, 413, 414, 415, 416, + 417, 418, 419, 0, 420, 421, 422, 423, 424, 0, + 425, 426, 427, 428, 0, 429, 430, 431, 0, 432, + 433, 434, 435, 436, 437, 438, 439, 440, 441, 442, + 0, 443, 444, 0, 445, 446, 447, 448, 449, 450, + 0, 451, 452, 0, 0, 453, 454, 455, 456, 0, + 457, 458, 459, 460, 461, 462, 463, 0, 0, 464, + 465, 466, 467, 468, 0, 0, 469, 470, 471, 472, + 473, 474, 475, 0, 476, 0, 477, 478, 479, 0, + 0, 480, 0, 0, 481, 482, 483, 484, 485, 486, + 487, 488, 489, 490, 491, 492, 493, 494, 495, 496, + 497, 199, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 200, 201, 202, 203, 204, 205, 206, 207, + 0, 209, 210, 211, 0, 0, 0, 0, 0, 0, + 0, 212, 213, 0, 214, 215, 1089, 216, 217, 218, + 219, 220, 0, 221, 222, 0, 223, 224, 225, 226, + 227, 0, 0, 658, 229, 230, 231, 1090, 0, 233, + 234, 235, 236, 237, 0, 0, 0, 238, 239, 240, + 241, 0, 242, 243, 0, 244, 245, 246, 247, 248, + 249, 0, 0, 250, 251, 0, 0, 0, 0, 0, + 0, 0, 252, 253, 254, 255, 256, 257, 258, 259, + 260, 0, 261, 0, 262, 263, 264, 265, 266, 0, + 267, 268, 269, 0, 0, 270, 271, 272, 273, 274, + 0, 275, 276, 277, 0, 278, 279, 0, 280, 281, + 282, 283, 284, 285, 286, 287, 288, 0, 289, 0, + 290, 291, 292, 0, 293, 0, 294, 0, 0, 0, + 295, 296, 297, 0, 298, 299, 0, 300, 0, 301, + 302, 303, 304, 305, 0, 306, 307, 308, 0, 309, + 310, 311, 312, 313, 314, 0, 315, 0, 316, 317, + 318, 319, 320, 321, 322, 0, 323, 0, 324, 0, + 0, 325, 0, 326, 327, 328, 329, 330, 331, 332, + 0, 333, 334, 0, 335, 0, 0, 336, 337, 338, + 0, 0, 339, 340, 341, 342, 343, 344, 345, 346, + 347, 348, 349, 661, 351, 0, 352, 353, 354, 355, + 0, 356, 357, 0, 358, 0, 359, 360, 361, 362, + 363, 364, 0, 365, 0, 0, 366, 367, 368, 0, + 0, 369, 0, 0, 0, 370, 371, 372, 373, 374, + 375, 376, 377, 0, 378, 379, 380, 381, 382, 383, + 384, 0, 385, 386, 387, 388, 389, 390, 391, 392, + 393, 394, 395, 396, 0, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 0, 407, 408, 0, 662, + 410, 411, 412, 413, 414, 663, 416, 417, 418, 419, + 0, 420, 421, 422, 423, 1082, 0, 425, 426, 427, + 428, 0, 429, 430, 431, 0, 432, 433, 434, 435, + 436, 437, 438, 439, 440, 441, 442, 0, 443, 444, + 0, 445, 446, 447, 448, 449, 450, 0, 665, 452, + 0, 0, 666, 454, 455, 456, 0, 457, 458, 459, + 460, 461, 462, 463, 0, 0, 464, 465, 466, 467, + 468, 0, 0, 469, 470, 471, 472, 473, 474, 475, + 0, 476, 0, 477, 478, 479, 0, 0, 480, 0, + 0, 481, 482, 483, 484, 667, 486, 487, 488, 489, + 490, 491, 492, 493, 494, 495, 496, 497, 199, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 200, + 201, 202, 203, 204, 205, 206, 207, 0, 209, 210, + 211, 0, 0, 0, 0, 0, 0, 0, 212, 213, + 0, 214, 215, 0, 216, 217, 218, 219, 220, 0, + 221, 222, 0, 223, 224, 225, 226, 227, 0, 0, + 228, 229, 230, 231, 232, 0, 233, 234, 235, 236, + 237, 0, 0, 0, 238, 239, 240, 241, 0, 242, + 243, 0, 244, 245, 246, 247, 248, 249, 0, 0, + 250, 251, 0, 0, 0, 0, 0, 0, 0, 252, + 253, 254, 255, 256, 257, 258, 259, 260, 0, 261, + 0, 262, 263, 264, 265, 266, 0, 267, 268, 269, + 0, 0, 270, 271, 272, 273, 274, 0, 275, 276, + 277, 0, 278, 279, 0, 280, 281, 282, 283, 284, + 285, 286, 287, 288, 0, 289, 0, 290, 291, 292, + 0, 293, 0, 294, 0, 0, 0, 295, 296, 297, + 0, 298, 299, 0, 300, 0, 301, 302, 303, 304, + 1186, 0, 306, 307, 308, 0, 309, 310, 311, 312, + 313, 314, 0, 315, 0, 316, 317, 318, 319, 320, + 321, 322, 0, 323, 0, 324, 0, 0, 325, 0, + 326, 327, 328, 329, 330, 331, 332, 0, 333, 334, + 0, 335, 0, 0, 336, 337, 338, 0, 0, 339, + 340, 341, 342, 343, 344, 345, 346, 347, 348, 349, + 350, 351, 0, 352, 353, 354, 355, 0, 356, 357, + 0, 358, 0, 359, 360, 361, 362, 363, 364, 0, + 365, 0, 677, 366, 367, 368, 0, 0, 369, 0, + 0, 0, 370, 371, 372, 373, 374, 375, 376, 377, + 0, 378, 379, 380, 381, 382, 383, 384, 0, 385, + 386, 387, 388, 389, 390, 391, 392, 393, 394, 395, + 396, 0, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 0, 407, 408, 0, 409, 410, 411, 412, + 413, 414, 415, 416, 417, 418, 419, 0, 420, 421, + 422, 423, 424, 0, 425, 426, 427, 428, 0, 429, + 430, 431, 0, 432, 433, 434, 435, 436, 437, 438, + 439, 440, 441, 442, 0, 443, 444, 0, 445, 446, + 447, 448, 449, 450, 0, 451, 452, 0, 0, 453, + 454, 455, 456, 0, 457, 458, 459, 460, 461, 462, + 463, 0, 0, 464, 465, 466, 467, 468, 0, 0, + 469, 470, 471, 472, 473, 474, 475, 0, 476, 0, + 477, 478, 479, 0, 0, 480, 0, 0, 481, 482, + 483, 484, 485, 486, 487, 488, 489, 490, 491, 492, + 493, 494, 495, 496, 497, 199, 0, 550, 0, 0, + 0, 0, 0, 0, 0, 0, 200, 201, 202, 203, + 204, 205, 206, 207, 0, 209, 210, 211, 0, 0, + 0, 0, 0, 0, 0, 212, 213, 0, 214, 215, + 0, 216, 217, 218, 219, 220, 0, 221, 222, 0, + 223, 224, 225, 226, 227, 0, 0, 228, 229, 230, + 231, 232, 0, 233, 234, 235, 236, 237, 0, 0, + 0, 238, 239, 240, 241, 0, 242, 243, 0, 244, + 245, 246, 247, 248, 249, 0, 0, 250, 251, 0, + 0, 0, 0, 0, 0, 0, 252, 253, 254, 255, + 256, 257, 258, 259, 260, 0, 261, 0, 262, 263, + 264, 265, 266, 0, 267, 268, 269, 0, 0, 270, + 271, 272, 273, 274, 0, 275, 276, 277, 0, 278, + 279, 0, 280, 281, 282, 283, 284, 285, 286, 287, + 288, 0, 289, 0, 290, 291, 292, 0, 293, 0, + 294, 0, 0, 0, 295, 296, 297, 0, 298, 299, + 0, 300, 0, 301, 302, 303, 304, 1454, 0, 306, + 307, 308, 0, 309, 310, 311, 312, 313, 314, 0, + 315, 0, 316, 317, 318, 319, 320, 321, 322, 0, + 323, 0, 324, 0, 0, 325, 0, 326, 327, 328, + 329, 330, 331, 332, 0, 333, 334, 0, 335, 0, + 0, 336, 337, 338, 0, 0, 339, 340, 341, 342, + 343, 344, 345, 346, 347, 348, 349, 350, 351, 0, + 352, 353, 354, 355, 0, 356, 357, 0, 358, 0, + 359, 360, 361, 362, 363, 364, 0, 365, 0, 0, + 366, 367, 368, 0, 0, 369, 0, 0, 0, 370, + 371, 372, 373, 374, 375, 376, 377, 0, 378, 379, + 380, 381, 382, 383, 384, 0, 385, 386, 387, 388, + 389, 390, 391, 392, 393, 394, 395, 396, 0, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 0, + 407, 408, 0, 409, 410, 411, 412, 413, 414, 415, + 416, 417, 418, 419, 0, 420, 421, 422, 423, 424, + 0, 425, 426, 427, 428, 0, 429, 430, 431, 0, + 432, 433, 434, 435, 436, 437, 438, 439, 440, 441, + 442, 0, 443, 444, 0, 445, 446, 447, 448, 449, + 450, 0, 451, 452, 0, 0, 453, 454, 455, 456, + 0, 457, 458, 459, 460, 461, 462, 463, 0, 0, + 464, 465, 466, 467, 468, 0, 0, 469, 470, 471, + 472, 473, 474, 475, 0, 476, 0, 477, 478, 479, + 0, 0, 480, 0, 0, 481, 482, 483, 484, 485, + 486, 487, 488, 489, 490, 491, 492, 493, 494, 495, + 496, 497, 199, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 200, 201, 202, 203, 204, 205, 206, + 207, 0, 209, 210, 211, 0, 0, 0, 0, 0, + 0, 0, 212, 213, 0, 214, 215, 0, 216, 217, + 218, 219, 220, 0, 221, 222, 0, 223, 224, 225, + 226, 227, 0, 0, 228, 229, 230, 231, 232, 0, + 233, 234, 235, 236, 237, 0, 0, 0, 238, 239, + 240, 241, 0, 242, 243, 0, 244, 245, 246, 247, + 248, 249, 0, 0, 250, 251, 0, 0, 0, 0, + 0, 0, 0, 252, 253, 254, 255, 256, 257, 258, + 259, 260, 0, 261, 0, 262, 263, 264, 265, 266, + 0, 267, 268, 269, 0, 0, 270, 271, 272, 273, + 274, 0, 275, 276, 277, 0, 278, 279, 0, 280, + 281, 282, 283, 284, 285, 286, 287, 288, 0, 289, + 0, 290, 291, 292, 0, 293, 0, 294, 0, 0, + 0, 295, 296, 2341, 0, 298, 299, 0, 300, 0, + 301, 302, 303, 304, 305, 0, 306, 307, 308, 0, + 309, 310, 311, 312, 313, 314, 0, 315, 0, 316, + 317, 318, 319, 320, 321, 322, 0, 323, 0, 324, + 0, 0, 325, 0, 326, 327, 328, 329, 330, 331, + 332, 0, 333, 334, 0, 335, 0, 0, 336, 337, + 2342, 0, 0, 339, 340, 341, 342, 343, 344, 345, + 346, 347, 348, 349, 350, 351, 0, 352, 353, 354, + 355, 0, 356, 357, 0, 358, 0, 359, 360, 361, + 362, 363, 364, 0, 365, 0, 0, 366, 367, 368, + 0, 0, 369, 0, 0, 0, 370, 371, 372, 373, + 374, 375, 376, 377, 0, 378, 379, 380, 381, 382, + 383, 384, 0, 385, 386, 387, 388, 389, 390, 391, + 392, 393, 394, 395, 396, 0, 397, 398, 399, 400, + 401, 402, 403, 404, 405, 406, 0, 407, 408, 0, + 409, 410, 411, 412, 413, 414, 415, 416, 417, 418, + 419, 0, 420, 421, 422, 423, 424, 0, 425, 426, + 427, 428, 0, 429, 430, 431, 0, 432, 433, 434, + 435, 436, 437, 438, 439, 440, 441, 442, 0, 443, + 444, 2343, 445, 446, 2344, 448, 2345, 450, 0, 451, + 452, 0, 0, 453, 454, 455, 456, 0, 457, 458, + 459, 460, 461, 462, 463, 0, 0, 464, 465, 2346, + 467, 468, 0, 0, 469, 470, 471, 472, 473, 474, + 475, 0, 476, 0, 477, 478, 479, 0, 0, 480, + 0, 0, 481, 482, 483, 484, 485, 486, 487, 488, + 489, 490, 491, 492, 493, 494, 495, 496, 497, 199, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 0, 0, 0, 212, + 213, 0, 214, 215, 0, 216, 217, 218, 219, 220, + 0, 221, 222, 0, 223, 224, 225, 226, 227, 0, + 0, 228, 229, 230, 231, 232, 0, 233, 234, 235, + 236, 237, 0, 0, 0, 238, 239, 240, 241, 0, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 0, + 0, 250, 251, 0, 0, 0, 0, 0, 0, 0, + 252, 253, 254, 255, 256, 257, 258, 259, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 272, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 284, 285, 286, 287, 288, 0, 289, 0, 290, 291, + 292, 0, 293, 0, 294, 0, 0, 0, 295, 296, + 297, 0, 298, 299, 2793, 300, 0, 301, 302, 303, + 304, 305, 0, 306, 307, 308, 0, 309, 310, 311, + 312, 313, 314, 0, 315, 0, 316, 317, 318, 319, + 320, 321, 322, 0, 323, 0, 324, 0, 0, 325, + 0, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 334, 0, 335, 0, 0, 336, 337, 338, 0, 0, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 351, 0, 352, 353, 354, 355, 0, 356, + 357, 0, 358, 0, 359, 360, 361, 362, 363, 364, + 0, 365, 0, 0, 366, 367, 368, 0, 0, 369, + 0, 0, 0, 370, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 379, 380, 381, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 0, 409, 410, 411, + 412, 413, 414, 415, 416, 417, 418, 419, 0, 420, + 421, 422, 423, 424, 0, 425, 426, 427, 428, 0, + 429, 430, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 442, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 451, 452, 0, 0, + 453, 454, 455, 456, 0, 457, 458, 459, 460, 461, + 462, 463, 0, 0, 464, 465, 466, 467, 468, 0, + 0, 469, 470, 471, 472, 473, 474, 475, 0, 476, + 0, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 485, 486, 487, 488, 489, 490, 491, + 492, 493, 494, 495, 496, 497, 199, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 200, 201, 202, + 203, 204, 205, 206, 207, 0, 209, 210, 211, 0, + 0, 0, 0, 0, 3397, 0, 212, 213, 0, 214, + 215, 0, 216, 217, 218, 219, 220, 0, 221, 222, + 0, 223, 224, 225, 226, 227, 0, 0, 228, 229, + 230, 231, 232, 0, 233, 234, 235, 236, 237, 0, + 0, 0, 238, 239, 240, 241, 0, 242, 243, 0, + 244, 245, 246, 247, 248, 249, 0, 0, 250, 251, + 0, 0, 0, 0, 0, 0, 0, 252, 253, 254, + 255, 256, 257, 258, 259, 260, 0, 261, 0, 262, + 263, 264, 265, 266, 0, 267, 268, 269, 0, 0, + 270, 271, 272, 273, 274, 0, 275, 276, 277, 0, + 278, 279, 0, 280, 281, 282, 283, 284, 285, 286, + 287, 288, 0, 289, 0, 290, 291, 292, 0, 293, + 0, 294, 0, 0, 0, 295, 296, 297, 0, 298, + 299, 0, 300, 0, 301, 302, 303, 304, 305, 0, + 306, 307, 308, 0, 309, 310, 311, 312, 313, 314, + 0, 315, 0, 316, 317, 318, 319, 320, 321, 322, + 0, 323, 0, 324, 0, 0, 325, 0, 326, 327, + 328, 329, 330, 331, 332, 0, 333, 334, 0, 335, + 0, 0, 336, 337, 338, 0, 0, 339, 340, 341, + 342, 343, 344, 345, 346, 347, 348, 349, 350, 351, + 0, 352, 353, 354, 355, 0, 356, 357, 0, 358, + 0, 359, 360, 361, 362, 363, 364, 0, 365, 0, + 0, 366, 367, 368, 0, 0, 369, 0, 0, 0, + 370, 371, 372, 373, 374, 375, 376, 377, 0, 378, + 379, 380, 381, 382, 383, 384, 0, 385, 386, 387, + 388, 389, 390, 391, 392, 393, 394, 395, 396, 0, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 0, 407, 408, 0, 409, 410, 411, 412, 413, 414, + 415, 416, 417, 418, 419, 0, 420, 421, 422, 423, + 424, 0, 425, 426, 427, 428, 0, 429, 430, 431, + 0, 432, 433, 434, 435, 436, 437, 438, 439, 440, + 441, 442, 0, 443, 444, 0, 445, 446, 447, 448, + 449, 450, 0, 451, 452, 0, 0, 453, 454, 455, + 456, 0, 457, 458, 459, 460, 461, 462, 463, 0, + 0, 464, 465, 466, 467, 468, 0, 0, 469, 470, + 471, 472, 473, 474, 475, 0, 476, 0, 477, 478, + 479, 0, 0, 480, 0, 0, 481, 482, 483, 484, + 485, 486, 487, 488, 489, 490, 491, 492, 493, 494, + 495, 496, 497, 199, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 200, 201, 202, 203, 204, 205, + 206, 207, 0, 209, 210, 211, 0, 0, 0, 0, + 0, 3410, 0, 212, 213, 0, 214, 215, 0, 216, + 217, 218, 219, 220, 0, 221, 222, 0, 223, 224, + 225, 226, 227, 0, 0, 228, 229, 230, 231, 232, + 0, 233, 234, 235, 236, 237, 0, 0, 0, 238, + 239, 240, 241, 0, 242, 243, 0, 244, 245, 246, + 247, 248, 249, 0, 0, 250, 251, 0, 0, 0, + 0, 0, 0, 0, 252, 253, 254, 255, 256, 257, + 258, 259, 260, 0, 261, 0, 262, 263, 264, 265, + 266, 0, 267, 268, 269, 0, 0, 270, 271, 272, + 273, 274, 0, 275, 276, 277, 0, 278, 279, 0, + 280, 281, 282, 283, 284, 285, 286, 287, 288, 0, + 289, 0, 290, 291, 292, 0, 293, 0, 294, 0, + 0, 0, 295, 296, 297, 0, 298, 299, 0, 300, + 0, 301, 302, 303, 304, 305, 0, 306, 307, 308, + 0, 309, 310, 311, 312, 313, 314, 0, 315, 0, + 316, 317, 318, 319, 320, 321, 322, 0, 323, 0, + 324, 0, 0, 325, 0, 326, 327, 328, 329, 330, + 331, 332, 0, 333, 334, 0, 335, 0, 0, 336, + 337, 338, 0, 0, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 351, 0, 352, 353, + 354, 355, 0, 356, 357, 0, 358, 0, 359, 360, + 361, 362, 363, 364, 0, 365, 0, 0, 366, 367, + 368, 0, 0, 369, 0, 0, 0, 370, 371, 372, + 373, 374, 375, 376, 377, 0, 378, 379, 380, 381, + 382, 383, 384, 0, 385, 386, 387, 388, 389, 390, + 391, 392, 393, 394, 395, 396, 0, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 0, 407, 408, + 0, 409, 410, 411, 412, 413, 414, 415, 416, 417, + 418, 419, 0, 420, 421, 422, 423, 424, 0, 425, + 426, 427, 428, 0, 429, 430, 431, 0, 432, 433, + 434, 435, 436, 437, 438, 439, 440, 441, 442, 0, + 443, 444, 0, 445, 446, 447, 448, 449, 450, 0, + 451, 452, 0, 0, 453, 454, 455, 456, 0, 457, + 458, 459, 460, 461, 462, 463, 0, 0, 464, 465, + 466, 467, 468, 0, 0, 469, 470, 471, 472, 473, + 474, 475, 0, 476, 0, 477, 478, 479, 0, 0, + 480, 0, 0, 481, 482, 483, 484, 485, 486, 487, + 488, 489, 490, 491, 492, 493, 494, 495, 496, 497, + 199, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 200, 201, 202, 203, 204, 205, 206, 207, 0, + 209, 210, 211, 0, 0, 0, 0, 0, 0, 0, + 212, 213, 0, 214, 215, 0, 216, 217, 218, 219, + 220, 0, 221, 222, 0, 223, 224, 225, 226, 227, + 0, 0, 228, 229, 230, 231, 232, 0, 233, 234, + 235, 236, 237, 0, 0, 0, 238, 239, 240, 241, + 0, 242, 243, 0, 244, 245, 246, 247, 248, 249, + 0, 0, 250, 251, 0, 0, 0, 0, 0, 0, + 0, 252, 253, 254, 255, 256, 257, 258, 259, 260, + 3615, 261, 0, 262, 263, 264, 265, 266, 0, 267, + 268, 269, 0, 0, 270, 271, 272, 273, 274, 0, + 275, 276, 277, 0, 278, 279, 0, 280, 281, 282, + 283, 284, 285, 286, 287, 288, 0, 289, 0, 290, + 291, 292, 0, 293, 0, 294, 0, 0, 0, 295, + 296, 297, 0, 298, 299, 0, 300, 0, 301, 302, + 303, 304, 305, 0, 306, 307, 308, 0, 309, 310, + 311, 312, 313, 314, 0, 315, 0, 316, 317, 318, + 319, 320, 321, 322, 0, 323, 0, 324, 0, 0, + 325, 0, 326, 327, 328, 329, 330, 331, 332, 0, + 333, 334, 0, 335, 0, 0, 336, 337, 338, 0, + 0, 339, 340, 341, 342, 343, 344, 345, 346, 347, + 348, 349, 350, 351, 0, 352, 353, 354, 355, 0, + 356, 357, 0, 358, 0, 359, 360, 361, 362, 363, + 364, 0, 365, 0, 0, 366, 367, 368, 0, 0, + 369, 0, 0, 0, 370, 371, 372, 373, 374, 375, + 376, 377, 0, 378, 379, 380, 381, 382, 383, 384, + 0, 385, 386, 387, 388, 389, 390, 391, 392, 393, + 394, 395, 396, 0, 397, 398, 399, 400, 401, 402, + 403, 404, 405, 406, 0, 407, 408, 0, 409, 410, + 411, 412, 413, 414, 415, 416, 417, 418, 419, 0, + 420, 421, 422, 423, 424, 0, 425, 426, 427, 428, + 0, 429, 430, 431, 0, 432, 433, 434, 435, 436, + 437, 438, 439, 440, 441, 442, 0, 443, 444, 0, + 445, 446, 447, 448, 449, 450, 0, 451, 452, 0, + 0, 453, 454, 455, 456, 0, 457, 458, 459, 460, + 461, 462, 463, 0, 0, 464, 465, 466, 467, 468, + 0, 0, 469, 470, 471, 472, 473, 474, 475, 0, + 476, 0, 477, 478, 479, 0, 0, 480, 0, 0, + 481, 482, 483, 484, 485, 486, 487, 488, 489, 490, + 491, 492, 493, 494, 495, 496, 497, 199, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 200, 201, + 202, 203, 204, 205, 206, 207, 0, 209, 210, 211, + 0, 0, 0, 0, 0, 0, 0, 212, 213, 0, + 214, 215, 0, 216, 217, 218, 219, 220, 0, 221, + 222, 0, 223, 224, 225, 226, 227, 0, 0, 228, + 229, 230, 231, 232, 0, 233, 234, 235, 236, 237, + 0, 0, 0, 238, 239, 240, 241, 0, 242, 243, + 0, 244, 245, 246, 247, 248, 249, 0, 0, 250, + 251, 0, 0, 0, 0, 0, 0, 0, 252, 253, + 254, 255, 256, 257, 258, 259, 260, 3617, 261, 0, + 262, 263, 264, 265, 266, 0, 267, 268, 269, 0, + 0, 270, 271, 272, 273, 274, 0, 275, 276, 277, + 0, 278, 279, 0, 280, 281, 282, 283, 284, 285, + 286, 287, 288, 0, 289, 0, 290, 291, 292, 0, + 293, 0, 294, 0, 0, 0, 295, 296, 297, 0, + 298, 299, 0, 300, 0, 301, 302, 303, 304, 305, + 0, 306, 307, 308, 0, 309, 310, 311, 312, 313, + 314, 0, 315, 0, 316, 317, 318, 319, 320, 321, + 322, 0, 323, 0, 324, 0, 0, 325, 0, 326, + 327, 328, 329, 330, 331, 332, 0, 333, 334, 0, + 335, 0, 0, 336, 337, 338, 0, 0, 339, 340, + 341, 342, 343, 344, 345, 346, 347, 348, 349, 350, + 351, 0, 352, 353, 354, 355, 0, 356, 357, 0, + 358, 0, 359, 360, 361, 362, 363, 364, 0, 365, + 0, 0, 366, 367, 368, 0, 0, 369, 0, 0, + 0, 370, 371, 372, 373, 374, 375, 376, 377, 0, + 378, 379, 380, 381, 382, 383, 384, 0, 385, 386, + 387, 388, 389, 390, 391, 392, 393, 394, 395, 396, + 0, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 0, 407, 408, 0, 409, 410, 411, 412, 413, + 414, 415, 416, 417, 418, 419, 0, 420, 421, 422, + 423, 424, 0, 425, 426, 427, 428, 0, 429, 430, + 431, 0, 432, 433, 434, 435, 436, 437, 438, 439, + 440, 441, 442, 0, 443, 444, 0, 445, 446, 447, + 448, 449, 450, 0, 451, 452, 0, 0, 453, 454, + 455, 456, 0, 457, 458, 459, 460, 461, 462, 463, + 0, 0, 464, 465, 466, 467, 468, 0, 0, 469, + 470, 471, 472, 473, 474, 475, 0, 476, 0, 477, + 478, 479, 0, 0, 480, 0, 0, 481, 482, 483, + 484, 485, 486, 487, 488, 489, 490, 491, 492, 493, + 494, 495, 496, 497, 199, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 200, 201, 202, 203, 204, + 205, 206, 207, 0, 209, 210, 211, 0, 0, 0, + 0, 0, 0, 0, 212, 213, 0, 214, 215, 0, + 216, 217, 218, 219, 220, 0, 221, 222, 0, 223, + 224, 225, 226, 227, 0, 0, 228, 229, 230, 231, + 232, 0, 233, 234, 235, 236, 237, 0, 0, 0, + 238, 239, 240, 241, 0, 242, 243, 0, 244, 245, + 246, 247, 248, 249, 0, 0, 250, 251, 0, 0, + 0, 0, 0, 0, 0, 252, 253, 254, 255, 256, + 257, 258, 259, 260, 3619, 261, 0, 262, 263, 264, + 265, 266, 0, 267, 268, 269, 0, 0, 270, 271, + 272, 273, 274, 0, 275, 276, 277, 0, 278, 279, + 0, 280, 281, 282, 283, 284, 285, 286, 287, 288, + 0, 289, 0, 290, 291, 292, 0, 293, 0, 294, + 0, 0, 0, 295, 296, 297, 0, 298, 299, 0, + 300, 0, 301, 302, 303, 304, 305, 0, 306, 307, + 308, 0, 309, 310, 311, 312, 313, 314, 0, 315, + 0, 316, 317, 318, 319, 320, 321, 322, 0, 323, + 0, 324, 0, 0, 325, 0, 326, 327, 328, 329, + 330, 331, 332, 0, 333, 334, 0, 335, 0, 0, + 336, 337, 338, 0, 0, 339, 340, 341, 342, 343, + 344, 345, 346, 347, 348, 349, 350, 351, 0, 352, + 353, 354, 355, 0, 356, 357, 0, 358, 0, 359, + 360, 361, 362, 363, 364, 0, 365, 0, 0, 366, + 367, 368, 0, 0, 369, 0, 0, 0, 370, 371, + 372, 373, 374, 375, 376, 377, 0, 378, 379, 380, + 381, 382, 383, 384, 0, 385, 386, 387, 388, 389, + 390, 391, 392, 393, 394, 395, 396, 0, 397, 398, + 399, 400, 401, 402, 403, 404, 405, 406, 0, 407, + 408, 0, 409, 410, 411, 412, 413, 414, 415, 416, + 417, 418, 419, 0, 420, 421, 422, 423, 424, 0, + 425, 426, 427, 428, 0, 429, 430, 431, 0, 432, + 433, 434, 435, 436, 437, 438, 439, 440, 441, 442, + 0, 443, 444, 0, 445, 446, 447, 448, 449, 450, + 0, 451, 452, 0, 0, 453, 454, 455, 456, 0, + 457, 458, 459, 460, 461, 462, 463, 0, 0, 464, + 465, 466, 467, 468, 0, 0, 469, 470, 471, 472, + 473, 474, 475, 0, 476, 0, 477, 478, 479, 0, + 0, 480, 0, 0, 481, 482, 483, 484, 485, 486, + 487, 488, 489, 490, 491, 492, 493, 494, 495, 496, + 497, 199, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 200, 201, 202, 203, 204, 205, 206, 207, + 0, 209, 210, 211, 0, 0, 0, 0, 0, 0, + 0, 212, 213, 0, 214, 215, 0, 216, 217, 218, + 219, 220, 0, 221, 222, 0, 223, 224, 225, 226, + 227, 0, 0, 228, 229, 230, 231, 232, 0, 233, + 234, 235, 236, 237, 0, 0, 0, 238, 239, 240, + 241, 0, 242, 243, 0, 244, 245, 246, 247, 248, + 249, 0, 0, 250, 251, 0, 0, 0, 0, 0, + 0, 0, 252, 253, 254, 255, 256, 257, 258, 259, + 260, 0, 261, 0, 262, 263, 264, 265, 266, 0, + 267, 268, 269, 0, 0, 270, 271, 272, 273, 274, + 0, 275, 276, 277, 0, 278, 279, 0, 280, 281, + 282, 283, 284, 285, 286, 287, 288, 0, 289, 0, + 290, 291, 292, 0, 293, 0, 294, 0, 0, 0, + 295, 296, 297, 0, 298, 299, 0, 300, 0, 301, + 302, 303, 304, 305, 0, 306, 307, 308, 0, 309, + 310, 311, 312, 313, 314, 0, 315, 0, 316, 317, + 318, 319, 320, 321, 322, 0, 323, 0, 324, 0, + 0, 325, 0, 326, 327, 328, 329, 330, 331, 332, + 0, 333, 334, 0, 335, 0, 0, 336, 337, 338, + 0, 0, 339, 340, 341, 342, 343, 344, 345, 346, + 347, 348, 349, 350, 351, 0, 352, 353, 354, 355, + 0, 356, 357, 0, 358, 0, 359, 360, 361, 362, + 363, 364, 0, 365, 0, 0, 366, 367, 368, 0, + 0, 369, 0, 0, 0, 370, 371, 372, 373, 374, + 375, 376, 377, 0, 378, 379, 380, 381, 382, 383, + 384, 0, 385, 386, 387, 388, 389, 390, 391, 392, + 393, 394, 395, 396, 0, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 0, 407, 408, 0, 409, + 410, 411, 412, 413, 414, 415, 416, 417, 418, 419, + 0, 420, 421, 422, 423, 424, 0, 425, 426, 427, + 428, 0, 429, 430, 431, 0, 432, 433, 434, 435, + 436, 437, 438, 439, 440, 441, 442, 0, 443, 444, + 0, 445, 446, 447, 448, 449, 450, 0, 451, 452, + 0, 0, 453, 454, 455, 456, 0, 457, 458, 459, + 460, 461, 462, 463, 0, 0, 464, 465, 466, 467, + 468, 0, 3974, 469, 470, 471, 472, 473, 474, 475, + 0, 476, 0, 477, 478, 479, 0, 0, 480, 0, + 0, 481, 482, 483, 484, 485, 486, 487, 488, 489, + 490, 491, 492, 493, 494, 495, 496, 497, 199, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 200, + 201, 202, 203, 204, 205, 206, 207, 0, 209, 210, + 211, 0, 0, 0, 0, 0, 0, 0, 212, 213, + 0, 214, 215, 0, 216, 217, 218, 219, 220, 0, + 221, 222, 0, 223, 224, 225, 226, 227, 0, 0, + 228, 229, 230, 231, 232, 0, 233, 234, 235, 236, + 237, 0, 0, 0, 238, 239, 240, 241, 0, 242, + 243, 0, 244, 245, 246, 247, 248, 249, 0, 0, + 250, 251, 0, 0, 0, 0, 0, 0, 0, 252, + 253, 254, 255, 256, 257, 258, 259, 260, 0, 261, + 0, 262, 263, 264, 265, 266, 0, 267, 268, 269, + 0, 0, 270, 271, 272, 273, 274, 0, 275, 276, + 277, 0, 278, 279, 0, 280, 281, 282, 283, 284, + 285, 286, 287, 288, 0, 289, 0, 290, 291, 292, + 0, 293, 0, 294, 0, 0, 0, 295, 296, 297, + 0, 298, 299, 0, 300, 0, 301, 302, 303, 304, + 305, 0, 306, 307, 308, 0, 309, 310, 311, 312, + 313, 314, 0, 315, 0, 316, 317, 318, 319, 320, + 321, 322, 0, 323, 0, 324, 0, 0, 325, 0, + 326, 327, 328, 329, 330, 331, 332, 0, 333, 334, + 0, 335, 0, 0, 336, 337, 338, 0, 0, 339, + 340, 341, 342, 343, 344, 345, 346, 347, 348, 349, + 350, 351, 0, 352, 353, 354, 355, 0, 356, 357, + 0, 358, 0, 359, 360, 361, 362, 363, 364, 0, + 365, 0, 0, 366, 367, 368, 0, 0, 369, 0, + 0, 0, 370, 371, 372, 373, 374, 375, 376, 377, + 0, 378, 379, 380, 381, 382, 383, 384, 0, 385, + 386, 387, 388, 389, 390, 391, 392, 393, 394, 395, + 396, 0, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 0, 407, 408, 0, 409, 410, 411, 412, + 413, 414, 415, 416, 417, 418, 419, 0, 420, 421, + 422, 423, 424, 0, 425, 426, 427, 428, 0, 429, + 430, 431, 0, 432, 433, 434, 435, 436, 437, 438, + 439, 440, 441, 442, 0, 443, 444, 0, 445, 446, + 447, 448, 449, 450, 0, 451, 452, 0, 0, 453, + 454, 455, 456, 0, 457, 458, 459, 460, 461, 462, + 463, 0, 0, 464, 465, 466, 467, 468, 0, 0, + 469, 470, 471, 472, 473, 474, 475, 0, 476, 0, + 477, 478, 479, 0, 0, 480, 0, 0, 481, 482, + 483, 484, 485, 486, 487, 488, 489, 490, 491, 492, + 493, 494, 495, 496, 497, 199, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 200, 201, 202, 203, + 204, 205, 206, 207, 0, 209, 210, 211, 0, 0, + 0, 0, 0, 0, 0, 212, 213, 0, 214, 215, + 0, 216, 217, 218, 219, 220, 0, 221, 222, 0, + 223, 224, 225, 226, 227, 0, 0, 228, 229, 230, + 231, 232, 0, 233, 234, 235, 236, 237, 0, 0, + 0, 238, 239, 240, 241, 0, 242, 243, 0, 244, + 245, 246, 247, 248, 249, 0, 0, 250, 251, 0, + 0, 0, 0, 0, 0, 0, 252, 253, 254, 255, + 256, 257, 258, 259, 260, 0, 261, 0, 262, 263, + 264, 265, 266, 0, 267, 268, 269, 0, 0, 270, + 271, 272, 273, 274, 0, 275, 276, 277, 0, 278, + 279, 0, 280, 281, 282, 283, 284, 285, 286, 287, + 288, 0, 289, 0, 290, 291, 292, 0, 293, 0, + 294, 0, 0, 0, 295, 296, 297, 0, 298, 299, + 0, 300, 0, 301, 302, 303, 304, 305, 0, 306, + 307, 308, 0, 309, 310, 311, 312, 313, 314, 0, + 315, 0, 316, 317, 318, 319, 320, 321, 322, 0, + 323, 0, 324, 0, 0, 325, 0, 326, 327, 328, + 329, 330, 331, 332, 0, 333, 334, 0, 335, 0, + 0, 336, 337, 338, 0, 0, 339, 340, 341, 342, + 343, 344, 345, 346, 347, 348, 349, 350, 351, 0, + 352, 353, 354, 355, 0, 356, 357, 0, 358, 0, + 359, 360, 361, 362, 363, 364, 0, 365, 0, 0, + 366, 367, 368, 0, 0, 369, 0, 0, 0, 370, + 371, 372, 373, 374, 375, 376, 377, 0, 378, 379, + 380, 381, 382, 383, 384, 0, 385, 386, 387, 388, + 389, 390, 391, 392, 393, 394, 395, 396, 0, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 0, + 407, 408, 0, 409, 410, 411, 412, 413, 414, 415, + 416, 417, 418, 419, 0, 420, 421, 422, 423, 424, + 0, 425, 426, 427, 428, 0, 429, 430, 431, 0, + 432, 433, 434, 435, 436, 437, 438, 439, 440, 441, + 442, 0, 443, 444, 0, 445, 446, 447, 448, 449, + 450, 0, 451, 452, 0, 0, 631, 454, 455, 456, + 0, 457, 458, 459, 460, 461, 462, 463, 0, 0, + 464, 465, 466, 467, 468, 0, 0, 469, 470, 471, + 472, 473, 474, 475, 0, 476, 0, 477, 478, 479, + 0, 0, 480, 0, 0, 481, 482, 483, 484, 485, + 486, 487, 488, 489, 490, 491, 492, 493, 494, 495, + 496, 497, 199, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 200, 201, 202, 203, 204, 205, 206, + 207, 0, 209, 210, 211, 0, 0, 0, 0, 0, + 0, 0, 212, 213, 0, 214, 215, 0, 216, 217, + 218, 219, 220, 0, 221, 222, 0, 223, 224, 225, + 226, 227, 0, 0, 228, 229, 230, 231, 232, 0, + 233, 234, 235, 236, 237, 0, 0, 0, 238, 239, + 240, 241, 0, 242, 243, 0, 244, 245, 246, 247, + 248, 249, 0, 0, 250, 251, 0, 0, 0, 0, + 0, 0, 0, 252, 253, 254, 255, 256, 257, 258, + 259, 260, 0, 261, 0, 262, 263, 264, 265, 266, + 0, 267, 268, 269, 0, 0, 270, 271, 272, 273, + 274, 0, 275, 276, 277, 0, 278, 279, 0, 280, + 281, 282, 283, 284, 285, 286, 287, 288, 0, 289, + 0, 290, 291, 292, 0, 293, 0, 294, 0, 0, + 0, 295, 296, 297, 0, 298, 299, 0, 300, 0, + 301, 302, 303, 304, 305, 0, 306, 307, 308, 0, + 309, 310, 311, 312, 313, 314, 0, 315, 0, 316, + 317, 318, 319, 320, 321, 322, 0, 323, 0, 324, + 0, 0, 325, 0, 326, 327, 328, 329, 330, 331, + 332, 0, 333, 334, 0, 335, 0, 0, 336, 337, + 338, 0, 0, 339, 340, 341, 342, 343, 344, 345, + 346, 347, 348, 349, 350, 351, 0, 352, 353, 354, + 355, 0, 356, 357, 0, 358, 0, 359, 360, 361, + 362, 363, 364, 0, 365, 0, 0, 366, 367, 368, + 0, 0, 369, 0, 0, 0, 370, 371, 372, 373, + 374, 375, 376, 377, 0, 378, 379, 380, 381, 382, + 383, 384, 0, 385, 386, 387, 388, 389, 390, 391, + 392, 393, 394, 395, 396, 0, 397, 398, 399, 400, + 401, 402, 403, 404, 405, 406, 0, 407, 408, 0, + 409, 410, 411, 412, 413, 639, 415, 416, 417, 418, + 419, 0, 420, 421, 422, 423, 424, 0, 425, 426, + 427, 428, 0, 429, 430, 431, 0, 432, 433, 434, + 435, 436, 437, 438, 439, 440, 441, 442, 0, 443, + 444, 0, 445, 446, 447, 448, 449, 450, 0, 451, + 452, 0, 0, 453, 454, 455, 456, 0, 457, 458, + 459, 460, 461, 462, 463, 0, 0, 464, 465, 466, + 467, 468, 0, 0, 469, 470, 471, 472, 473, 474, + 475, 0, 476, 0, 477, 478, 479, 0, 0, 480, + 0, 0, 481, 482, 483, 484, 485, 486, 487, 488, + 489, 490, 491, 492, 493, 494, 495, 496, 497, 199, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 0, 0, 0, 212, + 213, 0, 214, 215, 0, 216, 217, 218, 219, 220, + 0, 221, 222, 0, 223, 224, 225, 226, 227, 0, + 0, 658, 229, 230, 231, 232, 0, 233, 234, 235, + 236, 237, 0, 0, 0, 238, 239, 240, 241, 0, + 242, 243, 0, 659, 245, 246, 247, 248, 249, 0, + 0, 250, 251, 0, 0, 0, 0, 0, 0, 0, + 252, 253, 254, 255, 256, 257, 258, 259, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 272, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 284, 285, 286, 287, 288, 0, 289, 0, 290, 291, + 292, 0, 293, 0, 294, 0, 0, 0, 295, 296, + 297, 0, 298, 299, 0, 300, 0, 301, 302, 303, + 304, 305, 0, 306, 307, 308, 0, 309, 310, 311, + 312, 313, 314, 0, 315, 0, 316, 317, 318, 319, + 320, 321, 322, 0, 323, 0, 324, 0, 0, 325, + 0, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 334, 0, 335, 0, 0, 336, 337, 660, 0, 0, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 661, 351, 0, 352, 353, 354, 355, 0, 356, + 357, 0, 358, 0, 359, 360, 361, 362, 363, 364, + 0, 365, 0, 0, 366, 367, 368, 0, 0, 369, + 0, 0, 0, 370, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 379, 380, 381, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 0, 662, 410, 411, + 412, 413, 414, 663, 416, 417, 418, 419, 0, 420, + 421, 422, 423, 664, 0, 425, 426, 427, 428, 0, + 429, 430, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 442, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 665, 452, 0, 0, + 666, 454, 455, 456, 0, 457, 458, 459, 460, 461, + 462, 463, 0, 0, 464, 465, 466, 467, 468, 0, + 0, 469, 470, 471, 472, 473, 474, 475, 0, 476, + 0, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 667, 486, 487, 488, 489, 490, 491, + 492, 493, 494, 495, 496, 497, 199, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 200, 201, 202, + 203, 204, 205, 206, 207, 0, 209, 210, 211, 0, + 0, 0, 0, 0, 0, 0, 212, 213, 0, 214, + 215, 0, 216, 217, 218, 219, 220, 0, 221, 222, + 0, 223, 224, 225, 226, 227, 0, 0, 228, 229, + 230, 231, 232, 0, 233, 234, 235, 236, 237, 0, + 0, 0, 238, 239, 240, 241, 0, 242, 243, 0, + 244, 245, 246, 247, 248, 249, 0, 0, 250, 251, + 0, 0, 0, 0, 0, 0, 0, 252, 253, 254, + 255, 256, 257, 258, 259, 260, 0, 261, 0, 262, + 263, 264, 265, 266, 0, 267, 268, 269, 0, 0, + 270, 271, 272, 273, 274, 0, 275, 276, 277, 0, + 278, 279, 0, 280, 281, 282, 283, 284, 285, 286, + 287, 288, 0, 289, 0, 290, 291, 292, 0, 293, + 0, 294, 0, 0, 0, 295, 296, 297, 0, 298, + 299, 0, 300, 0, 301, 302, 303, 304, 305, 0, + 306, 307, 308, 0, 309, 310, 311, 312, 313, 314, + 0, 315, 0, 316, 317, 318, 319, 320, 321, 322, + 0, 323, 0, 324, 0, 0, 325, 0, 326, 327, + 328, 329, 330, 331, 332, 0, 333, 334, 0, 335, + 0, 0, 336, 337, 338, 0, 0, 339, 340, 341, + 342, 343, 344, 345, 346, 347, 348, 349, 350, 351, + 0, 352, 353, 354, 355, 0, 356, 357, 0, 358, + 0, 359, 360, 361, 362, 363, 364, 0, 365, 0, + 0, 366, 367, 368, 0, 0, 369, 0, 0, 0, + 370, 371, 372, 373, 374, 375, 376, 377, 0, 378, + 379, 380, 381, 382, 383, 384, 0, 385, 386, 387, + 388, 389, 390, 391, 392, 393, 394, 689, 396, 0, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 0, 407, 408, 0, 409, 410, 411, 412, 413, 414, + 415, 416, 417, 418, 419, 0, 420, 421, 422, 423, + 424, 0, 425, 426, 427, 428, 0, 429, 430, 431, + 0, 432, 433, 434, 435, 436, 437, 438, 439, 440, + 441, 442, 0, 443, 444, 0, 445, 446, 447, 448, + 449, 450, 0, 451, 452, 0, 0, 453, 454, 455, + 456, 0, 457, 458, 459, 460, 461, 462, 463, 0, + 0, 464, 465, 466, 467, 468, 0, 0, 469, 470, + 471, 472, 473, 474, 475, 0, 476, 0, 477, 478, + 479, 0, 0, 480, 0, 0, 481, 482, 483, 484, + 485, 486, 487, 488, 489, 490, 491, 492, 493, 494, + 495, 496, 497, 199, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 200, 201, 202, 203, 204, 205, + 206, 207, 0, 209, 210, 211, 0, 0, 0, 0, + 0, 0, 0, 212, 213, 0, 214, 215, 0, 216, + 217, 218, 219, 220, 0, 221, 222, 0, 223, 224, + 225, 226, 227, 0, 0, 228, 229, 230, 231, 232, + 0, 233, 234, 235, 236, 237, 0, 0, 0, 238, + 239, 240, 241, 0, 242, 243, 0, 244, 245, 246, + 247, 248, 249, 0, 0, 250, 251, 0, 0, 0, + 0, 0, 0, 0, 252, 253, 254, 255, 256, 257, + 258, 259, 260, 0, 261, 0, 262, 263, 264, 265, + 266, 0, 267, 268, 269, 0, 0, 270, 271, 272, + 273, 274, 0, 275, 276, 277, 0, 278, 279, 0, + 280, 281, 282, 283, 284, 285, 286, 287, 288, 0, + 289, 0, 290, 291, 292, 0, 293, 0, 294, 0, + 0, 0, 295, 296, 297, 0, 298, 299, 0, 300, + 0, 301, 302, 303, 304, 757, 0, 306, 307, 308, + 0, 309, 310, 311, 312, 313, 314, 0, 315, 0, + 316, 317, 318, 319, 320, 321, 322, 0, 323, 0, + 324, 0, 0, 325, 0, 326, 327, 328, 329, 330, + 331, 332, 0, 333, 334, 0, 335, 0, 0, 336, + 337, 338, 0, 0, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 351, 0, 352, 353, + 354, 355, 0, 356, 357, 0, 358, 0, 359, 360, + 361, 362, 363, 364, 0, 365, 0, 0, 366, 367, + 368, 0, 0, 369, 0, 0, 0, 370, 371, 372, + 373, 374, 375, 376, 377, 0, 378, 379, 380, 381, + 382, 383, 384, 0, 385, 386, 387, 388, 389, 390, + 391, 392, 393, 394, 395, 396, 0, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 0, 407, 408, + 0, 409, 410, 411, 412, 413, 414, 415, 416, 417, + 418, 419, 0, 420, 421, 422, 423, 424, 0, 425, + 426, 427, 428, 0, 429, 430, 431, 0, 432, 433, + 434, 435, 436, 437, 438, 439, 440, 441, 442, 0, + 443, 444, 0, 445, 446, 447, 448, 449, 450, 0, + 451, 452, 0, 0, 453, 454, 455, 456, 0, 457, + 458, 459, 460, 461, 462, 463, 0, 0, 464, 465, + 466, 467, 468, 0, 0, 469, 470, 471, 472, 473, + 474, 475, 0, 476, 0, 477, 478, 479, 0, 0, + 480, 0, 0, 481, 482, 483, 484, 485, 486, 487, + 488, 489, 490, 491, 492, 493, 494, 495, 496, 497, + 199, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 200, 201, 202, 203, 204, 205, 206, 207, 0, + 209, 210, 211, 0, 0, 0, 0, 0, 0, 0, + 212, 213, 0, 214, 215, 0, 216, 217, 218, 219, + 220, 0, 221, 222, 0, 223, 224, 225, 226, 227, + 0, 0, 228, 229, 230, 231, 232, 0, 233, 234, + 235, 236, 237, 0, 0, 0, 238, 239, 240, 241, + 0, 242, 243, 0, 244, 245, 246, 247, 248, 249, + 0, 0, 250, 251, 0, 0, 0, 0, 0, 0, + 0, 252, 253, 254, 255, 256, 257, 258, 259, 260, + 0, 261, 0, 262, 263, 264, 265, 266, 0, 267, + 268, 269, 0, 0, 270, 271, 272, 273, 274, 0, + 275, 276, 277, 0, 278, 279, 0, 280, 281, 282, + 283, 284, 285, 286, 287, 288, 0, 289, 0, 290, + 291, 292, 0, 293, 0, 294, 0, 0, 0, 295, + 296, 297, 0, 298, 299, 0, 300, 0, 301, 302, + 303, 304, 778, 0, 306, 307, 308, 0, 309, 310, + 311, 312, 313, 314, 0, 315, 0, 316, 317, 318, + 319, 320, 321, 322, 0, 323, 0, 324, 0, 0, + 325, 0, 326, 327, 328, 329, 330, 331, 332, 0, + 333, 334, 0, 335, 0, 0, 336, 337, 338, 0, + 0, 339, 340, 341, 342, 343, 344, 345, 346, 347, + 348, 349, 350, 351, 0, 352, 353, 354, 355, 0, + 356, 357, 0, 358, 0, 359, 360, 361, 362, 363, + 364, 0, 365, 0, 0, 366, 367, 368, 0, 0, + 369, 0, 0, 0, 370, 371, 372, 373, 374, 375, + 376, 377, 0, 378, 379, 380, 381, 382, 383, 384, + 0, 385, 386, 387, 388, 389, 390, 391, 392, 393, + 394, 395, 396, 0, 397, 398, 399, 400, 401, 402, + 403, 404, 405, 406, 0, 407, 408, 0, 409, 410, + 411, 412, 413, 414, 415, 416, 417, 418, 419, 0, + 420, 421, 422, 423, 424, 0, 425, 426, 427, 428, + 0, 429, 430, 431, 0, 432, 433, 434, 435, 436, + 437, 438, 439, 440, 441, 442, 0, 443, 444, 0, + 445, 446, 447, 448, 449, 450, 0, 451, 452, 0, + 0, 453, 454, 455, 456, 0, 457, 458, 459, 460, + 461, 462, 463, 0, 0, 464, 465, 466, 467, 468, + 0, 0, 469, 470, 471, 472, 473, 474, 475, 0, + 476, 0, 477, 478, 479, 0, 0, 480, 0, 0, + 481, 482, 483, 484, 485, 486, 487, 488, 489, 490, + 491, 492, 493, 494, 495, 496, 497, 199, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 200, 201, + 202, 203, 204, 205, 206, 207, 0, 209, 210, 211, + 0, 0, 0, 0, 0, 0, 0, 212, 213, 0, + 214, 215, 0, 216, 217, 218, 219, 220, 0, 221, + 222, 0, 223, 224, 225, 226, 227, 0, 0, 228, + 229, 230, 231, 232, 0, 233, 234, 235, 236, 237, + 0, 0, 0, 238, 239, 240, 241, 0, 242, 243, + 0, 244, 245, 246, 247, 248, 249, 0, 0, 250, + 251, 0, 0, 0, 0, 0, 0, 0, 252, 253, + 254, 255, 256, 257, 258, 259, 260, 0, 261, 0, + 262, 263, 264, 265, 266, 0, 267, 268, 269, 0, + 0, 270, 271, 272, 273, 274, 0, 275, 276, 277, + 0, 278, 279, 0, 280, 281, 282, 283, 284, 285, + 286, 287, 288, 0, 289, 0, 290, 291, 292, 0, + 293, 0, 294, 0, 0, 0, 295, 296, 297, 0, + 298, 299, 0, 300, 0, 301, 302, 303, 304, 305, + 0, 306, 307, 308, 0, 309, 310, 311, 312, 313, + 314, 0, 315, 0, 316, 317, 318, 319, 320, 321, + 322, 0, 323, 0, 324, 0, 0, 325, 0, 326, + 327, 328, 329, 330, 331, 332, 0, 333, 334, 0, + 335, 0, 0, 336, 337, 338, 0, 0, 339, 340, + 787, 342, 343, 344, 345, 346, 347, 348, 349, 350, + 351, 0, 352, 353, 354, 355, 0, 356, 357, 0, + 358, 0, 359, 360, 361, 362, 363, 364, 0, 365, + 0, 0, 366, 367, 368, 0, 0, 369, 0, 0, + 0, 370, 371, 372, 373, 374, 375, 376, 377, 0, + 378, 379, 380, 381, 382, 383, 384, 0, 385, 386, + 387, 388, 389, 390, 391, 392, 393, 394, 395, 396, + 0, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 0, 407, 408, 0, 409, 410, 411, 412, 413, + 414, 415, 416, 417, 418, 419, 0, 420, 421, 422, + 423, 424, 0, 425, 426, 427, 428, 0, 429, 430, + 431, 0, 432, 433, 434, 435, 436, 437, 438, 439, + 440, 441, 442, 0, 443, 444, 0, 445, 446, 447, + 448, 449, 450, 0, 451, 452, 0, 0, 453, 454, + 455, 456, 0, 457, 458, 459, 460, 461, 462, 463, + 0, 0, 464, 465, 466, 467, 468, 0, 0, 469, + 470, 471, 472, 473, 474, 475, 0, 476, 0, 477, + 478, 479, 0, 0, 480, 0, 0, 481, 482, 483, + 484, 485, 486, 487, 488, 489, 490, 491, 492, 493, + 494, 495, 496, 497, 199, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 200, 201, 202, 203, 204, + 205, 206, 207, 0, 209, 210, 211, 0, 0, 0, + 0, 0, 0, 0, 212, 213, 0, 214, 215, 0, + 216, 217, 218, 219, 220, 0, 221, 222, 0, 223, + 224, 225, 226, 227, 0, 0, 228, 229, 230, 231, + 232, 0, 233, 234, 235, 236, 237, 0, 0, 0, + 238, 239, 240, 241, 0, 242, 243, 0, 244, 245, + 246, 247, 248, 249, 0, 0, 250, 251, 0, 0, + 0, 0, 0, 0, 0, 252, 253, 254, 255, 256, + 257, 258, 259, 260, 0, 261, 0, 262, 263, 264, + 265, 266, 0, 267, 268, 269, 0, 0, 270, 271, + 272, 273, 274, 0, 275, 276, 277, 0, 278, 279, + 0, 280, 281, 282, 283, 284, 285, 286, 287, 288, + 0, 289, 0, 290, 291, 292, 0, 293, 0, 294, + 0, 0, 0, 295, 296, 297, 0, 298, 299, 0, + 300, 0, 301, 302, 303, 304, 789, 0, 306, 307, + 308, 0, 309, 310, 311, 312, 313, 314, 0, 315, + 0, 316, 317, 318, 319, 320, 321, 322, 0, 323, + 0, 324, 0, 0, 325, 0, 326, 327, 328, 329, + 330, 331, 332, 0, 333, 334, 0, 335, 0, 0, + 336, 337, 338, 0, 0, 339, 340, 341, 342, 343, + 344, 345, 346, 347, 348, 349, 350, 351, 0, 352, + 353, 354, 355, 0, 356, 357, 0, 358, 0, 359, + 360, 361, 362, 363, 364, 0, 365, 0, 0, 366, + 367, 368, 0, 0, 369, 0, 0, 0, 370, 371, + 372, 373, 374, 375, 376, 377, 0, 378, 379, 380, + 381, 382, 383, 384, 0, 385, 386, 387, 388, 389, + 390, 391, 392, 393, 394, 395, 396, 0, 397, 398, + 399, 400, 401, 402, 403, 404, 405, 406, 0, 407, + 408, 0, 409, 410, 411, 412, 413, 414, 415, 416, + 417, 418, 419, 0, 420, 421, 422, 423, 424, 0, + 425, 426, 427, 428, 0, 429, 430, 431, 0, 432, + 433, 434, 435, 436, 437, 438, 439, 440, 441, 442, + 0, 443, 444, 0, 445, 446, 447, 448, 449, 450, + 0, 451, 452, 0, 0, 453, 454, 455, 456, 0, + 457, 458, 459, 460, 461, 462, 463, 0, 0, 464, + 465, 466, 467, 468, 0, 0, 469, 470, 471, 472, + 473, 474, 475, 0, 476, 0, 477, 478, 479, 0, + 0, 480, 0, 0, 481, 482, 483, 484, 485, 486, + 487, 488, 489, 490, 491, 492, 493, 494, 495, 496, + 497, 199, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 200, 201, 202, 203, 204, 205, 206, 207, + 0, 209, 210, 211, 0, 0, 0, 0, 0, 0, + 0, 212, 213, 0, 214, 215, 0, 216, 217, 218, + 219, 220, 0, 221, 222, 0, 223, 224, 225, 226, + 227, 0, 0, 228, 229, 230, 231, 232, 0, 233, + 234, 235, 236, 237, 0, 0, 0, 238, 239, 240, + 241, 0, 242, 243, 0, 244, 245, 246, 247, 248, + 249, 0, 0, 250, 251, 0, 0, 0, 0, 0, + 0, 0, 252, 253, 254, 255, 256, 257, 258, 259, + 260, 0, 261, 0, 262, 263, 264, 265, 266, 0, + 267, 268, 269, 0, 0, 270, 271, 272, 273, 274, + 0, 275, 276, 277, 0, 278, 279, 0, 280, 281, + 282, 283, 284, 285, 286, 287, 288, 0, 289, 0, + 290, 291, 292, 0, 293, 0, 294, 0, 0, 0, + 295, 296, 297, 0, 298, 299, 0, 300, 0, 301, + 302, 303, 304, 839, 0, 306, 307, 308, 0, 309, + 310, 311, 312, 313, 314, 0, 315, 0, 316, 317, + 318, 319, 320, 321, 322, 0, 323, 0, 324, 0, + 0, 325, 0, 326, 327, 328, 329, 330, 331, 332, + 0, 333, 334, 0, 335, 0, 0, 336, 337, 338, + 0, 0, 339, 340, 341, 342, 343, 344, 345, 346, + 347, 348, 349, 350, 351, 0, 352, 353, 354, 355, + 0, 356, 357, 0, 358, 0, 359, 360, 361, 362, + 363, 364, 0, 365, 0, 0, 366, 367, 368, 0, + 0, 369, 0, 0, 0, 370, 371, 372, 373, 374, + 375, 376, 377, 0, 378, 379, 380, 381, 382, 383, + 384, 0, 385, 386, 387, 388, 389, 390, 391, 392, + 393, 394, 395, 396, 0, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 0, 407, 408, 0, 409, + 410, 411, 412, 413, 414, 415, 416, 417, 418, 419, + 0, 420, 421, 422, 423, 424, 0, 425, 426, 427, + 428, 0, 429, 430, 431, 0, 432, 433, 434, 435, + 436, 437, 438, 439, 440, 441, 442, 0, 443, 444, + 0, 445, 446, 447, 448, 449, 450, 0, 451, 452, + 0, 0, 453, 454, 455, 456, 0, 457, 458, 459, + 460, 461, 462, 463, 0, 0, 464, 465, 466, 467, + 468, 0, 0, 469, 470, 471, 472, 473, 474, 475, + 0, 476, 0, 477, 478, 479, 0, 0, 480, 0, + 0, 481, 482, 483, 484, 485, 486, 487, 488, 489, + 490, 491, 492, 493, 494, 495, 496, 497, 199, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 200, + 201, 202, 203, 204, 205, 206, 207, 0, 209, 210, + 211, 0, 0, 0, 0, 0, 0, 0, 212, 213, + 0, 214, 215, 0, 216, 217, 218, 219, 220, 0, + 221, 222, 0, 223, 224, 225, 226, 227, 0, 0, + 228, 229, 230, 231, 232, 0, 233, 234, 235, 236, + 237, 0, 0, 0, 238, 239, 240, 241, 0, 242, + 243, 0, 244, 245, 246, 247, 248, 249, 0, 0, + 250, 251, 0, 0, 0, 0, 0, 0, 0, 252, + 253, 254, 255, 256, 257, 258, 259, 260, 0, 261, + 0, 262, 263, 264, 265, 266, 0, 267, 268, 269, + 0, 0, 270, 271, 272, 273, 274, 0, 275, 276, + 277, 0, 278, 279, 0, 280, 281, 282, 283, 284, + 285, 286, 287, 288, 0, 289, 0, 290, 291, 292, + 0, 293, 0, 294, 0, 0, 0, 295, 296, 297, + 0, 298, 299, 0, 300, 0, 301, 302, 303, 304, + 305, 0, 306, 307, 308, 0, 309, 310, 311, 312, + 313, 314, 0, 315, 0, 316, 317, 318, 319, 320, + 321, 322, 0, 323, 0, 324, 0, 0, 325, 0, + 326, 327, 328, 329, 330, 331, 332, 0, 333, 334, + 0, 335, 0, 0, 336, 337, 338, 0, 0, 339, + 340, 860, 342, 343, 344, 345, 346, 347, 348, 349, + 350, 351, 0, 352, 353, 354, 355, 0, 356, 357, + 0, 358, 0, 359, 360, 361, 362, 363, 364, 0, + 365, 0, 0, 366, 367, 368, 0, 0, 369, 0, + 0, 0, 370, 371, 372, 373, 374, 375, 376, 377, + 0, 378, 379, 380, 381, 382, 383, 384, 0, 385, + 386, 387, 388, 389, 390, 391, 392, 393, 394, 395, + 396, 0, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 0, 407, 408, 0, 409, 410, 411, 412, + 413, 414, 415, 416, 417, 418, 419, 0, 420, 421, + 422, 423, 424, 0, 425, 426, 427, 428, 0, 429, + 430, 431, 0, 432, 433, 434, 435, 436, 437, 438, + 439, 440, 441, 442, 0, 443, 444, 0, 445, 446, + 447, 448, 449, 450, 0, 451, 452, 0, 0, 453, + 454, 455, 456, 0, 457, 458, 459, 460, 461, 462, + 463, 0, 0, 464, 465, 466, 467, 468, 0, 0, + 469, 470, 471, 472, 473, 474, 475, 0, 476, 0, + 477, 478, 479, 0, 0, 480, 0, 0, 481, 482, + 483, 484, 485, 486, 487, 488, 489, 490, 491, 492, + 493, 494, 495, 496, 497, 199, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 200, 201, 202, 203, + 204, 205, 206, 207, 0, 209, 210, 211, 0, 0, + 0, 0, 0, 0, 0, 212, 213, 0, 214, 215, + 0, 216, 217, 218, 219, 220, 0, 221, 222, 0, + 223, 224, 225, 226, 227, 0, 0, 228, 229, 230, + 231, 232, 0, 233, 234, 235, 236, 237, 0, 0, + 0, 238, 239, 240, 241, 0, 242, 243, 0, 244, + 245, 246, 247, 248, 249, 0, 0, 250, 251, 0, + 0, 0, 0, 0, 0, 0, 252, 253, 254, 255, + 256, 257, 258, 259, 260, 0, 261, 0, 262, 263, + 264, 265, 266, 0, 267, 268, 269, 0, 0, 270, + 271, 272, 273, 274, 0, 275, 276, 277, 0, 278, + 279, 0, 280, 281, 282, 283, 284, 285, 286, 287, + 288, 0, 289, 0, 290, 291, 292, 0, 293, 0, + 294, 0, 0, 0, 295, 296, 297, 0, 298, 299, + 0, 300, 0, 301, 302, 303, 304, 883, 0, 306, + 307, 308, 0, 309, 310, 311, 312, 313, 314, 0, + 315, 0, 316, 317, 318, 319, 320, 321, 322, 0, + 323, 0, 324, 0, 0, 325, 0, 326, 327, 328, + 329, 330, 331, 332, 0, 333, 334, 0, 335, 0, + 0, 336, 337, 338, 0, 0, 339, 340, 341, 342, + 343, 344, 345, 346, 347, 348, 349, 350, 351, 0, + 352, 353, 354, 355, 0, 356, 357, 0, 358, 0, + 359, 360, 361, 362, 363, 364, 0, 365, 0, 0, + 366, 367, 368, 0, 0, 369, 0, 0, 0, 370, + 371, 372, 373, 374, 375, 376, 377, 0, 378, 379, + 380, 381, 382, 383, 384, 0, 385, 386, 387, 388, + 389, 390, 391, 392, 393, 394, 395, 396, 0, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 0, + 407, 408, 0, 409, 410, 411, 412, 413, 414, 415, + 416, 417, 418, 419, 0, 420, 421, 422, 423, 424, + 0, 425, 426, 427, 428, 0, 429, 430, 431, 0, + 432, 433, 434, 435, 436, 437, 438, 439, 440, 441, + 442, 0, 443, 444, 0, 445, 446, 447, 448, 449, + 450, 0, 451, 452, 0, 0, 453, 454, 455, 456, + 0, 457, 458, 459, 460, 461, 462, 463, 0, 0, + 464, 465, 466, 467, 468, 0, 0, 469, 470, 471, + 472, 473, 474, 475, 0, 476, 0, 477, 478, 479, + 0, 0, 480, 0, 0, 481, 482, 483, 484, 485, + 486, 487, 488, 489, 490, 491, 492, 493, 494, 495, + 496, 497, 199, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 200, 201, 202, 203, 204, 205, 206, + 207, 0, 209, 210, 211, 0, 0, 0, 0, 0, + 0, 0, 212, 213, 0, 214, 215, 0, 216, 217, + 218, 219, 220, 0, 221, 222, 0, 223, 224, 225, + 226, 227, 0, 0, 228, 229, 230, 231, 232, 0, + 233, 234, 235, 236, 237, 0, 0, 0, 238, 239, + 240, 241, 0, 242, 243, 0, 244, 245, 246, 247, + 248, 249, 0, 0, 250, 251, 0, 0, 0, 0, + 0, 0, 0, 252, 253, 254, 255, 256, 257, 258, + 259, 260, 0, 261, 0, 262, 263, 264, 265, 266, + 0, 267, 268, 269, 0, 0, 270, 271, 272, 273, + 274, 0, 275, 276, 277, 0, 278, 279, 0, 280, + 281, 282, 283, 284, 285, 286, 287, 288, 0, 289, + 0, 290, 291, 292, 0, 293, 0, 294, 0, 0, + 0, 295, 296, 297, 0, 298, 299, 0, 300, 0, + 301, 302, 303, 304, 889, 0, 306, 307, 308, 0, + 309, 310, 311, 312, 313, 314, 0, 315, 0, 316, + 317, 318, 319, 320, 321, 322, 0, 323, 0, 324, + 0, 0, 325, 0, 326, 327, 328, 329, 330, 331, + 332, 0, 333, 334, 0, 335, 0, 0, 336, 337, + 338, 0, 0, 339, 340, 341, 342, 343, 344, 345, + 346, 347, 348, 349, 350, 351, 0, 352, 353, 354, + 355, 0, 356, 357, 0, 358, 0, 359, 360, 361, + 362, 363, 364, 0, 365, 0, 0, 366, 367, 368, + 0, 0, 369, 0, 0, 0, 370, 371, 372, 373, + 374, 375, 376, 377, 0, 378, 379, 380, 381, 382, + 383, 384, 0, 385, 386, 387, 388, 389, 390, 391, + 392, 393, 394, 395, 396, 0, 397, 398, 399, 400, + 401, 402, 403, 404, 405, 406, 0, 407, 408, 0, + 409, 410, 411, 412, 413, 414, 415, 416, 417, 418, + 419, 0, 420, 421, 422, 423, 424, 0, 425, 426, + 427, 428, 0, 429, 430, 431, 0, 432, 433, 434, + 435, 436, 437, 438, 439, 440, 441, 442, 0, 443, + 444, 0, 445, 446, 447, 448, 449, 450, 0, 451, + 452, 0, 0, 453, 454, 455, 456, 0, 457, 458, + 459, 460, 461, 462, 463, 0, 0, 464, 465, 466, + 467, 468, 0, 0, 469, 470, 471, 472, 473, 474, + 475, 0, 476, 0, 477, 478, 479, 0, 0, 480, + 0, 0, 481, 482, 483, 484, 485, 486, 487, 488, + 489, 490, 491, 492, 493, 494, 495, 496, 497, 199, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 0, 0, 0, 212, + 213, 0, 214, 215, 0, 216, 217, 218, 219, 220, + 0, 221, 222, 0, 223, 224, 225, 226, 227, 0, + 0, 228, 229, 230, 231, 232, 0, 233, 234, 235, + 236, 237, 0, 0, 0, 238, 239, 240, 241, 0, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 0, + 0, 250, 251, 0, 0, 0, 0, 0, 0, 0, + 252, 253, 254, 255, 256, 257, 258, 259, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 272, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 284, 285, 286, 287, 288, 0, 289, 0, 290, 291, + 292, 0, 293, 0, 294, 0, 0, 0, 295, 296, + 297, 0, 298, 299, 0, 300, 0, 301, 302, 303, + 304, 898, 0, 306, 307, 308, 0, 309, 310, 311, + 312, 313, 314, 0, 315, 0, 316, 317, 318, 319, + 320, 321, 322, 0, 323, 0, 324, 0, 0, 325, + 0, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 334, 0, 335, 0, 0, 336, 337, 338, 0, 0, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 351, 0, 352, 353, 354, 355, 0, 356, + 357, 0, 358, 0, 359, 360, 361, 362, 363, 364, + 0, 365, 0, 0, 366, 367, 368, 0, 0, 369, + 0, 0, 0, 370, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 379, 380, 381, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 0, 409, 410, 411, + 412, 413, 414, 415, 416, 417, 418, 419, 0, 420, + 421, 422, 423, 424, 0, 425, 426, 427, 428, 0, + 429, 430, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 442, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 451, 452, 0, 0, + 453, 454, 455, 456, 0, 457, 458, 459, 460, 461, + 462, 463, 0, 0, 464, 465, 466, 467, 468, 0, + 0, 469, 470, 471, 472, 473, 474, 475, 0, 476, + 0, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 485, 486, 487, 488, 489, 490, 491, + 492, 493, 494, 495, 496, 497, 199, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 200, 201, 202, + 203, 204, 205, 206, 207, 0, 209, 210, 211, 0, + 0, 0, 0, 0, 0, 0, 212, 213, 0, 214, + 215, 0, 216, 217, 218, 219, 220, 0, 221, 222, + 0, 223, 224, 225, 226, 227, 0, 0, 228, 229, + 230, 231, 232, 0, 233, 234, 235, 236, 237, 0, + 0, 0, 238, 239, 240, 241, 0, 242, 243, 0, + 244, 245, 246, 247, 248, 249, 0, 0, 250, 251, + 0, 0, 0, 0, 0, 0, 0, 252, 253, 254, + 255, 256, 257, 258, 259, 260, 0, 261, 0, 262, + 263, 264, 265, 266, 0, 267, 268, 269, 0, 0, + 270, 271, 272, 273, 274, 0, 275, 276, 277, 0, + 278, 279, 0, 280, 281, 282, 283, 284, 285, 286, + 287, 288, 0, 289, 0, 290, 291, 292, 0, 293, + 0, 294, 0, 0, 0, 295, 296, 297, 0, 298, + 299, 0, 300, 0, 301, 302, 303, 304, 900, 0, + 306, 307, 308, 0, 309, 310, 311, 312, 313, 314, + 0, 315, 0, 316, 317, 318, 319, 320, 321, 322, + 0, 323, 0, 324, 0, 0, 325, 0, 326, 327, + 328, 329, 330, 331, 332, 0, 333, 334, 0, 335, + 0, 0, 336, 337, 338, 0, 0, 339, 340, 341, + 342, 343, 344, 345, 346, 347, 348, 349, 350, 351, + 0, 352, 353, 354, 355, 0, 356, 357, 0, 358, + 0, 359, 360, 361, 362, 363, 364, 0, 365, 0, + 0, 366, 367, 368, 0, 0, 369, 0, 0, 0, + 370, 371, 372, 373, 374, 375, 376, 377, 0, 378, + 379, 380, 381, 382, 383, 384, 0, 385, 386, 387, + 388, 389, 390, 391, 392, 393, 394, 395, 396, 0, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 0, 407, 408, 0, 409, 410, 411, 412, 413, 414, + 415, 416, 417, 418, 419, 0, 420, 421, 422, 423, + 424, 0, 425, 426, 427, 428, 0, 429, 430, 431, + 0, 432, 433, 434, 435, 436, 437, 438, 439, 440, + 441, 442, 0, 443, 444, 0, 445, 446, 447, 448, + 449, 450, 0, 451, 452, 0, 0, 453, 454, 455, + 456, 0, 457, 458, 459, 460, 461, 462, 463, 0, + 0, 464, 465, 466, 467, 468, 0, 0, 469, 470, + 471, 472, 473, 474, 475, 0, 476, 0, 477, 478, + 479, 0, 0, 480, 0, 0, 481, 482, 483, 484, + 485, 486, 487, 488, 489, 490, 491, 492, 493, 494, + 495, 496, 497, 199, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 200, 201, 202, 203, 204, 205, + 206, 207, 0, 209, 210, 211, 0, 0, 0, 0, + 0, 0, 0, 212, 213, 0, 214, 215, 0, 216, + 217, 218, 219, 220, 0, 221, 222, 0, 223, 224, + 225, 226, 227, 0, 0, 228, 229, 230, 231, 232, + 0, 233, 234, 235, 236, 237, 0, 0, 0, 238, + 239, 240, 241, 0, 242, 243, 0, 244, 245, 246, + 247, 248, 249, 0, 0, 250, 251, 0, 0, 0, + 0, 0, 0, 0, 252, 253, 254, 255, 256, 257, + 258, 259, 260, 0, 261, 0, 262, 263, 264, 265, + 266, 0, 267, 268, 269, 0, 0, 270, 271, 272, + 273, 274, 0, 275, 276, 277, 0, 278, 279, 0, + 280, 281, 282, 283, 284, 285, 286, 287, 288, 0, + 289, 0, 290, 291, 292, 0, 293, 0, 294, 0, + 0, 0, 295, 296, 297, 0, 298, 299, 0, 300, + 0, 301, 302, 303, 304, 902, 0, 306, 307, 308, + 0, 309, 310, 311, 312, 313, 314, 0, 315, 0, + 316, 317, 318, 319, 320, 321, 322, 0, 323, 0, + 324, 0, 0, 325, 0, 326, 327, 328, 329, 330, + 331, 332, 0, 333, 334, 0, 335, 0, 0, 336, + 337, 338, 0, 0, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 351, 0, 352, 353, + 354, 355, 0, 356, 357, 0, 358, 0, 359, 360, + 361, 362, 363, 364, 0, 365, 0, 0, 366, 367, + 368, 0, 0, 369, 0, 0, 0, 370, 371, 372, + 373, 374, 375, 376, 377, 0, 378, 379, 380, 381, + 382, 383, 384, 0, 385, 386, 387, 388, 389, 390, + 391, 392, 393, 394, 395, 396, 0, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 0, 407, 408, + 0, 409, 410, 411, 412, 413, 414, 415, 416, 417, + 418, 419, 0, 420, 421, 422, 423, 424, 0, 425, + 426, 427, 428, 0, 429, 430, 431, 0, 432, 433, + 434, 435, 436, 437, 438, 439, 440, 441, 442, 0, + 443, 444, 0, 445, 446, 447, 448, 449, 450, 0, + 451, 452, 0, 0, 453, 454, 455, 456, 0, 457, + 458, 459, 460, 461, 462, 463, 0, 0, 464, 465, + 466, 467, 468, 0, 0, 469, 470, 471, 472, 473, + 474, 475, 0, 476, 0, 477, 478, 479, 0, 0, + 480, 0, 0, 481, 482, 483, 484, 485, 486, 487, + 488, 489, 490, 491, 492, 493, 494, 495, 496, 497, + 199, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 200, 201, 202, 203, 204, 205, 206, 207, 0, + 209, 210, 211, 0, 0, 0, 0, 0, 0, 0, + 212, 213, 0, 214, 215, 0, 216, 217, 218, 219, + 220, 0, 221, 222, 0, 223, 224, 225, 226, 227, + 0, 0, 228, 229, 230, 231, 232, 0, 233, 234, + 235, 236, 237, 0, 0, 0, 238, 239, 240, 241, + 0, 242, 243, 0, 244, 245, 246, 247, 248, 249, + 0, 0, 250, 251, 0, 0, 0, 0, 0, 0, + 0, 252, 253, 254, 255, 256, 257, 258, 259, 260, + 0, 261, 0, 262, 263, 264, 265, 266, 0, 267, + 268, 269, 0, 0, 270, 271, 272, 273, 274, 0, + 275, 276, 277, 0, 278, 279, 0, 280, 281, 282, + 283, 284, 285, 286, 287, 288, 0, 289, 0, 290, + 291, 292, 0, 293, 0, 294, 0, 0, 0, 295, + 296, 297, 0, 298, 299, 0, 300, 0, 301, 302, + 303, 304, 904, 0, 306, 307, 308, 0, 309, 310, + 311, 312, 313, 314, 0, 315, 0, 316, 317, 318, + 319, 320, 321, 322, 0, 323, 0, 324, 0, 0, + 325, 0, 326, 327, 328, 329, 330, 331, 332, 0, + 333, 334, 0, 335, 0, 0, 336, 337, 338, 0, + 0, 339, 340, 341, 342, 343, 344, 345, 346, 347, + 348, 349, 350, 351, 0, 352, 353, 354, 355, 0, + 356, 357, 0, 358, 0, 359, 360, 361, 362, 363, + 364, 0, 365, 0, 0, 366, 367, 368, 0, 0, + 369, 0, 0, 0, 370, 371, 372, 373, 374, 375, + 376, 377, 0, 378, 379, 380, 381, 382, 383, 384, + 0, 385, 386, 387, 388, 389, 390, 391, 392, 393, + 394, 395, 396, 0, 397, 398, 399, 400, 401, 402, + 403, 404, 405, 406, 0, 407, 408, 0, 409, 410, + 411, 412, 413, 414, 415, 416, 417, 418, 419, 0, + 420, 421, 422, 423, 424, 0, 425, 426, 427, 428, + 0, 429, 430, 431, 0, 432, 433, 434, 435, 436, + 437, 438, 439, 440, 441, 442, 0, 443, 444, 0, + 445, 446, 447, 448, 449, 450, 0, 451, 452, 0, + 0, 453, 454, 455, 456, 0, 457, 458, 459, 460, + 461, 462, 463, 0, 0, 464, 465, 466, 467, 468, + 0, 0, 469, 470, 471, 472, 473, 474, 475, 0, + 476, 0, 477, 478, 479, 0, 0, 480, 0, 0, + 481, 482, 483, 484, 485, 486, 487, 488, 489, 490, + 491, 492, 493, 494, 495, 496, 497, 199, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 200, 201, + 202, 203, 204, 205, 206, 207, 0, 209, 210, 211, + 0, 0, 0, 0, 0, 0, 0, 212, 213, 0, + 214, 215, 0, 216, 217, 218, 219, 220, 0, 221, + 222, 0, 223, 224, 225, 226, 227, 0, 0, 228, + 229, 230, 231, 232, 0, 233, 234, 235, 236, 237, + 0, 0, 0, 238, 239, 240, 241, 0, 242, 243, + 0, 244, 245, 246, 247, 248, 249, 0, 0, 250, + 251, 0, 0, 0, 0, 0, 0, 0, 252, 253, + 254, 255, 256, 257, 258, 259, 260, 0, 261, 0, + 262, 263, 264, 265, 266, 0, 267, 268, 269, 0, + 0, 270, 271, 272, 273, 274, 0, 275, 276, 277, + 0, 278, 279, 0, 280, 281, 282, 283, 284, 285, + 286, 287, 288, 0, 289, 0, 290, 291, 292, 0, + 293, 0, 294, 0, 0, 0, 295, 296, 297, 0, + 298, 299, 0, 300, 0, 301, 302, 303, 304, 907, + 0, 306, 307, 308, 0, 309, 310, 311, 312, 313, + 314, 0, 315, 0, 316, 317, 318, 319, 320, 321, + 322, 0, 323, 0, 324, 0, 0, 325, 0, 326, + 327, 328, 329, 330, 331, 332, 0, 333, 334, 0, + 335, 0, 0, 336, 337, 338, 0, 0, 339, 340, + 341, 342, 343, 344, 345, 346, 347, 348, 349, 350, + 351, 0, 352, 353, 354, 355, 0, 356, 357, 0, + 358, 0, 359, 360, 361, 362, 363, 364, 0, 365, + 0, 0, 366, 367, 368, 0, 0, 369, 0, 0, + 0, 370, 371, 372, 373, 374, 375, 376, 377, 0, + 378, 379, 380, 381, 382, 383, 384, 0, 385, 386, + 387, 388, 389, 390, 391, 392, 393, 394, 395, 396, + 0, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 0, 407, 408, 0, 409, 410, 411, 412, 413, + 414, 415, 416, 417, 418, 419, 0, 420, 421, 422, + 423, 424, 0, 425, 426, 427, 428, 0, 429, 430, + 431, 0, 432, 433, 434, 435, 436, 437, 438, 439, + 440, 441, 442, 0, 443, 444, 0, 445, 446, 447, + 448, 449, 450, 0, 451, 452, 0, 0, 453, 454, + 455, 456, 0, 457, 458, 459, 460, 461, 462, 463, + 0, 0, 464, 465, 466, 467, 468, 0, 0, 469, + 470, 471, 472, 473, 474, 475, 0, 476, 0, 477, + 478, 479, 0, 0, 480, 0, 0, 481, 482, 483, + 484, 485, 486, 487, 488, 489, 490, 491, 492, 493, + 494, 495, 496, 497, 199, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 200, 201, 202, 203, 204, + 205, 206, 207, 0, 209, 210, 211, 0, 0, 0, + 0, 0, 0, 0, 212, 213, 0, 214, 215, 0, + 216, 217, 218, 219, 220, 0, 221, 222, 0, 223, + 224, 225, 226, 227, 0, 0, 228, 229, 230, 231, + 232, 0, 233, 234, 235, 236, 237, 0, 0, 0, + 238, 239, 240, 241, 0, 242, 243, 0, 244, 245, + 246, 247, 248, 249, 0, 0, 250, 251, 0, 0, + 0, 0, 0, 0, 0, 252, 253, 254, 255, 256, + 257, 258, 259, 260, 0, 261, 0, 262, 263, 264, + 265, 266, 0, 267, 268, 269, 0, 0, 270, 271, + 272, 273, 274, 0, 275, 276, 277, 0, 278, 279, + 0, 280, 281, 282, 283, 284, 285, 286, 287, 288, + 0, 289, 0, 290, 291, 292, 0, 293, 0, 294, + 0, 0, 0, 295, 296, 297, 0, 298, 299, 0, + 300, 0, 301, 302, 303, 304, 909, 0, 306, 307, + 308, 0, 309, 310, 311, 312, 313, 314, 0, 315, + 0, 316, 317, 318, 319, 320, 321, 322, 0, 323, + 0, 324, 0, 0, 325, 0, 326, 327, 328, 329, + 330, 331, 332, 0, 333, 334, 0, 335, 0, 0, + 336, 337, 338, 0, 0, 339, 340, 910, 342, 343, + 344, 345, 346, 347, 348, 349, 350, 351, 0, 352, + 353, 354, 355, 0, 356, 357, 0, 358, 0, 359, + 360, 361, 362, 363, 364, 0, 365, 0, 0, 366, + 367, 368, 0, 0, 369, 0, 0, 0, 370, 371, + 372, 373, 374, 375, 376, 377, 0, 378, 379, 380, + 381, 382, 383, 384, 0, 385, 386, 387, 388, 389, + 390, 391, 392, 393, 394, 395, 396, 0, 397, 398, + 399, 400, 401, 402, 403, 404, 405, 406, 0, 407, + 408, 0, 409, 410, 411, 412, 413, 414, 415, 416, + 417, 418, 419, 0, 420, 421, 422, 423, 424, 0, + 425, 426, 427, 428, 0, 429, 430, 431, 0, 432, + 433, 434, 435, 436, 437, 438, 439, 440, 441, 442, + 0, 443, 444, 0, 445, 446, 447, 448, 449, 450, + 0, 451, 452, 0, 0, 453, 454, 455, 456, 0, + 457, 458, 459, 460, 461, 462, 463, 0, 0, 464, + 465, 466, 467, 468, 0, 0, 469, 470, 471, 472, + 473, 474, 475, 0, 476, 0, 477, 478, 479, 0, + 0, 480, 0, 0, 481, 482, 483, 484, 485, 486, + 487, 488, 489, 490, 491, 492, 493, 494, 495, 496, + 497, 199, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 200, 201, 202, 203, 204, 205, 206, 207, + 0, 209, 210, 211, 0, 0, 0, 0, 0, 0, + 0, 212, 213, 0, 214, 215, 0, 216, 217, 218, + 219, 220, 0, 221, 222, 0, 223, 224, 225, 226, + 227, 0, 0, 228, 229, 230, 231, 232, 0, 233, + 234, 235, 236, 237, 0, 0, 0, 238, 239, 240, + 241, 0, 242, 243, 0, 244, 245, 246, 247, 248, + 249, 0, 0, 250, 251, 0, 0, 0, 0, 0, + 0, 0, 252, 253, 254, 255, 256, 257, 258, 259, + 260, 0, 261, 0, 262, 263, 264, 265, 266, 0, + 267, 268, 269, 0, 0, 270, 271, 272, 273, 274, + 0, 275, 276, 277, 0, 278, 279, 0, 280, 281, + 282, 283, 284, 285, 286, 287, 288, 0, 289, 0, + 290, 291, 292, 0, 293, 0, 294, 0, 0, 0, + 295, 296, 297, 0, 298, 299, 0, 300, 0, 301, + 302, 303, 304, 913, 0, 306, 307, 308, 0, 309, + 310, 311, 312, 313, 314, 0, 315, 0, 316, 317, + 318, 319, 320, 321, 322, 0, 323, 0, 324, 0, + 0, 325, 0, 326, 327, 328, 329, 330, 331, 332, + 0, 333, 334, 0, 335, 0, 0, 336, 337, 338, + 0, 0, 339, 340, 341, 342, 343, 344, 345, 346, + 347, 348, 349, 350, 351, 0, 352, 353, 354, 355, + 0, 356, 357, 0, 358, 0, 359, 360, 361, 362, + 363, 364, 0, 365, 0, 0, 366, 367, 368, 0, + 0, 369, 0, 0, 0, 370, 371, 372, 373, 374, + 375, 376, 377, 0, 378, 379, 380, 381, 382, 383, + 384, 0, 385, 386, 387, 388, 389, 390, 391, 392, + 393, 394, 395, 396, 0, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 0, 407, 408, 0, 409, + 410, 411, 412, 413, 414, 415, 416, 417, 418, 419, + 0, 420, 421, 422, 423, 424, 0, 425, 426, 427, + 428, 0, 429, 430, 431, 0, 432, 433, 434, 435, + 436, 437, 438, 439, 440, 441, 442, 0, 443, 444, + 0, 445, 446, 447, 448, 449, 450, 0, 451, 452, + 0, 0, 453, 454, 455, 456, 0, 457, 458, 459, + 460, 461, 462, 463, 0, 0, 464, 465, 466, 467, + 468, 0, 0, 469, 470, 471, 472, 473, 474, 475, + 0, 476, 0, 477, 478, 479, 0, 0, 480, 0, + 0, 481, 482, 483, 484, 485, 486, 487, 488, 489, + 490, 491, 492, 493, 494, 495, 496, 497, 199, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 200, + 201, 202, 203, 204, 205, 206, 207, 0, 209, 210, + 211, 0, 0, 0, 0, 0, 0, 0, 212, 213, + 0, 214, 215, 0, 216, 217, 218, 219, 220, 0, + 221, 222, 0, 223, 224, 225, 226, 227, 0, 0, + 658, 229, 230, 231, 232, 0, 233, 234, 235, 236, + 237, 0, 0, 0, 238, 239, 240, 241, 0, 242, + 243, 0, 244, 245, 246, 247, 248, 249, 0, 0, + 250, 251, 0, 0, 0, 0, 0, 0, 0, 252, + 253, 254, 255, 256, 257, 258, 259, 260, 0, 261, + 0, 262, 263, 264, 265, 266, 0, 267, 268, 269, + 0, 0, 270, 271, 272, 273, 274, 0, 275, 276, + 277, 0, 278, 279, 0, 280, 281, 282, 283, 284, + 285, 286, 287, 288, 0, 289, 0, 290, 291, 292, + 0, 293, 0, 294, 0, 0, 0, 295, 296, 297, + 0, 298, 299, 0, 300, 0, 301, 302, 303, 304, + 305, 0, 306, 307, 308, 0, 309, 310, 311, 312, + 313, 314, 0, 315, 0, 316, 317, 318, 319, 320, + 321, 322, 0, 323, 0, 324, 0, 0, 325, 0, + 326, 327, 328, 329, 330, 331, 332, 0, 333, 334, + 0, 335, 0, 0, 336, 337, 338, 0, 0, 339, + 340, 341, 342, 343, 344, 345, 346, 347, 348, 349, + 661, 351, 0, 352, 353, 354, 355, 0, 356, 357, + 0, 358, 0, 359, 360, 361, 362, 363, 364, 0, + 365, 0, 0, 366, 367, 368, 0, 0, 369, 0, + 0, 0, 370, 371, 372, 373, 374, 375, 376, 377, + 0, 378, 379, 380, 381, 382, 383, 384, 0, 385, + 386, 387, 388, 389, 390, 391, 392, 393, 394, 395, + 396, 0, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 0, 407, 408, 0, 662, 410, 411, 412, + 413, 414, 663, 416, 417, 418, 419, 0, 420, 421, + 422, 423, 1082, 0, 425, 426, 427, 428, 0, 429, + 430, 431, 0, 432, 433, 434, 435, 436, 437, 438, + 439, 440, 441, 442, 0, 443, 444, 0, 445, 446, + 447, 448, 449, 450, 0, 665, 452, 0, 0, 666, + 454, 455, 456, 0, 457, 458, 459, 460, 461, 462, + 463, 0, 0, 464, 465, 466, 467, 468, 0, 0, + 469, 470, 471, 472, 473, 474, 475, 0, 476, 0, + 477, 478, 479, 0, 0, 480, 0, 0, 481, 482, + 483, 484, 667, 486, 487, 488, 489, 490, 491, 492, + 493, 494, 495, 496, 497, 199, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 200, 201, 202, 203, + 204, 205, 206, 207, 0, 209, 210, 211, 0, 0, + 0, 0, 0, 0, 0, 212, 213, 0, 214, 215, + 0, 216, 217, 218, 219, 220, 0, 221, 222, 0, + 223, 224, 225, 226, 227, 0, 0, 228, 229, 230, + 231, 232, 0, 233, 234, 235, 236, 237, 0, 0, + 0, 238, 239, 240, 241, 0, 242, 243, 0, 244, + 245, 246, 247, 248, 249, 0, 0, 250, 251, 0, + 0, 0, 0, 0, 0, 0, 252, 253, 254, 255, + 256, 257, 258, 259, 260, 0, 261, 0, 262, 263, + 264, 265, 266, 0, 267, 268, 269, 0, 0, 270, + 271, 272, 273, 274, 0, 275, 276, 277, 0, 278, + 279, 0, 280, 281, 282, 283, 284, 285, 286, 287, + 288, 0, 289, 0, 290, 291, 292, 0, 293, 0, + 294, 0, 0, 0, 295, 296, 297, 0, 298, 299, + 0, 300, 0, 301, 302, 303, 304, 1375, 0, 306, + 307, 308, 0, 309, 310, 311, 312, 313, 314, 0, + 315, 0, 316, 317, 318, 319, 320, 321, 322, 0, + 323, 0, 324, 0, 0, 325, 0, 326, 327, 328, + 329, 330, 331, 332, 0, 333, 334, 0, 335, 0, + 0, 336, 337, 338, 0, 0, 339, 340, 341, 342, + 343, 344, 345, 346, 347, 348, 349, 350, 351, 0, + 352, 353, 354, 355, 0, 356, 357, 0, 358, 0, + 359, 360, 361, 362, 363, 364, 0, 365, 0, 0, + 366, 367, 368, 0, 0, 369, 0, 0, 0, 370, + 371, 372, 373, 374, 375, 376, 377, 0, 378, 379, + 380, 381, 382, 383, 384, 0, 385, 386, 387, 388, + 389, 390, 391, 392, 393, 394, 395, 396, 0, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 0, + 407, 408, 0, 409, 410, 411, 412, 413, 414, 415, + 416, 417, 418, 419, 0, 420, 421, 422, 423, 424, + 0, 425, 426, 427, 428, 0, 429, 430, 431, 0, + 432, 433, 434, 435, 436, 437, 438, 439, 440, 441, + 442, 0, 443, 444, 0, 445, 446, 447, 448, 449, + 450, 0, 451, 452, 0, 0, 453, 454, 455, 456, + 0, 457, 458, 459, 460, 461, 462, 463, 0, 0, + 464, 465, 466, 467, 468, 0, 0, 469, 470, 471, + 472, 473, 474, 475, 0, 476, 0, 477, 478, 479, + 0, 0, 480, 0, 0, 481, 482, 483, 484, 485, + 486, 487, 488, 489, 490, 491, 492, 493, 494, 495, + 496, 497, 199, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 200, 201, 202, 203, 204, 205, 206, + 207, 0, 209, 210, 211, 0, 0, 0, 0, 0, + 0, 0, 212, 213, 0, 214, 215, 0, 216, 217, + 218, 219, 220, 0, 221, 222, 0, 223, 224, 225, + 226, 227, 0, 0, 228, 229, 230, 231, 232, 0, + 233, 234, 235, 236, 237, 0, 0, 0, 238, 239, + 240, 241, 0, 242, 243, 0, 244, 245, 246, 247, + 248, 249, 0, 0, 250, 251, 0, 0, 0, 0, + 0, 0, 0, 252, 253, 254, 255, 256, 257, 258, + 259, 260, 0, 261, 0, 262, 263, 264, 265, 266, + 0, 267, 268, 269, 0, 0, 270, 271, 272, 273, + 274, 0, 275, 276, 277, 0, 278, 279, 0, 280, + 281, 282, 283, 284, 285, 286, 287, 288, 0, 289, + 0, 290, 291, 292, 0, 293, 0, 294, 0, 0, + 0, 295, 296, 297, 0, 298, 299, 0, 300, 0, + 301, 302, 303, 304, 1402, 0, 306, 307, 308, 0, + 309, 310, 311, 312, 313, 314, 0, 315, 0, 316, + 317, 318, 319, 320, 321, 322, 0, 323, 0, 324, + 0, 0, 325, 0, 326, 327, 328, 329, 330, 331, + 332, 0, 333, 334, 0, 335, 0, 0, 336, 337, + 338, 0, 0, 339, 340, 341, 342, 343, 344, 345, + 346, 347, 348, 349, 350, 351, 0, 352, 353, 354, + 355, 0, 356, 357, 0, 358, 0, 359, 360, 361, + 362, 363, 364, 0, 365, 0, 0, 366, 367, 368, + 0, 0, 369, 0, 0, 0, 370, 371, 372, 373, + 374, 375, 376, 377, 0, 378, 379, 380, 381, 382, + 383, 384, 0, 385, 386, 387, 388, 389, 390, 391, + 392, 393, 394, 395, 396, 0, 397, 398, 399, 400, + 401, 402, 403, 404, 405, 406, 0, 407, 408, 0, + 409, 410, 411, 412, 413, 414, 415, 416, 417, 418, + 419, 0, 420, 421, 422, 423, 424, 0, 425, 426, + 427, 428, 0, 429, 430, 431, 0, 432, 433, 434, + 435, 436, 437, 438, 439, 440, 441, 442, 0, 443, + 444, 0, 445, 446, 447, 448, 449, 450, 0, 451, + 452, 0, 0, 453, 454, 455, 456, 0, 457, 458, + 459, 460, 461, 462, 463, 0, 0, 464, 465, 466, + 467, 468, 0, 0, 469, 470, 471, 472, 473, 474, + 475, 0, 476, 0, 477, 478, 479, 0, 0, 480, + 0, 0, 481, 482, 483, 484, 485, 486, 487, 488, + 489, 490, 491, 492, 493, 494, 495, 496, 497, 199, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 0, 0, 0, 212, + 213, 0, 214, 215, 0, 216, 217, 218, 219, 220, + 0, 221, 222, 0, 223, 224, 225, 226, 227, 0, + 0, 228, 229, 230, 231, 232, 0, 233, 234, 235, + 236, 237, 0, 0, 0, 238, 239, 240, 241, 0, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 0, + 0, 250, 251, 0, 0, 0, 0, 0, 0, 0, + 252, 253, 254, 255, 256, 257, 258, 259, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 272, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 284, 285, 286, 287, 288, 0, 289, 0, 290, 291, + 292, 0, 293, 0, 294, 0, 0, 0, 295, 296, + 297, 0, 298, 299, 0, 300, 0, 301, 302, 303, + 304, 1430, 0, 306, 307, 308, 0, 309, 310, 311, + 312, 313, 314, 0, 315, 0, 316, 317, 318, 319, + 320, 321, 322, 0, 323, 0, 324, 0, 0, 325, + 0, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 334, 0, 335, 0, 0, 336, 337, 338, 0, 0, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 351, 0, 352, 353, 354, 355, 0, 356, + 357, 0, 358, 0, 359, 360, 361, 362, 363, 364, + 0, 365, 0, 0, 366, 367, 368, 0, 0, 369, + 0, 0, 0, 370, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 379, 380, 381, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 0, 409, 410, 411, + 412, 413, 414, 415, 416, 417, 418, 419, 0, 420, + 421, 422, 423, 424, 0, 425, 426, 427, 428, 0, + 429, 430, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 442, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 451, 452, 0, 0, + 453, 454, 455, 456, 0, 457, 458, 459, 460, 461, + 462, 463, 0, 0, 464, 465, 466, 467, 468, 0, + 0, 469, 470, 471, 472, 473, 474, 475, 0, 476, + 0, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 485, 486, 487, 488, 489, 490, 491, + 492, 493, 494, 495, 496, 497, 199, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 200, 201, 202, + 203, 204, 205, 206, 207, 0, 209, 210, 211, 0, + 0, 0, 0, 0, 0, 0, 212, 213, 0, 214, + 215, 0, 216, 217, 218, 219, 220, 0, 221, 222, + 0, 223, 224, 225, 226, 227, 0, 0, 228, 229, + 230, 231, 232, 0, 233, 234, 235, 236, 237, 0, + 0, 0, 238, 239, 240, 241, 0, 242, 243, 0, + 244, 245, 246, 247, 248, 249, 0, 0, 250, 251, + 0, 0, 0, 0, 0, 0, 0, 252, 253, 254, + 255, 256, 257, 258, 259, 260, 0, 261, 0, 262, + 263, 264, 265, 266, 0, 267, 268, 269, 0, 0, + 270, 271, 272, 273, 274, 0, 275, 276, 277, 0, + 278, 279, 0, 280, 281, 282, 283, 284, 285, 286, + 287, 288, 0, 289, 0, 290, 291, 292, 0, 293, + 0, 294, 0, 0, 0, 295, 296, 297, 0, 298, + 299, 0, 300, 0, 301, 302, 303, 304, 1432, 0, + 306, 307, 308, 0, 309, 310, 311, 312, 313, 314, + 0, 315, 0, 316, 317, 318, 319, 320, 321, 322, + 0, 323, 0, 324, 0, 0, 325, 0, 326, 327, + 328, 329, 330, 331, 332, 0, 333, 334, 0, 335, + 0, 0, 336, 337, 338, 0, 0, 339, 340, 341, + 342, 343, 344, 345, 346, 347, 348, 349, 350, 351, + 0, 352, 353, 354, 355, 0, 356, 357, 0, 358, + 0, 359, 360, 361, 362, 363, 364, 0, 365, 0, + 0, 366, 367, 368, 0, 0, 369, 0, 0, 0, + 370, 371, 372, 373, 374, 375, 376, 377, 0, 378, + 379, 380, 381, 382, 383, 384, 0, 385, 386, 387, + 388, 389, 390, 391, 392, 393, 394, 395, 396, 0, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 0, 407, 408, 0, 409, 410, 411, 412, 413, 414, + 415, 416, 417, 418, 419, 0, 420, 421, 422, 423, + 424, 0, 425, 426, 427, 428, 0, 429, 430, 431, + 0, 432, 433, 434, 435, 436, 437, 438, 439, 440, + 441, 442, 0, 443, 444, 0, 445, 446, 447, 448, + 449, 450, 0, 451, 452, 0, 0, 453, 454, 455, + 456, 0, 457, 458, 459, 460, 461, 462, 463, 0, + 0, 464, 465, 466, 467, 468, 0, 0, 469, 470, + 471, 472, 473, 474, 475, 0, 476, 0, 477, 478, + 479, 0, 0, 480, 0, 0, 481, 482, 483, 484, + 485, 486, 487, 488, 489, 490, 491, 492, 493, 494, + 495, 496, 497, 199, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 200, 201, 202, 203, 204, 205, + 206, 207, 0, 209, 210, 211, 0, 0, 0, 0, + 0, 0, 0, 212, 213, 0, 214, 215, 0, 216, + 217, 218, 219, 220, 0, 221, 222, 0, 223, 224, + 225, 226, 227, 0, 0, 228, 229, 230, 231, 232, + 0, 233, 234, 235, 236, 237, 0, 0, 0, 238, + 239, 240, 241, 0, 242, 243, 0, 244, 245, 246, + 247, 248, 249, 0, 0, 250, 251, 0, 0, 0, + 0, 0, 0, 0, 252, 253, 254, 255, 256, 257, + 258, 259, 260, 0, 261, 0, 262, 263, 264, 265, + 266, 0, 267, 268, 269, 0, 0, 270, 271, 272, + 273, 274, 0, 275, 276, 277, 0, 278, 279, 0, + 280, 281, 282, 283, 284, 285, 286, 287, 288, 0, + 289, 0, 290, 291, 292, 0, 293, 0, 294, 0, + 0, 0, 295, 296, 297, 0, 298, 299, 0, 300, + 0, 301, 302, 303, 304, 1434, 0, 306, 307, 308, + 0, 309, 310, 311, 312, 313, 314, 0, 315, 0, + 316, 317, 318, 319, 320, 321, 322, 0, 323, 0, + 324, 0, 0, 325, 0, 326, 327, 328, 329, 330, + 331, 332, 0, 333, 334, 0, 335, 0, 0, 336, + 337, 338, 0, 0, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 351, 0, 352, 353, + 354, 355, 0, 356, 357, 0, 358, 0, 359, 360, + 361, 362, 363, 364, 0, 365, 0, 0, 366, 367, + 368, 0, 0, 369, 0, 0, 0, 370, 371, 372, + 373, 374, 375, 376, 377, 0, 378, 379, 380, 381, + 382, 383, 384, 0, 385, 386, 387, 388, 389, 390, + 391, 392, 393, 394, 395, 396, 0, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 0, 407, 408, + 0, 409, 410, 411, 412, 413, 414, 415, 416, 417, + 418, 419, 0, 420, 421, 422, 423, 424, 0, 425, + 426, 427, 428, 0, 429, 430, 431, 0, 432, 433, + 434, 435, 436, 437, 438, 439, 440, 441, 442, 0, + 443, 444, 0, 445, 446, 447, 448, 449, 450, 0, + 451, 452, 0, 0, 453, 454, 455, 456, 0, 457, + 458, 459, 460, 461, 462, 463, 0, 0, 464, 465, + 466, 467, 468, 0, 0, 469, 470, 471, 472, 473, + 474, 475, 0, 476, 0, 477, 478, 479, 0, 0, + 480, 0, 0, 481, 482, 483, 484, 485, 486, 487, + 488, 489, 490, 491, 492, 493, 494, 495, 496, 497, + 199, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 200, 201, 202, 203, 204, 205, 206, 207, 0, + 209, 210, 211, 0, 0, 0, 0, 0, 0, 0, + 212, 213, 0, 214, 215, 0, 216, 217, 218, 219, + 220, 0, 221, 222, 0, 223, 224, 225, 226, 227, + 0, 0, 228, 229, 230, 231, 232, 0, 233, 234, + 235, 236, 237, 0, 0, 0, 238, 239, 240, 241, + 0, 242, 243, 0, 244, 245, 246, 247, 248, 249, + 0, 0, 250, 251, 0, 0, 0, 0, 0, 0, + 0, 252, 253, 254, 255, 256, 257, 258, 259, 260, + 0, 261, 0, 262, 263, 264, 265, 266, 0, 267, + 268, 269, 0, 0, 270, 271, 272, 273, 274, 0, + 275, 276, 277, 0, 278, 279, 0, 280, 281, 282, + 283, 284, 285, 286, 287, 288, 0, 289, 0, 290, + 291, 292, 0, 293, 0, 294, 0, 0, 0, 295, + 296, 297, 0, 298, 299, 0, 300, 0, 301, 302, + 303, 304, 305, 0, 306, 307, 308, 0, 309, 310, + 311, 312, 313, 314, 0, 315, 0, 316, 317, 318, + 319, 320, 321, 322, 0, 323, 0, 324, 0, 0, + 325, 0, 326, 327, 328, 329, 330, 331, 332, 0, + 333, 334, 0, 335, 0, 0, 336, 337, 338, 0, + 0, 339, 340, 341, 342, 343, 344, 345, 346, 347, + 348, 349, 350, 351, 0, 352, 353, 354, 355, 0, + 356, 357, 0, 358, 0, 359, 360, 361, 362, 363, + 364, 0, 365, 0, 0, 366, 367, 368, 0, 0, + 369, 0, 0, 0, 370, 371, 372, 373, 374, 375, + 376, 377, 0, 378, 379, 380, 381, 382, 383, 384, + 0, 385, 386, 387, 388, 389, 390, 391, 392, 393, + 394, 395, 396, 0, 397, 398, 399, 400, 401, 402, + 403, 404, 405, 406, 0, 407, 408, 0, 409, 410, + 411, 412, 413, 1525, 415, 416, 417, 418, 419, 0, + 420, 421, 422, 423, 424, 0, 425, 426, 427, 428, + 0, 429, 430, 431, 0, 432, 433, 434, 435, 436, + 437, 438, 439, 440, 441, 442, 0, 443, 444, 0, + 445, 446, 447, 448, 449, 450, 0, 451, 452, 0, + 0, 453, 454, 455, 456, 0, 457, 458, 459, 460, + 461, 462, 463, 0, 0, 464, 465, 466, 467, 468, + 0, 0, 469, 470, 471, 472, 473, 474, 475, 0, + 476, 0, 477, 478, 479, 0, 0, 480, 0, 0, + 481, 482, 483, 484, 485, 486, 487, 488, 489, 490, + 491, 492, 493, 494, 495, 496, 497, 199, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 200, 201, + 202, 203, 204, 205, 206, 207, 0, 209, 210, 211, + 0, 0, 0, 0, 0, 1792, 0, 212, 213, 0, + 214, 215, 0, 216, 217, 218, 219, 220, 0, 221, + 222, 0, 223, 224, 225, 226, 227, 0, 0, 228, + 229, 230, 231, 232, 0, 233, 234, 235, 236, 237, + 0, 0, 0, 238, 239, 240, 241, 0, 242, 243, + 0, 244, 245, 246, 247, 248, 249, 0, 0, 250, + 251, 0, 0, 0, 0, 0, 0, 0, 252, 253, + 254, 255, 256, 257, 258, 259, 260, 0, 261, 0, + 262, 263, 264, 265, 266, 0, 267, 268, 269, 0, + 0, 270, 271, 272, 273, 274, 0, 275, 276, 277, + 0, 278, 279, 0, 280, 281, 282, 283, 284, 285, + 286, 287, 288, 0, 289, 0, 290, 291, 292, 0, + 293, 0, 294, 0, 0, 0, 295, 296, 297, 0, + 298, 299, 0, 300, 0, 301, 302, 303, 304, 305, + 0, 306, 307, 308, 0, 309, 310, 311, 312, 313, + 314, 0, 315, 0, 316, 317, 318, 319, 320, 321, + 322, 0, 323, 0, 324, 0, 0, 325, 0, 326, + 327, 328, 329, 330, 331, 332, 0, 333, 334, 0, + 335, 0, 0, 336, 337, 338, 0, 0, 339, 340, + 341, 342, 343, 344, 345, 346, 347, 348, 349, 350, + 351, 0, 352, 353, 354, 355, 0, 356, 357, 0, + 358, 0, 359, 360, 361, 362, 363, 364, 0, 365, + 0, 0, 366, 367, 368, 0, 0, 369, 0, 0, + 0, 370, 371, 372, 373, 374, 375, 376, 377, 0, + 378, 379, 380, 381, 382, 383, 384, 0, 385, 386, + 387, 388, 389, 390, 391, 392, 393, 394, 395, 396, + 0, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 0, 407, 408, 0, 409, 410, 411, 412, 413, + 414, 415, 416, 417, 418, 419, 0, 420, 421, 422, + 423, 424, 0, 0, 426, 427, 428, 0, 429, 430, + 431, 0, 432, 433, 434, 435, 436, 437, 438, 439, + 440, 441, 442, 0, 443, 444, 0, 445, 446, 447, + 448, 449, 450, 0, 451, 452, 0, 0, 453, 454, + 455, 456, 0, 457, 458, 459, 460, 461, 462, 463, + 0, 0, 464, 465, 466, 467, 468, 0, 0, 469, + 470, 471, 472, 473, 474, 475, 0, 476, 0, 477, + 478, 479, 0, 0, 480, 0, 0, 481, 482, 483, + 484, 485, 486, 487, 488, 489, 490, 491, 492, 493, + 494, 495, 496, 497, 199, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 200, 201, 202, 203, 204, + 205, 206, 207, 0, 209, 210, 211, 0, 0, 0, + 0, 0, 0, 0, 212, 213, 0, 214, 215, 0, + 216, 217, 218, 219, 220, 0, 221, 222, 0, 223, + 224, 225, 226, 227, 0, 0, 658, 229, 230, 231, + 232, 0, 233, 234, 235, 236, 237, 0, 0, 0, + 238, 239, 240, 241, 0, 242, 243, 0, 244, 245, + 246, 247, 248, 249, 0, 0, 250, 251, 0, 0, + 0, 0, 0, 0, 0, 252, 253, 254, 255, 256, + 257, 258, 259, 260, 0, 261, 0, 262, 263, 264, + 265, 266, 0, 267, 268, 269, 0, 0, 270, 271, + 272, 273, 274, 0, 275, 276, 277, 0, 278, 279, + 0, 280, 281, 282, 283, 284, 285, 286, 287, 288, + 0, 289, 0, 290, 291, 292, 0, 293, 0, 294, + 0, 0, 0, 295, 296, 297, 0, 298, 299, 0, + 300, 0, 301, 302, 303, 304, 305, 0, 306, 307, + 308, 0, 309, 310, 311, 312, 313, 314, 0, 315, + 0, 316, 317, 318, 319, 320, 321, 322, 0, 323, + 0, 324, 0, 0, 325, 0, 326, 327, 328, 329, + 330, 331, 332, 0, 333, 334, 0, 335, 0, 0, + 336, 337, 338, 0, 0, 339, 340, 341, 342, 343, + 344, 345, 346, 347, 348, 349, 661, 351, 0, 352, + 353, 354, 355, 0, 356, 357, 0, 358, 0, 359, + 360, 361, 362, 363, 364, 0, 365, 0, 0, 366, + 367, 368, 0, 0, 369, 0, 0, 0, 370, 371, + 372, 373, 374, 375, 376, 377, 0, 378, 379, 380, + 381, 382, 383, 384, 0, 385, 386, 387, 388, 389, + 390, 391, 392, 393, 394, 395, 396, 0, 397, 398, + 399, 400, 401, 402, 403, 404, 405, 406, 0, 407, + 408, 0, 662, 410, 411, 412, 413, 414, 663, 416, + 417, 418, 419, 0, 420, 421, 422, 423, 1082, 0, + 425, 426, 427, 428, 0, 429, 430, 431, 0, 432, + 433, 434, 435, 436, 437, 438, 439, 440, 441, 442, + 0, 443, 444, 0, 445, 1810, 447, 448, 449, 450, + 0, 665, 452, 0, 0, 666, 454, 455, 456, 0, + 457, 458, 459, 460, 461, 462, 463, 0, 0, 464, + 465, 466, 467, 468, 0, 0, 469, 470, 471, 472, + 473, 474, 475, 0, 476, 0, 477, 478, 479, 0, + 0, 480, 0, 0, 481, 482, 483, 484, 667, 486, + 487, 488, 489, 490, 491, 492, 493, 494, 495, 496, + 497, 199, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 200, 201, 202, 203, 204, 205, 206, 207, + 0, 209, 210, 211, 0, 0, 0, 0, 0, 0, + 0, 212, 213, 0, 214, 215, 0, 216, 217, 218, + 219, 220, 0, 221, 222, 0, 223, 224, 225, 226, + 227, 0, 0, 658, 229, 230, 231, 232, 0, 233, + 234, 235, 236, 237, 0, 0, 0, 238, 239, 240, + 241, 0, 242, 243, 0, 244, 245, 246, 247, 248, + 249, 0, 0, 250, 251, 0, 0, 0, 0, 0, + 0, 0, 252, 253, 254, 255, 256, 257, 258, 259, + 260, 0, 261, 0, 262, 263, 264, 265, 266, 0, + 267, 268, 269, 0, 0, 270, 271, 272, 273, 274, + 0, 275, 276, 277, 0, 278, 279, 0, 280, 281, + 282, 283, 284, 285, 286, 287, 288, 0, 289, 0, + 290, 291, 292, 0, 293, 0, 294, 0, 0, 0, + 295, 296, 297, 0, 298, 299, 0, 300, 0, 301, + 302, 303, 304, 305, 0, 306, 307, 308, 0, 309, + 310, 311, 312, 313, 314, 0, 315, 0, 316, 317, + 318, 319, 320, 321, 322, 0, 323, 0, 324, 0, + 0, 325, 0, 326, 327, 328, 329, 330, 331, 332, + 0, 333, 334, 0, 335, 0, 0, 336, 337, 338, + 0, 0, 339, 340, 341, 342, 343, 344, 345, 346, + 347, 348, 349, 661, 351, 0, 352, 353, 354, 355, + 0, 356, 357, 0, 358, 0, 359, 360, 361, 362, + 363, 364, 0, 365, 0, 0, 366, 367, 368, 0, + 0, 369, 0, 0, 0, 370, 371, 372, 373, 374, + 375, 376, 377, 0, 378, 379, 380, 381, 382, 383, + 384, 0, 385, 386, 387, 388, 389, 390, 391, 392, + 393, 394, 395, 396, 0, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 0, 407, 408, 0, 662, + 410, 411, 412, 413, 414, 1870, 416, 417, 418, 419, + 0, 420, 421, 422, 423, 1871, 0, 425, 426, 427, + 428, 0, 429, 430, 431, 0, 432, 433, 434, 435, + 436, 437, 438, 439, 440, 441, 442, 0, 443, 444, + 0, 445, 446, 447, 448, 449, 450, 0, 665, 452, + 0, 0, 1872, 454, 455, 456, 0, 457, 458, 459, + 460, 461, 462, 463, 0, 0, 464, 465, 466, 467, + 468, 0, 0, 469, 470, 471, 472, 473, 474, 475, + 0, 476, 0, 477, 478, 479, 0, 0, 480, 0, + 0, 481, 482, 483, 484, 667, 486, 487, 488, 489, + 490, 491, 492, 493, 494, 495, 496, 497, 199, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 200, + 201, 202, 203, 204, 205, 206, 207, 0, 209, 210, + 211, 0, 0, 0, 0, 0, 0, 0, 212, 213, + 0, 214, 215, 0, 216, 217, 218, 219, 220, 0, + 221, 222, 0, 223, 224, 225, 226, 227, 0, 0, + 228, 229, 230, 231, 232, 0, 233, 234, 235, 236, + 237, 0, 0, 0, 238, 239, 240, 241, 0, 242, + 243, 0, 244, 245, 246, 247, 248, 249, 0, 0, + 250, 251, 0, 0, 0, 0, 0, 0, 0, 252, + 253, 254, 255, 256, 257, 258, 259, 260, 0, 261, + 0, 262, 263, 264, 265, 266, 0, 267, 268, 269, + 0, 0, 270, 271, 272, 273, 274, 0, 275, 276, + 277, 0, 278, 279, 0, 280, 281, 282, 283, 284, + 285, 286, 287, 288, 0, 289, 0, 290, 291, 292, + 0, 293, 0, 294, 0, 0, 0, 295, 296, 297, + 0, 298, 299, 0, 300, 0, 301, 302, 303, 304, + 2116, 0, 306, 307, 308, 0, 309, 310, 311, 312, + 313, 314, 0, 315, 0, 316, 317, 318, 319, 320, + 321, 322, 0, 323, 0, 324, 0, 0, 325, 0, + 326, 327, 328, 329, 330, 331, 332, 0, 333, 334, + 0, 335, 0, 0, 336, 337, 338, 0, 0, 339, + 340, 341, 342, 343, 344, 345, 346, 347, 348, 349, + 350, 351, 0, 352, 353, 354, 355, 0, 356, 357, + 0, 358, 0, 359, 360, 361, 362, 363, 364, 0, + 365, 0, 0, 366, 367, 368, 0, 0, 369, 0, + 0, 0, 370, 371, 372, 373, 374, 375, 376, 377, + 0, 378, 379, 380, 381, 382, 383, 384, 0, 385, + 386, 387, 388, 389, 390, 391, 392, 393, 394, 395, + 396, 0, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 0, 407, 408, 0, 409, 410, 411, 412, + 413, 414, 415, 416, 417, 418, 419, 0, 420, 421, + 422, 423, 424, 0, 425, 426, 427, 428, 0, 429, + 430, 431, 0, 432, 433, 434, 435, 436, 437, 438, + 439, 440, 441, 442, 0, 443, 444, 0, 445, 446, + 447, 448, 449, 450, 0, 451, 452, 0, 0, 453, + 454, 455, 456, 0, 457, 458, 459, 460, 461, 462, + 463, 0, 0, 464, 465, 466, 467, 468, 0, 0, + 469, 470, 471, 472, 473, 474, 475, 0, 476, 0, + 477, 478, 479, 0, 0, 480, 0, 0, 481, 482, + 483, 484, 485, 486, 487, 488, 489, 490, 491, 492, + 493, 494, 495, 496, 497, 199, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 200, 201, 202, 203, + 204, 205, 206, 207, 0, 209, 210, 211, 0, 0, + 0, 0, 0, 0, 0, 212, 213, 0, 214, 215, + 0, 216, 217, 218, 219, 220, 0, 221, 222, 0, + 223, 224, 225, 226, 227, 0, 0, 228, 229, 230, + 231, 232, 0, 233, 234, 235, 236, 237, 0, 0, + 0, 238, 239, 240, 241, 0, 242, 243, 0, 244, + 245, 246, 247, 248, 249, 0, 0, 250, 251, 0, + 0, 0, 0, 0, 0, 0, 252, 253, 254, 255, + 256, 257, 258, 259, 260, 0, 261, 0, 262, 263, + 264, 265, 266, 0, 267, 268, 269, 0, 0, 270, + 271, 272, 273, 274, 0, 275, 276, 277, 0, 278, + 279, 0, 280, 281, 282, 283, 284, 285, 286, 287, + 288, 0, 289, 0, 290, 291, 292, 0, 293, 0, + 294, 0, 0, 0, 295, 296, 297, 0, 298, 299, + 0, 300, 0, 301, 302, 303, 304, 2444, 0, 306, + 307, 308, 0, 309, 310, 311, 312, 313, 314, 0, + 315, 0, 316, 317, 318, 319, 320, 321, 322, 0, + 323, 0, 324, 0, 0, 325, 0, 326, 327, 328, + 329, 330, 331, 332, 0, 333, 334, 0, 335, 0, + 0, 336, 337, 338, 0, 0, 339, 340, 341, 342, + 343, 344, 345, 346, 347, 348, 349, 350, 351, 0, + 352, 353, 354, 355, 0, 356, 357, 0, 358, 0, + 359, 360, 361, 362, 363, 364, 0, 365, 0, 0, + 366, 367, 368, 0, 0, 369, 0, 0, 0, 370, + 371, 372, 373, 374, 375, 376, 377, 0, 378, 379, + 380, 381, 382, 383, 384, 0, 385, 386, 387, 388, + 389, 390, 391, 392, 393, 394, 395, 396, 0, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 0, + 407, 408, 0, 409, 410, 411, 412, 413, 414, 415, + 416, 417, 418, 419, 0, 420, 421, 422, 423, 424, + 0, 425, 426, 427, 428, 0, 429, 430, 431, 0, + 432, 433, 434, 435, 436, 437, 438, 439, 440, 441, + 442, 0, 443, 444, 0, 445, 446, 447, 448, 449, + 450, 0, 451, 452, 0, 0, 453, 454, 455, 456, + 0, 457, 458, 459, 460, 461, 462, 463, 0, 0, + 464, 465, 466, 467, 468, 0, 0, 469, 470, 471, + 472, 473, 474, 475, 0, 476, 0, 477, 478, 479, + 0, 0, 480, 0, 0, 481, 482, 483, 484, 485, + 486, 487, 488, 489, 490, 491, 492, 493, 494, 495, + 496, 497, 199, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 200, 201, 202, 203, 204, 205, 206, + 207, 0, 209, 210, 211, 0, 0, 0, 0, 0, + 0, 0, 212, 213, 0, 214, 215, 0, 216, 217, + 218, 219, 220, 0, 221, 222, 0, 223, 224, 225, + 226, 227, 0, 0, 658, 229, 230, 231, 232, 0, + 233, 234, 235, 236, 237, 0, 0, 0, 238, 239, + 240, 241, 0, 242, 243, 0, 244, 245, 246, 247, + 248, 249, 0, 0, 250, 251, 0, 0, 0, 0, + 0, 0, 0, 252, 253, 254, 255, 256, 257, 258, + 259, 260, 0, 261, 0, 262, 263, 264, 265, 266, + 0, 267, 268, 269, 0, 0, 270, 271, 272, 273, + 274, 0, 275, 276, 277, 0, 278, 279, 0, 280, + 281, 282, 283, 284, 285, 286, 287, 288, 0, 289, + 0, 290, 291, 292, 0, 293, 0, 294, 0, 0, + 0, 295, 296, 297, 0, 298, 299, 0, 300, 0, + 301, 302, 303, 304, 305, 0, 306, 307, 308, 0, + 309, 310, 311, 312, 313, 314, 0, 315, 0, 316, + 317, 318, 319, 320, 321, 322, 0, 323, 0, 324, + 0, 0, 325, 0, 326, 327, 328, 329, 330, 331, + 332, 0, 333, 334, 0, 335, 0, 0, 336, 337, + 338, 0, 0, 339, 340, 341, 342, 343, 344, 345, + 346, 347, 348, 349, 661, 351, 0, 352, 353, 354, + 355, 0, 356, 357, 0, 358, 0, 359, 360, 361, + 362, 363, 364, 0, 365, 0, 0, 366, 367, 368, + 0, 0, 369, 0, 0, 0, 370, 371, 372, 373, + 374, 375, 376, 377, 0, 378, 379, 380, 381, 382, + 383, 384, 0, 385, 386, 387, 388, 389, 390, 391, + 392, 393, 394, 395, 396, 0, 397, 398, 399, 400, + 401, 402, 403, 404, 405, 406, 0, 407, 408, 0, + 662, 410, 411, 412, 413, 414, 663, 416, 417, 418, + 419, 0, 420, 421, 422, 423, 1871, 0, 425, 426, + 427, 428, 0, 429, 430, 431, 0, 432, 433, 434, + 435, 436, 437, 438, 439, 440, 441, 442, 0, 443, + 444, 0, 445, 446, 447, 448, 449, 450, 0, 665, + 452, 0, 0, 1872, 454, 455, 456, 0, 457, 458, + 459, 460, 461, 462, 463, 0, 0, 464, 465, 466, + 467, 468, 0, 0, 469, 470, 471, 472, 473, 474, + 475, 0, 476, 0, 477, 478, 479, 0, 0, 480, + 0, 0, 481, 482, 483, 484, 667, 486, 487, 488, + 489, 490, 491, 492, 493, 494, 495, 496, 497, 1330, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 0, 0, 0, 212, + 213, 0, 214, 215, 713, 216, 217, 218, 0, 1331, + 714, 1332, 1333, 0, 223, 224, 225, 226, 227, 0, + 0, 228, 229, 1334, 1335, 232, 0, 233, 234, 235, + 236, 0, 0, 715, 0, 238, 239, 240, 241, 716, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 0, + 717, 250, 251, 0, 0, 0, 718, 0, 0, 0, + 252, 253, 254, 255, 256, 257, 1336, 1337, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 1005, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 0, 285, 286, 287, 0, 0, 289, 0, 290, 1338, + 292, 0, 293, 0, 294, 719, 0, 720, 295, 296, + 297, 0, 298, 0, 0, 300, 0, 301, 302, 303, + 304, 305, 721, 306, 307, 308, 1878, 309, 310, 311, + 312, 313, 314, 0, 315, 722, 1879, 317, 318, 319, + 320, 1339, 1340, 0, 1341, 0, 324, 723, 724, 325, + 725, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 0, 726, 335, 727, 0, 336, 337, 338, 0, 0, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 1342, 728, 1343, 353, 354, 0, 0, 356, + 357, 729, 358, 0, 0, 360, 1344, 362, 363, 364, + 0, 365, 0, 0, 366, 367, 368, 0, 0, 1880, + 730, 731, 732, 0, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 0, 380, 0, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 1345, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 733, 409, 410, 0, + 412, 413, 414, 415, 416, 417, 418, 419, 0, 420, + 421, 422, 423, 424, 0, 425, 1881, 427, 428, 734, + 429, 1347, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 0, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 1348, 1349, 0, 0, + 453, 0, 455, 0, 0, 457, 458, 459, 460, 461, + 462, 463, 0, 0, 464, 465, 466, 467, 468, 0, + 0, 469, 470, 471, 472, 473, 0, 1350, 1882, 476, + 735, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 485, 0, 199, 0, 0, 0, 0, + 0, 0, 0, 495, 496, 497, 200, 201, 202, 203, + 204, 205, 206, 207, 0, 209, 210, 211, 0, 0, + 0, 0, 0, 0, 0, 212, 213, 0, 214, 215, + 0, 216, 217, 218, 219, 220, 0, 221, 222, 0, + 223, 224, 225, 226, 227, 0, 0, 228, 229, 230, + 231, 232, 0, 233, 234, 235, 236, 237, 0, 0, + 0, 238, 239, 240, 241, 0, 242, 243, 0, 244, + 245, 246, 247, 248, 249, 0, 0, 250, 251, 0, + 0, 0, 0, 0, 0, 0, 252, 253, 254, 255, + 256, 257, 258, 259, 260, 0, 261, 0, 262, 263, + 264, 265, 266, 0, 267, 268, 269, 0, 0, 270, + 271, 272, 273, 274, 0, 275, 276, 277, 0, 278, + 279, 0, 280, 281, 282, 283, 284, 285, 286, 287, + 288, 0, 289, 0, 290, 291, 292, 0, 293, 0, + 294, 0, 0, 0, 295, 296, 297, 0, 298, 299, + 0, 300, 0, 301, 302, 303, 304, 2517, 0, 306, + 307, 308, 0, 309, 310, 311, 312, 313, 314, 0, + 315, 0, 316, 317, 318, 319, 320, 321, 322, 0, + 323, 0, 324, 0, 0, 325, 0, 326, 327, 328, + 329, 330, 331, 332, 0, 333, 334, 0, 335, 0, + 0, 336, 337, 338, 0, 0, 339, 340, 341, 342, + 343, 344, 345, 346, 347, 348, 349, 350, 351, 0, + 352, 353, 354, 355, 0, 356, 357, 0, 358, 0, + 359, 360, 361, 362, 363, 364, 0, 365, 0, 0, + 366, 367, 368, 0, 0, 369, 0, 0, 0, 370, + 371, 372, 373, 374, 375, 376, 377, 0, 378, 379, + 380, 381, 382, 383, 384, 0, 385, 386, 387, 388, + 389, 390, 391, 392, 393, 394, 395, 396, 0, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 0, + 407, 408, 0, 409, 410, 411, 412, 413, 414, 415, + 416, 417, 418, 419, 0, 420, 421, 422, 423, 424, + 0, 425, 426, 427, 428, 0, 429, 430, 431, 0, + 432, 433, 434, 435, 436, 437, 438, 439, 440, 441, + 442, 0, 443, 444, 0, 445, 446, 447, 448, 449, + 450, 0, 451, 452, 0, 0, 453, 454, 455, 456, + 0, 457, 458, 459, 460, 461, 462, 463, 0, 0, + 464, 465, 466, 467, 468, 0, 0, 469, 470, 471, + 472, 473, 474, 475, 0, 476, 0, 477, 478, 479, + 0, 0, 480, 0, 0, 481, 482, 483, 484, 485, + 486, 487, 488, 489, 490, 491, 492, 493, 494, 495, + 496, 497, 199, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 200, 201, 202, 203, 204, 205, 206, + 207, 0, 209, 210, 211, 0, 0, 0, 0, 0, + 0, 0, 212, 213, 0, 214, 215, 0, 216, 217, + 218, 219, 220, 0, 221, 222, 0, 223, 224, 225, + 226, 227, 0, 0, 228, 229, 230, 231, 232, 0, + 233, 234, 235, 236, 237, 0, 0, 0, 238, 239, + 240, 241, 0, 242, 243, 0, 244, 245, 246, 247, + 248, 249, 0, 0, 250, 251, 0, 0, 0, 0, + 0, 0, 0, 252, 253, 254, 255, 256, 257, 258, + 259, 260, 0, 261, 0, 262, 263, 264, 265, 266, + 0, 267, 268, 269, 0, 0, 270, 271, 272, 273, + 274, 0, 275, 276, 277, 0, 278, 279, 0, 280, + 281, 282, 283, 284, 285, 286, 287, 288, 0, 289, + 0, 290, 291, 292, 0, 293, 0, 294, 0, 0, + 0, 295, 296, 297, 0, 298, 299, 0, 300, 0, + 301, 302, 303, 304, 2519, 0, 306, 307, 308, 0, + 309, 310, 311, 312, 313, 314, 0, 315, 0, 316, + 317, 318, 319, 320, 321, 322, 0, 323, 0, 324, + 0, 0, 325, 0, 326, 327, 328, 329, 330, 331, + 332, 0, 333, 334, 0, 335, 0, 0, 336, 337, + 338, 0, 0, 339, 340, 341, 342, 343, 344, 345, + 346, 347, 348, 349, 350, 351, 0, 352, 353, 354, + 355, 0, 356, 357, 0, 358, 0, 359, 360, 361, + 362, 363, 364, 0, 365, 0, 0, 366, 367, 368, + 0, 0, 369, 0, 0, 0, 370, 371, 372, 373, + 374, 375, 376, 377, 0, 378, 379, 380, 381, 382, + 383, 384, 0, 385, 386, 387, 388, 389, 390, 391, + 392, 393, 394, 395, 396, 0, 397, 398, 399, 400, + 401, 402, 403, 404, 405, 406, 0, 407, 408, 0, + 409, 410, 411, 412, 413, 414, 415, 416, 417, 418, + 419, 0, 420, 421, 422, 423, 424, 0, 425, 426, + 427, 428, 0, 429, 430, 431, 0, 432, 433, 434, + 435, 436, 437, 438, 439, 440, 441, 442, 0, 443, + 444, 0, 445, 446, 447, 448, 449, 450, 0, 451, + 452, 0, 0, 453, 454, 455, 456, 0, 457, 458, + 459, 460, 461, 462, 463, 0, 0, 464, 465, 466, + 467, 468, 0, 0, 469, 470, 471, 472, 473, 474, + 475, 0, 476, 0, 477, 478, 479, 0, 0, 480, + 0, 0, 481, 482, 483, 484, 485, 486, 487, 488, + 489, 490, 491, 492, 493, 494, 495, 496, 497, 199, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 0, 0, 0, 212, + 213, 0, 214, 215, 0, 216, 217, 218, 219, 220, + 0, 221, 222, 0, 223, 224, 225, 226, 227, 0, + 0, 228, 229, 230, 231, 232, 0, 233, 234, 235, + 236, 237, 0, 0, 0, 238, 239, 240, 241, 0, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 0, + 0, 250, 251, 0, 0, 0, 0, 0, 0, 0, + 252, 253, 254, 255, 256, 257, 258, 259, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 272, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 284, 285, 286, 287, 288, 0, 289, 0, 290, 291, + 292, 0, 293, 0, 294, 0, 0, 0, 295, 296, + 297, 0, 298, 299, 0, 300, 0, 301, 302, 303, + 304, 2611, 0, 306, 307, 308, 0, 309, 310, 311, + 312, 313, 314, 0, 315, 0, 316, 317, 318, 319, + 320, 321, 322, 0, 323, 0, 324, 0, 0, 325, + 0, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 334, 0, 335, 0, 0, 336, 337, 338, 0, 0, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 351, 0, 352, 353, 354, 355, 0, 356, + 357, 0, 358, 0, 359, 360, 361, 362, 363, 364, + 0, 365, 0, 0, 366, 367, 368, 0, 0, 369, + 0, 0, 0, 370, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 379, 380, 381, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 0, 409, 410, 411, + 412, 413, 414, 415, 416, 417, 418, 419, 0, 420, + 421, 422, 423, 424, 0, 425, 426, 427, 428, 0, + 429, 430, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 442, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 451, 452, 0, 0, + 453, 454, 455, 456, 0, 457, 458, 459, 460, 461, + 462, 463, 0, 0, 464, 465, 466, 467, 468, 0, + 0, 469, 470, 471, 472, 473, 474, 475, 0, 476, + 0, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 485, 486, 487, 488, 489, 490, 491, + 492, 493, 494, 495, 496, 497, 1330, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 200, 201, 202, + 203, 204, 205, 206, 207, 0, 209, 210, 211, 0, + 0, 0, 0, 0, 0, 0, 212, 213, 0, 214, + 215, 713, 216, 217, 218, 0, 1331, 714, 1332, 1333, + 0, 223, 224, 225, 226, 227, 0, 0, 228, 229, + 1334, 1335, 232, 0, 233, 234, 235, 236, 0, 0, + 715, 0, 238, 239, 240, 241, 716, 242, 243, 0, + 244, 245, 246, 247, 248, 249, 0, 717, 250, 251, + 0, 0, 0, 718, 0, 0, 0, 252, 253, 254, + 255, 256, 257, 1336, 1337, 260, 0, 261, 0, 262, + 263, 264, 265, 266, 0, 267, 268, 269, 0, 0, + 270, 271, 1005, 273, 274, 0, 275, 276, 277, 0, + 278, 279, 0, 280, 281, 282, 283, 0, 285, 286, + 287, 0, 0, 289, 0, 290, 1338, 292, 0, 293, + 0, 294, 719, 0, 720, 295, 296, 297, 0, 298, + 0, 0, 300, 0, 301, 302, 303, 304, 305, 721, + 306, 307, 308, 0, 309, 310, 311, 312, 313, 314, + 0, 315, 722, 0, 317, 318, 319, 320, 1339, 1340, + 0, 1341, 0, 324, 723, 724, 325, 725, 326, 327, + 328, 329, 330, 331, 332, 0, 333, 0, 726, 335, + 727, 0, 336, 337, 338, 0, 0, 339, 340, 341, + 342, 343, 344, 345, 346, 347, 348, 349, 350, 1342, + 728, 1343, 353, 354, 0, 0, 356, 357, 729, 358, + 1866, 0, 360, 1344, 362, 363, 364, 0, 365, 0, + 0, 366, 367, 368, 0, 0, 0, 730, 731, 732, + 0, 371, 372, 373, 374, 375, 376, 377, 0, 378, + 0, 380, 0, 382, 383, 384, 0, 385, 386, 387, + 388, 389, 390, 391, 1345, 393, 394, 395, 396, 0, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 0, 407, 408, 733, 409, 410, 0, 412, 413, 414, + 415, 416, 417, 418, 419, 0, 420, 421, 422, 423, + 424, 0, 425, 1881, 427, 428, 734, 429, 1347, 431, + 0, 432, 433, 434, 435, 436, 437, 438, 439, 440, + 441, 0, 0, 443, 444, 3263, 445, 446, 447, 448, + 449, 450, 0, 1348, 1349, 0, 0, 453, 0, 455, + 0, 0, 457, 458, 459, 460, 461, 462, 463, 0, + 0, 464, 465, 466, 467, 468, 0, 0, 469, 470, + 471, 472, 473, 0, 1350, 0, 476, 735, 477, 478, + 479, 0, 0, 480, 0, 0, 481, 482, 483, 484, + 485, 0, 1330, 0, 0, 0, 0, 0, 0, 0, + 495, 496, 497, 200, 201, 202, 203, 204, 205, 206, + 207, 0, 209, 210, 211, 0, 0, 0, 0, 0, + 0, 0, 212, 213, 0, 214, 215, 713, 216, 217, + 218, 0, 1331, 714, 1332, 1333, 0, 223, 224, 225, + 226, 227, 0, 0, 228, 229, 1334, 1335, 232, 0, + 233, 234, 235, 236, 0, 0, 715, 0, 238, 239, + 240, 241, 716, 242, 243, 0, 244, 245, 246, 247, + 248, 249, 0, 717, 250, 251, 0, 0, 0, 718, + 0, 0, 0, 252, 253, 254, 255, 256, 257, 1336, + 1337, 260, 0, 261, 0, 262, 263, 264, 265, 266, + 0, 267, 268, 269, 0, 0, 270, 271, 1005, 273, + 274, 0, 275, 276, 277, 0, 278, 279, 0, 280, + 281, 282, 283, 0, 285, 286, 287, 0, 0, 289, + 0, 290, 1338, 292, 0, 293, 0, 294, 719, 0, + 720, 295, 296, 297, 0, 298, 0, 0, 300, 0, + 301, 302, 303, 304, 305, 721, 306, 307, 308, 0, + 309, 310, 311, 312, 313, 314, 0, 315, 722, 0, + 317, 318, 319, 320, 1339, 1340, 0, 1341, 0, 324, + 723, 724, 325, 725, 326, 327, 328, 329, 330, 331, + 332, 0, 333, 0, 726, 335, 727, 0, 336, 337, + 338, 0, 0, 339, 340, 341, 342, 343, 344, 345, + 346, 347, 348, 349, 350, 1342, 728, 1343, 353, 354, + 1929, 0, 356, 357, 729, 358, 0, 0, 360, 1344, + 362, 363, 364, 0, 365, 0, 0, 366, 367, 368, + 0, 0, 0, 730, 731, 732, 0, 371, 372, 373, + 374, 375, 376, 377, 0, 378, 0, 380, 0, 382, + 383, 384, 0, 385, 386, 387, 388, 389, 390, 391, + 1345, 393, 394, 395, 396, 0, 397, 398, 399, 400, + 401, 402, 403, 404, 405, 406, 0, 407, 408, 733, + 409, 410, 0, 412, 413, 414, 415, 416, 417, 418, + 419, 0, 420, 421, 422, 423, 424, 0, 425, 1346, + 427, 428, 734, 429, 1347, 431, 0, 432, 433, 434, + 435, 436, 437, 438, 439, 440, 441, 0, 0, 443, + 444, 0, 445, 446, 447, 448, 449, 450, 0, 1348, + 1349, 0, 0, 453, 0, 455, 0, 0, 457, 458, + 459, 460, 461, 462, 463, 0, 0, 464, 465, 466, + 467, 468, 0, 0, 469, 470, 471, 472, 473, 0, + 1350, 0, 476, 735, 477, 478, 479, 0, 0, 480, + 0, 0, 481, 482, 483, 484, 485, 0, 1330, 0, + 0, 0, 0, 0, 0, 0, 495, 496, 497, 200, + 201, 202, 203, 204, 205, 206, 207, 0, 209, 210, + 211, 0, 0, 0, 0, 0, 0, 0, 212, 213, + 0, 214, 215, 713, 216, 217, 218, 0, 1331, 714, + 1332, 1333, 0, 223, 224, 225, 226, 227, 0, 0, + 228, 229, 1334, 1335, 232, 0, 233, 234, 235, 236, + 0, 0, 715, 0, 238, 239, 240, 241, 716, 242, + 243, 0, 244, 245, 246, 247, 248, 249, 0, 717, + 250, 251, 0, 0, 0, 718, 0, 0, 0, 252, + 253, 254, 255, 256, 257, 1336, 1337, 260, 0, 261, + 0, 262, 263, 264, 265, 266, 0, 267, 268, 269, + 0, 0, 270, 271, 1005, 273, 274, 0, 275, 276, + 277, 0, 278, 279, 0, 280, 281, 282, 283, 0, + 285, 286, 287, 0, 0, 289, 0, 290, 1338, 292, + 0, 293, 0, 294, 719, 0, 720, 295, 296, 297, + 0, 298, 0, 0, 300, 0, 301, 302, 303, 304, + 305, 721, 306, 307, 308, 0, 309, 310, 311, 312, + 313, 314, 0, 315, 722, 0, 317, 318, 319, 320, + 1339, 1340, 0, 1341, 0, 324, 723, 724, 325, 725, + 326, 327, 328, 329, 330, 331, 332, 0, 333, 0, + 726, 335, 727, 0, 336, 337, 338, 0, 0, 339, + 340, 341, 342, 343, 344, 345, 346, 347, 348, 349, + 350, 1342, 728, 1343, 353, 354, 3082, 0, 356, 357, + 729, 358, 0, 0, 360, 1344, 362, 363, 364, 0, + 365, 0, 0, 366, 367, 368, 0, 0, 0, 730, + 731, 732, 0, 371, 372, 373, 374, 375, 376, 377, + 0, 378, 0, 380, 0, 382, 383, 384, 0, 385, + 386, 387, 388, 389, 390, 391, 1345, 393, 394, 395, + 396, 0, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 0, 407, 408, 733, 409, 410, 0, 412, + 413, 414, 415, 416, 417, 418, 419, 0, 420, 421, + 422, 423, 424, 0, 425, 1346, 427, 428, 734, 429, + 1347, 431, 0, 432, 433, 434, 435, 436, 437, 438, + 439, 440, 441, 0, 0, 443, 444, 0, 445, 446, + 447, 448, 449, 450, 0, 1348, 1349, 0, 0, 453, + 0, 455, 0, 0, 457, 458, 459, 460, 461, 462, + 463, 0, 0, 464, 465, 466, 467, 468, 0, 0, + 469, 470, 471, 472, 473, 0, 1350, 0, 476, 735, + 477, 478, 479, 0, 0, 480, 0, 0, 481, 482, + 483, 484, 485, 0, 199, 0, 0, 0, 0, 0, + 0, 0, 495, 496, 497, 200, 201, 202, 203, 204, + 205, 206, 207, 0, 209, 210, 211, 0, 0, 0, + 0, 0, 0, 0, 212, 213, 0, 214, 215, 0, + 216, 217, 218, 219, 220, 0, 221, 222, 0, 223, + 224, 225, 226, 227, 0, 0, 228, 229, 230, 231, + 232, 0, 233, 234, 235, 236, 237, 0, 0, 0, + 238, 239, 240, 241, 0, 242, 243, 0, 244, 245, + 246, 247, 248, 249, 0, 0, 250, 251, 0, 0, + 0, 0, 0, 0, 0, 252, 253, 254, 255, 256, + 257, 258, 259, 260, 0, 261, 0, 262, 263, 264, + 265, 266, 0, 267, 268, 269, 0, 0, 270, 271, + 272, 273, 274, 0, 275, 276, 277, 0, 278, 279, + 0, 280, 281, 282, 283, 284, 285, 286, 287, 288, + 0, 289, 0, 290, 291, 292, 0, 293, 0, 294, + 0, 0, 0, 295, 296, 297, 0, 298, 299, 0, + 300, 0, 301, 302, 303, 304, 305, 0, 306, 307, + 308, 0, 309, 310, 311, 312, 313, 314, 0, 315, + 0, 316, 317, 318, 319, 320, 321, 322, 0, 323, + 0, 324, 0, 0, 325, 0, 326, 327, 328, 329, + 330, 331, 332, 0, 333, 334, 0, 335, 0, 0, + 336, 337, 338, 0, 0, 339, 340, 341, 342, 343, + 344, 345, 346, 347, 348, 349, 350, 351, 0, 352, + 353, 354, 355, 0, 356, 357, 0, 358, 0, 359, + 360, 361, 362, 363, 364, 0, 365, 0, 0, 366, + 367, 368, 0, 0, 369, 0, 0, 0, 370, 371, + 372, 373, 374, 0, 376, 377, 0, 378, 379, 380, + 381, 382, 383, 384, 0, 385, 386, 387, 388, 389, + 0, 391, 392, 393, 394, 395, 396, 0, 397, 398, + 399, 400, 401, 402, 403, 404, 405, 406, 0, 407, + 408, 0, 409, 410, 411, 0, 413, 414, 415, 416, + 417, 418, 419, 0, 420, 421, 422, 423, 424, 0, + 425, 426, 427, 428, 0, 429, 430, 431, 0, 432, + 433, 434, 435, 436, 437, 438, 439, 440, 441, 442, + 0, 443, 444, 0, 445, 446, 447, 448, 449, 450, + 0, 451, 452, 0, 0, 453, 454, 455, 456, 0, + 457, 458, 459, 460, 461, 462, 463, 0, 0, 464, + 465, 466, 467, 468, 0, 0, 469, 470, 471, 472, + 473, 474, 475, 0, 476, 0, 477, 478, 479, 0, + 0, 480, 0, 0, 481, 482, 483, 484, 485, 486, + 487, 488, 489, 490, 491, 492, 493, 494, 495, 496, + 497, 1330, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 200, 201, 202, 203, 204, 205, 206, 207, + 0, 209, 210, 211, 0, 0, 0, 0, 0, 0, + 0, 212, 213, 0, 214, 215, 713, 216, 217, 218, + 0, 1331, 714, 1332, 1333, 0, 223, 224, 225, 226, + 227, 0, 0, 228, 229, 1334, 1335, 232, 0, 233, + 234, 235, 236, 0, 0, 715, 0, 238, 239, 240, + 241, 716, 242, 243, 0, 244, 245, 246, 247, 248, + 249, 0, 717, 250, 251, 0, 0, 0, 718, 0, + 0, 0, 252, 253, 254, 255, 256, 257, 1336, 1337, + 260, 0, 261, 0, 262, 263, 264, 265, 266, 0, + 267, 268, 269, 0, 0, 270, 271, 1005, 273, 274, + 0, 275, 276, 277, 0, 278, 279, 0, 280, 281, + 282, 283, 0, 285, 286, 287, 0, 0, 289, 0, + 290, 1338, 292, 0, 293, 0, 294, 719, 0, 720, + 295, 296, 297, 0, 298, 0, 0, 300, 0, 301, + 302, 303, 304, 305, 721, 306, 307, 308, 0, 309, + 310, 311, 312, 313, 314, 0, 315, 722, 0, 317, + 318, 319, 320, 1339, 1340, 0, 1341, 0, 324, 723, + 724, 325, 725, 326, 327, 328, 329, 330, 331, 332, + 0, 333, 0, 726, 335, 727, 0, 336, 337, 338, + 0, 0, 339, 340, 341, 342, 343, 344, 345, 346, + 347, 348, 349, 350, 1342, 728, 1343, 353, 354, 0, + 0, 356, 357, 729, 358, 0, 0, 360, 1344, 362, + 363, 364, 0, 365, 0, 0, 366, 367, 368, 0, + 0, 0, 730, 731, 732, 0, 371, 372, 373, 374, + 375, 376, 377, 0, 378, 0, 380, 0, 382, 383, + 384, 0, 385, 386, 387, 388, 389, 390, 391, 1345, + 393, 394, 395, 396, 0, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 0, 407, 408, 733, 409, + 410, 0, 412, 413, 414, 415, 416, 417, 418, 419, + 0, 420, 421, 422, 423, 424, 0, 425, 1346, 427, + 428, 734, 429, 1347, 431, 0, 432, 433, 434, 435, + 436, 437, 438, 439, 440, 441, 0, 0, 443, 444, + 0, 445, 446, 447, 448, 449, 450, 0, 1348, 1349, + 0, 0, 453, 0, 455, 0, 0, 457, 458, 459, + 460, 461, 462, 463, 0, 0, 464, 465, 466, 467, + 468, 0, 0, 469, 470, 471, 472, 473, 0, 1350, + 0, 476, 735, 477, 478, 479, 0, 0, 480, 0, + 0, 481, 482, 483, 484, 485, 0, 1330, 0, 0, + 0, 0, 0, 0, 0, 495, 496, 497, 200, 201, + 202, 203, 204, 205, 206, 207, 0, 209, 210, 211, + 0, 0, 0, 0, 0, 0, 0, 212, 213, 0, + 214, 215, 713, 216, 217, 218, 0, 1331, 714, 1332, + 1333, 0, 223, 224, 225, 226, 227, 0, 0, 228, + 229, 1334, 1335, 232, 0, 233, 234, 235, 236, 0, + 0, 715, 0, 238, 239, 240, 241, 716, 242, 243, + 0, 244, 245, 246, 247, 248, 249, 0, 717, 250, + 251, 0, 0, 0, 718, 0, 0, 0, 252, 253, + 254, 255, 256, 257, 1336, 1337, 260, 0, 261, 0, + 262, 263, 264, 265, 266, 0, 267, 268, 269, 0, + 0, 270, 271, 1005, 273, 274, 0, 275, 276, 277, + 0, 278, 279, 0, 280, 281, 282, 283, 0, 285, + 286, 287, 0, 0, 289, 0, 290, 1338, 292, 0, + 293, 0, 294, 719, 0, 720, 295, 296, 297, 0, + 298, 0, 0, 300, 0, 301, 302, 303, 304, 305, + 721, 306, 307, 308, 0, 309, 310, 311, 312, 313, + 314, 0, 315, 722, 0, 317, 318, 319, 320, 1339, + 1340, 0, 1341, 0, 324, 723, 724, 325, 725, 326, + 327, 328, 329, 330, 331, 332, 0, 333, 0, 726, + 335, 727, 0, 336, 337, 338, 0, 0, 339, 340, + 341, 342, 343, 344, 345, 346, 347, 348, 349, 350, + 1342, 728, 1343, 353, 354, 0, 0, 356, 357, 729, + 358, 0, 0, 360, 1344, 362, 363, 364, 0, 365, + 0, 0, 366, 367, 368, 0, 0, 0, 730, 731, + 732, 0, 371, 372, 373, 374, 375, 376, 377, 0, + 378, 0, 380, 0, 382, 383, 384, 0, 385, 386, + 387, 388, 389, 390, 391, 1345, 393, 394, 395, 396, + 0, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 0, 407, 408, 733, 409, 410, 0, 412, 413, + 414, 415, 416, 417, 418, 419, 0, 420, 421, 422, + 423, 424, 0, 425, 1881, 427, 428, 734, 429, 1347, + 431, 0, 432, 433, 434, 435, 436, 437, 438, 439, + 440, 441, 0, 0, 443, 444, 0, 445, 446, 447, + 448, 449, 450, 0, 1348, 1349, 0, 0, 453, 0, + 455, 0, 0, 457, 458, 459, 460, 461, 462, 463, + 0, 0, 464, 465, 466, 467, 468, 0, 0, 469, + 470, 471, 472, 473, 0, 1350, 0, 476, 735, 477, + 478, 479, 0, 0, 480, 0, 0, 481, 482, 483, + 484, 485, 0, 1330, 0, 0, 0, 0, 0, 0, + 0, 495, 496, 497, 200, 201, 202, 203, 204, 205, + 206, 207, 0, 209, 210, 211, 0, 0, 0, 0, + 0, 0, 0, 212, 213, 0, 214, 215, 713, 216, + 217, 218, 0, 1331, 714, 1332, 1333, 0, 223, 224, + 225, 226, 227, 0, 0, 228, 229, 1334, 1335, 232, + 0, 233, 234, 235, 236, 0, 0, 715, 0, 238, + 239, 240, 241, 716, 242, 243, 0, 244, 245, 246, + 247, 248, 249, 0, 717, 250, 251, 0, 0, 0, + 718, 0, 0, 0, 252, 253, 254, 255, 256, 257, + 1336, 1337, 260, 0, 261, 0, 262, 263, 264, 265, + 266, 0, 267, 268, 269, 0, 0, 270, 271, 1005, + 273, 274, 0, 275, 276, 277, 0, 278, 279, 0, + 280, 281, 282, 283, 0, 285, 286, 287, 0, 0, + 289, 0, 290, 1338, 292, 0, 293, 0, 294, 719, + 0, 720, 295, 296, 297, 0, 298, 0, 0, 300, + 0, 301, 302, 303, 304, 305, 721, 306, 307, 308, + 0, 309, 310, 311, 312, 313, 314, 0, 315, 722, + 0, 317, 318, 319, 320, 1339, 1340, 0, 1341, 0, + 324, 723, 724, 325, 725, 326, 327, 328, 329, 330, + 331, 332, 0, 333, 0, 726, 335, 727, 0, 336, + 337, 338, 0, 0, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 1342, 728, 1343, 353, + 354, 0, 0, 356, 357, 729, 358, 0, 0, 360, + 1344, 362, 363, 364, 0, 365, 0, 0, 366, 367, + 368, 0, 0, 0, 730, 731, 732, 0, 371, 372, + 373, 374, 375, 376, 377, 0, 378, 0, 380, 0, + 382, 383, 384, 0, 385, 386, 387, 388, 389, 390, + 391, 1345, 393, 394, 395, 396, 0, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 0, 407, 408, + 733, 409, 410, 0, 412, 413, 414, 415, 416, 417, + 418, 419, 0, 420, 421, 422, 423, 424, 0, 425, + 0, 427, 428, 734, 429, 1347, 431, 0, 432, 433, + 434, 435, 436, 437, 438, 439, 440, 441, 0, 0, + 443, 444, 0, 445, 446, 447, 448, 449, 450, 0, + 1348, 1349, 0, 0, 453, 0, 455, 0, 0, 457, + 458, 459, 460, 461, 462, 463, 0, 0, 464, 465, + 466, 467, 468, 0, 0, 469, 470, 471, 472, 473, + 0, 1350, 0, 476, 735, 477, 478, 479, 0, 0, + 480, 0, 0, 481, 482, 483, 484, 485, 0, 1330, + 0, 0, 0, 0, 0, 0, 0, 495, 496, 497, + 200, 201, 202, 203, 204, 205, 206, 207, 0, 209, + 210, 211, 0, 0, 0, 0, 0, 0, 0, 212, + 213, 0, 214, 215, 713, 216, 217, 218, 0, 0, + 714, 0, 0, 0, 223, 224, 225, 226, 227, 0, + 0, 228, 229, 0, 0, 232, 0, 233, 234, 235, + 236, 0, 0, 715, 0, 238, 239, 240, 241, 716, + 242, 243, 0, 244, 245, 246, 247, 248, 249, 0, + 717, 250, 251, 0, 0, 0, 718, 0, 0, 0, + 252, 253, 254, 255, 256, 257, 0, 0, 260, 0, + 261, 0, 262, 263, 264, 265, 266, 0, 267, 268, + 269, 0, 0, 270, 271, 272, 273, 274, 0, 275, + 276, 277, 0, 278, 279, 0, 280, 281, 282, 283, + 0, 285, 286, 287, 0, 0, 289, 0, 290, 0, + 292, 0, 293, 0, 294, 719, 0, 720, 295, 296, + 297, 0, 298, 0, 0, 300, 0, 301, 302, 303, + 304, 305, 721, 306, 307, 308, 0, 309, 310, 311, + 312, 313, 314, 0, 315, 722, 0, 317, 318, 319, + 320, 0, 0, 0, 0, 0, 324, 723, 724, 325, + 725, 326, 327, 328, 329, 330, 331, 332, 0, 333, + 0, 726, 335, 727, 0, 336, 337, 338, 0, 0, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 0, 728, 0, 353, 354, 0, 0, 356, + 357, 729, 358, 0, 0, 360, 0, 362, 363, 364, + 0, 365, 0, 0, 366, 367, 368, 0, 0, 0, + 730, 731, 732, 0, 371, 372, 373, 374, 375, 376, + 377, 0, 378, 0, 380, 0, 382, 383, 384, 0, + 385, 386, 387, 388, 389, 390, 391, 0, 393, 394, + 395, 396, 0, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 0, 407, 408, 733, 409, 410, 0, + 412, 413, 414, 415, 416, 417, 418, 419, 0, 420, + 421, 422, 423, 424, 0, 425, 0, 427, 428, 734, + 429, 0, 431, 0, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 0, 0, 443, 444, 0, 445, + 446, 447, 448, 449, 450, 0, 0, 0, 0, 0, + 453, 0, 455, 0, 0, 457, 458, 459, 460, 461, + 462, 463, 0, 0, 464, 465, 466, 467, 468, 0, + 0, 469, 470, 471, 472, 473, 0, 0, 0, 476, + 735, 477, 478, 479, 0, 0, 480, 0, 0, 481, + 482, 483, 484, 485, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 495, 496, 497 +}; + +static const yytype_int16 yycheck[] = +{ + 0, 0, 0, 0, 0, 0, 47, 16, 164, 524, + 184, 11, 33, 888, 21, 24, 896, 706, 659, 26, + 20, 737, 20, 617, 618, 619, 1107, 711, 1495, 623, + 892, 1207, 961, 7, 947, 925, 1107, 797, 1173, 850, + 14, 776, 1595, 551, 12, 1212, 21, 47, 859, 832, + 172, 26, 567, 788, 1109, 1346, 916, 1032, 180, 974, + 2198, 42, 181, 41, 1216, 20, 780, 186, 1140, 565, + 1303, 666, 2356, 569, 2754, 1399, 195, 1212, 1384, 1160, + 17, 516, 1107, 579, 1225, 1384, 1363, 22, 1207, 1160, + 1928, 1384, 1384, 1003, 1004, 2480, 879, 1384, 33, 1259, + 1531, 1156, 837, 2961, 1384, 840, 1886, 1887, 1975, 2530, + 845, 2532, 1022, 1130, 1756, 1267, 779, 852, 2178, 782, + 2675, 2693, 2405, 3046, 2995, 560, 861, 790, 1452, 151, + 2354, 1272, 1273, 3264, 0, 1160, 2352, 2353, 166, 2657, + 3002, 3243, 0, 166, 3225, 586, 2934, 2935, 0, 1199, + 0, 0, 2289, 1160, 662, 38, 2867, 2675, 703, 3466, + 3206, 788, 2973, 703, 5, 1401, 166, 759, 2679, 2680, + 2681, 2682, 2683, 2684, 31, 1408, 9, 753, 66, 5, + 44, 58, 0, 992, 993, 0, 0, 35, 22, 2020, + 1050, 2929, 0, 37, 903, 9, 3904, 18, 3658, 5, + 25, 9, 37, 5, 79, 914, 18, 13, 22, 1018, + 72, 13, 190, 22, 22, 0, 150, 58, 0, 5, + 29, 2059, 103, 145, 5, 189, 3885, 5, 3787, 156, + 5, 2350, 58, 5, 35, 13, 830, 150, 26, 27, + 51, 96, 18, 5, 51, 11, 150, 5, 5, 5, + 170, 170, 98, 5, 153, 150, 5, 182, 151, 22, + 3857, 5, 98, 188, 127, 5, 29, 2255, 2256, 159, + 64, 196, 2260, 110, 2411, 9, 132, 22, 150, 2398, + 245, 105, 2482, 76, 29, 1366, 153, 2125, 68, 2127, + 150, 20, 275, 132, 252, 1366, 76, 3976, 3977, 120, + 815, 4, 34, 247, 151, 22, 9, 3169, 120, 51, + 103, 40, 2300, 2301, 219, 11, 158, 163, 352, 96, + 22, 105, 4207, 5, 393, 141, 96, 163, 141, 51, + 83, 96, 150, 925, 1094, 150, 150, 142, 32, 0, + 36, 1366, 150, 412, 120, 3, 4, 5, 305, 5, + 524, 9, 170, 1936, 11, 170, 170, 30, 106, 384, + 1076, 149, 170, 151, 5, 150, 0, 1565, 150, 193, + 66, 290, 4, 219, 1349, 294, 222, 9, 1845, 36, + 11, 1579, 4041, 219, 427, 170, 222, 430, 170, 511, + 4275, 122, 208, 567, 68, 208, 430, 9, 115, 356, + 319, 897, 155, 522, 912, 310, 1989, 526, 232, 66, + 4007, 76, 307, 115, 261, 314, 279, 111, 537, 167, + 295, 103, 83, 230, 229, 3471, 1336, 1337, 1626, 3889, + 103, 244, 266, 555, 1344, 1315, 1311, 169, 259, 232, + 197, 105, 564, 426, 343, 103, 11, 314, 352, 83, + 96, 245, 396, 237, 68, 184, 280, 953, 68, 301, + 230, 426, 103, 362, 310, 321, 430, 963, 293, 290, + 978, 36, 430, 392, 310, 1530, 343, 324, 2989, 975, + 305, 834, 321, 255, 4163, 296, 927, 342, 378, 296, + 385, 339, 2692, 1565, 155, 96, 430, 506, 319, 8, + 1092, 66, 364, 430, 426, 1097, 1098, 1579, 352, 150, + 430, 345, 319, 347, 290, 3070, 1327, 430, 327, 1600, + 1255, 155, 1257, 1306, 1187, 1334, 1335, 4086, 4236, 1600, + 188, 356, 413, 426, 1343, 4194, 424, 374, 339, 4198, + 428, 1301, 551, 552, 379, 150, 587, 333, 334, 426, + 706, 1265, 3070, 211, 296, 430, 377, 383, 430, 3661, + 372, 407, 426, 426, 327, 342, 426, 589, 505, 426, + 11, 407, 352, 1486, 296, 1600, 4235, 342, 1633, 504, + 426, 1089, 327, 3629, 509, 426, 586, 587, 586, 1324, + 1881, 598, 425, 600, 1456, 602, 384, 1189, 3460, 2437, + 426, 608, 1147, 417, 418, 1197, 430, 1147, 961, 417, + 418, 429, 3323, 1890, 429, 429, 1243, 585, 393, 430, + 426, 429, 631, 598, 426, 600, 191, 602, 3674, 1125, + 1206, 1493, 587, 608, 609, 610, 297, 412, 612, 3450, + 1502, 815, 651, 383, 429, 426, 3218, 429, 426, 658, + 628, 426, 661, 662, 663, 1247, 422, 388, 1250, 1251, + 2944, 3968, 3400, 297, 426, 3237, 3404, 695, 426, 1529, + 426, 1531, 695, 4133, 426, 424, 3187, 426, 352, 428, + 802, 1541, 426, 417, 418, 1545, 426, 352, 430, 392, + 812, 51, 426, 1553, 1554, 695, 342, 697, 697, 697, + 697, 697, 697, 681, 1940, 1857, 1566, 1567, 430, 1418, + 1886, 352, 376, 638, 417, 418, 18, 1577, 1427, 2499, + 1312, 2501, 1431, 1804, 1239, 2949, 422, 1894, 1437, 1438, + 685, 392, 710, 1804, 659, 4195, 3782, 393, 352, 248, + 413, 342, 352, 3789, 301, 867, 1455, 352, 1557, 1558, + 191, 424, 677, 426, 427, 428, 412, 430, 392, 417, + 418, 108, 419, 420, 421, 422, 427, 108, 429, 3, + 426, 3897, 413, 698, 752, 103, 5, 660, 96, 1804, + 152, 664, 74, 152, 759, 417, 418, 428, 419, 420, + 421, 422, 3, 427, 5, 429, 74, 1804, 2636, 2637, + 2631, 1154, 5, 2634, 2635, 417, 418, 2638, 413, 246, + 2929, 1405, 2365, 60, 16, 108, 373, 2648, 120, 5, + 112, 246, 831, 428, 144, 1875, 159, 8, 60, 76, + 11, 697, 83, 1914, 112, 230, 1917, 5, 129, 697, + 2977, 75, 183, 1914, 18, 697, 1917, 697, 697, 242, + 24, 102, 417, 418, 419, 420, 421, 422, 1499, 1500, + 5, 2849, 242, 23, 2852, 2853, 2854, 2855, 2856, 2857, + 2858, 2859, 2860, 2861, 103, 42, 248, 2657, 744, 248, + 2999, 303, 133, 130, 1237, 152, 152, 98, 2055, 3274, + 183, 125, 1917, 3790, 103, 2675, 187, 230, 130, 97, + 147, 60, 242, 912, 413, 414, 415, 11, 417, 418, + 419, 420, 421, 422, 180, 147, 925, 842, 108, 108, + 4051, 1436, 788, 2911, 2912, 4027, 103, 927, 2104, 927, + 132, 120, 1428, 870, 2094, 5, 296, 862, 863, 864, + 96, 175, 133, 1439, 103, 18, 120, 103, 268, 958, + 925, 24, 163, 3741, 1307, 1451, 930, 259, 932, 106, + 934, 252, 936, 335, 938, 939, 940, 3864, 260, 978, + 259, 945, 2752, 1326, 22, 173, 417, 418, 419, 420, + 421, 422, 260, 3754, 312, 3756, 986, 424, 290, 1424, + 145, 428, 230, 183, 3674, 252, 1492, 3859, 316, 166, + 1496, 290, 1498, 170, 426, 1501, 1006, 3745, 219, 1050, + 191, 222, 3750, 408, 342, 3753, 4142, 319, 1371, 312, + 167, 1462, 70, 232, 184, 372, 273, 952, 3, 77, + 264, 372, 4134, 426, 237, 252, 1036, 105, 305, 321, + 207, 273, 1751, 1052, 19, 378, 426, 120, 1563, 974, + 1050, 237, 380, 1062, 346, 232, 104, 2255, 2256, 413, + 4141, 312, 2260, 1072, 392, 1239, 74, 248, 346, 237, + 1423, 342, 3969, 232, 428, 366, 232, 3498, 237, 372, + 1089, 270, 3979, 1092, 1093, 259, 426, 191, 1097, 1098, + 372, 342, 237, 360, 5, 3966, 1118, 4143, 426, 310, + 75, 303, 2300, 2301, 112, 1133, 1134, 4030, 1136, 177, + 1133, 1134, 258, 1136, 273, 103, 290, 1092, 3980, 321, + 367, 312, 1097, 1098, 141, 74, 174, 286, 145, 380, + 307, 365, 2042, 1133, 1134, 367, 1136, 292, 3422, 373, + 378, 392, 376, 341, 342, 319, 150, 319, 3432, 74, + 125, 342, 600, 601, 602, 252, 323, 605, 606, 607, + 1971, 196, 230, 112, 232, 3448, 170, 615, 1287, 359, + 427, 1149, 120, 430, 44, 426, 332, 3948, 1103, 335, + 159, 78, 372, 2255, 2256, 52, 259, 112, 2260, 380, + 259, 208, 103, 60, 3418, 170, 407, 3413, 191, 2280, + 175, 392, 163, 105, 303, 2286, 3430, 3945, 367, 2280, + 427, 3199, 309, 430, 1189, 2286, 115, 290, 117, 2496, + 117, 290, 1197, 106, 94, 1150, 2503, 244, 2300, 2301, + 1893, 4093, 4090, 4091, 292, 426, 417, 418, 419, 420, + 421, 422, 107, 2118, 3304, 1598, 319, 1184, 2128, 237, + 319, 230, 260, 246, 1263, 2280, 428, 1232, 219, 3814, + 2122, 2286, 1436, 95, 1383, 272, 2077, 2078, 2079, 2080, + 426, 250, 1247, 372, 352, 1250, 1251, 1940, 2089, 154, + 1399, 3400, 105, 280, 167, 3404, 1211, 335, 1266, 264, + 3070, 193, 354, 1218, 259, 1417, 3814, 354, 1961, 3130, + 3872, 107, 250, 4165, 1426, 3136, 3137, 3138, 3139, 3140, + 3141, 260, 182, 417, 418, 419, 420, 421, 422, 38, + 272, 1246, 2498, 2790, 321, 190, 301, 1990, 154, 2112, + 232, 1846, 394, 1452, 392, 260, 211, 1312, 346, 290, + 59, 250, 2984, 242, 211, 8, 294, 354, 11, 310, + 259, 1943, 430, 1278, 319, 374, 2373, 426, 4216, 1951, + 230, 1953, 426, 313, 2224, 340, 0, 1292, 319, 3236, + 193, 319, 430, 1495, 1809, 372, 1385, 1243, 280, 2498, + 1305, 290, 3370, 3371, 190, 211, 218, 394, 220, 1563, + 365, 2822, 342, 4255, 18, 145, 1892, 346, 373, 378, + 24, 376, 354, 2709, 374, 155, 259, 426, 2117, 232, + 2709, 129, 95, 2273, 2574, 374, 2709, 2709, 131, 49, + 170, 346, 2709, 141, 2133, 2134, 11, 145, 2137, 2709, + 115, 2583, 117, 105, 2143, 1382, 386, 290, 308, 290, + 232, 294, 394, 3281, 2304, 3283, 4018, 307, 5, 2530, + 2531, 2532, 9, 1400, 139, 2779, 426, 280, 171, 2530, + 2531, 2532, 1462, 4143, 1462, 95, 319, 426, 319, 187, + 345, 305, 347, 145, 57, 58, 385, 3761, 3762, 2339, + 928, 66, 0, 931, 344, 933, 278, 935, 429, 937, + 208, 2200, 175, 941, 312, 370, 120, 151, 1472, 1934, + 1474, 1522, 1476, 326, 1478, 177, 1480, 170, 1463, 8, + 1484, 386, 11, 1513, 1513, 1513, 1513, 1513, 1513, 345, + 3905, 347, 356, 392, 342, 179, 244, 303, 191, 2442, + 1508, 305, 392, 393, 252, 218, 1461, 220, 4, 392, + 194, 1550, 172, 9, 370, 1898, 103, 232, 259, 299, + 8, 205, 237, 11, 3692, 331, 430, 242, 230, 294, + 232, 430, 380, 3984, 392, 83, 426, 279, 1543, 1544, + 28, 275, 234, 2654, 1499, 1500, 1551, 392, 2170, 290, + 1555, 1556, 356, 2654, 319, 248, 1521, 2467, 218, 3811, + 220, 1528, 304, 2674, 2504, 1570, 2844, 1572, 2739, 2107, + 230, 2742, 430, 2674, 159, 1605, 313, 32, 426, 129, + 115, 129, 117, 3835, 39, 430, 145, 1592, 141, 1594, + 2868, 141, 145, 141, 241, 145, 3745, 145, 258, 2654, + 3183, 3750, 150, 2141, 3753, 342, 165, 155, 1647, 3777, + 158, 3779, 160, 3481, 3482, 68, 300, 259, 366, 2674, + 312, 2849, 309, 76, 2852, 2853, 2854, 2855, 2856, 2857, + 2858, 2859, 2860, 2861, 3783, 295, 197, 187, 259, 187, + 2166, 4056, 1846, 358, 2457, 230, 3960, 2030, 290, 386, + 342, 1800, 294, 368, 2882, 208, 1805, 280, 208, 1808, + 208, 2272, 191, 2274, 2275, 115, 393, 117, 291, 290, + 330, 352, 290, 1628, 259, 20, 294, 319, 345, 427, + 347, 1830, 1637, 2911, 2912, 412, 3704, 1839, 380, 139, + 393, 244, 315, 1845, 244, 40, 244, 232, 319, 426, + 392, 319, 252, 191, 252, 290, 2445, 242, 426, 412, + 3571, 3572, 3730, 3731, 292, 1864, 3023, 356, 2389, 248, + 413, 414, 415, 426, 417, 418, 419, 420, 421, 422, + 427, 80, 1769, 430, 426, 427, 421, 429, 2363, 2483, + 3003, 426, 1891, 428, 2366, 11, 309, 2849, 3897, 297, + 2852, 2853, 2854, 2855, 2856, 2857, 2858, 2859, 2860, 2861, + 248, 1791, 1791, 1814, 1769, 1816, 1915, 2511, 1753, 345, + 36, 347, 344, 2884, 392, 2718, 2321, 259, 145, 2518, + 2882, 2520, 312, 2884, 424, 3368, 1935, 237, 428, 1938, + 5, 2484, 242, 378, 342, 10, 3945, 1752, 165, 1754, + 66, 427, 84, 18, 430, 2188, 2891, 1956, 290, 2911, + 2912, 259, 342, 173, 75, 259, 366, 1966, 366, 34, + 392, 393, 246, 425, 392, 393, 50, 251, 430, 2884, + 1979, 1870, 11, 3149, 424, 3151, 426, 319, 3154, 1988, + 3156, 389, 290, 391, 392, 426, 290, 428, 1856, 3031, + 380, 425, 26, 27, 426, 246, 430, 36, 82, 426, + 251, 428, 392, 124, 2809, 421, 2871, 2872, 2607, 151, + 426, 319, 428, 2612, 84, 319, 424, 3048, 3049, 427, + 428, 429, 303, 304, 413, 414, 415, 66, 417, 418, + 419, 420, 421, 422, 21, 427, 426, 179, 430, 26, + 2985, 3919, 427, 2429, 2430, 430, 2432, 165, 358, 83, + 2815, 427, 194, 137, 430, 73, 427, 2455, 368, 430, + 392, 393, 2687, 205, 307, 413, 414, 415, 102, 417, + 418, 419, 420, 421, 422, 303, 304, 1976, 1943, 200, + 201, 151, 410, 411, 168, 227, 1951, 424, 1953, 426, + 2909, 428, 427, 214, 3065, 430, 1911, 48, 3069, 133, + 3071, 344, 427, 8, 3065, 430, 11, 309, 3069, 179, + 3071, 3199, 345, 2012, 347, 427, 197, 3838, 430, 203, + 426, 2020, 233, 234, 194, 9, 427, 31, 2878, 430, + 345, 36, 347, 4142, 4162, 205, 427, 42, 259, 430, + 2813, 3869, 427, 426, 3814, 430, 50, 246, 232, 392, + 393, 430, 191, 192, 3069, 426, 3071, 227, 300, 427, + 3217, 66, 430, 2762, 2390, 2391, 8, 2766, 2767, 11, + 2769, 48, 2771, 2772, 2039, 38, 246, 2076, 82, 427, + 2566, 2780, 430, 426, 3365, 8, 28, 409, 11, 427, + 2202, 3257, 430, 392, 393, 2207, 235, 3000, 3001, 307, + 193, 312, 2101, 307, 428, 2063, 2096, 2096, 2107, 249, + 294, 2810, 296, 36, 298, 2458, 427, 3242, 429, 42, + 304, 307, 249, 344, 2708, 346, 427, 311, 429, 3899, + 300, 342, 700, 137, 702, 319, 344, 3199, 8, 3039, + 344, 11, 2141, 66, 328, 2060, 3693, 3694, 3695, 3696, + 427, 427, 336, 430, 430, 246, 427, 2321, 344, 430, + 427, 166, 352, 430, 168, 170, 145, 427, 427, 380, + 430, 430, 427, 427, 307, 430, 430, 427, 312, 246, + 430, 392, 3370, 3371, 392, 393, 191, 192, 392, 393, + 2688, 249, 2690, 197, 0, 427, 409, 427, 430, 203, + 430, 2951, 207, 387, 374, 2170, 392, 393, 342, 38, + 2553, 344, 2555, 2359, 2700, 426, 2702, 427, 426, 2383, + 430, 427, 426, 193, 430, 3768, 427, 419, 232, 430, + 235, 409, 2938, 427, 2816, 3405, 430, 3407, 2350, 427, + 426, 1581, 430, 248, 1584, 427, 380, 170, 430, 191, + 384, 427, 149, 2751, 430, 2666, 2667, 2668, 392, 392, + 393, 427, 2941, 2942, 430, 2608, 3146, 427, 191, 192, + 430, 427, 427, 2304, 430, 430, 430, 83, 417, 418, + 419, 420, 421, 422, 427, 427, 2398, 430, 430, 2632, + 294, 426, 426, 426, 298, 427, 965, 966, 430, 307, + 304, 427, 2788, 427, 430, 2414, 248, 311, 3370, 3371, + 427, 307, 235, 430, 2304, 319, 427, 427, 323, 430, + 430, 191, 2808, 129, 328, 248, 76, 427, 2318, 48, + 8, 427, 336, 11, 430, 141, 344, 427, 427, 145, + 430, 430, 427, 427, 150, 430, 430, 2337, 344, 155, + 427, 150, 158, 430, 160, 189, 8, 426, 36, 11, + 2350, 319, 427, 427, 42, 430, 430, 2366, 427, 3414, + 2401, 430, 428, 2344, 2345, 2346, 28, 427, 248, 427, + 430, 187, 430, 387, 392, 393, 395, 391, 66, 2379, + 2379, 2379, 2379, 2379, 2379, 2738, 392, 393, 3855, 2364, + 3445, 2366, 208, 427, 154, 426, 430, 134, 2398, 414, + 415, 2401, 417, 418, 419, 420, 421, 422, 426, 3123, + 2763, 427, 134, 173, 430, 428, 427, 3498, 2343, 430, + 426, 426, 8, 427, 134, 11, 430, 3498, 244, 427, + 2549, 427, 430, 246, 430, 134, 252, 2556, 145, 206, + 128, 105, 28, 374, 246, 426, 2455, 3376, 241, 309, + 36, 211, 197, 60, 426, 3266, 42, 392, 31, 232, + 426, 413, 414, 415, 2389, 417, 418, 419, 420, 421, + 422, 395, 38, 38, 361, 2828, 259, 145, 166, 73, + 66, 297, 170, 2657, 417, 418, 419, 420, 421, 422, + 276, 251, 3352, 134, 134, 2848, 426, 3673, 134, 395, + 134, 2675, 3583, 191, 192, 134, 3704, 2626, 430, 134, + 134, 134, 3583, 246, 134, 3713, 134, 134, 246, 207, + 2873, 134, 134, 342, 426, 31, 342, 2536, 206, 191, + 146, 145, 3730, 3731, 414, 415, 145, 417, 418, 419, + 420, 421, 422, 8, 246, 426, 11, 235, 5, 5, + 366, 426, 426, 44, 3146, 2564, 2909, 145, 3583, 426, + 248, 426, 426, 28, 269, 426, 5, 426, 5, 3278, + 426, 426, 426, 389, 426, 391, 392, 3286, 3287, 426, + 166, 426, 5, 426, 170, 345, 248, 347, 426, 5, + 426, 426, 426, 426, 85, 426, 356, 426, 426, 426, + 426, 426, 426, 256, 31, 191, 192, 367, 424, 430, + 370, 427, 428, 429, 86, 206, 31, 145, 109, 145, + 352, 207, 2631, 244, 319, 2634, 2635, 352, 307, 2638, + 428, 352, 3704, 124, 352, 323, 307, 128, 352, 2648, + 352, 3713, 76, 352, 2653, 134, 232, 307, 2657, 235, + 246, 203, 311, 237, 352, 146, 352, 373, 3730, 3731, + 2779, 352, 248, 68, 0, 251, 2675, 246, 2790, 18, + 161, 175, 242, 426, 2793, 24, 352, 352, 426, 2688, + 3593, 2690, 2657, 76, 430, 259, 97, 374, 374, 2664, + 2665, 352, 2811, 48, 2669, 3585, 352, 352, 48, 250, + 2675, 352, 352, 352, 3296, 352, 352, 37, 37, 352, + 307, 430, 2721, 352, 352, 64, 246, 246, 395, 392, + 191, 3919, 426, 426, 3220, 3221, 191, 31, 2703, 417, + 418, 419, 420, 421, 422, 383, 426, 323, 30, 20, + 134, 2750, 2751, 426, 232, 103, 237, 83, 3883, 386, + 3466, 413, 414, 415, 245, 417, 418, 419, 420, 421, + 422, 2761, 2761, 374, 113, 214, 385, 242, 3477, 2694, + 232, 120, 31, 145, 123, 31, 197, 308, 134, 3708, + 134, 426, 374, 248, 374, 352, 134, 278, 134, 134, + 241, 236, 350, 129, 2719, 3291, 3292, 3293, 150, 3508, + 3509, 388, 2727, 409, 426, 141, 2731, 2929, 11, 145, + 224, 426, 224, 350, 150, 150, 319, 352, 426, 155, + 2745, 354, 158, 426, 160, 430, 175, 413, 414, 415, + 430, 417, 418, 419, 420, 421, 422, 164, 427, 164, + 187, 2816, 242, 426, 430, 3580, 247, 3919, 430, 430, + 374, 187, 427, 352, 352, 3564, 3565, 307, 75, 307, + 374, 195, 426, 195, 237, 352, 237, 426, 309, 197, + 237, 3224, 208, 38, 326, 253, 4052, 2999, 2919, 352, + 246, 230, 245, 232, 2809, 430, 2895, 307, 2929, 352, + 316, 290, 352, 242, 352, 280, 3070, 191, 3758, 31, + 191, 250, 191, 3984, 374, 374, 191, 3026, 244, 191, + 259, 426, 245, 3984, 30, 424, 252, 413, 426, 2919, + 352, 3436, 424, 352, 352, 134, 316, 352, 413, 2929, + 145, 147, 242, 426, 316, 134, 3849, 392, 246, 2948, + 2921, 2922, 2923, 2924, 246, 294, 31, 145, 413, 414, + 415, 162, 417, 418, 419, 420, 421, 422, 162, 134, + 8, 297, 246, 11, 145, 316, 246, 19, 170, 3678, + 319, 3680, 3681, 170, 170, 221, 430, 395, 156, 60, + 246, 48, 3691, 430, 3103, 66, 430, 3106, 36, 342, + 241, 3920, 197, 21, 42, 76, 427, 427, 150, 263, + 150, 2926, 2927, 2928, 13, 427, 342, 255, 427, 352, + 427, 409, 409, 389, 427, 13, 380, 427, 66, 427, + 427, 430, 103, 3376, 105, 427, 297, 389, 377, 208, + 366, 427, 427, 413, 246, 427, 3630, 173, 427, 427, + 68, 427, 426, 426, 134, 246, 352, 3543, 3544, 249, + 3546, 426, 426, 389, 395, 391, 392, 352, 3987, 352, + 181, 3070, 3991, 3992, 3924, 237, 352, 250, 134, 97, + 134, 208, 264, 264, 371, 352, 352, 352, 3087, 3086, + 352, 3090, 216, 3092, 352, 216, 216, 307, 424, 3773, + 118, 427, 428, 429, 352, 3070, 177, 352, 352, 307, + 307, 307, 352, 352, 134, 319, 37, 3116, 3117, 3989, + 352, 3086, 352, 3988, 8, 4005, 191, 11, 166, 147, + 191, 3130, 170, 191, 152, 3, 3479, 3136, 3137, 3138, + 3139, 3140, 3141, 3995, 28, 3997, 191, 3146, 191, 427, + 191, 3150, 36, 191, 192, 191, 424, 310, 42, 222, + 208, 232, 4233, 427, 3507, 96, 237, 292, 427, 207, + 413, 392, 4233, 430, 426, 430, 3519, 361, 245, 31, + 198, 3146, 66, 159, 246, 427, 352, 132, 307, 374, + 3189, 3190, 3191, 3192, 3159, 3160, 374, 235, 307, 307, + 249, 430, 273, 132, 191, 3170, 424, 126, 150, 4280, + 248, 11, 145, 427, 3913, 286, 18, 4288, 4233, 4280, + 3563, 385, 24, 58, 3189, 150, 426, 4288, 158, 145, + 4080, 247, 31, 374, 352, 22, 23, 374, 181, 352, + 27, 307, 352, 426, 31, 32, 33, 49, 35, 361, + 427, 38, 39, 427, 41, 3254, 43, 3888, 276, 361, + 427, 352, 64, 3253, 3253, 4280, 427, 430, 3967, 427, + 427, 3186, 3436, 4288, 352, 427, 427, 426, 426, 3784, + 3959, 307, 166, 301, 427, 323, 170, 145, 3400, 307, + 3205, 427, 3404, 95, 427, 313, 367, 66, 96, 427, + 191, 4000, 361, 191, 427, 195, 392, 191, 192, 425, + 425, 113, 3227, 3312, 3819, 50, 395, 145, 120, 426, + 176, 123, 71, 207, 342, 430, 344, 427, 352, 430, + 344, 3296, 430, 426, 316, 427, 155, 150, 191, 427, + 191, 191, 191, 361, 150, 426, 285, 82, 232, 48, + 427, 235, 426, 390, 427, 390, 4221, 427, 430, 254, + 194, 194, 426, 48, 248, 3708, 160, 251, 386, 242, + 172, 352, 427, 175, 427, 413, 414, 415, 430, 417, + 418, 419, 420, 421, 422, 172, 173, 174, 175, 150, + 177, 178, 413, 180, 181, 182, 392, 184, 66, 186, + 175, 188, 137, 190, 361, 3514, 237, 194, 195, 196, + 3400, 237, 413, 430, 3404, 430, 218, 3526, 220, 134, + 352, 191, 110, 237, 152, 425, 150, 374, 230, 316, + 232, 31, 121, 168, 3433, 388, 374, 96, 392, 323, + 242, 426, 392, 150, 178, 249, 426, 3458, 250, 150, + 329, 426, 3938, 3443, 3443, 3452, 258, 259, 426, 379, + 285, 427, 3948, 427, 426, 194, 426, 391, 203, 262, + 246, 427, 3387, 3388, 3389, 3390, 427, 286, 427, 392, + 352, 145, 426, 31, 237, 426, 217, 3452, 290, 173, + 426, 133, 294, 295, 250, 48, 304, 232, 48, 427, + 426, 304, 252, 426, 374, 230, 246, 3504, 4092, 140, + 277, 60, 344, 3999, 60, 116, 4215, 319, 378, 249, + 285, 430, 379, 31, 259, 150, 389, 145, 330, 413, + 414, 415, 283, 417, 418, 419, 420, 421, 422, 3504, + 121, 425, 175, 246, 392, 31, 246, 431, 426, 48, + 427, 249, 3517, 3518, 249, 290, 427, 3522, 3523, 294, + 426, 303, 372, 298, 108, 426, 303, 17, 28, 304, + 133, 277, 3571, 3572, 1290, 377, 311, 3920, 2062, 426, + 697, 1098, 2366, 4088, 319, 4071, 3585, 1924, 2511, 3069, + 3589, 1983, 3591, 328, 3841, 3594, 3595, 2653, 4005, 755, + 3583, 336, 3649, 3878, 3246, 3883, 3623, 3950, 3605, 2436, + 3887, 3757, 2158, 4169, 3783, 4220, 4125, 4124, 4028, 4184, + 3784, 2440, 3650, 3210, 2053, 3065, 8, 2053, 2531, 11, + 1386, 3215, 3217, 3745, 2048, 2720, 4225, 4288, 3750, 31, + 3605, 3753, 4280, 2674, 3987, 2659, 3645, 4191, 3991, 3992, + 3814, 3821, 387, 1378, 36, 3819, 4103, 4177, 50, 3824, + 42, 26, 3299, 954, 3965, 3255, 4052, 1887, 3257, 552, + 4203, 3783, 4282, 3672, 2610, 4020, 1754, 21, 676, 1753, + 2379, 1463, 3239, 3444, 66, 2982, 689, 2380, 1124, 33, + 82, 1789, 1143, 1142, 3693, 3694, 3695, 3696, 2386, 1772, + 2392, 2406, 1788, 2398, 2929, 3406, 3818, 3946, 681, 2983, + 54, 2029, 1145, 3922, 2886, 4156, 2894, 504, 4157, 1149, + 4160, 2318, 509, 67, 511, 2383, 2226, 514, 2316, 516, + 2978, 518, -1, 1629, -1, 522, 80, 524, -1, 526, + 527, -1, -1, 3855, -1, 137, -1, 534, -1, -1, + 537, -1, -1, 97, -1, 3745, -1, -1, -1, -1, + 3750, 3676, -1, 3753, 551, -1, -1, -1, 555, -1, + -1, -1, -1, 560, 118, -1, 168, 564, -1, -1, + 567, -1, -1, -1, 166, 3897, -1, -1, 170, -1, + -1, -1, 136, -1, -1, 582, -1, -1, -1, -1, + 587, -1, -1, 147, -1, 197, 3770, -1, 152, 191, + 192, 203, -1, -1, 158, 3814, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 207, -1, 8, -1, 173, + 11, -1, -1, 3945, -1, -1, -1, -1, -1, 3838, + 232, 628, -1, 3842, -1, -1, -1, -1, -1, 3814, + 232, 638, 639, 235, -1, 36, -1, -1, -1, -1, + -1, 42, 21, -1, -1, -1, 248, -1, -1, -1, + 657, -1, 659, 660, -1, 662, -1, 664, -1, -1, + 3870, 3870, -1, -1, -1, 66, -1, -1, -1, -1, + 677, -1, -1, -1, 681, 54, -1, -1, -1, -1, + 687, -1, 294, -1, 248, -1, 298, -1, 67, -1, + -1, 698, 304, -1, 258, -1, -1, -1, -1, 311, + -1, 80, -1, 710, 4088, -1, -1, 319, 8, -1, + -1, 11, 276, -1, -1, -1, 328, -1, -1, -1, + -1, 323, -1, 3858, 336, -1, -1, 128, 28, -1, + -1, -1, -1, -1, -1, 3945, 36, 301, -1, 118, + -1, 305, 42, 307, -1, 752, -1, -1, -1, 313, + -1, -1, 316, 3888, 761, 762, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 166, 66, -1, 147, 170, + -1, -1, -1, 152, -1, 387, -1, -1, 342, 391, + 344, -1, -1, -1, 348, -1, 4005, -1, -1, -1, + 191, 192, 356, -1, -1, 802, -1, 361, -1, -1, + 4132, -1, -1, -1, -1, 812, 207, -1, 815, 373, + 4142, 413, 414, 415, -1, 417, 418, 419, 420, 421, + 422, 828, 386, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 235, 842, -1, -1, -1, -1, + 4172, 848, 849, 3978, -1, -1, -1, 248, -1, -1, + -1, -1, -1, -1, -1, 862, 863, 864, 865, -1, + 867, -1, -1, -1, -1, -1, 166, -1, -1, 248, + 170, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 892, 893, 894, -1, -1, + -1, 191, 192, -1, -1, -1, -1, 276, -1, -1, + -1, -1, -1, -1, -1, 912, -1, 207, -1, 916, + -1, -1, -1, -1, -1, -1, -1, -1, 925, -1, + -1, 3, 323, -1, -1, -1, 8, -1, 307, 11, + -1, -1, 232, -1, 313, 235, -1, 316, -1, -1, + 947, 948, -1, -1, -1, 952, 28, 954, 248, 31, + -1, 251, 4284, -1, 36, -1, -1, -1, -1, -1, + 42, -1, -1, 342, 971, -1, -1, 974, -1, 348, + 977, 978, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 361, 990, 66, -1, -1, 4238, -1, -1, + -1, -1, -1, 4203, 4203, 4203, 4203, 4203, 4203, -1, + -1, -1, -1, -1, -1, -1, -1, 386, -1, -1, + -1, -1, 1019, -1, 4233, -1, 417, 418, 419, 420, + 421, 422, -1, 323, -1, -1, -1, -1, 4238, 4238, + 4238, 4238, 4238, 4238, -1, -1, -1, -1, -1, -1, + 1047, 1048, -1, 1050, -1, -1, 31, -1, 4233, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 1067, 4280, -1, -1, -1, 50, -1, -1, -1, 4288, + -1, -1, 4282, 4282, 4282, 4282, 4282, 4282, -1, -1, + -1, -1, 1089, -1, 166, -1, -1, -1, 170, -1, + 1097, 1098, -1, -1, -1, 4280, 1103, 82, -1, 1106, + -1, -1, -1, 4288, -1, -1, -1, -1, -1, 191, + 192, -1, -1, 413, 414, 415, -1, 417, 418, 419, + 420, 421, 422, -1, -1, 207, -1, -1, 1135, -1, + 430, -1, 1139, 1140, -1, -1, -1, -1, -1, -1, + -1, -1, 1149, 1150, 1151, -1, -1, -1, -1, -1, + 232, -1, 137, 235, -1, -1, -1, -1, -1, -1, + 1167, -1, -1, -1, -1, -1, 248, -1, -1, 251, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 168, -1, -1, -1, -1, -1, -1, + -1, -1, 1199, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 1211, 1212, -1, -1, -1, -1, + -1, 1218, 197, -1, 1221, -1, -1, -1, 203, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 8, -1, + -1, 11, 1239, -1, -1, -1, -1, -1, -1, 1246, + -1, 323, -1, -1, -1, -1, -1, 232, 28, -1, + -1, -1, -1, -1, -1, -1, 36, -1, -1, 1266, + -1, -1, 42, 8, -1, -1, 11, 1274, 1275, 1276, + 1277, 1278, -1, -1, -1, -1, -1, -1, -1, -1, + 1287, -1, 1289, 28, -1, 1292, 66, -1, -1, -1, + -1, 36, -1, -1, -1, -1, 1303, 42, 1305, -1, + -1, -1, -1, -1, -1, -1, 1313, 1314, -1, 294, + -1, -1, 1319, 298, -1, -1, -1, -1, -1, 304, + -1, 66, -1, -1, -1, -1, 311, -1, -1, -1, + -1, 413, 414, 415, 319, 417, 418, 419, 420, 421, + 422, -1, -1, 328, -1, -1, -1, -1, -1, -1, + -1, 336, -1, -1, -1, -1, -1, -1, 1365, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 1383, -1, -1, -1, + -1, -1, 1389, 1390, 1391, 1392, 166, -1, -1, -1, + 170, -1, 1399, -1, -1, -1, -1, -1, -1, -1, + -1, 1408, 387, -1, -1, -1, 391, 392, -1, -1, + 1417, 191, 192, -1, -1, -1, -1, 1424, -1, 1426, + -1, 166, -1, -1, -1, 170, -1, 207, -1, 1436, + -1, -1, -1, -1, 1441, -1, -1, -1, -1, -1, + -1, -1, -1, 1450, -1, 1452, 191, 192, -1, 1456, + 1457, -1, 232, -1, 1461, 235, 1463, -1, -1, -1, + -1, -1, 207, -1, -1, -1, -1, -1, 248, -1, + -1, 251, -1, -1, -1, -1, -1, -1, -1, 1486, + -1, -1, -1, -1, -1, -1, 1493, 232, 1495, -1, + 235, -1, 1499, 1500, -1, 1502, -1, -1, -1, -1, + -1, 1508, -1, 248, -1, -1, 251, -1, -1, -1, + -1, -1, -1, -1, 1521, 1522, -1, -1, 1525, -1, + -1, -1, 1529, -1, 1531, -1, -1, -1, -1, -1, + -1, 1538, -1, -1, 1541, -1, -1, -1, 1545, -1, + -1, 8, -1, 323, 11, -1, 1553, 1554, -1, -1, + -1, -1, -1, -1, 1561, -1, 1563, 1564, 1565, 1566, + 1567, 28, -1, -1, -1, -1, -1, 1574, 1575, 36, + 1577, -1, 1579, 1580, -1, 42, 1583, -1, 323, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 1599, -1, -1, -1, 1603, 1604, -1, 66, + -1, 1608, -1, -1, -1, 1612, -1, 1614, 1615, 1616, + 1617, 1618, 1619, 1620, 1621, 1622, -1, 1624, -1, -1, + -1, 1628, 1629, -1, 1631, -1, -1, -1, -1, -1, + 1637, -1, -1, 413, 414, 415, -1, 417, 418, 419, + 420, 421, 422, -1, -1, -1, -1, 427, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 18, -1, -1, 413, 414, + 415, 24, 417, 418, 419, 420, 421, 422, -1, -1, + -1, -1, 427, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 166, + -1, -1, -1, 170, -1, -1, -1, -1, -1, -1, + -1, 64, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 191, 192, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 207, -1, -1, -1, -1, 1752, -1, 1754, -1, 1756, + -1, -1, -1, 18, -1, -1, -1, -1, -1, 24, + 113, -1, -1, -1, -1, 232, -1, 120, 235, -1, + 123, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 248, -1, -1, 251, 1792, -1, 1794, -1, -1, + -1, -1, -1, 1800, -1, -1, -1, -1, 1805, 64, + -1, 1808, 1809, -1, -1, -1, -1, 1814, -1, 1816, + -1, -1, -1, -1, -1, -1, 8, -1, -1, 11, + -1, -1, 175, 1830, -1, -1, 1833, -1, -1, -1, + -1, -1, 1839, -1, 1841, 1842, 1843, -1, 1845, 1846, + -1, 1848, -1, 1850, 36, 1852, 1853, -1, 113, 1856, + 42, -1, -1, -1, -1, 120, 323, 1864, 123, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 1875, -1, + -1, -1, -1, -1, 66, -1, -1, 230, -1, 232, + -1, -1, -1, -1, 1891, -1, -1, 1894, -1, 242, + -1, -1, -1, 1900, -1, -1, -1, 250, 1905, -1, + -1, -1, -1, -1, 1911, -1, 259, -1, 1915, -1, + 175, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 1927, 1928, -1, -1, -1, -1, -1, 1934, 1935, -1, + -1, 1938, -1, -1, -1, -1, 128, 290, -1, -1, + -1, 294, 1949, -1, -1, -1, 413, 414, 415, 1956, + 417, 418, 419, 420, 421, 422, -1, -1, -1, 1966, + 427, -1, -1, -1, -1, 230, 319, 232, 1975, -1, + 1977, 1978, 1979, -1, 166, -1, -1, 242, 170, -1, + -1, 1988, -1, -1, -1, 250, -1, -1, -1, -1, + -1, -1, -1, -1, 259, -1, -1, -1, 2005, 191, + 192, -1, -1, -1, -1, -1, 2013, 2014, 2015, 2016, + 2017, 2018, -1, -1, -1, 207, -1, -1, -1, -1, + -1, 2028, -1, -1, 377, 290, -1, -1, -1, 294, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 235, -1, -1, -1, -1, 2055, -1, + -1, -1, 2059, 2060, 319, -1, 248, 2064, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 8, -1, -1, 11, -1, + -1, -1, -1, 2090, -1, -1, -1, -1, -1, -1, + 2097, 2098, -1, -1, -1, 28, -1, -1, -1, -1, + 2107, -1, -1, 36, -1, -1, -1, -1, -1, 42, + -1, -1, 377, -1, -1, 2122, -1, 2124, 2125, 2126, + 2127, -1, -1, -1, 8, -1, -1, 11, -1, -1, + -1, 323, -1, 66, 2141, -1, -1, -1, -1, 2146, + -1, -1, -1, -1, 28, -1, -1, -1, -1, -1, + -1, 2158, 36, -1, -1, -1, -1, -1, 42, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 2176, + -1, -1, -1, -1, -1, -1, -1, 8, -1, -1, + 11, -1, 66, -1, -1, -1, -1, -1, -1, -1, + -1, 2198, -1, -1, -1, 2202, -1, 28, -1, -1, + 2207, -1, -1, -1, -1, 36, -1, -1, -1, -1, + 2217, 42, -1, 8, -1, -1, 11, 2224, 2225, -1, + -1, -1, -1, 2230, -1, 417, 418, 419, 420, 421, + 422, -1, -1, 166, -1, 66, -1, 170, -1, -1, + -1, 36, -1, -1, -1, -1, -1, 42, 2255, 2256, + -1, -1, -1, 2260, -1, -1, -1, -1, 191, 192, + -1, -1, -1, -1, -1, 2272, 2273, 2274, 2275, -1, + -1, 66, -1, -1, 207, -1, -1, -1, 2285, -1, + -1, 2288, 166, 2290, 2291, -1, 170, -1, -1, -1, + -1, -1, -1, 2300, 2301, -1, -1, 2304, -1, 232, + -1, -1, 235, -1, -1, -1, -1, 191, 192, -1, + 2317, -1, 2319, -1, 2321, 248, 2323, -1, 251, -1, + -1, -1, -1, 207, -1, -1, -1, -1, -1, -1, + -1, -1, 2339, 128, -1, 166, 2343, -1, -1, 170, + -1, -1, -1, 2350, -1, 2352, 2353, 2354, 232, -1, + -1, 235, -1, -1, -1, -1, -1, -1, -1, 2366, + 191, 192, 2369, -1, 248, -1, -1, 251, -1, -1, + -1, 166, -1, 2380, -1, 170, 207, -1, 2385, -1, + -1, -1, 2389, -1, -1, 2392, -1, -1, -1, -1, + 323, 2398, -1, -1, 2401, -1, 191, 192, 2405, -1, + -1, 232, -1, -1, 235, -1, -1, 2414, -1, -1, + -1, -1, 207, -1, -1, -1, -1, 248, -1, -1, + 251, -1, -1, -1, -1, -1, -1, -1, 2435, -1, + 2437, -1, -1, -1, -1, 2442, -1, -1, -1, 323, + 235, -1, -1, -1, -1, -1, -1, -1, 2455, -1, + -1, -1, -1, 248, -1, -1, 2463, -1, 2465, 2466, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 413, 414, 415, -1, 417, 418, 419, 420, 421, 422, + -1, -1, 323, -1, 427, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 18, -1, -1, -1, -1, + -1, 24, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 323, 413, + 414, 415, -1, 417, 418, 419, 420, 421, 422, 18, + -1, -1, 2549, 427, -1, 24, -1, -1, -1, 2556, + -1, 64, -1, -1, -1, -1, -1, -1, -1, 7, + -1, -1, -1, -1, -1, 13, 14, -1, -1, -1, + -1, 19, -1, 21, -1, -1, -1, -1, 26, -1, + 28, -1, 413, 414, 415, 64, 417, 418, 419, 420, + 421, 422, -1, -1, -1, -1, 427, -1, 46, -1, + 113, -1, -1, -1, -1, -1, -1, 120, -1, -1, + 123, -1, -1, -1, -1, -1, -1, -1, -1, 2626, + -1, -1, 417, 418, 419, 420, 421, 422, -1, 2636, + 2637, -1, -1, 8, 113, -1, 11, -1, -1, -1, + -1, 120, -1, -1, 123, -1, -1, -1, -1, -1, + -1, -1, -1, 28, -1, -1, -1, -1, -1, -1, + -1, 36, 175, -1, -1, -1, -1, 42, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 2688, -1, 2690, -1, -1, -1, 2694, -1, -1, + -1, 66, -1, -1, -1, -1, 175, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 2718, 2719, -1, -1, -1, -1, 230, -1, 232, + 2727, -1, -1, -1, 2731, -1, -1, -1, -1, 242, + 178, -1, -1, -1, -1, -1, -1, 250, 2745, 187, + -1, 189, -1, 191, 2751, 193, 259, -1, -1, -1, + -1, 230, -1, 232, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 242, -1, -1, 2773, -1, -1, 2776, + -1, 250, 2779, -1, -1, -1, -1, 290, -1, -1, + 259, 294, -1, 2790, -1, -1, 2793, -1, -1, -1, + -1, 166, -1, -1, -1, 170, -1, -1, -1, -1, + -1, -1, 2809, -1, 2811, -1, 319, -1, -1, -1, + 2817, 290, -1, -1, -1, 294, 191, 192, 2825, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 2835, -1, + -1, -1, 207, -1, 2841, -1, 2843, -1, -1, -1, + 319, -1, 2849, -1, -1, 2852, 2853, 2854, 2855, 2856, + 2857, 2858, 2859, 2860, 2861, -1, -1, 232, 2865, 2866, + 235, -1, -1, -1, 377, -1, -1, -1, -1, -1, + -1, 2878, -1, 248, -1, 2882, 251, -1, -1, 2886, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 2896, + -1, -1, 2899, -1, 2901, -1, -1, -1, 377, -1, + -1, -1, -1, 2910, 2911, 2912, -1, -1, -1, 2916, + -1, -1, 2919, -1, -1, -1, -1, -1, -1, 2926, + 2927, 2928, 2929, 2930, -1, -1, -1, 2934, 2935, -1, + -1, -1, 2939, -1, -1, -1, -1, -1, 2945, -1, + 2947, -1, 2949, -1, -1, -1, -1, -1, 323, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 2972, -1, -1, -1, -1, + -1, 2978, -1, -1, -1, 2982, -1, 2984, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 18, + -1, -1, 2999, 3000, 3001, 24, 3003, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 3017, 3018, 3019, 3020, -1, -1, -1, -1, -1, 3026, + -1, -1, -1, -1, -1, -1, 18, -1, -1, -1, + -1, -1, 24, -1, -1, 64, -1, -1, 413, 414, + 415, -1, 417, 418, 419, 420, 421, 422, 3055, -1, + -1, -1, 427, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 512, -1, -1, -1, -1, -1, + -1, 519, 64, -1, -1, -1, -1, -1, -1, -1, + 528, 529, -1, -1, 113, 533, -1, -1, -1, -1, + -1, 120, -1, -1, 123, 543, 3103, -1, -1, 3106, + -1, -1, -1, -1, 8, -1, -1, 11, 556, -1, + -1, -1, -1, 3120, -1, -1, -1, -1, -1, -1, + -1, 113, 570, -1, -1, 573, -1, 575, 120, 577, + -1, 123, 36, 8, -1, -1, 11, -1, 42, 3146, + -1, -1, -1, -1, -1, -1, 175, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 36, 66, -1, 612, -1, -1, 42, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 3186, + -1, -1, -1, 175, -1, -1, 634, -1, 636, -1, + 3197, 66, 3199, -1, -1, -1, -1, -1, 3205, -1, + -1, 230, -1, 232, -1, -1, -1, -1, -1, -1, + 3217, -1, -1, 242, -1, -1, -1, -1, -1, -1, + 3227, 250, -1, -1, 128, -1, -1, -1, -1, 3236, + 259, -1, -1, -1, -1, 3242, -1, -1, 230, 3246, + 232, 689, -1, -1, -1, -1, -1, -1, -1, -1, + 242, 3258, 3259, 128, -1, -1, -1, -1, 250, -1, + -1, 290, 166, -1, -1, 294, 170, 259, -1, -1, + -1, -1, -1, -1, 3281, -1, 3283, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 191, 192, -1, + 319, 166, 3299, -1, -1, 170, -1, -1, 290, -1, + -1, -1, 294, 207, -1, -1, -1, -1, 3315, -1, + -1, -1, -1, -1, -1, -1, 191, 192, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 319, -1, -1, + -1, 235, 207, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 791, 248, 3352, -1, -1, 377, -1, + -1, -1, -1, -1, -1, 3362, 3363, -1, 806, -1, + 235, -1, -1, 3370, 3371, -1, -1, -1, 3375, 817, + -1, -1, -1, 248, 3381, 3382, 824, -1, 3385, -1, + 3387, 3388, 3389, 3390, -1, 377, -1, 3394, 836, -1, + 3397, -1, -1, 3400, -1, -1, -1, 3404, -1, -1, + -1, -1, -1, 3410, -1, -1, 3413, -1, -1, -1, + -1, 3418, -1, -1, -1, -1, -1, 3424, -1, 323, + 868, -1, -1, 3430, -1, 8, -1, -1, 11, 3436, + -1, -1, -1, -1, -1, -1, -1, 3444, -1, -1, + -1, 3448, -1, -1, -1, 28, -1, -1, 323, -1, + -1, 3458, -1, 36, 3461, -1, -1, -1, -1, 42, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 3481, 3482, -1, -1, -1, -1, + -1, -1, 930, 66, 932, -1, 934, -1, 936, -1, + 938, 939, 940, -1, -1, -1, -1, 945, 3505, -1, + -1, -1, -1, -1, -1, 173, 174, 3514, -1, 177, + 178, -1, -1, 417, 418, 419, 420, 421, 422, 3526, + -1, -1, -1, -1, -1, -1, 194, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 3545, -1, + -1, -1, 417, 418, 419, 420, 421, 422, -1, -1, + -1, 18, 3559, -1, -1, -1, -1, 24, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 0, -1, 3585, -1, + -1, -1, -1, 166, -1, -1, 3593, 170, -1, -1, + 14, -1, -1, -1, -1, -1, -1, 64, -1, -1, + 24, -1, 26, 27, -1, -1, -1, -1, 191, 192, + -1, -1, -1, -1, 3621, -1, -1, 41, -1, -1, + -1, -1, -1, -1, 207, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 61, -1, 63, + 64, 3648, 3649, -1, -1, 69, 113, 71, -1, 232, + -1, -1, 235, 120, -1, -1, 123, 81, -1, 83, + -1, -1, -1, -1, -1, 248, -1, -1, 251, 3676, + -1, -1, -1, -1, -1, 99, 1124, -1, 102, -1, + -1, -1, -1, -1, -1, 3692, -1, -1, -1, -1, + 114, -1, 116, -1, -1, -1, 120, 3704, -1, -1, + -1, -1, 126, -1, -1, -1, 3713, -1, 175, 133, + -1, 135, -1, -1, -1, -1, -1, 141, -1, -1, + -1, -1, -1, 3730, 3731, -1, -1, 3734, -1, -1, + -1, 155, -1, -1, 3741, -1, -1, 1185, 3745, -1, + 323, -1, -1, 3750, -1, -1, 3753, 3754, -1, 3756, + -1, 3758, 3759, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 230, -1, 232, -1, -1, -1, -1, + 3777, -1, 3779, -1, -1, 242, 3783, 3784, 3785, 3786, + 3787, -1, -1, 250, -1, 209, 210, -1, -1, -1, + -1, 215, 259, -1, -1, -1, -1, -1, -1, 223, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 234, 3818, 3819, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 290, -1, -1, -1, 294, -1, -1, + 413, 414, 415, -1, 417, 418, 419, 420, 421, 422, + -1, -1, 3849, -1, 427, -1, 514, 271, 3855, -1, + 518, 3858, 319, -1, -1, -1, -1, -1, 282, -1, + -1, -1, 3869, 287, 3871, 289, 534, -1, -1, -1, + 294, -1, -1, -1, -1, 299, 3883, -1, 302, -1, + -1, 3888, 306, -1, -1, -1, -1, 311, 312, 3896, + 3897, -1, -1, -1, -1, 319, -1, -1, 322, 8, + -1, -1, 11, -1, -1, -1, 330, 21, -1, -1, + 377, -1, 3919, -1, -1, 3922, -1, 3924, 342, 28, + -1, -1, -1, -1, -1, -1, 1374, 36, -1, -1, + -1, -1, -1, 42, 3941, 359, -1, -1, 3945, 1387, + 54, 3948, -1, -1, -1, 369, -1, 3954, -1, -1, + -1, 375, -1, 67, 68, -1, 380, 66, -1, -1, + -1, -1, 76, -1, -1, -1, 80, 3974, 392, -1, + -1, 3978, -1, -1, -1, -1, -1, 1425, -1, -1, + -1, 1429, -1, 97, -1, -1, -1, -1, 3995, 3996, + 3997, 3998, 1440, -1, 1442, -1, 1444, -1, 4005, -1, + -1, 1449, 426, -1, 118, 429, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 4025, -1, + -1, -1, 136, -1, 1472, -1, 1474, -1, 1476, -1, + 1478, -1, 1480, 147, -1, -1, 1484, -1, 152, -1, + -1, -1, -1, 172, -1, -1, -1, -1, -1, -1, + -1, 180, -1, -1, -1, -1, -1, 166, -1, 173, + -1, 170, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 4080, -1, -1, -1, -1, -1, 4086, + -1, 4088, 191, 192, 198, -1, -1, -1, -1, -1, + 4097, -1, -1, 761, 762, -1, -1, -1, 207, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 4128, -1, 232, -1, 4132, 235, -1, -1, -1, + -1, -1, -1, -1, 248, 4142, -1, -1, -1, 248, + -1, -1, 251, -1, -1, -1, -1, -1, -1, 4156, + -1, -1, 4159, 4160, -1, 4162, -1, -1, -1, -1, + 828, -1, 276, -1, -1, 4172, -1, -1, -1, -1, + -1, -1, -1, 4180, -1, -1, -1, -1, -1, -1, + 848, 849, -1, -1, -1, -1, 18, 301, -1, -1, + -1, 305, 24, 307, -1, -1, -1, 865, -1, 313, + 4207, -1, 316, -1, -1, -1, -1, -1, -1, 8, + 4217, -1, 11, -1, 323, 4222, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 893, 894, -1, 342, 28, + 344, -1, 64, -1, 348, -1, -1, 36, -1, -1, + -1, -1, 356, 42, -1, -1, -1, 361, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 8, -1, + -1, 11, -1, -1, -1, -1, -1, 66, 4275, -1, + -1, -1, 386, -1, -1, -1, -1, 4284, 28, -1, + -1, 113, -1, -1, -1, -1, 36, -1, 120, -1, + -1, 123, 42, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 413, 414, 415, -1, 417, 418, + 419, 420, 421, 422, -1, -1, 66, -1, 427, -1, + -1, -1, 8, -1, -1, 11, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 28, 175, -1, -1, -1, -1, -1, -1, + 36, -1, -1, 1801, 1802, -1, 42, -1, 1806, 1807, + -1, -1, 1810, -1, -1, -1, -1, 166, -1, -1, + -1, 170, 1820, -1, -1, -1, -1, -1, -1, 1827, + 66, -1, 511, 1831, 1832, -1, -1, 1835, 1836, 1837, + -1, -1, 191, 192, -1, -1, -1, -1, 230, 1847, + 232, 1849, -1, -1, -1, -1, -1, -1, 207, -1, + 242, -1, -1, -1, -1, -1, 166, 1865, 250, -1, + 170, -1, 1870, -1, -1, -1, 555, 259, -1, -1, + -1, -1, -1, 232, -1, 564, 235, -1, -1, -1, + -1, 191, 192, -1, -1, -1, -1, -1, -1, 248, + -1, -1, 251, 1901, 1902, 1903, 1904, 207, 290, -1, + 1908, 1909, 294, -1, -1, -1, -1, -1, 1916, -1, + -1, 1919, -1, -1, -1, 1923, -1, -1, -1, -1, + 166, -1, 232, -1, 170, 235, -1, 319, -1, -1, + -1, 1939, -1, -1, -1, -1, -1, -1, 248, -1, + -1, 251, 1950, -1, 1952, 191, 192, -1, -1, 1957, + -1, -1, -1, -1, 1962, 1963, 1964, 1965, -1, 1967, + 8, 207, -1, 11, 323, -1, -1, -1, 657, 21, + -1, -1, 1980, 1981, 1982, -1, -1, -1, -1, -1, + 28, -1, -1, 1991, 1992, 377, 232, -1, 36, 235, + -1, -1, -1, 1221, 42, -1, -1, -1, 687, -1, + -1, -1, 248, -1, -1, 251, -1, -1, -1, -1, + -1, -1, -1, 323, -1, 67, -1, -1, 66, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 80, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 2051, -1, 97, 1274, 1275, 1276, 1277, + -1, 103, -1, -1, 413, 414, 415, -1, 417, 418, + 419, 420, 421, 422, -1, -1, 118, -1, 427, -1, + -1, -1, -1, -1, -1, -1, -1, 323, -1, -1, + -1, -1, -1, -1, 136, 1313, 1314, -1, -1, -1, + -1, 1319, -1, -1, -1, 147, 8, -1, -1, 11, + 152, -1, -1, 413, 414, 415, 158, 417, 418, 419, + 420, 421, 422, 802, -1, -1, 28, 427, 166, -1, + 32, 173, 170, 812, 36, -1, -1, -1, -1, -1, + 42, -1, -1, -1, -1, -1, -1, 1365, -1, -1, + -1, -1, -1, 191, 192, 834, 198, -1, -1, -1, + -1, -1, -1, -1, 66, -1, -1, -1, -1, 207, + -1, 1389, 1390, 1391, 1392, -1, -1, 413, 414, 415, + -1, 417, 418, 419, 420, 421, 422, -1, 867, -1, + -1, 427, -1, -1, 232, -1, 2194, 235, -1, -1, + -1, -1, -1, -1, -1, -1, 248, -1, -1, 111, + 248, -1, -1, 251, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 1441, -1, -1, -1, -1, -1, -1, + -1, -1, 1450, -1, 276, -1, -1, 916, -1, 1457, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 301, + -1, -1, -1, -1, 166, 307, -1, 8, 170, -1, + 11, 313, -1, -1, 316, -1, -1, -1, -1, -1, + -1, -1, 961, -1, -1, 323, -1, 28, -1, 191, + 192, -1, -1, -1, -1, 36, -1, -1, -1, -1, + 342, 42, 344, -1, -1, 207, 348, -1, -1, -1, + -1, 990, -1, -1, 356, -1, -1, -1, -1, 361, + -1, -1, -1, -1, -1, 66, -1, -1, -1, -1, + 232, 373, 657, 235, -1, -1, -1, -1, -1, -1, + 1019, -1, -1, -1, 386, -1, 248, -1, -1, 251, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 687, -1, -1, -1, -1, -1, 1047, 1048, + -1, 1050, -1, -1, -1, 413, 414, 415, -1, 417, + 418, 419, 420, 421, 422, 1603, -1, -1, 1067, 427, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 8, -1, -1, 11, -1, 2415, 2416, -1, + -1, 323, -1, -1, -1, 166, -1, 1106, 1107, 170, + -1, -1, 28, -1, -1, -1, -1, -1, -1, -1, + 36, -1, -1, -1, -1, -1, 42, -1, -1, -1, + 191, 192, -1, -1, -1, -1, 1135, -1, -1, -1, + 1139, 1140, -1, -1, -1, -1, 207, -1, -1, -1, + 66, -1, 374, -1, -1, 1154, -1, 2475, 2476, -1, + -1, 1160, 2480, -1, -1, -1, -1, 2485, 2486, 2487, + -1, 232, -1, -1, 235, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 248, -1, -1, + 251, 413, 414, 415, -1, 417, 418, 419, 420, 421, + 422, -1, -1, 2521, 2522, 2523, 2524, -1, 1207, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 145, + -1, -1, -1, -1, 150, -1, -1, -1, 1237, 2557, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 166, -1, -1, -1, 170, -1, -1, -1, -1, -1, + -1, -1, 323, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 191, 192, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 207, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 2619, -1, 1841, 1842, 1843, -1, -1, 1307, 2627, + 1848, -1, 1850, -1, 1852, 1853, 232, -1, -1, 235, + -1, -1, -1, -1, -1, -1, -1, 1326, -1, -1, + -1, -1, 248, -1, -1, 251, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 990, -1, 1346, -1, -1, + -1, -1, 413, 414, 415, -1, 417, 418, 419, 420, + 421, 422, -1, -1, 425, -1, -1, 1366, -1, -1, + -1, 2689, 1371, -1, 1019, -1, -1, -1, -1, -1, + -1, 2699, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 1047, 1048, -1, 1050, -1, 323, 2726, -1, + 2728, 1949, -1, -1, -1, -1, -1, -1, 1417, -1, + -1, -1, 1067, -1, 1423, -1, -1, 1426, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 2764, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 2778, 1106, -1, -1, -1, -1, -1, 2005, -1, -1, + -1, -1, -1, -1, -1, 2013, 2014, 2015, 2016, 2017, + 2018, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 1135, -1, -1, -1, 1139, 1140, 1495, 413, 414, 415, + -1, 417, 418, 419, 420, 421, 422, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 1529, -1, 1531, -1, -1, -1, -1, -1, -1, 1538, + -1, -1, 1541, -1, -1, -1, 1545, -1, -1, -1, + -1, -1, -1, -1, 1553, 1554, -1, -1, -1, 2097, + -1, -1, 1561, -1, -1, 1564, 1565, 1566, 1567, -1, + -1, -1, -1, -1, -1, 1574, 1575, -1, 1577, -1, + 1579, 1580, -1, -1, 1583, -1, 2124, -1, 2126, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 1598, + 1599, 1600, -1, -1, -1, 1604, -1, -1, -1, 1608, + -1, -1, -1, 1612, -1, 1614, 1615, 1616, 1617, 1618, + 1619, 1620, 1621, 1622, -1, 1624, -1, -1, -1, -1, + 1629, -1, 1631, -1, -1, -1, -1, -1, 8, -1, + -1, 11, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 28, -1, + -1, -1, -1, -1, -1, -1, 36, -1, -1, -1, + -1, -1, 42, -1, -1, -1, -1, -1, -1, 2217, + 8, -1, -1, 11, -1, -1, -1, -1, 3006, -1, + 3008, -1, -1, -1, 3012, -1, 66, -1, -1, -1, + 28, -1, -1, -1, -1, -1, -1, -1, 36, 3027, + -1, -1, 8, -1, 42, 11, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3044, -1, -1, -1, + -1, -1, 28, -1, -1, 3053, -1, -1, 66, -1, + 36, -1, -1, -1, -1, -1, 42, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 1756, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 66, -1, -1, -1, 144, 3093, 3094, 3095, 3096, 3097, + 3098, 3099, -1, -1, -1, -1, 3104, 3105, -1, 3107, + 3108, 3109, 3110, 3111, 3112, 3113, 166, -1, -1, -1, + 170, -1, -1, -1, 3122, 1804, 3124, 3125, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 191, 192, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 1833, -1, -1, 207, 166, -1, + 1839, -1, 170, -1, -1, -1, 1845, -1, -1, -1, + -1, -1, -1, -1, 150, -1, -1, -1, -1, -1, + -1, -1, 232, 191, 192, 235, -1, -1, -1, -1, + 166, -1, -1, -1, 170, 3193, 3194, 3195, 248, 207, + 3198, 251, 1881, -1, -1, 834, -1, 1886, 1887, -1, + -1, -1, -1, 1538, -1, 191, 192, -1, 268, 1898, + -1, -1, -1, -1, 232, -1, -1, 235, -1, -1, + -1, 207, -1, -1, -1, 1914, 1561, -1, 1917, 1564, + 248, -1, 1567, 251, -1, 2463, -1, 2465, 2466, 1574, + 1575, -1, -1, -1, -1, 1580, 232, -1, 1583, 235, + -1, -1, 270, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 248, 323, 1599, 251, 3274, -1, -1, 1604, + -1, -1, -1, 1608, -1, -1, -1, 1612, -1, 1614, + 1615, 1616, 1617, 1618, 1619, 1620, 1621, 1622, -1, 1624, + -1, -1, -1, -1, 1629, -1, 1631, -1, -1, -1, + -1, -1, -1, -1, -1, 323, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 337, + -1, -1, 961, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 323, -1, 2028, + -1, 2030, -1, -1, -1, -1, 834, -1, -1, -1, + -1, -1, -1, 413, 414, 415, -1, 417, 418, 419, + 420, 421, 422, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 8, + -1, -1, 11, -1, -1, 413, 414, 415, -1, 417, + 418, 419, 420, 421, 422, -1, -1, -1, -1, 28, + -1, -1, 31, -1, -1, 2104, -1, 36, -1, -1, + -1, 1756, -1, 42, -1, -1, -1, 413, 414, 415, + -1, 417, 418, 419, 420, 421, 422, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 66, -1, -1, + -1, -1, -1, 1092, -1, -1, -1, 2146, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 961, -1, -1, -1, -1, -1, -1, + -1, -1, 3490, 3491, 3492, 3493, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 1833, 2188, + -1, -1, -1, -1, -1, -1, -1, 3515, 3516, -1, + -1, -1, -1, 2202, -1, 1154, -1, -1, 2207, 3527, + 3528, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 2224, 2225, -1, -1, -1, + -1, 2230, -1, -1, -1, 2773, -1, 166, 2776, -1, + -1, 170, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 2255, 2256, 1207, -1, + -1, 2260, 191, 192, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 2272, 2273, 2274, 2275, -1, 207, 2817, + -1, 2280, -1, -1, -1, -1, 2285, 2286, 1237, 2288, + -1, 2290, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 2300, 2301, 232, -1, 2304, 235, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 2317, 248, + 2319, -1, 251, 3641, 2323, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 2339, -1, -1, -1, -1, -1, 3664, -1, -1, -1, + -1, 2350, -1, 2352, 2353, 2354, 1154, -1, 1307, -1, + -1, -1, 8, -1, -1, 11, 3684, -1, -1, -1, + 2369, -1, -1, -1, -1, -1, -1, 1326, -1, -1, + -1, 2380, 28, 2028, -1, -1, 2385, -1, -1, -1, + 36, -1, -1, 2392, 323, -1, 42, 1346, -1, 2398, + -1, -1, -1, -1, -1, -1, -1, 8, -1, 1207, + 11, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 66, -1, 1371, -1, -1, -1, -1, 28, -1, -1, + 31, -1, -1, -1, -1, 36, 2435, -1, -1, 1237, + -1, 42, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 3770, -1, -1, -1, -1, -1, -1, 2458, + -1, -1, -1, -1, -1, 66, -1, -1, -1, -1, + -1, -1, -1, -1, 1423, -1, -1, -1, -1, 3017, + 3018, 3019, 3020, -1, 413, 414, 415, -1, 417, 418, + 419, 420, 421, 422, -1, -1, -1, -1, -1, 2498, + 2499, 2146, 2501, -1, -1, -1, -1, -1, -1, 1307, + 3828, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 166, -1, -1, -1, 170, -1, -1, -1, 1326, -1, + -1, 2530, 2531, 2532, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 191, 192, -1, 1346, -1, + 3868, -1, -1, -1, 2553, -1, 2555, -1, -1, -1, + -1, 207, -1, -1, -1, 166, -1, -1, -1, 170, + -1, -1, -1, 1371, -1, -1, -1, -1, -1, -1, + 2225, -1, -1, -1, -1, 2230, 232, 3905, -1, 235, + 191, 192, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 248, -1, -1, 251, 207, -1, -1, 2608, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 265, + -1, -1, -1, -1, -1, 1423, -1, 2272, -1, 2274, + 2275, 232, -1, 2632, 235, -1, -1, -1, -1, -1, + 2285, -1, -1, 2288, -1, 2290, -1, 248, -1, 1598, + 251, -1, -1, -1, -1, 2654, -1, -1, 2657, 3197, + -1, -1, -1, -1, 3982, -1, -1, -1, -1, -1, + -1, -1, 2317, -1, 2319, 2674, 2675, 323, 2323, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 2352, 2353, 2354, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 323, -1, 2369, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 2380, -1, -1, 4056, 2738, + 2385, -1, -1, -1, -1, -1, -1, 2392, -1, -1, + -1, -1, -1, 2752, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 2763, -1, -1, 413, 414, 415, + -1, 417, 418, 419, 420, 421, 422, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 2435, 2790, -1, -1, -1, -1, -1, -1, -1, -1, + 1598, -1, -1, -1, -1, -1, -1, -1, 4126, -1, + -1, -1, 413, 414, 415, -1, 417, 418, 419, 420, + 421, 422, -1, -1, -1, -1, 2825, -1, -1, 2828, + -1, -1, -1, 1631, -1, -1, 2835, -1, -1, -1, + -1, -1, 2841, -1, 2843, -1, -1, -1, -1, 2848, + 2849, -1, -1, 2852, 2853, 2854, 2855, 2856, 2857, 2858, + 2859, 2860, 2861, -1, -1, -1, 2865, 2866, -1, -1, + -1, -1, -1, -1, 2873, -1, -1, -1, -1, 2878, + -1, -1, -1, 2882, -1, 2884, -1, 2886, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 2896, -1, -1, + 2899, -1, 2901, -1, -1, -1, -1, -1, -1, -1, + 2909, 2910, 2911, 2912, -1, -1, -1, 2916, -1, -1, + 2919, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 2929, -1, 1881, -1, -1, -1, -1, 1886, 1887, -1, + 2939, -1, -1, -1, -1, -1, -1, -1, 2947, 1898, + 2949, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 2972, -1, -1, -1, -1, -1, 2978, + -1, -1, -1, -1, -1, 2984, 8, -1, -1, 11, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 2999, -1, -1, -1, -1, -1, 28, 3545, -1, 31, + -1, -1, -1, -1, 36, -1, -1, -1, -1, -1, + 42, 3559, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 8, + -1, -1, 11, -1, 66, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 28, + -1, -1, -1, -1, -1, -1, 3065, 36, -1, -1, + 3069, 3070, 3071, 42, -1, -1, -1, -1, -1, -1, + -1, 2030, -1, 1881, -1, -1, -1, -1, 1886, 1887, + -1, -1, -1, -1, 1063, -1, -1, 66, -1, -1, + 1898, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 3648, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 8, -1, -1, 11, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 166, 28, -1, -1, 170, -1, + -1, 1120, -1, 36, -1, 2104, -1, -1, -1, 42, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 191, + 192, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 2825, -1, -1, 66, -1, 207, -1, -1, -1, -1, + 2835, -1, -1, -1, -1, -1, 2841, 166, 2843, -1, + 3199, 170, -1, -1, -1, -1, -1, -1, -1, -1, + 232, -1, -1, 235, -1, -1, -1, -1, -1, -1, + 2865, 2866, 191, 192, -1, 3224, 248, -1, -1, 251, + -1, -1, 2030, -1, -1, -1, -1, -1, 207, 2188, + -1, 2886, -1, -1, -1, -1, -1, 3785, 3786, 3787, + -1, 2896, -1, -1, 2899, -1, 2901, -1, 3257, 3258, + 3259, -1, -1, 232, -1, 2910, 235, -1, -1, -1, + -1, 2916, -1, -1, 2919, -1, -1, -1, -1, 248, + -1, -1, 251, 166, -1, -1, -1, 170, -1, -1, + -1, -1, -1, -1, 2939, -1, -1, -1, -1, -1, + -1, 323, 2947, -1, 2949, -1, 2104, -1, 191, 192, + -1, -1, -1, -1, -1, -1, 3315, -1, -1, -1, + -1, -1, -1, -1, 207, -1, -1, 2972, -1, -1, + -1, -1, -1, 2978, -1, -1, -1, -1, -1, 2984, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 232, + -1, -1, 235, 3352, 323, -1, -1, -1, 3896, -1, + -1, -1, -1, 3362, 3363, 248, 3365, -1, 251, -1, + -1, 3370, 3371, -1, -1, -1, 3375, 3376, -1, -1, + 349, -1, 3381, 3382, -1, -1, 3385, -1, -1, -1, + 2188, 413, 414, 415, -1, 417, 418, 419, 420, 421, + 422, 3400, 834, -1, -1, 3404, -1, -1, -1, -1, + -1, -1, -1, -1, 3413, -1, -1, -1, -1, 3418, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 3430, -1, -1, -1, -1, 3974, -1, -1, -1, + 323, -1, -1, -1, 413, 414, 415, -1, 417, 418, + 419, 420, 421, 422, -1, -1, -1, -1, 3996, -1, + 3998, -1, 3461, -1, -1, -1, 18, -1, -1, -1, + -1, -1, 24, -1, -1, -1, -1, -1, -1, -1, + 3479, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 1459, -1, -1, -1, -1, -1, -1, 49, -1, 3498, + -1, -1, -1, -1, -1, -1, -1, -1, 3507, 2458, + -1, -1, 64, -1, -1, -1, -1, -1, -1, -1, + 3519, -1, -1, -1, -1, -1, -1, -1, -1, 961, + 413, 414, 415, -1, 417, 418, 419, 420, 421, 422, + -1, -1, -1, 95, -1, -1, -1, -1, 4086, 2498, + 2499, -1, 2501, -1, 2352, 2353, 2354, -1, -1, -1, + -1, 113, -1, -1, 3563, -1, -1, 1536, 120, -1, + -1, 123, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 3583, -1, -1, -1, -1, -1, + 4128, 1560, -1, -1, -1, -1, 1565, -1, -1, -1, + -1, -1, -1, -1, 2553, -1, 2555, -1, -1, -1, + -1, -1, -1, 3258, 3259, -1, 1585, 1586, -1, 1588, + 172, -1, 3621, 175, -1, -1, -1, -1, 8, -1, + -1, 11, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 4180, -1, -1, -1, -1, -1, 28, -1, + -1, 31, -1, -1, -1, -1, 36, -1, 1627, 2608, + 2458, -1, 42, -1, -1, -1, 218, -1, 220, -1, + 3315, -1, -1, -1, 3673, -1, -1, -1, 230, -1, + 232, -1, -1, 2632, 4222, -1, 66, -1, -1, -1, + 242, -1, -1, -1, 1663, -1, -1, -1, 250, -1, + 2498, 2499, -1, 2501, -1, 3704, 258, 259, 2657, 3708, + -1, -1, -1, -1, 3713, -1, -1, 3362, 3363, -1, + -1, -1, 1154, -1, -1, -1, 2675, -1, -1, -1, + 3375, 3730, 3731, -1, -1, 3734, 3381, 3382, 290, -1, + 3385, -1, 294, 295, -1, -1, 3745, -1, -1, -1, + -1, 3750, -1, -1, 3753, 2553, -1, 2555, -1, 3758, + 3759, -1, -1, -1, -1, -1, -1, 319, 3413, -1, + -1, -1, -1, 3418, -1, 1207, -1, -1, 330, 8, + -1, -1, 11, -1, 3783, 3430, 166, -1, -1, 2738, + 170, -1, -1, -1, -1, -1, 1765, -1, -1, 28, + -1, -1, -1, 2752, -1, 1237, 1775, 36, -1, 1778, + 2608, 191, 192, 42, 2763, 3814, 3461, -1, -1, 3818, + -1, -1, -1, -1, -1, 377, -1, 207, -1, -1, + -1, -1, -1, -1, 2632, -1, -1, 66, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 232, -1, -1, 235, 3855, -1, -1, 2657, + -1, -1, -1, -1, -1, -1, -1, -1, 248, -1, + -1, 251, -1, -1, -1, 1307, -1, 2675, -1, 2828, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 1326, -1, -1, -1, 3897, 2848, + 3899, 834, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 1346, -1, -1, -1, -1, -1, + 3919, 3920, -1, 3922, 2873, 3924, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 166, -1, 1371, + 2738, 170, 3941, 323, -1, -1, 3945, -1, -1, -1, + -1, 3950, -1, -1, 2752, -1, -1, -1, -1, -1, + 2909, -1, 191, 192, -1, 2763, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3621, -1, 207, -1, + -1, -1, -1, -1, -1, 3984, -1, -1, 3987, -1, + -1, 1423, 3991, 3992, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 232, -1, -1, 235, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 248, + -1, -1, -1, -1, -1, -1, 4025, -1, 961, -1, + 2828, -1, -1, 413, 414, 415, -1, 417, 418, 419, + 420, 421, 422, -1, -1, -1, -1, -1, -1, -1, + 2848, -1, -1, 4052, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 2873, -1, -1, -1, -1, + -1, 4080, -1, -1, -1, -1, -1, -1, -1, 3734, + -1, -1, -1, -1, 323, -1, -1, -1, 4097, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 2909, -1, -1, 3759, 834, -1, -1, -1, -1, + -1, 3070, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 4132, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 4142, -1, -1, -1, -1, -1, -1, + -1, 2949, -1, -1, -1, -1, -1, -1, -1, -1, + 4159, 4160, -1, -1, -1, -1, 1598, -1, -1, -1, + -1, -1, -1, 4172, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 413, 414, 415, -1, 417, 418, + 419, 420, 421, 422, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 4207, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 4217, -1, + -1, 1154, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 4233, -1, -1, -1, -1, 834, + -1, -1, 961, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 2228, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 3070, -1, 1207, 3224, 4275, 3922, -1, -1, + -1, 4280, 2251, -1, 2253, 4284, 2255, 2256, 2257, 4288, + -1, 2260, -1, -1, -1, 2264, 3941, -1, -1, -1, + -1, -1, 2271, -1, 1237, -1, -1, 2276, 3257, -1, + -1, -1, -1, 2282, -1, -1, -1, -1, 2287, -1, + -1, -1, -1, -1, -1, -1, -1, 2296, -1, -1, + -1, 2300, 2301, -1, 2303, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 2315, -1, -1, -1, + -1, -1, -1, 2322, -1, 2324, 2325, 2326, 2327, 2328, + 2329, 2330, 2331, 2332, 2333, -1, 961, -1, -1, -1, + -1, -1, -1, -1, 1307, -1, -1, -1, -1, -1, + 4025, -1, -1, -1, -1, -1, -1, -1, -1, 2358, + -1, -1, -1, 1326, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 1346, -1, -1, 3365, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3224, 3376, -1, -1, + -1, -1, -1, -1, -1, 1154, -1, -1, 1371, -1, + -1, -1, -1, -1, -1, -1, 834, -1, -1, 1881, + -1, -1, 4097, -1, 1886, 1887, -1, -1, -1, 3257, + -1, -1, -1, -1, -1, -1, 1898, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 2450, -1, -1, -1, -1, -1, -1, 1207, -1, + 1423, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 4159, 4160, -1, -1, 1237, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 3479, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 3507, 1154, + -1, -1, 4207, -1, -1, -1, -1, 3365, -1, -1, + 3519, -1, 4217, 961, -1, -1, -1, -1, 3376, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 1307, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 2030, -1, + -1, -1, -1, -1, -1, -1, -1, 1326, -1, -1, + -1, -1, 1207, -1, 3563, 3413, -1, -1, -1, -1, + 3418, -1, -1, -1, -1, -1, -1, 1346, -1, -1, + 4275, -1, 3430, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 1237, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 1371, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 1598, -1, -1, -1, -1, + -1, -1, 2104, -1, -1, -1, -1, -1, -1, -1, + -1, 3479, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 2660, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 1423, -1, -1, -1, -1, 3507, + -1, -1, 1307, -1, -1, -1, -1, -1, -1, -1, + -1, 3519, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 1326, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 1346, -1, -1, -1, -1, 2188, -1, -1, 3708, + -1, -1, -1, -1, -1, 3563, 1154, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 1371, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 2782, -1, -1, -1, -1, -1, 1207, + -1, -1, -1, -1, -1, -1, -1, -1, 1423, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 1237, + -1, -1, -1, -1, -1, 2824, -1, -1, -1, -1, + -1, 2830, -1, -1, -1, 3814, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 3673, -1, 2846, 2847, 1598, + 2849, -1, -1, 2852, 2853, 2854, 2855, 2856, 2857, 2858, + 2859, 2860, 2861, 2862, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 3708, -1, -1, -1, -1, -1, -1, -1, 2887, 1307, + -1, 2890, -1, 2892, -1, -1, -1, -1, 2897, 2898, + -1, -1, -1, -1, -1, -1, -1, -1, 1326, -1, + -1, -1, 2911, 2912, 2913, 834, 2915, 21, 1881, 2918, + 3899, -1, -1, 1886, 1887, -1, -1, -1, 1346, 33, + -1, -1, -1, -1, -1, 1898, -1, -1, -1, -1, + -1, 3920, -1, -1, -1, -1, -1, -1, -1, -1, + 54, -1, -1, 1371, -1, -1, 2955, -1, -1, -1, + -1, -1, -1, 67, -1, -1, 2965, -1, -1, -1, + -1, 3950, 76, 1598, -1, -1, 80, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3814, -1, -1, -1, + -1, -1, -1, 97, -1, -1, 2458, 2996, -1, 103, + -1, -1, -1, -1, -1, 1423, -1, -1, 3987, -1, + -1, -1, 3991, 3992, 118, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 136, -1, -1, -1, 2498, 2499, -1, 2501, + -1, -1, 961, 147, -1, -1, -1, -1, -1, -1, + 154, -1, -1, -1, 158, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 2030, -1, 173, + -1, 3899, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 2553, 3920, 2555, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 211, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 3950, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 1881, -1, -1, -1, -1, 1886, 1887, -1, + -1, 2104, -1, -1, 248, -1, 2608, 251, -1, 1898, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 3987, + -1, -1, -1, 3991, 3992, -1, -1, -1, -1, -1, + 2632, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 1598, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 2657, -1, 301, -1, -1, + 3199, -1, -1, 307, -1, -1, -1, -1, -1, 313, + -1, -1, 316, 2675, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 4052, 2188, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 1154, -1, -1, 342, -1, + 344, 345, -1, 347, 348, -1, -1, -1, -1, -1, + -1, -1, 356, -1, -1, -1, 1881, 361, -1, -1, + -1, 1886, 1887, 367, -1, -1, 370, -1, -1, 373, + -1, -1, -1, 1898, -1, -1, 2738, -1, -1, -1, + -1, 2030, 386, -1, -1, -1, -1, -1, 1207, -1, + 2752, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 2763, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 3316, 1237, -1, + -1, 3320, 3321, 3322, -1, -1, 3325, -1, -1, -1, + -1, 3330, 3331, 3332, 3333, 3334, 3335, 3336, 3337, 3338, + 3339, 3340, 3341, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 2104, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 2828, -1, -1, -1, + 3369, 3370, 3371, 3372, -1, 3374, -1, -1, -1, 3378, + 3379, 3380, -1, -1, 3383, -1, 2848, 3386, 1307, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 2030, -1, 1326, -1, -1, + -1, 2873, -1, -1, -1, -1, 3415, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 1346, 3427, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 2188, + -1, -1, 3441, -1, -1, -1, -1, 2909, -1, -1, + -1, -1, 1371, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 1881, -1, -1, -1, -1, 1886, 1887, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 2104, + 1898, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 2458, -1, -1, -1, -1, + -1, -1, -1, -1, 1423, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 2498, 2499, -1, 2501, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 2188, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 2553, -1, 2555, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 3070, -1, + -1, -1, 2030, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 3624, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 2608, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 2632, + -1, 3670, 3671, -1, -1, -1, -1, -1, -1, 1598, + -1, -1, -1, -1, -1, -1, 2104, -1, -1, -1, + -1, -1, -1, -1, 2657, -1, -1, -1, -1, -1, + -1, 3700, -1, -1, -1, 3704, -1, -1, -1, 2458, + -1, -1, 2675, -1, -1, -1, -1, -1, -1, 3718, + -1, 3720, -1, -1, -1, -1, 3725, 3726, 3727, -1, + -1, 3730, 3731, 3732, 3733, -1, 3735, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 2498, + 2499, -1, 2501, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 3224, -1, -1, -1, -1, -1, -1, -1, + 2188, -1, -1, -1, -1, 2738, -1, -1, -1, -1, + -1, -1, 3781, -1, -1, -1, -1, -1, -1, 2752, + -1, -1, -1, -1, -1, 3257, -1, -1, -1, -1, + 2763, -1, -1, -1, 2553, -1, 2555, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 2458, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 2608, + -1, -1, 3861, -1, -1, 2828, -1, -1, -1, -1, + -1, -1, -1, 2498, 2499, -1, 2501, -1, -1, -1, + -1, -1, -1, 2632, -1, 2848, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 3365, -1, -1, -1, -1, 2657, -1, + 2873, -1, -1, -1, 3376, -1, -1, -1, -1, 3918, + 3919, -1, -1, -1, -1, -1, 2675, -1, 2553, -1, + 2555, -1, -1, -1, -1, 3934, 3935, 3936, -1, -1, + -1, -1, -1, -1, -1, -1, 2909, -1, -1, -1, + -1, -1, -1, -1, 3953, -1, -1, -1, -1, -1, + -1, -1, 1881, -1, -1, -1, -1, 1886, 1887, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 1898, + -1, -1, -1, 2608, -1, -1, -1, -1, -1, 2738, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 2752, -1, -1, -1, 2632, -1, -1, + -1, -1, -1, -1, 2763, -1, -1, 3479, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 2657, -1, -1, -1, -1, -1, -1, -1, + 2458, -1, -1, -1, -1, 3507, -1, -1, -1, -1, + 2675, -1, -1, -1, -1, -1, -1, 3519, -1, -1, + -1, 4060, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 4070, -1, -1, -1, -1, -1, -1, -1, 2828, + 2498, 2499, -1, 2501, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 2848, + -1, 3563, -1, -1, -1, -1, -1, 3070, -1, -1, + -1, 2030, -1, 2738, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 2873, -1, -1, 2752, -1, -1, + -1, -1, 4131, -1, -1, 2553, -1, 2555, 2763, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 2909, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 4171, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 2104, -1, -1, -1, -1, + 2608, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 2828, -1, -1, -1, -1, -1, -1, + -1, 4210, -1, -1, 2632, -1, -1, -1, -1, -1, + -1, -1, -1, 2848, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 2657, + -1, -1, -1, -1, -1, -1, 3708, -1, 2873, -1, + -1, -1, -1, -1, -1, 4254, -1, 2675, -1, -1, + -1, 3224, -1, -1, -1, -1, -1, -1, -1, 2188, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 2909, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 3257, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 2738, 3070, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 2752, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 2763, -1, -1, -1, -1, + -1, -1, 3814, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 3365, -1, -1, -1, -1, -1, -1, -1, + 2828, -1, -1, 3376, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 2848, -1, -1, -1, -1, -1, -1, 3899, -1, -1, + -1, -1, -1, -1, -1, 3070, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 2873, -1, -1, 3920, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 3224, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 3950, -1, + -1, 2909, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 3257, -1, + -1, -1, -1, -1, -1, -1, 3479, -1, -1, -1, + -1, -1, -1, -1, -1, 3987, -1, -1, -1, 3991, + 3992, -1, -1, -1, -1, -1, -1, -1, -1, 2458, + -1, -1, -1, -1, 3507, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3519, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 2498, + 2499, -1, 2501, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 3224, + 3563, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3365, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 3376, -1, -1, + -1, -1, 3257, -1, 2553, -1, 2555, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 3070, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 2608, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 2632, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 3479, -1, -1, -1, -1, -1, -1, -1, 2657, -1, + 3365, -1, -1, -1, -1, 3708, -1, -1, -1, -1, + -1, 3376, -1, -1, -1, -1, 2675, -1, 3507, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 3519, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3224, -1, -1, -1, + -1, -1, -1, -1, 3563, -1, -1, -1, -1, 2738, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 2752, -1, -1, -1, -1, -1, 3257, + -1, -1, -1, -1, 2763, -1, -1, -1, -1, -1, + -1, 3814, -1, -1, 3479, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 3507, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 3519, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 2828, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 2848, + -1, -1, -1, -1, -1, -1, 3899, -1, 3563, -1, + -1, -1, -1, -1, -1, -1, -1, 3365, -1, -1, + -1, -1, -1, -1, 2873, -1, -1, 3920, 3376, 3708, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 3950, -1, -1, + 2909, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 3987, -1, -1, -1, 3991, 3992, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 3479, -1, -1, -1, 3814, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 3708, -1, -1, -1, -1, -1, 3507, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 3519, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 3563, -1, -1, -1, -1, + 3899, 3070, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 3920, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 3814, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 3950, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 3987, -1, + -1, -1, 3991, 3992, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 3899, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 3708, -1, -1, -1, -1, 3920, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 3224, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 3950, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 3257, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 3987, -1, -1, -1, 3991, 3992, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3814, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3365, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 3376, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 3899, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 3920, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 3950, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 3479, -1, -1, -1, -1, -1, -1, -1, -1, 3987, + -1, -1, -1, 3991, 3992, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 3507, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 3519, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 3563, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 3708, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 3814, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 3899, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 3920, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 3950, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 3, 4, 5, 6, 7, 8, + 9, 10, -1, -1, -1, 14, 15, 16, 17, 18, + 19, 20, 21, 22, 23, 24, 25, -1, 3987, -1, + -1, 30, 3991, 3992, 33, 34, -1, 36, 37, 38, + 39, 40, 41, 42, 43, 44, 45, 46, -1, 48, + 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, + 59, -1, 61, 62, 63, 64, 65, -1, 67, -1, + 69, 70, 71, 72, 73, 74, 75, -1, 77, 78, + 79, 80, 81, 82, -1, 84, 85, 86, 87, 88, + 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, + 99, 100, 101, 102, -1, 104, -1, 106, 107, 108, + 109, 110, -1, 112, 113, 114, 115, -1, 117, 118, + 119, 120, 121, -1, 123, 124, 125, -1, 127, 128, + -1, 130, 131, 132, 133, 134, 135, 136, 137, 138, + 139, 140, -1, 142, 143, 144, -1, 146, -1, 148, + 149, -1, 151, 152, 153, 154, -1, 156, 157, -1, + 159, -1, 161, 162, 163, 164, 165, 166, 167, 168, + 169, -1, 171, 172, 173, 174, 175, 176, -1, 178, + 179, 180, 181, 182, 183, 184, 185, 186, -1, 188, + -1, 190, 191, 192, 193, 194, 195, 196, 197, 198, + 199, 200, 201, -1, 203, 204, 205, 206, 207, -1, + 209, 210, 211, 212, 213, 214, 215, 216, 217, 218, + 219, 220, 221, 222, 223, 224, 225, 226, 227, 228, + 229, 230, 231, 232, 233, 234, 235, 236, 237, 238, + 239, 240, 241, 242, 243, -1, 245, -1, -1, 248, + 249, 250, -1, -1, 253, 254, 255, 256, 257, 258, + 259, 260, 261, 262, 263, 264, -1, 266, 267, 268, + 269, 270, 271, 272, -1, 274, 275, 276, 277, 278, + 279, 280, 281, 282, 283, 284, 285, -1, 287, 288, + 289, 290, 291, 292, 293, 294, 295, 296, -1, 298, + 299, 300, 301, 302, 303, 304, 305, 306, 307, 308, + 309, 310, 311, -1, 313, 314, 315, 316, 317, 318, + 319, 320, 321, 322, 323, 324, 325, 326, -1, 328, + 329, 330, 331, 332, 333, 334, 335, 336, 337, 338, + -1, 340, 341, -1, 343, 344, 345, 346, 347, 348, + -1, 350, 351, -1, -1, 354, 355, 356, 357, 358, + 359, 360, 361, 362, 363, 364, 365, -1, 367, 368, + 369, 370, 371, 372, 373, -1, 375, 376, 377, 378, + 379, 380, 381, 382, 383, 384, 385, 386, 387, -1, + -1, 390, -1, -1, 393, 394, 395, 396, 397, 398, + 399, 400, 401, 402, 403, 404, 405, 406, 407, 408, + 409, -1, -1, -1, -1, -1, -1, -1, 417, 418, + 419, -1, -1, -1, -1, -1, -1, 426, 427, 3, + 4, 5, 6, 7, 8, 9, 10, -1, -1, -1, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, 30, -1, -1, 33, + 34, -1, 36, 37, 38, 39, 40, 41, 42, 43, + 44, 45, 46, -1, 48, 49, 50, 51, 52, 53, + 54, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, 65, -1, 67, -1, 69, 70, 71, 72, 73, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + 134, 135, 136, 137, 138, 139, 140, -1, 142, 143, + 144, -1, 146, -1, 148, 149, -1, 151, 152, 153, + 154, -1, 156, 157, -1, 159, -1, 161, 162, 163, + 164, 165, 166, 167, 168, 169, -1, 171, 172, 173, + 174, 175, 176, -1, 178, 179, 180, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, 191, 192, 193, + 194, 195, 196, 197, 198, 199, 200, 201, -1, 203, + 204, 205, 206, 207, -1, 209, 210, 211, 212, 213, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, 227, 228, 229, 230, 231, 232, 233, + 234, 235, 236, 237, 238, 239, 240, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, 253, + 254, 255, 256, 257, 258, 259, 260, 261, 262, 263, + 264, -1, 266, 267, 268, 269, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, 300, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, -1, 313, + 314, 315, 316, 317, 318, 319, 320, 321, 322, 323, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, 338, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, 355, 356, 357, 358, 359, 360, 361, 362, 363, + 364, 365, -1, 367, 368, 369, 370, 371, 372, 373, + -1, 375, 376, 377, 378, 379, 380, 381, -1, 383, + 384, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 407, 408, 409, -1, -1, -1, -1, + -1, -1, -1, 417, 418, 3, -1, -1, -1, -1, + -1, -1, 426, 427, -1, -1, 14, 15, 16, 17, + 18, 19, 20, 21, -1, 23, 24, 25, -1, -1, + -1, -1, -1, 31, -1, 33, 34, -1, 36, 37, + -1, 39, 40, 41, 42, 43, -1, 45, 46, -1, + 48, 49, 50, 51, 52, -1, -1, 55, 56, 57, + 58, 59, -1, 61, 62, 63, 64, 65, -1, -1, + -1, 69, 70, 71, 72, -1, 74, 75, -1, 77, + 78, 79, 80, 81, 82, -1, 84, 85, 86, -1, + -1, -1, -1, -1, -1, -1, 94, 95, 96, 97, + 98, 99, 100, 101, 102, -1, 104, -1, 106, 107, + 108, 109, 110, -1, 112, 113, 114, -1, -1, 117, + 118, 119, 120, 121, -1, 123, 124, 125, -1, 127, + 128, -1, 130, 131, 132, 133, 134, 135, 136, 137, + 138, -1, 140, -1, 142, 143, 144, -1, 146, -1, + 148, -1, -1, 151, 152, 153, 154, -1, 156, 157, + -1, 159, -1, 161, 162, 163, 164, 165, -1, 167, + 168, 169, -1, 171, 172, 173, 174, 175, 176, -1, + 178, 179, 180, 181, 182, 183, 184, 185, 186, -1, + 188, -1, 190, -1, -1, 193, 194, 195, 196, 197, + 198, 199, 200, 201, -1, 203, 204, 205, 206, -1, + -1, 209, 210, 211, -1, -1, 214, 215, 216, 217, + 218, 219, 220, 221, 222, 223, 224, 225, 226, 227, + 228, 229, 230, 231, -1, 233, 234, -1, 236, -1, + 238, 239, 240, 241, 242, 243, -1, 245, -1, -1, + 248, 249, 250, -1, -1, 253, -1, -1, -1, 257, + 258, 259, 260, 261, 262, 263, 264, -1, 266, 267, + 268, 269, 270, 271, 272, -1, 274, 275, 276, 277, + 278, 279, 280, 281, 282, 283, 284, 285, -1, 287, + 288, 289, 290, 291, 292, 293, 294, 295, 296, -1, + 298, 299, 300, 301, 302, 303, 304, 305, 306, 307, + 308, 309, 310, 311, -1, 313, 314, 315, 316, 317, + -1, 319, 320, 321, 322, -1, 324, 325, 326, -1, + 328, 329, 330, 331, 332, 333, 334, 335, 336, 337, + 338, -1, 340, 341, -1, 343, 344, 345, 346, 347, + 348, -1, 350, 351, -1, -1, 354, 355, 356, 357, + -1, 359, 360, 361, 362, 363, 364, 365, -1, -1, + 368, 369, 370, 371, 372, -1, -1, 375, 376, 377, + 378, 379, 380, 381, -1, 383, -1, 385, 386, 387, + -1, -1, 390, -1, -1, 393, 394, 395, 396, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, + 408, 409, -1, -1, -1, -1, -1, -1, -1, 3, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 427, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, -1, -1, -1, 33, + 34, -1, 36, 37, 38, 39, 40, 41, -1, 43, + 44, 45, 46, -1, 48, 49, 50, 51, 52, -1, + -1, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, -1, -1, 67, -1, 69, 70, 71, 72, 73, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + 84, 85, 86, -1, -1, -1, 90, -1, -1, -1, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + -1, 135, 136, 137, -1, -1, 140, -1, 142, 143, + 144, -1, 146, -1, 148, 149, -1, 151, 152, 153, + 154, -1, 156, -1, -1, 159, -1, 161, 162, 163, + 164, 165, 166, 167, 168, 169, 170, 171, 172, 173, + 174, 175, 176, -1, 178, 179, 180, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, 191, 192, 193, + 194, 195, 196, 197, 198, 199, 200, 201, -1, 203, + -1, 205, 206, 207, -1, 209, 210, 211, -1, -1, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, 227, 228, 229, 230, -1, -1, 233, + 234, 235, 236, -1, -1, 239, 240, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, 253, + 254, 255, 256, -1, 258, 259, 260, 261, 262, 263, + 264, -1, 266, -1, 268, -1, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, 300, 301, 302, -1, + 304, 305, 306, 307, 308, 309, 310, 311, -1, 313, + 314, 315, 316, 317, -1, 319, 320, 321, 322, 323, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, -1, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, -1, 356, -1, -1, 359, 360, 361, 362, 363, + 364, 365, -1, -1, 368, 369, 370, 371, 372, -1, + -1, 375, 376, 377, 378, 379, -1, 381, 382, 383, + 384, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, -1, 3, -1, -1, -1, -1, + -1, -1, -1, 407, 408, 409, 14, 15, 16, 17, + 18, 19, 20, 21, -1, 23, 24, 25, -1, -1, + -1, -1, -1, 427, -1, 33, 34, -1, 36, 37, + -1, 39, 40, 41, 42, 43, -1, 45, 46, -1, + 48, 49, 50, 51, 52, -1, -1, 55, 56, 57, + 58, 59, -1, 61, 62, 63, 64, 65, -1, -1, + -1, 69, 70, 71, 72, -1, 74, 75, -1, 77, + 78, 79, 80, 81, 82, -1, -1, 85, 86, -1, + -1, -1, -1, -1, -1, -1, 94, 95, 96, 97, + 98, 99, 100, 101, 102, -1, 104, -1, 106, 107, + 108, 109, 110, -1, 112, 113, 114, -1, -1, 117, + 118, 119, 120, 121, -1, 123, 124, 125, -1, 127, + 128, -1, 130, 131, 132, 133, 134, 135, 136, 137, + 138, -1, 140, -1, 142, 143, 144, -1, 146, -1, + 148, -1, -1, -1, 152, 153, 154, -1, 156, 157, + -1, 159, -1, 161, 162, 163, 164, 165, -1, 167, + 168, 169, -1, 171, 172, 173, 174, 175, 176, -1, + 178, -1, 180, 181, 182, 183, 184, 185, 186, -1, + 188, -1, 190, -1, -1, 193, -1, 195, 196, 197, + 198, 199, 200, 201, -1, 203, 204, -1, 206, -1, + -1, 209, 210, 211, -1, -1, 214, 215, 216, 217, + 218, 219, 220, 221, 222, 223, 224, 225, 226, -1, + 228, 229, 230, 231, -1, 233, 234, -1, 236, -1, + 238, 239, 240, 241, 242, 243, -1, 245, -1, -1, + 248, 249, 250, -1, -1, 253, -1, -1, -1, 257, + 258, 259, 260, 261, 262, 263, 264, -1, 266, 267, + 268, 269, 270, 271, 272, -1, 274, 275, 276, 277, + 278, 279, 280, 281, 282, 283, 284, 285, -1, 287, + 288, 289, 290, 291, 292, 293, 294, 295, 296, -1, + 298, 299, -1, 301, 302, 303, 304, 305, 306, 307, + 308, 309, 310, 311, -1, 313, 314, 315, 316, 317, + -1, 319, 320, 321, 322, -1, 324, 325, 326, -1, + 328, 329, 330, 331, 332, 333, 334, 335, 336, 337, + 338, -1, 340, 341, -1, 343, 344, 345, 346, 347, + 348, -1, 350, 351, -1, -1, 354, 355, 356, 357, + -1, 359, 360, 361, 362, 363, 364, 365, -1, -1, + 368, 369, 370, 371, 372, -1, -1, 375, 376, 377, + 378, 379, 380, 381, -1, 383, -1, 385, 386, 387, + -1, -1, 390, -1, -1, 393, 394, 395, 396, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, + 408, 409, -1, -1, -1, -1, -1, -1, -1, 3, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 427, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, -1, -1, -1, 33, + 34, -1, 36, 37, 38, 39, 40, 41, -1, 43, + 44, 45, 46, -1, 48, 49, 50, 51, 52, -1, + -1, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, -1, -1, 67, -1, 69, 70, 71, 72, 73, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + 84, 85, 86, -1, -1, -1, 90, -1, -1, -1, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + -1, 135, 136, 137, -1, -1, 140, -1, 142, 143, + 144, -1, 146, -1, 148, 149, -1, 151, 152, 153, + 154, -1, 156, -1, -1, 159, -1, 161, 162, 163, + 164, 165, 166, 167, 168, 169, 170, 171, 172, 173, + 174, 175, 176, -1, 178, 179, 180, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, 191, 192, 193, + 194, 195, 196, 197, 198, 199, 200, 201, -1, 203, + -1, 205, 206, 207, -1, 209, 210, 211, -1, -1, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, 227, 228, 229, 230, -1, -1, 233, + 234, 235, 236, -1, -1, 239, 240, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, 253, + 254, 255, 256, -1, 258, 259, 260, 261, 262, 263, + 264, -1, 266, -1, 268, -1, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, 300, 301, 302, -1, + 304, 305, 306, 307, 308, 309, 310, 311, -1, 313, + 314, 315, 316, 317, -1, 319, 320, 321, 322, 323, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, -1, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, -1, 356, -1, -1, 359, 360, 361, 362, 363, + 364, 365, -1, -1, 368, 369, 370, 371, 372, -1, + -1, 375, 376, 377, 378, 379, -1, 381, 382, 383, + 384, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, -1, 3, 4, 5, 6, 7, + 8, 9, 10, 407, 408, 409, 14, 15, 16, 17, + 18, 19, 20, 21, -1, 23, 24, 25, -1, -1, + -1, -1, 30, 427, -1, 33, 34, -1, 36, 37, + 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, + 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, + 58, 59, -1, 61, 62, 63, 64, 65, -1, 67, + -1, 69, 70, 71, 72, 73, 74, 75, -1, 77, + 78, 79, 80, 81, 82, -1, 84, 85, 86, 87, + 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, + 98, 99, 100, 101, 102, -1, 104, -1, 106, 107, + 108, 109, 110, -1, 112, 113, 114, -1, -1, 117, + 118, 119, 120, 121, -1, 123, 124, 125, -1, 127, + 128, -1, 130, 131, 132, 133, 134, 135, 136, 137, + 138, 139, 140, -1, 142, 143, 144, -1, 146, -1, + 148, 149, 150, 151, 152, 153, 154, -1, 156, 157, + -1, 159, -1, 161, 162, 163, 164, 165, 166, 167, + 168, 169, -1, 171, 172, 173, 174, 175, 176, -1, + 178, 179, 180, 181, 182, 183, 184, 185, 186, -1, + 188, -1, 190, 191, 192, 193, 194, 195, 196, 197, + 198, 199, 200, 201, 202, 203, 204, 205, 206, 207, + -1, 209, 210, 211, 212, 213, 214, 215, 216, 217, + 218, 219, 220, 221, 222, 223, 224, 225, 226, 227, + 228, 229, 230, 231, 232, 233, 234, 235, 236, 237, + 238, 239, 240, 241, 242, 243, -1, 245, -1, -1, + 248, 249, 250, -1, -1, 253, 254, 255, 256, 257, + 258, 259, 260, 261, 262, 263, 264, -1, 266, 267, + 268, 269, 270, 271, 272, -1, 274, 275, 276, 277, + 278, 279, 280, 281, 282, 283, 284, 285, -1, 287, + 288, 289, 290, 291, 292, 293, 294, 295, 296, -1, + 298, 299, 300, 301, 302, 303, 304, 305, 306, 307, + 308, 309, 310, 311, -1, 313, 314, 315, 316, 317, + 318, 319, 320, 321, 322, 323, 324, 325, 326, -1, + 328, 329, 330, 331, 332, 333, 334, 335, 336, 337, + 338, -1, 340, 341, -1, 343, 344, 345, 346, 347, + 348, -1, 350, 351, -1, 353, 354, 355, 356, 357, + 358, 359, 360, 361, 362, 363, 364, 365, -1, 367, + 368, 369, 370, 371, 372, 373, -1, 375, 376, 377, + 378, 379, 380, 381, -1, 383, 384, 385, 386, 387, + -1, -1, 390, -1, -1, 393, 394, 395, 396, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, + 408, 409, -1, -1, -1, -1, -1, -1, -1, 417, + 418, -1, -1, -1, -1, -1, -1, -1, 426, 3, + 4, 5, 6, 7, 8, 9, 10, -1, -1, -1, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, 30, -1, -1, 33, + 34, -1, 36, 37, 38, 39, 40, 41, 42, 43, + 44, 45, 46, -1, 48, 49, 50, 51, 52, 53, + 54, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, 65, -1, 67, -1, 69, 70, 71, 72, 73, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + 134, 135, 136, 137, 138, 139, 140, -1, 142, 143, + 144, -1, 146, -1, 148, 149, -1, 151, 152, 153, + 154, -1, 156, 157, -1, 159, -1, 161, 162, 163, + 164, 165, 166, 167, 168, 169, -1, 171, 172, 173, + 174, 175, 176, -1, 178, 179, 180, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, 191, 192, 193, + 194, 195, 196, 197, 198, 199, 200, 201, -1, 203, + 204, 205, 206, 207, -1, 209, 210, 211, 212, 213, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, 227, 228, 229, 230, 231, 232, 233, + 234, 235, 236, 237, 238, 239, 240, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, 253, + 254, 255, 256, 257, 258, 259, 260, 261, 262, 263, + 264, -1, 266, 267, 268, 269, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, 300, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, 312, 313, + 314, 315, 316, 317, 318, 319, 320, 321, 322, 323, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, 338, -1, 340, 341, 342, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, 355, 356, 357, 358, 359, 360, 361, 362, 363, + 364, 365, -1, 367, 368, 369, 370, 371, 372, 373, + -1, 375, 376, 377, 378, 379, 380, 381, -1, 383, + 384, 385, 386, 387, -1, -1, 390, -1, 392, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 407, 408, 409, -1, -1, -1, -1, + -1, -1, -1, 417, 418, -1, -1, -1, -1, -1, + -1, -1, 426, 3, 4, 5, 6, 7, 8, 9, + 10, -1, -1, -1, 14, 15, 16, 17, 18, 19, + 20, 21, -1, 23, 24, 25, -1, -1, -1, -1, + 30, -1, -1, 33, 34, -1, 36, 37, 38, 39, + 40, 41, 42, 43, 44, 45, 46, -1, 48, 49, + 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, + -1, 61, 62, 63, 64, 65, -1, 67, -1, 69, + 70, 71, 72, 73, 74, 75, -1, 77, 78, 79, + 80, 81, 82, -1, 84, 85, 86, 87, 88, 89, + 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, + 100, 101, 102, -1, 104, -1, 106, 107, 108, 109, + 110, -1, 112, 113, 114, -1, -1, 117, 118, 119, + 120, 121, -1, 123, 124, 125, -1, 127, 128, -1, + 130, 131, 132, 133, 134, 135, 136, 137, 138, 139, + 140, -1, 142, 143, 144, -1, 146, -1, 148, 149, + -1, 151, 152, 153, 154, -1, 156, 157, -1, 159, + -1, 161, 162, 163, 164, 165, 166, 167, 168, 169, + -1, 171, 172, 173, 174, 175, 176, -1, 178, 179, + 180, 181, 182, 183, 184, 185, 186, -1, 188, -1, + 190, 191, 192, 193, 194, 195, 196, 197, 198, 199, + 200, 201, -1, 203, 204, 205, 206, 207, -1, 209, + 210, 211, 212, 213, 214, 215, 216, 217, 218, 219, + 220, 221, 222, 223, 224, 225, 226, 227, 228, 229, + 230, 231, 232, 233, 234, 235, 236, 237, 238, 239, + 240, 241, 242, 243, -1, 245, -1, -1, 248, 249, + 250, -1, -1, 253, 254, 255, 256, 257, 258, 259, + 260, 261, 262, 263, 264, -1, 266, 267, 268, 269, + 270, 271, 272, -1, 274, 275, 276, 277, 278, 279, + 280, 281, 282, 283, 284, 285, -1, 287, 288, 289, + 290, 291, 292, 293, 294, 295, 296, -1, 298, 299, + 300, 301, 302, 303, 304, 305, 306, 307, 308, 309, + 310, 311, -1, 313, 314, 315, 316, 317, 318, 319, + 320, 321, 322, 323, 324, 325, 326, -1, 328, 329, + 330, 331, 332, 333, 334, 335, 336, 337, 338, -1, + 340, 341, -1, 343, 344, 345, 346, 347, 348, -1, + 350, 351, -1, -1, 354, 355, 356, 357, 358, 359, + 360, 361, 362, 363, 364, 365, -1, 367, 368, 369, + 370, 371, 372, 373, -1, 375, 376, 377, 378, 379, + 380, 381, -1, 383, 384, 385, 386, 387, -1, -1, + 390, -1, -1, 393, 394, 395, 396, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 407, 408, 409, + -1, -1, -1, -1, -1, -1, -1, 417, 418, -1, + -1, -1, -1, -1, 424, 425, 426, 3, 4, 5, + 6, 7, 8, 9, 10, -1, -1, -1, 14, 15, + 16, 17, 18, 19, 20, 21, -1, 23, 24, 25, + -1, -1, -1, -1, 30, -1, -1, 33, 34, -1, + 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, + 46, -1, 48, 49, 50, 51, 52, 53, 54, 55, + 56, 57, 58, 59, -1, 61, 62, 63, 64, 65, + -1, 67, -1, 69, 70, 71, 72, 73, 74, 75, + -1, 77, 78, 79, 80, 81, 82, -1, 84, 85, + 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, + 96, 97, 98, 99, 100, 101, 102, -1, 104, -1, + 106, 107, 108, 109, 110, -1, 112, 113, 114, -1, + -1, 117, 118, 119, 120, 121, -1, 123, 124, 125, + -1, 127, 128, -1, 130, 131, 132, 133, 134, 135, + 136, 137, 138, 139, 140, -1, 142, 143, 144, -1, + 146, -1, 148, 149, -1, 151, 152, 153, 154, -1, + 156, 157, -1, 159, -1, 161, 162, 163, 164, 165, + 166, 167, 168, 169, -1, 171, 172, 173, 174, 175, + 176, -1, 178, 179, 180, 181, 182, 183, 184, 185, + 186, -1, 188, -1, 190, 191, 192, 193, 194, 195, + 196, 197, 198, 199, 200, 201, -1, 203, 204, 205, + 206, 207, -1, 209, 210, 211, 212, 213, 214, 215, + 216, 217, 218, 219, 220, 221, 222, 223, 224, 225, + 226, 227, 228, 229, 230, 231, 232, 233, 234, 235, + 236, 237, 238, 239, 240, 241, 242, 243, -1, 245, + -1, -1, 248, 249, 250, -1, -1, 253, 254, 255, + 256, 257, 258, 259, 260, 261, 262, 263, 264, -1, + 266, 267, 268, 269, 270, 271, 272, -1, 274, 275, + 276, 277, 278, 279, 280, 281, 282, 283, 284, 285, + -1, 287, 288, 289, 290, 291, 292, 293, 294, 295, + 296, -1, 298, 299, 300, 301, 302, 303, 304, 305, + 306, 307, 308, 309, 310, 311, -1, 313, 314, 315, + 316, 317, 318, 319, 320, 321, 322, 323, 324, 325, + 326, -1, 328, 329, 330, 331, 332, 333, 334, 335, + 336, 337, 338, -1, 340, 341, -1, 343, 344, 345, + 346, 347, 348, -1, 350, 351, -1, -1, 354, 355, + 356, 357, 358, 359, 360, 361, 362, 363, 364, 365, + -1, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, 377, 378, 379, 380, 381, -1, 383, 384, 385, + 386, 387, -1, -1, 390, -1, -1, 393, 394, 395, + 396, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 407, 408, 409, -1, -1, -1, -1, -1, -1, + -1, 417, 418, 419, -1, -1, -1, -1, -1, -1, + 426, 3, 4, 5, 6, 7, 8, 9, 10, -1, + -1, -1, 14, 15, 16, 17, 18, 19, 20, 21, + -1, 23, 24, 25, -1, -1, -1, -1, 30, -1, + -1, 33, 34, -1, 36, 37, 38, 39, 40, 41, + 42, 43, 44, 45, 46, -1, 48, 49, 50, 51, + 52, 53, 54, 55, 56, 57, 58, 59, -1, 61, + 62, 63, 64, 65, -1, 67, -1, 69, 70, 71, + 72, 73, 74, 75, -1, 77, 78, 79, 80, 81, + 82, -1, 84, 85, 86, 87, 88, 89, 90, 91, + 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, + 102, 103, 104, -1, 106, 107, 108, 109, 110, -1, + 112, 113, 114, -1, -1, 117, 118, 119, 120, 121, + -1, 123, 124, 125, -1, 127, 128, -1, 130, 131, + 132, 133, 134, 135, 136, 137, 138, 139, 140, -1, + 142, 143, 144, -1, 146, -1, 148, 149, -1, 151, + 152, 153, 154, -1, 156, 157, -1, 159, -1, 161, + 162, 163, 164, 165, 166, 167, 168, 169, -1, 171, + 172, 173, 174, 175, 176, -1, 178, 179, 180, 181, + 182, 183, 184, 185, 186, -1, 188, -1, 190, 191, + 192, 193, 194, 195, 196, 197, 198, 199, 200, 201, + -1, 203, 204, 205, 206, 207, -1, 209, 210, 211, + 212, 213, 214, 215, 216, 217, 218, 219, 220, 221, + 222, 223, 224, 225, 226, 227, 228, 229, 230, 231, + 232, 233, 234, 235, 236, 237, 238, 239, 240, 241, + 242, 243, -1, 245, -1, -1, 248, 249, 250, -1, + -1, 253, 254, 255, 256, 257, 258, 259, 260, 261, + 262, 263, 264, -1, 266, 267, 268, 269, 270, 271, + 272, -1, 274, 275, 276, 277, 278, 279, 280, 281, + 282, 283, 284, 285, -1, 287, 288, 289, 290, 291, + 292, 293, 294, 295, 296, -1, 298, 299, 300, 301, + 302, 303, 304, 305, 306, 307, 308, 309, 310, 311, + -1, 313, 314, 315, 316, 317, 318, 319, 320, 321, + 322, 323, 324, 325, 326, -1, 328, 329, 330, 331, + 332, 333, 334, 335, 336, 337, 338, -1, 340, 341, + -1, 343, 344, 345, 346, 347, 348, -1, 350, 351, + -1, -1, 354, 355, 356, 357, 358, 359, 360, 361, + 362, 363, 364, 365, -1, 367, 368, 369, 370, 371, + 372, 373, -1, 375, 376, 377, 378, 379, 380, 381, + -1, 383, 384, 385, 386, 387, -1, -1, 390, -1, + -1, 393, 394, 395, 396, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 407, 408, 409, -1, -1, + -1, -1, -1, -1, -1, 417, 418, -1, -1, -1, + -1, -1, -1, -1, 426, 3, 4, 5, 6, 7, + 8, 9, 10, -1, -1, -1, 14, 15, 16, 17, + 18, 19, 20, 21, 22, 23, 24, 25, -1, -1, + -1, -1, 30, -1, -1, 33, 34, -1, 36, 37, + 38, 39, 40, 41, 42, 43, 44, 45, 46, -1, + 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, + 58, 59, -1, 61, 62, 63, 64, 65, -1, 67, + -1, 69, 70, 71, 72, 73, 74, 75, -1, 77, + 78, 79, 80, 81, 82, -1, 84, 85, 86, 87, + 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, + 98, 99, 100, 101, 102, -1, 104, -1, 106, 107, + 108, 109, 110, -1, 112, 113, 114, -1, -1, 117, + 118, 119, 120, 121, -1, 123, 124, 125, -1, 127, + 128, -1, 130, 131, 132, 133, 134, 135, 136, 137, + 138, 139, 140, -1, 142, 143, 144, -1, 146, -1, + 148, 149, -1, 151, 152, 153, 154, -1, 156, 157, + -1, 159, -1, 161, 162, 163, 164, 165, 166, 167, + 168, 169, -1, 171, 172, 173, 174, 175, 176, -1, + 178, 179, 180, 181, 182, 183, 184, 185, 186, -1, + 188, -1, 190, 191, 192, 193, 194, 195, 196, 197, + 198, 199, 200, 201, -1, 203, 204, 205, 206, 207, + -1, 209, 210, 211, 212, 213, 214, 215, 216, 217, + 218, 219, 220, 221, 222, 223, 224, 225, 226, 227, + 228, 229, 230, 231, 232, 233, 234, 235, 236, 237, + 238, 239, 240, 241, 242, 243, -1, 245, -1, -1, + 248, 249, 250, -1, -1, 253, 254, 255, 256, 257, + 258, 259, 260, 261, 262, 263, 264, -1, 266, 267, + 268, 269, 270, 271, 272, -1, 274, 275, 276, 277, + 278, 279, 280, 281, 282, 283, 284, 285, -1, 287, + 288, 289, 290, 291, 292, 293, 294, 295, 296, -1, + 298, 299, 300, 301, 302, 303, 304, 305, 306, 307, + 308, 309, 310, 311, -1, 313, 314, 315, 316, 317, + 318, 319, 320, 321, 322, 323, 324, 325, 326, -1, + 328, 329, 330, 331, 332, 333, 334, 335, 336, 337, + 338, -1, 340, 341, -1, 343, 344, 345, 346, 347, + 348, -1, 350, 351, -1, -1, 354, 355, 356, 357, + 358, 359, 360, 361, 362, 363, 364, 365, -1, 367, + 368, 369, 370, 371, 372, 373, -1, 375, 376, 377, + 378, 379, 380, 381, -1, 383, 384, 385, 386, 387, + -1, -1, 390, -1, -1, 393, 394, 395, 396, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, + 408, 409, -1, -1, -1, -1, -1, -1, -1, 417, + 418, -1, -1, -1, -1, -1, -1, -1, 426, 3, + 4, 5, 6, 7, 8, 9, 10, -1, -1, -1, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, 30, -1, -1, 33, + 34, -1, 36, 37, 38, 39, 40, 41, 42, 43, + 44, 45, 46, -1, 48, 49, 50, 51, 52, 53, + 54, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, 65, -1, 67, -1, 69, 70, 71, 72, 73, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + 134, 135, 136, 137, 138, 139, 140, -1, 142, 143, + 144, -1, 146, -1, 148, 149, 150, 151, 152, 153, + 154, -1, 156, 157, -1, 159, -1, 161, 162, 163, + 164, 165, 166, 167, 168, 169, -1, 171, 172, 173, + 174, 175, 176, -1, 178, 179, 180, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, 191, 192, 193, + 194, 195, 196, 197, 198, 199, 200, 201, -1, 203, + 204, 205, 206, 207, -1, 209, 210, 211, 212, 213, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, 227, 228, 229, 230, 231, 232, 233, + 234, 235, 236, 237, 238, 239, 240, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, 253, + 254, 255, 256, 257, 258, 259, 260, 261, 262, 263, + 264, -1, 266, 267, 268, 269, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, 300, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, -1, 313, + 314, 315, 316, 317, 318, 319, 320, 321, 322, 323, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, 338, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, 355, 356, 357, 358, 359, 360, 361, 362, 363, + 364, 365, -1, 367, 368, 369, 370, 371, 372, 373, + -1, 375, 376, 377, 378, 379, 380, 381, -1, 383, + 384, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 407, 408, 409, -1, -1, -1, -1, + -1, -1, -1, 417, 418, -1, -1, -1, -1, -1, + -1, -1, 426, 3, 4, 5, 6, 7, 8, 9, + 10, -1, -1, -1, 14, 15, 16, 17, 18, 19, + 20, 21, -1, 23, 24, 25, -1, -1, -1, -1, + 30, -1, -1, 33, 34, -1, 36, 37, 38, 39, + 40, 41, 42, 43, 44, 45, 46, -1, 48, 49, + 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, + -1, 61, 62, 63, 64, 65, -1, 67, -1, 69, + 70, 71, 72, 73, 74, 75, -1, 77, 78, 79, + 80, 81, 82, -1, 84, 85, 86, 87, 88, 89, + 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, + 100, 101, 102, -1, 104, -1, 106, 107, 108, 109, + 110, -1, 112, 113, 114, -1, -1, 117, 118, 119, + 120, 121, -1, 123, 124, 125, -1, 127, 128, -1, + 130, 131, 132, 133, 134, 135, 136, 137, 138, 139, + 140, -1, 142, 143, 144, -1, 146, -1, 148, 149, + -1, 151, 152, 153, 154, -1, 156, 157, -1, 159, + -1, 161, 162, 163, 164, 165, 166, 167, 168, 169, + -1, 171, 172, 173, 174, 175, 176, -1, 178, 179, + 180, 181, 182, 183, 184, 185, 186, -1, 188, -1, + 190, 191, 192, 193, 194, 195, 196, 197, 198, 199, + 200, 201, -1, 203, 204, 205, 206, 207, -1, 209, + 210, 211, 212, 213, 214, 215, 216, 217, 218, 219, + 220, 221, 222, 223, 224, 225, 226, 227, 228, 229, + 230, 231, 232, 233, 234, 235, 236, 237, 238, 239, + 240, 241, 242, 243, -1, 245, -1, -1, 248, 249, + 250, -1, -1, 253, 254, 255, 256, 257, 258, 259, + 260, 261, 262, 263, 264, -1, 266, 267, 268, 269, + 270, 271, 272, -1, 274, 275, 276, 277, 278, 279, + 280, 281, 282, 283, 284, 285, -1, 287, 288, 289, + 290, 291, 292, 293, 294, 295, 296, -1, 298, 299, + 300, 301, 302, 303, 304, 305, 306, 307, 308, 309, + 310, 311, -1, 313, 314, 315, 316, 317, 318, 319, + 320, 321, 322, 323, 324, 325, 326, -1, 328, 329, + 330, 331, 332, 333, 334, 335, 336, 337, 338, -1, + 340, 341, -1, 343, 344, 345, 346, 347, 348, -1, + 350, 351, -1, -1, 354, 355, 356, 357, 358, 359, + 360, 361, 362, 363, 364, 365, -1, 367, 368, 369, + 370, 371, 372, 373, -1, 375, 376, 377, 378, 379, + 380, 381, 382, 383, 384, 385, 386, 387, -1, -1, + 390, -1, -1, 393, 394, 395, 396, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 407, 408, 409, + -1, -1, -1, -1, -1, -1, -1, 417, 418, -1, + -1, -1, -1, -1, -1, -1, 426, 3, 4, 5, + 6, 7, 8, 9, 10, -1, -1, -1, 14, 15, + 16, 17, 18, 19, 20, 21, -1, 23, 24, 25, + -1, -1, -1, -1, 30, -1, -1, 33, 34, -1, + 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, + 46, -1, 48, 49, 50, 51, 52, 53, 54, 55, + 56, 57, 58, 59, -1, 61, 62, 63, 64, 65, + -1, 67, -1, 69, 70, 71, 72, 73, 74, 75, + -1, 77, 78, 79, 80, 81, 82, -1, 84, 85, + 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, + 96, 97, 98, 99, 100, 101, 102, -1, 104, -1, + 106, 107, 108, 109, 110, -1, 112, 113, 114, -1, + -1, 117, 118, 119, 120, 121, -1, 123, 124, 125, + -1, 127, 128, -1, 130, 131, 132, 133, 134, 135, + 136, 137, 138, 139, 140, -1, 142, 143, 144, -1, + 146, -1, 148, 149, -1, 151, 152, 153, 154, -1, + 156, 157, -1, 159, -1, 161, 162, 163, 164, 165, + 166, 167, 168, 169, -1, 171, 172, 173, 174, 175, + 176, -1, 178, 179, 180, 181, 182, 183, 184, 185, + 186, -1, 188, -1, 190, 191, 192, 193, 194, 195, + 196, 197, 198, 199, 200, 201, -1, 203, 204, 205, + 206, 207, -1, 209, 210, 211, 212, 213, 214, 215, + 216, 217, 218, 219, 220, 221, 222, 223, 224, 225, + 226, 227, 228, 229, 230, 231, 232, 233, 234, 235, + 236, 237, 238, 239, 240, 241, 242, 243, -1, 245, + -1, -1, 248, 249, 250, -1, -1, 253, 254, 255, + 256, 257, 258, 259, 260, 261, 262, 263, 264, -1, + 266, 267, 268, 269, 270, 271, 272, -1, 274, 275, + 276, 277, 278, 279, 280, 281, 282, 283, 284, 285, + -1, 287, 288, 289, 290, 291, 292, 293, 294, 295, + 296, -1, 298, 299, 300, 301, 302, 303, 304, 305, + 306, 307, 308, 309, 310, 311, -1, 313, 314, 315, + 316, 317, 318, 319, 320, 321, 322, 323, 324, 325, + 326, -1, 328, 329, 330, 331, 332, 333, 334, 335, + 336, 337, 338, -1, 340, 341, -1, 343, 344, 345, + 346, 347, 348, -1, 350, 351, -1, -1, 354, 355, + 356, 357, 358, 359, 360, 361, 362, 363, 364, 365, + -1, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, 377, 378, 379, 380, 381, -1, 383, 384, 385, + 386, 387, -1, -1, 390, -1, -1, 393, 394, 395, + 396, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 407, 408, 409, -1, -1, -1, -1, -1, -1, + -1, 417, 418, -1, -1, -1, -1, -1, -1, -1, + 426, 3, 4, 5, 6, 7, 8, 9, 10, -1, + -1, -1, 14, 15, 16, 17, 18, 19, 20, 21, + -1, 23, 24, 25, -1, -1, -1, -1, 30, -1, + -1, 33, 34, -1, 36, 37, 38, 39, 40, 41, + 42, 43, 44, 45, 46, -1, 48, 49, 50, 51, + 52, 53, 54, 55, 56, 57, 58, 59, -1, 61, + 62, 63, 64, 65, -1, 67, -1, 69, 70, 71, + 72, 73, 74, 75, -1, 77, 78, 79, 80, 81, + 82, -1, 84, 85, 86, 87, 88, 89, 90, 91, + 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, + 102, -1, 104, -1, 106, 107, 108, 109, 110, -1, + 112, 113, 114, -1, -1, 117, 118, 119, 120, 121, + -1, 123, 124, 125, -1, 127, 128, -1, 130, 131, + 132, 133, 134, 135, 136, 137, 138, 139, 140, -1, + 142, 143, 144, -1, 146, -1, 148, 149, -1, 151, + 152, 153, 154, -1, 156, 157, -1, 159, -1, 161, + 162, 163, 164, 165, 166, 167, 168, 169, -1, 171, + 172, 173, 174, 175, 176, -1, 178, 179, 180, 181, + 182, 183, 184, 185, 186, -1, 188, -1, 190, 191, + 192, 193, 194, 195, 196, 197, 198, 199, 200, 201, + -1, 203, 204, 205, 206, 207, -1, 209, 210, 211, + 212, 213, 214, 215, 216, 217, 218, 219, 220, 221, + 222, 223, 224, 225, 226, 227, 228, 229, 230, 231, + 232, 233, 234, 235, 236, 237, 238, 239, 240, 241, + 242, 243, -1, 245, -1, -1, 248, 249, 250, -1, + -1, 253, 254, 255, 256, 257, 258, 259, 260, 261, + 262, 263, 264, -1, 266, 267, 268, 269, 270, 271, + 272, -1, 274, 275, 276, 277, 278, 279, 280, 281, + 282, 283, 284, 285, -1, 287, 288, 289, 290, 291, + 292, 293, 294, 295, 296, -1, 298, 299, 300, 301, + 302, 303, 304, 305, 306, 307, 308, 309, 310, 311, + -1, 313, 314, 315, 316, 317, 318, 319, 320, 321, + 322, 323, 324, 325, 326, -1, 328, 329, 330, 331, + 332, 333, 334, 335, 336, 337, 338, -1, 340, 341, + -1, 343, 344, 345, 346, 347, 348, -1, 350, 351, + -1, -1, 354, 355, 356, 357, 358, 359, 360, 361, + 362, 363, 364, 365, -1, 367, 368, 369, 370, 371, + 372, 373, -1, 375, 376, 377, 378, 379, 380, 381, + -1, 383, 384, 385, 386, 387, -1, -1, 390, -1, + -1, 393, 394, 395, 396, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 407, 408, 409, -1, -1, + -1, -1, -1, -1, -1, 417, 418, -1, -1, -1, + -1, -1, -1, -1, 426, 3, 4, 5, 6, 7, + 8, 9, 10, -1, -1, -1, 14, 15, 16, 17, + 18, 19, 20, 21, -1, 23, 24, 25, -1, -1, + -1, -1, 30, -1, -1, 33, 34, -1, 36, 37, + 38, 39, 40, 41, 42, 43, 44, 45, 46, -1, + 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, + 58, 59, -1, 61, 62, 63, 64, 65, -1, 67, + -1, 69, 70, 71, 72, 73, 74, 75, -1, 77, + 78, 79, 80, 81, 82, -1, 84, 85, 86, 87, + 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, + 98, 99, 100, 101, 102, -1, 104, -1, 106, 107, + 108, 109, 110, -1, 112, 113, 114, -1, -1, 117, + 118, 119, 120, 121, -1, 123, 124, 125, -1, 127, + 128, -1, 130, 131, 132, 133, 134, 135, 136, 137, + 138, 139, 140, -1, 142, 143, 144, -1, 146, -1, + 148, 149, -1, 151, 152, 153, 154, -1, 156, 157, + -1, 159, -1, 161, 162, 163, 164, 165, 166, 167, + 168, 169, -1, 171, 172, 173, 174, 175, 176, -1, + 178, 179, 180, 181, 182, 183, 184, 185, 186, -1, + 188, -1, 190, 191, 192, 193, 194, 195, 196, 197, + 198, 199, 200, 201, -1, 203, 204, 205, 206, 207, + -1, 209, 210, 211, 212, 213, 214, 215, 216, 217, + 218, 219, 220, 221, 222, 223, 224, 225, 226, 227, + 228, 229, 230, 231, 232, 233, 234, 235, 236, 237, + 238, 239, 240, 241, 242, 243, -1, 245, -1, -1, + 248, 249, 250, -1, -1, 253, 254, 255, 256, 257, + 258, 259, 260, 261, 262, 263, 264, -1, 266, 267, + 268, 269, 270, 271, 272, -1, 274, 275, 276, 277, + 278, 279, 280, 281, 282, 283, 284, 285, -1, 287, + 288, 289, 290, 291, 292, 293, 294, 295, 296, -1, + 298, 299, 300, 301, 302, 303, 304, 305, 306, 307, + 308, 309, 310, 311, -1, 313, 314, 315, 316, 317, + 318, 319, 320, 321, 322, 323, 324, 325, 326, -1, + 328, 329, 330, 331, 332, 333, 334, 335, 336, 337, + 338, -1, 340, 341, -1, 343, 344, 345, 346, 347, + 348, -1, 350, 351, -1, -1, 354, 355, 356, 357, + 358, 359, 360, 361, 362, 363, 364, 365, -1, 367, + 368, 369, 370, 371, 372, 373, -1, 375, 376, 377, + 378, 379, 380, 381, -1, 383, 384, 385, 386, 387, + -1, -1, 390, -1, -1, 393, 394, 395, 396, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, + 408, 409, -1, -1, -1, -1, -1, -1, -1, 417, + 418, -1, -1, -1, -1, -1, -1, -1, 426, 3, + 4, 5, 6, 7, 8, 9, 10, -1, -1, -1, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, 30, -1, -1, 33, + 34, -1, 36, 37, 38, 39, 40, 41, 42, 43, + 44, 45, 46, -1, 48, 49, 50, 51, 52, 53, + 54, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, 65, -1, 67, -1, 69, 70, 71, 72, 73, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + 134, 135, 136, 137, 138, 139, 140, -1, 142, 143, + 144, -1, 146, -1, 148, 149, -1, 151, 152, 153, + 154, -1, 156, 157, -1, 159, -1, 161, 162, 163, + 164, 165, 166, 167, 168, 169, -1, 171, 172, 173, + 174, 175, 176, -1, 178, 179, 180, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, 191, 192, 193, + 194, 195, 196, 197, 198, 199, 200, 201, -1, 203, + 204, 205, 206, 207, -1, 209, 210, 211, 212, 213, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, 227, 228, 229, 230, 231, 232, 233, + 234, 235, 236, 237, 238, 239, 240, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, 253, + 254, 255, 256, 257, 258, 259, 260, 261, 262, 263, + 264, -1, 266, 267, 268, 269, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, 300, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, -1, 313, + 314, 315, 316, 317, 318, 319, 320, 321, 322, 323, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, 338, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, 355, 356, 357, 358, 359, 360, 361, 362, 363, + 364, 365, -1, 367, 368, 369, 370, 371, 372, 373, + -1, 375, 376, 377, 378, 379, 380, 381, -1, 383, + 384, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 407, 408, 409, -1, -1, -1, -1, + -1, -1, -1, 417, 418, -1, -1, -1, -1, -1, + -1, -1, 426, 3, 4, 5, 6, 7, 8, 9, + 10, -1, -1, -1, 14, 15, 16, 17, 18, 19, + 20, 21, -1, 23, 24, 25, -1, -1, -1, -1, + 30, -1, -1, 33, 34, -1, 36, 37, 38, 39, + 40, 41, 42, 43, 44, 45, 46, -1, 48, 49, + 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, + -1, 61, 62, 63, 64, 65, -1, 67, -1, 69, + 70, 71, 72, 73, 74, 75, -1, 77, 78, 79, + 80, 81, 82, -1, 84, 85, 86, 87, 88, 89, + 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, + 100, 101, 102, -1, 104, -1, 106, 107, 108, 109, + 110, -1, 112, 113, 114, -1, -1, 117, 118, 119, + 120, 121, -1, 123, 124, 125, -1, 127, 128, -1, + 130, 131, 132, 133, 134, 135, 136, 137, 138, 139, + 140, -1, 142, 143, 144, -1, 146, -1, 148, 149, + -1, 151, 152, 153, 154, -1, 156, 157, -1, 159, + -1, 161, 162, 163, 164, 165, 166, 167, 168, 169, + -1, 171, 172, 173, 174, 175, 176, -1, 178, 179, + 180, 181, 182, 183, 184, 185, 186, -1, 188, -1, + 190, 191, 192, 193, 194, 195, 196, 197, 198, 199, + 200, 201, -1, 203, 204, 205, 206, 207, -1, 209, + 210, 211, 212, 213, 214, 215, 216, 217, 218, 219, + 220, 221, 222, 223, 224, 225, 226, 227, 228, 229, + 230, 231, 232, 233, 234, 235, 236, 237, 238, 239, + 240, 241, 242, 243, -1, 245, -1, -1, 248, 249, + 250, -1, -1, 253, 254, 255, 256, 257, 258, 259, + 260, 261, 262, 263, 264, -1, 266, 267, 268, 269, + 270, 271, 272, -1, 274, 275, 276, 277, 278, 279, + 280, 281, 282, 283, 284, 285, -1, 287, 288, 289, + 290, 291, 292, 293, 294, 295, 296, -1, 298, 299, + 300, 301, 302, 303, 304, 305, 306, 307, 308, 309, + 310, 311, -1, 313, 314, 315, 316, 317, 318, 319, + 320, 321, 322, 323, 324, 325, 326, -1, 328, 329, + 330, 331, 332, 333, 334, 335, 336, 337, 338, -1, + 340, 341, -1, 343, 344, 345, 346, 347, 348, -1, + 350, 351, -1, -1, 354, 355, 356, 357, 358, 359, + 360, 361, 362, 363, 364, 365, -1, 367, 368, 369, + 370, 371, 372, 373, -1, 375, 376, 377, 378, 379, + 380, 381, -1, 383, 384, 385, 386, 387, -1, -1, + 390, -1, -1, 393, 394, 395, 396, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 407, 408, 409, + -1, -1, -1, -1, -1, -1, -1, 417, 418, -1, + -1, -1, -1, -1, -1, -1, 426, 3, 4, 5, + 6, 7, 8, 9, 10, -1, -1, -1, 14, 15, + 16, 17, 18, 19, 20, 21, -1, 23, 24, 25, + -1, -1, -1, -1, 30, -1, -1, 33, 34, -1, + 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, + 46, -1, 48, 49, 50, 51, 52, 53, 54, 55, + 56, 57, 58, 59, -1, 61, 62, 63, 64, 65, + -1, 67, -1, 69, 70, 71, 72, 73, 74, 75, + -1, 77, 78, 79, 80, 81, 82, -1, 84, 85, + 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, + 96, 97, 98, 99, 100, 101, 102, -1, 104, -1, + 106, 107, 108, 109, 110, -1, 112, 113, 114, -1, + -1, 117, 118, 119, 120, 121, -1, 123, 124, 125, + -1, 127, 128, -1, 130, 131, 132, 133, 134, 135, + 136, 137, 138, 139, 140, -1, 142, 143, 144, -1, + 146, -1, 148, 149, -1, 151, 152, 153, 154, -1, + 156, 157, -1, 159, -1, 161, 162, 163, 164, 165, + 166, 167, 168, 169, -1, 171, 172, 173, 174, 175, + 176, -1, 178, 179, 180, 181, 182, 183, 184, 185, + 186, -1, 188, -1, 190, 191, 192, 193, 194, 195, + 196, 197, 198, 199, 200, 201, -1, 203, 204, 205, + 206, 207, -1, 209, 210, 211, 212, 213, 214, 215, + 216, 217, 218, 219, 220, 221, 222, 223, 224, 225, + 226, 227, 228, 229, 230, 231, 232, 233, 234, 235, + 236, 237, 238, 239, 240, 241, 242, 243, -1, 245, + -1, -1, 248, 249, 250, -1, -1, 253, 254, 255, + 256, 257, 258, 259, 260, 261, 262, 263, 264, -1, + 266, 267, 268, 269, 270, 271, 272, -1, 274, 275, + 276, 277, 278, 279, 280, 281, 282, 283, 284, 285, + -1, 287, 288, 289, 290, 291, 292, 293, 294, 295, + 296, -1, 298, 299, 300, 301, 302, 303, 304, 305, + 306, 307, 308, 309, 310, 311, -1, 313, 314, 315, + 316, 317, 318, 319, 320, 321, 322, 323, 324, 325, + 326, -1, 328, 329, 330, 331, 332, 333, 334, 335, + 336, 337, 338, -1, 340, 341, -1, 343, 344, 345, + 346, 347, 348, -1, 350, 351, -1, -1, 354, 355, + 356, 357, 358, 359, 360, 361, 362, 363, 364, 365, + -1, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, 377, 378, 379, 380, 381, -1, 383, 384, 385, + 386, 387, -1, -1, 390, -1, -1, 393, 394, 395, + 396, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 407, 408, 409, -1, -1, -1, -1, -1, -1, + -1, 417, 418, -1, -1, -1, -1, -1, -1, -1, + 426, 3, 4, 5, 6, 7, 8, 9, 10, -1, + -1, -1, 14, 15, 16, 17, 18, 19, 20, 21, + -1, 23, 24, 25, -1, -1, -1, -1, 30, -1, + -1, 33, 34, -1, 36, 37, 38, 39, 40, 41, + 42, 43, 44, 45, 46, -1, 48, 49, 50, 51, + 52, 53, 54, 55, 56, 57, 58, 59, -1, 61, + 62, 63, 64, 65, -1, 67, -1, 69, 70, 71, + 72, 73, 74, 75, -1, 77, 78, 79, 80, 81, + 82, -1, 84, 85, 86, 87, 88, 89, 90, 91, + 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, + 102, -1, 104, -1, 106, 107, 108, 109, 110, -1, + 112, 113, 114, -1, -1, 117, 118, 119, 120, 121, + -1, 123, 124, 125, -1, 127, 128, -1, 130, 131, + 132, 133, 134, 135, 136, 137, 138, 139, 140, -1, + 142, 143, 144, -1, 146, -1, 148, 149, -1, 151, + 152, 153, 154, -1, 156, 157, -1, 159, -1, 161, + 162, 163, 164, 165, 166, 167, 168, 169, -1, 171, + 172, 173, 174, 175, 176, -1, 178, 179, 180, 181, + 182, 183, 184, 185, 186, -1, 188, -1, 190, 191, + 192, 193, 194, 195, 196, 197, 198, 199, 200, 201, + -1, 203, 204, 205, 206, 207, -1, 209, 210, 211, + 212, 213, 214, 215, 216, 217, 218, 219, 220, 221, + 222, 223, 224, 225, 226, 227, 228, 229, 230, 231, + -1, 233, 234, 235, 236, 237, 238, 239, 240, 241, + 242, 243, -1, 245, -1, -1, 248, 249, 250, -1, + -1, 253, 254, 255, 256, 257, 258, 259, 260, 261, + 262, 263, 264, -1, 266, 267, 268, 269, 270, 271, + 272, -1, 274, 275, 276, 277, 278, 279, 280, 281, + 282, 283, 284, 285, -1, 287, 288, 289, 290, 291, + 292, 293, 294, 295, 296, -1, 298, 299, 300, 301, + 302, 303, 304, 305, 306, 307, 308, 309, 310, 311, + -1, 313, 314, 315, 316, 317, 318, 319, 320, 321, + 322, 323, 324, 325, 326, -1, 328, 329, 330, 331, + 332, 333, 334, 335, 336, 337, 338, -1, 340, 341, + -1, 343, 344, 345, 346, 347, 348, -1, 350, 351, + -1, -1, 354, 355, 356, 357, 358, 359, 360, 361, + 362, 363, 364, 365, -1, -1, 368, 369, 370, 371, + 372, 373, -1, 375, 376, 377, 378, 379, 380, 381, + -1, 383, 384, 385, 386, 387, -1, -1, 390, -1, + -1, 393, 394, 395, 396, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 407, 408, 409, -1, -1, + -1, -1, -1, -1, -1, 417, 418, -1, -1, -1, + -1, -1, -1, -1, 426, 3, 4, 5, 6, 7, + 8, 9, 10, -1, -1, -1, 14, 15, 16, 17, + 18, 19, 20, 21, -1, 23, 24, 25, -1, -1, + -1, -1, 30, -1, -1, 33, 34, -1, 36, 37, + 38, 39, 40, 41, 42, 43, 44, 45, 46, -1, + 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, + 58, 59, -1, 61, 62, 63, 64, 65, -1, 67, + -1, 69, 70, 71, 72, 73, 74, 75, -1, 77, + 78, 79, 80, 81, 82, -1, 84, 85, 86, 87, + 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, + 98, 99, 100, 101, 102, -1, 104, -1, 106, 107, + 108, 109, 110, -1, 112, 113, 114, -1, -1, 117, + 118, 119, 120, 121, -1, 123, 124, 125, -1, 127, + 128, -1, 130, 131, 132, 133, 134, 135, 136, 137, + 138, 139, 140, -1, 142, 143, 144, -1, 146, -1, + 148, 149, -1, 151, 152, 153, 154, -1, 156, 157, + -1, 159, -1, 161, 162, 163, 164, 165, -1, 167, + 168, 169, -1, 171, 172, 173, 174, 175, 176, -1, + 178, 179, 180, 181, 182, 183, 184, 185, 186, -1, + 188, -1, 190, 191, 192, 193, 194, 195, 196, 197, + 198, 199, 200, 201, -1, 203, 204, 205, 206, -1, + -1, 209, 210, 211, 212, 213, 214, 215, 216, 217, + 218, 219, 220, 221, 222, 223, 224, 225, 226, 227, + 228, 229, 230, 231, -1, 233, 234, 235, 236, 237, + 238, 239, 240, 241, 242, 243, -1, 245, -1, -1, + 248, 249, 250, -1, -1, 253, 254, 255, 256, 257, + 258, 259, 260, 261, 262, 263, 264, -1, 266, 267, + 268, 269, 270, 271, 272, -1, 274, 275, 276, 277, + 278, 279, 280, 281, 282, 283, 284, 285, -1, 287, + 288, 289, 290, 291, 292, 293, 294, 295, 296, -1, + 298, 299, 300, 301, 302, 303, 304, 305, 306, 307, + 308, 309, 310, 311, -1, 313, 314, 315, 316, 317, + 318, 319, 320, 321, 322, -1, 324, 325, 326, -1, + 328, 329, 330, 331, 332, 333, 334, 335, 336, 337, + 338, -1, 340, 341, -1, 343, 344, 345, 346, 347, + 348, -1, 350, 351, -1, -1, 354, 355, 356, 357, + 358, 359, 360, 361, 362, 363, 364, 365, -1, 367, + 368, 369, 370, 371, 372, 373, -1, 375, 376, 377, + 378, 379, 380, 381, -1, 383, 384, 385, 386, 387, + -1, -1, 390, -1, -1, 393, 394, 395, 396, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, + 408, 409, -1, -1, -1, -1, -1, -1, -1, 417, + 418, -1, -1, 3, 4, 5, 6, 7, 426, 9, + 10, -1, -1, -1, 14, 15, 16, 17, 18, 19, + 20, 21, -1, 23, 24, 25, -1, -1, -1, -1, + 30, -1, -1, 33, 34, -1, 36, 37, 38, 39, + 40, 41, 42, 43, 44, 45, 46, -1, 48, 49, + 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, + -1, 61, 62, 63, 64, 65, -1, 67, -1, 69, + 70, 71, 72, 73, 74, 75, -1, 77, 78, 79, + 80, 81, 82, -1, 84, 85, 86, 87, 88, 89, + 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, + 100, 101, 102, -1, 104, -1, 106, 107, 108, 109, + 110, -1, 112, 113, 114, -1, -1, 117, 118, 119, + 120, 121, -1, 123, 124, 125, -1, 127, 128, -1, + 130, 131, 132, 133, 134, 135, 136, 137, 138, 139, + 140, -1, 142, 143, 144, -1, 146, -1, 148, 149, + -1, 151, 152, 153, 154, -1, 156, 157, -1, 159, + -1, 161, 162, 163, 164, 165, 166, 167, 168, 169, + -1, 171, 172, 173, 174, 175, 176, -1, 178, 179, + 180, 181, 182, 183, 184, 185, 186, -1, 188, -1, + 190, 191, 192, 193, 194, 195, 196, 197, 198, 199, + 200, 201, -1, 203, 204, 205, 206, 207, -1, 209, + 210, 211, 212, 213, 214, 215, 216, 217, 218, 219, + 220, 221, 222, 223, 224, 225, 226, 227, 228, 229, + 230, 231, -1, 233, 234, 235, 236, 237, 238, 239, + 240, 241, 242, 243, -1, 245, -1, -1, 248, 249, + 250, -1, -1, 253, 254, 255, 256, 257, 258, 259, + 260, 261, 262, 263, 264, -1, 266, 267, 268, 269, + 270, 271, 272, -1, 274, 275, 276, 277, 278, 279, + 280, 281, 282, 283, 284, 285, -1, 287, 288, 289, + 290, 291, 292, 293, 294, 295, 296, -1, 298, 299, + 300, 301, 302, 303, 304, 305, 306, 307, 308, 309, + 310, 311, -1, 313, 314, 315, 316, 317, 318, 319, + 320, 321, 322, 323, 324, 325, 326, -1, 328, 329, + 330, 331, 332, 333, 334, 335, 336, 337, 338, -1, + 340, 341, -1, 343, 344, 345, 346, 347, 348, -1, + 350, 351, -1, -1, 354, 355, 356, 357, 358, 359, + 360, 361, 362, 363, 364, 365, -1, -1, 368, 369, + 370, 371, 372, 373, -1, 375, 376, 377, 378, 379, + 380, 381, -1, 383, 384, 385, 386, 387, -1, -1, + 390, -1, -1, 393, 394, 395, 396, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 407, 408, 409, + -1, -1, -1, -1, -1, -1, 3, 4, 5, 6, + 7, -1, 9, 10, -1, -1, 426, 14, 15, 16, + 17, 18, 19, 20, 21, -1, 23, 24, 25, -1, + -1, -1, -1, 30, -1, -1, 33, 34, -1, 36, + 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, + -1, 48, 49, 50, 51, 52, 53, 54, 55, 56, + 57, 58, 59, -1, 61, 62, 63, 64, 65, -1, + 67, -1, 69, 70, 71, 72, 73, 74, 75, -1, + 77, 78, 79, 80, 81, 82, -1, 84, 85, 86, + 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, + 97, 98, 99, 100, 101, 102, -1, 104, -1, 106, + 107, 108, 109, 110, -1, 112, 113, 114, -1, -1, + 117, 118, 119, 120, 121, -1, 123, 124, 125, -1, + 127, 128, -1, 130, 131, 132, 133, 134, 135, 136, + 137, 138, 139, 140, -1, 142, 143, 144, -1, 146, + -1, 148, 149, -1, 151, 152, 153, 154, -1, 156, + 157, -1, 159, -1, 161, 162, 163, 164, 165, 166, + 167, 168, 169, -1, 171, 172, 173, 174, 175, 176, + -1, 178, 179, 180, 181, 182, 183, 184, 185, 186, + -1, 188, -1, 190, 191, 192, 193, 194, 195, 196, + 197, 198, 199, 200, 201, -1, 203, 204, 205, 206, + 207, -1, 209, 210, 211, 212, 213, 214, 215, 216, + 217, 218, 219, 220, 221, 222, 223, 224, 225, 226, + 227, 228, 229, 230, 231, -1, 233, 234, 235, 236, + 237, 238, 239, 240, 241, 242, 243, -1, 245, -1, + -1, 248, 249, 250, -1, -1, 253, 254, 255, 256, + 257, 258, 259, 260, 261, 262, 263, 264, -1, 266, + 267, 268, 269, 270, 271, 272, -1, 274, 275, 276, + 277, 278, 279, 280, 281, 282, 283, 284, 285, -1, + 287, 288, 289, 290, 291, 292, 293, 294, 295, 296, + -1, 298, 299, 300, 301, 302, 303, 304, 305, 306, + 307, 308, 309, 310, 311, -1, 313, 314, 315, 316, + 317, 318, 319, 320, 321, 322, 323, 324, 325, 326, + -1, 328, 329, 330, 331, 332, 333, 334, 335, 336, + 337, 338, -1, 340, 341, -1, 343, 344, 345, 346, + 347, 348, -1, 350, 351, -1, -1, 354, 355, 356, + 357, 358, 359, 360, 361, 362, 363, 364, 365, -1, + -1, 368, 369, 370, 371, 372, 373, -1, 375, 376, + 377, 378, 379, 380, 381, -1, 383, 384, 385, 386, + 387, -1, -1, 390, -1, -1, 393, 394, 395, 396, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 407, 408, 409, -1, -1, -1, -1, -1, -1, 3, + 4, 5, 6, 7, 8, 9, 10, -1, -1, 426, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, 30, -1, -1, 33, + 34, -1, 36, 37, 38, 39, 40, 41, -1, 43, + 44, 45, 46, -1, 48, 49, 50, 51, 52, 53, + 54, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, 65, -1, 67, -1, 69, 70, 71, 72, 73, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, -1, -1, 130, 131, 132, 133, + 134, 135, 136, 137, 138, 139, 140, -1, 142, 143, + 144, -1, 146, -1, 148, 149, -1, 151, 152, 153, + 154, -1, 156, 157, -1, 159, -1, 161, 162, 163, + 164, 165, -1, 167, 168, 169, -1, 171, 172, 173, + 174, 175, 176, -1, 178, 179, 180, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, 191, 192, 193, + 194, 195, 196, 197, 198, 199, 200, 201, -1, 203, + 204, 205, 206, -1, -1, 209, 210, 211, 212, 213, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, 227, 228, 229, 230, 231, -1, 233, + 234, 235, 236, 237, 238, 239, 240, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, 253, + 254, 255, 256, 257, 258, 259, 260, 261, 262, 263, + 264, -1, 266, 267, 268, 269, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, 300, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, -1, 313, + 314, 315, 316, 317, 318, 319, 320, 321, 322, -1, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, 338, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, 355, 356, 357, 358, 359, 360, 361, 362, 363, + 364, 365, -1, 367, 368, 369, 370, 371, 372, 373, + -1, 375, 376, 377, 378, 379, 380, 381, -1, 383, + 384, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 407, 408, 409, -1, -1, -1, -1, + -1, -1, -1, 417, 418, -1, -1, -1, -1, -1, + -1, -1, 426, 3, 4, 5, 6, 7, 8, 9, + 10, -1, -1, -1, 14, 15, 16, 17, 18, 19, + 20, 21, -1, 23, 24, 25, -1, -1, -1, -1, + 30, -1, -1, 33, 34, -1, 36, 37, 38, 39, + 40, 41, -1, 43, 44, 45, 46, -1, 48, 49, + 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, + -1, 61, 62, 63, 64, 65, -1, 67, -1, 69, + 70, 71, 72, 73, 74, 75, -1, 77, 78, 79, + 80, 81, 82, -1, 84, 85, 86, 87, 88, 89, + 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, + 100, 101, 102, -1, 104, -1, 106, 107, 108, 109, + 110, -1, 112, 113, 114, -1, -1, 117, 118, 119, + 120, 121, -1, 123, 124, 125, -1, 127, -1, -1, + 130, 131, 132, 133, 134, 135, 136, 137, 138, 139, + 140, -1, 142, 143, 144, -1, 146, -1, 148, 149, + -1, 151, 152, 153, 154, -1, 156, 157, -1, 159, + -1, 161, 162, 163, 164, 165, -1, 167, 168, 169, + -1, 171, 172, 173, 174, 175, 176, -1, 178, 179, + 180, 181, 182, 183, 184, 185, 186, -1, 188, -1, + 190, 191, 192, 193, 194, 195, 196, 197, 198, 199, + 200, 201, -1, 203, 204, 205, 206, -1, -1, 209, + 210, 211, 212, 213, 214, 215, 216, 217, 218, 219, + 220, 221, 222, 223, 224, 225, 226, 227, 228, 229, + 230, 231, -1, 233, 234, 235, 236, 237, 238, 239, + 240, 241, 242, 243, -1, 245, -1, -1, 248, 249, + 250, -1, -1, 253, 254, 255, 256, 257, 258, 259, + 260, 261, 262, 263, 264, -1, 266, 267, 268, 269, + 270, 271, 272, -1, 274, 275, 276, 277, 278, 279, + 280, 281, 282, 283, 284, 285, -1, 287, 288, 289, + 290, 291, 292, 293, 294, 295, 296, -1, 298, 299, + 300, 301, 302, 303, 304, 305, 306, 307, 308, 309, + 310, 311, -1, 313, 314, 315, 316, 317, 318, 319, + 320, 321, 322, -1, 324, 325, 326, -1, 328, 329, + 330, 331, 332, 333, 334, 335, 336, 337, 338, -1, + 340, 341, -1, 343, 344, 345, 346, 347, 348, -1, + 350, 351, -1, -1, 354, 355, 356, 357, 358, 359, + 360, 361, 362, 363, 364, 365, -1, -1, 368, 369, + 370, 371, 372, 373, -1, 375, 376, 377, 378, 379, + 380, 381, -1, 383, 384, 385, 386, 387, -1, -1, + 390, -1, -1, 393, 394, 395, 396, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 407, 408, 409, + -1, -1, -1, -1, -1, -1, 3, 417, 418, -1, + -1, -1, -1, -1, -1, -1, 426, 14, 15, 16, + 17, 18, 19, 20, 21, -1, 23, 24, 25, -1, + -1, -1, -1, -1, -1, -1, 33, 34, -1, 36, + 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, + -1, 48, 49, 50, 51, 52, -1, 54, 55, 56, + 57, 58, 59, -1, 61, 62, 63, 64, 65, -1, + 67, -1, 69, 70, 71, 72, 73, 74, 75, -1, + 77, 78, 79, 80, 81, 82, -1, 84, 85, 86, + 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, + 97, 98, 99, 100, 101, 102, -1, 104, -1, 106, + 107, 108, 109, 110, -1, 112, 113, 114, -1, -1, + 117, 118, 119, 120, 121, -1, 123, 124, 125, -1, + 127, 128, -1, 130, 131, 132, 133, 134, 135, 136, + 137, 138, -1, 140, -1, 142, 143, 144, -1, 146, + -1, 148, 149, -1, 151, 152, 153, 154, -1, 156, + 157, -1, 159, -1, 161, 162, 163, 164, 165, 166, + 167, 168, 169, -1, 171, 172, 173, 174, 175, 176, + -1, 178, 179, 180, 181, 182, 183, 184, 185, 186, + -1, 188, -1, 190, 191, 192, 193, 194, 195, 196, + 197, 198, 199, 200, 201, -1, 203, 204, 205, 206, + 207, -1, 209, 210, 211, 212, 213, 214, 215, 216, + 217, 218, 219, 220, 221, 222, 223, 224, 225, 226, + 227, 228, 229, 230, 231, -1, 233, 234, 235, 236, + -1, 238, 239, 240, 241, 242, 243, -1, 245, -1, + 247, 248, 249, 250, -1, -1, 253, 254, 255, 256, + 257, 258, 259, 260, 261, 262, 263, 264, -1, 266, + 267, 268, 269, 270, 271, 272, -1, 274, 275, 276, + 277, 278, 279, 280, 281, 282, 283, 284, 285, -1, + 287, 288, 289, 290, 291, 292, 293, 294, 295, 296, + -1, 298, 299, 300, 301, 302, 303, 304, 305, 306, + 307, 308, 309, 310, 311, 312, 313, 314, 315, 316, + 317, 318, 319, 320, 321, 322, 323, 324, 325, 326, + -1, 328, 329, 330, 331, 332, 333, 334, 335, 336, + 337, 338, -1, 340, 341, 342, 343, 344, 345, 346, + 347, 348, -1, 350, 351, -1, -1, 354, 355, 356, + 357, -1, 359, 360, 361, 362, 363, 364, 365, -1, + -1, 368, 369, 370, 371, 372, 373, -1, 375, 376, + 377, 378, 379, 380, 381, -1, 383, 384, 385, 386, + 387, -1, -1, 390, -1, 392, 393, 394, 395, 396, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 407, 408, 409, -1, -1, -1, -1, -1, -1, 3, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 426, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, -1, -1, -1, 33, + 34, -1, 36, 37, 38, 39, 40, 41, 42, 43, + 44, 45, 46, -1, 48, 49, 50, 51, 52, -1, + 54, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, 65, -1, 67, -1, 69, 70, 71, 72, 73, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + 134, 135, 136, 137, 138, -1, 140, -1, 142, 143, + 144, -1, 146, -1, 148, 149, -1, 151, 152, 153, + 154, -1, 156, 157, -1, 159, -1, 161, 162, 163, + 164, 165, 166, 167, 168, 169, -1, 171, 172, 173, + 174, 175, 176, -1, 178, 179, 180, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, 191, 192, 193, + 194, 195, 196, 197, 198, 199, 200, 201, -1, 203, + 204, 205, 206, 207, -1, 209, 210, 211, 212, 213, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, 227, 228, 229, 230, 231, -1, 233, + 234, 235, 236, -1, 238, 239, 240, 241, 242, 243, + -1, 245, -1, 247, 248, 249, 250, -1, -1, 253, + 254, 255, 256, 257, 258, 259, 260, 261, 262, 263, + 264, -1, 266, 267, 268, 269, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, 300, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, -1, 313, + 314, 315, 316, 317, 318, 319, 320, 321, 322, 323, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, 338, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, 355, 356, 357, -1, 359, 360, 361, 362, 363, + 364, 365, -1, -1, 368, 369, 370, 371, 372, 373, + -1, 375, 376, 377, 378, 379, 380, 381, -1, 383, + 384, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 407, 408, 409, -1, -1, -1, -1, + -1, -1, 3, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 426, 14, 15, 16, 17, 18, 19, 20, + 21, -1, 23, 24, 25, -1, -1, -1, -1, -1, + -1, -1, 33, 34, -1, 36, 37, 38, 39, 40, + 41, 42, 43, 44, 45, 46, -1, 48, 49, 50, + 51, 52, -1, 54, 55, 56, 57, 58, 59, -1, + 61, 62, 63, 64, 65, -1, 67, -1, 69, 70, + 71, 72, 73, 74, 75, -1, 77, 78, 79, 80, + 81, 82, -1, 84, 85, 86, 87, 88, 89, 90, + 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, + 101, 102, -1, 104, -1, 106, 107, 108, 109, 110, + -1, 112, 113, 114, -1, -1, 117, 118, 119, 120, + 121, -1, 123, 124, 125, -1, 127, 128, -1, 130, + 131, 132, 133, 134, 135, 136, 137, 138, -1, 140, + -1, 142, 143, 144, -1, 146, -1, 148, 149, -1, + 151, 152, 153, 154, -1, 156, 157, -1, 159, -1, + 161, 162, 163, 164, 165, 166, 167, 168, 169, -1, + 171, 172, 173, 174, 175, 176, -1, 178, 179, 180, + 181, 182, 183, 184, 185, 186, -1, 188, -1, 190, + 191, 192, 193, 194, 195, 196, 197, 198, 199, 200, + 201, -1, 203, 204, 205, 206, 207, -1, 209, 210, + 211, 212, 213, 214, 215, 216, 217, 218, 219, 220, + 221, 222, 223, 224, 225, 226, 227, 228, 229, 230, + 231, -1, 233, 234, 235, 236, -1, 238, 239, 240, + 241, 242, 243, -1, 245, -1, -1, 248, 249, 250, + -1, -1, 253, 254, 255, 256, 257, 258, 259, 260, + 261, 262, 263, 264, -1, 266, 267, 268, 269, 270, + 271, 272, -1, 274, 275, 276, 277, 278, 279, 280, + 281, 282, 283, 284, 285, -1, 287, 288, 289, 290, + 291, 292, 293, 294, 295, 296, -1, 298, 299, 300, + 301, 302, 303, 304, 305, 306, 307, 308, 309, 310, + 311, -1, 313, 314, 315, 316, 317, 318, 319, 320, + 321, 322, 323, 324, 325, 326, -1, 328, 329, 330, + 331, 332, 333, 334, 335, 336, 337, 338, -1, 340, + 341, -1, 343, 344, 345, 346, 347, 348, -1, 350, + 351, -1, -1, 354, 355, 356, 357, -1, 359, 360, + 361, 362, 363, 364, 365, -1, -1, 368, 369, 370, + 371, 372, 373, -1, 375, 376, 377, 378, 379, 380, + 381, -1, 383, 384, 385, 386, 387, -1, -1, 390, + -1, -1, 393, 394, 395, 396, 397, 398, 399, 400, + 401, 402, 403, 404, 405, 406, 407, 408, 409, -1, + -1, -1, -1, -1, -1, 3, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 426, 14, 15, 16, 17, + 18, 19, 20, 21, -1, 23, 24, 25, -1, -1, + -1, -1, -1, -1, -1, 33, 34, -1, 36, 37, + 38, 39, 40, 41, 42, 43, 44, 45, 46, -1, + 48, 49, 50, 51, 52, -1, -1, 55, 56, 57, + 58, 59, -1, 61, 62, 63, 64, 65, -1, 67, + -1, 69, 70, 71, 72, 73, 74, 75, -1, 77, + 78, 79, 80, 81, 82, -1, 84, 85, 86, -1, + -1, -1, 90, -1, -1, -1, 94, 95, 96, 97, + 98, 99, 100, 101, 102, -1, 104, -1, 106, 107, + 108, 109, 110, -1, 112, 113, 114, -1, -1, 117, + 118, 119, 120, 121, -1, 123, 124, 125, -1, 127, + 128, -1, 130, 131, 132, 133, 134, 135, 136, 137, + 138, -1, 140, -1, 142, 143, 144, -1, 146, -1, + 148, 149, -1, 151, 152, 153, 154, -1, 156, 157, + -1, 159, -1, 161, 162, 163, 164, 165, 166, 167, + 168, 169, -1, 171, 172, 173, 174, 175, 176, -1, + 178, 179, 180, 181, 182, 183, 184, 185, 186, -1, + 188, -1, 190, 191, 192, 193, 194, 195, 196, 197, + 198, 199, 200, 201, -1, 203, 204, 205, 206, 207, + -1, 209, 210, 211, -1, -1, 214, 215, 216, 217, + 218, 219, 220, 221, 222, 223, 224, 225, 226, 227, + 228, 229, 230, 231, -1, 233, 234, 235, 236, -1, + 238, 239, 240, 241, 242, 243, -1, 245, -1, -1, + 248, 249, 250, -1, -1, 253, 254, 255, 256, 257, + 258, 259, 260, 261, 262, 263, 264, -1, 266, 267, + 268, 269, 270, 271, 272, -1, 274, 275, 276, 277, + 278, 279, 280, 281, 282, 283, 284, 285, -1, 287, + 288, 289, 290, 291, 292, 293, 294, 295, 296, -1, + 298, 299, 300, 301, 302, 303, 304, 305, 306, 307, + 308, 309, 310, 311, -1, 313, 314, 315, 316, 317, + -1, 319, 320, 321, 322, 323, 324, 325, 326, -1, + 328, 329, 330, 331, 332, 333, 334, 335, 336, 337, + 338, -1, 340, 341, -1, 343, 344, 345, 346, 347, + 348, -1, 350, 351, -1, -1, 354, 355, 356, 357, + -1, 359, 360, 361, 362, 363, 364, 365, -1, -1, + 368, 369, 370, 371, 372, -1, -1, 375, 376, 377, + 378, 379, 380, 381, -1, 383, 384, 385, 386, 387, + -1, -1, 390, -1, -1, 393, 394, 395, 396, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, + 408, 409, -1, -1, -1, -1, -1, -1, 3, 4, + 5, -1, -1, -1, 9, -1, -1, -1, 426, 14, + 15, 16, 17, 18, 19, 20, 21, -1, 23, 24, + 25, -1, -1, -1, -1, -1, -1, -1, 33, 34, + -1, 36, 37, -1, 39, 40, 41, 42, 43, -1, + 45, 46, -1, 48, 49, 50, 51, 52, -1, -1, + 55, 56, 57, 58, 59, -1, 61, 62, 63, 64, + 65, -1, -1, -1, 69, 70, 71, 72, -1, 74, + 75, -1, 77, 78, 79, 80, 81, 82, -1, -1, + 85, 86, -1, -1, -1, -1, -1, -1, -1, 94, + 95, 96, 97, 98, 99, 100, 101, 102, -1, 104, + -1, 106, 107, 108, 109, 110, -1, 112, 113, 114, + -1, -1, 117, 118, 119, 120, 121, -1, 123, 124, + 125, -1, 127, 128, -1, 130, 131, 132, 133, 134, + 135, 136, 137, 138, 139, 140, -1, 142, 143, 144, + -1, 146, -1, 148, -1, -1, -1, 152, 153, 154, + -1, 156, 157, -1, 159, -1, 161, 162, 163, 164, + 165, -1, 167, 168, 169, -1, 171, 172, 173, 174, + 175, 176, -1, 178, -1, 180, 181, 182, 183, 184, + 185, 186, -1, 188, -1, 190, -1, -1, 193, -1, + 195, 196, 197, 198, 199, 200, 201, -1, 203, 204, + -1, 206, -1, -1, 209, 210, 211, -1, -1, 214, + 215, 216, 217, 218, 219, 220, 221, 222, 223, 224, + 225, 226, -1, 228, 229, 230, 231, -1, 233, 234, + -1, 236, -1, 238, 239, 240, 241, 242, 243, -1, + 245, 246, -1, 248, 249, 250, -1, -1, 253, -1, + -1, -1, 257, 258, 259, 260, 261, 262, 263, 264, + -1, 266, 267, 268, 269, 270, 271, 272, -1, 274, + 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, + 285, -1, 287, 288, 289, 290, 291, 292, 293, 294, + 295, 296, -1, 298, 299, -1, 301, 302, 303, 304, + 305, 306, 307, 308, 309, 310, 311, -1, 313, 314, + 315, 316, 317, -1, 319, 320, 321, 322, -1, 324, + 325, 326, -1, 328, 329, 330, 331, 332, 333, 334, + 335, 336, 337, 338, -1, 340, 341, -1, 343, 344, + 345, 346, 347, 348, -1, 350, 351, -1, -1, 354, + 355, 356, 357, 358, 359, 360, 361, 362, 363, 364, + 365, -1, -1, 368, 369, 370, 371, 372, -1, -1, + 375, 376, 377, 378, 379, 380, 381, -1, 383, -1, + 385, 386, 387, -1, -1, 390, -1, -1, 393, 394, + 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 407, 408, 409, -1, -1, -1, -1, -1, + -1, 3, 417, 418, 419, -1, -1, -1, -1, -1, + -1, 426, 14, 15, 16, 17, 18, 19, 20, 21, + -1, 23, 24, 25, 26, 27, -1, -1, -1, -1, + -1, 33, 34, -1, 36, 37, -1, 39, 40, 41, + 42, 43, -1, 45, 46, -1, 48, 49, 50, 51, + 52, -1, -1, 55, 56, 57, 58, 59, -1, 61, + 62, 63, 64, 65, -1, -1, -1, 69, 70, 71, + 72, -1, 74, 75, -1, 77, 78, 79, 80, 81, + 82, -1, -1, 85, 86, -1, -1, -1, -1, -1, + -1, -1, 94, 95, 96, 97, 98, 99, 100, 101, + 102, -1, 104, -1, 106, 107, 108, 109, 110, -1, + 112, 113, 114, -1, -1, 117, 118, 119, 120, 121, + -1, 123, 124, 125, -1, 127, 128, -1, 130, 131, + 132, 133, 134, 135, 136, 137, 138, -1, 140, -1, + 142, 143, 144, -1, 146, -1, 148, -1, -1, -1, + 152, 153, 154, -1, 156, 157, -1, 159, -1, 161, + 162, 163, 164, 165, -1, 167, 168, 169, -1, 171, + 172, 173, 174, 175, 176, -1, 178, -1, 180, 181, + 182, 183, 184, 185, 186, -1, 188, -1, 190, -1, + -1, 193, -1, 195, 196, 197, 198, 199, 200, 201, + -1, 203, 204, -1, 206, -1, -1, 209, 210, 211, + -1, -1, 214, 215, 216, 217, 218, 219, 220, 221, + 222, 223, 224, 225, 226, -1, 228, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, 243, -1, 245, -1, -1, 248, 249, 250, -1, + -1, 253, -1, -1, -1, 257, 258, 259, 260, 261, + 262, 263, 264, -1, 266, 267, 268, 269, 270, 271, + 272, -1, 274, 275, 276, 277, 278, 279, 280, 281, + 282, 283, 284, 285, -1, 287, 288, 289, 290, 291, + 292, 293, 294, 295, 296, -1, 298, 299, -1, 301, + 302, 303, 304, 305, 306, 307, 308, 309, 310, 311, + 312, 313, 314, 315, 316, 317, -1, 319, 320, 321, + 322, -1, 324, 325, 326, -1, 328, 329, 330, 331, + 332, 333, 334, 335, 336, 337, 338, -1, 340, 341, + 342, 343, 344, 345, 346, 347, 348, -1, 350, 351, + -1, -1, 354, 355, 356, 357, -1, 359, 360, 361, + 362, 363, 364, 365, -1, -1, 368, 369, 370, 371, + 372, -1, -1, 375, 376, 377, 378, 379, 380, 381, + -1, 383, 384, 385, 386, 387, -1, -1, 390, -1, + 392, 393, 394, 395, 396, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 407, 408, 409, -1, -1, + -1, -1, -1, -1, 3, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 426, 14, 15, 16, 17, 18, + 19, 20, 21, -1, 23, 24, 25, -1, -1, -1, + -1, -1, -1, -1, 33, 34, -1, 36, 37, -1, + 39, 40, 41, 42, 43, -1, 45, 46, -1, 48, + 49, 50, 51, 52, -1, -1, 55, 56, 57, 58, + 59, -1, 61, 62, 63, 64, 65, -1, -1, -1, + 69, 70, 71, 72, -1, 74, 75, -1, 77, 78, + 79, 80, 81, 82, -1, -1, 85, 86, -1, -1, + -1, -1, -1, -1, -1, 94, 95, 96, 97, 98, + 99, 100, 101, 102, -1, 104, -1, 106, 107, 108, + 109, 110, -1, 112, 113, 114, -1, -1, 117, 118, + 119, 120, 121, -1, 123, 124, 125, -1, 127, 128, + -1, 130, 131, 132, 133, 134, 135, 136, 137, 138, + -1, 140, -1, 142, 143, 144, -1, 146, -1, 148, + -1, -1, -1, 152, 153, 154, -1, 156, 157, -1, + 159, -1, 161, 162, 163, 164, 165, -1, 167, 168, + 169, -1, 171, 172, 173, 174, 175, 176, -1, 178, + -1, 180, 181, 182, 183, 184, 185, 186, -1, 188, + -1, 190, -1, -1, 193, -1, 195, 196, 197, 198, + 199, 200, 201, -1, 203, 204, -1, 206, -1, -1, + 209, 210, 211, -1, -1, 214, 215, 216, 217, 218, + 219, 220, 221, 222, 223, 224, 225, 226, -1, 228, + 229, 230, 231, -1, 233, 234, -1, 236, -1, 238, + 239, 240, 241, 242, 243, -1, 245, -1, -1, 248, + 249, 250, -1, -1, 253, -1, -1, -1, 257, 258, + 259, 260, 261, 262, 263, 264, -1, 266, 267, 268, + 269, 270, 271, 272, -1, 274, 275, 276, 277, 278, + 279, 280, 281, 282, 283, 284, 285, -1, 287, 288, + 289, 290, 291, 292, 293, 294, 295, 296, -1, 298, + 299, -1, 301, 302, 303, 304, 305, 306, 307, 308, + 309, 310, 311, 312, 313, 314, 315, 316, 317, -1, + 319, 320, 321, 322, -1, 324, 325, 326, -1, 328, + 329, 330, 331, 332, 333, 334, 335, 336, 337, 338, + -1, 340, 341, 342, 343, 344, 345, 346, 347, 348, + -1, 350, 351, -1, -1, 354, 355, 356, 357, -1, + 359, 360, 361, 362, 363, 364, 365, -1, -1, 368, + 369, 370, 371, 372, -1, -1, 375, 376, 377, 378, + 379, 380, 381, -1, 383, -1, 385, 386, 387, -1, + -1, 390, -1, 392, 393, 394, 395, 396, 397, 398, + 399, 400, 401, 402, 403, 404, 405, 406, 407, 408, + 409, -1, -1, -1, -1, -1, -1, 3, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 426, 14, 15, + 16, 17, 18, 19, 20, 21, -1, 23, 24, 25, + -1, -1, -1, -1, -1, -1, -1, 33, 34, -1, + 36, 37, -1, 39, 40, 41, 42, 43, -1, 45, + 46, -1, 48, 49, 50, 51, 52, -1, -1, 55, + 56, 57, 58, 59, -1, 61, 62, 63, 64, 65, + -1, -1, -1, 69, 70, 71, 72, -1, 74, 75, + -1, 77, 78, 79, 80, 81, 82, -1, -1, 85, + 86, -1, -1, -1, -1, -1, -1, -1, 94, 95, + 96, 97, 98, 99, 100, 101, 102, -1, 104, -1, + 106, 107, 108, 109, 110, -1, 112, 113, 114, -1, + -1, 117, 118, 119, 120, 121, -1, 123, 124, 125, + -1, 127, 128, -1, 130, 131, 132, 133, 134, 135, + 136, 137, 138, -1, 140, -1, 142, 143, 144, -1, + 146, -1, 148, -1, -1, -1, 152, 153, 154, -1, + 156, 157, -1, 159, -1, 161, 162, 163, 164, 165, + -1, 167, 168, 169, -1, 171, 172, 173, 174, 175, + 176, -1, 178, -1, 180, 181, 182, 183, 184, 185, + 186, -1, 188, -1, 190, -1, -1, 193, -1, 195, + 196, 197, 198, 199, 200, 201, -1, 203, 204, -1, + 206, -1, -1, 209, 210, 211, -1, -1, 214, 215, + 216, 217, 218, 219, 220, 221, 222, 223, 224, 225, + 226, -1, 228, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, 243, -1, 245, + -1, -1, 248, 249, 250, -1, -1, 253, -1, -1, + -1, 257, 258, 259, 260, 261, 262, 263, 264, -1, + 266, 267, 268, 269, 270, 271, 272, -1, 274, 275, + 276, 277, 278, 279, 280, 281, 282, 283, 284, 285, + -1, 287, 288, 289, 290, 291, 292, 293, 294, 295, + 296, -1, 298, 299, -1, 301, 302, 303, 304, 305, + 306, 307, 308, 309, 310, 311, -1, 313, 314, 315, + 316, 317, -1, 319, 320, 321, 322, -1, 324, 325, + 326, -1, 328, 329, 330, 331, 332, 333, 334, 335, + 336, 337, 338, -1, 340, 341, -1, 343, 344, 345, + 346, 347, 348, -1, 350, 351, -1, -1, 354, 355, + 356, 357, -1, 359, 360, 361, 362, 363, 364, 365, + -1, -1, 368, 369, 370, 371, 372, -1, -1, 375, + 376, 377, 378, 379, 380, 381, -1, 383, -1, 385, + 386, 387, -1, -1, 390, -1, -1, 393, 394, 395, + 396, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 407, 408, 409, -1, -1, -1, -1, -1, -1, + 3, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 426, 14, 15, 16, 17, 18, 19, 20, 21, -1, + 23, 24, 25, -1, -1, -1, -1, -1, -1, -1, + 33, 34, -1, 36, 37, -1, 39, 40, 41, 42, + 43, -1, 45, 46, -1, 48, 49, 50, 51, 52, + -1, -1, 55, 56, 57, 58, 59, -1, 61, 62, + 63, 64, 65, -1, -1, -1, 69, 70, 71, 72, + -1, 74, 75, -1, 77, 78, 79, 80, 81, 82, + -1, -1, 85, 86, -1, -1, -1, -1, -1, -1, + -1, 94, 95, 96, 97, 98, 99, 100, 101, 102, + -1, 104, -1, 106, 107, 108, 109, 110, -1, 112, + 113, 114, -1, -1, 117, 118, 119, 120, 121, -1, + 123, 124, 125, -1, 127, 128, -1, 130, 131, 132, + 133, 134, 135, 136, 137, 138, -1, 140, -1, 142, + 143, 144, -1, 146, -1, 148, -1, -1, -1, 152, + 153, 154, -1, 156, 157, -1, 159, -1, 161, 162, + 163, 164, 165, -1, 167, 168, 169, -1, 171, 172, + 173, 174, 175, 176, -1, 178, -1, 180, 181, 182, + 183, 184, 185, 186, -1, 188, -1, 190, -1, -1, + 193, -1, 195, 196, 197, 198, 199, 200, 201, -1, + 203, 204, -1, 206, -1, -1, 209, 210, 211, -1, + -1, 214, 215, 216, 217, 218, 219, 220, 221, 222, + 223, 224, 225, 226, -1, 228, 229, 230, 231, -1, + 233, 234, -1, 236, -1, 238, 239, 240, 241, 242, + 243, -1, 245, -1, -1, 248, 249, 250, -1, -1, + 253, -1, -1, -1, 257, 258, 259, 260, 261, 262, + 263, 264, -1, 266, 267, 268, 269, 270, 271, 272, + -1, 274, 275, 276, 277, 278, 279, 280, 281, 282, + 283, 284, 285, -1, 287, 288, 289, 290, 291, 292, + 293, 294, 295, 296, -1, 298, 299, -1, 301, 302, + 303, 304, 305, 306, 307, 308, 309, 310, 311, -1, + 313, 314, 315, 316, 317, -1, 319, 320, 321, 322, + -1, 324, 325, 326, -1, 328, 329, 330, 331, 332, + 333, 334, 335, 336, 337, 338, -1, 340, 341, -1, + 343, 344, 345, 346, 347, 348, -1, 350, 351, -1, + -1, 354, 355, 356, 357, -1, 359, 360, 361, 362, + 363, 364, 365, -1, -1, 368, 369, 370, 371, 372, + -1, -1, 375, 376, 377, 378, 379, 380, 381, -1, + 383, -1, 385, 386, 387, -1, -1, 390, -1, -1, + 393, 394, 395, 396, 397, 398, 399, 400, 401, 402, + 403, 404, 405, 406, 407, 408, 409, -1, -1, -1, + -1, -1, -1, 3, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 426, 14, 15, 16, 17, 18, 19, + 20, 21, -1, 23, 24, 25, -1, -1, -1, -1, + -1, -1, -1, 33, 34, -1, 36, 37, -1, 39, + 40, 41, 42, 43, -1, 45, 46, -1, 48, 49, + 50, 51, 52, -1, -1, 55, 56, 57, 58, 59, + -1, 61, 62, 63, 64, 65, -1, -1, -1, 69, + 70, 71, 72, -1, 74, 75, -1, 77, 78, 79, + 80, 81, 82, -1, -1, 85, 86, -1, -1, -1, + -1, -1, -1, -1, 94, 95, 96, 97, 98, 99, + 100, 101, 102, -1, 104, -1, 106, 107, 108, 109, + 110, -1, 112, 113, 114, -1, -1, 117, 118, 119, + 120, 121, -1, 123, 124, 125, -1, 127, 128, -1, + 130, 131, 132, 133, 134, 135, 136, 137, 138, -1, + 140, -1, 142, 143, 144, -1, 146, -1, 148, -1, + -1, -1, 152, 153, 154, -1, 156, 157, -1, 159, + -1, 161, 162, 163, 164, 165, -1, 167, 168, 169, + -1, 171, 172, 173, 174, 175, 176, -1, 178, -1, + 180, 181, 182, 183, 184, 185, 186, -1, 188, -1, + 190, -1, -1, 193, -1, 195, 196, 197, 198, 199, + 200, 201, -1, 203, 204, -1, 206, -1, -1, 209, + 210, 211, -1, -1, 214, 215, 216, 217, 218, 219, + 220, 221, 222, 223, 224, 225, 226, -1, 228, 229, + 230, 231, -1, 233, 234, -1, 236, -1, 238, 239, + 240, 241, 242, 243, -1, 245, -1, -1, 248, 249, + 250, -1, -1, 253, -1, -1, -1, 257, 258, 259, + 260, 261, 262, 263, 264, -1, 266, 267, 268, 269, + 270, 271, 272, -1, 274, 275, 276, 277, 278, 279, + 280, 281, 282, 283, 284, 285, -1, 287, 288, 289, + 290, 291, 292, 293, 294, 295, 296, -1, 298, 299, + -1, 301, 302, 303, 304, 305, 306, 307, 308, 309, + 310, 311, -1, 313, 314, 315, 316, 317, -1, 319, + 320, 321, 322, -1, 324, 325, 326, -1, 328, 329, + 330, 331, 332, 333, 334, 335, 336, 337, 338, -1, + 340, 341, -1, 343, 344, 345, 346, 347, 348, -1, + 350, 351, -1, -1, 354, 355, 356, 357, -1, 359, + 360, 361, 362, 363, 364, 365, -1, -1, 368, 369, + 370, 371, 372, -1, -1, 375, 376, 377, 378, 379, + 380, 381, -1, 383, -1, 385, 386, 387, -1, -1, + 390, -1, -1, 393, 394, 395, 396, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 407, 408, 409, + -1, -1, -1, -1, -1, -1, 3, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 426, 14, 15, 16, + 17, 18, 19, 20, 21, -1, 23, 24, 25, -1, + -1, -1, -1, -1, -1, -1, 33, 34, -1, 36, + 37, -1, 39, 40, 41, 42, 43, -1, 45, 46, + -1, 48, 49, 50, 51, 52, -1, -1, 55, 56, + 57, 58, 59, -1, 61, 62, 63, 64, 65, -1, + -1, -1, 69, 70, 71, 72, -1, 74, 75, -1, + 77, 78, 79, 80, 81, 82, -1, -1, 85, 86, + -1, -1, -1, -1, -1, -1, -1, 94, 95, 96, + 97, 98, 99, 100, 101, 102, -1, 104, -1, 106, + 107, 108, 109, 110, -1, 112, 113, 114, -1, -1, + 117, 118, 119, 120, 121, -1, 123, 124, 125, -1, + 127, 128, -1, 130, 131, 132, 133, 134, 135, 136, + 137, 138, -1, 140, -1, 142, 143, 144, -1, 146, + -1, 148, -1, -1, -1, 152, 153, 154, -1, 156, + 157, -1, 159, -1, 161, 162, 163, 164, 165, -1, + 167, 168, 169, -1, 171, 172, 173, 174, 175, 176, + -1, 178, -1, 180, 181, 182, 183, 184, 185, 186, + -1, 188, -1, 190, -1, -1, 193, -1, 195, 196, + 197, 198, 199, 200, 201, -1, 203, 204, -1, 206, + -1, -1, 209, 210, 211, -1, -1, 214, 215, 216, + 217, 218, 219, 220, 221, 222, 223, 224, 225, 226, + -1, 228, 229, 230, 231, -1, 233, 234, -1, 236, + -1, 238, 239, 240, 241, 242, 243, -1, 245, -1, + -1, 248, 249, 250, -1, -1, 253, -1, -1, -1, + 257, 258, 259, 260, 261, 262, 263, 264, -1, 266, + 267, 268, 269, 270, 271, 272, -1, 274, 275, 276, + 277, 278, 279, 280, 281, 282, 283, 284, 285, -1, + 287, 288, 289, 290, 291, 292, 293, 294, 295, 296, + -1, 298, 299, -1, 301, 302, 303, 304, 305, 306, + 307, 308, 309, 310, 311, -1, 313, 314, 315, 316, + 317, -1, 319, 320, 321, 322, -1, 324, 325, 326, + -1, 328, 329, 330, 331, 332, 333, 334, 335, 336, + 337, 338, -1, 340, 341, -1, 343, 344, 345, 346, + 347, 348, -1, 350, 351, -1, -1, 354, 355, 356, + 357, -1, 359, 360, 361, 362, 363, 364, 365, -1, + -1, 368, 369, 370, 371, 372, -1, -1, 375, 376, + 377, 378, 379, 380, 381, -1, 383, -1, 385, 386, + 387, -1, -1, 390, -1, -1, 393, 394, 395, 396, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 407, 408, 409, -1, -1, -1, -1, -1, -1, 3, + 4, 5, -1, -1, 8, 9, -1, -1, -1, 426, + 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, -1, 43, + 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, + 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, + 64, -1, 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, 92, 93, + 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, + 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, + 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, + 124, 125, 126, 127, 128, 129, 130, 131, 132, 133, + -1, 135, 136, 137, -1, 139, 140, 141, 142, 143, + 144, 145, 146, 147, 148, 149, 150, 151, 152, 153, + 154, 155, 156, -1, 158, 159, 160, 161, 162, 163, + 164, 165, 166, 167, 168, 169, 170, 171, 172, 173, + 174, 175, 176, 177, 178, 179, -1, 181, 182, 183, + 184, 185, 186, 187, 188, 189, 190, 191, 192, 193, + 194, 195, 196, 197, 198, 199, 200, 201, 202, 203, + -1, 205, 206, 207, 208, 209, 210, 211, 212, 213, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, 227, 228, 229, 230, -1, 232, 233, + 234, 235, 236, 237, -1, 239, 240, 241, 242, 243, + 244, 245, 246, 247, 248, 249, 250, 251, 252, -1, + 254, 255, 256, -1, 258, 259, 260, 261, 262, 263, + 264, 265, 266, -1, 268, -1, 270, 271, 272, 273, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, 286, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, 297, 298, 299, 300, 301, 302, -1, + 304, 305, 306, 307, 308, 309, 310, 311, 312, 313, + 314, 315, 316, 317, 318, 319, 320, 321, 322, 323, + 324, 325, 326, 327, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, -1, 339, 340, 341, 342, 343, + 344, 345, 346, 347, 348, 349, 350, 351, 352, 353, + 354, -1, 356, -1, 358, 359, 360, 361, 362, 363, + 364, 365, 366, 367, 368, 369, 370, 371, 372, 373, + 374, 375, 376, 377, 378, 379, -1, 381, 382, 383, + 384, 385, 386, 387, 388, 389, 390, 391, 392, 393, + 394, 395, 396, 397, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 407, 408, 409, -1, -1, -1, 413, + 414, 415, -1, 417, 418, 419, 420, 421, 422, 3, + -1, -1, -1, -1, 8, -1, -1, -1, -1, -1, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, -1, -1, -1, 33, + 34, -1, 36, 37, -1, 39, 40, 41, 42, 43, + -1, 45, 46, -1, 48, 49, 50, 51, 52, -1, + -1, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, 65, -1, -1, -1, 69, 70, 71, 72, -1, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + -1, 85, 86, -1, -1, -1, -1, -1, -1, -1, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + 134, 135, 136, 137, 138, -1, 140, -1, 142, 143, + 144, -1, 146, -1, 148, -1, -1, -1, 152, 153, + 154, -1, 156, 157, -1, 159, -1, 161, 162, 163, + 164, 165, -1, 167, 168, 169, -1, 171, 172, 173, + 174, 175, 176, -1, 178, -1, 180, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, -1, -1, 193, + -1, 195, 196, 197, 198, 199, 200, 201, -1, 203, + 204, -1, 206, -1, -1, 209, 210, 211, -1, -1, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, -1, 228, 229, 230, 231, -1, 233, + 234, -1, 236, -1, 238, 239, 240, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, 253, + -1, -1, -1, 257, 258, 259, 260, 261, 262, 263, + 264, -1, 266, 267, 268, 269, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, -1, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, -1, 313, + 314, 315, 316, 317, -1, 319, 320, 321, 322, -1, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, 338, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, 355, 356, 357, -1, 359, 360, 361, 362, 363, + 364, 365, -1, -1, 368, 369, 370, 371, 372, -1, + -1, 375, 376, 377, 378, 379, 380, 381, -1, 383, + -1, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 407, 408, 409, -1, -1, -1, 413, + 414, 415, -1, 417, 418, 419, 420, 421, 422, 3, + -1, -1, -1, -1, 8, -1, -1, -1, -1, -1, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, -1, -1, -1, 33, + 34, -1, 36, 37, -1, 39, 40, 41, 42, 43, + -1, 45, 46, -1, 48, 49, 50, 51, 52, -1, + -1, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, 65, -1, -1, -1, 69, 70, 71, 72, -1, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + -1, 85, 86, -1, -1, -1, -1, -1, -1, -1, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + 134, 135, 136, 137, 138, -1, 140, -1, 142, 143, + 144, -1, 146, -1, 148, -1, -1, -1, 152, 153, + 154, -1, 156, 157, -1, 159, -1, 161, 162, 163, + 164, 165, -1, 167, 168, 169, -1, 171, 172, 173, + 174, 175, 176, -1, 178, -1, 180, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, -1, -1, 193, + -1, 195, 196, 197, 198, 199, 200, 201, -1, 203, + 204, -1, 206, -1, -1, 209, 210, 211, -1, -1, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, -1, 228, 229, 230, 231, -1, 233, + 234, -1, 236, -1, 238, 239, 240, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, 253, + -1, -1, -1, 257, 258, 259, 260, 261, 262, 263, + 264, -1, 266, 267, 268, 269, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, -1, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, -1, 313, + 314, 315, 316, 317, -1, 319, 320, 321, 322, -1, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, 338, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, 355, 356, 357, -1, 359, 360, 361, 362, 363, + 364, 365, -1, -1, 368, 369, 370, 371, 372, -1, + -1, 375, 376, 377, 378, 379, 380, 381, -1, 383, + -1, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 407, 408, 409, -1, -1, -1, 413, + 414, 415, -1, 417, 418, 419, 420, 421, 422, 3, + -1, -1, -1, -1, 8, -1, -1, -1, -1, -1, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, -1, -1, -1, 33, + 34, -1, 36, 37, -1, 39, 40, 41, 42, 43, + -1, 45, 46, -1, 48, 49, 50, 51, 52, -1, + -1, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, 65, -1, -1, -1, 69, 70, 71, 72, -1, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + -1, 85, 86, -1, -1, -1, -1, -1, -1, -1, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + 134, 135, 136, 137, 138, -1, 140, -1, 142, 143, + 144, -1, 146, -1, 148, -1, -1, -1, 152, 153, + 154, -1, 156, 157, -1, 159, -1, 161, 162, 163, + 164, 165, -1, 167, 168, 169, -1, 171, 172, 173, + 174, 175, 176, -1, 178, -1, 180, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, -1, -1, 193, + -1, 195, 196, 197, 198, 199, 200, 201, -1, 203, + 204, -1, 206, -1, -1, 209, 210, 211, -1, -1, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, -1, 228, 229, 230, 231, -1, 233, + 234, -1, 236, -1, 238, 239, 240, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, 253, + -1, -1, -1, 257, 258, 259, 260, 261, 262, 263, + 264, -1, 266, 267, 268, 269, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, -1, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, -1, 313, + 314, 315, 316, 317, -1, 319, 320, 321, 322, -1, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, 338, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, 355, 356, 357, -1, 359, 360, 361, 362, 363, + 364, 365, -1, -1, 368, 369, 370, 371, 372, -1, + -1, 375, 376, 377, 378, 379, 380, 381, -1, 383, + -1, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 407, 408, 409, -1, -1, -1, 413, + 414, 415, -1, 417, 418, 419, 420, 421, 422, 3, + -1, -1, -1, -1, 8, -1, -1, -1, -1, -1, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, -1, -1, -1, 33, + 34, -1, 36, 37, -1, 39, 40, 41, 42, 43, + -1, 45, 46, -1, 48, 49, 50, 51, 52, -1, + -1, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, 65, -1, -1, -1, 69, 70, 71, 72, -1, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + -1, 85, 86, -1, -1, -1, -1, -1, -1, -1, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + 134, 135, 136, 137, 138, -1, 140, -1, 142, 143, + 144, -1, 146, -1, 148, -1, -1, -1, 152, 153, + 154, -1, 156, 157, -1, 159, -1, 161, 162, 163, + 164, 165, -1, 167, 168, 169, -1, 171, 172, 173, + 174, 175, 176, -1, 178, -1, 180, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, -1, -1, 193, + -1, 195, 196, 197, 198, 199, 200, 201, -1, 203, + 204, -1, 206, -1, -1, 209, 210, 211, -1, -1, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, -1, 228, 229, 230, 231, -1, 233, + 234, -1, 236, -1, 238, 239, 240, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, 253, + -1, -1, -1, 257, 258, 259, 260, 261, 262, 263, + 264, -1, 266, 267, 268, 269, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, -1, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, -1, 313, + 314, 315, 316, 317, -1, 319, 320, 321, 322, -1, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, 338, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, 355, 356, 357, -1, 359, 360, 361, 362, 363, + 364, 365, -1, -1, 368, 369, 370, 371, 372, -1, + -1, 375, 376, 377, 378, 379, 380, 381, -1, 383, + -1, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 407, 408, 409, -1, -1, -1, 413, + 414, 415, -1, 417, 418, 419, 420, 421, 422, 3, + -1, -1, -1, -1, 8, -1, -1, -1, -1, -1, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, -1, -1, -1, 33, + 34, -1, 36, 37, -1, 39, 40, 41, 42, 43, + -1, 45, 46, -1, 48, 49, 50, 51, 52, -1, + -1, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, 65, -1, -1, -1, 69, 70, 71, 72, -1, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + -1, 85, 86, -1, -1, -1, -1, -1, -1, -1, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + 134, 135, 136, 137, 138, -1, 140, -1, 142, 143, + 144, -1, 146, -1, 148, -1, -1, -1, 152, 153, + 154, -1, 156, 157, -1, 159, -1, 161, 162, 163, + 164, 165, -1, 167, 168, 169, -1, 171, 172, 173, + 174, 175, 176, -1, 178, -1, 180, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, -1, -1, 193, + -1, 195, 196, 197, 198, 199, 200, 201, -1, 203, + 204, -1, 206, -1, -1, 209, 210, 211, -1, -1, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, -1, 228, 229, 230, 231, -1, 233, + 234, -1, 236, -1, 238, 239, 240, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, 253, + -1, -1, -1, 257, 258, 259, 260, 261, 262, 263, + 264, -1, 266, 267, 268, 269, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, -1, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, -1, 313, + 314, 315, 316, 317, -1, 319, 320, 321, 322, -1, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, 338, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, 355, 356, 357, -1, 359, 360, 361, 362, 363, + 364, 365, -1, -1, 368, 369, 370, 371, 372, -1, + -1, 375, 376, 377, 378, 379, 380, 381, -1, 383, + -1, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 407, 408, 409, -1, -1, -1, 413, + 414, 415, -1, 417, 418, 419, 420, 421, 422, 3, + -1, -1, -1, -1, 8, -1, -1, -1, -1, -1, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, -1, -1, -1, 33, + 34, -1, 36, 37, -1, 39, 40, 41, 42, 43, + -1, 45, 46, -1, 48, 49, 50, 51, 52, -1, + -1, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, 65, -1, -1, -1, 69, 70, 71, 72, -1, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + -1, 85, 86, -1, -1, -1, -1, -1, -1, -1, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + 134, 135, 136, 137, 138, -1, 140, -1, 142, 143, + 144, -1, 146, -1, 148, -1, -1, -1, 152, 153, + 154, -1, 156, 157, -1, 159, -1, 161, 162, 163, + 164, 165, -1, 167, 168, 169, -1, 171, 172, 173, + 174, 175, 176, -1, 178, -1, 180, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, -1, -1, 193, + -1, 195, 196, 197, 198, 199, 200, 201, -1, 203, + 204, -1, 206, -1, -1, 209, 210, 211, -1, -1, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, -1, 228, 229, 230, 231, -1, 233, + 234, -1, 236, -1, 238, 239, 240, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, 253, + -1, -1, -1, 257, 258, 259, 260, 261, 262, 263, + 264, -1, 266, 267, 268, 269, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, -1, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, -1, 313, + 314, 315, 316, 317, -1, 319, 320, 321, 322, -1, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, 338, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, 355, 356, 357, -1, 359, 360, 361, 362, 363, + 364, 365, -1, -1, 368, 369, 370, 371, 372, -1, + -1, 375, 376, 377, 378, 379, 380, 381, -1, 383, + -1, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 407, 408, 409, -1, -1, -1, 413, + 414, 415, -1, 417, 418, 419, 420, 421, 422, 3, + -1, -1, -1, -1, 8, -1, -1, -1, -1, -1, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, -1, -1, -1, 33, + 34, -1, 36, 37, -1, 39, 40, 41, 42, 43, + -1, 45, 46, -1, 48, 49, 50, 51, 52, -1, + -1, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, 65, -1, -1, -1, 69, 70, 71, 72, -1, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + -1, 85, 86, -1, -1, -1, -1, -1, -1, -1, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + 134, 135, 136, 137, 138, -1, 140, -1, 142, 143, + 144, -1, 146, -1, 148, -1, -1, -1, 152, 153, + 154, -1, 156, 157, -1, 159, -1, 161, 162, 163, + 164, 165, -1, 167, 168, 169, -1, 171, 172, 173, + 174, 175, 176, -1, 178, -1, 180, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, -1, -1, 193, + -1, 195, 196, 197, 198, 199, 200, 201, -1, 203, + 204, -1, 206, -1, -1, 209, 210, 211, -1, -1, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, -1, 228, 229, 230, 231, -1, 233, + 234, -1, 236, -1, 238, 239, 240, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, 253, + -1, -1, -1, 257, 258, 259, 260, 261, 262, 263, + 264, -1, 266, 267, 268, 269, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, -1, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, -1, 313, + 314, 315, 316, 317, -1, 319, 320, 321, 322, -1, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, 338, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, 355, 356, 357, -1, 359, 360, 361, 362, 363, + 364, 365, -1, -1, 368, 369, 370, 371, 372, -1, + -1, 375, 376, 377, 378, 379, 380, 381, -1, 383, + -1, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 407, 408, 409, -1, -1, 3, 413, + 414, 415, -1, 417, 418, 419, 420, 421, 422, 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, 92, 93, 94, + 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, + 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, + 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, + 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, + 135, 136, 137, 138, 139, 140, 141, 142, 143, 144, + 145, 146, 147, 148, 149, 150, 151, 152, 153, 154, + 155, 156, 157, 158, 159, 160, 161, 162, 163, 164, + 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, + 175, 176, 177, 178, 179, 180, 181, 182, 183, 184, + 185, 186, 187, 188, 189, 190, 191, 192, 193, 194, + 195, 196, 197, 198, 199, 200, 201, 202, 203, 204, + 205, 206, 207, 208, 209, 210, 211, 212, 213, 214, + 215, 216, 217, 218, 219, 220, 221, 222, 223, 224, + 225, 226, 227, 228, 229, 230, 231, 232, 233, 234, + 235, 236, 237, 238, 239, 240, 241, 242, 243, 244, + 245, 246, 247, 248, 249, 250, 251, 252, 253, 254, + 255, 256, 257, 258, 259, 260, 261, 262, 263, 264, + 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, + 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, + 285, 286, 287, 288, 289, 290, 291, 292, 293, 294, + 295, 296, 297, 298, 299, 300, 301, 302, 303, 304, + 305, 306, 307, 308, 309, 310, 311, 312, 313, 314, + 315, 316, 317, 318, 319, 320, 321, 322, 323, 324, + 325, 326, 327, 328, 329, 330, 331, 332, 333, 334, + 335, 336, 337, 338, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 351, 352, 353, 354, + 355, 356, 357, 358, 359, 360, 361, 362, 363, 364, + 365, 366, 367, 368, 369, 370, 371, 372, 373, 374, + 375, 376, 377, 378, 379, 380, 381, 382, 383, 384, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 407, 408, 409, 3, -1, -1, -1, -1, + -1, -1, -1, -1, 419, -1, 14, 15, 16, 17, + 18, 19, 20, 21, -1, 23, 24, 25, -1, -1, + -1, -1, -1, -1, -1, 33, 34, -1, 36, 37, + -1, 39, 40, 41, 42, 43, -1, 45, 46, -1, + 48, 49, 50, 51, 52, -1, -1, 55, 56, 57, + 58, 59, -1, 61, 62, 63, 64, 65, -1, -1, + -1, 69, 70, 71, 72, -1, 74, 75, -1, 77, + 78, 79, 80, 81, 82, -1, -1, 85, 86, -1, + -1, -1, -1, -1, -1, -1, 94, 95, 96, 97, + 98, 99, 100, 101, 102, -1, 104, -1, 106, 107, + 108, 109, 110, -1, 112, 113, 114, -1, -1, 117, + 118, 119, 120, 121, -1, 123, 124, 125, -1, 127, + 128, -1, 130, 131, 132, 133, 134, 135, 136, 137, + 138, -1, 140, -1, 142, 143, 144, -1, 146, -1, + 148, -1, -1, -1, 152, 153, 154, -1, 156, 157, + -1, 159, -1, 161, 162, 163, 164, 165, -1, 167, + 168, 169, -1, 171, 172, 173, 174, 175, 176, -1, + 178, -1, 180, 181, 182, 183, 184, 185, 186, -1, + 188, -1, 190, -1, -1, 193, -1, 195, 196, 197, + 198, 199, 200, 201, -1, 203, 204, -1, 206, -1, + -1, 209, 210, 211, -1, -1, 214, 215, 216, 217, + 218, 219, 220, 221, 222, 223, 224, 225, 226, -1, + 228, 229, 230, 231, -1, 233, 234, -1, 236, -1, + 238, 239, 240, 241, 242, 243, -1, 245, -1, -1, + 248, 249, 250, -1, -1, 253, -1, -1, -1, 257, + 258, 259, 260, 261, 262, 263, 264, -1, 266, 267, + 268, 269, 270, 271, 272, -1, 274, 275, 276, 277, + 278, 279, 280, 281, 282, 283, 284, 285, -1, 287, + 288, 289, 290, 291, 292, 293, 294, 295, 296, -1, + 298, 299, -1, 301, 302, 303, 304, 305, 306, 307, + 308, 309, 310, 311, -1, 313, 314, 315, 316, 317, + -1, 319, 320, 321, 322, -1, 324, 325, 326, -1, + 328, 329, 330, 331, 332, 333, 334, 335, 336, 337, + 338, -1, 340, 341, -1, 343, 344, 345, 346, 347, + 348, -1, 350, 351, -1, -1, 354, 355, 356, 357, + -1, 359, 360, 361, 362, 363, 364, 365, -1, -1, + 368, 369, 370, 371, 372, -1, -1, 375, 376, 377, + 378, 379, 380, 381, -1, 383, -1, 385, 386, 387, + -1, -1, 390, -1, -1, 393, 394, 395, 396, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, + 408, 409, 3, -1, -1, -1, -1, -1, -1, -1, + -1, 419, -1, 14, 15, 16, 17, 18, 19, 20, + 21, -1, 23, 24, 25, -1, -1, -1, -1, -1, + -1, -1, 33, 34, -1, 36, 37, -1, 39, 40, + 41, 42, 43, -1, 45, 46, -1, 48, 49, 50, + 51, 52, -1, -1, 55, 56, 57, 58, 59, -1, + 61, 62, 63, 64, 65, -1, -1, -1, 69, 70, + 71, 72, -1, 74, 75, -1, 77, 78, 79, 80, + 81, 82, -1, -1, 85, 86, -1, -1, -1, -1, + -1, -1, -1, 94, 95, 96, 97, 98, 99, 100, + 101, 102, -1, 104, -1, 106, 107, 108, 109, 110, + -1, 112, 113, 114, -1, -1, 117, 118, 119, 120, + 121, -1, 123, 124, 125, -1, 127, 128, -1, 130, + 131, 132, 133, 134, 135, 136, 137, 138, -1, 140, + -1, 142, 143, 144, -1, 146, -1, 148, -1, -1, + -1, 152, 153, 154, -1, 156, 157, -1, 159, -1, + 161, 162, 163, 164, 165, -1, 167, 168, 169, -1, + 171, 172, 173, 174, 175, 176, -1, 178, -1, 180, + 181, 182, 183, 184, 185, 186, -1, 188, -1, 190, + -1, -1, 193, -1, 195, 196, 197, 198, 199, 200, + 201, -1, 203, 204, -1, 206, -1, -1, 209, 210, + 211, -1, -1, 214, 215, 216, 217, 218, 219, 220, + 221, 222, 223, 224, 225, 226, -1, 228, 229, 230, + 231, -1, 233, 234, -1, 236, -1, 238, 239, 240, + 241, 242, 243, -1, 245, -1, -1, 248, 249, 250, + -1, -1, 253, -1, -1, -1, 257, 258, 259, 260, + 261, 262, 263, 264, -1, 266, 267, 268, 269, 270, + 271, 272, -1, 274, 275, 276, 277, 278, 279, 280, + 281, 282, 283, 284, 285, -1, 287, 288, 289, 290, + 291, 292, 293, 294, 295, 296, -1, 298, 299, -1, + 301, 302, 303, 304, 305, 306, 307, 308, 309, 310, + 311, -1, 313, 314, 315, 316, 317, -1, 319, 320, + 321, 322, -1, 324, 325, 326, -1, 328, 329, 330, + 331, 332, 333, 334, 335, 336, 337, 338, -1, 340, + 341, -1, 343, 344, 345, 346, 347, 348, -1, 350, + 351, -1, -1, 354, 355, 356, 357, -1, 359, 360, + 361, 362, 363, 364, 365, -1, -1, 368, 369, 370, + 371, 372, -1, -1, 375, 376, 377, 378, 379, 380, + 381, -1, 383, -1, 385, 386, 387, -1, -1, 390, + -1, -1, 393, 394, 395, 396, 397, 398, 399, 400, + 401, 402, 403, 404, 405, 406, 407, 408, 409, 3, + -1, -1, -1, -1, -1, -1, -1, -1, 419, -1, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, -1, -1, -1, 33, + 34, -1, 36, 37, 38, 39, 40, 41, -1, 43, + 44, 45, 46, -1, 48, 49, 50, 51, 52, -1, + -1, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, -1, -1, 67, -1, 69, 70, 71, 72, 73, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + 84, 85, 86, -1, -1, -1, 90, -1, -1, -1, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + -1, 135, 136, 137, -1, -1, 140, -1, 142, 143, + 144, -1, 146, -1, 148, 149, -1, 151, 152, 153, + 154, -1, 156, -1, -1, 159, -1, 161, 162, 163, + 164, 165, 166, 167, 168, 169, -1, 171, 172, 173, + 174, 175, 176, -1, 178, 179, -1, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, 191, 192, 193, + 194, 195, 196, 197, 198, 199, 200, 201, -1, 203, + -1, 205, 206, 207, -1, 209, 210, 211, -1, -1, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, 227, 228, 229, 230, -1, -1, 233, + 234, 235, 236, -1, -1, 239, 240, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, -1, + 254, 255, 256, -1, 258, 259, 260, 261, 262, 263, + 264, -1, 266, -1, 268, -1, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, 300, 301, 302, -1, + 304, 305, 306, 307, 308, 309, 310, 311, -1, 313, + 314, 315, 316, 317, -1, 319, 320, 321, 322, 323, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, -1, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, -1, 356, -1, -1, 359, 360, 361, 362, 363, + 364, 365, -1, -1, 368, 369, 370, 371, 372, -1, + -1, 375, 376, 377, 378, 379, -1, 381, -1, 383, + 384, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, -1, -1, 3, -1, -1, -1, + -1, -1, -1, 407, 408, 409, -1, 14, 15, 16, + 17, 18, 19, 20, 21, 419, 23, 24, 25, -1, + -1, -1, -1, -1, -1, -1, 33, 34, -1, 36, + 37, 38, 39, 40, 41, -1, 43, 44, 45, 46, + -1, 48, 49, 50, 51, 52, -1, -1, 55, 56, + 57, 58, 59, -1, 61, 62, 63, 64, -1, -1, + 67, -1, 69, 70, 71, 72, 73, 74, 75, -1, + 77, 78, 79, 80, 81, 82, -1, 84, 85, 86, + -1, -1, -1, 90, -1, -1, -1, 94, 95, 96, + 97, 98, 99, 100, 101, 102, -1, 104, -1, 106, + 107, 108, 109, 110, -1, 112, 113, 114, -1, -1, + 117, 118, 119, 120, 121, -1, 123, 124, 125, -1, + 127, 128, -1, 130, 131, 132, 133, -1, 135, 136, + 137, -1, -1, 140, -1, 142, 143, 144, -1, 146, + -1, 148, 149, -1, 151, 152, 153, 154, -1, 156, + -1, -1, 159, -1, 161, 162, 163, 164, 165, 166, + 167, 168, 169, -1, 171, 172, 173, 174, 175, 176, + -1, 178, 179, -1, 181, 182, 183, 184, 185, 186, + -1, 188, -1, 190, 191, 192, 193, 194, 195, 196, + 197, 198, 199, 200, 201, -1, 203, -1, 205, 206, + 207, -1, 209, 210, 211, -1, -1, 214, 215, 216, + 217, 218, 219, 220, 221, 222, 223, 224, 225, 226, + 227, 228, 229, 230, -1, -1, 233, 234, 235, 236, + -1, -1, 239, 240, 241, 242, 243, -1, 245, -1, + -1, 248, 249, 250, -1, -1, -1, 254, 255, 256, + -1, 258, 259, 260, 261, 262, 263, 264, -1, 266, + -1, 268, -1, 270, 271, 272, -1, 274, 275, 276, + 277, 278, 279, 280, 281, 282, 283, 284, 285, -1, + 287, 288, 289, 290, 291, 292, 293, 294, 295, 296, + -1, 298, 299, 300, 301, 302, -1, 304, 305, 306, + 307, 308, 309, 310, 311, -1, 313, 314, 315, 316, + 317, -1, 319, 320, 321, 322, 323, 324, 325, 326, + -1, 328, 329, 330, 331, 332, 333, 334, 335, 336, + 337, -1, -1, 340, 341, -1, 343, 344, 345, 346, + 347, 348, -1, 350, 351, -1, -1, 354, -1, 356, + -1, -1, 359, 360, 361, 362, 363, 364, 365, -1, + -1, 368, 369, 370, 371, 372, -1, -1, 375, 376, + 377, 378, 379, -1, 381, -1, 383, 384, 385, 386, + 387, -1, -1, 390, -1, -1, 393, 394, 395, 396, + 397, -1, -1, 3, 4, 5, -1, -1, -1, 9, + 407, 408, 409, -1, 14, 15, 16, 17, 18, 19, + 20, 21, 419, 23, 24, 25, -1, -1, -1, -1, + -1, -1, -1, 33, 34, -1, 36, 37, -1, 39, + 40, 41, 42, 43, -1, 45, 46, -1, 48, 49, + 50, 51, 52, -1, -1, 55, 56, 57, 58, 59, + -1, 61, 62, 63, 64, 65, -1, -1, -1, 69, + 70, 71, 72, -1, 74, 75, -1, 77, 78, 79, + 80, 81, 82, -1, -1, 85, 86, -1, -1, -1, + -1, -1, -1, -1, 94, 95, 96, 97, 98, 99, + 100, 101, 102, 103, 104, -1, 106, 107, 108, 109, + 110, -1, 112, 113, 114, -1, -1, 117, 118, 119, + 120, 121, -1, 123, 124, 125, -1, 127, 128, -1, + 130, 131, 132, 133, 134, 135, 136, 137, 138, 139, + 140, -1, 142, 143, 144, -1, 146, -1, 148, -1, + -1, -1, 152, 153, 154, -1, 156, 157, -1, 159, + -1, 161, 162, 163, 164, 165, -1, 167, 168, 169, + -1, 171, 172, 173, 174, 175, 176, -1, 178, -1, + 180, 181, 182, 183, 184, 185, 186, -1, 188, -1, + 190, -1, -1, 193, -1, 195, 196, 197, 198, 199, + 200, 201, -1, 203, 204, -1, 206, -1, -1, 209, + 210, 211, -1, -1, 214, 215, 216, 217, 218, 219, + 220, 221, 222, 223, 224, 225, 226, -1, 228, 229, + 230, 231, -1, 233, 234, -1, 236, -1, 238, 239, + 240, 241, 242, 243, -1, 245, 246, -1, 248, 249, + 250, -1, -1, 253, -1, -1, -1, 257, 258, 259, + 260, 261, 262, 263, 264, -1, 266, 267, 268, 269, + 270, 271, 272, -1, 274, 275, 276, 277, 278, 279, + 280, 281, 282, 283, 284, 285, -1, 287, 288, 289, + 290, 291, 292, 293, 294, 295, 296, -1, 298, 299, + -1, 301, 302, 303, 304, 305, 306, 307, 308, 309, + 310, 311, -1, 313, 314, 315, 316, 317, -1, 319, + 320, 321, 322, -1, 324, 325, 326, -1, 328, 329, + 330, 331, 332, 333, 334, 335, 336, 337, 338, -1, + 340, 341, -1, 343, 344, 345, 346, 347, 348, -1, + 350, 351, -1, -1, 354, 355, 356, 357, 358, 359, + 360, 361, 362, 363, 364, 365, -1, -1, 368, 369, + 370, 371, 372, -1, -1, 375, 376, 377, 378, 379, + 380, 381, -1, 383, -1, 385, 386, 387, -1, -1, + 390, -1, -1, 393, 394, 395, 396, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 407, 408, 409, + 3, 4, 5, -1, -1, -1, 9, 417, 418, -1, + -1, 14, 15, 16, 17, 18, 19, 20, 21, -1, + 23, 24, 25, -1, -1, -1, -1, -1, -1, -1, + 33, 34, -1, 36, 37, -1, 39, 40, 41, 42, + 43, -1, 45, 46, -1, 48, 49, 50, 51, 52, + -1, -1, 55, 56, 57, 58, 59, -1, 61, 62, + 63, 64, 65, -1, -1, -1, 69, 70, 71, 72, + -1, 74, 75, -1, 77, 78, 79, 80, 81, 82, + -1, -1, 85, 86, -1, -1, -1, -1, -1, -1, + -1, 94, 95, 96, 97, 98, 99, 100, 101, 102, + 103, 104, -1, 106, 107, 108, 109, 110, -1, 112, + 113, 114, -1, -1, 117, 118, 119, 120, 121, -1, + 123, 124, 125, -1, 127, 128, -1, 130, 131, 132, + 133, 134, 135, 136, 137, 138, 139, 140, -1, 142, + 143, 144, -1, 146, -1, 148, -1, -1, -1, 152, + 153, 154, -1, 156, 157, -1, 159, -1, 161, 162, + 163, 164, 165, -1, 167, 168, 169, -1, 171, 172, + 173, 174, 175, 176, -1, 178, -1, 180, 181, 182, + 183, 184, 185, 186, -1, 188, -1, 190, -1, -1, + 193, -1, 195, 196, 197, 198, 199, 200, 201, -1, + 203, 204, -1, 206, -1, -1, 209, 210, 211, -1, + -1, 214, 215, 216, 217, 218, 219, 220, 221, 222, + 223, 224, 225, 226, -1, 228, 229, 230, 231, -1, + 233, 234, -1, 236, -1, 238, 239, 240, 241, 242, + 243, -1, 245, 246, -1, 248, 249, 250, -1, -1, + 253, -1, -1, -1, 257, 258, 259, 260, 261, 262, + 263, 264, -1, 266, 267, 268, 269, 270, 271, 272, + -1, 274, 275, 276, 277, 278, 279, 280, 281, 282, + 283, 284, 285, -1, 287, 288, 289, 290, 291, 292, + 293, 294, 295, 296, -1, 298, 299, -1, 301, 302, + 303, 304, 305, 306, 307, 308, 309, 310, 311, -1, + 313, 314, 315, 316, 317, -1, 319, 320, 321, 322, + -1, 324, 325, 326, -1, 328, 329, 330, 331, 332, + 333, 334, 335, 336, 337, 338, -1, 340, 341, -1, + 343, 344, 345, 346, 347, 348, -1, 350, 351, -1, + -1, 354, 355, 356, 357, 358, 359, 360, 361, 362, + 363, 364, 365, -1, -1, 368, 369, 370, 371, 372, + -1, -1, 375, 376, 377, 378, 379, 380, 381, -1, + 383, -1, 385, 386, 387, -1, -1, 390, -1, -1, + 393, 394, 395, 396, 397, 398, 399, 400, 401, 402, + 403, 404, 405, 406, 407, 408, 409, 3, 4, 5, + -1, -1, -1, 9, 417, 418, -1, -1, 14, 15, + 16, 17, 18, 19, 20, 21, -1, 23, 24, 25, + -1, -1, -1, -1, -1, -1, -1, 33, 34, -1, + 36, 37, -1, 39, 40, 41, 42, 43, -1, 45, + 46, -1, 48, 49, 50, 51, 52, -1, -1, 55, + 56, 57, 58, 59, -1, 61, 62, 63, 64, 65, + -1, -1, -1, 69, 70, 71, 72, -1, 74, 75, + -1, 77, 78, 79, 80, 81, 82, -1, -1, 85, + 86, -1, -1, -1, -1, -1, -1, -1, 94, 95, + 96, 97, 98, 99, 100, 101, 102, -1, 104, -1, + 106, 107, 108, 109, 110, -1, 112, 113, 114, -1, + -1, 117, 118, 119, 120, 121, -1, 123, 124, 125, + -1, 127, 128, -1, 130, 131, 132, 133, 134, 135, + 136, 137, 138, 139, 140, -1, 142, 143, 144, -1, + 146, -1, 148, -1, -1, -1, 152, 153, 154, -1, + 156, 157, -1, 159, -1, 161, 162, 163, 164, 165, + -1, 167, 168, 169, -1, 171, 172, 173, 174, 175, + 176, -1, 178, -1, 180, 181, 182, 183, 184, 185, + 186, -1, 188, -1, 190, -1, -1, 193, -1, 195, + 196, 197, 198, 199, 200, 201, -1, 203, 204, -1, + 206, -1, -1, 209, 210, 211, -1, -1, 214, 215, + 216, 217, 218, 219, 220, 221, 222, 223, 224, 225, + 226, -1, 228, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, 243, -1, 245, + 246, -1, 248, 249, 250, -1, -1, 253, -1, -1, + -1, 257, 258, 259, 260, 261, 262, 263, 264, -1, + 266, 267, 268, 269, 270, 271, 272, -1, 274, 275, + 276, 277, 278, 279, 280, 281, 282, 283, 284, 285, + -1, 287, 288, 289, 290, 291, 292, 293, 294, 295, + 296, -1, 298, 299, -1, 301, 302, 303, 304, 305, + 306, 307, 308, 309, 310, 311, -1, 313, 314, 315, + 316, 317, -1, 319, 320, 321, 322, -1, 324, 325, + 326, -1, 328, 329, 330, 331, 332, 333, 334, 335, + 336, 337, 338, -1, 340, 341, -1, 343, 344, 345, + 346, 347, 348, -1, 350, 351, -1, -1, 354, 355, + 356, 357, 358, 359, 360, 361, 362, 363, 364, 365, + -1, -1, 368, 369, 370, 371, 372, -1, -1, 375, + 376, 377, 378, 379, 380, 381, -1, 383, -1, 385, + 386, 387, -1, -1, 390, -1, -1, 393, 394, 395, + 396, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 407, 408, 409, 3, -1, -1, -1, -1, -1, + 9, 417, 418, -1, -1, 14, 15, 16, 17, 18, + 19, 20, 21, 22, 23, 24, 25, -1, -1, -1, + -1, -1, -1, -1, 33, 34, -1, 36, 37, -1, + 39, 40, 41, 42, 43, -1, 45, 46, -1, 48, + 49, 50, 51, 52, -1, -1, 55, 56, 57, 58, + 59, -1, 61, 62, 63, 64, 65, -1, -1, -1, + 69, 70, 71, 72, -1, 74, 75, -1, 77, 78, + 79, 80, 81, 82, -1, -1, 85, 86, -1, -1, + -1, -1, -1, -1, -1, 94, 95, 96, 97, 98, + 99, 100, 101, 102, -1, 104, -1, 106, 107, 108, + 109, 110, -1, 112, 113, 114, -1, -1, 117, 118, + 119, 120, 121, -1, 123, 124, 125, -1, 127, 128, + -1, 130, 131, 132, 133, 134, 135, 136, 137, 138, + -1, 140, -1, 142, 143, 144, -1, 146, -1, 148, + -1, 150, -1, 152, 153, 154, -1, 156, 157, -1, + 159, -1, 161, 162, 163, 164, 165, -1, 167, 168, + 169, 170, 171, 172, 173, 174, 175, 176, -1, 178, + -1, 180, 181, 182, 183, 184, 185, 186, -1, 188, + -1, 190, -1, -1, 193, -1, 195, 196, 197, 198, + 199, 200, 201, -1, 203, 204, -1, 206, -1, -1, + 209, 210, 211, -1, -1, 214, 215, 216, 217, 218, + 219, 220, 221, 222, 223, 224, 225, 226, -1, 228, + 229, 230, 231, -1, 233, 234, -1, 236, -1, 238, + 239, 240, 241, 242, 243, -1, 245, -1, -1, 248, + 249, 250, -1, -1, 253, -1, -1, -1, 257, 258, + 259, 260, 261, 262, 263, 264, -1, 266, 267, 268, + 269, 270, 271, 272, -1, 274, 275, 276, 277, 278, + 279, 280, 281, 282, 283, 284, 285, -1, 287, 288, + 289, 290, 291, 292, 293, 294, 295, 296, -1, 298, + 299, -1, 301, 302, 303, 304, 305, 306, 307, 308, + 309, 310, 311, -1, 313, 314, 315, 316, 317, -1, + 319, 320, 321, 322, -1, 324, 325, 326, -1, 328, + 329, 330, 331, 332, 333, 334, 335, 336, 337, 338, + -1, 340, 341, -1, 343, 344, 345, 346, 347, 348, + -1, 350, 351, -1, -1, 354, 355, 356, 357, -1, + 359, 360, 361, 362, 363, 364, 365, -1, -1, 368, + 369, 370, 371, 372, -1, -1, 375, 376, 377, 378, + 379, 380, 381, -1, 383, -1, 385, 386, 387, -1, + -1, 390, -1, -1, 393, 394, 395, 396, 397, 398, + 399, 400, 401, 402, 403, 404, 405, 406, 407, 408, + 409, 3, 4, 5, -1, -1, -1, 9, 417, 418, + -1, -1, 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, + 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, + 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, + 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, + 122, 123, 124, 125, 126, 127, 128, 129, 130, 131, + 132, 133, 134, 135, 136, 137, 138, 139, 140, 141, + 142, 143, 144, 145, 146, 147, 148, 149, 150, 151, + 152, 153, 154, 155, 156, 157, 158, 159, 160, 161, + 162, 163, 164, 165, 166, 167, 168, 169, 170, 171, + 172, 173, 174, 175, 176, 177, 178, 179, 180, 181, + 182, 183, 184, 185, 186, 187, 188, 189, 190, 191, + 192, 193, 194, 195, 196, 197, 198, 199, 200, 201, + 202, 203, 204, 205, 206, 207, 208, 209, 210, 211, + 212, 213, 214, 215, 216, 217, 218, 219, 220, 221, + 222, 223, 224, 225, 226, 227, 228, 229, 230, 231, + 232, 233, 234, 235, 236, 237, 238, 239, 240, 241, + 242, 243, 244, 245, 246, 247, 248, 249, 250, 251, + 252, 253, 254, 255, 256, 257, 258, 259, 260, 261, + 262, 263, 264, 265, 266, 267, 268, 269, 270, 271, + 272, 273, 274, 275, 276, 277, 278, 279, 280, 281, + 282, 283, 284, 285, 286, 287, 288, 289, 290, 291, + 292, 293, 294, 295, 296, 297, 298, 299, 300, 301, + 302, 303, 304, 305, 306, 307, 308, 309, 310, 311, + 312, 313, 314, 315, 316, 317, 318, 319, 320, 321, + 322, 323, 324, 325, 326, 327, 328, 329, 330, 331, + 332, 333, 334, 335, 336, 337, 338, 339, 340, 341, + 342, 343, 344, 345, 346, 347, 348, 349, 350, 351, + 352, 353, 354, 355, 356, 357, 358, 359, 360, 361, + 362, 363, 364, 365, 366, 367, 368, 369, 370, 371, + 372, 373, 374, 375, 376, 377, 378, 379, 380, 381, + 382, 383, 384, 385, 386, 387, 388, 389, 390, 391, + 392, 393, 394, 395, 396, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 407, 408, 409, 3, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 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, 92, 93, 94, + 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, + 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, + 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, + 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, + 135, 136, 137, 138, 139, 140, 141, 142, 143, 144, + 145, 146, 147, 148, 149, 150, 151, 152, 153, 154, + 155, 156, 157, 158, 159, 160, 161, 162, 163, 164, + 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, + 175, 176, 177, 178, 179, 180, 181, 182, 183, 184, + 185, 186, 187, 188, 189, 190, 191, 192, 193, 194, + 195, 196, 197, 198, 199, 200, 201, 202, 203, 204, + 205, 206, 207, 208, 209, 210, 211, 212, 213, 214, + 215, 216, 217, 218, 219, 220, 221, 222, 223, 224, + 225, 226, 227, 228, 229, 230, 231, 232, 233, 234, + 235, 236, 237, 238, 239, 240, 241, 242, 243, 244, + 245, 246, 247, 248, 249, 250, 251, 252, 253, 254, + 255, 256, 257, 258, 259, 260, 261, 262, 263, 264, + 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, + 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, + 285, 286, 287, 288, 289, 290, 291, 292, 293, 294, + 295, 296, 297, 298, 299, 300, 301, 302, 303, 304, + 305, 306, 307, 308, 309, 310, 311, 312, 313, 314, + 315, 316, 317, 318, 319, 320, 321, 322, 323, 324, + 325, 326, 327, 328, 329, 330, 331, 332, 333, 334, + 335, 336, 337, 338, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 351, 352, 353, 354, + 355, 356, 357, 358, 359, 360, 361, 362, 363, 364, + 365, 366, 367, 368, 369, 370, 371, 372, 373, 374, + 375, 376, 377, 378, 379, 380, 381, 382, 383, 384, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 407, 408, 409, 3, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 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, 92, 93, 94, 95, 96, 97, + 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, + 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, + 118, 119, 120, 121, 122, 123, 124, 125, 126, 127, + 128, 129, 130, 131, 132, 133, 134, 135, 136, 137, + 138, 139, 140, 141, 142, 143, 144, 145, 146, 147, + 148, 149, 150, 151, 152, 153, 154, 155, 156, 157, + 158, 159, 160, 161, 162, 163, 164, 165, 166, 167, + 168, 169, 170, 171, 172, 173, 174, 175, 176, 177, + 178, 179, 180, 181, 182, 183, 184, 185, 186, 187, + 188, 189, 190, 191, 192, 193, 194, 195, 196, 197, + 198, 199, 200, 201, 202, 203, 204, 205, 206, 207, + 208, 209, 210, 211, 212, 213, 214, 215, 216, 217, + 218, 219, 220, 221, 222, 223, 224, 225, 226, 227, + 228, 229, 230, 231, 232, 233, 234, 235, 236, 237, + 238, 239, 240, 241, 242, 243, 244, 245, 246, 247, + 248, 249, 250, 251, 252, 253, 254, 255, 256, 257, + 258, 259, 260, 261, 262, 263, 264, 265, 266, 267, + 268, 269, 270, 271, 272, 273, 274, 275, 276, 277, + 278, 279, 280, 281, 282, 283, 284, 285, 286, 287, + 288, 289, 290, 291, 292, 293, 294, 295, 296, 297, + 298, 299, 300, 301, 302, 303, 304, 305, 306, 307, + 308, 309, 310, 311, 312, 313, 314, 315, 316, 317, + 318, 319, 320, 321, 322, 323, 324, 325, 326, 327, + 328, 329, 330, 331, 332, 333, 334, 335, 336, 337, + 338, 339, 340, 341, 342, 343, 344, 345, 346, 347, + 348, 349, 350, 351, 352, 353, 354, 355, 356, 357, + 358, 359, 360, 361, 362, 363, 364, 365, 366, 367, + 368, 369, 370, 371, 372, 373, 374, 375, 376, 377, + 378, 379, 380, 381, 382, 383, 384, 385, 386, 387, + 388, 389, 390, 391, 392, 393, 394, 395, 396, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, + 408, 409, 3, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 14, 15, 16, 17, 18, 19, 20, + 21, -1, 23, 24, 25, -1, -1, -1, -1, -1, + -1, -1, 33, 34, -1, 36, 37, 38, 39, 40, + 41, 42, 43, 44, 45, 46, -1, 48, 49, 50, + 51, 52, -1, -1, 55, 56, 57, 58, 59, -1, + 61, 62, 63, 64, 65, -1, 67, -1, 69, 70, + 71, 72, 73, 74, 75, -1, 77, 78, 79, 80, + 81, 82, -1, 84, 85, 86, -1, -1, -1, 90, + -1, -1, -1, 94, 95, 96, 97, 98, 99, 100, + 101, 102, -1, 104, -1, 106, 107, 108, 109, 110, + -1, 112, 113, 114, -1, -1, 117, 118, 119, 120, + 121, -1, 123, 124, 125, -1, 127, 128, -1, 130, + 131, 132, 133, 134, 135, 136, 137, 138, -1, 140, + -1, 142, 143, 144, -1, 146, -1, 148, 149, -1, + 151, 152, 153, 154, -1, 156, 157, -1, 159, -1, + 161, 162, 163, 164, 165, 166, 167, 168, 169, -1, + 171, 172, 173, 174, 175, 176, -1, 178, 179, 180, + 181, 182, 183, 184, 185, 186, -1, 188, -1, 190, + 191, 192, 193, 194, 195, 196, 197, 198, 199, 200, + 201, -1, 203, 204, 205, 206, 207, -1, 209, 210, + 211, -1, -1, 214, 215, 216, 217, 218, 219, 220, + 221, 222, 223, 224, 225, 226, 227, 228, 229, 230, + 231, -1, 233, 234, 235, 236, -1, 238, 239, 240, + 241, 242, 243, -1, 245, -1, -1, 248, 249, 250, + -1, -1, 253, 254, 255, 256, 257, 258, 259, 260, + 261, 262, 263, 264, -1, 266, 267, 268, 269, 270, + 271, 272, -1, 274, 275, 276, 277, 278, 279, 280, + 281, 282, 283, 284, 285, -1, 287, 288, 289, 290, + 291, 292, 293, 294, 295, 296, -1, 298, 299, 300, + 301, 302, 303, 304, 305, 306, 307, 308, 309, 310, + 311, -1, 313, 314, 315, 316, 317, -1, 319, 320, + 321, 322, 323, 324, 325, 326, -1, 328, 329, 330, + 331, 332, 333, 334, 335, 336, 337, 338, -1, 340, + 341, -1, 343, 344, 345, 346, 347, 348, -1, 350, + 351, -1, -1, 354, 355, 356, 357, -1, 359, 360, + 361, 362, 363, 364, 365, -1, -1, 368, 369, 370, + 371, 372, -1, -1, 375, 376, 377, 378, 379, 380, + 381, -1, 383, 384, 385, 386, 387, -1, -1, 390, + -1, -1, 393, 394, 395, 396, 397, 398, 399, 400, + 401, 402, 403, 404, 405, 406, 407, 408, 409, 3, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, -1, -1, -1, 33, + 34, -1, 36, 37, 38, 39, 40, 41, 42, 43, + 44, 45, 46, -1, 48, 49, 50, 51, 52, -1, + -1, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, 65, -1, 67, -1, 69, 70, 71, 72, 73, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + 84, 85, 86, -1, -1, -1, 90, -1, -1, -1, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + 134, 135, 136, 137, 138, -1, 140, -1, 142, 143, + 144, -1, 146, -1, 148, 149, -1, 151, 152, 153, + 154, -1, 156, 157, -1, 159, -1, 161, 162, 163, + 164, 165, 166, 167, 168, 169, -1, 171, 172, 173, + 174, 175, 176, -1, 178, 179, 180, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, 191, 192, 193, + 194, 195, 196, 197, 198, 199, 200, 201, -1, 203, + 204, 205, 206, 207, -1, 209, 210, 211, -1, -1, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, 227, 228, 229, 230, 231, -1, 233, + 234, 235, 236, -1, 238, 239, 240, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, 253, + 254, 255, 256, 257, 258, 259, 260, 261, 262, 263, + 264, -1, 266, 267, 268, 269, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, 300, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, -1, 313, + 314, 315, 316, 317, -1, 319, 320, 321, 322, 323, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, 338, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, 355, 356, 357, -1, 359, 360, 361, 362, 363, + 364, 365, -1, -1, 368, 369, 370, 371, 372, -1, + -1, 375, 376, 377, 378, 379, 380, 381, -1, 383, + 384, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 407, 408, 409, 3, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 14, 15, 16, + 17, 18, 19, 20, 21, -1, 23, 24, 25, -1, + -1, -1, -1, -1, -1, -1, 33, 34, -1, 36, + 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, + -1, 48, 49, 50, 51, 52, -1, -1, 55, 56, + 57, 58, 59, -1, 61, 62, 63, 64, 65, -1, + 67, -1, 69, 70, 71, 72, 73, 74, 75, -1, + 77, 78, 79, 80, 81, 82, -1, 84, 85, 86, + -1, -1, -1, 90, -1, -1, -1, 94, 95, 96, + 97, 98, 99, 100, 101, 102, -1, 104, -1, 106, + 107, 108, 109, 110, -1, 112, 113, 114, -1, -1, + 117, 118, 119, 120, 121, -1, 123, 124, 125, -1, + 127, 128, -1, 130, 131, 132, 133, 134, 135, 136, + 137, 138, -1, 140, -1, 142, 143, 144, -1, 146, + -1, 148, 149, -1, 151, 152, 153, 154, -1, 156, + 157, -1, 159, -1, 161, 162, 163, 164, 165, 166, + 167, 168, 169, -1, 171, 172, 173, 174, 175, 176, + -1, 178, 179, 180, 181, 182, 183, 184, 185, 186, + -1, 188, -1, 190, 191, 192, 193, 194, 195, 196, + 197, 198, 199, 200, 201, -1, 203, 204, 205, 206, + 207, -1, 209, 210, 211, -1, -1, 214, 215, 216, + 217, 218, 219, 220, 221, 222, 223, 224, 225, 226, + 227, 228, 229, 230, 231, -1, 233, 234, 235, 236, + -1, 238, 239, 240, 241, 242, 243, -1, 245, -1, + -1, 248, 249, 250, -1, -1, 253, 254, 255, 256, + 257, 258, 259, 260, 261, 262, 263, 264, -1, 266, + 267, 268, 269, 270, 271, 272, -1, 274, 275, 276, + 277, 278, 279, 280, 281, 282, 283, 284, 285, -1, + 287, 288, 289, 290, 291, 292, 293, 294, 295, 296, + -1, 298, 299, 300, 301, 302, 303, 304, 305, 306, + 307, 308, 309, 310, 311, -1, 313, 314, 315, 316, + 317, -1, 319, 320, 321, 322, 323, 324, 325, 326, + -1, 328, 329, 330, 331, 332, 333, 334, 335, 336, + 337, 338, -1, 340, 341, -1, 343, 344, 345, 346, + 347, 348, -1, 350, 351, -1, -1, 354, 355, 356, + 357, -1, 359, 360, 361, 362, 363, 364, 365, -1, + -1, 368, 369, 370, 371, 372, -1, -1, 375, 376, + 377, 378, 379, 380, 381, -1, 383, 384, 385, 386, + 387, -1, -1, 390, -1, -1, 393, 394, 395, 396, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 407, 408, 409, 3, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 14, 15, 16, 17, 18, 19, + 20, 21, -1, 23, 24, 25, -1, -1, -1, -1, + -1, -1, -1, 33, 34, -1, 36, 37, -1, 39, + 40, 41, 42, 43, -1, 45, 46, -1, 48, 49, + 50, 51, 52, -1, -1, 55, 56, 57, 58, 59, + 60, 61, 62, 63, 64, 65, -1, -1, 68, 69, + 70, 71, 72, -1, 74, 75, 76, 77, 78, 79, + 80, 81, 82, -1, -1, 85, 86, -1, -1, -1, + -1, -1, -1, -1, 94, 95, 96, 97, 98, 99, + 100, 101, 102, -1, 104, -1, 106, 107, 108, 109, + 110, -1, 112, 113, 114, -1, -1, 117, 118, 119, + 120, 121, -1, 123, 124, 125, -1, 127, 128, -1, + 130, 131, 132, 133, 134, 135, 136, 137, 138, -1, + 140, -1, 142, 143, 144, -1, 146, 147, 148, -1, + -1, -1, 152, 153, 154, -1, 156, 157, -1, 159, + -1, 161, 162, 163, 164, 165, -1, 167, 168, 169, + -1, 171, 172, 173, 174, 175, 176, -1, 178, -1, + 180, 181, 182, 183, 184, 185, 186, -1, 188, -1, + 190, -1, -1, 193, -1, 195, 196, 197, 198, 199, + 200, 201, -1, 203, 204, -1, 206, -1, -1, 209, + 210, 211, -1, -1, 214, 215, 216, 217, 218, 219, + 220, 221, 222, 223, 224, 225, 226, -1, 228, 229, + 230, 231, -1, 233, 234, -1, 236, -1, 238, 239, + 240, 241, 242, 243, -1, 245, -1, -1, 248, 249, + 250, -1, -1, 253, -1, -1, -1, 257, 258, 259, + 260, 261, 262, 263, 264, -1, 266, 267, 268, 269, + 270, 271, 272, 273, 274, 275, 276, 277, 278, 279, + 280, 281, 282, 283, 284, 285, -1, 287, 288, 289, + 290, 291, 292, 293, 294, 295, 296, -1, 298, 299, + -1, 301, 302, 303, 304, 305, 306, 307, 308, 309, + 310, 311, -1, 313, 314, 315, 316, 317, -1, 319, + 320, 321, 322, -1, 324, 325, 326, -1, 328, 329, + 330, 331, 332, 333, 334, 335, 336, 337, 338, -1, + 340, 341, -1, 343, 344, 345, 346, 347, 348, -1, + 350, 351, -1, -1, 354, 355, 356, 357, -1, 359, + 360, 361, 362, 363, 364, 365, -1, 367, 368, 369, + 370, 371, 372, -1, -1, 375, 376, 377, 378, 379, + 380, 381, -1, 383, -1, 385, 386, 387, -1, -1, + 390, -1, -1, 393, 394, 395, 396, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 407, 408, 409, + 3, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 14, 15, 16, 17, 18, 19, 20, 21, -1, + 23, 24, 25, -1, -1, -1, -1, -1, -1, -1, + 33, 34, -1, 36, 37, -1, 39, 40, 41, 42, + 43, -1, 45, 46, -1, 48, 49, 50, 51, 52, + -1, -1, 55, 56, 57, 58, 59, 60, 61, 62, + 63, 64, 65, -1, -1, -1, 69, 70, 71, 72, + -1, 74, 75, 76, 77, 78, 79, 80, 81, 82, + -1, -1, 85, 86, -1, -1, -1, -1, -1, -1, + -1, 94, 95, 96, 97, 98, 99, 100, 101, 102, + -1, 104, -1, 106, 107, 108, 109, 110, -1, 112, + 113, 114, -1, -1, 117, 118, 119, 120, 121, -1, + 123, 124, 125, -1, 127, 128, -1, 130, 131, 132, + 133, 134, 135, 136, 137, 138, -1, 140, -1, 142, + 143, 144, -1, 146, 147, 148, -1, -1, -1, 152, + 153, 154, -1, 156, 157, -1, 159, -1, 161, 162, + 163, 164, 165, -1, 167, 168, 169, -1, 171, 172, + 173, 174, 175, 176, -1, 178, -1, 180, 181, 182, + 183, 184, 185, 186, -1, 188, -1, 190, -1, -1, + 193, -1, 195, 196, 197, 198, 199, 200, 201, -1, + 203, 204, -1, 206, 207, -1, 209, 210, 211, -1, + -1, 214, 215, 216, 217, 218, 219, 220, 221, 222, + 223, 224, 225, 226, -1, 228, 229, 230, 231, -1, + 233, 234, -1, 236, -1, 238, 239, 240, 241, 242, + 243, -1, 245, -1, -1, 248, 249, 250, -1, -1, + 253, -1, -1, -1, 257, 258, 259, 260, 261, 262, + 263, 264, -1, 266, 267, 268, 269, 270, 271, 272, + 273, 274, 275, 276, 277, 278, 279, 280, 281, 282, + 283, 284, 285, -1, 287, 288, 289, 290, 291, 292, + 293, 294, 295, 296, -1, 298, 299, -1, 301, 302, + 303, 304, 305, 306, 307, 308, 309, 310, 311, -1, + 313, 314, 315, 316, 317, -1, 319, 320, 321, 322, + -1, 324, 325, 326, -1, 328, 329, 330, 331, 332, + 333, 334, 335, 336, 337, 338, -1, 340, 341, -1, + 343, 344, 345, 346, 347, 348, -1, 350, 351, -1, + -1, 354, 355, 356, 357, -1, 359, 360, 361, 362, + 363, 364, 365, -1, 367, 368, 369, 370, 371, 372, + -1, -1, 375, 376, 377, 378, 379, 380, 381, -1, + 383, -1, 385, 386, 387, -1, -1, 390, -1, -1, + 393, 394, 395, 396, 397, 398, 399, 400, 401, 402, + 403, 404, 405, 406, 407, 408, 409, 3, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 14, 15, + 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, + -1, -1, -1, -1, -1, -1, -1, 33, 34, -1, + 36, 37, -1, 39, 40, 41, 42, 43, -1, 45, + 46, -1, 48, 49, 50, 51, 52, -1, -1, 55, + 56, 57, 58, 59, -1, 61, 62, 63, 64, 65, + -1, -1, -1, 69, 70, 71, 72, -1, 74, 75, + -1, 77, 78, 79, 80, 81, 82, 83, -1, 85, + 86, -1, -1, -1, -1, -1, -1, -1, 94, 95, + 96, 97, 98, 99, 100, 101, 102, -1, 104, -1, + 106, 107, 108, 109, 110, -1, 112, 113, 114, -1, + -1, 117, 118, 119, 120, 121, -1, 123, 124, 125, + -1, 127, 128, -1, 130, 131, 132, 133, 134, 135, + 136, 137, 138, -1, 140, -1, 142, 143, 144, -1, + 146, -1, 148, -1, -1, -1, 152, 153, 154, 155, + 156, 157, -1, 159, -1, 161, 162, 163, 164, 165, + -1, 167, 168, 169, -1, 171, 172, 173, 174, 175, + 176, -1, 178, -1, 180, 181, 182, 183, 184, 185, + 186, -1, 188, -1, 190, -1, -1, 193, -1, 195, + 196, 197, 198, 199, 200, 201, -1, 203, 204, -1, + 206, -1, -1, 209, 210, 211, -1, -1, 214, 215, + 216, 217, 218, 219, 220, 221, 222, 223, 224, 225, + 226, -1, 228, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, 243, -1, 245, + -1, -1, 248, 249, 250, -1, -1, 253, -1, -1, + -1, 257, 258, 259, 260, 261, 262, 263, 264, -1, + 266, 267, 268, 269, 270, 271, 272, -1, 274, 275, + 276, 277, 278, 279, 280, 281, 282, 283, 284, 285, + 286, 287, 288, 289, 290, 291, 292, 293, 294, 295, + 296, -1, 298, 299, -1, 301, 302, 303, 304, 305, + 306, 307, 308, 309, 310, 311, 312, 313, 314, 315, + 316, 317, -1, 319, 320, 321, 322, -1, 324, 325, + 326, -1, 328, 329, 330, 331, 332, 333, 334, 335, + 336, 337, 338, -1, 340, 341, -1, 343, 344, 345, + 346, 347, 348, -1, 350, 351, -1, -1, 354, 355, + 356, 357, -1, 359, 360, 361, 362, 363, 364, 365, + -1, -1, 368, 369, 370, 371, 372, -1, -1, 375, + 376, 377, 378, 379, 380, 381, -1, 383, -1, 385, + 386, 387, -1, -1, 390, -1, -1, 393, 394, 395, + 396, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 407, 408, 409, 3, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 14, 15, 16, 17, 18, + 19, 20, 21, 22, 23, 24, 25, -1, -1, -1, + -1, -1, -1, -1, 33, 34, -1, 36, 37, -1, + 39, 40, 41, 42, 43, -1, 45, 46, -1, 48, + 49, 50, 51, 52, -1, -1, 55, 56, 57, 58, + 59, -1, 61, 62, 63, 64, 65, -1, -1, -1, + 69, 70, 71, 72, -1, 74, 75, -1, 77, 78, + 79, 80, 81, 82, 83, -1, 85, 86, -1, -1, + -1, -1, -1, -1, -1, 94, 95, 96, 97, 98, + 99, 100, 101, 102, -1, 104, -1, 106, 107, 108, + 109, 110, -1, 112, 113, 114, -1, -1, 117, 118, + 119, 120, 121, -1, 123, 124, 125, -1, 127, 128, + -1, 130, 131, 132, 133, 134, 135, 136, 137, 138, + -1, 140, -1, 142, 143, 144, -1, 146, -1, 148, + -1, -1, -1, 152, 153, 154, 155, 156, 157, -1, + 159, -1, 161, 162, 163, 164, 165, -1, 167, 168, + 169, -1, 171, 172, 173, 174, 175, 176, -1, 178, + -1, 180, 181, 182, 183, 184, 185, 186, -1, 188, + -1, 190, -1, -1, 193, -1, 195, 196, 197, 198, + 199, 200, 201, -1, 203, 204, -1, 206, -1, -1, + 209, 210, 211, -1, -1, 214, 215, 216, 217, 218, + 219, 220, 221, 222, 223, 224, 225, 226, -1, 228, + 229, 230, 231, -1, 233, 234, -1, 236, -1, 238, + 239, 240, 241, 242, 243, -1, 245, -1, -1, 248, + 249, 250, -1, -1, 253, -1, -1, -1, 257, 258, + 259, 260, 261, 262, 263, 264, -1, 266, 267, 268, + 269, 270, 271, 272, -1, 274, 275, 276, 277, 278, + 279, 280, 281, 282, 283, 284, 285, 286, 287, 288, + 289, 290, 291, 292, 293, 294, 295, 296, -1, 298, + 299, -1, 301, 302, 303, 304, 305, 306, 307, 308, + 309, 310, 311, 312, 313, 314, 315, 316, 317, -1, + 319, 320, 321, 322, -1, 324, 325, 326, -1, 328, + 329, 330, 331, 332, 333, 334, 335, 336, 337, 338, + -1, 340, 341, -1, 343, 344, 345, 346, 347, 348, + -1, 350, 351, -1, -1, 354, 355, 356, 357, -1, + 359, 360, 361, 362, 363, 364, 365, -1, -1, 368, + 369, 370, 371, 372, -1, -1, 375, 376, 377, 378, + 379, 380, 381, -1, 383, -1, 385, 386, 387, -1, + -1, 390, -1, -1, 393, 394, 395, 396, 397, 398, + 399, 400, 401, 402, 403, 404, 405, 406, 407, 408, + 409, 3, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 14, 15, 16, 17, 18, 19, 20, 21, + -1, 23, 24, 25, -1, -1, -1, -1, -1, -1, + -1, 33, 34, -1, 36, 37, -1, 39, 40, 41, + 42, 43, -1, 45, 46, -1, 48, 49, 50, 51, + 52, -1, -1, 55, 56, 57, 58, 59, 60, 61, + 62, 63, 64, 65, -1, -1, -1, 69, 70, 71, + 72, -1, 74, 75, 76, 77, 78, 79, 80, 81, + 82, -1, -1, 85, 86, -1, -1, -1, -1, -1, + -1, -1, 94, 95, 96, 97, 98, 99, 100, 101, + 102, -1, 104, -1, 106, 107, 108, 109, 110, -1, + 112, 113, 114, -1, -1, 117, 118, 119, 120, 121, + -1, 123, 124, 125, -1, 127, 128, -1, 130, 131, + 132, 133, 134, 135, 136, 137, 138, -1, 140, -1, + 142, 143, 144, -1, 146, 147, 148, -1, -1, -1, + 152, 153, 154, -1, 156, 157, -1, 159, -1, 161, + 162, 163, 164, 165, -1, 167, 168, 169, -1, 171, + 172, 173, 174, 175, 176, -1, 178, -1, 180, 181, + 182, 183, 184, 185, 186, -1, 188, -1, 190, -1, + -1, 193, -1, 195, 196, 197, 198, 199, 200, 201, + -1, 203, 204, -1, 206, -1, -1, 209, 210, 211, + -1, -1, 214, 215, 216, 217, 218, 219, 220, 221, + 222, 223, 224, 225, 226, -1, 228, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, 243, -1, 245, -1, -1, 248, 249, 250, -1, + -1, 253, -1, -1, -1, 257, 258, 259, 260, 261, + 262, 263, 264, -1, 266, 267, 268, 269, 270, 271, + 272, 273, 274, 275, 276, 277, 278, 279, 280, 281, + 282, 283, 284, 285, -1, 287, 288, 289, 290, 291, + 292, 293, 294, 295, 296, -1, 298, 299, -1, 301, + 302, 303, 304, 305, 306, 307, 308, 309, 310, 311, + -1, 313, 314, 315, 316, 317, -1, 319, 320, 321, + 322, -1, 324, 325, 326, -1, 328, 329, 330, 331, + 332, 333, 334, 335, 336, 337, 338, -1, 340, 341, + -1, 343, 344, 345, 346, 347, 348, -1, 350, 351, + -1, -1, 354, 355, 356, 357, -1, 359, 360, 361, + 362, 363, 364, 365, -1, 367, 368, 369, 370, 371, + 372, -1, -1, 375, 376, 377, 378, 379, 380, 381, + -1, 383, -1, 385, 386, 387, -1, -1, 390, -1, + -1, 393, 394, 395, 396, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 407, 408, 409, 3, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 14, + 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, + 25, -1, -1, -1, -1, -1, -1, -1, 33, 34, + -1, 36, 37, -1, 39, 40, 41, 42, 43, -1, + 45, 46, -1, 48, 49, 50, 51, 52, -1, -1, + 55, 56, 57, 58, 59, -1, 61, 62, 63, 64, + 65, -1, -1, -1, 69, 70, 71, 72, -1, 74, + 75, -1, 77, 78, 79, 80, 81, 82, 83, -1, + 85, 86, -1, -1, -1, -1, -1, -1, -1, 94, + 95, 96, 97, 98, 99, 100, 101, 102, -1, 104, + -1, 106, 107, 108, 109, 110, -1, 112, 113, 114, + -1, -1, 117, 118, 119, 120, 121, -1, 123, 124, + 125, -1, 127, 128, -1, 130, 131, 132, 133, 134, + 135, 136, 137, 138, -1, 140, -1, 142, 143, 144, + -1, 146, -1, 148, -1, -1, -1, 152, 153, 154, + -1, 156, 157, -1, 159, -1, 161, 162, 163, 164, + 165, -1, 167, 168, 169, -1, 171, 172, 173, 174, + 175, 176, -1, 178, -1, 180, 181, 182, 183, 184, + 185, 186, -1, 188, -1, 190, -1, -1, 193, -1, + 195, 196, 197, 198, 199, 200, 201, -1, 203, 204, + -1, 206, -1, -1, 209, 210, 211, -1, -1, 214, + 215, 216, 217, 218, 219, 220, 221, 222, 223, 224, + 225, 226, -1, 228, 229, 230, 231, -1, 233, 234, + -1, 236, -1, 238, 239, 240, 241, 242, 243, -1, + 245, -1, -1, 248, 249, 250, -1, -1, 253, -1, + -1, -1, 257, 258, 259, 260, 261, 262, 263, 264, + -1, 266, 267, 268, 269, 270, 271, 272, -1, 274, + 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, + 285, 286, 287, 288, 289, 290, 291, 292, 293, 294, + 295, 296, -1, 298, 299, -1, 301, 302, 303, 304, + 305, 306, 307, 308, 309, 310, 311, 312, 313, 314, + 315, 316, 317, -1, 319, 320, 321, 322, -1, 324, + 325, 326, -1, 328, 329, 330, 331, 332, 333, 334, + 335, 336, 337, 338, -1, 340, 341, -1, 343, 344, + 345, 346, 347, 348, -1, 350, 351, -1, -1, 354, + 355, 356, 357, -1, 359, 360, 361, 362, 363, 364, + 365, -1, -1, 368, 369, 370, 371, 372, -1, -1, + 375, 376, 377, 378, 379, 380, 381, -1, 383, -1, + 385, 386, 387, -1, -1, 390, -1, -1, 393, 394, + 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 407, 408, 409, 3, -1, 5, -1, -1, + -1, -1, -1, -1, -1, -1, 14, 15, 16, 17, + 18, 19, 20, 21, -1, 23, 24, 25, -1, -1, + -1, -1, -1, -1, -1, 33, 34, -1, 36, 37, + -1, 39, 40, 41, 42, 43, -1, 45, 46, -1, + 48, 49, 50, 51, 52, -1, -1, 55, 56, 57, + 58, 59, -1, 61, 62, 63, 64, 65, -1, -1, + -1, 69, 70, 71, 72, -1, 74, 75, -1, 77, + 78, 79, 80, 81, 82, -1, -1, 85, 86, -1, + -1, -1, -1, -1, -1, -1, 94, 95, 96, 97, + 98, 99, 100, 101, 102, -1, 104, -1, 106, 107, + 108, 109, 110, -1, 112, 113, 114, -1, -1, 117, + 118, 119, 120, 121, -1, 123, 124, 125, -1, 127, + 128, -1, 130, 131, 132, 133, 134, 135, 136, 137, + 138, 139, 140, -1, 142, 143, 144, -1, 146, -1, + 148, -1, -1, -1, 152, 153, 154, -1, 156, 157, + -1, 159, -1, 161, 162, 163, 164, 165, -1, 167, + 168, 169, -1, 171, 172, 173, 174, 175, 176, -1, + 178, -1, 180, 181, 182, 183, 184, 185, 186, -1, + 188, -1, 190, -1, -1, 193, -1, 195, 196, 197, + 198, 199, 200, 201, -1, 203, 204, -1, 206, -1, + -1, 209, 210, 211, -1, -1, 214, 215, 216, 217, + 218, 219, 220, 221, 222, 223, 224, 225, 226, -1, + 228, 229, 230, 231, -1, 233, 234, -1, 236, -1, + 238, 239, 240, 241, 242, 243, -1, 245, 246, -1, + 248, 249, 250, -1, -1, 253, -1, -1, -1, 257, + 258, 259, 260, 261, 262, 263, 264, -1, 266, 267, + 268, 269, 270, 271, 272, -1, 274, 275, 276, 277, + 278, 279, 280, 281, 282, 283, 284, 285, -1, 287, + 288, 289, 290, 291, 292, 293, 294, 295, 296, -1, + 298, 299, -1, 301, 302, 303, 304, 305, 306, 307, + 308, 309, 310, 311, -1, 313, 314, 315, 316, 317, + -1, 319, 320, 321, 322, -1, 324, 325, 326, -1, + 328, 329, 330, 331, 332, 333, 334, 335, 336, 337, + 338, -1, 340, 341, -1, 343, 344, 345, 346, 347, + 348, -1, 350, 351, -1, -1, 354, 355, 356, 357, + 358, 359, 360, 361, 362, 363, 364, 365, -1, -1, + 368, 369, 370, 371, 372, -1, -1, 375, 376, 377, + 378, 379, 380, 381, -1, 383, -1, 385, 386, 387, + -1, -1, 390, -1, -1, 393, 394, 395, 396, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, + 408, 409, 3, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 14, 15, 16, 17, 18, 19, 20, + 21, 22, 23, 24, 25, -1, -1, -1, -1, -1, + -1, -1, 33, 34, -1, 36, 37, -1, 39, 40, + 41, 42, 43, -1, 45, 46, -1, 48, 49, 50, + 51, 52, -1, -1, 55, 56, 57, 58, 59, -1, + 61, 62, 63, 64, 65, -1, -1, -1, 69, 70, + 71, 72, -1, 74, 75, -1, 77, 78, 79, 80, + 81, 82, -1, -1, 85, 86, -1, -1, -1, -1, + -1, -1, -1, 94, 95, 96, 97, 98, 99, 100, + 101, 102, -1, 104, -1, 106, 107, 108, 109, 110, + -1, 112, 113, 114, -1, -1, 117, 118, 119, 120, + 121, -1, 123, 124, 125, -1, 127, 128, -1, 130, + 131, 132, 133, 134, 135, 136, 137, 138, -1, 140, + -1, 142, 143, 144, -1, 146, 147, 148, -1, -1, + -1, 152, 153, 154, -1, 156, 157, -1, 159, -1, + 161, 162, 163, 164, 165, -1, 167, 168, 169, -1, + 171, 172, 173, 174, 175, 176, -1, 178, -1, 180, + 181, 182, 183, 184, 185, 186, -1, 188, -1, 190, + -1, -1, 193, -1, 195, 196, 197, 198, 199, 200, + 201, -1, 203, 204, -1, 206, -1, -1, 209, 210, + 211, -1, -1, 214, 215, 216, 217, 218, 219, 220, + 221, 222, 223, 224, 225, 226, -1, 228, 229, 230, + 231, -1, 233, 234, -1, 236, -1, 238, 239, 240, + 241, 242, 243, -1, 245, -1, -1, 248, 249, 250, + -1, -1, 253, -1, -1, -1, 257, 258, 259, 260, + 261, 262, 263, 264, -1, 266, 267, 268, 269, 270, + 271, 272, -1, 274, 275, 276, 277, 278, 279, 280, + 281, 282, 283, 284, 285, -1, 287, 288, 289, 290, + 291, 292, 293, 294, 295, 296, -1, 298, 299, -1, + 301, 302, 303, 304, 305, 306, 307, 308, 309, 310, + 311, -1, 313, 314, 315, 316, 317, -1, 319, 320, + 321, 322, -1, 324, 325, 326, -1, 328, 329, 330, + 331, 332, 333, 334, 335, 336, 337, 338, -1, 340, + 341, 342, 343, 344, 345, 346, 347, 348, -1, 350, + 351, -1, -1, 354, 355, 356, 357, -1, 359, 360, + 361, 362, 363, 364, 365, -1, -1, 368, 369, 370, + 371, 372, -1, -1, 375, 376, 377, 378, 379, 380, + 381, -1, 383, -1, 385, 386, 387, -1, -1, 390, + -1, -1, 393, 394, 395, 396, 397, 398, 399, 400, + 401, 402, 403, 404, 405, 406, 407, 408, 409, 3, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, -1, -1, -1, 33, + 34, -1, 36, 37, -1, 39, 40, 41, 42, 43, + -1, 45, 46, -1, 48, 49, 50, 51, 52, -1, + -1, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, 65, -1, -1, -1, 69, 70, 71, 72, -1, + 74, 75, -1, 77, 78, 79, 80, 81, 82, 83, + -1, 85, 86, -1, -1, -1, -1, -1, -1, -1, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + 134, 135, 136, 137, 138, -1, 140, -1, 142, 143, + 144, -1, 146, -1, 148, -1, -1, -1, 152, 153, + 154, -1, 156, 157, -1, 159, -1, 161, 162, 163, + 164, 165, -1, 167, 168, 169, -1, 171, 172, 173, + 174, 175, 176, -1, 178, -1, 180, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, -1, -1, 193, + -1, 195, 196, 197, 198, 199, 200, 201, -1, 203, + 204, -1, 206, -1, -1, 209, 210, 211, -1, -1, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, -1, 228, 229, 230, 231, -1, 233, + 234, -1, 236, -1, 238, 239, 240, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, 253, + -1, -1, -1, 257, 258, 259, 260, 261, 262, 263, + 264, -1, 266, 267, 268, 269, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, 286, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, -1, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, 312, 313, + 314, 315, 316, 317, -1, 319, 320, 321, 322, -1, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, 338, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, 355, 356, 357, -1, 359, 360, 361, 362, 363, + 364, 365, -1, -1, 368, 369, 370, 371, 372, -1, + -1, 375, 376, 377, 378, 379, 380, 381, -1, 383, + -1, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 407, 408, 409, 3, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 14, 15, 16, + 17, 18, 19, 20, 21, -1, 23, 24, 25, 26, + 27, -1, -1, -1, -1, -1, 33, 34, -1, 36, + 37, -1, 39, 40, 41, 42, 43, -1, 45, 46, + -1, 48, 49, 50, 51, 52, -1, -1, 55, 56, + 57, 58, 59, -1, 61, 62, 63, 64, 65, -1, + -1, -1, 69, 70, 71, 72, -1, 74, 75, -1, + 77, 78, 79, 80, 81, 82, -1, -1, 85, 86, + -1, -1, -1, -1, -1, -1, -1, 94, 95, 96, + 97, 98, 99, 100, 101, 102, -1, 104, -1, 106, + 107, 108, 109, 110, -1, 112, 113, 114, -1, -1, + 117, 118, 119, 120, 121, -1, 123, 124, 125, -1, + 127, 128, -1, 130, 131, 132, 133, 134, 135, 136, + 137, 138, -1, 140, -1, 142, 143, 144, -1, 146, + -1, 148, -1, -1, -1, 152, 153, 154, -1, 156, + 157, -1, 159, -1, 161, 162, 163, 164, 165, -1, + 167, 168, 169, -1, 171, 172, 173, 174, 175, 176, + -1, 178, -1, 180, 181, 182, 183, 184, 185, 186, + -1, 188, -1, 190, -1, -1, 193, -1, 195, 196, + 197, 198, 199, 200, 201, -1, 203, 204, -1, 206, + -1, -1, 209, 210, 211, -1, -1, 214, 215, 216, + 217, 218, 219, 220, 221, 222, 223, 224, 225, 226, + -1, 228, 229, 230, 231, -1, 233, 234, -1, 236, + -1, 238, 239, 240, 241, 242, 243, -1, 245, -1, + -1, 248, 249, 250, -1, -1, 253, -1, -1, -1, + 257, 258, 259, 260, 261, 262, 263, 264, -1, 266, + 267, 268, 269, 270, 271, 272, -1, 274, 275, 276, + 277, 278, 279, 280, 281, 282, 283, 284, 285, -1, + 287, 288, 289, 290, 291, 292, 293, 294, 295, 296, + -1, 298, 299, -1, 301, 302, 303, 304, 305, 306, + 307, 308, 309, 310, 311, -1, 313, 314, 315, 316, + 317, -1, 319, 320, 321, 322, -1, 324, 325, 326, + -1, 328, 329, 330, 331, 332, 333, 334, 335, 336, + 337, 338, -1, 340, 341, -1, 343, 344, 345, 346, + 347, 348, -1, 350, 351, -1, -1, 354, 355, 356, + 357, -1, 359, 360, 361, 362, 363, 364, 365, -1, + -1, 368, 369, 370, 371, 372, -1, -1, 375, 376, + 377, 378, 379, 380, 381, -1, 383, 384, 385, 386, + 387, -1, -1, 390, -1, -1, 393, 394, 395, 396, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 407, 408, 409, 3, -1, 5, -1, -1, -1, -1, + -1, -1, -1, -1, 14, 15, 16, 17, 18, 19, + 20, 21, -1, 23, 24, 25, -1, -1, -1, -1, + -1, -1, -1, 33, 34, -1, 36, 37, -1, 39, + 40, 41, 42, 43, -1, 45, 46, -1, 48, 49, + 50, 51, 52, -1, -1, 55, 56, 57, 58, 59, + -1, 61, 62, 63, 64, 65, -1, -1, -1, 69, + 70, 71, 72, -1, 74, 75, -1, 77, 78, 79, + 80, 81, 82, -1, -1, 85, 86, -1, -1, -1, + -1, -1, -1, -1, 94, 95, 96, 97, 98, 99, + 100, 101, 102, 103, 104, -1, 106, 107, 108, 109, + 110, -1, 112, 113, 114, -1, -1, 117, 118, 119, + 120, 121, -1, 123, 124, 125, -1, 127, 128, -1, + 130, 131, 132, 133, 134, 135, 136, 137, 138, -1, + 140, -1, 142, 143, 144, -1, 146, -1, 148, -1, + -1, -1, 152, 153, 154, -1, 156, 157, -1, 159, + -1, 161, 162, 163, 164, 165, -1, 167, 168, 169, + -1, 171, 172, 173, 174, 175, 176, -1, 178, -1, + 180, 181, 182, 183, 184, 185, 186, -1, 188, -1, + 190, -1, -1, 193, -1, 195, 196, 197, 198, 199, + 200, 201, -1, 203, 204, -1, 206, -1, -1, 209, + 210, 211, -1, -1, 214, 215, 216, 217, 218, 219, + 220, 221, 222, 223, 224, 225, 226, -1, 228, 229, + 230, 231, -1, 233, 234, -1, 236, -1, 238, 239, + 240, 241, 242, 243, -1, 245, -1, -1, 248, 249, + 250, -1, -1, 253, -1, -1, -1, 257, 258, 259, + 260, 261, 262, 263, 264, -1, 266, 267, 268, 269, + 270, 271, 272, -1, 274, 275, 276, 277, 278, 279, + 280, 281, 282, 283, 284, 285, -1, 287, 288, 289, + 290, 291, 292, 293, 294, 295, 296, -1, 298, 299, + -1, 301, 302, 303, 304, 305, 306, 307, 308, 309, + 310, 311, -1, 313, 314, 315, 316, 317, -1, 319, + 320, 321, 322, -1, 324, 325, 326, -1, 328, 329, + 330, 331, 332, 333, 334, 335, 336, 337, 338, -1, + 340, 341, -1, 343, 344, 345, 346, 347, 348, -1, + 350, 351, -1, -1, 354, 355, 356, 357, -1, 359, + 360, 361, 362, 363, 364, 365, -1, -1, 368, 369, + 370, 371, 372, -1, -1, 375, 376, 377, 378, 379, + 380, 381, -1, 383, -1, 385, 386, 387, -1, -1, + 390, -1, -1, 393, 394, 395, 396, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 407, 408, 409, + 3, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 14, 15, 16, 17, 18, 19, 20, 21, -1, + 23, 24, 25, -1, -1, -1, -1, -1, -1, -1, + 33, 34, -1, 36, 37, -1, 39, 40, 41, 42, + 43, -1, 45, 46, -1, 48, 49, 50, 51, 52, + -1, -1, 55, 56, 57, 58, 59, -1, 61, 62, + 63, 64, 65, -1, -1, -1, 69, 70, 71, 72, + -1, 74, 75, -1, 77, 78, 79, 80, 81, 82, + -1, -1, 85, 86, -1, -1, -1, -1, -1, -1, + 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, + -1, 104, -1, 106, 107, 108, 109, 110, -1, 112, + 113, 114, -1, -1, 117, 118, 119, 120, 121, -1, + 123, 124, 125, -1, 127, 128, -1, 130, 131, 132, + 133, 134, 135, 136, 137, 138, -1, 140, -1, 142, + 143, 144, -1, 146, -1, 148, -1, -1, -1, 152, + 153, 154, -1, 156, 157, -1, 159, -1, 161, 162, + 163, 164, 165, -1, 167, 168, 169, -1, 171, 172, + 173, 174, 175, 176, -1, 178, -1, 180, 181, 182, + 183, 184, 185, 186, -1, 188, -1, 190, -1, -1, + 193, -1, 195, 196, 197, 198, 199, 200, 201, -1, + 203, 204, -1, 206, -1, -1, 209, 210, 211, -1, + -1, 214, 215, 216, 217, 218, 219, 220, 221, 222, + 223, 224, 225, 226, -1, 228, 229, 230, 231, -1, + 233, 234, -1, 236, -1, 238, 239, 240, 241, 242, + 243, -1, 245, -1, -1, 248, 249, 250, -1, -1, + 253, -1, -1, -1, 257, 258, 259, 260, 261, 262, + 263, 264, -1, 266, 267, 268, 269, 270, 271, 272, + -1, 274, 275, 276, 277, 278, 279, 280, 281, 282, + 283, 284, 285, -1, 287, 288, 289, 290, 291, 292, + 293, 294, 295, 296, -1, 298, 299, -1, 301, 302, + 303, 304, 305, 306, 307, 308, 309, 310, 311, -1, + 313, 314, 315, 316, 317, -1, 319, 320, 321, 322, + -1, 324, 325, 326, -1, 328, 329, 330, 331, 332, + 333, 334, 335, 336, 337, 338, -1, 340, 341, -1, + 343, 344, 345, 346, 347, 348, -1, 350, 351, -1, + -1, 354, 355, 356, 357, -1, 359, 360, 361, 362, + 363, 364, 365, -1, -1, 368, 369, 370, 371, 372, + 373, -1, 375, 376, 377, 378, 379, 380, 381, -1, + 383, -1, 385, 386, 387, -1, -1, 390, -1, -1, + 393, 394, 395, 396, 397, 398, 399, 400, 401, 402, + 403, 404, 405, 406, 407, 408, 409, 3, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 14, 15, + 16, 17, 18, 19, 20, 21, -1, 23, 24, 25, + 26, 27, -1, -1, -1, -1, -1, 33, 34, -1, + 36, 37, -1, 39, 40, 41, 42, 43, -1, 45, + 46, -1, 48, 49, 50, 51, 52, -1, -1, 55, + 56, 57, 58, 59, -1, 61, 62, 63, 64, 65, + -1, -1, -1, 69, 70, 71, 72, -1, 74, 75, + -1, 77, 78, 79, 80, 81, 82, -1, -1, 85, + 86, -1, -1, -1, -1, -1, -1, -1, 94, 95, + 96, 97, 98, 99, 100, 101, 102, -1, 104, -1, + 106, 107, 108, 109, 110, -1, 112, 113, 114, -1, + -1, 117, 118, 119, 120, 121, -1, 123, 124, 125, + -1, 127, 128, -1, 130, 131, 132, 133, 134, 135, + 136, 137, 138, -1, 140, -1, 142, 143, 144, -1, + 146, -1, 148, -1, -1, -1, 152, 153, 154, -1, + 156, 157, -1, 159, -1, 161, 162, 163, 164, 165, + -1, 167, 168, 169, -1, 171, 172, 173, 174, 175, + 176, -1, 178, -1, 180, 181, 182, 183, 184, 185, + 186, -1, 188, -1, 190, -1, -1, 193, -1, 195, + 196, 197, 198, 199, 200, 201, -1, 203, 204, -1, + 206, -1, -1, 209, 210, 211, -1, -1, 214, 215, + 216, 217, 218, 219, 220, 221, 222, 223, 224, 225, + 226, -1, 228, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, 243, -1, 245, + -1, -1, 248, 249, 250, -1, -1, 253, -1, -1, + -1, 257, 258, 259, 260, 261, 262, 263, 264, -1, + 266, 267, 268, 269, 270, 271, 272, -1, 274, 275, + 276, 277, 278, 279, 280, 281, 282, 283, 284, 285, + -1, 287, 288, 289, 290, 291, 292, 293, 294, 295, + 296, -1, 298, 299, -1, 301, 302, 303, 304, 305, + 306, 307, 308, 309, 310, 311, -1, 313, 314, 315, + 316, 317, -1, 319, 320, 321, 322, -1, 324, 325, + 326, -1, 328, 329, 330, 331, 332, 333, 334, 335, + 336, 337, 338, -1, 340, 341, -1, 343, 344, 345, + 346, 347, 348, -1, 350, 351, -1, -1, 354, 355, + 356, 357, -1, 359, 360, 361, 362, 363, 364, 365, + -1, -1, 368, 369, 370, 371, 372, -1, -1, 375, + 376, 377, 378, 379, 380, 381, -1, 383, -1, 385, + 386, 387, -1, -1, 390, -1, -1, 393, 394, 395, + 396, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 407, 408, 409, 3, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 14, 15, 16, 17, 18, + 19, 20, 21, 22, 23, 24, 25, -1, -1, -1, + -1, -1, -1, -1, 33, 34, -1, 36, 37, -1, + 39, 40, 41, 42, 43, -1, 45, 46, -1, 48, + 49, 50, 51, 52, -1, -1, 55, 56, 57, 58, + 59, -1, 61, 62, 63, 64, 65, -1, -1, -1, + 69, 70, 71, 72, -1, 74, 75, -1, 77, 78, + 79, 80, 81, 82, -1, -1, 85, 86, -1, -1, + -1, -1, -1, -1, -1, 94, 95, 96, 97, 98, + 99, 100, 101, 102, -1, 104, -1, 106, 107, 108, + 109, 110, -1, 112, 113, 114, -1, -1, 117, 118, + 119, 120, 121, -1, 123, 124, 125, -1, 127, 128, + -1, 130, 131, 132, 133, 134, 135, 136, 137, 138, + -1, 140, -1, 142, 143, 144, -1, 146, -1, 148, + -1, -1, -1, 152, 153, 154, -1, 156, 157, -1, + 159, -1, 161, 162, 163, 164, 165, -1, 167, 168, + 169, -1, 171, 172, 173, 174, 175, 176, -1, 178, + -1, 180, 181, 182, 183, 184, 185, 186, -1, 188, + -1, 190, -1, -1, 193, -1, 195, 196, 197, 198, + 199, 200, 201, -1, 203, 204, -1, 206, -1, -1, + 209, 210, 211, -1, -1, 214, 215, 216, 217, 218, + 219, 220, 221, 222, 223, 224, 225, 226, -1, 228, + 229, 230, 231, -1, 233, 234, -1, 236, -1, 238, + 239, 240, 241, 242, 243, -1, 245, -1, -1, 248, + 249, 250, -1, -1, 253, -1, -1, -1, 257, 258, + 259, 260, 261, 262, 263, 264, -1, 266, 267, 268, + 269, 270, 271, 272, -1, 274, 275, 276, 277, 278, + 279, 280, 281, 282, 283, 284, 285, -1, 287, 288, + 289, 290, 291, 292, 293, 294, 295, 296, -1, 298, + 299, -1, 301, 302, 303, 304, 305, 306, 307, 308, + 309, 310, 311, -1, 313, 314, 315, 316, 317, -1, + 319, 320, 321, 322, -1, 324, 325, 326, -1, 328, + 329, 330, 331, 332, 333, 334, 335, 336, 337, 338, + -1, 340, 341, -1, 343, 344, 345, 346, 347, 348, + -1, 350, 351, -1, -1, 354, 355, 356, 357, -1, + 359, 360, 361, 362, 363, 364, 365, -1, -1, 368, + 369, 370, 371, 372, 373, -1, 375, 376, 377, 378, + 379, 380, 381, -1, 383, -1, 385, 386, 387, -1, + -1, 390, -1, -1, 393, 394, 395, 396, 397, 398, + 399, 400, 401, 402, 403, 404, 405, 406, 407, 408, + 409, 3, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 14, 15, 16, 17, 18, 19, 20, 21, + 22, 23, 24, 25, -1, -1, -1, -1, -1, -1, + -1, 33, 34, -1, 36, 37, -1, 39, 40, 41, + 42, 43, -1, 45, 46, -1, 48, 49, 50, 51, + 52, -1, -1, 55, 56, 57, 58, 59, -1, 61, + 62, 63, 64, 65, -1, -1, -1, 69, 70, 71, + 72, -1, 74, 75, -1, 77, 78, 79, 80, 81, + 82, -1, -1, 85, 86, -1, -1, -1, -1, -1, + -1, -1, 94, 95, 96, 97, 98, 99, 100, 101, + 102, -1, 104, -1, 106, 107, 108, 109, 110, -1, + 112, 113, 114, -1, -1, 117, 118, 119, 120, 121, + -1, 123, 124, 125, -1, 127, 128, -1, 130, 131, + 132, 133, 134, 135, 136, 137, 138, -1, 140, -1, + 142, 143, 144, -1, 146, -1, 148, -1, -1, -1, + 152, 153, 154, -1, 156, 157, -1, 159, -1, 161, + 162, 163, 164, 165, -1, 167, 168, 169, -1, 171, + 172, 173, 174, 175, 176, -1, 178, -1, 180, 181, + 182, 183, 184, 185, 186, -1, 188, -1, 190, -1, + -1, 193, -1, 195, 196, 197, 198, 199, 200, 201, + -1, 203, 204, -1, 206, -1, -1, 209, 210, 211, + -1, -1, 214, 215, 216, 217, 218, 219, 220, 221, + 222, 223, 224, 225, 226, -1, 228, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, 243, -1, 245, -1, -1, 248, 249, 250, -1, + -1, 253, -1, -1, -1, 257, 258, 259, 260, 261, + 262, 263, 264, -1, 266, 267, 268, 269, 270, 271, + 272, -1, 274, 275, 276, 277, 278, 279, 280, 281, + 282, 283, 284, 285, -1, 287, 288, 289, 290, 291, + 292, 293, 294, 295, 296, -1, 298, 299, -1, 301, + 302, 303, 304, 305, 306, 307, 308, 309, 310, 311, + -1, 313, 314, 315, 316, 317, -1, 319, 320, 321, + 322, -1, 324, 325, 326, -1, 328, 329, 330, 331, + 332, 333, 334, 335, 336, 337, 338, -1, 340, 341, + -1, 343, 344, 345, 346, 347, 348, -1, 350, 351, + -1, -1, 354, 355, 356, 357, -1, 359, 360, 361, + 362, 363, 364, 365, -1, -1, 368, 369, 370, 371, + 372, 373, -1, 375, 376, 377, 378, 379, 380, 381, + -1, 383, -1, 385, 386, 387, -1, -1, 390, -1, + -1, 393, 394, 395, 396, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 407, 408, 409, 3, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 14, + 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, + 25, -1, -1, -1, -1, -1, -1, -1, 33, 34, + -1, 36, 37, -1, 39, 40, 41, 42, 43, -1, + 45, 46, -1, 48, 49, 50, 51, 52, -1, -1, + 55, 56, 57, 58, 59, -1, 61, 62, 63, 64, + 65, -1, -1, -1, 69, 70, 71, 72, -1, 74, + 75, -1, 77, 78, 79, 80, 81, 82, -1, -1, + 85, 86, -1, -1, -1, -1, -1, -1, -1, 94, + 95, 96, 97, 98, 99, 100, 101, 102, -1, 104, + -1, 106, 107, 108, 109, 110, -1, 112, 113, 114, + -1, -1, 117, 118, 119, 120, 121, -1, 123, 124, + 125, -1, 127, 128, -1, 130, 131, 132, 133, 134, + 135, 136, 137, 138, -1, 140, -1, 142, 143, 144, + -1, 146, -1, 148, -1, -1, -1, 152, 153, 154, + -1, 156, 157, -1, 159, -1, 161, 162, 163, 164, + 165, -1, 167, 168, 169, -1, 171, 172, 173, 174, + 175, 176, -1, 178, -1, 180, 181, 182, 183, 184, + 185, 186, -1, 188, -1, 190, -1, -1, 193, -1, + 195, 196, 197, 198, 199, 200, 201, -1, 203, 204, + -1, 206, -1, -1, 209, 210, 211, -1, -1, 214, + 215, 216, 217, 218, 219, 220, 221, 222, 223, 224, + 225, 226, -1, 228, 229, 230, 231, -1, 233, 234, + -1, 236, -1, 238, 239, 240, 241, 242, 243, -1, + 245, -1, -1, 248, 249, 250, -1, -1, 253, -1, + -1, -1, 257, 258, 259, 260, 261, 262, 263, 264, + -1, 266, 267, 268, 269, 270, 271, 272, -1, 274, + 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, + 285, -1, 287, 288, 289, 290, 291, 292, 293, 294, + 295, 296, -1, 298, 299, -1, 301, 302, 303, 304, + 305, 306, 307, 308, 309, 310, 311, -1, 313, 314, + 315, 316, 317, -1, 319, 320, 321, 322, -1, 324, + 325, 326, -1, 328, 329, 330, 331, 332, 333, 334, + 335, 336, 337, 338, -1, 340, 341, -1, 343, 344, + 345, 346, 347, 348, -1, 350, 351, -1, -1, 354, + 355, 356, 357, -1, 359, 360, 361, 362, 363, 364, + 365, -1, -1, 368, 369, 370, 371, 372, -1, -1, + 375, 376, 377, 378, 379, 380, 381, -1, 383, -1, + 385, 386, 387, -1, -1, 390, -1, -1, 393, 394, + 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 407, 408, 409, 3, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 14, 15, 16, 17, + 18, 19, 20, 21, 22, 23, 24, 25, -1, -1, + -1, -1, -1, -1, -1, 33, 34, -1, 36, 37, + -1, 39, 40, 41, 42, 43, -1, 45, 46, -1, + 48, 49, 50, 51, 52, -1, -1, 55, 56, 57, + 58, 59, -1, 61, 62, 63, 64, 65, -1, -1, + -1, 69, 70, 71, 72, -1, 74, 75, -1, 77, + 78, 79, 80, 81, 82, -1, -1, 85, 86, -1, + -1, -1, -1, -1, -1, -1, 94, 95, 96, 97, + 98, 99, 100, 101, 102, -1, 104, -1, 106, 107, + 108, 109, 110, -1, 112, 113, 114, -1, -1, 117, + 118, 119, 120, 121, -1, 123, 124, 125, -1, 127, + 128, -1, 130, 131, 132, 133, 134, 135, 136, 137, + 138, -1, 140, -1, 142, 143, 144, -1, 146, -1, + 148, -1, -1, -1, 152, 153, 154, -1, 156, 157, + -1, 159, -1, 161, 162, 163, 164, 165, -1, 167, + 168, 169, -1, 171, 172, 173, 174, 175, 176, -1, + 178, -1, 180, 181, 182, 183, 184, 185, 186, -1, + 188, -1, 190, -1, -1, 193, -1, 195, 196, 197, + 198, 199, 200, 201, -1, 203, 204, -1, 206, -1, + -1, 209, 210, 211, -1, -1, 214, 215, 216, 217, + 218, 219, 220, 221, 222, 223, 224, 225, 226, -1, + 228, 229, 230, 231, -1, 233, 234, -1, 236, -1, + 238, 239, 240, 241, 242, 243, -1, 245, -1, -1, + 248, 249, 250, -1, -1, 253, -1, -1, -1, 257, + 258, 259, 260, 261, 262, 263, 264, -1, 266, 267, + 268, 269, 270, 271, 272, -1, 274, 275, 276, 277, + 278, 279, 280, 281, 282, 283, 284, 285, -1, 287, + 288, 289, 290, 291, 292, 293, 294, 295, 296, -1, + 298, 299, -1, 301, 302, 303, 304, 305, 306, 307, + 308, 309, 310, 311, -1, 313, 314, 315, 316, 317, + -1, 319, 320, 321, 322, -1, 324, 325, 326, -1, + 328, 329, 330, 331, 332, 333, 334, 335, 336, 337, + 338, -1, 340, 341, -1, 343, 344, 345, 346, 347, + 348, -1, 350, 351, -1, -1, 354, 355, 356, 357, + -1, 359, 360, 361, 362, 363, 364, 365, -1, -1, + 368, 369, 370, 371, 372, -1, -1, 375, 376, 377, + 378, 379, 380, 381, -1, 383, -1, 385, 386, 387, + -1, -1, 390, -1, -1, 393, 394, 395, 396, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, + 408, 409, 3, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 14, 15, 16, 17, 18, 19, 20, + 21, 22, 23, 24, 25, -1, -1, -1, -1, -1, + -1, -1, 33, 34, -1, 36, 37, -1, 39, 40, + 41, 42, 43, -1, 45, 46, -1, 48, 49, 50, + 51, 52, -1, -1, 55, 56, 57, 58, 59, -1, + 61, 62, 63, 64, 65, -1, -1, -1, 69, 70, + 71, 72, -1, 74, 75, -1, 77, 78, 79, 80, + 81, 82, -1, -1, 85, 86, -1, -1, -1, -1, + -1, -1, -1, 94, 95, 96, 97, 98, 99, 100, + 101, 102, -1, 104, -1, 106, 107, 108, 109, 110, + -1, 112, 113, 114, -1, -1, 117, 118, 119, 120, + 121, -1, 123, 124, 125, -1, 127, 128, -1, 130, + 131, 132, 133, 134, 135, 136, 137, 138, -1, 140, + -1, 142, 143, 144, -1, 146, -1, 148, -1, -1, + -1, 152, 153, 154, -1, 156, 157, -1, 159, -1, + 161, 162, 163, 164, 165, -1, 167, 168, 169, -1, + 171, 172, 173, 174, 175, 176, -1, 178, -1, 180, + 181, 182, 183, 184, 185, 186, -1, 188, -1, 190, + -1, -1, 193, -1, 195, 196, 197, 198, 199, 200, + 201, -1, 203, 204, -1, 206, -1, -1, 209, 210, + 211, -1, -1, 214, 215, 216, 217, 218, 219, 220, + 221, 222, 223, 224, 225, 226, -1, 228, 229, 230, + 231, -1, 233, 234, -1, 236, -1, 238, 239, 240, + 241, 242, 243, -1, 245, -1, -1, 248, 249, 250, + -1, -1, 253, -1, -1, -1, 257, 258, 259, 260, + 261, 262, 263, 264, -1, 266, 267, 268, 269, 270, + 271, 272, -1, 274, 275, 276, 277, 278, 279, 280, + 281, 282, 283, 284, 285, -1, 287, 288, 289, 290, + 291, 292, 293, 294, 295, 296, -1, 298, 299, -1, + 301, 302, 303, 304, 305, 306, 307, 308, 309, 310, + 311, -1, 313, 314, 315, 316, 317, -1, 319, 320, + 321, 322, -1, 324, 325, 326, -1, 328, 329, 330, + 331, 332, 333, 334, 335, 336, 337, 338, -1, 340, + 341, -1, 343, 344, 345, 346, 347, 348, -1, 350, + 351, -1, -1, 354, 355, 356, 357, -1, 359, 360, + 361, 362, 363, 364, 365, -1, -1, 368, 369, 370, + 371, 372, -1, -1, 375, 376, 377, 378, 379, 380, + 381, -1, 383, -1, 385, 386, 387, -1, -1, 390, + -1, -1, 393, 394, 395, 396, 397, 398, 399, 400, + 401, 402, 403, 404, 405, 406, 407, 408, 409, 3, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, + 24, 25, -1, -1, -1, -1, -1, -1, -1, 33, + 34, -1, 36, 37, -1, 39, 40, 41, 42, 43, + -1, 45, 46, -1, 48, 49, 50, 51, 52, -1, + -1, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, 65, -1, -1, -1, 69, 70, 71, 72, -1, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + -1, 85, 86, -1, -1, -1, -1, -1, -1, -1, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + 134, 135, 136, 137, 138, -1, 140, -1, 142, 143, + 144, -1, 146, -1, 148, -1, -1, -1, 152, 153, + 154, -1, 156, 157, -1, 159, -1, 161, 162, 163, + 164, 165, -1, 167, 168, 169, -1, 171, 172, 173, + 174, 175, 176, -1, 178, -1, 180, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, -1, -1, 193, + -1, 195, 196, 197, 198, 199, 200, 201, -1, 203, + 204, -1, 206, -1, -1, 209, 210, 211, -1, -1, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, -1, 228, 229, 230, 231, -1, 233, + 234, -1, 236, -1, 238, 239, 240, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, 253, + -1, -1, -1, 257, 258, 259, 260, 261, 262, 263, + 264, -1, 266, 267, 268, 269, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, -1, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, -1, 313, + 314, 315, 316, 317, -1, 319, 320, 321, 322, -1, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, 338, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, 355, 356, 357, -1, 359, 360, 361, 362, 363, + 364, 365, -1, -1, 368, 369, 370, 371, 372, -1, + -1, 375, 376, 377, 378, 379, 380, 381, -1, 383, + -1, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 407, 408, 409, 3, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 14, 15, 16, + 17, 18, 19, 20, 21, -1, 23, 24, 25, -1, + -1, -1, -1, -1, -1, -1, 33, 34, -1, 36, + 37, -1, 39, 40, 41, 42, 43, -1, 45, 46, + -1, 48, 49, 50, 51, 52, -1, -1, 55, 56, + 57, 58, 59, -1, 61, 62, 63, 64, 65, -1, + -1, -1, 69, 70, 71, 72, -1, 74, 75, -1, + 77, 78, 79, 80, 81, 82, -1, -1, 85, 86, + -1, -1, -1, -1, -1, -1, -1, 94, 95, 96, + 97, 98, 99, 100, 101, 102, -1, 104, -1, 106, + 107, 108, 109, 110, -1, 112, 113, 114, -1, -1, + 117, 118, 119, 120, 121, -1, 123, 124, 125, -1, + 127, 128, -1, 130, 131, 132, 133, 134, 135, 136, + 137, 138, -1, 140, -1, 142, 143, 144, -1, 146, + -1, 148, -1, -1, -1, 152, 153, 154, -1, 156, + 157, -1, 159, -1, 161, 162, 163, 164, 165, -1, + 167, 168, 169, -1, 171, 172, 173, 174, 175, 176, + -1, 178, -1, 180, 181, 182, 183, 184, 185, 186, + -1, 188, -1, 190, -1, -1, 193, -1, 195, 196, + 197, 198, 199, 200, 201, -1, 203, 204, -1, 206, + -1, -1, 209, 210, 211, -1, -1, 214, 215, 216, + 217, 218, 219, 220, 221, 222, 223, 224, 225, 226, + -1, 228, 229, 230, 231, -1, 233, 234, -1, 236, + -1, 238, 239, 240, 241, 242, 243, -1, 245, -1, + 247, 248, 249, 250, -1, -1, 253, -1, -1, -1, + 257, 258, 259, 260, 261, 262, 263, 264, -1, 266, + 267, 268, 269, 270, 271, 272, -1, 274, 275, 276, + 277, 278, 279, 280, 281, 282, 283, 284, 285, -1, + 287, 288, 289, 290, 291, 292, 293, 294, 295, 296, + -1, 298, 299, -1, 301, 302, 303, 304, 305, 306, + 307, 308, 309, 310, 311, -1, 313, 314, 315, 316, + 317, -1, 319, 320, 321, 322, -1, 324, 325, 326, + -1, 328, 329, 330, 331, 332, 333, 334, 335, 336, + 337, 338, -1, 340, 341, -1, 343, 344, 345, 346, + 347, 348, -1, 350, 351, -1, -1, 354, 355, 356, + 357, -1, 359, 360, 361, 362, 363, 364, 365, -1, + -1, 368, 369, 370, 371, 372, -1, -1, 375, 376, + 377, 378, 379, 380, 381, -1, 383, -1, 385, 386, + 387, -1, -1, 390, -1, -1, 393, 394, 395, 396, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 407, 408, 409, 3, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 14, 15, 16, 17, 18, 19, + 20, 21, -1, 23, 24, 25, -1, -1, -1, -1, + -1, -1, -1, 33, 34, -1, 36, 37, -1, 39, + 40, 41, 42, 43, -1, 45, 46, -1, 48, 49, + 50, 51, 52, -1, -1, 55, 56, 57, 58, 59, + -1, 61, 62, 63, 64, 65, -1, -1, -1, 69, + 70, 71, 72, -1, 74, 75, -1, 77, 78, 79, + 80, 81, 82, -1, -1, 85, 86, -1, -1, -1, + -1, -1, -1, -1, 94, 95, 96, 97, 98, 99, + 100, 101, 102, -1, 104, -1, 106, 107, 108, 109, + 110, -1, 112, 113, 114, -1, -1, 117, 118, 119, + 120, 121, -1, 123, 124, 125, -1, 127, 128, -1, + 130, 131, 132, 133, 134, 135, 136, 137, 138, -1, + 140, -1, 142, 143, 144, -1, 146, -1, 148, -1, + -1, -1, 152, 153, 154, -1, 156, 157, -1, 159, + -1, 161, 162, 163, 164, 165, -1, 167, 168, 169, + -1, 171, 172, 173, 174, 175, 176, -1, 178, -1, + 180, 181, 182, 183, 184, 185, 186, -1, 188, -1, + 190, -1, -1, 193, -1, 195, 196, 197, 198, 199, + 200, 201, -1, 203, 204, -1, 206, -1, -1, 209, + 210, 211, -1, -1, 214, 215, 216, 217, 218, 219, + 220, 221, 222, 223, 224, 225, 226, -1, 228, 229, + 230, 231, -1, 233, 234, -1, 236, -1, 238, 239, + 240, 241, 242, 243, -1, 245, -1, 247, 248, 249, + 250, -1, -1, 253, -1, -1, -1, 257, 258, 259, + 260, 261, 262, 263, 264, -1, 266, 267, 268, 269, + 270, 271, 272, -1, 274, 275, 276, 277, 278, 279, + 280, 281, 282, 283, 284, 285, -1, 287, 288, 289, + 290, 291, 292, 293, 294, 295, 296, -1, 298, 299, + -1, 301, 302, 303, 304, 305, 306, 307, 308, 309, + 310, 311, -1, 313, 314, 315, 316, 317, -1, 319, + 320, 321, 322, -1, 324, 325, 326, -1, 328, 329, + 330, 331, 332, 333, 334, 335, 336, 337, 338, -1, + 340, 341, -1, 343, 344, 345, 346, 347, 348, -1, + 350, 351, -1, -1, 354, 355, 356, 357, -1, 359, + 360, 361, 362, 363, 364, 365, -1, -1, 368, 369, + 370, 371, 372, -1, -1, 375, 376, 377, 378, 379, + 380, 381, -1, 383, -1, 385, 386, 387, -1, -1, + 390, -1, -1, 393, 394, 395, 396, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 407, 408, 409, + 3, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 14, 15, 16, 17, 18, 19, 20, 21, 22, + 23, 24, 25, -1, -1, -1, -1, -1, -1, -1, + 33, 34, -1, 36, 37, -1, 39, 40, 41, 42, + 43, -1, 45, 46, -1, 48, 49, 50, 51, 52, + -1, -1, 55, 56, 57, 58, 59, -1, 61, 62, + 63, 64, 65, -1, -1, -1, 69, 70, 71, 72, + -1, 74, 75, -1, 77, 78, 79, 80, 81, 82, + -1, -1, 85, 86, -1, -1, -1, -1, -1, -1, + -1, 94, 95, 96, 97, 98, 99, 100, 101, 102, + -1, 104, -1, 106, 107, 108, 109, 110, -1, 112, + 113, 114, -1, -1, 117, 118, 119, 120, 121, -1, + 123, 124, 125, -1, 127, 128, -1, 130, 131, 132, + 133, 134, 135, 136, 137, 138, -1, 140, -1, 142, + 143, 144, -1, 146, -1, 148, -1, -1, -1, 152, + 153, 154, -1, 156, 157, -1, 159, -1, 161, 162, + 163, 164, 165, -1, 167, 168, 169, -1, 171, 172, + 173, 174, 175, 176, -1, 178, -1, 180, 181, 182, + 183, 184, 185, 186, -1, 188, -1, 190, -1, -1, + 193, -1, 195, 196, 197, 198, 199, 200, 201, -1, + 203, 204, -1, 206, -1, -1, 209, 210, 211, -1, + -1, 214, 215, 216, 217, 218, 219, 220, 221, 222, + 223, 224, 225, 226, -1, 228, 229, 230, 231, -1, + 233, 234, -1, 236, -1, 238, 239, 240, 241, 242, + 243, -1, 245, -1, -1, 248, 249, 250, -1, -1, + 253, -1, -1, -1, 257, 258, 259, 260, 261, 262, + 263, 264, -1, 266, 267, 268, 269, 270, 271, 272, + -1, 274, 275, 276, 277, 278, 279, 280, 281, 282, + 283, 284, 285, -1, 287, 288, 289, 290, 291, 292, + 293, 294, 295, 296, -1, 298, 299, -1, 301, 302, + 303, 304, 305, 306, 307, 308, 309, 310, 311, -1, + 313, 314, 315, 316, 317, -1, 319, 320, 321, 322, + -1, 324, 325, 326, -1, 328, 329, 330, 331, 332, + 333, 334, 335, 336, 337, 338, -1, 340, 341, -1, + 343, 344, 345, 346, 347, 348, -1, 350, 351, -1, + -1, 354, 355, 356, 357, -1, 359, 360, 361, 362, + 363, 364, 365, -1, -1, 368, 369, 370, 371, 372, + -1, -1, 375, 376, 377, 378, 379, 380, 381, -1, + 383, -1, 385, 386, 387, -1, -1, 390, -1, -1, + 393, 394, 395, 396, 397, 398, 399, 400, 401, 402, + 403, 404, 405, 406, 407, 408, 409, 3, -1, 5, + -1, -1, -1, -1, -1, -1, -1, -1, 14, 15, + 16, 17, 18, 19, 20, 21, -1, 23, 24, 25, + -1, -1, -1, -1, -1, -1, -1, 33, 34, -1, + 36, 37, -1, 39, 40, 41, 42, 43, -1, 45, + 46, -1, 48, 49, 50, 51, 52, -1, -1, 55, + 56, 57, 58, 59, -1, 61, 62, 63, 64, 65, + -1, -1, -1, 69, 70, 71, 72, -1, 74, 75, + -1, 77, 78, 79, 80, 81, 82, -1, -1, 85, + 86, -1, -1, -1, -1, -1, -1, -1, 94, 95, + 96, 97, 98, 99, 100, 101, 102, -1, 104, -1, + 106, 107, 108, 109, 110, -1, 112, 113, 114, -1, + -1, 117, 118, 119, 120, 121, -1, 123, 124, 125, + -1, 127, 128, -1, 130, 131, 132, 133, 134, 135, + 136, 137, 138, -1, 140, -1, 142, 143, 144, -1, + 146, -1, 148, -1, -1, -1, 152, 153, 154, -1, + 156, 157, -1, 159, -1, 161, 162, 163, 164, 165, + -1, 167, 168, 169, -1, 171, 172, 173, 174, 175, + 176, -1, 178, -1, 180, 181, 182, 183, 184, 185, + 186, -1, 188, -1, 190, -1, -1, 193, -1, 195, + 196, 197, 198, 199, 200, 201, -1, 203, 204, -1, + 206, -1, -1, 209, 210, 211, -1, -1, 214, 215, + 216, 217, 218, 219, 220, 221, 222, 223, 224, 225, + 226, -1, 228, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, 243, -1, 245, + -1, -1, 248, 249, 250, -1, -1, 253, -1, -1, + -1, 257, 258, 259, 260, 261, 262, 263, 264, -1, + 266, 267, 268, 269, 270, 271, 272, -1, 274, 275, + 276, 277, 278, 279, 280, 281, 282, 283, 284, 285, + -1, 287, 288, 289, 290, 291, 292, 293, 294, 295, + 296, -1, 298, 299, -1, 301, 302, 303, 304, 305, + 306, 307, 308, 309, 310, 311, -1, 313, 314, 315, + 316, 317, -1, 319, 320, 321, 322, -1, 324, 325, + 326, -1, 328, 329, 330, 331, 332, 333, 334, 335, + 336, 337, 338, -1, 340, 341, -1, 343, 344, 345, + 346, 347, 348, -1, 350, 351, -1, -1, 354, 355, + 356, 357, -1, 359, 360, 361, 362, 363, 364, 365, + -1, -1, 368, 369, 370, 371, 372, -1, -1, 375, + 376, 377, 378, 379, 380, 381, -1, 383, -1, 385, + 386, 387, -1, -1, 390, -1, -1, 393, 394, 395, + 396, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 407, 408, 409, 3, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 14, 15, 16, 17, 18, + 19, 20, 21, 22, 23, 24, 25, -1, -1, -1, + -1, -1, -1, -1, 33, 34, -1, 36, 37, -1, + 39, 40, 41, 42, 43, -1, 45, 46, -1, 48, + 49, 50, 51, 52, -1, -1, 55, 56, 57, 58, + 59, -1, 61, 62, 63, 64, 65, -1, -1, -1, + 69, 70, 71, 72, -1, 74, 75, -1, 77, 78, + 79, 80, 81, 82, -1, -1, 85, 86, -1, -1, + -1, -1, -1, -1, -1, 94, 95, 96, 97, 98, + 99, 100, 101, 102, -1, 104, -1, 106, 107, 108, + 109, 110, -1, 112, 113, 114, -1, -1, 117, 118, + 119, 120, 121, -1, 123, 124, 125, -1, 127, 128, + -1, 130, 131, 132, 133, 134, 135, 136, 137, 138, + -1, 140, -1, 142, 143, 144, -1, 146, -1, 148, + -1, -1, -1, 152, 153, 154, -1, 156, 157, -1, + 159, -1, 161, 162, 163, 164, 165, -1, 167, 168, + 169, -1, 171, 172, 173, 174, 175, 176, -1, 178, + -1, 180, 181, 182, 183, 184, 185, 186, -1, 188, + -1, 190, -1, -1, 193, -1, 195, 196, 197, 198, + 199, 200, 201, -1, 203, 204, -1, 206, -1, -1, + 209, 210, 211, -1, -1, 214, 215, 216, 217, 218, + 219, 220, 221, 222, 223, 224, 225, 226, -1, 228, + 229, 230, 231, -1, 233, 234, -1, 236, -1, 238, + 239, 240, 241, 242, 243, -1, 245, -1, -1, 248, + 249, 250, -1, -1, 253, -1, -1, -1, 257, 258, + 259, 260, 261, 262, 263, 264, -1, 266, 267, 268, + 269, 270, 271, 272, -1, 274, 275, 276, 277, 278, + 279, 280, 281, 282, 283, 284, 285, -1, 287, 288, + 289, 290, 291, 292, 293, 294, 295, 296, -1, 298, + 299, -1, 301, 302, 303, 304, 305, 306, 307, 308, + 309, 310, 311, -1, 313, 314, 315, 316, 317, -1, + 319, 320, 321, 322, -1, 324, 325, 326, -1, 328, + 329, 330, 331, 332, 333, 334, 335, 336, 337, 338, + -1, 340, 341, -1, 343, 344, 345, 346, 347, 348, + -1, 350, 351, -1, -1, 354, 355, 356, 357, -1, + 359, 360, 361, 362, 363, 364, 365, -1, -1, 368, + 369, 370, 371, 372, -1, -1, 375, 376, 377, 378, + 379, 380, 381, -1, 383, -1, 385, 386, 387, -1, + -1, 390, -1, -1, 393, 394, 395, 396, 397, 398, + 399, 400, 401, 402, 403, 404, 405, 406, 407, 408, + 409, 3, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 14, 15, 16, 17, 18, 19, 20, 21, + -1, 23, 24, 25, -1, -1, -1, -1, -1, -1, + -1, 33, 34, -1, 36, 37, 38, 39, 40, 41, + 42, 43, -1, 45, 46, -1, 48, 49, 50, 51, + 52, -1, -1, 55, 56, 57, 58, 59, -1, 61, + 62, 63, 64, 65, -1, -1, -1, 69, 70, 71, + 72, -1, 74, 75, -1, 77, 78, 79, 80, 81, + 82, -1, -1, 85, 86, -1, -1, -1, -1, -1, + -1, -1, 94, 95, 96, 97, 98, 99, 100, 101, + 102, -1, 104, -1, 106, 107, 108, 109, 110, -1, + 112, 113, 114, -1, -1, 117, 118, 119, 120, 121, + -1, 123, 124, 125, -1, 127, 128, -1, 130, 131, + 132, 133, 134, 135, 136, 137, 138, -1, 140, -1, + 142, 143, 144, -1, 146, -1, 148, -1, -1, -1, + 152, 153, 154, -1, 156, 157, -1, 159, -1, 161, + 162, 163, 164, 165, -1, 167, 168, 169, -1, 171, + 172, 173, 174, 175, 176, -1, 178, -1, 180, 181, + 182, 183, 184, 185, 186, -1, 188, -1, 190, -1, + -1, 193, -1, 195, 196, 197, 198, 199, 200, 201, + -1, 203, 204, -1, 206, -1, -1, 209, 210, 211, + -1, -1, 214, 215, 216, 217, 218, 219, 220, 221, + 222, 223, 224, 225, 226, -1, 228, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, 243, -1, 245, -1, -1, 248, 249, 250, -1, + -1, 253, -1, -1, -1, 257, 258, 259, 260, 261, + 262, 263, 264, -1, 266, 267, 268, 269, 270, 271, + 272, -1, 274, 275, 276, 277, 278, 279, 280, 281, + 282, 283, 284, 285, -1, 287, 288, 289, 290, 291, + 292, 293, 294, 295, 296, -1, 298, 299, -1, 301, + 302, 303, 304, 305, 306, 307, 308, 309, 310, 311, + -1, 313, 314, 315, 316, 317, -1, 319, 320, 321, + 322, -1, 324, 325, 326, -1, 328, 329, 330, 331, + 332, 333, 334, 335, 336, 337, 338, -1, 340, 341, + -1, 343, 344, 345, 346, 347, 348, -1, 350, 351, + -1, -1, 354, 355, 356, 357, -1, 359, 360, 361, + 362, 363, 364, 365, -1, -1, 368, 369, 370, 371, + 372, -1, -1, 375, 376, 377, 378, 379, 380, 381, + -1, 383, -1, 385, 386, 387, -1, -1, 390, -1, + -1, 393, 394, 395, 396, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 407, 408, 409, 3, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 14, + 15, 16, 17, 18, 19, 20, 21, -1, 23, 24, + 25, -1, -1, -1, -1, -1, -1, -1, 33, 34, + -1, 36, 37, -1, 39, 40, 41, 42, 43, -1, + 45, 46, -1, 48, 49, 50, 51, 52, -1, -1, + 55, 56, 57, 58, 59, -1, 61, 62, 63, 64, + 65, -1, -1, -1, 69, 70, 71, 72, -1, 74, + 75, -1, 77, 78, 79, 80, 81, 82, -1, -1, + 85, 86, -1, -1, -1, -1, -1, -1, -1, 94, + 95, 96, 97, 98, 99, 100, 101, 102, -1, 104, + -1, 106, 107, 108, 109, 110, -1, 112, 113, 114, + -1, -1, 117, 118, 119, 120, 121, -1, 123, 124, + 125, -1, 127, 128, -1, 130, 131, 132, 133, 134, + 135, 136, 137, 138, -1, 140, -1, 142, 143, 144, + -1, 146, -1, 148, -1, -1, -1, 152, 153, 154, + -1, 156, 157, -1, 159, -1, 161, 162, 163, 164, + 165, -1, 167, 168, 169, -1, 171, 172, 173, 174, + 175, 176, -1, 178, -1, 180, 181, 182, 183, 184, + 185, 186, -1, 188, -1, 190, -1, -1, 193, -1, + 195, 196, 197, 198, 199, 200, 201, -1, 203, 204, + -1, 206, -1, -1, 209, 210, 211, -1, -1, 214, + 215, 216, 217, 218, 219, 220, 221, 222, 223, 224, + 225, 226, -1, 228, 229, 230, 231, -1, 233, 234, + -1, 236, -1, 238, 239, 240, 241, 242, 243, -1, + 245, -1, 247, 248, 249, 250, -1, -1, 253, -1, + -1, -1, 257, 258, 259, 260, 261, 262, 263, 264, + -1, 266, 267, 268, 269, 270, 271, 272, -1, 274, + 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, + 285, -1, 287, 288, 289, 290, 291, 292, 293, 294, + 295, 296, -1, 298, 299, -1, 301, 302, 303, 304, + 305, 306, 307, 308, 309, 310, 311, -1, 313, 314, + 315, 316, 317, -1, 319, 320, 321, 322, -1, 324, + 325, 326, -1, 328, 329, 330, 331, 332, 333, 334, + 335, 336, 337, 338, -1, 340, 341, -1, 343, 344, + 345, 346, 347, 348, -1, 350, 351, -1, -1, 354, + 355, 356, 357, -1, 359, 360, 361, 362, 363, 364, + 365, -1, -1, 368, 369, 370, 371, 372, -1, -1, + 375, 376, 377, 378, 379, 380, 381, -1, 383, -1, + 385, 386, 387, -1, -1, 390, -1, -1, 393, 394, + 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 407, 408, 409, 3, -1, 5, -1, -1, + -1, -1, -1, -1, -1, -1, 14, 15, 16, 17, + 18, 19, 20, 21, -1, 23, 24, 25, -1, -1, + -1, -1, -1, -1, -1, 33, 34, -1, 36, 37, + -1, 39, 40, 41, 42, 43, -1, 45, 46, -1, + 48, 49, 50, 51, 52, -1, -1, 55, 56, 57, + 58, 59, -1, 61, 62, 63, 64, 65, -1, -1, + -1, 69, 70, 71, 72, -1, 74, 75, -1, 77, + 78, 79, 80, 81, 82, -1, -1, 85, 86, -1, + -1, -1, -1, -1, -1, -1, 94, 95, 96, 97, + 98, 99, 100, 101, 102, -1, 104, -1, 106, 107, + 108, 109, 110, -1, 112, 113, 114, -1, -1, 117, + 118, 119, 120, 121, -1, 123, 124, 125, -1, 127, + 128, -1, 130, 131, 132, 133, 134, 135, 136, 137, + 138, -1, 140, -1, 142, 143, 144, -1, 146, -1, + 148, -1, -1, -1, 152, 153, 154, -1, 156, 157, + -1, 159, -1, 161, 162, 163, 164, 165, -1, 167, + 168, 169, -1, 171, 172, 173, 174, 175, 176, -1, + 178, -1, 180, 181, 182, 183, 184, 185, 186, -1, + 188, -1, 190, -1, -1, 193, -1, 195, 196, 197, + 198, 199, 200, 201, -1, 203, 204, -1, 206, -1, + -1, 209, 210, 211, -1, -1, 214, 215, 216, 217, + 218, 219, 220, 221, 222, 223, 224, 225, 226, -1, + 228, 229, 230, 231, -1, 233, 234, -1, 236, -1, + 238, 239, 240, 241, 242, 243, -1, 245, -1, -1, + 248, 249, 250, -1, -1, 253, -1, -1, -1, 257, + 258, 259, 260, 261, 262, 263, 264, -1, 266, 267, + 268, 269, 270, 271, 272, -1, 274, 275, 276, 277, + 278, 279, 280, 281, 282, 283, 284, 285, -1, 287, + 288, 289, 290, 291, 292, 293, 294, 295, 296, -1, + 298, 299, -1, 301, 302, 303, 304, 305, 306, 307, + 308, 309, 310, 311, -1, 313, 314, 315, 316, 317, + -1, 319, 320, 321, 322, -1, 324, 325, 326, -1, + 328, 329, 330, 331, 332, 333, 334, 335, 336, 337, + 338, -1, 340, 341, -1, 343, 344, 345, 346, 347, + 348, -1, 350, 351, -1, -1, 354, 355, 356, 357, + -1, 359, 360, 361, 362, 363, 364, 365, -1, -1, + 368, 369, 370, 371, 372, -1, -1, 375, 376, 377, + 378, 379, 380, 381, -1, 383, -1, 385, 386, 387, + -1, -1, 390, -1, -1, 393, 394, 395, 396, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, + 408, 409, 3, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 14, 15, 16, 17, 18, 19, 20, + 21, -1, 23, 24, 25, -1, -1, -1, -1, -1, + -1, -1, 33, 34, -1, 36, 37, -1, 39, 40, + 41, 42, 43, -1, 45, 46, -1, 48, 49, 50, + 51, 52, -1, -1, 55, 56, 57, 58, 59, -1, + 61, 62, 63, 64, 65, -1, -1, -1, 69, 70, + 71, 72, -1, 74, 75, -1, 77, 78, 79, 80, + 81, 82, -1, -1, 85, 86, -1, -1, -1, -1, + -1, -1, -1, 94, 95, 96, 97, 98, 99, 100, + 101, 102, -1, 104, -1, 106, 107, 108, 109, 110, + -1, 112, 113, 114, -1, -1, 117, 118, 119, 120, + 121, -1, 123, 124, 125, -1, 127, 128, -1, 130, + 131, 132, 133, 134, 135, 136, 137, 138, -1, 140, + -1, 142, 143, 144, -1, 146, -1, 148, -1, -1, + -1, 152, 153, 154, -1, 156, 157, -1, 159, -1, + 161, 162, 163, 164, 165, -1, 167, 168, 169, -1, + 171, 172, 173, 174, 175, 176, -1, 178, -1, 180, + 181, 182, 183, 184, 185, 186, -1, 188, -1, 190, + -1, -1, 193, -1, 195, 196, 197, 198, 199, 200, + 201, -1, 203, 204, -1, 206, -1, -1, 209, 210, + 211, -1, -1, 214, 215, 216, 217, 218, 219, 220, + 221, 222, 223, 224, 225, 226, -1, 228, 229, 230, + 231, -1, 233, 234, -1, 236, -1, 238, 239, 240, + 241, 242, 243, -1, 245, -1, -1, 248, 249, 250, + -1, -1, 253, -1, -1, -1, 257, 258, 259, 260, + 261, 262, 263, 264, -1, 266, 267, 268, 269, 270, + 271, 272, -1, 274, 275, 276, 277, 278, 279, 280, + 281, 282, 283, 284, 285, -1, 287, 288, 289, 290, + 291, 292, 293, 294, 295, 296, -1, 298, 299, -1, + 301, 302, 303, 304, 305, 306, 307, 308, 309, 310, + 311, -1, 313, 314, 315, 316, 317, -1, 319, 320, + 321, 322, -1, 324, 325, 326, -1, 328, 329, 330, + 331, 332, 333, 334, 335, 336, 337, 338, -1, 340, + 341, 342, 343, 344, 345, 346, 347, 348, -1, 350, + 351, -1, -1, 354, 355, 356, 357, -1, 359, 360, + 361, 362, 363, 364, 365, -1, -1, 368, 369, 370, + 371, 372, -1, -1, 375, 376, 377, 378, 379, 380, + 381, -1, 383, -1, 385, 386, 387, -1, -1, 390, + -1, -1, 393, 394, 395, 396, 397, 398, 399, 400, + 401, 402, 403, 404, 405, 406, 407, 408, 409, 3, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, -1, -1, -1, 33, + 34, -1, 36, 37, -1, 39, 40, 41, 42, 43, + -1, 45, 46, -1, 48, 49, 50, 51, 52, -1, + -1, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, 65, -1, -1, -1, 69, 70, 71, 72, -1, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + -1, 85, 86, -1, -1, -1, -1, -1, -1, -1, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + 134, 135, 136, 137, 138, -1, 140, -1, 142, 143, + 144, -1, 146, -1, 148, -1, -1, -1, 152, 153, + 154, -1, 156, 157, 158, 159, -1, 161, 162, 163, + 164, 165, -1, 167, 168, 169, -1, 171, 172, 173, + 174, 175, 176, -1, 178, -1, 180, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, -1, -1, 193, + -1, 195, 196, 197, 198, 199, 200, 201, -1, 203, + 204, -1, 206, -1, -1, 209, 210, 211, -1, -1, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, -1, 228, 229, 230, 231, -1, 233, + 234, -1, 236, -1, 238, 239, 240, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, 253, + -1, -1, -1, 257, 258, 259, 260, 261, 262, 263, + 264, -1, 266, 267, 268, 269, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, -1, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, -1, 313, + 314, 315, 316, 317, -1, 319, 320, 321, 322, -1, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, 338, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, 355, 356, 357, -1, 359, 360, 361, 362, 363, + 364, 365, -1, -1, 368, 369, 370, 371, 372, -1, + -1, 375, 376, 377, 378, 379, 380, 381, -1, 383, + -1, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 407, 408, 409, 3, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 14, 15, 16, + 17, 18, 19, 20, 21, -1, 23, 24, 25, -1, + -1, -1, -1, -1, 31, -1, 33, 34, -1, 36, + 37, -1, 39, 40, 41, 42, 43, -1, 45, 46, + -1, 48, 49, 50, 51, 52, -1, -1, 55, 56, + 57, 58, 59, -1, 61, 62, 63, 64, 65, -1, + -1, -1, 69, 70, 71, 72, -1, 74, 75, -1, + 77, 78, 79, 80, 81, 82, -1, -1, 85, 86, + -1, -1, -1, -1, -1, -1, -1, 94, 95, 96, + 97, 98, 99, 100, 101, 102, -1, 104, -1, 106, + 107, 108, 109, 110, -1, 112, 113, 114, -1, -1, + 117, 118, 119, 120, 121, -1, 123, 124, 125, -1, + 127, 128, -1, 130, 131, 132, 133, 134, 135, 136, + 137, 138, -1, 140, -1, 142, 143, 144, -1, 146, + -1, 148, -1, -1, -1, 152, 153, 154, -1, 156, + 157, -1, 159, -1, 161, 162, 163, 164, 165, -1, + 167, 168, 169, -1, 171, 172, 173, 174, 175, 176, + -1, 178, -1, 180, 181, 182, 183, 184, 185, 186, + -1, 188, -1, 190, -1, -1, 193, -1, 195, 196, + 197, 198, 199, 200, 201, -1, 203, 204, -1, 206, + -1, -1, 209, 210, 211, -1, -1, 214, 215, 216, + 217, 218, 219, 220, 221, 222, 223, 224, 225, 226, + -1, 228, 229, 230, 231, -1, 233, 234, -1, 236, + -1, 238, 239, 240, 241, 242, 243, -1, 245, -1, + -1, 248, 249, 250, -1, -1, 253, -1, -1, -1, + 257, 258, 259, 260, 261, 262, 263, 264, -1, 266, + 267, 268, 269, 270, 271, 272, -1, 274, 275, 276, + 277, 278, 279, 280, 281, 282, 283, 284, 285, -1, + 287, 288, 289, 290, 291, 292, 293, 294, 295, 296, + -1, 298, 299, -1, 301, 302, 303, 304, 305, 306, + 307, 308, 309, 310, 311, -1, 313, 314, 315, 316, + 317, -1, 319, 320, 321, 322, -1, 324, 325, 326, + -1, 328, 329, 330, 331, 332, 333, 334, 335, 336, + 337, 338, -1, 340, 341, -1, 343, 344, 345, 346, + 347, 348, -1, 350, 351, -1, -1, 354, 355, 356, + 357, -1, 359, 360, 361, 362, 363, 364, 365, -1, + -1, 368, 369, 370, 371, 372, -1, -1, 375, 376, + 377, 378, 379, 380, 381, -1, 383, -1, 385, 386, + 387, -1, -1, 390, -1, -1, 393, 394, 395, 396, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 407, 408, 409, 3, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 14, 15, 16, 17, 18, 19, + 20, 21, -1, 23, 24, 25, -1, -1, -1, -1, + -1, 31, -1, 33, 34, -1, 36, 37, -1, 39, + 40, 41, 42, 43, -1, 45, 46, -1, 48, 49, + 50, 51, 52, -1, -1, 55, 56, 57, 58, 59, + -1, 61, 62, 63, 64, 65, -1, -1, -1, 69, + 70, 71, 72, -1, 74, 75, -1, 77, 78, 79, + 80, 81, 82, -1, -1, 85, 86, -1, -1, -1, + -1, -1, -1, -1, 94, 95, 96, 97, 98, 99, + 100, 101, 102, -1, 104, -1, 106, 107, 108, 109, + 110, -1, 112, 113, 114, -1, -1, 117, 118, 119, + 120, 121, -1, 123, 124, 125, -1, 127, 128, -1, + 130, 131, 132, 133, 134, 135, 136, 137, 138, -1, + 140, -1, 142, 143, 144, -1, 146, -1, 148, -1, + -1, -1, 152, 153, 154, -1, 156, 157, -1, 159, + -1, 161, 162, 163, 164, 165, -1, 167, 168, 169, + -1, 171, 172, 173, 174, 175, 176, -1, 178, -1, + 180, 181, 182, 183, 184, 185, 186, -1, 188, -1, + 190, -1, -1, 193, -1, 195, 196, 197, 198, 199, + 200, 201, -1, 203, 204, -1, 206, -1, -1, 209, + 210, 211, -1, -1, 214, 215, 216, 217, 218, 219, + 220, 221, 222, 223, 224, 225, 226, -1, 228, 229, + 230, 231, -1, 233, 234, -1, 236, -1, 238, 239, + 240, 241, 242, 243, -1, 245, -1, -1, 248, 249, + 250, -1, -1, 253, -1, -1, -1, 257, 258, 259, + 260, 261, 262, 263, 264, -1, 266, 267, 268, 269, + 270, 271, 272, -1, 274, 275, 276, 277, 278, 279, + 280, 281, 282, 283, 284, 285, -1, 287, 288, 289, + 290, 291, 292, 293, 294, 295, 296, -1, 298, 299, + -1, 301, 302, 303, 304, 305, 306, 307, 308, 309, + 310, 311, -1, 313, 314, 315, 316, 317, -1, 319, + 320, 321, 322, -1, 324, 325, 326, -1, 328, 329, + 330, 331, 332, 333, 334, 335, 336, 337, 338, -1, + 340, 341, -1, 343, 344, 345, 346, 347, 348, -1, + 350, 351, -1, -1, 354, 355, 356, 357, -1, 359, + 360, 361, 362, 363, 364, 365, -1, -1, 368, 369, + 370, 371, 372, -1, -1, 375, 376, 377, 378, 379, + 380, 381, -1, 383, -1, 385, 386, 387, -1, -1, + 390, -1, -1, 393, 394, 395, 396, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 407, 408, 409, + 3, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 14, 15, 16, 17, 18, 19, 20, 21, -1, + 23, 24, 25, -1, -1, -1, -1, -1, -1, -1, + 33, 34, -1, 36, 37, -1, 39, 40, 41, 42, + 43, -1, 45, 46, -1, 48, 49, 50, 51, 52, + -1, -1, 55, 56, 57, 58, 59, -1, 61, 62, + 63, 64, 65, -1, -1, -1, 69, 70, 71, 72, + -1, 74, 75, -1, 77, 78, 79, 80, 81, 82, + -1, -1, 85, 86, -1, -1, -1, -1, -1, -1, + -1, 94, 95, 96, 97, 98, 99, 100, 101, 102, + 103, 104, -1, 106, 107, 108, 109, 110, -1, 112, + 113, 114, -1, -1, 117, 118, 119, 120, 121, -1, + 123, 124, 125, -1, 127, 128, -1, 130, 131, 132, + 133, 134, 135, 136, 137, 138, -1, 140, -1, 142, + 143, 144, -1, 146, -1, 148, -1, -1, -1, 152, + 153, 154, -1, 156, 157, -1, 159, -1, 161, 162, + 163, 164, 165, -1, 167, 168, 169, -1, 171, 172, + 173, 174, 175, 176, -1, 178, -1, 180, 181, 182, + 183, 184, 185, 186, -1, 188, -1, 190, -1, -1, + 193, -1, 195, 196, 197, 198, 199, 200, 201, -1, + 203, 204, -1, 206, -1, -1, 209, 210, 211, -1, + -1, 214, 215, 216, 217, 218, 219, 220, 221, 222, + 223, 224, 225, 226, -1, 228, 229, 230, 231, -1, + 233, 234, -1, 236, -1, 238, 239, 240, 241, 242, + 243, -1, 245, -1, -1, 248, 249, 250, -1, -1, + 253, -1, -1, -1, 257, 258, 259, 260, 261, 262, + 263, 264, -1, 266, 267, 268, 269, 270, 271, 272, + -1, 274, 275, 276, 277, 278, 279, 280, 281, 282, + 283, 284, 285, -1, 287, 288, 289, 290, 291, 292, + 293, 294, 295, 296, -1, 298, 299, -1, 301, 302, + 303, 304, 305, 306, 307, 308, 309, 310, 311, -1, + 313, 314, 315, 316, 317, -1, 319, 320, 321, 322, + -1, 324, 325, 326, -1, 328, 329, 330, 331, 332, + 333, 334, 335, 336, 337, 338, -1, 340, 341, -1, + 343, 344, 345, 346, 347, 348, -1, 350, 351, -1, + -1, 354, 355, 356, 357, -1, 359, 360, 361, 362, + 363, 364, 365, -1, -1, 368, 369, 370, 371, 372, + -1, -1, 375, 376, 377, 378, 379, 380, 381, -1, + 383, -1, 385, 386, 387, -1, -1, 390, -1, -1, + 393, 394, 395, 396, 397, 398, 399, 400, 401, 402, + 403, 404, 405, 406, 407, 408, 409, 3, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 14, 15, + 16, 17, 18, 19, 20, 21, -1, 23, 24, 25, + -1, -1, -1, -1, -1, -1, -1, 33, 34, -1, + 36, 37, -1, 39, 40, 41, 42, 43, -1, 45, + 46, -1, 48, 49, 50, 51, 52, -1, -1, 55, + 56, 57, 58, 59, -1, 61, 62, 63, 64, 65, + -1, -1, -1, 69, 70, 71, 72, -1, 74, 75, + -1, 77, 78, 79, 80, 81, 82, -1, -1, 85, + 86, -1, -1, -1, -1, -1, -1, -1, 94, 95, + 96, 97, 98, 99, 100, 101, 102, 103, 104, -1, + 106, 107, 108, 109, 110, -1, 112, 113, 114, -1, + -1, 117, 118, 119, 120, 121, -1, 123, 124, 125, + -1, 127, 128, -1, 130, 131, 132, 133, 134, 135, + 136, 137, 138, -1, 140, -1, 142, 143, 144, -1, + 146, -1, 148, -1, -1, -1, 152, 153, 154, -1, + 156, 157, -1, 159, -1, 161, 162, 163, 164, 165, + -1, 167, 168, 169, -1, 171, 172, 173, 174, 175, + 176, -1, 178, -1, 180, 181, 182, 183, 184, 185, + 186, -1, 188, -1, 190, -1, -1, 193, -1, 195, + 196, 197, 198, 199, 200, 201, -1, 203, 204, -1, + 206, -1, -1, 209, 210, 211, -1, -1, 214, 215, + 216, 217, 218, 219, 220, 221, 222, 223, 224, 225, + 226, -1, 228, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, 243, -1, 245, + -1, -1, 248, 249, 250, -1, -1, 253, -1, -1, + -1, 257, 258, 259, 260, 261, 262, 263, 264, -1, + 266, 267, 268, 269, 270, 271, 272, -1, 274, 275, + 276, 277, 278, 279, 280, 281, 282, 283, 284, 285, + -1, 287, 288, 289, 290, 291, 292, 293, 294, 295, + 296, -1, 298, 299, -1, 301, 302, 303, 304, 305, + 306, 307, 308, 309, 310, 311, -1, 313, 314, 315, + 316, 317, -1, 319, 320, 321, 322, -1, 324, 325, + 326, -1, 328, 329, 330, 331, 332, 333, 334, 335, + 336, 337, 338, -1, 340, 341, -1, 343, 344, 345, + 346, 347, 348, -1, 350, 351, -1, -1, 354, 355, + 356, 357, -1, 359, 360, 361, 362, 363, 364, 365, + -1, -1, 368, 369, 370, 371, 372, -1, -1, 375, + 376, 377, 378, 379, 380, 381, -1, 383, -1, 385, + 386, 387, -1, -1, 390, -1, -1, 393, 394, 395, + 396, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 407, 408, 409, 3, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 14, 15, 16, 17, 18, + 19, 20, 21, -1, 23, 24, 25, -1, -1, -1, + -1, -1, -1, -1, 33, 34, -1, 36, 37, -1, + 39, 40, 41, 42, 43, -1, 45, 46, -1, 48, + 49, 50, 51, 52, -1, -1, 55, 56, 57, 58, + 59, -1, 61, 62, 63, 64, 65, -1, -1, -1, + 69, 70, 71, 72, -1, 74, 75, -1, 77, 78, + 79, 80, 81, 82, -1, -1, 85, 86, -1, -1, + -1, -1, -1, -1, -1, 94, 95, 96, 97, 98, + 99, 100, 101, 102, 103, 104, -1, 106, 107, 108, + 109, 110, -1, 112, 113, 114, -1, -1, 117, 118, + 119, 120, 121, -1, 123, 124, 125, -1, 127, 128, + -1, 130, 131, 132, 133, 134, 135, 136, 137, 138, + -1, 140, -1, 142, 143, 144, -1, 146, -1, 148, + -1, -1, -1, 152, 153, 154, -1, 156, 157, -1, + 159, -1, 161, 162, 163, 164, 165, -1, 167, 168, + 169, -1, 171, 172, 173, 174, 175, 176, -1, 178, + -1, 180, 181, 182, 183, 184, 185, 186, -1, 188, + -1, 190, -1, -1, 193, -1, 195, 196, 197, 198, + 199, 200, 201, -1, 203, 204, -1, 206, -1, -1, + 209, 210, 211, -1, -1, 214, 215, 216, 217, 218, + 219, 220, 221, 222, 223, 224, 225, 226, -1, 228, + 229, 230, 231, -1, 233, 234, -1, 236, -1, 238, + 239, 240, 241, 242, 243, -1, 245, -1, -1, 248, + 249, 250, -1, -1, 253, -1, -1, -1, 257, 258, + 259, 260, 261, 262, 263, 264, -1, 266, 267, 268, + 269, 270, 271, 272, -1, 274, 275, 276, 277, 278, + 279, 280, 281, 282, 283, 284, 285, -1, 287, 288, + 289, 290, 291, 292, 293, 294, 295, 296, -1, 298, + 299, -1, 301, 302, 303, 304, 305, 306, 307, 308, + 309, 310, 311, -1, 313, 314, 315, 316, 317, -1, + 319, 320, 321, 322, -1, 324, 325, 326, -1, 328, + 329, 330, 331, 332, 333, 334, 335, 336, 337, 338, + -1, 340, 341, -1, 343, 344, 345, 346, 347, 348, + -1, 350, 351, -1, -1, 354, 355, 356, 357, -1, + 359, 360, 361, 362, 363, 364, 365, -1, -1, 368, + 369, 370, 371, 372, -1, -1, 375, 376, 377, 378, + 379, 380, 381, -1, 383, -1, 385, 386, 387, -1, + -1, 390, -1, -1, 393, 394, 395, 396, 397, 398, + 399, 400, 401, 402, 403, 404, 405, 406, 407, 408, + 409, 3, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 14, 15, 16, 17, 18, 19, 20, 21, + -1, 23, 24, 25, -1, -1, -1, -1, -1, -1, + -1, 33, 34, -1, 36, 37, -1, 39, 40, 41, + 42, 43, -1, 45, 46, -1, 48, 49, 50, 51, + 52, -1, -1, 55, 56, 57, 58, 59, -1, 61, + 62, 63, 64, 65, -1, -1, -1, 69, 70, 71, + 72, -1, 74, 75, -1, 77, 78, 79, 80, 81, + 82, -1, -1, 85, 86, -1, -1, -1, -1, -1, + -1, -1, 94, 95, 96, 97, 98, 99, 100, 101, + 102, -1, 104, -1, 106, 107, 108, 109, 110, -1, + 112, 113, 114, -1, -1, 117, 118, 119, 120, 121, + -1, 123, 124, 125, -1, 127, 128, -1, 130, 131, + 132, 133, 134, 135, 136, 137, 138, -1, 140, -1, + 142, 143, 144, -1, 146, -1, 148, -1, -1, -1, + 152, 153, 154, -1, 156, 157, -1, 159, -1, 161, + 162, 163, 164, 165, -1, 167, 168, 169, -1, 171, + 172, 173, 174, 175, 176, -1, 178, -1, 180, 181, + 182, 183, 184, 185, 186, -1, 188, -1, 190, -1, + -1, 193, -1, 195, 196, 197, 198, 199, 200, 201, + -1, 203, 204, -1, 206, -1, -1, 209, 210, 211, + -1, -1, 214, 215, 216, 217, 218, 219, 220, 221, + 222, 223, 224, 225, 226, -1, 228, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, 243, -1, 245, -1, -1, 248, 249, 250, -1, + -1, 253, -1, -1, -1, 257, 258, 259, 260, 261, + 262, 263, 264, -1, 266, 267, 268, 269, 270, 271, + 272, -1, 274, 275, 276, 277, 278, 279, 280, 281, + 282, 283, 284, 285, -1, 287, 288, 289, 290, 291, + 292, 293, 294, 295, 296, -1, 298, 299, -1, 301, + 302, 303, 304, 305, 306, 307, 308, 309, 310, 311, + -1, 313, 314, 315, 316, 317, -1, 319, 320, 321, + 322, -1, 324, 325, 326, -1, 328, 329, 330, 331, + 332, 333, 334, 335, 336, 337, 338, -1, 340, 341, + -1, 343, 344, 345, 346, 347, 348, -1, 350, 351, + -1, -1, 354, 355, 356, 357, -1, 359, 360, 361, + 362, 363, 364, 365, -1, -1, 368, 369, 370, 371, + 372, -1, 374, 375, 376, 377, 378, 379, 380, 381, + -1, 383, -1, 385, 386, 387, -1, -1, 390, -1, + -1, 393, 394, 395, 396, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 407, 408, 409, 3, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 14, + 15, 16, 17, 18, 19, 20, 21, -1, 23, 24, + 25, -1, -1, -1, -1, -1, -1, -1, 33, 34, + -1, 36, 37, -1, 39, 40, 41, 42, 43, -1, + 45, 46, -1, 48, 49, 50, 51, 52, -1, -1, + 55, 56, 57, 58, 59, -1, 61, 62, 63, 64, + 65, -1, -1, -1, 69, 70, 71, 72, -1, 74, + 75, -1, 77, 78, 79, 80, 81, 82, -1, -1, + 85, 86, -1, -1, -1, -1, -1, -1, -1, 94, + 95, 96, 97, 98, 99, 100, 101, 102, -1, 104, + -1, 106, 107, 108, 109, 110, -1, 112, 113, 114, + -1, -1, 117, 118, 119, 120, 121, -1, 123, 124, + 125, -1, 127, 128, -1, 130, 131, 132, 133, 134, + 135, 136, 137, 138, -1, 140, -1, 142, 143, 144, + -1, 146, -1, 148, -1, -1, -1, 152, 153, 154, + -1, 156, 157, -1, 159, -1, 161, 162, 163, 164, + 165, -1, 167, 168, 169, -1, 171, 172, 173, 174, + 175, 176, -1, 178, -1, 180, 181, 182, 183, 184, + 185, 186, -1, 188, -1, 190, -1, -1, 193, -1, + 195, 196, 197, 198, 199, 200, 201, -1, 203, 204, + -1, 206, -1, -1, 209, 210, 211, -1, -1, 214, + 215, 216, 217, 218, 219, 220, 221, 222, 223, 224, + 225, 226, -1, 228, 229, 230, 231, -1, 233, 234, + -1, 236, -1, 238, 239, 240, 241, 242, 243, -1, + 245, -1, -1, 248, 249, 250, -1, -1, 253, -1, + -1, -1, 257, 258, 259, 260, 261, 262, 263, 264, + -1, 266, 267, 268, 269, 270, 271, 272, -1, 274, + 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, + 285, -1, 287, 288, 289, 290, 291, 292, 293, 294, + 295, 296, -1, 298, 299, -1, 301, 302, 303, 304, + 305, 306, 307, 308, 309, 310, 311, -1, 313, 314, + 315, 316, 317, -1, 319, 320, 321, 322, -1, 324, + 325, 326, -1, 328, 329, 330, 331, 332, 333, 334, + 335, 336, 337, 338, -1, 340, 341, -1, 343, 344, + 345, 346, 347, 348, -1, 350, 351, -1, -1, 354, + 355, 356, 357, -1, 359, 360, 361, 362, 363, 364, + 365, -1, -1, 368, 369, 370, 371, 372, -1, -1, + 375, 376, 377, 378, 379, 380, 381, -1, 383, -1, + 385, 386, 387, -1, -1, 390, -1, -1, 393, 394, + 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 407, 408, 409, 3, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 14, 15, 16, 17, + 18, 19, 20, 21, -1, 23, 24, 25, -1, -1, + -1, -1, -1, -1, -1, 33, 34, -1, 36, 37, + -1, 39, 40, 41, 42, 43, -1, 45, 46, -1, + 48, 49, 50, 51, 52, -1, -1, 55, 56, 57, + 58, 59, -1, 61, 62, 63, 64, 65, -1, -1, + -1, 69, 70, 71, 72, -1, 74, 75, -1, 77, + 78, 79, 80, 81, 82, -1, -1, 85, 86, -1, + -1, -1, -1, -1, -1, -1, 94, 95, 96, 97, + 98, 99, 100, 101, 102, -1, 104, -1, 106, 107, + 108, 109, 110, -1, 112, 113, 114, -1, -1, 117, + 118, 119, 120, 121, -1, 123, 124, 125, -1, 127, + 128, -1, 130, 131, 132, 133, 134, 135, 136, 137, + 138, -1, 140, -1, 142, 143, 144, -1, 146, -1, + 148, -1, -1, -1, 152, 153, 154, -1, 156, 157, + -1, 159, -1, 161, 162, 163, 164, 165, -1, 167, + 168, 169, -1, 171, 172, 173, 174, 175, 176, -1, + 178, -1, 180, 181, 182, 183, 184, 185, 186, -1, + 188, -1, 190, -1, -1, 193, -1, 195, 196, 197, + 198, 199, 200, 201, -1, 203, 204, -1, 206, -1, + -1, 209, 210, 211, -1, -1, 214, 215, 216, 217, + 218, 219, 220, 221, 222, 223, 224, 225, 226, -1, + 228, 229, 230, 231, -1, 233, 234, -1, 236, -1, + 238, 239, 240, 241, 242, 243, -1, 245, -1, -1, + 248, 249, 250, -1, -1, 253, -1, -1, -1, 257, + 258, 259, 260, 261, 262, 263, 264, -1, 266, 267, + 268, 269, 270, 271, 272, -1, 274, 275, 276, 277, + 278, 279, 280, 281, 282, 283, 284, 285, -1, 287, + 288, 289, 290, 291, 292, 293, 294, 295, 296, -1, + 298, 299, -1, 301, 302, 303, 304, 305, 306, 307, + 308, 309, 310, 311, -1, 313, 314, 315, 316, 317, + -1, 319, 320, 321, 322, -1, 324, 325, 326, -1, + 328, 329, 330, 331, 332, 333, 334, 335, 336, 337, + 338, -1, 340, 341, -1, 343, 344, 345, 346, 347, + 348, -1, 350, 351, -1, -1, 354, 355, 356, 357, + -1, 359, 360, 361, 362, 363, 364, 365, -1, -1, + 368, 369, 370, 371, 372, -1, -1, 375, 376, 377, + 378, 379, 380, 381, -1, 383, -1, 385, 386, 387, + -1, -1, 390, -1, -1, 393, 394, 395, 396, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, + 408, 409, 3, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 14, 15, 16, 17, 18, 19, 20, + 21, -1, 23, 24, 25, -1, -1, -1, -1, -1, + -1, -1, 33, 34, -1, 36, 37, -1, 39, 40, + 41, 42, 43, -1, 45, 46, -1, 48, 49, 50, + 51, 52, -1, -1, 55, 56, 57, 58, 59, -1, + 61, 62, 63, 64, 65, -1, -1, -1, 69, 70, + 71, 72, -1, 74, 75, -1, 77, 78, 79, 80, + 81, 82, -1, -1, 85, 86, -1, -1, -1, -1, + -1, -1, -1, 94, 95, 96, 97, 98, 99, 100, + 101, 102, -1, 104, -1, 106, 107, 108, 109, 110, + -1, 112, 113, 114, -1, -1, 117, 118, 119, 120, + 121, -1, 123, 124, 125, -1, 127, 128, -1, 130, + 131, 132, 133, 134, 135, 136, 137, 138, -1, 140, + -1, 142, 143, 144, -1, 146, -1, 148, -1, -1, + -1, 152, 153, 154, -1, 156, 157, -1, 159, -1, + 161, 162, 163, 164, 165, -1, 167, 168, 169, -1, + 171, 172, 173, 174, 175, 176, -1, 178, -1, 180, + 181, 182, 183, 184, 185, 186, -1, 188, -1, 190, + -1, -1, 193, -1, 195, 196, 197, 198, 199, 200, + 201, -1, 203, 204, -1, 206, -1, -1, 209, 210, + 211, -1, -1, 214, 215, 216, 217, 218, 219, 220, + 221, 222, 223, 224, 225, 226, -1, 228, 229, 230, + 231, -1, 233, 234, -1, 236, -1, 238, 239, 240, + 241, 242, 243, -1, 245, -1, -1, 248, 249, 250, + -1, -1, 253, -1, -1, -1, 257, 258, 259, 260, + 261, 262, 263, 264, -1, 266, 267, 268, 269, 270, + 271, 272, -1, 274, 275, 276, 277, 278, 279, 280, + 281, 282, 283, 284, 285, -1, 287, 288, 289, 290, + 291, 292, 293, 294, 295, 296, -1, 298, 299, -1, + 301, 302, 303, 304, 305, 306, 307, 308, 309, 310, + 311, -1, 313, 314, 315, 316, 317, -1, 319, 320, + 321, 322, -1, 324, 325, 326, -1, 328, 329, 330, + 331, 332, 333, 334, 335, 336, 337, 338, -1, 340, + 341, -1, 343, 344, 345, 346, 347, 348, -1, 350, + 351, -1, -1, 354, 355, 356, 357, -1, 359, 360, + 361, 362, 363, 364, 365, -1, -1, 368, 369, 370, + 371, 372, -1, -1, 375, 376, 377, 378, 379, 380, + 381, -1, 383, -1, 385, 386, 387, -1, -1, 390, + -1, -1, 393, 394, 395, 396, 397, 398, 399, 400, + 401, 402, 403, 404, 405, 406, 407, 408, 409, 3, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, -1, -1, -1, 33, + 34, -1, 36, 37, -1, 39, 40, 41, 42, 43, + -1, 45, 46, -1, 48, 49, 50, 51, 52, -1, + -1, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, 65, -1, -1, -1, 69, 70, 71, 72, -1, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + -1, 85, 86, -1, -1, -1, -1, -1, -1, -1, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + 134, 135, 136, 137, 138, -1, 140, -1, 142, 143, + 144, -1, 146, -1, 148, -1, -1, -1, 152, 153, + 154, -1, 156, 157, -1, 159, -1, 161, 162, 163, + 164, 165, -1, 167, 168, 169, -1, 171, 172, 173, + 174, 175, 176, -1, 178, -1, 180, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, -1, -1, 193, + -1, 195, 196, 197, 198, 199, 200, 201, -1, 203, + 204, -1, 206, -1, -1, 209, 210, 211, -1, -1, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, -1, 228, 229, 230, 231, -1, 233, + 234, -1, 236, -1, 238, 239, 240, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, 253, + -1, -1, -1, 257, 258, 259, 260, 261, 262, 263, + 264, -1, 266, 267, 268, 269, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, -1, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, -1, 313, + 314, 315, 316, 317, -1, 319, 320, 321, 322, -1, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, 338, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, 355, 356, 357, -1, 359, 360, 361, 362, 363, + 364, 365, -1, -1, 368, 369, 370, 371, 372, -1, + -1, 375, 376, 377, 378, 379, 380, 381, -1, 383, + -1, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 407, 408, 409, 3, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 14, 15, 16, + 17, 18, 19, 20, 21, -1, 23, 24, 25, -1, + -1, -1, -1, -1, -1, -1, 33, 34, -1, 36, + 37, -1, 39, 40, 41, 42, 43, -1, 45, 46, + -1, 48, 49, 50, 51, 52, -1, -1, 55, 56, + 57, 58, 59, -1, 61, 62, 63, 64, 65, -1, + -1, -1, 69, 70, 71, 72, -1, 74, 75, -1, + 77, 78, 79, 80, 81, 82, -1, -1, 85, 86, + -1, -1, -1, -1, -1, -1, -1, 94, 95, 96, + 97, 98, 99, 100, 101, 102, -1, 104, -1, 106, + 107, 108, 109, 110, -1, 112, 113, 114, -1, -1, + 117, 118, 119, 120, 121, -1, 123, 124, 125, -1, + 127, 128, -1, 130, 131, 132, 133, 134, 135, 136, + 137, 138, -1, 140, -1, 142, 143, 144, -1, 146, + -1, 148, -1, -1, -1, 152, 153, 154, -1, 156, + 157, -1, 159, -1, 161, 162, 163, 164, 165, -1, + 167, 168, 169, -1, 171, 172, 173, 174, 175, 176, + -1, 178, -1, 180, 181, 182, 183, 184, 185, 186, + -1, 188, -1, 190, -1, -1, 193, -1, 195, 196, + 197, 198, 199, 200, 201, -1, 203, 204, -1, 206, + -1, -1, 209, 210, 211, -1, -1, 214, 215, 216, + 217, 218, 219, 220, 221, 222, 223, 224, 225, 226, + -1, 228, 229, 230, 231, -1, 233, 234, -1, 236, + -1, 238, 239, 240, 241, 242, 243, -1, 245, -1, + -1, 248, 249, 250, -1, -1, 253, -1, -1, -1, + 257, 258, 259, 260, 261, 262, 263, 264, -1, 266, + 267, 268, 269, 270, 271, 272, -1, 274, 275, 276, + 277, 278, 279, 280, 281, 282, 283, 284, 285, -1, + 287, 288, 289, 290, 291, 292, 293, 294, 295, 296, + -1, 298, 299, -1, 301, 302, 303, 304, 305, 306, + 307, 308, 309, 310, 311, -1, 313, 314, 315, 316, + 317, -1, 319, 320, 321, 322, -1, 324, 325, 326, + -1, 328, 329, 330, 331, 332, 333, 334, 335, 336, + 337, 338, -1, 340, 341, -1, 343, 344, 345, 346, + 347, 348, -1, 350, 351, -1, -1, 354, 355, 356, + 357, -1, 359, 360, 361, 362, 363, 364, 365, -1, + -1, 368, 369, 370, 371, 372, -1, -1, 375, 376, + 377, 378, 379, 380, 381, -1, 383, -1, 385, 386, + 387, -1, -1, 390, -1, -1, 393, 394, 395, 396, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 407, 408, 409, 3, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 14, 15, 16, 17, 18, 19, + 20, 21, -1, 23, 24, 25, -1, -1, -1, -1, + -1, -1, -1, 33, 34, -1, 36, 37, -1, 39, + 40, 41, 42, 43, -1, 45, 46, -1, 48, 49, + 50, 51, 52, -1, -1, 55, 56, 57, 58, 59, + -1, 61, 62, 63, 64, 65, -1, -1, -1, 69, + 70, 71, 72, -1, 74, 75, -1, 77, 78, 79, + 80, 81, 82, -1, -1, 85, 86, -1, -1, -1, + -1, -1, -1, -1, 94, 95, 96, 97, 98, 99, + 100, 101, 102, -1, 104, -1, 106, 107, 108, 109, + 110, -1, 112, 113, 114, -1, -1, 117, 118, 119, + 120, 121, -1, 123, 124, 125, -1, 127, 128, -1, + 130, 131, 132, 133, 134, 135, 136, 137, 138, -1, + 140, -1, 142, 143, 144, -1, 146, -1, 148, -1, + -1, -1, 152, 153, 154, -1, 156, 157, -1, 159, + -1, 161, 162, 163, 164, 165, -1, 167, 168, 169, + -1, 171, 172, 173, 174, 175, 176, -1, 178, -1, + 180, 181, 182, 183, 184, 185, 186, -1, 188, -1, + 190, -1, -1, 193, -1, 195, 196, 197, 198, 199, + 200, 201, -1, 203, 204, -1, 206, -1, -1, 209, + 210, 211, -1, -1, 214, 215, 216, 217, 218, 219, + 220, 221, 222, 223, 224, 225, 226, -1, 228, 229, + 230, 231, -1, 233, 234, -1, 236, -1, 238, 239, + 240, 241, 242, 243, -1, 245, -1, -1, 248, 249, + 250, -1, -1, 253, -1, -1, -1, 257, 258, 259, + 260, 261, 262, 263, 264, -1, 266, 267, 268, 269, + 270, 271, 272, -1, 274, 275, 276, 277, 278, 279, + 280, 281, 282, 283, 284, 285, -1, 287, 288, 289, + 290, 291, 292, 293, 294, 295, 296, -1, 298, 299, + -1, 301, 302, 303, 304, 305, 306, 307, 308, 309, + 310, 311, -1, 313, 314, 315, 316, 317, -1, 319, + 320, 321, 322, -1, 324, 325, 326, -1, 328, 329, + 330, 331, 332, 333, 334, 335, 336, 337, 338, -1, + 340, 341, -1, 343, 344, 345, 346, 347, 348, -1, + 350, 351, -1, -1, 354, 355, 356, 357, -1, 359, + 360, 361, 362, 363, 364, 365, -1, -1, 368, 369, + 370, 371, 372, -1, -1, 375, 376, 377, 378, 379, + 380, 381, -1, 383, -1, 385, 386, 387, -1, -1, + 390, -1, -1, 393, 394, 395, 396, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 407, 408, 409, + 3, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 14, 15, 16, 17, 18, 19, 20, 21, -1, + 23, 24, 25, -1, -1, -1, -1, -1, -1, -1, + 33, 34, -1, 36, 37, -1, 39, 40, 41, 42, + 43, -1, 45, 46, -1, 48, 49, 50, 51, 52, + -1, -1, 55, 56, 57, 58, 59, -1, 61, 62, + 63, 64, 65, -1, -1, -1, 69, 70, 71, 72, + -1, 74, 75, -1, 77, 78, 79, 80, 81, 82, + -1, -1, 85, 86, -1, -1, -1, -1, -1, -1, + -1, 94, 95, 96, 97, 98, 99, 100, 101, 102, + -1, 104, -1, 106, 107, 108, 109, 110, -1, 112, + 113, 114, -1, -1, 117, 118, 119, 120, 121, -1, + 123, 124, 125, -1, 127, 128, -1, 130, 131, 132, + 133, 134, 135, 136, 137, 138, -1, 140, -1, 142, + 143, 144, -1, 146, -1, 148, -1, -1, -1, 152, + 153, 154, -1, 156, 157, -1, 159, -1, 161, 162, + 163, 164, 165, -1, 167, 168, 169, -1, 171, 172, + 173, 174, 175, 176, -1, 178, -1, 180, 181, 182, + 183, 184, 185, 186, -1, 188, -1, 190, -1, -1, + 193, -1, 195, 196, 197, 198, 199, 200, 201, -1, + 203, 204, -1, 206, -1, -1, 209, 210, 211, -1, + -1, 214, 215, 216, 217, 218, 219, 220, 221, 222, + 223, 224, 225, 226, -1, 228, 229, 230, 231, -1, + 233, 234, -1, 236, -1, 238, 239, 240, 241, 242, + 243, -1, 245, -1, -1, 248, 249, 250, -1, -1, + 253, -1, -1, -1, 257, 258, 259, 260, 261, 262, + 263, 264, -1, 266, 267, 268, 269, 270, 271, 272, + -1, 274, 275, 276, 277, 278, 279, 280, 281, 282, + 283, 284, 285, -1, 287, 288, 289, 290, 291, 292, + 293, 294, 295, 296, -1, 298, 299, -1, 301, 302, + 303, 304, 305, 306, 307, 308, 309, 310, 311, -1, + 313, 314, 315, 316, 317, -1, 319, 320, 321, 322, + -1, 324, 325, 326, -1, 328, 329, 330, 331, 332, + 333, 334, 335, 336, 337, 338, -1, 340, 341, -1, + 343, 344, 345, 346, 347, 348, -1, 350, 351, -1, + -1, 354, 355, 356, 357, -1, 359, 360, 361, 362, + 363, 364, 365, -1, -1, 368, 369, 370, 371, 372, + -1, -1, 375, 376, 377, 378, 379, 380, 381, -1, + 383, -1, 385, 386, 387, -1, -1, 390, -1, -1, + 393, 394, 395, 396, 397, 398, 399, 400, 401, 402, + 403, 404, 405, 406, 407, 408, 409, 3, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 14, 15, + 16, 17, 18, 19, 20, 21, -1, 23, 24, 25, + -1, -1, -1, -1, -1, -1, -1, 33, 34, -1, + 36, 37, -1, 39, 40, 41, 42, 43, -1, 45, + 46, -1, 48, 49, 50, 51, 52, -1, -1, 55, + 56, 57, 58, 59, -1, 61, 62, 63, 64, 65, + -1, -1, -1, 69, 70, 71, 72, -1, 74, 75, + -1, 77, 78, 79, 80, 81, 82, -1, -1, 85, + 86, -1, -1, -1, -1, -1, -1, -1, 94, 95, + 96, 97, 98, 99, 100, 101, 102, -1, 104, -1, + 106, 107, 108, 109, 110, -1, 112, 113, 114, -1, + -1, 117, 118, 119, 120, 121, -1, 123, 124, 125, + -1, 127, 128, -1, 130, 131, 132, 133, 134, 135, + 136, 137, 138, -1, 140, -1, 142, 143, 144, -1, + 146, -1, 148, -1, -1, -1, 152, 153, 154, -1, + 156, 157, -1, 159, -1, 161, 162, 163, 164, 165, + -1, 167, 168, 169, -1, 171, 172, 173, 174, 175, + 176, -1, 178, -1, 180, 181, 182, 183, 184, 185, + 186, -1, 188, -1, 190, -1, -1, 193, -1, 195, + 196, 197, 198, 199, 200, 201, -1, 203, 204, -1, + 206, -1, -1, 209, 210, 211, -1, -1, 214, 215, + 216, 217, 218, 219, 220, 221, 222, 223, 224, 225, + 226, -1, 228, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, 243, -1, 245, + -1, -1, 248, 249, 250, -1, -1, 253, -1, -1, + -1, 257, 258, 259, 260, 261, 262, 263, 264, -1, + 266, 267, 268, 269, 270, 271, 272, -1, 274, 275, + 276, 277, 278, 279, 280, 281, 282, 283, 284, 285, + -1, 287, 288, 289, 290, 291, 292, 293, 294, 295, + 296, -1, 298, 299, -1, 301, 302, 303, 304, 305, + 306, 307, 308, 309, 310, 311, -1, 313, 314, 315, + 316, 317, -1, 319, 320, 321, 322, -1, 324, 325, + 326, -1, 328, 329, 330, 331, 332, 333, 334, 335, + 336, 337, 338, -1, 340, 341, -1, 343, 344, 345, + 346, 347, 348, -1, 350, 351, -1, -1, 354, 355, + 356, 357, -1, 359, 360, 361, 362, 363, 364, 365, + -1, -1, 368, 369, 370, 371, 372, -1, -1, 375, + 376, 377, 378, 379, 380, 381, -1, 383, -1, 385, + 386, 387, -1, -1, 390, -1, -1, 393, 394, 395, + 396, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 407, 408, 409, 3, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 14, 15, 16, 17, 18, + 19, 20, 21, -1, 23, 24, 25, -1, -1, -1, + -1, -1, -1, -1, 33, 34, -1, 36, 37, -1, + 39, 40, 41, 42, 43, -1, 45, 46, -1, 48, + 49, 50, 51, 52, -1, -1, 55, 56, 57, 58, + 59, -1, 61, 62, 63, 64, 65, -1, -1, -1, + 69, 70, 71, 72, -1, 74, 75, -1, 77, 78, + 79, 80, 81, 82, -1, -1, 85, 86, -1, -1, + -1, -1, -1, -1, -1, 94, 95, 96, 97, 98, + 99, 100, 101, 102, -1, 104, -1, 106, 107, 108, + 109, 110, -1, 112, 113, 114, -1, -1, 117, 118, + 119, 120, 121, -1, 123, 124, 125, -1, 127, 128, + -1, 130, 131, 132, 133, 134, 135, 136, 137, 138, + -1, 140, -1, 142, 143, 144, -1, 146, -1, 148, + -1, -1, -1, 152, 153, 154, -1, 156, 157, -1, + 159, -1, 161, 162, 163, 164, 165, -1, 167, 168, + 169, -1, 171, 172, 173, 174, 175, 176, -1, 178, + -1, 180, 181, 182, 183, 184, 185, 186, -1, 188, + -1, 190, -1, -1, 193, -1, 195, 196, 197, 198, + 199, 200, 201, -1, 203, 204, -1, 206, -1, -1, + 209, 210, 211, -1, -1, 214, 215, 216, 217, 218, + 219, 220, 221, 222, 223, 224, 225, 226, -1, 228, + 229, 230, 231, -1, 233, 234, -1, 236, -1, 238, + 239, 240, 241, 242, 243, -1, 245, -1, -1, 248, + 249, 250, -1, -1, 253, -1, -1, -1, 257, 258, + 259, 260, 261, 262, 263, 264, -1, 266, 267, 268, + 269, 270, 271, 272, -1, 274, 275, 276, 277, 278, + 279, 280, 281, 282, 283, 284, 285, -1, 287, 288, + 289, 290, 291, 292, 293, 294, 295, 296, -1, 298, + 299, -1, 301, 302, 303, 304, 305, 306, 307, 308, + 309, 310, 311, -1, 313, 314, 315, 316, 317, -1, + 319, 320, 321, 322, -1, 324, 325, 326, -1, 328, + 329, 330, 331, 332, 333, 334, 335, 336, 337, 338, + -1, 340, 341, -1, 343, 344, 345, 346, 347, 348, + -1, 350, 351, -1, -1, 354, 355, 356, 357, -1, + 359, 360, 361, 362, 363, 364, 365, -1, -1, 368, + 369, 370, 371, 372, -1, -1, 375, 376, 377, 378, + 379, 380, 381, -1, 383, -1, 385, 386, 387, -1, + -1, 390, -1, -1, 393, 394, 395, 396, 397, 398, + 399, 400, 401, 402, 403, 404, 405, 406, 407, 408, + 409, 3, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 14, 15, 16, 17, 18, 19, 20, 21, + -1, 23, 24, 25, -1, -1, -1, -1, -1, -1, + -1, 33, 34, -1, 36, 37, -1, 39, 40, 41, + 42, 43, -1, 45, 46, -1, 48, 49, 50, 51, + 52, -1, -1, 55, 56, 57, 58, 59, -1, 61, + 62, 63, 64, 65, -1, -1, -1, 69, 70, 71, + 72, -1, 74, 75, -1, 77, 78, 79, 80, 81, + 82, -1, -1, 85, 86, -1, -1, -1, -1, -1, + -1, -1, 94, 95, 96, 97, 98, 99, 100, 101, + 102, -1, 104, -1, 106, 107, 108, 109, 110, -1, + 112, 113, 114, -1, -1, 117, 118, 119, 120, 121, + -1, 123, 124, 125, -1, 127, 128, -1, 130, 131, + 132, 133, 134, 135, 136, 137, 138, -1, 140, -1, + 142, 143, 144, -1, 146, -1, 148, -1, -1, -1, + 152, 153, 154, -1, 156, 157, -1, 159, -1, 161, + 162, 163, 164, 165, -1, 167, 168, 169, -1, 171, + 172, 173, 174, 175, 176, -1, 178, -1, 180, 181, + 182, 183, 184, 185, 186, -1, 188, -1, 190, -1, + -1, 193, -1, 195, 196, 197, 198, 199, 200, 201, + -1, 203, 204, -1, 206, -1, -1, 209, 210, 211, + -1, -1, 214, 215, 216, 217, 218, 219, 220, 221, + 222, 223, 224, 225, 226, -1, 228, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, 243, -1, 245, -1, -1, 248, 249, 250, -1, + -1, 253, -1, -1, -1, 257, 258, 259, 260, 261, + 262, 263, 264, -1, 266, 267, 268, 269, 270, 271, + 272, -1, 274, 275, 276, 277, 278, 279, 280, 281, + 282, 283, 284, 285, -1, 287, 288, 289, 290, 291, + 292, 293, 294, 295, 296, -1, 298, 299, -1, 301, + 302, 303, 304, 305, 306, 307, 308, 309, 310, 311, + -1, 313, 314, 315, 316, 317, -1, 319, 320, 321, + 322, -1, 324, 325, 326, -1, 328, 329, 330, 331, + 332, 333, 334, 335, 336, 337, 338, -1, 340, 341, + -1, 343, 344, 345, 346, 347, 348, -1, 350, 351, + -1, -1, 354, 355, 356, 357, -1, 359, 360, 361, + 362, 363, 364, 365, -1, -1, 368, 369, 370, 371, + 372, -1, -1, 375, 376, 377, 378, 379, 380, 381, + -1, 383, -1, 385, 386, 387, -1, -1, 390, -1, + -1, 393, 394, 395, 396, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 407, 408, 409, 3, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 14, + 15, 16, 17, 18, 19, 20, 21, -1, 23, 24, + 25, -1, -1, -1, -1, -1, -1, -1, 33, 34, + -1, 36, 37, -1, 39, 40, 41, 42, 43, -1, + 45, 46, -1, 48, 49, 50, 51, 52, -1, -1, + 55, 56, 57, 58, 59, -1, 61, 62, 63, 64, + 65, -1, -1, -1, 69, 70, 71, 72, -1, 74, + 75, -1, 77, 78, 79, 80, 81, 82, -1, -1, + 85, 86, -1, -1, -1, -1, -1, -1, -1, 94, + 95, 96, 97, 98, 99, 100, 101, 102, -1, 104, + -1, 106, 107, 108, 109, 110, -1, 112, 113, 114, + -1, -1, 117, 118, 119, 120, 121, -1, 123, 124, + 125, -1, 127, 128, -1, 130, 131, 132, 133, 134, + 135, 136, 137, 138, -1, 140, -1, 142, 143, 144, + -1, 146, -1, 148, -1, -1, -1, 152, 153, 154, + -1, 156, 157, -1, 159, -1, 161, 162, 163, 164, + 165, -1, 167, 168, 169, -1, 171, 172, 173, 174, + 175, 176, -1, 178, -1, 180, 181, 182, 183, 184, + 185, 186, -1, 188, -1, 190, -1, -1, 193, -1, + 195, 196, 197, 198, 199, 200, 201, -1, 203, 204, + -1, 206, -1, -1, 209, 210, 211, -1, -1, 214, + 215, 216, 217, 218, 219, 220, 221, 222, 223, 224, + 225, 226, -1, 228, 229, 230, 231, -1, 233, 234, + -1, 236, -1, 238, 239, 240, 241, 242, 243, -1, + 245, -1, -1, 248, 249, 250, -1, -1, 253, -1, + -1, -1, 257, 258, 259, 260, 261, 262, 263, 264, + -1, 266, 267, 268, 269, 270, 271, 272, -1, 274, + 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, + 285, -1, 287, 288, 289, 290, 291, 292, 293, 294, + 295, 296, -1, 298, 299, -1, 301, 302, 303, 304, + 305, 306, 307, 308, 309, 310, 311, -1, 313, 314, + 315, 316, 317, -1, 319, 320, 321, 322, -1, 324, + 325, 326, -1, 328, 329, 330, 331, 332, 333, 334, + 335, 336, 337, 338, -1, 340, 341, -1, 343, 344, + 345, 346, 347, 348, -1, 350, 351, -1, -1, 354, + 355, 356, 357, -1, 359, 360, 361, 362, 363, 364, + 365, -1, -1, 368, 369, 370, 371, 372, -1, -1, + 375, 376, 377, 378, 379, 380, 381, -1, 383, -1, + 385, 386, 387, -1, -1, 390, -1, -1, 393, 394, + 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 407, 408, 409, 3, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 14, 15, 16, 17, + 18, 19, 20, 21, -1, 23, 24, 25, -1, -1, + -1, -1, -1, -1, -1, 33, 34, -1, 36, 37, + -1, 39, 40, 41, 42, 43, -1, 45, 46, -1, + 48, 49, 50, 51, 52, -1, -1, 55, 56, 57, + 58, 59, -1, 61, 62, 63, 64, 65, -1, -1, + -1, 69, 70, 71, 72, -1, 74, 75, -1, 77, + 78, 79, 80, 81, 82, -1, -1, 85, 86, -1, + -1, -1, -1, -1, -1, -1, 94, 95, 96, 97, + 98, 99, 100, 101, 102, -1, 104, -1, 106, 107, + 108, 109, 110, -1, 112, 113, 114, -1, -1, 117, + 118, 119, 120, 121, -1, 123, 124, 125, -1, 127, + 128, -1, 130, 131, 132, 133, 134, 135, 136, 137, + 138, -1, 140, -1, 142, 143, 144, -1, 146, -1, + 148, -1, -1, -1, 152, 153, 154, -1, 156, 157, + -1, 159, -1, 161, 162, 163, 164, 165, -1, 167, + 168, 169, -1, 171, 172, 173, 174, 175, 176, -1, + 178, -1, 180, 181, 182, 183, 184, 185, 186, -1, + 188, -1, 190, -1, -1, 193, -1, 195, 196, 197, + 198, 199, 200, 201, -1, 203, 204, -1, 206, -1, + -1, 209, 210, 211, -1, -1, 214, 215, 216, 217, + 218, 219, 220, 221, 222, 223, 224, 225, 226, -1, + 228, 229, 230, 231, -1, 233, 234, -1, 236, -1, + 238, 239, 240, 241, 242, 243, -1, 245, -1, -1, + 248, 249, 250, -1, -1, 253, -1, -1, -1, 257, + 258, 259, 260, 261, 262, 263, 264, -1, 266, 267, + 268, 269, 270, 271, 272, -1, 274, 275, 276, 277, + 278, 279, 280, 281, 282, 283, 284, 285, -1, 287, + 288, 289, 290, 291, 292, 293, 294, 295, 296, -1, + 298, 299, -1, 301, 302, 303, 304, 305, 306, 307, + 308, 309, 310, 311, -1, 313, 314, 315, 316, 317, + -1, 319, 320, 321, 322, -1, 324, 325, 326, -1, + 328, 329, 330, 331, 332, 333, 334, 335, 336, 337, + 338, -1, 340, 341, -1, 343, 344, 345, 346, 347, + 348, -1, 350, 351, -1, -1, 354, 355, 356, 357, + -1, 359, 360, 361, 362, 363, 364, 365, -1, -1, + 368, 369, 370, 371, 372, -1, -1, 375, 376, 377, + 378, 379, 380, 381, -1, 383, -1, 385, 386, 387, + -1, -1, 390, -1, -1, 393, 394, 395, 396, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, + 408, 409, 3, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 14, 15, 16, 17, 18, 19, 20, + 21, -1, 23, 24, 25, -1, -1, -1, -1, -1, + -1, -1, 33, 34, -1, 36, 37, -1, 39, 40, + 41, 42, 43, -1, 45, 46, -1, 48, 49, 50, + 51, 52, -1, -1, 55, 56, 57, 58, 59, -1, + 61, 62, 63, 64, 65, -1, -1, -1, 69, 70, + 71, 72, -1, 74, 75, -1, 77, 78, 79, 80, + 81, 82, -1, -1, 85, 86, -1, -1, -1, -1, + -1, -1, -1, 94, 95, 96, 97, 98, 99, 100, + 101, 102, -1, 104, -1, 106, 107, 108, 109, 110, + -1, 112, 113, 114, -1, -1, 117, 118, 119, 120, + 121, -1, 123, 124, 125, -1, 127, 128, -1, 130, + 131, 132, 133, 134, 135, 136, 137, 138, -1, 140, + -1, 142, 143, 144, -1, 146, -1, 148, -1, -1, + -1, 152, 153, 154, -1, 156, 157, -1, 159, -1, + 161, 162, 163, 164, 165, -1, 167, 168, 169, -1, + 171, 172, 173, 174, 175, 176, -1, 178, -1, 180, + 181, 182, 183, 184, 185, 186, -1, 188, -1, 190, + -1, -1, 193, -1, 195, 196, 197, 198, 199, 200, + 201, -1, 203, 204, -1, 206, -1, -1, 209, 210, + 211, -1, -1, 214, 215, 216, 217, 218, 219, 220, + 221, 222, 223, 224, 225, 226, -1, 228, 229, 230, + 231, -1, 233, 234, -1, 236, -1, 238, 239, 240, + 241, 242, 243, -1, 245, -1, -1, 248, 249, 250, + -1, -1, 253, -1, -1, -1, 257, 258, 259, 260, + 261, 262, 263, 264, -1, 266, 267, 268, 269, 270, + 271, 272, -1, 274, 275, 276, 277, 278, 279, 280, + 281, 282, 283, 284, 285, -1, 287, 288, 289, 290, + 291, 292, 293, 294, 295, 296, -1, 298, 299, -1, + 301, 302, 303, 304, 305, 306, 307, 308, 309, 310, + 311, -1, 313, 314, 315, 316, 317, -1, 319, 320, + 321, 322, -1, 324, 325, 326, -1, 328, 329, 330, + 331, 332, 333, 334, 335, 336, 337, 338, -1, 340, + 341, -1, 343, 344, 345, 346, 347, 348, -1, 350, + 351, -1, -1, 354, 355, 356, 357, -1, 359, 360, + 361, 362, 363, 364, 365, -1, -1, 368, 369, 370, + 371, 372, -1, -1, 375, 376, 377, 378, 379, 380, + 381, -1, 383, -1, 385, 386, 387, -1, -1, 390, + -1, -1, 393, 394, 395, 396, 397, 398, 399, 400, + 401, 402, 403, 404, 405, 406, 407, 408, 409, 3, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, -1, -1, -1, 33, + 34, -1, 36, 37, -1, 39, 40, 41, 42, 43, + -1, 45, 46, -1, 48, 49, 50, 51, 52, -1, + -1, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, 65, -1, -1, -1, 69, 70, 71, 72, -1, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + -1, 85, 86, -1, -1, -1, -1, -1, -1, -1, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + 134, 135, 136, 137, 138, -1, 140, -1, 142, 143, + 144, -1, 146, -1, 148, -1, -1, -1, 152, 153, + 154, -1, 156, 157, -1, 159, -1, 161, 162, 163, + 164, 165, -1, 167, 168, 169, -1, 171, 172, 173, + 174, 175, 176, -1, 178, -1, 180, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, -1, -1, 193, + -1, 195, 196, 197, 198, 199, 200, 201, -1, 203, + 204, -1, 206, -1, -1, 209, 210, 211, -1, -1, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, -1, 228, 229, 230, 231, -1, 233, + 234, -1, 236, -1, 238, 239, 240, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, 253, + -1, -1, -1, 257, 258, 259, 260, 261, 262, 263, + 264, -1, 266, 267, 268, 269, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, -1, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, -1, 313, + 314, 315, 316, 317, -1, 319, 320, 321, 322, -1, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, 338, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, 355, 356, 357, -1, 359, 360, 361, 362, 363, + 364, 365, -1, -1, 368, 369, 370, 371, 372, -1, + -1, 375, 376, 377, 378, 379, 380, 381, -1, 383, + -1, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 407, 408, 409, 3, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 14, 15, 16, + 17, 18, 19, 20, 21, -1, 23, 24, 25, -1, + -1, -1, -1, -1, -1, -1, 33, 34, -1, 36, + 37, -1, 39, 40, 41, 42, 43, -1, 45, 46, + -1, 48, 49, 50, 51, 52, -1, -1, 55, 56, + 57, 58, 59, -1, 61, 62, 63, 64, 65, -1, + -1, -1, 69, 70, 71, 72, -1, 74, 75, -1, + 77, 78, 79, 80, 81, 82, -1, -1, 85, 86, + -1, -1, -1, -1, -1, -1, -1, 94, 95, 96, + 97, 98, 99, 100, 101, 102, -1, 104, -1, 106, + 107, 108, 109, 110, -1, 112, 113, 114, -1, -1, + 117, 118, 119, 120, 121, -1, 123, 124, 125, -1, + 127, 128, -1, 130, 131, 132, 133, 134, 135, 136, + 137, 138, -1, 140, -1, 142, 143, 144, -1, 146, + -1, 148, -1, -1, -1, 152, 153, 154, -1, 156, + 157, -1, 159, -1, 161, 162, 163, 164, 165, -1, + 167, 168, 169, -1, 171, 172, 173, 174, 175, 176, + -1, 178, -1, 180, 181, 182, 183, 184, 185, 186, + -1, 188, -1, 190, -1, -1, 193, -1, 195, 196, + 197, 198, 199, 200, 201, -1, 203, 204, -1, 206, + -1, -1, 209, 210, 211, -1, -1, 214, 215, 216, + 217, 218, 219, 220, 221, 222, 223, 224, 225, 226, + -1, 228, 229, 230, 231, -1, 233, 234, -1, 236, + -1, 238, 239, 240, 241, 242, 243, -1, 245, -1, + -1, 248, 249, 250, -1, -1, 253, -1, -1, -1, + 257, 258, 259, 260, 261, 262, 263, 264, -1, 266, + 267, 268, 269, 270, 271, 272, -1, 274, 275, 276, + 277, 278, 279, 280, 281, 282, 283, 284, 285, -1, + 287, 288, 289, 290, 291, 292, 293, 294, 295, 296, + -1, 298, 299, -1, 301, 302, 303, 304, 305, 306, + 307, 308, 309, 310, 311, -1, 313, 314, 315, 316, + 317, -1, 319, 320, 321, 322, -1, 324, 325, 326, + -1, 328, 329, 330, 331, 332, 333, 334, 335, 336, + 337, 338, -1, 340, 341, -1, 343, 344, 345, 346, + 347, 348, -1, 350, 351, -1, -1, 354, 355, 356, + 357, -1, 359, 360, 361, 362, 363, 364, 365, -1, + -1, 368, 369, 370, 371, 372, -1, -1, 375, 376, + 377, 378, 379, 380, 381, -1, 383, -1, 385, 386, + 387, -1, -1, 390, -1, -1, 393, 394, 395, 396, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 407, 408, 409, 3, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 14, 15, 16, 17, 18, 19, + 20, 21, -1, 23, 24, 25, -1, -1, -1, -1, + -1, -1, -1, 33, 34, -1, 36, 37, -1, 39, + 40, 41, 42, 43, -1, 45, 46, -1, 48, 49, + 50, 51, 52, -1, -1, 55, 56, 57, 58, 59, + -1, 61, 62, 63, 64, 65, -1, -1, -1, 69, + 70, 71, 72, -1, 74, 75, -1, 77, 78, 79, + 80, 81, 82, -1, -1, 85, 86, -1, -1, -1, + -1, -1, -1, -1, 94, 95, 96, 97, 98, 99, + 100, 101, 102, -1, 104, -1, 106, 107, 108, 109, + 110, -1, 112, 113, 114, -1, -1, 117, 118, 119, + 120, 121, -1, 123, 124, 125, -1, 127, 128, -1, + 130, 131, 132, 133, 134, 135, 136, 137, 138, -1, + 140, -1, 142, 143, 144, -1, 146, -1, 148, -1, + -1, -1, 152, 153, 154, -1, 156, 157, -1, 159, + -1, 161, 162, 163, 164, 165, -1, 167, 168, 169, + -1, 171, 172, 173, 174, 175, 176, -1, 178, -1, + 180, 181, 182, 183, 184, 185, 186, -1, 188, -1, + 190, -1, -1, 193, -1, 195, 196, 197, 198, 199, + 200, 201, -1, 203, 204, -1, 206, -1, -1, 209, + 210, 211, -1, -1, 214, 215, 216, 217, 218, 219, + 220, 221, 222, 223, 224, 225, 226, -1, 228, 229, + 230, 231, -1, 233, 234, -1, 236, -1, 238, 239, + 240, 241, 242, 243, -1, 245, -1, -1, 248, 249, + 250, -1, -1, 253, -1, -1, -1, 257, 258, 259, + 260, 261, 262, 263, 264, -1, 266, 267, 268, 269, + 270, 271, 272, -1, 274, 275, 276, 277, 278, 279, + 280, 281, 282, 283, 284, 285, -1, 287, 288, 289, + 290, 291, 292, 293, 294, 295, 296, -1, 298, 299, + -1, 301, 302, 303, 304, 305, 306, 307, 308, 309, + 310, 311, -1, 313, 314, 315, 316, 317, -1, 319, + 320, 321, 322, -1, 324, 325, 326, -1, 328, 329, + 330, 331, 332, 333, 334, 335, 336, 337, 338, -1, + 340, 341, -1, 343, 344, 345, 346, 347, 348, -1, + 350, 351, -1, -1, 354, 355, 356, 357, -1, 359, + 360, 361, 362, 363, 364, 365, -1, -1, 368, 369, + 370, 371, 372, -1, -1, 375, 376, 377, 378, 379, + 380, 381, -1, 383, -1, 385, 386, 387, -1, -1, + 390, -1, -1, 393, 394, 395, 396, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 407, 408, 409, + 3, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 14, 15, 16, 17, 18, 19, 20, 21, -1, + 23, 24, 25, -1, -1, -1, -1, -1, -1, -1, + 33, 34, -1, 36, 37, -1, 39, 40, 41, 42, + 43, -1, 45, 46, -1, 48, 49, 50, 51, 52, + -1, -1, 55, 56, 57, 58, 59, -1, 61, 62, + 63, 64, 65, -1, -1, -1, 69, 70, 71, 72, + -1, 74, 75, -1, 77, 78, 79, 80, 81, 82, + -1, -1, 85, 86, -1, -1, -1, -1, -1, -1, + -1, 94, 95, 96, 97, 98, 99, 100, 101, 102, + -1, 104, -1, 106, 107, 108, 109, 110, -1, 112, + 113, 114, -1, -1, 117, 118, 119, 120, 121, -1, + 123, 124, 125, -1, 127, 128, -1, 130, 131, 132, + 133, 134, 135, 136, 137, 138, -1, 140, -1, 142, + 143, 144, -1, 146, -1, 148, -1, -1, -1, 152, + 153, 154, -1, 156, 157, -1, 159, -1, 161, 162, + 163, 164, 165, -1, 167, 168, 169, -1, 171, 172, + 173, 174, 175, 176, -1, 178, -1, 180, 181, 182, + 183, 184, 185, 186, -1, 188, -1, 190, -1, -1, + 193, -1, 195, 196, 197, 198, 199, 200, 201, -1, + 203, 204, -1, 206, -1, -1, 209, 210, 211, -1, + -1, 214, 215, 216, 217, 218, 219, 220, 221, 222, + 223, 224, 225, 226, -1, 228, 229, 230, 231, -1, + 233, 234, -1, 236, -1, 238, 239, 240, 241, 242, + 243, -1, 245, -1, -1, 248, 249, 250, -1, -1, + 253, -1, -1, -1, 257, 258, 259, 260, 261, 262, + 263, 264, -1, 266, 267, 268, 269, 270, 271, 272, + -1, 274, 275, 276, 277, 278, 279, 280, 281, 282, + 283, 284, 285, -1, 287, 288, 289, 290, 291, 292, + 293, 294, 295, 296, -1, 298, 299, -1, 301, 302, + 303, 304, 305, 306, 307, 308, 309, 310, 311, -1, + 313, 314, 315, 316, 317, -1, 319, 320, 321, 322, + -1, 324, 325, 326, -1, 328, 329, 330, 331, 332, + 333, 334, 335, 336, 337, 338, -1, 340, 341, -1, + 343, 344, 345, 346, 347, 348, -1, 350, 351, -1, + -1, 354, 355, 356, 357, -1, 359, 360, 361, 362, + 363, 364, 365, -1, -1, 368, 369, 370, 371, 372, + -1, -1, 375, 376, 377, 378, 379, 380, 381, -1, + 383, -1, 385, 386, 387, -1, -1, 390, -1, -1, + 393, 394, 395, 396, 397, 398, 399, 400, 401, 402, + 403, 404, 405, 406, 407, 408, 409, 3, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 14, 15, + 16, 17, 18, 19, 20, 21, -1, 23, 24, 25, + -1, -1, -1, -1, -1, -1, -1, 33, 34, -1, + 36, 37, -1, 39, 40, 41, 42, 43, -1, 45, + 46, -1, 48, 49, 50, 51, 52, -1, -1, 55, + 56, 57, 58, 59, -1, 61, 62, 63, 64, 65, + -1, -1, -1, 69, 70, 71, 72, -1, 74, 75, + -1, 77, 78, 79, 80, 81, 82, -1, -1, 85, + 86, -1, -1, -1, -1, -1, -1, -1, 94, 95, + 96, 97, 98, 99, 100, 101, 102, -1, 104, -1, + 106, 107, 108, 109, 110, -1, 112, 113, 114, -1, + -1, 117, 118, 119, 120, 121, -1, 123, 124, 125, + -1, 127, 128, -1, 130, 131, 132, 133, 134, 135, + 136, 137, 138, -1, 140, -1, 142, 143, 144, -1, + 146, -1, 148, -1, -1, -1, 152, 153, 154, -1, + 156, 157, -1, 159, -1, 161, 162, 163, 164, 165, + -1, 167, 168, 169, -1, 171, 172, 173, 174, 175, + 176, -1, 178, -1, 180, 181, 182, 183, 184, 185, + 186, -1, 188, -1, 190, -1, -1, 193, -1, 195, + 196, 197, 198, 199, 200, 201, -1, 203, 204, -1, + 206, -1, -1, 209, 210, 211, -1, -1, 214, 215, + 216, 217, 218, 219, 220, 221, 222, 223, 224, 225, + 226, -1, 228, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, 243, -1, 245, + -1, -1, 248, 249, 250, -1, -1, 253, -1, -1, + -1, 257, 258, 259, 260, 261, 262, 263, 264, -1, + 266, 267, 268, 269, 270, 271, 272, -1, 274, 275, + 276, 277, 278, 279, 280, 281, 282, 283, 284, 285, + -1, 287, 288, 289, 290, 291, 292, 293, 294, 295, + 296, -1, 298, 299, -1, 301, 302, 303, 304, 305, + 306, 307, 308, 309, 310, 311, -1, 313, 314, 315, + 316, 317, -1, 319, 320, 321, 322, -1, 324, 325, + 326, -1, 328, 329, 330, 331, 332, 333, 334, 335, + 336, 337, 338, -1, 340, 341, -1, 343, 344, 345, + 346, 347, 348, -1, 350, 351, -1, -1, 354, 355, + 356, 357, -1, 359, 360, 361, 362, 363, 364, 365, + -1, -1, 368, 369, 370, 371, 372, -1, -1, 375, + 376, 377, 378, 379, 380, 381, -1, 383, -1, 385, + 386, 387, -1, -1, 390, -1, -1, 393, 394, 395, + 396, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 407, 408, 409, 3, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 14, 15, 16, 17, 18, + 19, 20, 21, -1, 23, 24, 25, -1, -1, -1, + -1, -1, -1, -1, 33, 34, -1, 36, 37, -1, + 39, 40, 41, 42, 43, -1, 45, 46, -1, 48, + 49, 50, 51, 52, -1, -1, 55, 56, 57, 58, + 59, -1, 61, 62, 63, 64, 65, -1, -1, -1, + 69, 70, 71, 72, -1, 74, 75, -1, 77, 78, + 79, 80, 81, 82, -1, -1, 85, 86, -1, -1, + -1, -1, -1, -1, -1, 94, 95, 96, 97, 98, + 99, 100, 101, 102, -1, 104, -1, 106, 107, 108, + 109, 110, -1, 112, 113, 114, -1, -1, 117, 118, + 119, 120, 121, -1, 123, 124, 125, -1, 127, 128, + -1, 130, 131, 132, 133, 134, 135, 136, 137, 138, + -1, 140, -1, 142, 143, 144, -1, 146, -1, 148, + -1, -1, -1, 152, 153, 154, -1, 156, 157, -1, + 159, -1, 161, 162, 163, 164, 165, -1, 167, 168, + 169, -1, 171, 172, 173, 174, 175, 176, -1, 178, + -1, 180, 181, 182, 183, 184, 185, 186, -1, 188, + -1, 190, -1, -1, 193, -1, 195, 196, 197, 198, + 199, 200, 201, -1, 203, 204, -1, 206, -1, -1, + 209, 210, 211, -1, -1, 214, 215, 216, 217, 218, + 219, 220, 221, 222, 223, 224, 225, 226, -1, 228, + 229, 230, 231, -1, 233, 234, -1, 236, -1, 238, + 239, 240, 241, 242, 243, -1, 245, -1, -1, 248, + 249, 250, -1, -1, 253, -1, -1, -1, 257, 258, + 259, 260, 261, 262, 263, 264, -1, 266, 267, 268, + 269, 270, 271, 272, -1, 274, 275, 276, 277, 278, + 279, 280, 281, 282, 283, 284, 285, -1, 287, 288, + 289, 290, 291, 292, 293, 294, 295, 296, -1, 298, + 299, -1, 301, 302, 303, 304, 305, 306, 307, 308, + 309, 310, 311, -1, 313, 314, 315, 316, 317, -1, + 319, 320, 321, 322, -1, 324, 325, 326, -1, 328, + 329, 330, 331, 332, 333, 334, 335, 336, 337, 338, + -1, 340, 341, -1, 343, 344, 345, 346, 347, 348, + -1, 350, 351, -1, -1, 354, 355, 356, 357, -1, + 359, 360, 361, 362, 363, 364, 365, -1, -1, 368, + 369, 370, 371, 372, -1, -1, 375, 376, 377, 378, + 379, 380, 381, -1, 383, -1, 385, 386, 387, -1, + -1, 390, -1, -1, 393, 394, 395, 396, 397, 398, + 399, 400, 401, 402, 403, 404, 405, 406, 407, 408, + 409, 3, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 14, 15, 16, 17, 18, 19, 20, 21, + -1, 23, 24, 25, -1, -1, -1, -1, -1, -1, + -1, 33, 34, -1, 36, 37, -1, 39, 40, 41, + 42, 43, -1, 45, 46, -1, 48, 49, 50, 51, + 52, -1, -1, 55, 56, 57, 58, 59, -1, 61, + 62, 63, 64, 65, -1, -1, -1, 69, 70, 71, + 72, -1, 74, 75, -1, 77, 78, 79, 80, 81, + 82, -1, -1, 85, 86, -1, -1, -1, -1, -1, + -1, -1, 94, 95, 96, 97, 98, 99, 100, 101, + 102, -1, 104, -1, 106, 107, 108, 109, 110, -1, + 112, 113, 114, -1, -1, 117, 118, 119, 120, 121, + -1, 123, 124, 125, -1, 127, 128, -1, 130, 131, + 132, 133, 134, 135, 136, 137, 138, -1, 140, -1, + 142, 143, 144, -1, 146, -1, 148, -1, -1, -1, + 152, 153, 154, -1, 156, 157, -1, 159, -1, 161, + 162, 163, 164, 165, -1, 167, 168, 169, -1, 171, + 172, 173, 174, 175, 176, -1, 178, -1, 180, 181, + 182, 183, 184, 185, 186, -1, 188, -1, 190, -1, + -1, 193, -1, 195, 196, 197, 198, 199, 200, 201, + -1, 203, 204, -1, 206, -1, -1, 209, 210, 211, + -1, -1, 214, 215, 216, 217, 218, 219, 220, 221, + 222, 223, 224, 225, 226, -1, 228, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, 243, -1, 245, -1, -1, 248, 249, 250, -1, + -1, 253, -1, -1, -1, 257, 258, 259, 260, 261, + 262, 263, 264, -1, 266, 267, 268, 269, 270, 271, + 272, -1, 274, 275, 276, 277, 278, 279, 280, 281, + 282, 283, 284, 285, -1, 287, 288, 289, 290, 291, + 292, 293, 294, 295, 296, -1, 298, 299, -1, 301, + 302, 303, 304, 305, 306, 307, 308, 309, 310, 311, + -1, 313, 314, 315, 316, 317, -1, 319, 320, 321, + 322, -1, 324, 325, 326, -1, 328, 329, 330, 331, + 332, 333, 334, 335, 336, 337, 338, -1, 340, 341, + -1, 343, 344, 345, 346, 347, 348, -1, 350, 351, + -1, -1, 354, 355, 356, 357, -1, 359, 360, 361, + 362, 363, 364, 365, -1, -1, 368, 369, 370, 371, + 372, -1, -1, 375, 376, 377, 378, 379, 380, 381, + -1, 383, -1, 385, 386, 387, -1, -1, 390, -1, + -1, 393, 394, 395, 396, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 407, 408, 409, 3, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 14, + 15, 16, 17, 18, 19, 20, 21, -1, 23, 24, + 25, -1, -1, -1, -1, -1, -1, -1, 33, 34, + -1, 36, 37, -1, 39, 40, 41, 42, 43, -1, + 45, 46, -1, 48, 49, 50, 51, 52, -1, -1, + 55, 56, 57, 58, 59, -1, 61, 62, 63, 64, + 65, -1, -1, -1, 69, 70, 71, 72, -1, 74, + 75, -1, 77, 78, 79, 80, 81, 82, -1, -1, + 85, 86, -1, -1, -1, -1, -1, -1, -1, 94, + 95, 96, 97, 98, 99, 100, 101, 102, -1, 104, + -1, 106, 107, 108, 109, 110, -1, 112, 113, 114, + -1, -1, 117, 118, 119, 120, 121, -1, 123, 124, + 125, -1, 127, 128, -1, 130, 131, 132, 133, 134, + 135, 136, 137, 138, -1, 140, -1, 142, 143, 144, + -1, 146, -1, 148, -1, -1, -1, 152, 153, 154, + -1, 156, 157, -1, 159, -1, 161, 162, 163, 164, + 165, -1, 167, 168, 169, -1, 171, 172, 173, 174, + 175, 176, -1, 178, -1, 180, 181, 182, 183, 184, + 185, 186, -1, 188, -1, 190, -1, -1, 193, -1, + 195, 196, 197, 198, 199, 200, 201, -1, 203, 204, + -1, 206, -1, -1, 209, 210, 211, -1, -1, 214, + 215, 216, 217, 218, 219, 220, 221, 222, 223, 224, + 225, 226, -1, 228, 229, 230, 231, -1, 233, 234, + -1, 236, -1, 238, 239, 240, 241, 242, 243, -1, + 245, -1, -1, 248, 249, 250, -1, -1, 253, -1, + -1, -1, 257, 258, 259, 260, 261, 262, 263, 264, + -1, 266, 267, 268, 269, 270, 271, 272, -1, 274, + 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, + 285, -1, 287, 288, 289, 290, 291, 292, 293, 294, + 295, 296, -1, 298, 299, -1, 301, 302, 303, 304, + 305, 306, 307, 308, 309, 310, 311, -1, 313, 314, + 315, 316, 317, -1, 319, 320, 321, 322, -1, 324, + 325, 326, -1, 328, 329, 330, 331, 332, 333, 334, + 335, 336, 337, 338, -1, 340, 341, -1, 343, 344, + 345, 346, 347, 348, -1, 350, 351, -1, -1, 354, + 355, 356, 357, -1, 359, 360, 361, 362, 363, 364, + 365, -1, -1, 368, 369, 370, 371, 372, -1, -1, + 375, 376, 377, 378, 379, 380, 381, -1, 383, -1, + 385, 386, 387, -1, -1, 390, -1, -1, 393, 394, + 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 407, 408, 409, 3, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 14, 15, 16, 17, + 18, 19, 20, 21, -1, 23, 24, 25, -1, -1, + -1, -1, -1, -1, -1, 33, 34, -1, 36, 37, + -1, 39, 40, 41, 42, 43, -1, 45, 46, -1, + 48, 49, 50, 51, 52, -1, -1, 55, 56, 57, + 58, 59, -1, 61, 62, 63, 64, 65, -1, -1, + -1, 69, 70, 71, 72, -1, 74, 75, -1, 77, + 78, 79, 80, 81, 82, -1, -1, 85, 86, -1, + -1, -1, -1, -1, -1, -1, 94, 95, 96, 97, + 98, 99, 100, 101, 102, -1, 104, -1, 106, 107, + 108, 109, 110, -1, 112, 113, 114, -1, -1, 117, + 118, 119, 120, 121, -1, 123, 124, 125, -1, 127, + 128, -1, 130, 131, 132, 133, 134, 135, 136, 137, + 138, -1, 140, -1, 142, 143, 144, -1, 146, -1, + 148, -1, -1, -1, 152, 153, 154, -1, 156, 157, + -1, 159, -1, 161, 162, 163, 164, 165, -1, 167, + 168, 169, -1, 171, 172, 173, 174, 175, 176, -1, + 178, -1, 180, 181, 182, 183, 184, 185, 186, -1, + 188, -1, 190, -1, -1, 193, -1, 195, 196, 197, + 198, 199, 200, 201, -1, 203, 204, -1, 206, -1, + -1, 209, 210, 211, -1, -1, 214, 215, 216, 217, + 218, 219, 220, 221, 222, 223, 224, 225, 226, -1, + 228, 229, 230, 231, -1, 233, 234, -1, 236, -1, + 238, 239, 240, 241, 242, 243, -1, 245, -1, -1, + 248, 249, 250, -1, -1, 253, -1, -1, -1, 257, + 258, 259, 260, 261, 262, 263, 264, -1, 266, 267, + 268, 269, 270, 271, 272, -1, 274, 275, 276, 277, + 278, 279, 280, 281, 282, 283, 284, 285, -1, 287, + 288, 289, 290, 291, 292, 293, 294, 295, 296, -1, + 298, 299, -1, 301, 302, 303, 304, 305, 306, 307, + 308, 309, 310, 311, -1, 313, 314, 315, 316, 317, + -1, 319, 320, 321, 322, -1, 324, 325, 326, -1, + 328, 329, 330, 331, 332, 333, 334, 335, 336, 337, + 338, -1, 340, 341, -1, 343, 344, 345, 346, 347, + 348, -1, 350, 351, -1, -1, 354, 355, 356, 357, + -1, 359, 360, 361, 362, 363, 364, 365, -1, -1, + 368, 369, 370, 371, 372, -1, -1, 375, 376, 377, + 378, 379, 380, 381, -1, 383, -1, 385, 386, 387, + -1, -1, 390, -1, -1, 393, 394, 395, 396, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, + 408, 409, 3, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 14, 15, 16, 17, 18, 19, 20, + 21, -1, 23, 24, 25, -1, -1, -1, -1, -1, + -1, -1, 33, 34, -1, 36, 37, -1, 39, 40, + 41, 42, 43, -1, 45, 46, -1, 48, 49, 50, + 51, 52, -1, -1, 55, 56, 57, 58, 59, -1, + 61, 62, 63, 64, 65, -1, -1, -1, 69, 70, + 71, 72, -1, 74, 75, -1, 77, 78, 79, 80, + 81, 82, -1, -1, 85, 86, -1, -1, -1, -1, + -1, -1, -1, 94, 95, 96, 97, 98, 99, 100, + 101, 102, -1, 104, -1, 106, 107, 108, 109, 110, + -1, 112, 113, 114, -1, -1, 117, 118, 119, 120, + 121, -1, 123, 124, 125, -1, 127, 128, -1, 130, + 131, 132, 133, 134, 135, 136, 137, 138, -1, 140, + -1, 142, 143, 144, -1, 146, -1, 148, -1, -1, + -1, 152, 153, 154, -1, 156, 157, -1, 159, -1, + 161, 162, 163, 164, 165, -1, 167, 168, 169, -1, + 171, 172, 173, 174, 175, 176, -1, 178, -1, 180, + 181, 182, 183, 184, 185, 186, -1, 188, -1, 190, + -1, -1, 193, -1, 195, 196, 197, 198, 199, 200, + 201, -1, 203, 204, -1, 206, -1, -1, 209, 210, + 211, -1, -1, 214, 215, 216, 217, 218, 219, 220, + 221, 222, 223, 224, 225, 226, -1, 228, 229, 230, + 231, -1, 233, 234, -1, 236, -1, 238, 239, 240, + 241, 242, 243, -1, 245, -1, -1, 248, 249, 250, + -1, -1, 253, -1, -1, -1, 257, 258, 259, 260, + 261, 262, 263, 264, -1, 266, 267, 268, 269, 270, + 271, 272, -1, 274, 275, 276, 277, 278, 279, 280, + 281, 282, 283, 284, 285, -1, 287, 288, 289, 290, + 291, 292, 293, 294, 295, 296, -1, 298, 299, -1, + 301, 302, 303, 304, 305, 306, 307, 308, 309, 310, + 311, -1, 313, 314, 315, 316, 317, -1, 319, 320, + 321, 322, -1, 324, 325, 326, -1, 328, 329, 330, + 331, 332, 333, 334, 335, 336, 337, 338, -1, 340, + 341, -1, 343, 344, 345, 346, 347, 348, -1, 350, + 351, -1, -1, 354, 355, 356, 357, -1, 359, 360, + 361, 362, 363, 364, 365, -1, -1, 368, 369, 370, + 371, 372, -1, -1, 375, 376, 377, 378, 379, 380, + 381, -1, 383, -1, 385, 386, 387, -1, -1, 390, + -1, -1, 393, 394, 395, 396, 397, 398, 399, 400, + 401, 402, 403, 404, 405, 406, 407, 408, 409, 3, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, -1, -1, -1, 33, + 34, -1, 36, 37, -1, 39, 40, 41, 42, 43, + -1, 45, 46, -1, 48, 49, 50, 51, 52, -1, + -1, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, 65, -1, -1, -1, 69, 70, 71, 72, -1, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + -1, 85, 86, -1, -1, -1, -1, -1, -1, -1, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + 134, 135, 136, 137, 138, -1, 140, -1, 142, 143, + 144, -1, 146, -1, 148, -1, -1, -1, 152, 153, + 154, -1, 156, 157, -1, 159, -1, 161, 162, 163, + 164, 165, -1, 167, 168, 169, -1, 171, 172, 173, + 174, 175, 176, -1, 178, -1, 180, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, -1, -1, 193, + -1, 195, 196, 197, 198, 199, 200, 201, -1, 203, + 204, -1, 206, -1, -1, 209, 210, 211, -1, -1, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, -1, 228, 229, 230, 231, -1, 233, + 234, -1, 236, -1, 238, 239, 240, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, 253, + -1, -1, -1, 257, 258, 259, 260, 261, 262, 263, + 264, -1, 266, 267, 268, 269, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, -1, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, -1, 313, + 314, 315, 316, 317, -1, 319, 320, 321, 322, -1, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, 338, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, 355, 356, 357, -1, 359, 360, 361, 362, 363, + 364, 365, -1, -1, 368, 369, 370, 371, 372, -1, + -1, 375, 376, 377, 378, 379, 380, 381, -1, 383, + -1, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 407, 408, 409, 3, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 14, 15, 16, + 17, 18, 19, 20, 21, -1, 23, 24, 25, -1, + -1, -1, -1, -1, -1, -1, 33, 34, -1, 36, + 37, -1, 39, 40, 41, 42, 43, -1, 45, 46, + -1, 48, 49, 50, 51, 52, -1, -1, 55, 56, + 57, 58, 59, -1, 61, 62, 63, 64, 65, -1, + -1, -1, 69, 70, 71, 72, -1, 74, 75, -1, + 77, 78, 79, 80, 81, 82, -1, -1, 85, 86, + -1, -1, -1, -1, -1, -1, -1, 94, 95, 96, + 97, 98, 99, 100, 101, 102, -1, 104, -1, 106, + 107, 108, 109, 110, -1, 112, 113, 114, -1, -1, + 117, 118, 119, 120, 121, -1, 123, 124, 125, -1, + 127, 128, -1, 130, 131, 132, 133, 134, 135, 136, + 137, 138, -1, 140, -1, 142, 143, 144, -1, 146, + -1, 148, -1, -1, -1, 152, 153, 154, -1, 156, + 157, -1, 159, -1, 161, 162, 163, 164, 165, -1, + 167, 168, 169, -1, 171, 172, 173, 174, 175, 176, + -1, 178, -1, 180, 181, 182, 183, 184, 185, 186, + -1, 188, -1, 190, -1, -1, 193, -1, 195, 196, + 197, 198, 199, 200, 201, -1, 203, 204, -1, 206, + -1, -1, 209, 210, 211, -1, -1, 214, 215, 216, + 217, 218, 219, 220, 221, 222, 223, 224, 225, 226, + -1, 228, 229, 230, 231, -1, 233, 234, -1, 236, + -1, 238, 239, 240, 241, 242, 243, -1, 245, -1, + -1, 248, 249, 250, -1, -1, 253, -1, -1, -1, + 257, 258, 259, 260, 261, 262, 263, 264, -1, 266, + 267, 268, 269, 270, 271, 272, -1, 274, 275, 276, + 277, 278, 279, 280, 281, 282, 283, 284, 285, -1, + 287, 288, 289, 290, 291, 292, 293, 294, 295, 296, + -1, 298, 299, -1, 301, 302, 303, 304, 305, 306, + 307, 308, 309, 310, 311, -1, 313, 314, 315, 316, + 317, -1, 319, 320, 321, 322, -1, 324, 325, 326, + -1, 328, 329, 330, 331, 332, 333, 334, 335, 336, + 337, 338, -1, 340, 341, -1, 343, 344, 345, 346, + 347, 348, -1, 350, 351, -1, -1, 354, 355, 356, + 357, -1, 359, 360, 361, 362, 363, 364, 365, -1, + -1, 368, 369, 370, 371, 372, -1, -1, 375, 376, + 377, 378, 379, 380, 381, -1, 383, -1, 385, 386, + 387, -1, -1, 390, -1, -1, 393, 394, 395, 396, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 407, 408, 409, 3, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 14, 15, 16, 17, 18, 19, + 20, 21, -1, 23, 24, 25, -1, -1, -1, -1, + -1, -1, -1, 33, 34, -1, 36, 37, -1, 39, + 40, 41, 42, 43, -1, 45, 46, -1, 48, 49, + 50, 51, 52, -1, -1, 55, 56, 57, 58, 59, + -1, 61, 62, 63, 64, 65, -1, -1, -1, 69, + 70, 71, 72, -1, 74, 75, -1, 77, 78, 79, + 80, 81, 82, -1, -1, 85, 86, -1, -1, -1, + -1, -1, -1, -1, 94, 95, 96, 97, 98, 99, + 100, 101, 102, -1, 104, -1, 106, 107, 108, 109, + 110, -1, 112, 113, 114, -1, -1, 117, 118, 119, + 120, 121, -1, 123, 124, 125, -1, 127, 128, -1, + 130, 131, 132, 133, 134, 135, 136, 137, 138, -1, + 140, -1, 142, 143, 144, -1, 146, -1, 148, -1, + -1, -1, 152, 153, 154, -1, 156, 157, -1, 159, + -1, 161, 162, 163, 164, 165, -1, 167, 168, 169, + -1, 171, 172, 173, 174, 175, 176, -1, 178, -1, + 180, 181, 182, 183, 184, 185, 186, -1, 188, -1, + 190, -1, -1, 193, -1, 195, 196, 197, 198, 199, + 200, 201, -1, 203, 204, -1, 206, -1, -1, 209, + 210, 211, -1, -1, 214, 215, 216, 217, 218, 219, + 220, 221, 222, 223, 224, 225, 226, -1, 228, 229, + 230, 231, -1, 233, 234, -1, 236, -1, 238, 239, + 240, 241, 242, 243, -1, 245, -1, -1, 248, 249, + 250, -1, -1, 253, -1, -1, -1, 257, 258, 259, + 260, 261, 262, 263, 264, -1, 266, 267, 268, 269, + 270, 271, 272, -1, 274, 275, 276, 277, 278, 279, + 280, 281, 282, 283, 284, 285, -1, 287, 288, 289, + 290, 291, 292, 293, 294, 295, 296, -1, 298, 299, + -1, 301, 302, 303, 304, 305, 306, 307, 308, 309, + 310, 311, -1, 313, 314, 315, 316, 317, -1, 319, + 320, 321, 322, -1, 324, 325, 326, -1, 328, 329, + 330, 331, 332, 333, 334, 335, 336, 337, 338, -1, + 340, 341, -1, 343, 344, 345, 346, 347, 348, -1, + 350, 351, -1, -1, 354, 355, 356, 357, -1, 359, + 360, 361, 362, 363, 364, 365, -1, -1, 368, 369, + 370, 371, 372, -1, -1, 375, 376, 377, 378, 379, + 380, 381, -1, 383, -1, 385, 386, 387, -1, -1, + 390, -1, -1, 393, 394, 395, 396, 397, 398, 399, + 400, 401, 402, 403, 404, 405, 406, 407, 408, 409, + 3, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 14, 15, 16, 17, 18, 19, 20, 21, -1, + 23, 24, 25, -1, -1, -1, -1, -1, -1, -1, + 33, 34, -1, 36, 37, -1, 39, 40, 41, 42, + 43, -1, 45, 46, -1, 48, 49, 50, 51, 52, + -1, -1, 55, 56, 57, 58, 59, -1, 61, 62, + 63, 64, 65, -1, -1, -1, 69, 70, 71, 72, + -1, 74, 75, -1, 77, 78, 79, 80, 81, 82, + -1, -1, 85, 86, -1, -1, -1, -1, -1, -1, + -1, 94, 95, 96, 97, 98, 99, 100, 101, 102, + -1, 104, -1, 106, 107, 108, 109, 110, -1, 112, + 113, 114, -1, -1, 117, 118, 119, 120, 121, -1, + 123, 124, 125, -1, 127, 128, -1, 130, 131, 132, + 133, 134, 135, 136, 137, 138, -1, 140, -1, 142, + 143, 144, -1, 146, -1, 148, -1, -1, -1, 152, + 153, 154, -1, 156, 157, -1, 159, -1, 161, 162, + 163, 164, 165, -1, 167, 168, 169, -1, 171, 172, + 173, 174, 175, 176, -1, 178, -1, 180, 181, 182, + 183, 184, 185, 186, -1, 188, -1, 190, -1, -1, + 193, -1, 195, 196, 197, 198, 199, 200, 201, -1, + 203, 204, -1, 206, -1, -1, 209, 210, 211, -1, + -1, 214, 215, 216, 217, 218, 219, 220, 221, 222, + 223, 224, 225, 226, -1, 228, 229, 230, 231, -1, + 233, 234, -1, 236, -1, 238, 239, 240, 241, 242, + 243, -1, 245, -1, -1, 248, 249, 250, -1, -1, + 253, -1, -1, -1, 257, 258, 259, 260, 261, 262, + 263, 264, -1, 266, 267, 268, 269, 270, 271, 272, + -1, 274, 275, 276, 277, 278, 279, 280, 281, 282, + 283, 284, 285, -1, 287, 288, 289, 290, 291, 292, + 293, 294, 295, 296, -1, 298, 299, -1, 301, 302, + 303, 304, 305, 306, 307, 308, 309, 310, 311, -1, + 313, 314, 315, 316, 317, -1, 319, 320, 321, 322, + -1, 324, 325, 326, -1, 328, 329, 330, 331, 332, + 333, 334, 335, 336, 337, 338, -1, 340, 341, -1, + 343, 344, 345, 346, 347, 348, -1, 350, 351, -1, + -1, 354, 355, 356, 357, -1, 359, 360, 361, 362, + 363, 364, 365, -1, -1, 368, 369, 370, 371, 372, + -1, -1, 375, 376, 377, 378, 379, 380, 381, -1, + 383, -1, 385, 386, 387, -1, -1, 390, -1, -1, + 393, 394, 395, 396, 397, 398, 399, 400, 401, 402, + 403, 404, 405, 406, 407, 408, 409, 3, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 14, 15, + 16, 17, 18, 19, 20, 21, -1, 23, 24, 25, + -1, -1, -1, -1, -1, 31, -1, 33, 34, -1, + 36, 37, -1, 39, 40, 41, 42, 43, -1, 45, + 46, -1, 48, 49, 50, 51, 52, -1, -1, 55, + 56, 57, 58, 59, -1, 61, 62, 63, 64, 65, + -1, -1, -1, 69, 70, 71, 72, -1, 74, 75, + -1, 77, 78, 79, 80, 81, 82, -1, -1, 85, + 86, -1, -1, -1, -1, -1, -1, -1, 94, 95, + 96, 97, 98, 99, 100, 101, 102, -1, 104, -1, + 106, 107, 108, 109, 110, -1, 112, 113, 114, -1, + -1, 117, 118, 119, 120, 121, -1, 123, 124, 125, + -1, 127, 128, -1, 130, 131, 132, 133, 134, 135, + 136, 137, 138, -1, 140, -1, 142, 143, 144, -1, + 146, -1, 148, -1, -1, -1, 152, 153, 154, -1, + 156, 157, -1, 159, -1, 161, 162, 163, 164, 165, + -1, 167, 168, 169, -1, 171, 172, 173, 174, 175, + 176, -1, 178, -1, 180, 181, 182, 183, 184, 185, + 186, -1, 188, -1, 190, -1, -1, 193, -1, 195, + 196, 197, 198, 199, 200, 201, -1, 203, 204, -1, + 206, -1, -1, 209, 210, 211, -1, -1, 214, 215, + 216, 217, 218, 219, 220, 221, 222, 223, 224, 225, + 226, -1, 228, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, 243, -1, 245, + -1, -1, 248, 249, 250, -1, -1, 253, -1, -1, + -1, 257, 258, 259, 260, 261, 262, 263, 264, -1, + 266, 267, 268, 269, 270, 271, 272, -1, 274, 275, + 276, 277, 278, 279, 280, 281, 282, 283, 284, 285, + -1, 287, 288, 289, 290, 291, 292, 293, 294, 295, + 296, -1, 298, 299, -1, 301, 302, 303, 304, 305, + 306, 307, 308, 309, 310, 311, -1, 313, 314, 315, + 316, 317, -1, -1, 320, 321, 322, -1, 324, 325, + 326, -1, 328, 329, 330, 331, 332, 333, 334, 335, + 336, 337, 338, -1, 340, 341, -1, 343, 344, 345, + 346, 347, 348, -1, 350, 351, -1, -1, 354, 355, + 356, 357, -1, 359, 360, 361, 362, 363, 364, 365, + -1, -1, 368, 369, 370, 371, 372, -1, -1, 375, + 376, 377, 378, 379, 380, 381, -1, 383, -1, 385, + 386, 387, -1, -1, 390, -1, -1, 393, 394, 395, + 396, 397, 398, 399, 400, 401, 402, 403, 404, 405, + 406, 407, 408, 409, 3, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 14, 15, 16, 17, 18, + 19, 20, 21, -1, 23, 24, 25, -1, -1, -1, + -1, -1, -1, -1, 33, 34, -1, 36, 37, -1, + 39, 40, 41, 42, 43, -1, 45, 46, -1, 48, + 49, 50, 51, 52, -1, -1, 55, 56, 57, 58, + 59, -1, 61, 62, 63, 64, 65, -1, -1, -1, + 69, 70, 71, 72, -1, 74, 75, -1, 77, 78, + 79, 80, 81, 82, -1, -1, 85, 86, -1, -1, + -1, -1, -1, -1, -1, 94, 95, 96, 97, 98, + 99, 100, 101, 102, -1, 104, -1, 106, 107, 108, + 109, 110, -1, 112, 113, 114, -1, -1, 117, 118, + 119, 120, 121, -1, 123, 124, 125, -1, 127, 128, + -1, 130, 131, 132, 133, 134, 135, 136, 137, 138, + -1, 140, -1, 142, 143, 144, -1, 146, -1, 148, + -1, -1, -1, 152, 153, 154, -1, 156, 157, -1, + 159, -1, 161, 162, 163, 164, 165, -1, 167, 168, + 169, -1, 171, 172, 173, 174, 175, 176, -1, 178, + -1, 180, 181, 182, 183, 184, 185, 186, -1, 188, + -1, 190, -1, -1, 193, -1, 195, 196, 197, 198, + 199, 200, 201, -1, 203, 204, -1, 206, -1, -1, + 209, 210, 211, -1, -1, 214, 215, 216, 217, 218, + 219, 220, 221, 222, 223, 224, 225, 226, -1, 228, + 229, 230, 231, -1, 233, 234, -1, 236, -1, 238, + 239, 240, 241, 242, 243, -1, 245, -1, -1, 248, + 249, 250, -1, -1, 253, -1, -1, -1, 257, 258, + 259, 260, 261, 262, 263, 264, -1, 266, 267, 268, + 269, 270, 271, 272, -1, 274, 275, 276, 277, 278, + 279, 280, 281, 282, 283, 284, 285, -1, 287, 288, + 289, 290, 291, 292, 293, 294, 295, 296, -1, 298, + 299, -1, 301, 302, 303, 304, 305, 306, 307, 308, + 309, 310, 311, -1, 313, 314, 315, 316, 317, -1, + 319, 320, 321, 322, -1, 324, 325, 326, -1, 328, + 329, 330, 331, 332, 333, 334, 335, 336, 337, 338, + -1, 340, 341, -1, 343, 344, 345, 346, 347, 348, + -1, 350, 351, -1, -1, 354, 355, 356, 357, -1, + 359, 360, 361, 362, 363, 364, 365, -1, -1, 368, + 369, 370, 371, 372, -1, -1, 375, 376, 377, 378, + 379, 380, 381, -1, 383, -1, 385, 386, 387, -1, + -1, 390, -1, -1, 393, 394, 395, 396, 397, 398, + 399, 400, 401, 402, 403, 404, 405, 406, 407, 408, + 409, 3, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 14, 15, 16, 17, 18, 19, 20, 21, + -1, 23, 24, 25, -1, -1, -1, -1, -1, -1, + -1, 33, 34, -1, 36, 37, -1, 39, 40, 41, + 42, 43, -1, 45, 46, -1, 48, 49, 50, 51, + 52, -1, -1, 55, 56, 57, 58, 59, -1, 61, + 62, 63, 64, 65, -1, -1, -1, 69, 70, 71, + 72, -1, 74, 75, -1, 77, 78, 79, 80, 81, + 82, -1, -1, 85, 86, -1, -1, -1, -1, -1, + -1, -1, 94, 95, 96, 97, 98, 99, 100, 101, + 102, -1, 104, -1, 106, 107, 108, 109, 110, -1, + 112, 113, 114, -1, -1, 117, 118, 119, 120, 121, + -1, 123, 124, 125, -1, 127, 128, -1, 130, 131, + 132, 133, 134, 135, 136, 137, 138, -1, 140, -1, + 142, 143, 144, -1, 146, -1, 148, -1, -1, -1, + 152, 153, 154, -1, 156, 157, -1, 159, -1, 161, + 162, 163, 164, 165, -1, 167, 168, 169, -1, 171, + 172, 173, 174, 175, 176, -1, 178, -1, 180, 181, + 182, 183, 184, 185, 186, -1, 188, -1, 190, -1, + -1, 193, -1, 195, 196, 197, 198, 199, 200, 201, + -1, 203, 204, -1, 206, -1, -1, 209, 210, 211, + -1, -1, 214, 215, 216, 217, 218, 219, 220, 221, + 222, 223, 224, 225, 226, -1, 228, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, 243, -1, 245, -1, -1, 248, 249, 250, -1, + -1, 253, -1, -1, -1, 257, 258, 259, 260, 261, + 262, 263, 264, -1, 266, 267, 268, 269, 270, 271, + 272, -1, 274, 275, 276, 277, 278, 279, 280, 281, + 282, 283, 284, 285, -1, 287, 288, 289, 290, 291, + 292, 293, 294, 295, 296, -1, 298, 299, -1, 301, + 302, 303, 304, 305, 306, 307, 308, 309, 310, 311, + -1, 313, 314, 315, 316, 317, -1, 319, 320, 321, + 322, -1, 324, 325, 326, -1, 328, 329, 330, 331, + 332, 333, 334, 335, 336, 337, 338, -1, 340, 341, + -1, 343, 344, 345, 346, 347, 348, -1, 350, 351, + -1, -1, 354, 355, 356, 357, -1, 359, 360, 361, + 362, 363, 364, 365, -1, -1, 368, 369, 370, 371, + 372, -1, -1, 375, 376, 377, 378, 379, 380, 381, + -1, 383, -1, 385, 386, 387, -1, -1, 390, -1, + -1, 393, 394, 395, 396, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 407, 408, 409, 3, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 14, + 15, 16, 17, 18, 19, 20, 21, -1, 23, 24, + 25, -1, -1, -1, -1, -1, -1, -1, 33, 34, + -1, 36, 37, -1, 39, 40, 41, 42, 43, -1, + 45, 46, -1, 48, 49, 50, 51, 52, -1, -1, + 55, 56, 57, 58, 59, -1, 61, 62, 63, 64, + 65, -1, -1, -1, 69, 70, 71, 72, -1, 74, + 75, -1, 77, 78, 79, 80, 81, 82, -1, -1, + 85, 86, -1, -1, -1, -1, -1, -1, -1, 94, + 95, 96, 97, 98, 99, 100, 101, 102, -1, 104, + -1, 106, 107, 108, 109, 110, -1, 112, 113, 114, + -1, -1, 117, 118, 119, 120, 121, -1, 123, 124, + 125, -1, 127, 128, -1, 130, 131, 132, 133, 134, + 135, 136, 137, 138, -1, 140, -1, 142, 143, 144, + -1, 146, -1, 148, -1, -1, -1, 152, 153, 154, + -1, 156, 157, -1, 159, -1, 161, 162, 163, 164, + 165, -1, 167, 168, 169, -1, 171, 172, 173, 174, + 175, 176, -1, 178, -1, 180, 181, 182, 183, 184, + 185, 186, -1, 188, -1, 190, -1, -1, 193, -1, + 195, 196, 197, 198, 199, 200, 201, -1, 203, 204, + -1, 206, -1, -1, 209, 210, 211, -1, -1, 214, + 215, 216, 217, 218, 219, 220, 221, 222, 223, 224, + 225, 226, -1, 228, 229, 230, 231, -1, 233, 234, + -1, 236, -1, 238, 239, 240, 241, 242, 243, -1, + 245, -1, -1, 248, 249, 250, -1, -1, 253, -1, + -1, -1, 257, 258, 259, 260, 261, 262, 263, 264, + -1, 266, 267, 268, 269, 270, 271, 272, -1, 274, + 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, + 285, -1, 287, 288, 289, 290, 291, 292, 293, 294, + 295, 296, -1, 298, 299, -1, 301, 302, 303, 304, + 305, 306, 307, 308, 309, 310, 311, -1, 313, 314, + 315, 316, 317, -1, 319, 320, 321, 322, -1, 324, + 325, 326, -1, 328, 329, 330, 331, 332, 333, 334, + 335, 336, 337, 338, -1, 340, 341, -1, 343, 344, + 345, 346, 347, 348, -1, 350, 351, -1, -1, 354, + 355, 356, 357, -1, 359, 360, 361, 362, 363, 364, + 365, -1, -1, 368, 369, 370, 371, 372, -1, -1, + 375, 376, 377, 378, 379, 380, 381, -1, 383, -1, + 385, 386, 387, -1, -1, 390, -1, -1, 393, 394, + 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 407, 408, 409, 3, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 14, 15, 16, 17, + 18, 19, 20, 21, -1, 23, 24, 25, -1, -1, + -1, -1, -1, -1, -1, 33, 34, -1, 36, 37, + -1, 39, 40, 41, 42, 43, -1, 45, 46, -1, + 48, 49, 50, 51, 52, -1, -1, 55, 56, 57, + 58, 59, -1, 61, 62, 63, 64, 65, -1, -1, + -1, 69, 70, 71, 72, -1, 74, 75, -1, 77, + 78, 79, 80, 81, 82, -1, -1, 85, 86, -1, + -1, -1, -1, -1, -1, -1, 94, 95, 96, 97, + 98, 99, 100, 101, 102, -1, 104, -1, 106, 107, + 108, 109, 110, -1, 112, 113, 114, -1, -1, 117, + 118, 119, 120, 121, -1, 123, 124, 125, -1, 127, + 128, -1, 130, 131, 132, 133, 134, 135, 136, 137, + 138, -1, 140, -1, 142, 143, 144, -1, 146, -1, + 148, -1, -1, -1, 152, 153, 154, -1, 156, 157, + -1, 159, -1, 161, 162, 163, 164, 165, -1, 167, + 168, 169, -1, 171, 172, 173, 174, 175, 176, -1, + 178, -1, 180, 181, 182, 183, 184, 185, 186, -1, + 188, -1, 190, -1, -1, 193, -1, 195, 196, 197, + 198, 199, 200, 201, -1, 203, 204, -1, 206, -1, + -1, 209, 210, 211, -1, -1, 214, 215, 216, 217, + 218, 219, 220, 221, 222, 223, 224, 225, 226, -1, + 228, 229, 230, 231, -1, 233, 234, -1, 236, -1, + 238, 239, 240, 241, 242, 243, -1, 245, -1, -1, + 248, 249, 250, -1, -1, 253, -1, -1, -1, 257, + 258, 259, 260, 261, 262, 263, 264, -1, 266, 267, + 268, 269, 270, 271, 272, -1, 274, 275, 276, 277, + 278, 279, 280, 281, 282, 283, 284, 285, -1, 287, + 288, 289, 290, 291, 292, 293, 294, 295, 296, -1, + 298, 299, -1, 301, 302, 303, 304, 305, 306, 307, + 308, 309, 310, 311, -1, 313, 314, 315, 316, 317, + -1, 319, 320, 321, 322, -1, 324, 325, 326, -1, + 328, 329, 330, 331, 332, 333, 334, 335, 336, 337, + 338, -1, 340, 341, -1, 343, 344, 345, 346, 347, + 348, -1, 350, 351, -1, -1, 354, 355, 356, 357, + -1, 359, 360, 361, 362, 363, 364, 365, -1, -1, + 368, 369, 370, 371, 372, -1, -1, 375, 376, 377, + 378, 379, 380, 381, -1, 383, -1, 385, 386, 387, + -1, -1, 390, -1, -1, 393, 394, 395, 396, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, + 408, 409, 3, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 14, 15, 16, 17, 18, 19, 20, + 21, -1, 23, 24, 25, -1, -1, -1, -1, -1, + -1, -1, 33, 34, -1, 36, 37, -1, 39, 40, + 41, 42, 43, -1, 45, 46, -1, 48, 49, 50, + 51, 52, -1, -1, 55, 56, 57, 58, 59, -1, + 61, 62, 63, 64, 65, -1, -1, -1, 69, 70, + 71, 72, -1, 74, 75, -1, 77, 78, 79, 80, + 81, 82, -1, -1, 85, 86, -1, -1, -1, -1, + -1, -1, -1, 94, 95, 96, 97, 98, 99, 100, + 101, 102, -1, 104, -1, 106, 107, 108, 109, 110, + -1, 112, 113, 114, -1, -1, 117, 118, 119, 120, + 121, -1, 123, 124, 125, -1, 127, 128, -1, 130, + 131, 132, 133, 134, 135, 136, 137, 138, -1, 140, + -1, 142, 143, 144, -1, 146, -1, 148, -1, -1, + -1, 152, 153, 154, -1, 156, 157, -1, 159, -1, + 161, 162, 163, 164, 165, -1, 167, 168, 169, -1, + 171, 172, 173, 174, 175, 176, -1, 178, -1, 180, + 181, 182, 183, 184, 185, 186, -1, 188, -1, 190, + -1, -1, 193, -1, 195, 196, 197, 198, 199, 200, + 201, -1, 203, 204, -1, 206, -1, -1, 209, 210, + 211, -1, -1, 214, 215, 216, 217, 218, 219, 220, + 221, 222, 223, 224, 225, 226, -1, 228, 229, 230, + 231, -1, 233, 234, -1, 236, -1, 238, 239, 240, + 241, 242, 243, -1, 245, -1, -1, 248, 249, 250, + -1, -1, 253, -1, -1, -1, 257, 258, 259, 260, + 261, 262, 263, 264, -1, 266, 267, 268, 269, 270, + 271, 272, -1, 274, 275, 276, 277, 278, 279, 280, + 281, 282, 283, 284, 285, -1, 287, 288, 289, 290, + 291, 292, 293, 294, 295, 296, -1, 298, 299, -1, + 301, 302, 303, 304, 305, 306, 307, 308, 309, 310, + 311, -1, 313, 314, 315, 316, 317, -1, 319, 320, + 321, 322, -1, 324, 325, 326, -1, 328, 329, 330, + 331, 332, 333, 334, 335, 336, 337, 338, -1, 340, + 341, -1, 343, 344, 345, 346, 347, 348, -1, 350, + 351, -1, -1, 354, 355, 356, 357, -1, 359, 360, + 361, 362, 363, 364, 365, -1, -1, 368, 369, 370, + 371, 372, -1, -1, 375, 376, 377, 378, 379, 380, + 381, -1, 383, -1, 385, 386, 387, -1, -1, 390, + -1, -1, 393, 394, 395, 396, 397, 398, 399, 400, + 401, 402, 403, 404, 405, 406, 407, 408, 409, 3, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, -1, -1, -1, 33, + 34, -1, 36, 37, 38, 39, 40, 41, -1, 43, + 44, 45, 46, -1, 48, 49, 50, 51, 52, -1, + -1, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, -1, -1, 67, -1, 69, 70, 71, 72, 73, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + 84, 85, 86, -1, -1, -1, 90, -1, -1, -1, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + -1, 135, 136, 137, -1, -1, 140, -1, 142, 143, + 144, -1, 146, -1, 148, 149, -1, 151, 152, 153, + 154, -1, 156, -1, -1, 159, -1, 161, 162, 163, + 164, 165, 166, 167, 168, 169, 170, 171, 172, 173, + 174, 175, 176, -1, 178, 179, 180, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, 191, 192, 193, + 194, 195, 196, 197, 198, 199, 200, 201, -1, 203, + -1, 205, 206, 207, -1, 209, 210, 211, -1, -1, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, 227, 228, 229, 230, -1, -1, 233, + 234, 235, 236, -1, -1, 239, 240, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, 253, + 254, 255, 256, -1, 258, 259, 260, 261, 262, 263, + 264, -1, 266, -1, 268, -1, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, 300, 301, 302, -1, + 304, 305, 306, 307, 308, 309, 310, 311, -1, 313, + 314, 315, 316, 317, -1, 319, 320, 321, 322, 323, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, -1, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, -1, 356, -1, -1, 359, 360, 361, 362, 363, + 364, 365, -1, -1, 368, 369, 370, 371, 372, -1, + -1, 375, 376, 377, 378, 379, -1, 381, 382, 383, + 384, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, -1, 3, -1, -1, -1, -1, + -1, -1, -1, 407, 408, 409, 14, 15, 16, 17, + 18, 19, 20, 21, -1, 23, 24, 25, -1, -1, + -1, -1, -1, -1, -1, 33, 34, -1, 36, 37, + -1, 39, 40, 41, 42, 43, -1, 45, 46, -1, + 48, 49, 50, 51, 52, -1, -1, 55, 56, 57, + 58, 59, -1, 61, 62, 63, 64, 65, -1, -1, + -1, 69, 70, 71, 72, -1, 74, 75, -1, 77, + 78, 79, 80, 81, 82, -1, -1, 85, 86, -1, + -1, -1, -1, -1, -1, -1, 94, 95, 96, 97, + 98, 99, 100, 101, 102, -1, 104, -1, 106, 107, + 108, 109, 110, -1, 112, 113, 114, -1, -1, 117, + 118, 119, 120, 121, -1, 123, 124, 125, -1, 127, + 128, -1, 130, 131, 132, 133, 134, 135, 136, 137, + 138, -1, 140, -1, 142, 143, 144, -1, 146, -1, + 148, -1, -1, -1, 152, 153, 154, -1, 156, 157, + -1, 159, -1, 161, 162, 163, 164, 165, -1, 167, + 168, 169, -1, 171, 172, 173, 174, 175, 176, -1, + 178, -1, 180, 181, 182, 183, 184, 185, 186, -1, + 188, -1, 190, -1, -1, 193, -1, 195, 196, 197, + 198, 199, 200, 201, -1, 203, 204, -1, 206, -1, + -1, 209, 210, 211, -1, -1, 214, 215, 216, 217, + 218, 219, 220, 221, 222, 223, 224, 225, 226, -1, + 228, 229, 230, 231, -1, 233, 234, -1, 236, -1, + 238, 239, 240, 241, 242, 243, -1, 245, -1, -1, + 248, 249, 250, -1, -1, 253, -1, -1, -1, 257, + 258, 259, 260, 261, 262, 263, 264, -1, 266, 267, + 268, 269, 270, 271, 272, -1, 274, 275, 276, 277, + 278, 279, 280, 281, 282, 283, 284, 285, -1, 287, + 288, 289, 290, 291, 292, 293, 294, 295, 296, -1, + 298, 299, -1, 301, 302, 303, 304, 305, 306, 307, + 308, 309, 310, 311, -1, 313, 314, 315, 316, 317, + -1, 319, 320, 321, 322, -1, 324, 325, 326, -1, + 328, 329, 330, 331, 332, 333, 334, 335, 336, 337, + 338, -1, 340, 341, -1, 343, 344, 345, 346, 347, + 348, -1, 350, 351, -1, -1, 354, 355, 356, 357, + -1, 359, 360, 361, 362, 363, 364, 365, -1, -1, + 368, 369, 370, 371, 372, -1, -1, 375, 376, 377, + 378, 379, 380, 381, -1, 383, -1, 385, 386, 387, + -1, -1, 390, -1, -1, 393, 394, 395, 396, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, + 408, 409, 3, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 14, 15, 16, 17, 18, 19, 20, + 21, -1, 23, 24, 25, -1, -1, -1, -1, -1, + -1, -1, 33, 34, -1, 36, 37, -1, 39, 40, + 41, 42, 43, -1, 45, 46, -1, 48, 49, 50, + 51, 52, -1, -1, 55, 56, 57, 58, 59, -1, + 61, 62, 63, 64, 65, -1, -1, -1, 69, 70, + 71, 72, -1, 74, 75, -1, 77, 78, 79, 80, + 81, 82, -1, -1, 85, 86, -1, -1, -1, -1, + -1, -1, -1, 94, 95, 96, 97, 98, 99, 100, + 101, 102, -1, 104, -1, 106, 107, 108, 109, 110, + -1, 112, 113, 114, -1, -1, 117, 118, 119, 120, + 121, -1, 123, 124, 125, -1, 127, 128, -1, 130, + 131, 132, 133, 134, 135, 136, 137, 138, -1, 140, + -1, 142, 143, 144, -1, 146, -1, 148, -1, -1, + -1, 152, 153, 154, -1, 156, 157, -1, 159, -1, + 161, 162, 163, 164, 165, -1, 167, 168, 169, -1, + 171, 172, 173, 174, 175, 176, -1, 178, -1, 180, + 181, 182, 183, 184, 185, 186, -1, 188, -1, 190, + -1, -1, 193, -1, 195, 196, 197, 198, 199, 200, + 201, -1, 203, 204, -1, 206, -1, -1, 209, 210, + 211, -1, -1, 214, 215, 216, 217, 218, 219, 220, + 221, 222, 223, 224, 225, 226, -1, 228, 229, 230, + 231, -1, 233, 234, -1, 236, -1, 238, 239, 240, + 241, 242, 243, -1, 245, -1, -1, 248, 249, 250, + -1, -1, 253, -1, -1, -1, 257, 258, 259, 260, + 261, 262, 263, 264, -1, 266, 267, 268, 269, 270, + 271, 272, -1, 274, 275, 276, 277, 278, 279, 280, + 281, 282, 283, 284, 285, -1, 287, 288, 289, 290, + 291, 292, 293, 294, 295, 296, -1, 298, 299, -1, + 301, 302, 303, 304, 305, 306, 307, 308, 309, 310, + 311, -1, 313, 314, 315, 316, 317, -1, 319, 320, + 321, 322, -1, 324, 325, 326, -1, 328, 329, 330, + 331, 332, 333, 334, 335, 336, 337, 338, -1, 340, + 341, -1, 343, 344, 345, 346, 347, 348, -1, 350, + 351, -1, -1, 354, 355, 356, 357, -1, 359, 360, + 361, 362, 363, 364, 365, -1, -1, 368, 369, 370, + 371, 372, -1, -1, 375, 376, 377, 378, 379, 380, + 381, -1, 383, -1, 385, 386, 387, -1, -1, 390, + -1, -1, 393, 394, 395, 396, 397, 398, 399, 400, + 401, 402, 403, 404, 405, 406, 407, 408, 409, 3, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, -1, -1, -1, 33, + 34, -1, 36, 37, -1, 39, 40, 41, 42, 43, + -1, 45, 46, -1, 48, 49, 50, 51, 52, -1, + -1, 55, 56, 57, 58, 59, -1, 61, 62, 63, + 64, 65, -1, -1, -1, 69, 70, 71, 72, -1, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + -1, 85, 86, -1, -1, -1, -1, -1, -1, -1, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + 134, 135, 136, 137, 138, -1, 140, -1, 142, 143, + 144, -1, 146, -1, 148, -1, -1, -1, 152, 153, + 154, -1, 156, 157, -1, 159, -1, 161, 162, 163, + 164, 165, -1, 167, 168, 169, -1, 171, 172, 173, + 174, 175, 176, -1, 178, -1, 180, 181, 182, 183, + 184, 185, 186, -1, 188, -1, 190, -1, -1, 193, + -1, 195, 196, 197, 198, 199, 200, 201, -1, 203, + 204, -1, 206, -1, -1, 209, 210, 211, -1, -1, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, -1, 228, 229, 230, 231, -1, 233, + 234, -1, 236, -1, 238, 239, 240, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, 253, + -1, -1, -1, 257, 258, 259, 260, 261, 262, 263, + 264, -1, 266, 267, 268, 269, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, -1, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, -1, 313, + 314, 315, 316, 317, -1, 319, 320, 321, 322, -1, + 324, 325, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, 338, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, 350, 351, -1, -1, + 354, 355, 356, 357, -1, 359, 360, 361, 362, 363, + 364, 365, -1, -1, 368, 369, 370, 371, 372, -1, + -1, 375, 376, 377, 378, 379, 380, 381, -1, 383, + -1, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 407, 408, 409, 3, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 14, 15, 16, + 17, 18, 19, 20, 21, -1, 23, 24, 25, -1, + -1, -1, -1, -1, -1, -1, 33, 34, -1, 36, + 37, 38, 39, 40, 41, -1, 43, 44, 45, 46, + -1, 48, 49, 50, 51, 52, -1, -1, 55, 56, + 57, 58, 59, -1, 61, 62, 63, 64, -1, -1, + 67, -1, 69, 70, 71, 72, 73, 74, 75, -1, + 77, 78, 79, 80, 81, 82, -1, 84, 85, 86, + -1, -1, -1, 90, -1, -1, -1, 94, 95, 96, + 97, 98, 99, 100, 101, 102, -1, 104, -1, 106, + 107, 108, 109, 110, -1, 112, 113, 114, -1, -1, + 117, 118, 119, 120, 121, -1, 123, 124, 125, -1, + 127, 128, -1, 130, 131, 132, 133, -1, 135, 136, + 137, -1, -1, 140, -1, 142, 143, 144, -1, 146, + -1, 148, 149, -1, 151, 152, 153, 154, -1, 156, + -1, -1, 159, -1, 161, 162, 163, 164, 165, 166, + 167, 168, 169, -1, 171, 172, 173, 174, 175, 176, + -1, 178, 179, -1, 181, 182, 183, 184, 185, 186, + -1, 188, -1, 190, 191, 192, 193, 194, 195, 196, + 197, 198, 199, 200, 201, -1, 203, -1, 205, 206, + 207, -1, 209, 210, 211, -1, -1, 214, 215, 216, + 217, 218, 219, 220, 221, 222, 223, 224, 225, 226, + 227, 228, 229, 230, -1, -1, 233, 234, 235, 236, + 237, -1, 239, 240, 241, 242, 243, -1, 245, -1, + -1, 248, 249, 250, -1, -1, -1, 254, 255, 256, + -1, 258, 259, 260, 261, 262, 263, 264, -1, 266, + -1, 268, -1, 270, 271, 272, -1, 274, 275, 276, + 277, 278, 279, 280, 281, 282, 283, 284, 285, -1, + 287, 288, 289, 290, 291, 292, 293, 294, 295, 296, + -1, 298, 299, 300, 301, 302, -1, 304, 305, 306, + 307, 308, 309, 310, 311, -1, 313, 314, 315, 316, + 317, -1, 319, 320, 321, 322, 323, 324, 325, 326, + -1, 328, 329, 330, 331, 332, 333, 334, 335, 336, + 337, -1, -1, 340, 341, 342, 343, 344, 345, 346, + 347, 348, -1, 350, 351, -1, -1, 354, -1, 356, + -1, -1, 359, 360, 361, 362, 363, 364, 365, -1, + -1, 368, 369, 370, 371, 372, -1, -1, 375, 376, + 377, 378, 379, -1, 381, -1, 383, 384, 385, 386, + 387, -1, -1, 390, -1, -1, 393, 394, 395, 396, + 397, -1, 3, -1, -1, -1, -1, -1, -1, -1, + 407, 408, 409, 14, 15, 16, 17, 18, 19, 20, + 21, -1, 23, 24, 25, -1, -1, -1, -1, -1, + -1, -1, 33, 34, -1, 36, 37, 38, 39, 40, + 41, -1, 43, 44, 45, 46, -1, 48, 49, 50, + 51, 52, -1, -1, 55, 56, 57, 58, 59, -1, + 61, 62, 63, 64, -1, -1, 67, -1, 69, 70, + 71, 72, 73, 74, 75, -1, 77, 78, 79, 80, + 81, 82, -1, 84, 85, 86, -1, -1, -1, 90, + -1, -1, -1, 94, 95, 96, 97, 98, 99, 100, + 101, 102, -1, 104, -1, 106, 107, 108, 109, 110, + -1, 112, 113, 114, -1, -1, 117, 118, 119, 120, + 121, -1, 123, 124, 125, -1, 127, 128, -1, 130, + 131, 132, 133, -1, 135, 136, 137, -1, -1, 140, + -1, 142, 143, 144, -1, 146, -1, 148, 149, -1, + 151, 152, 153, 154, -1, 156, -1, -1, 159, -1, + 161, 162, 163, 164, 165, 166, 167, 168, 169, -1, + 171, 172, 173, 174, 175, 176, -1, 178, 179, -1, + 181, 182, 183, 184, 185, 186, -1, 188, -1, 190, + 191, 192, 193, 194, 195, 196, 197, 198, 199, 200, + 201, -1, 203, -1, 205, 206, 207, -1, 209, 210, + 211, -1, -1, 214, 215, 216, 217, 218, 219, 220, + 221, 222, 223, 224, 225, 226, 227, 228, 229, 230, + 231, -1, 233, 234, 235, 236, -1, -1, 239, 240, + 241, 242, 243, -1, 245, -1, -1, 248, 249, 250, + -1, -1, -1, 254, 255, 256, -1, 258, 259, 260, + 261, 262, 263, 264, -1, 266, -1, 268, -1, 270, + 271, 272, -1, 274, 275, 276, 277, 278, 279, 280, + 281, 282, 283, 284, 285, -1, 287, 288, 289, 290, + 291, 292, 293, 294, 295, 296, -1, 298, 299, 300, + 301, 302, -1, 304, 305, 306, 307, 308, 309, 310, + 311, -1, 313, 314, 315, 316, 317, -1, 319, 320, + 321, 322, 323, 324, 325, 326, -1, 328, 329, 330, + 331, 332, 333, 334, 335, 336, 337, -1, -1, 340, + 341, -1, 343, 344, 345, 346, 347, 348, -1, 350, + 351, -1, -1, 354, -1, 356, -1, -1, 359, 360, + 361, 362, 363, 364, 365, -1, -1, 368, 369, 370, + 371, 372, -1, -1, 375, 376, 377, 378, 379, -1, + 381, -1, 383, 384, 385, 386, 387, -1, -1, 390, + -1, -1, 393, 394, 395, 396, 397, -1, 3, -1, + -1, -1, -1, -1, -1, -1, 407, 408, 409, 14, + 15, 16, 17, 18, 19, 20, 21, -1, 23, 24, + 25, -1, -1, -1, -1, -1, -1, -1, 33, 34, + -1, 36, 37, 38, 39, 40, 41, -1, 43, 44, + 45, 46, -1, 48, 49, 50, 51, 52, -1, -1, + 55, 56, 57, 58, 59, -1, 61, 62, 63, 64, + -1, -1, 67, -1, 69, 70, 71, 72, 73, 74, + 75, -1, 77, 78, 79, 80, 81, 82, -1, 84, + 85, 86, -1, -1, -1, 90, -1, -1, -1, 94, + 95, 96, 97, 98, 99, 100, 101, 102, -1, 104, + -1, 106, 107, 108, 109, 110, -1, 112, 113, 114, + -1, -1, 117, 118, 119, 120, 121, -1, 123, 124, + 125, -1, 127, 128, -1, 130, 131, 132, 133, -1, + 135, 136, 137, -1, -1, 140, -1, 142, 143, 144, + -1, 146, -1, 148, 149, -1, 151, 152, 153, 154, + -1, 156, -1, -1, 159, -1, 161, 162, 163, 164, + 165, 166, 167, 168, 169, -1, 171, 172, 173, 174, + 175, 176, -1, 178, 179, -1, 181, 182, 183, 184, + 185, 186, -1, 188, -1, 190, 191, 192, 193, 194, + 195, 196, 197, 198, 199, 200, 201, -1, 203, -1, + 205, 206, 207, -1, 209, 210, 211, -1, -1, 214, + 215, 216, 217, 218, 219, 220, 221, 222, 223, 224, + 225, 226, 227, 228, 229, 230, 231, -1, 233, 234, + 235, 236, -1, -1, 239, 240, 241, 242, 243, -1, + 245, -1, -1, 248, 249, 250, -1, -1, -1, 254, + 255, 256, -1, 258, 259, 260, 261, 262, 263, 264, + -1, 266, -1, 268, -1, 270, 271, 272, -1, 274, + 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, + 285, -1, 287, 288, 289, 290, 291, 292, 293, 294, + 295, 296, -1, 298, 299, 300, 301, 302, -1, 304, + 305, 306, 307, 308, 309, 310, 311, -1, 313, 314, + 315, 316, 317, -1, 319, 320, 321, 322, 323, 324, + 325, 326, -1, 328, 329, 330, 331, 332, 333, 334, + 335, 336, 337, -1, -1, 340, 341, -1, 343, 344, + 345, 346, 347, 348, -1, 350, 351, -1, -1, 354, + -1, 356, -1, -1, 359, 360, 361, 362, 363, 364, + 365, -1, -1, 368, 369, 370, 371, 372, -1, -1, + 375, 376, 377, 378, 379, -1, 381, -1, 383, 384, + 385, 386, 387, -1, -1, 390, -1, -1, 393, 394, + 395, 396, 397, -1, 3, -1, -1, -1, -1, -1, + -1, -1, 407, 408, 409, 14, 15, 16, 17, 18, + 19, 20, 21, -1, 23, 24, 25, -1, -1, -1, + -1, -1, -1, -1, 33, 34, -1, 36, 37, -1, + 39, 40, 41, 42, 43, -1, 45, 46, -1, 48, + 49, 50, 51, 52, -1, -1, 55, 56, 57, 58, + 59, -1, 61, 62, 63, 64, 65, -1, -1, -1, + 69, 70, 71, 72, -1, 74, 75, -1, 77, 78, + 79, 80, 81, 82, -1, -1, 85, 86, -1, -1, + -1, -1, -1, -1, -1, 94, 95, 96, 97, 98, + 99, 100, 101, 102, -1, 104, -1, 106, 107, 108, + 109, 110, -1, 112, 113, 114, -1, -1, 117, 118, + 119, 120, 121, -1, 123, 124, 125, -1, 127, 128, + -1, 130, 131, 132, 133, 134, 135, 136, 137, 138, + -1, 140, -1, 142, 143, 144, -1, 146, -1, 148, + -1, -1, -1, 152, 153, 154, -1, 156, 157, -1, + 159, -1, 161, 162, 163, 164, 165, -1, 167, 168, + 169, -1, 171, 172, 173, 174, 175, 176, -1, 178, + -1, 180, 181, 182, 183, 184, 185, 186, -1, 188, + -1, 190, -1, -1, 193, -1, 195, 196, 197, 198, + 199, 200, 201, -1, 203, 204, -1, 206, -1, -1, + 209, 210, 211, -1, -1, 214, 215, 216, 217, 218, + 219, 220, 221, 222, 223, 224, 225, 226, -1, 228, + 229, 230, 231, -1, 233, 234, -1, 236, -1, 238, + 239, 240, 241, 242, 243, -1, 245, -1, -1, 248, + 249, 250, -1, -1, 253, -1, -1, -1, 257, 258, + 259, 260, 261, -1, 263, 264, -1, 266, 267, 268, + 269, 270, 271, 272, -1, 274, 275, 276, 277, 278, + -1, 280, 281, 282, 283, 284, 285, -1, 287, 288, + 289, 290, 291, 292, 293, 294, 295, 296, -1, 298, + 299, -1, 301, 302, 303, -1, 305, 306, 307, 308, + 309, 310, 311, -1, 313, 314, 315, 316, 317, -1, + 319, 320, 321, 322, -1, 324, 325, 326, -1, 328, + 329, 330, 331, 332, 333, 334, 335, 336, 337, 338, + -1, 340, 341, -1, 343, 344, 345, 346, 347, 348, + -1, 350, 351, -1, -1, 354, 355, 356, 357, -1, + 359, 360, 361, 362, 363, 364, 365, -1, -1, 368, + 369, 370, 371, 372, -1, -1, 375, 376, 377, 378, + 379, 380, 381, -1, 383, -1, 385, 386, 387, -1, + -1, 390, -1, -1, 393, 394, 395, 396, 397, 398, + 399, 400, 401, 402, 403, 404, 405, 406, 407, 408, + 409, 3, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 14, 15, 16, 17, 18, 19, 20, 21, + -1, 23, 24, 25, -1, -1, -1, -1, -1, -1, + -1, 33, 34, -1, 36, 37, 38, 39, 40, 41, + -1, 43, 44, 45, 46, -1, 48, 49, 50, 51, + 52, -1, -1, 55, 56, 57, 58, 59, -1, 61, + 62, 63, 64, -1, -1, 67, -1, 69, 70, 71, + 72, 73, 74, 75, -1, 77, 78, 79, 80, 81, + 82, -1, 84, 85, 86, -1, -1, -1, 90, -1, + -1, -1, 94, 95, 96, 97, 98, 99, 100, 101, + 102, -1, 104, -1, 106, 107, 108, 109, 110, -1, + 112, 113, 114, -1, -1, 117, 118, 119, 120, 121, + -1, 123, 124, 125, -1, 127, 128, -1, 130, 131, + 132, 133, -1, 135, 136, 137, -1, -1, 140, -1, + 142, 143, 144, -1, 146, -1, 148, 149, -1, 151, + 152, 153, 154, -1, 156, -1, -1, 159, -1, 161, + 162, 163, 164, 165, 166, 167, 168, 169, -1, 171, + 172, 173, 174, 175, 176, -1, 178, 179, -1, 181, + 182, 183, 184, 185, 186, -1, 188, -1, 190, 191, + 192, 193, 194, 195, 196, 197, 198, 199, 200, 201, + -1, 203, -1, 205, 206, 207, -1, 209, 210, 211, + -1, -1, 214, 215, 216, 217, 218, 219, 220, 221, + 222, 223, 224, 225, 226, 227, 228, 229, 230, -1, + -1, 233, 234, 235, 236, -1, -1, 239, 240, 241, + 242, 243, -1, 245, -1, -1, 248, 249, 250, -1, + -1, -1, 254, 255, 256, -1, 258, 259, 260, 261, + 262, 263, 264, -1, 266, -1, 268, -1, 270, 271, + 272, -1, 274, 275, 276, 277, 278, 279, 280, 281, + 282, 283, 284, 285, -1, 287, 288, 289, 290, 291, + 292, 293, 294, 295, 296, -1, 298, 299, 300, 301, + 302, -1, 304, 305, 306, 307, 308, 309, 310, 311, + -1, 313, 314, 315, 316, 317, -1, 319, 320, 321, + 322, 323, 324, 325, 326, -1, 328, 329, 330, 331, + 332, 333, 334, 335, 336, 337, -1, -1, 340, 341, + -1, 343, 344, 345, 346, 347, 348, -1, 350, 351, + -1, -1, 354, -1, 356, -1, -1, 359, 360, 361, + 362, 363, 364, 365, -1, -1, 368, 369, 370, 371, + 372, -1, -1, 375, 376, 377, 378, 379, -1, 381, + -1, 383, 384, 385, 386, 387, -1, -1, 390, -1, + -1, 393, 394, 395, 396, 397, -1, 3, -1, -1, + -1, -1, -1, -1, -1, 407, 408, 409, 14, 15, + 16, 17, 18, 19, 20, 21, -1, 23, 24, 25, + -1, -1, -1, -1, -1, -1, -1, 33, 34, -1, + 36, 37, 38, 39, 40, 41, -1, 43, 44, 45, + 46, -1, 48, 49, 50, 51, 52, -1, -1, 55, + 56, 57, 58, 59, -1, 61, 62, 63, 64, -1, + -1, 67, -1, 69, 70, 71, 72, 73, 74, 75, + -1, 77, 78, 79, 80, 81, 82, -1, 84, 85, + 86, -1, -1, -1, 90, -1, -1, -1, 94, 95, + 96, 97, 98, 99, 100, 101, 102, -1, 104, -1, + 106, 107, 108, 109, 110, -1, 112, 113, 114, -1, + -1, 117, 118, 119, 120, 121, -1, 123, 124, 125, + -1, 127, 128, -1, 130, 131, 132, 133, -1, 135, + 136, 137, -1, -1, 140, -1, 142, 143, 144, -1, + 146, -1, 148, 149, -1, 151, 152, 153, 154, -1, + 156, -1, -1, 159, -1, 161, 162, 163, 164, 165, + 166, 167, 168, 169, -1, 171, 172, 173, 174, 175, + 176, -1, 178, 179, -1, 181, 182, 183, 184, 185, + 186, -1, 188, -1, 190, 191, 192, 193, 194, 195, + 196, 197, 198, 199, 200, 201, -1, 203, -1, 205, + 206, 207, -1, 209, 210, 211, -1, -1, 214, 215, + 216, 217, 218, 219, 220, 221, 222, 223, 224, 225, + 226, 227, 228, 229, 230, -1, -1, 233, 234, 235, + 236, -1, -1, 239, 240, 241, 242, 243, -1, 245, + -1, -1, 248, 249, 250, -1, -1, -1, 254, 255, + 256, -1, 258, 259, 260, 261, 262, 263, 264, -1, + 266, -1, 268, -1, 270, 271, 272, -1, 274, 275, + 276, 277, 278, 279, 280, 281, 282, 283, 284, 285, + -1, 287, 288, 289, 290, 291, 292, 293, 294, 295, + 296, -1, 298, 299, 300, 301, 302, -1, 304, 305, + 306, 307, 308, 309, 310, 311, -1, 313, 314, 315, + 316, 317, -1, 319, 320, 321, 322, 323, 324, 325, + 326, -1, 328, 329, 330, 331, 332, 333, 334, 335, + 336, 337, -1, -1, 340, 341, -1, 343, 344, 345, + 346, 347, 348, -1, 350, 351, -1, -1, 354, -1, + 356, -1, -1, 359, 360, 361, 362, 363, 364, 365, + -1, -1, 368, 369, 370, 371, 372, -1, -1, 375, + 376, 377, 378, 379, -1, 381, -1, 383, 384, 385, + 386, 387, -1, -1, 390, -1, -1, 393, 394, 395, + 396, 397, -1, 3, -1, -1, -1, -1, -1, -1, + -1, 407, 408, 409, 14, 15, 16, 17, 18, 19, + 20, 21, -1, 23, 24, 25, -1, -1, -1, -1, + -1, -1, -1, 33, 34, -1, 36, 37, 38, 39, + 40, 41, -1, 43, 44, 45, 46, -1, 48, 49, + 50, 51, 52, -1, -1, 55, 56, 57, 58, 59, + -1, 61, 62, 63, 64, -1, -1, 67, -1, 69, + 70, 71, 72, 73, 74, 75, -1, 77, 78, 79, + 80, 81, 82, -1, 84, 85, 86, -1, -1, -1, + 90, -1, -1, -1, 94, 95, 96, 97, 98, 99, + 100, 101, 102, -1, 104, -1, 106, 107, 108, 109, + 110, -1, 112, 113, 114, -1, -1, 117, 118, 119, + 120, 121, -1, 123, 124, 125, -1, 127, 128, -1, + 130, 131, 132, 133, -1, 135, 136, 137, -1, -1, + 140, -1, 142, 143, 144, -1, 146, -1, 148, 149, + -1, 151, 152, 153, 154, -1, 156, -1, -1, 159, + -1, 161, 162, 163, 164, 165, 166, 167, 168, 169, + -1, 171, 172, 173, 174, 175, 176, -1, 178, 179, + -1, 181, 182, 183, 184, 185, 186, -1, 188, -1, + 190, 191, 192, 193, 194, 195, 196, 197, 198, 199, + 200, 201, -1, 203, -1, 205, 206, 207, -1, 209, + 210, 211, -1, -1, 214, 215, 216, 217, 218, 219, + 220, 221, 222, 223, 224, 225, 226, 227, 228, 229, + 230, -1, -1, 233, 234, 235, 236, -1, -1, 239, + 240, 241, 242, 243, -1, 245, -1, -1, 248, 249, + 250, -1, -1, -1, 254, 255, 256, -1, 258, 259, + 260, 261, 262, 263, 264, -1, 266, -1, 268, -1, + 270, 271, 272, -1, 274, 275, 276, 277, 278, 279, + 280, 281, 282, 283, 284, 285, -1, 287, 288, 289, + 290, 291, 292, 293, 294, 295, 296, -1, 298, 299, + 300, 301, 302, -1, 304, 305, 306, 307, 308, 309, + 310, 311, -1, 313, 314, 315, 316, 317, -1, 319, + -1, 321, 322, 323, 324, 325, 326, -1, 328, 329, + 330, 331, 332, 333, 334, 335, 336, 337, -1, -1, + 340, 341, -1, 343, 344, 345, 346, 347, 348, -1, + 350, 351, -1, -1, 354, -1, 356, -1, -1, 359, + 360, 361, 362, 363, 364, 365, -1, -1, 368, 369, + 370, 371, 372, -1, -1, 375, 376, 377, 378, 379, + -1, 381, -1, 383, 384, 385, 386, 387, -1, -1, + 390, -1, -1, 393, 394, 395, 396, 397, -1, 3, + -1, -1, -1, -1, -1, -1, -1, 407, 408, 409, + 14, 15, 16, 17, 18, 19, 20, 21, -1, 23, + 24, 25, -1, -1, -1, -1, -1, -1, -1, 33, + 34, -1, 36, 37, 38, 39, 40, 41, -1, -1, + 44, -1, -1, -1, 48, 49, 50, 51, 52, -1, + -1, 55, 56, -1, -1, 59, -1, 61, 62, 63, + 64, -1, -1, 67, -1, 69, 70, 71, 72, 73, + 74, 75, -1, 77, 78, 79, 80, 81, 82, -1, + 84, 85, 86, -1, -1, -1, 90, -1, -1, -1, + 94, 95, 96, 97, 98, 99, -1, -1, 102, -1, + 104, -1, 106, 107, 108, 109, 110, -1, 112, 113, + 114, -1, -1, 117, 118, 119, 120, 121, -1, 123, + 124, 125, -1, 127, 128, -1, 130, 131, 132, 133, + -1, 135, 136, 137, -1, -1, 140, -1, 142, -1, + 144, -1, 146, -1, 148, 149, -1, 151, 152, 153, + 154, -1, 156, -1, -1, 159, -1, 161, 162, 163, + 164, 165, 166, 167, 168, 169, -1, 171, 172, 173, + 174, 175, 176, -1, 178, 179, -1, 181, 182, 183, + 184, -1, -1, -1, -1, -1, 190, 191, 192, 193, + 194, 195, 196, 197, 198, 199, 200, 201, -1, 203, + -1, 205, 206, 207, -1, 209, 210, 211, -1, -1, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, -1, 227, -1, 229, 230, -1, -1, 233, + 234, 235, 236, -1, -1, 239, -1, 241, 242, 243, + -1, 245, -1, -1, 248, 249, 250, -1, -1, -1, + 254, 255, 256, -1, 258, 259, 260, 261, 262, 263, + 264, -1, 266, -1, 268, -1, 270, 271, 272, -1, + 274, 275, 276, 277, 278, 279, 280, -1, 282, 283, + 284, 285, -1, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, -1, 298, 299, 300, 301, 302, -1, + 304, 305, 306, 307, 308, 309, 310, 311, -1, 313, + 314, 315, 316, 317, -1, 319, -1, 321, 322, 323, + 324, -1, 326, -1, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, -1, -1, 340, 341, -1, 343, + 344, 345, 346, 347, 348, -1, -1, -1, -1, -1, + 354, -1, 356, -1, -1, 359, 360, 361, 362, 363, + 364, 365, -1, -1, 368, 369, 370, 371, 372, -1, + -1, 375, 376, 377, 378, 379, -1, -1, -1, 383, + 384, 385, 386, 387, -1, -1, 390, -1, -1, 393, + 394, 395, 396, 397, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 407, 408, 409 +}; + +/* YYSTOS[STATE-NUM] -- The (internal number of the) accessing + symbol of state STATE-NUM. */ +static const yytype_uint16 yystos[] = +{ + 0, 14, 24, 26, 27, 41, 61, 63, 64, 69, + 71, 81, 83, 99, 102, 114, 116, 120, 126, 133, + 135, 141, 155, 209, 210, 215, 223, 234, 271, 282, + 287, 289, 294, 299, 302, 306, 311, 312, 319, 322, + 330, 342, 359, 369, 375, 380, 392, 426, 433, 434, + 435, 436, 442, 443, 445, 446, 447, 448, 449, 450, + 451, 453, 454, 458, 469, 472, 473, 476, 477, 478, + 489, 492, 493, 508, 545, 548, 549, 556, 562, 564, + 566, 567, 570, 573, 574, 578, 579, 588, 592, 593, + 594, 598, 599, 601, 602, 603, 616, 617, 618, 619, + 630, 631, 638, 639, 642, 643, 644, 645, 646, 651, + 653, 656, 660, 664, 665, 675, 676, 679, 684, 695, + 714, 717, 718, 719, 722, 725, 727, 729, 732, 735, + 736, 737, 744, 745, 747, 748, 749, 754, 756, 757, + 761, 762, 765, 766, 767, 769, 770, 771, 772, 774, + 777, 778, 783, 789, 792, 794, 795, 800, 802, 806, + 813, 817, 818, 819, 820, 821, 822, 825, 852, 354, + 394, 750, 21, 67, 80, 97, 103, 118, 136, 147, + 152, 158, 173, 198, 248, 276, 301, 307, 313, 316, + 342, 344, 348, 356, 361, 373, 386, 563, 750, 3, + 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, + 24, 25, 33, 34, 36, 37, 39, 40, 41, 42, + 43, 45, 46, 48, 49, 50, 51, 52, 55, 56, + 57, 58, 59, 61, 62, 63, 64, 65, 69, 70, + 71, 72, 74, 75, 77, 78, 79, 80, 81, 82, + 85, 86, 94, 95, 96, 97, 98, 99, 100, 101, + 102, 104, 106, 107, 108, 109, 110, 112, 113, 114, + 117, 118, 119, 120, 121, 123, 124, 125, 127, 128, + 130, 131, 132, 133, 134, 135, 136, 137, 138, 140, + 142, 143, 144, 146, 148, 152, 153, 154, 156, 157, + 159, 161, 162, 163, 164, 165, 167, 168, 169, 171, + 172, 173, 174, 175, 176, 178, 180, 181, 182, 183, + 184, 185, 186, 188, 190, 193, 195, 196, 197, 198, + 199, 200, 201, 203, 204, 206, 209, 210, 211, 214, + 215, 216, 217, 218, 219, 220, 221, 222, 223, 224, + 225, 226, 228, 229, 230, 231, 233, 234, 236, 238, + 239, 240, 241, 242, 243, 245, 248, 249, 250, 253, + 257, 258, 259, 260, 261, 262, 263, 264, 266, 267, + 268, 269, 270, 271, 272, 274, 275, 276, 277, 278, + 279, 280, 281, 282, 283, 284, 285, 287, 288, 289, + 290, 291, 292, 293, 294, 295, 296, 298, 299, 301, + 302, 303, 304, 305, 306, 307, 308, 309, 310, 311, + 313, 314, 315, 316, 317, 319, 320, 321, 322, 324, + 325, 326, 328, 329, 330, 331, 332, 333, 334, 335, + 336, 337, 338, 340, 341, 343, 344, 345, 346, 347, + 348, 350, 351, 354, 355, 356, 357, 359, 360, 361, + 362, 363, 364, 365, 368, 369, 370, 371, 372, 375, + 376, 377, 378, 379, 380, 381, 383, 385, 386, 387, + 390, 393, 394, 395, 396, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 407, 408, 409, 814, 957, + 969, 972, 973, 384, 779, 246, 272, 750, 44, 499, + 818, 21, 33, 54, 67, 76, 97, 103, 118, 136, + 147, 154, 158, 211, 248, 251, 301, 307, 316, 344, + 345, 347, 348, 356, 361, 367, 370, 373, 509, 634, + 685, 696, 22, 271, 957, 814, 22, 266, 345, 347, + 5, 197, 723, 724, 966, 21, 33, 54, 67, 80, + 97, 118, 136, 147, 152, 158, 173, 248, 258, 301, + 305, 307, 313, 316, 342, 344, 348, 356, 361, 373, + 386, 563, 647, 750, 957, 83, 384, 426, 545, 778, + 784, 792, 795, 800, 806, 813, 817, 9, 15, 22, + 39, 142, 148, 150, 170, 199, 229, 274, 288, 417, + 418, 661, 662, 814, 965, 968, 22, 83, 286, 312, + 666, 667, 668, 969, 969, 962, 966, 342, 828, 661, + 969, 354, 957, 258, 97, 173, 341, 342, 730, 306, + 969, 22, 317, 350, 354, 461, 969, 19, 155, 666, + 667, 272, 750, 969, 196, 22, 115, 830, 55, 77, + 211, 225, 301, 307, 317, 350, 354, 397, 459, 460, + 461, 22, 317, 350, 354, 461, 354, 247, 861, 955, + 969, 828, 419, 969, 151, 426, 780, 426, 951, 284, + 823, 824, 957, 818, 819, 822, 0, 429, 779, 129, + 187, 252, 366, 831, 832, 818, 820, 821, 108, 183, + 372, 430, 3, 38, 44, 67, 73, 84, 90, 149, + 151, 166, 179, 191, 192, 194, 205, 207, 227, 235, + 254, 255, 256, 300, 323, 384, 963, 969, 970, 972, + 974, 649, 969, 649, 958, 969, 275, 649, 649, 957, + 969, 96, 342, 674, 963, 967, 969, 165, 955, 241, + 8, 62, 140, 413, 414, 415, 417, 418, 419, 420, + 421, 422, 721, 918, 919, 969, 967, 957, 165, 955, + 957, 165, 861, 957, 309, 957, 649, 216, 967, 165, + 955, 197, 105, 193, 232, 280, 751, 752, 753, 955, + 961, 969, 21, 54, 67, 68, 76, 80, 97, 118, + 136, 147, 152, 173, 198, 248, 301, 305, 307, 313, + 316, 342, 344, 348, 356, 361, 386, 563, 654, 966, + 955, 352, 963, 957, 426, 649, 356, 958, 649, 165, + 957, 96, 342, 345, 347, 967, 345, 347, 62, 140, + 721, 292, 967, 455, 969, 957, 957, 309, 957, 649, + 216, 967, 313, 342, 386, 80, 173, 152, 305, 360, + 557, 22, 957, 815, 468, 966, 969, 724, 165, 963, + 957, 165, 728, 165, 958, 96, 342, 165, 963, 165, + 956, 957, 73, 62, 140, 165, 721, 48, 165, 956, + 165, 957, 165, 957, 165, 957, 309, 165, 957, 165, + 216, 956, 197, 165, 648, 649, 426, 793, 509, 784, + 380, 384, 778, 785, 786, 787, 969, 779, 968, 662, + 663, 22, 663, 968, 663, 22, 663, 968, 663, 663, + 663, 968, 965, 965, 814, 663, 275, 426, 426, 528, + 528, 528, 246, 352, 430, 528, 861, 862, 430, 746, + 966, 426, 790, 48, 957, 957, 955, 969, 38, 409, + 193, 428, 249, 249, 246, 150, 966, 352, 145, 657, + 246, 4, 6, 7, 8, 10, 30, 43, 45, 46, + 53, 54, 57, 58, 65, 67, 87, 88, 89, 90, + 91, 92, 93, 100, 101, 119, 134, 138, 139, 143, + 157, 185, 186, 188, 204, 212, 213, 226, 228, 232, + 237, 238, 240, 248, 257, 267, 281, 303, 318, 325, + 338, 350, 351, 355, 357, 358, 367, 373, 381, 399, + 400, 401, 402, 403, 404, 405, 406, 417, 418, 419, + 426, 818, 873, 876, 879, 880, 881, 883, 884, 885, + 886, 889, 890, 894, 896, 897, 916, 920, 939, 944, + 952, 953, 963, 964, 965, 966, 969, 966, 22, 474, + 954, 955, 317, 459, 103, 467, 966, 468, 966, 38, + 59, 459, 409, 326, 752, 249, 150, 352, 413, 38, + 409, 193, 753, 426, 955, 419, 424, 428, 945, 946, + 862, 149, 151, 384, 775, 776, 778, 149, 781, 103, + 894, 949, 950, 823, 430, 426, 782, 427, 427, 435, + 955, 22, 115, 829, 829, 48, 829, 141, 145, 208, + 244, 835, 837, 838, 847, 849, 850, 831, 832, 150, + 189, 861, 863, 951, 426, 624, 946, 259, 290, 319, + 428, 650, 259, 290, 319, 259, 290, 319, 392, 437, + 469, 470, 680, 18, 120, 259, 290, 319, 377, 481, + 319, 18, 120, 372, 452, 395, 165, 861, 50, 82, + 137, 168, 203, 232, 259, 290, 298, 304, 311, 319, + 328, 336, 387, 469, 471, 708, 715, 426, 697, 290, + 452, 134, 18, 24, 64, 113, 120, 123, 175, 230, + 232, 242, 250, 259, 290, 294, 319, 377, 479, 480, + 582, 4, 418, 554, 968, 649, 649, 426, 720, 428, + 170, 290, 437, 444, 259, 290, 134, 49, 95, 172, + 218, 220, 230, 258, 290, 295, 319, 330, 479, 551, + 552, 259, 290, 385, 582, 590, 134, 290, 319, 479, + 259, 290, 294, 319, 74, 112, 260, 346, 246, 18, + 24, 120, 259, 290, 319, 490, 491, 145, 290, 319, + 437, 470, 134, 290, 319, 479, 957, 206, 105, 247, + 396, 430, 751, 374, 773, 246, 963, 426, 957, 96, + 342, 963, 241, 62, 140, 721, 957, 309, 957, 197, + 649, 528, 333, 334, 495, 966, 426, 624, 625, 60, + 3, 43, 45, 46, 57, 58, 100, 101, 143, 185, + 186, 188, 226, 228, 240, 281, 320, 325, 350, 351, + 381, 870, 872, 874, 876, 878, 880, 881, 882, 884, + 885, 889, 890, 970, 972, 150, 426, 620, 957, 437, + 31, 768, 232, 437, 395, 165, 955, 437, 649, 649, + 620, 509, 437, 38, 456, 361, 589, 259, 565, 74, + 112, 260, 346, 20, 40, 184, 604, 31, 620, 145, + 437, 955, 165, 546, 955, 955, 649, 73, 686, 963, + 957, 563, 44, 94, 182, 230, 308, 134, 624, 51, + 296, 482, 134, 426, 134, 395, 134, 697, 134, 430, + 165, 648, 165, 649, 165, 649, 134, 720, 956, 134, + 134, 246, 134, 482, 134, 74, 112, 260, 346, 134, + 246, 134, 145, 165, 165, 468, 134, 430, 482, 894, + 923, 342, 427, 430, 139, 246, 358, 465, 468, 554, + 788, 784, 663, 814, 663, 814, 663, 814, 663, 814, + 663, 814, 814, 814, 663, 814, 426, 529, 530, 969, + 529, 22, 97, 118, 147, 152, 197, 198, 307, 313, + 342, 344, 361, 669, 954, 956, 668, 170, 430, 803, + 966, 870, 926, 31, 956, 146, 731, 731, 731, 206, + 969, 145, 145, 669, 956, 306, 969, 468, 246, 426, + 947, 424, 818, 927, 383, 887, 894, 943, 426, 887, + 887, 426, 145, 426, 426, 426, 875, 875, 269, 818, + 426, 426, 877, 426, 426, 426, 426, 57, 58, 887, + 894, 426, 875, 426, 426, 426, 426, 426, 393, 412, + 426, 891, 426, 891, 426, 426, 818, 426, 426, 426, + 426, 426, 426, 426, 426, 894, 894, 818, 894, 923, + 966, 58, 426, 888, 426, 966, 3, 8, 11, 28, + 31, 36, 42, 66, 166, 170, 191, 192, 207, 232, + 235, 248, 251, 323, 413, 414, 415, 417, 418, 419, + 420, 421, 422, 918, 920, 922, 256, 894, 189, 430, + 826, 426, 966, 946, 106, 167, 475, 430, 59, 103, + 468, 31, 3, 103, 211, 466, 554, 890, 966, 966, + 78, 117, 903, 86, 103, 462, 463, 465, 554, 103, + 462, 206, 955, 894, 3, 22, 26, 27, 28, 29, + 30, 31, 32, 35, 47, 53, 54, 60, 66, 68, + 76, 83, 87, 88, 89, 91, 92, 93, 103, 105, + 111, 115, 116, 122, 126, 129, 139, 141, 145, 147, + 150, 155, 158, 160, 170, 177, 187, 189, 202, 208, + 212, 213, 232, 237, 244, 246, 247, 251, 252, 265, + 273, 286, 297, 312, 318, 327, 339, 342, 349, 352, + 353, 358, 366, 367, 373, 374, 382, 388, 389, 391, + 392, 419, 960, 971, 972, 973, 974, 975, 945, 79, + 295, 652, 427, 430, 779, 427, 430, 824, 956, 31, + 782, 820, 820, 833, 834, 894, 820, 142, 229, 844, + 280, 321, 372, 22, 839, 894, 840, 842, 894, 896, + 847, 848, 838, 837, 835, 836, 145, 850, 835, 847, + 863, 955, 31, 969, 319, 419, 926, 259, 290, 319, + 352, 352, 307, 960, 428, 352, 352, 307, 352, 352, + 344, 459, 763, 145, 155, 170, 299, 681, 682, 60, + 76, 130, 147, 273, 367, 525, 526, 76, 103, 232, + 352, 76, 352, 103, 232, 307, 76, 307, 571, 21, + 54, 67, 80, 118, 147, 152, 248, 307, 313, 316, + 342, 348, 361, 386, 563, 957, 134, 290, 319, 479, + 246, 554, 311, 203, 352, 352, 237, 554, 107, 190, + 307, 317, 354, 460, 296, 319, 708, 716, 170, 180, + 253, 320, 382, 427, 698, 701, 702, 703, 705, 870, + 970, 352, 373, 955, 68, 130, 516, 525, 969, 68, + 733, 246, 305, 356, 76, 733, 25, 293, 305, 356, + 955, 175, 242, 649, 426, 352, 352, 426, 485, 344, + 392, 393, 485, 76, 430, 4, 259, 374, 374, 231, + 870, 259, 319, 721, 97, 352, 439, 470, 352, 352, + 955, 554, 48, 553, 554, 554, 95, 218, 220, 48, + 352, 437, 307, 437, 230, 552, 352, 352, 237, 966, + 582, 861, 76, 352, 733, 307, 352, 352, 485, 485, + 649, 649, 649, 649, 955, 37, 379, 37, 37, 352, + 37, 352, 307, 430, 93, 373, 600, 967, 352, 439, + 955, 352, 307, 259, 290, 280, 291, 315, 464, 751, + 961, 969, 955, 624, 870, 246, 395, 697, 554, 649, + 649, 720, 191, 246, 74, 112, 260, 346, 246, 649, + 191, 392, 500, 437, 3, 626, 627, 620, 426, 872, + 31, 30, 871, 98, 163, 219, 222, 310, 407, 426, + 892, 893, 650, 875, 649, 621, 622, 971, 20, 758, + 870, 134, 568, 957, 232, 426, 595, 438, 634, 374, + 386, 438, 967, 83, 155, 457, 508, 548, 603, 664, + 684, 754, 966, 590, 591, 957, 214, 649, 649, 649, + 649, 242, 108, 183, 359, 372, 605, 606, 127, 279, + 426, 600, 438, 550, 551, 232, 31, 242, 426, 528, + 528, 145, 687, 961, 426, 699, 31, 197, 392, 393, + 816, 308, 963, 482, 870, 958, 165, 957, 963, 482, + 956, 957, 134, 482, 134, 374, 134, 374, 721, 482, + 482, 956, 957, 649, 957, 957, 957, 649, 956, 600, + 134, 134, 482, 648, 649, 427, 430, 955, 784, 786, + 814, 814, 814, 814, 814, 814, 529, 427, 430, 427, + 153, 314, 343, 956, 648, 96, 316, 673, 674, 956, + 241, 956, 954, 954, 956, 648, 352, 392, 677, 16, + 132, 303, 321, 804, 861, 236, 805, 427, 430, 791, + 795, 800, 806, 817, 352, 667, 666, 667, 150, 156, + 678, 969, 21, 68, 97, 118, 147, 152, 198, 301, + 307, 313, 342, 344, 361, 386, 563, 658, 923, 945, + 425, 923, 927, 928, 426, 388, 940, 941, 894, 923, + 426, 965, 965, 923, 3, 98, 163, 219, 222, 310, + 407, 929, 930, 966, 965, 923, 923, 965, 965, 887, + 887, 894, 721, 894, 931, 417, 418, 895, 896, 916, + 920, 933, 427, 923, 894, 923, 934, 350, 409, 965, + 965, 894, 47, 150, 202, 353, 894, 923, 937, 923, + 224, 896, 894, 901, 902, 903, 224, 894, 903, 427, + 430, 319, 965, 965, 892, 870, 894, 971, 350, 35, + 339, 948, 649, 894, 426, 818, 938, 115, 117, 139, + 232, 237, 242, 358, 368, 894, 42, 166, 170, 207, + 323, 426, 894, 352, 894, 894, 894, 894, 894, 894, + 894, 894, 894, 894, 22, 29, 327, 917, 303, 426, + 916, 154, 211, 342, 345, 347, 370, 827, 955, 953, + 150, 853, 22, 115, 382, 419, 427, 703, 894, 924, + 925, 970, 955, 354, 426, 966, 430, 427, 425, 431, + 164, 164, 482, 955, 776, 777, 955, 949, 427, 426, + 430, 32, 111, 374, 693, 426, 841, 968, 247, 242, + 851, 851, 430, 303, 304, 843, 848, 836, 374, 801, + 103, 426, 796, 817, 969, 426, 807, 808, 809, 810, + 811, 969, 427, 427, 352, 352, 307, 967, 957, 957, + 960, 967, 957, 957, 967, 958, 957, 75, 764, 301, + 373, 666, 307, 155, 666, 426, 957, 374, 688, 195, + 195, 374, 426, 544, 165, 957, 237, 967, 957, 957, + 894, 237, 957, 957, 957, 352, 572, 963, 426, 649, + 649, 649, 96, 342, 674, 62, 140, 721, 957, 649, + 957, 649, 309, 649, 649, 197, 159, 230, 259, 290, + 378, 575, 576, 577, 861, 352, 733, 307, 237, 107, + 190, 967, 957, 246, 957, 253, 970, 427, 430, 703, + 705, 702, 705, 970, 650, 967, 956, 290, 479, 516, + 870, 969, 957, 957, 22, 373, 957, 165, 957, 165, + 969, 305, 356, 305, 356, 957, 22, 373, 957, 955, + 18, 120, 319, 583, 584, 585, 586, 971, 967, 957, + 487, 488, 971, 957, 245, 64, 245, 957, 480, 352, + 959, 969, 959, 430, 427, 430, 352, 307, 958, 967, + 3, 75, 125, 175, 264, 365, 373, 376, 440, 967, + 957, 290, 319, 479, 551, 554, 649, 957, 554, 957, + 554, 967, 957, 290, 319, 479, 957, 957, 957, 957, + 967, 957, 18, 24, 120, 259, 290, 319, 259, 290, + 319, 620, 290, 319, 290, 319, 290, 869, 969, 966, + 969, 165, 969, 967, 957, 957, 957, 18, 491, 316, + 967, 290, 319, 479, 957, 957, 352, 352, 72, 364, + 280, 191, 31, 649, 191, 191, 374, 374, 191, 237, + 655, 966, 649, 649, 649, 649, 649, 649, 191, 655, + 245, 150, 352, 494, 426, 496, 497, 413, 427, 430, + 894, 30, 871, 870, 424, 424, 352, 352, 352, 426, + 352, 965, 875, 427, 430, 413, 605, 75, 124, 200, + 201, 214, 259, 344, 346, 759, 518, 957, 150, 307, + 385, 569, 576, 577, 134, 427, 516, 596, 597, 316, + 19, 170, 301, 340, 440, 441, 145, 959, 955, 456, + 251, 509, 147, 966, 620, 620, 620, 620, 242, 246, + 251, 426, 620, 867, 868, 869, 316, 134, 133, 817, + 649, 207, 510, 512, 514, 516, 522, 525, 969, 392, + 393, 540, 392, 486, 966, 246, 427, 700, 701, 706, + 31, 197, 298, 391, 707, 708, 709, 246, 468, 162, + 162, 145, 624, 31, 134, 482, 697, 648, 649, 959, + 649, 959, 720, 246, 482, 482, 246, 482, 316, 145, + 468, 482, 894, 427, 530, 170, 170, 170, 395, 956, + 430, 554, 555, 158, 670, 671, 967, 19, 678, 132, + 321, 132, 321, 303, 372, 221, 870, 957, 150, 246, + 670, 48, 482, 963, 342, 963, 241, 197, 649, 427, + 425, 425, 430, 923, 894, 122, 941, 942, 31, 427, + 894, 427, 427, 427, 427, 150, 427, 427, 427, 427, + 427, 430, 427, 265, 932, 427, 895, 895, 11, 170, + 191, 248, 413, 414, 415, 417, 418, 419, 420, 421, + 422, 920, 895, 427, 427, 145, 150, 935, 936, 427, + 409, 427, 427, 31, 937, 923, 937, 937, 150, 427, + 427, 971, 263, 905, 31, 427, 430, 894, 971, 430, + 894, 947, 894, 969, 427, 427, 409, 895, 895, 128, + 923, 150, 115, 117, 139, 237, 242, 358, 368, 426, + 128, 339, 948, 894, 938, 894, 352, 721, 894, 426, + 818, 345, 347, 345, 347, 955, 828, 828, 828, 426, + 818, 854, 855, 856, 861, 864, 897, 963, 969, 389, + 865, 924, 924, 925, 427, 255, 909, 13, 427, 430, + 832, 752, 965, 892, 463, 894, 782, 791, 834, 248, + 918, 921, 410, 411, 694, 894, 843, 954, 805, 805, + 840, 854, 389, 866, 380, 797, 798, 969, 297, 799, + 811, 812, 430, 853, 413, 947, 967, 957, 957, 208, + 956, 956, 246, 956, 249, 246, 894, 526, 959, 426, + 426, 426, 544, 173, 529, 614, 134, 482, 352, 468, + 624, 870, 395, 649, 649, 649, 720, 74, 112, 260, + 346, 957, 558, 957, 159, 378, 352, 352, 558, 575, + 582, 290, 319, 479, 957, 957, 957, 181, 237, 650, + 701, 705, 705, 421, 352, 250, 580, 120, 294, 319, + 481, 582, 734, 134, 482, 134, 482, 957, 957, 957, + 957, 585, 586, 585, 427, 430, 587, 966, 427, 430, + 413, 428, 967, 259, 290, 319, 18, 120, 259, 290, + 319, 870, 231, 870, 967, 957, 208, 264, 237, 966, + 264, 956, 371, 352, 307, 352, 733, 307, 352, 352, + 216, 216, 216, 352, 352, 307, 352, 352, 307, 352, + 307, 352, 307, 352, 482, 870, 20, 40, 319, 734, + 134, 482, 352, 957, 352, 307, 967, 957, 655, 870, + 191, 655, 655, 959, 959, 655, 191, 191, 191, 191, + 191, 191, 655, 495, 503, 504, 971, 44, 85, 109, + 124, 128, 146, 161, 237, 245, 278, 498, 248, 417, + 418, 554, 623, 705, 921, 966, 975, 3, 627, 427, + 424, 427, 965, 425, 965, 163, 219, 893, 219, 893, + 893, 965, 222, 427, 622, 623, 246, 208, 413, 760, + 760, 760, 760, 760, 760, 760, 60, 66, 76, 103, + 105, 177, 232, 237, 273, 286, 367, 519, 520, 521, + 437, 468, 957, 468, 580, 955, 427, 430, 957, 956, + 158, 301, 956, 965, 361, 528, 292, 342, 96, 529, + 955, 606, 628, 629, 966, 427, 430, 957, 955, 957, + 392, 547, 426, 511, 955, 427, 430, 245, 485, 245, + 246, 541, 485, 31, 352, 955, 427, 430, 103, 413, + 710, 966, 468, 342, 704, 705, 392, 709, 711, 108, + 183, 312, 372, 742, 159, 817, 482, 870, 957, 482, + 482, 374, 482, 374, 482, 482, 649, 649, 957, 600, + 482, 307, 307, 307, 956, 674, 430, 967, 392, 430, + 672, 249, 132, 132, 956, 669, 482, 967, 624, 697, + 554, 649, 191, 927, 427, 349, 894, 126, 870, 427, + 894, 894, 894, 935, 870, 895, 115, 117, 232, 242, + 895, 895, 895, 895, 895, 895, 895, 895, 895, 895, + 894, 894, 936, 935, 891, 891, 870, 427, 427, 427, + 923, 427, 430, 48, 896, 427, 971, 902, 270, 337, + 904, 427, 430, 385, 898, 31, 427, 888, 966, 894, + 28, 28, 894, 427, 894, 150, 426, 926, 894, 895, + 895, 128, 128, 894, 427, 128, 894, 828, 828, 828, + 828, 955, 955, 955, 818, 855, 856, 31, 857, 969, + 430, 84, 151, 179, 194, 205, 227, 300, 858, 857, + 31, 857, 969, 426, 946, 894, 158, 845, 430, 831, + 832, 831, 427, 909, 426, 910, 969, 894, 909, 966, + 382, 925, 427, 427, 425, 427, 426, 694, 427, 247, + 86, 894, 799, 427, 430, 947, 952, 427, 430, 808, + 866, 949, 760, 153, 314, 343, 362, 683, 145, 683, + 427, 426, 532, 533, 690, 897, 969, 529, 529, 614, + 961, 427, 105, 177, 230, 232, 615, 957, 957, 31, + 957, 374, 374, 649, 649, 649, 649, 650, 967, 957, + 352, 733, 307, 352, 181, 421, 361, 957, 426, 518, + 232, 485, 96, 232, 332, 335, 485, 361, 957, 969, + 584, 488, 623, 971, 352, 352, 307, 152, 248, 335, + 632, 633, 152, 248, 640, 641, 352, 352, 307, 427, + 427, 427, 968, 966, 966, 966, 957, 957, 957, 957, + 957, 957, 957, 145, 145, 292, 145, 165, 967, 957, + 957, 967, 957, 957, 957, 957, 957, 957, 957, 66, + 483, 966, 966, 361, 969, 957, 582, 957, 957, 427, + 655, 191, 191, 655, 655, 655, 655, 655, 655, 374, + 501, 502, 427, 430, 419, 426, 465, 505, 554, 768, + 966, 768, 232, 278, 768, 768, 614, 965, 392, 393, + 425, 425, 427, 892, 955, 760, 103, 965, 966, 103, + 966, 103, 966, 103, 966, 103, 957, 103, 957, 103, + 957, 426, 649, 957, 895, 106, 167, 105, 237, 195, + 955, 711, 568, 595, 597, 580, 956, 956, 870, 486, + 955, 395, 145, 607, 427, 430, 869, 580, 242, 426, + 793, 96, 230, 513, 515, 517, 525, 969, 540, 523, + 176, 539, 514, 71, 344, 542, 817, 966, 688, 706, + 894, 894, 430, 426, 707, 620, 352, 558, 427, 482, + 959, 959, 482, 482, 316, 956, 956, 956, 554, 155, + 671, 678, 150, 191, 191, 191, 191, 237, 659, 966, + 894, 427, 427, 936, 150, 115, 117, 242, 426, 427, + 398, 900, 923, 285, 48, 390, 390, 427, 894, 230, + 894, 430, 899, 872, 892, 895, 895, 894, 926, 427, + 28, 28, 894, 894, 128, 894, 427, 955, 955, 955, + 955, 427, 969, 426, 855, 194, 254, 859, 855, 859, + 194, 858, 859, 194, 426, 969, 426, 924, 48, 160, + 846, 427, 427, 909, 911, 969, 925, 909, 966, 721, + 242, 817, 798, 413, 811, 799, 968, 352, 666, 150, + 614, 894, 427, 430, 392, 66, 691, 691, 427, 427, + 711, 106, 167, 175, 105, 376, 482, 870, 959, 959, + 957, 957, 957, 957, 361, 581, 585, 237, 237, 968, + 969, 870, 482, 482, 413, 967, 957, 957, 965, 965, + 870, 430, 965, 965, 430, 967, 957, 957, 352, 956, + 956, 649, 956, 134, 649, 870, 482, 482, 191, 655, + 655, 437, 110, 504, 465, 506, 507, 966, 966, 237, + 419, 529, 966, 966, 425, 152, 180, 152, 150, 613, + 968, 894, 232, 520, 711, 528, 374, 543, 316, 374, + 31, 426, 957, 121, 608, 388, 610, 966, 649, 510, + 547, 96, 427, 430, 392, 541, 131, 171, 426, 540, + 108, 120, 270, 957, 392, 755, 150, 426, 966, 703, + 712, 713, 970, 711, 955, 178, 559, 482, 482, 482, + 957, 249, 482, 670, 659, 659, 659, 659, 895, 150, + 426, 926, 426, 427, 430, 427, 896, 285, 427, 379, + 329, 427, 427, 427, 895, 895, 894, 857, 426, 956, + 855, 246, 374, 860, 855, 194, 855, 868, 426, 868, + 969, 427, 923, 894, 391, 906, 909, 909, 262, 912, + 427, 892, 427, 814, 951, 670, 246, 670, 427, 711, + 533, 248, 721, 649, 374, 649, 692, 692, 286, 711, + 543, 427, 352, 427, 430, 483, 623, 426, 963, 721, + 633, 426, 426, 641, 957, 392, 292, 392, 392, 145, + 483, 655, 496, 966, 427, 430, 529, 674, 31, 726, + 726, 955, 614, 427, 543, 217, 531, 173, 957, 959, + 817, 580, 303, 331, 609, 426, 133, 511, 427, 515, + 250, 542, 22, 70, 77, 104, 174, 335, 524, 524, + 954, 541, 304, 304, 52, 60, 211, 649, 689, 690, + 705, 427, 430, 865, 558, 230, 378, 560, 561, 482, + 895, 926, 427, 901, 923, 48, 230, 408, 956, 427, + 894, 426, 855, 860, 427, 868, 427, 907, 908, 969, + 48, 831, 909, 672, 683, 482, 691, 543, 426, 649, + 693, 693, 955, 543, 614, 957, 585, 374, 484, 926, + 697, 145, 636, 720, 926, 926, 648, 649, 648, 649, + 956, 482, 507, 726, 34, 169, 145, 230, 527, 151, + 261, 324, 246, 535, 536, 537, 344, 580, 140, 635, + 755, 894, 277, 540, 539, 518, 427, 542, 60, 249, + 60, 427, 430, 707, 712, 116, 378, 558, 427, 427, + 427, 285, 379, 427, 956, 427, 430, 31, 923, 279, + 304, 913, 150, 692, 389, 534, 721, 694, 694, 528, + 614, 894, 427, 252, 309, 283, 637, 636, 427, 427, + 392, 121, 175, 108, 372, 246, 537, 246, 536, 957, + 649, 31, 427, 963, 541, 540, 249, 249, 486, 690, + 711, 23, 184, 743, 427, 908, 910, 42, 86, 363, + 894, 914, 915, 914, 427, 670, 693, 426, 614, 427, + 531, 963, 48, 637, 649, 303, 51, 230, 296, 319, + 538, 538, 632, 426, 542, 541, 542, 233, 426, 738, + 740, 745, 795, 800, 806, 817, 915, 303, 144, 268, + 144, 268, 482, 694, 894, 535, 697, 649, 610, 17, + 103, 237, 4, 611, 612, 965, 966, 971, 542, 865, + 739, 740, 741, 818, 819, 28, 427, 614, 133, 427, + 430, 427, 429, 915, 277, 612, 741, 963, 426, 611, + 427 +}; + +#define yyerrok (yyerrstatus = 0) +#define yyclearin (yychar = YYEMPTY) +#define YYEMPTY (-2) +#define YYEOF 0 + +#define YYACCEPT goto yyacceptlab +#define YYABORT goto yyabortlab +#define YYERROR goto yyerrorlab + + +/* Like YYERROR except do call yyerror. This remains here temporarily + to ease the transition to the new meaning of YYERROR, for GCC. + Once GCC version 2 has supplanted version 1, this can go. */ + +#define YYFAIL goto yyerrlab + +#define YYRECOVERING() (!!yyerrstatus) + +#define YYBACKUP(Token, Value) \ +do \ + if (yychar == YYEMPTY && yylen == 1) \ + { \ + yychar = (Token); \ + yylval = (Value); \ + yytoken = YYTRANSLATE (yychar); \ + YYPOPSTACK (1); \ + goto yybackup; \ + } \ + else \ + { \ + yyerror (&yylloc, yyscanner, YY_("syntax error: cannot back up")); \ + YYERROR; \ + } \ +while (YYID (0)) + + +#define YYTERROR 1 +#define YYERRCODE 256 + + +/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N]. + If N is 0, then set CURRENT to the empty location which ends + the previous symbol: RHS[0] (always defined). */ + +#define YYRHSLOC(Rhs, K) ((Rhs)[K]) +#ifndef YYLLOC_DEFAULT +# define YYLLOC_DEFAULT(Current, Rhs, N) \ + do \ + if (YYID (N)) \ + { \ + (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \ + (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \ + (Current).last_line = YYRHSLOC (Rhs, N).last_line; \ + (Current).last_column = YYRHSLOC (Rhs, N).last_column; \ + } \ + else \ + { \ + (Current).first_line = (Current).last_line = \ + YYRHSLOC (Rhs, 0).last_line; \ + (Current).first_column = (Current).last_column = \ + YYRHSLOC (Rhs, 0).last_column; \ + } \ + while (YYID (0)) +#endif + + +/* YY_LOCATION_PRINT -- Print the location on the stream. + This macro was not mandated originally: define only if we know + we won't break user code: when these are the locations we know. */ + +#ifndef YY_LOCATION_PRINT +# if YYLTYPE_IS_TRIVIAL +# define YY_LOCATION_PRINT(File, Loc) \ + fprintf (File, "%d.%d-%d.%d", \ + (Loc).first_line, (Loc).first_column, \ + (Loc).last_line, (Loc).last_column) +# else +# define YY_LOCATION_PRINT(File, Loc) ((void) 0) +# endif +#endif + + +/* YYLEX -- calling `yylex' with the right arguments. */ + +#ifdef YYLEX_PARAM +# define YYLEX yylex (&yylval, &yylloc, YYLEX_PARAM) +#else +# define YYLEX yylex (&yylval, &yylloc, yyscanner) +#endif + +/* Enable debugging if requested. */ +#if YYDEBUG + +# ifndef YYFPRINTF +# include /* INFRINGES ON USER NAME SPACE */ +# define YYFPRINTF fprintf +# endif + +# define YYDPRINTF(Args) \ +do { \ + if (yydebug) \ + YYFPRINTF Args; \ +} while (YYID (0)) + +# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \ +do { \ + if (yydebug) \ + { \ + YYFPRINTF (stderr, "%s ", Title); \ + yy_symbol_print (stderr, \ + Type, Value, Location, yyscanner); \ + YYFPRINTF (stderr, "\n"); \ + } \ +} while (YYID (0)) + + +/*--------------------------------. +| Print this symbol on YYOUTPUT. | +`--------------------------------*/ + +/*ARGSUSED*/ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp, core_yyscan_t yyscanner) +#else +static void +yy_symbol_value_print (yyoutput, yytype, yyvaluep, yylocationp, yyscanner) + FILE *yyoutput; + int yytype; + YYSTYPE const * const yyvaluep; + YYLTYPE const * const yylocationp; + core_yyscan_t yyscanner; +#endif +{ + if (!yyvaluep) + return; + YYUSE (yylocationp); + YYUSE (yyscanner); +# ifdef YYPRINT + if (yytype < YYNTOKENS) + YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep); +# else + YYUSE (yyoutput); +# endif + switch (yytype) + { + default: + break; + } +} + + +/*--------------------------------. +| Print this symbol on YYOUTPUT. | +`--------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp, core_yyscan_t yyscanner) +#else +static void +yy_symbol_print (yyoutput, yytype, yyvaluep, yylocationp, yyscanner) + FILE *yyoutput; + int yytype; + YYSTYPE const * const yyvaluep; + YYLTYPE const * const yylocationp; + core_yyscan_t yyscanner; +#endif +{ + if (yytype < YYNTOKENS) + YYFPRINTF (yyoutput, "token %s (", yytname[yytype]); + else + YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]); + + YY_LOCATION_PRINT (yyoutput, *yylocationp); + YYFPRINTF (yyoutput, ": "); + yy_symbol_value_print (yyoutput, yytype, yyvaluep, yylocationp, yyscanner); + YYFPRINTF (yyoutput, ")"); +} + +/*------------------------------------------------------------------. +| yy_stack_print -- Print the state stack from its BOTTOM up to its | +| TOP (included). | +`------------------------------------------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop) +#else +static void +yy_stack_print (yybottom, yytop) + yytype_int16 *yybottom; + yytype_int16 *yytop; +#endif +{ + YYFPRINTF (stderr, "Stack now"); + for (; yybottom <= yytop; yybottom++) + { + int yybot = *yybottom; + YYFPRINTF (stderr, " %d", yybot); + } + YYFPRINTF (stderr, "\n"); +} + +# define YY_STACK_PRINT(Bottom, Top) \ +do { \ + if (yydebug) \ + yy_stack_print ((Bottom), (Top)); \ +} while (YYID (0)) + + +/*------------------------------------------------. +| Report that the YYRULE is going to be reduced. | +`------------------------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_reduce_print (YYSTYPE *yyvsp, YYLTYPE *yylsp, int yyrule, core_yyscan_t yyscanner) +#else +static void +yy_reduce_print (yyvsp, yylsp, yyrule, yyscanner) + YYSTYPE *yyvsp; + YYLTYPE *yylsp; + int yyrule; + core_yyscan_t yyscanner; +#endif +{ + int yynrhs = yyr2[yyrule]; + int yyi; + unsigned long int yylno = yyrline[yyrule]; + YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n", + yyrule - 1, yylno); + /* The symbols being reduced. */ + for (yyi = 0; yyi < yynrhs; yyi++) + { + YYFPRINTF (stderr, " $%d = ", yyi + 1); + yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi], + &(yyvsp[(yyi + 1) - (yynrhs)]) + , &(yylsp[(yyi + 1) - (yynrhs)]) , yyscanner); + YYFPRINTF (stderr, "\n"); + } +} + +# define YY_REDUCE_PRINT(Rule) \ +do { \ + if (yydebug) \ + yy_reduce_print (yyvsp, yylsp, Rule, yyscanner); \ +} while (YYID (0)) + +/* Nonzero means print parse trace. It is left uninitialized so that + multiple parsers can coexist. */ +int yydebug; +#else /* !YYDEBUG */ +# define YYDPRINTF(Args) +# define YY_SYMBOL_PRINT(Title, Type, Value, Location) +# define YY_STACK_PRINT(Bottom, Top) +# define YY_REDUCE_PRINT(Rule) +#endif /* !YYDEBUG */ + + +/* YYINITDEPTH -- initial size of the parser's stacks. */ +#ifndef YYINITDEPTH +# define YYINITDEPTH 200 +#endif + +/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only + if the built-in stack extension method is used). + + Do not make this value too large; the results are undefined if + YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH) + evaluated with infinite-precision integer arithmetic. */ + +#ifndef YYMAXDEPTH +# define YYMAXDEPTH 10000 +#endif + + + +#if YYERROR_VERBOSE + +# ifndef yystrlen +# if defined __GLIBC__ && defined _STRING_H +# define yystrlen strlen +# else +/* Return the length of YYSTR. */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static YYSIZE_T +yystrlen (const char *yystr) +#else +static YYSIZE_T +yystrlen (yystr) + const char *yystr; +#endif +{ + YYSIZE_T yylen; + for (yylen = 0; yystr[yylen]; yylen++) + continue; + return yylen; +} +# endif +# endif + +# ifndef yystpcpy +# if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE +# define yystpcpy stpcpy +# else +/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in + YYDEST. */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static char * +yystpcpy (char *yydest, const char *yysrc) +#else +static char * +yystpcpy (yydest, yysrc) + char *yydest; + const char *yysrc; +#endif +{ + char *yyd = yydest; + const char *yys = yysrc; + + while ((*yyd++ = *yys++) != '\0') + continue; + + return yyd - 1; +} +# endif +# endif + +# ifndef yytnamerr +/* Copy to YYRES the contents of YYSTR after stripping away unnecessary + quotes and backslashes, so that it's suitable for yyerror. The + heuristic is that double-quoting is unnecessary unless the string + contains an apostrophe, a comma, or backslash (other than + backslash-backslash). YYSTR is taken from yytname. If YYRES is + null, do not copy; instead, return the length of what the result + would have been. */ +static YYSIZE_T +yytnamerr (char *yyres, const char *yystr) +{ + if (*yystr == '"') + { + YYSIZE_T yyn = 0; + char const *yyp = yystr; + + for (;;) + switch (*++yyp) + { + case '\'': + case ',': + goto do_not_strip_quotes; + + case '\\': + if (*++yyp != '\\') + goto do_not_strip_quotes; + /* Fall through. */ + default: + if (yyres) + yyres[yyn] = *yyp; + yyn++; + break; + + case '"': + if (yyres) + yyres[yyn] = '\0'; + return yyn; + } + do_not_strip_quotes: ; + } + + if (! yyres) + return yystrlen (yystr); + + return yystpcpy (yyres, yystr) - yyres; +} +# endif + +/* Copy into YYRESULT an error message about the unexpected token + YYCHAR while in state YYSTATE. Return the number of bytes copied, + including the terminating null byte. If YYRESULT is null, do not + copy anything; just return the number of bytes that would be + copied. As a special case, return 0 if an ordinary "syntax error" + message will do. Return YYSIZE_MAXIMUM if overflow occurs during + size calculation. */ +static YYSIZE_T +yysyntax_error (char *yyresult, int yystate, int yychar) +{ + int yyn = yypact[yystate]; + + if (! (YYPACT_NINF < yyn && yyn <= YYLAST)) + return 0; + else + { + int yytype = YYTRANSLATE (yychar); + YYSIZE_T yysize0 = yytnamerr (0, yytname[yytype]); + YYSIZE_T yysize = yysize0; + YYSIZE_T yysize1; + int yysize_overflow = 0; + enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; + char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; + int yyx; + +# if 0 + /* This is so xgettext sees the translatable formats that are + constructed on the fly. */ + YY_("syntax error, unexpected %s"); + YY_("syntax error, unexpected %s, expecting %s"); + YY_("syntax error, unexpected %s, expecting %s or %s"); + YY_("syntax error, unexpected %s, expecting %s or %s or %s"); + YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"); +# endif + char *yyfmt; + char const *yyf; + static char const yyunexpected[] = "syntax error, unexpected %s"; + static char const yyexpecting[] = ", expecting %s"; + static char const yyor[] = " or %s"; + char yyformat[sizeof yyunexpected + + sizeof yyexpecting - 1 + + ((YYERROR_VERBOSE_ARGS_MAXIMUM - 2) + * (sizeof yyor - 1))]; + char const *yyprefix = yyexpecting; + + /* Start YYX at -YYN if negative to avoid negative indexes in + YYCHECK. */ + int yyxbegin = yyn < 0 ? -yyn : 0; + + /* Stay within bounds of both yycheck and yytname. */ + int yychecklim = YYLAST - yyn + 1; + int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; + int yycount = 1; + + yyarg[0] = yytname[yytype]; + yyfmt = yystpcpy (yyformat, yyunexpected); + + for (yyx = yyxbegin; yyx < yyxend; ++yyx) + if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR) + { + if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) + { + yycount = 1; + yysize = yysize0; + yyformat[sizeof yyunexpected - 1] = '\0'; + break; + } + yyarg[yycount++] = yytname[yyx]; + yysize1 = yysize + yytnamerr (0, yytname[yyx]); + yysize_overflow |= (yysize1 < yysize); + yysize = yysize1; + yyfmt = yystpcpy (yyfmt, yyprefix); + yyprefix = yyor; + } + + yyf = YY_(yyformat); + yysize1 = yysize + yystrlen (yyf); + yysize_overflow |= (yysize1 < yysize); + yysize = yysize1; + + if (yysize_overflow) + return YYSIZE_MAXIMUM; + + if (yyresult) + { + /* Avoid sprintf, as that infringes on the user's name space. + Don't have undefined behavior even if the translation + produced a string with the wrong number of "%s"s. */ + char *yyp = yyresult; + int yyi = 0; + while ((*yyp = *yyf) != '\0') + { + if (*yyp == '%' && yyf[1] == 's' && yyi < yycount) + { + yyp += yytnamerr (yyp, yyarg[yyi++]); + yyf += 2; + } + else + { + yyp++; + yyf++; + } + } + } + return yysize; + } +} +#endif /* YYERROR_VERBOSE */ + + +/*-----------------------------------------------. +| Release the memory associated to this symbol. | +`-----------------------------------------------*/ + +/*ARGSUSED*/ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep, YYLTYPE *yylocationp, core_yyscan_t yyscanner) +#else +static void +yydestruct (yymsg, yytype, yyvaluep, yylocationp, yyscanner) + const char *yymsg; + int yytype; + YYSTYPE *yyvaluep; + YYLTYPE *yylocationp; + core_yyscan_t yyscanner; +#endif +{ + YYUSE (yyvaluep); + YYUSE (yylocationp); + YYUSE (yyscanner); + + if (!yymsg) + yymsg = "Deleting"; + YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp); + + switch (yytype) + { + + default: + break; + } +} + +/* Prevent warnings from -Wmissing-prototypes. */ +#ifdef YYPARSE_PARAM +#if defined __STDC__ || defined __cplusplus +int yyparse (void *YYPARSE_PARAM); +#else +int yyparse (); +#endif +#else /* ! YYPARSE_PARAM */ +#if defined __STDC__ || defined __cplusplus +int yyparse (core_yyscan_t yyscanner); +#else +int yyparse (); +#endif +#endif /* ! YYPARSE_PARAM */ + + + + + +/*-------------------------. +| yyparse or yypush_parse. | +`-------------------------*/ + +#ifdef YYPARSE_PARAM +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +int +yyparse (void *YYPARSE_PARAM) +#else +int +yyparse (YYPARSE_PARAM) + void *YYPARSE_PARAM; +#endif +#else /* ! YYPARSE_PARAM */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +int +yyparse (core_yyscan_t yyscanner) +#else +int +yyparse (yyscanner) + core_yyscan_t yyscanner; +#endif +#endif +{ +/* The lookahead symbol. */ +int yychar; + +/* The semantic value of the lookahead symbol. */ +YYSTYPE yylval; + +/* Location data for the lookahead symbol. */ +YYLTYPE yylloc; + + /* Number of syntax errors so far. */ + int yynerrs; + + int yystate; + /* Number of tokens to shift before error messages enabled. */ + int yyerrstatus; + + /* The stacks and their tools: + `yyss': related to states. + `yyvs': related to semantic values. + `yyls': related to locations. + + Refer to the stacks thru separate pointers, to allow yyoverflow + to reallocate them elsewhere. */ + + /* The state stack. */ + yytype_int16 yyssa[YYINITDEPTH]; + yytype_int16 *yyss; + yytype_int16 *yyssp; + + /* The semantic value stack. */ + YYSTYPE yyvsa[YYINITDEPTH]; + YYSTYPE *yyvs; + YYSTYPE *yyvsp; + + /* The location stack. */ + YYLTYPE yylsa[YYINITDEPTH]; + YYLTYPE *yyls; + YYLTYPE *yylsp; + + /* The locations where the error started and ended. */ + YYLTYPE yyerror_range[2]; + + YYSIZE_T yystacksize; + + int yyn; + int yyresult; + /* Lookahead token as an internal (translated) token number. */ + int yytoken; + /* The variables used to return semantic value and location from the + action routines. */ + YYSTYPE yyval; + YYLTYPE yyloc; + +#if YYERROR_VERBOSE + /* Buffer for error messages, and its allocated size. */ + char yymsgbuf[128]; + char *yymsg = yymsgbuf; + YYSIZE_T yymsg_alloc = sizeof yymsgbuf; +#endif + +#define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N), yylsp -= (N)) + + /* The number of symbols on the RHS of the reduced rule. + Keep to zero when no symbol should be popped. */ + int yylen = 0; + + yytoken = 0; + yyss = yyssa; + yyvs = yyvsa; + yyls = yylsa; + yystacksize = YYINITDEPTH; + + YYDPRINTF ((stderr, "Starting parse\n")); + + yystate = 0; + yyerrstatus = 0; + yynerrs = 0; + yychar = YYEMPTY; /* Cause a token to be read. */ + + /* Initialize stack pointers. + Waste one element of value and location stack + so that they stay on the same level as the state stack. + The wasted elements are never initialized. */ + yyssp = yyss; + yyvsp = yyvs; + yylsp = yyls; + +#if YYLTYPE_IS_TRIVIAL + /* Initialize the default location before parsing starts. */ + yylloc.first_line = yylloc.last_line = 1; + yylloc.first_column = yylloc.last_column = 1; +#endif + + goto yysetstate; + +/*------------------------------------------------------------. +| yynewstate -- Push a new state, which is found in yystate. | +`------------------------------------------------------------*/ + yynewstate: + /* In all cases, when you get here, the value and location stacks + have just been pushed. So pushing a state here evens the stacks. */ + yyssp++; + + yysetstate: + *yyssp = yystate; + + if (yyss + yystacksize - 1 <= yyssp) + { + /* Get the current used size of the three stacks, in elements. */ + YYSIZE_T yysize = yyssp - yyss + 1; + +#ifdef yyoverflow + { + /* Give user a chance to reallocate the stack. Use copies of + these so that the &'s don't force the real ones into + memory. */ + YYSTYPE *yyvs1 = yyvs; + yytype_int16 *yyss1 = yyss; + YYLTYPE *yyls1 = yyls; + + /* Each stack pointer address is followed by the size of the + data in use in that stack, in bytes. This used to be a + conditional around just the two extra args, but that might + be undefined if yyoverflow is a macro. */ + yyoverflow (YY_("memory exhausted"), + &yyss1, yysize * sizeof (*yyssp), + &yyvs1, yysize * sizeof (*yyvsp), + &yyls1, yysize * sizeof (*yylsp), + &yystacksize); + + yyls = yyls1; + yyss = yyss1; + yyvs = yyvs1; + } +#else /* no yyoverflow */ +# ifndef YYSTACK_RELOCATE + goto yyexhaustedlab; +# else + /* Extend the stack our own way. */ + if (YYMAXDEPTH <= yystacksize) + goto yyexhaustedlab; + yystacksize *= 2; + if (YYMAXDEPTH < yystacksize) + yystacksize = YYMAXDEPTH; + + { + yytype_int16 *yyss1 = yyss; + union yyalloc *yyptr = + (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize)); + if (! yyptr) + goto yyexhaustedlab; + YYSTACK_RELOCATE (yyss_alloc, yyss); + YYSTACK_RELOCATE (yyvs_alloc, yyvs); + YYSTACK_RELOCATE (yyls_alloc, yyls); +# undef YYSTACK_RELOCATE + if (yyss1 != yyssa) + YYSTACK_FREE (yyss1); + } +# endif +#endif /* no yyoverflow */ + + yyssp = yyss + yysize - 1; + yyvsp = yyvs + yysize - 1; + yylsp = yyls + yysize - 1; + + YYDPRINTF ((stderr, "Stack size increased to %lu\n", + (unsigned long int) yystacksize)); + + if (yyss + yystacksize - 1 <= yyssp) + YYABORT; + } + + YYDPRINTF ((stderr, "Entering state %d\n", yystate)); + + if (yystate == YYFINAL) + YYACCEPT; + + goto yybackup; + +/*-----------. +| yybackup. | +`-----------*/ +yybackup: + + /* Do appropriate processing given the current state. Read a + lookahead token if we need one and don't already have one. */ + + /* First try to decide what to do without reference to lookahead token. */ + yyn = yypact[yystate]; + if (yyn == YYPACT_NINF) + goto yydefault; + + /* Not known => get a lookahead token if don't already have one. */ + + /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */ + if (yychar == YYEMPTY) + { + YYDPRINTF ((stderr, "Reading a token: ")); + yychar = YYLEX; + } + + if (yychar <= YYEOF) + { + yychar = yytoken = YYEOF; + YYDPRINTF ((stderr, "Now at end of input.\n")); + } + else + { + yytoken = YYTRANSLATE (yychar); + YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc); + } + + /* If the proper action on seeing token YYTOKEN is to reduce or to + detect an error, take that action. */ + yyn += yytoken; + if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken) + goto yydefault; + yyn = yytable[yyn]; + if (yyn <= 0) + { + if (yyn == 0 || yyn == YYTABLE_NINF) + goto yyerrlab; + yyn = -yyn; + goto yyreduce; + } + + /* Count tokens shifted since error; after three, turn off error + status. */ + if (yyerrstatus) + yyerrstatus--; + + /* Shift the lookahead token. */ + YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc); + + /* Discard the shifted token. */ + yychar = YYEMPTY; + + yystate = yyn; + *++yyvsp = yylval; + *++yylsp = yylloc; + goto yynewstate; + + +/*-----------------------------------------------------------. +| yydefault -- do the default action for the current state. | +`-----------------------------------------------------------*/ +yydefault: + yyn = yydefact[yystate]; + if (yyn == 0) + goto yyerrlab; + goto yyreduce; + + +/*-----------------------------. +| yyreduce -- Do a reduction. | +`-----------------------------*/ +yyreduce: + /* yyn is the number of a rule to reduce with. */ + yylen = yyr2[yyn]; + + /* If YYLEN is nonzero, implement the default value of the action: + `$$ = $1'. + + Otherwise, the following line sets YYVAL to garbage. + This behavior is undocumented and Bison + users should not rely upon it. Assigning to YYVAL + unconditionally makes the parser a bit smaller, and it avoids a + GCC warning that YYVAL may be used uninitialized. */ + yyval = yyvsp[1-yylen]; + + /* Default location. */ + YYLLOC_DEFAULT (yyloc, (yylsp - yylen), yylen); + YY_REDUCE_PRINT (yyn); + switch (yyn) + { + case 2: + +/* Line 1455 of yacc.c */ +#line 655 "gram.y" + { + pg_yyget_extra(yyscanner)->parsetree = (yyvsp[(1) - (1)].list); + ;} + break; + + case 3: + +/* Line 1455 of yacc.c */ +#line 662 "gram.y" + { + if ((yyvsp[(3) - (3)].node) != NULL) + (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].node)); + else + (yyval.list) = (yyvsp[(1) - (3)].list); + ;} + break; + + case 4: + +/* Line 1455 of yacc.c */ +#line 669 "gram.y" + { + if ((yyvsp[(1) - (1)].node) != NULL) + (yyval.list) = list_make1((yyvsp[(1) - (1)].node)); + else + (yyval.list) = NIL; + ;} + break; + + case 115: + +/* Line 1455 of yacc.c */ +#line 789 "gram.y" + { (yyval.node) = NULL; ;} + break; + + case 116: + +/* Line 1455 of yacc.c */ +#line 800 "gram.y" + { + CreateRoleStmt *n = makeNode(CreateRoleStmt); + n->stmt_type = ROLESTMT_ROLE; + n->role = (yyvsp[(3) - (5)].str); + n->options = (yyvsp[(5) - (5)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 117: + +/* Line 1455 of yacc.c */ +#line 810 "gram.y" + {;} + break; + + case 118: + +/* Line 1455 of yacc.c */ +#line 811 "gram.y" + {;} + break; + + case 119: + +/* Line 1455 of yacc.c */ +#line 820 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (2)].list), (yyvsp[(2) - (2)].defelt)); ;} + break; + + case 120: + +/* Line 1455 of yacc.c */ +#line 821 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 121: + +/* Line 1455 of yacc.c */ +#line 825 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (2)].list), (yyvsp[(2) - (2)].defelt)); ;} + break; + + case 122: + +/* Line 1455 of yacc.c */ +#line 826 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 123: + +/* Line 1455 of yacc.c */ +#line 831 "gram.y" + { + (yyval.defelt) = makeDefElem("password", + (Node *)makeString((yyvsp[(2) - (2)].str))); + ;} + break; + + case 124: + +/* Line 1455 of yacc.c */ +#line 836 "gram.y" + { + (yyval.defelt) = makeDefElem("password", NULL); + ;} + break; + + case 125: + +/* Line 1455 of yacc.c */ +#line 840 "gram.y" + { + (yyval.defelt) = makeDefElem("encryptedPassword", + (Node *)makeString((yyvsp[(3) - (3)].str))); + ;} + break; + + case 126: + +/* Line 1455 of yacc.c */ +#line 845 "gram.y" + { + (yyval.defelt) = makeDefElem("unencryptedPassword", + (Node *)makeString((yyvsp[(3) - (3)].str))); + ;} + break; + + case 127: + +/* Line 1455 of yacc.c */ +#line 850 "gram.y" + { + (yyval.defelt) = makeDefElem("inherit", (Node *)makeInteger(TRUE)); + ;} + break; + + case 128: + +/* Line 1455 of yacc.c */ +#line 854 "gram.y" + { + (yyval.defelt) = makeDefElem("connectionlimit", (Node *)makeInteger((yyvsp[(3) - (3)].ival))); + ;} + break; + + case 129: + +/* Line 1455 of yacc.c */ +#line 858 "gram.y" + { + (yyval.defelt) = makeDefElem("validUntil", (Node *)makeString((yyvsp[(3) - (3)].str))); + ;} + break; + + case 130: + +/* Line 1455 of yacc.c */ +#line 863 "gram.y" + { + (yyval.defelt) = makeDefElem("rolemembers", (Node *)(yyvsp[(2) - (2)].list)); + ;} + break; + + case 131: + +/* Line 1455 of yacc.c */ +#line 867 "gram.y" + { + /* + * We handle identifiers that aren't parser keywords with + * the following special-case codes, to avoid bloating the + * size of the main parser. + */ + if (strcmp((yyvsp[(1) - (1)].str), "superuser") == 0) + (yyval.defelt) = makeDefElem("superuser", (Node *)makeInteger(TRUE)); + else if (strcmp((yyvsp[(1) - (1)].str), "nosuperuser") == 0) + (yyval.defelt) = makeDefElem("superuser", (Node *)makeInteger(FALSE)); + else if (strcmp((yyvsp[(1) - (1)].str), "createuser") == 0) + { + /* For backwards compatibility, synonym for SUPERUSER */ + (yyval.defelt) = makeDefElem("superuser", (Node *)makeInteger(TRUE)); + } + else if (strcmp((yyvsp[(1) - (1)].str), "nocreateuser") == 0) + { + /* For backwards compatibility, synonym for SUPERUSER */ + (yyval.defelt) = makeDefElem("superuser", (Node *)makeInteger(FALSE)); + } + else if (strcmp((yyvsp[(1) - (1)].str), "createrole") == 0) + (yyval.defelt) = makeDefElem("createrole", (Node *)makeInteger(TRUE)); + else if (strcmp((yyvsp[(1) - (1)].str), "nocreaterole") == 0) + (yyval.defelt) = makeDefElem("createrole", (Node *)makeInteger(FALSE)); + else if (strcmp((yyvsp[(1) - (1)].str), "replication") == 0) + (yyval.defelt) = makeDefElem("isreplication", (Node *)makeInteger(TRUE)); + else if (strcmp((yyvsp[(1) - (1)].str), "noreplication") == 0) + (yyval.defelt) = makeDefElem("isreplication", (Node *)makeInteger(FALSE)); + else if (strcmp((yyvsp[(1) - (1)].str), "createdb") == 0) + (yyval.defelt) = makeDefElem("createdb", (Node *)makeInteger(TRUE)); + else if (strcmp((yyvsp[(1) - (1)].str), "nocreatedb") == 0) + (yyval.defelt) = makeDefElem("createdb", (Node *)makeInteger(FALSE)); + else if (strcmp((yyvsp[(1) - (1)].str), "login") == 0) + (yyval.defelt) = makeDefElem("canlogin", (Node *)makeInteger(TRUE)); + else if (strcmp((yyvsp[(1) - (1)].str), "nologin") == 0) + (yyval.defelt) = makeDefElem("canlogin", (Node *)makeInteger(FALSE)); + else if (strcmp((yyvsp[(1) - (1)].str), "noinherit") == 0) + { + /* + * Note that INHERIT is a keyword, so it's handled by main parser, but + * NOINHERIT is handled here. + */ + (yyval.defelt) = makeDefElem("inherit", (Node *)makeInteger(FALSE)); + } + else + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("unrecognized role option \"%s\"", (yyvsp[(1) - (1)].str)), + parser_errposition((yylsp[(1) - (1)])))); + ;} + break; + + case 132: + +/* Line 1455 of yacc.c */ +#line 920 "gram.y" + { (yyval.defelt) = (yyvsp[(1) - (1)].defelt); ;} + break; + + case 133: + +/* Line 1455 of yacc.c */ +#line 923 "gram.y" + { + (yyval.defelt) = makeDefElem("sysid", (Node *)makeInteger((yyvsp[(2) - (2)].ival))); + ;} + break; + + case 134: + +/* Line 1455 of yacc.c */ +#line 927 "gram.y" + { + (yyval.defelt) = makeDefElem("adminmembers", (Node *)(yyvsp[(2) - (2)].list)); + ;} + break; + + case 135: + +/* Line 1455 of yacc.c */ +#line 931 "gram.y" + { + (yyval.defelt) = makeDefElem("rolemembers", (Node *)(yyvsp[(2) - (2)].list)); + ;} + break; + + case 136: + +/* Line 1455 of yacc.c */ +#line 935 "gram.y" + { + (yyval.defelt) = makeDefElem("addroleto", (Node *)(yyvsp[(3) - (3)].list)); + ;} + break; + + case 137: + +/* Line 1455 of yacc.c */ +#line 939 "gram.y" + { + (yyval.defelt) = makeDefElem("addroleto", (Node *)(yyvsp[(3) - (3)].list)); + ;} + break; + + case 138: + +/* Line 1455 of yacc.c */ +#line 953 "gram.y" + { + CreateRoleStmt *n = makeNode(CreateRoleStmt); + n->stmt_type = ROLESTMT_USER; + n->role = (yyvsp[(3) - (5)].str); + n->options = (yyvsp[(5) - (5)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 139: + +/* Line 1455 of yacc.c */ +#line 971 "gram.y" + { + AlterRoleStmt *n = makeNode(AlterRoleStmt); + n->role = (yyvsp[(3) - (5)].str); + n->action = +1; /* add, if there are members */ + n->options = (yyvsp[(5) - (5)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 140: + +/* Line 1455 of yacc.c */ +#line 981 "gram.y" + { (yyval.str) = NULL; ;} + break; + + case 141: + +/* Line 1455 of yacc.c */ +#line 982 "gram.y" + { (yyval.str) = (yyvsp[(3) - (3)].str); ;} + break; + + case 142: + +/* Line 1455 of yacc.c */ +#line 987 "gram.y" + { + AlterRoleSetStmt *n = makeNode(AlterRoleSetStmt); + n->role = (yyvsp[(3) - (5)].str); + n->database = (yyvsp[(4) - (5)].str); + n->setstmt = (yyvsp[(5) - (5)].vsetstmt); + (yyval.node) = (Node *)n; + ;} + break; + + case 143: + +/* Line 1455 of yacc.c */ +#line 1005 "gram.y" + { + AlterRoleStmt *n = makeNode(AlterRoleStmt); + n->role = (yyvsp[(3) - (5)].str); + n->action = +1; /* add, if there are members */ + n->options = (yyvsp[(5) - (5)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 144: + +/* Line 1455 of yacc.c */ +#line 1017 "gram.y" + { + AlterRoleSetStmt *n = makeNode(AlterRoleSetStmt); + n->role = (yyvsp[(3) - (4)].str); + n->database = NULL; + n->setstmt = (yyvsp[(4) - (4)].vsetstmt); + (yyval.node) = (Node *)n; + ;} + break; + + case 145: + +/* Line 1455 of yacc.c */ +#line 1038 "gram.y" + { + DropRoleStmt *n = makeNode(DropRoleStmt); + n->missing_ok = FALSE; + n->roles = (yyvsp[(3) - (3)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 146: + +/* Line 1455 of yacc.c */ +#line 1045 "gram.y" + { + DropRoleStmt *n = makeNode(DropRoleStmt); + n->missing_ok = TRUE; + n->roles = (yyvsp[(5) - (5)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 147: + +/* Line 1455 of yacc.c */ +#line 1064 "gram.y" + { + DropRoleStmt *n = makeNode(DropRoleStmt); + n->missing_ok = FALSE; + n->roles = (yyvsp[(3) - (3)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 148: + +/* Line 1455 of yacc.c */ +#line 1071 "gram.y" + { + DropRoleStmt *n = makeNode(DropRoleStmt); + n->roles = (yyvsp[(5) - (5)].list); + n->missing_ok = TRUE; + (yyval.node) = (Node *)n; + ;} + break; + + case 149: + +/* Line 1455 of yacc.c */ +#line 1088 "gram.y" + { + CreateRoleStmt *n = makeNode(CreateRoleStmt); + n->stmt_type = ROLESTMT_GROUP; + n->role = (yyvsp[(3) - (5)].str); + n->options = (yyvsp[(5) - (5)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 150: + +/* Line 1455 of yacc.c */ +#line 1106 "gram.y" + { + AlterRoleStmt *n = makeNode(AlterRoleStmt); + n->role = (yyvsp[(3) - (6)].str); + n->action = (yyvsp[(4) - (6)].ival); + n->options = list_make1(makeDefElem("rolemembers", + (Node *)(yyvsp[(6) - (6)].list))); + (yyval.node) = (Node *)n; + ;} + break; + + case 151: + +/* Line 1455 of yacc.c */ +#line 1116 "gram.y" + { (yyval.ival) = +1; ;} + break; + + case 152: + +/* Line 1455 of yacc.c */ +#line 1117 "gram.y" + { (yyval.ival) = -1; ;} + break; + + case 153: + +/* Line 1455 of yacc.c */ +#line 1130 "gram.y" + { + DropRoleStmt *n = makeNode(DropRoleStmt); + n->missing_ok = FALSE; + n->roles = (yyvsp[(3) - (3)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 154: + +/* Line 1455 of yacc.c */ +#line 1137 "gram.y" + { + DropRoleStmt *n = makeNode(DropRoleStmt); + n->missing_ok = TRUE; + n->roles = (yyvsp[(5) - (5)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 155: + +/* Line 1455 of yacc.c */ +#line 1154 "gram.y" + { + CreateSchemaStmt *n = makeNode(CreateSchemaStmt); + /* One can omit the schema name or the authorization id. */ + if ((yyvsp[(3) - (6)].str) != NULL) + n->schemaname = (yyvsp[(3) - (6)].str); + else + n->schemaname = (yyvsp[(5) - (6)].str); + n->authid = (yyvsp[(5) - (6)].str); + n->schemaElts = (yyvsp[(6) - (6)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 156: + +/* Line 1455 of yacc.c */ +#line 1166 "gram.y" + { + CreateSchemaStmt *n = makeNode(CreateSchemaStmt); + /* ...but not both */ + n->schemaname = (yyvsp[(3) - (4)].str); + n->authid = NULL; + n->schemaElts = (yyvsp[(4) - (4)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 157: + +/* Line 1455 of yacc.c */ +#line 1177 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 158: + +/* Line 1455 of yacc.c */ +#line 1178 "gram.y" + { (yyval.str) = NULL; ;} + break; + + case 159: + +/* Line 1455 of yacc.c */ +#line 1182 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (2)].list), (yyvsp[(2) - (2)].node)); ;} + break; + + case 160: + +/* Line 1455 of yacc.c */ +#line 1183 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 167: + +/* Line 1455 of yacc.c */ +#line 1211 "gram.y" + { + VariableSetStmt *n = (yyvsp[(2) - (2)].vsetstmt); + n->is_local = false; + (yyval.node) = (Node *) n; + ;} + break; + + case 168: + +/* Line 1455 of yacc.c */ +#line 1217 "gram.y" + { + VariableSetStmt *n = (yyvsp[(3) - (3)].vsetstmt); + n->is_local = true; + (yyval.node) = (Node *) n; + ;} + break; + + case 169: + +/* Line 1455 of yacc.c */ +#line 1223 "gram.y" + { + VariableSetStmt *n = (yyvsp[(3) - (3)].vsetstmt); + n->is_local = false; + (yyval.node) = (Node *) n; + ;} + break; + + case 170: + +/* Line 1455 of yacc.c */ +#line 1232 "gram.y" + { + VariableSetStmt *n = makeNode(VariableSetStmt); + n->kind = VAR_SET_MULTI; + n->name = "TRANSACTION"; + n->args = (yyvsp[(2) - (2)].list); + (yyval.vsetstmt) = n; + ;} + break; + + case 171: + +/* Line 1455 of yacc.c */ +#line 1240 "gram.y" + { + VariableSetStmt *n = makeNode(VariableSetStmt); + n->kind = VAR_SET_MULTI; + n->name = "SESSION CHARACTERISTICS"; + n->args = (yyvsp[(5) - (5)].list); + (yyval.vsetstmt) = n; + ;} + break; + + case 173: + +/* Line 1455 of yacc.c */ +#line 1252 "gram.y" + { + VariableSetStmt *n = makeNode(VariableSetStmt); + n->kind = VAR_SET_VALUE; + n->name = (yyvsp[(1) - (3)].str); + n->args = (yyvsp[(3) - (3)].list); + (yyval.vsetstmt) = n; + ;} + break; + + case 174: + +/* Line 1455 of yacc.c */ +#line 1260 "gram.y" + { + VariableSetStmt *n = makeNode(VariableSetStmt); + n->kind = VAR_SET_VALUE; + n->name = (yyvsp[(1) - (3)].str); + n->args = (yyvsp[(3) - (3)].list); + (yyval.vsetstmt) = n; + ;} + break; + + case 175: + +/* Line 1455 of yacc.c */ +#line 1268 "gram.y" + { + VariableSetStmt *n = makeNode(VariableSetStmt); + n->kind = VAR_SET_DEFAULT; + n->name = (yyvsp[(1) - (3)].str); + (yyval.vsetstmt) = n; + ;} + break; + + case 176: + +/* Line 1455 of yacc.c */ +#line 1275 "gram.y" + { + VariableSetStmt *n = makeNode(VariableSetStmt); + n->kind = VAR_SET_DEFAULT; + n->name = (yyvsp[(1) - (3)].str); + (yyval.vsetstmt) = n; + ;} + break; + + case 177: + +/* Line 1455 of yacc.c */ +#line 1282 "gram.y" + { + VariableSetStmt *n = makeNode(VariableSetStmt); + n->kind = VAR_SET_CURRENT; + n->name = (yyvsp[(1) - (3)].str); + (yyval.vsetstmt) = n; + ;} + break; + + case 178: + +/* Line 1455 of yacc.c */ +#line 1290 "gram.y" + { + VariableSetStmt *n = makeNode(VariableSetStmt); + n->kind = VAR_SET_VALUE; + n->name = "timezone"; + if ((yyvsp[(3) - (3)].node) != NULL) + n->args = list_make1((yyvsp[(3) - (3)].node)); + else + n->kind = VAR_SET_DEFAULT; + (yyval.vsetstmt) = n; + ;} + break; + + case 179: + +/* Line 1455 of yacc.c */ +#line 1301 "gram.y" + { + ereport(ERROR, + (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), + errmsg("current database cannot be changed"), + parser_errposition((yylsp[(2) - (2)])))); + (yyval.vsetstmt) = NULL; /*not reached*/ + ;} + break; + + case 180: + +/* Line 1455 of yacc.c */ +#line 1309 "gram.y" + { + VariableSetStmt *n = makeNode(VariableSetStmt); + n->kind = VAR_SET_VALUE; + n->name = "search_path"; + n->args = list_make1(makeStringConst((yyvsp[(2) - (2)].str), (yylsp[(2) - (2)]))); + (yyval.vsetstmt) = n; + ;} + break; + + case 181: + +/* Line 1455 of yacc.c */ +#line 1317 "gram.y" + { + VariableSetStmt *n = makeNode(VariableSetStmt); + n->kind = VAR_SET_VALUE; + n->name = "client_encoding"; + if ((yyvsp[(2) - (2)].str) != NULL) + n->args = list_make1(makeStringConst((yyvsp[(2) - (2)].str), (yylsp[(2) - (2)]))); + else + n->kind = VAR_SET_DEFAULT; + (yyval.vsetstmt) = n; + ;} + break; + + case 182: + +/* Line 1455 of yacc.c */ +#line 1328 "gram.y" + { + VariableSetStmt *n = makeNode(VariableSetStmt); + n->kind = VAR_SET_VALUE; + n->name = "role"; + n->args = list_make1(makeStringConst((yyvsp[(2) - (2)].str), (yylsp[(2) - (2)]))); + (yyval.vsetstmt) = n; + ;} + break; + + case 183: + +/* Line 1455 of yacc.c */ +#line 1336 "gram.y" + { + VariableSetStmt *n = makeNode(VariableSetStmt); + n->kind = VAR_SET_VALUE; + n->name = "session_authorization"; + n->args = list_make1(makeStringConst((yyvsp[(3) - (3)].str), (yylsp[(3) - (3)]))); + (yyval.vsetstmt) = n; + ;} + break; + + case 184: + +/* Line 1455 of yacc.c */ +#line 1344 "gram.y" + { + VariableSetStmt *n = makeNode(VariableSetStmt); + n->kind = VAR_SET_DEFAULT; + n->name = "session_authorization"; + (yyval.vsetstmt) = n; + ;} + break; + + case 185: + +/* Line 1455 of yacc.c */ +#line 1351 "gram.y" + { + VariableSetStmt *n = makeNode(VariableSetStmt); + n->kind = VAR_SET_VALUE; + n->name = "xmloption"; + n->args = list_make1(makeStringConst((yyvsp[(3) - (3)].ival) == XMLOPTION_DOCUMENT ? "DOCUMENT" : "CONTENT", (yylsp[(3) - (3)]))); + (yyval.vsetstmt) = n; + ;} + break; + + case 186: + +/* Line 1455 of yacc.c */ +#line 1360 "gram.y" + { + VariableSetStmt *n = makeNode(VariableSetStmt); + n->kind = VAR_SET_MULTI; + n->name = "TRANSACTION SNAPSHOT"; + n->args = list_make1(makeStringConst((yyvsp[(3) - (3)].str), (yylsp[(3) - (3)]))); + (yyval.vsetstmt) = n; + ;} + break; + + case 187: + +/* Line 1455 of yacc.c */ +#line 1369 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 188: + +/* Line 1455 of yacc.c */ +#line 1371 "gram.y" + { + (yyval.str) = palloc(strlen((yyvsp[(1) - (3)].str)) + strlen((yyvsp[(3) - (3)].str)) + 2); + sprintf((yyval.str), "%s.%s", (yyvsp[(1) - (3)].str), (yyvsp[(3) - (3)].str)); + ;} + break; + + case 189: + +/* Line 1455 of yacc.c */ +#line 1377 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].node)); ;} + break; + + case 190: + +/* Line 1455 of yacc.c */ +#line 1378 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].node)); ;} + break; + + case 191: + +/* Line 1455 of yacc.c */ +#line 1382 "gram.y" + { (yyval.node) = makeStringConst((yyvsp[(1) - (1)].str), (yylsp[(1) - (1)])); ;} + break; + + case 192: + +/* Line 1455 of yacc.c */ +#line 1384 "gram.y" + { (yyval.node) = makeAConst((yyvsp[(1) - (1)].value), (yylsp[(1) - (1)])); ;} + break; + + case 193: + +/* Line 1455 of yacc.c */ +#line 1387 "gram.y" + { (yyval.str) = "read uncommitted"; ;} + break; + + case 194: + +/* Line 1455 of yacc.c */ +#line 1388 "gram.y" + { (yyval.str) = "read committed"; ;} + break; + + case 195: + +/* Line 1455 of yacc.c */ +#line 1389 "gram.y" + { (yyval.str) = "repeatable read"; ;} + break; + + case 196: + +/* Line 1455 of yacc.c */ +#line 1390 "gram.y" + { (yyval.str) = "serializable"; ;} + break; + + case 197: + +/* Line 1455 of yacc.c */ +#line 1394 "gram.y" + { (yyval.str) = "true"; ;} + break; + + case 198: + +/* Line 1455 of yacc.c */ +#line 1395 "gram.y" + { (yyval.str) = "false"; ;} + break; + + case 199: + +/* Line 1455 of yacc.c */ +#line 1396 "gram.y" + { (yyval.str) = "on"; ;} + break; + + case 200: + +/* Line 1455 of yacc.c */ +#line 1402 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 201: + +/* Line 1455 of yacc.c */ +#line 1415 "gram.y" + { + (yyval.node) = makeStringConst((yyvsp[(1) - (1)].str), (yylsp[(1) - (1)])); + ;} + break; + + case 202: + +/* Line 1455 of yacc.c */ +#line 1419 "gram.y" + { + (yyval.node) = makeStringConst((yyvsp[(1) - (1)].str), (yylsp[(1) - (1)])); + ;} + break; + + case 203: + +/* Line 1455 of yacc.c */ +#line 1423 "gram.y" + { + TypeName *t = (yyvsp[(1) - (3)].typnam); + if ((yyvsp[(3) - (3)].list) != NIL) + { + A_Const *n = (A_Const *) linitial((yyvsp[(3) - (3)].list)); + if ((n->val.val.ival & ~(INTERVAL_MASK(HOUR) | INTERVAL_MASK(MINUTE))) != 0) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("time zone interval must be HOUR or HOUR TO MINUTE"), + parser_errposition((yylsp[(3) - (3)])))); + } + t->typmods = (yyvsp[(3) - (3)].list); + (yyval.node) = makeStringConstCast((yyvsp[(2) - (3)].str), (yylsp[(2) - (3)]), t); + ;} + break; + + case 204: + +/* Line 1455 of yacc.c */ +#line 1438 "gram.y" + { + TypeName *t = (yyvsp[(1) - (6)].typnam); + if ((yyvsp[(6) - (6)].list) != NIL) + { + A_Const *n = (A_Const *) linitial((yyvsp[(6) - (6)].list)); + if ((n->val.val.ival & ~(INTERVAL_MASK(HOUR) | INTERVAL_MASK(MINUTE))) != 0) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("time zone interval must be HOUR or HOUR TO MINUTE"), + parser_errposition((yylsp[(6) - (6)])))); + if (list_length((yyvsp[(6) - (6)].list)) != 1) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("interval precision specified twice"), + parser_errposition((yylsp[(1) - (6)])))); + t->typmods = lappend((yyvsp[(6) - (6)].list), makeIntConst((yyvsp[(3) - (6)].ival), (yylsp[(3) - (6)]))); + } + else + t->typmods = list_make2(makeIntConst(INTERVAL_FULL_RANGE, -1), + makeIntConst((yyvsp[(3) - (6)].ival), (yylsp[(3) - (6)]))); + (yyval.node) = makeStringConstCast((yyvsp[(5) - (6)].str), (yylsp[(5) - (6)]), t); + ;} + break; + + case 205: + +/* Line 1455 of yacc.c */ +#line 1460 "gram.y" + { (yyval.node) = makeAConst((yyvsp[(1) - (1)].value), (yylsp[(1) - (1)])); ;} + break; + + case 206: + +/* Line 1455 of yacc.c */ +#line 1461 "gram.y" + { (yyval.node) = NULL; ;} + break; + + case 207: + +/* Line 1455 of yacc.c */ +#line 1462 "gram.y" + { (yyval.node) = NULL; ;} + break; + + case 208: + +/* Line 1455 of yacc.c */ +#line 1466 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 209: + +/* Line 1455 of yacc.c */ +#line 1467 "gram.y" + { (yyval.str) = NULL; ;} + break; + + case 210: + +/* Line 1455 of yacc.c */ +#line 1468 "gram.y" + { (yyval.str) = NULL; ;} + break; + + case 211: + +/* Line 1455 of yacc.c */ +#line 1472 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 212: + +/* Line 1455 of yacc.c */ +#line 1473 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 213: + +/* Line 1455 of yacc.c */ +#line 1478 "gram.y" + { + VariableSetStmt *n = makeNode(VariableSetStmt); + n->kind = VAR_RESET; + n->name = (yyvsp[(2) - (2)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 214: + +/* Line 1455 of yacc.c */ +#line 1485 "gram.y" + { + VariableSetStmt *n = makeNode(VariableSetStmt); + n->kind = VAR_RESET; + n->name = "timezone"; + (yyval.node) = (Node *) n; + ;} + break; + + case 215: + +/* Line 1455 of yacc.c */ +#line 1492 "gram.y" + { + VariableSetStmt *n = makeNode(VariableSetStmt); + n->kind = VAR_RESET; + n->name = "transaction_isolation"; + (yyval.node) = (Node *) n; + ;} + break; + + case 216: + +/* Line 1455 of yacc.c */ +#line 1499 "gram.y" + { + VariableSetStmt *n = makeNode(VariableSetStmt); + n->kind = VAR_RESET; + n->name = "session_authorization"; + (yyval.node) = (Node *) n; + ;} + break; + + case 217: + +/* Line 1455 of yacc.c */ +#line 1506 "gram.y" + { + VariableSetStmt *n = makeNode(VariableSetStmt); + n->kind = VAR_RESET_ALL; + (yyval.node) = (Node *) n; + ;} + break; + + case 218: + +/* Line 1455 of yacc.c */ +#line 1515 "gram.y" + { (yyval.vsetstmt) = (yyvsp[(2) - (2)].vsetstmt); ;} + break; + + case 219: + +/* Line 1455 of yacc.c */ +#line 1516 "gram.y" + { (yyval.vsetstmt) = (VariableSetStmt *) (yyvsp[(1) - (1)].node); ;} + break; + + case 220: + +/* Line 1455 of yacc.c */ +#line 1521 "gram.y" + { (yyval.vsetstmt) = (yyvsp[(2) - (2)].vsetstmt); ;} + break; + + case 221: + +/* Line 1455 of yacc.c */ +#line 1522 "gram.y" + { (yyval.vsetstmt) = (VariableSetStmt *) (yyvsp[(1) - (1)].node); ;} + break; + + case 222: + +/* Line 1455 of yacc.c */ +#line 1528 "gram.y" + { + VariableShowStmt *n = makeNode(VariableShowStmt); + n->name = (yyvsp[(2) - (2)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 223: + +/* Line 1455 of yacc.c */ +#line 1534 "gram.y" + { + VariableShowStmt *n = makeNode(VariableShowStmt); + n->name = "timezone"; + (yyval.node) = (Node *) n; + ;} + break; + + case 224: + +/* Line 1455 of yacc.c */ +#line 1540 "gram.y" + { + VariableShowStmt *n = makeNode(VariableShowStmt); + n->name = "transaction_isolation"; + (yyval.node) = (Node *) n; + ;} + break; + + case 225: + +/* Line 1455 of yacc.c */ +#line 1546 "gram.y" + { + VariableShowStmt *n = makeNode(VariableShowStmt); + n->name = "session_authorization"; + (yyval.node) = (Node *) n; + ;} + break; + + case 226: + +/* Line 1455 of yacc.c */ +#line 1552 "gram.y" + { + VariableShowStmt *n = makeNode(VariableShowStmt); + n->name = "all"; + (yyval.node) = (Node *) n; + ;} + break; + + case 227: + +/* Line 1455 of yacc.c */ +#line 1562 "gram.y" + { + ConstraintsSetStmt *n = makeNode(ConstraintsSetStmt); + n->constraints = (yyvsp[(3) - (4)].list); + n->deferred = (yyvsp[(4) - (4)].boolean); + (yyval.node) = (Node *) n; + ;} + break; + + case 228: + +/* Line 1455 of yacc.c */ +#line 1571 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 229: + +/* Line 1455 of yacc.c */ +#line 1572 "gram.y" + { (yyval.list) = (yyvsp[(1) - (1)].list); ;} + break; + + case 230: + +/* Line 1455 of yacc.c */ +#line 1576 "gram.y" + { (yyval.boolean) = TRUE; ;} + break; + + case 231: + +/* Line 1455 of yacc.c */ +#line 1577 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 232: + +/* Line 1455 of yacc.c */ +#line 1586 "gram.y" + { + CheckPointStmt *n = makeNode(CheckPointStmt); + (yyval.node) = (Node *)n; + ;} + break; + + case 233: + +/* Line 1455 of yacc.c */ +#line 1601 "gram.y" + { + DiscardStmt *n = makeNode(DiscardStmt); + n->target = DISCARD_ALL; + (yyval.node) = (Node *) n; + ;} + break; + + case 234: + +/* Line 1455 of yacc.c */ +#line 1607 "gram.y" + { + DiscardStmt *n = makeNode(DiscardStmt); + n->target = DISCARD_TEMP; + (yyval.node) = (Node *) n; + ;} + break; + + case 235: + +/* Line 1455 of yacc.c */ +#line 1613 "gram.y" + { + DiscardStmt *n = makeNode(DiscardStmt); + n->target = DISCARD_TEMP; + (yyval.node) = (Node *) n; + ;} + break; + + case 236: + +/* Line 1455 of yacc.c */ +#line 1619 "gram.y" + { + DiscardStmt *n = makeNode(DiscardStmt); + n->target = DISCARD_PLANS; + (yyval.node) = (Node *) n; + ;} + break; + + case 237: + +/* Line 1455 of yacc.c */ +#line 1637 "gram.y" + { + AlterTableStmt *n = makeNode(AlterTableStmt); + n->relation = (yyvsp[(3) - (4)].range); + n->cmds = (yyvsp[(4) - (4)].list); + n->relkind = OBJECT_TABLE; + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 238: + +/* Line 1455 of yacc.c */ +#line 1646 "gram.y" + { + AlterTableStmt *n = makeNode(AlterTableStmt); + n->relation = (yyvsp[(5) - (6)].range); + n->cmds = (yyvsp[(6) - (6)].list); + n->relkind = OBJECT_TABLE; + n->missing_ok = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 239: + +/* Line 1455 of yacc.c */ +#line 1655 "gram.y" + { + AlterTableStmt *n = makeNode(AlterTableStmt); + n->relation = (yyvsp[(3) - (4)].range); + n->cmds = (yyvsp[(4) - (4)].list); + n->relkind = OBJECT_INDEX; + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 240: + +/* Line 1455 of yacc.c */ +#line 1664 "gram.y" + { + AlterTableStmt *n = makeNode(AlterTableStmt); + n->relation = (yyvsp[(5) - (6)].range); + n->cmds = (yyvsp[(6) - (6)].list); + n->relkind = OBJECT_INDEX; + n->missing_ok = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 241: + +/* Line 1455 of yacc.c */ +#line 1673 "gram.y" + { + AlterTableStmt *n = makeNode(AlterTableStmt); + n->relation = (yyvsp[(3) - (4)].range); + n->cmds = (yyvsp[(4) - (4)].list); + n->relkind = OBJECT_SEQUENCE; + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 242: + +/* Line 1455 of yacc.c */ +#line 1682 "gram.y" + { + AlterTableStmt *n = makeNode(AlterTableStmt); + n->relation = (yyvsp[(5) - (6)].range); + n->cmds = (yyvsp[(6) - (6)].list); + n->relkind = OBJECT_SEQUENCE; + n->missing_ok = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 243: + +/* Line 1455 of yacc.c */ +#line 1691 "gram.y" + { + AlterTableStmt *n = makeNode(AlterTableStmt); + n->relation = (yyvsp[(3) - (4)].range); + n->cmds = (yyvsp[(4) - (4)].list); + n->relkind = OBJECT_VIEW; + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 244: + +/* Line 1455 of yacc.c */ +#line 1700 "gram.y" + { + AlterTableStmt *n = makeNode(AlterTableStmt); + n->relation = (yyvsp[(5) - (6)].range); + n->cmds = (yyvsp[(6) - (6)].list); + n->relkind = OBJECT_VIEW; + n->missing_ok = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 245: + +/* Line 1455 of yacc.c */ +#line 1711 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].node)); ;} + break; + + case 246: + +/* Line 1455 of yacc.c */ +#line 1712 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].node)); ;} + break; + + case 247: + +/* Line 1455 of yacc.c */ +#line 1718 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_AddColumn; + n->def = (yyvsp[(2) - (2)].node); + (yyval.node) = (Node *)n; + ;} + break; + + case 248: + +/* Line 1455 of yacc.c */ +#line 1726 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_AddColumn; + n->def = (yyvsp[(3) - (3)].node); + (yyval.node) = (Node *)n; + ;} + break; + + case 249: + +/* Line 1455 of yacc.c */ +#line 1734 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_ColumnDefault; + n->name = (yyvsp[(3) - (4)].str); + n->def = (yyvsp[(4) - (4)].node); + (yyval.node) = (Node *)n; + ;} + break; + + case 250: + +/* Line 1455 of yacc.c */ +#line 1743 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_DropNotNull; + n->name = (yyvsp[(3) - (6)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 251: + +/* Line 1455 of yacc.c */ +#line 1751 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_SetNotNull; + n->name = (yyvsp[(3) - (6)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 252: + +/* Line 1455 of yacc.c */ +#line 1759 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_SetStatistics; + n->name = (yyvsp[(3) - (6)].str); + n->def = (Node *) makeInteger((yyvsp[(6) - (6)].ival)); + (yyval.node) = (Node *)n; + ;} + break; + + case 253: + +/* Line 1455 of yacc.c */ +#line 1768 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_SetOptions; + n->name = (yyvsp[(3) - (5)].str); + n->def = (Node *) (yyvsp[(5) - (5)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 254: + +/* Line 1455 of yacc.c */ +#line 1777 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_ResetOptions; + n->name = (yyvsp[(3) - (5)].str); + n->def = (Node *) (yyvsp[(5) - (5)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 255: + +/* Line 1455 of yacc.c */ +#line 1786 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_SetStorage; + n->name = (yyvsp[(3) - (6)].str); + n->def = (Node *) makeString((yyvsp[(6) - (6)].str)); + (yyval.node) = (Node *)n; + ;} + break; + + case 256: + +/* Line 1455 of yacc.c */ +#line 1795 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_DropColumn; + n->name = (yyvsp[(5) - (6)].str); + n->behavior = (yyvsp[(6) - (6)].dbehavior); + n->missing_ok = TRUE; + (yyval.node) = (Node *)n; + ;} + break; + + case 257: + +/* Line 1455 of yacc.c */ +#line 1805 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_DropColumn; + n->name = (yyvsp[(3) - (4)].str); + n->behavior = (yyvsp[(4) - (4)].dbehavior); + n->missing_ok = FALSE; + (yyval.node) = (Node *)n; + ;} + break; + + case 258: + +/* Line 1455 of yacc.c */ +#line 1818 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + ColumnDef *def = makeNode(ColumnDef); + n->subtype = AT_AlterColumnType; + n->name = (yyvsp[(3) - (8)].str); + n->def = (Node *) def; + /* We only use these three fields of the ColumnDef node */ + def->typeName = (yyvsp[(6) - (8)].typnam); + def->collClause = (CollateClause *) (yyvsp[(7) - (8)].node); + def->raw_default = (yyvsp[(8) - (8)].node); + (yyval.node) = (Node *)n; + ;} + break; + + case 259: + +/* Line 1455 of yacc.c */ +#line 1832 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_AlterColumnGenericOptions; + n->name = (yyvsp[(3) - (4)].str); + n->def = (Node *) (yyvsp[(4) - (4)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 260: + +/* Line 1455 of yacc.c */ +#line 1841 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_AddConstraint; + n->def = (yyvsp[(2) - (2)].node); + (yyval.node) = (Node *)n; + ;} + break; + + case 261: + +/* Line 1455 of yacc.c */ +#line 1849 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_ValidateConstraint; + n->name = (yyvsp[(3) - (3)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 262: + +/* Line 1455 of yacc.c */ +#line 1857 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_DropConstraint; + n->name = (yyvsp[(5) - (6)].str); + n->behavior = (yyvsp[(6) - (6)].dbehavior); + n->missing_ok = TRUE; + (yyval.node) = (Node *)n; + ;} + break; + + case 263: + +/* Line 1455 of yacc.c */ +#line 1867 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_DropConstraint; + n->name = (yyvsp[(3) - (4)].str); + n->behavior = (yyvsp[(4) - (4)].dbehavior); + n->missing_ok = FALSE; + (yyval.node) = (Node *)n; + ;} + break; + + case 264: + +/* Line 1455 of yacc.c */ +#line 1877 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_AddOids; + (yyval.node) = (Node *)n; + ;} + break; + + case 265: + +/* Line 1455 of yacc.c */ +#line 1884 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_DropOids; + (yyval.node) = (Node *)n; + ;} + break; + + case 266: + +/* Line 1455 of yacc.c */ +#line 1891 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_ClusterOn; + n->name = (yyvsp[(3) - (3)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 267: + +/* Line 1455 of yacc.c */ +#line 1899 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_DropCluster; + n->name = NULL; + (yyval.node) = (Node *)n; + ;} + break; + + case 268: + +/* Line 1455 of yacc.c */ +#line 1907 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_EnableTrig; + n->name = (yyvsp[(3) - (3)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 269: + +/* Line 1455 of yacc.c */ +#line 1915 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_EnableAlwaysTrig; + n->name = (yyvsp[(4) - (4)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 270: + +/* Line 1455 of yacc.c */ +#line 1923 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_EnableReplicaTrig; + n->name = (yyvsp[(4) - (4)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 271: + +/* Line 1455 of yacc.c */ +#line 1931 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_EnableTrigAll; + (yyval.node) = (Node *)n; + ;} + break; + + case 272: + +/* Line 1455 of yacc.c */ +#line 1938 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_EnableTrigUser; + (yyval.node) = (Node *)n; + ;} + break; + + case 273: + +/* Line 1455 of yacc.c */ +#line 1945 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_DisableTrig; + n->name = (yyvsp[(3) - (3)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 274: + +/* Line 1455 of yacc.c */ +#line 1953 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_DisableTrigAll; + (yyval.node) = (Node *)n; + ;} + break; + + case 275: + +/* Line 1455 of yacc.c */ +#line 1960 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_DisableTrigUser; + (yyval.node) = (Node *)n; + ;} + break; + + case 276: + +/* Line 1455 of yacc.c */ +#line 1967 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_EnableRule; + n->name = (yyvsp[(3) - (3)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 277: + +/* Line 1455 of yacc.c */ +#line 1975 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_EnableAlwaysRule; + n->name = (yyvsp[(4) - (4)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 278: + +/* Line 1455 of yacc.c */ +#line 1983 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_EnableReplicaRule; + n->name = (yyvsp[(4) - (4)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 279: + +/* Line 1455 of yacc.c */ +#line 1991 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_DisableRule; + n->name = (yyvsp[(3) - (3)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 280: + +/* Line 1455 of yacc.c */ +#line 1999 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_AddInherit; + n->def = (Node *) (yyvsp[(2) - (2)].range); + (yyval.node) = (Node *)n; + ;} + break; + + case 281: + +/* Line 1455 of yacc.c */ +#line 2007 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_DropInherit; + n->def = (Node *) (yyvsp[(3) - (3)].range); + (yyval.node) = (Node *)n; + ;} + break; + + case 282: + +/* Line 1455 of yacc.c */ +#line 2015 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + TypeName *def = makeTypeNameFromNameList((yyvsp[(2) - (2)].list)); + def->location = (yylsp[(2) - (2)]); + n->subtype = AT_AddOf; + n->def = (Node *) def; + (yyval.node) = (Node *)n; + ;} + break; + + case 283: + +/* Line 1455 of yacc.c */ +#line 2025 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_DropOf; + (yyval.node) = (Node *)n; + ;} + break; + + case 284: + +/* Line 1455 of yacc.c */ +#line 2032 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_ChangeOwner; + n->name = (yyvsp[(3) - (3)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 285: + +/* Line 1455 of yacc.c */ +#line 2040 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_SetTableSpace; + n->name = (yyvsp[(3) - (3)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 286: + +/* Line 1455 of yacc.c */ +#line 2048 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_SetRelOptions; + n->def = (Node *)(yyvsp[(2) - (2)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 287: + +/* Line 1455 of yacc.c */ +#line 2056 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_ResetRelOptions; + n->def = (Node *)(yyvsp[(2) - (2)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 288: + +/* Line 1455 of yacc.c */ +#line 2063 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_GenericOptions; + n->def = (Node *)(yyvsp[(1) - (1)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 289: + +/* Line 1455 of yacc.c */ +#line 2072 "gram.y" + { (yyval.node) = (yyvsp[(3) - (3)].node); ;} + break; + + case 290: + +/* Line 1455 of yacc.c */ +#line 2073 "gram.y" + { (yyval.node) = NULL; ;} + break; + + case 291: + +/* Line 1455 of yacc.c */ +#line 2077 "gram.y" + { (yyval.dbehavior) = DROP_CASCADE; ;} + break; + + case 292: + +/* Line 1455 of yacc.c */ +#line 2078 "gram.y" + { (yyval.dbehavior) = DROP_RESTRICT; ;} + break; + + case 293: + +/* Line 1455 of yacc.c */ +#line 2079 "gram.y" + { (yyval.dbehavior) = DROP_RESTRICT; /* default */ ;} + break; + + case 294: + +/* Line 1455 of yacc.c */ +#line 2084 "gram.y" + { + CollateClause *n = makeNode(CollateClause); + n->arg = NULL; + n->collname = (yyvsp[(2) - (2)].list); + n->location = (yylsp[(1) - (2)]); + (yyval.node) = (Node *) n; + ;} + break; + + case 295: + +/* Line 1455 of yacc.c */ +#line 2091 "gram.y" + { (yyval.node) = NULL; ;} + break; + + case 296: + +/* Line 1455 of yacc.c */ +#line 2095 "gram.y" + { (yyval.node) = (yyvsp[(2) - (2)].node); ;} + break; + + case 297: + +/* Line 1455 of yacc.c */ +#line 2096 "gram.y" + { (yyval.node) = NULL; ;} + break; + + case 298: + +/* Line 1455 of yacc.c */ +#line 2100 "gram.y" + { (yyval.list) = (yyvsp[(2) - (3)].list); ;} + break; + + case 299: + +/* Line 1455 of yacc.c */ +#line 2103 "gram.y" + { (yyval.list) = (yyvsp[(2) - (2)].list); ;} + break; + + case 300: + +/* Line 1455 of yacc.c */ +#line 2104 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 301: + +/* Line 1455 of yacc.c */ +#line 2108 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].defelt)); ;} + break; + + case 302: + +/* Line 1455 of yacc.c */ +#line 2109 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].defelt)); ;} + break; + + case 303: + +/* Line 1455 of yacc.c */ +#line 2115 "gram.y" + { + (yyval.defelt) = makeDefElem((yyvsp[(1) - (3)].str), (Node *) (yyvsp[(3) - (3)].node)); + ;} + break; + + case 304: + +/* Line 1455 of yacc.c */ +#line 2119 "gram.y" + { + (yyval.defelt) = makeDefElem((yyvsp[(1) - (1)].str), NULL); + ;} + break; + + case 305: + +/* Line 1455 of yacc.c */ +#line 2123 "gram.y" + { + (yyval.defelt) = makeDefElemExtended((yyvsp[(1) - (5)].str), (yyvsp[(3) - (5)].str), (Node *) (yyvsp[(5) - (5)].node), + DEFELEM_UNSPEC); + ;} + break; + + case 306: + +/* Line 1455 of yacc.c */ +#line 2128 "gram.y" + { + (yyval.defelt) = makeDefElemExtended((yyvsp[(1) - (3)].str), (yyvsp[(3) - (3)].str), NULL, DEFELEM_UNSPEC); + ;} + break; + + case 307: + +/* Line 1455 of yacc.c */ +#line 2143 "gram.y" + { + AlterTableStmt *n = makeNode(AlterTableStmt); + + /* can't use qualified_name, sigh */ + n->relation = makeRangeVarFromAnyName((yyvsp[(3) - (4)].list), (yylsp[(3) - (4)]), yyscanner); + n->cmds = (yyvsp[(4) - (4)].list); + n->relkind = OBJECT_TYPE; + (yyval.node) = (Node *)n; + ;} + break; + + case 308: + +/* Line 1455 of yacc.c */ +#line 2155 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].node)); ;} + break; + + case 309: + +/* Line 1455 of yacc.c */ +#line 2156 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].node)); ;} + break; + + case 310: + +/* Line 1455 of yacc.c */ +#line 2162 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_AddColumn; + n->def = (yyvsp[(3) - (4)].node); + n->behavior = (yyvsp[(4) - (4)].dbehavior); + (yyval.node) = (Node *)n; + ;} + break; + + case 311: + +/* Line 1455 of yacc.c */ +#line 2171 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_DropColumn; + n->name = (yyvsp[(5) - (6)].str); + n->behavior = (yyvsp[(6) - (6)].dbehavior); + n->missing_ok = TRUE; + (yyval.node) = (Node *)n; + ;} + break; + + case 312: + +/* Line 1455 of yacc.c */ +#line 2181 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + n->subtype = AT_DropColumn; + n->name = (yyvsp[(3) - (4)].str); + n->behavior = (yyvsp[(4) - (4)].dbehavior); + n->missing_ok = FALSE; + (yyval.node) = (Node *)n; + ;} + break; + + case 313: + +/* Line 1455 of yacc.c */ +#line 2191 "gram.y" + { + AlterTableCmd *n = makeNode(AlterTableCmd); + ColumnDef *def = makeNode(ColumnDef); + n->subtype = AT_AlterColumnType; + n->name = (yyvsp[(3) - (8)].str); + n->def = (Node *) def; + n->behavior = (yyvsp[(8) - (8)].dbehavior); + /* We only use these three fields of the ColumnDef node */ + def->typeName = (yyvsp[(6) - (8)].typnam); + def->collClause = (CollateClause *) (yyvsp[(7) - (8)].node); + def->raw_default = NULL; + (yyval.node) = (Node *)n; + ;} + break; + + case 314: + +/* Line 1455 of yacc.c */ +#line 2216 "gram.y" + { + ClosePortalStmt *n = makeNode(ClosePortalStmt); + n->portalname = (yyvsp[(2) - (2)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 315: + +/* Line 1455 of yacc.c */ +#line 2222 "gram.y" + { + ClosePortalStmt *n = makeNode(ClosePortalStmt); + n->portalname = NULL; + (yyval.node) = (Node *)n; + ;} + break; + + case 316: + +/* Line 1455 of yacc.c */ +#line 2250 "gram.y" + { + CopyStmt *n = makeNode(CopyStmt); + n->relation = (yyvsp[(3) - (10)].range); + n->query = NULL; + n->attlist = (yyvsp[(4) - (10)].list); + n->is_from = (yyvsp[(6) - (10)].boolean); + n->filename = (yyvsp[(7) - (10)].str); + + n->options = NIL; + /* Concatenate user-supplied flags */ + if ((yyvsp[(2) - (10)].defelt)) + n->options = lappend(n->options, (yyvsp[(2) - (10)].defelt)); + if ((yyvsp[(5) - (10)].defelt)) + n->options = lappend(n->options, (yyvsp[(5) - (10)].defelt)); + if ((yyvsp[(8) - (10)].defelt)) + n->options = lappend(n->options, (yyvsp[(8) - (10)].defelt)); + if ((yyvsp[(10) - (10)].list)) + n->options = list_concat(n->options, (yyvsp[(10) - (10)].list)); + (yyval.node) = (Node *)n; + ;} + break; + + case 317: + +/* Line 1455 of yacc.c */ +#line 2271 "gram.y" + { + CopyStmt *n = makeNode(CopyStmt); + n->relation = NULL; + n->query = (yyvsp[(2) - (6)].node); + n->attlist = NIL; + n->is_from = false; + n->filename = (yyvsp[(4) - (6)].str); + n->options = (yyvsp[(6) - (6)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 318: + +/* Line 1455 of yacc.c */ +#line 2284 "gram.y" + { (yyval.boolean) = TRUE; ;} + break; + + case 319: + +/* Line 1455 of yacc.c */ +#line 2285 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 320: + +/* Line 1455 of yacc.c */ +#line 2294 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 321: + +/* Line 1455 of yacc.c */ +#line 2295 "gram.y" + { (yyval.str) = NULL; ;} + break; + + case 322: + +/* Line 1455 of yacc.c */ +#line 2296 "gram.y" + { (yyval.str) = NULL; ;} + break; + + case 323: + +/* Line 1455 of yacc.c */ +#line 2299 "gram.y" + { (yyval.list) = (yyvsp[(1) - (1)].list); ;} + break; + + case 324: + +/* Line 1455 of yacc.c */ +#line 2300 "gram.y" + { (yyval.list) = (yyvsp[(2) - (3)].list); ;} + break; + + case 325: + +/* Line 1455 of yacc.c */ +#line 2305 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (2)].list), (yyvsp[(2) - (2)].defelt)); ;} + break; + + case 326: + +/* Line 1455 of yacc.c */ +#line 2306 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 327: + +/* Line 1455 of yacc.c */ +#line 2311 "gram.y" + { + (yyval.defelt) = makeDefElem("format", (Node *)makeString("binary")); + ;} + break; + + case 328: + +/* Line 1455 of yacc.c */ +#line 2315 "gram.y" + { + (yyval.defelt) = makeDefElem("oids", (Node *)makeInteger(TRUE)); + ;} + break; + + case 329: + +/* Line 1455 of yacc.c */ +#line 2319 "gram.y" + { + (yyval.defelt) = makeDefElem("delimiter", (Node *)makeString((yyvsp[(3) - (3)].str))); + ;} + break; + + case 330: + +/* Line 1455 of yacc.c */ +#line 2323 "gram.y" + { + (yyval.defelt) = makeDefElem("null", (Node *)makeString((yyvsp[(3) - (3)].str))); + ;} + break; + + case 331: + +/* Line 1455 of yacc.c */ +#line 2327 "gram.y" + { + (yyval.defelt) = makeDefElem("format", (Node *)makeString("csv")); + ;} + break; + + case 332: + +/* Line 1455 of yacc.c */ +#line 2331 "gram.y" + { + (yyval.defelt) = makeDefElem("header", (Node *)makeInteger(TRUE)); + ;} + break; + + case 333: + +/* Line 1455 of yacc.c */ +#line 2335 "gram.y" + { + (yyval.defelt) = makeDefElem("quote", (Node *)makeString((yyvsp[(3) - (3)].str))); + ;} + break; + + case 334: + +/* Line 1455 of yacc.c */ +#line 2339 "gram.y" + { + (yyval.defelt) = makeDefElem("escape", (Node *)makeString((yyvsp[(3) - (3)].str))); + ;} + break; + + case 335: + +/* Line 1455 of yacc.c */ +#line 2343 "gram.y" + { + (yyval.defelt) = makeDefElem("force_quote", (Node *)(yyvsp[(3) - (3)].list)); + ;} + break; + + case 336: + +/* Line 1455 of yacc.c */ +#line 2347 "gram.y" + { + (yyval.defelt) = makeDefElem("force_quote", (Node *)makeNode(A_Star)); + ;} + break; + + case 337: + +/* Line 1455 of yacc.c */ +#line 2351 "gram.y" + { + (yyval.defelt) = makeDefElem("force_not_null", (Node *)(yyvsp[(4) - (4)].list)); + ;} + break; + + case 338: + +/* Line 1455 of yacc.c */ +#line 2355 "gram.y" + { + (yyval.defelt) = makeDefElem("encoding", (Node *)makeString((yyvsp[(2) - (2)].str))); + ;} + break; + + case 339: + +/* Line 1455 of yacc.c */ +#line 2364 "gram.y" + { + (yyval.defelt) = makeDefElem("format", (Node *)makeString("binary")); + ;} + break; + + case 340: + +/* Line 1455 of yacc.c */ +#line 2367 "gram.y" + { (yyval.defelt) = NULL; ;} + break; + + case 341: + +/* Line 1455 of yacc.c */ +#line 2372 "gram.y" + { + (yyval.defelt) = makeDefElem("oids", (Node *)makeInteger(TRUE)); + ;} + break; + + case 342: + +/* Line 1455 of yacc.c */ +#line 2375 "gram.y" + { (yyval.defelt) = NULL; ;} + break; + + case 343: + +/* Line 1455 of yacc.c */ +#line 2380 "gram.y" + { + (yyval.defelt) = makeDefElem("delimiter", (Node *)makeString((yyvsp[(3) - (3)].str))); + ;} + break; + + case 344: + +/* Line 1455 of yacc.c */ +#line 2383 "gram.y" + { (yyval.defelt) = NULL; ;} + break; + + case 345: + +/* Line 1455 of yacc.c */ +#line 2387 "gram.y" + {;} + break; + + case 346: + +/* Line 1455 of yacc.c */ +#line 2388 "gram.y" + {;} + break; + + case 347: + +/* Line 1455 of yacc.c */ +#line 2394 "gram.y" + { + (yyval.list) = list_make1((yyvsp[(1) - (1)].defelt)); + ;} + break; + + case 348: + +/* Line 1455 of yacc.c */ +#line 2398 "gram.y" + { + (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].defelt)); + ;} + break; + + case 349: + +/* Line 1455 of yacc.c */ +#line 2405 "gram.y" + { + (yyval.defelt) = makeDefElem((yyvsp[(1) - (2)].str), (yyvsp[(2) - (2)].node)); + ;} + break; + + case 350: + +/* Line 1455 of yacc.c */ +#line 2411 "gram.y" + { (yyval.node) = (Node *) makeString((yyvsp[(1) - (1)].str)); ;} + break; + + case 351: + +/* Line 1455 of yacc.c */ +#line 2412 "gram.y" + { (yyval.node) = (Node *) (yyvsp[(1) - (1)].value); ;} + break; + + case 352: + +/* Line 1455 of yacc.c */ +#line 2413 "gram.y" + { (yyval.node) = (Node *) makeNode(A_Star); ;} + break; + + case 353: + +/* Line 1455 of yacc.c */ +#line 2414 "gram.y" + { (yyval.node) = (Node *) (yyvsp[(2) - (3)].list); ;} + break; + + case 354: + +/* Line 1455 of yacc.c */ +#line 2415 "gram.y" + { (yyval.node) = NULL; ;} + break; + + case 355: + +/* Line 1455 of yacc.c */ +#line 2420 "gram.y" + { + (yyval.list) = list_make1((yyvsp[(1) - (1)].node)); + ;} + break; + + case 356: + +/* Line 1455 of yacc.c */ +#line 2424 "gram.y" + { + (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].node)); + ;} + break; + + case 357: + +/* Line 1455 of yacc.c */ +#line 2431 "gram.y" + { (yyval.node) = (Node *) makeString((yyvsp[(1) - (1)].str)); ;} + break; + + case 358: + +/* Line 1455 of yacc.c */ +#line 2444 "gram.y" + { + CreateStmt *n = makeNode(CreateStmt); + (yyvsp[(4) - (11)].range)->relpersistence = (yyvsp[(2) - (11)].ival); + n->relation = (yyvsp[(4) - (11)].range); + n->tableElts = (yyvsp[(6) - (11)].list); + n->inhRelations = (yyvsp[(8) - (11)].list); + n->constraints = NIL; + n->options = (yyvsp[(9) - (11)].list); + n->oncommit = (yyvsp[(10) - (11)].oncommit); + n->tablespacename = (yyvsp[(11) - (11)].str); + n->if_not_exists = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 359: + +/* Line 1455 of yacc.c */ +#line 2460 "gram.y" + { + CreateStmt *n = makeNode(CreateStmt); + (yyvsp[(7) - (14)].range)->relpersistence = (yyvsp[(2) - (14)].ival); + n->relation = (yyvsp[(7) - (14)].range); + n->tableElts = (yyvsp[(9) - (14)].list); + n->inhRelations = (yyvsp[(11) - (14)].list); + n->constraints = NIL; + n->options = (yyvsp[(12) - (14)].list); + n->oncommit = (yyvsp[(13) - (14)].oncommit); + n->tablespacename = (yyvsp[(14) - (14)].str); + n->if_not_exists = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 360: + +/* Line 1455 of yacc.c */ +#line 2475 "gram.y" + { + CreateStmt *n = makeNode(CreateStmt); + (yyvsp[(4) - (10)].range)->relpersistence = (yyvsp[(2) - (10)].ival); + n->relation = (yyvsp[(4) - (10)].range); + n->tableElts = (yyvsp[(7) - (10)].list); + n->ofTypename = makeTypeNameFromNameList((yyvsp[(6) - (10)].list)); + n->ofTypename->location = (yylsp[(6) - (10)]); + n->constraints = NIL; + n->options = (yyvsp[(8) - (10)].list); + n->oncommit = (yyvsp[(9) - (10)].oncommit); + n->tablespacename = (yyvsp[(10) - (10)].str); + n->if_not_exists = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 361: + +/* Line 1455 of yacc.c */ +#line 2491 "gram.y" + { + CreateStmt *n = makeNode(CreateStmt); + (yyvsp[(7) - (13)].range)->relpersistence = (yyvsp[(2) - (13)].ival); + n->relation = (yyvsp[(7) - (13)].range); + n->tableElts = (yyvsp[(10) - (13)].list); + n->ofTypename = makeTypeNameFromNameList((yyvsp[(9) - (13)].list)); + n->ofTypename->location = (yylsp[(9) - (13)]); + n->constraints = NIL; + n->options = (yyvsp[(11) - (13)].list); + n->oncommit = (yyvsp[(12) - (13)].oncommit); + n->tablespacename = (yyvsp[(13) - (13)].str); + n->if_not_exists = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 362: + +/* Line 1455 of yacc.c */ +#line 2518 "gram.y" + { (yyval.ival) = RELPERSISTENCE_TEMP; ;} + break; + + case 363: + +/* Line 1455 of yacc.c */ +#line 2519 "gram.y" + { (yyval.ival) = RELPERSISTENCE_TEMP; ;} + break; + + case 364: + +/* Line 1455 of yacc.c */ +#line 2520 "gram.y" + { (yyval.ival) = RELPERSISTENCE_TEMP; ;} + break; + + case 365: + +/* Line 1455 of yacc.c */ +#line 2521 "gram.y" + { (yyval.ival) = RELPERSISTENCE_TEMP; ;} + break; + + case 366: + +/* Line 1455 of yacc.c */ +#line 2523 "gram.y" + { + ereport(WARNING, + (errmsg("GLOBAL is deprecated in temporary table creation"), + parser_errposition((yylsp[(1) - (2)])))); + (yyval.ival) = RELPERSISTENCE_TEMP; + ;} + break; + + case 367: + +/* Line 1455 of yacc.c */ +#line 2530 "gram.y" + { + ereport(WARNING, + (errmsg("GLOBAL is deprecated in temporary table creation"), + parser_errposition((yylsp[(1) - (2)])))); + (yyval.ival) = RELPERSISTENCE_TEMP; + ;} + break; + + case 368: + +/* Line 1455 of yacc.c */ +#line 2536 "gram.y" + { (yyval.ival) = RELPERSISTENCE_UNLOGGED; ;} + break; + + case 369: + +/* Line 1455 of yacc.c */ +#line 2537 "gram.y" + { (yyval.ival) = RELPERSISTENCE_PERMANENT; ;} + break; + + case 370: + +/* Line 1455 of yacc.c */ +#line 2541 "gram.y" + { (yyval.list) = (yyvsp[(1) - (1)].list); ;} + break; + + case 371: + +/* Line 1455 of yacc.c */ +#line 2542 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 372: + +/* Line 1455 of yacc.c */ +#line 2546 "gram.y" + { (yyval.list) = (yyvsp[(2) - (3)].list); ;} + break; + + case 373: + +/* Line 1455 of yacc.c */ +#line 2547 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 374: + +/* Line 1455 of yacc.c */ +#line 2552 "gram.y" + { + (yyval.list) = list_make1((yyvsp[(1) - (1)].node)); + ;} + break; + + case 375: + +/* Line 1455 of yacc.c */ +#line 2556 "gram.y" + { + (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].node)); + ;} + break; + + case 376: + +/* Line 1455 of yacc.c */ +#line 2563 "gram.y" + { + (yyval.list) = list_make1((yyvsp[(1) - (1)].node)); + ;} + break; + + case 377: + +/* Line 1455 of yacc.c */ +#line 2567 "gram.y" + { + (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].node)); + ;} + break; + + case 378: + +/* Line 1455 of yacc.c */ +#line 2573 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 379: + +/* Line 1455 of yacc.c */ +#line 2574 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 380: + +/* Line 1455 of yacc.c */ +#line 2575 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 381: + +/* Line 1455 of yacc.c */ +#line 2579 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 382: + +/* Line 1455 of yacc.c */ +#line 2580 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 383: + +/* Line 1455 of yacc.c */ +#line 2584 "gram.y" + { + ColumnDef *n = makeNode(ColumnDef); + n->colname = (yyvsp[(1) - (4)].str); + n->typeName = (yyvsp[(2) - (4)].typnam); + n->inhcount = 0; + n->is_local = true; + n->is_not_null = false; + n->is_from_type = false; + n->storage = 0; + n->raw_default = NULL; + n->cooked_default = NULL; + n->collOid = InvalidOid; + n->fdwoptions = (yyvsp[(3) - (4)].list); + SplitColQualList((yyvsp[(4) - (4)].list), &n->constraints, &n->collClause, + yyscanner); + (yyval.node) = (Node *)n; + ;} + break; + + case 384: + +/* Line 1455 of yacc.c */ +#line 2604 "gram.y" + { + ColumnDef *n = makeNode(ColumnDef); + n->colname = (yyvsp[(1) - (4)].str); + n->typeName = NULL; + n->inhcount = 0; + n->is_local = true; + n->is_not_null = false; + n->is_from_type = false; + n->storage = 0; + n->raw_default = NULL; + n->cooked_default = NULL; + n->collOid = InvalidOid; + SplitColQualList((yyvsp[(4) - (4)].list), &n->constraints, &n->collClause, + yyscanner); + (yyval.node) = (Node *)n; + ;} + break; + + case 385: + +/* Line 1455 of yacc.c */ +#line 2623 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (2)].list), (yyvsp[(2) - (2)].node)); ;} + break; + + case 386: + +/* Line 1455 of yacc.c */ +#line 2624 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 387: + +/* Line 1455 of yacc.c */ +#line 2629 "gram.y" + { + Constraint *n = (Constraint *) (yyvsp[(3) - (3)].node); + Assert(IsA(n, Constraint)); + n->conname = (yyvsp[(2) - (3)].str); + n->location = (yylsp[(1) - (3)]); + (yyval.node) = (Node *) n; + ;} + break; + + case 388: + +/* Line 1455 of yacc.c */ +#line 2636 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 389: + +/* Line 1455 of yacc.c */ +#line 2637 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 390: + +/* Line 1455 of yacc.c */ +#line 2639 "gram.y" + { + /* + * Note: the CollateClause is momentarily included in + * the list built by ColQualList, but we split it out + * again in SplitColQualList. + */ + CollateClause *n = makeNode(CollateClause); + n->arg = NULL; + n->collname = (yyvsp[(2) - (2)].list); + n->location = (yylsp[(1) - (2)]); + (yyval.node) = (Node *) n; + ;} + break; + + case 391: + +/* Line 1455 of yacc.c */ +#line 2670 "gram.y" + { + Constraint *n = makeNode(Constraint); + n->contype = CONSTR_NOTNULL; + n->location = (yylsp[(1) - (2)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 392: + +/* Line 1455 of yacc.c */ +#line 2677 "gram.y" + { + Constraint *n = makeNode(Constraint); + n->contype = CONSTR_NULL; + n->location = (yylsp[(1) - (1)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 393: + +/* Line 1455 of yacc.c */ +#line 2684 "gram.y" + { + Constraint *n = makeNode(Constraint); + n->contype = CONSTR_UNIQUE; + n->location = (yylsp[(1) - (3)]); + n->keys = NULL; + n->options = (yyvsp[(2) - (3)].list); + n->indexname = NULL; + n->indexspace = (yyvsp[(3) - (3)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 394: + +/* Line 1455 of yacc.c */ +#line 2695 "gram.y" + { + Constraint *n = makeNode(Constraint); + n->contype = CONSTR_PRIMARY; + n->location = (yylsp[(1) - (4)]); + n->keys = NULL; + n->options = (yyvsp[(3) - (4)].list); + n->indexname = NULL; + n->indexspace = (yyvsp[(4) - (4)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 395: + +/* Line 1455 of yacc.c */ +#line 2706 "gram.y" + { + Constraint *n = makeNode(Constraint); + n->contype = CONSTR_CHECK; + n->location = (yylsp[(1) - (5)]); + n->is_no_inherit = (yyvsp[(5) - (5)].boolean); + n->raw_expr = (yyvsp[(3) - (5)].node); + n->cooked_expr = NULL; + (yyval.node) = (Node *)n; + ;} + break; + + case 396: + +/* Line 1455 of yacc.c */ +#line 2716 "gram.y" + { + Constraint *n = makeNode(Constraint); + n->contype = CONSTR_DEFAULT; + n->location = (yylsp[(1) - (2)]); + n->raw_expr = (yyvsp[(2) - (2)].node); + n->cooked_expr = NULL; + (yyval.node) = (Node *)n; + ;} + break; + + case 397: + +/* Line 1455 of yacc.c */ +#line 2725 "gram.y" + { + Constraint *n = makeNode(Constraint); + n->contype = CONSTR_FOREIGN; + n->location = (yylsp[(1) - (5)]); + n->pktable = (yyvsp[(2) - (5)].range); + n->fk_attrs = NIL; + n->pk_attrs = (yyvsp[(3) - (5)].list); + n->fk_matchtype = (yyvsp[(4) - (5)].ival); + n->fk_upd_action = (char) ((yyvsp[(5) - (5)].ival) >> 8); + n->fk_del_action = (char) ((yyvsp[(5) - (5)].ival) & 0xFF); + n->skip_validation = false; + n->initially_valid = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 398: + +/* Line 1455 of yacc.c */ +#line 2758 "gram.y" + { + Constraint *n = makeNode(Constraint); + n->contype = CONSTR_ATTR_DEFERRABLE; + n->location = (yylsp[(1) - (1)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 399: + +/* Line 1455 of yacc.c */ +#line 2765 "gram.y" + { + Constraint *n = makeNode(Constraint); + n->contype = CONSTR_ATTR_NOT_DEFERRABLE; + n->location = (yylsp[(1) - (2)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 400: + +/* Line 1455 of yacc.c */ +#line 2772 "gram.y" + { + Constraint *n = makeNode(Constraint); + n->contype = CONSTR_ATTR_DEFERRED; + n->location = (yylsp[(1) - (2)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 401: + +/* Line 1455 of yacc.c */ +#line 2779 "gram.y" + { + Constraint *n = makeNode(Constraint); + n->contype = CONSTR_ATTR_IMMEDIATE; + n->location = (yylsp[(1) - (2)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 402: + +/* Line 1455 of yacc.c */ +#line 2790 "gram.y" + { + TableLikeClause *n = makeNode(TableLikeClause); + n->relation = (yyvsp[(2) - (3)].range); + n->options = (yyvsp[(3) - (3)].ival); + (yyval.node) = (Node *)n; + ;} + break; + + case 403: + +/* Line 1455 of yacc.c */ +#line 2799 "gram.y" + { (yyval.ival) = (yyvsp[(1) - (3)].ival) | (yyvsp[(3) - (3)].ival); ;} + break; + + case 404: + +/* Line 1455 of yacc.c */ +#line 2800 "gram.y" + { (yyval.ival) = (yyvsp[(1) - (3)].ival) & ~(yyvsp[(3) - (3)].ival); ;} + break; + + case 405: + +/* Line 1455 of yacc.c */ +#line 2801 "gram.y" + { (yyval.ival) = 0; ;} + break; + + case 406: + +/* Line 1455 of yacc.c */ +#line 2805 "gram.y" + { (yyval.ival) = CREATE_TABLE_LIKE_DEFAULTS; ;} + break; + + case 407: + +/* Line 1455 of yacc.c */ +#line 2806 "gram.y" + { (yyval.ival) = CREATE_TABLE_LIKE_CONSTRAINTS; ;} + break; + + case 408: + +/* Line 1455 of yacc.c */ +#line 2807 "gram.y" + { (yyval.ival) = CREATE_TABLE_LIKE_INDEXES; ;} + break; + + case 409: + +/* Line 1455 of yacc.c */ +#line 2808 "gram.y" + { (yyval.ival) = CREATE_TABLE_LIKE_STORAGE; ;} + break; + + case 410: + +/* Line 1455 of yacc.c */ +#line 2809 "gram.y" + { (yyval.ival) = CREATE_TABLE_LIKE_COMMENTS; ;} + break; + + case 411: + +/* Line 1455 of yacc.c */ +#line 2810 "gram.y" + { (yyval.ival) = CREATE_TABLE_LIKE_ALL; ;} + break; + + case 412: + +/* Line 1455 of yacc.c */ +#line 2820 "gram.y" + { + Constraint *n = (Constraint *) (yyvsp[(3) - (3)].node); + Assert(IsA(n, Constraint)); + n->conname = (yyvsp[(2) - (3)].str); + n->location = (yylsp[(1) - (3)]); + (yyval.node) = (Node *) n; + ;} + break; + + case 413: + +/* Line 1455 of yacc.c */ +#line 2827 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 414: + +/* Line 1455 of yacc.c */ +#line 2832 "gram.y" + { + Constraint *n = makeNode(Constraint); + n->contype = CONSTR_CHECK; + n->location = (yylsp[(1) - (5)]); + n->raw_expr = (yyvsp[(3) - (5)].node); + n->cooked_expr = NULL; + processCASbits((yyvsp[(5) - (5)].ival), (yylsp[(5) - (5)]), "CHECK", + NULL, NULL, &n->skip_validation, + &n->is_no_inherit, yyscanner); + n->initially_valid = !n->skip_validation; + (yyval.node) = (Node *)n; + ;} + break; + + case 415: + +/* Line 1455 of yacc.c */ +#line 2846 "gram.y" + { + Constraint *n = makeNode(Constraint); + n->contype = CONSTR_UNIQUE; + n->location = (yylsp[(1) - (7)]); + n->keys = (yyvsp[(3) - (7)].list); + n->options = (yyvsp[(5) - (7)].list); + n->indexname = NULL; + n->indexspace = (yyvsp[(6) - (7)].str); + processCASbits((yyvsp[(7) - (7)].ival), (yylsp[(7) - (7)]), "UNIQUE", + &n->deferrable, &n->initdeferred, NULL, + NULL, yyscanner); + (yyval.node) = (Node *)n; + ;} + break; + + case 416: + +/* Line 1455 of yacc.c */ +#line 2860 "gram.y" + { + Constraint *n = makeNode(Constraint); + n->contype = CONSTR_UNIQUE; + n->location = (yylsp[(1) - (3)]); + n->keys = NIL; + n->options = NIL; + n->indexname = (yyvsp[(2) - (3)].str); + n->indexspace = NULL; + processCASbits((yyvsp[(3) - (3)].ival), (yylsp[(3) - (3)]), "UNIQUE", + &n->deferrable, &n->initdeferred, NULL, + NULL, yyscanner); + (yyval.node) = (Node *)n; + ;} + break; + + case 417: + +/* Line 1455 of yacc.c */ +#line 2875 "gram.y" + { + Constraint *n = makeNode(Constraint); + n->contype = CONSTR_PRIMARY; + n->location = (yylsp[(1) - (8)]); + n->keys = (yyvsp[(4) - (8)].list); + n->options = (yyvsp[(6) - (8)].list); + n->indexname = NULL; + n->indexspace = (yyvsp[(7) - (8)].str); + processCASbits((yyvsp[(8) - (8)].ival), (yylsp[(8) - (8)]), "PRIMARY KEY", + &n->deferrable, &n->initdeferred, NULL, + NULL, yyscanner); + (yyval.node) = (Node *)n; + ;} + break; + + case 418: + +/* Line 1455 of yacc.c */ +#line 2889 "gram.y" + { + Constraint *n = makeNode(Constraint); + n->contype = CONSTR_PRIMARY; + n->location = (yylsp[(1) - (4)]); + n->keys = NIL; + n->options = NIL; + n->indexname = (yyvsp[(3) - (4)].str); + n->indexspace = NULL; + processCASbits((yyvsp[(4) - (4)].ival), (yylsp[(4) - (4)]), "PRIMARY KEY", + &n->deferrable, &n->initdeferred, NULL, + NULL, yyscanner); + (yyval.node) = (Node *)n; + ;} + break; + + case 419: + +/* Line 1455 of yacc.c */ +#line 2905 "gram.y" + { + Constraint *n = makeNode(Constraint); + n->contype = CONSTR_EXCLUSION; + n->location = (yylsp[(1) - (9)]); + n->access_method = (yyvsp[(2) - (9)].str); + n->exclusions = (yyvsp[(4) - (9)].list); + n->options = (yyvsp[(6) - (9)].list); + n->indexname = NULL; + n->indexspace = (yyvsp[(7) - (9)].str); + n->where_clause = (yyvsp[(8) - (9)].node); + processCASbits((yyvsp[(9) - (9)].ival), (yylsp[(9) - (9)]), "EXCLUDE", + &n->deferrable, &n->initdeferred, NULL, + NULL, yyscanner); + (yyval.node) = (Node *)n; + ;} + break; + + case 420: + +/* Line 1455 of yacc.c */ +#line 2922 "gram.y" + { + Constraint *n = makeNode(Constraint); + n->contype = CONSTR_FOREIGN; + n->location = (yylsp[(1) - (11)]); + n->pktable = (yyvsp[(7) - (11)].range); + n->fk_attrs = (yyvsp[(4) - (11)].list); + n->pk_attrs = (yyvsp[(8) - (11)].list); + n->fk_matchtype = (yyvsp[(9) - (11)].ival); + n->fk_upd_action = (char) ((yyvsp[(10) - (11)].ival) >> 8); + n->fk_del_action = (char) ((yyvsp[(10) - (11)].ival) & 0xFF); + processCASbits((yyvsp[(11) - (11)].ival), (yylsp[(11) - (11)]), "FOREIGN KEY", + &n->deferrable, &n->initdeferred, + &n->skip_validation, NULL, + yyscanner); + n->initially_valid = !n->skip_validation; + (yyval.node) = (Node *)n; + ;} + break; + + case 421: + +/* Line 1455 of yacc.c */ +#line 2941 "gram.y" + { (yyval.boolean) = TRUE; ;} + break; + + case 422: + +/* Line 1455 of yacc.c */ +#line 2942 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 423: + +/* Line 1455 of yacc.c */ +#line 2946 "gram.y" + { (yyval.list) = (yyvsp[(2) - (3)].list); ;} + break; + + case 424: + +/* Line 1455 of yacc.c */ +#line 2947 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 425: + +/* Line 1455 of yacc.c */ +#line 2951 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].node)); ;} + break; + + case 426: + +/* Line 1455 of yacc.c */ +#line 2952 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].node)); ;} + break; + + case 427: + +/* Line 1455 of yacc.c */ +#line 2956 "gram.y" + { + (yyval.node) = (Node *) makeString((yyvsp[(1) - (1)].str)); + ;} + break; + + case 428: + +/* Line 1455 of yacc.c */ +#line 2962 "gram.y" + { + (yyval.ival) = FKCONSTR_MATCH_FULL; + ;} + break; + + case 429: + +/* Line 1455 of yacc.c */ +#line 2966 "gram.y" + { + ereport(ERROR, + (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), + errmsg("MATCH PARTIAL not yet implemented"), + parser_errposition((yylsp[(1) - (2)])))); + (yyval.ival) = FKCONSTR_MATCH_PARTIAL; + ;} + break; + + case 430: + +/* Line 1455 of yacc.c */ +#line 2974 "gram.y" + { + (yyval.ival) = FKCONSTR_MATCH_UNSPECIFIED; + ;} + break; + + case 431: + +/* Line 1455 of yacc.c */ +#line 2978 "gram.y" + { + (yyval.ival) = FKCONSTR_MATCH_UNSPECIFIED; + ;} + break; + + case 432: + +/* Line 1455 of yacc.c */ +#line 2984 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].list)); ;} + break; + + case 433: + +/* Line 1455 of yacc.c */ +#line 2986 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].list)); ;} + break; + + case 434: + +/* Line 1455 of yacc.c */ +#line 2990 "gram.y" + { + (yyval.list) = list_make2((yyvsp[(1) - (3)].ielem), (yyvsp[(3) - (3)].list)); + ;} + break; + + case 435: + +/* Line 1455 of yacc.c */ +#line 2995 "gram.y" + { + (yyval.list) = list_make2((yyvsp[(1) - (6)].ielem), (yyvsp[(5) - (6)].list)); + ;} + break; + + case 436: + +/* Line 1455 of yacc.c */ +#line 3001 "gram.y" + { (yyval.node) = (yyvsp[(3) - (4)].node); ;} + break; + + case 437: + +/* Line 1455 of yacc.c */ +#line 3002 "gram.y" + { (yyval.node) = NULL; ;} + break; + + case 438: + +/* Line 1455 of yacc.c */ +#line 3013 "gram.y" + { (yyval.ival) = ((yyvsp[(1) - (1)].ival) << 8) | (FKCONSTR_ACTION_NOACTION & 0xFF); ;} + break; + + case 439: + +/* Line 1455 of yacc.c */ +#line 3015 "gram.y" + { (yyval.ival) = (FKCONSTR_ACTION_NOACTION << 8) | ((yyvsp[(1) - (1)].ival) & 0xFF); ;} + break; + + case 440: + +/* Line 1455 of yacc.c */ +#line 3017 "gram.y" + { (yyval.ival) = ((yyvsp[(1) - (2)].ival) << 8) | ((yyvsp[(2) - (2)].ival) & 0xFF); ;} + break; + + case 441: + +/* Line 1455 of yacc.c */ +#line 3019 "gram.y" + { (yyval.ival) = ((yyvsp[(2) - (2)].ival) << 8) | ((yyvsp[(1) - (2)].ival) & 0xFF); ;} + break; + + case 442: + +/* Line 1455 of yacc.c */ +#line 3021 "gram.y" + { (yyval.ival) = (FKCONSTR_ACTION_NOACTION << 8) | (FKCONSTR_ACTION_NOACTION & 0xFF); ;} + break; + + case 443: + +/* Line 1455 of yacc.c */ +#line 3024 "gram.y" + { (yyval.ival) = (yyvsp[(3) - (3)].ival); ;} + break; + + case 444: + +/* Line 1455 of yacc.c */ +#line 3027 "gram.y" + { (yyval.ival) = (yyvsp[(3) - (3)].ival); ;} + break; + + case 445: + +/* Line 1455 of yacc.c */ +#line 3031 "gram.y" + { (yyval.ival) = FKCONSTR_ACTION_NOACTION; ;} + break; + + case 446: + +/* Line 1455 of yacc.c */ +#line 3032 "gram.y" + { (yyval.ival) = FKCONSTR_ACTION_RESTRICT; ;} + break; + + case 447: + +/* Line 1455 of yacc.c */ +#line 3033 "gram.y" + { (yyval.ival) = FKCONSTR_ACTION_CASCADE; ;} + break; + + case 448: + +/* Line 1455 of yacc.c */ +#line 3034 "gram.y" + { (yyval.ival) = FKCONSTR_ACTION_SETNULL; ;} + break; + + case 449: + +/* Line 1455 of yacc.c */ +#line 3035 "gram.y" + { (yyval.ival) = FKCONSTR_ACTION_SETDEFAULT; ;} + break; + + case 450: + +/* Line 1455 of yacc.c */ +#line 3038 "gram.y" + { (yyval.list) = (yyvsp[(3) - (4)].list); ;} + break; + + case 451: + +/* Line 1455 of yacc.c */ +#line 3039 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 452: + +/* Line 1455 of yacc.c */ +#line 3044 "gram.y" + { (yyval.list) = (yyvsp[(2) - (2)].list); ;} + break; + + case 453: + +/* Line 1455 of yacc.c */ +#line 3045 "gram.y" + { (yyval.list) = list_make1(defWithOids(true)); ;} + break; + + case 454: + +/* Line 1455 of yacc.c */ +#line 3046 "gram.y" + { (yyval.list) = list_make1(defWithOids(false)); ;} + break; + + case 455: + +/* Line 1455 of yacc.c */ +#line 3047 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 456: + +/* Line 1455 of yacc.c */ +#line 3050 "gram.y" + { (yyval.oncommit) = ONCOMMIT_DROP; ;} + break; + + case 457: + +/* Line 1455 of yacc.c */ +#line 3051 "gram.y" + { (yyval.oncommit) = ONCOMMIT_DELETE_ROWS; ;} + break; + + case 458: + +/* Line 1455 of yacc.c */ +#line 3052 "gram.y" + { (yyval.oncommit) = ONCOMMIT_PRESERVE_ROWS; ;} + break; + + case 459: + +/* Line 1455 of yacc.c */ +#line 3053 "gram.y" + { (yyval.oncommit) = ONCOMMIT_NOOP; ;} + break; + + case 460: + +/* Line 1455 of yacc.c */ +#line 3056 "gram.y" + { (yyval.str) = (yyvsp[(2) - (2)].str); ;} + break; + + case 461: + +/* Line 1455 of yacc.c */ +#line 3057 "gram.y" + { (yyval.str) = NULL; ;} + break; + + case 462: + +/* Line 1455 of yacc.c */ +#line 3060 "gram.y" + { (yyval.str) = (yyvsp[(4) - (4)].str); ;} + break; + + case 463: + +/* Line 1455 of yacc.c */ +#line 3061 "gram.y" + { (yyval.str) = NULL; ;} + break; + + case 464: + +/* Line 1455 of yacc.c */ +#line 3064 "gram.y" + { (yyval.str) = (yyvsp[(3) - (3)].str); ;} + break; + + case 465: + +/* Line 1455 of yacc.c */ +#line 3080 "gram.y" + { + CreateTableAsStmt *ctas = makeNode(CreateTableAsStmt); + ctas->query = (yyvsp[(6) - (7)].node); + ctas->into = (yyvsp[(4) - (7)].into); + ctas->is_select_into = false; + /* cram additional flags into the IntoClause */ + (yyvsp[(4) - (7)].into)->rel->relpersistence = (yyvsp[(2) - (7)].ival); + (yyvsp[(4) - (7)].into)->skipData = !((yyvsp[(7) - (7)].boolean)); + (yyval.node) = (Node *) ctas; + ;} + break; + + case 466: + +/* Line 1455 of yacc.c */ +#line 3094 "gram.y" + { + (yyval.into) = makeNode(IntoClause); + (yyval.into)->rel = (yyvsp[(1) - (5)].range); + (yyval.into)->colNames = (yyvsp[(2) - (5)].list); + (yyval.into)->options = (yyvsp[(3) - (5)].list); + (yyval.into)->onCommit = (yyvsp[(4) - (5)].oncommit); + (yyval.into)->tableSpaceName = (yyvsp[(5) - (5)].str); + (yyval.into)->skipData = false; /* might get changed later */ + ;} + break; + + case 467: + +/* Line 1455 of yacc.c */ +#line 3106 "gram.y" + { (yyval.boolean) = TRUE; ;} + break; + + case 468: + +/* Line 1455 of yacc.c */ +#line 3107 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 469: + +/* Line 1455 of yacc.c */ +#line 3108 "gram.y" + { (yyval.boolean) = TRUE; ;} + break; + + case 470: + +/* Line 1455 of yacc.c */ +#line 3122 "gram.y" + { + CreateSeqStmt *n = makeNode(CreateSeqStmt); + (yyvsp[(4) - (5)].range)->relpersistence = (yyvsp[(2) - (5)].ival); + n->sequence = (yyvsp[(4) - (5)].range); + n->options = (yyvsp[(5) - (5)].list); + n->ownerId = InvalidOid; + (yyval.node) = (Node *)n; + ;} + break; + + case 471: + +/* Line 1455 of yacc.c */ +#line 3134 "gram.y" + { + AlterSeqStmt *n = makeNode(AlterSeqStmt); + n->sequence = (yyvsp[(3) - (4)].range); + n->options = (yyvsp[(4) - (4)].list); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 472: + +/* Line 1455 of yacc.c */ +#line 3142 "gram.y" + { + AlterSeqStmt *n = makeNode(AlterSeqStmt); + n->sequence = (yyvsp[(5) - (6)].range); + n->options = (yyvsp[(6) - (6)].list); + n->missing_ok = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 473: + +/* Line 1455 of yacc.c */ +#line 3152 "gram.y" + { (yyval.list) = (yyvsp[(1) - (1)].list); ;} + break; + + case 474: + +/* Line 1455 of yacc.c */ +#line 3153 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 475: + +/* Line 1455 of yacc.c */ +#line 3156 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].defelt)); ;} + break; + + case 476: + +/* Line 1455 of yacc.c */ +#line 3157 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (2)].list), (yyvsp[(2) - (2)].defelt)); ;} + break; + + case 477: + +/* Line 1455 of yacc.c */ +#line 3161 "gram.y" + { + (yyval.defelt) = makeDefElem("cache", (Node *)(yyvsp[(2) - (2)].value)); + ;} + break; + + case 478: + +/* Line 1455 of yacc.c */ +#line 3165 "gram.y" + { + (yyval.defelt) = makeDefElem("cycle", (Node *)makeInteger(TRUE)); + ;} + break; + + case 479: + +/* Line 1455 of yacc.c */ +#line 3169 "gram.y" + { + (yyval.defelt) = makeDefElem("cycle", (Node *)makeInteger(FALSE)); + ;} + break; + + case 480: + +/* Line 1455 of yacc.c */ +#line 3173 "gram.y" + { + (yyval.defelt) = makeDefElem("increment", (Node *)(yyvsp[(3) - (3)].value)); + ;} + break; + + case 481: + +/* Line 1455 of yacc.c */ +#line 3177 "gram.y" + { + (yyval.defelt) = makeDefElem("maxvalue", (Node *)(yyvsp[(2) - (2)].value)); + ;} + break; + + case 482: + +/* Line 1455 of yacc.c */ +#line 3181 "gram.y" + { + (yyval.defelt) = makeDefElem("minvalue", (Node *)(yyvsp[(2) - (2)].value)); + ;} + break; + + case 483: + +/* Line 1455 of yacc.c */ +#line 3185 "gram.y" + { + (yyval.defelt) = makeDefElem("maxvalue", NULL); + ;} + break; + + case 484: + +/* Line 1455 of yacc.c */ +#line 3189 "gram.y" + { + (yyval.defelt) = makeDefElem("minvalue", NULL); + ;} + break; + + case 485: + +/* Line 1455 of yacc.c */ +#line 3193 "gram.y" + { + (yyval.defelt) = makeDefElem("owned_by", (Node *)(yyvsp[(3) - (3)].list)); + ;} + break; + + case 486: + +/* Line 1455 of yacc.c */ +#line 3197 "gram.y" + { + (yyval.defelt) = makeDefElem("start", (Node *)(yyvsp[(3) - (3)].value)); + ;} + break; + + case 487: + +/* Line 1455 of yacc.c */ +#line 3201 "gram.y" + { + (yyval.defelt) = makeDefElem("restart", NULL); + ;} + break; + + case 488: + +/* Line 1455 of yacc.c */ +#line 3205 "gram.y" + { + (yyval.defelt) = makeDefElem("restart", (Node *)(yyvsp[(3) - (3)].value)); + ;} + break; + + case 489: + +/* Line 1455 of yacc.c */ +#line 3210 "gram.y" + {;} + break; + + case 490: + +/* Line 1455 of yacc.c */ +#line 3211 "gram.y" + {;} + break; + + case 491: + +/* Line 1455 of yacc.c */ +#line 3215 "gram.y" + { (yyval.value) = makeFloat((yyvsp[(1) - (1)].str)); ;} + break; + + case 492: + +/* Line 1455 of yacc.c */ +#line 3217 "gram.y" + { + (yyval.value) = makeFloat((yyvsp[(2) - (2)].str)); + doNegateFloat((yyval.value)); + ;} + break; + + case 493: + +/* Line 1455 of yacc.c */ +#line 3221 "gram.y" + { (yyval.value) = makeInteger((yyvsp[(1) - (1)].ival)); ;} + break; + + case 494: + +/* Line 1455 of yacc.c */ +#line 3224 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].value)); ;} + break; + + case 495: + +/* Line 1455 of yacc.c */ +#line 3225 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].value)); ;} + break; + + case 496: + +/* Line 1455 of yacc.c */ +#line 3238 "gram.y" + { + CreatePLangStmt *n = makeNode(CreatePLangStmt); + n->replace = (yyvsp[(2) - (6)].boolean); + n->plname = (yyvsp[(6) - (6)].str); + /* parameters are all to be supplied by system */ + n->plhandler = NIL; + n->plinline = NIL; + n->plvalidator = NIL; + n->pltrusted = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 497: + +/* Line 1455 of yacc.c */ +#line 3251 "gram.y" + { + CreatePLangStmt *n = makeNode(CreatePLangStmt); + n->replace = (yyvsp[(2) - (10)].boolean); + n->plname = (yyvsp[(6) - (10)].str); + n->plhandler = (yyvsp[(8) - (10)].list); + n->plinline = (yyvsp[(9) - (10)].list); + n->plvalidator = (yyvsp[(10) - (10)].list); + n->pltrusted = (yyvsp[(3) - (10)].boolean); + (yyval.node) = (Node *)n; + ;} + break; + + case 498: + +/* Line 1455 of yacc.c */ +#line 3264 "gram.y" + { (yyval.boolean) = TRUE; ;} + break; + + case 499: + +/* Line 1455 of yacc.c */ +#line 3265 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 500: + +/* Line 1455 of yacc.c */ +#line 3273 "gram.y" + { (yyval.list) = list_make1(makeString((yyvsp[(1) - (1)].str))); ;} + break; + + case 501: + +/* Line 1455 of yacc.c */ +#line 3274 "gram.y" + { (yyval.list) = lcons(makeString((yyvsp[(1) - (2)].str)), (yyvsp[(2) - (2)].list)); ;} + break; + + case 502: + +/* Line 1455 of yacc.c */ +#line 3278 "gram.y" + { (yyval.list) = (yyvsp[(2) - (2)].list); ;} + break; + + case 503: + +/* Line 1455 of yacc.c */ +#line 3279 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 504: + +/* Line 1455 of yacc.c */ +#line 3283 "gram.y" + { (yyval.list) = (yyvsp[(2) - (2)].list); ;} + break; + + case 505: + +/* Line 1455 of yacc.c */ +#line 3284 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 506: + +/* Line 1455 of yacc.c */ +#line 3288 "gram.y" + { (yyval.list) = (yyvsp[(1) - (1)].list); ;} + break; + + case 507: + +/* Line 1455 of yacc.c */ +#line 3289 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 508: + +/* Line 1455 of yacc.c */ +#line 3294 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->removeType = OBJECT_LANGUAGE; + n->objects = list_make1(list_make1(makeString((yyvsp[(4) - (5)].str)))); + n->arguments = NIL; + n->behavior = (yyvsp[(5) - (5)].dbehavior); + n->missing_ok = false; + n->concurrent = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 509: + +/* Line 1455 of yacc.c */ +#line 3305 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->removeType = OBJECT_LANGUAGE; + n->objects = list_make1(list_make1(makeString((yyvsp[(6) - (7)].str)))); + n->behavior = (yyvsp[(7) - (7)].dbehavior); + n->missing_ok = true; + n->concurrent = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 510: + +/* Line 1455 of yacc.c */ +#line 3317 "gram.y" + {;} + break; + + case 511: + +/* Line 1455 of yacc.c */ +#line 3318 "gram.y" + {;} + break; + + case 512: + +/* Line 1455 of yacc.c */ +#line 3329 "gram.y" + { + CreateTableSpaceStmt *n = makeNode(CreateTableSpaceStmt); + n->tablespacename = (yyvsp[(3) - (6)].str); + n->owner = (yyvsp[(4) - (6)].str); + n->location = (yyvsp[(6) - (6)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 513: + +/* Line 1455 of yacc.c */ +#line 3338 "gram.y" + { (yyval.str) = (yyvsp[(2) - (2)].str); ;} + break; + + case 514: + +/* Line 1455 of yacc.c */ +#line 3339 "gram.y" + { (yyval.str) = NULL; ;} + break; + + case 515: + +/* Line 1455 of yacc.c */ +#line 3353 "gram.y" + { + DropTableSpaceStmt *n = makeNode(DropTableSpaceStmt); + n->tablespacename = (yyvsp[(3) - (3)].str); + n->missing_ok = false; + (yyval.node) = (Node *) n; + ;} + break; + + case 516: + +/* Line 1455 of yacc.c */ +#line 3360 "gram.y" + { + DropTableSpaceStmt *n = makeNode(DropTableSpaceStmt); + n->tablespacename = (yyvsp[(5) - (5)].str); + n->missing_ok = true; + (yyval.node) = (Node *) n; + ;} + break; + + case 517: + +/* Line 1455 of yacc.c */ +#line 3377 "gram.y" + { + CreateExtensionStmt *n = makeNode(CreateExtensionStmt); + n->extname = (yyvsp[(3) - (5)].str); + n->if_not_exists = false; + n->options = (yyvsp[(5) - (5)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 518: + +/* Line 1455 of yacc.c */ +#line 3385 "gram.y" + { + CreateExtensionStmt *n = makeNode(CreateExtensionStmt); + n->extname = (yyvsp[(6) - (8)].str); + n->if_not_exists = true; + n->options = (yyvsp[(8) - (8)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 519: + +/* Line 1455 of yacc.c */ +#line 3396 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (2)].list), (yyvsp[(2) - (2)].defelt)); ;} + break; + + case 520: + +/* Line 1455 of yacc.c */ +#line 3398 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 521: + +/* Line 1455 of yacc.c */ +#line 3403 "gram.y" + { + (yyval.defelt) = makeDefElem("schema", (Node *)makeString((yyvsp[(2) - (2)].str))); + ;} + break; + + case 522: + +/* Line 1455 of yacc.c */ +#line 3407 "gram.y" + { + (yyval.defelt) = makeDefElem("new_version", (Node *)makeString((yyvsp[(2) - (2)].str))); + ;} + break; + + case 523: + +/* Line 1455 of yacc.c */ +#line 3411 "gram.y" + { + (yyval.defelt) = makeDefElem("old_version", (Node *)makeString((yyvsp[(2) - (2)].str))); + ;} + break; + + case 524: + +/* Line 1455 of yacc.c */ +#line 3423 "gram.y" + { + AlterExtensionStmt *n = makeNode(AlterExtensionStmt); + n->extname = (yyvsp[(3) - (5)].str); + n->options = (yyvsp[(5) - (5)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 525: + +/* Line 1455 of yacc.c */ +#line 3433 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (2)].list), (yyvsp[(2) - (2)].defelt)); ;} + break; + + case 526: + +/* Line 1455 of yacc.c */ +#line 3435 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 527: + +/* Line 1455 of yacc.c */ +#line 3440 "gram.y" + { + (yyval.defelt) = makeDefElem("new_version", (Node *)makeString((yyvsp[(2) - (2)].str))); + ;} + break; + + case 528: + +/* Line 1455 of yacc.c */ +#line 3453 "gram.y" + { + AlterExtensionContentsStmt *n = makeNode(AlterExtensionContentsStmt); + n->extname = (yyvsp[(3) - (7)].str); + n->action = (yyvsp[(4) - (7)].ival); + n->objtype = OBJECT_AGGREGATE; + n->objname = (yyvsp[(6) - (7)].list); + n->objargs = (yyvsp[(7) - (7)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 529: + +/* Line 1455 of yacc.c */ +#line 3463 "gram.y" + { + AlterExtensionContentsStmt *n = makeNode(AlterExtensionContentsStmt); + n->extname = (yyvsp[(3) - (10)].str); + n->action = (yyvsp[(4) - (10)].ival); + n->objtype = OBJECT_CAST; + n->objname = list_make1((yyvsp[(7) - (10)].typnam)); + n->objargs = list_make1((yyvsp[(9) - (10)].typnam)); + (yyval.node) = (Node *) n; + ;} + break; + + case 530: + +/* Line 1455 of yacc.c */ +#line 3473 "gram.y" + { + AlterExtensionContentsStmt *n = makeNode(AlterExtensionContentsStmt); + n->extname = (yyvsp[(3) - (6)].str); + n->action = (yyvsp[(4) - (6)].ival); + n->objtype = OBJECT_COLLATION; + n->objname = (yyvsp[(6) - (6)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 531: + +/* Line 1455 of yacc.c */ +#line 3482 "gram.y" + { + AlterExtensionContentsStmt *n = makeNode(AlterExtensionContentsStmt); + n->extname = (yyvsp[(3) - (6)].str); + n->action = (yyvsp[(4) - (6)].ival); + n->objtype = OBJECT_CONVERSION; + n->objname = (yyvsp[(6) - (6)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 532: + +/* Line 1455 of yacc.c */ +#line 3491 "gram.y" + { + AlterExtensionContentsStmt *n = makeNode(AlterExtensionContentsStmt); + n->extname = (yyvsp[(3) - (6)].str); + n->action = (yyvsp[(4) - (6)].ival); + n->objtype = OBJECT_DOMAIN; + n->objname = (yyvsp[(6) - (6)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 533: + +/* Line 1455 of yacc.c */ +#line 3500 "gram.y" + { + AlterExtensionContentsStmt *n = makeNode(AlterExtensionContentsStmt); + n->extname = (yyvsp[(3) - (6)].str); + n->action = (yyvsp[(4) - (6)].ival); + n->objtype = OBJECT_FUNCTION; + n->objname = (yyvsp[(6) - (6)].funwithargs)->funcname; + n->objargs = (yyvsp[(6) - (6)].funwithargs)->funcargs; + (yyval.node) = (Node *)n; + ;} + break; + + case 534: + +/* Line 1455 of yacc.c */ +#line 3510 "gram.y" + { + AlterExtensionContentsStmt *n = makeNode(AlterExtensionContentsStmt); + n->extname = (yyvsp[(3) - (7)].str); + n->action = (yyvsp[(4) - (7)].ival); + n->objtype = OBJECT_LANGUAGE; + n->objname = list_make1(makeString((yyvsp[(7) - (7)].str))); + (yyval.node) = (Node *)n; + ;} + break; + + case 535: + +/* Line 1455 of yacc.c */ +#line 3519 "gram.y" + { + AlterExtensionContentsStmt *n = makeNode(AlterExtensionContentsStmt); + n->extname = (yyvsp[(3) - (7)].str); + n->action = (yyvsp[(4) - (7)].ival); + n->objtype = OBJECT_OPERATOR; + n->objname = (yyvsp[(6) - (7)].list); + n->objargs = (yyvsp[(7) - (7)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 536: + +/* Line 1455 of yacc.c */ +#line 3529 "gram.y" + { + AlterExtensionContentsStmt *n = makeNode(AlterExtensionContentsStmt); + n->extname = (yyvsp[(3) - (9)].str); + n->action = (yyvsp[(4) - (9)].ival); + n->objtype = OBJECT_OPCLASS; + n->objname = (yyvsp[(7) - (9)].list); + n->objargs = list_make1(makeString((yyvsp[(9) - (9)].str))); + (yyval.node) = (Node *)n; + ;} + break; + + case 537: + +/* Line 1455 of yacc.c */ +#line 3539 "gram.y" + { + AlterExtensionContentsStmt *n = makeNode(AlterExtensionContentsStmt); + n->extname = (yyvsp[(3) - (9)].str); + n->action = (yyvsp[(4) - (9)].ival); + n->objtype = OBJECT_OPFAMILY; + n->objname = (yyvsp[(7) - (9)].list); + n->objargs = list_make1(makeString((yyvsp[(9) - (9)].str))); + (yyval.node) = (Node *)n; + ;} + break; + + case 538: + +/* Line 1455 of yacc.c */ +#line 3549 "gram.y" + { + AlterExtensionContentsStmt *n = makeNode(AlterExtensionContentsStmt); + n->extname = (yyvsp[(3) - (6)].str); + n->action = (yyvsp[(4) - (6)].ival); + n->objtype = OBJECT_SCHEMA; + n->objname = list_make1(makeString((yyvsp[(6) - (6)].str))); + (yyval.node) = (Node *)n; + ;} + break; + + case 539: + +/* Line 1455 of yacc.c */ +#line 3558 "gram.y" + { + AlterExtensionContentsStmt *n = makeNode(AlterExtensionContentsStmt); + n->extname = (yyvsp[(3) - (6)].str); + n->action = (yyvsp[(4) - (6)].ival); + n->objtype = OBJECT_TABLE; + n->objname = (yyvsp[(6) - (6)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 540: + +/* Line 1455 of yacc.c */ +#line 3567 "gram.y" + { + AlterExtensionContentsStmt *n = makeNode(AlterExtensionContentsStmt); + n->extname = (yyvsp[(3) - (8)].str); + n->action = (yyvsp[(4) - (8)].ival); + n->objtype = OBJECT_TSPARSER; + n->objname = (yyvsp[(8) - (8)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 541: + +/* Line 1455 of yacc.c */ +#line 3576 "gram.y" + { + AlterExtensionContentsStmt *n = makeNode(AlterExtensionContentsStmt); + n->extname = (yyvsp[(3) - (8)].str); + n->action = (yyvsp[(4) - (8)].ival); + n->objtype = OBJECT_TSDICTIONARY; + n->objname = (yyvsp[(8) - (8)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 542: + +/* Line 1455 of yacc.c */ +#line 3585 "gram.y" + { + AlterExtensionContentsStmt *n = makeNode(AlterExtensionContentsStmt); + n->extname = (yyvsp[(3) - (8)].str); + n->action = (yyvsp[(4) - (8)].ival); + n->objtype = OBJECT_TSTEMPLATE; + n->objname = (yyvsp[(8) - (8)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 543: + +/* Line 1455 of yacc.c */ +#line 3594 "gram.y" + { + AlterExtensionContentsStmt *n = makeNode(AlterExtensionContentsStmt); + n->extname = (yyvsp[(3) - (8)].str); + n->action = (yyvsp[(4) - (8)].ival); + n->objtype = OBJECT_TSCONFIGURATION; + n->objname = (yyvsp[(8) - (8)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 544: + +/* Line 1455 of yacc.c */ +#line 3603 "gram.y" + { + AlterExtensionContentsStmt *n = makeNode(AlterExtensionContentsStmt); + n->extname = (yyvsp[(3) - (6)].str); + n->action = (yyvsp[(4) - (6)].ival); + n->objtype = OBJECT_SEQUENCE; + n->objname = (yyvsp[(6) - (6)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 545: + +/* Line 1455 of yacc.c */ +#line 3612 "gram.y" + { + AlterExtensionContentsStmt *n = makeNode(AlterExtensionContentsStmt); + n->extname = (yyvsp[(3) - (6)].str); + n->action = (yyvsp[(4) - (6)].ival); + n->objtype = OBJECT_VIEW; + n->objname = (yyvsp[(6) - (6)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 546: + +/* Line 1455 of yacc.c */ +#line 3621 "gram.y" + { + AlterExtensionContentsStmt *n = makeNode(AlterExtensionContentsStmt); + n->extname = (yyvsp[(3) - (7)].str); + n->action = (yyvsp[(4) - (7)].ival); + n->objtype = OBJECT_FOREIGN_TABLE; + n->objname = (yyvsp[(7) - (7)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 547: + +/* Line 1455 of yacc.c */ +#line 3630 "gram.y" + { + AlterExtensionContentsStmt *n = makeNode(AlterExtensionContentsStmt); + n->extname = (yyvsp[(3) - (8)].str); + n->action = (yyvsp[(4) - (8)].ival); + n->objtype = OBJECT_FDW; + n->objname = list_make1(makeString((yyvsp[(8) - (8)].str))); + (yyval.node) = (Node *)n; + ;} + break; + + case 548: + +/* Line 1455 of yacc.c */ +#line 3639 "gram.y" + { + AlterExtensionContentsStmt *n = makeNode(AlterExtensionContentsStmt); + n->extname = (yyvsp[(3) - (6)].str); + n->action = (yyvsp[(4) - (6)].ival); + n->objtype = OBJECT_FOREIGN_SERVER; + n->objname = list_make1(makeString((yyvsp[(6) - (6)].str))); + (yyval.node) = (Node *)n; + ;} + break; + + case 549: + +/* Line 1455 of yacc.c */ +#line 3648 "gram.y" + { + AlterExtensionContentsStmt *n = makeNode(AlterExtensionContentsStmt); + n->extname = (yyvsp[(3) - (6)].str); + n->action = (yyvsp[(4) - (6)].ival); + n->objtype = OBJECT_TYPE; + n->objname = (yyvsp[(6) - (6)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 550: + +/* Line 1455 of yacc.c */ +#line 3666 "gram.y" + { + CreateFdwStmt *n = makeNode(CreateFdwStmt); + n->fdwname = (yyvsp[(5) - (7)].str); + n->func_options = (yyvsp[(6) - (7)].list); + n->options = (yyvsp[(7) - (7)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 551: + +/* Line 1455 of yacc.c */ +#line 3676 "gram.y" + { (yyval.defelt) = makeDefElem("handler", (Node *)(yyvsp[(2) - (2)].list)); ;} + break; + + case 552: + +/* Line 1455 of yacc.c */ +#line 3677 "gram.y" + { (yyval.defelt) = makeDefElem("handler", NULL); ;} + break; + + case 553: + +/* Line 1455 of yacc.c */ +#line 3678 "gram.y" + { (yyval.defelt) = makeDefElem("validator", (Node *)(yyvsp[(2) - (2)].list)); ;} + break; + + case 554: + +/* Line 1455 of yacc.c */ +#line 3679 "gram.y" + { (yyval.defelt) = makeDefElem("validator", NULL); ;} + break; + + case 555: + +/* Line 1455 of yacc.c */ +#line 3683 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].defelt)); ;} + break; + + case 556: + +/* Line 1455 of yacc.c */ +#line 3684 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (2)].list), (yyvsp[(2) - (2)].defelt)); ;} + break; + + case 557: + +/* Line 1455 of yacc.c */ +#line 3688 "gram.y" + { (yyval.list) = (yyvsp[(1) - (1)].list); ;} + break; + + case 558: + +/* Line 1455 of yacc.c */ +#line 3689 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 559: + +/* Line 1455 of yacc.c */ +#line 3700 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->removeType = OBJECT_FDW; + n->objects = list_make1(list_make1(makeString((yyvsp[(5) - (6)].str)))); + n->arguments = NIL; + n->missing_ok = false; + n->behavior = (yyvsp[(6) - (6)].dbehavior); + n->concurrent = false; + (yyval.node) = (Node *) n; + ;} + break; + + case 560: + +/* Line 1455 of yacc.c */ +#line 3711 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->removeType = OBJECT_FDW; + n->objects = list_make1(list_make1(makeString((yyvsp[(7) - (8)].str)))); + n->arguments = NIL; + n->missing_ok = true; + n->behavior = (yyvsp[(8) - (8)].dbehavior); + n->concurrent = false; + (yyval.node) = (Node *) n; + ;} + break; + + case 561: + +/* Line 1455 of yacc.c */ +#line 3731 "gram.y" + { + AlterFdwStmt *n = makeNode(AlterFdwStmt); + n->fdwname = (yyvsp[(5) - (7)].str); + n->func_options = (yyvsp[(6) - (7)].list); + n->options = (yyvsp[(7) - (7)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 562: + +/* Line 1455 of yacc.c */ +#line 3739 "gram.y" + { + AlterFdwStmt *n = makeNode(AlterFdwStmt); + n->fdwname = (yyvsp[(5) - (6)].str); + n->func_options = (yyvsp[(6) - (6)].list); + n->options = NIL; + (yyval.node) = (Node *) n; + ;} + break; + + case 563: + +/* Line 1455 of yacc.c */ +#line 3750 "gram.y" + { (yyval.list) = (yyvsp[(3) - (4)].list); ;} + break; + + case 564: + +/* Line 1455 of yacc.c */ +#line 3751 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 565: + +/* Line 1455 of yacc.c */ +#line 3756 "gram.y" + { + (yyval.list) = list_make1((yyvsp[(1) - (1)].defelt)); + ;} + break; + + case 566: + +/* Line 1455 of yacc.c */ +#line 3760 "gram.y" + { + (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].defelt)); + ;} + break; + + case 567: + +/* Line 1455 of yacc.c */ +#line 3767 "gram.y" + { (yyval.list) = (yyvsp[(3) - (4)].list); ;} + break; + + case 568: + +/* Line 1455 of yacc.c */ +#line 3772 "gram.y" + { + (yyval.list) = list_make1((yyvsp[(1) - (1)].defelt)); + ;} + break; + + case 569: + +/* Line 1455 of yacc.c */ +#line 3776 "gram.y" + { + (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].defelt)); + ;} + break; + + case 570: + +/* Line 1455 of yacc.c */ +#line 3783 "gram.y" + { + (yyval.defelt) = (yyvsp[(1) - (1)].defelt); + ;} + break; + + case 571: + +/* Line 1455 of yacc.c */ +#line 3787 "gram.y" + { + (yyval.defelt) = (yyvsp[(2) - (2)].defelt); + (yyval.defelt)->defaction = DEFELEM_SET; + ;} + break; + + case 572: + +/* Line 1455 of yacc.c */ +#line 3792 "gram.y" + { + (yyval.defelt) = (yyvsp[(2) - (2)].defelt); + (yyval.defelt)->defaction = DEFELEM_ADD; + ;} + break; + + case 573: + +/* Line 1455 of yacc.c */ +#line 3797 "gram.y" + { + (yyval.defelt) = makeDefElemExtended(NULL, (yyvsp[(2) - (2)].str), NULL, DEFELEM_DROP); + ;} + break; + + case 574: + +/* Line 1455 of yacc.c */ +#line 3804 "gram.y" + { + (yyval.defelt) = makeDefElem((yyvsp[(1) - (2)].str), (yyvsp[(2) - (2)].node)); + ;} + break; + + case 575: + +/* Line 1455 of yacc.c */ +#line 3810 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 576: + +/* Line 1455 of yacc.c */ +#line 3815 "gram.y" + { (yyval.node) = (Node *) makeString((yyvsp[(1) - (1)].str)); ;} + break; + + case 577: + +/* Line 1455 of yacc.c */ +#line 3827 "gram.y" + { + CreateForeignServerStmt *n = makeNode(CreateForeignServerStmt); + n->servername = (yyvsp[(3) - (10)].str); + n->servertype = (yyvsp[(4) - (10)].str); + n->version = (yyvsp[(5) - (10)].str); + n->fdwname = (yyvsp[(9) - (10)].str); + n->options = (yyvsp[(10) - (10)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 578: + +/* Line 1455 of yacc.c */ +#line 3839 "gram.y" + { (yyval.str) = (yyvsp[(2) - (2)].str); ;} + break; + + case 579: + +/* Line 1455 of yacc.c */ +#line 3840 "gram.y" + { (yyval.str) = NULL; ;} + break; + + case 580: + +/* Line 1455 of yacc.c */ +#line 3845 "gram.y" + { (yyval.str) = (yyvsp[(2) - (2)].str); ;} + break; + + case 581: + +/* Line 1455 of yacc.c */ +#line 3846 "gram.y" + { (yyval.str) = NULL; ;} + break; + + case 582: + +/* Line 1455 of yacc.c */ +#line 3850 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 583: + +/* Line 1455 of yacc.c */ +#line 3851 "gram.y" + { (yyval.str) = NULL; ;} + break; + + case 584: + +/* Line 1455 of yacc.c */ +#line 3862 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->removeType = OBJECT_FOREIGN_SERVER; + n->objects = list_make1(list_make1(makeString((yyvsp[(3) - (4)].str)))); + n->arguments = NIL; + n->missing_ok = false; + n->behavior = (yyvsp[(4) - (4)].dbehavior); + n->concurrent = false; + (yyval.node) = (Node *) n; + ;} + break; + + case 585: + +/* Line 1455 of yacc.c */ +#line 3873 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->removeType = OBJECT_FOREIGN_SERVER; + n->objects = list_make1(list_make1(makeString((yyvsp[(5) - (6)].str)))); + n->arguments = NIL; + n->missing_ok = true; + n->behavior = (yyvsp[(6) - (6)].dbehavior); + n->concurrent = false; + (yyval.node) = (Node *) n; + ;} + break; + + case 586: + +/* Line 1455 of yacc.c */ +#line 3893 "gram.y" + { + AlterForeignServerStmt *n = makeNode(AlterForeignServerStmt); + n->servername = (yyvsp[(3) - (5)].str); + n->version = (yyvsp[(4) - (5)].str); + n->options = (yyvsp[(5) - (5)].list); + n->has_version = true; + (yyval.node) = (Node *) n; + ;} + break; + + case 587: + +/* Line 1455 of yacc.c */ +#line 3902 "gram.y" + { + AlterForeignServerStmt *n = makeNode(AlterForeignServerStmt); + n->servername = (yyvsp[(3) - (4)].str); + n->version = (yyvsp[(4) - (4)].str); + n->has_version = true; + (yyval.node) = (Node *) n; + ;} + break; + + case 588: + +/* Line 1455 of yacc.c */ +#line 3910 "gram.y" + { + AlterForeignServerStmt *n = makeNode(AlterForeignServerStmt); + n->servername = (yyvsp[(3) - (4)].str); + n->options = (yyvsp[(4) - (4)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 589: + +/* Line 1455 of yacc.c */ +#line 3929 "gram.y" + { + CreateForeignTableStmt *n = makeNode(CreateForeignTableStmt); + (yyvsp[(4) - (8)].range)->relpersistence = RELPERSISTENCE_PERMANENT; + n->base.relation = (yyvsp[(4) - (8)].range); + n->base.tableElts = (yyvsp[(5) - (8)].list); + n->base.inhRelations = NIL; + n->base.if_not_exists = false; + /* FDW-specific data */ + n->servername = (yyvsp[(7) - (8)].str); + n->options = (yyvsp[(8) - (8)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 590: + +/* Line 1455 of yacc.c */ +#line 3944 "gram.y" + { + CreateForeignTableStmt *n = makeNode(CreateForeignTableStmt); + (yyvsp[(7) - (11)].range)->relpersistence = RELPERSISTENCE_PERMANENT; + n->base.relation = (yyvsp[(7) - (11)].range); + n->base.tableElts = (yyvsp[(8) - (11)].list); + n->base.inhRelations = NIL; + n->base.if_not_exists = true; + /* FDW-specific data */ + n->servername = (yyvsp[(10) - (11)].str); + n->options = (yyvsp[(11) - (11)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 591: + +/* Line 1455 of yacc.c */ +#line 3959 "gram.y" + { (yyval.list) = (yyvsp[(2) - (3)].list); ;} + break; + + case 592: + +/* Line 1455 of yacc.c */ +#line 3960 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 593: + +/* Line 1455 of yacc.c */ +#line 3965 "gram.y" + { + (yyval.list) = list_make1((yyvsp[(1) - (1)].node)); + ;} + break; + + case 594: + +/* Line 1455 of yacc.c */ +#line 3969 "gram.y" + { + (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].node)); + ;} + break; + + case 595: + +/* Line 1455 of yacc.c */ +#line 3975 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 596: + +/* Line 1455 of yacc.c */ +#line 3987 "gram.y" + { + AlterTableStmt *n = makeNode(AlterTableStmt); + n->relation = (yyvsp[(4) - (5)].range); + n->cmds = (yyvsp[(5) - (5)].list); + n->relkind = OBJECT_FOREIGN_TABLE; + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 597: + +/* Line 1455 of yacc.c */ +#line 3996 "gram.y" + { + AlterTableStmt *n = makeNode(AlterTableStmt); + n->relation = (yyvsp[(6) - (7)].range); + n->cmds = (yyvsp[(7) - (7)].list); + n->relkind = OBJECT_FOREIGN_TABLE; + n->missing_ok = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 598: + +/* Line 1455 of yacc.c */ +#line 4014 "gram.y" + { + CreateUserMappingStmt *n = makeNode(CreateUserMappingStmt); + n->username = (yyvsp[(5) - (8)].str); + n->servername = (yyvsp[(7) - (8)].str); + n->options = (yyvsp[(8) - (8)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 599: + +/* Line 1455 of yacc.c */ +#line 4025 "gram.y" + { (yyval.str) = "current_user"; ;} + break; + + case 600: + +/* Line 1455 of yacc.c */ +#line 4026 "gram.y" + { (yyval.str) = "current_user"; ;} + break; + + case 601: + +/* Line 1455 of yacc.c */ +#line 4027 "gram.y" + { (yyval.str) = (strcmp((yyvsp[(1) - (1)].str), "public") == 0) ? NULL : (yyvsp[(1) - (1)].str); ;} + break; + + case 602: + +/* Line 1455 of yacc.c */ +#line 4038 "gram.y" + { + DropUserMappingStmt *n = makeNode(DropUserMappingStmt); + n->username = (yyvsp[(5) - (7)].str); + n->servername = (yyvsp[(7) - (7)].str); + n->missing_ok = false; + (yyval.node) = (Node *) n; + ;} + break; + + case 603: + +/* Line 1455 of yacc.c */ +#line 4046 "gram.y" + { + DropUserMappingStmt *n = makeNode(DropUserMappingStmt); + n->username = (yyvsp[(7) - (9)].str); + n->servername = (yyvsp[(9) - (9)].str); + n->missing_ok = true; + (yyval.node) = (Node *) n; + ;} + break; + + case 604: + +/* Line 1455 of yacc.c */ +#line 4063 "gram.y" + { + AlterUserMappingStmt *n = makeNode(AlterUserMappingStmt); + n->username = (yyvsp[(5) - (8)].str); + n->servername = (yyvsp[(7) - (8)].str); + n->options = (yyvsp[(8) - (8)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 605: + +/* Line 1455 of yacc.c */ +#line 4084 "gram.y" + { + CreateTrigStmt *n = makeNode(CreateTrigStmt); + n->trigname = (yyvsp[(3) - (15)].str); + n->relation = (yyvsp[(7) - (15)].range); + n->funcname = (yyvsp[(12) - (15)].list); + n->args = (yyvsp[(14) - (15)].list); + n->row = (yyvsp[(8) - (15)].boolean); + n->timing = (yyvsp[(4) - (15)].ival); + n->events = intVal(linitial((yyvsp[(5) - (15)].list))); + n->columns = (List *) lsecond((yyvsp[(5) - (15)].list)); + n->whenClause = (yyvsp[(9) - (15)].node); + n->isconstraint = FALSE; + n->deferrable = FALSE; + n->initdeferred = FALSE; + n->constrrel = NULL; + (yyval.node) = (Node *)n; + ;} + break; + + case 606: + +/* Line 1455 of yacc.c */ +#line 4105 "gram.y" + { + CreateTrigStmt *n = makeNode(CreateTrigStmt); + n->trigname = (yyvsp[(4) - (20)].str); + n->relation = (yyvsp[(8) - (20)].range); + n->funcname = (yyvsp[(17) - (20)].list); + n->args = (yyvsp[(19) - (20)].list); + n->row = TRUE; + n->timing = TRIGGER_TYPE_AFTER; + n->events = intVal(linitial((yyvsp[(6) - (20)].list))); + n->columns = (List *) lsecond((yyvsp[(6) - (20)].list)); + n->whenClause = (yyvsp[(14) - (20)].node); + n->isconstraint = TRUE; + processCASbits((yyvsp[(10) - (20)].ival), (yylsp[(10) - (20)]), "TRIGGER", + &n->deferrable, &n->initdeferred, NULL, + NULL, yyscanner); + n->constrrel = (yyvsp[(9) - (20)].range); + (yyval.node) = (Node *)n; + ;} + break; + + case 607: + +/* Line 1455 of yacc.c */ +#line 4126 "gram.y" + { (yyval.ival) = TRIGGER_TYPE_BEFORE; ;} + break; + + case 608: + +/* Line 1455 of yacc.c */ +#line 4127 "gram.y" + { (yyval.ival) = TRIGGER_TYPE_AFTER; ;} + break; + + case 609: + +/* Line 1455 of yacc.c */ +#line 4128 "gram.y" + { (yyval.ival) = TRIGGER_TYPE_INSTEAD; ;} + break; + + case 610: + +/* Line 1455 of yacc.c */ +#line 4133 "gram.y" + { (yyval.list) = (yyvsp[(1) - (1)].list); ;} + break; + + case 611: + +/* Line 1455 of yacc.c */ +#line 4135 "gram.y" + { + int events1 = intVal(linitial((yyvsp[(1) - (3)].list))); + int events2 = intVal(linitial((yyvsp[(3) - (3)].list))); + List *columns1 = (List *) lsecond((yyvsp[(1) - (3)].list)); + List *columns2 = (List *) lsecond((yyvsp[(3) - (3)].list)); + + if (events1 & events2) + parser_yyerror("duplicate trigger events specified"); + /* + * concat'ing the columns lists loses information about + * which columns went with which event, but so long as + * only UPDATE carries columns and we disallow multiple + * UPDATE items, it doesn't matter. Command execution + * should just ignore the columns for non-UPDATE events. + */ + (yyval.list) = list_make2(makeInteger(events1 | events2), + list_concat(columns1, columns2)); + ;} + break; + + case 612: + +/* Line 1455 of yacc.c */ +#line 4157 "gram.y" + { (yyval.list) = list_make2(makeInteger(TRIGGER_TYPE_INSERT), NIL); ;} + break; + + case 613: + +/* Line 1455 of yacc.c */ +#line 4159 "gram.y" + { (yyval.list) = list_make2(makeInteger(TRIGGER_TYPE_DELETE), NIL); ;} + break; + + case 614: + +/* Line 1455 of yacc.c */ +#line 4161 "gram.y" + { (yyval.list) = list_make2(makeInteger(TRIGGER_TYPE_UPDATE), NIL); ;} + break; + + case 615: + +/* Line 1455 of yacc.c */ +#line 4163 "gram.y" + { (yyval.list) = list_make2(makeInteger(TRIGGER_TYPE_UPDATE), (yyvsp[(3) - (3)].list)); ;} + break; + + case 616: + +/* Line 1455 of yacc.c */ +#line 4165 "gram.y" + { (yyval.list) = list_make2(makeInteger(TRIGGER_TYPE_TRUNCATE), NIL); ;} + break; + + case 617: + +/* Line 1455 of yacc.c */ +#line 4170 "gram.y" + { + (yyval.boolean) = (yyvsp[(3) - (3)].boolean); + ;} + break; + + case 618: + +/* Line 1455 of yacc.c */ +#line 4174 "gram.y" + { + /* + * If ROW/STATEMENT not specified, default to + * STATEMENT, per SQL + */ + (yyval.boolean) = FALSE; + ;} + break; + + case 619: + +/* Line 1455 of yacc.c */ +#line 4184 "gram.y" + {;} + break; + + case 620: + +/* Line 1455 of yacc.c */ +#line 4185 "gram.y" + {;} + break; + + case 621: + +/* Line 1455 of yacc.c */ +#line 4189 "gram.y" + { (yyval.boolean) = TRUE; ;} + break; + + case 622: + +/* Line 1455 of yacc.c */ +#line 4190 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 623: + +/* Line 1455 of yacc.c */ +#line 4194 "gram.y" + { (yyval.node) = (yyvsp[(3) - (4)].node); ;} + break; + + case 624: + +/* Line 1455 of yacc.c */ +#line 4195 "gram.y" + { (yyval.node) = NULL; ;} + break; + + case 625: + +/* Line 1455 of yacc.c */ +#line 4199 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].value)); ;} + break; + + case 626: + +/* Line 1455 of yacc.c */ +#line 4200 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].value)); ;} + break; + + case 627: + +/* Line 1455 of yacc.c */ +#line 4201 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 628: + +/* Line 1455 of yacc.c */ +#line 4206 "gram.y" + { + char buf[64]; + snprintf(buf, sizeof(buf), "%d", (yyvsp[(1) - (1)].ival)); + (yyval.value) = makeString(pstrdup(buf)); + ;} + break; + + case 629: + +/* Line 1455 of yacc.c */ +#line 4211 "gram.y" + { (yyval.value) = makeString((yyvsp[(1) - (1)].str)); ;} + break; + + case 630: + +/* Line 1455 of yacc.c */ +#line 4212 "gram.y" + { (yyval.value) = makeString((yyvsp[(1) - (1)].str)); ;} + break; + + case 631: + +/* Line 1455 of yacc.c */ +#line 4213 "gram.y" + { (yyval.value) = makeString((yyvsp[(1) - (1)].str)); ;} + break; + + case 632: + +/* Line 1455 of yacc.c */ +#line 4217 "gram.y" + { (yyval.range) = (yyvsp[(2) - (2)].range); ;} + break; + + case 633: + +/* Line 1455 of yacc.c */ +#line 4218 "gram.y" + { (yyval.range) = NULL; ;} + break; + + case 634: + +/* Line 1455 of yacc.c */ +#line 4223 "gram.y" + { (yyval.ival) = 0; ;} + break; + + case 635: + +/* Line 1455 of yacc.c */ +#line 4225 "gram.y" + { + /* + * We must complain about conflicting options. + * We could, but choose not to, complain about redundant + * options (ie, where $2's bit is already set in $1). + */ + int newspec = (yyvsp[(1) - (2)].ival) | (yyvsp[(2) - (2)].ival); + + /* special message for this case */ + if ((newspec & (CAS_NOT_DEFERRABLE | CAS_INITIALLY_DEFERRED)) == (CAS_NOT_DEFERRABLE | CAS_INITIALLY_DEFERRED)) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("constraint declared INITIALLY DEFERRED must be DEFERRABLE"), + parser_errposition((yylsp[(2) - (2)])))); + /* generic message for other conflicts */ + if ((newspec & (CAS_NOT_DEFERRABLE | CAS_DEFERRABLE)) == (CAS_NOT_DEFERRABLE | CAS_DEFERRABLE) || + (newspec & (CAS_INITIALLY_IMMEDIATE | CAS_INITIALLY_DEFERRED)) == (CAS_INITIALLY_IMMEDIATE | CAS_INITIALLY_DEFERRED)) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("conflicting constraint properties"), + parser_errposition((yylsp[(2) - (2)])))); + (yyval.ival) = newspec; + ;} + break; + + case 636: + +/* Line 1455 of yacc.c */ +#line 4251 "gram.y" + { (yyval.ival) = CAS_NOT_DEFERRABLE; ;} + break; + + case 637: + +/* Line 1455 of yacc.c */ +#line 4252 "gram.y" + { (yyval.ival) = CAS_DEFERRABLE; ;} + break; + + case 638: + +/* Line 1455 of yacc.c */ +#line 4253 "gram.y" + { (yyval.ival) = CAS_INITIALLY_IMMEDIATE; ;} + break; + + case 639: + +/* Line 1455 of yacc.c */ +#line 4254 "gram.y" + { (yyval.ival) = CAS_INITIALLY_DEFERRED; ;} + break; + + case 640: + +/* Line 1455 of yacc.c */ +#line 4255 "gram.y" + { (yyval.ival) = CAS_NOT_VALID; ;} + break; + + case 641: + +/* Line 1455 of yacc.c */ +#line 4256 "gram.y" + { (yyval.ival) = CAS_NO_INHERIT; ;} + break; + + case 642: + +/* Line 1455 of yacc.c */ +#line 4262 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->removeType = OBJECT_TRIGGER; + n->objects = list_make1(lappend((yyvsp[(5) - (6)].list), makeString((yyvsp[(3) - (6)].str)))); + n->arguments = NIL; + n->behavior = (yyvsp[(6) - (6)].dbehavior); + n->missing_ok = false; + n->concurrent = false; + (yyval.node) = (Node *) n; + ;} + break; + + case 643: + +/* Line 1455 of yacc.c */ +#line 4273 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->removeType = OBJECT_TRIGGER; + n->objects = list_make1(lappend((yyvsp[(7) - (8)].list), makeString((yyvsp[(5) - (8)].str)))); + n->arguments = NIL; + n->behavior = (yyvsp[(8) - (8)].dbehavior); + n->missing_ok = true; + n->concurrent = false; + (yyval.node) = (Node *) n; + ;} + break; + + case 644: + +/* Line 1455 of yacc.c */ +#line 4297 "gram.y" + { + CreateTrigStmt *n = makeNode(CreateTrigStmt); + n->trigname = (yyvsp[(3) - (8)].str); + n->args = list_make1((yyvsp[(6) - (8)].node)); + n->isconstraint = TRUE; + processCASbits((yyvsp[(8) - (8)].ival), (yylsp[(8) - (8)]), "ASSERTION", + &n->deferrable, &n->initdeferred, NULL, + NULL, yyscanner); + + ereport(ERROR, + (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), + errmsg("CREATE ASSERTION is not yet implemented"))); + + (yyval.node) = (Node *)n; + ;} + break; + + case 645: + +/* Line 1455 of yacc.c */ +#line 4316 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->objects = NIL; + n->arguments = NIL; + n->behavior = (yyvsp[(4) - (4)].dbehavior); + n->removeType = OBJECT_TRIGGER; /* XXX */ + ereport(ERROR, + (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), + errmsg("DROP ASSERTION is not yet implemented"))); + (yyval.node) = (Node *) n; + ;} + break; + + case 646: + +/* Line 1455 of yacc.c */ +#line 4339 "gram.y" + { + DefineStmt *n = makeNode(DefineStmt); + n->kind = OBJECT_AGGREGATE; + n->oldstyle = false; + n->defnames = (yyvsp[(3) - (5)].list); + n->args = (yyvsp[(4) - (5)].list); + n->definition = (yyvsp[(5) - (5)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 647: + +/* Line 1455 of yacc.c */ +#line 4349 "gram.y" + { + /* old-style (pre-8.2) syntax for CREATE AGGREGATE */ + DefineStmt *n = makeNode(DefineStmt); + n->kind = OBJECT_AGGREGATE; + n->oldstyle = true; + n->defnames = (yyvsp[(3) - (4)].list); + n->args = NIL; + n->definition = (yyvsp[(4) - (4)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 648: + +/* Line 1455 of yacc.c */ +#line 4360 "gram.y" + { + DefineStmt *n = makeNode(DefineStmt); + n->kind = OBJECT_OPERATOR; + n->oldstyle = false; + n->defnames = (yyvsp[(3) - (4)].list); + n->args = NIL; + n->definition = (yyvsp[(4) - (4)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 649: + +/* Line 1455 of yacc.c */ +#line 4370 "gram.y" + { + DefineStmt *n = makeNode(DefineStmt); + n->kind = OBJECT_TYPE; + n->oldstyle = false; + n->defnames = (yyvsp[(3) - (4)].list); + n->args = NIL; + n->definition = (yyvsp[(4) - (4)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 650: + +/* Line 1455 of yacc.c */ +#line 4380 "gram.y" + { + /* Shell type (identified by lack of definition) */ + DefineStmt *n = makeNode(DefineStmt); + n->kind = OBJECT_TYPE; + n->oldstyle = false; + n->defnames = (yyvsp[(3) - (3)].list); + n->args = NIL; + n->definition = NIL; + (yyval.node) = (Node *)n; + ;} + break; + + case 651: + +/* Line 1455 of yacc.c */ +#line 4391 "gram.y" + { + CompositeTypeStmt *n = makeNode(CompositeTypeStmt); + + /* can't use qualified_name, sigh */ + n->typevar = makeRangeVarFromAnyName((yyvsp[(3) - (7)].list), (yylsp[(3) - (7)]), yyscanner); + n->coldeflist = (yyvsp[(6) - (7)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 652: + +/* Line 1455 of yacc.c */ +#line 4400 "gram.y" + { + CreateEnumStmt *n = makeNode(CreateEnumStmt); + n->typeName = (yyvsp[(3) - (8)].list); + n->vals = (yyvsp[(7) - (8)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 653: + +/* Line 1455 of yacc.c */ +#line 4407 "gram.y" + { + CreateRangeStmt *n = makeNode(CreateRangeStmt); + n->typeName = (yyvsp[(3) - (6)].list); + n->params = (yyvsp[(6) - (6)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 654: + +/* Line 1455 of yacc.c */ +#line 4414 "gram.y" + { + DefineStmt *n = makeNode(DefineStmt); + n->kind = OBJECT_TSPARSER; + n->args = NIL; + n->defnames = (yyvsp[(5) - (6)].list); + n->definition = (yyvsp[(6) - (6)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 655: + +/* Line 1455 of yacc.c */ +#line 4423 "gram.y" + { + DefineStmt *n = makeNode(DefineStmt); + n->kind = OBJECT_TSDICTIONARY; + n->args = NIL; + n->defnames = (yyvsp[(5) - (6)].list); + n->definition = (yyvsp[(6) - (6)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 656: + +/* Line 1455 of yacc.c */ +#line 4432 "gram.y" + { + DefineStmt *n = makeNode(DefineStmt); + n->kind = OBJECT_TSTEMPLATE; + n->args = NIL; + n->defnames = (yyvsp[(5) - (6)].list); + n->definition = (yyvsp[(6) - (6)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 657: + +/* Line 1455 of yacc.c */ +#line 4441 "gram.y" + { + DefineStmt *n = makeNode(DefineStmt); + n->kind = OBJECT_TSCONFIGURATION; + n->args = NIL; + n->defnames = (yyvsp[(5) - (6)].list); + n->definition = (yyvsp[(6) - (6)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 658: + +/* Line 1455 of yacc.c */ +#line 4450 "gram.y" + { + DefineStmt *n = makeNode(DefineStmt); + n->kind = OBJECT_COLLATION; + n->args = NIL; + n->defnames = (yyvsp[(3) - (4)].list); + n->definition = (yyvsp[(4) - (4)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 659: + +/* Line 1455 of yacc.c */ +#line 4459 "gram.y" + { + DefineStmt *n = makeNode(DefineStmt); + n->kind = OBJECT_COLLATION; + n->args = NIL; + n->defnames = (yyvsp[(3) - (5)].list); + n->definition = list_make1(makeDefElem("from", (Node *) (yyvsp[(5) - (5)].list))); + (yyval.node) = (Node *)n; + ;} + break; + + case 660: + +/* Line 1455 of yacc.c */ +#line 4469 "gram.y" + { (yyval.list) = (yyvsp[(2) - (3)].list); ;} + break; + + case 661: + +/* Line 1455 of yacc.c */ +#line 4472 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].defelt)); ;} + break; + + case 662: + +/* Line 1455 of yacc.c */ +#line 4473 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].defelt)); ;} + break; + + case 663: + +/* Line 1455 of yacc.c */ +#line 4477 "gram.y" + { + (yyval.defelt) = makeDefElem((yyvsp[(1) - (3)].str), (Node *) (yyvsp[(3) - (3)].node)); + ;} + break; + + case 664: + +/* Line 1455 of yacc.c */ +#line 4481 "gram.y" + { + (yyval.defelt) = makeDefElem((yyvsp[(1) - (1)].str), NULL); + ;} + break; + + case 665: + +/* Line 1455 of yacc.c */ +#line 4487 "gram.y" + { (yyval.node) = (Node *)(yyvsp[(1) - (1)].typnam); ;} + break; + + case 666: + +/* Line 1455 of yacc.c */ +#line 4488 "gram.y" + { (yyval.node) = (Node *)makeString(pstrdup((yyvsp[(1) - (1)].keyword))); ;} + break; + + case 667: + +/* Line 1455 of yacc.c */ +#line 4489 "gram.y" + { (yyval.node) = (Node *)(yyvsp[(1) - (1)].list); ;} + break; + + case 668: + +/* Line 1455 of yacc.c */ +#line 4490 "gram.y" + { (yyval.node) = (Node *)(yyvsp[(1) - (1)].value); ;} + break; + + case 669: + +/* Line 1455 of yacc.c */ +#line 4491 "gram.y" + { (yyval.node) = (Node *)makeString((yyvsp[(1) - (1)].str)); ;} + break; + + case 670: + +/* Line 1455 of yacc.c */ +#line 4494 "gram.y" + { (yyval.list) = (yyvsp[(2) - (3)].list); ;} + break; + + case 671: + +/* Line 1455 of yacc.c */ +#line 4495 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 672: + +/* Line 1455 of yacc.c */ +#line 4498 "gram.y" + { (yyval.list) = (yyvsp[(2) - (3)].list); ;} + break; + + case 673: + +/* Line 1455 of yacc.c */ +#line 4501 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].defelt)); ;} + break; + + case 674: + +/* Line 1455 of yacc.c */ +#line 4502 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].defelt)); ;} + break; + + case 675: + +/* Line 1455 of yacc.c */ +#line 4511 "gram.y" + { + (yyval.defelt) = makeDefElem((yyvsp[(1) - (3)].str), (Node *)(yyvsp[(3) - (3)].node)); + ;} + break; + + case 676: + +/* Line 1455 of yacc.c */ +#line 4517 "gram.y" + { (yyval.list) = (yyvsp[(1) - (1)].list); ;} + break; + + case 677: + +/* Line 1455 of yacc.c */ +#line 4518 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 678: + +/* Line 1455 of yacc.c */ +#line 4522 "gram.y" + { (yyval.list) = list_make1(makeString((yyvsp[(1) - (1)].str))); ;} + break; + + case 679: + +/* Line 1455 of yacc.c */ +#line 4524 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), makeString((yyvsp[(3) - (3)].str))); ;} + break; + + case 680: + +/* Line 1455 of yacc.c */ +#line 4535 "gram.y" + { + AlterEnumStmt *n = makeNode(AlterEnumStmt); + n->typeName = (yyvsp[(3) - (6)].list); + n->newVal = (yyvsp[(6) - (6)].str); + n->newValNeighbor = NULL; + n->newValIsAfter = true; + (yyval.node) = (Node *) n; + ;} + break; + + case 681: + +/* Line 1455 of yacc.c */ +#line 4544 "gram.y" + { + AlterEnumStmt *n = makeNode(AlterEnumStmt); + n->typeName = (yyvsp[(3) - (8)].list); + n->newVal = (yyvsp[(6) - (8)].str); + n->newValNeighbor = (yyvsp[(8) - (8)].str); + n->newValIsAfter = false; + (yyval.node) = (Node *) n; + ;} + break; + + case 682: + +/* Line 1455 of yacc.c */ +#line 4553 "gram.y" + { + AlterEnumStmt *n = makeNode(AlterEnumStmt); + n->typeName = (yyvsp[(3) - (8)].list); + n->newVal = (yyvsp[(6) - (8)].str); + n->newValNeighbor = (yyvsp[(8) - (8)].str); + n->newValIsAfter = true; + (yyval.node) = (Node *) n; + ;} + break; + + case 683: + +/* Line 1455 of yacc.c */ +#line 4578 "gram.y" + { + CreateOpClassStmt *n = makeNode(CreateOpClassStmt); + n->opclassname = (yyvsp[(4) - (13)].list); + n->isDefault = (yyvsp[(5) - (13)].boolean); + n->datatype = (yyvsp[(8) - (13)].typnam); + n->amname = (yyvsp[(10) - (13)].str); + n->opfamilyname = (yyvsp[(11) - (13)].list); + n->items = (yyvsp[(13) - (13)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 684: + +/* Line 1455 of yacc.c */ +#line 4591 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].node)); ;} + break; + + case 685: + +/* Line 1455 of yacc.c */ +#line 4592 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].node)); ;} + break; + + case 686: + +/* Line 1455 of yacc.c */ +#line 4597 "gram.y" + { + CreateOpClassItem *n = makeNode(CreateOpClassItem); + n->itemtype = OPCLASS_ITEM_OPERATOR; + n->name = (yyvsp[(3) - (5)].list); + n->args = NIL; + n->number = (yyvsp[(2) - (5)].ival); + n->order_family = (yyvsp[(4) - (5)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 687: + +/* Line 1455 of yacc.c */ +#line 4608 "gram.y" + { + CreateOpClassItem *n = makeNode(CreateOpClassItem); + n->itemtype = OPCLASS_ITEM_OPERATOR; + n->name = (yyvsp[(3) - (6)].list); + n->args = (yyvsp[(4) - (6)].list); + n->number = (yyvsp[(2) - (6)].ival); + n->order_family = (yyvsp[(5) - (6)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 688: + +/* Line 1455 of yacc.c */ +#line 4618 "gram.y" + { + CreateOpClassItem *n = makeNode(CreateOpClassItem); + n->itemtype = OPCLASS_ITEM_FUNCTION; + n->name = (yyvsp[(3) - (4)].list); + n->args = extractArgTypes((yyvsp[(4) - (4)].list)); + n->number = (yyvsp[(2) - (4)].ival); + (yyval.node) = (Node *) n; + ;} + break; + + case 689: + +/* Line 1455 of yacc.c */ +#line 4627 "gram.y" + { + CreateOpClassItem *n = makeNode(CreateOpClassItem); + n->itemtype = OPCLASS_ITEM_FUNCTION; + n->name = (yyvsp[(6) - (7)].list); + n->args = extractArgTypes((yyvsp[(7) - (7)].list)); + n->number = (yyvsp[(2) - (7)].ival); + n->class_args = (yyvsp[(4) - (7)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 690: + +/* Line 1455 of yacc.c */ +#line 4637 "gram.y" + { + CreateOpClassItem *n = makeNode(CreateOpClassItem); + n->itemtype = OPCLASS_ITEM_STORAGETYPE; + n->storedtype = (yyvsp[(2) - (2)].typnam); + (yyval.node) = (Node *) n; + ;} + break; + + case 691: + +/* Line 1455 of yacc.c */ +#line 4645 "gram.y" + { (yyval.boolean) = TRUE; ;} + break; + + case 692: + +/* Line 1455 of yacc.c */ +#line 4646 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 693: + +/* Line 1455 of yacc.c */ +#line 4649 "gram.y" + { (yyval.list) = (yyvsp[(2) - (2)].list); ;} + break; + + case 694: + +/* Line 1455 of yacc.c */ +#line 4650 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 695: + +/* Line 1455 of yacc.c */ +#line 4653 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 696: + +/* Line 1455 of yacc.c */ +#line 4654 "gram.y" + { (yyval.list) = (yyvsp[(4) - (4)].list); ;} + break; + + case 697: + +/* Line 1455 of yacc.c */ +#line 4655 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 698: + +/* Line 1455 of yacc.c */ +#line 4659 "gram.y" + { + /* + * RECHECK no longer does anything in opclass definitions, + * but we still accept it to ease porting of old database + * dumps. + */ + ereport(NOTICE, + (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), + errmsg("RECHECK is no longer required"), + errhint("Update your data type."), + parser_errposition((yylsp[(1) - (1)])))); + (yyval.boolean) = TRUE; + ;} + break; + + case 699: + +/* Line 1455 of yacc.c */ +#line 4672 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 700: + +/* Line 1455 of yacc.c */ +#line 4678 "gram.y" + { + CreateOpFamilyStmt *n = makeNode(CreateOpFamilyStmt); + n->opfamilyname = (yyvsp[(4) - (6)].list); + n->amname = (yyvsp[(6) - (6)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 701: + +/* Line 1455 of yacc.c */ +#line 4688 "gram.y" + { + AlterOpFamilyStmt *n = makeNode(AlterOpFamilyStmt); + n->opfamilyname = (yyvsp[(4) - (8)].list); + n->amname = (yyvsp[(6) - (8)].str); + n->isDrop = false; + n->items = (yyvsp[(8) - (8)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 702: + +/* Line 1455 of yacc.c */ +#line 4697 "gram.y" + { + AlterOpFamilyStmt *n = makeNode(AlterOpFamilyStmt); + n->opfamilyname = (yyvsp[(4) - (8)].list); + n->amname = (yyvsp[(6) - (8)].str); + n->isDrop = true; + n->items = (yyvsp[(8) - (8)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 703: + +/* Line 1455 of yacc.c */ +#line 4708 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].node)); ;} + break; + + case 704: + +/* Line 1455 of yacc.c */ +#line 4709 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].node)); ;} + break; + + case 705: + +/* Line 1455 of yacc.c */ +#line 4714 "gram.y" + { + CreateOpClassItem *n = makeNode(CreateOpClassItem); + n->itemtype = OPCLASS_ITEM_OPERATOR; + n->number = (yyvsp[(2) - (5)].ival); + n->args = (yyvsp[(4) - (5)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 706: + +/* Line 1455 of yacc.c */ +#line 4722 "gram.y" + { + CreateOpClassItem *n = makeNode(CreateOpClassItem); + n->itemtype = OPCLASS_ITEM_FUNCTION; + n->number = (yyvsp[(2) - (5)].ival); + n->args = (yyvsp[(4) - (5)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 707: + +/* Line 1455 of yacc.c */ +#line 4734 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->objects = list_make1((yyvsp[(4) - (7)].list)); + n->arguments = list_make1(list_make1(makeString((yyvsp[(6) - (7)].str)))); + n->removeType = OBJECT_OPCLASS; + n->behavior = (yyvsp[(7) - (7)].dbehavior); + n->missing_ok = false; + n->concurrent = false; + (yyval.node) = (Node *) n; + ;} + break; + + case 708: + +/* Line 1455 of yacc.c */ +#line 4745 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->objects = list_make1((yyvsp[(6) - (9)].list)); + n->arguments = list_make1(list_make1(makeString((yyvsp[(8) - (9)].str)))); + n->removeType = OBJECT_OPCLASS; + n->behavior = (yyvsp[(9) - (9)].dbehavior); + n->missing_ok = true; + n->concurrent = false; + (yyval.node) = (Node *) n; + ;} + break; + + case 709: + +/* Line 1455 of yacc.c */ +#line 4759 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->objects = list_make1((yyvsp[(4) - (7)].list)); + n->arguments = list_make1(list_make1(makeString((yyvsp[(6) - (7)].str)))); + n->removeType = OBJECT_OPFAMILY; + n->behavior = (yyvsp[(7) - (7)].dbehavior); + n->missing_ok = false; + n->concurrent = false; + (yyval.node) = (Node *) n; + ;} + break; + + case 710: + +/* Line 1455 of yacc.c */ +#line 4770 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->objects = list_make1((yyvsp[(6) - (9)].list)); + n->arguments = list_make1(list_make1(makeString((yyvsp[(8) - (9)].str)))); + n->removeType = OBJECT_OPFAMILY; + n->behavior = (yyvsp[(9) - (9)].dbehavior); + n->missing_ok = true; + n->concurrent = false; + (yyval.node) = (Node *) n; + ;} + break; + + case 711: + +/* Line 1455 of yacc.c */ +#line 4793 "gram.y" + { + DropOwnedStmt *n = makeNode(DropOwnedStmt); + n->roles = (yyvsp[(4) - (5)].list); + n->behavior = (yyvsp[(5) - (5)].dbehavior); + (yyval.node) = (Node *)n; + ;} + break; + + case 712: + +/* Line 1455 of yacc.c */ +#line 4803 "gram.y" + { + ReassignOwnedStmt *n = makeNode(ReassignOwnedStmt); + n->roles = (yyvsp[(4) - (6)].list); + n->newrole = (yyvsp[(6) - (6)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 713: + +/* Line 1455 of yacc.c */ +#line 4821 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->removeType = (yyvsp[(2) - (6)].objtype); + n->missing_ok = TRUE; + n->objects = (yyvsp[(5) - (6)].list); + n->arguments = NIL; + n->behavior = (yyvsp[(6) - (6)].dbehavior); + n->concurrent = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 714: + +/* Line 1455 of yacc.c */ +#line 4832 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->removeType = (yyvsp[(2) - (4)].objtype); + n->missing_ok = FALSE; + n->objects = (yyvsp[(3) - (4)].list); + n->arguments = NIL; + n->behavior = (yyvsp[(4) - (4)].dbehavior); + n->concurrent = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 715: + +/* Line 1455 of yacc.c */ +#line 4843 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->removeType = OBJECT_INDEX; + n->missing_ok = FALSE; + n->objects = (yyvsp[(4) - (5)].list); + n->arguments = NIL; + n->behavior = (yyvsp[(5) - (5)].dbehavior); + n->concurrent = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 716: + +/* Line 1455 of yacc.c */ +#line 4854 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->removeType = OBJECT_INDEX; + n->missing_ok = TRUE; + n->objects = (yyvsp[(6) - (7)].list); + n->arguments = NIL; + n->behavior = (yyvsp[(7) - (7)].dbehavior); + n->concurrent = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 717: + +/* Line 1455 of yacc.c */ +#line 4867 "gram.y" + { (yyval.objtype) = OBJECT_TABLE; ;} + break; + + case 718: + +/* Line 1455 of yacc.c */ +#line 4868 "gram.y" + { (yyval.objtype) = OBJECT_SEQUENCE; ;} + break; + + case 719: + +/* Line 1455 of yacc.c */ +#line 4869 "gram.y" + { (yyval.objtype) = OBJECT_VIEW; ;} + break; + + case 720: + +/* Line 1455 of yacc.c */ +#line 4870 "gram.y" + { (yyval.objtype) = OBJECT_INDEX; ;} + break; + + case 721: + +/* Line 1455 of yacc.c */ +#line 4871 "gram.y" + { (yyval.objtype) = OBJECT_FOREIGN_TABLE; ;} + break; + + case 722: + +/* Line 1455 of yacc.c */ +#line 4872 "gram.y" + { (yyval.objtype) = OBJECT_TYPE; ;} + break; + + case 723: + +/* Line 1455 of yacc.c */ +#line 4873 "gram.y" + { (yyval.objtype) = OBJECT_DOMAIN; ;} + break; + + case 724: + +/* Line 1455 of yacc.c */ +#line 4874 "gram.y" + { (yyval.objtype) = OBJECT_COLLATION; ;} + break; + + case 725: + +/* Line 1455 of yacc.c */ +#line 4875 "gram.y" + { (yyval.objtype) = OBJECT_CONVERSION; ;} + break; + + case 726: + +/* Line 1455 of yacc.c */ +#line 4876 "gram.y" + { (yyval.objtype) = OBJECT_SCHEMA; ;} + break; + + case 727: + +/* Line 1455 of yacc.c */ +#line 4877 "gram.y" + { (yyval.objtype) = OBJECT_EXTENSION; ;} + break; + + case 728: + +/* Line 1455 of yacc.c */ +#line 4878 "gram.y" + { (yyval.objtype) = OBJECT_TSPARSER; ;} + break; + + case 729: + +/* Line 1455 of yacc.c */ +#line 4879 "gram.y" + { (yyval.objtype) = OBJECT_TSDICTIONARY; ;} + break; + + case 730: + +/* Line 1455 of yacc.c */ +#line 4880 "gram.y" + { (yyval.objtype) = OBJECT_TSTEMPLATE; ;} + break; + + case 731: + +/* Line 1455 of yacc.c */ +#line 4881 "gram.y" + { (yyval.objtype) = OBJECT_TSCONFIGURATION; ;} + break; + + case 732: + +/* Line 1455 of yacc.c */ +#line 4885 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].list)); ;} + break; + + case 733: + +/* Line 1455 of yacc.c */ +#line 4886 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].list)); ;} + break; + + case 734: + +/* Line 1455 of yacc.c */ +#line 4889 "gram.y" + { (yyval.list) = list_make1(makeString((yyvsp[(1) - (1)].str))); ;} + break; + + case 735: + +/* Line 1455 of yacc.c */ +#line 4890 "gram.y" + { (yyval.list) = lcons(makeString((yyvsp[(1) - (2)].str)), (yyvsp[(2) - (2)].list)); ;} + break; + + case 736: + +/* Line 1455 of yacc.c */ +#line 4894 "gram.y" + { (yyval.list) = list_make1(makeString((yyvsp[(2) - (2)].str))); ;} + break; + + case 737: + +/* Line 1455 of yacc.c */ +#line 4896 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), makeString((yyvsp[(3) - (3)].str))); ;} + break; + + case 738: + +/* Line 1455 of yacc.c */ +#line 4909 "gram.y" + { + TruncateStmt *n = makeNode(TruncateStmt); + n->relations = (yyvsp[(3) - (5)].list); + n->restart_seqs = (yyvsp[(4) - (5)].boolean); + n->behavior = (yyvsp[(5) - (5)].dbehavior); + (yyval.node) = (Node *)n; + ;} + break; + + case 739: + +/* Line 1455 of yacc.c */ +#line 4919 "gram.y" + { (yyval.boolean) = false; ;} + break; + + case 740: + +/* Line 1455 of yacc.c */ +#line 4920 "gram.y" + { (yyval.boolean) = true; ;} + break; + + case 741: + +/* Line 1455 of yacc.c */ +#line 4921 "gram.y" + { (yyval.boolean) = false; ;} + break; + + case 742: + +/* Line 1455 of yacc.c */ +#line 4948 "gram.y" + { + CommentStmt *n = makeNode(CommentStmt); + n->objtype = (yyvsp[(3) - (6)].objtype); + n->objname = (yyvsp[(4) - (6)].list); + n->objargs = NIL; + n->comment = (yyvsp[(6) - (6)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 743: + +/* Line 1455 of yacc.c */ +#line 4957 "gram.y" + { + CommentStmt *n = makeNode(CommentStmt); + n->objtype = OBJECT_AGGREGATE; + n->objname = (yyvsp[(4) - (7)].list); + n->objargs = (yyvsp[(5) - (7)].list); + n->comment = (yyvsp[(7) - (7)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 744: + +/* Line 1455 of yacc.c */ +#line 4966 "gram.y" + { + CommentStmt *n = makeNode(CommentStmt); + n->objtype = OBJECT_FUNCTION; + n->objname = (yyvsp[(4) - (7)].list); + n->objargs = extractArgTypes((yyvsp[(5) - (7)].list)); + n->comment = (yyvsp[(7) - (7)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 745: + +/* Line 1455 of yacc.c */ +#line 4975 "gram.y" + { + CommentStmt *n = makeNode(CommentStmt); + n->objtype = OBJECT_OPERATOR; + n->objname = (yyvsp[(4) - (7)].list); + n->objargs = (yyvsp[(5) - (7)].list); + n->comment = (yyvsp[(7) - (7)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 746: + +/* Line 1455 of yacc.c */ +#line 4984 "gram.y" + { + CommentStmt *n = makeNode(CommentStmt); + n->objtype = OBJECT_CONSTRAINT; + n->objname = lappend((yyvsp[(6) - (8)].list), makeString((yyvsp[(4) - (8)].str))); + n->objargs = NIL; + n->comment = (yyvsp[(8) - (8)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 747: + +/* Line 1455 of yacc.c */ +#line 4993 "gram.y" + { + CommentStmt *n = makeNode(CommentStmt); + n->objtype = OBJECT_RULE; + n->objname = lappend((yyvsp[(6) - (8)].list), makeString((yyvsp[(4) - (8)].str))); + n->objargs = NIL; + n->comment = (yyvsp[(8) - (8)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 748: + +/* Line 1455 of yacc.c */ +#line 5002 "gram.y" + { + /* Obsolete syntax supported for awhile for compatibility */ + CommentStmt *n = makeNode(CommentStmt); + n->objtype = OBJECT_RULE; + n->objname = list_make1(makeString((yyvsp[(4) - (6)].str))); + n->objargs = NIL; + n->comment = (yyvsp[(6) - (6)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 749: + +/* Line 1455 of yacc.c */ +#line 5012 "gram.y" + { + CommentStmt *n = makeNode(CommentStmt); + n->objtype = OBJECT_TRIGGER; + n->objname = lappend((yyvsp[(6) - (8)].list), makeString((yyvsp[(4) - (8)].str))); + n->objargs = NIL; + n->comment = (yyvsp[(8) - (8)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 750: + +/* Line 1455 of yacc.c */ +#line 5021 "gram.y" + { + CommentStmt *n = makeNode(CommentStmt); + n->objtype = OBJECT_OPCLASS; + n->objname = (yyvsp[(5) - (9)].list); + n->objargs = list_make1(makeString((yyvsp[(7) - (9)].str))); + n->comment = (yyvsp[(9) - (9)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 751: + +/* Line 1455 of yacc.c */ +#line 5030 "gram.y" + { + CommentStmt *n = makeNode(CommentStmt); + n->objtype = OBJECT_OPFAMILY; + n->objname = (yyvsp[(5) - (9)].list); + n->objargs = list_make1(makeString((yyvsp[(7) - (9)].str))); + n->comment = (yyvsp[(9) - (9)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 752: + +/* Line 1455 of yacc.c */ +#line 5039 "gram.y" + { + CommentStmt *n = makeNode(CommentStmt); + n->objtype = OBJECT_LARGEOBJECT; + n->objname = list_make1((yyvsp[(5) - (7)].value)); + n->objargs = NIL; + n->comment = (yyvsp[(7) - (7)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 753: + +/* Line 1455 of yacc.c */ +#line 5048 "gram.y" + { + CommentStmt *n = makeNode(CommentStmt); + n->objtype = OBJECT_CAST; + n->objname = list_make1((yyvsp[(5) - (10)].typnam)); + n->objargs = list_make1((yyvsp[(7) - (10)].typnam)); + n->comment = (yyvsp[(10) - (10)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 754: + +/* Line 1455 of yacc.c */ +#line 5057 "gram.y" + { + CommentStmt *n = makeNode(CommentStmt); + n->objtype = OBJECT_LANGUAGE; + n->objname = (yyvsp[(5) - (7)].list); + n->objargs = NIL; + n->comment = (yyvsp[(7) - (7)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 755: + +/* Line 1455 of yacc.c */ +#line 5066 "gram.y" + { + CommentStmt *n = makeNode(CommentStmt); + n->objtype = OBJECT_TSPARSER; + n->objname = (yyvsp[(6) - (8)].list); + n->comment = (yyvsp[(8) - (8)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 756: + +/* Line 1455 of yacc.c */ +#line 5074 "gram.y" + { + CommentStmt *n = makeNode(CommentStmt); + n->objtype = OBJECT_TSDICTIONARY; + n->objname = (yyvsp[(6) - (8)].list); + n->comment = (yyvsp[(8) - (8)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 757: + +/* Line 1455 of yacc.c */ +#line 5082 "gram.y" + { + CommentStmt *n = makeNode(CommentStmt); + n->objtype = OBJECT_TSTEMPLATE; + n->objname = (yyvsp[(6) - (8)].list); + n->comment = (yyvsp[(8) - (8)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 758: + +/* Line 1455 of yacc.c */ +#line 5090 "gram.y" + { + CommentStmt *n = makeNode(CommentStmt); + n->objtype = OBJECT_TSCONFIGURATION; + n->objname = (yyvsp[(6) - (8)].list); + n->comment = (yyvsp[(8) - (8)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 759: + +/* Line 1455 of yacc.c */ +#line 5100 "gram.y" + { (yyval.objtype) = OBJECT_COLUMN; ;} + break; + + case 760: + +/* Line 1455 of yacc.c */ +#line 5101 "gram.y" + { (yyval.objtype) = OBJECT_DATABASE; ;} + break; + + case 761: + +/* Line 1455 of yacc.c */ +#line 5102 "gram.y" + { (yyval.objtype) = OBJECT_SCHEMA; ;} + break; + + case 762: + +/* Line 1455 of yacc.c */ +#line 5103 "gram.y" + { (yyval.objtype) = OBJECT_INDEX; ;} + break; + + case 763: + +/* Line 1455 of yacc.c */ +#line 5104 "gram.y" + { (yyval.objtype) = OBJECT_SEQUENCE; ;} + break; + + case 764: + +/* Line 1455 of yacc.c */ +#line 5105 "gram.y" + { (yyval.objtype) = OBJECT_TABLE; ;} + break; + + case 765: + +/* Line 1455 of yacc.c */ +#line 5106 "gram.y" + { (yyval.objtype) = OBJECT_DOMAIN; ;} + break; + + case 766: + +/* Line 1455 of yacc.c */ +#line 5107 "gram.y" + { (yyval.objtype) = OBJECT_TYPE; ;} + break; + + case 767: + +/* Line 1455 of yacc.c */ +#line 5108 "gram.y" + { (yyval.objtype) = OBJECT_VIEW; ;} + break; + + case 768: + +/* Line 1455 of yacc.c */ +#line 5109 "gram.y" + { (yyval.objtype) = OBJECT_COLLATION; ;} + break; + + case 769: + +/* Line 1455 of yacc.c */ +#line 5110 "gram.y" + { (yyval.objtype) = OBJECT_CONVERSION; ;} + break; + + case 770: + +/* Line 1455 of yacc.c */ +#line 5111 "gram.y" + { (yyval.objtype) = OBJECT_TABLESPACE; ;} + break; + + case 771: + +/* Line 1455 of yacc.c */ +#line 5112 "gram.y" + { (yyval.objtype) = OBJECT_EXTENSION; ;} + break; + + case 772: + +/* Line 1455 of yacc.c */ +#line 5113 "gram.y" + { (yyval.objtype) = OBJECT_ROLE; ;} + break; + + case 773: + +/* Line 1455 of yacc.c */ +#line 5114 "gram.y" + { (yyval.objtype) = OBJECT_FOREIGN_TABLE; ;} + break; + + case 774: + +/* Line 1455 of yacc.c */ +#line 5115 "gram.y" + { (yyval.objtype) = OBJECT_FOREIGN_SERVER; ;} + break; + + case 775: + +/* Line 1455 of yacc.c */ +#line 5116 "gram.y" + { (yyval.objtype) = OBJECT_FDW; ;} + break; + + case 776: + +/* Line 1455 of yacc.c */ +#line 5120 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 777: + +/* Line 1455 of yacc.c */ +#line 5121 "gram.y" + { (yyval.str) = NULL; ;} + break; + + case 778: + +/* Line 1455 of yacc.c */ +#line 5137 "gram.y" + { + SecLabelStmt *n = makeNode(SecLabelStmt); + n->provider = (yyvsp[(3) - (8)].str); + n->objtype = (yyvsp[(5) - (8)].objtype); + n->objname = (yyvsp[(6) - (8)].list); + n->objargs = NIL; + n->label = (yyvsp[(8) - (8)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 779: + +/* Line 1455 of yacc.c */ +#line 5148 "gram.y" + { + SecLabelStmt *n = makeNode(SecLabelStmt); + n->provider = (yyvsp[(3) - (9)].str); + n->objtype = OBJECT_AGGREGATE; + n->objname = (yyvsp[(6) - (9)].list); + n->objargs = (yyvsp[(7) - (9)].list); + n->label = (yyvsp[(9) - (9)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 780: + +/* Line 1455 of yacc.c */ +#line 5159 "gram.y" + { + SecLabelStmt *n = makeNode(SecLabelStmt); + n->provider = (yyvsp[(3) - (9)].str); + n->objtype = OBJECT_FUNCTION; + n->objname = (yyvsp[(6) - (9)].list); + n->objargs = extractArgTypes((yyvsp[(7) - (9)].list)); + n->label = (yyvsp[(9) - (9)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 781: + +/* Line 1455 of yacc.c */ +#line 5170 "gram.y" + { + SecLabelStmt *n = makeNode(SecLabelStmt); + n->provider = (yyvsp[(3) - (9)].str); + n->objtype = OBJECT_LARGEOBJECT; + n->objname = list_make1((yyvsp[(7) - (9)].value)); + n->objargs = NIL; + n->label = (yyvsp[(9) - (9)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 782: + +/* Line 1455 of yacc.c */ +#line 5181 "gram.y" + { + SecLabelStmt *n = makeNode(SecLabelStmt); + n->provider = (yyvsp[(3) - (9)].str); + n->objtype = OBJECT_LANGUAGE; + n->objname = (yyvsp[(7) - (9)].list); + n->objargs = NIL; + n->label = (yyvsp[(9) - (9)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 783: + +/* Line 1455 of yacc.c */ +#line 5192 "gram.y" + { (yyval.str) = (yyvsp[(2) - (2)].str); ;} + break; + + case 784: + +/* Line 1455 of yacc.c */ +#line 5193 "gram.y" + { (yyval.str) = NULL; ;} + break; + + case 785: + +/* Line 1455 of yacc.c */ +#line 5197 "gram.y" + { (yyval.objtype) = OBJECT_COLUMN; ;} + break; + + case 786: + +/* Line 1455 of yacc.c */ +#line 5198 "gram.y" + { (yyval.objtype) = OBJECT_DATABASE; ;} + break; + + case 787: + +/* Line 1455 of yacc.c */ +#line 5199 "gram.y" + { (yyval.objtype) = OBJECT_FOREIGN_TABLE; ;} + break; + + case 788: + +/* Line 1455 of yacc.c */ +#line 5200 "gram.y" + { (yyval.objtype) = OBJECT_SCHEMA; ;} + break; + + case 789: + +/* Line 1455 of yacc.c */ +#line 5201 "gram.y" + { (yyval.objtype) = OBJECT_SEQUENCE; ;} + break; + + case 790: + +/* Line 1455 of yacc.c */ +#line 5202 "gram.y" + { (yyval.objtype) = OBJECT_TABLE; ;} + break; + + case 791: + +/* Line 1455 of yacc.c */ +#line 5203 "gram.y" + { (yyval.objtype) = OBJECT_TYPE; ;} + break; + + case 792: + +/* Line 1455 of yacc.c */ +#line 5204 "gram.y" + { (yyval.objtype) = OBJECT_ROLE; ;} + break; + + case 793: + +/* Line 1455 of yacc.c */ +#line 5205 "gram.y" + { (yyval.objtype) = OBJECT_TABLESPACE; ;} + break; + + case 794: + +/* Line 1455 of yacc.c */ +#line 5206 "gram.y" + { (yyval.objtype) = OBJECT_TYPE; ;} + break; + + case 795: + +/* Line 1455 of yacc.c */ +#line 5207 "gram.y" + { (yyval.objtype) = OBJECT_VIEW; ;} + break; + + case 796: + +/* Line 1455 of yacc.c */ +#line 5210 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 797: + +/* Line 1455 of yacc.c */ +#line 5211 "gram.y" + { (yyval.str) = NULL; ;} + break; + + case 798: + +/* Line 1455 of yacc.c */ +#line 5222 "gram.y" + { + FetchStmt *n = (FetchStmt *) (yyvsp[(2) - (2)].node); + n->ismove = FALSE; + (yyval.node) = (Node *)n; + ;} + break; + + case 799: + +/* Line 1455 of yacc.c */ +#line 5228 "gram.y" + { + FetchStmt *n = (FetchStmt *) (yyvsp[(2) - (2)].node); + n->ismove = TRUE; + (yyval.node) = (Node *)n; + ;} + break; + + case 800: + +/* Line 1455 of yacc.c */ +#line 5236 "gram.y" + { + FetchStmt *n = makeNode(FetchStmt); + n->portalname = (yyvsp[(1) - (1)].str); + n->direction = FETCH_FORWARD; + n->howMany = 1; + (yyval.node) = (Node *)n; + ;} + break; + + case 801: + +/* Line 1455 of yacc.c */ +#line 5244 "gram.y" + { + FetchStmt *n = makeNode(FetchStmt); + n->portalname = (yyvsp[(2) - (2)].str); + n->direction = FETCH_FORWARD; + n->howMany = 1; + (yyval.node) = (Node *)n; + ;} + break; + + case 802: + +/* Line 1455 of yacc.c */ +#line 5252 "gram.y" + { + FetchStmt *n = makeNode(FetchStmt); + n->portalname = (yyvsp[(3) - (3)].str); + n->direction = FETCH_FORWARD; + n->howMany = 1; + (yyval.node) = (Node *)n; + ;} + break; + + case 803: + +/* Line 1455 of yacc.c */ +#line 5260 "gram.y" + { + FetchStmt *n = makeNode(FetchStmt); + n->portalname = (yyvsp[(3) - (3)].str); + n->direction = FETCH_BACKWARD; + n->howMany = 1; + (yyval.node) = (Node *)n; + ;} + break; + + case 804: + +/* Line 1455 of yacc.c */ +#line 5268 "gram.y" + { + FetchStmt *n = makeNode(FetchStmt); + n->portalname = (yyvsp[(3) - (3)].str); + n->direction = FETCH_ABSOLUTE; + n->howMany = 1; + (yyval.node) = (Node *)n; + ;} + break; + + case 805: + +/* Line 1455 of yacc.c */ +#line 5276 "gram.y" + { + FetchStmt *n = makeNode(FetchStmt); + n->portalname = (yyvsp[(3) - (3)].str); + n->direction = FETCH_ABSOLUTE; + n->howMany = -1; + (yyval.node) = (Node *)n; + ;} + break; + + case 806: + +/* Line 1455 of yacc.c */ +#line 5284 "gram.y" + { + FetchStmt *n = makeNode(FetchStmt); + n->portalname = (yyvsp[(4) - (4)].str); + n->direction = FETCH_ABSOLUTE; + n->howMany = (yyvsp[(2) - (4)].ival); + (yyval.node) = (Node *)n; + ;} + break; + + case 807: + +/* Line 1455 of yacc.c */ +#line 5292 "gram.y" + { + FetchStmt *n = makeNode(FetchStmt); + n->portalname = (yyvsp[(4) - (4)].str); + n->direction = FETCH_RELATIVE; + n->howMany = (yyvsp[(2) - (4)].ival); + (yyval.node) = (Node *)n; + ;} + break; + + case 808: + +/* Line 1455 of yacc.c */ +#line 5300 "gram.y" + { + FetchStmt *n = makeNode(FetchStmt); + n->portalname = (yyvsp[(3) - (3)].str); + n->direction = FETCH_FORWARD; + n->howMany = (yyvsp[(1) - (3)].ival); + (yyval.node) = (Node *)n; + ;} + break; + + case 809: + +/* Line 1455 of yacc.c */ +#line 5308 "gram.y" + { + FetchStmt *n = makeNode(FetchStmt); + n->portalname = (yyvsp[(3) - (3)].str); + n->direction = FETCH_FORWARD; + n->howMany = FETCH_ALL; + (yyval.node) = (Node *)n; + ;} + break; + + case 810: + +/* Line 1455 of yacc.c */ +#line 5316 "gram.y" + { + FetchStmt *n = makeNode(FetchStmt); + n->portalname = (yyvsp[(3) - (3)].str); + n->direction = FETCH_FORWARD; + n->howMany = 1; + (yyval.node) = (Node *)n; + ;} + break; + + case 811: + +/* Line 1455 of yacc.c */ +#line 5324 "gram.y" + { + FetchStmt *n = makeNode(FetchStmt); + n->portalname = (yyvsp[(4) - (4)].str); + n->direction = FETCH_FORWARD; + n->howMany = (yyvsp[(2) - (4)].ival); + (yyval.node) = (Node *)n; + ;} + break; + + case 812: + +/* Line 1455 of yacc.c */ +#line 5332 "gram.y" + { + FetchStmt *n = makeNode(FetchStmt); + n->portalname = (yyvsp[(4) - (4)].str); + n->direction = FETCH_FORWARD; + n->howMany = FETCH_ALL; + (yyval.node) = (Node *)n; + ;} + break; + + case 813: + +/* Line 1455 of yacc.c */ +#line 5340 "gram.y" + { + FetchStmt *n = makeNode(FetchStmt); + n->portalname = (yyvsp[(3) - (3)].str); + n->direction = FETCH_BACKWARD; + n->howMany = 1; + (yyval.node) = (Node *)n; + ;} + break; + + case 814: + +/* Line 1455 of yacc.c */ +#line 5348 "gram.y" + { + FetchStmt *n = makeNode(FetchStmt); + n->portalname = (yyvsp[(4) - (4)].str); + n->direction = FETCH_BACKWARD; + n->howMany = (yyvsp[(2) - (4)].ival); + (yyval.node) = (Node *)n; + ;} + break; + + case 815: + +/* Line 1455 of yacc.c */ +#line 5356 "gram.y" + { + FetchStmt *n = makeNode(FetchStmt); + n->portalname = (yyvsp[(4) - (4)].str); + n->direction = FETCH_BACKWARD; + n->howMany = FETCH_ALL; + (yyval.node) = (Node *)n; + ;} + break; + + case 816: + +/* Line 1455 of yacc.c */ +#line 5365 "gram.y" + {;} + break; + + case 817: + +/* Line 1455 of yacc.c */ +#line 5366 "gram.y" + {;} + break; + + case 818: + +/* Line 1455 of yacc.c */ +#line 5369 "gram.y" + {;} + break; + + case 819: + +/* Line 1455 of yacc.c */ +#line 5370 "gram.y" + {;} + break; + + case 820: + +/* Line 1455 of yacc.c */ +#line 5382 "gram.y" + { + GrantStmt *n = makeNode(GrantStmt); + n->is_grant = true; + n->privileges = (yyvsp[(2) - (7)].list); + n->targtype = ((yyvsp[(4) - (7)].privtarget))->targtype; + n->objtype = ((yyvsp[(4) - (7)].privtarget))->objtype; + n->objects = ((yyvsp[(4) - (7)].privtarget))->objs; + n->grantees = (yyvsp[(6) - (7)].list); + n->grant_option = (yyvsp[(7) - (7)].boolean); + (yyval.node) = (Node*)n; + ;} + break; + + case 821: + +/* Line 1455 of yacc.c */ +#line 5398 "gram.y" + { + GrantStmt *n = makeNode(GrantStmt); + n->is_grant = false; + n->grant_option = false; + n->privileges = (yyvsp[(2) - (7)].list); + n->targtype = ((yyvsp[(4) - (7)].privtarget))->targtype; + n->objtype = ((yyvsp[(4) - (7)].privtarget))->objtype; + n->objects = ((yyvsp[(4) - (7)].privtarget))->objs; + n->grantees = (yyvsp[(6) - (7)].list); + n->behavior = (yyvsp[(7) - (7)].dbehavior); + (yyval.node) = (Node *)n; + ;} + break; + + case 822: + +/* Line 1455 of yacc.c */ +#line 5412 "gram.y" + { + GrantStmt *n = makeNode(GrantStmt); + n->is_grant = false; + n->grant_option = true; + n->privileges = (yyvsp[(5) - (10)].list); + n->targtype = ((yyvsp[(7) - (10)].privtarget))->targtype; + n->objtype = ((yyvsp[(7) - (10)].privtarget))->objtype; + n->objects = ((yyvsp[(7) - (10)].privtarget))->objs; + n->grantees = (yyvsp[(9) - (10)].list); + n->behavior = (yyvsp[(10) - (10)].dbehavior); + (yyval.node) = (Node *)n; + ;} + break; + + case 823: + +/* Line 1455 of yacc.c */ +#line 5437 "gram.y" + { (yyval.list) = (yyvsp[(1) - (1)].list); ;} + break; + + case 824: + +/* Line 1455 of yacc.c */ +#line 5439 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 825: + +/* Line 1455 of yacc.c */ +#line 5441 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 826: + +/* Line 1455 of yacc.c */ +#line 5443 "gram.y" + { + AccessPriv *n = makeNode(AccessPriv); + n->priv_name = NULL; + n->cols = (yyvsp[(3) - (4)].list); + (yyval.list) = list_make1(n); + ;} + break; + + case 827: + +/* Line 1455 of yacc.c */ +#line 5450 "gram.y" + { + AccessPriv *n = makeNode(AccessPriv); + n->priv_name = NULL; + n->cols = (yyvsp[(4) - (5)].list); + (yyval.list) = list_make1(n); + ;} + break; + + case 828: + +/* Line 1455 of yacc.c */ +#line 5458 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].accesspriv)); ;} + break; + + case 829: + +/* Line 1455 of yacc.c */ +#line 5459 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].accesspriv)); ;} + break; + + case 830: + +/* Line 1455 of yacc.c */ +#line 5463 "gram.y" + { + AccessPriv *n = makeNode(AccessPriv); + n->priv_name = pstrdup((yyvsp[(1) - (2)].keyword)); + n->cols = (yyvsp[(2) - (2)].list); + (yyval.accesspriv) = n; + ;} + break; + + case 831: + +/* Line 1455 of yacc.c */ +#line 5470 "gram.y" + { + AccessPriv *n = makeNode(AccessPriv); + n->priv_name = pstrdup((yyvsp[(1) - (2)].keyword)); + n->cols = (yyvsp[(2) - (2)].list); + (yyval.accesspriv) = n; + ;} + break; + + case 832: + +/* Line 1455 of yacc.c */ +#line 5477 "gram.y" + { + AccessPriv *n = makeNode(AccessPriv); + n->priv_name = pstrdup((yyvsp[(1) - (2)].keyword)); + n->cols = (yyvsp[(2) - (2)].list); + (yyval.accesspriv) = n; + ;} + break; + + case 833: + +/* Line 1455 of yacc.c */ +#line 5484 "gram.y" + { + AccessPriv *n = makeNode(AccessPriv); + n->priv_name = (yyvsp[(1) - (2)].str); + n->cols = (yyvsp[(2) - (2)].list); + (yyval.accesspriv) = n; + ;} + break; + + case 834: + +/* Line 1455 of yacc.c */ +#line 5498 "gram.y" + { + PrivTarget *n = (PrivTarget *) palloc(sizeof(PrivTarget)); + n->targtype = ACL_TARGET_OBJECT; + n->objtype = ACL_OBJECT_RELATION; + n->objs = (yyvsp[(1) - (1)].list); + (yyval.privtarget) = n; + ;} + break; + + case 835: + +/* Line 1455 of yacc.c */ +#line 5506 "gram.y" + { + PrivTarget *n = (PrivTarget *) palloc(sizeof(PrivTarget)); + n->targtype = ACL_TARGET_OBJECT; + n->objtype = ACL_OBJECT_RELATION; + n->objs = (yyvsp[(2) - (2)].list); + (yyval.privtarget) = n; + ;} + break; + + case 836: + +/* Line 1455 of yacc.c */ +#line 5514 "gram.y" + { + PrivTarget *n = (PrivTarget *) palloc(sizeof(PrivTarget)); + n->targtype = ACL_TARGET_OBJECT; + n->objtype = ACL_OBJECT_SEQUENCE; + n->objs = (yyvsp[(2) - (2)].list); + (yyval.privtarget) = n; + ;} + break; + + case 837: + +/* Line 1455 of yacc.c */ +#line 5522 "gram.y" + { + PrivTarget *n = (PrivTarget *) palloc(sizeof(PrivTarget)); + n->targtype = ACL_TARGET_OBJECT; + n->objtype = ACL_OBJECT_FDW; + n->objs = (yyvsp[(4) - (4)].list); + (yyval.privtarget) = n; + ;} + break; + + case 838: + +/* Line 1455 of yacc.c */ +#line 5530 "gram.y" + { + PrivTarget *n = (PrivTarget *) palloc(sizeof(PrivTarget)); + n->targtype = ACL_TARGET_OBJECT; + n->objtype = ACL_OBJECT_FOREIGN_SERVER; + n->objs = (yyvsp[(3) - (3)].list); + (yyval.privtarget) = n; + ;} + break; + + case 839: + +/* Line 1455 of yacc.c */ +#line 5538 "gram.y" + { + PrivTarget *n = (PrivTarget *) palloc(sizeof(PrivTarget)); + n->targtype = ACL_TARGET_OBJECT; + n->objtype = ACL_OBJECT_FUNCTION; + n->objs = (yyvsp[(2) - (2)].list); + (yyval.privtarget) = n; + ;} + break; + + case 840: + +/* Line 1455 of yacc.c */ +#line 5546 "gram.y" + { + PrivTarget *n = (PrivTarget *) palloc(sizeof(PrivTarget)); + n->targtype = ACL_TARGET_OBJECT; + n->objtype = ACL_OBJECT_DATABASE; + n->objs = (yyvsp[(2) - (2)].list); + (yyval.privtarget) = n; + ;} + break; + + case 841: + +/* Line 1455 of yacc.c */ +#line 5554 "gram.y" + { + PrivTarget *n = (PrivTarget *) palloc(sizeof(PrivTarget)); + n->targtype = ACL_TARGET_OBJECT; + n->objtype = ACL_OBJECT_DOMAIN; + n->objs = (yyvsp[(2) - (2)].list); + (yyval.privtarget) = n; + ;} + break; + + case 842: + +/* Line 1455 of yacc.c */ +#line 5562 "gram.y" + { + PrivTarget *n = (PrivTarget *) palloc(sizeof(PrivTarget)); + n->targtype = ACL_TARGET_OBJECT; + n->objtype = ACL_OBJECT_LANGUAGE; + n->objs = (yyvsp[(2) - (2)].list); + (yyval.privtarget) = n; + ;} + break; + + case 843: + +/* Line 1455 of yacc.c */ +#line 5570 "gram.y" + { + PrivTarget *n = (PrivTarget *) palloc(sizeof(PrivTarget)); + n->targtype = ACL_TARGET_OBJECT; + n->objtype = ACL_OBJECT_LARGEOBJECT; + n->objs = (yyvsp[(3) - (3)].list); + (yyval.privtarget) = n; + ;} + break; + + case 844: + +/* Line 1455 of yacc.c */ +#line 5578 "gram.y" + { + PrivTarget *n = (PrivTarget *) palloc(sizeof(PrivTarget)); + n->targtype = ACL_TARGET_OBJECT; + n->objtype = ACL_OBJECT_NAMESPACE; + n->objs = (yyvsp[(2) - (2)].list); + (yyval.privtarget) = n; + ;} + break; + + case 845: + +/* Line 1455 of yacc.c */ +#line 5586 "gram.y" + { + PrivTarget *n = (PrivTarget *) palloc(sizeof(PrivTarget)); + n->targtype = ACL_TARGET_OBJECT; + n->objtype = ACL_OBJECT_TABLESPACE; + n->objs = (yyvsp[(2) - (2)].list); + (yyval.privtarget) = n; + ;} + break; + + case 846: + +/* Line 1455 of yacc.c */ +#line 5594 "gram.y" + { + PrivTarget *n = (PrivTarget *) palloc(sizeof(PrivTarget)); + n->targtype = ACL_TARGET_OBJECT; + n->objtype = ACL_OBJECT_TYPE; + n->objs = (yyvsp[(2) - (2)].list); + (yyval.privtarget) = n; + ;} + break; + + case 847: + +/* Line 1455 of yacc.c */ +#line 5602 "gram.y" + { + PrivTarget *n = (PrivTarget *) palloc(sizeof(PrivTarget)); + n->targtype = ACL_TARGET_ALL_IN_SCHEMA; + n->objtype = ACL_OBJECT_RELATION; + n->objs = (yyvsp[(5) - (5)].list); + (yyval.privtarget) = n; + ;} + break; + + case 848: + +/* Line 1455 of yacc.c */ +#line 5610 "gram.y" + { + PrivTarget *n = (PrivTarget *) palloc(sizeof(PrivTarget)); + n->targtype = ACL_TARGET_ALL_IN_SCHEMA; + n->objtype = ACL_OBJECT_SEQUENCE; + n->objs = (yyvsp[(5) - (5)].list); + (yyval.privtarget) = n; + ;} + break; + + case 849: + +/* Line 1455 of yacc.c */ +#line 5618 "gram.y" + { + PrivTarget *n = (PrivTarget *) palloc(sizeof(PrivTarget)); + n->targtype = ACL_TARGET_ALL_IN_SCHEMA; + n->objtype = ACL_OBJECT_FUNCTION; + n->objs = (yyvsp[(5) - (5)].list); + (yyval.privtarget) = n; + ;} + break; + + case 850: + +/* Line 1455 of yacc.c */ +#line 5629 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].node)); ;} + break; + + case 851: + +/* Line 1455 of yacc.c */ +#line 5630 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].node)); ;} + break; + + case 852: + +/* Line 1455 of yacc.c */ +#line 5634 "gram.y" + { + PrivGrantee *n = makeNode(PrivGrantee); + /* This hack lets us avoid reserving PUBLIC as a keyword*/ + if (strcmp((yyvsp[(1) - (1)].str), "public") == 0) + n->rolname = NULL; + else + n->rolname = (yyvsp[(1) - (1)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 853: + +/* Line 1455 of yacc.c */ +#line 5644 "gram.y" + { + PrivGrantee *n = makeNode(PrivGrantee); + /* Treat GROUP PUBLIC as a synonym for PUBLIC */ + if (strcmp((yyvsp[(2) - (2)].str), "public") == 0) + n->rolname = NULL; + else + n->rolname = (yyvsp[(2) - (2)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 854: + +/* Line 1455 of yacc.c */ +#line 5657 "gram.y" + { (yyval.boolean) = TRUE; ;} + break; + + case 855: + +/* Line 1455 of yacc.c */ +#line 5658 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 856: + +/* Line 1455 of yacc.c */ +#line 5662 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].funwithargs)); ;} + break; + + case 857: + +/* Line 1455 of yacc.c */ +#line 5664 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].funwithargs)); ;} + break; + + case 858: + +/* Line 1455 of yacc.c */ +#line 5669 "gram.y" + { + FuncWithArgs *n = makeNode(FuncWithArgs); + n->funcname = (yyvsp[(1) - (2)].list); + n->funcargs = extractArgTypes((yyvsp[(2) - (2)].list)); + (yyval.funwithargs) = n; + ;} + break; + + case 859: + +/* Line 1455 of yacc.c */ +#line 5685 "gram.y" + { + GrantRoleStmt *n = makeNode(GrantRoleStmt); + n->is_grant = true; + n->granted_roles = (yyvsp[(2) - (6)].list); + n->grantee_roles = (yyvsp[(4) - (6)].list); + n->admin_opt = (yyvsp[(5) - (6)].boolean); + n->grantor = (yyvsp[(6) - (6)].str); + (yyval.node) = (Node*)n; + ;} + break; + + case 860: + +/* Line 1455 of yacc.c */ +#line 5698 "gram.y" + { + GrantRoleStmt *n = makeNode(GrantRoleStmt); + n->is_grant = false; + n->admin_opt = false; + n->granted_roles = (yyvsp[(2) - (6)].list); + n->grantee_roles = (yyvsp[(4) - (6)].list); + n->behavior = (yyvsp[(6) - (6)].dbehavior); + (yyval.node) = (Node*)n; + ;} + break; + + case 861: + +/* Line 1455 of yacc.c */ +#line 5708 "gram.y" + { + GrantRoleStmt *n = makeNode(GrantRoleStmt); + n->is_grant = false; + n->admin_opt = true; + n->granted_roles = (yyvsp[(5) - (9)].list); + n->grantee_roles = (yyvsp[(7) - (9)].list); + n->behavior = (yyvsp[(9) - (9)].dbehavior); + (yyval.node) = (Node*)n; + ;} + break; + + case 862: + +/* Line 1455 of yacc.c */ +#line 5719 "gram.y" + { (yyval.boolean) = TRUE; ;} + break; + + case 863: + +/* Line 1455 of yacc.c */ +#line 5720 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 864: + +/* Line 1455 of yacc.c */ +#line 5723 "gram.y" + { (yyval.str) = (yyvsp[(3) - (3)].str); ;} + break; + + case 865: + +/* Line 1455 of yacc.c */ +#line 5724 "gram.y" + { (yyval.str) = NULL; ;} + break; + + case 866: + +/* Line 1455 of yacc.c */ +#line 5735 "gram.y" + { + AlterDefaultPrivilegesStmt *n = makeNode(AlterDefaultPrivilegesStmt); + n->options = (yyvsp[(4) - (5)].list); + n->action = (GrantStmt *) (yyvsp[(5) - (5)].node); + (yyval.node) = (Node*)n; + ;} + break; + + case 867: + +/* Line 1455 of yacc.c */ +#line 5744 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (2)].list), (yyvsp[(2) - (2)].defelt)); ;} + break; + + case 868: + +/* Line 1455 of yacc.c */ +#line 5745 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 869: + +/* Line 1455 of yacc.c */ +#line 5750 "gram.y" + { + (yyval.defelt) = makeDefElem("schemas", (Node *)(yyvsp[(3) - (3)].list)); + ;} + break; + + case 870: + +/* Line 1455 of yacc.c */ +#line 5754 "gram.y" + { + (yyval.defelt) = makeDefElem("roles", (Node *)(yyvsp[(3) - (3)].list)); + ;} + break; + + case 871: + +/* Line 1455 of yacc.c */ +#line 5758 "gram.y" + { + (yyval.defelt) = makeDefElem("roles", (Node *)(yyvsp[(3) - (3)].list)); + ;} + break; + + case 872: + +/* Line 1455 of yacc.c */ +#line 5770 "gram.y" + { + GrantStmt *n = makeNode(GrantStmt); + n->is_grant = true; + n->privileges = (yyvsp[(2) - (7)].list); + n->targtype = ACL_TARGET_DEFAULTS; + n->objtype = (yyvsp[(4) - (7)].ival); + n->objects = NIL; + n->grantees = (yyvsp[(6) - (7)].list); + n->grant_option = (yyvsp[(7) - (7)].boolean); + (yyval.node) = (Node*)n; + ;} + break; + + case 873: + +/* Line 1455 of yacc.c */ +#line 5783 "gram.y" + { + GrantStmt *n = makeNode(GrantStmt); + n->is_grant = false; + n->grant_option = false; + n->privileges = (yyvsp[(2) - (7)].list); + n->targtype = ACL_TARGET_DEFAULTS; + n->objtype = (yyvsp[(4) - (7)].ival); + n->objects = NIL; + n->grantees = (yyvsp[(6) - (7)].list); + n->behavior = (yyvsp[(7) - (7)].dbehavior); + (yyval.node) = (Node *)n; + ;} + break; + + case 874: + +/* Line 1455 of yacc.c */ +#line 5797 "gram.y" + { + GrantStmt *n = makeNode(GrantStmt); + n->is_grant = false; + n->grant_option = true; + n->privileges = (yyvsp[(5) - (10)].list); + n->targtype = ACL_TARGET_DEFAULTS; + n->objtype = (yyvsp[(7) - (10)].ival); + n->objects = NIL; + n->grantees = (yyvsp[(9) - (10)].list); + n->behavior = (yyvsp[(10) - (10)].dbehavior); + (yyval.node) = (Node *)n; + ;} + break; + + case 875: + +/* Line 1455 of yacc.c */ +#line 5812 "gram.y" + { (yyval.ival) = ACL_OBJECT_RELATION; ;} + break; + + case 876: + +/* Line 1455 of yacc.c */ +#line 5813 "gram.y" + { (yyval.ival) = ACL_OBJECT_FUNCTION; ;} + break; + + case 877: + +/* Line 1455 of yacc.c */ +#line 5814 "gram.y" + { (yyval.ival) = ACL_OBJECT_SEQUENCE; ;} + break; + + case 878: + +/* Line 1455 of yacc.c */ +#line 5815 "gram.y" + { (yyval.ival) = ACL_OBJECT_TYPE; ;} + break; + + case 879: + +/* Line 1455 of yacc.c */ +#line 5830 "gram.y" + { + IndexStmt *n = makeNode(IndexStmt); + n->unique = (yyvsp[(2) - (14)].boolean); + n->concurrent = (yyvsp[(4) - (14)].boolean); + n->idxname = (yyvsp[(5) - (14)].str); + n->relation = (yyvsp[(7) - (14)].range); + n->accessMethod = (yyvsp[(8) - (14)].str); + n->indexParams = (yyvsp[(10) - (14)].list); + n->options = (yyvsp[(12) - (14)].list); + n->tableSpace = (yyvsp[(13) - (14)].str); + n->whereClause = (yyvsp[(14) - (14)].node); + n->excludeOpNames = NIL; + n->idxcomment = NULL; + n->indexOid = InvalidOid; + n->oldNode = InvalidOid; + n->primary = false; + n->isconstraint = false; + n->deferrable = false; + n->initdeferred = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 880: + +/* Line 1455 of yacc.c */ +#line 5854 "gram.y" + { (yyval.boolean) = TRUE; ;} + break; + + case 881: + +/* Line 1455 of yacc.c */ +#line 5855 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 882: + +/* Line 1455 of yacc.c */ +#line 5859 "gram.y" + { (yyval.boolean) = TRUE; ;} + break; + + case 883: + +/* Line 1455 of yacc.c */ +#line 5860 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 884: + +/* Line 1455 of yacc.c */ +#line 5864 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 885: + +/* Line 1455 of yacc.c */ +#line 5865 "gram.y" + { (yyval.str) = NULL; ;} + break; + + case 886: + +/* Line 1455 of yacc.c */ +#line 5869 "gram.y" + { (yyval.str) = (yyvsp[(2) - (2)].str); ;} + break; + + case 887: + +/* Line 1455 of yacc.c */ +#line 5870 "gram.y" + { (yyval.str) = DEFAULT_INDEX_TYPE; ;} + break; + + case 888: + +/* Line 1455 of yacc.c */ +#line 5873 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].ielem)); ;} + break; + + case 889: + +/* Line 1455 of yacc.c */ +#line 5874 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].ielem)); ;} + break; + + case 890: + +/* Line 1455 of yacc.c */ +#line 5883 "gram.y" + { + (yyval.ielem) = makeNode(IndexElem); + (yyval.ielem)->name = (yyvsp[(1) - (5)].str); + (yyval.ielem)->expr = NULL; + (yyval.ielem)->indexcolname = NULL; + (yyval.ielem)->collation = (yyvsp[(2) - (5)].list); + (yyval.ielem)->opclass = (yyvsp[(3) - (5)].list); + (yyval.ielem)->ordering = (yyvsp[(4) - (5)].ival); + (yyval.ielem)->nulls_ordering = (yyvsp[(5) - (5)].ival); + ;} + break; + + case 891: + +/* Line 1455 of yacc.c */ +#line 5894 "gram.y" + { + (yyval.ielem) = makeNode(IndexElem); + (yyval.ielem)->name = NULL; + (yyval.ielem)->expr = (yyvsp[(1) - (5)].node); + (yyval.ielem)->indexcolname = NULL; + (yyval.ielem)->collation = (yyvsp[(2) - (5)].list); + (yyval.ielem)->opclass = (yyvsp[(3) - (5)].list); + (yyval.ielem)->ordering = (yyvsp[(4) - (5)].ival); + (yyval.ielem)->nulls_ordering = (yyvsp[(5) - (5)].ival); + ;} + break; + + case 892: + +/* Line 1455 of yacc.c */ +#line 5905 "gram.y" + { + (yyval.ielem) = makeNode(IndexElem); + (yyval.ielem)->name = NULL; + (yyval.ielem)->expr = (yyvsp[(2) - (7)].node); + (yyval.ielem)->indexcolname = NULL; + (yyval.ielem)->collation = (yyvsp[(4) - (7)].list); + (yyval.ielem)->opclass = (yyvsp[(5) - (7)].list); + (yyval.ielem)->ordering = (yyvsp[(6) - (7)].ival); + (yyval.ielem)->nulls_ordering = (yyvsp[(7) - (7)].ival); + ;} + break; + + case 893: + +/* Line 1455 of yacc.c */ +#line 5917 "gram.y" + { (yyval.list) = (yyvsp[(2) - (2)].list); ;} + break; + + case 894: + +/* Line 1455 of yacc.c */ +#line 5918 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 895: + +/* Line 1455 of yacc.c */ +#line 5921 "gram.y" + { (yyval.list) = (yyvsp[(1) - (1)].list); ;} + break; + + case 896: + +/* Line 1455 of yacc.c */ +#line 5922 "gram.y" + { (yyval.list) = (yyvsp[(2) - (2)].list); ;} + break; + + case 897: + +/* Line 1455 of yacc.c */ +#line 5923 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 898: + +/* Line 1455 of yacc.c */ +#line 5926 "gram.y" + { (yyval.ival) = SORTBY_ASC; ;} + break; + + case 899: + +/* Line 1455 of yacc.c */ +#line 5927 "gram.y" + { (yyval.ival) = SORTBY_DESC; ;} + break; + + case 900: + +/* Line 1455 of yacc.c */ +#line 5928 "gram.y" + { (yyval.ival) = SORTBY_DEFAULT; ;} + break; + + case 901: + +/* Line 1455 of yacc.c */ +#line 5931 "gram.y" + { (yyval.ival) = SORTBY_NULLS_FIRST; ;} + break; + + case 902: + +/* Line 1455 of yacc.c */ +#line 5932 "gram.y" + { (yyval.ival) = SORTBY_NULLS_LAST; ;} + break; + + case 903: + +/* Line 1455 of yacc.c */ +#line 5933 "gram.y" + { (yyval.ival) = SORTBY_NULLS_DEFAULT; ;} + break; + + case 904: + +/* Line 1455 of yacc.c */ +#line 5951 "gram.y" + { + CreateFunctionStmt *n = makeNode(CreateFunctionStmt); + n->replace = (yyvsp[(2) - (9)].boolean); + n->funcname = (yyvsp[(4) - (9)].list); + n->parameters = (yyvsp[(5) - (9)].list); + n->returnType = (yyvsp[(7) - (9)].typnam); + n->options = (yyvsp[(8) - (9)].list); + n->withClause = (yyvsp[(9) - (9)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 905: + +/* Line 1455 of yacc.c */ +#line 5963 "gram.y" + { + CreateFunctionStmt *n = makeNode(CreateFunctionStmt); + n->replace = (yyvsp[(2) - (12)].boolean); + n->funcname = (yyvsp[(4) - (12)].list); + n->parameters = mergeTableFuncParameters((yyvsp[(5) - (12)].list), (yyvsp[(9) - (12)].list)); + n->returnType = TableFuncTypeName((yyvsp[(9) - (12)].list)); + n->returnType->location = (yylsp[(7) - (12)]); + n->options = (yyvsp[(11) - (12)].list); + n->withClause = (yyvsp[(12) - (12)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 906: + +/* Line 1455 of yacc.c */ +#line 5976 "gram.y" + { + CreateFunctionStmt *n = makeNode(CreateFunctionStmt); + n->replace = (yyvsp[(2) - (7)].boolean); + n->funcname = (yyvsp[(4) - (7)].list); + n->parameters = (yyvsp[(5) - (7)].list); + n->returnType = NULL; + n->options = (yyvsp[(6) - (7)].list); + n->withClause = (yyvsp[(7) - (7)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 907: + +/* Line 1455 of yacc.c */ +#line 5989 "gram.y" + { (yyval.boolean) = TRUE; ;} + break; + + case 908: + +/* Line 1455 of yacc.c */ +#line 5990 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 909: + +/* Line 1455 of yacc.c */ +#line 5993 "gram.y" + { (yyval.list) = (yyvsp[(2) - (3)].list); ;} + break; + + case 910: + +/* Line 1455 of yacc.c */ +#line 5994 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 911: + +/* Line 1455 of yacc.c */ +#line 5998 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].fun_param)); ;} + break; + + case 912: + +/* Line 1455 of yacc.c */ +#line 5999 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].fun_param)); ;} + break; + + case 913: + +/* Line 1455 of yacc.c */ +#line 6007 "gram.y" + { (yyval.list) = (yyvsp[(2) - (3)].list); ;} + break; + + case 914: + +/* Line 1455 of yacc.c */ +#line 6008 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 915: + +/* Line 1455 of yacc.c */ +#line 6012 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].fun_param)); ;} + break; + + case 916: + +/* Line 1455 of yacc.c */ +#line 6014 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].fun_param)); ;} + break; + + case 917: + +/* Line 1455 of yacc.c */ +#line 6029 "gram.y" + { + FunctionParameter *n = makeNode(FunctionParameter); + n->name = (yyvsp[(2) - (3)].str); + n->argType = (yyvsp[(3) - (3)].typnam); + n->mode = (yyvsp[(1) - (3)].fun_param_mode); + n->defexpr = NULL; + (yyval.fun_param) = n; + ;} + break; + + case 918: + +/* Line 1455 of yacc.c */ +#line 6038 "gram.y" + { + FunctionParameter *n = makeNode(FunctionParameter); + n->name = (yyvsp[(1) - (3)].str); + n->argType = (yyvsp[(3) - (3)].typnam); + n->mode = (yyvsp[(2) - (3)].fun_param_mode); + n->defexpr = NULL; + (yyval.fun_param) = n; + ;} + break; + + case 919: + +/* Line 1455 of yacc.c */ +#line 6047 "gram.y" + { + FunctionParameter *n = makeNode(FunctionParameter); + n->name = (yyvsp[(1) - (2)].str); + n->argType = (yyvsp[(2) - (2)].typnam); + n->mode = FUNC_PARAM_IN; + n->defexpr = NULL; + (yyval.fun_param) = n; + ;} + break; + + case 920: + +/* Line 1455 of yacc.c */ +#line 6056 "gram.y" + { + FunctionParameter *n = makeNode(FunctionParameter); + n->name = NULL; + n->argType = (yyvsp[(2) - (2)].typnam); + n->mode = (yyvsp[(1) - (2)].fun_param_mode); + n->defexpr = NULL; + (yyval.fun_param) = n; + ;} + break; + + case 921: + +/* Line 1455 of yacc.c */ +#line 6065 "gram.y" + { + FunctionParameter *n = makeNode(FunctionParameter); + n->name = NULL; + n->argType = (yyvsp[(1) - (1)].typnam); + n->mode = FUNC_PARAM_IN; + n->defexpr = NULL; + (yyval.fun_param) = n; + ;} + break; + + case 922: + +/* Line 1455 of yacc.c */ +#line 6076 "gram.y" + { (yyval.fun_param_mode) = FUNC_PARAM_IN; ;} + break; + + case 923: + +/* Line 1455 of yacc.c */ +#line 6077 "gram.y" + { (yyval.fun_param_mode) = FUNC_PARAM_OUT; ;} + break; + + case 924: + +/* Line 1455 of yacc.c */ +#line 6078 "gram.y" + { (yyval.fun_param_mode) = FUNC_PARAM_INOUT; ;} + break; + + case 925: + +/* Line 1455 of yacc.c */ +#line 6079 "gram.y" + { (yyval.fun_param_mode) = FUNC_PARAM_INOUT; ;} + break; + + case 926: + +/* Line 1455 of yacc.c */ +#line 6080 "gram.y" + { (yyval.fun_param_mode) = FUNC_PARAM_VARIADIC; ;} + break; + + case 928: + +/* Line 1455 of yacc.c */ +#line 6091 "gram.y" + { + /* We can catch over-specified results here if we want to, + * but for now better to silently swallow typmod, etc. + * - thomas 2000-03-22 + */ + (yyval.typnam) = (yyvsp[(1) - (1)].typnam); + ;} + break; + + case 929: + +/* Line 1455 of yacc.c */ +#line 6105 "gram.y" + { (yyval.typnam) = (yyvsp[(1) - (1)].typnam); ;} + break; + + case 930: + +/* Line 1455 of yacc.c */ +#line 6107 "gram.y" + { + (yyval.typnam) = makeTypeNameFromNameList(lcons(makeString((yyvsp[(1) - (4)].str)), (yyvsp[(2) - (4)].list))); + (yyval.typnam)->pct_type = true; + (yyval.typnam)->location = (yylsp[(1) - (4)]); + ;} + break; + + case 931: + +/* Line 1455 of yacc.c */ +#line 6113 "gram.y" + { + (yyval.typnam) = makeTypeNameFromNameList(lcons(makeString((yyvsp[(2) - (5)].str)), (yyvsp[(3) - (5)].list))); + (yyval.typnam)->pct_type = true; + (yyval.typnam)->setof = TRUE; + (yyval.typnam)->location = (yylsp[(2) - (5)]); + ;} + break; + + case 932: + +/* Line 1455 of yacc.c */ +#line 6123 "gram.y" + { + (yyval.fun_param) = (yyvsp[(1) - (1)].fun_param); + ;} + break; + + case 933: + +/* Line 1455 of yacc.c */ +#line 6127 "gram.y" + { + (yyval.fun_param) = (yyvsp[(1) - (3)].fun_param); + (yyval.fun_param)->defexpr = (yyvsp[(3) - (3)].node); + ;} + break; + + case 934: + +/* Line 1455 of yacc.c */ +#line 6132 "gram.y" + { + (yyval.fun_param) = (yyvsp[(1) - (3)].fun_param); + (yyval.fun_param)->defexpr = (yyvsp[(3) - (3)].node); + ;} + break; + + case 935: + +/* Line 1455 of yacc.c */ +#line 6141 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].defelt)); ;} + break; + + case 936: + +/* Line 1455 of yacc.c */ +#line 6142 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (2)].list), (yyvsp[(2) - (2)].defelt)); ;} + break; + + case 937: + +/* Line 1455 of yacc.c */ +#line 6150 "gram.y" + { + (yyval.defelt) = makeDefElem("strict", (Node *)makeInteger(FALSE)); + ;} + break; + + case 938: + +/* Line 1455 of yacc.c */ +#line 6154 "gram.y" + { + (yyval.defelt) = makeDefElem("strict", (Node *)makeInteger(TRUE)); + ;} + break; + + case 939: + +/* Line 1455 of yacc.c */ +#line 6158 "gram.y" + { + (yyval.defelt) = makeDefElem("strict", (Node *)makeInteger(TRUE)); + ;} + break; + + case 940: + +/* Line 1455 of yacc.c */ +#line 6162 "gram.y" + { + (yyval.defelt) = makeDefElem("volatility", (Node *)makeString("immutable")); + ;} + break; + + case 941: + +/* Line 1455 of yacc.c */ +#line 6166 "gram.y" + { + (yyval.defelt) = makeDefElem("volatility", (Node *)makeString("stable")); + ;} + break; + + case 942: + +/* Line 1455 of yacc.c */ +#line 6170 "gram.y" + { + (yyval.defelt) = makeDefElem("volatility", (Node *)makeString("volatile")); + ;} + break; + + case 943: + +/* Line 1455 of yacc.c */ +#line 6174 "gram.y" + { + (yyval.defelt) = makeDefElem("security", (Node *)makeInteger(TRUE)); + ;} + break; + + case 944: + +/* Line 1455 of yacc.c */ +#line 6178 "gram.y" + { + (yyval.defelt) = makeDefElem("security", (Node *)makeInteger(FALSE)); + ;} + break; + + case 945: + +/* Line 1455 of yacc.c */ +#line 6182 "gram.y" + { + (yyval.defelt) = makeDefElem("security", (Node *)makeInteger(TRUE)); + ;} + break; + + case 946: + +/* Line 1455 of yacc.c */ +#line 6186 "gram.y" + { + (yyval.defelt) = makeDefElem("security", (Node *)makeInteger(FALSE)); + ;} + break; + + case 947: + +/* Line 1455 of yacc.c */ +#line 6190 "gram.y" + { + (yyval.defelt) = makeDefElem("leakproof", (Node *)makeInteger(TRUE)); + ;} + break; + + case 948: + +/* Line 1455 of yacc.c */ +#line 6194 "gram.y" + { + (yyval.defelt) = makeDefElem("leakproof", (Node *)makeInteger(FALSE)); + ;} + break; + + case 949: + +/* Line 1455 of yacc.c */ +#line 6198 "gram.y" + { + (yyval.defelt) = makeDefElem("cost", (Node *)(yyvsp[(2) - (2)].value)); + ;} + break; + + case 950: + +/* Line 1455 of yacc.c */ +#line 6202 "gram.y" + { + (yyval.defelt) = makeDefElem("rows", (Node *)(yyvsp[(2) - (2)].value)); + ;} + break; + + case 951: + +/* Line 1455 of yacc.c */ +#line 6206 "gram.y" + { + /* we abuse the normal content of a DefElem here */ + (yyval.defelt) = makeDefElem("set", (Node *)(yyvsp[(1) - (1)].vsetstmt)); + ;} + break; + + case 952: + +/* Line 1455 of yacc.c */ +#line 6214 "gram.y" + { + (yyval.defelt) = makeDefElem("as", (Node *)(yyvsp[(2) - (2)].list)); + ;} + break; + + case 953: + +/* Line 1455 of yacc.c */ +#line 6218 "gram.y" + { + (yyval.defelt) = makeDefElem("language", (Node *)makeString((yyvsp[(2) - (2)].str))); + ;} + break; + + case 954: + +/* Line 1455 of yacc.c */ +#line 6222 "gram.y" + { + (yyval.defelt) = makeDefElem("window", (Node *)makeInteger(TRUE)); + ;} + break; + + case 955: + +/* Line 1455 of yacc.c */ +#line 6226 "gram.y" + { + (yyval.defelt) = (yyvsp[(1) - (1)].defelt); + ;} + break; + + case 956: + +/* Line 1455 of yacc.c */ +#line 6231 "gram.y" + { (yyval.list) = list_make1(makeString((yyvsp[(1) - (1)].str))); ;} + break; + + case 957: + +/* Line 1455 of yacc.c */ +#line 6233 "gram.y" + { + (yyval.list) = list_make2(makeString((yyvsp[(1) - (3)].str)), makeString((yyvsp[(3) - (3)].str))); + ;} + break; + + case 958: + +/* Line 1455 of yacc.c */ +#line 6239 "gram.y" + { (yyval.list) = (yyvsp[(2) - (2)].list); ;} + break; + + case 959: + +/* Line 1455 of yacc.c */ +#line 6240 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 960: + +/* Line 1455 of yacc.c */ +#line 6244 "gram.y" + { + FunctionParameter *n = makeNode(FunctionParameter); + n->name = (yyvsp[(1) - (2)].str); + n->argType = (yyvsp[(2) - (2)].typnam); + n->mode = FUNC_PARAM_TABLE; + n->defexpr = NULL; + (yyval.fun_param) = n; + ;} + break; + + case 961: + +/* Line 1455 of yacc.c */ +#line 6256 "gram.y" + { + (yyval.list) = list_make1((yyvsp[(1) - (1)].fun_param)); + ;} + break; + + case 962: + +/* Line 1455 of yacc.c */ +#line 6260 "gram.y" + { + (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].fun_param)); + ;} + break; + + case 963: + +/* Line 1455 of yacc.c */ +#line 6275 "gram.y" + { + AlterFunctionStmt *n = makeNode(AlterFunctionStmt); + n->func = (yyvsp[(3) - (5)].funwithargs); + n->actions = (yyvsp[(4) - (5)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 964: + +/* Line 1455 of yacc.c */ +#line 6285 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].defelt)); ;} + break; + + case 965: + +/* Line 1455 of yacc.c */ +#line 6286 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (2)].list), (yyvsp[(2) - (2)].defelt)); ;} + break; + + case 968: + +/* Line 1455 of yacc.c */ +#line 6308 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->removeType = OBJECT_FUNCTION; + n->objects = list_make1((yyvsp[(3) - (5)].list)); + n->arguments = list_make1(extractArgTypes((yyvsp[(4) - (5)].list))); + n->behavior = (yyvsp[(5) - (5)].dbehavior); + n->missing_ok = false; + n->concurrent = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 969: + +/* Line 1455 of yacc.c */ +#line 6319 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->removeType = OBJECT_FUNCTION; + n->objects = list_make1((yyvsp[(5) - (7)].list)); + n->arguments = list_make1(extractArgTypes((yyvsp[(6) - (7)].list))); + n->behavior = (yyvsp[(7) - (7)].dbehavior); + n->missing_ok = true; + n->concurrent = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 970: + +/* Line 1455 of yacc.c */ +#line 6333 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->removeType = OBJECT_AGGREGATE; + n->objects = list_make1((yyvsp[(3) - (5)].list)); + n->arguments = list_make1((yyvsp[(4) - (5)].list)); + n->behavior = (yyvsp[(5) - (5)].dbehavior); + n->missing_ok = false; + n->concurrent = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 971: + +/* Line 1455 of yacc.c */ +#line 6344 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->removeType = OBJECT_AGGREGATE; + n->objects = list_make1((yyvsp[(5) - (7)].list)); + n->arguments = list_make1((yyvsp[(6) - (7)].list)); + n->behavior = (yyvsp[(7) - (7)].dbehavior); + n->missing_ok = true; + n->concurrent = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 972: + +/* Line 1455 of yacc.c */ +#line 6358 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->removeType = OBJECT_OPERATOR; + n->objects = list_make1((yyvsp[(3) - (5)].list)); + n->arguments = list_make1((yyvsp[(4) - (5)].list)); + n->behavior = (yyvsp[(5) - (5)].dbehavior); + n->missing_ok = false; + n->concurrent = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 973: + +/* Line 1455 of yacc.c */ +#line 6369 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->removeType = OBJECT_OPERATOR; + n->objects = list_make1((yyvsp[(5) - (7)].list)); + n->arguments = list_make1((yyvsp[(6) - (7)].list)); + n->behavior = (yyvsp[(7) - (7)].dbehavior); + n->missing_ok = true; + n->concurrent = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 974: + +/* Line 1455 of yacc.c */ +#line 6383 "gram.y" + { + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("missing argument"), + errhint("Use NONE to denote the missing argument of a unary operator."), + parser_errposition((yylsp[(3) - (3)])))); + ;} + break; + + case 975: + +/* Line 1455 of yacc.c */ +#line 6391 "gram.y" + { (yyval.list) = list_make2((yyvsp[(2) - (5)].typnam), (yyvsp[(4) - (5)].typnam)); ;} + break; + + case 976: + +/* Line 1455 of yacc.c */ +#line 6393 "gram.y" + { (yyval.list) = list_make2(NULL, (yyvsp[(4) - (5)].typnam)); ;} + break; + + case 977: + +/* Line 1455 of yacc.c */ +#line 6395 "gram.y" + { (yyval.list) = list_make2((yyvsp[(2) - (5)].typnam), NULL); ;} + break; + + case 978: + +/* Line 1455 of yacc.c */ +#line 6400 "gram.y" + { (yyval.list) = list_make1(makeString((yyvsp[(1) - (1)].str))); ;} + break; + + case 979: + +/* Line 1455 of yacc.c */ +#line 6402 "gram.y" + { (yyval.list) = lcons(makeString((yyvsp[(1) - (3)].str)), (yyvsp[(3) - (3)].list)); ;} + break; + + case 980: + +/* Line 1455 of yacc.c */ +#line 6415 "gram.y" + { + DoStmt *n = makeNode(DoStmt); + n->args = (yyvsp[(2) - (2)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 981: + +/* Line 1455 of yacc.c */ +#line 6423 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].defelt)); ;} + break; + + case 982: + +/* Line 1455 of yacc.c */ +#line 6424 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (2)].list), (yyvsp[(2) - (2)].defelt)); ;} + break; + + case 983: + +/* Line 1455 of yacc.c */ +#line 6429 "gram.y" + { + (yyval.defelt) = makeDefElem("as", (Node *)makeString((yyvsp[(1) - (1)].str))); + ;} + break; + + case 984: + +/* Line 1455 of yacc.c */ +#line 6433 "gram.y" + { + (yyval.defelt) = makeDefElem("language", (Node *)makeString((yyvsp[(2) - (2)].str))); + ;} + break; + + case 985: + +/* Line 1455 of yacc.c */ +#line 6446 "gram.y" + { + CreateCastStmt *n = makeNode(CreateCastStmt); + n->sourcetype = (yyvsp[(4) - (11)].typnam); + n->targettype = (yyvsp[(6) - (11)].typnam); + n->func = (yyvsp[(10) - (11)].funwithargs); + n->context = (CoercionContext) (yyvsp[(11) - (11)].ival); + n->inout = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 986: + +/* Line 1455 of yacc.c */ +#line 6457 "gram.y" + { + CreateCastStmt *n = makeNode(CreateCastStmt); + n->sourcetype = (yyvsp[(4) - (10)].typnam); + n->targettype = (yyvsp[(6) - (10)].typnam); + n->func = NULL; + n->context = (CoercionContext) (yyvsp[(10) - (10)].ival); + n->inout = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 987: + +/* Line 1455 of yacc.c */ +#line 6468 "gram.y" + { + CreateCastStmt *n = makeNode(CreateCastStmt); + n->sourcetype = (yyvsp[(4) - (10)].typnam); + n->targettype = (yyvsp[(6) - (10)].typnam); + n->func = NULL; + n->context = (CoercionContext) (yyvsp[(10) - (10)].ival); + n->inout = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 988: + +/* Line 1455 of yacc.c */ +#line 6479 "gram.y" + { (yyval.ival) = COERCION_IMPLICIT; ;} + break; + + case 989: + +/* Line 1455 of yacc.c */ +#line 6480 "gram.y" + { (yyval.ival) = COERCION_ASSIGNMENT; ;} + break; + + case 990: + +/* Line 1455 of yacc.c */ +#line 6481 "gram.y" + { (yyval.ival) = COERCION_EXPLICIT; ;} + break; + + case 991: + +/* Line 1455 of yacc.c */ +#line 6486 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->removeType = OBJECT_CAST; + n->objects = list_make1(list_make1((yyvsp[(5) - (9)].typnam))); + n->arguments = list_make1(list_make1((yyvsp[(7) - (9)].typnam))); + n->behavior = (yyvsp[(9) - (9)].dbehavior); + n->missing_ok = (yyvsp[(3) - (9)].boolean); + n->concurrent = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 992: + +/* Line 1455 of yacc.c */ +#line 6498 "gram.y" + { (yyval.boolean) = TRUE; ;} + break; + + case 993: + +/* Line 1455 of yacc.c */ +#line 6499 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 994: + +/* Line 1455 of yacc.c */ +#line 6514 "gram.y" + { + ReindexStmt *n = makeNode(ReindexStmt); + n->kind = (yyvsp[(2) - (4)].objtype); + n->relation = (yyvsp[(3) - (4)].range); + n->name = NULL; + (yyval.node) = (Node *)n; + ;} + break; + + case 995: + +/* Line 1455 of yacc.c */ +#line 6522 "gram.y" + { + ReindexStmt *n = makeNode(ReindexStmt); + n->kind = OBJECT_DATABASE; + n->name = (yyvsp[(3) - (4)].str); + n->relation = NULL; + n->do_system = true; + n->do_user = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 996: + +/* Line 1455 of yacc.c */ +#line 6532 "gram.y" + { + ReindexStmt *n = makeNode(ReindexStmt); + n->kind = OBJECT_DATABASE; + n->name = (yyvsp[(3) - (4)].str); + n->relation = NULL; + n->do_system = true; + n->do_user = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 997: + +/* Line 1455 of yacc.c */ +#line 6544 "gram.y" + { (yyval.objtype) = OBJECT_INDEX; ;} + break; + + case 998: + +/* Line 1455 of yacc.c */ +#line 6545 "gram.y" + { (yyval.objtype) = OBJECT_TABLE; ;} + break; + + case 999: + +/* Line 1455 of yacc.c */ +#line 6548 "gram.y" + { (yyval.boolean) = TRUE; ;} + break; + + case 1000: + +/* Line 1455 of yacc.c */ +#line 6549 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 1001: + +/* Line 1455 of yacc.c */ +#line 6560 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_AGGREGATE; + n->object = (yyvsp[(3) - (7)].list); + n->objarg = (yyvsp[(4) - (7)].list); + n->newname = (yyvsp[(7) - (7)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1002: + +/* Line 1455 of yacc.c */ +#line 6570 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_COLLATION; + n->object = (yyvsp[(3) - (6)].list); + n->newname = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1003: + +/* Line 1455 of yacc.c */ +#line 6579 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_CONVERSION; + n->object = (yyvsp[(3) - (6)].list); + n->newname = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1004: + +/* Line 1455 of yacc.c */ +#line 6588 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_DATABASE; + n->subname = (yyvsp[(3) - (6)].str); + n->newname = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1005: + +/* Line 1455 of yacc.c */ +#line 6597 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_DOMAIN; + n->object = (yyvsp[(3) - (6)].list); + n->newname = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1006: + +/* Line 1455 of yacc.c */ +#line 6606 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_CONSTRAINT; + n->relationType = OBJECT_DOMAIN; + n->object = (yyvsp[(3) - (8)].list); + n->subname = (yyvsp[(6) - (8)].str); + n->newname = (yyvsp[(8) - (8)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1007: + +/* Line 1455 of yacc.c */ +#line 6616 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_FDW; + n->subname = (yyvsp[(5) - (8)].str); + n->newname = (yyvsp[(8) - (8)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1008: + +/* Line 1455 of yacc.c */ +#line 6625 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_FUNCTION; + n->object = (yyvsp[(3) - (6)].funwithargs)->funcname; + n->objarg = (yyvsp[(3) - (6)].funwithargs)->funcargs; + n->newname = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1009: + +/* Line 1455 of yacc.c */ +#line 6635 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_ROLE; + n->subname = (yyvsp[(3) - (6)].str); + n->newname = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1010: + +/* Line 1455 of yacc.c */ +#line 6644 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_LANGUAGE; + n->subname = (yyvsp[(4) - (7)].str); + n->newname = (yyvsp[(7) - (7)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1011: + +/* Line 1455 of yacc.c */ +#line 6653 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_OPCLASS; + n->object = (yyvsp[(4) - (9)].list); + n->subname = (yyvsp[(6) - (9)].str); + n->newname = (yyvsp[(9) - (9)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1012: + +/* Line 1455 of yacc.c */ +#line 6663 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_OPFAMILY; + n->object = (yyvsp[(4) - (9)].list); + n->subname = (yyvsp[(6) - (9)].str); + n->newname = (yyvsp[(9) - (9)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1013: + +/* Line 1455 of yacc.c */ +#line 6673 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_SCHEMA; + n->subname = (yyvsp[(3) - (6)].str); + n->newname = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1014: + +/* Line 1455 of yacc.c */ +#line 6682 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_FOREIGN_SERVER; + n->subname = (yyvsp[(3) - (6)].str); + n->newname = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1015: + +/* Line 1455 of yacc.c */ +#line 6691 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_TABLE; + n->relation = (yyvsp[(3) - (6)].range); + n->subname = NULL; + n->newname = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1016: + +/* Line 1455 of yacc.c */ +#line 6701 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_TABLE; + n->relation = (yyvsp[(5) - (8)].range); + n->subname = NULL; + n->newname = (yyvsp[(8) - (8)].str); + n->missing_ok = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 1017: + +/* Line 1455 of yacc.c */ +#line 6711 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_SEQUENCE; + n->relation = (yyvsp[(3) - (6)].range); + n->subname = NULL; + n->newname = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1018: + +/* Line 1455 of yacc.c */ +#line 6721 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_SEQUENCE; + n->relation = (yyvsp[(5) - (8)].range); + n->subname = NULL; + n->newname = (yyvsp[(8) - (8)].str); + n->missing_ok = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 1019: + +/* Line 1455 of yacc.c */ +#line 6731 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_VIEW; + n->relation = (yyvsp[(3) - (6)].range); + n->subname = NULL; + n->newname = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1020: + +/* Line 1455 of yacc.c */ +#line 6741 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_VIEW; + n->relation = (yyvsp[(5) - (8)].range); + n->subname = NULL; + n->newname = (yyvsp[(8) - (8)].str); + n->missing_ok = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 1021: + +/* Line 1455 of yacc.c */ +#line 6751 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_INDEX; + n->relation = (yyvsp[(3) - (6)].range); + n->subname = NULL; + n->newname = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1022: + +/* Line 1455 of yacc.c */ +#line 6761 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_INDEX; + n->relation = (yyvsp[(5) - (8)].range); + n->subname = NULL; + n->newname = (yyvsp[(8) - (8)].str); + n->missing_ok = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 1023: + +/* Line 1455 of yacc.c */ +#line 6771 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_FOREIGN_TABLE; + n->relation = (yyvsp[(4) - (7)].range); + n->subname = NULL; + n->newname = (yyvsp[(7) - (7)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1024: + +/* Line 1455 of yacc.c */ +#line 6781 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_FOREIGN_TABLE; + n->relation = (yyvsp[(6) - (9)].range); + n->subname = NULL; + n->newname = (yyvsp[(9) - (9)].str); + n->missing_ok = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 1025: + +/* Line 1455 of yacc.c */ +#line 6791 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_COLUMN; + n->relationType = OBJECT_TABLE; + n->relation = (yyvsp[(3) - (8)].range); + n->subname = (yyvsp[(6) - (8)].str); + n->newname = (yyvsp[(8) - (8)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1026: + +/* Line 1455 of yacc.c */ +#line 6802 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_COLUMN; + n->relationType = OBJECT_TABLE; + n->relation = (yyvsp[(5) - (10)].range); + n->subname = (yyvsp[(8) - (10)].str); + n->newname = (yyvsp[(10) - (10)].str); + n->missing_ok = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 1027: + +/* Line 1455 of yacc.c */ +#line 6813 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_CONSTRAINT; + n->relationType = OBJECT_TABLE; + n->relation = (yyvsp[(3) - (8)].range); + n->subname = (yyvsp[(6) - (8)].str); + n->newname = (yyvsp[(8) - (8)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1028: + +/* Line 1455 of yacc.c */ +#line 6823 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_COLUMN; + n->relationType = OBJECT_FOREIGN_TABLE; + n->relation = (yyvsp[(4) - (9)].range); + n->subname = (yyvsp[(7) - (9)].str); + n->newname = (yyvsp[(9) - (9)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1029: + +/* Line 1455 of yacc.c */ +#line 6834 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_COLUMN; + n->relationType = OBJECT_FOREIGN_TABLE; + n->relation = (yyvsp[(6) - (11)].range); + n->subname = (yyvsp[(9) - (11)].str); + n->newname = (yyvsp[(11) - (11)].str); + n->missing_ok = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 1030: + +/* Line 1455 of yacc.c */ +#line 6845 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_TRIGGER; + n->relation = (yyvsp[(5) - (8)].range); + n->subname = (yyvsp[(3) - (8)].str); + n->newname = (yyvsp[(8) - (8)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1031: + +/* Line 1455 of yacc.c */ +#line 6855 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_ROLE; + n->subname = (yyvsp[(3) - (6)].str); + n->newname = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1032: + +/* Line 1455 of yacc.c */ +#line 6864 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_ROLE; + n->subname = (yyvsp[(3) - (6)].str); + n->newname = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1033: + +/* Line 1455 of yacc.c */ +#line 6873 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_TABLESPACE; + n->subname = (yyvsp[(3) - (6)].str); + n->newname = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1034: + +/* Line 1455 of yacc.c */ +#line 6882 "gram.y" + { + AlterTableSpaceOptionsStmt *n = + makeNode(AlterTableSpaceOptionsStmt); + n->tablespacename = (yyvsp[(3) - (5)].str); + n->options = (yyvsp[(5) - (5)].list); + n->isReset = FALSE; + (yyval.node) = (Node *)n; + ;} + break; + + case 1035: + +/* Line 1455 of yacc.c */ +#line 6891 "gram.y" + { + AlterTableSpaceOptionsStmt *n = + makeNode(AlterTableSpaceOptionsStmt); + n->tablespacename = (yyvsp[(3) - (5)].str); + n->options = (yyvsp[(5) - (5)].list); + n->isReset = TRUE; + (yyval.node) = (Node *)n; + ;} + break; + + case 1036: + +/* Line 1455 of yacc.c */ +#line 6900 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_TSPARSER; + n->object = (yyvsp[(5) - (8)].list); + n->newname = (yyvsp[(8) - (8)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1037: + +/* Line 1455 of yacc.c */ +#line 6909 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_TSDICTIONARY; + n->object = (yyvsp[(5) - (8)].list); + n->newname = (yyvsp[(8) - (8)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1038: + +/* Line 1455 of yacc.c */ +#line 6918 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_TSTEMPLATE; + n->object = (yyvsp[(5) - (8)].list); + n->newname = (yyvsp[(8) - (8)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1039: + +/* Line 1455 of yacc.c */ +#line 6927 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_TSCONFIGURATION; + n->object = (yyvsp[(5) - (8)].list); + n->newname = (yyvsp[(8) - (8)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1040: + +/* Line 1455 of yacc.c */ +#line 6936 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_TYPE; + n->object = (yyvsp[(3) - (6)].list); + n->newname = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1041: + +/* Line 1455 of yacc.c */ +#line 6945 "gram.y" + { + RenameStmt *n = makeNode(RenameStmt); + n->renameType = OBJECT_ATTRIBUTE; + n->relationType = OBJECT_TYPE; + n->relation = makeRangeVarFromAnyName((yyvsp[(3) - (9)].list), (yylsp[(3) - (9)]), yyscanner); + n->subname = (yyvsp[(6) - (9)].str); + n->newname = (yyvsp[(8) - (9)].str); + n->behavior = (yyvsp[(9) - (9)].dbehavior); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1042: + +/* Line 1455 of yacc.c */ +#line 6958 "gram.y" + { (yyval.ival) = COLUMN; ;} + break; + + case 1043: + +/* Line 1455 of yacc.c */ +#line 6959 "gram.y" + { (yyval.ival) = 0; ;} + break; + + case 1044: + +/* Line 1455 of yacc.c */ +#line 6962 "gram.y" + { (yyval.ival) = 1; ;} + break; + + case 1045: + +/* Line 1455 of yacc.c */ +#line 6963 "gram.y" + { (yyval.ival) = 0; ;} + break; + + case 1046: + +/* Line 1455 of yacc.c */ +#line 6974 "gram.y" + { + AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt); + n->objectType = OBJECT_AGGREGATE; + n->object = (yyvsp[(3) - (7)].list); + n->objarg = (yyvsp[(4) - (7)].list); + n->newschema = (yyvsp[(7) - (7)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1047: + +/* Line 1455 of yacc.c */ +#line 6984 "gram.y" + { + AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt); + n->objectType = OBJECT_COLLATION; + n->object = (yyvsp[(3) - (6)].list); + n->newschema = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1048: + +/* Line 1455 of yacc.c */ +#line 6993 "gram.y" + { + AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt); + n->objectType = OBJECT_CONVERSION; + n->object = (yyvsp[(3) - (6)].list); + n->newschema = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1049: + +/* Line 1455 of yacc.c */ +#line 7002 "gram.y" + { + AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt); + n->objectType = OBJECT_DOMAIN; + n->object = (yyvsp[(3) - (6)].list); + n->newschema = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1050: + +/* Line 1455 of yacc.c */ +#line 7011 "gram.y" + { + AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt); + n->objectType = OBJECT_EXTENSION; + n->object = (yyvsp[(3) - (6)].list); + n->newschema = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1051: + +/* Line 1455 of yacc.c */ +#line 7020 "gram.y" + { + AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt); + n->objectType = OBJECT_FUNCTION; + n->object = (yyvsp[(3) - (6)].funwithargs)->funcname; + n->objarg = (yyvsp[(3) - (6)].funwithargs)->funcargs; + n->newschema = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1052: + +/* Line 1455 of yacc.c */ +#line 7030 "gram.y" + { + AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt); + n->objectType = OBJECT_OPERATOR; + n->object = (yyvsp[(3) - (7)].list); + n->objarg = (yyvsp[(4) - (7)].list); + n->newschema = (yyvsp[(7) - (7)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1053: + +/* Line 1455 of yacc.c */ +#line 7040 "gram.y" + { + AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt); + n->objectType = OBJECT_OPCLASS; + n->object = (yyvsp[(4) - (9)].list); + n->addname = (yyvsp[(6) - (9)].str); + n->newschema = (yyvsp[(9) - (9)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1054: + +/* Line 1455 of yacc.c */ +#line 7050 "gram.y" + { + AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt); + n->objectType = OBJECT_OPFAMILY; + n->object = (yyvsp[(4) - (9)].list); + n->addname = (yyvsp[(6) - (9)].str); + n->newschema = (yyvsp[(9) - (9)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1055: + +/* Line 1455 of yacc.c */ +#line 7060 "gram.y" + { + AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt); + n->objectType = OBJECT_TABLE; + n->relation = (yyvsp[(3) - (6)].range); + n->newschema = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1056: + +/* Line 1455 of yacc.c */ +#line 7069 "gram.y" + { + AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt); + n->objectType = OBJECT_TABLE; + n->relation = (yyvsp[(5) - (8)].range); + n->newschema = (yyvsp[(8) - (8)].str); + n->missing_ok = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 1057: + +/* Line 1455 of yacc.c */ +#line 7078 "gram.y" + { + AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt); + n->objectType = OBJECT_TSPARSER; + n->object = (yyvsp[(5) - (8)].list); + n->newschema = (yyvsp[(8) - (8)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1058: + +/* Line 1455 of yacc.c */ +#line 7087 "gram.y" + { + AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt); + n->objectType = OBJECT_TSDICTIONARY; + n->object = (yyvsp[(5) - (8)].list); + n->newschema = (yyvsp[(8) - (8)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1059: + +/* Line 1455 of yacc.c */ +#line 7096 "gram.y" + { + AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt); + n->objectType = OBJECT_TSTEMPLATE; + n->object = (yyvsp[(5) - (8)].list); + n->newschema = (yyvsp[(8) - (8)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1060: + +/* Line 1455 of yacc.c */ +#line 7105 "gram.y" + { + AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt); + n->objectType = OBJECT_TSCONFIGURATION; + n->object = (yyvsp[(5) - (8)].list); + n->newschema = (yyvsp[(8) - (8)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1061: + +/* Line 1455 of yacc.c */ +#line 7114 "gram.y" + { + AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt); + n->objectType = OBJECT_SEQUENCE; + n->relation = (yyvsp[(3) - (6)].range); + n->newschema = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1062: + +/* Line 1455 of yacc.c */ +#line 7123 "gram.y" + { + AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt); + n->objectType = OBJECT_SEQUENCE; + n->relation = (yyvsp[(5) - (8)].range); + n->newschema = (yyvsp[(8) - (8)].str); + n->missing_ok = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 1063: + +/* Line 1455 of yacc.c */ +#line 7132 "gram.y" + { + AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt); + n->objectType = OBJECT_VIEW; + n->relation = (yyvsp[(3) - (6)].range); + n->newschema = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1064: + +/* Line 1455 of yacc.c */ +#line 7141 "gram.y" + { + AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt); + n->objectType = OBJECT_VIEW; + n->relation = (yyvsp[(5) - (8)].range); + n->newschema = (yyvsp[(8) - (8)].str); + n->missing_ok = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 1065: + +/* Line 1455 of yacc.c */ +#line 7150 "gram.y" + { + AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt); + n->objectType = OBJECT_FOREIGN_TABLE; + n->relation = (yyvsp[(4) - (7)].range); + n->newschema = (yyvsp[(7) - (7)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1066: + +/* Line 1455 of yacc.c */ +#line 7159 "gram.y" + { + AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt); + n->objectType = OBJECT_FOREIGN_TABLE; + n->relation = (yyvsp[(6) - (9)].range); + n->newschema = (yyvsp[(9) - (9)].str); + n->missing_ok = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 1067: + +/* Line 1455 of yacc.c */ +#line 7168 "gram.y" + { + AlterObjectSchemaStmt *n = makeNode(AlterObjectSchemaStmt); + n->objectType = OBJECT_TYPE; + n->object = (yyvsp[(3) - (6)].list); + n->newschema = (yyvsp[(6) - (6)].str); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1068: + +/* Line 1455 of yacc.c */ +#line 7185 "gram.y" + { + AlterOwnerStmt *n = makeNode(AlterOwnerStmt); + n->objectType = OBJECT_AGGREGATE; + n->object = (yyvsp[(3) - (7)].list); + n->objarg = (yyvsp[(4) - (7)].list); + n->newowner = (yyvsp[(7) - (7)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1069: + +/* Line 1455 of yacc.c */ +#line 7194 "gram.y" + { + AlterOwnerStmt *n = makeNode(AlterOwnerStmt); + n->objectType = OBJECT_COLLATION; + n->object = (yyvsp[(3) - (6)].list); + n->newowner = (yyvsp[(6) - (6)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1070: + +/* Line 1455 of yacc.c */ +#line 7202 "gram.y" + { + AlterOwnerStmt *n = makeNode(AlterOwnerStmt); + n->objectType = OBJECT_CONVERSION; + n->object = (yyvsp[(3) - (6)].list); + n->newowner = (yyvsp[(6) - (6)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1071: + +/* Line 1455 of yacc.c */ +#line 7210 "gram.y" + { + AlterOwnerStmt *n = makeNode(AlterOwnerStmt); + n->objectType = OBJECT_DATABASE; + n->object = list_make1(makeString((yyvsp[(3) - (6)].str))); + n->newowner = (yyvsp[(6) - (6)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1072: + +/* Line 1455 of yacc.c */ +#line 7218 "gram.y" + { + AlterOwnerStmt *n = makeNode(AlterOwnerStmt); + n->objectType = OBJECT_DOMAIN; + n->object = (yyvsp[(3) - (6)].list); + n->newowner = (yyvsp[(6) - (6)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1073: + +/* Line 1455 of yacc.c */ +#line 7226 "gram.y" + { + AlterOwnerStmt *n = makeNode(AlterOwnerStmt); + n->objectType = OBJECT_FUNCTION; + n->object = (yyvsp[(3) - (6)].funwithargs)->funcname; + n->objarg = (yyvsp[(3) - (6)].funwithargs)->funcargs; + n->newowner = (yyvsp[(6) - (6)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1074: + +/* Line 1455 of yacc.c */ +#line 7235 "gram.y" + { + AlterOwnerStmt *n = makeNode(AlterOwnerStmt); + n->objectType = OBJECT_LANGUAGE; + n->object = list_make1(makeString((yyvsp[(4) - (7)].str))); + n->newowner = (yyvsp[(7) - (7)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1075: + +/* Line 1455 of yacc.c */ +#line 7243 "gram.y" + { + AlterOwnerStmt *n = makeNode(AlterOwnerStmt); + n->objectType = OBJECT_LARGEOBJECT; + n->object = list_make1((yyvsp[(4) - (7)].value)); + n->newowner = (yyvsp[(7) - (7)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1076: + +/* Line 1455 of yacc.c */ +#line 7251 "gram.y" + { + AlterOwnerStmt *n = makeNode(AlterOwnerStmt); + n->objectType = OBJECT_OPERATOR; + n->object = (yyvsp[(3) - (7)].list); + n->objarg = (yyvsp[(4) - (7)].list); + n->newowner = (yyvsp[(7) - (7)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1077: + +/* Line 1455 of yacc.c */ +#line 7260 "gram.y" + { + AlterOwnerStmt *n = makeNode(AlterOwnerStmt); + n->objectType = OBJECT_OPCLASS; + n->object = (yyvsp[(4) - (9)].list); + n->addname = (yyvsp[(6) - (9)].str); + n->newowner = (yyvsp[(9) - (9)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1078: + +/* Line 1455 of yacc.c */ +#line 7269 "gram.y" + { + AlterOwnerStmt *n = makeNode(AlterOwnerStmt); + n->objectType = OBJECT_OPFAMILY; + n->object = (yyvsp[(4) - (9)].list); + n->addname = (yyvsp[(6) - (9)].str); + n->newowner = (yyvsp[(9) - (9)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1079: + +/* Line 1455 of yacc.c */ +#line 7278 "gram.y" + { + AlterOwnerStmt *n = makeNode(AlterOwnerStmt); + n->objectType = OBJECT_SCHEMA; + n->object = list_make1(makeString((yyvsp[(3) - (6)].str))); + n->newowner = (yyvsp[(6) - (6)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1080: + +/* Line 1455 of yacc.c */ +#line 7286 "gram.y" + { + AlterOwnerStmt *n = makeNode(AlterOwnerStmt); + n->objectType = OBJECT_TYPE; + n->object = (yyvsp[(3) - (6)].list); + n->newowner = (yyvsp[(6) - (6)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1081: + +/* Line 1455 of yacc.c */ +#line 7294 "gram.y" + { + AlterOwnerStmt *n = makeNode(AlterOwnerStmt); + n->objectType = OBJECT_TABLESPACE; + n->object = list_make1(makeString((yyvsp[(3) - (6)].str))); + n->newowner = (yyvsp[(6) - (6)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1082: + +/* Line 1455 of yacc.c */ +#line 7302 "gram.y" + { + AlterOwnerStmt *n = makeNode(AlterOwnerStmt); + n->objectType = OBJECT_TSDICTIONARY; + n->object = (yyvsp[(5) - (8)].list); + n->newowner = (yyvsp[(8) - (8)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1083: + +/* Line 1455 of yacc.c */ +#line 7310 "gram.y" + { + AlterOwnerStmt *n = makeNode(AlterOwnerStmt); + n->objectType = OBJECT_TSCONFIGURATION; + n->object = (yyvsp[(5) - (8)].list); + n->newowner = (yyvsp[(8) - (8)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1084: + +/* Line 1455 of yacc.c */ +#line 7318 "gram.y" + { + AlterOwnerStmt *n = makeNode(AlterOwnerStmt); + n->objectType = OBJECT_FDW; + n->object = list_make1(makeString((yyvsp[(5) - (8)].str))); + n->newowner = (yyvsp[(8) - (8)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1085: + +/* Line 1455 of yacc.c */ +#line 7326 "gram.y" + { + AlterOwnerStmt *n = makeNode(AlterOwnerStmt); + n->objectType = OBJECT_FOREIGN_SERVER; + n->object = list_make1(makeString((yyvsp[(3) - (6)].str))); + n->newowner = (yyvsp[(6) - (6)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1086: + +/* Line 1455 of yacc.c */ +#line 7345 "gram.y" + { + RuleStmt *n = makeNode(RuleStmt); + n->replace = (yyvsp[(2) - (13)].boolean); + n->relation = (yyvsp[(9) - (13)].range); + n->rulename = (yyvsp[(4) - (13)].str); + n->whereClause = (yyvsp[(10) - (13)].node); + n->event = (yyvsp[(7) - (13)].ival); + n->instead = (yyvsp[(12) - (13)].boolean); + n->actions = (yyvsp[(13) - (13)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 1087: + +/* Line 1455 of yacc.c */ +#line 7359 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1088: + +/* Line 1455 of yacc.c */ +#line 7360 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].node)); ;} + break; + + case 1089: + +/* Line 1455 of yacc.c */ +#line 7361 "gram.y" + { (yyval.list) = (yyvsp[(2) - (3)].list); ;} + break; + + case 1090: + +/* Line 1455 of yacc.c */ +#line 7367 "gram.y" + { if ((yyvsp[(3) - (3)].node) != NULL) + (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].node)); + else + (yyval.list) = (yyvsp[(1) - (3)].list); + ;} + break; + + case 1091: + +/* Line 1455 of yacc.c */ +#line 7373 "gram.y" + { if ((yyvsp[(1) - (1)].node) != NULL) + (yyval.list) = list_make1((yyvsp[(1) - (1)].node)); + else + (yyval.list) = NIL; + ;} + break; + + case 1097: + +/* Line 1455 of yacc.c */ +#line 7389 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 1098: + +/* Line 1455 of yacc.c */ +#line 7390 "gram.y" + { (yyval.node) = NULL; ;} + break; + + case 1099: + +/* Line 1455 of yacc.c */ +#line 7393 "gram.y" + { (yyval.ival) = CMD_SELECT; ;} + break; + + case 1100: + +/* Line 1455 of yacc.c */ +#line 7394 "gram.y" + { (yyval.ival) = CMD_UPDATE; ;} + break; + + case 1101: + +/* Line 1455 of yacc.c */ +#line 7395 "gram.y" + { (yyval.ival) = CMD_DELETE; ;} + break; + + case 1102: + +/* Line 1455 of yacc.c */ +#line 7396 "gram.y" + { (yyval.ival) = CMD_INSERT; ;} + break; + + case 1103: + +/* Line 1455 of yacc.c */ +#line 7400 "gram.y" + { (yyval.boolean) = TRUE; ;} + break; + + case 1104: + +/* Line 1455 of yacc.c */ +#line 7401 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 1105: + +/* Line 1455 of yacc.c */ +#line 7402 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 1106: + +/* Line 1455 of yacc.c */ +#line 7408 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->removeType = OBJECT_RULE; + n->objects = list_make1(lappend((yyvsp[(5) - (6)].list), makeString((yyvsp[(3) - (6)].str)))); + n->arguments = NIL; + n->behavior = (yyvsp[(6) - (6)].dbehavior); + n->missing_ok = false; + n->concurrent = false; + (yyval.node) = (Node *) n; + ;} + break; + + case 1107: + +/* Line 1455 of yacc.c */ +#line 7419 "gram.y" + { + DropStmt *n = makeNode(DropStmt); + n->removeType = OBJECT_RULE; + n->objects = list_make1(lappend((yyvsp[(7) - (8)].list), makeString((yyvsp[(5) - (8)].str)))); + n->arguments = NIL; + n->behavior = (yyvsp[(8) - (8)].dbehavior); + n->missing_ok = true; + n->concurrent = false; + (yyval.node) = (Node *) n; + ;} + break; + + case 1108: + +/* Line 1455 of yacc.c */ +#line 7441 "gram.y" + { + NotifyStmt *n = makeNode(NotifyStmt); + n->conditionname = (yyvsp[(2) - (3)].str); + n->payload = (yyvsp[(3) - (3)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1109: + +/* Line 1455 of yacc.c */ +#line 7450 "gram.y" + { (yyval.str) = (yyvsp[(2) - (2)].str); ;} + break; + + case 1110: + +/* Line 1455 of yacc.c */ +#line 7451 "gram.y" + { (yyval.str) = NULL; ;} + break; + + case 1111: + +/* Line 1455 of yacc.c */ +#line 7455 "gram.y" + { + ListenStmt *n = makeNode(ListenStmt); + n->conditionname = (yyvsp[(2) - (2)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1112: + +/* Line 1455 of yacc.c */ +#line 7464 "gram.y" + { + UnlistenStmt *n = makeNode(UnlistenStmt); + n->conditionname = (yyvsp[(2) - (2)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1113: + +/* Line 1455 of yacc.c */ +#line 7470 "gram.y" + { + UnlistenStmt *n = makeNode(UnlistenStmt); + n->conditionname = NULL; + (yyval.node) = (Node *)n; + ;} + break; + + case 1114: + +/* Line 1455 of yacc.c */ +#line 7489 "gram.y" + { + TransactionStmt *n = makeNode(TransactionStmt); + n->kind = TRANS_STMT_ROLLBACK; + n->options = NIL; + (yyval.node) = (Node *)n; + ;} + break; + + case 1115: + +/* Line 1455 of yacc.c */ +#line 7496 "gram.y" + { + TransactionStmt *n = makeNode(TransactionStmt); + n->kind = TRANS_STMT_BEGIN; + n->options = (yyvsp[(3) - (3)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 1116: + +/* Line 1455 of yacc.c */ +#line 7503 "gram.y" + { + TransactionStmt *n = makeNode(TransactionStmt); + n->kind = TRANS_STMT_START; + n->options = (yyvsp[(3) - (3)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 1117: + +/* Line 1455 of yacc.c */ +#line 7510 "gram.y" + { + TransactionStmt *n = makeNode(TransactionStmt); + n->kind = TRANS_STMT_COMMIT; + n->options = NIL; + (yyval.node) = (Node *)n; + ;} + break; + + case 1118: + +/* Line 1455 of yacc.c */ +#line 7517 "gram.y" + { + TransactionStmt *n = makeNode(TransactionStmt); + n->kind = TRANS_STMT_COMMIT; + n->options = NIL; + (yyval.node) = (Node *)n; + ;} + break; + + case 1119: + +/* Line 1455 of yacc.c */ +#line 7524 "gram.y" + { + TransactionStmt *n = makeNode(TransactionStmt); + n->kind = TRANS_STMT_ROLLBACK; + n->options = NIL; + (yyval.node) = (Node *)n; + ;} + break; + + case 1120: + +/* Line 1455 of yacc.c */ +#line 7531 "gram.y" + { + TransactionStmt *n = makeNode(TransactionStmt); + n->kind = TRANS_STMT_SAVEPOINT; + n->options = list_make1(makeDefElem("savepoint_name", + (Node *)makeString((yyvsp[(2) - (2)].str)))); + (yyval.node) = (Node *)n; + ;} + break; + + case 1121: + +/* Line 1455 of yacc.c */ +#line 7539 "gram.y" + { + TransactionStmt *n = makeNode(TransactionStmt); + n->kind = TRANS_STMT_RELEASE; + n->options = list_make1(makeDefElem("savepoint_name", + (Node *)makeString((yyvsp[(3) - (3)].str)))); + (yyval.node) = (Node *)n; + ;} + break; + + case 1122: + +/* Line 1455 of yacc.c */ +#line 7547 "gram.y" + { + TransactionStmt *n = makeNode(TransactionStmt); + n->kind = TRANS_STMT_RELEASE; + n->options = list_make1(makeDefElem("savepoint_name", + (Node *)makeString((yyvsp[(2) - (2)].str)))); + (yyval.node) = (Node *)n; + ;} + break; + + case 1123: + +/* Line 1455 of yacc.c */ +#line 7555 "gram.y" + { + TransactionStmt *n = makeNode(TransactionStmt); + n->kind = TRANS_STMT_ROLLBACK_TO; + n->options = list_make1(makeDefElem("savepoint_name", + (Node *)makeString((yyvsp[(5) - (5)].str)))); + (yyval.node) = (Node *)n; + ;} + break; + + case 1124: + +/* Line 1455 of yacc.c */ +#line 7563 "gram.y" + { + TransactionStmt *n = makeNode(TransactionStmt); + n->kind = TRANS_STMT_ROLLBACK_TO; + n->options = list_make1(makeDefElem("savepoint_name", + (Node *)makeString((yyvsp[(4) - (4)].str)))); + (yyval.node) = (Node *)n; + ;} + break; + + case 1125: + +/* Line 1455 of yacc.c */ +#line 7571 "gram.y" + { + TransactionStmt *n = makeNode(TransactionStmt); + n->kind = TRANS_STMT_PREPARE; + n->gid = (yyvsp[(3) - (3)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1126: + +/* Line 1455 of yacc.c */ +#line 7578 "gram.y" + { + TransactionStmt *n = makeNode(TransactionStmt); + n->kind = TRANS_STMT_COMMIT_PREPARED; + n->gid = (yyvsp[(3) - (3)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1127: + +/* Line 1455 of yacc.c */ +#line 7585 "gram.y" + { + TransactionStmt *n = makeNode(TransactionStmt); + n->kind = TRANS_STMT_ROLLBACK_PREPARED; + n->gid = (yyvsp[(3) - (3)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1128: + +/* Line 1455 of yacc.c */ +#line 7593 "gram.y" + {;} + break; + + case 1129: + +/* Line 1455 of yacc.c */ +#line 7594 "gram.y" + {;} + break; + + case 1130: + +/* Line 1455 of yacc.c */ +#line 7595 "gram.y" + {;} + break; + + case 1131: + +/* Line 1455 of yacc.c */ +#line 7600 "gram.y" + { (yyval.defelt) = makeDefElem("transaction_isolation", + makeStringConst((yyvsp[(3) - (3)].str), (yylsp[(3) - (3)]))); ;} + break; + + case 1132: + +/* Line 1455 of yacc.c */ +#line 7603 "gram.y" + { (yyval.defelt) = makeDefElem("transaction_read_only", + makeIntConst(TRUE, (yylsp[(1) - (2)]))); ;} + break; + + case 1133: + +/* Line 1455 of yacc.c */ +#line 7606 "gram.y" + { (yyval.defelt) = makeDefElem("transaction_read_only", + makeIntConst(FALSE, (yylsp[(1) - (2)]))); ;} + break; + + case 1134: + +/* Line 1455 of yacc.c */ +#line 7609 "gram.y" + { (yyval.defelt) = makeDefElem("transaction_deferrable", + makeIntConst(TRUE, (yylsp[(1) - (1)]))); ;} + break; + + case 1135: + +/* Line 1455 of yacc.c */ +#line 7612 "gram.y" + { (yyval.defelt) = makeDefElem("transaction_deferrable", + makeIntConst(FALSE, (yylsp[(1) - (2)]))); ;} + break; + + case 1136: + +/* Line 1455 of yacc.c */ +#line 7619 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].defelt)); ;} + break; + + case 1137: + +/* Line 1455 of yacc.c */ +#line 7621 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].defelt)); ;} + break; + + case 1138: + +/* Line 1455 of yacc.c */ +#line 7623 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (2)].list), (yyvsp[(2) - (2)].defelt)); ;} + break; + + case 1140: + +/* Line 1455 of yacc.c */ +#line 7629 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1141: + +/* Line 1455 of yacc.c */ +#line 7643 "gram.y" + { + ViewStmt *n = makeNode(ViewStmt); + n->view = (yyvsp[(4) - (9)].range); + n->view->relpersistence = (yyvsp[(2) - (9)].ival); + n->aliases = (yyvsp[(5) - (9)].list); + n->query = (yyvsp[(8) - (9)].node); + n->replace = false; + n->options = (yyvsp[(6) - (9)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 1142: + +/* Line 1455 of yacc.c */ +#line 7655 "gram.y" + { + ViewStmt *n = makeNode(ViewStmt); + n->view = (yyvsp[(6) - (11)].range); + n->view->relpersistence = (yyvsp[(4) - (11)].ival); + n->aliases = (yyvsp[(7) - (11)].list); + n->query = (yyvsp[(10) - (11)].node); + n->replace = true; + n->options = (yyvsp[(8) - (11)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 1143: + +/* Line 1455 of yacc.c */ +#line 7669 "gram.y" + { + ereport(ERROR, + (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), + errmsg("WITH CHECK OPTION is not implemented"))); + ;} + break; + + case 1144: + +/* Line 1455 of yacc.c */ +#line 7675 "gram.y" + { + ereport(ERROR, + (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), + errmsg("WITH CHECK OPTION is not implemented"))); + ;} + break; + + case 1145: + +/* Line 1455 of yacc.c */ +#line 7681 "gram.y" + { + ereport(ERROR, + (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), + errmsg("WITH CHECK OPTION is not implemented"))); + ;} + break; + + case 1146: + +/* Line 1455 of yacc.c */ +#line 7686 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1147: + +/* Line 1455 of yacc.c */ +#line 7697 "gram.y" + { + LoadStmt *n = makeNode(LoadStmt); + n->filename = (yyvsp[(2) - (2)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1148: + +/* Line 1455 of yacc.c */ +#line 7713 "gram.y" + { + CreatedbStmt *n = makeNode(CreatedbStmt); + n->dbname = (yyvsp[(3) - (5)].str); + n->options = (yyvsp[(5) - (5)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 1149: + +/* Line 1455 of yacc.c */ +#line 7722 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (2)].list), (yyvsp[(2) - (2)].defelt)); ;} + break; + + case 1150: + +/* Line 1455 of yacc.c */ +#line 7723 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1151: + +/* Line 1455 of yacc.c */ +#line 7728 "gram.y" + { + (yyval.defelt) = makeDefElem("tablespace", (Node *)makeString((yyvsp[(3) - (3)].str))); + ;} + break; + + case 1152: + +/* Line 1455 of yacc.c */ +#line 7732 "gram.y" + { + (yyval.defelt) = makeDefElem("tablespace", NULL); + ;} + break; + + case 1153: + +/* Line 1455 of yacc.c */ +#line 7736 "gram.y" + { + (yyval.defelt) = makeDefElem("location", (Node *)makeString((yyvsp[(3) - (3)].str))); + ;} + break; + + case 1154: + +/* Line 1455 of yacc.c */ +#line 7740 "gram.y" + { + (yyval.defelt) = makeDefElem("location", NULL); + ;} + break; + + case 1155: + +/* Line 1455 of yacc.c */ +#line 7744 "gram.y" + { + (yyval.defelt) = makeDefElem("template", (Node *)makeString((yyvsp[(3) - (3)].str))); + ;} + break; + + case 1156: + +/* Line 1455 of yacc.c */ +#line 7748 "gram.y" + { + (yyval.defelt) = makeDefElem("template", NULL); + ;} + break; + + case 1157: + +/* Line 1455 of yacc.c */ +#line 7752 "gram.y" + { + (yyval.defelt) = makeDefElem("encoding", (Node *)makeString((yyvsp[(3) - (3)].str))); + ;} + break; + + case 1158: + +/* Line 1455 of yacc.c */ +#line 7756 "gram.y" + { + (yyval.defelt) = makeDefElem("encoding", (Node *)makeInteger((yyvsp[(3) - (3)].ival))); + ;} + break; + + case 1159: + +/* Line 1455 of yacc.c */ +#line 7760 "gram.y" + { + (yyval.defelt) = makeDefElem("encoding", NULL); + ;} + break; + + case 1160: + +/* Line 1455 of yacc.c */ +#line 7764 "gram.y" + { + (yyval.defelt) = makeDefElem("lc_collate", (Node *)makeString((yyvsp[(3) - (3)].str))); + ;} + break; + + case 1161: + +/* Line 1455 of yacc.c */ +#line 7768 "gram.y" + { + (yyval.defelt) = makeDefElem("lc_collate", NULL); + ;} + break; + + case 1162: + +/* Line 1455 of yacc.c */ +#line 7772 "gram.y" + { + (yyval.defelt) = makeDefElem("lc_ctype", (Node *)makeString((yyvsp[(3) - (3)].str))); + ;} + break; + + case 1163: + +/* Line 1455 of yacc.c */ +#line 7776 "gram.y" + { + (yyval.defelt) = makeDefElem("lc_ctype", NULL); + ;} + break; + + case 1164: + +/* Line 1455 of yacc.c */ +#line 7780 "gram.y" + { + (yyval.defelt) = makeDefElem("connectionlimit", (Node *)makeInteger((yyvsp[(4) - (4)].ival))); + ;} + break; + + case 1165: + +/* Line 1455 of yacc.c */ +#line 7784 "gram.y" + { + (yyval.defelt) = makeDefElem("owner", (Node *)makeString((yyvsp[(3) - (3)].str))); + ;} + break; + + case 1166: + +/* Line 1455 of yacc.c */ +#line 7788 "gram.y" + { + (yyval.defelt) = makeDefElem("owner", NULL); + ;} + break; + + case 1167: + +/* Line 1455 of yacc.c */ +#line 7797 "gram.y" + {;} + break; + + case 1168: + +/* Line 1455 of yacc.c */ +#line 7798 "gram.y" + {;} + break; + + case 1169: + +/* Line 1455 of yacc.c */ +#line 7810 "gram.y" + { + AlterDatabaseStmt *n = makeNode(AlterDatabaseStmt); + n->dbname = (yyvsp[(3) - (5)].str); + n->options = (yyvsp[(5) - (5)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 1170: + +/* Line 1455 of yacc.c */ +#line 7817 "gram.y" + { + AlterDatabaseStmt *n = makeNode(AlterDatabaseStmt); + n->dbname = (yyvsp[(3) - (6)].str); + n->options = list_make1(makeDefElem("tablespace", + (Node *)makeString((yyvsp[(6) - (6)].str)))); + (yyval.node) = (Node *)n; + ;} + break; + + case 1171: + +/* Line 1455 of yacc.c */ +#line 7828 "gram.y" + { + AlterDatabaseSetStmt *n = makeNode(AlterDatabaseSetStmt); + n->dbname = (yyvsp[(3) - (4)].str); + n->setstmt = (yyvsp[(4) - (4)].vsetstmt); + (yyval.node) = (Node *)n; + ;} + break; + + case 1172: + +/* Line 1455 of yacc.c */ +#line 7838 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (2)].list), (yyvsp[(2) - (2)].defelt)); ;} + break; + + case 1173: + +/* Line 1455 of yacc.c */ +#line 7839 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1174: + +/* Line 1455 of yacc.c */ +#line 7844 "gram.y" + { + (yyval.defelt) = makeDefElem("connectionlimit", (Node *)makeInteger((yyvsp[(4) - (4)].ival))); + ;} + break; + + case 1175: + +/* Line 1455 of yacc.c */ +#line 7858 "gram.y" + { + DropdbStmt *n = makeNode(DropdbStmt); + n->dbname = (yyvsp[(3) - (3)].str); + n->missing_ok = FALSE; + (yyval.node) = (Node *)n; + ;} + break; + + case 1176: + +/* Line 1455 of yacc.c */ +#line 7865 "gram.y" + { + DropdbStmt *n = makeNode(DropdbStmt); + n->dbname = (yyvsp[(5) - (5)].str); + n->missing_ok = TRUE; + (yyval.node) = (Node *)n; + ;} + break; + + case 1177: + +/* Line 1455 of yacc.c */ +#line 7882 "gram.y" + { + CreateDomainStmt *n = makeNode(CreateDomainStmt); + n->domainname = (yyvsp[(3) - (6)].list); + n->typeName = (yyvsp[(5) - (6)].typnam); + SplitColQualList((yyvsp[(6) - (6)].list), &n->constraints, &n->collClause, + yyscanner); + (yyval.node) = (Node *)n; + ;} + break; + + case 1178: + +/* Line 1455 of yacc.c */ +#line 7895 "gram.y" + { + AlterDomainStmt *n = makeNode(AlterDomainStmt); + n->subtype = 'T'; + n->typeName = (yyvsp[(3) - (4)].list); + n->def = (yyvsp[(4) - (4)].node); + (yyval.node) = (Node *)n; + ;} + break; + + case 1179: + +/* Line 1455 of yacc.c */ +#line 7904 "gram.y" + { + AlterDomainStmt *n = makeNode(AlterDomainStmt); + n->subtype = 'N'; + n->typeName = (yyvsp[(3) - (6)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 1180: + +/* Line 1455 of yacc.c */ +#line 7912 "gram.y" + { + AlterDomainStmt *n = makeNode(AlterDomainStmt); + n->subtype = 'O'; + n->typeName = (yyvsp[(3) - (6)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 1181: + +/* Line 1455 of yacc.c */ +#line 7920 "gram.y" + { + AlterDomainStmt *n = makeNode(AlterDomainStmt); + n->subtype = 'C'; + n->typeName = (yyvsp[(3) - (5)].list); + n->def = (yyvsp[(5) - (5)].node); + (yyval.node) = (Node *)n; + ;} + break; + + case 1182: + +/* Line 1455 of yacc.c */ +#line 7929 "gram.y" + { + AlterDomainStmt *n = makeNode(AlterDomainStmt); + n->subtype = 'X'; + n->typeName = (yyvsp[(3) - (7)].list); + n->name = (yyvsp[(6) - (7)].str); + n->behavior = (yyvsp[(7) - (7)].dbehavior); + n->missing_ok = false; + (yyval.node) = (Node *)n; + ;} + break; + + case 1183: + +/* Line 1455 of yacc.c */ +#line 7940 "gram.y" + { + AlterDomainStmt *n = makeNode(AlterDomainStmt); + n->subtype = 'X'; + n->typeName = (yyvsp[(3) - (9)].list); + n->name = (yyvsp[(8) - (9)].str); + n->behavior = (yyvsp[(9) - (9)].dbehavior); + n->missing_ok = true; + (yyval.node) = (Node *)n; + ;} + break; + + case 1184: + +/* Line 1455 of yacc.c */ +#line 7951 "gram.y" + { + AlterDomainStmt *n = makeNode(AlterDomainStmt); + n->subtype = 'V'; + n->typeName = (yyvsp[(3) - (6)].list); + n->name = (yyvsp[(6) - (6)].str); + (yyval.node) = (Node *)n; + ;} + break; + + case 1185: + +/* Line 1455 of yacc.c */ +#line 7960 "gram.y" + {;} + break; + + case 1186: + +/* Line 1455 of yacc.c */ +#line 7961 "gram.y" + {;} + break; + + case 1187: + +/* Line 1455 of yacc.c */ +#line 7973 "gram.y" + { + AlterTSDictionaryStmt *n = makeNode(AlterTSDictionaryStmt); + n->dictname = (yyvsp[(5) - (6)].list); + n->options = (yyvsp[(6) - (6)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 1188: + +/* Line 1455 of yacc.c */ +#line 7983 "gram.y" + { + AlterTSConfigurationStmt *n = makeNode(AlterTSConfigurationStmt); + n->cfgname = (yyvsp[(5) - (11)].list); + n->tokentype = (yyvsp[(9) - (11)].list); + n->dicts = (yyvsp[(11) - (11)].list); + n->override = false; + n->replace = false; + (yyval.node) = (Node*)n; + ;} + break; + + case 1189: + +/* Line 1455 of yacc.c */ +#line 7993 "gram.y" + { + AlterTSConfigurationStmt *n = makeNode(AlterTSConfigurationStmt); + n->cfgname = (yyvsp[(5) - (11)].list); + n->tokentype = (yyvsp[(9) - (11)].list); + n->dicts = (yyvsp[(11) - (11)].list); + n->override = true; + n->replace = false; + (yyval.node) = (Node*)n; + ;} + break; + + case 1190: + +/* Line 1455 of yacc.c */ +#line 8003 "gram.y" + { + AlterTSConfigurationStmt *n = makeNode(AlterTSConfigurationStmt); + n->cfgname = (yyvsp[(5) - (11)].list); + n->tokentype = NIL; + n->dicts = list_make2((yyvsp[(9) - (11)].list),(yyvsp[(11) - (11)].list)); + n->override = false; + n->replace = true; + (yyval.node) = (Node*)n; + ;} + break; + + case 1191: + +/* Line 1455 of yacc.c */ +#line 8013 "gram.y" + { + AlterTSConfigurationStmt *n = makeNode(AlterTSConfigurationStmt); + n->cfgname = (yyvsp[(5) - (13)].list); + n->tokentype = (yyvsp[(9) - (13)].list); + n->dicts = list_make2((yyvsp[(11) - (13)].list),(yyvsp[(13) - (13)].list)); + n->override = false; + n->replace = true; + (yyval.node) = (Node*)n; + ;} + break; + + case 1192: + +/* Line 1455 of yacc.c */ +#line 8023 "gram.y" + { + AlterTSConfigurationStmt *n = makeNode(AlterTSConfigurationStmt); + n->cfgname = (yyvsp[(5) - (9)].list); + n->tokentype = (yyvsp[(9) - (9)].list); + n->missing_ok = false; + (yyval.node) = (Node*)n; + ;} + break; + + case 1193: + +/* Line 1455 of yacc.c */ +#line 8031 "gram.y" + { + AlterTSConfigurationStmt *n = makeNode(AlterTSConfigurationStmt); + n->cfgname = (yyvsp[(5) - (11)].list); + n->tokentype = (yyvsp[(11) - (11)].list); + n->missing_ok = true; + (yyval.node) = (Node*)n; + ;} + break; + + case 1194: + +/* Line 1455 of yacc.c */ +#line 8053 "gram.y" + { + CreateConversionStmt *n = makeNode(CreateConversionStmt); + n->conversion_name = (yyvsp[(4) - (10)].list); + n->for_encoding_name = (yyvsp[(6) - (10)].str); + n->to_encoding_name = (yyvsp[(8) - (10)].str); + n->func_name = (yyvsp[(10) - (10)].list); + n->def = (yyvsp[(2) - (10)].boolean); + (yyval.node) = (Node *)n; + ;} + break; + + case 1195: + +/* Line 1455 of yacc.c */ +#line 8075 "gram.y" + { + ClusterStmt *n = makeNode(ClusterStmt); + n->relation = (yyvsp[(3) - (4)].range); + n->indexname = (yyvsp[(4) - (4)].str); + n->verbose = (yyvsp[(2) - (4)].boolean); + (yyval.node) = (Node*)n; + ;} + break; + + case 1196: + +/* Line 1455 of yacc.c */ +#line 8083 "gram.y" + { + ClusterStmt *n = makeNode(ClusterStmt); + n->relation = NULL; + n->indexname = NULL; + n->verbose = (yyvsp[(2) - (2)].boolean); + (yyval.node) = (Node*)n; + ;} + break; + + case 1197: + +/* Line 1455 of yacc.c */ +#line 8092 "gram.y" + { + ClusterStmt *n = makeNode(ClusterStmt); + n->relation = (yyvsp[(5) - (5)].range); + n->indexname = (yyvsp[(3) - (5)].str); + n->verbose = (yyvsp[(2) - (5)].boolean); + (yyval.node) = (Node*)n; + ;} + break; + + case 1198: + +/* Line 1455 of yacc.c */ +#line 8102 "gram.y" + { (yyval.str) = (yyvsp[(2) - (2)].str); ;} + break; + + case 1199: + +/* Line 1455 of yacc.c */ +#line 8103 "gram.y" + { (yyval.str) = NULL; ;} + break; + + case 1200: + +/* Line 1455 of yacc.c */ +#line 8116 "gram.y" + { + VacuumStmt *n = makeNode(VacuumStmt); + n->options = VACOPT_VACUUM; + if ((yyvsp[(2) - (4)].boolean)) + n->options |= VACOPT_FULL; + if ((yyvsp[(4) - (4)].boolean)) + n->options |= VACOPT_VERBOSE; + n->freeze_min_age = (yyvsp[(3) - (4)].boolean) ? 0 : -1; + n->freeze_table_age = (yyvsp[(3) - (4)].boolean) ? 0 : -1; + n->relation = NULL; + n->va_cols = NIL; + (yyval.node) = (Node *)n; + ;} + break; + + case 1201: + +/* Line 1455 of yacc.c */ +#line 8130 "gram.y" + { + VacuumStmt *n = makeNode(VacuumStmt); + n->options = VACOPT_VACUUM; + if ((yyvsp[(2) - (5)].boolean)) + n->options |= VACOPT_FULL; + if ((yyvsp[(4) - (5)].boolean)) + n->options |= VACOPT_VERBOSE; + n->freeze_min_age = (yyvsp[(3) - (5)].boolean) ? 0 : -1; + n->freeze_table_age = (yyvsp[(3) - (5)].boolean) ? 0 : -1; + n->relation = (yyvsp[(5) - (5)].range); + n->va_cols = NIL; + (yyval.node) = (Node *)n; + ;} + break; + + case 1202: + +/* Line 1455 of yacc.c */ +#line 8144 "gram.y" + { + VacuumStmt *n = (VacuumStmt *) (yyvsp[(5) - (5)].node); + n->options |= VACOPT_VACUUM; + if ((yyvsp[(2) - (5)].boolean)) + n->options |= VACOPT_FULL; + if ((yyvsp[(4) - (5)].boolean)) + n->options |= VACOPT_VERBOSE; + n->freeze_min_age = (yyvsp[(3) - (5)].boolean) ? 0 : -1; + n->freeze_table_age = (yyvsp[(3) - (5)].boolean) ? 0 : -1; + (yyval.node) = (Node *)n; + ;} + break; + + case 1203: + +/* Line 1455 of yacc.c */ +#line 8156 "gram.y" + { + VacuumStmt *n = makeNode(VacuumStmt); + n->options = VACOPT_VACUUM | (yyvsp[(3) - (4)].ival); + if (n->options & VACOPT_FREEZE) + n->freeze_min_age = n->freeze_table_age = 0; + else + n->freeze_min_age = n->freeze_table_age = -1; + n->relation = NULL; + n->va_cols = NIL; + (yyval.node) = (Node *) n; + ;} + break; + + case 1204: + +/* Line 1455 of yacc.c */ +#line 8168 "gram.y" + { + VacuumStmt *n = makeNode(VacuumStmt); + n->options = VACOPT_VACUUM | (yyvsp[(3) - (6)].ival); + if (n->options & VACOPT_FREEZE) + n->freeze_min_age = n->freeze_table_age = 0; + else + n->freeze_min_age = n->freeze_table_age = -1; + n->relation = (yyvsp[(5) - (6)].range); + n->va_cols = (yyvsp[(6) - (6)].list); + if (n->va_cols != NIL) /* implies analyze */ + n->options |= VACOPT_ANALYZE; + (yyval.node) = (Node *) n; + ;} + break; + + case 1205: + +/* Line 1455 of yacc.c */ +#line 8184 "gram.y" + { (yyval.ival) = (yyvsp[(1) - (1)].ival); ;} + break; + + case 1206: + +/* Line 1455 of yacc.c */ +#line 8185 "gram.y" + { (yyval.ival) = (yyvsp[(1) - (3)].ival) | (yyvsp[(3) - (3)].ival); ;} + break; + + case 1207: + +/* Line 1455 of yacc.c */ +#line 8189 "gram.y" + { (yyval.ival) = VACOPT_ANALYZE; ;} + break; + + case 1208: + +/* Line 1455 of yacc.c */ +#line 8190 "gram.y" + { (yyval.ival) = VACOPT_VERBOSE; ;} + break; + + case 1209: + +/* Line 1455 of yacc.c */ +#line 8191 "gram.y" + { (yyval.ival) = VACOPT_FREEZE; ;} + break; + + case 1210: + +/* Line 1455 of yacc.c */ +#line 8192 "gram.y" + { (yyval.ival) = VACOPT_FULL; ;} + break; + + case 1211: + +/* Line 1455 of yacc.c */ +#line 8197 "gram.y" + { + VacuumStmt *n = makeNode(VacuumStmt); + n->options = VACOPT_ANALYZE; + if ((yyvsp[(2) - (2)].boolean)) + n->options |= VACOPT_VERBOSE; + n->freeze_min_age = -1; + n->freeze_table_age = -1; + n->relation = NULL; + n->va_cols = NIL; + (yyval.node) = (Node *)n; + ;} + break; + + case 1212: + +/* Line 1455 of yacc.c */ +#line 8209 "gram.y" + { + VacuumStmt *n = makeNode(VacuumStmt); + n->options = VACOPT_ANALYZE; + if ((yyvsp[(2) - (4)].boolean)) + n->options |= VACOPT_VERBOSE; + n->freeze_min_age = -1; + n->freeze_table_age = -1; + n->relation = (yyvsp[(3) - (4)].range); + n->va_cols = (yyvsp[(4) - (4)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 1213: + +/* Line 1455 of yacc.c */ +#line 8223 "gram.y" + {;} + break; + + case 1214: + +/* Line 1455 of yacc.c */ +#line 8224 "gram.y" + {;} + break; + + case 1215: + +/* Line 1455 of yacc.c */ +#line 8228 "gram.y" + { (yyval.boolean) = TRUE; ;} + break; + + case 1216: + +/* Line 1455 of yacc.c */ +#line 8229 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 1217: + +/* Line 1455 of yacc.c */ +#line 8232 "gram.y" + { (yyval.boolean) = TRUE; ;} + break; + + case 1218: + +/* Line 1455 of yacc.c */ +#line 8233 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 1219: + +/* Line 1455 of yacc.c */ +#line 8236 "gram.y" + { (yyval.boolean) = TRUE; ;} + break; + + case 1220: + +/* Line 1455 of yacc.c */ +#line 8237 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 1221: + +/* Line 1455 of yacc.c */ +#line 8241 "gram.y" + { (yyval.list) = (yyvsp[(2) - (3)].list); ;} + break; + + case 1222: + +/* Line 1455 of yacc.c */ +#line 8242 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1223: + +/* Line 1455 of yacc.c */ +#line 8256 "gram.y" + { + ExplainStmt *n = makeNode(ExplainStmt); + n->query = (yyvsp[(2) - (2)].node); + n->options = NIL; + (yyval.node) = (Node *) n; + ;} + break; + + case 1224: + +/* Line 1455 of yacc.c */ +#line 8263 "gram.y" + { + ExplainStmt *n = makeNode(ExplainStmt); + n->query = (yyvsp[(4) - (4)].node); + n->options = list_make1(makeDefElem("analyze", NULL)); + if ((yyvsp[(3) - (4)].boolean)) + n->options = lappend(n->options, + makeDefElem("verbose", NULL)); + (yyval.node) = (Node *) n; + ;} + break; + + case 1225: + +/* Line 1455 of yacc.c */ +#line 8273 "gram.y" + { + ExplainStmt *n = makeNode(ExplainStmt); + n->query = (yyvsp[(3) - (3)].node); + n->options = list_make1(makeDefElem("verbose", NULL)); + (yyval.node) = (Node *) n; + ;} + break; + + case 1226: + +/* Line 1455 of yacc.c */ +#line 8280 "gram.y" + { + ExplainStmt *n = makeNode(ExplainStmt); + n->query = (yyvsp[(5) - (5)].node); + n->options = (yyvsp[(3) - (5)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 1234: + +/* Line 1455 of yacc.c */ +#line 8300 "gram.y" + { + (yyval.list) = list_make1((yyvsp[(1) - (1)].defelt)); + ;} + break; + + case 1235: + +/* Line 1455 of yacc.c */ +#line 8304 "gram.y" + { + (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].defelt)); + ;} + break; + + case 1236: + +/* Line 1455 of yacc.c */ +#line 8311 "gram.y" + { + (yyval.defelt) = makeDefElem((yyvsp[(1) - (2)].str), (yyvsp[(2) - (2)].node)); + ;} + break; + + case 1237: + +/* Line 1455 of yacc.c */ +#line 8317 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 1238: + +/* Line 1455 of yacc.c */ +#line 8318 "gram.y" + { (yyval.str) = "analyze"; ;} + break; + + case 1239: + +/* Line 1455 of yacc.c */ +#line 8319 "gram.y" + { (yyval.str) = "verbose"; ;} + break; + + case 1240: + +/* Line 1455 of yacc.c */ +#line 8323 "gram.y" + { (yyval.node) = (Node *) makeString((yyvsp[(1) - (1)].str)); ;} + break; + + case 1241: + +/* Line 1455 of yacc.c */ +#line 8324 "gram.y" + { (yyval.node) = (Node *) (yyvsp[(1) - (1)].value); ;} + break; + + case 1242: + +/* Line 1455 of yacc.c */ +#line 8325 "gram.y" + { (yyval.node) = NULL; ;} + break; + + case 1243: + +/* Line 1455 of yacc.c */ +#line 8336 "gram.y" + { + PrepareStmt *n = makeNode(PrepareStmt); + n->name = (yyvsp[(2) - (5)].str); + n->argtypes = (yyvsp[(3) - (5)].list); + n->query = (yyvsp[(5) - (5)].node); + (yyval.node) = (Node *) n; + ;} + break; + + case 1244: + +/* Line 1455 of yacc.c */ +#line 8345 "gram.y" + { (yyval.list) = (yyvsp[(2) - (3)].list); ;} + break; + + case 1245: + +/* Line 1455 of yacc.c */ +#line 8346 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1250: + +/* Line 1455 of yacc.c */ +#line 8364 "gram.y" + { + ExecuteStmt *n = makeNode(ExecuteStmt); + n->name = (yyvsp[(2) - (3)].str); + n->params = (yyvsp[(3) - (3)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 1251: + +/* Line 1455 of yacc.c */ +#line 8372 "gram.y" + { + CreateTableAsStmt *ctas = makeNode(CreateTableAsStmt); + ExecuteStmt *n = makeNode(ExecuteStmt); + n->name = (yyvsp[(7) - (9)].str); + n->params = (yyvsp[(8) - (9)].list); + ctas->query = (Node *) n; + ctas->into = (yyvsp[(4) - (9)].into); + ctas->is_select_into = false; + /* cram additional flags into the IntoClause */ + (yyvsp[(4) - (9)].into)->rel->relpersistence = (yyvsp[(2) - (9)].ival); + (yyvsp[(4) - (9)].into)->skipData = !((yyvsp[(9) - (9)].boolean)); + (yyval.node) = (Node *) ctas; + ;} + break; + + case 1252: + +/* Line 1455 of yacc.c */ +#line 8387 "gram.y" + { (yyval.list) = (yyvsp[(2) - (3)].list); ;} + break; + + case 1253: + +/* Line 1455 of yacc.c */ +#line 8388 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1254: + +/* Line 1455 of yacc.c */ +#line 8399 "gram.y" + { + DeallocateStmt *n = makeNode(DeallocateStmt); + n->name = (yyvsp[(2) - (2)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 1255: + +/* Line 1455 of yacc.c */ +#line 8405 "gram.y" + { + DeallocateStmt *n = makeNode(DeallocateStmt); + n->name = (yyvsp[(3) - (3)].str); + (yyval.node) = (Node *) n; + ;} + break; + + case 1256: + +/* Line 1455 of yacc.c */ +#line 8411 "gram.y" + { + DeallocateStmt *n = makeNode(DeallocateStmt); + n->name = NULL; + (yyval.node) = (Node *) n; + ;} + break; + + case 1257: + +/* Line 1455 of yacc.c */ +#line 8417 "gram.y" + { + DeallocateStmt *n = makeNode(DeallocateStmt); + n->name = NULL; + (yyval.node) = (Node *) n; + ;} + break; + + case 1258: + +/* Line 1455 of yacc.c */ +#line 8433 "gram.y" + { + (yyvsp[(5) - (6)].istmt)->relation = (yyvsp[(4) - (6)].range); + (yyvsp[(5) - (6)].istmt)->returningList = (yyvsp[(6) - (6)].list); + (yyvsp[(5) - (6)].istmt)->withClause = (yyvsp[(1) - (6)].with); + (yyval.node) = (Node *) (yyvsp[(5) - (6)].istmt); + ;} + break; + + case 1259: + +/* Line 1455 of yacc.c */ +#line 8443 "gram.y" + { + (yyval.istmt) = makeNode(InsertStmt); + (yyval.istmt)->cols = NIL; + (yyval.istmt)->selectStmt = (yyvsp[(1) - (1)].node); + ;} + break; + + case 1260: + +/* Line 1455 of yacc.c */ +#line 8449 "gram.y" + { + (yyval.istmt) = makeNode(InsertStmt); + (yyval.istmt)->cols = (yyvsp[(2) - (4)].list); + (yyval.istmt)->selectStmt = (yyvsp[(4) - (4)].node); + ;} + break; + + case 1261: + +/* Line 1455 of yacc.c */ +#line 8455 "gram.y" + { + (yyval.istmt) = makeNode(InsertStmt); + (yyval.istmt)->cols = NIL; + (yyval.istmt)->selectStmt = NULL; + ;} + break; + + case 1262: + +/* Line 1455 of yacc.c */ +#line 8464 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].target)); ;} + break; + + case 1263: + +/* Line 1455 of yacc.c */ +#line 8466 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].target)); ;} + break; + + case 1264: + +/* Line 1455 of yacc.c */ +#line 8471 "gram.y" + { + (yyval.target) = makeNode(ResTarget); + (yyval.target)->name = (yyvsp[(1) - (2)].str); + (yyval.target)->indirection = check_indirection((yyvsp[(2) - (2)].list), yyscanner); + (yyval.target)->val = NULL; + (yyval.target)->location = (yylsp[(1) - (2)]); + ;} + break; + + case 1265: + +/* Line 1455 of yacc.c */ +#line 8481 "gram.y" + { (yyval.list) = (yyvsp[(2) - (2)].list); ;} + break; + + case 1266: + +/* Line 1455 of yacc.c */ +#line 8482 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1267: + +/* Line 1455 of yacc.c */ +#line 8495 "gram.y" + { + DeleteStmt *n = makeNode(DeleteStmt); + n->relation = (yyvsp[(4) - (7)].range); + n->usingClause = (yyvsp[(5) - (7)].list); + n->whereClause = (yyvsp[(6) - (7)].node); + n->returningList = (yyvsp[(7) - (7)].list); + n->withClause = (yyvsp[(1) - (7)].with); + (yyval.node) = (Node *)n; + ;} + break; + + case 1268: + +/* Line 1455 of yacc.c */ +#line 8507 "gram.y" + { (yyval.list) = (yyvsp[(2) - (2)].list); ;} + break; + + case 1269: + +/* Line 1455 of yacc.c */ +#line 8508 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1270: + +/* Line 1455 of yacc.c */ +#line 8520 "gram.y" + { + LockStmt *n = makeNode(LockStmt); + + n->relations = (yyvsp[(3) - (5)].list); + n->mode = (yyvsp[(4) - (5)].ival); + n->nowait = (yyvsp[(5) - (5)].boolean); + (yyval.node) = (Node *)n; + ;} + break; + + case 1271: + +/* Line 1455 of yacc.c */ +#line 8530 "gram.y" + { (yyval.ival) = (yyvsp[(2) - (3)].ival); ;} + break; + + case 1272: + +/* Line 1455 of yacc.c */ +#line 8531 "gram.y" + { (yyval.ival) = AccessExclusiveLock; ;} + break; + + case 1273: + +/* Line 1455 of yacc.c */ +#line 8534 "gram.y" + { (yyval.ival) = AccessShareLock; ;} + break; + + case 1274: + +/* Line 1455 of yacc.c */ +#line 8535 "gram.y" + { (yyval.ival) = RowShareLock; ;} + break; + + case 1275: + +/* Line 1455 of yacc.c */ +#line 8536 "gram.y" + { (yyval.ival) = RowExclusiveLock; ;} + break; + + case 1276: + +/* Line 1455 of yacc.c */ +#line 8537 "gram.y" + { (yyval.ival) = ShareUpdateExclusiveLock; ;} + break; + + case 1277: + +/* Line 1455 of yacc.c */ +#line 8538 "gram.y" + { (yyval.ival) = ShareLock; ;} + break; + + case 1278: + +/* Line 1455 of yacc.c */ +#line 8539 "gram.y" + { (yyval.ival) = ShareRowExclusiveLock; ;} + break; + + case 1279: + +/* Line 1455 of yacc.c */ +#line 8540 "gram.y" + { (yyval.ival) = ExclusiveLock; ;} + break; + + case 1280: + +/* Line 1455 of yacc.c */ +#line 8541 "gram.y" + { (yyval.ival) = AccessExclusiveLock; ;} + break; + + case 1281: + +/* Line 1455 of yacc.c */ +#line 8544 "gram.y" + { (yyval.boolean) = TRUE; ;} + break; + + case 1282: + +/* Line 1455 of yacc.c */ +#line 8545 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 1283: + +/* Line 1455 of yacc.c */ +#line 8561 "gram.y" + { + UpdateStmt *n = makeNode(UpdateStmt); + n->relation = (yyvsp[(3) - (8)].range); + n->targetList = (yyvsp[(5) - (8)].list); + n->fromClause = (yyvsp[(6) - (8)].list); + n->whereClause = (yyvsp[(7) - (8)].node); + n->returningList = (yyvsp[(8) - (8)].list); + n->withClause = (yyvsp[(1) - (8)].with); + (yyval.node) = (Node *)n; + ;} + break; + + case 1284: + +/* Line 1455 of yacc.c */ +#line 8574 "gram.y" + { (yyval.list) = (yyvsp[(1) - (1)].list); ;} + break; + + case 1285: + +/* Line 1455 of yacc.c */ +#line 8575 "gram.y" + { (yyval.list) = list_concat((yyvsp[(1) - (3)].list),(yyvsp[(3) - (3)].list)); ;} + break; + + case 1286: + +/* Line 1455 of yacc.c */ +#line 8579 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].target)); ;} + break; + + case 1287: + +/* Line 1455 of yacc.c */ +#line 8580 "gram.y" + { (yyval.list) = (yyvsp[(1) - (1)].list); ;} + break; + + case 1288: + +/* Line 1455 of yacc.c */ +#line 8585 "gram.y" + { + (yyval.target) = (yyvsp[(1) - (3)].target); + (yyval.target)->val = (Node *) (yyvsp[(3) - (3)].node); + ;} + break; + + case 1289: + +/* Line 1455 of yacc.c */ +#line 8593 "gram.y" + { + ListCell *col_cell; + ListCell *val_cell; + + /* + * Break the ctext_row apart, merge individual expressions + * into the destination ResTargets. XXX this approach + * cannot work for general row expressions as sources. + */ + if (list_length((yyvsp[(2) - (5)].list)) != list_length((yyvsp[(5) - (5)].list))) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("number of columns does not match number of values"), + parser_errposition((yylsp[(1) - (5)])))); + forboth(col_cell, (yyvsp[(2) - (5)].list), val_cell, (yyvsp[(5) - (5)].list)) + { + ResTarget *res_col = (ResTarget *) lfirst(col_cell); + Node *res_val = (Node *) lfirst(val_cell); + + res_col->val = res_val; + } + + (yyval.list) = (yyvsp[(2) - (5)].list); + ;} + break; + + case 1290: + +/* Line 1455 of yacc.c */ +#line 8621 "gram.y" + { + (yyval.target) = makeNode(ResTarget); + (yyval.target)->name = (yyvsp[(1) - (2)].str); + (yyval.target)->indirection = check_indirection((yyvsp[(2) - (2)].list), yyscanner); + (yyval.target)->val = NULL; /* upper production sets this */ + (yyval.target)->location = (yylsp[(1) - (2)]); + ;} + break; + + case 1291: + +/* Line 1455 of yacc.c */ +#line 8631 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].target)); ;} + break; + + case 1292: + +/* Line 1455 of yacc.c */ +#line 8632 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list),(yyvsp[(3) - (3)].target)); ;} + break; + + case 1293: + +/* Line 1455 of yacc.c */ +#line 8643 "gram.y" + { + DeclareCursorStmt *n = makeNode(DeclareCursorStmt); + n->portalname = (yyvsp[(2) - (7)].str); + /* currently we always set FAST_PLAN option */ + n->options = (yyvsp[(3) - (7)].ival) | (yyvsp[(5) - (7)].ival) | CURSOR_OPT_FAST_PLAN; + n->query = (yyvsp[(7) - (7)].node); + (yyval.node) = (Node *)n; + ;} + break; + + case 1294: + +/* Line 1455 of yacc.c */ +#line 8653 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 1295: + +/* Line 1455 of yacc.c */ +#line 8656 "gram.y" + { (yyval.ival) = 0; ;} + break; + + case 1296: + +/* Line 1455 of yacc.c */ +#line 8657 "gram.y" + { (yyval.ival) = (yyvsp[(1) - (3)].ival) | CURSOR_OPT_NO_SCROLL; ;} + break; + + case 1297: + +/* Line 1455 of yacc.c */ +#line 8658 "gram.y" + { (yyval.ival) = (yyvsp[(1) - (2)].ival) | CURSOR_OPT_SCROLL; ;} + break; + + case 1298: + +/* Line 1455 of yacc.c */ +#line 8659 "gram.y" + { (yyval.ival) = (yyvsp[(1) - (2)].ival) | CURSOR_OPT_BINARY; ;} + break; + + case 1299: + +/* Line 1455 of yacc.c */ +#line 8660 "gram.y" + { (yyval.ival) = (yyvsp[(1) - (2)].ival) | CURSOR_OPT_INSENSITIVE; ;} + break; + + case 1300: + +/* Line 1455 of yacc.c */ +#line 8663 "gram.y" + { (yyval.ival) = 0; ;} + break; + + case 1301: + +/* Line 1455 of yacc.c */ +#line 8664 "gram.y" + { (yyval.ival) = CURSOR_OPT_HOLD; ;} + break; + + case 1302: + +/* Line 1455 of yacc.c */ +#line 8665 "gram.y" + { (yyval.ival) = 0; ;} + break; + + case 1305: + +/* Line 1455 of yacc.c */ +#line 8718 "gram.y" + { (yyval.node) = (yyvsp[(2) - (3)].node); ;} + break; + + case 1306: + +/* Line 1455 of yacc.c */ +#line 8719 "gram.y" + { (yyval.node) = (yyvsp[(2) - (3)].node); ;} + break; + + case 1307: + +/* Line 1455 of yacc.c */ +#line 8733 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 1308: + +/* Line 1455 of yacc.c */ +#line 8735 "gram.y" + { + insertSelectOptions((SelectStmt *) (yyvsp[(1) - (2)].node), (yyvsp[(2) - (2)].list), NIL, + NULL, NULL, NULL, + yyscanner); + (yyval.node) = (yyvsp[(1) - (2)].node); + ;} + break; + + case 1309: + +/* Line 1455 of yacc.c */ +#line 8742 "gram.y" + { + insertSelectOptions((SelectStmt *) (yyvsp[(1) - (4)].node), (yyvsp[(2) - (4)].list), (yyvsp[(3) - (4)].list), + list_nth((yyvsp[(4) - (4)].list), 0), list_nth((yyvsp[(4) - (4)].list), 1), + NULL, + yyscanner); + (yyval.node) = (yyvsp[(1) - (4)].node); + ;} + break; + + case 1310: + +/* Line 1455 of yacc.c */ +#line 8750 "gram.y" + { + insertSelectOptions((SelectStmt *) (yyvsp[(1) - (4)].node), (yyvsp[(2) - (4)].list), (yyvsp[(4) - (4)].list), + list_nth((yyvsp[(3) - (4)].list), 0), list_nth((yyvsp[(3) - (4)].list), 1), + NULL, + yyscanner); + (yyval.node) = (yyvsp[(1) - (4)].node); + ;} + break; + + case 1311: + +/* Line 1455 of yacc.c */ +#line 8758 "gram.y" + { + insertSelectOptions((SelectStmt *) (yyvsp[(2) - (2)].node), NULL, NIL, + NULL, NULL, + (yyvsp[(1) - (2)].with), + yyscanner); + (yyval.node) = (yyvsp[(2) - (2)].node); + ;} + break; + + case 1312: + +/* Line 1455 of yacc.c */ +#line 8766 "gram.y" + { + insertSelectOptions((SelectStmt *) (yyvsp[(2) - (3)].node), (yyvsp[(3) - (3)].list), NIL, + NULL, NULL, + (yyvsp[(1) - (3)].with), + yyscanner); + (yyval.node) = (yyvsp[(2) - (3)].node); + ;} + break; + + case 1313: + +/* Line 1455 of yacc.c */ +#line 8774 "gram.y" + { + insertSelectOptions((SelectStmt *) (yyvsp[(2) - (5)].node), (yyvsp[(3) - (5)].list), (yyvsp[(4) - (5)].list), + list_nth((yyvsp[(5) - (5)].list), 0), list_nth((yyvsp[(5) - (5)].list), 1), + (yyvsp[(1) - (5)].with), + yyscanner); + (yyval.node) = (yyvsp[(2) - (5)].node); + ;} + break; + + case 1314: + +/* Line 1455 of yacc.c */ +#line 8782 "gram.y" + { + insertSelectOptions((SelectStmt *) (yyvsp[(2) - (5)].node), (yyvsp[(3) - (5)].list), (yyvsp[(5) - (5)].list), + list_nth((yyvsp[(4) - (5)].list), 0), list_nth((yyvsp[(4) - (5)].list), 1), + (yyvsp[(1) - (5)].with), + yyscanner); + (yyval.node) = (yyvsp[(2) - (5)].node); + ;} + break; + + case 1315: + +/* Line 1455 of yacc.c */ +#line 8792 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 1316: + +/* Line 1455 of yacc.c */ +#line 8793 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 1317: + +/* Line 1455 of yacc.c */ +#line 8823 "gram.y" + { + SelectStmt *n = makeNode(SelectStmt); + n->distinctClause = (yyvsp[(2) - (9)].list); + n->targetList = (yyvsp[(3) - (9)].list); + n->intoClause = (yyvsp[(4) - (9)].into); + n->fromClause = (yyvsp[(5) - (9)].list); + n->whereClause = (yyvsp[(6) - (9)].node); + n->groupClause = (yyvsp[(7) - (9)].list); + n->havingClause = (yyvsp[(8) - (9)].node); + n->windowClause = (yyvsp[(9) - (9)].list); + (yyval.node) = (Node *)n; + ;} + break; + + case 1318: + +/* Line 1455 of yacc.c */ +#line 8835 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 1319: + +/* Line 1455 of yacc.c */ +#line 8837 "gram.y" + { + /* same as SELECT * FROM relation_expr */ + ColumnRef *cr = makeNode(ColumnRef); + ResTarget *rt = makeNode(ResTarget); + SelectStmt *n = makeNode(SelectStmt); + + cr->fields = list_make1(makeNode(A_Star)); + cr->location = -1; + + rt->name = NULL; + rt->indirection = NIL; + rt->val = (Node *)cr; + rt->location = -1; + + n->targetList = list_make1(rt); + n->fromClause = list_make1((yyvsp[(2) - (2)].range)); + (yyval.node) = (Node *)n; + ;} + break; + + case 1320: + +/* Line 1455 of yacc.c */ +#line 8856 "gram.y" + { + (yyval.node) = makeSetOp(SETOP_UNION, (yyvsp[(3) - (4)].boolean), (yyvsp[(1) - (4)].node), (yyvsp[(4) - (4)].node)); + ;} + break; + + case 1321: + +/* Line 1455 of yacc.c */ +#line 8860 "gram.y" + { + (yyval.node) = makeSetOp(SETOP_INTERSECT, (yyvsp[(3) - (4)].boolean), (yyvsp[(1) - (4)].node), (yyvsp[(4) - (4)].node)); + ;} + break; + + case 1322: + +/* Line 1455 of yacc.c */ +#line 8864 "gram.y" + { + (yyval.node) = makeSetOp(SETOP_EXCEPT, (yyvsp[(3) - (4)].boolean), (yyvsp[(1) - (4)].node), (yyvsp[(4) - (4)].node)); + ;} + break; + + case 1323: + +/* Line 1455 of yacc.c */ +#line 8879 "gram.y" + { + (yyval.with) = makeNode(WithClause); + (yyval.with)->ctes = (yyvsp[(2) - (2)].list); + (yyval.with)->recursive = false; + (yyval.with)->location = (yylsp[(1) - (2)]); + ;} + break; + + case 1324: + +/* Line 1455 of yacc.c */ +#line 8886 "gram.y" + { + (yyval.with) = makeNode(WithClause); + (yyval.with)->ctes = (yyvsp[(3) - (3)].list); + (yyval.with)->recursive = true; + (yyval.with)->location = (yylsp[(1) - (3)]); + ;} + break; + + case 1325: + +/* Line 1455 of yacc.c */ +#line 8895 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].node)); ;} + break; + + case 1326: + +/* Line 1455 of yacc.c */ +#line 8896 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].node)); ;} + break; + + case 1327: + +/* Line 1455 of yacc.c */ +#line 8900 "gram.y" + { + CommonTableExpr *n = makeNode(CommonTableExpr); + n->ctename = (yyvsp[(1) - (6)].str); + n->aliascolnames = (yyvsp[(2) - (6)].list); + n->ctequery = (yyvsp[(5) - (6)].node); + n->location = (yylsp[(1) - (6)]); + (yyval.node) = (Node *) n; + ;} + break; + + case 1328: + +/* Line 1455 of yacc.c */ +#line 8911 "gram.y" + { (yyval.with) = (yyvsp[(1) - (1)].with); ;} + break; + + case 1329: + +/* Line 1455 of yacc.c */ +#line 8912 "gram.y" + { (yyval.with) = NULL; ;} + break; + + case 1330: + +/* Line 1455 of yacc.c */ +#line 8917 "gram.y" + { + (yyval.into) = makeNode(IntoClause); + (yyval.into)->rel = (yyvsp[(2) - (2)].range); + (yyval.into)->colNames = NIL; + (yyval.into)->options = NIL; + (yyval.into)->onCommit = ONCOMMIT_NOOP; + (yyval.into)->tableSpaceName = NULL; + (yyval.into)->skipData = false; + ;} + break; + + case 1331: + +/* Line 1455 of yacc.c */ +#line 8927 "gram.y" + { (yyval.into) = NULL; ;} + break; + + case 1332: + +/* Line 1455 of yacc.c */ +#line 8936 "gram.y" + { + (yyval.range) = (yyvsp[(3) - (3)].range); + (yyval.range)->relpersistence = RELPERSISTENCE_TEMP; + ;} + break; + + case 1333: + +/* Line 1455 of yacc.c */ +#line 8941 "gram.y" + { + (yyval.range) = (yyvsp[(3) - (3)].range); + (yyval.range)->relpersistence = RELPERSISTENCE_TEMP; + ;} + break; + + case 1334: + +/* Line 1455 of yacc.c */ +#line 8946 "gram.y" + { + (yyval.range) = (yyvsp[(4) - (4)].range); + (yyval.range)->relpersistence = RELPERSISTENCE_TEMP; + ;} + break; + + case 1335: + +/* Line 1455 of yacc.c */ +#line 8951 "gram.y" + { + (yyval.range) = (yyvsp[(4) - (4)].range); + (yyval.range)->relpersistence = RELPERSISTENCE_TEMP; + ;} + break; + + case 1336: + +/* Line 1455 of yacc.c */ +#line 8956 "gram.y" + { + ereport(WARNING, + (errmsg("GLOBAL is deprecated in temporary table creation"), + parser_errposition((yylsp[(1) - (4)])))); + (yyval.range) = (yyvsp[(4) - (4)].range); + (yyval.range)->relpersistence = RELPERSISTENCE_TEMP; + ;} + break; + + case 1337: + +/* Line 1455 of yacc.c */ +#line 8964 "gram.y" + { + ereport(WARNING, + (errmsg("GLOBAL is deprecated in temporary table creation"), + parser_errposition((yylsp[(1) - (4)])))); + (yyval.range) = (yyvsp[(4) - (4)].range); + (yyval.range)->relpersistence = RELPERSISTENCE_TEMP; + ;} + break; + + case 1338: + +/* Line 1455 of yacc.c */ +#line 8972 "gram.y" + { + (yyval.range) = (yyvsp[(3) - (3)].range); + (yyval.range)->relpersistence = RELPERSISTENCE_UNLOGGED; + ;} + break; + + case 1339: + +/* Line 1455 of yacc.c */ +#line 8977 "gram.y" + { + (yyval.range) = (yyvsp[(2) - (2)].range); + (yyval.range)->relpersistence = RELPERSISTENCE_PERMANENT; + ;} + break; + + case 1340: + +/* Line 1455 of yacc.c */ +#line 8982 "gram.y" + { + (yyval.range) = (yyvsp[(1) - (1)].range); + (yyval.range)->relpersistence = RELPERSISTENCE_PERMANENT; + ;} + break; + + case 1341: + +/* Line 1455 of yacc.c */ +#line 8988 "gram.y" + {;} + break; + + case 1342: + +/* Line 1455 of yacc.c */ +#line 8989 "gram.y" + {;} + break; + + case 1343: + +/* Line 1455 of yacc.c */ +#line 8992 "gram.y" + { (yyval.boolean) = TRUE; ;} + break; + + case 1344: + +/* Line 1455 of yacc.c */ +#line 8993 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 1345: + +/* Line 1455 of yacc.c */ +#line 8994 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 1346: + +/* Line 1455 of yacc.c */ +#line 9001 "gram.y" + { (yyval.list) = list_make1(NIL); ;} + break; + + case 1347: + +/* Line 1455 of yacc.c */ +#line 9002 "gram.y" + { (yyval.list) = (yyvsp[(4) - (5)].list); ;} + break; + + case 1348: + +/* Line 1455 of yacc.c */ +#line 9003 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1349: + +/* Line 1455 of yacc.c */ +#line 9004 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1350: + +/* Line 1455 of yacc.c */ +#line 9008 "gram.y" + { (yyval.list) = (yyvsp[(1) - (1)].list);;} + break; + + case 1351: + +/* Line 1455 of yacc.c */ +#line 9009 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1352: + +/* Line 1455 of yacc.c */ +#line 9013 "gram.y" + { (yyval.list) = (yyvsp[(3) - (3)].list); ;} + break; + + case 1353: + +/* Line 1455 of yacc.c */ +#line 9017 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].sortby)); ;} + break; + + case 1354: + +/* Line 1455 of yacc.c */ +#line 9018 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].sortby)); ;} + break; + + case 1355: + +/* Line 1455 of yacc.c */ +#line 9022 "gram.y" + { + (yyval.sortby) = makeNode(SortBy); + (yyval.sortby)->node = (yyvsp[(1) - (4)].node); + (yyval.sortby)->sortby_dir = SORTBY_USING; + (yyval.sortby)->sortby_nulls = (yyvsp[(4) - (4)].ival); + (yyval.sortby)->useOp = (yyvsp[(3) - (4)].list); + (yyval.sortby)->location = (yylsp[(3) - (4)]); + ;} + break; + + case 1356: + +/* Line 1455 of yacc.c */ +#line 9031 "gram.y" + { + (yyval.sortby) = makeNode(SortBy); + (yyval.sortby)->node = (yyvsp[(1) - (3)].node); + (yyval.sortby)->sortby_dir = (yyvsp[(2) - (3)].ival); + (yyval.sortby)->sortby_nulls = (yyvsp[(3) - (3)].ival); + (yyval.sortby)->useOp = NIL; + (yyval.sortby)->location = -1; /* no operator */ + ;} + break; + + case 1357: + +/* Line 1455 of yacc.c */ +#line 9043 "gram.y" + { (yyval.list) = list_make2((yyvsp[(2) - (2)].node), (yyvsp[(1) - (2)].node)); ;} + break; + + case 1358: + +/* Line 1455 of yacc.c */ +#line 9044 "gram.y" + { (yyval.list) = list_make2((yyvsp[(1) - (2)].node), (yyvsp[(2) - (2)].node)); ;} + break; + + case 1359: + +/* Line 1455 of yacc.c */ +#line 9045 "gram.y" + { (yyval.list) = list_make2(NULL, (yyvsp[(1) - (1)].node)); ;} + break; + + case 1360: + +/* Line 1455 of yacc.c */ +#line 9046 "gram.y" + { (yyval.list) = list_make2((yyvsp[(1) - (1)].node), NULL); ;} + break; + + case 1361: + +/* Line 1455 of yacc.c */ +#line 9050 "gram.y" + { (yyval.list) = (yyvsp[(1) - (1)].list); ;} + break; + + case 1362: + +/* Line 1455 of yacc.c */ +#line 9051 "gram.y" + { (yyval.list) = list_make2(NULL,NULL); ;} + break; + + case 1363: + +/* Line 1455 of yacc.c */ +#line 9056 "gram.y" + { (yyval.node) = (yyvsp[(2) - (2)].node); ;} + break; + + case 1364: + +/* Line 1455 of yacc.c */ +#line 9058 "gram.y" + { + /* Disabled because it was too confusing, bjm 2002-02-18 */ + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("LIMIT #,# syntax is not supported"), + errhint("Use separate LIMIT and OFFSET clauses."), + parser_errposition((yylsp[(1) - (4)])))); + ;} + break; + + case 1365: + +/* Line 1455 of yacc.c */ +#line 9068 "gram.y" + { (yyval.node) = (yyvsp[(3) - (5)].node); ;} + break; + + case 1366: + +/* Line 1455 of yacc.c */ +#line 9073 "gram.y" + { (yyval.node) = (yyvsp[(2) - (2)].node); ;} + break; + + case 1367: + +/* Line 1455 of yacc.c */ +#line 9076 "gram.y" + { (yyval.node) = (yyvsp[(2) - (3)].node); ;} + break; + + case 1368: + +/* Line 1455 of yacc.c */ +#line 9080 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 1369: + +/* Line 1455 of yacc.c */ +#line 9082 "gram.y" + { + /* LIMIT ALL is represented as a NULL constant */ + (yyval.node) = makeNullAConst((yylsp[(1) - (1)])); + ;} + break; + + case 1370: + +/* Line 1455 of yacc.c */ +#line 9089 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 1371: + +/* Line 1455 of yacc.c */ +#line 9099 "gram.y" + { (yyval.node) = makeIntConst((yyvsp[(1) - (1)].ival), (yylsp[(1) - (1)])); ;} + break; + + case 1372: + +/* Line 1455 of yacc.c */ +#line 9100 "gram.y" + { (yyval.node) = (yyvsp[(2) - (3)].node); ;} + break; + + case 1373: + +/* Line 1455 of yacc.c */ +#line 9101 "gram.y" + { (yyval.node) = makeIntConst(1, -1); ;} + break; + + case 1374: + +/* Line 1455 of yacc.c */ +#line 9109 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 1375: + +/* Line 1455 of yacc.c */ +#line 9113 "gram.y" + { (yyval.ival) = 0; ;} + break; + + case 1376: + +/* Line 1455 of yacc.c */ +#line 9114 "gram.y" + { (yyval.ival) = 0; ;} + break; + + case 1377: + +/* Line 1455 of yacc.c */ +#line 9117 "gram.y" + { (yyval.ival) = 0; ;} + break; + + case 1378: + +/* Line 1455 of yacc.c */ +#line 9118 "gram.y" + { (yyval.ival) = 0; ;} + break; + + case 1379: + +/* Line 1455 of yacc.c */ +#line 9123 "gram.y" + { (yyval.list) = (yyvsp[(3) - (3)].list); ;} + break; + + case 1380: + +/* Line 1455 of yacc.c */ +#line 9124 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1381: + +/* Line 1455 of yacc.c */ +#line 9128 "gram.y" + { (yyval.node) = (yyvsp[(2) - (2)].node); ;} + break; + + case 1382: + +/* Line 1455 of yacc.c */ +#line 9129 "gram.y" + { (yyval.node) = NULL; ;} + break; + + case 1383: + +/* Line 1455 of yacc.c */ +#line 9133 "gram.y" + { (yyval.list) = (yyvsp[(1) - (1)].list); ;} + break; + + case 1384: + +/* Line 1455 of yacc.c */ +#line 9134 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1385: + +/* Line 1455 of yacc.c */ +#line 9138 "gram.y" + { (yyval.list) = (yyvsp[(1) - (1)].list); ;} + break; + + case 1386: + +/* Line 1455 of yacc.c */ +#line 9139 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1387: + +/* Line 1455 of yacc.c */ +#line 9143 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].node)); ;} + break; + + case 1388: + +/* Line 1455 of yacc.c */ +#line 9144 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (2)].list), (yyvsp[(2) - (2)].node)); ;} + break; + + case 1389: + +/* Line 1455 of yacc.c */ +#line 9149 "gram.y" + { + LockingClause *n = makeNode(LockingClause); + n->lockedRels = (yyvsp[(3) - (4)].list); + n->forUpdate = TRUE; + n->noWait = (yyvsp[(4) - (4)].boolean); + (yyval.node) = (Node *) n; + ;} + break; + + case 1390: + +/* Line 1455 of yacc.c */ +#line 9157 "gram.y" + { + LockingClause *n = makeNode(LockingClause); + n->lockedRels = (yyvsp[(3) - (4)].list); + n->forUpdate = FALSE; + n->noWait = (yyvsp[(4) - (4)].boolean); + (yyval.node) = (Node *) n; + ;} + break; + + case 1391: + +/* Line 1455 of yacc.c */ +#line 9167 "gram.y" + { (yyval.list) = (yyvsp[(2) - (2)].list); ;} + break; + + case 1392: + +/* Line 1455 of yacc.c */ +#line 9168 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1393: + +/* Line 1455 of yacc.c */ +#line 9174 "gram.y" + { + SelectStmt *n = makeNode(SelectStmt); + n->valuesLists = list_make1((yyvsp[(2) - (2)].list)); + (yyval.node) = (Node *) n; + ;} + break; + + case 1394: + +/* Line 1455 of yacc.c */ +#line 9180 "gram.y" + { + SelectStmt *n = (SelectStmt *) (yyvsp[(1) - (3)].node); + n->valuesLists = lappend(n->valuesLists, (yyvsp[(3) - (3)].list)); + (yyval.node) = (Node *) n; + ;} + break; + + case 1395: + +/* Line 1455 of yacc.c */ +#line 9197 "gram.y" + { (yyval.list) = (yyvsp[(2) - (2)].list); ;} + break; + + case 1396: + +/* Line 1455 of yacc.c */ +#line 9198 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1397: + +/* Line 1455 of yacc.c */ +#line 9202 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].node)); ;} + break; + + case 1398: + +/* Line 1455 of yacc.c */ +#line 9203 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].node)); ;} + break; + + case 1399: + +/* Line 1455 of yacc.c */ +#line 9214 "gram.y" + { + (yyval.node) = (Node *) (yyvsp[(1) - (1)].range); + ;} + break; + + case 1400: + +/* Line 1455 of yacc.c */ +#line 9218 "gram.y" + { + (yyvsp[(1) - (2)].range)->alias = (yyvsp[(2) - (2)].alias); + (yyval.node) = (Node *) (yyvsp[(1) - (2)].range); + ;} + break; + + case 1401: + +/* Line 1455 of yacc.c */ +#line 9223 "gram.y" + { + RangeFunction *n = makeNode(RangeFunction); + n->funccallnode = (yyvsp[(1) - (1)].node); + n->coldeflist = NIL; + (yyval.node) = (Node *) n; + ;} + break; + + case 1402: + +/* Line 1455 of yacc.c */ +#line 9230 "gram.y" + { + RangeFunction *n = makeNode(RangeFunction); + n->funccallnode = (yyvsp[(1) - (2)].node); + n->alias = (yyvsp[(2) - (2)].alias); + n->coldeflist = NIL; + (yyval.node) = (Node *) n; + ;} + break; + + case 1403: + +/* Line 1455 of yacc.c */ +#line 9238 "gram.y" + { + RangeFunction *n = makeNode(RangeFunction); + n->funccallnode = (yyvsp[(1) - (5)].node); + n->coldeflist = (yyvsp[(4) - (5)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 1404: + +/* Line 1455 of yacc.c */ +#line 9245 "gram.y" + { + RangeFunction *n = makeNode(RangeFunction); + Alias *a = makeNode(Alias); + n->funccallnode = (yyvsp[(1) - (6)].node); + a->aliasname = (yyvsp[(3) - (6)].str); + n->alias = a; + n->coldeflist = (yyvsp[(5) - (6)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 1405: + +/* Line 1455 of yacc.c */ +#line 9255 "gram.y" + { + RangeFunction *n = makeNode(RangeFunction); + Alias *a = makeNode(Alias); + n->funccallnode = (yyvsp[(1) - (5)].node); + a->aliasname = (yyvsp[(2) - (5)].str); + n->alias = a; + n->coldeflist = (yyvsp[(4) - (5)].list); + (yyval.node) = (Node *) n; + ;} + break; + + case 1406: + +/* Line 1455 of yacc.c */ +#line 9265 "gram.y" + { + /* + * The SQL spec does not permit a subselect + * () without an alias clause, + * so we don't either. This avoids the problem + * of needing to invent a unique refname for it. + * That could be surmounted if there's sufficient + * popular demand, but for now let's just implement + * the spec and see if anyone complains. + * However, it does seem like a good idea to emit + * an error message that's better than "syntax error". + */ + if (IsA((yyvsp[(1) - (1)].node), SelectStmt) && + ((SelectStmt *) (yyvsp[(1) - (1)].node))->valuesLists) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("VALUES in FROM must have an alias"), + errhint("For example, FROM (VALUES ...) [AS] foo."), + parser_errposition((yylsp[(1) - (1)])))); + else + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("subquery in FROM must have an alias"), + errhint("For example, FROM (SELECT ...) [AS] foo."), + parser_errposition((yylsp[(1) - (1)])))); + (yyval.node) = NULL; + ;} + break; + + case 1407: + +/* Line 1455 of yacc.c */ +#line 9293 "gram.y" + { + RangeSubselect *n = makeNode(RangeSubselect); + n->subquery = (yyvsp[(1) - (2)].node); + n->alias = (yyvsp[(2) - (2)].alias); + (yyval.node) = (Node *) n; + ;} + break; + + case 1408: + +/* Line 1455 of yacc.c */ +#line 9300 "gram.y" + { + (yyval.node) = (Node *) (yyvsp[(1) - (1)].jexpr); + ;} + break; + + case 1409: + +/* Line 1455 of yacc.c */ +#line 9304 "gram.y" + { + (yyvsp[(2) - (4)].jexpr)->alias = (yyvsp[(4) - (4)].alias); + (yyval.node) = (Node *) (yyvsp[(2) - (4)].jexpr); + ;} + break; + + case 1410: + +/* Line 1455 of yacc.c */ +#line 9330 "gram.y" + { + (yyval.jexpr) = (yyvsp[(2) - (3)].jexpr); + ;} + break; + + case 1411: + +/* Line 1455 of yacc.c */ +#line 9334 "gram.y" + { + /* CROSS JOIN is same as unqualified inner join */ + JoinExpr *n = makeNode(JoinExpr); + n->jointype = JOIN_INNER; + n->isNatural = FALSE; + n->larg = (yyvsp[(1) - (4)].node); + n->rarg = (yyvsp[(4) - (4)].node); + n->usingClause = NIL; + n->quals = NULL; + (yyval.jexpr) = n; + ;} + break; + + case 1412: + +/* Line 1455 of yacc.c */ +#line 9346 "gram.y" + { + JoinExpr *n = makeNode(JoinExpr); + n->jointype = (yyvsp[(2) - (5)].jtype); + n->isNatural = FALSE; + n->larg = (yyvsp[(1) - (5)].node); + n->rarg = (yyvsp[(4) - (5)].node); + if ((yyvsp[(5) - (5)].node) != NULL && IsA((yyvsp[(5) - (5)].node), List)) + n->usingClause = (List *) (yyvsp[(5) - (5)].node); /* USING clause */ + else + n->quals = (yyvsp[(5) - (5)].node); /* ON clause */ + (yyval.jexpr) = n; + ;} + break; + + case 1413: + +/* Line 1455 of yacc.c */ +#line 9359 "gram.y" + { + /* letting join_type reduce to empty doesn't work */ + JoinExpr *n = makeNode(JoinExpr); + n->jointype = JOIN_INNER; + n->isNatural = FALSE; + n->larg = (yyvsp[(1) - (4)].node); + n->rarg = (yyvsp[(3) - (4)].node); + if ((yyvsp[(4) - (4)].node) != NULL && IsA((yyvsp[(4) - (4)].node), List)) + n->usingClause = (List *) (yyvsp[(4) - (4)].node); /* USING clause */ + else + n->quals = (yyvsp[(4) - (4)].node); /* ON clause */ + (yyval.jexpr) = n; + ;} + break; + + case 1414: + +/* Line 1455 of yacc.c */ +#line 9373 "gram.y" + { + JoinExpr *n = makeNode(JoinExpr); + n->jointype = (yyvsp[(3) - (5)].jtype); + n->isNatural = TRUE; + n->larg = (yyvsp[(1) - (5)].node); + n->rarg = (yyvsp[(5) - (5)].node); + n->usingClause = NIL; /* figure out which columns later... */ + n->quals = NULL; /* fill later */ + (yyval.jexpr) = n; + ;} + break; + + case 1415: + +/* Line 1455 of yacc.c */ +#line 9384 "gram.y" + { + /* letting join_type reduce to empty doesn't work */ + JoinExpr *n = makeNode(JoinExpr); + n->jointype = JOIN_INNER; + n->isNatural = TRUE; + n->larg = (yyvsp[(1) - (4)].node); + n->rarg = (yyvsp[(4) - (4)].node); + n->usingClause = NIL; /* figure out which columns later... */ + n->quals = NULL; /* fill later */ + (yyval.jexpr) = n; + ;} + break; + + case 1416: + +/* Line 1455 of yacc.c */ +#line 9399 "gram.y" + { + (yyval.alias) = makeNode(Alias); + (yyval.alias)->aliasname = (yyvsp[(2) - (5)].str); + (yyval.alias)->colnames = (yyvsp[(4) - (5)].list); + ;} + break; + + case 1417: + +/* Line 1455 of yacc.c */ +#line 9405 "gram.y" + { + (yyval.alias) = makeNode(Alias); + (yyval.alias)->aliasname = (yyvsp[(2) - (2)].str); + ;} + break; + + case 1418: + +/* Line 1455 of yacc.c */ +#line 9410 "gram.y" + { + (yyval.alias) = makeNode(Alias); + (yyval.alias)->aliasname = (yyvsp[(1) - (4)].str); + (yyval.alias)->colnames = (yyvsp[(3) - (4)].list); + ;} + break; + + case 1419: + +/* Line 1455 of yacc.c */ +#line 9416 "gram.y" + { + (yyval.alias) = makeNode(Alias); + (yyval.alias)->aliasname = (yyvsp[(1) - (1)].str); + ;} + break; + + case 1420: + +/* Line 1455 of yacc.c */ +#line 9422 "gram.y" + { (yyval.jtype) = JOIN_FULL; ;} + break; + + case 1421: + +/* Line 1455 of yacc.c */ +#line 9423 "gram.y" + { (yyval.jtype) = JOIN_LEFT; ;} + break; + + case 1422: + +/* Line 1455 of yacc.c */ +#line 9424 "gram.y" + { (yyval.jtype) = JOIN_RIGHT; ;} + break; + + case 1423: + +/* Line 1455 of yacc.c */ +#line 9425 "gram.y" + { (yyval.jtype) = JOIN_INNER; ;} + break; + + case 1424: + +/* Line 1455 of yacc.c */ +#line 9429 "gram.y" + { (yyval.node) = NULL; ;} + break; + + case 1425: + +/* Line 1455 of yacc.c */ +#line 9430 "gram.y" + { (yyval.node) = NULL; ;} + break; + + case 1426: + +/* Line 1455 of yacc.c */ +#line 9442 "gram.y" + { (yyval.node) = (Node *) (yyvsp[(3) - (4)].list); ;} + break; + + case 1427: + +/* Line 1455 of yacc.c */ +#line 9443 "gram.y" + { (yyval.node) = (yyvsp[(2) - (2)].node); ;} + break; + + case 1428: + +/* Line 1455 of yacc.c */ +#line 9449 "gram.y" + { + /* default inheritance */ + (yyval.range) = (yyvsp[(1) - (1)].range); + (yyval.range)->inhOpt = INH_DEFAULT; + (yyval.range)->alias = NULL; + ;} + break; + + case 1429: + +/* Line 1455 of yacc.c */ +#line 9456 "gram.y" + { + /* inheritance query */ + (yyval.range) = (yyvsp[(1) - (2)].range); + (yyval.range)->inhOpt = INH_YES; + (yyval.range)->alias = NULL; + ;} + break; + + case 1430: + +/* Line 1455 of yacc.c */ +#line 9463 "gram.y" + { + /* no inheritance */ + (yyval.range) = (yyvsp[(2) - (2)].range); + (yyval.range)->inhOpt = INH_NO; + (yyval.range)->alias = NULL; + ;} + break; + + case 1431: + +/* Line 1455 of yacc.c */ +#line 9470 "gram.y" + { + /* no inheritance, SQL99-style syntax */ + (yyval.range) = (yyvsp[(3) - (4)].range); + (yyval.range)->inhOpt = INH_NO; + (yyval.range)->alias = NULL; + ;} + break; + + case 1432: + +/* Line 1455 of yacc.c */ +#line 9480 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].range)); ;} + break; + + case 1433: + +/* Line 1455 of yacc.c */ +#line 9481 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].range)); ;} + break; + + case 1434: + +/* Line 1455 of yacc.c */ +#line 9495 "gram.y" + { + (yyval.range) = (yyvsp[(1) - (1)].range); + ;} + break; + + case 1435: + +/* Line 1455 of yacc.c */ +#line 9499 "gram.y" + { + Alias *alias = makeNode(Alias); + alias->aliasname = (yyvsp[(2) - (2)].str); + (yyvsp[(1) - (2)].range)->alias = alias; + (yyval.range) = (yyvsp[(1) - (2)].range); + ;} + break; + + case 1436: + +/* Line 1455 of yacc.c */ +#line 9506 "gram.y" + { + Alias *alias = makeNode(Alias); + alias->aliasname = (yyvsp[(3) - (3)].str); + (yyvsp[(1) - (3)].range)->alias = alias; + (yyval.range) = (yyvsp[(1) - (3)].range); + ;} + break; + + case 1437: + +/* Line 1455 of yacc.c */ +#line 9515 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 1438: + +/* Line 1455 of yacc.c */ +#line 9520 "gram.y" + { (yyval.node) = (yyvsp[(2) - (2)].node); ;} + break; + + case 1439: + +/* Line 1455 of yacc.c */ +#line 9521 "gram.y" + { (yyval.node) = NULL; ;} + break; + + case 1440: + +/* Line 1455 of yacc.c */ +#line 9526 "gram.y" + { (yyval.node) = (yyvsp[(2) - (2)].node); ;} + break; + + case 1441: + +/* Line 1455 of yacc.c */ +#line 9528 "gram.y" + { + CurrentOfExpr *n = makeNode(CurrentOfExpr); + /* cvarno is filled in by parse analysis */ + n->cursor_name = (yyvsp[(4) - (4)].str); + n->cursor_param = 0; + (yyval.node) = (Node *) n; + ;} + break; + + case 1442: + +/* Line 1455 of yacc.c */ +#line 9535 "gram.y" + { (yyval.node) = NULL; ;} + break; + + case 1443: + +/* Line 1455 of yacc.c */ +#line 9540 "gram.y" + { (yyval.list) = (yyvsp[(1) - (1)].list); ;} + break; + + case 1444: + +/* Line 1455 of yacc.c */ +#line 9541 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1445: + +/* Line 1455 of yacc.c */ +#line 9546 "gram.y" + { + (yyval.list) = list_make1((yyvsp[(1) - (1)].node)); + ;} + break; + + case 1446: + +/* Line 1455 of yacc.c */ +#line 9550 "gram.y" + { + (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].node)); + ;} + break; + + case 1447: + +/* Line 1455 of yacc.c */ +#line 9556 "gram.y" + { + ColumnDef *n = makeNode(ColumnDef); + n->colname = (yyvsp[(1) - (3)].str); + n->typeName = (yyvsp[(2) - (3)].typnam); + n->inhcount = 0; + n->is_local = true; + n->is_not_null = false; + n->is_from_type = false; + n->storage = 0; + n->raw_default = NULL; + n->cooked_default = NULL; + n->collClause = (CollateClause *) (yyvsp[(3) - (3)].node); + n->collOid = InvalidOid; + n->constraints = NIL; + (yyval.node) = (Node *)n; + ;} + break; + + case 1448: + +/* Line 1455 of yacc.c */ +#line 9585 "gram.y" + { + (yyval.typnam) = (yyvsp[(1) - (2)].typnam); + (yyval.typnam)->arrayBounds = (yyvsp[(2) - (2)].list); + ;} + break; + + case 1449: + +/* Line 1455 of yacc.c */ +#line 9590 "gram.y" + { + (yyval.typnam) = (yyvsp[(2) - (3)].typnam); + (yyval.typnam)->arrayBounds = (yyvsp[(3) - (3)].list); + (yyval.typnam)->setof = TRUE; + ;} + break; + + case 1450: + +/* Line 1455 of yacc.c */ +#line 9597 "gram.y" + { + (yyval.typnam) = (yyvsp[(1) - (5)].typnam); + (yyval.typnam)->arrayBounds = list_make1(makeInteger((yyvsp[(4) - (5)].ival))); + ;} + break; + + case 1451: + +/* Line 1455 of yacc.c */ +#line 9602 "gram.y" + { + (yyval.typnam) = (yyvsp[(2) - (6)].typnam); + (yyval.typnam)->arrayBounds = list_make1(makeInteger((yyvsp[(5) - (6)].ival))); + (yyval.typnam)->setof = TRUE; + ;} + break; + + case 1452: + +/* Line 1455 of yacc.c */ +#line 9608 "gram.y" + { + (yyval.typnam) = (yyvsp[(1) - (2)].typnam); + (yyval.typnam)->arrayBounds = list_make1(makeInteger(-1)); + ;} + break; + + case 1453: + +/* Line 1455 of yacc.c */ +#line 9613 "gram.y" + { + (yyval.typnam) = (yyvsp[(2) - (3)].typnam); + (yyval.typnam)->arrayBounds = list_make1(makeInteger(-1)); + (yyval.typnam)->setof = TRUE; + ;} + break; + + case 1454: + +/* Line 1455 of yacc.c */ +#line 9622 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), makeInteger(-1)); ;} + break; + + case 1455: + +/* Line 1455 of yacc.c */ +#line 9624 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (4)].list), makeInteger((yyvsp[(3) - (4)].ival))); ;} + break; + + case 1456: + +/* Line 1455 of yacc.c */ +#line 9626 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1457: + +/* Line 1455 of yacc.c */ +#line 9630 "gram.y" + { (yyval.typnam) = (yyvsp[(1) - (1)].typnam); ;} + break; + + case 1458: + +/* Line 1455 of yacc.c */ +#line 9631 "gram.y" + { (yyval.typnam) = (yyvsp[(1) - (1)].typnam); ;} + break; + + case 1459: + +/* Line 1455 of yacc.c */ +#line 9632 "gram.y" + { (yyval.typnam) = (yyvsp[(1) - (1)].typnam); ;} + break; + + case 1460: + +/* Line 1455 of yacc.c */ +#line 9633 "gram.y" + { (yyval.typnam) = (yyvsp[(1) - (1)].typnam); ;} + break; + + case 1461: + +/* Line 1455 of yacc.c */ +#line 9634 "gram.y" + { (yyval.typnam) = (yyvsp[(1) - (1)].typnam); ;} + break; + + case 1462: + +/* Line 1455 of yacc.c */ +#line 9636 "gram.y" + { + (yyval.typnam) = (yyvsp[(1) - (2)].typnam); + (yyval.typnam)->typmods = (yyvsp[(2) - (2)].list); + ;} + break; + + case 1463: + +/* Line 1455 of yacc.c */ +#line 9641 "gram.y" + { + (yyval.typnam) = (yyvsp[(1) - (5)].typnam); + if ((yyvsp[(5) - (5)].list) != NIL) + { + if (list_length((yyvsp[(5) - (5)].list)) != 1) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("interval precision specified twice"), + parser_errposition((yylsp[(1) - (5)])))); + (yyval.typnam)->typmods = lappend((yyvsp[(5) - (5)].list), makeIntConst((yyvsp[(3) - (5)].ival), (yylsp[(3) - (5)]))); + } + else + (yyval.typnam)->typmods = list_make2(makeIntConst(INTERVAL_FULL_RANGE, -1), + makeIntConst((yyvsp[(3) - (5)].ival), (yylsp[(3) - (5)]))); + ;} + break; + + case 1464: + +/* Line 1455 of yacc.c */ +#line 9670 "gram.y" + { (yyval.typnam) = (yyvsp[(1) - (1)].typnam); ;} + break; + + case 1465: + +/* Line 1455 of yacc.c */ +#line 9671 "gram.y" + { (yyval.typnam) = (yyvsp[(1) - (1)].typnam); ;} + break; + + case 1466: + +/* Line 1455 of yacc.c */ +#line 9672 "gram.y" + { (yyval.typnam) = (yyvsp[(1) - (1)].typnam); ;} + break; + + case 1467: + +/* Line 1455 of yacc.c */ +#line 9673 "gram.y" + { (yyval.typnam) = (yyvsp[(1) - (1)].typnam); ;} + break; + + case 1468: + +/* Line 1455 of yacc.c */ +#line 9685 "gram.y" + { + (yyval.typnam) = makeTypeName((yyvsp[(1) - (2)].str)); + (yyval.typnam)->typmods = (yyvsp[(2) - (2)].list); + (yyval.typnam)->location = (yylsp[(1) - (2)]); + ;} + break; + + case 1469: + +/* Line 1455 of yacc.c */ +#line 9691 "gram.y" + { + (yyval.typnam) = makeTypeNameFromNameList(lcons(makeString((yyvsp[(1) - (3)].str)), (yyvsp[(2) - (3)].list))); + (yyval.typnam)->typmods = (yyvsp[(3) - (3)].list); + (yyval.typnam)->location = (yylsp[(1) - (3)]); + ;} + break; + + case 1470: + +/* Line 1455 of yacc.c */ +#line 9698 "gram.y" + { (yyval.list) = (yyvsp[(2) - (3)].list); ;} + break; + + case 1471: + +/* Line 1455 of yacc.c */ +#line 9699 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1472: + +/* Line 1455 of yacc.c */ +#line 9706 "gram.y" + { + (yyval.typnam) = SystemTypeName("int4"); + (yyval.typnam)->location = (yylsp[(1) - (1)]); + ;} + break; + + case 1473: + +/* Line 1455 of yacc.c */ +#line 9711 "gram.y" + { + (yyval.typnam) = SystemTypeName("int4"); + (yyval.typnam)->location = (yylsp[(1) - (1)]); + ;} + break; + + case 1474: + +/* Line 1455 of yacc.c */ +#line 9716 "gram.y" + { + (yyval.typnam) = SystemTypeName("int2"); + (yyval.typnam)->location = (yylsp[(1) - (1)]); + ;} + break; + + case 1475: + +/* Line 1455 of yacc.c */ +#line 9721 "gram.y" + { + (yyval.typnam) = SystemTypeName("int8"); + (yyval.typnam)->location = (yylsp[(1) - (1)]); + ;} + break; + + case 1476: + +/* Line 1455 of yacc.c */ +#line 9726 "gram.y" + { + (yyval.typnam) = SystemTypeName("float4"); + (yyval.typnam)->location = (yylsp[(1) - (1)]); + ;} + break; + + case 1477: + +/* Line 1455 of yacc.c */ +#line 9731 "gram.y" + { + (yyval.typnam) = (yyvsp[(2) - (2)].typnam); + (yyval.typnam)->location = (yylsp[(1) - (2)]); + ;} + break; + + case 1478: + +/* Line 1455 of yacc.c */ +#line 9736 "gram.y" + { + (yyval.typnam) = SystemTypeName("float8"); + (yyval.typnam)->location = (yylsp[(1) - (2)]); + ;} + break; + + case 1479: + +/* Line 1455 of yacc.c */ +#line 9741 "gram.y" + { + (yyval.typnam) = SystemTypeName("numeric"); + (yyval.typnam)->typmods = (yyvsp[(2) - (2)].list); + (yyval.typnam)->location = (yylsp[(1) - (2)]); + ;} + break; + + case 1480: + +/* Line 1455 of yacc.c */ +#line 9747 "gram.y" + { + (yyval.typnam) = SystemTypeName("numeric"); + (yyval.typnam)->typmods = (yyvsp[(2) - (2)].list); + (yyval.typnam)->location = (yylsp[(1) - (2)]); + ;} + break; + + case 1481: + +/* Line 1455 of yacc.c */ +#line 9753 "gram.y" + { + (yyval.typnam) = SystemTypeName("numeric"); + (yyval.typnam)->typmods = (yyvsp[(2) - (2)].list); + (yyval.typnam)->location = (yylsp[(1) - (2)]); + ;} + break; + + case 1482: + +/* Line 1455 of yacc.c */ +#line 9759 "gram.y" + { + (yyval.typnam) = SystemTypeName("bool"); + (yyval.typnam)->location = (yylsp[(1) - (1)]); + ;} + break; + + case 1483: + +/* Line 1455 of yacc.c */ +#line 9766 "gram.y" + { + /* + * Check FLOAT() precision limits assuming IEEE floating + * types - thomas 1997-09-18 + */ + if ((yyvsp[(2) - (3)].ival) < 1) + ereport(ERROR, + (errcode(ERRCODE_INVALID_PARAMETER_VALUE), + errmsg("precision for type float must be at least 1 bit"), + parser_errposition((yylsp[(2) - (3)])))); + else if ((yyvsp[(2) - (3)].ival) <= 24) + (yyval.typnam) = SystemTypeName("float4"); + else if ((yyvsp[(2) - (3)].ival) <= 53) + (yyval.typnam) = SystemTypeName("float8"); + else + ereport(ERROR, + (errcode(ERRCODE_INVALID_PARAMETER_VALUE), + errmsg("precision for type float must be less than 54 bits"), + parser_errposition((yylsp[(2) - (3)])))); + ;} + break; + + case 1484: + +/* Line 1455 of yacc.c */ +#line 9787 "gram.y" + { + (yyval.typnam) = SystemTypeName("float8"); + ;} + break; + + case 1485: + +/* Line 1455 of yacc.c */ +#line 9797 "gram.y" + { + (yyval.typnam) = (yyvsp[(1) - (1)].typnam); + ;} + break; + + case 1486: + +/* Line 1455 of yacc.c */ +#line 9801 "gram.y" + { + (yyval.typnam) = (yyvsp[(1) - (1)].typnam); + ;} + break; + + case 1487: + +/* Line 1455 of yacc.c */ +#line 9809 "gram.y" + { + (yyval.typnam) = (yyvsp[(1) - (1)].typnam); + ;} + break; + + case 1488: + +/* Line 1455 of yacc.c */ +#line 9813 "gram.y" + { + (yyval.typnam) = (yyvsp[(1) - (1)].typnam); + (yyval.typnam)->typmods = NIL; + ;} + break; + + case 1489: + +/* Line 1455 of yacc.c */ +#line 9821 "gram.y" + { + char *typname; + + typname = (yyvsp[(2) - (5)].boolean) ? "varbit" : "bit"; + (yyval.typnam) = SystemTypeName(typname); + (yyval.typnam)->typmods = (yyvsp[(4) - (5)].list); + (yyval.typnam)->location = (yylsp[(1) - (5)]); + ;} + break; + + case 1490: + +/* Line 1455 of yacc.c */ +#line 9833 "gram.y" + { + /* bit defaults to bit(1), varbit to no limit */ + if ((yyvsp[(2) - (2)].boolean)) + { + (yyval.typnam) = SystemTypeName("varbit"); + } + else + { + (yyval.typnam) = SystemTypeName("bit"); + (yyval.typnam)->typmods = list_make1(makeIntConst(1, -1)); + } + (yyval.typnam)->location = (yylsp[(1) - (2)]); + ;} + break; + + case 1491: + +/* Line 1455 of yacc.c */ +#line 9854 "gram.y" + { + (yyval.typnam) = (yyvsp[(1) - (1)].typnam); + ;} + break; + + case 1492: + +/* Line 1455 of yacc.c */ +#line 9858 "gram.y" + { + (yyval.typnam) = (yyvsp[(1) - (1)].typnam); + ;} + break; + + case 1493: + +/* Line 1455 of yacc.c */ +#line 9864 "gram.y" + { + (yyval.typnam) = (yyvsp[(1) - (1)].typnam); + ;} + break; + + case 1494: + +/* Line 1455 of yacc.c */ +#line 9868 "gram.y" + { + /* Length was not specified so allow to be unrestricted. + * This handles problems with fixed-length (bpchar) strings + * which in column definitions must default to a length + * of one, but should not be constrained if the length + * was not specified. + */ + (yyval.typnam) = (yyvsp[(1) - (1)].typnam); + (yyval.typnam)->typmods = NIL; + ;} + break; + + case 1495: + +/* Line 1455 of yacc.c */ +#line 9881 "gram.y" + { + if (((yyvsp[(5) - (5)].str) != NULL) && (strcmp((yyvsp[(5) - (5)].str), "sql_text") != 0)) + { + char *type; + + type = palloc(strlen((yyvsp[(1) - (5)].str)) + 1 + strlen((yyvsp[(5) - (5)].str)) + 1); + strcpy(type, (yyvsp[(1) - (5)].str)); + strcat(type, "_"); + strcat(type, (yyvsp[(5) - (5)].str)); + (yyvsp[(1) - (5)].str) = type; + } + + (yyval.typnam) = SystemTypeName((yyvsp[(1) - (5)].str)); + (yyval.typnam)->typmods = list_make1(makeIntConst((yyvsp[(3) - (5)].ival), (yylsp[(3) - (5)]))); + (yyval.typnam)->location = (yylsp[(1) - (5)]); + ;} + break; + + case 1496: + +/* Line 1455 of yacc.c */ +#line 9900 "gram.y" + { + if (((yyvsp[(2) - (2)].str) != NULL) && (strcmp((yyvsp[(2) - (2)].str), "sql_text") != 0)) + { + char *type; + + type = palloc(strlen((yyvsp[(1) - (2)].str)) + 1 + strlen((yyvsp[(2) - (2)].str)) + 1); + strcpy(type, (yyvsp[(1) - (2)].str)); + strcat(type, "_"); + strcat(type, (yyvsp[(2) - (2)].str)); + (yyvsp[(1) - (2)].str) = type; + } + + (yyval.typnam) = SystemTypeName((yyvsp[(1) - (2)].str)); + + /* char defaults to char(1), varchar to no limit */ + if (strcmp((yyvsp[(1) - (2)].str), "bpchar") == 0) + (yyval.typnam)->typmods = list_make1(makeIntConst(1, -1)); + + (yyval.typnam)->location = (yylsp[(1) - (2)]); + ;} + break; + + case 1497: + +/* Line 1455 of yacc.c */ +#line 9923 "gram.y" + { (yyval.str) = (yyvsp[(2) - (2)].boolean) ? "varchar": "bpchar"; ;} + break; + + case 1498: + +/* Line 1455 of yacc.c */ +#line 9925 "gram.y" + { (yyval.str) = (yyvsp[(2) - (2)].boolean) ? "varchar": "bpchar"; ;} + break; + + case 1499: + +/* Line 1455 of yacc.c */ +#line 9927 "gram.y" + { (yyval.str) = "varchar"; ;} + break; + + case 1500: + +/* Line 1455 of yacc.c */ +#line 9929 "gram.y" + { (yyval.str) = (yyvsp[(3) - (3)].boolean) ? "varchar": "bpchar"; ;} + break; + + case 1501: + +/* Line 1455 of yacc.c */ +#line 9931 "gram.y" + { (yyval.str) = (yyvsp[(3) - (3)].boolean) ? "varchar": "bpchar"; ;} + break; + + case 1502: + +/* Line 1455 of yacc.c */ +#line 9933 "gram.y" + { (yyval.str) = (yyvsp[(2) - (2)].boolean) ? "varchar": "bpchar"; ;} + break; + + case 1503: + +/* Line 1455 of yacc.c */ +#line 9937 "gram.y" + { (yyval.boolean) = TRUE; ;} + break; + + case 1504: + +/* Line 1455 of yacc.c */ +#line 9938 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 1505: + +/* Line 1455 of yacc.c */ +#line 9942 "gram.y" + { (yyval.str) = (yyvsp[(3) - (3)].str); ;} + break; + + case 1506: + +/* Line 1455 of yacc.c */ +#line 9943 "gram.y" + { (yyval.str) = NULL; ;} + break; + + case 1507: + +/* Line 1455 of yacc.c */ +#line 9951 "gram.y" + { + if ((yyvsp[(5) - (5)].boolean)) + (yyval.typnam) = SystemTypeName("timestamptz"); + else + (yyval.typnam) = SystemTypeName("timestamp"); + (yyval.typnam)->typmods = list_make1(makeIntConst((yyvsp[(3) - (5)].ival), (yylsp[(3) - (5)]))); + (yyval.typnam)->location = (yylsp[(1) - (5)]); + ;} + break; + + case 1508: + +/* Line 1455 of yacc.c */ +#line 9960 "gram.y" + { + if ((yyvsp[(2) - (2)].boolean)) + (yyval.typnam) = SystemTypeName("timestamptz"); + else + (yyval.typnam) = SystemTypeName("timestamp"); + (yyval.typnam)->location = (yylsp[(1) - (2)]); + ;} + break; + + case 1509: + +/* Line 1455 of yacc.c */ +#line 9968 "gram.y" + { + if ((yyvsp[(5) - (5)].boolean)) + (yyval.typnam) = SystemTypeName("timetz"); + else + (yyval.typnam) = SystemTypeName("time"); + (yyval.typnam)->typmods = list_make1(makeIntConst((yyvsp[(3) - (5)].ival), (yylsp[(3) - (5)]))); + (yyval.typnam)->location = (yylsp[(1) - (5)]); + ;} + break; + + case 1510: + +/* Line 1455 of yacc.c */ +#line 9977 "gram.y" + { + if ((yyvsp[(2) - (2)].boolean)) + (yyval.typnam) = SystemTypeName("timetz"); + else + (yyval.typnam) = SystemTypeName("time"); + (yyval.typnam)->location = (yylsp[(1) - (2)]); + ;} + break; + + case 1511: + +/* Line 1455 of yacc.c */ +#line 9988 "gram.y" + { + (yyval.typnam) = SystemTypeName("interval"); + (yyval.typnam)->location = (yylsp[(1) - (1)]); + ;} + break; + + case 1512: + +/* Line 1455 of yacc.c */ +#line 9995 "gram.y" + { (yyval.boolean) = TRUE; ;} + break; + + case 1513: + +/* Line 1455 of yacc.c */ +#line 9996 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 1514: + +/* Line 1455 of yacc.c */ +#line 9997 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 1515: + +/* Line 1455 of yacc.c */ +#line 10002 "gram.y" + { (yyval.list) = list_make1(makeIntConst(INTERVAL_MASK(YEAR), (yylsp[(1) - (1)]))); ;} + break; + + case 1516: + +/* Line 1455 of yacc.c */ +#line 10004 "gram.y" + { (yyval.list) = list_make1(makeIntConst(INTERVAL_MASK(MONTH), (yylsp[(1) - (1)]))); ;} + break; + + case 1517: + +/* Line 1455 of yacc.c */ +#line 10006 "gram.y" + { (yyval.list) = list_make1(makeIntConst(INTERVAL_MASK(DAY), (yylsp[(1) - (1)]))); ;} + break; + + case 1518: + +/* Line 1455 of yacc.c */ +#line 10008 "gram.y" + { (yyval.list) = list_make1(makeIntConst(INTERVAL_MASK(HOUR), (yylsp[(1) - (1)]))); ;} + break; + + case 1519: + +/* Line 1455 of yacc.c */ +#line 10010 "gram.y" + { (yyval.list) = list_make1(makeIntConst(INTERVAL_MASK(MINUTE), (yylsp[(1) - (1)]))); ;} + break; + + case 1520: + +/* Line 1455 of yacc.c */ +#line 10012 "gram.y" + { (yyval.list) = (yyvsp[(1) - (1)].list); ;} + break; + + case 1521: + +/* Line 1455 of yacc.c */ +#line 10014 "gram.y" + { + (yyval.list) = list_make1(makeIntConst(INTERVAL_MASK(YEAR) | + INTERVAL_MASK(MONTH), (yylsp[(1) - (3)]))); + ;} + break; + + case 1522: + +/* Line 1455 of yacc.c */ +#line 10019 "gram.y" + { + (yyval.list) = list_make1(makeIntConst(INTERVAL_MASK(DAY) | + INTERVAL_MASK(HOUR), (yylsp[(1) - (3)]))); + ;} + break; + + case 1523: + +/* Line 1455 of yacc.c */ +#line 10024 "gram.y" + { + (yyval.list) = list_make1(makeIntConst(INTERVAL_MASK(DAY) | + INTERVAL_MASK(HOUR) | + INTERVAL_MASK(MINUTE), (yylsp[(1) - (3)]))); + ;} + break; + + case 1524: + +/* Line 1455 of yacc.c */ +#line 10030 "gram.y" + { + (yyval.list) = (yyvsp[(3) - (3)].list); + linitial((yyval.list)) = makeIntConst(INTERVAL_MASK(DAY) | + INTERVAL_MASK(HOUR) | + INTERVAL_MASK(MINUTE) | + INTERVAL_MASK(SECOND), (yylsp[(1) - (3)])); + ;} + break; + + case 1525: + +/* Line 1455 of yacc.c */ +#line 10038 "gram.y" + { + (yyval.list) = list_make1(makeIntConst(INTERVAL_MASK(HOUR) | + INTERVAL_MASK(MINUTE), (yylsp[(1) - (3)]))); + ;} + break; + + case 1526: + +/* Line 1455 of yacc.c */ +#line 10043 "gram.y" + { + (yyval.list) = (yyvsp[(3) - (3)].list); + linitial((yyval.list)) = makeIntConst(INTERVAL_MASK(HOUR) | + INTERVAL_MASK(MINUTE) | + INTERVAL_MASK(SECOND), (yylsp[(1) - (3)])); + ;} + break; + + case 1527: + +/* Line 1455 of yacc.c */ +#line 10050 "gram.y" + { + (yyval.list) = (yyvsp[(3) - (3)].list); + linitial((yyval.list)) = makeIntConst(INTERVAL_MASK(MINUTE) | + INTERVAL_MASK(SECOND), (yylsp[(1) - (3)])); + ;} + break; + + case 1528: + +/* Line 1455 of yacc.c */ +#line 10056 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1529: + +/* Line 1455 of yacc.c */ +#line 10061 "gram.y" + { + (yyval.list) = list_make1(makeIntConst(INTERVAL_MASK(SECOND), (yylsp[(1) - (1)]))); + ;} + break; + + case 1530: + +/* Line 1455 of yacc.c */ +#line 10065 "gram.y" + { + (yyval.list) = list_make2(makeIntConst(INTERVAL_MASK(SECOND), (yylsp[(1) - (4)])), + makeIntConst((yyvsp[(3) - (4)].ival), (yylsp[(3) - (4)]))); + ;} + break; + + case 1531: + +/* Line 1455 of yacc.c */ +#line 10094 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 1532: + +/* Line 1455 of yacc.c */ +#line 10096 "gram.y" + { (yyval.node) = makeTypeCast((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].typnam), (yylsp[(2) - (3)])); ;} + break; + + case 1533: + +/* Line 1455 of yacc.c */ +#line 10098 "gram.y" + { + CollateClause *n = makeNode(CollateClause); + n->arg = (yyvsp[(1) - (3)].node); + n->collname = (yyvsp[(3) - (3)].list); + n->location = (yylsp[(2) - (3)]); + (yyval.node) = (Node *) n; + ;} + break; + + case 1534: + +/* Line 1455 of yacc.c */ +#line 10106 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("timezone"); + n->args = list_make2((yyvsp[(5) - (5)].node), (yyvsp[(1) - (5)].node)); + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(2) - (5)]); + (yyval.node) = (Node *) n; + ;} + break; + + case 1535: + +/* Line 1455 of yacc.c */ +#line 10128 "gram.y" + { (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "+", NULL, (yyvsp[(2) - (2)].node), (yylsp[(1) - (2)])); ;} + break; + + case 1536: + +/* Line 1455 of yacc.c */ +#line 10130 "gram.y" + { (yyval.node) = doNegate((yyvsp[(2) - (2)].node), (yylsp[(1) - (2)])); ;} + break; + + case 1537: + +/* Line 1455 of yacc.c */ +#line 10132 "gram.y" + { (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "+", (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); ;} + break; + + case 1538: + +/* Line 1455 of yacc.c */ +#line 10134 "gram.y" + { (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "-", (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); ;} + break; + + case 1539: + +/* Line 1455 of yacc.c */ +#line 10136 "gram.y" + { (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "*", (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); ;} + break; + + case 1540: + +/* Line 1455 of yacc.c */ +#line 10138 "gram.y" + { (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "/", (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); ;} + break; + + case 1541: + +/* Line 1455 of yacc.c */ +#line 10140 "gram.y" + { (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "%", (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); ;} + break; + + case 1542: + +/* Line 1455 of yacc.c */ +#line 10142 "gram.y" + { (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "^", (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); ;} + break; + + case 1543: + +/* Line 1455 of yacc.c */ +#line 10144 "gram.y" + { (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "<", (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); ;} + break; + + case 1544: + +/* Line 1455 of yacc.c */ +#line 10146 "gram.y" + { (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, ">", (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); ;} + break; + + case 1545: + +/* Line 1455 of yacc.c */ +#line 10148 "gram.y" + { (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "=", (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); ;} + break; + + case 1546: + +/* Line 1455 of yacc.c */ +#line 10151 "gram.y" + { (yyval.node) = (Node *) makeA_Expr(AEXPR_OP, (yyvsp[(2) - (3)].list), (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); ;} + break; + + case 1547: + +/* Line 1455 of yacc.c */ +#line 10153 "gram.y" + { (yyval.node) = (Node *) makeA_Expr(AEXPR_OP, (yyvsp[(1) - (2)].list), NULL, (yyvsp[(2) - (2)].node), (yylsp[(1) - (2)])); ;} + break; + + case 1548: + +/* Line 1455 of yacc.c */ +#line 10155 "gram.y" + { (yyval.node) = (Node *) makeA_Expr(AEXPR_OP, (yyvsp[(2) - (2)].list), (yyvsp[(1) - (2)].node), NULL, (yylsp[(2) - (2)])); ;} + break; + + case 1549: + +/* Line 1455 of yacc.c */ +#line 10158 "gram.y" + { (yyval.node) = (Node *) makeA_Expr(AEXPR_AND, NIL, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); ;} + break; + + case 1550: + +/* Line 1455 of yacc.c */ +#line 10160 "gram.y" + { (yyval.node) = (Node *) makeA_Expr(AEXPR_OR, NIL, (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); ;} + break; + + case 1551: + +/* Line 1455 of yacc.c */ +#line 10162 "gram.y" + { (yyval.node) = (Node *) makeA_Expr(AEXPR_NOT, NIL, NULL, (yyvsp[(2) - (2)].node), (yylsp[(1) - (2)])); ;} + break; + + case 1552: + +/* Line 1455 of yacc.c */ +#line 10165 "gram.y" + { (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "~~", (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); ;} + break; + + case 1553: + +/* Line 1455 of yacc.c */ +#line 10167 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("like_escape"); + n->args = list_make2((yyvsp[(3) - (5)].node), (yyvsp[(5) - (5)].node)); + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(2) - (5)]); + (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "~~", (yyvsp[(1) - (5)].node), (Node *) n, (yylsp[(2) - (5)])); + ;} + break; + + case 1554: + +/* Line 1455 of yacc.c */ +#line 10180 "gram.y" + { (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "!~~", (yyvsp[(1) - (4)].node), (yyvsp[(4) - (4)].node), (yylsp[(2) - (4)])); ;} + break; + + case 1555: + +/* Line 1455 of yacc.c */ +#line 10182 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("like_escape"); + n->args = list_make2((yyvsp[(4) - (6)].node), (yyvsp[(6) - (6)].node)); + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(2) - (6)]); + (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "!~~", (yyvsp[(1) - (6)].node), (Node *) n, (yylsp[(2) - (6)])); + ;} + break; + + case 1556: + +/* Line 1455 of yacc.c */ +#line 10195 "gram.y" + { (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "~~*", (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); ;} + break; + + case 1557: + +/* Line 1455 of yacc.c */ +#line 10197 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("like_escape"); + n->args = list_make2((yyvsp[(3) - (5)].node), (yyvsp[(5) - (5)].node)); + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(2) - (5)]); + (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "~~*", (yyvsp[(1) - (5)].node), (Node *) n, (yylsp[(2) - (5)])); + ;} + break; + + case 1558: + +/* Line 1455 of yacc.c */ +#line 10210 "gram.y" + { (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "!~~*", (yyvsp[(1) - (4)].node), (yyvsp[(4) - (4)].node), (yylsp[(2) - (4)])); ;} + break; + + case 1559: + +/* Line 1455 of yacc.c */ +#line 10212 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("like_escape"); + n->args = list_make2((yyvsp[(4) - (6)].node), (yyvsp[(6) - (6)].node)); + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(2) - (6)]); + (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "!~~*", (yyvsp[(1) - (6)].node), (Node *) n, (yylsp[(2) - (6)])); + ;} + break; + + case 1560: + +/* Line 1455 of yacc.c */ +#line 10226 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("similar_escape"); + n->args = list_make2((yyvsp[(4) - (4)].node), makeNullAConst(-1)); + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(2) - (4)]); + (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "~", (yyvsp[(1) - (4)].node), (Node *) n, (yylsp[(2) - (4)])); + ;} + break; + + case 1561: + +/* Line 1455 of yacc.c */ +#line 10239 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("similar_escape"); + n->args = list_make2((yyvsp[(4) - (6)].node), (yyvsp[(6) - (6)].node)); + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(2) - (6)]); + (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "~", (yyvsp[(1) - (6)].node), (Node *) n, (yylsp[(2) - (6)])); + ;} + break; + + case 1562: + +/* Line 1455 of yacc.c */ +#line 10252 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("similar_escape"); + n->args = list_make2((yyvsp[(5) - (5)].node), makeNullAConst(-1)); + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(2) - (5)]); + (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "!~", (yyvsp[(1) - (5)].node), (Node *) n, (yylsp[(2) - (5)])); + ;} + break; + + case 1563: + +/* Line 1455 of yacc.c */ +#line 10265 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("similar_escape"); + n->args = list_make2((yyvsp[(5) - (7)].node), (yyvsp[(7) - (7)].node)); + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(2) - (7)]); + (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "!~", (yyvsp[(1) - (7)].node), (Node *) n, (yylsp[(2) - (7)])); + ;} + break; + + case 1564: + +/* Line 1455 of yacc.c */ +#line 10288 "gram.y" + { + NullTest *n = makeNode(NullTest); + n->arg = (Expr *) (yyvsp[(1) - (3)].node); + n->nulltesttype = IS_NULL; + (yyval.node) = (Node *)n; + ;} + break; + + case 1565: + +/* Line 1455 of yacc.c */ +#line 10295 "gram.y" + { + NullTest *n = makeNode(NullTest); + n->arg = (Expr *) (yyvsp[(1) - (2)].node); + n->nulltesttype = IS_NULL; + (yyval.node) = (Node *)n; + ;} + break; + + case 1566: + +/* Line 1455 of yacc.c */ +#line 10302 "gram.y" + { + NullTest *n = makeNode(NullTest); + n->arg = (Expr *) (yyvsp[(1) - (4)].node); + n->nulltesttype = IS_NOT_NULL; + (yyval.node) = (Node *)n; + ;} + break; + + case 1567: + +/* Line 1455 of yacc.c */ +#line 10309 "gram.y" + { + NullTest *n = makeNode(NullTest); + n->arg = (Expr *) (yyvsp[(1) - (2)].node); + n->nulltesttype = IS_NOT_NULL; + (yyval.node) = (Node *)n; + ;} + break; + + case 1568: + +/* Line 1455 of yacc.c */ +#line 10316 "gram.y" + { + (yyval.node) = (Node *)makeOverlaps((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].list), (yylsp[(2) - (3)]), yyscanner); + ;} + break; + + case 1569: + +/* Line 1455 of yacc.c */ +#line 10320 "gram.y" + { + BooleanTest *b = makeNode(BooleanTest); + b->arg = (Expr *) (yyvsp[(1) - (3)].node); + b->booltesttype = IS_TRUE; + (yyval.node) = (Node *)b; + ;} + break; + + case 1570: + +/* Line 1455 of yacc.c */ +#line 10327 "gram.y" + { + BooleanTest *b = makeNode(BooleanTest); + b->arg = (Expr *) (yyvsp[(1) - (4)].node); + b->booltesttype = IS_NOT_TRUE; + (yyval.node) = (Node *)b; + ;} + break; + + case 1571: + +/* Line 1455 of yacc.c */ +#line 10334 "gram.y" + { + BooleanTest *b = makeNode(BooleanTest); + b->arg = (Expr *) (yyvsp[(1) - (3)].node); + b->booltesttype = IS_FALSE; + (yyval.node) = (Node *)b; + ;} + break; + + case 1572: + +/* Line 1455 of yacc.c */ +#line 10341 "gram.y" + { + BooleanTest *b = makeNode(BooleanTest); + b->arg = (Expr *) (yyvsp[(1) - (4)].node); + b->booltesttype = IS_NOT_FALSE; + (yyval.node) = (Node *)b; + ;} + break; + + case 1573: + +/* Line 1455 of yacc.c */ +#line 10348 "gram.y" + { + BooleanTest *b = makeNode(BooleanTest); + b->arg = (Expr *) (yyvsp[(1) - (3)].node); + b->booltesttype = IS_UNKNOWN; + (yyval.node) = (Node *)b; + ;} + break; + + case 1574: + +/* Line 1455 of yacc.c */ +#line 10355 "gram.y" + { + BooleanTest *b = makeNode(BooleanTest); + b->arg = (Expr *) (yyvsp[(1) - (4)].node); + b->booltesttype = IS_NOT_UNKNOWN; + (yyval.node) = (Node *)b; + ;} + break; + + case 1575: + +/* Line 1455 of yacc.c */ +#line 10362 "gram.y" + { + (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_DISTINCT, "=", (yyvsp[(1) - (5)].node), (yyvsp[(5) - (5)].node), (yylsp[(2) - (5)])); + ;} + break; + + case 1576: + +/* Line 1455 of yacc.c */ +#line 10366 "gram.y" + { + (yyval.node) = (Node *) makeA_Expr(AEXPR_NOT, NIL, NULL, + (Node *) makeSimpleA_Expr(AEXPR_DISTINCT, + "=", (yyvsp[(1) - (6)].node), (yyvsp[(6) - (6)].node), (yylsp[(2) - (6)])), + (yylsp[(2) - (6)])); + + ;} + break; + + case 1577: + +/* Line 1455 of yacc.c */ +#line 10374 "gram.y" + { + (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OF, "=", (yyvsp[(1) - (6)].node), (Node *) (yyvsp[(5) - (6)].list), (yylsp[(2) - (6)])); + ;} + break; + + case 1578: + +/* Line 1455 of yacc.c */ +#line 10378 "gram.y" + { + (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OF, "<>", (yyvsp[(1) - (7)].node), (Node *) (yyvsp[(6) - (7)].list), (yylsp[(2) - (7)])); + ;} + break; + + case 1579: + +/* Line 1455 of yacc.c */ +#line 10388 "gram.y" + { + (yyval.node) = (Node *) makeA_Expr(AEXPR_AND, NIL, + (Node *) makeSimpleA_Expr(AEXPR_OP, ">=", (yyvsp[(1) - (6)].node), (yyvsp[(4) - (6)].node), (yylsp[(2) - (6)])), + (Node *) makeSimpleA_Expr(AEXPR_OP, "<=", (yyvsp[(1) - (6)].node), (yyvsp[(6) - (6)].node), (yylsp[(2) - (6)])), + (yylsp[(2) - (6)])); + ;} + break; + + case 1580: + +/* Line 1455 of yacc.c */ +#line 10395 "gram.y" + { + (yyval.node) = (Node *) makeA_Expr(AEXPR_OR, NIL, + (Node *) makeSimpleA_Expr(AEXPR_OP, "<", (yyvsp[(1) - (7)].node), (yyvsp[(5) - (7)].node), (yylsp[(2) - (7)])), + (Node *) makeSimpleA_Expr(AEXPR_OP, ">", (yyvsp[(1) - (7)].node), (yyvsp[(7) - (7)].node), (yylsp[(2) - (7)])), + (yylsp[(2) - (7)])); + ;} + break; + + case 1581: + +/* Line 1455 of yacc.c */ +#line 10402 "gram.y" + { + (yyval.node) = (Node *) makeA_Expr(AEXPR_OR, NIL, + (Node *) makeA_Expr(AEXPR_AND, NIL, + (Node *) makeSimpleA_Expr(AEXPR_OP, ">=", (yyvsp[(1) - (6)].node), (yyvsp[(4) - (6)].node), (yylsp[(2) - (6)])), + (Node *) makeSimpleA_Expr(AEXPR_OP, "<=", (yyvsp[(1) - (6)].node), (yyvsp[(6) - (6)].node), (yylsp[(2) - (6)])), + (yylsp[(2) - (6)])), + (Node *) makeA_Expr(AEXPR_AND, NIL, + (Node *) makeSimpleA_Expr(AEXPR_OP, ">=", (yyvsp[(1) - (6)].node), (yyvsp[(6) - (6)].node), (yylsp[(2) - (6)])), + (Node *) makeSimpleA_Expr(AEXPR_OP, "<=", (yyvsp[(1) - (6)].node), (yyvsp[(4) - (6)].node), (yylsp[(2) - (6)])), + (yylsp[(2) - (6)])), + (yylsp[(2) - (6)])); + ;} + break; + + case 1582: + +/* Line 1455 of yacc.c */ +#line 10415 "gram.y" + { + (yyval.node) = (Node *) makeA_Expr(AEXPR_AND, NIL, + (Node *) makeA_Expr(AEXPR_OR, NIL, + (Node *) makeSimpleA_Expr(AEXPR_OP, "<", (yyvsp[(1) - (7)].node), (yyvsp[(5) - (7)].node), (yylsp[(2) - (7)])), + (Node *) makeSimpleA_Expr(AEXPR_OP, ">", (yyvsp[(1) - (7)].node), (yyvsp[(7) - (7)].node), (yylsp[(2) - (7)])), + (yylsp[(2) - (7)])), + (Node *) makeA_Expr(AEXPR_OR, NIL, + (Node *) makeSimpleA_Expr(AEXPR_OP, "<", (yyvsp[(1) - (7)].node), (yyvsp[(7) - (7)].node), (yylsp[(2) - (7)])), + (Node *) makeSimpleA_Expr(AEXPR_OP, ">", (yyvsp[(1) - (7)].node), (yyvsp[(5) - (7)].node), (yylsp[(2) - (7)])), + (yylsp[(2) - (7)])), + (yylsp[(2) - (7)])); + ;} + break; + + case 1583: + +/* Line 1455 of yacc.c */ +#line 10428 "gram.y" + { + /* in_expr returns a SubLink or a list of a_exprs */ + if (IsA((yyvsp[(3) - (3)].node), SubLink)) + { + /* generate foo = ANY (subquery) */ + SubLink *n = (SubLink *) (yyvsp[(3) - (3)].node); + n->subLinkType = ANY_SUBLINK; + n->testexpr = (yyvsp[(1) - (3)].node); + n->operName = list_make1(makeString("=")); + n->location = (yylsp[(2) - (3)]); + (yyval.node) = (Node *)n; + } + else + { + /* generate scalar IN expression */ + (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_IN, "=", (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); + } + ;} + break; + + case 1584: + +/* Line 1455 of yacc.c */ +#line 10447 "gram.y" + { + /* in_expr returns a SubLink or a list of a_exprs */ + if (IsA((yyvsp[(4) - (4)].node), SubLink)) + { + /* generate NOT (foo = ANY (subquery)) */ + /* Make an = ANY node */ + SubLink *n = (SubLink *) (yyvsp[(4) - (4)].node); + n->subLinkType = ANY_SUBLINK; + n->testexpr = (yyvsp[(1) - (4)].node); + n->operName = list_make1(makeString("=")); + n->location = (yylsp[(3) - (4)]); + /* Stick a NOT on top */ + (yyval.node) = (Node *) makeA_Expr(AEXPR_NOT, NIL, NULL, (Node *) n, (yylsp[(2) - (4)])); + } + else + { + /* generate scalar NOT IN expression */ + (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_IN, "<>", (yyvsp[(1) - (4)].node), (yyvsp[(4) - (4)].node), (yylsp[(2) - (4)])); + } + ;} + break; + + case 1585: + +/* Line 1455 of yacc.c */ +#line 10468 "gram.y" + { + SubLink *n = makeNode(SubLink); + n->subLinkType = (yyvsp[(3) - (4)].ival); + n->testexpr = (yyvsp[(1) - (4)].node); + n->operName = (yyvsp[(2) - (4)].list); + n->subselect = (yyvsp[(4) - (4)].node); + n->location = (yylsp[(2) - (4)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1586: + +/* Line 1455 of yacc.c */ +#line 10478 "gram.y" + { + if ((yyvsp[(3) - (6)].ival) == ANY_SUBLINK) + (yyval.node) = (Node *) makeA_Expr(AEXPR_OP_ANY, (yyvsp[(2) - (6)].list), (yyvsp[(1) - (6)].node), (yyvsp[(5) - (6)].node), (yylsp[(2) - (6)])); + else + (yyval.node) = (Node *) makeA_Expr(AEXPR_OP_ALL, (yyvsp[(2) - (6)].list), (yyvsp[(1) - (6)].node), (yyvsp[(5) - (6)].node), (yylsp[(2) - (6)])); + ;} + break; + + case 1587: + +/* Line 1455 of yacc.c */ +#line 10485 "gram.y" + { + /* Not sure how to get rid of the parentheses + * but there are lots of shift/reduce errors without them. + * + * Should be able to implement this by plopping the entire + * select into a node, then transforming the target expressions + * from whatever they are into count(*), and testing the + * entire result equal to one. + * But, will probably implement a separate node in the executor. + */ + ereport(ERROR, + (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), + errmsg("UNIQUE predicate is not yet implemented"), + parser_errposition((yylsp[(1) - (2)])))); + ;} + break; + + case 1588: + +/* Line 1455 of yacc.c */ +#line 10501 "gram.y" + { + (yyval.node) = makeXmlExpr(IS_DOCUMENT, NULL, NIL, + list_make1((yyvsp[(1) - (3)].node)), (yylsp[(2) - (3)])); + ;} + break; + + case 1589: + +/* Line 1455 of yacc.c */ +#line 10506 "gram.y" + { + (yyval.node) = (Node *) makeA_Expr(AEXPR_NOT, NIL, NULL, + makeXmlExpr(IS_DOCUMENT, NULL, NIL, + list_make1((yyvsp[(1) - (4)].node)), (yylsp[(2) - (4)])), + (yylsp[(2) - (4)])); + ;} + break; + + case 1590: + +/* Line 1455 of yacc.c */ +#line 10524 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 1591: + +/* Line 1455 of yacc.c */ +#line 10526 "gram.y" + { (yyval.node) = makeTypeCast((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].typnam), (yylsp[(2) - (3)])); ;} + break; + + case 1592: + +/* Line 1455 of yacc.c */ +#line 10528 "gram.y" + { (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "+", NULL, (yyvsp[(2) - (2)].node), (yylsp[(1) - (2)])); ;} + break; + + case 1593: + +/* Line 1455 of yacc.c */ +#line 10530 "gram.y" + { (yyval.node) = doNegate((yyvsp[(2) - (2)].node), (yylsp[(1) - (2)])); ;} + break; + + case 1594: + +/* Line 1455 of yacc.c */ +#line 10532 "gram.y" + { (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "+", (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); ;} + break; + + case 1595: + +/* Line 1455 of yacc.c */ +#line 10534 "gram.y" + { (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "-", (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); ;} + break; + + case 1596: + +/* Line 1455 of yacc.c */ +#line 10536 "gram.y" + { (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "*", (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); ;} + break; + + case 1597: + +/* Line 1455 of yacc.c */ +#line 10538 "gram.y" + { (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "/", (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); ;} + break; + + case 1598: + +/* Line 1455 of yacc.c */ +#line 10540 "gram.y" + { (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "%", (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); ;} + break; + + case 1599: + +/* Line 1455 of yacc.c */ +#line 10542 "gram.y" + { (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "^", (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); ;} + break; + + case 1600: + +/* Line 1455 of yacc.c */ +#line 10544 "gram.y" + { (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "<", (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); ;} + break; + + case 1601: + +/* Line 1455 of yacc.c */ +#line 10546 "gram.y" + { (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, ">", (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); ;} + break; + + case 1602: + +/* Line 1455 of yacc.c */ +#line 10548 "gram.y" + { (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OP, "=", (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); ;} + break; + + case 1603: + +/* Line 1455 of yacc.c */ +#line 10550 "gram.y" + { (yyval.node) = (Node *) makeA_Expr(AEXPR_OP, (yyvsp[(2) - (3)].list), (yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yylsp[(2) - (3)])); ;} + break; + + case 1604: + +/* Line 1455 of yacc.c */ +#line 10552 "gram.y" + { (yyval.node) = (Node *) makeA_Expr(AEXPR_OP, (yyvsp[(1) - (2)].list), NULL, (yyvsp[(2) - (2)].node), (yylsp[(1) - (2)])); ;} + break; + + case 1605: + +/* Line 1455 of yacc.c */ +#line 10554 "gram.y" + { (yyval.node) = (Node *) makeA_Expr(AEXPR_OP, (yyvsp[(2) - (2)].list), (yyvsp[(1) - (2)].node), NULL, (yylsp[(2) - (2)])); ;} + break; + + case 1606: + +/* Line 1455 of yacc.c */ +#line 10556 "gram.y" + { + (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_DISTINCT, "=", (yyvsp[(1) - (5)].node), (yyvsp[(5) - (5)].node), (yylsp[(2) - (5)])); + ;} + break; + + case 1607: + +/* Line 1455 of yacc.c */ +#line 10560 "gram.y" + { + (yyval.node) = (Node *) makeA_Expr(AEXPR_NOT, NIL, + NULL, (Node *) makeSimpleA_Expr(AEXPR_DISTINCT, "=", (yyvsp[(1) - (6)].node), (yyvsp[(6) - (6)].node), (yylsp[(2) - (6)])), (yylsp[(2) - (6)])); + ;} + break; + + case 1608: + +/* Line 1455 of yacc.c */ +#line 10565 "gram.y" + { + (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OF, "=", (yyvsp[(1) - (6)].node), (Node *) (yyvsp[(5) - (6)].list), (yylsp[(2) - (6)])); + ;} + break; + + case 1609: + +/* Line 1455 of yacc.c */ +#line 10569 "gram.y" + { + (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_OF, "<>", (yyvsp[(1) - (7)].node), (Node *) (yyvsp[(6) - (7)].list), (yylsp[(2) - (7)])); + ;} + break; + + case 1610: + +/* Line 1455 of yacc.c */ +#line 10573 "gram.y" + { + (yyval.node) = makeXmlExpr(IS_DOCUMENT, NULL, NIL, + list_make1((yyvsp[(1) - (3)].node)), (yylsp[(2) - (3)])); + ;} + break; + + case 1611: + +/* Line 1455 of yacc.c */ +#line 10578 "gram.y" + { + (yyval.node) = (Node *) makeA_Expr(AEXPR_NOT, NIL, NULL, + makeXmlExpr(IS_DOCUMENT, NULL, NIL, + list_make1((yyvsp[(1) - (4)].node)), (yylsp[(2) - (4)])), + (yylsp[(2) - (4)])); + ;} + break; + + case 1612: + +/* Line 1455 of yacc.c */ +#line 10594 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 1613: + +/* Line 1455 of yacc.c */ +#line 10595 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 1614: + +/* Line 1455 of yacc.c */ +#line 10597 "gram.y" + { + ParamRef *p = makeNode(ParamRef); + p->number = (yyvsp[(1) - (2)].ival); + p->location = (yylsp[(1) - (2)]); + if ((yyvsp[(2) - (2)].list)) + { + A_Indirection *n = makeNode(A_Indirection); + n->arg = (Node *) p; + n->indirection = check_indirection((yyvsp[(2) - (2)].list), yyscanner); + (yyval.node) = (Node *) n; + } + else + (yyval.node) = (Node *) p; + ;} + break; + + case 1615: + +/* Line 1455 of yacc.c */ +#line 10612 "gram.y" + { + if ((yyvsp[(4) - (4)].list)) + { + A_Indirection *n = makeNode(A_Indirection); + n->arg = (yyvsp[(2) - (4)].node); + n->indirection = check_indirection((yyvsp[(4) - (4)].list), yyscanner); + (yyval.node) = (Node *)n; + } + else + (yyval.node) = (yyvsp[(2) - (4)].node); + ;} + break; + + case 1616: + +/* Line 1455 of yacc.c */ +#line 10624 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 1617: + +/* Line 1455 of yacc.c */ +#line 10626 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 1618: + +/* Line 1455 of yacc.c */ +#line 10628 "gram.y" + { + SubLink *n = makeNode(SubLink); + n->subLinkType = EXPR_SUBLINK; + n->testexpr = NULL; + n->operName = NIL; + n->subselect = (yyvsp[(1) - (1)].node); + n->location = (yylsp[(1) - (1)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1619: + +/* Line 1455 of yacc.c */ +#line 10638 "gram.y" + { + SubLink *n = makeNode(SubLink); + n->subLinkType = EXISTS_SUBLINK; + n->testexpr = NULL; + n->operName = NIL; + n->subselect = (yyvsp[(2) - (2)].node); + n->location = (yylsp[(1) - (2)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1620: + +/* Line 1455 of yacc.c */ +#line 10648 "gram.y" + { + SubLink *n = makeNode(SubLink); + n->subLinkType = ARRAY_SUBLINK; + n->testexpr = NULL; + n->operName = NIL; + n->subselect = (yyvsp[(2) - (2)].node); + n->location = (yylsp[(1) - (2)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1621: + +/* Line 1455 of yacc.c */ +#line 10658 "gram.y" + { + A_ArrayExpr *n = (A_ArrayExpr *) (yyvsp[(2) - (2)].node); + Assert(IsA(n, A_ArrayExpr)); + /* point outermost A_ArrayExpr to the ARRAY keyword */ + n->location = (yylsp[(1) - (2)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1622: + +/* Line 1455 of yacc.c */ +#line 10666 "gram.y" + { + RowExpr *r = makeNode(RowExpr); + r->args = (yyvsp[(1) - (1)].list); + r->row_typeid = InvalidOid; /* not analyzed yet */ + r->colnames = NIL; /* to be filled in during analysis */ + r->location = (yylsp[(1) - (1)]); + (yyval.node) = (Node *)r; + ;} + break; + + case 1623: + +/* Line 1455 of yacc.c */ +#line 10685 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = (yyvsp[(1) - (4)].list); + n->args = NIL; + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = (yyvsp[(4) - (4)].windef); + n->location = (yylsp[(1) - (4)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1624: + +/* Line 1455 of yacc.c */ +#line 10698 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = (yyvsp[(1) - (5)].list); + n->args = (yyvsp[(3) - (5)].list); + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = (yyvsp[(5) - (5)].windef); + n->location = (yylsp[(1) - (5)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1625: + +/* Line 1455 of yacc.c */ +#line 10711 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = (yyvsp[(1) - (6)].list); + n->args = list_make1((yyvsp[(4) - (6)].node)); + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = TRUE; + n->over = (yyvsp[(6) - (6)].windef); + n->location = (yylsp[(1) - (6)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1626: + +/* Line 1455 of yacc.c */ +#line 10724 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = (yyvsp[(1) - (8)].list); + n->args = lappend((yyvsp[(3) - (8)].list), (yyvsp[(6) - (8)].node)); + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = TRUE; + n->over = (yyvsp[(8) - (8)].windef); + n->location = (yylsp[(1) - (8)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1627: + +/* Line 1455 of yacc.c */ +#line 10737 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = (yyvsp[(1) - (6)].list); + n->args = (yyvsp[(3) - (6)].list); + n->agg_order = (yyvsp[(4) - (6)].list); + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = (yyvsp[(6) - (6)].windef); + n->location = (yylsp[(1) - (6)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1628: + +/* Line 1455 of yacc.c */ +#line 10750 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = (yyvsp[(1) - (7)].list); + n->args = (yyvsp[(4) - (7)].list); + n->agg_order = (yyvsp[(5) - (7)].list); + n->agg_star = FALSE; + n->agg_distinct = FALSE; + /* Ideally we'd mark the FuncCall node to indicate + * "must be an aggregate", but there's no provision + * for that in FuncCall at the moment. + */ + n->func_variadic = FALSE; + n->over = (yyvsp[(7) - (7)].windef); + n->location = (yylsp[(1) - (7)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1629: + +/* Line 1455 of yacc.c */ +#line 10767 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = (yyvsp[(1) - (7)].list); + n->args = (yyvsp[(4) - (7)].list); + n->agg_order = (yyvsp[(5) - (7)].list); + n->agg_star = FALSE; + n->agg_distinct = TRUE; + n->func_variadic = FALSE; + n->over = (yyvsp[(7) - (7)].windef); + n->location = (yylsp[(1) - (7)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1630: + +/* Line 1455 of yacc.c */ +#line 10780 "gram.y" + { + /* + * We consider AGGREGATE(*) to invoke a parameterless + * aggregate. This does the right thing for COUNT(*), + * and there are no other aggregates in SQL92 that accept + * '*' as parameter. + * + * The FuncCall node is also marked agg_star = true, + * so that later processing can detect what the argument + * really was. + */ + FuncCall *n = makeNode(FuncCall); + n->funcname = (yyvsp[(1) - (5)].list); + n->args = NIL; + n->agg_order = NIL; + n->agg_star = TRUE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = (yyvsp[(5) - (5)].windef); + n->location = (yylsp[(1) - (5)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1631: + +/* Line 1455 of yacc.c */ +#line 10803 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("pg_collation_for"); + n->args = list_make1((yyvsp[(4) - (5)].node)); + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(1) - (5)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1632: + +/* Line 1455 of yacc.c */ +#line 10816 "gram.y" + { + /* + * Translate as "'now'::text::date". + * + * We cannot use "'now'::date" because coerce_type() will + * immediately reduce that to a constant representing + * today's date. We need to delay the conversion until + * runtime, else the wrong things will happen when + * CURRENT_DATE is used in a column default value or rule. + * + * This could be simplified if we had a way to generate + * an expression tree representing runtime application + * of type-input conversion functions. (As of PG 7.3 + * that is actually possible, but not clear that we want + * to rely on it.) + */ + Node *n; + n = makeStringConstCast("now", (yylsp[(1) - (1)]), SystemTypeName("text")); + (yyval.node) = makeTypeCast(n, SystemTypeName("date"), -1); + ;} + break; + + case 1633: + +/* Line 1455 of yacc.c */ +#line 10837 "gram.y" + { + /* + * Translate as "'now'::text::timetz". + * See comments for CURRENT_DATE. + */ + Node *n; + n = makeStringConstCast("now", (yylsp[(1) - (1)]), SystemTypeName("text")); + (yyval.node) = makeTypeCast(n, SystemTypeName("timetz"), -1); + ;} + break; + + case 1634: + +/* Line 1455 of yacc.c */ +#line 10847 "gram.y" + { + /* + * Translate as "'now'::text::timetz(n)". + * See comments for CURRENT_DATE. + */ + Node *n; + TypeName *d; + n = makeStringConstCast("now", (yylsp[(1) - (4)]), SystemTypeName("text")); + d = SystemTypeName("timetz"); + d->typmods = list_make1(makeIntConst((yyvsp[(3) - (4)].ival), (yylsp[(3) - (4)]))); + (yyval.node) = makeTypeCast(n, d, -1); + ;} + break; + + case 1635: + +/* Line 1455 of yacc.c */ +#line 10860 "gram.y" + { + /* + * Translate as "now()", since we have a function that + * does exactly what is needed. + */ + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("now"); + n->args = NIL; + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(1) - (1)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1636: + +/* Line 1455 of yacc.c */ +#line 10877 "gram.y" + { + /* + * Translate as "'now'::text::timestamptz(n)". + * See comments for CURRENT_DATE. + */ + Node *n; + TypeName *d; + n = makeStringConstCast("now", (yylsp[(1) - (4)]), SystemTypeName("text")); + d = SystemTypeName("timestamptz"); + d->typmods = list_make1(makeIntConst((yyvsp[(3) - (4)].ival), (yylsp[(3) - (4)]))); + (yyval.node) = makeTypeCast(n, d, -1); + ;} + break; + + case 1637: + +/* Line 1455 of yacc.c */ +#line 10890 "gram.y" + { + /* + * Translate as "'now'::text::time". + * See comments for CURRENT_DATE. + */ + Node *n; + n = makeStringConstCast("now", (yylsp[(1) - (1)]), SystemTypeName("text")); + (yyval.node) = makeTypeCast((Node *)n, SystemTypeName("time"), -1); + ;} + break; + + case 1638: + +/* Line 1455 of yacc.c */ +#line 10900 "gram.y" + { + /* + * Translate as "'now'::text::time(n)". + * See comments for CURRENT_DATE. + */ + Node *n; + TypeName *d; + n = makeStringConstCast("now", (yylsp[(1) - (4)]), SystemTypeName("text")); + d = SystemTypeName("time"); + d->typmods = list_make1(makeIntConst((yyvsp[(3) - (4)].ival), (yylsp[(3) - (4)]))); + (yyval.node) = makeTypeCast((Node *)n, d, -1); + ;} + break; + + case 1639: + +/* Line 1455 of yacc.c */ +#line 10913 "gram.y" + { + /* + * Translate as "'now'::text::timestamp". + * See comments for CURRENT_DATE. + */ + Node *n; + n = makeStringConstCast("now", (yylsp[(1) - (1)]), SystemTypeName("text")); + (yyval.node) = makeTypeCast(n, SystemTypeName("timestamp"), -1); + ;} + break; + + case 1640: + +/* Line 1455 of yacc.c */ +#line 10923 "gram.y" + { + /* + * Translate as "'now'::text::timestamp(n)". + * See comments for CURRENT_DATE. + */ + Node *n; + TypeName *d; + n = makeStringConstCast("now", (yylsp[(1) - (4)]), SystemTypeName("text")); + d = SystemTypeName("timestamp"); + d->typmods = list_make1(makeIntConst((yyvsp[(3) - (4)].ival), (yylsp[(3) - (4)]))); + (yyval.node) = makeTypeCast(n, d, -1); + ;} + break; + + case 1641: + +/* Line 1455 of yacc.c */ +#line 10936 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("current_user"); + n->args = NIL; + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(1) - (1)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1642: + +/* Line 1455 of yacc.c */ +#line 10949 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("current_user"); + n->args = NIL; + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(1) - (1)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1643: + +/* Line 1455 of yacc.c */ +#line 10962 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("session_user"); + n->args = NIL; + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(1) - (1)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1644: + +/* Line 1455 of yacc.c */ +#line 10975 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("current_user"); + n->args = NIL; + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(1) - (1)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1645: + +/* Line 1455 of yacc.c */ +#line 10988 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("current_database"); + n->args = NIL; + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(1) - (1)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1646: + +/* Line 1455 of yacc.c */ +#line 11001 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("current_schema"); + n->args = NIL; + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(1) - (1)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1647: + +/* Line 1455 of yacc.c */ +#line 11014 "gram.y" + { (yyval.node) = makeTypeCast((yyvsp[(3) - (6)].node), (yyvsp[(5) - (6)].typnam), (yylsp[(1) - (6)])); ;} + break; + + case 1648: + +/* Line 1455 of yacc.c */ +#line 11016 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("date_part"); + n->args = (yyvsp[(3) - (4)].list); + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(1) - (4)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1649: + +/* Line 1455 of yacc.c */ +#line 11029 "gram.y" + { + /* overlay(A PLACING B FROM C FOR D) is converted to + * overlay(A, B, C, D) + * overlay(A PLACING B FROM C) is converted to + * overlay(A, B, C) + */ + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("overlay"); + n->args = (yyvsp[(3) - (4)].list); + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(1) - (4)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1650: + +/* Line 1455 of yacc.c */ +#line 11047 "gram.y" + { + /* position(A in B) is converted to position(B, A) */ + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("position"); + n->args = (yyvsp[(3) - (4)].list); + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(1) - (4)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1651: + +/* Line 1455 of yacc.c */ +#line 11061 "gram.y" + { + /* substring(A from B for C) is converted to + * substring(A, B, C) - thomas 2000-11-28 + */ + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("substring"); + n->args = (yyvsp[(3) - (4)].list); + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(1) - (4)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1652: + +/* Line 1455 of yacc.c */ +#line 11077 "gram.y" + { + /* TREAT(expr AS target) converts expr of a particular type to target, + * which is defined to be a subtype of the original expression. + * In SQL99, this is intended for use with structured UDTs, + * but let's make this a generally useful form allowing stronger + * coercions than are handled by implicit casting. + */ + FuncCall *n = makeNode(FuncCall); + /* Convert SystemTypeName() to SystemFuncName() even though + * at the moment they result in the same thing. + */ + n->funcname = SystemFuncName(((Value *)llast((yyvsp[(5) - (6)].typnam)->names))->val.str); + n->args = list_make1((yyvsp[(3) - (6)].node)); + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(1) - (6)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1653: + +/* Line 1455 of yacc.c */ +#line 11099 "gram.y" + { + /* various trim expressions are defined in SQL92 + * - thomas 1997-07-19 + */ + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("btrim"); + n->args = (yyvsp[(4) - (5)].list); + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(1) - (5)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1654: + +/* Line 1455 of yacc.c */ +#line 11115 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("ltrim"); + n->args = (yyvsp[(4) - (5)].list); + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(1) - (5)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1655: + +/* Line 1455 of yacc.c */ +#line 11128 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("rtrim"); + n->args = (yyvsp[(4) - (5)].list); + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(1) - (5)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1656: + +/* Line 1455 of yacc.c */ +#line 11141 "gram.y" + { + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("btrim"); + n->args = (yyvsp[(3) - (4)].list); + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(1) - (4)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1657: + +/* Line 1455 of yacc.c */ +#line 11154 "gram.y" + { + (yyval.node) = (Node *) makeSimpleA_Expr(AEXPR_NULLIF, "=", (yyvsp[(3) - (6)].node), (yyvsp[(5) - (6)].node), (yylsp[(1) - (6)])); + ;} + break; + + case 1658: + +/* Line 1455 of yacc.c */ +#line 11158 "gram.y" + { + CoalesceExpr *c = makeNode(CoalesceExpr); + c->args = (yyvsp[(3) - (4)].list); + c->location = (yylsp[(1) - (4)]); + (yyval.node) = (Node *)c; + ;} + break; + + case 1659: + +/* Line 1455 of yacc.c */ +#line 11165 "gram.y" + { + MinMaxExpr *v = makeNode(MinMaxExpr); + v->args = (yyvsp[(3) - (4)].list); + v->op = IS_GREATEST; + v->location = (yylsp[(1) - (4)]); + (yyval.node) = (Node *)v; + ;} + break; + + case 1660: + +/* Line 1455 of yacc.c */ +#line 11173 "gram.y" + { + MinMaxExpr *v = makeNode(MinMaxExpr); + v->args = (yyvsp[(3) - (4)].list); + v->op = IS_LEAST; + v->location = (yylsp[(1) - (4)]); + (yyval.node) = (Node *)v; + ;} + break; + + case 1661: + +/* Line 1455 of yacc.c */ +#line 11181 "gram.y" + { + (yyval.node) = makeXmlExpr(IS_XMLCONCAT, NULL, NIL, (yyvsp[(3) - (4)].list), (yylsp[(1) - (4)])); + ;} + break; + + case 1662: + +/* Line 1455 of yacc.c */ +#line 11185 "gram.y" + { + (yyval.node) = makeXmlExpr(IS_XMLELEMENT, (yyvsp[(4) - (5)].str), NIL, NIL, (yylsp[(1) - (5)])); + ;} + break; + + case 1663: + +/* Line 1455 of yacc.c */ +#line 11189 "gram.y" + { + (yyval.node) = makeXmlExpr(IS_XMLELEMENT, (yyvsp[(4) - (7)].str), (yyvsp[(6) - (7)].list), NIL, (yylsp[(1) - (7)])); + ;} + break; + + case 1664: + +/* Line 1455 of yacc.c */ +#line 11193 "gram.y" + { + (yyval.node) = makeXmlExpr(IS_XMLELEMENT, (yyvsp[(4) - (7)].str), NIL, (yyvsp[(6) - (7)].list), (yylsp[(1) - (7)])); + ;} + break; + + case 1665: + +/* Line 1455 of yacc.c */ +#line 11197 "gram.y" + { + (yyval.node) = makeXmlExpr(IS_XMLELEMENT, (yyvsp[(4) - (9)].str), (yyvsp[(6) - (9)].list), (yyvsp[(8) - (9)].list), (yylsp[(1) - (9)])); + ;} + break; + + case 1666: + +/* Line 1455 of yacc.c */ +#line 11201 "gram.y" + { + /* xmlexists(A PASSING [BY REF] B [BY REF]) is + * converted to xmlexists(A, B)*/ + FuncCall *n = makeNode(FuncCall); + n->funcname = SystemFuncName("xmlexists"); + n->args = list_make2((yyvsp[(3) - (5)].node), (yyvsp[(4) - (5)].node)); + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = (yylsp[(1) - (5)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1667: + +/* Line 1455 of yacc.c */ +#line 11216 "gram.y" + { + (yyval.node) = makeXmlExpr(IS_XMLFOREST, NULL, (yyvsp[(3) - (4)].list), NIL, (yylsp[(1) - (4)])); + ;} + break; + + case 1668: + +/* Line 1455 of yacc.c */ +#line 11220 "gram.y" + { + XmlExpr *x = (XmlExpr *) + makeXmlExpr(IS_XMLPARSE, NULL, NIL, + list_make2((yyvsp[(4) - (6)].node), makeBoolAConst((yyvsp[(5) - (6)].boolean), -1)), + (yylsp[(1) - (6)])); + x->xmloption = (yyvsp[(3) - (6)].ival); + (yyval.node) = (Node *)x; + ;} + break; + + case 1669: + +/* Line 1455 of yacc.c */ +#line 11229 "gram.y" + { + (yyval.node) = makeXmlExpr(IS_XMLPI, (yyvsp[(4) - (5)].str), NULL, NIL, (yylsp[(1) - (5)])); + ;} + break; + + case 1670: + +/* Line 1455 of yacc.c */ +#line 11233 "gram.y" + { + (yyval.node) = makeXmlExpr(IS_XMLPI, (yyvsp[(4) - (7)].str), NULL, list_make1((yyvsp[(6) - (7)].node)), (yylsp[(1) - (7)])); + ;} + break; + + case 1671: + +/* Line 1455 of yacc.c */ +#line 11237 "gram.y" + { + (yyval.node) = makeXmlExpr(IS_XMLROOT, NULL, NIL, + list_make3((yyvsp[(3) - (7)].node), (yyvsp[(5) - (7)].node), (yyvsp[(6) - (7)].node)), (yylsp[(1) - (7)])); + ;} + break; + + case 1672: + +/* Line 1455 of yacc.c */ +#line 11242 "gram.y" + { + XmlSerialize *n = makeNode(XmlSerialize); + n->xmloption = (yyvsp[(3) - (7)].ival); + n->expr = (yyvsp[(4) - (7)].node); + n->typeName = (yyvsp[(6) - (7)].typnam); + n->location = (yylsp[(1) - (7)]); + (yyval.node) = (Node *)n; + ;} + break; + + case 1673: + +/* Line 1455 of yacc.c */ +#line 11256 "gram.y" + { (yyval.node) = (yyvsp[(2) - (2)].node); ;} + break; + + case 1674: + +/* Line 1455 of yacc.c */ +#line 11258 "gram.y" + { (yyval.node) = makeNullAConst(-1); ;} + break; + + case 1675: + +/* Line 1455 of yacc.c */ +#line 11262 "gram.y" + { (yyval.node) = makeIntConst(XML_STANDALONE_YES, -1); ;} + break; + + case 1676: + +/* Line 1455 of yacc.c */ +#line 11264 "gram.y" + { (yyval.node) = makeIntConst(XML_STANDALONE_NO, -1); ;} + break; + + case 1677: + +/* Line 1455 of yacc.c */ +#line 11266 "gram.y" + { (yyval.node) = makeIntConst(XML_STANDALONE_NO_VALUE, -1); ;} + break; + + case 1678: + +/* Line 1455 of yacc.c */ +#line 11268 "gram.y" + { (yyval.node) = makeIntConst(XML_STANDALONE_OMITTED, -1); ;} + break; + + case 1679: + +/* Line 1455 of yacc.c */ +#line 11271 "gram.y" + { (yyval.list) = (yyvsp[(3) - (4)].list); ;} + break; + + case 1680: + +/* Line 1455 of yacc.c */ +#line 11274 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].target)); ;} + break; + + case 1681: + +/* Line 1455 of yacc.c */ +#line 11275 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].target)); ;} + break; + + case 1682: + +/* Line 1455 of yacc.c */ +#line 11279 "gram.y" + { + (yyval.target) = makeNode(ResTarget); + (yyval.target)->name = (yyvsp[(3) - (3)].str); + (yyval.target)->indirection = NIL; + (yyval.target)->val = (Node *) (yyvsp[(1) - (3)].node); + (yyval.target)->location = (yylsp[(1) - (3)]); + ;} + break; + + case 1683: + +/* Line 1455 of yacc.c */ +#line 11287 "gram.y" + { + (yyval.target) = makeNode(ResTarget); + (yyval.target)->name = NULL; + (yyval.target)->indirection = NIL; + (yyval.target)->val = (Node *) (yyvsp[(1) - (1)].node); + (yyval.target)->location = (yylsp[(1) - (1)]); + ;} + break; + + case 1684: + +/* Line 1455 of yacc.c */ +#line 11296 "gram.y" + { (yyval.ival) = XMLOPTION_DOCUMENT; ;} + break; + + case 1685: + +/* Line 1455 of yacc.c */ +#line 11297 "gram.y" + { (yyval.ival) = XMLOPTION_CONTENT; ;} + break; + + case 1686: + +/* Line 1455 of yacc.c */ +#line 11300 "gram.y" + { (yyval.boolean) = TRUE; ;} + break; + + case 1687: + +/* Line 1455 of yacc.c */ +#line 11301 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 1688: + +/* Line 1455 of yacc.c */ +#line 11302 "gram.y" + { (yyval.boolean) = FALSE; ;} + break; + + case 1689: + +/* Line 1455 of yacc.c */ +#line 11308 "gram.y" + { + (yyval.node) = (yyvsp[(2) - (2)].node); + ;} + break; + + case 1690: + +/* Line 1455 of yacc.c */ +#line 11312 "gram.y" + { + (yyval.node) = (yyvsp[(2) - (4)].node); + ;} + break; + + case 1691: + +/* Line 1455 of yacc.c */ +#line 11316 "gram.y" + { + (yyval.node) = (yyvsp[(4) - (4)].node); + ;} + break; + + case 1692: + +/* Line 1455 of yacc.c */ +#line 11320 "gram.y" + { + (yyval.node) = (yyvsp[(4) - (6)].node); + ;} + break; + + case 1693: + +/* Line 1455 of yacc.c */ +#line 11330 "gram.y" + { (yyval.list) = (yyvsp[(2) - (2)].list); ;} + break; + + case 1694: + +/* Line 1455 of yacc.c */ +#line 11331 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1695: + +/* Line 1455 of yacc.c */ +#line 11335 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].windef)); ;} + break; + + case 1696: + +/* Line 1455 of yacc.c */ +#line 11337 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].windef)); ;} + break; + + case 1697: + +/* Line 1455 of yacc.c */ +#line 11342 "gram.y" + { + WindowDef *n = (yyvsp[(3) - (3)].windef); + n->name = (yyvsp[(1) - (3)].str); + (yyval.windef) = n; + ;} + break; + + case 1698: + +/* Line 1455 of yacc.c */ +#line 11350 "gram.y" + { (yyval.windef) = (yyvsp[(2) - (2)].windef); ;} + break; + + case 1699: + +/* Line 1455 of yacc.c */ +#line 11352 "gram.y" + { + WindowDef *n = makeNode(WindowDef); + n->name = (yyvsp[(2) - (2)].str); + n->refname = NULL; + n->partitionClause = NIL; + n->orderClause = NIL; + n->frameOptions = FRAMEOPTION_DEFAULTS; + n->startOffset = NULL; + n->endOffset = NULL; + n->location = (yylsp[(2) - (2)]); + (yyval.windef) = n; + ;} + break; + + case 1700: + +/* Line 1455 of yacc.c */ +#line 11365 "gram.y" + { (yyval.windef) = NULL; ;} + break; + + case 1701: + +/* Line 1455 of yacc.c */ +#line 11370 "gram.y" + { + WindowDef *n = makeNode(WindowDef); + n->name = NULL; + n->refname = (yyvsp[(2) - (6)].str); + n->partitionClause = (yyvsp[(3) - (6)].list); + n->orderClause = (yyvsp[(4) - (6)].list); + /* copy relevant fields of opt_frame_clause */ + n->frameOptions = (yyvsp[(5) - (6)].windef)->frameOptions; + n->startOffset = (yyvsp[(5) - (6)].windef)->startOffset; + n->endOffset = (yyvsp[(5) - (6)].windef)->endOffset; + n->location = (yylsp[(1) - (6)]); + (yyval.windef) = n; + ;} + break; + + case 1702: + +/* Line 1455 of yacc.c */ +#line 11395 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 1703: + +/* Line 1455 of yacc.c */ +#line 11396 "gram.y" + { (yyval.str) = NULL; ;} + break; + + case 1704: + +/* Line 1455 of yacc.c */ +#line 11399 "gram.y" + { (yyval.list) = (yyvsp[(3) - (3)].list); ;} + break; + + case 1705: + +/* Line 1455 of yacc.c */ +#line 11400 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1706: + +/* Line 1455 of yacc.c */ +#line 11412 "gram.y" + { + WindowDef *n = (yyvsp[(2) - (2)].windef); + n->frameOptions |= FRAMEOPTION_NONDEFAULT | FRAMEOPTION_RANGE; + if (n->frameOptions & (FRAMEOPTION_START_VALUE_PRECEDING | + FRAMEOPTION_END_VALUE_PRECEDING)) + ereport(ERROR, + (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), + errmsg("RANGE PRECEDING is only supported with UNBOUNDED"), + parser_errposition((yylsp[(1) - (2)])))); + if (n->frameOptions & (FRAMEOPTION_START_VALUE_FOLLOWING | + FRAMEOPTION_END_VALUE_FOLLOWING)) + ereport(ERROR, + (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), + errmsg("RANGE FOLLOWING is only supported with UNBOUNDED"), + parser_errposition((yylsp[(1) - (2)])))); + (yyval.windef) = n; + ;} + break; + + case 1707: + +/* Line 1455 of yacc.c */ +#line 11430 "gram.y" + { + WindowDef *n = (yyvsp[(2) - (2)].windef); + n->frameOptions |= FRAMEOPTION_NONDEFAULT | FRAMEOPTION_ROWS; + (yyval.windef) = n; + ;} + break; + + case 1708: + +/* Line 1455 of yacc.c */ +#line 11436 "gram.y" + { + WindowDef *n = makeNode(WindowDef); + n->frameOptions = FRAMEOPTION_DEFAULTS; + n->startOffset = NULL; + n->endOffset = NULL; + (yyval.windef) = n; + ;} + break; + + case 1709: + +/* Line 1455 of yacc.c */ +#line 11446 "gram.y" + { + WindowDef *n = (yyvsp[(1) - (1)].windef); + /* reject invalid cases */ + if (n->frameOptions & FRAMEOPTION_START_UNBOUNDED_FOLLOWING) + ereport(ERROR, + (errcode(ERRCODE_WINDOWING_ERROR), + errmsg("frame start cannot be UNBOUNDED FOLLOWING"), + parser_errposition((yylsp[(1) - (1)])))); + if (n->frameOptions & FRAMEOPTION_START_VALUE_FOLLOWING) + ereport(ERROR, + (errcode(ERRCODE_WINDOWING_ERROR), + errmsg("frame starting from following row cannot end with current row"), + parser_errposition((yylsp[(1) - (1)])))); + n->frameOptions |= FRAMEOPTION_END_CURRENT_ROW; + (yyval.windef) = n; + ;} + break; + + case 1710: + +/* Line 1455 of yacc.c */ +#line 11463 "gram.y" + { + WindowDef *n1 = (yyvsp[(2) - (4)].windef); + WindowDef *n2 = (yyvsp[(4) - (4)].windef); + /* form merged options */ + int frameOptions = n1->frameOptions; + /* shift converts START_ options to END_ options */ + frameOptions |= n2->frameOptions << 1; + frameOptions |= FRAMEOPTION_BETWEEN; + /* reject invalid cases */ + if (frameOptions & FRAMEOPTION_START_UNBOUNDED_FOLLOWING) + ereport(ERROR, + (errcode(ERRCODE_WINDOWING_ERROR), + errmsg("frame start cannot be UNBOUNDED FOLLOWING"), + parser_errposition((yylsp[(2) - (4)])))); + if (frameOptions & FRAMEOPTION_END_UNBOUNDED_PRECEDING) + ereport(ERROR, + (errcode(ERRCODE_WINDOWING_ERROR), + errmsg("frame end cannot be UNBOUNDED PRECEDING"), + parser_errposition((yylsp[(4) - (4)])))); + if ((frameOptions & FRAMEOPTION_START_CURRENT_ROW) && + (frameOptions & FRAMEOPTION_END_VALUE_PRECEDING)) + ereport(ERROR, + (errcode(ERRCODE_WINDOWING_ERROR), + errmsg("frame starting from current row cannot have preceding rows"), + parser_errposition((yylsp[(4) - (4)])))); + if ((frameOptions & FRAMEOPTION_START_VALUE_FOLLOWING) && + (frameOptions & (FRAMEOPTION_END_VALUE_PRECEDING | + FRAMEOPTION_END_CURRENT_ROW))) + ereport(ERROR, + (errcode(ERRCODE_WINDOWING_ERROR), + errmsg("frame starting from following row cannot have preceding rows"), + parser_errposition((yylsp[(4) - (4)])))); + n1->frameOptions = frameOptions; + n1->endOffset = n2->startOffset; + (yyval.windef) = n1; + ;} + break; + + case 1711: + +/* Line 1455 of yacc.c */ +#line 11508 "gram.y" + { + WindowDef *n = makeNode(WindowDef); + n->frameOptions = FRAMEOPTION_START_UNBOUNDED_PRECEDING; + n->startOffset = NULL; + n->endOffset = NULL; + (yyval.windef) = n; + ;} + break; + + case 1712: + +/* Line 1455 of yacc.c */ +#line 11516 "gram.y" + { + WindowDef *n = makeNode(WindowDef); + n->frameOptions = FRAMEOPTION_START_UNBOUNDED_FOLLOWING; + n->startOffset = NULL; + n->endOffset = NULL; + (yyval.windef) = n; + ;} + break; + + case 1713: + +/* Line 1455 of yacc.c */ +#line 11524 "gram.y" + { + WindowDef *n = makeNode(WindowDef); + n->frameOptions = FRAMEOPTION_START_CURRENT_ROW; + n->startOffset = NULL; + n->endOffset = NULL; + (yyval.windef) = n; + ;} + break; + + case 1714: + +/* Line 1455 of yacc.c */ +#line 11532 "gram.y" + { + WindowDef *n = makeNode(WindowDef); + n->frameOptions = FRAMEOPTION_START_VALUE_PRECEDING; + n->startOffset = (yyvsp[(1) - (2)].node); + n->endOffset = NULL; + (yyval.windef) = n; + ;} + break; + + case 1715: + +/* Line 1455 of yacc.c */ +#line 11540 "gram.y" + { + WindowDef *n = makeNode(WindowDef); + n->frameOptions = FRAMEOPTION_START_VALUE_FOLLOWING; + n->startOffset = (yyvsp[(1) - (2)].node); + n->endOffset = NULL; + (yyval.windef) = n; + ;} + break; + + case 1716: + +/* Line 1455 of yacc.c */ +#line 11560 "gram.y" + { (yyval.list) = (yyvsp[(3) - (4)].list); ;} + break; + + case 1717: + +/* Line 1455 of yacc.c */ +#line 11561 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1718: + +/* Line 1455 of yacc.c */ +#line 11562 "gram.y" + { (yyval.list) = lappend((yyvsp[(2) - (5)].list), (yyvsp[(4) - (5)].node)); ;} + break; + + case 1719: + +/* Line 1455 of yacc.c */ +#line 11565 "gram.y" + { (yyval.ival) = ANY_SUBLINK; ;} + break; + + case 1720: + +/* Line 1455 of yacc.c */ +#line 11566 "gram.y" + { (yyval.ival) = ANY_SUBLINK; ;} + break; + + case 1721: + +/* Line 1455 of yacc.c */ +#line 11567 "gram.y" + { (yyval.ival) = ALL_SUBLINK; ;} + break; + + case 1722: + +/* Line 1455 of yacc.c */ +#line 11570 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 1723: + +/* Line 1455 of yacc.c */ +#line 11571 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 1724: + +/* Line 1455 of yacc.c */ +#line 11574 "gram.y" + { (yyval.str) = "+"; ;} + break; + + case 1725: + +/* Line 1455 of yacc.c */ +#line 11575 "gram.y" + { (yyval.str) = "-"; ;} + break; + + case 1726: + +/* Line 1455 of yacc.c */ +#line 11576 "gram.y" + { (yyval.str) = "*"; ;} + break; + + case 1727: + +/* Line 1455 of yacc.c */ +#line 11577 "gram.y" + { (yyval.str) = "/"; ;} + break; + + case 1728: + +/* Line 1455 of yacc.c */ +#line 11578 "gram.y" + { (yyval.str) = "%"; ;} + break; + + case 1729: + +/* Line 1455 of yacc.c */ +#line 11579 "gram.y" + { (yyval.str) = "^"; ;} + break; + + case 1730: + +/* Line 1455 of yacc.c */ +#line 11580 "gram.y" + { (yyval.str) = "<"; ;} + break; + + case 1731: + +/* Line 1455 of yacc.c */ +#line 11581 "gram.y" + { (yyval.str) = ">"; ;} + break; + + case 1732: + +/* Line 1455 of yacc.c */ +#line 11582 "gram.y" + { (yyval.str) = "="; ;} + break; + + case 1733: + +/* Line 1455 of yacc.c */ +#line 11586 "gram.y" + { (yyval.list) = list_make1(makeString((yyvsp[(1) - (1)].str))); ;} + break; + + case 1734: + +/* Line 1455 of yacc.c */ +#line 11588 "gram.y" + { (yyval.list) = (yyvsp[(3) - (4)].list); ;} + break; + + case 1735: + +/* Line 1455 of yacc.c */ +#line 11593 "gram.y" + { (yyval.list) = list_make1(makeString((yyvsp[(1) - (1)].str))); ;} + break; + + case 1736: + +/* Line 1455 of yacc.c */ +#line 11595 "gram.y" + { (yyval.list) = (yyvsp[(3) - (4)].list); ;} + break; + + case 1737: + +/* Line 1455 of yacc.c */ +#line 11600 "gram.y" + { (yyval.list) = list_make1(makeString((yyvsp[(1) - (1)].str))); ;} + break; + + case 1738: + +/* Line 1455 of yacc.c */ +#line 11602 "gram.y" + { (yyval.list) = (yyvsp[(3) - (4)].list); ;} + break; + + case 1739: + +/* Line 1455 of yacc.c */ +#line 11604 "gram.y" + { (yyval.list) = list_make1(makeString("~~")); ;} + break; + + case 1740: + +/* Line 1455 of yacc.c */ +#line 11606 "gram.y" + { (yyval.list) = list_make1(makeString("!~~")); ;} + break; + + case 1741: + +/* Line 1455 of yacc.c */ +#line 11608 "gram.y" + { (yyval.list) = list_make1(makeString("~~*")); ;} + break; + + case 1742: + +/* Line 1455 of yacc.c */ +#line 11610 "gram.y" + { (yyval.list) = list_make1(makeString("!~~*")); ;} + break; + + case 1743: + +/* Line 1455 of yacc.c */ +#line 11622 "gram.y" + { + (yyval.list) = list_make1((yyvsp[(1) - (1)].node)); + ;} + break; + + case 1744: + +/* Line 1455 of yacc.c */ +#line 11626 "gram.y" + { + (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].node)); + ;} + break; + + case 1745: + +/* Line 1455 of yacc.c */ +#line 11633 "gram.y" + { + (yyval.list) = list_make1((yyvsp[(1) - (1)].node)); + ;} + break; + + case 1746: + +/* Line 1455 of yacc.c */ +#line 11637 "gram.y" + { + (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].node)); + ;} + break; + + case 1747: + +/* Line 1455 of yacc.c */ +#line 11643 "gram.y" + { + (yyval.node) = (yyvsp[(1) - (1)].node); + ;} + break; + + case 1748: + +/* Line 1455 of yacc.c */ +#line 11647 "gram.y" + { + NamedArgExpr *na = makeNode(NamedArgExpr); + na->name = (yyvsp[(1) - (3)].str); + na->arg = (Expr *) (yyvsp[(3) - (3)].node); + na->argnumber = -1; /* until determined */ + na->location = (yylsp[(1) - (3)]); + (yyval.node) = (Node *) na; + ;} + break; + + case 1749: + +/* Line 1455 of yacc.c */ +#line 11657 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].typnam)); ;} + break; + + case 1750: + +/* Line 1455 of yacc.c */ +#line 11658 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].typnam)); ;} + break; + + case 1751: + +/* Line 1455 of yacc.c */ +#line 11662 "gram.y" + { + (yyval.node) = makeAArrayExpr((yyvsp[(2) - (3)].list), (yylsp[(1) - (3)])); + ;} + break; + + case 1752: + +/* Line 1455 of yacc.c */ +#line 11666 "gram.y" + { + (yyval.node) = makeAArrayExpr((yyvsp[(2) - (3)].list), (yylsp[(1) - (3)])); + ;} + break; + + case 1753: + +/* Line 1455 of yacc.c */ +#line 11670 "gram.y" + { + (yyval.node) = makeAArrayExpr(NIL, (yylsp[(1) - (2)])); + ;} + break; + + case 1754: + +/* Line 1455 of yacc.c */ +#line 11675 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].node)); ;} + break; + + case 1755: + +/* Line 1455 of yacc.c */ +#line 11676 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].node)); ;} + break; + + case 1756: + +/* Line 1455 of yacc.c */ +#line 11682 "gram.y" + { + (yyval.list) = list_make2(makeStringConst((yyvsp[(1) - (3)].str), (yylsp[(1) - (3)])), (yyvsp[(3) - (3)].node)); + ;} + break; + + case 1757: + +/* Line 1455 of yacc.c */ +#line 11685 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1758: + +/* Line 1455 of yacc.c */ +#line 11692 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 1759: + +/* Line 1455 of yacc.c */ +#line 11693 "gram.y" + { (yyval.str) = "year"; ;} + break; + + case 1760: + +/* Line 1455 of yacc.c */ +#line 11694 "gram.y" + { (yyval.str) = "month"; ;} + break; + + case 1761: + +/* Line 1455 of yacc.c */ +#line 11695 "gram.y" + { (yyval.str) = "day"; ;} + break; + + case 1762: + +/* Line 1455 of yacc.c */ +#line 11696 "gram.y" + { (yyval.str) = "hour"; ;} + break; + + case 1763: + +/* Line 1455 of yacc.c */ +#line 11697 "gram.y" + { (yyval.str) = "minute"; ;} + break; + + case 1764: + +/* Line 1455 of yacc.c */ +#line 11698 "gram.y" + { (yyval.str) = "second"; ;} + break; + + case 1765: + +/* Line 1455 of yacc.c */ +#line 11699 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 1766: + +/* Line 1455 of yacc.c */ +#line 11710 "gram.y" + { + (yyval.list) = list_make4((yyvsp[(1) - (4)].node), (yyvsp[(2) - (4)].node), (yyvsp[(3) - (4)].node), (yyvsp[(4) - (4)].node)); + ;} + break; + + case 1767: + +/* Line 1455 of yacc.c */ +#line 11714 "gram.y" + { + (yyval.list) = list_make3((yyvsp[(1) - (3)].node), (yyvsp[(2) - (3)].node), (yyvsp[(3) - (3)].node)); + ;} + break; + + case 1768: + +/* Line 1455 of yacc.c */ +#line 11721 "gram.y" + { (yyval.node) = (yyvsp[(2) - (2)].node); ;} + break; + + case 1769: + +/* Line 1455 of yacc.c */ +#line 11727 "gram.y" + { (yyval.list) = list_make2((yyvsp[(3) - (3)].node), (yyvsp[(1) - (3)].node)); ;} + break; + + case 1770: + +/* Line 1455 of yacc.c */ +#line 11728 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1771: + +/* Line 1455 of yacc.c */ +#line 11745 "gram.y" + { + (yyval.list) = list_make3((yyvsp[(1) - (3)].node), (yyvsp[(2) - (3)].node), (yyvsp[(3) - (3)].node)); + ;} + break; + + case 1772: + +/* Line 1455 of yacc.c */ +#line 11749 "gram.y" + { + /* not legal per SQL99, but might as well allow it */ + (yyval.list) = list_make3((yyvsp[(1) - (3)].node), (yyvsp[(3) - (3)].node), (yyvsp[(2) - (3)].node)); + ;} + break; + + case 1773: + +/* Line 1455 of yacc.c */ +#line 11754 "gram.y" + { + (yyval.list) = list_make2((yyvsp[(1) - (2)].node), (yyvsp[(2) - (2)].node)); + ;} + break; + + case 1774: + +/* Line 1455 of yacc.c */ +#line 11758 "gram.y" + { + /* + * Since there are no cases where this syntax allows + * a textual FOR value, we forcibly cast the argument + * to int4. The possible matches in pg_proc are + * substring(text,int4) and substring(text,text), + * and we don't want the parser to choose the latter, + * which it is likely to do if the second argument + * is unknown or doesn't have an implicit cast to int4. + */ + (yyval.list) = list_make3((yyvsp[(1) - (2)].node), makeIntConst(1, -1), + makeTypeCast((yyvsp[(2) - (2)].node), + SystemTypeName("int4"), -1)); + ;} + break; + + case 1775: + +/* Line 1455 of yacc.c */ +#line 11773 "gram.y" + { + (yyval.list) = (yyvsp[(1) - (1)].list); + ;} + break; + + case 1776: + +/* Line 1455 of yacc.c */ +#line 11777 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1777: + +/* Line 1455 of yacc.c */ +#line 11781 "gram.y" + { (yyval.node) = (yyvsp[(2) - (2)].node); ;} + break; + + case 1778: + +/* Line 1455 of yacc.c */ +#line 11784 "gram.y" + { (yyval.node) = (yyvsp[(2) - (2)].node); ;} + break; + + case 1779: + +/* Line 1455 of yacc.c */ +#line 11787 "gram.y" + { (yyval.list) = lappend((yyvsp[(3) - (3)].list), (yyvsp[(1) - (3)].node)); ;} + break; + + case 1780: + +/* Line 1455 of yacc.c */ +#line 11788 "gram.y" + { (yyval.list) = (yyvsp[(2) - (2)].list); ;} + break; + + case 1781: + +/* Line 1455 of yacc.c */ +#line 11789 "gram.y" + { (yyval.list) = (yyvsp[(1) - (1)].list); ;} + break; + + case 1782: + +/* Line 1455 of yacc.c */ +#line 11793 "gram.y" + { + SubLink *n = makeNode(SubLink); + n->subselect = (yyvsp[(1) - (1)].node); + /* other fields will be filled later */ + (yyval.node) = (Node *)n; + ;} + break; + + case 1783: + +/* Line 1455 of yacc.c */ +#line 11799 "gram.y" + { (yyval.node) = (Node *)(yyvsp[(2) - (3)].list); ;} + break; + + case 1784: + +/* Line 1455 of yacc.c */ +#line 11810 "gram.y" + { + CaseExpr *c = makeNode(CaseExpr); + c->casetype = InvalidOid; /* not analyzed yet */ + c->arg = (Expr *) (yyvsp[(2) - (5)].node); + c->args = (yyvsp[(3) - (5)].list); + c->defresult = (Expr *) (yyvsp[(4) - (5)].node); + c->location = (yylsp[(1) - (5)]); + (yyval.node) = (Node *)c; + ;} + break; + + case 1785: + +/* Line 1455 of yacc.c */ +#line 11823 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].node)); ;} + break; + + case 1786: + +/* Line 1455 of yacc.c */ +#line 11824 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (2)].list), (yyvsp[(2) - (2)].node)); ;} + break; + + case 1787: + +/* Line 1455 of yacc.c */ +#line 11829 "gram.y" + { + CaseWhen *w = makeNode(CaseWhen); + w->expr = (Expr *) (yyvsp[(2) - (4)].node); + w->result = (Expr *) (yyvsp[(4) - (4)].node); + w->location = (yylsp[(1) - (4)]); + (yyval.node) = (Node *)w; + ;} + break; + + case 1788: + +/* Line 1455 of yacc.c */ +#line 11839 "gram.y" + { (yyval.node) = (yyvsp[(2) - (2)].node); ;} + break; + + case 1789: + +/* Line 1455 of yacc.c */ +#line 11840 "gram.y" + { (yyval.node) = NULL; ;} + break; + + case 1790: + +/* Line 1455 of yacc.c */ +#line 11843 "gram.y" + { (yyval.node) = (yyvsp[(1) - (1)].node); ;} + break; + + case 1791: + +/* Line 1455 of yacc.c */ +#line 11844 "gram.y" + { (yyval.node) = NULL; ;} + break; + + case 1792: + +/* Line 1455 of yacc.c */ +#line 11848 "gram.y" + { + (yyval.node) = makeColumnRef((yyvsp[(1) - (1)].str), NIL, (yylsp[(1) - (1)]), yyscanner); + ;} + break; + + case 1793: + +/* Line 1455 of yacc.c */ +#line 11852 "gram.y" + { + (yyval.node) = makeColumnRef((yyvsp[(1) - (2)].str), (yyvsp[(2) - (2)].list), (yylsp[(1) - (2)]), yyscanner); + ;} + break; + + case 1794: + +/* Line 1455 of yacc.c */ +#line 11859 "gram.y" + { + (yyval.node) = (Node *) makeString((yyvsp[(2) - (2)].str)); + ;} + break; + + case 1795: + +/* Line 1455 of yacc.c */ +#line 11863 "gram.y" + { + (yyval.node) = (Node *) makeNode(A_Star); + ;} + break; + + case 1796: + +/* Line 1455 of yacc.c */ +#line 11867 "gram.y" + { + A_Indices *ai = makeNode(A_Indices); + ai->lidx = NULL; + ai->uidx = (yyvsp[(2) - (3)].node); + (yyval.node) = (Node *) ai; + ;} + break; + + case 1797: + +/* Line 1455 of yacc.c */ +#line 11874 "gram.y" + { + A_Indices *ai = makeNode(A_Indices); + ai->lidx = (yyvsp[(2) - (5)].node); + ai->uidx = (yyvsp[(4) - (5)].node); + (yyval.node) = (Node *) ai; + ;} + break; + + case 1798: + +/* Line 1455 of yacc.c */ +#line 11883 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].node)); ;} + break; + + case 1799: + +/* Line 1455 of yacc.c */ +#line 11884 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (2)].list), (yyvsp[(2) - (2)].node)); ;} + break; + + case 1800: + +/* Line 1455 of yacc.c */ +#line 11888 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 1801: + +/* Line 1455 of yacc.c */ +#line 11889 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (2)].list), (yyvsp[(2) - (2)].node)); ;} + break; + + case 1804: + +/* Line 1455 of yacc.c */ +#line 11904 "gram.y" + { (yyval.node) = (Node *) (yyvsp[(1) - (1)].node); ;} + break; + + case 1805: + +/* Line 1455 of yacc.c */ +#line 11906 "gram.y" + { + SetToDefault *n = makeNode(SetToDefault); + n->location = (yylsp[(1) - (1)]); + (yyval.node) = (Node *) n; + ;} + break; + + case 1806: + +/* Line 1455 of yacc.c */ +#line 11914 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].node)); ;} + break; + + case 1807: + +/* Line 1455 of yacc.c */ +#line 11915 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].node)); ;} + break; + + case 1808: + +/* Line 1455 of yacc.c */ +#line 11923 "gram.y" + { (yyval.list) = (yyvsp[(2) - (3)].list); ;} + break; + + case 1809: + +/* Line 1455 of yacc.c */ +#line 11934 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].target)); ;} + break; + + case 1810: + +/* Line 1455 of yacc.c */ +#line 11935 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].target)); ;} + break; + + case 1811: + +/* Line 1455 of yacc.c */ +#line 11939 "gram.y" + { + (yyval.target) = makeNode(ResTarget); + (yyval.target)->name = (yyvsp[(3) - (3)].str); + (yyval.target)->indirection = NIL; + (yyval.target)->val = (Node *)(yyvsp[(1) - (3)].node); + (yyval.target)->location = (yylsp[(1) - (3)]); + ;} + break; + + case 1812: + +/* Line 1455 of yacc.c */ +#line 11955 "gram.y" + { + (yyval.target) = makeNode(ResTarget); + (yyval.target)->name = (yyvsp[(2) - (2)].str); + (yyval.target)->indirection = NIL; + (yyval.target)->val = (Node *)(yyvsp[(1) - (2)].node); + (yyval.target)->location = (yylsp[(1) - (2)]); + ;} + break; + + case 1813: + +/* Line 1455 of yacc.c */ +#line 11963 "gram.y" + { + (yyval.target) = makeNode(ResTarget); + (yyval.target)->name = NULL; + (yyval.target)->indirection = NIL; + (yyval.target)->val = (Node *)(yyvsp[(1) - (1)].node); + (yyval.target)->location = (yylsp[(1) - (1)]); + ;} + break; + + case 1814: + +/* Line 1455 of yacc.c */ +#line 11971 "gram.y" + { + ColumnRef *n = makeNode(ColumnRef); + n->fields = list_make1(makeNode(A_Star)); + n->location = (yylsp[(1) - (1)]); + + (yyval.target) = makeNode(ResTarget); + (yyval.target)->name = NULL; + (yyval.target)->indirection = NIL; + (yyval.target)->val = (Node *)n; + (yyval.target)->location = (yylsp[(1) - (1)]); + ;} + break; + + case 1815: + +/* Line 1455 of yacc.c */ +#line 11992 "gram.y" + { (yyval.list) = list_make1((yyvsp[(1) - (1)].range)); ;} + break; + + case 1816: + +/* Line 1455 of yacc.c */ +#line 11993 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].range)); ;} + break; + + case 1817: + +/* Line 1455 of yacc.c */ +#line 12005 "gram.y" + { + (yyval.range) = makeRangeVar(NULL, (yyvsp[(1) - (1)].str), (yylsp[(1) - (1)])); + ;} + break; + + case 1818: + +/* Line 1455 of yacc.c */ +#line 12009 "gram.y" + { + check_qualified_name((yyvsp[(2) - (2)].list), yyscanner); + (yyval.range) = makeRangeVar(NULL, NULL, (yylsp[(1) - (2)])); + switch (list_length((yyvsp[(2) - (2)].list))) + { + case 1: + (yyval.range)->catalogname = NULL; + (yyval.range)->schemaname = (yyvsp[(1) - (2)].str); + (yyval.range)->relname = strVal(linitial((yyvsp[(2) - (2)].list))); + break; + case 2: + (yyval.range)->catalogname = (yyvsp[(1) - (2)].str); + (yyval.range)->schemaname = strVal(linitial((yyvsp[(2) - (2)].list))); + (yyval.range)->relname = strVal(lsecond((yyvsp[(2) - (2)].list))); + break; + default: + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("improper qualified name (too many dotted names): %s", + NameListToString(lcons(makeString((yyvsp[(1) - (2)].str)), (yyvsp[(2) - (2)].list)))), + parser_errposition((yylsp[(1) - (2)])))); + break; + } + ;} + break; + + case 1819: + +/* Line 1455 of yacc.c */ +#line 12036 "gram.y" + { (yyval.list) = list_make1(makeString((yyvsp[(1) - (1)].str))); ;} + break; + + case 1820: + +/* Line 1455 of yacc.c */ +#line 12038 "gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (3)].list), makeString((yyvsp[(3) - (3)].str))); ;} + break; + + case 1821: + +/* Line 1455 of yacc.c */ +#line 12042 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 1822: + +/* Line 1455 of yacc.c */ +#line 12045 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 1823: + +/* Line 1455 of yacc.c */ +#line 12048 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 1824: + +/* Line 1455 of yacc.c */ +#line 12050 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 1825: + +/* Line 1455 of yacc.c */ +#line 12052 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 1826: + +/* Line 1455 of yacc.c */ +#line 12054 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 1827: + +/* Line 1455 of yacc.c */ +#line 12065 "gram.y" + { (yyval.list) = list_make1(makeString((yyvsp[(1) - (1)].str))); ;} + break; + + case 1828: + +/* Line 1455 of yacc.c */ +#line 12067 "gram.y" + { + (yyval.list) = check_func_name(lcons(makeString((yyvsp[(1) - (2)].str)), (yyvsp[(2) - (2)].list)), + yyscanner); + ;} + break; + + case 1829: + +/* Line 1455 of yacc.c */ +#line 12078 "gram.y" + { + (yyval.node) = makeIntConst((yyvsp[(1) - (1)].ival), (yylsp[(1) - (1)])); + ;} + break; + + case 1830: + +/* Line 1455 of yacc.c */ +#line 12082 "gram.y" + { + (yyval.node) = makeFloatConst((yyvsp[(1) - (1)].str), (yylsp[(1) - (1)])); + ;} + break; + + case 1831: + +/* Line 1455 of yacc.c */ +#line 12086 "gram.y" + { + (yyval.node) = makeStringConst((yyvsp[(1) - (1)].str), (yylsp[(1) - (1)])); + ;} + break; + + case 1832: + +/* Line 1455 of yacc.c */ +#line 12090 "gram.y" + { + (yyval.node) = makeBitStringConst((yyvsp[(1) - (1)].str), (yylsp[(1) - (1)])); + ;} + break; + + case 1833: + +/* Line 1455 of yacc.c */ +#line 12094 "gram.y" + { + /* This is a bit constant per SQL99: + * Without Feature F511, "BIT data type", + * a shall not be a + * or a . + */ + (yyval.node) = makeBitStringConst((yyvsp[(1) - (1)].str), (yylsp[(1) - (1)])); + ;} + break; + + case 1834: + +/* Line 1455 of yacc.c */ +#line 12103 "gram.y" + { + /* generic type 'literal' syntax */ + TypeName *t = makeTypeNameFromNameList((yyvsp[(1) - (2)].list)); + t->location = (yylsp[(1) - (2)]); + (yyval.node) = makeStringConstCast((yyvsp[(2) - (2)].str), (yylsp[(2) - (2)]), t); + ;} + break; + + case 1835: + +/* Line 1455 of yacc.c */ +#line 12110 "gram.y" + { + /* generic syntax with a type modifier */ + TypeName *t = makeTypeNameFromNameList((yyvsp[(1) - (5)].list)); + ListCell *lc; + + /* + * We must use func_arg_list in the production to avoid + * reduce/reduce conflicts, but we don't actually wish + * to allow NamedArgExpr in this context. + */ + foreach(lc, (yyvsp[(3) - (5)].list)) + { + NamedArgExpr *arg = (NamedArgExpr *) lfirst(lc); + + if (IsA(arg, NamedArgExpr)) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("type modifier cannot have parameter name"), + parser_errposition(arg->location))); + } + t->typmods = (yyvsp[(3) - (5)].list); + t->location = (yylsp[(1) - (5)]); + (yyval.node) = makeStringConstCast((yyvsp[(5) - (5)].str), (yylsp[(5) - (5)]), t); + ;} + break; + + case 1836: + +/* Line 1455 of yacc.c */ +#line 12135 "gram.y" + { + (yyval.node) = makeStringConstCast((yyvsp[(2) - (2)].str), (yylsp[(2) - (2)]), (yyvsp[(1) - (2)].typnam)); + ;} + break; + + case 1837: + +/* Line 1455 of yacc.c */ +#line 12139 "gram.y" + { + TypeName *t = (yyvsp[(1) - (3)].typnam); + t->typmods = (yyvsp[(3) - (3)].list); + (yyval.node) = makeStringConstCast((yyvsp[(2) - (3)].str), (yylsp[(2) - (3)]), t); + ;} + break; + + case 1838: + +/* Line 1455 of yacc.c */ +#line 12145 "gram.y" + { + TypeName *t = (yyvsp[(1) - (6)].typnam); + if ((yyvsp[(6) - (6)].list) != NIL) + { + if (list_length((yyvsp[(6) - (6)].list)) != 1) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("interval precision specified twice"), + parser_errposition((yylsp[(1) - (6)])))); + t->typmods = lappend((yyvsp[(6) - (6)].list), makeIntConst((yyvsp[(3) - (6)].ival), (yylsp[(3) - (6)]))); + } + else + t->typmods = list_make2(makeIntConst(INTERVAL_FULL_RANGE, -1), + makeIntConst((yyvsp[(3) - (6)].ival), (yylsp[(3) - (6)]))); + (yyval.node) = makeStringConstCast((yyvsp[(5) - (6)].str), (yylsp[(5) - (6)]), t); + ;} + break; + + case 1839: + +/* Line 1455 of yacc.c */ +#line 12162 "gram.y" + { + (yyval.node) = makeBoolAConst(TRUE, (yylsp[(1) - (1)])); + ;} + break; + + case 1840: + +/* Line 1455 of yacc.c */ +#line 12166 "gram.y" + { + (yyval.node) = makeBoolAConst(FALSE, (yylsp[(1) - (1)])); + ;} + break; + + case 1841: + +/* Line 1455 of yacc.c */ +#line 12170 "gram.y" + { + (yyval.node) = makeNullAConst((yylsp[(1) - (1)])); + ;} + break; + + case 1842: + +/* Line 1455 of yacc.c */ +#line 12175 "gram.y" + { (yyval.ival) = (yyvsp[(1) - (1)].ival); ;} + break; + + case 1843: + +/* Line 1455 of yacc.c */ +#line 12176 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 1844: + +/* Line 1455 of yacc.c */ +#line 12177 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 1845: + +/* Line 1455 of yacc.c */ +#line 12179 "gram.y" + { (yyval.ival) = (yyvsp[(1) - (1)].ival); ;} + break; + + case 1846: + +/* Line 1455 of yacc.c */ +#line 12180 "gram.y" + { (yyval.ival) = + (yyvsp[(2) - (2)].ival); ;} + break; + + case 1847: + +/* Line 1455 of yacc.c */ +#line 12181 "gram.y" + { (yyval.ival) = - (yyvsp[(2) - (2)].ival); ;} + break; + + case 1848: + +/* Line 1455 of yacc.c */ +#line 12197 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 1849: + +/* Line 1455 of yacc.c */ +#line 12198 "gram.y" + { (yyval.str) = pstrdup((yyvsp[(1) - (1)].keyword)); ;} + break; + + case 1850: + +/* Line 1455 of yacc.c */ +#line 12199 "gram.y" + { (yyval.str) = pstrdup((yyvsp[(1) - (1)].keyword)); ;} + break; + + case 1851: + +/* Line 1455 of yacc.c */ +#line 12204 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 1852: + +/* Line 1455 of yacc.c */ +#line 12205 "gram.y" + { (yyval.str) = pstrdup((yyvsp[(1) - (1)].keyword)); ;} + break; + + case 1853: + +/* Line 1455 of yacc.c */ +#line 12206 "gram.y" + { (yyval.str) = pstrdup((yyvsp[(1) - (1)].keyword)); ;} + break; + + case 1854: + +/* Line 1455 of yacc.c */ +#line 12212 "gram.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 1855: + +/* Line 1455 of yacc.c */ +#line 12213 "gram.y" + { (yyval.str) = pstrdup((yyvsp[(1) - (1)].keyword)); ;} + break; + + case 1856: + +/* Line 1455 of yacc.c */ +#line 12214 "gram.y" + { (yyval.str) = pstrdup((yyvsp[(1) - (1)].keyword)); ;} + break; + + case 1857: + +/* Line 1455 of yacc.c */ +#line 12215 "gram.y" + { (yyval.str) = pstrdup((yyvsp[(1) - (1)].keyword)); ;} + break; + + case 1858: + +/* Line 1455 of yacc.c */ +#line 12216 "gram.y" + { (yyval.str) = pstrdup((yyvsp[(1) - (1)].keyword)); ;} + break; + + + +/* Line 1455 of yacc.c */ +#line 37682 "gram.c" + default: break; + } + YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); + + YYPOPSTACK (yylen); + yylen = 0; + YY_STACK_PRINT (yyss, yyssp); + + *++yyvsp = yyval; + *++yylsp = yyloc; + + /* Now `shift' the result of the reduction. Determine what state + that goes to, based on the state we popped back to and the rule + number reduced by. */ + + yyn = yyr1[yyn]; + + yystate = yypgoto[yyn - YYNTOKENS] + *yyssp; + if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp) + yystate = yytable[yystate]; + else + yystate = yydefgoto[yyn - YYNTOKENS]; + + goto yynewstate; + + +/*------------------------------------. +| yyerrlab -- here on detecting error | +`------------------------------------*/ +yyerrlab: + /* If not already recovering from an error, report this error. */ + if (!yyerrstatus) + { + ++yynerrs; +#if ! YYERROR_VERBOSE + yyerror (&yylloc, yyscanner, YY_("syntax error")); +#else + { + YYSIZE_T yysize = yysyntax_error (0, yystate, yychar); + if (yymsg_alloc < yysize && yymsg_alloc < YYSTACK_ALLOC_MAXIMUM) + { + YYSIZE_T yyalloc = 2 * yysize; + if (! (yysize <= yyalloc && yyalloc <= YYSTACK_ALLOC_MAXIMUM)) + yyalloc = YYSTACK_ALLOC_MAXIMUM; + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); + yymsg = (char *) YYSTACK_ALLOC (yyalloc); + if (yymsg) + yymsg_alloc = yyalloc; + else + { + yymsg = yymsgbuf; + yymsg_alloc = sizeof yymsgbuf; + } + } + + if (0 < yysize && yysize <= yymsg_alloc) + { + (void) yysyntax_error (yymsg, yystate, yychar); + yyerror (&yylloc, yyscanner, yymsg); + } + else + { + yyerror (&yylloc, yyscanner, YY_("syntax error")); + if (yysize != 0) + goto yyexhaustedlab; + } + } +#endif + } + + yyerror_range[0] = yylloc; + + if (yyerrstatus == 3) + { + /* If just tried and failed to reuse lookahead token after an + error, discard it. */ + + if (yychar <= YYEOF) + { + /* Return failure if at end of input. */ + if (yychar == YYEOF) + YYABORT; + } + else + { + yydestruct ("Error: discarding", + yytoken, &yylval, &yylloc, yyscanner); + yychar = YYEMPTY; + } + } + + /* Else will try to reuse lookahead token after shifting the error + token. */ + goto yyerrlab1; + + +/*---------------------------------------------------. +| yyerrorlab -- error raised explicitly by YYERROR. | +`---------------------------------------------------*/ +yyerrorlab: + + /* Pacify compilers like GCC when the user code never invokes + YYERROR and the label yyerrorlab therefore never appears in user + code. */ + if (/*CONSTCOND*/ 0) + goto yyerrorlab; + + yyerror_range[0] = yylsp[1-yylen]; + /* Do not reclaim the symbols of the rule which action triggered + this YYERROR. */ + YYPOPSTACK (yylen); + yylen = 0; + YY_STACK_PRINT (yyss, yyssp); + yystate = *yyssp; + goto yyerrlab1; + + +/*-------------------------------------------------------------. +| yyerrlab1 -- common code for both syntax error and YYERROR. | +`-------------------------------------------------------------*/ +yyerrlab1: + yyerrstatus = 3; /* Each real token shifted decrements this. */ + + for (;;) + { + yyn = yypact[yystate]; + if (yyn != YYPACT_NINF) + { + yyn += YYTERROR; + if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR) + { + yyn = yytable[yyn]; + if (0 < yyn) + break; + } + } + + /* Pop the current state because it cannot handle the error token. */ + if (yyssp == yyss) + YYABORT; + + yyerror_range[0] = *yylsp; + yydestruct ("Error: popping", + yystos[yystate], yyvsp, yylsp, yyscanner); + YYPOPSTACK (1); + yystate = *yyssp; + YY_STACK_PRINT (yyss, yyssp); + } + + *++yyvsp = yylval; + + yyerror_range[1] = yylloc; + /* Using YYLLOC is tempting, but would change the location of + the lookahead. YYLOC is available though. */ + YYLLOC_DEFAULT (yyloc, (yyerror_range - 1), 2); + *++yylsp = yyloc; + + /* Shift the error token. */ + YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp); + + yystate = yyn; + goto yynewstate; + + +/*-------------------------------------. +| yyacceptlab -- YYACCEPT comes here. | +`-------------------------------------*/ +yyacceptlab: + yyresult = 0; + goto yyreturn; + +/*-----------------------------------. +| yyabortlab -- YYABORT comes here. | +`-----------------------------------*/ +yyabortlab: + yyresult = 1; + goto yyreturn; + +#if !defined(yyoverflow) || YYERROR_VERBOSE +/*-------------------------------------------------. +| yyexhaustedlab -- memory exhaustion comes here. | +`-------------------------------------------------*/ +yyexhaustedlab: + yyerror (&yylloc, yyscanner, YY_("memory exhausted")); + yyresult = 2; + /* Fall through. */ +#endif + +yyreturn: + if (yychar != YYEMPTY) + yydestruct ("Cleanup: discarding lookahead", + yytoken, &yylval, &yylloc, yyscanner); + /* Do not reclaim the symbols of the rule which action triggered + this YYABORT or YYACCEPT. */ + YYPOPSTACK (yylen); + YY_STACK_PRINT (yyss, yyssp); + while (yyssp != yyss) + { + yydestruct ("Cleanup: popping", + yystos[*yyssp], yyvsp, yylsp, yyscanner); + YYPOPSTACK (1); + } +#ifndef yyoverflow + if (yyss != yyssa) + YYSTACK_FREE (yyss); +#endif +#if YYERROR_VERBOSE + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); +#endif + /* Make sure YYID is used. */ + return YYID (yyresult); +} + + + +/* Line 1675 of yacc.c */ +#line 12669 "gram.y" + + +/* + * The signature of this function is required by bison. However, we + * ignore the passed yylloc and instead use the last token position + * available from the scanner. + */ +static void +base_yyerror(YYLTYPE *yylloc, core_yyscan_t yyscanner, const char *msg) +{ + parser_yyerror(msg); +} + +static Node * +makeColumnRef(char *colname, List *indirection, + int location, core_yyscan_t yyscanner) +{ + /* + * Generate a ColumnRef node, with an A_Indirection node added if there + * is any subscripting in the specified indirection list. However, + * any field selection at the start of the indirection list must be + * transposed into the "fields" part of the ColumnRef node. + */ + ColumnRef *c = makeNode(ColumnRef); + int nfields = 0; + ListCell *l; + + c->location = location; + foreach(l, indirection) + { + if (IsA(lfirst(l), A_Indices)) + { + A_Indirection *i = makeNode(A_Indirection); + + if (nfields == 0) + { + /* easy case - all indirection goes to A_Indirection */ + c->fields = list_make1(makeString(colname)); + i->indirection = check_indirection(indirection, yyscanner); + } + else + { + /* got to split the list in two */ + i->indirection = check_indirection(list_copy_tail(indirection, + nfields), + yyscanner); + indirection = list_truncate(indirection, nfields); + c->fields = lcons(makeString(colname), indirection); + } + i->arg = (Node *) c; + return (Node *) i; + } + else if (IsA(lfirst(l), A_Star)) + { + /* We only allow '*' at the end of a ColumnRef */ + if (lnext(l) != NULL) + parser_yyerror("improper use of \"*\""); + } + nfields++; + } + /* No subscripting, so all indirection gets added to field list */ + c->fields = lcons(makeString(colname), indirection); + return (Node *) c; +} + +static Node * +makeTypeCast(Node *arg, TypeName *typename, int location) +{ + TypeCast *n = makeNode(TypeCast); + n->arg = arg; + n->typeName = typename; + n->location = location; + return (Node *) n; +} + +static Node * +makeStringConst(char *str, int location) +{ + A_Const *n = makeNode(A_Const); + + n->val.type = T_String; + n->val.val.str = str; + n->location = location; + + return (Node *)n; +} + +static Node * +makeStringConstCast(char *str, int location, TypeName *typename) +{ + Node *s = makeStringConst(str, location); + + return makeTypeCast(s, typename, -1); +} + +static Node * +makeIntConst(int val, int location) +{ + A_Const *n = makeNode(A_Const); + + n->val.type = T_Integer; + n->val.val.ival = val; + n->location = location; + + return (Node *)n; +} + +static Node * +makeFloatConst(char *str, int location) +{ + A_Const *n = makeNode(A_Const); + + n->val.type = T_Float; + n->val.val.str = str; + n->location = location; + + return (Node *)n; +} + +static Node * +makeBitStringConst(char *str, int location) +{ + A_Const *n = makeNode(A_Const); + + n->val.type = T_BitString; + n->val.val.str = str; + n->location = location; + + return (Node *)n; +} + +static Node * +makeNullAConst(int location) +{ + A_Const *n = makeNode(A_Const); + + n->val.type = T_Null; + n->location = location; + + return (Node *)n; +} + +static Node * +makeAConst(Value *v, int location) +{ + Node *n; + + switch (v->type) + { + case T_Float: + n = makeFloatConst(v->val.str, location); + break; + + case T_Integer: + n = makeIntConst(v->val.ival, location); + break; + + case T_String: + default: + n = makeStringConst(v->val.str, location); + break; + } + + return n; +} + +/* makeBoolAConst() + * Create an A_Const string node and put it inside a boolean cast. + */ +static Node * +makeBoolAConst(bool state, int location) +{ + A_Const *n = makeNode(A_Const); + + n->val.type = T_String; + n->val.val.str = (state ? "t" : "f"); + n->location = location; + + return makeTypeCast((Node *)n, SystemTypeName("bool"), -1); +} + +/* makeOverlaps() + * Create and populate a FuncCall node to support the OVERLAPS operator. + */ +static FuncCall * +makeOverlaps(List *largs, List *rargs, int location, core_yyscan_t yyscanner) +{ + FuncCall *n = makeNode(FuncCall); + + n->funcname = SystemFuncName("overlaps"); + if (list_length(largs) == 1) + largs = lappend(largs, largs); + else if (list_length(largs) != 2) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("wrong number of parameters on left side of OVERLAPS expression"), + parser_errposition(location))); + if (list_length(rargs) == 1) + rargs = lappend(rargs, rargs); + else if (list_length(rargs) != 2) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("wrong number of parameters on right side of OVERLAPS expression"), + parser_errposition(location))); + n->args = list_concat(largs, rargs); + n->agg_order = NIL; + n->agg_star = FALSE; + n->agg_distinct = FALSE; + n->func_variadic = FALSE; + n->over = NULL; + n->location = location; + return n; +} + +/* check_qualified_name --- check the result of qualified_name production + * + * It's easiest to let the grammar production for qualified_name allow + * subscripts and '*', which we then must reject here. + */ +static void +check_qualified_name(List *names, core_yyscan_t yyscanner) +{ + ListCell *i; + + foreach(i, names) + { + if (!IsA(lfirst(i), String)) + parser_yyerror("syntax error"); + } +} + +/* check_func_name --- check the result of func_name production + * + * It's easiest to let the grammar production for func_name allow subscripts + * and '*', which we then must reject here. + */ +static List * +check_func_name(List *names, core_yyscan_t yyscanner) +{ + ListCell *i; + + foreach(i, names) + { + if (!IsA(lfirst(i), String)) + parser_yyerror("syntax error"); + } + return names; +} + +/* check_indirection --- check the result of indirection production + * + * We only allow '*' at the end of the list, but it's hard to enforce that + * in the grammar, so do it here. + */ +static List * +check_indirection(List *indirection, core_yyscan_t yyscanner) +{ + ListCell *l; + + foreach(l, indirection) + { + if (IsA(lfirst(l), A_Star)) + { + if (lnext(l) != NULL) + parser_yyerror("improper use of \"*\""); + } + } + return indirection; +} + +/* extractArgTypes() + * Given a list of FunctionParameter nodes, extract a list of just the + * argument types (TypeNames) for input parameters only. This is what + * is needed to look up an existing function, which is what is wanted by + * the productions that use this call. + */ +static List * +extractArgTypes(List *parameters) +{ + List *result = NIL; + ListCell *i; + + foreach(i, parameters) + { + FunctionParameter *p = (FunctionParameter *) lfirst(i); + + if (p->mode != FUNC_PARAM_OUT && p->mode != FUNC_PARAM_TABLE) + result = lappend(result, p->argType); + } + return result; +} + +/* insertSelectOptions() + * Insert ORDER BY, etc into an already-constructed SelectStmt. + * + * This routine is just to avoid duplicating code in SelectStmt productions. + */ +static void +insertSelectOptions(SelectStmt *stmt, + List *sortClause, List *lockingClause, + Node *limitOffset, Node *limitCount, + WithClause *withClause, + core_yyscan_t yyscanner) +{ + Assert(IsA(stmt, SelectStmt)); + + /* + * Tests here are to reject constructs like + * (SELECT foo ORDER BY bar) ORDER BY baz + */ + if (sortClause) + { + if (stmt->sortClause) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("multiple ORDER BY clauses not allowed"), + parser_errposition(exprLocation((Node *) sortClause)))); + stmt->sortClause = sortClause; + } + /* We can handle multiple locking clauses, though */ + stmt->lockingClause = list_concat(stmt->lockingClause, lockingClause); + if (limitOffset) + { + if (stmt->limitOffset) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("multiple OFFSET clauses not allowed"), + parser_errposition(exprLocation(limitOffset)))); + stmt->limitOffset = limitOffset; + } + if (limitCount) + { + if (stmt->limitCount) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("multiple LIMIT clauses not allowed"), + parser_errposition(exprLocation(limitCount)))); + stmt->limitCount = limitCount; + } + if (withClause) + { + if (stmt->withClause) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("multiple WITH clauses not allowed"), + parser_errposition(exprLocation((Node *) withClause)))); + stmt->withClause = withClause; + } +} + +static Node * +makeSetOp(SetOperation op, bool all, Node *larg, Node *rarg) +{ + SelectStmt *n = makeNode(SelectStmt); + + n->op = op; + n->all = all; + n->larg = (SelectStmt *) larg; + n->rarg = (SelectStmt *) rarg; + return (Node *) n; +} + +/* SystemFuncName() + * Build a properly-qualified reference to a built-in function. + */ +List * +SystemFuncName(char *name) +{ + return list_make2(makeString("pg_catalog"), makeString(name)); +} + +/* SystemTypeName() + * Build a properly-qualified reference to a built-in type. + * + * typmod is defaulted, but may be changed afterwards by caller. + * Likewise for the location. + */ +TypeName * +SystemTypeName(char *name) +{ + return makeTypeNameFromNameList(list_make2(makeString("pg_catalog"), + makeString(name))); +} + +/* doNegate() + * Handle negation of a numeric constant. + * + * Formerly, we did this here because the optimizer couldn't cope with + * indexquals that looked like "var = -4" --- it wants "var = const" + * and a unary minus operator applied to a constant didn't qualify. + * As of Postgres 7.0, that problem doesn't exist anymore because there + * is a constant-subexpression simplifier in the optimizer. However, + * there's still a good reason for doing this here, which is that we can + * postpone committing to a particular internal representation for simple + * negative constants. It's better to leave "-123.456" in string form + * until we know what the desired type is. + */ +static Node * +doNegate(Node *n, int location) +{ + if (IsA(n, A_Const)) + { + A_Const *con = (A_Const *)n; + + /* report the constant's location as that of the '-' sign */ + con->location = location; + + if (con->val.type == T_Integer) + { + con->val.val.ival = -con->val.val.ival; + return n; + } + if (con->val.type == T_Float) + { + doNegateFloat(&con->val); + return n; + } + } + + return (Node *) makeSimpleA_Expr(AEXPR_OP, "-", NULL, n, location); +} + +static void +doNegateFloat(Value *v) +{ + char *oldval = v->val.str; + + Assert(IsA(v, Float)); + if (*oldval == '+') + oldval++; + if (*oldval == '-') + v->val.str = oldval+1; /* just strip the '-' */ + else + { + char *newval = (char *) palloc(strlen(oldval) + 2); + + *newval = '-'; + strcpy(newval+1, oldval); + v->val.str = newval; + } +} + +static Node * +makeAArrayExpr(List *elements, int location) +{ + A_ArrayExpr *n = makeNode(A_ArrayExpr); + + n->elements = elements; + n->location = location; + return (Node *) n; +} + +static Node * +makeXmlExpr(XmlExprOp op, char *name, List *named_args, List *args, + int location) +{ + XmlExpr *x = makeNode(XmlExpr); + + x->op = op; + x->name = name; + /* + * named_args is a list of ResTarget; it'll be split apart into separate + * expression and name lists in transformXmlExpr(). + */ + x->named_args = named_args; + x->arg_names = NIL; + x->args = args; + /* xmloption, if relevant, must be filled in by caller */ + /* type and typmod will be filled in during parse analysis */ + x->location = location; + return (Node *) x; +} + +/* + * Merge the input and output parameters of a table function. + */ +static List * +mergeTableFuncParameters(List *func_args, List *columns) +{ + ListCell *lc; + + /* Explicit OUT and INOUT parameters shouldn't be used in this syntax */ + foreach(lc, func_args) + { + FunctionParameter *p = (FunctionParameter *) lfirst(lc); + + if (p->mode != FUNC_PARAM_IN && p->mode != FUNC_PARAM_VARIADIC) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("OUT and INOUT arguments aren't allowed in TABLE functions"))); + } + + return list_concat(func_args, columns); +} + +/* + * Determine return type of a TABLE function. A single result column + * returns setof that column's type; otherwise return setof record. + */ +static TypeName * +TableFuncTypeName(List *columns) +{ + TypeName *result; + + if (list_length(columns) == 1) + { + FunctionParameter *p = (FunctionParameter *) linitial(columns); + + result = (TypeName *) copyObject(p->argType); + } + else + result = SystemTypeName("record"); + + result->setof = true; + + return result; +} + +/* + * Convert a list of (dotted) names to a RangeVar (like + * makeRangeVarFromNameList, but with position support). The + * "AnyName" refers to the any_name production in the grammar. + */ +static RangeVar * +makeRangeVarFromAnyName(List *names, int position, core_yyscan_t yyscanner) +{ + RangeVar *r = makeNode(RangeVar); + + switch (list_length(names)) + { + case 1: + r->catalogname = NULL; + r->schemaname = NULL; + r->relname = strVal(linitial(names)); + break; + case 2: + r->catalogname = NULL; + r->schemaname = strVal(linitial(names)); + r->relname = strVal(lsecond(names)); + break; + case 3: + r->catalogname = strVal(linitial(names));; + r->schemaname = strVal(lsecond(names)); + r->relname = strVal(lthird(names)); + break; + default: + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("improper qualified name (too many dotted names): %s", + NameListToString(names)), + parser_errposition(position))); + break; + } + + r->relpersistence = RELPERSISTENCE_PERMANENT; + r->location = position; + + return r; +} + +/* Separate Constraint nodes from COLLATE clauses in a ColQualList */ +static void +SplitColQualList(List *qualList, + List **constraintList, CollateClause **collClause, + core_yyscan_t yyscanner) +{ + ListCell *cell; + ListCell *prev; + ListCell *next; + + *collClause = NULL; + prev = NULL; + for (cell = list_head(qualList); cell; cell = next) + { + Node *n = (Node *) lfirst(cell); + + next = lnext(cell); + if (IsA(n, Constraint)) + { + /* keep it in list */ + prev = cell; + continue; + } + if (IsA(n, CollateClause)) + { + CollateClause *c = (CollateClause *) n; + + if (*collClause) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("multiple COLLATE clauses not allowed"), + parser_errposition(c->location))); + *collClause = c; + } + else + elog(ERROR, "unexpected node type %d", (int) n->type); + /* remove non-Constraint nodes from qualList */ + qualList = list_delete_cell(qualList, cell, prev); + } + *constraintList = qualList; +} + +/* + * Process result of ConstraintAttributeSpec, and set appropriate bool flags + * in the output command node. Pass NULL for any flags the particular + * command doesn't support. + */ +static void +processCASbits(int cas_bits, int location, const char *constrType, + bool *deferrable, bool *initdeferred, bool *not_valid, + bool *no_inherit, core_yyscan_t yyscanner) +{ + /* defaults */ + if (deferrable) + *deferrable = false; + if (initdeferred) + *initdeferred = false; + if (not_valid) + *not_valid = false; + + if (cas_bits & (CAS_DEFERRABLE | CAS_INITIALLY_DEFERRED)) + { + if (deferrable) + *deferrable = true; + else + ereport(ERROR, + (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), + /* translator: %s is CHECK, UNIQUE, or similar */ + errmsg("%s constraints cannot be marked DEFERRABLE", + constrType), + parser_errposition(location))); + } + + if (cas_bits & CAS_INITIALLY_DEFERRED) + { + if (initdeferred) + *initdeferred = true; + else + ereport(ERROR, + (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), + /* translator: %s is CHECK, UNIQUE, or similar */ + errmsg("%s constraints cannot be marked DEFERRABLE", + constrType), + parser_errposition(location))); + } + + if (cas_bits & CAS_NOT_VALID) + { + if (not_valid) + *not_valid = true; + else + ereport(ERROR, + (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), + /* translator: %s is CHECK, UNIQUE, or similar */ + errmsg("%s constraints cannot be marked NOT VALID", + constrType), + parser_errposition(location))); + } + + if (cas_bits & CAS_NO_INHERIT) + { + if (no_inherit) + *no_inherit = true; + else + ereport(ERROR, + (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), + /* translator: %s is CHECK, UNIQUE, or similar */ + errmsg("%s constraints cannot be marked NO INHERIT", + constrType), + parser_errposition(location))); + } +} + +/* parser_init() + * Initialize to parse one query string + */ +void +parser_init(base_yy_extra_type *yyext) +{ + yyext->parsetree = NIL; /* in case grammar forgets to set it */ +} + +/* + * Must undefine this stuff before including scan.c, since it has different + * definitions for these macros. + */ +#undef yyerror +#undef yylval +#undef yylloc + +#include "scan.c" + diff --git a/src/backend/parser/gram.h b/src/backend/parser/gram.h new file mode 100644 index 000000000..b0de768fd --- /dev/null +++ b/src/backend/parser/gram.h @@ -0,0 +1,527 @@ + +/* A Bison parser, made by GNU Bison 2.4.1. */ + +/* Skeleton interface for Bison's Yacc-like parsers in C + + Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 + Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . */ + +/* As a special exception, you may create a larger work that contains + part or all of the Bison parser skeleton and distribute that work + under terms of your choice, so long as that work isn't itself a + parser generator using the skeleton or a modified version thereof + as a parser skeleton. Alternatively, if you modify or redistribute + the parser skeleton itself, you may (at your option) remove this + special exception, which will cause the skeleton and the resulting + Bison output files to be licensed under the GNU General Public + License without this special exception. + + This special exception was added by the Free Software Foundation in + version 2.2 of Bison. */ + + +/* Tokens. */ +#ifndef YYTOKENTYPE +# define YYTOKENTYPE + /* Put the tokens into the symbol table, so that GDB and other debuggers + know about them. */ + enum yytokentype { + IDENT = 258, + FCONST = 259, + SCONST = 260, + BCONST = 261, + XCONST = 262, + Op = 263, + ICONST = 264, + PARAM = 265, + TYPECAST = 266, + DOT_DOT = 267, + COLON_EQUALS = 268, + ABORT_P = 269, + ABSOLUTE_P = 270, + ACCESS = 271, + ACTION = 272, + ADD_P = 273, + ADMIN = 274, + AFTER = 275, + AGGREGATE = 276, + ALL = 277, + ALSO = 278, + ALTER = 279, + ALWAYS = 280, + ANALYSE = 281, + ANALYZE = 282, + AND = 283, + ANY = 284, + ARRAY = 285, + AS = 286, + ASC = 287, + ASSERTION = 288, + ASSIGNMENT = 289, + ASYMMETRIC = 290, + AT = 291, + ATTRIBUTE = 292, + AUTHORIZATION = 293, + BACKWARD = 294, + BEFORE = 295, + BEGIN_P = 296, + BETWEEN = 297, + BIGINT = 298, + BINARY = 299, + BIT = 300, + BOOLEAN_P = 301, + BOTH = 302, + BY = 303, + CACHE = 304, + CALLED = 305, + CASCADE = 306, + CASCADED = 307, + CASE = 308, + CAST = 309, + CATALOG_P = 310, + CHAIN = 311, + CHAR_P = 312, + CHARACTER = 313, + CHARACTERISTICS = 314, + CHECK = 315, + CHECKPOINT = 316, + CLASS = 317, + CLOSE = 318, + CLUSTER = 319, + COALESCE = 320, + COLLATE = 321, + COLLATION = 322, + COLUMN = 323, + COMMENT = 324, + COMMENTS = 325, + COMMIT = 326, + COMMITTED = 327, + CONCURRENTLY = 328, + CONFIGURATION = 329, + CONNECTION = 330, + CONSTRAINT = 331, + CONSTRAINTS = 332, + CONTENT_P = 333, + CONTINUE_P = 334, + CONVERSION_P = 335, + COPY = 336, + COST = 337, + CREATE = 338, + CROSS = 339, + CSV = 340, + CURRENT_P = 341, + CURRENT_CATALOG = 342, + CURRENT_DATE = 343, + CURRENT_ROLE = 344, + CURRENT_SCHEMA = 345, + CURRENT_TIME = 346, + CURRENT_TIMESTAMP = 347, + CURRENT_USER = 348, + CURSOR = 349, + CYCLE = 350, + DATA_P = 351, + DATABASE = 352, + DAY_P = 353, + DEALLOCATE = 354, + DEC = 355, + DECIMAL_P = 356, + DECLARE = 357, + DEFAULT = 358, + DEFAULTS = 359, + DEFERRABLE = 360, + DEFERRED = 361, + DEFINER = 362, + DELETE_P = 363, + DELIMITER = 364, + DELIMITERS = 365, + DESC = 366, + DICTIONARY = 367, + DISABLE_P = 368, + DISCARD = 369, + DISTINCT = 370, + DO = 371, + DOCUMENT_P = 372, + DOMAIN_P = 373, + DOUBLE_P = 374, + DROP = 375, + EACH = 376, + ELSE = 377, + ENABLE_P = 378, + ENCODING = 379, + ENCRYPTED = 380, + END_P = 381, + ENUM_P = 382, + ESCAPE = 383, + EXCEPT = 384, + EXCLUDE = 385, + EXCLUDING = 386, + EXCLUSIVE = 387, + EXECUTE = 388, + EXISTS = 389, + EXPLAIN = 390, + EXTENSION = 391, + EXTERNAL = 392, + EXTRACT = 393, + FALSE_P = 394, + FAMILY = 395, + FETCH = 396, + FIRST_P = 397, + FLOAT_P = 398, + FOLLOWING = 399, + FOR = 400, + FORCE = 401, + FOREIGN = 402, + FORWARD = 403, + FREEZE = 404, + FROM = 405, + FULL = 406, + FUNCTION = 407, + FUNCTIONS = 408, + GLOBAL = 409, + GRANT = 410, + GRANTED = 411, + GREATEST = 412, + GROUP_P = 413, + HANDLER = 414, + HAVING = 415, + HEADER_P = 416, + HOLD = 417, + HOUR_P = 418, + IDENTITY_P = 419, + IF_P = 420, + ILIKE = 421, + IMMEDIATE = 422, + IMMUTABLE = 423, + IMPLICIT_P = 424, + IN_P = 425, + INCLUDING = 426, + INCREMENT = 427, + INDEX = 428, + INDEXES = 429, + INHERIT = 430, + INHERITS = 431, + INITIALLY = 432, + INLINE_P = 433, + INNER_P = 434, + INOUT = 435, + INPUT_P = 436, + INSENSITIVE = 437, + INSERT = 438, + INSTEAD = 439, + INT_P = 440, + INTEGER = 441, + INTERSECT = 442, + INTERVAL = 443, + INTO = 444, + INVOKER = 445, + IS = 446, + ISNULL = 447, + ISOLATION = 448, + JOIN = 449, + KEY = 450, + LABEL = 451, + LANGUAGE = 452, + LARGE_P = 453, + LAST_P = 454, + LC_COLLATE_P = 455, + LC_CTYPE_P = 456, + LEADING = 457, + LEAKPROOF = 458, + LEAST = 459, + LEFT = 460, + LEVEL = 461, + LIKE = 462, + LIMIT = 463, + LISTEN = 464, + LOAD = 465, + LOCAL = 466, + LOCALTIME = 467, + LOCALTIMESTAMP = 468, + LOCATION = 469, + LOCK_P = 470, + MAPPING = 471, + MATCH = 472, + MAXVALUE = 473, + MINUTE_P = 474, + MINVALUE = 475, + MODE = 476, + MONTH_P = 477, + MOVE = 478, + NAME_P = 479, + NAMES = 480, + NATIONAL = 481, + NATURAL = 482, + NCHAR = 483, + NEXT = 484, + NO = 485, + NONE = 486, + NOT = 487, + NOTHING = 488, + NOTIFY = 489, + NOTNULL = 490, + NOWAIT = 491, + NULL_P = 492, + NULLIF = 493, + NULLS_P = 494, + NUMERIC = 495, + OBJECT_P = 496, + OF = 497, + OFF = 498, + OFFSET = 499, + OIDS = 500, + ON = 501, + ONLY = 502, + OPERATOR = 503, + OPTION = 504, + OPTIONS = 505, + OR = 506, + ORDER = 507, + OUT_P = 508, + OUTER_P = 509, + OVER = 510, + OVERLAPS = 511, + OVERLAY = 512, + OWNED = 513, + OWNER = 514, + PARSER = 515, + PARTIAL = 516, + PARTITION = 517, + PASSING = 518, + PASSWORD = 519, + PLACING = 520, + PLANS = 521, + POSITION = 522, + PRECEDING = 523, + PRECISION = 524, + PRESERVE = 525, + PREPARE = 526, + PREPARED = 527, + PRIMARY = 528, + PRIOR = 529, + PRIVILEGES = 530, + PROCEDURAL = 531, + PROCEDURE = 532, + QUOTE = 533, + RANGE = 534, + READ = 535, + REAL = 536, + REASSIGN = 537, + RECHECK = 538, + RECURSIVE = 539, + REF = 540, + REFERENCES = 541, + REINDEX = 542, + RELATIVE_P = 543, + RELEASE = 544, + RENAME = 545, + REPEATABLE = 546, + REPLACE = 547, + REPLICA = 548, + RESET = 549, + RESTART = 550, + RESTRICT = 551, + RETURNING = 552, + RETURNS = 553, + REVOKE = 554, + RIGHT = 555, + ROLE = 556, + ROLLBACK = 557, + ROW = 558, + ROWS = 559, + RULE = 560, + SAVEPOINT = 561, + SCHEMA = 562, + SCROLL = 563, + SEARCH = 564, + SECOND_P = 565, + SECURITY = 566, + SELECT = 567, + SEQUENCE = 568, + SEQUENCES = 569, + SERIALIZABLE = 570, + SERVER = 571, + SESSION = 572, + SESSION_USER = 573, + SET = 574, + SETOF = 575, + SHARE = 576, + SHOW = 577, + SIMILAR = 578, + SIMPLE = 579, + SMALLINT = 580, + SNAPSHOT = 581, + SOME = 582, + STABLE = 583, + STANDALONE_P = 584, + START = 585, + STATEMENT = 586, + STATISTICS = 587, + STDIN = 588, + STDOUT = 589, + STORAGE = 590, + STRICT_P = 591, + STRIP_P = 592, + SUBSTRING = 593, + SYMMETRIC = 594, + SYSID = 595, + SYSTEM_P = 596, + TABLE = 597, + TABLES = 598, + TABLESPACE = 599, + TEMP = 600, + TEMPLATE = 601, + TEMPORARY = 602, + TEXT_P = 603, + THEN = 604, + TIME = 605, + TIMESTAMP = 606, + TO = 607, + TRAILING = 608, + TRANSACTION = 609, + TREAT = 610, + TRIGGER = 611, + TRIM = 612, + TRUE_P = 613, + TRUNCATE = 614, + TRUSTED = 615, + TYPE_P = 616, + TYPES_P = 617, + UNBOUNDED = 618, + UNCOMMITTED = 619, + UNENCRYPTED = 620, + UNION = 621, + UNIQUE = 622, + UNKNOWN = 623, + UNLISTEN = 624, + UNLOGGED = 625, + UNTIL = 626, + UPDATE = 627, + USER = 628, + USING = 629, + VACUUM = 630, + VALID = 631, + VALIDATE = 632, + VALIDATOR = 633, + VALUE_P = 634, + VALUES = 635, + VARCHAR = 636, + VARIADIC = 637, + VARYING = 638, + VERBOSE = 639, + VERSION_P = 640, + VIEW = 641, + VOLATILE = 642, + WHEN = 643, + WHERE = 644, + WHITESPACE_P = 645, + WINDOW = 646, + WITH = 647, + WITHOUT = 648, + WORK = 649, + WRAPPER = 650, + WRITE = 651, + XML_P = 652, + XMLATTRIBUTES = 653, + XMLCONCAT = 654, + XMLELEMENT = 655, + XMLEXISTS = 656, + XMLFOREST = 657, + XMLPARSE = 658, + XMLPI = 659, + XMLROOT = 660, + XMLSERIALIZE = 661, + YEAR_P = 662, + YES_P = 663, + ZONE = 664, + NULLS_FIRST = 665, + NULLS_LAST = 666, + WITH_TIME = 667, + POSTFIXOP = 668, + UMINUS = 669 + }; +#endif + + + +#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED +typedef union YYSTYPE +{ + +/* Line 1676 of yacc.c */ +#line 160 "gram.y" + + core_YYSTYPE core_yystype; + /* these fields must match core_YYSTYPE: */ + int ival; + char *str; + const char *keyword; + + char chr; + bool boolean; + JoinType jtype; + DropBehavior dbehavior; + OnCommitAction oncommit; + List *list; + Node *node; + Value *value; + ObjectType objtype; + TypeName *typnam; + FunctionParameter *fun_param; + FunctionParameterMode fun_param_mode; + FuncWithArgs *funwithargs; + DefElem *defelt; + SortBy *sortby; + WindowDef *windef; + JoinExpr *jexpr; + IndexElem *ielem; + Alias *alias; + RangeVar *range; + IntoClause *into; + WithClause *with; + A_Indices *aind; + ResTarget *target; + struct PrivTarget *privtarget; + AccessPriv *accesspriv; + InsertStmt *istmt; + VariableSetStmt *vsetstmt; + + + +/* Line 1676 of yacc.c */ +#line 505 "gram.h" +} YYSTYPE; +# define YYSTYPE_IS_TRIVIAL 1 +# define yystype YYSTYPE /* obsolescent; will be withdrawn */ +# define YYSTYPE_IS_DECLARED 1 +#endif + + + +#if ! defined YYLTYPE && ! defined YYLTYPE_IS_DECLARED +typedef struct YYLTYPE +{ + int first_line; + int first_column; + int last_line; + int last_column; +} YYLTYPE; +# define yyltype YYLTYPE /* obsolescent; will be withdrawn */ +# define YYLTYPE_IS_DECLARED 1 +# define YYLTYPE_IS_TRIVIAL 1 +#endif + + + diff --git a/src/backend/parser/scan.c b/src/backend/parser/scan.c new file mode 100644 index 000000000..12152468a --- /dev/null +++ b/src/backend/parser/scan.c @@ -0,0 +1,17565 @@ +#line 2 "scan.c" + +#line 4 "scan.c" + +#define YY_INT_ALIGNED short int + +/* A lexical scanner generated by flex */ + +#define FLEX_SCANNER +#define YY_FLEX_MAJOR_VERSION 2 +#define YY_FLEX_MINOR_VERSION 5 +#define YY_FLEX_SUBMINOR_VERSION 35 +#if YY_FLEX_SUBMINOR_VERSION > 0 +#define FLEX_BETA +#endif + +/* First, we deal with platform-specific or compiler-specific issues. */ + +/* begin standard C headers. */ +#include +#include +#include +#include + +/* end standard C headers. */ + +/* flex integer type definitions */ + +#ifndef FLEXINT_H +#define FLEXINT_H + +/* C99 systems have . Non-C99 systems may or may not. */ + +#if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L + +/* C99 says to define __STDC_LIMIT_MACROS before including stdint.h, + * if you want the limit (max/min) macros for int types. + */ +#ifndef __STDC_LIMIT_MACROS +#define __STDC_LIMIT_MACROS 1 +#endif + +#include +typedef int8_t flex_int8_t; +typedef uint8_t flex_uint8_t; +typedef int16_t flex_int16_t; +typedef uint16_t flex_uint16_t; +typedef int32_t flex_int32_t; +typedef uint32_t flex_uint32_t; +#else +typedef signed char flex_int8_t; +typedef short int flex_int16_t; +typedef int flex_int32_t; +typedef unsigned char flex_uint8_t; +typedef unsigned short int flex_uint16_t; +typedef unsigned int flex_uint32_t; + +/* Limits of integral types. */ +#ifndef INT8_MIN +#define INT8_MIN (-128) +#endif +#ifndef INT16_MIN +#define INT16_MIN (-32767-1) +#endif +#ifndef INT32_MIN +#define INT32_MIN (-2147483647-1) +#endif +#ifndef INT8_MAX +#define INT8_MAX (127) +#endif +#ifndef INT16_MAX +#define INT16_MAX (32767) +#endif +#ifndef INT32_MAX +#define INT32_MAX (2147483647) +#endif +#ifndef UINT8_MAX +#define UINT8_MAX (255U) +#endif +#ifndef UINT16_MAX +#define UINT16_MAX (65535U) +#endif +#ifndef UINT32_MAX +#define UINT32_MAX (4294967295U) +#endif + +#endif /* ! C99 */ + +#endif /* ! FLEXINT_H */ + +#ifdef __cplusplus + +/* The "const" storage-class-modifier is valid. */ +#define YY_USE_CONST + +#else /* ! __cplusplus */ + +/* C99 requires __STDC__ to be defined as 1. */ +#if defined (__STDC__) + +#define YY_USE_CONST + +#endif /* defined (__STDC__) */ +#endif /* ! __cplusplus */ + +#ifdef YY_USE_CONST +#define yyconst const +#else +#define yyconst +#endif + +/* Returned upon end-of-file. */ +#define YY_NULL 0 + +/* Promotes a possibly negative, possibly signed char to an unsigned + * integer for use as an array index. If the signed char is negative, + * we want to instead treat it as an 8-bit unsigned char, hence the + * double cast. + */ +#define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c) + +/* An opaque pointer. */ +#ifndef YY_TYPEDEF_YY_SCANNER_T +#define YY_TYPEDEF_YY_SCANNER_T +typedef void* yyscan_t; +#endif + +/* For convenience, these vars (plus the bison vars far below) + are macros in the reentrant scanner. */ +#define yyin yyg->yyin_r +#define yyout yyg->yyout_r +#define yyextra yyg->yyextra_r +#define yyleng yyg->yyleng_r +#define yytext yyg->yytext_r +#define yylineno (YY_CURRENT_BUFFER_LVALUE->yy_bs_lineno) +#define yycolumn (YY_CURRENT_BUFFER_LVALUE->yy_bs_column) +#define yy_flex_debug yyg->yy_flex_debug_r + +/* Enter a start condition. This macro really ought to take a parameter, + * but we do it the disgusting crufty way forced on us by the ()-less + * definition of BEGIN. + */ +#define BEGIN yyg->yy_start = 1 + 2 * + +/* Translate the current start state into a value that can be later handed + * to BEGIN to return to the state. The YYSTATE alias is for lex + * compatibility. + */ +#define YY_START ((yyg->yy_start - 1) / 2) +#define YYSTATE YY_START + +/* Action number for EOF rule of a given start state. */ +#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1) + +/* Special action meaning "start processing a new file". */ +#define YY_NEW_FILE core_yyrestart(yyin ,yyscanner ) + +#define YY_END_OF_BUFFER_CHAR 0 + +/* Size of default input buffer. */ +#ifndef YY_BUF_SIZE +#ifdef __ia64__ +/* On IA-64, the buffer size is 16k, not 8k. + * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case. + * Ditto for the __ia64__ case accordingly. + */ +#define YY_BUF_SIZE 32768 +#else +#define YY_BUF_SIZE 16384 +#endif /* __ia64__ */ +#endif + +/* The state buf must be large enough to hold one state per character in the main buffer. + */ +#define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type)) + +#ifndef YY_TYPEDEF_YY_BUFFER_STATE +#define YY_TYPEDEF_YY_BUFFER_STATE +typedef struct yy_buffer_state *YY_BUFFER_STATE; +#endif + +#define EOB_ACT_CONTINUE_SCAN 0 +#define EOB_ACT_END_OF_FILE 1 +#define EOB_ACT_LAST_MATCH 2 + + #define YY_LESS_LINENO(n) + +/* Return all but the first "n" matched characters back to the input stream. */ +#define yyless(n) \ + do \ + { \ + /* Undo effects of setting up yytext. */ \ + int yyless_macro_arg = (n); \ + YY_LESS_LINENO(yyless_macro_arg);\ + *yy_cp = yyg->yy_hold_char; \ + YY_RESTORE_YY_MORE_OFFSET \ + yyg->yy_c_buf_p = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \ + YY_DO_BEFORE_ACTION; /* set up yytext again */ \ + } \ + while ( 0 ) + +#define unput(c) yyunput( c, yyg->yytext_ptr , yyscanner ) + +#ifndef YY_TYPEDEF_YY_SIZE_T +#define YY_TYPEDEF_YY_SIZE_T +typedef size_t yy_size_t; +#endif + +#ifndef YY_STRUCT_YY_BUFFER_STATE +#define YY_STRUCT_YY_BUFFER_STATE +struct yy_buffer_state + { + FILE *yy_input_file; + + char *yy_ch_buf; /* input buffer */ + char *yy_buf_pos; /* current position in input buffer */ + + /* Size of input buffer in bytes, not including room for EOB + * characters. + */ + yy_size_t yy_buf_size; + + /* Number of characters read into yy_ch_buf, not including EOB + * characters. + */ + int yy_n_chars; + + /* Whether we "own" the buffer - i.e., we know we created it, + * and can realloc() it to grow it, and should free() it to + * delete it. + */ + int yy_is_our_buffer; + + /* Whether this is an "interactive" input source; if so, and + * if we're using stdio for input, then we want to use getc() + * instead of fread(), to make sure we stop fetching input after + * each newline. + */ + int yy_is_interactive; + + /* Whether we're considered to be at the beginning of a line. + * If so, '^' rules will be active on the next match, otherwise + * not. + */ + int yy_at_bol; + + int yy_bs_lineno; /**< The line count. */ + int yy_bs_column; /**< The column count. */ + + /* Whether to try to fill the input buffer when we reach the + * end of it. + */ + int yy_fill_buffer; + + int yy_buffer_status; + +#define YY_BUFFER_NEW 0 +#define YY_BUFFER_NORMAL 1 + /* When an EOF's been seen but there's still some text to process + * then we mark the buffer as YY_EOF_PENDING, to indicate that we + * shouldn't try reading from the input source any more. We might + * still have a bunch of tokens to match, though, because of + * possible backing-up. + * + * When we actually see the EOF, we change the status to "new" + * (via core_yyrestart()), so that the user can continue scanning by + * just pointing yyin at a new input file. + */ +#define YY_BUFFER_EOF_PENDING 2 + + }; +#endif /* !YY_STRUCT_YY_BUFFER_STATE */ + +/* We provide macros for accessing buffer states in case in the + * future we want to put the buffer states in a more general + * "scanner state". + * + * Returns the top of the stack, or NULL. + */ +#define YY_CURRENT_BUFFER ( yyg->yy_buffer_stack \ + ? yyg->yy_buffer_stack[yyg->yy_buffer_stack_top] \ + : NULL) + +/* Same as previous macro, but useful when we know that the buffer stack is not + * NULL or when we need an lvalue. For internal use only. + */ +#define YY_CURRENT_BUFFER_LVALUE yyg->yy_buffer_stack[yyg->yy_buffer_stack_top] + +void core_yyrestart (FILE *input_file ,yyscan_t yyscanner ); +void core_yy_switch_to_buffer (YY_BUFFER_STATE new_buffer ,yyscan_t yyscanner ); +YY_BUFFER_STATE core_yy_create_buffer (FILE *file,int size ,yyscan_t yyscanner ); +void core_yy_delete_buffer (YY_BUFFER_STATE b ,yyscan_t yyscanner ); +void core_yy_flush_buffer (YY_BUFFER_STATE b ,yyscan_t yyscanner ); +void core_yypush_buffer_state (YY_BUFFER_STATE new_buffer ,yyscan_t yyscanner ); +void core_yypop_buffer_state (yyscan_t yyscanner ); + +static void core_yyensure_buffer_stack (yyscan_t yyscanner ); +static void core_yy_load_buffer_state (yyscan_t yyscanner ); +static void core_yy_init_buffer (YY_BUFFER_STATE b,FILE *file ,yyscan_t yyscanner ); + +#define YY_FLUSH_BUFFER core_yy_flush_buffer(YY_CURRENT_BUFFER ,yyscanner) + +YY_BUFFER_STATE core_yy_scan_buffer (char *base,yy_size_t size ,yyscan_t yyscanner ); +YY_BUFFER_STATE core_yy_scan_string (yyconst char *yy_str ,yyscan_t yyscanner ); +YY_BUFFER_STATE core_yy_scan_bytes (yyconst char *bytes,int len ,yyscan_t yyscanner ); + +void *core_yyalloc (yy_size_t ,yyscan_t yyscanner ); +void *core_yyrealloc (void *,yy_size_t ,yyscan_t yyscanner ); +void core_yyfree (void * ,yyscan_t yyscanner ); + +#define yy_new_buffer core_yy_create_buffer + +#define yy_set_interactive(is_interactive) \ + { \ + if ( ! YY_CURRENT_BUFFER ){ \ + core_yyensure_buffer_stack (yyscanner); \ + YY_CURRENT_BUFFER_LVALUE = \ + core_yy_create_buffer(yyin,YY_BUF_SIZE ,yyscanner); \ + } \ + YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \ + } + +#define yy_set_bol(at_bol) \ + { \ + if ( ! YY_CURRENT_BUFFER ){\ + core_yyensure_buffer_stack (yyscanner); \ + YY_CURRENT_BUFFER_LVALUE = \ + core_yy_create_buffer(yyin,YY_BUF_SIZE ,yyscanner); \ + } \ + YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \ + } + +#define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol) + +/* Begin user sect3 */ + +#define core_yywrap(n) 1 +#define YY_SKIP_YYWRAP + +typedef unsigned char YY_CHAR; + +typedef yyconst struct yy_trans_info *yy_state_type; + +#define yytext_ptr yytext_r + +static yy_state_type yy_get_previous_state (yyscan_t yyscanner ); +static yy_state_type yy_try_NUL_trans (yy_state_type current_state ,yyscan_t yyscanner); +static int yy_get_next_buffer (yyscan_t yyscanner ); +static void yy_fatal_error (yyconst char msg[] ,yyscan_t yyscanner ); + +/* Done after the current pattern has been matched and before the + * corresponding action - sets up yytext. + */ +#define YY_DO_BEFORE_ACTION \ + yyg->yytext_ptr = yy_bp; \ + yyleng = (size_t) (yy_cp - yy_bp); \ + yyg->yy_hold_char = *yy_cp; \ + *yy_cp = '\0'; \ + yyg->yy_c_buf_p = yy_cp; + +#define YY_NUM_RULES 67 +#define YY_END_OF_BUFFER 68 +struct yy_trans_info + { + flex_int32_t yy_verify; + flex_int32_t yy_nxt; + }; +static yyconst struct yy_trans_info yy_transition[64535] = + { + { 0, 0 }, { 0,64279 }, { 0, 0 }, { 0,64277 }, { 1,5676 }, + { 2,5676 }, { 3,5676 }, { 4,5676 }, { 5,5676 }, { 6,5676 }, + { 7,5676 }, { 8,5676 }, { 9,5678 }, { 10,5683 }, { 11,5676 }, + { 12,5678 }, { 13,5678 }, { 14,5676 }, { 15,5676 }, { 16,5676 }, + { 17,5676 }, { 18,5676 }, { 19,5676 }, { 20,5676 }, { 21,5676 }, + { 22,5676 }, { 23,5676 }, { 24,5676 }, { 25,5676 }, { 26,5676 }, + { 27,5676 }, { 28,5676 }, { 29,5676 }, { 30,5676 }, { 31,5676 }, + { 32,5678 }, { 33,5685 }, { 34,5680 }, { 35,5685 }, { 36,5717 }, + { 37,5974 }, { 38,5685 }, { 39,5698 }, { 40,5700 }, { 41,5700 }, + { 42,5974 }, { 43,5974 }, { 44,5700 }, { 45,5985 }, { 46,6004 }, + + { 47,6075 }, { 48,6077 }, { 49,6077 }, { 50,6077 }, { 51,6077 }, + { 52,6077 }, { 53,6077 }, { 54,6077 }, { 55,6077 }, { 56,6077 }, + { 57,6077 }, { 58,5702 }, { 59,5700 }, { 60,5974 }, { 61,5974 }, + { 62,5974 }, { 63,5685 }, { 64,5685 }, { 65,6141 }, { 66,6398 }, + { 67,6141 }, { 68,6141 }, { 69,6655 }, { 70,6141 }, { 71,6141 }, + { 72,6141 }, { 73,6141 }, { 74,6141 }, { 75,6141 }, { 76,6141 }, + { 77,6141 }, { 78,6912 }, { 79,6141 }, { 80,6141 }, { 81,6141 }, + { 82,6141 }, { 83,6141 }, { 84,6141 }, { 85,7169 }, { 86,6141 }, + { 87,6141 }, { 88,7426 }, { 89,6141 }, { 90,6141 }, { 91,5700 }, + { 92,5676 }, { 93,5700 }, { 94,5974 }, { 95,6141 }, { 96,5685 }, + + { 97,6141 }, { 98,6398 }, { 99,6141 }, { 100,6141 }, { 101,6655 }, + { 102,6141 }, { 103,6141 }, { 104,6141 }, { 105,6141 }, { 106,6141 }, + { 107,6141 }, { 108,6141 }, { 109,6141 }, { 110,6912 }, { 111,6141 }, + { 112,6141 }, { 113,6141 }, { 114,6141 }, { 115,6141 }, { 116,6141 }, + { 117,7169 }, { 118,6141 }, { 119,6141 }, { 120,7426 }, { 121,6141 }, + { 122,6141 }, { 123,5676 }, { 124,5685 }, { 125,5676 }, { 126,5685 }, + { 127,5676 }, { 128,6141 }, { 129,6141 }, { 130,6141 }, { 131,6141 }, + { 132,6141 }, { 133,6141 }, { 134,6141 }, { 135,6141 }, { 136,6141 }, + { 137,6141 }, { 138,6141 }, { 139,6141 }, { 140,6141 }, { 141,6141 }, + { 142,6141 }, { 143,6141 }, { 144,6141 }, { 145,6141 }, { 146,6141 }, + + { 147,6141 }, { 148,6141 }, { 149,6141 }, { 150,6141 }, { 151,6141 }, + { 152,6141 }, { 153,6141 }, { 154,6141 }, { 155,6141 }, { 156,6141 }, + { 157,6141 }, { 158,6141 }, { 159,6141 }, { 160,6141 }, { 161,6141 }, + { 162,6141 }, { 163,6141 }, { 164,6141 }, { 165,6141 }, { 166,6141 }, + { 167,6141 }, { 168,6141 }, { 169,6141 }, { 170,6141 }, { 171,6141 }, + { 172,6141 }, { 173,6141 }, { 174,6141 }, { 175,6141 }, { 176,6141 }, + { 177,6141 }, { 178,6141 }, { 179,6141 }, { 180,6141 }, { 181,6141 }, + { 182,6141 }, { 183,6141 }, { 184,6141 }, { 185,6141 }, { 186,6141 }, + { 187,6141 }, { 188,6141 }, { 189,6141 }, { 190,6141 }, { 191,6141 }, + { 192,6141 }, { 193,6141 }, { 194,6141 }, { 195,6141 }, { 196,6141 }, + + { 197,6141 }, { 198,6141 }, { 199,6141 }, { 200,6141 }, { 201,6141 }, + { 202,6141 }, { 203,6141 }, { 204,6141 }, { 205,6141 }, { 206,6141 }, + { 207,6141 }, { 208,6141 }, { 209,6141 }, { 210,6141 }, { 211,6141 }, + { 212,6141 }, { 213,6141 }, { 214,6141 }, { 215,6141 }, { 216,6141 }, + { 217,6141 }, { 218,6141 }, { 219,6141 }, { 220,6141 }, { 221,6141 }, + { 222,6141 }, { 223,6141 }, { 224,6141 }, { 225,6141 }, { 226,6141 }, + { 227,6141 }, { 228,6141 }, { 229,6141 }, { 230,6141 }, { 231,6141 }, + { 232,6141 }, { 233,6141 }, { 234,6141 }, { 235,6141 }, { 236,6141 }, + { 237,6141 }, { 238,6141 }, { 239,6141 }, { 240,6141 }, { 241,6141 }, + { 242,6141 }, { 243,6141 }, { 244,6141 }, { 245,6141 }, { 246,6141 }, + + { 247,6141 }, { 248,6141 }, { 249,6141 }, { 250,6141 }, { 251,6141 }, + { 252,6141 }, { 253,6141 }, { 254,6141 }, { 255,6141 }, { 256,5676 }, + { 0, 0 }, { 0,64019 }, { 1,5418 }, { 2,5418 }, { 3,5418 }, + { 4,5418 }, { 5,5418 }, { 6,5418 }, { 7,5418 }, { 8,5418 }, + { 9,5420 }, { 10,5425 }, { 11,5418 }, { 12,5420 }, { 13,5420 }, + { 14,5418 }, { 15,5418 }, { 16,5418 }, { 17,5418 }, { 18,5418 }, + { 19,5418 }, { 20,5418 }, { 21,5418 }, { 22,5418 }, { 23,5418 }, + { 24,5418 }, { 25,5418 }, { 26,5418 }, { 27,5418 }, { 28,5418 }, + { 29,5418 }, { 30,5418 }, { 31,5418 }, { 32,5420 }, { 33,5427 }, + { 34,5422 }, { 35,5427 }, { 36,5459 }, { 37,5716 }, { 38,5427 }, + + { 39,5440 }, { 40,5442 }, { 41,5442 }, { 42,5716 }, { 43,5716 }, + { 44,5442 }, { 45,5727 }, { 46,5746 }, { 47,5817 }, { 48,5819 }, + { 49,5819 }, { 50,5819 }, { 51,5819 }, { 52,5819 }, { 53,5819 }, + { 54,5819 }, { 55,5819 }, { 56,5819 }, { 57,5819 }, { 58,5444 }, + { 59,5442 }, { 60,5716 }, { 61,5716 }, { 62,5716 }, { 63,5427 }, + { 64,5427 }, { 65,5883 }, { 66,6140 }, { 67,5883 }, { 68,5883 }, + { 69,6397 }, { 70,5883 }, { 71,5883 }, { 72,5883 }, { 73,5883 }, + { 74,5883 }, { 75,5883 }, { 76,5883 }, { 77,5883 }, { 78,6654 }, + { 79,5883 }, { 80,5883 }, { 81,5883 }, { 82,5883 }, { 83,5883 }, + { 84,5883 }, { 85,6911 }, { 86,5883 }, { 87,5883 }, { 88,7168 }, + + { 89,5883 }, { 90,5883 }, { 91,5442 }, { 92,5418 }, { 93,5442 }, + { 94,5716 }, { 95,5883 }, { 96,5427 }, { 97,5883 }, { 98,6140 }, + { 99,5883 }, { 100,5883 }, { 101,6397 }, { 102,5883 }, { 103,5883 }, + { 104,5883 }, { 105,5883 }, { 106,5883 }, { 107,5883 }, { 108,5883 }, + { 109,5883 }, { 110,6654 }, { 111,5883 }, { 112,5883 }, { 113,5883 }, + { 114,5883 }, { 115,5883 }, { 116,5883 }, { 117,6911 }, { 118,5883 }, + { 119,5883 }, { 120,7168 }, { 121,5883 }, { 122,5883 }, { 123,5418 }, + { 124,5427 }, { 125,5418 }, { 126,5427 }, { 127,5418 }, { 128,5883 }, + { 129,5883 }, { 130,5883 }, { 131,5883 }, { 132,5883 }, { 133,5883 }, + { 134,5883 }, { 135,5883 }, { 136,5883 }, { 137,5883 }, { 138,5883 }, + + { 139,5883 }, { 140,5883 }, { 141,5883 }, { 142,5883 }, { 143,5883 }, + { 144,5883 }, { 145,5883 }, { 146,5883 }, { 147,5883 }, { 148,5883 }, + { 149,5883 }, { 150,5883 }, { 151,5883 }, { 152,5883 }, { 153,5883 }, + { 154,5883 }, { 155,5883 }, { 156,5883 }, { 157,5883 }, { 158,5883 }, + { 159,5883 }, { 160,5883 }, { 161,5883 }, { 162,5883 }, { 163,5883 }, + { 164,5883 }, { 165,5883 }, { 166,5883 }, { 167,5883 }, { 168,5883 }, + { 169,5883 }, { 170,5883 }, { 171,5883 }, { 172,5883 }, { 173,5883 }, + { 174,5883 }, { 175,5883 }, { 176,5883 }, { 177,5883 }, { 178,5883 }, + { 179,5883 }, { 180,5883 }, { 181,5883 }, { 182,5883 }, { 183,5883 }, + { 184,5883 }, { 185,5883 }, { 186,5883 }, { 187,5883 }, { 188,5883 }, + + { 189,5883 }, { 190,5883 }, { 191,5883 }, { 192,5883 }, { 193,5883 }, + { 194,5883 }, { 195,5883 }, { 196,5883 }, { 197,5883 }, { 198,5883 }, + { 199,5883 }, { 200,5883 }, { 201,5883 }, { 202,5883 }, { 203,5883 }, + { 204,5883 }, { 205,5883 }, { 206,5883 }, { 207,5883 }, { 208,5883 }, + { 209,5883 }, { 210,5883 }, { 211,5883 }, { 212,5883 }, { 213,5883 }, + { 214,5883 }, { 215,5883 }, { 216,5883 }, { 217,5883 }, { 218,5883 }, + { 219,5883 }, { 220,5883 }, { 221,5883 }, { 222,5883 }, { 223,5883 }, + { 224,5883 }, { 225,5883 }, { 226,5883 }, { 227,5883 }, { 228,5883 }, + { 229,5883 }, { 230,5883 }, { 231,5883 }, { 232,5883 }, { 233,5883 }, + { 234,5883 }, { 235,5883 }, { 236,5883 }, { 237,5883 }, { 238,5883 }, + + { 239,5883 }, { 240,5883 }, { 241,5883 }, { 242,5883 }, { 243,5883 }, + { 244,5883 }, { 245,5883 }, { 246,5883 }, { 247,5883 }, { 248,5883 }, + { 249,5883 }, { 250,5883 }, { 251,5883 }, { 252,5883 }, { 253,5883 }, + { 254,5883 }, { 255,5883 }, { 256,5418 }, { 0, 12 }, { 0,63761 }, + { 1,7167 }, { 2,7167 }, { 3,7167 }, { 4,7167 }, { 5,7167 }, + { 6,7167 }, { 7,7167 }, { 8,7167 }, { 9,7167 }, { 10,7167 }, + { 11,7167 }, { 12,7167 }, { 13,7167 }, { 14,7167 }, { 15,7167 }, + { 16,7167 }, { 17,7167 }, { 18,7167 }, { 19,7167 }, { 20,7167 }, + { 21,7167 }, { 22,7167 }, { 23,7167 }, { 24,7167 }, { 25,7167 }, + { 26,7167 }, { 27,7167 }, { 28,7167 }, { 29,7167 }, { 30,7167 }, + + { 31,7167 }, { 32,7167 }, { 33,7167 }, { 34,7167 }, { 35,7167 }, + { 36,7167 }, { 37,7167 }, { 38,7167 }, { 39,7425 }, { 40,7167 }, + { 41,7167 }, { 42,7167 }, { 43,7167 }, { 44,7167 }, { 45,7167 }, + { 46,7167 }, { 47,7167 }, { 48,7167 }, { 49,7167 }, { 50,7167 }, + { 51,7167 }, { 52,7167 }, { 53,7167 }, { 54,7167 }, { 55,7167 }, + { 56,7167 }, { 57,7167 }, { 58,7167 }, { 59,7167 }, { 60,7167 }, + { 61,7167 }, { 62,7167 }, { 63,7167 }, { 64,7167 }, { 65,7167 }, + { 66,7167 }, { 67,7167 }, { 68,7167 }, { 69,7167 }, { 70,7167 }, + { 71,7167 }, { 72,7167 }, { 73,7167 }, { 74,7167 }, { 75,7167 }, + { 76,7167 }, { 77,7167 }, { 78,7167 }, { 79,7167 }, { 80,7167 }, + + { 81,7167 }, { 82,7167 }, { 83,7167 }, { 84,7167 }, { 85,7167 }, + { 86,7167 }, { 87,7167 }, { 88,7167 }, { 89,7167 }, { 90,7167 }, + { 91,7167 }, { 92,7167 }, { 93,7167 }, { 94,7167 }, { 95,7167 }, + { 96,7167 }, { 97,7167 }, { 98,7167 }, { 99,7167 }, { 100,7167 }, + { 101,7167 }, { 102,7167 }, { 103,7167 }, { 104,7167 }, { 105,7167 }, + { 106,7167 }, { 107,7167 }, { 108,7167 }, { 109,7167 }, { 110,7167 }, + { 111,7167 }, { 112,7167 }, { 113,7167 }, { 114,7167 }, { 115,7167 }, + { 116,7167 }, { 117,7167 }, { 118,7167 }, { 119,7167 }, { 120,7167 }, + { 121,7167 }, { 122,7167 }, { 123,7167 }, { 124,7167 }, { 125,7167 }, + { 126,7167 }, { 127,7167 }, { 128,7167 }, { 129,7167 }, { 130,7167 }, + + { 131,7167 }, { 132,7167 }, { 133,7167 }, { 134,7167 }, { 135,7167 }, + { 136,7167 }, { 137,7167 }, { 138,7167 }, { 139,7167 }, { 140,7167 }, + { 141,7167 }, { 142,7167 }, { 143,7167 }, { 144,7167 }, { 145,7167 }, + { 146,7167 }, { 147,7167 }, { 148,7167 }, { 149,7167 }, { 150,7167 }, + { 151,7167 }, { 152,7167 }, { 153,7167 }, { 154,7167 }, { 155,7167 }, + { 156,7167 }, { 157,7167 }, { 158,7167 }, { 159,7167 }, { 160,7167 }, + { 161,7167 }, { 162,7167 }, { 163,7167 }, { 164,7167 }, { 165,7167 }, + { 166,7167 }, { 167,7167 }, { 168,7167 }, { 169,7167 }, { 170,7167 }, + { 171,7167 }, { 172,7167 }, { 173,7167 }, { 174,7167 }, { 175,7167 }, + { 176,7167 }, { 177,7167 }, { 178,7167 }, { 179,7167 }, { 180,7167 }, + + { 181,7167 }, { 182,7167 }, { 183,7167 }, { 184,7167 }, { 185,7167 }, + { 186,7167 }, { 187,7167 }, { 188,7167 }, { 189,7167 }, { 190,7167 }, + { 191,7167 }, { 192,7167 }, { 193,7167 }, { 194,7167 }, { 195,7167 }, + { 196,7167 }, { 197,7167 }, { 198,7167 }, { 199,7167 }, { 200,7167 }, + { 201,7167 }, { 202,7167 }, { 203,7167 }, { 204,7167 }, { 205,7167 }, + { 206,7167 }, { 207,7167 }, { 208,7167 }, { 209,7167 }, { 210,7167 }, + { 211,7167 }, { 212,7167 }, { 213,7167 }, { 214,7167 }, { 215,7167 }, + { 216,7167 }, { 217,7167 }, { 218,7167 }, { 219,7167 }, { 220,7167 }, + { 221,7167 }, { 222,7167 }, { 223,7167 }, { 224,7167 }, { 225,7167 }, + { 226,7167 }, { 227,7167 }, { 228,7167 }, { 229,7167 }, { 230,7167 }, + + { 231,7167 }, { 232,7167 }, { 233,7167 }, { 234,7167 }, { 235,7167 }, + { 236,7167 }, { 237,7167 }, { 238,7167 }, { 239,7167 }, { 240,7167 }, + { 241,7167 }, { 242,7167 }, { 243,7167 }, { 244,7167 }, { 245,7167 }, + { 246,7167 }, { 247,7167 }, { 248,7167 }, { 249,7167 }, { 250,7167 }, + { 251,7167 }, { 252,7167 }, { 253,7167 }, { 254,7167 }, { 255,7167 }, + { 256,7167 }, { 0, 12 }, { 0,63503 }, { 1,6909 }, { 2,6909 }, + { 3,6909 }, { 4,6909 }, { 5,6909 }, { 6,6909 }, { 7,6909 }, + { 8,6909 }, { 9,6909 }, { 10,6909 }, { 11,6909 }, { 12,6909 }, + { 13,6909 }, { 14,6909 }, { 15,6909 }, { 16,6909 }, { 17,6909 }, + { 18,6909 }, { 19,6909 }, { 20,6909 }, { 21,6909 }, { 22,6909 }, + + { 23,6909 }, { 24,6909 }, { 25,6909 }, { 26,6909 }, { 27,6909 }, + { 28,6909 }, { 29,6909 }, { 30,6909 }, { 31,6909 }, { 32,6909 }, + { 33,6909 }, { 34,6909 }, { 35,6909 }, { 36,6909 }, { 37,6909 }, + { 38,6909 }, { 39,7167 }, { 40,6909 }, { 41,6909 }, { 42,6909 }, + { 43,6909 }, { 44,6909 }, { 45,6909 }, { 46,6909 }, { 47,6909 }, + { 48,6909 }, { 49,6909 }, { 50,6909 }, { 51,6909 }, { 52,6909 }, + { 53,6909 }, { 54,6909 }, { 55,6909 }, { 56,6909 }, { 57,6909 }, + { 58,6909 }, { 59,6909 }, { 60,6909 }, { 61,6909 }, { 62,6909 }, + { 63,6909 }, { 64,6909 }, { 65,6909 }, { 66,6909 }, { 67,6909 }, + { 68,6909 }, { 69,6909 }, { 70,6909 }, { 71,6909 }, { 72,6909 }, + + { 73,6909 }, { 74,6909 }, { 75,6909 }, { 76,6909 }, { 77,6909 }, + { 78,6909 }, { 79,6909 }, { 80,6909 }, { 81,6909 }, { 82,6909 }, + { 83,6909 }, { 84,6909 }, { 85,6909 }, { 86,6909 }, { 87,6909 }, + { 88,6909 }, { 89,6909 }, { 90,6909 }, { 91,6909 }, { 92,6909 }, + { 93,6909 }, { 94,6909 }, { 95,6909 }, { 96,6909 }, { 97,6909 }, + { 98,6909 }, { 99,6909 }, { 100,6909 }, { 101,6909 }, { 102,6909 }, + { 103,6909 }, { 104,6909 }, { 105,6909 }, { 106,6909 }, { 107,6909 }, + { 108,6909 }, { 109,6909 }, { 110,6909 }, { 111,6909 }, { 112,6909 }, + { 113,6909 }, { 114,6909 }, { 115,6909 }, { 116,6909 }, { 117,6909 }, + { 118,6909 }, { 119,6909 }, { 120,6909 }, { 121,6909 }, { 122,6909 }, + + { 123,6909 }, { 124,6909 }, { 125,6909 }, { 126,6909 }, { 127,6909 }, + { 128,6909 }, { 129,6909 }, { 130,6909 }, { 131,6909 }, { 132,6909 }, + { 133,6909 }, { 134,6909 }, { 135,6909 }, { 136,6909 }, { 137,6909 }, + { 138,6909 }, { 139,6909 }, { 140,6909 }, { 141,6909 }, { 142,6909 }, + { 143,6909 }, { 144,6909 }, { 145,6909 }, { 146,6909 }, { 147,6909 }, + { 148,6909 }, { 149,6909 }, { 150,6909 }, { 151,6909 }, { 152,6909 }, + { 153,6909 }, { 154,6909 }, { 155,6909 }, { 156,6909 }, { 157,6909 }, + { 158,6909 }, { 159,6909 }, { 160,6909 }, { 161,6909 }, { 162,6909 }, + { 163,6909 }, { 164,6909 }, { 165,6909 }, { 166,6909 }, { 167,6909 }, + { 168,6909 }, { 169,6909 }, { 170,6909 }, { 171,6909 }, { 172,6909 }, + + { 173,6909 }, { 174,6909 }, { 175,6909 }, { 176,6909 }, { 177,6909 }, + { 178,6909 }, { 179,6909 }, { 180,6909 }, { 181,6909 }, { 182,6909 }, + { 183,6909 }, { 184,6909 }, { 185,6909 }, { 186,6909 }, { 187,6909 }, + { 188,6909 }, { 189,6909 }, { 190,6909 }, { 191,6909 }, { 192,6909 }, + { 193,6909 }, { 194,6909 }, { 195,6909 }, { 196,6909 }, { 197,6909 }, + { 198,6909 }, { 199,6909 }, { 200,6909 }, { 201,6909 }, { 202,6909 }, + { 203,6909 }, { 204,6909 }, { 205,6909 }, { 206,6909 }, { 207,6909 }, + { 208,6909 }, { 209,6909 }, { 210,6909 }, { 211,6909 }, { 212,6909 }, + { 213,6909 }, { 214,6909 }, { 215,6909 }, { 216,6909 }, { 217,6909 }, + { 218,6909 }, { 219,6909 }, { 220,6909 }, { 221,6909 }, { 222,6909 }, + + { 223,6909 }, { 224,6909 }, { 225,6909 }, { 226,6909 }, { 227,6909 }, + { 228,6909 }, { 229,6909 }, { 230,6909 }, { 231,6909 }, { 232,6909 }, + { 233,6909 }, { 234,6909 }, { 235,6909 }, { 236,6909 }, { 237,6909 }, + { 238,6909 }, { 239,6909 }, { 240,6909 }, { 241,6909 }, { 242,6909 }, + { 243,6909 }, { 244,6909 }, { 245,6909 }, { 246,6909 }, { 247,6909 }, + { 248,6909 }, { 249,6909 }, { 250,6909 }, { 251,6909 }, { 252,6909 }, + { 253,6909 }, { 254,6909 }, { 255,6909 }, { 256,6909 }, { 0, 0 }, + { 0,63245 }, { 1,6956 }, { 2,6956 }, { 3,6956 }, { 4,6956 }, + { 5,6956 }, { 6,6956 }, { 7,6956 }, { 8,6956 }, { 9,6956 }, + { 10,6956 }, { 11,6956 }, { 12,6956 }, { 13,6956 }, { 14,6956 }, + + { 15,6956 }, { 16,6956 }, { 17,6956 }, { 18,6956 }, { 19,6956 }, + { 20,6956 }, { 21,6956 }, { 22,6956 }, { 23,6956 }, { 24,6956 }, + { 25,6956 }, { 26,6956 }, { 27,6956 }, { 28,6956 }, { 29,6956 }, + { 30,6956 }, { 31,6956 }, { 32,6956 }, { 33,7214 }, { 34,6956 }, + { 35,7214 }, { 36,6956 }, { 37,7214 }, { 38,7214 }, { 39,6956 }, + { 40,6956 }, { 41,6956 }, { 42,4676 }, { 43,7214 }, { 44,6956 }, + { 45,7214 }, { 46,6956 }, { 47,4680 }, { 48,6956 }, { 49,6956 }, + { 50,6956 }, { 51,6956 }, { 52,6956 }, { 53,6956 }, { 54,6956 }, + { 55,6956 }, { 56,6956 }, { 57,6956 }, { 58,6956 }, { 59,6956 }, + { 60,7214 }, { 61,7214 }, { 62,7214 }, { 63,7214 }, { 64,7214 }, + + { 65,6956 }, { 66,6956 }, { 67,6956 }, { 68,6956 }, { 69,6956 }, + { 70,6956 }, { 71,6956 }, { 72,6956 }, { 73,6956 }, { 74,6956 }, + { 75,6956 }, { 76,6956 }, { 77,6956 }, { 78,6956 }, { 79,6956 }, + { 80,6956 }, { 81,6956 }, { 82,6956 }, { 83,6956 }, { 84,6956 }, + { 85,6956 }, { 86,6956 }, { 87,6956 }, { 88,6956 }, { 89,6956 }, + { 90,6956 }, { 91,6956 }, { 92,6956 }, { 93,6956 }, { 94,7214 }, + { 95,6956 }, { 96,7214 }, { 97,6956 }, { 98,6956 }, { 99,6956 }, + { 100,6956 }, { 101,6956 }, { 102,6956 }, { 103,6956 }, { 104,6956 }, + { 105,6956 }, { 106,6956 }, { 107,6956 }, { 108,6956 }, { 109,6956 }, + { 110,6956 }, { 111,6956 }, { 112,6956 }, { 113,6956 }, { 114,6956 }, + + { 115,6956 }, { 116,6956 }, { 117,6956 }, { 118,6956 }, { 119,6956 }, + { 120,6956 }, { 121,6956 }, { 122,6956 }, { 123,6956 }, { 124,7214 }, + { 125,6956 }, { 126,7214 }, { 127,6956 }, { 128,6956 }, { 129,6956 }, + { 130,6956 }, { 131,6956 }, { 132,6956 }, { 133,6956 }, { 134,6956 }, + { 135,6956 }, { 136,6956 }, { 137,6956 }, { 138,6956 }, { 139,6956 }, + { 140,6956 }, { 141,6956 }, { 142,6956 }, { 143,6956 }, { 144,6956 }, + { 145,6956 }, { 146,6956 }, { 147,6956 }, { 148,6956 }, { 149,6956 }, + { 150,6956 }, { 151,6956 }, { 152,6956 }, { 153,6956 }, { 154,6956 }, + { 155,6956 }, { 156,6956 }, { 157,6956 }, { 158,6956 }, { 159,6956 }, + { 160,6956 }, { 161,6956 }, { 162,6956 }, { 163,6956 }, { 164,6956 }, + + { 165,6956 }, { 166,6956 }, { 167,6956 }, { 168,6956 }, { 169,6956 }, + { 170,6956 }, { 171,6956 }, { 172,6956 }, { 173,6956 }, { 174,6956 }, + { 175,6956 }, { 176,6956 }, { 177,6956 }, { 178,6956 }, { 179,6956 }, + { 180,6956 }, { 181,6956 }, { 182,6956 }, { 183,6956 }, { 184,6956 }, + { 185,6956 }, { 186,6956 }, { 187,6956 }, { 188,6956 }, { 189,6956 }, + { 190,6956 }, { 191,6956 }, { 192,6956 }, { 193,6956 }, { 194,6956 }, + { 195,6956 }, { 196,6956 }, { 197,6956 }, { 198,6956 }, { 199,6956 }, + { 200,6956 }, { 201,6956 }, { 202,6956 }, { 203,6956 }, { 204,6956 }, + { 205,6956 }, { 206,6956 }, { 207,6956 }, { 208,6956 }, { 209,6956 }, + { 210,6956 }, { 211,6956 }, { 212,6956 }, { 213,6956 }, { 214,6956 }, + + { 215,6956 }, { 216,6956 }, { 217,6956 }, { 218,6956 }, { 219,6956 }, + { 220,6956 }, { 221,6956 }, { 222,6956 }, { 223,6956 }, { 224,6956 }, + { 225,6956 }, { 226,6956 }, { 227,6956 }, { 228,6956 }, { 229,6956 }, + { 230,6956 }, { 231,6956 }, { 232,6956 }, { 233,6956 }, { 234,6956 }, + { 235,6956 }, { 236,6956 }, { 237,6956 }, { 238,6956 }, { 239,6956 }, + { 240,6956 }, { 241,6956 }, { 242,6956 }, { 243,6956 }, { 244,6956 }, + { 245,6956 }, { 246,6956 }, { 247,6956 }, { 248,6956 }, { 249,6956 }, + { 250,6956 }, { 251,6956 }, { 252,6956 }, { 253,6956 }, { 254,6956 }, + { 255,6956 }, { 256,6956 }, { 0, 0 }, { 0,62987 }, { 1,6698 }, + { 2,6698 }, { 3,6698 }, { 4,6698 }, { 5,6698 }, { 6,6698 }, + + { 7,6698 }, { 8,6698 }, { 9,6698 }, { 10,6698 }, { 11,6698 }, + { 12,6698 }, { 13,6698 }, { 14,6698 }, { 15,6698 }, { 16,6698 }, + { 17,6698 }, { 18,6698 }, { 19,6698 }, { 20,6698 }, { 21,6698 }, + { 22,6698 }, { 23,6698 }, { 24,6698 }, { 25,6698 }, { 26,6698 }, + { 27,6698 }, { 28,6698 }, { 29,6698 }, { 30,6698 }, { 31,6698 }, + { 32,6698 }, { 33,6956 }, { 34,6698 }, { 35,6956 }, { 36,6698 }, + { 37,6956 }, { 38,6956 }, { 39,6698 }, { 40,6698 }, { 41,6698 }, + { 42,4418 }, { 43,6956 }, { 44,6698 }, { 45,6956 }, { 46,6698 }, + { 47,4422 }, { 48,6698 }, { 49,6698 }, { 50,6698 }, { 51,6698 }, + { 52,6698 }, { 53,6698 }, { 54,6698 }, { 55,6698 }, { 56,6698 }, + + { 57,6698 }, { 58,6698 }, { 59,6698 }, { 60,6956 }, { 61,6956 }, + { 62,6956 }, { 63,6956 }, { 64,6956 }, { 65,6698 }, { 66,6698 }, + { 67,6698 }, { 68,6698 }, { 69,6698 }, { 70,6698 }, { 71,6698 }, + { 72,6698 }, { 73,6698 }, { 74,6698 }, { 75,6698 }, { 76,6698 }, + { 77,6698 }, { 78,6698 }, { 79,6698 }, { 80,6698 }, { 81,6698 }, + { 82,6698 }, { 83,6698 }, { 84,6698 }, { 85,6698 }, { 86,6698 }, + { 87,6698 }, { 88,6698 }, { 89,6698 }, { 90,6698 }, { 91,6698 }, + { 92,6698 }, { 93,6698 }, { 94,6956 }, { 95,6698 }, { 96,6956 }, + { 97,6698 }, { 98,6698 }, { 99,6698 }, { 100,6698 }, { 101,6698 }, + { 102,6698 }, { 103,6698 }, { 104,6698 }, { 105,6698 }, { 106,6698 }, + + { 107,6698 }, { 108,6698 }, { 109,6698 }, { 110,6698 }, { 111,6698 }, + { 112,6698 }, { 113,6698 }, { 114,6698 }, { 115,6698 }, { 116,6698 }, + { 117,6698 }, { 118,6698 }, { 119,6698 }, { 120,6698 }, { 121,6698 }, + { 122,6698 }, { 123,6698 }, { 124,6956 }, { 125,6698 }, { 126,6956 }, + { 127,6698 }, { 128,6698 }, { 129,6698 }, { 130,6698 }, { 131,6698 }, + { 132,6698 }, { 133,6698 }, { 134,6698 }, { 135,6698 }, { 136,6698 }, + { 137,6698 }, { 138,6698 }, { 139,6698 }, { 140,6698 }, { 141,6698 }, + { 142,6698 }, { 143,6698 }, { 144,6698 }, { 145,6698 }, { 146,6698 }, + { 147,6698 }, { 148,6698 }, { 149,6698 }, { 150,6698 }, { 151,6698 }, + { 152,6698 }, { 153,6698 }, { 154,6698 }, { 155,6698 }, { 156,6698 }, + + { 157,6698 }, { 158,6698 }, { 159,6698 }, { 160,6698 }, { 161,6698 }, + { 162,6698 }, { 163,6698 }, { 164,6698 }, { 165,6698 }, { 166,6698 }, + { 167,6698 }, { 168,6698 }, { 169,6698 }, { 170,6698 }, { 171,6698 }, + { 172,6698 }, { 173,6698 }, { 174,6698 }, { 175,6698 }, { 176,6698 }, + { 177,6698 }, { 178,6698 }, { 179,6698 }, { 180,6698 }, { 181,6698 }, + { 182,6698 }, { 183,6698 }, { 184,6698 }, { 185,6698 }, { 186,6698 }, + { 187,6698 }, { 188,6698 }, { 189,6698 }, { 190,6698 }, { 191,6698 }, + { 192,6698 }, { 193,6698 }, { 194,6698 }, { 195,6698 }, { 196,6698 }, + { 197,6698 }, { 198,6698 }, { 199,6698 }, { 200,6698 }, { 201,6698 }, + { 202,6698 }, { 203,6698 }, { 204,6698 }, { 205,6698 }, { 206,6698 }, + + { 207,6698 }, { 208,6698 }, { 209,6698 }, { 210,6698 }, { 211,6698 }, + { 212,6698 }, { 213,6698 }, { 214,6698 }, { 215,6698 }, { 216,6698 }, + { 217,6698 }, { 218,6698 }, { 219,6698 }, { 220,6698 }, { 221,6698 }, + { 222,6698 }, { 223,6698 }, { 224,6698 }, { 225,6698 }, { 226,6698 }, + { 227,6698 }, { 228,6698 }, { 229,6698 }, { 230,6698 }, { 231,6698 }, + { 232,6698 }, { 233,6698 }, { 234,6698 }, { 235,6698 }, { 236,6698 }, + { 237,6698 }, { 238,6698 }, { 239,6698 }, { 240,6698 }, { 241,6698 }, + { 242,6698 }, { 243,6698 }, { 244,6698 }, { 245,6698 }, { 246,6698 }, + { 247,6698 }, { 248,6698 }, { 249,6698 }, { 250,6698 }, { 251,6698 }, + { 252,6698 }, { 253,6698 }, { 254,6698 }, { 255,6698 }, { 256,6698 }, + + { 0, 0 }, { 0,62729 }, { 1,6956 }, { 2,6956 }, { 3,6956 }, + { 4,6956 }, { 5,6956 }, { 6,6956 }, { 7,6956 }, { 8,6956 }, + { 9,6956 }, { 10,6956 }, { 11,6956 }, { 12,6956 }, { 13,6956 }, + { 14,6956 }, { 15,6956 }, { 16,6956 }, { 17,6956 }, { 18,6956 }, + { 19,6956 }, { 20,6956 }, { 21,6956 }, { 22,6956 }, { 23,6956 }, + { 24,6956 }, { 25,6956 }, { 26,6956 }, { 27,6956 }, { 28,6956 }, + { 29,6956 }, { 30,6956 }, { 31,6956 }, { 32,6956 }, { 33,6956 }, + { 34,4177 }, { 35,6956 }, { 36,6956 }, { 37,6956 }, { 38,6956 }, + { 39,6956 }, { 40,6956 }, { 41,6956 }, { 42,6956 }, { 43,6956 }, + { 44,6956 }, { 45,6956 }, { 46,6956 }, { 47,6956 }, { 48,6956 }, + + { 49,6956 }, { 50,6956 }, { 51,6956 }, { 52,6956 }, { 53,6956 }, + { 54,6956 }, { 55,6956 }, { 56,6956 }, { 57,6956 }, { 58,6956 }, + { 59,6956 }, { 60,6956 }, { 61,6956 }, { 62,6956 }, { 63,6956 }, + { 64,6956 }, { 65,6956 }, { 66,6956 }, { 67,6956 }, { 68,6956 }, + { 69,6956 }, { 70,6956 }, { 71,6956 }, { 72,6956 }, { 73,6956 }, + { 74,6956 }, { 75,6956 }, { 76,6956 }, { 77,6956 }, { 78,6956 }, + { 79,6956 }, { 80,6956 }, { 81,6956 }, { 82,6956 }, { 83,6956 }, + { 84,6956 }, { 85,6956 }, { 86,6956 }, { 87,6956 }, { 88,6956 }, + { 89,6956 }, { 90,6956 }, { 91,6956 }, { 92,6956 }, { 93,6956 }, + { 94,6956 }, { 95,6956 }, { 96,6956 }, { 97,6956 }, { 98,6956 }, + + { 99,6956 }, { 100,6956 }, { 101,6956 }, { 102,6956 }, { 103,6956 }, + { 104,6956 }, { 105,6956 }, { 106,6956 }, { 107,6956 }, { 108,6956 }, + { 109,6956 }, { 110,6956 }, { 111,6956 }, { 112,6956 }, { 113,6956 }, + { 114,6956 }, { 115,6956 }, { 116,6956 }, { 117,6956 }, { 118,6956 }, + { 119,6956 }, { 120,6956 }, { 121,6956 }, { 122,6956 }, { 123,6956 }, + { 124,6956 }, { 125,6956 }, { 126,6956 }, { 127,6956 }, { 128,6956 }, + { 129,6956 }, { 130,6956 }, { 131,6956 }, { 132,6956 }, { 133,6956 }, + { 134,6956 }, { 135,6956 }, { 136,6956 }, { 137,6956 }, { 138,6956 }, + { 139,6956 }, { 140,6956 }, { 141,6956 }, { 142,6956 }, { 143,6956 }, + { 144,6956 }, { 145,6956 }, { 146,6956 }, { 147,6956 }, { 148,6956 }, + + { 149,6956 }, { 150,6956 }, { 151,6956 }, { 152,6956 }, { 153,6956 }, + { 154,6956 }, { 155,6956 }, { 156,6956 }, { 157,6956 }, { 158,6956 }, + { 159,6956 }, { 160,6956 }, { 161,6956 }, { 162,6956 }, { 163,6956 }, + { 164,6956 }, { 165,6956 }, { 166,6956 }, { 167,6956 }, { 168,6956 }, + { 169,6956 }, { 170,6956 }, { 171,6956 }, { 172,6956 }, { 173,6956 }, + { 174,6956 }, { 175,6956 }, { 176,6956 }, { 177,6956 }, { 178,6956 }, + { 179,6956 }, { 180,6956 }, { 181,6956 }, { 182,6956 }, { 183,6956 }, + { 184,6956 }, { 185,6956 }, { 186,6956 }, { 187,6956 }, { 188,6956 }, + { 189,6956 }, { 190,6956 }, { 191,6956 }, { 192,6956 }, { 193,6956 }, + { 194,6956 }, { 195,6956 }, { 196,6956 }, { 197,6956 }, { 198,6956 }, + + { 199,6956 }, { 200,6956 }, { 201,6956 }, { 202,6956 }, { 203,6956 }, + { 204,6956 }, { 205,6956 }, { 206,6956 }, { 207,6956 }, { 208,6956 }, + { 209,6956 }, { 210,6956 }, { 211,6956 }, { 212,6956 }, { 213,6956 }, + { 214,6956 }, { 215,6956 }, { 216,6956 }, { 217,6956 }, { 218,6956 }, + { 219,6956 }, { 220,6956 }, { 221,6956 }, { 222,6956 }, { 223,6956 }, + { 224,6956 }, { 225,6956 }, { 226,6956 }, { 227,6956 }, { 228,6956 }, + { 229,6956 }, { 230,6956 }, { 231,6956 }, { 232,6956 }, { 233,6956 }, + { 234,6956 }, { 235,6956 }, { 236,6956 }, { 237,6956 }, { 238,6956 }, + { 239,6956 }, { 240,6956 }, { 241,6956 }, { 242,6956 }, { 243,6956 }, + { 244,6956 }, { 245,6956 }, { 246,6956 }, { 247,6956 }, { 248,6956 }, + + { 249,6956 }, { 250,6956 }, { 251,6956 }, { 252,6956 }, { 253,6956 }, + { 254,6956 }, { 255,6956 }, { 256,6956 }, { 0, 0 }, { 0,62471 }, + { 1,6698 }, { 2,6698 }, { 3,6698 }, { 4,6698 }, { 5,6698 }, + { 6,6698 }, { 7,6698 }, { 8,6698 }, { 9,6698 }, { 10,6698 }, + { 11,6698 }, { 12,6698 }, { 13,6698 }, { 14,6698 }, { 15,6698 }, + { 16,6698 }, { 17,6698 }, { 18,6698 }, { 19,6698 }, { 20,6698 }, + { 21,6698 }, { 22,6698 }, { 23,6698 }, { 24,6698 }, { 25,6698 }, + { 26,6698 }, { 27,6698 }, { 28,6698 }, { 29,6698 }, { 30,6698 }, + { 31,6698 }, { 32,6698 }, { 33,6698 }, { 34,3919 }, { 35,6698 }, + { 36,6698 }, { 37,6698 }, { 38,6698 }, { 39,6698 }, { 40,6698 }, + + { 41,6698 }, { 42,6698 }, { 43,6698 }, { 44,6698 }, { 45,6698 }, + { 46,6698 }, { 47,6698 }, { 48,6698 }, { 49,6698 }, { 50,6698 }, + { 51,6698 }, { 52,6698 }, { 53,6698 }, { 54,6698 }, { 55,6698 }, + { 56,6698 }, { 57,6698 }, { 58,6698 }, { 59,6698 }, { 60,6698 }, + { 61,6698 }, { 62,6698 }, { 63,6698 }, { 64,6698 }, { 65,6698 }, + { 66,6698 }, { 67,6698 }, { 68,6698 }, { 69,6698 }, { 70,6698 }, + { 71,6698 }, { 72,6698 }, { 73,6698 }, { 74,6698 }, { 75,6698 }, + { 76,6698 }, { 77,6698 }, { 78,6698 }, { 79,6698 }, { 80,6698 }, + { 81,6698 }, { 82,6698 }, { 83,6698 }, { 84,6698 }, { 85,6698 }, + { 86,6698 }, { 87,6698 }, { 88,6698 }, { 89,6698 }, { 90,6698 }, + + { 91,6698 }, { 92,6698 }, { 93,6698 }, { 94,6698 }, { 95,6698 }, + { 96,6698 }, { 97,6698 }, { 98,6698 }, { 99,6698 }, { 100,6698 }, + { 101,6698 }, { 102,6698 }, { 103,6698 }, { 104,6698 }, { 105,6698 }, + { 106,6698 }, { 107,6698 }, { 108,6698 }, { 109,6698 }, { 110,6698 }, + { 111,6698 }, { 112,6698 }, { 113,6698 }, { 114,6698 }, { 115,6698 }, + { 116,6698 }, { 117,6698 }, { 118,6698 }, { 119,6698 }, { 120,6698 }, + { 121,6698 }, { 122,6698 }, { 123,6698 }, { 124,6698 }, { 125,6698 }, + { 126,6698 }, { 127,6698 }, { 128,6698 }, { 129,6698 }, { 130,6698 }, + { 131,6698 }, { 132,6698 }, { 133,6698 }, { 134,6698 }, { 135,6698 }, + { 136,6698 }, { 137,6698 }, { 138,6698 }, { 139,6698 }, { 140,6698 }, + + { 141,6698 }, { 142,6698 }, { 143,6698 }, { 144,6698 }, { 145,6698 }, + { 146,6698 }, { 147,6698 }, { 148,6698 }, { 149,6698 }, { 150,6698 }, + { 151,6698 }, { 152,6698 }, { 153,6698 }, { 154,6698 }, { 155,6698 }, + { 156,6698 }, { 157,6698 }, { 158,6698 }, { 159,6698 }, { 160,6698 }, + { 161,6698 }, { 162,6698 }, { 163,6698 }, { 164,6698 }, { 165,6698 }, + { 166,6698 }, { 167,6698 }, { 168,6698 }, { 169,6698 }, { 170,6698 }, + { 171,6698 }, { 172,6698 }, { 173,6698 }, { 174,6698 }, { 175,6698 }, + { 176,6698 }, { 177,6698 }, { 178,6698 }, { 179,6698 }, { 180,6698 }, + { 181,6698 }, { 182,6698 }, { 183,6698 }, { 184,6698 }, { 185,6698 }, + { 186,6698 }, { 187,6698 }, { 188,6698 }, { 189,6698 }, { 190,6698 }, + + { 191,6698 }, { 192,6698 }, { 193,6698 }, { 194,6698 }, { 195,6698 }, + { 196,6698 }, { 197,6698 }, { 198,6698 }, { 199,6698 }, { 200,6698 }, + { 201,6698 }, { 202,6698 }, { 203,6698 }, { 204,6698 }, { 205,6698 }, + { 206,6698 }, { 207,6698 }, { 208,6698 }, { 209,6698 }, { 210,6698 }, + { 211,6698 }, { 212,6698 }, { 213,6698 }, { 214,6698 }, { 215,6698 }, + { 216,6698 }, { 217,6698 }, { 218,6698 }, { 219,6698 }, { 220,6698 }, + { 221,6698 }, { 222,6698 }, { 223,6698 }, { 224,6698 }, { 225,6698 }, + { 226,6698 }, { 227,6698 }, { 228,6698 }, { 229,6698 }, { 230,6698 }, + { 231,6698 }, { 232,6698 }, { 233,6698 }, { 234,6698 }, { 235,6698 }, + { 236,6698 }, { 237,6698 }, { 238,6698 }, { 239,6698 }, { 240,6698 }, + + { 241,6698 }, { 242,6698 }, { 243,6698 }, { 244,6698 }, { 245,6698 }, + { 246,6698 }, { 247,6698 }, { 248,6698 }, { 249,6698 }, { 250,6698 }, + { 251,6698 }, { 252,6698 }, { 253,6698 }, { 254,6698 }, { 255,6698 }, + { 256,6698 }, { 0, 11 }, { 0,62213 }, { 1,6698 }, { 2,6698 }, + { 3,6698 }, { 4,6698 }, { 5,6698 }, { 6,6698 }, { 7,6698 }, + { 8,6698 }, { 9,6698 }, { 10,6698 }, { 11,6698 }, { 12,6698 }, + { 13,6698 }, { 14,6698 }, { 15,6698 }, { 16,6698 }, { 17,6698 }, + { 18,6698 }, { 19,6698 }, { 20,6698 }, { 21,6698 }, { 22,6698 }, + { 23,6698 }, { 24,6698 }, { 25,6698 }, { 26,6698 }, { 27,6698 }, + { 28,6698 }, { 29,6698 }, { 30,6698 }, { 31,6698 }, { 32,6698 }, + + { 33,6698 }, { 34,6698 }, { 35,6698 }, { 36,6698 }, { 37,6698 }, + { 38,6698 }, { 39,6956 }, { 40,6698 }, { 41,6698 }, { 42,6698 }, + { 43,6698 }, { 44,6698 }, { 45,6698 }, { 46,6698 }, { 47,6698 }, + { 48,6698 }, { 49,6698 }, { 50,6698 }, { 51,6698 }, { 52,6698 }, + { 53,6698 }, { 54,6698 }, { 55,6698 }, { 56,6698 }, { 57,6698 }, + { 58,6698 }, { 59,6698 }, { 60,6698 }, { 61,6698 }, { 62,6698 }, + { 63,6698 }, { 64,6698 }, { 65,6698 }, { 66,6698 }, { 67,6698 }, + { 68,6698 }, { 69,6698 }, { 70,6698 }, { 71,6698 }, { 72,6698 }, + { 73,6698 }, { 74,6698 }, { 75,6698 }, { 76,6698 }, { 77,6698 }, + { 78,6698 }, { 79,6698 }, { 80,6698 }, { 81,6698 }, { 82,6698 }, + + { 83,6698 }, { 84,6698 }, { 85,6698 }, { 86,6698 }, { 87,6698 }, + { 88,6698 }, { 89,6698 }, { 90,6698 }, { 91,6698 }, { 92,6698 }, + { 93,6698 }, { 94,6698 }, { 95,6698 }, { 96,6698 }, { 97,6698 }, + { 98,6698 }, { 99,6698 }, { 100,6698 }, { 101,6698 }, { 102,6698 }, + { 103,6698 }, { 104,6698 }, { 105,6698 }, { 106,6698 }, { 107,6698 }, + { 108,6698 }, { 109,6698 }, { 110,6698 }, { 111,6698 }, { 112,6698 }, + { 113,6698 }, { 114,6698 }, { 115,6698 }, { 116,6698 }, { 117,6698 }, + { 118,6698 }, { 119,6698 }, { 120,6698 }, { 121,6698 }, { 122,6698 }, + { 123,6698 }, { 124,6698 }, { 125,6698 }, { 126,6698 }, { 127,6698 }, + { 128,6698 }, { 129,6698 }, { 130,6698 }, { 131,6698 }, { 132,6698 }, + + { 133,6698 }, { 134,6698 }, { 135,6698 }, { 136,6698 }, { 137,6698 }, + { 138,6698 }, { 139,6698 }, { 140,6698 }, { 141,6698 }, { 142,6698 }, + { 143,6698 }, { 144,6698 }, { 145,6698 }, { 146,6698 }, { 147,6698 }, + { 148,6698 }, { 149,6698 }, { 150,6698 }, { 151,6698 }, { 152,6698 }, + { 153,6698 }, { 154,6698 }, { 155,6698 }, { 156,6698 }, { 157,6698 }, + { 158,6698 }, { 159,6698 }, { 160,6698 }, { 161,6698 }, { 162,6698 }, + { 163,6698 }, { 164,6698 }, { 165,6698 }, { 166,6698 }, { 167,6698 }, + { 168,6698 }, { 169,6698 }, { 170,6698 }, { 171,6698 }, { 172,6698 }, + { 173,6698 }, { 174,6698 }, { 175,6698 }, { 176,6698 }, { 177,6698 }, + { 178,6698 }, { 179,6698 }, { 180,6698 }, { 181,6698 }, { 182,6698 }, + + { 183,6698 }, { 184,6698 }, { 185,6698 }, { 186,6698 }, { 187,6698 }, + { 188,6698 }, { 189,6698 }, { 190,6698 }, { 191,6698 }, { 192,6698 }, + { 193,6698 }, { 194,6698 }, { 195,6698 }, { 196,6698 }, { 197,6698 }, + { 198,6698 }, { 199,6698 }, { 200,6698 }, { 201,6698 }, { 202,6698 }, + { 203,6698 }, { 204,6698 }, { 205,6698 }, { 206,6698 }, { 207,6698 }, + { 208,6698 }, { 209,6698 }, { 210,6698 }, { 211,6698 }, { 212,6698 }, + { 213,6698 }, { 214,6698 }, { 215,6698 }, { 216,6698 }, { 217,6698 }, + { 218,6698 }, { 219,6698 }, { 220,6698 }, { 221,6698 }, { 222,6698 }, + { 223,6698 }, { 224,6698 }, { 225,6698 }, { 226,6698 }, { 227,6698 }, + { 228,6698 }, { 229,6698 }, { 230,6698 }, { 231,6698 }, { 232,6698 }, + + { 233,6698 }, { 234,6698 }, { 235,6698 }, { 236,6698 }, { 237,6698 }, + { 238,6698 }, { 239,6698 }, { 240,6698 }, { 241,6698 }, { 242,6698 }, + { 243,6698 }, { 244,6698 }, { 245,6698 }, { 246,6698 }, { 247,6698 }, + { 248,6698 }, { 249,6698 }, { 250,6698 }, { 251,6698 }, { 252,6698 }, + { 253,6698 }, { 254,6698 }, { 255,6698 }, { 256,6698 }, { 0, 11 }, + { 0,61955 }, { 1,6440 }, { 2,6440 }, { 3,6440 }, { 4,6440 }, + { 5,6440 }, { 6,6440 }, { 7,6440 }, { 8,6440 }, { 9,6440 }, + { 10,6440 }, { 11,6440 }, { 12,6440 }, { 13,6440 }, { 14,6440 }, + { 15,6440 }, { 16,6440 }, { 17,6440 }, { 18,6440 }, { 19,6440 }, + { 20,6440 }, { 21,6440 }, { 22,6440 }, { 23,6440 }, { 24,6440 }, + + { 25,6440 }, { 26,6440 }, { 27,6440 }, { 28,6440 }, { 29,6440 }, + { 30,6440 }, { 31,6440 }, { 32,6440 }, { 33,6440 }, { 34,6440 }, + { 35,6440 }, { 36,6440 }, { 37,6440 }, { 38,6440 }, { 39,6698 }, + { 40,6440 }, { 41,6440 }, { 42,6440 }, { 43,6440 }, { 44,6440 }, + { 45,6440 }, { 46,6440 }, { 47,6440 }, { 48,6440 }, { 49,6440 }, + { 50,6440 }, { 51,6440 }, { 52,6440 }, { 53,6440 }, { 54,6440 }, + { 55,6440 }, { 56,6440 }, { 57,6440 }, { 58,6440 }, { 59,6440 }, + { 60,6440 }, { 61,6440 }, { 62,6440 }, { 63,6440 }, { 64,6440 }, + { 65,6440 }, { 66,6440 }, { 67,6440 }, { 68,6440 }, { 69,6440 }, + { 70,6440 }, { 71,6440 }, { 72,6440 }, { 73,6440 }, { 74,6440 }, + + { 75,6440 }, { 76,6440 }, { 77,6440 }, { 78,6440 }, { 79,6440 }, + { 80,6440 }, { 81,6440 }, { 82,6440 }, { 83,6440 }, { 84,6440 }, + { 85,6440 }, { 86,6440 }, { 87,6440 }, { 88,6440 }, { 89,6440 }, + { 90,6440 }, { 91,6440 }, { 92,6440 }, { 93,6440 }, { 94,6440 }, + { 95,6440 }, { 96,6440 }, { 97,6440 }, { 98,6440 }, { 99,6440 }, + { 100,6440 }, { 101,6440 }, { 102,6440 }, { 103,6440 }, { 104,6440 }, + { 105,6440 }, { 106,6440 }, { 107,6440 }, { 108,6440 }, { 109,6440 }, + { 110,6440 }, { 111,6440 }, { 112,6440 }, { 113,6440 }, { 114,6440 }, + { 115,6440 }, { 116,6440 }, { 117,6440 }, { 118,6440 }, { 119,6440 }, + { 120,6440 }, { 121,6440 }, { 122,6440 }, { 123,6440 }, { 124,6440 }, + + { 125,6440 }, { 126,6440 }, { 127,6440 }, { 128,6440 }, { 129,6440 }, + { 130,6440 }, { 131,6440 }, { 132,6440 }, { 133,6440 }, { 134,6440 }, + { 135,6440 }, { 136,6440 }, { 137,6440 }, { 138,6440 }, { 139,6440 }, + { 140,6440 }, { 141,6440 }, { 142,6440 }, { 143,6440 }, { 144,6440 }, + { 145,6440 }, { 146,6440 }, { 147,6440 }, { 148,6440 }, { 149,6440 }, + { 150,6440 }, { 151,6440 }, { 152,6440 }, { 153,6440 }, { 154,6440 }, + { 155,6440 }, { 156,6440 }, { 157,6440 }, { 158,6440 }, { 159,6440 }, + { 160,6440 }, { 161,6440 }, { 162,6440 }, { 163,6440 }, { 164,6440 }, + { 165,6440 }, { 166,6440 }, { 167,6440 }, { 168,6440 }, { 169,6440 }, + { 170,6440 }, { 171,6440 }, { 172,6440 }, { 173,6440 }, { 174,6440 }, + + { 175,6440 }, { 176,6440 }, { 177,6440 }, { 178,6440 }, { 179,6440 }, + { 180,6440 }, { 181,6440 }, { 182,6440 }, { 183,6440 }, { 184,6440 }, + { 185,6440 }, { 186,6440 }, { 187,6440 }, { 188,6440 }, { 189,6440 }, + { 190,6440 }, { 191,6440 }, { 192,6440 }, { 193,6440 }, { 194,6440 }, + { 195,6440 }, { 196,6440 }, { 197,6440 }, { 198,6440 }, { 199,6440 }, + { 200,6440 }, { 201,6440 }, { 202,6440 }, { 203,6440 }, { 204,6440 }, + { 205,6440 }, { 206,6440 }, { 207,6440 }, { 208,6440 }, { 209,6440 }, + { 210,6440 }, { 211,6440 }, { 212,6440 }, { 213,6440 }, { 214,6440 }, + { 215,6440 }, { 216,6440 }, { 217,6440 }, { 218,6440 }, { 219,6440 }, + { 220,6440 }, { 221,6440 }, { 222,6440 }, { 223,6440 }, { 224,6440 }, + + { 225,6440 }, { 226,6440 }, { 227,6440 }, { 228,6440 }, { 229,6440 }, + { 230,6440 }, { 231,6440 }, { 232,6440 }, { 233,6440 }, { 234,6440 }, + { 235,6440 }, { 236,6440 }, { 237,6440 }, { 238,6440 }, { 239,6440 }, + { 240,6440 }, { 241,6440 }, { 242,6440 }, { 243,6440 }, { 244,6440 }, + { 245,6440 }, { 246,6440 }, { 247,6440 }, { 248,6440 }, { 249,6440 }, + { 250,6440 }, { 251,6440 }, { 252,6440 }, { 253,6440 }, { 254,6440 }, + { 255,6440 }, { 256,6440 }, { 0, 0 }, { 0,61697 }, { 1,6487 }, + { 2,6487 }, { 3,6487 }, { 4,6487 }, { 5,6487 }, { 6,6487 }, + { 7,6487 }, { 8,6487 }, { 9,6487 }, { 10,6745 }, { 11,6487 }, + { 12,6487 }, { 13,6487 }, { 14,6487 }, { 15,6487 }, { 16,6487 }, + + { 17,6487 }, { 18,6487 }, { 19,6487 }, { 20,6487 }, { 21,6487 }, + { 22,6487 }, { 23,6487 }, { 24,6487 }, { 25,6487 }, { 26,6487 }, + { 27,6487 }, { 28,6487 }, { 29,6487 }, { 30,6487 }, { 31,6487 }, + { 32,6487 }, { 33,6487 }, { 34,6487 }, { 35,6487 }, { 36,6487 }, + { 37,6487 }, { 38,6487 }, { 39,7003 }, { 40,6487 }, { 41,6487 }, + { 42,6487 }, { 43,6487 }, { 44,6487 }, { 45,6487 }, { 46,6487 }, + { 47,6487 }, { 48,6487 }, { 49,6487 }, { 50,6487 }, { 51,6487 }, + { 52,6487 }, { 53,6487 }, { 54,6487 }, { 55,6487 }, { 56,6487 }, + { 57,6487 }, { 58,6487 }, { 59,6487 }, { 60,6487 }, { 61,6487 }, + { 62,6487 }, { 63,6487 }, { 64,6487 }, { 65,6487 }, { 66,6487 }, + + { 67,6487 }, { 68,6487 }, { 69,6487 }, { 70,6487 }, { 71,6487 }, + { 72,6487 }, { 73,6487 }, { 74,6487 }, { 75,6487 }, { 76,6487 }, + { 77,6487 }, { 78,6487 }, { 79,6487 }, { 80,6487 }, { 81,6487 }, + { 82,6487 }, { 83,6487 }, { 84,6487 }, { 85,6487 }, { 86,6487 }, + { 87,6487 }, { 88,6487 }, { 89,6487 }, { 90,6487 }, { 91,6487 }, + { 92,7050 }, { 93,6487 }, { 94,6487 }, { 95,6487 }, { 96,6487 }, + { 97,6487 }, { 98,6487 }, { 99,6487 }, { 100,6487 }, { 101,6487 }, + { 102,6487 }, { 103,6487 }, { 104,6487 }, { 105,6487 }, { 106,6487 }, + { 107,6487 }, { 108,6487 }, { 109,6487 }, { 110,6487 }, { 111,6487 }, + { 112,6487 }, { 113,6487 }, { 114,6487 }, { 115,6487 }, { 116,6487 }, + + { 117,6487 }, { 118,6487 }, { 119,6487 }, { 120,6487 }, { 121,6487 }, + { 122,6487 }, { 123,6487 }, { 124,6487 }, { 125,6487 }, { 126,6487 }, + { 127,6487 }, { 128,6487 }, { 129,6487 }, { 130,6487 }, { 131,6487 }, + { 132,6487 }, { 133,6487 }, { 134,6487 }, { 135,6487 }, { 136,6487 }, + { 137,6487 }, { 138,6487 }, { 139,6487 }, { 140,6487 }, { 141,6487 }, + { 142,6487 }, { 143,6487 }, { 144,6487 }, { 145,6487 }, { 146,6487 }, + { 147,6487 }, { 148,6487 }, { 149,6487 }, { 150,6487 }, { 151,6487 }, + { 152,6487 }, { 153,6487 }, { 154,6487 }, { 155,6487 }, { 156,6487 }, + { 157,6487 }, { 158,6487 }, { 159,6487 }, { 160,6487 }, { 161,6487 }, + { 162,6487 }, { 163,6487 }, { 164,6487 }, { 165,6487 }, { 166,6487 }, + + { 167,6487 }, { 168,6487 }, { 169,6487 }, { 170,6487 }, { 171,6487 }, + { 172,6487 }, { 173,6487 }, { 174,6487 }, { 175,6487 }, { 176,6487 }, + { 177,6487 }, { 178,6487 }, { 179,6487 }, { 180,6487 }, { 181,6487 }, + { 182,6487 }, { 183,6487 }, { 184,6487 }, { 185,6487 }, { 186,6487 }, + { 187,6487 }, { 188,6487 }, { 189,6487 }, { 190,6487 }, { 191,6487 }, + { 192,6487 }, { 193,6487 }, { 194,6487 }, { 195,6487 }, { 196,6487 }, + { 197,6487 }, { 198,6487 }, { 199,6487 }, { 200,6487 }, { 201,6487 }, + { 202,6487 }, { 203,6487 }, { 204,6487 }, { 205,6487 }, { 206,6487 }, + { 207,6487 }, { 208,6487 }, { 209,6487 }, { 210,6487 }, { 211,6487 }, + { 212,6487 }, { 213,6487 }, { 214,6487 }, { 215,6487 }, { 216,6487 }, + + { 217,6487 }, { 218,6487 }, { 219,6487 }, { 220,6487 }, { 221,6487 }, + { 222,6487 }, { 223,6487 }, { 224,6487 }, { 225,6487 }, { 226,6487 }, + { 227,6487 }, { 228,6487 }, { 229,6487 }, { 230,6487 }, { 231,6487 }, + { 232,6487 }, { 233,6487 }, { 234,6487 }, { 235,6487 }, { 236,6487 }, + { 237,6487 }, { 238,6487 }, { 239,6487 }, { 240,6487 }, { 241,6487 }, + { 242,6487 }, { 243,6487 }, { 244,6487 }, { 245,6487 }, { 246,6487 }, + { 247,6487 }, { 248,6487 }, { 249,6487 }, { 250,6487 }, { 251,6487 }, + { 252,6487 }, { 253,6487 }, { 254,6487 }, { 255,6487 }, { 256,6487 }, + { 0, 0 }, { 0,61439 }, { 1,6229 }, { 2,6229 }, { 3,6229 }, + { 4,6229 }, { 5,6229 }, { 6,6229 }, { 7,6229 }, { 8,6229 }, + + { 9,6229 }, { 10,6487 }, { 11,6229 }, { 12,6229 }, { 13,6229 }, + { 14,6229 }, { 15,6229 }, { 16,6229 }, { 17,6229 }, { 18,6229 }, + { 19,6229 }, { 20,6229 }, { 21,6229 }, { 22,6229 }, { 23,6229 }, + { 24,6229 }, { 25,6229 }, { 26,6229 }, { 27,6229 }, { 28,6229 }, + { 29,6229 }, { 30,6229 }, { 31,6229 }, { 32,6229 }, { 33,6229 }, + { 34,6229 }, { 35,6229 }, { 36,6229 }, { 37,6229 }, { 38,6229 }, + { 39,6745 }, { 40,6229 }, { 41,6229 }, { 42,6229 }, { 43,6229 }, + { 44,6229 }, { 45,6229 }, { 46,6229 }, { 47,6229 }, { 48,6229 }, + { 49,6229 }, { 50,6229 }, { 51,6229 }, { 52,6229 }, { 53,6229 }, + { 54,6229 }, { 55,6229 }, { 56,6229 }, { 57,6229 }, { 58,6229 }, + + { 59,6229 }, { 60,6229 }, { 61,6229 }, { 62,6229 }, { 63,6229 }, + { 64,6229 }, { 65,6229 }, { 66,6229 }, { 67,6229 }, { 68,6229 }, + { 69,6229 }, { 70,6229 }, { 71,6229 }, { 72,6229 }, { 73,6229 }, + { 74,6229 }, { 75,6229 }, { 76,6229 }, { 77,6229 }, { 78,6229 }, + { 79,6229 }, { 80,6229 }, { 81,6229 }, { 82,6229 }, { 83,6229 }, + { 84,6229 }, { 85,6229 }, { 86,6229 }, { 87,6229 }, { 88,6229 }, + { 89,6229 }, { 90,6229 }, { 91,6229 }, { 92,6792 }, { 93,6229 }, + { 94,6229 }, { 95,6229 }, { 96,6229 }, { 97,6229 }, { 98,6229 }, + { 99,6229 }, { 100,6229 }, { 101,6229 }, { 102,6229 }, { 103,6229 }, + { 104,6229 }, { 105,6229 }, { 106,6229 }, { 107,6229 }, { 108,6229 }, + + { 109,6229 }, { 110,6229 }, { 111,6229 }, { 112,6229 }, { 113,6229 }, + { 114,6229 }, { 115,6229 }, { 116,6229 }, { 117,6229 }, { 118,6229 }, + { 119,6229 }, { 120,6229 }, { 121,6229 }, { 122,6229 }, { 123,6229 }, + { 124,6229 }, { 125,6229 }, { 126,6229 }, { 127,6229 }, { 128,6229 }, + { 129,6229 }, { 130,6229 }, { 131,6229 }, { 132,6229 }, { 133,6229 }, + { 134,6229 }, { 135,6229 }, { 136,6229 }, { 137,6229 }, { 138,6229 }, + { 139,6229 }, { 140,6229 }, { 141,6229 }, { 142,6229 }, { 143,6229 }, + { 144,6229 }, { 145,6229 }, { 146,6229 }, { 147,6229 }, { 148,6229 }, + { 149,6229 }, { 150,6229 }, { 151,6229 }, { 152,6229 }, { 153,6229 }, + { 154,6229 }, { 155,6229 }, { 156,6229 }, { 157,6229 }, { 158,6229 }, + + { 159,6229 }, { 160,6229 }, { 161,6229 }, { 162,6229 }, { 163,6229 }, + { 164,6229 }, { 165,6229 }, { 166,6229 }, { 167,6229 }, { 168,6229 }, + { 169,6229 }, { 170,6229 }, { 171,6229 }, { 172,6229 }, { 173,6229 }, + { 174,6229 }, { 175,6229 }, { 176,6229 }, { 177,6229 }, { 178,6229 }, + { 179,6229 }, { 180,6229 }, { 181,6229 }, { 182,6229 }, { 183,6229 }, + { 184,6229 }, { 185,6229 }, { 186,6229 }, { 187,6229 }, { 188,6229 }, + { 189,6229 }, { 190,6229 }, { 191,6229 }, { 192,6229 }, { 193,6229 }, + { 194,6229 }, { 195,6229 }, { 196,6229 }, { 197,6229 }, { 198,6229 }, + { 199,6229 }, { 200,6229 }, { 201,6229 }, { 202,6229 }, { 203,6229 }, + { 204,6229 }, { 205,6229 }, { 206,6229 }, { 207,6229 }, { 208,6229 }, + + { 209,6229 }, { 210,6229 }, { 211,6229 }, { 212,6229 }, { 213,6229 }, + { 214,6229 }, { 215,6229 }, { 216,6229 }, { 217,6229 }, { 218,6229 }, + { 219,6229 }, { 220,6229 }, { 221,6229 }, { 222,6229 }, { 223,6229 }, + { 224,6229 }, { 225,6229 }, { 226,6229 }, { 227,6229 }, { 228,6229 }, + { 229,6229 }, { 230,6229 }, { 231,6229 }, { 232,6229 }, { 233,6229 }, + { 234,6229 }, { 235,6229 }, { 236,6229 }, { 237,6229 }, { 238,6229 }, + { 239,6229 }, { 240,6229 }, { 241,6229 }, { 242,6229 }, { 243,6229 }, + { 244,6229 }, { 245,6229 }, { 246,6229 }, { 247,6229 }, { 248,6229 }, + { 249,6229 }, { 250,6229 }, { 251,6229 }, { 252,6229 }, { 253,6229 }, + { 254,6229 }, { 255,6229 }, { 256,6229 }, { 0, 0 }, { 0,61181 }, + + { 1,6792 }, { 2,6792 }, { 3,6792 }, { 4,6792 }, { 5,6792 }, + { 6,6792 }, { 7,6792 }, { 8,6792 }, { 9,6792 }, { 10,6792 }, + { 11,6792 }, { 12,6792 }, { 13,6792 }, { 14,6792 }, { 15,6792 }, + { 16,6792 }, { 17,6792 }, { 18,6792 }, { 19,6792 }, { 20,6792 }, + { 21,6792 }, { 22,6792 }, { 23,6792 }, { 24,6792 }, { 25,6792 }, + { 26,6792 }, { 27,6792 }, { 28,6792 }, { 29,6792 }, { 30,6792 }, + { 31,6792 }, { 32,6792 }, { 33,6792 }, { 34,6792 }, { 35,6792 }, + { 36,6792 }, { 37,6792 }, { 38,6792 }, { 39,7050 }, { 40,6792 }, + { 41,6792 }, { 42,6792 }, { 43,6792 }, { 44,6792 }, { 45,6792 }, + { 46,6792 }, { 47,6792 }, { 48,6792 }, { 49,6792 }, { 50,6792 }, + + { 51,6792 }, { 52,6792 }, { 53,6792 }, { 54,6792 }, { 55,6792 }, + { 56,6792 }, { 57,6792 }, { 58,6792 }, { 59,6792 }, { 60,6792 }, + { 61,6792 }, { 62,6792 }, { 63,6792 }, { 64,6792 }, { 65,6792 }, + { 66,6792 }, { 67,6792 }, { 68,6792 }, { 69,6792 }, { 70,6792 }, + { 71,6792 }, { 72,6792 }, { 73,6792 }, { 74,6792 }, { 75,6792 }, + { 76,6792 }, { 77,6792 }, { 78,6792 }, { 79,6792 }, { 80,6792 }, + { 81,6792 }, { 82,6792 }, { 83,6792 }, { 84,6792 }, { 85,6792 }, + { 86,6792 }, { 87,6792 }, { 88,6792 }, { 89,6792 }, { 90,6792 }, + { 91,6792 }, { 92,6792 }, { 93,6792 }, { 94,6792 }, { 95,6792 }, + { 96,6792 }, { 97,6792 }, { 98,6792 }, { 99,6792 }, { 100,6792 }, + + { 101,6792 }, { 102,6792 }, { 103,6792 }, { 104,6792 }, { 105,6792 }, + { 106,6792 }, { 107,6792 }, { 108,6792 }, { 109,6792 }, { 110,6792 }, + { 111,6792 }, { 112,6792 }, { 113,6792 }, { 114,6792 }, { 115,6792 }, + { 116,6792 }, { 117,6792 }, { 118,6792 }, { 119,6792 }, { 120,6792 }, + { 121,6792 }, { 122,6792 }, { 123,6792 }, { 124,6792 }, { 125,6792 }, + { 126,6792 }, { 127,6792 }, { 128,6792 }, { 129,6792 }, { 130,6792 }, + { 131,6792 }, { 132,6792 }, { 133,6792 }, { 134,6792 }, { 135,6792 }, + { 136,6792 }, { 137,6792 }, { 138,6792 }, { 139,6792 }, { 140,6792 }, + { 141,6792 }, { 142,6792 }, { 143,6792 }, { 144,6792 }, { 145,6792 }, + { 146,6792 }, { 147,6792 }, { 148,6792 }, { 149,6792 }, { 150,6792 }, + + { 151,6792 }, { 152,6792 }, { 153,6792 }, { 154,6792 }, { 155,6792 }, + { 156,6792 }, { 157,6792 }, { 158,6792 }, { 159,6792 }, { 160,6792 }, + { 161,6792 }, { 162,6792 }, { 163,6792 }, { 164,6792 }, { 165,6792 }, + { 166,6792 }, { 167,6792 }, { 168,6792 }, { 169,6792 }, { 170,6792 }, + { 171,6792 }, { 172,6792 }, { 173,6792 }, { 174,6792 }, { 175,6792 }, + { 176,6792 }, { 177,6792 }, { 178,6792 }, { 179,6792 }, { 180,6792 }, + { 181,6792 }, { 182,6792 }, { 183,6792 }, { 184,6792 }, { 185,6792 }, + { 186,6792 }, { 187,6792 }, { 188,6792 }, { 189,6792 }, { 190,6792 }, + { 191,6792 }, { 192,6792 }, { 193,6792 }, { 194,6792 }, { 195,6792 }, + { 196,6792 }, { 197,6792 }, { 198,6792 }, { 199,6792 }, { 200,6792 }, + + { 201,6792 }, { 202,6792 }, { 203,6792 }, { 204,6792 }, { 205,6792 }, + { 206,6792 }, { 207,6792 }, { 208,6792 }, { 209,6792 }, { 210,6792 }, + { 211,6792 }, { 212,6792 }, { 213,6792 }, { 214,6792 }, { 215,6792 }, + { 216,6792 }, { 217,6792 }, { 218,6792 }, { 219,6792 }, { 220,6792 }, + { 221,6792 }, { 222,6792 }, { 223,6792 }, { 224,6792 }, { 225,6792 }, + { 226,6792 }, { 227,6792 }, { 228,6792 }, { 229,6792 }, { 230,6792 }, + { 231,6792 }, { 232,6792 }, { 233,6792 }, { 234,6792 }, { 235,6792 }, + { 236,6792 }, { 237,6792 }, { 238,6792 }, { 239,6792 }, { 240,6792 }, + { 241,6792 }, { 242,6792 }, { 243,6792 }, { 244,6792 }, { 245,6792 }, + { 246,6792 }, { 247,6792 }, { 248,6792 }, { 249,6792 }, { 250,6792 }, + + { 251,6792 }, { 252,6792 }, { 253,6792 }, { 254,6792 }, { 255,6792 }, + { 256,6792 }, { 0, 0 }, { 0,60923 }, { 1,6534 }, { 2,6534 }, + { 3,6534 }, { 4,6534 }, { 5,6534 }, { 6,6534 }, { 7,6534 }, + { 8,6534 }, { 9,6534 }, { 10,6534 }, { 11,6534 }, { 12,6534 }, + { 13,6534 }, { 14,6534 }, { 15,6534 }, { 16,6534 }, { 17,6534 }, + { 18,6534 }, { 19,6534 }, { 20,6534 }, { 21,6534 }, { 22,6534 }, + { 23,6534 }, { 24,6534 }, { 25,6534 }, { 26,6534 }, { 27,6534 }, + { 28,6534 }, { 29,6534 }, { 30,6534 }, { 31,6534 }, { 32,6534 }, + { 33,6534 }, { 34,6534 }, { 35,6534 }, { 36,6534 }, { 37,6534 }, + { 38,6534 }, { 39,6792 }, { 40,6534 }, { 41,6534 }, { 42,6534 }, + + { 43,6534 }, { 44,6534 }, { 45,6534 }, { 46,6534 }, { 47,6534 }, + { 48,6534 }, { 49,6534 }, { 50,6534 }, { 51,6534 }, { 52,6534 }, + { 53,6534 }, { 54,6534 }, { 55,6534 }, { 56,6534 }, { 57,6534 }, + { 58,6534 }, { 59,6534 }, { 60,6534 }, { 61,6534 }, { 62,6534 }, + { 63,6534 }, { 64,6534 }, { 65,6534 }, { 66,6534 }, { 67,6534 }, + { 68,6534 }, { 69,6534 }, { 70,6534 }, { 71,6534 }, { 72,6534 }, + { 73,6534 }, { 74,6534 }, { 75,6534 }, { 76,6534 }, { 77,6534 }, + { 78,6534 }, { 79,6534 }, { 80,6534 }, { 81,6534 }, { 82,6534 }, + { 83,6534 }, { 84,6534 }, { 85,6534 }, { 86,6534 }, { 87,6534 }, + { 88,6534 }, { 89,6534 }, { 90,6534 }, { 91,6534 }, { 92,6534 }, + + { 93,6534 }, { 94,6534 }, { 95,6534 }, { 96,6534 }, { 97,6534 }, + { 98,6534 }, { 99,6534 }, { 100,6534 }, { 101,6534 }, { 102,6534 }, + { 103,6534 }, { 104,6534 }, { 105,6534 }, { 106,6534 }, { 107,6534 }, + { 108,6534 }, { 109,6534 }, { 110,6534 }, { 111,6534 }, { 112,6534 }, + { 113,6534 }, { 114,6534 }, { 115,6534 }, { 116,6534 }, { 117,6534 }, + { 118,6534 }, { 119,6534 }, { 120,6534 }, { 121,6534 }, { 122,6534 }, + { 123,6534 }, { 124,6534 }, { 125,6534 }, { 126,6534 }, { 127,6534 }, + { 128,6534 }, { 129,6534 }, { 130,6534 }, { 131,6534 }, { 132,6534 }, + { 133,6534 }, { 134,6534 }, { 135,6534 }, { 136,6534 }, { 137,6534 }, + { 138,6534 }, { 139,6534 }, { 140,6534 }, { 141,6534 }, { 142,6534 }, + + { 143,6534 }, { 144,6534 }, { 145,6534 }, { 146,6534 }, { 147,6534 }, + { 148,6534 }, { 149,6534 }, { 150,6534 }, { 151,6534 }, { 152,6534 }, + { 153,6534 }, { 154,6534 }, { 155,6534 }, { 156,6534 }, { 157,6534 }, + { 158,6534 }, { 159,6534 }, { 160,6534 }, { 161,6534 }, { 162,6534 }, + { 163,6534 }, { 164,6534 }, { 165,6534 }, { 166,6534 }, { 167,6534 }, + { 168,6534 }, { 169,6534 }, { 170,6534 }, { 171,6534 }, { 172,6534 }, + { 173,6534 }, { 174,6534 }, { 175,6534 }, { 176,6534 }, { 177,6534 }, + { 178,6534 }, { 179,6534 }, { 180,6534 }, { 181,6534 }, { 182,6534 }, + { 183,6534 }, { 184,6534 }, { 185,6534 }, { 186,6534 }, { 187,6534 }, + { 188,6534 }, { 189,6534 }, { 190,6534 }, { 191,6534 }, { 192,6534 }, + + { 193,6534 }, { 194,6534 }, { 195,6534 }, { 196,6534 }, { 197,6534 }, + { 198,6534 }, { 199,6534 }, { 200,6534 }, { 201,6534 }, { 202,6534 }, + { 203,6534 }, { 204,6534 }, { 205,6534 }, { 206,6534 }, { 207,6534 }, + { 208,6534 }, { 209,6534 }, { 210,6534 }, { 211,6534 }, { 212,6534 }, + { 213,6534 }, { 214,6534 }, { 215,6534 }, { 216,6534 }, { 217,6534 }, + { 218,6534 }, { 219,6534 }, { 220,6534 }, { 221,6534 }, { 222,6534 }, + { 223,6534 }, { 224,6534 }, { 225,6534 }, { 226,6534 }, { 227,6534 }, + { 228,6534 }, { 229,6534 }, { 230,6534 }, { 231,6534 }, { 232,6534 }, + { 233,6534 }, { 234,6534 }, { 235,6534 }, { 236,6534 }, { 237,6534 }, + { 238,6534 }, { 239,6534 }, { 240,6534 }, { 241,6534 }, { 242,6534 }, + + { 243,6534 }, { 244,6534 }, { 245,6534 }, { 246,6534 }, { 247,6534 }, + { 248,6534 }, { 249,6534 }, { 250,6534 }, { 251,6534 }, { 252,6534 }, + { 253,6534 }, { 254,6534 }, { 255,6534 }, { 256,6534 }, { 0, 0 }, + { 0,60665 }, { 1,6581 }, { 2,6581 }, { 3,6581 }, { 4,6581 }, + { 5,6581 }, { 6,6581 }, { 7,6581 }, { 8,6581 }, { 9,6581 }, + { 10,6839 }, { 11,6581 }, { 12,6581 }, { 13,6581 }, { 14,6581 }, + { 15,6581 }, { 16,6581 }, { 17,6581 }, { 18,6581 }, { 19,6581 }, + { 20,6581 }, { 21,6581 }, { 22,6581 }, { 23,6581 }, { 24,6581 }, + { 25,6581 }, { 26,6581 }, { 27,6581 }, { 28,6581 }, { 29,6581 }, + { 30,6581 }, { 31,6581 }, { 32,6581 }, { 33,6581 }, { 34,6581 }, + + { 35,6581 }, { 36,7097 }, { 37,6581 }, { 38,6581 }, { 39,6581 }, + { 40,6581 }, { 41,6581 }, { 42,6581 }, { 43,6581 }, { 44,6581 }, + { 45,6581 }, { 46,6581 }, { 47,6581 }, { 48,6581 }, { 49,6581 }, + { 50,6581 }, { 51,6581 }, { 52,6581 }, { 53,6581 }, { 54,6581 }, + { 55,6581 }, { 56,6581 }, { 57,6581 }, { 58,6581 }, { 59,6581 }, + { 60,6581 }, { 61,6581 }, { 62,6581 }, { 63,6581 }, { 64,6581 }, + { 65,6581 }, { 66,6581 }, { 67,6581 }, { 68,6581 }, { 69,6581 }, + { 70,6581 }, { 71,6581 }, { 72,6581 }, { 73,6581 }, { 74,6581 }, + { 75,6581 }, { 76,6581 }, { 77,6581 }, { 78,6581 }, { 79,6581 }, + { 80,6581 }, { 81,6581 }, { 82,6581 }, { 83,6581 }, { 84,6581 }, + + { 85,6581 }, { 86,6581 }, { 87,6581 }, { 88,6581 }, { 89,6581 }, + { 90,6581 }, { 91,6581 }, { 92,6581 }, { 93,6581 }, { 94,6581 }, + { 95,6581 }, { 96,6581 }, { 97,6581 }, { 98,6581 }, { 99,6581 }, + { 100,6581 }, { 101,6581 }, { 102,6581 }, { 103,6581 }, { 104,6581 }, + { 105,6581 }, { 106,6581 }, { 107,6581 }, { 108,6581 }, { 109,6581 }, + { 110,6581 }, { 111,6581 }, { 112,6581 }, { 113,6581 }, { 114,6581 }, + { 115,6581 }, { 116,6581 }, { 117,6581 }, { 118,6581 }, { 119,6581 }, + { 120,6581 }, { 121,6581 }, { 122,6581 }, { 123,6581 }, { 124,6581 }, + { 125,6581 }, { 126,6581 }, { 127,6581 }, { 128,6581 }, { 129,6581 }, + { 130,6581 }, { 131,6581 }, { 132,6581 }, { 133,6581 }, { 134,6581 }, + + { 135,6581 }, { 136,6581 }, { 137,6581 }, { 138,6581 }, { 139,6581 }, + { 140,6581 }, { 141,6581 }, { 142,6581 }, { 143,6581 }, { 144,6581 }, + { 145,6581 }, { 146,6581 }, { 147,6581 }, { 148,6581 }, { 149,6581 }, + { 150,6581 }, { 151,6581 }, { 152,6581 }, { 153,6581 }, { 154,6581 }, + { 155,6581 }, { 156,6581 }, { 157,6581 }, { 158,6581 }, { 159,6581 }, + { 160,6581 }, { 161,6581 }, { 162,6581 }, { 163,6581 }, { 164,6581 }, + { 165,6581 }, { 166,6581 }, { 167,6581 }, { 168,6581 }, { 169,6581 }, + { 170,6581 }, { 171,6581 }, { 172,6581 }, { 173,6581 }, { 174,6581 }, + { 175,6581 }, { 176,6581 }, { 177,6581 }, { 178,6581 }, { 179,6581 }, + { 180,6581 }, { 181,6581 }, { 182,6581 }, { 183,6581 }, { 184,6581 }, + + { 185,6581 }, { 186,6581 }, { 187,6581 }, { 188,6581 }, { 189,6581 }, + { 190,6581 }, { 191,6581 }, { 192,6581 }, { 193,6581 }, { 194,6581 }, + { 195,6581 }, { 196,6581 }, { 197,6581 }, { 198,6581 }, { 199,6581 }, + { 200,6581 }, { 201,6581 }, { 202,6581 }, { 203,6581 }, { 204,6581 }, + { 205,6581 }, { 206,6581 }, { 207,6581 }, { 208,6581 }, { 209,6581 }, + { 210,6581 }, { 211,6581 }, { 212,6581 }, { 213,6581 }, { 214,6581 }, + { 215,6581 }, { 216,6581 }, { 217,6581 }, { 218,6581 }, { 219,6581 }, + { 220,6581 }, { 221,6581 }, { 222,6581 }, { 223,6581 }, { 224,6581 }, + { 225,6581 }, { 226,6581 }, { 227,6581 }, { 228,6581 }, { 229,6581 }, + { 230,6581 }, { 231,6581 }, { 232,6581 }, { 233,6581 }, { 234,6581 }, + + { 235,6581 }, { 236,6581 }, { 237,6581 }, { 238,6581 }, { 239,6581 }, + { 240,6581 }, { 241,6581 }, { 242,6581 }, { 243,6581 }, { 244,6581 }, + { 245,6581 }, { 246,6581 }, { 247,6581 }, { 248,6581 }, { 249,6581 }, + { 250,6581 }, { 251,6581 }, { 252,6581 }, { 253,6581 }, { 254,6581 }, + { 255,6581 }, { 256,6581 }, { 0, 0 }, { 0,60407 }, { 1,6323 }, + { 2,6323 }, { 3,6323 }, { 4,6323 }, { 5,6323 }, { 6,6323 }, + { 7,6323 }, { 8,6323 }, { 9,6323 }, { 10,6581 }, { 11,6323 }, + { 12,6323 }, { 13,6323 }, { 14,6323 }, { 15,6323 }, { 16,6323 }, + { 17,6323 }, { 18,6323 }, { 19,6323 }, { 20,6323 }, { 21,6323 }, + { 22,6323 }, { 23,6323 }, { 24,6323 }, { 25,6323 }, { 26,6323 }, + + { 27,6323 }, { 28,6323 }, { 29,6323 }, { 30,6323 }, { 31,6323 }, + { 32,6323 }, { 33,6323 }, { 34,6323 }, { 35,6323 }, { 36,6839 }, + { 37,6323 }, { 38,6323 }, { 39,6323 }, { 40,6323 }, { 41,6323 }, + { 42,6323 }, { 43,6323 }, { 44,6323 }, { 45,6323 }, { 46,6323 }, + { 47,6323 }, { 48,6323 }, { 49,6323 }, { 50,6323 }, { 51,6323 }, + { 52,6323 }, { 53,6323 }, { 54,6323 }, { 55,6323 }, { 56,6323 }, + { 57,6323 }, { 58,6323 }, { 59,6323 }, { 60,6323 }, { 61,6323 }, + { 62,6323 }, { 63,6323 }, { 64,6323 }, { 65,6323 }, { 66,6323 }, + { 67,6323 }, { 68,6323 }, { 69,6323 }, { 70,6323 }, { 71,6323 }, + { 72,6323 }, { 73,6323 }, { 74,6323 }, { 75,6323 }, { 76,6323 }, + + { 77,6323 }, { 78,6323 }, { 79,6323 }, { 80,6323 }, { 81,6323 }, + { 82,6323 }, { 83,6323 }, { 84,6323 }, { 85,6323 }, { 86,6323 }, + { 87,6323 }, { 88,6323 }, { 89,6323 }, { 90,6323 }, { 91,6323 }, + { 92,6323 }, { 93,6323 }, { 94,6323 }, { 95,6323 }, { 96,6323 }, + { 97,6323 }, { 98,6323 }, { 99,6323 }, { 100,6323 }, { 101,6323 }, + { 102,6323 }, { 103,6323 }, { 104,6323 }, { 105,6323 }, { 106,6323 }, + { 107,6323 }, { 108,6323 }, { 109,6323 }, { 110,6323 }, { 111,6323 }, + { 112,6323 }, { 113,6323 }, { 114,6323 }, { 115,6323 }, { 116,6323 }, + { 117,6323 }, { 118,6323 }, { 119,6323 }, { 120,6323 }, { 121,6323 }, + { 122,6323 }, { 123,6323 }, { 124,6323 }, { 125,6323 }, { 126,6323 }, + + { 127,6323 }, { 128,6323 }, { 129,6323 }, { 130,6323 }, { 131,6323 }, + { 132,6323 }, { 133,6323 }, { 134,6323 }, { 135,6323 }, { 136,6323 }, + { 137,6323 }, { 138,6323 }, { 139,6323 }, { 140,6323 }, { 141,6323 }, + { 142,6323 }, { 143,6323 }, { 144,6323 }, { 145,6323 }, { 146,6323 }, + { 147,6323 }, { 148,6323 }, { 149,6323 }, { 150,6323 }, { 151,6323 }, + { 152,6323 }, { 153,6323 }, { 154,6323 }, { 155,6323 }, { 156,6323 }, + { 157,6323 }, { 158,6323 }, { 159,6323 }, { 160,6323 }, { 161,6323 }, + { 162,6323 }, { 163,6323 }, { 164,6323 }, { 165,6323 }, { 166,6323 }, + { 167,6323 }, { 168,6323 }, { 169,6323 }, { 170,6323 }, { 171,6323 }, + { 172,6323 }, { 173,6323 }, { 174,6323 }, { 175,6323 }, { 176,6323 }, + + { 177,6323 }, { 178,6323 }, { 179,6323 }, { 180,6323 }, { 181,6323 }, + { 182,6323 }, { 183,6323 }, { 184,6323 }, { 185,6323 }, { 186,6323 }, + { 187,6323 }, { 188,6323 }, { 189,6323 }, { 190,6323 }, { 191,6323 }, + { 192,6323 }, { 193,6323 }, { 194,6323 }, { 195,6323 }, { 196,6323 }, + { 197,6323 }, { 198,6323 }, { 199,6323 }, { 200,6323 }, { 201,6323 }, + { 202,6323 }, { 203,6323 }, { 204,6323 }, { 205,6323 }, { 206,6323 }, + { 207,6323 }, { 208,6323 }, { 209,6323 }, { 210,6323 }, { 211,6323 }, + { 212,6323 }, { 213,6323 }, { 214,6323 }, { 215,6323 }, { 216,6323 }, + { 217,6323 }, { 218,6323 }, { 219,6323 }, { 220,6323 }, { 221,6323 }, + { 222,6323 }, { 223,6323 }, { 224,6323 }, { 225,6323 }, { 226,6323 }, + + { 227,6323 }, { 228,6323 }, { 229,6323 }, { 230,6323 }, { 231,6323 }, + { 232,6323 }, { 233,6323 }, { 234,6323 }, { 235,6323 }, { 236,6323 }, + { 237,6323 }, { 238,6323 }, { 239,6323 }, { 240,6323 }, { 241,6323 }, + { 242,6323 }, { 243,6323 }, { 244,6323 }, { 245,6323 }, { 246,6323 }, + { 247,6323 }, { 248,6323 }, { 249,6323 }, { 250,6323 }, { 251,6323 }, + { 252,6323 }, { 253,6323 }, { 254,6323 }, { 255,6323 }, { 256,6323 }, + { 0, 0 }, { 0,60149 }, { 1,4376 }, { 2,4376 }, { 3,4376 }, + { 4,4376 }, { 5,4376 }, { 6,4376 }, { 7,4376 }, { 8,4376 }, + { 9,4376 }, { 10,4376 }, { 11,4376 }, { 12,4376 }, { 13,4376 }, + { 14,4376 }, { 15,4376 }, { 16,4376 }, { 17,4376 }, { 18,4376 }, + + { 19,4376 }, { 20,4376 }, { 21,4376 }, { 22,4376 }, { 23,4376 }, + { 24,4376 }, { 25,4376 }, { 26,4376 }, { 27,4376 }, { 28,4376 }, + { 29,4376 }, { 30,4376 }, { 31,4376 }, { 32,4376 }, { 33,4376 }, + { 34,6587 }, { 35,4376 }, { 36,4376 }, { 37,4376 }, { 38,4376 }, + { 39,4376 }, { 40,4376 }, { 41,4376 }, { 42,4376 }, { 43,4376 }, + { 44,4376 }, { 45,4376 }, { 46,4376 }, { 47,4376 }, { 48,4376 }, + { 49,4376 }, { 50,4376 }, { 51,4376 }, { 52,4376 }, { 53,4376 }, + { 54,4376 }, { 55,4376 }, { 56,4376 }, { 57,4376 }, { 58,4376 }, + { 59,4376 }, { 60,4376 }, { 61,4376 }, { 62,4376 }, { 63,4376 }, + { 64,4376 }, { 65,4376 }, { 66,4376 }, { 67,4376 }, { 68,4376 }, + + { 69,4376 }, { 70,4376 }, { 71,4376 }, { 72,4376 }, { 73,4376 }, + { 74,4376 }, { 75,4376 }, { 76,4376 }, { 77,4376 }, { 78,4376 }, + { 79,4376 }, { 80,4376 }, { 81,4376 }, { 82,4376 }, { 83,4376 }, + { 84,4376 }, { 85,4376 }, { 86,4376 }, { 87,4376 }, { 88,4376 }, + { 89,4376 }, { 90,4376 }, { 91,4376 }, { 92,4376 }, { 93,4376 }, + { 94,4376 }, { 95,4376 }, { 96,4376 }, { 97,4376 }, { 98,4376 }, + { 99,4376 }, { 100,4376 }, { 101,4376 }, { 102,4376 }, { 103,4376 }, + { 104,4376 }, { 105,4376 }, { 106,4376 }, { 107,4376 }, { 108,4376 }, + { 109,4376 }, { 110,4376 }, { 111,4376 }, { 112,4376 }, { 113,4376 }, + { 114,4376 }, { 115,4376 }, { 116,4376 }, { 117,4376 }, { 118,4376 }, + + { 119,4376 }, { 120,4376 }, { 121,4376 }, { 122,4376 }, { 123,4376 }, + { 124,4376 }, { 125,4376 }, { 126,4376 }, { 127,4376 }, { 128,4376 }, + { 129,4376 }, { 130,4376 }, { 131,4376 }, { 132,4376 }, { 133,4376 }, + { 134,4376 }, { 135,4376 }, { 136,4376 }, { 137,4376 }, { 138,4376 }, + { 139,4376 }, { 140,4376 }, { 141,4376 }, { 142,4376 }, { 143,4376 }, + { 144,4376 }, { 145,4376 }, { 146,4376 }, { 147,4376 }, { 148,4376 }, + { 149,4376 }, { 150,4376 }, { 151,4376 }, { 152,4376 }, { 153,4376 }, + { 154,4376 }, { 155,4376 }, { 156,4376 }, { 157,4376 }, { 158,4376 }, + { 159,4376 }, { 160,4376 }, { 161,4376 }, { 162,4376 }, { 163,4376 }, + { 164,4376 }, { 165,4376 }, { 166,4376 }, { 167,4376 }, { 168,4376 }, + + { 169,4376 }, { 170,4376 }, { 171,4376 }, { 172,4376 }, { 173,4376 }, + { 174,4376 }, { 175,4376 }, { 176,4376 }, { 177,4376 }, { 178,4376 }, + { 179,4376 }, { 180,4376 }, { 181,4376 }, { 182,4376 }, { 183,4376 }, + { 184,4376 }, { 185,4376 }, { 186,4376 }, { 187,4376 }, { 188,4376 }, + { 189,4376 }, { 190,4376 }, { 191,4376 }, { 192,4376 }, { 193,4376 }, + { 194,4376 }, { 195,4376 }, { 196,4376 }, { 197,4376 }, { 198,4376 }, + { 199,4376 }, { 200,4376 }, { 201,4376 }, { 202,4376 }, { 203,4376 }, + { 204,4376 }, { 205,4376 }, { 206,4376 }, { 207,4376 }, { 208,4376 }, + { 209,4376 }, { 210,4376 }, { 211,4376 }, { 212,4376 }, { 213,4376 }, + { 214,4376 }, { 215,4376 }, { 216,4376 }, { 217,4376 }, { 218,4376 }, + + { 219,4376 }, { 220,4376 }, { 221,4376 }, { 222,4376 }, { 223,4376 }, + { 224,4376 }, { 225,4376 }, { 226,4376 }, { 227,4376 }, { 228,4376 }, + { 229,4376 }, { 230,4376 }, { 231,4376 }, { 232,4376 }, { 233,4376 }, + { 234,4376 }, { 235,4376 }, { 236,4376 }, { 237,4376 }, { 238,4376 }, + { 239,4376 }, { 240,4376 }, { 241,4376 }, { 242,4376 }, { 243,4376 }, + { 244,4376 }, { 245,4376 }, { 246,4376 }, { 247,4376 }, { 248,4376 }, + { 249,4376 }, { 250,4376 }, { 251,4376 }, { 252,4376 }, { 253,4376 }, + { 254,4376 }, { 255,4376 }, { 256,4376 }, { 0, 0 }, { 0,59891 }, + { 1,4118 }, { 2,4118 }, { 3,4118 }, { 4,4118 }, { 5,4118 }, + { 6,4118 }, { 7,4118 }, { 8,4118 }, { 9,4118 }, { 10,4118 }, + + { 11,4118 }, { 12,4118 }, { 13,4118 }, { 14,4118 }, { 15,4118 }, + { 16,4118 }, { 17,4118 }, { 18,4118 }, { 19,4118 }, { 20,4118 }, + { 21,4118 }, { 22,4118 }, { 23,4118 }, { 24,4118 }, { 25,4118 }, + { 26,4118 }, { 27,4118 }, { 28,4118 }, { 29,4118 }, { 30,4118 }, + { 31,4118 }, { 32,4118 }, { 33,4118 }, { 34,6329 }, { 35,4118 }, + { 36,4118 }, { 37,4118 }, { 38,4118 }, { 39,4118 }, { 40,4118 }, + { 41,4118 }, { 42,4118 }, { 43,4118 }, { 44,4118 }, { 45,4118 }, + { 46,4118 }, { 47,4118 }, { 48,4118 }, { 49,4118 }, { 50,4118 }, + { 51,4118 }, { 52,4118 }, { 53,4118 }, { 54,4118 }, { 55,4118 }, + { 56,4118 }, { 57,4118 }, { 58,4118 }, { 59,4118 }, { 60,4118 }, + + { 61,4118 }, { 62,4118 }, { 63,4118 }, { 64,4118 }, { 65,4118 }, + { 66,4118 }, { 67,4118 }, { 68,4118 }, { 69,4118 }, { 70,4118 }, + { 71,4118 }, { 72,4118 }, { 73,4118 }, { 74,4118 }, { 75,4118 }, + { 76,4118 }, { 77,4118 }, { 78,4118 }, { 79,4118 }, { 80,4118 }, + { 81,4118 }, { 82,4118 }, { 83,4118 }, { 84,4118 }, { 85,4118 }, + { 86,4118 }, { 87,4118 }, { 88,4118 }, { 89,4118 }, { 90,4118 }, + { 91,4118 }, { 92,4118 }, { 93,4118 }, { 94,4118 }, { 95,4118 }, + { 96,4118 }, { 97,4118 }, { 98,4118 }, { 99,4118 }, { 100,4118 }, + { 101,4118 }, { 102,4118 }, { 103,4118 }, { 104,4118 }, { 105,4118 }, + { 106,4118 }, { 107,4118 }, { 108,4118 }, { 109,4118 }, { 110,4118 }, + + { 111,4118 }, { 112,4118 }, { 113,4118 }, { 114,4118 }, { 115,4118 }, + { 116,4118 }, { 117,4118 }, { 118,4118 }, { 119,4118 }, { 120,4118 }, + { 121,4118 }, { 122,4118 }, { 123,4118 }, { 124,4118 }, { 125,4118 }, + { 126,4118 }, { 127,4118 }, { 128,4118 }, { 129,4118 }, { 130,4118 }, + { 131,4118 }, { 132,4118 }, { 133,4118 }, { 134,4118 }, { 135,4118 }, + { 136,4118 }, { 137,4118 }, { 138,4118 }, { 139,4118 }, { 140,4118 }, + { 141,4118 }, { 142,4118 }, { 143,4118 }, { 144,4118 }, { 145,4118 }, + { 146,4118 }, { 147,4118 }, { 148,4118 }, { 149,4118 }, { 150,4118 }, + { 151,4118 }, { 152,4118 }, { 153,4118 }, { 154,4118 }, { 155,4118 }, + { 156,4118 }, { 157,4118 }, { 158,4118 }, { 159,4118 }, { 160,4118 }, + + { 161,4118 }, { 162,4118 }, { 163,4118 }, { 164,4118 }, { 165,4118 }, + { 166,4118 }, { 167,4118 }, { 168,4118 }, { 169,4118 }, { 170,4118 }, + { 171,4118 }, { 172,4118 }, { 173,4118 }, { 174,4118 }, { 175,4118 }, + { 176,4118 }, { 177,4118 }, { 178,4118 }, { 179,4118 }, { 180,4118 }, + { 181,4118 }, { 182,4118 }, { 183,4118 }, { 184,4118 }, { 185,4118 }, + { 186,4118 }, { 187,4118 }, { 188,4118 }, { 189,4118 }, { 190,4118 }, + { 191,4118 }, { 192,4118 }, { 193,4118 }, { 194,4118 }, { 195,4118 }, + { 196,4118 }, { 197,4118 }, { 198,4118 }, { 199,4118 }, { 200,4118 }, + { 201,4118 }, { 202,4118 }, { 203,4118 }, { 204,4118 }, { 205,4118 }, + { 206,4118 }, { 207,4118 }, { 208,4118 }, { 209,4118 }, { 210,4118 }, + + { 211,4118 }, { 212,4118 }, { 213,4118 }, { 214,4118 }, { 215,4118 }, + { 216,4118 }, { 217,4118 }, { 218,4118 }, { 219,4118 }, { 220,4118 }, + { 221,4118 }, { 222,4118 }, { 223,4118 }, { 224,4118 }, { 225,4118 }, + { 226,4118 }, { 227,4118 }, { 228,4118 }, { 229,4118 }, { 230,4118 }, + { 231,4118 }, { 232,4118 }, { 233,4118 }, { 234,4118 }, { 235,4118 }, + { 236,4118 }, { 237,4118 }, { 238,4118 }, { 239,4118 }, { 240,4118 }, + { 241,4118 }, { 242,4118 }, { 243,4118 }, { 244,4118 }, { 245,4118 }, + { 246,4118 }, { 247,4118 }, { 248,4118 }, { 249,4118 }, { 250,4118 }, + { 251,4118 }, { 252,4118 }, { 253,4118 }, { 254,4118 }, { 255,4118 }, + { 256,4118 }, { 0, 0 }, { 0,59633 }, { 1,5244 }, { 2,5244 }, + + { 3,5244 }, { 4,5244 }, { 5,5244 }, { 6,5244 }, { 7,5244 }, + { 8,5244 }, { 9,5244 }, { 10,5244 }, { 11,5244 }, { 12,5244 }, + { 13,5244 }, { 14,5244 }, { 15,5244 }, { 16,5244 }, { 17,5244 }, + { 18,5244 }, { 19,5244 }, { 20,5244 }, { 21,5244 }, { 22,5244 }, + { 23,5244 }, { 24,5244 }, { 25,5244 }, { 26,5244 }, { 27,5244 }, + { 28,5244 }, { 29,5244 }, { 30,5244 }, { 31,5244 }, { 32,5244 }, + { 33,5244 }, { 34,5244 }, { 35,5244 }, { 36,5244 }, { 37,5244 }, + { 38,5244 }, { 39,6322 }, { 40,5244 }, { 41,5244 }, { 42,5244 }, + { 43,5244 }, { 44,5244 }, { 45,5244 }, { 46,5244 }, { 47,5244 }, + { 48,5244 }, { 49,5244 }, { 50,5244 }, { 51,5244 }, { 52,5244 }, + + { 53,5244 }, { 54,5244 }, { 55,5244 }, { 56,5244 }, { 57,5244 }, + { 58,5244 }, { 59,5244 }, { 60,5244 }, { 61,5244 }, { 62,5244 }, + { 63,5244 }, { 64,5244 }, { 65,5244 }, { 66,5244 }, { 67,5244 }, + { 68,5244 }, { 69,5244 }, { 70,5244 }, { 71,5244 }, { 72,5244 }, + { 73,5244 }, { 74,5244 }, { 75,5244 }, { 76,5244 }, { 77,5244 }, + { 78,5244 }, { 79,5244 }, { 80,5244 }, { 81,5244 }, { 82,5244 }, + { 83,5244 }, { 84,5244 }, { 85,5244 }, { 86,5244 }, { 87,5244 }, + { 88,5244 }, { 89,5244 }, { 90,5244 }, { 91,5244 }, { 92,5244 }, + { 93,5244 }, { 94,5244 }, { 95,5244 }, { 96,5244 }, { 97,5244 }, + { 98,5244 }, { 99,5244 }, { 100,5244 }, { 101,5244 }, { 102,5244 }, + + { 103,5244 }, { 104,5244 }, { 105,5244 }, { 106,5244 }, { 107,5244 }, + { 108,5244 }, { 109,5244 }, { 110,5244 }, { 111,5244 }, { 112,5244 }, + { 113,5244 }, { 114,5244 }, { 115,5244 }, { 116,5244 }, { 117,5244 }, + { 118,5244 }, { 119,5244 }, { 120,5244 }, { 121,5244 }, { 122,5244 }, + { 123,5244 }, { 124,5244 }, { 125,5244 }, { 126,5244 }, { 127,5244 }, + { 128,5244 }, { 129,5244 }, { 130,5244 }, { 131,5244 }, { 132,5244 }, + { 133,5244 }, { 134,5244 }, { 135,5244 }, { 136,5244 }, { 137,5244 }, + { 138,5244 }, { 139,5244 }, { 140,5244 }, { 141,5244 }, { 142,5244 }, + { 143,5244 }, { 144,5244 }, { 145,5244 }, { 146,5244 }, { 147,5244 }, + { 148,5244 }, { 149,5244 }, { 150,5244 }, { 151,5244 }, { 152,5244 }, + + { 153,5244 }, { 154,5244 }, { 155,5244 }, { 156,5244 }, { 157,5244 }, + { 158,5244 }, { 159,5244 }, { 160,5244 }, { 161,5244 }, { 162,5244 }, + { 163,5244 }, { 164,5244 }, { 165,5244 }, { 166,5244 }, { 167,5244 }, + { 168,5244 }, { 169,5244 }, { 170,5244 }, { 171,5244 }, { 172,5244 }, + { 173,5244 }, { 174,5244 }, { 175,5244 }, { 176,5244 }, { 177,5244 }, + { 178,5244 }, { 179,5244 }, { 180,5244 }, { 181,5244 }, { 182,5244 }, + { 183,5244 }, { 184,5244 }, { 185,5244 }, { 186,5244 }, { 187,5244 }, + { 188,5244 }, { 189,5244 }, { 190,5244 }, { 191,5244 }, { 192,5244 }, + { 193,5244 }, { 194,5244 }, { 195,5244 }, { 196,5244 }, { 197,5244 }, + { 198,5244 }, { 199,5244 }, { 200,5244 }, { 201,5244 }, { 202,5244 }, + + { 203,5244 }, { 204,5244 }, { 205,5244 }, { 206,5244 }, { 207,5244 }, + { 208,5244 }, { 209,5244 }, { 210,5244 }, { 211,5244 }, { 212,5244 }, + { 213,5244 }, { 214,5244 }, { 215,5244 }, { 216,5244 }, { 217,5244 }, + { 218,5244 }, { 219,5244 }, { 220,5244 }, { 221,5244 }, { 222,5244 }, + { 223,5244 }, { 224,5244 }, { 225,5244 }, { 226,5244 }, { 227,5244 }, + { 228,5244 }, { 229,5244 }, { 230,5244 }, { 231,5244 }, { 232,5244 }, + { 233,5244 }, { 234,5244 }, { 235,5244 }, { 236,5244 }, { 237,5244 }, + { 238,5244 }, { 239,5244 }, { 240,5244 }, { 241,5244 }, { 242,5244 }, + { 243,5244 }, { 244,5244 }, { 245,5244 }, { 246,5244 }, { 247,5244 }, + { 248,5244 }, { 249,5244 }, { 250,5244 }, { 251,5244 }, { 252,5244 }, + + { 253,5244 }, { 254,5244 }, { 255,5244 }, { 256,5244 }, { 0, 0 }, + { 0,59375 }, { 1,4986 }, { 2,4986 }, { 3,4986 }, { 4,4986 }, + { 5,4986 }, { 6,4986 }, { 7,4986 }, { 8,4986 }, { 9,4986 }, + { 10,4986 }, { 11,4986 }, { 12,4986 }, { 13,4986 }, { 14,4986 }, + { 15,4986 }, { 16,4986 }, { 17,4986 }, { 18,4986 }, { 19,4986 }, + { 20,4986 }, { 21,4986 }, { 22,4986 }, { 23,4986 }, { 24,4986 }, + { 25,4986 }, { 26,4986 }, { 27,4986 }, { 28,4986 }, { 29,4986 }, + { 30,4986 }, { 31,4986 }, { 32,4986 }, { 33,4986 }, { 34,4986 }, + { 35,4986 }, { 36,4986 }, { 37,4986 }, { 38,4986 }, { 39,6064 }, + { 40,4986 }, { 41,4986 }, { 42,4986 }, { 43,4986 }, { 44,4986 }, + + { 45,4986 }, { 46,4986 }, { 47,4986 }, { 48,4986 }, { 49,4986 }, + { 50,4986 }, { 51,4986 }, { 52,4986 }, { 53,4986 }, { 54,4986 }, + { 55,4986 }, { 56,4986 }, { 57,4986 }, { 58,4986 }, { 59,4986 }, + { 60,4986 }, { 61,4986 }, { 62,4986 }, { 63,4986 }, { 64,4986 }, + { 65,4986 }, { 66,4986 }, { 67,4986 }, { 68,4986 }, { 69,4986 }, + { 70,4986 }, { 71,4986 }, { 72,4986 }, { 73,4986 }, { 74,4986 }, + { 75,4986 }, { 76,4986 }, { 77,4986 }, { 78,4986 }, { 79,4986 }, + { 80,4986 }, { 81,4986 }, { 82,4986 }, { 83,4986 }, { 84,4986 }, + { 85,4986 }, { 86,4986 }, { 87,4986 }, { 88,4986 }, { 89,4986 }, + { 90,4986 }, { 91,4986 }, { 92,4986 }, { 93,4986 }, { 94,4986 }, + + { 95,4986 }, { 96,4986 }, { 97,4986 }, { 98,4986 }, { 99,4986 }, + { 100,4986 }, { 101,4986 }, { 102,4986 }, { 103,4986 }, { 104,4986 }, + { 105,4986 }, { 106,4986 }, { 107,4986 }, { 108,4986 }, { 109,4986 }, + { 110,4986 }, { 111,4986 }, { 112,4986 }, { 113,4986 }, { 114,4986 }, + { 115,4986 }, { 116,4986 }, { 117,4986 }, { 118,4986 }, { 119,4986 }, + { 120,4986 }, { 121,4986 }, { 122,4986 }, { 123,4986 }, { 124,4986 }, + { 125,4986 }, { 126,4986 }, { 127,4986 }, { 128,4986 }, { 129,4986 }, + { 130,4986 }, { 131,4986 }, { 132,4986 }, { 133,4986 }, { 134,4986 }, + { 135,4986 }, { 136,4986 }, { 137,4986 }, { 138,4986 }, { 139,4986 }, + { 140,4986 }, { 141,4986 }, { 142,4986 }, { 143,4986 }, { 144,4986 }, + + { 145,4986 }, { 146,4986 }, { 147,4986 }, { 148,4986 }, { 149,4986 }, + { 150,4986 }, { 151,4986 }, { 152,4986 }, { 153,4986 }, { 154,4986 }, + { 155,4986 }, { 156,4986 }, { 157,4986 }, { 158,4986 }, { 159,4986 }, + { 160,4986 }, { 161,4986 }, { 162,4986 }, { 163,4986 }, { 164,4986 }, + { 165,4986 }, { 166,4986 }, { 167,4986 }, { 168,4986 }, { 169,4986 }, + { 170,4986 }, { 171,4986 }, { 172,4986 }, { 173,4986 }, { 174,4986 }, + { 175,4986 }, { 176,4986 }, { 177,4986 }, { 178,4986 }, { 179,4986 }, + { 180,4986 }, { 181,4986 }, { 182,4986 }, { 183,4986 }, { 184,4986 }, + { 185,4986 }, { 186,4986 }, { 187,4986 }, { 188,4986 }, { 189,4986 }, + { 190,4986 }, { 191,4986 }, { 192,4986 }, { 193,4986 }, { 194,4986 }, + + { 195,4986 }, { 196,4986 }, { 197,4986 }, { 198,4986 }, { 199,4986 }, + { 200,4986 }, { 201,4986 }, { 202,4986 }, { 203,4986 }, { 204,4986 }, + { 205,4986 }, { 206,4986 }, { 207,4986 }, { 208,4986 }, { 209,4986 }, + { 210,4986 }, { 211,4986 }, { 212,4986 }, { 213,4986 }, { 214,4986 }, + { 215,4986 }, { 216,4986 }, { 217,4986 }, { 218,4986 }, { 219,4986 }, + { 220,4986 }, { 221,4986 }, { 222,4986 }, { 223,4986 }, { 224,4986 }, + { 225,4986 }, { 226,4986 }, { 227,4986 }, { 228,4986 }, { 229,4986 }, + { 230,4986 }, { 231,4986 }, { 232,4986 }, { 233,4986 }, { 234,4986 }, + { 235,4986 }, { 236,4986 }, { 237,4986 }, { 238,4986 }, { 239,4986 }, + { 240,4986 }, { 241,4986 }, { 242,4986 }, { 243,4986 }, { 244,4986 }, + + { 245,4986 }, { 246,4986 }, { 247,4986 }, { 248,4986 }, { 249,4986 }, + { 250,4986 }, { 251,4986 }, { 252,4986 }, { 253,4986 }, { 254,4986 }, + { 255,4986 }, { 256,4986 }, { 0, 0 }, { 0,59117 }, { 1, 574 }, + { 2, 574 }, { 3, 574 }, { 4, 574 }, { 5, 574 }, { 6, 574 }, + { 7, 574 }, { 8, 574 }, { 9, 574 }, { 10, 576 }, { 11, 574 }, + { 12, 574 }, { 13, 574 }, { 14, 574 }, { 15, 574 }, { 16, 574 }, + { 17, 574 }, { 18, 574 }, { 19, 574 }, { 20, 574 }, { 21, 574 }, + { 22, 574 }, { 23, 574 }, { 24, 574 }, { 25, 574 }, { 26, 574 }, + { 27, 574 }, { 28, 574 }, { 29, 574 }, { 30, 574 }, { 31, 574 }, + { 32, 574 }, { 33, 574 }, { 34, 574 }, { 35, 574 }, { 36, 574 }, + + { 37, 574 }, { 38, 574 }, { 39, 574 }, { 40, 574 }, { 41, 574 }, + { 42, 574 }, { 43, 574 }, { 44, 574 }, { 45, 574 }, { 46, 574 }, + { 47, 574 }, { 48, 574 }, { 49, 574 }, { 50, 574 }, { 51, 574 }, + { 52, 574 }, { 53, 574 }, { 54, 574 }, { 55, 574 }, { 56, 574 }, + { 57, 574 }, { 58, 574 }, { 59, 574 }, { 60, 574 }, { 61, 574 }, + { 62, 574 }, { 63, 574 }, { 64, 574 }, { 65, 574 }, { 66, 574 }, + { 67, 574 }, { 68, 574 }, { 69, 574 }, { 70, 574 }, { 71, 574 }, + { 72, 574 }, { 73, 574 }, { 74, 574 }, { 75, 574 }, { 76, 574 }, + { 77, 574 }, { 78, 574 }, { 79, 574 }, { 80, 574 }, { 81, 574 }, + { 82, 574 }, { 83, 574 }, { 84, 574 }, { 85, 574 }, { 86, 574 }, + + { 87, 574 }, { 88, 574 }, { 89, 574 }, { 90, 574 }, { 91, 574 }, + { 92, 817 }, { 93, 574 }, { 94, 574 }, { 95, 574 }, { 96, 574 }, + { 97, 574 }, { 98, 574 }, { 99, 574 }, { 100, 574 }, { 101, 574 }, + { 102, 574 }, { 103, 574 }, { 104, 574 }, { 105, 574 }, { 106, 574 }, + { 107, 574 }, { 108, 574 }, { 109, 574 }, { 110, 574 }, { 111, 574 }, + { 112, 574 }, { 113, 574 }, { 114, 574 }, { 115, 574 }, { 116, 574 }, + { 117, 574 }, { 118, 574 }, { 119, 574 }, { 120, 574 }, { 121, 574 }, + { 122, 574 }, { 123, 574 }, { 124, 574 }, { 125, 574 }, { 126, 574 }, + { 127, 574 }, { 128, 574 }, { 129, 574 }, { 130, 574 }, { 131, 574 }, + { 132, 574 }, { 133, 574 }, { 134, 574 }, { 135, 574 }, { 136, 574 }, + + { 137, 574 }, { 138, 574 }, { 139, 574 }, { 140, 574 }, { 141, 574 }, + { 142, 574 }, { 143, 574 }, { 144, 574 }, { 145, 574 }, { 146, 574 }, + { 147, 574 }, { 148, 574 }, { 149, 574 }, { 150, 574 }, { 151, 574 }, + { 152, 574 }, { 153, 574 }, { 154, 574 }, { 155, 574 }, { 156, 574 }, + { 157, 574 }, { 158, 574 }, { 159, 574 }, { 160, 574 }, { 161, 574 }, + { 162, 574 }, { 163, 574 }, { 164, 574 }, { 165, 574 }, { 166, 574 }, + { 167, 574 }, { 168, 574 }, { 169, 574 }, { 170, 574 }, { 171, 574 }, + { 172, 574 }, { 173, 574 }, { 174, 574 }, { 175, 574 }, { 176, 574 }, + { 177, 574 }, { 178, 574 }, { 179, 574 }, { 180, 574 }, { 181, 574 }, + { 182, 574 }, { 183, 574 }, { 184, 574 }, { 185, 574 }, { 186, 574 }, + + { 187, 574 }, { 188, 574 }, { 189, 574 }, { 190, 574 }, { 191, 574 }, + { 192, 574 }, { 193, 574 }, { 194, 574 }, { 195, 574 }, { 196, 574 }, + { 197, 574 }, { 198, 574 }, { 199, 574 }, { 200, 574 }, { 201, 574 }, + { 202, 574 }, { 203, 574 }, { 204, 574 }, { 205, 574 }, { 206, 574 }, + { 207, 574 }, { 208, 574 }, { 209, 574 }, { 210, 574 }, { 211, 574 }, + { 212, 574 }, { 213, 574 }, { 214, 574 }, { 215, 574 }, { 216, 574 }, + { 217, 574 }, { 218, 574 }, { 219, 574 }, { 220, 574 }, { 221, 574 }, + { 222, 574 }, { 223, 574 }, { 224, 574 }, { 225, 574 }, { 226, 574 }, + { 227, 574 }, { 228, 574 }, { 229, 574 }, { 230, 574 }, { 231, 574 }, + { 232, 574 }, { 233, 574 }, { 234, 574 }, { 235, 574 }, { 236, 574 }, + + { 237, 574 }, { 238, 574 }, { 239, 574 }, { 240, 574 }, { 241, 574 }, + { 242, 574 }, { 243, 574 }, { 244, 574 }, { 245, 574 }, { 246, 574 }, + { 247, 574 }, { 248, 574 }, { 249, 574 }, { 250, 574 }, { 251, 574 }, + { 252, 574 }, { 253, 574 }, { 254, 574 }, { 255, 574 }, { 256, 574 }, + { 0, 0 }, { 0,58859 }, { 1, 316 }, { 2, 316 }, { 3, 316 }, + { 4, 316 }, { 5, 316 }, { 6, 316 }, { 7, 316 }, { 8, 316 }, + { 9, 316 }, { 10, 318 }, { 11, 316 }, { 12, 316 }, { 13, 316 }, + { 14, 316 }, { 15, 316 }, { 16, 316 }, { 17, 316 }, { 18, 316 }, + { 19, 316 }, { 20, 316 }, { 21, 316 }, { 22, 316 }, { 23, 316 }, + { 24, 316 }, { 25, 316 }, { 26, 316 }, { 27, 316 }, { 28, 316 }, + + { 29, 316 }, { 30, 316 }, { 31, 316 }, { 32, 316 }, { 33, 316 }, + { 34, 316 }, { 35, 316 }, { 36, 316 }, { 37, 316 }, { 38, 316 }, + { 39, 316 }, { 40, 316 }, { 41, 316 }, { 42, 316 }, { 43, 316 }, + { 44, 316 }, { 45, 316 }, { 46, 316 }, { 47, 316 }, { 48, 316 }, + { 49, 316 }, { 50, 316 }, { 51, 316 }, { 52, 316 }, { 53, 316 }, + { 54, 316 }, { 55, 316 }, { 56, 316 }, { 57, 316 }, { 58, 316 }, + { 59, 316 }, { 60, 316 }, { 61, 316 }, { 62, 316 }, { 63, 316 }, + { 64, 316 }, { 65, 316 }, { 66, 316 }, { 67, 316 }, { 68, 316 }, + { 69, 316 }, { 70, 316 }, { 71, 316 }, { 72, 316 }, { 73, 316 }, + { 74, 316 }, { 75, 316 }, { 76, 316 }, { 77, 316 }, { 78, 316 }, + + { 79, 316 }, { 80, 316 }, { 81, 316 }, { 82, 316 }, { 83, 316 }, + { 84, 316 }, { 85, 316 }, { 86, 316 }, { 87, 316 }, { 88, 316 }, + { 89, 316 }, { 90, 316 }, { 91, 316 }, { 92, 559 }, { 93, 316 }, + { 94, 316 }, { 95, 316 }, { 96, 316 }, { 97, 316 }, { 98, 316 }, + { 99, 316 }, { 100, 316 }, { 101, 316 }, { 102, 316 }, { 103, 316 }, + { 104, 316 }, { 105, 316 }, { 106, 316 }, { 107, 316 }, { 108, 316 }, + { 109, 316 }, { 110, 316 }, { 111, 316 }, { 112, 316 }, { 113, 316 }, + { 114, 316 }, { 115, 316 }, { 116, 316 }, { 117, 316 }, { 118, 316 }, + { 119, 316 }, { 120, 316 }, { 121, 316 }, { 122, 316 }, { 123, 316 }, + { 124, 316 }, { 125, 316 }, { 126, 316 }, { 127, 316 }, { 128, 316 }, + + { 129, 316 }, { 130, 316 }, { 131, 316 }, { 132, 316 }, { 133, 316 }, + { 134, 316 }, { 135, 316 }, { 136, 316 }, { 137, 316 }, { 138, 316 }, + { 139, 316 }, { 140, 316 }, { 141, 316 }, { 142, 316 }, { 143, 316 }, + { 144, 316 }, { 145, 316 }, { 146, 316 }, { 147, 316 }, { 148, 316 }, + { 149, 316 }, { 150, 316 }, { 151, 316 }, { 152, 316 }, { 153, 316 }, + { 154, 316 }, { 155, 316 }, { 156, 316 }, { 157, 316 }, { 158, 316 }, + { 159, 316 }, { 160, 316 }, { 161, 316 }, { 162, 316 }, { 163, 316 }, + { 164, 316 }, { 165, 316 }, { 166, 316 }, { 167, 316 }, { 168, 316 }, + { 169, 316 }, { 170, 316 }, { 171, 316 }, { 172, 316 }, { 173, 316 }, + { 174, 316 }, { 175, 316 }, { 176, 316 }, { 177, 316 }, { 178, 316 }, + + { 179, 316 }, { 180, 316 }, { 181, 316 }, { 182, 316 }, { 183, 316 }, + { 184, 316 }, { 185, 316 }, { 186, 316 }, { 187, 316 }, { 188, 316 }, + { 189, 316 }, { 190, 316 }, { 191, 316 }, { 192, 316 }, { 193, 316 }, + { 194, 316 }, { 195, 316 }, { 196, 316 }, { 197, 316 }, { 198, 316 }, + { 199, 316 }, { 200, 316 }, { 201, 316 }, { 202, 316 }, { 203, 316 }, + { 204, 316 }, { 205, 316 }, { 206, 316 }, { 207, 316 }, { 208, 316 }, + { 209, 316 }, { 210, 316 }, { 211, 316 }, { 212, 316 }, { 213, 316 }, + { 214, 316 }, { 215, 316 }, { 216, 316 }, { 217, 316 }, { 218, 316 }, + { 219, 316 }, { 220, 316 }, { 221, 316 }, { 222, 316 }, { 223, 316 }, + { 224, 316 }, { 225, 316 }, { 226, 316 }, { 227, 316 }, { 228, 316 }, + + { 229, 316 }, { 230, 316 }, { 231, 316 }, { 232, 316 }, { 233, 316 }, + { 234, 316 }, { 235, 316 }, { 236, 316 }, { 237, 316 }, { 238, 316 }, + { 239, 316 }, { 240, 316 }, { 241, 316 }, { 242, 316 }, { 243, 316 }, + { 244, 316 }, { 245, 316 }, { 246, 316 }, { 247, 316 }, { 248, 316 }, + { 249, 316 }, { 250, 316 }, { 251, 316 }, { 252, 316 }, { 253, 316 }, + { 254, 316 }, { 255, 316 }, { 256, 316 }, { 0, 66 }, { 0,58601 }, + { 0, 1 }, { 0,58599 }, { 0, 45 }, { 0,58597 }, { 0, 0 }, + { 0, 1 }, { 0,58594 }, { 0, 57 }, { 0,58592 }, { 0, 0 }, + { 9,5293 }, { 10,5293 }, { 0, 0 }, { 12,5293 }, { 13,5293 }, + { 9,5288 }, { 10,5288 }, { 0, 0 }, { 12,5288 }, { 13,5288 }, + + { 0, 19 }, { 0,58579 }, { 0, 56 }, { 0,58577 }, { 0, 56 }, + { 0,58575 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 6 }, { 0,58569 }, { 0, 0 }, { 32,5293 }, { 0, 6 }, + { 0,58565 }, { 0, 0 }, { 0, 0 }, { 32,5288 }, { 0, 66 }, + { 0,58560 }, { 33,5301 }, { 0, 0 }, { 35,5301 }, { 0, 0 }, + { 37,5301 }, { 38,5301 }, { 0, 47 }, { 0,58552 }, { 0, 0 }, + { 42,5301 }, { 43,5301 }, { 0, 0 }, { 45,5301 }, { 0, 0 }, + { 47,5301 }, { 0, 31 }, { 0,58543 }, { 0, 32 }, { 0,58541 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 60,5301 }, { 61,5301 }, + + { 62,5301 }, { 63,5301 }, { 64,5301 }, { 42, 394 }, { 0, 0 }, + { 0, 0 }, { 36, 262 }, { 42,6846 }, { 47, 396 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 34, 381 }, { 58, 281 }, { 0, 0 }, + { 0, 0 }, { 61, 285 }, { 0, 0 }, { 48,5271 }, { 49,5271 }, + { 50,5271 }, { 51,5271 }, { 52,5271 }, { 53,5271 }, { 54,5271 }, + { 55,5271 }, { 56,5271 }, { 57,5271 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 94,5301 }, { 0, 0 }, { 96,5301 }, + { 65,5348 }, { 66,5348 }, { 67,5348 }, { 68,5348 }, { 69,5348 }, + { 70,5348 }, { 71,5348 }, { 72,5348 }, { 73,5348 }, { 74,5348 }, + { 75,5348 }, { 76,5348 }, { 77,5348 }, { 78,5348 }, { 79,5348 }, + + { 80,5348 }, { 81,5348 }, { 82,5348 }, { 83,5348 }, { 84,5348 }, + { 85,5348 }, { 86,5348 }, { 87,5348 }, { 88,5348 }, { 89,5348 }, + { 90,5348 }, { 0, 0 }, { 124,5301 }, { 0, 0 }, { 126,5301 }, + { 95,5348 }, { 0, 0 }, { 97,5348 }, { 98,5348 }, { 99,5348 }, + { 100,5348 }, { 101,5348 }, { 102,5348 }, { 103,5348 }, { 104,5348 }, + { 105,5348 }, { 106,5348 }, { 107,5348 }, { 108,5348 }, { 109,5348 }, + { 110,5348 }, { 111,5348 }, { 112,5348 }, { 113,5348 }, { 114,5348 }, + { 115,5348 }, { 116,5348 }, { 117,5348 }, { 118,5348 }, { 119,5348 }, + { 120,5348 }, { 121,5348 }, { 122,5348 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 128,5348 }, { 129,5348 }, + + { 130,5348 }, { 131,5348 }, { 132,5348 }, { 133,5348 }, { 134,5348 }, + { 135,5348 }, { 136,5348 }, { 137,5348 }, { 138,5348 }, { 139,5348 }, + { 140,5348 }, { 141,5348 }, { 142,5348 }, { 143,5348 }, { 144,5348 }, + { 145,5348 }, { 146,5348 }, { 147,5348 }, { 148,5348 }, { 149,5348 }, + { 150,5348 }, { 151,5348 }, { 152,5348 }, { 153,5348 }, { 154,5348 }, + { 155,5348 }, { 156,5348 }, { 157,5348 }, { 158,5348 }, { 159,5348 }, + { 160,5348 }, { 161,5348 }, { 162,5348 }, { 163,5348 }, { 164,5348 }, + { 165,5348 }, { 166,5348 }, { 167,5348 }, { 168,5348 }, { 169,5348 }, + { 170,5348 }, { 171,5348 }, { 172,5348 }, { 173,5348 }, { 174,5348 }, + { 175,5348 }, { 176,5348 }, { 177,5348 }, { 178,5348 }, { 179,5348 }, + + { 180,5348 }, { 181,5348 }, { 182,5348 }, { 183,5348 }, { 184,5348 }, + { 185,5348 }, { 186,5348 }, { 187,5348 }, { 188,5348 }, { 189,5348 }, + { 190,5348 }, { 191,5348 }, { 192,5348 }, { 193,5348 }, { 194,5348 }, + { 195,5348 }, { 196,5348 }, { 197,5348 }, { 198,5348 }, { 199,5348 }, + { 200,5348 }, { 201,5348 }, { 202,5348 }, { 203,5348 }, { 204,5348 }, + { 205,5348 }, { 206,5348 }, { 207,5348 }, { 208,5348 }, { 209,5348 }, + { 210,5348 }, { 211,5348 }, { 212,5348 }, { 213,5348 }, { 214,5348 }, + { 215,5348 }, { 216,5348 }, { 217,5348 }, { 218,5348 }, { 219,5348 }, + { 220,5348 }, { 221,5348 }, { 222,5348 }, { 223,5348 }, { 224,5348 }, + { 225,5348 }, { 226,5348 }, { 227,5348 }, { 228,5348 }, { 229,5348 }, + + { 230,5348 }, { 231,5348 }, { 232,5348 }, { 233,5348 }, { 234,5348 }, + { 235,5348 }, { 236,5348 }, { 237,5348 }, { 238,5348 }, { 239,5348 }, + { 240,5348 }, { 241,5348 }, { 242,5348 }, { 243,5348 }, { 244,5348 }, + { 245,5348 }, { 246,5348 }, { 247,5348 }, { 248,5348 }, { 249,5348 }, + { 250,5348 }, { 251,5348 }, { 252,5348 }, { 253,5348 }, { 254,5348 }, + { 255,5348 }, { 0, 56 }, { 0,58303 }, { 0, 0 }, { 0, 31 }, + { 0,58300 }, { 0, 39 }, { 0,58298 }, { 0, 54 }, { 0,58296 }, + { 0, 53 }, { 0,58294 }, { 0, 56 }, { 0,58292 }, { 0, 55 }, + { 0,58290 }, { 0, 8 }, { 0,58288 }, { 0, 20 }, { 0,58286 }, + { 0, 18 }, { 0,58284 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 56 }, { 0,58273 }, { 0, 0 }, { 0, 0 }, + { 33,5012 }, { 0, 0 }, { 35,5012 }, { 0, 0 }, { 37,5012 }, + { 38,5012 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 42,5012 }, + { 43,5012 }, { 33,5001 }, { 45,5012 }, { 35,5001 }, { 47,5012 }, + { 37,5001 }, { 38,5001 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 42,5001 }, { 43,5001 }, { 0, 0 }, { 45,5337 }, { 0, 0 }, + { 47,5001 }, { 0, 0 }, { 60,5012 }, { 61,5012 }, { 62,5012 }, + { 63,5012 }, { 64,5012 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 52 }, { 0,58233 }, { 60,5001 }, { 61,5001 }, + + { 62,5001 }, { 63,5001 }, { 64,5001 }, { 46, -23 }, { 0, 0 }, + { 48,5576 }, { 49,5576 }, { 50,5576 }, { 51,5576 }, { 52,5576 }, + { 53,5576 }, { 54,5576 }, { 55,5576 }, { 56,5576 }, { 57,5576 }, + { 85,8519 }, { 0, 15 }, { 0,58213 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 94,5012 }, { 0, 0 }, { 96,5012 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 56 }, { 0,58202 }, { 0, 59 }, + { 0,58200 }, { 34, 637 }, { 94,5001 }, { 0, 0 }, { 96,5001 }, + { 0, 0 }, { 39, 639 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 117,8591 }, { 0, 0 }, { 0, 10 }, + + { 0,58180 }, { 124,5012 }, { 0, 0 }, { 126,5012 }, { 0, 7 }, + { 0,58175 }, { 0, 4 }, { 0,58173 }, { 0, 50 }, { 0,58171 }, + { 0, 0 }, { 33,4911 }, { 124,5001 }, { 35,4911 }, { 126,5001 }, + { 37,4911 }, { 38,4911 }, { 0, 17 }, { 0,58162 }, { 0, 0 }, + { 42,5530 }, { 43,4911 }, { 0, 0 }, { 45,4911 }, { 0, 0 }, + { 47,4911 }, { 46,5530 }, { 0, 0 }, { 48,5594 }, { 49,5594 }, + { 50,5594 }, { 51,5594 }, { 52,5594 }, { 53,5594 }, { 54,5594 }, + { 55,5594 }, { 56,5594 }, { 57,5594 }, { 60,4911 }, { 61,4911 }, + { 62,4911 }, { 63,4911 }, { 64,4911 }, { 0, 65 }, { 0,58136 }, + { 45,9427 }, { 0, 0 }, { 42, 0 }, { 0, 0 }, { 69,5616 }, + + { 0, 26 }, { 0,58129 }, { 47, 2 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 23 }, { 0,58122 }, { 0, 34 }, + { 0,58120 }, { 0, 41 }, { 0,58118 }, { 45,9795 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 94,4911 }, { 0, 0 }, { 96,4911 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 36,5592 }, { 101,5616 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 48 }, + { 0,58090 }, { 0, 0 }, { 48,5592 }, { 49,5592 }, { 50,5592 }, + { 51,5592 }, { 52,5592 }, { 53,5592 }, { 54,5592 }, { 55,5592 }, + + { 56,5592 }, { 57,5592 }, { 124,4911 }, { 45,10060 }, { 126,4911 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 65,5592 }, + { 66,5592 }, { 67,5592 }, { 68,5592 }, { 69,5592 }, { 70,5592 }, + { 71,5592 }, { 72,5592 }, { 73,5592 }, { 74,5592 }, { 75,5592 }, + { 76,5592 }, { 77,5592 }, { 78,5592 }, { 79,5592 }, { 80,5592 }, + { 81,5592 }, { 82,5592 }, { 83,5592 }, { 84,5592 }, { 85,5592 }, + { 86,5592 }, { 87,5592 }, { 88,5592 }, { 89,5592 }, { 90,5592 }, + { 45,10684 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 95,5592 }, + { 0, 0 }, { 97,5592 }, { 98,5592 }, { 99,5592 }, { 100,5592 }, + { 101,5592 }, { 102,5592 }, { 103,5592 }, { 104,5592 }, { 105,5592 }, + + { 106,5592 }, { 107,5592 }, { 108,5592 }, { 109,5592 }, { 110,5592 }, + { 111,5592 }, { 112,5592 }, { 113,5592 }, { 114,5592 }, { 115,5592 }, + { 116,5592 }, { 117,5592 }, { 118,5592 }, { 119,5592 }, { 120,5592 }, + { 121,5592 }, { 122,5592 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 128,5592 }, { 129,5592 }, { 130,5592 }, + { 131,5592 }, { 132,5592 }, { 133,5592 }, { 134,5592 }, { 135,5592 }, + { 136,5592 }, { 137,5592 }, { 138,5592 }, { 139,5592 }, { 140,5592 }, + { 141,5592 }, { 142,5592 }, { 143,5592 }, { 144,5592 }, { 145,5592 }, + { 146,5592 }, { 147,5592 }, { 148,5592 }, { 149,5592 }, { 150,5592 }, + { 151,5592 }, { 152,5592 }, { 153,5592 }, { 154,5592 }, { 155,5592 }, + + { 156,5592 }, { 157,5592 }, { 158,5592 }, { 159,5592 }, { 160,5592 }, + { 161,5592 }, { 162,5592 }, { 163,5592 }, { 164,5592 }, { 165,5592 }, + { 166,5592 }, { 167,5592 }, { 168,5592 }, { 169,5592 }, { 170,5592 }, + { 171,5592 }, { 172,5592 }, { 173,5592 }, { 174,5592 }, { 175,5592 }, + { 176,5592 }, { 177,5592 }, { 178,5592 }, { 179,5592 }, { 180,5592 }, + { 181,5592 }, { 182,5592 }, { 183,5592 }, { 184,5592 }, { 185,5592 }, + { 186,5592 }, { 187,5592 }, { 188,5592 }, { 189,5592 }, { 190,5592 }, + { 191,5592 }, { 192,5592 }, { 193,5592 }, { 194,5592 }, { 195,5592 }, + { 196,5592 }, { 197,5592 }, { 198,5592 }, { 199,5592 }, { 200,5592 }, + { 201,5592 }, { 202,5592 }, { 203,5592 }, { 204,5592 }, { 205,5592 }, + + { 206,5592 }, { 207,5592 }, { 208,5592 }, { 209,5592 }, { 210,5592 }, + { 211,5592 }, { 212,5592 }, { 213,5592 }, { 214,5592 }, { 215,5592 }, + { 216,5592 }, { 217,5592 }, { 218,5592 }, { 219,5592 }, { 220,5592 }, + { 221,5592 }, { 222,5592 }, { 223,5592 }, { 224,5592 }, { 225,5592 }, + { 226,5592 }, { 227,5592 }, { 228,5592 }, { 229,5592 }, { 230,5592 }, + { 231,5592 }, { 232,5592 }, { 233,5592 }, { 234,5592 }, { 235,5592 }, + { 236,5592 }, { 237,5592 }, { 238,5592 }, { 239,5592 }, { 240,5592 }, + { 241,5592 }, { 242,5592 }, { 243,5592 }, { 244,5592 }, { 245,5592 }, + { 246,5592 }, { 247,5592 }, { 248,5592 }, { 249,5592 }, { 250,5592 }, + { 251,5592 }, { 252,5592 }, { 253,5592 }, { 254,5592 }, { 255,5592 }, + + { 0, 65 }, { 0,57879 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 48 }, { 0,57857 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 36,5335 }, { 0, 0 }, { 0, 0 }, + { 39,-409 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 24 }, { 0,57832 }, { 48,5335 }, + + { 49,5335 }, { 50,5335 }, { 51,5335 }, { 52,5335 }, { 53,5335 }, + { 54,5335 }, { 55,5335 }, { 56,5335 }, { 57,5335 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 65,5335 }, { 66,5335 }, { 67,5335 }, { 68,5335 }, + { 69,5335 }, { 70,5335 }, { 71,5335 }, { 72,5335 }, { 73,5335 }, + { 74,5335 }, { 75,5335 }, { 76,5335 }, { 77,5335 }, { 78,5335 }, + { 79,5335 }, { 80,5335 }, { 81,5335 }, { 82,5335 }, { 83,5335 }, + { 84,5335 }, { 85,5335 }, { 86,5335 }, { 87,5335 }, { 88,5335 }, + { 89,5335 }, { 90,5335 }, { 69, 757 }, { 45,10803 }, { 0, 0 }, + { 0, 0 }, { 95,5335 }, { 0, 0 }, { 97,5335 }, { 98,5335 }, + + { 99,5335 }, { 100,5335 }, { 101,5335 }, { 102,5335 }, { 103,5335 }, + { 104,5335 }, { 105,5335 }, { 106,5335 }, { 107,5335 }, { 108,5335 }, + { 109,5335 }, { 110,5335 }, { 111,5335 }, { 112,5335 }, { 113,5335 }, + { 114,5335 }, { 115,5335 }, { 116,5335 }, { 117,5335 }, { 118,5335 }, + { 119,5335 }, { 120,5335 }, { 121,5335 }, { 122,5335 }, { 101, 757 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 128,5335 }, + { 129,5335 }, { 130,5335 }, { 131,5335 }, { 132,5335 }, { 133,5335 }, + { 134,5335 }, { 135,5335 }, { 136,5335 }, { 137,5335 }, { 138,5335 }, + { 139,5335 }, { 140,5335 }, { 141,5335 }, { 142,5335 }, { 143,5335 }, + { 144,5335 }, { 145,5335 }, { 146,5335 }, { 147,5335 }, { 148,5335 }, + + { 149,5335 }, { 150,5335 }, { 151,5335 }, { 152,5335 }, { 153,5335 }, + { 154,5335 }, { 155,5335 }, { 156,5335 }, { 157,5335 }, { 158,5335 }, + { 159,5335 }, { 160,5335 }, { 161,5335 }, { 162,5335 }, { 163,5335 }, + { 164,5335 }, { 165,5335 }, { 166,5335 }, { 167,5335 }, { 168,5335 }, + { 169,5335 }, { 170,5335 }, { 171,5335 }, { 172,5335 }, { 173,5335 }, + { 174,5335 }, { 175,5335 }, { 176,5335 }, { 177,5335 }, { 178,5335 }, + { 179,5335 }, { 180,5335 }, { 181,5335 }, { 182,5335 }, { 183,5335 }, + { 184,5335 }, { 185,5335 }, { 186,5335 }, { 187,5335 }, { 188,5335 }, + { 189,5335 }, { 190,5335 }, { 191,5335 }, { 192,5335 }, { 193,5335 }, + { 194,5335 }, { 195,5335 }, { 196,5335 }, { 197,5335 }, { 198,5335 }, + + { 199,5335 }, { 200,5335 }, { 201,5335 }, { 202,5335 }, { 203,5335 }, + { 204,5335 }, { 205,5335 }, { 206,5335 }, { 207,5335 }, { 208,5335 }, + { 209,5335 }, { 210,5335 }, { 211,5335 }, { 212,5335 }, { 213,5335 }, + { 214,5335 }, { 215,5335 }, { 216,5335 }, { 217,5335 }, { 218,5335 }, + { 219,5335 }, { 220,5335 }, { 221,5335 }, { 222,5335 }, { 223,5335 }, + { 224,5335 }, { 225,5335 }, { 226,5335 }, { 227,5335 }, { 228,5335 }, + { 229,5335 }, { 230,5335 }, { 231,5335 }, { 232,5335 }, { 233,5335 }, + { 234,5335 }, { 235,5335 }, { 236,5335 }, { 237,5335 }, { 238,5335 }, + { 239,5335 }, { 240,5335 }, { 241,5335 }, { 242,5335 }, { 243,5335 }, + { 244,5335 }, { 245,5335 }, { 246,5335 }, { 247,5335 }, { 248,5335 }, + + { 249,5335 }, { 250,5335 }, { 251,5335 }, { 252,5335 }, { 253,5335 }, + { 254,5335 }, { 255,5335 }, { 0, 65 }, { 0,57622 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 24 }, + { 0,57600 }, { 0, 61 }, { 0,57598 }, { 0, 46 }, { 0,57596 }, + { 0, 21 }, { 0,57594 }, { 0, 14 }, { 0,57592 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 36,5078 }, + { 0, 0 }, { 0, 0 }, { 39,-664 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 10 }, + { 0,57575 }, { 48,5078 }, { 49,5078 }, { 50,5078 }, { 51,5078 }, + { 52,5078 }, { 53,5078 }, { 54,5078 }, { 55,5078 }, { 56,5078 }, + { 57,5078 }, { 0, 13 }, { 0,57563 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 65,5078 }, { 66,5078 }, + { 67,5078 }, { 68,5078 }, { 69,5078 }, { 70,5078 }, { 71,5078 }, + { 72,5078 }, { 73,5078 }, { 74,5078 }, { 75,5078 }, { 76,5078 }, + { 77,5078 }, { 78,5078 }, { 79,5078 }, { 80,5078 }, { 81,5078 }, + { 82,5078 }, { 83,5078 }, { 84,5078 }, { 85,5078 }, { 86,5078 }, + { 87,5078 }, { 88,5078 }, { 89,5078 }, { 90,5078 }, { 69, 757 }, + + { 45,10931 }, { 0, 0 }, { 0, 0 }, { 95,5078 }, { 0, 0 }, + { 97,5078 }, { 98,5078 }, { 99,5078 }, { 100,5078 }, { 101,5078 }, + { 102,5078 }, { 103,5078 }, { 104,5078 }, { 105,5078 }, { 106,5078 }, + { 107,5078 }, { 108,5078 }, { 109,5078 }, { 110,5078 }, { 111,5078 }, + { 112,5078 }, { 113,5078 }, { 114,5078 }, { 115,5078 }, { 116,5078 }, + { 117,5078 }, { 118,5078 }, { 119,5078 }, { 120,5078 }, { 121,5078 }, + { 122,5078 }, { 101, 757 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 128,5078 }, { 129,5078 }, { 130,5078 }, { 131,5078 }, + { 132,5078 }, { 133,5078 }, { 134,5078 }, { 135,5078 }, { 136,5078 }, + { 137,5078 }, { 138,5078 }, { 139,5078 }, { 140,5078 }, { 141,5078 }, + + { 142,5078 }, { 143,5078 }, { 144,5078 }, { 145,5078 }, { 146,5078 }, + { 147,5078 }, { 148,5078 }, { 149,5078 }, { 150,5078 }, { 151,5078 }, + { 152,5078 }, { 153,5078 }, { 154,5078 }, { 155,5078 }, { 156,5078 }, + { 157,5078 }, { 158,5078 }, { 159,5078 }, { 160,5078 }, { 161,5078 }, + { 162,5078 }, { 163,5078 }, { 164,5078 }, { 165,5078 }, { 166,5078 }, + { 167,5078 }, { 168,5078 }, { 169,5078 }, { 170,5078 }, { 171,5078 }, + { 172,5078 }, { 173,5078 }, { 174,5078 }, { 175,5078 }, { 176,5078 }, + { 177,5078 }, { 178,5078 }, { 179,5078 }, { 180,5078 }, { 181,5078 }, + { 182,5078 }, { 183,5078 }, { 184,5078 }, { 185,5078 }, { 186,5078 }, + { 187,5078 }, { 188,5078 }, { 189,5078 }, { 190,5078 }, { 191,5078 }, + + { 192,5078 }, { 193,5078 }, { 194,5078 }, { 195,5078 }, { 196,5078 }, + { 197,5078 }, { 198,5078 }, { 199,5078 }, { 200,5078 }, { 201,5078 }, + { 202,5078 }, { 203,5078 }, { 204,5078 }, { 205,5078 }, { 206,5078 }, + { 207,5078 }, { 208,5078 }, { 209,5078 }, { 210,5078 }, { 211,5078 }, + { 212,5078 }, { 213,5078 }, { 214,5078 }, { 215,5078 }, { 216,5078 }, + { 217,5078 }, { 218,5078 }, { 219,5078 }, { 220,5078 }, { 221,5078 }, + { 222,5078 }, { 223,5078 }, { 224,5078 }, { 225,5078 }, { 226,5078 }, + { 227,5078 }, { 228,5078 }, { 229,5078 }, { 230,5078 }, { 231,5078 }, + { 232,5078 }, { 233,5078 }, { 234,5078 }, { 235,5078 }, { 236,5078 }, + { 237,5078 }, { 238,5078 }, { 239,5078 }, { 240,5078 }, { 241,5078 }, + + { 242,5078 }, { 243,5078 }, { 244,5078 }, { 245,5078 }, { 246,5078 }, + { 247,5078 }, { 248,5078 }, { 249,5078 }, { 250,5078 }, { 251,5078 }, + { 252,5078 }, { 253,5078 }, { 254,5078 }, { 255,5078 }, { 0, 65 }, + { 0,57365 }, { 0, 17 }, { 0,57363 }, { 0, 37 }, { 0,57361 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 23 }, { 0,57352 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 36,4821 }, { 0, 0 }, { 0, 0 }, { 39,-919 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 45,11751 }, { 48,4821 }, { 49,4821 }, + { 50,4821 }, { 51,4821 }, { 52,4821 }, { 53,4821 }, { 54,4821 }, + { 55,4821 }, { 56,4821 }, { 57,4821 }, { 45,12772 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 65,4821 }, { 66,4821 }, { 67,4821 }, { 68,4821 }, { 69,4821 }, + { 70,4821 }, { 71,4821 }, { 72,4821 }, { 73,4821 }, { 74,4821 }, + { 75,4821 }, { 76,4821 }, { 77,4821 }, { 78,4821 }, { 79,4821 }, + { 80,4821 }, { 81,4821 }, { 82,4821 }, { 83,4821 }, { 84,4821 }, + + { 85,4821 }, { 86,4821 }, { 87,4821 }, { 88,4821 }, { 89,4821 }, + { 90,4821 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 95,4821 }, { 0, 0 }, { 97,4821 }, { 98,4821 }, { 99,4821 }, + { 100,4821 }, { 101,4821 }, { 102,4821 }, { 103,4821 }, { 104,4821 }, + { 105,4821 }, { 106,4821 }, { 107,4821 }, { 108,4821 }, { 109,4821 }, + { 110,4821 }, { 111,4821 }, { 112,4821 }, { 113,4821 }, { 114,4821 }, + { 115,4821 }, { 116,4821 }, { 117,4821 }, { 118,4821 }, { 119,4821 }, + { 120,4821 }, { 121,4821 }, { 122,4821 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 128,4821 }, { 129,4821 }, + { 130,4821 }, { 131,4821 }, { 132,4821 }, { 133,4821 }, { 134,4821 }, + + { 135,4821 }, { 136,4821 }, { 137,4821 }, { 138,4821 }, { 139,4821 }, + { 140,4821 }, { 141,4821 }, { 142,4821 }, { 143,4821 }, { 144,4821 }, + { 145,4821 }, { 146,4821 }, { 147,4821 }, { 148,4821 }, { 149,4821 }, + { 150,4821 }, { 151,4821 }, { 152,4821 }, { 153,4821 }, { 154,4821 }, + { 155,4821 }, { 156,4821 }, { 157,4821 }, { 158,4821 }, { 159,4821 }, + { 160,4821 }, { 161,4821 }, { 162,4821 }, { 163,4821 }, { 164,4821 }, + { 165,4821 }, { 166,4821 }, { 167,4821 }, { 168,4821 }, { 169,4821 }, + { 170,4821 }, { 171,4821 }, { 172,4821 }, { 173,4821 }, { 174,4821 }, + { 175,4821 }, { 176,4821 }, { 177,4821 }, { 178,4821 }, { 179,4821 }, + { 180,4821 }, { 181,4821 }, { 182,4821 }, { 183,4821 }, { 184,4821 }, + + { 185,4821 }, { 186,4821 }, { 187,4821 }, { 188,4821 }, { 189,4821 }, + { 190,4821 }, { 191,4821 }, { 192,4821 }, { 193,4821 }, { 194,4821 }, + { 195,4821 }, { 196,4821 }, { 197,4821 }, { 198,4821 }, { 199,4821 }, + { 200,4821 }, { 201,4821 }, { 202,4821 }, { 203,4821 }, { 204,4821 }, + { 205,4821 }, { 206,4821 }, { 207,4821 }, { 208,4821 }, { 209,4821 }, + { 210,4821 }, { 211,4821 }, { 212,4821 }, { 213,4821 }, { 214,4821 }, + { 215,4821 }, { 216,4821 }, { 217,4821 }, { 218,4821 }, { 219,4821 }, + { 220,4821 }, { 221,4821 }, { 222,4821 }, { 223,4821 }, { 224,4821 }, + { 225,4821 }, { 226,4821 }, { 227,4821 }, { 228,4821 }, { 229,4821 }, + { 230,4821 }, { 231,4821 }, { 232,4821 }, { 233,4821 }, { 234,4821 }, + + { 235,4821 }, { 236,4821 }, { 237,4821 }, { 238,4821 }, { 239,4821 }, + { 240,4821 }, { 241,4821 }, { 242,4821 }, { 243,4821 }, { 244,4821 }, + { 245,4821 }, { 246,4821 }, { 247,4821 }, { 248,4821 }, { 249,4821 }, + { 250,4821 }, { 251,4821 }, { 252,4821 }, { 253,4821 }, { 254,4821 }, + { 255,4821 }, { 0, 65 }, { 0,57108 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 48 }, + { 0,57100 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 24 }, + { 0,57095 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 36,4564 }, { 0, 0 }, + { 38,-1125 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 48,4564 }, { 49,4564 }, { 50,4564 }, { 51,4564 }, { 52,4564 }, + { 53,4564 }, { 54,4564 }, { 55,4564 }, { 56,4564 }, { 57,4564 }, + { 45,14706 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 65,4564 }, { 66,4564 }, { 67,4564 }, + { 68,4564 }, { 69,4564 }, { 70,4564 }, { 71,4564 }, { 72,4564 }, + { 73,4564 }, { 74,4564 }, { 75,4564 }, { 76,4564 }, { 77,4564 }, + + { 78,4564 }, { 79,4564 }, { 80,4564 }, { 81,4564 }, { 82,4564 }, + { 83,4564 }, { 84,4564 }, { 85,4564 }, { 86,4564 }, { 87,4564 }, + { 88,4564 }, { 89,4564 }, { 90,4564 }, { 83, 274 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 95,4564 }, { 0, 0 }, { 97,4564 }, + { 98,4564 }, { 99,4564 }, { 100,4564 }, { 101,4564 }, { 102,4564 }, + { 103,4564 }, { 104,4564 }, { 105,4564 }, { 106,4564 }, { 107,4564 }, + { 108,4564 }, { 109,4564 }, { 110,4564 }, { 111,4564 }, { 112,4564 }, + { 113,4564 }, { 114,4564 }, { 115,4564 }, { 116,4564 }, { 117,4564 }, + { 118,4564 }, { 119,4564 }, { 120,4564 }, { 121,4564 }, { 122,4564 }, + { 115, 274 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 128,4564 }, { 129,4564 }, { 130,4564 }, { 131,4564 }, { 132,4564 }, + { 133,4564 }, { 134,4564 }, { 135,4564 }, { 136,4564 }, { 137,4564 }, + { 138,4564 }, { 139,4564 }, { 140,4564 }, { 141,4564 }, { 142,4564 }, + { 143,4564 }, { 144,4564 }, { 145,4564 }, { 146,4564 }, { 147,4564 }, + { 148,4564 }, { 149,4564 }, { 150,4564 }, { 151,4564 }, { 152,4564 }, + { 153,4564 }, { 154,4564 }, { 155,4564 }, { 156,4564 }, { 157,4564 }, + { 158,4564 }, { 159,4564 }, { 160,4564 }, { 161,4564 }, { 162,4564 }, + { 163,4564 }, { 164,4564 }, { 165,4564 }, { 166,4564 }, { 167,4564 }, + { 168,4564 }, { 169,4564 }, { 170,4564 }, { 171,4564 }, { 172,4564 }, + { 173,4564 }, { 174,4564 }, { 175,4564 }, { 176,4564 }, { 177,4564 }, + + { 178,4564 }, { 179,4564 }, { 180,4564 }, { 181,4564 }, { 182,4564 }, + { 183,4564 }, { 184,4564 }, { 185,4564 }, { 186,4564 }, { 187,4564 }, + { 188,4564 }, { 189,4564 }, { 190,4564 }, { 191,4564 }, { 192,4564 }, + { 193,4564 }, { 194,4564 }, { 195,4564 }, { 196,4564 }, { 197,4564 }, + { 198,4564 }, { 199,4564 }, { 200,4564 }, { 201,4564 }, { 202,4564 }, + { 203,4564 }, { 204,4564 }, { 205,4564 }, { 206,4564 }, { 207,4564 }, + { 208,4564 }, { 209,4564 }, { 210,4564 }, { 211,4564 }, { 212,4564 }, + { 213,4564 }, { 214,4564 }, { 215,4564 }, { 216,4564 }, { 217,4564 }, + { 218,4564 }, { 219,4564 }, { 220,4564 }, { 221,4564 }, { 222,4564 }, + { 223,4564 }, { 224,4564 }, { 225,4564 }, { 226,4564 }, { 227,4564 }, + + { 228,4564 }, { 229,4564 }, { 230,4564 }, { 231,4564 }, { 232,4564 }, + { 233,4564 }, { 234,4564 }, { 235,4564 }, { 236,4564 }, { 237,4564 }, + { 238,4564 }, { 239,4564 }, { 240,4564 }, { 241,4564 }, { 242,4564 }, + { 243,4564 }, { 244,4564 }, { 245,4564 }, { 246,4564 }, { 247,4564 }, + { 248,4564 }, { 249,4564 }, { 250,4564 }, { 251,4564 }, { 252,4564 }, + { 253,4564 }, { 254,4564 }, { 255,4564 }, { 0, 65 }, { 0,56851 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 24 }, { 0,56843 }, { 0, 35 }, { 0,56841 }, + { 0, 36 }, { 0,56839 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 48 }, { 0,56826 }, + { 0, 24 }, { 0,56824 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 36,4307 }, { 0, 0 }, { 0, 0 }, { 39,-1362 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 48,4307 }, { 49,4307 }, { 50,4307 }, + { 51,4307 }, { 52,4307 }, { 53,4307 }, { 54,4307 }, { 55,4307 }, + { 56,4307 }, { 57,4307 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 65,4307 }, + { 66,4307 }, { 67,4307 }, { 68,4307 }, { 69,4307 }, { 70,4307 }, + + { 71,4307 }, { 72,4307 }, { 73,4307 }, { 74,4307 }, { 75,4307 }, + { 76,4307 }, { 77,4307 }, { 78,4307 }, { 79,4307 }, { 80,4307 }, + { 81,4307 }, { 82,4307 }, { 83,4307 }, { 84,4307 }, { 85,4307 }, + { 86,4307 }, { 87,4307 }, { 88,4307 }, { 89,4307 }, { 90,4307 }, + { 83, 19 }, { 67,3285 }, { 0, 0 }, { 67,3285 }, { 95,4307 }, + { 0, 0 }, { 97,4307 }, { 98,4307 }, { 99,4307 }, { 100,4307 }, + { 101,4307 }, { 102,4307 }, { 103,4307 }, { 104,4307 }, { 105,4307 }, + { 106,4307 }, { 107,4307 }, { 108,4307 }, { 109,4307 }, { 110,4307 }, + { 111,4307 }, { 112,4307 }, { 113,4307 }, { 114,4307 }, { 115,4307 }, + { 116,4307 }, { 117,4307 }, { 118,4307 }, { 119,4307 }, { 120,4307 }, + + { 121,4307 }, { 122,4307 }, { 115, 19 }, { 99,3285 }, { 0, 0 }, + { 99,3285 }, { 0, 0 }, { 128,4307 }, { 129,4307 }, { 130,4307 }, + { 131,4307 }, { 132,4307 }, { 133,4307 }, { 134,4307 }, { 135,4307 }, + { 136,4307 }, { 137,4307 }, { 138,4307 }, { 139,4307 }, { 140,4307 }, + { 141,4307 }, { 142,4307 }, { 143,4307 }, { 144,4307 }, { 145,4307 }, + { 146,4307 }, { 147,4307 }, { 148,4307 }, { 149,4307 }, { 150,4307 }, + { 151,4307 }, { 152,4307 }, { 153,4307 }, { 154,4307 }, { 155,4307 }, + { 156,4307 }, { 157,4307 }, { 158,4307 }, { 159,4307 }, { 160,4307 }, + { 161,4307 }, { 162,4307 }, { 163,4307 }, { 164,4307 }, { 165,4307 }, + { 166,4307 }, { 167,4307 }, { 168,4307 }, { 169,4307 }, { 170,4307 }, + + { 171,4307 }, { 172,4307 }, { 173,4307 }, { 174,4307 }, { 175,4307 }, + { 176,4307 }, { 177,4307 }, { 178,4307 }, { 179,4307 }, { 180,4307 }, + { 181,4307 }, { 182,4307 }, { 183,4307 }, { 184,4307 }, { 185,4307 }, + { 186,4307 }, { 187,4307 }, { 188,4307 }, { 189,4307 }, { 190,4307 }, + { 191,4307 }, { 192,4307 }, { 193,4307 }, { 194,4307 }, { 195,4307 }, + { 196,4307 }, { 197,4307 }, { 198,4307 }, { 199,4307 }, { 200,4307 }, + { 201,4307 }, { 202,4307 }, { 203,4307 }, { 204,4307 }, { 205,4307 }, + { 206,4307 }, { 207,4307 }, { 208,4307 }, { 209,4307 }, { 210,4307 }, + { 211,4307 }, { 212,4307 }, { 213,4307 }, { 214,4307 }, { 215,4307 }, + { 216,4307 }, { 217,4307 }, { 218,4307 }, { 219,4307 }, { 220,4307 }, + + { 221,4307 }, { 222,4307 }, { 223,4307 }, { 224,4307 }, { 225,4307 }, + { 226,4307 }, { 227,4307 }, { 228,4307 }, { 229,4307 }, { 230,4307 }, + { 231,4307 }, { 232,4307 }, { 233,4307 }, { 234,4307 }, { 235,4307 }, + { 236,4307 }, { 237,4307 }, { 238,4307 }, { 239,4307 }, { 240,4307 }, + { 241,4307 }, { 242,4307 }, { 243,4307 }, { 244,4307 }, { 245,4307 }, + { 246,4307 }, { 247,4307 }, { 248,4307 }, { 249,4307 }, { 250,4307 }, + { 251,4307 }, { 252,4307 }, { 253,4307 }, { 254,4307 }, { 255,4307 }, + { 0, 12 }, { 0,56594 }, { 1,4307 }, { 2,4307 }, { 3,4307 }, + { 4,4307 }, { 5,4307 }, { 6,4307 }, { 7,4307 }, { 8,4307 }, + { 9,4307 }, { 10,4307 }, { 11,4307 }, { 12,4307 }, { 13,4307 }, + + { 14,4307 }, { 15,4307 }, { 16,4307 }, { 17,4307 }, { 18,4307 }, + { 19,4307 }, { 20,4307 }, { 21,4307 }, { 22,4307 }, { 23,4307 }, + { 24,4307 }, { 25,4307 }, { 26,4307 }, { 27,4307 }, { 28,4307 }, + { 29,4307 }, { 30,4307 }, { 31,4307 }, { 32,4307 }, { 33,4307 }, + { 34,4307 }, { 35,4307 }, { 36,4307 }, { 37,4307 }, { 38,4307 }, + { 0, 0 }, { 40,4307 }, { 41,4307 }, { 42,4307 }, { 43,4307 }, + { 44,4307 }, { 45,4307 }, { 46,4307 }, { 47,4307 }, { 48,4307 }, + { 49,4307 }, { 50,4307 }, { 51,4307 }, { 52,4307 }, { 53,4307 }, + { 54,4307 }, { 55,4307 }, { 56,4307 }, { 57,4307 }, { 58,4307 }, + { 59,4307 }, { 60,4307 }, { 61,4307 }, { 62,4307 }, { 63,4307 }, + + { 64,4307 }, { 65,4307 }, { 66,4307 }, { 67,4307 }, { 68,4307 }, + { 69,4307 }, { 70,4307 }, { 71,4307 }, { 72,4307 }, { 73,4307 }, + { 74,4307 }, { 75,4307 }, { 76,4307 }, { 77,4307 }, { 78,4307 }, + { 79,4307 }, { 80,4307 }, { 81,4307 }, { 82,4307 }, { 83,4307 }, + { 84,4307 }, { 85,4307 }, { 86,4307 }, { 87,4307 }, { 88,4307 }, + { 89,4307 }, { 90,4307 }, { 91,4307 }, { 92,4307 }, { 93,4307 }, + { 94,4307 }, { 95,4307 }, { 96,4307 }, { 97,4307 }, { 98,4307 }, + { 99,4307 }, { 100,4307 }, { 101,4307 }, { 102,4307 }, { 103,4307 }, + { 104,4307 }, { 105,4307 }, { 106,4307 }, { 107,4307 }, { 108,4307 }, + { 109,4307 }, { 110,4307 }, { 111,4307 }, { 112,4307 }, { 113,4307 }, + + { 114,4307 }, { 115,4307 }, { 116,4307 }, { 117,4307 }, { 118,4307 }, + { 119,4307 }, { 120,4307 }, { 121,4307 }, { 122,4307 }, { 123,4307 }, + { 124,4307 }, { 125,4307 }, { 126,4307 }, { 127,4307 }, { 128,4307 }, + { 129,4307 }, { 130,4307 }, { 131,4307 }, { 132,4307 }, { 133,4307 }, + { 134,4307 }, { 135,4307 }, { 136,4307 }, { 137,4307 }, { 138,4307 }, + { 139,4307 }, { 140,4307 }, { 141,4307 }, { 142,4307 }, { 143,4307 }, + { 144,4307 }, { 145,4307 }, { 146,4307 }, { 147,4307 }, { 148,4307 }, + { 149,4307 }, { 150,4307 }, { 151,4307 }, { 152,4307 }, { 153,4307 }, + { 154,4307 }, { 155,4307 }, { 156,4307 }, { 157,4307 }, { 158,4307 }, + { 159,4307 }, { 160,4307 }, { 161,4307 }, { 162,4307 }, { 163,4307 }, + + { 164,4307 }, { 165,4307 }, { 166,4307 }, { 167,4307 }, { 168,4307 }, + { 169,4307 }, { 170,4307 }, { 171,4307 }, { 172,4307 }, { 173,4307 }, + { 174,4307 }, { 175,4307 }, { 176,4307 }, { 177,4307 }, { 178,4307 }, + { 179,4307 }, { 180,4307 }, { 181,4307 }, { 182,4307 }, { 183,4307 }, + { 184,4307 }, { 185,4307 }, { 186,4307 }, { 187,4307 }, { 188,4307 }, + { 189,4307 }, { 190,4307 }, { 191,4307 }, { 192,4307 }, { 193,4307 }, + { 194,4307 }, { 195,4307 }, { 196,4307 }, { 197,4307 }, { 198,4307 }, + { 199,4307 }, { 200,4307 }, { 201,4307 }, { 202,4307 }, { 203,4307 }, + { 204,4307 }, { 205,4307 }, { 206,4307 }, { 207,4307 }, { 208,4307 }, + { 209,4307 }, { 210,4307 }, { 211,4307 }, { 212,4307 }, { 213,4307 }, + + { 214,4307 }, { 215,4307 }, { 216,4307 }, { 217,4307 }, { 218,4307 }, + { 219,4307 }, { 220,4307 }, { 221,4307 }, { 222,4307 }, { 223,4307 }, + { 224,4307 }, { 225,4307 }, { 226,4307 }, { 227,4307 }, { 228,4307 }, + { 229,4307 }, { 230,4307 }, { 231,4307 }, { 232,4307 }, { 233,4307 }, + { 234,4307 }, { 235,4307 }, { 236,4307 }, { 237,4307 }, { 238,4307 }, + { 239,4307 }, { 240,4307 }, { 241,4307 }, { 242,4307 }, { 243,4307 }, + { 244,4307 }, { 245,4307 }, { 246,4307 }, { 247,4307 }, { 248,4307 }, + { 249,4307 }, { 250,4307 }, { 251,4307 }, { 252,4307 }, { 253,4307 }, + { 254,4307 }, { 255,4307 }, { 256,4307 }, { 0, 9 }, { 0,56336 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 9,4307 }, { 10,4312 }, + { 0, 0 }, { 12,4307 }, { 13,4312 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 32,4307 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 45,-1844 }, + { 0, 5 }, { 0,56289 }, { 1,4312 }, { 2,4312 }, { 3,4312 }, + { 4,4312 }, { 5,4312 }, { 6,4312 }, { 7,4312 }, { 8,4312 }, + + { 9,4312 }, { 10,4312 }, { 11,4312 }, { 12,4312 }, { 13,4312 }, + { 14,4312 }, { 15,4312 }, { 16,4312 }, { 17,4312 }, { 18,4312 }, + { 19,4312 }, { 20,4312 }, { 21,4312 }, { 22,4312 }, { 23,4312 }, + { 24,4312 }, { 25,4312 }, { 26,4312 }, { 27,4312 }, { 28,4312 }, + { 29,4312 }, { 30,4312 }, { 31,4312 }, { 32,4312 }, { 33,4312 }, + { 34,4312 }, { 35,4312 }, { 36,4312 }, { 37,4312 }, { 38,4312 }, + { 39,4312 }, { 40,4312 }, { 41,4312 }, { 0, 0 }, { 43,4312 }, + { 44,4312 }, { 45,4312 }, { 46,4312 }, { 0, 0 }, { 48,4312 }, + { 49,4312 }, { 50,4312 }, { 51,4312 }, { 52,4312 }, { 53,4312 }, + { 54,4312 }, { 55,4312 }, { 56,4312 }, { 57,4312 }, { 58,4312 }, + + { 59,4312 }, { 60,4312 }, { 61,4312 }, { 62,4312 }, { 63,4312 }, + { 64,4312 }, { 65,4312 }, { 66,4312 }, { 67,4312 }, { 68,4312 }, + { 69,4312 }, { 70,4312 }, { 71,4312 }, { 72,4312 }, { 73,4312 }, + { 74,4312 }, { 75,4312 }, { 76,4312 }, { 77,4312 }, { 78,4312 }, + { 79,4312 }, { 80,4312 }, { 81,4312 }, { 82,4312 }, { 83,4312 }, + { 84,4312 }, { 85,4312 }, { 86,4312 }, { 87,4312 }, { 88,4312 }, + { 89,4312 }, { 90,4312 }, { 91,4312 }, { 92,4312 }, { 93,4312 }, + { 94,4312 }, { 95,4312 }, { 96,4312 }, { 97,4312 }, { 98,4312 }, + { 99,4312 }, { 100,4312 }, { 101,4312 }, { 102,4312 }, { 103,4312 }, + { 104,4312 }, { 105,4312 }, { 106,4312 }, { 107,4312 }, { 108,4312 }, + + { 109,4312 }, { 110,4312 }, { 111,4312 }, { 112,4312 }, { 113,4312 }, + { 114,4312 }, { 115,4312 }, { 116,4312 }, { 117,4312 }, { 118,4312 }, + { 119,4312 }, { 120,4312 }, { 121,4312 }, { 122,4312 }, { 123,4312 }, + { 124,4312 }, { 125,4312 }, { 126,4312 }, { 127,4312 }, { 128,4312 }, + { 129,4312 }, { 130,4312 }, { 131,4312 }, { 132,4312 }, { 133,4312 }, + { 134,4312 }, { 135,4312 }, { 136,4312 }, { 137,4312 }, { 138,4312 }, + { 139,4312 }, { 140,4312 }, { 141,4312 }, { 142,4312 }, { 143,4312 }, + { 144,4312 }, { 145,4312 }, { 146,4312 }, { 147,4312 }, { 148,4312 }, + { 149,4312 }, { 150,4312 }, { 151,4312 }, { 152,4312 }, { 153,4312 }, + { 154,4312 }, { 155,4312 }, { 156,4312 }, { 157,4312 }, { 158,4312 }, + + { 159,4312 }, { 160,4312 }, { 161,4312 }, { 162,4312 }, { 163,4312 }, + { 164,4312 }, { 165,4312 }, { 166,4312 }, { 167,4312 }, { 168,4312 }, + { 169,4312 }, { 170,4312 }, { 171,4312 }, { 172,4312 }, { 173,4312 }, + { 174,4312 }, { 175,4312 }, { 176,4312 }, { 177,4312 }, { 178,4312 }, + { 179,4312 }, { 180,4312 }, { 181,4312 }, { 182,4312 }, { 183,4312 }, + { 184,4312 }, { 185,4312 }, { 186,4312 }, { 187,4312 }, { 188,4312 }, + { 189,4312 }, { 190,4312 }, { 191,4312 }, { 192,4312 }, { 193,4312 }, + { 194,4312 }, { 195,4312 }, { 196,4312 }, { 197,4312 }, { 198,4312 }, + { 199,4312 }, { 200,4312 }, { 201,4312 }, { 202,4312 }, { 203,4312 }, + { 204,4312 }, { 205,4312 }, { 206,4312 }, { 207,4312 }, { 208,4312 }, + + { 209,4312 }, { 210,4312 }, { 211,4312 }, { 212,4312 }, { 213,4312 }, + { 214,4312 }, { 215,4312 }, { 216,4312 }, { 217,4312 }, { 218,4312 }, + { 219,4312 }, { 220,4312 }, { 221,4312 }, { 222,4312 }, { 223,4312 }, + { 224,4312 }, { 225,4312 }, { 226,4312 }, { 227,4312 }, { 228,4312 }, + { 229,4312 }, { 230,4312 }, { 231,4312 }, { 232,4312 }, { 233,4312 }, + { 234,4312 }, { 235,4312 }, { 236,4312 }, { 237,4312 }, { 238,4312 }, + { 239,4312 }, { 240,4312 }, { 241,4312 }, { 242,4312 }, { 243,4312 }, + { 244,4312 }, { 245,4312 }, { 246,4312 }, { 247,4312 }, { 248,4312 }, + { 249,4312 }, { 250,4312 }, { 251,4312 }, { 252,4312 }, { 253,4312 }, + { 254,4312 }, { 255,4312 }, { 256,4312 }, { 0, 5 }, { 0,56031 }, + + { 1,4054 }, { 2,4054 }, { 3,4054 }, { 4,4054 }, { 5,4054 }, + { 6,4054 }, { 7,4054 }, { 8,4054 }, { 9,4054 }, { 10,4054 }, + { 11,4054 }, { 12,4054 }, { 13,4054 }, { 14,4054 }, { 15,4054 }, + { 16,4054 }, { 17,4054 }, { 18,4054 }, { 19,4054 }, { 20,4054 }, + { 21,4054 }, { 22,4054 }, { 23,4054 }, { 24,4054 }, { 25,4054 }, + { 26,4054 }, { 27,4054 }, { 28,4054 }, { 29,4054 }, { 30,4054 }, + { 31,4054 }, { 32,4054 }, { 33,4054 }, { 34,4054 }, { 35,4054 }, + { 36,4054 }, { 37,4054 }, { 38,4054 }, { 39,4054 }, { 40,4054 }, + { 41,4054 }, { 0, 0 }, { 43,4054 }, { 44,4054 }, { 45,4054 }, + { 46,4054 }, { 0, 0 }, { 48,4054 }, { 49,4054 }, { 50,4054 }, + + { 51,4054 }, { 52,4054 }, { 53,4054 }, { 54,4054 }, { 55,4054 }, + { 56,4054 }, { 57,4054 }, { 58,4054 }, { 59,4054 }, { 60,4054 }, + { 61,4054 }, { 62,4054 }, { 63,4054 }, { 64,4054 }, { 65,4054 }, + { 66,4054 }, { 67,4054 }, { 68,4054 }, { 69,4054 }, { 70,4054 }, + { 71,4054 }, { 72,4054 }, { 73,4054 }, { 74,4054 }, { 75,4054 }, + { 76,4054 }, { 77,4054 }, { 78,4054 }, { 79,4054 }, { 80,4054 }, + { 81,4054 }, { 82,4054 }, { 83,4054 }, { 84,4054 }, { 85,4054 }, + { 86,4054 }, { 87,4054 }, { 88,4054 }, { 89,4054 }, { 90,4054 }, + { 91,4054 }, { 92,4054 }, { 93,4054 }, { 94,4054 }, { 95,4054 }, + { 96,4054 }, { 97,4054 }, { 98,4054 }, { 99,4054 }, { 100,4054 }, + + { 101,4054 }, { 102,4054 }, { 103,4054 }, { 104,4054 }, { 105,4054 }, + { 106,4054 }, { 107,4054 }, { 108,4054 }, { 109,4054 }, { 110,4054 }, + { 111,4054 }, { 112,4054 }, { 113,4054 }, { 114,4054 }, { 115,4054 }, + { 116,4054 }, { 117,4054 }, { 118,4054 }, { 119,4054 }, { 120,4054 }, + { 121,4054 }, { 122,4054 }, { 123,4054 }, { 124,4054 }, { 125,4054 }, + { 126,4054 }, { 127,4054 }, { 128,4054 }, { 129,4054 }, { 130,4054 }, + { 131,4054 }, { 132,4054 }, { 133,4054 }, { 134,4054 }, { 135,4054 }, + { 136,4054 }, { 137,4054 }, { 138,4054 }, { 139,4054 }, { 140,4054 }, + { 141,4054 }, { 142,4054 }, { 143,4054 }, { 144,4054 }, { 145,4054 }, + { 146,4054 }, { 147,4054 }, { 148,4054 }, { 149,4054 }, { 150,4054 }, + + { 151,4054 }, { 152,4054 }, { 153,4054 }, { 154,4054 }, { 155,4054 }, + { 156,4054 }, { 157,4054 }, { 158,4054 }, { 159,4054 }, { 160,4054 }, + { 161,4054 }, { 162,4054 }, { 163,4054 }, { 164,4054 }, { 165,4054 }, + { 166,4054 }, { 167,4054 }, { 168,4054 }, { 169,4054 }, { 170,4054 }, + { 171,4054 }, { 172,4054 }, { 173,4054 }, { 174,4054 }, { 175,4054 }, + { 176,4054 }, { 177,4054 }, { 178,4054 }, { 179,4054 }, { 180,4054 }, + { 181,4054 }, { 182,4054 }, { 183,4054 }, { 184,4054 }, { 185,4054 }, + { 186,4054 }, { 187,4054 }, { 188,4054 }, { 189,4054 }, { 190,4054 }, + { 191,4054 }, { 192,4054 }, { 193,4054 }, { 194,4054 }, { 195,4054 }, + { 196,4054 }, { 197,4054 }, { 198,4054 }, { 199,4054 }, { 200,4054 }, + + { 201,4054 }, { 202,4054 }, { 203,4054 }, { 204,4054 }, { 205,4054 }, + { 206,4054 }, { 207,4054 }, { 208,4054 }, { 209,4054 }, { 210,4054 }, + { 211,4054 }, { 212,4054 }, { 213,4054 }, { 214,4054 }, { 215,4054 }, + { 216,4054 }, { 217,4054 }, { 218,4054 }, { 219,4054 }, { 220,4054 }, + { 221,4054 }, { 222,4054 }, { 223,4054 }, { 224,4054 }, { 225,4054 }, + { 226,4054 }, { 227,4054 }, { 228,4054 }, { 229,4054 }, { 230,4054 }, + { 231,4054 }, { 232,4054 }, { 233,4054 }, { 234,4054 }, { 235,4054 }, + { 236,4054 }, { 237,4054 }, { 238,4054 }, { 239,4054 }, { 240,4054 }, + { 241,4054 }, { 242,4054 }, { 243,4054 }, { 244,4054 }, { 245,4054 }, + { 246,4054 }, { 247,4054 }, { 248,4054 }, { 249,4054 }, { 250,4054 }, + + { 251,4054 }, { 252,4054 }, { 253,4054 }, { 254,4054 }, { 255,4054 }, + { 256,4054 }, { 0, 51 }, { 0,55773 }, { 1,4182 }, { 2,4182 }, + { 3,4182 }, { 4,4182 }, { 5,4182 }, { 6,4182 }, { 7,4182 }, + { 8,4182 }, { 9,4182 }, { 10,4182 }, { 11,4182 }, { 12,4182 }, + { 13,4182 }, { 14,4182 }, { 15,4182 }, { 16,4182 }, { 17,4182 }, + { 18,4182 }, { 19,4182 }, { 20,4182 }, { 21,4182 }, { 22,4182 }, + { 23,4182 }, { 24,4182 }, { 25,4182 }, { 26,4182 }, { 27,4182 }, + { 28,4182 }, { 29,4182 }, { 30,4182 }, { 31,4182 }, { 32,4182 }, + { 33,4182 }, { 0, 0 }, { 35,4182 }, { 36,4182 }, { 37,4182 }, + { 38,4182 }, { 39,4182 }, { 40,4182 }, { 41,4182 }, { 42,4182 }, + + { 43,4182 }, { 44,4182 }, { 45,4182 }, { 46,4182 }, { 47,4182 }, + { 48,4182 }, { 49,4182 }, { 50,4182 }, { 51,4182 }, { 52,4182 }, + { 53,4182 }, { 54,4182 }, { 55,4182 }, { 56,4182 }, { 57,4182 }, + { 58,4182 }, { 59,4182 }, { 60,4182 }, { 61,4182 }, { 62,4182 }, + { 63,4182 }, { 64,4182 }, { 65,4182 }, { 66,4182 }, { 67,4182 }, + { 68,4182 }, { 69,4182 }, { 70,4182 }, { 71,4182 }, { 72,4182 }, + { 73,4182 }, { 74,4182 }, { 75,4182 }, { 76,4182 }, { 77,4182 }, + { 78,4182 }, { 79,4182 }, { 80,4182 }, { 81,4182 }, { 82,4182 }, + { 83,4182 }, { 84,4182 }, { 85,4182 }, { 86,4182 }, { 87,4182 }, + { 88,4182 }, { 89,4182 }, { 90,4182 }, { 91,4182 }, { 92,4182 }, + + { 93,4182 }, { 94,4182 }, { 95,4182 }, { 96,4182 }, { 97,4182 }, + { 98,4182 }, { 99,4182 }, { 100,4182 }, { 101,4182 }, { 102,4182 }, + { 103,4182 }, { 104,4182 }, { 105,4182 }, { 106,4182 }, { 107,4182 }, + { 108,4182 }, { 109,4182 }, { 110,4182 }, { 111,4182 }, { 112,4182 }, + { 113,4182 }, { 114,4182 }, { 115,4182 }, { 116,4182 }, { 117,4182 }, + { 118,4182 }, { 119,4182 }, { 120,4182 }, { 121,4182 }, { 122,4182 }, + { 123,4182 }, { 124,4182 }, { 125,4182 }, { 126,4182 }, { 127,4182 }, + { 128,4182 }, { 129,4182 }, { 130,4182 }, { 131,4182 }, { 132,4182 }, + { 133,4182 }, { 134,4182 }, { 135,4182 }, { 136,4182 }, { 137,4182 }, + { 138,4182 }, { 139,4182 }, { 140,4182 }, { 141,4182 }, { 142,4182 }, + + { 143,4182 }, { 144,4182 }, { 145,4182 }, { 146,4182 }, { 147,4182 }, + { 148,4182 }, { 149,4182 }, { 150,4182 }, { 151,4182 }, { 152,4182 }, + { 153,4182 }, { 154,4182 }, { 155,4182 }, { 156,4182 }, { 157,4182 }, + { 158,4182 }, { 159,4182 }, { 160,4182 }, { 161,4182 }, { 162,4182 }, + { 163,4182 }, { 164,4182 }, { 165,4182 }, { 166,4182 }, { 167,4182 }, + { 168,4182 }, { 169,4182 }, { 170,4182 }, { 171,4182 }, { 172,4182 }, + { 173,4182 }, { 174,4182 }, { 175,4182 }, { 176,4182 }, { 177,4182 }, + { 178,4182 }, { 179,4182 }, { 180,4182 }, { 181,4182 }, { 182,4182 }, + { 183,4182 }, { 184,4182 }, { 185,4182 }, { 186,4182 }, { 187,4182 }, + { 188,4182 }, { 189,4182 }, { 190,4182 }, { 191,4182 }, { 192,4182 }, + + { 193,4182 }, { 194,4182 }, { 195,4182 }, { 196,4182 }, { 197,4182 }, + { 198,4182 }, { 199,4182 }, { 200,4182 }, { 201,4182 }, { 202,4182 }, + { 203,4182 }, { 204,4182 }, { 205,4182 }, { 206,4182 }, { 207,4182 }, + { 208,4182 }, { 209,4182 }, { 210,4182 }, { 211,4182 }, { 212,4182 }, + { 213,4182 }, { 214,4182 }, { 215,4182 }, { 216,4182 }, { 217,4182 }, + { 218,4182 }, { 219,4182 }, { 220,4182 }, { 221,4182 }, { 222,4182 }, + { 223,4182 }, { 224,4182 }, { 225,4182 }, { 226,4182 }, { 227,4182 }, + { 228,4182 }, { 229,4182 }, { 230,4182 }, { 231,4182 }, { 232,4182 }, + { 233,4182 }, { 234,4182 }, { 235,4182 }, { 236,4182 }, { 237,4182 }, + { 238,4182 }, { 239,4182 }, { 240,4182 }, { 241,4182 }, { 242,4182 }, + + { 243,4182 }, { 244,4182 }, { 245,4182 }, { 246,4182 }, { 247,4182 }, + { 248,4182 }, { 249,4182 }, { 250,4182 }, { 251,4182 }, { 252,4182 }, + { 253,4182 }, { 254,4182 }, { 255,4182 }, { 256,4182 }, { 0, 11 }, + { 0,55515 }, { 1,4182 }, { 2,4182 }, { 3,4182 }, { 4,4182 }, + { 5,4182 }, { 6,4182 }, { 7,4182 }, { 8,4182 }, { 9,4182 }, + { 10,4182 }, { 11,4182 }, { 12,4182 }, { 13,4182 }, { 14,4182 }, + { 15,4182 }, { 16,4182 }, { 17,4182 }, { 18,4182 }, { 19,4182 }, + { 20,4182 }, { 21,4182 }, { 22,4182 }, { 23,4182 }, { 24,4182 }, + { 25,4182 }, { 26,4182 }, { 27,4182 }, { 28,4182 }, { 29,4182 }, + { 30,4182 }, { 31,4182 }, { 32,4182 }, { 33,4182 }, { 34,4182 }, + + { 35,4182 }, { 36,4182 }, { 37,4182 }, { 38,4182 }, { 0, 0 }, + { 40,4182 }, { 41,4182 }, { 42,4182 }, { 43,4182 }, { 44,4182 }, + { 45,4182 }, { 46,4182 }, { 47,4182 }, { 48,4182 }, { 49,4182 }, + { 50,4182 }, { 51,4182 }, { 52,4182 }, { 53,4182 }, { 54,4182 }, + { 55,4182 }, { 56,4182 }, { 57,4182 }, { 58,4182 }, { 59,4182 }, + { 60,4182 }, { 61,4182 }, { 62,4182 }, { 63,4182 }, { 64,4182 }, + { 65,4182 }, { 66,4182 }, { 67,4182 }, { 68,4182 }, { 69,4182 }, + { 70,4182 }, { 71,4182 }, { 72,4182 }, { 73,4182 }, { 74,4182 }, + { 75,4182 }, { 76,4182 }, { 77,4182 }, { 78,4182 }, { 79,4182 }, + { 80,4182 }, { 81,4182 }, { 82,4182 }, { 83,4182 }, { 84,4182 }, + + { 85,4182 }, { 86,4182 }, { 87,4182 }, { 88,4182 }, { 89,4182 }, + { 90,4182 }, { 91,4182 }, { 92,4182 }, { 93,4182 }, { 94,4182 }, + { 95,4182 }, { 96,4182 }, { 97,4182 }, { 98,4182 }, { 99,4182 }, + { 100,4182 }, { 101,4182 }, { 102,4182 }, { 103,4182 }, { 104,4182 }, + { 105,4182 }, { 106,4182 }, { 107,4182 }, { 108,4182 }, { 109,4182 }, + { 110,4182 }, { 111,4182 }, { 112,4182 }, { 113,4182 }, { 114,4182 }, + { 115,4182 }, { 116,4182 }, { 117,4182 }, { 118,4182 }, { 119,4182 }, + { 120,4182 }, { 121,4182 }, { 122,4182 }, { 123,4182 }, { 124,4182 }, + { 125,4182 }, { 126,4182 }, { 127,4182 }, { 128,4182 }, { 129,4182 }, + { 130,4182 }, { 131,4182 }, { 132,4182 }, { 133,4182 }, { 134,4182 }, + + { 135,4182 }, { 136,4182 }, { 137,4182 }, { 138,4182 }, { 139,4182 }, + { 140,4182 }, { 141,4182 }, { 142,4182 }, { 143,4182 }, { 144,4182 }, + { 145,4182 }, { 146,4182 }, { 147,4182 }, { 148,4182 }, { 149,4182 }, + { 150,4182 }, { 151,4182 }, { 152,4182 }, { 153,4182 }, { 154,4182 }, + { 155,4182 }, { 156,4182 }, { 157,4182 }, { 158,4182 }, { 159,4182 }, + { 160,4182 }, { 161,4182 }, { 162,4182 }, { 163,4182 }, { 164,4182 }, + { 165,4182 }, { 166,4182 }, { 167,4182 }, { 168,4182 }, { 169,4182 }, + { 170,4182 }, { 171,4182 }, { 172,4182 }, { 173,4182 }, { 174,4182 }, + { 175,4182 }, { 176,4182 }, { 177,4182 }, { 178,4182 }, { 179,4182 }, + { 180,4182 }, { 181,4182 }, { 182,4182 }, { 183,4182 }, { 184,4182 }, + + { 185,4182 }, { 186,4182 }, { 187,4182 }, { 188,4182 }, { 189,4182 }, + { 190,4182 }, { 191,4182 }, { 192,4182 }, { 193,4182 }, { 194,4182 }, + { 195,4182 }, { 196,4182 }, { 197,4182 }, { 198,4182 }, { 199,4182 }, + { 200,4182 }, { 201,4182 }, { 202,4182 }, { 203,4182 }, { 204,4182 }, + { 205,4182 }, { 206,4182 }, { 207,4182 }, { 208,4182 }, { 209,4182 }, + { 210,4182 }, { 211,4182 }, { 212,4182 }, { 213,4182 }, { 214,4182 }, + { 215,4182 }, { 216,4182 }, { 217,4182 }, { 218,4182 }, { 219,4182 }, + { 220,4182 }, { 221,4182 }, { 222,4182 }, { 223,4182 }, { 224,4182 }, + { 225,4182 }, { 226,4182 }, { 227,4182 }, { 228,4182 }, { 229,4182 }, + { 230,4182 }, { 231,4182 }, { 232,4182 }, { 233,4182 }, { 234,4182 }, + + { 235,4182 }, { 236,4182 }, { 237,4182 }, { 238,4182 }, { 239,4182 }, + { 240,4182 }, { 241,4182 }, { 242,4182 }, { 243,4182 }, { 244,4182 }, + { 245,4182 }, { 246,4182 }, { 247,4182 }, { 248,4182 }, { 249,4182 }, + { 250,4182 }, { 251,4182 }, { 252,4182 }, { 253,4182 }, { 254,4182 }, + { 255,4182 }, { 256,4182 }, { 0, 16 }, { 0,55257 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 9,4182 }, { 10,4187 }, { 0, 0 }, + { 12,4182 }, { 13,4187 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 32,4182 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 45,-2905 }, { 0, 28 }, + { 0,55210 }, { 1,4187 }, { 2,4187 }, { 3,4187 }, { 4,4187 }, + { 5,4187 }, { 6,4187 }, { 7,4187 }, { 8,4187 }, { 9,4187 }, + { 10,4187 }, { 11,4187 }, { 12,4187 }, { 13,4187 }, { 14,4187 }, + { 15,4187 }, { 16,4187 }, { 17,4187 }, { 18,4187 }, { 19,4187 }, + { 20,4187 }, { 21,4187 }, { 22,4187 }, { 23,4187 }, { 24,4187 }, + { 25,4187 }, { 26,4187 }, { 27,4187 }, { 28,4187 }, { 29,4187 }, + + { 30,4187 }, { 31,4187 }, { 32,4187 }, { 33,4187 }, { 34,4187 }, + { 35,4187 }, { 36,4187 }, { 37,4187 }, { 38,4187 }, { 0, 0 }, + { 40,4187 }, { 41,4187 }, { 42,4187 }, { 43,4187 }, { 44,4187 }, + { 45,4187 }, { 46,4187 }, { 47,4187 }, { 48,4187 }, { 49,4187 }, + { 50,4187 }, { 51,4187 }, { 52,4187 }, { 53,4187 }, { 54,4187 }, + { 55,4187 }, { 56,4187 }, { 57,4187 }, { 58,4187 }, { 59,4187 }, + { 60,4187 }, { 61,4187 }, { 62,4187 }, { 63,4187 }, { 64,4187 }, + { 65,4187 }, { 66,4187 }, { 67,4187 }, { 68,4187 }, { 69,4187 }, + { 70,4187 }, { 71,4187 }, { 72,4187 }, { 73,4187 }, { 74,4187 }, + { 75,4187 }, { 76,4187 }, { 77,4187 }, { 78,4187 }, { 79,4187 }, + + { 80,4187 }, { 81,4187 }, { 82,4187 }, { 83,4187 }, { 84,4187 }, + { 85,4187 }, { 86,4187 }, { 87,4187 }, { 88,4187 }, { 89,4187 }, + { 90,4187 }, { 91,4187 }, { 0, 0 }, { 93,4187 }, { 94,4187 }, + { 95,4187 }, { 96,4187 }, { 97,4187 }, { 98,4187 }, { 99,4187 }, + { 100,4187 }, { 101,4187 }, { 102,4187 }, { 103,4187 }, { 104,4187 }, + { 105,4187 }, { 106,4187 }, { 107,4187 }, { 108,4187 }, { 109,4187 }, + { 110,4187 }, { 111,4187 }, { 112,4187 }, { 113,4187 }, { 114,4187 }, + { 115,4187 }, { 116,4187 }, { 117,4187 }, { 118,4187 }, { 119,4187 }, + { 120,4187 }, { 121,4187 }, { 122,4187 }, { 123,4187 }, { 124,4187 }, + { 125,4187 }, { 126,4187 }, { 127,4187 }, { 128,4187 }, { 129,4187 }, + + { 130,4187 }, { 131,4187 }, { 132,4187 }, { 133,4187 }, { 134,4187 }, + { 135,4187 }, { 136,4187 }, { 137,4187 }, { 138,4187 }, { 139,4187 }, + { 140,4187 }, { 141,4187 }, { 142,4187 }, { 143,4187 }, { 144,4187 }, + { 145,4187 }, { 146,4187 }, { 147,4187 }, { 148,4187 }, { 149,4187 }, + { 150,4187 }, { 151,4187 }, { 152,4187 }, { 153,4187 }, { 154,4187 }, + { 155,4187 }, { 156,4187 }, { 157,4187 }, { 158,4187 }, { 159,4187 }, + { 160,4187 }, { 161,4187 }, { 162,4187 }, { 163,4187 }, { 164,4187 }, + { 165,4187 }, { 166,4187 }, { 167,4187 }, { 168,4187 }, { 169,4187 }, + { 170,4187 }, { 171,4187 }, { 172,4187 }, { 173,4187 }, { 174,4187 }, + { 175,4187 }, { 176,4187 }, { 177,4187 }, { 178,4187 }, { 179,4187 }, + + { 180,4187 }, { 181,4187 }, { 182,4187 }, { 183,4187 }, { 184,4187 }, + { 185,4187 }, { 186,4187 }, { 187,4187 }, { 188,4187 }, { 189,4187 }, + { 190,4187 }, { 191,4187 }, { 192,4187 }, { 193,4187 }, { 194,4187 }, + { 195,4187 }, { 196,4187 }, { 197,4187 }, { 198,4187 }, { 199,4187 }, + { 200,4187 }, { 201,4187 }, { 202,4187 }, { 203,4187 }, { 204,4187 }, + { 205,4187 }, { 206,4187 }, { 207,4187 }, { 208,4187 }, { 209,4187 }, + { 210,4187 }, { 211,4187 }, { 212,4187 }, { 213,4187 }, { 214,4187 }, + { 215,4187 }, { 216,4187 }, { 217,4187 }, { 218,4187 }, { 219,4187 }, + { 220,4187 }, { 221,4187 }, { 222,4187 }, { 223,4187 }, { 224,4187 }, + { 225,4187 }, { 226,4187 }, { 227,4187 }, { 228,4187 }, { 229,4187 }, + + { 230,4187 }, { 231,4187 }, { 232,4187 }, { 233,4187 }, { 234,4187 }, + { 235,4187 }, { 236,4187 }, { 237,4187 }, { 238,4187 }, { 239,4187 }, + { 240,4187 }, { 241,4187 }, { 242,4187 }, { 243,4187 }, { 244,4187 }, + { 245,4187 }, { 246,4187 }, { 247,4187 }, { 248,4187 }, { 249,4187 }, + { 250,4187 }, { 251,4187 }, { 252,4187 }, { 253,4187 }, { 254,4187 }, + { 255,4187 }, { 256,4187 }, { 0, 28 }, { 0,54952 }, { 1,3929 }, + { 2,3929 }, { 3,3929 }, { 4,3929 }, { 5,3929 }, { 6,3929 }, + { 7,3929 }, { 8,3929 }, { 9,3929 }, { 10,3929 }, { 11,3929 }, + { 12,3929 }, { 13,3929 }, { 14,3929 }, { 15,3929 }, { 16,3929 }, + { 17,3929 }, { 18,3929 }, { 19,3929 }, { 20,3929 }, { 21,3929 }, + + { 22,3929 }, { 23,3929 }, { 24,3929 }, { 25,3929 }, { 26,3929 }, + { 27,3929 }, { 28,3929 }, { 29,3929 }, { 30,3929 }, { 31,3929 }, + { 32,3929 }, { 33,3929 }, { 34,3929 }, { 35,3929 }, { 36,3929 }, + { 37,3929 }, { 38,3929 }, { 0, 0 }, { 40,3929 }, { 41,3929 }, + { 42,3929 }, { 43,3929 }, { 44,3929 }, { 45,3929 }, { 46,3929 }, + { 47,3929 }, { 48,3929 }, { 49,3929 }, { 50,3929 }, { 51,3929 }, + { 52,3929 }, { 53,3929 }, { 54,3929 }, { 55,3929 }, { 56,3929 }, + { 57,3929 }, { 58,3929 }, { 59,3929 }, { 60,3929 }, { 61,3929 }, + { 62,3929 }, { 63,3929 }, { 64,3929 }, { 65,3929 }, { 66,3929 }, + { 67,3929 }, { 68,3929 }, { 69,3929 }, { 70,3929 }, { 71,3929 }, + + { 72,3929 }, { 73,3929 }, { 74,3929 }, { 75,3929 }, { 76,3929 }, + { 77,3929 }, { 78,3929 }, { 79,3929 }, { 80,3929 }, { 81,3929 }, + { 82,3929 }, { 83,3929 }, { 84,3929 }, { 85,3929 }, { 86,3929 }, + { 87,3929 }, { 88,3929 }, { 89,3929 }, { 90,3929 }, { 91,3929 }, + { 0, 0 }, { 93,3929 }, { 94,3929 }, { 95,3929 }, { 96,3929 }, + { 97,3929 }, { 98,3929 }, { 99,3929 }, { 100,3929 }, { 101,3929 }, + { 102,3929 }, { 103,3929 }, { 104,3929 }, { 105,3929 }, { 106,3929 }, + { 107,3929 }, { 108,3929 }, { 109,3929 }, { 110,3929 }, { 111,3929 }, + { 112,3929 }, { 113,3929 }, { 114,3929 }, { 115,3929 }, { 116,3929 }, + { 117,3929 }, { 118,3929 }, { 119,3929 }, { 120,3929 }, { 121,3929 }, + + { 122,3929 }, { 123,3929 }, { 124,3929 }, { 125,3929 }, { 126,3929 }, + { 127,3929 }, { 128,3929 }, { 129,3929 }, { 130,3929 }, { 131,3929 }, + { 132,3929 }, { 133,3929 }, { 134,3929 }, { 135,3929 }, { 136,3929 }, + { 137,3929 }, { 138,3929 }, { 139,3929 }, { 140,3929 }, { 141,3929 }, + { 142,3929 }, { 143,3929 }, { 144,3929 }, { 145,3929 }, { 146,3929 }, + { 147,3929 }, { 148,3929 }, { 149,3929 }, { 150,3929 }, { 151,3929 }, + { 152,3929 }, { 153,3929 }, { 154,3929 }, { 155,3929 }, { 156,3929 }, + { 157,3929 }, { 158,3929 }, { 159,3929 }, { 160,3929 }, { 161,3929 }, + { 162,3929 }, { 163,3929 }, { 164,3929 }, { 165,3929 }, { 166,3929 }, + { 167,3929 }, { 168,3929 }, { 169,3929 }, { 170,3929 }, { 171,3929 }, + + { 172,3929 }, { 173,3929 }, { 174,3929 }, { 175,3929 }, { 176,3929 }, + { 177,3929 }, { 178,3929 }, { 179,3929 }, { 180,3929 }, { 181,3929 }, + { 182,3929 }, { 183,3929 }, { 184,3929 }, { 185,3929 }, { 186,3929 }, + { 187,3929 }, { 188,3929 }, { 189,3929 }, { 190,3929 }, { 191,3929 }, + { 192,3929 }, { 193,3929 }, { 194,3929 }, { 195,3929 }, { 196,3929 }, + { 197,3929 }, { 198,3929 }, { 199,3929 }, { 200,3929 }, { 201,3929 }, + { 202,3929 }, { 203,3929 }, { 204,3929 }, { 205,3929 }, { 206,3929 }, + { 207,3929 }, { 208,3929 }, { 209,3929 }, { 210,3929 }, { 211,3929 }, + { 212,3929 }, { 213,3929 }, { 214,3929 }, { 215,3929 }, { 216,3929 }, + { 217,3929 }, { 218,3929 }, { 219,3929 }, { 220,3929 }, { 221,3929 }, + + { 222,3929 }, { 223,3929 }, { 224,3929 }, { 225,3929 }, { 226,3929 }, + { 227,3929 }, { 228,3929 }, { 229,3929 }, { 230,3929 }, { 231,3929 }, + { 232,3929 }, { 233,3929 }, { 234,3929 }, { 235,3929 }, { 236,3929 }, + { 237,3929 }, { 238,3929 }, { 239,3929 }, { 240,3929 }, { 241,3929 }, + { 242,3929 }, { 243,3929 }, { 244,3929 }, { 245,3929 }, { 246,3929 }, + { 247,3929 }, { 248,3929 }, { 249,3929 }, { 250,3929 }, { 251,3929 }, + { 252,3929 }, { 253,3929 }, { 254,3929 }, { 255,3929 }, { 256,3929 }, + { 0, 22 }, { 0,54694 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 9,3929 }, { 10,3934 }, { 0, 0 }, { 12,3929 }, { 13,3934 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 32,3929 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 39,-3435 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 45,-3428 }, { 0, 38 }, { 0,54647 }, { 1,-3473 }, + { 2,-3473 }, { 3,-3473 }, { 4,-3473 }, { 5,-3473 }, { 6,-3473 }, + { 7,-3473 }, { 8,-3473 }, { 9,-3473 }, { 10,-3473 }, { 11,-3473 }, + { 12,-3473 }, { 13,-3473 }, { 14,-3473 }, { 15,-3473 }, { 16,-3473 }, + + { 17,-3473 }, { 18,-3473 }, { 19,-3473 }, { 20,-3473 }, { 21,-3473 }, + { 22,-3473 }, { 23,-3473 }, { 24,-3473 }, { 25,-3473 }, { 26,-3473 }, + { 27,-3473 }, { 28,-3473 }, { 29,-3473 }, { 30,-3473 }, { 31,-3473 }, + { 32,-3473 }, { 33,-3473 }, { 34,-3473 }, { 35,-3473 }, { 36,-3473 }, + { 37,-3473 }, { 38,-3473 }, { 39,-3473 }, { 40,-3473 }, { 41,-3473 }, + { 42,-3473 }, { 43,-3473 }, { 44,-3473 }, { 45,-3473 }, { 46,-3473 }, + { 47,-3473 }, { 48,3889 }, { 49,3889 }, { 50,3889 }, { 51,3889 }, + { 52,3889 }, { 53,3889 }, { 54,3889 }, { 55,3889 }, { 56,-3473 }, + { 57,-3473 }, { 58,-3473 }, { 59,-3473 }, { 60,-3473 }, { 61,-3473 }, + { 62,-3473 }, { 63,-3473 }, { 64,-3473 }, { 65,-3473 }, { 66,-3473 }, + + { 67,-3473 }, { 68,-3473 }, { 69,-3473 }, { 70,-3473 }, { 71,-3473 }, + { 72,-3473 }, { 73,-3473 }, { 74,-3473 }, { 75,-3473 }, { 76,-3473 }, + { 77,-3473 }, { 78,-3473 }, { 79,-3473 }, { 80,-3473 }, { 81,-3473 }, + { 82,-3473 }, { 83,-3473 }, { 84,-3473 }, { 85,3902 }, { 86,-3473 }, + { 87,-3473 }, { 88,-3473 }, { 89,-3473 }, { 90,-3473 }, { 91,-3473 }, + { 92,-3473 }, { 93,-3473 }, { 94,-3473 }, { 95,-3473 }, { 96,-3473 }, + { 97,-3473 }, { 98,-3473 }, { 99,-3473 }, { 100,-3473 }, { 101,-3473 }, + { 102,-3473 }, { 103,-3473 }, { 104,-3473 }, { 105,-3473 }, { 106,-3473 }, + { 107,-3473 }, { 108,-3473 }, { 109,-3473 }, { 110,-3473 }, { 111,-3473 }, + { 112,-3473 }, { 113,-3473 }, { 114,-3473 }, { 115,-3473 }, { 116,-3473 }, + + { 117,3925 }, { 118,-3473 }, { 119,-3473 }, { 120,3963 }, { 121,-3473 }, + { 122,-3473 }, { 123,-3473 }, { 124,-3473 }, { 125,-3473 }, { 126,-3473 }, + { 127,-3473 }, { 128,-3473 }, { 129,-3473 }, { 130,-3473 }, { 131,-3473 }, + { 132,-3473 }, { 133,-3473 }, { 134,-3473 }, { 135,-3473 }, { 136,-3473 }, + { 137,-3473 }, { 138,-3473 }, { 139,-3473 }, { 140,-3473 }, { 141,-3473 }, + { 142,-3473 }, { 143,-3473 }, { 144,-3473 }, { 145,-3473 }, { 146,-3473 }, + { 147,-3473 }, { 148,-3473 }, { 149,-3473 }, { 150,-3473 }, { 151,-3473 }, + { 152,-3473 }, { 153,-3473 }, { 154,-3473 }, { 155,-3473 }, { 156,-3473 }, + { 157,-3473 }, { 158,-3473 }, { 159,-3473 }, { 160,-3473 }, { 161,-3473 }, + { 162,-3473 }, { 163,-3473 }, { 164,-3473 }, { 165,-3473 }, { 166,-3473 }, + + { 167,-3473 }, { 168,-3473 }, { 169,-3473 }, { 170,-3473 }, { 171,-3473 }, + { 172,-3473 }, { 173,-3473 }, { 174,-3473 }, { 175,-3473 }, { 176,-3473 }, + { 177,-3473 }, { 178,-3473 }, { 179,-3473 }, { 180,-3473 }, { 181,-3473 }, + { 182,-3473 }, { 183,-3473 }, { 184,-3473 }, { 185,-3473 }, { 186,-3473 }, + { 187,-3473 }, { 188,-3473 }, { 189,-3473 }, { 190,-3473 }, { 191,-3473 }, + { 192,-3473 }, { 193,-3473 }, { 194,-3473 }, { 195,-3473 }, { 196,-3473 }, + { 197,-3473 }, { 198,-3473 }, { 199,-3473 }, { 200,-3473 }, { 201,-3473 }, + { 202,-3473 }, { 203,-3473 }, { 204,-3473 }, { 205,-3473 }, { 206,-3473 }, + { 207,-3473 }, { 208,-3473 }, { 209,-3473 }, { 210,-3473 }, { 211,-3473 }, + { 212,-3473 }, { 213,-3473 }, { 214,-3473 }, { 215,-3473 }, { 216,-3473 }, + + { 217,-3473 }, { 218,-3473 }, { 219,-3473 }, { 220,-3473 }, { 221,-3473 }, + { 222,-3473 }, { 223,-3473 }, { 224,-3473 }, { 225,-3473 }, { 226,-3473 }, + { 227,-3473 }, { 228,-3473 }, { 229,-3473 }, { 230,-3473 }, { 231,-3473 }, + { 232,-3473 }, { 233,-3473 }, { 234,-3473 }, { 235,-3473 }, { 236,-3473 }, + { 237,-3473 }, { 238,-3473 }, { 239,-3473 }, { 240,-3473 }, { 241,-3473 }, + { 242,-3473 }, { 243,-3473 }, { 244,-3473 }, { 245,-3473 }, { 246,-3473 }, + { 247,-3473 }, { 248,-3473 }, { 249,-3473 }, { 250,-3473 }, { 251,-3473 }, + { 252,-3473 }, { 253,-3473 }, { 254,-3473 }, { 255,-3473 }, { 256,-3473 }, + { 0, 27 }, { 0,54389 }, { 1,3809 }, { 2,3809 }, { 3,3809 }, + { 4,3809 }, { 5,3809 }, { 6,3809 }, { 7,3809 }, { 8,3809 }, + + { 9,3809 }, { 10,3809 }, { 11,3809 }, { 12,3809 }, { 13,3809 }, + { 14,3809 }, { 15,3809 }, { 16,3809 }, { 17,3809 }, { 18,3809 }, + { 19,3809 }, { 20,3809 }, { 21,3809 }, { 22,3809 }, { 23,3809 }, + { 24,3809 }, { 25,3809 }, { 26,3809 }, { 27,3809 }, { 28,3809 }, + { 29,3809 }, { 30,3809 }, { 31,3809 }, { 32,3809 }, { 33,3809 }, + { 34,3809 }, { 35,3809 }, { 36,3809 }, { 37,3809 }, { 38,3809 }, + { 0, 0 }, { 40,3809 }, { 41,3809 }, { 42,3809 }, { 43,3809 }, + { 44,3809 }, { 45,3809 }, { 46,3809 }, { 47,3809 }, { 48,3809 }, + { 49,3809 }, { 50,3809 }, { 51,3809 }, { 52,3809 }, { 53,3809 }, + { 54,3809 }, { 55,3809 }, { 56,3809 }, { 57,3809 }, { 58,3809 }, + + { 59,3809 }, { 60,3809 }, { 61,3809 }, { 62,3809 }, { 63,3809 }, + { 64,3809 }, { 65,3809 }, { 66,3809 }, { 67,3809 }, { 68,3809 }, + { 69,3809 }, { 70,3809 }, { 71,3809 }, { 72,3809 }, { 73,3809 }, + { 74,3809 }, { 75,3809 }, { 76,3809 }, { 77,3809 }, { 78,3809 }, + { 79,3809 }, { 80,3809 }, { 81,3809 }, { 82,3809 }, { 83,3809 }, + { 84,3809 }, { 85,3809 }, { 86,3809 }, { 87,3809 }, { 88,3809 }, + { 89,3809 }, { 90,3809 }, { 91,3809 }, { 92,3809 }, { 93,3809 }, + { 94,3809 }, { 95,3809 }, { 96,3809 }, { 97,3809 }, { 98,3809 }, + { 99,3809 }, { 100,3809 }, { 101,3809 }, { 102,3809 }, { 103,3809 }, + { 104,3809 }, { 105,3809 }, { 106,3809 }, { 107,3809 }, { 108,3809 }, + + { 109,3809 }, { 110,3809 }, { 111,3809 }, { 112,3809 }, { 113,3809 }, + { 114,3809 }, { 115,3809 }, { 116,3809 }, { 117,3809 }, { 118,3809 }, + { 119,3809 }, { 120,3809 }, { 121,3809 }, { 122,3809 }, { 123,3809 }, + { 124,3809 }, { 125,3809 }, { 126,3809 }, { 127,3809 }, { 128,3809 }, + { 129,3809 }, { 130,3809 }, { 131,3809 }, { 132,3809 }, { 133,3809 }, + { 134,3809 }, { 135,3809 }, { 136,3809 }, { 137,3809 }, { 138,3809 }, + { 139,3809 }, { 140,3809 }, { 141,3809 }, { 142,3809 }, { 143,3809 }, + { 144,3809 }, { 145,3809 }, { 146,3809 }, { 147,3809 }, { 148,3809 }, + { 149,3809 }, { 150,3809 }, { 151,3809 }, { 152,3809 }, { 153,3809 }, + { 154,3809 }, { 155,3809 }, { 156,3809 }, { 157,3809 }, { 158,3809 }, + + { 159,3809 }, { 160,3809 }, { 161,3809 }, { 162,3809 }, { 163,3809 }, + { 164,3809 }, { 165,3809 }, { 166,3809 }, { 167,3809 }, { 168,3809 }, + { 169,3809 }, { 170,3809 }, { 171,3809 }, { 172,3809 }, { 173,3809 }, + { 174,3809 }, { 175,3809 }, { 176,3809 }, { 177,3809 }, { 178,3809 }, + { 179,3809 }, { 180,3809 }, { 181,3809 }, { 182,3809 }, { 183,3809 }, + { 184,3809 }, { 185,3809 }, { 186,3809 }, { 187,3809 }, { 188,3809 }, + { 189,3809 }, { 190,3809 }, { 191,3809 }, { 192,3809 }, { 193,3809 }, + { 194,3809 }, { 195,3809 }, { 196,3809 }, { 197,3809 }, { 198,3809 }, + { 199,3809 }, { 200,3809 }, { 201,3809 }, { 202,3809 }, { 203,3809 }, + { 204,3809 }, { 205,3809 }, { 206,3809 }, { 207,3809 }, { 208,3809 }, + + { 209,3809 }, { 210,3809 }, { 211,3809 }, { 212,3809 }, { 213,3809 }, + { 214,3809 }, { 215,3809 }, { 216,3809 }, { 217,3809 }, { 218,3809 }, + { 219,3809 }, { 220,3809 }, { 221,3809 }, { 222,3809 }, { 223,3809 }, + { 224,3809 }, { 225,3809 }, { 226,3809 }, { 227,3809 }, { 228,3809 }, + { 229,3809 }, { 230,3809 }, { 231,3809 }, { 232,3809 }, { 233,3809 }, + { 234,3809 }, { 235,3809 }, { 236,3809 }, { 237,3809 }, { 238,3809 }, + { 239,3809 }, { 240,3809 }, { 241,3809 }, { 242,3809 }, { 243,3809 }, + { 244,3809 }, { 245,3809 }, { 246,3809 }, { 247,3809 }, { 248,3809 }, + { 249,3809 }, { 250,3809 }, { 251,3809 }, { 252,3809 }, { 253,3809 }, + { 254,3809 }, { 255,3809 }, { 256,3809 }, { 0, 22 }, { 0,54131 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 9,3366 }, { 10,3371 }, + { 0, 0 }, { 12,3366 }, { 13,3371 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 32,3366 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 39,-3998 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 45,-3991 }, + { 0, 42 }, { 0,54084 }, { 1,3762 }, { 2,3762 }, { 3,3762 }, + + { 4,3762 }, { 5,3762 }, { 6,3762 }, { 7,3762 }, { 8,3762 }, + { 9,3762 }, { 10,3762 }, { 11,3762 }, { 12,3762 }, { 13,3762 }, + { 14,3762 }, { 15,3762 }, { 16,3762 }, { 17,3762 }, { 18,3762 }, + { 19,3762 }, { 20,3762 }, { 21,3762 }, { 22,3762 }, { 23,3762 }, + { 24,3762 }, { 25,3762 }, { 26,3762 }, { 27,3762 }, { 28,3762 }, + { 29,3762 }, { 30,3762 }, { 31,3762 }, { 32,3762 }, { 33,3762 }, + { 34,3762 }, { 35,3762 }, { 0, 0 }, { 37,3762 }, { 38,3762 }, + { 39,3762 }, { 40,3762 }, { 41,3762 }, { 42,3762 }, { 43,3762 }, + { 44,3762 }, { 45,3762 }, { 46,3762 }, { 47,3762 }, { 48,3762 }, + { 49,3762 }, { 50,3762 }, { 51,3762 }, { 52,3762 }, { 53,3762 }, + + { 54,3762 }, { 55,3762 }, { 56,3762 }, { 57,3762 }, { 58,3762 }, + { 59,3762 }, { 60,3762 }, { 61,3762 }, { 62,3762 }, { 63,3762 }, + { 64,3762 }, { 65,3762 }, { 66,3762 }, { 67,3762 }, { 68,3762 }, + { 69,3762 }, { 70,3762 }, { 71,3762 }, { 72,3762 }, { 73,3762 }, + { 74,3762 }, { 75,3762 }, { 76,3762 }, { 77,3762 }, { 78,3762 }, + { 79,3762 }, { 80,3762 }, { 81,3762 }, { 82,3762 }, { 83,3762 }, + { 84,3762 }, { 85,3762 }, { 86,3762 }, { 87,3762 }, { 88,3762 }, + { 89,3762 }, { 90,3762 }, { 91,3762 }, { 92,3762 }, { 93,3762 }, + { 94,3762 }, { 95,3762 }, { 96,3762 }, { 97,3762 }, { 98,3762 }, + { 99,3762 }, { 100,3762 }, { 101,3762 }, { 102,3762 }, { 103,3762 }, + + { 104,3762 }, { 105,3762 }, { 106,3762 }, { 107,3762 }, { 108,3762 }, + { 109,3762 }, { 110,3762 }, { 111,3762 }, { 112,3762 }, { 113,3762 }, + { 114,3762 }, { 115,3762 }, { 116,3762 }, { 117,3762 }, { 118,3762 }, + { 119,3762 }, { 120,3762 }, { 121,3762 }, { 122,3762 }, { 123,3762 }, + { 124,3762 }, { 125,3762 }, { 126,3762 }, { 127,3762 }, { 128,3762 }, + { 129,3762 }, { 130,3762 }, { 131,3762 }, { 132,3762 }, { 133,3762 }, + { 134,3762 }, { 135,3762 }, { 136,3762 }, { 137,3762 }, { 138,3762 }, + { 139,3762 }, { 140,3762 }, { 141,3762 }, { 142,3762 }, { 143,3762 }, + { 144,3762 }, { 145,3762 }, { 146,3762 }, { 147,3762 }, { 148,3762 }, + { 149,3762 }, { 150,3762 }, { 151,3762 }, { 152,3762 }, { 153,3762 }, + + { 154,3762 }, { 155,3762 }, { 156,3762 }, { 157,3762 }, { 158,3762 }, + { 159,3762 }, { 160,3762 }, { 161,3762 }, { 162,3762 }, { 163,3762 }, + { 164,3762 }, { 165,3762 }, { 166,3762 }, { 167,3762 }, { 168,3762 }, + { 169,3762 }, { 170,3762 }, { 171,3762 }, { 172,3762 }, { 173,3762 }, + { 174,3762 }, { 175,3762 }, { 176,3762 }, { 177,3762 }, { 178,3762 }, + { 179,3762 }, { 180,3762 }, { 181,3762 }, { 182,3762 }, { 183,3762 }, + { 184,3762 }, { 185,3762 }, { 186,3762 }, { 187,3762 }, { 188,3762 }, + { 189,3762 }, { 190,3762 }, { 191,3762 }, { 192,3762 }, { 193,3762 }, + { 194,3762 }, { 195,3762 }, { 196,3762 }, { 197,3762 }, { 198,3762 }, + { 199,3762 }, { 200,3762 }, { 201,3762 }, { 202,3762 }, { 203,3762 }, + + { 204,3762 }, { 205,3762 }, { 206,3762 }, { 207,3762 }, { 208,3762 }, + { 209,3762 }, { 210,3762 }, { 211,3762 }, { 212,3762 }, { 213,3762 }, + { 214,3762 }, { 215,3762 }, { 216,3762 }, { 217,3762 }, { 218,3762 }, + { 219,3762 }, { 220,3762 }, { 221,3762 }, { 222,3762 }, { 223,3762 }, + { 224,3762 }, { 225,3762 }, { 226,3762 }, { 227,3762 }, { 228,3762 }, + { 229,3762 }, { 230,3762 }, { 231,3762 }, { 232,3762 }, { 233,3762 }, + { 234,3762 }, { 235,3762 }, { 236,3762 }, { 237,3762 }, { 238,3762 }, + { 239,3762 }, { 240,3762 }, { 241,3762 }, { 242,3762 }, { 243,3762 }, + { 244,3762 }, { 245,3762 }, { 246,3762 }, { 247,3762 }, { 248,3762 }, + { 249,3762 }, { 250,3762 }, { 251,3762 }, { 252,3762 }, { 253,3762 }, + + { 254,3762 }, { 255,3762 }, { 256,3762 }, { 0, 42 }, { 0,53826 }, + { 1,3504 }, { 2,3504 }, { 3,3504 }, { 4,3504 }, { 5,3504 }, + { 6,3504 }, { 7,3504 }, { 8,3504 }, { 9,3504 }, { 10,3504 }, + { 11,3504 }, { 12,3504 }, { 13,3504 }, { 14,3504 }, { 15,3504 }, + { 16,3504 }, { 17,3504 }, { 18,3504 }, { 19,3504 }, { 20,3504 }, + { 21,3504 }, { 22,3504 }, { 23,3504 }, { 24,3504 }, { 25,3504 }, + { 26,3504 }, { 27,3504 }, { 28,3504 }, { 29,3504 }, { 30,3504 }, + { 31,3504 }, { 32,3504 }, { 33,3504 }, { 34,3504 }, { 35,3504 }, + { 0, 0 }, { 37,3504 }, { 38,3504 }, { 39,3504 }, { 40,3504 }, + { 41,3504 }, { 42,3504 }, { 43,3504 }, { 44,3504 }, { 45,3504 }, + + { 46,3504 }, { 47,3504 }, { 48,3504 }, { 49,3504 }, { 50,3504 }, + { 51,3504 }, { 52,3504 }, { 53,3504 }, { 54,3504 }, { 55,3504 }, + { 56,3504 }, { 57,3504 }, { 58,3504 }, { 59,3504 }, { 60,3504 }, + { 61,3504 }, { 62,3504 }, { 63,3504 }, { 64,3504 }, { 65,3504 }, + { 66,3504 }, { 67,3504 }, { 68,3504 }, { 69,3504 }, { 70,3504 }, + { 71,3504 }, { 72,3504 }, { 73,3504 }, { 74,3504 }, { 75,3504 }, + { 76,3504 }, { 77,3504 }, { 78,3504 }, { 79,3504 }, { 80,3504 }, + { 81,3504 }, { 82,3504 }, { 83,3504 }, { 84,3504 }, { 85,3504 }, + { 86,3504 }, { 87,3504 }, { 88,3504 }, { 89,3504 }, { 90,3504 }, + { 91,3504 }, { 92,3504 }, { 93,3504 }, { 94,3504 }, { 95,3504 }, + + { 96,3504 }, { 97,3504 }, { 98,3504 }, { 99,3504 }, { 100,3504 }, + { 101,3504 }, { 102,3504 }, { 103,3504 }, { 104,3504 }, { 105,3504 }, + { 106,3504 }, { 107,3504 }, { 108,3504 }, { 109,3504 }, { 110,3504 }, + { 111,3504 }, { 112,3504 }, { 113,3504 }, { 114,3504 }, { 115,3504 }, + { 116,3504 }, { 117,3504 }, { 118,3504 }, { 119,3504 }, { 120,3504 }, + { 121,3504 }, { 122,3504 }, { 123,3504 }, { 124,3504 }, { 125,3504 }, + { 126,3504 }, { 127,3504 }, { 128,3504 }, { 129,3504 }, { 130,3504 }, + { 131,3504 }, { 132,3504 }, { 133,3504 }, { 134,3504 }, { 135,3504 }, + { 136,3504 }, { 137,3504 }, { 138,3504 }, { 139,3504 }, { 140,3504 }, + { 141,3504 }, { 142,3504 }, { 143,3504 }, { 144,3504 }, { 145,3504 }, + + { 146,3504 }, { 147,3504 }, { 148,3504 }, { 149,3504 }, { 150,3504 }, + { 151,3504 }, { 152,3504 }, { 153,3504 }, { 154,3504 }, { 155,3504 }, + { 156,3504 }, { 157,3504 }, { 158,3504 }, { 159,3504 }, { 160,3504 }, + { 161,3504 }, { 162,3504 }, { 163,3504 }, { 164,3504 }, { 165,3504 }, + { 166,3504 }, { 167,3504 }, { 168,3504 }, { 169,3504 }, { 170,3504 }, + { 171,3504 }, { 172,3504 }, { 173,3504 }, { 174,3504 }, { 175,3504 }, + { 176,3504 }, { 177,3504 }, { 178,3504 }, { 179,3504 }, { 180,3504 }, + { 181,3504 }, { 182,3504 }, { 183,3504 }, { 184,3504 }, { 185,3504 }, + { 186,3504 }, { 187,3504 }, { 188,3504 }, { 189,3504 }, { 190,3504 }, + { 191,3504 }, { 192,3504 }, { 193,3504 }, { 194,3504 }, { 195,3504 }, + + { 196,3504 }, { 197,3504 }, { 198,3504 }, { 199,3504 }, { 200,3504 }, + { 201,3504 }, { 202,3504 }, { 203,3504 }, { 204,3504 }, { 205,3504 }, + { 206,3504 }, { 207,3504 }, { 208,3504 }, { 209,3504 }, { 210,3504 }, + { 211,3504 }, { 212,3504 }, { 213,3504 }, { 214,3504 }, { 215,3504 }, + { 216,3504 }, { 217,3504 }, { 218,3504 }, { 219,3504 }, { 220,3504 }, + { 221,3504 }, { 222,3504 }, { 223,3504 }, { 224,3504 }, { 225,3504 }, + { 226,3504 }, { 227,3504 }, { 228,3504 }, { 229,3504 }, { 230,3504 }, + { 231,3504 }, { 232,3504 }, { 233,3504 }, { 234,3504 }, { 235,3504 }, + { 236,3504 }, { 237,3504 }, { 238,3504 }, { 239,3504 }, { 240,3504 }, + { 241,3504 }, { 242,3504 }, { 243,3504 }, { 244,3504 }, { 245,3504 }, + + { 246,3504 }, { 247,3504 }, { 248,3504 }, { 249,3504 }, { 250,3504 }, + { 251,3504 }, { 252,3504 }, { 253,3504 }, { 254,3504 }, { 255,3504 }, + { 256,3504 }, { 0, 44 }, { 0,53568 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 48 }, { 0,53562 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 9,3755 }, { 10,3755 }, { 0, 0 }, + { 12,3755 }, { 13,3755 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 48 }, { 0,53541 }, + { 0, 24 }, { 0,53539 }, { 0, 29 }, { 0,53537 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 36,-4550 }, { 0, 0 }, + + { 32,3755 }, { 0, 0 }, { 34,-4609 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 45,-4528 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 65,3504 }, { 66,3504 }, { 67,3504 }, + { 68,3504 }, { 69,3504 }, { 70,3504 }, { 71,3504 }, { 72,3504 }, + { 73,3504 }, { 74,3504 }, { 75,3504 }, { 76,3504 }, { 77,3504 }, + { 78,3504 }, { 79,3504 }, { 80,3504 }, { 81,3504 }, { 82,3504 }, + { 83,3504 }, { 84,3504 }, { 85,3504 }, { 86,3504 }, { 87,3504 }, + + { 88,3504 }, { 89,3504 }, { 90,3504 }, { 85,-4295 }, { 65, 237 }, + { 0, 0 }, { 65, 252 }, { 95,3504 }, { 0, 0 }, { 97,3504 }, + { 98,3504 }, { 99,3504 }, { 100,3504 }, { 101,3504 }, { 102,3504 }, + { 103,3504 }, { 104,3504 }, { 105,3504 }, { 106,3504 }, { 107,3504 }, + { 108,3504 }, { 109,3504 }, { 110,3504 }, { 111,3504 }, { 112,3504 }, + { 113,3504 }, { 114,3504 }, { 115,3504 }, { 116,3504 }, { 117,3504 }, + { 118,3504 }, { 119,3504 }, { 120,3504 }, { 121,3504 }, { 122,3504 }, + { 117,-4295 }, { 97, 237 }, { 0, 0 }, { 97, 252 }, { 0, 0 }, + { 128,3504 }, { 129,3504 }, { 130,3504 }, { 131,3504 }, { 132,3504 }, + { 133,3504 }, { 134,3504 }, { 135,3504 }, { 136,3504 }, { 137,3504 }, + + { 138,3504 }, { 139,3504 }, { 140,3504 }, { 141,3504 }, { 142,3504 }, + { 143,3504 }, { 144,3504 }, { 145,3504 }, { 146,3504 }, { 147,3504 }, + { 148,3504 }, { 149,3504 }, { 150,3504 }, { 151,3504 }, { 152,3504 }, + { 153,3504 }, { 154,3504 }, { 155,3504 }, { 156,3504 }, { 157,3504 }, + { 158,3504 }, { 159,3504 }, { 160,3504 }, { 161,3504 }, { 162,3504 }, + { 163,3504 }, { 164,3504 }, { 165,3504 }, { 166,3504 }, { 167,3504 }, + { 168,3504 }, { 169,3504 }, { 170,3504 }, { 171,3504 }, { 172,3504 }, + { 173,3504 }, { 174,3504 }, { 175,3504 }, { 176,3504 }, { 177,3504 }, + { 178,3504 }, { 179,3504 }, { 180,3504 }, { 181,3504 }, { 182,3504 }, + { 183,3504 }, { 184,3504 }, { 185,3504 }, { 186,3504 }, { 187,3504 }, + + { 188,3504 }, { 189,3504 }, { 190,3504 }, { 191,3504 }, { 192,3504 }, + { 193,3504 }, { 194,3504 }, { 195,3504 }, { 196,3504 }, { 197,3504 }, + { 198,3504 }, { 199,3504 }, { 200,3504 }, { 201,3504 }, { 202,3504 }, + { 203,3504 }, { 204,3504 }, { 205,3504 }, { 206,3504 }, { 207,3504 }, + { 208,3504 }, { 209,3504 }, { 210,3504 }, { 211,3504 }, { 212,3504 }, + { 213,3504 }, { 214,3504 }, { 215,3504 }, { 216,3504 }, { 217,3504 }, + { 218,3504 }, { 219,3504 }, { 220,3504 }, { 221,3504 }, { 222,3504 }, + { 223,3504 }, { 224,3504 }, { 225,3504 }, { 226,3504 }, { 227,3504 }, + { 228,3504 }, { 229,3504 }, { 230,3504 }, { 231,3504 }, { 232,3504 }, + { 233,3504 }, { 234,3504 }, { 235,3504 }, { 236,3504 }, { 237,3504 }, + + { 238,3504 }, { 239,3504 }, { 240,3504 }, { 241,3504 }, { 242,3504 }, + { 243,3504 }, { 244,3504 }, { 245,3504 }, { 246,3504 }, { 247,3504 }, + { 248,3504 }, { 249,3504 }, { 250,3504 }, { 251,3504 }, { 252,3504 }, + { 253,3504 }, { 254,3504 }, { 255,3504 }, { 0, 24 }, { 0,53311 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 1 }, { 0,53306 }, + { 0, 48 }, { 0,53304 }, { 0, 0 }, { 9,3509 }, { 10,3525 }, + { 0, 0 }, { 12,3509 }, { 13,3525 }, { 9, 0 }, { 10, 0 }, + { 0, 0 }, { 12, 0 }, { 13, 0 }, { 0, 57 }, { 0,53291 }, + { 0, 58 }, { 0,53289 }, { 0, 24 }, { 0,53287 }, { 0, 30 }, + { 0,53285 }, { 0, 48 }, { 0,53283 }, { 0, 0 }, { 0, 24 }, + + { 0,53280 }, { 32,3509 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 32, 0 }, { 0, 0 }, { 39,-4818 }, { 0, 48 }, + { 0,53270 }, { 0, 24 }, { 0,53268 }, { 0, 0 }, { 45,-4521 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 48 }, { 0,53261 }, + { 0, 24 }, { 0,53259 }, { 33, 0 }, { 0, 0 }, { 35, 0 }, + { 0, 0 }, { 37, 0 }, { 38, 0 }, { 0, 49 }, { 0,53251 }, + { 0, 0 }, { 42, 0 }, { 43, 0 }, { 0, 0 }, { 45, 0 }, + { 0, 0 }, { 47, 0 }, { 0, 25 }, { 0,53242 }, { 48, 0 }, + { 49, 0 }, { 50, 0 }, { 51, 0 }, { 52, 0 }, { 53, 0 }, + { 54, 0 }, { 55, 0 }, { 56, 0 }, { 57, 0 }, { 60, 0 }, + + { 61, 0 }, { 62, 0 }, { 63, 0 }, { 64, 0 }, { 85,-4289 }, + { 45,23606 }, { 80, 21 }, { 45,24378 }, { 39, 10 }, { 0, 0 }, + { 39, 17 }, { 0, 48 }, { 0,53218 }, { 0, 24 }, { 0,53216 }, + { 0, 0 }, { 69,21181 }, { 0, 40 }, { 0,53212 }, { 69,21741 }, + { 0, 25 }, { 0,53209 }, { 0, 0 }, { 80, 7 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 94, 0 }, { 0, 0 }, + { 96, 0 }, { 117,-4289 }, { 0, 0 }, { 112, 21 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 101,21181 }, { 0, 0 }, + + { 0, 0 }, { 101,21741 }, { 0, 0 }, { 0, 0 }, { 36,-5086 }, + { 112, 7 }, { 0, 0 }, { 45,34940 }, { 0, 0 }, { 45,38669 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 124, 0 }, { 0, 0 }, + { 126, 0 }, { 48,3541 }, { 49,3541 }, { 50,3541 }, { 51,3541 }, + { 52,3541 }, { 53,3541 }, { 54,3541 }, { 55,3541 }, { 56,3541 }, + { 57,3541 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 65,3541 }, { 66,3541 }, + { 67,3541 }, { 68,3541 }, { 69,3541 }, { 70,3541 }, { 71,3541 }, + { 72,3541 }, { 73,3541 }, { 74,3541 }, { 75,3541 }, { 76,3541 }, + { 77,3541 }, { 78,3541 }, { 79,3541 }, { 80,3541 }, { 81,3541 }, + + { 82,3541 }, { 83,3541 }, { 84,3541 }, { 85,3541 }, { 86,3541 }, + { 87,3541 }, { 88,3541 }, { 89,3541 }, { 90,3541 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 95,3541 }, { 0, 0 }, + { 97,3541 }, { 98,3541 }, { 99,3541 }, { 100,3541 }, { 101,3541 }, + { 102,3541 }, { 103,3541 }, { 104,3541 }, { 105,3541 }, { 106,3541 }, + { 107,3541 }, { 108,3541 }, { 109,3541 }, { 110,3541 }, { 111,3541 }, + { 112,3541 }, { 113,3541 }, { 114,3541 }, { 115,3541 }, { 116,3541 }, + { 117,3541 }, { 118,3541 }, { 119,3541 }, { 120,3541 }, { 121,3541 }, + { 122,3541 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 128,3541 }, { 129,3541 }, { 130,3541 }, { 131,3541 }, + + { 132,3541 }, { 133,3541 }, { 134,3541 }, { 135,3541 }, { 136,3541 }, + { 137,3541 }, { 138,3541 }, { 139,3541 }, { 140,3541 }, { 141,3541 }, + { 142,3541 }, { 143,3541 }, { 144,3541 }, { 145,3541 }, { 146,3541 }, + { 147,3541 }, { 148,3541 }, { 149,3541 }, { 150,3541 }, { 151,3541 }, + { 152,3541 }, { 153,3541 }, { 154,3541 }, { 155,3541 }, { 156,3541 }, + { 157,3541 }, { 158,3541 }, { 159,3541 }, { 160,3541 }, { 161,3541 }, + { 162,3541 }, { 163,3541 }, { 164,3541 }, { 165,3541 }, { 166,3541 }, + { 167,3541 }, { 168,3541 }, { 169,3541 }, { 170,3541 }, { 171,3541 }, + { 172,3541 }, { 173,3541 }, { 174,3541 }, { 175,3541 }, { 176,3541 }, + { 177,3541 }, { 178,3541 }, { 179,3541 }, { 180,3541 }, { 181,3541 }, + + { 182,3541 }, { 183,3541 }, { 184,3541 }, { 185,3541 }, { 186,3541 }, + { 187,3541 }, { 188,3541 }, { 189,3541 }, { 190,3541 }, { 191,3541 }, + { 192,3541 }, { 193,3541 }, { 194,3541 }, { 195,3541 }, { 196,3541 }, + { 197,3541 }, { 198,3541 }, { 199,3541 }, { 200,3541 }, { 201,3541 }, + { 202,3541 }, { 203,3541 }, { 204,3541 }, { 205,3541 }, { 206,3541 }, + { 207,3541 }, { 208,3541 }, { 209,3541 }, { 210,3541 }, { 211,3541 }, + { 212,3541 }, { 213,3541 }, { 214,3541 }, { 215,3541 }, { 216,3541 }, + { 217,3541 }, { 218,3541 }, { 219,3541 }, { 220,3541 }, { 221,3541 }, + { 222,3541 }, { 223,3541 }, { 224,3541 }, { 225,3541 }, { 226,3541 }, + { 227,3541 }, { 228,3541 }, { 229,3541 }, { 230,3541 }, { 231,3541 }, + + { 232,3541 }, { 233,3541 }, { 234,3541 }, { 235,3541 }, { 236,3541 }, + { 237,3541 }, { 238,3541 }, { 239,3541 }, { 240,3541 }, { 241,3541 }, + { 242,3541 }, { 243,3541 }, { 244,3541 }, { 245,3541 }, { 246,3541 }, + { 247,3541 }, { 248,3541 }, { 249,3541 }, { 250,3541 }, { 251,3541 }, + { 252,3541 }, { 253,3541 }, { 254,3541 }, { 255,3541 }, { 0, 1 }, + { 0,52955 }, { 1,3541 }, { 2,3541 }, { 3,3541 }, { 4,3541 }, + { 5,3541 }, { 6,3541 }, { 7,3541 }, { 8,3541 }, { 9,3541 }, + { 0, 0 }, { 11,3541 }, { 12,3541 }, { 0, 0 }, { 14,3541 }, + { 15,3541 }, { 16,3541 }, { 17,3541 }, { 18,3541 }, { 19,3541 }, + { 20,3541 }, { 21,3541 }, { 22,3541 }, { 23,3541 }, { 24,3541 }, + + { 25,3541 }, { 26,3541 }, { 27,3541 }, { 28,3541 }, { 29,3541 }, + { 30,3541 }, { 31,3541 }, { 32,3541 }, { 33,3799 }, { 34,3541 }, + { 35,3799 }, { 36,3541 }, { 37,3799 }, { 38,3799 }, { 39,3541 }, + { 40,3541 }, { 41,3541 }, { 42,3799 }, { 43,3799 }, { 44,3541 }, + { 45,3799 }, { 46,3541 }, { 47,3799 }, { 48,3541 }, { 49,3541 }, + { 50,3541 }, { 51,3541 }, { 52,3541 }, { 53,3541 }, { 54,3541 }, + { 55,3541 }, { 56,3541 }, { 57,3541 }, { 58,3541 }, { 59,3541 }, + { 60,3799 }, { 61,3799 }, { 62,3799 }, { 63,3799 }, { 64,3799 }, + { 65,3541 }, { 66,3541 }, { 67,3541 }, { 68,3541 }, { 69,3541 }, + { 70,3541 }, { 71,3541 }, { 72,3541 }, { 73,3541 }, { 74,3541 }, + + { 75,3541 }, { 76,3541 }, { 77,3541 }, { 78,3541 }, { 79,3541 }, + { 80,3541 }, { 81,3541 }, { 82,3541 }, { 83,3541 }, { 84,3541 }, + { 85,3541 }, { 86,3541 }, { 87,3541 }, { 88,3541 }, { 89,3541 }, + { 90,3541 }, { 91,3541 }, { 92,3541 }, { 93,3541 }, { 94,3799 }, + { 95,3541 }, { 96,3799 }, { 97,3541 }, { 98,3541 }, { 99,3541 }, + { 100,3541 }, { 101,3541 }, { 102,3541 }, { 103,3541 }, { 104,3541 }, + { 105,3541 }, { 106,3541 }, { 107,3541 }, { 108,3541 }, { 109,3541 }, + { 110,3541 }, { 111,3541 }, { 112,3541 }, { 113,3541 }, { 114,3541 }, + { 115,3541 }, { 116,3541 }, { 117,3541 }, { 118,3541 }, { 119,3541 }, + { 120,3541 }, { 121,3541 }, { 122,3541 }, { 123,3541 }, { 124,3799 }, + + { 125,3541 }, { 126,3799 }, { 127,3541 }, { 128,3541 }, { 129,3541 }, + { 130,3541 }, { 131,3541 }, { 132,3541 }, { 133,3541 }, { 134,3541 }, + { 135,3541 }, { 136,3541 }, { 137,3541 }, { 138,3541 }, { 139,3541 }, + { 140,3541 }, { 141,3541 }, { 142,3541 }, { 143,3541 }, { 144,3541 }, + { 145,3541 }, { 146,3541 }, { 147,3541 }, { 148,3541 }, { 149,3541 }, + { 150,3541 }, { 151,3541 }, { 152,3541 }, { 153,3541 }, { 154,3541 }, + { 155,3541 }, { 156,3541 }, { 157,3541 }, { 158,3541 }, { 159,3541 }, + { 160,3541 }, { 161,3541 }, { 162,3541 }, { 163,3541 }, { 164,3541 }, + { 165,3541 }, { 166,3541 }, { 167,3541 }, { 168,3541 }, { 169,3541 }, + { 170,3541 }, { 171,3541 }, { 172,3541 }, { 173,3541 }, { 174,3541 }, + + { 175,3541 }, { 176,3541 }, { 177,3541 }, { 178,3541 }, { 179,3541 }, + { 180,3541 }, { 181,3541 }, { 182,3541 }, { 183,3541 }, { 184,3541 }, + { 185,3541 }, { 186,3541 }, { 187,3541 }, { 188,3541 }, { 189,3541 }, + { 190,3541 }, { 191,3541 }, { 192,3541 }, { 193,3541 }, { 194,3541 }, + { 195,3541 }, { 196,3541 }, { 197,3541 }, { 198,3541 }, { 199,3541 }, + { 200,3541 }, { 201,3541 }, { 202,3541 }, { 203,3541 }, { 204,3541 }, + { 205,3541 }, { 206,3541 }, { 207,3541 }, { 208,3541 }, { 209,3541 }, + { 210,3541 }, { 211,3541 }, { 212,3541 }, { 213,3541 }, { 214,3541 }, + { 215,3541 }, { 216,3541 }, { 217,3541 }, { 218,3541 }, { 219,3541 }, + { 220,3541 }, { 221,3541 }, { 222,3541 }, { 223,3541 }, { 224,3541 }, + + { 225,3541 }, { 226,3541 }, { 227,3541 }, { 228,3541 }, { 229,3541 }, + { 230,3541 }, { 231,3541 }, { 232,3541 }, { 233,3541 }, { 234,3541 }, + { 235,3541 }, { 236,3541 }, { 237,3541 }, { 238,3541 }, { 239,3541 }, + { 240,3541 }, { 241,3541 }, { 242,3541 }, { 243,3541 }, { 244,3541 }, + { 245,3541 }, { 246,3541 }, { 247,3541 }, { 248,3541 }, { 249,3541 }, + { 250,3541 }, { 251,3541 }, { 252,3541 }, { 253,3541 }, { 254,3541 }, + { 255,3541 }, { 256,3541 }, { 0, 60 }, { 0,52697 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 2 }, { 0,52672 }, { 0, 60 }, + { 0,52670 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 48, 0 }, { 49, 0 }, { 50, 0 }, { 51, 0 }, + { 52, 0 }, { 53, 0 }, { 54, 0 }, { 55, 0 }, { 56, 0 }, + { 57, 0 }, { 33,3774 }, { 0, 0 }, { 35,3774 }, { 0, 0 }, + { 37,3774 }, { 38,3774 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 42,3774 }, { 43,3774 }, { 69, 113 }, { 45,3774 }, { 0, 0 }, + { 47,3774 }, { 46,-4928 }, { 0, 0 }, { 48,3774 }, { 49,3774 }, + { 50,3774 }, { 51,3774 }, { 52,3774 }, { 53,3774 }, { 54,3774 }, + { 55,3774 }, { 56,3774 }, { 57,3774 }, { 60,3774 }, { 61,3774 }, + { 62,3774 }, { 63,3774 }, { 64,3774 }, { 0, 59 }, { 0,52606 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 69, 86 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 101, 113 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 63 }, { 0,52584 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 94,3774 }, { 0, 0 }, { 96,3774 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 101, 86 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 46, -64 }, { 0, 0 }, { 48, 0 }, { 49, 0 }, { 50, 0 }, + { 51, 0 }, { 52, 0 }, { 53, 0 }, { 54, 0 }, { 55, 0 }, + { 56, 0 }, { 57, 0 }, { 124,3774 }, { 0, 0 }, { 126,3774 }, + { 0, 65 }, { 0,52544 }, { 0, 0 }, { 0, 0 }, { 43,3710 }, + { 0, 0 }, { 45,3710 }, { 0, 0 }, { 69, 22 }, { 48,3752 }, + { 49,3752 }, { 50,3752 }, { 51,3752 }, { 52,3752 }, { 53,3752 }, + + { 54,3752 }, { 55,3752 }, { 56,3752 }, { 57,3752 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 36, 0 }, { 0, 0 }, { 0, 0 }, + { 101, 22 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 48, 0 }, + { 49, 0 }, { 50, 0 }, { 51, 0 }, { 52, 0 }, { 53, 0 }, + { 54, 0 }, { 55, 0 }, { 56, 0 }, { 57, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 65, 0 }, { 66, 0 }, { 67, 0 }, { 68, 0 }, + { 69, 0 }, { 70, 0 }, { 71, 0 }, { 72, 0 }, { 73, 0 }, + { 74, 0 }, { 75, 0 }, { 76, 0 }, { 77, 0 }, { 78, 0 }, + { 79, 0 }, { 80, 0 }, { 81, 0 }, { 82, 0 }, { 83, 0 }, + { 84, 0 }, { 85, 0 }, { 86, 0 }, { 87, 0 }, { 88, 0 }, + { 89, 0 }, { 90, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 95, 0 }, { 0, 0 }, { 97, 0 }, { 98, 0 }, + { 99, 0 }, { 100, 0 }, { 101, 0 }, { 102, 0 }, { 103, 0 }, + { 104, 0 }, { 105, 0 }, { 106, 0 }, { 107, 0 }, { 108, 0 }, + { 109, 0 }, { 110, 0 }, { 111, 0 }, { 112, 0 }, { 113, 0 }, + + { 114, 0 }, { 115, 0 }, { 116, 0 }, { 117, 0 }, { 118, 0 }, + { 119, 0 }, { 120, 0 }, { 121, 0 }, { 122, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 128, 0 }, + { 129, 0 }, { 130, 0 }, { 131, 0 }, { 132, 0 }, { 133, 0 }, + { 134, 0 }, { 135, 0 }, { 136, 0 }, { 137, 0 }, { 138, 0 }, + { 139, 0 }, { 140, 0 }, { 141, 0 }, { 142, 0 }, { 143, 0 }, + { 144, 0 }, { 145, 0 }, { 146, 0 }, { 147, 0 }, { 148, 0 }, + { 149, 0 }, { 150, 0 }, { 151, 0 }, { 152, 0 }, { 153, 0 }, + { 154, 0 }, { 155, 0 }, { 156, 0 }, { 157, 0 }, { 158, 0 }, + { 159, 0 }, { 160, 0 }, { 161, 0 }, { 162, 0 }, { 163, 0 }, + + { 164, 0 }, { 165, 0 }, { 166, 0 }, { 167, 0 }, { 168, 0 }, + { 169, 0 }, { 170, 0 }, { 171, 0 }, { 172, 0 }, { 173, 0 }, + { 174, 0 }, { 175, 0 }, { 176, 0 }, { 177, 0 }, { 178, 0 }, + { 179, 0 }, { 180, 0 }, { 181, 0 }, { 182, 0 }, { 183, 0 }, + { 184, 0 }, { 185, 0 }, { 186, 0 }, { 187, 0 }, { 188, 0 }, + { 189, 0 }, { 190, 0 }, { 191, 0 }, { 192, 0 }, { 193, 0 }, + { 194, 0 }, { 195, 0 }, { 196, 0 }, { 197, 0 }, { 198, 0 }, + { 199, 0 }, { 200, 0 }, { 201, 0 }, { 202, 0 }, { 203, 0 }, + { 204, 0 }, { 205, 0 }, { 206, 0 }, { 207, 0 }, { 208, 0 }, + { 209, 0 }, { 210, 0 }, { 211, 0 }, { 212, 0 }, { 213, 0 }, + + { 214, 0 }, { 215, 0 }, { 216, 0 }, { 217, 0 }, { 218, 0 }, + { 219, 0 }, { 220, 0 }, { 221, 0 }, { 222, 0 }, { 223, 0 }, + { 224, 0 }, { 225, 0 }, { 226, 0 }, { 227, 0 }, { 228, 0 }, + { 229, 0 }, { 230, 0 }, { 231, 0 }, { 232, 0 }, { 233, 0 }, + { 234, 0 }, { 235, 0 }, { 236, 0 }, { 237, 0 }, { 238, 0 }, + { 239, 0 }, { 240, 0 }, { 241, 0 }, { 242, 0 }, { 243, 0 }, + { 244, 0 }, { 245, 0 }, { 246, 0 }, { 247, 0 }, { 248, 0 }, + { 249, 0 }, { 250, 0 }, { 251, 0 }, { 252, 0 }, { 253, 0 }, + { 254, 0 }, { 255, 0 }, { 0, 12 }, { 0,52287 }, { 1, 0 }, + { 2, 0 }, { 3, 0 }, { 4, 0 }, { 5, 0 }, { 6, 0 }, + + { 7, 0 }, { 8, 0 }, { 9, 0 }, { 10, 0 }, { 11, 0 }, + { 12, 0 }, { 13, 0 }, { 14, 0 }, { 15, 0 }, { 16, 0 }, + { 17, 0 }, { 18, 0 }, { 19, 0 }, { 20, 0 }, { 21, 0 }, + { 22, 0 }, { 23, 0 }, { 24, 0 }, { 25, 0 }, { 26, 0 }, + { 27, 0 }, { 28, 0 }, { 29, 0 }, { 30, 0 }, { 31, 0 }, + { 32, 0 }, { 33, 0 }, { 34, 0 }, { 35, 0 }, { 36, 0 }, + { 37, 0 }, { 38, 0 }, { 0, 0 }, { 40, 0 }, { 41, 0 }, + { 42, 0 }, { 43, 0 }, { 44, 0 }, { 45, 0 }, { 46, 0 }, + { 47, 0 }, { 48, 0 }, { 49, 0 }, { 50, 0 }, { 51, 0 }, + { 52, 0 }, { 53, 0 }, { 54, 0 }, { 55, 0 }, { 56, 0 }, + + { 57, 0 }, { 58, 0 }, { 59, 0 }, { 60, 0 }, { 61, 0 }, + { 62, 0 }, { 63, 0 }, { 64, 0 }, { 65, 0 }, { 66, 0 }, + { 67, 0 }, { 68, 0 }, { 69, 0 }, { 70, 0 }, { 71, 0 }, + { 72, 0 }, { 73, 0 }, { 74, 0 }, { 75, 0 }, { 76, 0 }, + { 77, 0 }, { 78, 0 }, { 79, 0 }, { 80, 0 }, { 81, 0 }, + { 82, 0 }, { 83, 0 }, { 84, 0 }, { 85, 0 }, { 86, 0 }, + { 87, 0 }, { 88, 0 }, { 89, 0 }, { 90, 0 }, { 91, 0 }, + { 92, 0 }, { 93, 0 }, { 94, 0 }, { 95, 0 }, { 96, 0 }, + { 97, 0 }, { 98, 0 }, { 99, 0 }, { 100, 0 }, { 101, 0 }, + { 102, 0 }, { 103, 0 }, { 104, 0 }, { 105, 0 }, { 106, 0 }, + + { 107, 0 }, { 108, 0 }, { 109, 0 }, { 110, 0 }, { 111, 0 }, + { 112, 0 }, { 113, 0 }, { 114, 0 }, { 115, 0 }, { 116, 0 }, + { 117, 0 }, { 118, 0 }, { 119, 0 }, { 120, 0 }, { 121, 0 }, + { 122, 0 }, { 123, 0 }, { 124, 0 }, { 125, 0 }, { 126, 0 }, + { 127, 0 }, { 128, 0 }, { 129, 0 }, { 130, 0 }, { 131, 0 }, + { 132, 0 }, { 133, 0 }, { 134, 0 }, { 135, 0 }, { 136, 0 }, + { 137, 0 }, { 138, 0 }, { 139, 0 }, { 140, 0 }, { 141, 0 }, + { 142, 0 }, { 143, 0 }, { 144, 0 }, { 145, 0 }, { 146, 0 }, + { 147, 0 }, { 148, 0 }, { 149, 0 }, { 150, 0 }, { 151, 0 }, + { 152, 0 }, { 153, 0 }, { 154, 0 }, { 155, 0 }, { 156, 0 }, + + { 157, 0 }, { 158, 0 }, { 159, 0 }, { 160, 0 }, { 161, 0 }, + { 162, 0 }, { 163, 0 }, { 164, 0 }, { 165, 0 }, { 166, 0 }, + { 167, 0 }, { 168, 0 }, { 169, 0 }, { 170, 0 }, { 171, 0 }, + { 172, 0 }, { 173, 0 }, { 174, 0 }, { 175, 0 }, { 176, 0 }, + { 177, 0 }, { 178, 0 }, { 179, 0 }, { 180, 0 }, { 181, 0 }, + { 182, 0 }, { 183, 0 }, { 184, 0 }, { 185, 0 }, { 186, 0 }, + { 187, 0 }, { 188, 0 }, { 189, 0 }, { 190, 0 }, { 191, 0 }, + { 192, 0 }, { 193, 0 }, { 194, 0 }, { 195, 0 }, { 196, 0 }, + { 197, 0 }, { 198, 0 }, { 199, 0 }, { 200, 0 }, { 201, 0 }, + { 202, 0 }, { 203, 0 }, { 204, 0 }, { 205, 0 }, { 206, 0 }, + + { 207, 0 }, { 208, 0 }, { 209, 0 }, { 210, 0 }, { 211, 0 }, + { 212, 0 }, { 213, 0 }, { 214, 0 }, { 215, 0 }, { 216, 0 }, + { 217, 0 }, { 218, 0 }, { 219, 0 }, { 220, 0 }, { 221, 0 }, + { 222, 0 }, { 223, 0 }, { 224, 0 }, { 225, 0 }, { 226, 0 }, + { 227, 0 }, { 228, 0 }, { 229, 0 }, { 230, 0 }, { 231, 0 }, + { 232, 0 }, { 233, 0 }, { 234, 0 }, { 235, 0 }, { 236, 0 }, + { 237, 0 }, { 238, 0 }, { 239, 0 }, { 240, 0 }, { 241, 0 }, + { 242, 0 }, { 243, 0 }, { 244, 0 }, { 245, 0 }, { 246, 0 }, + { 247, 0 }, { 248, 0 }, { 249, 0 }, { 250, 0 }, { 251, 0 }, + { 252, 0 }, { 253, 0 }, { 254, 0 }, { 255, 0 }, { 256, 0 }, + + { 0, 9 }, { 0,52029 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 9 }, { 0,52024 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 9, 0 }, { 10, 5 }, { 0, 0 }, { 12, 0 }, { 13, 5 }, + { 9,3224 }, { 10,3224 }, { 0, 0 }, { 12,3224 }, { 13,3224 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 32, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 32,3224 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 39,-5568 }, { 45,-6151 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 45,-5551 }, { 0, 5 }, { 0,51977 }, { 1, 0 }, + { 2, 0 }, { 3, 0 }, { 4, 0 }, { 5, 0 }, { 6, 0 }, + { 7, 0 }, { 8, 0 }, { 9, 0 }, { 10, 0 }, { 11, 0 }, + { 12, 0 }, { 13, 0 }, { 14, 0 }, { 15, 0 }, { 16, 0 }, + { 17, 0 }, { 18, 0 }, { 19, 0 }, { 20, 0 }, { 21, 0 }, + { 22, 0 }, { 23, 0 }, { 24, 0 }, { 25, 0 }, { 26, 0 }, + { 27, 0 }, { 28, 0 }, { 29, 0 }, { 30, 0 }, { 31, 0 }, + { 32, 0 }, { 33, 0 }, { 34, 0 }, { 35, 0 }, { 36, 0 }, + { 37, 0 }, { 38, 0 }, { 39, 0 }, { 40, 0 }, { 41, 0 }, + { 0, 0 }, { 43, 0 }, { 44, 0 }, { 45, 0 }, { 46, 0 }, + + { 0, 0 }, { 48, 0 }, { 49, 0 }, { 50, 0 }, { 51, 0 }, + { 52, 0 }, { 53, 0 }, { 54, 0 }, { 55, 0 }, { 56, 0 }, + { 57, 0 }, { 58, 0 }, { 59, 0 }, { 60, 0 }, { 61, 0 }, + { 62, 0 }, { 63, 0 }, { 64, 0 }, { 65, 0 }, { 66, 0 }, + { 67, 0 }, { 68, 0 }, { 69, 0 }, { 70, 0 }, { 71, 0 }, + { 72, 0 }, { 73, 0 }, { 74, 0 }, { 75, 0 }, { 76, 0 }, + { 77, 0 }, { 78, 0 }, { 79, 0 }, { 80, 0 }, { 81, 0 }, + { 82, 0 }, { 83, 0 }, { 84, 0 }, { 85, 0 }, { 86, 0 }, + { 87, 0 }, { 88, 0 }, { 89, 0 }, { 90, 0 }, { 91, 0 }, + { 92, 0 }, { 93, 0 }, { 94, 0 }, { 95, 0 }, { 96, 0 }, + + { 97, 0 }, { 98, 0 }, { 99, 0 }, { 100, 0 }, { 101, 0 }, + { 102, 0 }, { 103, 0 }, { 104, 0 }, { 105, 0 }, { 106, 0 }, + { 107, 0 }, { 108, 0 }, { 109, 0 }, { 110, 0 }, { 111, 0 }, + { 112, 0 }, { 113, 0 }, { 114, 0 }, { 115, 0 }, { 116, 0 }, + { 117, 0 }, { 118, 0 }, { 119, 0 }, { 120, 0 }, { 121, 0 }, + { 122, 0 }, { 123, 0 }, { 124, 0 }, { 125, 0 }, { 126, 0 }, + { 127, 0 }, { 128, 0 }, { 129, 0 }, { 130, 0 }, { 131, 0 }, + { 132, 0 }, { 133, 0 }, { 134, 0 }, { 135, 0 }, { 136, 0 }, + { 137, 0 }, { 138, 0 }, { 139, 0 }, { 140, 0 }, { 141, 0 }, + { 142, 0 }, { 143, 0 }, { 144, 0 }, { 145, 0 }, { 146, 0 }, + + { 147, 0 }, { 148, 0 }, { 149, 0 }, { 150, 0 }, { 151, 0 }, + { 152, 0 }, { 153, 0 }, { 154, 0 }, { 155, 0 }, { 156, 0 }, + { 157, 0 }, { 158, 0 }, { 159, 0 }, { 160, 0 }, { 161, 0 }, + { 162, 0 }, { 163, 0 }, { 164, 0 }, { 165, 0 }, { 166, 0 }, + { 167, 0 }, { 168, 0 }, { 169, 0 }, { 170, 0 }, { 171, 0 }, + { 172, 0 }, { 173, 0 }, { 174, 0 }, { 175, 0 }, { 176, 0 }, + { 177, 0 }, { 178, 0 }, { 179, 0 }, { 180, 0 }, { 181, 0 }, + { 182, 0 }, { 183, 0 }, { 184, 0 }, { 185, 0 }, { 186, 0 }, + { 187, 0 }, { 188, 0 }, { 189, 0 }, { 190, 0 }, { 191, 0 }, + { 192, 0 }, { 193, 0 }, { 194, 0 }, { 195, 0 }, { 196, 0 }, + + { 197, 0 }, { 198, 0 }, { 199, 0 }, { 200, 0 }, { 201, 0 }, + { 202, 0 }, { 203, 0 }, { 204, 0 }, { 205, 0 }, { 206, 0 }, + { 207, 0 }, { 208, 0 }, { 209, 0 }, { 210, 0 }, { 211, 0 }, + { 212, 0 }, { 213, 0 }, { 214, 0 }, { 215, 0 }, { 216, 0 }, + { 217, 0 }, { 218, 0 }, { 219, 0 }, { 220, 0 }, { 221, 0 }, + { 222, 0 }, { 223, 0 }, { 224, 0 }, { 225, 0 }, { 226, 0 }, + { 227, 0 }, { 228, 0 }, { 229, 0 }, { 230, 0 }, { 231, 0 }, + { 232, 0 }, { 233, 0 }, { 234, 0 }, { 235, 0 }, { 236, 0 }, + { 237, 0 }, { 238, 0 }, { 239, 0 }, { 240, 0 }, { 241, 0 }, + { 242, 0 }, { 243, 0 }, { 244, 0 }, { 245, 0 }, { 246, 0 }, + + { 247, 0 }, { 248, 0 }, { 249, 0 }, { 250, 0 }, { 251, 0 }, + { 252, 0 }, { 253, 0 }, { 254, 0 }, { 255, 0 }, { 256, 0 }, + { 0, 3 }, { 0,51719 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 33,3224 }, + { 0, 0 }, { 35,3224 }, { 0, 0 }, { 37,3224 }, { 38,3224 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 42,3224 }, { 43,3224 }, + { 0, 0 }, { 45,3224 }, { 0, 0 }, { 47,3224 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 60,3224 }, { 61,3224 }, { 62,3224 }, { 63,3224 }, + { 64,3224 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 94,3224 }, { 0, 0 }, { 96,3224 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 124,3224 }, { 0, 0 }, { 126,3224 }, { 0, 51 }, { 0,51591 }, + { 1, 0 }, { 2, 0 }, { 3, 0 }, { 4, 0 }, { 5, 0 }, + { 6, 0 }, { 7, 0 }, { 8, 0 }, { 9, 0 }, { 10, 0 }, + + { 11, 0 }, { 12, 0 }, { 13, 0 }, { 14, 0 }, { 15, 0 }, + { 16, 0 }, { 17, 0 }, { 18, 0 }, { 19, 0 }, { 20, 0 }, + { 21, 0 }, { 22, 0 }, { 23, 0 }, { 24, 0 }, { 25, 0 }, + { 26, 0 }, { 27, 0 }, { 28, 0 }, { 29, 0 }, { 30, 0 }, + { 31, 0 }, { 32, 0 }, { 33, 0 }, { 0, 0 }, { 35, 0 }, + { 36, 0 }, { 37, 0 }, { 38, 0 }, { 39, 0 }, { 40, 0 }, + { 41, 0 }, { 42, 0 }, { 43, 0 }, { 44, 0 }, { 45, 0 }, + { 46, 0 }, { 47, 0 }, { 48, 0 }, { 49, 0 }, { 50, 0 }, + { 51, 0 }, { 52, 0 }, { 53, 0 }, { 54, 0 }, { 55, 0 }, + { 56, 0 }, { 57, 0 }, { 58, 0 }, { 59, 0 }, { 60, 0 }, + + { 61, 0 }, { 62, 0 }, { 63, 0 }, { 64, 0 }, { 65, 0 }, + { 66, 0 }, { 67, 0 }, { 68, 0 }, { 69, 0 }, { 70, 0 }, + { 71, 0 }, { 72, 0 }, { 73, 0 }, { 74, 0 }, { 75, 0 }, + { 76, 0 }, { 77, 0 }, { 78, 0 }, { 79, 0 }, { 80, 0 }, + { 81, 0 }, { 82, 0 }, { 83, 0 }, { 84, 0 }, { 85, 0 }, + { 86, 0 }, { 87, 0 }, { 88, 0 }, { 89, 0 }, { 90, 0 }, + { 91, 0 }, { 92, 0 }, { 93, 0 }, { 94, 0 }, { 95, 0 }, + { 96, 0 }, { 97, 0 }, { 98, 0 }, { 99, 0 }, { 100, 0 }, + { 101, 0 }, { 102, 0 }, { 103, 0 }, { 104, 0 }, { 105, 0 }, + { 106, 0 }, { 107, 0 }, { 108, 0 }, { 109, 0 }, { 110, 0 }, + + { 111, 0 }, { 112, 0 }, { 113, 0 }, { 114, 0 }, { 115, 0 }, + { 116, 0 }, { 117, 0 }, { 118, 0 }, { 119, 0 }, { 120, 0 }, + { 121, 0 }, { 122, 0 }, { 123, 0 }, { 124, 0 }, { 125, 0 }, + { 126, 0 }, { 127, 0 }, { 128, 0 }, { 129, 0 }, { 130, 0 }, + { 131, 0 }, { 132, 0 }, { 133, 0 }, { 134, 0 }, { 135, 0 }, + { 136, 0 }, { 137, 0 }, { 138, 0 }, { 139, 0 }, { 140, 0 }, + { 141, 0 }, { 142, 0 }, { 143, 0 }, { 144, 0 }, { 145, 0 }, + { 146, 0 }, { 147, 0 }, { 148, 0 }, { 149, 0 }, { 150, 0 }, + { 151, 0 }, { 152, 0 }, { 153, 0 }, { 154, 0 }, { 155, 0 }, + { 156, 0 }, { 157, 0 }, { 158, 0 }, { 159, 0 }, { 160, 0 }, + + { 161, 0 }, { 162, 0 }, { 163, 0 }, { 164, 0 }, { 165, 0 }, + { 166, 0 }, { 167, 0 }, { 168, 0 }, { 169, 0 }, { 170, 0 }, + { 171, 0 }, { 172, 0 }, { 173, 0 }, { 174, 0 }, { 175, 0 }, + { 176, 0 }, { 177, 0 }, { 178, 0 }, { 179, 0 }, { 180, 0 }, + { 181, 0 }, { 182, 0 }, { 183, 0 }, { 184, 0 }, { 185, 0 }, + { 186, 0 }, { 187, 0 }, { 188, 0 }, { 189, 0 }, { 190, 0 }, + { 191, 0 }, { 192, 0 }, { 193, 0 }, { 194, 0 }, { 195, 0 }, + { 196, 0 }, { 197, 0 }, { 198, 0 }, { 199, 0 }, { 200, 0 }, + { 201, 0 }, { 202, 0 }, { 203, 0 }, { 204, 0 }, { 205, 0 }, + { 206, 0 }, { 207, 0 }, { 208, 0 }, { 209, 0 }, { 210, 0 }, + + { 211, 0 }, { 212, 0 }, { 213, 0 }, { 214, 0 }, { 215, 0 }, + { 216, 0 }, { 217, 0 }, { 218, 0 }, { 219, 0 }, { 220, 0 }, + { 221, 0 }, { 222, 0 }, { 223, 0 }, { 224, 0 }, { 225, 0 }, + { 226, 0 }, { 227, 0 }, { 228, 0 }, { 229, 0 }, { 230, 0 }, + { 231, 0 }, { 232, 0 }, { 233, 0 }, { 234, 0 }, { 235, 0 }, + { 236, 0 }, { 237, 0 }, { 238, 0 }, { 239, 0 }, { 240, 0 }, + { 241, 0 }, { 242, 0 }, { 243, 0 }, { 244, 0 }, { 245, 0 }, + { 246, 0 }, { 247, 0 }, { 248, 0 }, { 249, 0 }, { 250, 0 }, + { 251, 0 }, { 252, 0 }, { 253, 0 }, { 254, 0 }, { 255, 0 }, + { 256, 0 }, { 0, 11 }, { 0,51333 }, { 1, 0 }, { 2, 0 }, + + { 3, 0 }, { 4, 0 }, { 5, 0 }, { 6, 0 }, { 7, 0 }, + { 8, 0 }, { 9, 0 }, { 10, 0 }, { 11, 0 }, { 12, 0 }, + { 13, 0 }, { 14, 0 }, { 15, 0 }, { 16, 0 }, { 17, 0 }, + { 18, 0 }, { 19, 0 }, { 20, 0 }, { 21, 0 }, { 22, 0 }, + { 23, 0 }, { 24, 0 }, { 25, 0 }, { 26, 0 }, { 27, 0 }, + { 28, 0 }, { 29, 0 }, { 30, 0 }, { 31, 0 }, { 32, 0 }, + { 33, 0 }, { 34, 0 }, { 35, 0 }, { 36, 0 }, { 37, 0 }, + { 38, 0 }, { 0, 0 }, { 40, 0 }, { 41, 0 }, { 42, 0 }, + { 43, 0 }, { 44, 0 }, { 45, 0 }, { 46, 0 }, { 47, 0 }, + { 48, 0 }, { 49, 0 }, { 50, 0 }, { 51, 0 }, { 52, 0 }, + + { 53, 0 }, { 54, 0 }, { 55, 0 }, { 56, 0 }, { 57, 0 }, + { 58, 0 }, { 59, 0 }, { 60, 0 }, { 61, 0 }, { 62, 0 }, + { 63, 0 }, { 64, 0 }, { 65, 0 }, { 66, 0 }, { 67, 0 }, + { 68, 0 }, { 69, 0 }, { 70, 0 }, { 71, 0 }, { 72, 0 }, + { 73, 0 }, { 74, 0 }, { 75, 0 }, { 76, 0 }, { 77, 0 }, + { 78, 0 }, { 79, 0 }, { 80, 0 }, { 81, 0 }, { 82, 0 }, + { 83, 0 }, { 84, 0 }, { 85, 0 }, { 86, 0 }, { 87, 0 }, + { 88, 0 }, { 89, 0 }, { 90, 0 }, { 91, 0 }, { 92, 0 }, + { 93, 0 }, { 94, 0 }, { 95, 0 }, { 96, 0 }, { 97, 0 }, + { 98, 0 }, { 99, 0 }, { 100, 0 }, { 101, 0 }, { 102, 0 }, + + { 103, 0 }, { 104, 0 }, { 105, 0 }, { 106, 0 }, { 107, 0 }, + { 108, 0 }, { 109, 0 }, { 110, 0 }, { 111, 0 }, { 112, 0 }, + { 113, 0 }, { 114, 0 }, { 115, 0 }, { 116, 0 }, { 117, 0 }, + { 118, 0 }, { 119, 0 }, { 120, 0 }, { 121, 0 }, { 122, 0 }, + { 123, 0 }, { 124, 0 }, { 125, 0 }, { 126, 0 }, { 127, 0 }, + { 128, 0 }, { 129, 0 }, { 130, 0 }, { 131, 0 }, { 132, 0 }, + { 133, 0 }, { 134, 0 }, { 135, 0 }, { 136, 0 }, { 137, 0 }, + { 138, 0 }, { 139, 0 }, { 140, 0 }, { 141, 0 }, { 142, 0 }, + { 143, 0 }, { 144, 0 }, { 145, 0 }, { 146, 0 }, { 147, 0 }, + { 148, 0 }, { 149, 0 }, { 150, 0 }, { 151, 0 }, { 152, 0 }, + + { 153, 0 }, { 154, 0 }, { 155, 0 }, { 156, 0 }, { 157, 0 }, + { 158, 0 }, { 159, 0 }, { 160, 0 }, { 161, 0 }, { 162, 0 }, + { 163, 0 }, { 164, 0 }, { 165, 0 }, { 166, 0 }, { 167, 0 }, + { 168, 0 }, { 169, 0 }, { 170, 0 }, { 171, 0 }, { 172, 0 }, + { 173, 0 }, { 174, 0 }, { 175, 0 }, { 176, 0 }, { 177, 0 }, + { 178, 0 }, { 179, 0 }, { 180, 0 }, { 181, 0 }, { 182, 0 }, + { 183, 0 }, { 184, 0 }, { 185, 0 }, { 186, 0 }, { 187, 0 }, + { 188, 0 }, { 189, 0 }, { 190, 0 }, { 191, 0 }, { 192, 0 }, + { 193, 0 }, { 194, 0 }, { 195, 0 }, { 196, 0 }, { 197, 0 }, + { 198, 0 }, { 199, 0 }, { 200, 0 }, { 201, 0 }, { 202, 0 }, + + { 203, 0 }, { 204, 0 }, { 205, 0 }, { 206, 0 }, { 207, 0 }, + { 208, 0 }, { 209, 0 }, { 210, 0 }, { 211, 0 }, { 212, 0 }, + { 213, 0 }, { 214, 0 }, { 215, 0 }, { 216, 0 }, { 217, 0 }, + { 218, 0 }, { 219, 0 }, { 220, 0 }, { 221, 0 }, { 222, 0 }, + { 223, 0 }, { 224, 0 }, { 225, 0 }, { 226, 0 }, { 227, 0 }, + { 228, 0 }, { 229, 0 }, { 230, 0 }, { 231, 0 }, { 232, 0 }, + { 233, 0 }, { 234, 0 }, { 235, 0 }, { 236, 0 }, { 237, 0 }, + { 238, 0 }, { 239, 0 }, { 240, 0 }, { 241, 0 }, { 242, 0 }, + { 243, 0 }, { 244, 0 }, { 245, 0 }, { 246, 0 }, { 247, 0 }, + { 248, 0 }, { 249, 0 }, { 250, 0 }, { 251, 0 }, { 252, 0 }, + + { 253, 0 }, { 254, 0 }, { 255, 0 }, { 256, 0 }, { 0, 16 }, + { 0,51075 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 16 }, + { 0,51070 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 9, 0 }, + { 10, 5 }, { 0, 0 }, { 12, 0 }, { 13, 5 }, { 9,2582 }, + { 10,2582 }, { 0, 0 }, { 12,2582 }, { 13,2582 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 32, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 32,2582 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 39,-6493 }, + + { 45,-7087 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 45,-6293 }, { 0, 28 }, { 0,51023 }, { 1, 0 }, { 2, 0 }, + { 3, 0 }, { 4, 0 }, { 5, 0 }, { 6, 0 }, { 7, 0 }, + { 8, 0 }, { 9, 0 }, { 10, 0 }, { 11, 0 }, { 12, 0 }, + { 13, 0 }, { 14, 0 }, { 15, 0 }, { 16, 0 }, { 17, 0 }, + { 18, 0 }, { 19, 0 }, { 20, 0 }, { 21, 0 }, { 22, 0 }, + { 23, 0 }, { 24, 0 }, { 25, 0 }, { 26, 0 }, { 27, 0 }, + { 28, 0 }, { 29, 0 }, { 30, 0 }, { 31, 0 }, { 32, 0 }, + { 33, 0 }, { 34, 0 }, { 35, 0 }, { 36, 0 }, { 37, 0 }, + { 38, 0 }, { 0, 0 }, { 40, 0 }, { 41, 0 }, { 42, 0 }, + + { 43, 0 }, { 44, 0 }, { 45, 0 }, { 46, 0 }, { 47, 0 }, + { 48, 0 }, { 49, 0 }, { 50, 0 }, { 51, 0 }, { 52, 0 }, + { 53, 0 }, { 54, 0 }, { 55, 0 }, { 56, 0 }, { 57, 0 }, + { 58, 0 }, { 59, 0 }, { 60, 0 }, { 61, 0 }, { 62, 0 }, + { 63, 0 }, { 64, 0 }, { 65, 0 }, { 66, 0 }, { 67, 0 }, + { 68, 0 }, { 69, 0 }, { 70, 0 }, { 71, 0 }, { 72, 0 }, + { 73, 0 }, { 74, 0 }, { 75, 0 }, { 76, 0 }, { 77, 0 }, + { 78, 0 }, { 79, 0 }, { 80, 0 }, { 81, 0 }, { 82, 0 }, + { 83, 0 }, { 84, 0 }, { 85, 0 }, { 86, 0 }, { 87, 0 }, + { 88, 0 }, { 89, 0 }, { 90, 0 }, { 91, 0 }, { 0, 0 }, + + { 93, 0 }, { 94, 0 }, { 95, 0 }, { 96, 0 }, { 97, 0 }, + { 98, 0 }, { 99, 0 }, { 100, 0 }, { 101, 0 }, { 102, 0 }, + { 103, 0 }, { 104, 0 }, { 105, 0 }, { 106, 0 }, { 107, 0 }, + { 108, 0 }, { 109, 0 }, { 110, 0 }, { 111, 0 }, { 112, 0 }, + { 113, 0 }, { 114, 0 }, { 115, 0 }, { 116, 0 }, { 117, 0 }, + { 118, 0 }, { 119, 0 }, { 120, 0 }, { 121, 0 }, { 122, 0 }, + { 123, 0 }, { 124, 0 }, { 125, 0 }, { 126, 0 }, { 127, 0 }, + { 128, 0 }, { 129, 0 }, { 130, 0 }, { 131, 0 }, { 132, 0 }, + { 133, 0 }, { 134, 0 }, { 135, 0 }, { 136, 0 }, { 137, 0 }, + { 138, 0 }, { 139, 0 }, { 140, 0 }, { 141, 0 }, { 142, 0 }, + + { 143, 0 }, { 144, 0 }, { 145, 0 }, { 146, 0 }, { 147, 0 }, + { 148, 0 }, { 149, 0 }, { 150, 0 }, { 151, 0 }, { 152, 0 }, + { 153, 0 }, { 154, 0 }, { 155, 0 }, { 156, 0 }, { 157, 0 }, + { 158, 0 }, { 159, 0 }, { 160, 0 }, { 161, 0 }, { 162, 0 }, + { 163, 0 }, { 164, 0 }, { 165, 0 }, { 166, 0 }, { 167, 0 }, + { 168, 0 }, { 169, 0 }, { 170, 0 }, { 171, 0 }, { 172, 0 }, + { 173, 0 }, { 174, 0 }, { 175, 0 }, { 176, 0 }, { 177, 0 }, + { 178, 0 }, { 179, 0 }, { 180, 0 }, { 181, 0 }, { 182, 0 }, + { 183, 0 }, { 184, 0 }, { 185, 0 }, { 186, 0 }, { 187, 0 }, + { 188, 0 }, { 189, 0 }, { 190, 0 }, { 191, 0 }, { 192, 0 }, + + { 193, 0 }, { 194, 0 }, { 195, 0 }, { 196, 0 }, { 197, 0 }, + { 198, 0 }, { 199, 0 }, { 200, 0 }, { 201, 0 }, { 202, 0 }, + { 203, 0 }, { 204, 0 }, { 205, 0 }, { 206, 0 }, { 207, 0 }, + { 208, 0 }, { 209, 0 }, { 210, 0 }, { 211, 0 }, { 212, 0 }, + { 213, 0 }, { 214, 0 }, { 215, 0 }, { 216, 0 }, { 217, 0 }, + { 218, 0 }, { 219, 0 }, { 220, 0 }, { 221, 0 }, { 222, 0 }, + { 223, 0 }, { 224, 0 }, { 225, 0 }, { 226, 0 }, { 227, 0 }, + { 228, 0 }, { 229, 0 }, { 230, 0 }, { 231, 0 }, { 232, 0 }, + { 233, 0 }, { 234, 0 }, { 235, 0 }, { 236, 0 }, { 237, 0 }, + { 238, 0 }, { 239, 0 }, { 240, 0 }, { 241, 0 }, { 242, 0 }, + + { 243, 0 }, { 244, 0 }, { 245, 0 }, { 246, 0 }, { 247, 0 }, + { 248, 0 }, { 249, 0 }, { 250, 0 }, { 251, 0 }, { 252, 0 }, + { 253, 0 }, { 254, 0 }, { 255, 0 }, { 256, 0 }, { 0, 22 }, + { 0,50765 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 22 }, + { 0,50760 }, { 0, 35 }, { 0,50758 }, { 0, 0 }, { 9, 0 }, + { 10, 5 }, { 0, 0 }, { 12, 0 }, { 13, 5 }, { 9,2651 }, + { 10,2651 }, { 0, 0 }, { 12,2651 }, { 13,2651 }, { 0, 33 }, + { 0,50745 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 32, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 32,2651 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 33 }, { 0,50722 }, { 39,-6601 }, + { 45,-7357 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 45,-6592 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 48,2954 }, { 49,2954 }, { 50,2954 }, { 51,2954 }, { 52,2954 }, + { 53,2954 }, { 54,2954 }, { 55,2954 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 48,2949 }, { 49,2949 }, + { 50,2949 }, { 51,2949 }, { 52,2949 }, { 53,2949 }, { 54,2949 }, + { 55,2949 }, { 56,2949 }, { 57,2949 }, { 0, 0 }, { 0, 0 }, + { 0, 34 }, { 0,50684 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 65,2949 }, { 66,2949 }, { 67,2949 }, { 68,2949 }, { 69,2949 }, + { 70,2949 }, { 48,2949 }, { 49,2949 }, { 50,2949 }, { 51,2949 }, + { 52,2949 }, { 53,2949 }, { 54,2949 }, { 55,2949 }, { 56,2949 }, + { 57,2949 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 65,2949 }, { 66,2949 }, + { 67,2949 }, { 68,2949 }, { 69,2949 }, { 70,2949 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 97,2949 }, { 98,2949 }, { 99,2949 }, + { 100,2949 }, { 101,2949 }, { 102,2949 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 48,2949 }, + { 49,2949 }, { 50,2949 }, { 51,2949 }, { 52,2949 }, { 53,2949 }, + + { 54,2949 }, { 55,2949 }, { 56,2949 }, { 57,2949 }, { 0, 0 }, + { 97,2949 }, { 98,2949 }, { 99,2949 }, { 100,2949 }, { 101,2949 }, + { 102,2949 }, { 65,2949 }, { 66,2949 }, { 67,2949 }, { 68,2949 }, + { 69,2949 }, { 70,2949 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 97,2949 }, { 98,2949 }, + { 99,2949 }, { 100,2949 }, { 101,2949 }, { 102,2949 }, { 0, 27 }, + + { 0,50580 }, { 1, 0 }, { 2, 0 }, { 3, 0 }, { 4, 0 }, + { 5, 0 }, { 6, 0 }, { 7, 0 }, { 8, 0 }, { 9, 0 }, + { 10, 0 }, { 11, 0 }, { 12, 0 }, { 13, 0 }, { 14, 0 }, + { 15, 0 }, { 16, 0 }, { 17, 0 }, { 18, 0 }, { 19, 0 }, + { 20, 0 }, { 21, 0 }, { 22, 0 }, { 23, 0 }, { 24, 0 }, + { 25, 0 }, { 26, 0 }, { 27, 0 }, { 28, 0 }, { 29, 0 }, + { 30, 0 }, { 31, 0 }, { 32, 0 }, { 33, 0 }, { 34, 0 }, + { 35, 0 }, { 36, 0 }, { 37, 0 }, { 38, 0 }, { 0, 0 }, + { 40, 0 }, { 41, 0 }, { 42, 0 }, { 43, 0 }, { 44, 0 }, + { 45, 0 }, { 46, 0 }, { 47, 0 }, { 48, 0 }, { 49, 0 }, + + { 50, 0 }, { 51, 0 }, { 52, 0 }, { 53, 0 }, { 54, 0 }, + { 55, 0 }, { 56, 0 }, { 57, 0 }, { 58, 0 }, { 59, 0 }, + { 60, 0 }, { 61, 0 }, { 62, 0 }, { 63, 0 }, { 64, 0 }, + { 65, 0 }, { 66, 0 }, { 67, 0 }, { 68, 0 }, { 69, 0 }, + { 70, 0 }, { 71, 0 }, { 72, 0 }, { 73, 0 }, { 74, 0 }, + { 75, 0 }, { 76, 0 }, { 77, 0 }, { 78, 0 }, { 79, 0 }, + { 80, 0 }, { 81, 0 }, { 82, 0 }, { 83, 0 }, { 84, 0 }, + { 85, 0 }, { 86, 0 }, { 87, 0 }, { 88, 0 }, { 89, 0 }, + { 90, 0 }, { 91, 0 }, { 92, 0 }, { 93, 0 }, { 94, 0 }, + { 95, 0 }, { 96, 0 }, { 97, 0 }, { 98, 0 }, { 99, 0 }, + + { 100, 0 }, { 101, 0 }, { 102, 0 }, { 103, 0 }, { 104, 0 }, + { 105, 0 }, { 106, 0 }, { 107, 0 }, { 108, 0 }, { 109, 0 }, + { 110, 0 }, { 111, 0 }, { 112, 0 }, { 113, 0 }, { 114, 0 }, + { 115, 0 }, { 116, 0 }, { 117, 0 }, { 118, 0 }, { 119, 0 }, + { 120, 0 }, { 121, 0 }, { 122, 0 }, { 123, 0 }, { 124, 0 }, + { 125, 0 }, { 126, 0 }, { 127, 0 }, { 128, 0 }, { 129, 0 }, + { 130, 0 }, { 131, 0 }, { 132, 0 }, { 133, 0 }, { 134, 0 }, + { 135, 0 }, { 136, 0 }, { 137, 0 }, { 138, 0 }, { 139, 0 }, + { 140, 0 }, { 141, 0 }, { 142, 0 }, { 143, 0 }, { 144, 0 }, + { 145, 0 }, { 146, 0 }, { 147, 0 }, { 148, 0 }, { 149, 0 }, + + { 150, 0 }, { 151, 0 }, { 152, 0 }, { 153, 0 }, { 154, 0 }, + { 155, 0 }, { 156, 0 }, { 157, 0 }, { 158, 0 }, { 159, 0 }, + { 160, 0 }, { 161, 0 }, { 162, 0 }, { 163, 0 }, { 164, 0 }, + { 165, 0 }, { 166, 0 }, { 167, 0 }, { 168, 0 }, { 169, 0 }, + { 170, 0 }, { 171, 0 }, { 172, 0 }, { 173, 0 }, { 174, 0 }, + { 175, 0 }, { 176, 0 }, { 177, 0 }, { 178, 0 }, { 179, 0 }, + { 180, 0 }, { 181, 0 }, { 182, 0 }, { 183, 0 }, { 184, 0 }, + { 185, 0 }, { 186, 0 }, { 187, 0 }, { 188, 0 }, { 189, 0 }, + { 190, 0 }, { 191, 0 }, { 192, 0 }, { 193, 0 }, { 194, 0 }, + { 195, 0 }, { 196, 0 }, { 197, 0 }, { 198, 0 }, { 199, 0 }, + + { 200, 0 }, { 201, 0 }, { 202, 0 }, { 203, 0 }, { 204, 0 }, + { 205, 0 }, { 206, 0 }, { 207, 0 }, { 208, 0 }, { 209, 0 }, + { 210, 0 }, { 211, 0 }, { 212, 0 }, { 213, 0 }, { 214, 0 }, + { 215, 0 }, { 216, 0 }, { 217, 0 }, { 218, 0 }, { 219, 0 }, + { 220, 0 }, { 221, 0 }, { 222, 0 }, { 223, 0 }, { 224, 0 }, + { 225, 0 }, { 226, 0 }, { 227, 0 }, { 228, 0 }, { 229, 0 }, + { 230, 0 }, { 231, 0 }, { 232, 0 }, { 233, 0 }, { 234, 0 }, + { 235, 0 }, { 236, 0 }, { 237, 0 }, { 238, 0 }, { 239, 0 }, + { 240, 0 }, { 241, 0 }, { 242, 0 }, { 243, 0 }, { 244, 0 }, + { 245, 0 }, { 246, 0 }, { 247, 0 }, { 248, 0 }, { 249, 0 }, + + { 250, 0 }, { 251, 0 }, { 252, 0 }, { 253, 0 }, { 254, 0 }, + { 255, 0 }, { 256, 0 }, { 0, 42 }, { 0,50322 }, { 1, 0 }, + { 2, 0 }, { 3, 0 }, { 4, 0 }, { 5, 0 }, { 6, 0 }, + { 7, 0 }, { 8, 0 }, { 9, 0 }, { 10, 0 }, { 11, 0 }, + { 12, 0 }, { 13, 0 }, { 14, 0 }, { 15, 0 }, { 16, 0 }, + { 17, 0 }, { 18, 0 }, { 19, 0 }, { 20, 0 }, { 21, 0 }, + { 22, 0 }, { 23, 0 }, { 24, 0 }, { 25, 0 }, { 26, 0 }, + { 27, 0 }, { 28, 0 }, { 29, 0 }, { 30, 0 }, { 31, 0 }, + { 32, 0 }, { 33, 0 }, { 34, 0 }, { 35, 0 }, { 0, 0 }, + { 37, 0 }, { 38, 0 }, { 39, 0 }, { 40, 0 }, { 41, 0 }, + + { 42, 0 }, { 43, 0 }, { 44, 0 }, { 45, 0 }, { 46, 0 }, + { 47, 0 }, { 48, 0 }, { 49, 0 }, { 50, 0 }, { 51, 0 }, + { 52, 0 }, { 53, 0 }, { 54, 0 }, { 55, 0 }, { 56, 0 }, + { 57, 0 }, { 58, 0 }, { 59, 0 }, { 60, 0 }, { 61, 0 }, + { 62, 0 }, { 63, 0 }, { 64, 0 }, { 65, 0 }, { 66, 0 }, + { 67, 0 }, { 68, 0 }, { 69, 0 }, { 70, 0 }, { 71, 0 }, + { 72, 0 }, { 73, 0 }, { 74, 0 }, { 75, 0 }, { 76, 0 }, + { 77, 0 }, { 78, 0 }, { 79, 0 }, { 80, 0 }, { 81, 0 }, + { 82, 0 }, { 83, 0 }, { 84, 0 }, { 85, 0 }, { 86, 0 }, + { 87, 0 }, { 88, 0 }, { 89, 0 }, { 90, 0 }, { 91, 0 }, + + { 92, 0 }, { 93, 0 }, { 94, 0 }, { 95, 0 }, { 96, 0 }, + { 97, 0 }, { 98, 0 }, { 99, 0 }, { 100, 0 }, { 101, 0 }, + { 102, 0 }, { 103, 0 }, { 104, 0 }, { 105, 0 }, { 106, 0 }, + { 107, 0 }, { 108, 0 }, { 109, 0 }, { 110, 0 }, { 111, 0 }, + { 112, 0 }, { 113, 0 }, { 114, 0 }, { 115, 0 }, { 116, 0 }, + { 117, 0 }, { 118, 0 }, { 119, 0 }, { 120, 0 }, { 121, 0 }, + { 122, 0 }, { 123, 0 }, { 124, 0 }, { 125, 0 }, { 126, 0 }, + { 127, 0 }, { 128, 0 }, { 129, 0 }, { 130, 0 }, { 131, 0 }, + { 132, 0 }, { 133, 0 }, { 134, 0 }, { 135, 0 }, { 136, 0 }, + { 137, 0 }, { 138, 0 }, { 139, 0 }, { 140, 0 }, { 141, 0 }, + + { 142, 0 }, { 143, 0 }, { 144, 0 }, { 145, 0 }, { 146, 0 }, + { 147, 0 }, { 148, 0 }, { 149, 0 }, { 150, 0 }, { 151, 0 }, + { 152, 0 }, { 153, 0 }, { 154, 0 }, { 155, 0 }, { 156, 0 }, + { 157, 0 }, { 158, 0 }, { 159, 0 }, { 160, 0 }, { 161, 0 }, + { 162, 0 }, { 163, 0 }, { 164, 0 }, { 165, 0 }, { 166, 0 }, + { 167, 0 }, { 168, 0 }, { 169, 0 }, { 170, 0 }, { 171, 0 }, + { 172, 0 }, { 173, 0 }, { 174, 0 }, { 175, 0 }, { 176, 0 }, + { 177, 0 }, { 178, 0 }, { 179, 0 }, { 180, 0 }, { 181, 0 }, + { 182, 0 }, { 183, 0 }, { 184, 0 }, { 185, 0 }, { 186, 0 }, + { 187, 0 }, { 188, 0 }, { 189, 0 }, { 190, 0 }, { 191, 0 }, + + { 192, 0 }, { 193, 0 }, { 194, 0 }, { 195, 0 }, { 196, 0 }, + { 197, 0 }, { 198, 0 }, { 199, 0 }, { 200, 0 }, { 201, 0 }, + { 202, 0 }, { 203, 0 }, { 204, 0 }, { 205, 0 }, { 206, 0 }, + { 207, 0 }, { 208, 0 }, { 209, 0 }, { 210, 0 }, { 211, 0 }, + { 212, 0 }, { 213, 0 }, { 214, 0 }, { 215, 0 }, { 216, 0 }, + { 217, 0 }, { 218, 0 }, { 219, 0 }, { 220, 0 }, { 221, 0 }, + { 222, 0 }, { 223, 0 }, { 224, 0 }, { 225, 0 }, { 226, 0 }, + { 227, 0 }, { 228, 0 }, { 229, 0 }, { 230, 0 }, { 231, 0 }, + { 232, 0 }, { 233, 0 }, { 234, 0 }, { 235, 0 }, { 236, 0 }, + { 237, 0 }, { 238, 0 }, { 239, 0 }, { 240, 0 }, { 241, 0 }, + + { 242, 0 }, { 243, 0 }, { 244, 0 }, { 245, 0 }, { 246, 0 }, + { 247, 0 }, { 248, 0 }, { 249, 0 }, { 250, 0 }, { 251, 0 }, + { 252, 0 }, { 253, 0 }, { 254, 0 }, { 255, 0 }, { 256, 0 }, + { 0, 43 }, { 0,50064 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 36,-8054 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 48,2401 }, + { 49,2401 }, { 50,2401 }, { 51,2401 }, { 52,2401 }, { 53,2401 }, + { 54,2401 }, { 55,2401 }, { 56,2401 }, { 57,2401 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 65,2401 }, { 66,2401 }, { 67,2401 }, { 68,2401 }, + { 69,2401 }, { 70,2401 }, { 71,2401 }, { 72,2401 }, { 73,2401 }, + { 74,2401 }, { 75,2401 }, { 76,2401 }, { 77,2401 }, { 78,2401 }, + { 79,2401 }, { 80,2401 }, { 81,2401 }, { 82,2401 }, { 83,2401 }, + + { 84,2401 }, { 85,2401 }, { 86,2401 }, { 87,2401 }, { 88,2401 }, + { 89,2401 }, { 90,2401 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 95,2401 }, { 0, 0 }, { 97,2401 }, { 98,2401 }, + { 99,2401 }, { 100,2401 }, { 101,2401 }, { 102,2401 }, { 103,2401 }, + { 104,2401 }, { 105,2401 }, { 106,2401 }, { 107,2401 }, { 108,2401 }, + { 109,2401 }, { 110,2401 }, { 111,2401 }, { 112,2401 }, { 113,2401 }, + { 114,2401 }, { 115,2401 }, { 116,2401 }, { 117,2401 }, { 118,2401 }, + { 119,2401 }, { 120,2401 }, { 121,2401 }, { 122,2401 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 128,2401 }, + { 129,2401 }, { 130,2401 }, { 131,2401 }, { 132,2401 }, { 133,2401 }, + + { 134,2401 }, { 135,2401 }, { 136,2401 }, { 137,2401 }, { 138,2401 }, + { 139,2401 }, { 140,2401 }, { 141,2401 }, { 142,2401 }, { 143,2401 }, + { 144,2401 }, { 145,2401 }, { 146,2401 }, { 147,2401 }, { 148,2401 }, + { 149,2401 }, { 150,2401 }, { 151,2401 }, { 152,2401 }, { 153,2401 }, + { 154,2401 }, { 155,2401 }, { 156,2401 }, { 157,2401 }, { 158,2401 }, + { 159,2401 }, { 160,2401 }, { 161,2401 }, { 162,2401 }, { 163,2401 }, + { 164,2401 }, { 165,2401 }, { 166,2401 }, { 167,2401 }, { 168,2401 }, + { 169,2401 }, { 170,2401 }, { 171,2401 }, { 172,2401 }, { 173,2401 }, + { 174,2401 }, { 175,2401 }, { 176,2401 }, { 177,2401 }, { 178,2401 }, + { 179,2401 }, { 180,2401 }, { 181,2401 }, { 182,2401 }, { 183,2401 }, + + { 184,2401 }, { 185,2401 }, { 186,2401 }, { 187,2401 }, { 188,2401 }, + { 189,2401 }, { 190,2401 }, { 191,2401 }, { 192,2401 }, { 193,2401 }, + { 194,2401 }, { 195,2401 }, { 196,2401 }, { 197,2401 }, { 198,2401 }, + { 199,2401 }, { 200,2401 }, { 201,2401 }, { 202,2401 }, { 203,2401 }, + { 204,2401 }, { 205,2401 }, { 206,2401 }, { 207,2401 }, { 208,2401 }, + { 209,2401 }, { 210,2401 }, { 211,2401 }, { 212,2401 }, { 213,2401 }, + { 214,2401 }, { 215,2401 }, { 216,2401 }, { 217,2401 }, { 218,2401 }, + { 219,2401 }, { 220,2401 }, { 221,2401 }, { 222,2401 }, { 223,2401 }, + { 224,2401 }, { 225,2401 }, { 226,2401 }, { 227,2401 }, { 228,2401 }, + { 229,2401 }, { 230,2401 }, { 231,2401 }, { 232,2401 }, { 233,2401 }, + + { 234,2401 }, { 235,2401 }, { 236,2401 }, { 237,2401 }, { 238,2401 }, + { 239,2401 }, { 240,2401 }, { 241,2401 }, { 242,2401 }, { 243,2401 }, + { 244,2401 }, { 245,2401 }, { 246,2401 }, { 247,2401 }, { 248,2401 }, + { 249,2401 }, { 250,2401 }, { 251,2401 }, { 252,2401 }, { 253,2401 }, + { 254,2401 }, { 255,2401 }, { 0, 48 }, { 0,49807 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 24 }, { 0,49802 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 9, 0 }, { 10, 0 }, { 0, 0 }, + { 12, 0 }, { 13, 0 }, { 9, 0 }, { 10, 16 }, { 0, 0 }, + { 12, 0 }, { 13, 16 }, { 0, 0 }, { 0, 24 }, { 0,49786 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 33 }, { 0,49781 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 9,2638 }, { 10,2638 }, + { 32, 0 }, { 12,2638 }, { 13,2638 }, { 0, 0 }, { 0, 0 }, + { 32, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 45,-8283 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 45,-8030 }, { 0, 0 }, + { 0, 0 }, { 32,2638 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 39,-7575 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 45,-7309 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 48,3010 }, { 49,3010 }, { 50,3010 }, + + { 51,3010 }, { 52,3010 }, { 53,3010 }, { 54,3010 }, { 55,3010 }, + { 56,3010 }, { 57,3010 }, { 0, 0 }, { 85,-8050 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 85,-7798 }, { 65,3010 }, + { 66,3010 }, { 67,3010 }, { 68,3010 }, { 69,3010 }, { 70,3010 }, + { 0, 33 }, { 0,49709 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 85,-7814 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 117,-8050 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 117,-7798 }, { 97,3010 }, { 98,3010 }, { 99,3010 }, { 100,3010 }, + + { 101,3010 }, { 102,3010 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 40 }, { 0,49671 }, + { 0, 0 }, { 117,-7814 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 48,2961 }, + { 49,2961 }, { 50,2961 }, { 51,2961 }, { 52,2961 }, { 53,2961 }, + { 54,2961 }, { 55,2961 }, { 56,2961 }, { 57,2961 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 65,2961 }, { 66,2961 }, { 67,2961 }, { 68,2961 }, + { 69,2961 }, { 70,2961 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 36,-8627 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 48, 0 }, { 49, 0 }, { 50, 0 }, + { 51, 0 }, { 52, 0 }, { 53, 0 }, { 54, 0 }, { 55, 0 }, + { 56, 0 }, { 57, 0 }, { 0, 0 }, { 97,2961 }, { 98,2961 }, + { 99,2961 }, { 100,2961 }, { 101,2961 }, { 102,2961 }, { 65, 0 }, + { 66, 0 }, { 67, 0 }, { 68, 0 }, { 69, 0 }, { 70, 0 }, + { 71, 0 }, { 72, 0 }, { 73, 0 }, { 74, 0 }, { 75, 0 }, + { 76, 0 }, { 77, 0 }, { 78, 0 }, { 79, 0 }, { 80, 0 }, + { 81, 0 }, { 82, 0 }, { 83, 0 }, { 84, 0 }, { 85, 0 }, + { 86, 0 }, { 87, 0 }, { 88, 0 }, { 89, 0 }, { 90, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 95, 0 }, + { 0, 0 }, { 97, 0 }, { 98, 0 }, { 99, 0 }, { 100, 0 }, + { 101, 0 }, { 102, 0 }, { 103, 0 }, { 104, 0 }, { 105, 0 }, + { 106, 0 }, { 107, 0 }, { 108, 0 }, { 109, 0 }, { 110, 0 }, + { 111, 0 }, { 112, 0 }, { 113, 0 }, { 114, 0 }, { 115, 0 }, + { 116, 0 }, { 117, 0 }, { 118, 0 }, { 119, 0 }, { 120, 0 }, + { 121, 0 }, { 122, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 128, 0 }, { 129, 0 }, { 130, 0 }, + { 131, 0 }, { 132, 0 }, { 133, 0 }, { 134, 0 }, { 135, 0 }, + { 136, 0 }, { 137, 0 }, { 138, 0 }, { 139, 0 }, { 140, 0 }, + + { 141, 0 }, { 142, 0 }, { 143, 0 }, { 144, 0 }, { 145, 0 }, + { 146, 0 }, { 147, 0 }, { 148, 0 }, { 149, 0 }, { 150, 0 }, + { 151, 0 }, { 152, 0 }, { 153, 0 }, { 154, 0 }, { 155, 0 }, + { 156, 0 }, { 157, 0 }, { 158, 0 }, { 159, 0 }, { 160, 0 }, + { 161, 0 }, { 162, 0 }, { 163, 0 }, { 164, 0 }, { 165, 0 }, + { 166, 0 }, { 167, 0 }, { 168, 0 }, { 169, 0 }, { 170, 0 }, + { 171, 0 }, { 172, 0 }, { 173, 0 }, { 174, 0 }, { 175, 0 }, + { 176, 0 }, { 177, 0 }, { 178, 0 }, { 179, 0 }, { 180, 0 }, + { 181, 0 }, { 182, 0 }, { 183, 0 }, { 184, 0 }, { 185, 0 }, + { 186, 0 }, { 187, 0 }, { 188, 0 }, { 189, 0 }, { 190, 0 }, + + { 191, 0 }, { 192, 0 }, { 193, 0 }, { 194, 0 }, { 195, 0 }, + { 196, 0 }, { 197, 0 }, { 198, 0 }, { 199, 0 }, { 200, 0 }, + { 201, 0 }, { 202, 0 }, { 203, 0 }, { 204, 0 }, { 205, 0 }, + { 206, 0 }, { 207, 0 }, { 208, 0 }, { 209, 0 }, { 210, 0 }, + { 211, 0 }, { 212, 0 }, { 213, 0 }, { 214, 0 }, { 215, 0 }, + { 216, 0 }, { 217, 0 }, { 218, 0 }, { 219, 0 }, { 220, 0 }, + { 221, 0 }, { 222, 0 }, { 223, 0 }, { 224, 0 }, { 225, 0 }, + { 226, 0 }, { 227, 0 }, { 228, 0 }, { 229, 0 }, { 230, 0 }, + { 231, 0 }, { 232, 0 }, { 233, 0 }, { 234, 0 }, { 235, 0 }, + { 236, 0 }, { 237, 0 }, { 238, 0 }, { 239, 0 }, { 240, 0 }, + + { 241, 0 }, { 242, 0 }, { 243, 0 }, { 244, 0 }, { 245, 0 }, + { 246, 0 }, { 247, 0 }, { 248, 0 }, { 249, 0 }, { 250, 0 }, + { 251, 0 }, { 252, 0 }, { 253, 0 }, { 254, 0 }, { 255, 0 }, + { 0, 1 }, { 0,49414 }, { 1, 0 }, { 2, 0 }, { 3, 0 }, + { 4, 0 }, { 5, 0 }, { 6, 0 }, { 7, 0 }, { 8, 0 }, + { 9, 0 }, { 0, 0 }, { 11, 0 }, { 12, 0 }, { 0, 0 }, + { 14, 0 }, { 15, 0 }, { 16, 0 }, { 17, 0 }, { 18, 0 }, + { 19, 0 }, { 20, 0 }, { 21, 0 }, { 22, 0 }, { 23, 0 }, + { 24, 0 }, { 25, 0 }, { 26, 0 }, { 27, 0 }, { 28, 0 }, + { 29, 0 }, { 30, 0 }, { 31, 0 }, { 32, 0 }, { 33, 0 }, + + { 34, 0 }, { 35, 0 }, { 36, 0 }, { 37, 0 }, { 38, 0 }, + { 39, 0 }, { 40, 0 }, { 41, 0 }, { 42, 0 }, { 43, 0 }, + { 44, 0 }, { 45, 0 }, { 46, 0 }, { 47, 0 }, { 48, 0 }, + { 49, 0 }, { 50, 0 }, { 51, 0 }, { 52, 0 }, { 53, 0 }, + { 54, 0 }, { 55, 0 }, { 56, 0 }, { 57, 0 }, { 58, 0 }, + { 59, 0 }, { 60, 0 }, { 61, 0 }, { 62, 0 }, { 63, 0 }, + { 64, 0 }, { 65, 0 }, { 66, 0 }, { 67, 0 }, { 68, 0 }, + { 69, 0 }, { 70, 0 }, { 71, 0 }, { 72, 0 }, { 73, 0 }, + { 74, 0 }, { 75, 0 }, { 76, 0 }, { 77, 0 }, { 78, 0 }, + { 79, 0 }, { 80, 0 }, { 81, 0 }, { 82, 0 }, { 83, 0 }, + + { 84, 0 }, { 85, 0 }, { 86, 0 }, { 87, 0 }, { 88, 0 }, + { 89, 0 }, { 90, 0 }, { 91, 0 }, { 92, 0 }, { 93, 0 }, + { 94, 0 }, { 95, 0 }, { 96, 0 }, { 97, 0 }, { 98, 0 }, + { 99, 0 }, { 100, 0 }, { 101, 0 }, { 102, 0 }, { 103, 0 }, + { 104, 0 }, { 105, 0 }, { 106, 0 }, { 107, 0 }, { 108, 0 }, + { 109, 0 }, { 110, 0 }, { 111, 0 }, { 112, 0 }, { 113, 0 }, + { 114, 0 }, { 115, 0 }, { 116, 0 }, { 117, 0 }, { 118, 0 }, + { 119, 0 }, { 120, 0 }, { 121, 0 }, { 122, 0 }, { 123, 0 }, + { 124, 0 }, { 125, 0 }, { 126, 0 }, { 127, 0 }, { 128, 0 }, + { 129, 0 }, { 130, 0 }, { 131, 0 }, { 132, 0 }, { 133, 0 }, + + { 134, 0 }, { 135, 0 }, { 136, 0 }, { 137, 0 }, { 138, 0 }, + { 139, 0 }, { 140, 0 }, { 141, 0 }, { 142, 0 }, { 143, 0 }, + { 144, 0 }, { 145, 0 }, { 146, 0 }, { 147, 0 }, { 148, 0 }, + { 149, 0 }, { 150, 0 }, { 151, 0 }, { 152, 0 }, { 153, 0 }, + { 154, 0 }, { 155, 0 }, { 156, 0 }, { 157, 0 }, { 158, 0 }, + { 159, 0 }, { 160, 0 }, { 161, 0 }, { 162, 0 }, { 163, 0 }, + { 164, 0 }, { 165, 0 }, { 166, 0 }, { 167, 0 }, { 168, 0 }, + { 169, 0 }, { 170, 0 }, { 171, 0 }, { 172, 0 }, { 173, 0 }, + { 174, 0 }, { 175, 0 }, { 176, 0 }, { 177, 0 }, { 178, 0 }, + { 179, 0 }, { 180, 0 }, { 181, 0 }, { 182, 0 }, { 183, 0 }, + + { 184, 0 }, { 185, 0 }, { 186, 0 }, { 187, 0 }, { 188, 0 }, + { 189, 0 }, { 190, 0 }, { 191, 0 }, { 192, 0 }, { 193, 0 }, + { 194, 0 }, { 195, 0 }, { 196, 0 }, { 197, 0 }, { 198, 0 }, + { 199, 0 }, { 200, 0 }, { 201, 0 }, { 202, 0 }, { 203, 0 }, + { 204, 0 }, { 205, 0 }, { 206, 0 }, { 207, 0 }, { 208, 0 }, + { 209, 0 }, { 210, 0 }, { 211, 0 }, { 212, 0 }, { 213, 0 }, + { 214, 0 }, { 215, 0 }, { 216, 0 }, { 217, 0 }, { 218, 0 }, + { 219, 0 }, { 220, 0 }, { 221, 0 }, { 222, 0 }, { 223, 0 }, + { 224, 0 }, { 225, 0 }, { 226, 0 }, { 227, 0 }, { 228, 0 }, + { 229, 0 }, { 230, 0 }, { 231, 0 }, { 232, 0 }, { 233, 0 }, + + { 234, 0 }, { 235, 0 }, { 236, 0 }, { 237, 0 }, { 238, 0 }, + { 239, 0 }, { 240, 0 }, { 241, 0 }, { 242, 0 }, { 243, 0 }, + { 244, 0 }, { 245, 0 }, { 246, 0 }, { 247, 0 }, { 248, 0 }, + { 249, 0 }, { 250, 0 }, { 251, 0 }, { 252, 0 }, { 253, 0 }, + { 254, 0 }, { 255, 0 }, { 256, 0 }, { 0, 1 }, { 0,49156 }, + { 1,-258 }, { 2,-258 }, { 3,-258 }, { 4,-258 }, { 5,-258 }, + { 6,-258 }, { 7,-258 }, { 8,-258 }, { 9,-258 }, { 0, 0 }, + { 11,-258 }, { 12,-258 }, { 0, 0 }, { 14,-258 }, { 15,-258 }, + { 16,-258 }, { 17,-258 }, { 18,-258 }, { 19,-258 }, { 20,-258 }, + { 21,-258 }, { 22,-258 }, { 23,-258 }, { 24,-258 }, { 25,-258 }, + + { 26,-258 }, { 27,-258 }, { 28,-258 }, { 29,-258 }, { 30,-258 }, + { 31,-258 }, { 32,-258 }, { 33, 0 }, { 34,-258 }, { 35, 0 }, + { 36,-258 }, { 37, 0 }, { 38, 0 }, { 39,-258 }, { 40,-258 }, + { 41,-258 }, { 42, 0 }, { 43, 0 }, { 44,-258 }, { 45, 0 }, + { 46,-258 }, { 47, 0 }, { 48,-258 }, { 49,-258 }, { 50,-258 }, + { 51,-258 }, { 52,-258 }, { 53,-258 }, { 54,-258 }, { 55,-258 }, + { 56,-258 }, { 57,-258 }, { 58,-258 }, { 59,-258 }, { 60, 0 }, + { 61, 0 }, { 62, 0 }, { 63, 0 }, { 64, 0 }, { 65,-258 }, + { 66,-258 }, { 67,-258 }, { 68,-258 }, { 69,-258 }, { 70,-258 }, + { 71,-258 }, { 72,-258 }, { 73,-258 }, { 74,-258 }, { 75,-258 }, + + { 76,-258 }, { 77,-258 }, { 78,-258 }, { 79,-258 }, { 80,-258 }, + { 81,-258 }, { 82,-258 }, { 83,-258 }, { 84,-258 }, { 85,-258 }, + { 86,-258 }, { 87,-258 }, { 88,-258 }, { 89,-258 }, { 90,-258 }, + { 91,-258 }, { 92,-258 }, { 93,-258 }, { 94, 0 }, { 95,-258 }, + { 96, 0 }, { 97,-258 }, { 98,-258 }, { 99,-258 }, { 100,-258 }, + { 101,-258 }, { 102,-258 }, { 103,-258 }, { 104,-258 }, { 105,-258 }, + { 106,-258 }, { 107,-258 }, { 108,-258 }, { 109,-258 }, { 110,-258 }, + { 111,-258 }, { 112,-258 }, { 113,-258 }, { 114,-258 }, { 115,-258 }, + { 116,-258 }, { 117,-258 }, { 118,-258 }, { 119,-258 }, { 120,-258 }, + { 121,-258 }, { 122,-258 }, { 123,-258 }, { 124, 0 }, { 125,-258 }, + + { 126, 0 }, { 127,-258 }, { 128,-258 }, { 129,-258 }, { 130,-258 }, + { 131,-258 }, { 132,-258 }, { 133,-258 }, { 134,-258 }, { 135,-258 }, + { 136,-258 }, { 137,-258 }, { 138,-258 }, { 139,-258 }, { 140,-258 }, + { 141,-258 }, { 142,-258 }, { 143,-258 }, { 144,-258 }, { 145,-258 }, + { 146,-258 }, { 147,-258 }, { 148,-258 }, { 149,-258 }, { 150,-258 }, + { 151,-258 }, { 152,-258 }, { 153,-258 }, { 154,-258 }, { 155,-258 }, + { 156,-258 }, { 157,-258 }, { 158,-258 }, { 159,-258 }, { 160,-258 }, + { 161,-258 }, { 162,-258 }, { 163,-258 }, { 164,-258 }, { 165,-258 }, + { 166,-258 }, { 167,-258 }, { 168,-258 }, { 169,-258 }, { 170,-258 }, + { 171,-258 }, { 172,-258 }, { 173,-258 }, { 174,-258 }, { 175,-258 }, + + { 176,-258 }, { 177,-258 }, { 178,-258 }, { 179,-258 }, { 180,-258 }, + { 181,-258 }, { 182,-258 }, { 183,-258 }, { 184,-258 }, { 185,-258 }, + { 186,-258 }, { 187,-258 }, { 188,-258 }, { 189,-258 }, { 190,-258 }, + { 191,-258 }, { 192,-258 }, { 193,-258 }, { 194,-258 }, { 195,-258 }, + { 196,-258 }, { 197,-258 }, { 198,-258 }, { 199,-258 }, { 200,-258 }, + { 201,-258 }, { 202,-258 }, { 203,-258 }, { 204,-258 }, { 205,-258 }, + { 206,-258 }, { 207,-258 }, { 208,-258 }, { 209,-258 }, { 210,-258 }, + { 211,-258 }, { 212,-258 }, { 213,-258 }, { 214,-258 }, { 215,-258 }, + { 216,-258 }, { 217,-258 }, { 218,-258 }, { 219,-258 }, { 220,-258 }, + { 221,-258 }, { 222,-258 }, { 223,-258 }, { 224,-258 }, { 225,-258 }, + + { 226,-258 }, { 227,-258 }, { 228,-258 }, { 229,-258 }, { 230,-258 }, + { 231,-258 }, { 232,-258 }, { 233,-258 }, { 234,-258 }, { 235,-258 }, + { 236,-258 }, { 237,-258 }, { 238,-258 }, { 239,-258 }, { 240,-258 }, + { 241,-258 }, { 242,-258 }, { 243,-258 }, { 244,-258 }, { 245,-258 }, + { 246,-258 }, { 247,-258 }, { 248,-258 }, { 249,-258 }, { 250,-258 }, + { 251,-258 }, { 252,-258 }, { 253,-258 }, { 254,-258 }, { 255,-258 }, + { 256,-258 }, { 0, 2 }, { 0,48898 }, { 0, 60 }, { 0,48896 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 64 }, { 0,48874 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 33, 0 }, { 0, 0 }, { 35, 0 }, { 0, 0 }, { 37, 0 }, + { 38, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 42, 0 }, + { 43, 0 }, { 0, 0 }, { 45, 0 }, { 0, 0 }, { 47, 0 }, + { 0, 0 }, { 0, 0 }, { 48, 0 }, { 49, 0 }, { 50, 0 }, + { 51, 0 }, { 52, 0 }, { 53, 0 }, { 54, 0 }, { 55, 0 }, + { 56, 0 }, { 57, 0 }, { 60, 0 }, { 61, 0 }, { 62, 0 }, + { 63, 0 }, { 64, 0 }, { 0, 62 }, { 0,48832 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 69,-3688 }, { 48, 42 }, + { 49, 42 }, { 50, 42 }, { 51, 42 }, { 52, 42 }, { 53, 42 }, + { 54, 42 }, { 55, 42 }, { 56, 42 }, { 57, 42 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 94, 0 }, { 0, 0 }, { 96, 0 }, { 0, 9 }, + { 0,48800 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 101,-3688 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 9, 0 }, + { 10, 0 }, { 0, 0 }, { 12, 0 }, { 13, 0 }, { 0, 0 }, + { 0, 0 }, { 48, 0 }, { 49, 0 }, { 50, 0 }, { 51, 0 }, + + { 52, 0 }, { 53, 0 }, { 54, 0 }, { 55, 0 }, { 56, 0 }, + { 57, 0 }, { 124, 0 }, { 0, 0 }, { 126, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 32, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 39,-8792 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 45,-8775 }, { 0, 9 }, { 0,48753 }, { 1,2367 }, { 2,2367 }, + { 3,2367 }, { 4,2367 }, { 5,2367 }, { 6,2367 }, { 7,2367 }, + { 8,2367 }, { 9,2625 }, { 10,-3271 }, { 11,2367 }, { 12,2625 }, + { 13,-3271 }, { 14,2367 }, { 15,2367 }, { 16,2367 }, { 17,2367 }, + { 18,2367 }, { 19,2367 }, { 20,2367 }, { 21,2367 }, { 22,2367 }, + + { 23,2367 }, { 24,2367 }, { 25,2367 }, { 26,2367 }, { 27,2367 }, + { 28,2367 }, { 29,2367 }, { 30,2367 }, { 31,2367 }, { 32,2625 }, + { 33,2367 }, { 34,2367 }, { 35,2367 }, { 36,2367 }, { 37,2367 }, + { 38,2367 }, { 39,2367 }, { 40,2367 }, { 41,2367 }, { 42,2367 }, + { 43,2367 }, { 44,2367 }, { 45,2883 }, { 46,2367 }, { 47,2367 }, + { 48,2367 }, { 49,2367 }, { 50,2367 }, { 51,2367 }, { 52,2367 }, + { 53,2367 }, { 54,2367 }, { 55,2367 }, { 56,2367 }, { 57,2367 }, + { 58,2367 }, { 59,2367 }, { 60,2367 }, { 61,2367 }, { 62,2367 }, + { 63,2367 }, { 64,2367 }, { 65,2367 }, { 66,2367 }, { 67,2367 }, + { 68,2367 }, { 69,2367 }, { 70,2367 }, { 71,2367 }, { 72,2367 }, + + { 73,2367 }, { 74,2367 }, { 75,2367 }, { 76,2367 }, { 77,2367 }, + { 78,2367 }, { 79,2367 }, { 80,2367 }, { 81,2367 }, { 82,2367 }, + { 83,2367 }, { 84,2367 }, { 85,2367 }, { 86,2367 }, { 87,2367 }, + { 88,2367 }, { 89,2367 }, { 90,2367 }, { 91,2367 }, { 92,2367 }, + { 93,2367 }, { 94,2367 }, { 95,2367 }, { 96,2367 }, { 97,2367 }, + { 98,2367 }, { 99,2367 }, { 100,2367 }, { 101,2367 }, { 102,2367 }, + { 103,2367 }, { 104,2367 }, { 105,2367 }, { 106,2367 }, { 107,2367 }, + { 108,2367 }, { 109,2367 }, { 110,2367 }, { 111,2367 }, { 112,2367 }, + { 113,2367 }, { 114,2367 }, { 115,2367 }, { 116,2367 }, { 117,2367 }, + { 118,2367 }, { 119,2367 }, { 120,2367 }, { 121,2367 }, { 122,2367 }, + + { 123,2367 }, { 124,2367 }, { 125,2367 }, { 126,2367 }, { 127,2367 }, + { 128,2367 }, { 129,2367 }, { 130,2367 }, { 131,2367 }, { 132,2367 }, + { 133,2367 }, { 134,2367 }, { 135,2367 }, { 136,2367 }, { 137,2367 }, + { 138,2367 }, { 139,2367 }, { 140,2367 }, { 141,2367 }, { 142,2367 }, + { 143,2367 }, { 144,2367 }, { 145,2367 }, { 146,2367 }, { 147,2367 }, + { 148,2367 }, { 149,2367 }, { 150,2367 }, { 151,2367 }, { 152,2367 }, + { 153,2367 }, { 154,2367 }, { 155,2367 }, { 156,2367 }, { 157,2367 }, + { 158,2367 }, { 159,2367 }, { 160,2367 }, { 161,2367 }, { 162,2367 }, + { 163,2367 }, { 164,2367 }, { 165,2367 }, { 166,2367 }, { 167,2367 }, + { 168,2367 }, { 169,2367 }, { 170,2367 }, { 171,2367 }, { 172,2367 }, + + { 173,2367 }, { 174,2367 }, { 175,2367 }, { 176,2367 }, { 177,2367 }, + { 178,2367 }, { 179,2367 }, { 180,2367 }, { 181,2367 }, { 182,2367 }, + { 183,2367 }, { 184,2367 }, { 185,2367 }, { 186,2367 }, { 187,2367 }, + { 188,2367 }, { 189,2367 }, { 190,2367 }, { 191,2367 }, { 192,2367 }, + { 193,2367 }, { 194,2367 }, { 195,2367 }, { 196,2367 }, { 197,2367 }, + { 198,2367 }, { 199,2367 }, { 200,2367 }, { 201,2367 }, { 202,2367 }, + { 203,2367 }, { 204,2367 }, { 205,2367 }, { 206,2367 }, { 207,2367 }, + { 208,2367 }, { 209,2367 }, { 210,2367 }, { 211,2367 }, { 212,2367 }, + { 213,2367 }, { 214,2367 }, { 215,2367 }, { 216,2367 }, { 217,2367 }, + { 218,2367 }, { 219,2367 }, { 220,2367 }, { 221,2367 }, { 222,2367 }, + + { 223,2367 }, { 224,2367 }, { 225,2367 }, { 226,2367 }, { 227,2367 }, + { 228,2367 }, { 229,2367 }, { 230,2367 }, { 231,2367 }, { 232,2367 }, + { 233,2367 }, { 234,2367 }, { 235,2367 }, { 236,2367 }, { 237,2367 }, + { 238,2367 }, { 239,2367 }, { 240,2367 }, { 241,2367 }, { 242,2367 }, + { 243,2367 }, { 244,2367 }, { 245,2367 }, { 246,2367 }, { 247,2367 }, + { 248,2367 }, { 249,2367 }, { 250,2367 }, { 251,2367 }, { 252,2367 }, + { 253,2367 }, { 254,2367 }, { 255,2367 }, { 256,2367 }, { 0, 3 }, + { 0,48495 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 16 }, { 0,48488 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 9, 0 }, { 10, 0 }, { 0, 0 }, { 12, 0 }, + { 13, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 33, 0 }, { 0, 0 }, + { 35, 0 }, { 0, 0 }, { 37, 0 }, { 38, 0 }, { 32, 0 }, + { 0, 0 }, { 0, 0 }, { 42, 0 }, { 43, 0 }, { 0, 0 }, + { 45, 0 }, { 39,-9075 }, { 47, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 45,-8875 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 60, 0 }, { 61, 0 }, { 62, 0 }, { 63, 0 }, { 64, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 94, 0 }, + { 0, 0 }, { 96, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 124, 0 }, + { 0, 0 }, { 126, 0 }, { 0, 16 }, { 0,48367 }, { 1,3013 }, + { 2,3013 }, { 3,3013 }, { 4,3013 }, { 5,3013 }, { 6,3013 }, + { 7,3013 }, { 8,3013 }, { 9,3271 }, { 10,-2703 }, { 11,3013 }, + { 12,3271 }, { 13,-2703 }, { 14,3013 }, { 15,3013 }, { 16,3013 }, + { 17,3013 }, { 18,3013 }, { 19,3013 }, { 20,3013 }, { 21,3013 }, + { 22,3013 }, { 23,3013 }, { 24,3013 }, { 25,3013 }, { 26,3013 }, + { 27,3013 }, { 28,3013 }, { 29,3013 }, { 30,3013 }, { 31,3013 }, + { 32,3271 }, { 33,3013 }, { 34,3013 }, { 35,3013 }, { 36,3013 }, + + { 37,3013 }, { 38,3013 }, { 39,3013 }, { 40,3013 }, { 41,3013 }, + { 42,3013 }, { 43,3013 }, { 44,3013 }, { 45,3529 }, { 46,3013 }, + { 47,3013 }, { 48,3013 }, { 49,3013 }, { 50,3013 }, { 51,3013 }, + { 52,3013 }, { 53,3013 }, { 54,3013 }, { 55,3013 }, { 56,3013 }, + { 57,3013 }, { 58,3013 }, { 59,3013 }, { 60,3013 }, { 61,3013 }, + { 62,3013 }, { 63,3013 }, { 64,3013 }, { 65,3013 }, { 66,3013 }, + { 67,3013 }, { 68,3013 }, { 69,3013 }, { 70,3013 }, { 71,3013 }, + { 72,3013 }, { 73,3013 }, { 74,3013 }, { 75,3013 }, { 76,3013 }, + { 77,3013 }, { 78,3013 }, { 79,3013 }, { 80,3013 }, { 81,3013 }, + { 82,3013 }, { 83,3013 }, { 84,3013 }, { 85,3013 }, { 86,3013 }, + + { 87,3013 }, { 88,3013 }, { 89,3013 }, { 90,3013 }, { 91,3013 }, + { 92,3013 }, { 93,3013 }, { 94,3013 }, { 95,3013 }, { 96,3013 }, + { 97,3013 }, { 98,3013 }, { 99,3013 }, { 100,3013 }, { 101,3013 }, + { 102,3013 }, { 103,3013 }, { 104,3013 }, { 105,3013 }, { 106,3013 }, + { 107,3013 }, { 108,3013 }, { 109,3013 }, { 110,3013 }, { 111,3013 }, + { 112,3013 }, { 113,3013 }, { 114,3013 }, { 115,3013 }, { 116,3013 }, + { 117,3013 }, { 118,3013 }, { 119,3013 }, { 120,3013 }, { 121,3013 }, + { 122,3013 }, { 123,3013 }, { 124,3013 }, { 125,3013 }, { 126,3013 }, + { 127,3013 }, { 128,3013 }, { 129,3013 }, { 130,3013 }, { 131,3013 }, + { 132,3013 }, { 133,3013 }, { 134,3013 }, { 135,3013 }, { 136,3013 }, + + { 137,3013 }, { 138,3013 }, { 139,3013 }, { 140,3013 }, { 141,3013 }, + { 142,3013 }, { 143,3013 }, { 144,3013 }, { 145,3013 }, { 146,3013 }, + { 147,3013 }, { 148,3013 }, { 149,3013 }, { 150,3013 }, { 151,3013 }, + { 152,3013 }, { 153,3013 }, { 154,3013 }, { 155,3013 }, { 156,3013 }, + { 157,3013 }, { 158,3013 }, { 159,3013 }, { 160,3013 }, { 161,3013 }, + { 162,3013 }, { 163,3013 }, { 164,3013 }, { 165,3013 }, { 166,3013 }, + { 167,3013 }, { 168,3013 }, { 169,3013 }, { 170,3013 }, { 171,3013 }, + { 172,3013 }, { 173,3013 }, { 174,3013 }, { 175,3013 }, { 176,3013 }, + { 177,3013 }, { 178,3013 }, { 179,3013 }, { 180,3013 }, { 181,3013 }, + { 182,3013 }, { 183,3013 }, { 184,3013 }, { 185,3013 }, { 186,3013 }, + + { 187,3013 }, { 188,3013 }, { 189,3013 }, { 190,3013 }, { 191,3013 }, + { 192,3013 }, { 193,3013 }, { 194,3013 }, { 195,3013 }, { 196,3013 }, + { 197,3013 }, { 198,3013 }, { 199,3013 }, { 200,3013 }, { 201,3013 }, + { 202,3013 }, { 203,3013 }, { 204,3013 }, { 205,3013 }, { 206,3013 }, + { 207,3013 }, { 208,3013 }, { 209,3013 }, { 210,3013 }, { 211,3013 }, + { 212,3013 }, { 213,3013 }, { 214,3013 }, { 215,3013 }, { 216,3013 }, + { 217,3013 }, { 218,3013 }, { 219,3013 }, { 220,3013 }, { 221,3013 }, + { 222,3013 }, { 223,3013 }, { 224,3013 }, { 225,3013 }, { 226,3013 }, + { 227,3013 }, { 228,3013 }, { 229,3013 }, { 230,3013 }, { 231,3013 }, + { 232,3013 }, { 233,3013 }, { 234,3013 }, { 235,3013 }, { 236,3013 }, + + { 237,3013 }, { 238,3013 }, { 239,3013 }, { 240,3013 }, { 241,3013 }, + { 242,3013 }, { 243,3013 }, { 244,3013 }, { 245,3013 }, { 246,3013 }, + { 247,3013 }, { 248,3013 }, { 249,3013 }, { 250,3013 }, { 251,3013 }, + { 252,3013 }, { 253,3013 }, { 254,3013 }, { 255,3013 }, { 256,3013 }, + { 0, 22 }, { 0,48109 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 9, 0 }, { 10, 0 }, { 0, 0 }, { 12, 0 }, { 13, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 32, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 39,-9252 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 45,-9243 }, { 0, 22 }, { 0,48062 }, { 1,3740 }, + { 2,3740 }, { 3,3740 }, { 4,3740 }, { 5,3740 }, { 6,3740 }, + { 7,3740 }, { 8,3740 }, { 9,3998 }, { 10,-2698 }, { 11,3740 }, + { 12,3998 }, { 13,-2698 }, { 14,3740 }, { 15,3740 }, { 16,3740 }, + { 17,3740 }, { 18,3740 }, { 19,3740 }, { 20,3740 }, { 21,3740 }, + { 22,3740 }, { 23,3740 }, { 24,3740 }, { 25,3740 }, { 26,3740 }, + { 27,3740 }, { 28,3740 }, { 29,3740 }, { 30,3740 }, { 31,3740 }, + + { 32,3998 }, { 33,3740 }, { 34,3740 }, { 35,3740 }, { 36,3740 }, + { 37,3740 }, { 38,3740 }, { 39,3740 }, { 40,3740 }, { 41,3740 }, + { 42,3740 }, { 43,3740 }, { 44,3740 }, { 45,4256 }, { 46,3740 }, + { 47,3740 }, { 48,3740 }, { 49,3740 }, { 50,3740 }, { 51,3740 }, + { 52,3740 }, { 53,3740 }, { 54,3740 }, { 55,3740 }, { 56,3740 }, + { 57,3740 }, { 58,3740 }, { 59,3740 }, { 60,3740 }, { 61,3740 }, + { 62,3740 }, { 63,3740 }, { 64,3740 }, { 65,3740 }, { 66,3740 }, + { 67,3740 }, { 68,3740 }, { 69,3740 }, { 70,3740 }, { 71,3740 }, + { 72,3740 }, { 73,3740 }, { 74,3740 }, { 75,3740 }, { 76,3740 }, + { 77,3740 }, { 78,3740 }, { 79,3740 }, { 80,3740 }, { 81,3740 }, + + { 82,3740 }, { 83,3740 }, { 84,3740 }, { 85,3740 }, { 86,3740 }, + { 87,3740 }, { 88,3740 }, { 89,3740 }, { 90,3740 }, { 91,3740 }, + { 92,3740 }, { 93,3740 }, { 94,3740 }, { 95,3740 }, { 96,3740 }, + { 97,3740 }, { 98,3740 }, { 99,3740 }, { 100,3740 }, { 101,3740 }, + { 102,3740 }, { 103,3740 }, { 104,3740 }, { 105,3740 }, { 106,3740 }, + { 107,3740 }, { 108,3740 }, { 109,3740 }, { 110,3740 }, { 111,3740 }, + { 112,3740 }, { 113,3740 }, { 114,3740 }, { 115,3740 }, { 116,3740 }, + { 117,3740 }, { 118,3740 }, { 119,3740 }, { 120,3740 }, { 121,3740 }, + { 122,3740 }, { 123,3740 }, { 124,3740 }, { 125,3740 }, { 126,3740 }, + { 127,3740 }, { 128,3740 }, { 129,3740 }, { 130,3740 }, { 131,3740 }, + + { 132,3740 }, { 133,3740 }, { 134,3740 }, { 135,3740 }, { 136,3740 }, + { 137,3740 }, { 138,3740 }, { 139,3740 }, { 140,3740 }, { 141,3740 }, + { 142,3740 }, { 143,3740 }, { 144,3740 }, { 145,3740 }, { 146,3740 }, + { 147,3740 }, { 148,3740 }, { 149,3740 }, { 150,3740 }, { 151,3740 }, + { 152,3740 }, { 153,3740 }, { 154,3740 }, { 155,3740 }, { 156,3740 }, + { 157,3740 }, { 158,3740 }, { 159,3740 }, { 160,3740 }, { 161,3740 }, + { 162,3740 }, { 163,3740 }, { 164,3740 }, { 165,3740 }, { 166,3740 }, + { 167,3740 }, { 168,3740 }, { 169,3740 }, { 170,3740 }, { 171,3740 }, + { 172,3740 }, { 173,3740 }, { 174,3740 }, { 175,3740 }, { 176,3740 }, + { 177,3740 }, { 178,3740 }, { 179,3740 }, { 180,3740 }, { 181,3740 }, + + { 182,3740 }, { 183,3740 }, { 184,3740 }, { 185,3740 }, { 186,3740 }, + { 187,3740 }, { 188,3740 }, { 189,3740 }, { 190,3740 }, { 191,3740 }, + { 192,3740 }, { 193,3740 }, { 194,3740 }, { 195,3740 }, { 196,3740 }, + { 197,3740 }, { 198,3740 }, { 199,3740 }, { 200,3740 }, { 201,3740 }, + { 202,3740 }, { 203,3740 }, { 204,3740 }, { 205,3740 }, { 206,3740 }, + { 207,3740 }, { 208,3740 }, { 209,3740 }, { 210,3740 }, { 211,3740 }, + { 212,3740 }, { 213,3740 }, { 214,3740 }, { 215,3740 }, { 216,3740 }, + { 217,3740 }, { 218,3740 }, { 219,3740 }, { 220,3740 }, { 221,3740 }, + { 222,3740 }, { 223,3740 }, { 224,3740 }, { 225,3740 }, { 226,3740 }, + { 227,3740 }, { 228,3740 }, { 229,3740 }, { 230,3740 }, { 231,3740 }, + + { 232,3740 }, { 233,3740 }, { 234,3740 }, { 235,3740 }, { 236,3740 }, + { 237,3740 }, { 238,3740 }, { 239,3740 }, { 240,3740 }, { 241,3740 }, + { 242,3740 }, { 243,3740 }, { 244,3740 }, { 245,3740 }, { 246,3740 }, + { 247,3740 }, { 248,3740 }, { 249,3740 }, { 250,3740 }, { 251,3740 }, + { 252,3740 }, { 253,3740 }, { 254,3740 }, { 255,3740 }, { 256,3740 }, + { 0, 35 }, { 0,47804 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 33 }, { 0,47796 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 33 }, { 0,47773 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 48,-9037 }, + { 49,-9037 }, { 50,-9037 }, { 51,-9037 }, { 52,-9037 }, { 53,-9037 }, + { 54,-9037 }, { 55,-9037 }, { 48,4248 }, { 49,4248 }, { 50,4248 }, + { 51,4248 }, { 52,4248 }, { 53,4248 }, { 54,4248 }, { 55,4248 }, + { 56,4248 }, { 57,4248 }, { 0, 0 }, { 0, 0 }, { 0, 36 }, + { 0,47735 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 65,4248 }, + + { 66,4248 }, { 67,4248 }, { 68,4248 }, { 69,4248 }, { 70,4248 }, + { 48,4248 }, { 49,4248 }, { 50,4248 }, { 51,4248 }, { 52,4248 }, + { 53,4248 }, { 54,4248 }, { 55,4248 }, { 56,4248 }, { 57,4248 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 65,4248 }, { 66,4248 }, { 67,4248 }, + { 68,4248 }, { 69,4248 }, { 70,4248 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 97,4248 }, { 98,4248 }, { 99,4248 }, { 100,4248 }, + { 101,4248 }, { 102,4248 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 48,-9104 }, { 49,-9104 }, + { 50,-9104 }, { 51,-9104 }, { 52,-9104 }, { 53,-9104 }, { 54,-9104 }, + + { 55,-9104 }, { 56,-9104 }, { 57,-9104 }, { 0, 0 }, { 97,4248 }, + { 98,4248 }, { 99,4248 }, { 100,4248 }, { 101,4248 }, { 102,4248 }, + { 65,-9104 }, { 66,-9104 }, { 67,-9104 }, { 68,-9104 }, { 69,-9104 }, + { 70,-9104 }, { 0, 43 }, { 0,47663 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 97,-9104 }, { 98,-9104 }, { 99,-9104 }, + { 100,-9104 }, { 101,-9104 }, { 102,-9104 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 36,-10455 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 48, 0 }, { 49, 0 }, { 50, 0 }, { 51, 0 }, { 52, 0 }, + { 53, 0 }, { 54, 0 }, { 55, 0 }, { 56, 0 }, { 57, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 65, 0 }, { 66, 0 }, { 67, 0 }, + { 68, 0 }, { 69, 0 }, { 70, 0 }, { 71, 0 }, { 72, 0 }, + { 73, 0 }, { 74, 0 }, { 75, 0 }, { 76, 0 }, { 77, 0 }, + { 78, 0 }, { 79, 0 }, { 80, 0 }, { 81, 0 }, { 82, 0 }, + + { 83, 0 }, { 84, 0 }, { 85, 0 }, { 86, 0 }, { 87, 0 }, + { 88, 0 }, { 89, 0 }, { 90, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 95, 0 }, { 0, 0 }, { 97, 0 }, + { 98, 0 }, { 99, 0 }, { 100, 0 }, { 101, 0 }, { 102, 0 }, + { 103, 0 }, { 104, 0 }, { 105, 0 }, { 106, 0 }, { 107, 0 }, + { 108, 0 }, { 109, 0 }, { 110, 0 }, { 111, 0 }, { 112, 0 }, + { 113, 0 }, { 114, 0 }, { 115, 0 }, { 116, 0 }, { 117, 0 }, + { 118, 0 }, { 119, 0 }, { 120, 0 }, { 121, 0 }, { 122, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 128, 0 }, { 129, 0 }, { 130, 0 }, { 131, 0 }, { 132, 0 }, + + { 133, 0 }, { 134, 0 }, { 135, 0 }, { 136, 0 }, { 137, 0 }, + { 138, 0 }, { 139, 0 }, { 140, 0 }, { 141, 0 }, { 142, 0 }, + { 143, 0 }, { 144, 0 }, { 145, 0 }, { 146, 0 }, { 147, 0 }, + { 148, 0 }, { 149, 0 }, { 150, 0 }, { 151, 0 }, { 152, 0 }, + { 153, 0 }, { 154, 0 }, { 155, 0 }, { 156, 0 }, { 157, 0 }, + { 158, 0 }, { 159, 0 }, { 160, 0 }, { 161, 0 }, { 162, 0 }, + { 163, 0 }, { 164, 0 }, { 165, 0 }, { 166, 0 }, { 167, 0 }, + { 168, 0 }, { 169, 0 }, { 170, 0 }, { 171, 0 }, { 172, 0 }, + { 173, 0 }, { 174, 0 }, { 175, 0 }, { 176, 0 }, { 177, 0 }, + { 178, 0 }, { 179, 0 }, { 180, 0 }, { 181, 0 }, { 182, 0 }, + + { 183, 0 }, { 184, 0 }, { 185, 0 }, { 186, 0 }, { 187, 0 }, + { 188, 0 }, { 189, 0 }, { 190, 0 }, { 191, 0 }, { 192, 0 }, + { 193, 0 }, { 194, 0 }, { 195, 0 }, { 196, 0 }, { 197, 0 }, + { 198, 0 }, { 199, 0 }, { 200, 0 }, { 201, 0 }, { 202, 0 }, + { 203, 0 }, { 204, 0 }, { 205, 0 }, { 206, 0 }, { 207, 0 }, + { 208, 0 }, { 209, 0 }, { 210, 0 }, { 211, 0 }, { 212, 0 }, + { 213, 0 }, { 214, 0 }, { 215, 0 }, { 216, 0 }, { 217, 0 }, + { 218, 0 }, { 219, 0 }, { 220, 0 }, { 221, 0 }, { 222, 0 }, + { 223, 0 }, { 224, 0 }, { 225, 0 }, { 226, 0 }, { 227, 0 }, + { 228, 0 }, { 229, 0 }, { 230, 0 }, { 231, 0 }, { 232, 0 }, + + { 233, 0 }, { 234, 0 }, { 235, 0 }, { 236, 0 }, { 237, 0 }, + { 238, 0 }, { 239, 0 }, { 240, 0 }, { 241, 0 }, { 242, 0 }, + { 243, 0 }, { 244, 0 }, { 245, 0 }, { 246, 0 }, { 247, 0 }, + { 248, 0 }, { 249, 0 }, { 250, 0 }, { 251, 0 }, { 252, 0 }, + { 253, 0 }, { 254, 0 }, { 255, 0 }, { 0, 48 }, { 0,47406 }, + { 1,3985 }, { 2,3985 }, { 3,3985 }, { 4,3985 }, { 5,3985 }, + { 6,3985 }, { 7,3985 }, { 8,3985 }, { 9,4243 }, { 10,-2401 }, + { 11,3985 }, { 12,4243 }, { 13,-2401 }, { 14,3985 }, { 15,3985 }, + { 16,3985 }, { 17,3985 }, { 18,3985 }, { 19,3985 }, { 20,3985 }, + { 21,3985 }, { 22,3985 }, { 23,3985 }, { 24,3985 }, { 25,3985 }, + + { 26,3985 }, { 27,3985 }, { 28,3985 }, { 29,3985 }, { 30,3985 }, + { 31,3985 }, { 32,4243 }, { 33,3985 }, { 34,3985 }, { 35,3985 }, + { 36,3985 }, { 37,3985 }, { 38,3985 }, { 39,3985 }, { 40,3985 }, + { 41,3985 }, { 42,3985 }, { 43,3985 }, { 44,3985 }, { 45,4501 }, + { 46,3985 }, { 47,3985 }, { 48,3985 }, { 49,3985 }, { 50,3985 }, + { 51,3985 }, { 52,3985 }, { 53,3985 }, { 54,3985 }, { 55,3985 }, + { 56,3985 }, { 57,3985 }, { 58,3985 }, { 59,3985 }, { 60,3985 }, + { 61,3985 }, { 62,3985 }, { 63,3985 }, { 64,3985 }, { 65,3985 }, + { 66,3985 }, { 67,3985 }, { 68,3985 }, { 69,3985 }, { 70,3985 }, + { 71,3985 }, { 72,3985 }, { 73,3985 }, { 74,3985 }, { 75,3985 }, + + { 76,3985 }, { 77,3985 }, { 78,3985 }, { 79,3985 }, { 80,3985 }, + { 81,3985 }, { 82,3985 }, { 83,3985 }, { 84,3985 }, { 85,4759 }, + { 86,3985 }, { 87,3985 }, { 88,3985 }, { 89,3985 }, { 90,3985 }, + { 91,3985 }, { 92,3985 }, { 93,3985 }, { 94,3985 }, { 95,3985 }, + { 96,3985 }, { 97,3985 }, { 98,3985 }, { 99,3985 }, { 100,3985 }, + { 101,3985 }, { 102,3985 }, { 103,3985 }, { 104,3985 }, { 105,3985 }, + { 106,3985 }, { 107,3985 }, { 108,3985 }, { 109,3985 }, { 110,3985 }, + { 111,3985 }, { 112,3985 }, { 113,3985 }, { 114,3985 }, { 115,3985 }, + { 116,3985 }, { 117,4759 }, { 118,3985 }, { 119,3985 }, { 120,3985 }, + { 121,3985 }, { 122,3985 }, { 123,3985 }, { 124,3985 }, { 125,3985 }, + + { 126,3985 }, { 127,3985 }, { 128,3985 }, { 129,3985 }, { 130,3985 }, + { 131,3985 }, { 132,3985 }, { 133,3985 }, { 134,3985 }, { 135,3985 }, + { 136,3985 }, { 137,3985 }, { 138,3985 }, { 139,3985 }, { 140,3985 }, + { 141,3985 }, { 142,3985 }, { 143,3985 }, { 144,3985 }, { 145,3985 }, + { 146,3985 }, { 147,3985 }, { 148,3985 }, { 149,3985 }, { 150,3985 }, + { 151,3985 }, { 152,3985 }, { 153,3985 }, { 154,3985 }, { 155,3985 }, + { 156,3985 }, { 157,3985 }, { 158,3985 }, { 159,3985 }, { 160,3985 }, + { 161,3985 }, { 162,3985 }, { 163,3985 }, { 164,3985 }, { 165,3985 }, + { 166,3985 }, { 167,3985 }, { 168,3985 }, { 169,3985 }, { 170,3985 }, + { 171,3985 }, { 172,3985 }, { 173,3985 }, { 174,3985 }, { 175,3985 }, + + { 176,3985 }, { 177,3985 }, { 178,3985 }, { 179,3985 }, { 180,3985 }, + { 181,3985 }, { 182,3985 }, { 183,3985 }, { 184,3985 }, { 185,3985 }, + { 186,3985 }, { 187,3985 }, { 188,3985 }, { 189,3985 }, { 190,3985 }, + { 191,3985 }, { 192,3985 }, { 193,3985 }, { 194,3985 }, { 195,3985 }, + { 196,3985 }, { 197,3985 }, { 198,3985 }, { 199,3985 }, { 200,3985 }, + { 201,3985 }, { 202,3985 }, { 203,3985 }, { 204,3985 }, { 205,3985 }, + { 206,3985 }, { 207,3985 }, { 208,3985 }, { 209,3985 }, { 210,3985 }, + { 211,3985 }, { 212,3985 }, { 213,3985 }, { 214,3985 }, { 215,3985 }, + { 216,3985 }, { 217,3985 }, { 218,3985 }, { 219,3985 }, { 220,3985 }, + { 221,3985 }, { 222,3985 }, { 223,3985 }, { 224,3985 }, { 225,3985 }, + + { 226,3985 }, { 227,3985 }, { 228,3985 }, { 229,3985 }, { 230,3985 }, + { 231,3985 }, { 232,3985 }, { 233,3985 }, { 234,3985 }, { 235,3985 }, + { 236,3985 }, { 237,3985 }, { 238,3985 }, { 239,3985 }, { 240,3985 }, + { 241,3985 }, { 242,3985 }, { 243,3985 }, { 244,3985 }, { 245,3985 }, + { 246,3985 }, { 247,3985 }, { 248,3985 }, { 249,3985 }, { 250,3985 }, + { 251,3985 }, { 252,3985 }, { 253,3985 }, { 254,3985 }, { 255,3985 }, + { 256,3985 }, { 0, 24 }, { 0,47148 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 9, 0 }, { 10, 0 }, { 0, 0 }, { 12, 0 }, + { 13, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 32, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 39,-10213 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 45,-9947 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 85,-10452 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 117,-10452 }, + + { 0, 24 }, { 0,47029 }, { 1,4898 }, { 2,4898 }, { 3,4898 }, + { 4,4898 }, { 5,4898 }, { 6,4898 }, { 7,4898 }, { 8,4898 }, + { 9,5156 }, { 10,-2757 }, { 11,4898 }, { 12,5156 }, { 13,-2757 }, + { 14,4898 }, { 15,4898 }, { 16,4898 }, { 17,4898 }, { 18,4898 }, + { 19,4898 }, { 20,4898 }, { 21,4898 }, { 22,4898 }, { 23,4898 }, + { 24,4898 }, { 25,4898 }, { 26,4898 }, { 27,4898 }, { 28,4898 }, + { 29,4898 }, { 30,4898 }, { 31,4898 }, { 32,5156 }, { 33,4898 }, + { 34,4898 }, { 35,4898 }, { 36,4898 }, { 37,4898 }, { 38,4898 }, + { 39,4898 }, { 40,4898 }, { 41,4898 }, { 42,4898 }, { 43,4898 }, + { 44,4898 }, { 45,5414 }, { 46,4898 }, { 47,4898 }, { 48,4898 }, + + { 49,4898 }, { 50,4898 }, { 51,4898 }, { 52,4898 }, { 53,4898 }, + { 54,4898 }, { 55,4898 }, { 56,4898 }, { 57,4898 }, { 58,4898 }, + { 59,4898 }, { 60,4898 }, { 61,4898 }, { 62,4898 }, { 63,4898 }, + { 64,4898 }, { 65,4898 }, { 66,4898 }, { 67,4898 }, { 68,4898 }, + { 69,4898 }, { 70,4898 }, { 71,4898 }, { 72,4898 }, { 73,4898 }, + { 74,4898 }, { 75,4898 }, { 76,4898 }, { 77,4898 }, { 78,4898 }, + { 79,4898 }, { 80,4898 }, { 81,4898 }, { 82,4898 }, { 83,4898 }, + { 84,4898 }, { 85,5672 }, { 86,4898 }, { 87,4898 }, { 88,4898 }, + { 89,4898 }, { 90,4898 }, { 91,4898 }, { 92,4898 }, { 93,4898 }, + { 94,4898 }, { 95,4898 }, { 96,4898 }, { 97,4898 }, { 98,4898 }, + + { 99,4898 }, { 100,4898 }, { 101,4898 }, { 102,4898 }, { 103,4898 }, + { 104,4898 }, { 105,4898 }, { 106,4898 }, { 107,4898 }, { 108,4898 }, + { 109,4898 }, { 110,4898 }, { 111,4898 }, { 112,4898 }, { 113,4898 }, + { 114,4898 }, { 115,4898 }, { 116,4898 }, { 117,5672 }, { 118,4898 }, + { 119,4898 }, { 120,4898 }, { 121,4898 }, { 122,4898 }, { 123,4898 }, + { 124,4898 }, { 125,4898 }, { 126,4898 }, { 127,4898 }, { 128,4898 }, + { 129,4898 }, { 130,4898 }, { 131,4898 }, { 132,4898 }, { 133,4898 }, + { 134,4898 }, { 135,4898 }, { 136,4898 }, { 137,4898 }, { 138,4898 }, + { 139,4898 }, { 140,4898 }, { 141,4898 }, { 142,4898 }, { 143,4898 }, + { 144,4898 }, { 145,4898 }, { 146,4898 }, { 147,4898 }, { 148,4898 }, + + { 149,4898 }, { 150,4898 }, { 151,4898 }, { 152,4898 }, { 153,4898 }, + { 154,4898 }, { 155,4898 }, { 156,4898 }, { 157,4898 }, { 158,4898 }, + { 159,4898 }, { 160,4898 }, { 161,4898 }, { 162,4898 }, { 163,4898 }, + { 164,4898 }, { 165,4898 }, { 166,4898 }, { 167,4898 }, { 168,4898 }, + { 169,4898 }, { 170,4898 }, { 171,4898 }, { 172,4898 }, { 173,4898 }, + { 174,4898 }, { 175,4898 }, { 176,4898 }, { 177,4898 }, { 178,4898 }, + { 179,4898 }, { 180,4898 }, { 181,4898 }, { 182,4898 }, { 183,4898 }, + { 184,4898 }, { 185,4898 }, { 186,4898 }, { 187,4898 }, { 188,4898 }, + { 189,4898 }, { 190,4898 }, { 191,4898 }, { 192,4898 }, { 193,4898 }, + { 194,4898 }, { 195,4898 }, { 196,4898 }, { 197,4898 }, { 198,4898 }, + + { 199,4898 }, { 200,4898 }, { 201,4898 }, { 202,4898 }, { 203,4898 }, + { 204,4898 }, { 205,4898 }, { 206,4898 }, { 207,4898 }, { 208,4898 }, + { 209,4898 }, { 210,4898 }, { 211,4898 }, { 212,4898 }, { 213,4898 }, + { 214,4898 }, { 215,4898 }, { 216,4898 }, { 217,4898 }, { 218,4898 }, + { 219,4898 }, { 220,4898 }, { 221,4898 }, { 222,4898 }, { 223,4898 }, + { 224,4898 }, { 225,4898 }, { 226,4898 }, { 227,4898 }, { 228,4898 }, + { 229,4898 }, { 230,4898 }, { 231,4898 }, { 232,4898 }, { 233,4898 }, + { 234,4898 }, { 235,4898 }, { 236,4898 }, { 237,4898 }, { 238,4898 }, + { 239,4898 }, { 240,4898 }, { 241,4898 }, { 242,4898 }, { 243,4898 }, + { 244,4898 }, { 245,4898 }, { 246,4898 }, { 247,4898 }, { 248,4898 }, + + { 249,4898 }, { 250,4898 }, { 251,4898 }, { 252,4898 }, { 253,4898 }, + { 254,4898 }, { 255,4898 }, { 256,4898 }, { 0, 33 }, { 0,46771 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 33 }, { 0,46748 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 48,5672 }, { 49,5672 }, { 50,5672 }, + { 51,5672 }, { 52,5672 }, { 53,5672 }, { 54,5672 }, { 55,5672 }, + { 56,5672 }, { 57,5672 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 65,5672 }, + { 66,5672 }, { 67,5672 }, { 68,5672 }, { 69,5672 }, { 70,5672 }, + { 48,5672 }, { 49,5672 }, { 50,5672 }, { 51,5672 }, { 52,5672 }, + { 53,5672 }, { 54,5672 }, { 55,5672 }, { 56,5672 }, { 57,5672 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 65,5672 }, { 66,5672 }, { 67,5672 }, + + { 68,5672 }, { 69,5672 }, { 70,5672 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 97,5672 }, { 98,5672 }, { 99,5672 }, { 100,5672 }, + { 101,5672 }, { 102,5672 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 97,5672 }, + { 98,5672 }, { 99,5672 }, { 100,5672 }, { 101,5672 }, { 102,5672 }, + { 0, 9 }, { 0,46644 }, { 1,5672 }, { 2,5672 }, { 3,5672 }, + { 4,5672 }, { 5,5672 }, { 6,5672 }, { 7,5672 }, { 8,5672 }, + { 9,5930 }, { 10,6188 }, { 11,5672 }, { 12,5930 }, { 13,6188 }, + + { 14,5672 }, { 15,5672 }, { 16,5672 }, { 17,5672 }, { 18,5672 }, + { 19,5672 }, { 20,5672 }, { 21,5672 }, { 22,5672 }, { 23,5672 }, + { 24,5672 }, { 25,5672 }, { 26,5672 }, { 27,5672 }, { 28,5672 }, + { 29,5672 }, { 30,5672 }, { 31,5672 }, { 32,5930 }, { 33,5672 }, + { 34,5672 }, { 35,5672 }, { 36,5672 }, { 37,5672 }, { 38,5672 }, + { 39,5672 }, { 40,5672 }, { 41,5672 }, { 42,5672 }, { 43,5672 }, + { 44,5672 }, { 45,6235 }, { 46,5672 }, { 47,5672 }, { 48,5672 }, + { 49,5672 }, { 50,5672 }, { 51,5672 }, { 52,5672 }, { 53,5672 }, + { 54,5672 }, { 55,5672 }, { 56,5672 }, { 57,5672 }, { 58,5672 }, + { 59,5672 }, { 60,5672 }, { 61,5672 }, { 62,5672 }, { 63,5672 }, + + { 64,5672 }, { 65,5672 }, { 66,5672 }, { 67,5672 }, { 68,5672 }, + { 69,5672 }, { 70,5672 }, { 71,5672 }, { 72,5672 }, { 73,5672 }, + { 74,5672 }, { 75,5672 }, { 76,5672 }, { 77,5672 }, { 78,5672 }, + { 79,5672 }, { 80,5672 }, { 81,5672 }, { 82,5672 }, { 83,5672 }, + { 84,5672 }, { 85,5672 }, { 86,5672 }, { 87,5672 }, { 88,5672 }, + { 89,5672 }, { 90,5672 }, { 91,5672 }, { 92,5672 }, { 93,5672 }, + { 94,5672 }, { 95,5672 }, { 96,5672 }, { 97,5672 }, { 98,5672 }, + { 99,5672 }, { 100,5672 }, { 101,5672 }, { 102,5672 }, { 103,5672 }, + { 104,5672 }, { 105,5672 }, { 106,5672 }, { 107,5672 }, { 108,5672 }, + { 109,5672 }, { 110,5672 }, { 111,5672 }, { 112,5672 }, { 113,5672 }, + + { 114,5672 }, { 115,5672 }, { 116,5672 }, { 117,5672 }, { 118,5672 }, + { 119,5672 }, { 120,5672 }, { 121,5672 }, { 122,5672 }, { 123,5672 }, + { 124,5672 }, { 125,5672 }, { 126,5672 }, { 127,5672 }, { 128,5672 }, + { 129,5672 }, { 130,5672 }, { 131,5672 }, { 132,5672 }, { 133,5672 }, + { 134,5672 }, { 135,5672 }, { 136,5672 }, { 137,5672 }, { 138,5672 }, + { 139,5672 }, { 140,5672 }, { 141,5672 }, { 142,5672 }, { 143,5672 }, + { 144,5672 }, { 145,5672 }, { 146,5672 }, { 147,5672 }, { 148,5672 }, + { 149,5672 }, { 150,5672 }, { 151,5672 }, { 152,5672 }, { 153,5672 }, + { 154,5672 }, { 155,5672 }, { 156,5672 }, { 157,5672 }, { 158,5672 }, + { 159,5672 }, { 160,5672 }, { 161,5672 }, { 162,5672 }, { 163,5672 }, + + { 164,5672 }, { 165,5672 }, { 166,5672 }, { 167,5672 }, { 168,5672 }, + { 169,5672 }, { 170,5672 }, { 171,5672 }, { 172,5672 }, { 173,5672 }, + { 174,5672 }, { 175,5672 }, { 176,5672 }, { 177,5672 }, { 178,5672 }, + { 179,5672 }, { 180,5672 }, { 181,5672 }, { 182,5672 }, { 183,5672 }, + { 184,5672 }, { 185,5672 }, { 186,5672 }, { 187,5672 }, { 188,5672 }, + { 189,5672 }, { 190,5672 }, { 191,5672 }, { 192,5672 }, { 193,5672 }, + { 194,5672 }, { 195,5672 }, { 196,5672 }, { 197,5672 }, { 198,5672 }, + { 199,5672 }, { 200,5672 }, { 201,5672 }, { 202,5672 }, { 203,5672 }, + { 204,5672 }, { 205,5672 }, { 206,5672 }, { 207,5672 }, { 208,5672 }, + { 209,5672 }, { 210,5672 }, { 211,5672 }, { 212,5672 }, { 213,5672 }, + + { 214,5672 }, { 215,5672 }, { 216,5672 }, { 217,5672 }, { 218,5672 }, + { 219,5672 }, { 220,5672 }, { 221,5672 }, { 222,5672 }, { 223,5672 }, + { 224,5672 }, { 225,5672 }, { 226,5672 }, { 227,5672 }, { 228,5672 }, + { 229,5672 }, { 230,5672 }, { 231,5672 }, { 232,5672 }, { 233,5672 }, + { 234,5672 }, { 235,5672 }, { 236,5672 }, { 237,5672 }, { 238,5672 }, + { 239,5672 }, { 240,5672 }, { 241,5672 }, { 242,5672 }, { 243,5672 }, + { 244,5672 }, { 245,5672 }, { 246,5672 }, { 247,5672 }, { 248,5672 }, + { 249,5672 }, { 250,5672 }, { 251,5672 }, { 252,5672 }, { 253,5672 }, + { 254,5672 }, { 255,5672 }, { 256,5672 }, { 0, 9 }, { 0,46386 }, + { 1, 0 }, { 2, 0 }, { 3, 0 }, { 4, 0 }, { 5, 0 }, + + { 6, 0 }, { 7, 0 }, { 8, 0 }, { 9, 258 }, { 10,-5638 }, + { 11, 0 }, { 12, 258 }, { 13,-5638 }, { 14, 0 }, { 15, 0 }, + { 16, 0 }, { 17, 0 }, { 18, 0 }, { 19, 0 }, { 20, 0 }, + { 21, 0 }, { 22, 0 }, { 23, 0 }, { 24, 0 }, { 25, 0 }, + { 26, 0 }, { 27, 0 }, { 28, 0 }, { 29, 0 }, { 30, 0 }, + { 31, 0 }, { 32, 258 }, { 33, 0 }, { 34, 0 }, { 35, 0 }, + { 36, 0 }, { 37, 0 }, { 38, 0 }, { 39, 0 }, { 40, 0 }, + { 41, 0 }, { 42, 0 }, { 43, 0 }, { 44, 0 }, { 45, 516 }, + { 46, 0 }, { 47, 0 }, { 48, 0 }, { 49, 0 }, { 50, 0 }, + { 51, 0 }, { 52, 0 }, { 53, 0 }, { 54, 0 }, { 55, 0 }, + + { 56, 0 }, { 57, 0 }, { 58, 0 }, { 59, 0 }, { 60, 0 }, + { 61, 0 }, { 62, 0 }, { 63, 0 }, { 64, 0 }, { 65, 0 }, + { 66, 0 }, { 67, 0 }, { 68, 0 }, { 69, 0 }, { 70, 0 }, + { 71, 0 }, { 72, 0 }, { 73, 0 }, { 74, 0 }, { 75, 0 }, + { 76, 0 }, { 77, 0 }, { 78, 0 }, { 79, 0 }, { 80, 0 }, + { 81, 0 }, { 82, 0 }, { 83, 0 }, { 84, 0 }, { 85, 0 }, + { 86, 0 }, { 87, 0 }, { 88, 0 }, { 89, 0 }, { 90, 0 }, + { 91, 0 }, { 92, 0 }, { 93, 0 }, { 94, 0 }, { 95, 0 }, + { 96, 0 }, { 97, 0 }, { 98, 0 }, { 99, 0 }, { 100, 0 }, + { 101, 0 }, { 102, 0 }, { 103, 0 }, { 104, 0 }, { 105, 0 }, + + { 106, 0 }, { 107, 0 }, { 108, 0 }, { 109, 0 }, { 110, 0 }, + { 111, 0 }, { 112, 0 }, { 113, 0 }, { 114, 0 }, { 115, 0 }, + { 116, 0 }, { 117, 0 }, { 118, 0 }, { 119, 0 }, { 120, 0 }, + { 121, 0 }, { 122, 0 }, { 123, 0 }, { 124, 0 }, { 125, 0 }, + { 126, 0 }, { 127, 0 }, { 128, 0 }, { 129, 0 }, { 130, 0 }, + { 131, 0 }, { 132, 0 }, { 133, 0 }, { 134, 0 }, { 135, 0 }, + { 136, 0 }, { 137, 0 }, { 138, 0 }, { 139, 0 }, { 140, 0 }, + { 141, 0 }, { 142, 0 }, { 143, 0 }, { 144, 0 }, { 145, 0 }, + { 146, 0 }, { 147, 0 }, { 148, 0 }, { 149, 0 }, { 150, 0 }, + { 151, 0 }, { 152, 0 }, { 153, 0 }, { 154, 0 }, { 155, 0 }, + + { 156, 0 }, { 157, 0 }, { 158, 0 }, { 159, 0 }, { 160, 0 }, + { 161, 0 }, { 162, 0 }, { 163, 0 }, { 164, 0 }, { 165, 0 }, + { 166, 0 }, { 167, 0 }, { 168, 0 }, { 169, 0 }, { 170, 0 }, + { 171, 0 }, { 172, 0 }, { 173, 0 }, { 174, 0 }, { 175, 0 }, + { 176, 0 }, { 177, 0 }, { 178, 0 }, { 179, 0 }, { 180, 0 }, + { 181, 0 }, { 182, 0 }, { 183, 0 }, { 184, 0 }, { 185, 0 }, + { 186, 0 }, { 187, 0 }, { 188, 0 }, { 189, 0 }, { 190, 0 }, + { 191, 0 }, { 192, 0 }, { 193, 0 }, { 194, 0 }, { 195, 0 }, + { 196, 0 }, { 197, 0 }, { 198, 0 }, { 199, 0 }, { 200, 0 }, + { 201, 0 }, { 202, 0 }, { 203, 0 }, { 204, 0 }, { 205, 0 }, + + { 206, 0 }, { 207, 0 }, { 208, 0 }, { 209, 0 }, { 210, 0 }, + { 211, 0 }, { 212, 0 }, { 213, 0 }, { 214, 0 }, { 215, 0 }, + { 216, 0 }, { 217, 0 }, { 218, 0 }, { 219, 0 }, { 220, 0 }, + { 221, 0 }, { 222, 0 }, { 223, 0 }, { 224, 0 }, { 225, 0 }, + { 226, 0 }, { 227, 0 }, { 228, 0 }, { 229, 0 }, { 230, 0 }, + { 231, 0 }, { 232, 0 }, { 233, 0 }, { 234, 0 }, { 235, 0 }, + { 236, 0 }, { 237, 0 }, { 238, 0 }, { 239, 0 }, { 240, 0 }, + { 241, 0 }, { 242, 0 }, { 243, 0 }, { 244, 0 }, { 245, 0 }, + { 246, 0 }, { 247, 0 }, { 248, 0 }, { 249, 0 }, { 250, 0 }, + { 251, 0 }, { 252, 0 }, { 253, 0 }, { 254, 0 }, { 255, 0 }, + + { 256, 0 }, { 0, 9 }, { 0,46128 }, { 1,-258 }, { 2,-258 }, + { 3,-258 }, { 4,-258 }, { 5,-258 }, { 6,-258 }, { 7,-258 }, + { 8,-258 }, { 9, 0 }, { 10,-5896 }, { 11,-258 }, { 12, 0 }, + { 13,-5896 }, { 14,-258 }, { 15,-258 }, { 16,-258 }, { 17,-258 }, + { 18,-258 }, { 19,-258 }, { 20,-258 }, { 21,-258 }, { 22,-258 }, + { 23,-258 }, { 24,-258 }, { 25,-258 }, { 26,-258 }, { 27,-258 }, + { 28,-258 }, { 29,-258 }, { 30,-258 }, { 31,-258 }, { 32, 0 }, + { 33,-258 }, { 34,-258 }, { 35,-258 }, { 36,-258 }, { 37,-258 }, + { 38,-258 }, { 39,-258 }, { 40,-258 }, { 41,-258 }, { 42,-258 }, + { 43,-258 }, { 44,-258 }, { 45, 258 }, { 46,-258 }, { 47,-258 }, + + { 48,-258 }, { 49,-258 }, { 50,-258 }, { 51,-258 }, { 52,-258 }, + { 53,-258 }, { 54,-258 }, { 55,-258 }, { 56,-258 }, { 57,-258 }, + { 58,-258 }, { 59,-258 }, { 60,-258 }, { 61,-258 }, { 62,-258 }, + { 63,-258 }, { 64,-258 }, { 65,-258 }, { 66,-258 }, { 67,-258 }, + { 68,-258 }, { 69,-258 }, { 70,-258 }, { 71,-258 }, { 72,-258 }, + { 73,-258 }, { 74,-258 }, { 75,-258 }, { 76,-258 }, { 77,-258 }, + { 78,-258 }, { 79,-258 }, { 80,-258 }, { 81,-258 }, { 82,-258 }, + { 83,-258 }, { 84,-258 }, { 85,-258 }, { 86,-258 }, { 87,-258 }, + { 88,-258 }, { 89,-258 }, { 90,-258 }, { 91,-258 }, { 92,-258 }, + { 93,-258 }, { 94,-258 }, { 95,-258 }, { 96,-258 }, { 97,-258 }, + + { 98,-258 }, { 99,-258 }, { 100,-258 }, { 101,-258 }, { 102,-258 }, + { 103,-258 }, { 104,-258 }, { 105,-258 }, { 106,-258 }, { 107,-258 }, + { 108,-258 }, { 109,-258 }, { 110,-258 }, { 111,-258 }, { 112,-258 }, + { 113,-258 }, { 114,-258 }, { 115,-258 }, { 116,-258 }, { 117,-258 }, + { 118,-258 }, { 119,-258 }, { 120,-258 }, { 121,-258 }, { 122,-258 }, + { 123,-258 }, { 124,-258 }, { 125,-258 }, { 126,-258 }, { 127,-258 }, + { 128,-258 }, { 129,-258 }, { 130,-258 }, { 131,-258 }, { 132,-258 }, + { 133,-258 }, { 134,-258 }, { 135,-258 }, { 136,-258 }, { 137,-258 }, + { 138,-258 }, { 139,-258 }, { 140,-258 }, { 141,-258 }, { 142,-258 }, + { 143,-258 }, { 144,-258 }, { 145,-258 }, { 146,-258 }, { 147,-258 }, + + { 148,-258 }, { 149,-258 }, { 150,-258 }, { 151,-258 }, { 152,-258 }, + { 153,-258 }, { 154,-258 }, { 155,-258 }, { 156,-258 }, { 157,-258 }, + { 158,-258 }, { 159,-258 }, { 160,-258 }, { 161,-258 }, { 162,-258 }, + { 163,-258 }, { 164,-258 }, { 165,-258 }, { 166,-258 }, { 167,-258 }, + { 168,-258 }, { 169,-258 }, { 170,-258 }, { 171,-258 }, { 172,-258 }, + { 173,-258 }, { 174,-258 }, { 175,-258 }, { 176,-258 }, { 177,-258 }, + { 178,-258 }, { 179,-258 }, { 180,-258 }, { 181,-258 }, { 182,-258 }, + { 183,-258 }, { 184,-258 }, { 185,-258 }, { 186,-258 }, { 187,-258 }, + { 188,-258 }, { 189,-258 }, { 190,-258 }, { 191,-258 }, { 192,-258 }, + { 193,-258 }, { 194,-258 }, { 195,-258 }, { 196,-258 }, { 197,-258 }, + + { 198,-258 }, { 199,-258 }, { 200,-258 }, { 201,-258 }, { 202,-258 }, + { 203,-258 }, { 204,-258 }, { 205,-258 }, { 206,-258 }, { 207,-258 }, + { 208,-258 }, { 209,-258 }, { 210,-258 }, { 211,-258 }, { 212,-258 }, + { 213,-258 }, { 214,-258 }, { 215,-258 }, { 216,-258 }, { 217,-258 }, + { 218,-258 }, { 219,-258 }, { 220,-258 }, { 221,-258 }, { 222,-258 }, + { 223,-258 }, { 224,-258 }, { 225,-258 }, { 226,-258 }, { 227,-258 }, + { 228,-258 }, { 229,-258 }, { 230,-258 }, { 231,-258 }, { 232,-258 }, + { 233,-258 }, { 234,-258 }, { 235,-258 }, { 236,-258 }, { 237,-258 }, + { 238,-258 }, { 239,-258 }, { 240,-258 }, { 241,-258 }, { 242,-258 }, + { 243,-258 }, { 244,-258 }, { 245,-258 }, { 246,-258 }, { 247,-258 }, + + { 248,-258 }, { 249,-258 }, { 250,-258 }, { 251,-258 }, { 252,-258 }, + { 253,-258 }, { 254,-258 }, { 255,-258 }, { 256,-258 }, { 0, 9 }, + { 0,45870 }, { 1,-516 }, { 2,-516 }, { 3,-516 }, { 4,-516 }, + { 5,-516 }, { 6,-516 }, { 7,-516 }, { 8,-516 }, { 9,-258 }, + { 10,-6154 }, { 11,-516 }, { 12,-258 }, { 13,-6154 }, { 14,-516 }, + { 15,-516 }, { 16,-516 }, { 17,-516 }, { 18,-516 }, { 19,-516 }, + { 20,-516 }, { 21,-516 }, { 22,-516 }, { 23,-516 }, { 24,-516 }, + { 25,-516 }, { 26,-516 }, { 27,-516 }, { 28,-516 }, { 29,-516 }, + { 30,-516 }, { 31,-516 }, { 32,-258 }, { 33,-516 }, { 34,-516 }, + { 35,-516 }, { 36,-516 }, { 37,-516 }, { 38,-516 }, { 39,-516 }, + + { 40,-516 }, { 41,-516 }, { 42,-516 }, { 43,-516 }, { 44,-516 }, + { 45,5719 }, { 46,-516 }, { 47,-516 }, { 48,-516 }, { 49,-516 }, + { 50,-516 }, { 51,-516 }, { 52,-516 }, { 53,-516 }, { 54,-516 }, + { 55,-516 }, { 56,-516 }, { 57,-516 }, { 58,-516 }, { 59,-516 }, + { 60,-516 }, { 61,-516 }, { 62,-516 }, { 63,-516 }, { 64,-516 }, + { 65,-516 }, { 66,-516 }, { 67,-516 }, { 68,-516 }, { 69,-516 }, + { 70,-516 }, { 71,-516 }, { 72,-516 }, { 73,-516 }, { 74,-516 }, + { 75,-516 }, { 76,-516 }, { 77,-516 }, { 78,-516 }, { 79,-516 }, + { 80,-516 }, { 81,-516 }, { 82,-516 }, { 83,-516 }, { 84,-516 }, + { 85,-516 }, { 86,-516 }, { 87,-516 }, { 88,-516 }, { 89,-516 }, + + { 90,-516 }, { 91,-516 }, { 92,-516 }, { 93,-516 }, { 94,-516 }, + { 95,-516 }, { 96,-516 }, { 97,-516 }, { 98,-516 }, { 99,-516 }, + { 100,-516 }, { 101,-516 }, { 102,-516 }, { 103,-516 }, { 104,-516 }, + { 105,-516 }, { 106,-516 }, { 107,-516 }, { 108,-516 }, { 109,-516 }, + { 110,-516 }, { 111,-516 }, { 112,-516 }, { 113,-516 }, { 114,-516 }, + { 115,-516 }, { 116,-516 }, { 117,-516 }, { 118,-516 }, { 119,-516 }, + { 120,-516 }, { 121,-516 }, { 122,-516 }, { 123,-516 }, { 124,-516 }, + { 125,-516 }, { 126,-516 }, { 127,-516 }, { 128,-516 }, { 129,-516 }, + { 130,-516 }, { 131,-516 }, { 132,-516 }, { 133,-516 }, { 134,-516 }, + { 135,-516 }, { 136,-516 }, { 137,-516 }, { 138,-516 }, { 139,-516 }, + + { 140,-516 }, { 141,-516 }, { 142,-516 }, { 143,-516 }, { 144,-516 }, + { 145,-516 }, { 146,-516 }, { 147,-516 }, { 148,-516 }, { 149,-516 }, + { 150,-516 }, { 151,-516 }, { 152,-516 }, { 153,-516 }, { 154,-516 }, + { 155,-516 }, { 156,-516 }, { 157,-516 }, { 158,-516 }, { 159,-516 }, + { 160,-516 }, { 161,-516 }, { 162,-516 }, { 163,-516 }, { 164,-516 }, + { 165,-516 }, { 166,-516 }, { 167,-516 }, { 168,-516 }, { 169,-516 }, + { 170,-516 }, { 171,-516 }, { 172,-516 }, { 173,-516 }, { 174,-516 }, + { 175,-516 }, { 176,-516 }, { 177,-516 }, { 178,-516 }, { 179,-516 }, + { 180,-516 }, { 181,-516 }, { 182,-516 }, { 183,-516 }, { 184,-516 }, + { 185,-516 }, { 186,-516 }, { 187,-516 }, { 188,-516 }, { 189,-516 }, + + { 190,-516 }, { 191,-516 }, { 192,-516 }, { 193,-516 }, { 194,-516 }, + { 195,-516 }, { 196,-516 }, { 197,-516 }, { 198,-516 }, { 199,-516 }, + { 200,-516 }, { 201,-516 }, { 202,-516 }, { 203,-516 }, { 204,-516 }, + { 205,-516 }, { 206,-516 }, { 207,-516 }, { 208,-516 }, { 209,-516 }, + { 210,-516 }, { 211,-516 }, { 212,-516 }, { 213,-516 }, { 214,-516 }, + { 215,-516 }, { 216,-516 }, { 217,-516 }, { 218,-516 }, { 219,-516 }, + { 220,-516 }, { 221,-516 }, { 222,-516 }, { 223,-516 }, { 224,-516 }, + { 225,-516 }, { 226,-516 }, { 227,-516 }, { 228,-516 }, { 229,-516 }, + { 230,-516 }, { 231,-516 }, { 232,-516 }, { 233,-516 }, { 234,-516 }, + { 235,-516 }, { 236,-516 }, { 237,-516 }, { 238,-516 }, { 239,-516 }, + + { 240,-516 }, { 241,-516 }, { 242,-516 }, { 243,-516 }, { 244,-516 }, + { 245,-516 }, { 246,-516 }, { 247,-516 }, { 248,-516 }, { 249,-516 }, + { 250,-516 }, { 251,-516 }, { 252,-516 }, { 253,-516 }, { 254,-516 }, + { 255,-516 }, { 256,-516 }, { 0, 16 }, { 0,45612 }, { 1,5719 }, + { 2,5719 }, { 3,5719 }, { 4,5719 }, { 5,5719 }, { 6,5719 }, + { 7,5719 }, { 8,5719 }, { 9,5977 }, { 10,6235 }, { 11,5719 }, + { 12,5977 }, { 13,6235 }, { 14,5719 }, { 15,5719 }, { 16,5719 }, + { 17,5719 }, { 18,5719 }, { 19,5719 }, { 20,5719 }, { 21,5719 }, + { 22,5719 }, { 23,5719 }, { 24,5719 }, { 25,5719 }, { 26,5719 }, + { 27,5719 }, { 28,5719 }, { 29,5719 }, { 30,5719 }, { 31,5719 }, + + { 32,5977 }, { 33,5719 }, { 34,5719 }, { 35,5719 }, { 36,5719 }, + { 37,5719 }, { 38,5719 }, { 39,5719 }, { 40,5719 }, { 41,5719 }, + { 42,5719 }, { 43,5719 }, { 44,5719 }, { 45,6282 }, { 46,5719 }, + { 47,5719 }, { 48,5719 }, { 49,5719 }, { 50,5719 }, { 51,5719 }, + { 52,5719 }, { 53,5719 }, { 54,5719 }, { 55,5719 }, { 56,5719 }, + { 57,5719 }, { 58,5719 }, { 59,5719 }, { 60,5719 }, { 61,5719 }, + { 62,5719 }, { 63,5719 }, { 64,5719 }, { 65,5719 }, { 66,5719 }, + { 67,5719 }, { 68,5719 }, { 69,5719 }, { 70,5719 }, { 71,5719 }, + { 72,5719 }, { 73,5719 }, { 74,5719 }, { 75,5719 }, { 76,5719 }, + { 77,5719 }, { 78,5719 }, { 79,5719 }, { 80,5719 }, { 81,5719 }, + + { 82,5719 }, { 83,5719 }, { 84,5719 }, { 85,5719 }, { 86,5719 }, + { 87,5719 }, { 88,5719 }, { 89,5719 }, { 90,5719 }, { 91,5719 }, + { 92,5719 }, { 93,5719 }, { 94,5719 }, { 95,5719 }, { 96,5719 }, + { 97,5719 }, { 98,5719 }, { 99,5719 }, { 100,5719 }, { 101,5719 }, + { 102,5719 }, { 103,5719 }, { 104,5719 }, { 105,5719 }, { 106,5719 }, + { 107,5719 }, { 108,5719 }, { 109,5719 }, { 110,5719 }, { 111,5719 }, + { 112,5719 }, { 113,5719 }, { 114,5719 }, { 115,5719 }, { 116,5719 }, + { 117,5719 }, { 118,5719 }, { 119,5719 }, { 120,5719 }, { 121,5719 }, + { 122,5719 }, { 123,5719 }, { 124,5719 }, { 125,5719 }, { 126,5719 }, + { 127,5719 }, { 128,5719 }, { 129,5719 }, { 130,5719 }, { 131,5719 }, + + { 132,5719 }, { 133,5719 }, { 134,5719 }, { 135,5719 }, { 136,5719 }, + { 137,5719 }, { 138,5719 }, { 139,5719 }, { 140,5719 }, { 141,5719 }, + { 142,5719 }, { 143,5719 }, { 144,5719 }, { 145,5719 }, { 146,5719 }, + { 147,5719 }, { 148,5719 }, { 149,5719 }, { 150,5719 }, { 151,5719 }, + { 152,5719 }, { 153,5719 }, { 154,5719 }, { 155,5719 }, { 156,5719 }, + { 157,5719 }, { 158,5719 }, { 159,5719 }, { 160,5719 }, { 161,5719 }, + { 162,5719 }, { 163,5719 }, { 164,5719 }, { 165,5719 }, { 166,5719 }, + { 167,5719 }, { 168,5719 }, { 169,5719 }, { 170,5719 }, { 171,5719 }, + { 172,5719 }, { 173,5719 }, { 174,5719 }, { 175,5719 }, { 176,5719 }, + { 177,5719 }, { 178,5719 }, { 179,5719 }, { 180,5719 }, { 181,5719 }, + + { 182,5719 }, { 183,5719 }, { 184,5719 }, { 185,5719 }, { 186,5719 }, + { 187,5719 }, { 188,5719 }, { 189,5719 }, { 190,5719 }, { 191,5719 }, + { 192,5719 }, { 193,5719 }, { 194,5719 }, { 195,5719 }, { 196,5719 }, + { 197,5719 }, { 198,5719 }, { 199,5719 }, { 200,5719 }, { 201,5719 }, + { 202,5719 }, { 203,5719 }, { 204,5719 }, { 205,5719 }, { 206,5719 }, + { 207,5719 }, { 208,5719 }, { 209,5719 }, { 210,5719 }, { 211,5719 }, + { 212,5719 }, { 213,5719 }, { 214,5719 }, { 215,5719 }, { 216,5719 }, + { 217,5719 }, { 218,5719 }, { 219,5719 }, { 220,5719 }, { 221,5719 }, + { 222,5719 }, { 223,5719 }, { 224,5719 }, { 225,5719 }, { 226,5719 }, + { 227,5719 }, { 228,5719 }, { 229,5719 }, { 230,5719 }, { 231,5719 }, + + { 232,5719 }, { 233,5719 }, { 234,5719 }, { 235,5719 }, { 236,5719 }, + { 237,5719 }, { 238,5719 }, { 239,5719 }, { 240,5719 }, { 241,5719 }, + { 242,5719 }, { 243,5719 }, { 244,5719 }, { 245,5719 }, { 246,5719 }, + { 247,5719 }, { 248,5719 }, { 249,5719 }, { 250,5719 }, { 251,5719 }, + { 252,5719 }, { 253,5719 }, { 254,5719 }, { 255,5719 }, { 256,5719 }, + { 0, 16 }, { 0,45354 }, { 1, 0 }, { 2, 0 }, { 3, 0 }, + { 4, 0 }, { 5, 0 }, { 6, 0 }, { 7, 0 }, { 8, 0 }, + { 9, 258 }, { 10,-5716 }, { 11, 0 }, { 12, 258 }, { 13,-5716 }, + { 14, 0 }, { 15, 0 }, { 16, 0 }, { 17, 0 }, { 18, 0 }, + { 19, 0 }, { 20, 0 }, { 21, 0 }, { 22, 0 }, { 23, 0 }, + + { 24, 0 }, { 25, 0 }, { 26, 0 }, { 27, 0 }, { 28, 0 }, + { 29, 0 }, { 30, 0 }, { 31, 0 }, { 32, 258 }, { 33, 0 }, + { 34, 0 }, { 35, 0 }, { 36, 0 }, { 37, 0 }, { 38, 0 }, + { 39, 0 }, { 40, 0 }, { 41, 0 }, { 42, 0 }, { 43, 0 }, + { 44, 0 }, { 45, 516 }, { 46, 0 }, { 47, 0 }, { 48, 0 }, + { 49, 0 }, { 50, 0 }, { 51, 0 }, { 52, 0 }, { 53, 0 }, + { 54, 0 }, { 55, 0 }, { 56, 0 }, { 57, 0 }, { 58, 0 }, + { 59, 0 }, { 60, 0 }, { 61, 0 }, { 62, 0 }, { 63, 0 }, + { 64, 0 }, { 65, 0 }, { 66, 0 }, { 67, 0 }, { 68, 0 }, + { 69, 0 }, { 70, 0 }, { 71, 0 }, { 72, 0 }, { 73, 0 }, + + { 74, 0 }, { 75, 0 }, { 76, 0 }, { 77, 0 }, { 78, 0 }, + { 79, 0 }, { 80, 0 }, { 81, 0 }, { 82, 0 }, { 83, 0 }, + { 84, 0 }, { 85, 0 }, { 86, 0 }, { 87, 0 }, { 88, 0 }, + { 89, 0 }, { 90, 0 }, { 91, 0 }, { 92, 0 }, { 93, 0 }, + { 94, 0 }, { 95, 0 }, { 96, 0 }, { 97, 0 }, { 98, 0 }, + { 99, 0 }, { 100, 0 }, { 101, 0 }, { 102, 0 }, { 103, 0 }, + { 104, 0 }, { 105, 0 }, { 106, 0 }, { 107, 0 }, { 108, 0 }, + { 109, 0 }, { 110, 0 }, { 111, 0 }, { 112, 0 }, { 113, 0 }, + { 114, 0 }, { 115, 0 }, { 116, 0 }, { 117, 0 }, { 118, 0 }, + { 119, 0 }, { 120, 0 }, { 121, 0 }, { 122, 0 }, { 123, 0 }, + + { 124, 0 }, { 125, 0 }, { 126, 0 }, { 127, 0 }, { 128, 0 }, + { 129, 0 }, { 130, 0 }, { 131, 0 }, { 132, 0 }, { 133, 0 }, + { 134, 0 }, { 135, 0 }, { 136, 0 }, { 137, 0 }, { 138, 0 }, + { 139, 0 }, { 140, 0 }, { 141, 0 }, { 142, 0 }, { 143, 0 }, + { 144, 0 }, { 145, 0 }, { 146, 0 }, { 147, 0 }, { 148, 0 }, + { 149, 0 }, { 150, 0 }, { 151, 0 }, { 152, 0 }, { 153, 0 }, + { 154, 0 }, { 155, 0 }, { 156, 0 }, { 157, 0 }, { 158, 0 }, + { 159, 0 }, { 160, 0 }, { 161, 0 }, { 162, 0 }, { 163, 0 }, + { 164, 0 }, { 165, 0 }, { 166, 0 }, { 167, 0 }, { 168, 0 }, + { 169, 0 }, { 170, 0 }, { 171, 0 }, { 172, 0 }, { 173, 0 }, + + { 174, 0 }, { 175, 0 }, { 176, 0 }, { 177, 0 }, { 178, 0 }, + { 179, 0 }, { 180, 0 }, { 181, 0 }, { 182, 0 }, { 183, 0 }, + { 184, 0 }, { 185, 0 }, { 186, 0 }, { 187, 0 }, { 188, 0 }, + { 189, 0 }, { 190, 0 }, { 191, 0 }, { 192, 0 }, { 193, 0 }, + { 194, 0 }, { 195, 0 }, { 196, 0 }, { 197, 0 }, { 198, 0 }, + { 199, 0 }, { 200, 0 }, { 201, 0 }, { 202, 0 }, { 203, 0 }, + { 204, 0 }, { 205, 0 }, { 206, 0 }, { 207, 0 }, { 208, 0 }, + { 209, 0 }, { 210, 0 }, { 211, 0 }, { 212, 0 }, { 213, 0 }, + { 214, 0 }, { 215, 0 }, { 216, 0 }, { 217, 0 }, { 218, 0 }, + { 219, 0 }, { 220, 0 }, { 221, 0 }, { 222, 0 }, { 223, 0 }, + + { 224, 0 }, { 225, 0 }, { 226, 0 }, { 227, 0 }, { 228, 0 }, + { 229, 0 }, { 230, 0 }, { 231, 0 }, { 232, 0 }, { 233, 0 }, + { 234, 0 }, { 235, 0 }, { 236, 0 }, { 237, 0 }, { 238, 0 }, + { 239, 0 }, { 240, 0 }, { 241, 0 }, { 242, 0 }, { 243, 0 }, + { 244, 0 }, { 245, 0 }, { 246, 0 }, { 247, 0 }, { 248, 0 }, + { 249, 0 }, { 250, 0 }, { 251, 0 }, { 252, 0 }, { 253, 0 }, + { 254, 0 }, { 255, 0 }, { 256, 0 }, { 0, 16 }, { 0,45096 }, + { 1,-258 }, { 2,-258 }, { 3,-258 }, { 4,-258 }, { 5,-258 }, + { 6,-258 }, { 7,-258 }, { 8,-258 }, { 9, 0 }, { 10,-5974 }, + { 11,-258 }, { 12, 0 }, { 13,-5974 }, { 14,-258 }, { 15,-258 }, + + { 16,-258 }, { 17,-258 }, { 18,-258 }, { 19,-258 }, { 20,-258 }, + { 21,-258 }, { 22,-258 }, { 23,-258 }, { 24,-258 }, { 25,-258 }, + { 26,-258 }, { 27,-258 }, { 28,-258 }, { 29,-258 }, { 30,-258 }, + { 31,-258 }, { 32, 0 }, { 33,-258 }, { 34,-258 }, { 35,-258 }, + { 36,-258 }, { 37,-258 }, { 38,-258 }, { 39,-258 }, { 40,-258 }, + { 41,-258 }, { 42,-258 }, { 43,-258 }, { 44,-258 }, { 45, 258 }, + { 46,-258 }, { 47,-258 }, { 48,-258 }, { 49,-258 }, { 50,-258 }, + { 51,-258 }, { 52,-258 }, { 53,-258 }, { 54,-258 }, { 55,-258 }, + { 56,-258 }, { 57,-258 }, { 58,-258 }, { 59,-258 }, { 60,-258 }, + { 61,-258 }, { 62,-258 }, { 63,-258 }, { 64,-258 }, { 65,-258 }, + + { 66,-258 }, { 67,-258 }, { 68,-258 }, { 69,-258 }, { 70,-258 }, + { 71,-258 }, { 72,-258 }, { 73,-258 }, { 74,-258 }, { 75,-258 }, + { 76,-258 }, { 77,-258 }, { 78,-258 }, { 79,-258 }, { 80,-258 }, + { 81,-258 }, { 82,-258 }, { 83,-258 }, { 84,-258 }, { 85,-258 }, + { 86,-258 }, { 87,-258 }, { 88,-258 }, { 89,-258 }, { 90,-258 }, + { 91,-258 }, { 92,-258 }, { 93,-258 }, { 94,-258 }, { 95,-258 }, + { 96,-258 }, { 97,-258 }, { 98,-258 }, { 99,-258 }, { 100,-258 }, + { 101,-258 }, { 102,-258 }, { 103,-258 }, { 104,-258 }, { 105,-258 }, + { 106,-258 }, { 107,-258 }, { 108,-258 }, { 109,-258 }, { 110,-258 }, + { 111,-258 }, { 112,-258 }, { 113,-258 }, { 114,-258 }, { 115,-258 }, + + { 116,-258 }, { 117,-258 }, { 118,-258 }, { 119,-258 }, { 120,-258 }, + { 121,-258 }, { 122,-258 }, { 123,-258 }, { 124,-258 }, { 125,-258 }, + { 126,-258 }, { 127,-258 }, { 128,-258 }, { 129,-258 }, { 130,-258 }, + { 131,-258 }, { 132,-258 }, { 133,-258 }, { 134,-258 }, { 135,-258 }, + { 136,-258 }, { 137,-258 }, { 138,-258 }, { 139,-258 }, { 140,-258 }, + { 141,-258 }, { 142,-258 }, { 143,-258 }, { 144,-258 }, { 145,-258 }, + { 146,-258 }, { 147,-258 }, { 148,-258 }, { 149,-258 }, { 150,-258 }, + { 151,-258 }, { 152,-258 }, { 153,-258 }, { 154,-258 }, { 155,-258 }, + { 156,-258 }, { 157,-258 }, { 158,-258 }, { 159,-258 }, { 160,-258 }, + { 161,-258 }, { 162,-258 }, { 163,-258 }, { 164,-258 }, { 165,-258 }, + + { 166,-258 }, { 167,-258 }, { 168,-258 }, { 169,-258 }, { 170,-258 }, + { 171,-258 }, { 172,-258 }, { 173,-258 }, { 174,-258 }, { 175,-258 }, + { 176,-258 }, { 177,-258 }, { 178,-258 }, { 179,-258 }, { 180,-258 }, + { 181,-258 }, { 182,-258 }, { 183,-258 }, { 184,-258 }, { 185,-258 }, + { 186,-258 }, { 187,-258 }, { 188,-258 }, { 189,-258 }, { 190,-258 }, + { 191,-258 }, { 192,-258 }, { 193,-258 }, { 194,-258 }, { 195,-258 }, + { 196,-258 }, { 197,-258 }, { 198,-258 }, { 199,-258 }, { 200,-258 }, + { 201,-258 }, { 202,-258 }, { 203,-258 }, { 204,-258 }, { 205,-258 }, + { 206,-258 }, { 207,-258 }, { 208,-258 }, { 209,-258 }, { 210,-258 }, + { 211,-258 }, { 212,-258 }, { 213,-258 }, { 214,-258 }, { 215,-258 }, + + { 216,-258 }, { 217,-258 }, { 218,-258 }, { 219,-258 }, { 220,-258 }, + { 221,-258 }, { 222,-258 }, { 223,-258 }, { 224,-258 }, { 225,-258 }, + { 226,-258 }, { 227,-258 }, { 228,-258 }, { 229,-258 }, { 230,-258 }, + { 231,-258 }, { 232,-258 }, { 233,-258 }, { 234,-258 }, { 235,-258 }, + { 236,-258 }, { 237,-258 }, { 238,-258 }, { 239,-258 }, { 240,-258 }, + { 241,-258 }, { 242,-258 }, { 243,-258 }, { 244,-258 }, { 245,-258 }, + { 246,-258 }, { 247,-258 }, { 248,-258 }, { 249,-258 }, { 250,-258 }, + { 251,-258 }, { 252,-258 }, { 253,-258 }, { 254,-258 }, { 255,-258 }, + { 256,-258 }, { 0, 16 }, { 0,44838 }, { 1,-516 }, { 2,-516 }, + { 3,-516 }, { 4,-516 }, { 5,-516 }, { 6,-516 }, { 7,-516 }, + + { 8,-516 }, { 9,-258 }, { 10,-6232 }, { 11,-516 }, { 12,-258 }, + { 13,-6232 }, { 14,-516 }, { 15,-516 }, { 16,-516 }, { 17,-516 }, + { 18,-516 }, { 19,-516 }, { 20,-516 }, { 21,-516 }, { 22,-516 }, + { 23,-516 }, { 24,-516 }, { 25,-516 }, { 26,-516 }, { 27,-516 }, + { 28,-516 }, { 29,-516 }, { 30,-516 }, { 31,-516 }, { 32,-258 }, + { 33,-516 }, { 34,-516 }, { 35,-516 }, { 36,-516 }, { 37,-516 }, + { 38,-516 }, { 39,-516 }, { 40,-516 }, { 41,-516 }, { 42,-516 }, + { 43,-516 }, { 44,-516 }, { 45,5766 }, { 46,-516 }, { 47,-516 }, + { 48,-516 }, { 49,-516 }, { 50,-516 }, { 51,-516 }, { 52,-516 }, + { 53,-516 }, { 54,-516 }, { 55,-516 }, { 56,-516 }, { 57,-516 }, + + { 58,-516 }, { 59,-516 }, { 60,-516 }, { 61,-516 }, { 62,-516 }, + { 63,-516 }, { 64,-516 }, { 65,-516 }, { 66,-516 }, { 67,-516 }, + { 68,-516 }, { 69,-516 }, { 70,-516 }, { 71,-516 }, { 72,-516 }, + { 73,-516 }, { 74,-516 }, { 75,-516 }, { 76,-516 }, { 77,-516 }, + { 78,-516 }, { 79,-516 }, { 80,-516 }, { 81,-516 }, { 82,-516 }, + { 83,-516 }, { 84,-516 }, { 85,-516 }, { 86,-516 }, { 87,-516 }, + { 88,-516 }, { 89,-516 }, { 90,-516 }, { 91,-516 }, { 92,-516 }, + { 93,-516 }, { 94,-516 }, { 95,-516 }, { 96,-516 }, { 97,-516 }, + { 98,-516 }, { 99,-516 }, { 100,-516 }, { 101,-516 }, { 102,-516 }, + { 103,-516 }, { 104,-516 }, { 105,-516 }, { 106,-516 }, { 107,-516 }, + + { 108,-516 }, { 109,-516 }, { 110,-516 }, { 111,-516 }, { 112,-516 }, + { 113,-516 }, { 114,-516 }, { 115,-516 }, { 116,-516 }, { 117,-516 }, + { 118,-516 }, { 119,-516 }, { 120,-516 }, { 121,-516 }, { 122,-516 }, + { 123,-516 }, { 124,-516 }, { 125,-516 }, { 126,-516 }, { 127,-516 }, + { 128,-516 }, { 129,-516 }, { 130,-516 }, { 131,-516 }, { 132,-516 }, + { 133,-516 }, { 134,-516 }, { 135,-516 }, { 136,-516 }, { 137,-516 }, + { 138,-516 }, { 139,-516 }, { 140,-516 }, { 141,-516 }, { 142,-516 }, + { 143,-516 }, { 144,-516 }, { 145,-516 }, { 146,-516 }, { 147,-516 }, + { 148,-516 }, { 149,-516 }, { 150,-516 }, { 151,-516 }, { 152,-516 }, + { 153,-516 }, { 154,-516 }, { 155,-516 }, { 156,-516 }, { 157,-516 }, + + { 158,-516 }, { 159,-516 }, { 160,-516 }, { 161,-516 }, { 162,-516 }, + { 163,-516 }, { 164,-516 }, { 165,-516 }, { 166,-516 }, { 167,-516 }, + { 168,-516 }, { 169,-516 }, { 170,-516 }, { 171,-516 }, { 172,-516 }, + { 173,-516 }, { 174,-516 }, { 175,-516 }, { 176,-516 }, { 177,-516 }, + { 178,-516 }, { 179,-516 }, { 180,-516 }, { 181,-516 }, { 182,-516 }, + { 183,-516 }, { 184,-516 }, { 185,-516 }, { 186,-516 }, { 187,-516 }, + { 188,-516 }, { 189,-516 }, { 190,-516 }, { 191,-516 }, { 192,-516 }, + { 193,-516 }, { 194,-516 }, { 195,-516 }, { 196,-516 }, { 197,-516 }, + { 198,-516 }, { 199,-516 }, { 200,-516 }, { 201,-516 }, { 202,-516 }, + { 203,-516 }, { 204,-516 }, { 205,-516 }, { 206,-516 }, { 207,-516 }, + + { 208,-516 }, { 209,-516 }, { 210,-516 }, { 211,-516 }, { 212,-516 }, + { 213,-516 }, { 214,-516 }, { 215,-516 }, { 216,-516 }, { 217,-516 }, + { 218,-516 }, { 219,-516 }, { 220,-516 }, { 221,-516 }, { 222,-516 }, + { 223,-516 }, { 224,-516 }, { 225,-516 }, { 226,-516 }, { 227,-516 }, + { 228,-516 }, { 229,-516 }, { 230,-516 }, { 231,-516 }, { 232,-516 }, + { 233,-516 }, { 234,-516 }, { 235,-516 }, { 236,-516 }, { 237,-516 }, + { 238,-516 }, { 239,-516 }, { 240,-516 }, { 241,-516 }, { 242,-516 }, + { 243,-516 }, { 244,-516 }, { 245,-516 }, { 246,-516 }, { 247,-516 }, + { 248,-516 }, { 249,-516 }, { 250,-516 }, { 251,-516 }, { 252,-516 }, + { 253,-516 }, { 254,-516 }, { 255,-516 }, { 256,-516 }, { 0, 22 }, + + { 0,44580 }, { 1,5766 }, { 2,5766 }, { 3,5766 }, { 4,5766 }, + { 5,5766 }, { 6,5766 }, { 7,5766 }, { 8,5766 }, { 9,6024 }, + { 10,6282 }, { 11,5766 }, { 12,6024 }, { 13,6282 }, { 14,5766 }, + { 15,5766 }, { 16,5766 }, { 17,5766 }, { 18,5766 }, { 19,5766 }, + { 20,5766 }, { 21,5766 }, { 22,5766 }, { 23,5766 }, { 24,5766 }, + { 25,5766 }, { 26,5766 }, { 27,5766 }, { 28,5766 }, { 29,5766 }, + { 30,5766 }, { 31,5766 }, { 32,6024 }, { 33,5766 }, { 34,5766 }, + { 35,5766 }, { 36,5766 }, { 37,5766 }, { 38,5766 }, { 39,5766 }, + { 40,5766 }, { 41,5766 }, { 42,5766 }, { 43,5766 }, { 44,5766 }, + { 45,6329 }, { 46,5766 }, { 47,5766 }, { 48,5766 }, { 49,5766 }, + + { 50,5766 }, { 51,5766 }, { 52,5766 }, { 53,5766 }, { 54,5766 }, + { 55,5766 }, { 56,5766 }, { 57,5766 }, { 58,5766 }, { 59,5766 }, + { 60,5766 }, { 61,5766 }, { 62,5766 }, { 63,5766 }, { 64,5766 }, + { 65,5766 }, { 66,5766 }, { 67,5766 }, { 68,5766 }, { 69,5766 }, + { 70,5766 }, { 71,5766 }, { 72,5766 }, { 73,5766 }, { 74,5766 }, + { 75,5766 }, { 76,5766 }, { 77,5766 }, { 78,5766 }, { 79,5766 }, + { 80,5766 }, { 81,5766 }, { 82,5766 }, { 83,5766 }, { 84,5766 }, + { 85,5766 }, { 86,5766 }, { 87,5766 }, { 88,5766 }, { 89,5766 }, + { 90,5766 }, { 91,5766 }, { 92,5766 }, { 93,5766 }, { 94,5766 }, + { 95,5766 }, { 96,5766 }, { 97,5766 }, { 98,5766 }, { 99,5766 }, + + { 100,5766 }, { 101,5766 }, { 102,5766 }, { 103,5766 }, { 104,5766 }, + { 105,5766 }, { 106,5766 }, { 107,5766 }, { 108,5766 }, { 109,5766 }, + { 110,5766 }, { 111,5766 }, { 112,5766 }, { 113,5766 }, { 114,5766 }, + { 115,5766 }, { 116,5766 }, { 117,5766 }, { 118,5766 }, { 119,5766 }, + { 120,5766 }, { 121,5766 }, { 122,5766 }, { 123,5766 }, { 124,5766 }, + { 125,5766 }, { 126,5766 }, { 127,5766 }, { 128,5766 }, { 129,5766 }, + { 130,5766 }, { 131,5766 }, { 132,5766 }, { 133,5766 }, { 134,5766 }, + { 135,5766 }, { 136,5766 }, { 137,5766 }, { 138,5766 }, { 139,5766 }, + { 140,5766 }, { 141,5766 }, { 142,5766 }, { 143,5766 }, { 144,5766 }, + { 145,5766 }, { 146,5766 }, { 147,5766 }, { 148,5766 }, { 149,5766 }, + + { 150,5766 }, { 151,5766 }, { 152,5766 }, { 153,5766 }, { 154,5766 }, + { 155,5766 }, { 156,5766 }, { 157,5766 }, { 158,5766 }, { 159,5766 }, + { 160,5766 }, { 161,5766 }, { 162,5766 }, { 163,5766 }, { 164,5766 }, + { 165,5766 }, { 166,5766 }, { 167,5766 }, { 168,5766 }, { 169,5766 }, + { 170,5766 }, { 171,5766 }, { 172,5766 }, { 173,5766 }, { 174,5766 }, + { 175,5766 }, { 176,5766 }, { 177,5766 }, { 178,5766 }, { 179,5766 }, + { 180,5766 }, { 181,5766 }, { 182,5766 }, { 183,5766 }, { 184,5766 }, + { 185,5766 }, { 186,5766 }, { 187,5766 }, { 188,5766 }, { 189,5766 }, + { 190,5766 }, { 191,5766 }, { 192,5766 }, { 193,5766 }, { 194,5766 }, + { 195,5766 }, { 196,5766 }, { 197,5766 }, { 198,5766 }, { 199,5766 }, + + { 200,5766 }, { 201,5766 }, { 202,5766 }, { 203,5766 }, { 204,5766 }, + { 205,5766 }, { 206,5766 }, { 207,5766 }, { 208,5766 }, { 209,5766 }, + { 210,5766 }, { 211,5766 }, { 212,5766 }, { 213,5766 }, { 214,5766 }, + { 215,5766 }, { 216,5766 }, { 217,5766 }, { 218,5766 }, { 219,5766 }, + { 220,5766 }, { 221,5766 }, { 222,5766 }, { 223,5766 }, { 224,5766 }, + { 225,5766 }, { 226,5766 }, { 227,5766 }, { 228,5766 }, { 229,5766 }, + { 230,5766 }, { 231,5766 }, { 232,5766 }, { 233,5766 }, { 234,5766 }, + { 235,5766 }, { 236,5766 }, { 237,5766 }, { 238,5766 }, { 239,5766 }, + { 240,5766 }, { 241,5766 }, { 242,5766 }, { 243,5766 }, { 244,5766 }, + { 245,5766 }, { 246,5766 }, { 247,5766 }, { 248,5766 }, { 249,5766 }, + + { 250,5766 }, { 251,5766 }, { 252,5766 }, { 253,5766 }, { 254,5766 }, + { 255,5766 }, { 256,5766 }, { 0, 22 }, { 0,44322 }, { 1, 0 }, + { 2, 0 }, { 3, 0 }, { 4, 0 }, { 5, 0 }, { 6, 0 }, + { 7, 0 }, { 8, 0 }, { 9, 258 }, { 10,-6438 }, { 11, 0 }, + { 12, 258 }, { 13,-6438 }, { 14, 0 }, { 15, 0 }, { 16, 0 }, + { 17, 0 }, { 18, 0 }, { 19, 0 }, { 20, 0 }, { 21, 0 }, + { 22, 0 }, { 23, 0 }, { 24, 0 }, { 25, 0 }, { 26, 0 }, + { 27, 0 }, { 28, 0 }, { 29, 0 }, { 30, 0 }, { 31, 0 }, + { 32, 258 }, { 33, 0 }, { 34, 0 }, { 35, 0 }, { 36, 0 }, + { 37, 0 }, { 38, 0 }, { 39, 0 }, { 40, 0 }, { 41, 0 }, + + { 42, 0 }, { 43, 0 }, { 44, 0 }, { 45, 516 }, { 46, 0 }, + { 47, 0 }, { 48, 0 }, { 49, 0 }, { 50, 0 }, { 51, 0 }, + { 52, 0 }, { 53, 0 }, { 54, 0 }, { 55, 0 }, { 56, 0 }, + { 57, 0 }, { 58, 0 }, { 59, 0 }, { 60, 0 }, { 61, 0 }, + { 62, 0 }, { 63, 0 }, { 64, 0 }, { 65, 0 }, { 66, 0 }, + { 67, 0 }, { 68, 0 }, { 69, 0 }, { 70, 0 }, { 71, 0 }, + { 72, 0 }, { 73, 0 }, { 74, 0 }, { 75, 0 }, { 76, 0 }, + { 77, 0 }, { 78, 0 }, { 79, 0 }, { 80, 0 }, { 81, 0 }, + { 82, 0 }, { 83, 0 }, { 84, 0 }, { 85, 0 }, { 86, 0 }, + { 87, 0 }, { 88, 0 }, { 89, 0 }, { 90, 0 }, { 91, 0 }, + + { 92, 0 }, { 93, 0 }, { 94, 0 }, { 95, 0 }, { 96, 0 }, + { 97, 0 }, { 98, 0 }, { 99, 0 }, { 100, 0 }, { 101, 0 }, + { 102, 0 }, { 103, 0 }, { 104, 0 }, { 105, 0 }, { 106, 0 }, + { 107, 0 }, { 108, 0 }, { 109, 0 }, { 110, 0 }, { 111, 0 }, + { 112, 0 }, { 113, 0 }, { 114, 0 }, { 115, 0 }, { 116, 0 }, + { 117, 0 }, { 118, 0 }, { 119, 0 }, { 120, 0 }, { 121, 0 }, + { 122, 0 }, { 123, 0 }, { 124, 0 }, { 125, 0 }, { 126, 0 }, + { 127, 0 }, { 128, 0 }, { 129, 0 }, { 130, 0 }, { 131, 0 }, + { 132, 0 }, { 133, 0 }, { 134, 0 }, { 135, 0 }, { 136, 0 }, + { 137, 0 }, { 138, 0 }, { 139, 0 }, { 140, 0 }, { 141, 0 }, + + { 142, 0 }, { 143, 0 }, { 144, 0 }, { 145, 0 }, { 146, 0 }, + { 147, 0 }, { 148, 0 }, { 149, 0 }, { 150, 0 }, { 151, 0 }, + { 152, 0 }, { 153, 0 }, { 154, 0 }, { 155, 0 }, { 156, 0 }, + { 157, 0 }, { 158, 0 }, { 159, 0 }, { 160, 0 }, { 161, 0 }, + { 162, 0 }, { 163, 0 }, { 164, 0 }, { 165, 0 }, { 166, 0 }, + { 167, 0 }, { 168, 0 }, { 169, 0 }, { 170, 0 }, { 171, 0 }, + { 172, 0 }, { 173, 0 }, { 174, 0 }, { 175, 0 }, { 176, 0 }, + { 177, 0 }, { 178, 0 }, { 179, 0 }, { 180, 0 }, { 181, 0 }, + { 182, 0 }, { 183, 0 }, { 184, 0 }, { 185, 0 }, { 186, 0 }, + { 187, 0 }, { 188, 0 }, { 189, 0 }, { 190, 0 }, { 191, 0 }, + + { 192, 0 }, { 193, 0 }, { 194, 0 }, { 195, 0 }, { 196, 0 }, + { 197, 0 }, { 198, 0 }, { 199, 0 }, { 200, 0 }, { 201, 0 }, + { 202, 0 }, { 203, 0 }, { 204, 0 }, { 205, 0 }, { 206, 0 }, + { 207, 0 }, { 208, 0 }, { 209, 0 }, { 210, 0 }, { 211, 0 }, + { 212, 0 }, { 213, 0 }, { 214, 0 }, { 215, 0 }, { 216, 0 }, + { 217, 0 }, { 218, 0 }, { 219, 0 }, { 220, 0 }, { 221, 0 }, + { 222, 0 }, { 223, 0 }, { 224, 0 }, { 225, 0 }, { 226, 0 }, + { 227, 0 }, { 228, 0 }, { 229, 0 }, { 230, 0 }, { 231, 0 }, + { 232, 0 }, { 233, 0 }, { 234, 0 }, { 235, 0 }, { 236, 0 }, + { 237, 0 }, { 238, 0 }, { 239, 0 }, { 240, 0 }, { 241, 0 }, + + { 242, 0 }, { 243, 0 }, { 244, 0 }, { 245, 0 }, { 246, 0 }, + { 247, 0 }, { 248, 0 }, { 249, 0 }, { 250, 0 }, { 251, 0 }, + { 252, 0 }, { 253, 0 }, { 254, 0 }, { 255, 0 }, { 256, 0 }, + { 0, 22 }, { 0,44064 }, { 1,-258 }, { 2,-258 }, { 3,-258 }, + { 4,-258 }, { 5,-258 }, { 6,-258 }, { 7,-258 }, { 8,-258 }, + { 9, 0 }, { 10,-6696 }, { 11,-258 }, { 12, 0 }, { 13,-6696 }, + { 14,-258 }, { 15,-258 }, { 16,-258 }, { 17,-258 }, { 18,-258 }, + { 19,-258 }, { 20,-258 }, { 21,-258 }, { 22,-258 }, { 23,-258 }, + { 24,-258 }, { 25,-258 }, { 26,-258 }, { 27,-258 }, { 28,-258 }, + { 29,-258 }, { 30,-258 }, { 31,-258 }, { 32, 0 }, { 33,-258 }, + + { 34,-258 }, { 35,-258 }, { 36,-258 }, { 37,-258 }, { 38,-258 }, + { 39,-258 }, { 40,-258 }, { 41,-258 }, { 42,-258 }, { 43,-258 }, + { 44,-258 }, { 45, 258 }, { 46,-258 }, { 47,-258 }, { 48,-258 }, + { 49,-258 }, { 50,-258 }, { 51,-258 }, { 52,-258 }, { 53,-258 }, + { 54,-258 }, { 55,-258 }, { 56,-258 }, { 57,-258 }, { 58,-258 }, + { 59,-258 }, { 60,-258 }, { 61,-258 }, { 62,-258 }, { 63,-258 }, + { 64,-258 }, { 65,-258 }, { 66,-258 }, { 67,-258 }, { 68,-258 }, + { 69,-258 }, { 70,-258 }, { 71,-258 }, { 72,-258 }, { 73,-258 }, + { 74,-258 }, { 75,-258 }, { 76,-258 }, { 77,-258 }, { 78,-258 }, + { 79,-258 }, { 80,-258 }, { 81,-258 }, { 82,-258 }, { 83,-258 }, + + { 84,-258 }, { 85,-258 }, { 86,-258 }, { 87,-258 }, { 88,-258 }, + { 89,-258 }, { 90,-258 }, { 91,-258 }, { 92,-258 }, { 93,-258 }, + { 94,-258 }, { 95,-258 }, { 96,-258 }, { 97,-258 }, { 98,-258 }, + { 99,-258 }, { 100,-258 }, { 101,-258 }, { 102,-258 }, { 103,-258 }, + { 104,-258 }, { 105,-258 }, { 106,-258 }, { 107,-258 }, { 108,-258 }, + { 109,-258 }, { 110,-258 }, { 111,-258 }, { 112,-258 }, { 113,-258 }, + { 114,-258 }, { 115,-258 }, { 116,-258 }, { 117,-258 }, { 118,-258 }, + { 119,-258 }, { 120,-258 }, { 121,-258 }, { 122,-258 }, { 123,-258 }, + { 124,-258 }, { 125,-258 }, { 126,-258 }, { 127,-258 }, { 128,-258 }, + { 129,-258 }, { 130,-258 }, { 131,-258 }, { 132,-258 }, { 133,-258 }, + + { 134,-258 }, { 135,-258 }, { 136,-258 }, { 137,-258 }, { 138,-258 }, + { 139,-258 }, { 140,-258 }, { 141,-258 }, { 142,-258 }, { 143,-258 }, + { 144,-258 }, { 145,-258 }, { 146,-258 }, { 147,-258 }, { 148,-258 }, + { 149,-258 }, { 150,-258 }, { 151,-258 }, { 152,-258 }, { 153,-258 }, + { 154,-258 }, { 155,-258 }, { 156,-258 }, { 157,-258 }, { 158,-258 }, + { 159,-258 }, { 160,-258 }, { 161,-258 }, { 162,-258 }, { 163,-258 }, + { 164,-258 }, { 165,-258 }, { 166,-258 }, { 167,-258 }, { 168,-258 }, + { 169,-258 }, { 170,-258 }, { 171,-258 }, { 172,-258 }, { 173,-258 }, + { 174,-258 }, { 175,-258 }, { 176,-258 }, { 177,-258 }, { 178,-258 }, + { 179,-258 }, { 180,-258 }, { 181,-258 }, { 182,-258 }, { 183,-258 }, + + { 184,-258 }, { 185,-258 }, { 186,-258 }, { 187,-258 }, { 188,-258 }, + { 189,-258 }, { 190,-258 }, { 191,-258 }, { 192,-258 }, { 193,-258 }, + { 194,-258 }, { 195,-258 }, { 196,-258 }, { 197,-258 }, { 198,-258 }, + { 199,-258 }, { 200,-258 }, { 201,-258 }, { 202,-258 }, { 203,-258 }, + { 204,-258 }, { 205,-258 }, { 206,-258 }, { 207,-258 }, { 208,-258 }, + { 209,-258 }, { 210,-258 }, { 211,-258 }, { 212,-258 }, { 213,-258 }, + { 214,-258 }, { 215,-258 }, { 216,-258 }, { 217,-258 }, { 218,-258 }, + { 219,-258 }, { 220,-258 }, { 221,-258 }, { 222,-258 }, { 223,-258 }, + { 224,-258 }, { 225,-258 }, { 226,-258 }, { 227,-258 }, { 228,-258 }, + { 229,-258 }, { 230,-258 }, { 231,-258 }, { 232,-258 }, { 233,-258 }, + + { 234,-258 }, { 235,-258 }, { 236,-258 }, { 237,-258 }, { 238,-258 }, + { 239,-258 }, { 240,-258 }, { 241,-258 }, { 242,-258 }, { 243,-258 }, + { 244,-258 }, { 245,-258 }, { 246,-258 }, { 247,-258 }, { 248,-258 }, + { 249,-258 }, { 250,-258 }, { 251,-258 }, { 252,-258 }, { 253,-258 }, + { 254,-258 }, { 255,-258 }, { 256,-258 }, { 0, 22 }, { 0,43806 }, + { 1,-516 }, { 2,-516 }, { 3,-516 }, { 4,-516 }, { 5,-516 }, + { 6,-516 }, { 7,-516 }, { 8,-516 }, { 9,-258 }, { 10,-6954 }, + { 11,-516 }, { 12,-258 }, { 13,-6954 }, { 14,-516 }, { 15,-516 }, + { 16,-516 }, { 17,-516 }, { 18,-516 }, { 19,-516 }, { 20,-516 }, + { 21,-516 }, { 22,-516 }, { 23,-516 }, { 24,-516 }, { 25,-516 }, + + { 26,-516 }, { 27,-516 }, { 28,-516 }, { 29,-516 }, { 30,-516 }, + { 31,-516 }, { 32,-258 }, { 33,-516 }, { 34,-516 }, { 35,-516 }, + { 36,-516 }, { 37,-516 }, { 38,-516 }, { 39,-516 }, { 40,-516 }, + { 41,-516 }, { 42,-516 }, { 43,-516 }, { 44,-516 }, { 45,5813 }, + { 46,-516 }, { 47,-516 }, { 48,-516 }, { 49,-516 }, { 50,-516 }, + { 51,-516 }, { 52,-516 }, { 53,-516 }, { 54,-516 }, { 55,-516 }, + { 56,-516 }, { 57,-516 }, { 58,-516 }, { 59,-516 }, { 60,-516 }, + { 61,-516 }, { 62,-516 }, { 63,-516 }, { 64,-516 }, { 65,-516 }, + { 66,-516 }, { 67,-516 }, { 68,-516 }, { 69,-516 }, { 70,-516 }, + { 71,-516 }, { 72,-516 }, { 73,-516 }, { 74,-516 }, { 75,-516 }, + + { 76,-516 }, { 77,-516 }, { 78,-516 }, { 79,-516 }, { 80,-516 }, + { 81,-516 }, { 82,-516 }, { 83,-516 }, { 84,-516 }, { 85,-516 }, + { 86,-516 }, { 87,-516 }, { 88,-516 }, { 89,-516 }, { 90,-516 }, + { 91,-516 }, { 92,-516 }, { 93,-516 }, { 94,-516 }, { 95,-516 }, + { 96,-516 }, { 97,-516 }, { 98,-516 }, { 99,-516 }, { 100,-516 }, + { 101,-516 }, { 102,-516 }, { 103,-516 }, { 104,-516 }, { 105,-516 }, + { 106,-516 }, { 107,-516 }, { 108,-516 }, { 109,-516 }, { 110,-516 }, + { 111,-516 }, { 112,-516 }, { 113,-516 }, { 114,-516 }, { 115,-516 }, + { 116,-516 }, { 117,-516 }, { 118,-516 }, { 119,-516 }, { 120,-516 }, + { 121,-516 }, { 122,-516 }, { 123,-516 }, { 124,-516 }, { 125,-516 }, + + { 126,-516 }, { 127,-516 }, { 128,-516 }, { 129,-516 }, { 130,-516 }, + { 131,-516 }, { 132,-516 }, { 133,-516 }, { 134,-516 }, { 135,-516 }, + { 136,-516 }, { 137,-516 }, { 138,-516 }, { 139,-516 }, { 140,-516 }, + { 141,-516 }, { 142,-516 }, { 143,-516 }, { 144,-516 }, { 145,-516 }, + { 146,-516 }, { 147,-516 }, { 148,-516 }, { 149,-516 }, { 150,-516 }, + { 151,-516 }, { 152,-516 }, { 153,-516 }, { 154,-516 }, { 155,-516 }, + { 156,-516 }, { 157,-516 }, { 158,-516 }, { 159,-516 }, { 160,-516 }, + { 161,-516 }, { 162,-516 }, { 163,-516 }, { 164,-516 }, { 165,-516 }, + { 166,-516 }, { 167,-516 }, { 168,-516 }, { 169,-516 }, { 170,-516 }, + { 171,-516 }, { 172,-516 }, { 173,-516 }, { 174,-516 }, { 175,-516 }, + + { 176,-516 }, { 177,-516 }, { 178,-516 }, { 179,-516 }, { 180,-516 }, + { 181,-516 }, { 182,-516 }, { 183,-516 }, { 184,-516 }, { 185,-516 }, + { 186,-516 }, { 187,-516 }, { 188,-516 }, { 189,-516 }, { 190,-516 }, + { 191,-516 }, { 192,-516 }, { 193,-516 }, { 194,-516 }, { 195,-516 }, + { 196,-516 }, { 197,-516 }, { 198,-516 }, { 199,-516 }, { 200,-516 }, + { 201,-516 }, { 202,-516 }, { 203,-516 }, { 204,-516 }, { 205,-516 }, + { 206,-516 }, { 207,-516 }, { 208,-516 }, { 209,-516 }, { 210,-516 }, + { 211,-516 }, { 212,-516 }, { 213,-516 }, { 214,-516 }, { 215,-516 }, + { 216,-516 }, { 217,-516 }, { 218,-516 }, { 219,-516 }, { 220,-516 }, + { 221,-516 }, { 222,-516 }, { 223,-516 }, { 224,-516 }, { 225,-516 }, + + { 226,-516 }, { 227,-516 }, { 228,-516 }, { 229,-516 }, { 230,-516 }, + { 231,-516 }, { 232,-516 }, { 233,-516 }, { 234,-516 }, { 235,-516 }, + { 236,-516 }, { 237,-516 }, { 238,-516 }, { 239,-516 }, { 240,-516 }, + { 241,-516 }, { 242,-516 }, { 243,-516 }, { 244,-516 }, { 245,-516 }, + { 246,-516 }, { 247,-516 }, { 248,-516 }, { 249,-516 }, { 250,-516 }, + { 251,-516 }, { 252,-516 }, { 253,-516 }, { 254,-516 }, { 255,-516 }, + { 256,-516 }, { 0, 33 }, { 0,43548 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 33 }, + { 0,43525 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 48,5813 }, { 49,5813 }, { 50,5813 }, { 51,5813 }, { 52,5813 }, + { 53,5813 }, { 54,5813 }, { 55,5813 }, { 56,5813 }, { 57,5813 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 65,5813 }, { 66,5813 }, { 67,5813 }, + + { 68,5813 }, { 69,5813 }, { 70,5813 }, { 48,5813 }, { 49,5813 }, + { 50,5813 }, { 51,5813 }, { 52,5813 }, { 53,5813 }, { 54,5813 }, + { 55,5813 }, { 56,5813 }, { 57,5813 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 65,5813 }, { 66,5813 }, { 67,5813 }, { 68,5813 }, { 69,5813 }, + { 70,5813 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 97,5813 }, + { 98,5813 }, { 99,5813 }, { 100,5813 }, { 101,5813 }, { 102,5813 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 97,5813 }, { 98,5813 }, { 99,5813 }, + { 100,5813 }, { 101,5813 }, { 102,5813 }, { 0, 48 }, { 0,43421 }, + { 1, 0 }, { 2, 0 }, { 3, 0 }, { 4, 0 }, { 5, 0 }, + { 6, 0 }, { 7, 0 }, { 8, 0 }, { 9, 258 }, { 10,-6386 }, + { 11, 0 }, { 12, 258 }, { 13,-6386 }, { 14, 0 }, { 15, 0 }, + { 16, 0 }, { 17, 0 }, { 18, 0 }, { 19, 0 }, { 20, 0 }, + { 21, 0 }, { 22, 0 }, { 23, 0 }, { 24, 0 }, { 25, 0 }, + { 26, 0 }, { 27, 0 }, { 28, 0 }, { 29, 0 }, { 30, 0 }, + { 31, 0 }, { 32, 258 }, { 33, 0 }, { 34, 0 }, { 35, 0 }, + { 36, 0 }, { 37, 0 }, { 38, 0 }, { 39, 0 }, { 40, 0 }, + + { 41, 0 }, { 42, 0 }, { 43, 0 }, { 44, 0 }, { 45, 516 }, + { 46, 0 }, { 47, 0 }, { 48, 0 }, { 49, 0 }, { 50, 0 }, + { 51, 0 }, { 52, 0 }, { 53, 0 }, { 54, 0 }, { 55, 0 }, + { 56, 0 }, { 57, 0 }, { 58, 0 }, { 59, 0 }, { 60, 0 }, + { 61, 0 }, { 62, 0 }, { 63, 0 }, { 64, 0 }, { 65, 0 }, + { 66, 0 }, { 67, 0 }, { 68, 0 }, { 69, 0 }, { 70, 0 }, + { 71, 0 }, { 72, 0 }, { 73, 0 }, { 74, 0 }, { 75, 0 }, + { 76, 0 }, { 77, 0 }, { 78, 0 }, { 79, 0 }, { 80, 0 }, + { 81, 0 }, { 82, 0 }, { 83, 0 }, { 84, 0 }, { 85, 774 }, + { 86, 0 }, { 87, 0 }, { 88, 0 }, { 89, 0 }, { 90, 0 }, + + { 91, 0 }, { 92, 0 }, { 93, 0 }, { 94, 0 }, { 95, 0 }, + { 96, 0 }, { 97, 0 }, { 98, 0 }, { 99, 0 }, { 100, 0 }, + { 101, 0 }, { 102, 0 }, { 103, 0 }, { 104, 0 }, { 105, 0 }, + { 106, 0 }, { 107, 0 }, { 108, 0 }, { 109, 0 }, { 110, 0 }, + { 111, 0 }, { 112, 0 }, { 113, 0 }, { 114, 0 }, { 115, 0 }, + { 116, 0 }, { 117, 774 }, { 118, 0 }, { 119, 0 }, { 120, 0 }, + { 121, 0 }, { 122, 0 }, { 123, 0 }, { 124, 0 }, { 125, 0 }, + { 126, 0 }, { 127, 0 }, { 128, 0 }, { 129, 0 }, { 130, 0 }, + { 131, 0 }, { 132, 0 }, { 133, 0 }, { 134, 0 }, { 135, 0 }, + { 136, 0 }, { 137, 0 }, { 138, 0 }, { 139, 0 }, { 140, 0 }, + + { 141, 0 }, { 142, 0 }, { 143, 0 }, { 144, 0 }, { 145, 0 }, + { 146, 0 }, { 147, 0 }, { 148, 0 }, { 149, 0 }, { 150, 0 }, + { 151, 0 }, { 152, 0 }, { 153, 0 }, { 154, 0 }, { 155, 0 }, + { 156, 0 }, { 157, 0 }, { 158, 0 }, { 159, 0 }, { 160, 0 }, + { 161, 0 }, { 162, 0 }, { 163, 0 }, { 164, 0 }, { 165, 0 }, + { 166, 0 }, { 167, 0 }, { 168, 0 }, { 169, 0 }, { 170, 0 }, + { 171, 0 }, { 172, 0 }, { 173, 0 }, { 174, 0 }, { 175, 0 }, + { 176, 0 }, { 177, 0 }, { 178, 0 }, { 179, 0 }, { 180, 0 }, + { 181, 0 }, { 182, 0 }, { 183, 0 }, { 184, 0 }, { 185, 0 }, + { 186, 0 }, { 187, 0 }, { 188, 0 }, { 189, 0 }, { 190, 0 }, + + { 191, 0 }, { 192, 0 }, { 193, 0 }, { 194, 0 }, { 195, 0 }, + { 196, 0 }, { 197, 0 }, { 198, 0 }, { 199, 0 }, { 200, 0 }, + { 201, 0 }, { 202, 0 }, { 203, 0 }, { 204, 0 }, { 205, 0 }, + { 206, 0 }, { 207, 0 }, { 208, 0 }, { 209, 0 }, { 210, 0 }, + { 211, 0 }, { 212, 0 }, { 213, 0 }, { 214, 0 }, { 215, 0 }, + { 216, 0 }, { 217, 0 }, { 218, 0 }, { 219, 0 }, { 220, 0 }, + { 221, 0 }, { 222, 0 }, { 223, 0 }, { 224, 0 }, { 225, 0 }, + { 226, 0 }, { 227, 0 }, { 228, 0 }, { 229, 0 }, { 230, 0 }, + { 231, 0 }, { 232, 0 }, { 233, 0 }, { 234, 0 }, { 235, 0 }, + { 236, 0 }, { 237, 0 }, { 238, 0 }, { 239, 0 }, { 240, 0 }, + + { 241, 0 }, { 242, 0 }, { 243, 0 }, { 244, 0 }, { 245, 0 }, + { 246, 0 }, { 247, 0 }, { 248, 0 }, { 249, 0 }, { 250, 0 }, + { 251, 0 }, { 252, 0 }, { 253, 0 }, { 254, 0 }, { 255, 0 }, + { 256, 0 }, { 0, 48 }, { 0,43163 }, { 1,-258 }, { 2,-258 }, + { 3,-258 }, { 4,-258 }, { 5,-258 }, { 6,-258 }, { 7,-258 }, + { 8,-258 }, { 9, 0 }, { 10,-6644 }, { 11,-258 }, { 12, 0 }, + { 13,-6644 }, { 14,-258 }, { 15,-258 }, { 16,-258 }, { 17,-258 }, + { 18,-258 }, { 19,-258 }, { 20,-258 }, { 21,-258 }, { 22,-258 }, + { 23,-258 }, { 24,-258 }, { 25,-258 }, { 26,-258 }, { 27,-258 }, + { 28,-258 }, { 29,-258 }, { 30,-258 }, { 31,-258 }, { 32, 0 }, + + { 33,-258 }, { 34,-258 }, { 35,-258 }, { 36,-258 }, { 37,-258 }, + { 38,-258 }, { 39,-258 }, { 40,-258 }, { 41,-258 }, { 42,-258 }, + { 43,-258 }, { 44,-258 }, { 45, 258 }, { 46,-258 }, { 47,-258 }, + { 48,-258 }, { 49,-258 }, { 50,-258 }, { 51,-258 }, { 52,-258 }, + { 53,-258 }, { 54,-258 }, { 55,-258 }, { 56,-258 }, { 57,-258 }, + { 58,-258 }, { 59,-258 }, { 60,-258 }, { 61,-258 }, { 62,-258 }, + { 63,-258 }, { 64,-258 }, { 65,-258 }, { 66,-258 }, { 67,-258 }, + { 68,-258 }, { 69,-258 }, { 70,-258 }, { 71,-258 }, { 72,-258 }, + { 73,-258 }, { 74,-258 }, { 75,-258 }, { 76,-258 }, { 77,-258 }, + { 78,-258 }, { 79,-258 }, { 80,-258 }, { 81,-258 }, { 82,-258 }, + + { 83,-258 }, { 84,-258 }, { 85, 516 }, { 86,-258 }, { 87,-258 }, + { 88,-258 }, { 89,-258 }, { 90,-258 }, { 91,-258 }, { 92,-258 }, + { 93,-258 }, { 94,-258 }, { 95,-258 }, { 96,-258 }, { 97,-258 }, + { 98,-258 }, { 99,-258 }, { 100,-258 }, { 101,-258 }, { 102,-258 }, + { 103,-258 }, { 104,-258 }, { 105,-258 }, { 106,-258 }, { 107,-258 }, + { 108,-258 }, { 109,-258 }, { 110,-258 }, { 111,-258 }, { 112,-258 }, + { 113,-258 }, { 114,-258 }, { 115,-258 }, { 116,-258 }, { 117, 516 }, + { 118,-258 }, { 119,-258 }, { 120,-258 }, { 121,-258 }, { 122,-258 }, + { 123,-258 }, { 124,-258 }, { 125,-258 }, { 126,-258 }, { 127,-258 }, + { 128,-258 }, { 129,-258 }, { 130,-258 }, { 131,-258 }, { 132,-258 }, + + { 133,-258 }, { 134,-258 }, { 135,-258 }, { 136,-258 }, { 137,-258 }, + { 138,-258 }, { 139,-258 }, { 140,-258 }, { 141,-258 }, { 142,-258 }, + { 143,-258 }, { 144,-258 }, { 145,-258 }, { 146,-258 }, { 147,-258 }, + { 148,-258 }, { 149,-258 }, { 150,-258 }, { 151,-258 }, { 152,-258 }, + { 153,-258 }, { 154,-258 }, { 155,-258 }, { 156,-258 }, { 157,-258 }, + { 158,-258 }, { 159,-258 }, { 160,-258 }, { 161,-258 }, { 162,-258 }, + { 163,-258 }, { 164,-258 }, { 165,-258 }, { 166,-258 }, { 167,-258 }, + { 168,-258 }, { 169,-258 }, { 170,-258 }, { 171,-258 }, { 172,-258 }, + { 173,-258 }, { 174,-258 }, { 175,-258 }, { 176,-258 }, { 177,-258 }, + { 178,-258 }, { 179,-258 }, { 180,-258 }, { 181,-258 }, { 182,-258 }, + + { 183,-258 }, { 184,-258 }, { 185,-258 }, { 186,-258 }, { 187,-258 }, + { 188,-258 }, { 189,-258 }, { 190,-258 }, { 191,-258 }, { 192,-258 }, + { 193,-258 }, { 194,-258 }, { 195,-258 }, { 196,-258 }, { 197,-258 }, + { 198,-258 }, { 199,-258 }, { 200,-258 }, { 201,-258 }, { 202,-258 }, + { 203,-258 }, { 204,-258 }, { 205,-258 }, { 206,-258 }, { 207,-258 }, + { 208,-258 }, { 209,-258 }, { 210,-258 }, { 211,-258 }, { 212,-258 }, + { 213,-258 }, { 214,-258 }, { 215,-258 }, { 216,-258 }, { 217,-258 }, + { 218,-258 }, { 219,-258 }, { 220,-258 }, { 221,-258 }, { 222,-258 }, + { 223,-258 }, { 224,-258 }, { 225,-258 }, { 226,-258 }, { 227,-258 }, + { 228,-258 }, { 229,-258 }, { 230,-258 }, { 231,-258 }, { 232,-258 }, + + { 233,-258 }, { 234,-258 }, { 235,-258 }, { 236,-258 }, { 237,-258 }, + { 238,-258 }, { 239,-258 }, { 240,-258 }, { 241,-258 }, { 242,-258 }, + { 243,-258 }, { 244,-258 }, { 245,-258 }, { 246,-258 }, { 247,-258 }, + { 248,-258 }, { 249,-258 }, { 250,-258 }, { 251,-258 }, { 252,-258 }, + { 253,-258 }, { 254,-258 }, { 255,-258 }, { 256,-258 }, { 0, 48 }, + { 0,42905 }, { 1,-516 }, { 2,-516 }, { 3,-516 }, { 4,-516 }, + { 5,-516 }, { 6,-516 }, { 7,-516 }, { 8,-516 }, { 9,-258 }, + { 10,-6902 }, { 11,-516 }, { 12,-258 }, { 13,-6902 }, { 14,-516 }, + { 15,-516 }, { 16,-516 }, { 17,-516 }, { 18,-516 }, { 19,-516 }, + { 20,-516 }, { 21,-516 }, { 22,-516 }, { 23,-516 }, { 24,-516 }, + + { 25,-516 }, { 26,-516 }, { 27,-516 }, { 28,-516 }, { 29,-516 }, + { 30,-516 }, { 31,-516 }, { 32,-258 }, { 33,-516 }, { 34,-516 }, + { 35,-516 }, { 36,-516 }, { 37,-516 }, { 38,-516 }, { 39,-516 }, + { 40,-516 }, { 41,-516 }, { 42,-516 }, { 43,-516 }, { 44,-516 }, + { 45,5297 }, { 46,-516 }, { 47,-516 }, { 48,-516 }, { 49,-516 }, + { 50,-516 }, { 51,-516 }, { 52,-516 }, { 53,-516 }, { 54,-516 }, + { 55,-516 }, { 56,-516 }, { 57,-516 }, { 58,-516 }, { 59,-516 }, + { 60,-516 }, { 61,-516 }, { 62,-516 }, { 63,-516 }, { 64,-516 }, + { 65,-516 }, { 66,-516 }, { 67,-516 }, { 68,-516 }, { 69,-516 }, + { 70,-516 }, { 71,-516 }, { 72,-516 }, { 73,-516 }, { 74,-516 }, + + { 75,-516 }, { 76,-516 }, { 77,-516 }, { 78,-516 }, { 79,-516 }, + { 80,-516 }, { 81,-516 }, { 82,-516 }, { 83,-516 }, { 84,-516 }, + { 85, 258 }, { 86,-516 }, { 87,-516 }, { 88,-516 }, { 89,-516 }, + { 90,-516 }, { 91,-516 }, { 92,-516 }, { 93,-516 }, { 94,-516 }, + { 95,-516 }, { 96,-516 }, { 97,-516 }, { 98,-516 }, { 99,-516 }, + { 100,-516 }, { 101,-516 }, { 102,-516 }, { 103,-516 }, { 104,-516 }, + { 105,-516 }, { 106,-516 }, { 107,-516 }, { 108,-516 }, { 109,-516 }, + { 110,-516 }, { 111,-516 }, { 112,-516 }, { 113,-516 }, { 114,-516 }, + { 115,-516 }, { 116,-516 }, { 117, 258 }, { 118,-516 }, { 119,-516 }, + { 120,-516 }, { 121,-516 }, { 122,-516 }, { 123,-516 }, { 124,-516 }, + + { 125,-516 }, { 126,-516 }, { 127,-516 }, { 128,-516 }, { 129,-516 }, + { 130,-516 }, { 131,-516 }, { 132,-516 }, { 133,-516 }, { 134,-516 }, + { 135,-516 }, { 136,-516 }, { 137,-516 }, { 138,-516 }, { 139,-516 }, + { 140,-516 }, { 141,-516 }, { 142,-516 }, { 143,-516 }, { 144,-516 }, + { 145,-516 }, { 146,-516 }, { 147,-516 }, { 148,-516 }, { 149,-516 }, + { 150,-516 }, { 151,-516 }, { 152,-516 }, { 153,-516 }, { 154,-516 }, + { 155,-516 }, { 156,-516 }, { 157,-516 }, { 158,-516 }, { 159,-516 }, + { 160,-516 }, { 161,-516 }, { 162,-516 }, { 163,-516 }, { 164,-516 }, + { 165,-516 }, { 166,-516 }, { 167,-516 }, { 168,-516 }, { 169,-516 }, + { 170,-516 }, { 171,-516 }, { 172,-516 }, { 173,-516 }, { 174,-516 }, + + { 175,-516 }, { 176,-516 }, { 177,-516 }, { 178,-516 }, { 179,-516 }, + { 180,-516 }, { 181,-516 }, { 182,-516 }, { 183,-516 }, { 184,-516 }, + { 185,-516 }, { 186,-516 }, { 187,-516 }, { 188,-516 }, { 189,-516 }, + { 190,-516 }, { 191,-516 }, { 192,-516 }, { 193,-516 }, { 194,-516 }, + { 195,-516 }, { 196,-516 }, { 197,-516 }, { 198,-516 }, { 199,-516 }, + { 200,-516 }, { 201,-516 }, { 202,-516 }, { 203,-516 }, { 204,-516 }, + { 205,-516 }, { 206,-516 }, { 207,-516 }, { 208,-516 }, { 209,-516 }, + { 210,-516 }, { 211,-516 }, { 212,-516 }, { 213,-516 }, { 214,-516 }, + { 215,-516 }, { 216,-516 }, { 217,-516 }, { 218,-516 }, { 219,-516 }, + { 220,-516 }, { 221,-516 }, { 222,-516 }, { 223,-516 }, { 224,-516 }, + + { 225,-516 }, { 226,-516 }, { 227,-516 }, { 228,-516 }, { 229,-516 }, + { 230,-516 }, { 231,-516 }, { 232,-516 }, { 233,-516 }, { 234,-516 }, + { 235,-516 }, { 236,-516 }, { 237,-516 }, { 238,-516 }, { 239,-516 }, + { 240,-516 }, { 241,-516 }, { 242,-516 }, { 243,-516 }, { 244,-516 }, + { 245,-516 }, { 246,-516 }, { 247,-516 }, { 248,-516 }, { 249,-516 }, + { 250,-516 }, { 251,-516 }, { 252,-516 }, { 253,-516 }, { 254,-516 }, + { 255,-516 }, { 256,-516 }, { 0, 48 }, { 0,42647 }, { 1,-774 }, + { 2,-774 }, { 3,-774 }, { 4,-774 }, { 5,-774 }, { 6,-774 }, + { 7,-774 }, { 8,-774 }, { 9,-516 }, { 10,-7160 }, { 11,-774 }, + { 12,-516 }, { 13,-7160 }, { 14,-774 }, { 15,-774 }, { 16,-774 }, + + { 17,-774 }, { 18,-774 }, { 19,-774 }, { 20,-774 }, { 21,-774 }, + { 22,-774 }, { 23,-774 }, { 24,-774 }, { 25,-774 }, { 26,-774 }, + { 27,-774 }, { 28,-774 }, { 29,-774 }, { 30,-774 }, { 31,-774 }, + { 32,-516 }, { 33,-774 }, { 34,-774 }, { 35,-774 }, { 36,-774 }, + { 37,-774 }, { 38,-774 }, { 39,-774 }, { 40,-774 }, { 41,-774 }, + { 42,-774 }, { 43,-774 }, { 44,-774 }, { 45,-258 }, { 46,-774 }, + { 47,-774 }, { 48,-774 }, { 49,-774 }, { 50,-774 }, { 51,-774 }, + { 52,-774 }, { 53,-774 }, { 54,-774 }, { 55,-774 }, { 56,-774 }, + { 57,-774 }, { 58,-774 }, { 59,-774 }, { 60,-774 }, { 61,-774 }, + { 62,-774 }, { 63,-774 }, { 64,-774 }, { 65,-774 }, { 66,-774 }, + + { 67,-774 }, { 68,-774 }, { 69,5297 }, { 70,-774 }, { 71,-774 }, + { 72,-774 }, { 73,-774 }, { 74,-774 }, { 75,-774 }, { 76,-774 }, + { 77,-774 }, { 78,-774 }, { 79,-774 }, { 80,-774 }, { 81,-774 }, + { 82,-774 }, { 83,-774 }, { 84,-774 }, { 85, 0 }, { 86,-774 }, + { 87,-774 }, { 88,-774 }, { 89,-774 }, { 90,-774 }, { 91,-774 }, + { 92,-774 }, { 93,-774 }, { 94,-774 }, { 95,-774 }, { 96,-774 }, + { 97,-774 }, { 98,-774 }, { 99,-774 }, { 100,-774 }, { 101,5297 }, + { 102,-774 }, { 103,-774 }, { 104,-774 }, { 105,-774 }, { 106,-774 }, + { 107,-774 }, { 108,-774 }, { 109,-774 }, { 110,-774 }, { 111,-774 }, + { 112,-774 }, { 113,-774 }, { 114,-774 }, { 115,-774 }, { 116,-774 }, + + { 117, 0 }, { 118,-774 }, { 119,-774 }, { 120,-774 }, { 121,-774 }, + { 122,-774 }, { 123,-774 }, { 124,-774 }, { 125,-774 }, { 126,-774 }, + { 127,-774 }, { 128,-774 }, { 129,-774 }, { 130,-774 }, { 131,-774 }, + { 132,-774 }, { 133,-774 }, { 134,-774 }, { 135,-774 }, { 136,-774 }, + { 137,-774 }, { 138,-774 }, { 139,-774 }, { 140,-774 }, { 141,-774 }, + { 142,-774 }, { 143,-774 }, { 144,-774 }, { 145,-774 }, { 146,-774 }, + { 147,-774 }, { 148,-774 }, { 149,-774 }, { 150,-774 }, { 151,-774 }, + { 152,-774 }, { 153,-774 }, { 154,-774 }, { 155,-774 }, { 156,-774 }, + { 157,-774 }, { 158,-774 }, { 159,-774 }, { 160,-774 }, { 161,-774 }, + { 162,-774 }, { 163,-774 }, { 164,-774 }, { 165,-774 }, { 166,-774 }, + + { 167,-774 }, { 168,-774 }, { 169,-774 }, { 170,-774 }, { 171,-774 }, + { 172,-774 }, { 173,-774 }, { 174,-774 }, { 175,-774 }, { 176,-774 }, + { 177,-774 }, { 178,-774 }, { 179,-774 }, { 180,-774 }, { 181,-774 }, + { 182,-774 }, { 183,-774 }, { 184,-774 }, { 185,-774 }, { 186,-774 }, + { 187,-774 }, { 188,-774 }, { 189,-774 }, { 190,-774 }, { 191,-774 }, + { 192,-774 }, { 193,-774 }, { 194,-774 }, { 195,-774 }, { 196,-774 }, + { 197,-774 }, { 198,-774 }, { 199,-774 }, { 200,-774 }, { 201,-774 }, + { 202,-774 }, { 203,-774 }, { 204,-774 }, { 205,-774 }, { 206,-774 }, + { 207,-774 }, { 208,-774 }, { 209,-774 }, { 210,-774 }, { 211,-774 }, + { 212,-774 }, { 213,-774 }, { 214,-774 }, { 215,-774 }, { 216,-774 }, + + { 217,-774 }, { 218,-774 }, { 219,-774 }, { 220,-774 }, { 221,-774 }, + { 222,-774 }, { 223,-774 }, { 224,-774 }, { 225,-774 }, { 226,-774 }, + { 227,-774 }, { 228,-774 }, { 229,-774 }, { 230,-774 }, { 231,-774 }, + { 232,-774 }, { 233,-774 }, { 234,-774 }, { 235,-774 }, { 236,-774 }, + { 237,-774 }, { 238,-774 }, { 239,-774 }, { 240,-774 }, { 241,-774 }, + { 242,-774 }, { 243,-774 }, { 244,-774 }, { 245,-774 }, { 246,-774 }, + { 247,-774 }, { 248,-774 }, { 249,-774 }, { 250,-774 }, { 251,-774 }, + { 252,-774 }, { 253,-774 }, { 254,-774 }, { 255,-774 }, { 256,-774 }, + { 0, 24 }, { 0,42389 }, { 1,5297 }, { 2,5297 }, { 3,5297 }, + { 4,5297 }, { 5,5297 }, { 6,5297 }, { 7,5297 }, { 8,5297 }, + + { 9,5555 }, { 10,5813 }, { 11,5297 }, { 12,5555 }, { 13,5813 }, + { 14,5297 }, { 15,5297 }, { 16,5297 }, { 17,5297 }, { 18,5297 }, + { 19,5297 }, { 20,5297 }, { 21,5297 }, { 22,5297 }, { 23,5297 }, + { 24,5297 }, { 25,5297 }, { 26,5297 }, { 27,5297 }, { 28,5297 }, + { 29,5297 }, { 30,5297 }, { 31,5297 }, { 32,5555 }, { 33,5297 }, + { 34,5297 }, { 35,5297 }, { 36,5297 }, { 37,5297 }, { 38,5297 }, + { 39,5297 }, { 40,5297 }, { 41,5297 }, { 42,5297 }, { 43,5297 }, + { 44,5297 }, { 45,5932 }, { 46,5297 }, { 47,5297 }, { 48,5297 }, + { 49,5297 }, { 50,5297 }, { 51,5297 }, { 52,5297 }, { 53,5297 }, + { 54,5297 }, { 55,5297 }, { 56,5297 }, { 57,5297 }, { 58,5297 }, + + { 59,5297 }, { 60,5297 }, { 61,5297 }, { 62,5297 }, { 63,5297 }, + { 64,5297 }, { 65,5297 }, { 66,5297 }, { 67,5297 }, { 68,5297 }, + { 69,5297 }, { 70,5297 }, { 71,5297 }, { 72,5297 }, { 73,5297 }, + { 74,5297 }, { 75,5297 }, { 76,5297 }, { 77,5297 }, { 78,5297 }, + { 79,5297 }, { 80,5297 }, { 81,5297 }, { 82,5297 }, { 83,5297 }, + { 84,5297 }, { 85,6190 }, { 86,5297 }, { 87,5297 }, { 88,5297 }, + { 89,5297 }, { 90,5297 }, { 91,5297 }, { 92,5297 }, { 93,5297 }, + { 94,5297 }, { 95,5297 }, { 96,5297 }, { 97,5297 }, { 98,5297 }, + { 99,5297 }, { 100,5297 }, { 101,5297 }, { 102,5297 }, { 103,5297 }, + { 104,5297 }, { 105,5297 }, { 106,5297 }, { 107,5297 }, { 108,5297 }, + + { 109,5297 }, { 110,5297 }, { 111,5297 }, { 112,5297 }, { 113,5297 }, + { 114,5297 }, { 115,5297 }, { 116,5297 }, { 117,6190 }, { 118,5297 }, + { 119,5297 }, { 120,5297 }, { 121,5297 }, { 122,5297 }, { 123,5297 }, + { 124,5297 }, { 125,5297 }, { 126,5297 }, { 127,5297 }, { 128,5297 }, + { 129,5297 }, { 130,5297 }, { 131,5297 }, { 132,5297 }, { 133,5297 }, + { 134,5297 }, { 135,5297 }, { 136,5297 }, { 137,5297 }, { 138,5297 }, + { 139,5297 }, { 140,5297 }, { 141,5297 }, { 142,5297 }, { 143,5297 }, + { 144,5297 }, { 145,5297 }, { 146,5297 }, { 147,5297 }, { 148,5297 }, + { 149,5297 }, { 150,5297 }, { 151,5297 }, { 152,5297 }, { 153,5297 }, + { 154,5297 }, { 155,5297 }, { 156,5297 }, { 157,5297 }, { 158,5297 }, + + { 159,5297 }, { 160,5297 }, { 161,5297 }, { 162,5297 }, { 163,5297 }, + { 164,5297 }, { 165,5297 }, { 166,5297 }, { 167,5297 }, { 168,5297 }, + { 169,5297 }, { 170,5297 }, { 171,5297 }, { 172,5297 }, { 173,5297 }, + { 174,5297 }, { 175,5297 }, { 176,5297 }, { 177,5297 }, { 178,5297 }, + { 179,5297 }, { 180,5297 }, { 181,5297 }, { 182,5297 }, { 183,5297 }, + { 184,5297 }, { 185,5297 }, { 186,5297 }, { 187,5297 }, { 188,5297 }, + { 189,5297 }, { 190,5297 }, { 191,5297 }, { 192,5297 }, { 193,5297 }, + { 194,5297 }, { 195,5297 }, { 196,5297 }, { 197,5297 }, { 198,5297 }, + { 199,5297 }, { 200,5297 }, { 201,5297 }, { 202,5297 }, { 203,5297 }, + { 204,5297 }, { 205,5297 }, { 206,5297 }, { 207,5297 }, { 208,5297 }, + + { 209,5297 }, { 210,5297 }, { 211,5297 }, { 212,5297 }, { 213,5297 }, + { 214,5297 }, { 215,5297 }, { 216,5297 }, { 217,5297 }, { 218,5297 }, + { 219,5297 }, { 220,5297 }, { 221,5297 }, { 222,5297 }, { 223,5297 }, + { 224,5297 }, { 225,5297 }, { 226,5297 }, { 227,5297 }, { 228,5297 }, + { 229,5297 }, { 230,5297 }, { 231,5297 }, { 232,5297 }, { 233,5297 }, + { 234,5297 }, { 235,5297 }, { 236,5297 }, { 237,5297 }, { 238,5297 }, + { 239,5297 }, { 240,5297 }, { 241,5297 }, { 242,5297 }, { 243,5297 }, + { 244,5297 }, { 245,5297 }, { 246,5297 }, { 247,5297 }, { 248,5297 }, + { 249,5297 }, { 250,5297 }, { 251,5297 }, { 252,5297 }, { 253,5297 }, + { 254,5297 }, { 255,5297 }, { 256,5297 }, { 0, 24 }, { 0,42131 }, + + { 1, 0 }, { 2, 0 }, { 3, 0 }, { 4, 0 }, { 5, 0 }, + { 6, 0 }, { 7, 0 }, { 8, 0 }, { 9, 258 }, { 10,-7655 }, + { 11, 0 }, { 12, 258 }, { 13,-7655 }, { 14, 0 }, { 15, 0 }, + { 16, 0 }, { 17, 0 }, { 18, 0 }, { 19, 0 }, { 20, 0 }, + { 21, 0 }, { 22, 0 }, { 23, 0 }, { 24, 0 }, { 25, 0 }, + { 26, 0 }, { 27, 0 }, { 28, 0 }, { 29, 0 }, { 30, 0 }, + { 31, 0 }, { 32, 258 }, { 33, 0 }, { 34, 0 }, { 35, 0 }, + { 36, 0 }, { 37, 0 }, { 38, 0 }, { 39, 0 }, { 40, 0 }, + { 41, 0 }, { 42, 0 }, { 43, 0 }, { 44, 0 }, { 45, 516 }, + { 46, 0 }, { 47, 0 }, { 48, 0 }, { 49, 0 }, { 50, 0 }, + + { 51, 0 }, { 52, 0 }, { 53, 0 }, { 54, 0 }, { 55, 0 }, + { 56, 0 }, { 57, 0 }, { 58, 0 }, { 59, 0 }, { 60, 0 }, + { 61, 0 }, { 62, 0 }, { 63, 0 }, { 64, 0 }, { 65, 0 }, + { 66, 0 }, { 67, 0 }, { 68, 0 }, { 69, 0 }, { 70, 0 }, + { 71, 0 }, { 72, 0 }, { 73, 0 }, { 74, 0 }, { 75, 0 }, + { 76, 0 }, { 77, 0 }, { 78, 0 }, { 79, 0 }, { 80, 0 }, + { 81, 0 }, { 82, 0 }, { 83, 0 }, { 84, 0 }, { 85, 774 }, + { 86, 0 }, { 87, 0 }, { 88, 0 }, { 89, 0 }, { 90, 0 }, + { 91, 0 }, { 92, 0 }, { 93, 0 }, { 94, 0 }, { 95, 0 }, + { 96, 0 }, { 97, 0 }, { 98, 0 }, { 99, 0 }, { 100, 0 }, + + { 101, 0 }, { 102, 0 }, { 103, 0 }, { 104, 0 }, { 105, 0 }, + { 106, 0 }, { 107, 0 }, { 108, 0 }, { 109, 0 }, { 110, 0 }, + { 111, 0 }, { 112, 0 }, { 113, 0 }, { 114, 0 }, { 115, 0 }, + { 116, 0 }, { 117, 774 }, { 118, 0 }, { 119, 0 }, { 120, 0 }, + { 121, 0 }, { 122, 0 }, { 123, 0 }, { 124, 0 }, { 125, 0 }, + { 126, 0 }, { 127, 0 }, { 128, 0 }, { 129, 0 }, { 130, 0 }, + { 131, 0 }, { 132, 0 }, { 133, 0 }, { 134, 0 }, { 135, 0 }, + { 136, 0 }, { 137, 0 }, { 138, 0 }, { 139, 0 }, { 140, 0 }, + { 141, 0 }, { 142, 0 }, { 143, 0 }, { 144, 0 }, { 145, 0 }, + { 146, 0 }, { 147, 0 }, { 148, 0 }, { 149, 0 }, { 150, 0 }, + + { 151, 0 }, { 152, 0 }, { 153, 0 }, { 154, 0 }, { 155, 0 }, + { 156, 0 }, { 157, 0 }, { 158, 0 }, { 159, 0 }, { 160, 0 }, + { 161, 0 }, { 162, 0 }, { 163, 0 }, { 164, 0 }, { 165, 0 }, + { 166, 0 }, { 167, 0 }, { 168, 0 }, { 169, 0 }, { 170, 0 }, + { 171, 0 }, { 172, 0 }, { 173, 0 }, { 174, 0 }, { 175, 0 }, + { 176, 0 }, { 177, 0 }, { 178, 0 }, { 179, 0 }, { 180, 0 }, + { 181, 0 }, { 182, 0 }, { 183, 0 }, { 184, 0 }, { 185, 0 }, + { 186, 0 }, { 187, 0 }, { 188, 0 }, { 189, 0 }, { 190, 0 }, + { 191, 0 }, { 192, 0 }, { 193, 0 }, { 194, 0 }, { 195, 0 }, + { 196, 0 }, { 197, 0 }, { 198, 0 }, { 199, 0 }, { 200, 0 }, + + { 201, 0 }, { 202, 0 }, { 203, 0 }, { 204, 0 }, { 205, 0 }, + { 206, 0 }, { 207, 0 }, { 208, 0 }, { 209, 0 }, { 210, 0 }, + { 211, 0 }, { 212, 0 }, { 213, 0 }, { 214, 0 }, { 215, 0 }, + { 216, 0 }, { 217, 0 }, { 218, 0 }, { 219, 0 }, { 220, 0 }, + { 221, 0 }, { 222, 0 }, { 223, 0 }, { 224, 0 }, { 225, 0 }, + { 226, 0 }, { 227, 0 }, { 228, 0 }, { 229, 0 }, { 230, 0 }, + { 231, 0 }, { 232, 0 }, { 233, 0 }, { 234, 0 }, { 235, 0 }, + { 236, 0 }, { 237, 0 }, { 238, 0 }, { 239, 0 }, { 240, 0 }, + { 241, 0 }, { 242, 0 }, { 243, 0 }, { 244, 0 }, { 245, 0 }, + { 246, 0 }, { 247, 0 }, { 248, 0 }, { 249, 0 }, { 250, 0 }, + + { 251, 0 }, { 252, 0 }, { 253, 0 }, { 254, 0 }, { 255, 0 }, + { 256, 0 }, { 0, 24 }, { 0,41873 }, { 1,-258 }, { 2,-258 }, + { 3,-258 }, { 4,-258 }, { 5,-258 }, { 6,-258 }, { 7,-258 }, + { 8,-258 }, { 9, 0 }, { 10,-7913 }, { 11,-258 }, { 12, 0 }, + { 13,-7913 }, { 14,-258 }, { 15,-258 }, { 16,-258 }, { 17,-258 }, + { 18,-258 }, { 19,-258 }, { 20,-258 }, { 21,-258 }, { 22,-258 }, + { 23,-258 }, { 24,-258 }, { 25,-258 }, { 26,-258 }, { 27,-258 }, + { 28,-258 }, { 29,-258 }, { 30,-258 }, { 31,-258 }, { 32, 0 }, + { 33,-258 }, { 34,-258 }, { 35,-258 }, { 36,-258 }, { 37,-258 }, + { 38,-258 }, { 39,-258 }, { 40,-258 }, { 41,-258 }, { 42,-258 }, + + { 43,-258 }, { 44,-258 }, { 45, 258 }, { 46,-258 }, { 47,-258 }, + { 48,-258 }, { 49,-258 }, { 50,-258 }, { 51,-258 }, { 52,-258 }, + { 53,-258 }, { 54,-258 }, { 55,-258 }, { 56,-258 }, { 57,-258 }, + { 58,-258 }, { 59,-258 }, { 60,-258 }, { 61,-258 }, { 62,-258 }, + { 63,-258 }, { 64,-258 }, { 65,-258 }, { 66,-258 }, { 67,-258 }, + { 68,-258 }, { 69,-258 }, { 70,-258 }, { 71,-258 }, { 72,-258 }, + { 73,-258 }, { 74,-258 }, { 75,-258 }, { 76,-258 }, { 77,-258 }, + { 78,-258 }, { 79,-258 }, { 80,-258 }, { 81,-258 }, { 82,-258 }, + { 83,-258 }, { 84,-258 }, { 85, 516 }, { 86,-258 }, { 87,-258 }, + { 88,-258 }, { 89,-258 }, { 90,-258 }, { 91,-258 }, { 92,-258 }, + + { 93,-258 }, { 94,-258 }, { 95,-258 }, { 96,-258 }, { 97,-258 }, + { 98,-258 }, { 99,-258 }, { 100,-258 }, { 101,-258 }, { 102,-258 }, + { 103,-258 }, { 104,-258 }, { 105,-258 }, { 106,-258 }, { 107,-258 }, + { 108,-258 }, { 109,-258 }, { 110,-258 }, { 111,-258 }, { 112,-258 }, + { 113,-258 }, { 114,-258 }, { 115,-258 }, { 116,-258 }, { 117, 516 }, + { 118,-258 }, { 119,-258 }, { 120,-258 }, { 121,-258 }, { 122,-258 }, + { 123,-258 }, { 124,-258 }, { 125,-258 }, { 126,-258 }, { 127,-258 }, + { 128,-258 }, { 129,-258 }, { 130,-258 }, { 131,-258 }, { 132,-258 }, + { 133,-258 }, { 134,-258 }, { 135,-258 }, { 136,-258 }, { 137,-258 }, + { 138,-258 }, { 139,-258 }, { 140,-258 }, { 141,-258 }, { 142,-258 }, + + { 143,-258 }, { 144,-258 }, { 145,-258 }, { 146,-258 }, { 147,-258 }, + { 148,-258 }, { 149,-258 }, { 150,-258 }, { 151,-258 }, { 152,-258 }, + { 153,-258 }, { 154,-258 }, { 155,-258 }, { 156,-258 }, { 157,-258 }, + { 158,-258 }, { 159,-258 }, { 160,-258 }, { 161,-258 }, { 162,-258 }, + { 163,-258 }, { 164,-258 }, { 165,-258 }, { 166,-258 }, { 167,-258 }, + { 168,-258 }, { 169,-258 }, { 170,-258 }, { 171,-258 }, { 172,-258 }, + { 173,-258 }, { 174,-258 }, { 175,-258 }, { 176,-258 }, { 177,-258 }, + { 178,-258 }, { 179,-258 }, { 180,-258 }, { 181,-258 }, { 182,-258 }, + { 183,-258 }, { 184,-258 }, { 185,-258 }, { 186,-258 }, { 187,-258 }, + { 188,-258 }, { 189,-258 }, { 190,-258 }, { 191,-258 }, { 192,-258 }, + + { 193,-258 }, { 194,-258 }, { 195,-258 }, { 196,-258 }, { 197,-258 }, + { 198,-258 }, { 199,-258 }, { 200,-258 }, { 201,-258 }, { 202,-258 }, + { 203,-258 }, { 204,-258 }, { 205,-258 }, { 206,-258 }, { 207,-258 }, + { 208,-258 }, { 209,-258 }, { 210,-258 }, { 211,-258 }, { 212,-258 }, + { 213,-258 }, { 214,-258 }, { 215,-258 }, { 216,-258 }, { 217,-258 }, + { 218,-258 }, { 219,-258 }, { 220,-258 }, { 221,-258 }, { 222,-258 }, + { 223,-258 }, { 224,-258 }, { 225,-258 }, { 226,-258 }, { 227,-258 }, + { 228,-258 }, { 229,-258 }, { 230,-258 }, { 231,-258 }, { 232,-258 }, + { 233,-258 }, { 234,-258 }, { 235,-258 }, { 236,-258 }, { 237,-258 }, + { 238,-258 }, { 239,-258 }, { 240,-258 }, { 241,-258 }, { 242,-258 }, + + { 243,-258 }, { 244,-258 }, { 245,-258 }, { 246,-258 }, { 247,-258 }, + { 248,-258 }, { 249,-258 }, { 250,-258 }, { 251,-258 }, { 252,-258 }, + { 253,-258 }, { 254,-258 }, { 255,-258 }, { 256,-258 }, { 0, 24 }, + { 0,41615 }, { 1,-516 }, { 2,-516 }, { 3,-516 }, { 4,-516 }, + { 5,-516 }, { 6,-516 }, { 7,-516 }, { 8,-516 }, { 9,-258 }, + { 10,-8171 }, { 11,-516 }, { 12,-258 }, { 13,-8171 }, { 14,-516 }, + { 15,-516 }, { 16,-516 }, { 17,-516 }, { 18,-516 }, { 19,-516 }, + { 20,-516 }, { 21,-516 }, { 22,-516 }, { 23,-516 }, { 24,-516 }, + { 25,-516 }, { 26,-516 }, { 27,-516 }, { 28,-516 }, { 29,-516 }, + { 30,-516 }, { 31,-516 }, { 32,-258 }, { 33,-516 }, { 34,-516 }, + + { 35,-516 }, { 36,-516 }, { 37,-516 }, { 38,-516 }, { 39,-516 }, + { 40,-516 }, { 41,-516 }, { 42,-516 }, { 43,-516 }, { 44,-516 }, + { 45,5674 }, { 46,-516 }, { 47,-516 }, { 48,-516 }, { 49,-516 }, + { 50,-516 }, { 51,-516 }, { 52,-516 }, { 53,-516 }, { 54,-516 }, + { 55,-516 }, { 56,-516 }, { 57,-516 }, { 58,-516 }, { 59,-516 }, + { 60,-516 }, { 61,-516 }, { 62,-516 }, { 63,-516 }, { 64,-516 }, + { 65,-516 }, { 66,-516 }, { 67,-516 }, { 68,-516 }, { 69,-516 }, + { 70,-516 }, { 71,-516 }, { 72,-516 }, { 73,-516 }, { 74,-516 }, + { 75,-516 }, { 76,-516 }, { 77,-516 }, { 78,-516 }, { 79,-516 }, + { 80,-516 }, { 81,-516 }, { 82,-516 }, { 83,-516 }, { 84,-516 }, + + { 85, 258 }, { 86,-516 }, { 87,-516 }, { 88,-516 }, { 89,-516 }, + { 90,-516 }, { 91,-516 }, { 92,-516 }, { 93,-516 }, { 94,-516 }, + { 95,-516 }, { 96,-516 }, { 97,-516 }, { 98,-516 }, { 99,-516 }, + { 100,-516 }, { 101,-516 }, { 102,-516 }, { 103,-516 }, { 104,-516 }, + { 105,-516 }, { 106,-516 }, { 107,-516 }, { 108,-516 }, { 109,-516 }, + { 110,-516 }, { 111,-516 }, { 112,-516 }, { 113,-516 }, { 114,-516 }, + { 115,-516 }, { 116,-516 }, { 117, 258 }, { 118,-516 }, { 119,-516 }, + { 120,-516 }, { 121,-516 }, { 122,-516 }, { 123,-516 }, { 124,-516 }, + { 125,-516 }, { 126,-516 }, { 127,-516 }, { 128,-516 }, { 129,-516 }, + { 130,-516 }, { 131,-516 }, { 132,-516 }, { 133,-516 }, { 134,-516 }, + + { 135,-516 }, { 136,-516 }, { 137,-516 }, { 138,-516 }, { 139,-516 }, + { 140,-516 }, { 141,-516 }, { 142,-516 }, { 143,-516 }, { 144,-516 }, + { 145,-516 }, { 146,-516 }, { 147,-516 }, { 148,-516 }, { 149,-516 }, + { 150,-516 }, { 151,-516 }, { 152,-516 }, { 153,-516 }, { 154,-516 }, + { 155,-516 }, { 156,-516 }, { 157,-516 }, { 158,-516 }, { 159,-516 }, + { 160,-516 }, { 161,-516 }, { 162,-516 }, { 163,-516 }, { 164,-516 }, + { 165,-516 }, { 166,-516 }, { 167,-516 }, { 168,-516 }, { 169,-516 }, + { 170,-516 }, { 171,-516 }, { 172,-516 }, { 173,-516 }, { 174,-516 }, + { 175,-516 }, { 176,-516 }, { 177,-516 }, { 178,-516 }, { 179,-516 }, + { 180,-516 }, { 181,-516 }, { 182,-516 }, { 183,-516 }, { 184,-516 }, + + { 185,-516 }, { 186,-516 }, { 187,-516 }, { 188,-516 }, { 189,-516 }, + { 190,-516 }, { 191,-516 }, { 192,-516 }, { 193,-516 }, { 194,-516 }, + { 195,-516 }, { 196,-516 }, { 197,-516 }, { 198,-516 }, { 199,-516 }, + { 200,-516 }, { 201,-516 }, { 202,-516 }, { 203,-516 }, { 204,-516 }, + { 205,-516 }, { 206,-516 }, { 207,-516 }, { 208,-516 }, { 209,-516 }, + { 210,-516 }, { 211,-516 }, { 212,-516 }, { 213,-516 }, { 214,-516 }, + { 215,-516 }, { 216,-516 }, { 217,-516 }, { 218,-516 }, { 219,-516 }, + { 220,-516 }, { 221,-516 }, { 222,-516 }, { 223,-516 }, { 224,-516 }, + { 225,-516 }, { 226,-516 }, { 227,-516 }, { 228,-516 }, { 229,-516 }, + { 230,-516 }, { 231,-516 }, { 232,-516 }, { 233,-516 }, { 234,-516 }, + + { 235,-516 }, { 236,-516 }, { 237,-516 }, { 238,-516 }, { 239,-516 }, + { 240,-516 }, { 241,-516 }, { 242,-516 }, { 243,-516 }, { 244,-516 }, + { 245,-516 }, { 246,-516 }, { 247,-516 }, { 248,-516 }, { 249,-516 }, + { 250,-516 }, { 251,-516 }, { 252,-516 }, { 253,-516 }, { 254,-516 }, + { 255,-516 }, { 256,-516 }, { 0, 24 }, { 0,41357 }, { 1,-774 }, + { 2,-774 }, { 3,-774 }, { 4,-774 }, { 5,-774 }, { 6,-774 }, + { 7,-774 }, { 8,-774 }, { 9,-516 }, { 10,-8429 }, { 11,-774 }, + { 12,-516 }, { 13,-8429 }, { 14,-774 }, { 15,-774 }, { 16,-774 }, + { 17,-774 }, { 18,-774 }, { 19,-774 }, { 20,-774 }, { 21,-774 }, + { 22,-774 }, { 23,-774 }, { 24,-774 }, { 25,-774 }, { 26,-774 }, + + { 27,-774 }, { 28,-774 }, { 29,-774 }, { 30,-774 }, { 31,-774 }, + { 32,-516 }, { 33,-774 }, { 34,-774 }, { 35,-774 }, { 36,-774 }, + { 37,-774 }, { 38,-774 }, { 39,-774 }, { 40,-774 }, { 41,-774 }, + { 42,-774 }, { 43,-774 }, { 44,-774 }, { 45,-258 }, { 46,-774 }, + { 47,-774 }, { 48,-774 }, { 49,-774 }, { 50,-774 }, { 51,-774 }, + { 52,-774 }, { 53,-774 }, { 54,-774 }, { 55,-774 }, { 56,-774 }, + { 57,-774 }, { 58,-774 }, { 59,-774 }, { 60,-774 }, { 61,-774 }, + { 62,-774 }, { 63,-774 }, { 64,-774 }, { 65,-774 }, { 66,-774 }, + { 67,-774 }, { 68,-774 }, { 69,5674 }, { 70,-774 }, { 71,-774 }, + { 72,-774 }, { 73,-774 }, { 74,-774 }, { 75,-774 }, { 76,-774 }, + + { 77,-774 }, { 78,-774 }, { 79,-774 }, { 80,-774 }, { 81,-774 }, + { 82,-774 }, { 83,-774 }, { 84,-774 }, { 85, 0 }, { 86,-774 }, + { 87,-774 }, { 88,-774 }, { 89,-774 }, { 90,-774 }, { 91,-774 }, + { 92,-774 }, { 93,-774 }, { 94,-774 }, { 95,-774 }, { 96,-774 }, + { 97,-774 }, { 98,-774 }, { 99,-774 }, { 100,-774 }, { 101,5674 }, + { 102,-774 }, { 103,-774 }, { 104,-774 }, { 105,-774 }, { 106,-774 }, + { 107,-774 }, { 108,-774 }, { 109,-774 }, { 110,-774 }, { 111,-774 }, + { 112,-774 }, { 113,-774 }, { 114,-774 }, { 115,-774 }, { 116,-774 }, + { 117, 0 }, { 118,-774 }, { 119,-774 }, { 120,-774 }, { 121,-774 }, + { 122,-774 }, { 123,-774 }, { 124,-774 }, { 125,-774 }, { 126,-774 }, + + { 127,-774 }, { 128,-774 }, { 129,-774 }, { 130,-774 }, { 131,-774 }, + { 132,-774 }, { 133,-774 }, { 134,-774 }, { 135,-774 }, { 136,-774 }, + { 137,-774 }, { 138,-774 }, { 139,-774 }, { 140,-774 }, { 141,-774 }, + { 142,-774 }, { 143,-774 }, { 144,-774 }, { 145,-774 }, { 146,-774 }, + { 147,-774 }, { 148,-774 }, { 149,-774 }, { 150,-774 }, { 151,-774 }, + { 152,-774 }, { 153,-774 }, { 154,-774 }, { 155,-774 }, { 156,-774 }, + { 157,-774 }, { 158,-774 }, { 159,-774 }, { 160,-774 }, { 161,-774 }, + { 162,-774 }, { 163,-774 }, { 164,-774 }, { 165,-774 }, { 166,-774 }, + { 167,-774 }, { 168,-774 }, { 169,-774 }, { 170,-774 }, { 171,-774 }, + { 172,-774 }, { 173,-774 }, { 174,-774 }, { 175,-774 }, { 176,-774 }, + + { 177,-774 }, { 178,-774 }, { 179,-774 }, { 180,-774 }, { 181,-774 }, + { 182,-774 }, { 183,-774 }, { 184,-774 }, { 185,-774 }, { 186,-774 }, + { 187,-774 }, { 188,-774 }, { 189,-774 }, { 190,-774 }, { 191,-774 }, + { 192,-774 }, { 193,-774 }, { 194,-774 }, { 195,-774 }, { 196,-774 }, + { 197,-774 }, { 198,-774 }, { 199,-774 }, { 200,-774 }, { 201,-774 }, + { 202,-774 }, { 203,-774 }, { 204,-774 }, { 205,-774 }, { 206,-774 }, + { 207,-774 }, { 208,-774 }, { 209,-774 }, { 210,-774 }, { 211,-774 }, + { 212,-774 }, { 213,-774 }, { 214,-774 }, { 215,-774 }, { 216,-774 }, + { 217,-774 }, { 218,-774 }, { 219,-774 }, { 220,-774 }, { 221,-774 }, + { 222,-774 }, { 223,-774 }, { 224,-774 }, { 225,-774 }, { 226,-774 }, + + { 227,-774 }, { 228,-774 }, { 229,-774 }, { 230,-774 }, { 231,-774 }, + { 232,-774 }, { 233,-774 }, { 234,-774 }, { 235,-774 }, { 236,-774 }, + { 237,-774 }, { 238,-774 }, { 239,-774 }, { 240,-774 }, { 241,-774 }, + { 242,-774 }, { 243,-774 }, { 244,-774 }, { 245,-774 }, { 246,-774 }, + { 247,-774 }, { 248,-774 }, { 249,-774 }, { 250,-774 }, { 251,-774 }, + { 252,-774 }, { 253,-774 }, { 254,-774 }, { 255,-774 }, { 256,-774 }, + { 0, 33 }, { 0,41099 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 33 }, { 0,41076 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 48,5674 }, + { 49,5674 }, { 50,5674 }, { 51,5674 }, { 52,5674 }, { 53,5674 }, + { 54,5674 }, { 55,5674 }, { 56,5674 }, { 57,5674 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 65,5674 }, { 66,5674 }, { 67,5674 }, { 68,5674 }, + + { 69,5674 }, { 70,5674 }, { 48,5674 }, { 49,5674 }, { 50,5674 }, + { 51,5674 }, { 52,5674 }, { 53,5674 }, { 54,5674 }, { 55,5674 }, + { 56,5674 }, { 57,5674 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 65,5674 }, + { 66,5674 }, { 67,5674 }, { 68,5674 }, { 69,5674 }, { 70,5674 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 97,5674 }, { 98,5674 }, + { 99,5674 }, { 100,5674 }, { 101,5674 }, { 102,5674 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 97,5674 }, { 98,5674 }, { 99,5674 }, { 100,5674 }, + { 101,5674 }, { 102,5674 }, { 0, 9 }, { 0,40972 }, { 1, 0 }, + { 2, 0 }, { 3, 0 }, { 4, 0 }, { 5, 0 }, { 6, 0 }, + { 7, 0 }, { 8, 0 }, { 9, 258 }, { 10, 516 }, { 11, 0 }, + { 12, 258 }, { 13, 516 }, { 14, 0 }, { 15, 0 }, { 16, 0 }, + { 17, 0 }, { 18, 0 }, { 19, 0 }, { 20, 0 }, { 21, 0 }, + { 22, 0 }, { 23, 0 }, { 24, 0 }, { 25, 0 }, { 26, 0 }, + { 27, 0 }, { 28, 0 }, { 29, 0 }, { 30, 0 }, { 31, 0 }, + { 32, 258 }, { 33, 0 }, { 34, 0 }, { 35, 0 }, { 36, 0 }, + { 37, 0 }, { 38, 0 }, { 39, 0 }, { 40, 0 }, { 41, 0 }, + + { 42, 0 }, { 43, 0 }, { 44, 0 }, { 45, 563 }, { 46, 0 }, + { 47, 0 }, { 48, 0 }, { 49, 0 }, { 50, 0 }, { 51, 0 }, + { 52, 0 }, { 53, 0 }, { 54, 0 }, { 55, 0 }, { 56, 0 }, + { 57, 0 }, { 58, 0 }, { 59, 0 }, { 60, 0 }, { 61, 0 }, + { 62, 0 }, { 63, 0 }, { 64, 0 }, { 65, 0 }, { 66, 0 }, + { 67, 0 }, { 68, 0 }, { 69, 0 }, { 70, 0 }, { 71, 0 }, + { 72, 0 }, { 73, 0 }, { 74, 0 }, { 75, 0 }, { 76, 0 }, + { 77, 0 }, { 78, 0 }, { 79, 0 }, { 80, 0 }, { 81, 0 }, + { 82, 0 }, { 83, 0 }, { 84, 0 }, { 85, 0 }, { 86, 0 }, + { 87, 0 }, { 88, 0 }, { 89, 0 }, { 90, 0 }, { 91, 0 }, + + { 92, 0 }, { 93, 0 }, { 94, 0 }, { 95, 0 }, { 96, 0 }, + { 97, 0 }, { 98, 0 }, { 99, 0 }, { 100, 0 }, { 101, 0 }, + { 102, 0 }, { 103, 0 }, { 104, 0 }, { 105, 0 }, { 106, 0 }, + { 107, 0 }, { 108, 0 }, { 109, 0 }, { 110, 0 }, { 111, 0 }, + { 112, 0 }, { 113, 0 }, { 114, 0 }, { 115, 0 }, { 116, 0 }, + { 117, 0 }, { 118, 0 }, { 119, 0 }, { 120, 0 }, { 121, 0 }, + { 122, 0 }, { 123, 0 }, { 124, 0 }, { 125, 0 }, { 126, 0 }, + { 127, 0 }, { 128, 0 }, { 129, 0 }, { 130, 0 }, { 131, 0 }, + { 132, 0 }, { 133, 0 }, { 134, 0 }, { 135, 0 }, { 136, 0 }, + { 137, 0 }, { 138, 0 }, { 139, 0 }, { 140, 0 }, { 141, 0 }, + + { 142, 0 }, { 143, 0 }, { 144, 0 }, { 145, 0 }, { 146, 0 }, + { 147, 0 }, { 148, 0 }, { 149, 0 }, { 150, 0 }, { 151, 0 }, + { 152, 0 }, { 153, 0 }, { 154, 0 }, { 155, 0 }, { 156, 0 }, + { 157, 0 }, { 158, 0 }, { 159, 0 }, { 160, 0 }, { 161, 0 }, + { 162, 0 }, { 163, 0 }, { 164, 0 }, { 165, 0 }, { 166, 0 }, + { 167, 0 }, { 168, 0 }, { 169, 0 }, { 170, 0 }, { 171, 0 }, + { 172, 0 }, { 173, 0 }, { 174, 0 }, { 175, 0 }, { 176, 0 }, + { 177, 0 }, { 178, 0 }, { 179, 0 }, { 180, 0 }, { 181, 0 }, + { 182, 0 }, { 183, 0 }, { 184, 0 }, { 185, 0 }, { 186, 0 }, + { 187, 0 }, { 188, 0 }, { 189, 0 }, { 190, 0 }, { 191, 0 }, + + { 192, 0 }, { 193, 0 }, { 194, 0 }, { 195, 0 }, { 196, 0 }, + { 197, 0 }, { 198, 0 }, { 199, 0 }, { 200, 0 }, { 201, 0 }, + { 202, 0 }, { 203, 0 }, { 204, 0 }, { 205, 0 }, { 206, 0 }, + { 207, 0 }, { 208, 0 }, { 209, 0 }, { 210, 0 }, { 211, 0 }, + { 212, 0 }, { 213, 0 }, { 214, 0 }, { 215, 0 }, { 216, 0 }, + { 217, 0 }, { 218, 0 }, { 219, 0 }, { 220, 0 }, { 221, 0 }, + { 222, 0 }, { 223, 0 }, { 224, 0 }, { 225, 0 }, { 226, 0 }, + { 227, 0 }, { 228, 0 }, { 229, 0 }, { 230, 0 }, { 231, 0 }, + { 232, 0 }, { 233, 0 }, { 234, 0 }, { 235, 0 }, { 236, 0 }, + { 237, 0 }, { 238, 0 }, { 239, 0 }, { 240, 0 }, { 241, 0 }, + + { 242, 0 }, { 243, 0 }, { 244, 0 }, { 245, 0 }, { 246, 0 }, + { 247, 0 }, { 248, 0 }, { 249, 0 }, { 250, 0 }, { 251, 0 }, + { 252, 0 }, { 253, 0 }, { 254, 0 }, { 255, 0 }, { 256, 0 }, + { 0, 9 }, { 0,40714 }, { 1,-258 }, { 2,-258 }, { 3,-258 }, + { 4,-258 }, { 5,-258 }, { 6,-258 }, { 7,-258 }, { 8,-258 }, + { 9, 0 }, { 10, 258 }, { 11,-258 }, { 12, 0 }, { 13, 258 }, + { 14,-258 }, { 15,-258 }, { 16,-258 }, { 17,-258 }, { 18,-258 }, + { 19,-258 }, { 20,-258 }, { 21,-258 }, { 22,-258 }, { 23,-258 }, + { 24,-258 }, { 25,-258 }, { 26,-258 }, { 27,-258 }, { 28,-258 }, + { 29,-258 }, { 30,-258 }, { 31,-258 }, { 32, 0 }, { 33,-258 }, + + { 34,-258 }, { 35,-258 }, { 36,-258 }, { 37,-258 }, { 38,-258 }, + { 39,-258 }, { 40,-258 }, { 41,-258 }, { 42,-258 }, { 43,-258 }, + { 44,-258 }, { 45, 305 }, { 46,-258 }, { 47,-258 }, { 48,-258 }, + { 49,-258 }, { 50,-258 }, { 51,-258 }, { 52,-258 }, { 53,-258 }, + { 54,-258 }, { 55,-258 }, { 56,-258 }, { 57,-258 }, { 58,-258 }, + { 59,-258 }, { 60,-258 }, { 61,-258 }, { 62,-258 }, { 63,-258 }, + { 64,-258 }, { 65,-258 }, { 66,-258 }, { 67,-258 }, { 68,-258 }, + { 69,-258 }, { 70,-258 }, { 71,-258 }, { 72,-258 }, { 73,-258 }, + { 74,-258 }, { 75,-258 }, { 76,-258 }, { 77,-258 }, { 78,-258 }, + { 79,-258 }, { 80,-258 }, { 81,-258 }, { 82,-258 }, { 83,-258 }, + + { 84,-258 }, { 85,-258 }, { 86,-258 }, { 87,-258 }, { 88,-258 }, + { 89,-258 }, { 90,-258 }, { 91,-258 }, { 92,-258 }, { 93,-258 }, + { 94,-258 }, { 95,-258 }, { 96,-258 }, { 97,-258 }, { 98,-258 }, + { 99,-258 }, { 100,-258 }, { 101,-258 }, { 102,-258 }, { 103,-258 }, + { 104,-258 }, { 105,-258 }, { 106,-258 }, { 107,-258 }, { 108,-258 }, + { 109,-258 }, { 110,-258 }, { 111,-258 }, { 112,-258 }, { 113,-258 }, + { 114,-258 }, { 115,-258 }, { 116,-258 }, { 117,-258 }, { 118,-258 }, + { 119,-258 }, { 120,-258 }, { 121,-258 }, { 122,-258 }, { 123,-258 }, + { 124,-258 }, { 125,-258 }, { 126,-258 }, { 127,-258 }, { 128,-258 }, + { 129,-258 }, { 130,-258 }, { 131,-258 }, { 132,-258 }, { 133,-258 }, + + { 134,-258 }, { 135,-258 }, { 136,-258 }, { 137,-258 }, { 138,-258 }, + { 139,-258 }, { 140,-258 }, { 141,-258 }, { 142,-258 }, { 143,-258 }, + { 144,-258 }, { 145,-258 }, { 146,-258 }, { 147,-258 }, { 148,-258 }, + { 149,-258 }, { 150,-258 }, { 151,-258 }, { 152,-258 }, { 153,-258 }, + { 154,-258 }, { 155,-258 }, { 156,-258 }, { 157,-258 }, { 158,-258 }, + { 159,-258 }, { 160,-258 }, { 161,-258 }, { 162,-258 }, { 163,-258 }, + { 164,-258 }, { 165,-258 }, { 166,-258 }, { 167,-258 }, { 168,-258 }, + { 169,-258 }, { 170,-258 }, { 171,-258 }, { 172,-258 }, { 173,-258 }, + { 174,-258 }, { 175,-258 }, { 176,-258 }, { 177,-258 }, { 178,-258 }, + { 179,-258 }, { 180,-258 }, { 181,-258 }, { 182,-258 }, { 183,-258 }, + + { 184,-258 }, { 185,-258 }, { 186,-258 }, { 187,-258 }, { 188,-258 }, + { 189,-258 }, { 190,-258 }, { 191,-258 }, { 192,-258 }, { 193,-258 }, + { 194,-258 }, { 195,-258 }, { 196,-258 }, { 197,-258 }, { 198,-258 }, + { 199,-258 }, { 200,-258 }, { 201,-258 }, { 202,-258 }, { 203,-258 }, + { 204,-258 }, { 205,-258 }, { 206,-258 }, { 207,-258 }, { 208,-258 }, + { 209,-258 }, { 210,-258 }, { 211,-258 }, { 212,-258 }, { 213,-258 }, + { 214,-258 }, { 215,-258 }, { 216,-258 }, { 217,-258 }, { 218,-258 }, + { 219,-258 }, { 220,-258 }, { 221,-258 }, { 222,-258 }, { 223,-258 }, + { 224,-258 }, { 225,-258 }, { 226,-258 }, { 227,-258 }, { 228,-258 }, + { 229,-258 }, { 230,-258 }, { 231,-258 }, { 232,-258 }, { 233,-258 }, + + { 234,-258 }, { 235,-258 }, { 236,-258 }, { 237,-258 }, { 238,-258 }, + { 239,-258 }, { 240,-258 }, { 241,-258 }, { 242,-258 }, { 243,-258 }, + { 244,-258 }, { 245,-258 }, { 246,-258 }, { 247,-258 }, { 248,-258 }, + { 249,-258 }, { 250,-258 }, { 251,-258 }, { 252,-258 }, { 253,-258 }, + { 254,-258 }, { 255,-258 }, { 256,-258 }, { 0, 9 }, { 0,40456 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 9,-8344 }, { 10,-8344 }, + { 0, 0 }, { 12,-8344 }, { 13,-8344 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 32,-8344 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 39,-17136 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 45,-17119 }, + { 0, 9 }, { 0,40409 }, { 1,-563 }, { 2,-563 }, { 3,-563 }, + { 4,-563 }, { 5,-563 }, { 6,-563 }, { 7,-563 }, { 8,-563 }, + { 9,-305 }, { 10, -47 }, { 11,-563 }, { 12,-305 }, { 13, -47 }, + { 14,-563 }, { 15,-563 }, { 16,-563 }, { 17,-563 }, { 18,-563 }, + { 19,-563 }, { 20,-563 }, { 21,-563 }, { 22,-563 }, { 23,-563 }, + { 24,-563 }, { 25,-563 }, { 26,-563 }, { 27,-563 }, { 28,-563 }, + + { 29,-563 }, { 30,-563 }, { 31,-563 }, { 32,-305 }, { 33,-563 }, + { 34,-563 }, { 35,-563 }, { 36,-563 }, { 37,-563 }, { 38,-563 }, + { 39,-563 }, { 40,-563 }, { 41,-563 }, { 42,-563 }, { 43,-563 }, + { 44,-563 }, { 45,5111 }, { 46,-563 }, { 47,-563 }, { 48,-563 }, + { 49,-563 }, { 50,-563 }, { 51,-563 }, { 52,-563 }, { 53,-563 }, + { 54,-563 }, { 55,-563 }, { 56,-563 }, { 57,-563 }, { 58,-563 }, + { 59,-563 }, { 60,-563 }, { 61,-563 }, { 62,-563 }, { 63,-563 }, + { 64,-563 }, { 65,-563 }, { 66,-563 }, { 67,-563 }, { 68,-563 }, + { 69,-563 }, { 70,-563 }, { 71,-563 }, { 72,-563 }, { 73,-563 }, + { 74,-563 }, { 75,-563 }, { 76,-563 }, { 77,-563 }, { 78,-563 }, + + { 79,-563 }, { 80,-563 }, { 81,-563 }, { 82,-563 }, { 83,-563 }, + { 84,-563 }, { 85,-563 }, { 86,-563 }, { 87,-563 }, { 88,-563 }, + { 89,-563 }, { 90,-563 }, { 91,-563 }, { 92,-563 }, { 93,-563 }, + { 94,-563 }, { 95,-563 }, { 96,-563 }, { 97,-563 }, { 98,-563 }, + { 99,-563 }, { 100,-563 }, { 101,-563 }, { 102,-563 }, { 103,-563 }, + { 104,-563 }, { 105,-563 }, { 106,-563 }, { 107,-563 }, { 108,-563 }, + { 109,-563 }, { 110,-563 }, { 111,-563 }, { 112,-563 }, { 113,-563 }, + { 114,-563 }, { 115,-563 }, { 116,-563 }, { 117,-563 }, { 118,-563 }, + { 119,-563 }, { 120,-563 }, { 121,-563 }, { 122,-563 }, { 123,-563 }, + { 124,-563 }, { 125,-563 }, { 126,-563 }, { 127,-563 }, { 128,-563 }, + + { 129,-563 }, { 130,-563 }, { 131,-563 }, { 132,-563 }, { 133,-563 }, + { 134,-563 }, { 135,-563 }, { 136,-563 }, { 137,-563 }, { 138,-563 }, + { 139,-563 }, { 140,-563 }, { 141,-563 }, { 142,-563 }, { 143,-563 }, + { 144,-563 }, { 145,-563 }, { 146,-563 }, { 147,-563 }, { 148,-563 }, + { 149,-563 }, { 150,-563 }, { 151,-563 }, { 152,-563 }, { 153,-563 }, + { 154,-563 }, { 155,-563 }, { 156,-563 }, { 157,-563 }, { 158,-563 }, + { 159,-563 }, { 160,-563 }, { 161,-563 }, { 162,-563 }, { 163,-563 }, + { 164,-563 }, { 165,-563 }, { 166,-563 }, { 167,-563 }, { 168,-563 }, + { 169,-563 }, { 170,-563 }, { 171,-563 }, { 172,-563 }, { 173,-563 }, + { 174,-563 }, { 175,-563 }, { 176,-563 }, { 177,-563 }, { 178,-563 }, + + { 179,-563 }, { 180,-563 }, { 181,-563 }, { 182,-563 }, { 183,-563 }, + { 184,-563 }, { 185,-563 }, { 186,-563 }, { 187,-563 }, { 188,-563 }, + { 189,-563 }, { 190,-563 }, { 191,-563 }, { 192,-563 }, { 193,-563 }, + { 194,-563 }, { 195,-563 }, { 196,-563 }, { 197,-563 }, { 198,-563 }, + { 199,-563 }, { 200,-563 }, { 201,-563 }, { 202,-563 }, { 203,-563 }, + { 204,-563 }, { 205,-563 }, { 206,-563 }, { 207,-563 }, { 208,-563 }, + { 209,-563 }, { 210,-563 }, { 211,-563 }, { 212,-563 }, { 213,-563 }, + { 214,-563 }, { 215,-563 }, { 216,-563 }, { 217,-563 }, { 218,-563 }, + { 219,-563 }, { 220,-563 }, { 221,-563 }, { 222,-563 }, { 223,-563 }, + { 224,-563 }, { 225,-563 }, { 226,-563 }, { 227,-563 }, { 228,-563 }, + + { 229,-563 }, { 230,-563 }, { 231,-563 }, { 232,-563 }, { 233,-563 }, + { 234,-563 }, { 235,-563 }, { 236,-563 }, { 237,-563 }, { 238,-563 }, + { 239,-563 }, { 240,-563 }, { 241,-563 }, { 242,-563 }, { 243,-563 }, + { 244,-563 }, { 245,-563 }, { 246,-563 }, { 247,-563 }, { 248,-563 }, + { 249,-563 }, { 250,-563 }, { 251,-563 }, { 252,-563 }, { 253,-563 }, + { 254,-563 }, { 255,-563 }, { 256,-563 }, { 0, 9 }, { 0,40151 }, + { 1,-6235 }, { 2,-6235 }, { 3,-6235 }, { 4,-6235 }, { 5,-6235 }, + { 6,-6235 }, { 7,-6235 }, { 8,-6235 }, { 9,-5977 }, { 10,-11873 }, + { 11,-6235 }, { 12,-5977 }, { 13,-11873 }, { 14,-6235 }, { 15,-6235 }, + { 16,-6235 }, { 17,-6235 }, { 18,-6235 }, { 19,-6235 }, { 20,-6235 }, + + { 21,-6235 }, { 22,-6235 }, { 23,-6235 }, { 24,-6235 }, { 25,-6235 }, + { 26,-6235 }, { 27,-6235 }, { 28,-6235 }, { 29,-6235 }, { 30,-6235 }, + { 31,-6235 }, { 32,-5977 }, { 33,-6235 }, { 34,-6235 }, { 35,-6235 }, + { 36,-6235 }, { 37,-6235 }, { 38,-6235 }, { 39,-6235 }, { 40,-6235 }, + { 41,-6235 }, { 42,-6235 }, { 43,-6235 }, { 44,-6235 }, { 45, 0 }, + { 46,-6235 }, { 47,-6235 }, { 48,-6235 }, { 49,-6235 }, { 50,-6235 }, + { 51,-6235 }, { 52,-6235 }, { 53,-6235 }, { 54,-6235 }, { 55,-6235 }, + { 56,-6235 }, { 57,-6235 }, { 58,-6235 }, { 59,-6235 }, { 60,-6235 }, + { 61,-6235 }, { 62,-6235 }, { 63,-6235 }, { 64,-6235 }, { 65,-6235 }, + { 66,-6235 }, { 67,-6235 }, { 68,-6235 }, { 69,-6235 }, { 70,-6235 }, + + { 71,-6235 }, { 72,-6235 }, { 73,-6235 }, { 74,-6235 }, { 75,-6235 }, + { 76,-6235 }, { 77,-6235 }, { 78,-6235 }, { 79,-6235 }, { 80,-6235 }, + { 81,-6235 }, { 82,-6235 }, { 83,-6235 }, { 84,-6235 }, { 85,-6235 }, + { 86,-6235 }, { 87,-6235 }, { 88,-6235 }, { 89,-6235 }, { 90,-6235 }, + { 91,-6235 }, { 92,-6235 }, { 93,-6235 }, { 94,-6235 }, { 95,-6235 }, + { 96,-6235 }, { 97,-6235 }, { 98,-6235 }, { 99,-6235 }, { 100,-6235 }, + { 101,-6235 }, { 102,-6235 }, { 103,-6235 }, { 104,-6235 }, { 105,-6235 }, + { 106,-6235 }, { 107,-6235 }, { 108,-6235 }, { 109,-6235 }, { 110,-6235 }, + { 111,-6235 }, { 112,-6235 }, { 113,-6235 }, { 114,-6235 }, { 115,-6235 }, + { 116,-6235 }, { 117,-6235 }, { 118,-6235 }, { 119,-6235 }, { 120,-6235 }, + + { 121,-6235 }, { 122,-6235 }, { 123,-6235 }, { 124,-6235 }, { 125,-6235 }, + { 126,-6235 }, { 127,-6235 }, { 128,-6235 }, { 129,-6235 }, { 130,-6235 }, + { 131,-6235 }, { 132,-6235 }, { 133,-6235 }, { 134,-6235 }, { 135,-6235 }, + { 136,-6235 }, { 137,-6235 }, { 138,-6235 }, { 139,-6235 }, { 140,-6235 }, + { 141,-6235 }, { 142,-6235 }, { 143,-6235 }, { 144,-6235 }, { 145,-6235 }, + { 146,-6235 }, { 147,-6235 }, { 148,-6235 }, { 149,-6235 }, { 150,-6235 }, + { 151,-6235 }, { 152,-6235 }, { 153,-6235 }, { 154,-6235 }, { 155,-6235 }, + { 156,-6235 }, { 157,-6235 }, { 158,-6235 }, { 159,-6235 }, { 160,-6235 }, + { 161,-6235 }, { 162,-6235 }, { 163,-6235 }, { 164,-6235 }, { 165,-6235 }, + { 166,-6235 }, { 167,-6235 }, { 168,-6235 }, { 169,-6235 }, { 170,-6235 }, + + { 171,-6235 }, { 172,-6235 }, { 173,-6235 }, { 174,-6235 }, { 175,-6235 }, + { 176,-6235 }, { 177,-6235 }, { 178,-6235 }, { 179,-6235 }, { 180,-6235 }, + { 181,-6235 }, { 182,-6235 }, { 183,-6235 }, { 184,-6235 }, { 185,-6235 }, + { 186,-6235 }, { 187,-6235 }, { 188,-6235 }, { 189,-6235 }, { 190,-6235 }, + { 191,-6235 }, { 192,-6235 }, { 193,-6235 }, { 194,-6235 }, { 195,-6235 }, + { 196,-6235 }, { 197,-6235 }, { 198,-6235 }, { 199,-6235 }, { 200,-6235 }, + { 201,-6235 }, { 202,-6235 }, { 203,-6235 }, { 204,-6235 }, { 205,-6235 }, + { 206,-6235 }, { 207,-6235 }, { 208,-6235 }, { 209,-6235 }, { 210,-6235 }, + { 211,-6235 }, { 212,-6235 }, { 213,-6235 }, { 214,-6235 }, { 215,-6235 }, + { 216,-6235 }, { 217,-6235 }, { 218,-6235 }, { 219,-6235 }, { 220,-6235 }, + + { 221,-6235 }, { 222,-6235 }, { 223,-6235 }, { 224,-6235 }, { 225,-6235 }, + { 226,-6235 }, { 227,-6235 }, { 228,-6235 }, { 229,-6235 }, { 230,-6235 }, + { 231,-6235 }, { 232,-6235 }, { 233,-6235 }, { 234,-6235 }, { 235,-6235 }, + { 236,-6235 }, { 237,-6235 }, { 238,-6235 }, { 239,-6235 }, { 240,-6235 }, + { 241,-6235 }, { 242,-6235 }, { 243,-6235 }, { 244,-6235 }, { 245,-6235 }, + { 246,-6235 }, { 247,-6235 }, { 248,-6235 }, { 249,-6235 }, { 250,-6235 }, + { 251,-6235 }, { 252,-6235 }, { 253,-6235 }, { 254,-6235 }, { 255,-6235 }, + { 256,-6235 }, { 0, 16 }, { 0,39893 }, { 1, 0 }, { 2, 0 }, + { 3, 0 }, { 4, 0 }, { 5, 0 }, { 6, 0 }, { 7, 0 }, + { 8, 0 }, { 9, 258 }, { 10, 516 }, { 11, 0 }, { 12, 258 }, + + { 13, 516 }, { 14, 0 }, { 15, 0 }, { 16, 0 }, { 17, 0 }, + { 18, 0 }, { 19, 0 }, { 20, 0 }, { 21, 0 }, { 22, 0 }, + { 23, 0 }, { 24, 0 }, { 25, 0 }, { 26, 0 }, { 27, 0 }, + { 28, 0 }, { 29, 0 }, { 30, 0 }, { 31, 0 }, { 32, 258 }, + { 33, 0 }, { 34, 0 }, { 35, 0 }, { 36, 0 }, { 37, 0 }, + { 38, 0 }, { 39, 0 }, { 40, 0 }, { 41, 0 }, { 42, 0 }, + { 43, 0 }, { 44, 0 }, { 45, 563 }, { 46, 0 }, { 47, 0 }, + { 48, 0 }, { 49, 0 }, { 50, 0 }, { 51, 0 }, { 52, 0 }, + { 53, 0 }, { 54, 0 }, { 55, 0 }, { 56, 0 }, { 57, 0 }, + { 58, 0 }, { 59, 0 }, { 60, 0 }, { 61, 0 }, { 62, 0 }, + + { 63, 0 }, { 64, 0 }, { 65, 0 }, { 66, 0 }, { 67, 0 }, + { 68, 0 }, { 69, 0 }, { 70, 0 }, { 71, 0 }, { 72, 0 }, + { 73, 0 }, { 74, 0 }, { 75, 0 }, { 76, 0 }, { 77, 0 }, + { 78, 0 }, { 79, 0 }, { 80, 0 }, { 81, 0 }, { 82, 0 }, + { 83, 0 }, { 84, 0 }, { 85, 0 }, { 86, 0 }, { 87, 0 }, + { 88, 0 }, { 89, 0 }, { 90, 0 }, { 91, 0 }, { 92, 0 }, + { 93, 0 }, { 94, 0 }, { 95, 0 }, { 96, 0 }, { 97, 0 }, + { 98, 0 }, { 99, 0 }, { 100, 0 }, { 101, 0 }, { 102, 0 }, + { 103, 0 }, { 104, 0 }, { 105, 0 }, { 106, 0 }, { 107, 0 }, + { 108, 0 }, { 109, 0 }, { 110, 0 }, { 111, 0 }, { 112, 0 }, + + { 113, 0 }, { 114, 0 }, { 115, 0 }, { 116, 0 }, { 117, 0 }, + { 118, 0 }, { 119, 0 }, { 120, 0 }, { 121, 0 }, { 122, 0 }, + { 123, 0 }, { 124, 0 }, { 125, 0 }, { 126, 0 }, { 127, 0 }, + { 128, 0 }, { 129, 0 }, { 130, 0 }, { 131, 0 }, { 132, 0 }, + { 133, 0 }, { 134, 0 }, { 135, 0 }, { 136, 0 }, { 137, 0 }, + { 138, 0 }, { 139, 0 }, { 140, 0 }, { 141, 0 }, { 142, 0 }, + { 143, 0 }, { 144, 0 }, { 145, 0 }, { 146, 0 }, { 147, 0 }, + { 148, 0 }, { 149, 0 }, { 150, 0 }, { 151, 0 }, { 152, 0 }, + { 153, 0 }, { 154, 0 }, { 155, 0 }, { 156, 0 }, { 157, 0 }, + { 158, 0 }, { 159, 0 }, { 160, 0 }, { 161, 0 }, { 162, 0 }, + + { 163, 0 }, { 164, 0 }, { 165, 0 }, { 166, 0 }, { 167, 0 }, + { 168, 0 }, { 169, 0 }, { 170, 0 }, { 171, 0 }, { 172, 0 }, + { 173, 0 }, { 174, 0 }, { 175, 0 }, { 176, 0 }, { 177, 0 }, + { 178, 0 }, { 179, 0 }, { 180, 0 }, { 181, 0 }, { 182, 0 }, + { 183, 0 }, { 184, 0 }, { 185, 0 }, { 186, 0 }, { 187, 0 }, + { 188, 0 }, { 189, 0 }, { 190, 0 }, { 191, 0 }, { 192, 0 }, + { 193, 0 }, { 194, 0 }, { 195, 0 }, { 196, 0 }, { 197, 0 }, + { 198, 0 }, { 199, 0 }, { 200, 0 }, { 201, 0 }, { 202, 0 }, + { 203, 0 }, { 204, 0 }, { 205, 0 }, { 206, 0 }, { 207, 0 }, + { 208, 0 }, { 209, 0 }, { 210, 0 }, { 211, 0 }, { 212, 0 }, + + { 213, 0 }, { 214, 0 }, { 215, 0 }, { 216, 0 }, { 217, 0 }, + { 218, 0 }, { 219, 0 }, { 220, 0 }, { 221, 0 }, { 222, 0 }, + { 223, 0 }, { 224, 0 }, { 225, 0 }, { 226, 0 }, { 227, 0 }, + { 228, 0 }, { 229, 0 }, { 230, 0 }, { 231, 0 }, { 232, 0 }, + { 233, 0 }, { 234, 0 }, { 235, 0 }, { 236, 0 }, { 237, 0 }, + { 238, 0 }, { 239, 0 }, { 240, 0 }, { 241, 0 }, { 242, 0 }, + { 243, 0 }, { 244, 0 }, { 245, 0 }, { 246, 0 }, { 247, 0 }, + { 248, 0 }, { 249, 0 }, { 250, 0 }, { 251, 0 }, { 252, 0 }, + { 253, 0 }, { 254, 0 }, { 255, 0 }, { 256, 0 }, { 0, 16 }, + { 0,39635 }, { 1,-258 }, { 2,-258 }, { 3,-258 }, { 4,-258 }, + + { 5,-258 }, { 6,-258 }, { 7,-258 }, { 8,-258 }, { 9, 0 }, + { 10, 258 }, { 11,-258 }, { 12, 0 }, { 13, 258 }, { 14,-258 }, + { 15,-258 }, { 16,-258 }, { 17,-258 }, { 18,-258 }, { 19,-258 }, + { 20,-258 }, { 21,-258 }, { 22,-258 }, { 23,-258 }, { 24,-258 }, + { 25,-258 }, { 26,-258 }, { 27,-258 }, { 28,-258 }, { 29,-258 }, + { 30,-258 }, { 31,-258 }, { 32, 0 }, { 33,-258 }, { 34,-258 }, + { 35,-258 }, { 36,-258 }, { 37,-258 }, { 38,-258 }, { 39,-258 }, + { 40,-258 }, { 41,-258 }, { 42,-258 }, { 43,-258 }, { 44,-258 }, + { 45, 305 }, { 46,-258 }, { 47,-258 }, { 48,-258 }, { 49,-258 }, + { 50,-258 }, { 51,-258 }, { 52,-258 }, { 53,-258 }, { 54,-258 }, + + { 55,-258 }, { 56,-258 }, { 57,-258 }, { 58,-258 }, { 59,-258 }, + { 60,-258 }, { 61,-258 }, { 62,-258 }, { 63,-258 }, { 64,-258 }, + { 65,-258 }, { 66,-258 }, { 67,-258 }, { 68,-258 }, { 69,-258 }, + { 70,-258 }, { 71,-258 }, { 72,-258 }, { 73,-258 }, { 74,-258 }, + { 75,-258 }, { 76,-258 }, { 77,-258 }, { 78,-258 }, { 79,-258 }, + { 80,-258 }, { 81,-258 }, { 82,-258 }, { 83,-258 }, { 84,-258 }, + { 85,-258 }, { 86,-258 }, { 87,-258 }, { 88,-258 }, { 89,-258 }, + { 90,-258 }, { 91,-258 }, { 92,-258 }, { 93,-258 }, { 94,-258 }, + { 95,-258 }, { 96,-258 }, { 97,-258 }, { 98,-258 }, { 99,-258 }, + { 100,-258 }, { 101,-258 }, { 102,-258 }, { 103,-258 }, { 104,-258 }, + + { 105,-258 }, { 106,-258 }, { 107,-258 }, { 108,-258 }, { 109,-258 }, + { 110,-258 }, { 111,-258 }, { 112,-258 }, { 113,-258 }, { 114,-258 }, + { 115,-258 }, { 116,-258 }, { 117,-258 }, { 118,-258 }, { 119,-258 }, + { 120,-258 }, { 121,-258 }, { 122,-258 }, { 123,-258 }, { 124,-258 }, + { 125,-258 }, { 126,-258 }, { 127,-258 }, { 128,-258 }, { 129,-258 }, + { 130,-258 }, { 131,-258 }, { 132,-258 }, { 133,-258 }, { 134,-258 }, + { 135,-258 }, { 136,-258 }, { 137,-258 }, { 138,-258 }, { 139,-258 }, + { 140,-258 }, { 141,-258 }, { 142,-258 }, { 143,-258 }, { 144,-258 }, + { 145,-258 }, { 146,-258 }, { 147,-258 }, { 148,-258 }, { 149,-258 }, + { 150,-258 }, { 151,-258 }, { 152,-258 }, { 153,-258 }, { 154,-258 }, + + { 155,-258 }, { 156,-258 }, { 157,-258 }, { 158,-258 }, { 159,-258 }, + { 160,-258 }, { 161,-258 }, { 162,-258 }, { 163,-258 }, { 164,-258 }, + { 165,-258 }, { 166,-258 }, { 167,-258 }, { 168,-258 }, { 169,-258 }, + { 170,-258 }, { 171,-258 }, { 172,-258 }, { 173,-258 }, { 174,-258 }, + { 175,-258 }, { 176,-258 }, { 177,-258 }, { 178,-258 }, { 179,-258 }, + { 180,-258 }, { 181,-258 }, { 182,-258 }, { 183,-258 }, { 184,-258 }, + { 185,-258 }, { 186,-258 }, { 187,-258 }, { 188,-258 }, { 189,-258 }, + { 190,-258 }, { 191,-258 }, { 192,-258 }, { 193,-258 }, { 194,-258 }, + { 195,-258 }, { 196,-258 }, { 197,-258 }, { 198,-258 }, { 199,-258 }, + { 200,-258 }, { 201,-258 }, { 202,-258 }, { 203,-258 }, { 204,-258 }, + + { 205,-258 }, { 206,-258 }, { 207,-258 }, { 208,-258 }, { 209,-258 }, + { 210,-258 }, { 211,-258 }, { 212,-258 }, { 213,-258 }, { 214,-258 }, + { 215,-258 }, { 216,-258 }, { 217,-258 }, { 218,-258 }, { 219,-258 }, + { 220,-258 }, { 221,-258 }, { 222,-258 }, { 223,-258 }, { 224,-258 }, + { 225,-258 }, { 226,-258 }, { 227,-258 }, { 228,-258 }, { 229,-258 }, + { 230,-258 }, { 231,-258 }, { 232,-258 }, { 233,-258 }, { 234,-258 }, + { 235,-258 }, { 236,-258 }, { 237,-258 }, { 238,-258 }, { 239,-258 }, + { 240,-258 }, { 241,-258 }, { 242,-258 }, { 243,-258 }, { 244,-258 }, + { 245,-258 }, { 246,-258 }, { 247,-258 }, { 248,-258 }, { 249,-258 }, + { 250,-258 }, { 251,-258 }, { 252,-258 }, { 253,-258 }, { 254,-258 }, + + { 255,-258 }, { 256,-258 }, { 0, 16 }, { 0,39377 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 9,-9111 }, { 10,-9111 }, { 0, 0 }, + { 12,-9111 }, { 13,-9111 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 32,-9111 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 39,-18186 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 45,-17986 }, { 0, 16 }, + + { 0,39330 }, { 1,-563 }, { 2,-563 }, { 3,-563 }, { 4,-563 }, + { 5,-563 }, { 6,-563 }, { 7,-563 }, { 8,-563 }, { 9,-305 }, + { 10, -47 }, { 11,-563 }, { 12,-305 }, { 13, -47 }, { 14,-563 }, + { 15,-563 }, { 16,-563 }, { 17,-563 }, { 18,-563 }, { 19,-563 }, + { 20,-563 }, { 21,-563 }, { 22,-563 }, { 23,-563 }, { 24,-563 }, + { 25,-563 }, { 26,-563 }, { 27,-563 }, { 28,-563 }, { 29,-563 }, + { 30,-563 }, { 31,-563 }, { 32,-305 }, { 33,-563 }, { 34,-563 }, + { 35,-563 }, { 36,-563 }, { 37,-563 }, { 38,-563 }, { 39,-563 }, + { 40,-563 }, { 41,-563 }, { 42,-563 }, { 43,-563 }, { 44,-563 }, + { 45,4290 }, { 46,-563 }, { 47,-563 }, { 48,-563 }, { 49,-563 }, + + { 50,-563 }, { 51,-563 }, { 52,-563 }, { 53,-563 }, { 54,-563 }, + { 55,-563 }, { 56,-563 }, { 57,-563 }, { 58,-563 }, { 59,-563 }, + { 60,-563 }, { 61,-563 }, { 62,-563 }, { 63,-563 }, { 64,-563 }, + { 65,-563 }, { 66,-563 }, { 67,-563 }, { 68,-563 }, { 69,-563 }, + { 70,-563 }, { 71,-563 }, { 72,-563 }, { 73,-563 }, { 74,-563 }, + { 75,-563 }, { 76,-563 }, { 77,-563 }, { 78,-563 }, { 79,-563 }, + { 80,-563 }, { 81,-563 }, { 82,-563 }, { 83,-563 }, { 84,-563 }, + { 85,-563 }, { 86,-563 }, { 87,-563 }, { 88,-563 }, { 89,-563 }, + { 90,-563 }, { 91,-563 }, { 92,-563 }, { 93,-563 }, { 94,-563 }, + { 95,-563 }, { 96,-563 }, { 97,-563 }, { 98,-563 }, { 99,-563 }, + + { 100,-563 }, { 101,-563 }, { 102,-563 }, { 103,-563 }, { 104,-563 }, + { 105,-563 }, { 106,-563 }, { 107,-563 }, { 108,-563 }, { 109,-563 }, + { 110,-563 }, { 111,-563 }, { 112,-563 }, { 113,-563 }, { 114,-563 }, + { 115,-563 }, { 116,-563 }, { 117,-563 }, { 118,-563 }, { 119,-563 }, + { 120,-563 }, { 121,-563 }, { 122,-563 }, { 123,-563 }, { 124,-563 }, + { 125,-563 }, { 126,-563 }, { 127,-563 }, { 128,-563 }, { 129,-563 }, + { 130,-563 }, { 131,-563 }, { 132,-563 }, { 133,-563 }, { 134,-563 }, + { 135,-563 }, { 136,-563 }, { 137,-563 }, { 138,-563 }, { 139,-563 }, + { 140,-563 }, { 141,-563 }, { 142,-563 }, { 143,-563 }, { 144,-563 }, + { 145,-563 }, { 146,-563 }, { 147,-563 }, { 148,-563 }, { 149,-563 }, + + { 150,-563 }, { 151,-563 }, { 152,-563 }, { 153,-563 }, { 154,-563 }, + { 155,-563 }, { 156,-563 }, { 157,-563 }, { 158,-563 }, { 159,-563 }, + { 160,-563 }, { 161,-563 }, { 162,-563 }, { 163,-563 }, { 164,-563 }, + { 165,-563 }, { 166,-563 }, { 167,-563 }, { 168,-563 }, { 169,-563 }, + { 170,-563 }, { 171,-563 }, { 172,-563 }, { 173,-563 }, { 174,-563 }, + { 175,-563 }, { 176,-563 }, { 177,-563 }, { 178,-563 }, { 179,-563 }, + { 180,-563 }, { 181,-563 }, { 182,-563 }, { 183,-563 }, { 184,-563 }, + { 185,-563 }, { 186,-563 }, { 187,-563 }, { 188,-563 }, { 189,-563 }, + { 190,-563 }, { 191,-563 }, { 192,-563 }, { 193,-563 }, { 194,-563 }, + { 195,-563 }, { 196,-563 }, { 197,-563 }, { 198,-563 }, { 199,-563 }, + + { 200,-563 }, { 201,-563 }, { 202,-563 }, { 203,-563 }, { 204,-563 }, + { 205,-563 }, { 206,-563 }, { 207,-563 }, { 208,-563 }, { 209,-563 }, + { 210,-563 }, { 211,-563 }, { 212,-563 }, { 213,-563 }, { 214,-563 }, + { 215,-563 }, { 216,-563 }, { 217,-563 }, { 218,-563 }, { 219,-563 }, + { 220,-563 }, { 221,-563 }, { 222,-563 }, { 223,-563 }, { 224,-563 }, + { 225,-563 }, { 226,-563 }, { 227,-563 }, { 228,-563 }, { 229,-563 }, + { 230,-563 }, { 231,-563 }, { 232,-563 }, { 233,-563 }, { 234,-563 }, + { 235,-563 }, { 236,-563 }, { 237,-563 }, { 238,-563 }, { 239,-563 }, + { 240,-563 }, { 241,-563 }, { 242,-563 }, { 243,-563 }, { 244,-563 }, + { 245,-563 }, { 246,-563 }, { 247,-563 }, { 248,-563 }, { 249,-563 }, + + { 250,-563 }, { 251,-563 }, { 252,-563 }, { 253,-563 }, { 254,-563 }, + { 255,-563 }, { 256,-563 }, { 0, 16 }, { 0,39072 }, { 1,-6282 }, + { 2,-6282 }, { 3,-6282 }, { 4,-6282 }, { 5,-6282 }, { 6,-6282 }, + { 7,-6282 }, { 8,-6282 }, { 9,-6024 }, { 10,-11998 }, { 11,-6282 }, + { 12,-6024 }, { 13,-11998 }, { 14,-6282 }, { 15,-6282 }, { 16,-6282 }, + { 17,-6282 }, { 18,-6282 }, { 19,-6282 }, { 20,-6282 }, { 21,-6282 }, + { 22,-6282 }, { 23,-6282 }, { 24,-6282 }, { 25,-6282 }, { 26,-6282 }, + { 27,-6282 }, { 28,-6282 }, { 29,-6282 }, { 30,-6282 }, { 31,-6282 }, + { 32,-6024 }, { 33,-6282 }, { 34,-6282 }, { 35,-6282 }, { 36,-6282 }, + { 37,-6282 }, { 38,-6282 }, { 39,-6282 }, { 40,-6282 }, { 41,-6282 }, + + { 42,-6282 }, { 43,-6282 }, { 44,-6282 }, { 45, 0 }, { 46,-6282 }, + { 47,-6282 }, { 48,-6282 }, { 49,-6282 }, { 50,-6282 }, { 51,-6282 }, + { 52,-6282 }, { 53,-6282 }, { 54,-6282 }, { 55,-6282 }, { 56,-6282 }, + { 57,-6282 }, { 58,-6282 }, { 59,-6282 }, { 60,-6282 }, { 61,-6282 }, + { 62,-6282 }, { 63,-6282 }, { 64,-6282 }, { 65,-6282 }, { 66,-6282 }, + { 67,-6282 }, { 68,-6282 }, { 69,-6282 }, { 70,-6282 }, { 71,-6282 }, + { 72,-6282 }, { 73,-6282 }, { 74,-6282 }, { 75,-6282 }, { 76,-6282 }, + { 77,-6282 }, { 78,-6282 }, { 79,-6282 }, { 80,-6282 }, { 81,-6282 }, + { 82,-6282 }, { 83,-6282 }, { 84,-6282 }, { 85,-6282 }, { 86,-6282 }, + { 87,-6282 }, { 88,-6282 }, { 89,-6282 }, { 90,-6282 }, { 91,-6282 }, + + { 92,-6282 }, { 93,-6282 }, { 94,-6282 }, { 95,-6282 }, { 96,-6282 }, + { 97,-6282 }, { 98,-6282 }, { 99,-6282 }, { 100,-6282 }, { 101,-6282 }, + { 102,-6282 }, { 103,-6282 }, { 104,-6282 }, { 105,-6282 }, { 106,-6282 }, + { 107,-6282 }, { 108,-6282 }, { 109,-6282 }, { 110,-6282 }, { 111,-6282 }, + { 112,-6282 }, { 113,-6282 }, { 114,-6282 }, { 115,-6282 }, { 116,-6282 }, + { 117,-6282 }, { 118,-6282 }, { 119,-6282 }, { 120,-6282 }, { 121,-6282 }, + { 122,-6282 }, { 123,-6282 }, { 124,-6282 }, { 125,-6282 }, { 126,-6282 }, + { 127,-6282 }, { 128,-6282 }, { 129,-6282 }, { 130,-6282 }, { 131,-6282 }, + { 132,-6282 }, { 133,-6282 }, { 134,-6282 }, { 135,-6282 }, { 136,-6282 }, + { 137,-6282 }, { 138,-6282 }, { 139,-6282 }, { 140,-6282 }, { 141,-6282 }, + + { 142,-6282 }, { 143,-6282 }, { 144,-6282 }, { 145,-6282 }, { 146,-6282 }, + { 147,-6282 }, { 148,-6282 }, { 149,-6282 }, { 150,-6282 }, { 151,-6282 }, + { 152,-6282 }, { 153,-6282 }, { 154,-6282 }, { 155,-6282 }, { 156,-6282 }, + { 157,-6282 }, { 158,-6282 }, { 159,-6282 }, { 160,-6282 }, { 161,-6282 }, + { 162,-6282 }, { 163,-6282 }, { 164,-6282 }, { 165,-6282 }, { 166,-6282 }, + { 167,-6282 }, { 168,-6282 }, { 169,-6282 }, { 170,-6282 }, { 171,-6282 }, + { 172,-6282 }, { 173,-6282 }, { 174,-6282 }, { 175,-6282 }, { 176,-6282 }, + { 177,-6282 }, { 178,-6282 }, { 179,-6282 }, { 180,-6282 }, { 181,-6282 }, + { 182,-6282 }, { 183,-6282 }, { 184,-6282 }, { 185,-6282 }, { 186,-6282 }, + { 187,-6282 }, { 188,-6282 }, { 189,-6282 }, { 190,-6282 }, { 191,-6282 }, + + { 192,-6282 }, { 193,-6282 }, { 194,-6282 }, { 195,-6282 }, { 196,-6282 }, + { 197,-6282 }, { 198,-6282 }, { 199,-6282 }, { 200,-6282 }, { 201,-6282 }, + { 202,-6282 }, { 203,-6282 }, { 204,-6282 }, { 205,-6282 }, { 206,-6282 }, + { 207,-6282 }, { 208,-6282 }, { 209,-6282 }, { 210,-6282 }, { 211,-6282 }, + { 212,-6282 }, { 213,-6282 }, { 214,-6282 }, { 215,-6282 }, { 216,-6282 }, + { 217,-6282 }, { 218,-6282 }, { 219,-6282 }, { 220,-6282 }, { 221,-6282 }, + { 222,-6282 }, { 223,-6282 }, { 224,-6282 }, { 225,-6282 }, { 226,-6282 }, + { 227,-6282 }, { 228,-6282 }, { 229,-6282 }, { 230,-6282 }, { 231,-6282 }, + { 232,-6282 }, { 233,-6282 }, { 234,-6282 }, { 235,-6282 }, { 236,-6282 }, + { 237,-6282 }, { 238,-6282 }, { 239,-6282 }, { 240,-6282 }, { 241,-6282 }, + + { 242,-6282 }, { 243,-6282 }, { 244,-6282 }, { 245,-6282 }, { 246,-6282 }, + { 247,-6282 }, { 248,-6282 }, { 249,-6282 }, { 250,-6282 }, { 251,-6282 }, + { 252,-6282 }, { 253,-6282 }, { 254,-6282 }, { 255,-6282 }, { 256,-6282 }, + { 0, 22 }, { 0,38814 }, { 1, 0 }, { 2, 0 }, { 3, 0 }, + { 4, 0 }, { 5, 0 }, { 6, 0 }, { 7, 0 }, { 8, 0 }, + { 9, 258 }, { 10, 516 }, { 11, 0 }, { 12, 258 }, { 13, 516 }, + { 14, 0 }, { 15, 0 }, { 16, 0 }, { 17, 0 }, { 18, 0 }, + { 19, 0 }, { 20, 0 }, { 21, 0 }, { 22, 0 }, { 23, 0 }, + { 24, 0 }, { 25, 0 }, { 26, 0 }, { 27, 0 }, { 28, 0 }, + { 29, 0 }, { 30, 0 }, { 31, 0 }, { 32, 258 }, { 33, 0 }, + + { 34, 0 }, { 35, 0 }, { 36, 0 }, { 37, 0 }, { 38, 0 }, + { 39, 0 }, { 40, 0 }, { 41, 0 }, { 42, 0 }, { 43, 0 }, + { 44, 0 }, { 45, 563 }, { 46, 0 }, { 47, 0 }, { 48, 0 }, + { 49, 0 }, { 50, 0 }, { 51, 0 }, { 52, 0 }, { 53, 0 }, + { 54, 0 }, { 55, 0 }, { 56, 0 }, { 57, 0 }, { 58, 0 }, + { 59, 0 }, { 60, 0 }, { 61, 0 }, { 62, 0 }, { 63, 0 }, + { 64, 0 }, { 65, 0 }, { 66, 0 }, { 67, 0 }, { 68, 0 }, + { 69, 0 }, { 70, 0 }, { 71, 0 }, { 72, 0 }, { 73, 0 }, + { 74, 0 }, { 75, 0 }, { 76, 0 }, { 77, 0 }, { 78, 0 }, + { 79, 0 }, { 80, 0 }, { 81, 0 }, { 82, 0 }, { 83, 0 }, + + { 84, 0 }, { 85, 0 }, { 86, 0 }, { 87, 0 }, { 88, 0 }, + { 89, 0 }, { 90, 0 }, { 91, 0 }, { 92, 0 }, { 93, 0 }, + { 94, 0 }, { 95, 0 }, { 96, 0 }, { 97, 0 }, { 98, 0 }, + { 99, 0 }, { 100, 0 }, { 101, 0 }, { 102, 0 }, { 103, 0 }, + { 104, 0 }, { 105, 0 }, { 106, 0 }, { 107, 0 }, { 108, 0 }, + { 109, 0 }, { 110, 0 }, { 111, 0 }, { 112, 0 }, { 113, 0 }, + { 114, 0 }, { 115, 0 }, { 116, 0 }, { 117, 0 }, { 118, 0 }, + { 119, 0 }, { 120, 0 }, { 121, 0 }, { 122, 0 }, { 123, 0 }, + { 124, 0 }, { 125, 0 }, { 126, 0 }, { 127, 0 }, { 128, 0 }, + { 129, 0 }, { 130, 0 }, { 131, 0 }, { 132, 0 }, { 133, 0 }, + + { 134, 0 }, { 135, 0 }, { 136, 0 }, { 137, 0 }, { 138, 0 }, + { 139, 0 }, { 140, 0 }, { 141, 0 }, { 142, 0 }, { 143, 0 }, + { 144, 0 }, { 145, 0 }, { 146, 0 }, { 147, 0 }, { 148, 0 }, + { 149, 0 }, { 150, 0 }, { 151, 0 }, { 152, 0 }, { 153, 0 }, + { 154, 0 }, { 155, 0 }, { 156, 0 }, { 157, 0 }, { 158, 0 }, + { 159, 0 }, { 160, 0 }, { 161, 0 }, { 162, 0 }, { 163, 0 }, + { 164, 0 }, { 165, 0 }, { 166, 0 }, { 167, 0 }, { 168, 0 }, + { 169, 0 }, { 170, 0 }, { 171, 0 }, { 172, 0 }, { 173, 0 }, + { 174, 0 }, { 175, 0 }, { 176, 0 }, { 177, 0 }, { 178, 0 }, + { 179, 0 }, { 180, 0 }, { 181, 0 }, { 182, 0 }, { 183, 0 }, + + { 184, 0 }, { 185, 0 }, { 186, 0 }, { 187, 0 }, { 188, 0 }, + { 189, 0 }, { 190, 0 }, { 191, 0 }, { 192, 0 }, { 193, 0 }, + { 194, 0 }, { 195, 0 }, { 196, 0 }, { 197, 0 }, { 198, 0 }, + { 199, 0 }, { 200, 0 }, { 201, 0 }, { 202, 0 }, { 203, 0 }, + { 204, 0 }, { 205, 0 }, { 206, 0 }, { 207, 0 }, { 208, 0 }, + { 209, 0 }, { 210, 0 }, { 211, 0 }, { 212, 0 }, { 213, 0 }, + { 214, 0 }, { 215, 0 }, { 216, 0 }, { 217, 0 }, { 218, 0 }, + { 219, 0 }, { 220, 0 }, { 221, 0 }, { 222, 0 }, { 223, 0 }, + { 224, 0 }, { 225, 0 }, { 226, 0 }, { 227, 0 }, { 228, 0 }, + { 229, 0 }, { 230, 0 }, { 231, 0 }, { 232, 0 }, { 233, 0 }, + + { 234, 0 }, { 235, 0 }, { 236, 0 }, { 237, 0 }, { 238, 0 }, + { 239, 0 }, { 240, 0 }, { 241, 0 }, { 242, 0 }, { 243, 0 }, + { 244, 0 }, { 245, 0 }, { 246, 0 }, { 247, 0 }, { 248, 0 }, + { 249, 0 }, { 250, 0 }, { 251, 0 }, { 252, 0 }, { 253, 0 }, + { 254, 0 }, { 255, 0 }, { 256, 0 }, { 0, 22 }, { 0,38556 }, + { 1,-258 }, { 2,-258 }, { 3,-258 }, { 4,-258 }, { 5,-258 }, + { 6,-258 }, { 7,-258 }, { 8,-258 }, { 9, 0 }, { 10, 258 }, + { 11,-258 }, { 12, 0 }, { 13, 258 }, { 14,-258 }, { 15,-258 }, + { 16,-258 }, { 17,-258 }, { 18,-258 }, { 19,-258 }, { 20,-258 }, + { 21,-258 }, { 22,-258 }, { 23,-258 }, { 24,-258 }, { 25,-258 }, + + { 26,-258 }, { 27,-258 }, { 28,-258 }, { 29,-258 }, { 30,-258 }, + { 31,-258 }, { 32, 0 }, { 33,-258 }, { 34,-258 }, { 35,-258 }, + { 36,-258 }, { 37,-258 }, { 38,-258 }, { 39,-258 }, { 40,-258 }, + { 41,-258 }, { 42,-258 }, { 43,-258 }, { 44,-258 }, { 45, 305 }, + { 46,-258 }, { 47,-258 }, { 48,-258 }, { 49,-258 }, { 50,-258 }, + { 51,-258 }, { 52,-258 }, { 53,-258 }, { 54,-258 }, { 55,-258 }, + { 56,-258 }, { 57,-258 }, { 58,-258 }, { 59,-258 }, { 60,-258 }, + { 61,-258 }, { 62,-258 }, { 63,-258 }, { 64,-258 }, { 65,-258 }, + { 66,-258 }, { 67,-258 }, { 68,-258 }, { 69,-258 }, { 70,-258 }, + { 71,-258 }, { 72,-258 }, { 73,-258 }, { 74,-258 }, { 75,-258 }, + + { 76,-258 }, { 77,-258 }, { 78,-258 }, { 79,-258 }, { 80,-258 }, + { 81,-258 }, { 82,-258 }, { 83,-258 }, { 84,-258 }, { 85,-258 }, + { 86,-258 }, { 87,-258 }, { 88,-258 }, { 89,-258 }, { 90,-258 }, + { 91,-258 }, { 92,-258 }, { 93,-258 }, { 94,-258 }, { 95,-258 }, + { 96,-258 }, { 97,-258 }, { 98,-258 }, { 99,-258 }, { 100,-258 }, + { 101,-258 }, { 102,-258 }, { 103,-258 }, { 104,-258 }, { 105,-258 }, + { 106,-258 }, { 107,-258 }, { 108,-258 }, { 109,-258 }, { 110,-258 }, + { 111,-258 }, { 112,-258 }, { 113,-258 }, { 114,-258 }, { 115,-258 }, + { 116,-258 }, { 117,-258 }, { 118,-258 }, { 119,-258 }, { 120,-258 }, + { 121,-258 }, { 122,-258 }, { 123,-258 }, { 124,-258 }, { 125,-258 }, + + { 126,-258 }, { 127,-258 }, { 128,-258 }, { 129,-258 }, { 130,-258 }, + { 131,-258 }, { 132,-258 }, { 133,-258 }, { 134,-258 }, { 135,-258 }, + { 136,-258 }, { 137,-258 }, { 138,-258 }, { 139,-258 }, { 140,-258 }, + { 141,-258 }, { 142,-258 }, { 143,-258 }, { 144,-258 }, { 145,-258 }, + { 146,-258 }, { 147,-258 }, { 148,-258 }, { 149,-258 }, { 150,-258 }, + { 151,-258 }, { 152,-258 }, { 153,-258 }, { 154,-258 }, { 155,-258 }, + { 156,-258 }, { 157,-258 }, { 158,-258 }, { 159,-258 }, { 160,-258 }, + { 161,-258 }, { 162,-258 }, { 163,-258 }, { 164,-258 }, { 165,-258 }, + { 166,-258 }, { 167,-258 }, { 168,-258 }, { 169,-258 }, { 170,-258 }, + { 171,-258 }, { 172,-258 }, { 173,-258 }, { 174,-258 }, { 175,-258 }, + + { 176,-258 }, { 177,-258 }, { 178,-258 }, { 179,-258 }, { 180,-258 }, + { 181,-258 }, { 182,-258 }, { 183,-258 }, { 184,-258 }, { 185,-258 }, + { 186,-258 }, { 187,-258 }, { 188,-258 }, { 189,-258 }, { 190,-258 }, + { 191,-258 }, { 192,-258 }, { 193,-258 }, { 194,-258 }, { 195,-258 }, + { 196,-258 }, { 197,-258 }, { 198,-258 }, { 199,-258 }, { 200,-258 }, + { 201,-258 }, { 202,-258 }, { 203,-258 }, { 204,-258 }, { 205,-258 }, + { 206,-258 }, { 207,-258 }, { 208,-258 }, { 209,-258 }, { 210,-258 }, + { 211,-258 }, { 212,-258 }, { 213,-258 }, { 214,-258 }, { 215,-258 }, + { 216,-258 }, { 217,-258 }, { 218,-258 }, { 219,-258 }, { 220,-258 }, + { 221,-258 }, { 222,-258 }, { 223,-258 }, { 224,-258 }, { 225,-258 }, + + { 226,-258 }, { 227,-258 }, { 228,-258 }, { 229,-258 }, { 230,-258 }, + { 231,-258 }, { 232,-258 }, { 233,-258 }, { 234,-258 }, { 235,-258 }, + { 236,-258 }, { 237,-258 }, { 238,-258 }, { 239,-258 }, { 240,-258 }, + { 241,-258 }, { 242,-258 }, { 243,-258 }, { 244,-258 }, { 245,-258 }, + { 246,-258 }, { 247,-258 }, { 248,-258 }, { 249,-258 }, { 250,-258 }, + { 251,-258 }, { 252,-258 }, { 253,-258 }, { 254,-258 }, { 255,-258 }, + { 256,-258 }, { 0, 22 }, { 0,38298 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 9,-9811 }, { 10,-9811 }, { 0, 0 }, { 12,-9811 }, + { 13,-9811 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 32,-9811 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 39,-19063 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 45,-19054 }, { 0, 22 }, { 0,38251 }, + { 1,-563 }, { 2,-563 }, { 3,-563 }, { 4,-563 }, { 5,-563 }, + { 6,-563 }, { 7,-563 }, { 8,-563 }, { 9,-305 }, { 10, -47 }, + { 11,-563 }, { 12,-305 }, { 13, -47 }, { 14,-563 }, { 15,-563 }, + { 16,-563 }, { 17,-563 }, { 18,-563 }, { 19,-563 }, { 20,-563 }, + + { 21,-563 }, { 22,-563 }, { 23,-563 }, { 24,-563 }, { 25,-563 }, + { 26,-563 }, { 27,-563 }, { 28,-563 }, { 29,-563 }, { 30,-563 }, + { 31,-563 }, { 32,-305 }, { 33,-563 }, { 34,-563 }, { 35,-563 }, + { 36,-563 }, { 37,-563 }, { 38,-563 }, { 39,-563 }, { 40,-563 }, + { 41,-563 }, { 42,-563 }, { 43,-563 }, { 44,-563 }, { 45,3469 }, + { 46,-563 }, { 47,-563 }, { 48,-563 }, { 49,-563 }, { 50,-563 }, + { 51,-563 }, { 52,-563 }, { 53,-563 }, { 54,-563 }, { 55,-563 }, + { 56,-563 }, { 57,-563 }, { 58,-563 }, { 59,-563 }, { 60,-563 }, + { 61,-563 }, { 62,-563 }, { 63,-563 }, { 64,-563 }, { 65,-563 }, + { 66,-563 }, { 67,-563 }, { 68,-563 }, { 69,-563 }, { 70,-563 }, + + { 71,-563 }, { 72,-563 }, { 73,-563 }, { 74,-563 }, { 75,-563 }, + { 76,-563 }, { 77,-563 }, { 78,-563 }, { 79,-563 }, { 80,-563 }, + { 81,-563 }, { 82,-563 }, { 83,-563 }, { 84,-563 }, { 85,-563 }, + { 86,-563 }, { 87,-563 }, { 88,-563 }, { 89,-563 }, { 90,-563 }, + { 91,-563 }, { 92,-563 }, { 93,-563 }, { 94,-563 }, { 95,-563 }, + { 96,-563 }, { 97,-563 }, { 98,-563 }, { 99,-563 }, { 100,-563 }, + { 101,-563 }, { 102,-563 }, { 103,-563 }, { 104,-563 }, { 105,-563 }, + { 106,-563 }, { 107,-563 }, { 108,-563 }, { 109,-563 }, { 110,-563 }, + { 111,-563 }, { 112,-563 }, { 113,-563 }, { 114,-563 }, { 115,-563 }, + { 116,-563 }, { 117,-563 }, { 118,-563 }, { 119,-563 }, { 120,-563 }, + + { 121,-563 }, { 122,-563 }, { 123,-563 }, { 124,-563 }, { 125,-563 }, + { 126,-563 }, { 127,-563 }, { 128,-563 }, { 129,-563 }, { 130,-563 }, + { 131,-563 }, { 132,-563 }, { 133,-563 }, { 134,-563 }, { 135,-563 }, + { 136,-563 }, { 137,-563 }, { 138,-563 }, { 139,-563 }, { 140,-563 }, + { 141,-563 }, { 142,-563 }, { 143,-563 }, { 144,-563 }, { 145,-563 }, + { 146,-563 }, { 147,-563 }, { 148,-563 }, { 149,-563 }, { 150,-563 }, + { 151,-563 }, { 152,-563 }, { 153,-563 }, { 154,-563 }, { 155,-563 }, + { 156,-563 }, { 157,-563 }, { 158,-563 }, { 159,-563 }, { 160,-563 }, + { 161,-563 }, { 162,-563 }, { 163,-563 }, { 164,-563 }, { 165,-563 }, + { 166,-563 }, { 167,-563 }, { 168,-563 }, { 169,-563 }, { 170,-563 }, + + { 171,-563 }, { 172,-563 }, { 173,-563 }, { 174,-563 }, { 175,-563 }, + { 176,-563 }, { 177,-563 }, { 178,-563 }, { 179,-563 }, { 180,-563 }, + { 181,-563 }, { 182,-563 }, { 183,-563 }, { 184,-563 }, { 185,-563 }, + { 186,-563 }, { 187,-563 }, { 188,-563 }, { 189,-563 }, { 190,-563 }, + { 191,-563 }, { 192,-563 }, { 193,-563 }, { 194,-563 }, { 195,-563 }, + { 196,-563 }, { 197,-563 }, { 198,-563 }, { 199,-563 }, { 200,-563 }, + { 201,-563 }, { 202,-563 }, { 203,-563 }, { 204,-563 }, { 205,-563 }, + { 206,-563 }, { 207,-563 }, { 208,-563 }, { 209,-563 }, { 210,-563 }, + { 211,-563 }, { 212,-563 }, { 213,-563 }, { 214,-563 }, { 215,-563 }, + { 216,-563 }, { 217,-563 }, { 218,-563 }, { 219,-563 }, { 220,-563 }, + + { 221,-563 }, { 222,-563 }, { 223,-563 }, { 224,-563 }, { 225,-563 }, + { 226,-563 }, { 227,-563 }, { 228,-563 }, { 229,-563 }, { 230,-563 }, + { 231,-563 }, { 232,-563 }, { 233,-563 }, { 234,-563 }, { 235,-563 }, + { 236,-563 }, { 237,-563 }, { 238,-563 }, { 239,-563 }, { 240,-563 }, + { 241,-563 }, { 242,-563 }, { 243,-563 }, { 244,-563 }, { 245,-563 }, + { 246,-563 }, { 247,-563 }, { 248,-563 }, { 249,-563 }, { 250,-563 }, + { 251,-563 }, { 252,-563 }, { 253,-563 }, { 254,-563 }, { 255,-563 }, + { 256,-563 }, { 0, 22 }, { 0,37993 }, { 1,-6329 }, { 2,-6329 }, + { 3,-6329 }, { 4,-6329 }, { 5,-6329 }, { 6,-6329 }, { 7,-6329 }, + { 8,-6329 }, { 9,-6071 }, { 10,-12767 }, { 11,-6329 }, { 12,-6071 }, + + { 13,-12767 }, { 14,-6329 }, { 15,-6329 }, { 16,-6329 }, { 17,-6329 }, + { 18,-6329 }, { 19,-6329 }, { 20,-6329 }, { 21,-6329 }, { 22,-6329 }, + { 23,-6329 }, { 24,-6329 }, { 25,-6329 }, { 26,-6329 }, { 27,-6329 }, + { 28,-6329 }, { 29,-6329 }, { 30,-6329 }, { 31,-6329 }, { 32,-6071 }, + { 33,-6329 }, { 34,-6329 }, { 35,-6329 }, { 36,-6329 }, { 37,-6329 }, + { 38,-6329 }, { 39,-6329 }, { 40,-6329 }, { 41,-6329 }, { 42,-6329 }, + { 43,-6329 }, { 44,-6329 }, { 45, 0 }, { 46,-6329 }, { 47,-6329 }, + { 48,-6329 }, { 49,-6329 }, { 50,-6329 }, { 51,-6329 }, { 52,-6329 }, + { 53,-6329 }, { 54,-6329 }, { 55,-6329 }, { 56,-6329 }, { 57,-6329 }, + { 58,-6329 }, { 59,-6329 }, { 60,-6329 }, { 61,-6329 }, { 62,-6329 }, + + { 63,-6329 }, { 64,-6329 }, { 65,-6329 }, { 66,-6329 }, { 67,-6329 }, + { 68,-6329 }, { 69,-6329 }, { 70,-6329 }, { 71,-6329 }, { 72,-6329 }, + { 73,-6329 }, { 74,-6329 }, { 75,-6329 }, { 76,-6329 }, { 77,-6329 }, + { 78,-6329 }, { 79,-6329 }, { 80,-6329 }, { 81,-6329 }, { 82,-6329 }, + { 83,-6329 }, { 84,-6329 }, { 85,-6329 }, { 86,-6329 }, { 87,-6329 }, + { 88,-6329 }, { 89,-6329 }, { 90,-6329 }, { 91,-6329 }, { 92,-6329 }, + { 93,-6329 }, { 94,-6329 }, { 95,-6329 }, { 96,-6329 }, { 97,-6329 }, + { 98,-6329 }, { 99,-6329 }, { 100,-6329 }, { 101,-6329 }, { 102,-6329 }, + { 103,-6329 }, { 104,-6329 }, { 105,-6329 }, { 106,-6329 }, { 107,-6329 }, + { 108,-6329 }, { 109,-6329 }, { 110,-6329 }, { 111,-6329 }, { 112,-6329 }, + + { 113,-6329 }, { 114,-6329 }, { 115,-6329 }, { 116,-6329 }, { 117,-6329 }, + { 118,-6329 }, { 119,-6329 }, { 120,-6329 }, { 121,-6329 }, { 122,-6329 }, + { 123,-6329 }, { 124,-6329 }, { 125,-6329 }, { 126,-6329 }, { 127,-6329 }, + { 128,-6329 }, { 129,-6329 }, { 130,-6329 }, { 131,-6329 }, { 132,-6329 }, + { 133,-6329 }, { 134,-6329 }, { 135,-6329 }, { 136,-6329 }, { 137,-6329 }, + { 138,-6329 }, { 139,-6329 }, { 140,-6329 }, { 141,-6329 }, { 142,-6329 }, + { 143,-6329 }, { 144,-6329 }, { 145,-6329 }, { 146,-6329 }, { 147,-6329 }, + { 148,-6329 }, { 149,-6329 }, { 150,-6329 }, { 151,-6329 }, { 152,-6329 }, + { 153,-6329 }, { 154,-6329 }, { 155,-6329 }, { 156,-6329 }, { 157,-6329 }, + { 158,-6329 }, { 159,-6329 }, { 160,-6329 }, { 161,-6329 }, { 162,-6329 }, + + { 163,-6329 }, { 164,-6329 }, { 165,-6329 }, { 166,-6329 }, { 167,-6329 }, + { 168,-6329 }, { 169,-6329 }, { 170,-6329 }, { 171,-6329 }, { 172,-6329 }, + { 173,-6329 }, { 174,-6329 }, { 175,-6329 }, { 176,-6329 }, { 177,-6329 }, + { 178,-6329 }, { 179,-6329 }, { 180,-6329 }, { 181,-6329 }, { 182,-6329 }, + { 183,-6329 }, { 184,-6329 }, { 185,-6329 }, { 186,-6329 }, { 187,-6329 }, + { 188,-6329 }, { 189,-6329 }, { 190,-6329 }, { 191,-6329 }, { 192,-6329 }, + { 193,-6329 }, { 194,-6329 }, { 195,-6329 }, { 196,-6329 }, { 197,-6329 }, + { 198,-6329 }, { 199,-6329 }, { 200,-6329 }, { 201,-6329 }, { 202,-6329 }, + { 203,-6329 }, { 204,-6329 }, { 205,-6329 }, { 206,-6329 }, { 207,-6329 }, + { 208,-6329 }, { 209,-6329 }, { 210,-6329 }, { 211,-6329 }, { 212,-6329 }, + + { 213,-6329 }, { 214,-6329 }, { 215,-6329 }, { 216,-6329 }, { 217,-6329 }, + { 218,-6329 }, { 219,-6329 }, { 220,-6329 }, { 221,-6329 }, { 222,-6329 }, + { 223,-6329 }, { 224,-6329 }, { 225,-6329 }, { 226,-6329 }, { 227,-6329 }, + { 228,-6329 }, { 229,-6329 }, { 230,-6329 }, { 231,-6329 }, { 232,-6329 }, + { 233,-6329 }, { 234,-6329 }, { 235,-6329 }, { 236,-6329 }, { 237,-6329 }, + { 238,-6329 }, { 239,-6329 }, { 240,-6329 }, { 241,-6329 }, { 242,-6329 }, + { 243,-6329 }, { 244,-6329 }, { 245,-6329 }, { 246,-6329 }, { 247,-6329 }, + { 248,-6329 }, { 249,-6329 }, { 250,-6329 }, { 251,-6329 }, { 252,-6329 }, + { 253,-6329 }, { 254,-6329 }, { 255,-6329 }, { 256,-6329 }, { 0, 33 }, + { 0,37735 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 33 }, { 0,37712 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 48,3211 }, { 49,3211 }, + { 50,3211 }, { 51,3211 }, { 52,3211 }, { 53,3211 }, { 54,3211 }, + + { 55,3211 }, { 56,3211 }, { 57,3211 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 65,3211 }, { 66,3211 }, { 67,3211 }, { 68,3211 }, { 69,3211 }, + { 70,3211 }, { 48,-15825 }, { 49,-15825 }, { 50,-15825 }, { 51,-15825 }, + { 52,-15825 }, { 53,-15825 }, { 54,-15825 }, { 55,-15825 }, { 56,-15825 }, + { 57,-15825 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 65,-15825 }, { 66,-15825 }, + { 67,-15825 }, { 68,-15825 }, { 69,-15825 }, { 70,-15825 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 97,3211 }, { 98,3211 }, { 99,3211 }, + { 100,3211 }, { 101,3211 }, { 102,3211 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 97,-15825 }, { 98,-15825 }, { 99,-15825 }, { 100,-15825 }, { 101,-15825 }, + { 102,-15825 }, { 0, 48 }, { 0,37608 }, { 1,-5813 }, { 2,-5813 }, + { 3,-5813 }, { 4,-5813 }, { 5,-5813 }, { 6,-5813 }, { 7,-5813 }, + { 8,-5813 }, { 9,-5555 }, { 10,-12199 }, { 11,-5813 }, { 12,-5555 }, + { 13,-12199 }, { 14,-5813 }, { 15,-5813 }, { 16,-5813 }, { 17,-5813 }, + { 18,-5813 }, { 19,-5813 }, { 20,-5813 }, { 21,-5813 }, { 22,-5813 }, + { 23,-5813 }, { 24,-5813 }, { 25,-5813 }, { 26,-5813 }, { 27,-5813 }, + + { 28,-5813 }, { 29,-5813 }, { 30,-5813 }, { 31,-5813 }, { 32,-5555 }, + { 33,-5813 }, { 34,-5813 }, { 35,-5813 }, { 36,-5813 }, { 37,-5813 }, + { 38,-5813 }, { 39,-5813 }, { 40,-5813 }, { 41,-5813 }, { 42,-5813 }, + { 43,-5813 }, { 44,-5813 }, { 45, 0 }, { 46,-5813 }, { 47,-5813 }, + { 48,-5813 }, { 49,-5813 }, { 50,-5813 }, { 51,-5813 }, { 52,-5813 }, + { 53,-5813 }, { 54,-5813 }, { 55,-5813 }, { 56,-5813 }, { 57,-5813 }, + { 58,-5813 }, { 59,-5813 }, { 60,-5813 }, { 61,-5813 }, { 62,-5813 }, + { 63,-5813 }, { 64,-5813 }, { 65,-5813 }, { 66,-5813 }, { 67,-5813 }, + { 68,-5813 }, { 69,-5813 }, { 70,-5813 }, { 71,-5813 }, { 72,-5813 }, + { 73,-5813 }, { 74,-5813 }, { 75,-5813 }, { 76,-5813 }, { 77,-5813 }, + + { 78,-5813 }, { 79,-5813 }, { 80,-5813 }, { 81,-5813 }, { 82,-5813 }, + { 83,-5813 }, { 84,-5813 }, { 85,-5039 }, { 86,-5813 }, { 87,-5813 }, + { 88,-5813 }, { 89,-5813 }, { 90,-5813 }, { 91,-5813 }, { 92,-5813 }, + { 93,-5813 }, { 94,-5813 }, { 95,-5813 }, { 96,-5813 }, { 97,-5813 }, + { 98,-5813 }, { 99,-5813 }, { 100,-5813 }, { 101,-5813 }, { 102,-5813 }, + { 103,-5813 }, { 104,-5813 }, { 105,-5813 }, { 106,-5813 }, { 107,-5813 }, + { 108,-5813 }, { 109,-5813 }, { 110,-5813 }, { 111,-5813 }, { 112,-5813 }, + { 113,-5813 }, { 114,-5813 }, { 115,-5813 }, { 116,-5813 }, { 117,-5039 }, + { 118,-5813 }, { 119,-5813 }, { 120,-5813 }, { 121,-5813 }, { 122,-5813 }, + { 123,-5813 }, { 124,-5813 }, { 125,-5813 }, { 126,-5813 }, { 127,-5813 }, + + { 128,-5813 }, { 129,-5813 }, { 130,-5813 }, { 131,-5813 }, { 132,-5813 }, + { 133,-5813 }, { 134,-5813 }, { 135,-5813 }, { 136,-5813 }, { 137,-5813 }, + { 138,-5813 }, { 139,-5813 }, { 140,-5813 }, { 141,-5813 }, { 142,-5813 }, + { 143,-5813 }, { 144,-5813 }, { 145,-5813 }, { 146,-5813 }, { 147,-5813 }, + { 148,-5813 }, { 149,-5813 }, { 150,-5813 }, { 151,-5813 }, { 152,-5813 }, + { 153,-5813 }, { 154,-5813 }, { 155,-5813 }, { 156,-5813 }, { 157,-5813 }, + { 158,-5813 }, { 159,-5813 }, { 160,-5813 }, { 161,-5813 }, { 162,-5813 }, + { 163,-5813 }, { 164,-5813 }, { 165,-5813 }, { 166,-5813 }, { 167,-5813 }, + { 168,-5813 }, { 169,-5813 }, { 170,-5813 }, { 171,-5813 }, { 172,-5813 }, + { 173,-5813 }, { 174,-5813 }, { 175,-5813 }, { 176,-5813 }, { 177,-5813 }, + + { 178,-5813 }, { 179,-5813 }, { 180,-5813 }, { 181,-5813 }, { 182,-5813 }, + { 183,-5813 }, { 184,-5813 }, { 185,-5813 }, { 186,-5813 }, { 187,-5813 }, + { 188,-5813 }, { 189,-5813 }, { 190,-5813 }, { 191,-5813 }, { 192,-5813 }, + { 193,-5813 }, { 194,-5813 }, { 195,-5813 }, { 196,-5813 }, { 197,-5813 }, + { 198,-5813 }, { 199,-5813 }, { 200,-5813 }, { 201,-5813 }, { 202,-5813 }, + { 203,-5813 }, { 204,-5813 }, { 205,-5813 }, { 206,-5813 }, { 207,-5813 }, + { 208,-5813 }, { 209,-5813 }, { 210,-5813 }, { 211,-5813 }, { 212,-5813 }, + { 213,-5813 }, { 214,-5813 }, { 215,-5813 }, { 216,-5813 }, { 217,-5813 }, + { 218,-5813 }, { 219,-5813 }, { 220,-5813 }, { 221,-5813 }, { 222,-5813 }, + { 223,-5813 }, { 224,-5813 }, { 225,-5813 }, { 226,-5813 }, { 227,-5813 }, + + { 228,-5813 }, { 229,-5813 }, { 230,-5813 }, { 231,-5813 }, { 232,-5813 }, + { 233,-5813 }, { 234,-5813 }, { 235,-5813 }, { 236,-5813 }, { 237,-5813 }, + { 238,-5813 }, { 239,-5813 }, { 240,-5813 }, { 241,-5813 }, { 242,-5813 }, + { 243,-5813 }, { 244,-5813 }, { 245,-5813 }, { 246,-5813 }, { 247,-5813 }, + { 248,-5813 }, { 249,-5813 }, { 250,-5813 }, { 251,-5813 }, { 252,-5813 }, + { 253,-5813 }, { 254,-5813 }, { 255,-5813 }, { 256,-5813 }, { 0, 48 }, + { 0,37350 }, { 1,-6071 }, { 2,-6071 }, { 3,-6071 }, { 4,-6071 }, + { 5,-6071 }, { 6,-6071 }, { 7,-6071 }, { 8,-6071 }, { 9,-5813 }, + { 10,-12457 }, { 11,-6071 }, { 12,-5813 }, { 13,-12457 }, { 14,-6071 }, + { 15,-6071 }, { 16,-6071 }, { 17,-6071 }, { 18,-6071 }, { 19,-6071 }, + + { 20,-6071 }, { 21,-6071 }, { 22,-6071 }, { 23,-6071 }, { 24,-6071 }, + { 25,-6071 }, { 26,-6071 }, { 27,-6071 }, { 28,-6071 }, { 29,-6071 }, + { 30,-6071 }, { 31,-6071 }, { 32,-5813 }, { 33,-6071 }, { 34,-6071 }, + { 35,-6071 }, { 36,-6071 }, { 37,-6071 }, { 38,-6071 }, { 39,-6071 }, + { 40,-6071 }, { 41,-6071 }, { 42,-6071 }, { 43,-6071 }, { 44,-6071 }, + { 45,-5555 }, { 46,-6071 }, { 47,-6071 }, { 48,-6071 }, { 49,-6071 }, + { 50,-6071 }, { 51,-6071 }, { 52,-6071 }, { 53,-6071 }, { 54,-6071 }, + { 55,-6071 }, { 56,-6071 }, { 57,-6071 }, { 58,-6071 }, { 59,-6071 }, + { 60,-6071 }, { 61,-6071 }, { 62,-6071 }, { 63,-6071 }, { 64,-6071 }, + { 65,-6071 }, { 66,-6071 }, { 67,-6071 }, { 68,-6071 }, { 69,-6071 }, + + { 70,-6071 }, { 71,-6071 }, { 72,-6071 }, { 73,-6071 }, { 74,-6071 }, + { 75,-6071 }, { 76,-6071 }, { 77,-6071 }, { 78,-6071 }, { 79,-6071 }, + { 80,-6071 }, { 81,-6071 }, { 82,-6071 }, { 83,2930 }, { 84,-6071 }, + { 85,-5297 }, { 86,-6071 }, { 87,-6071 }, { 88,-6071 }, { 89,-6071 }, + { 90,-6071 }, { 91,-6071 }, { 92,-6071 }, { 93,-6071 }, { 94,-6071 }, + { 95,-6071 }, { 96,-6071 }, { 97,-6071 }, { 98,-6071 }, { 99,-6071 }, + { 100,-6071 }, { 101,-6071 }, { 102,-6071 }, { 103,-6071 }, { 104,-6071 }, + { 105,-6071 }, { 106,-6071 }, { 107,-6071 }, { 108,-6071 }, { 109,-6071 }, + { 110,-6071 }, { 111,-6071 }, { 112,-6071 }, { 113,-6071 }, { 114,-6071 }, + { 115,2930 }, { 116,-6071 }, { 117,-5297 }, { 118,-6071 }, { 119,-6071 }, + + { 120,-6071 }, { 121,-6071 }, { 122,-6071 }, { 123,-6071 }, { 124,-6071 }, + { 125,-6071 }, { 126,-6071 }, { 127,-6071 }, { 128,-6071 }, { 129,-6071 }, + { 130,-6071 }, { 131,-6071 }, { 132,-6071 }, { 133,-6071 }, { 134,-6071 }, + { 135,-6071 }, { 136,-6071 }, { 137,-6071 }, { 138,-6071 }, { 139,-6071 }, + { 140,-6071 }, { 141,-6071 }, { 142,-6071 }, { 143,-6071 }, { 144,-6071 }, + { 145,-6071 }, { 146,-6071 }, { 147,-6071 }, { 148,-6071 }, { 149,-6071 }, + { 150,-6071 }, { 151,-6071 }, { 152,-6071 }, { 153,-6071 }, { 154,-6071 }, + { 155,-6071 }, { 156,-6071 }, { 157,-6071 }, { 158,-6071 }, { 159,-6071 }, + { 160,-6071 }, { 161,-6071 }, { 162,-6071 }, { 163,-6071 }, { 164,-6071 }, + { 165,-6071 }, { 166,-6071 }, { 167,-6071 }, { 168,-6071 }, { 169,-6071 }, + + { 170,-6071 }, { 171,-6071 }, { 172,-6071 }, { 173,-6071 }, { 174,-6071 }, + { 175,-6071 }, { 176,-6071 }, { 177,-6071 }, { 178,-6071 }, { 179,-6071 }, + { 180,-6071 }, { 181,-6071 }, { 182,-6071 }, { 183,-6071 }, { 184,-6071 }, + { 185,-6071 }, { 186,-6071 }, { 187,-6071 }, { 188,-6071 }, { 189,-6071 }, + { 190,-6071 }, { 191,-6071 }, { 192,-6071 }, { 193,-6071 }, { 194,-6071 }, + { 195,-6071 }, { 196,-6071 }, { 197,-6071 }, { 198,-6071 }, { 199,-6071 }, + { 200,-6071 }, { 201,-6071 }, { 202,-6071 }, { 203,-6071 }, { 204,-6071 }, + { 205,-6071 }, { 206,-6071 }, { 207,-6071 }, { 208,-6071 }, { 209,-6071 }, + { 210,-6071 }, { 211,-6071 }, { 212,-6071 }, { 213,-6071 }, { 214,-6071 }, + { 215,-6071 }, { 216,-6071 }, { 217,-6071 }, { 218,-6071 }, { 219,-6071 }, + + { 220,-6071 }, { 221,-6071 }, { 222,-6071 }, { 223,-6071 }, { 224,-6071 }, + { 225,-6071 }, { 226,-6071 }, { 227,-6071 }, { 228,-6071 }, { 229,-6071 }, + { 230,-6071 }, { 231,-6071 }, { 232,-6071 }, { 233,-6071 }, { 234,-6071 }, + { 235,-6071 }, { 236,-6071 }, { 237,-6071 }, { 238,-6071 }, { 239,-6071 }, + { 240,-6071 }, { 241,-6071 }, { 242,-6071 }, { 243,-6071 }, { 244,-6071 }, + { 245,-6071 }, { 246,-6071 }, { 247,-6071 }, { 248,-6071 }, { 249,-6071 }, + { 250,-6071 }, { 251,-6071 }, { 252,-6071 }, { 253,-6071 }, { 254,-6071 }, + { 255,-6071 }, { 256,-6071 }, { 0, 24 }, { 0,37092 }, { 1, 0 }, + { 2, 0 }, { 3, 0 }, { 4, 0 }, { 5, 0 }, { 6, 0 }, + { 7, 0 }, { 8, 0 }, { 9, 258 }, { 10, 516 }, { 11, 0 }, + + { 12, 258 }, { 13, 516 }, { 14, 0 }, { 15, 0 }, { 16, 0 }, + { 17, 0 }, { 18, 0 }, { 19, 0 }, { 20, 0 }, { 21, 0 }, + { 22, 0 }, { 23, 0 }, { 24, 0 }, { 25, 0 }, { 26, 0 }, + { 27, 0 }, { 28, 0 }, { 29, 0 }, { 30, 0 }, { 31, 0 }, + { 32, 258 }, { 33, 0 }, { 34, 0 }, { 35, 0 }, { 36, 0 }, + { 37, 0 }, { 38, 0 }, { 39, 0 }, { 40, 0 }, { 41, 0 }, + { 42, 0 }, { 43, 0 }, { 44, 0 }, { 45, 635 }, { 46, 0 }, + { 47, 0 }, { 48, 0 }, { 49, 0 }, { 50, 0 }, { 51, 0 }, + { 52, 0 }, { 53, 0 }, { 54, 0 }, { 55, 0 }, { 56, 0 }, + { 57, 0 }, { 58, 0 }, { 59, 0 }, { 60, 0 }, { 61, 0 }, + + { 62, 0 }, { 63, 0 }, { 64, 0 }, { 65, 0 }, { 66, 0 }, + { 67, 0 }, { 68, 0 }, { 69, 0 }, { 70, 0 }, { 71, 0 }, + { 72, 0 }, { 73, 0 }, { 74, 0 }, { 75, 0 }, { 76, 0 }, + { 77, 0 }, { 78, 0 }, { 79, 0 }, { 80, 0 }, { 81, 0 }, + { 82, 0 }, { 83, 0 }, { 84, 0 }, { 85, 893 }, { 86, 0 }, + { 87, 0 }, { 88, 0 }, { 89, 0 }, { 90, 0 }, { 91, 0 }, + { 92, 0 }, { 93, 0 }, { 94, 0 }, { 95, 0 }, { 96, 0 }, + { 97, 0 }, { 98, 0 }, { 99, 0 }, { 100, 0 }, { 101, 0 }, + { 102, 0 }, { 103, 0 }, { 104, 0 }, { 105, 0 }, { 106, 0 }, + { 107, 0 }, { 108, 0 }, { 109, 0 }, { 110, 0 }, { 111, 0 }, + + { 112, 0 }, { 113, 0 }, { 114, 0 }, { 115, 0 }, { 116, 0 }, + { 117, 893 }, { 118, 0 }, { 119, 0 }, { 120, 0 }, { 121, 0 }, + { 122, 0 }, { 123, 0 }, { 124, 0 }, { 125, 0 }, { 126, 0 }, + { 127, 0 }, { 128, 0 }, { 129, 0 }, { 130, 0 }, { 131, 0 }, + { 132, 0 }, { 133, 0 }, { 134, 0 }, { 135, 0 }, { 136, 0 }, + { 137, 0 }, { 138, 0 }, { 139, 0 }, { 140, 0 }, { 141, 0 }, + { 142, 0 }, { 143, 0 }, { 144, 0 }, { 145, 0 }, { 146, 0 }, + { 147, 0 }, { 148, 0 }, { 149, 0 }, { 150, 0 }, { 151, 0 }, + { 152, 0 }, { 153, 0 }, { 154, 0 }, { 155, 0 }, { 156, 0 }, + { 157, 0 }, { 158, 0 }, { 159, 0 }, { 160, 0 }, { 161, 0 }, + + { 162, 0 }, { 163, 0 }, { 164, 0 }, { 165, 0 }, { 166, 0 }, + { 167, 0 }, { 168, 0 }, { 169, 0 }, { 170, 0 }, { 171, 0 }, + { 172, 0 }, { 173, 0 }, { 174, 0 }, { 175, 0 }, { 176, 0 }, + { 177, 0 }, { 178, 0 }, { 179, 0 }, { 180, 0 }, { 181, 0 }, + { 182, 0 }, { 183, 0 }, { 184, 0 }, { 185, 0 }, { 186, 0 }, + { 187, 0 }, { 188, 0 }, { 189, 0 }, { 190, 0 }, { 191, 0 }, + { 192, 0 }, { 193, 0 }, { 194, 0 }, { 195, 0 }, { 196, 0 }, + { 197, 0 }, { 198, 0 }, { 199, 0 }, { 200, 0 }, { 201, 0 }, + { 202, 0 }, { 203, 0 }, { 204, 0 }, { 205, 0 }, { 206, 0 }, + { 207, 0 }, { 208, 0 }, { 209, 0 }, { 210, 0 }, { 211, 0 }, + + { 212, 0 }, { 213, 0 }, { 214, 0 }, { 215, 0 }, { 216, 0 }, + { 217, 0 }, { 218, 0 }, { 219, 0 }, { 220, 0 }, { 221, 0 }, + { 222, 0 }, { 223, 0 }, { 224, 0 }, { 225, 0 }, { 226, 0 }, + { 227, 0 }, { 228, 0 }, { 229, 0 }, { 230, 0 }, { 231, 0 }, + { 232, 0 }, { 233, 0 }, { 234, 0 }, { 235, 0 }, { 236, 0 }, + { 237, 0 }, { 238, 0 }, { 239, 0 }, { 240, 0 }, { 241, 0 }, + { 242, 0 }, { 243, 0 }, { 244, 0 }, { 245, 0 }, { 246, 0 }, + { 247, 0 }, { 248, 0 }, { 249, 0 }, { 250, 0 }, { 251, 0 }, + { 252, 0 }, { 253, 0 }, { 254, 0 }, { 255, 0 }, { 256, 0 }, + { 0, 24 }, { 0,36834 }, { 1,-258 }, { 2,-258 }, { 3,-258 }, + + { 4,-258 }, { 5,-258 }, { 6,-258 }, { 7,-258 }, { 8,-258 }, + { 9, 0 }, { 10, 258 }, { 11,-258 }, { 12, 0 }, { 13, 258 }, + { 14,-258 }, { 15,-258 }, { 16,-258 }, { 17,-258 }, { 18,-258 }, + { 19,-258 }, { 20,-258 }, { 21,-258 }, { 22,-258 }, { 23,-258 }, + { 24,-258 }, { 25,-258 }, { 26,-258 }, { 27,-258 }, { 28,-258 }, + { 29,-258 }, { 30,-258 }, { 31,-258 }, { 32, 0 }, { 33,-258 }, + { 34,-258 }, { 35,-258 }, { 36,-258 }, { 37,-258 }, { 38,-258 }, + { 39,-258 }, { 40,-258 }, { 41,-258 }, { 42,-258 }, { 43,-258 }, + { 44,-258 }, { 45, 377 }, { 46,-258 }, { 47,-258 }, { 48,-258 }, + { 49,-258 }, { 50,-258 }, { 51,-258 }, { 52,-258 }, { 53,-258 }, + + { 54,-258 }, { 55,-258 }, { 56,-258 }, { 57,-258 }, { 58,-258 }, + { 59,-258 }, { 60,-258 }, { 61,-258 }, { 62,-258 }, { 63,-258 }, + { 64,-258 }, { 65,-258 }, { 66,-258 }, { 67,-258 }, { 68,-258 }, + { 69,-258 }, { 70,-258 }, { 71,-258 }, { 72,-258 }, { 73,-258 }, + { 74,-258 }, { 75,-258 }, { 76,-258 }, { 77,-258 }, { 78,-258 }, + { 79,-258 }, { 80,-258 }, { 81,-258 }, { 82,-258 }, { 83,-258 }, + { 84,-258 }, { 85, 635 }, { 86,-258 }, { 87,-258 }, { 88,-258 }, + { 89,-258 }, { 90,-258 }, { 91,-258 }, { 92,-258 }, { 93,-258 }, + { 94,-258 }, { 95,-258 }, { 96,-258 }, { 97,-258 }, { 98,-258 }, + { 99,-258 }, { 100,-258 }, { 101,-258 }, { 102,-258 }, { 103,-258 }, + + { 104,-258 }, { 105,-258 }, { 106,-258 }, { 107,-258 }, { 108,-258 }, + { 109,-258 }, { 110,-258 }, { 111,-258 }, { 112,-258 }, { 113,-258 }, + { 114,-258 }, { 115,-258 }, { 116,-258 }, { 117, 635 }, { 118,-258 }, + { 119,-258 }, { 120,-258 }, { 121,-258 }, { 122,-258 }, { 123,-258 }, + { 124,-258 }, { 125,-258 }, { 126,-258 }, { 127,-258 }, { 128,-258 }, + { 129,-258 }, { 130,-258 }, { 131,-258 }, { 132,-258 }, { 133,-258 }, + { 134,-258 }, { 135,-258 }, { 136,-258 }, { 137,-258 }, { 138,-258 }, + { 139,-258 }, { 140,-258 }, { 141,-258 }, { 142,-258 }, { 143,-258 }, + { 144,-258 }, { 145,-258 }, { 146,-258 }, { 147,-258 }, { 148,-258 }, + { 149,-258 }, { 150,-258 }, { 151,-258 }, { 152,-258 }, { 153,-258 }, + + { 154,-258 }, { 155,-258 }, { 156,-258 }, { 157,-258 }, { 158,-258 }, + { 159,-258 }, { 160,-258 }, { 161,-258 }, { 162,-258 }, { 163,-258 }, + { 164,-258 }, { 165,-258 }, { 166,-258 }, { 167,-258 }, { 168,-258 }, + { 169,-258 }, { 170,-258 }, { 171,-258 }, { 172,-258 }, { 173,-258 }, + { 174,-258 }, { 175,-258 }, { 176,-258 }, { 177,-258 }, { 178,-258 }, + { 179,-258 }, { 180,-258 }, { 181,-258 }, { 182,-258 }, { 183,-258 }, + { 184,-258 }, { 185,-258 }, { 186,-258 }, { 187,-258 }, { 188,-258 }, + { 189,-258 }, { 190,-258 }, { 191,-258 }, { 192,-258 }, { 193,-258 }, + { 194,-258 }, { 195,-258 }, { 196,-258 }, { 197,-258 }, { 198,-258 }, + { 199,-258 }, { 200,-258 }, { 201,-258 }, { 202,-258 }, { 203,-258 }, + + { 204,-258 }, { 205,-258 }, { 206,-258 }, { 207,-258 }, { 208,-258 }, + { 209,-258 }, { 210,-258 }, { 211,-258 }, { 212,-258 }, { 213,-258 }, + { 214,-258 }, { 215,-258 }, { 216,-258 }, { 217,-258 }, { 218,-258 }, + { 219,-258 }, { 220,-258 }, { 221,-258 }, { 222,-258 }, { 223,-258 }, + { 224,-258 }, { 225,-258 }, { 226,-258 }, { 227,-258 }, { 228,-258 }, + { 229,-258 }, { 230,-258 }, { 231,-258 }, { 232,-258 }, { 233,-258 }, + { 234,-258 }, { 235,-258 }, { 236,-258 }, { 237,-258 }, { 238,-258 }, + { 239,-258 }, { 240,-258 }, { 241,-258 }, { 242,-258 }, { 243,-258 }, + { 244,-258 }, { 245,-258 }, { 246,-258 }, { 247,-258 }, { 248,-258 }, + { 249,-258 }, { 250,-258 }, { 251,-258 }, { 252,-258 }, { 253,-258 }, + + { 254,-258 }, { 255,-258 }, { 256,-258 }, { 0, 24 }, { 0,36576 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 9,-10572 }, { 10,-10572 }, + { 0, 0 }, { 12,-10572 }, { 13,-10572 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 32,-10572 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 39,-20785 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 45,-20519 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 85,-21024 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 117,-21024 }, { 0, 24 }, { 0,36457 }, { 1,-635 }, + { 2,-635 }, { 3,-635 }, { 4,-635 }, { 5,-635 }, { 6,-635 }, + { 7,-635 }, { 8,-635 }, { 9,-377 }, { 10,-119 }, { 11,-635 }, + { 12,-377 }, { 13,-119 }, { 14,-635 }, { 15,-635 }, { 16,-635 }, + { 17,-635 }, { 18,-635 }, { 19,-635 }, { 20,-635 }, { 21,-635 }, + { 22,-635 }, { 23,-635 }, { 24,-635 }, { 25,-635 }, { 26,-635 }, + + { 27,-635 }, { 28,-635 }, { 29,-635 }, { 30,-635 }, { 31,-635 }, + { 32,-377 }, { 33,-635 }, { 34,-635 }, { 35,-635 }, { 36,-635 }, + { 37,-635 }, { 38,-635 }, { 39,-635 }, { 40,-635 }, { 41,-635 }, + { 42,-635 }, { 43,-635 }, { 44,-635 }, { 45,2295 }, { 46,-635 }, + { 47,-635 }, { 48,-635 }, { 49,-635 }, { 50,-635 }, { 51,-635 }, + { 52,-635 }, { 53,-635 }, { 54,-635 }, { 55,-635 }, { 56,-635 }, + { 57,-635 }, { 58,-635 }, { 59,-635 }, { 60,-635 }, { 61,-635 }, + { 62,-635 }, { 63,-635 }, { 64,-635 }, { 65,-635 }, { 66,-635 }, + { 67,-635 }, { 68,-635 }, { 69,-635 }, { 70,-635 }, { 71,-635 }, + { 72,-635 }, { 73,-635 }, { 74,-635 }, { 75,-635 }, { 76,-635 }, + + { 77,-635 }, { 78,-635 }, { 79,-635 }, { 80,-635 }, { 81,-635 }, + { 82,-635 }, { 83,-635 }, { 84,-635 }, { 85, 258 }, { 86,-635 }, + { 87,-635 }, { 88,-635 }, { 89,-635 }, { 90,-635 }, { 91,-635 }, + { 92,-635 }, { 93,-635 }, { 94,-635 }, { 95,-635 }, { 96,-635 }, + { 97,-635 }, { 98,-635 }, { 99,-635 }, { 100,-635 }, { 101,-635 }, + { 102,-635 }, { 103,-635 }, { 104,-635 }, { 105,-635 }, { 106,-635 }, + { 107,-635 }, { 108,-635 }, { 109,-635 }, { 110,-635 }, { 111,-635 }, + { 112,-635 }, { 113,-635 }, { 114,-635 }, { 115,-635 }, { 116,-635 }, + { 117, 258 }, { 118,-635 }, { 119,-635 }, { 120,-635 }, { 121,-635 }, + { 122,-635 }, { 123,-635 }, { 124,-635 }, { 125,-635 }, { 126,-635 }, + + { 127,-635 }, { 128,-635 }, { 129,-635 }, { 130,-635 }, { 131,-635 }, + { 132,-635 }, { 133,-635 }, { 134,-635 }, { 135,-635 }, { 136,-635 }, + { 137,-635 }, { 138,-635 }, { 139,-635 }, { 140,-635 }, { 141,-635 }, + { 142,-635 }, { 143,-635 }, { 144,-635 }, { 145,-635 }, { 146,-635 }, + { 147,-635 }, { 148,-635 }, { 149,-635 }, { 150,-635 }, { 151,-635 }, + { 152,-635 }, { 153,-635 }, { 154,-635 }, { 155,-635 }, { 156,-635 }, + { 157,-635 }, { 158,-635 }, { 159,-635 }, { 160,-635 }, { 161,-635 }, + { 162,-635 }, { 163,-635 }, { 164,-635 }, { 165,-635 }, { 166,-635 }, + { 167,-635 }, { 168,-635 }, { 169,-635 }, { 170,-635 }, { 171,-635 }, + { 172,-635 }, { 173,-635 }, { 174,-635 }, { 175,-635 }, { 176,-635 }, + + { 177,-635 }, { 178,-635 }, { 179,-635 }, { 180,-635 }, { 181,-635 }, + { 182,-635 }, { 183,-635 }, { 184,-635 }, { 185,-635 }, { 186,-635 }, + { 187,-635 }, { 188,-635 }, { 189,-635 }, { 190,-635 }, { 191,-635 }, + { 192,-635 }, { 193,-635 }, { 194,-635 }, { 195,-635 }, { 196,-635 }, + { 197,-635 }, { 198,-635 }, { 199,-635 }, { 200,-635 }, { 201,-635 }, + { 202,-635 }, { 203,-635 }, { 204,-635 }, { 205,-635 }, { 206,-635 }, + { 207,-635 }, { 208,-635 }, { 209,-635 }, { 210,-635 }, { 211,-635 }, + { 212,-635 }, { 213,-635 }, { 214,-635 }, { 215,-635 }, { 216,-635 }, + { 217,-635 }, { 218,-635 }, { 219,-635 }, { 220,-635 }, { 221,-635 }, + { 222,-635 }, { 223,-635 }, { 224,-635 }, { 225,-635 }, { 226,-635 }, + + { 227,-635 }, { 228,-635 }, { 229,-635 }, { 230,-635 }, { 231,-635 }, + { 232,-635 }, { 233,-635 }, { 234,-635 }, { 235,-635 }, { 236,-635 }, + { 237,-635 }, { 238,-635 }, { 239,-635 }, { 240,-635 }, { 241,-635 }, + { 242,-635 }, { 243,-635 }, { 244,-635 }, { 245,-635 }, { 246,-635 }, + { 247,-635 }, { 248,-635 }, { 249,-635 }, { 250,-635 }, { 251,-635 }, + { 252,-635 }, { 253,-635 }, { 254,-635 }, { 255,-635 }, { 256,-635 }, + { 0, 24 }, { 0,36199 }, { 1,-893 }, { 2,-893 }, { 3,-893 }, + { 4,-893 }, { 5,-893 }, { 6,-893 }, { 7,-893 }, { 8,-893 }, + { 9,-635 }, { 10,-377 }, { 11,-893 }, { 12,-635 }, { 13,-377 }, + { 14,-893 }, { 15,-893 }, { 16,-893 }, { 17,-893 }, { 18,-893 }, + + { 19,-893 }, { 20,-893 }, { 21,-893 }, { 22,-893 }, { 23,-893 }, + { 24,-893 }, { 25,-893 }, { 26,-893 }, { 27,-893 }, { 28,-893 }, + { 29,-893 }, { 30,-893 }, { 31,-893 }, { 32,-635 }, { 33,-893 }, + { 34,-893 }, { 35,-893 }, { 36,-893 }, { 37,-893 }, { 38,-893 }, + { 39,-893 }, { 40,-893 }, { 41,-893 }, { 42,-893 }, { 43,-893 }, + { 44,-893 }, { 45,-258 }, { 46,-893 }, { 47,-893 }, { 48,-893 }, + { 49,-893 }, { 50,-893 }, { 51,-893 }, { 52,-893 }, { 53,-893 }, + { 54,-893 }, { 55,-893 }, { 56,-893 }, { 57,-893 }, { 58,-893 }, + { 59,-893 }, { 60,-893 }, { 61,-893 }, { 62,-893 }, { 63,-893 }, + { 64,-893 }, { 65,-893 }, { 66,-893 }, { 67,-893 }, { 68,-893 }, + + { 69,2295 }, { 70,-893 }, { 71,-893 }, { 72,-893 }, { 73,-893 }, + { 74,-893 }, { 75,-893 }, { 76,-893 }, { 77,-893 }, { 78,-893 }, + { 79,-893 }, { 80,-893 }, { 81,-893 }, { 82,-893 }, { 83,-893 }, + { 84,-893 }, { 85, 0 }, { 86,-893 }, { 87,-893 }, { 88,-893 }, + { 89,-893 }, { 90,-893 }, { 91,-893 }, { 92,-893 }, { 93,-893 }, + { 94,-893 }, { 95,-893 }, { 96,-893 }, { 97,-893 }, { 98,-893 }, + { 99,-893 }, { 100,-893 }, { 101,2295 }, { 102,-893 }, { 103,-893 }, + { 104,-893 }, { 105,-893 }, { 106,-893 }, { 107,-893 }, { 108,-893 }, + { 109,-893 }, { 110,-893 }, { 111,-893 }, { 112,-893 }, { 113,-893 }, + { 114,-893 }, { 115,-893 }, { 116,-893 }, { 117, 0 }, { 118,-893 }, + + { 119,-893 }, { 120,-893 }, { 121,-893 }, { 122,-893 }, { 123,-893 }, + { 124,-893 }, { 125,-893 }, { 126,-893 }, { 127,-893 }, { 128,-893 }, + { 129,-893 }, { 130,-893 }, { 131,-893 }, { 132,-893 }, { 133,-893 }, + { 134,-893 }, { 135,-893 }, { 136,-893 }, { 137,-893 }, { 138,-893 }, + { 139,-893 }, { 140,-893 }, { 141,-893 }, { 142,-893 }, { 143,-893 }, + { 144,-893 }, { 145,-893 }, { 146,-893 }, { 147,-893 }, { 148,-893 }, + { 149,-893 }, { 150,-893 }, { 151,-893 }, { 152,-893 }, { 153,-893 }, + { 154,-893 }, { 155,-893 }, { 156,-893 }, { 157,-893 }, { 158,-893 }, + { 159,-893 }, { 160,-893 }, { 161,-893 }, { 162,-893 }, { 163,-893 }, + { 164,-893 }, { 165,-893 }, { 166,-893 }, { 167,-893 }, { 168,-893 }, + + { 169,-893 }, { 170,-893 }, { 171,-893 }, { 172,-893 }, { 173,-893 }, + { 174,-893 }, { 175,-893 }, { 176,-893 }, { 177,-893 }, { 178,-893 }, + { 179,-893 }, { 180,-893 }, { 181,-893 }, { 182,-893 }, { 183,-893 }, + { 184,-893 }, { 185,-893 }, { 186,-893 }, { 187,-893 }, { 188,-893 }, + { 189,-893 }, { 190,-893 }, { 191,-893 }, { 192,-893 }, { 193,-893 }, + { 194,-893 }, { 195,-893 }, { 196,-893 }, { 197,-893 }, { 198,-893 }, + { 199,-893 }, { 200,-893 }, { 201,-893 }, { 202,-893 }, { 203,-893 }, + { 204,-893 }, { 205,-893 }, { 206,-893 }, { 207,-893 }, { 208,-893 }, + { 209,-893 }, { 210,-893 }, { 211,-893 }, { 212,-893 }, { 213,-893 }, + { 214,-893 }, { 215,-893 }, { 216,-893 }, { 217,-893 }, { 218,-893 }, + + { 219,-893 }, { 220,-893 }, { 221,-893 }, { 222,-893 }, { 223,-893 }, + { 224,-893 }, { 225,-893 }, { 226,-893 }, { 227,-893 }, { 228,-893 }, + { 229,-893 }, { 230,-893 }, { 231,-893 }, { 232,-893 }, { 233,-893 }, + { 234,-893 }, { 235,-893 }, { 236,-893 }, { 237,-893 }, { 238,-893 }, + { 239,-893 }, { 240,-893 }, { 241,-893 }, { 242,-893 }, { 243,-893 }, + { 244,-893 }, { 245,-893 }, { 246,-893 }, { 247,-893 }, { 248,-893 }, + { 249,-893 }, { 250,-893 }, { 251,-893 }, { 252,-893 }, { 253,-893 }, + { 254,-893 }, { 255,-893 }, { 256,-893 }, { 0, 24 }, { 0,35941 }, + { 1,-6190 }, { 2,-6190 }, { 3,-6190 }, { 4,-6190 }, { 5,-6190 }, + { 6,-6190 }, { 7,-6190 }, { 8,-6190 }, { 9,-5932 }, { 10,-13845 }, + + { 11,-6190 }, { 12,-5932 }, { 13,-13845 }, { 14,-6190 }, { 15,-6190 }, + { 16,-6190 }, { 17,-6190 }, { 18,-6190 }, { 19,-6190 }, { 20,-6190 }, + { 21,-6190 }, { 22,-6190 }, { 23,-6190 }, { 24,-6190 }, { 25,-6190 }, + { 26,-6190 }, { 27,-6190 }, { 28,-6190 }, { 29,-6190 }, { 30,-6190 }, + { 31,-6190 }, { 32,-5932 }, { 33,-6190 }, { 34,-6190 }, { 35,-6190 }, + { 36,-6190 }, { 37,-6190 }, { 38,-6190 }, { 39,-6190 }, { 40,-6190 }, + { 41,-6190 }, { 42,-6190 }, { 43,-6190 }, { 44,-6190 }, { 45, 0 }, + { 46,-6190 }, { 47,-6190 }, { 48,-6190 }, { 49,-6190 }, { 50,-6190 }, + { 51,-6190 }, { 52,-6190 }, { 53,-6190 }, { 54,-6190 }, { 55,-6190 }, + { 56,-6190 }, { 57,-6190 }, { 58,-6190 }, { 59,-6190 }, { 60,-6190 }, + + { 61,-6190 }, { 62,-6190 }, { 63,-6190 }, { 64,-6190 }, { 65,-6190 }, + { 66,-6190 }, { 67,-6190 }, { 68,-6190 }, { 69,-6190 }, { 70,-6190 }, + { 71,-6190 }, { 72,-6190 }, { 73,-6190 }, { 74,-6190 }, { 75,-6190 }, + { 76,-6190 }, { 77,-6190 }, { 78,-6190 }, { 79,-6190 }, { 80,-6190 }, + { 81,-6190 }, { 82,-6190 }, { 83,-6190 }, { 84,-6190 }, { 85,-5416 }, + { 86,-6190 }, { 87,-6190 }, { 88,-6190 }, { 89,-6190 }, { 90,-6190 }, + { 91,-6190 }, { 92,-6190 }, { 93,-6190 }, { 94,-6190 }, { 95,-6190 }, + { 96,-6190 }, { 97,-6190 }, { 98,-6190 }, { 99,-6190 }, { 100,-6190 }, + { 101,-6190 }, { 102,-6190 }, { 103,-6190 }, { 104,-6190 }, { 105,-6190 }, + { 106,-6190 }, { 107,-6190 }, { 108,-6190 }, { 109,-6190 }, { 110,-6190 }, + + { 111,-6190 }, { 112,-6190 }, { 113,-6190 }, { 114,-6190 }, { 115,-6190 }, + { 116,-6190 }, { 117,-5416 }, { 118,-6190 }, { 119,-6190 }, { 120,-6190 }, + { 121,-6190 }, { 122,-6190 }, { 123,-6190 }, { 124,-6190 }, { 125,-6190 }, + { 126,-6190 }, { 127,-6190 }, { 128,-6190 }, { 129,-6190 }, { 130,-6190 }, + { 131,-6190 }, { 132,-6190 }, { 133,-6190 }, { 134,-6190 }, { 135,-6190 }, + { 136,-6190 }, { 137,-6190 }, { 138,-6190 }, { 139,-6190 }, { 140,-6190 }, + { 141,-6190 }, { 142,-6190 }, { 143,-6190 }, { 144,-6190 }, { 145,-6190 }, + { 146,-6190 }, { 147,-6190 }, { 148,-6190 }, { 149,-6190 }, { 150,-6190 }, + { 151,-6190 }, { 152,-6190 }, { 153,-6190 }, { 154,-6190 }, { 155,-6190 }, + { 156,-6190 }, { 157,-6190 }, { 158,-6190 }, { 159,-6190 }, { 160,-6190 }, + + { 161,-6190 }, { 162,-6190 }, { 163,-6190 }, { 164,-6190 }, { 165,-6190 }, + { 166,-6190 }, { 167,-6190 }, { 168,-6190 }, { 169,-6190 }, { 170,-6190 }, + { 171,-6190 }, { 172,-6190 }, { 173,-6190 }, { 174,-6190 }, { 175,-6190 }, + { 176,-6190 }, { 177,-6190 }, { 178,-6190 }, { 179,-6190 }, { 180,-6190 }, + { 181,-6190 }, { 182,-6190 }, { 183,-6190 }, { 184,-6190 }, { 185,-6190 }, + { 186,-6190 }, { 187,-6190 }, { 188,-6190 }, { 189,-6190 }, { 190,-6190 }, + { 191,-6190 }, { 192,-6190 }, { 193,-6190 }, { 194,-6190 }, { 195,-6190 }, + { 196,-6190 }, { 197,-6190 }, { 198,-6190 }, { 199,-6190 }, { 200,-6190 }, + { 201,-6190 }, { 202,-6190 }, { 203,-6190 }, { 204,-6190 }, { 205,-6190 }, + { 206,-6190 }, { 207,-6190 }, { 208,-6190 }, { 209,-6190 }, { 210,-6190 }, + + { 211,-6190 }, { 212,-6190 }, { 213,-6190 }, { 214,-6190 }, { 215,-6190 }, + { 216,-6190 }, { 217,-6190 }, { 218,-6190 }, { 219,-6190 }, { 220,-6190 }, + { 221,-6190 }, { 222,-6190 }, { 223,-6190 }, { 224,-6190 }, { 225,-6190 }, + { 226,-6190 }, { 227,-6190 }, { 228,-6190 }, { 229,-6190 }, { 230,-6190 }, + { 231,-6190 }, { 232,-6190 }, { 233,-6190 }, { 234,-6190 }, { 235,-6190 }, + { 236,-6190 }, { 237,-6190 }, { 238,-6190 }, { 239,-6190 }, { 240,-6190 }, + { 241,-6190 }, { 242,-6190 }, { 243,-6190 }, { 244,-6190 }, { 245,-6190 }, + { 246,-6190 }, { 247,-6190 }, { 248,-6190 }, { 249,-6190 }, { 250,-6190 }, + { 251,-6190 }, { 252,-6190 }, { 253,-6190 }, { 254,-6190 }, { 255,-6190 }, + { 256,-6190 }, { 0, 24 }, { 0,35683 }, { 1,-6448 }, { 2,-6448 }, + + { 3,-6448 }, { 4,-6448 }, { 5,-6448 }, { 6,-6448 }, { 7,-6448 }, + { 8,-6448 }, { 9,-6190 }, { 10,-14103 }, { 11,-6448 }, { 12,-6190 }, + { 13,-14103 }, { 14,-6448 }, { 15,-6448 }, { 16,-6448 }, { 17,-6448 }, + { 18,-6448 }, { 19,-6448 }, { 20,-6448 }, { 21,-6448 }, { 22,-6448 }, + { 23,-6448 }, { 24,-6448 }, { 25,-6448 }, { 26,-6448 }, { 27,-6448 }, + { 28,-6448 }, { 29,-6448 }, { 30,-6448 }, { 31,-6448 }, { 32,-6190 }, + { 33,-6448 }, { 34,-6448 }, { 35,-6448 }, { 36,-6448 }, { 37,-6448 }, + { 38,-6448 }, { 39,-6448 }, { 40,-6448 }, { 41,-6448 }, { 42,-6448 }, + { 43,-6448 }, { 44,-6448 }, { 45,-5932 }, { 46,-6448 }, { 47,-6448 }, + { 48,-6448 }, { 49,-6448 }, { 50,-6448 }, { 51,-6448 }, { 52,-6448 }, + + { 53,-6448 }, { 54,-6448 }, { 55,-6448 }, { 56,-6448 }, { 57,-6448 }, + { 58,-6448 }, { 59,-6448 }, { 60,-6448 }, { 61,-6448 }, { 62,-6448 }, + { 63,-6448 }, { 64,-6448 }, { 65,-6448 }, { 66,-6448 }, { 67,-6448 }, + { 68,-6448 }, { 69,-6448 }, { 70,-6448 }, { 71,-6448 }, { 72,-6448 }, + { 73,-6448 }, { 74,-6448 }, { 75,-6448 }, { 76,-6448 }, { 77,-6448 }, + { 78,-6448 }, { 79,-6448 }, { 80,-6448 }, { 81,-6448 }, { 82,-6448 }, + { 83,2037 }, { 84,-6448 }, { 85,-5674 }, { 86,-6448 }, { 87,-6448 }, + { 88,-6448 }, { 89,-6448 }, { 90,-6448 }, { 91,-6448 }, { 92,-6448 }, + { 93,-6448 }, { 94,-6448 }, { 95,-6448 }, { 96,-6448 }, { 97,-6448 }, + { 98,-6448 }, { 99,-6448 }, { 100,-6448 }, { 101,-6448 }, { 102,-6448 }, + + { 103,-6448 }, { 104,-6448 }, { 105,-6448 }, { 106,-6448 }, { 107,-6448 }, + { 108,-6448 }, { 109,-6448 }, { 110,-6448 }, { 111,-6448 }, { 112,-6448 }, + { 113,-6448 }, { 114,-6448 }, { 115,2037 }, { 116,-6448 }, { 117,-5674 }, + { 118,-6448 }, { 119,-6448 }, { 120,-6448 }, { 121,-6448 }, { 122,-6448 }, + { 123,-6448 }, { 124,-6448 }, { 125,-6448 }, { 126,-6448 }, { 127,-6448 }, + { 128,-6448 }, { 129,-6448 }, { 130,-6448 }, { 131,-6448 }, { 132,-6448 }, + { 133,-6448 }, { 134,-6448 }, { 135,-6448 }, { 136,-6448 }, { 137,-6448 }, + { 138,-6448 }, { 139,-6448 }, { 140,-6448 }, { 141,-6448 }, { 142,-6448 }, + { 143,-6448 }, { 144,-6448 }, { 145,-6448 }, { 146,-6448 }, { 147,-6448 }, + { 148,-6448 }, { 149,-6448 }, { 150,-6448 }, { 151,-6448 }, { 152,-6448 }, + + { 153,-6448 }, { 154,-6448 }, { 155,-6448 }, { 156,-6448 }, { 157,-6448 }, + { 158,-6448 }, { 159,-6448 }, { 160,-6448 }, { 161,-6448 }, { 162,-6448 }, + { 163,-6448 }, { 164,-6448 }, { 165,-6448 }, { 166,-6448 }, { 167,-6448 }, + { 168,-6448 }, { 169,-6448 }, { 170,-6448 }, { 171,-6448 }, { 172,-6448 }, + { 173,-6448 }, { 174,-6448 }, { 175,-6448 }, { 176,-6448 }, { 177,-6448 }, + { 178,-6448 }, { 179,-6448 }, { 180,-6448 }, { 181,-6448 }, { 182,-6448 }, + { 183,-6448 }, { 184,-6448 }, { 185,-6448 }, { 186,-6448 }, { 187,-6448 }, + { 188,-6448 }, { 189,-6448 }, { 190,-6448 }, { 191,-6448 }, { 192,-6448 }, + { 193,-6448 }, { 194,-6448 }, { 195,-6448 }, { 196,-6448 }, { 197,-6448 }, + { 198,-6448 }, { 199,-6448 }, { 200,-6448 }, { 201,-6448 }, { 202,-6448 }, + + { 203,-6448 }, { 204,-6448 }, { 205,-6448 }, { 206,-6448 }, { 207,-6448 }, + { 208,-6448 }, { 209,-6448 }, { 210,-6448 }, { 211,-6448 }, { 212,-6448 }, + { 213,-6448 }, { 214,-6448 }, { 215,-6448 }, { 216,-6448 }, { 217,-6448 }, + { 218,-6448 }, { 219,-6448 }, { 220,-6448 }, { 221,-6448 }, { 222,-6448 }, + { 223,-6448 }, { 224,-6448 }, { 225,-6448 }, { 226,-6448 }, { 227,-6448 }, + { 228,-6448 }, { 229,-6448 }, { 230,-6448 }, { 231,-6448 }, { 232,-6448 }, + { 233,-6448 }, { 234,-6448 }, { 235,-6448 }, { 236,-6448 }, { 237,-6448 }, + { 238,-6448 }, { 239,-6448 }, { 240,-6448 }, { 241,-6448 }, { 242,-6448 }, + { 243,-6448 }, { 244,-6448 }, { 245,-6448 }, { 246,-6448 }, { 247,-6448 }, + { 248,-6448 }, { 249,-6448 }, { 250,-6448 }, { 251,-6448 }, { 252,-6448 }, + + { 253,-6448 }, { 254,-6448 }, { 255,-6448 }, { 256,-6448 }, { 0, 33 }, + { 0,35425 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 33 }, { 0,35402 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 48,2037 }, { 49,2037 }, + { 50,2037 }, { 51,2037 }, { 52,2037 }, { 53,2037 }, { 54,2037 }, + { 55,2037 }, { 56,2037 }, { 57,2037 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 65,2037 }, { 66,2037 }, { 67,2037 }, { 68,2037 }, { 69,2037 }, + { 70,2037 }, { 48,-17883 }, { 49,-17883 }, { 50,-17883 }, { 51,-17883 }, + { 52,-17883 }, { 53,-17883 }, { 54,-17883 }, { 55,-17883 }, { 56,-17883 }, + { 57,-17883 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 65,-17883 }, { 66,-17883 }, + { 67,-17883 }, { 68,-17883 }, { 69,-17883 }, { 70,-17883 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 97,2037 }, { 98,2037 }, { 99,2037 }, + { 100,2037 }, { 101,2037 }, { 102,2037 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 97,-17883 }, { 98,-17883 }, { 99,-17883 }, { 100,-17883 }, { 101,-17883 }, + { 102,-17883 }, { 0, 9 }, { 0,35298 }, { 1,-5674 }, { 2,-5674 }, + { 3,-5674 }, { 4,-5674 }, { 5,-5674 }, { 6,-5674 }, { 7,-5674 }, + { 8,-5674 }, { 9,-5416 }, { 10,-5158 }, { 11,-5674 }, { 12,-5416 }, + { 13,-5158 }, { 14,-5674 }, { 15,-5674 }, { 16,-5674 }, { 17,-5674 }, + + { 18,-5674 }, { 19,-5674 }, { 20,-5674 }, { 21,-5674 }, { 22,-5674 }, + { 23,-5674 }, { 24,-5674 }, { 25,-5674 }, { 26,-5674 }, { 27,-5674 }, + { 28,-5674 }, { 29,-5674 }, { 30,-5674 }, { 31,-5674 }, { 32,-5416 }, + { 33,-5674 }, { 34,-5674 }, { 35,-5674 }, { 36,-5674 }, { 37,-5674 }, + { 38,-5674 }, { 39,-5674 }, { 40,-5674 }, { 41,-5674 }, { 42,-5674 }, + { 43,-5674 }, { 44,-5674 }, { 45, 0 }, { 46,-5674 }, { 47,-5674 }, + { 48,-5674 }, { 49,-5674 }, { 50,-5674 }, { 51,-5674 }, { 52,-5674 }, + { 53,-5674 }, { 54,-5674 }, { 55,-5674 }, { 56,-5674 }, { 57,-5674 }, + { 58,-5674 }, { 59,-5674 }, { 60,-5674 }, { 61,-5674 }, { 62,-5674 }, + { 63,-5674 }, { 64,-5674 }, { 65,-5674 }, { 66,-5674 }, { 67,-5674 }, + + { 68,-5674 }, { 69,-5674 }, { 70,-5674 }, { 71,-5674 }, { 72,-5674 }, + { 73,-5674 }, { 74,-5674 }, { 75,-5674 }, { 76,-5674 }, { 77,-5674 }, + { 78,-5674 }, { 79,-5674 }, { 80,-5674 }, { 81,-5674 }, { 82,-5674 }, + { 83,-5674 }, { 84,-5674 }, { 85,-5674 }, { 86,-5674 }, { 87,-5674 }, + { 88,-5674 }, { 89,-5674 }, { 90,-5674 }, { 91,-5674 }, { 92,-5674 }, + { 93,-5674 }, { 94,-5674 }, { 95,-5674 }, { 96,-5674 }, { 97,-5674 }, + { 98,-5674 }, { 99,-5674 }, { 100,-5674 }, { 101,-5674 }, { 102,-5674 }, + { 103,-5674 }, { 104,-5674 }, { 105,-5674 }, { 106,-5674 }, { 107,-5674 }, + { 108,-5674 }, { 109,-5674 }, { 110,-5674 }, { 111,-5674 }, { 112,-5674 }, + { 113,-5674 }, { 114,-5674 }, { 115,-5674 }, { 116,-5674 }, { 117,-5674 }, + + { 118,-5674 }, { 119,-5674 }, { 120,-5674 }, { 121,-5674 }, { 122,-5674 }, + { 123,-5674 }, { 124,-5674 }, { 125,-5674 }, { 126,-5674 }, { 127,-5674 }, + { 128,-5674 }, { 129,-5674 }, { 130,-5674 }, { 131,-5674 }, { 132,-5674 }, + { 133,-5674 }, { 134,-5674 }, { 135,-5674 }, { 136,-5674 }, { 137,-5674 }, + { 138,-5674 }, { 139,-5674 }, { 140,-5674 }, { 141,-5674 }, { 142,-5674 }, + { 143,-5674 }, { 144,-5674 }, { 145,-5674 }, { 146,-5674 }, { 147,-5674 }, + { 148,-5674 }, { 149,-5674 }, { 150,-5674 }, { 151,-5674 }, { 152,-5674 }, + { 153,-5674 }, { 154,-5674 }, { 155,-5674 }, { 156,-5674 }, { 157,-5674 }, + { 158,-5674 }, { 159,-5674 }, { 160,-5674 }, { 161,-5674 }, { 162,-5674 }, + { 163,-5674 }, { 164,-5674 }, { 165,-5674 }, { 166,-5674 }, { 167,-5674 }, + + { 168,-5674 }, { 169,-5674 }, { 170,-5674 }, { 171,-5674 }, { 172,-5674 }, + { 173,-5674 }, { 174,-5674 }, { 175,-5674 }, { 176,-5674 }, { 177,-5674 }, + { 178,-5674 }, { 179,-5674 }, { 180,-5674 }, { 181,-5674 }, { 182,-5674 }, + { 183,-5674 }, { 184,-5674 }, { 185,-5674 }, { 186,-5674 }, { 187,-5674 }, + { 188,-5674 }, { 189,-5674 }, { 190,-5674 }, { 191,-5674 }, { 192,-5674 }, + { 193,-5674 }, { 194,-5674 }, { 195,-5674 }, { 196,-5674 }, { 197,-5674 }, + { 198,-5674 }, { 199,-5674 }, { 200,-5674 }, { 201,-5674 }, { 202,-5674 }, + { 203,-5674 }, { 204,-5674 }, { 205,-5674 }, { 206,-5674 }, { 207,-5674 }, + { 208,-5674 }, { 209,-5674 }, { 210,-5674 }, { 211,-5674 }, { 212,-5674 }, + { 213,-5674 }, { 214,-5674 }, { 215,-5674 }, { 216,-5674 }, { 217,-5674 }, + + { 218,-5674 }, { 219,-5674 }, { 220,-5674 }, { 221,-5674 }, { 222,-5674 }, + { 223,-5674 }, { 224,-5674 }, { 225,-5674 }, { 226,-5674 }, { 227,-5674 }, + { 228,-5674 }, { 229,-5674 }, { 230,-5674 }, { 231,-5674 }, { 232,-5674 }, + { 233,-5674 }, { 234,-5674 }, { 235,-5674 }, { 236,-5674 }, { 237,-5674 }, + { 238,-5674 }, { 239,-5674 }, { 240,-5674 }, { 241,-5674 }, { 242,-5674 }, + { 243,-5674 }, { 244,-5674 }, { 245,-5674 }, { 246,-5674 }, { 247,-5674 }, + { 248,-5674 }, { 249,-5674 }, { 250,-5674 }, { 251,-5674 }, { 252,-5674 }, + { 253,-5674 }, { 254,-5674 }, { 255,-5674 }, { 256,-5674 }, { 0, 16 }, + { 0,35040 }, { 1,-4853 }, { 2,-4853 }, { 3,-4853 }, { 4,-4853 }, + { 5,-4853 }, { 6,-4853 }, { 7,-4853 }, { 8,-4853 }, { 9,-4595 }, + + { 10,-4337 }, { 11,-4853 }, { 12,-4595 }, { 13,-4337 }, { 14,-4853 }, + { 15,-4853 }, { 16,-4853 }, { 17,-4853 }, { 18,-4853 }, { 19,-4853 }, + { 20,-4853 }, { 21,-4853 }, { 22,-4853 }, { 23,-4853 }, { 24,-4853 }, + { 25,-4853 }, { 26,-4853 }, { 27,-4853 }, { 28,-4853 }, { 29,-4853 }, + { 30,-4853 }, { 31,-4853 }, { 32,-4595 }, { 33,-4853 }, { 34,-4853 }, + { 35,-4853 }, { 36,-4853 }, { 37,-4853 }, { 38,-4853 }, { 39,-4853 }, + { 40,-4853 }, { 41,-4853 }, { 42,-4853 }, { 43,-4853 }, { 44,-4853 }, + { 45, 0 }, { 46,-4853 }, { 47,-4853 }, { 48,-4853 }, { 49,-4853 }, + { 50,-4853 }, { 51,-4853 }, { 52,-4853 }, { 53,-4853 }, { 54,-4853 }, + { 55,-4853 }, { 56,-4853 }, { 57,-4853 }, { 58,-4853 }, { 59,-4853 }, + + { 60,-4853 }, { 61,-4853 }, { 62,-4853 }, { 63,-4853 }, { 64,-4853 }, + { 65,-4853 }, { 66,-4853 }, { 67,-4853 }, { 68,-4853 }, { 69,-4853 }, + { 70,-4853 }, { 71,-4853 }, { 72,-4853 }, { 73,-4853 }, { 74,-4853 }, + { 75,-4853 }, { 76,-4853 }, { 77,-4853 }, { 78,-4853 }, { 79,-4853 }, + { 80,-4853 }, { 81,-4853 }, { 82,-4853 }, { 83,-4853 }, { 84,-4853 }, + { 85,-4853 }, { 86,-4853 }, { 87,-4853 }, { 88,-4853 }, { 89,-4853 }, + { 90,-4853 }, { 91,-4853 }, { 92,-4853 }, { 93,-4853 }, { 94,-4853 }, + { 95,-4853 }, { 96,-4853 }, { 97,-4853 }, { 98,-4853 }, { 99,-4853 }, + { 100,-4853 }, { 101,-4853 }, { 102,-4853 }, { 103,-4853 }, { 104,-4853 }, + { 105,-4853 }, { 106,-4853 }, { 107,-4853 }, { 108,-4853 }, { 109,-4853 }, + + { 110,-4853 }, { 111,-4853 }, { 112,-4853 }, { 113,-4853 }, { 114,-4853 }, + { 115,-4853 }, { 116,-4853 }, { 117,-4853 }, { 118,-4853 }, { 119,-4853 }, + { 120,-4853 }, { 121,-4853 }, { 122,-4853 }, { 123,-4853 }, { 124,-4853 }, + { 125,-4853 }, { 126,-4853 }, { 127,-4853 }, { 128,-4853 }, { 129,-4853 }, + { 130,-4853 }, { 131,-4853 }, { 132,-4853 }, { 133,-4853 }, { 134,-4853 }, + { 135,-4853 }, { 136,-4853 }, { 137,-4853 }, { 138,-4853 }, { 139,-4853 }, + { 140,-4853 }, { 141,-4853 }, { 142,-4853 }, { 143,-4853 }, { 144,-4853 }, + { 145,-4853 }, { 146,-4853 }, { 147,-4853 }, { 148,-4853 }, { 149,-4853 }, + { 150,-4853 }, { 151,-4853 }, { 152,-4853 }, { 153,-4853 }, { 154,-4853 }, + { 155,-4853 }, { 156,-4853 }, { 157,-4853 }, { 158,-4853 }, { 159,-4853 }, + + { 160,-4853 }, { 161,-4853 }, { 162,-4853 }, { 163,-4853 }, { 164,-4853 }, + { 165,-4853 }, { 166,-4853 }, { 167,-4853 }, { 168,-4853 }, { 169,-4853 }, + { 170,-4853 }, { 171,-4853 }, { 172,-4853 }, { 173,-4853 }, { 174,-4853 }, + { 175,-4853 }, { 176,-4853 }, { 177,-4853 }, { 178,-4853 }, { 179,-4853 }, + { 180,-4853 }, { 181,-4853 }, { 182,-4853 }, { 183,-4853 }, { 184,-4853 }, + { 185,-4853 }, { 186,-4853 }, { 187,-4853 }, { 188,-4853 }, { 189,-4853 }, + { 190,-4853 }, { 191,-4853 }, { 192,-4853 }, { 193,-4853 }, { 194,-4853 }, + { 195,-4853 }, { 196,-4853 }, { 197,-4853 }, { 198,-4853 }, { 199,-4853 }, + { 200,-4853 }, { 201,-4853 }, { 202,-4853 }, { 203,-4853 }, { 204,-4853 }, + { 205,-4853 }, { 206,-4853 }, { 207,-4853 }, { 208,-4853 }, { 209,-4853 }, + + { 210,-4853 }, { 211,-4853 }, { 212,-4853 }, { 213,-4853 }, { 214,-4853 }, + { 215,-4853 }, { 216,-4853 }, { 217,-4853 }, { 218,-4853 }, { 219,-4853 }, + { 220,-4853 }, { 221,-4853 }, { 222,-4853 }, { 223,-4853 }, { 224,-4853 }, + { 225,-4853 }, { 226,-4853 }, { 227,-4853 }, { 228,-4853 }, { 229,-4853 }, + { 230,-4853 }, { 231,-4853 }, { 232,-4853 }, { 233,-4853 }, { 234,-4853 }, + { 235,-4853 }, { 236,-4853 }, { 237,-4853 }, { 238,-4853 }, { 239,-4853 }, + { 240,-4853 }, { 241,-4853 }, { 242,-4853 }, { 243,-4853 }, { 244,-4853 }, + { 245,-4853 }, { 246,-4853 }, { 247,-4853 }, { 248,-4853 }, { 249,-4853 }, + { 250,-4853 }, { 251,-4853 }, { 252,-4853 }, { 253,-4853 }, { 254,-4853 }, + { 255,-4853 }, { 256,-4853 }, { 0, 22 }, { 0,34782 }, { 1,-4032 }, + + { 2,-4032 }, { 3,-4032 }, { 4,-4032 }, { 5,-4032 }, { 6,-4032 }, + { 7,-4032 }, { 8,-4032 }, { 9,-3774 }, { 10,-3516 }, { 11,-4032 }, + { 12,-3774 }, { 13,-3516 }, { 14,-4032 }, { 15,-4032 }, { 16,-4032 }, + { 17,-4032 }, { 18,-4032 }, { 19,-4032 }, { 20,-4032 }, { 21,-4032 }, + { 22,-4032 }, { 23,-4032 }, { 24,-4032 }, { 25,-4032 }, { 26,-4032 }, + { 27,-4032 }, { 28,-4032 }, { 29,-4032 }, { 30,-4032 }, { 31,-4032 }, + { 32,-3774 }, { 33,-4032 }, { 34,-4032 }, { 35,-4032 }, { 36,-4032 }, + { 37,-4032 }, { 38,-4032 }, { 39,-4032 }, { 40,-4032 }, { 41,-4032 }, + { 42,-4032 }, { 43,-4032 }, { 44,-4032 }, { 45, 0 }, { 46,-4032 }, + { 47,-4032 }, { 48,-4032 }, { 49,-4032 }, { 50,-4032 }, { 51,-4032 }, + + { 52,-4032 }, { 53,-4032 }, { 54,-4032 }, { 55,-4032 }, { 56,-4032 }, + { 57,-4032 }, { 58,-4032 }, { 59,-4032 }, { 60,-4032 }, { 61,-4032 }, + { 62,-4032 }, { 63,-4032 }, { 64,-4032 }, { 65,-4032 }, { 66,-4032 }, + { 67,-4032 }, { 68,-4032 }, { 69,-4032 }, { 70,-4032 }, { 71,-4032 }, + { 72,-4032 }, { 73,-4032 }, { 74,-4032 }, { 75,-4032 }, { 76,-4032 }, + { 77,-4032 }, { 78,-4032 }, { 79,-4032 }, { 80,-4032 }, { 81,-4032 }, + { 82,-4032 }, { 83,-4032 }, { 84,-4032 }, { 85,-4032 }, { 86,-4032 }, + { 87,-4032 }, { 88,-4032 }, { 89,-4032 }, { 90,-4032 }, { 91,-4032 }, + { 92,-4032 }, { 93,-4032 }, { 94,-4032 }, { 95,-4032 }, { 96,-4032 }, + { 97,-4032 }, { 98,-4032 }, { 99,-4032 }, { 100,-4032 }, { 101,-4032 }, + + { 102,-4032 }, { 103,-4032 }, { 104,-4032 }, { 105,-4032 }, { 106,-4032 }, + { 107,-4032 }, { 108,-4032 }, { 109,-4032 }, { 110,-4032 }, { 111,-4032 }, + { 112,-4032 }, { 113,-4032 }, { 114,-4032 }, { 115,-4032 }, { 116,-4032 }, + { 117,-4032 }, { 118,-4032 }, { 119,-4032 }, { 120,-4032 }, { 121,-4032 }, + { 122,-4032 }, { 123,-4032 }, { 124,-4032 }, { 125,-4032 }, { 126,-4032 }, + { 127,-4032 }, { 128,-4032 }, { 129,-4032 }, { 130,-4032 }, { 131,-4032 }, + { 132,-4032 }, { 133,-4032 }, { 134,-4032 }, { 135,-4032 }, { 136,-4032 }, + { 137,-4032 }, { 138,-4032 }, { 139,-4032 }, { 140,-4032 }, { 141,-4032 }, + { 142,-4032 }, { 143,-4032 }, { 144,-4032 }, { 145,-4032 }, { 146,-4032 }, + { 147,-4032 }, { 148,-4032 }, { 149,-4032 }, { 150,-4032 }, { 151,-4032 }, + + { 152,-4032 }, { 153,-4032 }, { 154,-4032 }, { 155,-4032 }, { 156,-4032 }, + { 157,-4032 }, { 158,-4032 }, { 159,-4032 }, { 160,-4032 }, { 161,-4032 }, + { 162,-4032 }, { 163,-4032 }, { 164,-4032 }, { 165,-4032 }, { 166,-4032 }, + { 167,-4032 }, { 168,-4032 }, { 169,-4032 }, { 170,-4032 }, { 171,-4032 }, + { 172,-4032 }, { 173,-4032 }, { 174,-4032 }, { 175,-4032 }, { 176,-4032 }, + { 177,-4032 }, { 178,-4032 }, { 179,-4032 }, { 180,-4032 }, { 181,-4032 }, + { 182,-4032 }, { 183,-4032 }, { 184,-4032 }, { 185,-4032 }, { 186,-4032 }, + { 187,-4032 }, { 188,-4032 }, { 189,-4032 }, { 190,-4032 }, { 191,-4032 }, + { 192,-4032 }, { 193,-4032 }, { 194,-4032 }, { 195,-4032 }, { 196,-4032 }, + { 197,-4032 }, { 198,-4032 }, { 199,-4032 }, { 200,-4032 }, { 201,-4032 }, + + { 202,-4032 }, { 203,-4032 }, { 204,-4032 }, { 205,-4032 }, { 206,-4032 }, + { 207,-4032 }, { 208,-4032 }, { 209,-4032 }, { 210,-4032 }, { 211,-4032 }, + { 212,-4032 }, { 213,-4032 }, { 214,-4032 }, { 215,-4032 }, { 216,-4032 }, + { 217,-4032 }, { 218,-4032 }, { 219,-4032 }, { 220,-4032 }, { 221,-4032 }, + { 222,-4032 }, { 223,-4032 }, { 224,-4032 }, { 225,-4032 }, { 226,-4032 }, + { 227,-4032 }, { 228,-4032 }, { 229,-4032 }, { 230,-4032 }, { 231,-4032 }, + { 232,-4032 }, { 233,-4032 }, { 234,-4032 }, { 235,-4032 }, { 236,-4032 }, + { 237,-4032 }, { 238,-4032 }, { 239,-4032 }, { 240,-4032 }, { 241,-4032 }, + { 242,-4032 }, { 243,-4032 }, { 244,-4032 }, { 245,-4032 }, { 246,-4032 }, + { 247,-4032 }, { 248,-4032 }, { 249,-4032 }, { 250,-4032 }, { 251,-4032 }, + + { 252,-4032 }, { 253,-4032 }, { 254,-4032 }, { 255,-4032 }, { 256,-4032 }, + { 0, 33 }, { 0,34524 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 48,1159 }, + { 49,1159 }, { 50,1159 }, { 51,1159 }, { 52,1159 }, { 53,1159 }, + { 54,1159 }, { 55,1159 }, { 56,1159 }, { 57,1159 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 65,1159 }, { 66,1159 }, { 67,1159 }, { 68,1159 }, + { 69,1159 }, { 70,1159 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 97,1159 }, { 98,1159 }, + { 99,1159 }, { 100,1159 }, { 101,1159 }, { 102,1159 }, { 0, 48 }, + { 0,34420 }, { 1,-9001 }, { 2,-9001 }, { 3,-9001 }, { 4,-9001 }, + { 5,-9001 }, { 6,-9001 }, { 7,-9001 }, { 8,-9001 }, { 9,-8743 }, + { 10,-15387 }, { 11,-9001 }, { 12,-8743 }, { 13,-15387 }, { 14,-9001 }, + { 15,-9001 }, { 16,-9001 }, { 17,-9001 }, { 18,-9001 }, { 19,-9001 }, + { 20,-9001 }, { 21,-9001 }, { 22,-9001 }, { 23,-9001 }, { 24,-9001 }, + { 25,-9001 }, { 26,-9001 }, { 27,-9001 }, { 28,-9001 }, { 29,-9001 }, + { 30,-9001 }, { 31,-9001 }, { 32,-8743 }, { 33,-9001 }, { 34,-9001 }, + { 35,-9001 }, { 36,-9001 }, { 37,-9001 }, { 38,-9001 }, { 39,-9001 }, + + { 40,-9001 }, { 41,-9001 }, { 42,-9001 }, { 43,-9001 }, { 44,-9001 }, + { 45,-8485 }, { 46,-9001 }, { 47,-9001 }, { 48,-9001 }, { 49,-9001 }, + { 50,-9001 }, { 51,-9001 }, { 52,-9001 }, { 53,-9001 }, { 54,-9001 }, + { 55,-9001 }, { 56,-9001 }, { 57,-9001 }, { 58,-9001 }, { 59,-9001 }, + { 60,-9001 }, { 61,-9001 }, { 62,-9001 }, { 63,-9001 }, { 64,-9001 }, + { 65,-9001 }, { 66,-9001 }, { 67,1159 }, { 68,-9001 }, { 69,-9001 }, + { 70,-9001 }, { 71,-9001 }, { 72,-9001 }, { 73,-9001 }, { 74,-9001 }, + { 75,-9001 }, { 76,-9001 }, { 77,-9001 }, { 78,-9001 }, { 79,-9001 }, + { 80,-9001 }, { 81,-9001 }, { 82,-9001 }, { 83,-9001 }, { 84,-9001 }, + { 85,-8227 }, { 86,-9001 }, { 87,-9001 }, { 88,-9001 }, { 89,-9001 }, + + { 90,-9001 }, { 91,-9001 }, { 92,-9001 }, { 93,-9001 }, { 94,-9001 }, + { 95,-9001 }, { 96,-9001 }, { 97,-9001 }, { 98,-9001 }, { 99,1159 }, + { 100,-9001 }, { 101,-9001 }, { 102,-9001 }, { 103,-9001 }, { 104,-9001 }, + { 105,-9001 }, { 106,-9001 }, { 107,-9001 }, { 108,-9001 }, { 109,-9001 }, + { 110,-9001 }, { 111,-9001 }, { 112,-9001 }, { 113,-9001 }, { 114,-9001 }, + { 115,-9001 }, { 116,-9001 }, { 117,-8227 }, { 118,-9001 }, { 119,-9001 }, + { 120,-9001 }, { 121,-9001 }, { 122,-9001 }, { 123,-9001 }, { 124,-9001 }, + { 125,-9001 }, { 126,-9001 }, { 127,-9001 }, { 128,-9001 }, { 129,-9001 }, + { 130,-9001 }, { 131,-9001 }, { 132,-9001 }, { 133,-9001 }, { 134,-9001 }, + { 135,-9001 }, { 136,-9001 }, { 137,-9001 }, { 138,-9001 }, { 139,-9001 }, + + { 140,-9001 }, { 141,-9001 }, { 142,-9001 }, { 143,-9001 }, { 144,-9001 }, + { 145,-9001 }, { 146,-9001 }, { 147,-9001 }, { 148,-9001 }, { 149,-9001 }, + { 150,-9001 }, { 151,-9001 }, { 152,-9001 }, { 153,-9001 }, { 154,-9001 }, + { 155,-9001 }, { 156,-9001 }, { 157,-9001 }, { 158,-9001 }, { 159,-9001 }, + { 160,-9001 }, { 161,-9001 }, { 162,-9001 }, { 163,-9001 }, { 164,-9001 }, + { 165,-9001 }, { 166,-9001 }, { 167,-9001 }, { 168,-9001 }, { 169,-9001 }, + { 170,-9001 }, { 171,-9001 }, { 172,-9001 }, { 173,-9001 }, { 174,-9001 }, + { 175,-9001 }, { 176,-9001 }, { 177,-9001 }, { 178,-9001 }, { 179,-9001 }, + { 180,-9001 }, { 181,-9001 }, { 182,-9001 }, { 183,-9001 }, { 184,-9001 }, + { 185,-9001 }, { 186,-9001 }, { 187,-9001 }, { 188,-9001 }, { 189,-9001 }, + + { 190,-9001 }, { 191,-9001 }, { 192,-9001 }, { 193,-9001 }, { 194,-9001 }, + { 195,-9001 }, { 196,-9001 }, { 197,-9001 }, { 198,-9001 }, { 199,-9001 }, + { 200,-9001 }, { 201,-9001 }, { 202,-9001 }, { 203,-9001 }, { 204,-9001 }, + { 205,-9001 }, { 206,-9001 }, { 207,-9001 }, { 208,-9001 }, { 209,-9001 }, + { 210,-9001 }, { 211,-9001 }, { 212,-9001 }, { 213,-9001 }, { 214,-9001 }, + { 215,-9001 }, { 216,-9001 }, { 217,-9001 }, { 218,-9001 }, { 219,-9001 }, + { 220,-9001 }, { 221,-9001 }, { 222,-9001 }, { 223,-9001 }, { 224,-9001 }, + { 225,-9001 }, { 226,-9001 }, { 227,-9001 }, { 228,-9001 }, { 229,-9001 }, + { 230,-9001 }, { 231,-9001 }, { 232,-9001 }, { 233,-9001 }, { 234,-9001 }, + { 235,-9001 }, { 236,-9001 }, { 237,-9001 }, { 238,-9001 }, { 239,-9001 }, + + { 240,-9001 }, { 241,-9001 }, { 242,-9001 }, { 243,-9001 }, { 244,-9001 }, + { 245,-9001 }, { 246,-9001 }, { 247,-9001 }, { 248,-9001 }, { 249,-9001 }, + { 250,-9001 }, { 251,-9001 }, { 252,-9001 }, { 253,-9001 }, { 254,-9001 }, + { 255,-9001 }, { 256,-9001 }, { 0, 24 }, { 0,34162 }, { 1,-2930 }, + { 2,-2930 }, { 3,-2930 }, { 4,-2930 }, { 5,-2930 }, { 6,-2930 }, + { 7,-2930 }, { 8,-2930 }, { 9,-2672 }, { 10,-2414 }, { 11,-2930 }, + { 12,-2672 }, { 13,-2414 }, { 14,-2930 }, { 15,-2930 }, { 16,-2930 }, + { 17,-2930 }, { 18,-2930 }, { 19,-2930 }, { 20,-2930 }, { 21,-2930 }, + { 22,-2930 }, { 23,-2930 }, { 24,-2930 }, { 25,-2930 }, { 26,-2930 }, + { 27,-2930 }, { 28,-2930 }, { 29,-2930 }, { 30,-2930 }, { 31,-2930 }, + + { 32,-2672 }, { 33,-2930 }, { 34,-2930 }, { 35,-2930 }, { 36,-2930 }, + { 37,-2930 }, { 38,-2930 }, { 39,-2930 }, { 40,-2930 }, { 41,-2930 }, + { 42,-2930 }, { 43,-2930 }, { 44,-2930 }, { 45, 0 }, { 46,-2930 }, + { 47,-2930 }, { 48,-2930 }, { 49,-2930 }, { 50,-2930 }, { 51,-2930 }, + { 52,-2930 }, { 53,-2930 }, { 54,-2930 }, { 55,-2930 }, { 56,-2930 }, + { 57,-2930 }, { 58,-2930 }, { 59,-2930 }, { 60,-2930 }, { 61,-2930 }, + { 62,-2930 }, { 63,-2930 }, { 64,-2930 }, { 65,-2930 }, { 66,-2930 }, + { 67,-2930 }, { 68,-2930 }, { 69,-2930 }, { 70,-2930 }, { 71,-2930 }, + { 72,-2930 }, { 73,-2930 }, { 74,-2930 }, { 75,-2930 }, { 76,-2930 }, + { 77,-2930 }, { 78,-2930 }, { 79,-2930 }, { 80,-2930 }, { 81,-2930 }, + + { 82,-2930 }, { 83,-2930 }, { 84,-2930 }, { 85,-2037 }, { 86,-2930 }, + { 87,-2930 }, { 88,-2930 }, { 89,-2930 }, { 90,-2930 }, { 91,-2930 }, + { 92,-2930 }, { 93,-2930 }, { 94,-2930 }, { 95,-2930 }, { 96,-2930 }, + { 97,-2930 }, { 98,-2930 }, { 99,-2930 }, { 100,-2930 }, { 101,-2930 }, + { 102,-2930 }, { 103,-2930 }, { 104,-2930 }, { 105,-2930 }, { 106,-2930 }, + { 107,-2930 }, { 108,-2930 }, { 109,-2930 }, { 110,-2930 }, { 111,-2930 }, + { 112,-2930 }, { 113,-2930 }, { 114,-2930 }, { 115,-2930 }, { 116,-2930 }, + { 117,-2037 }, { 118,-2930 }, { 119,-2930 }, { 120,-2930 }, { 121,-2930 }, + { 122,-2930 }, { 123,-2930 }, { 124,-2930 }, { 125,-2930 }, { 126,-2930 }, + { 127,-2930 }, { 128,-2930 }, { 129,-2930 }, { 130,-2930 }, { 131,-2930 }, + + { 132,-2930 }, { 133,-2930 }, { 134,-2930 }, { 135,-2930 }, { 136,-2930 }, + { 137,-2930 }, { 138,-2930 }, { 139,-2930 }, { 140,-2930 }, { 141,-2930 }, + { 142,-2930 }, { 143,-2930 }, { 144,-2930 }, { 145,-2930 }, { 146,-2930 }, + { 147,-2930 }, { 148,-2930 }, { 149,-2930 }, { 150,-2930 }, { 151,-2930 }, + { 152,-2930 }, { 153,-2930 }, { 154,-2930 }, { 155,-2930 }, { 156,-2930 }, + { 157,-2930 }, { 158,-2930 }, { 159,-2930 }, { 160,-2930 }, { 161,-2930 }, + { 162,-2930 }, { 163,-2930 }, { 164,-2930 }, { 165,-2930 }, { 166,-2930 }, + { 167,-2930 }, { 168,-2930 }, { 169,-2930 }, { 170,-2930 }, { 171,-2930 }, + { 172,-2930 }, { 173,-2930 }, { 174,-2930 }, { 175,-2930 }, { 176,-2930 }, + { 177,-2930 }, { 178,-2930 }, { 179,-2930 }, { 180,-2930 }, { 181,-2930 }, + + { 182,-2930 }, { 183,-2930 }, { 184,-2930 }, { 185,-2930 }, { 186,-2930 }, + { 187,-2930 }, { 188,-2930 }, { 189,-2930 }, { 190,-2930 }, { 191,-2930 }, + { 192,-2930 }, { 193,-2930 }, { 194,-2930 }, { 195,-2930 }, { 196,-2930 }, + { 197,-2930 }, { 198,-2930 }, { 199,-2930 }, { 200,-2930 }, { 201,-2930 }, + { 202,-2930 }, { 203,-2930 }, { 204,-2930 }, { 205,-2930 }, { 206,-2930 }, + { 207,-2930 }, { 208,-2930 }, { 209,-2930 }, { 210,-2930 }, { 211,-2930 }, + { 212,-2930 }, { 213,-2930 }, { 214,-2930 }, { 215,-2930 }, { 216,-2930 }, + { 217,-2930 }, { 218,-2930 }, { 219,-2930 }, { 220,-2930 }, { 221,-2930 }, + { 222,-2930 }, { 223,-2930 }, { 224,-2930 }, { 225,-2930 }, { 226,-2930 }, + { 227,-2930 }, { 228,-2930 }, { 229,-2930 }, { 230,-2930 }, { 231,-2930 }, + + { 232,-2930 }, { 233,-2930 }, { 234,-2930 }, { 235,-2930 }, { 236,-2930 }, + { 237,-2930 }, { 238,-2930 }, { 239,-2930 }, { 240,-2930 }, { 241,-2930 }, + { 242,-2930 }, { 243,-2930 }, { 244,-2930 }, { 245,-2930 }, { 246,-2930 }, + { 247,-2930 }, { 248,-2930 }, { 249,-2930 }, { 250,-2930 }, { 251,-2930 }, + { 252,-2930 }, { 253,-2930 }, { 254,-2930 }, { 255,-2930 }, { 256,-2930 }, + { 0, 24 }, { 0,33904 }, { 1,-3188 }, { 2,-3188 }, { 3,-3188 }, + { 4,-3188 }, { 5,-3188 }, { 6,-3188 }, { 7,-3188 }, { 8,-3188 }, + { 9,-2930 }, { 10,-2672 }, { 11,-3188 }, { 12,-2930 }, { 13,-2672 }, + { 14,-3188 }, { 15,-3188 }, { 16,-3188 }, { 17,-3188 }, { 18,-3188 }, + { 19,-3188 }, { 20,-3188 }, { 21,-3188 }, { 22,-3188 }, { 23,-3188 }, + + { 24,-3188 }, { 25,-3188 }, { 26,-3188 }, { 27,-3188 }, { 28,-3188 }, + { 29,-3188 }, { 30,-3188 }, { 31,-3188 }, { 32,-2930 }, { 33,-3188 }, + { 34,-3188 }, { 35,-3188 }, { 36,-3188 }, { 37,-3188 }, { 38,-3188 }, + { 39,-3188 }, { 40,-3188 }, { 41,-3188 }, { 42,-3188 }, { 43,-3188 }, + { 44,-3188 }, { 45,-2553 }, { 46,-3188 }, { 47,-3188 }, { 48,-3188 }, + { 49,-3188 }, { 50,-3188 }, { 51,-3188 }, { 52,-3188 }, { 53,-3188 }, + { 54,-3188 }, { 55,-3188 }, { 56,-3188 }, { 57,-3188 }, { 58,-3188 }, + { 59,-3188 }, { 60,-3188 }, { 61,-3188 }, { 62,-3188 }, { 63,-3188 }, + { 64,-3188 }, { 65,-3188 }, { 66,-3188 }, { 67,-3188 }, { 68,-3188 }, + { 69,-3188 }, { 70,-3188 }, { 71,-3188 }, { 72,-3188 }, { 73,-3188 }, + + { 74,-3188 }, { 75,-3188 }, { 76,-3188 }, { 77,-3188 }, { 78,-3188 }, + { 79,-3188 }, { 80,-3188 }, { 81,-3188 }, { 82,-3188 }, { 83, 901 }, + { 84,-3188 }, { 85,-2295 }, { 86,-3188 }, { 87,-3188 }, { 88,-3188 }, + { 89,-3188 }, { 90,-3188 }, { 91,-3188 }, { 92,-3188 }, { 93,-3188 }, + { 94,-3188 }, { 95,-3188 }, { 96,-3188 }, { 97,-3188 }, { 98,-3188 }, + { 99,-3188 }, { 100,-3188 }, { 101,-3188 }, { 102,-3188 }, { 103,-3188 }, + { 104,-3188 }, { 105,-3188 }, { 106,-3188 }, { 107,-3188 }, { 108,-3188 }, + { 109,-3188 }, { 110,-3188 }, { 111,-3188 }, { 112,-3188 }, { 113,-3188 }, + { 114,-3188 }, { 115, 901 }, { 116,-3188 }, { 117,-2295 }, { 118,-3188 }, + { 119,-3188 }, { 120,-3188 }, { 121,-3188 }, { 122,-3188 }, { 123,-3188 }, + + { 124,-3188 }, { 125,-3188 }, { 126,-3188 }, { 127,-3188 }, { 128,-3188 }, + { 129,-3188 }, { 130,-3188 }, { 131,-3188 }, { 132,-3188 }, { 133,-3188 }, + { 134,-3188 }, { 135,-3188 }, { 136,-3188 }, { 137,-3188 }, { 138,-3188 }, + { 139,-3188 }, { 140,-3188 }, { 141,-3188 }, { 142,-3188 }, { 143,-3188 }, + { 144,-3188 }, { 145,-3188 }, { 146,-3188 }, { 147,-3188 }, { 148,-3188 }, + { 149,-3188 }, { 150,-3188 }, { 151,-3188 }, { 152,-3188 }, { 153,-3188 }, + { 154,-3188 }, { 155,-3188 }, { 156,-3188 }, { 157,-3188 }, { 158,-3188 }, + { 159,-3188 }, { 160,-3188 }, { 161,-3188 }, { 162,-3188 }, { 163,-3188 }, + { 164,-3188 }, { 165,-3188 }, { 166,-3188 }, { 167,-3188 }, { 168,-3188 }, + { 169,-3188 }, { 170,-3188 }, { 171,-3188 }, { 172,-3188 }, { 173,-3188 }, + + { 174,-3188 }, { 175,-3188 }, { 176,-3188 }, { 177,-3188 }, { 178,-3188 }, + { 179,-3188 }, { 180,-3188 }, { 181,-3188 }, { 182,-3188 }, { 183,-3188 }, + { 184,-3188 }, { 185,-3188 }, { 186,-3188 }, { 187,-3188 }, { 188,-3188 }, + { 189,-3188 }, { 190,-3188 }, { 191,-3188 }, { 192,-3188 }, { 193,-3188 }, + { 194,-3188 }, { 195,-3188 }, { 196,-3188 }, { 197,-3188 }, { 198,-3188 }, + { 199,-3188 }, { 200,-3188 }, { 201,-3188 }, { 202,-3188 }, { 203,-3188 }, + { 204,-3188 }, { 205,-3188 }, { 206,-3188 }, { 207,-3188 }, { 208,-3188 }, + { 209,-3188 }, { 210,-3188 }, { 211,-3188 }, { 212,-3188 }, { 213,-3188 }, + { 214,-3188 }, { 215,-3188 }, { 216,-3188 }, { 217,-3188 }, { 218,-3188 }, + { 219,-3188 }, { 220,-3188 }, { 221,-3188 }, { 222,-3188 }, { 223,-3188 }, + + { 224,-3188 }, { 225,-3188 }, { 226,-3188 }, { 227,-3188 }, { 228,-3188 }, + { 229,-3188 }, { 230,-3188 }, { 231,-3188 }, { 232,-3188 }, { 233,-3188 }, + { 234,-3188 }, { 235,-3188 }, { 236,-3188 }, { 237,-3188 }, { 238,-3188 }, + { 239,-3188 }, { 240,-3188 }, { 241,-3188 }, { 242,-3188 }, { 243,-3188 }, + { 244,-3188 }, { 245,-3188 }, { 246,-3188 }, { 247,-3188 }, { 248,-3188 }, + { 249,-3188 }, { 250,-3188 }, { 251,-3188 }, { 252,-3188 }, { 253,-3188 }, + { 254,-3188 }, { 255,-3188 }, { 256,-3188 }, { 0, 24 }, { 0,33646 }, + { 1,-8485 }, { 2,-8485 }, { 3,-8485 }, { 4,-8485 }, { 5,-8485 }, + { 6,-8485 }, { 7,-8485 }, { 8,-8485 }, { 9,-8227 }, { 10,-16140 }, + { 11,-8485 }, { 12,-8227 }, { 13,-16140 }, { 14,-8485 }, { 15,-8485 }, + + { 16,-8485 }, { 17,-8485 }, { 18,-8485 }, { 19,-8485 }, { 20,-8485 }, + { 21,-8485 }, { 22,-8485 }, { 23,-8485 }, { 24,-8485 }, { 25,-8485 }, + { 26,-8485 }, { 27,-8485 }, { 28,-8485 }, { 29,-8485 }, { 30,-8485 }, + { 31,-8485 }, { 32,-8227 }, { 33,-8485 }, { 34,-8485 }, { 35,-8485 }, + { 36,-8485 }, { 37,-8485 }, { 38,-8485 }, { 39,-8485 }, { 40,-8485 }, + { 41,-8485 }, { 42,-8485 }, { 43,-8485 }, { 44,-8485 }, { 45,-7969 }, + { 46,-8485 }, { 47,-8485 }, { 48,-8485 }, { 49,-8485 }, { 50,-8485 }, + { 51,-8485 }, { 52,-8485 }, { 53,-8485 }, { 54,-8485 }, { 55,-8485 }, + { 56,-8485 }, { 57,-8485 }, { 58,-8485 }, { 59,-8485 }, { 60,-8485 }, + { 61,-8485 }, { 62,-8485 }, { 63,-8485 }, { 64,-8485 }, { 65,-8485 }, + + { 66,-8485 }, { 67, 901 }, { 68,-8485 }, { 69,-8485 }, { 70,-8485 }, + { 71,-8485 }, { 72,-8485 }, { 73,-8485 }, { 74,-8485 }, { 75,-8485 }, + { 76,-8485 }, { 77,-8485 }, { 78,-8485 }, { 79,-8485 }, { 80,-8485 }, + { 81,-8485 }, { 82,-8485 }, { 83,-8485 }, { 84,-8485 }, { 85,-7711 }, + { 86,-8485 }, { 87,-8485 }, { 88,-8485 }, { 89,-8485 }, { 90,-8485 }, + { 91,-8485 }, { 92,-8485 }, { 93,-8485 }, { 94,-8485 }, { 95,-8485 }, + { 96,-8485 }, { 97,-8485 }, { 98,-8485 }, { 99, 901 }, { 100,-8485 }, + { 101,-8485 }, { 102,-8485 }, { 103,-8485 }, { 104,-8485 }, { 105,-8485 }, + { 106,-8485 }, { 107,-8485 }, { 108,-8485 }, { 109,-8485 }, { 110,-8485 }, + { 111,-8485 }, { 112,-8485 }, { 113,-8485 }, { 114,-8485 }, { 115,-8485 }, + + { 116,-8485 }, { 117,-7711 }, { 118,-8485 }, { 119,-8485 }, { 120,-8485 }, + { 121,-8485 }, { 122,-8485 }, { 123,-8485 }, { 124,-8485 }, { 125,-8485 }, + { 126,-8485 }, { 127,-8485 }, { 128,-8485 }, { 129,-8485 }, { 130,-8485 }, + { 131,-8485 }, { 132,-8485 }, { 133,-8485 }, { 134,-8485 }, { 135,-8485 }, + { 136,-8485 }, { 137,-8485 }, { 138,-8485 }, { 139,-8485 }, { 140,-8485 }, + { 141,-8485 }, { 142,-8485 }, { 143,-8485 }, { 144,-8485 }, { 145,-8485 }, + { 146,-8485 }, { 147,-8485 }, { 148,-8485 }, { 149,-8485 }, { 150,-8485 }, + { 151,-8485 }, { 152,-8485 }, { 153,-8485 }, { 154,-8485 }, { 155,-8485 }, + { 156,-8485 }, { 157,-8485 }, { 158,-8485 }, { 159,-8485 }, { 160,-8485 }, + { 161,-8485 }, { 162,-8485 }, { 163,-8485 }, { 164,-8485 }, { 165,-8485 }, + + { 166,-8485 }, { 167,-8485 }, { 168,-8485 }, { 169,-8485 }, { 170,-8485 }, + { 171,-8485 }, { 172,-8485 }, { 173,-8485 }, { 174,-8485 }, { 175,-8485 }, + { 176,-8485 }, { 177,-8485 }, { 178,-8485 }, { 179,-8485 }, { 180,-8485 }, + { 181,-8485 }, { 182,-8485 }, { 183,-8485 }, { 184,-8485 }, { 185,-8485 }, + { 186,-8485 }, { 187,-8485 }, { 188,-8485 }, { 189,-8485 }, { 190,-8485 }, + { 191,-8485 }, { 192,-8485 }, { 193,-8485 }, { 194,-8485 }, { 195,-8485 }, + { 196,-8485 }, { 197,-8485 }, { 198,-8485 }, { 199,-8485 }, { 200,-8485 }, + { 201,-8485 }, { 202,-8485 }, { 203,-8485 }, { 204,-8485 }, { 205,-8485 }, + { 206,-8485 }, { 207,-8485 }, { 208,-8485 }, { 209,-8485 }, { 210,-8485 }, + { 211,-8485 }, { 212,-8485 }, { 213,-8485 }, { 214,-8485 }, { 215,-8485 }, + + { 216,-8485 }, { 217,-8485 }, { 218,-8485 }, { 219,-8485 }, { 220,-8485 }, + { 221,-8485 }, { 222,-8485 }, { 223,-8485 }, { 224,-8485 }, { 225,-8485 }, + { 226,-8485 }, { 227,-8485 }, { 228,-8485 }, { 229,-8485 }, { 230,-8485 }, + { 231,-8485 }, { 232,-8485 }, { 233,-8485 }, { 234,-8485 }, { 235,-8485 }, + { 236,-8485 }, { 237,-8485 }, { 238,-8485 }, { 239,-8485 }, { 240,-8485 }, + { 241,-8485 }, { 242,-8485 }, { 243,-8485 }, { 244,-8485 }, { 245,-8485 }, + { 246,-8485 }, { 247,-8485 }, { 248,-8485 }, { 249,-8485 }, { 250,-8485 }, + { 251,-8485 }, { 252,-8485 }, { 253,-8485 }, { 254,-8485 }, { 255,-8485 }, + { 256,-8485 }, { 0, 33 }, { 0,33388 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 33 }, + { 0,33365 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 48, 901 }, { 49, 901 }, { 50, 901 }, { 51, 901 }, { 52, 901 }, + { 53, 901 }, { 54, 901 }, { 55, 901 }, { 56, 901 }, { 57, 901 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 65, 901 }, { 66, 901 }, { 67, 901 }, + { 68, 901 }, { 69, 901 }, { 70, 901 }, { 48, 901 }, { 49, 901 }, + { 50, 901 }, { 51, 901 }, { 52, 901 }, { 53, 901 }, { 54, 901 }, + { 55, 901 }, { 56, 901 }, { 57, 901 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 65, 901 }, { 66, 901 }, { 67, 901 }, { 68, 901 }, { 69, 901 }, + { 70, 901 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 97, 901 }, + { 98, 901 }, { 99, 901 }, { 100, 901 }, { 101, 901 }, { 102, 901 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 97, 901 }, { 98, 901 }, { 99, 901 }, + { 100, 901 }, { 101, 901 }, { 102, 901 }, { 0, 48 }, { 0,33261 }, + { 1,-10160 }, { 2,-10160 }, { 3,-10160 }, { 4,-10160 }, { 5,-10160 }, + { 6,-10160 }, { 7,-10160 }, { 8,-10160 }, { 9,-9902 }, { 10,-16546 }, + { 11,-10160 }, { 12,-9902 }, { 13,-16546 }, { 14,-10160 }, { 15,-10160 }, + { 16,-10160 }, { 17,-10160 }, { 18,-10160 }, { 19,-10160 }, { 20,-10160 }, + { 21,-10160 }, { 22,-10160 }, { 23,-10160 }, { 24,-10160 }, { 25,-10160 }, + { 26,-10160 }, { 27,-10160 }, { 28,-10160 }, { 29,-10160 }, { 30,-10160 }, + + { 31,-10160 }, { 32,-9902 }, { 33,-10160 }, { 34,-10160 }, { 35,-10160 }, + { 36,-10160 }, { 37,-10160 }, { 38,-10160 }, { 39,-10160 }, { 40,-10160 }, + { 41,-10160 }, { 42,-10160 }, { 43,-10160 }, { 44,-10160 }, { 45,-9644 }, + { 46,-10160 }, { 47,-10160 }, { 48,-10160 }, { 49,-10160 }, { 50,-10160 }, + { 51,-10160 }, { 52,-10160 }, { 53,-10160 }, { 54,-10160 }, { 55,-10160 }, + { 56,-10160 }, { 57,-10160 }, { 58,-10160 }, { 59,-10160 }, { 60,-10160 }, + { 61,-10160 }, { 62,-10160 }, { 63,-10160 }, { 64,-10160 }, { 65, 901 }, + { 66,-10160 }, { 67,-10160 }, { 68,-10160 }, { 69,-10160 }, { 70,-10160 }, + { 71,-10160 }, { 72,-10160 }, { 73,-10160 }, { 74,-10160 }, { 75,-10160 }, + { 76,-10160 }, { 77,-10160 }, { 78,-10160 }, { 79,-10160 }, { 80,-10160 }, + + { 81,-10160 }, { 82,-10160 }, { 83,-10160 }, { 84,-10160 }, { 85,-9386 }, + { 86,-10160 }, { 87,-10160 }, { 88,-10160 }, { 89,-10160 }, { 90,-10160 }, + { 91,-10160 }, { 92,-10160 }, { 93,-10160 }, { 94,-10160 }, { 95,-10160 }, + { 96,-10160 }, { 97, 901 }, { 98,-10160 }, { 99,-10160 }, { 100,-10160 }, + { 101,-10160 }, { 102,-10160 }, { 103,-10160 }, { 104,-10160 }, { 105,-10160 }, + { 106,-10160 }, { 107,-10160 }, { 108,-10160 }, { 109,-10160 }, { 110,-10160 }, + { 111,-10160 }, { 112,-10160 }, { 113,-10160 }, { 114,-10160 }, { 115,-10160 }, + { 116,-10160 }, { 117,-9386 }, { 118,-10160 }, { 119,-10160 }, { 120,-10160 }, + { 121,-10160 }, { 122,-10160 }, { 123,-10160 }, { 124,-10160 }, { 125,-10160 }, + { 126,-10160 }, { 127,-10160 }, { 128,-10160 }, { 129,-10160 }, { 130,-10160 }, + + { 131,-10160 }, { 132,-10160 }, { 133,-10160 }, { 134,-10160 }, { 135,-10160 }, + { 136,-10160 }, { 137,-10160 }, { 138,-10160 }, { 139,-10160 }, { 140,-10160 }, + { 141,-10160 }, { 142,-10160 }, { 143,-10160 }, { 144,-10160 }, { 145,-10160 }, + { 146,-10160 }, { 147,-10160 }, { 148,-10160 }, { 149,-10160 }, { 150,-10160 }, + { 151,-10160 }, { 152,-10160 }, { 153,-10160 }, { 154,-10160 }, { 155,-10160 }, + { 156,-10160 }, { 157,-10160 }, { 158,-10160 }, { 159,-10160 }, { 160,-10160 }, + { 161,-10160 }, { 162,-10160 }, { 163,-10160 }, { 164,-10160 }, { 165,-10160 }, + { 166,-10160 }, { 167,-10160 }, { 168,-10160 }, { 169,-10160 }, { 170,-10160 }, + { 171,-10160 }, { 172,-10160 }, { 173,-10160 }, { 174,-10160 }, { 175,-10160 }, + { 176,-10160 }, { 177,-10160 }, { 178,-10160 }, { 179,-10160 }, { 180,-10160 }, + + { 181,-10160 }, { 182,-10160 }, { 183,-10160 }, { 184,-10160 }, { 185,-10160 }, + { 186,-10160 }, { 187,-10160 }, { 188,-10160 }, { 189,-10160 }, { 190,-10160 }, + { 191,-10160 }, { 192,-10160 }, { 193,-10160 }, { 194,-10160 }, { 195,-10160 }, + { 196,-10160 }, { 197,-10160 }, { 198,-10160 }, { 199,-10160 }, { 200,-10160 }, + { 201,-10160 }, { 202,-10160 }, { 203,-10160 }, { 204,-10160 }, { 205,-10160 }, + { 206,-10160 }, { 207,-10160 }, { 208,-10160 }, { 209,-10160 }, { 210,-10160 }, + { 211,-10160 }, { 212,-10160 }, { 213,-10160 }, { 214,-10160 }, { 215,-10160 }, + { 216,-10160 }, { 217,-10160 }, { 218,-10160 }, { 219,-10160 }, { 220,-10160 }, + { 221,-10160 }, { 222,-10160 }, { 223,-10160 }, { 224,-10160 }, { 225,-10160 }, + { 226,-10160 }, { 227,-10160 }, { 228,-10160 }, { 229,-10160 }, { 230,-10160 }, + + { 231,-10160 }, { 232,-10160 }, { 233,-10160 }, { 234,-10160 }, { 235,-10160 }, + { 236,-10160 }, { 237,-10160 }, { 238,-10160 }, { 239,-10160 }, { 240,-10160 }, + { 241,-10160 }, { 242,-10160 }, { 243,-10160 }, { 244,-10160 }, { 245,-10160 }, + { 246,-10160 }, { 247,-10160 }, { 248,-10160 }, { 249,-10160 }, { 250,-10160 }, + { 251,-10160 }, { 252,-10160 }, { 253,-10160 }, { 254,-10160 }, { 255,-10160 }, + { 256,-10160 }, { 0, 24 }, { 0,33003 }, { 1,-4089 }, { 2,-4089 }, + { 3,-4089 }, { 4,-4089 }, { 5,-4089 }, { 6,-4089 }, { 7,-4089 }, + { 8,-4089 }, { 9,-3831 }, { 10,-3573 }, { 11,-4089 }, { 12,-3831 }, + { 13,-3573 }, { 14,-4089 }, { 15,-4089 }, { 16,-4089 }, { 17,-4089 }, + { 18,-4089 }, { 19,-4089 }, { 20,-4089 }, { 21,-4089 }, { 22,-4089 }, + + { 23,-4089 }, { 24,-4089 }, { 25,-4089 }, { 26,-4089 }, { 27,-4089 }, + { 28,-4089 }, { 29,-4089 }, { 30,-4089 }, { 31,-4089 }, { 32,-3831 }, + { 33,-4089 }, { 34,-4089 }, { 35,-4089 }, { 36,-4089 }, { 37,-4089 }, + { 38,-4089 }, { 39,-4089 }, { 40,-4089 }, { 41,-4089 }, { 42,-4089 }, + { 43,-4089 }, { 44,-4089 }, { 45,-3454 }, { 46,-4089 }, { 47,-4089 }, + { 48,-4089 }, { 49,-4089 }, { 50,-4089 }, { 51,-4089 }, { 52,-4089 }, + { 53,-4089 }, { 54,-4089 }, { 55,-4089 }, { 56,-4089 }, { 57,-4089 }, + { 58,-4089 }, { 59,-4089 }, { 60,-4089 }, { 61,-4089 }, { 62,-4089 }, + { 63,-4089 }, { 64,-4089 }, { 65,-4089 }, { 66,-4089 }, { 67, 948 }, + { 68,-4089 }, { 69,-4089 }, { 70,-4089 }, { 71,-4089 }, { 72,-4089 }, + + { 73,-4089 }, { 74,-4089 }, { 75,-4089 }, { 76,-4089 }, { 77,-4089 }, + { 78,-4089 }, { 79,-4089 }, { 80,-4089 }, { 81,-4089 }, { 82,-4089 }, + { 83,-4089 }, { 84,-4089 }, { 85,-3196 }, { 86,-4089 }, { 87,-4089 }, + { 88,-4089 }, { 89,-4089 }, { 90,-4089 }, { 91,-4089 }, { 92,-4089 }, + { 93,-4089 }, { 94,-4089 }, { 95,-4089 }, { 96,-4089 }, { 97,-4089 }, + { 98,-4089 }, { 99, 948 }, { 100,-4089 }, { 101,-4089 }, { 102,-4089 }, + { 103,-4089 }, { 104,-4089 }, { 105,-4089 }, { 106,-4089 }, { 107,-4089 }, + { 108,-4089 }, { 109,-4089 }, { 110,-4089 }, { 111,-4089 }, { 112,-4089 }, + { 113,-4089 }, { 114,-4089 }, { 115,-4089 }, { 116,-4089 }, { 117,-3196 }, + { 118,-4089 }, { 119,-4089 }, { 120,-4089 }, { 121,-4089 }, { 122,-4089 }, + + { 123,-4089 }, { 124,-4089 }, { 125,-4089 }, { 126,-4089 }, { 127,-4089 }, + { 128,-4089 }, { 129,-4089 }, { 130,-4089 }, { 131,-4089 }, { 132,-4089 }, + { 133,-4089 }, { 134,-4089 }, { 135,-4089 }, { 136,-4089 }, { 137,-4089 }, + { 138,-4089 }, { 139,-4089 }, { 140,-4089 }, { 141,-4089 }, { 142,-4089 }, + { 143,-4089 }, { 144,-4089 }, { 145,-4089 }, { 146,-4089 }, { 147,-4089 }, + { 148,-4089 }, { 149,-4089 }, { 150,-4089 }, { 151,-4089 }, { 152,-4089 }, + { 153,-4089 }, { 154,-4089 }, { 155,-4089 }, { 156,-4089 }, { 157,-4089 }, + { 158,-4089 }, { 159,-4089 }, { 160,-4089 }, { 161,-4089 }, { 162,-4089 }, + { 163,-4089 }, { 164,-4089 }, { 165,-4089 }, { 166,-4089 }, { 167,-4089 }, + { 168,-4089 }, { 169,-4089 }, { 170,-4089 }, { 171,-4089 }, { 172,-4089 }, + + { 173,-4089 }, { 174,-4089 }, { 175,-4089 }, { 176,-4089 }, { 177,-4089 }, + { 178,-4089 }, { 179,-4089 }, { 180,-4089 }, { 181,-4089 }, { 182,-4089 }, + { 183,-4089 }, { 184,-4089 }, { 185,-4089 }, { 186,-4089 }, { 187,-4089 }, + { 188,-4089 }, { 189,-4089 }, { 190,-4089 }, { 191,-4089 }, { 192,-4089 }, + { 193,-4089 }, { 194,-4089 }, { 195,-4089 }, { 196,-4089 }, { 197,-4089 }, + { 198,-4089 }, { 199,-4089 }, { 200,-4089 }, { 201,-4089 }, { 202,-4089 }, + { 203,-4089 }, { 204,-4089 }, { 205,-4089 }, { 206,-4089 }, { 207,-4089 }, + { 208,-4089 }, { 209,-4089 }, { 210,-4089 }, { 211,-4089 }, { 212,-4089 }, + { 213,-4089 }, { 214,-4089 }, { 215,-4089 }, { 216,-4089 }, { 217,-4089 }, + { 218,-4089 }, { 219,-4089 }, { 220,-4089 }, { 221,-4089 }, { 222,-4089 }, + + { 223,-4089 }, { 224,-4089 }, { 225,-4089 }, { 226,-4089 }, { 227,-4089 }, + { 228,-4089 }, { 229,-4089 }, { 230,-4089 }, { 231,-4089 }, { 232,-4089 }, + { 233,-4089 }, { 234,-4089 }, { 235,-4089 }, { 236,-4089 }, { 237,-4089 }, + { 238,-4089 }, { 239,-4089 }, { 240,-4089 }, { 241,-4089 }, { 242,-4089 }, + { 243,-4089 }, { 244,-4089 }, { 245,-4089 }, { 246,-4089 }, { 247,-4089 }, + { 248,-4089 }, { 249,-4089 }, { 250,-4089 }, { 251,-4089 }, { 252,-4089 }, + { 253,-4089 }, { 254,-4089 }, { 255,-4089 }, { 256,-4089 }, { 0, 24 }, + { 0,32745 }, { 1,-9386 }, { 2,-9386 }, { 3,-9386 }, { 4,-9386 }, + { 5,-9386 }, { 6,-9386 }, { 7,-9386 }, { 8,-9386 }, { 9,-9128 }, + { 10,-17041 }, { 11,-9386 }, { 12,-9128 }, { 13,-17041 }, { 14,-9386 }, + + { 15,-9386 }, { 16,-9386 }, { 17,-9386 }, { 18,-9386 }, { 19,-9386 }, + { 20,-9386 }, { 21,-9386 }, { 22,-9386 }, { 23,-9386 }, { 24,-9386 }, + { 25,-9386 }, { 26,-9386 }, { 27,-9386 }, { 28,-9386 }, { 29,-9386 }, + { 30,-9386 }, { 31,-9386 }, { 32,-9128 }, { 33,-9386 }, { 34,-9386 }, + { 35,-9386 }, { 36,-9386 }, { 37,-9386 }, { 38,-9386 }, { 39,-9386 }, + { 40,-9386 }, { 41,-9386 }, { 42,-9386 }, { 43,-9386 }, { 44,-9386 }, + { 45,-8870 }, { 46,-9386 }, { 47,-9386 }, { 48,-9386 }, { 49,-9386 }, + { 50,-9386 }, { 51,-9386 }, { 52,-9386 }, { 53,-9386 }, { 54,-9386 }, + { 55,-9386 }, { 56,-9386 }, { 57,-9386 }, { 58,-9386 }, { 59,-9386 }, + { 60,-9386 }, { 61,-9386 }, { 62,-9386 }, { 63,-9386 }, { 64,-9386 }, + + { 65, 948 }, { 66,-9386 }, { 67,-9386 }, { 68,-9386 }, { 69,-9386 }, + { 70,-9386 }, { 71,-9386 }, { 72,-9386 }, { 73,-9386 }, { 74,-9386 }, + { 75,-9386 }, { 76,-9386 }, { 77,-9386 }, { 78,-9386 }, { 79,-9386 }, + { 80,-9386 }, { 81,-9386 }, { 82,-9386 }, { 83,-9386 }, { 84,-9386 }, + { 85,-8612 }, { 86,-9386 }, { 87,-9386 }, { 88,-9386 }, { 89,-9386 }, + { 90,-9386 }, { 91,-9386 }, { 92,-9386 }, { 93,-9386 }, { 94,-9386 }, + { 95,-9386 }, { 96,-9386 }, { 97, 948 }, { 98,-9386 }, { 99,-9386 }, + { 100,-9386 }, { 101,-9386 }, { 102,-9386 }, { 103,-9386 }, { 104,-9386 }, + { 105,-9386 }, { 106,-9386 }, { 107,-9386 }, { 108,-9386 }, { 109,-9386 }, + { 110,-9386 }, { 111,-9386 }, { 112,-9386 }, { 113,-9386 }, { 114,-9386 }, + + { 115,-9386 }, { 116,-9386 }, { 117,-8612 }, { 118,-9386 }, { 119,-9386 }, + { 120,-9386 }, { 121,-9386 }, { 122,-9386 }, { 123,-9386 }, { 124,-9386 }, + { 125,-9386 }, { 126,-9386 }, { 127,-9386 }, { 128,-9386 }, { 129,-9386 }, + { 130,-9386 }, { 131,-9386 }, { 132,-9386 }, { 133,-9386 }, { 134,-9386 }, + { 135,-9386 }, { 136,-9386 }, { 137,-9386 }, { 138,-9386 }, { 139,-9386 }, + { 140,-9386 }, { 141,-9386 }, { 142,-9386 }, { 143,-9386 }, { 144,-9386 }, + { 145,-9386 }, { 146,-9386 }, { 147,-9386 }, { 148,-9386 }, { 149,-9386 }, + { 150,-9386 }, { 151,-9386 }, { 152,-9386 }, { 153,-9386 }, { 154,-9386 }, + { 155,-9386 }, { 156,-9386 }, { 157,-9386 }, { 158,-9386 }, { 159,-9386 }, + { 160,-9386 }, { 161,-9386 }, { 162,-9386 }, { 163,-9386 }, { 164,-9386 }, + + { 165,-9386 }, { 166,-9386 }, { 167,-9386 }, { 168,-9386 }, { 169,-9386 }, + { 170,-9386 }, { 171,-9386 }, { 172,-9386 }, { 173,-9386 }, { 174,-9386 }, + { 175,-9386 }, { 176,-9386 }, { 177,-9386 }, { 178,-9386 }, { 179,-9386 }, + { 180,-9386 }, { 181,-9386 }, { 182,-9386 }, { 183,-9386 }, { 184,-9386 }, + { 185,-9386 }, { 186,-9386 }, { 187,-9386 }, { 188,-9386 }, { 189,-9386 }, + { 190,-9386 }, { 191,-9386 }, { 192,-9386 }, { 193,-9386 }, { 194,-9386 }, + { 195,-9386 }, { 196,-9386 }, { 197,-9386 }, { 198,-9386 }, { 199,-9386 }, + { 200,-9386 }, { 201,-9386 }, { 202,-9386 }, { 203,-9386 }, { 204,-9386 }, + { 205,-9386 }, { 206,-9386 }, { 207,-9386 }, { 208,-9386 }, { 209,-9386 }, + { 210,-9386 }, { 211,-9386 }, { 212,-9386 }, { 213,-9386 }, { 214,-9386 }, + + { 215,-9386 }, { 216,-9386 }, { 217,-9386 }, { 218,-9386 }, { 219,-9386 }, + { 220,-9386 }, { 221,-9386 }, { 222,-9386 }, { 223,-9386 }, { 224,-9386 }, + { 225,-9386 }, { 226,-9386 }, { 227,-9386 }, { 228,-9386 }, { 229,-9386 }, + { 230,-9386 }, { 231,-9386 }, { 232,-9386 }, { 233,-9386 }, { 234,-9386 }, + { 235,-9386 }, { 236,-9386 }, { 237,-9386 }, { 238,-9386 }, { 239,-9386 }, + { 240,-9386 }, { 241,-9386 }, { 242,-9386 }, { 243,-9386 }, { 244,-9386 }, + { 245,-9386 }, { 246,-9386 }, { 247,-9386 }, { 248,-9386 }, { 249,-9386 }, + { 250,-9386 }, { 251,-9386 }, { 252,-9386 }, { 253,-9386 }, { 254,-9386 }, + { 255,-9386 }, { 256,-9386 }, { 0, 33 }, { 0,32487 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 33 }, { 0,32464 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 48, 950 }, { 49, 950 }, { 50, 950 }, { 51, 950 }, + { 52, 950 }, { 53, 950 }, { 54, 950 }, { 55, 950 }, { 56, 950 }, + + { 57, 950 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 65, 950 }, { 66, 950 }, + { 67, 950 }, { 68, 950 }, { 69, 950 }, { 70, 950 }, { 48, 950 }, + { 49, 950 }, { 50, 950 }, { 51, 950 }, { 52, 950 }, { 53, 950 }, + { 54, 950 }, { 55, 950 }, { 56, 950 }, { 57, 950 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 65, 950 }, { 66, 950 }, { 67, 950 }, { 68, 950 }, + { 69, 950 }, { 70, 950 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 97, 950 }, { 98, 950 }, { 99, 950 }, { 100, 950 }, { 101, 950 }, + { 102, 950 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 97, 950 }, { 98, 950 }, + { 99, 950 }, { 100, 950 }, { 101, 950 }, { 102, 950 }, { 0, 48 }, + { 0,32360 }, { 1,-11061 }, { 2,-11061 }, { 3,-11061 }, { 4,-11061 }, + { 5,-11061 }, { 6,-11061 }, { 7,-11061 }, { 8,-11061 }, { 9,-10803 }, + { 10,-17447 }, { 11,-11061 }, { 12,-10803 }, { 13,-17447 }, { 14,-11061 }, + { 15,-11061 }, { 16,-11061 }, { 17,-11061 }, { 18,-11061 }, { 19,-11061 }, + { 20,-11061 }, { 21,-11061 }, { 22,-11061 }, { 23,-11061 }, { 24,-11061 }, + { 25,-11061 }, { 26,-11061 }, { 27,-11061 }, { 28,-11061 }, { 29,-11061 }, + + { 30,-11061 }, { 31,-11061 }, { 32,-10803 }, { 33,-11061 }, { 34,-11061 }, + { 35,-11061 }, { 36,-11061 }, { 37,-11061 }, { 38,-11061 }, { 39,-11061 }, + { 40,-11061 }, { 41,-11061 }, { 42,-11061 }, { 43,-11061 }, { 44,-11061 }, + { 45,-10545 }, { 46,-11061 }, { 47,-11061 }, { 48,-11061 }, { 49,-11061 }, + { 50,-11061 }, { 51,-11061 }, { 52,-11061 }, { 53,-11061 }, { 54,-11061 }, + { 55,-11061 }, { 56,-11061 }, { 57,-11061 }, { 58,-11061 }, { 59,-11061 }, + { 60,-11061 }, { 61,-11061 }, { 62,-11061 }, { 63,-11061 }, { 64,-11061 }, + { 65,-11061 }, { 66,-11061 }, { 67,-11061 }, { 68,-11061 }, { 69,-11061 }, + { 70,-11061 }, { 71,-11061 }, { 72,-11061 }, { 73,-11061 }, { 74,-11061 }, + { 75,-11061 }, { 76,-11061 }, { 77,-11061 }, { 78,-11061 }, { 79,-11061 }, + + { 80, 950 }, { 81,-11061 }, { 82,-11061 }, { 83,-11061 }, { 84,-11061 }, + { 85,-10287 }, { 86,-11061 }, { 87,-11061 }, { 88,-11061 }, { 89,-11061 }, + { 90,-11061 }, { 91,-11061 }, { 92,-11061 }, { 93,-11061 }, { 94,-11061 }, + { 95,-11061 }, { 96,-11061 }, { 97,-11061 }, { 98,-11061 }, { 99,-11061 }, + { 100,-11061 }, { 101,-11061 }, { 102,-11061 }, { 103,-11061 }, { 104,-11061 }, + { 105,-11061 }, { 106,-11061 }, { 107,-11061 }, { 108,-11061 }, { 109,-11061 }, + { 110,-11061 }, { 111,-11061 }, { 112, 950 }, { 113,-11061 }, { 114,-11061 }, + { 115,-11061 }, { 116,-11061 }, { 117,-10287 }, { 118,-11061 }, { 119,-11061 }, + { 120,-11061 }, { 121,-11061 }, { 122,-11061 }, { 123,-11061 }, { 124,-11061 }, + { 125,-11061 }, { 126,-11061 }, { 127,-11061 }, { 128,-11061 }, { 129,-11061 }, + + { 130,-11061 }, { 131,-11061 }, { 132,-11061 }, { 133,-11061 }, { 134,-11061 }, + { 135,-11061 }, { 136,-11061 }, { 137,-11061 }, { 138,-11061 }, { 139,-11061 }, + { 140,-11061 }, { 141,-11061 }, { 142,-11061 }, { 143,-11061 }, { 144,-11061 }, + { 145,-11061 }, { 146,-11061 }, { 147,-11061 }, { 148,-11061 }, { 149,-11061 }, + { 150,-11061 }, { 151,-11061 }, { 152,-11061 }, { 153,-11061 }, { 154,-11061 }, + { 155,-11061 }, { 156,-11061 }, { 157,-11061 }, { 158,-11061 }, { 159,-11061 }, + { 160,-11061 }, { 161,-11061 }, { 162,-11061 }, { 163,-11061 }, { 164,-11061 }, + { 165,-11061 }, { 166,-11061 }, { 167,-11061 }, { 168,-11061 }, { 169,-11061 }, + { 170,-11061 }, { 171,-11061 }, { 172,-11061 }, { 173,-11061 }, { 174,-11061 }, + { 175,-11061 }, { 176,-11061 }, { 177,-11061 }, { 178,-11061 }, { 179,-11061 }, + + { 180,-11061 }, { 181,-11061 }, { 182,-11061 }, { 183,-11061 }, { 184,-11061 }, + { 185,-11061 }, { 186,-11061 }, { 187,-11061 }, { 188,-11061 }, { 189,-11061 }, + { 190,-11061 }, { 191,-11061 }, { 192,-11061 }, { 193,-11061 }, { 194,-11061 }, + { 195,-11061 }, { 196,-11061 }, { 197,-11061 }, { 198,-11061 }, { 199,-11061 }, + { 200,-11061 }, { 201,-11061 }, { 202,-11061 }, { 203,-11061 }, { 204,-11061 }, + { 205,-11061 }, { 206,-11061 }, { 207,-11061 }, { 208,-11061 }, { 209,-11061 }, + { 210,-11061 }, { 211,-11061 }, { 212,-11061 }, { 213,-11061 }, { 214,-11061 }, + { 215,-11061 }, { 216,-11061 }, { 217,-11061 }, { 218,-11061 }, { 219,-11061 }, + { 220,-11061 }, { 221,-11061 }, { 222,-11061 }, { 223,-11061 }, { 224,-11061 }, + { 225,-11061 }, { 226,-11061 }, { 227,-11061 }, { 228,-11061 }, { 229,-11061 }, + + { 230,-11061 }, { 231,-11061 }, { 232,-11061 }, { 233,-11061 }, { 234,-11061 }, + { 235,-11061 }, { 236,-11061 }, { 237,-11061 }, { 238,-11061 }, { 239,-11061 }, + { 240,-11061 }, { 241,-11061 }, { 242,-11061 }, { 243,-11061 }, { 244,-11061 }, + { 245,-11061 }, { 246,-11061 }, { 247,-11061 }, { 248,-11061 }, { 249,-11061 }, + { 250,-11061 }, { 251,-11061 }, { 252,-11061 }, { 253,-11061 }, { 254,-11061 }, + { 255,-11061 }, { 256,-11061 }, { 0, 48 }, { 0,32102 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 9, 950 }, { 10, 950 }, { 0, 0 }, + { 12, 950 }, { 13, 950 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 32, 950 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 39, 997 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 45,-21168 }, { 0, 24 }, + { 0,32055 }, { 1,-5037 }, { 2,-5037 }, { 3,-5037 }, { 4,-5037 }, + { 5,-5037 }, { 6,-5037 }, { 7,-5037 }, { 8,-5037 }, { 9,-4779 }, + { 10,-4521 }, { 11,-5037 }, { 12,-4779 }, { 13,-4521 }, { 14,-5037 }, + { 15,-5037 }, { 16,-5037 }, { 17,-5037 }, { 18,-5037 }, { 19,-5037 }, + { 20,-5037 }, { 21,-5037 }, { 22,-5037 }, { 23,-5037 }, { 24,-5037 }, + + { 25,-5037 }, { 26,-5037 }, { 27,-5037 }, { 28,-5037 }, { 29,-5037 }, + { 30,-5037 }, { 31,-5037 }, { 32,-4779 }, { 33,-5037 }, { 34,-5037 }, + { 35,-5037 }, { 36,-5037 }, { 37,-5037 }, { 38,-5037 }, { 39,-5037 }, + { 40,-5037 }, { 41,-5037 }, { 42,-5037 }, { 43,-5037 }, { 44,-5037 }, + { 45,-4402 }, { 46,-5037 }, { 47,-5037 }, { 48,-5037 }, { 49,-5037 }, + { 50,-5037 }, { 51,-5037 }, { 52,-5037 }, { 53,-5037 }, { 54,-5037 }, + { 55,-5037 }, { 56,-5037 }, { 57,-5037 }, { 58,-5037 }, { 59,-5037 }, + { 60,-5037 }, { 61,-5037 }, { 62,-5037 }, { 63,-5037 }, { 64,-5037 }, + { 65,1208 }, { 66,-5037 }, { 67,-5037 }, { 68,-5037 }, { 69,-5037 }, + { 70,-5037 }, { 71,-5037 }, { 72,-5037 }, { 73,-5037 }, { 74,-5037 }, + + { 75,-5037 }, { 76,-5037 }, { 77,-5037 }, { 78,-5037 }, { 79,-5037 }, + { 80,-5037 }, { 81,-5037 }, { 82,-5037 }, { 83,-5037 }, { 84,-5037 }, + { 85,-4144 }, { 86,-5037 }, { 87,-5037 }, { 88,-5037 }, { 89,-5037 }, + { 90,-5037 }, { 91,-5037 }, { 92,-5037 }, { 93,-5037 }, { 94,-5037 }, + { 95,-5037 }, { 96,-5037 }, { 97,1208 }, { 98,-5037 }, { 99,-5037 }, + { 100,-5037 }, { 101,-5037 }, { 102,-5037 }, { 103,-5037 }, { 104,-5037 }, + { 105,-5037 }, { 106,-5037 }, { 107,-5037 }, { 108,-5037 }, { 109,-5037 }, + { 110,-5037 }, { 111,-5037 }, { 112,-5037 }, { 113,-5037 }, { 114,-5037 }, + { 115,-5037 }, { 116,-5037 }, { 117,-4144 }, { 118,-5037 }, { 119,-5037 }, + { 120,-5037 }, { 121,-5037 }, { 122,-5037 }, { 123,-5037 }, { 124,-5037 }, + + { 125,-5037 }, { 126,-5037 }, { 127,-5037 }, { 128,-5037 }, { 129,-5037 }, + { 130,-5037 }, { 131,-5037 }, { 132,-5037 }, { 133,-5037 }, { 134,-5037 }, + { 135,-5037 }, { 136,-5037 }, { 137,-5037 }, { 138,-5037 }, { 139,-5037 }, + { 140,-5037 }, { 141,-5037 }, { 142,-5037 }, { 143,-5037 }, { 144,-5037 }, + { 145,-5037 }, { 146,-5037 }, { 147,-5037 }, { 148,-5037 }, { 149,-5037 }, + { 150,-5037 }, { 151,-5037 }, { 152,-5037 }, { 153,-5037 }, { 154,-5037 }, + { 155,-5037 }, { 156,-5037 }, { 157,-5037 }, { 158,-5037 }, { 159,-5037 }, + { 160,-5037 }, { 161,-5037 }, { 162,-5037 }, { 163,-5037 }, { 164,-5037 }, + { 165,-5037 }, { 166,-5037 }, { 167,-5037 }, { 168,-5037 }, { 169,-5037 }, + { 170,-5037 }, { 171,-5037 }, { 172,-5037 }, { 173,-5037 }, { 174,-5037 }, + + { 175,-5037 }, { 176,-5037 }, { 177,-5037 }, { 178,-5037 }, { 179,-5037 }, + { 180,-5037 }, { 181,-5037 }, { 182,-5037 }, { 183,-5037 }, { 184,-5037 }, + { 185,-5037 }, { 186,-5037 }, { 187,-5037 }, { 188,-5037 }, { 189,-5037 }, + { 190,-5037 }, { 191,-5037 }, { 192,-5037 }, { 193,-5037 }, { 194,-5037 }, + { 195,-5037 }, { 196,-5037 }, { 197,-5037 }, { 198,-5037 }, { 199,-5037 }, + { 200,-5037 }, { 201,-5037 }, { 202,-5037 }, { 203,-5037 }, { 204,-5037 }, + { 205,-5037 }, { 206,-5037 }, { 207,-5037 }, { 208,-5037 }, { 209,-5037 }, + { 210,-5037 }, { 211,-5037 }, { 212,-5037 }, { 213,-5037 }, { 214,-5037 }, + { 215,-5037 }, { 216,-5037 }, { 217,-5037 }, { 218,-5037 }, { 219,-5037 }, + { 220,-5037 }, { 221,-5037 }, { 222,-5037 }, { 223,-5037 }, { 224,-5037 }, + + { 225,-5037 }, { 226,-5037 }, { 227,-5037 }, { 228,-5037 }, { 229,-5037 }, + { 230,-5037 }, { 231,-5037 }, { 232,-5037 }, { 233,-5037 }, { 234,-5037 }, + { 235,-5037 }, { 236,-5037 }, { 237,-5037 }, { 238,-5037 }, { 239,-5037 }, + { 240,-5037 }, { 241,-5037 }, { 242,-5037 }, { 243,-5037 }, { 244,-5037 }, + { 245,-5037 }, { 246,-5037 }, { 247,-5037 }, { 248,-5037 }, { 249,-5037 }, + { 250,-5037 }, { 251,-5037 }, { 252,-5037 }, { 253,-5037 }, { 254,-5037 }, + { 255,-5037 }, { 256,-5037 }, { 0, 24 }, { 0,31797 }, { 1,-10334 }, + { 2,-10334 }, { 3,-10334 }, { 4,-10334 }, { 5,-10334 }, { 6,-10334 }, + { 7,-10334 }, { 8,-10334 }, { 9,-10076 }, { 10,-17989 }, { 11,-10334 }, + { 12,-10076 }, { 13,-17989 }, { 14,-10334 }, { 15,-10334 }, { 16,-10334 }, + + { 17,-10334 }, { 18,-10334 }, { 19,-10334 }, { 20,-10334 }, { 21,-10334 }, + { 22,-10334 }, { 23,-10334 }, { 24,-10334 }, { 25,-10334 }, { 26,-10334 }, + { 27,-10334 }, { 28,-10334 }, { 29,-10334 }, { 30,-10334 }, { 31,-10334 }, + { 32,-10076 }, { 33,-10334 }, { 34,-10334 }, { 35,-10334 }, { 36,-10334 }, + { 37,-10334 }, { 38,-10334 }, { 39,-10334 }, { 40,-10334 }, { 41,-10334 }, + { 42,-10334 }, { 43,-10334 }, { 44,-10334 }, { 45,-9818 }, { 46,-10334 }, + { 47,-10334 }, { 48,-10334 }, { 49,-10334 }, { 50,-10334 }, { 51,-10334 }, + { 52,-10334 }, { 53,-10334 }, { 54,-10334 }, { 55,-10334 }, { 56,-10334 }, + { 57,-10334 }, { 58,-10334 }, { 59,-10334 }, { 60,-10334 }, { 61,-10334 }, + { 62,-10334 }, { 63,-10334 }, { 64,-10334 }, { 65,-10334 }, { 66,-10334 }, + + { 67,-10334 }, { 68,-10334 }, { 69,-10334 }, { 70,-10334 }, { 71,-10334 }, + { 72,-10334 }, { 73,-10334 }, { 74,-10334 }, { 75,-10334 }, { 76,-10334 }, + { 77,-10334 }, { 78,-10334 }, { 79,-10334 }, { 80,1208 }, { 81,-10334 }, + { 82,-10334 }, { 83,-10334 }, { 84,-10334 }, { 85,-9560 }, { 86,-10334 }, + { 87,-10334 }, { 88,-10334 }, { 89,-10334 }, { 90,-10334 }, { 91,-10334 }, + { 92,-10334 }, { 93,-10334 }, { 94,-10334 }, { 95,-10334 }, { 96,-10334 }, + { 97,-10334 }, { 98,-10334 }, { 99,-10334 }, { 100,-10334 }, { 101,-10334 }, + { 102,-10334 }, { 103,-10334 }, { 104,-10334 }, { 105,-10334 }, { 106,-10334 }, + { 107,-10334 }, { 108,-10334 }, { 109,-10334 }, { 110,-10334 }, { 111,-10334 }, + { 112,1208 }, { 113,-10334 }, { 114,-10334 }, { 115,-10334 }, { 116,-10334 }, + + { 117,-9560 }, { 118,-10334 }, { 119,-10334 }, { 120,-10334 }, { 121,-10334 }, + { 122,-10334 }, { 123,-10334 }, { 124,-10334 }, { 125,-10334 }, { 126,-10334 }, + { 127,-10334 }, { 128,-10334 }, { 129,-10334 }, { 130,-10334 }, { 131,-10334 }, + { 132,-10334 }, { 133,-10334 }, { 134,-10334 }, { 135,-10334 }, { 136,-10334 }, + { 137,-10334 }, { 138,-10334 }, { 139,-10334 }, { 140,-10334 }, { 141,-10334 }, + { 142,-10334 }, { 143,-10334 }, { 144,-10334 }, { 145,-10334 }, { 146,-10334 }, + { 147,-10334 }, { 148,-10334 }, { 149,-10334 }, { 150,-10334 }, { 151,-10334 }, + { 152,-10334 }, { 153,-10334 }, { 154,-10334 }, { 155,-10334 }, { 156,-10334 }, + { 157,-10334 }, { 158,-10334 }, { 159,-10334 }, { 160,-10334 }, { 161,-10334 }, + { 162,-10334 }, { 163,-10334 }, { 164,-10334 }, { 165,-10334 }, { 166,-10334 }, + + { 167,-10334 }, { 168,-10334 }, { 169,-10334 }, { 170,-10334 }, { 171,-10334 }, + { 172,-10334 }, { 173,-10334 }, { 174,-10334 }, { 175,-10334 }, { 176,-10334 }, + { 177,-10334 }, { 178,-10334 }, { 179,-10334 }, { 180,-10334 }, { 181,-10334 }, + { 182,-10334 }, { 183,-10334 }, { 184,-10334 }, { 185,-10334 }, { 186,-10334 }, + { 187,-10334 }, { 188,-10334 }, { 189,-10334 }, { 190,-10334 }, { 191,-10334 }, + { 192,-10334 }, { 193,-10334 }, { 194,-10334 }, { 195,-10334 }, { 196,-10334 }, + { 197,-10334 }, { 198,-10334 }, { 199,-10334 }, { 200,-10334 }, { 201,-10334 }, + { 202,-10334 }, { 203,-10334 }, { 204,-10334 }, { 205,-10334 }, { 206,-10334 }, + { 207,-10334 }, { 208,-10334 }, { 209,-10334 }, { 210,-10334 }, { 211,-10334 }, + { 212,-10334 }, { 213,-10334 }, { 214,-10334 }, { 215,-10334 }, { 216,-10334 }, + + { 217,-10334 }, { 218,-10334 }, { 219,-10334 }, { 220,-10334 }, { 221,-10334 }, + { 222,-10334 }, { 223,-10334 }, { 224,-10334 }, { 225,-10334 }, { 226,-10334 }, + { 227,-10334 }, { 228,-10334 }, { 229,-10334 }, { 230,-10334 }, { 231,-10334 }, + { 232,-10334 }, { 233,-10334 }, { 234,-10334 }, { 235,-10334 }, { 236,-10334 }, + { 237,-10334 }, { 238,-10334 }, { 239,-10334 }, { 240,-10334 }, { 241,-10334 }, + { 242,-10334 }, { 243,-10334 }, { 244,-10334 }, { 245,-10334 }, { 246,-10334 }, + { 247,-10334 }, { 248,-10334 }, { 249,-10334 }, { 250,-10334 }, { 251,-10334 }, + { 252,-10334 }, { 253,-10334 }, { 254,-10334 }, { 255,-10334 }, { 256,-10334 }, + { 0, 24 }, { 0,31539 }, { 0, 33 }, { 0,31537 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 9,1208 }, { 10,1208 }, { 0, 0 }, { 12,1208 }, { 13,1208 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 33 }, { 0,31514 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 32,1208 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 39,1255 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 45,-21729 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 48,1511 }, { 49,1511 }, { 50,1511 }, { 51,1511 }, + { 52,1511 }, { 53,1511 }, { 54,1511 }, { 55,1511 }, { 56,1511 }, + + { 57,1511 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 65,1511 }, { 66,1511 }, + { 67,1511 }, { 68,1511 }, { 69,1511 }, { 70,1511 }, { 48,-22023 }, + { 49,-22023 }, { 50,-22023 }, { 51,-22023 }, { 52,-22023 }, { 53,-22023 }, + { 54,-22023 }, { 55,-22023 }, { 56,-22023 }, { 57,-22023 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 65,-22023 }, { 66,-22023 }, { 67,-22023 }, { 68,-22023 }, + { 69,-22023 }, { 70,-22023 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 97,1511 }, { 98,1511 }, { 99,1511 }, { 100,1511 }, { 101,1511 }, + { 102,1511 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 97,-22023 }, { 98,-22023 }, + { 99,-22023 }, { 100,-22023 }, { 101,-22023 }, { 102,-22023 }, { 0, 48 }, + { 0,31410 }, { 1,-12011 }, { 2,-12011 }, { 3,-12011 }, { 4,-12011 }, + { 5,-12011 }, { 6,-12011 }, { 7,-12011 }, { 8,-12011 }, { 9,-11753 }, + { 10,-18397 }, { 11,-12011 }, { 12,-11753 }, { 13,-18397 }, { 14,-12011 }, + { 15,-12011 }, { 16,-12011 }, { 17,-12011 }, { 18,-12011 }, { 19,-12011 }, + { 20,-12011 }, { 21,-12011 }, { 22,-12011 }, { 23,-12011 }, { 24,-12011 }, + { 25,-12011 }, { 26,-12011 }, { 27,-12011 }, { 28,-12011 }, { 29,-12011 }, + + { 30,-12011 }, { 31,-12011 }, { 32,-11753 }, { 33,-12011 }, { 34,-12011 }, + { 35,-12011 }, { 36,-12011 }, { 37,-12011 }, { 38,-12011 }, { 39,-12011 }, + { 40,-12011 }, { 41,-12011 }, { 42,-12011 }, { 43,-12011 }, { 44,-12011 }, + { 45,-11495 }, { 46,-12011 }, { 47,-12011 }, { 48,-12011 }, { 49,-12011 }, + { 50,-12011 }, { 51,-12011 }, { 52,-12011 }, { 53,-12011 }, { 54,-12011 }, + { 55,-12011 }, { 56,-12011 }, { 57,-12011 }, { 58,-12011 }, { 59,-12011 }, + { 60,-12011 }, { 61,-12011 }, { 62,-12011 }, { 63,-12011 }, { 64,-12011 }, + { 65,-12011 }, { 66,-12011 }, { 67,-12011 }, { 68,-12011 }, { 69,1488 }, + { 70,-12011 }, { 71,-12011 }, { 72,-12011 }, { 73,-12011 }, { 74,-12011 }, + { 75,-12011 }, { 76,-12011 }, { 77,-12011 }, { 78,-12011 }, { 79,-12011 }, + + { 80,-12011 }, { 81,-12011 }, { 82,-12011 }, { 83,-12011 }, { 84,-12011 }, + { 85,-11237 }, { 86,-12011 }, { 87,-12011 }, { 88,-12011 }, { 89,-12011 }, + { 90,-12011 }, { 91,-12011 }, { 92,-12011 }, { 93,-12011 }, { 94,-12011 }, + { 95,-12011 }, { 96,-12011 }, { 97,-12011 }, { 98,-12011 }, { 99,-12011 }, + { 100,-12011 }, { 101,1488 }, { 102,-12011 }, { 103,-12011 }, { 104,-12011 }, + { 105,-12011 }, { 106,-12011 }, { 107,-12011 }, { 108,-12011 }, { 109,-12011 }, + { 110,-12011 }, { 111,-12011 }, { 112,-12011 }, { 113,-12011 }, { 114,-12011 }, + { 115,-12011 }, { 116,-12011 }, { 117,-11237 }, { 118,-12011 }, { 119,-12011 }, + { 120,-12011 }, { 121,-12011 }, { 122,-12011 }, { 123,-12011 }, { 124,-12011 }, + { 125,-12011 }, { 126,-12011 }, { 127,-12011 }, { 128,-12011 }, { 129,-12011 }, + + { 130,-12011 }, { 131,-12011 }, { 132,-12011 }, { 133,-12011 }, { 134,-12011 }, + { 135,-12011 }, { 136,-12011 }, { 137,-12011 }, { 138,-12011 }, { 139,-12011 }, + { 140,-12011 }, { 141,-12011 }, { 142,-12011 }, { 143,-12011 }, { 144,-12011 }, + { 145,-12011 }, { 146,-12011 }, { 147,-12011 }, { 148,-12011 }, { 149,-12011 }, + { 150,-12011 }, { 151,-12011 }, { 152,-12011 }, { 153,-12011 }, { 154,-12011 }, + { 155,-12011 }, { 156,-12011 }, { 157,-12011 }, { 158,-12011 }, { 159,-12011 }, + { 160,-12011 }, { 161,-12011 }, { 162,-12011 }, { 163,-12011 }, { 164,-12011 }, + { 165,-12011 }, { 166,-12011 }, { 167,-12011 }, { 168,-12011 }, { 169,-12011 }, + { 170,-12011 }, { 171,-12011 }, { 172,-12011 }, { 173,-12011 }, { 174,-12011 }, + { 175,-12011 }, { 176,-12011 }, { 177,-12011 }, { 178,-12011 }, { 179,-12011 }, + + { 180,-12011 }, { 181,-12011 }, { 182,-12011 }, { 183,-12011 }, { 184,-12011 }, + { 185,-12011 }, { 186,-12011 }, { 187,-12011 }, { 188,-12011 }, { 189,-12011 }, + { 190,-12011 }, { 191,-12011 }, { 192,-12011 }, { 193,-12011 }, { 194,-12011 }, + { 195,-12011 }, { 196,-12011 }, { 197,-12011 }, { 198,-12011 }, { 199,-12011 }, + { 200,-12011 }, { 201,-12011 }, { 202,-12011 }, { 203,-12011 }, { 204,-12011 }, + { 205,-12011 }, { 206,-12011 }, { 207,-12011 }, { 208,-12011 }, { 209,-12011 }, + { 210,-12011 }, { 211,-12011 }, { 212,-12011 }, { 213,-12011 }, { 214,-12011 }, + { 215,-12011 }, { 216,-12011 }, { 217,-12011 }, { 218,-12011 }, { 219,-12011 }, + { 220,-12011 }, { 221,-12011 }, { 222,-12011 }, { 223,-12011 }, { 224,-12011 }, + { 225,-12011 }, { 226,-12011 }, { 227,-12011 }, { 228,-12011 }, { 229,-12011 }, + + { 230,-12011 }, { 231,-12011 }, { 232,-12011 }, { 233,-12011 }, { 234,-12011 }, + { 235,-12011 }, { 236,-12011 }, { 237,-12011 }, { 238,-12011 }, { 239,-12011 }, + { 240,-12011 }, { 241,-12011 }, { 242,-12011 }, { 243,-12011 }, { 244,-12011 }, + { 245,-12011 }, { 246,-12011 }, { 247,-12011 }, { 248,-12011 }, { 249,-12011 }, + { 250,-12011 }, { 251,-12011 }, { 252,-12011 }, { 253,-12011 }, { 254,-12011 }, + { 255,-12011 }, { 256,-12011 }, { 0, 48 }, { 0,31152 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 9, 0 }, { 10, 0 }, { 0, 0 }, + { 12, 0 }, { 13, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 32, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 39, 47 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 45,-22118 }, { 0, 48 }, + { 0,31105 }, { 1,-22156 }, { 2,-22156 }, { 3,-22156 }, { 4,-22156 }, + { 5,-22156 }, { 6,-22156 }, { 7,-22156 }, { 8,-22156 }, { 9,-22156 }, + { 10,-22156 }, { 11,-22156 }, { 12,-22156 }, { 13,-22156 }, { 14,-22156 }, + { 15,-22156 }, { 16,-22156 }, { 17,-22156 }, { 18,-22156 }, { 19,-22156 }, + { 20,-22156 }, { 21,-22156 }, { 22,-22156 }, { 23,-22156 }, { 24,-22156 }, + + { 25,-22156 }, { 26,-22156 }, { 27,-22156 }, { 28,-22156 }, { 29,-22156 }, + { 30,-22156 }, { 31,-22156 }, { 32,-22156 }, { 33,-22156 }, { 34,-22156 }, + { 35,-22156 }, { 36,-22156 }, { 37,-22156 }, { 38,-22156 }, { 0, 0 }, + { 40,-22156 }, { 41,-22156 }, { 42,-22156 }, { 43,-22156 }, { 44,-22156 }, + { 45,-22156 }, { 46,-22156 }, { 47,-22156 }, { 48,-22156 }, { 49,-22156 }, + { 50,-22156 }, { 51,-22156 }, { 52,-22156 }, { 53,-22156 }, { 54,-22156 }, + { 55,-22156 }, { 56,-22156 }, { 57,-22156 }, { 58,-22156 }, { 59,-22156 }, + { 60,-22156 }, { 61,-22156 }, { 62,-22156 }, { 63,-22156 }, { 64,-22156 }, + { 65,-22156 }, { 66,-22156 }, { 67,-22156 }, { 68,-22156 }, { 69,-22156 }, + { 70,-22156 }, { 71,-22156 }, { 72,-22156 }, { 73,-22156 }, { 74,-22156 }, + + { 75,-22156 }, { 76,-22156 }, { 77,-22156 }, { 78,-22156 }, { 79,-22156 }, + { 80,-22156 }, { 81,-22156 }, { 82,-22156 }, { 83,-22156 }, { 84,-22156 }, + { 85,-22156 }, { 86,-22156 }, { 87,-22156 }, { 88,-22156 }, { 89,-22156 }, + { 90,-22156 }, { 91,-22156 }, { 92,-22156 }, { 93,-22156 }, { 94,-22156 }, + { 95,-22156 }, { 96,-22156 }, { 97,-22156 }, { 98,-22156 }, { 99,-22156 }, + { 100,-22156 }, { 101,-22156 }, { 102,-22156 }, { 103,-22156 }, { 104,-22156 }, + { 105,-22156 }, { 106,-22156 }, { 107,-22156 }, { 108,-22156 }, { 109,-22156 }, + { 110,-22156 }, { 111,-22156 }, { 112,-22156 }, { 113,-22156 }, { 114,-22156 }, + { 115,-22156 }, { 116,-22156 }, { 117,-22156 }, { 118,-22156 }, { 119,-22156 }, + { 120,-22156 }, { 121,-22156 }, { 122,-22156 }, { 123,-22156 }, { 124,-22156 }, + + { 125,-22156 }, { 126,-22156 }, { 127,-22156 }, { 128,-22156 }, { 129,-22156 }, + { 130,-22156 }, { 131,-22156 }, { 132,-22156 }, { 133,-22156 }, { 134,-22156 }, + { 135,-22156 }, { 136,-22156 }, { 137,-22156 }, { 138,-22156 }, { 139,-22156 }, + { 140,-22156 }, { 141,-22156 }, { 142,-22156 }, { 143,-22156 }, { 144,-22156 }, + { 145,-22156 }, { 146,-22156 }, { 147,-22156 }, { 148,-22156 }, { 149,-22156 }, + { 150,-22156 }, { 151,-22156 }, { 152,-22156 }, { 153,-22156 }, { 154,-22156 }, + { 155,-22156 }, { 156,-22156 }, { 157,-22156 }, { 158,-22156 }, { 159,-22156 }, + { 160,-22156 }, { 161,-22156 }, { 162,-22156 }, { 163,-22156 }, { 164,-22156 }, + { 165,-22156 }, { 166,-22156 }, { 167,-22156 }, { 168,-22156 }, { 169,-22156 }, + { 170,-22156 }, { 171,-22156 }, { 172,-22156 }, { 173,-22156 }, { 174,-22156 }, + + { 175,-22156 }, { 176,-22156 }, { 177,-22156 }, { 178,-22156 }, { 179,-22156 }, + { 180,-22156 }, { 181,-22156 }, { 182,-22156 }, { 183,-22156 }, { 184,-22156 }, + { 185,-22156 }, { 186,-22156 }, { 187,-22156 }, { 188,-22156 }, { 189,-22156 }, + { 190,-22156 }, { 191,-22156 }, { 192,-22156 }, { 193,-22156 }, { 194,-22156 }, + { 195,-22156 }, { 196,-22156 }, { 197,-22156 }, { 198,-22156 }, { 199,-22156 }, + { 200,-22156 }, { 201,-22156 }, { 202,-22156 }, { 203,-22156 }, { 204,-22156 }, + { 205,-22156 }, { 206,-22156 }, { 207,-22156 }, { 208,-22156 }, { 209,-22156 }, + { 210,-22156 }, { 211,-22156 }, { 212,-22156 }, { 213,-22156 }, { 214,-22156 }, + { 215,-22156 }, { 216,-22156 }, { 217,-22156 }, { 218,-22156 }, { 219,-22156 }, + { 220,-22156 }, { 221,-22156 }, { 222,-22156 }, { 223,-22156 }, { 224,-22156 }, + + { 225,-22156 }, { 226,-22156 }, { 227,-22156 }, { 228,-22156 }, { 229,-22156 }, + { 230,-22156 }, { 231,-22156 }, { 232,-22156 }, { 233,-22156 }, { 234,-22156 }, + { 235,-22156 }, { 236,-22156 }, { 237,-22156 }, { 238,-22156 }, { 239,-22156 }, + { 240,-22156 }, { 241,-22156 }, { 242,-22156 }, { 243,-22156 }, { 244,-22156 }, + { 245,-22156 }, { 246,-22156 }, { 247,-22156 }, { 248,-22156 }, { 249,-22156 }, + { 250,-22156 }, { 251,-22156 }, { 252,-22156 }, { 253,-22156 }, { 254,-22156 }, + { 255,-22156 }, { 256,-22156 }, { 0, 24 }, { 0,30847 }, { 1,-6245 }, + { 2,-6245 }, { 3,-6245 }, { 4,-6245 }, { 5,-6245 }, { 6,-6245 }, + { 7,-6245 }, { 8,-6245 }, { 9,-5987 }, { 10,-5729 }, { 11,-6245 }, + { 12,-5987 }, { 13,-5729 }, { 14,-6245 }, { 15,-6245 }, { 16,-6245 }, + + { 17,-6245 }, { 18,-6245 }, { 19,-6245 }, { 20,-6245 }, { 21,-6245 }, + { 22,-6245 }, { 23,-6245 }, { 24,-6245 }, { 25,-6245 }, { 26,-6245 }, + { 27,-6245 }, { 28,-6245 }, { 29,-6245 }, { 30,-6245 }, { 31,-6245 }, + { 32,-5987 }, { 33,-6245 }, { 34,-6245 }, { 35,-6245 }, { 36,-6245 }, + { 37,-6245 }, { 38,-6245 }, { 39,-6245 }, { 40,-6245 }, { 41,-6245 }, + { 42,-6245 }, { 43,-6245 }, { 44,-6245 }, { 45,-5610 }, { 46,-6245 }, + { 47,-6245 }, { 48,-6245 }, { 49,-6245 }, { 50,-6245 }, { 51,-6245 }, + { 52,-6245 }, { 53,-6245 }, { 54,-6245 }, { 55,-6245 }, { 56,-6245 }, + { 57,-6245 }, { 58,-6245 }, { 59,-6245 }, { 60,-6245 }, { 61,-6245 }, + { 62,-6245 }, { 63,-6245 }, { 64,-6245 }, { 65,-6245 }, { 66,-6245 }, + + { 67,-6245 }, { 68,-6245 }, { 69,-6245 }, { 70,-6245 }, { 71,-6245 }, + { 72,-6245 }, { 73,-6245 }, { 74,-6245 }, { 75,-6245 }, { 76,-6245 }, + { 77,-6245 }, { 78,-6245 }, { 79,-6245 }, { 80,1441 }, { 81,-6245 }, + { 82,-6245 }, { 83,-6245 }, { 84,-6245 }, { 85,-5352 }, { 86,-6245 }, + { 87,-6245 }, { 88,-6245 }, { 89,-6245 }, { 90,-6245 }, { 91,-6245 }, + { 92,-6245 }, { 93,-6245 }, { 94,-6245 }, { 95,-6245 }, { 96,-6245 }, + { 97,-6245 }, { 98,-6245 }, { 99,-6245 }, { 100,-6245 }, { 101,-6245 }, + { 102,-6245 }, { 103,-6245 }, { 104,-6245 }, { 105,-6245 }, { 106,-6245 }, + { 107,-6245 }, { 108,-6245 }, { 109,-6245 }, { 110,-6245 }, { 111,-6245 }, + { 112,1441 }, { 113,-6245 }, { 114,-6245 }, { 115,-6245 }, { 116,-6245 }, + + { 117,-5352 }, { 118,-6245 }, { 119,-6245 }, { 120,-6245 }, { 121,-6245 }, + { 122,-6245 }, { 123,-6245 }, { 124,-6245 }, { 125,-6245 }, { 126,-6245 }, + { 127,-6245 }, { 128,-6245 }, { 129,-6245 }, { 130,-6245 }, { 131,-6245 }, + { 132,-6245 }, { 133,-6245 }, { 134,-6245 }, { 135,-6245 }, { 136,-6245 }, + { 137,-6245 }, { 138,-6245 }, { 139,-6245 }, { 140,-6245 }, { 141,-6245 }, + { 142,-6245 }, { 143,-6245 }, { 144,-6245 }, { 145,-6245 }, { 146,-6245 }, + { 147,-6245 }, { 148,-6245 }, { 149,-6245 }, { 150,-6245 }, { 151,-6245 }, + { 152,-6245 }, { 153,-6245 }, { 154,-6245 }, { 155,-6245 }, { 156,-6245 }, + { 157,-6245 }, { 158,-6245 }, { 159,-6245 }, { 160,-6245 }, { 161,-6245 }, + { 162,-6245 }, { 163,-6245 }, { 164,-6245 }, { 165,-6245 }, { 166,-6245 }, + + { 167,-6245 }, { 168,-6245 }, { 169,-6245 }, { 170,-6245 }, { 171,-6245 }, + { 172,-6245 }, { 173,-6245 }, { 174,-6245 }, { 175,-6245 }, { 176,-6245 }, + { 177,-6245 }, { 178,-6245 }, { 179,-6245 }, { 180,-6245 }, { 181,-6245 }, + { 182,-6245 }, { 183,-6245 }, { 184,-6245 }, { 185,-6245 }, { 186,-6245 }, + { 187,-6245 }, { 188,-6245 }, { 189,-6245 }, { 190,-6245 }, { 191,-6245 }, + { 192,-6245 }, { 193,-6245 }, { 194,-6245 }, { 195,-6245 }, { 196,-6245 }, + { 197,-6245 }, { 198,-6245 }, { 199,-6245 }, { 200,-6245 }, { 201,-6245 }, + { 202,-6245 }, { 203,-6245 }, { 204,-6245 }, { 205,-6245 }, { 206,-6245 }, + { 207,-6245 }, { 208,-6245 }, { 209,-6245 }, { 210,-6245 }, { 211,-6245 }, + { 212,-6245 }, { 213,-6245 }, { 214,-6245 }, { 215,-6245 }, { 216,-6245 }, + + { 217,-6245 }, { 218,-6245 }, { 219,-6245 }, { 220,-6245 }, { 221,-6245 }, + { 222,-6245 }, { 223,-6245 }, { 224,-6245 }, { 225,-6245 }, { 226,-6245 }, + { 227,-6245 }, { 228,-6245 }, { 229,-6245 }, { 230,-6245 }, { 231,-6245 }, + { 232,-6245 }, { 233,-6245 }, { 234,-6245 }, { 235,-6245 }, { 236,-6245 }, + { 237,-6245 }, { 238,-6245 }, { 239,-6245 }, { 240,-6245 }, { 241,-6245 }, + { 242,-6245 }, { 243,-6245 }, { 244,-6245 }, { 245,-6245 }, { 246,-6245 }, + { 247,-6245 }, { 248,-6245 }, { 249,-6245 }, { 250,-6245 }, { 251,-6245 }, + { 252,-6245 }, { 253,-6245 }, { 254,-6245 }, { 255,-6245 }, { 256,-6245 }, + { 0, 24 }, { 0,30589 }, { 1,-11542 }, { 2,-11542 }, { 3,-11542 }, + { 4,-11542 }, { 5,-11542 }, { 6,-11542 }, { 7,-11542 }, { 8,-11542 }, + + { 9,-11284 }, { 10,-19197 }, { 11,-11542 }, { 12,-11284 }, { 13,-19197 }, + { 14,-11542 }, { 15,-11542 }, { 16,-11542 }, { 17,-11542 }, { 18,-11542 }, + { 19,-11542 }, { 20,-11542 }, { 21,-11542 }, { 22,-11542 }, { 23,-11542 }, + { 24,-11542 }, { 25,-11542 }, { 26,-11542 }, { 27,-11542 }, { 28,-11542 }, + { 29,-11542 }, { 30,-11542 }, { 31,-11542 }, { 32,-11284 }, { 33,-11542 }, + { 34,-11542 }, { 35,-11542 }, { 36,-11542 }, { 37,-11542 }, { 38,-11542 }, + { 39,-11542 }, { 40,-11542 }, { 41,-11542 }, { 42,-11542 }, { 43,-11542 }, + { 44,-11542 }, { 45,-11026 }, { 46,-11542 }, { 47,-11542 }, { 48,-11542 }, + { 49,-11542 }, { 50,-11542 }, { 51,-11542 }, { 52,-11542 }, { 53,-11542 }, + { 54,-11542 }, { 55,-11542 }, { 56,-11542 }, { 57,-11542 }, { 58,-11542 }, + + { 59,-11542 }, { 60,-11542 }, { 61,-11542 }, { 62,-11542 }, { 63,-11542 }, + { 64,-11542 }, { 65,-11542 }, { 66,-11542 }, { 67,-11542 }, { 68,-11542 }, + { 69,1441 }, { 70,-11542 }, { 71,-11542 }, { 72,-11542 }, { 73,-11542 }, + { 74,-11542 }, { 75,-11542 }, { 76,-11542 }, { 77,-11542 }, { 78,-11542 }, + { 79,-11542 }, { 80,-11542 }, { 81,-11542 }, { 82,-11542 }, { 83,-11542 }, + { 84,-11542 }, { 85,-10768 }, { 86,-11542 }, { 87,-11542 }, { 88,-11542 }, + { 89,-11542 }, { 90,-11542 }, { 91,-11542 }, { 92,-11542 }, { 93,-11542 }, + { 94,-11542 }, { 95,-11542 }, { 96,-11542 }, { 97,-11542 }, { 98,-11542 }, + { 99,-11542 }, { 100,-11542 }, { 101,1441 }, { 102,-11542 }, { 103,-11542 }, + { 104,-11542 }, { 105,-11542 }, { 106,-11542 }, { 107,-11542 }, { 108,-11542 }, + + { 109,-11542 }, { 110,-11542 }, { 111,-11542 }, { 112,-11542 }, { 113,-11542 }, + { 114,-11542 }, { 115,-11542 }, { 116,-11542 }, { 117,-10768 }, { 118,-11542 }, + { 119,-11542 }, { 120,-11542 }, { 121,-11542 }, { 122,-11542 }, { 123,-11542 }, + { 124,-11542 }, { 125,-11542 }, { 126,-11542 }, { 127,-11542 }, { 128,-11542 }, + { 129,-11542 }, { 130,-11542 }, { 131,-11542 }, { 132,-11542 }, { 133,-11542 }, + { 134,-11542 }, { 135,-11542 }, { 136,-11542 }, { 137,-11542 }, { 138,-11542 }, + { 139,-11542 }, { 140,-11542 }, { 141,-11542 }, { 142,-11542 }, { 143,-11542 }, + { 144,-11542 }, { 145,-11542 }, { 146,-11542 }, { 147,-11542 }, { 148,-11542 }, + { 149,-11542 }, { 150,-11542 }, { 151,-11542 }, { 152,-11542 }, { 153,-11542 }, + { 154,-11542 }, { 155,-11542 }, { 156,-11542 }, { 157,-11542 }, { 158,-11542 }, + + { 159,-11542 }, { 160,-11542 }, { 161,-11542 }, { 162,-11542 }, { 163,-11542 }, + { 164,-11542 }, { 165,-11542 }, { 166,-11542 }, { 167,-11542 }, { 168,-11542 }, + { 169,-11542 }, { 170,-11542 }, { 171,-11542 }, { 172,-11542 }, { 173,-11542 }, + { 174,-11542 }, { 175,-11542 }, { 176,-11542 }, { 177,-11542 }, { 178,-11542 }, + { 179,-11542 }, { 180,-11542 }, { 181,-11542 }, { 182,-11542 }, { 183,-11542 }, + { 184,-11542 }, { 185,-11542 }, { 186,-11542 }, { 187,-11542 }, { 188,-11542 }, + { 189,-11542 }, { 190,-11542 }, { 191,-11542 }, { 192,-11542 }, { 193,-11542 }, + { 194,-11542 }, { 195,-11542 }, { 196,-11542 }, { 197,-11542 }, { 198,-11542 }, + { 199,-11542 }, { 200,-11542 }, { 201,-11542 }, { 202,-11542 }, { 203,-11542 }, + { 204,-11542 }, { 205,-11542 }, { 206,-11542 }, { 207,-11542 }, { 208,-11542 }, + + { 209,-11542 }, { 210,-11542 }, { 211,-11542 }, { 212,-11542 }, { 213,-11542 }, + { 214,-11542 }, { 215,-11542 }, { 216,-11542 }, { 217,-11542 }, { 218,-11542 }, + { 219,-11542 }, { 220,-11542 }, { 221,-11542 }, { 222,-11542 }, { 223,-11542 }, + { 224,-11542 }, { 225,-11542 }, { 226,-11542 }, { 227,-11542 }, { 228,-11542 }, + { 229,-11542 }, { 230,-11542 }, { 231,-11542 }, { 232,-11542 }, { 233,-11542 }, + { 234,-11542 }, { 235,-11542 }, { 236,-11542 }, { 237,-11542 }, { 238,-11542 }, + { 239,-11542 }, { 240,-11542 }, { 241,-11542 }, { 242,-11542 }, { 243,-11542 }, + { 244,-11542 }, { 245,-11542 }, { 246,-11542 }, { 247,-11542 }, { 248,-11542 }, + { 249,-11542 }, { 250,-11542 }, { 251,-11542 }, { 252,-11542 }, { 253,-11542 }, + { 254,-11542 }, { 255,-11542 }, { 256,-11542 }, { 0, 24 }, { 0,30331 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 9, 0 }, { 10, 0 }, + { 0, 0 }, { 12, 0 }, { 13, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 32, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 39, 47 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 45,-22937 }, + { 0, 24 }, { 0,30284 }, { 1,-22975 }, { 2,-22975 }, { 3,-22975 }, + + { 4,-22975 }, { 5,-22975 }, { 6,-22975 }, { 7,-22975 }, { 8,-22975 }, + { 9,-22975 }, { 10,-22975 }, { 11,-22975 }, { 12,-22975 }, { 13,-22975 }, + { 14,-22975 }, { 15,-22975 }, { 16,-22975 }, { 17,-22975 }, { 18,-22975 }, + { 19,-22975 }, { 20,-22975 }, { 21,-22975 }, { 22,-22975 }, { 23,-22975 }, + { 24,-22975 }, { 25,-22975 }, { 26,-22975 }, { 27,-22975 }, { 28,-22975 }, + { 29,-22975 }, { 30,-22975 }, { 31,-22975 }, { 32,-22975 }, { 33,-22975 }, + { 34,-22975 }, { 35,-22975 }, { 36,-22975 }, { 37,-22975 }, { 38,-22975 }, + { 0, 0 }, { 40,-22975 }, { 41,-22975 }, { 42,-22975 }, { 43,-22975 }, + { 44,-22975 }, { 45,-22975 }, { 46,-22975 }, { 47,-22975 }, { 48,-22975 }, + { 49,-22975 }, { 50,-22975 }, { 51,-22975 }, { 52,-22975 }, { 53,-22975 }, + + { 54,-22975 }, { 55,-22975 }, { 56,-22975 }, { 57,-22975 }, { 58,-22975 }, + { 59,-22975 }, { 60,-22975 }, { 61,-22975 }, { 62,-22975 }, { 63,-22975 }, + { 64,-22975 }, { 65,-22975 }, { 66,-22975 }, { 67,-22975 }, { 68,-22975 }, + { 69,-22975 }, { 70,-22975 }, { 71,-22975 }, { 72,-22975 }, { 73,-22975 }, + { 74,-22975 }, { 75,-22975 }, { 76,-22975 }, { 77,-22975 }, { 78,-22975 }, + { 79,-22975 }, { 80,-22975 }, { 81,-22975 }, { 82,-22975 }, { 83,-22975 }, + { 84,-22975 }, { 85,-22975 }, { 86,-22975 }, { 87,-22975 }, { 88,-22975 }, + { 89,-22975 }, { 90,-22975 }, { 91,-22975 }, { 92,-22975 }, { 93,-22975 }, + { 94,-22975 }, { 95,-22975 }, { 96,-22975 }, { 97,-22975 }, { 98,-22975 }, + { 99,-22975 }, { 100,-22975 }, { 101,-22975 }, { 102,-22975 }, { 103,-22975 }, + + { 104,-22975 }, { 105,-22975 }, { 106,-22975 }, { 107,-22975 }, { 108,-22975 }, + { 109,-22975 }, { 110,-22975 }, { 111,-22975 }, { 112,-22975 }, { 113,-22975 }, + { 114,-22975 }, { 115,-22975 }, { 116,-22975 }, { 117,-22975 }, { 118,-22975 }, + { 119,-22975 }, { 120,-22975 }, { 121,-22975 }, { 122,-22975 }, { 123,-22975 }, + { 124,-22975 }, { 125,-22975 }, { 126,-22975 }, { 127,-22975 }, { 128,-22975 }, + { 129,-22975 }, { 130,-22975 }, { 131,-22975 }, { 132,-22975 }, { 133,-22975 }, + { 134,-22975 }, { 135,-22975 }, { 136,-22975 }, { 137,-22975 }, { 138,-22975 }, + { 139,-22975 }, { 140,-22975 }, { 141,-22975 }, { 142,-22975 }, { 143,-22975 }, + { 144,-22975 }, { 145,-22975 }, { 146,-22975 }, { 147,-22975 }, { 148,-22975 }, + { 149,-22975 }, { 150,-22975 }, { 151,-22975 }, { 152,-22975 }, { 153,-22975 }, + + { 154,-22975 }, { 155,-22975 }, { 156,-22975 }, { 157,-22975 }, { 158,-22975 }, + { 159,-22975 }, { 160,-22975 }, { 161,-22975 }, { 162,-22975 }, { 163,-22975 }, + { 164,-22975 }, { 165,-22975 }, { 166,-22975 }, { 167,-22975 }, { 168,-22975 }, + { 169,-22975 }, { 170,-22975 }, { 171,-22975 }, { 172,-22975 }, { 173,-22975 }, + { 174,-22975 }, { 175,-22975 }, { 176,-22975 }, { 177,-22975 }, { 178,-22975 }, + { 179,-22975 }, { 180,-22975 }, { 181,-22975 }, { 182,-22975 }, { 183,-22975 }, + { 184,-22975 }, { 185,-22975 }, { 186,-22975 }, { 187,-22975 }, { 188,-22975 }, + { 189,-22975 }, { 190,-22975 }, { 191,-22975 }, { 192,-22975 }, { 193,-22975 }, + { 194,-22975 }, { 195,-22975 }, { 196,-22975 }, { 197,-22975 }, { 198,-22975 }, + { 199,-22975 }, { 200,-22975 }, { 201,-22975 }, { 202,-22975 }, { 203,-22975 }, + + { 204,-22975 }, { 205,-22975 }, { 206,-22975 }, { 207,-22975 }, { 208,-22975 }, + { 209,-22975 }, { 210,-22975 }, { 211,-22975 }, { 212,-22975 }, { 213,-22975 }, + { 214,-22975 }, { 215,-22975 }, { 216,-22975 }, { 217,-22975 }, { 218,-22975 }, + { 219,-22975 }, { 220,-22975 }, { 221,-22975 }, { 222,-22975 }, { 223,-22975 }, + { 224,-22975 }, { 225,-22975 }, { 226,-22975 }, { 227,-22975 }, { 228,-22975 }, + { 229,-22975 }, { 230,-22975 }, { 231,-22975 }, { 232,-22975 }, { 233,-22975 }, + { 234,-22975 }, { 235,-22975 }, { 236,-22975 }, { 237,-22975 }, { 238,-22975 }, + { 239,-22975 }, { 240,-22975 }, { 241,-22975 }, { 242,-22975 }, { 243,-22975 }, + { 244,-22975 }, { 245,-22975 }, { 246,-22975 }, { 247,-22975 }, { 248,-22975 }, + { 249,-22975 }, { 250,-22975 }, { 251,-22975 }, { 252,-22975 }, { 253,-22975 }, + + { 254,-22975 }, { 255,-22975 }, { 256,-22975 }, { 0, 33 }, { 0,30026 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 48,-23259 }, { 49,-23259 }, { 50,-23259 }, + { 51,-23259 }, { 52,-23259 }, { 53,-23259 }, { 54,-23259 }, { 55,-23259 }, + { 56,-23259 }, { 57,-23259 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 65,-23259 }, + { 66,-23259 }, { 67,-23259 }, { 68,-23259 }, { 69,-23259 }, { 70,-23259 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 97,-23259 }, { 98,-23259 }, { 99,-23259 }, { 100,-23259 }, + { 101,-23259 }, { 102,-23259 }, { 0, 48 }, { 0,29922 }, { 1,-13499 }, + { 2,-13499 }, { 3,-13499 }, { 4,-13499 }, { 5,-13499 }, { 6,-13499 }, + { 7,-13499 }, { 8,-13499 }, { 9,1290 }, { 10,1548 }, { 11,-13499 }, + { 12,1290 }, { 13,1548 }, { 14,-13499 }, { 15,-13499 }, { 16,-13499 }, + { 17,-13499 }, { 18,-13499 }, { 19,-13499 }, { 20,-13499 }, { 21,-13499 }, + { 22,-13499 }, { 23,-13499 }, { 24,-13499 }, { 25,-13499 }, { 26,-13499 }, + { 27,-13499 }, { 28,-13499 }, { 29,-13499 }, { 30,-13499 }, { 31,-13499 }, + { 32,1290 }, { 33,-13499 }, { 34,-13499 }, { 35,-13499 }, { 36,-13499 }, + { 37,-13499 }, { 38,-13499 }, { 39,1667 }, { 40,-13499 }, { 41,-13499 }, + + { 42,-13499 }, { 43,-13499 }, { 44,-13499 }, { 45,1925 }, { 46,-13499 }, + { 47,-13499 }, { 48,-13499 }, { 49,-13499 }, { 50,-13499 }, { 51,-13499 }, + { 52,-13499 }, { 53,-13499 }, { 54,-13499 }, { 55,-13499 }, { 56,-13499 }, + { 57,-13499 }, { 58,-13499 }, { 59,-13499 }, { 60,-13499 }, { 61,-13499 }, + { 62,-13499 }, { 63,-13499 }, { 64,-13499 }, { 65,-13499 }, { 66,-13499 }, + { 67,-13499 }, { 68,-13499 }, { 69,-13499 }, { 70,-13499 }, { 71,-13499 }, + { 72,-13499 }, { 73,-13499 }, { 74,-13499 }, { 75,-13499 }, { 76,-13499 }, + { 77,-13499 }, { 78,-13499 }, { 79,-13499 }, { 80,-13499 }, { 81,-13499 }, + { 82,-13499 }, { 83,-13499 }, { 84,-13499 }, { 85,-12725 }, { 86,-13499 }, + { 87,-13499 }, { 88,-13499 }, { 89,-13499 }, { 90,-13499 }, { 91,-13499 }, + + { 92,-13499 }, { 93,-13499 }, { 94,-13499 }, { 95,-13499 }, { 96,-13499 }, + { 97,-13499 }, { 98,-13499 }, { 99,-13499 }, { 100,-13499 }, { 101,-13499 }, + { 102,-13499 }, { 103,-13499 }, { 104,-13499 }, { 105,-13499 }, { 106,-13499 }, + { 107,-13499 }, { 108,-13499 }, { 109,-13499 }, { 110,-13499 }, { 111,-13499 }, + { 112,-13499 }, { 113,-13499 }, { 114,-13499 }, { 115,-13499 }, { 116,-13499 }, + { 117,-12725 }, { 118,-13499 }, { 119,-13499 }, { 120,-13499 }, { 121,-13499 }, + { 122,-13499 }, { 123,-13499 }, { 124,-13499 }, { 125,-13499 }, { 126,-13499 }, + { 127,-13499 }, { 128,-13499 }, { 129,-13499 }, { 130,-13499 }, { 131,-13499 }, + { 132,-13499 }, { 133,-13499 }, { 134,-13499 }, { 135,-13499 }, { 136,-13499 }, + { 137,-13499 }, { 138,-13499 }, { 139,-13499 }, { 140,-13499 }, { 141,-13499 }, + + { 142,-13499 }, { 143,-13499 }, { 144,-13499 }, { 145,-13499 }, { 146,-13499 }, + { 147,-13499 }, { 148,-13499 }, { 149,-13499 }, { 150,-13499 }, { 151,-13499 }, + { 152,-13499 }, { 153,-13499 }, { 154,-13499 }, { 155,-13499 }, { 156,-13499 }, + { 157,-13499 }, { 158,-13499 }, { 159,-13499 }, { 160,-13499 }, { 161,-13499 }, + { 162,-13499 }, { 163,-13499 }, { 164,-13499 }, { 165,-13499 }, { 166,-13499 }, + { 167,-13499 }, { 168,-13499 }, { 169,-13499 }, { 170,-13499 }, { 171,-13499 }, + { 172,-13499 }, { 173,-13499 }, { 174,-13499 }, { 175,-13499 }, { 176,-13499 }, + { 177,-13499 }, { 178,-13499 }, { 179,-13499 }, { 180,-13499 }, { 181,-13499 }, + { 182,-13499 }, { 183,-13499 }, { 184,-13499 }, { 185,-13499 }, { 186,-13499 }, + { 187,-13499 }, { 188,-13499 }, { 189,-13499 }, { 190,-13499 }, { 191,-13499 }, + + { 192,-13499 }, { 193,-13499 }, { 194,-13499 }, { 195,-13499 }, { 196,-13499 }, + { 197,-13499 }, { 198,-13499 }, { 199,-13499 }, { 200,-13499 }, { 201,-13499 }, + { 202,-13499 }, { 203,-13499 }, { 204,-13499 }, { 205,-13499 }, { 206,-13499 }, + { 207,-13499 }, { 208,-13499 }, { 209,-13499 }, { 210,-13499 }, { 211,-13499 }, + { 212,-13499 }, { 213,-13499 }, { 214,-13499 }, { 215,-13499 }, { 216,-13499 }, + { 217,-13499 }, { 218,-13499 }, { 219,-13499 }, { 220,-13499 }, { 221,-13499 }, + { 222,-13499 }, { 223,-13499 }, { 224,-13499 }, { 225,-13499 }, { 226,-13499 }, + { 227,-13499 }, { 228,-13499 }, { 229,-13499 }, { 230,-13499 }, { 231,-13499 }, + { 232,-13499 }, { 233,-13499 }, { 234,-13499 }, { 235,-13499 }, { 236,-13499 }, + { 237,-13499 }, { 238,-13499 }, { 239,-13499 }, { 240,-13499 }, { 241,-13499 }, + + { 242,-13499 }, { 243,-13499 }, { 244,-13499 }, { 245,-13499 }, { 246,-13499 }, + { 247,-13499 }, { 248,-13499 }, { 249,-13499 }, { 250,-13499 }, { 251,-13499 }, + { 252,-13499 }, { 253,-13499 }, { 254,-13499 }, { 255,-13499 }, { 256,-13499 }, + { 0, 48 }, { 0,29664 }, { 1,1925 }, { 2,1925 }, { 3,1925 }, + { 4,1925 }, { 5,1925 }, { 6,1925 }, { 7,1925 }, { 8,1925 }, + { 9,2183 }, { 10,-1488 }, { 11,1925 }, { 12,2183 }, { 13,-1488 }, + { 14,1925 }, { 15,1925 }, { 16,1925 }, { 17,1925 }, { 18,1925 }, + { 19,1925 }, { 20,1925 }, { 21,1925 }, { 22,1925 }, { 23,1925 }, + { 24,1925 }, { 25,1925 }, { 26,1925 }, { 27,1925 }, { 28,1925 }, + { 29,1925 }, { 30,1925 }, { 31,1925 }, { 32,2183 }, { 33,1925 }, + + { 34,1925 }, { 35,1925 }, { 36,1925 }, { 37,1925 }, { 38,1925 }, + { 39,2441 }, { 40,1925 }, { 41,1925 }, { 42,1925 }, { 43,1925 }, + { 44,1925 }, { 45,2699 }, { 46,1925 }, { 47,1925 }, { 48,1925 }, + { 49,1925 }, { 50,1925 }, { 51,1925 }, { 52,1925 }, { 53,1925 }, + { 54,1925 }, { 55,1925 }, { 56,1925 }, { 57,1925 }, { 58,1925 }, + { 59,1925 }, { 60,1925 }, { 61,1925 }, { 62,1925 }, { 63,1925 }, + { 64,1925 }, { 65,1925 }, { 66,1925 }, { 67,1925 }, { 68,1925 }, + { 69,1925 }, { 70,1925 }, { 71,1925 }, { 72,1925 }, { 73,1925 }, + { 74,1925 }, { 75,1925 }, { 76,1925 }, { 77,1925 }, { 78,1925 }, + { 79,1925 }, { 80,1925 }, { 81,1925 }, { 82,1925 }, { 83,1925 }, + + { 84,1925 }, { 85,1925 }, { 86,1925 }, { 87,1925 }, { 88,1925 }, + { 89,1925 }, { 90,1925 }, { 91,1925 }, { 92,1925 }, { 93,1925 }, + { 94,1925 }, { 95,1925 }, { 96,1925 }, { 97,1925 }, { 98,1925 }, + { 99,1925 }, { 100,1925 }, { 101,1925 }, { 102,1925 }, { 103,1925 }, + { 104,1925 }, { 105,1925 }, { 106,1925 }, { 107,1925 }, { 108,1925 }, + { 109,1925 }, { 110,1925 }, { 111,1925 }, { 112,1925 }, { 113,1925 }, + { 114,1925 }, { 115,1925 }, { 116,1925 }, { 117,1925 }, { 118,1925 }, + { 119,1925 }, { 120,1925 }, { 121,1925 }, { 122,1925 }, { 123,1925 }, + { 124,1925 }, { 125,1925 }, { 126,1925 }, { 127,1925 }, { 128,1925 }, + { 129,1925 }, { 130,1925 }, { 131,1925 }, { 132,1925 }, { 133,1925 }, + + { 134,1925 }, { 135,1925 }, { 136,1925 }, { 137,1925 }, { 138,1925 }, + { 139,1925 }, { 140,1925 }, { 141,1925 }, { 142,1925 }, { 143,1925 }, + { 144,1925 }, { 145,1925 }, { 146,1925 }, { 147,1925 }, { 148,1925 }, + { 149,1925 }, { 150,1925 }, { 151,1925 }, { 152,1925 }, { 153,1925 }, + { 154,1925 }, { 155,1925 }, { 156,1925 }, { 157,1925 }, { 158,1925 }, + { 159,1925 }, { 160,1925 }, { 161,1925 }, { 162,1925 }, { 163,1925 }, + { 164,1925 }, { 165,1925 }, { 166,1925 }, { 167,1925 }, { 168,1925 }, + { 169,1925 }, { 170,1925 }, { 171,1925 }, { 172,1925 }, { 173,1925 }, + { 174,1925 }, { 175,1925 }, { 176,1925 }, { 177,1925 }, { 178,1925 }, + { 179,1925 }, { 180,1925 }, { 181,1925 }, { 182,1925 }, { 183,1925 }, + + { 184,1925 }, { 185,1925 }, { 186,1925 }, { 187,1925 }, { 188,1925 }, + { 189,1925 }, { 190,1925 }, { 191,1925 }, { 192,1925 }, { 193,1925 }, + { 194,1925 }, { 195,1925 }, { 196,1925 }, { 197,1925 }, { 198,1925 }, + { 199,1925 }, { 200,1925 }, { 201,1925 }, { 202,1925 }, { 203,1925 }, + { 204,1925 }, { 205,1925 }, { 206,1925 }, { 207,1925 }, { 208,1925 }, + { 209,1925 }, { 210,1925 }, { 211,1925 }, { 212,1925 }, { 213,1925 }, + { 214,1925 }, { 215,1925 }, { 216,1925 }, { 217,1925 }, { 218,1925 }, + { 219,1925 }, { 220,1925 }, { 221,1925 }, { 222,1925 }, { 223,1925 }, + { 224,1925 }, { 225,1925 }, { 226,1925 }, { 227,1925 }, { 228,1925 }, + { 229,1925 }, { 230,1925 }, { 231,1925 }, { 232,1925 }, { 233,1925 }, + + { 234,1925 }, { 235,1925 }, { 236,1925 }, { 237,1925 }, { 238,1925 }, + { 239,1925 }, { 240,1925 }, { 241,1925 }, { 242,1925 }, { 243,1925 }, + { 244,1925 }, { 245,1925 }, { 246,1925 }, { 247,1925 }, { 248,1925 }, + { 249,1925 }, { 250,1925 }, { 251,1925 }, { 252,1925 }, { 253,1925 }, + { 254,1925 }, { 255,1925 }, { 256,1925 }, { 0, 24 }, { 0,29406 }, + { 1,-7686 }, { 2,-7686 }, { 3,-7686 }, { 4,-7686 }, { 5,-7686 }, + { 6,-7686 }, { 7,-7686 }, { 8,-7686 }, { 9,-7428 }, { 10,-7170 }, + { 11,-7686 }, { 12,-7428 }, { 13,-7170 }, { 14,-7686 }, { 15,-7686 }, + { 16,-7686 }, { 17,-7686 }, { 18,-7686 }, { 19,-7686 }, { 20,-7686 }, + { 21,-7686 }, { 22,-7686 }, { 23,-7686 }, { 24,-7686 }, { 25,-7686 }, + + { 26,-7686 }, { 27,-7686 }, { 28,-7686 }, { 29,-7686 }, { 30,-7686 }, + { 31,-7686 }, { 32,-7428 }, { 33,-7686 }, { 34,-7686 }, { 35,-7686 }, + { 36,-7686 }, { 37,-7686 }, { 38,-7686 }, { 39,-7686 }, { 40,-7686 }, + { 41,-7686 }, { 42,-7686 }, { 43,-7686 }, { 44,-7686 }, { 45,-7051 }, + { 46,-7686 }, { 47,-7686 }, { 48,-7686 }, { 49,-7686 }, { 50,-7686 }, + { 51,-7686 }, { 52,-7686 }, { 53,-7686 }, { 54,-7686 }, { 55,-7686 }, + { 56,-7686 }, { 57,-7686 }, { 58,-7686 }, { 59,-7686 }, { 60,-7686 }, + { 61,-7686 }, { 62,-7686 }, { 63,-7686 }, { 64,-7686 }, { 65,-7686 }, + { 66,-7686 }, { 67,-7686 }, { 68,-7686 }, { 69,2699 }, { 70,-7686 }, + { 71,-7686 }, { 72,-7686 }, { 73,-7686 }, { 74,-7686 }, { 75,-7686 }, + + { 76,-7686 }, { 77,-7686 }, { 78,-7686 }, { 79,-7686 }, { 80,-7686 }, + { 81,-7686 }, { 82,-7686 }, { 83,-7686 }, { 84,-7686 }, { 85,-6793 }, + { 86,-7686 }, { 87,-7686 }, { 88,-7686 }, { 89,-7686 }, { 90,-7686 }, + { 91,-7686 }, { 92,-7686 }, { 93,-7686 }, { 94,-7686 }, { 95,-7686 }, + { 96,-7686 }, { 97,-7686 }, { 98,-7686 }, { 99,-7686 }, { 100,-7686 }, + { 101,2699 }, { 102,-7686 }, { 103,-7686 }, { 104,-7686 }, { 105,-7686 }, + { 106,-7686 }, { 107,-7686 }, { 108,-7686 }, { 109,-7686 }, { 110,-7686 }, + { 111,-7686 }, { 112,-7686 }, { 113,-7686 }, { 114,-7686 }, { 115,-7686 }, + { 116,-7686 }, { 117,-6793 }, { 118,-7686 }, { 119,-7686 }, { 120,-7686 }, + { 121,-7686 }, { 122,-7686 }, { 123,-7686 }, { 124,-7686 }, { 125,-7686 }, + + { 126,-7686 }, { 127,-7686 }, { 128,-7686 }, { 129,-7686 }, { 130,-7686 }, + { 131,-7686 }, { 132,-7686 }, { 133,-7686 }, { 134,-7686 }, { 135,-7686 }, + { 136,-7686 }, { 137,-7686 }, { 138,-7686 }, { 139,-7686 }, { 140,-7686 }, + { 141,-7686 }, { 142,-7686 }, { 143,-7686 }, { 144,-7686 }, { 145,-7686 }, + { 146,-7686 }, { 147,-7686 }, { 148,-7686 }, { 149,-7686 }, { 150,-7686 }, + { 151,-7686 }, { 152,-7686 }, { 153,-7686 }, { 154,-7686 }, { 155,-7686 }, + { 156,-7686 }, { 157,-7686 }, { 158,-7686 }, { 159,-7686 }, { 160,-7686 }, + { 161,-7686 }, { 162,-7686 }, { 163,-7686 }, { 164,-7686 }, { 165,-7686 }, + { 166,-7686 }, { 167,-7686 }, { 168,-7686 }, { 169,-7686 }, { 170,-7686 }, + { 171,-7686 }, { 172,-7686 }, { 173,-7686 }, { 174,-7686 }, { 175,-7686 }, + + { 176,-7686 }, { 177,-7686 }, { 178,-7686 }, { 179,-7686 }, { 180,-7686 }, + { 181,-7686 }, { 182,-7686 }, { 183,-7686 }, { 184,-7686 }, { 185,-7686 }, + { 186,-7686 }, { 187,-7686 }, { 188,-7686 }, { 189,-7686 }, { 190,-7686 }, + { 191,-7686 }, { 192,-7686 }, { 193,-7686 }, { 194,-7686 }, { 195,-7686 }, + { 196,-7686 }, { 197,-7686 }, { 198,-7686 }, { 199,-7686 }, { 200,-7686 }, + { 201,-7686 }, { 202,-7686 }, { 203,-7686 }, { 204,-7686 }, { 205,-7686 }, + { 206,-7686 }, { 207,-7686 }, { 208,-7686 }, { 209,-7686 }, { 210,-7686 }, + { 211,-7686 }, { 212,-7686 }, { 213,-7686 }, { 214,-7686 }, { 215,-7686 }, + { 216,-7686 }, { 217,-7686 }, { 218,-7686 }, { 219,-7686 }, { 220,-7686 }, + { 221,-7686 }, { 222,-7686 }, { 223,-7686 }, { 224,-7686 }, { 225,-7686 }, + + { 226,-7686 }, { 227,-7686 }, { 228,-7686 }, { 229,-7686 }, { 230,-7686 }, + { 231,-7686 }, { 232,-7686 }, { 233,-7686 }, { 234,-7686 }, { 235,-7686 }, + { 236,-7686 }, { 237,-7686 }, { 238,-7686 }, { 239,-7686 }, { 240,-7686 }, + { 241,-7686 }, { 242,-7686 }, { 243,-7686 }, { 244,-7686 }, { 245,-7686 }, + { 246,-7686 }, { 247,-7686 }, { 248,-7686 }, { 249,-7686 }, { 250,-7686 }, + { 251,-7686 }, { 252,-7686 }, { 253,-7686 }, { 254,-7686 }, { 255,-7686 }, + { 256,-7686 }, { 0, 24 }, { 0,29148 }, { 1,-12983 }, { 2,-12983 }, + { 3,-12983 }, { 4,-12983 }, { 5,-12983 }, { 6,-12983 }, { 7,-12983 }, + { 8,-12983 }, { 9,2699 }, { 10,2957 }, { 11,-12983 }, { 12,2699 }, + { 13,2957 }, { 14,-12983 }, { 15,-12983 }, { 16,-12983 }, { 17,-12983 }, + + { 18,-12983 }, { 19,-12983 }, { 20,-12983 }, { 21,-12983 }, { 22,-12983 }, + { 23,-12983 }, { 24,-12983 }, { 25,-12983 }, { 26,-12983 }, { 27,-12983 }, + { 28,-12983 }, { 29,-12983 }, { 30,-12983 }, { 31,-12983 }, { 32,2699 }, + { 33,-12983 }, { 34,-12983 }, { 35,-12983 }, { 36,-12983 }, { 37,-12983 }, + { 38,-12983 }, { 39,3076 }, { 40,-12983 }, { 41,-12983 }, { 42,-12983 }, + { 43,-12983 }, { 44,-12983 }, { 45,3334 }, { 46,-12983 }, { 47,-12983 }, + { 48,-12983 }, { 49,-12983 }, { 50,-12983 }, { 51,-12983 }, { 52,-12983 }, + { 53,-12983 }, { 54,-12983 }, { 55,-12983 }, { 56,-12983 }, { 57,-12983 }, + { 58,-12983 }, { 59,-12983 }, { 60,-12983 }, { 61,-12983 }, { 62,-12983 }, + { 63,-12983 }, { 64,-12983 }, { 65,-12983 }, { 66,-12983 }, { 67,-12983 }, + + { 68,-12983 }, { 69,-12983 }, { 70,-12983 }, { 71,-12983 }, { 72,-12983 }, + { 73,-12983 }, { 74,-12983 }, { 75,-12983 }, { 76,-12983 }, { 77,-12983 }, + { 78,-12983 }, { 79,-12983 }, { 80,-12983 }, { 81,-12983 }, { 82,-12983 }, + { 83,-12983 }, { 84,-12983 }, { 85,-12209 }, { 86,-12983 }, { 87,-12983 }, + { 88,-12983 }, { 89,-12983 }, { 90,-12983 }, { 91,-12983 }, { 92,-12983 }, + { 93,-12983 }, { 94,-12983 }, { 95,-12983 }, { 96,-12983 }, { 97,-12983 }, + { 98,-12983 }, { 99,-12983 }, { 100,-12983 }, { 101,-12983 }, { 102,-12983 }, + { 103,-12983 }, { 104,-12983 }, { 105,-12983 }, { 106,-12983 }, { 107,-12983 }, + { 108,-12983 }, { 109,-12983 }, { 110,-12983 }, { 111,-12983 }, { 112,-12983 }, + { 113,-12983 }, { 114,-12983 }, { 115,-12983 }, { 116,-12983 }, { 117,-12209 }, + + { 118,-12983 }, { 119,-12983 }, { 120,-12983 }, { 121,-12983 }, { 122,-12983 }, + { 123,-12983 }, { 124,-12983 }, { 125,-12983 }, { 126,-12983 }, { 127,-12983 }, + { 128,-12983 }, { 129,-12983 }, { 130,-12983 }, { 131,-12983 }, { 132,-12983 }, + { 133,-12983 }, { 134,-12983 }, { 135,-12983 }, { 136,-12983 }, { 137,-12983 }, + { 138,-12983 }, { 139,-12983 }, { 140,-12983 }, { 141,-12983 }, { 142,-12983 }, + { 143,-12983 }, { 144,-12983 }, { 145,-12983 }, { 146,-12983 }, { 147,-12983 }, + { 148,-12983 }, { 149,-12983 }, { 150,-12983 }, { 151,-12983 }, { 152,-12983 }, + { 153,-12983 }, { 154,-12983 }, { 155,-12983 }, { 156,-12983 }, { 157,-12983 }, + { 158,-12983 }, { 159,-12983 }, { 160,-12983 }, { 161,-12983 }, { 162,-12983 }, + { 163,-12983 }, { 164,-12983 }, { 165,-12983 }, { 166,-12983 }, { 167,-12983 }, + + { 168,-12983 }, { 169,-12983 }, { 170,-12983 }, { 171,-12983 }, { 172,-12983 }, + { 173,-12983 }, { 174,-12983 }, { 175,-12983 }, { 176,-12983 }, { 177,-12983 }, + { 178,-12983 }, { 179,-12983 }, { 180,-12983 }, { 181,-12983 }, { 182,-12983 }, + { 183,-12983 }, { 184,-12983 }, { 185,-12983 }, { 186,-12983 }, { 187,-12983 }, + { 188,-12983 }, { 189,-12983 }, { 190,-12983 }, { 191,-12983 }, { 192,-12983 }, + { 193,-12983 }, { 194,-12983 }, { 195,-12983 }, { 196,-12983 }, { 197,-12983 }, + { 198,-12983 }, { 199,-12983 }, { 200,-12983 }, { 201,-12983 }, { 202,-12983 }, + { 203,-12983 }, { 204,-12983 }, { 205,-12983 }, { 206,-12983 }, { 207,-12983 }, + { 208,-12983 }, { 209,-12983 }, { 210,-12983 }, { 211,-12983 }, { 212,-12983 }, + { 213,-12983 }, { 214,-12983 }, { 215,-12983 }, { 216,-12983 }, { 217,-12983 }, + + { 218,-12983 }, { 219,-12983 }, { 220,-12983 }, { 221,-12983 }, { 222,-12983 }, + { 223,-12983 }, { 224,-12983 }, { 225,-12983 }, { 226,-12983 }, { 227,-12983 }, + { 228,-12983 }, { 229,-12983 }, { 230,-12983 }, { 231,-12983 }, { 232,-12983 }, + { 233,-12983 }, { 234,-12983 }, { 235,-12983 }, { 236,-12983 }, { 237,-12983 }, + { 238,-12983 }, { 239,-12983 }, { 240,-12983 }, { 241,-12983 }, { 242,-12983 }, + { 243,-12983 }, { 244,-12983 }, { 245,-12983 }, { 246,-12983 }, { 247,-12983 }, + { 248,-12983 }, { 249,-12983 }, { 250,-12983 }, { 251,-12983 }, { 252,-12983 }, + { 253,-12983 }, { 254,-12983 }, { 255,-12983 }, { 256,-12983 }, { 0, 24 }, + { 0,28890 }, { 1,3334 }, { 2,3334 }, { 3,3334 }, { 4,3334 }, + { 5,3334 }, { 6,3334 }, { 7,3334 }, { 8,3334 }, { 9,3592 }, + + { 10,-1441 }, { 11,3334 }, { 12,3592 }, { 13,-1441 }, { 14,3334 }, + { 15,3334 }, { 16,3334 }, { 17,3334 }, { 18,3334 }, { 19,3334 }, + { 20,3334 }, { 21,3334 }, { 22,3334 }, { 23,3334 }, { 24,3334 }, + { 25,3334 }, { 26,3334 }, { 27,3334 }, { 28,3334 }, { 29,3334 }, + { 30,3334 }, { 31,3334 }, { 32,3592 }, { 33,3334 }, { 34,3334 }, + { 35,3334 }, { 36,3334 }, { 37,3334 }, { 38,3334 }, { 39,3850 }, + { 40,3334 }, { 41,3334 }, { 42,3334 }, { 43,3334 }, { 44,3334 }, + { 45,4108 }, { 46,3334 }, { 47,3334 }, { 48,3334 }, { 49,3334 }, + { 50,3334 }, { 51,3334 }, { 52,3334 }, { 53,3334 }, { 54,3334 }, + { 55,3334 }, { 56,3334 }, { 57,3334 }, { 58,3334 }, { 59,3334 }, + + { 60,3334 }, { 61,3334 }, { 62,3334 }, { 63,3334 }, { 64,3334 }, + { 65,3334 }, { 66,3334 }, { 67,3334 }, { 68,3334 }, { 69,3334 }, + { 70,3334 }, { 71,3334 }, { 72,3334 }, { 73,3334 }, { 74,3334 }, + { 75,3334 }, { 76,3334 }, { 77,3334 }, { 78,3334 }, { 79,3334 }, + { 80,3334 }, { 81,3334 }, { 82,3334 }, { 83,3334 }, { 84,3334 }, + { 85,3334 }, { 86,3334 }, { 87,3334 }, { 88,3334 }, { 89,3334 }, + { 90,3334 }, { 91,3334 }, { 92,3334 }, { 93,3334 }, { 94,3334 }, + { 95,3334 }, { 96,3334 }, { 97,3334 }, { 98,3334 }, { 99,3334 }, + { 100,3334 }, { 101,3334 }, { 102,3334 }, { 103,3334 }, { 104,3334 }, + { 105,3334 }, { 106,3334 }, { 107,3334 }, { 108,3334 }, { 109,3334 }, + + { 110,3334 }, { 111,3334 }, { 112,3334 }, { 113,3334 }, { 114,3334 }, + { 115,3334 }, { 116,3334 }, { 117,3334 }, { 118,3334 }, { 119,3334 }, + { 120,3334 }, { 121,3334 }, { 122,3334 }, { 123,3334 }, { 124,3334 }, + { 125,3334 }, { 126,3334 }, { 127,3334 }, { 128,3334 }, { 129,3334 }, + { 130,3334 }, { 131,3334 }, { 132,3334 }, { 133,3334 }, { 134,3334 }, + { 135,3334 }, { 136,3334 }, { 137,3334 }, { 138,3334 }, { 139,3334 }, + { 140,3334 }, { 141,3334 }, { 142,3334 }, { 143,3334 }, { 144,3334 }, + { 145,3334 }, { 146,3334 }, { 147,3334 }, { 148,3334 }, { 149,3334 }, + { 150,3334 }, { 151,3334 }, { 152,3334 }, { 153,3334 }, { 154,3334 }, + { 155,3334 }, { 156,3334 }, { 157,3334 }, { 158,3334 }, { 159,3334 }, + + { 160,3334 }, { 161,3334 }, { 162,3334 }, { 163,3334 }, { 164,3334 }, + { 165,3334 }, { 166,3334 }, { 167,3334 }, { 168,3334 }, { 169,3334 }, + { 170,3334 }, { 171,3334 }, { 172,3334 }, { 173,3334 }, { 174,3334 }, + { 175,3334 }, { 176,3334 }, { 177,3334 }, { 178,3334 }, { 179,3334 }, + { 180,3334 }, { 181,3334 }, { 182,3334 }, { 183,3334 }, { 184,3334 }, + { 185,3334 }, { 186,3334 }, { 187,3334 }, { 188,3334 }, { 189,3334 }, + { 190,3334 }, { 191,3334 }, { 192,3334 }, { 193,3334 }, { 194,3334 }, + { 195,3334 }, { 196,3334 }, { 197,3334 }, { 198,3334 }, { 199,3334 }, + { 200,3334 }, { 201,3334 }, { 202,3334 }, { 203,3334 }, { 204,3334 }, + { 205,3334 }, { 206,3334 }, { 207,3334 }, { 208,3334 }, { 209,3334 }, + + { 210,3334 }, { 211,3334 }, { 212,3334 }, { 213,3334 }, { 214,3334 }, + { 215,3334 }, { 216,3334 }, { 217,3334 }, { 218,3334 }, { 219,3334 }, + { 220,3334 }, { 221,3334 }, { 222,3334 }, { 223,3334 }, { 224,3334 }, + { 225,3334 }, { 226,3334 }, { 227,3334 }, { 228,3334 }, { 229,3334 }, + { 230,3334 }, { 231,3334 }, { 232,3334 }, { 233,3334 }, { 234,3334 }, + { 235,3334 }, { 236,3334 }, { 237,3334 }, { 238,3334 }, { 239,3334 }, + { 240,3334 }, { 241,3334 }, { 242,3334 }, { 243,3334 }, { 244,3334 }, + { 245,3334 }, { 246,3334 }, { 247,3334 }, { 248,3334 }, { 249,3334 }, + { 250,3334 }, { 251,3334 }, { 252,3334 }, { 253,3334 }, { 254,3334 }, + { 255,3334 }, { 256,3334 }, { 0, 48 }, { 0,28632 }, { 1,-14789 }, + + { 2,-14789 }, { 3,-14789 }, { 4,-14789 }, { 5,-14789 }, { 6,-14789 }, + { 7,-14789 }, { 8,-14789 }, { 9, 0 }, { 10, 258 }, { 11,-14789 }, + { 12, 0 }, { 13, 258 }, { 14,-14789 }, { 15,-14789 }, { 16,-14789 }, + { 17,-14789 }, { 18,-14789 }, { 19,-14789 }, { 20,-14789 }, { 21,-14789 }, + { 22,-14789 }, { 23,-14789 }, { 24,-14789 }, { 25,-14789 }, { 26,-14789 }, + { 27,-14789 }, { 28,-14789 }, { 29,-14789 }, { 30,-14789 }, { 31,-14789 }, + { 32, 0 }, { 33,-14789 }, { 34,-14789 }, { 35,-14789 }, { 36,-14789 }, + { 37,-14789 }, { 38,-14789 }, { 39, 377 }, { 40,-14789 }, { 41,-14789 }, + { 42,-14789 }, { 43,-14789 }, { 44,-14789 }, { 45, 635 }, { 46,-14789 }, + { 47,-14789 }, { 48,-14789 }, { 49,-14789 }, { 50,-14789 }, { 51,-14789 }, + + { 52,-14789 }, { 53,-14789 }, { 54,-14789 }, { 55,-14789 }, { 56,-14789 }, + { 57,-14789 }, { 58,-14789 }, { 59,-14789 }, { 60,-14789 }, { 61,-14789 }, + { 62,-14789 }, { 63,-14789 }, { 64,-14789 }, { 65,-14789 }, { 66,-14789 }, + { 67,-14789 }, { 68,-14789 }, { 69,-14789 }, { 70,-14789 }, { 71,-14789 }, + { 72,-14789 }, { 73,-14789 }, { 74,-14789 }, { 75,-14789 }, { 76,-14789 }, + { 77,-14789 }, { 78,-14789 }, { 79,-14789 }, { 80,-14789 }, { 81,-14789 }, + { 82,-14789 }, { 83,-14789 }, { 84,-14789 }, { 85,-14015 }, { 86,-14789 }, + { 87,-14789 }, { 88,-14789 }, { 89,-14789 }, { 90,-14789 }, { 91,-14789 }, + { 92,-14789 }, { 93,-14789 }, { 94,-14789 }, { 95,-14789 }, { 96,-14789 }, + { 97,-14789 }, { 98,-14789 }, { 99,-14789 }, { 100,-14789 }, { 101,-14789 }, + + { 102,-14789 }, { 103,-14789 }, { 104,-14789 }, { 105,-14789 }, { 106,-14789 }, + { 107,-14789 }, { 108,-14789 }, { 109,-14789 }, { 110,-14789 }, { 111,-14789 }, + { 112,-14789 }, { 113,-14789 }, { 114,-14789 }, { 115,-14789 }, { 116,-14789 }, + { 117,-14015 }, { 118,-14789 }, { 119,-14789 }, { 120,-14789 }, { 121,-14789 }, + { 122,-14789 }, { 123,-14789 }, { 124,-14789 }, { 125,-14789 }, { 126,-14789 }, + { 127,-14789 }, { 128,-14789 }, { 129,-14789 }, { 130,-14789 }, { 131,-14789 }, + { 132,-14789 }, { 133,-14789 }, { 134,-14789 }, { 135,-14789 }, { 136,-14789 }, + { 137,-14789 }, { 138,-14789 }, { 139,-14789 }, { 140,-14789 }, { 141,-14789 }, + { 142,-14789 }, { 143,-14789 }, { 144,-14789 }, { 145,-14789 }, { 146,-14789 }, + { 147,-14789 }, { 148,-14789 }, { 149,-14789 }, { 150,-14789 }, { 151,-14789 }, + + { 152,-14789 }, { 153,-14789 }, { 154,-14789 }, { 155,-14789 }, { 156,-14789 }, + { 157,-14789 }, { 158,-14789 }, { 159,-14789 }, { 160,-14789 }, { 161,-14789 }, + { 162,-14789 }, { 163,-14789 }, { 164,-14789 }, { 165,-14789 }, { 166,-14789 }, + { 167,-14789 }, { 168,-14789 }, { 169,-14789 }, { 170,-14789 }, { 171,-14789 }, + { 172,-14789 }, { 173,-14789 }, { 174,-14789 }, { 175,-14789 }, { 176,-14789 }, + { 177,-14789 }, { 178,-14789 }, { 179,-14789 }, { 180,-14789 }, { 181,-14789 }, + { 182,-14789 }, { 183,-14789 }, { 184,-14789 }, { 185,-14789 }, { 186,-14789 }, + { 187,-14789 }, { 188,-14789 }, { 189,-14789 }, { 190,-14789 }, { 191,-14789 }, + { 192,-14789 }, { 193,-14789 }, { 194,-14789 }, { 195,-14789 }, { 196,-14789 }, + { 197,-14789 }, { 198,-14789 }, { 199,-14789 }, { 200,-14789 }, { 201,-14789 }, + + { 202,-14789 }, { 203,-14789 }, { 204,-14789 }, { 205,-14789 }, { 206,-14789 }, + { 207,-14789 }, { 208,-14789 }, { 209,-14789 }, { 210,-14789 }, { 211,-14789 }, + { 212,-14789 }, { 213,-14789 }, { 214,-14789 }, { 215,-14789 }, { 216,-14789 }, + { 217,-14789 }, { 218,-14789 }, { 219,-14789 }, { 220,-14789 }, { 221,-14789 }, + { 222,-14789 }, { 223,-14789 }, { 224,-14789 }, { 225,-14789 }, { 226,-14789 }, + { 227,-14789 }, { 228,-14789 }, { 229,-14789 }, { 230,-14789 }, { 231,-14789 }, + { 232,-14789 }, { 233,-14789 }, { 234,-14789 }, { 235,-14789 }, { 236,-14789 }, + { 237,-14789 }, { 238,-14789 }, { 239,-14789 }, { 240,-14789 }, { 241,-14789 }, + { 242,-14789 }, { 243,-14789 }, { 244,-14789 }, { 245,-14789 }, { 246,-14789 }, + { 247,-14789 }, { 248,-14789 }, { 249,-14789 }, { 250,-14789 }, { 251,-14789 }, + + { 252,-14789 }, { 253,-14789 }, { 254,-14789 }, { 255,-14789 }, { 256,-14789 }, + { 0, 48 }, { 0,28374 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 9, 0 }, { 10, 0 }, { 0, 0 }, { 12, 0 }, { 13, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 32, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 39,-2731 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 45,-24844 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 85,-29483 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 117,-29483 }, { 0, 48 }, + { 0,28255 }, { 1,3731 }, { 2,3731 }, { 3,3731 }, { 4,3731 }, + { 5,3731 }, { 6,3731 }, { 7,3731 }, { 8,3731 }, { 9,3989 }, + { 10,4247 }, { 11,3731 }, { 12,3989 }, { 13,4247 }, { 14,3731 }, + { 15,3731 }, { 16,3731 }, { 17,3731 }, { 18,3731 }, { 19,3731 }, + { 20,3731 }, { 21,3731 }, { 22,3731 }, { 23,3731 }, { 24,3731 }, + + { 25,3731 }, { 26,3731 }, { 27,3731 }, { 28,3731 }, { 29,3731 }, + { 30,3731 }, { 31,3731 }, { 32,3989 }, { 33,3731 }, { 34,3731 }, + { 35,3731 }, { 36,3731 }, { 37,3731 }, { 38,3731 }, { 39,-15166 }, + { 40,3731 }, { 41,3731 }, { 42,3731 }, { 43,3731 }, { 44,3731 }, + { 45,4366 }, { 46,3731 }, { 47,3731 }, { 48,3731 }, { 49,3731 }, + { 50,3731 }, { 51,3731 }, { 52,3731 }, { 53,3731 }, { 54,3731 }, + { 55,3731 }, { 56,3731 }, { 57,3731 }, { 58,3731 }, { 59,3731 }, + { 60,3731 }, { 61,3731 }, { 62,3731 }, { 63,3731 }, { 64,3731 }, + { 65,3731 }, { 66,3731 }, { 67,3731 }, { 68,3731 }, { 69,3731 }, + { 70,3731 }, { 71,3731 }, { 72,3731 }, { 73,3731 }, { 74,3731 }, + + { 75,3731 }, { 76,3731 }, { 77,3731 }, { 78,3731 }, { 79,3731 }, + { 80,3731 }, { 81,3731 }, { 82,3731 }, { 83,3731 }, { 84,3731 }, + { 85,4624 }, { 86,3731 }, { 87,3731 }, { 88,3731 }, { 89,3731 }, + { 90,3731 }, { 91,3731 }, { 92,3731 }, { 93,3731 }, { 94,3731 }, + { 95,3731 }, { 96,3731 }, { 97,3731 }, { 98,3731 }, { 99,3731 }, + { 100,3731 }, { 101,3731 }, { 102,3731 }, { 103,3731 }, { 104,3731 }, + { 105,3731 }, { 106,3731 }, { 107,3731 }, { 108,3731 }, { 109,3731 }, + { 110,3731 }, { 111,3731 }, { 112,3731 }, { 113,3731 }, { 114,3731 }, + { 115,3731 }, { 116,3731 }, { 117,4624 }, { 118,3731 }, { 119,3731 }, + { 120,3731 }, { 121,3731 }, { 122,3731 }, { 123,3731 }, { 124,3731 }, + + { 125,3731 }, { 126,3731 }, { 127,3731 }, { 128,3731 }, { 129,3731 }, + { 130,3731 }, { 131,3731 }, { 132,3731 }, { 133,3731 }, { 134,3731 }, + { 135,3731 }, { 136,3731 }, { 137,3731 }, { 138,3731 }, { 139,3731 }, + { 140,3731 }, { 141,3731 }, { 142,3731 }, { 143,3731 }, { 144,3731 }, + { 145,3731 }, { 146,3731 }, { 147,3731 }, { 148,3731 }, { 149,3731 }, + { 150,3731 }, { 151,3731 }, { 152,3731 }, { 153,3731 }, { 154,3731 }, + { 155,3731 }, { 156,3731 }, { 157,3731 }, { 158,3731 }, { 159,3731 }, + { 160,3731 }, { 161,3731 }, { 162,3731 }, { 163,3731 }, { 164,3731 }, + { 165,3731 }, { 166,3731 }, { 167,3731 }, { 168,3731 }, { 169,3731 }, + { 170,3731 }, { 171,3731 }, { 172,3731 }, { 173,3731 }, { 174,3731 }, + + { 175,3731 }, { 176,3731 }, { 177,3731 }, { 178,3731 }, { 179,3731 }, + { 180,3731 }, { 181,3731 }, { 182,3731 }, { 183,3731 }, { 184,3731 }, + { 185,3731 }, { 186,3731 }, { 187,3731 }, { 188,3731 }, { 189,3731 }, + { 190,3731 }, { 191,3731 }, { 192,3731 }, { 193,3731 }, { 194,3731 }, + { 195,3731 }, { 196,3731 }, { 197,3731 }, { 198,3731 }, { 199,3731 }, + { 200,3731 }, { 201,3731 }, { 202,3731 }, { 203,3731 }, { 204,3731 }, + { 205,3731 }, { 206,3731 }, { 207,3731 }, { 208,3731 }, { 209,3731 }, + { 210,3731 }, { 211,3731 }, { 212,3731 }, { 213,3731 }, { 214,3731 }, + { 215,3731 }, { 216,3731 }, { 217,3731 }, { 218,3731 }, { 219,3731 }, + { 220,3731 }, { 221,3731 }, { 222,3731 }, { 223,3731 }, { 224,3731 }, + + { 225,3731 }, { 226,3731 }, { 227,3731 }, { 228,3731 }, { 229,3731 }, + { 230,3731 }, { 231,3731 }, { 232,3731 }, { 233,3731 }, { 234,3731 }, + { 235,3731 }, { 236,3731 }, { 237,3731 }, { 238,3731 }, { 239,3731 }, + { 240,3731 }, { 241,3731 }, { 242,3731 }, { 243,3731 }, { 244,3731 }, + { 245,3731 }, { 246,3731 }, { 247,3731 }, { 248,3731 }, { 249,3731 }, + { 250,3731 }, { 251,3731 }, { 252,3731 }, { 253,3731 }, { 254,3731 }, + { 255,3731 }, { 256,3731 }, { 0, 48 }, { 0,27997 }, { 1,-15424 }, + { 2,-15424 }, { 3,-15424 }, { 4,-15424 }, { 5,-15424 }, { 6,-15424 }, + { 7,-15424 }, { 8,-15424 }, { 9,-15166 }, { 10,-21810 }, { 11,-15424 }, + { 12,-15166 }, { 13,-21810 }, { 14,-15424 }, { 15,-15424 }, { 16,-15424 }, + + { 17,-15424 }, { 18,-15424 }, { 19,-15424 }, { 20,-15424 }, { 21,-15424 }, + { 22,-15424 }, { 23,-15424 }, { 24,-15424 }, { 25,-15424 }, { 26,-15424 }, + { 27,-15424 }, { 28,-15424 }, { 29,-15424 }, { 30,-15424 }, { 31,-15424 }, + { 32,-15166 }, { 33,-15424 }, { 34,-15424 }, { 35,-15424 }, { 36,-15424 }, + { 37,-15424 }, { 38,-15424 }, { 39,-15424 }, { 40,-15424 }, { 41,-15424 }, + { 42,-15424 }, { 43,-15424 }, { 44,-15424 }, { 45,4624 }, { 46,-15424 }, + { 47,-15424 }, { 48,-15424 }, { 49,-15424 }, { 50,-15424 }, { 51,-15424 }, + { 52,-15424 }, { 53,-15424 }, { 54,-15424 }, { 55,-15424 }, { 56,-15424 }, + { 57,-15424 }, { 58,-15424 }, { 59,-15424 }, { 60,-15424 }, { 61,-15424 }, + { 62,-15424 }, { 63,-15424 }, { 64,-15424 }, { 65,-15424 }, { 66,-15424 }, + + { 67,-15424 }, { 68,-15424 }, { 69,-15424 }, { 70,-15424 }, { 71,-15424 }, + { 72,-15424 }, { 73,-15424 }, { 74,-15424 }, { 75,-15424 }, { 76,-15424 }, + { 77,-15424 }, { 78,-15424 }, { 79,-15424 }, { 80,-15424 }, { 81,-15424 }, + { 82,-15424 }, { 83,-15424 }, { 84,-15424 }, { 85,-14650 }, { 86,-15424 }, + { 87,-15424 }, { 88,-15424 }, { 89,-15424 }, { 90,-15424 }, { 91,-15424 }, + { 92,-15424 }, { 93,-15424 }, { 94,-15424 }, { 95,-15424 }, { 96,-15424 }, + { 97,-15424 }, { 98,-15424 }, { 99,-15424 }, { 100,-15424 }, { 101,-15424 }, + { 102,-15424 }, { 103,-15424 }, { 104,-15424 }, { 105,-15424 }, { 106,-15424 }, + { 107,-15424 }, { 108,-15424 }, { 109,-15424 }, { 110,-15424 }, { 111,-15424 }, + { 112,-15424 }, { 113,-15424 }, { 114,-15424 }, { 115,-15424 }, { 116,-15424 }, + + { 117,-14650 }, { 118,-15424 }, { 119,-15424 }, { 120,-15424 }, { 121,-15424 }, + { 122,-15424 }, { 123,-15424 }, { 124,-15424 }, { 125,-15424 }, { 126,-15424 }, + { 127,-15424 }, { 128,-15424 }, { 129,-15424 }, { 130,-15424 }, { 131,-15424 }, + { 132,-15424 }, { 133,-15424 }, { 134,-15424 }, { 135,-15424 }, { 136,-15424 }, + { 137,-15424 }, { 138,-15424 }, { 139,-15424 }, { 140,-15424 }, { 141,-15424 }, + { 142,-15424 }, { 143,-15424 }, { 144,-15424 }, { 145,-15424 }, { 146,-15424 }, + { 147,-15424 }, { 148,-15424 }, { 149,-15424 }, { 150,-15424 }, { 151,-15424 }, + { 152,-15424 }, { 153,-15424 }, { 154,-15424 }, { 155,-15424 }, { 156,-15424 }, + { 157,-15424 }, { 158,-15424 }, { 159,-15424 }, { 160,-15424 }, { 161,-15424 }, + { 162,-15424 }, { 163,-15424 }, { 164,-15424 }, { 165,-15424 }, { 166,-15424 }, + + { 167,-15424 }, { 168,-15424 }, { 169,-15424 }, { 170,-15424 }, { 171,-15424 }, + { 172,-15424 }, { 173,-15424 }, { 174,-15424 }, { 175,-15424 }, { 176,-15424 }, + { 177,-15424 }, { 178,-15424 }, { 179,-15424 }, { 180,-15424 }, { 181,-15424 }, + { 182,-15424 }, { 183,-15424 }, { 184,-15424 }, { 185,-15424 }, { 186,-15424 }, + { 187,-15424 }, { 188,-15424 }, { 189,-15424 }, { 190,-15424 }, { 191,-15424 }, + { 192,-15424 }, { 193,-15424 }, { 194,-15424 }, { 195,-15424 }, { 196,-15424 }, + { 197,-15424 }, { 198,-15424 }, { 199,-15424 }, { 200,-15424 }, { 201,-15424 }, + { 202,-15424 }, { 203,-15424 }, { 204,-15424 }, { 205,-15424 }, { 206,-15424 }, + { 207,-15424 }, { 208,-15424 }, { 209,-15424 }, { 210,-15424 }, { 211,-15424 }, + { 212,-15424 }, { 213,-15424 }, { 214,-15424 }, { 215,-15424 }, { 216,-15424 }, + + { 217,-15424 }, { 218,-15424 }, { 219,-15424 }, { 220,-15424 }, { 221,-15424 }, + { 222,-15424 }, { 223,-15424 }, { 224,-15424 }, { 225,-15424 }, { 226,-15424 }, + { 227,-15424 }, { 228,-15424 }, { 229,-15424 }, { 230,-15424 }, { 231,-15424 }, + { 232,-15424 }, { 233,-15424 }, { 234,-15424 }, { 235,-15424 }, { 236,-15424 }, + { 237,-15424 }, { 238,-15424 }, { 239,-15424 }, { 240,-15424 }, { 241,-15424 }, + { 242,-15424 }, { 243,-15424 }, { 244,-15424 }, { 245,-15424 }, { 246,-15424 }, + { 247,-15424 }, { 248,-15424 }, { 249,-15424 }, { 250,-15424 }, { 251,-15424 }, + { 252,-15424 }, { 253,-15424 }, { 254,-15424 }, { 255,-15424 }, { 256,-15424 }, + { 0, 48 }, { 0,27739 }, { 1, 0 }, { 2, 0 }, { 3, 0 }, + { 4, 0 }, { 5, 0 }, { 6, 0 }, { 7, 0 }, { 8, 0 }, + + { 9, 258 }, { 10,-3413 }, { 11, 0 }, { 12, 258 }, { 13,-3413 }, + { 14, 0 }, { 15, 0 }, { 16, 0 }, { 17, 0 }, { 18, 0 }, + { 19, 0 }, { 20, 0 }, { 21, 0 }, { 22, 0 }, { 23, 0 }, + { 24, 0 }, { 25, 0 }, { 26, 0 }, { 27, 0 }, { 28, 0 }, + { 29, 0 }, { 30, 0 }, { 31, 0 }, { 32, 258 }, { 33, 0 }, + { 34, 0 }, { 35, 0 }, { 36, 0 }, { 37, 0 }, { 38, 0 }, + { 39, 516 }, { 40, 0 }, { 41, 0 }, { 42, 0 }, { 43, 0 }, + { 44, 0 }, { 45, 774 }, { 46, 0 }, { 47, 0 }, { 48, 0 }, + { 49, 0 }, { 50, 0 }, { 51, 0 }, { 52, 0 }, { 53, 0 }, + { 54, 0 }, { 55, 0 }, { 56, 0 }, { 57, 0 }, { 58, 0 }, + + { 59, 0 }, { 60, 0 }, { 61, 0 }, { 62, 0 }, { 63, 0 }, + { 64, 0 }, { 65, 0 }, { 66, 0 }, { 67, 0 }, { 68, 0 }, + { 69, 0 }, { 70, 0 }, { 71, 0 }, { 72, 0 }, { 73, 0 }, + { 74, 0 }, { 75, 0 }, { 76, 0 }, { 77, 0 }, { 78, 0 }, + { 79, 0 }, { 80, 0 }, { 81, 0 }, { 82, 0 }, { 83, 0 }, + { 84, 0 }, { 85, 0 }, { 86, 0 }, { 87, 0 }, { 88, 0 }, + { 89, 0 }, { 90, 0 }, { 91, 0 }, { 92, 0 }, { 93, 0 }, + { 94, 0 }, { 95, 0 }, { 96, 0 }, { 97, 0 }, { 98, 0 }, + { 99, 0 }, { 100, 0 }, { 101, 0 }, { 102, 0 }, { 103, 0 }, + { 104, 0 }, { 105, 0 }, { 106, 0 }, { 107, 0 }, { 108, 0 }, + + { 109, 0 }, { 110, 0 }, { 111, 0 }, { 112, 0 }, { 113, 0 }, + { 114, 0 }, { 115, 0 }, { 116, 0 }, { 117, 0 }, { 118, 0 }, + { 119, 0 }, { 120, 0 }, { 121, 0 }, { 122, 0 }, { 123, 0 }, + { 124, 0 }, { 125, 0 }, { 126, 0 }, { 127, 0 }, { 128, 0 }, + { 129, 0 }, { 130, 0 }, { 131, 0 }, { 132, 0 }, { 133, 0 }, + { 134, 0 }, { 135, 0 }, { 136, 0 }, { 137, 0 }, { 138, 0 }, + { 139, 0 }, { 140, 0 }, { 141, 0 }, { 142, 0 }, { 143, 0 }, + { 144, 0 }, { 145, 0 }, { 146, 0 }, { 147, 0 }, { 148, 0 }, + { 149, 0 }, { 150, 0 }, { 151, 0 }, { 152, 0 }, { 153, 0 }, + { 154, 0 }, { 155, 0 }, { 156, 0 }, { 157, 0 }, { 158, 0 }, + + { 159, 0 }, { 160, 0 }, { 161, 0 }, { 162, 0 }, { 163, 0 }, + { 164, 0 }, { 165, 0 }, { 166, 0 }, { 167, 0 }, { 168, 0 }, + { 169, 0 }, { 170, 0 }, { 171, 0 }, { 172, 0 }, { 173, 0 }, + { 174, 0 }, { 175, 0 }, { 176, 0 }, { 177, 0 }, { 178, 0 }, + { 179, 0 }, { 180, 0 }, { 181, 0 }, { 182, 0 }, { 183, 0 }, + { 184, 0 }, { 185, 0 }, { 186, 0 }, { 187, 0 }, { 188, 0 }, + { 189, 0 }, { 190, 0 }, { 191, 0 }, { 192, 0 }, { 193, 0 }, + { 194, 0 }, { 195, 0 }, { 196, 0 }, { 197, 0 }, { 198, 0 }, + { 199, 0 }, { 200, 0 }, { 201, 0 }, { 202, 0 }, { 203, 0 }, + { 204, 0 }, { 205, 0 }, { 206, 0 }, { 207, 0 }, { 208, 0 }, + + { 209, 0 }, { 210, 0 }, { 211, 0 }, { 212, 0 }, { 213, 0 }, + { 214, 0 }, { 215, 0 }, { 216, 0 }, { 217, 0 }, { 218, 0 }, + { 219, 0 }, { 220, 0 }, { 221, 0 }, { 222, 0 }, { 223, 0 }, + { 224, 0 }, { 225, 0 }, { 226, 0 }, { 227, 0 }, { 228, 0 }, + { 229, 0 }, { 230, 0 }, { 231, 0 }, { 232, 0 }, { 233, 0 }, + { 234, 0 }, { 235, 0 }, { 236, 0 }, { 237, 0 }, { 238, 0 }, + { 239, 0 }, { 240, 0 }, { 241, 0 }, { 242, 0 }, { 243, 0 }, + { 244, 0 }, { 245, 0 }, { 246, 0 }, { 247, 0 }, { 248, 0 }, + { 249, 0 }, { 250, 0 }, { 251, 0 }, { 252, 0 }, { 253, 0 }, + { 254, 0 }, { 255, 0 }, { 256, 0 }, { 0, 48 }, { 0,27481 }, + + { 1,-258 }, { 2,-258 }, { 3,-258 }, { 4,-258 }, { 5,-258 }, + { 6,-258 }, { 7,-258 }, { 8,-258 }, { 9, 0 }, { 10,-3671 }, + { 11,-258 }, { 12, 0 }, { 13,-3671 }, { 14,-258 }, { 15,-258 }, + { 16,-258 }, { 17,-258 }, { 18,-258 }, { 19,-258 }, { 20,-258 }, + { 21,-258 }, { 22,-258 }, { 23,-258 }, { 24,-258 }, { 25,-258 }, + { 26,-258 }, { 27,-258 }, { 28,-258 }, { 29,-258 }, { 30,-258 }, + { 31,-258 }, { 32, 0 }, { 33,-258 }, { 34,-258 }, { 35,-258 }, + { 36,-258 }, { 37,-258 }, { 38,-258 }, { 39, 258 }, { 40,-258 }, + { 41,-258 }, { 42,-258 }, { 43,-258 }, { 44,-258 }, { 45, 516 }, + { 46,-258 }, { 47,-258 }, { 48,-258 }, { 49,-258 }, { 50,-258 }, + + { 51,-258 }, { 52,-258 }, { 53,-258 }, { 54,-258 }, { 55,-258 }, + { 56,-258 }, { 57,-258 }, { 58,-258 }, { 59,-258 }, { 60,-258 }, + { 61,-258 }, { 62,-258 }, { 63,-258 }, { 64,-258 }, { 65,-258 }, + { 66,-258 }, { 67,-258 }, { 68,-258 }, { 69,-258 }, { 70,-258 }, + { 71,-258 }, { 72,-258 }, { 73,-258 }, { 74,-258 }, { 75,-258 }, + { 76,-258 }, { 77,-258 }, { 78,-258 }, { 79,-258 }, { 80,-258 }, + { 81,-258 }, { 82,-258 }, { 83,-258 }, { 84,-258 }, { 85,-258 }, + { 86,-258 }, { 87,-258 }, { 88,-258 }, { 89,-258 }, { 90,-258 }, + { 91,-258 }, { 92,-258 }, { 93,-258 }, { 94,-258 }, { 95,-258 }, + { 96,-258 }, { 97,-258 }, { 98,-258 }, { 99,-258 }, { 100,-258 }, + + { 101,-258 }, { 102,-258 }, { 103,-258 }, { 104,-258 }, { 105,-258 }, + { 106,-258 }, { 107,-258 }, { 108,-258 }, { 109,-258 }, { 110,-258 }, + { 111,-258 }, { 112,-258 }, { 113,-258 }, { 114,-258 }, { 115,-258 }, + { 116,-258 }, { 117,-258 }, { 118,-258 }, { 119,-258 }, { 120,-258 }, + { 121,-258 }, { 122,-258 }, { 123,-258 }, { 124,-258 }, { 125,-258 }, + { 126,-258 }, { 127,-258 }, { 128,-258 }, { 129,-258 }, { 130,-258 }, + { 131,-258 }, { 132,-258 }, { 133,-258 }, { 134,-258 }, { 135,-258 }, + { 136,-258 }, { 137,-258 }, { 138,-258 }, { 139,-258 }, { 140,-258 }, + { 141,-258 }, { 142,-258 }, { 143,-258 }, { 144,-258 }, { 145,-258 }, + { 146,-258 }, { 147,-258 }, { 148,-258 }, { 149,-258 }, { 150,-258 }, + + { 151,-258 }, { 152,-258 }, { 153,-258 }, { 154,-258 }, { 155,-258 }, + { 156,-258 }, { 157,-258 }, { 158,-258 }, { 159,-258 }, { 160,-258 }, + { 161,-258 }, { 162,-258 }, { 163,-258 }, { 164,-258 }, { 165,-258 }, + { 166,-258 }, { 167,-258 }, { 168,-258 }, { 169,-258 }, { 170,-258 }, + { 171,-258 }, { 172,-258 }, { 173,-258 }, { 174,-258 }, { 175,-258 }, + { 176,-258 }, { 177,-258 }, { 178,-258 }, { 179,-258 }, { 180,-258 }, + { 181,-258 }, { 182,-258 }, { 183,-258 }, { 184,-258 }, { 185,-258 }, + { 186,-258 }, { 187,-258 }, { 188,-258 }, { 189,-258 }, { 190,-258 }, + { 191,-258 }, { 192,-258 }, { 193,-258 }, { 194,-258 }, { 195,-258 }, + { 196,-258 }, { 197,-258 }, { 198,-258 }, { 199,-258 }, { 200,-258 }, + + { 201,-258 }, { 202,-258 }, { 203,-258 }, { 204,-258 }, { 205,-258 }, + { 206,-258 }, { 207,-258 }, { 208,-258 }, { 209,-258 }, { 210,-258 }, + { 211,-258 }, { 212,-258 }, { 213,-258 }, { 214,-258 }, { 215,-258 }, + { 216,-258 }, { 217,-258 }, { 218,-258 }, { 219,-258 }, { 220,-258 }, + { 221,-258 }, { 222,-258 }, { 223,-258 }, { 224,-258 }, { 225,-258 }, + { 226,-258 }, { 227,-258 }, { 228,-258 }, { 229,-258 }, { 230,-258 }, + { 231,-258 }, { 232,-258 }, { 233,-258 }, { 234,-258 }, { 235,-258 }, + { 236,-258 }, { 237,-258 }, { 238,-258 }, { 239,-258 }, { 240,-258 }, + { 241,-258 }, { 242,-258 }, { 243,-258 }, { 244,-258 }, { 245,-258 }, + { 246,-258 }, { 247,-258 }, { 248,-258 }, { 249,-258 }, { 250,-258 }, + + { 251,-258 }, { 252,-258 }, { 253,-258 }, { 254,-258 }, { 255,-258 }, + { 256,-258 }, { 0, 48 }, { 0,27223 }, { 1,4108 }, { 2,4108 }, + { 3,4108 }, { 4,4108 }, { 5,4108 }, { 6,4108 }, { 7,4108 }, + { 8,4108 }, { 9,4366 }, { 10,4624 }, { 11,4108 }, { 12,4366 }, + { 13,4624 }, { 14,4108 }, { 15,4108 }, { 16,4108 }, { 17,4108 }, + { 18,4108 }, { 19,4108 }, { 20,4108 }, { 21,4108 }, { 22,4108 }, + { 23,4108 }, { 24,4108 }, { 25,4108 }, { 26,4108 }, { 27,4108 }, + { 28,4108 }, { 29,4108 }, { 30,4108 }, { 31,4108 }, { 32,4366 }, + { 33,4108 }, { 34,4108 }, { 35,4108 }, { 36,4108 }, { 37,4108 }, + { 38,4108 }, { 39, 0 }, { 40,4108 }, { 41,4108 }, { 42,4108 }, + + { 43,4108 }, { 44,4108 }, { 45,4671 }, { 46,4108 }, { 47,4108 }, + { 48,4108 }, { 49,4108 }, { 50,4108 }, { 51,4108 }, { 52,4108 }, + { 53,4108 }, { 54,4108 }, { 55,4108 }, { 56,4108 }, { 57,4108 }, + { 58,4108 }, { 59,4108 }, { 60,4108 }, { 61,4108 }, { 62,4108 }, + { 63,4108 }, { 64,4108 }, { 65,4108 }, { 66,4108 }, { 67,4108 }, + { 68,4108 }, { 69,4108 }, { 70,4108 }, { 71,4108 }, { 72,4108 }, + { 73,4108 }, { 74,4108 }, { 75,4108 }, { 76,4108 }, { 77,4108 }, + { 78,4108 }, { 79,4108 }, { 80,4108 }, { 81,4108 }, { 82,4108 }, + { 83,4108 }, { 84,4108 }, { 85,4108 }, { 86,4108 }, { 87,4108 }, + { 88,4108 }, { 89,4108 }, { 90,4108 }, { 91,4108 }, { 92,4108 }, + + { 93,4108 }, { 94,4108 }, { 95,4108 }, { 96,4108 }, { 97,4108 }, + { 98,4108 }, { 99,4108 }, { 100,4108 }, { 101,4108 }, { 102,4108 }, + { 103,4108 }, { 104,4108 }, { 105,4108 }, { 106,4108 }, { 107,4108 }, + { 108,4108 }, { 109,4108 }, { 110,4108 }, { 111,4108 }, { 112,4108 }, + { 113,4108 }, { 114,4108 }, { 115,4108 }, { 116,4108 }, { 117,4108 }, + { 118,4108 }, { 119,4108 }, { 120,4108 }, { 121,4108 }, { 122,4108 }, + { 123,4108 }, { 124,4108 }, { 125,4108 }, { 126,4108 }, { 127,4108 }, + { 128,4108 }, { 129,4108 }, { 130,4108 }, { 131,4108 }, { 132,4108 }, + { 133,4108 }, { 134,4108 }, { 135,4108 }, { 136,4108 }, { 137,4108 }, + { 138,4108 }, { 139,4108 }, { 140,4108 }, { 141,4108 }, { 142,4108 }, + + { 143,4108 }, { 144,4108 }, { 145,4108 }, { 146,4108 }, { 147,4108 }, + { 148,4108 }, { 149,4108 }, { 150,4108 }, { 151,4108 }, { 152,4108 }, + { 153,4108 }, { 154,4108 }, { 155,4108 }, { 156,4108 }, { 157,4108 }, + { 158,4108 }, { 159,4108 }, { 160,4108 }, { 161,4108 }, { 162,4108 }, + { 163,4108 }, { 164,4108 }, { 165,4108 }, { 166,4108 }, { 167,4108 }, + { 168,4108 }, { 169,4108 }, { 170,4108 }, { 171,4108 }, { 172,4108 }, + { 173,4108 }, { 174,4108 }, { 175,4108 }, { 176,4108 }, { 177,4108 }, + { 178,4108 }, { 179,4108 }, { 180,4108 }, { 181,4108 }, { 182,4108 }, + { 183,4108 }, { 184,4108 }, { 185,4108 }, { 186,4108 }, { 187,4108 }, + { 188,4108 }, { 189,4108 }, { 190,4108 }, { 191,4108 }, { 192,4108 }, + + { 193,4108 }, { 194,4108 }, { 195,4108 }, { 196,4108 }, { 197,4108 }, + { 198,4108 }, { 199,4108 }, { 200,4108 }, { 201,4108 }, { 202,4108 }, + { 203,4108 }, { 204,4108 }, { 205,4108 }, { 206,4108 }, { 207,4108 }, + { 208,4108 }, { 209,4108 }, { 210,4108 }, { 211,4108 }, { 212,4108 }, + { 213,4108 }, { 214,4108 }, { 215,4108 }, { 216,4108 }, { 217,4108 }, + { 218,4108 }, { 219,4108 }, { 220,4108 }, { 221,4108 }, { 222,4108 }, + { 223,4108 }, { 224,4108 }, { 225,4108 }, { 226,4108 }, { 227,4108 }, + { 228,4108 }, { 229,4108 }, { 230,4108 }, { 231,4108 }, { 232,4108 }, + { 233,4108 }, { 234,4108 }, { 235,4108 }, { 236,4108 }, { 237,4108 }, + { 238,4108 }, { 239,4108 }, { 240,4108 }, { 241,4108 }, { 242,4108 }, + + { 243,4108 }, { 244,4108 }, { 245,4108 }, { 246,4108 }, { 247,4108 }, + { 248,4108 }, { 249,4108 }, { 250,4108 }, { 251,4108 }, { 252,4108 }, + { 253,4108 }, { 254,4108 }, { 255,4108 }, { 256,4108 }, { 0, 48 }, + { 0,26965 }, { 1,-774 }, { 2,-774 }, { 3,-774 }, { 4,-774 }, + { 5,-774 }, { 6,-774 }, { 7,-774 }, { 8,-774 }, { 9,-516 }, + { 10,-4187 }, { 11,-774 }, { 12,-516 }, { 13,-4187 }, { 14,-774 }, + { 15,-774 }, { 16,-774 }, { 17,-774 }, { 18,-774 }, { 19,-774 }, + { 20,-774 }, { 21,-774 }, { 22,-774 }, { 23,-774 }, { 24,-774 }, + { 25,-774 }, { 26,-774 }, { 27,-774 }, { 28,-774 }, { 29,-774 }, + { 30,-774 }, { 31,-774 }, { 32,-516 }, { 33,-774 }, { 34,-774 }, + + { 35,-774 }, { 36,-774 }, { 37,-774 }, { 38,-774 }, { 39,-258 }, + { 40,-774 }, { 41,-774 }, { 42,-774 }, { 43,-774 }, { 44,-774 }, + { 45,4671 }, { 46,-774 }, { 47,-774 }, { 48,-774 }, { 49,-774 }, + { 50,-774 }, { 51,-774 }, { 52,-774 }, { 53,-774 }, { 54,-774 }, + { 55,-774 }, { 56,-774 }, { 57,-774 }, { 58,-774 }, { 59,-774 }, + { 60,-774 }, { 61,-774 }, { 62,-774 }, { 63,-774 }, { 64,-774 }, + { 65,-774 }, { 66,-774 }, { 67,-774 }, { 68,-774 }, { 69,-774 }, + { 70,-774 }, { 71,-774 }, { 72,-774 }, { 73,-774 }, { 74,-774 }, + { 75,-774 }, { 76,-774 }, { 77,-774 }, { 78,-774 }, { 79,-774 }, + { 80,-774 }, { 81,-774 }, { 82,-774 }, { 83,-774 }, { 84,-774 }, + + { 85,-774 }, { 86,-774 }, { 87,-774 }, { 88,-774 }, { 89,-774 }, + { 90,-774 }, { 91,-774 }, { 92,-774 }, { 93,-774 }, { 94,-774 }, + { 95,-774 }, { 96,-774 }, { 97,-774 }, { 98,-774 }, { 99,-774 }, + { 100,-774 }, { 101,-774 }, { 102,-774 }, { 103,-774 }, { 104,-774 }, + { 105,-774 }, { 106,-774 }, { 107,-774 }, { 108,-774 }, { 109,-774 }, + { 110,-774 }, { 111,-774 }, { 112,-774 }, { 113,-774 }, { 114,-774 }, + { 115,-774 }, { 116,-774 }, { 117,-774 }, { 118,-774 }, { 119,-774 }, + { 120,-774 }, { 121,-774 }, { 122,-774 }, { 123,-774 }, { 124,-774 }, + { 125,-774 }, { 126,-774 }, { 127,-774 }, { 128,-774 }, { 129,-774 }, + { 130,-774 }, { 131,-774 }, { 132,-774 }, { 133,-774 }, { 134,-774 }, + + { 135,-774 }, { 136,-774 }, { 137,-774 }, { 138,-774 }, { 139,-774 }, + { 140,-774 }, { 141,-774 }, { 142,-774 }, { 143,-774 }, { 144,-774 }, + { 145,-774 }, { 146,-774 }, { 147,-774 }, { 148,-774 }, { 149,-774 }, + { 150,-774 }, { 151,-774 }, { 152,-774 }, { 153,-774 }, { 154,-774 }, + { 155,-774 }, { 156,-774 }, { 157,-774 }, { 158,-774 }, { 159,-774 }, + { 160,-774 }, { 161,-774 }, { 162,-774 }, { 163,-774 }, { 164,-774 }, + { 165,-774 }, { 166,-774 }, { 167,-774 }, { 168,-774 }, { 169,-774 }, + { 170,-774 }, { 171,-774 }, { 172,-774 }, { 173,-774 }, { 174,-774 }, + { 175,-774 }, { 176,-774 }, { 177,-774 }, { 178,-774 }, { 179,-774 }, + { 180,-774 }, { 181,-774 }, { 182,-774 }, { 183,-774 }, { 184,-774 }, + + { 185,-774 }, { 186,-774 }, { 187,-774 }, { 188,-774 }, { 189,-774 }, + { 190,-774 }, { 191,-774 }, { 192,-774 }, { 193,-774 }, { 194,-774 }, + { 195,-774 }, { 196,-774 }, { 197,-774 }, { 198,-774 }, { 199,-774 }, + { 200,-774 }, { 201,-774 }, { 202,-774 }, { 203,-774 }, { 204,-774 }, + { 205,-774 }, { 206,-774 }, { 207,-774 }, { 208,-774 }, { 209,-774 }, + { 210,-774 }, { 211,-774 }, { 212,-774 }, { 213,-774 }, { 214,-774 }, + { 215,-774 }, { 216,-774 }, { 217,-774 }, { 218,-774 }, { 219,-774 }, + { 220,-774 }, { 221,-774 }, { 222,-774 }, { 223,-774 }, { 224,-774 }, + { 225,-774 }, { 226,-774 }, { 227,-774 }, { 228,-774 }, { 229,-774 }, + { 230,-774 }, { 231,-774 }, { 232,-774 }, { 233,-774 }, { 234,-774 }, + + { 235,-774 }, { 236,-774 }, { 237,-774 }, { 238,-774 }, { 239,-774 }, + { 240,-774 }, { 241,-774 }, { 242,-774 }, { 243,-774 }, { 244,-774 }, + { 245,-774 }, { 246,-774 }, { 247,-774 }, { 248,-774 }, { 249,-774 }, + { 250,-774 }, { 251,-774 }, { 252,-774 }, { 253,-774 }, { 254,-774 }, + { 255,-774 }, { 256,-774 }, { 0, 24 }, { 0,26707 }, { 1,-10385 }, + { 2,-10385 }, { 3,-10385 }, { 4,-10385 }, { 5,-10385 }, { 6,-10385 }, + { 7,-10385 }, { 8,-10385 }, { 9,4671 }, { 10,4929 }, { 11,-10385 }, + { 12,4671 }, { 13,4929 }, { 14,-10385 }, { 15,-10385 }, { 16,-10385 }, + { 17,-10385 }, { 18,-10385 }, { 19,-10385 }, { 20,-10385 }, { 21,-10385 }, + { 22,-10385 }, { 23,-10385 }, { 24,-10385 }, { 25,-10385 }, { 26,-10385 }, + + { 27,-10385 }, { 28,-10385 }, { 29,-10385 }, { 30,-10385 }, { 31,-10385 }, + { 32,4671 }, { 33,-10385 }, { 34,-10385 }, { 35,-10385 }, { 36,-10385 }, + { 37,-10385 }, { 38,-10385 }, { 39,5048 }, { 40,-10385 }, { 41,-10385 }, + { 42,-10385 }, { 43,-10385 }, { 44,-10385 }, { 45,5306 }, { 46,-10385 }, + { 47,-10385 }, { 48,-10385 }, { 49,-10385 }, { 50,-10385 }, { 51,-10385 }, + { 52,-10385 }, { 53,-10385 }, { 54,-10385 }, { 55,-10385 }, { 56,-10385 }, + { 57,-10385 }, { 58,-10385 }, { 59,-10385 }, { 60,-10385 }, { 61,-10385 }, + { 62,-10385 }, { 63,-10385 }, { 64,-10385 }, { 65,-10385 }, { 66,-10385 }, + { 67,-10385 }, { 68,-10385 }, { 69,-10385 }, { 70,-10385 }, { 71,-10385 }, + { 72,-10385 }, { 73,-10385 }, { 74,-10385 }, { 75,-10385 }, { 76,-10385 }, + + { 77,-10385 }, { 78,-10385 }, { 79,-10385 }, { 80,-10385 }, { 81,-10385 }, + { 82,-10385 }, { 83,-10385 }, { 84,-10385 }, { 85,-9492 }, { 86,-10385 }, + { 87,-10385 }, { 88,-10385 }, { 89,-10385 }, { 90,-10385 }, { 91,-10385 }, + { 92,-10385 }, { 93,-10385 }, { 94,-10385 }, { 95,-10385 }, { 96,-10385 }, + { 97,-10385 }, { 98,-10385 }, { 99,-10385 }, { 100,-10385 }, { 101,-10385 }, + { 102,-10385 }, { 103,-10385 }, { 104,-10385 }, { 105,-10385 }, { 106,-10385 }, + { 107,-10385 }, { 108,-10385 }, { 109,-10385 }, { 110,-10385 }, { 111,-10385 }, + { 112,-10385 }, { 113,-10385 }, { 114,-10385 }, { 115,-10385 }, { 116,-10385 }, + { 117,-9492 }, { 118,-10385 }, { 119,-10385 }, { 120,-10385 }, { 121,-10385 }, + { 122,-10385 }, { 123,-10385 }, { 124,-10385 }, { 125,-10385 }, { 126,-10385 }, + + { 127,-10385 }, { 128,-10385 }, { 129,-10385 }, { 130,-10385 }, { 131,-10385 }, + { 132,-10385 }, { 133,-10385 }, { 134,-10385 }, { 135,-10385 }, { 136,-10385 }, + { 137,-10385 }, { 138,-10385 }, { 139,-10385 }, { 140,-10385 }, { 141,-10385 }, + { 142,-10385 }, { 143,-10385 }, { 144,-10385 }, { 145,-10385 }, { 146,-10385 }, + { 147,-10385 }, { 148,-10385 }, { 149,-10385 }, { 150,-10385 }, { 151,-10385 }, + { 152,-10385 }, { 153,-10385 }, { 154,-10385 }, { 155,-10385 }, { 156,-10385 }, + { 157,-10385 }, { 158,-10385 }, { 159,-10385 }, { 160,-10385 }, { 161,-10385 }, + { 162,-10385 }, { 163,-10385 }, { 164,-10385 }, { 165,-10385 }, { 166,-10385 }, + { 167,-10385 }, { 168,-10385 }, { 169,-10385 }, { 170,-10385 }, { 171,-10385 }, + { 172,-10385 }, { 173,-10385 }, { 174,-10385 }, { 175,-10385 }, { 176,-10385 }, + + { 177,-10385 }, { 178,-10385 }, { 179,-10385 }, { 180,-10385 }, { 181,-10385 }, + { 182,-10385 }, { 183,-10385 }, { 184,-10385 }, { 185,-10385 }, { 186,-10385 }, + { 187,-10385 }, { 188,-10385 }, { 189,-10385 }, { 190,-10385 }, { 191,-10385 }, + { 192,-10385 }, { 193,-10385 }, { 194,-10385 }, { 195,-10385 }, { 196,-10385 }, + { 197,-10385 }, { 198,-10385 }, { 199,-10385 }, { 200,-10385 }, { 201,-10385 }, + { 202,-10385 }, { 203,-10385 }, { 204,-10385 }, { 205,-10385 }, { 206,-10385 }, + { 207,-10385 }, { 208,-10385 }, { 209,-10385 }, { 210,-10385 }, { 211,-10385 }, + { 212,-10385 }, { 213,-10385 }, { 214,-10385 }, { 215,-10385 }, { 216,-10385 }, + { 217,-10385 }, { 218,-10385 }, { 219,-10385 }, { 220,-10385 }, { 221,-10385 }, + { 222,-10385 }, { 223,-10385 }, { 224,-10385 }, { 225,-10385 }, { 226,-10385 }, + + { 227,-10385 }, { 228,-10385 }, { 229,-10385 }, { 230,-10385 }, { 231,-10385 }, + { 232,-10385 }, { 233,-10385 }, { 234,-10385 }, { 235,-10385 }, { 236,-10385 }, + { 237,-10385 }, { 238,-10385 }, { 239,-10385 }, { 240,-10385 }, { 241,-10385 }, + { 242,-10385 }, { 243,-10385 }, { 244,-10385 }, { 245,-10385 }, { 246,-10385 }, + { 247,-10385 }, { 248,-10385 }, { 249,-10385 }, { 250,-10385 }, { 251,-10385 }, + { 252,-10385 }, { 253,-10385 }, { 254,-10385 }, { 255,-10385 }, { 256,-10385 }, + { 0, 24 }, { 0,26449 }, { 1,-15682 }, { 2,-15682 }, { 3,-15682 }, + { 4,-15682 }, { 5,-15682 }, { 6,-15682 }, { 7,-15682 }, { 8,-15682 }, + { 9, 0 }, { 10, 258 }, { 11,-15682 }, { 12, 0 }, { 13, 258 }, + { 14,-15682 }, { 15,-15682 }, { 16,-15682 }, { 17,-15682 }, { 18,-15682 }, + + { 19,-15682 }, { 20,-15682 }, { 21,-15682 }, { 22,-15682 }, { 23,-15682 }, + { 24,-15682 }, { 25,-15682 }, { 26,-15682 }, { 27,-15682 }, { 28,-15682 }, + { 29,-15682 }, { 30,-15682 }, { 31,-15682 }, { 32, 0 }, { 33,-15682 }, + { 34,-15682 }, { 35,-15682 }, { 36,-15682 }, { 37,-15682 }, { 38,-15682 }, + { 39, 377 }, { 40,-15682 }, { 41,-15682 }, { 42,-15682 }, { 43,-15682 }, + { 44,-15682 }, { 45, 635 }, { 46,-15682 }, { 47,-15682 }, { 48,-15682 }, + { 49,-15682 }, { 50,-15682 }, { 51,-15682 }, { 52,-15682 }, { 53,-15682 }, + { 54,-15682 }, { 55,-15682 }, { 56,-15682 }, { 57,-15682 }, { 58,-15682 }, + { 59,-15682 }, { 60,-15682 }, { 61,-15682 }, { 62,-15682 }, { 63,-15682 }, + { 64,-15682 }, { 65,-15682 }, { 66,-15682 }, { 67,-15682 }, { 68,-15682 }, + + { 69,-15682 }, { 70,-15682 }, { 71,-15682 }, { 72,-15682 }, { 73,-15682 }, + { 74,-15682 }, { 75,-15682 }, { 76,-15682 }, { 77,-15682 }, { 78,-15682 }, + { 79,-15682 }, { 80,-15682 }, { 81,-15682 }, { 82,-15682 }, { 83,-15682 }, + { 84,-15682 }, { 85,-14908 }, { 86,-15682 }, { 87,-15682 }, { 88,-15682 }, + { 89,-15682 }, { 90,-15682 }, { 91,-15682 }, { 92,-15682 }, { 93,-15682 }, + { 94,-15682 }, { 95,-15682 }, { 96,-15682 }, { 97,-15682 }, { 98,-15682 }, + { 99,-15682 }, { 100,-15682 }, { 101,-15682 }, { 102,-15682 }, { 103,-15682 }, + { 104,-15682 }, { 105,-15682 }, { 106,-15682 }, { 107,-15682 }, { 108,-15682 }, + { 109,-15682 }, { 110,-15682 }, { 111,-15682 }, { 112,-15682 }, { 113,-15682 }, + { 114,-15682 }, { 115,-15682 }, { 116,-15682 }, { 117,-14908 }, { 118,-15682 }, + + { 119,-15682 }, { 120,-15682 }, { 121,-15682 }, { 122,-15682 }, { 123,-15682 }, + { 124,-15682 }, { 125,-15682 }, { 126,-15682 }, { 127,-15682 }, { 128,-15682 }, + { 129,-15682 }, { 130,-15682 }, { 131,-15682 }, { 132,-15682 }, { 133,-15682 }, + { 134,-15682 }, { 135,-15682 }, { 136,-15682 }, { 137,-15682 }, { 138,-15682 }, + { 139,-15682 }, { 140,-15682 }, { 141,-15682 }, { 142,-15682 }, { 143,-15682 }, + { 144,-15682 }, { 145,-15682 }, { 146,-15682 }, { 147,-15682 }, { 148,-15682 }, + { 149,-15682 }, { 150,-15682 }, { 151,-15682 }, { 152,-15682 }, { 153,-15682 }, + { 154,-15682 }, { 155,-15682 }, { 156,-15682 }, { 157,-15682 }, { 158,-15682 }, + { 159,-15682 }, { 160,-15682 }, { 161,-15682 }, { 162,-15682 }, { 163,-15682 }, + { 164,-15682 }, { 165,-15682 }, { 166,-15682 }, { 167,-15682 }, { 168,-15682 }, + + { 169,-15682 }, { 170,-15682 }, { 171,-15682 }, { 172,-15682 }, { 173,-15682 }, + { 174,-15682 }, { 175,-15682 }, { 176,-15682 }, { 177,-15682 }, { 178,-15682 }, + { 179,-15682 }, { 180,-15682 }, { 181,-15682 }, { 182,-15682 }, { 183,-15682 }, + { 184,-15682 }, { 185,-15682 }, { 186,-15682 }, { 187,-15682 }, { 188,-15682 }, + { 189,-15682 }, { 190,-15682 }, { 191,-15682 }, { 192,-15682 }, { 193,-15682 }, + { 194,-15682 }, { 195,-15682 }, { 196,-15682 }, { 197,-15682 }, { 198,-15682 }, + { 199,-15682 }, { 200,-15682 }, { 201,-15682 }, { 202,-15682 }, { 203,-15682 }, + { 204,-15682 }, { 205,-15682 }, { 206,-15682 }, { 207,-15682 }, { 208,-15682 }, + { 209,-15682 }, { 210,-15682 }, { 211,-15682 }, { 212,-15682 }, { 213,-15682 }, + { 214,-15682 }, { 215,-15682 }, { 216,-15682 }, { 217,-15682 }, { 218,-15682 }, + + { 219,-15682 }, { 220,-15682 }, { 221,-15682 }, { 222,-15682 }, { 223,-15682 }, + { 224,-15682 }, { 225,-15682 }, { 226,-15682 }, { 227,-15682 }, { 228,-15682 }, + { 229,-15682 }, { 230,-15682 }, { 231,-15682 }, { 232,-15682 }, { 233,-15682 }, + { 234,-15682 }, { 235,-15682 }, { 236,-15682 }, { 237,-15682 }, { 238,-15682 }, + { 239,-15682 }, { 240,-15682 }, { 241,-15682 }, { 242,-15682 }, { 243,-15682 }, + { 244,-15682 }, { 245,-15682 }, { 246,-15682 }, { 247,-15682 }, { 248,-15682 }, + { 249,-15682 }, { 250,-15682 }, { 251,-15682 }, { 252,-15682 }, { 253,-15682 }, + { 254,-15682 }, { 255,-15682 }, { 256,-15682 }, { 0, 24 }, { 0,26191 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 9,5048 }, { 10,5048 }, + + { 0, 0 }, { 12,5048 }, { 13,5048 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 32,5048 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 39,5167 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 45,-27025 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 85,-31409 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 117,-31409 }, { 0, 24 }, { 0,26072 }, { 1,5306 }, + { 2,5306 }, { 3,5306 }, { 4,5306 }, { 5,5306 }, { 6,5306 }, + { 7,5306 }, { 8,5306 }, { 9,5564 }, { 10,5822 }, { 11,5306 }, + { 12,5564 }, { 13,5822 }, { 14,5306 }, { 15,5306 }, { 16,5306 }, + { 17,5306 }, { 18,5306 }, { 19,5306 }, { 20,5306 }, { 21,5306 }, + { 22,5306 }, { 23,5306 }, { 24,5306 }, { 25,5306 }, { 26,5306 }, + { 27,5306 }, { 28,5306 }, { 29,5306 }, { 30,5306 }, { 31,5306 }, + { 32,5564 }, { 33,5306 }, { 34,5306 }, { 35,5306 }, { 36,5306 }, + { 37,5306 }, { 38,5306 }, { 39,-16059 }, { 40,5306 }, { 41,5306 }, + + { 42,5306 }, { 43,5306 }, { 44,5306 }, { 45,5941 }, { 46,5306 }, + { 47,5306 }, { 48,5306 }, { 49,5306 }, { 50,5306 }, { 51,5306 }, + { 52,5306 }, { 53,5306 }, { 54,5306 }, { 55,5306 }, { 56,5306 }, + { 57,5306 }, { 58,5306 }, { 59,5306 }, { 60,5306 }, { 61,5306 }, + { 62,5306 }, { 63,5306 }, { 64,5306 }, { 65,5306 }, { 66,5306 }, + { 67,5306 }, { 68,5306 }, { 69,5306 }, { 70,5306 }, { 71,5306 }, + { 72,5306 }, { 73,5306 }, { 74,5306 }, { 75,5306 }, { 76,5306 }, + { 77,5306 }, { 78,5306 }, { 79,5306 }, { 80,5306 }, { 81,5306 }, + { 82,5306 }, { 83,5306 }, { 84,5306 }, { 85,6199 }, { 86,5306 }, + { 87,5306 }, { 88,5306 }, { 89,5306 }, { 90,5306 }, { 91,5306 }, + + { 92,5306 }, { 93,5306 }, { 94,5306 }, { 95,5306 }, { 96,5306 }, + { 97,5306 }, { 98,5306 }, { 99,5306 }, { 100,5306 }, { 101,5306 }, + { 102,5306 }, { 103,5306 }, { 104,5306 }, { 105,5306 }, { 106,5306 }, + { 107,5306 }, { 108,5306 }, { 109,5306 }, { 110,5306 }, { 111,5306 }, + { 112,5306 }, { 113,5306 }, { 114,5306 }, { 115,5306 }, { 116,5306 }, + { 117,6199 }, { 118,5306 }, { 119,5306 }, { 120,5306 }, { 121,5306 }, + { 122,5306 }, { 123,5306 }, { 124,5306 }, { 125,5306 }, { 126,5306 }, + { 127,5306 }, { 128,5306 }, { 129,5306 }, { 130,5306 }, { 131,5306 }, + { 132,5306 }, { 133,5306 }, { 134,5306 }, { 135,5306 }, { 136,5306 }, + { 137,5306 }, { 138,5306 }, { 139,5306 }, { 140,5306 }, { 141,5306 }, + + { 142,5306 }, { 143,5306 }, { 144,5306 }, { 145,5306 }, { 146,5306 }, + { 147,5306 }, { 148,5306 }, { 149,5306 }, { 150,5306 }, { 151,5306 }, + { 152,5306 }, { 153,5306 }, { 154,5306 }, { 155,5306 }, { 156,5306 }, + { 157,5306 }, { 158,5306 }, { 159,5306 }, { 160,5306 }, { 161,5306 }, + { 162,5306 }, { 163,5306 }, { 164,5306 }, { 165,5306 }, { 166,5306 }, + { 167,5306 }, { 168,5306 }, { 169,5306 }, { 170,5306 }, { 171,5306 }, + { 172,5306 }, { 173,5306 }, { 174,5306 }, { 175,5306 }, { 176,5306 }, + { 177,5306 }, { 178,5306 }, { 179,5306 }, { 180,5306 }, { 181,5306 }, + { 182,5306 }, { 183,5306 }, { 184,5306 }, { 185,5306 }, { 186,5306 }, + { 187,5306 }, { 188,5306 }, { 189,5306 }, { 190,5306 }, { 191,5306 }, + + { 192,5306 }, { 193,5306 }, { 194,5306 }, { 195,5306 }, { 196,5306 }, + { 197,5306 }, { 198,5306 }, { 199,5306 }, { 200,5306 }, { 201,5306 }, + { 202,5306 }, { 203,5306 }, { 204,5306 }, { 205,5306 }, { 206,5306 }, + { 207,5306 }, { 208,5306 }, { 209,5306 }, { 210,5306 }, { 211,5306 }, + { 212,5306 }, { 213,5306 }, { 214,5306 }, { 215,5306 }, { 216,5306 }, + { 217,5306 }, { 218,5306 }, { 219,5306 }, { 220,5306 }, { 221,5306 }, + { 222,5306 }, { 223,5306 }, { 224,5306 }, { 225,5306 }, { 226,5306 }, + { 227,5306 }, { 228,5306 }, { 229,5306 }, { 230,5306 }, { 231,5306 }, + { 232,5306 }, { 233,5306 }, { 234,5306 }, { 235,5306 }, { 236,5306 }, + { 237,5306 }, { 238,5306 }, { 239,5306 }, { 240,5306 }, { 241,5306 }, + + { 242,5306 }, { 243,5306 }, { 244,5306 }, { 245,5306 }, { 246,5306 }, + { 247,5306 }, { 248,5306 }, { 249,5306 }, { 250,5306 }, { 251,5306 }, + { 252,5306 }, { 253,5306 }, { 254,5306 }, { 255,5306 }, { 256,5306 }, + { 0, 24 }, { 0,25814 }, { 1,-16317 }, { 2,-16317 }, { 3,-16317 }, + { 4,-16317 }, { 5,-16317 }, { 6,-16317 }, { 7,-16317 }, { 8,-16317 }, + { 9,-16059 }, { 10,-23972 }, { 11,-16317 }, { 12,-16059 }, { 13,-23972 }, + { 14,-16317 }, { 15,-16317 }, { 16,-16317 }, { 17,-16317 }, { 18,-16317 }, + { 19,-16317 }, { 20,-16317 }, { 21,-16317 }, { 22,-16317 }, { 23,-16317 }, + { 24,-16317 }, { 25,-16317 }, { 26,-16317 }, { 27,-16317 }, { 28,-16317 }, + { 29,-16317 }, { 30,-16317 }, { 31,-16317 }, { 32,-16059 }, { 33,-16317 }, + + { 34,-16317 }, { 35,-16317 }, { 36,-16317 }, { 37,-16317 }, { 38,-16317 }, + { 39,-16317 }, { 40,-16317 }, { 41,-16317 }, { 42,-16317 }, { 43,-16317 }, + { 44,-16317 }, { 45,6199 }, { 46,-16317 }, { 47,-16317 }, { 48,-16317 }, + { 49,-16317 }, { 50,-16317 }, { 51,-16317 }, { 52,-16317 }, { 53,-16317 }, + { 54,-16317 }, { 55,-16317 }, { 56,-16317 }, { 57,-16317 }, { 58,-16317 }, + { 59,-16317 }, { 60,-16317 }, { 61,-16317 }, { 62,-16317 }, { 63,-16317 }, + { 64,-16317 }, { 65,-16317 }, { 66,-16317 }, { 67,-16317 }, { 68,-16317 }, + { 69,-16317 }, { 70,-16317 }, { 71,-16317 }, { 72,-16317 }, { 73,-16317 }, + { 74,-16317 }, { 75,-16317 }, { 76,-16317 }, { 77,-16317 }, { 78,-16317 }, + { 79,-16317 }, { 80,-16317 }, { 81,-16317 }, { 82,-16317 }, { 83,-16317 }, + + { 84,-16317 }, { 85,-15543 }, { 86,-16317 }, { 87,-16317 }, { 88,-16317 }, + { 89,-16317 }, { 90,-16317 }, { 91,-16317 }, { 92,-16317 }, { 93,-16317 }, + { 94,-16317 }, { 95,-16317 }, { 96,-16317 }, { 97,-16317 }, { 98,-16317 }, + { 99,-16317 }, { 100,-16317 }, { 101,-16317 }, { 102,-16317 }, { 103,-16317 }, + { 104,-16317 }, { 105,-16317 }, { 106,-16317 }, { 107,-16317 }, { 108,-16317 }, + { 109,-16317 }, { 110,-16317 }, { 111,-16317 }, { 112,-16317 }, { 113,-16317 }, + { 114,-16317 }, { 115,-16317 }, { 116,-16317 }, { 117,-15543 }, { 118,-16317 }, + { 119,-16317 }, { 120,-16317 }, { 121,-16317 }, { 122,-16317 }, { 123,-16317 }, + { 124,-16317 }, { 125,-16317 }, { 126,-16317 }, { 127,-16317 }, { 128,-16317 }, + { 129,-16317 }, { 130,-16317 }, { 131,-16317 }, { 132,-16317 }, { 133,-16317 }, + + { 134,-16317 }, { 135,-16317 }, { 136,-16317 }, { 137,-16317 }, { 138,-16317 }, + { 139,-16317 }, { 140,-16317 }, { 141,-16317 }, { 142,-16317 }, { 143,-16317 }, + { 144,-16317 }, { 145,-16317 }, { 146,-16317 }, { 147,-16317 }, { 148,-16317 }, + { 149,-16317 }, { 150,-16317 }, { 151,-16317 }, { 152,-16317 }, { 153,-16317 }, + { 154,-16317 }, { 155,-16317 }, { 156,-16317 }, { 157,-16317 }, { 158,-16317 }, + { 159,-16317 }, { 160,-16317 }, { 161,-16317 }, { 162,-16317 }, { 163,-16317 }, + { 164,-16317 }, { 165,-16317 }, { 166,-16317 }, { 167,-16317 }, { 168,-16317 }, + { 169,-16317 }, { 170,-16317 }, { 171,-16317 }, { 172,-16317 }, { 173,-16317 }, + { 174,-16317 }, { 175,-16317 }, { 176,-16317 }, { 177,-16317 }, { 178,-16317 }, + { 179,-16317 }, { 180,-16317 }, { 181,-16317 }, { 182,-16317 }, { 183,-16317 }, + + { 184,-16317 }, { 185,-16317 }, { 186,-16317 }, { 187,-16317 }, { 188,-16317 }, + { 189,-16317 }, { 190,-16317 }, { 191,-16317 }, { 192,-16317 }, { 193,-16317 }, + { 194,-16317 }, { 195,-16317 }, { 196,-16317 }, { 197,-16317 }, { 198,-16317 }, + { 199,-16317 }, { 200,-16317 }, { 201,-16317 }, { 202,-16317 }, { 203,-16317 }, + { 204,-16317 }, { 205,-16317 }, { 206,-16317 }, { 207,-16317 }, { 208,-16317 }, + { 209,-16317 }, { 210,-16317 }, { 211,-16317 }, { 212,-16317 }, { 213,-16317 }, + { 214,-16317 }, { 215,-16317 }, { 216,-16317 }, { 217,-16317 }, { 218,-16317 }, + { 219,-16317 }, { 220,-16317 }, { 221,-16317 }, { 222,-16317 }, { 223,-16317 }, + { 224,-16317 }, { 225,-16317 }, { 226,-16317 }, { 227,-16317 }, { 228,-16317 }, + { 229,-16317 }, { 230,-16317 }, { 231,-16317 }, { 232,-16317 }, { 233,-16317 }, + + { 234,-16317 }, { 235,-16317 }, { 236,-16317 }, { 237,-16317 }, { 238,-16317 }, + { 239,-16317 }, { 240,-16317 }, { 241,-16317 }, { 242,-16317 }, { 243,-16317 }, + { 244,-16317 }, { 245,-16317 }, { 246,-16317 }, { 247,-16317 }, { 248,-16317 }, + { 249,-16317 }, { 250,-16317 }, { 251,-16317 }, { 252,-16317 }, { 253,-16317 }, + { 254,-16317 }, { 255,-16317 }, { 256,-16317 }, { 0, 24 }, { 0,25556 }, + { 1, 0 }, { 2, 0 }, { 3, 0 }, { 4, 0 }, { 5, 0 }, + { 6, 0 }, { 7, 0 }, { 8, 0 }, { 9, 258 }, { 10,-4775 }, + { 11, 0 }, { 12, 258 }, { 13,-4775 }, { 14, 0 }, { 15, 0 }, + { 16, 0 }, { 17, 0 }, { 18, 0 }, { 19, 0 }, { 20, 0 }, + { 21, 0 }, { 22, 0 }, { 23, 0 }, { 24, 0 }, { 25, 0 }, + + { 26, 0 }, { 27, 0 }, { 28, 0 }, { 29, 0 }, { 30, 0 }, + { 31, 0 }, { 32, 258 }, { 33, 0 }, { 34, 0 }, { 35, 0 }, + { 36, 0 }, { 37, 0 }, { 38, 0 }, { 39, 516 }, { 40, 0 }, + { 41, 0 }, { 42, 0 }, { 43, 0 }, { 44, 0 }, { 45, 774 }, + { 46, 0 }, { 47, 0 }, { 48, 0 }, { 49, 0 }, { 50, 0 }, + { 51, 0 }, { 52, 0 }, { 53, 0 }, { 54, 0 }, { 55, 0 }, + { 56, 0 }, { 57, 0 }, { 58, 0 }, { 59, 0 }, { 60, 0 }, + { 61, 0 }, { 62, 0 }, { 63, 0 }, { 64, 0 }, { 65, 0 }, + { 66, 0 }, { 67, 0 }, { 68, 0 }, { 69, 0 }, { 70, 0 }, + { 71, 0 }, { 72, 0 }, { 73, 0 }, { 74, 0 }, { 75, 0 }, + + { 76, 0 }, { 77, 0 }, { 78, 0 }, { 79, 0 }, { 80, 0 }, + { 81, 0 }, { 82, 0 }, { 83, 0 }, { 84, 0 }, { 85, 0 }, + { 86, 0 }, { 87, 0 }, { 88, 0 }, { 89, 0 }, { 90, 0 }, + { 91, 0 }, { 92, 0 }, { 93, 0 }, { 94, 0 }, { 95, 0 }, + { 96, 0 }, { 97, 0 }, { 98, 0 }, { 99, 0 }, { 100, 0 }, + { 101, 0 }, { 102, 0 }, { 103, 0 }, { 104, 0 }, { 105, 0 }, + { 106, 0 }, { 107, 0 }, { 108, 0 }, { 109, 0 }, { 110, 0 }, + { 111, 0 }, { 112, 0 }, { 113, 0 }, { 114, 0 }, { 115, 0 }, + { 116, 0 }, { 117, 0 }, { 118, 0 }, { 119, 0 }, { 120, 0 }, + { 121, 0 }, { 122, 0 }, { 123, 0 }, { 124, 0 }, { 125, 0 }, + + { 126, 0 }, { 127, 0 }, { 128, 0 }, { 129, 0 }, { 130, 0 }, + { 131, 0 }, { 132, 0 }, { 133, 0 }, { 134, 0 }, { 135, 0 }, + { 136, 0 }, { 137, 0 }, { 138, 0 }, { 139, 0 }, { 140, 0 }, + { 141, 0 }, { 142, 0 }, { 143, 0 }, { 144, 0 }, { 145, 0 }, + { 146, 0 }, { 147, 0 }, { 148, 0 }, { 149, 0 }, { 150, 0 }, + { 151, 0 }, { 152, 0 }, { 153, 0 }, { 154, 0 }, { 155, 0 }, + { 156, 0 }, { 157, 0 }, { 158, 0 }, { 159, 0 }, { 160, 0 }, + { 161, 0 }, { 162, 0 }, { 163, 0 }, { 164, 0 }, { 165, 0 }, + { 166, 0 }, { 167, 0 }, { 168, 0 }, { 169, 0 }, { 170, 0 }, + { 171, 0 }, { 172, 0 }, { 173, 0 }, { 174, 0 }, { 175, 0 }, + + { 176, 0 }, { 177, 0 }, { 178, 0 }, { 179, 0 }, { 180, 0 }, + { 181, 0 }, { 182, 0 }, { 183, 0 }, { 184, 0 }, { 185, 0 }, + { 186, 0 }, { 187, 0 }, { 188, 0 }, { 189, 0 }, { 190, 0 }, + { 191, 0 }, { 192, 0 }, { 193, 0 }, { 194, 0 }, { 195, 0 }, + { 196, 0 }, { 197, 0 }, { 198, 0 }, { 199, 0 }, { 200, 0 }, + { 201, 0 }, { 202, 0 }, { 203, 0 }, { 204, 0 }, { 205, 0 }, + { 206, 0 }, { 207, 0 }, { 208, 0 }, { 209, 0 }, { 210, 0 }, + { 211, 0 }, { 212, 0 }, { 213, 0 }, { 214, 0 }, { 215, 0 }, + { 216, 0 }, { 217, 0 }, { 218, 0 }, { 219, 0 }, { 220, 0 }, + { 221, 0 }, { 222, 0 }, { 223, 0 }, { 224, 0 }, { 225, 0 }, + + { 226, 0 }, { 227, 0 }, { 228, 0 }, { 229, 0 }, { 230, 0 }, + { 231, 0 }, { 232, 0 }, { 233, 0 }, { 234, 0 }, { 235, 0 }, + { 236, 0 }, { 237, 0 }, { 238, 0 }, { 239, 0 }, { 240, 0 }, + { 241, 0 }, { 242, 0 }, { 243, 0 }, { 244, 0 }, { 245, 0 }, + { 246, 0 }, { 247, 0 }, { 248, 0 }, { 249, 0 }, { 250, 0 }, + { 251, 0 }, { 252, 0 }, { 253, 0 }, { 254, 0 }, { 255, 0 }, + { 256, 0 }, { 0, 24 }, { 0,25298 }, { 1,-258 }, { 2,-258 }, + { 3,-258 }, { 4,-258 }, { 5,-258 }, { 6,-258 }, { 7,-258 }, + { 8,-258 }, { 9, 0 }, { 10,-5033 }, { 11,-258 }, { 12, 0 }, + { 13,-5033 }, { 14,-258 }, { 15,-258 }, { 16,-258 }, { 17,-258 }, + + { 18,-258 }, { 19,-258 }, { 20,-258 }, { 21,-258 }, { 22,-258 }, + { 23,-258 }, { 24,-258 }, { 25,-258 }, { 26,-258 }, { 27,-258 }, + { 28,-258 }, { 29,-258 }, { 30,-258 }, { 31,-258 }, { 32, 0 }, + { 33,-258 }, { 34,-258 }, { 35,-258 }, { 36,-258 }, { 37,-258 }, + { 38,-258 }, { 39, 258 }, { 40,-258 }, { 41,-258 }, { 42,-258 }, + { 43,-258 }, { 44,-258 }, { 45, 516 }, { 46,-258 }, { 47,-258 }, + { 48,-258 }, { 49,-258 }, { 50,-258 }, { 51,-258 }, { 52,-258 }, + { 53,-258 }, { 54,-258 }, { 55,-258 }, { 56,-258 }, { 57,-258 }, + { 58,-258 }, { 59,-258 }, { 60,-258 }, { 61,-258 }, { 62,-258 }, + { 63,-258 }, { 64,-258 }, { 65,-258 }, { 66,-258 }, { 67,-258 }, + + { 68,-258 }, { 69,-258 }, { 70,-258 }, { 71,-258 }, { 72,-258 }, + { 73,-258 }, { 74,-258 }, { 75,-258 }, { 76,-258 }, { 77,-258 }, + { 78,-258 }, { 79,-258 }, { 80,-258 }, { 81,-258 }, { 82,-258 }, + { 83,-258 }, { 84,-258 }, { 85,-258 }, { 86,-258 }, { 87,-258 }, + { 88,-258 }, { 89,-258 }, { 90,-258 }, { 91,-258 }, { 92,-258 }, + { 93,-258 }, { 94,-258 }, { 95,-258 }, { 96,-258 }, { 97,-258 }, + { 98,-258 }, { 99,-258 }, { 100,-258 }, { 101,-258 }, { 102,-258 }, + { 103,-258 }, { 104,-258 }, { 105,-258 }, { 106,-258 }, { 107,-258 }, + { 108,-258 }, { 109,-258 }, { 110,-258 }, { 111,-258 }, { 112,-258 }, + { 113,-258 }, { 114,-258 }, { 115,-258 }, { 116,-258 }, { 117,-258 }, + + { 118,-258 }, { 119,-258 }, { 120,-258 }, { 121,-258 }, { 122,-258 }, + { 123,-258 }, { 124,-258 }, { 125,-258 }, { 126,-258 }, { 127,-258 }, + { 128,-258 }, { 129,-258 }, { 130,-258 }, { 131,-258 }, { 132,-258 }, + { 133,-258 }, { 134,-258 }, { 135,-258 }, { 136,-258 }, { 137,-258 }, + { 138,-258 }, { 139,-258 }, { 140,-258 }, { 141,-258 }, { 142,-258 }, + { 143,-258 }, { 144,-258 }, { 145,-258 }, { 146,-258 }, { 147,-258 }, + { 148,-258 }, { 149,-258 }, { 150,-258 }, { 151,-258 }, { 152,-258 }, + { 153,-258 }, { 154,-258 }, { 155,-258 }, { 156,-258 }, { 157,-258 }, + { 158,-258 }, { 159,-258 }, { 160,-258 }, { 161,-258 }, { 162,-258 }, + { 163,-258 }, { 164,-258 }, { 165,-258 }, { 166,-258 }, { 167,-258 }, + + { 168,-258 }, { 169,-258 }, { 170,-258 }, { 171,-258 }, { 172,-258 }, + { 173,-258 }, { 174,-258 }, { 175,-258 }, { 176,-258 }, { 177,-258 }, + { 178,-258 }, { 179,-258 }, { 180,-258 }, { 181,-258 }, { 182,-258 }, + { 183,-258 }, { 184,-258 }, { 185,-258 }, { 186,-258 }, { 187,-258 }, + { 188,-258 }, { 189,-258 }, { 190,-258 }, { 191,-258 }, { 192,-258 }, + { 193,-258 }, { 194,-258 }, { 195,-258 }, { 196,-258 }, { 197,-258 }, + { 198,-258 }, { 199,-258 }, { 200,-258 }, { 201,-258 }, { 202,-258 }, + { 203,-258 }, { 204,-258 }, { 205,-258 }, { 206,-258 }, { 207,-258 }, + { 208,-258 }, { 209,-258 }, { 210,-258 }, { 211,-258 }, { 212,-258 }, + { 213,-258 }, { 214,-258 }, { 215,-258 }, { 216,-258 }, { 217,-258 }, + + { 218,-258 }, { 219,-258 }, { 220,-258 }, { 221,-258 }, { 222,-258 }, + { 223,-258 }, { 224,-258 }, { 225,-258 }, { 226,-258 }, { 227,-258 }, + { 228,-258 }, { 229,-258 }, { 230,-258 }, { 231,-258 }, { 232,-258 }, + { 233,-258 }, { 234,-258 }, { 235,-258 }, { 236,-258 }, { 237,-258 }, + { 238,-258 }, { 239,-258 }, { 240,-258 }, { 241,-258 }, { 242,-258 }, + { 243,-258 }, { 244,-258 }, { 245,-258 }, { 246,-258 }, { 247,-258 }, + { 248,-258 }, { 249,-258 }, { 250,-258 }, { 251,-258 }, { 252,-258 }, + { 253,-258 }, { 254,-258 }, { 255,-258 }, { 256,-258 }, { 0, 24 }, + { 0,25040 }, { 1,5683 }, { 2,5683 }, { 3,5683 }, { 4,5683 }, + { 5,5683 }, { 6,5683 }, { 7,5683 }, { 8,5683 }, { 9,5941 }, + + { 10,6199 }, { 11,5683 }, { 12,5941 }, { 13,6199 }, { 14,5683 }, + { 15,5683 }, { 16,5683 }, { 17,5683 }, { 18,5683 }, { 19,5683 }, + { 20,5683 }, { 21,5683 }, { 22,5683 }, { 23,5683 }, { 24,5683 }, + { 25,5683 }, { 26,5683 }, { 27,5683 }, { 28,5683 }, { 29,5683 }, + { 30,5683 }, { 31,5683 }, { 32,5941 }, { 33,5683 }, { 34,5683 }, + { 35,5683 }, { 36,5683 }, { 37,5683 }, { 38,5683 }, { 39, 0 }, + { 40,5683 }, { 41,5683 }, { 42,5683 }, { 43,5683 }, { 44,5683 }, + { 45,6246 }, { 46,5683 }, { 47,5683 }, { 48,5683 }, { 49,5683 }, + { 50,5683 }, { 51,5683 }, { 52,5683 }, { 53,5683 }, { 54,5683 }, + { 55,5683 }, { 56,5683 }, { 57,5683 }, { 58,5683 }, { 59,5683 }, + + { 60,5683 }, { 61,5683 }, { 62,5683 }, { 63,5683 }, { 64,5683 }, + { 65,5683 }, { 66,5683 }, { 67,5683 }, { 68,5683 }, { 69,5683 }, + { 70,5683 }, { 71,5683 }, { 72,5683 }, { 73,5683 }, { 74,5683 }, + { 75,5683 }, { 76,5683 }, { 77,5683 }, { 78,5683 }, { 79,5683 }, + { 80,5683 }, { 81,5683 }, { 82,5683 }, { 83,5683 }, { 84,5683 }, + { 85,5683 }, { 86,5683 }, { 87,5683 }, { 88,5683 }, { 89,5683 }, + { 90,5683 }, { 91,5683 }, { 92,5683 }, { 93,5683 }, { 94,5683 }, + { 95,5683 }, { 96,5683 }, { 97,5683 }, { 98,5683 }, { 99,5683 }, + { 100,5683 }, { 101,5683 }, { 102,5683 }, { 103,5683 }, { 104,5683 }, + { 105,5683 }, { 106,5683 }, { 107,5683 }, { 108,5683 }, { 109,5683 }, + + { 110,5683 }, { 111,5683 }, { 112,5683 }, { 113,5683 }, { 114,5683 }, + { 115,5683 }, { 116,5683 }, { 117,5683 }, { 118,5683 }, { 119,5683 }, + { 120,5683 }, { 121,5683 }, { 122,5683 }, { 123,5683 }, { 124,5683 }, + { 125,5683 }, { 126,5683 }, { 127,5683 }, { 128,5683 }, { 129,5683 }, + { 130,5683 }, { 131,5683 }, { 132,5683 }, { 133,5683 }, { 134,5683 }, + { 135,5683 }, { 136,5683 }, { 137,5683 }, { 138,5683 }, { 139,5683 }, + { 140,5683 }, { 141,5683 }, { 142,5683 }, { 143,5683 }, { 144,5683 }, + { 145,5683 }, { 146,5683 }, { 147,5683 }, { 148,5683 }, { 149,5683 }, + { 150,5683 }, { 151,5683 }, { 152,5683 }, { 153,5683 }, { 154,5683 }, + { 155,5683 }, { 156,5683 }, { 157,5683 }, { 158,5683 }, { 159,5683 }, + + { 160,5683 }, { 161,5683 }, { 162,5683 }, { 163,5683 }, { 164,5683 }, + { 165,5683 }, { 166,5683 }, { 167,5683 }, { 168,5683 }, { 169,5683 }, + { 170,5683 }, { 171,5683 }, { 172,5683 }, { 173,5683 }, { 174,5683 }, + { 175,5683 }, { 176,5683 }, { 177,5683 }, { 178,5683 }, { 179,5683 }, + { 180,5683 }, { 181,5683 }, { 182,5683 }, { 183,5683 }, { 184,5683 }, + { 185,5683 }, { 186,5683 }, { 187,5683 }, { 188,5683 }, { 189,5683 }, + { 190,5683 }, { 191,5683 }, { 192,5683 }, { 193,5683 }, { 194,5683 }, + { 195,5683 }, { 196,5683 }, { 197,5683 }, { 198,5683 }, { 199,5683 }, + { 200,5683 }, { 201,5683 }, { 202,5683 }, { 203,5683 }, { 204,5683 }, + { 205,5683 }, { 206,5683 }, { 207,5683 }, { 208,5683 }, { 209,5683 }, + + { 210,5683 }, { 211,5683 }, { 212,5683 }, { 213,5683 }, { 214,5683 }, + { 215,5683 }, { 216,5683 }, { 217,5683 }, { 218,5683 }, { 219,5683 }, + { 220,5683 }, { 221,5683 }, { 222,5683 }, { 223,5683 }, { 224,5683 }, + { 225,5683 }, { 226,5683 }, { 227,5683 }, { 228,5683 }, { 229,5683 }, + { 230,5683 }, { 231,5683 }, { 232,5683 }, { 233,5683 }, { 234,5683 }, + { 235,5683 }, { 236,5683 }, { 237,5683 }, { 238,5683 }, { 239,5683 }, + { 240,5683 }, { 241,5683 }, { 242,5683 }, { 243,5683 }, { 244,5683 }, + { 245,5683 }, { 246,5683 }, { 247,5683 }, { 248,5683 }, { 249,5683 }, + { 250,5683 }, { 251,5683 }, { 252,5683 }, { 253,5683 }, { 254,5683 }, + { 255,5683 }, { 256,5683 }, { 0, 24 }, { 0,24782 }, { 1,-774 }, + + { 2,-774 }, { 3,-774 }, { 4,-774 }, { 5,-774 }, { 6,-774 }, + { 7,-774 }, { 8,-774 }, { 9,-516 }, { 10,-5549 }, { 11,-774 }, + { 12,-516 }, { 13,-5549 }, { 14,-774 }, { 15,-774 }, { 16,-774 }, + { 17,-774 }, { 18,-774 }, { 19,-774 }, { 20,-774 }, { 21,-774 }, + { 22,-774 }, { 23,-774 }, { 24,-774 }, { 25,-774 }, { 26,-774 }, + { 27,-774 }, { 28,-774 }, { 29,-774 }, { 30,-774 }, { 31,-774 }, + { 32,-516 }, { 33,-774 }, { 34,-774 }, { 35,-774 }, { 36,-774 }, + { 37,-774 }, { 38,-774 }, { 39,-258 }, { 40,-774 }, { 41,-774 }, + { 42,-774 }, { 43,-774 }, { 44,-774 }, { 45,6246 }, { 46,-774 }, + { 47,-774 }, { 48,-774 }, { 49,-774 }, { 50,-774 }, { 51,-774 }, + + { 52,-774 }, { 53,-774 }, { 54,-774 }, { 55,-774 }, { 56,-774 }, + { 57,-774 }, { 58,-774 }, { 59,-774 }, { 60,-774 }, { 61,-774 }, + { 62,-774 }, { 63,-774 }, { 64,-774 }, { 65,-774 }, { 66,-774 }, + { 67,-774 }, { 68,-774 }, { 69,-774 }, { 70,-774 }, { 71,-774 }, + { 72,-774 }, { 73,-774 }, { 74,-774 }, { 75,-774 }, { 76,-774 }, + { 77,-774 }, { 78,-774 }, { 79,-774 }, { 80,-774 }, { 81,-774 }, + { 82,-774 }, { 83,-774 }, { 84,-774 }, { 85,-774 }, { 86,-774 }, + { 87,-774 }, { 88,-774 }, { 89,-774 }, { 90,-774 }, { 91,-774 }, + { 92,-774 }, { 93,-774 }, { 94,-774 }, { 95,-774 }, { 96,-774 }, + { 97,-774 }, { 98,-774 }, { 99,-774 }, { 100,-774 }, { 101,-774 }, + + { 102,-774 }, { 103,-774 }, { 104,-774 }, { 105,-774 }, { 106,-774 }, + { 107,-774 }, { 108,-774 }, { 109,-774 }, { 110,-774 }, { 111,-774 }, + { 112,-774 }, { 113,-774 }, { 114,-774 }, { 115,-774 }, { 116,-774 }, + { 117,-774 }, { 118,-774 }, { 119,-774 }, { 120,-774 }, { 121,-774 }, + { 122,-774 }, { 123,-774 }, { 124,-774 }, { 125,-774 }, { 126,-774 }, + { 127,-774 }, { 128,-774 }, { 129,-774 }, { 130,-774 }, { 131,-774 }, + { 132,-774 }, { 133,-774 }, { 134,-774 }, { 135,-774 }, { 136,-774 }, + { 137,-774 }, { 138,-774 }, { 139,-774 }, { 140,-774 }, { 141,-774 }, + { 142,-774 }, { 143,-774 }, { 144,-774 }, { 145,-774 }, { 146,-774 }, + { 147,-774 }, { 148,-774 }, { 149,-774 }, { 150,-774 }, { 151,-774 }, + + { 152,-774 }, { 153,-774 }, { 154,-774 }, { 155,-774 }, { 156,-774 }, + { 157,-774 }, { 158,-774 }, { 159,-774 }, { 160,-774 }, { 161,-774 }, + { 162,-774 }, { 163,-774 }, { 164,-774 }, { 165,-774 }, { 166,-774 }, + { 167,-774 }, { 168,-774 }, { 169,-774 }, { 170,-774 }, { 171,-774 }, + { 172,-774 }, { 173,-774 }, { 174,-774 }, { 175,-774 }, { 176,-774 }, + { 177,-774 }, { 178,-774 }, { 179,-774 }, { 180,-774 }, { 181,-774 }, + { 182,-774 }, { 183,-774 }, { 184,-774 }, { 185,-774 }, { 186,-774 }, + { 187,-774 }, { 188,-774 }, { 189,-774 }, { 190,-774 }, { 191,-774 }, + { 192,-774 }, { 193,-774 }, { 194,-774 }, { 195,-774 }, { 196,-774 }, + { 197,-774 }, { 198,-774 }, { 199,-774 }, { 200,-774 }, { 201,-774 }, + + { 202,-774 }, { 203,-774 }, { 204,-774 }, { 205,-774 }, { 206,-774 }, + { 207,-774 }, { 208,-774 }, { 209,-774 }, { 210,-774 }, { 211,-774 }, + { 212,-774 }, { 213,-774 }, { 214,-774 }, { 215,-774 }, { 216,-774 }, + { 217,-774 }, { 218,-774 }, { 219,-774 }, { 220,-774 }, { 221,-774 }, + { 222,-774 }, { 223,-774 }, { 224,-774 }, { 225,-774 }, { 226,-774 }, + { 227,-774 }, { 228,-774 }, { 229,-774 }, { 230,-774 }, { 231,-774 }, + { 232,-774 }, { 233,-774 }, { 234,-774 }, { 235,-774 }, { 236,-774 }, + { 237,-774 }, { 238,-774 }, { 239,-774 }, { 240,-774 }, { 241,-774 }, + { 242,-774 }, { 243,-774 }, { 244,-774 }, { 245,-774 }, { 246,-774 }, + { 247,-774 }, { 248,-774 }, { 249,-774 }, { 250,-774 }, { 251,-774 }, + + { 252,-774 }, { 253,-774 }, { 254,-774 }, { 255,-774 }, { 256,-774 }, + { 0, 48 }, { 0,24524 }, { 1,-18897 }, { 2,-18897 }, { 3,-18897 }, + { 4,-18897 }, { 5,-18897 }, { 6,-18897 }, { 7,-18897 }, { 8,-18897 }, + { 9,-18639 }, { 10,-25283 }, { 11,-18897 }, { 12,-18639 }, { 13,-25283 }, + { 14,-18897 }, { 15,-18897 }, { 16,-18897 }, { 17,-18897 }, { 18,-18897 }, + { 19,-18897 }, { 20,-18897 }, { 21,-18897 }, { 22,-18897 }, { 23,-18897 }, + { 24,-18897 }, { 25,-18897 }, { 26,-18897 }, { 27,-18897 }, { 28,-18897 }, + { 29,-18897 }, { 30,-18897 }, { 31,-18897 }, { 32,-18639 }, { 33,-18897 }, + { 34,-18897 }, { 35,-18897 }, { 36,-18897 }, { 37,-18897 }, { 38,-18897 }, + { 39,6504 }, { 40,-18897 }, { 41,-18897 }, { 42,-18897 }, { 43,-18897 }, + + { 44,-18897 }, { 45,-18381 }, { 46,-18897 }, { 47,-18897 }, { 48,-18897 }, + { 49,-18897 }, { 50,-18897 }, { 51,-18897 }, { 52,-18897 }, { 53,-18897 }, + { 54,-18897 }, { 55,-18897 }, { 56,-18897 }, { 57,-18897 }, { 58,-18897 }, + { 59,-18897 }, { 60,-18897 }, { 61,-18897 }, { 62,-18897 }, { 63,-18897 }, + { 64,-18897 }, { 65,-18897 }, { 66,-18897 }, { 67,-18897 }, { 68,-18897 }, + { 69,-18897 }, { 70,-18897 }, { 71,-18897 }, { 72,-18897 }, { 73,-18897 }, + { 74,-18897 }, { 75,-18897 }, { 76,-18897 }, { 77,-18897 }, { 78,-18897 }, + { 79,-18897 }, { 80,-18897 }, { 81,-18897 }, { 82,-18897 }, { 83,-18897 }, + { 84,-18897 }, { 85,-18123 }, { 86,-18897 }, { 87,-18897 }, { 88,-18897 }, + { 89,-18897 }, { 90,-18897 }, { 91,-18897 }, { 92,-18897 }, { 93,-18897 }, + + { 94,-18897 }, { 95,-18897 }, { 96,-18897 }, { 97,-18897 }, { 98,-18897 }, + { 99,-18897 }, { 100,-18897 }, { 101,-18897 }, { 102,-18897 }, { 103,-18897 }, + { 104,-18897 }, { 105,-18897 }, { 106,-18897 }, { 107,-18897 }, { 108,-18897 }, + { 109,-18897 }, { 110,-18897 }, { 111,-18897 }, { 112,-18897 }, { 113,-18897 }, + { 114,-18897 }, { 115,-18897 }, { 116,-18897 }, { 117,-18123 }, { 118,-18897 }, + { 119,-18897 }, { 120,-18897 }, { 121,-18897 }, { 122,-18897 }, { 123,-18897 }, + { 124,-18897 }, { 125,-18897 }, { 126,-18897 }, { 127,-18897 }, { 128,-18897 }, + { 129,-18897 }, { 130,-18897 }, { 131,-18897 }, { 132,-18897 }, { 133,-18897 }, + { 134,-18897 }, { 135,-18897 }, { 136,-18897 }, { 137,-18897 }, { 138,-18897 }, + { 139,-18897 }, { 140,-18897 }, { 141,-18897 }, { 142,-18897 }, { 143,-18897 }, + + { 144,-18897 }, { 145,-18897 }, { 146,-18897 }, { 147,-18897 }, { 148,-18897 }, + { 149,-18897 }, { 150,-18897 }, { 151,-18897 }, { 152,-18897 }, { 153,-18897 }, + { 154,-18897 }, { 155,-18897 }, { 156,-18897 }, { 157,-18897 }, { 158,-18897 }, + { 159,-18897 }, { 160,-18897 }, { 161,-18897 }, { 162,-18897 }, { 163,-18897 }, + { 164,-18897 }, { 165,-18897 }, { 166,-18897 }, { 167,-18897 }, { 168,-18897 }, + { 169,-18897 }, { 170,-18897 }, { 171,-18897 }, { 172,-18897 }, { 173,-18897 }, + { 174,-18897 }, { 175,-18897 }, { 176,-18897 }, { 177,-18897 }, { 178,-18897 }, + { 179,-18897 }, { 180,-18897 }, { 181,-18897 }, { 182,-18897 }, { 183,-18897 }, + { 184,-18897 }, { 185,-18897 }, { 186,-18897 }, { 187,-18897 }, { 188,-18897 }, + { 189,-18897 }, { 190,-18897 }, { 191,-18897 }, { 192,-18897 }, { 193,-18897 }, + + { 194,-18897 }, { 195,-18897 }, { 196,-18897 }, { 197,-18897 }, { 198,-18897 }, + { 199,-18897 }, { 200,-18897 }, { 201,-18897 }, { 202,-18897 }, { 203,-18897 }, + { 204,-18897 }, { 205,-18897 }, { 206,-18897 }, { 207,-18897 }, { 208,-18897 }, + { 209,-18897 }, { 210,-18897 }, { 211,-18897 }, { 212,-18897 }, { 213,-18897 }, + { 214,-18897 }, { 215,-18897 }, { 216,-18897 }, { 217,-18897 }, { 218,-18897 }, + { 219,-18897 }, { 220,-18897 }, { 221,-18897 }, { 222,-18897 }, { 223,-18897 }, + { 224,-18897 }, { 225,-18897 }, { 226,-18897 }, { 227,-18897 }, { 228,-18897 }, + { 229,-18897 }, { 230,-18897 }, { 231,-18897 }, { 232,-18897 }, { 233,-18897 }, + { 234,-18897 }, { 235,-18897 }, { 236,-18897 }, { 237,-18897 }, { 238,-18897 }, + { 239,-18897 }, { 240,-18897 }, { 241,-18897 }, { 242,-18897 }, { 243,-18897 }, + + { 244,-18897 }, { 245,-18897 }, { 246,-18897 }, { 247,-18897 }, { 248,-18897 }, + { 249,-18897 }, { 250,-18897 }, { 251,-18897 }, { 252,-18897 }, { 253,-18897 }, + { 254,-18897 }, { 255,-18897 }, { 256,-18897 }, { 0, 48 }, { 0,24266 }, + { 1,-19155 }, { 2,-19155 }, { 3,-19155 }, { 4,-19155 }, { 5,-19155 }, + { 6,-19155 }, { 7,-19155 }, { 8,-19155 }, { 9,-18897 }, { 10,-25541 }, + { 11,-19155 }, { 12,-18897 }, { 13,-25541 }, { 14,-19155 }, { 15,-19155 }, + { 16,-19155 }, { 17,-19155 }, { 18,-19155 }, { 19,-19155 }, { 20,-19155 }, + { 21,-19155 }, { 22,-19155 }, { 23,-19155 }, { 24,-19155 }, { 25,-19155 }, + { 26,-19155 }, { 27,-19155 }, { 28,-19155 }, { 29,-19155 }, { 30,-19155 }, + { 31,-19155 }, { 32,-18897 }, { 33,-19155 }, { 34,-19155 }, { 35,-19155 }, + + { 36,-19155 }, { 37,-19155 }, { 38,-19155 }, { 39,6246 }, { 40,-19155 }, + { 41,-19155 }, { 42,-19155 }, { 43,-19155 }, { 44,-19155 }, { 45,-18639 }, + { 46,-19155 }, { 47,-19155 }, { 48,-19155 }, { 49,-19155 }, { 50,-19155 }, + { 51,-19155 }, { 52,-19155 }, { 53,-19155 }, { 54,-19155 }, { 55,-19155 }, + { 56,-19155 }, { 57,-19155 }, { 58,-19155 }, { 59,-19155 }, { 60,-19155 }, + { 61,-19155 }, { 62,-19155 }, { 63,-19155 }, { 64,-19155 }, { 65,-19155 }, + { 66,-19155 }, { 67,-19155 }, { 68,-19155 }, { 69,-19155 }, { 70,-19155 }, + { 71,-19155 }, { 72,-19155 }, { 73,-19155 }, { 74,-19155 }, { 75,-19155 }, + { 76,-19155 }, { 77,-19155 }, { 78,-19155 }, { 79,-19155 }, { 80,-19155 }, + { 81,-19155 }, { 82,-19155 }, { 83,-19155 }, { 84,-19155 }, { 85,-18381 }, + + { 86,-19155 }, { 87,-19155 }, { 88,-19155 }, { 89,-19155 }, { 90,-19155 }, + { 91,-19155 }, { 92,-19155 }, { 93,-19155 }, { 94,-19155 }, { 95,-19155 }, + { 96,-19155 }, { 97,-19155 }, { 98,-19155 }, { 99,-19155 }, { 100,-19155 }, + { 101,-19155 }, { 102,-19155 }, { 103,-19155 }, { 104,-19155 }, { 105,-19155 }, + { 106,-19155 }, { 107,-19155 }, { 108,-19155 }, { 109,-19155 }, { 110,-19155 }, + { 111,-19155 }, { 112,-19155 }, { 113,-19155 }, { 114,-19155 }, { 115,-19155 }, + { 116,-19155 }, { 117,-18381 }, { 118,-19155 }, { 119,-19155 }, { 120,-19155 }, + { 121,-19155 }, { 122,-19155 }, { 123,-19155 }, { 124,-19155 }, { 125,-19155 }, + { 126,-19155 }, { 127,-19155 }, { 128,-19155 }, { 129,-19155 }, { 130,-19155 }, + { 131,-19155 }, { 132,-19155 }, { 133,-19155 }, { 134,-19155 }, { 135,-19155 }, + + { 136,-19155 }, { 137,-19155 }, { 138,-19155 }, { 139,-19155 }, { 140,-19155 }, + { 141,-19155 }, { 142,-19155 }, { 143,-19155 }, { 144,-19155 }, { 145,-19155 }, + { 146,-19155 }, { 147,-19155 }, { 148,-19155 }, { 149,-19155 }, { 150,-19155 }, + { 151,-19155 }, { 152,-19155 }, { 153,-19155 }, { 154,-19155 }, { 155,-19155 }, + { 156,-19155 }, { 157,-19155 }, { 158,-19155 }, { 159,-19155 }, { 160,-19155 }, + { 161,-19155 }, { 162,-19155 }, { 163,-19155 }, { 164,-19155 }, { 165,-19155 }, + { 166,-19155 }, { 167,-19155 }, { 168,-19155 }, { 169,-19155 }, { 170,-19155 }, + { 171,-19155 }, { 172,-19155 }, { 173,-19155 }, { 174,-19155 }, { 175,-19155 }, + { 176,-19155 }, { 177,-19155 }, { 178,-19155 }, { 179,-19155 }, { 180,-19155 }, + { 181,-19155 }, { 182,-19155 }, { 183,-19155 }, { 184,-19155 }, { 185,-19155 }, + + { 186,-19155 }, { 187,-19155 }, { 188,-19155 }, { 189,-19155 }, { 190,-19155 }, + { 191,-19155 }, { 192,-19155 }, { 193,-19155 }, { 194,-19155 }, { 195,-19155 }, + { 196,-19155 }, { 197,-19155 }, { 198,-19155 }, { 199,-19155 }, { 200,-19155 }, + { 201,-19155 }, { 202,-19155 }, { 203,-19155 }, { 204,-19155 }, { 205,-19155 }, + { 206,-19155 }, { 207,-19155 }, { 208,-19155 }, { 209,-19155 }, { 210,-19155 }, + { 211,-19155 }, { 212,-19155 }, { 213,-19155 }, { 214,-19155 }, { 215,-19155 }, + { 216,-19155 }, { 217,-19155 }, { 218,-19155 }, { 219,-19155 }, { 220,-19155 }, + { 221,-19155 }, { 222,-19155 }, { 223,-19155 }, { 224,-19155 }, { 225,-19155 }, + { 226,-19155 }, { 227,-19155 }, { 228,-19155 }, { 229,-19155 }, { 230,-19155 }, + { 231,-19155 }, { 232,-19155 }, { 233,-19155 }, { 234,-19155 }, { 235,-19155 }, + + { 236,-19155 }, { 237,-19155 }, { 238,-19155 }, { 239,-19155 }, { 240,-19155 }, + { 241,-19155 }, { 242,-19155 }, { 243,-19155 }, { 244,-19155 }, { 245,-19155 }, + { 246,-19155 }, { 247,-19155 }, { 248,-19155 }, { 249,-19155 }, { 250,-19155 }, + { 251,-19155 }, { 252,-19155 }, { 253,-19155 }, { 254,-19155 }, { 255,-19155 }, + { 256,-19155 }, { 0, 48 }, { 0,24008 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 9,-25799 }, { 10,-25799 }, { 0, 0 }, { 12,-25799 }, + { 13,-25799 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 32,-25799 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 39,-29243 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 45,-34082 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 85,-33849 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 117,-33849 }, + { 0, 48 }, { 0,23889 }, { 1,-19532 }, { 2,-19532 }, { 3,-19532 }, + { 4,-19532 }, { 5,-19532 }, { 6,-19532 }, { 7,-19532 }, { 8,-19532 }, + + { 9,-19274 }, { 10,-25918 }, { 11,-19532 }, { 12,-19274 }, { 13,-25918 }, + { 14,-19532 }, { 15,-19532 }, { 16,-19532 }, { 17,-19532 }, { 18,-19532 }, + { 19,-19532 }, { 20,-19532 }, { 21,-19532 }, { 22,-19532 }, { 23,-19532 }, + { 24,-19532 }, { 25,-19532 }, { 26,-19532 }, { 27,-19532 }, { 28,-19532 }, + { 29,-19532 }, { 30,-19532 }, { 31,-19532 }, { 32,-19274 }, { 33,-19532 }, + { 34,-19532 }, { 35,-19532 }, { 36,-19532 }, { 37,-19532 }, { 38,-19532 }, + { 39,5869 }, { 40,-19532 }, { 41,-19532 }, { 42,-19532 }, { 43,-19532 }, + { 44,-19532 }, { 45,-13719 }, { 46,-19532 }, { 47,-19532 }, { 48,-19532 }, + { 49,-19532 }, { 50,-19532 }, { 51,-19532 }, { 52,-19532 }, { 53,-19532 }, + { 54,-19532 }, { 55,-19532 }, { 56,-19532 }, { 57,-19532 }, { 58,-19532 }, + + { 59,-19532 }, { 60,-19532 }, { 61,-19532 }, { 62,-19532 }, { 63,-19532 }, + { 64,-19532 }, { 65,-19532 }, { 66,-19532 }, { 67,-19532 }, { 68,-19532 }, + { 69,-19532 }, { 70,-19532 }, { 71,-19532 }, { 72,-19532 }, { 73,-19532 }, + { 74,-19532 }, { 75,-19532 }, { 76,-19532 }, { 77,-19532 }, { 78,-19532 }, + { 79,-19532 }, { 80,-19532 }, { 81,-19532 }, { 82,-19532 }, { 83,-19532 }, + { 84,-19532 }, { 85,-18758 }, { 86,-19532 }, { 87,-19532 }, { 88,-19532 }, + { 89,-19532 }, { 90,-19532 }, { 91,-19532 }, { 92,-19532 }, { 93,-19532 }, + { 94,-19532 }, { 95,-19532 }, { 96,-19532 }, { 97,-19532 }, { 98,-19532 }, + { 99,-19532 }, { 100,-19532 }, { 101,-19532 }, { 102,-19532 }, { 103,-19532 }, + { 104,-19532 }, { 105,-19532 }, { 106,-19532 }, { 107,-19532 }, { 108,-19532 }, + + { 109,-19532 }, { 110,-19532 }, { 111,-19532 }, { 112,-19532 }, { 113,-19532 }, + { 114,-19532 }, { 115,-19532 }, { 116,-19532 }, { 117,-18758 }, { 118,-19532 }, + { 119,-19532 }, { 120,-19532 }, { 121,-19532 }, { 122,-19532 }, { 123,-19532 }, + { 124,-19532 }, { 125,-19532 }, { 126,-19532 }, { 127,-19532 }, { 128,-19532 }, + { 129,-19532 }, { 130,-19532 }, { 131,-19532 }, { 132,-19532 }, { 133,-19532 }, + { 134,-19532 }, { 135,-19532 }, { 136,-19532 }, { 137,-19532 }, { 138,-19532 }, + { 139,-19532 }, { 140,-19532 }, { 141,-19532 }, { 142,-19532 }, { 143,-19532 }, + { 144,-19532 }, { 145,-19532 }, { 146,-19532 }, { 147,-19532 }, { 148,-19532 }, + { 149,-19532 }, { 150,-19532 }, { 151,-19532 }, { 152,-19532 }, { 153,-19532 }, + { 154,-19532 }, { 155,-19532 }, { 156,-19532 }, { 157,-19532 }, { 158,-19532 }, + + { 159,-19532 }, { 160,-19532 }, { 161,-19532 }, { 162,-19532 }, { 163,-19532 }, + { 164,-19532 }, { 165,-19532 }, { 166,-19532 }, { 167,-19532 }, { 168,-19532 }, + { 169,-19532 }, { 170,-19532 }, { 171,-19532 }, { 172,-19532 }, { 173,-19532 }, + { 174,-19532 }, { 175,-19532 }, { 176,-19532 }, { 177,-19532 }, { 178,-19532 }, + { 179,-19532 }, { 180,-19532 }, { 181,-19532 }, { 182,-19532 }, { 183,-19532 }, + { 184,-19532 }, { 185,-19532 }, { 186,-19532 }, { 187,-19532 }, { 188,-19532 }, + { 189,-19532 }, { 190,-19532 }, { 191,-19532 }, { 192,-19532 }, { 193,-19532 }, + { 194,-19532 }, { 195,-19532 }, { 196,-19532 }, { 197,-19532 }, { 198,-19532 }, + { 199,-19532 }, { 200,-19532 }, { 201,-19532 }, { 202,-19532 }, { 203,-19532 }, + { 204,-19532 }, { 205,-19532 }, { 206,-19532 }, { 207,-19532 }, { 208,-19532 }, + + { 209,-19532 }, { 210,-19532 }, { 211,-19532 }, { 212,-19532 }, { 213,-19532 }, + { 214,-19532 }, { 215,-19532 }, { 216,-19532 }, { 217,-19532 }, { 218,-19532 }, + { 219,-19532 }, { 220,-19532 }, { 221,-19532 }, { 222,-19532 }, { 223,-19532 }, + { 224,-19532 }, { 225,-19532 }, { 226,-19532 }, { 227,-19532 }, { 228,-19532 }, + { 229,-19532 }, { 230,-19532 }, { 231,-19532 }, { 232,-19532 }, { 233,-19532 }, + { 234,-19532 }, { 235,-19532 }, { 236,-19532 }, { 237,-19532 }, { 238,-19532 }, + { 239,-19532 }, { 240,-19532 }, { 241,-19532 }, { 242,-19532 }, { 243,-19532 }, + { 244,-19532 }, { 245,-19532 }, { 246,-19532 }, { 247,-19532 }, { 248,-19532 }, + { 249,-19532 }, { 250,-19532 }, { 251,-19532 }, { 252,-19532 }, { 253,-19532 }, + { 254,-19532 }, { 255,-19532 }, { 256,-19532 }, { 0, 48 }, { 0,23631 }, + + { 1,-19790 }, { 2,-19790 }, { 3,-19790 }, { 4,-19790 }, { 5,-19790 }, + { 6,-19790 }, { 7,-19790 }, { 8,-19790 }, { 9,-19532 }, { 10,-26176 }, + { 11,-19790 }, { 12,-19532 }, { 13,-26176 }, { 14,-19790 }, { 15,-19790 }, + { 16,-19790 }, { 17,-19790 }, { 18,-19790 }, { 19,-19790 }, { 20,-19790 }, + { 21,-19790 }, { 22,-19790 }, { 23,-19790 }, { 24,-19790 }, { 25,-19790 }, + { 26,-19790 }, { 27,-19790 }, { 28,-19790 }, { 29,-19790 }, { 30,-19790 }, + { 31,-19790 }, { 32,-19532 }, { 33,-19790 }, { 34,-19790 }, { 35,-19790 }, + { 36,-19790 }, { 37,-19790 }, { 38,-19790 }, { 39,5611 }, { 40,-19790 }, + { 41,-19790 }, { 42,-19790 }, { 43,-19790 }, { 44,-19790 }, { 45,-19274 }, + { 46,-19790 }, { 47,-19790 }, { 48,-19790 }, { 49,-19790 }, { 50,-19790 }, + + { 51,-19790 }, { 52,-19790 }, { 53,-19790 }, { 54,-19790 }, { 55,-19790 }, + { 56,-19790 }, { 57,-19790 }, { 58,-19790 }, { 59,-19790 }, { 60,-19790 }, + { 61,-19790 }, { 62,-19790 }, { 63,-19790 }, { 64,-19790 }, { 65,-19790 }, + { 66,-19790 }, { 67,-19790 }, { 68,-19790 }, { 69,-13719 }, { 70,-19790 }, + { 71,-19790 }, { 72,-19790 }, { 73,-19790 }, { 74,-19790 }, { 75,-19790 }, + { 76,-19790 }, { 77,-19790 }, { 78,-19790 }, { 79,-19790 }, { 80,-19790 }, + { 81,-19790 }, { 82,-19790 }, { 83,-19790 }, { 84,-19790 }, { 85,-19016 }, + { 86,-19790 }, { 87,-19790 }, { 88,-19790 }, { 89,-19790 }, { 90,-19790 }, + { 91,-19790 }, { 92,-19790 }, { 93,-19790 }, { 94,-19790 }, { 95,-19790 }, + { 96,-19790 }, { 97,-19790 }, { 98,-19790 }, { 99,-19790 }, { 100,-19790 }, + + { 101,-13719 }, { 102,-19790 }, { 103,-19790 }, { 104,-19790 }, { 105,-19790 }, + { 106,-19790 }, { 107,-19790 }, { 108,-19790 }, { 109,-19790 }, { 110,-19790 }, + { 111,-19790 }, { 112,-19790 }, { 113,-19790 }, { 114,-19790 }, { 115,-19790 }, + { 116,-19790 }, { 117,-19016 }, { 118,-19790 }, { 119,-19790 }, { 120,-19790 }, + { 121,-19790 }, { 122,-19790 }, { 123,-19790 }, { 124,-19790 }, { 125,-19790 }, + { 126,-19790 }, { 127,-19790 }, { 128,-19790 }, { 129,-19790 }, { 130,-19790 }, + { 131,-19790 }, { 132,-19790 }, { 133,-19790 }, { 134,-19790 }, { 135,-19790 }, + { 136,-19790 }, { 137,-19790 }, { 138,-19790 }, { 139,-19790 }, { 140,-19790 }, + { 141,-19790 }, { 142,-19790 }, { 143,-19790 }, { 144,-19790 }, { 145,-19790 }, + { 146,-19790 }, { 147,-19790 }, { 148,-19790 }, { 149,-19790 }, { 150,-19790 }, + + { 151,-19790 }, { 152,-19790 }, { 153,-19790 }, { 154,-19790 }, { 155,-19790 }, + { 156,-19790 }, { 157,-19790 }, { 158,-19790 }, { 159,-19790 }, { 160,-19790 }, + { 161,-19790 }, { 162,-19790 }, { 163,-19790 }, { 164,-19790 }, { 165,-19790 }, + { 166,-19790 }, { 167,-19790 }, { 168,-19790 }, { 169,-19790 }, { 170,-19790 }, + { 171,-19790 }, { 172,-19790 }, { 173,-19790 }, { 174,-19790 }, { 175,-19790 }, + { 176,-19790 }, { 177,-19790 }, { 178,-19790 }, { 179,-19790 }, { 180,-19790 }, + { 181,-19790 }, { 182,-19790 }, { 183,-19790 }, { 184,-19790 }, { 185,-19790 }, + { 186,-19790 }, { 187,-19790 }, { 188,-19790 }, { 189,-19790 }, { 190,-19790 }, + { 191,-19790 }, { 192,-19790 }, { 193,-19790 }, { 194,-19790 }, { 195,-19790 }, + { 196,-19790 }, { 197,-19790 }, { 198,-19790 }, { 199,-19790 }, { 200,-19790 }, + + { 201,-19790 }, { 202,-19790 }, { 203,-19790 }, { 204,-19790 }, { 205,-19790 }, + { 206,-19790 }, { 207,-19790 }, { 208,-19790 }, { 209,-19790 }, { 210,-19790 }, + { 211,-19790 }, { 212,-19790 }, { 213,-19790 }, { 214,-19790 }, { 215,-19790 }, + { 216,-19790 }, { 217,-19790 }, { 218,-19790 }, { 219,-19790 }, { 220,-19790 }, + { 221,-19790 }, { 222,-19790 }, { 223,-19790 }, { 224,-19790 }, { 225,-19790 }, + { 226,-19790 }, { 227,-19790 }, { 228,-19790 }, { 229,-19790 }, { 230,-19790 }, + { 231,-19790 }, { 232,-19790 }, { 233,-19790 }, { 234,-19790 }, { 235,-19790 }, + { 236,-19790 }, { 237,-19790 }, { 238,-19790 }, { 239,-19790 }, { 240,-19790 }, + { 241,-19790 }, { 242,-19790 }, { 243,-19790 }, { 244,-19790 }, { 245,-19790 }, + { 246,-19790 }, { 247,-19790 }, { 248,-19790 }, { 249,-19790 }, { 250,-19790 }, + + { 251,-19790 }, { 252,-19790 }, { 253,-19790 }, { 254,-19790 }, { 255,-19790 }, + { 256,-19790 }, { 0, 48 }, { 0,23373 }, { 1,5611 }, { 2,5611 }, + { 3,5611 }, { 4,5611 }, { 5,5611 }, { 6,5611 }, { 7,5611 }, + { 8,5611 }, { 9,5869 }, { 10,-5001 }, { 11,5611 }, { 12,5869 }, + { 13,-5001 }, { 14,5611 }, { 15,5611 }, { 16,5611 }, { 17,5611 }, + { 18,5611 }, { 19,5611 }, { 20,5611 }, { 21,5611 }, { 22,5611 }, + { 23,5611 }, { 24,5611 }, { 25,5611 }, { 26,5611 }, { 27,5611 }, + { 28,5611 }, { 29,5611 }, { 30,5611 }, { 31,5611 }, { 32,5869 }, + { 33,5611 }, { 34,5611 }, { 35,5611 }, { 36,5611 }, { 37,5611 }, + { 38,5611 }, { 39,6127 }, { 40,5611 }, { 41,5611 }, { 42,5611 }, + + { 43,5611 }, { 44,5611 }, { 45,6385 }, { 46,5611 }, { 47,5611 }, + { 48,5611 }, { 49,5611 }, { 50,5611 }, { 51,5611 }, { 52,5611 }, + { 53,5611 }, { 54,5611 }, { 55,5611 }, { 56,5611 }, { 57,5611 }, + { 58,5611 }, { 59,5611 }, { 60,5611 }, { 61,5611 }, { 62,5611 }, + { 63,5611 }, { 64,5611 }, { 65,5611 }, { 66,5611 }, { 67,5611 }, + { 68,5611 }, { 69,5611 }, { 70,5611 }, { 71,5611 }, { 72,5611 }, + { 73,5611 }, { 74,5611 }, { 75,5611 }, { 76,5611 }, { 77,5611 }, + { 78,5611 }, { 79,5611 }, { 80,5611 }, { 81,5611 }, { 82,5611 }, + { 83,5611 }, { 84,5611 }, { 85,6643 }, { 86,5611 }, { 87,5611 }, + { 88,5611 }, { 89,5611 }, { 90,5611 }, { 91,5611 }, { 92,5611 }, + + { 93,5611 }, { 94,5611 }, { 95,5611 }, { 96,5611 }, { 97,5611 }, + { 98,5611 }, { 99,5611 }, { 100,5611 }, { 101,5611 }, { 102,5611 }, + { 103,5611 }, { 104,5611 }, { 105,5611 }, { 106,5611 }, { 107,5611 }, + { 108,5611 }, { 109,5611 }, { 110,5611 }, { 111,5611 }, { 112,5611 }, + { 113,5611 }, { 114,5611 }, { 115,5611 }, { 116,5611 }, { 117,6643 }, + { 118,5611 }, { 119,5611 }, { 120,5611 }, { 121,5611 }, { 122,5611 }, + { 123,5611 }, { 124,5611 }, { 125,5611 }, { 126,5611 }, { 127,5611 }, + { 128,5611 }, { 129,5611 }, { 130,5611 }, { 131,5611 }, { 132,5611 }, + { 133,5611 }, { 134,5611 }, { 135,5611 }, { 136,5611 }, { 137,5611 }, + { 138,5611 }, { 139,5611 }, { 140,5611 }, { 141,5611 }, { 142,5611 }, + + { 143,5611 }, { 144,5611 }, { 145,5611 }, { 146,5611 }, { 147,5611 }, + { 148,5611 }, { 149,5611 }, { 150,5611 }, { 151,5611 }, { 152,5611 }, + { 153,5611 }, { 154,5611 }, { 155,5611 }, { 156,5611 }, { 157,5611 }, + { 158,5611 }, { 159,5611 }, { 160,5611 }, { 161,5611 }, { 162,5611 }, + { 163,5611 }, { 164,5611 }, { 165,5611 }, { 166,5611 }, { 167,5611 }, + { 168,5611 }, { 169,5611 }, { 170,5611 }, { 171,5611 }, { 172,5611 }, + { 173,5611 }, { 174,5611 }, { 175,5611 }, { 176,5611 }, { 177,5611 }, + { 178,5611 }, { 179,5611 }, { 180,5611 }, { 181,5611 }, { 182,5611 }, + { 183,5611 }, { 184,5611 }, { 185,5611 }, { 186,5611 }, { 187,5611 }, + { 188,5611 }, { 189,5611 }, { 190,5611 }, { 191,5611 }, { 192,5611 }, + + { 193,5611 }, { 194,5611 }, { 195,5611 }, { 196,5611 }, { 197,5611 }, + { 198,5611 }, { 199,5611 }, { 200,5611 }, { 201,5611 }, { 202,5611 }, + { 203,5611 }, { 204,5611 }, { 205,5611 }, { 206,5611 }, { 207,5611 }, + { 208,5611 }, { 209,5611 }, { 210,5611 }, { 211,5611 }, { 212,5611 }, + { 213,5611 }, { 214,5611 }, { 215,5611 }, { 216,5611 }, { 217,5611 }, + { 218,5611 }, { 219,5611 }, { 220,5611 }, { 221,5611 }, { 222,5611 }, + { 223,5611 }, { 224,5611 }, { 225,5611 }, { 226,5611 }, { 227,5611 }, + { 228,5611 }, { 229,5611 }, { 230,5611 }, { 231,5611 }, { 232,5611 }, + { 233,5611 }, { 234,5611 }, { 235,5611 }, { 236,5611 }, { 237,5611 }, + { 238,5611 }, { 239,5611 }, { 240,5611 }, { 241,5611 }, { 242,5611 }, + + { 243,5611 }, { 244,5611 }, { 245,5611 }, { 246,5611 }, { 247,5611 }, + { 248,5611 }, { 249,5611 }, { 250,5611 }, { 251,5611 }, { 252,5611 }, + { 253,5611 }, { 254,5611 }, { 255,5611 }, { 256,5611 }, { 0, 48 }, + { 0,23115 }, { 1,-4624 }, { 2,-4624 }, { 3,-4624 }, { 4,-4624 }, + { 5,-4624 }, { 6,-4624 }, { 7,-4624 }, { 8,-4624 }, { 9,-4366 }, + { 10,-8037 }, { 11,-4624 }, { 12,-4366 }, { 13,-8037 }, { 14,-4624 }, + { 15,-4624 }, { 16,-4624 }, { 17,-4624 }, { 18,-4624 }, { 19,-4624 }, + { 20,-4624 }, { 21,-4624 }, { 22,-4624 }, { 23,-4624 }, { 24,-4624 }, + { 25,-4624 }, { 26,-4624 }, { 27,-4624 }, { 28,-4624 }, { 29,-4624 }, + { 30,-4624 }, { 31,-4624 }, { 32,-4366 }, { 33,-4624 }, { 34,-4624 }, + + { 35,-4624 }, { 36,-4624 }, { 37,-4624 }, { 38,-4624 }, { 39,6643 }, + { 40,-4624 }, { 41,-4624 }, { 42,-4624 }, { 43,-4624 }, { 44,-4624 }, + { 45,-3850 }, { 46,-4624 }, { 47,-4624 }, { 48,-4624 }, { 49,-4624 }, + { 50,-4624 }, { 51,-4624 }, { 52,-4624 }, { 53,-4624 }, { 54,-4624 }, + { 55,-4624 }, { 56,-4624 }, { 57,-4624 }, { 58,-4624 }, { 59,-4624 }, + { 60,-4624 }, { 61,-4624 }, { 62,-4624 }, { 63,-4624 }, { 64,-4624 }, + { 65,-4624 }, { 66,-4624 }, { 67,-4624 }, { 68,-4624 }, { 69,-4624 }, + { 70,-4624 }, { 71,-4624 }, { 72,-4624 }, { 73,-4624 }, { 74,-4624 }, + { 75,-4624 }, { 76,-4624 }, { 77,-4624 }, { 78,-4624 }, { 79,-4624 }, + { 80,-4624 }, { 81,-4624 }, { 82,-4624 }, { 83,-4624 }, { 84,-4624 }, + + { 85,-4624 }, { 86,-4624 }, { 87,-4624 }, { 88,-4624 }, { 89,-4624 }, + { 90,-4624 }, { 91,-4624 }, { 92,-4624 }, { 93,-4624 }, { 94,-4624 }, + { 95,-4624 }, { 96,-4624 }, { 97,-4624 }, { 98,-4624 }, { 99,-4624 }, + { 100,-4624 }, { 101,-4624 }, { 102,-4624 }, { 103,-4624 }, { 104,-4624 }, + { 105,-4624 }, { 106,-4624 }, { 107,-4624 }, { 108,-4624 }, { 109,-4624 }, + { 110,-4624 }, { 111,-4624 }, { 112,-4624 }, { 113,-4624 }, { 114,-4624 }, + { 115,-4624 }, { 116,-4624 }, { 117,-4624 }, { 118,-4624 }, { 119,-4624 }, + { 120,-4624 }, { 121,-4624 }, { 122,-4624 }, { 123,-4624 }, { 124,-4624 }, + { 125,-4624 }, { 126,-4624 }, { 127,-4624 }, { 128,-4624 }, { 129,-4624 }, + { 130,-4624 }, { 131,-4624 }, { 132,-4624 }, { 133,-4624 }, { 134,-4624 }, + + { 135,-4624 }, { 136,-4624 }, { 137,-4624 }, { 138,-4624 }, { 139,-4624 }, + { 140,-4624 }, { 141,-4624 }, { 142,-4624 }, { 143,-4624 }, { 144,-4624 }, + { 145,-4624 }, { 146,-4624 }, { 147,-4624 }, { 148,-4624 }, { 149,-4624 }, + { 150,-4624 }, { 151,-4624 }, { 152,-4624 }, { 153,-4624 }, { 154,-4624 }, + { 155,-4624 }, { 156,-4624 }, { 157,-4624 }, { 158,-4624 }, { 159,-4624 }, + { 160,-4624 }, { 161,-4624 }, { 162,-4624 }, { 163,-4624 }, { 164,-4624 }, + { 165,-4624 }, { 166,-4624 }, { 167,-4624 }, { 168,-4624 }, { 169,-4624 }, + { 170,-4624 }, { 171,-4624 }, { 172,-4624 }, { 173,-4624 }, { 174,-4624 }, + { 175,-4624 }, { 176,-4624 }, { 177,-4624 }, { 178,-4624 }, { 179,-4624 }, + { 180,-4624 }, { 181,-4624 }, { 182,-4624 }, { 183,-4624 }, { 184,-4624 }, + + { 185,-4624 }, { 186,-4624 }, { 187,-4624 }, { 188,-4624 }, { 189,-4624 }, + { 190,-4624 }, { 191,-4624 }, { 192,-4624 }, { 193,-4624 }, { 194,-4624 }, + { 195,-4624 }, { 196,-4624 }, { 197,-4624 }, { 198,-4624 }, { 199,-4624 }, + { 200,-4624 }, { 201,-4624 }, { 202,-4624 }, { 203,-4624 }, { 204,-4624 }, + { 205,-4624 }, { 206,-4624 }, { 207,-4624 }, { 208,-4624 }, { 209,-4624 }, + { 210,-4624 }, { 211,-4624 }, { 212,-4624 }, { 213,-4624 }, { 214,-4624 }, + { 215,-4624 }, { 216,-4624 }, { 217,-4624 }, { 218,-4624 }, { 219,-4624 }, + { 220,-4624 }, { 221,-4624 }, { 222,-4624 }, { 223,-4624 }, { 224,-4624 }, + { 225,-4624 }, { 226,-4624 }, { 227,-4624 }, { 228,-4624 }, { 229,-4624 }, + { 230,-4624 }, { 231,-4624 }, { 232,-4624 }, { 233,-4624 }, { 234,-4624 }, + + { 235,-4624 }, { 236,-4624 }, { 237,-4624 }, { 238,-4624 }, { 239,-4624 }, + { 240,-4624 }, { 241,-4624 }, { 242,-4624 }, { 243,-4624 }, { 244,-4624 }, + { 245,-4624 }, { 246,-4624 }, { 247,-4624 }, { 248,-4624 }, { 249,-4624 }, + { 250,-4624 }, { 251,-4624 }, { 252,-4624 }, { 253,-4624 }, { 254,-4624 }, + { 255,-4624 }, { 256,-4624 }, { 0, 48 }, { 0,22857 }, { 1,-4882 }, + { 2,-4882 }, { 3,-4882 }, { 4,-4882 }, { 5,-4882 }, { 6,-4882 }, + { 7,-4882 }, { 8,-4882 }, { 9,-4624 }, { 10,-8295 }, { 11,-4882 }, + { 12,-4624 }, { 13,-8295 }, { 14,-4882 }, { 15,-4882 }, { 16,-4882 }, + { 17,-4882 }, { 18,-4882 }, { 19,-4882 }, { 20,-4882 }, { 21,-4882 }, + { 22,-4882 }, { 23,-4882 }, { 24,-4882 }, { 25,-4882 }, { 26,-4882 }, + + { 27,-4882 }, { 28,-4882 }, { 29,-4882 }, { 30,-4882 }, { 31,-4882 }, + { 32,-4624 }, { 33,-4882 }, { 34,-4882 }, { 35,-4882 }, { 36,-4882 }, + { 37,-4882 }, { 38,-4882 }, { 39,6385 }, { 40,-4882 }, { 41,-4882 }, + { 42,-4882 }, { 43,-4882 }, { 44,-4882 }, { 45,-4108 }, { 46,-4882 }, + { 47,-4882 }, { 48,-4882 }, { 49,-4882 }, { 50,-4882 }, { 51,-4882 }, + { 52,-4882 }, { 53,-4882 }, { 54,-4882 }, { 55,-4882 }, { 56,-4882 }, + { 57,-4882 }, { 58,-4882 }, { 59,-4882 }, { 60,-4882 }, { 61,-4882 }, + { 62,-4882 }, { 63,-4882 }, { 64,-4882 }, { 65,-4882 }, { 66,-4882 }, + { 67,-4882 }, { 68,-4882 }, { 69,-4882 }, { 70,-4882 }, { 71,-4882 }, + { 72,-4882 }, { 73,-4882 }, { 74,-4882 }, { 75,-4882 }, { 76,-4882 }, + + { 77,-4882 }, { 78,-4882 }, { 79,-4882 }, { 80,-4882 }, { 81,-4882 }, + { 82,-4882 }, { 83,-4882 }, { 84,-4882 }, { 85,-4882 }, { 86,-4882 }, + { 87,-4882 }, { 88,-4882 }, { 89,-4882 }, { 90,-4882 }, { 91,-4882 }, + { 92,-4882 }, { 93,-4882 }, { 94,-4882 }, { 95,-4882 }, { 96,-4882 }, + { 97,-4882 }, { 98,-4882 }, { 99,-4882 }, { 100,-4882 }, { 101,-4882 }, + { 102,-4882 }, { 103,-4882 }, { 104,-4882 }, { 105,-4882 }, { 106,-4882 }, + { 107,-4882 }, { 108,-4882 }, { 109,-4882 }, { 110,-4882 }, { 111,-4882 }, + { 112,-4882 }, { 113,-4882 }, { 114,-4882 }, { 115,-4882 }, { 116,-4882 }, + { 117,-4882 }, { 118,-4882 }, { 119,-4882 }, { 120,-4882 }, { 121,-4882 }, + { 122,-4882 }, { 123,-4882 }, { 124,-4882 }, { 125,-4882 }, { 126,-4882 }, + + { 127,-4882 }, { 128,-4882 }, { 129,-4882 }, { 130,-4882 }, { 131,-4882 }, + { 132,-4882 }, { 133,-4882 }, { 134,-4882 }, { 135,-4882 }, { 136,-4882 }, + { 137,-4882 }, { 138,-4882 }, { 139,-4882 }, { 140,-4882 }, { 141,-4882 }, + { 142,-4882 }, { 143,-4882 }, { 144,-4882 }, { 145,-4882 }, { 146,-4882 }, + { 147,-4882 }, { 148,-4882 }, { 149,-4882 }, { 150,-4882 }, { 151,-4882 }, + { 152,-4882 }, { 153,-4882 }, { 154,-4882 }, { 155,-4882 }, { 156,-4882 }, + { 157,-4882 }, { 158,-4882 }, { 159,-4882 }, { 160,-4882 }, { 161,-4882 }, + { 162,-4882 }, { 163,-4882 }, { 164,-4882 }, { 165,-4882 }, { 166,-4882 }, + { 167,-4882 }, { 168,-4882 }, { 169,-4882 }, { 170,-4882 }, { 171,-4882 }, + { 172,-4882 }, { 173,-4882 }, { 174,-4882 }, { 175,-4882 }, { 176,-4882 }, + + { 177,-4882 }, { 178,-4882 }, { 179,-4882 }, { 180,-4882 }, { 181,-4882 }, + { 182,-4882 }, { 183,-4882 }, { 184,-4882 }, { 185,-4882 }, { 186,-4882 }, + { 187,-4882 }, { 188,-4882 }, { 189,-4882 }, { 190,-4882 }, { 191,-4882 }, + { 192,-4882 }, { 193,-4882 }, { 194,-4882 }, { 195,-4882 }, { 196,-4882 }, + { 197,-4882 }, { 198,-4882 }, { 199,-4882 }, { 200,-4882 }, { 201,-4882 }, + { 202,-4882 }, { 203,-4882 }, { 204,-4882 }, { 205,-4882 }, { 206,-4882 }, + { 207,-4882 }, { 208,-4882 }, { 209,-4882 }, { 210,-4882 }, { 211,-4882 }, + { 212,-4882 }, { 213,-4882 }, { 214,-4882 }, { 215,-4882 }, { 216,-4882 }, + { 217,-4882 }, { 218,-4882 }, { 219,-4882 }, { 220,-4882 }, { 221,-4882 }, + { 222,-4882 }, { 223,-4882 }, { 224,-4882 }, { 225,-4882 }, { 226,-4882 }, + + { 227,-4882 }, { 228,-4882 }, { 229,-4882 }, { 230,-4882 }, { 231,-4882 }, + { 232,-4882 }, { 233,-4882 }, { 234,-4882 }, { 235,-4882 }, { 236,-4882 }, + { 237,-4882 }, { 238,-4882 }, { 239,-4882 }, { 240,-4882 }, { 241,-4882 }, + { 242,-4882 }, { 243,-4882 }, { 244,-4882 }, { 245,-4882 }, { 246,-4882 }, + { 247,-4882 }, { 248,-4882 }, { 249,-4882 }, { 250,-4882 }, { 251,-4882 }, + { 252,-4882 }, { 253,-4882 }, { 254,-4882 }, { 255,-4882 }, { 256,-4882 }, + { 0, 48 }, { 0,22599 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 9,-8553 }, { 10,-8553 }, { 0, 0 }, { 12,-8553 }, { 13,-8553 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 32,-8553 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 39,6385 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 45,-30671 }, { 0, 48 }, { 0,22552 }, { 1,-5187 }, + { 2,-5187 }, { 3,-5187 }, { 4,-5187 }, { 5,-5187 }, { 6,-5187 }, + { 7,-5187 }, { 8,-5187 }, { 9,-4929 }, { 10,-8600 }, { 11,-5187 }, + { 12,-4929 }, { 13,-8600 }, { 14,-5187 }, { 15,-5187 }, { 16,-5187 }, + { 17,-5187 }, { 18,-5187 }, { 19,-5187 }, { 20,-5187 }, { 21,-5187 }, + + { 22,-5187 }, { 23,-5187 }, { 24,-5187 }, { 25,-5187 }, { 26,-5187 }, + { 27,-5187 }, { 28,-5187 }, { 29,-5187 }, { 30,-5187 }, { 31,-5187 }, + { 32,-4929 }, { 33,-5187 }, { 34,-5187 }, { 35,-5187 }, { 36,-5187 }, + { 37,-5187 }, { 38,-5187 }, { 39,6080 }, { 40,-5187 }, { 41,-5187 }, + { 42,-5187 }, { 43,-5187 }, { 44,-5187 }, { 45, 258 }, { 46,-5187 }, + { 47,-5187 }, { 48,-5187 }, { 49,-5187 }, { 50,-5187 }, { 51,-5187 }, + { 52,-5187 }, { 53,-5187 }, { 54,-5187 }, { 55,-5187 }, { 56,-5187 }, + { 57,-5187 }, { 58,-5187 }, { 59,-5187 }, { 60,-5187 }, { 61,-5187 }, + { 62,-5187 }, { 63,-5187 }, { 64,-5187 }, { 65,-5187 }, { 66,-5187 }, + { 67,-5187 }, { 68,-5187 }, { 69,-5187 }, { 70,-5187 }, { 71,-5187 }, + + { 72,-5187 }, { 73,-5187 }, { 74,-5187 }, { 75,-5187 }, { 76,-5187 }, + { 77,-5187 }, { 78,-5187 }, { 79,-5187 }, { 80,-5187 }, { 81,-5187 }, + { 82,-5187 }, { 83,-5187 }, { 84,-5187 }, { 85,-5187 }, { 86,-5187 }, + { 87,-5187 }, { 88,-5187 }, { 89,-5187 }, { 90,-5187 }, { 91,-5187 }, + { 92,-5187 }, { 93,-5187 }, { 94,-5187 }, { 95,-5187 }, { 96,-5187 }, + { 97,-5187 }, { 98,-5187 }, { 99,-5187 }, { 100,-5187 }, { 101,-5187 }, + { 102,-5187 }, { 103,-5187 }, { 104,-5187 }, { 105,-5187 }, { 106,-5187 }, + { 107,-5187 }, { 108,-5187 }, { 109,-5187 }, { 110,-5187 }, { 111,-5187 }, + { 112,-5187 }, { 113,-5187 }, { 114,-5187 }, { 115,-5187 }, { 116,-5187 }, + { 117,-5187 }, { 118,-5187 }, { 119,-5187 }, { 120,-5187 }, { 121,-5187 }, + + { 122,-5187 }, { 123,-5187 }, { 124,-5187 }, { 125,-5187 }, { 126,-5187 }, + { 127,-5187 }, { 128,-5187 }, { 129,-5187 }, { 130,-5187 }, { 131,-5187 }, + { 132,-5187 }, { 133,-5187 }, { 134,-5187 }, { 135,-5187 }, { 136,-5187 }, + { 137,-5187 }, { 138,-5187 }, { 139,-5187 }, { 140,-5187 }, { 141,-5187 }, + { 142,-5187 }, { 143,-5187 }, { 144,-5187 }, { 145,-5187 }, { 146,-5187 }, + { 147,-5187 }, { 148,-5187 }, { 149,-5187 }, { 150,-5187 }, { 151,-5187 }, + { 152,-5187 }, { 153,-5187 }, { 154,-5187 }, { 155,-5187 }, { 156,-5187 }, + { 157,-5187 }, { 158,-5187 }, { 159,-5187 }, { 160,-5187 }, { 161,-5187 }, + { 162,-5187 }, { 163,-5187 }, { 164,-5187 }, { 165,-5187 }, { 166,-5187 }, + { 167,-5187 }, { 168,-5187 }, { 169,-5187 }, { 170,-5187 }, { 171,-5187 }, + + { 172,-5187 }, { 173,-5187 }, { 174,-5187 }, { 175,-5187 }, { 176,-5187 }, + { 177,-5187 }, { 178,-5187 }, { 179,-5187 }, { 180,-5187 }, { 181,-5187 }, + { 182,-5187 }, { 183,-5187 }, { 184,-5187 }, { 185,-5187 }, { 186,-5187 }, + { 187,-5187 }, { 188,-5187 }, { 189,-5187 }, { 190,-5187 }, { 191,-5187 }, + { 192,-5187 }, { 193,-5187 }, { 194,-5187 }, { 195,-5187 }, { 196,-5187 }, + { 197,-5187 }, { 198,-5187 }, { 199,-5187 }, { 200,-5187 }, { 201,-5187 }, + { 202,-5187 }, { 203,-5187 }, { 204,-5187 }, { 205,-5187 }, { 206,-5187 }, + { 207,-5187 }, { 208,-5187 }, { 209,-5187 }, { 210,-5187 }, { 211,-5187 }, + { 212,-5187 }, { 213,-5187 }, { 214,-5187 }, { 215,-5187 }, { 216,-5187 }, + { 217,-5187 }, { 218,-5187 }, { 219,-5187 }, { 220,-5187 }, { 221,-5187 }, + + { 222,-5187 }, { 223,-5187 }, { 224,-5187 }, { 225,-5187 }, { 226,-5187 }, + { 227,-5187 }, { 228,-5187 }, { 229,-5187 }, { 230,-5187 }, { 231,-5187 }, + { 232,-5187 }, { 233,-5187 }, { 234,-5187 }, { 235,-5187 }, { 236,-5187 }, + { 237,-5187 }, { 238,-5187 }, { 239,-5187 }, { 240,-5187 }, { 241,-5187 }, + { 242,-5187 }, { 243,-5187 }, { 244,-5187 }, { 245,-5187 }, { 246,-5187 }, + { 247,-5187 }, { 248,-5187 }, { 249,-5187 }, { 250,-5187 }, { 251,-5187 }, + { 252,-5187 }, { 253,-5187 }, { 254,-5187 }, { 255,-5187 }, { 256,-5187 }, + { 0, 48 }, { 0,22294 }, { 1,-5445 }, { 2,-5445 }, { 3,-5445 }, + { 4,-5445 }, { 5,-5445 }, { 6,-5445 }, { 7,-5445 }, { 8,-5445 }, + { 9,-5187 }, { 10,-8858 }, { 11,-5445 }, { 12,-5187 }, { 13,-8858 }, + + { 14,-5445 }, { 15,-5445 }, { 16,-5445 }, { 17,-5445 }, { 18,-5445 }, + { 19,-5445 }, { 20,-5445 }, { 21,-5445 }, { 22,-5445 }, { 23,-5445 }, + { 24,-5445 }, { 25,-5445 }, { 26,-5445 }, { 27,-5445 }, { 28,-5445 }, + { 29,-5445 }, { 30,-5445 }, { 31,-5445 }, { 32,-5187 }, { 33,-5445 }, + { 34,-5445 }, { 35,-5445 }, { 36,-5445 }, { 37,-5445 }, { 38,-5445 }, + { 39,-4929 }, { 40,-5445 }, { 41,-5445 }, { 42,-5445 }, { 43,-5445 }, + { 44,-5445 }, { 45, 0 }, { 46,-5445 }, { 47,-5445 }, { 48,-5445 }, + { 49,-5445 }, { 50,-5445 }, { 51,-5445 }, { 52,-5445 }, { 53,-5445 }, + { 54,-5445 }, { 55,-5445 }, { 56,-5445 }, { 57,-5445 }, { 58,-5445 }, + { 59,-5445 }, { 60,-5445 }, { 61,-5445 }, { 62,-5445 }, { 63,-5445 }, + + { 64,-5445 }, { 65,-5445 }, { 66,-5445 }, { 67,-5445 }, { 68,-5445 }, + { 69,-5445 }, { 70,-5445 }, { 71,-5445 }, { 72,-5445 }, { 73,-5445 }, + { 74,-5445 }, { 75,-5445 }, { 76,-5445 }, { 77,-5445 }, { 78,-5445 }, + { 79,-5445 }, { 80,-5445 }, { 81,-5445 }, { 82,-5445 }, { 83,-5445 }, + { 84,-5445 }, { 85,-5445 }, { 86,-5445 }, { 87,-5445 }, { 88,-5445 }, + { 89,-5445 }, { 90,-5445 }, { 91,-5445 }, { 92,-5445 }, { 93,-5445 }, + { 94,-5445 }, { 95,-5445 }, { 96,-5445 }, { 97,-5445 }, { 98,-5445 }, + { 99,-5445 }, { 100,-5445 }, { 101,-5445 }, { 102,-5445 }, { 103,-5445 }, + { 104,-5445 }, { 105,-5445 }, { 106,-5445 }, { 107,-5445 }, { 108,-5445 }, + { 109,-5445 }, { 110,-5445 }, { 111,-5445 }, { 112,-5445 }, { 113,-5445 }, + + { 114,-5445 }, { 115,-5445 }, { 116,-5445 }, { 117,-5445 }, { 118,-5445 }, + { 119,-5445 }, { 120,-5445 }, { 121,-5445 }, { 122,-5445 }, { 123,-5445 }, + { 124,-5445 }, { 125,-5445 }, { 126,-5445 }, { 127,-5445 }, { 128,-5445 }, + { 129,-5445 }, { 130,-5445 }, { 131,-5445 }, { 132,-5445 }, { 133,-5445 }, + { 134,-5445 }, { 135,-5445 }, { 136,-5445 }, { 137,-5445 }, { 138,-5445 }, + { 139,-5445 }, { 140,-5445 }, { 141,-5445 }, { 142,-5445 }, { 143,-5445 }, + { 144,-5445 }, { 145,-5445 }, { 146,-5445 }, { 147,-5445 }, { 148,-5445 }, + { 149,-5445 }, { 150,-5445 }, { 151,-5445 }, { 152,-5445 }, { 153,-5445 }, + { 154,-5445 }, { 155,-5445 }, { 156,-5445 }, { 157,-5445 }, { 158,-5445 }, + { 159,-5445 }, { 160,-5445 }, { 161,-5445 }, { 162,-5445 }, { 163,-5445 }, + + { 164,-5445 }, { 165,-5445 }, { 166,-5445 }, { 167,-5445 }, { 168,-5445 }, + { 169,-5445 }, { 170,-5445 }, { 171,-5445 }, { 172,-5445 }, { 173,-5445 }, + { 174,-5445 }, { 175,-5445 }, { 176,-5445 }, { 177,-5445 }, { 178,-5445 }, + { 179,-5445 }, { 180,-5445 }, { 181,-5445 }, { 182,-5445 }, { 183,-5445 }, + { 184,-5445 }, { 185,-5445 }, { 186,-5445 }, { 187,-5445 }, { 188,-5445 }, + { 189,-5445 }, { 190,-5445 }, { 191,-5445 }, { 192,-5445 }, { 193,-5445 }, + { 194,-5445 }, { 195,-5445 }, { 196,-5445 }, { 197,-5445 }, { 198,-5445 }, + { 199,-5445 }, { 200,-5445 }, { 201,-5445 }, { 202,-5445 }, { 203,-5445 }, + { 204,-5445 }, { 205,-5445 }, { 206,-5445 }, { 207,-5445 }, { 208,-5445 }, + { 209,-5445 }, { 210,-5445 }, { 211,-5445 }, { 212,-5445 }, { 213,-5445 }, + + { 214,-5445 }, { 215,-5445 }, { 216,-5445 }, { 217,-5445 }, { 218,-5445 }, + { 219,-5445 }, { 220,-5445 }, { 221,-5445 }, { 222,-5445 }, { 223,-5445 }, + { 224,-5445 }, { 225,-5445 }, { 226,-5445 }, { 227,-5445 }, { 228,-5445 }, + { 229,-5445 }, { 230,-5445 }, { 231,-5445 }, { 232,-5445 }, { 233,-5445 }, + { 234,-5445 }, { 235,-5445 }, { 236,-5445 }, { 237,-5445 }, { 238,-5445 }, + { 239,-5445 }, { 240,-5445 }, { 241,-5445 }, { 242,-5445 }, { 243,-5445 }, + { 244,-5445 }, { 245,-5445 }, { 246,-5445 }, { 247,-5445 }, { 248,-5445 }, + { 249,-5445 }, { 250,-5445 }, { 251,-5445 }, { 252,-5445 }, { 253,-5445 }, + { 254,-5445 }, { 255,-5445 }, { 256,-5445 }, { 0, 24 }, { 0,22036 }, + { 1,-15056 }, { 2,-15056 }, { 3,-15056 }, { 4,-15056 }, { 5,-15056 }, + + { 6,-15056 }, { 7,-15056 }, { 8,-15056 }, { 9, 0 }, { 10, 258 }, + { 11,-15056 }, { 12, 0 }, { 13, 258 }, { 14,-15056 }, { 15,-15056 }, + { 16,-15056 }, { 17,-15056 }, { 18,-15056 }, { 19,-15056 }, { 20,-15056 }, + { 21,-15056 }, { 22,-15056 }, { 23,-15056 }, { 24,-15056 }, { 25,-15056 }, + { 26,-15056 }, { 27,-15056 }, { 28,-15056 }, { 29,-15056 }, { 30,-15056 }, + { 31,-15056 }, { 32, 0 }, { 33,-15056 }, { 34,-15056 }, { 35,-15056 }, + { 36,-15056 }, { 37,-15056 }, { 38,-15056 }, { 39, 377 }, { 40,-15056 }, + { 41,-15056 }, { 42,-15056 }, { 43,-15056 }, { 44,-15056 }, { 45, 635 }, + { 46,-15056 }, { 47,-15056 }, { 48,-15056 }, { 49,-15056 }, { 50,-15056 }, + { 51,-15056 }, { 52,-15056 }, { 53,-15056 }, { 54,-15056 }, { 55,-15056 }, + + { 56,-15056 }, { 57,-15056 }, { 58,-15056 }, { 59,-15056 }, { 60,-15056 }, + { 61,-15056 }, { 62,-15056 }, { 63,-15056 }, { 64,-15056 }, { 65,-15056 }, + { 66,-15056 }, { 67,-15056 }, { 68,-15056 }, { 69,-15056 }, { 70,-15056 }, + { 71,-15056 }, { 72,-15056 }, { 73,-15056 }, { 74,-15056 }, { 75,-15056 }, + { 76,-15056 }, { 77,-15056 }, { 78,-15056 }, { 79,-15056 }, { 80,-15056 }, + { 81,-15056 }, { 82,-15056 }, { 83,-15056 }, { 84,-15056 }, { 85,-14163 }, + { 86,-15056 }, { 87,-15056 }, { 88,-15056 }, { 89,-15056 }, { 90,-15056 }, + { 91,-15056 }, { 92,-15056 }, { 93,-15056 }, { 94,-15056 }, { 95,-15056 }, + { 96,-15056 }, { 97,-15056 }, { 98,-15056 }, { 99,-15056 }, { 100,-15056 }, + { 101,-15056 }, { 102,-15056 }, { 103,-15056 }, { 104,-15056 }, { 105,-15056 }, + + { 106,-15056 }, { 107,-15056 }, { 108,-15056 }, { 109,-15056 }, { 110,-15056 }, + { 111,-15056 }, { 112,-15056 }, { 113,-15056 }, { 114,-15056 }, { 115,-15056 }, + { 116,-15056 }, { 117,-14163 }, { 118,-15056 }, { 119,-15056 }, { 120,-15056 }, + { 121,-15056 }, { 122,-15056 }, { 123,-15056 }, { 124,-15056 }, { 125,-15056 }, + { 126,-15056 }, { 127,-15056 }, { 128,-15056 }, { 129,-15056 }, { 130,-15056 }, + { 131,-15056 }, { 132,-15056 }, { 133,-15056 }, { 134,-15056 }, { 135,-15056 }, + { 136,-15056 }, { 137,-15056 }, { 138,-15056 }, { 139,-15056 }, { 140,-15056 }, + { 141,-15056 }, { 142,-15056 }, { 143,-15056 }, { 144,-15056 }, { 145,-15056 }, + { 146,-15056 }, { 147,-15056 }, { 148,-15056 }, { 149,-15056 }, { 150,-15056 }, + { 151,-15056 }, { 152,-15056 }, { 153,-15056 }, { 154,-15056 }, { 155,-15056 }, + + { 156,-15056 }, { 157,-15056 }, { 158,-15056 }, { 159,-15056 }, { 160,-15056 }, + { 161,-15056 }, { 162,-15056 }, { 163,-15056 }, { 164,-15056 }, { 165,-15056 }, + { 166,-15056 }, { 167,-15056 }, { 168,-15056 }, { 169,-15056 }, { 170,-15056 }, + { 171,-15056 }, { 172,-15056 }, { 173,-15056 }, { 174,-15056 }, { 175,-15056 }, + { 176,-15056 }, { 177,-15056 }, { 178,-15056 }, { 179,-15056 }, { 180,-15056 }, + { 181,-15056 }, { 182,-15056 }, { 183,-15056 }, { 184,-15056 }, { 185,-15056 }, + { 186,-15056 }, { 187,-15056 }, { 188,-15056 }, { 189,-15056 }, { 190,-15056 }, + { 191,-15056 }, { 192,-15056 }, { 193,-15056 }, { 194,-15056 }, { 195,-15056 }, + { 196,-15056 }, { 197,-15056 }, { 198,-15056 }, { 199,-15056 }, { 200,-15056 }, + { 201,-15056 }, { 202,-15056 }, { 203,-15056 }, { 204,-15056 }, { 205,-15056 }, + + { 206,-15056 }, { 207,-15056 }, { 208,-15056 }, { 209,-15056 }, { 210,-15056 }, + { 211,-15056 }, { 212,-15056 }, { 213,-15056 }, { 214,-15056 }, { 215,-15056 }, + { 216,-15056 }, { 217,-15056 }, { 218,-15056 }, { 219,-15056 }, { 220,-15056 }, + { 221,-15056 }, { 222,-15056 }, { 223,-15056 }, { 224,-15056 }, { 225,-15056 }, + { 226,-15056 }, { 227,-15056 }, { 228,-15056 }, { 229,-15056 }, { 230,-15056 }, + { 231,-15056 }, { 232,-15056 }, { 233,-15056 }, { 234,-15056 }, { 235,-15056 }, + { 236,-15056 }, { 237,-15056 }, { 238,-15056 }, { 239,-15056 }, { 240,-15056 }, + { 241,-15056 }, { 242,-15056 }, { 243,-15056 }, { 244,-15056 }, { 245,-15056 }, + { 246,-15056 }, { 247,-15056 }, { 248,-15056 }, { 249,-15056 }, { 250,-15056 }, + { 251,-15056 }, { 252,-15056 }, { 253,-15056 }, { 254,-15056 }, { 255,-15056 }, + + { 256,-15056 }, { 0, 24 }, { 0,21778 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 9, 635 }, { 10, 635 }, { 0, 0 }, { 12, 635 }, + { 13, 635 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 32, 635 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 39, 754 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 45,-31438 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 85,-35822 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 117,-35822 }, + { 0, 24 }, { 0,21659 }, { 1,5703 }, { 2,5703 }, { 3,5703 }, + { 4,5703 }, { 5,5703 }, { 6,5703 }, { 7,5703 }, { 8,5703 }, + { 9,5961 }, { 10,6219 }, { 11,5703 }, { 12,5961 }, { 13,6219 }, + { 14,5703 }, { 15,5703 }, { 16,5703 }, { 17,5703 }, { 18,5703 }, + { 19,5703 }, { 20,5703 }, { 21,5703 }, { 22,5703 }, { 23,5703 }, + { 24,5703 }, { 25,5703 }, { 26,5703 }, { 27,5703 }, { 28,5703 }, + + { 29,5703 }, { 30,5703 }, { 31,5703 }, { 32,5961 }, { 33,5703 }, + { 34,5703 }, { 35,5703 }, { 36,5703 }, { 37,5703 }, { 38,5703 }, + { 39,-15433 }, { 40,5703 }, { 41,5703 }, { 42,5703 }, { 43,5703 }, + { 44,5703 }, { 45,6338 }, { 46,5703 }, { 47,5703 }, { 48,5703 }, + { 49,5703 }, { 50,5703 }, { 51,5703 }, { 52,5703 }, { 53,5703 }, + { 54,5703 }, { 55,5703 }, { 56,5703 }, { 57,5703 }, { 58,5703 }, + { 59,5703 }, { 60,5703 }, { 61,5703 }, { 62,5703 }, { 63,5703 }, + { 64,5703 }, { 65,5703 }, { 66,5703 }, { 67,5703 }, { 68,5703 }, + { 69,5703 }, { 70,5703 }, { 71,5703 }, { 72,5703 }, { 73,5703 }, + { 74,5703 }, { 75,5703 }, { 76,5703 }, { 77,5703 }, { 78,5703 }, + + { 79,5703 }, { 80,5703 }, { 81,5703 }, { 82,5703 }, { 83,5703 }, + { 84,5703 }, { 85,6596 }, { 86,5703 }, { 87,5703 }, { 88,5703 }, + { 89,5703 }, { 90,5703 }, { 91,5703 }, { 92,5703 }, { 93,5703 }, + { 94,5703 }, { 95,5703 }, { 96,5703 }, { 97,5703 }, { 98,5703 }, + { 99,5703 }, { 100,5703 }, { 101,5703 }, { 102,5703 }, { 103,5703 }, + { 104,5703 }, { 105,5703 }, { 106,5703 }, { 107,5703 }, { 108,5703 }, + { 109,5703 }, { 110,5703 }, { 111,5703 }, { 112,5703 }, { 113,5703 }, + { 114,5703 }, { 115,5703 }, { 116,5703 }, { 117,6596 }, { 118,5703 }, + { 119,5703 }, { 120,5703 }, { 121,5703 }, { 122,5703 }, { 123,5703 }, + { 124,5703 }, { 125,5703 }, { 126,5703 }, { 127,5703 }, { 128,5703 }, + + { 129,5703 }, { 130,5703 }, { 131,5703 }, { 132,5703 }, { 133,5703 }, + { 134,5703 }, { 135,5703 }, { 136,5703 }, { 137,5703 }, { 138,5703 }, + { 139,5703 }, { 140,5703 }, { 141,5703 }, { 142,5703 }, { 143,5703 }, + { 144,5703 }, { 145,5703 }, { 146,5703 }, { 147,5703 }, { 148,5703 }, + { 149,5703 }, { 150,5703 }, { 151,5703 }, { 152,5703 }, { 153,5703 }, + { 154,5703 }, { 155,5703 }, { 156,5703 }, { 157,5703 }, { 158,5703 }, + { 159,5703 }, { 160,5703 }, { 161,5703 }, { 162,5703 }, { 163,5703 }, + { 164,5703 }, { 165,5703 }, { 166,5703 }, { 167,5703 }, { 168,5703 }, + { 169,5703 }, { 170,5703 }, { 171,5703 }, { 172,5703 }, { 173,5703 }, + { 174,5703 }, { 175,5703 }, { 176,5703 }, { 177,5703 }, { 178,5703 }, + + { 179,5703 }, { 180,5703 }, { 181,5703 }, { 182,5703 }, { 183,5703 }, + { 184,5703 }, { 185,5703 }, { 186,5703 }, { 187,5703 }, { 188,5703 }, + { 189,5703 }, { 190,5703 }, { 191,5703 }, { 192,5703 }, { 193,5703 }, + { 194,5703 }, { 195,5703 }, { 196,5703 }, { 197,5703 }, { 198,5703 }, + { 199,5703 }, { 200,5703 }, { 201,5703 }, { 202,5703 }, { 203,5703 }, + { 204,5703 }, { 205,5703 }, { 206,5703 }, { 207,5703 }, { 208,5703 }, + { 209,5703 }, { 210,5703 }, { 211,5703 }, { 212,5703 }, { 213,5703 }, + { 214,5703 }, { 215,5703 }, { 216,5703 }, { 217,5703 }, { 218,5703 }, + { 219,5703 }, { 220,5703 }, { 221,5703 }, { 222,5703 }, { 223,5703 }, + { 224,5703 }, { 225,5703 }, { 226,5703 }, { 227,5703 }, { 228,5703 }, + + { 229,5703 }, { 230,5703 }, { 231,5703 }, { 232,5703 }, { 233,5703 }, + { 234,5703 }, { 235,5703 }, { 236,5703 }, { 237,5703 }, { 238,5703 }, + { 239,5703 }, { 240,5703 }, { 241,5703 }, { 242,5703 }, { 243,5703 }, + { 244,5703 }, { 245,5703 }, { 246,5703 }, { 247,5703 }, { 248,5703 }, + { 249,5703 }, { 250,5703 }, { 251,5703 }, { 252,5703 }, { 253,5703 }, + { 254,5703 }, { 255,5703 }, { 256,5703 }, { 0, 24 }, { 0,21401 }, + { 1,-15691 }, { 2,-15691 }, { 3,-15691 }, { 4,-15691 }, { 5,-15691 }, + { 6,-15691 }, { 7,-15691 }, { 8,-15691 }, { 9,-15433 }, { 10,-15175 }, + { 11,-15691 }, { 12,-15433 }, { 13,-15175 }, { 14,-15691 }, { 15,-15691 }, + { 16,-15691 }, { 17,-15691 }, { 18,-15691 }, { 19,-15691 }, { 20,-15691 }, + + { 21,-15691 }, { 22,-15691 }, { 23,-15691 }, { 24,-15691 }, { 25,-15691 }, + { 26,-15691 }, { 27,-15691 }, { 28,-15691 }, { 29,-15691 }, { 30,-15691 }, + { 31,-15691 }, { 32,-15433 }, { 33,-15691 }, { 34,-15691 }, { 35,-15691 }, + { 36,-15691 }, { 37,-15691 }, { 38,-15691 }, { 39,-15691 }, { 40,-15691 }, + { 41,-15691 }, { 42,-15691 }, { 43,-15691 }, { 44,-15691 }, { 45,6596 }, + { 46,-15691 }, { 47,-15691 }, { 48,-15691 }, { 49,-15691 }, { 50,-15691 }, + { 51,-15691 }, { 52,-15691 }, { 53,-15691 }, { 54,-15691 }, { 55,-15691 }, + { 56,-15691 }, { 57,-15691 }, { 58,-15691 }, { 59,-15691 }, { 60,-15691 }, + { 61,-15691 }, { 62,-15691 }, { 63,-15691 }, { 64,-15691 }, { 65,-15691 }, + { 66,-15691 }, { 67,-15691 }, { 68,-15691 }, { 69,-15691 }, { 70,-15691 }, + + { 71,-15691 }, { 72,-15691 }, { 73,-15691 }, { 74,-15691 }, { 75,-15691 }, + { 76,-15691 }, { 77,-15691 }, { 78,-15691 }, { 79,-15691 }, { 80,-15691 }, + { 81,-15691 }, { 82,-15691 }, { 83,-15691 }, { 84,-15691 }, { 85,-14798 }, + { 86,-15691 }, { 87,-15691 }, { 88,-15691 }, { 89,-15691 }, { 90,-15691 }, + { 91,-15691 }, { 92,-15691 }, { 93,-15691 }, { 94,-15691 }, { 95,-15691 }, + { 96,-15691 }, { 97,-15691 }, { 98,-15691 }, { 99,-15691 }, { 100,-15691 }, + { 101,-15691 }, { 102,-15691 }, { 103,-15691 }, { 104,-15691 }, { 105,-15691 }, + { 106,-15691 }, { 107,-15691 }, { 108,-15691 }, { 109,-15691 }, { 110,-15691 }, + { 111,-15691 }, { 112,-15691 }, { 113,-15691 }, { 114,-15691 }, { 115,-15691 }, + { 116,-15691 }, { 117,-14798 }, { 118,-15691 }, { 119,-15691 }, { 120,-15691 }, + + { 121,-15691 }, { 122,-15691 }, { 123,-15691 }, { 124,-15691 }, { 125,-15691 }, + { 126,-15691 }, { 127,-15691 }, { 128,-15691 }, { 129,-15691 }, { 130,-15691 }, + { 131,-15691 }, { 132,-15691 }, { 133,-15691 }, { 134,-15691 }, { 135,-15691 }, + { 136,-15691 }, { 137,-15691 }, { 138,-15691 }, { 139,-15691 }, { 140,-15691 }, + { 141,-15691 }, { 142,-15691 }, { 143,-15691 }, { 144,-15691 }, { 145,-15691 }, + { 146,-15691 }, { 147,-15691 }, { 148,-15691 }, { 149,-15691 }, { 150,-15691 }, + { 151,-15691 }, { 152,-15691 }, { 153,-15691 }, { 154,-15691 }, { 155,-15691 }, + { 156,-15691 }, { 157,-15691 }, { 158,-15691 }, { 159,-15691 }, { 160,-15691 }, + { 161,-15691 }, { 162,-15691 }, { 163,-15691 }, { 164,-15691 }, { 165,-15691 }, + { 166,-15691 }, { 167,-15691 }, { 168,-15691 }, { 169,-15691 }, { 170,-15691 }, + + { 171,-15691 }, { 172,-15691 }, { 173,-15691 }, { 174,-15691 }, { 175,-15691 }, + { 176,-15691 }, { 177,-15691 }, { 178,-15691 }, { 179,-15691 }, { 180,-15691 }, + { 181,-15691 }, { 182,-15691 }, { 183,-15691 }, { 184,-15691 }, { 185,-15691 }, + { 186,-15691 }, { 187,-15691 }, { 188,-15691 }, { 189,-15691 }, { 190,-15691 }, + { 191,-15691 }, { 192,-15691 }, { 193,-15691 }, { 194,-15691 }, { 195,-15691 }, + { 196,-15691 }, { 197,-15691 }, { 198,-15691 }, { 199,-15691 }, { 200,-15691 }, + { 201,-15691 }, { 202,-15691 }, { 203,-15691 }, { 204,-15691 }, { 205,-15691 }, + { 206,-15691 }, { 207,-15691 }, { 208,-15691 }, { 209,-15691 }, { 210,-15691 }, + { 211,-15691 }, { 212,-15691 }, { 213,-15691 }, { 214,-15691 }, { 215,-15691 }, + { 216,-15691 }, { 217,-15691 }, { 218,-15691 }, { 219,-15691 }, { 220,-15691 }, + + { 221,-15691 }, { 222,-15691 }, { 223,-15691 }, { 224,-15691 }, { 225,-15691 }, + { 226,-15691 }, { 227,-15691 }, { 228,-15691 }, { 229,-15691 }, { 230,-15691 }, + { 231,-15691 }, { 232,-15691 }, { 233,-15691 }, { 234,-15691 }, { 235,-15691 }, + { 236,-15691 }, { 237,-15691 }, { 238,-15691 }, { 239,-15691 }, { 240,-15691 }, + { 241,-15691 }, { 242,-15691 }, { 243,-15691 }, { 244,-15691 }, { 245,-15691 }, + { 246,-15691 }, { 247,-15691 }, { 248,-15691 }, { 249,-15691 }, { 250,-15691 }, + { 251,-15691 }, { 252,-15691 }, { 253,-15691 }, { 254,-15691 }, { 255,-15691 }, + { 256,-15691 }, { 0, 24 }, { 0,21143 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 9, 0 }, { 10, 0 }, { 0, 0 }, { 12, 0 }, + + { 13, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 32, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 39, 119 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 45,-32073 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 85,-36457 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 117,-36457 }, + { 0, 24 }, { 0,21024 }, { 1,-32235 }, { 2,-32235 }, { 3,-32235 }, + { 4,-32235 }, { 5,-32235 }, { 6,-32235 }, { 7,-32235 }, { 8,-32235 }, + { 9,-32235 }, { 10,-32235 }, { 11,-32235 }, { 12,-32235 }, { 13,-32235 }, + { 14,-32235 }, { 15,-32235 }, { 16,-32235 }, { 17,-32235 }, { 18,-32235 }, + { 19,-32235 }, { 20,-32235 }, { 21,-32235 }, { 22,-32235 }, { 23,-32235 }, + { 24,-32235 }, { 25,-32235 }, { 26,-32235 }, { 27,-32235 }, { 28,-32235 }, + { 29,-32235 }, { 30,-32235 }, { 31,-32235 }, { 32,-32235 }, { 33,-32235 }, + { 34,-32235 }, { 35,-32235 }, { 36,-32235 }, { 37,-32235 }, { 38,-32235 }, + { 0, 0 }, { 40,-32235 }, { 41,-32235 }, { 42,-32235 }, { 43,-32235 }, + + { 44,-32235 }, { 45,-32235 }, { 46,-32235 }, { 47,-32235 }, { 48,-32235 }, + { 49,-32235 }, { 50,-32235 }, { 51,-32235 }, { 52,-32235 }, { 53,-32235 }, + { 54,-32235 }, { 55,-32235 }, { 56,-32235 }, { 57,-32235 }, { 58,-32235 }, + { 59,-32235 }, { 60,-32235 }, { 61,-32235 }, { 62,-32235 }, { 63,-32235 }, + { 64,-32235 }, { 65,-32235 }, { 66,-32235 }, { 67,-32235 }, { 68,-32235 }, + { 69,-32235 }, { 70,-32235 }, { 71,-32235 }, { 72,-32235 }, { 73,-32235 }, + { 74,-32235 }, { 75,-32235 }, { 76,-32235 }, { 77,-32235 }, { 78,-32235 }, + { 79,-32235 }, { 80,-32235 }, { 81,-32235 }, { 82,-32235 }, { 83,-32235 }, + { 84,-32235 }, { 85,-32235 }, { 86,-32235 }, { 87,-32235 }, { 88,-32235 }, + { 89,-32235 }, { 90,-32235 }, { 91,-32235 }, { 92,-32235 }, { 93,-32235 }, + + { 94,-32235 }, { 95,-32235 }, { 96,-32235 }, { 97,-32235 }, { 98,-32235 }, + { 99,-32235 }, { 100,-32235 }, { 101,-32235 }, { 102,-32235 }, { 103,-32235 }, + { 104,-32235 }, { 105,-32235 }, { 106,-32235 }, { 107,-32235 }, { 108,-32235 }, + { 109,-32235 }, { 110,-32235 }, { 111,-32235 }, { 112,-32235 }, { 113,-32235 }, + { 114,-32235 }, { 115,-32235 }, { 116,-32235 }, { 117,-32235 }, { 118,-32235 }, + { 119,-32235 }, { 120,-32235 }, { 121,-32235 }, { 122,-32235 }, { 123,-32235 }, + { 124,-32235 }, { 125,-32235 }, { 126,-32235 }, { 127,-32235 }, { 128,-32235 }, + { 129,-32235 }, { 130,-32235 }, { 131,-32235 }, { 132,-32235 }, { 133,-32235 }, + { 134,-32235 }, { 135,-32235 }, { 136,-32235 }, { 137,-32235 }, { 138,-32235 }, + { 139,-32235 }, { 140,-32235 }, { 141,-32235 }, { 142,-32235 }, { 143,-32235 }, + + { 144,-32235 }, { 145,-32235 }, { 146,-32235 }, { 147,-32235 }, { 148,-32235 }, + { 149,-32235 }, { 150,-32235 }, { 151,-32235 }, { 152,-32235 }, { 153,-32235 }, + { 154,-32235 }, { 155,-32235 }, { 156,-32235 }, { 157,-32235 }, { 158,-32235 }, + { 159,-32235 }, { 160,-32235 }, { 161,-32235 }, { 162,-32235 }, { 163,-32235 }, + { 164,-32235 }, { 165,-32235 }, { 166,-32235 }, { 167,-32235 }, { 168,-32235 }, + { 169,-32235 }, { 170,-32235 }, { 171,-32235 }, { 172,-32235 }, { 173,-32235 }, + { 174,-32235 }, { 175,-32235 }, { 176,-32235 }, { 177,-32235 }, { 178,-32235 }, + { 179,-32235 }, { 180,-32235 }, { 181,-32235 }, { 182,-32235 }, { 183,-32235 }, + { 184,-32235 }, { 185,-32235 }, { 186,-32235 }, { 187,-32235 }, { 188,-32235 }, + { 189,-32235 }, { 190,-32235 }, { 191,-32235 }, { 192,-32235 }, { 193,-32235 }, + + { 194,-32235 }, { 195,-32235 }, { 196,-32235 }, { 197,-32235 }, { 198,-32235 }, + { 199,-32235 }, { 200,-32235 }, { 201,-32235 }, { 202,-32235 }, { 203,-32235 }, + { 204,-32235 }, { 205,-32235 }, { 206,-32235 }, { 207,-32235 }, { 208,-32235 }, + { 209,-32235 }, { 210,-32235 }, { 211,-32235 }, { 212,-32235 }, { 213,-32235 }, + { 214,-32235 }, { 215,-32235 }, { 216,-32235 }, { 217,-32235 }, { 218,-32235 }, + { 219,-32235 }, { 220,-32235 }, { 221,-32235 }, { 222,-32235 }, { 223,-32235 }, + { 224,-32235 }, { 225,-32235 }, { 226,-32235 }, { 227,-32235 }, { 228,-32235 }, + { 229,-32235 }, { 230,-32235 }, { 231,-32235 }, { 232,-32235 }, { 233,-32235 }, + { 234,-32235 }, { 235,-32235 }, { 236,-32235 }, { 237,-32235 }, { 238,-32235 }, + { 239,-32235 }, { 240,-32235 }, { 241,-32235 }, { 242,-32235 }, { 243,-32235 }, + + { 244,-32235 }, { 245,-32235 }, { 246,-32235 }, { 247,-32235 }, { 248,-32235 }, + { 249,-32235 }, { 250,-32235 }, { 251,-32235 }, { 252,-32235 }, { 253,-32235 }, + { 254,-32235 }, { 255,-32235 }, { 256,-32235 }, { 0, 24 }, { 0,20766 }, + { 1,-21365 }, { 2,-21365 }, { 3,-21365 }, { 4,-21365 }, { 5,-21365 }, + { 6,-21365 }, { 7,-21365 }, { 8,-21365 }, { 9,-21107 }, { 10,-29020 }, + { 11,-21365 }, { 12,-21107 }, { 13,-29020 }, { 14,-21365 }, { 15,-21365 }, + { 16,-21365 }, { 17,-21365 }, { 18,-21365 }, { 19,-21365 }, { 20,-21365 }, + { 21,-21365 }, { 22,-21365 }, { 23,-21365 }, { 24,-21365 }, { 25,-21365 }, + { 26,-21365 }, { 27,-21365 }, { 28,-21365 }, { 29,-21365 }, { 30,-21365 }, + { 31,-21365 }, { 32,-21107 }, { 33,-21365 }, { 34,-21365 }, { 35,-21365 }, + + { 36,-21365 }, { 37,-21365 }, { 38,-21365 }, { 39,6477 }, { 40,-21365 }, + { 41,-21365 }, { 42,-21365 }, { 43,-21365 }, { 44,-21365 }, { 45,-20849 }, + { 46,-21365 }, { 47,-21365 }, { 48,-21365 }, { 49,-21365 }, { 50,-21365 }, + { 51,-21365 }, { 52,-21365 }, { 53,-21365 }, { 54,-21365 }, { 55,-21365 }, + { 56,-21365 }, { 57,-21365 }, { 58,-21365 }, { 59,-21365 }, { 60,-21365 }, + { 61,-21365 }, { 62,-21365 }, { 63,-21365 }, { 64,-21365 }, { 65,-21365 }, + { 66,-21365 }, { 67,-21365 }, { 68,-21365 }, { 69,-21365 }, { 70,-21365 }, + { 71,-21365 }, { 72,-21365 }, { 73,-21365 }, { 74,-21365 }, { 75,-21365 }, + { 76,-21365 }, { 77,-21365 }, { 78,-21365 }, { 79,-21365 }, { 80,-21365 }, + { 81,-21365 }, { 82,-21365 }, { 83,-21365 }, { 84,-21365 }, { 85,-20591 }, + + { 86,-21365 }, { 87,-21365 }, { 88,-21365 }, { 89,-21365 }, { 90,-21365 }, + { 91,-21365 }, { 92,-21365 }, { 93,-21365 }, { 94,-21365 }, { 95,-21365 }, + { 96,-21365 }, { 97,-21365 }, { 98,-21365 }, { 99,-21365 }, { 100,-21365 }, + { 101,-21365 }, { 102,-21365 }, { 103,-21365 }, { 104,-21365 }, { 105,-21365 }, + { 106,-21365 }, { 107,-21365 }, { 108,-21365 }, { 109,-21365 }, { 110,-21365 }, + { 111,-21365 }, { 112,-21365 }, { 113,-21365 }, { 114,-21365 }, { 115,-21365 }, + { 116,-21365 }, { 117,-20591 }, { 118,-21365 }, { 119,-21365 }, { 120,-21365 }, + { 121,-21365 }, { 122,-21365 }, { 123,-21365 }, { 124,-21365 }, { 125,-21365 }, + { 126,-21365 }, { 127,-21365 }, { 128,-21365 }, { 129,-21365 }, { 130,-21365 }, + { 131,-21365 }, { 132,-21365 }, { 133,-21365 }, { 134,-21365 }, { 135,-21365 }, + + { 136,-21365 }, { 137,-21365 }, { 138,-21365 }, { 139,-21365 }, { 140,-21365 }, + { 141,-21365 }, { 142,-21365 }, { 143,-21365 }, { 144,-21365 }, { 145,-21365 }, + { 146,-21365 }, { 147,-21365 }, { 148,-21365 }, { 149,-21365 }, { 150,-21365 }, + { 151,-21365 }, { 152,-21365 }, { 153,-21365 }, { 154,-21365 }, { 155,-21365 }, + { 156,-21365 }, { 157,-21365 }, { 158,-21365 }, { 159,-21365 }, { 160,-21365 }, + { 161,-21365 }, { 162,-21365 }, { 163,-21365 }, { 164,-21365 }, { 165,-21365 }, + { 166,-21365 }, { 167,-21365 }, { 168,-21365 }, { 169,-21365 }, { 170,-21365 }, + { 171,-21365 }, { 172,-21365 }, { 173,-21365 }, { 174,-21365 }, { 175,-21365 }, + { 176,-21365 }, { 177,-21365 }, { 178,-21365 }, { 179,-21365 }, { 180,-21365 }, + { 181,-21365 }, { 182,-21365 }, { 183,-21365 }, { 184,-21365 }, { 185,-21365 }, + + { 186,-21365 }, { 187,-21365 }, { 188,-21365 }, { 189,-21365 }, { 190,-21365 }, + { 191,-21365 }, { 192,-21365 }, { 193,-21365 }, { 194,-21365 }, { 195,-21365 }, + { 196,-21365 }, { 197,-21365 }, { 198,-21365 }, { 199,-21365 }, { 200,-21365 }, + { 201,-21365 }, { 202,-21365 }, { 203,-21365 }, { 204,-21365 }, { 205,-21365 }, + { 206,-21365 }, { 207,-21365 }, { 208,-21365 }, { 209,-21365 }, { 210,-21365 }, + { 211,-21365 }, { 212,-21365 }, { 213,-21365 }, { 214,-21365 }, { 215,-21365 }, + { 216,-21365 }, { 217,-21365 }, { 218,-21365 }, { 219,-21365 }, { 220,-21365 }, + { 221,-21365 }, { 222,-21365 }, { 223,-21365 }, { 224,-21365 }, { 225,-21365 }, + { 226,-21365 }, { 227,-21365 }, { 228,-21365 }, { 229,-21365 }, { 230,-21365 }, + { 231,-21365 }, { 232,-21365 }, { 233,-21365 }, { 234,-21365 }, { 235,-21365 }, + + { 236,-21365 }, { 237,-21365 }, { 238,-21365 }, { 239,-21365 }, { 240,-21365 }, + { 241,-21365 }, { 242,-21365 }, { 243,-21365 }, { 244,-21365 }, { 245,-21365 }, + { 246,-21365 }, { 247,-21365 }, { 248,-21365 }, { 249,-21365 }, { 250,-21365 }, + { 251,-21365 }, { 252,-21365 }, { 253,-21365 }, { 254,-21365 }, { 255,-21365 }, + { 256,-21365 }, { 0, 24 }, { 0,20508 }, { 1,-21623 }, { 2,-21623 }, + { 3,-21623 }, { 4,-21623 }, { 5,-21623 }, { 6,-21623 }, { 7,-21623 }, + { 8,-21623 }, { 9,-21365 }, { 10,-29278 }, { 11,-21623 }, { 12,-21365 }, + { 13,-29278 }, { 14,-21623 }, { 15,-21623 }, { 16,-21623 }, { 17,-21623 }, + { 18,-21623 }, { 19,-21623 }, { 20,-21623 }, { 21,-21623 }, { 22,-21623 }, + { 23,-21623 }, { 24,-21623 }, { 25,-21623 }, { 26,-21623 }, { 27,-21623 }, + + { 28,-21623 }, { 29,-21623 }, { 30,-21623 }, { 31,-21623 }, { 32,-21365 }, + { 33,-21623 }, { 34,-21623 }, { 35,-21623 }, { 36,-21623 }, { 37,-21623 }, + { 38,-21623 }, { 39,6219 }, { 40,-21623 }, { 41,-21623 }, { 42,-21623 }, + { 43,-21623 }, { 44,-21623 }, { 45,-21107 }, { 46,-21623 }, { 47,-21623 }, + { 48,-21623 }, { 49,-21623 }, { 50,-21623 }, { 51,-21623 }, { 52,-21623 }, + { 53,-21623 }, { 54,-21623 }, { 55,-21623 }, { 56,-21623 }, { 57,-21623 }, + { 58,-21623 }, { 59,-21623 }, { 60,-21623 }, { 61,-21623 }, { 62,-21623 }, + { 63,-21623 }, { 64,-21623 }, { 65,-21623 }, { 66,-21623 }, { 67,-21623 }, + { 68,-21623 }, { 69,-21623 }, { 70,-21623 }, { 71,-21623 }, { 72,-21623 }, + { 73,-21623 }, { 74,-21623 }, { 75,-21623 }, { 76,-21623 }, { 77,-21623 }, + + { 78,-21623 }, { 79,-21623 }, { 80,-21623 }, { 81,-21623 }, { 82,-21623 }, + { 83,-21623 }, { 84,-21623 }, { 85,-20849 }, { 86,-21623 }, { 87,-21623 }, + { 88,-21623 }, { 89,-21623 }, { 90,-21623 }, { 91,-21623 }, { 92,-21623 }, + { 93,-21623 }, { 94,-21623 }, { 95,-21623 }, { 96,-21623 }, { 97,-21623 }, + { 98,-21623 }, { 99,-21623 }, { 100,-21623 }, { 101,-21623 }, { 102,-21623 }, + { 103,-21623 }, { 104,-21623 }, { 105,-21623 }, { 106,-21623 }, { 107,-21623 }, + { 108,-21623 }, { 109,-21623 }, { 110,-21623 }, { 111,-21623 }, { 112,-21623 }, + { 113,-21623 }, { 114,-21623 }, { 115,-21623 }, { 116,-21623 }, { 117,-20849 }, + { 118,-21623 }, { 119,-21623 }, { 120,-21623 }, { 121,-21623 }, { 122,-21623 }, + { 123,-21623 }, { 124,-21623 }, { 125,-21623 }, { 126,-21623 }, { 127,-21623 }, + + { 128,-21623 }, { 129,-21623 }, { 130,-21623 }, { 131,-21623 }, { 132,-21623 }, + { 133,-21623 }, { 134,-21623 }, { 135,-21623 }, { 136,-21623 }, { 137,-21623 }, + { 138,-21623 }, { 139,-21623 }, { 140,-21623 }, { 141,-21623 }, { 142,-21623 }, + { 143,-21623 }, { 144,-21623 }, { 145,-21623 }, { 146,-21623 }, { 147,-21623 }, + { 148,-21623 }, { 149,-21623 }, { 150,-21623 }, { 151,-21623 }, { 152,-21623 }, + { 153,-21623 }, { 154,-21623 }, { 155,-21623 }, { 156,-21623 }, { 157,-21623 }, + { 158,-21623 }, { 159,-21623 }, { 160,-21623 }, { 161,-21623 }, { 162,-21623 }, + { 163,-21623 }, { 164,-21623 }, { 165,-21623 }, { 166,-21623 }, { 167,-21623 }, + { 168,-21623 }, { 169,-21623 }, { 170,-21623 }, { 171,-21623 }, { 172,-21623 }, + { 173,-21623 }, { 174,-21623 }, { 175,-21623 }, { 176,-21623 }, { 177,-21623 }, + + { 178,-21623 }, { 179,-21623 }, { 180,-21623 }, { 181,-21623 }, { 182,-21623 }, + { 183,-21623 }, { 184,-21623 }, { 185,-21623 }, { 186,-21623 }, { 187,-21623 }, + { 188,-21623 }, { 189,-21623 }, { 190,-21623 }, { 191,-21623 }, { 192,-21623 }, + { 193,-21623 }, { 194,-21623 }, { 195,-21623 }, { 196,-21623 }, { 197,-21623 }, + { 198,-21623 }, { 199,-21623 }, { 200,-21623 }, { 201,-21623 }, { 202,-21623 }, + { 203,-21623 }, { 204,-21623 }, { 205,-21623 }, { 206,-21623 }, { 207,-21623 }, + { 208,-21623 }, { 209,-21623 }, { 210,-21623 }, { 211,-21623 }, { 212,-21623 }, + { 213,-21623 }, { 214,-21623 }, { 215,-21623 }, { 216,-21623 }, { 217,-21623 }, + { 218,-21623 }, { 219,-21623 }, { 220,-21623 }, { 221,-21623 }, { 222,-21623 }, + { 223,-21623 }, { 224,-21623 }, { 225,-21623 }, { 226,-21623 }, { 227,-21623 }, + + { 228,-21623 }, { 229,-21623 }, { 230,-21623 }, { 231,-21623 }, { 232,-21623 }, + { 233,-21623 }, { 234,-21623 }, { 235,-21623 }, { 236,-21623 }, { 237,-21623 }, + { 238,-21623 }, { 239,-21623 }, { 240,-21623 }, { 241,-21623 }, { 242,-21623 }, + { 243,-21623 }, { 244,-21623 }, { 245,-21623 }, { 246,-21623 }, { 247,-21623 }, + { 248,-21623 }, { 249,-21623 }, { 250,-21623 }, { 251,-21623 }, { 252,-21623 }, + { 253,-21623 }, { 254,-21623 }, { 255,-21623 }, { 256,-21623 }, { 0, 24 }, + { 0,20250 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 9,-26898 }, + { 10,-26898 }, { 0, 0 }, { 12,-26898 }, { 13,-26898 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 32,-26898 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 39,-32959 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 45,-36845 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 85,-37350 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 117,-37350 }, { 0, 24 }, { 0,20131 }, + + { 1,-22000 }, { 2,-22000 }, { 3,-22000 }, { 4,-22000 }, { 5,-22000 }, + { 6,-22000 }, { 7,-22000 }, { 8,-22000 }, { 9,-21742 }, { 10,-29655 }, + { 11,-22000 }, { 12,-21742 }, { 13,-29655 }, { 14,-22000 }, { 15,-22000 }, + { 16,-22000 }, { 17,-22000 }, { 18,-22000 }, { 19,-22000 }, { 20,-22000 }, + { 21,-22000 }, { 22,-22000 }, { 23,-22000 }, { 24,-22000 }, { 25,-22000 }, + { 26,-22000 }, { 27,-22000 }, { 28,-22000 }, { 29,-22000 }, { 30,-22000 }, + { 31,-22000 }, { 32,-21742 }, { 33,-22000 }, { 34,-22000 }, { 35,-22000 }, + { 36,-22000 }, { 37,-22000 }, { 38,-22000 }, { 39,5842 }, { 40,-22000 }, + { 41,-22000 }, { 42,-22000 }, { 43,-22000 }, { 44,-22000 }, { 45,-15810 }, + { 46,-22000 }, { 47,-22000 }, { 48,-22000 }, { 49,-22000 }, { 50,-22000 }, + + { 51,-22000 }, { 52,-22000 }, { 53,-22000 }, { 54,-22000 }, { 55,-22000 }, + { 56,-22000 }, { 57,-22000 }, { 58,-22000 }, { 59,-22000 }, { 60,-22000 }, + { 61,-22000 }, { 62,-22000 }, { 63,-22000 }, { 64,-22000 }, { 65,-22000 }, + { 66,-22000 }, { 67,-22000 }, { 68,-22000 }, { 69,-22000 }, { 70,-22000 }, + { 71,-22000 }, { 72,-22000 }, { 73,-22000 }, { 74,-22000 }, { 75,-22000 }, + { 76,-22000 }, { 77,-22000 }, { 78,-22000 }, { 79,-22000 }, { 80,-22000 }, + { 81,-22000 }, { 82,-22000 }, { 83,-22000 }, { 84,-22000 }, { 85,-21226 }, + { 86,-22000 }, { 87,-22000 }, { 88,-22000 }, { 89,-22000 }, { 90,-22000 }, + { 91,-22000 }, { 92,-22000 }, { 93,-22000 }, { 94,-22000 }, { 95,-22000 }, + { 96,-22000 }, { 97,-22000 }, { 98,-22000 }, { 99,-22000 }, { 100,-22000 }, + + { 101,-22000 }, { 102,-22000 }, { 103,-22000 }, { 104,-22000 }, { 105,-22000 }, + { 106,-22000 }, { 107,-22000 }, { 108,-22000 }, { 109,-22000 }, { 110,-22000 }, + { 111,-22000 }, { 112,-22000 }, { 113,-22000 }, { 114,-22000 }, { 115,-22000 }, + { 116,-22000 }, { 117,-21226 }, { 118,-22000 }, { 119,-22000 }, { 120,-22000 }, + { 121,-22000 }, { 122,-22000 }, { 123,-22000 }, { 124,-22000 }, { 125,-22000 }, + { 126,-22000 }, { 127,-22000 }, { 128,-22000 }, { 129,-22000 }, { 130,-22000 }, + { 131,-22000 }, { 132,-22000 }, { 133,-22000 }, { 134,-22000 }, { 135,-22000 }, + { 136,-22000 }, { 137,-22000 }, { 138,-22000 }, { 139,-22000 }, { 140,-22000 }, + { 141,-22000 }, { 142,-22000 }, { 143,-22000 }, { 144,-22000 }, { 145,-22000 }, + { 146,-22000 }, { 147,-22000 }, { 148,-22000 }, { 149,-22000 }, { 150,-22000 }, + + { 151,-22000 }, { 152,-22000 }, { 153,-22000 }, { 154,-22000 }, { 155,-22000 }, + { 156,-22000 }, { 157,-22000 }, { 158,-22000 }, { 159,-22000 }, { 160,-22000 }, + { 161,-22000 }, { 162,-22000 }, { 163,-22000 }, { 164,-22000 }, { 165,-22000 }, + { 166,-22000 }, { 167,-22000 }, { 168,-22000 }, { 169,-22000 }, { 170,-22000 }, + { 171,-22000 }, { 172,-22000 }, { 173,-22000 }, { 174,-22000 }, { 175,-22000 }, + { 176,-22000 }, { 177,-22000 }, { 178,-22000 }, { 179,-22000 }, { 180,-22000 }, + { 181,-22000 }, { 182,-22000 }, { 183,-22000 }, { 184,-22000 }, { 185,-22000 }, + { 186,-22000 }, { 187,-22000 }, { 188,-22000 }, { 189,-22000 }, { 190,-22000 }, + { 191,-22000 }, { 192,-22000 }, { 193,-22000 }, { 194,-22000 }, { 195,-22000 }, + { 196,-22000 }, { 197,-22000 }, { 198,-22000 }, { 199,-22000 }, { 200,-22000 }, + + { 201,-22000 }, { 202,-22000 }, { 203,-22000 }, { 204,-22000 }, { 205,-22000 }, + { 206,-22000 }, { 207,-22000 }, { 208,-22000 }, { 209,-22000 }, { 210,-22000 }, + { 211,-22000 }, { 212,-22000 }, { 213,-22000 }, { 214,-22000 }, { 215,-22000 }, + { 216,-22000 }, { 217,-22000 }, { 218,-22000 }, { 219,-22000 }, { 220,-22000 }, + { 221,-22000 }, { 222,-22000 }, { 223,-22000 }, { 224,-22000 }, { 225,-22000 }, + { 226,-22000 }, { 227,-22000 }, { 228,-22000 }, { 229,-22000 }, { 230,-22000 }, + { 231,-22000 }, { 232,-22000 }, { 233,-22000 }, { 234,-22000 }, { 235,-22000 }, + { 236,-22000 }, { 237,-22000 }, { 238,-22000 }, { 239,-22000 }, { 240,-22000 }, + { 241,-22000 }, { 242,-22000 }, { 243,-22000 }, { 244,-22000 }, { 245,-22000 }, + { 246,-22000 }, { 247,-22000 }, { 248,-22000 }, { 249,-22000 }, { 250,-22000 }, + + { 251,-22000 }, { 252,-22000 }, { 253,-22000 }, { 254,-22000 }, { 255,-22000 }, + { 256,-22000 }, { 0, 24 }, { 0,19873 }, { 1,-22258 }, { 2,-22258 }, + { 3,-22258 }, { 4,-22258 }, { 5,-22258 }, { 6,-22258 }, { 7,-22258 }, + { 8,-22258 }, { 9,-22000 }, { 10,-29913 }, { 11,-22258 }, { 12,-22000 }, + { 13,-29913 }, { 14,-22258 }, { 15,-22258 }, { 16,-22258 }, { 17,-22258 }, + { 18,-22258 }, { 19,-22258 }, { 20,-22258 }, { 21,-22258 }, { 22,-22258 }, + { 23,-22258 }, { 24,-22258 }, { 25,-22258 }, { 26,-22258 }, { 27,-22258 }, + { 28,-22258 }, { 29,-22258 }, { 30,-22258 }, { 31,-22258 }, { 32,-22000 }, + { 33,-22258 }, { 34,-22258 }, { 35,-22258 }, { 36,-22258 }, { 37,-22258 }, + { 38,-22258 }, { 39,5584 }, { 40,-22258 }, { 41,-22258 }, { 42,-22258 }, + + { 43,-22258 }, { 44,-22258 }, { 45,-21742 }, { 46,-22258 }, { 47,-22258 }, + { 48,-22258 }, { 49,-22258 }, { 50,-22258 }, { 51,-22258 }, { 52,-22258 }, + { 53,-22258 }, { 54,-22258 }, { 55,-22258 }, { 56,-22258 }, { 57,-22258 }, + { 58,-22258 }, { 59,-22258 }, { 60,-22258 }, { 61,-22258 }, { 62,-22258 }, + { 63,-22258 }, { 64,-22258 }, { 65,-22258 }, { 66,-22258 }, { 67,-22258 }, + { 68,-22258 }, { 69,-15810 }, { 70,-22258 }, { 71,-22258 }, { 72,-22258 }, + { 73,-22258 }, { 74,-22258 }, { 75,-22258 }, { 76,-22258 }, { 77,-22258 }, + { 78,-22258 }, { 79,-22258 }, { 80,-22258 }, { 81,-22258 }, { 82,-22258 }, + { 83,-22258 }, { 84,-22258 }, { 85,-21484 }, { 86,-22258 }, { 87,-22258 }, + { 88,-22258 }, { 89,-22258 }, { 90,-22258 }, { 91,-22258 }, { 92,-22258 }, + + { 93,-22258 }, { 94,-22258 }, { 95,-22258 }, { 96,-22258 }, { 97,-22258 }, + { 98,-22258 }, { 99,-22258 }, { 100,-22258 }, { 101,-15810 }, { 102,-22258 }, + { 103,-22258 }, { 104,-22258 }, { 105,-22258 }, { 106,-22258 }, { 107,-22258 }, + { 108,-22258 }, { 109,-22258 }, { 110,-22258 }, { 111,-22258 }, { 112,-22258 }, + { 113,-22258 }, { 114,-22258 }, { 115,-22258 }, { 116,-22258 }, { 117,-21484 }, + { 118,-22258 }, { 119,-22258 }, { 120,-22258 }, { 121,-22258 }, { 122,-22258 }, + { 123,-22258 }, { 124,-22258 }, { 125,-22258 }, { 126,-22258 }, { 127,-22258 }, + { 128,-22258 }, { 129,-22258 }, { 130,-22258 }, { 131,-22258 }, { 132,-22258 }, + { 133,-22258 }, { 134,-22258 }, { 135,-22258 }, { 136,-22258 }, { 137,-22258 }, + { 138,-22258 }, { 139,-22258 }, { 140,-22258 }, { 141,-22258 }, { 142,-22258 }, + + { 143,-22258 }, { 144,-22258 }, { 145,-22258 }, { 146,-22258 }, { 147,-22258 }, + { 148,-22258 }, { 149,-22258 }, { 150,-22258 }, { 151,-22258 }, { 152,-22258 }, + { 153,-22258 }, { 154,-22258 }, { 155,-22258 }, { 156,-22258 }, { 157,-22258 }, + { 158,-22258 }, { 159,-22258 }, { 160,-22258 }, { 161,-22258 }, { 162,-22258 }, + { 163,-22258 }, { 164,-22258 }, { 165,-22258 }, { 166,-22258 }, { 167,-22258 }, + { 168,-22258 }, { 169,-22258 }, { 170,-22258 }, { 171,-22258 }, { 172,-22258 }, + { 173,-22258 }, { 174,-22258 }, { 175,-22258 }, { 176,-22258 }, { 177,-22258 }, + { 178,-22258 }, { 179,-22258 }, { 180,-22258 }, { 181,-22258 }, { 182,-22258 }, + { 183,-22258 }, { 184,-22258 }, { 185,-22258 }, { 186,-22258 }, { 187,-22258 }, + { 188,-22258 }, { 189,-22258 }, { 190,-22258 }, { 191,-22258 }, { 192,-22258 }, + + { 193,-22258 }, { 194,-22258 }, { 195,-22258 }, { 196,-22258 }, { 197,-22258 }, + { 198,-22258 }, { 199,-22258 }, { 200,-22258 }, { 201,-22258 }, { 202,-22258 }, + { 203,-22258 }, { 204,-22258 }, { 205,-22258 }, { 206,-22258 }, { 207,-22258 }, + { 208,-22258 }, { 209,-22258 }, { 210,-22258 }, { 211,-22258 }, { 212,-22258 }, + { 213,-22258 }, { 214,-22258 }, { 215,-22258 }, { 216,-22258 }, { 217,-22258 }, + { 218,-22258 }, { 219,-22258 }, { 220,-22258 }, { 221,-22258 }, { 222,-22258 }, + { 223,-22258 }, { 224,-22258 }, { 225,-22258 }, { 226,-22258 }, { 227,-22258 }, + { 228,-22258 }, { 229,-22258 }, { 230,-22258 }, { 231,-22258 }, { 232,-22258 }, + { 233,-22258 }, { 234,-22258 }, { 235,-22258 }, { 236,-22258 }, { 237,-22258 }, + { 238,-22258 }, { 239,-22258 }, { 240,-22258 }, { 241,-22258 }, { 242,-22258 }, + + { 243,-22258 }, { 244,-22258 }, { 245,-22258 }, { 246,-22258 }, { 247,-22258 }, + { 248,-22258 }, { 249,-22258 }, { 250,-22258 }, { 251,-22258 }, { 252,-22258 }, + { 253,-22258 }, { 254,-22258 }, { 255,-22258 }, { 256,-22258 }, { 0, 24 }, + { 0,19615 }, { 1,5584 }, { 2,5584 }, { 3,5584 }, { 4,5584 }, + { 5,5584 }, { 6,5584 }, { 7,5584 }, { 8,5584 }, { 9,5842 }, + { 10,-6576 }, { 11,5584 }, { 12,5842 }, { 13,-6576 }, { 14,5584 }, + { 15,5584 }, { 16,5584 }, { 17,5584 }, { 18,5584 }, { 19,5584 }, + { 20,5584 }, { 21,5584 }, { 22,5584 }, { 23,5584 }, { 24,5584 }, + { 25,5584 }, { 26,5584 }, { 27,5584 }, { 28,5584 }, { 29,5584 }, + { 30,5584 }, { 31,5584 }, { 32,5842 }, { 33,5584 }, { 34,5584 }, + + { 35,5584 }, { 36,5584 }, { 37,5584 }, { 38,5584 }, { 39,6100 }, + { 40,5584 }, { 41,5584 }, { 42,5584 }, { 43,5584 }, { 44,5584 }, + { 45,6358 }, { 46,5584 }, { 47,5584 }, { 48,5584 }, { 49,5584 }, + { 50,5584 }, { 51,5584 }, { 52,5584 }, { 53,5584 }, { 54,5584 }, + { 55,5584 }, { 56,5584 }, { 57,5584 }, { 58,5584 }, { 59,5584 }, + { 60,5584 }, { 61,5584 }, { 62,5584 }, { 63,5584 }, { 64,5584 }, + { 65,5584 }, { 66,5584 }, { 67,5584 }, { 68,5584 }, { 69,5584 }, + { 70,5584 }, { 71,5584 }, { 72,5584 }, { 73,5584 }, { 74,5584 }, + { 75,5584 }, { 76,5584 }, { 77,5584 }, { 78,5584 }, { 79,5584 }, + { 80,5584 }, { 81,5584 }, { 82,5584 }, { 83,5584 }, { 84,5584 }, + + { 85,6616 }, { 86,5584 }, { 87,5584 }, { 88,5584 }, { 89,5584 }, + { 90,5584 }, { 91,5584 }, { 92,5584 }, { 93,5584 }, { 94,5584 }, + { 95,5584 }, { 96,5584 }, { 97,5584 }, { 98,5584 }, { 99,5584 }, + { 100,5584 }, { 101,5584 }, { 102,5584 }, { 103,5584 }, { 104,5584 }, + { 105,5584 }, { 106,5584 }, { 107,5584 }, { 108,5584 }, { 109,5584 }, + { 110,5584 }, { 111,5584 }, { 112,5584 }, { 113,5584 }, { 114,5584 }, + { 115,5584 }, { 116,5584 }, { 117,6616 }, { 118,5584 }, { 119,5584 }, + { 120,5584 }, { 121,5584 }, { 122,5584 }, { 123,5584 }, { 124,5584 }, + { 125,5584 }, { 126,5584 }, { 127,5584 }, { 128,5584 }, { 129,5584 }, + { 130,5584 }, { 131,5584 }, { 132,5584 }, { 133,5584 }, { 134,5584 }, + + { 135,5584 }, { 136,5584 }, { 137,5584 }, { 138,5584 }, { 139,5584 }, + { 140,5584 }, { 141,5584 }, { 142,5584 }, { 143,5584 }, { 144,5584 }, + { 145,5584 }, { 146,5584 }, { 147,5584 }, { 148,5584 }, { 149,5584 }, + { 150,5584 }, { 151,5584 }, { 152,5584 }, { 153,5584 }, { 154,5584 }, + { 155,5584 }, { 156,5584 }, { 157,5584 }, { 158,5584 }, { 159,5584 }, + { 160,5584 }, { 161,5584 }, { 162,5584 }, { 163,5584 }, { 164,5584 }, + { 165,5584 }, { 166,5584 }, { 167,5584 }, { 168,5584 }, { 169,5584 }, + { 170,5584 }, { 171,5584 }, { 172,5584 }, { 173,5584 }, { 174,5584 }, + { 175,5584 }, { 176,5584 }, { 177,5584 }, { 178,5584 }, { 179,5584 }, + { 180,5584 }, { 181,5584 }, { 182,5584 }, { 183,5584 }, { 184,5584 }, + + { 185,5584 }, { 186,5584 }, { 187,5584 }, { 188,5584 }, { 189,5584 }, + { 190,5584 }, { 191,5584 }, { 192,5584 }, { 193,5584 }, { 194,5584 }, + { 195,5584 }, { 196,5584 }, { 197,5584 }, { 198,5584 }, { 199,5584 }, + { 200,5584 }, { 201,5584 }, { 202,5584 }, { 203,5584 }, { 204,5584 }, + { 205,5584 }, { 206,5584 }, { 207,5584 }, { 208,5584 }, { 209,5584 }, + { 210,5584 }, { 211,5584 }, { 212,5584 }, { 213,5584 }, { 214,5584 }, + { 215,5584 }, { 216,5584 }, { 217,5584 }, { 218,5584 }, { 219,5584 }, + { 220,5584 }, { 221,5584 }, { 222,5584 }, { 223,5584 }, { 224,5584 }, + { 225,5584 }, { 226,5584 }, { 227,5584 }, { 228,5584 }, { 229,5584 }, + { 230,5584 }, { 231,5584 }, { 232,5584 }, { 233,5584 }, { 234,5584 }, + + { 235,5584 }, { 236,5584 }, { 237,5584 }, { 238,5584 }, { 239,5584 }, + { 240,5584 }, { 241,5584 }, { 242,5584 }, { 243,5584 }, { 244,5584 }, + { 245,5584 }, { 246,5584 }, { 247,5584 }, { 248,5584 }, { 249,5584 }, + { 250,5584 }, { 251,5584 }, { 252,5584 }, { 253,5584 }, { 254,5584 }, + { 255,5584 }, { 256,5584 }, { 0, 24 }, { 0,19357 }, { 1,-6199 }, + { 2,-6199 }, { 3,-6199 }, { 4,-6199 }, { 5,-6199 }, { 6,-6199 }, + { 7,-6199 }, { 8,-6199 }, { 9,-5941 }, { 10,-10974 }, { 11,-6199 }, + { 12,-5941 }, { 13,-10974 }, { 14,-6199 }, { 15,-6199 }, { 16,-6199 }, + { 17,-6199 }, { 18,-6199 }, { 19,-6199 }, { 20,-6199 }, { 21,-6199 }, + { 22,-6199 }, { 23,-6199 }, { 24,-6199 }, { 25,-6199 }, { 26,-6199 }, + + { 27,-6199 }, { 28,-6199 }, { 29,-6199 }, { 30,-6199 }, { 31,-6199 }, + { 32,-5941 }, { 33,-6199 }, { 34,-6199 }, { 35,-6199 }, { 36,-6199 }, + { 37,-6199 }, { 38,-6199 }, { 39,6616 }, { 40,-6199 }, { 41,-6199 }, + { 42,-6199 }, { 43,-6199 }, { 44,-6199 }, { 45,-5425 }, { 46,-6199 }, + { 47,-6199 }, { 48,-6199 }, { 49,-6199 }, { 50,-6199 }, { 51,-6199 }, + { 52,-6199 }, { 53,-6199 }, { 54,-6199 }, { 55,-6199 }, { 56,-6199 }, + { 57,-6199 }, { 58,-6199 }, { 59,-6199 }, { 60,-6199 }, { 61,-6199 }, + { 62,-6199 }, { 63,-6199 }, { 64,-6199 }, { 65,-6199 }, { 66,-6199 }, + { 67,-6199 }, { 68,-6199 }, { 69,-6199 }, { 70,-6199 }, { 71,-6199 }, + { 72,-6199 }, { 73,-6199 }, { 74,-6199 }, { 75,-6199 }, { 76,-6199 }, + + { 77,-6199 }, { 78,-6199 }, { 79,-6199 }, { 80,-6199 }, { 81,-6199 }, + { 82,-6199 }, { 83,-6199 }, { 84,-6199 }, { 85,-6199 }, { 86,-6199 }, + { 87,-6199 }, { 88,-6199 }, { 89,-6199 }, { 90,-6199 }, { 91,-6199 }, + { 92,-6199 }, { 93,-6199 }, { 94,-6199 }, { 95,-6199 }, { 96,-6199 }, + { 97,-6199 }, { 98,-6199 }, { 99,-6199 }, { 100,-6199 }, { 101,-6199 }, + { 102,-6199 }, { 103,-6199 }, { 104,-6199 }, { 105,-6199 }, { 106,-6199 }, + { 107,-6199 }, { 108,-6199 }, { 109,-6199 }, { 110,-6199 }, { 111,-6199 }, + { 112,-6199 }, { 113,-6199 }, { 114,-6199 }, { 115,-6199 }, { 116,-6199 }, + { 117,-6199 }, { 118,-6199 }, { 119,-6199 }, { 120,-6199 }, { 121,-6199 }, + { 122,-6199 }, { 123,-6199 }, { 124,-6199 }, { 125,-6199 }, { 126,-6199 }, + + { 127,-6199 }, { 128,-6199 }, { 129,-6199 }, { 130,-6199 }, { 131,-6199 }, + { 132,-6199 }, { 133,-6199 }, { 134,-6199 }, { 135,-6199 }, { 136,-6199 }, + { 137,-6199 }, { 138,-6199 }, { 139,-6199 }, { 140,-6199 }, { 141,-6199 }, + { 142,-6199 }, { 143,-6199 }, { 144,-6199 }, { 145,-6199 }, { 146,-6199 }, + { 147,-6199 }, { 148,-6199 }, { 149,-6199 }, { 150,-6199 }, { 151,-6199 }, + { 152,-6199 }, { 153,-6199 }, { 154,-6199 }, { 155,-6199 }, { 156,-6199 }, + { 157,-6199 }, { 158,-6199 }, { 159,-6199 }, { 160,-6199 }, { 161,-6199 }, + { 162,-6199 }, { 163,-6199 }, { 164,-6199 }, { 165,-6199 }, { 166,-6199 }, + { 167,-6199 }, { 168,-6199 }, { 169,-6199 }, { 170,-6199 }, { 171,-6199 }, + { 172,-6199 }, { 173,-6199 }, { 174,-6199 }, { 175,-6199 }, { 176,-6199 }, + + { 177,-6199 }, { 178,-6199 }, { 179,-6199 }, { 180,-6199 }, { 181,-6199 }, + { 182,-6199 }, { 183,-6199 }, { 184,-6199 }, { 185,-6199 }, { 186,-6199 }, + { 187,-6199 }, { 188,-6199 }, { 189,-6199 }, { 190,-6199 }, { 191,-6199 }, + { 192,-6199 }, { 193,-6199 }, { 194,-6199 }, { 195,-6199 }, { 196,-6199 }, + { 197,-6199 }, { 198,-6199 }, { 199,-6199 }, { 200,-6199 }, { 201,-6199 }, + { 202,-6199 }, { 203,-6199 }, { 204,-6199 }, { 205,-6199 }, { 206,-6199 }, + { 207,-6199 }, { 208,-6199 }, { 209,-6199 }, { 210,-6199 }, { 211,-6199 }, + { 212,-6199 }, { 213,-6199 }, { 214,-6199 }, { 215,-6199 }, { 216,-6199 }, + { 217,-6199 }, { 218,-6199 }, { 219,-6199 }, { 220,-6199 }, { 221,-6199 }, + { 222,-6199 }, { 223,-6199 }, { 224,-6199 }, { 225,-6199 }, { 226,-6199 }, + + { 227,-6199 }, { 228,-6199 }, { 229,-6199 }, { 230,-6199 }, { 231,-6199 }, + { 232,-6199 }, { 233,-6199 }, { 234,-6199 }, { 235,-6199 }, { 236,-6199 }, + { 237,-6199 }, { 238,-6199 }, { 239,-6199 }, { 240,-6199 }, { 241,-6199 }, + { 242,-6199 }, { 243,-6199 }, { 244,-6199 }, { 245,-6199 }, { 246,-6199 }, + { 247,-6199 }, { 248,-6199 }, { 249,-6199 }, { 250,-6199 }, { 251,-6199 }, + { 252,-6199 }, { 253,-6199 }, { 254,-6199 }, { 255,-6199 }, { 256,-6199 }, + { 0, 24 }, { 0,19099 }, { 1,-6457 }, { 2,-6457 }, { 3,-6457 }, + { 4,-6457 }, { 5,-6457 }, { 6,-6457 }, { 7,-6457 }, { 8,-6457 }, + { 9,-6199 }, { 10,-11232 }, { 11,-6457 }, { 12,-6199 }, { 13,-11232 }, + { 14,-6457 }, { 15,-6457 }, { 16,-6457 }, { 17,-6457 }, { 18,-6457 }, + + { 19,-6457 }, { 20,-6457 }, { 21,-6457 }, { 22,-6457 }, { 23,-6457 }, + { 24,-6457 }, { 25,-6457 }, { 26,-6457 }, { 27,-6457 }, { 28,-6457 }, + { 29,-6457 }, { 30,-6457 }, { 31,-6457 }, { 32,-6199 }, { 33,-6457 }, + { 34,-6457 }, { 35,-6457 }, { 36,-6457 }, { 37,-6457 }, { 38,-6457 }, + { 39,6358 }, { 40,-6457 }, { 41,-6457 }, { 42,-6457 }, { 43,-6457 }, + { 44,-6457 }, { 45,-5683 }, { 46,-6457 }, { 47,-6457 }, { 48,-6457 }, + { 49,-6457 }, { 50,-6457 }, { 51,-6457 }, { 52,-6457 }, { 53,-6457 }, + { 54,-6457 }, { 55,-6457 }, { 56,-6457 }, { 57,-6457 }, { 58,-6457 }, + { 59,-6457 }, { 60,-6457 }, { 61,-6457 }, { 62,-6457 }, { 63,-6457 }, + { 64,-6457 }, { 65,-6457 }, { 66,-6457 }, { 67,-6457 }, { 68,-6457 }, + + { 69,-6457 }, { 70,-6457 }, { 71,-6457 }, { 72,-6457 }, { 73,-6457 }, + { 74,-6457 }, { 75,-6457 }, { 76,-6457 }, { 77,-6457 }, { 78,-6457 }, + { 79,-6457 }, { 80,-6457 }, { 81,-6457 }, { 82,-6457 }, { 83,-6457 }, + { 84,-6457 }, { 85,-6457 }, { 86,-6457 }, { 87,-6457 }, { 88,-6457 }, + { 89,-6457 }, { 90,-6457 }, { 91,-6457 }, { 92,-6457 }, { 93,-6457 }, + { 94,-6457 }, { 95,-6457 }, { 96,-6457 }, { 97,-6457 }, { 98,-6457 }, + { 99,-6457 }, { 100,-6457 }, { 101,-6457 }, { 102,-6457 }, { 103,-6457 }, + { 104,-6457 }, { 105,-6457 }, { 106,-6457 }, { 107,-6457 }, { 108,-6457 }, + { 109,-6457 }, { 110,-6457 }, { 111,-6457 }, { 112,-6457 }, { 113,-6457 }, + { 114,-6457 }, { 115,-6457 }, { 116,-6457 }, { 117,-6457 }, { 118,-6457 }, + + { 119,-6457 }, { 120,-6457 }, { 121,-6457 }, { 122,-6457 }, { 123,-6457 }, + { 124,-6457 }, { 125,-6457 }, { 126,-6457 }, { 127,-6457 }, { 128,-6457 }, + { 129,-6457 }, { 130,-6457 }, { 131,-6457 }, { 132,-6457 }, { 133,-6457 }, + { 134,-6457 }, { 135,-6457 }, { 136,-6457 }, { 137,-6457 }, { 138,-6457 }, + { 139,-6457 }, { 140,-6457 }, { 141,-6457 }, { 142,-6457 }, { 143,-6457 }, + { 144,-6457 }, { 145,-6457 }, { 146,-6457 }, { 147,-6457 }, { 148,-6457 }, + { 149,-6457 }, { 150,-6457 }, { 151,-6457 }, { 152,-6457 }, { 153,-6457 }, + { 154,-6457 }, { 155,-6457 }, { 156,-6457 }, { 157,-6457 }, { 158,-6457 }, + { 159,-6457 }, { 160,-6457 }, { 161,-6457 }, { 162,-6457 }, { 163,-6457 }, + { 164,-6457 }, { 165,-6457 }, { 166,-6457 }, { 167,-6457 }, { 168,-6457 }, + + { 169,-6457 }, { 170,-6457 }, { 171,-6457 }, { 172,-6457 }, { 173,-6457 }, + { 174,-6457 }, { 175,-6457 }, { 176,-6457 }, { 177,-6457 }, { 178,-6457 }, + { 179,-6457 }, { 180,-6457 }, { 181,-6457 }, { 182,-6457 }, { 183,-6457 }, + { 184,-6457 }, { 185,-6457 }, { 186,-6457 }, { 187,-6457 }, { 188,-6457 }, + { 189,-6457 }, { 190,-6457 }, { 191,-6457 }, { 192,-6457 }, { 193,-6457 }, + { 194,-6457 }, { 195,-6457 }, { 196,-6457 }, { 197,-6457 }, { 198,-6457 }, + { 199,-6457 }, { 200,-6457 }, { 201,-6457 }, { 202,-6457 }, { 203,-6457 }, + { 204,-6457 }, { 205,-6457 }, { 206,-6457 }, { 207,-6457 }, { 208,-6457 }, + { 209,-6457 }, { 210,-6457 }, { 211,-6457 }, { 212,-6457 }, { 213,-6457 }, + { 214,-6457 }, { 215,-6457 }, { 216,-6457 }, { 217,-6457 }, { 218,-6457 }, + + { 219,-6457 }, { 220,-6457 }, { 221,-6457 }, { 222,-6457 }, { 223,-6457 }, + { 224,-6457 }, { 225,-6457 }, { 226,-6457 }, { 227,-6457 }, { 228,-6457 }, + { 229,-6457 }, { 230,-6457 }, { 231,-6457 }, { 232,-6457 }, { 233,-6457 }, + { 234,-6457 }, { 235,-6457 }, { 236,-6457 }, { 237,-6457 }, { 238,-6457 }, + { 239,-6457 }, { 240,-6457 }, { 241,-6457 }, { 242,-6457 }, { 243,-6457 }, + { 244,-6457 }, { 245,-6457 }, { 246,-6457 }, { 247,-6457 }, { 248,-6457 }, + { 249,-6457 }, { 250,-6457 }, { 251,-6457 }, { 252,-6457 }, { 253,-6457 }, + { 254,-6457 }, { 255,-6457 }, { 256,-6457 }, { 0, 24 }, { 0,18841 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 9,-11490 }, { 10,-11490 }, + + { 0, 0 }, { 12,-11490 }, { 13,-11490 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 32,-11490 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 39,6358 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 45,-34427 }, + { 0, 24 }, { 0,18794 }, { 1,-6762 }, { 2,-6762 }, { 3,-6762 }, + { 4,-6762 }, { 5,-6762 }, { 6,-6762 }, { 7,-6762 }, { 8,-6762 }, + { 9,-6504 }, { 10,-11537 }, { 11,-6762 }, { 12,-6504 }, { 13,-11537 }, + + { 14,-6762 }, { 15,-6762 }, { 16,-6762 }, { 17,-6762 }, { 18,-6762 }, + { 19,-6762 }, { 20,-6762 }, { 21,-6762 }, { 22,-6762 }, { 23,-6762 }, + { 24,-6762 }, { 25,-6762 }, { 26,-6762 }, { 27,-6762 }, { 28,-6762 }, + { 29,-6762 }, { 30,-6762 }, { 31,-6762 }, { 32,-6504 }, { 33,-6762 }, + { 34,-6762 }, { 35,-6762 }, { 36,-6762 }, { 37,-6762 }, { 38,-6762 }, + { 39,6053 }, { 40,-6762 }, { 41,-6762 }, { 42,-6762 }, { 43,-6762 }, + { 44,-6762 }, { 45, 258 }, { 46,-6762 }, { 47,-6762 }, { 48,-6762 }, + { 49,-6762 }, { 50,-6762 }, { 51,-6762 }, { 52,-6762 }, { 53,-6762 }, + { 54,-6762 }, { 55,-6762 }, { 56,-6762 }, { 57,-6762 }, { 58,-6762 }, + { 59,-6762 }, { 60,-6762 }, { 61,-6762 }, { 62,-6762 }, { 63,-6762 }, + + { 64,-6762 }, { 65,-6762 }, { 66,-6762 }, { 67,-6762 }, { 68,-6762 }, + { 69,-6762 }, { 70,-6762 }, { 71,-6762 }, { 72,-6762 }, { 73,-6762 }, + { 74,-6762 }, { 75,-6762 }, { 76,-6762 }, { 77,-6762 }, { 78,-6762 }, + { 79,-6762 }, { 80,-6762 }, { 81,-6762 }, { 82,-6762 }, { 83,-6762 }, + { 84,-6762 }, { 85,-6762 }, { 86,-6762 }, { 87,-6762 }, { 88,-6762 }, + { 89,-6762 }, { 90,-6762 }, { 91,-6762 }, { 92,-6762 }, { 93,-6762 }, + { 94,-6762 }, { 95,-6762 }, { 96,-6762 }, { 97,-6762 }, { 98,-6762 }, + { 99,-6762 }, { 100,-6762 }, { 101,-6762 }, { 102,-6762 }, { 103,-6762 }, + { 104,-6762 }, { 105,-6762 }, { 106,-6762 }, { 107,-6762 }, { 108,-6762 }, + { 109,-6762 }, { 110,-6762 }, { 111,-6762 }, { 112,-6762 }, { 113,-6762 }, + + { 114,-6762 }, { 115,-6762 }, { 116,-6762 }, { 117,-6762 }, { 118,-6762 }, + { 119,-6762 }, { 120,-6762 }, { 121,-6762 }, { 122,-6762 }, { 123,-6762 }, + { 124,-6762 }, { 125,-6762 }, { 126,-6762 }, { 127,-6762 }, { 128,-6762 }, + { 129,-6762 }, { 130,-6762 }, { 131,-6762 }, { 132,-6762 }, { 133,-6762 }, + { 134,-6762 }, { 135,-6762 }, { 136,-6762 }, { 137,-6762 }, { 138,-6762 }, + { 139,-6762 }, { 140,-6762 }, { 141,-6762 }, { 142,-6762 }, { 143,-6762 }, + { 144,-6762 }, { 145,-6762 }, { 146,-6762 }, { 147,-6762 }, { 148,-6762 }, + { 149,-6762 }, { 150,-6762 }, { 151,-6762 }, { 152,-6762 }, { 153,-6762 }, + { 154,-6762 }, { 155,-6762 }, { 156,-6762 }, { 157,-6762 }, { 158,-6762 }, + { 159,-6762 }, { 160,-6762 }, { 161,-6762 }, { 162,-6762 }, { 163,-6762 }, + + { 164,-6762 }, { 165,-6762 }, { 166,-6762 }, { 167,-6762 }, { 168,-6762 }, + { 169,-6762 }, { 170,-6762 }, { 171,-6762 }, { 172,-6762 }, { 173,-6762 }, + { 174,-6762 }, { 175,-6762 }, { 176,-6762 }, { 177,-6762 }, { 178,-6762 }, + { 179,-6762 }, { 180,-6762 }, { 181,-6762 }, { 182,-6762 }, { 183,-6762 }, + { 184,-6762 }, { 185,-6762 }, { 186,-6762 }, { 187,-6762 }, { 188,-6762 }, + { 189,-6762 }, { 190,-6762 }, { 191,-6762 }, { 192,-6762 }, { 193,-6762 }, + { 194,-6762 }, { 195,-6762 }, { 196,-6762 }, { 197,-6762 }, { 198,-6762 }, + { 199,-6762 }, { 200,-6762 }, { 201,-6762 }, { 202,-6762 }, { 203,-6762 }, + { 204,-6762 }, { 205,-6762 }, { 206,-6762 }, { 207,-6762 }, { 208,-6762 }, + { 209,-6762 }, { 210,-6762 }, { 211,-6762 }, { 212,-6762 }, { 213,-6762 }, + + { 214,-6762 }, { 215,-6762 }, { 216,-6762 }, { 217,-6762 }, { 218,-6762 }, + { 219,-6762 }, { 220,-6762 }, { 221,-6762 }, { 222,-6762 }, { 223,-6762 }, + { 224,-6762 }, { 225,-6762 }, { 226,-6762 }, { 227,-6762 }, { 228,-6762 }, + { 229,-6762 }, { 230,-6762 }, { 231,-6762 }, { 232,-6762 }, { 233,-6762 }, + { 234,-6762 }, { 235,-6762 }, { 236,-6762 }, { 237,-6762 }, { 238,-6762 }, + { 239,-6762 }, { 240,-6762 }, { 241,-6762 }, { 242,-6762 }, { 243,-6762 }, + { 244,-6762 }, { 245,-6762 }, { 246,-6762 }, { 247,-6762 }, { 248,-6762 }, + { 249,-6762 }, { 250,-6762 }, { 251,-6762 }, { 252,-6762 }, { 253,-6762 }, + { 254,-6762 }, { 255,-6762 }, { 256,-6762 }, { 0, 24 }, { 0,18536 }, + { 1,-7020 }, { 2,-7020 }, { 3,-7020 }, { 4,-7020 }, { 5,-7020 }, + + { 6,-7020 }, { 7,-7020 }, { 8,-7020 }, { 9,-6762 }, { 10,-11795 }, + { 11,-7020 }, { 12,-6762 }, { 13,-11795 }, { 14,-7020 }, { 15,-7020 }, + { 16,-7020 }, { 17,-7020 }, { 18,-7020 }, { 19,-7020 }, { 20,-7020 }, + { 21,-7020 }, { 22,-7020 }, { 23,-7020 }, { 24,-7020 }, { 25,-7020 }, + { 26,-7020 }, { 27,-7020 }, { 28,-7020 }, { 29,-7020 }, { 30,-7020 }, + { 31,-7020 }, { 32,-6762 }, { 33,-7020 }, { 34,-7020 }, { 35,-7020 }, + { 36,-7020 }, { 37,-7020 }, { 38,-7020 }, { 39,-6504 }, { 40,-7020 }, + { 41,-7020 }, { 42,-7020 }, { 43,-7020 }, { 44,-7020 }, { 45, 0 }, + { 46,-7020 }, { 47,-7020 }, { 48,-7020 }, { 49,-7020 }, { 50,-7020 }, + { 51,-7020 }, { 52,-7020 }, { 53,-7020 }, { 54,-7020 }, { 55,-7020 }, + + { 56,-7020 }, { 57,-7020 }, { 58,-7020 }, { 59,-7020 }, { 60,-7020 }, + { 61,-7020 }, { 62,-7020 }, { 63,-7020 }, { 64,-7020 }, { 65,-7020 }, + { 66,-7020 }, { 67,-7020 }, { 68,-7020 }, { 69,-7020 }, { 70,-7020 }, + { 71,-7020 }, { 72,-7020 }, { 73,-7020 }, { 74,-7020 }, { 75,-7020 }, + { 76,-7020 }, { 77,-7020 }, { 78,-7020 }, { 79,-7020 }, { 80,-7020 }, + { 81,-7020 }, { 82,-7020 }, { 83,-7020 }, { 84,-7020 }, { 85,-7020 }, + { 86,-7020 }, { 87,-7020 }, { 88,-7020 }, { 89,-7020 }, { 90,-7020 }, + { 91,-7020 }, { 92,-7020 }, { 93,-7020 }, { 94,-7020 }, { 95,-7020 }, + { 96,-7020 }, { 97,-7020 }, { 98,-7020 }, { 99,-7020 }, { 100,-7020 }, + { 101,-7020 }, { 102,-7020 }, { 103,-7020 }, { 104,-7020 }, { 105,-7020 }, + + { 106,-7020 }, { 107,-7020 }, { 108,-7020 }, { 109,-7020 }, { 110,-7020 }, + { 111,-7020 }, { 112,-7020 }, { 113,-7020 }, { 114,-7020 }, { 115,-7020 }, + { 116,-7020 }, { 117,-7020 }, { 118,-7020 }, { 119,-7020 }, { 120,-7020 }, + { 121,-7020 }, { 122,-7020 }, { 123,-7020 }, { 124,-7020 }, { 125,-7020 }, + { 126,-7020 }, { 127,-7020 }, { 128,-7020 }, { 129,-7020 }, { 130,-7020 }, + { 131,-7020 }, { 132,-7020 }, { 133,-7020 }, { 134,-7020 }, { 135,-7020 }, + { 136,-7020 }, { 137,-7020 }, { 138,-7020 }, { 139,-7020 }, { 140,-7020 }, + { 141,-7020 }, { 142,-7020 }, { 143,-7020 }, { 144,-7020 }, { 145,-7020 }, + { 146,-7020 }, { 147,-7020 }, { 148,-7020 }, { 149,-7020 }, { 150,-7020 }, + { 151,-7020 }, { 152,-7020 }, { 153,-7020 }, { 154,-7020 }, { 155,-7020 }, + + { 156,-7020 }, { 157,-7020 }, { 158,-7020 }, { 159,-7020 }, { 160,-7020 }, + { 161,-7020 }, { 162,-7020 }, { 163,-7020 }, { 164,-7020 }, { 165,-7020 }, + { 166,-7020 }, { 167,-7020 }, { 168,-7020 }, { 169,-7020 }, { 170,-7020 }, + { 171,-7020 }, { 172,-7020 }, { 173,-7020 }, { 174,-7020 }, { 175,-7020 }, + { 176,-7020 }, { 177,-7020 }, { 178,-7020 }, { 179,-7020 }, { 180,-7020 }, + { 181,-7020 }, { 182,-7020 }, { 183,-7020 }, { 184,-7020 }, { 185,-7020 }, + { 186,-7020 }, { 187,-7020 }, { 188,-7020 }, { 189,-7020 }, { 190,-7020 }, + { 191,-7020 }, { 192,-7020 }, { 193,-7020 }, { 194,-7020 }, { 195,-7020 }, + { 196,-7020 }, { 197,-7020 }, { 198,-7020 }, { 199,-7020 }, { 200,-7020 }, + { 201,-7020 }, { 202,-7020 }, { 203,-7020 }, { 204,-7020 }, { 205,-7020 }, + + { 206,-7020 }, { 207,-7020 }, { 208,-7020 }, { 209,-7020 }, { 210,-7020 }, + { 211,-7020 }, { 212,-7020 }, { 213,-7020 }, { 214,-7020 }, { 215,-7020 }, + { 216,-7020 }, { 217,-7020 }, { 218,-7020 }, { 219,-7020 }, { 220,-7020 }, + { 221,-7020 }, { 222,-7020 }, { 223,-7020 }, { 224,-7020 }, { 225,-7020 }, + { 226,-7020 }, { 227,-7020 }, { 228,-7020 }, { 229,-7020 }, { 230,-7020 }, + { 231,-7020 }, { 232,-7020 }, { 233,-7020 }, { 234,-7020 }, { 235,-7020 }, + { 236,-7020 }, { 237,-7020 }, { 238,-7020 }, { 239,-7020 }, { 240,-7020 }, + { 241,-7020 }, { 242,-7020 }, { 243,-7020 }, { 244,-7020 }, { 245,-7020 }, + { 246,-7020 }, { 247,-7020 }, { 248,-7020 }, { 249,-7020 }, { 250,-7020 }, + { 251,-7020 }, { 252,-7020 }, { 253,-7020 }, { 254,-7020 }, { 255,-7020 }, + + { 256,-7020 }, { 0, 48 }, { 0,18278 }, { 1, 516 }, { 2, 516 }, + { 3, 516 }, { 4, 516 }, { 5, 516 }, { 6, 516 }, { 7, 516 }, + { 8, 516 }, { 9, 774 }, { 10,-10096 }, { 11, 516 }, { 12, 774 }, + { 13,-10096 }, { 14, 516 }, { 15, 516 }, { 16, 516 }, { 17, 516 }, + { 18, 516 }, { 19, 516 }, { 20, 516 }, { 21, 516 }, { 22, 516 }, + { 23, 516 }, { 24, 516 }, { 25, 516 }, { 26, 516 }, { 27, 516 }, + { 28, 516 }, { 29, 516 }, { 30, 516 }, { 31, 516 }, { 32, 774 }, + { 33, 516 }, { 34, 516 }, { 35, 516 }, { 36, 516 }, { 37, 516 }, + { 38, 516 }, { 39,1032 }, { 40, 516 }, { 41, 516 }, { 42, 516 }, + { 43, 516 }, { 44, 516 }, { 45,6053 }, { 46, 516 }, { 47, 516 }, + + { 48, 516 }, { 49, 516 }, { 50, 516 }, { 51, 516 }, { 52, 516 }, + { 53, 516 }, { 54, 516 }, { 55, 516 }, { 56, 516 }, { 57, 516 }, + { 58, 516 }, { 59, 516 }, { 60, 516 }, { 61, 516 }, { 62, 516 }, + { 63, 516 }, { 64, 516 }, { 65, 516 }, { 66, 516 }, { 67, 516 }, + { 68, 516 }, { 69, 516 }, { 70, 516 }, { 71, 516 }, { 72, 516 }, + { 73, 516 }, { 74, 516 }, { 75, 516 }, { 76, 516 }, { 77, 516 }, + { 78, 516 }, { 79, 516 }, { 80, 516 }, { 81, 516 }, { 82, 516 }, + { 83, 516 }, { 84, 516 }, { 85,1548 }, { 86, 516 }, { 87, 516 }, + { 88, 516 }, { 89, 516 }, { 90, 516 }, { 91, 516 }, { 92, 516 }, + { 93, 516 }, { 94, 516 }, { 95, 516 }, { 96, 516 }, { 97, 516 }, + + { 98, 516 }, { 99, 516 }, { 100, 516 }, { 101, 516 }, { 102, 516 }, + { 103, 516 }, { 104, 516 }, { 105, 516 }, { 106, 516 }, { 107, 516 }, + { 108, 516 }, { 109, 516 }, { 110, 516 }, { 111, 516 }, { 112, 516 }, + { 113, 516 }, { 114, 516 }, { 115, 516 }, { 116, 516 }, { 117,1548 }, + { 118, 516 }, { 119, 516 }, { 120, 516 }, { 121, 516 }, { 122, 516 }, + { 123, 516 }, { 124, 516 }, { 125, 516 }, { 126, 516 }, { 127, 516 }, + { 128, 516 }, { 129, 516 }, { 130, 516 }, { 131, 516 }, { 132, 516 }, + { 133, 516 }, { 134, 516 }, { 135, 516 }, { 136, 516 }, { 137, 516 }, + { 138, 516 }, { 139, 516 }, { 140, 516 }, { 141, 516 }, { 142, 516 }, + { 143, 516 }, { 144, 516 }, { 145, 516 }, { 146, 516 }, { 147, 516 }, + + { 148, 516 }, { 149, 516 }, { 150, 516 }, { 151, 516 }, { 152, 516 }, + { 153, 516 }, { 154, 516 }, { 155, 516 }, { 156, 516 }, { 157, 516 }, + { 158, 516 }, { 159, 516 }, { 160, 516 }, { 161, 516 }, { 162, 516 }, + { 163, 516 }, { 164, 516 }, { 165, 516 }, { 166, 516 }, { 167, 516 }, + { 168, 516 }, { 169, 516 }, { 170, 516 }, { 171, 516 }, { 172, 516 }, + { 173, 516 }, { 174, 516 }, { 175, 516 }, { 176, 516 }, { 177, 516 }, + { 178, 516 }, { 179, 516 }, { 180, 516 }, { 181, 516 }, { 182, 516 }, + { 183, 516 }, { 184, 516 }, { 185, 516 }, { 186, 516 }, { 187, 516 }, + { 188, 516 }, { 189, 516 }, { 190, 516 }, { 191, 516 }, { 192, 516 }, + { 193, 516 }, { 194, 516 }, { 195, 516 }, { 196, 516 }, { 197, 516 }, + + { 198, 516 }, { 199, 516 }, { 200, 516 }, { 201, 516 }, { 202, 516 }, + { 203, 516 }, { 204, 516 }, { 205, 516 }, { 206, 516 }, { 207, 516 }, + { 208, 516 }, { 209, 516 }, { 210, 516 }, { 211, 516 }, { 212, 516 }, + { 213, 516 }, { 214, 516 }, { 215, 516 }, { 216, 516 }, { 217, 516 }, + { 218, 516 }, { 219, 516 }, { 220, 516 }, { 221, 516 }, { 222, 516 }, + { 223, 516 }, { 224, 516 }, { 225, 516 }, { 226, 516 }, { 227, 516 }, + { 228, 516 }, { 229, 516 }, { 230, 516 }, { 231, 516 }, { 232, 516 }, + { 233, 516 }, { 234, 516 }, { 235, 516 }, { 236, 516 }, { 237, 516 }, + { 238, 516 }, { 239, 516 }, { 240, 516 }, { 241, 516 }, { 242, 516 }, + { 243, 516 }, { 244, 516 }, { 245, 516 }, { 246, 516 }, { 247, 516 }, + + { 248, 516 }, { 249, 516 }, { 250, 516 }, { 251, 516 }, { 252, 516 }, + { 253, 516 }, { 254, 516 }, { 255, 516 }, { 256, 516 }, { 0, 48 }, + { 0,18020 }, { 1,-25401 }, { 2,-25401 }, { 3,-25401 }, { 4,-25401 }, + { 5,-25401 }, { 6,-25401 }, { 7,-25401 }, { 8,-25401 }, { 9,-25143 }, + { 10,-31787 }, { 11,-25401 }, { 12,-25143 }, { 13,-31787 }, { 14,-25401 }, + { 15,-25401 }, { 16,-25401 }, { 17,-25401 }, { 18,-25401 }, { 19,-25401 }, + { 20,-25401 }, { 21,-25401 }, { 22,-25401 }, { 23,-25401 }, { 24,-25401 }, + { 25,-25401 }, { 26,-25401 }, { 27,-25401 }, { 28,-25401 }, { 29,-25401 }, + { 30,-25401 }, { 31,-25401 }, { 32,-25143 }, { 33,-25401 }, { 34,-25401 }, + { 35,-25401 }, { 36,-25401 }, { 37,-25401 }, { 38,-25401 }, { 39,-25401 }, + + { 40,-25401 }, { 41,-25401 }, { 42,-25401 }, { 43,-25401 }, { 44,-25401 }, + { 45,-24885 }, { 46,-25401 }, { 47,-25401 }, { 48,-25401 }, { 49,-25401 }, + { 50,-25401 }, { 51,-25401 }, { 52,-25401 }, { 53,-25401 }, { 54,-25401 }, + { 55,-25401 }, { 56,-25401 }, { 57,-25401 }, { 58,-25401 }, { 59,-25401 }, + { 60,-25401 }, { 61,-25401 }, { 62,-25401 }, { 63,-25401 }, { 64,-25401 }, + { 65,-25401 }, { 66,-25401 }, { 67,-25401 }, { 68,-25401 }, { 69,-25401 }, + { 70,-25401 }, { 71,-25401 }, { 72,-25401 }, { 73,-25401 }, { 74,-25401 }, + { 75,-25401 }, { 76,-25401 }, { 77,-25401 }, { 78,-25401 }, { 79,-25401 }, + { 80,-25401 }, { 81,-25401 }, { 82,-25401 }, { 83,-25401 }, { 84,-25401 }, + { 85,-24627 }, { 86,-25401 }, { 87,-25401 }, { 88,-25401 }, { 89,-25401 }, + + { 90,-25401 }, { 91,-25401 }, { 92,-25401 }, { 93,-25401 }, { 94,-25401 }, + { 95,-25401 }, { 96,-25401 }, { 97,-25401 }, { 98,-25401 }, { 99,-25401 }, + { 100,-25401 }, { 101,-25401 }, { 102,-25401 }, { 103,-25401 }, { 104,-25401 }, + { 105,-25401 }, { 106,-25401 }, { 107,-25401 }, { 108,-25401 }, { 109,-25401 }, + { 110,-25401 }, { 111,-25401 }, { 112,-25401 }, { 113,-25401 }, { 114,-25401 }, + { 115,-25401 }, { 116,-25401 }, { 117,-24627 }, { 118,-25401 }, { 119,-25401 }, + { 120,-25401 }, { 121,-25401 }, { 122,-25401 }, { 123,-25401 }, { 124,-25401 }, + { 125,-25401 }, { 126,-25401 }, { 127,-25401 }, { 128,-25401 }, { 129,-25401 }, + { 130,-25401 }, { 131,-25401 }, { 132,-25401 }, { 133,-25401 }, { 134,-25401 }, + { 135,-25401 }, { 136,-25401 }, { 137,-25401 }, { 138,-25401 }, { 139,-25401 }, + + { 140,-25401 }, { 141,-25401 }, { 142,-25401 }, { 143,-25401 }, { 144,-25401 }, + { 145,-25401 }, { 146,-25401 }, { 147,-25401 }, { 148,-25401 }, { 149,-25401 }, + { 150,-25401 }, { 151,-25401 }, { 152,-25401 }, { 153,-25401 }, { 154,-25401 }, + { 155,-25401 }, { 156,-25401 }, { 157,-25401 }, { 158,-25401 }, { 159,-25401 }, + { 160,-25401 }, { 161,-25401 }, { 162,-25401 }, { 163,-25401 }, { 164,-25401 }, + { 165,-25401 }, { 166,-25401 }, { 167,-25401 }, { 168,-25401 }, { 169,-25401 }, + { 170,-25401 }, { 171,-25401 }, { 172,-25401 }, { 173,-25401 }, { 174,-25401 }, + { 175,-25401 }, { 176,-25401 }, { 177,-25401 }, { 178,-25401 }, { 179,-25401 }, + { 180,-25401 }, { 181,-25401 }, { 182,-25401 }, { 183,-25401 }, { 184,-25401 }, + { 185,-25401 }, { 186,-25401 }, { 187,-25401 }, { 188,-25401 }, { 189,-25401 }, + + { 190,-25401 }, { 191,-25401 }, { 192,-25401 }, { 193,-25401 }, { 194,-25401 }, + { 195,-25401 }, { 196,-25401 }, { 197,-25401 }, { 198,-25401 }, { 199,-25401 }, + { 200,-25401 }, { 201,-25401 }, { 202,-25401 }, { 203,-25401 }, { 204,-25401 }, + { 205,-25401 }, { 206,-25401 }, { 207,-25401 }, { 208,-25401 }, { 209,-25401 }, + { 210,-25401 }, { 211,-25401 }, { 212,-25401 }, { 213,-25401 }, { 214,-25401 }, + { 215,-25401 }, { 216,-25401 }, { 217,-25401 }, { 218,-25401 }, { 219,-25401 }, + { 220,-25401 }, { 221,-25401 }, { 222,-25401 }, { 223,-25401 }, { 224,-25401 }, + { 225,-25401 }, { 226,-25401 }, { 227,-25401 }, { 228,-25401 }, { 229,-25401 }, + { 230,-25401 }, { 231,-25401 }, { 232,-25401 }, { 233,-25401 }, { 234,-25401 }, + { 235,-25401 }, { 236,-25401 }, { 237,-25401 }, { 238,-25401 }, { 239,-25401 }, + + { 240,-25401 }, { 241,-25401 }, { 242,-25401 }, { 243,-25401 }, { 244,-25401 }, + { 245,-25401 }, { 246,-25401 }, { 247,-25401 }, { 248,-25401 }, { 249,-25401 }, + { 250,-25401 }, { 251,-25401 }, { 252,-25401 }, { 253,-25401 }, { 254,-25401 }, + { 255,-25401 }, { 256,-25401 }, { 0, 48 }, { 0,17762 }, { 1, 0 }, + { 2, 0 }, { 3, 0 }, { 4, 0 }, { 5, 0 }, { 6, 0 }, + { 7, 0 }, { 8, 0 }, { 9, 258 }, { 10,-10612 }, { 11, 0 }, + { 12, 258 }, { 13,-10612 }, { 14, 0 }, { 15, 0 }, { 16, 0 }, + { 17, 0 }, { 18, 0 }, { 19, 0 }, { 20, 0 }, { 21, 0 }, + { 22, 0 }, { 23, 0 }, { 24, 0 }, { 25, 0 }, { 26, 0 }, + { 27, 0 }, { 28, 0 }, { 29, 0 }, { 30, 0 }, { 31, 0 }, + + { 32, 258 }, { 33, 0 }, { 34, 0 }, { 35, 0 }, { 36, 0 }, + { 37, 0 }, { 38, 0 }, { 39, 516 }, { 40, 0 }, { 41, 0 }, + { 42, 0 }, { 43, 0 }, { 44, 0 }, { 45,5537 }, { 46, 0 }, + { 47, 0 }, { 48, 0 }, { 49, 0 }, { 50, 0 }, { 51, 0 }, + { 52, 0 }, { 53, 0 }, { 54, 0 }, { 55, 0 }, { 56, 0 }, + { 57, 0 }, { 58, 0 }, { 59, 0 }, { 60, 0 }, { 61, 0 }, + { 62, 0 }, { 63, 0 }, { 64, 0 }, { 65, 0 }, { 66, 0 }, + { 67, 0 }, { 68, 0 }, { 69, 0 }, { 70, 0 }, { 71, 0 }, + { 72, 0 }, { 73, 0 }, { 74, 0 }, { 75, 0 }, { 76, 0 }, + { 77, 0 }, { 78, 0 }, { 79, 0 }, { 80, 0 }, { 81, 0 }, + + { 82, 0 }, { 83, 0 }, { 84, 0 }, { 85,1032 }, { 86, 0 }, + { 87, 0 }, { 88, 0 }, { 89, 0 }, { 90, 0 }, { 91, 0 }, + { 92, 0 }, { 93, 0 }, { 94, 0 }, { 95, 0 }, { 96, 0 }, + { 97, 0 }, { 98, 0 }, { 99, 0 }, { 100, 0 }, { 101, 0 }, + { 102, 0 }, { 103, 0 }, { 104, 0 }, { 105, 0 }, { 106, 0 }, + { 107, 0 }, { 108, 0 }, { 109, 0 }, { 110, 0 }, { 111, 0 }, + { 112, 0 }, { 113, 0 }, { 114, 0 }, { 115, 0 }, { 116, 0 }, + { 117,1032 }, { 118, 0 }, { 119, 0 }, { 120, 0 }, { 121, 0 }, + { 122, 0 }, { 123, 0 }, { 124, 0 }, { 125, 0 }, { 126, 0 }, + { 127, 0 }, { 128, 0 }, { 129, 0 }, { 130, 0 }, { 131, 0 }, + + { 132, 0 }, { 133, 0 }, { 134, 0 }, { 135, 0 }, { 136, 0 }, + { 137, 0 }, { 138, 0 }, { 139, 0 }, { 140, 0 }, { 141, 0 }, + { 142, 0 }, { 143, 0 }, { 144, 0 }, { 145, 0 }, { 146, 0 }, + { 147, 0 }, { 148, 0 }, { 149, 0 }, { 150, 0 }, { 151, 0 }, + { 152, 0 }, { 153, 0 }, { 154, 0 }, { 155, 0 }, { 156, 0 }, + { 157, 0 }, { 158, 0 }, { 159, 0 }, { 160, 0 }, { 161, 0 }, + { 162, 0 }, { 163, 0 }, { 164, 0 }, { 165, 0 }, { 166, 0 }, + { 167, 0 }, { 168, 0 }, { 169, 0 }, { 170, 0 }, { 171, 0 }, + { 172, 0 }, { 173, 0 }, { 174, 0 }, { 175, 0 }, { 176, 0 }, + { 177, 0 }, { 178, 0 }, { 179, 0 }, { 180, 0 }, { 181, 0 }, + + { 182, 0 }, { 183, 0 }, { 184, 0 }, { 185, 0 }, { 186, 0 }, + { 187, 0 }, { 188, 0 }, { 189, 0 }, { 190, 0 }, { 191, 0 }, + { 192, 0 }, { 193, 0 }, { 194, 0 }, { 195, 0 }, { 196, 0 }, + { 197, 0 }, { 198, 0 }, { 199, 0 }, { 200, 0 }, { 201, 0 }, + { 202, 0 }, { 203, 0 }, { 204, 0 }, { 205, 0 }, { 206, 0 }, + { 207, 0 }, { 208, 0 }, { 209, 0 }, { 210, 0 }, { 211, 0 }, + { 212, 0 }, { 213, 0 }, { 214, 0 }, { 215, 0 }, { 216, 0 }, + { 217, 0 }, { 218, 0 }, { 219, 0 }, { 220, 0 }, { 221, 0 }, + { 222, 0 }, { 223, 0 }, { 224, 0 }, { 225, 0 }, { 226, 0 }, + { 227, 0 }, { 228, 0 }, { 229, 0 }, { 230, 0 }, { 231, 0 }, + + { 232, 0 }, { 233, 0 }, { 234, 0 }, { 235, 0 }, { 236, 0 }, + { 237, 0 }, { 238, 0 }, { 239, 0 }, { 240, 0 }, { 241, 0 }, + { 242, 0 }, { 243, 0 }, { 244, 0 }, { 245, 0 }, { 246, 0 }, + { 247, 0 }, { 248, 0 }, { 249, 0 }, { 250, 0 }, { 251, 0 }, + { 252, 0 }, { 253, 0 }, { 254, 0 }, { 255, 0 }, { 256, 0 }, + { 0, 48 }, { 0,17504 }, { 1,-258 }, { 2,-258 }, { 3,-258 }, + { 4,-258 }, { 5,-258 }, { 6,-258 }, { 7,-258 }, { 8,-258 }, + { 9, 0 }, { 10,-10870 }, { 11,-258 }, { 12, 0 }, { 13,-10870 }, + { 14,-258 }, { 15,-258 }, { 16,-258 }, { 17,-258 }, { 18,-258 }, + { 19,-258 }, { 20,-258 }, { 21,-258 }, { 22,-258 }, { 23,-258 }, + + { 24,-258 }, { 25,-258 }, { 26,-258 }, { 27,-258 }, { 28,-258 }, + { 29,-258 }, { 30,-258 }, { 31,-258 }, { 32, 0 }, { 33,-258 }, + { 34,-258 }, { 35,-258 }, { 36,-258 }, { 37,-258 }, { 38,-258 }, + { 39, 258 }, { 40,-258 }, { 41,-258 }, { 42,-258 }, { 43,-258 }, + { 44,-258 }, { 45,5279 }, { 46,-258 }, { 47,-258 }, { 48,-258 }, + { 49,-258 }, { 50,-258 }, { 51,-258 }, { 52,-258 }, { 53,-258 }, + { 54,-258 }, { 55,-258 }, { 56,-258 }, { 57,-258 }, { 58,-258 }, + { 59,-258 }, { 60,-258 }, { 61,-258 }, { 62,-258 }, { 63,-258 }, + { 64,-258 }, { 65,-258 }, { 66,-258 }, { 67,-258 }, { 68,-258 }, + { 69,-258 }, { 70,-258 }, { 71,-258 }, { 72,-258 }, { 73,-258 }, + + { 74,-258 }, { 75,-258 }, { 76,-258 }, { 77,-258 }, { 78,-258 }, + { 79,-258 }, { 80,-258 }, { 81,-258 }, { 82,-258 }, { 83,-258 }, + { 84,-258 }, { 85, 774 }, { 86,-258 }, { 87,-258 }, { 88,-258 }, + { 89,-258 }, { 90,-258 }, { 91,-258 }, { 92,-258 }, { 93,-258 }, + { 94,-258 }, { 95,-258 }, { 96,-258 }, { 97,-258 }, { 98,-258 }, + { 99,-258 }, { 100,-258 }, { 101,-258 }, { 102,-258 }, { 103,-258 }, + { 104,-258 }, { 105,-258 }, { 106,-258 }, { 107,-258 }, { 108,-258 }, + { 109,-258 }, { 110,-258 }, { 111,-258 }, { 112,-258 }, { 113,-258 }, + { 114,-258 }, { 115,-258 }, { 116,-258 }, { 117, 774 }, { 118,-258 }, + { 119,-258 }, { 120,-258 }, { 121,-258 }, { 122,-258 }, { 123,-258 }, + + { 124,-258 }, { 125,-258 }, { 126,-258 }, { 127,-258 }, { 128,-258 }, + { 129,-258 }, { 130,-258 }, { 131,-258 }, { 132,-258 }, { 133,-258 }, + { 134,-258 }, { 135,-258 }, { 136,-258 }, { 137,-258 }, { 138,-258 }, + { 139,-258 }, { 140,-258 }, { 141,-258 }, { 142,-258 }, { 143,-258 }, + { 144,-258 }, { 145,-258 }, { 146,-258 }, { 147,-258 }, { 148,-258 }, + { 149,-258 }, { 150,-258 }, { 151,-258 }, { 152,-258 }, { 153,-258 }, + { 154,-258 }, { 155,-258 }, { 156,-258 }, { 157,-258 }, { 158,-258 }, + { 159,-258 }, { 160,-258 }, { 161,-258 }, { 162,-258 }, { 163,-258 }, + { 164,-258 }, { 165,-258 }, { 166,-258 }, { 167,-258 }, { 168,-258 }, + { 169,-258 }, { 170,-258 }, { 171,-258 }, { 172,-258 }, { 173,-258 }, + + { 174,-258 }, { 175,-258 }, { 176,-258 }, { 177,-258 }, { 178,-258 }, + { 179,-258 }, { 180,-258 }, { 181,-258 }, { 182,-258 }, { 183,-258 }, + { 184,-258 }, { 185,-258 }, { 186,-258 }, { 187,-258 }, { 188,-258 }, + { 189,-258 }, { 190,-258 }, { 191,-258 }, { 192,-258 }, { 193,-258 }, + { 194,-258 }, { 195,-258 }, { 196,-258 }, { 197,-258 }, { 198,-258 }, + { 199,-258 }, { 200,-258 }, { 201,-258 }, { 202,-258 }, { 203,-258 }, + { 204,-258 }, { 205,-258 }, { 206,-258 }, { 207,-258 }, { 208,-258 }, + { 209,-258 }, { 210,-258 }, { 211,-258 }, { 212,-258 }, { 213,-258 }, + { 214,-258 }, { 215,-258 }, { 216,-258 }, { 217,-258 }, { 218,-258 }, + { 219,-258 }, { 220,-258 }, { 221,-258 }, { 222,-258 }, { 223,-258 }, + + { 224,-258 }, { 225,-258 }, { 226,-258 }, { 227,-258 }, { 228,-258 }, + { 229,-258 }, { 230,-258 }, { 231,-258 }, { 232,-258 }, { 233,-258 }, + { 234,-258 }, { 235,-258 }, { 236,-258 }, { 237,-258 }, { 238,-258 }, + { 239,-258 }, { 240,-258 }, { 241,-258 }, { 242,-258 }, { 243,-258 }, + { 244,-258 }, { 245,-258 }, { 246,-258 }, { 247,-258 }, { 248,-258 }, + { 249,-258 }, { 250,-258 }, { 251,-258 }, { 252,-258 }, { 253,-258 }, + { 254,-258 }, { 255,-258 }, { 256,-258 }, { 0, 48 }, { 0,17246 }, + { 1,5279 }, { 2,5279 }, { 3,5279 }, { 4,5279 }, { 5,5279 }, + { 6,5279 }, { 7,5279 }, { 8,5279 }, { 9,5537 }, { 10,5795 }, + { 11,5279 }, { 12,5537 }, { 13,5795 }, { 14,5279 }, { 15,5279 }, + + { 16,5279 }, { 17,5279 }, { 18,5279 }, { 19,5279 }, { 20,5279 }, + { 21,5279 }, { 22,5279 }, { 23,5279 }, { 24,5279 }, { 25,5279 }, + { 26,5279 }, { 27,5279 }, { 28,5279 }, { 29,5279 }, { 30,5279 }, + { 31,5279 }, { 32,5537 }, { 33,5279 }, { 34,5279 }, { 35,5279 }, + { 36,5279 }, { 37,5279 }, { 38,5279 }, { 39, 0 }, { 40,5279 }, + { 41,5279 }, { 42,5279 }, { 43,5279 }, { 44,5279 }, { 45,5914 }, + { 46,5279 }, { 47,5279 }, { 48,5279 }, { 49,5279 }, { 50,5279 }, + { 51,5279 }, { 52,5279 }, { 53,5279 }, { 54,5279 }, { 55,5279 }, + { 56,5279 }, { 57,5279 }, { 58,5279 }, { 59,5279 }, { 60,5279 }, + { 61,5279 }, { 62,5279 }, { 63,5279 }, { 64,5279 }, { 65,5279 }, + + { 66,5279 }, { 67,5279 }, { 68,5279 }, { 69,5279 }, { 70,5279 }, + { 71,5279 }, { 72,5279 }, { 73,5279 }, { 74,5279 }, { 75,5279 }, + { 76,5279 }, { 77,5279 }, { 78,5279 }, { 79,5279 }, { 80,5279 }, + { 81,5279 }, { 82,5279 }, { 83,5279 }, { 84,5279 }, { 85,6172 }, + { 86,5279 }, { 87,5279 }, { 88,5279 }, { 89,5279 }, { 90,5279 }, + { 91,5279 }, { 92,5279 }, { 93,5279 }, { 94,5279 }, { 95,5279 }, + { 96,5279 }, { 97,5279 }, { 98,5279 }, { 99,5279 }, { 100,5279 }, + { 101,5279 }, { 102,5279 }, { 103,5279 }, { 104,5279 }, { 105,5279 }, + { 106,5279 }, { 107,5279 }, { 108,5279 }, { 109,5279 }, { 110,5279 }, + { 111,5279 }, { 112,5279 }, { 113,5279 }, { 114,5279 }, { 115,5279 }, + + { 116,5279 }, { 117,6172 }, { 118,5279 }, { 119,5279 }, { 120,5279 }, + { 121,5279 }, { 122,5279 }, { 123,5279 }, { 124,5279 }, { 125,5279 }, + { 126,5279 }, { 127,5279 }, { 128,5279 }, { 129,5279 }, { 130,5279 }, + { 131,5279 }, { 132,5279 }, { 133,5279 }, { 134,5279 }, { 135,5279 }, + { 136,5279 }, { 137,5279 }, { 138,5279 }, { 139,5279 }, { 140,5279 }, + { 141,5279 }, { 142,5279 }, { 143,5279 }, { 144,5279 }, { 145,5279 }, + { 146,5279 }, { 147,5279 }, { 148,5279 }, { 149,5279 }, { 150,5279 }, + { 151,5279 }, { 152,5279 }, { 153,5279 }, { 154,5279 }, { 155,5279 }, + { 156,5279 }, { 157,5279 }, { 158,5279 }, { 159,5279 }, { 160,5279 }, + { 161,5279 }, { 162,5279 }, { 163,5279 }, { 164,5279 }, { 165,5279 }, + + { 166,5279 }, { 167,5279 }, { 168,5279 }, { 169,5279 }, { 170,5279 }, + { 171,5279 }, { 172,5279 }, { 173,5279 }, { 174,5279 }, { 175,5279 }, + { 176,5279 }, { 177,5279 }, { 178,5279 }, { 179,5279 }, { 180,5279 }, + { 181,5279 }, { 182,5279 }, { 183,5279 }, { 184,5279 }, { 185,5279 }, + { 186,5279 }, { 187,5279 }, { 188,5279 }, { 189,5279 }, { 190,5279 }, + { 191,5279 }, { 192,5279 }, { 193,5279 }, { 194,5279 }, { 195,5279 }, + { 196,5279 }, { 197,5279 }, { 198,5279 }, { 199,5279 }, { 200,5279 }, + { 201,5279 }, { 202,5279 }, { 203,5279 }, { 204,5279 }, { 205,5279 }, + { 206,5279 }, { 207,5279 }, { 208,5279 }, { 209,5279 }, { 210,5279 }, + { 211,5279 }, { 212,5279 }, { 213,5279 }, { 214,5279 }, { 215,5279 }, + + { 216,5279 }, { 217,5279 }, { 218,5279 }, { 219,5279 }, { 220,5279 }, + { 221,5279 }, { 222,5279 }, { 223,5279 }, { 224,5279 }, { 225,5279 }, + { 226,5279 }, { 227,5279 }, { 228,5279 }, { 229,5279 }, { 230,5279 }, + { 231,5279 }, { 232,5279 }, { 233,5279 }, { 234,5279 }, { 235,5279 }, + { 236,5279 }, { 237,5279 }, { 238,5279 }, { 239,5279 }, { 240,5279 }, + { 241,5279 }, { 242,5279 }, { 243,5279 }, { 244,5279 }, { 245,5279 }, + { 246,5279 }, { 247,5279 }, { 248,5279 }, { 249,5279 }, { 250,5279 }, + { 251,5279 }, { 252,5279 }, { 253,5279 }, { 254,5279 }, { 255,5279 }, + { 256,5279 }, { 0, 48 }, { 0,16988 }, { 1,-774 }, { 2,-774 }, + { 3,-774 }, { 4,-774 }, { 5,-774 }, { 6,-774 }, { 7,-774 }, + + { 8,-774 }, { 9,-516 }, { 10,-11386 }, { 11,-774 }, { 12,-516 }, + { 13,-11386 }, { 14,-774 }, { 15,-774 }, { 16,-774 }, { 17,-774 }, + { 18,-774 }, { 19,-774 }, { 20,-774 }, { 21,-774 }, { 22,-774 }, + { 23,-774 }, { 24,-774 }, { 25,-774 }, { 26,-774 }, { 27,-774 }, + { 28,-774 }, { 29,-774 }, { 30,-774 }, { 31,-774 }, { 32,-516 }, + { 33,-774 }, { 34,-774 }, { 35,-774 }, { 36,-774 }, { 37,-774 }, + { 38,-774 }, { 39,-258 }, { 40,-774 }, { 41,-774 }, { 42,-774 }, + { 43,-774 }, { 44,-774 }, { 45,6172 }, { 46,-774 }, { 47,-774 }, + { 48,-774 }, { 49,-774 }, { 50,-774 }, { 51,-774 }, { 52,-774 }, + { 53,-774 }, { 54,-774 }, { 55,-774 }, { 56,-774 }, { 57,-774 }, + + { 58,-774 }, { 59,-774 }, { 60,-774 }, { 61,-774 }, { 62,-774 }, + { 63,-774 }, { 64,-774 }, { 65,-774 }, { 66,-774 }, { 67,-774 }, + { 68,-774 }, { 69,-774 }, { 70,-774 }, { 71,-774 }, { 72,-774 }, + { 73,-774 }, { 74,-774 }, { 75,-774 }, { 76,-774 }, { 77,-774 }, + { 78,-774 }, { 79,-774 }, { 80,-774 }, { 81,-774 }, { 82,-774 }, + { 83,-774 }, { 84,-774 }, { 85, 258 }, { 86,-774 }, { 87,-774 }, + { 88,-774 }, { 89,-774 }, { 90,-774 }, { 91,-774 }, { 92,-774 }, + { 93,-774 }, { 94,-774 }, { 95,-774 }, { 96,-774 }, { 97,-774 }, + { 98,-774 }, { 99,-774 }, { 100,-774 }, { 101,-774 }, { 102,-774 }, + { 103,-774 }, { 104,-774 }, { 105,-774 }, { 106,-774 }, { 107,-774 }, + + { 108,-774 }, { 109,-774 }, { 110,-774 }, { 111,-774 }, { 112,-774 }, + { 113,-774 }, { 114,-774 }, { 115,-774 }, { 116,-774 }, { 117, 258 }, + { 118,-774 }, { 119,-774 }, { 120,-774 }, { 121,-774 }, { 122,-774 }, + { 123,-774 }, { 124,-774 }, { 125,-774 }, { 126,-774 }, { 127,-774 }, + { 128,-774 }, { 129,-774 }, { 130,-774 }, { 131,-774 }, { 132,-774 }, + { 133,-774 }, { 134,-774 }, { 135,-774 }, { 136,-774 }, { 137,-774 }, + { 138,-774 }, { 139,-774 }, { 140,-774 }, { 141,-774 }, { 142,-774 }, + { 143,-774 }, { 144,-774 }, { 145,-774 }, { 146,-774 }, { 147,-774 }, + { 148,-774 }, { 149,-774 }, { 150,-774 }, { 151,-774 }, { 152,-774 }, + { 153,-774 }, { 154,-774 }, { 155,-774 }, { 156,-774 }, { 157,-774 }, + + { 158,-774 }, { 159,-774 }, { 160,-774 }, { 161,-774 }, { 162,-774 }, + { 163,-774 }, { 164,-774 }, { 165,-774 }, { 166,-774 }, { 167,-774 }, + { 168,-774 }, { 169,-774 }, { 170,-774 }, { 171,-774 }, { 172,-774 }, + { 173,-774 }, { 174,-774 }, { 175,-774 }, { 176,-774 }, { 177,-774 }, + { 178,-774 }, { 179,-774 }, { 180,-774 }, { 181,-774 }, { 182,-774 }, + { 183,-774 }, { 184,-774 }, { 185,-774 }, { 186,-774 }, { 187,-774 }, + { 188,-774 }, { 189,-774 }, { 190,-774 }, { 191,-774 }, { 192,-774 }, + { 193,-774 }, { 194,-774 }, { 195,-774 }, { 196,-774 }, { 197,-774 }, + { 198,-774 }, { 199,-774 }, { 200,-774 }, { 201,-774 }, { 202,-774 }, + { 203,-774 }, { 204,-774 }, { 205,-774 }, { 206,-774 }, { 207,-774 }, + + { 208,-774 }, { 209,-774 }, { 210,-774 }, { 211,-774 }, { 212,-774 }, + { 213,-774 }, { 214,-774 }, { 215,-774 }, { 216,-774 }, { 217,-774 }, + { 218,-774 }, { 219,-774 }, { 220,-774 }, { 221,-774 }, { 222,-774 }, + { 223,-774 }, { 224,-774 }, { 225,-774 }, { 226,-774 }, { 227,-774 }, + { 228,-774 }, { 229,-774 }, { 230,-774 }, { 231,-774 }, { 232,-774 }, + { 233,-774 }, { 234,-774 }, { 235,-774 }, { 236,-774 }, { 237,-774 }, + { 238,-774 }, { 239,-774 }, { 240,-774 }, { 241,-774 }, { 242,-774 }, + { 243,-774 }, { 244,-774 }, { 245,-774 }, { 246,-774 }, { 247,-774 }, + { 248,-774 }, { 249,-774 }, { 250,-774 }, { 251,-774 }, { 252,-774 }, + { 253,-774 }, { 254,-774 }, { 255,-774 }, { 256,-774 }, { 0, 48 }, + + { 0,16730 }, { 1,-1032 }, { 2,-1032 }, { 3,-1032 }, { 4,-1032 }, + { 5,-1032 }, { 6,-1032 }, { 7,-1032 }, { 8,-1032 }, { 9,-774 }, + { 10,-11644 }, { 11,-1032 }, { 12,-774 }, { 13,-11644 }, { 14,-1032 }, + { 15,-1032 }, { 16,-1032 }, { 17,-1032 }, { 18,-1032 }, { 19,-1032 }, + { 20,-1032 }, { 21,-1032 }, { 22,-1032 }, { 23,-1032 }, { 24,-1032 }, + { 25,-1032 }, { 26,-1032 }, { 27,-1032 }, { 28,-1032 }, { 29,-1032 }, + { 30,-1032 }, { 31,-1032 }, { 32,-774 }, { 33,-1032 }, { 34,-1032 }, + { 35,-1032 }, { 36,-1032 }, { 37,-1032 }, { 38,-1032 }, { 39,-516 }, + { 40,-1032 }, { 41,-1032 }, { 42,-1032 }, { 43,-1032 }, { 44,-1032 }, + { 45,4505 }, { 46,-1032 }, { 47,-1032 }, { 48,-1032 }, { 49,-1032 }, + + { 50,-1032 }, { 51,-1032 }, { 52,-1032 }, { 53,-1032 }, { 54,-1032 }, + { 55,-1032 }, { 56,-1032 }, { 57,-1032 }, { 58,-1032 }, { 59,-1032 }, + { 60,-1032 }, { 61,-1032 }, { 62,-1032 }, { 63,-1032 }, { 64,-1032 }, + { 65,-1032 }, { 66,-1032 }, { 67,-1032 }, { 68,-1032 }, { 69,6172 }, + { 70,-1032 }, { 71,-1032 }, { 72,-1032 }, { 73,-1032 }, { 74,-1032 }, + { 75,-1032 }, { 76,-1032 }, { 77,-1032 }, { 78,-1032 }, { 79,-1032 }, + { 80,-1032 }, { 81,-1032 }, { 82,-1032 }, { 83,-1032 }, { 84,-1032 }, + { 85, 0 }, { 86,-1032 }, { 87,-1032 }, { 88,-1032 }, { 89,-1032 }, + { 90,-1032 }, { 91,-1032 }, { 92,-1032 }, { 93,-1032 }, { 94,-1032 }, + { 95,-1032 }, { 96,-1032 }, { 97,-1032 }, { 98,-1032 }, { 99,-1032 }, + + { 100,-1032 }, { 101,6172 }, { 102,-1032 }, { 103,-1032 }, { 104,-1032 }, + { 105,-1032 }, { 106,-1032 }, { 107,-1032 }, { 108,-1032 }, { 109,-1032 }, + { 110,-1032 }, { 111,-1032 }, { 112,-1032 }, { 113,-1032 }, { 114,-1032 }, + { 115,-1032 }, { 116,-1032 }, { 117, 0 }, { 118,-1032 }, { 119,-1032 }, + { 120,-1032 }, { 121,-1032 }, { 122,-1032 }, { 123,-1032 }, { 124,-1032 }, + { 125,-1032 }, { 126,-1032 }, { 127,-1032 }, { 128,-1032 }, { 129,-1032 }, + { 130,-1032 }, { 131,-1032 }, { 132,-1032 }, { 133,-1032 }, { 134,-1032 }, + { 135,-1032 }, { 136,-1032 }, { 137,-1032 }, { 138,-1032 }, { 139,-1032 }, + { 140,-1032 }, { 141,-1032 }, { 142,-1032 }, { 143,-1032 }, { 144,-1032 }, + { 145,-1032 }, { 146,-1032 }, { 147,-1032 }, { 148,-1032 }, { 149,-1032 }, + + { 150,-1032 }, { 151,-1032 }, { 152,-1032 }, { 153,-1032 }, { 154,-1032 }, + { 155,-1032 }, { 156,-1032 }, { 157,-1032 }, { 158,-1032 }, { 159,-1032 }, + { 160,-1032 }, { 161,-1032 }, { 162,-1032 }, { 163,-1032 }, { 164,-1032 }, + { 165,-1032 }, { 166,-1032 }, { 167,-1032 }, { 168,-1032 }, { 169,-1032 }, + { 170,-1032 }, { 171,-1032 }, { 172,-1032 }, { 173,-1032 }, { 174,-1032 }, + { 175,-1032 }, { 176,-1032 }, { 177,-1032 }, { 178,-1032 }, { 179,-1032 }, + { 180,-1032 }, { 181,-1032 }, { 182,-1032 }, { 183,-1032 }, { 184,-1032 }, + { 185,-1032 }, { 186,-1032 }, { 187,-1032 }, { 188,-1032 }, { 189,-1032 }, + { 190,-1032 }, { 191,-1032 }, { 192,-1032 }, { 193,-1032 }, { 194,-1032 }, + { 195,-1032 }, { 196,-1032 }, { 197,-1032 }, { 198,-1032 }, { 199,-1032 }, + + { 200,-1032 }, { 201,-1032 }, { 202,-1032 }, { 203,-1032 }, { 204,-1032 }, + { 205,-1032 }, { 206,-1032 }, { 207,-1032 }, { 208,-1032 }, { 209,-1032 }, + { 210,-1032 }, { 211,-1032 }, { 212,-1032 }, { 213,-1032 }, { 214,-1032 }, + { 215,-1032 }, { 216,-1032 }, { 217,-1032 }, { 218,-1032 }, { 219,-1032 }, + { 220,-1032 }, { 221,-1032 }, { 222,-1032 }, { 223,-1032 }, { 224,-1032 }, + { 225,-1032 }, { 226,-1032 }, { 227,-1032 }, { 228,-1032 }, { 229,-1032 }, + { 230,-1032 }, { 231,-1032 }, { 232,-1032 }, { 233,-1032 }, { 234,-1032 }, + { 235,-1032 }, { 236,-1032 }, { 237,-1032 }, { 238,-1032 }, { 239,-1032 }, + { 240,-1032 }, { 241,-1032 }, { 242,-1032 }, { 243,-1032 }, { 244,-1032 }, + { 245,-1032 }, { 246,-1032 }, { 247,-1032 }, { 248,-1032 }, { 249,-1032 }, + + { 250,-1032 }, { 251,-1032 }, { 252,-1032 }, { 253,-1032 }, { 254,-1032 }, + { 255,-1032 }, { 256,-1032 }, { 0, 48 }, { 0,16472 }, { 1,-6643 }, + { 2,-6643 }, { 3,-6643 }, { 4,-6643 }, { 5,-6643 }, { 6,-6643 }, + { 7,-6643 }, { 8,-6643 }, { 9,-6385 }, { 10,-6127 }, { 11,-6643 }, + { 12,-6385 }, { 13,-6127 }, { 14,-6643 }, { 15,-6643 }, { 16,-6643 }, + { 17,-6643 }, { 18,-6643 }, { 19,-6643 }, { 20,-6643 }, { 21,-6643 }, + { 22,-6643 }, { 23,-6643 }, { 24,-6643 }, { 25,-6643 }, { 26,-6643 }, + { 27,-6643 }, { 28,-6643 }, { 29,-6643 }, { 30,-6643 }, { 31,-6643 }, + { 32,-6385 }, { 33,-6643 }, { 34,-6643 }, { 35,-6643 }, { 36,-6643 }, + { 37,-6643 }, { 38,-6643 }, { 39,-10751 }, { 40,-6643 }, { 41,-6643 }, + + { 42,-6643 }, { 43,-6643 }, { 44,-6643 }, { 45,-6080 }, { 46,-6643 }, + { 47,-6643 }, { 48,-6643 }, { 49,-6643 }, { 50,-6643 }, { 51,-6643 }, + { 52,-6643 }, { 53,-6643 }, { 54,-6643 }, { 55,-6643 }, { 56,-6643 }, + { 57,-6643 }, { 58,-6643 }, { 59,-6643 }, { 60,-6643 }, { 61,-6643 }, + { 62,-6643 }, { 63,-6643 }, { 64,-6643 }, { 65,-6643 }, { 66,-6643 }, + { 67,-6643 }, { 68,-6643 }, { 69,-6643 }, { 70,-6643 }, { 71,-6643 }, + { 72,-6643 }, { 73,-6643 }, { 74,-6643 }, { 75,-6643 }, { 76,-6643 }, + { 77,-6643 }, { 78,-6643 }, { 79,-6643 }, { 80,-6643 }, { 81,-6643 }, + { 82,-6643 }, { 83,-6643 }, { 84,-6643 }, { 85,-6643 }, { 86,-6643 }, + { 87,-6643 }, { 88,-6643 }, { 89,-6643 }, { 90,-6643 }, { 91,-6643 }, + + { 92,-6643 }, { 93,-6643 }, { 94,-6643 }, { 95,-6643 }, { 96,-6643 }, + { 97,-6643 }, { 98,-6643 }, { 99,-6643 }, { 100,-6643 }, { 101,-6643 }, + { 102,-6643 }, { 103,-6643 }, { 104,-6643 }, { 105,-6643 }, { 106,-6643 }, + { 107,-6643 }, { 108,-6643 }, { 109,-6643 }, { 110,-6643 }, { 111,-6643 }, + { 112,-6643 }, { 113,-6643 }, { 114,-6643 }, { 115,-6643 }, { 116,-6643 }, + { 117,-6643 }, { 118,-6643 }, { 119,-6643 }, { 120,-6643 }, { 121,-6643 }, + { 122,-6643 }, { 123,-6643 }, { 124,-6643 }, { 125,-6643 }, { 126,-6643 }, + { 127,-6643 }, { 128,-6643 }, { 129,-6643 }, { 130,-6643 }, { 131,-6643 }, + { 132,-6643 }, { 133,-6643 }, { 134,-6643 }, { 135,-6643 }, { 136,-6643 }, + { 137,-6643 }, { 138,-6643 }, { 139,-6643 }, { 140,-6643 }, { 141,-6643 }, + + { 142,-6643 }, { 143,-6643 }, { 144,-6643 }, { 145,-6643 }, { 146,-6643 }, + { 147,-6643 }, { 148,-6643 }, { 149,-6643 }, { 150,-6643 }, { 151,-6643 }, + { 152,-6643 }, { 153,-6643 }, { 154,-6643 }, { 155,-6643 }, { 156,-6643 }, + { 157,-6643 }, { 158,-6643 }, { 159,-6643 }, { 160,-6643 }, { 161,-6643 }, + { 162,-6643 }, { 163,-6643 }, { 164,-6643 }, { 165,-6643 }, { 166,-6643 }, + { 167,-6643 }, { 168,-6643 }, { 169,-6643 }, { 170,-6643 }, { 171,-6643 }, + { 172,-6643 }, { 173,-6643 }, { 174,-6643 }, { 175,-6643 }, { 176,-6643 }, + { 177,-6643 }, { 178,-6643 }, { 179,-6643 }, { 180,-6643 }, { 181,-6643 }, + { 182,-6643 }, { 183,-6643 }, { 184,-6643 }, { 185,-6643 }, { 186,-6643 }, + { 187,-6643 }, { 188,-6643 }, { 189,-6643 }, { 190,-6643 }, { 191,-6643 }, + + { 192,-6643 }, { 193,-6643 }, { 194,-6643 }, { 195,-6643 }, { 196,-6643 }, + { 197,-6643 }, { 198,-6643 }, { 199,-6643 }, { 200,-6643 }, { 201,-6643 }, + { 202,-6643 }, { 203,-6643 }, { 204,-6643 }, { 205,-6643 }, { 206,-6643 }, + { 207,-6643 }, { 208,-6643 }, { 209,-6643 }, { 210,-6643 }, { 211,-6643 }, + { 212,-6643 }, { 213,-6643 }, { 214,-6643 }, { 215,-6643 }, { 216,-6643 }, + { 217,-6643 }, { 218,-6643 }, { 219,-6643 }, { 220,-6643 }, { 221,-6643 }, + { 222,-6643 }, { 223,-6643 }, { 224,-6643 }, { 225,-6643 }, { 226,-6643 }, + { 227,-6643 }, { 228,-6643 }, { 229,-6643 }, { 230,-6643 }, { 231,-6643 }, + { 232,-6643 }, { 233,-6643 }, { 234,-6643 }, { 235,-6643 }, { 236,-6643 }, + { 237,-6643 }, { 238,-6643 }, { 239,-6643 }, { 240,-6643 }, { 241,-6643 }, + + { 242,-6643 }, { 243,-6643 }, { 244,-6643 }, { 245,-6643 }, { 246,-6643 }, + { 247,-6643 }, { 248,-6643 }, { 249,-6643 }, { 250,-6643 }, { 251,-6643 }, + { 252,-6643 }, { 253,-6643 }, { 254,-6643 }, { 255,-6643 }, { 256,-6643 }, + { 0, 48 }, { 0,16214 }, { 1,-37047 }, { 2,-37047 }, { 3,-37047 }, + { 4,-37047 }, { 5,-37047 }, { 6,-37047 }, { 7,-37047 }, { 8,-37047 }, + { 9,-37047 }, { 10,-37047 }, { 11,-37047 }, { 12,-37047 }, { 13,-37047 }, + { 14,-37047 }, { 15,-37047 }, { 16,-37047 }, { 17,-37047 }, { 18,-37047 }, + { 19,-37047 }, { 20,-37047 }, { 21,-37047 }, { 22,-37047 }, { 23,-37047 }, + { 24,-37047 }, { 25,-37047 }, { 26,-37047 }, { 27,-37047 }, { 28,-37047 }, + { 29,-37047 }, { 30,-37047 }, { 31,-37047 }, { 32,-37047 }, { 33,-37047 }, + + { 34,-37047 }, { 35,-37047 }, { 36,-37047 }, { 37,-37047 }, { 38,-37047 }, + { 0, 0 }, { 40,-37047 }, { 41,-37047 }, { 42,-37047 }, { 43,-37047 }, + { 44,-37047 }, { 45,-37047 }, { 46,-37047 }, { 47,-37047 }, { 48,-37047 }, + { 49,-37047 }, { 50,-37047 }, { 51,-37047 }, { 52,-37047 }, { 53,-37047 }, + { 54,-37047 }, { 55,-37047 }, { 56,-37047 }, { 57,-37047 }, { 58,-37047 }, + { 59,-37047 }, { 60,-37047 }, { 61,-37047 }, { 62,-37047 }, { 63,-37047 }, + { 64,-37047 }, { 65,-37047 }, { 66,-37047 }, { 67,-37047 }, { 68,-37047 }, + { 69,-37047 }, { 70,-37047 }, { 71,-37047 }, { 72,-37047 }, { 73,-37047 }, + { 74,-37047 }, { 75,-37047 }, { 76,-37047 }, { 77,-37047 }, { 78,-37047 }, + { 79,-37047 }, { 80,-37047 }, { 81,-37047 }, { 82,-37047 }, { 83,-37047 }, + + { 84,-37047 }, { 85,-37047 }, { 86,-37047 }, { 87,-37047 }, { 88,-37047 }, + { 89,-37047 }, { 90,-37047 }, { 91,-37047 }, { 92,-37047 }, { 93,-37047 }, + { 94,-37047 }, { 95,-37047 }, { 96,-37047 }, { 97,-37047 }, { 98,-37047 }, + { 99,-37047 }, { 100,-37047 }, { 101,-37047 }, { 102,-37047 }, { 103,-37047 }, + { 104,-37047 }, { 105,-37047 }, { 106,-37047 }, { 107,-37047 }, { 108,-37047 }, + { 109,-37047 }, { 110,-37047 }, { 111,-37047 }, { 112,-37047 }, { 113,-37047 }, + { 114,-37047 }, { 115,-37047 }, { 116,-37047 }, { 117,-37047 }, { 118,-37047 }, + { 119,-37047 }, { 120,-37047 }, { 121,-37047 }, { 122,-37047 }, { 123,-37047 }, + { 124,-37047 }, { 125,-37047 }, { 126,-37047 }, { 127,-37047 }, { 128,-37047 }, + { 129,-37047 }, { 130,-37047 }, { 131,-37047 }, { 132,-37047 }, { 133,-37047 }, + + { 134,-37047 }, { 135,-37047 }, { 136,-37047 }, { 137,-37047 }, { 138,-37047 }, + { 139,-37047 }, { 140,-37047 }, { 141,-37047 }, { 142,-37047 }, { 143,-37047 }, + { 144,-37047 }, { 145,-37047 }, { 146,-37047 }, { 147,-37047 }, { 148,-37047 }, + { 149,-37047 }, { 150,-37047 }, { 151,-37047 }, { 152,-37047 }, { 153,-37047 }, + { 154,-37047 }, { 155,-37047 }, { 156,-37047 }, { 157,-37047 }, { 158,-37047 }, + { 159,-37047 }, { 160,-37047 }, { 161,-37047 }, { 162,-37047 }, { 163,-37047 }, + { 164,-37047 }, { 165,-37047 }, { 166,-37047 }, { 167,-37047 }, { 168,-37047 }, + { 169,-37047 }, { 170,-37047 }, { 171,-37047 }, { 172,-37047 }, { 173,-37047 }, + { 174,-37047 }, { 175,-37047 }, { 176,-37047 }, { 177,-37047 }, { 178,-37047 }, + { 179,-37047 }, { 180,-37047 }, { 181,-37047 }, { 182,-37047 }, { 183,-37047 }, + + { 184,-37047 }, { 185,-37047 }, { 186,-37047 }, { 187,-37047 }, { 188,-37047 }, + { 189,-37047 }, { 190,-37047 }, { 191,-37047 }, { 192,-37047 }, { 193,-37047 }, + { 194,-37047 }, { 195,-37047 }, { 196,-37047 }, { 197,-37047 }, { 198,-37047 }, + { 199,-37047 }, { 200,-37047 }, { 201,-37047 }, { 202,-37047 }, { 203,-37047 }, + { 204,-37047 }, { 205,-37047 }, { 206,-37047 }, { 207,-37047 }, { 208,-37047 }, + { 209,-37047 }, { 210,-37047 }, { 211,-37047 }, { 212,-37047 }, { 213,-37047 }, + { 214,-37047 }, { 215,-37047 }, { 216,-37047 }, { 217,-37047 }, { 218,-37047 }, + { 219,-37047 }, { 220,-37047 }, { 221,-37047 }, { 222,-37047 }, { 223,-37047 }, + { 224,-37047 }, { 225,-37047 }, { 226,-37047 }, { 227,-37047 }, { 228,-37047 }, + { 229,-37047 }, { 230,-37047 }, { 231,-37047 }, { 232,-37047 }, { 233,-37047 }, + + { 234,-37047 }, { 235,-37047 }, { 236,-37047 }, { 237,-37047 }, { 238,-37047 }, + { 239,-37047 }, { 240,-37047 }, { 241,-37047 }, { 242,-37047 }, { 243,-37047 }, + { 244,-37047 }, { 245,-37047 }, { 246,-37047 }, { 247,-37047 }, { 248,-37047 }, + { 249,-37047 }, { 250,-37047 }, { 251,-37047 }, { 252,-37047 }, { 253,-37047 }, + { 254,-37047 }, { 255,-37047 }, { 256,-37047 }, { 0, 24 }, { 0,15956 }, + { 1,-21136 }, { 2,-21136 }, { 3,-21136 }, { 4,-21136 }, { 5,-21136 }, + { 6,-21136 }, { 7,-21136 }, { 8,-21136 }, { 9,-20878 }, { 10,-20620 }, + { 11,-21136 }, { 12,-20878 }, { 13,-20620 }, { 14,-21136 }, { 15,-21136 }, + { 16,-21136 }, { 17,-21136 }, { 18,-21136 }, { 19,-21136 }, { 20,-21136 }, + { 21,-21136 }, { 22,-21136 }, { 23,-21136 }, { 24,-21136 }, { 25,-21136 }, + + { 26,-21136 }, { 27,-21136 }, { 28,-21136 }, { 29,-21136 }, { 30,-21136 }, + { 31,-21136 }, { 32,-20878 }, { 33,-21136 }, { 34,-21136 }, { 35,-21136 }, + { 36,-21136 }, { 37,-21136 }, { 38,-21136 }, { 39,5656 }, { 40,-21136 }, + { 41,-21136 }, { 42,-21136 }, { 43,-21136 }, { 44,-21136 }, { 45,-20501 }, + { 46,-21136 }, { 47,-21136 }, { 48,-21136 }, { 49,-21136 }, { 50,-21136 }, + { 51,-21136 }, { 52,-21136 }, { 53,-21136 }, { 54,-21136 }, { 55,-21136 }, + { 56,-21136 }, { 57,-21136 }, { 58,-21136 }, { 59,-21136 }, { 60,-21136 }, + { 61,-21136 }, { 62,-21136 }, { 63,-21136 }, { 64,-21136 }, { 65,-21136 }, + { 66,-21136 }, { 67,-21136 }, { 68,-21136 }, { 69,-21136 }, { 70,-21136 }, + { 71,-21136 }, { 72,-21136 }, { 73,-21136 }, { 74,-21136 }, { 75,-21136 }, + + { 76,-21136 }, { 77,-21136 }, { 78,-21136 }, { 79,-21136 }, { 80,-21136 }, + { 81,-21136 }, { 82,-21136 }, { 83,-21136 }, { 84,-21136 }, { 85,-20243 }, + { 86,-21136 }, { 87,-21136 }, { 88,-21136 }, { 89,-21136 }, { 90,-21136 }, + { 91,-21136 }, { 92,-21136 }, { 93,-21136 }, { 94,-21136 }, { 95,-21136 }, + { 96,-21136 }, { 97,-21136 }, { 98,-21136 }, { 99,-21136 }, { 100,-21136 }, + { 101,-21136 }, { 102,-21136 }, { 103,-21136 }, { 104,-21136 }, { 105,-21136 }, + { 106,-21136 }, { 107,-21136 }, { 108,-21136 }, { 109,-21136 }, { 110,-21136 }, + { 111,-21136 }, { 112,-21136 }, { 113,-21136 }, { 114,-21136 }, { 115,-21136 }, + { 116,-21136 }, { 117,-20243 }, { 118,-21136 }, { 119,-21136 }, { 120,-21136 }, + { 121,-21136 }, { 122,-21136 }, { 123,-21136 }, { 124,-21136 }, { 125,-21136 }, + + { 126,-21136 }, { 127,-21136 }, { 128,-21136 }, { 129,-21136 }, { 130,-21136 }, + { 131,-21136 }, { 132,-21136 }, { 133,-21136 }, { 134,-21136 }, { 135,-21136 }, + { 136,-21136 }, { 137,-21136 }, { 138,-21136 }, { 139,-21136 }, { 140,-21136 }, + { 141,-21136 }, { 142,-21136 }, { 143,-21136 }, { 144,-21136 }, { 145,-21136 }, + { 146,-21136 }, { 147,-21136 }, { 148,-21136 }, { 149,-21136 }, { 150,-21136 }, + { 151,-21136 }, { 152,-21136 }, { 153,-21136 }, { 154,-21136 }, { 155,-21136 }, + { 156,-21136 }, { 157,-21136 }, { 158,-21136 }, { 159,-21136 }, { 160,-21136 }, + { 161,-21136 }, { 162,-21136 }, { 163,-21136 }, { 164,-21136 }, { 165,-21136 }, + { 166,-21136 }, { 167,-21136 }, { 168,-21136 }, { 169,-21136 }, { 170,-21136 }, + { 171,-21136 }, { 172,-21136 }, { 173,-21136 }, { 174,-21136 }, { 175,-21136 }, + + { 176,-21136 }, { 177,-21136 }, { 178,-21136 }, { 179,-21136 }, { 180,-21136 }, + { 181,-21136 }, { 182,-21136 }, { 183,-21136 }, { 184,-21136 }, { 185,-21136 }, + { 186,-21136 }, { 187,-21136 }, { 188,-21136 }, { 189,-21136 }, { 190,-21136 }, + { 191,-21136 }, { 192,-21136 }, { 193,-21136 }, { 194,-21136 }, { 195,-21136 }, + { 196,-21136 }, { 197,-21136 }, { 198,-21136 }, { 199,-21136 }, { 200,-21136 }, + { 201,-21136 }, { 202,-21136 }, { 203,-21136 }, { 204,-21136 }, { 205,-21136 }, + { 206,-21136 }, { 207,-21136 }, { 208,-21136 }, { 209,-21136 }, { 210,-21136 }, + { 211,-21136 }, { 212,-21136 }, { 213,-21136 }, { 214,-21136 }, { 215,-21136 }, + { 216,-21136 }, { 217,-21136 }, { 218,-21136 }, { 219,-21136 }, { 220,-21136 }, + { 221,-21136 }, { 222,-21136 }, { 223,-21136 }, { 224,-21136 }, { 225,-21136 }, + + { 226,-21136 }, { 227,-21136 }, { 228,-21136 }, { 229,-21136 }, { 230,-21136 }, + { 231,-21136 }, { 232,-21136 }, { 233,-21136 }, { 234,-21136 }, { 235,-21136 }, + { 236,-21136 }, { 237,-21136 }, { 238,-21136 }, { 239,-21136 }, { 240,-21136 }, + { 241,-21136 }, { 242,-21136 }, { 243,-21136 }, { 244,-21136 }, { 245,-21136 }, + { 246,-21136 }, { 247,-21136 }, { 248,-21136 }, { 249,-21136 }, { 250,-21136 }, + { 251,-21136 }, { 252,-21136 }, { 253,-21136 }, { 254,-21136 }, { 255,-21136 }, + { 256,-21136 }, { 0, 24 }, { 0,15698 }, { 1,-21394 }, { 2,-21394 }, + { 3,-21394 }, { 4,-21394 }, { 5,-21394 }, { 6,-21394 }, { 7,-21394 }, + { 8,-21394 }, { 9,-21136 }, { 10,-20878 }, { 11,-21394 }, { 12,-21136 }, + { 13,-20878 }, { 14,-21394 }, { 15,-21394 }, { 16,-21394 }, { 17,-21394 }, + + { 18,-21394 }, { 19,-21394 }, { 20,-21394 }, { 21,-21394 }, { 22,-21394 }, + { 23,-21394 }, { 24,-21394 }, { 25,-21394 }, { 26,-21394 }, { 27,-21394 }, + { 28,-21394 }, { 29,-21394 }, { 30,-21394 }, { 31,-21394 }, { 32,-21136 }, + { 33,-21394 }, { 34,-21394 }, { 35,-21394 }, { 36,-21394 }, { 37,-21394 }, + { 38,-21394 }, { 39,5398 }, { 40,-21394 }, { 41,-21394 }, { 42,-21394 }, + { 43,-21394 }, { 44,-21394 }, { 45,-20759 }, { 46,-21394 }, { 47,-21394 }, + { 48,-21394 }, { 49,-21394 }, { 50,-21394 }, { 51,-21394 }, { 52,-21394 }, + { 53,-21394 }, { 54,-21394 }, { 55,-21394 }, { 56,-21394 }, { 57,-21394 }, + { 58,-21394 }, { 59,-21394 }, { 60,-21394 }, { 61,-21394 }, { 62,-21394 }, + { 63,-21394 }, { 64,-21394 }, { 65,-21394 }, { 66,-21394 }, { 67,-21394 }, + + { 68,-21394 }, { 69,-21394 }, { 70,-21394 }, { 71,-21394 }, { 72,-21394 }, + { 73,-21394 }, { 74,-21394 }, { 75,-21394 }, { 76,-21394 }, { 77,-21394 }, + { 78,-21394 }, { 79,-21394 }, { 80,-21394 }, { 81,-21394 }, { 82,-21394 }, + { 83,-21394 }, { 84,-21394 }, { 85,-20501 }, { 86,-21394 }, { 87,-21394 }, + { 88,-21394 }, { 89,-21394 }, { 90,-21394 }, { 91,-21394 }, { 92,-21394 }, + { 93,-21394 }, { 94,-21394 }, { 95,-21394 }, { 96,-21394 }, { 97,-21394 }, + { 98,-21394 }, { 99,-21394 }, { 100,-21394 }, { 101,-21394 }, { 102,-21394 }, + { 103,-21394 }, { 104,-21394 }, { 105,-21394 }, { 106,-21394 }, { 107,-21394 }, + { 108,-21394 }, { 109,-21394 }, { 110,-21394 }, { 111,-21394 }, { 112,-21394 }, + { 113,-21394 }, { 114,-21394 }, { 115,-21394 }, { 116,-21394 }, { 117,-20501 }, + + { 118,-21394 }, { 119,-21394 }, { 120,-21394 }, { 121,-21394 }, { 122,-21394 }, + { 123,-21394 }, { 124,-21394 }, { 125,-21394 }, { 126,-21394 }, { 127,-21394 }, + { 128,-21394 }, { 129,-21394 }, { 130,-21394 }, { 131,-21394 }, { 132,-21394 }, + { 133,-21394 }, { 134,-21394 }, { 135,-21394 }, { 136,-21394 }, { 137,-21394 }, + { 138,-21394 }, { 139,-21394 }, { 140,-21394 }, { 141,-21394 }, { 142,-21394 }, + { 143,-21394 }, { 144,-21394 }, { 145,-21394 }, { 146,-21394 }, { 147,-21394 }, + { 148,-21394 }, { 149,-21394 }, { 150,-21394 }, { 151,-21394 }, { 152,-21394 }, + { 153,-21394 }, { 154,-21394 }, { 155,-21394 }, { 156,-21394 }, { 157,-21394 }, + { 158,-21394 }, { 159,-21394 }, { 160,-21394 }, { 161,-21394 }, { 162,-21394 }, + { 163,-21394 }, { 164,-21394 }, { 165,-21394 }, { 166,-21394 }, { 167,-21394 }, + + { 168,-21394 }, { 169,-21394 }, { 170,-21394 }, { 171,-21394 }, { 172,-21394 }, + { 173,-21394 }, { 174,-21394 }, { 175,-21394 }, { 176,-21394 }, { 177,-21394 }, + { 178,-21394 }, { 179,-21394 }, { 180,-21394 }, { 181,-21394 }, { 182,-21394 }, + { 183,-21394 }, { 184,-21394 }, { 185,-21394 }, { 186,-21394 }, { 187,-21394 }, + { 188,-21394 }, { 189,-21394 }, { 190,-21394 }, { 191,-21394 }, { 192,-21394 }, + { 193,-21394 }, { 194,-21394 }, { 195,-21394 }, { 196,-21394 }, { 197,-21394 }, + { 198,-21394 }, { 199,-21394 }, { 200,-21394 }, { 201,-21394 }, { 202,-21394 }, + { 203,-21394 }, { 204,-21394 }, { 205,-21394 }, { 206,-21394 }, { 207,-21394 }, + { 208,-21394 }, { 209,-21394 }, { 210,-21394 }, { 211,-21394 }, { 212,-21394 }, + { 213,-21394 }, { 214,-21394 }, { 215,-21394 }, { 216,-21394 }, { 217,-21394 }, + + { 218,-21394 }, { 219,-21394 }, { 220,-21394 }, { 221,-21394 }, { 222,-21394 }, + { 223,-21394 }, { 224,-21394 }, { 225,-21394 }, { 226,-21394 }, { 227,-21394 }, + { 228,-21394 }, { 229,-21394 }, { 230,-21394 }, { 231,-21394 }, { 232,-21394 }, + { 233,-21394 }, { 234,-21394 }, { 235,-21394 }, { 236,-21394 }, { 237,-21394 }, + { 238,-21394 }, { 239,-21394 }, { 240,-21394 }, { 241,-21394 }, { 242,-21394 }, + { 243,-21394 }, { 244,-21394 }, { 245,-21394 }, { 246,-21394 }, { 247,-21394 }, + { 248,-21394 }, { 249,-21394 }, { 250,-21394 }, { 251,-21394 }, { 252,-21394 }, + { 253,-21394 }, { 254,-21394 }, { 255,-21394 }, { 256,-21394 }, { 0, 24 }, + { 0,15440 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 9,-31708 }, + + { 10,-31708 }, { 0, 0 }, { 12,-31708 }, { 13,-31708 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 32,-31708 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 39,-37769 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 45,-41655 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 85,-42160 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 117,-42160 }, { 0, 24 }, { 0,15321 }, + { 1,-21771 }, { 2,-21771 }, { 3,-21771 }, { 4,-21771 }, { 5,-21771 }, + { 6,-21771 }, { 7,-21771 }, { 8,-21771 }, { 9,-21513 }, { 10,-21255 }, + { 11,-21771 }, { 12,-21513 }, { 13,-21255 }, { 14,-21771 }, { 15,-21771 }, + { 16,-21771 }, { 17,-21771 }, { 18,-21771 }, { 19,-21771 }, { 20,-21771 }, + { 21,-21771 }, { 22,-21771 }, { 23,-21771 }, { 24,-21771 }, { 25,-21771 }, + { 26,-21771 }, { 27,-21771 }, { 28,-21771 }, { 29,-21771 }, { 30,-21771 }, + { 31,-21771 }, { 32,-21513 }, { 33,-21771 }, { 34,-21771 }, { 35,-21771 }, + { 36,-21771 }, { 37,-21771 }, { 38,-21771 }, { 39,5021 }, { 40,-21771 }, + + { 41,-21771 }, { 42,-21771 }, { 43,-21771 }, { 44,-21771 }, { 45,-18841 }, + { 46,-21771 }, { 47,-21771 }, { 48,-21771 }, { 49,-21771 }, { 50,-21771 }, + { 51,-21771 }, { 52,-21771 }, { 53,-21771 }, { 54,-21771 }, { 55,-21771 }, + { 56,-21771 }, { 57,-21771 }, { 58,-21771 }, { 59,-21771 }, { 60,-21771 }, + { 61,-21771 }, { 62,-21771 }, { 63,-21771 }, { 64,-21771 }, { 65,-21771 }, + { 66,-21771 }, { 67,-21771 }, { 68,-21771 }, { 69,-21771 }, { 70,-21771 }, + { 71,-21771 }, { 72,-21771 }, { 73,-21771 }, { 74,-21771 }, { 75,-21771 }, + { 76,-21771 }, { 77,-21771 }, { 78,-21771 }, { 79,-21771 }, { 80,-21771 }, + { 81,-21771 }, { 82,-21771 }, { 83,-21771 }, { 84,-21771 }, { 85,-20878 }, + { 86,-21771 }, { 87,-21771 }, { 88,-21771 }, { 89,-21771 }, { 90,-21771 }, + + { 91,-21771 }, { 92,-21771 }, { 93,-21771 }, { 94,-21771 }, { 95,-21771 }, + { 96,-21771 }, { 97,-21771 }, { 98,-21771 }, { 99,-21771 }, { 100,-21771 }, + { 101,-21771 }, { 102,-21771 }, { 103,-21771 }, { 104,-21771 }, { 105,-21771 }, + { 106,-21771 }, { 107,-21771 }, { 108,-21771 }, { 109,-21771 }, { 110,-21771 }, + { 111,-21771 }, { 112,-21771 }, { 113,-21771 }, { 114,-21771 }, { 115,-21771 }, + { 116,-21771 }, { 117,-20878 }, { 118,-21771 }, { 119,-21771 }, { 120,-21771 }, + { 121,-21771 }, { 122,-21771 }, { 123,-21771 }, { 124,-21771 }, { 125,-21771 }, + { 126,-21771 }, { 127,-21771 }, { 128,-21771 }, { 129,-21771 }, { 130,-21771 }, + { 131,-21771 }, { 132,-21771 }, { 133,-21771 }, { 134,-21771 }, { 135,-21771 }, + { 136,-21771 }, { 137,-21771 }, { 138,-21771 }, { 139,-21771 }, { 140,-21771 }, + + { 141,-21771 }, { 142,-21771 }, { 143,-21771 }, { 144,-21771 }, { 145,-21771 }, + { 146,-21771 }, { 147,-21771 }, { 148,-21771 }, { 149,-21771 }, { 150,-21771 }, + { 151,-21771 }, { 152,-21771 }, { 153,-21771 }, { 154,-21771 }, { 155,-21771 }, + { 156,-21771 }, { 157,-21771 }, { 158,-21771 }, { 159,-21771 }, { 160,-21771 }, + { 161,-21771 }, { 162,-21771 }, { 163,-21771 }, { 164,-21771 }, { 165,-21771 }, + { 166,-21771 }, { 167,-21771 }, { 168,-21771 }, { 169,-21771 }, { 170,-21771 }, + { 171,-21771 }, { 172,-21771 }, { 173,-21771 }, { 174,-21771 }, { 175,-21771 }, + { 176,-21771 }, { 177,-21771 }, { 178,-21771 }, { 179,-21771 }, { 180,-21771 }, + { 181,-21771 }, { 182,-21771 }, { 183,-21771 }, { 184,-21771 }, { 185,-21771 }, + { 186,-21771 }, { 187,-21771 }, { 188,-21771 }, { 189,-21771 }, { 190,-21771 }, + + { 191,-21771 }, { 192,-21771 }, { 193,-21771 }, { 194,-21771 }, { 195,-21771 }, + { 196,-21771 }, { 197,-21771 }, { 198,-21771 }, { 199,-21771 }, { 200,-21771 }, + { 201,-21771 }, { 202,-21771 }, { 203,-21771 }, { 204,-21771 }, { 205,-21771 }, + { 206,-21771 }, { 207,-21771 }, { 208,-21771 }, { 209,-21771 }, { 210,-21771 }, + { 211,-21771 }, { 212,-21771 }, { 213,-21771 }, { 214,-21771 }, { 215,-21771 }, + { 216,-21771 }, { 217,-21771 }, { 218,-21771 }, { 219,-21771 }, { 220,-21771 }, + { 221,-21771 }, { 222,-21771 }, { 223,-21771 }, { 224,-21771 }, { 225,-21771 }, + { 226,-21771 }, { 227,-21771 }, { 228,-21771 }, { 229,-21771 }, { 230,-21771 }, + { 231,-21771 }, { 232,-21771 }, { 233,-21771 }, { 234,-21771 }, { 235,-21771 }, + { 236,-21771 }, { 237,-21771 }, { 238,-21771 }, { 239,-21771 }, { 240,-21771 }, + + { 241,-21771 }, { 242,-21771 }, { 243,-21771 }, { 244,-21771 }, { 245,-21771 }, + { 246,-21771 }, { 247,-21771 }, { 248,-21771 }, { 249,-21771 }, { 250,-21771 }, + { 251,-21771 }, { 252,-21771 }, { 253,-21771 }, { 254,-21771 }, { 255,-21771 }, + { 256,-21771 }, { 0, 24 }, { 0,15063 }, { 1,-22029 }, { 2,-22029 }, + { 3,-22029 }, { 4,-22029 }, { 5,-22029 }, { 6,-22029 }, { 7,-22029 }, + { 8,-22029 }, { 9,-21771 }, { 10,-21513 }, { 11,-22029 }, { 12,-21771 }, + { 13,-21513 }, { 14,-22029 }, { 15,-22029 }, { 16,-22029 }, { 17,-22029 }, + { 18,-22029 }, { 19,-22029 }, { 20,-22029 }, { 21,-22029 }, { 22,-22029 }, + { 23,-22029 }, { 24,-22029 }, { 25,-22029 }, { 26,-22029 }, { 27,-22029 }, + { 28,-22029 }, { 29,-22029 }, { 30,-22029 }, { 31,-22029 }, { 32,-21771 }, + + { 33,-22029 }, { 34,-22029 }, { 35,-22029 }, { 36,-22029 }, { 37,-22029 }, + { 38,-22029 }, { 39,4763 }, { 40,-22029 }, { 41,-22029 }, { 42,-22029 }, + { 43,-22029 }, { 44,-22029 }, { 45,-21394 }, { 46,-22029 }, { 47,-22029 }, + { 48,-22029 }, { 49,-22029 }, { 50,-22029 }, { 51,-22029 }, { 52,-22029 }, + { 53,-22029 }, { 54,-22029 }, { 55,-22029 }, { 56,-22029 }, { 57,-22029 }, + { 58,-22029 }, { 59,-22029 }, { 60,-22029 }, { 61,-22029 }, { 62,-22029 }, + { 63,-22029 }, { 64,-22029 }, { 65,-22029 }, { 66,-22029 }, { 67,-22029 }, + { 68,-22029 }, { 69,-18841 }, { 70,-22029 }, { 71,-22029 }, { 72,-22029 }, + { 73,-22029 }, { 74,-22029 }, { 75,-22029 }, { 76,-22029 }, { 77,-22029 }, + { 78,-22029 }, { 79,-22029 }, { 80,-22029 }, { 81,-22029 }, { 82,-22029 }, + + { 83,-22029 }, { 84,-22029 }, { 85,-21136 }, { 86,-22029 }, { 87,-22029 }, + { 88,-22029 }, { 89,-22029 }, { 90,-22029 }, { 91,-22029 }, { 92,-22029 }, + { 93,-22029 }, { 94,-22029 }, { 95,-22029 }, { 96,-22029 }, { 97,-22029 }, + { 98,-22029 }, { 99,-22029 }, { 100,-22029 }, { 101,-18841 }, { 102,-22029 }, + { 103,-22029 }, { 104,-22029 }, { 105,-22029 }, { 106,-22029 }, { 107,-22029 }, + { 108,-22029 }, { 109,-22029 }, { 110,-22029 }, { 111,-22029 }, { 112,-22029 }, + { 113,-22029 }, { 114,-22029 }, { 115,-22029 }, { 116,-22029 }, { 117,-21136 }, + { 118,-22029 }, { 119,-22029 }, { 120,-22029 }, { 121,-22029 }, { 122,-22029 }, + { 123,-22029 }, { 124,-22029 }, { 125,-22029 }, { 126,-22029 }, { 127,-22029 }, + { 128,-22029 }, { 129,-22029 }, { 130,-22029 }, { 131,-22029 }, { 132,-22029 }, + + { 133,-22029 }, { 134,-22029 }, { 135,-22029 }, { 136,-22029 }, { 137,-22029 }, + { 138,-22029 }, { 139,-22029 }, { 140,-22029 }, { 141,-22029 }, { 142,-22029 }, + { 143,-22029 }, { 144,-22029 }, { 145,-22029 }, { 146,-22029 }, { 147,-22029 }, + { 148,-22029 }, { 149,-22029 }, { 150,-22029 }, { 151,-22029 }, { 152,-22029 }, + { 153,-22029 }, { 154,-22029 }, { 155,-22029 }, { 156,-22029 }, { 157,-22029 }, + { 158,-22029 }, { 159,-22029 }, { 160,-22029 }, { 161,-22029 }, { 162,-22029 }, + { 163,-22029 }, { 164,-22029 }, { 165,-22029 }, { 166,-22029 }, { 167,-22029 }, + { 168,-22029 }, { 169,-22029 }, { 170,-22029 }, { 171,-22029 }, { 172,-22029 }, + { 173,-22029 }, { 174,-22029 }, { 175,-22029 }, { 176,-22029 }, { 177,-22029 }, + { 178,-22029 }, { 179,-22029 }, { 180,-22029 }, { 181,-22029 }, { 182,-22029 }, + + { 183,-22029 }, { 184,-22029 }, { 185,-22029 }, { 186,-22029 }, { 187,-22029 }, + { 188,-22029 }, { 189,-22029 }, { 190,-22029 }, { 191,-22029 }, { 192,-22029 }, + { 193,-22029 }, { 194,-22029 }, { 195,-22029 }, { 196,-22029 }, { 197,-22029 }, + { 198,-22029 }, { 199,-22029 }, { 200,-22029 }, { 201,-22029 }, { 202,-22029 }, + { 203,-22029 }, { 204,-22029 }, { 205,-22029 }, { 206,-22029 }, { 207,-22029 }, + { 208,-22029 }, { 209,-22029 }, { 210,-22029 }, { 211,-22029 }, { 212,-22029 }, + { 213,-22029 }, { 214,-22029 }, { 215,-22029 }, { 216,-22029 }, { 217,-22029 }, + { 218,-22029 }, { 219,-22029 }, { 220,-22029 }, { 221,-22029 }, { 222,-22029 }, + { 223,-22029 }, { 224,-22029 }, { 225,-22029 }, { 226,-22029 }, { 227,-22029 }, + { 228,-22029 }, { 229,-22029 }, { 230,-22029 }, { 231,-22029 }, { 232,-22029 }, + + { 233,-22029 }, { 234,-22029 }, { 235,-22029 }, { 236,-22029 }, { 237,-22029 }, + { 238,-22029 }, { 239,-22029 }, { 240,-22029 }, { 241,-22029 }, { 242,-22029 }, + { 243,-22029 }, { 244,-22029 }, { 245,-22029 }, { 246,-22029 }, { 247,-22029 }, + { 248,-22029 }, { 249,-22029 }, { 250,-22029 }, { 251,-22029 }, { 252,-22029 }, + { 253,-22029 }, { 254,-22029 }, { 255,-22029 }, { 256,-22029 }, { 0, 24 }, + { 0,14805 }, { 1,4763 }, { 2,4763 }, { 3,4763 }, { 4,4763 }, + { 5,4763 }, { 6,4763 }, { 7,4763 }, { 8,4763 }, { 9,5021 }, + { 10,-6973 }, { 11,4763 }, { 12,5021 }, { 13,-6973 }, { 14,4763 }, + { 15,4763 }, { 16,4763 }, { 17,4763 }, { 18,4763 }, { 19,4763 }, + { 20,4763 }, { 21,4763 }, { 22,4763 }, { 23,4763 }, { 24,4763 }, + + { 25,4763 }, { 26,4763 }, { 27,4763 }, { 28,4763 }, { 29,4763 }, + { 30,4763 }, { 31,4763 }, { 32,5021 }, { 33,4763 }, { 34,4763 }, + { 35,4763 }, { 36,4763 }, { 37,4763 }, { 38,4763 }, { 39,5279 }, + { 40,4763 }, { 41,4763 }, { 42,4763 }, { 43,4763 }, { 44,4763 }, + { 45,5537 }, { 46,4763 }, { 47,4763 }, { 48,4763 }, { 49,4763 }, + { 50,4763 }, { 51,4763 }, { 52,4763 }, { 53,4763 }, { 54,4763 }, + { 55,4763 }, { 56,4763 }, { 57,4763 }, { 58,4763 }, { 59,4763 }, + { 60,4763 }, { 61,4763 }, { 62,4763 }, { 63,4763 }, { 64,4763 }, + { 65,4763 }, { 66,4763 }, { 67,4763 }, { 68,4763 }, { 69,4763 }, + { 70,4763 }, { 71,4763 }, { 72,4763 }, { 73,4763 }, { 74,4763 }, + + { 75,4763 }, { 76,4763 }, { 77,4763 }, { 78,4763 }, { 79,4763 }, + { 80,4763 }, { 81,4763 }, { 82,4763 }, { 83,4763 }, { 84,4763 }, + { 85,5795 }, { 86,4763 }, { 87,4763 }, { 88,4763 }, { 89,4763 }, + { 90,4763 }, { 91,4763 }, { 92,4763 }, { 93,4763 }, { 94,4763 }, + { 95,4763 }, { 96,4763 }, { 97,4763 }, { 98,4763 }, { 99,4763 }, + { 100,4763 }, { 101,4763 }, { 102,4763 }, { 103,4763 }, { 104,4763 }, + { 105,4763 }, { 106,4763 }, { 107,4763 }, { 108,4763 }, { 109,4763 }, + { 110,4763 }, { 111,4763 }, { 112,4763 }, { 113,4763 }, { 114,4763 }, + { 115,4763 }, { 116,4763 }, { 117,5795 }, { 118,4763 }, { 119,4763 }, + { 120,4763 }, { 121,4763 }, { 122,4763 }, { 123,4763 }, { 124,4763 }, + + { 125,4763 }, { 126,4763 }, { 127,4763 }, { 128,4763 }, { 129,4763 }, + { 130,4763 }, { 131,4763 }, { 132,4763 }, { 133,4763 }, { 134,4763 }, + { 135,4763 }, { 136,4763 }, { 137,4763 }, { 138,4763 }, { 139,4763 }, + { 140,4763 }, { 141,4763 }, { 142,4763 }, { 143,4763 }, { 144,4763 }, + { 145,4763 }, { 146,4763 }, { 147,4763 }, { 148,4763 }, { 149,4763 }, + { 150,4763 }, { 151,4763 }, { 152,4763 }, { 153,4763 }, { 154,4763 }, + { 155,4763 }, { 156,4763 }, { 157,4763 }, { 158,4763 }, { 159,4763 }, + { 160,4763 }, { 161,4763 }, { 162,4763 }, { 163,4763 }, { 164,4763 }, + { 165,4763 }, { 166,4763 }, { 167,4763 }, { 168,4763 }, { 169,4763 }, + { 170,4763 }, { 171,4763 }, { 172,4763 }, { 173,4763 }, { 174,4763 }, + + { 175,4763 }, { 176,4763 }, { 177,4763 }, { 178,4763 }, { 179,4763 }, + { 180,4763 }, { 181,4763 }, { 182,4763 }, { 183,4763 }, { 184,4763 }, + { 185,4763 }, { 186,4763 }, { 187,4763 }, { 188,4763 }, { 189,4763 }, + { 190,4763 }, { 191,4763 }, { 192,4763 }, { 193,4763 }, { 194,4763 }, + { 195,4763 }, { 196,4763 }, { 197,4763 }, { 198,4763 }, { 199,4763 }, + { 200,4763 }, { 201,4763 }, { 202,4763 }, { 203,4763 }, { 204,4763 }, + { 205,4763 }, { 206,4763 }, { 207,4763 }, { 208,4763 }, { 209,4763 }, + { 210,4763 }, { 211,4763 }, { 212,4763 }, { 213,4763 }, { 214,4763 }, + { 215,4763 }, { 216,4763 }, { 217,4763 }, { 218,4763 }, { 219,4763 }, + { 220,4763 }, { 221,4763 }, { 222,4763 }, { 223,4763 }, { 224,4763 }, + + { 225,4763 }, { 226,4763 }, { 227,4763 }, { 228,4763 }, { 229,4763 }, + { 230,4763 }, { 231,4763 }, { 232,4763 }, { 233,4763 }, { 234,4763 }, + { 235,4763 }, { 236,4763 }, { 237,4763 }, { 238,4763 }, { 239,4763 }, + { 240,4763 }, { 241,4763 }, { 242,4763 }, { 243,4763 }, { 244,4763 }, + { 245,4763 }, { 246,4763 }, { 247,4763 }, { 248,4763 }, { 249,4763 }, + { 250,4763 }, { 251,4763 }, { 252,4763 }, { 253,4763 }, { 254,4763 }, + { 255,4763 }, { 256,4763 }, { 0, 24 }, { 0,14547 }, { 1,4505 }, + { 2,4505 }, { 3,4505 }, { 4,4505 }, { 5,4505 }, { 6,4505 }, + { 7,4505 }, { 8,4505 }, { 9,4763 }, { 10,-7231 }, { 11,4505 }, + { 12,4763 }, { 13,-7231 }, { 14,4505 }, { 15,4505 }, { 16,4505 }, + + { 17,4505 }, { 18,4505 }, { 19,4505 }, { 20,4505 }, { 21,4505 }, + { 22,4505 }, { 23,4505 }, { 24,4505 }, { 25,4505 }, { 26,4505 }, + { 27,4505 }, { 28,4505 }, { 29,4505 }, { 30,4505 }, { 31,4505 }, + { 32,4763 }, { 33,4505 }, { 34,4505 }, { 35,4505 }, { 36,4505 }, + { 37,4505 }, { 38,4505 }, { 39,5021 }, { 40,4505 }, { 41,4505 }, + { 42,4505 }, { 43,4505 }, { 44,4505 }, { 45,5795 }, { 46,4505 }, + { 47,4505 }, { 48,4505 }, { 49,4505 }, { 50,4505 }, { 51,4505 }, + { 52,4505 }, { 53,4505 }, { 54,4505 }, { 55,4505 }, { 56,4505 }, + { 57,4505 }, { 58,4505 }, { 59,4505 }, { 60,4505 }, { 61,4505 }, + { 62,4505 }, { 63,4505 }, { 64,4505 }, { 65,4505 }, { 66,4505 }, + + { 67,4505 }, { 68,4505 }, { 69,4505 }, { 70,4505 }, { 71,4505 }, + { 72,4505 }, { 73,4505 }, { 74,4505 }, { 75,4505 }, { 76,4505 }, + { 77,4505 }, { 78,4505 }, { 79,4505 }, { 80,4505 }, { 81,4505 }, + { 82,4505 }, { 83,4505 }, { 84,4505 }, { 85,5537 }, { 86,4505 }, + { 87,4505 }, { 88,4505 }, { 89,4505 }, { 90,4505 }, { 91,4505 }, + { 92,4505 }, { 93,4505 }, { 94,4505 }, { 95,4505 }, { 96,4505 }, + { 97,4505 }, { 98,4505 }, { 99,4505 }, { 100,4505 }, { 101,4505 }, + { 102,4505 }, { 103,4505 }, { 104,4505 }, { 105,4505 }, { 106,4505 }, + { 107,4505 }, { 108,4505 }, { 109,4505 }, { 110,4505 }, { 111,4505 }, + { 112,4505 }, { 113,4505 }, { 114,4505 }, { 115,4505 }, { 116,4505 }, + + { 117,5537 }, { 118,4505 }, { 119,4505 }, { 120,4505 }, { 121,4505 }, + { 122,4505 }, { 123,4505 }, { 124,4505 }, { 125,4505 }, { 126,4505 }, + { 127,4505 }, { 128,4505 }, { 129,4505 }, { 130,4505 }, { 131,4505 }, + { 132,4505 }, { 133,4505 }, { 134,4505 }, { 135,4505 }, { 136,4505 }, + { 137,4505 }, { 138,4505 }, { 139,4505 }, { 140,4505 }, { 141,4505 }, + { 142,4505 }, { 143,4505 }, { 144,4505 }, { 145,4505 }, { 146,4505 }, + { 147,4505 }, { 148,4505 }, { 149,4505 }, { 150,4505 }, { 151,4505 }, + { 152,4505 }, { 153,4505 }, { 154,4505 }, { 155,4505 }, { 156,4505 }, + { 157,4505 }, { 158,4505 }, { 159,4505 }, { 160,4505 }, { 161,4505 }, + { 162,4505 }, { 163,4505 }, { 164,4505 }, { 165,4505 }, { 166,4505 }, + + { 167,4505 }, { 168,4505 }, { 169,4505 }, { 170,4505 }, { 171,4505 }, + { 172,4505 }, { 173,4505 }, { 174,4505 }, { 175,4505 }, { 176,4505 }, + { 177,4505 }, { 178,4505 }, { 179,4505 }, { 180,4505 }, { 181,4505 }, + { 182,4505 }, { 183,4505 }, { 184,4505 }, { 185,4505 }, { 186,4505 }, + { 187,4505 }, { 188,4505 }, { 189,4505 }, { 190,4505 }, { 191,4505 }, + { 192,4505 }, { 193,4505 }, { 194,4505 }, { 195,4505 }, { 196,4505 }, + { 197,4505 }, { 198,4505 }, { 199,4505 }, { 200,4505 }, { 201,4505 }, + { 202,4505 }, { 203,4505 }, { 204,4505 }, { 205,4505 }, { 206,4505 }, + { 207,4505 }, { 208,4505 }, { 209,4505 }, { 210,4505 }, { 211,4505 }, + { 212,4505 }, { 213,4505 }, { 214,4505 }, { 215,4505 }, { 216,4505 }, + + { 217,4505 }, { 218,4505 }, { 219,4505 }, { 220,4505 }, { 221,4505 }, + { 222,4505 }, { 223,4505 }, { 224,4505 }, { 225,4505 }, { 226,4505 }, + { 227,4505 }, { 228,4505 }, { 229,4505 }, { 230,4505 }, { 231,4505 }, + { 232,4505 }, { 233,4505 }, { 234,4505 }, { 235,4505 }, { 236,4505 }, + { 237,4505 }, { 238,4505 }, { 239,4505 }, { 240,4505 }, { 241,4505 }, + { 242,4505 }, { 243,4505 }, { 244,4505 }, { 245,4505 }, { 246,4505 }, + { 247,4505 }, { 248,4505 }, { 249,4505 }, { 250,4505 }, { 251,4505 }, + { 252,4505 }, { 253,4505 }, { 254,4505 }, { 255,4505 }, { 256,4505 }, + { 0, 24 }, { 0,14289 }, { 1,-27842 }, { 2,-27842 }, { 3,-27842 }, + { 4,-27842 }, { 5,-27842 }, { 6,-27842 }, { 7,-27842 }, { 8,-27842 }, + + { 9,-27584 }, { 10,-35497 }, { 11,-27842 }, { 12,-27584 }, { 13,-35497 }, + { 14,-27842 }, { 15,-27842 }, { 16,-27842 }, { 17,-27842 }, { 18,-27842 }, + { 19,-27842 }, { 20,-27842 }, { 21,-27842 }, { 22,-27842 }, { 23,-27842 }, + { 24,-27842 }, { 25,-27842 }, { 26,-27842 }, { 27,-27842 }, { 28,-27842 }, + { 29,-27842 }, { 30,-27842 }, { 31,-27842 }, { 32,-27584 }, { 33,-27842 }, + { 34,-27842 }, { 35,-27842 }, { 36,-27842 }, { 37,-27842 }, { 38,-27842 }, + { 39,-27842 }, { 40,-27842 }, { 41,-27842 }, { 42,-27842 }, { 43,-27842 }, + { 44,-27842 }, { 45,-27326 }, { 46,-27842 }, { 47,-27842 }, { 48,-27842 }, + { 49,-27842 }, { 50,-27842 }, { 51,-27842 }, { 52,-27842 }, { 53,-27842 }, + { 54,-27842 }, { 55,-27842 }, { 56,-27842 }, { 57,-27842 }, { 58,-27842 }, + + { 59,-27842 }, { 60,-27842 }, { 61,-27842 }, { 62,-27842 }, { 63,-27842 }, + { 64,-27842 }, { 65,-27842 }, { 66,-27842 }, { 67,-27842 }, { 68,-27842 }, + { 69,-27842 }, { 70,-27842 }, { 71,-27842 }, { 72,-27842 }, { 73,-27842 }, + { 74,-27842 }, { 75,-27842 }, { 76,-27842 }, { 77,-27842 }, { 78,-27842 }, + { 79,-27842 }, { 80,-27842 }, { 81,-27842 }, { 82,-27842 }, { 83,-27842 }, + { 84,-27842 }, { 85,-27068 }, { 86,-27842 }, { 87,-27842 }, { 88,-27842 }, + { 89,-27842 }, { 90,-27842 }, { 91,-27842 }, { 92,-27842 }, { 93,-27842 }, + { 94,-27842 }, { 95,-27842 }, { 96,-27842 }, { 97,-27842 }, { 98,-27842 }, + { 99,-27842 }, { 100,-27842 }, { 101,-27842 }, { 102,-27842 }, { 103,-27842 }, + { 104,-27842 }, { 105,-27842 }, { 106,-27842 }, { 107,-27842 }, { 108,-27842 }, + + { 109,-27842 }, { 110,-27842 }, { 111,-27842 }, { 112,-27842 }, { 113,-27842 }, + { 114,-27842 }, { 115,-27842 }, { 116,-27842 }, { 117,-27068 }, { 118,-27842 }, + { 119,-27842 }, { 120,-27842 }, { 121,-27842 }, { 122,-27842 }, { 123,-27842 }, + { 124,-27842 }, { 125,-27842 }, { 126,-27842 }, { 127,-27842 }, { 128,-27842 }, + { 129,-27842 }, { 130,-27842 }, { 131,-27842 }, { 132,-27842 }, { 133,-27842 }, + { 134,-27842 }, { 135,-27842 }, { 136,-27842 }, { 137,-27842 }, { 138,-27842 }, + { 139,-27842 }, { 140,-27842 }, { 141,-27842 }, { 142,-27842 }, { 143,-27842 }, + { 144,-27842 }, { 145,-27842 }, { 146,-27842 }, { 147,-27842 }, { 148,-27842 }, + { 149,-27842 }, { 150,-27842 }, { 151,-27842 }, { 152,-27842 }, { 153,-27842 }, + { 154,-27842 }, { 155,-27842 }, { 156,-27842 }, { 157,-27842 }, { 158,-27842 }, + + { 159,-27842 }, { 160,-27842 }, { 161,-27842 }, { 162,-27842 }, { 163,-27842 }, + { 164,-27842 }, { 165,-27842 }, { 166,-27842 }, { 167,-27842 }, { 168,-27842 }, + { 169,-27842 }, { 170,-27842 }, { 171,-27842 }, { 172,-27842 }, { 173,-27842 }, + { 174,-27842 }, { 175,-27842 }, { 176,-27842 }, { 177,-27842 }, { 178,-27842 }, + { 179,-27842 }, { 180,-27842 }, { 181,-27842 }, { 182,-27842 }, { 183,-27842 }, + { 184,-27842 }, { 185,-27842 }, { 186,-27842 }, { 187,-27842 }, { 188,-27842 }, + { 189,-27842 }, { 190,-27842 }, { 191,-27842 }, { 192,-27842 }, { 193,-27842 }, + { 194,-27842 }, { 195,-27842 }, { 196,-27842 }, { 197,-27842 }, { 198,-27842 }, + { 199,-27842 }, { 200,-27842 }, { 201,-27842 }, { 202,-27842 }, { 203,-27842 }, + { 204,-27842 }, { 205,-27842 }, { 206,-27842 }, { 207,-27842 }, { 208,-27842 }, + + { 209,-27842 }, { 210,-27842 }, { 211,-27842 }, { 212,-27842 }, { 213,-27842 }, + { 214,-27842 }, { 215,-27842 }, { 216,-27842 }, { 217,-27842 }, { 218,-27842 }, + { 219,-27842 }, { 220,-27842 }, { 221,-27842 }, { 222,-27842 }, { 223,-27842 }, + { 224,-27842 }, { 225,-27842 }, { 226,-27842 }, { 227,-27842 }, { 228,-27842 }, + { 229,-27842 }, { 230,-27842 }, { 231,-27842 }, { 232,-27842 }, { 233,-27842 }, + { 234,-27842 }, { 235,-27842 }, { 236,-27842 }, { 237,-27842 }, { 238,-27842 }, + { 239,-27842 }, { 240,-27842 }, { 241,-27842 }, { 242,-27842 }, { 243,-27842 }, + { 244,-27842 }, { 245,-27842 }, { 246,-27842 }, { 247,-27842 }, { 248,-27842 }, + { 249,-27842 }, { 250,-27842 }, { 251,-27842 }, { 252,-27842 }, { 253,-27842 }, + { 254,-27842 }, { 255,-27842 }, { 256,-27842 }, { 0, 24 }, { 0,14031 }, + + { 1, 0 }, { 2, 0 }, { 3, 0 }, { 4, 0 }, { 5, 0 }, + { 6, 0 }, { 7, 0 }, { 8, 0 }, { 9, 258 }, { 10,-12160 }, + { 11, 0 }, { 12, 258 }, { 13,-12160 }, { 14, 0 }, { 15, 0 }, + { 16, 0 }, { 17, 0 }, { 18, 0 }, { 19, 0 }, { 20, 0 }, + { 21, 0 }, { 22, 0 }, { 23, 0 }, { 24, 0 }, { 25, 0 }, + { 26, 0 }, { 27, 0 }, { 28, 0 }, { 29, 0 }, { 30, 0 }, + { 31, 0 }, { 32, 258 }, { 33, 0 }, { 34, 0 }, { 35, 0 }, + { 36, 0 }, { 37, 0 }, { 38, 0 }, { 39, 516 }, { 40, 0 }, + { 41, 0 }, { 42, 0 }, { 43, 0 }, { 44, 0 }, { 45,5537 }, + { 46, 0 }, { 47, 0 }, { 48, 0 }, { 49, 0 }, { 50, 0 }, + + { 51, 0 }, { 52, 0 }, { 53, 0 }, { 54, 0 }, { 55, 0 }, + { 56, 0 }, { 57, 0 }, { 58, 0 }, { 59, 0 }, { 60, 0 }, + { 61, 0 }, { 62, 0 }, { 63, 0 }, { 64, 0 }, { 65, 0 }, + { 66, 0 }, { 67, 0 }, { 68, 0 }, { 69, 0 }, { 70, 0 }, + { 71, 0 }, { 72, 0 }, { 73, 0 }, { 74, 0 }, { 75, 0 }, + { 76, 0 }, { 77, 0 }, { 78, 0 }, { 79, 0 }, { 80, 0 }, + { 81, 0 }, { 82, 0 }, { 83, 0 }, { 84, 0 }, { 85,1032 }, + { 86, 0 }, { 87, 0 }, { 88, 0 }, { 89, 0 }, { 90, 0 }, + { 91, 0 }, { 92, 0 }, { 93, 0 }, { 94, 0 }, { 95, 0 }, + { 96, 0 }, { 97, 0 }, { 98, 0 }, { 99, 0 }, { 100, 0 }, + + { 101, 0 }, { 102, 0 }, { 103, 0 }, { 104, 0 }, { 105, 0 }, + { 106, 0 }, { 107, 0 }, { 108, 0 }, { 109, 0 }, { 110, 0 }, + { 111, 0 }, { 112, 0 }, { 113, 0 }, { 114, 0 }, { 115, 0 }, + { 116, 0 }, { 117,1032 }, { 118, 0 }, { 119, 0 }, { 120, 0 }, + { 121, 0 }, { 122, 0 }, { 123, 0 }, { 124, 0 }, { 125, 0 }, + { 126, 0 }, { 127, 0 }, { 128, 0 }, { 129, 0 }, { 130, 0 }, + { 131, 0 }, { 132, 0 }, { 133, 0 }, { 134, 0 }, { 135, 0 }, + { 136, 0 }, { 137, 0 }, { 138, 0 }, { 139, 0 }, { 140, 0 }, + { 141, 0 }, { 142, 0 }, { 143, 0 }, { 144, 0 }, { 145, 0 }, + { 146, 0 }, { 147, 0 }, { 148, 0 }, { 149, 0 }, { 150, 0 }, + + { 151, 0 }, { 152, 0 }, { 153, 0 }, { 154, 0 }, { 155, 0 }, + { 156, 0 }, { 157, 0 }, { 158, 0 }, { 159, 0 }, { 160, 0 }, + { 161, 0 }, { 162, 0 }, { 163, 0 }, { 164, 0 }, { 165, 0 }, + { 166, 0 }, { 167, 0 }, { 168, 0 }, { 169, 0 }, { 170, 0 }, + { 171, 0 }, { 172, 0 }, { 173, 0 }, { 174, 0 }, { 175, 0 }, + { 176, 0 }, { 177, 0 }, { 178, 0 }, { 179, 0 }, { 180, 0 }, + { 181, 0 }, { 182, 0 }, { 183, 0 }, { 184, 0 }, { 185, 0 }, + { 186, 0 }, { 187, 0 }, { 188, 0 }, { 189, 0 }, { 190, 0 }, + { 191, 0 }, { 192, 0 }, { 193, 0 }, { 194, 0 }, { 195, 0 }, + { 196, 0 }, { 197, 0 }, { 198, 0 }, { 199, 0 }, { 200, 0 }, + + { 201, 0 }, { 202, 0 }, { 203, 0 }, { 204, 0 }, { 205, 0 }, + { 206, 0 }, { 207, 0 }, { 208, 0 }, { 209, 0 }, { 210, 0 }, + { 211, 0 }, { 212, 0 }, { 213, 0 }, { 214, 0 }, { 215, 0 }, + { 216, 0 }, { 217, 0 }, { 218, 0 }, { 219, 0 }, { 220, 0 }, + { 221, 0 }, { 222, 0 }, { 223, 0 }, { 224, 0 }, { 225, 0 }, + { 226, 0 }, { 227, 0 }, { 228, 0 }, { 229, 0 }, { 230, 0 }, + { 231, 0 }, { 232, 0 }, { 233, 0 }, { 234, 0 }, { 235, 0 }, + { 236, 0 }, { 237, 0 }, { 238, 0 }, { 239, 0 }, { 240, 0 }, + { 241, 0 }, { 242, 0 }, { 243, 0 }, { 244, 0 }, { 245, 0 }, + { 246, 0 }, { 247, 0 }, { 248, 0 }, { 249, 0 }, { 250, 0 }, + + { 251, 0 }, { 252, 0 }, { 253, 0 }, { 254, 0 }, { 255, 0 }, + { 256, 0 }, { 0, 24 }, { 0,13773 }, { 1,-258 }, { 2,-258 }, + { 3,-258 }, { 4,-258 }, { 5,-258 }, { 6,-258 }, { 7,-258 }, + { 8,-258 }, { 9, 0 }, { 10,-12418 }, { 11,-258 }, { 12, 0 }, + { 13,-12418 }, { 14,-258 }, { 15,-258 }, { 16,-258 }, { 17,-258 }, + { 18,-258 }, { 19,-258 }, { 20,-258 }, { 21,-258 }, { 22,-258 }, + { 23,-258 }, { 24,-258 }, { 25,-258 }, { 26,-258 }, { 27,-258 }, + { 28,-258 }, { 29,-258 }, { 30,-258 }, { 31,-258 }, { 32, 0 }, + { 33,-258 }, { 34,-258 }, { 35,-258 }, { 36,-258 }, { 37,-258 }, + { 38,-258 }, { 39, 258 }, { 40,-258 }, { 41,-258 }, { 42,-258 }, + + { 43,-258 }, { 44,-258 }, { 45,5279 }, { 46,-258 }, { 47,-258 }, + { 48,-258 }, { 49,-258 }, { 50,-258 }, { 51,-258 }, { 52,-258 }, + { 53,-258 }, { 54,-258 }, { 55,-258 }, { 56,-258 }, { 57,-258 }, + { 58,-258 }, { 59,-258 }, { 60,-258 }, { 61,-258 }, { 62,-258 }, + { 63,-258 }, { 64,-258 }, { 65,-258 }, { 66,-258 }, { 67,-258 }, + { 68,-258 }, { 69,-258 }, { 70,-258 }, { 71,-258 }, { 72,-258 }, + { 73,-258 }, { 74,-258 }, { 75,-258 }, { 76,-258 }, { 77,-258 }, + { 78,-258 }, { 79,-258 }, { 80,-258 }, { 81,-258 }, { 82,-258 }, + { 83,-258 }, { 84,-258 }, { 85, 774 }, { 86,-258 }, { 87,-258 }, + { 88,-258 }, { 89,-258 }, { 90,-258 }, { 91,-258 }, { 92,-258 }, + + { 93,-258 }, { 94,-258 }, { 95,-258 }, { 96,-258 }, { 97,-258 }, + { 98,-258 }, { 99,-258 }, { 100,-258 }, { 101,-258 }, { 102,-258 }, + { 103,-258 }, { 104,-258 }, { 105,-258 }, { 106,-258 }, { 107,-258 }, + { 108,-258 }, { 109,-258 }, { 110,-258 }, { 111,-258 }, { 112,-258 }, + { 113,-258 }, { 114,-258 }, { 115,-258 }, { 116,-258 }, { 117, 774 }, + { 118,-258 }, { 119,-258 }, { 120,-258 }, { 121,-258 }, { 122,-258 }, + { 123,-258 }, { 124,-258 }, { 125,-258 }, { 126,-258 }, { 127,-258 }, + { 128,-258 }, { 129,-258 }, { 130,-258 }, { 131,-258 }, { 132,-258 }, + { 133,-258 }, { 134,-258 }, { 135,-258 }, { 136,-258 }, { 137,-258 }, + { 138,-258 }, { 139,-258 }, { 140,-258 }, { 141,-258 }, { 142,-258 }, + + { 143,-258 }, { 144,-258 }, { 145,-258 }, { 146,-258 }, { 147,-258 }, + { 148,-258 }, { 149,-258 }, { 150,-258 }, { 151,-258 }, { 152,-258 }, + { 153,-258 }, { 154,-258 }, { 155,-258 }, { 156,-258 }, { 157,-258 }, + { 158,-258 }, { 159,-258 }, { 160,-258 }, { 161,-258 }, { 162,-258 }, + { 163,-258 }, { 164,-258 }, { 165,-258 }, { 166,-258 }, { 167,-258 }, + { 168,-258 }, { 169,-258 }, { 170,-258 }, { 171,-258 }, { 172,-258 }, + { 173,-258 }, { 174,-258 }, { 175,-258 }, { 176,-258 }, { 177,-258 }, + { 178,-258 }, { 179,-258 }, { 180,-258 }, { 181,-258 }, { 182,-258 }, + { 183,-258 }, { 184,-258 }, { 185,-258 }, { 186,-258 }, { 187,-258 }, + { 188,-258 }, { 189,-258 }, { 190,-258 }, { 191,-258 }, { 192,-258 }, + + { 193,-258 }, { 194,-258 }, { 195,-258 }, { 196,-258 }, { 197,-258 }, + { 198,-258 }, { 199,-258 }, { 200,-258 }, { 201,-258 }, { 202,-258 }, + { 203,-258 }, { 204,-258 }, { 205,-258 }, { 206,-258 }, { 207,-258 }, + { 208,-258 }, { 209,-258 }, { 210,-258 }, { 211,-258 }, { 212,-258 }, + { 213,-258 }, { 214,-258 }, { 215,-258 }, { 216,-258 }, { 217,-258 }, + { 218,-258 }, { 219,-258 }, { 220,-258 }, { 221,-258 }, { 222,-258 }, + { 223,-258 }, { 224,-258 }, { 225,-258 }, { 226,-258 }, { 227,-258 }, + { 228,-258 }, { 229,-258 }, { 230,-258 }, { 231,-258 }, { 232,-258 }, + { 233,-258 }, { 234,-258 }, { 235,-258 }, { 236,-258 }, { 237,-258 }, + { 238,-258 }, { 239,-258 }, { 240,-258 }, { 241,-258 }, { 242,-258 }, + + { 243,-258 }, { 244,-258 }, { 245,-258 }, { 246,-258 }, { 247,-258 }, + { 248,-258 }, { 249,-258 }, { 250,-258 }, { 251,-258 }, { 252,-258 }, + { 253,-258 }, { 254,-258 }, { 255,-258 }, { 256,-258 }, { 0, 24 }, + { 0,13515 }, { 1,5279 }, { 2,5279 }, { 3,5279 }, { 4,5279 }, + { 5,5279 }, { 6,5279 }, { 7,5279 }, { 8,5279 }, { 9,5537 }, + { 10,5795 }, { 11,5279 }, { 12,5537 }, { 13,5795 }, { 14,5279 }, + { 15,5279 }, { 16,5279 }, { 17,5279 }, { 18,5279 }, { 19,5279 }, + { 20,5279 }, { 21,5279 }, { 22,5279 }, { 23,5279 }, { 24,5279 }, + { 25,5279 }, { 26,5279 }, { 27,5279 }, { 28,5279 }, { 29,5279 }, + { 30,5279 }, { 31,5279 }, { 32,5537 }, { 33,5279 }, { 34,5279 }, + + { 35,5279 }, { 36,5279 }, { 37,5279 }, { 38,5279 }, { 39, 0 }, + { 40,5279 }, { 41,5279 }, { 42,5279 }, { 43,5279 }, { 44,5279 }, + { 45,5914 }, { 46,5279 }, { 47,5279 }, { 48,5279 }, { 49,5279 }, + { 50,5279 }, { 51,5279 }, { 52,5279 }, { 53,5279 }, { 54,5279 }, + { 55,5279 }, { 56,5279 }, { 57,5279 }, { 58,5279 }, { 59,5279 }, + { 60,5279 }, { 61,5279 }, { 62,5279 }, { 63,5279 }, { 64,5279 }, + { 65,5279 }, { 66,5279 }, { 67,5279 }, { 68,5279 }, { 69,5279 }, + { 70,5279 }, { 71,5279 }, { 72,5279 }, { 73,5279 }, { 74,5279 }, + { 75,5279 }, { 76,5279 }, { 77,5279 }, { 78,5279 }, { 79,5279 }, + { 80,5279 }, { 81,5279 }, { 82,5279 }, { 83,5279 }, { 84,5279 }, + + { 85,6172 }, { 86,5279 }, { 87,5279 }, { 88,5279 }, { 89,5279 }, + { 90,5279 }, { 91,5279 }, { 92,5279 }, { 93,5279 }, { 94,5279 }, + { 95,5279 }, { 96,5279 }, { 97,5279 }, { 98,5279 }, { 99,5279 }, + { 100,5279 }, { 101,5279 }, { 102,5279 }, { 103,5279 }, { 104,5279 }, + { 105,5279 }, { 106,5279 }, { 107,5279 }, { 108,5279 }, { 109,5279 }, + { 110,5279 }, { 111,5279 }, { 112,5279 }, { 113,5279 }, { 114,5279 }, + { 115,5279 }, { 116,5279 }, { 117,6172 }, { 118,5279 }, { 119,5279 }, + { 120,5279 }, { 121,5279 }, { 122,5279 }, { 123,5279 }, { 124,5279 }, + { 125,5279 }, { 126,5279 }, { 127,5279 }, { 128,5279 }, { 129,5279 }, + { 130,5279 }, { 131,5279 }, { 132,5279 }, { 133,5279 }, { 134,5279 }, + + { 135,5279 }, { 136,5279 }, { 137,5279 }, { 138,5279 }, { 139,5279 }, + { 140,5279 }, { 141,5279 }, { 142,5279 }, { 143,5279 }, { 144,5279 }, + { 145,5279 }, { 146,5279 }, { 147,5279 }, { 148,5279 }, { 149,5279 }, + { 150,5279 }, { 151,5279 }, { 152,5279 }, { 153,5279 }, { 154,5279 }, + { 155,5279 }, { 156,5279 }, { 157,5279 }, { 158,5279 }, { 159,5279 }, + { 160,5279 }, { 161,5279 }, { 162,5279 }, { 163,5279 }, { 164,5279 }, + { 165,5279 }, { 166,5279 }, { 167,5279 }, { 168,5279 }, { 169,5279 }, + { 170,5279 }, { 171,5279 }, { 172,5279 }, { 173,5279 }, { 174,5279 }, + { 175,5279 }, { 176,5279 }, { 177,5279 }, { 178,5279 }, { 179,5279 }, + { 180,5279 }, { 181,5279 }, { 182,5279 }, { 183,5279 }, { 184,5279 }, + + { 185,5279 }, { 186,5279 }, { 187,5279 }, { 188,5279 }, { 189,5279 }, + { 190,5279 }, { 191,5279 }, { 192,5279 }, { 193,5279 }, { 194,5279 }, + { 195,5279 }, { 196,5279 }, { 197,5279 }, { 198,5279 }, { 199,5279 }, + { 200,5279 }, { 201,5279 }, { 202,5279 }, { 203,5279 }, { 204,5279 }, + { 205,5279 }, { 206,5279 }, { 207,5279 }, { 208,5279 }, { 209,5279 }, + { 210,5279 }, { 211,5279 }, { 212,5279 }, { 213,5279 }, { 214,5279 }, + { 215,5279 }, { 216,5279 }, { 217,5279 }, { 218,5279 }, { 219,5279 }, + { 220,5279 }, { 221,5279 }, { 222,5279 }, { 223,5279 }, { 224,5279 }, + { 225,5279 }, { 226,5279 }, { 227,5279 }, { 228,5279 }, { 229,5279 }, + { 230,5279 }, { 231,5279 }, { 232,5279 }, { 233,5279 }, { 234,5279 }, + + { 235,5279 }, { 236,5279 }, { 237,5279 }, { 238,5279 }, { 239,5279 }, + { 240,5279 }, { 241,5279 }, { 242,5279 }, { 243,5279 }, { 244,5279 }, + { 245,5279 }, { 246,5279 }, { 247,5279 }, { 248,5279 }, { 249,5279 }, + { 250,5279 }, { 251,5279 }, { 252,5279 }, { 253,5279 }, { 254,5279 }, + { 255,5279 }, { 256,5279 }, { 0, 24 }, { 0,13257 }, { 1,-774 }, + { 2,-774 }, { 3,-774 }, { 4,-774 }, { 5,-774 }, { 6,-774 }, + { 7,-774 }, { 8,-774 }, { 9,-516 }, { 10,-12934 }, { 11,-774 }, + { 12,-516 }, { 13,-12934 }, { 14,-774 }, { 15,-774 }, { 16,-774 }, + { 17,-774 }, { 18,-774 }, { 19,-774 }, { 20,-774 }, { 21,-774 }, + { 22,-774 }, { 23,-774 }, { 24,-774 }, { 25,-774 }, { 26,-774 }, + + { 27,-774 }, { 28,-774 }, { 29,-774 }, { 30,-774 }, { 31,-774 }, + { 32,-516 }, { 33,-774 }, { 34,-774 }, { 35,-774 }, { 36,-774 }, + { 37,-774 }, { 38,-774 }, { 39,-258 }, { 40,-774 }, { 41,-774 }, + { 42,-774 }, { 43,-774 }, { 44,-774 }, { 45,6172 }, { 46,-774 }, + { 47,-774 }, { 48,-774 }, { 49,-774 }, { 50,-774 }, { 51,-774 }, + { 52,-774 }, { 53,-774 }, { 54,-774 }, { 55,-774 }, { 56,-774 }, + { 57,-774 }, { 58,-774 }, { 59,-774 }, { 60,-774 }, { 61,-774 }, + { 62,-774 }, { 63,-774 }, { 64,-774 }, { 65,-774 }, { 66,-774 }, + { 67,-774 }, { 68,-774 }, { 69,-774 }, { 70,-774 }, { 71,-774 }, + { 72,-774 }, { 73,-774 }, { 74,-774 }, { 75,-774 }, { 76,-774 }, + + { 77,-774 }, { 78,-774 }, { 79,-774 }, { 80,-774 }, { 81,-774 }, + { 82,-774 }, { 83,-774 }, { 84,-774 }, { 85, 258 }, { 86,-774 }, + { 87,-774 }, { 88,-774 }, { 89,-774 }, { 90,-774 }, { 91,-774 }, + { 92,-774 }, { 93,-774 }, { 94,-774 }, { 95,-774 }, { 96,-774 }, + { 97,-774 }, { 98,-774 }, { 99,-774 }, { 100,-774 }, { 101,-774 }, + { 102,-774 }, { 103,-774 }, { 104,-774 }, { 105,-774 }, { 106,-774 }, + { 107,-774 }, { 108,-774 }, { 109,-774 }, { 110,-774 }, { 111,-774 }, + { 112,-774 }, { 113,-774 }, { 114,-774 }, { 115,-774 }, { 116,-774 }, + { 117, 258 }, { 118,-774 }, { 119,-774 }, { 120,-774 }, { 121,-774 }, + { 122,-774 }, { 123,-774 }, { 124,-774 }, { 125,-774 }, { 126,-774 }, + + { 127,-774 }, { 128,-774 }, { 129,-774 }, { 130,-774 }, { 131,-774 }, + { 132,-774 }, { 133,-774 }, { 134,-774 }, { 135,-774 }, { 136,-774 }, + { 137,-774 }, { 138,-774 }, { 139,-774 }, { 140,-774 }, { 141,-774 }, + { 142,-774 }, { 143,-774 }, { 144,-774 }, { 145,-774 }, { 146,-774 }, + { 147,-774 }, { 148,-774 }, { 149,-774 }, { 150,-774 }, { 151,-774 }, + { 152,-774 }, { 153,-774 }, { 154,-774 }, { 155,-774 }, { 156,-774 }, + { 157,-774 }, { 158,-774 }, { 159,-774 }, { 160,-774 }, { 161,-774 }, + { 162,-774 }, { 163,-774 }, { 164,-774 }, { 165,-774 }, { 166,-774 }, + { 167,-774 }, { 168,-774 }, { 169,-774 }, { 170,-774 }, { 171,-774 }, + { 172,-774 }, { 173,-774 }, { 174,-774 }, { 175,-774 }, { 176,-774 }, + + { 177,-774 }, { 178,-774 }, { 179,-774 }, { 180,-774 }, { 181,-774 }, + { 182,-774 }, { 183,-774 }, { 184,-774 }, { 185,-774 }, { 186,-774 }, + { 187,-774 }, { 188,-774 }, { 189,-774 }, { 190,-774 }, { 191,-774 }, + { 192,-774 }, { 193,-774 }, { 194,-774 }, { 195,-774 }, { 196,-774 }, + { 197,-774 }, { 198,-774 }, { 199,-774 }, { 200,-774 }, { 201,-774 }, + { 202,-774 }, { 203,-774 }, { 204,-774 }, { 205,-774 }, { 206,-774 }, + { 207,-774 }, { 208,-774 }, { 209,-774 }, { 210,-774 }, { 211,-774 }, + { 212,-774 }, { 213,-774 }, { 214,-774 }, { 215,-774 }, { 216,-774 }, + { 217,-774 }, { 218,-774 }, { 219,-774 }, { 220,-774 }, { 221,-774 }, + { 222,-774 }, { 223,-774 }, { 224,-774 }, { 225,-774 }, { 226,-774 }, + + { 227,-774 }, { 228,-774 }, { 229,-774 }, { 230,-774 }, { 231,-774 }, + { 232,-774 }, { 233,-774 }, { 234,-774 }, { 235,-774 }, { 236,-774 }, + { 237,-774 }, { 238,-774 }, { 239,-774 }, { 240,-774 }, { 241,-774 }, + { 242,-774 }, { 243,-774 }, { 244,-774 }, { 245,-774 }, { 246,-774 }, + { 247,-774 }, { 248,-774 }, { 249,-774 }, { 250,-774 }, { 251,-774 }, + { 252,-774 }, { 253,-774 }, { 254,-774 }, { 255,-774 }, { 256,-774 }, + { 0, 24 }, { 0,12999 }, { 1,-1032 }, { 2,-1032 }, { 3,-1032 }, + { 4,-1032 }, { 5,-1032 }, { 6,-1032 }, { 7,-1032 }, { 8,-1032 }, + { 9,-774 }, { 10,-13192 }, { 11,-1032 }, { 12,-774 }, { 13,-13192 }, + { 14,-1032 }, { 15,-1032 }, { 16,-1032 }, { 17,-1032 }, { 18,-1032 }, + + { 19,-1032 }, { 20,-1032 }, { 21,-1032 }, { 22,-1032 }, { 23,-1032 }, + { 24,-1032 }, { 25,-1032 }, { 26,-1032 }, { 27,-1032 }, { 28,-1032 }, + { 29,-1032 }, { 30,-1032 }, { 31,-1032 }, { 32,-774 }, { 33,-1032 }, + { 34,-1032 }, { 35,-1032 }, { 36,-1032 }, { 37,-1032 }, { 38,-1032 }, + { 39,-516 }, { 40,-1032 }, { 41,-1032 }, { 42,-1032 }, { 43,-1032 }, + { 44,-1032 }, { 45,4505 }, { 46,-1032 }, { 47,-1032 }, { 48,-1032 }, + { 49,-1032 }, { 50,-1032 }, { 51,-1032 }, { 52,-1032 }, { 53,-1032 }, + { 54,-1032 }, { 55,-1032 }, { 56,-1032 }, { 57,-1032 }, { 58,-1032 }, + { 59,-1032 }, { 60,-1032 }, { 61,-1032 }, { 62,-1032 }, { 63,-1032 }, + { 64,-1032 }, { 65,-1032 }, { 66,-1032 }, { 67,-1032 }, { 68,-1032 }, + + { 69,6172 }, { 70,-1032 }, { 71,-1032 }, { 72,-1032 }, { 73,-1032 }, + { 74,-1032 }, { 75,-1032 }, { 76,-1032 }, { 77,-1032 }, { 78,-1032 }, + { 79,-1032 }, { 80,-1032 }, { 81,-1032 }, { 82,-1032 }, { 83,-1032 }, + { 84,-1032 }, { 85, 0 }, { 86,-1032 }, { 87,-1032 }, { 88,-1032 }, + { 89,-1032 }, { 90,-1032 }, { 91,-1032 }, { 92,-1032 }, { 93,-1032 }, + { 94,-1032 }, { 95,-1032 }, { 96,-1032 }, { 97,-1032 }, { 98,-1032 }, + { 99,-1032 }, { 100,-1032 }, { 101,6172 }, { 102,-1032 }, { 103,-1032 }, + { 104,-1032 }, { 105,-1032 }, { 106,-1032 }, { 107,-1032 }, { 108,-1032 }, + { 109,-1032 }, { 110,-1032 }, { 111,-1032 }, { 112,-1032 }, { 113,-1032 }, + { 114,-1032 }, { 115,-1032 }, { 116,-1032 }, { 117, 0 }, { 118,-1032 }, + + { 119,-1032 }, { 120,-1032 }, { 121,-1032 }, { 122,-1032 }, { 123,-1032 }, + { 124,-1032 }, { 125,-1032 }, { 126,-1032 }, { 127,-1032 }, { 128,-1032 }, + { 129,-1032 }, { 130,-1032 }, { 131,-1032 }, { 132,-1032 }, { 133,-1032 }, + { 134,-1032 }, { 135,-1032 }, { 136,-1032 }, { 137,-1032 }, { 138,-1032 }, + { 139,-1032 }, { 140,-1032 }, { 141,-1032 }, { 142,-1032 }, { 143,-1032 }, + { 144,-1032 }, { 145,-1032 }, { 146,-1032 }, { 147,-1032 }, { 148,-1032 }, + { 149,-1032 }, { 150,-1032 }, { 151,-1032 }, { 152,-1032 }, { 153,-1032 }, + { 154,-1032 }, { 155,-1032 }, { 156,-1032 }, { 157,-1032 }, { 158,-1032 }, + { 159,-1032 }, { 160,-1032 }, { 161,-1032 }, { 162,-1032 }, { 163,-1032 }, + { 164,-1032 }, { 165,-1032 }, { 166,-1032 }, { 167,-1032 }, { 168,-1032 }, + + { 169,-1032 }, { 170,-1032 }, { 171,-1032 }, { 172,-1032 }, { 173,-1032 }, + { 174,-1032 }, { 175,-1032 }, { 176,-1032 }, { 177,-1032 }, { 178,-1032 }, + { 179,-1032 }, { 180,-1032 }, { 181,-1032 }, { 182,-1032 }, { 183,-1032 }, + { 184,-1032 }, { 185,-1032 }, { 186,-1032 }, { 187,-1032 }, { 188,-1032 }, + { 189,-1032 }, { 190,-1032 }, { 191,-1032 }, { 192,-1032 }, { 193,-1032 }, + { 194,-1032 }, { 195,-1032 }, { 196,-1032 }, { 197,-1032 }, { 198,-1032 }, + { 199,-1032 }, { 200,-1032 }, { 201,-1032 }, { 202,-1032 }, { 203,-1032 }, + { 204,-1032 }, { 205,-1032 }, { 206,-1032 }, { 207,-1032 }, { 208,-1032 }, + { 209,-1032 }, { 210,-1032 }, { 211,-1032 }, { 212,-1032 }, { 213,-1032 }, + { 214,-1032 }, { 215,-1032 }, { 216,-1032 }, { 217,-1032 }, { 218,-1032 }, + + { 219,-1032 }, { 220,-1032 }, { 221,-1032 }, { 222,-1032 }, { 223,-1032 }, + { 224,-1032 }, { 225,-1032 }, { 226,-1032 }, { 227,-1032 }, { 228,-1032 }, + { 229,-1032 }, { 230,-1032 }, { 231,-1032 }, { 232,-1032 }, { 233,-1032 }, + { 234,-1032 }, { 235,-1032 }, { 236,-1032 }, { 237,-1032 }, { 238,-1032 }, + { 239,-1032 }, { 240,-1032 }, { 241,-1032 }, { 242,-1032 }, { 243,-1032 }, + { 244,-1032 }, { 245,-1032 }, { 246,-1032 }, { 247,-1032 }, { 248,-1032 }, + { 249,-1032 }, { 250,-1032 }, { 251,-1032 }, { 252,-1032 }, { 253,-1032 }, + { 254,-1032 }, { 255,-1032 }, { 256,-1032 }, { 0, 24 }, { 0,12741 }, + { 1,-6616 }, { 2,-6616 }, { 3,-6616 }, { 4,-6616 }, { 5,-6616 }, + { 6,-6616 }, { 7,-6616 }, { 8,-6616 }, { 9,-6358 }, { 10,-6100 }, + + { 11,-6616 }, { 12,-6358 }, { 13,-6100 }, { 14,-6616 }, { 15,-6616 }, + { 16,-6616 }, { 17,-6616 }, { 18,-6616 }, { 19,-6616 }, { 20,-6616 }, + { 21,-6616 }, { 22,-6616 }, { 23,-6616 }, { 24,-6616 }, { 25,-6616 }, + { 26,-6616 }, { 27,-6616 }, { 28,-6616 }, { 29,-6616 }, { 30,-6616 }, + { 31,-6616 }, { 32,-6358 }, { 33,-6616 }, { 34,-6616 }, { 35,-6616 }, + { 36,-6616 }, { 37,-6616 }, { 38,-6616 }, { 39,-12299 }, { 40,-6616 }, + { 41,-6616 }, { 42,-6616 }, { 43,-6616 }, { 44,-6616 }, { 45,-6053 }, + { 46,-6616 }, { 47,-6616 }, { 48,-6616 }, { 49,-6616 }, { 50,-6616 }, + { 51,-6616 }, { 52,-6616 }, { 53,-6616 }, { 54,-6616 }, { 55,-6616 }, + { 56,-6616 }, { 57,-6616 }, { 58,-6616 }, { 59,-6616 }, { 60,-6616 }, + + { 61,-6616 }, { 62,-6616 }, { 63,-6616 }, { 64,-6616 }, { 65,-6616 }, + { 66,-6616 }, { 67,-6616 }, { 68,-6616 }, { 69,-6616 }, { 70,-6616 }, + { 71,-6616 }, { 72,-6616 }, { 73,-6616 }, { 74,-6616 }, { 75,-6616 }, + { 76,-6616 }, { 77,-6616 }, { 78,-6616 }, { 79,-6616 }, { 80,-6616 }, + { 81,-6616 }, { 82,-6616 }, { 83,-6616 }, { 84,-6616 }, { 85,-6616 }, + { 86,-6616 }, { 87,-6616 }, { 88,-6616 }, { 89,-6616 }, { 90,-6616 }, + { 91,-6616 }, { 92,-6616 }, { 93,-6616 }, { 94,-6616 }, { 95,-6616 }, + { 96,-6616 }, { 97,-6616 }, { 98,-6616 }, { 99,-6616 }, { 100,-6616 }, + { 101,-6616 }, { 102,-6616 }, { 103,-6616 }, { 104,-6616 }, { 105,-6616 }, + { 106,-6616 }, { 107,-6616 }, { 108,-6616 }, { 109,-6616 }, { 110,-6616 }, + + { 111,-6616 }, { 112,-6616 }, { 113,-6616 }, { 114,-6616 }, { 115,-6616 }, + { 116,-6616 }, { 117,-6616 }, { 118,-6616 }, { 119,-6616 }, { 120,-6616 }, + { 121,-6616 }, { 122,-6616 }, { 123,-6616 }, { 124,-6616 }, { 125,-6616 }, + { 126,-6616 }, { 127,-6616 }, { 128,-6616 }, { 129,-6616 }, { 130,-6616 }, + { 131,-6616 }, { 132,-6616 }, { 133,-6616 }, { 134,-6616 }, { 135,-6616 }, + { 136,-6616 }, { 137,-6616 }, { 138,-6616 }, { 139,-6616 }, { 140,-6616 }, + { 141,-6616 }, { 142,-6616 }, { 143,-6616 }, { 144,-6616 }, { 145,-6616 }, + { 146,-6616 }, { 147,-6616 }, { 148,-6616 }, { 149,-6616 }, { 150,-6616 }, + { 151,-6616 }, { 152,-6616 }, { 153,-6616 }, { 154,-6616 }, { 155,-6616 }, + { 156,-6616 }, { 157,-6616 }, { 158,-6616 }, { 159,-6616 }, { 160,-6616 }, + + { 161,-6616 }, { 162,-6616 }, { 163,-6616 }, { 164,-6616 }, { 165,-6616 }, + { 166,-6616 }, { 167,-6616 }, { 168,-6616 }, { 169,-6616 }, { 170,-6616 }, + { 171,-6616 }, { 172,-6616 }, { 173,-6616 }, { 174,-6616 }, { 175,-6616 }, + { 176,-6616 }, { 177,-6616 }, { 178,-6616 }, { 179,-6616 }, { 180,-6616 }, + { 181,-6616 }, { 182,-6616 }, { 183,-6616 }, { 184,-6616 }, { 185,-6616 }, + { 186,-6616 }, { 187,-6616 }, { 188,-6616 }, { 189,-6616 }, { 190,-6616 }, + { 191,-6616 }, { 192,-6616 }, { 193,-6616 }, { 194,-6616 }, { 195,-6616 }, + { 196,-6616 }, { 197,-6616 }, { 198,-6616 }, { 199,-6616 }, { 200,-6616 }, + { 201,-6616 }, { 202,-6616 }, { 203,-6616 }, { 204,-6616 }, { 205,-6616 }, + { 206,-6616 }, { 207,-6616 }, { 208,-6616 }, { 209,-6616 }, { 210,-6616 }, + + { 211,-6616 }, { 212,-6616 }, { 213,-6616 }, { 214,-6616 }, { 215,-6616 }, + { 216,-6616 }, { 217,-6616 }, { 218,-6616 }, { 219,-6616 }, { 220,-6616 }, + { 221,-6616 }, { 222,-6616 }, { 223,-6616 }, { 224,-6616 }, { 225,-6616 }, + { 226,-6616 }, { 227,-6616 }, { 228,-6616 }, { 229,-6616 }, { 230,-6616 }, + { 231,-6616 }, { 232,-6616 }, { 233,-6616 }, { 234,-6616 }, { 235,-6616 }, + { 236,-6616 }, { 237,-6616 }, { 238,-6616 }, { 239,-6616 }, { 240,-6616 }, + { 241,-6616 }, { 242,-6616 }, { 243,-6616 }, { 244,-6616 }, { 245,-6616 }, + { 246,-6616 }, { 247,-6616 }, { 248,-6616 }, { 249,-6616 }, { 250,-6616 }, + { 251,-6616 }, { 252,-6616 }, { 253,-6616 }, { 254,-6616 }, { 255,-6616 }, + { 256,-6616 }, { 0, 24 }, { 0,12483 }, { 1,-40776 }, { 2,-40776 }, + + { 3,-40776 }, { 4,-40776 }, { 5,-40776 }, { 6,-40776 }, { 7,-40776 }, + { 8,-40776 }, { 9,-40776 }, { 10,-40776 }, { 11,-40776 }, { 12,-40776 }, + { 13,-40776 }, { 14,-40776 }, { 15,-40776 }, { 16,-40776 }, { 17,-40776 }, + { 18,-40776 }, { 19,-40776 }, { 20,-40776 }, { 21,-40776 }, { 22,-40776 }, + { 23,-40776 }, { 24,-40776 }, { 25,-40776 }, { 26,-40776 }, { 27,-40776 }, + { 28,-40776 }, { 29,-40776 }, { 30,-40776 }, { 31,-40776 }, { 32,-40776 }, + { 33,-40776 }, { 34,-40776 }, { 35,-40776 }, { 36,-40776 }, { 37,-40776 }, + { 38,-40776 }, { 0, 0 }, { 40,-40776 }, { 41,-40776 }, { 42,-40776 }, + { 43,-40776 }, { 44,-40776 }, { 45,-40776 }, { 46,-40776 }, { 47,-40776 }, + { 48,-40776 }, { 49,-40776 }, { 50,-40776 }, { 51,-40776 }, { 52,-40776 }, + + { 53,-40776 }, { 54,-40776 }, { 55,-40776 }, { 56,-40776 }, { 57,-40776 }, + { 58,-40776 }, { 59,-40776 }, { 60,-40776 }, { 61,-40776 }, { 62,-40776 }, + { 63,-40776 }, { 64,-40776 }, { 65,-40776 }, { 66,-40776 }, { 67,-40776 }, + { 68,-40776 }, { 69,-40776 }, { 70,-40776 }, { 71,-40776 }, { 72,-40776 }, + { 73,-40776 }, { 74,-40776 }, { 75,-40776 }, { 76,-40776 }, { 77,-40776 }, + { 78,-40776 }, { 79,-40776 }, { 80,-40776 }, { 81,-40776 }, { 82,-40776 }, + { 83,-40776 }, { 84,-40776 }, { 85,-40776 }, { 86,-40776 }, { 87,-40776 }, + { 88,-40776 }, { 89,-40776 }, { 90,-40776 }, { 91,-40776 }, { 92,-40776 }, + { 93,-40776 }, { 94,-40776 }, { 95,-40776 }, { 96,-40776 }, { 97,-40776 }, + { 98,-40776 }, { 99,-40776 }, { 100,-40776 }, { 101,-40776 }, { 102,-40776 }, + + { 103,-40776 }, { 104,-40776 }, { 105,-40776 }, { 106,-40776 }, { 107,-40776 }, + { 108,-40776 }, { 109,-40776 }, { 110,-40776 }, { 111,-40776 }, { 112,-40776 }, + { 113,-40776 }, { 114,-40776 }, { 115,-40776 }, { 116,-40776 }, { 117,-40776 }, + { 118,-40776 }, { 119,-40776 }, { 120,-40776 }, { 121,-40776 }, { 122,-40776 }, + { 123,-40776 }, { 124,-40776 }, { 125,-40776 }, { 126,-40776 }, { 127,-40776 }, + { 128,-40776 }, { 129,-40776 }, { 130,-40776 }, { 131,-40776 }, { 132,-40776 }, + { 133,-40776 }, { 134,-40776 }, { 135,-40776 }, { 136,-40776 }, { 137,-40776 }, + { 138,-40776 }, { 139,-40776 }, { 140,-40776 }, { 141,-40776 }, { 142,-40776 }, + { 143,-40776 }, { 144,-40776 }, { 145,-40776 }, { 146,-40776 }, { 147,-40776 }, + { 148,-40776 }, { 149,-40776 }, { 150,-40776 }, { 151,-40776 }, { 152,-40776 }, + + { 153,-40776 }, { 154,-40776 }, { 155,-40776 }, { 156,-40776 }, { 157,-40776 }, + { 158,-40776 }, { 159,-40776 }, { 160,-40776 }, { 161,-40776 }, { 162,-40776 }, + { 163,-40776 }, { 164,-40776 }, { 165,-40776 }, { 166,-40776 }, { 167,-40776 }, + { 168,-40776 }, { 169,-40776 }, { 170,-40776 }, { 171,-40776 }, { 172,-40776 }, + { 173,-40776 }, { 174,-40776 }, { 175,-40776 }, { 176,-40776 }, { 177,-40776 }, + { 178,-40776 }, { 179,-40776 }, { 180,-40776 }, { 181,-40776 }, { 182,-40776 }, + { 183,-40776 }, { 184,-40776 }, { 185,-40776 }, { 186,-40776 }, { 187,-40776 }, + { 188,-40776 }, { 189,-40776 }, { 190,-40776 }, { 191,-40776 }, { 192,-40776 }, + { 193,-40776 }, { 194,-40776 }, { 195,-40776 }, { 196,-40776 }, { 197,-40776 }, + { 198,-40776 }, { 199,-40776 }, { 200,-40776 }, { 201,-40776 }, { 202,-40776 }, + + { 203,-40776 }, { 204,-40776 }, { 205,-40776 }, { 206,-40776 }, { 207,-40776 }, + { 208,-40776 }, { 209,-40776 }, { 210,-40776 }, { 211,-40776 }, { 212,-40776 }, + { 213,-40776 }, { 214,-40776 }, { 215,-40776 }, { 216,-40776 }, { 217,-40776 }, + { 218,-40776 }, { 219,-40776 }, { 220,-40776 }, { 221,-40776 }, { 222,-40776 }, + { 223,-40776 }, { 224,-40776 }, { 225,-40776 }, { 226,-40776 }, { 227,-40776 }, + { 228,-40776 }, { 229,-40776 }, { 230,-40776 }, { 231,-40776 }, { 232,-40776 }, + { 233,-40776 }, { 234,-40776 }, { 235,-40776 }, { 236,-40776 }, { 237,-40776 }, + { 238,-40776 }, { 239,-40776 }, { 240,-40776 }, { 241,-40776 }, { 242,-40776 }, + { 243,-40776 }, { 244,-40776 }, { 245,-40776 }, { 246,-40776 }, { 247,-40776 }, + { 248,-40776 }, { 249,-40776 }, { 250,-40776 }, { 251,-40776 }, { 252,-40776 }, + + { 253,-40776 }, { 254,-40776 }, { 255,-40776 }, { 256,-40776 }, { 0, 48 }, + { 0,12225 }, { 1,-5537 }, { 2,-5537 }, { 3,-5537 }, { 4,-5537 }, + { 5,-5537 }, { 6,-5537 }, { 7,-5537 }, { 8,-5537 }, { 9,-5279 }, + { 10,-16149 }, { 11,-5537 }, { 12,-5279 }, { 13,-16149 }, { 14,-5537 }, + { 15,-5537 }, { 16,-5537 }, { 17,-5537 }, { 18,-5537 }, { 19,-5537 }, + { 20,-5537 }, { 21,-5537 }, { 22,-5537 }, { 23,-5537 }, { 24,-5537 }, + { 25,-5537 }, { 26,-5537 }, { 27,-5537 }, { 28,-5537 }, { 29,-5537 }, + { 30,-5537 }, { 31,-5537 }, { 32,-5279 }, { 33,-5537 }, { 34,-5537 }, + { 35,-5537 }, { 36,-5537 }, { 37,-5537 }, { 38,-5537 }, { 39,-5021 }, + { 40,-5537 }, { 41,-5537 }, { 42,-5537 }, { 43,-5537 }, { 44,-5537 }, + + { 45,1409 }, { 46,-5537 }, { 47,-5537 }, { 48,-5537 }, { 49,-5537 }, + { 50,-5537 }, { 51,-5537 }, { 52,-5537 }, { 53,-5537 }, { 54,-5537 }, + { 55,-5537 }, { 56,-5537 }, { 57,-5537 }, { 58,-5537 }, { 59,-5537 }, + { 60,-5537 }, { 61,-5537 }, { 62,-5537 }, { 63,-5537 }, { 64,-5537 }, + { 65,-5537 }, { 66,-5537 }, { 67,-5537 }, { 68,-5537 }, { 69,-5537 }, + { 70,-5537 }, { 71,-5537 }, { 72,-5537 }, { 73,-5537 }, { 74,-5537 }, + { 75,-5537 }, { 76,-5537 }, { 77,-5537 }, { 78,-5537 }, { 79,-5537 }, + { 80,-5537 }, { 81,-5537 }, { 82,-5537 }, { 83,-5537 }, { 84,-5537 }, + { 85,-4505 }, { 86,-5537 }, { 87,-5537 }, { 88,-5537 }, { 89,-5537 }, + { 90,-5537 }, { 91,-5537 }, { 92,-5537 }, { 93,-5537 }, { 94,-5537 }, + + { 95,-5537 }, { 96,-5537 }, { 97,-5537 }, { 98,-5537 }, { 99,-5537 }, + { 100,-5537 }, { 101,-5537 }, { 102,-5537 }, { 103,-5537 }, { 104,-5537 }, + { 105,-5537 }, { 106,-5537 }, { 107,-5537 }, { 108,-5537 }, { 109,-5537 }, + { 110,-5537 }, { 111,-5537 }, { 112,-5537 }, { 113,-5537 }, { 114,-5537 }, + { 115,-5537 }, { 116,-5537 }, { 117,-4505 }, { 118,-5537 }, { 119,-5537 }, + { 120,-5537 }, { 121,-5537 }, { 122,-5537 }, { 123,-5537 }, { 124,-5537 }, + { 125,-5537 }, { 126,-5537 }, { 127,-5537 }, { 128,-5537 }, { 129,-5537 }, + { 130,-5537 }, { 131,-5537 }, { 132,-5537 }, { 133,-5537 }, { 134,-5537 }, + { 135,-5537 }, { 136,-5537 }, { 137,-5537 }, { 138,-5537 }, { 139,-5537 }, + { 140,-5537 }, { 141,-5537 }, { 142,-5537 }, { 143,-5537 }, { 144,-5537 }, + + { 145,-5537 }, { 146,-5537 }, { 147,-5537 }, { 148,-5537 }, { 149,-5537 }, + { 150,-5537 }, { 151,-5537 }, { 152,-5537 }, { 153,-5537 }, { 154,-5537 }, + { 155,-5537 }, { 156,-5537 }, { 157,-5537 }, { 158,-5537 }, { 159,-5537 }, + { 160,-5537 }, { 161,-5537 }, { 162,-5537 }, { 163,-5537 }, { 164,-5537 }, + { 165,-5537 }, { 166,-5537 }, { 167,-5537 }, { 168,-5537 }, { 169,-5537 }, + { 170,-5537 }, { 171,-5537 }, { 172,-5537 }, { 173,-5537 }, { 174,-5537 }, + { 175,-5537 }, { 176,-5537 }, { 177,-5537 }, { 178,-5537 }, { 179,-5537 }, + { 180,-5537 }, { 181,-5537 }, { 182,-5537 }, { 183,-5537 }, { 184,-5537 }, + { 185,-5537 }, { 186,-5537 }, { 187,-5537 }, { 188,-5537 }, { 189,-5537 }, + { 190,-5537 }, { 191,-5537 }, { 192,-5537 }, { 193,-5537 }, { 194,-5537 }, + + { 195,-5537 }, { 196,-5537 }, { 197,-5537 }, { 198,-5537 }, { 199,-5537 }, + { 200,-5537 }, { 201,-5537 }, { 202,-5537 }, { 203,-5537 }, { 204,-5537 }, + { 205,-5537 }, { 206,-5537 }, { 207,-5537 }, { 208,-5537 }, { 209,-5537 }, + { 210,-5537 }, { 211,-5537 }, { 212,-5537 }, { 213,-5537 }, { 214,-5537 }, + { 215,-5537 }, { 216,-5537 }, { 217,-5537 }, { 218,-5537 }, { 219,-5537 }, + { 220,-5537 }, { 221,-5537 }, { 222,-5537 }, { 223,-5537 }, { 224,-5537 }, + { 225,-5537 }, { 226,-5537 }, { 227,-5537 }, { 228,-5537 }, { 229,-5537 }, + { 230,-5537 }, { 231,-5537 }, { 232,-5537 }, { 233,-5537 }, { 234,-5537 }, + { 235,-5537 }, { 236,-5537 }, { 237,-5537 }, { 238,-5537 }, { 239,-5537 }, + { 240,-5537 }, { 241,-5537 }, { 242,-5537 }, { 243,-5537 }, { 244,-5537 }, + + { 245,-5537 }, { 246,-5537 }, { 247,-5537 }, { 248,-5537 }, { 249,-5537 }, + { 250,-5537 }, { 251,-5537 }, { 252,-5537 }, { 253,-5537 }, { 254,-5537 }, + { 255,-5537 }, { 256,-5537 }, { 0, 48 }, { 0,11967 }, { 1,-5795 }, + { 2,-5795 }, { 3,-5795 }, { 4,-5795 }, { 5,-5795 }, { 6,-5795 }, + { 7,-5795 }, { 8,-5795 }, { 9,-5537 }, { 10,-16407 }, { 11,-5795 }, + { 12,-5537 }, { 13,-16407 }, { 14,-5795 }, { 15,-5795 }, { 16,-5795 }, + { 17,-5795 }, { 18,-5795 }, { 19,-5795 }, { 20,-5795 }, { 21,-5795 }, + { 22,-5795 }, { 23,-5795 }, { 24,-5795 }, { 25,-5795 }, { 26,-5795 }, + { 27,-5795 }, { 28,-5795 }, { 29,-5795 }, { 30,-5795 }, { 31,-5795 }, + { 32,-5537 }, { 33,-5795 }, { 34,-5795 }, { 35,-5795 }, { 36,-5795 }, + + { 37,-5795 }, { 38,-5795 }, { 39,5398 }, { 40,-5795 }, { 41,-5795 }, + { 42,-5795 }, { 43,-5795 }, { 44,-5795 }, { 45,-258 }, { 46,-5795 }, + { 47,-5795 }, { 48,-5795 }, { 49,-5795 }, { 50,-5795 }, { 51,-5795 }, + { 52,-5795 }, { 53,-5795 }, { 54,-5795 }, { 55,-5795 }, { 56,-5795 }, + { 57,-5795 }, { 58,-5795 }, { 59,-5795 }, { 60,-5795 }, { 61,-5795 }, + { 62,-5795 }, { 63,-5795 }, { 64,-5795 }, { 65,-5795 }, { 66,-5795 }, + { 67,-5795 }, { 68,-5795 }, { 69,-5795 }, { 70,-5795 }, { 71,-5795 }, + { 72,-5795 }, { 73,-5795 }, { 74,-5795 }, { 75,-5795 }, { 76,-5795 }, + { 77,-5795 }, { 78,-5795 }, { 79,-5795 }, { 80,-5795 }, { 81,-5795 }, + { 82,-5795 }, { 83,-5795 }, { 84,-5795 }, { 85,-4763 }, { 86,-5795 }, + + { 87,-5795 }, { 88,-5795 }, { 89,-5795 }, { 90,-5795 }, { 91,-5795 }, + { 92,-5795 }, { 93,-5795 }, { 94,-5795 }, { 95,-5795 }, { 96,-5795 }, + { 97,-5795 }, { 98,-5795 }, { 99,-5795 }, { 100,-5795 }, { 101,-5795 }, + { 102,-5795 }, { 103,-5795 }, { 104,-5795 }, { 105,-5795 }, { 106,-5795 }, + { 107,-5795 }, { 108,-5795 }, { 109,-5795 }, { 110,-5795 }, { 111,-5795 }, + { 112,-5795 }, { 113,-5795 }, { 114,-5795 }, { 115,-5795 }, { 116,-5795 }, + { 117,-4763 }, { 118,-5795 }, { 119,-5795 }, { 120,-5795 }, { 121,-5795 }, + { 122,-5795 }, { 123,-5795 }, { 124,-5795 }, { 125,-5795 }, { 126,-5795 }, + { 127,-5795 }, { 128,-5795 }, { 129,-5795 }, { 130,-5795 }, { 131,-5795 }, + { 132,-5795 }, { 133,-5795 }, { 134,-5795 }, { 135,-5795 }, { 136,-5795 }, + + { 137,-5795 }, { 138,-5795 }, { 139,-5795 }, { 140,-5795 }, { 141,-5795 }, + { 142,-5795 }, { 143,-5795 }, { 144,-5795 }, { 145,-5795 }, { 146,-5795 }, + { 147,-5795 }, { 148,-5795 }, { 149,-5795 }, { 150,-5795 }, { 151,-5795 }, + { 152,-5795 }, { 153,-5795 }, { 154,-5795 }, { 155,-5795 }, { 156,-5795 }, + { 157,-5795 }, { 158,-5795 }, { 159,-5795 }, { 160,-5795 }, { 161,-5795 }, + { 162,-5795 }, { 163,-5795 }, { 164,-5795 }, { 165,-5795 }, { 166,-5795 }, + { 167,-5795 }, { 168,-5795 }, { 169,-5795 }, { 170,-5795 }, { 171,-5795 }, + { 172,-5795 }, { 173,-5795 }, { 174,-5795 }, { 175,-5795 }, { 176,-5795 }, + { 177,-5795 }, { 178,-5795 }, { 179,-5795 }, { 180,-5795 }, { 181,-5795 }, + { 182,-5795 }, { 183,-5795 }, { 184,-5795 }, { 185,-5795 }, { 186,-5795 }, + + { 187,-5795 }, { 188,-5795 }, { 189,-5795 }, { 190,-5795 }, { 191,-5795 }, + { 192,-5795 }, { 193,-5795 }, { 194,-5795 }, { 195,-5795 }, { 196,-5795 }, + { 197,-5795 }, { 198,-5795 }, { 199,-5795 }, { 200,-5795 }, { 201,-5795 }, + { 202,-5795 }, { 203,-5795 }, { 204,-5795 }, { 205,-5795 }, { 206,-5795 }, + { 207,-5795 }, { 208,-5795 }, { 209,-5795 }, { 210,-5795 }, { 211,-5795 }, + { 212,-5795 }, { 213,-5795 }, { 214,-5795 }, { 215,-5795 }, { 216,-5795 }, + { 217,-5795 }, { 218,-5795 }, { 219,-5795 }, { 220,-5795 }, { 221,-5795 }, + { 222,-5795 }, { 223,-5795 }, { 224,-5795 }, { 225,-5795 }, { 226,-5795 }, + { 227,-5795 }, { 228,-5795 }, { 229,-5795 }, { 230,-5795 }, { 231,-5795 }, + { 232,-5795 }, { 233,-5795 }, { 234,-5795 }, { 235,-5795 }, { 236,-5795 }, + + { 237,-5795 }, { 238,-5795 }, { 239,-5795 }, { 240,-5795 }, { 241,-5795 }, + { 242,-5795 }, { 243,-5795 }, { 244,-5795 }, { 245,-5795 }, { 246,-5795 }, + { 247,-5795 }, { 248,-5795 }, { 249,-5795 }, { 250,-5795 }, { 251,-5795 }, + { 252,-5795 }, { 253,-5795 }, { 254,-5795 }, { 255,-5795 }, { 256,-5795 }, + { 0, 48 }, { 0,11709 }, { 1,-6053 }, { 2,-6053 }, { 3,-6053 }, + { 4,-6053 }, { 5,-6053 }, { 6,-6053 }, { 7,-6053 }, { 8,-6053 }, + { 9,-5795 }, { 10,-16665 }, { 11,-6053 }, { 12,-5795 }, { 13,-16665 }, + { 14,-6053 }, { 15,-6053 }, { 16,-6053 }, { 17,-6053 }, { 18,-6053 }, + { 19,-6053 }, { 20,-6053 }, { 21,-6053 }, { 22,-6053 }, { 23,-6053 }, + { 24,-6053 }, { 25,-6053 }, { 26,-6053 }, { 27,-6053 }, { 28,-6053 }, + + { 29,-6053 }, { 30,-6053 }, { 31,-6053 }, { 32,-5795 }, { 33,-6053 }, + { 34,-6053 }, { 35,-6053 }, { 36,-6053 }, { 37,-6053 }, { 38,-6053 }, + { 39,5140 }, { 40,-6053 }, { 41,-6053 }, { 42,-6053 }, { 43,-6053 }, + { 44,-6053 }, { 45,-516 }, { 46,-6053 }, { 47,-6053 }, { 48,-6053 }, + { 49,-6053 }, { 50,-6053 }, { 51,-6053 }, { 52,-6053 }, { 53,-6053 }, + { 54,-6053 }, { 55,-6053 }, { 56,-6053 }, { 57,-6053 }, { 58,-6053 }, + { 59,-6053 }, { 60,-6053 }, { 61,-6053 }, { 62,-6053 }, { 63,-6053 }, + { 64,-6053 }, { 65,-6053 }, { 66,-6053 }, { 67,-6053 }, { 68,-6053 }, + { 69,-6053 }, { 70,-6053 }, { 71,-6053 }, { 72,-6053 }, { 73,-6053 }, + { 74,-6053 }, { 75,-6053 }, { 76,-6053 }, { 77,-6053 }, { 78,-6053 }, + + { 79,-6053 }, { 80,-6053 }, { 81,-6053 }, { 82,-6053 }, { 83,-6053 }, + { 84,-6053 }, { 85,-5021 }, { 86,-6053 }, { 87,-6053 }, { 88,-6053 }, + { 89,-6053 }, { 90,-6053 }, { 91,-6053 }, { 92,-6053 }, { 93,-6053 }, + { 94,-6053 }, { 95,-6053 }, { 96,-6053 }, { 97,-6053 }, { 98,-6053 }, + { 99,-6053 }, { 100,-6053 }, { 101,-6053 }, { 102,-6053 }, { 103,-6053 }, + { 104,-6053 }, { 105,-6053 }, { 106,-6053 }, { 107,-6053 }, { 108,-6053 }, + { 109,-6053 }, { 110,-6053 }, { 111,-6053 }, { 112,-6053 }, { 113,-6053 }, + { 114,-6053 }, { 115,-6053 }, { 116,-6053 }, { 117,-5021 }, { 118,-6053 }, + { 119,-6053 }, { 120,-6053 }, { 121,-6053 }, { 122,-6053 }, { 123,-6053 }, + { 124,-6053 }, { 125,-6053 }, { 126,-6053 }, { 127,-6053 }, { 128,-6053 }, + + { 129,-6053 }, { 130,-6053 }, { 131,-6053 }, { 132,-6053 }, { 133,-6053 }, + { 134,-6053 }, { 135,-6053 }, { 136,-6053 }, { 137,-6053 }, { 138,-6053 }, + { 139,-6053 }, { 140,-6053 }, { 141,-6053 }, { 142,-6053 }, { 143,-6053 }, + { 144,-6053 }, { 145,-6053 }, { 146,-6053 }, { 147,-6053 }, { 148,-6053 }, + { 149,-6053 }, { 150,-6053 }, { 151,-6053 }, { 152,-6053 }, { 153,-6053 }, + { 154,-6053 }, { 155,-6053 }, { 156,-6053 }, { 157,-6053 }, { 158,-6053 }, + { 159,-6053 }, { 160,-6053 }, { 161,-6053 }, { 162,-6053 }, { 163,-6053 }, + { 164,-6053 }, { 165,-6053 }, { 166,-6053 }, { 167,-6053 }, { 168,-6053 }, + { 169,-6053 }, { 170,-6053 }, { 171,-6053 }, { 172,-6053 }, { 173,-6053 }, + { 174,-6053 }, { 175,-6053 }, { 176,-6053 }, { 177,-6053 }, { 178,-6053 }, + + { 179,-6053 }, { 180,-6053 }, { 181,-6053 }, { 182,-6053 }, { 183,-6053 }, + { 184,-6053 }, { 185,-6053 }, { 186,-6053 }, { 187,-6053 }, { 188,-6053 }, + { 189,-6053 }, { 190,-6053 }, { 191,-6053 }, { 192,-6053 }, { 193,-6053 }, + { 194,-6053 }, { 195,-6053 }, { 196,-6053 }, { 197,-6053 }, { 198,-6053 }, + { 199,-6053 }, { 200,-6053 }, { 201,-6053 }, { 202,-6053 }, { 203,-6053 }, + { 204,-6053 }, { 205,-6053 }, { 206,-6053 }, { 207,-6053 }, { 208,-6053 }, + { 209,-6053 }, { 210,-6053 }, { 211,-6053 }, { 212,-6053 }, { 213,-6053 }, + { 214,-6053 }, { 215,-6053 }, { 216,-6053 }, { 217,-6053 }, { 218,-6053 }, + { 219,-6053 }, { 220,-6053 }, { 221,-6053 }, { 222,-6053 }, { 223,-6053 }, + { 224,-6053 }, { 225,-6053 }, { 226,-6053 }, { 227,-6053 }, { 228,-6053 }, + + { 229,-6053 }, { 230,-6053 }, { 231,-6053 }, { 232,-6053 }, { 233,-6053 }, + { 234,-6053 }, { 235,-6053 }, { 236,-6053 }, { 237,-6053 }, { 238,-6053 }, + { 239,-6053 }, { 240,-6053 }, { 241,-6053 }, { 242,-6053 }, { 243,-6053 }, + { 244,-6053 }, { 245,-6053 }, { 246,-6053 }, { 247,-6053 }, { 248,-6053 }, + { 249,-6053 }, { 250,-6053 }, { 251,-6053 }, { 252,-6053 }, { 253,-6053 }, + { 254,-6053 }, { 255,-6053 }, { 256,-6053 }, { 0, 48 }, { 0,11451 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 9,-16923 }, { 10,-16923 }, + { 0, 0 }, { 12,-16923 }, { 13,-16923 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 32,-16923 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 39,-4763 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 45,-41767 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 85,-46406 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 117,-46406 }, { 0, 48 }, { 0,11332 }, { 1,-6430 }, + + { 2,-6430 }, { 3,-6430 }, { 4,-6430 }, { 5,-6430 }, { 6,-6430 }, + { 7,-6430 }, { 8,-6430 }, { 9,-6172 }, { 10,-17042 }, { 11,-6430 }, + { 12,-6172 }, { 13,-17042 }, { 14,-6430 }, { 15,-6430 }, { 16,-6430 }, + { 17,-6430 }, { 18,-6430 }, { 19,-6430 }, { 20,-6430 }, { 21,-6430 }, + { 22,-6430 }, { 23,-6430 }, { 24,-6430 }, { 25,-6430 }, { 26,-6430 }, + { 27,-6430 }, { 28,-6430 }, { 29,-6430 }, { 30,-6430 }, { 31,-6430 }, + { 32,-6172 }, { 33,-6430 }, { 34,-6430 }, { 35,-6430 }, { 36,-6430 }, + { 37,-6430 }, { 38,-6430 }, { 39,4763 }, { 40,-6430 }, { 41,-6430 }, + { 42,-6430 }, { 43,-6430 }, { 44,-6430 }, { 45, 516 }, { 46,-6430 }, + { 47,-6430 }, { 48,-6430 }, { 49,-6430 }, { 50,-6430 }, { 51,-6430 }, + + { 52,-6430 }, { 53,-6430 }, { 54,-6430 }, { 55,-6430 }, { 56,-6430 }, + { 57,-6430 }, { 58,-6430 }, { 59,-6430 }, { 60,-6430 }, { 61,-6430 }, + { 62,-6430 }, { 63,-6430 }, { 64,-6430 }, { 65,-6430 }, { 66,-6430 }, + { 67,-6430 }, { 68,-6430 }, { 69,-6430 }, { 70,-6430 }, { 71,-6430 }, + { 72,-6430 }, { 73,-6430 }, { 74,-6430 }, { 75,-6430 }, { 76,-6430 }, + { 77,-6430 }, { 78,-6430 }, { 79,-6430 }, { 80,-6430 }, { 81,-6430 }, + { 82,-6430 }, { 83,-6430 }, { 84,-6430 }, { 85,-5398 }, { 86,-6430 }, + { 87,-6430 }, { 88,-6430 }, { 89,-6430 }, { 90,-6430 }, { 91,-6430 }, + { 92,-6430 }, { 93,-6430 }, { 94,-6430 }, { 95,-6430 }, { 96,-6430 }, + { 97,-6430 }, { 98,-6430 }, { 99,-6430 }, { 100,-6430 }, { 101,-6430 }, + + { 102,-6430 }, { 103,-6430 }, { 104,-6430 }, { 105,-6430 }, { 106,-6430 }, + { 107,-6430 }, { 108,-6430 }, { 109,-6430 }, { 110,-6430 }, { 111,-6430 }, + { 112,-6430 }, { 113,-6430 }, { 114,-6430 }, { 115,-6430 }, { 116,-6430 }, + { 117,-5398 }, { 118,-6430 }, { 119,-6430 }, { 120,-6430 }, { 121,-6430 }, + { 122,-6430 }, { 123,-6430 }, { 124,-6430 }, { 125,-6430 }, { 126,-6430 }, + { 127,-6430 }, { 128,-6430 }, { 129,-6430 }, { 130,-6430 }, { 131,-6430 }, + { 132,-6430 }, { 133,-6430 }, { 134,-6430 }, { 135,-6430 }, { 136,-6430 }, + { 137,-6430 }, { 138,-6430 }, { 139,-6430 }, { 140,-6430 }, { 141,-6430 }, + { 142,-6430 }, { 143,-6430 }, { 144,-6430 }, { 145,-6430 }, { 146,-6430 }, + { 147,-6430 }, { 148,-6430 }, { 149,-6430 }, { 150,-6430 }, { 151,-6430 }, + + { 152,-6430 }, { 153,-6430 }, { 154,-6430 }, { 155,-6430 }, { 156,-6430 }, + { 157,-6430 }, { 158,-6430 }, { 159,-6430 }, { 160,-6430 }, { 161,-6430 }, + { 162,-6430 }, { 163,-6430 }, { 164,-6430 }, { 165,-6430 }, { 166,-6430 }, + { 167,-6430 }, { 168,-6430 }, { 169,-6430 }, { 170,-6430 }, { 171,-6430 }, + { 172,-6430 }, { 173,-6430 }, { 174,-6430 }, { 175,-6430 }, { 176,-6430 }, + { 177,-6430 }, { 178,-6430 }, { 179,-6430 }, { 180,-6430 }, { 181,-6430 }, + { 182,-6430 }, { 183,-6430 }, { 184,-6430 }, { 185,-6430 }, { 186,-6430 }, + { 187,-6430 }, { 188,-6430 }, { 189,-6430 }, { 190,-6430 }, { 191,-6430 }, + { 192,-6430 }, { 193,-6430 }, { 194,-6430 }, { 195,-6430 }, { 196,-6430 }, + { 197,-6430 }, { 198,-6430 }, { 199,-6430 }, { 200,-6430 }, { 201,-6430 }, + + { 202,-6430 }, { 203,-6430 }, { 204,-6430 }, { 205,-6430 }, { 206,-6430 }, + { 207,-6430 }, { 208,-6430 }, { 209,-6430 }, { 210,-6430 }, { 211,-6430 }, + { 212,-6430 }, { 213,-6430 }, { 214,-6430 }, { 215,-6430 }, { 216,-6430 }, + { 217,-6430 }, { 218,-6430 }, { 219,-6430 }, { 220,-6430 }, { 221,-6430 }, + { 222,-6430 }, { 223,-6430 }, { 224,-6430 }, { 225,-6430 }, { 226,-6430 }, + { 227,-6430 }, { 228,-6430 }, { 229,-6430 }, { 230,-6430 }, { 231,-6430 }, + { 232,-6430 }, { 233,-6430 }, { 234,-6430 }, { 235,-6430 }, { 236,-6430 }, + { 237,-6430 }, { 238,-6430 }, { 239,-6430 }, { 240,-6430 }, { 241,-6430 }, + { 242,-6430 }, { 243,-6430 }, { 244,-6430 }, { 245,-6430 }, { 246,-6430 }, + { 247,-6430 }, { 248,-6430 }, { 249,-6430 }, { 250,-6430 }, { 251,-6430 }, + + { 252,-6430 }, { 253,-6430 }, { 254,-6430 }, { 255,-6430 }, { 256,-6430 }, + { 0, 48 }, { 0,11074 }, { 1,-6688 }, { 2,-6688 }, { 3,-6688 }, + { 4,-6688 }, { 5,-6688 }, { 6,-6688 }, { 7,-6688 }, { 8,-6688 }, + { 9,-6430 }, { 10,-17300 }, { 11,-6688 }, { 12,-6430 }, { 13,-17300 }, + { 14,-6688 }, { 15,-6688 }, { 16,-6688 }, { 17,-6688 }, { 18,-6688 }, + { 19,-6688 }, { 20,-6688 }, { 21,-6688 }, { 22,-6688 }, { 23,-6688 }, + { 24,-6688 }, { 25,-6688 }, { 26,-6688 }, { 27,-6688 }, { 28,-6688 }, + { 29,-6688 }, { 30,-6688 }, { 31,-6688 }, { 32,-6430 }, { 33,-6688 }, + { 34,-6688 }, { 35,-6688 }, { 36,-6688 }, { 37,-6688 }, { 38,-6688 }, + { 39,4505 }, { 40,-6688 }, { 41,-6688 }, { 42,-6688 }, { 43,-6688 }, + + { 44,-6688 }, { 45,-1151 }, { 46,-6688 }, { 47,-6688 }, { 48,-6688 }, + { 49,-6688 }, { 50,-6688 }, { 51,-6688 }, { 52,-6688 }, { 53,-6688 }, + { 54,-6688 }, { 55,-6688 }, { 56,-6688 }, { 57,-6688 }, { 58,-6688 }, + { 59,-6688 }, { 60,-6688 }, { 61,-6688 }, { 62,-6688 }, { 63,-6688 }, + { 64,-6688 }, { 65,-6688 }, { 66,-6688 }, { 67,-6688 }, { 68,-6688 }, + { 69, 516 }, { 70,-6688 }, { 71,-6688 }, { 72,-6688 }, { 73,-6688 }, + { 74,-6688 }, { 75,-6688 }, { 76,-6688 }, { 77,-6688 }, { 78,-6688 }, + { 79,-6688 }, { 80,-6688 }, { 81,-6688 }, { 82,-6688 }, { 83,-6688 }, + { 84,-6688 }, { 85,-5656 }, { 86,-6688 }, { 87,-6688 }, { 88,-6688 }, + { 89,-6688 }, { 90,-6688 }, { 91,-6688 }, { 92,-6688 }, { 93,-6688 }, + + { 94,-6688 }, { 95,-6688 }, { 96,-6688 }, { 97,-6688 }, { 98,-6688 }, + { 99,-6688 }, { 100,-6688 }, { 101, 516 }, { 102,-6688 }, { 103,-6688 }, + { 104,-6688 }, { 105,-6688 }, { 106,-6688 }, { 107,-6688 }, { 108,-6688 }, + { 109,-6688 }, { 110,-6688 }, { 111,-6688 }, { 112,-6688 }, { 113,-6688 }, + { 114,-6688 }, { 115,-6688 }, { 116,-6688 }, { 117,-5656 }, { 118,-6688 }, + { 119,-6688 }, { 120,-6688 }, { 121,-6688 }, { 122,-6688 }, { 123,-6688 }, + { 124,-6688 }, { 125,-6688 }, { 126,-6688 }, { 127,-6688 }, { 128,-6688 }, + { 129,-6688 }, { 130,-6688 }, { 131,-6688 }, { 132,-6688 }, { 133,-6688 }, + { 134,-6688 }, { 135,-6688 }, { 136,-6688 }, { 137,-6688 }, { 138,-6688 }, + { 139,-6688 }, { 140,-6688 }, { 141,-6688 }, { 142,-6688 }, { 143,-6688 }, + + { 144,-6688 }, { 145,-6688 }, { 146,-6688 }, { 147,-6688 }, { 148,-6688 }, + { 149,-6688 }, { 150,-6688 }, { 151,-6688 }, { 152,-6688 }, { 153,-6688 }, + { 154,-6688 }, { 155,-6688 }, { 156,-6688 }, { 157,-6688 }, { 158,-6688 }, + { 159,-6688 }, { 160,-6688 }, { 161,-6688 }, { 162,-6688 }, { 163,-6688 }, + { 164,-6688 }, { 165,-6688 }, { 166,-6688 }, { 167,-6688 }, { 168,-6688 }, + { 169,-6688 }, { 170,-6688 }, { 171,-6688 }, { 172,-6688 }, { 173,-6688 }, + { 174,-6688 }, { 175,-6688 }, { 176,-6688 }, { 177,-6688 }, { 178,-6688 }, + { 179,-6688 }, { 180,-6688 }, { 181,-6688 }, { 182,-6688 }, { 183,-6688 }, + { 184,-6688 }, { 185,-6688 }, { 186,-6688 }, { 187,-6688 }, { 188,-6688 }, + { 189,-6688 }, { 190,-6688 }, { 191,-6688 }, { 192,-6688 }, { 193,-6688 }, + + { 194,-6688 }, { 195,-6688 }, { 196,-6688 }, { 197,-6688 }, { 198,-6688 }, + { 199,-6688 }, { 200,-6688 }, { 201,-6688 }, { 202,-6688 }, { 203,-6688 }, + { 204,-6688 }, { 205,-6688 }, { 206,-6688 }, { 207,-6688 }, { 208,-6688 }, + { 209,-6688 }, { 210,-6688 }, { 211,-6688 }, { 212,-6688 }, { 213,-6688 }, + { 214,-6688 }, { 215,-6688 }, { 216,-6688 }, { 217,-6688 }, { 218,-6688 }, + { 219,-6688 }, { 220,-6688 }, { 221,-6688 }, { 222,-6688 }, { 223,-6688 }, + { 224,-6688 }, { 225,-6688 }, { 226,-6688 }, { 227,-6688 }, { 228,-6688 }, + { 229,-6688 }, { 230,-6688 }, { 231,-6688 }, { 232,-6688 }, { 233,-6688 }, + { 234,-6688 }, { 235,-6688 }, { 236,-6688 }, { 237,-6688 }, { 238,-6688 }, + { 239,-6688 }, { 240,-6688 }, { 241,-6688 }, { 242,-6688 }, { 243,-6688 }, + + { 244,-6688 }, { 245,-6688 }, { 246,-6688 }, { 247,-6688 }, { 248,-6688 }, + { 249,-6688 }, { 250,-6688 }, { 251,-6688 }, { 252,-6688 }, { 253,-6688 }, + { 254,-6688 }, { 255,-6688 }, { 256,-6688 }, { 0, 48 }, { 0,10816 }, + { 1,-6946 }, { 2,-6946 }, { 3,-6946 }, { 4,-6946 }, { 5,-6946 }, + { 6,-6946 }, { 7,-6946 }, { 8,-6946 }, { 9,-6688 }, { 10,-17558 }, + { 11,-6946 }, { 12,-6688 }, { 13,-17558 }, { 14,-6946 }, { 15,-6946 }, + { 16,-6946 }, { 17,-6946 }, { 18,-6946 }, { 19,-6946 }, { 20,-6946 }, + { 21,-6946 }, { 22,-6946 }, { 23,-6946 }, { 24,-6946 }, { 25,-6946 }, + { 26,-6946 }, { 27,-6946 }, { 28,-6946 }, { 29,-6946 }, { 30,-6946 }, + { 31,-6946 }, { 32,-6688 }, { 33,-6946 }, { 34,-6946 }, { 35,-6946 }, + + { 36,-6946 }, { 37,-6946 }, { 38,-6946 }, { 39,-6430 }, { 40,-6946 }, + { 41,-6946 }, { 42,-6946 }, { 43,-6946 }, { 44,-6946 }, { 45, 0 }, + { 46,-6946 }, { 47,-6946 }, { 48,-6946 }, { 49,-6946 }, { 50,-6946 }, + { 51,-6946 }, { 52,-6946 }, { 53,-6946 }, { 54,-6946 }, { 55,-6946 }, + { 56,-6946 }, { 57,-6946 }, { 58,-6946 }, { 59,-6946 }, { 60,-6946 }, + { 61,-6946 }, { 62,-6946 }, { 63,-6946 }, { 64,-6946 }, { 65,-6946 }, + { 66,-6946 }, { 67,-6946 }, { 68,-6946 }, { 69,-6946 }, { 70,-6946 }, + { 71,-6946 }, { 72,-6946 }, { 73,-6946 }, { 74,-6946 }, { 75,-6946 }, + { 76,-6946 }, { 77,-6946 }, { 78,-6946 }, { 79,-6946 }, { 80,-6946 }, + { 81,-6946 }, { 82,-6946 }, { 83,-6946 }, { 84,-6946 }, { 85,-5914 }, + + { 86,-6946 }, { 87,-6946 }, { 88,-6946 }, { 89,-6946 }, { 90,-6946 }, + { 91,-6946 }, { 92,-6946 }, { 93,-6946 }, { 94,-6946 }, { 95,-6946 }, + { 96,-6946 }, { 97,-6946 }, { 98,-6946 }, { 99,-6946 }, { 100,-6946 }, + { 101,-6946 }, { 102,-6946 }, { 103,-6946 }, { 104,-6946 }, { 105,-6946 }, + { 106,-6946 }, { 107,-6946 }, { 108,-6946 }, { 109,-6946 }, { 110,-6946 }, + { 111,-6946 }, { 112,-6946 }, { 113,-6946 }, { 114,-6946 }, { 115,-6946 }, + { 116,-6946 }, { 117,-5914 }, { 118,-6946 }, { 119,-6946 }, { 120,-6946 }, + { 121,-6946 }, { 122,-6946 }, { 123,-6946 }, { 124,-6946 }, { 125,-6946 }, + { 126,-6946 }, { 127,-6946 }, { 128,-6946 }, { 129,-6946 }, { 130,-6946 }, + { 131,-6946 }, { 132,-6946 }, { 133,-6946 }, { 134,-6946 }, { 135,-6946 }, + + { 136,-6946 }, { 137,-6946 }, { 138,-6946 }, { 139,-6946 }, { 140,-6946 }, + { 141,-6946 }, { 142,-6946 }, { 143,-6946 }, { 144,-6946 }, { 145,-6946 }, + { 146,-6946 }, { 147,-6946 }, { 148,-6946 }, { 149,-6946 }, { 150,-6946 }, + { 151,-6946 }, { 152,-6946 }, { 153,-6946 }, { 154,-6946 }, { 155,-6946 }, + { 156,-6946 }, { 157,-6946 }, { 158,-6946 }, { 159,-6946 }, { 160,-6946 }, + { 161,-6946 }, { 162,-6946 }, { 163,-6946 }, { 164,-6946 }, { 165,-6946 }, + { 166,-6946 }, { 167,-6946 }, { 168,-6946 }, { 169,-6946 }, { 170,-6946 }, + { 171,-6946 }, { 172,-6946 }, { 173,-6946 }, { 174,-6946 }, { 175,-6946 }, + { 176,-6946 }, { 177,-6946 }, { 178,-6946 }, { 179,-6946 }, { 180,-6946 }, + { 181,-6946 }, { 182,-6946 }, { 183,-6946 }, { 184,-6946 }, { 185,-6946 }, + + { 186,-6946 }, { 187,-6946 }, { 188,-6946 }, { 189,-6946 }, { 190,-6946 }, + { 191,-6946 }, { 192,-6946 }, { 193,-6946 }, { 194,-6946 }, { 195,-6946 }, + { 196,-6946 }, { 197,-6946 }, { 198,-6946 }, { 199,-6946 }, { 200,-6946 }, + { 201,-6946 }, { 202,-6946 }, { 203,-6946 }, { 204,-6946 }, { 205,-6946 }, + { 206,-6946 }, { 207,-6946 }, { 208,-6946 }, { 209,-6946 }, { 210,-6946 }, + { 211,-6946 }, { 212,-6946 }, { 213,-6946 }, { 214,-6946 }, { 215,-6946 }, + { 216,-6946 }, { 217,-6946 }, { 218,-6946 }, { 219,-6946 }, { 220,-6946 }, + { 221,-6946 }, { 222,-6946 }, { 223,-6946 }, { 224,-6946 }, { 225,-6946 }, + { 226,-6946 }, { 227,-6946 }, { 228,-6946 }, { 229,-6946 }, { 230,-6946 }, + { 231,-6946 }, { 232,-6946 }, { 233,-6946 }, { 234,-6946 }, { 235,-6946 }, + + { 236,-6946 }, { 237,-6946 }, { 238,-6946 }, { 239,-6946 }, { 240,-6946 }, + { 241,-6946 }, { 242,-6946 }, { 243,-6946 }, { 244,-6946 }, { 245,-6946 }, + { 246,-6946 }, { 247,-6946 }, { 248,-6946 }, { 249,-6946 }, { 250,-6946 }, + { 251,-6946 }, { 252,-6946 }, { 253,-6946 }, { 254,-6946 }, { 255,-6946 }, + { 256,-6946 }, { 0, 48 }, { 0,10558 }, { 1,-7204 }, { 2,-7204 }, + { 3,-7204 }, { 4,-7204 }, { 5,-7204 }, { 6,-7204 }, { 7,-7204 }, + { 8,-7204 }, { 9,-6946 }, { 10,-17816 }, { 11,-7204 }, { 12,-6946 }, + { 13,-17816 }, { 14,-7204 }, { 15,-7204 }, { 16,-7204 }, { 17,-7204 }, + { 18,-7204 }, { 19,-7204 }, { 20,-7204 }, { 21,-7204 }, { 22,-7204 }, + { 23,-7204 }, { 24,-7204 }, { 25,-7204 }, { 26,-7204 }, { 27,-7204 }, + + { 28,-7204 }, { 29,-7204 }, { 30,-7204 }, { 31,-7204 }, { 32,-6946 }, + { 33,-7204 }, { 34,-7204 }, { 35,-7204 }, { 36,-7204 }, { 37,-7204 }, + { 38,-7204 }, { 39,-6688 }, { 40,-7204 }, { 41,-7204 }, { 42,-7204 }, + { 43,-7204 }, { 44,-7204 }, { 45,-1667 }, { 46,-7204 }, { 47,-7204 }, + { 48,-7204 }, { 49,-7204 }, { 50,-7204 }, { 51,-7204 }, { 52,-7204 }, + { 53,-7204 }, { 54,-7204 }, { 55,-7204 }, { 56,-7204 }, { 57,-7204 }, + { 58,-7204 }, { 59,-7204 }, { 60,-7204 }, { 61,-7204 }, { 62,-7204 }, + { 63,-7204 }, { 64,-7204 }, { 65,-7204 }, { 66,-7204 }, { 67,-7204 }, + { 68,-7204 }, { 69,-7204 }, { 70,-7204 }, { 71,-7204 }, { 72,-7204 }, + { 73,-7204 }, { 74,-7204 }, { 75,-7204 }, { 76,-7204 }, { 77,-7204 }, + + { 78,-7204 }, { 79,-7204 }, { 80,-7204 }, { 81,-7204 }, { 82,-7204 }, + { 83,4247 }, { 84,-7204 }, { 85,-6172 }, { 86,-7204 }, { 87,-7204 }, + { 88,-7204 }, { 89,-7204 }, { 90,-7204 }, { 91,-7204 }, { 92,-7204 }, + { 93,-7204 }, { 94,-7204 }, { 95,-7204 }, { 96,-7204 }, { 97,-7204 }, + { 98,-7204 }, { 99,-7204 }, { 100,-7204 }, { 101,-7204 }, { 102,-7204 }, + { 103,-7204 }, { 104,-7204 }, { 105,-7204 }, { 106,-7204 }, { 107,-7204 }, + { 108,-7204 }, { 109,-7204 }, { 110,-7204 }, { 111,-7204 }, { 112,-7204 }, + { 113,-7204 }, { 114,-7204 }, { 115,4247 }, { 116,-7204 }, { 117,-6172 }, + { 118,-7204 }, { 119,-7204 }, { 120,-7204 }, { 121,-7204 }, { 122,-7204 }, + { 123,-7204 }, { 124,-7204 }, { 125,-7204 }, { 126,-7204 }, { 127,-7204 }, + + { 128,-7204 }, { 129,-7204 }, { 130,-7204 }, { 131,-7204 }, { 132,-7204 }, + { 133,-7204 }, { 134,-7204 }, { 135,-7204 }, { 136,-7204 }, { 137,-7204 }, + { 138,-7204 }, { 139,-7204 }, { 140,-7204 }, { 141,-7204 }, { 142,-7204 }, + { 143,-7204 }, { 144,-7204 }, { 145,-7204 }, { 146,-7204 }, { 147,-7204 }, + { 148,-7204 }, { 149,-7204 }, { 150,-7204 }, { 151,-7204 }, { 152,-7204 }, + { 153,-7204 }, { 154,-7204 }, { 155,-7204 }, { 156,-7204 }, { 157,-7204 }, + { 158,-7204 }, { 159,-7204 }, { 160,-7204 }, { 161,-7204 }, { 162,-7204 }, + { 163,-7204 }, { 164,-7204 }, { 165,-7204 }, { 166,-7204 }, { 167,-7204 }, + { 168,-7204 }, { 169,-7204 }, { 170,-7204 }, { 171,-7204 }, { 172,-7204 }, + { 173,-7204 }, { 174,-7204 }, { 175,-7204 }, { 176,-7204 }, { 177,-7204 }, + + { 178,-7204 }, { 179,-7204 }, { 180,-7204 }, { 181,-7204 }, { 182,-7204 }, + { 183,-7204 }, { 184,-7204 }, { 185,-7204 }, { 186,-7204 }, { 187,-7204 }, + { 188,-7204 }, { 189,-7204 }, { 190,-7204 }, { 191,-7204 }, { 192,-7204 }, + { 193,-7204 }, { 194,-7204 }, { 195,-7204 }, { 196,-7204 }, { 197,-7204 }, + { 198,-7204 }, { 199,-7204 }, { 200,-7204 }, { 201,-7204 }, { 202,-7204 }, + { 203,-7204 }, { 204,-7204 }, { 205,-7204 }, { 206,-7204 }, { 207,-7204 }, + { 208,-7204 }, { 209,-7204 }, { 210,-7204 }, { 211,-7204 }, { 212,-7204 }, + { 213,-7204 }, { 214,-7204 }, { 215,-7204 }, { 216,-7204 }, { 217,-7204 }, + { 218,-7204 }, { 219,-7204 }, { 220,-7204 }, { 221,-7204 }, { 222,-7204 }, + { 223,-7204 }, { 224,-7204 }, { 225,-7204 }, { 226,-7204 }, { 227,-7204 }, + + { 228,-7204 }, { 229,-7204 }, { 230,-7204 }, { 231,-7204 }, { 232,-7204 }, + { 233,-7204 }, { 234,-7204 }, { 235,-7204 }, { 236,-7204 }, { 237,-7204 }, + { 238,-7204 }, { 239,-7204 }, { 240,-7204 }, { 241,-7204 }, { 242,-7204 }, + { 243,-7204 }, { 244,-7204 }, { 245,-7204 }, { 246,-7204 }, { 247,-7204 }, + { 248,-7204 }, { 249,-7204 }, { 250,-7204 }, { 251,-7204 }, { 252,-7204 }, + { 253,-7204 }, { 254,-7204 }, { 255,-7204 }, { 256,-7204 }, { 0, 24 }, + { 0,10300 }, { 1,-26792 }, { 2,-26792 }, { 3,-26792 }, { 4,-26792 }, + { 5,-26792 }, { 6,-26792 }, { 7,-26792 }, { 8,-26792 }, { 9,-26534 }, + { 10,-26276 }, { 11,-26792 }, { 12,-26534 }, { 13,-26276 }, { 14,-26792 }, + { 15,-26792 }, { 16,-26792 }, { 17,-26792 }, { 18,-26792 }, { 19,-26792 }, + + { 20,-26792 }, { 21,-26792 }, { 22,-26792 }, { 23,-26792 }, { 24,-26792 }, + { 25,-26792 }, { 26,-26792 }, { 27,-26792 }, { 28,-26792 }, { 29,-26792 }, + { 30,-26792 }, { 31,-26792 }, { 32,-26534 }, { 33,-26792 }, { 34,-26792 }, + { 35,-26792 }, { 36,-26792 }, { 37,-26792 }, { 38,-26792 }, { 39,-26792 }, + { 40,-26792 }, { 41,-26792 }, { 42,-26792 }, { 43,-26792 }, { 44,-26792 }, + { 45,-26157 }, { 46,-26792 }, { 47,-26792 }, { 48,-26792 }, { 49,-26792 }, + { 50,-26792 }, { 51,-26792 }, { 52,-26792 }, { 53,-26792 }, { 54,-26792 }, + { 55,-26792 }, { 56,-26792 }, { 57,-26792 }, { 58,-26792 }, { 59,-26792 }, + { 60,-26792 }, { 61,-26792 }, { 62,-26792 }, { 63,-26792 }, { 64,-26792 }, + { 65,-26792 }, { 66,-26792 }, { 67,-26792 }, { 68,-26792 }, { 69,-26792 }, + + { 70,-26792 }, { 71,-26792 }, { 72,-26792 }, { 73,-26792 }, { 74,-26792 }, + { 75,-26792 }, { 76,-26792 }, { 77,-26792 }, { 78,-26792 }, { 79,-26792 }, + { 80,-26792 }, { 81,-26792 }, { 82,-26792 }, { 83,-26792 }, { 84,-26792 }, + { 85,-25899 }, { 86,-26792 }, { 87,-26792 }, { 88,-26792 }, { 89,-26792 }, + { 90,-26792 }, { 91,-26792 }, { 92,-26792 }, { 93,-26792 }, { 94,-26792 }, + { 95,-26792 }, { 96,-26792 }, { 97,-26792 }, { 98,-26792 }, { 99,-26792 }, + { 100,-26792 }, { 101,-26792 }, { 102,-26792 }, { 103,-26792 }, { 104,-26792 }, + { 105,-26792 }, { 106,-26792 }, { 107,-26792 }, { 108,-26792 }, { 109,-26792 }, + { 110,-26792 }, { 111,-26792 }, { 112,-26792 }, { 113,-26792 }, { 114,-26792 }, + { 115,-26792 }, { 116,-26792 }, { 117,-25899 }, { 118,-26792 }, { 119,-26792 }, + + { 120,-26792 }, { 121,-26792 }, { 122,-26792 }, { 123,-26792 }, { 124,-26792 }, + { 125,-26792 }, { 126,-26792 }, { 127,-26792 }, { 128,-26792 }, { 129,-26792 }, + { 130,-26792 }, { 131,-26792 }, { 132,-26792 }, { 133,-26792 }, { 134,-26792 }, + { 135,-26792 }, { 136,-26792 }, { 137,-26792 }, { 138,-26792 }, { 139,-26792 }, + { 140,-26792 }, { 141,-26792 }, { 142,-26792 }, { 143,-26792 }, { 144,-26792 }, + { 145,-26792 }, { 146,-26792 }, { 147,-26792 }, { 148,-26792 }, { 149,-26792 }, + { 150,-26792 }, { 151,-26792 }, { 152,-26792 }, { 153,-26792 }, { 154,-26792 }, + { 155,-26792 }, { 156,-26792 }, { 157,-26792 }, { 158,-26792 }, { 159,-26792 }, + { 160,-26792 }, { 161,-26792 }, { 162,-26792 }, { 163,-26792 }, { 164,-26792 }, + { 165,-26792 }, { 166,-26792 }, { 167,-26792 }, { 168,-26792 }, { 169,-26792 }, + + { 170,-26792 }, { 171,-26792 }, { 172,-26792 }, { 173,-26792 }, { 174,-26792 }, + { 175,-26792 }, { 176,-26792 }, { 177,-26792 }, { 178,-26792 }, { 179,-26792 }, + { 180,-26792 }, { 181,-26792 }, { 182,-26792 }, { 183,-26792 }, { 184,-26792 }, + { 185,-26792 }, { 186,-26792 }, { 187,-26792 }, { 188,-26792 }, { 189,-26792 }, + { 190,-26792 }, { 191,-26792 }, { 192,-26792 }, { 193,-26792 }, { 194,-26792 }, + { 195,-26792 }, { 196,-26792 }, { 197,-26792 }, { 198,-26792 }, { 199,-26792 }, + { 200,-26792 }, { 201,-26792 }, { 202,-26792 }, { 203,-26792 }, { 204,-26792 }, + { 205,-26792 }, { 206,-26792 }, { 207,-26792 }, { 208,-26792 }, { 209,-26792 }, + { 210,-26792 }, { 211,-26792 }, { 212,-26792 }, { 213,-26792 }, { 214,-26792 }, + { 215,-26792 }, { 216,-26792 }, { 217,-26792 }, { 218,-26792 }, { 219,-26792 }, + + { 220,-26792 }, { 221,-26792 }, { 222,-26792 }, { 223,-26792 }, { 224,-26792 }, + { 225,-26792 }, { 226,-26792 }, { 227,-26792 }, { 228,-26792 }, { 229,-26792 }, + { 230,-26792 }, { 231,-26792 }, { 232,-26792 }, { 233,-26792 }, { 234,-26792 }, + { 235,-26792 }, { 236,-26792 }, { 237,-26792 }, { 238,-26792 }, { 239,-26792 }, + { 240,-26792 }, { 241,-26792 }, { 242,-26792 }, { 243,-26792 }, { 244,-26792 }, + { 245,-26792 }, { 246,-26792 }, { 247,-26792 }, { 248,-26792 }, { 249,-26792 }, + { 250,-26792 }, { 251,-26792 }, { 252,-26792 }, { 253,-26792 }, { 254,-26792 }, + { 255,-26792 }, { 256,-26792 }, { 0, 24 }, { 0,10042 }, { 1, 0 }, + { 2, 0 }, { 3, 0 }, { 4, 0 }, { 5, 0 }, { 6, 0 }, + { 7, 0 }, { 8, 0 }, { 9, 258 }, { 10,-11736 }, { 11, 0 }, + + { 12, 258 }, { 13,-11736 }, { 14, 0 }, { 15, 0 }, { 16, 0 }, + { 17, 0 }, { 18, 0 }, { 19, 0 }, { 20, 0 }, { 21, 0 }, + { 22, 0 }, { 23, 0 }, { 24, 0 }, { 25, 0 }, { 26, 0 }, + { 27, 0 }, { 28, 0 }, { 29, 0 }, { 30, 0 }, { 31, 0 }, + { 32, 258 }, { 33, 0 }, { 34, 0 }, { 35, 0 }, { 36, 0 }, + { 37, 0 }, { 38, 0 }, { 39, 516 }, { 40, 0 }, { 41, 0 }, + { 42, 0 }, { 43, 0 }, { 44, 0 }, { 45,1290 }, { 46, 0 }, + { 47, 0 }, { 48, 0 }, { 49, 0 }, { 50, 0 }, { 51, 0 }, + { 52, 0 }, { 53, 0 }, { 54, 0 }, { 55, 0 }, { 56, 0 }, + { 57, 0 }, { 58, 0 }, { 59, 0 }, { 60, 0 }, { 61, 0 }, + + { 62, 0 }, { 63, 0 }, { 64, 0 }, { 65, 0 }, { 66, 0 }, + { 67, 0 }, { 68, 0 }, { 69, 0 }, { 70, 0 }, { 71, 0 }, + { 72, 0 }, { 73, 0 }, { 74, 0 }, { 75, 0 }, { 76, 0 }, + { 77, 0 }, { 78, 0 }, { 79, 0 }, { 80, 0 }, { 81, 0 }, + { 82, 0 }, { 83, 0 }, { 84, 0 }, { 85,1032 }, { 86, 0 }, + { 87, 0 }, { 88, 0 }, { 89, 0 }, { 90, 0 }, { 91, 0 }, + { 92, 0 }, { 93, 0 }, { 94, 0 }, { 95, 0 }, { 96, 0 }, + { 97, 0 }, { 98, 0 }, { 99, 0 }, { 100, 0 }, { 101, 0 }, + { 102, 0 }, { 103, 0 }, { 104, 0 }, { 105, 0 }, { 106, 0 }, + { 107, 0 }, { 108, 0 }, { 109, 0 }, { 110, 0 }, { 111, 0 }, + + { 112, 0 }, { 113, 0 }, { 114, 0 }, { 115, 0 }, { 116, 0 }, + { 117,1032 }, { 118, 0 }, { 119, 0 }, { 120, 0 }, { 121, 0 }, + { 122, 0 }, { 123, 0 }, { 124, 0 }, { 125, 0 }, { 126, 0 }, + { 127, 0 }, { 128, 0 }, { 129, 0 }, { 130, 0 }, { 131, 0 }, + { 132, 0 }, { 133, 0 }, { 134, 0 }, { 135, 0 }, { 136, 0 }, + { 137, 0 }, { 138, 0 }, { 139, 0 }, { 140, 0 }, { 141, 0 }, + { 142, 0 }, { 143, 0 }, { 144, 0 }, { 145, 0 }, { 146, 0 }, + { 147, 0 }, { 148, 0 }, { 149, 0 }, { 150, 0 }, { 151, 0 }, + { 152, 0 }, { 153, 0 }, { 154, 0 }, { 155, 0 }, { 156, 0 }, + { 157, 0 }, { 158, 0 }, { 159, 0 }, { 160, 0 }, { 161, 0 }, + + { 162, 0 }, { 163, 0 }, { 164, 0 }, { 165, 0 }, { 166, 0 }, + { 167, 0 }, { 168, 0 }, { 169, 0 }, { 170, 0 }, { 171, 0 }, + { 172, 0 }, { 173, 0 }, { 174, 0 }, { 175, 0 }, { 176, 0 }, + { 177, 0 }, { 178, 0 }, { 179, 0 }, { 180, 0 }, { 181, 0 }, + { 182, 0 }, { 183, 0 }, { 184, 0 }, { 185, 0 }, { 186, 0 }, + { 187, 0 }, { 188, 0 }, { 189, 0 }, { 190, 0 }, { 191, 0 }, + { 192, 0 }, { 193, 0 }, { 194, 0 }, { 195, 0 }, { 196, 0 }, + { 197, 0 }, { 198, 0 }, { 199, 0 }, { 200, 0 }, { 201, 0 }, + { 202, 0 }, { 203, 0 }, { 204, 0 }, { 205, 0 }, { 206, 0 }, + { 207, 0 }, { 208, 0 }, { 209, 0 }, { 210, 0 }, { 211, 0 }, + + { 212, 0 }, { 213, 0 }, { 214, 0 }, { 215, 0 }, { 216, 0 }, + { 217, 0 }, { 218, 0 }, { 219, 0 }, { 220, 0 }, { 221, 0 }, + { 222, 0 }, { 223, 0 }, { 224, 0 }, { 225, 0 }, { 226, 0 }, + { 227, 0 }, { 228, 0 }, { 229, 0 }, { 230, 0 }, { 231, 0 }, + { 232, 0 }, { 233, 0 }, { 234, 0 }, { 235, 0 }, { 236, 0 }, + { 237, 0 }, { 238, 0 }, { 239, 0 }, { 240, 0 }, { 241, 0 }, + { 242, 0 }, { 243, 0 }, { 244, 0 }, { 245, 0 }, { 246, 0 }, + { 247, 0 }, { 248, 0 }, { 249, 0 }, { 250, 0 }, { 251, 0 }, + { 252, 0 }, { 253, 0 }, { 254, 0 }, { 255, 0 }, { 256, 0 }, + { 0, 24 }, { 0,9784 }, { 1,-258 }, { 2,-258 }, { 3,-258 }, + + { 4,-258 }, { 5,-258 }, { 6,-258 }, { 7,-258 }, { 8,-258 }, + { 9, 0 }, { 10,-11994 }, { 11,-258 }, { 12, 0 }, { 13,-11994 }, + { 14,-258 }, { 15,-258 }, { 16,-258 }, { 17,-258 }, { 18,-258 }, + { 19,-258 }, { 20,-258 }, { 21,-258 }, { 22,-258 }, { 23,-258 }, + { 24,-258 }, { 25,-258 }, { 26,-258 }, { 27,-258 }, { 28,-258 }, + { 29,-258 }, { 30,-258 }, { 31,-258 }, { 32, 0 }, { 33,-258 }, + { 34,-258 }, { 35,-258 }, { 36,-258 }, { 37,-258 }, { 38,-258 }, + { 39, 258 }, { 40,-258 }, { 41,-258 }, { 42,-258 }, { 43,-258 }, + { 44,-258 }, { 45,1032 }, { 46,-258 }, { 47,-258 }, { 48,-258 }, + { 49,-258 }, { 50,-258 }, { 51,-258 }, { 52,-258 }, { 53,-258 }, + + { 54,-258 }, { 55,-258 }, { 56,-258 }, { 57,-258 }, { 58,-258 }, + { 59,-258 }, { 60,-258 }, { 61,-258 }, { 62,-258 }, { 63,-258 }, + { 64,-258 }, { 65,-258 }, { 66,-258 }, { 67,-258 }, { 68,-258 }, + { 69,-258 }, { 70,-258 }, { 71,-258 }, { 72,-258 }, { 73,-258 }, + { 74,-258 }, { 75,-258 }, { 76,-258 }, { 77,-258 }, { 78,-258 }, + { 79,-258 }, { 80,-258 }, { 81,-258 }, { 82,-258 }, { 83,-258 }, + { 84,-258 }, { 85, 774 }, { 86,-258 }, { 87,-258 }, { 88,-258 }, + { 89,-258 }, { 90,-258 }, { 91,-258 }, { 92,-258 }, { 93,-258 }, + { 94,-258 }, { 95,-258 }, { 96,-258 }, { 97,-258 }, { 98,-258 }, + { 99,-258 }, { 100,-258 }, { 101,-258 }, { 102,-258 }, { 103,-258 }, + + { 104,-258 }, { 105,-258 }, { 106,-258 }, { 107,-258 }, { 108,-258 }, + { 109,-258 }, { 110,-258 }, { 111,-258 }, { 112,-258 }, { 113,-258 }, + { 114,-258 }, { 115,-258 }, { 116,-258 }, { 117, 774 }, { 118,-258 }, + { 119,-258 }, { 120,-258 }, { 121,-258 }, { 122,-258 }, { 123,-258 }, + { 124,-258 }, { 125,-258 }, { 126,-258 }, { 127,-258 }, { 128,-258 }, + { 129,-258 }, { 130,-258 }, { 131,-258 }, { 132,-258 }, { 133,-258 }, + { 134,-258 }, { 135,-258 }, { 136,-258 }, { 137,-258 }, { 138,-258 }, + { 139,-258 }, { 140,-258 }, { 141,-258 }, { 142,-258 }, { 143,-258 }, + { 144,-258 }, { 145,-258 }, { 146,-258 }, { 147,-258 }, { 148,-258 }, + { 149,-258 }, { 150,-258 }, { 151,-258 }, { 152,-258 }, { 153,-258 }, + + { 154,-258 }, { 155,-258 }, { 156,-258 }, { 157,-258 }, { 158,-258 }, + { 159,-258 }, { 160,-258 }, { 161,-258 }, { 162,-258 }, { 163,-258 }, + { 164,-258 }, { 165,-258 }, { 166,-258 }, { 167,-258 }, { 168,-258 }, + { 169,-258 }, { 170,-258 }, { 171,-258 }, { 172,-258 }, { 173,-258 }, + { 174,-258 }, { 175,-258 }, { 176,-258 }, { 177,-258 }, { 178,-258 }, + { 179,-258 }, { 180,-258 }, { 181,-258 }, { 182,-258 }, { 183,-258 }, + { 184,-258 }, { 185,-258 }, { 186,-258 }, { 187,-258 }, { 188,-258 }, + { 189,-258 }, { 190,-258 }, { 191,-258 }, { 192,-258 }, { 193,-258 }, + { 194,-258 }, { 195,-258 }, { 196,-258 }, { 197,-258 }, { 198,-258 }, + { 199,-258 }, { 200,-258 }, { 201,-258 }, { 202,-258 }, { 203,-258 }, + + { 204,-258 }, { 205,-258 }, { 206,-258 }, { 207,-258 }, { 208,-258 }, + { 209,-258 }, { 210,-258 }, { 211,-258 }, { 212,-258 }, { 213,-258 }, + { 214,-258 }, { 215,-258 }, { 216,-258 }, { 217,-258 }, { 218,-258 }, + { 219,-258 }, { 220,-258 }, { 221,-258 }, { 222,-258 }, { 223,-258 }, + { 224,-258 }, { 225,-258 }, { 226,-258 }, { 227,-258 }, { 228,-258 }, + { 229,-258 }, { 230,-258 }, { 231,-258 }, { 232,-258 }, { 233,-258 }, + { 234,-258 }, { 235,-258 }, { 236,-258 }, { 237,-258 }, { 238,-258 }, + { 239,-258 }, { 240,-258 }, { 241,-258 }, { 242,-258 }, { 243,-258 }, + { 244,-258 }, { 245,-258 }, { 246,-258 }, { 247,-258 }, { 248,-258 }, + { 249,-258 }, { 250,-258 }, { 251,-258 }, { 252,-258 }, { 253,-258 }, + + { 254,-258 }, { 255,-258 }, { 256,-258 }, { 0, 24 }, { 0,9526 }, + { 1,3473 }, { 2,3473 }, { 3,3473 }, { 4,3473 }, { 5,3473 }, + { 6,3473 }, { 7,3473 }, { 8,3473 }, { 9,3731 }, { 10,3989 }, + { 11,3473 }, { 12,3731 }, { 13,3989 }, { 14,3473 }, { 15,3473 }, + { 16,3473 }, { 17,3473 }, { 18,3473 }, { 19,3473 }, { 20,3473 }, + { 21,3473 }, { 22,3473 }, { 23,3473 }, { 24,3473 }, { 25,3473 }, + { 26,3473 }, { 27,3473 }, { 28,3473 }, { 29,3473 }, { 30,3473 }, + { 31,3473 }, { 32,3731 }, { 33,3473 }, { 34,3473 }, { 35,3473 }, + { 36,3473 }, { 37,3473 }, { 38,3473 }, { 39, 0 }, { 40,3473 }, + { 41,3473 }, { 42,3473 }, { 43,3473 }, { 44,3473 }, { 45,4108 }, + + { 46,3473 }, { 47,3473 }, { 48,3473 }, { 49,3473 }, { 50,3473 }, + { 51,3473 }, { 52,3473 }, { 53,3473 }, { 54,3473 }, { 55,3473 }, + { 56,3473 }, { 57,3473 }, { 58,3473 }, { 59,3473 }, { 60,3473 }, + { 61,3473 }, { 62,3473 }, { 63,3473 }, { 64,3473 }, { 65,3473 }, + { 66,3473 }, { 67,3473 }, { 68,3473 }, { 69,3473 }, { 70,3473 }, + { 71,3473 }, { 72,3473 }, { 73,3473 }, { 74,3473 }, { 75,3473 }, + { 76,3473 }, { 77,3473 }, { 78,3473 }, { 79,3473 }, { 80,3473 }, + { 81,3473 }, { 82,3473 }, { 83,3473 }, { 84,3473 }, { 85,4366 }, + { 86,3473 }, { 87,3473 }, { 88,3473 }, { 89,3473 }, { 90,3473 }, + { 91,3473 }, { 92,3473 }, { 93,3473 }, { 94,3473 }, { 95,3473 }, + + { 96,3473 }, { 97,3473 }, { 98,3473 }, { 99,3473 }, { 100,3473 }, + { 101,3473 }, { 102,3473 }, { 103,3473 }, { 104,3473 }, { 105,3473 }, + { 106,3473 }, { 107,3473 }, { 108,3473 }, { 109,3473 }, { 110,3473 }, + { 111,3473 }, { 112,3473 }, { 113,3473 }, { 114,3473 }, { 115,3473 }, + { 116,3473 }, { 117,4366 }, { 118,3473 }, { 119,3473 }, { 120,3473 }, + { 121,3473 }, { 122,3473 }, { 123,3473 }, { 124,3473 }, { 125,3473 }, + { 126,3473 }, { 127,3473 }, { 128,3473 }, { 129,3473 }, { 130,3473 }, + { 131,3473 }, { 132,3473 }, { 133,3473 }, { 134,3473 }, { 135,3473 }, + { 136,3473 }, { 137,3473 }, { 138,3473 }, { 139,3473 }, { 140,3473 }, + { 141,3473 }, { 142,3473 }, { 143,3473 }, { 144,3473 }, { 145,3473 }, + + { 146,3473 }, { 147,3473 }, { 148,3473 }, { 149,3473 }, { 150,3473 }, + { 151,3473 }, { 152,3473 }, { 153,3473 }, { 154,3473 }, { 155,3473 }, + { 156,3473 }, { 157,3473 }, { 158,3473 }, { 159,3473 }, { 160,3473 }, + { 161,3473 }, { 162,3473 }, { 163,3473 }, { 164,3473 }, { 165,3473 }, + { 166,3473 }, { 167,3473 }, { 168,3473 }, { 169,3473 }, { 170,3473 }, + { 171,3473 }, { 172,3473 }, { 173,3473 }, { 174,3473 }, { 175,3473 }, + { 176,3473 }, { 177,3473 }, { 178,3473 }, { 179,3473 }, { 180,3473 }, + { 181,3473 }, { 182,3473 }, { 183,3473 }, { 184,3473 }, { 185,3473 }, + { 186,3473 }, { 187,3473 }, { 188,3473 }, { 189,3473 }, { 190,3473 }, + { 191,3473 }, { 192,3473 }, { 193,3473 }, { 194,3473 }, { 195,3473 }, + + { 196,3473 }, { 197,3473 }, { 198,3473 }, { 199,3473 }, { 200,3473 }, + { 201,3473 }, { 202,3473 }, { 203,3473 }, { 204,3473 }, { 205,3473 }, + { 206,3473 }, { 207,3473 }, { 208,3473 }, { 209,3473 }, { 210,3473 }, + { 211,3473 }, { 212,3473 }, { 213,3473 }, { 214,3473 }, { 215,3473 }, + { 216,3473 }, { 217,3473 }, { 218,3473 }, { 219,3473 }, { 220,3473 }, + { 221,3473 }, { 222,3473 }, { 223,3473 }, { 224,3473 }, { 225,3473 }, + { 226,3473 }, { 227,3473 }, { 228,3473 }, { 229,3473 }, { 230,3473 }, + { 231,3473 }, { 232,3473 }, { 233,3473 }, { 234,3473 }, { 235,3473 }, + { 236,3473 }, { 237,3473 }, { 238,3473 }, { 239,3473 }, { 240,3473 }, + { 241,3473 }, { 242,3473 }, { 243,3473 }, { 244,3473 }, { 245,3473 }, + + { 246,3473 }, { 247,3473 }, { 248,3473 }, { 249,3473 }, { 250,3473 }, + { 251,3473 }, { 252,3473 }, { 253,3473 }, { 254,3473 }, { 255,3473 }, + { 256,3473 }, { 0, 24 }, { 0,9268 }, { 1,-774 }, { 2,-774 }, + { 3,-774 }, { 4,-774 }, { 5,-774 }, { 6,-774 }, { 7,-774 }, + { 8,-774 }, { 9,-516 }, { 10,-12510 }, { 11,-774 }, { 12,-516 }, + { 13,-12510 }, { 14,-774 }, { 15,-774 }, { 16,-774 }, { 17,-774 }, + { 18,-774 }, { 19,-774 }, { 20,-774 }, { 21,-774 }, { 22,-774 }, + { 23,-774 }, { 24,-774 }, { 25,-774 }, { 26,-774 }, { 27,-774 }, + { 28,-774 }, { 29,-774 }, { 30,-774 }, { 31,-774 }, { 32,-516 }, + { 33,-774 }, { 34,-774 }, { 35,-774 }, { 36,-774 }, { 37,-774 }, + + { 38,-774 }, { 39,-258 }, { 40,-774 }, { 41,-774 }, { 42,-774 }, + { 43,-774 }, { 44,-774 }, { 45,4366 }, { 46,-774 }, { 47,-774 }, + { 48,-774 }, { 49,-774 }, { 50,-774 }, { 51,-774 }, { 52,-774 }, + { 53,-774 }, { 54,-774 }, { 55,-774 }, { 56,-774 }, { 57,-774 }, + { 58,-774 }, { 59,-774 }, { 60,-774 }, { 61,-774 }, { 62,-774 }, + { 63,-774 }, { 64,-774 }, { 65,-774 }, { 66,-774 }, { 67,-774 }, + { 68,-774 }, { 69,-774 }, { 70,-774 }, { 71,-774 }, { 72,-774 }, + { 73,-774 }, { 74,-774 }, { 75,-774 }, { 76,-774 }, { 77,-774 }, + { 78,-774 }, { 79,-774 }, { 80,-774 }, { 81,-774 }, { 82,-774 }, + { 83,-774 }, { 84,-774 }, { 85, 258 }, { 86,-774 }, { 87,-774 }, + + { 88,-774 }, { 89,-774 }, { 90,-774 }, { 91,-774 }, { 92,-774 }, + { 93,-774 }, { 94,-774 }, { 95,-774 }, { 96,-774 }, { 97,-774 }, + { 98,-774 }, { 99,-774 }, { 100,-774 }, { 101,-774 }, { 102,-774 }, + { 103,-774 }, { 104,-774 }, { 105,-774 }, { 106,-774 }, { 107,-774 }, + { 108,-774 }, { 109,-774 }, { 110,-774 }, { 111,-774 }, { 112,-774 }, + { 113,-774 }, { 114,-774 }, { 115,-774 }, { 116,-774 }, { 117, 258 }, + { 118,-774 }, { 119,-774 }, { 120,-774 }, { 121,-774 }, { 122,-774 }, + { 123,-774 }, { 124,-774 }, { 125,-774 }, { 126,-774 }, { 127,-774 }, + { 128,-774 }, { 129,-774 }, { 130,-774 }, { 131,-774 }, { 132,-774 }, + { 133,-774 }, { 134,-774 }, { 135,-774 }, { 136,-774 }, { 137,-774 }, + + { 138,-774 }, { 139,-774 }, { 140,-774 }, { 141,-774 }, { 142,-774 }, + { 143,-774 }, { 144,-774 }, { 145,-774 }, { 146,-774 }, { 147,-774 }, + { 148,-774 }, { 149,-774 }, { 150,-774 }, { 151,-774 }, { 152,-774 }, + { 153,-774 }, { 154,-774 }, { 155,-774 }, { 156,-774 }, { 157,-774 }, + { 158,-774 }, { 159,-774 }, { 160,-774 }, { 161,-774 }, { 162,-774 }, + { 163,-774 }, { 164,-774 }, { 165,-774 }, { 166,-774 }, { 167,-774 }, + { 168,-774 }, { 169,-774 }, { 170,-774 }, { 171,-774 }, { 172,-774 }, + { 173,-774 }, { 174,-774 }, { 175,-774 }, { 176,-774 }, { 177,-774 }, + { 178,-774 }, { 179,-774 }, { 180,-774 }, { 181,-774 }, { 182,-774 }, + { 183,-774 }, { 184,-774 }, { 185,-774 }, { 186,-774 }, { 187,-774 }, + + { 188,-774 }, { 189,-774 }, { 190,-774 }, { 191,-774 }, { 192,-774 }, + { 193,-774 }, { 194,-774 }, { 195,-774 }, { 196,-774 }, { 197,-774 }, + { 198,-774 }, { 199,-774 }, { 200,-774 }, { 201,-774 }, { 202,-774 }, + { 203,-774 }, { 204,-774 }, { 205,-774 }, { 206,-774 }, { 207,-774 }, + { 208,-774 }, { 209,-774 }, { 210,-774 }, { 211,-774 }, { 212,-774 }, + { 213,-774 }, { 214,-774 }, { 215,-774 }, { 216,-774 }, { 217,-774 }, + { 218,-774 }, { 219,-774 }, { 220,-774 }, { 221,-774 }, { 222,-774 }, + { 223,-774 }, { 224,-774 }, { 225,-774 }, { 226,-774 }, { 227,-774 }, + { 228,-774 }, { 229,-774 }, { 230,-774 }, { 231,-774 }, { 232,-774 }, + { 233,-774 }, { 234,-774 }, { 235,-774 }, { 236,-774 }, { 237,-774 }, + + { 238,-774 }, { 239,-774 }, { 240,-774 }, { 241,-774 }, { 242,-774 }, + { 243,-774 }, { 244,-774 }, { 245,-774 }, { 246,-774 }, { 247,-774 }, + { 248,-774 }, { 249,-774 }, { 250,-774 }, { 251,-774 }, { 252,-774 }, + { 253,-774 }, { 254,-774 }, { 255,-774 }, { 256,-774 }, { 0, 24 }, + { 0,9010 }, { 1,-1032 }, { 2,-1032 }, { 3,-1032 }, { 4,-1032 }, + { 5,-1032 }, { 6,-1032 }, { 7,-1032 }, { 8,-1032 }, { 9,-774 }, + { 10,-12768 }, { 11,-1032 }, { 12,-774 }, { 13,-12768 }, { 14,-1032 }, + { 15,-1032 }, { 16,-1032 }, { 17,-1032 }, { 18,-1032 }, { 19,-1032 }, + { 20,-1032 }, { 21,-1032 }, { 22,-1032 }, { 23,-1032 }, { 24,-1032 }, + { 25,-1032 }, { 26,-1032 }, { 27,-1032 }, { 28,-1032 }, { 29,-1032 }, + + { 30,-1032 }, { 31,-1032 }, { 32,-774 }, { 33,-1032 }, { 34,-1032 }, + { 35,-1032 }, { 36,-1032 }, { 37,-1032 }, { 38,-1032 }, { 39,-516 }, + { 40,-1032 }, { 41,-1032 }, { 42,-1032 }, { 43,-1032 }, { 44,-1032 }, + { 45, 258 }, { 46,-1032 }, { 47,-1032 }, { 48,-1032 }, { 49,-1032 }, + { 50,-1032 }, { 51,-1032 }, { 52,-1032 }, { 53,-1032 }, { 54,-1032 }, + { 55,-1032 }, { 56,-1032 }, { 57,-1032 }, { 58,-1032 }, { 59,-1032 }, + { 60,-1032 }, { 61,-1032 }, { 62,-1032 }, { 63,-1032 }, { 64,-1032 }, + { 65,-1032 }, { 66,-1032 }, { 67,-1032 }, { 68,-1032 }, { 69,4366 }, + { 70,-1032 }, { 71,-1032 }, { 72,-1032 }, { 73,-1032 }, { 74,-1032 }, + { 75,-1032 }, { 76,-1032 }, { 77,-1032 }, { 78,-1032 }, { 79,-1032 }, + + { 80,-1032 }, { 81,-1032 }, { 82,-1032 }, { 83,-1032 }, { 84,-1032 }, + { 85, 0 }, { 86,-1032 }, { 87,-1032 }, { 88,-1032 }, { 89,-1032 }, + { 90,-1032 }, { 91,-1032 }, { 92,-1032 }, { 93,-1032 }, { 94,-1032 }, + { 95,-1032 }, { 96,-1032 }, { 97,-1032 }, { 98,-1032 }, { 99,-1032 }, + { 100,-1032 }, { 101,4366 }, { 102,-1032 }, { 103,-1032 }, { 104,-1032 }, + { 105,-1032 }, { 106,-1032 }, { 107,-1032 }, { 108,-1032 }, { 109,-1032 }, + { 110,-1032 }, { 111,-1032 }, { 112,-1032 }, { 113,-1032 }, { 114,-1032 }, + { 115,-1032 }, { 116,-1032 }, { 117, 0 }, { 118,-1032 }, { 119,-1032 }, + { 120,-1032 }, { 121,-1032 }, { 122,-1032 }, { 123,-1032 }, { 124,-1032 }, + { 125,-1032 }, { 126,-1032 }, { 127,-1032 }, { 128,-1032 }, { 129,-1032 }, + + { 130,-1032 }, { 131,-1032 }, { 132,-1032 }, { 133,-1032 }, { 134,-1032 }, + { 135,-1032 }, { 136,-1032 }, { 137,-1032 }, { 138,-1032 }, { 139,-1032 }, + { 140,-1032 }, { 141,-1032 }, { 142,-1032 }, { 143,-1032 }, { 144,-1032 }, + { 145,-1032 }, { 146,-1032 }, { 147,-1032 }, { 148,-1032 }, { 149,-1032 }, + { 150,-1032 }, { 151,-1032 }, { 152,-1032 }, { 153,-1032 }, { 154,-1032 }, + { 155,-1032 }, { 156,-1032 }, { 157,-1032 }, { 158,-1032 }, { 159,-1032 }, + { 160,-1032 }, { 161,-1032 }, { 162,-1032 }, { 163,-1032 }, { 164,-1032 }, + { 165,-1032 }, { 166,-1032 }, { 167,-1032 }, { 168,-1032 }, { 169,-1032 }, + { 170,-1032 }, { 171,-1032 }, { 172,-1032 }, { 173,-1032 }, { 174,-1032 }, + { 175,-1032 }, { 176,-1032 }, { 177,-1032 }, { 178,-1032 }, { 179,-1032 }, + + { 180,-1032 }, { 181,-1032 }, { 182,-1032 }, { 183,-1032 }, { 184,-1032 }, + { 185,-1032 }, { 186,-1032 }, { 187,-1032 }, { 188,-1032 }, { 189,-1032 }, + { 190,-1032 }, { 191,-1032 }, { 192,-1032 }, { 193,-1032 }, { 194,-1032 }, + { 195,-1032 }, { 196,-1032 }, { 197,-1032 }, { 198,-1032 }, { 199,-1032 }, + { 200,-1032 }, { 201,-1032 }, { 202,-1032 }, { 203,-1032 }, { 204,-1032 }, + { 205,-1032 }, { 206,-1032 }, { 207,-1032 }, { 208,-1032 }, { 209,-1032 }, + { 210,-1032 }, { 211,-1032 }, { 212,-1032 }, { 213,-1032 }, { 214,-1032 }, + { 215,-1032 }, { 216,-1032 }, { 217,-1032 }, { 218,-1032 }, { 219,-1032 }, + { 220,-1032 }, { 221,-1032 }, { 222,-1032 }, { 223,-1032 }, { 224,-1032 }, + { 225,-1032 }, { 226,-1032 }, { 227,-1032 }, { 228,-1032 }, { 229,-1032 }, + + { 230,-1032 }, { 231,-1032 }, { 232,-1032 }, { 233,-1032 }, { 234,-1032 }, + { 235,-1032 }, { 236,-1032 }, { 237,-1032 }, { 238,-1032 }, { 239,-1032 }, + { 240,-1032 }, { 241,-1032 }, { 242,-1032 }, { 243,-1032 }, { 244,-1032 }, + { 245,-1032 }, { 246,-1032 }, { 247,-1032 }, { 248,-1032 }, { 249,-1032 }, + { 250,-1032 }, { 251,-1032 }, { 252,-1032 }, { 253,-1032 }, { 254,-1032 }, + { 255,-1032 }, { 256,-1032 }, { 0, 24 }, { 0,8752 }, { 1,-1290 }, + { 2,-1290 }, { 3,-1290 }, { 4,-1290 }, { 5,-1290 }, { 6,-1290 }, + { 7,-1290 }, { 8,-1290 }, { 9,-1032 }, { 10,-13026 }, { 11,-1290 }, + { 12,-1032 }, { 13,-13026 }, { 14,-1290 }, { 15,-1290 }, { 16,-1290 }, + { 17,-1290 }, { 18,-1290 }, { 19,-1290 }, { 20,-1290 }, { 21,-1290 }, + + { 22,-1290 }, { 23,-1290 }, { 24,-1290 }, { 25,-1290 }, { 26,-1290 }, + { 27,-1290 }, { 28,-1290 }, { 29,-1290 }, { 30,-1290 }, { 31,-1290 }, + { 32,-1032 }, { 33,-1290 }, { 34,-1290 }, { 35,-1290 }, { 36,-1290 }, + { 37,-1290 }, { 38,-1290 }, { 39,-774 }, { 40,-1290 }, { 41,-1290 }, + { 42,-1290 }, { 43,-1290 }, { 44,-1290 }, { 45,3850 }, { 46,-1290 }, + { 47,-1290 }, { 48,-1290 }, { 49,-1290 }, { 50,-1290 }, { 51,-1290 }, + { 52,-1290 }, { 53,-1290 }, { 54,-1290 }, { 55,-1290 }, { 56,-1290 }, + { 57,-1290 }, { 58,-1290 }, { 59,-1290 }, { 60,-1290 }, { 61,-1290 }, + { 62,-1290 }, { 63,-1290 }, { 64,-1290 }, { 65,-1290 }, { 66,-1290 }, + { 67,-1290 }, { 68,-1290 }, { 69,-1290 }, { 70,-1290 }, { 71,-1290 }, + + { 72,-1290 }, { 73,-1290 }, { 74,-1290 }, { 75,-1290 }, { 76,-1290 }, + { 77,-1290 }, { 78,-1290 }, { 79,-1290 }, { 80,-1290 }, { 81,-1290 }, + { 82,-1290 }, { 83,-1290 }, { 84,-1290 }, { 85,-258 }, { 86,-1290 }, + { 87,-1290 }, { 88,-1290 }, { 89,-1290 }, { 90,-1290 }, { 91,-1290 }, + { 92,-1290 }, { 93,-1290 }, { 94,-1290 }, { 95,-1290 }, { 96,-1290 }, + { 97,-1290 }, { 98,-1290 }, { 99,-1290 }, { 100,-1290 }, { 101,-1290 }, + { 102,-1290 }, { 103,-1290 }, { 104,-1290 }, { 105,-1290 }, { 106,-1290 }, + { 107,-1290 }, { 108,-1290 }, { 109,-1290 }, { 110,-1290 }, { 111,-1290 }, + { 112,-1290 }, { 113,-1290 }, { 114,-1290 }, { 115,-1290 }, { 116,-1290 }, + { 117,-258 }, { 118,-1290 }, { 119,-1290 }, { 120,-1290 }, { 121,-1290 }, + + { 122,-1290 }, { 123,-1290 }, { 124,-1290 }, { 125,-1290 }, { 126,-1290 }, + { 127,-1290 }, { 128,-1290 }, { 129,-1290 }, { 130,-1290 }, { 131,-1290 }, + { 132,-1290 }, { 133,-1290 }, { 134,-1290 }, { 135,-1290 }, { 136,-1290 }, + { 137,-1290 }, { 138,-1290 }, { 139,-1290 }, { 140,-1290 }, { 141,-1290 }, + { 142,-1290 }, { 143,-1290 }, { 144,-1290 }, { 145,-1290 }, { 146,-1290 }, + { 147,-1290 }, { 148,-1290 }, { 149,-1290 }, { 150,-1290 }, { 151,-1290 }, + { 152,-1290 }, { 153,-1290 }, { 154,-1290 }, { 155,-1290 }, { 156,-1290 }, + { 157,-1290 }, { 158,-1290 }, { 159,-1290 }, { 160,-1290 }, { 161,-1290 }, + { 162,-1290 }, { 163,-1290 }, { 164,-1290 }, { 165,-1290 }, { 166,-1290 }, + { 167,-1290 }, { 168,-1290 }, { 169,-1290 }, { 170,-1290 }, { 171,-1290 }, + + { 172,-1290 }, { 173,-1290 }, { 174,-1290 }, { 175,-1290 }, { 176,-1290 }, + { 177,-1290 }, { 178,-1290 }, { 179,-1290 }, { 180,-1290 }, { 181,-1290 }, + { 182,-1290 }, { 183,-1290 }, { 184,-1290 }, { 185,-1290 }, { 186,-1290 }, + { 187,-1290 }, { 188,-1290 }, { 189,-1290 }, { 190,-1290 }, { 191,-1290 }, + { 192,-1290 }, { 193,-1290 }, { 194,-1290 }, { 195,-1290 }, { 196,-1290 }, + { 197,-1290 }, { 198,-1290 }, { 199,-1290 }, { 200,-1290 }, { 201,-1290 }, + { 202,-1290 }, { 203,-1290 }, { 204,-1290 }, { 205,-1290 }, { 206,-1290 }, + { 207,-1290 }, { 208,-1290 }, { 209,-1290 }, { 210,-1290 }, { 211,-1290 }, + { 212,-1290 }, { 213,-1290 }, { 214,-1290 }, { 215,-1290 }, { 216,-1290 }, + { 217,-1290 }, { 218,-1290 }, { 219,-1290 }, { 220,-1290 }, { 221,-1290 }, + + { 222,-1290 }, { 223,-1290 }, { 224,-1290 }, { 225,-1290 }, { 226,-1290 }, + { 227,-1290 }, { 228,-1290 }, { 229,-1290 }, { 230,-1290 }, { 231,-1290 }, + { 232,-1290 }, { 233,-1290 }, { 234,-1290 }, { 235,-1290 }, { 236,-1290 }, + { 237,-1290 }, { 238,-1290 }, { 239,-1290 }, { 240,-1290 }, { 241,-1290 }, + { 242,-1290 }, { 243,-1290 }, { 244,-1290 }, { 245,-1290 }, { 246,-1290 }, + { 247,-1290 }, { 248,-1290 }, { 249,-1290 }, { 250,-1290 }, { 251,-1290 }, + { 252,-1290 }, { 253,-1290 }, { 254,-1290 }, { 255,-1290 }, { 256,-1290 }, + { 0, 24 }, { 0,8494 }, { 1,-5537 }, { 2,-5537 }, { 3,-5537 }, + { 4,-5537 }, { 5,-5537 }, { 6,-5537 }, { 7,-5537 }, { 8,-5537 }, + { 9,-5279 }, { 10,-17697 }, { 11,-5537 }, { 12,-5279 }, { 13,-17697 }, + + { 14,-5537 }, { 15,-5537 }, { 16,-5537 }, { 17,-5537 }, { 18,-5537 }, + { 19,-5537 }, { 20,-5537 }, { 21,-5537 }, { 22,-5537 }, { 23,-5537 }, + { 24,-5537 }, { 25,-5537 }, { 26,-5537 }, { 27,-5537 }, { 28,-5537 }, + { 29,-5537 }, { 30,-5537 }, { 31,-5537 }, { 32,-5279 }, { 33,-5537 }, + { 34,-5537 }, { 35,-5537 }, { 36,-5537 }, { 37,-5537 }, { 38,-5537 }, + { 39,-5021 }, { 40,-5537 }, { 41,-5537 }, { 42,-5537 }, { 43,-5537 }, + { 44,-5537 }, { 45,1409 }, { 46,-5537 }, { 47,-5537 }, { 48,-5537 }, + { 49,-5537 }, { 50,-5537 }, { 51,-5537 }, { 52,-5537 }, { 53,-5537 }, + { 54,-5537 }, { 55,-5537 }, { 56,-5537 }, { 57,-5537 }, { 58,-5537 }, + { 59,-5537 }, { 60,-5537 }, { 61,-5537 }, { 62,-5537 }, { 63,-5537 }, + + { 64,-5537 }, { 65,-5537 }, { 66,-5537 }, { 67,-5537 }, { 68,-5537 }, + { 69,-5537 }, { 70,-5537 }, { 71,-5537 }, { 72,-5537 }, { 73,-5537 }, + { 74,-5537 }, { 75,-5537 }, { 76,-5537 }, { 77,-5537 }, { 78,-5537 }, + { 79,-5537 }, { 80,-5537 }, { 81,-5537 }, { 82,-5537 }, { 83,-5537 }, + { 84,-5537 }, { 85,-4505 }, { 86,-5537 }, { 87,-5537 }, { 88,-5537 }, + { 89,-5537 }, { 90,-5537 }, { 91,-5537 }, { 92,-5537 }, { 93,-5537 }, + { 94,-5537 }, { 95,-5537 }, { 96,-5537 }, { 97,-5537 }, { 98,-5537 }, + { 99,-5537 }, { 100,-5537 }, { 101,-5537 }, { 102,-5537 }, { 103,-5537 }, + { 104,-5537 }, { 105,-5537 }, { 106,-5537 }, { 107,-5537 }, { 108,-5537 }, + { 109,-5537 }, { 110,-5537 }, { 111,-5537 }, { 112,-5537 }, { 113,-5537 }, + + { 114,-5537 }, { 115,-5537 }, { 116,-5537 }, { 117,-4505 }, { 118,-5537 }, + { 119,-5537 }, { 120,-5537 }, { 121,-5537 }, { 122,-5537 }, { 123,-5537 }, + { 124,-5537 }, { 125,-5537 }, { 126,-5537 }, { 127,-5537 }, { 128,-5537 }, + { 129,-5537 }, { 130,-5537 }, { 131,-5537 }, { 132,-5537 }, { 133,-5537 }, + { 134,-5537 }, { 135,-5537 }, { 136,-5537 }, { 137,-5537 }, { 138,-5537 }, + { 139,-5537 }, { 140,-5537 }, { 141,-5537 }, { 142,-5537 }, { 143,-5537 }, + { 144,-5537 }, { 145,-5537 }, { 146,-5537 }, { 147,-5537 }, { 148,-5537 }, + { 149,-5537 }, { 150,-5537 }, { 151,-5537 }, { 152,-5537 }, { 153,-5537 }, + { 154,-5537 }, { 155,-5537 }, { 156,-5537 }, { 157,-5537 }, { 158,-5537 }, + { 159,-5537 }, { 160,-5537 }, { 161,-5537 }, { 162,-5537 }, { 163,-5537 }, + + { 164,-5537 }, { 165,-5537 }, { 166,-5537 }, { 167,-5537 }, { 168,-5537 }, + { 169,-5537 }, { 170,-5537 }, { 171,-5537 }, { 172,-5537 }, { 173,-5537 }, + { 174,-5537 }, { 175,-5537 }, { 176,-5537 }, { 177,-5537 }, { 178,-5537 }, + { 179,-5537 }, { 180,-5537 }, { 181,-5537 }, { 182,-5537 }, { 183,-5537 }, + { 184,-5537 }, { 185,-5537 }, { 186,-5537 }, { 187,-5537 }, { 188,-5537 }, + { 189,-5537 }, { 190,-5537 }, { 191,-5537 }, { 192,-5537 }, { 193,-5537 }, + { 194,-5537 }, { 195,-5537 }, { 196,-5537 }, { 197,-5537 }, { 198,-5537 }, + { 199,-5537 }, { 200,-5537 }, { 201,-5537 }, { 202,-5537 }, { 203,-5537 }, + { 204,-5537 }, { 205,-5537 }, { 206,-5537 }, { 207,-5537 }, { 208,-5537 }, + { 209,-5537 }, { 210,-5537 }, { 211,-5537 }, { 212,-5537 }, { 213,-5537 }, + + { 214,-5537 }, { 215,-5537 }, { 216,-5537 }, { 217,-5537 }, { 218,-5537 }, + { 219,-5537 }, { 220,-5537 }, { 221,-5537 }, { 222,-5537 }, { 223,-5537 }, + { 224,-5537 }, { 225,-5537 }, { 226,-5537 }, { 227,-5537 }, { 228,-5537 }, + { 229,-5537 }, { 230,-5537 }, { 231,-5537 }, { 232,-5537 }, { 233,-5537 }, + { 234,-5537 }, { 235,-5537 }, { 236,-5537 }, { 237,-5537 }, { 238,-5537 }, + { 239,-5537 }, { 240,-5537 }, { 241,-5537 }, { 242,-5537 }, { 243,-5537 }, + { 244,-5537 }, { 245,-5537 }, { 246,-5537 }, { 247,-5537 }, { 248,-5537 }, + { 249,-5537 }, { 250,-5537 }, { 251,-5537 }, { 252,-5537 }, { 253,-5537 }, + { 254,-5537 }, { 255,-5537 }, { 256,-5537 }, { 0, 24 }, { 0,8236 }, + { 1,-5795 }, { 2,-5795 }, { 3,-5795 }, { 4,-5795 }, { 5,-5795 }, + + { 6,-5795 }, { 7,-5795 }, { 8,-5795 }, { 9,-5537 }, { 10,-17955 }, + { 11,-5795 }, { 12,-5537 }, { 13,-17955 }, { 14,-5795 }, { 15,-5795 }, + { 16,-5795 }, { 17,-5795 }, { 18,-5795 }, { 19,-5795 }, { 20,-5795 }, + { 21,-5795 }, { 22,-5795 }, { 23,-5795 }, { 24,-5795 }, { 25,-5795 }, + { 26,-5795 }, { 27,-5795 }, { 28,-5795 }, { 29,-5795 }, { 30,-5795 }, + { 31,-5795 }, { 32,-5537 }, { 33,-5795 }, { 34,-5795 }, { 35,-5795 }, + { 36,-5795 }, { 37,-5795 }, { 38,-5795 }, { 39,3850 }, { 40,-5795 }, + { 41,-5795 }, { 42,-5795 }, { 43,-5795 }, { 44,-5795 }, { 45,-258 }, + { 46,-5795 }, { 47,-5795 }, { 48,-5795 }, { 49,-5795 }, { 50,-5795 }, + { 51,-5795 }, { 52,-5795 }, { 53,-5795 }, { 54,-5795 }, { 55,-5795 }, + + { 56,-5795 }, { 57,-5795 }, { 58,-5795 }, { 59,-5795 }, { 60,-5795 }, + { 61,-5795 }, { 62,-5795 }, { 63,-5795 }, { 64,-5795 }, { 65,-5795 }, + { 66,-5795 }, { 67,-5795 }, { 68,-5795 }, { 69,-5795 }, { 70,-5795 }, + { 71,-5795 }, { 72,-5795 }, { 73,-5795 }, { 74,-5795 }, { 75,-5795 }, + { 76,-5795 }, { 77,-5795 }, { 78,-5795 }, { 79,-5795 }, { 80,-5795 }, + { 81,-5795 }, { 82,-5795 }, { 83,-5795 }, { 84,-5795 }, { 85,-4763 }, + { 86,-5795 }, { 87,-5795 }, { 88,-5795 }, { 89,-5795 }, { 90,-5795 }, + { 91,-5795 }, { 92,-5795 }, { 93,-5795 }, { 94,-5795 }, { 95,-5795 }, + { 96,-5795 }, { 97,-5795 }, { 98,-5795 }, { 99,-5795 }, { 100,-5795 }, + { 101,-5795 }, { 102,-5795 }, { 103,-5795 }, { 104,-5795 }, { 105,-5795 }, + + { 106,-5795 }, { 107,-5795 }, { 108,-5795 }, { 109,-5795 }, { 110,-5795 }, + { 111,-5795 }, { 112,-5795 }, { 113,-5795 }, { 114,-5795 }, { 115,-5795 }, + { 116,-5795 }, { 117,-4763 }, { 118,-5795 }, { 119,-5795 }, { 120,-5795 }, + { 121,-5795 }, { 122,-5795 }, { 123,-5795 }, { 124,-5795 }, { 125,-5795 }, + { 126,-5795 }, { 127,-5795 }, { 128,-5795 }, { 129,-5795 }, { 130,-5795 }, + { 131,-5795 }, { 132,-5795 }, { 133,-5795 }, { 134,-5795 }, { 135,-5795 }, + { 136,-5795 }, { 137,-5795 }, { 138,-5795 }, { 139,-5795 }, { 140,-5795 }, + { 141,-5795 }, { 142,-5795 }, { 143,-5795 }, { 144,-5795 }, { 145,-5795 }, + { 146,-5795 }, { 147,-5795 }, { 148,-5795 }, { 149,-5795 }, { 150,-5795 }, + { 151,-5795 }, { 152,-5795 }, { 153,-5795 }, { 154,-5795 }, { 155,-5795 }, + + { 156,-5795 }, { 157,-5795 }, { 158,-5795 }, { 159,-5795 }, { 160,-5795 }, + { 161,-5795 }, { 162,-5795 }, { 163,-5795 }, { 164,-5795 }, { 165,-5795 }, + { 166,-5795 }, { 167,-5795 }, { 168,-5795 }, { 169,-5795 }, { 170,-5795 }, + { 171,-5795 }, { 172,-5795 }, { 173,-5795 }, { 174,-5795 }, { 175,-5795 }, + { 176,-5795 }, { 177,-5795 }, { 178,-5795 }, { 179,-5795 }, { 180,-5795 }, + { 181,-5795 }, { 182,-5795 }, { 183,-5795 }, { 184,-5795 }, { 185,-5795 }, + { 186,-5795 }, { 187,-5795 }, { 188,-5795 }, { 189,-5795 }, { 190,-5795 }, + { 191,-5795 }, { 192,-5795 }, { 193,-5795 }, { 194,-5795 }, { 195,-5795 }, + { 196,-5795 }, { 197,-5795 }, { 198,-5795 }, { 199,-5795 }, { 200,-5795 }, + { 201,-5795 }, { 202,-5795 }, { 203,-5795 }, { 204,-5795 }, { 205,-5795 }, + + { 206,-5795 }, { 207,-5795 }, { 208,-5795 }, { 209,-5795 }, { 210,-5795 }, + { 211,-5795 }, { 212,-5795 }, { 213,-5795 }, { 214,-5795 }, { 215,-5795 }, + { 216,-5795 }, { 217,-5795 }, { 218,-5795 }, { 219,-5795 }, { 220,-5795 }, + { 221,-5795 }, { 222,-5795 }, { 223,-5795 }, { 224,-5795 }, { 225,-5795 }, + { 226,-5795 }, { 227,-5795 }, { 228,-5795 }, { 229,-5795 }, { 230,-5795 }, + { 231,-5795 }, { 232,-5795 }, { 233,-5795 }, { 234,-5795 }, { 235,-5795 }, + { 236,-5795 }, { 237,-5795 }, { 238,-5795 }, { 239,-5795 }, { 240,-5795 }, + { 241,-5795 }, { 242,-5795 }, { 243,-5795 }, { 244,-5795 }, { 245,-5795 }, + { 246,-5795 }, { 247,-5795 }, { 248,-5795 }, { 249,-5795 }, { 250,-5795 }, + { 251,-5795 }, { 252,-5795 }, { 253,-5795 }, { 254,-5795 }, { 255,-5795 }, + + { 256,-5795 }, { 0, 24 }, { 0,7978 }, { 1,-6053 }, { 2,-6053 }, + { 3,-6053 }, { 4,-6053 }, { 5,-6053 }, { 6,-6053 }, { 7,-6053 }, + { 8,-6053 }, { 9,-5795 }, { 10,-18213 }, { 11,-6053 }, { 12,-5795 }, + { 13,-18213 }, { 14,-6053 }, { 15,-6053 }, { 16,-6053 }, { 17,-6053 }, + { 18,-6053 }, { 19,-6053 }, { 20,-6053 }, { 21,-6053 }, { 22,-6053 }, + { 23,-6053 }, { 24,-6053 }, { 25,-6053 }, { 26,-6053 }, { 27,-6053 }, + { 28,-6053 }, { 29,-6053 }, { 30,-6053 }, { 31,-6053 }, { 32,-5795 }, + { 33,-6053 }, { 34,-6053 }, { 35,-6053 }, { 36,-6053 }, { 37,-6053 }, + { 38,-6053 }, { 39,3592 }, { 40,-6053 }, { 41,-6053 }, { 42,-6053 }, + { 43,-6053 }, { 44,-6053 }, { 45,-516 }, { 46,-6053 }, { 47,-6053 }, + + { 48,-6053 }, { 49,-6053 }, { 50,-6053 }, { 51,-6053 }, { 52,-6053 }, + { 53,-6053 }, { 54,-6053 }, { 55,-6053 }, { 56,-6053 }, { 57,-6053 }, + { 58,-6053 }, { 59,-6053 }, { 60,-6053 }, { 61,-6053 }, { 62,-6053 }, + { 63,-6053 }, { 64,-6053 }, { 65,-6053 }, { 66,-6053 }, { 67,-6053 }, + { 68,-6053 }, { 69,-6053 }, { 70,-6053 }, { 71,-6053 }, { 72,-6053 }, + { 73,-6053 }, { 74,-6053 }, { 75,-6053 }, { 76,-6053 }, { 77,-6053 }, + { 78,-6053 }, { 79,-6053 }, { 80,-6053 }, { 81,-6053 }, { 82,-6053 }, + { 83,-6053 }, { 84,-6053 }, { 85,-5021 }, { 86,-6053 }, { 87,-6053 }, + { 88,-6053 }, { 89,-6053 }, { 90,-6053 }, { 91,-6053 }, { 92,-6053 }, + { 93,-6053 }, { 94,-6053 }, { 95,-6053 }, { 96,-6053 }, { 97,-6053 }, + + { 98,-6053 }, { 99,-6053 }, { 100,-6053 }, { 101,-6053 }, { 102,-6053 }, + { 103,-6053 }, { 104,-6053 }, { 105,-6053 }, { 106,-6053 }, { 107,-6053 }, + { 108,-6053 }, { 109,-6053 }, { 110,-6053 }, { 111,-6053 }, { 112,-6053 }, + { 113,-6053 }, { 114,-6053 }, { 115,-6053 }, { 116,-6053 }, { 117,-5021 }, + { 118,-6053 }, { 119,-6053 }, { 120,-6053 }, { 121,-6053 }, { 122,-6053 }, + { 123,-6053 }, { 124,-6053 }, { 125,-6053 }, { 126,-6053 }, { 127,-6053 }, + { 128,-6053 }, { 129,-6053 }, { 130,-6053 }, { 131,-6053 }, { 132,-6053 }, + { 133,-6053 }, { 134,-6053 }, { 135,-6053 }, { 136,-6053 }, { 137,-6053 }, + { 138,-6053 }, { 139,-6053 }, { 140,-6053 }, { 141,-6053 }, { 142,-6053 }, + { 143,-6053 }, { 144,-6053 }, { 145,-6053 }, { 146,-6053 }, { 147,-6053 }, + + { 148,-6053 }, { 149,-6053 }, { 150,-6053 }, { 151,-6053 }, { 152,-6053 }, + { 153,-6053 }, { 154,-6053 }, { 155,-6053 }, { 156,-6053 }, { 157,-6053 }, + { 158,-6053 }, { 159,-6053 }, { 160,-6053 }, { 161,-6053 }, { 162,-6053 }, + { 163,-6053 }, { 164,-6053 }, { 165,-6053 }, { 166,-6053 }, { 167,-6053 }, + { 168,-6053 }, { 169,-6053 }, { 170,-6053 }, { 171,-6053 }, { 172,-6053 }, + { 173,-6053 }, { 174,-6053 }, { 175,-6053 }, { 176,-6053 }, { 177,-6053 }, + { 178,-6053 }, { 179,-6053 }, { 180,-6053 }, { 181,-6053 }, { 182,-6053 }, + { 183,-6053 }, { 184,-6053 }, { 185,-6053 }, { 186,-6053 }, { 187,-6053 }, + { 188,-6053 }, { 189,-6053 }, { 190,-6053 }, { 191,-6053 }, { 192,-6053 }, + { 193,-6053 }, { 194,-6053 }, { 195,-6053 }, { 196,-6053 }, { 197,-6053 }, + + { 198,-6053 }, { 199,-6053 }, { 200,-6053 }, { 201,-6053 }, { 202,-6053 }, + { 203,-6053 }, { 204,-6053 }, { 205,-6053 }, { 206,-6053 }, { 207,-6053 }, + { 208,-6053 }, { 209,-6053 }, { 210,-6053 }, { 211,-6053 }, { 212,-6053 }, + { 213,-6053 }, { 214,-6053 }, { 215,-6053 }, { 216,-6053 }, { 217,-6053 }, + { 218,-6053 }, { 219,-6053 }, { 220,-6053 }, { 221,-6053 }, { 222,-6053 }, + { 223,-6053 }, { 224,-6053 }, { 225,-6053 }, { 226,-6053 }, { 227,-6053 }, + { 228,-6053 }, { 229,-6053 }, { 230,-6053 }, { 231,-6053 }, { 232,-6053 }, + { 233,-6053 }, { 234,-6053 }, { 235,-6053 }, { 236,-6053 }, { 237,-6053 }, + { 238,-6053 }, { 239,-6053 }, { 240,-6053 }, { 241,-6053 }, { 242,-6053 }, + { 243,-6053 }, { 244,-6053 }, { 245,-6053 }, { 246,-6053 }, { 247,-6053 }, + + { 248,-6053 }, { 249,-6053 }, { 250,-6053 }, { 251,-6053 }, { 252,-6053 }, + { 253,-6053 }, { 254,-6053 }, { 255,-6053 }, { 256,-6053 }, { 0, 24 }, + { 0,7720 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 9,-13423 }, + { 10,-13423 }, { 0, 0 }, { 12,-13423 }, { 13,-13423 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 32,-13423 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 39,3592 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 45,-45496 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 85,-49880 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 117,-49880 }, { 0, 24 }, { 0,7601 }, + { 1,-6430 }, { 2,-6430 }, { 3,-6430 }, { 4,-6430 }, { 5,-6430 }, + { 6,-6430 }, { 7,-6430 }, { 8,-6430 }, { 9,-6172 }, { 10,-18590 }, + { 11,-6430 }, { 12,-6172 }, { 13,-18590 }, { 14,-6430 }, { 15,-6430 }, + { 16,-6430 }, { 17,-6430 }, { 18,-6430 }, { 19,-6430 }, { 20,-6430 }, + + { 21,-6430 }, { 22,-6430 }, { 23,-6430 }, { 24,-6430 }, { 25,-6430 }, + { 26,-6430 }, { 27,-6430 }, { 28,-6430 }, { 29,-6430 }, { 30,-6430 }, + { 31,-6430 }, { 32,-6172 }, { 33,-6430 }, { 34,-6430 }, { 35,-6430 }, + { 36,-6430 }, { 37,-6430 }, { 38,-6430 }, { 39,3215 }, { 40,-6430 }, + { 41,-6430 }, { 42,-6430 }, { 43,-6430 }, { 44,-6430 }, { 45, 516 }, + { 46,-6430 }, { 47,-6430 }, { 48,-6430 }, { 49,-6430 }, { 50,-6430 }, + { 51,-6430 }, { 52,-6430 }, { 53,-6430 }, { 54,-6430 }, { 55,-6430 }, + { 56,-6430 }, { 57,-6430 }, { 58,-6430 }, { 59,-6430 }, { 60,-6430 }, + { 61,-6430 }, { 62,-6430 }, { 63,-6430 }, { 64,-6430 }, { 65,-6430 }, + { 66,-6430 }, { 67,-6430 }, { 68,-6430 }, { 69,-6430 }, { 70,-6430 }, + + { 71,-6430 }, { 72,-6430 }, { 73,-6430 }, { 74,-6430 }, { 75,-6430 }, + { 76,-6430 }, { 77,-6430 }, { 78,-6430 }, { 79,-6430 }, { 80,-6430 }, + { 81,-6430 }, { 82,-6430 }, { 83,-6430 }, { 84,-6430 }, { 85,-5398 }, + { 86,-6430 }, { 87,-6430 }, { 88,-6430 }, { 89,-6430 }, { 90,-6430 }, + { 91,-6430 }, { 92,-6430 }, { 93,-6430 }, { 94,-6430 }, { 95,-6430 }, + { 96,-6430 }, { 97,-6430 }, { 98,-6430 }, { 99,-6430 }, { 100,-6430 }, + { 101,-6430 }, { 102,-6430 }, { 103,-6430 }, { 104,-6430 }, { 105,-6430 }, + { 106,-6430 }, { 107,-6430 }, { 108,-6430 }, { 109,-6430 }, { 110,-6430 }, + { 111,-6430 }, { 112,-6430 }, { 113,-6430 }, { 114,-6430 }, { 115,-6430 }, + { 116,-6430 }, { 117,-5398 }, { 118,-6430 }, { 119,-6430 }, { 120,-6430 }, + + { 121,-6430 }, { 122,-6430 }, { 123,-6430 }, { 124,-6430 }, { 125,-6430 }, + { 126,-6430 }, { 127,-6430 }, { 128,-6430 }, { 129,-6430 }, { 130,-6430 }, + { 131,-6430 }, { 132,-6430 }, { 133,-6430 }, { 134,-6430 }, { 135,-6430 }, + { 136,-6430 }, { 137,-6430 }, { 138,-6430 }, { 139,-6430 }, { 140,-6430 }, + { 141,-6430 }, { 142,-6430 }, { 143,-6430 }, { 144,-6430 }, { 145,-6430 }, + { 146,-6430 }, { 147,-6430 }, { 148,-6430 }, { 149,-6430 }, { 150,-6430 }, + { 151,-6430 }, { 152,-6430 }, { 153,-6430 }, { 154,-6430 }, { 155,-6430 }, + { 156,-6430 }, { 157,-6430 }, { 158,-6430 }, { 159,-6430 }, { 160,-6430 }, + { 161,-6430 }, { 162,-6430 }, { 163,-6430 }, { 164,-6430 }, { 165,-6430 }, + { 166,-6430 }, { 167,-6430 }, { 168,-6430 }, { 169,-6430 }, { 170,-6430 }, + + { 171,-6430 }, { 172,-6430 }, { 173,-6430 }, { 174,-6430 }, { 175,-6430 }, + { 176,-6430 }, { 177,-6430 }, { 178,-6430 }, { 179,-6430 }, { 180,-6430 }, + { 181,-6430 }, { 182,-6430 }, { 183,-6430 }, { 184,-6430 }, { 185,-6430 }, + { 186,-6430 }, { 187,-6430 }, { 188,-6430 }, { 189,-6430 }, { 190,-6430 }, + { 191,-6430 }, { 192,-6430 }, { 193,-6430 }, { 194,-6430 }, { 195,-6430 }, + { 196,-6430 }, { 197,-6430 }, { 198,-6430 }, { 199,-6430 }, { 200,-6430 }, + { 201,-6430 }, { 202,-6430 }, { 203,-6430 }, { 204,-6430 }, { 205,-6430 }, + { 206,-6430 }, { 207,-6430 }, { 208,-6430 }, { 209,-6430 }, { 210,-6430 }, + { 211,-6430 }, { 212,-6430 }, { 213,-6430 }, { 214,-6430 }, { 215,-6430 }, + { 216,-6430 }, { 217,-6430 }, { 218,-6430 }, { 219,-6430 }, { 220,-6430 }, + + { 221,-6430 }, { 222,-6430 }, { 223,-6430 }, { 224,-6430 }, { 225,-6430 }, + { 226,-6430 }, { 227,-6430 }, { 228,-6430 }, { 229,-6430 }, { 230,-6430 }, + { 231,-6430 }, { 232,-6430 }, { 233,-6430 }, { 234,-6430 }, { 235,-6430 }, + { 236,-6430 }, { 237,-6430 }, { 238,-6430 }, { 239,-6430 }, { 240,-6430 }, + { 241,-6430 }, { 242,-6430 }, { 243,-6430 }, { 244,-6430 }, { 245,-6430 }, + { 246,-6430 }, { 247,-6430 }, { 248,-6430 }, { 249,-6430 }, { 250,-6430 }, + { 251,-6430 }, { 252,-6430 }, { 253,-6430 }, { 254,-6430 }, { 255,-6430 }, + { 256,-6430 }, { 0, 24 }, { 0,7343 }, { 1,-6688 }, { 2,-6688 }, + { 3,-6688 }, { 4,-6688 }, { 5,-6688 }, { 6,-6688 }, { 7,-6688 }, + { 8,-6688 }, { 9,-6430 }, { 10,-18848 }, { 11,-6688 }, { 12,-6430 }, + + { 13,-18848 }, { 14,-6688 }, { 15,-6688 }, { 16,-6688 }, { 17,-6688 }, + { 18,-6688 }, { 19,-6688 }, { 20,-6688 }, { 21,-6688 }, { 22,-6688 }, + { 23,-6688 }, { 24,-6688 }, { 25,-6688 }, { 26,-6688 }, { 27,-6688 }, + { 28,-6688 }, { 29,-6688 }, { 30,-6688 }, { 31,-6688 }, { 32,-6430 }, + { 33,-6688 }, { 34,-6688 }, { 35,-6688 }, { 36,-6688 }, { 37,-6688 }, + { 38,-6688 }, { 39,2957 }, { 40,-6688 }, { 41,-6688 }, { 42,-6688 }, + { 43,-6688 }, { 44,-6688 }, { 45,-1151 }, { 46,-6688 }, { 47,-6688 }, + { 48,-6688 }, { 49,-6688 }, { 50,-6688 }, { 51,-6688 }, { 52,-6688 }, + { 53,-6688 }, { 54,-6688 }, { 55,-6688 }, { 56,-6688 }, { 57,-6688 }, + { 58,-6688 }, { 59,-6688 }, { 60,-6688 }, { 61,-6688 }, { 62,-6688 }, + + { 63,-6688 }, { 64,-6688 }, { 65,-6688 }, { 66,-6688 }, { 67,-6688 }, + { 68,-6688 }, { 69, 516 }, { 70,-6688 }, { 71,-6688 }, { 72,-6688 }, + { 73,-6688 }, { 74,-6688 }, { 75,-6688 }, { 76,-6688 }, { 77,-6688 }, + { 78,-6688 }, { 79,-6688 }, { 80,-6688 }, { 81,-6688 }, { 82,-6688 }, + { 83,-6688 }, { 84,-6688 }, { 85,-5656 }, { 86,-6688 }, { 87,-6688 }, + { 88,-6688 }, { 89,-6688 }, { 90,-6688 }, { 91,-6688 }, { 92,-6688 }, + { 93,-6688 }, { 94,-6688 }, { 95,-6688 }, { 96,-6688 }, { 97,-6688 }, + { 98,-6688 }, { 99,-6688 }, { 100,-6688 }, { 101, 516 }, { 102,-6688 }, + { 103,-6688 }, { 104,-6688 }, { 105,-6688 }, { 106,-6688 }, { 107,-6688 }, + { 108,-6688 }, { 109,-6688 }, { 110,-6688 }, { 111,-6688 }, { 112,-6688 }, + + { 113,-6688 }, { 114,-6688 }, { 115,-6688 }, { 116,-6688 }, { 117,-5656 }, + { 118,-6688 }, { 119,-6688 }, { 120,-6688 }, { 121,-6688 }, { 122,-6688 }, + { 123,-6688 }, { 124,-6688 }, { 125,-6688 }, { 126,-6688 }, { 127,-6688 }, + { 128,-6688 }, { 129,-6688 }, { 130,-6688 }, { 131,-6688 }, { 132,-6688 }, + { 133,-6688 }, { 134,-6688 }, { 135,-6688 }, { 136,-6688 }, { 137,-6688 }, + { 138,-6688 }, { 139,-6688 }, { 140,-6688 }, { 141,-6688 }, { 142,-6688 }, + { 143,-6688 }, { 144,-6688 }, { 145,-6688 }, { 146,-6688 }, { 147,-6688 }, + { 148,-6688 }, { 149,-6688 }, { 150,-6688 }, { 151,-6688 }, { 152,-6688 }, + { 153,-6688 }, { 154,-6688 }, { 155,-6688 }, { 156,-6688 }, { 157,-6688 }, + { 158,-6688 }, { 159,-6688 }, { 160,-6688 }, { 161,-6688 }, { 162,-6688 }, + + { 163,-6688 }, { 164,-6688 }, { 165,-6688 }, { 166,-6688 }, { 167,-6688 }, + { 168,-6688 }, { 169,-6688 }, { 170,-6688 }, { 171,-6688 }, { 172,-6688 }, + { 173,-6688 }, { 174,-6688 }, { 175,-6688 }, { 176,-6688 }, { 177,-6688 }, + { 178,-6688 }, { 179,-6688 }, { 180,-6688 }, { 181,-6688 }, { 182,-6688 }, + { 183,-6688 }, { 184,-6688 }, { 185,-6688 }, { 186,-6688 }, { 187,-6688 }, + { 188,-6688 }, { 189,-6688 }, { 190,-6688 }, { 191,-6688 }, { 192,-6688 }, + { 193,-6688 }, { 194,-6688 }, { 195,-6688 }, { 196,-6688 }, { 197,-6688 }, + { 198,-6688 }, { 199,-6688 }, { 200,-6688 }, { 201,-6688 }, { 202,-6688 }, + { 203,-6688 }, { 204,-6688 }, { 205,-6688 }, { 206,-6688 }, { 207,-6688 }, + { 208,-6688 }, { 209,-6688 }, { 210,-6688 }, { 211,-6688 }, { 212,-6688 }, + + { 213,-6688 }, { 214,-6688 }, { 215,-6688 }, { 216,-6688 }, { 217,-6688 }, + { 218,-6688 }, { 219,-6688 }, { 220,-6688 }, { 221,-6688 }, { 222,-6688 }, + { 223,-6688 }, { 224,-6688 }, { 225,-6688 }, { 226,-6688 }, { 227,-6688 }, + { 228,-6688 }, { 229,-6688 }, { 230,-6688 }, { 231,-6688 }, { 232,-6688 }, + { 233,-6688 }, { 234,-6688 }, { 235,-6688 }, { 236,-6688 }, { 237,-6688 }, + { 238,-6688 }, { 239,-6688 }, { 240,-6688 }, { 241,-6688 }, { 242,-6688 }, + { 243,-6688 }, { 244,-6688 }, { 245,-6688 }, { 246,-6688 }, { 247,-6688 }, + { 248,-6688 }, { 249,-6688 }, { 250,-6688 }, { 251,-6688 }, { 252,-6688 }, + { 253,-6688 }, { 254,-6688 }, { 255,-6688 }, { 256,-6688 }, { 0, 24 }, + { 0,7085 }, { 1,-6946 }, { 2,-6946 }, { 3,-6946 }, { 4,-6946 }, + + { 5,-6946 }, { 6,-6946 }, { 7,-6946 }, { 8,-6946 }, { 9,-6688 }, + { 10,-19106 }, { 11,-6946 }, { 12,-6688 }, { 13,-19106 }, { 14,-6946 }, + { 15,-6946 }, { 16,-6946 }, { 17,-6946 }, { 18,-6946 }, { 19,-6946 }, + { 20,-6946 }, { 21,-6946 }, { 22,-6946 }, { 23,-6946 }, { 24,-6946 }, + { 25,-6946 }, { 26,-6946 }, { 27,-6946 }, { 28,-6946 }, { 29,-6946 }, + { 30,-6946 }, { 31,-6946 }, { 32,-6688 }, { 33,-6946 }, { 34,-6946 }, + { 35,-6946 }, { 36,-6946 }, { 37,-6946 }, { 38,-6946 }, { 39,-6430 }, + { 40,-6946 }, { 41,-6946 }, { 42,-6946 }, { 43,-6946 }, { 44,-6946 }, + { 45, 0 }, { 46,-6946 }, { 47,-6946 }, { 48,-6946 }, { 49,-6946 }, + { 50,-6946 }, { 51,-6946 }, { 52,-6946 }, { 53,-6946 }, { 54,-6946 }, + + { 55,-6946 }, { 56,-6946 }, { 57,-6946 }, { 58,-6946 }, { 59,-6946 }, + { 60,-6946 }, { 61,-6946 }, { 62,-6946 }, { 63,-6946 }, { 64,-6946 }, + { 65,-6946 }, { 66,-6946 }, { 67,-6946 }, { 68,-6946 }, { 69,-6946 }, + { 70,-6946 }, { 71,-6946 }, { 72,-6946 }, { 73,-6946 }, { 74,-6946 }, + { 75,-6946 }, { 76,-6946 }, { 77,-6946 }, { 78,-6946 }, { 79,-6946 }, + { 80,-6946 }, { 81,-6946 }, { 82,-6946 }, { 83,-6946 }, { 84,-6946 }, + { 85,-5914 }, { 86,-6946 }, { 87,-6946 }, { 88,-6946 }, { 89,-6946 }, + { 90,-6946 }, { 91,-6946 }, { 92,-6946 }, { 93,-6946 }, { 94,-6946 }, + { 95,-6946 }, { 96,-6946 }, { 97,-6946 }, { 98,-6946 }, { 99,-6946 }, + { 100,-6946 }, { 101,-6946 }, { 102,-6946 }, { 103,-6946 }, { 104,-6946 }, + + { 105,-6946 }, { 106,-6946 }, { 107,-6946 }, { 108,-6946 }, { 109,-6946 }, + { 110,-6946 }, { 111,-6946 }, { 112,-6946 }, { 113,-6946 }, { 114,-6946 }, + { 115,-6946 }, { 116,-6946 }, { 117,-5914 }, { 118,-6946 }, { 119,-6946 }, + { 120,-6946 }, { 121,-6946 }, { 122,-6946 }, { 123,-6946 }, { 124,-6946 }, + { 125,-6946 }, { 126,-6946 }, { 127,-6946 }, { 128,-6946 }, { 129,-6946 }, + { 130,-6946 }, { 131,-6946 }, { 132,-6946 }, { 133,-6946 }, { 134,-6946 }, + { 135,-6946 }, { 136,-6946 }, { 137,-6946 }, { 138,-6946 }, { 139,-6946 }, + { 140,-6946 }, { 141,-6946 }, { 142,-6946 }, { 143,-6946 }, { 144,-6946 }, + { 145,-6946 }, { 146,-6946 }, { 147,-6946 }, { 148,-6946 }, { 149,-6946 }, + { 150,-6946 }, { 151,-6946 }, { 152,-6946 }, { 153,-6946 }, { 154,-6946 }, + + { 155,-6946 }, { 156,-6946 }, { 157,-6946 }, { 158,-6946 }, { 159,-6946 }, + { 160,-6946 }, { 161,-6946 }, { 162,-6946 }, { 163,-6946 }, { 164,-6946 }, + { 165,-6946 }, { 166,-6946 }, { 167,-6946 }, { 168,-6946 }, { 169,-6946 }, + { 170,-6946 }, { 171,-6946 }, { 172,-6946 }, { 173,-6946 }, { 174,-6946 }, + { 175,-6946 }, { 176,-6946 }, { 177,-6946 }, { 178,-6946 }, { 179,-6946 }, + { 180,-6946 }, { 181,-6946 }, { 182,-6946 }, { 183,-6946 }, { 184,-6946 }, + { 185,-6946 }, { 186,-6946 }, { 187,-6946 }, { 188,-6946 }, { 189,-6946 }, + { 190,-6946 }, { 191,-6946 }, { 192,-6946 }, { 193,-6946 }, { 194,-6946 }, + { 195,-6946 }, { 196,-6946 }, { 197,-6946 }, { 198,-6946 }, { 199,-6946 }, + { 200,-6946 }, { 201,-6946 }, { 202,-6946 }, { 203,-6946 }, { 204,-6946 }, + + { 205,-6946 }, { 206,-6946 }, { 207,-6946 }, { 208,-6946 }, { 209,-6946 }, + { 210,-6946 }, { 211,-6946 }, { 212,-6946 }, { 213,-6946 }, { 214,-6946 }, + { 215,-6946 }, { 216,-6946 }, { 217,-6946 }, { 218,-6946 }, { 219,-6946 }, + { 220,-6946 }, { 221,-6946 }, { 222,-6946 }, { 223,-6946 }, { 224,-6946 }, + { 225,-6946 }, { 226,-6946 }, { 227,-6946 }, { 228,-6946 }, { 229,-6946 }, + { 230,-6946 }, { 231,-6946 }, { 232,-6946 }, { 233,-6946 }, { 234,-6946 }, + { 235,-6946 }, { 236,-6946 }, { 237,-6946 }, { 238,-6946 }, { 239,-6946 }, + { 240,-6946 }, { 241,-6946 }, { 242,-6946 }, { 243,-6946 }, { 244,-6946 }, + { 245,-6946 }, { 246,-6946 }, { 247,-6946 }, { 248,-6946 }, { 249,-6946 }, + { 250,-6946 }, { 251,-6946 }, { 252,-6946 }, { 253,-6946 }, { 254,-6946 }, + + { 255,-6946 }, { 256,-6946 }, { 0, 24 }, { 0,6827 }, { 1,-7204 }, + { 2,-7204 }, { 3,-7204 }, { 4,-7204 }, { 5,-7204 }, { 6,-7204 }, + { 7,-7204 }, { 8,-7204 }, { 9,-6946 }, { 10,-19364 }, { 11,-7204 }, + { 12,-6946 }, { 13,-19364 }, { 14,-7204 }, { 15,-7204 }, { 16,-7204 }, + { 17,-7204 }, { 18,-7204 }, { 19,-7204 }, { 20,-7204 }, { 21,-7204 }, + { 22,-7204 }, { 23,-7204 }, { 24,-7204 }, { 25,-7204 }, { 26,-7204 }, + { 27,-7204 }, { 28,-7204 }, { 29,-7204 }, { 30,-7204 }, { 31,-7204 }, + { 32,-6946 }, { 33,-7204 }, { 34,-7204 }, { 35,-7204 }, { 36,-7204 }, + { 37,-7204 }, { 38,-7204 }, { 39,-6688 }, { 40,-7204 }, { 41,-7204 }, + { 42,-7204 }, { 43,-7204 }, { 44,-7204 }, { 45,-1667 }, { 46,-7204 }, + + { 47,-7204 }, { 48,-7204 }, { 49,-7204 }, { 50,-7204 }, { 51,-7204 }, + { 52,-7204 }, { 53,-7204 }, { 54,-7204 }, { 55,-7204 }, { 56,-7204 }, + { 57,-7204 }, { 58,-7204 }, { 59,-7204 }, { 60,-7204 }, { 61,-7204 }, + { 62,-7204 }, { 63,-7204 }, { 64,-7204 }, { 65,-7204 }, { 66,-7204 }, + { 67,-7204 }, { 68,-7204 }, { 69,-7204 }, { 70,-7204 }, { 71,-7204 }, + { 72,-7204 }, { 73,-7204 }, { 74,-7204 }, { 75,-7204 }, { 76,-7204 }, + { 77,-7204 }, { 78,-7204 }, { 79,-7204 }, { 80,-7204 }, { 81,-7204 }, + { 82,-7204 }, { 83,2957 }, { 84,-7204 }, { 85,-6172 }, { 86,-7204 }, + { 87,-7204 }, { 88,-7204 }, { 89,-7204 }, { 90,-7204 }, { 91,-7204 }, + { 92,-7204 }, { 93,-7204 }, { 94,-7204 }, { 95,-7204 }, { 96,-7204 }, + + { 97,-7204 }, { 98,-7204 }, { 99,-7204 }, { 100,-7204 }, { 101,-7204 }, + { 102,-7204 }, { 103,-7204 }, { 104,-7204 }, { 105,-7204 }, { 106,-7204 }, + { 107,-7204 }, { 108,-7204 }, { 109,-7204 }, { 110,-7204 }, { 111,-7204 }, + { 112,-7204 }, { 113,-7204 }, { 114,-7204 }, { 115,2957 }, { 116,-7204 }, + { 117,-6172 }, { 118,-7204 }, { 119,-7204 }, { 120,-7204 }, { 121,-7204 }, + { 122,-7204 }, { 123,-7204 }, { 124,-7204 }, { 125,-7204 }, { 126,-7204 }, + { 127,-7204 }, { 128,-7204 }, { 129,-7204 }, { 130,-7204 }, { 131,-7204 }, + { 132,-7204 }, { 133,-7204 }, { 134,-7204 }, { 135,-7204 }, { 136,-7204 }, + { 137,-7204 }, { 138,-7204 }, { 139,-7204 }, { 140,-7204 }, { 141,-7204 }, + { 142,-7204 }, { 143,-7204 }, { 144,-7204 }, { 145,-7204 }, { 146,-7204 }, + + { 147,-7204 }, { 148,-7204 }, { 149,-7204 }, { 150,-7204 }, { 151,-7204 }, + { 152,-7204 }, { 153,-7204 }, { 154,-7204 }, { 155,-7204 }, { 156,-7204 }, + { 157,-7204 }, { 158,-7204 }, { 159,-7204 }, { 160,-7204 }, { 161,-7204 }, + { 162,-7204 }, { 163,-7204 }, { 164,-7204 }, { 165,-7204 }, { 166,-7204 }, + { 167,-7204 }, { 168,-7204 }, { 169,-7204 }, { 170,-7204 }, { 171,-7204 }, + { 172,-7204 }, { 173,-7204 }, { 174,-7204 }, { 175,-7204 }, { 176,-7204 }, + { 177,-7204 }, { 178,-7204 }, { 179,-7204 }, { 180,-7204 }, { 181,-7204 }, + { 182,-7204 }, { 183,-7204 }, { 184,-7204 }, { 185,-7204 }, { 186,-7204 }, + { 187,-7204 }, { 188,-7204 }, { 189,-7204 }, { 190,-7204 }, { 191,-7204 }, + { 192,-7204 }, { 193,-7204 }, { 194,-7204 }, { 195,-7204 }, { 196,-7204 }, + + { 197,-7204 }, { 198,-7204 }, { 199,-7204 }, { 200,-7204 }, { 201,-7204 }, + { 202,-7204 }, { 203,-7204 }, { 204,-7204 }, { 205,-7204 }, { 206,-7204 }, + { 207,-7204 }, { 208,-7204 }, { 209,-7204 }, { 210,-7204 }, { 211,-7204 }, + { 212,-7204 }, { 213,-7204 }, { 214,-7204 }, { 215,-7204 }, { 216,-7204 }, + { 217,-7204 }, { 218,-7204 }, { 219,-7204 }, { 220,-7204 }, { 221,-7204 }, + { 222,-7204 }, { 223,-7204 }, { 224,-7204 }, { 225,-7204 }, { 226,-7204 }, + { 227,-7204 }, { 228,-7204 }, { 229,-7204 }, { 230,-7204 }, { 231,-7204 }, + { 232,-7204 }, { 233,-7204 }, { 234,-7204 }, { 235,-7204 }, { 236,-7204 }, + { 237,-7204 }, { 238,-7204 }, { 239,-7204 }, { 240,-7204 }, { 241,-7204 }, + { 242,-7204 }, { 243,-7204 }, { 244,-7204 }, { 245,-7204 }, { 246,-7204 }, + + { 247,-7204 }, { 248,-7204 }, { 249,-7204 }, { 250,-7204 }, { 251,-7204 }, + { 252,-7204 }, { 253,-7204 }, { 254,-7204 }, { 255,-7204 }, { 256,-7204 }, + { 0, 48 }, { 0,6569 }, { 1,-5398 }, { 2,-5398 }, { 3,-5398 }, + { 4,-5398 }, { 5,-5398 }, { 6,-5398 }, { 7,-5398 }, { 8,-5398 }, + { 9,-5140 }, { 10,-4882 }, { 11,-5398 }, { 12,-5140 }, { 13,-4882 }, + { 14,-5398 }, { 15,-5398 }, { 16,-5398 }, { 17,-5398 }, { 18,-5398 }, + { 19,-5398 }, { 20,-5398 }, { 21,-5398 }, { 22,-5398 }, { 23,-5398 }, + { 24,-5398 }, { 25,-5398 }, { 26,-5398 }, { 27,-5398 }, { 28,-5398 }, + { 29,-5398 }, { 30,-5398 }, { 31,-5398 }, { 32,-5140 }, { 33,-5398 }, + { 34,-5398 }, { 35,-5398 }, { 36,-5398 }, { 37,-5398 }, { 38,-5398 }, + + { 39,-10677 }, { 40,-5398 }, { 41,-5398 }, { 42,-5398 }, { 43,-5398 }, + { 44,-5398 }, { 45,-4763 }, { 46,-5398 }, { 47,-5398 }, { 48,-5398 }, + { 49,-5398 }, { 50,-5398 }, { 51,-5398 }, { 52,-5398 }, { 53,-5398 }, + { 54,-5398 }, { 55,-5398 }, { 56,-5398 }, { 57,-5398 }, { 58,-5398 }, + { 59,-5398 }, { 60,-5398 }, { 61,-5398 }, { 62,-5398 }, { 63,-5398 }, + { 64,-5398 }, { 65,-5398 }, { 66,-5398 }, { 67,-5398 }, { 68,-5398 }, + { 69,-5398 }, { 70,-5398 }, { 71,-5398 }, { 72,-5398 }, { 73,-5398 }, + { 74,-5398 }, { 75,-5398 }, { 76,-5398 }, { 77,-5398 }, { 78,-5398 }, + { 79,-5398 }, { 80,-5398 }, { 81,-5398 }, { 82,-5398 }, { 83,-5398 }, + { 84,-5398 }, { 85,-4505 }, { 86,-5398 }, { 87,-5398 }, { 88,-5398 }, + + { 89,-5398 }, { 90,-5398 }, { 91,-5398 }, { 92,-5398 }, { 93,-5398 }, + { 94,-5398 }, { 95,-5398 }, { 96,-5398 }, { 97,-5398 }, { 98,-5398 }, + { 99,-5398 }, { 100,-5398 }, { 101,-5398 }, { 102,-5398 }, { 103,-5398 }, + { 104,-5398 }, { 105,-5398 }, { 106,-5398 }, { 107,-5398 }, { 108,-5398 }, + { 109,-5398 }, { 110,-5398 }, { 111,-5398 }, { 112,-5398 }, { 113,-5398 }, + { 114,-5398 }, { 115,-5398 }, { 116,-5398 }, { 117,-4505 }, { 118,-5398 }, + { 119,-5398 }, { 120,-5398 }, { 121,-5398 }, { 122,-5398 }, { 123,-5398 }, + { 124,-5398 }, { 125,-5398 }, { 126,-5398 }, { 127,-5398 }, { 128,-5398 }, + { 129,-5398 }, { 130,-5398 }, { 131,-5398 }, { 132,-5398 }, { 133,-5398 }, + { 134,-5398 }, { 135,-5398 }, { 136,-5398 }, { 137,-5398 }, { 138,-5398 }, + + { 139,-5398 }, { 140,-5398 }, { 141,-5398 }, { 142,-5398 }, { 143,-5398 }, + { 144,-5398 }, { 145,-5398 }, { 146,-5398 }, { 147,-5398 }, { 148,-5398 }, + { 149,-5398 }, { 150,-5398 }, { 151,-5398 }, { 152,-5398 }, { 153,-5398 }, + { 154,-5398 }, { 155,-5398 }, { 156,-5398 }, { 157,-5398 }, { 158,-5398 }, + { 159,-5398 }, { 160,-5398 }, { 161,-5398 }, { 162,-5398 }, { 163,-5398 }, + { 164,-5398 }, { 165,-5398 }, { 166,-5398 }, { 167,-5398 }, { 168,-5398 }, + { 169,-5398 }, { 170,-5398 }, { 171,-5398 }, { 172,-5398 }, { 173,-5398 }, + { 174,-5398 }, { 175,-5398 }, { 176,-5398 }, { 177,-5398 }, { 178,-5398 }, + { 179,-5398 }, { 180,-5398 }, { 181,-5398 }, { 182,-5398 }, { 183,-5398 }, + { 184,-5398 }, { 185,-5398 }, { 186,-5398 }, { 187,-5398 }, { 188,-5398 }, + + { 189,-5398 }, { 190,-5398 }, { 191,-5398 }, { 192,-5398 }, { 193,-5398 }, + { 194,-5398 }, { 195,-5398 }, { 196,-5398 }, { 197,-5398 }, { 198,-5398 }, + { 199,-5398 }, { 200,-5398 }, { 201,-5398 }, { 202,-5398 }, { 203,-5398 }, + { 204,-5398 }, { 205,-5398 }, { 206,-5398 }, { 207,-5398 }, { 208,-5398 }, + { 209,-5398 }, { 210,-5398 }, { 211,-5398 }, { 212,-5398 }, { 213,-5398 }, + { 214,-5398 }, { 215,-5398 }, { 216,-5398 }, { 217,-5398 }, { 218,-5398 }, + { 219,-5398 }, { 220,-5398 }, { 221,-5398 }, { 222,-5398 }, { 223,-5398 }, + { 224,-5398 }, { 225,-5398 }, { 226,-5398 }, { 227,-5398 }, { 228,-5398 }, + { 229,-5398 }, { 230,-5398 }, { 231,-5398 }, { 232,-5398 }, { 233,-5398 }, + { 234,-5398 }, { 235,-5398 }, { 236,-5398 }, { 237,-5398 }, { 238,-5398 }, + + { 239,-5398 }, { 240,-5398 }, { 241,-5398 }, { 242,-5398 }, { 243,-5398 }, + { 244,-5398 }, { 245,-5398 }, { 246,-5398 }, { 247,-5398 }, { 248,-5398 }, + { 249,-5398 }, { 250,-5398 }, { 251,-5398 }, { 252,-5398 }, { 253,-5398 }, + { 254,-5398 }, { 255,-5398 }, { 256,-5398 }, { 0, 48 }, { 0,6311 }, + { 1,-11451 }, { 2,-11451 }, { 3,-11451 }, { 4,-11451 }, { 5,-11451 }, + { 6,-11451 }, { 7,-11451 }, { 8,-11451 }, { 9,-11193 }, { 10,-22063 }, + { 11,-11451 }, { 12,-11193 }, { 13,-22063 }, { 14,-11451 }, { 15,-11451 }, + { 16,-11451 }, { 17,-11451 }, { 18,-11451 }, { 19,-11451 }, { 20,-11451 }, + { 21,-11451 }, { 22,-11451 }, { 23,-11451 }, { 24,-11451 }, { 25,-11451 }, + { 26,-11451 }, { 27,-11451 }, { 28,-11451 }, { 29,-11451 }, { 30,-11451 }, + + { 31,-11451 }, { 32,-11193 }, { 33,-11451 }, { 34,-11451 }, { 35,-11451 }, + { 36,-11451 }, { 37,-11451 }, { 38,-11451 }, { 39,-10935 }, { 40,-11451 }, + { 41,-11451 }, { 42,-11451 }, { 43,-11451 }, { 44,-11451 }, { 45,-5914 }, + { 46,-11451 }, { 47,-11451 }, { 48,-11451 }, { 49,-11451 }, { 50,-11451 }, + { 51,-11451 }, { 52,-11451 }, { 53,-11451 }, { 54,-11451 }, { 55,-11451 }, + { 56,-11451 }, { 57,-11451 }, { 58,-11451 }, { 59,-11451 }, { 60,-11451 }, + { 61,-11451 }, { 62,-11451 }, { 63,-11451 }, { 64,-11451 }, { 65,-11451 }, + { 66,-11451 }, { 67,2699 }, { 68,-11451 }, { 69,-11451 }, { 70,-11451 }, + { 71,-11451 }, { 72,-11451 }, { 73,-11451 }, { 74,-11451 }, { 75,-11451 }, + { 76,-11451 }, { 77,-11451 }, { 78,-11451 }, { 79,-11451 }, { 80,-11451 }, + + { 81,-11451 }, { 82,-11451 }, { 83,-11451 }, { 84,-11451 }, { 85,-10419 }, + { 86,-11451 }, { 87,-11451 }, { 88,-11451 }, { 89,-11451 }, { 90,-11451 }, + { 91,-11451 }, { 92,-11451 }, { 93,-11451 }, { 94,-11451 }, { 95,-11451 }, + { 96,-11451 }, { 97,-11451 }, { 98,-11451 }, { 99,2699 }, { 100,-11451 }, + { 101,-11451 }, { 102,-11451 }, { 103,-11451 }, { 104,-11451 }, { 105,-11451 }, + { 106,-11451 }, { 107,-11451 }, { 108,-11451 }, { 109,-11451 }, { 110,-11451 }, + { 111,-11451 }, { 112,-11451 }, { 113,-11451 }, { 114,-11451 }, { 115,-11451 }, + { 116,-11451 }, { 117,-10419 }, { 118,-11451 }, { 119,-11451 }, { 120,-11451 }, + { 121,-11451 }, { 122,-11451 }, { 123,-11451 }, { 124,-11451 }, { 125,-11451 }, + { 126,-11451 }, { 127,-11451 }, { 128,-11451 }, { 129,-11451 }, { 130,-11451 }, + + { 131,-11451 }, { 132,-11451 }, { 133,-11451 }, { 134,-11451 }, { 135,-11451 }, + { 136,-11451 }, { 137,-11451 }, { 138,-11451 }, { 139,-11451 }, { 140,-11451 }, + { 141,-11451 }, { 142,-11451 }, { 143,-11451 }, { 144,-11451 }, { 145,-11451 }, + { 146,-11451 }, { 147,-11451 }, { 148,-11451 }, { 149,-11451 }, { 150,-11451 }, + { 151,-11451 }, { 152,-11451 }, { 153,-11451 }, { 154,-11451 }, { 155,-11451 }, + { 156,-11451 }, { 157,-11451 }, { 158,-11451 }, { 159,-11451 }, { 160,-11451 }, + { 161,-11451 }, { 162,-11451 }, { 163,-11451 }, { 164,-11451 }, { 165,-11451 }, + { 166,-11451 }, { 167,-11451 }, { 168,-11451 }, { 169,-11451 }, { 170,-11451 }, + { 171,-11451 }, { 172,-11451 }, { 173,-11451 }, { 174,-11451 }, { 175,-11451 }, + { 176,-11451 }, { 177,-11451 }, { 178,-11451 }, { 179,-11451 }, { 180,-11451 }, + + { 181,-11451 }, { 182,-11451 }, { 183,-11451 }, { 184,-11451 }, { 185,-11451 }, + { 186,-11451 }, { 187,-11451 }, { 188,-11451 }, { 189,-11451 }, { 190,-11451 }, + { 191,-11451 }, { 192,-11451 }, { 193,-11451 }, { 194,-11451 }, { 195,-11451 }, + { 196,-11451 }, { 197,-11451 }, { 198,-11451 }, { 199,-11451 }, { 200,-11451 }, + { 201,-11451 }, { 202,-11451 }, { 203,-11451 }, { 204,-11451 }, { 205,-11451 }, + { 206,-11451 }, { 207,-11451 }, { 208,-11451 }, { 209,-11451 }, { 210,-11451 }, + { 211,-11451 }, { 212,-11451 }, { 213,-11451 }, { 214,-11451 }, { 215,-11451 }, + { 216,-11451 }, { 217,-11451 }, { 218,-11451 }, { 219,-11451 }, { 220,-11451 }, + { 221,-11451 }, { 222,-11451 }, { 223,-11451 }, { 224,-11451 }, { 225,-11451 }, + { 226,-11451 }, { 227,-11451 }, { 228,-11451 }, { 229,-11451 }, { 230,-11451 }, + + { 231,-11451 }, { 232,-11451 }, { 233,-11451 }, { 234,-11451 }, { 235,-11451 }, + { 236,-11451 }, { 237,-11451 }, { 238,-11451 }, { 239,-11451 }, { 240,-11451 }, + { 241,-11451 }, { 242,-11451 }, { 243,-11451 }, { 244,-11451 }, { 245,-11451 }, + { 246,-11451 }, { 247,-11451 }, { 248,-11451 }, { 249,-11451 }, { 250,-11451 }, + { 251,-11451 }, { 252,-11451 }, { 253,-11451 }, { 254,-11451 }, { 255,-11451 }, + { 256,-11451 }, { 0, 24 }, { 0,6053 }, { 1,-3989 }, { 2,-3989 }, + { 3,-3989 }, { 4,-3989 }, { 5,-3989 }, { 6,-3989 }, { 7,-3989 }, + { 8,-3989 }, { 9,-3731 }, { 10,-15725 }, { 11,-3989 }, { 12,-3731 }, + { 13,-15725 }, { 14,-3989 }, { 15,-3989 }, { 16,-3989 }, { 17,-3989 }, + { 18,-3989 }, { 19,-3989 }, { 20,-3989 }, { 21,-3989 }, { 22,-3989 }, + + { 23,-3989 }, { 24,-3989 }, { 25,-3989 }, { 26,-3989 }, { 27,-3989 }, + { 28,-3989 }, { 29,-3989 }, { 30,-3989 }, { 31,-3989 }, { 32,-3731 }, + { 33,-3989 }, { 34,-3989 }, { 35,-3989 }, { 36,-3989 }, { 37,-3989 }, + { 38,-3989 }, { 39,2699 }, { 40,-3989 }, { 41,-3989 }, { 42,-3989 }, + { 43,-3989 }, { 44,-3989 }, { 45,-2699 }, { 46,-3989 }, { 47,-3989 }, + { 48,-3989 }, { 49,-3989 }, { 50,-3989 }, { 51,-3989 }, { 52,-3989 }, + { 53,-3989 }, { 54,-3989 }, { 55,-3989 }, { 56,-3989 }, { 57,-3989 }, + { 58,-3989 }, { 59,-3989 }, { 60,-3989 }, { 61,-3989 }, { 62,-3989 }, + { 63,-3989 }, { 64,-3989 }, { 65,-3989 }, { 66,-3989 }, { 67,-3989 }, + { 68,-3989 }, { 69,-3989 }, { 70,-3989 }, { 71,-3989 }, { 72,-3989 }, + + { 73,-3989 }, { 74,-3989 }, { 75,-3989 }, { 76,-3989 }, { 77,-3989 }, + { 78,-3989 }, { 79,-3989 }, { 80,-3989 }, { 81,-3989 }, { 82,-3989 }, + { 83,-3989 }, { 84,-3989 }, { 85,-2957 }, { 86,-3989 }, { 87,-3989 }, + { 88,-3989 }, { 89,-3989 }, { 90,-3989 }, { 91,-3989 }, { 92,-3989 }, + { 93,-3989 }, { 94,-3989 }, { 95,-3989 }, { 96,-3989 }, { 97,-3989 }, + { 98,-3989 }, { 99,-3989 }, { 100,-3989 }, { 101,-3989 }, { 102,-3989 }, + { 103,-3989 }, { 104,-3989 }, { 105,-3989 }, { 106,-3989 }, { 107,-3989 }, + { 108,-3989 }, { 109,-3989 }, { 110,-3989 }, { 111,-3989 }, { 112,-3989 }, + { 113,-3989 }, { 114,-3989 }, { 115,-3989 }, { 116,-3989 }, { 117,-2957 }, + { 118,-3989 }, { 119,-3989 }, { 120,-3989 }, { 121,-3989 }, { 122,-3989 }, + + { 123,-3989 }, { 124,-3989 }, { 125,-3989 }, { 126,-3989 }, { 127,-3989 }, + { 128,-3989 }, { 129,-3989 }, { 130,-3989 }, { 131,-3989 }, { 132,-3989 }, + { 133,-3989 }, { 134,-3989 }, { 135,-3989 }, { 136,-3989 }, { 137,-3989 }, + { 138,-3989 }, { 139,-3989 }, { 140,-3989 }, { 141,-3989 }, { 142,-3989 }, + { 143,-3989 }, { 144,-3989 }, { 145,-3989 }, { 146,-3989 }, { 147,-3989 }, + { 148,-3989 }, { 149,-3989 }, { 150,-3989 }, { 151,-3989 }, { 152,-3989 }, + { 153,-3989 }, { 154,-3989 }, { 155,-3989 }, { 156,-3989 }, { 157,-3989 }, + { 158,-3989 }, { 159,-3989 }, { 160,-3989 }, { 161,-3989 }, { 162,-3989 }, + { 163,-3989 }, { 164,-3989 }, { 165,-3989 }, { 166,-3989 }, { 167,-3989 }, + { 168,-3989 }, { 169,-3989 }, { 170,-3989 }, { 171,-3989 }, { 172,-3989 }, + + { 173,-3989 }, { 174,-3989 }, { 175,-3989 }, { 176,-3989 }, { 177,-3989 }, + { 178,-3989 }, { 179,-3989 }, { 180,-3989 }, { 181,-3989 }, { 182,-3989 }, + { 183,-3989 }, { 184,-3989 }, { 185,-3989 }, { 186,-3989 }, { 187,-3989 }, + { 188,-3989 }, { 189,-3989 }, { 190,-3989 }, { 191,-3989 }, { 192,-3989 }, + { 193,-3989 }, { 194,-3989 }, { 195,-3989 }, { 196,-3989 }, { 197,-3989 }, + { 198,-3989 }, { 199,-3989 }, { 200,-3989 }, { 201,-3989 }, { 202,-3989 }, + { 203,-3989 }, { 204,-3989 }, { 205,-3989 }, { 206,-3989 }, { 207,-3989 }, + { 208,-3989 }, { 209,-3989 }, { 210,-3989 }, { 211,-3989 }, { 212,-3989 }, + { 213,-3989 }, { 214,-3989 }, { 215,-3989 }, { 216,-3989 }, { 217,-3989 }, + { 218,-3989 }, { 219,-3989 }, { 220,-3989 }, { 221,-3989 }, { 222,-3989 }, + + { 223,-3989 }, { 224,-3989 }, { 225,-3989 }, { 226,-3989 }, { 227,-3989 }, + { 228,-3989 }, { 229,-3989 }, { 230,-3989 }, { 231,-3989 }, { 232,-3989 }, + { 233,-3989 }, { 234,-3989 }, { 235,-3989 }, { 236,-3989 }, { 237,-3989 }, + { 238,-3989 }, { 239,-3989 }, { 240,-3989 }, { 241,-3989 }, { 242,-3989 }, + { 243,-3989 }, { 244,-3989 }, { 245,-3989 }, { 246,-3989 }, { 247,-3989 }, + { 248,-3989 }, { 249,-3989 }, { 250,-3989 }, { 251,-3989 }, { 252,-3989 }, + { 253,-3989 }, { 254,-3989 }, { 255,-3989 }, { 256,-3989 }, { 0, 24 }, + { 0,5795 }, { 1,-4247 }, { 2,-4247 }, { 3,-4247 }, { 4,-4247 }, + { 5,-4247 }, { 6,-4247 }, { 7,-4247 }, { 8,-4247 }, { 9,-3989 }, + { 10,-15983 }, { 11,-4247 }, { 12,-3989 }, { 13,-15983 }, { 14,-4247 }, + + { 15,-4247 }, { 16,-4247 }, { 17,-4247 }, { 18,-4247 }, { 19,-4247 }, + { 20,-4247 }, { 21,-4247 }, { 22,-4247 }, { 23,-4247 }, { 24,-4247 }, + { 25,-4247 }, { 26,-4247 }, { 27,-4247 }, { 28,-4247 }, { 29,-4247 }, + { 30,-4247 }, { 31,-4247 }, { 32,-3989 }, { 33,-4247 }, { 34,-4247 }, + { 35,-4247 }, { 36,-4247 }, { 37,-4247 }, { 38,-4247 }, { 39,2441 }, + { 40,-4247 }, { 41,-4247 }, { 42,-4247 }, { 43,-4247 }, { 44,-4247 }, + { 45,-2957 }, { 46,-4247 }, { 47,-4247 }, { 48,-4247 }, { 49,-4247 }, + { 50,-4247 }, { 51,-4247 }, { 52,-4247 }, { 53,-4247 }, { 54,-4247 }, + { 55,-4247 }, { 56,-4247 }, { 57,-4247 }, { 58,-4247 }, { 59,-4247 }, + { 60,-4247 }, { 61,-4247 }, { 62,-4247 }, { 63,-4247 }, { 64,-4247 }, + + { 65,-4247 }, { 66,-4247 }, { 67,-4247 }, { 68,-4247 }, { 69,-4247 }, + { 70,-4247 }, { 71,-4247 }, { 72,-4247 }, { 73,-4247 }, { 74,-4247 }, + { 75,-4247 }, { 76,-4247 }, { 77,-4247 }, { 78,-4247 }, { 79,-4247 }, + { 80,-4247 }, { 81,-4247 }, { 82,-4247 }, { 83,-4247 }, { 84,-4247 }, + { 85,-3215 }, { 86,-4247 }, { 87,-4247 }, { 88,-4247 }, { 89,-4247 }, + { 90,-4247 }, { 91,-4247 }, { 92,-4247 }, { 93,-4247 }, { 94,-4247 }, + { 95,-4247 }, { 96,-4247 }, { 97,-4247 }, { 98,-4247 }, { 99,-4247 }, + { 100,-4247 }, { 101,-4247 }, { 102,-4247 }, { 103,-4247 }, { 104,-4247 }, + { 105,-4247 }, { 106,-4247 }, { 107,-4247 }, { 108,-4247 }, { 109,-4247 }, + { 110,-4247 }, { 111,-4247 }, { 112,-4247 }, { 113,-4247 }, { 114,-4247 }, + + { 115,-4247 }, { 116,-4247 }, { 117,-3215 }, { 118,-4247 }, { 119,-4247 }, + { 120,-4247 }, { 121,-4247 }, { 122,-4247 }, { 123,-4247 }, { 124,-4247 }, + { 125,-4247 }, { 126,-4247 }, { 127,-4247 }, { 128,-4247 }, { 129,-4247 }, + { 130,-4247 }, { 131,-4247 }, { 132,-4247 }, { 133,-4247 }, { 134,-4247 }, + { 135,-4247 }, { 136,-4247 }, { 137,-4247 }, { 138,-4247 }, { 139,-4247 }, + { 140,-4247 }, { 141,-4247 }, { 142,-4247 }, { 143,-4247 }, { 144,-4247 }, + { 145,-4247 }, { 146,-4247 }, { 147,-4247 }, { 148,-4247 }, { 149,-4247 }, + { 150,-4247 }, { 151,-4247 }, { 152,-4247 }, { 153,-4247 }, { 154,-4247 }, + { 155,-4247 }, { 156,-4247 }, { 157,-4247 }, { 158,-4247 }, { 159,-4247 }, + { 160,-4247 }, { 161,-4247 }, { 162,-4247 }, { 163,-4247 }, { 164,-4247 }, + + { 165,-4247 }, { 166,-4247 }, { 167,-4247 }, { 168,-4247 }, { 169,-4247 }, + { 170,-4247 }, { 171,-4247 }, { 172,-4247 }, { 173,-4247 }, { 174,-4247 }, + { 175,-4247 }, { 176,-4247 }, { 177,-4247 }, { 178,-4247 }, { 179,-4247 }, + { 180,-4247 }, { 181,-4247 }, { 182,-4247 }, { 183,-4247 }, { 184,-4247 }, + { 185,-4247 }, { 186,-4247 }, { 187,-4247 }, { 188,-4247 }, { 189,-4247 }, + { 190,-4247 }, { 191,-4247 }, { 192,-4247 }, { 193,-4247 }, { 194,-4247 }, + { 195,-4247 }, { 196,-4247 }, { 197,-4247 }, { 198,-4247 }, { 199,-4247 }, + { 200,-4247 }, { 201,-4247 }, { 202,-4247 }, { 203,-4247 }, { 204,-4247 }, + { 205,-4247 }, { 206,-4247 }, { 207,-4247 }, { 208,-4247 }, { 209,-4247 }, + { 210,-4247 }, { 211,-4247 }, { 212,-4247 }, { 213,-4247 }, { 214,-4247 }, + + { 215,-4247 }, { 216,-4247 }, { 217,-4247 }, { 218,-4247 }, { 219,-4247 }, + { 220,-4247 }, { 221,-4247 }, { 222,-4247 }, { 223,-4247 }, { 224,-4247 }, + { 225,-4247 }, { 226,-4247 }, { 227,-4247 }, { 228,-4247 }, { 229,-4247 }, + { 230,-4247 }, { 231,-4247 }, { 232,-4247 }, { 233,-4247 }, { 234,-4247 }, + { 235,-4247 }, { 236,-4247 }, { 237,-4247 }, { 238,-4247 }, { 239,-4247 }, + { 240,-4247 }, { 241,-4247 }, { 242,-4247 }, { 243,-4247 }, { 244,-4247 }, + { 245,-4247 }, { 246,-4247 }, { 247,-4247 }, { 248,-4247 }, { 249,-4247 }, + { 250,-4247 }, { 251,-4247 }, { 252,-4247 }, { 253,-4247 }, { 254,-4247 }, + { 255,-4247 }, { 256,-4247 }, { 0, 24 }, { 0,5537 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 9,-15606 }, { 10,-15606 }, { 0, 0 }, + { 12,-15606 }, { 13,-15606 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 32,-15606 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 39,1409 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 45,-47679 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 85,-52063 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, { 0, 0 }, + { 117,-52063 }, { 0, 24 }, { 0,5418 }, { 1,-4624 }, { 2,-4624 }, + { 3,-4624 }, { 4,-4624 }, { 5,-4624 }, { 6,-4624 }, { 7,-4624 }, + { 8,-4624 }, { 9,-4366 }, { 10,-16360 }, { 11,-4624 }, { 12,-4366 }, + { 13,-16360 }, { 14,-4624 }, { 15,-4624 }, { 16,-4624 }, { 17,-4624 }, + { 18,-4624 }, { 19,-4624 }, { 20,-4624 }, { 21,-4624 }, { 22,-4624 }, + { 23,-4624 }, { 24,-4624 }, { 25,-4624 }, { 26,-4624 }, { 27,-4624 }, + { 28,-4624 }, { 29,-4624 }, { 30,-4624 }, { 31,-4624 }, { 32,-4366 }, + { 33,-4624 }, { 34,-4624 }, { 35,-4624 }, { 36,-4624 }, { 37,-4624 }, + + { 38,-4624 }, { 39,2064 }, { 40,-4624 }, { 41,-4624 }, { 42,-4624 }, + { 43,-4624 }, { 44,-4624 }, { 45, 516 }, { 46,-4624 }, { 47,-4624 }, + { 48,-4624 }, { 49,-4624 }, { 50,-4624 }, { 51,-4624 }, { 52,-4624 }, + { 53,-4624 }, { 54,-4624 }, { 55,-4624 }, { 56,-4624 }, { 57,-4624 }, + { 58,-4624 }, { 59,-4624 }, { 60,-4624 }, { 61,-4624 }, { 62,-4624 }, + { 63,-4624 }, { 64,-4624 }, { 65,-4624 }, { 66,-4624 }, { 67,-4624 }, + { 68,-4624 }, { 69,-4624 }, { 70,-4624 }, { 71,-4624 }, { 72,-4624 }, + { 73,-4624 }, { 74,-4624 }, { 75,-4624 }, { 76,-4624 }, { 77,-4624 }, + { 78,-4624 }, { 79,-4624 }, { 80,-4624 }, { 81,-4624 }, { 82,-4624 }, + { 83,-4624 }, { 84,-4624 }, { 85,-3592 }, { 86,-4624 }, { 87,-4624 }, + + { 88,-4624 }, { 89,-4624 }, { 90,-4624 }, { 91,-4624 }, { 92,-4624 }, + { 93,-4624 }, { 94,-4624 }, { 95,-4624 }, { 96,-4624 }, { 97,-4624 }, + { 98,-4624 }, { 99,-4624 }, { 100,-4624 }, { 101,-4624 }, { 102,-4624 }, + { 103,-4624 }, { 104,-4624 }, { 105,-4624 }, { 106,-4624 }, { 107,-4624 }, + { 108,-4624 }, { 109,-4624 }, { 110,-4624 }, { 111,-4624 }, { 112,-4624 }, + { 113,-4624 }, { 114,-4624 }, { 115,-4624 }, { 116,-4624 }, { 117,-3592 }, + { 118,-4624 }, { 119,-4624 }, { 120,-4624 }, { 121,-4624 }, { 122,-4624 }, + { 123,-4624 }, { 124,-4624 }, { 125,-4624 }, { 126,-4624 }, { 127,-4624 }, + { 128,-4624 }, { 129,-4624 }, { 130,-4624 }, { 131,-4624 }, { 132,-4624 }, + { 133,-4624 }, { 134,-4624 }, { 135,-4624 }, { 136,-4624 }, { 137,-4624 }, + + { 138,-4624 }, { 139,-4624 }, { 140,-4624 }, { 141,-4624 }, { 142,-4624 }, + { 143,-4624 }, { 144,-4624 }, { 145,-4624 }, { 146,-4624 }, { 147,-4624 }, + { 148,-4624 }, { 149,-4624 }, { 150,-4624 }, { 151,-4624 }, { 152,-4624 }, + { 153,-4624 }, { 154,-4624 }, { 155,-4624 }, { 156,-4624 }, { 157,-4624 }, + { 158,-4624 }, { 159,-4624 }, { 160,-4624 }, { 161,-4624 }, { 162,-4624 }, + { 163,-4624 }, { 164,-4624 }, { 165,-4624 }, { 166,-4624 }, { 167,-4624 }, + { 168,-4624 }, { 169,-4624 }, { 170,-4624 }, { 171,-4624 }, { 172,-4624 }, + { 173,-4624 }, { 174,-4624 }, { 175,-4624 }, { 176,-4624 }, { 177,-4624 }, + { 178,-4624 }, { 179,-4624 }, { 180,-4624 }, { 181,-4624 }, { 182,-4624 }, + { 183,-4624 }, { 184,-4624 }, { 185,-4624 }, { 186,-4624 }, { 187,-4624 }, + + { 188,-4624 }, { 189,-4624 }, { 190,-4624 }, { 191,-4624 }, { 192,-4624 }, + { 193,-4624 }, { 194,-4624 }, { 195,-4624 }, { 196,-4624 }, { 197,-4624 }, + { 198,-4624 }, { 199,-4624 }, { 200,-4624 }, { 201,-4624 }, { 202,-4624 }, + { 203,-4624 }, { 204,-4624 }, { 205,-4624 }, { 206,-4624 }, { 207,-4624 }, + { 208,-4624 }, { 209,-4624 }, { 210,-4624 }, { 211,-4624 }, { 212,-4624 }, + { 213,-4624 }, { 214,-4624 }, { 215,-4624 }, { 216,-4624 }, { 217,-4624 }, + { 218,-4624 }, { 219,-4624 }, { 220,-4624 }, { 221,-4624 }, { 222,-4624 }, + { 223,-4624 }, { 224,-4624 }, { 225,-4624 }, { 226,-4624 }, { 227,-4624 }, + { 228,-4624 }, { 229,-4624 }, { 230,-4624 }, { 231,-4624 }, { 232,-4624 }, + { 233,-4624 }, { 234,-4624 }, { 235,-4624 }, { 236,-4624 }, { 237,-4624 }, + + { 238,-4624 }, { 239,-4624 }, { 240,-4624 }, { 241,-4624 }, { 242,-4624 }, + { 243,-4624 }, { 244,-4624 }, { 245,-4624 }, { 246,-4624 }, { 247,-4624 }, + { 248,-4624 }, { 249,-4624 }, { 250,-4624 }, { 251,-4624 }, { 252,-4624 }, + { 253,-4624 }, { 254,-4624 }, { 255,-4624 }, { 256,-4624 }, { 0, 24 }, + { 0,5160 }, { 1,-4882 }, { 2,-4882 }, { 3,-4882 }, { 4,-4882 }, + { 5,-4882 }, { 6,-4882 }, { 7,-4882 }, { 8,-4882 }, { 9,-4624 }, + { 10,-16618 }, { 11,-4882 }, { 12,-4624 }, { 13,-16618 }, { 14,-4882 }, + { 15,-4882 }, { 16,-4882 }, { 17,-4882 }, { 18,-4882 }, { 19,-4882 }, + { 20,-4882 }, { 21,-4882 }, { 22,-4882 }, { 23,-4882 }, { 24,-4882 }, + { 25,-4882 }, { 26,-4882 }, { 27,-4882 }, { 28,-4882 }, { 29,-4882 }, + + { 30,-4882 }, { 31,-4882 }, { 32,-4624 }, { 33,-4882 }, { 34,-4882 }, + { 35,-4882 }, { 36,-4882 }, { 37,-4882 }, { 38,-4882 }, { 39,1806 }, + { 40,-4882 }, { 41,-4882 }, { 42,-4882 }, { 43,-4882 }, { 44,-4882 }, + { 45,-3592 }, { 46,-4882 }, { 47,-4882 }, { 48,-4882 }, { 49,-4882 }, + { 50,-4882 }, { 51,-4882 }, { 52,-4882 }, { 53,-4882 }, { 54,-4882 }, + { 55,-4882 }, { 56,-4882 }, { 57,-4882 }, { 58,-4882 }, { 59,-4882 }, + { 60,-4882 }, { 61,-4882 }, { 62,-4882 }, { 63,-4882 }, { 64,-4882 }, + { 65,-4882 }, { 66,-4882 }, { 67,-4882 }, { 68,-4882 }, { 69, 516 }, + { 70,-4882 }, { 71,-4882 }, { 72,-4882 }, { 73,-4882 }, { 74,-4882 }, + { 75,-4882 }, { 76,-4882 }, { 77,-4882 }, { 78,-4882 }, { 79,-4882 }, + + { 80,-4882 }, { 81,-4882 }, { 82,-4882 }, { 83,-4882 }, { 84,-4882 }, + { 85,-3850 }, { 86,-4882 }, { 87,-4882 }, { 88,-4882 }, { 89,-4882 }, + { 90,-4882 }, { 91,-4882 }, { 92,-4882 }, { 93,-4882 }, { 94,-4882 }, + { 95,-4882 }, { 96,-4882 }, { 97,-4882 }, { 98,-4882 }, { 99,-4882 }, + { 100,-4882 }, { 101, 516 }, { 102,-4882 }, { 103,-4882 }, { 104,-4882 }, + { 105,-4882 }, { 106,-4882 }, { 107,-4882 }, { 108,-4882 }, { 109,-4882 }, + { 110,-4882 }, { 111,-4882 }, { 112,-4882 }, { 113,-4882 }, { 114,-4882 }, + { 115,-4882 }, { 116,-4882 }, { 117,-3850 }, { 118,-4882 }, { 119,-4882 }, + { 120,-4882 }, { 121,-4882 }, { 122,-4882 }, { 123,-4882 }, { 124,-4882 }, + { 125,-4882 }, { 126,-4882 }, { 127,-4882 }, { 128,-4882 }, { 129,-4882 }, + + { 130,-4882 }, { 131,-4882 }, { 132,-4882 }, { 133,-4882 }, { 134,-4882 }, + { 135,-4882 }, { 136,-4882 }, { 137,-4882 }, { 138,-4882 }, { 139,-4882 }, + { 140,-4882 }, { 141,-4882 }, { 142,-4882 }, { 143,-4882 }, { 144,-4882 }, + { 145,-4882 }, { 146,-4882 }, { 147,-4882 }, { 148,-4882 }, { 149,-4882 }, + { 150,-4882 }, { 151,-4882 }, { 152,-4882 }, { 153,-4882 }, { 154,-4882 }, + { 155,-4882 }, { 156,-4882 }, { 157,-4882 }, { 158,-4882 }, { 159,-4882 }, + { 160,-4882 }, { 161,-4882 }, { 162,-4882 }, { 163,-4882 }, { 164,-4882 }, + { 165,-4882 }, { 166,-4882 }, { 167,-4882 }, { 168,-4882 }, { 169,-4882 }, + { 170,-4882 }, { 171,-4882 }, { 172,-4882 }, { 173,-4882 }, { 174,-4882 }, + { 175,-4882 }, { 176,-4882 }, { 177,-4882 }, { 178,-4882 }, { 179,-4882 }, + + { 180,-4882 }, { 181,-4882 }, { 182,-4882 }, { 183,-4882 }, { 184,-4882 }, + { 185,-4882 }, { 186,-4882 }, { 187,-4882 }, { 188,-4882 }, { 189,-4882 }, + { 190,-4882 }, { 191,-4882 }, { 192,-4882 }, { 193,-4882 }, { 194,-4882 }, + { 195,-4882 }, { 196,-4882 }, { 197,-4882 }, { 198,-4882 }, { 199,-4882 }, + { 200,-4882 }, { 201,-4882 }, { 202,-4882 }, { 203,-4882 }, { 204,-4882 }, + { 205,-4882 }, { 206,-4882 }, { 207,-4882 }, { 208,-4882 }, { 209,-4882 }, + { 210,-4882 }, { 211,-4882 }, { 212,-4882 }, { 213,-4882 }, { 214,-4882 }, + { 215,-4882 }, { 216,-4882 }, { 217,-4882 }, { 218,-4882 }, { 219,-4882 }, + { 220,-4882 }, { 221,-4882 }, { 222,-4882 }, { 223,-4882 }, { 224,-4882 }, + { 225,-4882 }, { 226,-4882 }, { 227,-4882 }, { 228,-4882 }, { 229,-4882 }, + + { 230,-4882 }, { 231,-4882 }, { 232,-4882 }, { 233,-4882 }, { 234,-4882 }, + { 235,-4882 }, { 236,-4882 }, { 237,-4882 }, { 238,-4882 }, { 239,-4882 }, + { 240,-4882 }, { 241,-4882 }, { 242,-4882 }, { 243,-4882 }, { 244,-4882 }, + { 245,-4882 }, { 246,-4882 }, { 247,-4882 }, { 248,-4882 }, { 249,-4882 }, + { 250,-4882 }, { 251,-4882 }, { 252,-4882 }, { 253,-4882 }, { 254,-4882 }, + { 255,-4882 }, { 256,-4882 }, { 0, 24 }, { 0,4902 }, { 1,-5140 }, + { 2,-5140 }, { 3,-5140 }, { 4,-5140 }, { 5,-5140 }, { 6,-5140 }, + { 7,-5140 }, { 8,-5140 }, { 9,-4882 }, { 10,-16876 }, { 11,-5140 }, + { 12,-4882 }, { 13,-16876 }, { 14,-5140 }, { 15,-5140 }, { 16,-5140 }, + { 17,-5140 }, { 18,-5140 }, { 19,-5140 }, { 20,-5140 }, { 21,-5140 }, + + { 22,-5140 }, { 23,-5140 }, { 24,-5140 }, { 25,-5140 }, { 26,-5140 }, + { 27,-5140 }, { 28,-5140 }, { 29,-5140 }, { 30,-5140 }, { 31,-5140 }, + { 32,-4882 }, { 33,-5140 }, { 34,-5140 }, { 35,-5140 }, { 36,-5140 }, + { 37,-5140 }, { 38,-5140 }, { 39,-4624 }, { 40,-5140 }, { 41,-5140 }, + { 42,-5140 }, { 43,-5140 }, { 44,-5140 }, { 45, 0 }, { 46,-5140 }, + { 47,-5140 }, { 48,-5140 }, { 49,-5140 }, { 50,-5140 }, { 51,-5140 }, + { 52,-5140 }, { 53,-5140 }, { 54,-5140 }, { 55,-5140 }, { 56,-5140 }, + { 57,-5140 }, { 58,-5140 }, { 59,-5140 }, { 60,-5140 }, { 61,-5140 }, + { 62,-5140 }, { 63,-5140 }, { 64,-5140 }, { 65,-5140 }, { 66,-5140 }, + { 67,-5140 }, { 68,-5140 }, { 69,-5140 }, { 70,-5140 }, { 71,-5140 }, + + { 72,-5140 }, { 73,-5140 }, { 74,-5140 }, { 75,-5140 }, { 76,-5140 }, + { 77,-5140 }, { 78,-5140 }, { 79,-5140 }, { 80,-5140 }, { 81,-5140 }, + { 82,-5140 }, { 83,-5140 }, { 84,-5140 }, { 85,-4108 }, { 86,-5140 }, + { 87,-5140 }, { 88,-5140 }, { 89,-5140 }, { 90,-5140 }, { 91,-5140 }, + { 92,-5140 }, { 93,-5140 }, { 94,-5140 }, { 95,-5140 }, { 96,-5140 }, + { 97,-5140 }, { 98,-5140 }, { 99,-5140 }, { 100,-5140 }, { 101,-5140 }, + { 102,-5140 }, { 103,-5140 }, { 104,-5140 }, { 105,-5140 }, { 106,-5140 }, + { 107,-5140 }, { 108,-5140 }, { 109,-5140 }, { 110,-5140 }, { 111,-5140 }, + { 112,-5140 }, { 113,-5140 }, { 114,-5140 }, { 115,-5140 }, { 116,-5140 }, + { 117,-4108 }, { 118,-5140 }, { 119,-5140 }, { 120,-5140 }, { 121,-5140 }, + + { 122,-5140 }, { 123,-5140 }, { 124,-5140 }, { 125,-5140 }, { 126,-5140 }, + { 127,-5140 }, { 128,-5140 }, { 129,-5140 }, { 130,-5140 }, { 131,-5140 }, + { 132,-5140 }, { 133,-5140 }, { 134,-5140 }, { 135,-5140 }, { 136,-5140 }, + { 137,-5140 }, { 138,-5140 }, { 139,-5140 }, { 140,-5140 }, { 141,-5140 }, + { 142,-5140 }, { 143,-5140 }, { 144,-5140 }, { 145,-5140 }, { 146,-5140 }, + { 147,-5140 }, { 148,-5140 }, { 149,-5140 }, { 150,-5140 }, { 151,-5140 }, + { 152,-5140 }, { 153,-5140 }, { 154,-5140 }, { 155,-5140 }, { 156,-5140 }, + { 157,-5140 }, { 158,-5140 }, { 159,-5140 }, { 160,-5140 }, { 161,-5140 }, + { 162,-5140 }, { 163,-5140 }, { 164,-5140 }, { 165,-5140 }, { 166,-5140 }, + { 167,-5140 }, { 168,-5140 }, { 169,-5140 }, { 170,-5140 }, { 171,-5140 }, + + { 172,-5140 }, { 173,-5140 }, { 174,-5140 }, { 175,-5140 }, { 176,-5140 }, + { 177,-5140 }, { 178,-5140 }, { 179,-5140 }, { 180,-5140 }, { 181,-5140 }, + { 182,-5140 }, { 183,-5140 }, { 184,-5140 }, { 185,-5140 }, { 186,-5140 }, + { 187,-5140 }, { 188,-5140 }, { 189,-5140 }, { 190,-5140 }, { 191,-5140 }, + { 192,-5140 }, { 193,-5140 }, { 194,-5140 }, { 195,-5140 }, { 196,-5140 }, + { 197,-5140 }, { 198,-5140 }, { 199,-5140 }, { 200,-5140 }, { 201,-5140 }, + { 202,-5140 }, { 203,-5140 }, { 204,-5140 }, { 205,-5140 }, { 206,-5140 }, + { 207,-5140 }, { 208,-5140 }, { 209,-5140 }, { 210,-5140 }, { 211,-5140 }, + { 212,-5140 }, { 213,-5140 }, { 214,-5140 }, { 215,-5140 }, { 216,-5140 }, + { 217,-5140 }, { 218,-5140 }, { 219,-5140 }, { 220,-5140 }, { 221,-5140 }, + + { 222,-5140 }, { 223,-5140 }, { 224,-5140 }, { 225,-5140 }, { 226,-5140 }, + { 227,-5140 }, { 228,-5140 }, { 229,-5140 }, { 230,-5140 }, { 231,-5140 }, + { 232,-5140 }, { 233,-5140 }, { 234,-5140 }, { 235,-5140 }, { 236,-5140 }, + { 237,-5140 }, { 238,-5140 }, { 239,-5140 }, { 240,-5140 }, { 241,-5140 }, + { 242,-5140 }, { 243,-5140 }, { 244,-5140 }, { 245,-5140 }, { 246,-5140 }, + { 247,-5140 }, { 248,-5140 }, { 249,-5140 }, { 250,-5140 }, { 251,-5140 }, + { 252,-5140 }, { 253,-5140 }, { 254,-5140 }, { 255,-5140 }, { 256,-5140 }, + { 0, 24 }, { 0,4644 }, { 1,-5398 }, { 2,-5398 }, { 3,-5398 }, + { 4,-5398 }, { 5,-5398 }, { 6,-5398 }, { 7,-5398 }, { 8,-5398 }, + { 9,-5140 }, { 10,-17134 }, { 11,-5398 }, { 12,-5140 }, { 13,-17134 }, + + { 14,-5398 }, { 15,-5398 }, { 16,-5398 }, { 17,-5398 }, { 18,-5398 }, + { 19,-5398 }, { 20,-5398 }, { 21,-5398 }, { 22,-5398 }, { 23,-5398 }, + { 24,-5398 }, { 25,-5398 }, { 26,-5398 }, { 27,-5398 }, { 28,-5398 }, + { 29,-5398 }, { 30,-5398 }, { 31,-5398 }, { 32,-5140 }, { 33,-5398 }, + { 34,-5398 }, { 35,-5398 }, { 36,-5398 }, { 37,-5398 }, { 38,-5398 }, + { 39,-4882 }, { 40,-5398 }, { 41,-5398 }, { 42,-5398 }, { 43,-5398 }, + { 44,-5398 }, { 45,-4108 }, { 46,-5398 }, { 47,-5398 }, { 48,-5398 }, + { 49,-5398 }, { 50,-5398 }, { 51,-5398 }, { 52,-5398 }, { 53,-5398 }, + { 54,-5398 }, { 55,-5398 }, { 56,-5398 }, { 57,-5398 }, { 58,-5398 }, + { 59,-5398 }, { 60,-5398 }, { 61,-5398 }, { 62,-5398 }, { 63,-5398 }, + + { 64,-5398 }, { 65,-5398 }, { 66,-5398 }, { 67,-5398 }, { 68,-5398 }, + { 69,-5398 }, { 70,-5398 }, { 71,-5398 }, { 72,-5398 }, { 73,-5398 }, + { 74,-5398 }, { 75,-5398 }, { 76,-5398 }, { 77,-5398 }, { 78,-5398 }, + { 79,-5398 }, { 80,-5398 }, { 81,-5398 }, { 82,-5398 }, { 83,1548 }, + { 84,-5398 }, { 85,-4366 }, { 86,-5398 }, { 87,-5398 }, { 88,-5398 }, + { 89,-5398 }, { 90,-5398 }, { 91,-5398 }, { 92,-5398 }, { 93,-5398 }, + { 94,-5398 }, { 95,-5398 }, { 96,-5398 }, { 97,-5398 }, { 98,-5398 }, + { 99,-5398 }, { 100,-5398 }, { 101,-5398 }, { 102,-5398 }, { 103,-5398 }, + { 104,-5398 }, { 105,-5398 }, { 106,-5398 }, { 107,-5398 }, { 108,-5398 }, + { 109,-5398 }, { 110,-5398 }, { 111,-5398 }, { 112,-5398 }, { 113,-5398 }, + + { 114,-5398 }, { 115,1548 }, { 116,-5398 }, { 117,-4366 }, { 118,-5398 }, + { 119,-5398 }, { 120,-5398 }, { 121,-5398 }, { 122,-5398 }, { 123,-5398 }, + { 124,-5398 }, { 125,-5398 }, { 126,-5398 }, { 127,-5398 }, { 128,-5398 }, + { 129,-5398 }, { 130,-5398 }, { 131,-5398 }, { 132,-5398 }, { 133,-5398 }, + { 134,-5398 }, { 135,-5398 }, { 136,-5398 }, { 137,-5398 }, { 138,-5398 }, + { 139,-5398 }, { 140,-5398 }, { 141,-5398 }, { 142,-5398 }, { 143,-5398 }, + { 144,-5398 }, { 145,-5398 }, { 146,-5398 }, { 147,-5398 }, { 148,-5398 }, + { 149,-5398 }, { 150,-5398 }, { 151,-5398 }, { 152,-5398 }, { 153,-5398 }, + { 154,-5398 }, { 155,-5398 }, { 156,-5398 }, { 157,-5398 }, { 158,-5398 }, + { 159,-5398 }, { 160,-5398 }, { 161,-5398 }, { 162,-5398 }, { 163,-5398 }, + + { 164,-5398 }, { 165,-5398 }, { 166,-5398 }, { 167,-5398 }, { 168,-5398 }, + { 169,-5398 }, { 170,-5398 }, { 171,-5398 }, { 172,-5398 }, { 173,-5398 }, + { 174,-5398 }, { 175,-5398 }, { 176,-5398 }, { 177,-5398 }, { 178,-5398 }, + { 179,-5398 }, { 180,-5398 }, { 181,-5398 }, { 182,-5398 }, { 183,-5398 }, + { 184,-5398 }, { 185,-5398 }, { 186,-5398 }, { 187,-5398 }, { 188,-5398 }, + { 189,-5398 }, { 190,-5398 }, { 191,-5398 }, { 192,-5398 }, { 193,-5398 }, + { 194,-5398 }, { 195,-5398 }, { 196,-5398 }, { 197,-5398 }, { 198,-5398 }, + { 199,-5398 }, { 200,-5398 }, { 201,-5398 }, { 202,-5398 }, { 203,-5398 }, + { 204,-5398 }, { 205,-5398 }, { 206,-5398 }, { 207,-5398 }, { 208,-5398 }, + { 209,-5398 }, { 210,-5398 }, { 211,-5398 }, { 212,-5398 }, { 213,-5398 }, + + { 214,-5398 }, { 215,-5398 }, { 216,-5398 }, { 217,-5398 }, { 218,-5398 }, + { 219,-5398 }, { 220,-5398 }, { 221,-5398 }, { 222,-5398 }, { 223,-5398 }, + { 224,-5398 }, { 225,-5398 }, { 226,-5398 }, { 227,-5398 }, { 228,-5398 }, + { 229,-5398 }, { 230,-5398 }, { 231,-5398 }, { 232,-5398 }, { 233,-5398 }, + { 234,-5398 }, { 235,-5398 }, { 236,-5398 }, { 237,-5398 }, { 238,-5398 }, + { 239,-5398 }, { 240,-5398 }, { 241,-5398 }, { 242,-5398 }, { 243,-5398 }, + { 244,-5398 }, { 245,-5398 }, { 246,-5398 }, { 247,-5398 }, { 248,-5398 }, + { 249,-5398 }, { 250,-5398 }, { 251,-5398 }, { 252,-5398 }, { 253,-5398 }, + { 254,-5398 }, { 255,-5398 }, { 256,-5398 }, { 0, 24 }, { 0,4386 }, + { 1,-3850 }, { 2,-3850 }, { 3,-3850 }, { 4,-3850 }, { 5,-3850 }, + + { 6,-3850 }, { 7,-3850 }, { 8,-3850 }, { 9,-3592 }, { 10,-3334 }, + { 11,-3850 }, { 12,-3592 }, { 13,-3334 }, { 14,-3850 }, { 15,-3850 }, + { 16,-3850 }, { 17,-3850 }, { 18,-3850 }, { 19,-3850 }, { 20,-3850 }, + { 21,-3850 }, { 22,-3850 }, { 23,-3850 }, { 24,-3850 }, { 25,-3850 }, + { 26,-3850 }, { 27,-3850 }, { 28,-3850 }, { 29,-3850 }, { 30,-3850 }, + { 31,-3850 }, { 32,-3592 }, { 33,-3850 }, { 34,-3850 }, { 35,-3850 }, + { 36,-3850 }, { 37,-3850 }, { 38,-3850 }, { 39,-9129 }, { 40,-3850 }, + { 41,-3850 }, { 42,-3850 }, { 43,-3850 }, { 44,-3850 }, { 45,-3215 }, + { 46,-3850 }, { 47,-3850 }, { 48,-3850 }, { 49,-3850 }, { 50,-3850 }, + { 51,-3850 }, { 52,-3850 }, { 53,-3850 }, { 54,-3850 }, { 55,-3850 }, + + { 56,-3850 }, { 57,-3850 }, { 58,-3850 }, { 59,-3850 }, { 60,-3850 }, + { 61,-3850 }, { 62,-3850 }, { 63,-3850 }, { 64,-3850 }, { 65,-3850 }, + { 66,-3850 }, { 67,-3850 }, { 68,-3850 }, { 69,-3850 }, { 70,-3850 }, + { 71,-3850 }, { 72,-3850 }, { 73,-3850 }, { 74,-3850 }, { 75,-3850 }, + { 76,-3850 }, { 77,-3850 }, { 78,-3850 }, { 79,-3850 }, { 80,-3850 }, + { 81,-3850 }, { 82,-3850 }, { 83,-3850 }, { 84,-3850 }, { 85,-2957 }, + { 86,-3850 }, { 87,-3850 }, { 88,-3850 }, { 89,-3850 }, { 90,-3850 }, + { 91,-3850 }, { 92,-3850 }, { 93,-3850 }, { 94,-3850 }, { 95,-3850 }, + { 96,-3850 }, { 97,-3850 }, { 98,-3850 }, { 99,-3850 }, { 100,-3850 }, + { 101,-3850 }, { 102,-3850 }, { 103,-3850 }, { 104,-3850 }, { 105,-3850 }, + + { 106,-3850 }, { 107,-3850 }, { 108,-3850 }, { 109,-3850 }, { 110,-3850 }, + { 111,-3850 }, { 112,-3850 }, { 113,-3850 }, { 114,-3850 }, { 115,-3850 }, + { 116,-3850 }, { 117,-2957 }, { 118,-3850 }, { 119,-3850 }, { 120,-3850 }, + { 121,-3850 }, { 122,-3850 }, { 123,-3850 }, { 124,-3850 }, { 125,-3850 }, + { 126,-3850 }, { 127,-3850 }, { 128,-3850 }, { 129,-3850 }, { 130,-3850 }, + { 131,-3850 }, { 132,-3850 }, { 133,-3850 }, { 134,-3850 }, { 135,-3850 }, + { 136,-3850 }, { 137,-3850 }, { 138,-3850 }, { 139,-3850 }, { 140,-3850 }, + { 141,-3850 }, { 142,-3850 }, { 143,-3850 }, { 144,-3850 }, { 145,-3850 }, + { 146,-3850 }, { 147,-3850 }, { 148,-3850 }, { 149,-3850 }, { 150,-3850 }, + { 151,-3850 }, { 152,-3850 }, { 153,-3850 }, { 154,-3850 }, { 155,-3850 }, + + { 156,-3850 }, { 157,-3850 }, { 158,-3850 }, { 159,-3850 }, { 160,-3850 }, + { 161,-3850 }, { 162,-3850 }, { 163,-3850 }, { 164,-3850 }, { 165,-3850 }, + { 166,-3850 }, { 167,-3850 }, { 168,-3850 }, { 169,-3850 }, { 170,-3850 }, + { 171,-3850 }, { 172,-3850 }, { 173,-3850 }, { 174,-3850 }, { 175,-3850 }, + { 176,-3850 }, { 177,-3850 }, { 178,-3850 }, { 179,-3850 }, { 180,-3850 }, + { 181,-3850 }, { 182,-3850 }, { 183,-3850 }, { 184,-3850 }, { 185,-3850 }, + { 186,-3850 }, { 187,-3850 }, { 188,-3850 }, { 189,-3850 }, { 190,-3850 }, + { 191,-3850 }, { 192,-3850 }, { 193,-3850 }, { 194,-3850 }, { 195,-3850 }, + { 196,-3850 }, { 197,-3850 }, { 198,-3850 }, { 199,-3850 }, { 200,-3850 }, + { 201,-3850 }, { 202,-3850 }, { 203,-3850 }, { 204,-3850 }, { 205,-3850 }, + + { 206,-3850 }, { 207,-3850 }, { 208,-3850 }, { 209,-3850 }, { 210,-3850 }, + { 211,-3850 }, { 212,-3850 }, { 213,-3850 }, { 214,-3850 }, { 215,-3850 }, + { 216,-3850 }, { 217,-3850 }, { 218,-3850 }, { 219,-3850 }, { 220,-3850 }, + { 221,-3850 }, { 222,-3850 }, { 223,-3850 }, { 224,-3850 }, { 225,-3850 }, + { 226,-3850 }, { 227,-3850 }, { 228,-3850 }, { 229,-3850 }, { 230,-3850 }, + { 231,-3850 }, { 232,-3850 }, { 233,-3850 }, { 234,-3850 }, { 235,-3850 }, + { 236,-3850 }, { 237,-3850 }, { 238,-3850 }, { 239,-3850 }, { 240,-3850 }, + { 241,-3850 }, { 242,-3850 }, { 243,-3850 }, { 244,-3850 }, { 245,-3850 }, + { 246,-3850 }, { 247,-3850 }, { 248,-3850 }, { 249,-3850 }, { 250,-3850 }, + { 251,-3850 }, { 252,-3850 }, { 253,-3850 }, { 254,-3850 }, { 255,-3850 }, + + { 256,-3850 }, { 0, 24 }, { 0,4128 }, { 1,-49131 }, { 2,-49131 }, + { 3,-49131 }, { 4,-49131 }, { 5,-49131 }, { 6,-49131 }, { 7,-49131 }, + { 8,-49131 }, { 9,-49131 }, { 10,-49131 }, { 11,-49131 }, { 12,-49131 }, + { 13,-49131 }, { 14,-49131 }, { 15,-49131 }, { 16,-49131 }, { 17,-49131 }, + { 18,-49131 }, { 19,-49131 }, { 20,-49131 }, { 21,-49131 }, { 22,-49131 }, + { 23,-49131 }, { 24,-49131 }, { 25,-49131 }, { 26,-49131 }, { 27,-49131 }, + { 28,-49131 }, { 29,-49131 }, { 30,-49131 }, { 31,-49131 }, { 32,-49131 }, + { 33,-49131 }, { 34,-49131 }, { 35,-49131 }, { 36,-49131 }, { 37,-49131 }, + { 38,-49131 }, { 0, 0 }, { 40,-49131 }, { 41,-49131 }, { 42,-49131 }, + { 43,-49131 }, { 44,-49131 }, { 45,-49131 }, { 46,-49131 }, { 47,-49131 }, + + { 48,-49131 }, { 49,-49131 }, { 50,-49131 }, { 51,-49131 }, { 52,-49131 }, + { 53,-49131 }, { 54,-49131 }, { 55,-49131 }, { 56,-49131 }, { 57,-49131 }, + { 58,-49131 }, { 59,-49131 }, { 60,-49131 }, { 61,-49131 }, { 62,-49131 }, + { 63,-49131 }, { 64,-49131 }, { 65,-49131 }, { 66,-49131 }, { 67,-49131 }, + { 68,-49131 }, { 69,-49131 }, { 70,-49131 }, { 71,-49131 }, { 72,-49131 }, + { 73,-49131 }, { 74,-49131 }, { 75,-49131 }, { 76,-49131 }, { 77,-49131 }, + { 78,-49131 }, { 79,-49131 }, { 80,-49131 }, { 81,-49131 }, { 82,-49131 }, + { 83,-49131 }, { 84,-49131 }, { 85,-49131 }, { 86,-49131 }, { 87,-49131 }, + { 88,-49131 }, { 89,-49131 }, { 90,-49131 }, { 91,-49131 }, { 92,-49131 }, + { 93,-49131 }, { 94,-49131 }, { 95,-49131 }, { 96,-49131 }, { 97,-49131 }, + + { 98,-49131 }, { 99,-49131 }, { 100,-49131 }, { 101,-49131 }, { 102,-49131 }, + { 103,-49131 }, { 104,-49131 }, { 105,-49131 }, { 106,-49131 }, { 107,-49131 }, + { 108,-49131 }, { 109,-49131 }, { 110,-49131 }, { 111,-49131 }, { 112,-49131 }, + { 113,-49131 }, { 114,-49131 }, { 115,-49131 }, { 116,-49131 }, { 117,-49131 }, + { 118,-49131 }, { 119,-49131 }, { 120,-49131 }, { 121,-49131 }, { 122,-49131 }, + { 123,-49131 }, { 124,-49131 }, { 125,-49131 }, { 126,-49131 }, { 127,-49131 }, + { 128,-49131 }, { 129,-49131 }, { 130,-49131 }, { 131,-49131 }, { 132,-49131 }, + { 133,-49131 }, { 134,-49131 }, { 135,-49131 }, { 136,-49131 }, { 137,-49131 }, + { 138,-49131 }, { 139,-49131 }, { 140,-49131 }, { 141,-49131 }, { 142,-49131 }, + { 143,-49131 }, { 144,-49131 }, { 145,-49131 }, { 146,-49131 }, { 147,-49131 }, + + { 148,-49131 }, { 149,-49131 }, { 150,-49131 }, { 151,-49131 }, { 152,-49131 }, + { 153,-49131 }, { 154,-49131 }, { 155,-49131 }, { 156,-49131 }, { 157,-49131 }, + { 158,-49131 }, { 159,-49131 }, { 160,-49131 }, { 161,-49131 }, { 162,-49131 }, + { 163,-49131 }, { 164,-49131 }, { 165,-49131 }, { 166,-49131 }, { 167,-49131 }, + { 168,-49131 }, { 169,-49131 }, { 170,-49131 }, { 171,-49131 }, { 172,-49131 }, + { 173,-49131 }, { 174,-49131 }, { 175,-49131 }, { 176,-49131 }, { 177,-49131 }, + { 178,-49131 }, { 179,-49131 }, { 180,-49131 }, { 181,-49131 }, { 182,-49131 }, + { 183,-49131 }, { 184,-49131 }, { 185,-49131 }, { 186,-49131 }, { 187,-49131 }, + { 188,-49131 }, { 189,-49131 }, { 190,-49131 }, { 191,-49131 }, { 192,-49131 }, + { 193,-49131 }, { 194,-49131 }, { 195,-49131 }, { 196,-49131 }, { 197,-49131 }, + + { 198,-49131 }, { 199,-49131 }, { 200,-49131 }, { 201,-49131 }, { 202,-49131 }, + { 203,-49131 }, { 204,-49131 }, { 205,-49131 }, { 206,-49131 }, { 207,-49131 }, + { 208,-49131 }, { 209,-49131 }, { 210,-49131 }, { 211,-49131 }, { 212,-49131 }, + { 213,-49131 }, { 214,-49131 }, { 215,-49131 }, { 216,-49131 }, { 217,-49131 }, + { 218,-49131 }, { 219,-49131 }, { 220,-49131 }, { 221,-49131 }, { 222,-49131 }, + { 223,-49131 }, { 224,-49131 }, { 225,-49131 }, { 226,-49131 }, { 227,-49131 }, + { 228,-49131 }, { 229,-49131 }, { 230,-49131 }, { 231,-49131 }, { 232,-49131 }, + { 233,-49131 }, { 234,-49131 }, { 235,-49131 }, { 236,-49131 }, { 237,-49131 }, + { 238,-49131 }, { 239,-49131 }, { 240,-49131 }, { 241,-49131 }, { 242,-49131 }, + { 243,-49131 }, { 244,-49131 }, { 245,-49131 }, { 246,-49131 }, { 247,-49131 }, + + { 248,-49131 }, { 249,-49131 }, { 250,-49131 }, { 251,-49131 }, { 252,-49131 }, + { 253,-49131 }, { 254,-49131 }, { 255,-49131 }, { 256,-49131 }, { 0, 24 }, + { 0,3870 }, { 1,-10161 }, { 2,-10161 }, { 3,-10161 }, { 4,-10161 }, + { 5,-10161 }, { 6,-10161 }, { 7,-10161 }, { 8,-10161 }, { 9,-9903 }, + { 10,-22321 }, { 11,-10161 }, { 12,-9903 }, { 13,-22321 }, { 14,-10161 }, + { 15,-10161 }, { 16,-10161 }, { 17,-10161 }, { 18,-10161 }, { 19,-10161 }, + { 20,-10161 }, { 21,-10161 }, { 22,-10161 }, { 23,-10161 }, { 24,-10161 }, + { 25,-10161 }, { 26,-10161 }, { 27,-10161 }, { 28,-10161 }, { 29,-10161 }, + { 30,-10161 }, { 31,-10161 }, { 32,-9903 }, { 33,-10161 }, { 34,-10161 }, + { 35,-10161 }, { 36,-10161 }, { 37,-10161 }, { 38,-10161 }, { 39,-9645 }, + + { 40,-10161 }, { 41,-10161 }, { 42,-10161 }, { 43,-10161 }, { 44,-10161 }, + { 45,-4624 }, { 46,-10161 }, { 47,-10161 }, { 48,-10161 }, { 49,-10161 }, + { 50,-10161 }, { 51,-10161 }, { 52,-10161 }, { 53,-10161 }, { 54,-10161 }, + { 55,-10161 }, { 56,-10161 }, { 57,-10161 }, { 58,-10161 }, { 59,-10161 }, + { 60,-10161 }, { 61,-10161 }, { 62,-10161 }, { 63,-10161 }, { 64,-10161 }, + { 65,-10161 }, { 66,-10161 }, { 67,1032 }, { 68,-10161 }, { 69,-10161 }, + { 70,-10161 }, { 71,-10161 }, { 72,-10161 }, { 73,-10161 }, { 74,-10161 }, + { 75,-10161 }, { 76,-10161 }, { 77,-10161 }, { 78,-10161 }, { 79,-10161 }, + { 80,-10161 }, { 81,-10161 }, { 82,-10161 }, { 83,-10161 }, { 84,-10161 }, + { 85,-9129 }, { 86,-10161 }, { 87,-10161 }, { 88,-10161 }, { 89,-10161 }, + + { 90,-10161 }, { 91,-10161 }, { 92,-10161 }, { 93,-10161 }, { 94,-10161 }, + { 95,-10161 }, { 96,-10161 }, { 97,-10161 }, { 98,-10161 }, { 99,1032 }, + { 100,-10161 }, { 101,-10161 }, { 102,-10161 }, { 103,-10161 }, { 104,-10161 }, + { 105,-10161 }, { 106,-10161 }, { 107,-10161 }, { 108,-10161 }, { 109,-10161 }, + { 110,-10161 }, { 111,-10161 }, { 112,-10161 }, { 113,-10161 }, { 114,-10161 }, + { 115,-10161 }, { 116,-10161 }, { 117,-9129 }, { 118,-10161 }, { 119,-10161 }, + { 120,-10161 }, { 121,-10161 }, { 122,-10161 }, { 123,-10161 }, { 124,-10161 }, + { 125,-10161 }, { 126,-10161 }, { 127,-10161 }, { 128,-10161 }, { 129,-10161 }, + { 130,-10161 }, { 131,-10161 }, { 132,-10161 }, { 133,-10161 }, { 134,-10161 }, + { 135,-10161 }, { 136,-10161 }, { 137,-10161 }, { 138,-10161 }, { 139,-10161 }, + + { 140,-10161 }, { 141,-10161 }, { 142,-10161 }, { 143,-10161 }, { 144,-10161 }, + { 145,-10161 }, { 146,-10161 }, { 147,-10161 }, { 148,-10161 }, { 149,-10161 }, + { 150,-10161 }, { 151,-10161 }, { 152,-10161 }, { 153,-10161 }, { 154,-10161 }, + { 155,-10161 }, { 156,-10161 }, { 157,-10161 }, { 158,-10161 }, { 159,-10161 }, + { 160,-10161 }, { 161,-10161 }, { 162,-10161 }, { 163,-10161 }, { 164,-10161 }, + { 165,-10161 }, { 166,-10161 }, { 167,-10161 }, { 168,-10161 }, { 169,-10161 }, + { 170,-10161 }, { 171,-10161 }, { 172,-10161 }, { 173,-10161 }, { 174,-10161 }, + { 175,-10161 }, { 176,-10161 }, { 177,-10161 }, { 178,-10161 }, { 179,-10161 }, + { 180,-10161 }, { 181,-10161 }, { 182,-10161 }, { 183,-10161 }, { 184,-10161 }, + { 185,-10161 }, { 186,-10161 }, { 187,-10161 }, { 188,-10161 }, { 189,-10161 }, + + { 190,-10161 }, { 191,-10161 }, { 192,-10161 }, { 193,-10161 }, { 194,-10161 }, + { 195,-10161 }, { 196,-10161 }, { 197,-10161 }, { 198,-10161 }, { 199,-10161 }, + { 200,-10161 }, { 201,-10161 }, { 202,-10161 }, { 203,-10161 }, { 204,-10161 }, + { 205,-10161 }, { 206,-10161 }, { 207,-10161 }, { 208,-10161 }, { 209,-10161 }, + { 210,-10161 }, { 211,-10161 }, { 212,-10161 }, { 213,-10161 }, { 214,-10161 }, + { 215,-10161 }, { 216,-10161 }, { 217,-10161 }, { 218,-10161 }, { 219,-10161 }, + { 220,-10161 }, { 221,-10161 }, { 222,-10161 }, { 223,-10161 }, { 224,-10161 }, + { 225,-10161 }, { 226,-10161 }, { 227,-10161 }, { 228,-10161 }, { 229,-10161 }, + { 230,-10161 }, { 231,-10161 }, { 232,-10161 }, { 233,-10161 }, { 234,-10161 }, + { 235,-10161 }, { 236,-10161 }, { 237,-10161 }, { 238,-10161 }, { 239,-10161 }, + + { 240,-10161 }, { 241,-10161 }, { 242,-10161 }, { 243,-10161 }, { 244,-10161 }, + { 245,-10161 }, { 246,-10161 }, { 247,-10161 }, { 248,-10161 }, { 249,-10161 }, + { 250,-10161 }, { 251,-10161 }, { 252,-10161 }, { 253,-10161 }, { 254,-10161 }, + { 255,-10161 }, { 256,-10161 }, { 0, 48 }, { 0,3612 }, { 1,-14150 }, + { 2,-14150 }, { 3,-14150 }, { 4,-14150 }, { 5,-14150 }, { 6,-14150 }, + { 7,-14150 }, { 8,-14150 }, { 9,-13892 }, { 10,-24762 }, { 11,-14150 }, + { 12,-13892 }, { 13,-24762 }, { 14,-14150 }, { 15,-14150 }, { 16,-14150 }, + { 17,-14150 }, { 18,-14150 }, { 19,-14150 }, { 20,-14150 }, { 21,-14150 }, + { 22,-14150 }, { 23,-14150 }, { 24,-14150 }, { 25,-14150 }, { 26,-14150 }, + { 27,-14150 }, { 28,-14150 }, { 29,-14150 }, { 30,-14150 }, { 31,-14150 }, + + { 32,-13892 }, { 33,-14150 }, { 34,-14150 }, { 35,-14150 }, { 36,-14150 }, + { 37,-14150 }, { 38,-14150 }, { 39,-13634 }, { 40,-14150 }, { 41,-14150 }, + { 42,-14150 }, { 43,-14150 }, { 44,-14150 }, { 45,-8613 }, { 46,-14150 }, + { 47,-14150 }, { 48,-14150 }, { 49,-14150 }, { 50,-14150 }, { 51,-14150 }, + { 52,-14150 }, { 53,-14150 }, { 54,-14150 }, { 55,-14150 }, { 56,-14150 }, + { 57,-14150 }, { 58,-14150 }, { 59,-14150 }, { 60,-14150 }, { 61,-14150 }, + { 62,-14150 }, { 63,-14150 }, { 64,-14150 }, { 65,1032 }, { 66,-14150 }, + { 67,-14150 }, { 68,-14150 }, { 69,-14150 }, { 70,-14150 }, { 71,-14150 }, + { 72,-14150 }, { 73,-14150 }, { 74,-14150 }, { 75,-14150 }, { 76,-14150 }, + { 77,-14150 }, { 78,-14150 }, { 79,-14150 }, { 80,-14150 }, { 81,-14150 }, + + { 82,-14150 }, { 83,-14150 }, { 84,-14150 }, { 85,-13118 }, { 86,-14150 }, + { 87,-14150 }, { 88,-14150 }, { 89,-14150 }, { 90,-14150 }, { 91,-14150 }, + { 92,-14150 }, { 93,-14150 }, { 94,-14150 }, { 95,-14150 }, { 96,-14150 }, + { 97,1032 }, { 98,-14150 }, { 99,-14150 }, { 100,-14150 }, { 101,-14150 }, + { 102,-14150 }, { 103,-14150 }, { 104,-14150 }, { 105,-14150 }, { 106,-14150 }, + { 107,-14150 }, { 108,-14150 }, { 109,-14150 }, { 110,-14150 }, { 111,-14150 }, + { 112,-14150 }, { 113,-14150 }, { 114,-14150 }, { 115,-14150 }, { 116,-14150 }, + { 117,-13118 }, { 118,-14150 }, { 119,-14150 }, { 120,-14150 }, { 121,-14150 }, + { 122,-14150 }, { 123,-14150 }, { 124,-14150 }, { 125,-14150 }, { 126,-14150 }, + { 127,-14150 }, { 128,-14150 }, { 129,-14150 }, { 130,-14150 }, { 131,-14150 }, + + { 132,-14150 }, { 133,-14150 }, { 134,-14150 }, { 135,-14150 }, { 136,-14150 }, + { 137,-14150 }, { 138,-14150 }, { 139,-14150 }, { 140,-14150 }, { 141,-14150 }, + { 142,-14150 }, { 143,-14150 }, { 144,-14150 }, { 145,-14150 }, { 146,-14150 }, + { 147,-14150 }, { 148,-14150 }, { 149,-14150 }, { 150,-14150 }, { 151,-14150 }, + { 152,-14150 }, { 153,-14150 }, { 154,-14150 }, { 155,-14150 }, { 156,-14150 }, + { 157,-14150 }, { 158,-14150 }, { 159,-14150 }, { 160,-14150 }, { 161,-14150 }, + { 162,-14150 }, { 163,-14150 }, { 164,-14150 }, { 165,-14150 }, { 166,-14150 }, + { 167,-14150 }, { 168,-14150 }, { 169,-14150 }, { 170,-14150 }, { 171,-14150 }, + { 172,-14150 }, { 173,-14150 }, { 174,-14150 }, { 175,-14150 }, { 176,-14150 }, + { 177,-14150 }, { 178,-14150 }, { 179,-14150 }, { 180,-14150 }, { 181,-14150 }, + + { 182,-14150 }, { 183,-14150 }, { 184,-14150 }, { 185,-14150 }, { 186,-14150 }, + { 187,-14150 }, { 188,-14150 }, { 189,-14150 }, { 190,-14150 }, { 191,-14150 }, + { 192,-14150 }, { 193,-14150 }, { 194,-14150 }, { 195,-14150 }, { 196,-14150 }, + { 197,-14150 }, { 198,-14150 }, { 199,-14150 }, { 200,-14150 }, { 201,-14150 }, + { 202,-14150 }, { 203,-14150 }, { 204,-14150 }, { 205,-14150 }, { 206,-14150 }, + { 207,-14150 }, { 208,-14150 }, { 209,-14150 }, { 210,-14150 }, { 211,-14150 }, + { 212,-14150 }, { 213,-14150 }, { 214,-14150 }, { 215,-14150 }, { 216,-14150 }, + { 217,-14150 }, { 218,-14150 }, { 219,-14150 }, { 220,-14150 }, { 221,-14150 }, + { 222,-14150 }, { 223,-14150 }, { 224,-14150 }, { 225,-14150 }, { 226,-14150 }, + { 227,-14150 }, { 228,-14150 }, { 229,-14150 }, { 230,-14150 }, { 231,-14150 }, + + { 232,-14150 }, { 233,-14150 }, { 234,-14150 }, { 235,-14150 }, { 236,-14150 }, + { 237,-14150 }, { 238,-14150 }, { 239,-14150 }, { 240,-14150 }, { 241,-14150 }, + { 242,-14150 }, { 243,-14150 }, { 244,-14150 }, { 245,-14150 }, { 246,-14150 }, + { 247,-14150 }, { 248,-14150 }, { 249,-14150 }, { 250,-14150 }, { 251,-14150 }, + { 252,-14150 }, { 253,-14150 }, { 254,-14150 }, { 255,-14150 }, { 256,-14150 }, + { 0, 24 }, { 0,3354 }, { 1,-2699 }, { 2,-2699 }, { 3,-2699 }, + { 4,-2699 }, { 5,-2699 }, { 6,-2699 }, { 7,-2699 }, { 8,-2699 }, + { 9,-2441 }, { 10,-2183 }, { 11,-2699 }, { 12,-2441 }, { 13,-2183 }, + { 14,-2699 }, { 15,-2699 }, { 16,-2699 }, { 17,-2699 }, { 18,-2699 }, + { 19,-2699 }, { 20,-2699 }, { 21,-2699 }, { 22,-2699 }, { 23,-2699 }, + + { 24,-2699 }, { 25,-2699 }, { 26,-2699 }, { 27,-2699 }, { 28,-2699 }, + { 29,-2699 }, { 30,-2699 }, { 31,-2699 }, { 32,-2441 }, { 33,-2699 }, + { 34,-2699 }, { 35,-2699 }, { 36,-2699 }, { 37,-2699 }, { 38,-2699 }, + { 39,-6172 }, { 40,-2699 }, { 41,-2699 }, { 42,-2699 }, { 43,-2699 }, + { 44,-2699 }, { 45,-2064 }, { 46,-2699 }, { 47,-2699 }, { 48,-2699 }, + { 49,-2699 }, { 50,-2699 }, { 51,-2699 }, { 52,-2699 }, { 53,-2699 }, + { 54,-2699 }, { 55,-2699 }, { 56,-2699 }, { 57,-2699 }, { 58,-2699 }, + { 59,-2699 }, { 60,-2699 }, { 61,-2699 }, { 62,-2699 }, { 63,-2699 }, + { 64,-2699 }, { 65,-2699 }, { 66,-2699 }, { 67,-2699 }, { 68,-2699 }, + { 69,-2699 }, { 70,-2699 }, { 71,-2699 }, { 72,-2699 }, { 73,-2699 }, + + { 74,-2699 }, { 75,-2699 }, { 76,-2699 }, { 77,-2699 }, { 78,-2699 }, + { 79,-2699 }, { 80,-2699 }, { 81,-2699 }, { 82,-2699 }, { 83,-2699 }, + { 84,-2699 }, { 85,-1806 }, { 86,-2699 }, { 87,-2699 }, { 88,-2699 }, + { 89,-2699 }, { 90,-2699 }, { 91,-2699 }, { 92,-2699 }, { 93,-2699 }, + { 94,-2699 }, { 95,-2699 }, { 96,-2699 }, { 97,-2699 }, { 98,-2699 }, + { 99,-2699 }, { 100,-2699 }, { 101,-2699 }, { 102,-2699 }, { 103,-2699 }, + { 104,-2699 }, { 105,-2699 }, { 106,-2699 }, { 107,-2699 }, { 108,-2699 }, + { 109,-2699 }, { 110,-2699 }, { 111,-2699 }, { 112,-2699 }, { 113,-2699 }, + { 114,-2699 }, { 115,-2699 }, { 116,-2699 }, { 117,-1806 }, { 118,-2699 }, + { 119,-2699 }, { 120,-2699 }, { 121,-2699 }, { 122,-2699 }, { 123,-2699 }, + + { 124,-2699 }, { 125,-2699 }, { 126,-2699 }, { 127,-2699 }, { 128,-2699 }, + { 129,-2699 }, { 130,-2699 }, { 131,-2699 }, { 132,-2699 }, { 133,-2699 }, + { 134,-2699 }, { 135,-2699 }, { 136,-2699 }, { 137,-2699 }, { 138,-2699 }, + { 139,-2699 }, { 140,-2699 }, { 141,-2699 }, { 142,-2699 }, { 143,-2699 }, + { 144,-2699 }, { 145,-2699 }, { 146,-2699 }, { 147,-2699 }, { 148,-2699 }, + { 149,-2699 }, { 150,-2699 }, { 151,-2699 }, { 152,-2699 }, { 153,-2699 }, + { 154,-2699 }, { 155,-2699 }, { 156,-2699 }, { 157,-2699 }, { 158,-2699 }, + { 159,-2699 }, { 160,-2699 }, { 161,-2699 }, { 162,-2699 }, { 163,-2699 }, + { 164,-2699 }, { 165,-2699 }, { 166,-2699 }, { 167,-2699 }, { 168,-2699 }, + { 169,-2699 }, { 170,-2699 }, { 171,-2699 }, { 172,-2699 }, { 173,-2699 }, + + { 174,-2699 }, { 175,-2699 }, { 176,-2699 }, { 177,-2699 }, { 178,-2699 }, + { 179,-2699 }, { 180,-2699 }, { 181,-2699 }, { 182,-2699 }, { 183,-2699 }, + { 184,-2699 }, { 185,-2699 }, { 186,-2699 }, { 187,-2699 }, { 188,-2699 }, + { 189,-2699 }, { 190,-2699 }, { 191,-2699 }, { 192,-2699 }, { 193,-2699 }, + { 194,-2699 }, { 195,-2699 }, { 196,-2699 }, { 197,-2699 }, { 198,-2699 }, + { 199,-2699 }, { 200,-2699 }, { 201,-2699 }, { 202,-2699 }, { 203,-2699 }, + { 204,-2699 }, { 205,-2699 }, { 206,-2699 }, { 207,-2699 }, { 208,-2699 }, + { 209,-2699 }, { 210,-2699 }, { 211,-2699 }, { 212,-2699 }, { 213,-2699 }, + { 214,-2699 }, { 215,-2699 }, { 216,-2699 }, { 217,-2699 }, { 218,-2699 }, + { 219,-2699 }, { 220,-2699 }, { 221,-2699 }, { 222,-2699 }, { 223,-2699 }, + + { 224,-2699 }, { 225,-2699 }, { 226,-2699 }, { 227,-2699 }, { 228,-2699 }, + { 229,-2699 }, { 230,-2699 }, { 231,-2699 }, { 232,-2699 }, { 233,-2699 }, + { 234,-2699 }, { 235,-2699 }, { 236,-2699 }, { 237,-2699 }, { 238,-2699 }, + { 239,-2699 }, { 240,-2699 }, { 241,-2699 }, { 242,-2699 }, { 243,-2699 }, + { 244,-2699 }, { 245,-2699 }, { 246,-2699 }, { 247,-2699 }, { 248,-2699 }, + { 249,-2699 }, { 250,-2699 }, { 251,-2699 }, { 252,-2699 }, { 253,-2699 }, + { 254,-2699 }, { 255,-2699 }, { 256,-2699 }, { 0, 24 }, { 0,3096 }, + { 1,-6946 }, { 2,-6946 }, { 3,-6946 }, { 4,-6946 }, { 5,-6946 }, + { 6,-6946 }, { 7,-6946 }, { 8,-6946 }, { 9,-6688 }, { 10,-18682 }, + { 11,-6946 }, { 12,-6688 }, { 13,-18682 }, { 14,-6946 }, { 15,-6946 }, + + { 16,-6946 }, { 17,-6946 }, { 18,-6946 }, { 19,-6946 }, { 20,-6946 }, + { 21,-6946 }, { 22,-6946 }, { 23,-6946 }, { 24,-6946 }, { 25,-6946 }, + { 26,-6946 }, { 27,-6946 }, { 28,-6946 }, { 29,-6946 }, { 30,-6946 }, + { 31,-6946 }, { 32,-6688 }, { 33,-6946 }, { 34,-6946 }, { 35,-6946 }, + { 36,-6946 }, { 37,-6946 }, { 38,-6946 }, { 39,-6430 }, { 40,-6946 }, + { 41,-6946 }, { 42,-6946 }, { 43,-6946 }, { 44,-6946 }, { 45,-5656 }, + { 46,-6946 }, { 47,-6946 }, { 48,-6946 }, { 49,-6946 }, { 50,-6946 }, + { 51,-6946 }, { 52,-6946 }, { 53,-6946 }, { 54,-6946 }, { 55,-6946 }, + { 56,-6946 }, { 57,-6946 }, { 58,-6946 }, { 59,-6946 }, { 60,-6946 }, + { 61,-6946 }, { 62,-6946 }, { 63,-6946 }, { 64,-6946 }, { 65,-6946 }, + + { 66,-6946 }, { 67, 774 }, { 68,-6946 }, { 69,-6946 }, { 70,-6946 }, + { 71,-6946 }, { 72,-6946 }, { 73,-6946 }, { 74,-6946 }, { 75,-6946 }, + { 76,-6946 }, { 77,-6946 }, { 78,-6946 }, { 79,-6946 }, { 80,-6946 }, + { 81,-6946 }, { 82,-6946 }, { 83,-6946 }, { 84,-6946 }, { 85,-5914 }, + { 86,-6946 }, { 87,-6946 }, { 88,-6946 }, { 89,-6946 }, { 90,-6946 }, + { 91,-6946 }, { 92,-6946 }, { 93,-6946 }, { 94,-6946 }, { 95,-6946 }, + { 96,-6946 }, { 97,-6946 }, { 98,-6946 }, { 99, 774 }, { 100,-6946 }, + { 101,-6946 }, { 102,-6946 }, { 103,-6946 }, { 104,-6946 }, { 105,-6946 }, + { 106,-6946 }, { 107,-6946 }, { 108,-6946 }, { 109,-6946 }, { 110,-6946 }, + { 111,-6946 }, { 112,-6946 }, { 113,-6946 }, { 114,-6946 }, { 115,-6946 }, + + { 116,-6946 }, { 117,-5914 }, { 118,-6946 }, { 119,-6946 }, { 120,-6946 }, + { 121,-6946 }, { 122,-6946 }, { 123,-6946 }, { 124,-6946 }, { 125,-6946 }, + { 126,-6946 }, { 127,-6946 }, { 128,-6946 }, { 129,-6946 }, { 130,-6946 }, + { 131,-6946 }, { 132,-6946 }, { 133,-6946 }, { 134,-6946 }, { 135,-6946 }, + { 136,-6946 }, { 137,-6946 }, { 138,-6946 }, { 139,-6946 }, { 140,-6946 }, + { 141,-6946 }, { 142,-6946 }, { 143,-6946 }, { 144,-6946 }, { 145,-6946 }, + { 146,-6946 }, { 147,-6946 }, { 148,-6946 }, { 149,-6946 }, { 150,-6946 }, + { 151,-6946 }, { 152,-6946 }, { 153,-6946 }, { 154,-6946 }, { 155,-6946 }, + { 156,-6946 }, { 157,-6946 }, { 158,-6946 }, { 159,-6946 }, { 160,-6946 }, + { 161,-6946 }, { 162,-6946 }, { 163,-6946 }, { 164,-6946 }, { 165,-6946 }, + + { 166,-6946 }, { 167,-6946 }, { 168,-6946 }, { 169,-6946 }, { 170,-6946 }, + { 171,-6946 }, { 172,-6946 }, { 173,-6946 }, { 174,-6946 }, { 175,-6946 }, + { 176,-6946 }, { 177,-6946 }, { 178,-6946 }, { 179,-6946 }, { 180,-6946 }, + { 181,-6946 }, { 182,-6946 }, { 183,-6946 }, { 184,-6946 }, { 185,-6946 }, + { 186,-6946 }, { 187,-6946 }, { 188,-6946 }, { 189,-6946 }, { 190,-6946 }, + { 191,-6946 }, { 192,-6946 }, { 193,-6946 }, { 194,-6946 }, { 195,-6946 }, + { 196,-6946 }, { 197,-6946 }, { 198,-6946 }, { 199,-6946 }, { 200,-6946 }, + { 201,-6946 }, { 202,-6946 }, { 203,-6946 }, { 204,-6946 }, { 205,-6946 }, + { 206,-6946 }, { 207,-6946 }, { 208,-6946 }, { 209,-6946 }, { 210,-6946 }, + { 211,-6946 }, { 212,-6946 }, { 213,-6946 }, { 214,-6946 }, { 215,-6946 }, + + { 216,-6946 }, { 217,-6946 }, { 218,-6946 }, { 219,-6946 }, { 220,-6946 }, + { 221,-6946 }, { 222,-6946 }, { 223,-6946 }, { 224,-6946 }, { 225,-6946 }, + { 226,-6946 }, { 227,-6946 }, { 228,-6946 }, { 229,-6946 }, { 230,-6946 }, + { 231,-6946 }, { 232,-6946 }, { 233,-6946 }, { 234,-6946 }, { 235,-6946 }, + { 236,-6946 }, { 237,-6946 }, { 238,-6946 }, { 239,-6946 }, { 240,-6946 }, + { 241,-6946 }, { 242,-6946 }, { 243,-6946 }, { 244,-6946 }, { 245,-6946 }, + { 246,-6946 }, { 247,-6946 }, { 248,-6946 }, { 249,-6946 }, { 250,-6946 }, + { 251,-6946 }, { 252,-6946 }, { 253,-6946 }, { 254,-6946 }, { 255,-6946 }, + { 256,-6946 }, { 0, 24 }, { 0,2838 }, { 1,-11193 }, { 2,-11193 }, + { 3,-11193 }, { 4,-11193 }, { 5,-11193 }, { 6,-11193 }, { 7,-11193 }, + + { 8,-11193 }, { 9,-10935 }, { 10,-23353 }, { 11,-11193 }, { 12,-10935 }, + { 13,-23353 }, { 14,-11193 }, { 15,-11193 }, { 16,-11193 }, { 17,-11193 }, + { 18,-11193 }, { 19,-11193 }, { 20,-11193 }, { 21,-11193 }, { 22,-11193 }, + { 23,-11193 }, { 24,-11193 }, { 25,-11193 }, { 26,-11193 }, { 27,-11193 }, + { 28,-11193 }, { 29,-11193 }, { 30,-11193 }, { 31,-11193 }, { 32,-10935 }, + { 33,-11193 }, { 34,-11193 }, { 35,-11193 }, { 36,-11193 }, { 37,-11193 }, + { 38,-11193 }, { 39,-10677 }, { 40,-11193 }, { 41,-11193 }, { 42,-11193 }, + { 43,-11193 }, { 44,-11193 }, { 45,-5656 }, { 46,-11193 }, { 47,-11193 }, + { 48,-11193 }, { 49,-11193 }, { 50,-11193 }, { 51,-11193 }, { 52,-11193 }, + { 53,-11193 }, { 54,-11193 }, { 55,-11193 }, { 56,-11193 }, { 57,-11193 }, + + { 58,-11193 }, { 59,-11193 }, { 60,-11193 }, { 61,-11193 }, { 62,-11193 }, + { 63,-11193 }, { 64,-11193 }, { 65, 774 }, { 66,-11193 }, { 67,-11193 }, + { 68,-11193 }, { 69,-11193 }, { 70,-11193 }, { 71,-11193 }, { 72,-11193 }, + { 73,-11193 }, { 74,-11193 }, { 75,-11193 }, { 76,-11193 }, { 77,-11193 }, + { 78,-11193 }, { 79,-11193 }, { 80,-11193 }, { 81,-11193 }, { 82,-11193 }, + { 83,-11193 }, { 84,-11193 }, { 85,-10161 }, { 86,-11193 }, { 87,-11193 }, + { 88,-11193 }, { 89,-11193 }, { 90,-11193 }, { 91,-11193 }, { 92,-11193 }, + { 93,-11193 }, { 94,-11193 }, { 95,-11193 }, { 96,-11193 }, { 97, 774 }, + { 98,-11193 }, { 99,-11193 }, { 100,-11193 }, { 101,-11193 }, { 102,-11193 }, + { 103,-11193 }, { 104,-11193 }, { 105,-11193 }, { 106,-11193 }, { 107,-11193 }, + + { 108,-11193 }, { 109,-11193 }, { 110,-11193 }, { 111,-11193 }, { 112,-11193 }, + { 113,-11193 }, { 114,-11193 }, { 115,-11193 }, { 116,-11193 }, { 117,-10161 }, + { 118,-11193 }, { 119,-11193 }, { 120,-11193 }, { 121,-11193 }, { 122,-11193 }, + { 123,-11193 }, { 124,-11193 }, { 125,-11193 }, { 126,-11193 }, { 127,-11193 }, + { 128,-11193 }, { 129,-11193 }, { 130,-11193 }, { 131,-11193 }, { 132,-11193 }, + { 133,-11193 }, { 134,-11193 }, { 135,-11193 }, { 136,-11193 }, { 137,-11193 }, + { 138,-11193 }, { 139,-11193 }, { 140,-11193 }, { 141,-11193 }, { 142,-11193 }, + { 143,-11193 }, { 144,-11193 }, { 145,-11193 }, { 146,-11193 }, { 147,-11193 }, + { 148,-11193 }, { 149,-11193 }, { 150,-11193 }, { 151,-11193 }, { 152,-11193 }, + { 153,-11193 }, { 154,-11193 }, { 155,-11193 }, { 156,-11193 }, { 157,-11193 }, + + { 158,-11193 }, { 159,-11193 }, { 160,-11193 }, { 161,-11193 }, { 162,-11193 }, + { 163,-11193 }, { 164,-11193 }, { 165,-11193 }, { 166,-11193 }, { 167,-11193 }, + { 168,-11193 }, { 169,-11193 }, { 170,-11193 }, { 171,-11193 }, { 172,-11193 }, + { 173,-11193 }, { 174,-11193 }, { 175,-11193 }, { 176,-11193 }, { 177,-11193 }, + { 178,-11193 }, { 179,-11193 }, { 180,-11193 }, { 181,-11193 }, { 182,-11193 }, + { 183,-11193 }, { 184,-11193 }, { 185,-11193 }, { 186,-11193 }, { 187,-11193 }, + { 188,-11193 }, { 189,-11193 }, { 190,-11193 }, { 191,-11193 }, { 192,-11193 }, + { 193,-11193 }, { 194,-11193 }, { 195,-11193 }, { 196,-11193 }, { 197,-11193 }, + { 198,-11193 }, { 199,-11193 }, { 200,-11193 }, { 201,-11193 }, { 202,-11193 }, + { 203,-11193 }, { 204,-11193 }, { 205,-11193 }, { 206,-11193 }, { 207,-11193 }, + + { 208,-11193 }, { 209,-11193 }, { 210,-11193 }, { 211,-11193 }, { 212,-11193 }, + { 213,-11193 }, { 214,-11193 }, { 215,-11193 }, { 216,-11193 }, { 217,-11193 }, + { 218,-11193 }, { 219,-11193 }, { 220,-11193 }, { 221,-11193 }, { 222,-11193 }, + { 223,-11193 }, { 224,-11193 }, { 225,-11193 }, { 226,-11193 }, { 227,-11193 }, + { 228,-11193 }, { 229,-11193 }, { 230,-11193 }, { 231,-11193 }, { 232,-11193 }, + { 233,-11193 }, { 234,-11193 }, { 235,-11193 }, { 236,-11193 }, { 237,-11193 }, + { 238,-11193 }, { 239,-11193 }, { 240,-11193 }, { 241,-11193 }, { 242,-11193 }, + { 243,-11193 }, { 244,-11193 }, { 245,-11193 }, { 246,-11193 }, { 247,-11193 }, + { 248,-11193 }, { 249,-11193 }, { 250,-11193 }, { 251,-11193 }, { 252,-11193 }, + { 253,-11193 }, { 254,-11193 }, { 255,-11193 }, { 256,-11193 }, { 0, 48 }, + + { 0,2580 }, { 1,-15182 }, { 2,-15182 }, { 3,-15182 }, { 4,-15182 }, + { 5,-15182 }, { 6,-15182 }, { 7,-15182 }, { 8,-15182 }, { 9,-14924 }, + { 10,-25794 }, { 11,-15182 }, { 12,-14924 }, { 13,-25794 }, { 14,-15182 }, + { 15,-15182 }, { 16,-15182 }, { 17,-15182 }, { 18,-15182 }, { 19,-15182 }, + { 20,-15182 }, { 21,-15182 }, { 22,-15182 }, { 23,-15182 }, { 24,-15182 }, + { 25,-15182 }, { 26,-15182 }, { 27,-15182 }, { 28,-15182 }, { 29,-15182 }, + { 30,-15182 }, { 31,-15182 }, { 32,-14924 }, { 33,-15182 }, { 34,-15182 }, + { 35,-15182 }, { 36,-15182 }, { 37,-15182 }, { 38,-15182 }, { 39,-14666 }, + { 40,-15182 }, { 41,-15182 }, { 42,-15182 }, { 43,-15182 }, { 44,-15182 }, + { 45,-9645 }, { 46,-15182 }, { 47,-15182 }, { 48,-15182 }, { 49,-15182 }, + + { 50,-15182 }, { 51,-15182 }, { 52,-15182 }, { 53,-15182 }, { 54,-15182 }, + { 55,-15182 }, { 56,-15182 }, { 57,-15182 }, { 58,-15182 }, { 59,-15182 }, + { 60,-15182 }, { 61,-15182 }, { 62,-15182 }, { 63,-15182 }, { 64,-15182 }, + { 65,-15182 }, { 66,-15182 }, { 67,-15182 }, { 68,-15182 }, { 69,-15182 }, + { 70,-15182 }, { 71,-15182 }, { 72,-15182 }, { 73,-15182 }, { 74,-15182 }, + { 75,-15182 }, { 76,-15182 }, { 77,-15182 }, { 78,-15182 }, { 79,-15182 }, + { 80, 774 }, { 81,-15182 }, { 82,-15182 }, { 83,-15182 }, { 84,-15182 }, + { 85,-14150 }, { 86,-15182 }, { 87,-15182 }, { 88,-15182 }, { 89,-15182 }, + { 90,-15182 }, { 91,-15182 }, { 92,-15182 }, { 93,-15182 }, { 94,-15182 }, + { 95,-15182 }, { 96,-15182 }, { 97,-15182 }, { 98,-15182 }, { 99,-15182 }, + + { 100,-15182 }, { 101,-15182 }, { 102,-15182 }, { 103,-15182 }, { 104,-15182 }, + { 105,-15182 }, { 106,-15182 }, { 107,-15182 }, { 108,-15182 }, { 109,-15182 }, + { 110,-15182 }, { 111,-15182 }, { 112, 774 }, { 113,-15182 }, { 114,-15182 }, + { 115,-15182 }, { 116,-15182 }, { 117,-14150 }, { 118,-15182 }, { 119,-15182 }, + { 120,-15182 }, { 121,-15182 }, { 122,-15182 }, { 123,-15182 }, { 124,-15182 }, + { 125,-15182 }, { 126,-15182 }, { 127,-15182 }, { 128,-15182 }, { 129,-15182 }, + { 130,-15182 }, { 131,-15182 }, { 132,-15182 }, { 133,-15182 }, { 134,-15182 }, + { 135,-15182 }, { 136,-15182 }, { 137,-15182 }, { 138,-15182 }, { 139,-15182 }, + { 140,-15182 }, { 141,-15182 }, { 142,-15182 }, { 143,-15182 }, { 144,-15182 }, + { 145,-15182 }, { 146,-15182 }, { 147,-15182 }, { 148,-15182 }, { 149,-15182 }, + + { 150,-15182 }, { 151,-15182 }, { 152,-15182 }, { 153,-15182 }, { 154,-15182 }, + { 155,-15182 }, { 156,-15182 }, { 157,-15182 }, { 158,-15182 }, { 159,-15182 }, + { 160,-15182 }, { 161,-15182 }, { 162,-15182 }, { 163,-15182 }, { 164,-15182 }, + { 165,-15182 }, { 166,-15182 }, { 167,-15182 }, { 168,-15182 }, { 169,-15182 }, + { 170,-15182 }, { 171,-15182 }, { 172,-15182 }, { 173,-15182 }, { 174,-15182 }, + { 175,-15182 }, { 176,-15182 }, { 177,-15182 }, { 178,-15182 }, { 179,-15182 }, + { 180,-15182 }, { 181,-15182 }, { 182,-15182 }, { 183,-15182 }, { 184,-15182 }, + { 185,-15182 }, { 186,-15182 }, { 187,-15182 }, { 188,-15182 }, { 189,-15182 }, + { 190,-15182 }, { 191,-15182 }, { 192,-15182 }, { 193,-15182 }, { 194,-15182 }, + { 195,-15182 }, { 196,-15182 }, { 197,-15182 }, { 198,-15182 }, { 199,-15182 }, + + { 200,-15182 }, { 201,-15182 }, { 202,-15182 }, { 203,-15182 }, { 204,-15182 }, + { 205,-15182 }, { 206,-15182 }, { 207,-15182 }, { 208,-15182 }, { 209,-15182 }, + { 210,-15182 }, { 211,-15182 }, { 212,-15182 }, { 213,-15182 }, { 214,-15182 }, + { 215,-15182 }, { 216,-15182 }, { 217,-15182 }, { 218,-15182 }, { 219,-15182 }, + { 220,-15182 }, { 221,-15182 }, { 222,-15182 }, { 223,-15182 }, { 224,-15182 }, + { 225,-15182 }, { 226,-15182 }, { 227,-15182 }, { 228,-15182 }, { 229,-15182 }, + { 230,-15182 }, { 231,-15182 }, { 232,-15182 }, { 233,-15182 }, { 234,-15182 }, + { 235,-15182 }, { 236,-15182 }, { 237,-15182 }, { 238,-15182 }, { 239,-15182 }, + { 240,-15182 }, { 241,-15182 }, { 242,-15182 }, { 243,-15182 }, { 244,-15182 }, + { 245,-15182 }, { 246,-15182 }, { 247,-15182 }, { 248,-15182 }, { 249,-15182 }, + + { 250,-15182 }, { 251,-15182 }, { 252,-15182 }, { 253,-15182 }, { 254,-15182 }, + { 255,-15182 }, { 256,-15182 }, { 0, 24 }, { 0,2322 }, { 1,-7720 }, + { 2,-7720 }, { 3,-7720 }, { 4,-7720 }, { 5,-7720 }, { 6,-7720 }, + { 7,-7720 }, { 8,-7720 }, { 9,-7462 }, { 10,-19456 }, { 11,-7720 }, + { 12,-7462 }, { 13,-19456 }, { 14,-7720 }, { 15,-7720 }, { 16,-7720 }, + { 17,-7720 }, { 18,-7720 }, { 19,-7720 }, { 20,-7720 }, { 21,-7720 }, + { 22,-7720 }, { 23,-7720 }, { 24,-7720 }, { 25,-7720 }, { 26,-7720 }, + { 27,-7720 }, { 28,-7720 }, { 29,-7720 }, { 30,-7720 }, { 31,-7720 }, + { 32,-7462 }, { 33,-7720 }, { 34,-7720 }, { 35,-7720 }, { 36,-7720 }, + { 37,-7720 }, { 38,-7720 }, { 39,-7204 }, { 40,-7720 }, { 41,-7720 }, + + { 42,-7720 }, { 43,-7720 }, { 44,-7720 }, { 45,-6430 }, { 46,-7720 }, + { 47,-7720 }, { 48,-7720 }, { 49,-7720 }, { 50,-7720 }, { 51,-7720 }, + { 52,-7720 }, { 53,-7720 }, { 54,-7720 }, { 55,-7720 }, { 56,-7720 }, + { 57,-7720 }, { 58,-7720 }, { 59,-7720 }, { 60,-7720 }, { 61,-7720 }, + { 62,-7720 }, { 63,-7720 }, { 64,-7720 }, { 65, 774 }, { 66,-7720 }, + { 67,-7720 }, { 68,-7720 }, { 69,-7720 }, { 70,-7720 }, { 71,-7720 }, + { 72,-7720 }, { 73,-7720 }, { 74,-7720 }, { 75,-7720 }, { 76,-7720 }, + { 77,-7720 }, { 78,-7720 }, { 79,-7720 }, { 80,-7720 }, { 81,-7720 }, + { 82,-7720 }, { 83,-7720 }, { 84,-7720 }, { 85,-6688 }, { 86,-7720 }, + { 87,-7720 }, { 88,-7720 }, { 89,-7720 }, { 90,-7720 }, { 91,-7720 }, + + { 92,-7720 }, { 93,-7720 }, { 94,-7720 }, { 95,-7720 }, { 96,-7720 }, + { 97, 774 }, { 98,-7720 }, { 99,-7720 }, { 100,-7720 }, { 101,-7720 }, + { 102,-7720 }, { 103,-7720 }, { 104,-7720 }, { 105,-7720 }, { 106,-7720 }, + { 107,-7720 }, { 108,-7720 }, { 109,-7720 }, { 110,-7720 }, { 111,-7720 }, + { 112,-7720 }, { 113,-7720 }, { 114,-7720 }, { 115,-7720 }, { 116,-7720 }, + { 117,-6688 }, { 118,-7720 }, { 119,-7720 }, { 120,-7720 }, { 121,-7720 }, + { 122,-7720 }, { 123,-7720 }, { 124,-7720 }, { 125,-7720 }, { 126,-7720 }, + { 127,-7720 }, { 128,-7720 }, { 129,-7720 }, { 130,-7720 }, { 131,-7720 }, + { 132,-7720 }, { 133,-7720 }, { 134,-7720 }, { 135,-7720 }, { 136,-7720 }, + { 137,-7720 }, { 138,-7720 }, { 139,-7720 }, { 140,-7720 }, { 141,-7720 }, + + { 142,-7720 }, { 143,-7720 }, { 144,-7720 }, { 145,-7720 }, { 146,-7720 }, + { 147,-7720 }, { 148,-7720 }, { 149,-7720 }, { 150,-7720 }, { 151,-7720 }, + { 152,-7720 }, { 153,-7720 }, { 154,-7720 }, { 155,-7720 }, { 156,-7720 }, + { 157,-7720 }, { 158,-7720 }, { 159,-7720 }, { 160,-7720 }, { 161,-7720 }, + { 162,-7720 }, { 163,-7720 }, { 164,-7720 }, { 165,-7720 }, { 166,-7720 }, + { 167,-7720 }, { 168,-7720 }, { 169,-7720 }, { 170,-7720 }, { 171,-7720 }, + { 172,-7720 }, { 173,-7720 }, { 174,-7720 }, { 175,-7720 }, { 176,-7720 }, + { 177,-7720 }, { 178,-7720 }, { 179,-7720 }, { 180,-7720 }, { 181,-7720 }, + { 182,-7720 }, { 183,-7720 }, { 184,-7720 }, { 185,-7720 }, { 186,-7720 }, + { 187,-7720 }, { 188,-7720 }, { 189,-7720 }, { 190,-7720 }, { 191,-7720 }, + + { 192,-7720 }, { 193,-7720 }, { 194,-7720 }, { 195,-7720 }, { 196,-7720 }, + { 197,-7720 }, { 198,-7720 }, { 199,-7720 }, { 200,-7720 }, { 201,-7720 }, + { 202,-7720 }, { 203,-7720 }, { 204,-7720 }, { 205,-7720 }, { 206,-7720 }, + { 207,-7720 }, { 208,-7720 }, { 209,-7720 }, { 210,-7720 }, { 211,-7720 }, + { 212,-7720 }, { 213,-7720 }, { 214,-7720 }, { 215,-7720 }, { 216,-7720 }, + { 217,-7720 }, { 218,-7720 }, { 219,-7720 }, { 220,-7720 }, { 221,-7720 }, + { 222,-7720 }, { 223,-7720 }, { 224,-7720 }, { 225,-7720 }, { 226,-7720 }, + { 227,-7720 }, { 228,-7720 }, { 229,-7720 }, { 230,-7720 }, { 231,-7720 }, + { 232,-7720 }, { 233,-7720 }, { 234,-7720 }, { 235,-7720 }, { 236,-7720 }, + { 237,-7720 }, { 238,-7720 }, { 239,-7720 }, { 240,-7720 }, { 241,-7720 }, + + { 242,-7720 }, { 243,-7720 }, { 244,-7720 }, { 245,-7720 }, { 246,-7720 }, + { 247,-7720 }, { 248,-7720 }, { 249,-7720 }, { 250,-7720 }, { 251,-7720 }, + { 252,-7720 }, { 253,-7720 }, { 254,-7720 }, { 255,-7720 }, { 256,-7720 }, + { 0, 24 }, { 0,2064 }, { 1,-11967 }, { 2,-11967 }, { 3,-11967 }, + { 4,-11967 }, { 5,-11967 }, { 6,-11967 }, { 7,-11967 }, { 8,-11967 }, + { 9,-11709 }, { 10,-24127 }, { 11,-11967 }, { 12,-11709 }, { 13,-24127 }, + { 14,-11967 }, { 15,-11967 }, { 16,-11967 }, { 17,-11967 }, { 18,-11967 }, + { 19,-11967 }, { 20,-11967 }, { 21,-11967 }, { 22,-11967 }, { 23,-11967 }, + { 24,-11967 }, { 25,-11967 }, { 26,-11967 }, { 27,-11967 }, { 28,-11967 }, + { 29,-11967 }, { 30,-11967 }, { 31,-11967 }, { 32,-11709 }, { 33,-11967 }, + + { 34,-11967 }, { 35,-11967 }, { 36,-11967 }, { 37,-11967 }, { 38,-11967 }, + { 39,-11451 }, { 40,-11967 }, { 41,-11967 }, { 42,-11967 }, { 43,-11967 }, + { 44,-11967 }, { 45,-6430 }, { 46,-11967 }, { 47,-11967 }, { 48,-11967 }, + { 49,-11967 }, { 50,-11967 }, { 51,-11967 }, { 52,-11967 }, { 53,-11967 }, + { 54,-11967 }, { 55,-11967 }, { 56,-11967 }, { 57,-11967 }, { 58,-11967 }, + { 59,-11967 }, { 60,-11967 }, { 61,-11967 }, { 62,-11967 }, { 63,-11967 }, + { 64,-11967 }, { 65,-11967 }, { 66,-11967 }, { 67,-11967 }, { 68,-11967 }, + { 69,-11967 }, { 70,-11967 }, { 71,-11967 }, { 72,-11967 }, { 73,-11967 }, + { 74,-11967 }, { 75,-11967 }, { 76,-11967 }, { 77,-11967 }, { 78,-11967 }, + { 79,-11967 }, { 80, 774 }, { 81,-11967 }, { 82,-11967 }, { 83,-11967 }, + + { 84,-11967 }, { 85,-10935 }, { 86,-11967 }, { 87,-11967 }, { 88,-11967 }, + { 89,-11967 }, { 90,-11967 }, { 91,-11967 }, { 92,-11967 }, { 93,-11967 }, + { 94,-11967 }, { 95,-11967 }, { 96,-11967 }, { 97,-11967 }, { 98,-11967 }, + { 99,-11967 }, { 100,-11967 }, { 101,-11967 }, { 102,-11967 }, { 103,-11967 }, + { 104,-11967 }, { 105,-11967 }, { 106,-11967 }, { 107,-11967 }, { 108,-11967 }, + { 109,-11967 }, { 110,-11967 }, { 111,-11967 }, { 112, 774 }, { 113,-11967 }, + { 114,-11967 }, { 115,-11967 }, { 116,-11967 }, { 117,-10935 }, { 118,-11967 }, + { 119,-11967 }, { 120,-11967 }, { 121,-11967 }, { 122,-11967 }, { 123,-11967 }, + { 124,-11967 }, { 125,-11967 }, { 126,-11967 }, { 127,-11967 }, { 128,-11967 }, + { 129,-11967 }, { 130,-11967 }, { 131,-11967 }, { 132,-11967 }, { 133,-11967 }, + + { 134,-11967 }, { 135,-11967 }, { 136,-11967 }, { 137,-11967 }, { 138,-11967 }, + { 139,-11967 }, { 140,-11967 }, { 141,-11967 }, { 142,-11967 }, { 143,-11967 }, + { 144,-11967 }, { 145,-11967 }, { 146,-11967 }, { 147,-11967 }, { 148,-11967 }, + { 149,-11967 }, { 150,-11967 }, { 151,-11967 }, { 152,-11967 }, { 153,-11967 }, + { 154,-11967 }, { 155,-11967 }, { 156,-11967 }, { 157,-11967 }, { 158,-11967 }, + { 159,-11967 }, { 160,-11967 }, { 161,-11967 }, { 162,-11967 }, { 163,-11967 }, + { 164,-11967 }, { 165,-11967 }, { 166,-11967 }, { 167,-11967 }, { 168,-11967 }, + { 169,-11967 }, { 170,-11967 }, { 171,-11967 }, { 172,-11967 }, { 173,-11967 }, + { 174,-11967 }, { 175,-11967 }, { 176,-11967 }, { 177,-11967 }, { 178,-11967 }, + { 179,-11967 }, { 180,-11967 }, { 181,-11967 }, { 182,-11967 }, { 183,-11967 }, + + { 184,-11967 }, { 185,-11967 }, { 186,-11967 }, { 187,-11967 }, { 188,-11967 }, + { 189,-11967 }, { 190,-11967 }, { 191,-11967 }, { 192,-11967 }, { 193,-11967 }, + { 194,-11967 }, { 195,-11967 }, { 196,-11967 }, { 197,-11967 }, { 198,-11967 }, + { 199,-11967 }, { 200,-11967 }, { 201,-11967 }, { 202,-11967 }, { 203,-11967 }, + { 204,-11967 }, { 205,-11967 }, { 206,-11967 }, { 207,-11967 }, { 208,-11967 }, + { 209,-11967 }, { 210,-11967 }, { 211,-11967 }, { 212,-11967 }, { 213,-11967 }, + { 214,-11967 }, { 215,-11967 }, { 216,-11967 }, { 217,-11967 }, { 218,-11967 }, + { 219,-11967 }, { 220,-11967 }, { 221,-11967 }, { 222,-11967 }, { 223,-11967 }, + { 224,-11967 }, { 225,-11967 }, { 226,-11967 }, { 227,-11967 }, { 228,-11967 }, + { 229,-11967 }, { 230,-11967 }, { 231,-11967 }, { 232,-11967 }, { 233,-11967 }, + + { 234,-11967 }, { 235,-11967 }, { 236,-11967 }, { 237,-11967 }, { 238,-11967 }, + { 239,-11967 }, { 240,-11967 }, { 241,-11967 }, { 242,-11967 }, { 243,-11967 }, + { 244,-11967 }, { 245,-11967 }, { 246,-11967 }, { 247,-11967 }, { 248,-11967 }, + { 249,-11967 }, { 250,-11967 }, { 251,-11967 }, { 252,-11967 }, { 253,-11967 }, + { 254,-11967 }, { 255,-11967 }, { 256,-11967 }, { 0, 48 }, { 0,1806 }, + { 1,-15956 }, { 2,-15956 }, { 3,-15956 }, { 4,-15956 }, { 5,-15956 }, + { 6,-15956 }, { 7,-15956 }, { 8,-15956 }, { 9,-15698 }, { 10,-26568 }, + { 11,-15956 }, { 12,-15698 }, { 13,-26568 }, { 14,-15956 }, { 15,-15956 }, + { 16,-15956 }, { 17,-15956 }, { 18,-15956 }, { 19,-15956 }, { 20,-15956 }, + { 21,-15956 }, { 22,-15956 }, { 23,-15956 }, { 24,-15956 }, { 25,-15956 }, + + { 26,-15956 }, { 27,-15956 }, { 28,-15956 }, { 29,-15956 }, { 30,-15956 }, + { 31,-15956 }, { 32,-15698 }, { 33,-15956 }, { 34,-15956 }, { 35,-15956 }, + { 36,-15956 }, { 37,-15956 }, { 38,-15956 }, { 39,-15440 }, { 40,-15956 }, + { 41,-15956 }, { 42,-15956 }, { 43,-15956 }, { 44,-15956 }, { 45,-10419 }, + { 46,-15956 }, { 47,-15956 }, { 48,-15956 }, { 49,-15956 }, { 50,-15956 }, + { 51,-15956 }, { 52,-15956 }, { 53,-15956 }, { 54,-15956 }, { 55,-15956 }, + { 56,-15956 }, { 57,-15956 }, { 58,-15956 }, { 59,-15956 }, { 60,-15956 }, + { 61,-15956 }, { 62,-15956 }, { 63,-15956 }, { 64,-15956 }, { 65,-15956 }, + { 66,-15956 }, { 67,-15956 }, { 68,-15956 }, { 69, 774 }, { 70,-15956 }, + { 71,-15956 }, { 72,-15956 }, { 73,-15956 }, { 74,-15956 }, { 75,-15956 }, + + { 76,-15956 }, { 77,-15956 }, { 78,-15956 }, { 79,-15956 }, { 80,-15956 }, + { 81,-15956 }, { 82,-15956 }, { 83,-15956 }, { 84,-15956 }, { 85,-14924 }, + { 86,-15956 }, { 87,-15956 }, { 88,-15956 }, { 89,-15956 }, { 90,-15956 }, + { 91,-15956 }, { 92,-15956 }, { 93,-15956 }, { 94,-15956 }, { 95,-15956 }, + { 96,-15956 }, { 97,-15956 }, { 98,-15956 }, { 99,-15956 }, { 100,-15956 }, + { 101, 774 }, { 102,-15956 }, { 103,-15956 }, { 104,-15956 }, { 105,-15956 }, + { 106,-15956 }, { 107,-15956 }, { 108,-15956 }, { 109,-15956 }, { 110,-15956 }, + { 111,-15956 }, { 112,-15956 }, { 113,-15956 }, { 114,-15956 }, { 115,-15956 }, + { 116,-15956 }, { 117,-14924 }, { 118,-15956 }, { 119,-15956 }, { 120,-15956 }, + { 121,-15956 }, { 122,-15956 }, { 123,-15956 }, { 124,-15956 }, { 125,-15956 }, + + { 126,-15956 }, { 127,-15956 }, { 128,-15956 }, { 129,-15956 }, { 130,-15956 }, + { 131,-15956 }, { 132,-15956 }, { 133,-15956 }, { 134,-15956 }, { 135,-15956 }, + { 136,-15956 }, { 137,-15956 }, { 138,-15956 }, { 139,-15956 }, { 140,-15956 }, + { 141,-15956 }, { 142,-15956 }, { 143,-15956 }, { 144,-15956 }, { 145,-15956 }, + { 146,-15956 }, { 147,-15956 }, { 148,-15956 }, { 149,-15956 }, { 150,-15956 }, + { 151,-15956 }, { 152,-15956 }, { 153,-15956 }, { 154,-15956 }, { 155,-15956 }, + { 156,-15956 }, { 157,-15956 }, { 158,-15956 }, { 159,-15956 }, { 160,-15956 }, + { 161,-15956 }, { 162,-15956 }, { 163,-15956 }, { 164,-15956 }, { 165,-15956 }, + { 166,-15956 }, { 167,-15956 }, { 168,-15956 }, { 169,-15956 }, { 170,-15956 }, + { 171,-15956 }, { 172,-15956 }, { 173,-15956 }, { 174,-15956 }, { 175,-15956 }, + + { 176,-15956 }, { 177,-15956 }, { 178,-15956 }, { 179,-15956 }, { 180,-15956 }, + { 181,-15956 }, { 182,-15956 }, { 183,-15956 }, { 184,-15956 }, { 185,-15956 }, + { 186,-15956 }, { 187,-15956 }, { 188,-15956 }, { 189,-15956 }, { 190,-15956 }, + { 191,-15956 }, { 192,-15956 }, { 193,-15956 }, { 194,-15956 }, { 195,-15956 }, + { 196,-15956 }, { 197,-15956 }, { 198,-15956 }, { 199,-15956 }, { 200,-15956 }, + { 201,-15956 }, { 202,-15956 }, { 203,-15956 }, { 204,-15956 }, { 205,-15956 }, + { 206,-15956 }, { 207,-15956 }, { 208,-15956 }, { 209,-15956 }, { 210,-15956 }, + { 211,-15956 }, { 212,-15956 }, { 213,-15956 }, { 214,-15956 }, { 215,-15956 }, + { 216,-15956 }, { 217,-15956 }, { 218,-15956 }, { 219,-15956 }, { 220,-15956 }, + { 221,-15956 }, { 222,-15956 }, { 223,-15956 }, { 224,-15956 }, { 225,-15956 }, + + { 226,-15956 }, { 227,-15956 }, { 228,-15956 }, { 229,-15956 }, { 230,-15956 }, + { 231,-15956 }, { 232,-15956 }, { 233,-15956 }, { 234,-15956 }, { 235,-15956 }, + { 236,-15956 }, { 237,-15956 }, { 238,-15956 }, { 239,-15956 }, { 240,-15956 }, + { 241,-15956 }, { 242,-15956 }, { 243,-15956 }, { 244,-15956 }, { 245,-15956 }, + { 246,-15956 }, { 247,-15956 }, { 248,-15956 }, { 249,-15956 }, { 250,-15956 }, + { 251,-15956 }, { 252,-15956 }, { 253,-15956 }, { 254,-15956 }, { 255,-15956 }, + { 256,-15956 }, { 0, 24 }, { 0,1548 }, { 1,-8494 }, { 2,-8494 }, + { 3,-8494 }, { 4,-8494 }, { 5,-8494 }, { 6,-8494 }, { 7,-8494 }, + { 8,-8494 }, { 9,-8236 }, { 10,-20230 }, { 11,-8494 }, { 12,-8236 }, + { 13,-20230 }, { 14,-8494 }, { 15,-8494 }, { 16,-8494 }, { 17,-8494 }, + + { 18,-8494 }, { 19,-8494 }, { 20,-8494 }, { 21,-8494 }, { 22,-8494 }, + { 23,-8494 }, { 24,-8494 }, { 25,-8494 }, { 26,-8494 }, { 27,-8494 }, + { 28,-8494 }, { 29,-8494 }, { 30,-8494 }, { 31,-8494 }, { 32,-8236 }, + { 33,-8494 }, { 34,-8494 }, { 35,-8494 }, { 36,-8494 }, { 37,-8494 }, + { 38,-8494 }, { 39,-7978 }, { 40,-8494 }, { 41,-8494 }, { 42,-8494 }, + { 43,-8494 }, { 44,-8494 }, { 45,-7204 }, { 46,-8494 }, { 47,-8494 }, + { 48,-8494 }, { 49,-8494 }, { 50,-8494 }, { 51,-8494 }, { 52,-8494 }, + { 53,-8494 }, { 54,-8494 }, { 55,-8494 }, { 56,-8494 }, { 57,-8494 }, + { 58,-8494 }, { 59,-8494 }, { 60,-8494 }, { 61,-8494 }, { 62,-8494 }, + { 63,-8494 }, { 64,-8494 }, { 65,-8494 }, { 66,-8494 }, { 67,-8494 }, + + { 68,-8494 }, { 69,-8494 }, { 70,-8494 }, { 71,-8494 }, { 72,-8494 }, + { 73,-8494 }, { 74,-8494 }, { 75,-8494 }, { 76,-8494 }, { 77,-8494 }, + { 78,-8494 }, { 79,-8494 }, { 80, 774 }, { 81,-8494 }, { 82,-8494 }, + { 83,-8494 }, { 84,-8494 }, { 85,-7462 }, { 86,-8494 }, { 87,-8494 }, + { 88,-8494 }, { 89,-8494 }, { 90,-8494 }, { 91,-8494 }, { 92,-8494 }, + { 93,-8494 }, { 94,-8494 }, { 95,-8494 }, { 96,-8494 }, { 97,-8494 }, + { 98,-8494 }, { 99,-8494 }, { 100,-8494 }, { 101,-8494 }, { 102,-8494 }, + { 103,-8494 }, { 104,-8494 }, { 105,-8494 }, { 106,-8494 }, { 107,-8494 }, + { 108,-8494 }, { 109,-8494 }, { 110,-8494 }, { 111,-8494 }, { 112, 774 }, + { 113,-8494 }, { 114,-8494 }, { 115,-8494 }, { 116,-8494 }, { 117,-7462 }, + + { 118,-8494 }, { 119,-8494 }, { 120,-8494 }, { 121,-8494 }, { 122,-8494 }, + { 123,-8494 }, { 124,-8494 }, { 125,-8494 }, { 126,-8494 }, { 127,-8494 }, + { 128,-8494 }, { 129,-8494 }, { 130,-8494 }, { 131,-8494 }, { 132,-8494 }, + { 133,-8494 }, { 134,-8494 }, { 135,-8494 }, { 136,-8494 }, { 137,-8494 }, + { 138,-8494 }, { 139,-8494 }, { 140,-8494 }, { 141,-8494 }, { 142,-8494 }, + { 143,-8494 }, { 144,-8494 }, { 145,-8494 }, { 146,-8494 }, { 147,-8494 }, + { 148,-8494 }, { 149,-8494 }, { 150,-8494 }, { 151,-8494 }, { 152,-8494 }, + { 153,-8494 }, { 154,-8494 }, { 155,-8494 }, { 156,-8494 }, { 157,-8494 }, + { 158,-8494 }, { 159,-8494 }, { 160,-8494 }, { 161,-8494 }, { 162,-8494 }, + { 163,-8494 }, { 164,-8494 }, { 165,-8494 }, { 166,-8494 }, { 167,-8494 }, + + { 168,-8494 }, { 169,-8494 }, { 170,-8494 }, { 171,-8494 }, { 172,-8494 }, + { 173,-8494 }, { 174,-8494 }, { 175,-8494 }, { 176,-8494 }, { 177,-8494 }, + { 178,-8494 }, { 179,-8494 }, { 180,-8494 }, { 181,-8494 }, { 182,-8494 }, + { 183,-8494 }, { 184,-8494 }, { 185,-8494 }, { 186,-8494 }, { 187,-8494 }, + { 188,-8494 }, { 189,-8494 }, { 190,-8494 }, { 191,-8494 }, { 192,-8494 }, + { 193,-8494 }, { 194,-8494 }, { 195,-8494 }, { 196,-8494 }, { 197,-8494 }, + { 198,-8494 }, { 199,-8494 }, { 200,-8494 }, { 201,-8494 }, { 202,-8494 }, + { 203,-8494 }, { 204,-8494 }, { 205,-8494 }, { 206,-8494 }, { 207,-8494 }, + { 208,-8494 }, { 209,-8494 }, { 210,-8494 }, { 211,-8494 }, { 212,-8494 }, + { 213,-8494 }, { 214,-8494 }, { 215,-8494 }, { 216,-8494 }, { 217,-8494 }, + + { 218,-8494 }, { 219,-8494 }, { 220,-8494 }, { 221,-8494 }, { 222,-8494 }, + { 223,-8494 }, { 224,-8494 }, { 225,-8494 }, { 226,-8494 }, { 227,-8494 }, + { 228,-8494 }, { 229,-8494 }, { 230,-8494 }, { 231,-8494 }, { 232,-8494 }, + { 233,-8494 }, { 234,-8494 }, { 235,-8494 }, { 236,-8494 }, { 237,-8494 }, + { 238,-8494 }, { 239,-8494 }, { 240,-8494 }, { 241,-8494 }, { 242,-8494 }, + { 243,-8494 }, { 244,-8494 }, { 245,-8494 }, { 246,-8494 }, { 247,-8494 }, + { 248,-8494 }, { 249,-8494 }, { 250,-8494 }, { 251,-8494 }, { 252,-8494 }, + { 253,-8494 }, { 254,-8494 }, { 255,-8494 }, { 256,-8494 }, { 0, 24 }, + { 0,1290 }, { 1,-12741 }, { 2,-12741 }, { 3,-12741 }, { 4,-12741 }, + { 5,-12741 }, { 6,-12741 }, { 7,-12741 }, { 8,-12741 }, { 9,-12483 }, + + { 10,-24901 }, { 11,-12741 }, { 12,-12483 }, { 13,-24901 }, { 14,-12741 }, + { 15,-12741 }, { 16,-12741 }, { 17,-12741 }, { 18,-12741 }, { 19,-12741 }, + { 20,-12741 }, { 21,-12741 }, { 22,-12741 }, { 23,-12741 }, { 24,-12741 }, + { 25,-12741 }, { 26,-12741 }, { 27,-12741 }, { 28,-12741 }, { 29,-12741 }, + { 30,-12741 }, { 31,-12741 }, { 32,-12483 }, { 33,-12741 }, { 34,-12741 }, + { 35,-12741 }, { 36,-12741 }, { 37,-12741 }, { 38,-12741 }, { 39,-12225 }, + { 40,-12741 }, { 41,-12741 }, { 42,-12741 }, { 43,-12741 }, { 44,-12741 }, + { 45,-7204 }, { 46,-12741 }, { 47,-12741 }, { 48,-12741 }, { 49,-12741 }, + { 50,-12741 }, { 51,-12741 }, { 52,-12741 }, { 53,-12741 }, { 54,-12741 }, + { 55,-12741 }, { 56,-12741 }, { 57,-12741 }, { 58,-12741 }, { 59,-12741 }, + + { 60,-12741 }, { 61,-12741 }, { 62,-12741 }, { 63,-12741 }, { 64,-12741 }, + { 65,-12741 }, { 66,-12741 }, { 67,-12741 }, { 68,-12741 }, { 69, 774 }, + { 70,-12741 }, { 71,-12741 }, { 72,-12741 }, { 73,-12741 }, { 74,-12741 }, + { 75,-12741 }, { 76,-12741 }, { 77,-12741 }, { 78,-12741 }, { 79,-12741 }, + { 80,-12741 }, { 81,-12741 }, { 82,-12741 }, { 83,-12741 }, { 84,-12741 }, + { 85,-11709 }, { 86,-12741 }, { 87,-12741 }, { 88,-12741 }, { 89,-12741 }, + { 90,-12741 }, { 91,-12741 }, { 92,-12741 }, { 93,-12741 }, { 94,-12741 }, + { 95,-12741 }, { 96,-12741 }, { 97,-12741 }, { 98,-12741 }, { 99,-12741 }, + { 100,-12741 }, { 101, 774 }, { 102,-12741 }, { 103,-12741 }, { 104,-12741 }, + { 105,-12741 }, { 106,-12741 }, { 107,-12741 }, { 108,-12741 }, { 109,-12741 }, + + { 110,-12741 }, { 111,-12741 }, { 112,-12741 }, { 113,-12741 }, { 114,-12741 }, + { 115,-12741 }, { 116,-12741 }, { 117,-11709 }, { 118,-12741 }, { 119,-12741 }, + { 120,-12741 }, { 121,-12741 }, { 122,-12741 }, { 123,-12741 }, { 124,-12741 }, + { 125,-12741 }, { 126,-12741 }, { 127,-12741 }, { 128,-12741 }, { 129,-12741 }, + { 130,-12741 }, { 131,-12741 }, { 132,-12741 }, { 133,-12741 }, { 134,-12741 }, + { 135,-12741 }, { 136,-12741 }, { 137,-12741 }, { 138,-12741 }, { 139,-12741 }, + { 140,-12741 }, { 141,-12741 }, { 142,-12741 }, { 143,-12741 }, { 144,-12741 }, + { 145,-12741 }, { 146,-12741 }, { 147,-12741 }, { 148,-12741 }, { 149,-12741 }, + { 150,-12741 }, { 151,-12741 }, { 152,-12741 }, { 153,-12741 }, { 154,-12741 }, + { 155,-12741 }, { 156,-12741 }, { 157,-12741 }, { 158,-12741 }, { 159,-12741 }, + + { 160,-12741 }, { 161,-12741 }, { 162,-12741 }, { 163,-12741 }, { 164,-12741 }, + { 165,-12741 }, { 166,-12741 }, { 167,-12741 }, { 168,-12741 }, { 169,-12741 }, + { 170,-12741 }, { 171,-12741 }, { 172,-12741 }, { 173,-12741 }, { 174,-12741 }, + { 175,-12741 }, { 176,-12741 }, { 177,-12741 }, { 178,-12741 }, { 179,-12741 }, + { 180,-12741 }, { 181,-12741 }, { 182,-12741 }, { 183,-12741 }, { 184,-12741 }, + { 185,-12741 }, { 186,-12741 }, { 187,-12741 }, { 188,-12741 }, { 189,-12741 }, + { 190,-12741 }, { 191,-12741 }, { 192,-12741 }, { 193,-12741 }, { 194,-12741 }, + { 195,-12741 }, { 196,-12741 }, { 197,-12741 }, { 198,-12741 }, { 199,-12741 }, + { 200,-12741 }, { 201,-12741 }, { 202,-12741 }, { 203,-12741 }, { 204,-12741 }, + { 205,-12741 }, { 206,-12741 }, { 207,-12741 }, { 208,-12741 }, { 209,-12741 }, + + { 210,-12741 }, { 211,-12741 }, { 212,-12741 }, { 213,-12741 }, { 214,-12741 }, + { 215,-12741 }, { 216,-12741 }, { 217,-12741 }, { 218,-12741 }, { 219,-12741 }, + { 220,-12741 }, { 221,-12741 }, { 222,-12741 }, { 223,-12741 }, { 224,-12741 }, + { 225,-12741 }, { 226,-12741 }, { 227,-12741 }, { 228,-12741 }, { 229,-12741 }, + { 230,-12741 }, { 231,-12741 }, { 232,-12741 }, { 233,-12741 }, { 234,-12741 }, + { 235,-12741 }, { 236,-12741 }, { 237,-12741 }, { 238,-12741 }, { 239,-12741 }, + { 240,-12741 }, { 241,-12741 }, { 242,-12741 }, { 243,-12741 }, { 244,-12741 }, + { 245,-12741 }, { 246,-12741 }, { 247,-12741 }, { 248,-12741 }, { 249,-12741 }, + { 250,-12741 }, { 251,-12741 }, { 252,-12741 }, { 253,-12741 }, { 254,-12741 }, + { 255,-12741 }, { 256,-12741 }, { 0, 48 }, { 0,1032 }, { 1,-16730 }, + + { 2,-16730 }, { 3,-16730 }, { 4,-16730 }, { 5,-16730 }, { 6,-16730 }, + { 7,-16730 }, { 8,-16730 }, { 9,-16472 }, { 10,-27342 }, { 11,-16730 }, + { 12,-16472 }, { 13,-27342 }, { 14,-16730 }, { 15,-16730 }, { 16,-16730 }, + { 17,-16730 }, { 18,-16730 }, { 19,-16730 }, { 20,-16730 }, { 21,-16730 }, + { 22,-16730 }, { 23,-16730 }, { 24,-16730 }, { 25,-16730 }, { 26,-16730 }, + { 27,-16730 }, { 28,-16730 }, { 29,-16730 }, { 30,-16730 }, { 31,-16730 }, + { 32,-16472 }, { 33,-16730 }, { 34,-16730 }, { 35,-16730 }, { 36,-16730 }, + { 37,-16730 }, { 38,-16730 }, { 39,-16214 }, { 40,-16730 }, { 41,-16730 }, + { 42,-16730 }, { 43,-16730 }, { 44,-16730 }, { 45,-11193 }, { 46,-16730 }, + { 47,-16730 }, { 48,-16730 }, { 49,-16730 }, { 50,-16730 }, { 51,-16730 }, + + { 52,-16730 }, { 53,-16730 }, { 54,-16730 }, { 55,-16730 }, { 56,-16730 }, + { 57,-16730 }, { 58,-16730 }, { 59,-16730 }, { 60,-16730 }, { 61,-16730 }, + { 62,-16730 }, { 63,-16730 }, { 64,-16730 }, { 65,-16730 }, { 66,-16730 }, + { 67,-16730 }, { 68,-16730 }, { 69,-16730 }, { 70,-16730 }, { 71,-16730 }, + { 72,-16730 }, { 73,-16730 }, { 74,-16730 }, { 75,-16730 }, { 76,-16730 }, + { 77,-16730 }, { 78,-16730 }, { 79,-16730 }, { 80,-16730 }, { 81,-16730 }, + { 82,-16730 }, { 83,-16730 }, { 84,-16730 }, { 85,-15698 }, { 86,-16730 }, + { 87,-16730 }, { 88,-16730 }, { 89,-16730 }, { 90,-16730 }, { 91,-16730 }, + { 92,-16730 }, { 93,-16730 }, { 94,-16730 }, { 95,-16730 }, { 96,-16730 }, + { 97,-16730 }, { 98,-16730 }, { 99,-16730 }, { 100,-16730 }, { 101,-16730 }, + + { 102,-16730 }, { 103,-16730 }, { 104,-16730 }, { 105,-16730 }, { 106,-16730 }, + { 107,-16730 }, { 108,-16730 }, { 109,-16730 }, { 110,-16730 }, { 111,-16730 }, + { 112,-16730 }, { 113,-16730 }, { 114,-16730 }, { 115,-16730 }, { 116,-16730 }, + { 117,-15698 }, { 118,-16730 }, { 119,-16730 }, { 120,-16730 }, { 121,-16730 }, + { 122,-16730 }, { 123,-16730 }, { 124,-16730 }, { 125,-16730 }, { 126,-16730 }, + { 127,-16730 }, { 128,-16730 }, { 129,-16730 }, { 130,-16730 }, { 131,-16730 }, + { 132,-16730 }, { 133,-16730 }, { 134,-16730 }, { 135,-16730 }, { 136,-16730 }, + { 137,-16730 }, { 138,-16730 }, { 139,-16730 }, { 140,-16730 }, { 141,-16730 }, + { 142,-16730 }, { 143,-16730 }, { 144,-16730 }, { 145,-16730 }, { 146,-16730 }, + { 147,-16730 }, { 148,-16730 }, { 149,-16730 }, { 150,-16730 }, { 151,-16730 }, + + { 152,-16730 }, { 153,-16730 }, { 154,-16730 }, { 155,-16730 }, { 156,-16730 }, + { 157,-16730 }, { 158,-16730 }, { 159,-16730 }, { 160,-16730 }, { 161,-16730 }, + { 162,-16730 }, { 163,-16730 }, { 164,-16730 }, { 165,-16730 }, { 166,-16730 }, + { 167,-16730 }, { 168,-16730 }, { 169,-16730 }, { 170,-16730 }, { 171,-16730 }, + { 172,-16730 }, { 173,-16730 }, { 174,-16730 }, { 175,-16730 }, { 176,-16730 }, + { 177,-16730 }, { 178,-16730 }, { 179,-16730 }, { 180,-16730 }, { 181,-16730 }, + { 182,-16730 }, { 183,-16730 }, { 184,-16730 }, { 185,-16730 }, { 186,-16730 }, + { 187,-16730 }, { 188,-16730 }, { 189,-16730 }, { 190,-16730 }, { 191,-16730 }, + { 192,-16730 }, { 193,-16730 }, { 194,-16730 }, { 195,-16730 }, { 196,-16730 }, + { 197,-16730 }, { 198,-16730 }, { 199,-16730 }, { 200,-16730 }, { 201,-16730 }, + + { 202,-16730 }, { 203,-16730 }, { 204,-16730 }, { 205,-16730 }, { 206,-16730 }, + { 207,-16730 }, { 208,-16730 }, { 209,-16730 }, { 210,-16730 }, { 211,-16730 }, + { 212,-16730 }, { 213,-16730 }, { 214,-16730 }, { 215,-16730 }, { 216,-16730 }, + { 217,-16730 }, { 218,-16730 }, { 219,-16730 }, { 220,-16730 }, { 221,-16730 }, + { 222,-16730 }, { 223,-16730 }, { 224,-16730 }, { 225,-16730 }, { 226,-16730 }, + { 227,-16730 }, { 228,-16730 }, { 229,-16730 }, { 230,-16730 }, { 231,-16730 }, + { 232,-16730 }, { 233,-16730 }, { 234,-16730 }, { 235,-16730 }, { 236,-16730 }, + { 237,-16730 }, { 238,-16730 }, { 239,-16730 }, { 240,-16730 }, { 241,-16730 }, + { 242,-16730 }, { 243,-16730 }, { 244,-16730 }, { 245,-16730 }, { 246,-16730 }, + { 247,-16730 }, { 248,-16730 }, { 249,-16730 }, { 250,-16730 }, { 251,-16730 }, + + { 252,-16730 }, { 253,-16730 }, { 254,-16730 }, { 255,-16730 }, { 256,-16730 }, + { 0, 24 }, { 0, 774 }, { 1,-9268 }, { 2,-9268 }, { 3,-9268 }, + { 4,-9268 }, { 5,-9268 }, { 6,-9268 }, { 7,-9268 }, { 8,-9268 }, + { 9,-9010 }, { 10,-21004 }, { 11,-9268 }, { 12,-9010 }, { 13,-21004 }, + { 14,-9268 }, { 15,-9268 }, { 16,-9268 }, { 17,-9268 }, { 18,-9268 }, + { 19,-9268 }, { 20,-9268 }, { 21,-9268 }, { 22,-9268 }, { 23,-9268 }, + { 24,-9268 }, { 25,-9268 }, { 26,-9268 }, { 27,-9268 }, { 28,-9268 }, + { 29,-9268 }, { 30,-9268 }, { 31,-9268 }, { 32,-9010 }, { 33,-9268 }, + { 34,-9268 }, { 35,-9268 }, { 36,-9268 }, { 37,-9268 }, { 38,-9268 }, + { 39,-8752 }, { 40,-9268 }, { 41,-9268 }, { 42,-9268 }, { 43,-9268 }, + + { 44,-9268 }, { 45,-7978 }, { 46,-9268 }, { 47,-9268 }, { 48,-9268 }, + { 49,-9268 }, { 50,-9268 }, { 51,-9268 }, { 52,-9268 }, { 53,-9268 }, + { 54,-9268 }, { 55,-9268 }, { 56,-9268 }, { 57,-9268 }, { 58,-9268 }, + { 59,-9268 }, { 60,-9268 }, { 61,-9268 }, { 62,-9268 }, { 63,-9268 }, + { 64,-9268 }, { 65,-9268 }, { 66,-9268 }, { 67,-9268 }, { 68,-9268 }, + { 69, 516 }, { 70,-9268 }, { 71,-9268 }, { 72,-9268 }, { 73,-9268 }, + { 74,-9268 }, { 75,-9268 }, { 76,-9268 }, { 77,-9268 }, { 78,-9268 }, + { 79,-9268 }, { 80,-9268 }, { 81,-9268 }, { 82,-9268 }, { 83,-9268 }, + { 84,-9268 }, { 85,-8236 }, { 86,-9268 }, { 87,-9268 }, { 88,-9268 }, + { 89,-9268 }, { 90,-9268 }, { 91,-9268 }, { 92,-9268 }, { 93,-9268 }, + + { 94,-9268 }, { 95,-9268 }, { 96,-9268 }, { 97,-9268 }, { 98,-9268 }, + { 99,-9268 }, { 100,-9268 }, { 101, 516 }, { 102,-9268 }, { 103,-9268 }, + { 104,-9268 }, { 105,-9268 }, { 106,-9268 }, { 107,-9268 }, { 108,-9268 }, + { 109,-9268 }, { 110,-9268 }, { 111,-9268 }, { 112,-9268 }, { 113,-9268 }, + { 114,-9268 }, { 115,-9268 }, { 116,-9268 }, { 117,-8236 }, { 118,-9268 }, + { 119,-9268 }, { 120,-9268 }, { 121,-9268 }, { 122,-9268 }, { 123,-9268 }, + { 124,-9268 }, { 125,-9268 }, { 126,-9268 }, { 127,-9268 }, { 128,-9268 }, + { 129,-9268 }, { 130,-9268 }, { 131,-9268 }, { 132,-9268 }, { 133,-9268 }, + { 134,-9268 }, { 135,-9268 }, { 136,-9268 }, { 137,-9268 }, { 138,-9268 }, + { 139,-9268 }, { 140,-9268 }, { 141,-9268 }, { 142,-9268 }, { 143,-9268 }, + + { 144,-9268 }, { 145,-9268 }, { 146,-9268 }, { 147,-9268 }, { 148,-9268 }, + { 149,-9268 }, { 150,-9268 }, { 151,-9268 }, { 152,-9268 }, { 153,-9268 }, + { 154,-9268 }, { 155,-9268 }, { 156,-9268 }, { 157,-9268 }, { 158,-9268 }, + { 159,-9268 }, { 160,-9268 }, { 161,-9268 }, { 162,-9268 }, { 163,-9268 }, + { 164,-9268 }, { 165,-9268 }, { 166,-9268 }, { 167,-9268 }, { 168,-9268 }, + { 169,-9268 }, { 170,-9268 }, { 171,-9268 }, { 172,-9268 }, { 173,-9268 }, + { 174,-9268 }, { 175,-9268 }, { 176,-9268 }, { 177,-9268 }, { 178,-9268 }, + { 179,-9268 }, { 180,-9268 }, { 181,-9268 }, { 182,-9268 }, { 183,-9268 }, + { 184,-9268 }, { 185,-9268 }, { 186,-9268 }, { 187,-9268 }, { 188,-9268 }, + { 189,-9268 }, { 190,-9268 }, { 191,-9268 }, { 192,-9268 }, { 193,-9268 }, + + { 194,-9268 }, { 195,-9268 }, { 196,-9268 }, { 197,-9268 }, { 198,-9268 }, + { 199,-9268 }, { 200,-9268 }, { 201,-9268 }, { 202,-9268 }, { 203,-9268 }, + { 204,-9268 }, { 205,-9268 }, { 206,-9268 }, { 207,-9268 }, { 208,-9268 }, + { 209,-9268 }, { 210,-9268 }, { 211,-9268 }, { 212,-9268 }, { 213,-9268 }, + { 214,-9268 }, { 215,-9268 }, { 216,-9268 }, { 217,-9268 }, { 218,-9268 }, + { 219,-9268 }, { 220,-9268 }, { 221,-9268 }, { 222,-9268 }, { 223,-9268 }, + { 224,-9268 }, { 225,-9268 }, { 226,-9268 }, { 227,-9268 }, { 228,-9268 }, + { 229,-9268 }, { 230,-9268 }, { 231,-9268 }, { 232,-9268 }, { 233,-9268 }, + { 234,-9268 }, { 235,-9268 }, { 236,-9268 }, { 237,-9268 }, { 238,-9268 }, + { 239,-9268 }, { 240,-9268 }, { 241,-9268 }, { 242,-9268 }, { 243,-9268 }, + + { 244,-9268 }, { 245,-9268 }, { 246,-9268 }, { 247,-9268 }, { 248,-9268 }, + { 249,-9268 }, { 250,-9268 }, { 251,-9268 }, { 252,-9268 }, { 253,-9268 }, + { 254,-9268 }, { 255,-9268 }, { 256,-9268 }, { 0, 24 }, { 0, 516 }, + { 1,-13515 }, { 2,-13515 }, { 3,-13515 }, { 4,-13515 }, { 5,-13515 }, + { 6,-13515 }, { 7,-13515 }, { 8,-13515 }, { 9,-13257 }, { 10,-25675 }, + { 11,-13515 }, { 12,-13257 }, { 13,-25675 }, { 14,-13515 }, { 15,-13515 }, + { 16,-13515 }, { 17,-13515 }, { 18,-13515 }, { 19,-13515 }, { 20,-13515 }, + { 21,-13515 }, { 22,-13515 }, { 23,-13515 }, { 24,-13515 }, { 25,-13515 }, + { 26,-13515 }, { 27,-13515 }, { 28,-13515 }, { 29,-13515 }, { 30,-13515 }, + { 31,-13515 }, { 32,-13257 }, { 33,-13515 }, { 34,-13515 }, { 35,-13515 }, + + { 36,-13515 }, { 37,-13515 }, { 38,-13515 }, { 39,-12999 }, { 40,-13515 }, + { 41,-13515 }, { 42,-13515 }, { 43,-13515 }, { 44,-13515 }, { 45,-7978 }, + { 46,-13515 }, { 47,-13515 }, { 48,-13515 }, { 49,-13515 }, { 50,-13515 }, + { 51,-13515 }, { 52,-13515 }, { 53,-13515 }, { 54,-13515 }, { 55,-13515 }, + { 56,-13515 }, { 57,-13515 }, { 58,-13515 }, { 59,-13515 }, { 60,-13515 }, + { 61,-13515 }, { 62,-13515 }, { 63,-13515 }, { 64,-13515 }, { 65,-13515 }, + { 66,-13515 }, { 67,-13515 }, { 68,-13515 }, { 69,-13515 }, { 70,-13515 }, + { 71,-13515 }, { 72,-13515 }, { 73,-13515 }, { 74,-13515 }, { 75,-13515 }, + { 76,-13515 }, { 77,-13515 }, { 78,-13515 }, { 79,-13515 }, { 80,-13515 }, + { 81,-13515 }, { 82,-13515 }, { 83,-13515 }, { 84,-13515 }, { 85,-12483 }, + + { 86,-13515 }, { 87,-13515 }, { 88,-13515 }, { 89,-13515 }, { 90,-13515 }, + { 91,-13515 }, { 92,-13515 }, { 93,-13515 }, { 94,-13515 }, { 95,-13515 }, + { 96,-13515 }, { 97,-13515 }, { 98,-13515 }, { 99,-13515 }, { 100,-13515 }, + { 101,-13515 }, { 102,-13515 }, { 103,-13515 }, { 104,-13515 }, { 105,-13515 }, + { 106,-13515 }, { 107,-13515 }, { 108,-13515 }, { 109,-13515 }, { 110,-13515 }, + { 111,-13515 }, { 112,-13515 }, { 113,-13515 }, { 114,-13515 }, { 115,-13515 }, + { 116,-13515 }, { 117,-12483 }, { 118,-13515 }, { 119,-13515 }, { 120,-13515 }, + { 121,-13515 }, { 122,-13515 }, { 123,-13515 }, { 124,-13515 }, { 125,-13515 }, + { 126,-13515 }, { 127,-13515 }, { 128,-13515 }, { 129,-13515 }, { 130,-13515 }, + { 131,-13515 }, { 132,-13515 }, { 133,-13515 }, { 134,-13515 }, { 135,-13515 }, + + { 136,-13515 }, { 137,-13515 }, { 138,-13515 }, { 139,-13515 }, { 140,-13515 }, + { 141,-13515 }, { 142,-13515 }, { 143,-13515 }, { 144,-13515 }, { 145,-13515 }, + { 146,-13515 }, { 147,-13515 }, { 148,-13515 }, { 149,-13515 }, { 150,-13515 }, + { 151,-13515 }, { 152,-13515 }, { 153,-13515 }, { 154,-13515 }, { 155,-13515 }, + { 156,-13515 }, { 157,-13515 }, { 158,-13515 }, { 159,-13515 }, { 160,-13515 }, + { 161,-13515 }, { 162,-13515 }, { 163,-13515 }, { 164,-13515 }, { 165,-13515 }, + { 166,-13515 }, { 167,-13515 }, { 168,-13515 }, { 169,-13515 }, { 170,-13515 }, + { 171,-13515 }, { 172,-13515 }, { 173,-13515 }, { 174,-13515 }, { 175,-13515 }, + { 176,-13515 }, { 177,-13515 }, { 178,-13515 }, { 179,-13515 }, { 180,-13515 }, + { 181,-13515 }, { 182,-13515 }, { 183,-13515 }, { 184,-13515 }, { 185,-13515 }, + + { 186,-13515 }, { 187,-13515 }, { 188,-13515 }, { 189,-13515 }, { 190,-13515 }, + { 191,-13515 }, { 192,-13515 }, { 193,-13515 }, { 194,-13515 }, { 195,-13515 }, + { 196,-13515 }, { 197,-13515 }, { 198,-13515 }, { 199,-13515 }, { 200,-13515 }, + { 201,-13515 }, { 202,-13515 }, { 203,-13515 }, { 204,-13515 }, { 205,-13515 }, + { 206,-13515 }, { 207,-13515 }, { 208,-13515 }, { 209,-13515 }, { 210,-13515 }, + { 211,-13515 }, { 212,-13515 }, { 213,-13515 }, { 214,-13515 }, { 215,-13515 }, + { 216,-13515 }, { 217,-13515 }, { 218,-13515 }, { 219,-13515 }, { 220,-13515 }, + { 221,-13515 }, { 222,-13515 }, { 223,-13515 }, { 224,-13515 }, { 225,-13515 }, + { 226,-13515 }, { 227,-13515 }, { 228,-13515 }, { 229,-13515 }, { 230,-13515 }, + { 231,-13515 }, { 232,-13515 }, { 233,-13515 }, { 234,-13515 }, { 235,-13515 }, + + { 236,-13515 }, { 237,-13515 }, { 238,-13515 }, { 239,-13515 }, { 240,-13515 }, + { 241,-13515 }, { 242,-13515 }, { 243,-13515 }, { 244,-13515 }, { 245,-13515 }, + { 246,-13515 }, { 247,-13515 }, { 248,-13515 }, { 249,-13515 }, { 250,-13515 }, + { 251,-13515 }, { 252,-13515 }, { 253,-13515 }, { 254,-13515 }, { 255,-13515 }, + { 256,-13515 }, { 0, 24 }, { 0, 258 }, { 1,-9784 }, { 2,-9784 }, + { 3,-9784 }, { 4,-9784 }, { 5,-9784 }, { 6,-9784 }, { 7,-9784 }, + { 8,-9784 }, { 9,-9526 }, { 10,-21520 }, { 11,-9784 }, { 12,-9526 }, + { 13,-21520 }, { 14,-9784 }, { 15,-9784 }, { 16,-9784 }, { 17,-9784 }, + { 18,-9784 }, { 19,-9784 }, { 20,-9784 }, { 21,-9784 }, { 22,-9784 }, + { 23,-9784 }, { 24,-9784 }, { 25,-9784 }, { 26,-9784 }, { 27,-9784 }, + + { 28,-9784 }, { 29,-9784 }, { 30,-9784 }, { 31,-9784 }, { 32,-9526 }, + { 33,-9784 }, { 34,-9784 }, { 35,-9784 }, { 36,-9784 }, { 37,-9784 }, + { 38,-9784 }, { 39,-9268 }, { 40,-9784 }, { 41,-9784 }, { 42,-9784 }, + { 43,-9784 }, { 44,-9784 }, { 45,-8494 }, { 46,-9784 }, { 47,-9784 }, + { 48,-9784 }, { 49,-9784 }, { 50,-9784 }, { 51,-9784 }, { 52,-9784 }, + { 53,-9784 }, { 54,-9784 }, { 55,-9784 }, { 56,-9784 }, { 57,-9784 }, + { 58,-9784 }, { 59,-9784 }, { 60,-9784 }, { 61,-9784 }, { 62,-9784 }, + { 63,-9784 }, { 64,-9784 }, { 65,-9784 }, { 66,-9784 }, { 67,-9784 }, + { 68,-9784 }, { 69,-9784 }, { 70,-9784 }, { 71,-9784 }, { 72,-9784 }, + { 73,-9784 }, { 74,-9784 }, { 75,-9784 }, { 76,-9784 }, { 77,-9784 }, + + { 78,-9784 }, { 79,-9784 }, { 80,-9784 }, { 81,-9784 }, { 82,-9784 }, + { 83,-9784 }, { 84,-9784 }, { 85,-8752 }, { 86,-9784 }, { 87,-9784 }, + { 88,-9784 }, { 89,-9784 }, { 90,-9784 }, { 91,-9784 }, { 92,-9784 }, + { 93,-9784 }, { 94,-9784 }, { 95,-9784 }, { 96,-9784 }, { 97,-9784 }, + { 98,-9784 }, { 99,-9784 }, { 100,-9784 }, { 101,-9784 }, { 102,-9784 }, + { 103,-9784 }, { 104,-9784 }, { 105,-9784 }, { 106,-9784 }, { 107,-9784 }, + { 108,-9784 }, { 109,-9784 }, { 110,-9784 }, { 111,-9784 }, { 112,-9784 }, + { 113,-9784 }, { 114,-9784 }, { 115,-9784 }, { 116,-9784 }, { 117,-8752 }, + { 118,-9784 }, { 119,-9784 }, { 120,-9784 }, { 121,-9784 }, { 122,-9784 }, + { 123,-9784 }, { 124,-9784 }, { 125,-9784 }, { 126,-9784 }, { 127,-9784 }, + + { 128,-9784 }, { 129,-9784 }, { 130,-9784 }, { 131,-9784 }, { 132,-9784 }, + { 133,-9784 }, { 134,-9784 }, { 135,-9784 }, { 136,-9784 }, { 137,-9784 }, + { 138,-9784 }, { 139,-9784 }, { 140,-9784 }, { 141,-9784 }, { 142,-9784 }, + { 143,-9784 }, { 144,-9784 }, { 145,-9784 }, { 146,-9784 }, { 147,-9784 }, + { 148,-9784 }, { 149,-9784 }, { 150,-9784 }, { 151,-9784 }, { 152,-9784 }, + { 153,-9784 }, { 154,-9784 }, { 155,-9784 }, { 156,-9784 }, { 157,-9784 }, + { 158,-9784 }, { 159,-9784 }, { 160,-9784 }, { 161,-9784 }, { 162,-9784 }, + { 163,-9784 }, { 164,-9784 }, { 165,-9784 }, { 166,-9784 }, { 167,-9784 }, + { 168,-9784 }, { 169,-9784 }, { 170,-9784 }, { 171,-9784 }, { 172,-9784 }, + { 173,-9784 }, { 174,-9784 }, { 175,-9784 }, { 176,-9784 }, { 177,-9784 }, + + { 178,-9784 }, { 179,-9784 }, { 180,-9784 }, { 181,-9784 }, { 182,-9784 }, + { 183,-9784 }, { 184,-9784 }, { 185,-9784 }, { 186,-9784 }, { 187,-9784 }, + { 188,-9784 }, { 189,-9784 }, { 190,-9784 }, { 191,-9784 }, { 192,-9784 }, + { 193,-9784 }, { 194,-9784 }, { 195,-9784 }, { 196,-9784 }, { 197,-9784 }, + { 198,-9784 }, { 199,-9784 }, { 200,-9784 }, { 201,-9784 }, { 202,-9784 }, + { 203,-9784 }, { 204,-9784 }, { 205,-9784 }, { 206,-9784 }, { 207,-9784 }, + { 208,-9784 }, { 209,-9784 }, { 210,-9784 }, { 211,-9784 }, { 212,-9784 }, + { 213,-9784 }, { 214,-9784 }, { 215,-9784 }, { 216,-9784 }, { 217,-9784 }, + { 218,-9784 }, { 219,-9784 }, { 220,-9784 }, { 221,-9784 }, { 222,-9784 }, + { 223,-9784 }, { 224,-9784 }, { 225,-9784 }, { 226,-9784 }, { 227,-9784 }, + + { 228,-9784 }, { 229,-9784 }, { 230,-9784 }, { 231,-9784 }, { 232,-9784 }, + { 233,-9784 }, { 234,-9784 }, { 235,-9784 }, { 236,-9784 }, { 237,-9784 }, + { 238,-9784 }, { 239,-9784 }, { 240,-9784 }, { 241,-9784 }, { 242,-9784 }, + { 243,-9784 }, { 244,-9784 }, { 245,-9784 }, { 246,-9784 }, { 247,-9784 }, + { 248,-9784 }, { 249,-9784 }, { 250,-9784 }, { 251,-9784 }, { 252,-9784 }, + { 253,-9784 }, { 254,-9784 }, { 255,-9784 }, { 256,-9784 }, { 257, 68 }, + { 1, 0 }, }; + +static yyconst struct yy_trans_info *yy_start_state_list[23] = + { + &yy_transition[1], + &yy_transition[3], + &yy_transition[261], + &yy_transition[519], + &yy_transition[777], + &yy_transition[1035], + &yy_transition[1293], + &yy_transition[1551], + &yy_transition[1809], + &yy_transition[2067], + &yy_transition[2325], + &yy_transition[2583], + &yy_transition[2841], + &yy_transition[3099], + &yy_transition[3357], + &yy_transition[3615], + &yy_transition[3873], + &yy_transition[4131], + &yy_transition[4389], + &yy_transition[4647], + &yy_transition[4905], + &yy_transition[5163], + &yy_transition[5421], + + } ; + +/* The intent behind this definition is that it'll catch + * any uses of REJECT which flex missed. + */ +#define REJECT reject_used_but_not_detected +#define yymore() yymore_used_but_not_detected +#define YY_MORE_ADJ 0 +#define YY_RESTORE_YY_MORE_OFFSET +#line 1 "scan.l" +#line 2 "scan.l" +/*------------------------------------------------------------------------- + * + * scan.l + * lexical scanner for PostgreSQL + * + * NOTE NOTE NOTE: + * + * The rules in this file must be kept in sync with psql's lexer!!! + * + * The rules are designed so that the scanner never has to backtrack, + * in the sense that there is always a rule that can match the input + * consumed so far (the rule action may internally throw back some input + * with yyless(), however). As explained in the flex manual, this makes + * for a useful speed increase --- about a third faster than a plain -CF + * lexer, in simple testing. The extra complexity is mostly in the rules + * for handling float numbers and continued string literals. If you change + * the lexical rules, verify that you haven't broken the no-backtrack + * property by running flex with the "-b" option and checking that the + * resulting "lex.backup" file says that no backing up is needed. (As of + * Postgres 9.2, this check is made automatically by the Makefile.) + * + * + * Portions Copyright (c) 1996-2012, PostgreSQL Global Development Group + * Portions Copyright (c) 1994, Regents of the University of California + * + * IDENTIFICATION + * src/backend/parser/scan.l + * + *------------------------------------------------------------------------- + */ +#include "postgres.h" + +#include +#include + +#include "parser/parser.h" /* only needed for GUC variables */ +#include "parser/scanner.h" +#include "parser/scansup.h" +#include "mb/pg_wchar.h" + + +/* Avoid exit() on fatal scanner errors (a bit ugly -- see yy_fatal_error) */ +#undef fprintf +#define fprintf(file, fmt, msg) ereport(ERROR, (errmsg_internal("%s", msg))) + +/* + * GUC variables. This is a DIRECT violation of the warning given at the + * head of gram.y, ie flex/bison code must not depend on any GUC variables; + * as such, changing their values can induce very unintuitive behavior. + * But we shall have to live with it as a short-term thing until the switch + * to SQL-standard string syntax is complete. + */ +int backslash_quote = BACKSLASH_QUOTE_SAFE_ENCODING; +bool escape_string_warning = true; +bool standard_conforming_strings = true; + +/* + * Set the type of YYSTYPE. + */ +#define YYSTYPE core_YYSTYPE + +/* + * Set the type of yyextra. All state variables used by the scanner should + * be in yyextra, *not* statically allocated. + */ +#define YY_EXTRA_TYPE core_yy_extra_type * + +/* + * Each call to core_yylex must set yylloc to the location of the found token + * (expressed as a byte offset from the start of the input text). + * When we parse a token that requires multiple lexer rules to process, + * this should be done in the first such rule, else yylloc will point + * into the middle of the token. + */ +#define SET_YYLLOC() (*(yylloc) = yytext - yyextra->scanbuf) + +/* + * Advance yylloc by the given number of bytes. + */ +#define ADVANCE_YYLLOC(delta) ( *(yylloc) += (delta) ) + +#define startlit() ( yyextra->literallen = 0 ) +static void addlit(char *ytext, int yleng, core_yyscan_t yyscanner); +static void addlitchar(unsigned char ychar, core_yyscan_t yyscanner); +static char *litbufdup(core_yyscan_t yyscanner); +static char *litbuf_udeescape(unsigned char escape, core_yyscan_t yyscanner); +static unsigned char unescape_single_char(unsigned char c, core_yyscan_t yyscanner); +static int process_integer_literal(const char *token, YYSTYPE *lval); +static bool is_utf16_surrogate_first(pg_wchar c); +static bool is_utf16_surrogate_second(pg_wchar c); +static pg_wchar surrogate_pair_to_codepoint(pg_wchar first, pg_wchar second); +static void addunicode(pg_wchar c, yyscan_t yyscanner); + +#define yyerror(msg) scanner_yyerror(msg, yyscanner) + +#define lexer_errposition() scanner_errposition(*(yylloc), yyscanner) + +static void check_string_escape_warning(unsigned char ychar, core_yyscan_t yyscanner); +static void check_escape_warning(core_yyscan_t yyscanner); + +/* + * Work around a bug in flex 2.5.35: it emits a couple of functions that + * it forgets to emit declarations for. Since we use -Wmissing-prototypes, + * this would cause warnings. Providing our own declarations should be + * harmless even when the bug gets fixed. + */ +extern int core_yyget_column(yyscan_t yyscanner); +extern void core_yyset_column(int column_no, yyscan_t yyscanner); + +#define YY_NO_INPUT 1 +/* + * OK, here is a short description of lex/flex rules behavior. + * The longest pattern which matches an input string is always chosen. + * For equal-length patterns, the first occurring in the rules list is chosen. + * INITIAL is the starting state, to which all non-conditional rules apply. + * Exclusive states change parsing rules while the state is active. When in + * an exclusive state, only those rules defined for that state apply. + * + * We use exclusive states for quoted strings, extended comments, + * and to eliminate parsing troubles for numeric strings. + * Exclusive states: + * bit string literal + * extended C-style comments + * delimited identifiers (double-quoted identifiers) + * hexadecimal numeric string + * standard quoted strings + * extended quoted strings (support backslash escape sequences) + * $foo$ quoted strings + * quoted identifier with Unicode escapes + * quoted string with Unicode escapes + * Unicode surrogate pair in extended quoted string + */ + + + + + + + + + + +/* + * In order to make the world safe for Windows and Mac clients as well as + * Unix ones, we accept either \n or \r as a newline. A DOS-style \r\n + * sequence will be seen as two successive newlines, but that doesn't cause + * any problems. Comments that start with -- and extend to the next + * newline are treated as equivalent to a single whitespace character. + * + * NOTE a fine point: if there is no newline following --, we will absorb + * everything to the end of the input as a comment. This is correct. Older + * versions of Postgres failed to recognize -- as a comment if the input + * did not end with a newline. + * + * XXX perhaps \f (formfeed) should be treated as a newline as well? + * + * XXX if you change the set of whitespace characters, fix scanner_isspace() + * to agree, and see also the plpgsql lexer. + */ +/* + * SQL requires at least one newline in the whitespace separating + * string literals that are to be concatenated. Silly, but who are we + * to argue? Note that {whitespace_with_newline} should not have * after + * it, whereas {whitespace} should generally have a * after it... + */ +/* + * To ensure that {quotecontinue} can be scanned without having to back up + * if the full pattern isn't matched, we include trailing whitespace in + * {quotestop}. This matches all cases where {quotecontinue} fails to match, + * except for {quote} followed by whitespace and just one "-" (not two, + * which would start a {comment}). To cover that we have {quotefail}. + * The actions for {quotestop} and {quotefail} must throw back characters + * beyond the quote proper. + */ +/* Bit string + * It is tempting to scan the string for only those characters + * which are allowed. However, this leads to silently swallowed + * characters if illegal characters are included in the string. + * For example, if xbinside is [01] then B'ABCD' is interpreted + * as a zero-length string, and the ABCD' is lost! + * Better to pass the string forward and let the input routines + * validate the contents. + */ +/* Hexadecimal number */ +/* National character */ +/* Quoted string that allows backslash escapes */ +/* Extended quote + * xqdouble implements embedded quote, '''' + */ +/* $foo$ style quotes ("dollar quoting") + * The quoted string starts with $foo$ where "foo" is an optional string + * in the form of an identifier, except that it may not contain "$", + * and extends to the first occurrence of an identical string. + * There is *no* processing of the quoted text. + * + * {dolqfailed} is an error rule to avoid scanner backup when {dolqdelim} + * fails to match its trailing "$". + */ +/* Double quote + * Allows embedded spaces and other special characters into identifiers. + */ +/* Unicode escapes */ +/* error rule to avoid backup */ +/* Quoted identifier with Unicode escapes */ +/* Quoted string with Unicode escapes */ +/* error rule to avoid backup */ +/* C-style comments + * + * The "extended comment" syntax closely resembles allowable operator syntax. + * The tricky part here is to get lex to recognize a string starting with + * slash-star as a comment, when interpreting it as an operator would produce + * a longer match --- remember lex will prefer a longer match! Also, if we + * have something like plus-slash-star, lex will think this is a 3-character + * operator whereas we want to see it as a + operator and a comment start. + * The solution is two-fold: + * 1. append {op_chars}* to xcstart so that it matches as much text as + * {operator} would. Then the tie-breaker (first matching rule of same + * length) ensures xcstart wins. We put back the extra stuff with yyless() + * in case it contains a star-slash that should terminate the comment. + * 2. In the operator rule, check for slash-star within the operator, and + * if found throw it back with yyless(). This handles the plus-slash-star + * problem. + * Dash-dash comments have similar interactions with the operator rule. + */ +/* + * "self" is the set of chars that should be returned as single-character + * tokens. "op_chars" is the set of chars that can make up "Op" tokens, + * which can be one or more characters long (but if a single-char token + * appears in the "self" set, it is not to be returned as an Op). Note + * that the sets overlap, but each has some chars that are not in the other. + * + * If you change either set, adjust the character lists appearing in the + * rule for "operator"! + */ +/* we no longer allow unary minus in numbers. + * instead we pass it separately to parser. there it gets + * coerced via doNegate() -- Leon aug 20 1999 + * +* {decimalfail} is used because we would like "1..10" to lex as 1, dot_dot, 10. +* + * {realfail1} and {realfail2} are added to prevent the need for scanner + * backup when the {real} rule fails to match completely. + */ +/* + * Dollar quoted strings are totally opaque, and no escaping is done on them. + * Other quoted strings must allow some special characters such as single-quote + * and newline. + * Embedded single-quotes are implemented both in the SQL standard + * style of two adjacent single quotes "''" and in the Postgres/Java style + * of escaped-quote "\'". + * Other embedded escaped characters are matched explicitly and the leading + * backslash is dropped from the string. + * Note that xcstart must appear before operator, as explained above! + * Also whitespace (comment) must appear before operator. + */ +#line 14806 "scan.c" + +#define INITIAL 0 +#define xb 1 +#define xc 2 +#define xd 3 +#define xh 4 +#define xe 5 +#define xq 6 +#define xdolq 7 +#define xui 8 +#define xus 9 +#define xeu 10 + +#ifndef YY_NO_UNISTD_H +/* Special case for "unistd.h", since it is non-ANSI. We include it way + * down here because we want the user's section 1 to have been scanned first. + * The user has a chance to override it with an option. + */ +#include +#endif + +#ifndef YY_EXTRA_TYPE +#define YY_EXTRA_TYPE void * +#endif + +/* Holds the entire state of the reentrant scanner. */ +struct yyguts_t + { + + /* User-defined. Not touched by flex. */ + YY_EXTRA_TYPE yyextra_r; + + /* The rest are the same as the globals declared in the non-reentrant scanner. */ + FILE *yyin_r, *yyout_r; + size_t yy_buffer_stack_top; /**< index of top of stack. */ + size_t yy_buffer_stack_max; /**< capacity of stack. */ + YY_BUFFER_STATE * yy_buffer_stack; /**< Stack as an array. */ + char yy_hold_char; + int yy_n_chars; + int yyleng_r; + char *yy_c_buf_p; + int yy_init; + int yy_start; + int yy_did_buffer_switch_on_eof; + int yy_start_stack_ptr; + int yy_start_stack_depth; + int *yy_start_stack; + yy_state_type yy_last_accepting_state; + char* yy_last_accepting_cpos; + + int yylineno_r; + int yy_flex_debug_r; + + char *yytext_r; + int yy_more_flag; + int yy_more_len; + + YYSTYPE * yylval_r; + + YYLTYPE * yylloc_r; + + }; /* end struct yyguts_t */ + +static int yy_init_globals (yyscan_t yyscanner ); + + /* This must go here because YYSTYPE and YYLTYPE are included + * from bison output in section 1.*/ + # define yylval yyg->yylval_r + + # define yylloc yyg->yylloc_r + +int core_yylex_init (yyscan_t* scanner); + +int core_yylex_init_extra (YY_EXTRA_TYPE user_defined,yyscan_t* scanner); + +/* Accessor methods to globals. + These are made visible to non-reentrant scanners for convenience. */ + +int core_yylex_destroy (yyscan_t yyscanner ); + +int core_yyget_debug (yyscan_t yyscanner ); + +void core_yyset_debug (int debug_flag ,yyscan_t yyscanner ); + +YY_EXTRA_TYPE core_yyget_extra (yyscan_t yyscanner ); + +void core_yyset_extra (YY_EXTRA_TYPE user_defined ,yyscan_t yyscanner ); + +FILE *core_yyget_in (yyscan_t yyscanner ); + +void core_yyset_in (FILE * in_str ,yyscan_t yyscanner ); + +FILE *core_yyget_out (yyscan_t yyscanner ); + +void core_yyset_out (FILE * out_str ,yyscan_t yyscanner ); + +int core_yyget_leng (yyscan_t yyscanner ); + +char *core_yyget_text (yyscan_t yyscanner ); + +int core_yyget_lineno (yyscan_t yyscanner ); + +void core_yyset_lineno (int line_number ,yyscan_t yyscanner ); + +YYSTYPE * core_yyget_lval (yyscan_t yyscanner ); + +void core_yyset_lval (YYSTYPE * yylval_param ,yyscan_t yyscanner ); + + YYLTYPE *core_yyget_lloc (yyscan_t yyscanner ); + + void core_yyset_lloc (YYLTYPE * yylloc_param ,yyscan_t yyscanner ); + +/* Macros after this point can all be overridden by user definitions in + * section 1. + */ + +#ifndef YY_SKIP_YYWRAP +#ifdef __cplusplus +extern "C" int core_yywrap (yyscan_t yyscanner ); +#else +extern int core_yywrap (yyscan_t yyscanner ); +#endif +#endif + +#ifndef yytext_ptr +static void yy_flex_strncpy (char *,yyconst char *,int ,yyscan_t yyscanner); +#endif + +#ifdef YY_NEED_STRLEN +static int yy_flex_strlen (yyconst char * ,yyscan_t yyscanner); +#endif + +#ifndef YY_NO_INPUT + +#ifdef __cplusplus +static int yyinput (yyscan_t yyscanner ); +#else +static int input (yyscan_t yyscanner ); +#endif + +#endif + +/* Amount of stuff to slurp up with each read. */ +#ifndef YY_READ_BUF_SIZE +#ifdef __ia64__ +/* On IA-64, the buffer size is 16k, not 8k */ +#define YY_READ_BUF_SIZE 16384 +#else +#define YY_READ_BUF_SIZE 8192 +#endif /* __ia64__ */ +#endif + +/* Copy whatever the last rule matched to the standard output. */ +#ifndef ECHO +/* This used to be an fputs(), but since the string might contain NUL's, + * we now use fwrite(). + */ +#define ECHO do { if (fwrite( yytext, yyleng, 1, yyout )) {} } while (0) +#endif + +/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL, + * is returned in "result". + */ +#ifndef YY_INPUT +#define YY_INPUT(buf,result,max_size) \ + if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \ + { \ + int c = '*'; \ + size_t n; \ + for ( n = 0; n < max_size && \ + (c = getc( yyin )) != EOF && c != '\n'; ++n ) \ + buf[n] = (char) c; \ + if ( c == '\n' ) \ + buf[n++] = (char) c; \ + if ( c == EOF && ferror( yyin ) ) \ + YY_FATAL_ERROR( "input in flex scanner failed" ); \ + result = n; \ + } \ + else \ + { \ + errno=0; \ + while ( (result = fread(buf, 1, max_size, yyin))==0 && ferror(yyin)) \ + { \ + if( errno != EINTR) \ + { \ + YY_FATAL_ERROR( "input in flex scanner failed" ); \ + break; \ + } \ + errno=0; \ + clearerr(yyin); \ + } \ + }\ +\ + +#endif + +/* No semi-colon after return; correct usage is to write "yyterminate();" - + * we don't want an extra ';' after the "return" because that will cause + * some compilers to complain about unreachable statements. + */ +#ifndef yyterminate +#define yyterminate() return YY_NULL +#endif + +/* Number of entries by which start-condition stack grows. */ +#ifndef YY_START_STACK_INCR +#define YY_START_STACK_INCR 25 +#endif + +/* Report a fatal error. */ +#ifndef YY_FATAL_ERROR +#define YY_FATAL_ERROR(msg) yy_fatal_error( msg , yyscanner) +#endif + +/* end tables serialization structures and prototypes */ + +/* Default declaration of generated scanner - a define so the user can + * easily add parameters. + */ +#ifndef YY_DECL +#define YY_DECL_IS_OURS 1 + +extern int core_yylex \ + (YYSTYPE * yylval_param,YYLTYPE * yylloc_param ,yyscan_t yyscanner); + +#define YY_DECL int core_yylex \ + (YYSTYPE * yylval_param, YYLTYPE * yylloc_param , yyscan_t yyscanner) +#endif /* !YY_DECL */ + +/* Code executed at the beginning of each rule, after yytext and yyleng + * have been set up. + */ +#ifndef YY_USER_ACTION +#define YY_USER_ACTION +#endif + +/* Code executed at the end of each rule. */ +#ifndef YY_BREAK +#define YY_BREAK break; +#endif + +#define YY_RULE_SETUP \ + YY_USER_ACTION + +/** The main scanner function which does all the work. + */ +YY_DECL +{ + register yy_state_type yy_current_state; + register char *yy_cp, *yy_bp; + register int yy_act; + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + +#line 372 "scan.l" + + +#line 15063 "scan.c" + + yylval = yylval_param; + + yylloc = yylloc_param; + + if ( !yyg->yy_init ) + { + yyg->yy_init = 1; + +#ifdef YY_USER_INIT + YY_USER_INIT; +#endif + + if ( ! yyg->yy_start ) + yyg->yy_start = 1; /* first start state */ + + if ( ! yyin ) + yyin = stdin; + + if ( ! yyout ) + yyout = stdout; + + if ( ! YY_CURRENT_BUFFER ) { + core_yyensure_buffer_stack (yyscanner); + YY_CURRENT_BUFFER_LVALUE = + core_yy_create_buffer(yyin,YY_BUF_SIZE ,yyscanner); + } + + core_yy_load_buffer_state(yyscanner ); + } + + while ( 1 ) /* loops until end-of-file is reached */ + { + yy_cp = yyg->yy_c_buf_p; + + /* Support of yytext. */ + *yy_cp = yyg->yy_hold_char; + + /* yy_bp points to the position in yy_ch_buf of the start of + * the current run. + */ + yy_bp = yy_cp; + + yy_current_state = yy_start_state_list[yyg->yy_start]; +yy_match: + { + register yyconst struct yy_trans_info *yy_trans_info; + + register YY_CHAR yy_c; + + for ( yy_c = YY_SC_TO_UI(*yy_cp); + (yy_trans_info = &yy_current_state[(unsigned int) yy_c])-> + yy_verify == yy_c; + yy_c = YY_SC_TO_UI(*++yy_cp) ) + yy_current_state += yy_trans_info->yy_nxt; + } + +yy_find_action: + yy_act = yy_current_state[-1].yy_nxt; + + YY_DO_BEFORE_ACTION; + +do_action: /* This label is used only to access EOF actions. */ + + switch ( yy_act ) + { /* beginning of action switch */ +case 1: +/* rule 1 can match eol */ +YY_RULE_SETUP +#line 374 "scan.l" +{ + /* ignore */ + } + YY_BREAK +case 2: +YY_RULE_SETUP +#line 378 "scan.l" +{ + /* Set location in case of syntax error in comment */ + SET_YYLLOC(); + yyextra->xcdepth = 0; + BEGIN(xc); + /* Put back any characters past slash-star; see above */ + yyless(2); + } + YY_BREAK +case 3: +YY_RULE_SETUP +#line 387 "scan.l" +{ + (yyextra->xcdepth)++; + /* Put back any characters past slash-star; see above */ + yyless(2); + } + YY_BREAK +case 4: +YY_RULE_SETUP +#line 393 "scan.l" +{ + if (yyextra->xcdepth <= 0) + BEGIN(INITIAL); + else + (yyextra->xcdepth)--; + } + YY_BREAK +case 5: +/* rule 5 can match eol */ +YY_RULE_SETUP +#line 400 "scan.l" +{ + /* ignore */ + } + YY_BREAK +case 6: +YY_RULE_SETUP +#line 404 "scan.l" +{ + /* ignore */ + } + YY_BREAK +case 7: +YY_RULE_SETUP +#line 408 "scan.l" +{ + /* ignore */ + } + YY_BREAK +case YY_STATE_EOF(xc): +#line 412 "scan.l" +{ yyerror("unterminated /* comment"); } + YY_BREAK +case 8: +YY_RULE_SETUP +#line 414 "scan.l" +{ + /* Binary bit type. + * At some point we should simply pass the string + * forward to the parser and label it there. + * In the meantime, place a leading "b" on the string + * to mark it for the input routine as a binary string. + */ + SET_YYLLOC(); + BEGIN(xb); + startlit(); + addlitchar('b', yyscanner); + } + YY_BREAK +case 9: +/* rule 9 can match eol */ +#line 427 "scan.l" +case 10: +/* rule 10 can match eol */ +YY_RULE_SETUP +#line 427 "scan.l" +{ + yyless(1); + BEGIN(INITIAL); + yylval->str = litbufdup(yyscanner); + return BCONST; + } + YY_BREAK +case 11: +/* rule 11 can match eol */ +#line 434 "scan.l" +case 12: +/* rule 12 can match eol */ +YY_RULE_SETUP +#line 434 "scan.l" +{ + addlit(yytext, yyleng, yyscanner); + } + YY_BREAK +case 13: +/* rule 13 can match eol */ +#line 438 "scan.l" +case 14: +/* rule 14 can match eol */ +YY_RULE_SETUP +#line 438 "scan.l" +{ + /* ignore */ + } + YY_BREAK +case YY_STATE_EOF(xb): +#line 441 "scan.l" +{ yyerror("unterminated bit string literal"); } + YY_BREAK +case 15: +YY_RULE_SETUP +#line 443 "scan.l" +{ + /* Hexadecimal bit type. + * At some point we should simply pass the string + * forward to the parser and label it there. + * In the meantime, place a leading "x" on the string + * to mark it for the input routine as a hex string. + */ + SET_YYLLOC(); + BEGIN(xh); + startlit(); + addlitchar('x', yyscanner); + } + YY_BREAK +case 16: +/* rule 16 can match eol */ +#line 456 "scan.l" +case 17: +/* rule 17 can match eol */ +YY_RULE_SETUP +#line 456 "scan.l" +{ + yyless(1); + BEGIN(INITIAL); + yylval->str = litbufdup(yyscanner); + return XCONST; + } + YY_BREAK +case YY_STATE_EOF(xh): +#line 462 "scan.l" +{ yyerror("unterminated hexadecimal string literal"); } + YY_BREAK +case 18: +YY_RULE_SETUP +#line 464 "scan.l" +{ + /* National character. + * We will pass this along as a normal character string, + * but preceded with an internally-generated "NCHAR". + */ + const ScanKeyword *keyword; + + SET_YYLLOC(); + yyless(1); /* eat only 'n' this time */ + + keyword = ScanKeywordLookup("nchar", + yyextra->keywords, + yyextra->num_keywords); + if (keyword != NULL) + { + yylval->keyword = keyword->name; + return keyword->value; + } + else + { + /* If NCHAR isn't a keyword, just return "n" */ + yylval->str = pstrdup("n"); + return IDENT; + } + } + YY_BREAK +case 19: +YY_RULE_SETUP +#line 490 "scan.l" +{ + yyextra->warn_on_first_escape = true; + yyextra->saw_non_ascii = false; + SET_YYLLOC(); + if (standard_conforming_strings) + BEGIN(xq); + else + BEGIN(xe); + startlit(); + } + YY_BREAK +case 20: +YY_RULE_SETUP +#line 500 "scan.l" +{ + yyextra->warn_on_first_escape = false; + yyextra->saw_non_ascii = false; + SET_YYLLOC(); + BEGIN(xe); + startlit(); + } + YY_BREAK +case 21: +YY_RULE_SETUP +#line 507 "scan.l" +{ + SET_YYLLOC(); + if (!standard_conforming_strings) + ereport(ERROR, + (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), + errmsg("unsafe use of string constant with Unicode escapes"), + errdetail("String constants with Unicode escapes cannot be used when standard_conforming_strings is off."), + lexer_errposition())); + BEGIN(xus); + startlit(); + } + YY_BREAK +case 22: +/* rule 22 can match eol */ +#line 519 "scan.l" +case 23: +/* rule 23 can match eol */ +YY_RULE_SETUP +#line 519 "scan.l" +{ + yyless(1); + BEGIN(INITIAL); + /* + * check that the data remains valid if it might have been + * made invalid by unescaping any chars. + */ + if (yyextra->saw_non_ascii) + pg_verifymbstr(yyextra->literalbuf, + yyextra->literallen, + false); + yylval->str = litbufdup(yyscanner); + return SCONST; + } + YY_BREAK +case 24: +/* rule 24 can match eol */ +YY_RULE_SETUP +#line 533 "scan.l" +{ + /* throw back all but the quote */ + yyless(1); + BEGIN(INITIAL); + yylval->str = litbuf_udeescape('\\', yyscanner); + return SCONST; + } + YY_BREAK +case 25: +/* rule 25 can match eol */ +YY_RULE_SETUP +#line 540 "scan.l" +{ + BEGIN(INITIAL); + yylval->str = litbuf_udeescape(yytext[yyleng-2], yyscanner); + return SCONST; + } + YY_BREAK +case 26: +YY_RULE_SETUP +#line 545 "scan.l" +{ + addlitchar('\'', yyscanner); + } + YY_BREAK +case 27: +/* rule 27 can match eol */ +YY_RULE_SETUP +#line 548 "scan.l" +{ + addlit(yytext, yyleng, yyscanner); + } + YY_BREAK +case 28: +/* rule 28 can match eol */ +YY_RULE_SETUP +#line 551 "scan.l" +{ + addlit(yytext, yyleng, yyscanner); + } + YY_BREAK +case 29: +YY_RULE_SETUP +#line 554 "scan.l" +{ + pg_wchar c = strtoul(yytext+2, NULL, 16); + + check_escape_warning(yyscanner); + + if (is_utf16_surrogate_first(c)) + { + yyextra->utf16_first_part = c; + BEGIN(xeu); + } + else if (is_utf16_surrogate_second(c)) + yyerror("invalid Unicode surrogate pair"); + else + addunicode(c, yyscanner); + } + YY_BREAK +case 30: +YY_RULE_SETUP +#line 569 "scan.l" +{ + pg_wchar c = strtoul(yytext+2, NULL, 16); + + if (!is_utf16_surrogate_second(c)) + yyerror("invalid Unicode surrogate pair"); + + c = surrogate_pair_to_codepoint(yyextra->utf16_first_part, c); + + addunicode(c, yyscanner); + + BEGIN(xe); + } + YY_BREAK +case 31: +YY_RULE_SETUP +#line 581 "scan.l" +{ yyerror("invalid Unicode surrogate pair"); } + YY_BREAK +case 32: +/* rule 32 can match eol */ +YY_RULE_SETUP +#line 582 "scan.l" +{ yyerror("invalid Unicode surrogate pair"); } + YY_BREAK +case YY_STATE_EOF(xeu): +#line 583 "scan.l" +{ yyerror("invalid Unicode surrogate pair"); } + YY_BREAK +case 33: +YY_RULE_SETUP +#line 584 "scan.l" +{ + ereport(ERROR, + (errcode(ERRCODE_INVALID_ESCAPE_SEQUENCE), + errmsg("invalid Unicode escape"), + errhint("Unicode escapes must be \\uXXXX or \\UXXXXXXXX."), + lexer_errposition())); + } + YY_BREAK +case 34: +/* rule 34 can match eol */ +YY_RULE_SETUP +#line 591 "scan.l" +{ + if (yytext[1] == '\'') + { + if (backslash_quote == BACKSLASH_QUOTE_OFF || + (backslash_quote == BACKSLASH_QUOTE_SAFE_ENCODING && + PG_ENCODING_IS_CLIENT_ONLY(pg_get_client_encoding()))) + ereport(ERROR, + (errcode(ERRCODE_NONSTANDARD_USE_OF_ESCAPE_CHARACTER), + errmsg("unsafe use of \\' in a string literal"), + errhint("Use '' to write quotes in strings. \\' is insecure in client-only encodings."), + lexer_errposition())); + } + check_string_escape_warning(yytext[1], yyscanner); + addlitchar(unescape_single_char(yytext[1], yyscanner), + yyscanner); + } + YY_BREAK +case 35: +YY_RULE_SETUP +#line 607 "scan.l" +{ + unsigned char c = strtoul(yytext+1, NULL, 8); + + check_escape_warning(yyscanner); + addlitchar(c, yyscanner); + if (c == '\0' || IS_HIGHBIT_SET(c)) + yyextra->saw_non_ascii = true; + } + YY_BREAK +case 36: +YY_RULE_SETUP +#line 615 "scan.l" +{ + unsigned char c = strtoul(yytext+2, NULL, 16); + + check_escape_warning(yyscanner); + addlitchar(c, yyscanner); + if (c == '\0' || IS_HIGHBIT_SET(c)) + yyextra->saw_non_ascii = true; + } + YY_BREAK +case 37: +/* rule 37 can match eol */ +YY_RULE_SETUP +#line 623 "scan.l" +{ + /* ignore */ + } + YY_BREAK +case 38: +YY_RULE_SETUP +#line 626 "scan.l" +{ + /* This is only needed for \ just before EOF */ + addlitchar(yytext[0], yyscanner); + } + YY_BREAK +case YY_STATE_EOF(xq): +case YY_STATE_EOF(xe): +case YY_STATE_EOF(xus): +#line 630 "scan.l" +{ yyerror("unterminated quoted string"); } + YY_BREAK +case 39: +YY_RULE_SETUP +#line 632 "scan.l" +{ + SET_YYLLOC(); + yyextra->dolqstart = pstrdup(yytext); + BEGIN(xdolq); + startlit(); + } + YY_BREAK +case 40: +YY_RULE_SETUP +#line 638 "scan.l" +{ + SET_YYLLOC(); + /* throw back all but the initial "$" */ + yyless(1); + /* and treat it as {other} */ + return yytext[0]; + } + YY_BREAK +case 41: +YY_RULE_SETUP +#line 645 "scan.l" +{ + if (strcmp(yytext, yyextra->dolqstart) == 0) + { + pfree(yyextra->dolqstart); + yyextra->dolqstart = NULL; + BEGIN(INITIAL); + yylval->str = litbufdup(yyscanner); + return SCONST; + } + else + { + /* + * When we fail to match $...$ to dolqstart, transfer + * the $... part to the output, but put back the final + * $ for rescanning. Consider $delim$...$junk$delim$ + */ + addlit(yytext, yyleng-1, yyscanner); + yyless(yyleng-1); + } + } + YY_BREAK +case 42: +/* rule 42 can match eol */ +YY_RULE_SETUP +#line 665 "scan.l" +{ + addlit(yytext, yyleng, yyscanner); + } + YY_BREAK +case 43: +YY_RULE_SETUP +#line 668 "scan.l" +{ + addlit(yytext, yyleng, yyscanner); + } + YY_BREAK +case 44: +YY_RULE_SETUP +#line 671 "scan.l" +{ + /* This is only needed for $ inside the quoted text */ + addlitchar(yytext[0], yyscanner); + } + YY_BREAK +case YY_STATE_EOF(xdolq): +#line 675 "scan.l" +{ yyerror("unterminated dollar-quoted string"); } + YY_BREAK +case 45: +YY_RULE_SETUP +#line 677 "scan.l" +{ + SET_YYLLOC(); + BEGIN(xd); + startlit(); + } + YY_BREAK +case 46: +YY_RULE_SETUP +#line 682 "scan.l" +{ + SET_YYLLOC(); + BEGIN(xui); + startlit(); + } + YY_BREAK +case 47: +YY_RULE_SETUP +#line 687 "scan.l" +{ + char *ident; + + BEGIN(INITIAL); + if (yyextra->literallen == 0) + yyerror("zero-length delimited identifier"); + ident = litbufdup(yyscanner); + if (yyextra->literallen >= NAMEDATALEN) + truncate_identifier(ident, yyextra->literallen, true); + yylval->str = ident; + return IDENT; + } + YY_BREAK +case 48: +/* rule 48 can match eol */ +YY_RULE_SETUP +#line 699 "scan.l" +{ + char *ident; + + BEGIN(INITIAL); + if (yyextra->literallen == 0) + yyerror("zero-length delimited identifier"); + ident = litbuf_udeescape('\\', yyscanner); + if (yyextra->literallen >= NAMEDATALEN) + truncate_identifier(ident, yyextra->literallen, true); + yylval->str = ident; + /* throw back all but the quote */ + yyless(1); + return IDENT; + } + YY_BREAK +case 49: +/* rule 49 can match eol */ +YY_RULE_SETUP +#line 713 "scan.l" +{ + char *ident; + + BEGIN(INITIAL); + if (yyextra->literallen == 0) + yyerror("zero-length delimited identifier"); + ident = litbuf_udeescape(yytext[yyleng - 2], yyscanner); + if (yyextra->literallen >= NAMEDATALEN) + truncate_identifier(ident, yyextra->literallen, true); + yylval->str = ident; + return IDENT; + } + YY_BREAK +case 50: +YY_RULE_SETUP +#line 725 "scan.l" +{ + addlitchar('"', yyscanner); + } + YY_BREAK +case 51: +/* rule 51 can match eol */ +YY_RULE_SETUP +#line 728 "scan.l" +{ + addlit(yytext, yyleng, yyscanner); + } + YY_BREAK +case YY_STATE_EOF(xd): +case YY_STATE_EOF(xui): +#line 731 "scan.l" +{ yyerror("unterminated quoted identifier"); } + YY_BREAK +case 52: +YY_RULE_SETUP +#line 733 "scan.l" +{ + char *ident; + + SET_YYLLOC(); + /* throw back all but the initial u/U */ + yyless(1); + /* and treat it as {identifier} */ + ident = downcase_truncate_identifier(yytext, yyleng, true); + yylval->str = ident; + return IDENT; + } + YY_BREAK +case 53: +YY_RULE_SETUP +#line 745 "scan.l" +{ + SET_YYLLOC(); + return TYPECAST; + } + YY_BREAK +case 54: +YY_RULE_SETUP +#line 750 "scan.l" +{ + SET_YYLLOC(); + return DOT_DOT; + } + YY_BREAK +case 55: +YY_RULE_SETUP +#line 755 "scan.l" +{ + SET_YYLLOC(); + return COLON_EQUALS; + } + YY_BREAK +case 56: +YY_RULE_SETUP +#line 760 "scan.l" +{ + SET_YYLLOC(); + return yytext[0]; + } + YY_BREAK +case 57: +YY_RULE_SETUP +#line 765 "scan.l" +{ + /* + * Check for embedded slash-star or dash-dash; those + * are comment starts, so operator must stop there. + * Note that slash-star or dash-dash at the first + * character will match a prior rule, not this one. + */ + int nchars = yyleng; + char *slashstar = strstr(yytext, "/*"); + char *dashdash = strstr(yytext, "--"); + + if (slashstar && dashdash) + { + /* if both appear, take the first one */ + if (slashstar > dashdash) + slashstar = dashdash; + } + else if (!slashstar) + slashstar = dashdash; + if (slashstar) + nchars = slashstar - yytext; + + /* + * For SQL compatibility, '+' and '-' cannot be the + * last char of a multi-char operator unless the operator + * contains chars that are not in SQL operators. + * The idea is to lex '=-' as two operators, but not + * to forbid operator names like '?-' that could not be + * sequences of SQL operators. + */ + while (nchars > 1 && + (yytext[nchars-1] == '+' || + yytext[nchars-1] == '-')) + { + int ic; + + for (ic = nchars-2; ic >= 0; ic--) + { + if (strchr("~!@#^&|`?%", yytext[ic])) + break; + } + if (ic >= 0) + break; /* found a char that makes it OK */ + nchars--; /* else remove the +/-, and check again */ + } + + SET_YYLLOC(); + + if (nchars < yyleng) + { + /* Strip the unwanted chars from the token */ + yyless(nchars); + /* + * If what we have left is only one char, and it's + * one of the characters matching "self", then + * return it as a character token the same way + * that the "self" rule would have. + */ + if (nchars == 1 && + strchr(",()[].;:+-*/%^<>=", yytext[0])) + return yytext[0]; + } + + /* + * Complain if operator is too long. Unlike the case + * for identifiers, we make this an error not a notice- + * and-truncate, because the odds are we are looking at + * a syntactic mistake anyway. + */ + if (nchars >= NAMEDATALEN) + yyerror("operator too long"); + + /* Convert "!=" operator to "<>" for compatibility */ + if (strcmp(yytext, "!=") == 0) + yylval->str = pstrdup("<>"); + else + yylval->str = pstrdup(yytext); + return Op; + } + YY_BREAK +case 58: +YY_RULE_SETUP +#line 845 "scan.l" +{ + SET_YYLLOC(); + yylval->ival = atol(yytext + 1); + return PARAM; + } + YY_BREAK +case 59: +YY_RULE_SETUP +#line 851 "scan.l" +{ + SET_YYLLOC(); + return process_integer_literal(yytext, yylval); + } + YY_BREAK +case 60: +YY_RULE_SETUP +#line 855 "scan.l" +{ + SET_YYLLOC(); + yylval->str = pstrdup(yytext); + return FCONST; + } + YY_BREAK +case 61: +YY_RULE_SETUP +#line 860 "scan.l" +{ + /* throw back the .., and treat as integer */ + yyless(yyleng-2); + SET_YYLLOC(); + return process_integer_literal(yytext, yylval); + } + YY_BREAK +case 62: +YY_RULE_SETUP +#line 866 "scan.l" +{ + SET_YYLLOC(); + yylval->str = pstrdup(yytext); + return FCONST; + } + YY_BREAK +case 63: +YY_RULE_SETUP +#line 871 "scan.l" +{ + /* + * throw back the [Ee], and treat as {decimal}. Note + * that it is possible the input is actually {integer}, + * but since this case will almost certainly lead to a + * syntax error anyway, we don't bother to distinguish. + */ + yyless(yyleng-1); + SET_YYLLOC(); + yylval->str = pstrdup(yytext); + return FCONST; + } + YY_BREAK +case 64: +YY_RULE_SETUP +#line 883 "scan.l" +{ + /* throw back the [Ee][+-], and proceed as above */ + yyless(yyleng-2); + SET_YYLLOC(); + yylval->str = pstrdup(yytext); + return FCONST; + } + YY_BREAK +case 65: +YY_RULE_SETUP +#line 892 "scan.l" +{ + const ScanKeyword *keyword; + char *ident; + + SET_YYLLOC(); + + /* Is it a keyword? */ + keyword = ScanKeywordLookup(yytext, + yyextra->keywords, + yyextra->num_keywords); + if (keyword != NULL) + { + yylval->keyword = keyword->name; + return keyword->value; + } + + /* + * No. Convert the identifier to lower case, and truncate + * if necessary. + */ + ident = downcase_truncate_identifier(yytext, yyleng, true); + yylval->str = ident; + return IDENT; + } + YY_BREAK +case 66: +YY_RULE_SETUP +#line 917 "scan.l" +{ + SET_YYLLOC(); + return yytext[0]; + } + YY_BREAK +case YY_STATE_EOF(INITIAL): +#line 922 "scan.l" +{ + SET_YYLLOC(); + yyterminate(); + } + YY_BREAK +case 67: +YY_RULE_SETUP +#line 927 "scan.l" +YY_FATAL_ERROR( "flex scanner jammed" ); + YY_BREAK +#line 15961 "scan.c" + + case YY_END_OF_BUFFER: + { + /* Amount of text matched not including the EOB char. */ + int yy_amount_of_matched_text = (int) (yy_cp - yyg->yytext_ptr) - 1; + + /* Undo the effects of YY_DO_BEFORE_ACTION. */ + *yy_cp = yyg->yy_hold_char; + YY_RESTORE_YY_MORE_OFFSET + + if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW ) + { + /* We're scanning a new file or input source. It's + * possible that this happened because the user + * just pointed yyin at a new source and called + * core_yylex(). If so, then we have to assure + * consistency between YY_CURRENT_BUFFER and our + * globals. Here is the right place to do so, because + * this is the first action (other than possibly a + * back-up) that will match for the new input source. + */ + yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars; + YY_CURRENT_BUFFER_LVALUE->yy_input_file = yyin; + YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL; + } + + /* Note that here we test for yy_c_buf_p "<=" to the position + * of the first EOB in the buffer, since yy_c_buf_p will + * already have been incremented past the NUL character + * (since all states make transitions on EOB to the + * end-of-buffer state). Contrast this with the test + * in input(). + */ + if ( yyg->yy_c_buf_p <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] ) + { /* This was really a NUL. */ + yy_state_type yy_next_state; + + yyg->yy_c_buf_p = yyg->yytext_ptr + yy_amount_of_matched_text; + + yy_current_state = yy_get_previous_state( yyscanner ); + + /* Okay, we're now positioned to make the NUL + * transition. We couldn't have + * yy_get_previous_state() go ahead and do it + * for us because it doesn't know how to deal + * with the possibility of jamming (and we don't + * want to build jamming into it because then it + * will run more slowly). + */ + + yy_next_state = yy_try_NUL_trans( yy_current_state , yyscanner); + + yy_bp = yyg->yytext_ptr + YY_MORE_ADJ; + + if ( yy_next_state ) + { + /* Consume the NUL. */ + yy_cp = ++yyg->yy_c_buf_p; + yy_current_state = yy_next_state; + goto yy_match; + } + + else + { + yy_cp = yyg->yy_c_buf_p; + goto yy_find_action; + } + } + + else switch ( yy_get_next_buffer( yyscanner ) ) + { + case EOB_ACT_END_OF_FILE: + { + yyg->yy_did_buffer_switch_on_eof = 0; + + if ( core_yywrap(yyscanner ) ) + { + /* Note: because we've taken care in + * yy_get_next_buffer() to have set up + * yytext, we can now set up + * yy_c_buf_p so that if some total + * hoser (like flex itself) wants to + * call the scanner after we return the + * YY_NULL, it'll still work - another + * YY_NULL will get returned. + */ + yyg->yy_c_buf_p = yyg->yytext_ptr + YY_MORE_ADJ; + + yy_act = YY_STATE_EOF(YY_START); + goto do_action; + } + + else + { + if ( ! yyg->yy_did_buffer_switch_on_eof ) + YY_NEW_FILE; + } + break; + } + + case EOB_ACT_CONTINUE_SCAN: + yyg->yy_c_buf_p = + yyg->yytext_ptr + yy_amount_of_matched_text; + + yy_current_state = yy_get_previous_state( yyscanner ); + + yy_cp = yyg->yy_c_buf_p; + yy_bp = yyg->yytext_ptr + YY_MORE_ADJ; + goto yy_match; + + case EOB_ACT_LAST_MATCH: + yyg->yy_c_buf_p = + &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars]; + + yy_current_state = yy_get_previous_state( yyscanner ); + + yy_cp = yyg->yy_c_buf_p; + yy_bp = yyg->yytext_ptr + YY_MORE_ADJ; + goto yy_find_action; + } + break; + } + + default: + YY_FATAL_ERROR( + "fatal flex scanner internal error--no action found" ); + } /* end of action switch */ + } /* end of scanning one token */ +} /* end of core_yylex */ + +/* yy_get_next_buffer - try to read in a new buffer + * + * Returns a code representing an action: + * EOB_ACT_LAST_MATCH - + * EOB_ACT_CONTINUE_SCAN - continue scanning from current position + * EOB_ACT_END_OF_FILE - end of file + */ +static int yy_get_next_buffer (yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + register char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf; + register char *source = yyg->yytext_ptr; + register int number_to_move, i; + int ret_val; + + if ( yyg->yy_c_buf_p > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1] ) + YY_FATAL_ERROR( + "fatal flex scanner internal error--end of buffer missed" ); + + if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 ) + { /* Don't try to fill the buffer, so this is an EOF. */ + if ( yyg->yy_c_buf_p - yyg->yytext_ptr - YY_MORE_ADJ == 1 ) + { + /* We matched a single character, the EOB, so + * treat this as a final EOF. + */ + return EOB_ACT_END_OF_FILE; + } + + else + { + /* We matched some text prior to the EOB, first + * process it. + */ + return EOB_ACT_LAST_MATCH; + } + } + + /* Try to read more data. */ + + /* First move last chars to start of buffer. */ + number_to_move = (int) (yyg->yy_c_buf_p - yyg->yytext_ptr) - 1; + + for ( i = 0; i < number_to_move; ++i ) + *(dest++) = *(source++); + + if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING ) + /* don't do the read, it's not guaranteed to return an EOF, + * just force an EOF + */ + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars = 0; + + else + { + int num_to_read = + YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1; + + while ( num_to_read <= 0 ) + { /* Not enough room in the buffer - grow it. */ + + /* just a shorter name for the current buffer */ + YY_BUFFER_STATE b = YY_CURRENT_BUFFER; + + int yy_c_buf_p_offset = + (int) (yyg->yy_c_buf_p - b->yy_ch_buf); + + if ( b->yy_is_our_buffer ) + { + int new_size = b->yy_buf_size * 2; + + if ( new_size <= 0 ) + b->yy_buf_size += b->yy_buf_size / 8; + else + b->yy_buf_size *= 2; + + b->yy_ch_buf = (char *) + /* Include room in for 2 EOB chars. */ + core_yyrealloc((void *) b->yy_ch_buf,b->yy_buf_size + 2 ,yyscanner ); + } + else + /* Can't grow it, we don't own it. */ + b->yy_ch_buf = 0; + + if ( ! b->yy_ch_buf ) + YY_FATAL_ERROR( + "fatal error - scanner input buffer overflow" ); + + yyg->yy_c_buf_p = &b->yy_ch_buf[yy_c_buf_p_offset]; + + num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size - + number_to_move - 1; + + } + + if ( num_to_read > YY_READ_BUF_SIZE ) + num_to_read = YY_READ_BUF_SIZE; + + /* Read in more data. */ + YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]), + yyg->yy_n_chars, (size_t) num_to_read ); + + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars; + } + + if ( yyg->yy_n_chars == 0 ) + { + if ( number_to_move == YY_MORE_ADJ ) + { + ret_val = EOB_ACT_END_OF_FILE; + core_yyrestart(yyin ,yyscanner); + } + + else + { + ret_val = EOB_ACT_LAST_MATCH; + YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = + YY_BUFFER_EOF_PENDING; + } + } + + else + ret_val = EOB_ACT_CONTINUE_SCAN; + + if ((yy_size_t) (yyg->yy_n_chars + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) { + /* Extend the array by 50%, plus the number we really need. */ + yy_size_t new_size = yyg->yy_n_chars + number_to_move + (yyg->yy_n_chars >> 1); + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) core_yyrealloc((void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,new_size ,yyscanner ); + if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf ) + YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" ); + } + + yyg->yy_n_chars += number_to_move; + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] = YY_END_OF_BUFFER_CHAR; + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR; + + yyg->yytext_ptr = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0]; + + return ret_val; +} + +/* yy_get_previous_state - get the state just before the EOB char was reached */ + + static yy_state_type yy_get_previous_state (yyscan_t yyscanner) +{ + register yy_state_type yy_current_state; + register char *yy_cp; + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + + yy_current_state = yy_start_state_list[yyg->yy_start]; + + for ( yy_cp = yyg->yytext_ptr + YY_MORE_ADJ; yy_cp < yyg->yy_c_buf_p; ++yy_cp ) + { + yy_current_state += yy_current_state[(*yy_cp ? YY_SC_TO_UI(*yy_cp) : 256)].yy_nxt; + } + + return yy_current_state; +} + +/* yy_try_NUL_trans - try to make a transition on the NUL character + * + * synopsis + * next_state = yy_try_NUL_trans( current_state ); + */ + static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state , yyscan_t yyscanner) +{ + register int yy_is_jam; + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; /* This var may be unused depending upon options. */ + + register int yy_c = 256; + register yyconst struct yy_trans_info *yy_trans_info; + + yy_trans_info = &yy_current_state[(unsigned int) yy_c]; + yy_current_state += yy_trans_info->yy_nxt; + yy_is_jam = (yy_trans_info->yy_verify != yy_c); + + return yy_is_jam ? 0 : yy_current_state; +} + +#ifndef YY_NO_INPUT +#ifdef __cplusplus + static int yyinput (yyscan_t yyscanner) +#else + static int input (yyscan_t yyscanner) +#endif + +{ + int c; + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + + *yyg->yy_c_buf_p = yyg->yy_hold_char; + + if ( *yyg->yy_c_buf_p == YY_END_OF_BUFFER_CHAR ) + { + /* yy_c_buf_p now points to the character we want to return. + * If this occurs *before* the EOB characters, then it's a + * valid NUL; if not, then we've hit the end of the buffer. + */ + if ( yyg->yy_c_buf_p < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[yyg->yy_n_chars] ) + /* This was really a NUL. */ + *yyg->yy_c_buf_p = '\0'; + + else + { /* need more input */ + int offset = yyg->yy_c_buf_p - yyg->yytext_ptr; + ++yyg->yy_c_buf_p; + + switch ( yy_get_next_buffer( yyscanner ) ) + { + case EOB_ACT_LAST_MATCH: + /* This happens because yy_g_n_b() + * sees that we've accumulated a + * token and flags that we need to + * try matching the token before + * proceeding. But for input(), + * there's no matching to consider. + * So convert the EOB_ACT_LAST_MATCH + * to EOB_ACT_END_OF_FILE. + */ + + /* Reset buffer status. */ + core_yyrestart(yyin ,yyscanner); + + /*FALLTHROUGH*/ + + case EOB_ACT_END_OF_FILE: + { + if ( core_yywrap(yyscanner ) ) + return EOF; + + if ( ! yyg->yy_did_buffer_switch_on_eof ) + YY_NEW_FILE; +#ifdef __cplusplus + return yyinput(yyscanner); +#else + return input(yyscanner); +#endif + } + + case EOB_ACT_CONTINUE_SCAN: + yyg->yy_c_buf_p = yyg->yytext_ptr + offset; + break; + } + } + } + + c = *(unsigned char *) yyg->yy_c_buf_p; /* cast for 8-bit char's */ + *yyg->yy_c_buf_p = '\0'; /* preserve yytext */ + yyg->yy_hold_char = *++yyg->yy_c_buf_p; + + return c; +} +#endif /* ifndef YY_NO_INPUT */ + +/** Immediately switch to a different input stream. + * @param input_file A readable stream. + * @param yyscanner The scanner object. + * @note This function does not reset the start condition to @c INITIAL . + */ + void core_yyrestart (FILE * input_file , yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + + if ( ! YY_CURRENT_BUFFER ){ + core_yyensure_buffer_stack (yyscanner); + YY_CURRENT_BUFFER_LVALUE = + core_yy_create_buffer(yyin,YY_BUF_SIZE ,yyscanner); + } + + core_yy_init_buffer(YY_CURRENT_BUFFER,input_file ,yyscanner); + core_yy_load_buffer_state(yyscanner ); +} + +/** Switch to a different input buffer. + * @param new_buffer The new input buffer. + * @param yyscanner The scanner object. + */ + void core_yy_switch_to_buffer (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + + /* TODO. We should be able to replace this entire function body + * with + * core_yypop_buffer_state(); + * core_yypush_buffer_state(new_buffer); + */ + core_yyensure_buffer_stack (yyscanner); + if ( YY_CURRENT_BUFFER == new_buffer ) + return; + + if ( YY_CURRENT_BUFFER ) + { + /* Flush out information for old buffer. */ + *yyg->yy_c_buf_p = yyg->yy_hold_char; + YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = yyg->yy_c_buf_p; + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars; + } + + YY_CURRENT_BUFFER_LVALUE = new_buffer; + core_yy_load_buffer_state(yyscanner ); + + /* We don't actually know whether we did this switch during + * EOF (core_yywrap()) processing, but the only time this flag + * is looked at is after core_yywrap() is called, so it's safe + * to go ahead and always set it. + */ + yyg->yy_did_buffer_switch_on_eof = 1; +} + +static void core_yy_load_buffer_state (yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars; + yyg->yytext_ptr = yyg->yy_c_buf_p = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos; + yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file; + yyg->yy_hold_char = *yyg->yy_c_buf_p; +} + +/** Allocate and initialize an input buffer state. + * @param file A readable stream. + * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE. + * @param yyscanner The scanner object. + * @return the allocated buffer state. + */ + YY_BUFFER_STATE core_yy_create_buffer (FILE * file, int size , yyscan_t yyscanner) +{ + YY_BUFFER_STATE b; + + b = (YY_BUFFER_STATE) core_yyalloc(sizeof( struct yy_buffer_state ) ,yyscanner ); + if ( ! b ) + YY_FATAL_ERROR( "out of dynamic memory in core_yy_create_buffer()" ); + + b->yy_buf_size = size; + + /* yy_ch_buf has to be 2 characters longer than the size given because + * we need to put in 2 end-of-buffer characters. + */ + b->yy_ch_buf = (char *) core_yyalloc(b->yy_buf_size + 2 ,yyscanner ); + if ( ! b->yy_ch_buf ) + YY_FATAL_ERROR( "out of dynamic memory in core_yy_create_buffer()" ); + + b->yy_is_our_buffer = 1; + + core_yy_init_buffer(b,file ,yyscanner); + + return b; +} + +/** Destroy the buffer. + * @param b a buffer created with core_yy_create_buffer() + * @param yyscanner The scanner object. + */ + void core_yy_delete_buffer (YY_BUFFER_STATE b , yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + + if ( ! b ) + return; + + if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */ + YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0; + + if ( b->yy_is_our_buffer ) + core_yyfree((void *) b->yy_ch_buf ,yyscanner ); + + core_yyfree((void *) b ,yyscanner ); +} + +/* Initializes or reinitializes a buffer. + * This function is sometimes called more than once on the same buffer, + * such as during a core_yyrestart() or at EOF. + */ + static void core_yy_init_buffer (YY_BUFFER_STATE b, FILE * file , yyscan_t yyscanner) + +{ + int oerrno = errno; + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + + core_yy_flush_buffer(b ,yyscanner); + + b->yy_input_file = file; + b->yy_fill_buffer = 1; + + /* If b is the current buffer, then core_yy_init_buffer was _probably_ + * called from core_yyrestart() or through yy_get_next_buffer. + * In that case, we don't want to reset the lineno or column. + */ + if (b != YY_CURRENT_BUFFER){ + b->yy_bs_lineno = 1; + b->yy_bs_column = 0; + } + + b->yy_is_interactive = 0; + + errno = oerrno; +} + +/** Discard all buffered characters. On the next scan, YY_INPUT will be called. + * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER. + * @param yyscanner The scanner object. + */ + void core_yy_flush_buffer (YY_BUFFER_STATE b , yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + if ( ! b ) + return; + + b->yy_n_chars = 0; + + /* We always need two end-of-buffer characters. The first causes + * a transition to the end-of-buffer state. The second causes + * a jam in that state. + */ + b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR; + b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR; + + b->yy_buf_pos = &b->yy_ch_buf[0]; + + b->yy_at_bol = 1; + b->yy_buffer_status = YY_BUFFER_NEW; + + if ( b == YY_CURRENT_BUFFER ) + core_yy_load_buffer_state(yyscanner ); +} + +/** Pushes the new state onto the stack. The new state becomes + * the current state. This function will allocate the stack + * if necessary. + * @param new_buffer The new state. + * @param yyscanner The scanner object. + */ +void core_yypush_buffer_state (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + if (new_buffer == NULL) + return; + + core_yyensure_buffer_stack(yyscanner); + + /* This block is copied from core_yy_switch_to_buffer. */ + if ( YY_CURRENT_BUFFER ) + { + /* Flush out information for old buffer. */ + *yyg->yy_c_buf_p = yyg->yy_hold_char; + YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = yyg->yy_c_buf_p; + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars; + } + + /* Only push if top exists. Otherwise, replace top. */ + if (YY_CURRENT_BUFFER) + yyg->yy_buffer_stack_top++; + YY_CURRENT_BUFFER_LVALUE = new_buffer; + + /* copied from core_yy_switch_to_buffer. */ + core_yy_load_buffer_state(yyscanner ); + yyg->yy_did_buffer_switch_on_eof = 1; +} + +/** Removes and deletes the top of the stack, if present. + * The next element becomes the new top. + * @param yyscanner The scanner object. + */ +void core_yypop_buffer_state (yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + if (!YY_CURRENT_BUFFER) + return; + + core_yy_delete_buffer(YY_CURRENT_BUFFER ,yyscanner); + YY_CURRENT_BUFFER_LVALUE = NULL; + if (yyg->yy_buffer_stack_top > 0) + --yyg->yy_buffer_stack_top; + + if (YY_CURRENT_BUFFER) { + core_yy_load_buffer_state(yyscanner ); + yyg->yy_did_buffer_switch_on_eof = 1; + } +} + +/* Allocates the stack if it does not exist. + * Guarantees space for at least one push. + */ +static void core_yyensure_buffer_stack (yyscan_t yyscanner) +{ + int num_to_alloc; + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + + if (!yyg->yy_buffer_stack) { + + /* First allocation is just for 2 elements, since we don't know if this + * scanner will even need a stack. We use 2 instead of 1 to avoid an + * immediate realloc on the next call. + */ + num_to_alloc = 1; + yyg->yy_buffer_stack = (struct yy_buffer_state**)core_yyalloc + (num_to_alloc * sizeof(struct yy_buffer_state*) + , yyscanner); + if ( ! yyg->yy_buffer_stack ) + YY_FATAL_ERROR( "out of dynamic memory in core_yyensure_buffer_stack()" ); + + memset(yyg->yy_buffer_stack, 0, num_to_alloc * sizeof(struct yy_buffer_state*)); + + yyg->yy_buffer_stack_max = num_to_alloc; + yyg->yy_buffer_stack_top = 0; + return; + } + + if (yyg->yy_buffer_stack_top >= (yyg->yy_buffer_stack_max) - 1){ + + /* Increase the buffer to prepare for a possible push. */ + int grow_size = 8 /* arbitrary grow size */; + + num_to_alloc = yyg->yy_buffer_stack_max + grow_size; + yyg->yy_buffer_stack = (struct yy_buffer_state**)core_yyrealloc + (yyg->yy_buffer_stack, + num_to_alloc * sizeof(struct yy_buffer_state*) + , yyscanner); + if ( ! yyg->yy_buffer_stack ) + YY_FATAL_ERROR( "out of dynamic memory in core_yyensure_buffer_stack()" ); + + /* zero only the new slots.*/ + memset(yyg->yy_buffer_stack + yyg->yy_buffer_stack_max, 0, grow_size * sizeof(struct yy_buffer_state*)); + yyg->yy_buffer_stack_max = num_to_alloc; + } +} + +/** Setup the input buffer state to scan directly from a user-specified character buffer. + * @param base the character buffer + * @param size the size in bytes of the character buffer + * @param yyscanner The scanner object. + * @return the newly allocated buffer state object. + */ +YY_BUFFER_STATE core_yy_scan_buffer (char * base, yy_size_t size , yyscan_t yyscanner) +{ + YY_BUFFER_STATE b; + + if ( size < 2 || + base[size-2] != YY_END_OF_BUFFER_CHAR || + base[size-1] != YY_END_OF_BUFFER_CHAR ) + /* They forgot to leave room for the EOB's. */ + return 0; + + b = (YY_BUFFER_STATE) core_yyalloc(sizeof( struct yy_buffer_state ) ,yyscanner ); + if ( ! b ) + YY_FATAL_ERROR( "out of dynamic memory in core_yy_scan_buffer()" ); + + b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */ + b->yy_buf_pos = b->yy_ch_buf = base; + b->yy_is_our_buffer = 0; + b->yy_input_file = 0; + b->yy_n_chars = b->yy_buf_size; + b->yy_is_interactive = 0; + b->yy_at_bol = 1; + b->yy_fill_buffer = 0; + b->yy_buffer_status = YY_BUFFER_NEW; + + core_yy_switch_to_buffer(b ,yyscanner ); + + return b; +} + +/** Setup the input buffer state to scan a string. The next call to core_yylex() will + * scan from a @e copy of @a str. + * @param yystr a NUL-terminated string to scan + * @param yyscanner The scanner object. + * @return the newly allocated buffer state object. + * @note If you want to scan bytes that may contain NUL values, then use + * core_yy_scan_bytes() instead. + */ +YY_BUFFER_STATE core_yy_scan_string (yyconst char * yystr , yyscan_t yyscanner) +{ + + return core_yy_scan_bytes(yystr,strlen(yystr) ,yyscanner); +} + +/** Setup the input buffer state to scan the given bytes. The next call to core_yylex() will + * scan from a @e copy of @a bytes. + * @param yybytes the byte buffer to scan + * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes. + * @param yyscanner The scanner object. + * @return the newly allocated buffer state object. + */ +YY_BUFFER_STATE core_yy_scan_bytes (yyconst char * yybytes, int _yybytes_len , yyscan_t yyscanner) +{ + YY_BUFFER_STATE b; + char *buf; + yy_size_t n; + int i; + + /* Get memory for full buffer, including space for trailing EOB's. */ + n = _yybytes_len + 2; + buf = (char *) core_yyalloc(n ,yyscanner ); + if ( ! buf ) + YY_FATAL_ERROR( "out of dynamic memory in core_yy_scan_bytes()" ); + + for ( i = 0; i < _yybytes_len; ++i ) + buf[i] = yybytes[i]; + + buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR; + + b = core_yy_scan_buffer(buf,n ,yyscanner); + if ( ! b ) + YY_FATAL_ERROR( "bad buffer in core_yy_scan_bytes()" ); + + /* It's okay to grow etc. this buffer, and we should throw it + * away when we're done. + */ + b->yy_is_our_buffer = 1; + + return b; +} + +#ifndef YY_EXIT_FAILURE +#define YY_EXIT_FAILURE 2 +#endif + +static void yy_fatal_error (yyconst char* msg , yyscan_t yyscanner) +{ + (void) fprintf( stderr, "%s\n", msg ); + exit( YY_EXIT_FAILURE ); +} + +/* Redefine yyless() so it works in section 3 code. */ + +#undef yyless +#define yyless(n) \ + do \ + { \ + /* Undo effects of setting up yytext. */ \ + int yyless_macro_arg = (n); \ + YY_LESS_LINENO(yyless_macro_arg);\ + yytext[yyleng] = yyg->yy_hold_char; \ + yyg->yy_c_buf_p = yytext + yyless_macro_arg; \ + yyg->yy_hold_char = *yyg->yy_c_buf_p; \ + *yyg->yy_c_buf_p = '\0'; \ + yyleng = yyless_macro_arg; \ + } \ + while ( 0 ) + +/* Accessor methods (get/set functions) to struct members. */ + +/** Get the user-defined data for this scanner. + * @param yyscanner The scanner object. + */ +YY_EXTRA_TYPE core_yyget_extra (yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + return yyextra; +} + +/** Get the current line number. + * @param yyscanner The scanner object. + */ +int core_yyget_lineno (yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + + if (! YY_CURRENT_BUFFER) + return 0; + + return yylineno; +} + +/** Get the current column number. + * @param yyscanner The scanner object. + */ +int core_yyget_column (yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + + if (! YY_CURRENT_BUFFER) + return 0; + + return yycolumn; +} + +/** Get the input stream. + * @param yyscanner The scanner object. + */ +FILE *core_yyget_in (yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + return yyin; +} + +/** Get the output stream. + * @param yyscanner The scanner object. + */ +FILE *core_yyget_out (yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + return yyout; +} + +/** Get the length of the current token. + * @param yyscanner The scanner object. + */ +int core_yyget_leng (yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + return yyleng; +} + +/** Get the current token. + * @param yyscanner The scanner object. + */ + +char *core_yyget_text (yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + return yytext; +} + +/** Set the user-defined data. This data is never touched by the scanner. + * @param user_defined The data to be associated with this scanner. + * @param yyscanner The scanner object. + */ +void core_yyset_extra (YY_EXTRA_TYPE user_defined , yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + yyextra = user_defined ; +} + +/** Set the current line number. + * @param line_number + * @param yyscanner The scanner object. + */ +void core_yyset_lineno (int line_number , yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + + /* lineno is only valid if an input buffer exists. */ + if (! YY_CURRENT_BUFFER ) + yy_fatal_error( "core_yyset_lineno called with no buffer" , yyscanner); + + yylineno = line_number; +} + +/** Set the current column. + * @param line_number + * @param yyscanner The scanner object. + */ +void core_yyset_column (int column_no , yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + + /* column is only valid if an input buffer exists. */ + if (! YY_CURRENT_BUFFER ) + yy_fatal_error( "core_yyset_column called with no buffer" , yyscanner); + + yycolumn = column_no; +} + +/** Set the input stream. This does not discard the current + * input buffer. + * @param in_str A readable stream. + * @param yyscanner The scanner object. + * @see core_yy_switch_to_buffer + */ +void core_yyset_in (FILE * in_str , yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + yyin = in_str ; +} + +void core_yyset_out (FILE * out_str , yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + yyout = out_str ; +} + +int core_yyget_debug (yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + return yy_flex_debug; +} + +void core_yyset_debug (int bdebug , yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + yy_flex_debug = bdebug ; +} + +/* Accessor methods for yylval and yylloc */ + +YYSTYPE * core_yyget_lval (yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + return yylval; +} + +void core_yyset_lval (YYSTYPE * yylval_param , yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + yylval = yylval_param; +} + +YYLTYPE *core_yyget_lloc (yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + return yylloc; +} + +void core_yyset_lloc (YYLTYPE * yylloc_param , yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + yylloc = yylloc_param; +} + +/* User-visible API */ + +/* core_yylex_init is special because it creates the scanner itself, so it is + * the ONLY reentrant function that doesn't take the scanner as the last argument. + * That's why we explicitly handle the declaration, instead of using our macros. + */ + +int core_yylex_init(yyscan_t* ptr_yy_globals) + +{ + if (ptr_yy_globals == NULL){ + errno = EINVAL; + return 1; + } + + *ptr_yy_globals = (yyscan_t) core_yyalloc ( sizeof( struct yyguts_t ), NULL ); + + if (*ptr_yy_globals == NULL){ + errno = ENOMEM; + return 1; + } + + /* By setting to 0xAA, we expose bugs in yy_init_globals. Leave at 0x00 for releases. */ + memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t)); + + return yy_init_globals ( *ptr_yy_globals ); +} + +/* core_yylex_init_extra has the same functionality as core_yylex_init, but follows the + * convention of taking the scanner as the last argument. Note however, that + * this is a *pointer* to a scanner, as it will be allocated by this call (and + * is the reason, too, why this function also must handle its own declaration). + * The user defined value in the first argument will be available to core_yyalloc in + * the yyextra field. + */ + +int core_yylex_init_extra(YY_EXTRA_TYPE yy_user_defined,yyscan_t* ptr_yy_globals ) + +{ + struct yyguts_t dummy_yyguts; + + core_yyset_extra (yy_user_defined, &dummy_yyguts); + + if (ptr_yy_globals == NULL){ + errno = EINVAL; + return 1; + } + + *ptr_yy_globals = (yyscan_t) core_yyalloc ( sizeof( struct yyguts_t ), &dummy_yyguts ); + + if (*ptr_yy_globals == NULL){ + errno = ENOMEM; + return 1; + } + + /* By setting to 0xAA, we expose bugs in + yy_init_globals. Leave at 0x00 for releases. */ + memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t)); + + core_yyset_extra (yy_user_defined, *ptr_yy_globals); + + return yy_init_globals ( *ptr_yy_globals ); +} + +static int yy_init_globals (yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + /* Initialization is the same as for the non-reentrant scanner. + * This function is called from core_yylex_destroy(), so don't allocate here. + */ + + yyg->yy_buffer_stack = 0; + yyg->yy_buffer_stack_top = 0; + yyg->yy_buffer_stack_max = 0; + yyg->yy_c_buf_p = (char *) 0; + yyg->yy_init = 0; + yyg->yy_start = 0; + + yyg->yy_start_stack_ptr = 0; + yyg->yy_start_stack_depth = 0; + yyg->yy_start_stack = NULL; + +/* Defined in main.c */ +#ifdef YY_STDINIT + yyin = stdin; + yyout = stdout; +#else + yyin = (FILE *) 0; + yyout = (FILE *) 0; +#endif + + /* For future reference: Set errno on error, since we are called by + * core_yylex_init() + */ + return 0; +} + +/* core_yylex_destroy is for both reentrant and non-reentrant scanners. */ +int core_yylex_destroy (yyscan_t yyscanner) +{ + struct yyguts_t * yyg = (struct yyguts_t*)yyscanner; + + /* Pop the buffer stack, destroying each element. */ + while(YY_CURRENT_BUFFER){ + core_yy_delete_buffer(YY_CURRENT_BUFFER ,yyscanner ); + YY_CURRENT_BUFFER_LVALUE = NULL; + core_yypop_buffer_state(yyscanner); + } + + /* Destroy the stack itself. */ + core_yyfree(yyg->yy_buffer_stack ,yyscanner); + yyg->yy_buffer_stack = NULL; + + /* Destroy the start condition stack. */ + core_yyfree(yyg->yy_start_stack ,yyscanner ); + yyg->yy_start_stack = NULL; + + /* Reset the globals. This is important in a non-reentrant scanner so the next time + * core_yylex() is called, initialization will occur. */ + yy_init_globals( yyscanner); + + /* Destroy the main struct (reentrant only). */ + core_yyfree ( yyscanner , yyscanner ); + yyscanner = NULL; + return 0; +} + +/* + * Internal utility routines. + */ + +#ifndef yytext_ptr +static void yy_flex_strncpy (char* s1, yyconst char * s2, int n , yyscan_t yyscanner) +{ + register int i; + for ( i = 0; i < n; ++i ) + s1[i] = s2[i]; +} +#endif + +#ifdef YY_NEED_STRLEN +static int yy_flex_strlen (yyconst char * s , yyscan_t yyscanner) +{ + register int n; + for ( n = 0; s[n]; ++n ) + ; + + return n; +} +#endif + +#define YYTABLES_NAME "yytables" + +#line 927 "scan.l" + + + +/* + * Arrange access to yyextra for subroutines of the main core_yylex() function. + * We expect each subroutine to have a yyscanner parameter. Rather than + * use the yyget_xxx functions, which might or might not get inlined by the + * compiler, we cheat just a bit and cast yyscanner to the right type. + */ +#undef yyextra +#define yyextra (((struct yyguts_t *) yyscanner)->yyextra_r) + +/* Likewise for a couple of other things we need. */ +#undef yylloc +#define yylloc (((struct yyguts_t *) yyscanner)->yylloc_r) +#undef yyleng +#define yyleng (((struct yyguts_t *) yyscanner)->yyleng_r) + + +/* + * scanner_errposition + * Report a lexer or grammar error cursor position, if possible. + * + * This is expected to be used within an ereport() call. The return value + * is a dummy (always 0, in fact). + * + * Note that this can only be used for messages emitted during raw parsing + * (essentially, scan.l and gram.y), since it requires the yyscanner struct + * to still be available. + */ +int +scanner_errposition(int location, core_yyscan_t yyscanner) +{ + int pos; + + if (location < 0) + return 0; /* no-op if location is unknown */ + + /* Convert byte offset to character number */ + pos = pg_mbstrlen_with_len(yyextra->scanbuf, location) + 1; + /* And pass it to the ereport mechanism */ + return errposition(pos); +} + +/* + * scanner_yyerror + * Report a lexer or grammar error. + * + * The message's cursor position is whatever YYLLOC was last set to, + * ie, the start of the current token if called within core_yylex(), or the + * most recently lexed token if called from the grammar. + * This is OK for syntax error messages from the Bison parser, because Bison + * parsers report error as soon as the first unparsable token is reached. + * Beware of using yyerror for other purposes, as the cursor position might + * be misleading! + */ +void +scanner_yyerror(const char *message, core_yyscan_t yyscanner) +{ + const char *loc = yyextra->scanbuf + *yylloc; + + if (*loc == YY_END_OF_BUFFER_CHAR) + { + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + /* translator: %s is typically the translation of "syntax error" */ + errmsg("%s at end of input", _(message)), + lexer_errposition())); + } + else + { + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + /* translator: first %s is typically the translation of "syntax error" */ + errmsg("%s at or near \"%s\"", _(message), loc), + lexer_errposition())); + } +} + + +/* + * Called before any actual parsing is done + */ +core_yyscan_t +scanner_init(const char *str, + core_yy_extra_type *yyext, + const ScanKeyword *keywords, + int num_keywords) +{ + Size slen = strlen(str); + yyscan_t scanner; + + if (core_yylex_init(&scanner) != 0) + elog(ERROR, "core_yylex_init() failed: %m"); + + core_yyset_extra(yyext, scanner); + + yyext->keywords = keywords; + yyext->num_keywords = num_keywords; + + /* + * Make a scan buffer with special termination needed by flex. + */ + yyext->scanbuf = (char *) palloc(slen + 2); + yyext->scanbuflen = slen; + memcpy(yyext->scanbuf, str, slen); + yyext->scanbuf[slen] = yyext->scanbuf[slen + 1] = YY_END_OF_BUFFER_CHAR; + core_yy_scan_buffer(yyext->scanbuf,slen + 2,scanner); + + /* initialize literal buffer to a reasonable but expansible size */ + yyext->literalalloc = 1024; + yyext->literalbuf = (char *) palloc(yyext->literalalloc); + yyext->literallen = 0; + + return scanner; +} + + +/* + * Called after parsing is done to clean up after scanner_init() + */ +void +scanner_finish(core_yyscan_t yyscanner) +{ + /* + * We don't bother to call core_yylex_destroy(), because all it would do + * is pfree a small amount of control storage. It's cheaper to leak + * the storage until the parsing context is destroyed. The amount of + * space involved is usually negligible compared to the output parse + * tree anyway. + * + * We do bother to pfree the scanbuf and literal buffer, but only if they + * represent a nontrivial amount of space. The 8K cutoff is arbitrary. + */ + if (yyextra->scanbuflen >= 8192) + pfree(yyextra->scanbuf); + if (yyextra->literalalloc >= 8192) + pfree(yyextra->literalbuf); +} + + +static void +addlit(char *ytext, int yleng, core_yyscan_t yyscanner) +{ + /* enlarge buffer if needed */ + if ((yyextra->literallen + yleng) >= yyextra->literalalloc) + { + do { + yyextra->literalalloc *= 2; + } while ((yyextra->literallen + yleng) >= yyextra->literalalloc); + yyextra->literalbuf = (char *) repalloc(yyextra->literalbuf, + yyextra->literalalloc); + } + /* append new data */ + memcpy(yyextra->literalbuf + yyextra->literallen, ytext, yleng); + yyextra->literallen += yleng; +} + + +static void +addlitchar(unsigned char ychar, core_yyscan_t yyscanner) +{ + /* enlarge buffer if needed */ + if ((yyextra->literallen + 1) >= yyextra->literalalloc) + { + yyextra->literalalloc *= 2; + yyextra->literalbuf = (char *) repalloc(yyextra->literalbuf, + yyextra->literalalloc); + } + /* append new data */ + yyextra->literalbuf[yyextra->literallen] = ychar; + yyextra->literallen += 1; +} + + +/* + * Create a palloc'd copy of literalbuf, adding a trailing null. + */ +static char * +litbufdup(core_yyscan_t yyscanner) +{ + int llen = yyextra->literallen; + char *new; + + new = palloc(llen + 1); + memcpy(new, yyextra->literalbuf, llen); + new[llen] = '\0'; + return new; +} + +static int +process_integer_literal(const char *token, YYSTYPE *lval) +{ + long val; + char *endptr; + + errno = 0; + val = strtol(token, &endptr, 10); + if (*endptr != '\0' || errno == ERANGE +#ifdef HAVE_LONG_INT_64 + /* if long > 32 bits, check for overflow of int4 */ + || val != (long) ((int32) val) +#endif + ) + { + /* integer too large, treat it as a float */ + lval->str = pstrdup(token); + return FCONST; + } + lval->ival = val; + return ICONST; +} + +static unsigned int +hexval(unsigned char c) +{ + if (c >= '0' && c <= '9') + return c - '0'; + if (c >= 'a' && c <= 'f') + return c - 'a' + 0xA; + if (c >= 'A' && c <= 'F') + return c - 'A' + 0xA; + elog(ERROR, "invalid hexadecimal digit"); + return 0; /* not reached */ +} + +static void +check_unicode_value(pg_wchar c, char *loc, core_yyscan_t yyscanner) +{ + if (GetDatabaseEncoding() == PG_UTF8) + return; + + if (c > 0x7F) + { + ADVANCE_YYLLOC(loc - yyextra->literalbuf + 3); /* 3 for U&" */ + yyerror("Unicode escape values cannot be used for code point values above 007F when the server encoding is not UTF8"); + } +} + +static bool +is_utf16_surrogate_first(pg_wchar c) +{ + return (c >= 0xD800 && c <= 0xDBFF); +} + +static bool +is_utf16_surrogate_second(pg_wchar c) +{ + return (c >= 0xDC00 && c <= 0xDFFF); +} + +static pg_wchar +surrogate_pair_to_codepoint(pg_wchar first, pg_wchar second) +{ + return ((first & 0x3FF) << 10) + 0x10000 + (second & 0x3FF); +} + +static void +addunicode(pg_wchar c, core_yyscan_t yyscanner) +{ + char buf[8]; + + if (c == 0 || c > 0x10FFFF) + yyerror("invalid Unicode escape value"); + if (c > 0x7F) + { + if (GetDatabaseEncoding() != PG_UTF8) + yyerror("Unicode escape values cannot be used for code point values above 007F when the server encoding is not UTF8"); + yyextra->saw_non_ascii = true; + } + unicode_to_utf8(c, (unsigned char *) buf); + addlit(buf, pg_mblen(buf), yyscanner); +} + +static char * +litbuf_udeescape(unsigned char escape, core_yyscan_t yyscanner) +{ + char *new; + char *litbuf, *in, *out; + pg_wchar pair_first = 0; + + if (isxdigit(escape) + || escape == '+' + || escape == '\'' + || escape == '"' + || scanner_isspace(escape)) + { + ADVANCE_YYLLOC(yyextra->literallen + yyleng + 1); + yyerror("invalid Unicode escape character"); + } + + /* Make literalbuf null-terminated to simplify the scanning loop */ + litbuf = yyextra->literalbuf; + litbuf[yyextra->literallen] = '\0'; + + /* + * This relies on the subtle assumption that a UTF-8 expansion + * cannot be longer than its escaped representation. + */ + new = palloc(yyextra->literallen + 1); + + in = litbuf; + out = new; + while (*in) + { + if (in[0] == escape) + { + if (in[1] == escape) + { + if (pair_first) + { + ADVANCE_YYLLOC(in - litbuf + 3); /* 3 for U&" */ + yyerror("invalid Unicode surrogate pair"); + } + *out++ = escape; + in += 2; + } + else if (isxdigit((unsigned char) in[1]) && + isxdigit((unsigned char) in[2]) && + isxdigit((unsigned char) in[3]) && + isxdigit((unsigned char) in[4])) + { + pg_wchar unicode; + + unicode = (hexval(in[1]) << 12) + + (hexval(in[2]) << 8) + + (hexval(in[3]) << 4) + + hexval(in[4]); + check_unicode_value(unicode, in, yyscanner); + if (pair_first) + { + if (is_utf16_surrogate_second(unicode)) + { + unicode = surrogate_pair_to_codepoint(pair_first, unicode); + pair_first = 0; + } + else + { + ADVANCE_YYLLOC(in - litbuf + 3); /* 3 for U&" */ + yyerror("invalid Unicode surrogate pair"); + } + } + else if (is_utf16_surrogate_second(unicode)) + yyerror("invalid Unicode surrogate pair"); + + if (is_utf16_surrogate_first(unicode)) + pair_first = unicode; + else + { + unicode_to_utf8(unicode, (unsigned char *) out); + out += pg_mblen(out); + } + in += 5; + } + else if (in[1] == '+' && + isxdigit((unsigned char) in[2]) && + isxdigit((unsigned char) in[3]) && + isxdigit((unsigned char) in[4]) && + isxdigit((unsigned char) in[5]) && + isxdigit((unsigned char) in[6]) && + isxdigit((unsigned char) in[7])) + { + pg_wchar unicode; + + unicode = (hexval(in[2]) << 20) + + (hexval(in[3]) << 16) + + (hexval(in[4]) << 12) + + (hexval(in[5]) << 8) + + (hexval(in[6]) << 4) + + hexval(in[7]); + check_unicode_value(unicode, in, yyscanner); + if (pair_first) + { + if (is_utf16_surrogate_second(unicode)) + { + unicode = surrogate_pair_to_codepoint(pair_first, unicode); + pair_first = 0; + } + else + { + ADVANCE_YYLLOC(in - litbuf + 3); /* 3 for U&" */ + yyerror("invalid Unicode surrogate pair"); + } + } + else if (is_utf16_surrogate_second(unicode)) + yyerror("invalid Unicode surrogate pair"); + + if (is_utf16_surrogate_first(unicode)) + pair_first = unicode; + else + { + unicode_to_utf8(unicode, (unsigned char *) out); + out += pg_mblen(out); + } + in += 8; + } + else + { + ADVANCE_YYLLOC(in - litbuf + 3); /* 3 for U&" */ + yyerror("invalid Unicode escape value"); + } + } + else + { + if (pair_first) + { + ADVANCE_YYLLOC(in - litbuf + 3); /* 3 for U&" */ + yyerror("invalid Unicode surrogate pair"); + } + *out++ = *in++; + } + } + + *out = '\0'; + /* + * We could skip pg_verifymbstr if we didn't process any non-7-bit-ASCII + * codes; but it's probably not worth the trouble, since this isn't + * likely to be a performance-critical path. + */ + pg_verifymbstr(new, out - new, false); + return new; +} + +static unsigned char +unescape_single_char(unsigned char c, core_yyscan_t yyscanner) +{ + switch (c) + { + case 'b': + return '\b'; + case 'f': + return '\f'; + case 'n': + return '\n'; + case 'r': + return '\r'; + case 't': + return '\t'; + default: + /* check for backslash followed by non-7-bit-ASCII */ + if (c == '\0' || IS_HIGHBIT_SET(c)) + yyextra->saw_non_ascii = true; + + return c; + } +} + +static void +check_string_escape_warning(unsigned char ychar, core_yyscan_t yyscanner) +{ + if (ychar == '\'') + { + if (yyextra->warn_on_first_escape && escape_string_warning) + ereport(WARNING, + (errcode(ERRCODE_NONSTANDARD_USE_OF_ESCAPE_CHARACTER), + errmsg("nonstandard use of \\' in a string literal"), + errhint("Use '' to write quotes in strings, or use the escape string syntax (E'...')."), + lexer_errposition())); + yyextra->warn_on_first_escape = false; /* warn only once per string */ + } + else if (ychar == '\\') + { + if (yyextra->warn_on_first_escape && escape_string_warning) + ereport(WARNING, + (errcode(ERRCODE_NONSTANDARD_USE_OF_ESCAPE_CHARACTER), + errmsg("nonstandard use of \\\\ in a string literal"), + errhint("Use the escape string syntax for backslashes, e.g., E'\\\\'."), + lexer_errposition())); + yyextra->warn_on_first_escape = false; /* warn only once per string */ + } + else + check_escape_warning(yyscanner); +} + +static void +check_escape_warning(core_yyscan_t yyscanner) +{ + if (yyextra->warn_on_first_escape && escape_string_warning) + ereport(WARNING, + (errcode(ERRCODE_NONSTANDARD_USE_OF_ESCAPE_CHARACTER), + errmsg("nonstandard use of escape in a string literal"), + errhint("Use the escape string syntax for escapes, e.g., E'\\r\\n'."), + lexer_errposition())); + yyextra->warn_on_first_escape = false; /* warn only once per string */ +} + +/* + * Interface functions to make flex use palloc() instead of malloc(). + * It'd be better to make these static, but flex insists otherwise. + */ + +void * +core_yyalloc(yy_size_t bytes, core_yyscan_t yyscanner) +{ + return palloc(bytes); +} + +void * +core_yyrealloc(void *ptr, yy_size_t bytes, core_yyscan_t yyscanner) +{ + if (ptr) + return repalloc(ptr, bytes); + else + return palloc(bytes); +} + +void +core_yyfree(void *ptr, core_yyscan_t yyscanner) +{ + if (ptr) + pfree(ptr); +} + diff --git a/src/backend/port/.gitignore b/src/backend/port/.gitignore deleted file mode 100644 index 7d3ac4ab4..000000000 --- a/src/backend/port/.gitignore +++ /dev/null @@ -1,5 +0,0 @@ -/dynloader.c -/pg_latch.c -/pg_sema.c -/pg_shmem.c -/tas.s diff --git a/src/backend/replication/.gitignore b/src/backend/replication/.gitignore deleted file mode 100644 index a0332b230..000000000 --- a/src/backend/replication/.gitignore +++ /dev/null @@ -1,3 +0,0 @@ -/repl_gram.c -/repl_gram.h -/repl_scanner.c diff --git a/src/backend/replication/repl_gram.c b/src/backend/replication/repl_gram.c new file mode 100644 index 000000000..e4e09157e --- /dev/null +++ b/src/backend/replication/repl_gram.c @@ -0,0 +1,1725 @@ + +/* A Bison parser, made by GNU Bison 2.4.1. */ + +/* Skeleton implementation for Bison's Yacc-like parsers in C + + Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 + Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . */ + +/* As a special exception, you may create a larger work that contains + part or all of the Bison parser skeleton and distribute that work + under terms of your choice, so long as that work isn't itself a + parser generator using the skeleton or a modified version thereof + as a parser skeleton. Alternatively, if you modify or redistribute + the parser skeleton itself, you may (at your option) remove this + special exception, which will cause the skeleton and the resulting + Bison output files to be licensed under the GNU General Public + License without this special exception. + + This special exception was added by the Free Software Foundation in + version 2.2 of Bison. */ + +/* C LALR(1) parser skeleton written by Richard Stallman, by + simplifying the original so-called "semantic" parser. */ + +/* All symbols defined below should begin with yy or YY, to avoid + infringing on user name space. This should be done even for local + variables, as they might otherwise be expanded by user macros. + There are some unavoidable exceptions within include files to + define necessary library symbols; they are noted "INFRINGES ON + USER NAME SPACE" below. */ + +/* Identify Bison output. */ +#define YYBISON 1 + +/* Bison version. */ +#define YYBISON_VERSION "2.4.1" + +/* Skeleton name. */ +#define YYSKELETON_NAME "yacc.c" + +/* Pure parsers. */ +#define YYPURE 0 + +/* Push parsers. */ +#define YYPUSH 0 + +/* Pull parsers. */ +#define YYPULL 1 + +/* Using locations. */ +#define YYLSP_NEEDED 0 + +/* Substitute the variable and function names. */ +#define yyparse replication_yyparse +#define yylex replication_yylex +#define yyerror replication_yyerror +#define yylval replication_yylval +#define yychar replication_yychar +#define yydebug replication_yydebug +#define yynerrs replication_yynerrs + + +/* Copy the first part of user declarations. */ + +/* Line 189 of yacc.c */ +#line 1 "repl_gram.y" + +/*------------------------------------------------------------------------- + * + * repl_gram.y - Parser for the replication commands + * + * Portions Copyright (c) 1996-2012, PostgreSQL Global Development Group + * Portions Copyright (c) 1994, Regents of the University of California + * + * + * IDENTIFICATION + * src/backend/replication/repl_gram.y + * + *------------------------------------------------------------------------- + */ + +#include "postgres.h" + +#include "access/xlogdefs.h" +#include "nodes/makefuncs.h" +#include "nodes/replnodes.h" +#include "replication/walsender.h" +#include "replication/walsender_private.h" + + +/* Result of the parsing is returned here */ +Node *replication_parse_result; + +/* Location tracking support --- simpler than bison's default */ +#define YYLLOC_DEFAULT(Current, Rhs, N) \ + do { \ + if (N) \ + (Current) = (Rhs)[1]; \ + else \ + (Current) = (Rhs)[0]; \ + } while (0) + +/* + * Bison doesn't allocate anything that needs to live across parser calls, + * so we can easily have it use palloc instead of malloc. This prevents + * memory leaks if we error out during parsing. Note this only works with + * bison >= 2.0. However, in bison 1.875 the default is to use alloca() + * if possible, so there's not really much problem anyhow, at least if + * you're building with gcc. + */ +#define YYMALLOC palloc +#define YYFREE pfree + +#define parser_yyerror(msg) replication_yyerror(msg, yyscanner) +#define parser_errposition(pos) replication_scanner_errposition(pos) + + + +/* Line 189 of yacc.c */ +#line 134 "repl_gram.c" + +/* Enabling traces. */ +#ifndef YYDEBUG +# define YYDEBUG 0 +#endif + +/* Enabling verbose error messages. */ +#ifdef YYERROR_VERBOSE +# undef YYERROR_VERBOSE +# define YYERROR_VERBOSE 1 +#else +# define YYERROR_VERBOSE 0 +#endif + +/* Enabling the token table. */ +#ifndef YYTOKEN_TABLE +# define YYTOKEN_TABLE 0 +#endif + + +/* Tokens. */ +#ifndef YYTOKENTYPE +# define YYTOKENTYPE + /* Put the tokens into the symbol table, so that GDB and other debuggers + know about them. */ + enum yytokentype { + SCONST = 258, + RECPTR = 259, + K_BASE_BACKUP = 260, + K_IDENTIFY_SYSTEM = 261, + K_LABEL = 262, + K_PROGRESS = 263, + K_FAST = 264, + K_NOWAIT = 265, + K_WAL = 266, + K_START_REPLICATION = 267 + }; +#endif + + + +#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED +typedef union YYSTYPE +{ + +/* Line 214 of yacc.c */ +#line 56 "repl_gram.y" + + char *str; + bool boolval; + + XLogRecPtr recptr; + Node *node; + List *list; + DefElem *defelt; + + + +/* Line 214 of yacc.c */ +#line 194 "repl_gram.c" +} YYSTYPE; +# define YYSTYPE_IS_TRIVIAL 1 +# define yystype YYSTYPE /* obsolescent; will be withdrawn */ +# define YYSTYPE_IS_DECLARED 1 +#endif + + +/* Copy the second part of user declarations. */ + + +/* Line 264 of yacc.c */ +#line 206 "repl_gram.c" + +#ifdef short +# undef short +#endif + +#ifdef YYTYPE_UINT8 +typedef YYTYPE_UINT8 yytype_uint8; +#else +typedef unsigned char yytype_uint8; +#endif + +#ifdef YYTYPE_INT8 +typedef YYTYPE_INT8 yytype_int8; +#elif (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +typedef signed char yytype_int8; +#else +typedef short int yytype_int8; +#endif + +#ifdef YYTYPE_UINT16 +typedef YYTYPE_UINT16 yytype_uint16; +#else +typedef unsigned short int yytype_uint16; +#endif + +#ifdef YYTYPE_INT16 +typedef YYTYPE_INT16 yytype_int16; +#else +typedef short int yytype_int16; +#endif + +#ifndef YYSIZE_T +# ifdef __SIZE_TYPE__ +# define YYSIZE_T __SIZE_TYPE__ +# elif defined size_t +# define YYSIZE_T size_t +# elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +# include /* INFRINGES ON USER NAME SPACE */ +# define YYSIZE_T size_t +# else +# define YYSIZE_T unsigned int +# endif +#endif + +#define YYSIZE_MAXIMUM ((YYSIZE_T) -1) + +#ifndef YY_ +# if YYENABLE_NLS +# if ENABLE_NLS +# include /* INFRINGES ON USER NAME SPACE */ +# define YY_(msgid) dgettext ("bison-runtime", msgid) +# endif +# endif +# ifndef YY_ +# define YY_(msgid) msgid +# endif +#endif + +/* Suppress unused-variable warnings by "using" E. */ +#if ! defined lint || defined __GNUC__ +# define YYUSE(e) ((void) (e)) +#else +# define YYUSE(e) /* empty */ +#endif + +/* Identity function, used to suppress warnings about constant conditions. */ +#ifndef lint +# define YYID(n) (n) +#else +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static int +YYID (int yyi) +#else +static int +YYID (yyi) + int yyi; +#endif +{ + return yyi; +} +#endif + +#if ! defined yyoverflow || YYERROR_VERBOSE + +/* The parser invokes alloca or malloc; define the necessary symbols. */ + +# ifdef YYSTACK_USE_ALLOCA +# if YYSTACK_USE_ALLOCA +# ifdef __GNUC__ +# define YYSTACK_ALLOC __builtin_alloca +# elif defined __BUILTIN_VA_ARG_INCR +# include /* INFRINGES ON USER NAME SPACE */ +# elif defined _AIX +# define YYSTACK_ALLOC __alloca +# elif defined _MSC_VER +# include /* INFRINGES ON USER NAME SPACE */ +# define alloca _alloca +# else +# define YYSTACK_ALLOC alloca +# if ! defined _ALLOCA_H && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +# include /* INFRINGES ON USER NAME SPACE */ +# ifndef _STDLIB_H +# define _STDLIB_H 1 +# endif +# endif +# endif +# endif +# endif + +# ifdef YYSTACK_ALLOC + /* Pacify GCC's `empty if-body' warning. */ +# define YYSTACK_FREE(Ptr) do { /* empty */; } while (YYID (0)) +# ifndef YYSTACK_ALLOC_MAXIMUM + /* The OS might guarantee only one guard page at the bottom of the stack, + and a page size can be as small as 4096 bytes. So we cannot safely + invoke alloca (N) if N exceeds 4096. Use a slightly smaller number + to allow for a few compiler-allocated temporary stack slots. */ +# define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */ +# endif +# else +# define YYSTACK_ALLOC YYMALLOC +# define YYSTACK_FREE YYFREE +# ifndef YYSTACK_ALLOC_MAXIMUM +# define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM +# endif +# if (defined __cplusplus && ! defined _STDLIB_H \ + && ! ((defined YYMALLOC || defined malloc) \ + && (defined YYFREE || defined free))) +# include /* INFRINGES ON USER NAME SPACE */ +# ifndef _STDLIB_H +# define _STDLIB_H 1 +# endif +# endif +# ifndef YYMALLOC +# define YYMALLOC malloc +# if ! defined malloc && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */ +# endif +# endif +# ifndef YYFREE +# define YYFREE free +# if ! defined free && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +void free (void *); /* INFRINGES ON USER NAME SPACE */ +# endif +# endif +# endif +#endif /* ! defined yyoverflow || YYERROR_VERBOSE */ + + +#if (! defined yyoverflow \ + && (! defined __cplusplus \ + || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) + +/* A type that is properly aligned for any stack member. */ +union yyalloc +{ + yytype_int16 yyss_alloc; + YYSTYPE yyvs_alloc; +}; + +/* The size of the maximum gap between one aligned stack and the next. */ +# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1) + +/* The size of an array large to enough to hold all stacks, each with + N elements. */ +# define YYSTACK_BYTES(N) \ + ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \ + + YYSTACK_GAP_MAXIMUM) + +/* Copy COUNT objects from FROM to TO. The source and destination do + not overlap. */ +# ifndef YYCOPY +# if defined __GNUC__ && 1 < __GNUC__ +# define YYCOPY(To, From, Count) \ + __builtin_memcpy (To, From, (Count) * sizeof (*(From))) +# else +# define YYCOPY(To, From, Count) \ + do \ + { \ + YYSIZE_T yyi; \ + for (yyi = 0; yyi < (Count); yyi++) \ + (To)[yyi] = (From)[yyi]; \ + } \ + while (YYID (0)) +# endif +# endif + +/* Relocate STACK from its old location to the new one. The + local variables YYSIZE and YYSTACKSIZE give the old and new number of + elements in the stack, and YYPTR gives the new location of the + stack. Advance YYPTR to a properly aligned location for the next + stack. */ +# define YYSTACK_RELOCATE(Stack_alloc, Stack) \ + do \ + { \ + YYSIZE_T yynewbytes; \ + YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \ + Stack = &yyptr->Stack_alloc; \ + yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ + yyptr += yynewbytes / sizeof (*yyptr); \ + } \ + while (YYID (0)) + +#endif + +/* YYFINAL -- State number of the termination state. */ +#define YYFINAL 11 +/* YYLAST -- Last index in YYTABLE. */ +#define YYLAST 12 + +/* YYNTOKENS -- Number of terminals. */ +#define YYNTOKENS 14 +/* YYNNTS -- Number of nonterminals. */ +#define YYNNTS 9 +/* YYNRULES -- Number of rules. */ +#define YYNRULES 17 +/* YYNRULES -- Number of states. */ +#define YYNSTATES 21 + +/* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */ +#define YYUNDEFTOK 2 +#define YYMAXUTOK 267 + +#define YYTRANSLATE(YYX) \ + ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) + +/* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */ +static const yytype_uint8 yytranslate[] = +{ + 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 13, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 1, 2, 3, 4, + 5, 6, 7, 8, 9, 10, 11, 12 +}; + +#if YYDEBUG +/* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in + YYRHS. */ +static const yytype_uint8 yyprhs[] = +{ + 0, 0, 3, 6, 8, 9, 11, 13, 15, 17, + 20, 23, 24, 27, 29, 31, 33, 35 +}; + +/* YYRHS -- A `-1'-separated list of the rules' RHS. */ +static const yytype_int8 yyrhs[] = +{ + 15, 0, -1, 17, 16, -1, 13, -1, -1, 18, + -1, 19, -1, 22, -1, 6, -1, 5, 20, -1, + 20, 21, -1, -1, 7, 3, -1, 8, -1, 9, + -1, 11, -1, 10, -1, 12, 4, -1 +}; + +/* YYRLINE[YYN] -- source line where rule number YYN was defined. */ +static const yytype_uint8 yyrline[] = +{ + 0, 86, 86, 92, 93, 97, 98, 99, 106, 116, + 124, 125, 128, 133, 138, 143, 148, 159 +}; +#endif + +#if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE +/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM. + First, the terminals, then, starting at YYNTOKENS, nonterminals. */ +static const char *const yytname[] = +{ + "$end", "error", "$undefined", "SCONST", "RECPTR", "K_BASE_BACKUP", + "K_IDENTIFY_SYSTEM", "K_LABEL", "K_PROGRESS", "K_FAST", "K_NOWAIT", + "K_WAL", "K_START_REPLICATION", "';'", "$accept", "firstcmd", + "opt_semicolon", "command", "identify_system", "base_backup", + "base_backup_opt_list", "base_backup_opt", "start_replication", 0 +}; +#endif + +# ifdef YYPRINT +/* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to + token YYLEX-NUM. */ +static const yytype_uint16 yytoknum[] = +{ + 0, 256, 257, 258, 259, 260, 261, 262, 263, 264, + 265, 266, 267, 59 +}; +# endif + +/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ +static const yytype_uint8 yyr1[] = +{ + 0, 14, 15, 16, 16, 17, 17, 17, 18, 19, + 20, 20, 21, 21, 21, 21, 21, 22 +}; + +/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */ +static const yytype_uint8 yyr2[] = +{ + 0, 2, 2, 1, 0, 1, 1, 1, 1, 2, + 2, 0, 2, 1, 1, 1, 1, 2 +}; + +/* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state + STATE-NUM when YYTABLE doesn't specify something else to do. Zero + means the default is an error. */ +static const yytype_uint8 yydefact[] = +{ + 0, 11, 8, 0, 0, 4, 5, 6, 7, 9, + 17, 1, 3, 2, 0, 13, 14, 16, 15, 10, + 12 +}; + +/* YYDEFGOTO[NTERM-NUM]. */ +static const yytype_int8 yydefgoto[] = +{ + -1, 4, 13, 5, 6, 7, 9, 19, 8 +}; + +/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing + STATE-NUM. */ +#define YYPACT_NINF -10 +static const yytype_int8 yypact[] = +{ + -5, -10, -10, -2, 3, -9, -10, -10, -10, 1, + -10, -10, -10, -10, 2, -10, -10, -10, -10, -10, + -10 +}; + +/* YYPGOTO[NTERM-NUM]. */ +static const yytype_int8 yypgoto[] = +{ + -10, -10, -10, -10, -10, -10, -10, -10, -10 +}; + +/* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If + positive, shift that token. If negative, reduce the rule which + number is the opposite. If zero, do what YYDEFACT says. + If YYTABLE_NINF, syntax error. */ +#define YYTABLE_NINF -1 +static const yytype_uint8 yytable[] = +{ + 1, 2, 10, 11, 12, 20, 0, 3, 14, 15, + 16, 17, 18 +}; + +static const yytype_int8 yycheck[] = +{ + 5, 6, 4, 0, 13, 3, -1, 12, 7, 8, + 9, 10, 11 +}; + +/* YYSTOS[STATE-NUM] -- The (internal number of the) accessing + symbol of state STATE-NUM. */ +static const yytype_uint8 yystos[] = +{ + 0, 5, 6, 12, 15, 17, 18, 19, 22, 20, + 4, 0, 13, 16, 7, 8, 9, 10, 11, 21, + 3 +}; + +#define yyerrok (yyerrstatus = 0) +#define yyclearin (yychar = YYEMPTY) +#define YYEMPTY (-2) +#define YYEOF 0 + +#define YYACCEPT goto yyacceptlab +#define YYABORT goto yyabortlab +#define YYERROR goto yyerrorlab + + +/* Like YYERROR except do call yyerror. This remains here temporarily + to ease the transition to the new meaning of YYERROR, for GCC. + Once GCC version 2 has supplanted version 1, this can go. */ + +#define YYFAIL goto yyerrlab + +#define YYRECOVERING() (!!yyerrstatus) + +#define YYBACKUP(Token, Value) \ +do \ + if (yychar == YYEMPTY && yylen == 1) \ + { \ + yychar = (Token); \ + yylval = (Value); \ + yytoken = YYTRANSLATE (yychar); \ + YYPOPSTACK (1); \ + goto yybackup; \ + } \ + else \ + { \ + yyerror (YY_("syntax error: cannot back up")); \ + YYERROR; \ + } \ +while (YYID (0)) + + +#define YYTERROR 1 +#define YYERRCODE 256 + + +/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N]. + If N is 0, then set CURRENT to the empty location which ends + the previous symbol: RHS[0] (always defined). */ + +#define YYRHSLOC(Rhs, K) ((Rhs)[K]) +#ifndef YYLLOC_DEFAULT +# define YYLLOC_DEFAULT(Current, Rhs, N) \ + do \ + if (YYID (N)) \ + { \ + (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \ + (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \ + (Current).last_line = YYRHSLOC (Rhs, N).last_line; \ + (Current).last_column = YYRHSLOC (Rhs, N).last_column; \ + } \ + else \ + { \ + (Current).first_line = (Current).last_line = \ + YYRHSLOC (Rhs, 0).last_line; \ + (Current).first_column = (Current).last_column = \ + YYRHSLOC (Rhs, 0).last_column; \ + } \ + while (YYID (0)) +#endif + + +/* YY_LOCATION_PRINT -- Print the location on the stream. + This macro was not mandated originally: define only if we know + we won't break user code: when these are the locations we know. */ + +#ifndef YY_LOCATION_PRINT +# if YYLTYPE_IS_TRIVIAL +# define YY_LOCATION_PRINT(File, Loc) \ + fprintf (File, "%d.%d-%d.%d", \ + (Loc).first_line, (Loc).first_column, \ + (Loc).last_line, (Loc).last_column) +# else +# define YY_LOCATION_PRINT(File, Loc) ((void) 0) +# endif +#endif + + +/* YYLEX -- calling `yylex' with the right arguments. */ + +#ifdef YYLEX_PARAM +# define YYLEX yylex (YYLEX_PARAM) +#else +# define YYLEX yylex () +#endif + +/* Enable debugging if requested. */ +#if YYDEBUG + +# ifndef YYFPRINTF +# include /* INFRINGES ON USER NAME SPACE */ +# define YYFPRINTF fprintf +# endif + +# define YYDPRINTF(Args) \ +do { \ + if (yydebug) \ + YYFPRINTF Args; \ +} while (YYID (0)) + +# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \ +do { \ + if (yydebug) \ + { \ + YYFPRINTF (stderr, "%s ", Title); \ + yy_symbol_print (stderr, \ + Type, Value); \ + YYFPRINTF (stderr, "\n"); \ + } \ +} while (YYID (0)) + + +/*--------------------------------. +| Print this symbol on YYOUTPUT. | +`--------------------------------*/ + +/*ARGSUSED*/ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep) +#else +static void +yy_symbol_value_print (yyoutput, yytype, yyvaluep) + FILE *yyoutput; + int yytype; + YYSTYPE const * const yyvaluep; +#endif +{ + if (!yyvaluep) + return; +# ifdef YYPRINT + if (yytype < YYNTOKENS) + YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep); +# else + YYUSE (yyoutput); +# endif + switch (yytype) + { + default: + break; + } +} + + +/*--------------------------------. +| Print this symbol on YYOUTPUT. | +`--------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep) +#else +static void +yy_symbol_print (yyoutput, yytype, yyvaluep) + FILE *yyoutput; + int yytype; + YYSTYPE const * const yyvaluep; +#endif +{ + if (yytype < YYNTOKENS) + YYFPRINTF (yyoutput, "token %s (", yytname[yytype]); + else + YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]); + + yy_symbol_value_print (yyoutput, yytype, yyvaluep); + YYFPRINTF (yyoutput, ")"); +} + +/*------------------------------------------------------------------. +| yy_stack_print -- Print the state stack from its BOTTOM up to its | +| TOP (included). | +`------------------------------------------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop) +#else +static void +yy_stack_print (yybottom, yytop) + yytype_int16 *yybottom; + yytype_int16 *yytop; +#endif +{ + YYFPRINTF (stderr, "Stack now"); + for (; yybottom <= yytop; yybottom++) + { + int yybot = *yybottom; + YYFPRINTF (stderr, " %d", yybot); + } + YYFPRINTF (stderr, "\n"); +} + +# define YY_STACK_PRINT(Bottom, Top) \ +do { \ + if (yydebug) \ + yy_stack_print ((Bottom), (Top)); \ +} while (YYID (0)) + + +/*------------------------------------------------. +| Report that the YYRULE is going to be reduced. | +`------------------------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_reduce_print (YYSTYPE *yyvsp, int yyrule) +#else +static void +yy_reduce_print (yyvsp, yyrule) + YYSTYPE *yyvsp; + int yyrule; +#endif +{ + int yynrhs = yyr2[yyrule]; + int yyi; + unsigned long int yylno = yyrline[yyrule]; + YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n", + yyrule - 1, yylno); + /* The symbols being reduced. */ + for (yyi = 0; yyi < yynrhs; yyi++) + { + YYFPRINTF (stderr, " $%d = ", yyi + 1); + yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi], + &(yyvsp[(yyi + 1) - (yynrhs)]) + ); + YYFPRINTF (stderr, "\n"); + } +} + +# define YY_REDUCE_PRINT(Rule) \ +do { \ + if (yydebug) \ + yy_reduce_print (yyvsp, Rule); \ +} while (YYID (0)) + +/* Nonzero means print parse trace. It is left uninitialized so that + multiple parsers can coexist. */ +int yydebug; +#else /* !YYDEBUG */ +# define YYDPRINTF(Args) +# define YY_SYMBOL_PRINT(Title, Type, Value, Location) +# define YY_STACK_PRINT(Bottom, Top) +# define YY_REDUCE_PRINT(Rule) +#endif /* !YYDEBUG */ + + +/* YYINITDEPTH -- initial size of the parser's stacks. */ +#ifndef YYINITDEPTH +# define YYINITDEPTH 200 +#endif + +/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only + if the built-in stack extension method is used). + + Do not make this value too large; the results are undefined if + YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH) + evaluated with infinite-precision integer arithmetic. */ + +#ifndef YYMAXDEPTH +# define YYMAXDEPTH 10000 +#endif + + + +#if YYERROR_VERBOSE + +# ifndef yystrlen +# if defined __GLIBC__ && defined _STRING_H +# define yystrlen strlen +# else +/* Return the length of YYSTR. */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static YYSIZE_T +yystrlen (const char *yystr) +#else +static YYSIZE_T +yystrlen (yystr) + const char *yystr; +#endif +{ + YYSIZE_T yylen; + for (yylen = 0; yystr[yylen]; yylen++) + continue; + return yylen; +} +# endif +# endif + +# ifndef yystpcpy +# if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE +# define yystpcpy stpcpy +# else +/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in + YYDEST. */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static char * +yystpcpy (char *yydest, const char *yysrc) +#else +static char * +yystpcpy (yydest, yysrc) + char *yydest; + const char *yysrc; +#endif +{ + char *yyd = yydest; + const char *yys = yysrc; + + while ((*yyd++ = *yys++) != '\0') + continue; + + return yyd - 1; +} +# endif +# endif + +# ifndef yytnamerr +/* Copy to YYRES the contents of YYSTR after stripping away unnecessary + quotes and backslashes, so that it's suitable for yyerror. The + heuristic is that double-quoting is unnecessary unless the string + contains an apostrophe, a comma, or backslash (other than + backslash-backslash). YYSTR is taken from yytname. If YYRES is + null, do not copy; instead, return the length of what the result + would have been. */ +static YYSIZE_T +yytnamerr (char *yyres, const char *yystr) +{ + if (*yystr == '"') + { + YYSIZE_T yyn = 0; + char const *yyp = yystr; + + for (;;) + switch (*++yyp) + { + case '\'': + case ',': + goto do_not_strip_quotes; + + case '\\': + if (*++yyp != '\\') + goto do_not_strip_quotes; + /* Fall through. */ + default: + if (yyres) + yyres[yyn] = *yyp; + yyn++; + break; + + case '"': + if (yyres) + yyres[yyn] = '\0'; + return yyn; + } + do_not_strip_quotes: ; + } + + if (! yyres) + return yystrlen (yystr); + + return yystpcpy (yyres, yystr) - yyres; +} +# endif + +/* Copy into YYRESULT an error message about the unexpected token + YYCHAR while in state YYSTATE. Return the number of bytes copied, + including the terminating null byte. If YYRESULT is null, do not + copy anything; just return the number of bytes that would be + copied. As a special case, return 0 if an ordinary "syntax error" + message will do. Return YYSIZE_MAXIMUM if overflow occurs during + size calculation. */ +static YYSIZE_T +yysyntax_error (char *yyresult, int yystate, int yychar) +{ + int yyn = yypact[yystate]; + + if (! (YYPACT_NINF < yyn && yyn <= YYLAST)) + return 0; + else + { + int yytype = YYTRANSLATE (yychar); + YYSIZE_T yysize0 = yytnamerr (0, yytname[yytype]); + YYSIZE_T yysize = yysize0; + YYSIZE_T yysize1; + int yysize_overflow = 0; + enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; + char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; + int yyx; + +# if 0 + /* This is so xgettext sees the translatable formats that are + constructed on the fly. */ + YY_("syntax error, unexpected %s"); + YY_("syntax error, unexpected %s, expecting %s"); + YY_("syntax error, unexpected %s, expecting %s or %s"); + YY_("syntax error, unexpected %s, expecting %s or %s or %s"); + YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"); +# endif + char *yyfmt; + char const *yyf; + static char const yyunexpected[] = "syntax error, unexpected %s"; + static char const yyexpecting[] = ", expecting %s"; + static char const yyor[] = " or %s"; + char yyformat[sizeof yyunexpected + + sizeof yyexpecting - 1 + + ((YYERROR_VERBOSE_ARGS_MAXIMUM - 2) + * (sizeof yyor - 1))]; + char const *yyprefix = yyexpecting; + + /* Start YYX at -YYN if negative to avoid negative indexes in + YYCHECK. */ + int yyxbegin = yyn < 0 ? -yyn : 0; + + /* Stay within bounds of both yycheck and yytname. */ + int yychecklim = YYLAST - yyn + 1; + int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; + int yycount = 1; + + yyarg[0] = yytname[yytype]; + yyfmt = yystpcpy (yyformat, yyunexpected); + + for (yyx = yyxbegin; yyx < yyxend; ++yyx) + if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR) + { + if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) + { + yycount = 1; + yysize = yysize0; + yyformat[sizeof yyunexpected - 1] = '\0'; + break; + } + yyarg[yycount++] = yytname[yyx]; + yysize1 = yysize + yytnamerr (0, yytname[yyx]); + yysize_overflow |= (yysize1 < yysize); + yysize = yysize1; + yyfmt = yystpcpy (yyfmt, yyprefix); + yyprefix = yyor; + } + + yyf = YY_(yyformat); + yysize1 = yysize + yystrlen (yyf); + yysize_overflow |= (yysize1 < yysize); + yysize = yysize1; + + if (yysize_overflow) + return YYSIZE_MAXIMUM; + + if (yyresult) + { + /* Avoid sprintf, as that infringes on the user's name space. + Don't have undefined behavior even if the translation + produced a string with the wrong number of "%s"s. */ + char *yyp = yyresult; + int yyi = 0; + while ((*yyp = *yyf) != '\0') + { + if (*yyp == '%' && yyf[1] == 's' && yyi < yycount) + { + yyp += yytnamerr (yyp, yyarg[yyi++]); + yyf += 2; + } + else + { + yyp++; + yyf++; + } + } + } + return yysize; + } +} +#endif /* YYERROR_VERBOSE */ + + +/*-----------------------------------------------. +| Release the memory associated to this symbol. | +`-----------------------------------------------*/ + +/*ARGSUSED*/ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep) +#else +static void +yydestruct (yymsg, yytype, yyvaluep) + const char *yymsg; + int yytype; + YYSTYPE *yyvaluep; +#endif +{ + YYUSE (yyvaluep); + + if (!yymsg) + yymsg = "Deleting"; + YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp); + + switch (yytype) + { + + default: + break; + } +} + +/* Prevent warnings from -Wmissing-prototypes. */ +#ifdef YYPARSE_PARAM +#if defined __STDC__ || defined __cplusplus +int yyparse (void *YYPARSE_PARAM); +#else +int yyparse (); +#endif +#else /* ! YYPARSE_PARAM */ +#if defined __STDC__ || defined __cplusplus +int yyparse (void); +#else +int yyparse (); +#endif +#endif /* ! YYPARSE_PARAM */ + + +/* The lookahead symbol. */ +int yychar; + +/* The semantic value of the lookahead symbol. */ +YYSTYPE yylval; + +/* Number of syntax errors so far. */ +int yynerrs; + + + +/*-------------------------. +| yyparse or yypush_parse. | +`-------------------------*/ + +#ifdef YYPARSE_PARAM +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +int +yyparse (void *YYPARSE_PARAM) +#else +int +yyparse (YYPARSE_PARAM) + void *YYPARSE_PARAM; +#endif +#else /* ! YYPARSE_PARAM */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +int +yyparse (void) +#else +int +yyparse () + +#endif +#endif +{ + + + int yystate; + /* Number of tokens to shift before error messages enabled. */ + int yyerrstatus; + + /* The stacks and their tools: + `yyss': related to states. + `yyvs': related to semantic values. + + Refer to the stacks thru separate pointers, to allow yyoverflow + to reallocate them elsewhere. */ + + /* The state stack. */ + yytype_int16 yyssa[YYINITDEPTH]; + yytype_int16 *yyss; + yytype_int16 *yyssp; + + /* The semantic value stack. */ + YYSTYPE yyvsa[YYINITDEPTH]; + YYSTYPE *yyvs; + YYSTYPE *yyvsp; + + YYSIZE_T yystacksize; + + int yyn; + int yyresult; + /* Lookahead token as an internal (translated) token number. */ + int yytoken; + /* The variables used to return semantic value and location from the + action routines. */ + YYSTYPE yyval; + +#if YYERROR_VERBOSE + /* Buffer for error messages, and its allocated size. */ + char yymsgbuf[128]; + char *yymsg = yymsgbuf; + YYSIZE_T yymsg_alloc = sizeof yymsgbuf; +#endif + +#define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N)) + + /* The number of symbols on the RHS of the reduced rule. + Keep to zero when no symbol should be popped. */ + int yylen = 0; + + yytoken = 0; + yyss = yyssa; + yyvs = yyvsa; + yystacksize = YYINITDEPTH; + + YYDPRINTF ((stderr, "Starting parse\n")); + + yystate = 0; + yyerrstatus = 0; + yynerrs = 0; + yychar = YYEMPTY; /* Cause a token to be read. */ + + /* Initialize stack pointers. + Waste one element of value and location stack + so that they stay on the same level as the state stack. + The wasted elements are never initialized. */ + yyssp = yyss; + yyvsp = yyvs; + + goto yysetstate; + +/*------------------------------------------------------------. +| yynewstate -- Push a new state, which is found in yystate. | +`------------------------------------------------------------*/ + yynewstate: + /* In all cases, when you get here, the value and location stacks + have just been pushed. So pushing a state here evens the stacks. */ + yyssp++; + + yysetstate: + *yyssp = yystate; + + if (yyss + yystacksize - 1 <= yyssp) + { + /* Get the current used size of the three stacks, in elements. */ + YYSIZE_T yysize = yyssp - yyss + 1; + +#ifdef yyoverflow + { + /* Give user a chance to reallocate the stack. Use copies of + these so that the &'s don't force the real ones into + memory. */ + YYSTYPE *yyvs1 = yyvs; + yytype_int16 *yyss1 = yyss; + + /* Each stack pointer address is followed by the size of the + data in use in that stack, in bytes. This used to be a + conditional around just the two extra args, but that might + be undefined if yyoverflow is a macro. */ + yyoverflow (YY_("memory exhausted"), + &yyss1, yysize * sizeof (*yyssp), + &yyvs1, yysize * sizeof (*yyvsp), + &yystacksize); + + yyss = yyss1; + yyvs = yyvs1; + } +#else /* no yyoverflow */ +# ifndef YYSTACK_RELOCATE + goto yyexhaustedlab; +# else + /* Extend the stack our own way. */ + if (YYMAXDEPTH <= yystacksize) + goto yyexhaustedlab; + yystacksize *= 2; + if (YYMAXDEPTH < yystacksize) + yystacksize = YYMAXDEPTH; + + { + yytype_int16 *yyss1 = yyss; + union yyalloc *yyptr = + (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize)); + if (! yyptr) + goto yyexhaustedlab; + YYSTACK_RELOCATE (yyss_alloc, yyss); + YYSTACK_RELOCATE (yyvs_alloc, yyvs); +# undef YYSTACK_RELOCATE + if (yyss1 != yyssa) + YYSTACK_FREE (yyss1); + } +# endif +#endif /* no yyoverflow */ + + yyssp = yyss + yysize - 1; + yyvsp = yyvs + yysize - 1; + + YYDPRINTF ((stderr, "Stack size increased to %lu\n", + (unsigned long int) yystacksize)); + + if (yyss + yystacksize - 1 <= yyssp) + YYABORT; + } + + YYDPRINTF ((stderr, "Entering state %d\n", yystate)); + + if (yystate == YYFINAL) + YYACCEPT; + + goto yybackup; + +/*-----------. +| yybackup. | +`-----------*/ +yybackup: + + /* Do appropriate processing given the current state. Read a + lookahead token if we need one and don't already have one. */ + + /* First try to decide what to do without reference to lookahead token. */ + yyn = yypact[yystate]; + if (yyn == YYPACT_NINF) + goto yydefault; + + /* Not known => get a lookahead token if don't already have one. */ + + /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */ + if (yychar == YYEMPTY) + { + YYDPRINTF ((stderr, "Reading a token: ")); + yychar = YYLEX; + } + + if (yychar <= YYEOF) + { + yychar = yytoken = YYEOF; + YYDPRINTF ((stderr, "Now at end of input.\n")); + } + else + { + yytoken = YYTRANSLATE (yychar); + YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc); + } + + /* If the proper action on seeing token YYTOKEN is to reduce or to + detect an error, take that action. */ + yyn += yytoken; + if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken) + goto yydefault; + yyn = yytable[yyn]; + if (yyn <= 0) + { + if (yyn == 0 || yyn == YYTABLE_NINF) + goto yyerrlab; + yyn = -yyn; + goto yyreduce; + } + + /* Count tokens shifted since error; after three, turn off error + status. */ + if (yyerrstatus) + yyerrstatus--; + + /* Shift the lookahead token. */ + YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc); + + /* Discard the shifted token. */ + yychar = YYEMPTY; + + yystate = yyn; + *++yyvsp = yylval; + + goto yynewstate; + + +/*-----------------------------------------------------------. +| yydefault -- do the default action for the current state. | +`-----------------------------------------------------------*/ +yydefault: + yyn = yydefact[yystate]; + if (yyn == 0) + goto yyerrlab; + goto yyreduce; + + +/*-----------------------------. +| yyreduce -- Do a reduction. | +`-----------------------------*/ +yyreduce: + /* yyn is the number of a rule to reduce with. */ + yylen = yyr2[yyn]; + + /* If YYLEN is nonzero, implement the default value of the action: + `$$ = $1'. + + Otherwise, the following line sets YYVAL to garbage. + This behavior is undocumented and Bison + users should not rely upon it. Assigning to YYVAL + unconditionally makes the parser a bit smaller, and it avoids a + GCC warning that YYVAL may be used uninitialized. */ + yyval = yyvsp[1-yylen]; + + + YY_REDUCE_PRINT (yyn); + switch (yyn) + { + case 2: + +/* Line 1455 of yacc.c */ +#line 87 "repl_gram.y" + { + replication_parse_result = (yyvsp[(1) - (2)].node); + ;} + break; + + case 8: + +/* Line 1455 of yacc.c */ +#line 107 "repl_gram.y" + { + (yyval.node) = (Node *) makeNode(IdentifySystemCmd); + ;} + break; + + case 9: + +/* Line 1455 of yacc.c */ +#line 117 "repl_gram.y" + { + BaseBackupCmd *cmd = (BaseBackupCmd *) makeNode(BaseBackupCmd); + cmd->options = (yyvsp[(2) - (2)].list); + (yyval.node) = (Node *) cmd; + ;} + break; + + case 10: + +/* Line 1455 of yacc.c */ +#line 124 "repl_gram.y" + { (yyval.list) = lappend((yyvsp[(1) - (2)].list), (yyvsp[(2) - (2)].defelt)); ;} + break; + + case 11: + +/* Line 1455 of yacc.c */ +#line 125 "repl_gram.y" + { (yyval.list) = NIL; ;} + break; + + case 12: + +/* Line 1455 of yacc.c */ +#line 129 "repl_gram.y" + { + (yyval.defelt) = makeDefElem("label", + (Node *)makeString((yyvsp[(2) - (2)].str))); + ;} + break; + + case 13: + +/* Line 1455 of yacc.c */ +#line 134 "repl_gram.y" + { + (yyval.defelt) = makeDefElem("progress", + (Node *)makeInteger(TRUE)); + ;} + break; + + case 14: + +/* Line 1455 of yacc.c */ +#line 139 "repl_gram.y" + { + (yyval.defelt) = makeDefElem("fast", + (Node *)makeInteger(TRUE)); + ;} + break; + + case 15: + +/* Line 1455 of yacc.c */ +#line 144 "repl_gram.y" + { + (yyval.defelt) = makeDefElem("wal", + (Node *)makeInteger(TRUE)); + ;} + break; + + case 16: + +/* Line 1455 of yacc.c */ +#line 149 "repl_gram.y" + { + (yyval.defelt) = makeDefElem("nowait", + (Node *)makeInteger(TRUE)); + ;} + break; + + case 17: + +/* Line 1455 of yacc.c */ +#line 160 "repl_gram.y" + { + StartReplicationCmd *cmd; + + cmd = makeNode(StartReplicationCmd); + cmd->startpoint = (yyvsp[(2) - (2)].recptr); + + (yyval.node) = (Node *) cmd; + ;} + break; + + + +/* Line 1455 of yacc.c */ +#line 1510 "repl_gram.c" + default: break; + } + YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); + + YYPOPSTACK (yylen); + yylen = 0; + YY_STACK_PRINT (yyss, yyssp); + + *++yyvsp = yyval; + + /* Now `shift' the result of the reduction. Determine what state + that goes to, based on the state we popped back to and the rule + number reduced by. */ + + yyn = yyr1[yyn]; + + yystate = yypgoto[yyn - YYNTOKENS] + *yyssp; + if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp) + yystate = yytable[yystate]; + else + yystate = yydefgoto[yyn - YYNTOKENS]; + + goto yynewstate; + + +/*------------------------------------. +| yyerrlab -- here on detecting error | +`------------------------------------*/ +yyerrlab: + /* If not already recovering from an error, report this error. */ + if (!yyerrstatus) + { + ++yynerrs; +#if ! YYERROR_VERBOSE + yyerror (YY_("syntax error")); +#else + { + YYSIZE_T yysize = yysyntax_error (0, yystate, yychar); + if (yymsg_alloc < yysize && yymsg_alloc < YYSTACK_ALLOC_MAXIMUM) + { + YYSIZE_T yyalloc = 2 * yysize; + if (! (yysize <= yyalloc && yyalloc <= YYSTACK_ALLOC_MAXIMUM)) + yyalloc = YYSTACK_ALLOC_MAXIMUM; + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); + yymsg = (char *) YYSTACK_ALLOC (yyalloc); + if (yymsg) + yymsg_alloc = yyalloc; + else + { + yymsg = yymsgbuf; + yymsg_alloc = sizeof yymsgbuf; + } + } + + if (0 < yysize && yysize <= yymsg_alloc) + { + (void) yysyntax_error (yymsg, yystate, yychar); + yyerror (yymsg); + } + else + { + yyerror (YY_("syntax error")); + if (yysize != 0) + goto yyexhaustedlab; + } + } +#endif + } + + + + if (yyerrstatus == 3) + { + /* If just tried and failed to reuse lookahead token after an + error, discard it. */ + + if (yychar <= YYEOF) + { + /* Return failure if at end of input. */ + if (yychar == YYEOF) + YYABORT; + } + else + { + yydestruct ("Error: discarding", + yytoken, &yylval); + yychar = YYEMPTY; + } + } + + /* Else will try to reuse lookahead token after shifting the error + token. */ + goto yyerrlab1; + + +/*---------------------------------------------------. +| yyerrorlab -- error raised explicitly by YYERROR. | +`---------------------------------------------------*/ +yyerrorlab: + + /* Pacify compilers like GCC when the user code never invokes + YYERROR and the label yyerrorlab therefore never appears in user + code. */ + if (/*CONSTCOND*/ 0) + goto yyerrorlab; + + /* Do not reclaim the symbols of the rule which action triggered + this YYERROR. */ + YYPOPSTACK (yylen); + yylen = 0; + YY_STACK_PRINT (yyss, yyssp); + yystate = *yyssp; + goto yyerrlab1; + + +/*-------------------------------------------------------------. +| yyerrlab1 -- common code for both syntax error and YYERROR. | +`-------------------------------------------------------------*/ +yyerrlab1: + yyerrstatus = 3; /* Each real token shifted decrements this. */ + + for (;;) + { + yyn = yypact[yystate]; + if (yyn != YYPACT_NINF) + { + yyn += YYTERROR; + if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR) + { + yyn = yytable[yyn]; + if (0 < yyn) + break; + } + } + + /* Pop the current state because it cannot handle the error token. */ + if (yyssp == yyss) + YYABORT; + + + yydestruct ("Error: popping", + yystos[yystate], yyvsp); + YYPOPSTACK (1); + yystate = *yyssp; + YY_STACK_PRINT (yyss, yyssp); + } + + *++yyvsp = yylval; + + + /* Shift the error token. */ + YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp); + + yystate = yyn; + goto yynewstate; + + +/*-------------------------------------. +| yyacceptlab -- YYACCEPT comes here. | +`-------------------------------------*/ +yyacceptlab: + yyresult = 0; + goto yyreturn; + +/*-----------------------------------. +| yyabortlab -- YYABORT comes here. | +`-----------------------------------*/ +yyabortlab: + yyresult = 1; + goto yyreturn; + +#if !defined(yyoverflow) || YYERROR_VERBOSE +/*-------------------------------------------------. +| yyexhaustedlab -- memory exhaustion comes here. | +`-------------------------------------------------*/ +yyexhaustedlab: + yyerror (YY_("memory exhausted")); + yyresult = 2; + /* Fall through. */ +#endif + +yyreturn: + if (yychar != YYEMPTY) + yydestruct ("Cleanup: discarding lookahead", + yytoken, &yylval); + /* Do not reclaim the symbols of the rule which action triggered + this YYABORT or YYACCEPT. */ + YYPOPSTACK (yylen); + YY_STACK_PRINT (yyss, yyssp); + while (yyssp != yyss) + { + yydestruct ("Cleanup: popping", + yystos[*yyssp], yyvsp); + YYPOPSTACK (1); + } +#ifndef yyoverflow + if (yyss != yyssa) + YYSTACK_FREE (yyss); +#endif +#if YYERROR_VERBOSE + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); +#endif + /* Make sure YYID is used. */ + return YYID (yyresult); +} + + + +/* Line 1675 of yacc.c */ +#line 169 "repl_gram.y" + + +#include "repl_scanner.c" + diff --git a/src/backend/replication/repl_gram.h b/src/backend/replication/repl_gram.h new file mode 100644 index 000000000..b2d4d659d --- /dev/null +++ b/src/backend/replication/repl_gram.h @@ -0,0 +1,84 @@ + +/* A Bison parser, made by GNU Bison 2.4.1. */ + +/* Skeleton interface for Bison's Yacc-like parsers in C + + Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 + Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . */ + +/* As a special exception, you may create a larger work that contains + part or all of the Bison parser skeleton and distribute that work + under terms of your choice, so long as that work isn't itself a + parser generator using the skeleton or a modified version thereof + as a parser skeleton. Alternatively, if you modify or redistribute + the parser skeleton itself, you may (at your option) remove this + special exception, which will cause the skeleton and the resulting + Bison output files to be licensed under the GNU General Public + License without this special exception. + + This special exception was added by the Free Software Foundation in + version 2.2 of Bison. */ + + +/* Tokens. */ +#ifndef YYTOKENTYPE +# define YYTOKENTYPE + /* Put the tokens into the symbol table, so that GDB and other debuggers + know about them. */ + enum yytokentype { + SCONST = 258, + RECPTR = 259, + K_BASE_BACKUP = 260, + K_IDENTIFY_SYSTEM = 261, + K_LABEL = 262, + K_PROGRESS = 263, + K_FAST = 264, + K_NOWAIT = 265, + K_WAL = 266, + K_START_REPLICATION = 267 + }; +#endif + + + +#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED +typedef union YYSTYPE +{ + +/* Line 1676 of yacc.c */ +#line 56 "repl_gram.y" + + char *str; + bool boolval; + + XLogRecPtr recptr; + Node *node; + List *list; + DefElem *defelt; + + + +/* Line 1676 of yacc.c */ +#line 76 "repl_gram.h" +} YYSTYPE; +# define YYSTYPE_IS_TRIVIAL 1 +# define yystype YYSTYPE /* obsolescent; will be withdrawn */ +# define YYSTYPE_IS_DECLARED 1 +#endif + +extern YYSTYPE replication_yylval; + + diff --git a/src/backend/replication/repl_scanner.c b/src/backend/replication/repl_scanner.c new file mode 100644 index 000000000..6eab5d3eb --- /dev/null +++ b/src/backend/replication/repl_scanner.c @@ -0,0 +1,2005 @@ +#line 2 "repl_scanner.c" + +#line 4 "repl_scanner.c" + +#define YY_INT_ALIGNED short int + +/* A lexical scanner generated by flex */ + +#define yy_create_buffer replication_yy_create_buffer +#define yy_delete_buffer replication_yy_delete_buffer +#define yy_flex_debug replication_yy_flex_debug +#define yy_init_buffer replication_yy_init_buffer +#define yy_flush_buffer replication_yy_flush_buffer +#define yy_load_buffer_state replication_yy_load_buffer_state +#define yy_switch_to_buffer replication_yy_switch_to_buffer +#define yyin replication_yyin +#define yyleng replication_yyleng +#define yylex replication_yylex +#define yylineno replication_yylineno +#define yyout replication_yyout +#define yyrestart replication_yyrestart +#define yytext replication_yytext +#define yywrap replication_yywrap +#define yyalloc replication_yyalloc +#define yyrealloc replication_yyrealloc +#define yyfree replication_yyfree + +#define FLEX_SCANNER +#define YY_FLEX_MAJOR_VERSION 2 +#define YY_FLEX_MINOR_VERSION 5 +#define YY_FLEX_SUBMINOR_VERSION 35 +#if YY_FLEX_SUBMINOR_VERSION > 0 +#define FLEX_BETA +#endif + +/* First, we deal with platform-specific or compiler-specific issues. */ + +/* begin standard C headers. */ +#include +#include +#include +#include + +/* end standard C headers. */ + +/* flex integer type definitions */ + +#ifndef FLEXINT_H +#define FLEXINT_H + +/* C99 systems have . Non-C99 systems may or may not. */ + +#if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L + +/* C99 says to define __STDC_LIMIT_MACROS before including stdint.h, + * if you want the limit (max/min) macros for int types. + */ +#ifndef __STDC_LIMIT_MACROS +#define __STDC_LIMIT_MACROS 1 +#endif + +#include +typedef int8_t flex_int8_t; +typedef uint8_t flex_uint8_t; +typedef int16_t flex_int16_t; +typedef uint16_t flex_uint16_t; +typedef int32_t flex_int32_t; +typedef uint32_t flex_uint32_t; +#else +typedef signed char flex_int8_t; +typedef short int flex_int16_t; +typedef int flex_int32_t; +typedef unsigned char flex_uint8_t; +typedef unsigned short int flex_uint16_t; +typedef unsigned int flex_uint32_t; + +/* Limits of integral types. */ +#ifndef INT8_MIN +#define INT8_MIN (-128) +#endif +#ifndef INT16_MIN +#define INT16_MIN (-32767-1) +#endif +#ifndef INT32_MIN +#define INT32_MIN (-2147483647-1) +#endif +#ifndef INT8_MAX +#define INT8_MAX (127) +#endif +#ifndef INT16_MAX +#define INT16_MAX (32767) +#endif +#ifndef INT32_MAX +#define INT32_MAX (2147483647) +#endif +#ifndef UINT8_MAX +#define UINT8_MAX (255U) +#endif +#ifndef UINT16_MAX +#define UINT16_MAX (65535U) +#endif +#ifndef UINT32_MAX +#define UINT32_MAX (4294967295U) +#endif + +#endif /* ! C99 */ + +#endif /* ! FLEXINT_H */ + +#ifdef __cplusplus + +/* The "const" storage-class-modifier is valid. */ +#define YY_USE_CONST + +#else /* ! __cplusplus */ + +/* C99 requires __STDC__ to be defined as 1. */ +#if defined (__STDC__) + +#define YY_USE_CONST + +#endif /* defined (__STDC__) */ +#endif /* ! __cplusplus */ + +#ifdef YY_USE_CONST +#define yyconst const +#else +#define yyconst +#endif + +/* Returned upon end-of-file. */ +#define YY_NULL 0 + +/* Promotes a possibly negative, possibly signed char to an unsigned + * integer for use as an array index. If the signed char is negative, + * we want to instead treat it as an 8-bit unsigned char, hence the + * double cast. + */ +#define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c) + +/* Enter a start condition. This macro really ought to take a parameter, + * but we do it the disgusting crufty way forced on us by the ()-less + * definition of BEGIN. + */ +#define BEGIN (yy_start) = 1 + 2 * + +/* Translate the current start state into a value that can be later handed + * to BEGIN to return to the state. The YYSTATE alias is for lex + * compatibility. + */ +#define YY_START (((yy_start) - 1) / 2) +#define YYSTATE YY_START + +/* Action number for EOF rule of a given start state. */ +#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1) + +/* Special action meaning "start processing a new file". */ +#define YY_NEW_FILE replication_yyrestart(replication_yyin ) + +#define YY_END_OF_BUFFER_CHAR 0 + +/* Size of default input buffer. */ +#ifndef YY_BUF_SIZE +#ifdef __ia64__ +/* On IA-64, the buffer size is 16k, not 8k. + * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case. + * Ditto for the __ia64__ case accordingly. + */ +#define YY_BUF_SIZE 32768 +#else +#define YY_BUF_SIZE 16384 +#endif /* __ia64__ */ +#endif + +/* The state buf must be large enough to hold one state per character in the main buffer. + */ +#define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type)) + +#ifndef YY_TYPEDEF_YY_BUFFER_STATE +#define YY_TYPEDEF_YY_BUFFER_STATE +typedef struct yy_buffer_state *YY_BUFFER_STATE; +#endif + +extern int replication_yyleng; + +extern FILE *replication_yyin, *replication_yyout; + +#define EOB_ACT_CONTINUE_SCAN 0 +#define EOB_ACT_END_OF_FILE 1 +#define EOB_ACT_LAST_MATCH 2 + + #define YY_LESS_LINENO(n) + +/* Return all but the first "n" matched characters back to the input stream. */ +#define yyless(n) \ + do \ + { \ + /* Undo effects of setting up replication_yytext. */ \ + int yyless_macro_arg = (n); \ + YY_LESS_LINENO(yyless_macro_arg);\ + *yy_cp = (yy_hold_char); \ + YY_RESTORE_YY_MORE_OFFSET \ + (yy_c_buf_p) = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \ + YY_DO_BEFORE_ACTION; /* set up replication_yytext again */ \ + } \ + while ( 0 ) + +#define unput(c) yyunput( c, (yytext_ptr) ) + +#ifndef YY_TYPEDEF_YY_SIZE_T +#define YY_TYPEDEF_YY_SIZE_T +typedef size_t yy_size_t; +#endif + +#ifndef YY_STRUCT_YY_BUFFER_STATE +#define YY_STRUCT_YY_BUFFER_STATE +struct yy_buffer_state + { + FILE *yy_input_file; + + char *yy_ch_buf; /* input buffer */ + char *yy_buf_pos; /* current position in input buffer */ + + /* Size of input buffer in bytes, not including room for EOB + * characters. + */ + yy_size_t yy_buf_size; + + /* Number of characters read into yy_ch_buf, not including EOB + * characters. + */ + int yy_n_chars; + + /* Whether we "own" the buffer - i.e., we know we created it, + * and can realloc() it to grow it, and should free() it to + * delete it. + */ + int yy_is_our_buffer; + + /* Whether this is an "interactive" input source; if so, and + * if we're using stdio for input, then we want to use getc() + * instead of fread(), to make sure we stop fetching input after + * each newline. + */ + int yy_is_interactive; + + /* Whether we're considered to be at the beginning of a line. + * If so, '^' rules will be active on the next match, otherwise + * not. + */ + int yy_at_bol; + + int yy_bs_lineno; /**< The line count. */ + int yy_bs_column; /**< The column count. */ + + /* Whether to try to fill the input buffer when we reach the + * end of it. + */ + int yy_fill_buffer; + + int yy_buffer_status; + +#define YY_BUFFER_NEW 0 +#define YY_BUFFER_NORMAL 1 + /* When an EOF's been seen but there's still some text to process + * then we mark the buffer as YY_EOF_PENDING, to indicate that we + * shouldn't try reading from the input source any more. We might + * still have a bunch of tokens to match, though, because of + * possible backing-up. + * + * When we actually see the EOF, we change the status to "new" + * (via replication_yyrestart()), so that the user can continue scanning by + * just pointing replication_yyin at a new input file. + */ +#define YY_BUFFER_EOF_PENDING 2 + + }; +#endif /* !YY_STRUCT_YY_BUFFER_STATE */ + +/* Stack of input buffers. */ +static size_t yy_buffer_stack_top = 0; /**< index of top of stack. */ +static size_t yy_buffer_stack_max = 0; /**< capacity of stack. */ +static YY_BUFFER_STATE * yy_buffer_stack = 0; /**< Stack as an array. */ + +/* We provide macros for accessing buffer states in case in the + * future we want to put the buffer states in a more general + * "scanner state". + * + * Returns the top of the stack, or NULL. + */ +#define YY_CURRENT_BUFFER ( (yy_buffer_stack) \ + ? (yy_buffer_stack)[(yy_buffer_stack_top)] \ + : NULL) + +/* Same as previous macro, but useful when we know that the buffer stack is not + * NULL or when we need an lvalue. For internal use only. + */ +#define YY_CURRENT_BUFFER_LVALUE (yy_buffer_stack)[(yy_buffer_stack_top)] + +/* yy_hold_char holds the character lost when replication_yytext is formed. */ +static char yy_hold_char; +static int yy_n_chars; /* number of characters read into yy_ch_buf */ +int replication_yyleng; + +/* Points to current character in buffer. */ +static char *yy_c_buf_p = (char *) 0; +static int yy_init = 0; /* whether we need to initialize */ +static int yy_start = 0; /* start state number */ + +/* Flag which is used to allow replication_yywrap()'s to do buffer switches + * instead of setting up a fresh replication_yyin. A bit of a hack ... + */ +static int yy_did_buffer_switch_on_eof; + +void replication_yyrestart (FILE *input_file ); +void replication_yy_switch_to_buffer (YY_BUFFER_STATE new_buffer ); +YY_BUFFER_STATE replication_yy_create_buffer (FILE *file,int size ); +void replication_yy_delete_buffer (YY_BUFFER_STATE b ); +void replication_yy_flush_buffer (YY_BUFFER_STATE b ); +void replication_yypush_buffer_state (YY_BUFFER_STATE new_buffer ); +void replication_yypop_buffer_state (void ); + +static void replication_yyensure_buffer_stack (void ); +static void replication_yy_load_buffer_state (void ); +static void replication_yy_init_buffer (YY_BUFFER_STATE b,FILE *file ); + +#define YY_FLUSH_BUFFER replication_yy_flush_buffer(YY_CURRENT_BUFFER ) + +YY_BUFFER_STATE replication_yy_scan_buffer (char *base,yy_size_t size ); +YY_BUFFER_STATE replication_yy_scan_string (yyconst char *yy_str ); +YY_BUFFER_STATE replication_yy_scan_bytes (yyconst char *bytes,int len ); + +void *replication_yyalloc (yy_size_t ); +void *replication_yyrealloc (void *,yy_size_t ); +void replication_yyfree (void * ); + +#define yy_new_buffer replication_yy_create_buffer + +#define yy_set_interactive(is_interactive) \ + { \ + if ( ! YY_CURRENT_BUFFER ){ \ + replication_yyensure_buffer_stack (); \ + YY_CURRENT_BUFFER_LVALUE = \ + replication_yy_create_buffer(replication_yyin,YY_BUF_SIZE ); \ + } \ + YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \ + } + +#define yy_set_bol(at_bol) \ + { \ + if ( ! YY_CURRENT_BUFFER ){\ + replication_yyensure_buffer_stack (); \ + YY_CURRENT_BUFFER_LVALUE = \ + replication_yy_create_buffer(replication_yyin,YY_BUF_SIZE ); \ + } \ + YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \ + } + +#define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol) + +/* Begin user sect3 */ + +#define replication_yywrap(n) 1 +#define YY_SKIP_YYWRAP + +typedef unsigned char YY_CHAR; + +FILE *replication_yyin = (FILE *) 0, *replication_yyout = (FILE *) 0; + +typedef int yy_state_type; + +extern int replication_yylineno; + +int replication_yylineno = 1; + +extern char *replication_yytext; +#define yytext_ptr replication_yytext + +static yy_state_type yy_get_previous_state (void ); +static yy_state_type yy_try_NUL_trans (yy_state_type current_state ); +static int yy_get_next_buffer (void ); +static void yy_fatal_error (yyconst char msg[] ); + +/* Done after the current pattern has been matched and before the + * corresponding action - sets up replication_yytext. + */ +#define YY_DO_BEFORE_ACTION \ + (yytext_ptr) = yy_bp; \ + replication_yyleng = (size_t) (yy_cp - yy_bp); \ + (yy_hold_char) = *yy_cp; \ + *yy_cp = '\0'; \ + (yy_c_buf_p) = yy_cp; + +#define YY_NUM_RULES 20 +#define YY_END_OF_BUFFER 21 +/* This struct is not used in this scanner, + but its presence is necessary. */ +struct yy_trans_info + { + flex_int32_t yy_verify; + flex_int32_t yy_nxt; + }; +static yyconst flex_int16_t yy_accept[91] = + { 0, + 0, 0, 0, 0, 21, 19, 12, 11, 13, 15, + 9, 19, 10, 19, 19, 19, 19, 19, 19, 19, + 19, 18, 16, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 18, 17, 14, 0, 0, 0, 0, + 0, 0, 0, 7, 0, 2, 0, 0, 0, 0, + 0, 0, 0, 4, 0, 0, 0, 0, 0, 5, + 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, + 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, + 0, 0, 0, 0, 0, 3, 0, 0, 8, 0 + } ; + +static yyconst flex_int32_t yy_ec[256] = + { 0, + 1, 1, 1, 1, 1, 1, 1, 1, 2, 3, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 4, 1, 1, 1, 1, 1, 1, 5, 1, + 1, 1, 1, 6, 1, 1, 7, 8, 8, 8, + 8, 8, 8, 8, 8, 8, 8, 1, 9, 1, + 1, 1, 1, 1, 10, 11, 12, 13, 14, 15, + 16, 8, 17, 8, 18, 19, 20, 21, 22, 23, + 8, 24, 25, 26, 27, 8, 28, 8, 29, 8, + 1, 1, 1, 1, 30, 1, 8, 8, 8, 8, + + 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, + 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, + 8, 8, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1 + } ; + +static yyconst flex_int32_t yy_meta[31] = + { 0, + 1, 1, 1, 1, 2, 1, 3, 4, 1, 4, + 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4, 4, 1 + } ; + +static yyconst flex_int16_t yy_base[95] = + { 0, + 0, 0, 145, 144, 148, 151, 151, 151, 151, 151, + 151, 140, 151, 24, 25, 26, 30, 29, 31, 34, + 35, 0, 141, 0, 138, 36, 37, 39, 41, 40, + 42, 47, 51, 0, 151, 0, 49, 43, 52, 58, + 64, 59, 60, 137, 69, 136, 70, 71, 72, 73, + 74, 131, 75, 134, 76, 79, 78, 130, 80, 132, + 81, 114, 125, 84, 87, 122, 117, 91, 127, 110, + 105, 104, 101, 96, 89, 100, 151, 91, 103, 88, + 101, 96, 83, 87, 88, 151, 82, 82, 151, 151, + 121, 123, 127, 97 + + } ; + +static yyconst flex_int16_t yy_def[95] = + { 0, + 90, 1, 91, 91, 90, 90, 90, 90, 90, 90, + 90, 92, 90, 92, 92, 92, 92, 92, 92, 92, + 92, 93, 90, 94, 92, 92, 92, 92, 92, 92, + 92, 92, 92, 93, 90, 94, 92, 92, 92, 92, + 92, 92, 92, 92, 92, 92, 92, 92, 92, 92, + 92, 90, 92, 92, 92, 92, 92, 90, 92, 92, + 92, 90, 90, 92, 92, 90, 90, 92, 92, 90, + 90, 90, 90, 90, 90, 90, 90, 90, 90, 90, + 90, 90, 90, 90, 90, 90, 90, 90, 90, 0, + 90, 90, 90, 90 + + } ; + +static yyconst flex_int16_t yy_nxt[182] = + { 0, + 6, 7, 8, 9, 10, 11, 6, 12, 13, 12, + 14, 12, 12, 12, 15, 12, 16, 12, 17, 12, + 18, 12, 19, 12, 20, 12, 12, 21, 12, 6, + 24, 24, 24, 26, 27, 24, 24, 24, 28, 29, + 24, 24, 24, 24, 33, 24, 24, 24, 24, 24, + 30, 40, 39, 24, 31, 24, 43, 24, 24, 32, + 37, 38, 45, 42, 24, 24, 24, 41, 46, 44, + 24, 48, 47, 49, 50, 24, 24, 24, 24, 24, + 24, 24, 24, 51, 24, 24, 24, 24, 55, 54, + 24, 59, 61, 24, 64, 53, 56, 24, 52, 57, + + 36, 60, 89, 88, 87, 65, 86, 62, 85, 84, + 83, 69, 68, 82, 81, 80, 79, 78, 77, 76, + 72, 22, 22, 22, 22, 25, 25, 34, 75, 34, + 34, 74, 73, 24, 71, 70, 67, 66, 24, 63, + 24, 58, 24, 24, 24, 35, 24, 90, 23, 23, + 5, 90, 90, 90, 90, 90, 90, 90, 90, 90, + 90, 90, 90, 90, 90, 90, 90, 90, 90, 90, + 90, 90, 90, 90, 90, 90, 90, 90, 90, 90, + 90 + } ; + +static yyconst flex_int16_t yy_chk[182] = + { 0, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 14, 15, 16, 14, 15, 18, 17, 19, 16, 17, + 20, 21, 26, 27, 21, 28, 30, 29, 31, 38, + 18, 29, 28, 32, 19, 37, 32, 33, 39, 20, + 26, 27, 37, 31, 40, 42, 43, 30, 38, 33, + 41, 40, 39, 41, 42, 45, 47, 48, 49, 50, + 51, 53, 55, 43, 57, 56, 59, 61, 49, 48, + 64, 53, 56, 65, 59, 47, 50, 68, 45, 51, + + 94, 55, 88, 87, 85, 61, 84, 57, 83, 82, + 81, 65, 64, 80, 79, 78, 76, 75, 74, 73, + 68, 91, 91, 91, 91, 92, 92, 93, 72, 93, + 93, 71, 70, 69, 67, 66, 63, 62, 60, 58, + 54, 52, 46, 44, 25, 23, 12, 5, 4, 3, + 90, 90, 90, 90, 90, 90, 90, 90, 90, 90, + 90, 90, 90, 90, 90, 90, 90, 90, 90, 90, + 90, 90, 90, 90, 90, 90, 90, 90, 90, 90, + 90 + } ; + +static yy_state_type yy_last_accepting_state; +static char *yy_last_accepting_cpos; + +extern int replication_yy_flex_debug; +int replication_yy_flex_debug = 0; + +/* The intent behind this definition is that it'll catch + * any uses of REJECT which flex missed. + */ +#define REJECT reject_used_but_not_detected +#define yymore() yymore_used_but_not_detected +#define YY_MORE_ADJ 0 +#define YY_RESTORE_YY_MORE_OFFSET +char *replication_yytext; +#line 1 "repl_scanner.l" +#line 2 "repl_scanner.l" +/*------------------------------------------------------------------------- + * + * repl_scanner.l + * a lexical scanner for the replication commands + * + * Portions Copyright (c) 1996-2012, PostgreSQL Global Development Group + * Portions Copyright (c) 1994, Regents of the University of California + * + * + * IDENTIFICATION + * src/backend/replication/repl_scanner.l + * + *------------------------------------------------------------------------- + */ +#include "postgres.h" + +/* Avoid exit() on fatal scanner errors (a bit ugly -- see yy_fatal_error) */ +#undef fprintf +#define fprintf(file, fmt, msg) ereport(ERROR, (errmsg_internal("%s", msg))) + +/* Handle to the buffer that the lexer uses internally */ +static YY_BUFFER_STATE scanbufhandle; + +static StringInfoData litbuf; + +static void startlit(void); +static char *litbufdup(void); +static void addlit(char *ytext, int yleng); +static void addlitchar(unsigned char ychar); + +#define YY_NO_INPUT 1 + +/* Extended quote + * xqdouble implements embedded quote, '''' + */ +#line 585 "repl_scanner.c" + +#define INITIAL 0 +#define xq 1 + +#ifndef YY_NO_UNISTD_H +/* Special case for "unistd.h", since it is non-ANSI. We include it way + * down here because we want the user's section 1 to have been scanned first. + * The user has a chance to override it with an option. + */ +#include +#endif + +#ifndef YY_EXTRA_TYPE +#define YY_EXTRA_TYPE void * +#endif + +static int yy_init_globals (void ); + +/* Accessor methods to globals. + These are made visible to non-reentrant scanners for convenience. */ + +int replication_yylex_destroy (void ); + +int replication_yyget_debug (void ); + +void replication_yyset_debug (int debug_flag ); + +YY_EXTRA_TYPE replication_yyget_extra (void ); + +void replication_yyset_extra (YY_EXTRA_TYPE user_defined ); + +FILE *replication_yyget_in (void ); + +void replication_yyset_in (FILE * in_str ); + +FILE *replication_yyget_out (void ); + +void replication_yyset_out (FILE * out_str ); + +int replication_yyget_leng (void ); + +char *replication_yyget_text (void ); + +int replication_yyget_lineno (void ); + +void replication_yyset_lineno (int line_number ); + +/* Macros after this point can all be overridden by user definitions in + * section 1. + */ + +#ifndef YY_SKIP_YYWRAP +#ifdef __cplusplus +extern "C" int replication_yywrap (void ); +#else +extern int replication_yywrap (void ); +#endif +#endif + +#ifndef yytext_ptr +static void yy_flex_strncpy (char *,yyconst char *,int ); +#endif + +#ifdef YY_NEED_STRLEN +static int yy_flex_strlen (yyconst char * ); +#endif + +#ifndef YY_NO_INPUT + +#ifdef __cplusplus +static int yyinput (void ); +#else +static int input (void ); +#endif + +#endif + +/* Amount of stuff to slurp up with each read. */ +#ifndef YY_READ_BUF_SIZE +#ifdef __ia64__ +/* On IA-64, the buffer size is 16k, not 8k */ +#define YY_READ_BUF_SIZE 16384 +#else +#define YY_READ_BUF_SIZE 8192 +#endif /* __ia64__ */ +#endif + +/* Copy whatever the last rule matched to the standard output. */ +#ifndef ECHO +/* This used to be an fputs(), but since the string might contain NUL's, + * we now use fwrite(). + */ +#define ECHO do { if (fwrite( replication_yytext, replication_yyleng, 1, replication_yyout )) {} } while (0) +#endif + +/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL, + * is returned in "result". + */ +#ifndef YY_INPUT +#define YY_INPUT(buf,result,max_size) \ + if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \ + { \ + int c = '*'; \ + size_t n; \ + for ( n = 0; n < max_size && \ + (c = getc( replication_yyin )) != EOF && c != '\n'; ++n ) \ + buf[n] = (char) c; \ + if ( c == '\n' ) \ + buf[n++] = (char) c; \ + if ( c == EOF && ferror( replication_yyin ) ) \ + YY_FATAL_ERROR( "input in flex scanner failed" ); \ + result = n; \ + } \ + else \ + { \ + errno=0; \ + while ( (result = fread(buf, 1, max_size, replication_yyin))==0 && ferror(replication_yyin)) \ + { \ + if( errno != EINTR) \ + { \ + YY_FATAL_ERROR( "input in flex scanner failed" ); \ + break; \ + } \ + errno=0; \ + clearerr(replication_yyin); \ + } \ + }\ +\ + +#endif + +/* No semi-colon after return; correct usage is to write "yyterminate();" - + * we don't want an extra ';' after the "return" because that will cause + * some compilers to complain about unreachable statements. + */ +#ifndef yyterminate +#define yyterminate() return YY_NULL +#endif + +/* Number of entries by which start-condition stack grows. */ +#ifndef YY_START_STACK_INCR +#define YY_START_STACK_INCR 25 +#endif + +/* Report a fatal error. */ +#ifndef YY_FATAL_ERROR +#define YY_FATAL_ERROR(msg) yy_fatal_error( msg ) +#endif + +/* end tables serialization structures and prototypes */ + +/* Default declaration of generated scanner - a define so the user can + * easily add parameters. + */ +#ifndef YY_DECL +#define YY_DECL_IS_OURS 1 + +extern int replication_yylex (void); + +#define YY_DECL int replication_yylex (void) +#endif /* !YY_DECL */ + +/* Code executed at the beginning of each rule, after replication_yytext and replication_yyleng + * have been set up. + */ +#ifndef YY_USER_ACTION +#define YY_USER_ACTION +#endif + +/* Code executed at the end of each rule. */ +#ifndef YY_BREAK +#define YY_BREAK break; +#endif + +#define YY_RULE_SETUP \ + YY_USER_ACTION + +/** The main scanner function which does all the work. + */ +YY_DECL +{ + register yy_state_type yy_current_state; + register char *yy_cp, *yy_bp; + register int yy_act; + +#line 57 "repl_scanner.l" + + +#line 774 "repl_scanner.c" + + if ( !(yy_init) ) + { + (yy_init) = 1; + +#ifdef YY_USER_INIT + YY_USER_INIT; +#endif + + if ( ! (yy_start) ) + (yy_start) = 1; /* first start state */ + + if ( ! replication_yyin ) + replication_yyin = stdin; + + if ( ! replication_yyout ) + replication_yyout = stdout; + + if ( ! YY_CURRENT_BUFFER ) { + replication_yyensure_buffer_stack (); + YY_CURRENT_BUFFER_LVALUE = + replication_yy_create_buffer(replication_yyin,YY_BUF_SIZE ); + } + + replication_yy_load_buffer_state( ); + } + + while ( 1 ) /* loops until end-of-file is reached */ + { + yy_cp = (yy_c_buf_p); + + /* Support of replication_yytext. */ + *yy_cp = (yy_hold_char); + + /* yy_bp points to the position in yy_ch_buf of the start of + * the current run. + */ + yy_bp = yy_cp; + + yy_current_state = (yy_start); +yy_match: + do + { + register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)]; + if ( yy_accept[yy_current_state] ) + { + (yy_last_accepting_state) = yy_current_state; + (yy_last_accepting_cpos) = yy_cp; + } + while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) + { + yy_current_state = (int) yy_def[yy_current_state]; + if ( yy_current_state >= 91 ) + yy_c = yy_meta[(unsigned int) yy_c]; + } + yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; + ++yy_cp; + } + while ( yy_current_state != 90 ); + yy_cp = (yy_last_accepting_cpos); + yy_current_state = (yy_last_accepting_state); + +yy_find_action: + yy_act = yy_accept[yy_current_state]; + + YY_DO_BEFORE_ACTION; + +do_action: /* This label is used only to access EOF actions. */ + + switch ( yy_act ) + { /* beginning of action switch */ + case 0: /* must back up */ + /* undo the effects of YY_DO_BEFORE_ACTION */ + *yy_cp = (yy_hold_char); + yy_cp = (yy_last_accepting_cpos); + yy_current_state = (yy_last_accepting_state); + goto yy_find_action; + +case 1: +YY_RULE_SETUP +#line 59 "repl_scanner.l" +{ return K_BASE_BACKUP; } + YY_BREAK +case 2: +YY_RULE_SETUP +#line 60 "repl_scanner.l" +{ return K_FAST; } + YY_BREAK +case 3: +YY_RULE_SETUP +#line 61 "repl_scanner.l" +{ return K_IDENTIFY_SYSTEM; } + YY_BREAK +case 4: +YY_RULE_SETUP +#line 62 "repl_scanner.l" +{ return K_LABEL; } + YY_BREAK +case 5: +YY_RULE_SETUP +#line 63 "repl_scanner.l" +{ return K_NOWAIT; } + YY_BREAK +case 6: +YY_RULE_SETUP +#line 64 "repl_scanner.l" +{ return K_PROGRESS; } + YY_BREAK +case 7: +YY_RULE_SETUP +#line 65 "repl_scanner.l" +{ return K_WAL; } + YY_BREAK +case 8: +YY_RULE_SETUP +#line 66 "repl_scanner.l" +{ return K_START_REPLICATION; } + YY_BREAK +case 9: +YY_RULE_SETUP +#line 67 "repl_scanner.l" +{ return ','; } + YY_BREAK +case 10: +YY_RULE_SETUP +#line 68 "repl_scanner.l" +{ return ';'; } + YY_BREAK +case 11: +/* rule 11 can match eol */ +YY_RULE_SETUP +#line 70 "repl_scanner.l" +; + YY_BREAK +case 12: +YY_RULE_SETUP +#line 71 "repl_scanner.l" +; + YY_BREAK +case 13: +YY_RULE_SETUP +#line 72 "repl_scanner.l" +; + YY_BREAK +case 14: +YY_RULE_SETUP +#line 74 "repl_scanner.l" +{ + if (sscanf(replication_yytext, "%X/%X", &yylval.recptr.xlogid, &yylval.recptr.xrecoff) != 2) + yyerror("invalid streaming start location"); + return RECPTR; + } + YY_BREAK +case 15: +YY_RULE_SETUP +#line 80 "repl_scanner.l" +{ + BEGIN(xq); + startlit(); + } + YY_BREAK +case 16: +YY_RULE_SETUP +#line 84 "repl_scanner.l" +{ + yyless(1); + BEGIN(INITIAL); + yylval.str = litbufdup(); + return SCONST; + } + YY_BREAK +case 17: +YY_RULE_SETUP +#line 90 "repl_scanner.l" +{ + addlitchar('\''); + } + YY_BREAK +case 18: +/* rule 18 can match eol */ +YY_RULE_SETUP +#line 93 "repl_scanner.l" +{ + addlit(replication_yytext, replication_yyleng); + } + YY_BREAK +case YY_STATE_EOF(xq): +#line 97 "repl_scanner.l" +{ yyerror("unterminated quoted string"); } + YY_BREAK +case YY_STATE_EOF(INITIAL): +#line 100 "repl_scanner.l" +{ + yyterminate(); + } + YY_BREAK +case 19: +YY_RULE_SETUP +#line 104 "repl_scanner.l" +{ + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("syntax error: unexpected character \"%s\"", replication_yytext))); + } + YY_BREAK +case 20: +YY_RULE_SETUP +#line 109 "repl_scanner.l" +YY_FATAL_ERROR( "flex scanner jammed" ); + YY_BREAK +#line 985 "repl_scanner.c" + + case YY_END_OF_BUFFER: + { + /* Amount of text matched not including the EOB char. */ + int yy_amount_of_matched_text = (int) (yy_cp - (yytext_ptr)) - 1; + + /* Undo the effects of YY_DO_BEFORE_ACTION. */ + *yy_cp = (yy_hold_char); + YY_RESTORE_YY_MORE_OFFSET + + if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW ) + { + /* We're scanning a new file or input source. It's + * possible that this happened because the user + * just pointed replication_yyin at a new source and called + * replication_yylex(). If so, then we have to assure + * consistency between YY_CURRENT_BUFFER and our + * globals. Here is the right place to do so, because + * this is the first action (other than possibly a + * back-up) that will match for the new input source. + */ + (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars; + YY_CURRENT_BUFFER_LVALUE->yy_input_file = replication_yyin; + YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL; + } + + /* Note that here we test for yy_c_buf_p "<=" to the position + * of the first EOB in the buffer, since yy_c_buf_p will + * already have been incremented past the NUL character + * (since all states make transitions on EOB to the + * end-of-buffer state). Contrast this with the test + * in input(). + */ + if ( (yy_c_buf_p) <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] ) + { /* This was really a NUL. */ + yy_state_type yy_next_state; + + (yy_c_buf_p) = (yytext_ptr) + yy_amount_of_matched_text; + + yy_current_state = yy_get_previous_state( ); + + /* Okay, we're now positioned to make the NUL + * transition. We couldn't have + * yy_get_previous_state() go ahead and do it + * for us because it doesn't know how to deal + * with the possibility of jamming (and we don't + * want to build jamming into it because then it + * will run more slowly). + */ + + yy_next_state = yy_try_NUL_trans( yy_current_state ); + + yy_bp = (yytext_ptr) + YY_MORE_ADJ; + + if ( yy_next_state ) + { + /* Consume the NUL. */ + yy_cp = ++(yy_c_buf_p); + yy_current_state = yy_next_state; + goto yy_match; + } + + else + { + yy_cp = (yy_last_accepting_cpos); + yy_current_state = (yy_last_accepting_state); + goto yy_find_action; + } + } + + else switch ( yy_get_next_buffer( ) ) + { + case EOB_ACT_END_OF_FILE: + { + (yy_did_buffer_switch_on_eof) = 0; + + if ( replication_yywrap( ) ) + { + /* Note: because we've taken care in + * yy_get_next_buffer() to have set up + * replication_yytext, we can now set up + * yy_c_buf_p so that if some total + * hoser (like flex itself) wants to + * call the scanner after we return the + * YY_NULL, it'll still work - another + * YY_NULL will get returned. + */ + (yy_c_buf_p) = (yytext_ptr) + YY_MORE_ADJ; + + yy_act = YY_STATE_EOF(YY_START); + goto do_action; + } + + else + { + if ( ! (yy_did_buffer_switch_on_eof) ) + YY_NEW_FILE; + } + break; + } + + case EOB_ACT_CONTINUE_SCAN: + (yy_c_buf_p) = + (yytext_ptr) + yy_amount_of_matched_text; + + yy_current_state = yy_get_previous_state( ); + + yy_cp = (yy_c_buf_p); + yy_bp = (yytext_ptr) + YY_MORE_ADJ; + goto yy_match; + + case EOB_ACT_LAST_MATCH: + (yy_c_buf_p) = + &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)]; + + yy_current_state = yy_get_previous_state( ); + + yy_cp = (yy_c_buf_p); + yy_bp = (yytext_ptr) + YY_MORE_ADJ; + goto yy_find_action; + } + break; + } + + default: + YY_FATAL_ERROR( + "fatal flex scanner internal error--no action found" ); + } /* end of action switch */ + } /* end of scanning one token */ +} /* end of replication_yylex */ + +/* yy_get_next_buffer - try to read in a new buffer + * + * Returns a code representing an action: + * EOB_ACT_LAST_MATCH - + * EOB_ACT_CONTINUE_SCAN - continue scanning from current position + * EOB_ACT_END_OF_FILE - end of file + */ +static int yy_get_next_buffer (void) +{ + register char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf; + register char *source = (yytext_ptr); + register int number_to_move, i; + int ret_val; + + if ( (yy_c_buf_p) > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] ) + YY_FATAL_ERROR( + "fatal flex scanner internal error--end of buffer missed" ); + + if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 ) + { /* Don't try to fill the buffer, so this is an EOF. */ + if ( (yy_c_buf_p) - (yytext_ptr) - YY_MORE_ADJ == 1 ) + { + /* We matched a single character, the EOB, so + * treat this as a final EOF. + */ + return EOB_ACT_END_OF_FILE; + } + + else + { + /* We matched some text prior to the EOB, first + * process it. + */ + return EOB_ACT_LAST_MATCH; + } + } + + /* Try to read more data. */ + + /* First move last chars to start of buffer. */ + number_to_move = (int) ((yy_c_buf_p) - (yytext_ptr)) - 1; + + for ( i = 0; i < number_to_move; ++i ) + *(dest++) = *(source++); + + if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING ) + /* don't do the read, it's not guaranteed to return an EOF, + * just force an EOF + */ + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars) = 0; + + else + { + int num_to_read = + YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1; + + while ( num_to_read <= 0 ) + { /* Not enough room in the buffer - grow it. */ + + /* just a shorter name for the current buffer */ + YY_BUFFER_STATE b = YY_CURRENT_BUFFER; + + int yy_c_buf_p_offset = + (int) ((yy_c_buf_p) - b->yy_ch_buf); + + if ( b->yy_is_our_buffer ) + { + int new_size = b->yy_buf_size * 2; + + if ( new_size <= 0 ) + b->yy_buf_size += b->yy_buf_size / 8; + else + b->yy_buf_size *= 2; + + b->yy_ch_buf = (char *) + /* Include room in for 2 EOB chars. */ + replication_yyrealloc((void *) b->yy_ch_buf,b->yy_buf_size + 2 ); + } + else + /* Can't grow it, we don't own it. */ + b->yy_ch_buf = 0; + + if ( ! b->yy_ch_buf ) + YY_FATAL_ERROR( + "fatal error - scanner input buffer overflow" ); + + (yy_c_buf_p) = &b->yy_ch_buf[yy_c_buf_p_offset]; + + num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size - + number_to_move - 1; + + } + + if ( num_to_read > YY_READ_BUF_SIZE ) + num_to_read = YY_READ_BUF_SIZE; + + /* Read in more data. */ + YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]), + (yy_n_chars), (size_t) num_to_read ); + + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); + } + + if ( (yy_n_chars) == 0 ) + { + if ( number_to_move == YY_MORE_ADJ ) + { + ret_val = EOB_ACT_END_OF_FILE; + replication_yyrestart(replication_yyin ); + } + + else + { + ret_val = EOB_ACT_LAST_MATCH; + YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = + YY_BUFFER_EOF_PENDING; + } + } + + else + ret_val = EOB_ACT_CONTINUE_SCAN; + + if ((yy_size_t) ((yy_n_chars) + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) { + /* Extend the array by 50%, plus the number we really need. */ + yy_size_t new_size = (yy_n_chars) + number_to_move + ((yy_n_chars) >> 1); + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) replication_yyrealloc((void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,new_size ); + if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf ) + YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" ); + } + + (yy_n_chars) += number_to_move; + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] = YY_END_OF_BUFFER_CHAR; + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] = YY_END_OF_BUFFER_CHAR; + + (yytext_ptr) = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0]; + + return ret_val; +} + +/* yy_get_previous_state - get the state just before the EOB char was reached */ + + static yy_state_type yy_get_previous_state (void) +{ + register yy_state_type yy_current_state; + register char *yy_cp; + + yy_current_state = (yy_start); + + for ( yy_cp = (yytext_ptr) + YY_MORE_ADJ; yy_cp < (yy_c_buf_p); ++yy_cp ) + { + register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1); + if ( yy_accept[yy_current_state] ) + { + (yy_last_accepting_state) = yy_current_state; + (yy_last_accepting_cpos) = yy_cp; + } + while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) + { + yy_current_state = (int) yy_def[yy_current_state]; + if ( yy_current_state >= 91 ) + yy_c = yy_meta[(unsigned int) yy_c]; + } + yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; + } + + return yy_current_state; +} + +/* yy_try_NUL_trans - try to make a transition on the NUL character + * + * synopsis + * next_state = yy_try_NUL_trans( current_state ); + */ + static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state ) +{ + register int yy_is_jam; + register char *yy_cp = (yy_c_buf_p); + + register YY_CHAR yy_c = 1; + if ( yy_accept[yy_current_state] ) + { + (yy_last_accepting_state) = yy_current_state; + (yy_last_accepting_cpos) = yy_cp; + } + while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) + { + yy_current_state = (int) yy_def[yy_current_state]; + if ( yy_current_state >= 91 ) + yy_c = yy_meta[(unsigned int) yy_c]; + } + yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; + yy_is_jam = (yy_current_state == 90); + + return yy_is_jam ? 0 : yy_current_state; +} + +#ifndef YY_NO_INPUT +#ifdef __cplusplus + static int yyinput (void) +#else + static int input (void) +#endif + +{ + int c; + + *(yy_c_buf_p) = (yy_hold_char); + + if ( *(yy_c_buf_p) == YY_END_OF_BUFFER_CHAR ) + { + /* yy_c_buf_p now points to the character we want to return. + * If this occurs *before* the EOB characters, then it's a + * valid NUL; if not, then we've hit the end of the buffer. + */ + if ( (yy_c_buf_p) < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] ) + /* This was really a NUL. */ + *(yy_c_buf_p) = '\0'; + + else + { /* need more input */ + int offset = (yy_c_buf_p) - (yytext_ptr); + ++(yy_c_buf_p); + + switch ( yy_get_next_buffer( ) ) + { + case EOB_ACT_LAST_MATCH: + /* This happens because yy_g_n_b() + * sees that we've accumulated a + * token and flags that we need to + * try matching the token before + * proceeding. But for input(), + * there's no matching to consider. + * So convert the EOB_ACT_LAST_MATCH + * to EOB_ACT_END_OF_FILE. + */ + + /* Reset buffer status. */ + replication_yyrestart(replication_yyin ); + + /*FALLTHROUGH*/ + + case EOB_ACT_END_OF_FILE: + { + if ( replication_yywrap( ) ) + return EOF; + + if ( ! (yy_did_buffer_switch_on_eof) ) + YY_NEW_FILE; +#ifdef __cplusplus + return yyinput(); +#else + return input(); +#endif + } + + case EOB_ACT_CONTINUE_SCAN: + (yy_c_buf_p) = (yytext_ptr) + offset; + break; + } + } + } + + c = *(unsigned char *) (yy_c_buf_p); /* cast for 8-bit char's */ + *(yy_c_buf_p) = '\0'; /* preserve replication_yytext */ + (yy_hold_char) = *++(yy_c_buf_p); + + return c; +} +#endif /* ifndef YY_NO_INPUT */ + +/** Immediately switch to a different input stream. + * @param input_file A readable stream. + * + * @note This function does not reset the start condition to @c INITIAL . + */ + void replication_yyrestart (FILE * input_file ) +{ + + if ( ! YY_CURRENT_BUFFER ){ + replication_yyensure_buffer_stack (); + YY_CURRENT_BUFFER_LVALUE = + replication_yy_create_buffer(replication_yyin,YY_BUF_SIZE ); + } + + replication_yy_init_buffer(YY_CURRENT_BUFFER,input_file ); + replication_yy_load_buffer_state( ); +} + +/** Switch to a different input buffer. + * @param new_buffer The new input buffer. + * + */ + void replication_yy_switch_to_buffer (YY_BUFFER_STATE new_buffer ) +{ + + /* TODO. We should be able to replace this entire function body + * with + * replication_yypop_buffer_state(); + * replication_yypush_buffer_state(new_buffer); + */ + replication_yyensure_buffer_stack (); + if ( YY_CURRENT_BUFFER == new_buffer ) + return; + + if ( YY_CURRENT_BUFFER ) + { + /* Flush out information for old buffer. */ + *(yy_c_buf_p) = (yy_hold_char); + YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p); + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); + } + + YY_CURRENT_BUFFER_LVALUE = new_buffer; + replication_yy_load_buffer_state( ); + + /* We don't actually know whether we did this switch during + * EOF (replication_yywrap()) processing, but the only time this flag + * is looked at is after replication_yywrap() is called, so it's safe + * to go ahead and always set it. + */ + (yy_did_buffer_switch_on_eof) = 1; +} + +static void replication_yy_load_buffer_state (void) +{ + (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars; + (yytext_ptr) = (yy_c_buf_p) = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos; + replication_yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file; + (yy_hold_char) = *(yy_c_buf_p); +} + +/** Allocate and initialize an input buffer state. + * @param file A readable stream. + * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE. + * + * @return the allocated buffer state. + */ + YY_BUFFER_STATE replication_yy_create_buffer (FILE * file, int size ) +{ + YY_BUFFER_STATE b; + + b = (YY_BUFFER_STATE) replication_yyalloc(sizeof( struct yy_buffer_state ) ); + if ( ! b ) + YY_FATAL_ERROR( "out of dynamic memory in replication_yy_create_buffer()" ); + + b->yy_buf_size = size; + + /* yy_ch_buf has to be 2 characters longer than the size given because + * we need to put in 2 end-of-buffer characters. + */ + b->yy_ch_buf = (char *) replication_yyalloc(b->yy_buf_size + 2 ); + if ( ! b->yy_ch_buf ) + YY_FATAL_ERROR( "out of dynamic memory in replication_yy_create_buffer()" ); + + b->yy_is_our_buffer = 1; + + replication_yy_init_buffer(b,file ); + + return b; +} + +/** Destroy the buffer. + * @param b a buffer created with replication_yy_create_buffer() + * + */ + void replication_yy_delete_buffer (YY_BUFFER_STATE b ) +{ + + if ( ! b ) + return; + + if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */ + YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0; + + if ( b->yy_is_our_buffer ) + replication_yyfree((void *) b->yy_ch_buf ); + + replication_yyfree((void *) b ); +} + +/* Initializes or reinitializes a buffer. + * This function is sometimes called more than once on the same buffer, + * such as during a replication_yyrestart() or at EOF. + */ + static void replication_yy_init_buffer (YY_BUFFER_STATE b, FILE * file ) + +{ + int oerrno = errno; + + replication_yy_flush_buffer(b ); + + b->yy_input_file = file; + b->yy_fill_buffer = 1; + + /* If b is the current buffer, then replication_yy_init_buffer was _probably_ + * called from replication_yyrestart() or through yy_get_next_buffer. + * In that case, we don't want to reset the lineno or column. + */ + if (b != YY_CURRENT_BUFFER){ + b->yy_bs_lineno = 1; + b->yy_bs_column = 0; + } + + b->yy_is_interactive = 0; + + errno = oerrno; +} + +/** Discard all buffered characters. On the next scan, YY_INPUT will be called. + * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER. + * + */ + void replication_yy_flush_buffer (YY_BUFFER_STATE b ) +{ + if ( ! b ) + return; + + b->yy_n_chars = 0; + + /* We always need two end-of-buffer characters. The first causes + * a transition to the end-of-buffer state. The second causes + * a jam in that state. + */ + b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR; + b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR; + + b->yy_buf_pos = &b->yy_ch_buf[0]; + + b->yy_at_bol = 1; + b->yy_buffer_status = YY_BUFFER_NEW; + + if ( b == YY_CURRENT_BUFFER ) + replication_yy_load_buffer_state( ); +} + +/** Pushes the new state onto the stack. The new state becomes + * the current state. This function will allocate the stack + * if necessary. + * @param new_buffer The new state. + * + */ +void replication_yypush_buffer_state (YY_BUFFER_STATE new_buffer ) +{ + if (new_buffer == NULL) + return; + + replication_yyensure_buffer_stack(); + + /* This block is copied from replication_yy_switch_to_buffer. */ + if ( YY_CURRENT_BUFFER ) + { + /* Flush out information for old buffer. */ + *(yy_c_buf_p) = (yy_hold_char); + YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p); + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); + } + + /* Only push if top exists. Otherwise, replace top. */ + if (YY_CURRENT_BUFFER) + (yy_buffer_stack_top)++; + YY_CURRENT_BUFFER_LVALUE = new_buffer; + + /* copied from replication_yy_switch_to_buffer. */ + replication_yy_load_buffer_state( ); + (yy_did_buffer_switch_on_eof) = 1; +} + +/** Removes and deletes the top of the stack, if present. + * The next element becomes the new top. + * + */ +void replication_yypop_buffer_state (void) +{ + if (!YY_CURRENT_BUFFER) + return; + + replication_yy_delete_buffer(YY_CURRENT_BUFFER ); + YY_CURRENT_BUFFER_LVALUE = NULL; + if ((yy_buffer_stack_top) > 0) + --(yy_buffer_stack_top); + + if (YY_CURRENT_BUFFER) { + replication_yy_load_buffer_state( ); + (yy_did_buffer_switch_on_eof) = 1; + } +} + +/* Allocates the stack if it does not exist. + * Guarantees space for at least one push. + */ +static void replication_yyensure_buffer_stack (void) +{ + int num_to_alloc; + + if (!(yy_buffer_stack)) { + + /* First allocation is just for 2 elements, since we don't know if this + * scanner will even need a stack. We use 2 instead of 1 to avoid an + * immediate realloc on the next call. + */ + num_to_alloc = 1; + (yy_buffer_stack) = (struct yy_buffer_state**)replication_yyalloc + (num_to_alloc * sizeof(struct yy_buffer_state*) + ); + if ( ! (yy_buffer_stack) ) + YY_FATAL_ERROR( "out of dynamic memory in replication_yyensure_buffer_stack()" ); + + memset((yy_buffer_stack), 0, num_to_alloc * sizeof(struct yy_buffer_state*)); + + (yy_buffer_stack_max) = num_to_alloc; + (yy_buffer_stack_top) = 0; + return; + } + + if ((yy_buffer_stack_top) >= ((yy_buffer_stack_max)) - 1){ + + /* Increase the buffer to prepare for a possible push. */ + int grow_size = 8 /* arbitrary grow size */; + + num_to_alloc = (yy_buffer_stack_max) + grow_size; + (yy_buffer_stack) = (struct yy_buffer_state**)replication_yyrealloc + ((yy_buffer_stack), + num_to_alloc * sizeof(struct yy_buffer_state*) + ); + if ( ! (yy_buffer_stack) ) + YY_FATAL_ERROR( "out of dynamic memory in replication_yyensure_buffer_stack()" ); + + /* zero only the new slots.*/ + memset((yy_buffer_stack) + (yy_buffer_stack_max), 0, grow_size * sizeof(struct yy_buffer_state*)); + (yy_buffer_stack_max) = num_to_alloc; + } +} + +/** Setup the input buffer state to scan directly from a user-specified character buffer. + * @param base the character buffer + * @param size the size in bytes of the character buffer + * + * @return the newly allocated buffer state object. + */ +YY_BUFFER_STATE replication_yy_scan_buffer (char * base, yy_size_t size ) +{ + YY_BUFFER_STATE b; + + if ( size < 2 || + base[size-2] != YY_END_OF_BUFFER_CHAR || + base[size-1] != YY_END_OF_BUFFER_CHAR ) + /* They forgot to leave room for the EOB's. */ + return 0; + + b = (YY_BUFFER_STATE) replication_yyalloc(sizeof( struct yy_buffer_state ) ); + if ( ! b ) + YY_FATAL_ERROR( "out of dynamic memory in replication_yy_scan_buffer()" ); + + b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */ + b->yy_buf_pos = b->yy_ch_buf = base; + b->yy_is_our_buffer = 0; + b->yy_input_file = 0; + b->yy_n_chars = b->yy_buf_size; + b->yy_is_interactive = 0; + b->yy_at_bol = 1; + b->yy_fill_buffer = 0; + b->yy_buffer_status = YY_BUFFER_NEW; + + replication_yy_switch_to_buffer(b ); + + return b; +} + +/** Setup the input buffer state to scan a string. The next call to replication_yylex() will + * scan from a @e copy of @a str. + * @param yystr a NUL-terminated string to scan + * + * @return the newly allocated buffer state object. + * @note If you want to scan bytes that may contain NUL values, then use + * replication_yy_scan_bytes() instead. + */ +YY_BUFFER_STATE replication_yy_scan_string (yyconst char * yystr ) +{ + + return replication_yy_scan_bytes(yystr,strlen(yystr) ); +} + +/** Setup the input buffer state to scan the given bytes. The next call to replication_yylex() will + * scan from a @e copy of @a bytes. + * @param yybytes the byte buffer to scan + * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes. + * + * @return the newly allocated buffer state object. + */ +YY_BUFFER_STATE replication_yy_scan_bytes (yyconst char * yybytes, int _yybytes_len ) +{ + YY_BUFFER_STATE b; + char *buf; + yy_size_t n; + int i; + + /* Get memory for full buffer, including space for trailing EOB's. */ + n = _yybytes_len + 2; + buf = (char *) replication_yyalloc(n ); + if ( ! buf ) + YY_FATAL_ERROR( "out of dynamic memory in replication_yy_scan_bytes()" ); + + for ( i = 0; i < _yybytes_len; ++i ) + buf[i] = yybytes[i]; + + buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR; + + b = replication_yy_scan_buffer(buf,n ); + if ( ! b ) + YY_FATAL_ERROR( "bad buffer in replication_yy_scan_bytes()" ); + + /* It's okay to grow etc. this buffer, and we should throw it + * away when we're done. + */ + b->yy_is_our_buffer = 1; + + return b; +} + +#ifndef YY_EXIT_FAILURE +#define YY_EXIT_FAILURE 2 +#endif + +static void yy_fatal_error (yyconst char* msg ) +{ + (void) fprintf( stderr, "%s\n", msg ); + exit( YY_EXIT_FAILURE ); +} + +/* Redefine yyless() so it works in section 3 code. */ + +#undef yyless +#define yyless(n) \ + do \ + { \ + /* Undo effects of setting up replication_yytext. */ \ + int yyless_macro_arg = (n); \ + YY_LESS_LINENO(yyless_macro_arg);\ + replication_yytext[replication_yyleng] = (yy_hold_char); \ + (yy_c_buf_p) = replication_yytext + yyless_macro_arg; \ + (yy_hold_char) = *(yy_c_buf_p); \ + *(yy_c_buf_p) = '\0'; \ + replication_yyleng = yyless_macro_arg; \ + } \ + while ( 0 ) + +/* Accessor methods (get/set functions) to struct members. */ + +/** Get the current line number. + * + */ +int replication_yyget_lineno (void) +{ + + return replication_yylineno; +} + +/** Get the input stream. + * + */ +FILE *replication_yyget_in (void) +{ + return replication_yyin; +} + +/** Get the output stream. + * + */ +FILE *replication_yyget_out (void) +{ + return replication_yyout; +} + +/** Get the length of the current token. + * + */ +int replication_yyget_leng (void) +{ + return replication_yyleng; +} + +/** Get the current token. + * + */ + +char *replication_yyget_text (void) +{ + return replication_yytext; +} + +/** Set the current line number. + * @param line_number + * + */ +void replication_yyset_lineno (int line_number ) +{ + + replication_yylineno = line_number; +} + +/** Set the input stream. This does not discard the current + * input buffer. + * @param in_str A readable stream. + * + * @see replication_yy_switch_to_buffer + */ +void replication_yyset_in (FILE * in_str ) +{ + replication_yyin = in_str ; +} + +void replication_yyset_out (FILE * out_str ) +{ + replication_yyout = out_str ; +} + +int replication_yyget_debug (void) +{ + return replication_yy_flex_debug; +} + +void replication_yyset_debug (int bdebug ) +{ + replication_yy_flex_debug = bdebug ; +} + +static int yy_init_globals (void) +{ + /* Initialization is the same as for the non-reentrant scanner. + * This function is called from replication_yylex_destroy(), so don't allocate here. + */ + + (yy_buffer_stack) = 0; + (yy_buffer_stack_top) = 0; + (yy_buffer_stack_max) = 0; + (yy_c_buf_p) = (char *) 0; + (yy_init) = 0; + (yy_start) = 0; + +/* Defined in main.c */ +#ifdef YY_STDINIT + replication_yyin = stdin; + replication_yyout = stdout; +#else + replication_yyin = (FILE *) 0; + replication_yyout = (FILE *) 0; +#endif + + /* For future reference: Set errno on error, since we are called by + * replication_yylex_init() + */ + return 0; +} + +/* replication_yylex_destroy is for both reentrant and non-reentrant scanners. */ +int replication_yylex_destroy (void) +{ + + /* Pop the buffer stack, destroying each element. */ + while(YY_CURRENT_BUFFER){ + replication_yy_delete_buffer(YY_CURRENT_BUFFER ); + YY_CURRENT_BUFFER_LVALUE = NULL; + replication_yypop_buffer_state(); + } + + /* Destroy the stack itself. */ + replication_yyfree((yy_buffer_stack) ); + (yy_buffer_stack) = NULL; + + /* Reset the globals. This is important in a non-reentrant scanner so the next time + * replication_yylex() is called, initialization will occur. */ + yy_init_globals( ); + + return 0; +} + +/* + * Internal utility routines. + */ + +#ifndef yytext_ptr +static void yy_flex_strncpy (char* s1, yyconst char * s2, int n ) +{ + register int i; + for ( i = 0; i < n; ++i ) + s1[i] = s2[i]; +} +#endif + +#ifdef YY_NEED_STRLEN +static int yy_flex_strlen (yyconst char * s ) +{ + register int n; + for ( n = 0; s[n]; ++n ) + ; + + return n; +} +#endif + +void *replication_yyalloc (yy_size_t size ) +{ + return (void *) malloc( size ); +} + +void *replication_yyrealloc (void * ptr, yy_size_t size ) +{ + /* The cast to (char *) in the following accommodates both + * implementations that use char* generic pointers, and those + * that use void* generic pointers. It works with the latter + * because both ANSI C and C++ allow castless assignment from + * any pointer type to void*, and deal with argument conversions + * as though doing an assignment. + */ + return (void *) realloc( (char *) ptr, size ); +} + +void replication_yyfree (void * ptr ) +{ + free( (char *) ptr ); /* see replication_yyrealloc() for (char *) cast */ +} + +#define YYTABLES_NAME "yytables" + +#line 109 "repl_scanner.l" + + + + +static void +startlit(void) +{ + initStringInfo(&litbuf); +} + +static char * +litbufdup(void) +{ + return litbuf.data; +} + +static void +addlit(char *ytext, int yleng) +{ + appendBinaryStringInfo(&litbuf, ytext, yleng); +} + +static void +addlitchar(unsigned char ychar) +{ + appendStringInfoChar(&litbuf, ychar); +} + +void +yyerror(const char *message) +{ + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg_internal("%s", message))); +} + + +void +replication_scanner_init(const char *str) +{ + Size slen = strlen(str); + char *scanbuf; + + /* + * Might be left over after ereport() + */ + if (YY_CURRENT_BUFFER) + replication_yy_delete_buffer(YY_CURRENT_BUFFER); + + /* + * Make a scan buffer with special termination needed by flex. + */ + scanbuf = (char *) palloc(slen + 2); + memcpy(scanbuf, str, slen); + scanbuf[slen] = scanbuf[slen + 1] = YY_END_OF_BUFFER_CHAR; + scanbufhandle = replication_yy_scan_buffer(scanbuf,slen + 2); +} + +void +replication_scanner_finish() +{ + replication_yy_delete_buffer(scanbufhandle); + scanbufhandle = NULL; +} + diff --git a/src/backend/snowball/.gitignore b/src/backend/snowball/.gitignore deleted file mode 100644 index ef03eb62a..000000000 --- a/src/backend/snowball/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/snowball_create.sql diff --git a/src/backend/utils/.gitignore b/src/backend/utils/.gitignore deleted file mode 100644 index 5c3a565ba..000000000 --- a/src/backend/utils/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -/fmgrtab.c -/fmgroids.h -/probes.h -/errcodes.h diff --git a/src/backend/utils/errcodes.h b/src/backend/utils/errcodes.h new file mode 100644 index 000000000..03b9a7144 --- /dev/null +++ b/src/backend/utils/errcodes.h @@ -0,0 +1,324 @@ +/* autogenerated from src/backend/utils/errcodes.txt, do not edit */ +/* there is deliberately not an #ifndef ERRCODES_H here */ + +/* Class 00 - Successful Completion */ +#define ERRCODE_SUCCESSFUL_COMPLETION MAKE_SQLSTATE('0','0','0','0','0') + +/* Class 01 - Warning */ +#define ERRCODE_WARNING MAKE_SQLSTATE('0','1','0','0','0') +#define ERRCODE_WARNING_DYNAMIC_RESULT_SETS_RETURNED MAKE_SQLSTATE('0','1','0','0','C') +#define ERRCODE_WARNING_IMPLICIT_ZERO_BIT_PADDING MAKE_SQLSTATE('0','1','0','0','8') +#define ERRCODE_WARNING_NULL_VALUE_ELIMINATED_IN_SET_FUNCTION MAKE_SQLSTATE('0','1','0','0','3') +#define ERRCODE_WARNING_PRIVILEGE_NOT_GRANTED MAKE_SQLSTATE('0','1','0','0','7') +#define ERRCODE_WARNING_PRIVILEGE_NOT_REVOKED MAKE_SQLSTATE('0','1','0','0','6') +#define ERRCODE_WARNING_STRING_DATA_RIGHT_TRUNCATION MAKE_SQLSTATE('0','1','0','0','4') +#define ERRCODE_WARNING_DEPRECATED_FEATURE MAKE_SQLSTATE('0','1','P','0','1') + +/* Class 02 - No Data (this is also a warning class per the SQL standard) */ +#define ERRCODE_NO_DATA MAKE_SQLSTATE('0','2','0','0','0') +#define ERRCODE_NO_ADDITIONAL_DYNAMIC_RESULT_SETS_RETURNED MAKE_SQLSTATE('0','2','0','0','1') + +/* Class 03 - SQL Statement Not Yet Complete */ +#define ERRCODE_SQL_STATEMENT_NOT_YET_COMPLETE MAKE_SQLSTATE('0','3','0','0','0') + +/* Class 08 - Connection Exception */ +#define ERRCODE_CONNECTION_EXCEPTION MAKE_SQLSTATE('0','8','0','0','0') +#define ERRCODE_CONNECTION_DOES_NOT_EXIST MAKE_SQLSTATE('0','8','0','0','3') +#define ERRCODE_CONNECTION_FAILURE MAKE_SQLSTATE('0','8','0','0','6') +#define ERRCODE_SQLCLIENT_UNABLE_TO_ESTABLISH_SQLCONNECTION MAKE_SQLSTATE('0','8','0','0','1') +#define ERRCODE_SQLSERVER_REJECTED_ESTABLISHMENT_OF_SQLCONNECTION MAKE_SQLSTATE('0','8','0','0','4') +#define ERRCODE_TRANSACTION_RESOLUTION_UNKNOWN MAKE_SQLSTATE('0','8','0','0','7') +#define ERRCODE_PROTOCOL_VIOLATION MAKE_SQLSTATE('0','8','P','0','1') + +/* Class 09 - Triggered Action Exception */ +#define ERRCODE_TRIGGERED_ACTION_EXCEPTION MAKE_SQLSTATE('0','9','0','0','0') + +/* Class 0A - Feature Not Supported */ +#define ERRCODE_FEATURE_NOT_SUPPORTED MAKE_SQLSTATE('0','A','0','0','0') + +/* Class 0B - Invalid Transaction Initiation */ +#define ERRCODE_INVALID_TRANSACTION_INITIATION MAKE_SQLSTATE('0','B','0','0','0') + +/* Class 0F - Locator Exception */ +#define ERRCODE_LOCATOR_EXCEPTION MAKE_SQLSTATE('0','F','0','0','0') +#define ERRCODE_L_E_INVALID_SPECIFICATION MAKE_SQLSTATE('0','F','0','0','1') + +/* Class 0L - Invalid Grantor */ +#define ERRCODE_INVALID_GRANTOR MAKE_SQLSTATE('0','L','0','0','0') +#define ERRCODE_INVALID_GRANT_OPERATION MAKE_SQLSTATE('0','L','P','0','1') + +/* Class 0P - Invalid Role Specification */ +#define ERRCODE_INVALID_ROLE_SPECIFICATION MAKE_SQLSTATE('0','P','0','0','0') + +/* Class 0Z - Diagnostics Exception */ +#define ERRCODE_DIAGNOSTICS_EXCEPTION MAKE_SQLSTATE('0','Z','0','0','0') +#define ERRCODE_STACKED_DIAGNOSTICS_ACCESSED_WITHOUT_ACTIVE_HANDLER MAKE_SQLSTATE('0','Z','0','0','2') + +/* Class 20 - Case Not Found */ +#define ERRCODE_CASE_NOT_FOUND MAKE_SQLSTATE('2','0','0','0','0') + +/* Class 21 - Cardinality Violation */ +#define ERRCODE_CARDINALITY_VIOLATION MAKE_SQLSTATE('2','1','0','0','0') + +/* Class 22 - Data Exception */ +#define ERRCODE_DATA_EXCEPTION MAKE_SQLSTATE('2','2','0','0','0') +#define ERRCODE_ARRAY_ELEMENT_ERROR MAKE_SQLSTATE('2','2','0','2','E') +#define ERRCODE_ARRAY_SUBSCRIPT_ERROR MAKE_SQLSTATE('2','2','0','2','E') +#define ERRCODE_CHARACTER_NOT_IN_REPERTOIRE MAKE_SQLSTATE('2','2','0','2','1') +#define ERRCODE_DATETIME_FIELD_OVERFLOW MAKE_SQLSTATE('2','2','0','0','8') +#define ERRCODE_DATETIME_VALUE_OUT_OF_RANGE MAKE_SQLSTATE('2','2','0','0','8') +#define ERRCODE_DIVISION_BY_ZERO MAKE_SQLSTATE('2','2','0','1','2') +#define ERRCODE_ERROR_IN_ASSIGNMENT MAKE_SQLSTATE('2','2','0','0','5') +#define ERRCODE_ESCAPE_CHARACTER_CONFLICT MAKE_SQLSTATE('2','2','0','0','B') +#define ERRCODE_INDICATOR_OVERFLOW MAKE_SQLSTATE('2','2','0','2','2') +#define ERRCODE_INTERVAL_FIELD_OVERFLOW MAKE_SQLSTATE('2','2','0','1','5') +#define ERRCODE_INVALID_ARGUMENT_FOR_LOG MAKE_SQLSTATE('2','2','0','1','E') +#define ERRCODE_INVALID_ARGUMENT_FOR_NTILE MAKE_SQLSTATE('2','2','0','1','4') +#define ERRCODE_INVALID_ARGUMENT_FOR_NTH_VALUE MAKE_SQLSTATE('2','2','0','1','6') +#define ERRCODE_INVALID_ARGUMENT_FOR_POWER_FUNCTION MAKE_SQLSTATE('2','2','0','1','F') +#define ERRCODE_INVALID_ARGUMENT_FOR_WIDTH_BUCKET_FUNCTION MAKE_SQLSTATE('2','2','0','1','G') +#define ERRCODE_INVALID_CHARACTER_VALUE_FOR_CAST MAKE_SQLSTATE('2','2','0','1','8') +#define ERRCODE_INVALID_DATETIME_FORMAT MAKE_SQLSTATE('2','2','0','0','7') +#define ERRCODE_INVALID_ESCAPE_CHARACTER MAKE_SQLSTATE('2','2','0','1','9') +#define ERRCODE_INVALID_ESCAPE_OCTET MAKE_SQLSTATE('2','2','0','0','D') +#define ERRCODE_INVALID_ESCAPE_SEQUENCE MAKE_SQLSTATE('2','2','0','2','5') +#define ERRCODE_NONSTANDARD_USE_OF_ESCAPE_CHARACTER MAKE_SQLSTATE('2','2','P','0','6') +#define ERRCODE_INVALID_INDICATOR_PARAMETER_VALUE MAKE_SQLSTATE('2','2','0','1','0') +#define ERRCODE_INVALID_PARAMETER_VALUE MAKE_SQLSTATE('2','2','0','2','3') +#define ERRCODE_INVALID_REGULAR_EXPRESSION MAKE_SQLSTATE('2','2','0','1','B') +#define ERRCODE_INVALID_ROW_COUNT_IN_LIMIT_CLAUSE MAKE_SQLSTATE('2','2','0','1','W') +#define ERRCODE_INVALID_ROW_COUNT_IN_RESULT_OFFSET_CLAUSE MAKE_SQLSTATE('2','2','0','1','X') +#define ERRCODE_INVALID_TIME_ZONE_DISPLACEMENT_VALUE MAKE_SQLSTATE('2','2','0','0','9') +#define ERRCODE_INVALID_USE_OF_ESCAPE_CHARACTER MAKE_SQLSTATE('2','2','0','0','C') +#define ERRCODE_MOST_SPECIFIC_TYPE_MISMATCH MAKE_SQLSTATE('2','2','0','0','G') +#define ERRCODE_NULL_VALUE_NOT_ALLOWED MAKE_SQLSTATE('2','2','0','0','4') +#define ERRCODE_NULL_VALUE_NO_INDICATOR_PARAMETER MAKE_SQLSTATE('2','2','0','0','2') +#define ERRCODE_NUMERIC_VALUE_OUT_OF_RANGE MAKE_SQLSTATE('2','2','0','0','3') +#define ERRCODE_STRING_DATA_LENGTH_MISMATCH MAKE_SQLSTATE('2','2','0','2','6') +#define ERRCODE_STRING_DATA_RIGHT_TRUNCATION MAKE_SQLSTATE('2','2','0','0','1') +#define ERRCODE_SUBSTRING_ERROR MAKE_SQLSTATE('2','2','0','1','1') +#define ERRCODE_TRIM_ERROR MAKE_SQLSTATE('2','2','0','2','7') +#define ERRCODE_UNTERMINATED_C_STRING MAKE_SQLSTATE('2','2','0','2','4') +#define ERRCODE_ZERO_LENGTH_CHARACTER_STRING MAKE_SQLSTATE('2','2','0','0','F') +#define ERRCODE_FLOATING_POINT_EXCEPTION MAKE_SQLSTATE('2','2','P','0','1') +#define ERRCODE_INVALID_TEXT_REPRESENTATION MAKE_SQLSTATE('2','2','P','0','2') +#define ERRCODE_INVALID_BINARY_REPRESENTATION MAKE_SQLSTATE('2','2','P','0','3') +#define ERRCODE_BAD_COPY_FILE_FORMAT MAKE_SQLSTATE('2','2','P','0','4') +#define ERRCODE_UNTRANSLATABLE_CHARACTER MAKE_SQLSTATE('2','2','P','0','5') +#define ERRCODE_NOT_AN_XML_DOCUMENT MAKE_SQLSTATE('2','2','0','0','L') +#define ERRCODE_INVALID_XML_DOCUMENT MAKE_SQLSTATE('2','2','0','0','M') +#define ERRCODE_INVALID_XML_CONTENT MAKE_SQLSTATE('2','2','0','0','N') +#define ERRCODE_INVALID_XML_COMMENT MAKE_SQLSTATE('2','2','0','0','S') +#define ERRCODE_INVALID_XML_PROCESSING_INSTRUCTION MAKE_SQLSTATE('2','2','0','0','T') + +/* Class 23 - Integrity Constraint Violation */ +#define ERRCODE_INTEGRITY_CONSTRAINT_VIOLATION MAKE_SQLSTATE('2','3','0','0','0') +#define ERRCODE_RESTRICT_VIOLATION MAKE_SQLSTATE('2','3','0','0','1') +#define ERRCODE_NOT_NULL_VIOLATION MAKE_SQLSTATE('2','3','5','0','2') +#define ERRCODE_FOREIGN_KEY_VIOLATION MAKE_SQLSTATE('2','3','5','0','3') +#define ERRCODE_UNIQUE_VIOLATION MAKE_SQLSTATE('2','3','5','0','5') +#define ERRCODE_CHECK_VIOLATION MAKE_SQLSTATE('2','3','5','1','4') +#define ERRCODE_EXCLUSION_VIOLATION MAKE_SQLSTATE('2','3','P','0','1') + +/* Class 24 - Invalid Cursor State */ +#define ERRCODE_INVALID_CURSOR_STATE MAKE_SQLSTATE('2','4','0','0','0') + +/* Class 25 - Invalid Transaction State */ +#define ERRCODE_INVALID_TRANSACTION_STATE MAKE_SQLSTATE('2','5','0','0','0') +#define ERRCODE_ACTIVE_SQL_TRANSACTION MAKE_SQLSTATE('2','5','0','0','1') +#define ERRCODE_BRANCH_TRANSACTION_ALREADY_ACTIVE MAKE_SQLSTATE('2','5','0','0','2') +#define ERRCODE_HELD_CURSOR_REQUIRES_SAME_ISOLATION_LEVEL MAKE_SQLSTATE('2','5','0','0','8') +#define ERRCODE_INAPPROPRIATE_ACCESS_MODE_FOR_BRANCH_TRANSACTION MAKE_SQLSTATE('2','5','0','0','3') +#define ERRCODE_INAPPROPRIATE_ISOLATION_LEVEL_FOR_BRANCH_TRANSACTION MAKE_SQLSTATE('2','5','0','0','4') +#define ERRCODE_NO_ACTIVE_SQL_TRANSACTION_FOR_BRANCH_TRANSACTION MAKE_SQLSTATE('2','5','0','0','5') +#define ERRCODE_READ_ONLY_SQL_TRANSACTION MAKE_SQLSTATE('2','5','0','0','6') +#define ERRCODE_SCHEMA_AND_DATA_STATEMENT_MIXING_NOT_SUPPORTED MAKE_SQLSTATE('2','5','0','0','7') +#define ERRCODE_NO_ACTIVE_SQL_TRANSACTION MAKE_SQLSTATE('2','5','P','0','1') +#define ERRCODE_IN_FAILED_SQL_TRANSACTION MAKE_SQLSTATE('2','5','P','0','2') + +/* Class 26 - Invalid SQL Statement Name */ +#define ERRCODE_INVALID_SQL_STATEMENT_NAME MAKE_SQLSTATE('2','6','0','0','0') + +/* Class 27 - Triggered Data Change Violation */ +#define ERRCODE_TRIGGERED_DATA_CHANGE_VIOLATION MAKE_SQLSTATE('2','7','0','0','0') + +/* Class 28 - Invalid Authorization Specification */ +#define ERRCODE_INVALID_AUTHORIZATION_SPECIFICATION MAKE_SQLSTATE('2','8','0','0','0') +#define ERRCODE_INVALID_PASSWORD MAKE_SQLSTATE('2','8','P','0','1') + +/* Class 2B - Dependent Privilege Descriptors Still Exist */ +#define ERRCODE_DEPENDENT_PRIVILEGE_DESCRIPTORS_STILL_EXIST MAKE_SQLSTATE('2','B','0','0','0') +#define ERRCODE_DEPENDENT_OBJECTS_STILL_EXIST MAKE_SQLSTATE('2','B','P','0','1') + +/* Class 2D - Invalid Transaction Termination */ +#define ERRCODE_INVALID_TRANSACTION_TERMINATION MAKE_SQLSTATE('2','D','0','0','0') + +/* Class 2F - SQL Routine Exception */ +#define ERRCODE_SQL_ROUTINE_EXCEPTION MAKE_SQLSTATE('2','F','0','0','0') +#define ERRCODE_S_R_E_FUNCTION_EXECUTED_NO_RETURN_STATEMENT MAKE_SQLSTATE('2','F','0','0','5') +#define ERRCODE_S_R_E_MODIFYING_SQL_DATA_NOT_PERMITTED MAKE_SQLSTATE('2','F','0','0','2') +#define ERRCODE_S_R_E_PROHIBITED_SQL_STATEMENT_ATTEMPTED MAKE_SQLSTATE('2','F','0','0','3') +#define ERRCODE_S_R_E_READING_SQL_DATA_NOT_PERMITTED MAKE_SQLSTATE('2','F','0','0','4') + +/* Class 34 - Invalid Cursor Name */ +#define ERRCODE_INVALID_CURSOR_NAME MAKE_SQLSTATE('3','4','0','0','0') + +/* Class 38 - External Routine Exception */ +#define ERRCODE_EXTERNAL_ROUTINE_EXCEPTION MAKE_SQLSTATE('3','8','0','0','0') +#define ERRCODE_E_R_E_CONTAINING_SQL_NOT_PERMITTED MAKE_SQLSTATE('3','8','0','0','1') +#define ERRCODE_E_R_E_MODIFYING_SQL_DATA_NOT_PERMITTED MAKE_SQLSTATE('3','8','0','0','2') +#define ERRCODE_E_R_E_PROHIBITED_SQL_STATEMENT_ATTEMPTED MAKE_SQLSTATE('3','8','0','0','3') +#define ERRCODE_E_R_E_READING_SQL_DATA_NOT_PERMITTED MAKE_SQLSTATE('3','8','0','0','4') + +/* Class 39 - External Routine Invocation Exception */ +#define ERRCODE_EXTERNAL_ROUTINE_INVOCATION_EXCEPTION MAKE_SQLSTATE('3','9','0','0','0') +#define ERRCODE_E_R_I_E_INVALID_SQLSTATE_RETURNED MAKE_SQLSTATE('3','9','0','0','1') +#define ERRCODE_E_R_I_E_NULL_VALUE_NOT_ALLOWED MAKE_SQLSTATE('3','9','0','0','4') +#define ERRCODE_E_R_I_E_TRIGGER_PROTOCOL_VIOLATED MAKE_SQLSTATE('3','9','P','0','1') +#define ERRCODE_E_R_I_E_SRF_PROTOCOL_VIOLATED MAKE_SQLSTATE('3','9','P','0','2') + +/* Class 3B - Savepoint Exception */ +#define ERRCODE_SAVEPOINT_EXCEPTION MAKE_SQLSTATE('3','B','0','0','0') +#define ERRCODE_S_E_INVALID_SPECIFICATION MAKE_SQLSTATE('3','B','0','0','1') + +/* Class 3D - Invalid Catalog Name */ +#define ERRCODE_INVALID_CATALOG_NAME MAKE_SQLSTATE('3','D','0','0','0') + +/* Class 3F - Invalid Schema Name */ +#define ERRCODE_INVALID_SCHEMA_NAME MAKE_SQLSTATE('3','F','0','0','0') + +/* Class 40 - Transaction Rollback */ +#define ERRCODE_TRANSACTION_ROLLBACK MAKE_SQLSTATE('4','0','0','0','0') +#define ERRCODE_T_R_INTEGRITY_CONSTRAINT_VIOLATION MAKE_SQLSTATE('4','0','0','0','2') +#define ERRCODE_T_R_SERIALIZATION_FAILURE MAKE_SQLSTATE('4','0','0','0','1') +#define ERRCODE_T_R_STATEMENT_COMPLETION_UNKNOWN MAKE_SQLSTATE('4','0','0','0','3') +#define ERRCODE_T_R_DEADLOCK_DETECTED MAKE_SQLSTATE('4','0','P','0','1') + +/* Class 42 - Syntax Error or Access Rule Violation */ +#define ERRCODE_SYNTAX_ERROR_OR_ACCESS_RULE_VIOLATION MAKE_SQLSTATE('4','2','0','0','0') +#define ERRCODE_SYNTAX_ERROR MAKE_SQLSTATE('4','2','6','0','1') +#define ERRCODE_INSUFFICIENT_PRIVILEGE MAKE_SQLSTATE('4','2','5','0','1') +#define ERRCODE_CANNOT_COERCE MAKE_SQLSTATE('4','2','8','4','6') +#define ERRCODE_GROUPING_ERROR MAKE_SQLSTATE('4','2','8','0','3') +#define ERRCODE_WINDOWING_ERROR MAKE_SQLSTATE('4','2','P','2','0') +#define ERRCODE_INVALID_RECURSION MAKE_SQLSTATE('4','2','P','1','9') +#define ERRCODE_INVALID_FOREIGN_KEY MAKE_SQLSTATE('4','2','8','3','0') +#define ERRCODE_INVALID_NAME MAKE_SQLSTATE('4','2','6','0','2') +#define ERRCODE_NAME_TOO_LONG MAKE_SQLSTATE('4','2','6','2','2') +#define ERRCODE_RESERVED_NAME MAKE_SQLSTATE('4','2','9','3','9') +#define ERRCODE_DATATYPE_MISMATCH MAKE_SQLSTATE('4','2','8','0','4') +#define ERRCODE_INDETERMINATE_DATATYPE MAKE_SQLSTATE('4','2','P','1','8') +#define ERRCODE_COLLATION_MISMATCH MAKE_SQLSTATE('4','2','P','2','1') +#define ERRCODE_INDETERMINATE_COLLATION MAKE_SQLSTATE('4','2','P','2','2') +#define ERRCODE_WRONG_OBJECT_TYPE MAKE_SQLSTATE('4','2','8','0','9') +#define ERRCODE_UNDEFINED_COLUMN MAKE_SQLSTATE('4','2','7','0','3') +#define ERRCODE_UNDEFINED_CURSOR MAKE_SQLSTATE('3','4','0','0','0') +#define ERRCODE_UNDEFINED_DATABASE MAKE_SQLSTATE('3','D','0','0','0') +#define ERRCODE_UNDEFINED_FUNCTION MAKE_SQLSTATE('4','2','8','8','3') +#define ERRCODE_UNDEFINED_PSTATEMENT MAKE_SQLSTATE('2','6','0','0','0') +#define ERRCODE_UNDEFINED_SCHEMA MAKE_SQLSTATE('3','F','0','0','0') +#define ERRCODE_UNDEFINED_TABLE MAKE_SQLSTATE('4','2','P','0','1') +#define ERRCODE_UNDEFINED_PARAMETER MAKE_SQLSTATE('4','2','P','0','2') +#define ERRCODE_UNDEFINED_OBJECT MAKE_SQLSTATE('4','2','7','0','4') +#define ERRCODE_DUPLICATE_COLUMN MAKE_SQLSTATE('4','2','7','0','1') +#define ERRCODE_DUPLICATE_CURSOR MAKE_SQLSTATE('4','2','P','0','3') +#define ERRCODE_DUPLICATE_DATABASE MAKE_SQLSTATE('4','2','P','0','4') +#define ERRCODE_DUPLICATE_FUNCTION MAKE_SQLSTATE('4','2','7','2','3') +#define ERRCODE_DUPLICATE_PSTATEMENT MAKE_SQLSTATE('4','2','P','0','5') +#define ERRCODE_DUPLICATE_SCHEMA MAKE_SQLSTATE('4','2','P','0','6') +#define ERRCODE_DUPLICATE_TABLE MAKE_SQLSTATE('4','2','P','0','7') +#define ERRCODE_DUPLICATE_ALIAS MAKE_SQLSTATE('4','2','7','1','2') +#define ERRCODE_DUPLICATE_OBJECT MAKE_SQLSTATE('4','2','7','1','0') +#define ERRCODE_AMBIGUOUS_COLUMN MAKE_SQLSTATE('4','2','7','0','2') +#define ERRCODE_AMBIGUOUS_FUNCTION MAKE_SQLSTATE('4','2','7','2','5') +#define ERRCODE_AMBIGUOUS_PARAMETER MAKE_SQLSTATE('4','2','P','0','8') +#define ERRCODE_AMBIGUOUS_ALIAS MAKE_SQLSTATE('4','2','P','0','9') +#define ERRCODE_INVALID_COLUMN_REFERENCE MAKE_SQLSTATE('4','2','P','1','0') +#define ERRCODE_INVALID_COLUMN_DEFINITION MAKE_SQLSTATE('4','2','6','1','1') +#define ERRCODE_INVALID_CURSOR_DEFINITION MAKE_SQLSTATE('4','2','P','1','1') +#define ERRCODE_INVALID_DATABASE_DEFINITION MAKE_SQLSTATE('4','2','P','1','2') +#define ERRCODE_INVALID_FUNCTION_DEFINITION MAKE_SQLSTATE('4','2','P','1','3') +#define ERRCODE_INVALID_PSTATEMENT_DEFINITION MAKE_SQLSTATE('4','2','P','1','4') +#define ERRCODE_INVALID_SCHEMA_DEFINITION MAKE_SQLSTATE('4','2','P','1','5') +#define ERRCODE_INVALID_TABLE_DEFINITION MAKE_SQLSTATE('4','2','P','1','6') +#define ERRCODE_INVALID_OBJECT_DEFINITION MAKE_SQLSTATE('4','2','P','1','7') + +/* Class 44 - WITH CHECK OPTION Violation */ +#define ERRCODE_WITH_CHECK_OPTION_VIOLATION MAKE_SQLSTATE('4','4','0','0','0') + +/* Class 53 - Insufficient Resources */ +#define ERRCODE_INSUFFICIENT_RESOURCES MAKE_SQLSTATE('5','3','0','0','0') +#define ERRCODE_DISK_FULL MAKE_SQLSTATE('5','3','1','0','0') +#define ERRCODE_OUT_OF_MEMORY MAKE_SQLSTATE('5','3','2','0','0') +#define ERRCODE_TOO_MANY_CONNECTIONS MAKE_SQLSTATE('5','3','3','0','0') +#define ERRCODE_CONFIGURATION_LIMIT_EXCEEDED MAKE_SQLSTATE('5','3','4','0','0') + +/* Class 54 - Program Limit Exceeded */ +#define ERRCODE_PROGRAM_LIMIT_EXCEEDED MAKE_SQLSTATE('5','4','0','0','0') +#define ERRCODE_STATEMENT_TOO_COMPLEX MAKE_SQLSTATE('5','4','0','0','1') +#define ERRCODE_TOO_MANY_COLUMNS MAKE_SQLSTATE('5','4','0','1','1') +#define ERRCODE_TOO_MANY_ARGUMENTS MAKE_SQLSTATE('5','4','0','2','3') + +/* Class 55 - Object Not In Prerequisite State */ +#define ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE MAKE_SQLSTATE('5','5','0','0','0') +#define ERRCODE_OBJECT_IN_USE MAKE_SQLSTATE('5','5','0','0','6') +#define ERRCODE_CANT_CHANGE_RUNTIME_PARAM MAKE_SQLSTATE('5','5','P','0','2') +#define ERRCODE_LOCK_NOT_AVAILABLE MAKE_SQLSTATE('5','5','P','0','3') + +/* Class 57 - Operator Intervention */ +#define ERRCODE_OPERATOR_INTERVENTION MAKE_SQLSTATE('5','7','0','0','0') +#define ERRCODE_QUERY_CANCELED MAKE_SQLSTATE('5','7','0','1','4') +#define ERRCODE_ADMIN_SHUTDOWN MAKE_SQLSTATE('5','7','P','0','1') +#define ERRCODE_CRASH_SHUTDOWN MAKE_SQLSTATE('5','7','P','0','2') +#define ERRCODE_CANNOT_CONNECT_NOW MAKE_SQLSTATE('5','7','P','0','3') +#define ERRCODE_DATABASE_DROPPED MAKE_SQLSTATE('5','7','P','0','4') + +/* Class 58 - System Error (errors external to PostgreSQL itself) */ +#define ERRCODE_SYSTEM_ERROR MAKE_SQLSTATE('5','8','0','0','0') +#define ERRCODE_IO_ERROR MAKE_SQLSTATE('5','8','0','3','0') +#define ERRCODE_UNDEFINED_FILE MAKE_SQLSTATE('5','8','P','0','1') +#define ERRCODE_DUPLICATE_FILE MAKE_SQLSTATE('5','8','P','0','2') + +/* Class F0 - Configuration File Error */ +#define ERRCODE_CONFIG_FILE_ERROR MAKE_SQLSTATE('F','0','0','0','0') +#define ERRCODE_LOCK_FILE_EXISTS MAKE_SQLSTATE('F','0','0','0','1') + +/* Class HV - Foreign Data Wrapper Error (SQL/MED) */ +#define ERRCODE_FDW_ERROR MAKE_SQLSTATE('H','V','0','0','0') +#define ERRCODE_FDW_COLUMN_NAME_NOT_FOUND MAKE_SQLSTATE('H','V','0','0','5') +#define ERRCODE_FDW_DYNAMIC_PARAMETER_VALUE_NEEDED MAKE_SQLSTATE('H','V','0','0','2') +#define ERRCODE_FDW_FUNCTION_SEQUENCE_ERROR MAKE_SQLSTATE('H','V','0','1','0') +#define ERRCODE_FDW_INCONSISTENT_DESCRIPTOR_INFORMATION MAKE_SQLSTATE('H','V','0','2','1') +#define ERRCODE_FDW_INVALID_ATTRIBUTE_VALUE MAKE_SQLSTATE('H','V','0','2','4') +#define ERRCODE_FDW_INVALID_COLUMN_NAME MAKE_SQLSTATE('H','V','0','0','7') +#define ERRCODE_FDW_INVALID_COLUMN_NUMBER MAKE_SQLSTATE('H','V','0','0','8') +#define ERRCODE_FDW_INVALID_DATA_TYPE MAKE_SQLSTATE('H','V','0','0','4') +#define ERRCODE_FDW_INVALID_DATA_TYPE_DESCRIPTORS MAKE_SQLSTATE('H','V','0','0','6') +#define ERRCODE_FDW_INVALID_DESCRIPTOR_FIELD_IDENTIFIER MAKE_SQLSTATE('H','V','0','9','1') +#define ERRCODE_FDW_INVALID_HANDLE MAKE_SQLSTATE('H','V','0','0','B') +#define ERRCODE_FDW_INVALID_OPTION_INDEX MAKE_SQLSTATE('H','V','0','0','C') +#define ERRCODE_FDW_INVALID_OPTION_NAME MAKE_SQLSTATE('H','V','0','0','D') +#define ERRCODE_FDW_INVALID_STRING_LENGTH_OR_BUFFER_LENGTH MAKE_SQLSTATE('H','V','0','9','0') +#define ERRCODE_FDW_INVALID_STRING_FORMAT MAKE_SQLSTATE('H','V','0','0','A') +#define ERRCODE_FDW_INVALID_USE_OF_NULL_POINTER MAKE_SQLSTATE('H','V','0','0','9') +#define ERRCODE_FDW_TOO_MANY_HANDLES MAKE_SQLSTATE('H','V','0','1','4') +#define ERRCODE_FDW_OUT_OF_MEMORY MAKE_SQLSTATE('H','V','0','0','1') +#define ERRCODE_FDW_NO_SCHEMAS MAKE_SQLSTATE('H','V','0','0','P') +#define ERRCODE_FDW_OPTION_NAME_NOT_FOUND MAKE_SQLSTATE('H','V','0','0','J') +#define ERRCODE_FDW_REPLY_HANDLE MAKE_SQLSTATE('H','V','0','0','K') +#define ERRCODE_FDW_SCHEMA_NOT_FOUND MAKE_SQLSTATE('H','V','0','0','Q') +#define ERRCODE_FDW_TABLE_NOT_FOUND MAKE_SQLSTATE('H','V','0','0','R') +#define ERRCODE_FDW_UNABLE_TO_CREATE_EXECUTION MAKE_SQLSTATE('H','V','0','0','L') +#define ERRCODE_FDW_UNABLE_TO_CREATE_REPLY MAKE_SQLSTATE('H','V','0','0','M') +#define ERRCODE_FDW_UNABLE_TO_ESTABLISH_CONNECTION MAKE_SQLSTATE('H','V','0','0','N') + +/* Class P0 - PL/pgSQL Error */ +#define ERRCODE_PLPGSQL_ERROR MAKE_SQLSTATE('P','0','0','0','0') +#define ERRCODE_RAISE_EXCEPTION MAKE_SQLSTATE('P','0','0','0','1') +#define ERRCODE_NO_DATA_FOUND MAKE_SQLSTATE('P','0','0','0','2') +#define ERRCODE_TOO_MANY_ROWS MAKE_SQLSTATE('P','0','0','0','3') + +/* Class XX - Internal Error */ +#define ERRCODE_INTERNAL_ERROR MAKE_SQLSTATE('X','X','0','0','0') +#define ERRCODE_DATA_CORRUPTED MAKE_SQLSTATE('X','X','0','0','1') +#define ERRCODE_INDEX_CORRUPTED MAKE_SQLSTATE('X','X','0','0','2') diff --git a/src/backend/utils/fmgroids.h b/src/backend/utils/fmgroids.h new file mode 100644 index 000000000..076f2eb51 --- /dev/null +++ b/src/backend/utils/fmgroids.h @@ -0,0 +1,2138 @@ +/*------------------------------------------------------------------------- + * + * fmgroids.h + * Macros that define the OIDs of built-in functions. + * + * These macros can be used to avoid a catalog lookup when a specific + * fmgr-callable function needs to be referenced. + * + * Portions Copyright (c) 1996-2012, PostgreSQL Global Development Group + * Portions Copyright (c) 1994, Regents of the University of California + * + * NOTES + * ****************************** + * *** DO NOT EDIT THIS FILE! *** + * ****************************** + * + * It has been GENERATED by Gen_fmgrtab.pl + * from ../../../src/include/catalog/pg_proc.h + * + *------------------------------------------------------------------------- + */ +#ifndef FMGROIDS_H +#define FMGROIDS_H + +/* + * Constant macros for the OIDs of entries in pg_proc. + * + * NOTE: macros are named after the prosrc value, ie the actual C name + * of the implementing function, not the proname which may be overloaded. + * For example, we want to be able to assign different macro names to both + * char_text() and name_text() even though these both appear with proname + * 'text'. If the same C function appears in more than one pg_proc entry, + * its equivalent macro will be defined with the lowest OID among those + * entries. + */ +#define F_BYTEAOUT 31 +#define F_CHAROUT 33 +#define F_NAMEIN 34 +#define F_NAMEOUT 35 +#define F_INT2IN 38 +#define F_INT2OUT 39 +#define F_INT2VECTORIN 40 +#define F_INT2VECTOROUT 41 +#define F_INT4IN 42 +#define F_INT4OUT 43 +#define F_REGPROCIN 44 +#define F_REGPROCOUT 45 +#define F_TEXTIN 46 +#define F_TEXTOUT 47 +#define F_TIDIN 48 +#define F_TIDOUT 49 +#define F_XIDIN 50 +#define F_XIDOUT 51 +#define F_CIDIN 52 +#define F_CIDOUT 53 +#define F_OIDVECTORIN 54 +#define F_OIDVECTOROUT 55 +#define F_BOOLLT 56 +#define F_BOOLGT 57 +#define F_BOOLEQ 60 +#define F_CHAREQ 61 +#define F_NAMEEQ 62 +#define F_INT2EQ 63 +#define F_INT2LT 64 +#define F_INT4EQ 65 +#define F_INT4LT 66 +#define F_TEXTEQ 67 +#define F_XIDEQ 68 +#define F_CIDEQ 69 +#define F_CHARNE 70 +#define F_CHARLE 72 +#define F_CHARGT 73 +#define F_CHARGE 74 +#define F_CHARTOI4 77 +#define F_I4TOCHAR 78 +#define F_NAMEREGEXEQ 79 +#define F_BOOLNE 84 +#define F_PGSQL_VERSION 89 +#define F_EQSEL 101 +#define F_NEQSEL 102 +#define F_SCALARLTSEL 103 +#define F_SCALARGTSEL 104 +#define F_EQJOINSEL 105 +#define F_NEQJOINSEL 106 +#define F_SCALARLTJOINSEL 107 +#define F_SCALARGTJOINSEL 108 +#define F_UNKNOWNIN 109 +#define F_UNKNOWNOUT 110 +#define F_NUMERIC_FAC 111 +#define F_BOX_ABOVE_EQ 115 +#define F_BOX_BELOW_EQ 116 +#define F_POINT_IN 117 +#define F_POINT_OUT 118 +#define F_LSEG_IN 119 +#define F_LSEG_OUT 120 +#define F_PATH_IN 121 +#define F_PATH_OUT 122 +#define F_BOX_IN 123 +#define F_BOX_OUT 124 +#define F_BOX_OVERLAP 125 +#define F_BOX_GE 126 +#define F_BOX_GT 127 +#define F_BOX_EQ 128 +#define F_BOX_LT 129 +#define F_BOX_LE 130 +#define F_POINT_ABOVE 131 +#define F_POINT_LEFT 132 +#define F_POINT_RIGHT 133 +#define F_POINT_BELOW 134 +#define F_POINT_EQ 135 +#define F_ON_PB 136 +#define F_ON_PPATH 137 +#define F_BOX_CENTER 138 +#define F_AREASEL 139 +#define F_AREAJOINSEL 140 +#define F_INT4MUL 141 +#define F_INT4NE 144 +#define F_INT2NE 145 +#define F_INT2GT 146 +#define F_INT4GT 147 +#define F_INT2LE 148 +#define F_INT4LE 149 +#define F_INT4GE 150 +#define F_INT2GE 151 +#define F_INT2MUL 152 +#define F_INT2DIV 153 +#define F_INT4DIV 154 +#define F_INT2MOD 155 +#define F_INT4MOD 156 +#define F_TEXTNE 157 +#define F_INT24EQ 158 +#define F_INT42EQ 159 +#define F_INT24LT 160 +#define F_INT42LT 161 +#define F_INT24GT 162 +#define F_INT42GT 163 +#define F_INT24NE 164 +#define F_INT42NE 165 +#define F_INT24LE 166 +#define F_INT42LE 167 +#define F_INT24GE 168 +#define F_INT42GE 169 +#define F_INT24MUL 170 +#define F_INT42MUL 171 +#define F_INT24DIV 172 +#define F_INT42DIV 173 +#define F_INT2PL 176 +#define F_INT4PL 177 +#define F_INT24PL 178 +#define F_INT42PL 179 +#define F_INT2MI 180 +#define F_INT4MI 181 +#define F_INT24MI 182 +#define F_INT42MI 183 +#define F_OIDEQ 184 +#define F_OIDNE 185 +#define F_BOX_SAME 186 +#define F_BOX_CONTAIN 187 +#define F_BOX_LEFT 188 +#define F_BOX_OVERLEFT 189 +#define F_BOX_OVERRIGHT 190 +#define F_BOX_RIGHT 191 +#define F_BOX_CONTAINED 192 +#define F_BOX_CONTAIN_PT 193 +#define F_PG_NODE_TREE_IN 195 +#define F_PG_NODE_TREE_OUT 196 +#define F_PG_NODE_TREE_RECV 197 +#define F_PG_NODE_TREE_SEND 198 +#define F_FLOAT4IN 200 +#define F_FLOAT4OUT 201 +#define F_FLOAT4MUL 202 +#define F_FLOAT4DIV 203 +#define F_FLOAT4PL 204 +#define F_FLOAT4MI 205 +#define F_FLOAT4UM 206 +#define F_FLOAT4ABS 207 +#define F_FLOAT4_ACCUM 208 +#define F_FLOAT4LARGER 209 +#define F_FLOAT4SMALLER 211 +#define F_INT4UM 212 +#define F_INT2UM 213 +#define F_FLOAT8IN 214 +#define F_FLOAT8OUT 215 +#define F_FLOAT8MUL 216 +#define F_FLOAT8DIV 217 +#define F_FLOAT8PL 218 +#define F_FLOAT8MI 219 +#define F_FLOAT8UM 220 +#define F_FLOAT8ABS 221 +#define F_FLOAT8_ACCUM 222 +#define F_FLOAT8LARGER 223 +#define F_FLOAT8SMALLER 224 +#define F_LSEG_CENTER 225 +#define F_PATH_CENTER 226 +#define F_POLY_CENTER 227 +#define F_DROUND 228 +#define F_DTRUNC 229 +#define F_DSQRT 230 +#define F_DCBRT 231 +#define F_DPOW 232 +#define F_DEXP 233 +#define F_DLOG1 234 +#define F_I2TOD 235 +#define F_I2TOF 236 +#define F_DTOI2 237 +#define F_FTOI2 238 +#define F_LINE_DISTANCE 239 +#define F_ABSTIMEIN 240 +#define F_ABSTIMEOUT 241 +#define F_RELTIMEIN 242 +#define F_RELTIMEOUT 243 +#define F_TIMEPL 244 +#define F_TIMEMI 245 +#define F_TINTERVALIN 246 +#define F_TINTERVALOUT 247 +#define F_INTINTERVAL 248 +#define F_TINTERVALREL 249 +#define F_TIMENOW 250 +#define F_ABSTIMEEQ 251 +#define F_ABSTIMENE 252 +#define F_ABSTIMELT 253 +#define F_ABSTIMEGT 254 +#define F_ABSTIMELE 255 +#define F_ABSTIMEGE 256 +#define F_RELTIMEEQ 257 +#define F_RELTIMENE 258 +#define F_RELTIMELT 259 +#define F_RELTIMEGT 260 +#define F_RELTIMELE 261 +#define F_RELTIMEGE 262 +#define F_TINTERVALSAME 263 +#define F_TINTERVALCT 264 +#define F_TINTERVALOV 265 +#define F_TINTERVALLENEQ 266 +#define F_TINTERVALLENNE 267 +#define F_TINTERVALLENLT 268 +#define F_TINTERVALLENGT 269 +#define F_TINTERVALLENLE 270 +#define F_TINTERVALLENGE 271 +#define F_TINTERVALSTART 272 +#define F_TINTERVALEND 273 +#define F_TIMEOFDAY 274 +#define F_ABSTIME_FINITE 275 +#define F_BTCANRETURN 276 +#define F_INTER_SL 277 +#define F_INTER_LB 278 +#define F_FLOAT48MUL 279 +#define F_FLOAT48DIV 280 +#define F_FLOAT48PL 281 +#define F_FLOAT48MI 282 +#define F_FLOAT84MUL 283 +#define F_FLOAT84DIV 284 +#define F_FLOAT84PL 285 +#define F_FLOAT84MI 286 +#define F_FLOAT4EQ 287 +#define F_FLOAT4NE 288 +#define F_FLOAT4LT 289 +#define F_FLOAT4LE 290 +#define F_FLOAT4GT 291 +#define F_FLOAT4GE 292 +#define F_FLOAT8EQ 293 +#define F_FLOAT8NE 294 +#define F_FLOAT8LT 295 +#define F_FLOAT8LE 296 +#define F_FLOAT8GT 297 +#define F_FLOAT8GE 298 +#define F_FLOAT48EQ 299 +#define F_FLOAT48NE 300 +#define F_FLOAT48LT 301 +#define F_FLOAT48LE 302 +#define F_FLOAT48GT 303 +#define F_FLOAT48GE 304 +#define F_FLOAT84EQ 305 +#define F_FLOAT84NE 306 +#define F_FLOAT84LT 307 +#define F_FLOAT84LE 308 +#define F_FLOAT84GT 309 +#define F_FLOAT84GE 310 +#define F_FTOD 311 +#define F_DTOF 312 +#define F_I2TOI4 313 +#define F_I4TOI2 314 +#define F_INT2VECTOREQ 315 +#define F_I4TOD 316 +#define F_DTOI4 317 +#define F_I4TOF 318 +#define F_FTOI4 319 +#define F_WIDTH_BUCKET_FLOAT8 320 +#define F_JSON_IN 321 +#define F_JSON_OUT 322 +#define F_JSON_RECV 323 +#define F_JSON_SEND 324 +#define F_GINBUILDEMPTY 325 +#define F_GISTBUILDEMPTY 326 +#define F_HASHBUILDEMPTY 327 +#define F_BTBUILDEMPTY 328 +#define F_HASH_ACLITEM 329 +#define F_BTGETTUPLE 330 +#define F_BTINSERT 331 +#define F_BTBULKDELETE 332 +#define F_BTBEGINSCAN 333 +#define F_BTRESCAN 334 +#define F_BTENDSCAN 335 +#define F_BTMARKPOS 336 +#define F_BTRESTRPOS 337 +#define F_BTBUILD 338 +#define F_POLY_SAME 339 +#define F_POLY_CONTAIN 340 +#define F_POLY_LEFT 341 +#define F_POLY_OVERLEFT 342 +#define F_POLY_OVERRIGHT 343 +#define F_POLY_RIGHT 344 +#define F_POLY_CONTAINED 345 +#define F_POLY_OVERLAP 346 +#define F_POLY_IN 347 +#define F_POLY_OUT 348 +#define F_BTINT2CMP 350 +#define F_BTINT4CMP 351 +#define F_BTFLOAT4CMP 354 +#define F_BTFLOAT8CMP 355 +#define F_BTOIDCMP 356 +#define F_BTABSTIMECMP 357 +#define F_BTCHARCMP 358 +#define F_BTNAMECMP 359 +#define F_BTTEXTCMP 360 +#define F_LSEG_DISTANCE 361 +#define F_LSEG_INTERPT 362 +#define F_DIST_PS 363 +#define F_DIST_PB 364 +#define F_DIST_SB 365 +#define F_CLOSE_PS 366 +#define F_CLOSE_PB 367 +#define F_CLOSE_SB 368 +#define F_ON_PS 369 +#define F_PATH_DISTANCE 370 +#define F_DIST_PPATH 371 +#define F_ON_SB 372 +#define F_INTER_SB 373 +#define F_TEXT_TO_ARRAY_NULL 376 +#define F_CASH_CMP 377 +#define F_ARRAY_PUSH 378 +#define F_BTRELTIMECMP 380 +#define F_BTTINTERVALCMP 381 +#define F_BTARRAYCMP 382 +#define F_ARRAY_CAT 383 +#define F_ARRAY_TO_TEXT_NULL 384 +#define F_ARRAY_NE 390 +#define F_ARRAY_LT 391 +#define F_ARRAY_GT 392 +#define F_ARRAY_LE 393 +#define F_TEXT_TO_ARRAY 394 +#define F_ARRAY_TO_TEXT 395 +#define F_ARRAY_GE 396 +#define F_HASHINT2VECTOR 398 +#define F_HASHMACADDR 399 +#define F_HASHTEXT 400 +#define F_RTRIM1 401 +#define F_BTOIDVECTORCMP 404 +#define F_NAME_TEXT 406 +#define F_TEXT_NAME 407 +#define F_NAME_BPCHAR 408 +#define F_BPCHAR_NAME 409 +#define F_HASHINET 422 +#define F_HASHVACUUMCLEANUP 425 +#define F_HASH_NUMERIC 432 +#define F_MACADDR_IN 436 +#define F_MACADDR_OUT 437 +#define F_HASHCOSTESTIMATE 438 +#define F_HASHGETTUPLE 440 +#define F_HASHINSERT 441 +#define F_HASHBULKDELETE 442 +#define F_HASHBEGINSCAN 443 +#define F_HASHRESCAN 444 +#define F_HASHENDSCAN 445 +#define F_HASHMARKPOS 446 +#define F_HASHRESTRPOS 447 +#define F_HASHBUILD 448 +#define F_HASHINT2 449 +#define F_HASHINT4 450 +#define F_HASHFLOAT4 451 +#define F_HASHFLOAT8 452 +#define F_HASHOID 453 +#define F_HASHCHAR 454 +#define F_HASHNAME 455 +#define F_HASHVARLENA 456 +#define F_HASHOIDVECTOR 457 +#define F_TEXT_LARGER 458 +#define F_TEXT_SMALLER 459 +#define F_INT8IN 460 +#define F_INT8OUT 461 +#define F_INT8UM 462 +#define F_INT8PL 463 +#define F_INT8MI 464 +#define F_INT8MUL 465 +#define F_INT8DIV 466 +#define F_INT8EQ 467 +#define F_INT8NE 468 +#define F_INT8LT 469 +#define F_INT8GT 470 +#define F_INT8LE 471 +#define F_INT8GE 472 +#define F_INT84EQ 474 +#define F_INT84NE 475 +#define F_INT84LT 476 +#define F_INT84GT 477 +#define F_INT84LE 478 +#define F_INT84GE 479 +#define F_INT84 480 +#define F_INT48 481 +#define F_I8TOD 482 +#define F_DTOI8 483 +#define F_ARRAY_LARGER 515 +#define F_ARRAY_SMALLER 516 +#define F_INET_ABBREV 598 +#define F_CIDR_ABBREV 599 +#define F_INET_SET_MASKLEN 605 +#define F_OIDVECTORNE 619 +#define F_HASH_ARRAY 626 +#define F_CIDR_SET_MASKLEN 635 +#define F_BTGETBITMAP 636 +#define F_HASHGETBITMAP 637 +#define F_GISTGETBITMAP 638 +#define F_I8TOF 652 +#define F_FTOI8 653 +#define F_NAMELT 655 +#define F_NAMELE 656 +#define F_NAMEGT 657 +#define F_NAMEGE 658 +#define F_NAMENE 659 +#define F_BPCHAR 668 +#define F_VARCHAR 669 +#define F_MKTINTERVAL 676 +#define F_OIDVECTORLT 677 +#define F_OIDVECTORLE 678 +#define F_OIDVECTOREQ 679 +#define F_OIDVECTORGE 680 +#define F_OIDVECTORGT 681 +#define F_NETWORK_NETWORK 683 +#define F_NETWORK_NETMASK 696 +#define F_NETWORK_MASKLEN 697 +#define F_NETWORK_BROADCAST 698 +#define F_NETWORK_HOST 699 +#define F_CURRENT_USER 710 +#define F_NETWORK_FAMILY 711 +#define F_INT82 714 +#define F_LO_CREATE 715 +#define F_OIDLT 716 +#define F_OIDLE 717 +#define F_BYTEAOCTETLEN 720 +#define F_BYTEAGETBYTE 721 +#define F_BYTEASETBYTE 722 +#define F_BYTEAGETBIT 723 +#define F_BYTEASETBIT 724 +#define F_DIST_PL 725 +#define F_DIST_LB 726 +#define F_DIST_SL 727 +#define F_DIST_CPOLY 728 +#define F_POLY_DISTANCE 729 +#define F_NETWORK_SHOW 730 +#define F_TEXT_LT 740 +#define F_TEXT_LE 741 +#define F_TEXT_GT 742 +#define F_TEXT_GE 743 +#define F_ARRAY_EQ 744 +#define F_SESSION_USER 746 +#define F_ARRAY_DIMS 747 +#define F_ARRAY_NDIMS 748 +#define F_BYTEAOVERLAY 749 +#define F_ARRAY_IN 750 +#define F_ARRAY_OUT 751 +#define F_BYTEAOVERLAY_NO_LEN 752 +#define F_MACADDR_TRUNC 753 +#define F_INT28 754 +#define F_SMGRIN 760 +#define F_SMGROUT 761 +#define F_SMGREQ 762 +#define F_SMGRNE 763 +#define F_LO_IMPORT 764 +#define F_LO_EXPORT 765 +#define F_INT4INC 766 +#define F_LO_IMPORT_WITH_OID 767 +#define F_INT4LARGER 768 +#define F_INT4SMALLER 769 +#define F_INT2LARGER 770 +#define F_INT2SMALLER 771 +#define F_GISTCOSTESTIMATE 772 +#define F_GISTGETTUPLE 774 +#define F_GISTINSERT 775 +#define F_GISTBULKDELETE 776 +#define F_GISTBEGINSCAN 777 +#define F_GISTRESCAN 778 +#define F_GISTENDSCAN 779 +#define F_GISTMARKPOS 780 +#define F_GISTRESTRPOS 781 +#define F_GISTBUILD 782 +#define F_TINTERVALEQ 784 +#define F_TINTERVALNE 785 +#define F_TINTERVALLT 786 +#define F_TINTERVALGT 787 +#define F_TINTERVALLE 788 +#define F_TINTERVALGE 789 +#define F_PG_CLIENT_ENCODING 810 +#define F_CURRENT_QUERY 817 +#define F_MACADDR_EQ 830 +#define F_MACADDR_LT 831 +#define F_MACADDR_LE 832 +#define F_MACADDR_GT 833 +#define F_MACADDR_GE 834 +#define F_MACADDR_NE 835 +#define F_MACADDR_CMP 836 +#define F_INT82PL 837 +#define F_INT82MI 838 +#define F_INT82MUL 839 +#define F_INT82DIV 840 +#define F_INT28PL 841 +#define F_BTINT8CMP 842 +#define F_CASH_MUL_FLT4 846 +#define F_CASH_DIV_FLT4 847 +#define F_FLT4_MUL_CASH 848 +#define F_TEXTPOS 849 +#define F_TEXTLIKE 850 +#define F_TEXTNLIKE 851 +#define F_INT48EQ 852 +#define F_INT48NE 853 +#define F_INT48LT 854 +#define F_INT48GT 855 +#define F_INT48LE 856 +#define F_INT48GE 857 +#define F_NAMELIKE 858 +#define F_NAMENLIKE 859 +#define F_CHAR_BPCHAR 860 +#define F_CURRENT_DATABASE 861 +#define F_INT4_MUL_CASH 862 +#define F_INT2_MUL_CASH 863 +#define F_CASH_MUL_INT4 864 +#define F_CASH_DIV_INT4 865 +#define F_CASH_MUL_INT2 866 +#define F_CASH_DIV_INT2 867 +#define F_LOWER 870 +#define F_UPPER 871 +#define F_INITCAP 872 +#define F_LPAD 873 +#define F_RPAD 874 +#define F_LTRIM 875 +#define F_RTRIM 876 +#define F_TEXT_SUBSTR 877 +#define F_TRANSLATE 878 +#define F_LTRIM1 881 +#define F_TEXT_SUBSTR_NO_LEN 883 +#define F_BTRIM 884 +#define F_BTRIM1 885 +#define F_CASH_IN 886 +#define F_CASH_OUT 887 +#define F_CASH_EQ 888 +#define F_CASH_NE 889 +#define F_CASH_LT 890 +#define F_CASH_LE 891 +#define F_CASH_GT 892 +#define F_CASH_GE 893 +#define F_CASH_PL 894 +#define F_CASH_MI 895 +#define F_CASH_MUL_FLT8 896 +#define F_CASH_DIV_FLT8 897 +#define F_CASHLARGER 898 +#define F_CASHSMALLER 899 +#define F_INET_IN 910 +#define F_INET_OUT 911 +#define F_FLT8_MUL_CASH 919 +#define F_NETWORK_EQ 920 +#define F_NETWORK_LT 921 +#define F_NETWORK_LE 922 +#define F_NETWORK_GT 923 +#define F_NETWORK_GE 924 +#define F_NETWORK_NE 925 +#define F_NETWORK_CMP 926 +#define F_NETWORK_SUB 927 +#define F_NETWORK_SUBEQ 928 +#define F_NETWORK_SUP 929 +#define F_NETWORK_SUPEQ 930 +#define F_CASH_WORDS 935 +#define F_GENERATE_SERIES_TIMESTAMP 938 +#define F_GENERATE_SERIES_TIMESTAMPTZ 939 +#define F_INT28MI 942 +#define F_INT28MUL 943 +#define F_TEXT_CHAR 944 +#define F_INT8MOD 945 +#define F_CHAR_TEXT 946 +#define F_INT28DIV 948 +#define F_HASHINT8 949 +#define F_LO_OPEN 952 +#define F_LO_CLOSE 953 +#define F_LOREAD 954 +#define F_LOWRITE 955 +#define F_LO_LSEEK 956 +#define F_LO_CREAT 957 +#define F_LO_TELL 958 +#define F_ON_PL 959 +#define F_ON_SL 960 +#define F_CLOSE_PL 961 +#define F_CLOSE_SL 962 +#define F_CLOSE_LB 963 +#define F_LO_UNLINK 964 +#define F_BTVACUUMCLEANUP 972 +#define F_PATH_INTER 973 +#define F_BOX_AREA 975 +#define F_BOX_WIDTH 976 +#define F_BOX_HEIGHT 977 +#define F_BOX_DISTANCE 978 +#define F_PATH_AREA 979 +#define F_BOX_INTERSECT 980 +#define F_BOX_DIAGONAL 981 +#define F_PATH_N_LT 982 +#define F_PATH_N_GT 983 +#define F_PATH_N_EQ 984 +#define F_PATH_N_LE 985 +#define F_PATH_N_GE 986 +#define F_PATH_LENGTH 987 +#define F_POINT_NE 988 +#define F_POINT_VERT 989 +#define F_POINT_HORIZ 990 +#define F_POINT_DISTANCE 991 +#define F_POINT_SLOPE 992 +#define F_LSEG_CONSTRUCT 993 +#define F_LSEG_INTERSECT 994 +#define F_LSEG_PARALLEL 995 +#define F_LSEG_PERP 996 +#define F_LSEG_VERTICAL 997 +#define F_LSEG_HORIZONTAL 998 +#define F_LSEG_EQ 999 +#define F_LO_TRUNCATE 1004 +#define F_TIMESTAMPTZ_IZONE 1026 +#define F_GIST_POINT_COMPRESS 1030 +#define F_ACLITEMIN 1031 +#define F_ACLITEMOUT 1032 +#define F_ACLINSERT 1035 +#define F_ACLREMOVE 1036 +#define F_ACLCONTAINS 1037 +#define F_GETDATABASEENCODING 1039 +#define F_BPCHARIN 1044 +#define F_BPCHAROUT 1045 +#define F_VARCHARIN 1046 +#define F_VARCHAROUT 1047 +#define F_BPCHAREQ 1048 +#define F_BPCHARLT 1049 +#define F_BPCHARLE 1050 +#define F_BPCHARGT 1051 +#define F_BPCHARGE 1052 +#define F_BPCHARNE 1053 +#define F_ACLITEM_EQ 1062 +#define F_BPCHAR_LARGER 1063 +#define F_BPCHAR_SMALLER 1064 +#define F_PG_PREPARED_XACT 1065 +#define F_GENERATE_SERIES_STEP_INT4 1066 +#define F_GENERATE_SERIES_INT4 1067 +#define F_GENERATE_SERIES_STEP_INT8 1068 +#define F_GENERATE_SERIES_INT8 1069 +#define F_BPCHARCMP 1078 +#define F_TEXT_REGCLASS 1079 +#define F_HASHBPCHAR 1080 +#define F_FORMAT_TYPE 1081 +#define F_DATE_IN 1084 +#define F_DATE_OUT 1085 +#define F_DATE_EQ 1086 +#define F_DATE_LT 1087 +#define F_DATE_LE 1088 +#define F_DATE_GT 1089 +#define F_DATE_GE 1090 +#define F_DATE_NE 1091 +#define F_DATE_CMP 1092 +#define F_TIME_LT 1102 +#define F_TIME_LE 1103 +#define F_TIME_GT 1104 +#define F_TIME_GE 1105 +#define F_TIME_NE 1106 +#define F_TIME_CMP 1107 +#define F_DATE_LARGER 1138 +#define F_DATE_SMALLER 1139 +#define F_DATE_MI 1140 +#define F_DATE_PLI 1141 +#define F_DATE_MII 1142 +#define F_TIME_IN 1143 +#define F_TIME_OUT 1144 +#define F_TIME_EQ 1145 +#define F_CIRCLE_ADD_PT 1146 +#define F_CIRCLE_SUB_PT 1147 +#define F_CIRCLE_MUL_PT 1148 +#define F_CIRCLE_DIV_PT 1149 +#define F_TIMESTAMPTZ_IN 1150 +#define F_TIMESTAMPTZ_OUT 1151 +#define F_TIMESTAMP_EQ 1152 +#define F_TIMESTAMP_NE 1153 +#define F_TIMESTAMP_LT 1154 +#define F_TIMESTAMP_LE 1155 +#define F_TIMESTAMP_GE 1156 +#define F_TIMESTAMP_GT 1157 +#define F_TIMESTAMPTZ_ZONE 1159 +#define F_INTERVAL_IN 1160 +#define F_INTERVAL_OUT 1161 +#define F_INTERVAL_EQ 1162 +#define F_INTERVAL_NE 1163 +#define F_INTERVAL_LT 1164 +#define F_INTERVAL_LE 1165 +#define F_INTERVAL_GE 1166 +#define F_INTERVAL_GT 1167 +#define F_INTERVAL_UM 1168 +#define F_INTERVAL_PL 1169 +#define F_INTERVAL_MI 1170 +#define F_TIMESTAMPTZ_PART 1171 +#define F_INTERVAL_PART 1172 +#define F_ABSTIME_TIMESTAMPTZ 1173 +#define F_DATE_TIMESTAMPTZ 1174 +#define F_INTERVAL_JUSTIFY_HOURS 1175 +#define F_RELTIME_INTERVAL 1177 +#define F_TIMESTAMPTZ_DATE 1178 +#define F_ABSTIME_DATE 1179 +#define F_TIMESTAMPTZ_ABSTIME 1180 +#define F_XID_AGE 1181 +#define F_TIMESTAMP_MI 1188 +#define F_TIMESTAMPTZ_PL_INTERVAL 1189 +#define F_TIMESTAMPTZ_MI_INTERVAL 1190 +#define F_GENERATE_SUBSCRIPTS 1191 +#define F_GENERATE_SUBSCRIPTS_NODIR 1192 +#define F_ARRAY_FILL 1193 +#define F_INTERVAL_RELTIME 1194 +#define F_TIMESTAMP_SMALLER 1195 +#define F_TIMESTAMP_LARGER 1196 +#define F_INTERVAL_SMALLER 1197 +#define F_INTERVAL_LARGER 1198 +#define F_TIMESTAMPTZ_AGE 1199 +#define F_INTERVAL_SCALE 1200 +#define F_TIMESTAMPTZ_TRUNC 1217 +#define F_INTERVAL_TRUNC 1218 +#define F_INT8INC 1219 +#define F_INT8ABS 1230 +#define F_INT8LARGER 1236 +#define F_INT8SMALLER 1237 +#define F_TEXTICREGEXEQ 1238 +#define F_TEXTICREGEXNE 1239 +#define F_NAMEICREGEXEQ 1240 +#define F_NAMEICREGEXNE 1241 +#define F_BOOLIN 1242 +#define F_BOOLOUT 1243 +#define F_BYTEAIN 1244 +#define F_CHARIN 1245 +#define F_CHARLT 1246 +#define F_UNIQUE_KEY_RECHECK 1250 +#define F_INT4ABS 1251 +#define F_NAMEREGEXNE 1252 +#define F_INT2ABS 1253 +#define F_TEXTREGEXEQ 1254 +#define F_TEXTREGEXNE 1256 +#define F_TEXTLEN 1257 +#define F_TEXTCAT 1258 +#define F_PG_CHAR_TO_ENCODING 1264 +#define F_TIDNE 1265 +#define F_CIDR_IN 1267 +#define F_BTCOSTESTIMATE 1268 +#define F_PG_COLUMN_SIZE 1269 +#define F_OVERLAPS_TIMETZ 1271 +#define F_DATETIME_TIMESTAMP 1272 +#define F_TIMETZ_PART 1273 +#define F_INT84PL 1274 +#define F_INT84MI 1275 +#define F_INT84MUL 1276 +#define F_INT84DIV 1277 +#define F_INT48PL 1278 +#define F_INT48MI 1279 +#define F_INT48MUL 1280 +#define F_INT48DIV 1281 +#define F_QUOTE_IDENT 1282 +#define F_QUOTE_LITERAL 1283 +#define F_ARRAY_FILL_WITH_LOWER_BOUNDS 1286 +#define F_I8TOOID 1287 +#define F_OIDTOI8 1288 +#define F_QUOTE_NULLABLE 1289 +#define F_SUPPRESS_REDUNDANT_UPDATES_TRIGGER 1291 +#define F_TIDEQ 1292 +#define F_CURRTID_BYRELOID 1293 +#define F_CURRTID_BYRELNAME 1294 +#define F_INTERVAL_JUSTIFY_DAYS 1295 +#define F_DATETIMETZ_TIMESTAMPTZ 1297 +#define F_NOW 1299 +#define F_POSITIONSEL 1300 +#define F_POSITIONJOINSEL 1301 +#define F_CONTSEL 1302 +#define F_CONTJOINSEL 1303 +#define F_OVERLAPS_TIMESTAMP 1304 +#define F_OVERLAPS_TIME 1308 +#define F_TIMESTAMP_IN 1312 +#define F_TIMESTAMP_OUT 1313 +#define F_TIMESTAMP_CMP 1314 +#define F_INTERVAL_CMP 1315 +#define F_TIMESTAMP_TIME 1316 +#define F_BPCHARLEN 1318 +#define F_INTERVAL_DIV 1326 +#define F_DLOG10 1339 +#define F_OIDVECTORTYPES 1349 +#define F_TIMETZ_IN 1350 +#define F_TIMETZ_OUT 1351 +#define F_TIMETZ_EQ 1352 +#define F_TIMETZ_NE 1353 +#define F_TIMETZ_LT 1354 +#define F_TIMETZ_LE 1355 +#define F_TIMETZ_GE 1356 +#define F_TIMETZ_GT 1357 +#define F_TIMETZ_CMP 1358 +#define F_NETWORK_HOSTMASK 1362 +#define F_MAKEACLITEM 1365 +#define F_TIME_INTERVAL 1370 +#define F_PG_LOCK_STATUS 1371 +#define F_DATE_FINITE 1373 +#define F_TEXTOCTETLEN 1374 +#define F_BPCHAROCTETLEN 1375 +#define F_TIME_LARGER 1377 +#define F_TIME_SMALLER 1378 +#define F_TIMETZ_LARGER 1379 +#define F_TIMETZ_SMALLER 1380 +#define F_TIME_PART 1385 +#define F_PG_GET_CONSTRAINTDEF 1387 +#define F_TIMESTAMPTZ_TIMETZ 1388 +#define F_TIMESTAMP_FINITE 1389 +#define F_INTERVAL_FINITE 1390 +#define F_PG_STAT_GET_BACKEND_START 1391 +#define F_PG_STAT_GET_BACKEND_CLIENT_ADDR 1392 +#define F_PG_STAT_GET_BACKEND_CLIENT_PORT 1393 +#define F_CURRENT_SCHEMA 1402 +#define F_CURRENT_SCHEMAS 1403 +#define F_TEXTOVERLAY 1404 +#define F_TEXTOVERLAY_NO_LEN 1405 +#define F_LINE_PARALLEL 1412 +#define F_LINE_PERP 1413 +#define F_LINE_VERTICAL 1414 +#define F_LINE_HORIZONTAL 1415 +#define F_CIRCLE_CENTER 1416 +#define F_INTERVAL_TIME 1419 +#define F_POINTS_BOX 1421 +#define F_BOX_ADD 1422 +#define F_BOX_SUB 1423 +#define F_BOX_MUL 1424 +#define F_BOX_DIV 1425 +#define F_CIDR_OUT 1427 +#define F_POLY_CONTAIN_PT 1428 +#define F_PT_CONTAINED_POLY 1429 +#define F_PATH_ISCLOSED 1430 +#define F_PATH_ISOPEN 1431 +#define F_PATH_NPOINTS 1432 +#define F_PATH_CLOSE 1433 +#define F_PATH_OPEN 1434 +#define F_PATH_ADD 1435 +#define F_PATH_ADD_PT 1436 +#define F_PATH_SUB_PT 1437 +#define F_PATH_MUL_PT 1438 +#define F_PATH_DIV_PT 1439 +#define F_CONSTRUCT_POINT 1440 +#define F_POINT_ADD 1441 +#define F_POINT_SUB 1442 +#define F_POINT_MUL 1443 +#define F_POINT_DIV 1444 +#define F_POLY_NPOINTS 1445 +#define F_POLY_BOX 1446 +#define F_POLY_PATH 1447 +#define F_BOX_POLY 1448 +#define F_PATH_POLY 1449 +#define F_CIRCLE_IN 1450 +#define F_CIRCLE_OUT 1451 +#define F_CIRCLE_SAME 1452 +#define F_CIRCLE_CONTAIN 1453 +#define F_CIRCLE_LEFT 1454 +#define F_CIRCLE_OVERLEFT 1455 +#define F_CIRCLE_OVERRIGHT 1456 +#define F_CIRCLE_RIGHT 1457 +#define F_CIRCLE_CONTAINED 1458 +#define F_CIRCLE_OVERLAP 1459 +#define F_CIRCLE_BELOW 1460 +#define F_CIRCLE_ABOVE 1461 +#define F_CIRCLE_EQ 1462 +#define F_CIRCLE_NE 1463 +#define F_CIRCLE_LT 1464 +#define F_CIRCLE_GT 1465 +#define F_CIRCLE_LE 1466 +#define F_CIRCLE_GE 1467 +#define F_CIRCLE_AREA 1468 +#define F_CIRCLE_DIAMETER 1469 +#define F_CIRCLE_RADIUS 1470 +#define F_CIRCLE_DISTANCE 1471 +#define F_CR_CIRCLE 1473 +#define F_POLY_CIRCLE 1474 +#define F_CIRCLE_POLY 1475 +#define F_DIST_PC 1476 +#define F_CIRCLE_CONTAIN_PT 1477 +#define F_PT_CONTAINED_CIRCLE 1478 +#define F_BOX_CIRCLE 1479 +#define F_CIRCLE_BOX 1480 +#define F_LSEG_NE 1482 +#define F_LSEG_LT 1483 +#define F_LSEG_LE 1484 +#define F_LSEG_GT 1485 +#define F_LSEG_GE 1486 +#define F_LSEG_LENGTH 1487 +#define F_CLOSE_LS 1488 +#define F_CLOSE_LSEG 1489 +#define F_LINE_IN 1490 +#define F_LINE_OUT 1491 +#define F_LINE_EQ 1492 +#define F_LINE_CONSTRUCT_PP 1493 +#define F_LINE_INTERPT 1494 +#define F_LINE_INTERSECT 1495 +#define F_BIT_IN 1564 +#define F_BIT_OUT 1565 +#define F_PG_GET_RULEDEF 1573 +#define F_NEXTVAL_OID 1574 +#define F_CURRVAL_OID 1575 +#define F_SETVAL_OID 1576 +#define F_VARBIT_IN 1579 +#define F_VARBIT_OUT 1580 +#define F_BITEQ 1581 +#define F_BITNE 1582 +#define F_BITGE 1592 +#define F_BITGT 1593 +#define F_BITLE 1594 +#define F_BITLT 1595 +#define F_BITCMP 1596 +#define F_PG_ENCODING_TO_CHAR 1597 +#define F_DRANDOM 1598 +#define F_SETSEED 1599 +#define F_DASIN 1600 +#define F_DACOS 1601 +#define F_DATAN 1602 +#define F_DATAN2 1603 +#define F_DSIN 1604 +#define F_DCOS 1605 +#define F_DTAN 1606 +#define F_DCOT 1607 +#define F_DEGREES 1608 +#define F_RADIANS 1609 +#define F_DPI 1610 +#define F_INTERVAL_MUL 1618 +#define F_PG_TYPEOF 1619 +#define F_ASCII 1620 +#define F_CHR 1621 +#define F_REPEAT 1622 +#define F_SIMILAR_ESCAPE 1623 +#define F_MUL_D_INTERVAL 1624 +#define F_TEXTICLIKE 1633 +#define F_TEXTICNLIKE 1634 +#define F_NAMEICLIKE 1635 +#define F_NAMEICNLIKE 1636 +#define F_LIKE_ESCAPE 1637 +#define F_OIDGT 1638 +#define F_OIDGE 1639 +#define F_PG_GET_VIEWDEF_NAME 1640 +#define F_PG_GET_VIEWDEF 1641 +#define F_PG_GET_USERBYID 1642 +#define F_PG_GET_INDEXDEF 1643 +#define F_RI_FKEY_CHECK_INS 1644 +#define F_RI_FKEY_CHECK_UPD 1645 +#define F_RI_FKEY_CASCADE_DEL 1646 +#define F_RI_FKEY_CASCADE_UPD 1647 +#define F_RI_FKEY_RESTRICT_DEL 1648 +#define F_RI_FKEY_RESTRICT_UPD 1649 +#define F_RI_FKEY_SETNULL_DEL 1650 +#define F_RI_FKEY_SETNULL_UPD 1651 +#define F_RI_FKEY_SETDEFAULT_DEL 1652 +#define F_RI_FKEY_SETDEFAULT_UPD 1653 +#define F_RI_FKEY_NOACTION_DEL 1654 +#define F_RI_FKEY_NOACTION_UPD 1655 +#define F_PG_GET_TRIGGERDEF 1662 +#define F_PG_GET_SERIAL_SEQUENCE 1665 +#define F_BIT_AND 1673 +#define F_BIT_OR 1674 +#define F_BITXOR 1675 +#define F_BITNOT 1676 +#define F_BITSHIFTLEFT 1677 +#define F_BITSHIFTRIGHT 1678 +#define F_BITCAT 1679 +#define F_BITSUBSTR 1680 +#define F_BITLENGTH 1681 +#define F_BITOCTETLENGTH 1682 +#define F_BITFROMINT4 1683 +#define F_BITTOINT4 1684 +#define F_BIT 1685 +#define F_PG_GET_KEYWORDS 1686 +#define F_VARBIT 1687 +#define F_TIME_HASH 1688 +#define F_ACLEXPLODE 1689 +#define F_TIME_MI_TIME 1690 +#define F_BOOLLE 1691 +#define F_BOOLGE 1692 +#define F_BTBOOLCMP 1693 +#define F_TIMETZ_HASH 1696 +#define F_INTERVAL_HASH 1697 +#define F_BITPOSITION 1698 +#define F_BITSUBSTR_NO_LEN 1699 +#define F_NUMERIC_IN 1701 +#define F_NUMERIC_OUT 1702 +#define F_NUMERIC 1703 +#define F_NUMERIC_ABS 1704 +#define F_NUMERIC_SIGN 1706 +#define F_NUMERIC_ROUND 1707 +#define F_NUMERIC_TRUNC 1709 +#define F_NUMERIC_CEIL 1711 +#define F_NUMERIC_FLOOR 1712 +#define F_LENGTH_IN_ENCODING 1713 +#define F_PG_CONVERT_FROM 1714 +#define F_INET_TO_CIDR 1715 +#define F_PG_GET_EXPR 1716 +#define F_PG_CONVERT_TO 1717 +#define F_NUMERIC_EQ 1718 +#define F_NUMERIC_NE 1719 +#define F_NUMERIC_GT 1720 +#define F_NUMERIC_GE 1721 +#define F_NUMERIC_LT 1722 +#define F_NUMERIC_LE 1723 +#define F_NUMERIC_ADD 1724 +#define F_NUMERIC_SUB 1725 +#define F_NUMERIC_MUL 1726 +#define F_NUMERIC_DIV 1727 +#define F_NUMERIC_MOD 1728 +#define F_NUMERIC_SQRT 1730 +#define F_NUMERIC_EXP 1732 +#define F_NUMERIC_LN 1734 +#define F_NUMERIC_LOG 1736 +#define F_NUMERIC_POWER 1738 +#define F_INT4_NUMERIC 1740 +#define F_FLOAT4_NUMERIC 1742 +#define F_FLOAT8_NUMERIC 1743 +#define F_NUMERIC_INT4 1744 +#define F_NUMERIC_FLOAT4 1745 +#define F_NUMERIC_FLOAT8 1746 +#define F_TIME_PL_INTERVAL 1747 +#define F_TIME_MI_INTERVAL 1748 +#define F_TIMETZ_PL_INTERVAL 1749 +#define F_TIMETZ_MI_INTERVAL 1750 +#define F_NUMERIC_INC 1764 +#define F_SETVAL3_OID 1765 +#define F_NUMERIC_SMALLER 1766 +#define F_NUMERIC_LARGER 1767 +#define F_INTERVAL_TO_CHAR 1768 +#define F_NUMERIC_CMP 1769 +#define F_TIMESTAMPTZ_TO_CHAR 1770 +#define F_NUMERIC_UMINUS 1771 +#define F_NUMERIC_TO_CHAR 1772 +#define F_INT4_TO_CHAR 1773 +#define F_INT8_TO_CHAR 1774 +#define F_FLOAT4_TO_CHAR 1775 +#define F_FLOAT8_TO_CHAR 1776 +#define F_NUMERIC_TO_NUMBER 1777 +#define F_TO_TIMESTAMP 1778 +#define F_NUMERIC_INT8 1779 +#define F_TO_DATE 1780 +#define F_INT8_NUMERIC 1781 +#define F_INT2_NUMERIC 1782 +#define F_NUMERIC_INT2 1783 +#define F_OIDIN 1798 +#define F_OIDOUT 1799 +#define F_PG_CONVERT 1813 +#define F_ICLIKESEL 1814 +#define F_ICNLIKESEL 1815 +#define F_ICLIKEJOINSEL 1816 +#define F_ICNLIKEJOINSEL 1817 +#define F_REGEXEQSEL 1818 +#define F_LIKESEL 1819 +#define F_ICREGEXEQSEL 1820 +#define F_REGEXNESEL 1821 +#define F_NLIKESEL 1822 +#define F_ICREGEXNESEL 1823 +#define F_REGEXEQJOINSEL 1824 +#define F_LIKEJOINSEL 1825 +#define F_ICREGEXEQJOINSEL 1826 +#define F_REGEXNEJOINSEL 1827 +#define F_NLIKEJOINSEL 1828 +#define F_ICREGEXNEJOINSEL 1829 +#define F_FLOAT8_AVG 1830 +#define F_FLOAT8_VAR_SAMP 1831 +#define F_FLOAT8_STDDEV_SAMP 1832 +#define F_NUMERIC_ACCUM 1833 +#define F_INT2_ACCUM 1834 +#define F_INT4_ACCUM 1835 +#define F_INT8_ACCUM 1836 +#define F_NUMERIC_AVG 1837 +#define F_NUMERIC_VAR_SAMP 1838 +#define F_NUMERIC_STDDEV_SAMP 1839 +#define F_INT2_SUM 1840 +#define F_INT4_SUM 1841 +#define F_INT8_SUM 1842 +#define F_INTERVAL_ACCUM 1843 +#define F_INTERVAL_AVG 1844 +#define F_TO_ASCII_DEFAULT 1845 +#define F_TO_ASCII_ENC 1846 +#define F_TO_ASCII_ENCNAME 1847 +#define F_INT28EQ 1850 +#define F_INT28NE 1851 +#define F_INT28LT 1852 +#define F_INT28GT 1853 +#define F_INT28LE 1854 +#define F_INT28GE 1855 +#define F_INT82EQ 1856 +#define F_INT82NE 1857 +#define F_INT82LT 1858 +#define F_INT82GT 1859 +#define F_INT82LE 1860 +#define F_INT82GE 1861 +#define F_INT2AND 1892 +#define F_INT2OR 1893 +#define F_INT2XOR 1894 +#define F_INT2NOT 1895 +#define F_INT2SHL 1896 +#define F_INT2SHR 1897 +#define F_INT4AND 1898 +#define F_INT4OR 1899 +#define F_INT4XOR 1900 +#define F_INT4NOT 1901 +#define F_INT4SHL 1902 +#define F_INT4SHR 1903 +#define F_INT8AND 1904 +#define F_INT8OR 1905 +#define F_INT8XOR 1906 +#define F_INT8NOT 1907 +#define F_INT8SHL 1908 +#define F_INT8SHR 1909 +#define F_INT8UP 1910 +#define F_INT2UP 1911 +#define F_INT4UP 1912 +#define F_FLOAT4UP 1913 +#define F_FLOAT8UP 1914 +#define F_NUMERIC_UPLUS 1915 +#define F_HAS_TABLE_PRIVILEGE_NAME_NAME 1922 +#define F_HAS_TABLE_PRIVILEGE_NAME_ID 1923 +#define F_HAS_TABLE_PRIVILEGE_ID_NAME 1924 +#define F_HAS_TABLE_PRIVILEGE_ID_ID 1925 +#define F_HAS_TABLE_PRIVILEGE_NAME 1926 +#define F_HAS_TABLE_PRIVILEGE_ID 1927 +#define F_PG_STAT_GET_NUMSCANS 1928 +#define F_PG_STAT_GET_TUPLES_RETURNED 1929 +#define F_PG_STAT_GET_TUPLES_FETCHED 1930 +#define F_PG_STAT_GET_TUPLES_INSERTED 1931 +#define F_PG_STAT_GET_TUPLES_UPDATED 1932 +#define F_PG_STAT_GET_TUPLES_DELETED 1933 +#define F_PG_STAT_GET_BLOCKS_FETCHED 1934 +#define F_PG_STAT_GET_BLOCKS_HIT 1935 +#define F_PG_STAT_GET_BACKEND_IDSET 1936 +#define F_PG_STAT_GET_BACKEND_PID 1937 +#define F_PG_STAT_GET_BACKEND_DBID 1938 +#define F_PG_STAT_GET_BACKEND_USERID 1939 +#define F_PG_STAT_GET_BACKEND_ACTIVITY 1940 +#define F_PG_STAT_GET_DB_NUMBACKENDS 1941 +#define F_PG_STAT_GET_DB_XACT_COMMIT 1942 +#define F_PG_STAT_GET_DB_XACT_ROLLBACK 1943 +#define F_PG_STAT_GET_DB_BLOCKS_FETCHED 1944 +#define F_PG_STAT_GET_DB_BLOCKS_HIT 1945 +#define F_BINARY_ENCODE 1946 +#define F_BINARY_DECODE 1947 +#define F_BYTEAEQ 1948 +#define F_BYTEALT 1949 +#define F_BYTEALE 1950 +#define F_BYTEAGT 1951 +#define F_BYTEAGE 1952 +#define F_BYTEANE 1953 +#define F_BYTEACMP 1954 +#define F_TIMESTAMP_SCALE 1961 +#define F_INT2_AVG_ACCUM 1962 +#define F_INT4_AVG_ACCUM 1963 +#define F_INT8_AVG 1964 +#define F_OIDLARGER 1965 +#define F_OIDSMALLER 1966 +#define F_TIMESTAMPTZ_SCALE 1967 +#define F_TIME_SCALE 1968 +#define F_TIMETZ_SCALE 1969 +#define F_PG_STAT_GET_TUPLES_HOT_UPDATED 1972 +#define F_NUMERIC_DIV_TRUNC 1973 +#define F_BYTEALIKE 2005 +#define F_BYTEANLIKE 2006 +#define F_LIKE_ESCAPE_BYTEA 2009 +#define F_BYTEACAT 2011 +#define F_BYTEA_SUBSTR 2012 +#define F_BYTEA_SUBSTR_NO_LEN 2013 +#define F_BYTEAPOS 2014 +#define F_BYTEATRIM 2015 +#define F_TIMESTAMPTZ_TIME 2019 +#define F_TIMESTAMP_TRUNC 2020 +#define F_TIMESTAMP_PART 2021 +#define F_PG_STAT_GET_ACTIVITY 2022 +#define F_ABSTIME_TIMESTAMP 2023 +#define F_DATE_TIMESTAMP 2024 +#define F_PG_BACKEND_PID 2026 +#define F_TIMESTAMPTZ_TIMESTAMP 2027 +#define F_TIMESTAMP_TIMESTAMPTZ 2028 +#define F_TIMESTAMP_DATE 2029 +#define F_TIMESTAMP_ABSTIME 2030 +#define F_TIMESTAMP_PL_INTERVAL 2032 +#define F_TIMESTAMP_MI_INTERVAL 2033 +#define F_PG_CONF_LOAD_TIME 2034 +#define F_TIMETZ_ZONE 2037 +#define F_TIMETZ_IZONE 2038 +#define F_TIMESTAMP_HASH 2039 +#define F_TIMETZ_TIME 2046 +#define F_TIME_TIMETZ 2047 +#define F_TIMESTAMP_TO_CHAR 2049 +#define F_AGGREGATE_DUMMY 2050 +#define F_TIMESTAMP_AGE 2058 +#define F_TIMESTAMP_ZONE 2069 +#define F_TIMESTAMP_IZONE 2070 +#define F_DATE_PL_INTERVAL 2071 +#define F_DATE_MI_INTERVAL 2072 +#define F_TEXTREGEXSUBSTR 2073 +#define F_BITFROMINT8 2075 +#define F_BITTOINT8 2076 +#define F_SHOW_CONFIG_BY_NAME 2077 +#define F_SET_CONFIG_BY_NAME 2078 +#define F_PG_TABLE_IS_VISIBLE 2079 +#define F_PG_TYPE_IS_VISIBLE 2080 +#define F_PG_FUNCTION_IS_VISIBLE 2081 +#define F_PG_OPERATOR_IS_VISIBLE 2082 +#define F_PG_OPCLASS_IS_VISIBLE 2083 +#define F_SHOW_ALL_SETTINGS 2084 +#define F_REPLACE_TEXT 2087 +#define F_SPLIT_TEXT 2088 +#define F_TO_HEX32 2089 +#define F_TO_HEX64 2090 +#define F_ARRAY_LOWER 2091 +#define F_ARRAY_UPPER 2092 +#define F_PG_CONVERSION_IS_VISIBLE 2093 +#define F_PG_STAT_GET_BACKEND_ACTIVITY_START 2094 +#define F_PG_TERMINATE_BACKEND 2096 +#define F_PG_GET_FUNCTIONDEF 2098 +#define F_TEXT_PATTERN_LT 2160 +#define F_TEXT_PATTERN_LE 2161 +#define F_PG_GET_FUNCTION_ARGUMENTS 2162 +#define F_TEXT_PATTERN_GE 2163 +#define F_TEXT_PATTERN_GT 2164 +#define F_PG_GET_FUNCTION_RESULT 2165 +#define F_BTTEXT_PATTERN_CMP 2166 +#define F_PG_DATABASE_SIZE_NAME 2168 +#define F_WIDTH_BUCKET_NUMERIC 2170 +#define F_PG_CANCEL_BACKEND 2171 +#define F_PG_START_BACKUP 2172 +#define F_PG_STOP_BACKUP 2173 +#define F_BPCHAR_PATTERN_LT 2174 +#define F_BPCHAR_PATTERN_LE 2175 +#define F_ARRAY_LENGTH 2176 +#define F_BPCHAR_PATTERN_GE 2177 +#define F_BPCHAR_PATTERN_GT 2178 +#define F_GIST_POINT_CONSISTENT 2179 +#define F_BTBPCHAR_PATTERN_CMP 2180 +#define F_HAS_SEQUENCE_PRIVILEGE_NAME_NAME 2181 +#define F_HAS_SEQUENCE_PRIVILEGE_NAME_ID 2182 +#define F_HAS_SEQUENCE_PRIVILEGE_ID_NAME 2183 +#define F_HAS_SEQUENCE_PRIVILEGE_ID_ID 2184 +#define F_HAS_SEQUENCE_PRIVILEGE_NAME 2185 +#define F_HAS_SEQUENCE_PRIVILEGE_ID 2186 +#define F_BTINT48CMP 2188 +#define F_BTINT84CMP 2189 +#define F_BTINT24CMP 2190 +#define F_BTINT42CMP 2191 +#define F_BTINT28CMP 2192 +#define F_BTINT82CMP 2193 +#define F_BTFLOAT48CMP 2194 +#define F_BTFLOAT84CMP 2195 +#define F_INET_CLIENT_ADDR 2196 +#define F_INET_CLIENT_PORT 2197 +#define F_INET_SERVER_ADDR 2198 +#define F_INET_SERVER_PORT 2199 +#define F_REGPROCEDUREIN 2212 +#define F_REGPROCEDUREOUT 2213 +#define F_REGOPERIN 2214 +#define F_REGOPEROUT 2215 +#define F_REGOPERATORIN 2216 +#define F_REGOPERATOROUT 2217 +#define F_REGCLASSIN 2218 +#define F_REGCLASSOUT 2219 +#define F_REGTYPEIN 2220 +#define F_REGTYPEOUT 2221 +#define F_PG_STAT_CLEAR_SNAPSHOT 2230 +#define F_PG_GET_FUNCTION_IDENTITY_ARGUMENTS 2232 +#define F_FMGR_INTERNAL_VALIDATOR 2246 +#define F_FMGR_C_VALIDATOR 2247 +#define F_FMGR_SQL_VALIDATOR 2248 +#define F_HAS_DATABASE_PRIVILEGE_NAME_NAME 2250 +#define F_HAS_DATABASE_PRIVILEGE_NAME_ID 2251 +#define F_HAS_DATABASE_PRIVILEGE_ID_NAME 2252 +#define F_HAS_DATABASE_PRIVILEGE_ID_ID 2253 +#define F_HAS_DATABASE_PRIVILEGE_NAME 2254 +#define F_HAS_DATABASE_PRIVILEGE_ID 2255 +#define F_HAS_FUNCTION_PRIVILEGE_NAME_NAME 2256 +#define F_HAS_FUNCTION_PRIVILEGE_NAME_ID 2257 +#define F_HAS_FUNCTION_PRIVILEGE_ID_NAME 2258 +#define F_HAS_FUNCTION_PRIVILEGE_ID_ID 2259 +#define F_HAS_FUNCTION_PRIVILEGE_NAME 2260 +#define F_HAS_FUNCTION_PRIVILEGE_ID 2261 +#define F_HAS_LANGUAGE_PRIVILEGE_NAME_NAME 2262 +#define F_HAS_LANGUAGE_PRIVILEGE_NAME_ID 2263 +#define F_HAS_LANGUAGE_PRIVILEGE_ID_NAME 2264 +#define F_HAS_LANGUAGE_PRIVILEGE_ID_ID 2265 +#define F_HAS_LANGUAGE_PRIVILEGE_NAME 2266 +#define F_HAS_LANGUAGE_PRIVILEGE_ID 2267 +#define F_HAS_SCHEMA_PRIVILEGE_NAME_NAME 2268 +#define F_HAS_SCHEMA_PRIVILEGE_NAME_ID 2269 +#define F_HAS_SCHEMA_PRIVILEGE_ID_NAME 2270 +#define F_HAS_SCHEMA_PRIVILEGE_ID_ID 2271 +#define F_HAS_SCHEMA_PRIVILEGE_NAME 2272 +#define F_HAS_SCHEMA_PRIVILEGE_ID 2273 +#define F_PG_STAT_RESET 2274 +#define F_TEXTREGEXREPLACE_NOOPT 2284 +#define F_TEXTREGEXREPLACE 2285 +#define F_PG_TOTAL_RELATION_SIZE 2286 +#define F_PG_SIZE_PRETTY 2288 +#define F_PG_OPTIONS_TO_TABLE 2289 +#define F_RECORD_IN 2290 +#define F_RECORD_OUT 2291 +#define F_CSTRING_IN 2292 +#define F_CSTRING_OUT 2293 +#define F_ANY_IN 2294 +#define F_ANY_OUT 2295 +#define F_ANYARRAY_IN 2296 +#define F_ANYARRAY_OUT 2297 +#define F_VOID_IN 2298 +#define F_VOID_OUT 2299 +#define F_TRIGGER_IN 2300 +#define F_TRIGGER_OUT 2301 +#define F_LANGUAGE_HANDLER_IN 2302 +#define F_LANGUAGE_HANDLER_OUT 2303 +#define F_INTERNAL_IN 2304 +#define F_INTERNAL_OUT 2305 +#define F_OPAQUE_IN 2306 +#define F_OPAQUE_OUT 2307 +#define F_DCEIL 2308 +#define F_DFLOOR 2309 +#define F_DSIGN 2310 +#define F_MD5_TEXT 2311 +#define F_ANYELEMENT_IN 2312 +#define F_ANYELEMENT_OUT 2313 +#define F_POSTGRESQL_FDW_VALIDATOR 2316 +#define F_PG_ENCODING_MAX_LENGTH_SQL 2319 +#define F_MD5_BYTEA 2321 +#define F_PG_TABLESPACE_SIZE_OID 2322 +#define F_PG_TABLESPACE_SIZE_NAME 2323 +#define F_PG_DATABASE_SIZE_OID 2324 +#define F_ARRAY_UNNEST 2331 +#define F_PG_RELATION_SIZE 2332 +#define F_ARRAY_AGG_TRANSFN 2333 +#define F_ARRAY_AGG_FINALFN 2334 +#define F_DATE_LT_TIMESTAMP 2338 +#define F_DATE_LE_TIMESTAMP 2339 +#define F_DATE_EQ_TIMESTAMP 2340 +#define F_DATE_GT_TIMESTAMP 2341 +#define F_DATE_GE_TIMESTAMP 2342 +#define F_DATE_NE_TIMESTAMP 2343 +#define F_DATE_CMP_TIMESTAMP 2344 +#define F_DATE_LT_TIMESTAMPTZ 2351 +#define F_DATE_LE_TIMESTAMPTZ 2352 +#define F_DATE_EQ_TIMESTAMPTZ 2353 +#define F_DATE_GT_TIMESTAMPTZ 2354 +#define F_DATE_GE_TIMESTAMPTZ 2355 +#define F_DATE_NE_TIMESTAMPTZ 2356 +#define F_DATE_CMP_TIMESTAMPTZ 2357 +#define F_TIMESTAMP_LT_DATE 2364 +#define F_TIMESTAMP_LE_DATE 2365 +#define F_TIMESTAMP_EQ_DATE 2366 +#define F_TIMESTAMP_GT_DATE 2367 +#define F_TIMESTAMP_GE_DATE 2368 +#define F_TIMESTAMP_NE_DATE 2369 +#define F_TIMESTAMP_CMP_DATE 2370 +#define F_TIMESTAMPTZ_LT_DATE 2377 +#define F_TIMESTAMPTZ_LE_DATE 2378 +#define F_TIMESTAMPTZ_EQ_DATE 2379 +#define F_TIMESTAMPTZ_GT_DATE 2380 +#define F_TIMESTAMPTZ_GE_DATE 2381 +#define F_TIMESTAMPTZ_NE_DATE 2382 +#define F_TIMESTAMPTZ_CMP_DATE 2383 +#define F_HAS_TABLESPACE_PRIVILEGE_NAME_NAME 2390 +#define F_HAS_TABLESPACE_PRIVILEGE_NAME_ID 2391 +#define F_HAS_TABLESPACE_PRIVILEGE_ID_NAME 2392 +#define F_HAS_TABLESPACE_PRIVILEGE_ID_ID 2393 +#define F_HAS_TABLESPACE_PRIVILEGE_NAME 2394 +#define F_HAS_TABLESPACE_PRIVILEGE_ID 2395 +#define F_SHELL_IN 2398 +#define F_SHELL_OUT 2399 +#define F_ARRAY_RECV 2400 +#define F_ARRAY_SEND 2401 +#define F_RECORD_RECV 2402 +#define F_RECORD_SEND 2403 +#define F_INT2RECV 2404 +#define F_INT2SEND 2405 +#define F_INT4RECV 2406 +#define F_INT4SEND 2407 +#define F_INT8RECV 2408 +#define F_INT8SEND 2409 +#define F_INT2VECTORRECV 2410 +#define F_INT2VECTORSEND 2411 +#define F_BYTEARECV 2412 +#define F_BYTEASEND 2413 +#define F_TEXTRECV 2414 +#define F_TEXTSEND 2415 +#define F_UNKNOWNRECV 2416 +#define F_UNKNOWNSEND 2417 +#define F_OIDRECV 2418 +#define F_OIDSEND 2419 +#define F_OIDVECTORRECV 2420 +#define F_OIDVECTORSEND 2421 +#define F_NAMERECV 2422 +#define F_NAMESEND 2423 +#define F_FLOAT4RECV 2424 +#define F_FLOAT4SEND 2425 +#define F_FLOAT8RECV 2426 +#define F_FLOAT8SEND 2427 +#define F_POINT_RECV 2428 +#define F_POINT_SEND 2429 +#define F_BPCHARRECV 2430 +#define F_BPCHARSEND 2431 +#define F_VARCHARRECV 2432 +#define F_VARCHARSEND 2433 +#define F_CHARRECV 2434 +#define F_CHARSEND 2435 +#define F_BOOLRECV 2436 +#define F_BOOLSEND 2437 +#define F_TIDRECV 2438 +#define F_TIDSEND 2439 +#define F_XIDRECV 2440 +#define F_XIDSEND 2441 +#define F_CIDRECV 2442 +#define F_CIDSEND 2443 +#define F_REGPROCRECV 2444 +#define F_REGPROCSEND 2445 +#define F_REGPROCEDURERECV 2446 +#define F_REGPROCEDURESEND 2447 +#define F_REGOPERRECV 2448 +#define F_REGOPERSEND 2449 +#define F_REGOPERATORRECV 2450 +#define F_REGOPERATORSEND 2451 +#define F_REGCLASSRECV 2452 +#define F_REGCLASSSEND 2453 +#define F_REGTYPERECV 2454 +#define F_REGTYPESEND 2455 +#define F_BIT_RECV 2456 +#define F_BIT_SEND 2457 +#define F_VARBIT_RECV 2458 +#define F_VARBIT_SEND 2459 +#define F_NUMERIC_RECV 2460 +#define F_NUMERIC_SEND 2461 +#define F_ABSTIMERECV 2462 +#define F_ABSTIMESEND 2463 +#define F_RELTIMERECV 2464 +#define F_RELTIMESEND 2465 +#define F_TINTERVALRECV 2466 +#define F_TINTERVALSEND 2467 +#define F_DATE_RECV 2468 +#define F_DATE_SEND 2469 +#define F_TIME_RECV 2470 +#define F_TIME_SEND 2471 +#define F_TIMETZ_RECV 2472 +#define F_TIMETZ_SEND 2473 +#define F_TIMESTAMP_RECV 2474 +#define F_TIMESTAMP_SEND 2475 +#define F_TIMESTAMPTZ_RECV 2476 +#define F_TIMESTAMPTZ_SEND 2477 +#define F_INTERVAL_RECV 2478 +#define F_INTERVAL_SEND 2479 +#define F_LSEG_RECV 2480 +#define F_LSEG_SEND 2481 +#define F_PATH_RECV 2482 +#define F_PATH_SEND 2483 +#define F_BOX_RECV 2484 +#define F_BOX_SEND 2485 +#define F_POLY_RECV 2486 +#define F_POLY_SEND 2487 +#define F_LINE_RECV 2488 +#define F_LINE_SEND 2489 +#define F_CIRCLE_RECV 2490 +#define F_CIRCLE_SEND 2491 +#define F_CASH_RECV 2492 +#define F_CASH_SEND 2493 +#define F_MACADDR_RECV 2494 +#define F_MACADDR_SEND 2495 +#define F_INET_RECV 2496 +#define F_INET_SEND 2497 +#define F_CIDR_RECV 2498 +#define F_CIDR_SEND 2499 +#define F_CSTRING_RECV 2500 +#define F_CSTRING_SEND 2501 +#define F_ANYARRAY_RECV 2502 +#define F_ANYARRAY_SEND 2503 +#define F_PG_GET_RULEDEF_EXT 2504 +#define F_PG_GET_VIEWDEF_NAME_EXT 2505 +#define F_PG_GET_VIEWDEF_EXT 2506 +#define F_PG_GET_INDEXDEF_EXT 2507 +#define F_PG_GET_CONSTRAINTDEF_EXT 2508 +#define F_PG_GET_EXPR_EXT 2509 +#define F_PG_PREPARED_STATEMENT 2510 +#define F_PG_CURSOR 2511 +#define F_FLOAT8_VAR_POP 2512 +#define F_FLOAT8_STDDEV_POP 2513 +#define F_NUMERIC_VAR_POP 2514 +#define F_BOOLAND_STATEFUNC 2515 +#define F_BOOLOR_STATEFUNC 2516 +#define F_TIMESTAMP_LT_TIMESTAMPTZ 2520 +#define F_TIMESTAMP_LE_TIMESTAMPTZ 2521 +#define F_TIMESTAMP_EQ_TIMESTAMPTZ 2522 +#define F_TIMESTAMP_GT_TIMESTAMPTZ 2523 +#define F_TIMESTAMP_GE_TIMESTAMPTZ 2524 +#define F_TIMESTAMP_NE_TIMESTAMPTZ 2525 +#define F_TIMESTAMP_CMP_TIMESTAMPTZ 2526 +#define F_TIMESTAMPTZ_LT_TIMESTAMP 2527 +#define F_TIMESTAMPTZ_LE_TIMESTAMP 2528 +#define F_TIMESTAMPTZ_EQ_TIMESTAMP 2529 +#define F_TIMESTAMPTZ_GT_TIMESTAMP 2530 +#define F_TIMESTAMPTZ_GE_TIMESTAMP 2531 +#define F_TIMESTAMPTZ_NE_TIMESTAMP 2532 +#define F_TIMESTAMPTZ_CMP_TIMESTAMP 2533 +#define F_PG_TABLESPACE_DATABASES 2556 +#define F_INT4_BOOL 2557 +#define F_BOOL_INT4 2558 +#define F_LASTVAL 2559 +#define F_PG_POSTMASTER_START_TIME 2560 +#define F_GISTVACUUMCLEANUP 2561 +#define F_BOX_BELOW 2562 +#define F_BOX_OVERBELOW 2563 +#define F_BOX_OVERABOVE 2564 +#define F_BOX_ABOVE 2565 +#define F_POLY_BELOW 2566 +#define F_POLY_OVERBELOW 2567 +#define F_POLY_OVERABOVE 2568 +#define F_POLY_ABOVE 2569 +#define F_GIST_BOX_CONSISTENT 2578 +#define F_GIST_BOX_COMPRESS 2579 +#define F_GIST_BOX_DECOMPRESS 2580 +#define F_GIST_BOX_PENALTY 2581 +#define F_GIST_BOX_PICKSPLIT 2582 +#define F_GIST_BOX_UNION 2583 +#define F_GIST_BOX_SAME 2584 +#define F_GIST_POLY_CONSISTENT 2585 +#define F_GIST_POLY_COMPRESS 2586 +#define F_CIRCLE_OVERBELOW 2587 +#define F_CIRCLE_OVERABOVE 2588 +#define F_GIST_CIRCLE_CONSISTENT 2591 +#define F_GIST_CIRCLE_COMPRESS 2592 +#define F_NUMERIC_STDDEV_POP 2596 +#define F_DOMAIN_IN 2597 +#define F_DOMAIN_RECV 2598 +#define F_PG_TIMEZONE_ABBREVS 2599 +#define F_XMLEXISTS 2614 +#define F_PG_RELOAD_CONF 2621 +#define F_PG_ROTATE_LOGFILE 2622 +#define F_PG_STAT_FILE 2623 +#define F_PG_READ_FILE 2624 +#define F_PG_LS_DIR 2625 +#define F_PG_SLEEP 2626 +#define F_INETNOT 2627 +#define F_INETAND 2628 +#define F_INETOR 2629 +#define F_INETPL 2630 +#define F_INETMI_INT8 2632 +#define F_INETMI 2633 +#define F_STATEMENT_TIMESTAMP 2648 +#define F_CLOCK_TIMESTAMP 2649 +#define F_GIN_CMP_PREFIX 2700 +#define F_PG_HAS_ROLE_NAME_NAME 2705 +#define F_PG_HAS_ROLE_NAME_ID 2706 +#define F_PG_HAS_ROLE_ID_NAME 2707 +#define F_PG_HAS_ROLE_ID_ID 2708 +#define F_PG_HAS_ROLE_NAME 2709 +#define F_PG_HAS_ROLE_ID 2710 +#define F_INTERVAL_JUSTIFY_INTERVAL 2711 +#define F_PG_GET_TRIGGERDEF_EXT 2730 +#define F_GINGETBITMAP 2731 +#define F_GININSERT 2732 +#define F_GINBEGINSCAN 2733 +#define F_GINRESCAN 2734 +#define F_GINENDSCAN 2735 +#define F_GINMARKPOS 2736 +#define F_GINRESTRPOS 2737 +#define F_GINBUILD 2738 +#define F_GINBULKDELETE 2739 +#define F_GINVACUUMCLEANUP 2740 +#define F_GINCOSTESTIMATE 2741 +#define F_GINARRAYEXTRACT 2743 +#define F_GINARRAYCONSISTENT 2744 +#define F_INT8_AVG_ACCUM 2746 +#define F_ARRAYOVERLAP 2747 +#define F_ARRAYCONTAINS 2748 +#define F_ARRAYCONTAINED 2749 +#define F_PG_STAT_GET_DB_TUPLES_RETURNED 2758 +#define F_PG_STAT_GET_DB_TUPLES_FETCHED 2759 +#define F_PG_STAT_GET_DB_TUPLES_INSERTED 2760 +#define F_PG_STAT_GET_DB_TUPLES_UPDATED 2761 +#define F_PG_STAT_GET_DB_TUPLES_DELETED 2762 +#define F_REGEXP_MATCHES_NO_FLAGS 2763 +#define F_REGEXP_MATCHES 2764 +#define F_REGEXP_SPLIT_TO_TABLE_NO_FLAGS 2765 +#define F_REGEXP_SPLIT_TO_TABLE 2766 +#define F_REGEXP_SPLIT_TO_ARRAY_NO_FLAGS 2767 +#define F_REGEXP_SPLIT_TO_ARRAY 2768 +#define F_PG_STAT_GET_BGWRITER_TIMED_CHECKPOINTS 2769 +#define F_PG_STAT_GET_BGWRITER_REQUESTED_CHECKPOINTS 2770 +#define F_PG_STAT_GET_BGWRITER_BUF_WRITTEN_CHECKPOINTS 2771 +#define F_PG_STAT_GET_BGWRITER_BUF_WRITTEN_CLEAN 2772 +#define F_PG_STAT_GET_BGWRITER_MAXWRITTEN_CLEAN 2773 +#define F_GINQUERYARRAYEXTRACT 2774 +#define F_PG_STAT_GET_BUF_WRITTEN_BACKEND 2775 +#define F_ANYNONARRAY_IN 2777 +#define F_ANYNONARRAY_OUT 2778 +#define F_PG_STAT_GET_LAST_VACUUM_TIME 2781 +#define F_PG_STAT_GET_LAST_AUTOVACUUM_TIME 2782 +#define F_PG_STAT_GET_LAST_ANALYZE_TIME 2783 +#define F_PG_STAT_GET_LAST_AUTOANALYZE_TIME 2784 +#define F_BTOPTIONS 2785 +#define F_HASHOPTIONS 2786 +#define F_GISTOPTIONS 2787 +#define F_GINOPTIONS 2788 +#define F_TIDGT 2790 +#define F_TIDLT 2791 +#define F_TIDGE 2792 +#define F_TIDLE 2793 +#define F_BTTIDCMP 2794 +#define F_TIDLARGER 2795 +#define F_TIDSMALLER 2796 +#define F_INT8INC_ANY 2804 +#define F_INT8INC_FLOAT8_FLOAT8 2805 +#define F_FLOAT8_REGR_ACCUM 2806 +#define F_FLOAT8_REGR_SXX 2807 +#define F_FLOAT8_REGR_SYY 2808 +#define F_FLOAT8_REGR_SXY 2809 +#define F_FLOAT8_REGR_AVGX 2810 +#define F_FLOAT8_REGR_AVGY 2811 +#define F_FLOAT8_REGR_R2 2812 +#define F_FLOAT8_REGR_SLOPE 2813 +#define F_FLOAT8_REGR_INTERCEPT 2814 +#define F_FLOAT8_COVAR_POP 2815 +#define F_FLOAT8_COVAR_SAMP 2816 +#define F_FLOAT8_CORR 2817 +#define F_PG_STAT_GET_DB_BLK_READ_TIME 2844 +#define F_PG_STAT_GET_DB_BLK_WRITE_TIME 2845 +#define F_PG_SWITCH_XLOG 2848 +#define F_PG_CURRENT_XLOG_LOCATION 2849 +#define F_PG_XLOGFILE_NAME_OFFSET 2850 +#define F_PG_XLOGFILE_NAME 2851 +#define F_PG_CURRENT_XLOG_INSERT_LOCATION 2852 +#define F_PG_STAT_GET_BACKEND_WAITING 2853 +#define F_PG_MY_TEMP_SCHEMA 2854 +#define F_PG_IS_OTHER_TEMP_SCHEMA 2855 +#define F_PG_TIMEZONE_NAMES 2856 +#define F_PG_STAT_GET_BACKEND_XACT_START 2857 +#define F_NUMERIC_AVG_ACCUM 2858 +#define F_PG_STAT_GET_BUF_ALLOC 2859 +#define F_PG_STAT_GET_LIVE_TUPLES 2878 +#define F_PG_STAT_GET_DEAD_TUPLES 2879 +#define F_PG_ADVISORY_LOCK_INT8 2880 +#define F_PG_ADVISORY_LOCK_SHARED_INT8 2881 +#define F_PG_TRY_ADVISORY_LOCK_INT8 2882 +#define F_PG_TRY_ADVISORY_LOCK_SHARED_INT8 2883 +#define F_PG_ADVISORY_UNLOCK_INT8 2884 +#define F_PG_ADVISORY_UNLOCK_SHARED_INT8 2885 +#define F_PG_ADVISORY_LOCK_INT4 2886 +#define F_PG_ADVISORY_LOCK_SHARED_INT4 2887 +#define F_PG_TRY_ADVISORY_LOCK_INT4 2888 +#define F_PG_TRY_ADVISORY_LOCK_SHARED_INT4 2889 +#define F_PG_ADVISORY_UNLOCK_INT4 2890 +#define F_PG_ADVISORY_UNLOCK_SHARED_INT4 2891 +#define F_PG_ADVISORY_UNLOCK_ALL 2892 +#define F_XML_IN 2893 +#define F_XML_OUT 2894 +#define F_XMLCOMMENT 2895 +#define F_TEXTTOXML 2896 +#define F_XMLVALIDATE 2897 +#define F_XML_RECV 2898 +#define F_XML_SEND 2899 +#define F_XMLCONCAT2 2900 +#define F_VARBITTYPMODIN 2902 +#define F_INTERVALTYPMODIN 2903 +#define F_INTERVALTYPMODOUT 2904 +#define F_TIMESTAMPTYPMODIN 2905 +#define F_TIMESTAMPTYPMODOUT 2906 +#define F_TIMESTAMPTZTYPMODIN 2907 +#define F_TIMESTAMPTZTYPMODOUT 2908 +#define F_TIMETYPMODIN 2909 +#define F_TIMETYPMODOUT 2910 +#define F_TIMETZTYPMODIN 2911 +#define F_TIMETZTYPMODOUT 2912 +#define F_BPCHARTYPMODIN 2913 +#define F_BPCHARTYPMODOUT 2914 +#define F_VARCHARTYPMODIN 2915 +#define F_VARCHARTYPMODOUT 2916 +#define F_NUMERICTYPMODIN 2917 +#define F_NUMERICTYPMODOUT 2918 +#define F_BITTYPMODIN 2919 +#define F_BITTYPMODOUT 2920 +#define F_VARBITTYPMODOUT 2921 +#define F_XMLTOTEXT 2922 +#define F_TABLE_TO_XML 2923 +#define F_QUERY_TO_XML 2924 +#define F_CURSOR_TO_XML 2925 +#define F_TABLE_TO_XMLSCHEMA 2926 +#define F_QUERY_TO_XMLSCHEMA 2927 +#define F_CURSOR_TO_XMLSCHEMA 2928 +#define F_TABLE_TO_XML_AND_XMLSCHEMA 2929 +#define F_QUERY_TO_XML_AND_XMLSCHEMA 2930 +#define F_XPATH 2931 +#define F_SCHEMA_TO_XML 2933 +#define F_SCHEMA_TO_XMLSCHEMA 2934 +#define F_SCHEMA_TO_XML_AND_XMLSCHEMA 2935 +#define F_DATABASE_TO_XML 2936 +#define F_DATABASE_TO_XMLSCHEMA 2937 +#define F_DATABASE_TO_XML_AND_XMLSCHEMA 2938 +#define F_TXID_SNAPSHOT_IN 2939 +#define F_TXID_SNAPSHOT_OUT 2940 +#define F_TXID_SNAPSHOT_RECV 2941 +#define F_TXID_SNAPSHOT_SEND 2942 +#define F_TXID_CURRENT 2943 +#define F_TXID_CURRENT_SNAPSHOT 2944 +#define F_TXID_SNAPSHOT_XMIN 2945 +#define F_TXID_SNAPSHOT_XMAX 2946 +#define F_TXID_SNAPSHOT_XIP 2947 +#define F_TXID_VISIBLE_IN_SNAPSHOT 2948 +#define F_UUID_IN 2952 +#define F_UUID_OUT 2953 +#define F_UUID_LT 2954 +#define F_UUID_LE 2955 +#define F_UUID_EQ 2956 +#define F_UUID_GE 2957 +#define F_UUID_GT 2958 +#define F_UUID_NE 2959 +#define F_UUID_CMP 2960 +#define F_UUID_RECV 2961 +#define F_UUID_SEND 2962 +#define F_UUID_HASH 2963 +#define F_BOOLTEXT 2971 +#define F_PG_STAT_GET_FUNCTION_CALLS 2978 +#define F_PG_STAT_GET_FUNCTION_TOTAL_TIME 2979 +#define F_PG_STAT_GET_FUNCTION_SELF_TIME 2980 +#define F_RECORD_EQ 2981 +#define F_RECORD_NE 2982 +#define F_RECORD_LT 2983 +#define F_RECORD_GT 2984 +#define F_RECORD_LE 2985 +#define F_RECORD_GE 2986 +#define F_BTRECORDCMP 2987 +#define F_PG_TABLE_SIZE 2997 +#define F_PG_INDEXES_SIZE 2998 +#define F_PG_RELATION_FILENODE 2999 +#define F_HAS_FOREIGN_DATA_WRAPPER_PRIVILEGE_NAME_NAME 3000 +#define F_HAS_FOREIGN_DATA_WRAPPER_PRIVILEGE_NAME_ID 3001 +#define F_HAS_FOREIGN_DATA_WRAPPER_PRIVILEGE_ID_NAME 3002 +#define F_HAS_FOREIGN_DATA_WRAPPER_PRIVILEGE_ID_ID 3003 +#define F_HAS_FOREIGN_DATA_WRAPPER_PRIVILEGE_NAME 3004 +#define F_HAS_FOREIGN_DATA_WRAPPER_PRIVILEGE_ID 3005 +#define F_HAS_SERVER_PRIVILEGE_NAME_NAME 3006 +#define F_HAS_SERVER_PRIVILEGE_NAME_ID 3007 +#define F_HAS_SERVER_PRIVILEGE_ID_NAME 3008 +#define F_HAS_SERVER_PRIVILEGE_ID_ID 3009 +#define F_HAS_SERVER_PRIVILEGE_NAME 3010 +#define F_HAS_SERVER_PRIVILEGE_ID 3011 +#define F_HAS_COLUMN_PRIVILEGE_NAME_NAME_NAME 3012 +#define F_HAS_COLUMN_PRIVILEGE_NAME_NAME_ATTNUM 3013 +#define F_HAS_COLUMN_PRIVILEGE_NAME_ID_NAME 3014 +#define F_HAS_COLUMN_PRIVILEGE_NAME_ID_ATTNUM 3015 +#define F_HAS_COLUMN_PRIVILEGE_ID_NAME_NAME 3016 +#define F_HAS_COLUMN_PRIVILEGE_ID_NAME_ATTNUM 3017 +#define F_HAS_COLUMN_PRIVILEGE_ID_ID_NAME 3018 +#define F_HAS_COLUMN_PRIVILEGE_ID_ID_ATTNUM 3019 +#define F_HAS_COLUMN_PRIVILEGE_NAME_NAME 3020 +#define F_HAS_COLUMN_PRIVILEGE_NAME_ATTNUM 3021 +#define F_HAS_COLUMN_PRIVILEGE_ID_NAME 3022 +#define F_HAS_COLUMN_PRIVILEGE_ID_ATTNUM 3023 +#define F_HAS_ANY_COLUMN_PRIVILEGE_NAME_NAME 3024 +#define F_HAS_ANY_COLUMN_PRIVILEGE_NAME_ID 3025 +#define F_HAS_ANY_COLUMN_PRIVILEGE_ID_NAME 3026 +#define F_HAS_ANY_COLUMN_PRIVILEGE_ID_ID 3027 +#define F_HAS_ANY_COLUMN_PRIVILEGE_NAME 3028 +#define F_HAS_ANY_COLUMN_PRIVILEGE_ID 3029 +#define F_BITOVERLAY 3030 +#define F_BITOVERLAY_NO_LEN 3031 +#define F_BITGETBIT 3032 +#define F_BITSETBIT 3033 +#define F_PG_RELATION_FILEPATH 3034 +#define F_PG_LISTENING_CHANNELS 3035 +#define F_PG_NOTIFY 3036 +#define F_PG_STAT_GET_XACT_NUMSCANS 3037 +#define F_PG_STAT_GET_XACT_TUPLES_RETURNED 3038 +#define F_PG_STAT_GET_XACT_TUPLES_FETCHED 3039 +#define F_PG_STAT_GET_XACT_TUPLES_INSERTED 3040 +#define F_PG_STAT_GET_XACT_TUPLES_UPDATED 3041 +#define F_PG_STAT_GET_XACT_TUPLES_DELETED 3042 +#define F_PG_STAT_GET_XACT_TUPLES_HOT_UPDATED 3043 +#define F_PG_STAT_GET_XACT_BLOCKS_FETCHED 3044 +#define F_PG_STAT_GET_XACT_BLOCKS_HIT 3045 +#define F_PG_STAT_GET_XACT_FUNCTION_CALLS 3046 +#define F_PG_STAT_GET_XACT_FUNCTION_TOTAL_TIME 3047 +#define F_PG_STAT_GET_XACT_FUNCTION_SELF_TIME 3048 +#define F_XPATH_EXISTS 3049 +#define F_XML_IS_WELL_FORMED 3051 +#define F_XML_IS_WELL_FORMED_DOCUMENT 3052 +#define F_XML_IS_WELL_FORMED_CONTENT 3053 +#define F_PG_STAT_GET_VACUUM_COUNT 3054 +#define F_PG_STAT_GET_AUTOVACUUM_COUNT 3055 +#define F_PG_STAT_GET_ANALYZE_COUNT 3056 +#define F_PG_STAT_GET_AUTOANALYZE_COUNT 3057 +#define F_TEXT_CONCAT 3058 +#define F_TEXT_CONCAT_WS 3059 +#define F_TEXT_LEFT 3060 +#define F_TEXT_RIGHT 3061 +#define F_TEXT_REVERSE 3062 +#define F_PG_STAT_GET_BUF_FSYNC_BACKEND 3063 +#define F_GIST_POINT_DISTANCE 3064 +#define F_PG_STAT_GET_DB_CONFLICT_TABLESPACE 3065 +#define F_PG_STAT_GET_DB_CONFLICT_LOCK 3066 +#define F_PG_STAT_GET_DB_CONFLICT_SNAPSHOT 3067 +#define F_PG_STAT_GET_DB_CONFLICT_BUFFERPIN 3068 +#define F_PG_STAT_GET_DB_CONFLICT_STARTUP_DEADLOCK 3069 +#define F_PG_STAT_GET_DB_CONFLICT_ALL 3070 +#define F_PG_XLOG_REPLAY_PAUSE 3071 +#define F_PG_XLOG_REPLAY_RESUME 3072 +#define F_PG_IS_XLOG_REPLAY_PAUSED 3073 +#define F_PG_STAT_GET_DB_STAT_RESET_TIME 3074 +#define F_PG_STAT_GET_BGWRITER_STAT_RESET_TIME 3075 +#define F_GINARRAYEXTRACT_2ARGS 3076 +#define F_GIN_EXTRACT_TSVECTOR_2ARGS 3077 +#define F_PG_SEQUENCE_PARAMETERS 3078 +#define F_PG_AVAILABLE_EXTENSIONS 3082 +#define F_PG_AVAILABLE_EXTENSION_VERSIONS 3083 +#define F_PG_EXTENSION_UPDATE_PATHS 3084 +#define F_PG_EXTENSION_CONFIG_DUMP 3086 +#define F_GIN_EXTRACT_TSQUERY_5ARGS 3087 +#define F_GIN_TSQUERY_CONSISTENT_6ARGS 3088 +#define F_PG_ADVISORY_XACT_LOCK_INT8 3089 +#define F_PG_ADVISORY_XACT_LOCK_SHARED_INT8 3090 +#define F_PG_TRY_ADVISORY_XACT_LOCK_INT8 3091 +#define F_PG_TRY_ADVISORY_XACT_LOCK_SHARED_INT8 3092 +#define F_PG_ADVISORY_XACT_LOCK_INT4 3093 +#define F_PG_ADVISORY_XACT_LOCK_SHARED_INT4 3094 +#define F_PG_TRY_ADVISORY_XACT_LOCK_INT4 3095 +#define F_PG_TRY_ADVISORY_XACT_LOCK_SHARED_INT4 3096 +#define F_VARCHAR_TRANSFORM 3097 +#define F_PG_CREATE_RESTORE_POINT 3098 +#define F_PG_STAT_GET_WAL_SENDERS 3099 +#define F_WINDOW_ROW_NUMBER 3100 +#define F_WINDOW_RANK 3101 +#define F_WINDOW_DENSE_RANK 3102 +#define F_WINDOW_PERCENT_RANK 3103 +#define F_WINDOW_CUME_DIST 3104 +#define F_WINDOW_NTILE 3105 +#define F_WINDOW_LAG 3106 +#define F_WINDOW_LAG_WITH_OFFSET 3107 +#define F_WINDOW_LAG_WITH_OFFSET_AND_DEFAULT 3108 +#define F_WINDOW_LEAD 3109 +#define F_WINDOW_LEAD_WITH_OFFSET 3110 +#define F_WINDOW_LEAD_WITH_OFFSET_AND_DEFAULT 3111 +#define F_WINDOW_FIRST_VALUE 3112 +#define F_WINDOW_LAST_VALUE 3113 +#define F_WINDOW_NTH_VALUE 3114 +#define F_FDW_HANDLER_IN 3116 +#define F_FDW_HANDLER_OUT 3117 +#define F_VOID_RECV 3120 +#define F_VOID_SEND 3121 +#define F_BTINT2SORTSUPPORT 3129 +#define F_BTINT4SORTSUPPORT 3130 +#define F_BTINT8SORTSUPPORT 3131 +#define F_BTFLOAT4SORTSUPPORT 3132 +#define F_BTFLOAT8SORTSUPPORT 3133 +#define F_BTOIDSORTSUPPORT 3134 +#define F_BTNAMESORTSUPPORT 3135 +#define F_DATE_SORTSUPPORT 3136 +#define F_TIMESTAMP_SORTSUPPORT 3137 +#define F_HAS_TYPE_PRIVILEGE_NAME_NAME 3138 +#define F_HAS_TYPE_PRIVILEGE_NAME_ID 3139 +#define F_HAS_TYPE_PRIVILEGE_ID_NAME 3140 +#define F_HAS_TYPE_PRIVILEGE_ID_ID 3141 +#define F_HAS_TYPE_PRIVILEGE_NAME 3142 +#define F_HAS_TYPE_PRIVILEGE_ID 3143 +#define F_MACADDR_NOT 3144 +#define F_MACADDR_AND 3145 +#define F_MACADDR_OR 3146 +#define F_PG_STAT_GET_DB_TEMP_FILES 3150 +#define F_PG_STAT_GET_DB_TEMP_BYTES 3151 +#define F_PG_STAT_GET_DB_DEADLOCKS 3152 +#define F_ARRAY_TO_JSON 3153 +#define F_ARRAY_TO_JSON_PRETTY 3154 +#define F_ROW_TO_JSON 3155 +#define F_ROW_TO_JSON_PRETTY 3156 +#define F_NUMERIC_TRANSFORM 3157 +#define F_VARBIT_TRANSFORM 3158 +#define F_PG_GET_VIEWDEF_WRAP 3159 +#define F_PG_STAT_GET_CHECKPOINT_WRITE_TIME 3160 +#define F_PG_STAT_GET_CHECKPOINT_SYNC_TIME 3161 +#define F_PG_COLLATION_FOR 3162 +#define F_PG_TRIGGER_DEPTH 3163 +#define F_PG_XLOG_LOCATION_DIFF 3165 +#define F_PG_SIZE_PRETTY_NUMERIC 3166 +#define F_ANYENUM_IN 3504 +#define F_ANYENUM_OUT 3505 +#define F_ENUM_IN 3506 +#define F_ENUM_OUT 3507 +#define F_ENUM_EQ 3508 +#define F_ENUM_NE 3509 +#define F_ENUM_LT 3510 +#define F_ENUM_GT 3511 +#define F_ENUM_LE 3512 +#define F_ENUM_GE 3513 +#define F_ENUM_CMP 3514 +#define F_HASHENUM 3515 +#define F_ENUM_SMALLER 3524 +#define F_ENUM_LARGER 3525 +#define F_ENUM_FIRST 3528 +#define F_ENUM_LAST 3529 +#define F_ENUM_RANGE_BOUNDS 3530 +#define F_ENUM_RANGE_ALL 3531 +#define F_ENUM_RECV 3532 +#define F_ENUM_SEND 3533 +#define F_STRING_AGG_TRANSFN 3535 +#define F_STRING_AGG_FINALFN 3536 +#define F_PG_DESCRIBE_OBJECT 3537 +#define F_TEXT_FORMAT 3539 +#define F_TEXT_FORMAT_NV 3540 +#define F_BYTEA_STRING_AGG_TRANSFN 3543 +#define F_BYTEA_STRING_AGG_FINALFN 3544 +#define F_TSVECTORIN 3610 +#define F_TSVECTOROUT 3611 +#define F_TSQUERYIN 3612 +#define F_TSQUERYOUT 3613 +#define F_TSVECTOR_LT 3616 +#define F_TSVECTOR_LE 3617 +#define F_TSVECTOR_EQ 3618 +#define F_TSVECTOR_NE 3619 +#define F_TSVECTOR_GE 3620 +#define F_TSVECTOR_GT 3621 +#define F_TSVECTOR_CMP 3622 +#define F_TSVECTOR_STRIP 3623 +#define F_TSVECTOR_SETWEIGHT 3624 +#define F_TSVECTOR_CONCAT 3625 +#define F_TS_MATCH_VQ 3634 +#define F_TS_MATCH_QV 3635 +#define F_TSVECTORSEND 3638 +#define F_TSVECTORRECV 3639 +#define F_TSQUERYSEND 3640 +#define F_TSQUERYRECV 3641 +#define F_GTSVECTORIN 3646 +#define F_GTSVECTOROUT 3647 +#define F_GTSVECTOR_COMPRESS 3648 +#define F_GTSVECTOR_DECOMPRESS 3649 +#define F_GTSVECTOR_PICKSPLIT 3650 +#define F_GTSVECTOR_UNION 3651 +#define F_GTSVECTOR_SAME 3652 +#define F_GTSVECTOR_PENALTY 3653 +#define F_GTSVECTOR_CONSISTENT 3654 +#define F_GIN_EXTRACT_TSVECTOR 3656 +#define F_GIN_EXTRACT_TSQUERY 3657 +#define F_GIN_TSQUERY_CONSISTENT 3658 +#define F_TSQUERY_LT 3662 +#define F_TSQUERY_LE 3663 +#define F_TSQUERY_EQ 3664 +#define F_TSQUERY_NE 3665 +#define F_TSQUERY_GE 3666 +#define F_TSQUERY_GT 3667 +#define F_TSQUERY_CMP 3668 +#define F_TSQUERY_AND 3669 +#define F_TSQUERY_OR 3670 +#define F_TSQUERY_NOT 3671 +#define F_TSQUERY_NUMNODE 3672 +#define F_TSQUERYTREE 3673 +#define F_TSQUERY_REWRITE 3684 +#define F_TSQUERY_REWRITE_QUERY 3685 +#define F_TSMATCHSEL 3686 +#define F_TSMATCHJOINSEL 3687 +#define F_TS_TYPANALYZE 3688 +#define F_TS_STAT1 3689 +#define F_TS_STAT2 3690 +#define F_TSQ_MCONTAINS 3691 +#define F_TSQ_MCONTAINED 3692 +#define F_GTSQUERY_COMPRESS 3695 +#define F_GTSQUERY_DECOMPRESS 3696 +#define F_GTSQUERY_PICKSPLIT 3697 +#define F_GTSQUERY_UNION 3698 +#define F_GTSQUERY_SAME 3699 +#define F_GTSQUERY_PENALTY 3700 +#define F_GTSQUERY_CONSISTENT 3701 +#define F_TS_RANK_WTTF 3703 +#define F_TS_RANK_WTT 3704 +#define F_TS_RANK_TTF 3705 +#define F_TS_RANK_TT 3706 +#define F_TS_RANKCD_WTTF 3707 +#define F_TS_RANKCD_WTT 3708 +#define F_TS_RANKCD_TTF 3709 +#define F_TS_RANKCD_TT 3710 +#define F_TSVECTOR_LENGTH 3711 +#define F_TS_TOKEN_TYPE_BYID 3713 +#define F_TS_TOKEN_TYPE_BYNAME 3714 +#define F_TS_PARSE_BYID 3715 +#define F_TS_PARSE_BYNAME 3716 +#define F_PRSD_START 3717 +#define F_PRSD_NEXTTOKEN 3718 +#define F_PRSD_END 3719 +#define F_PRSD_HEADLINE 3720 +#define F_PRSD_LEXTYPE 3721 +#define F_TS_LEXIZE 3723 +#define F_GIN_CMP_TSLEXEME 3724 +#define F_DSIMPLE_INIT 3725 +#define F_DSIMPLE_LEXIZE 3726 +#define F_DSYNONYM_INIT 3728 +#define F_DSYNONYM_LEXIZE 3729 +#define F_DISPELL_INIT 3731 +#define F_DISPELL_LEXIZE 3732 +#define F_REGCONFIGIN 3736 +#define F_REGCONFIGOUT 3737 +#define F_REGCONFIGRECV 3738 +#define F_REGCONFIGSEND 3739 +#define F_THESAURUS_INIT 3740 +#define F_THESAURUS_LEXIZE 3741 +#define F_TS_HEADLINE_BYID_OPT 3743 +#define F_TS_HEADLINE_BYID 3744 +#define F_TO_TSVECTOR_BYID 3745 +#define F_TO_TSQUERY_BYID 3746 +#define F_PLAINTO_TSQUERY_BYID 3747 +#define F_TO_TSVECTOR 3749 +#define F_TO_TSQUERY 3750 +#define F_PLAINTO_TSQUERY 3751 +#define F_TSVECTOR_UPDATE_TRIGGER_BYID 3752 +#define F_TSVECTOR_UPDATE_TRIGGER_BYCOLUMN 3753 +#define F_TS_HEADLINE_OPT 3754 +#define F_TS_HEADLINE 3755 +#define F_PG_TS_PARSER_IS_VISIBLE 3756 +#define F_PG_TS_DICT_IS_VISIBLE 3757 +#define F_PG_TS_CONFIG_IS_VISIBLE 3758 +#define F_GET_CURRENT_TS_CONFIG 3759 +#define F_TS_MATCH_TT 3760 +#define F_TS_MATCH_TQ 3761 +#define F_PG_TS_TEMPLATE_IS_VISIBLE 3768 +#define F_REGDICTIONARYIN 3771 +#define F_REGDICTIONARYOUT 3772 +#define F_REGDICTIONARYRECV 3773 +#define F_REGDICTIONARYSEND 3774 +#define F_PG_STAT_RESET_SHARED 3775 +#define F_PG_STAT_RESET_SINGLE_TABLE_COUNTERS 3776 +#define F_PG_STAT_RESET_SINGLE_FUNCTION_COUNTERS 3777 +#define F_PG_TABLESPACE_LOCATION 3778 +#define F_PG_EXPORT_SNAPSHOT 3809 +#define F_PG_IS_IN_RECOVERY 3810 +#define F_INT4_CASH 3811 +#define F_INT8_CASH 3812 +#define F_PG_COLLATION_IS_VISIBLE 3815 +#define F_ARRAY_TYPANALYZE 3816 +#define F_ARRAYCONTSEL 3817 +#define F_ARRAYCONTJOINSEL 3818 +#define F_PG_LAST_XLOG_RECEIVE_LOCATION 3820 +#define F_PG_LAST_XLOG_REPLAY_LOCATION 3821 +#define F_CASH_DIV_CASH 3822 +#define F_CASH_NUMERIC 3823 +#define F_NUMERIC_CASH 3824 +#define F_PG_READ_FILE_ALL 3826 +#define F_PG_READ_BINARY_FILE 3827 +#define F_PG_READ_BINARY_FILE_ALL 3828 +#define F_PG_OPFAMILY_IS_VISIBLE 3829 +#define F_PG_LAST_XACT_REPLAY_TIMESTAMP 3830 +#define F_ANYRANGE_IN 3832 +#define F_ANYRANGE_OUT 3833 +#define F_RANGE_IN 3834 +#define F_RANGE_OUT 3835 +#define F_RANGE_RECV 3836 +#define F_RANGE_SEND 3837 +#define F_RANGE_CONSTRUCTOR2 3840 +#define F_RANGE_CONSTRUCTOR3 3841 +#define F_RANGE_LOWER 3848 +#define F_RANGE_UPPER 3849 +#define F_RANGE_EMPTY 3850 +#define F_RANGE_LOWER_INC 3851 +#define F_RANGE_UPPER_INC 3852 +#define F_RANGE_LOWER_INF 3853 +#define F_RANGE_UPPER_INF 3854 +#define F_RANGE_EQ 3855 +#define F_RANGE_NE 3856 +#define F_RANGE_OVERLAPS 3857 +#define F_RANGE_CONTAINS_ELEM 3858 +#define F_RANGE_CONTAINS 3859 +#define F_ELEM_CONTAINED_BY_RANGE 3860 +#define F_RANGE_CONTAINED_BY 3861 +#define F_RANGE_ADJACENT 3862 +#define F_RANGE_BEFORE 3863 +#define F_RANGE_AFTER 3864 +#define F_RANGE_OVERLEFT 3865 +#define F_RANGE_OVERRIGHT 3866 +#define F_RANGE_UNION 3867 +#define F_RANGE_INTERSECT 3868 +#define F_RANGE_MINUS 3869 +#define F_RANGE_CMP 3870 +#define F_RANGE_LT 3871 +#define F_RANGE_LE 3872 +#define F_RANGE_GE 3873 +#define F_RANGE_GT 3874 +#define F_RANGE_GIST_CONSISTENT 3875 +#define F_RANGE_GIST_UNION 3876 +#define F_RANGE_GIST_COMPRESS 3877 +#define F_RANGE_GIST_DECOMPRESS 3878 +#define F_RANGE_GIST_PENALTY 3879 +#define F_RANGE_GIST_PICKSPLIT 3880 +#define F_RANGE_GIST_SAME 3881 +#define F_HASH_RANGE 3902 +#define F_INT4RANGE_CANONICAL 3914 +#define F_DATERANGE_CANONICAL 3915 +#define F_RANGE_TYPANALYZE 3916 +#define F_TIMESTAMP_TRANSFORM 3917 +#define F_INTERVAL_TRANSFORM 3918 +#define F_INT4RANGE_SUBDIFF 3922 +#define F_INT8RANGE_SUBDIFF 3923 +#define F_NUMRANGE_SUBDIFF 3924 +#define F_DATERANGE_SUBDIFF 3925 +#define F_INT8RANGE_CANONICAL 3928 +#define F_TSRANGE_SUBDIFF 3929 +#define F_TSTZRANGE_SUBDIFF 3930 +#define F_ACLDEFAULT_SQL 3943 +#define F_TIME_TRANSFORM 3944 +#define F_SPGGETTUPLE 4001 +#define F_SPGGETBITMAP 4002 +#define F_SPGINSERT 4003 +#define F_SPGBEGINSCAN 4004 +#define F_SPGRESCAN 4005 +#define F_SPGENDSCAN 4006 +#define F_SPGMARKPOS 4007 +#define F_SPGRESTRPOS 4008 +#define F_SPGBUILD 4009 +#define F_SPGBUILDEMPTY 4010 +#define F_SPGBULKDELETE 4011 +#define F_SPGVACUUMCLEANUP 4012 +#define F_SPGCOSTESTIMATE 4013 +#define F_SPGOPTIONS 4014 +#define F_SPG_QUAD_CONFIG 4018 +#define F_SPG_QUAD_CHOOSE 4019 +#define F_SPG_QUAD_PICKSPLIT 4020 +#define F_SPG_QUAD_INNER_CONSISTENT 4021 +#define F_SPG_QUAD_LEAF_CONSISTENT 4022 +#define F_SPG_KD_CONFIG 4023 +#define F_SPG_KD_CHOOSE 4024 +#define F_SPG_KD_PICKSPLIT 4025 +#define F_SPG_KD_INNER_CONSISTENT 4026 +#define F_SPG_TEXT_CONFIG 4027 +#define F_SPG_TEXT_CHOOSE 4028 +#define F_SPG_TEXT_PICKSPLIT 4029 +#define F_SPG_TEXT_INNER_CONSISTENT 4030 +#define F_SPG_TEXT_LEAF_CONSISTENT 4031 +#define F_SPGCANRETURN 4032 + +#endif /* FMGROIDS_H */ diff --git a/src/backend/utils/fmgrtab.c b/src/backend/utils/fmgrtab.c new file mode 100644 index 000000000..e0233fc78 --- /dev/null +++ b/src/backend/utils/fmgrtab.c @@ -0,0 +1,4470 @@ +/*------------------------------------------------------------------------- + * + * fmgrtab.c + * The function manager's table of internal functions. + * + * Portions Copyright (c) 1996-2012, PostgreSQL Global Development Group + * Portions Copyright (c) 1994, Regents of the University of California + * + * NOTES + * + * ****************************** + * *** DO NOT EDIT THIS FILE! *** + * ****************************** + * + * It has been GENERATED by Gen_fmgrtab.pl + * from ../../../src/include/catalog/pg_proc.h + * + *------------------------------------------------------------------------- + */ + +#include "postgres.h" + +#include "utils/fmgrtab.h" + +extern Datum byteaout (PG_FUNCTION_ARGS); +extern Datum charout (PG_FUNCTION_ARGS); +extern Datum namein (PG_FUNCTION_ARGS); +extern Datum nameout (PG_FUNCTION_ARGS); +extern Datum int2in (PG_FUNCTION_ARGS); +extern Datum int2out (PG_FUNCTION_ARGS); +extern Datum int2vectorin (PG_FUNCTION_ARGS); +extern Datum int2vectorout (PG_FUNCTION_ARGS); +extern Datum int4in (PG_FUNCTION_ARGS); +extern Datum int4out (PG_FUNCTION_ARGS); +extern Datum regprocin (PG_FUNCTION_ARGS); +extern Datum regprocout (PG_FUNCTION_ARGS); +extern Datum textin (PG_FUNCTION_ARGS); +extern Datum textout (PG_FUNCTION_ARGS); +extern Datum tidin (PG_FUNCTION_ARGS); +extern Datum tidout (PG_FUNCTION_ARGS); +extern Datum xidin (PG_FUNCTION_ARGS); +extern Datum xidout (PG_FUNCTION_ARGS); +extern Datum cidin (PG_FUNCTION_ARGS); +extern Datum cidout (PG_FUNCTION_ARGS); +extern Datum oidvectorin (PG_FUNCTION_ARGS); +extern Datum oidvectorout (PG_FUNCTION_ARGS); +extern Datum boollt (PG_FUNCTION_ARGS); +extern Datum boolgt (PG_FUNCTION_ARGS); +extern Datum booleq (PG_FUNCTION_ARGS); +extern Datum chareq (PG_FUNCTION_ARGS); +extern Datum nameeq (PG_FUNCTION_ARGS); +extern Datum int2eq (PG_FUNCTION_ARGS); +extern Datum int2lt (PG_FUNCTION_ARGS); +extern Datum int4eq (PG_FUNCTION_ARGS); +extern Datum int4lt (PG_FUNCTION_ARGS); +extern Datum texteq (PG_FUNCTION_ARGS); +extern Datum xideq (PG_FUNCTION_ARGS); +extern Datum cideq (PG_FUNCTION_ARGS); +extern Datum charne (PG_FUNCTION_ARGS); +extern Datum charle (PG_FUNCTION_ARGS); +extern Datum chargt (PG_FUNCTION_ARGS); +extern Datum charge (PG_FUNCTION_ARGS); +extern Datum chartoi4 (PG_FUNCTION_ARGS); +extern Datum i4tochar (PG_FUNCTION_ARGS); +extern Datum nameregexeq (PG_FUNCTION_ARGS); +extern Datum boolne (PG_FUNCTION_ARGS); +extern Datum pgsql_version (PG_FUNCTION_ARGS); +extern Datum eqsel (PG_FUNCTION_ARGS); +extern Datum neqsel (PG_FUNCTION_ARGS); +extern Datum scalarltsel (PG_FUNCTION_ARGS); +extern Datum scalargtsel (PG_FUNCTION_ARGS); +extern Datum eqjoinsel (PG_FUNCTION_ARGS); +extern Datum neqjoinsel (PG_FUNCTION_ARGS); +extern Datum scalarltjoinsel (PG_FUNCTION_ARGS); +extern Datum scalargtjoinsel (PG_FUNCTION_ARGS); +extern Datum unknownin (PG_FUNCTION_ARGS); +extern Datum unknownout (PG_FUNCTION_ARGS); +extern Datum numeric_fac (PG_FUNCTION_ARGS); +extern Datum box_above_eq (PG_FUNCTION_ARGS); +extern Datum box_below_eq (PG_FUNCTION_ARGS); +extern Datum point_in (PG_FUNCTION_ARGS); +extern Datum point_out (PG_FUNCTION_ARGS); +extern Datum lseg_in (PG_FUNCTION_ARGS); +extern Datum lseg_out (PG_FUNCTION_ARGS); +extern Datum path_in (PG_FUNCTION_ARGS); +extern Datum path_out (PG_FUNCTION_ARGS); +extern Datum box_in (PG_FUNCTION_ARGS); +extern Datum box_out (PG_FUNCTION_ARGS); +extern Datum box_overlap (PG_FUNCTION_ARGS); +extern Datum box_ge (PG_FUNCTION_ARGS); +extern Datum box_gt (PG_FUNCTION_ARGS); +extern Datum box_eq (PG_FUNCTION_ARGS); +extern Datum box_lt (PG_FUNCTION_ARGS); +extern Datum box_le (PG_FUNCTION_ARGS); +extern Datum point_above (PG_FUNCTION_ARGS); +extern Datum point_left (PG_FUNCTION_ARGS); +extern Datum point_right (PG_FUNCTION_ARGS); +extern Datum point_below (PG_FUNCTION_ARGS); +extern Datum point_eq (PG_FUNCTION_ARGS); +extern Datum on_pb (PG_FUNCTION_ARGS); +extern Datum on_ppath (PG_FUNCTION_ARGS); +extern Datum box_center (PG_FUNCTION_ARGS); +extern Datum areasel (PG_FUNCTION_ARGS); +extern Datum areajoinsel (PG_FUNCTION_ARGS); +extern Datum int4mul (PG_FUNCTION_ARGS); +extern Datum int4ne (PG_FUNCTION_ARGS); +extern Datum int2ne (PG_FUNCTION_ARGS); +extern Datum int2gt (PG_FUNCTION_ARGS); +extern Datum int4gt (PG_FUNCTION_ARGS); +extern Datum int2le (PG_FUNCTION_ARGS); +extern Datum int4le (PG_FUNCTION_ARGS); +extern Datum int4ge (PG_FUNCTION_ARGS); +extern Datum int2ge (PG_FUNCTION_ARGS); +extern Datum int2mul (PG_FUNCTION_ARGS); +extern Datum int2div (PG_FUNCTION_ARGS); +extern Datum int4div (PG_FUNCTION_ARGS); +extern Datum int2mod (PG_FUNCTION_ARGS); +extern Datum int4mod (PG_FUNCTION_ARGS); +extern Datum textne (PG_FUNCTION_ARGS); +extern Datum int24eq (PG_FUNCTION_ARGS); +extern Datum int42eq (PG_FUNCTION_ARGS); +extern Datum int24lt (PG_FUNCTION_ARGS); +extern Datum int42lt (PG_FUNCTION_ARGS); +extern Datum int24gt (PG_FUNCTION_ARGS); +extern Datum int42gt (PG_FUNCTION_ARGS); +extern Datum int24ne (PG_FUNCTION_ARGS); +extern Datum int42ne (PG_FUNCTION_ARGS); +extern Datum int24le (PG_FUNCTION_ARGS); +extern Datum int42le (PG_FUNCTION_ARGS); +extern Datum int24ge (PG_FUNCTION_ARGS); +extern Datum int42ge (PG_FUNCTION_ARGS); +extern Datum int24mul (PG_FUNCTION_ARGS); +extern Datum int42mul (PG_FUNCTION_ARGS); +extern Datum int24div (PG_FUNCTION_ARGS); +extern Datum int42div (PG_FUNCTION_ARGS); +extern Datum int2pl (PG_FUNCTION_ARGS); +extern Datum int4pl (PG_FUNCTION_ARGS); +extern Datum int24pl (PG_FUNCTION_ARGS); +extern Datum int42pl (PG_FUNCTION_ARGS); +extern Datum int2mi (PG_FUNCTION_ARGS); +extern Datum int4mi (PG_FUNCTION_ARGS); +extern Datum int24mi (PG_FUNCTION_ARGS); +extern Datum int42mi (PG_FUNCTION_ARGS); +extern Datum oideq (PG_FUNCTION_ARGS); +extern Datum oidne (PG_FUNCTION_ARGS); +extern Datum box_same (PG_FUNCTION_ARGS); +extern Datum box_contain (PG_FUNCTION_ARGS); +extern Datum box_left (PG_FUNCTION_ARGS); +extern Datum box_overleft (PG_FUNCTION_ARGS); +extern Datum box_overright (PG_FUNCTION_ARGS); +extern Datum box_right (PG_FUNCTION_ARGS); +extern Datum box_contained (PG_FUNCTION_ARGS); +extern Datum box_contain_pt (PG_FUNCTION_ARGS); +extern Datum pg_node_tree_in (PG_FUNCTION_ARGS); +extern Datum pg_node_tree_out (PG_FUNCTION_ARGS); +extern Datum pg_node_tree_recv (PG_FUNCTION_ARGS); +extern Datum pg_node_tree_send (PG_FUNCTION_ARGS); +extern Datum float4in (PG_FUNCTION_ARGS); +extern Datum float4out (PG_FUNCTION_ARGS); +extern Datum float4mul (PG_FUNCTION_ARGS); +extern Datum float4div (PG_FUNCTION_ARGS); +extern Datum float4pl (PG_FUNCTION_ARGS); +extern Datum float4mi (PG_FUNCTION_ARGS); +extern Datum float4um (PG_FUNCTION_ARGS); +extern Datum float4abs (PG_FUNCTION_ARGS); +extern Datum float4_accum (PG_FUNCTION_ARGS); +extern Datum float4larger (PG_FUNCTION_ARGS); +extern Datum float4smaller (PG_FUNCTION_ARGS); +extern Datum int4um (PG_FUNCTION_ARGS); +extern Datum int2um (PG_FUNCTION_ARGS); +extern Datum float8in (PG_FUNCTION_ARGS); +extern Datum float8out (PG_FUNCTION_ARGS); +extern Datum float8mul (PG_FUNCTION_ARGS); +extern Datum float8div (PG_FUNCTION_ARGS); +extern Datum float8pl (PG_FUNCTION_ARGS); +extern Datum float8mi (PG_FUNCTION_ARGS); +extern Datum float8um (PG_FUNCTION_ARGS); +extern Datum float8abs (PG_FUNCTION_ARGS); +extern Datum float8_accum (PG_FUNCTION_ARGS); +extern Datum float8larger (PG_FUNCTION_ARGS); +extern Datum float8smaller (PG_FUNCTION_ARGS); +extern Datum lseg_center (PG_FUNCTION_ARGS); +extern Datum path_center (PG_FUNCTION_ARGS); +extern Datum poly_center (PG_FUNCTION_ARGS); +extern Datum dround (PG_FUNCTION_ARGS); +extern Datum dtrunc (PG_FUNCTION_ARGS); +extern Datum dsqrt (PG_FUNCTION_ARGS); +extern Datum dcbrt (PG_FUNCTION_ARGS); +extern Datum dpow (PG_FUNCTION_ARGS); +extern Datum dexp (PG_FUNCTION_ARGS); +extern Datum dlog1 (PG_FUNCTION_ARGS); +extern Datum i2tod (PG_FUNCTION_ARGS); +extern Datum i2tof (PG_FUNCTION_ARGS); +extern Datum dtoi2 (PG_FUNCTION_ARGS); +extern Datum ftoi2 (PG_FUNCTION_ARGS); +extern Datum line_distance (PG_FUNCTION_ARGS); +extern Datum abstimein (PG_FUNCTION_ARGS); +extern Datum abstimeout (PG_FUNCTION_ARGS); +extern Datum reltimein (PG_FUNCTION_ARGS); +extern Datum reltimeout (PG_FUNCTION_ARGS); +extern Datum timepl (PG_FUNCTION_ARGS); +extern Datum timemi (PG_FUNCTION_ARGS); +extern Datum tintervalin (PG_FUNCTION_ARGS); +extern Datum tintervalout (PG_FUNCTION_ARGS); +extern Datum intinterval (PG_FUNCTION_ARGS); +extern Datum tintervalrel (PG_FUNCTION_ARGS); +extern Datum timenow (PG_FUNCTION_ARGS); +extern Datum abstimeeq (PG_FUNCTION_ARGS); +extern Datum abstimene (PG_FUNCTION_ARGS); +extern Datum abstimelt (PG_FUNCTION_ARGS); +extern Datum abstimegt (PG_FUNCTION_ARGS); +extern Datum abstimele (PG_FUNCTION_ARGS); +extern Datum abstimege (PG_FUNCTION_ARGS); +extern Datum reltimeeq (PG_FUNCTION_ARGS); +extern Datum reltimene (PG_FUNCTION_ARGS); +extern Datum reltimelt (PG_FUNCTION_ARGS); +extern Datum reltimegt (PG_FUNCTION_ARGS); +extern Datum reltimele (PG_FUNCTION_ARGS); +extern Datum reltimege (PG_FUNCTION_ARGS); +extern Datum tintervalsame (PG_FUNCTION_ARGS); +extern Datum tintervalct (PG_FUNCTION_ARGS); +extern Datum tintervalov (PG_FUNCTION_ARGS); +extern Datum tintervalleneq (PG_FUNCTION_ARGS); +extern Datum tintervallenne (PG_FUNCTION_ARGS); +extern Datum tintervallenlt (PG_FUNCTION_ARGS); +extern Datum tintervallengt (PG_FUNCTION_ARGS); +extern Datum tintervallenle (PG_FUNCTION_ARGS); +extern Datum tintervallenge (PG_FUNCTION_ARGS); +extern Datum tintervalstart (PG_FUNCTION_ARGS); +extern Datum tintervalend (PG_FUNCTION_ARGS); +extern Datum timeofday (PG_FUNCTION_ARGS); +extern Datum abstime_finite (PG_FUNCTION_ARGS); +extern Datum btcanreturn (PG_FUNCTION_ARGS); +extern Datum inter_sl (PG_FUNCTION_ARGS); +extern Datum inter_lb (PG_FUNCTION_ARGS); +extern Datum float48mul (PG_FUNCTION_ARGS); +extern Datum float48div (PG_FUNCTION_ARGS); +extern Datum float48pl (PG_FUNCTION_ARGS); +extern Datum float48mi (PG_FUNCTION_ARGS); +extern Datum float84mul (PG_FUNCTION_ARGS); +extern Datum float84div (PG_FUNCTION_ARGS); +extern Datum float84pl (PG_FUNCTION_ARGS); +extern Datum float84mi (PG_FUNCTION_ARGS); +extern Datum float4eq (PG_FUNCTION_ARGS); +extern Datum float4ne (PG_FUNCTION_ARGS); +extern Datum float4lt (PG_FUNCTION_ARGS); +extern Datum float4le (PG_FUNCTION_ARGS); +extern Datum float4gt (PG_FUNCTION_ARGS); +extern Datum float4ge (PG_FUNCTION_ARGS); +extern Datum float8eq (PG_FUNCTION_ARGS); +extern Datum float8ne (PG_FUNCTION_ARGS); +extern Datum float8lt (PG_FUNCTION_ARGS); +extern Datum float8le (PG_FUNCTION_ARGS); +extern Datum float8gt (PG_FUNCTION_ARGS); +extern Datum float8ge (PG_FUNCTION_ARGS); +extern Datum float48eq (PG_FUNCTION_ARGS); +extern Datum float48ne (PG_FUNCTION_ARGS); +extern Datum float48lt (PG_FUNCTION_ARGS); +extern Datum float48le (PG_FUNCTION_ARGS); +extern Datum float48gt (PG_FUNCTION_ARGS); +extern Datum float48ge (PG_FUNCTION_ARGS); +extern Datum float84eq (PG_FUNCTION_ARGS); +extern Datum float84ne (PG_FUNCTION_ARGS); +extern Datum float84lt (PG_FUNCTION_ARGS); +extern Datum float84le (PG_FUNCTION_ARGS); +extern Datum float84gt (PG_FUNCTION_ARGS); +extern Datum float84ge (PG_FUNCTION_ARGS); +extern Datum ftod (PG_FUNCTION_ARGS); +extern Datum dtof (PG_FUNCTION_ARGS); +extern Datum i2toi4 (PG_FUNCTION_ARGS); +extern Datum i4toi2 (PG_FUNCTION_ARGS); +extern Datum int2vectoreq (PG_FUNCTION_ARGS); +extern Datum i4tod (PG_FUNCTION_ARGS); +extern Datum dtoi4 (PG_FUNCTION_ARGS); +extern Datum i4tof (PG_FUNCTION_ARGS); +extern Datum ftoi4 (PG_FUNCTION_ARGS); +extern Datum width_bucket_float8 (PG_FUNCTION_ARGS); +extern Datum json_in (PG_FUNCTION_ARGS); +extern Datum json_out (PG_FUNCTION_ARGS); +extern Datum json_recv (PG_FUNCTION_ARGS); +extern Datum json_send (PG_FUNCTION_ARGS); +extern Datum ginbuildempty (PG_FUNCTION_ARGS); +extern Datum gistbuildempty (PG_FUNCTION_ARGS); +extern Datum hashbuildempty (PG_FUNCTION_ARGS); +extern Datum btbuildempty (PG_FUNCTION_ARGS); +extern Datum hash_aclitem (PG_FUNCTION_ARGS); +extern Datum btgettuple (PG_FUNCTION_ARGS); +extern Datum btinsert (PG_FUNCTION_ARGS); +extern Datum btbulkdelete (PG_FUNCTION_ARGS); +extern Datum btbeginscan (PG_FUNCTION_ARGS); +extern Datum btrescan (PG_FUNCTION_ARGS); +extern Datum btendscan (PG_FUNCTION_ARGS); +extern Datum btmarkpos (PG_FUNCTION_ARGS); +extern Datum btrestrpos (PG_FUNCTION_ARGS); +extern Datum btbuild (PG_FUNCTION_ARGS); +extern Datum poly_same (PG_FUNCTION_ARGS); +extern Datum poly_contain (PG_FUNCTION_ARGS); +extern Datum poly_left (PG_FUNCTION_ARGS); +extern Datum poly_overleft (PG_FUNCTION_ARGS); +extern Datum poly_overright (PG_FUNCTION_ARGS); +extern Datum poly_right (PG_FUNCTION_ARGS); +extern Datum poly_contained (PG_FUNCTION_ARGS); +extern Datum poly_overlap (PG_FUNCTION_ARGS); +extern Datum poly_in (PG_FUNCTION_ARGS); +extern Datum poly_out (PG_FUNCTION_ARGS); +extern Datum btint2cmp (PG_FUNCTION_ARGS); +extern Datum btint4cmp (PG_FUNCTION_ARGS); +extern Datum btfloat4cmp (PG_FUNCTION_ARGS); +extern Datum btfloat8cmp (PG_FUNCTION_ARGS); +extern Datum btoidcmp (PG_FUNCTION_ARGS); +extern Datum btabstimecmp (PG_FUNCTION_ARGS); +extern Datum btcharcmp (PG_FUNCTION_ARGS); +extern Datum btnamecmp (PG_FUNCTION_ARGS); +extern Datum bttextcmp (PG_FUNCTION_ARGS); +extern Datum lseg_distance (PG_FUNCTION_ARGS); +extern Datum lseg_interpt (PG_FUNCTION_ARGS); +extern Datum dist_ps (PG_FUNCTION_ARGS); +extern Datum dist_pb (PG_FUNCTION_ARGS); +extern Datum dist_sb (PG_FUNCTION_ARGS); +extern Datum close_ps (PG_FUNCTION_ARGS); +extern Datum close_pb (PG_FUNCTION_ARGS); +extern Datum close_sb (PG_FUNCTION_ARGS); +extern Datum on_ps (PG_FUNCTION_ARGS); +extern Datum path_distance (PG_FUNCTION_ARGS); +extern Datum dist_ppath (PG_FUNCTION_ARGS); +extern Datum on_sb (PG_FUNCTION_ARGS); +extern Datum inter_sb (PG_FUNCTION_ARGS); +extern Datum text_to_array_null (PG_FUNCTION_ARGS); +extern Datum cash_cmp (PG_FUNCTION_ARGS); +extern Datum array_push (PG_FUNCTION_ARGS); +extern Datum btreltimecmp (PG_FUNCTION_ARGS); +extern Datum bttintervalcmp (PG_FUNCTION_ARGS); +extern Datum btarraycmp (PG_FUNCTION_ARGS); +extern Datum array_cat (PG_FUNCTION_ARGS); +extern Datum array_to_text_null (PG_FUNCTION_ARGS); +extern Datum array_ne (PG_FUNCTION_ARGS); +extern Datum array_lt (PG_FUNCTION_ARGS); +extern Datum array_gt (PG_FUNCTION_ARGS); +extern Datum array_le (PG_FUNCTION_ARGS); +extern Datum text_to_array (PG_FUNCTION_ARGS); +extern Datum array_to_text (PG_FUNCTION_ARGS); +extern Datum array_ge (PG_FUNCTION_ARGS); +extern Datum hashint2vector (PG_FUNCTION_ARGS); +extern Datum hashmacaddr (PG_FUNCTION_ARGS); +extern Datum hashtext (PG_FUNCTION_ARGS); +extern Datum rtrim1 (PG_FUNCTION_ARGS); +extern Datum btoidvectorcmp (PG_FUNCTION_ARGS); +extern Datum name_text (PG_FUNCTION_ARGS); +extern Datum text_name (PG_FUNCTION_ARGS); +extern Datum name_bpchar (PG_FUNCTION_ARGS); +extern Datum bpchar_name (PG_FUNCTION_ARGS); +extern Datum hashinet (PG_FUNCTION_ARGS); +extern Datum hashvacuumcleanup (PG_FUNCTION_ARGS); +extern Datum hash_numeric (PG_FUNCTION_ARGS); +extern Datum macaddr_in (PG_FUNCTION_ARGS); +extern Datum macaddr_out (PG_FUNCTION_ARGS); +extern Datum hashcostestimate (PG_FUNCTION_ARGS); +extern Datum hashgettuple (PG_FUNCTION_ARGS); +extern Datum hashinsert (PG_FUNCTION_ARGS); +extern Datum hashbulkdelete (PG_FUNCTION_ARGS); +extern Datum hashbeginscan (PG_FUNCTION_ARGS); +extern Datum hashrescan (PG_FUNCTION_ARGS); +extern Datum hashendscan (PG_FUNCTION_ARGS); +extern Datum hashmarkpos (PG_FUNCTION_ARGS); +extern Datum hashrestrpos (PG_FUNCTION_ARGS); +extern Datum hashbuild (PG_FUNCTION_ARGS); +extern Datum hashint2 (PG_FUNCTION_ARGS); +extern Datum hashint4 (PG_FUNCTION_ARGS); +extern Datum hashfloat4 (PG_FUNCTION_ARGS); +extern Datum hashfloat8 (PG_FUNCTION_ARGS); +extern Datum hashoid (PG_FUNCTION_ARGS); +extern Datum hashchar (PG_FUNCTION_ARGS); +extern Datum hashname (PG_FUNCTION_ARGS); +extern Datum hashvarlena (PG_FUNCTION_ARGS); +extern Datum hashoidvector (PG_FUNCTION_ARGS); +extern Datum text_larger (PG_FUNCTION_ARGS); +extern Datum text_smaller (PG_FUNCTION_ARGS); +extern Datum int8in (PG_FUNCTION_ARGS); +extern Datum int8out (PG_FUNCTION_ARGS); +extern Datum int8um (PG_FUNCTION_ARGS); +extern Datum int8pl (PG_FUNCTION_ARGS); +extern Datum int8mi (PG_FUNCTION_ARGS); +extern Datum int8mul (PG_FUNCTION_ARGS); +extern Datum int8div (PG_FUNCTION_ARGS); +extern Datum int8eq (PG_FUNCTION_ARGS); +extern Datum int8ne (PG_FUNCTION_ARGS); +extern Datum int8lt (PG_FUNCTION_ARGS); +extern Datum int8gt (PG_FUNCTION_ARGS); +extern Datum int8le (PG_FUNCTION_ARGS); +extern Datum int8ge (PG_FUNCTION_ARGS); +extern Datum int84eq (PG_FUNCTION_ARGS); +extern Datum int84ne (PG_FUNCTION_ARGS); +extern Datum int84lt (PG_FUNCTION_ARGS); +extern Datum int84gt (PG_FUNCTION_ARGS); +extern Datum int84le (PG_FUNCTION_ARGS); +extern Datum int84ge (PG_FUNCTION_ARGS); +extern Datum int84 (PG_FUNCTION_ARGS); +extern Datum int48 (PG_FUNCTION_ARGS); +extern Datum i8tod (PG_FUNCTION_ARGS); +extern Datum dtoi8 (PG_FUNCTION_ARGS); +extern Datum array_larger (PG_FUNCTION_ARGS); +extern Datum array_smaller (PG_FUNCTION_ARGS); +extern Datum inet_abbrev (PG_FUNCTION_ARGS); +extern Datum cidr_abbrev (PG_FUNCTION_ARGS); +extern Datum inet_set_masklen (PG_FUNCTION_ARGS); +extern Datum oidvectorne (PG_FUNCTION_ARGS); +extern Datum hash_array (PG_FUNCTION_ARGS); +extern Datum cidr_set_masklen (PG_FUNCTION_ARGS); +extern Datum btgetbitmap (PG_FUNCTION_ARGS); +extern Datum hashgetbitmap (PG_FUNCTION_ARGS); +extern Datum gistgetbitmap (PG_FUNCTION_ARGS); +extern Datum i8tof (PG_FUNCTION_ARGS); +extern Datum ftoi8 (PG_FUNCTION_ARGS); +extern Datum namelt (PG_FUNCTION_ARGS); +extern Datum namele (PG_FUNCTION_ARGS); +extern Datum namegt (PG_FUNCTION_ARGS); +extern Datum namege (PG_FUNCTION_ARGS); +extern Datum namene (PG_FUNCTION_ARGS); +extern Datum bpchar (PG_FUNCTION_ARGS); +extern Datum varchar (PG_FUNCTION_ARGS); +extern Datum mktinterval (PG_FUNCTION_ARGS); +extern Datum oidvectorlt (PG_FUNCTION_ARGS); +extern Datum oidvectorle (PG_FUNCTION_ARGS); +extern Datum oidvectoreq (PG_FUNCTION_ARGS); +extern Datum oidvectorge (PG_FUNCTION_ARGS); +extern Datum oidvectorgt (PG_FUNCTION_ARGS); +extern Datum network_network (PG_FUNCTION_ARGS); +extern Datum network_netmask (PG_FUNCTION_ARGS); +extern Datum network_masklen (PG_FUNCTION_ARGS); +extern Datum network_broadcast (PG_FUNCTION_ARGS); +extern Datum network_host (PG_FUNCTION_ARGS); +extern Datum current_user (PG_FUNCTION_ARGS); +extern Datum network_family (PG_FUNCTION_ARGS); +extern Datum int82 (PG_FUNCTION_ARGS); +extern Datum lo_create (PG_FUNCTION_ARGS); +extern Datum oidlt (PG_FUNCTION_ARGS); +extern Datum oidle (PG_FUNCTION_ARGS); +extern Datum byteaoctetlen (PG_FUNCTION_ARGS); +extern Datum byteaGetByte (PG_FUNCTION_ARGS); +extern Datum byteaSetByte (PG_FUNCTION_ARGS); +extern Datum byteaGetBit (PG_FUNCTION_ARGS); +extern Datum byteaSetBit (PG_FUNCTION_ARGS); +extern Datum dist_pl (PG_FUNCTION_ARGS); +extern Datum dist_lb (PG_FUNCTION_ARGS); +extern Datum dist_sl (PG_FUNCTION_ARGS); +extern Datum dist_cpoly (PG_FUNCTION_ARGS); +extern Datum poly_distance (PG_FUNCTION_ARGS); +extern Datum network_show (PG_FUNCTION_ARGS); +extern Datum text_lt (PG_FUNCTION_ARGS); +extern Datum text_le (PG_FUNCTION_ARGS); +extern Datum text_gt (PG_FUNCTION_ARGS); +extern Datum text_ge (PG_FUNCTION_ARGS); +extern Datum array_eq (PG_FUNCTION_ARGS); +extern Datum session_user (PG_FUNCTION_ARGS); +extern Datum array_dims (PG_FUNCTION_ARGS); +extern Datum array_ndims (PG_FUNCTION_ARGS); +extern Datum byteaoverlay (PG_FUNCTION_ARGS); +extern Datum array_in (PG_FUNCTION_ARGS); +extern Datum array_out (PG_FUNCTION_ARGS); +extern Datum byteaoverlay_no_len (PG_FUNCTION_ARGS); +extern Datum macaddr_trunc (PG_FUNCTION_ARGS); +extern Datum int28 (PG_FUNCTION_ARGS); +extern Datum smgrin (PG_FUNCTION_ARGS); +extern Datum smgrout (PG_FUNCTION_ARGS); +extern Datum smgreq (PG_FUNCTION_ARGS); +extern Datum smgrne (PG_FUNCTION_ARGS); +extern Datum lo_import (PG_FUNCTION_ARGS); +extern Datum lo_export (PG_FUNCTION_ARGS); +extern Datum int4inc (PG_FUNCTION_ARGS); +extern Datum lo_import_with_oid (PG_FUNCTION_ARGS); +extern Datum int4larger (PG_FUNCTION_ARGS); +extern Datum int4smaller (PG_FUNCTION_ARGS); +extern Datum int2larger (PG_FUNCTION_ARGS); +extern Datum int2smaller (PG_FUNCTION_ARGS); +extern Datum gistcostestimate (PG_FUNCTION_ARGS); +extern Datum gistgettuple (PG_FUNCTION_ARGS); +extern Datum gistinsert (PG_FUNCTION_ARGS); +extern Datum gistbulkdelete (PG_FUNCTION_ARGS); +extern Datum gistbeginscan (PG_FUNCTION_ARGS); +extern Datum gistrescan (PG_FUNCTION_ARGS); +extern Datum gistendscan (PG_FUNCTION_ARGS); +extern Datum gistmarkpos (PG_FUNCTION_ARGS); +extern Datum gistrestrpos (PG_FUNCTION_ARGS); +extern Datum gistbuild (PG_FUNCTION_ARGS); +extern Datum tintervaleq (PG_FUNCTION_ARGS); +extern Datum tintervalne (PG_FUNCTION_ARGS); +extern Datum tintervallt (PG_FUNCTION_ARGS); +extern Datum tintervalgt (PG_FUNCTION_ARGS); +extern Datum tintervalle (PG_FUNCTION_ARGS); +extern Datum tintervalge (PG_FUNCTION_ARGS); +extern Datum pg_client_encoding (PG_FUNCTION_ARGS); +extern Datum current_query (PG_FUNCTION_ARGS); +extern Datum macaddr_eq (PG_FUNCTION_ARGS); +extern Datum macaddr_lt (PG_FUNCTION_ARGS); +extern Datum macaddr_le (PG_FUNCTION_ARGS); +extern Datum macaddr_gt (PG_FUNCTION_ARGS); +extern Datum macaddr_ge (PG_FUNCTION_ARGS); +extern Datum macaddr_ne (PG_FUNCTION_ARGS); +extern Datum macaddr_cmp (PG_FUNCTION_ARGS); +extern Datum int82pl (PG_FUNCTION_ARGS); +extern Datum int82mi (PG_FUNCTION_ARGS); +extern Datum int82mul (PG_FUNCTION_ARGS); +extern Datum int82div (PG_FUNCTION_ARGS); +extern Datum int28pl (PG_FUNCTION_ARGS); +extern Datum btint8cmp (PG_FUNCTION_ARGS); +extern Datum cash_mul_flt4 (PG_FUNCTION_ARGS); +extern Datum cash_div_flt4 (PG_FUNCTION_ARGS); +extern Datum flt4_mul_cash (PG_FUNCTION_ARGS); +extern Datum textpos (PG_FUNCTION_ARGS); +extern Datum textlike (PG_FUNCTION_ARGS); +extern Datum textnlike (PG_FUNCTION_ARGS); +extern Datum int48eq (PG_FUNCTION_ARGS); +extern Datum int48ne (PG_FUNCTION_ARGS); +extern Datum int48lt (PG_FUNCTION_ARGS); +extern Datum int48gt (PG_FUNCTION_ARGS); +extern Datum int48le (PG_FUNCTION_ARGS); +extern Datum int48ge (PG_FUNCTION_ARGS); +extern Datum namelike (PG_FUNCTION_ARGS); +extern Datum namenlike (PG_FUNCTION_ARGS); +extern Datum char_bpchar (PG_FUNCTION_ARGS); +extern Datum current_database (PG_FUNCTION_ARGS); +extern Datum int4_mul_cash (PG_FUNCTION_ARGS); +extern Datum int2_mul_cash (PG_FUNCTION_ARGS); +extern Datum cash_mul_int4 (PG_FUNCTION_ARGS); +extern Datum cash_div_int4 (PG_FUNCTION_ARGS); +extern Datum cash_mul_int2 (PG_FUNCTION_ARGS); +extern Datum cash_div_int2 (PG_FUNCTION_ARGS); +extern Datum lower (PG_FUNCTION_ARGS); +extern Datum upper (PG_FUNCTION_ARGS); +extern Datum initcap (PG_FUNCTION_ARGS); +extern Datum lpad (PG_FUNCTION_ARGS); +extern Datum rpad (PG_FUNCTION_ARGS); +extern Datum ltrim (PG_FUNCTION_ARGS); +extern Datum rtrim (PG_FUNCTION_ARGS); +extern Datum text_substr (PG_FUNCTION_ARGS); +extern Datum translate (PG_FUNCTION_ARGS); +extern Datum ltrim1 (PG_FUNCTION_ARGS); +extern Datum text_substr_no_len (PG_FUNCTION_ARGS); +extern Datum btrim (PG_FUNCTION_ARGS); +extern Datum btrim1 (PG_FUNCTION_ARGS); +extern Datum cash_in (PG_FUNCTION_ARGS); +extern Datum cash_out (PG_FUNCTION_ARGS); +extern Datum cash_eq (PG_FUNCTION_ARGS); +extern Datum cash_ne (PG_FUNCTION_ARGS); +extern Datum cash_lt (PG_FUNCTION_ARGS); +extern Datum cash_le (PG_FUNCTION_ARGS); +extern Datum cash_gt (PG_FUNCTION_ARGS); +extern Datum cash_ge (PG_FUNCTION_ARGS); +extern Datum cash_pl (PG_FUNCTION_ARGS); +extern Datum cash_mi (PG_FUNCTION_ARGS); +extern Datum cash_mul_flt8 (PG_FUNCTION_ARGS); +extern Datum cash_div_flt8 (PG_FUNCTION_ARGS); +extern Datum cashlarger (PG_FUNCTION_ARGS); +extern Datum cashsmaller (PG_FUNCTION_ARGS); +extern Datum inet_in (PG_FUNCTION_ARGS); +extern Datum inet_out (PG_FUNCTION_ARGS); +extern Datum flt8_mul_cash (PG_FUNCTION_ARGS); +extern Datum network_eq (PG_FUNCTION_ARGS); +extern Datum network_lt (PG_FUNCTION_ARGS); +extern Datum network_le (PG_FUNCTION_ARGS); +extern Datum network_gt (PG_FUNCTION_ARGS); +extern Datum network_ge (PG_FUNCTION_ARGS); +extern Datum network_ne (PG_FUNCTION_ARGS); +extern Datum network_cmp (PG_FUNCTION_ARGS); +extern Datum network_sub (PG_FUNCTION_ARGS); +extern Datum network_subeq (PG_FUNCTION_ARGS); +extern Datum network_sup (PG_FUNCTION_ARGS); +extern Datum network_supeq (PG_FUNCTION_ARGS); +extern Datum cash_words (PG_FUNCTION_ARGS); +extern Datum generate_series_timestamp (PG_FUNCTION_ARGS); +extern Datum generate_series_timestamptz (PG_FUNCTION_ARGS); +extern Datum int28mi (PG_FUNCTION_ARGS); +extern Datum int28mul (PG_FUNCTION_ARGS); +extern Datum text_char (PG_FUNCTION_ARGS); +extern Datum int8mod (PG_FUNCTION_ARGS); +extern Datum char_text (PG_FUNCTION_ARGS); +extern Datum int28div (PG_FUNCTION_ARGS); +extern Datum hashint8 (PG_FUNCTION_ARGS); +extern Datum lo_open (PG_FUNCTION_ARGS); +extern Datum lo_close (PG_FUNCTION_ARGS); +extern Datum loread (PG_FUNCTION_ARGS); +extern Datum lowrite (PG_FUNCTION_ARGS); +extern Datum lo_lseek (PG_FUNCTION_ARGS); +extern Datum lo_creat (PG_FUNCTION_ARGS); +extern Datum lo_tell (PG_FUNCTION_ARGS); +extern Datum on_pl (PG_FUNCTION_ARGS); +extern Datum on_sl (PG_FUNCTION_ARGS); +extern Datum close_pl (PG_FUNCTION_ARGS); +extern Datum close_sl (PG_FUNCTION_ARGS); +extern Datum close_lb (PG_FUNCTION_ARGS); +extern Datum lo_unlink (PG_FUNCTION_ARGS); +extern Datum btvacuumcleanup (PG_FUNCTION_ARGS); +extern Datum path_inter (PG_FUNCTION_ARGS); +extern Datum box_area (PG_FUNCTION_ARGS); +extern Datum box_width (PG_FUNCTION_ARGS); +extern Datum box_height (PG_FUNCTION_ARGS); +extern Datum box_distance (PG_FUNCTION_ARGS); +extern Datum path_area (PG_FUNCTION_ARGS); +extern Datum box_intersect (PG_FUNCTION_ARGS); +extern Datum box_diagonal (PG_FUNCTION_ARGS); +extern Datum path_n_lt (PG_FUNCTION_ARGS); +extern Datum path_n_gt (PG_FUNCTION_ARGS); +extern Datum path_n_eq (PG_FUNCTION_ARGS); +extern Datum path_n_le (PG_FUNCTION_ARGS); +extern Datum path_n_ge (PG_FUNCTION_ARGS); +extern Datum path_length (PG_FUNCTION_ARGS); +extern Datum point_ne (PG_FUNCTION_ARGS); +extern Datum point_vert (PG_FUNCTION_ARGS); +extern Datum point_horiz (PG_FUNCTION_ARGS); +extern Datum point_distance (PG_FUNCTION_ARGS); +extern Datum point_slope (PG_FUNCTION_ARGS); +extern Datum lseg_construct (PG_FUNCTION_ARGS); +extern Datum lseg_intersect (PG_FUNCTION_ARGS); +extern Datum lseg_parallel (PG_FUNCTION_ARGS); +extern Datum lseg_perp (PG_FUNCTION_ARGS); +extern Datum lseg_vertical (PG_FUNCTION_ARGS); +extern Datum lseg_horizontal (PG_FUNCTION_ARGS); +extern Datum lseg_eq (PG_FUNCTION_ARGS); +extern Datum lo_truncate (PG_FUNCTION_ARGS); +extern Datum timestamptz_izone (PG_FUNCTION_ARGS); +extern Datum gist_point_compress (PG_FUNCTION_ARGS); +extern Datum aclitemin (PG_FUNCTION_ARGS); +extern Datum aclitemout (PG_FUNCTION_ARGS); +extern Datum aclinsert (PG_FUNCTION_ARGS); +extern Datum aclremove (PG_FUNCTION_ARGS); +extern Datum aclcontains (PG_FUNCTION_ARGS); +extern Datum getdatabaseencoding (PG_FUNCTION_ARGS); +extern Datum bpcharin (PG_FUNCTION_ARGS); +extern Datum bpcharout (PG_FUNCTION_ARGS); +extern Datum varcharin (PG_FUNCTION_ARGS); +extern Datum varcharout (PG_FUNCTION_ARGS); +extern Datum bpchareq (PG_FUNCTION_ARGS); +extern Datum bpcharlt (PG_FUNCTION_ARGS); +extern Datum bpcharle (PG_FUNCTION_ARGS); +extern Datum bpchargt (PG_FUNCTION_ARGS); +extern Datum bpcharge (PG_FUNCTION_ARGS); +extern Datum bpcharne (PG_FUNCTION_ARGS); +extern Datum aclitem_eq (PG_FUNCTION_ARGS); +extern Datum bpchar_larger (PG_FUNCTION_ARGS); +extern Datum bpchar_smaller (PG_FUNCTION_ARGS); +extern Datum pg_prepared_xact (PG_FUNCTION_ARGS); +extern Datum generate_series_step_int4 (PG_FUNCTION_ARGS); +extern Datum generate_series_int4 (PG_FUNCTION_ARGS); +extern Datum generate_series_step_int8 (PG_FUNCTION_ARGS); +extern Datum generate_series_int8 (PG_FUNCTION_ARGS); +extern Datum bpcharcmp (PG_FUNCTION_ARGS); +extern Datum text_regclass (PG_FUNCTION_ARGS); +extern Datum hashbpchar (PG_FUNCTION_ARGS); +extern Datum format_type (PG_FUNCTION_ARGS); +extern Datum date_in (PG_FUNCTION_ARGS); +extern Datum date_out (PG_FUNCTION_ARGS); +extern Datum date_eq (PG_FUNCTION_ARGS); +extern Datum date_lt (PG_FUNCTION_ARGS); +extern Datum date_le (PG_FUNCTION_ARGS); +extern Datum date_gt (PG_FUNCTION_ARGS); +extern Datum date_ge (PG_FUNCTION_ARGS); +extern Datum date_ne (PG_FUNCTION_ARGS); +extern Datum date_cmp (PG_FUNCTION_ARGS); +extern Datum time_lt (PG_FUNCTION_ARGS); +extern Datum time_le (PG_FUNCTION_ARGS); +extern Datum time_gt (PG_FUNCTION_ARGS); +extern Datum time_ge (PG_FUNCTION_ARGS); +extern Datum time_ne (PG_FUNCTION_ARGS); +extern Datum time_cmp (PG_FUNCTION_ARGS); +extern Datum date_larger (PG_FUNCTION_ARGS); +extern Datum date_smaller (PG_FUNCTION_ARGS); +extern Datum date_mi (PG_FUNCTION_ARGS); +extern Datum date_pli (PG_FUNCTION_ARGS); +extern Datum date_mii (PG_FUNCTION_ARGS); +extern Datum time_in (PG_FUNCTION_ARGS); +extern Datum time_out (PG_FUNCTION_ARGS); +extern Datum time_eq (PG_FUNCTION_ARGS); +extern Datum circle_add_pt (PG_FUNCTION_ARGS); +extern Datum circle_sub_pt (PG_FUNCTION_ARGS); +extern Datum circle_mul_pt (PG_FUNCTION_ARGS); +extern Datum circle_div_pt (PG_FUNCTION_ARGS); +extern Datum timestamptz_in (PG_FUNCTION_ARGS); +extern Datum timestamptz_out (PG_FUNCTION_ARGS); +extern Datum timestamp_eq (PG_FUNCTION_ARGS); +extern Datum timestamp_ne (PG_FUNCTION_ARGS); +extern Datum timestamp_lt (PG_FUNCTION_ARGS); +extern Datum timestamp_le (PG_FUNCTION_ARGS); +extern Datum timestamp_ge (PG_FUNCTION_ARGS); +extern Datum timestamp_gt (PG_FUNCTION_ARGS); +extern Datum timestamptz_zone (PG_FUNCTION_ARGS); +extern Datum interval_in (PG_FUNCTION_ARGS); +extern Datum interval_out (PG_FUNCTION_ARGS); +extern Datum interval_eq (PG_FUNCTION_ARGS); +extern Datum interval_ne (PG_FUNCTION_ARGS); +extern Datum interval_lt (PG_FUNCTION_ARGS); +extern Datum interval_le (PG_FUNCTION_ARGS); +extern Datum interval_ge (PG_FUNCTION_ARGS); +extern Datum interval_gt (PG_FUNCTION_ARGS); +extern Datum interval_um (PG_FUNCTION_ARGS); +extern Datum interval_pl (PG_FUNCTION_ARGS); +extern Datum interval_mi (PG_FUNCTION_ARGS); +extern Datum timestamptz_part (PG_FUNCTION_ARGS); +extern Datum interval_part (PG_FUNCTION_ARGS); +extern Datum abstime_timestamptz (PG_FUNCTION_ARGS); +extern Datum date_timestamptz (PG_FUNCTION_ARGS); +extern Datum interval_justify_hours (PG_FUNCTION_ARGS); +extern Datum reltime_interval (PG_FUNCTION_ARGS); +extern Datum timestamptz_date (PG_FUNCTION_ARGS); +extern Datum abstime_date (PG_FUNCTION_ARGS); +extern Datum timestamptz_abstime (PG_FUNCTION_ARGS); +extern Datum xid_age (PG_FUNCTION_ARGS); +extern Datum timestamp_mi (PG_FUNCTION_ARGS); +extern Datum timestamptz_pl_interval (PG_FUNCTION_ARGS); +extern Datum timestamptz_mi_interval (PG_FUNCTION_ARGS); +extern Datum generate_subscripts (PG_FUNCTION_ARGS); +extern Datum generate_subscripts_nodir (PG_FUNCTION_ARGS); +extern Datum array_fill (PG_FUNCTION_ARGS); +extern Datum interval_reltime (PG_FUNCTION_ARGS); +extern Datum timestamp_smaller (PG_FUNCTION_ARGS); +extern Datum timestamp_larger (PG_FUNCTION_ARGS); +extern Datum interval_smaller (PG_FUNCTION_ARGS); +extern Datum interval_larger (PG_FUNCTION_ARGS); +extern Datum timestamptz_age (PG_FUNCTION_ARGS); +extern Datum interval_scale (PG_FUNCTION_ARGS); +extern Datum timestamptz_trunc (PG_FUNCTION_ARGS); +extern Datum interval_trunc (PG_FUNCTION_ARGS); +extern Datum int8inc (PG_FUNCTION_ARGS); +extern Datum int8abs (PG_FUNCTION_ARGS); +extern Datum int8larger (PG_FUNCTION_ARGS); +extern Datum int8smaller (PG_FUNCTION_ARGS); +extern Datum texticregexeq (PG_FUNCTION_ARGS); +extern Datum texticregexne (PG_FUNCTION_ARGS); +extern Datum nameicregexeq (PG_FUNCTION_ARGS); +extern Datum nameicregexne (PG_FUNCTION_ARGS); +extern Datum boolin (PG_FUNCTION_ARGS); +extern Datum boolout (PG_FUNCTION_ARGS); +extern Datum byteain (PG_FUNCTION_ARGS); +extern Datum charin (PG_FUNCTION_ARGS); +extern Datum charlt (PG_FUNCTION_ARGS); +extern Datum unique_key_recheck (PG_FUNCTION_ARGS); +extern Datum int4abs (PG_FUNCTION_ARGS); +extern Datum nameregexne (PG_FUNCTION_ARGS); +extern Datum int2abs (PG_FUNCTION_ARGS); +extern Datum textregexeq (PG_FUNCTION_ARGS); +extern Datum textregexne (PG_FUNCTION_ARGS); +extern Datum textlen (PG_FUNCTION_ARGS); +extern Datum textcat (PG_FUNCTION_ARGS); +extern Datum PG_char_to_encoding (PG_FUNCTION_ARGS); +extern Datum tidne (PG_FUNCTION_ARGS); +extern Datum cidr_in (PG_FUNCTION_ARGS); +extern Datum btcostestimate (PG_FUNCTION_ARGS); +extern Datum pg_column_size (PG_FUNCTION_ARGS); +extern Datum overlaps_timetz (PG_FUNCTION_ARGS); +extern Datum datetime_timestamp (PG_FUNCTION_ARGS); +extern Datum timetz_part (PG_FUNCTION_ARGS); +extern Datum int84pl (PG_FUNCTION_ARGS); +extern Datum int84mi (PG_FUNCTION_ARGS); +extern Datum int84mul (PG_FUNCTION_ARGS); +extern Datum int84div (PG_FUNCTION_ARGS); +extern Datum int48pl (PG_FUNCTION_ARGS); +extern Datum int48mi (PG_FUNCTION_ARGS); +extern Datum int48mul (PG_FUNCTION_ARGS); +extern Datum int48div (PG_FUNCTION_ARGS); +extern Datum quote_ident (PG_FUNCTION_ARGS); +extern Datum quote_literal (PG_FUNCTION_ARGS); +extern Datum array_fill_with_lower_bounds (PG_FUNCTION_ARGS); +extern Datum i8tooid (PG_FUNCTION_ARGS); +extern Datum oidtoi8 (PG_FUNCTION_ARGS); +extern Datum quote_nullable (PG_FUNCTION_ARGS); +extern Datum suppress_redundant_updates_trigger (PG_FUNCTION_ARGS); +extern Datum tideq (PG_FUNCTION_ARGS); +extern Datum currtid_byreloid (PG_FUNCTION_ARGS); +extern Datum currtid_byrelname (PG_FUNCTION_ARGS); +extern Datum interval_justify_days (PG_FUNCTION_ARGS); +extern Datum datetimetz_timestamptz (PG_FUNCTION_ARGS); +extern Datum now (PG_FUNCTION_ARGS); +extern Datum positionsel (PG_FUNCTION_ARGS); +extern Datum positionjoinsel (PG_FUNCTION_ARGS); +extern Datum contsel (PG_FUNCTION_ARGS); +extern Datum contjoinsel (PG_FUNCTION_ARGS); +extern Datum overlaps_timestamp (PG_FUNCTION_ARGS); +extern Datum overlaps_time (PG_FUNCTION_ARGS); +extern Datum timestamp_in (PG_FUNCTION_ARGS); +extern Datum timestamp_out (PG_FUNCTION_ARGS); +extern Datum timestamp_cmp (PG_FUNCTION_ARGS); +extern Datum interval_cmp (PG_FUNCTION_ARGS); +extern Datum timestamp_time (PG_FUNCTION_ARGS); +extern Datum bpcharlen (PG_FUNCTION_ARGS); +extern Datum interval_div (PG_FUNCTION_ARGS); +extern Datum dlog10 (PG_FUNCTION_ARGS); +extern Datum oidvectortypes (PG_FUNCTION_ARGS); +extern Datum timetz_in (PG_FUNCTION_ARGS); +extern Datum timetz_out (PG_FUNCTION_ARGS); +extern Datum timetz_eq (PG_FUNCTION_ARGS); +extern Datum timetz_ne (PG_FUNCTION_ARGS); +extern Datum timetz_lt (PG_FUNCTION_ARGS); +extern Datum timetz_le (PG_FUNCTION_ARGS); +extern Datum timetz_ge (PG_FUNCTION_ARGS); +extern Datum timetz_gt (PG_FUNCTION_ARGS); +extern Datum timetz_cmp (PG_FUNCTION_ARGS); +extern Datum network_hostmask (PG_FUNCTION_ARGS); +extern Datum makeaclitem (PG_FUNCTION_ARGS); +extern Datum time_interval (PG_FUNCTION_ARGS); +extern Datum pg_lock_status (PG_FUNCTION_ARGS); +extern Datum date_finite (PG_FUNCTION_ARGS); +extern Datum textoctetlen (PG_FUNCTION_ARGS); +extern Datum bpcharoctetlen (PG_FUNCTION_ARGS); +extern Datum time_larger (PG_FUNCTION_ARGS); +extern Datum time_smaller (PG_FUNCTION_ARGS); +extern Datum timetz_larger (PG_FUNCTION_ARGS); +extern Datum timetz_smaller (PG_FUNCTION_ARGS); +extern Datum time_part (PG_FUNCTION_ARGS); +extern Datum pg_get_constraintdef (PG_FUNCTION_ARGS); +extern Datum timestamptz_timetz (PG_FUNCTION_ARGS); +extern Datum timestamp_finite (PG_FUNCTION_ARGS); +extern Datum interval_finite (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_backend_start (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_backend_client_addr (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_backend_client_port (PG_FUNCTION_ARGS); +extern Datum current_schema (PG_FUNCTION_ARGS); +extern Datum current_schemas (PG_FUNCTION_ARGS); +extern Datum textoverlay (PG_FUNCTION_ARGS); +extern Datum textoverlay_no_len (PG_FUNCTION_ARGS); +extern Datum line_parallel (PG_FUNCTION_ARGS); +extern Datum line_perp (PG_FUNCTION_ARGS); +extern Datum line_vertical (PG_FUNCTION_ARGS); +extern Datum line_horizontal (PG_FUNCTION_ARGS); +extern Datum circle_center (PG_FUNCTION_ARGS); +extern Datum interval_time (PG_FUNCTION_ARGS); +extern Datum points_box (PG_FUNCTION_ARGS); +extern Datum box_add (PG_FUNCTION_ARGS); +extern Datum box_sub (PG_FUNCTION_ARGS); +extern Datum box_mul (PG_FUNCTION_ARGS); +extern Datum box_div (PG_FUNCTION_ARGS); +extern Datum cidr_out (PG_FUNCTION_ARGS); +extern Datum poly_contain_pt (PG_FUNCTION_ARGS); +extern Datum pt_contained_poly (PG_FUNCTION_ARGS); +extern Datum path_isclosed (PG_FUNCTION_ARGS); +extern Datum path_isopen (PG_FUNCTION_ARGS); +extern Datum path_npoints (PG_FUNCTION_ARGS); +extern Datum path_close (PG_FUNCTION_ARGS); +extern Datum path_open (PG_FUNCTION_ARGS); +extern Datum path_add (PG_FUNCTION_ARGS); +extern Datum path_add_pt (PG_FUNCTION_ARGS); +extern Datum path_sub_pt (PG_FUNCTION_ARGS); +extern Datum path_mul_pt (PG_FUNCTION_ARGS); +extern Datum path_div_pt (PG_FUNCTION_ARGS); +extern Datum construct_point (PG_FUNCTION_ARGS); +extern Datum point_add (PG_FUNCTION_ARGS); +extern Datum point_sub (PG_FUNCTION_ARGS); +extern Datum point_mul (PG_FUNCTION_ARGS); +extern Datum point_div (PG_FUNCTION_ARGS); +extern Datum poly_npoints (PG_FUNCTION_ARGS); +extern Datum poly_box (PG_FUNCTION_ARGS); +extern Datum poly_path (PG_FUNCTION_ARGS); +extern Datum box_poly (PG_FUNCTION_ARGS); +extern Datum path_poly (PG_FUNCTION_ARGS); +extern Datum circle_in (PG_FUNCTION_ARGS); +extern Datum circle_out (PG_FUNCTION_ARGS); +extern Datum circle_same (PG_FUNCTION_ARGS); +extern Datum circle_contain (PG_FUNCTION_ARGS); +extern Datum circle_left (PG_FUNCTION_ARGS); +extern Datum circle_overleft (PG_FUNCTION_ARGS); +extern Datum circle_overright (PG_FUNCTION_ARGS); +extern Datum circle_right (PG_FUNCTION_ARGS); +extern Datum circle_contained (PG_FUNCTION_ARGS); +extern Datum circle_overlap (PG_FUNCTION_ARGS); +extern Datum circle_below (PG_FUNCTION_ARGS); +extern Datum circle_above (PG_FUNCTION_ARGS); +extern Datum circle_eq (PG_FUNCTION_ARGS); +extern Datum circle_ne (PG_FUNCTION_ARGS); +extern Datum circle_lt (PG_FUNCTION_ARGS); +extern Datum circle_gt (PG_FUNCTION_ARGS); +extern Datum circle_le (PG_FUNCTION_ARGS); +extern Datum circle_ge (PG_FUNCTION_ARGS); +extern Datum circle_area (PG_FUNCTION_ARGS); +extern Datum circle_diameter (PG_FUNCTION_ARGS); +extern Datum circle_radius (PG_FUNCTION_ARGS); +extern Datum circle_distance (PG_FUNCTION_ARGS); +extern Datum cr_circle (PG_FUNCTION_ARGS); +extern Datum poly_circle (PG_FUNCTION_ARGS); +extern Datum circle_poly (PG_FUNCTION_ARGS); +extern Datum dist_pc (PG_FUNCTION_ARGS); +extern Datum circle_contain_pt (PG_FUNCTION_ARGS); +extern Datum pt_contained_circle (PG_FUNCTION_ARGS); +extern Datum box_circle (PG_FUNCTION_ARGS); +extern Datum circle_box (PG_FUNCTION_ARGS); +extern Datum lseg_ne (PG_FUNCTION_ARGS); +extern Datum lseg_lt (PG_FUNCTION_ARGS); +extern Datum lseg_le (PG_FUNCTION_ARGS); +extern Datum lseg_gt (PG_FUNCTION_ARGS); +extern Datum lseg_ge (PG_FUNCTION_ARGS); +extern Datum lseg_length (PG_FUNCTION_ARGS); +extern Datum close_ls (PG_FUNCTION_ARGS); +extern Datum close_lseg (PG_FUNCTION_ARGS); +extern Datum line_in (PG_FUNCTION_ARGS); +extern Datum line_out (PG_FUNCTION_ARGS); +extern Datum line_eq (PG_FUNCTION_ARGS); +extern Datum line_construct_pp (PG_FUNCTION_ARGS); +extern Datum line_interpt (PG_FUNCTION_ARGS); +extern Datum line_intersect (PG_FUNCTION_ARGS); +extern Datum bit_in (PG_FUNCTION_ARGS); +extern Datum bit_out (PG_FUNCTION_ARGS); +extern Datum pg_get_ruledef (PG_FUNCTION_ARGS); +extern Datum nextval_oid (PG_FUNCTION_ARGS); +extern Datum currval_oid (PG_FUNCTION_ARGS); +extern Datum setval_oid (PG_FUNCTION_ARGS); +extern Datum varbit_in (PG_FUNCTION_ARGS); +extern Datum varbit_out (PG_FUNCTION_ARGS); +extern Datum biteq (PG_FUNCTION_ARGS); +extern Datum bitne (PG_FUNCTION_ARGS); +extern Datum bitge (PG_FUNCTION_ARGS); +extern Datum bitgt (PG_FUNCTION_ARGS); +extern Datum bitle (PG_FUNCTION_ARGS); +extern Datum bitlt (PG_FUNCTION_ARGS); +extern Datum bitcmp (PG_FUNCTION_ARGS); +extern Datum PG_encoding_to_char (PG_FUNCTION_ARGS); +extern Datum drandom (PG_FUNCTION_ARGS); +extern Datum setseed (PG_FUNCTION_ARGS); +extern Datum dasin (PG_FUNCTION_ARGS); +extern Datum dacos (PG_FUNCTION_ARGS); +extern Datum datan (PG_FUNCTION_ARGS); +extern Datum datan2 (PG_FUNCTION_ARGS); +extern Datum dsin (PG_FUNCTION_ARGS); +extern Datum dcos (PG_FUNCTION_ARGS); +extern Datum dtan (PG_FUNCTION_ARGS); +extern Datum dcot (PG_FUNCTION_ARGS); +extern Datum degrees (PG_FUNCTION_ARGS); +extern Datum radians (PG_FUNCTION_ARGS); +extern Datum dpi (PG_FUNCTION_ARGS); +extern Datum interval_mul (PG_FUNCTION_ARGS); +extern Datum pg_typeof (PG_FUNCTION_ARGS); +extern Datum ascii (PG_FUNCTION_ARGS); +extern Datum chr (PG_FUNCTION_ARGS); +extern Datum repeat (PG_FUNCTION_ARGS); +extern Datum similar_escape (PG_FUNCTION_ARGS); +extern Datum mul_d_interval (PG_FUNCTION_ARGS); +extern Datum texticlike (PG_FUNCTION_ARGS); +extern Datum texticnlike (PG_FUNCTION_ARGS); +extern Datum nameiclike (PG_FUNCTION_ARGS); +extern Datum nameicnlike (PG_FUNCTION_ARGS); +extern Datum like_escape (PG_FUNCTION_ARGS); +extern Datum oidgt (PG_FUNCTION_ARGS); +extern Datum oidge (PG_FUNCTION_ARGS); +extern Datum pg_get_viewdef_name (PG_FUNCTION_ARGS); +extern Datum pg_get_viewdef (PG_FUNCTION_ARGS); +extern Datum pg_get_userbyid (PG_FUNCTION_ARGS); +extern Datum pg_get_indexdef (PG_FUNCTION_ARGS); +extern Datum RI_FKey_check_ins (PG_FUNCTION_ARGS); +extern Datum RI_FKey_check_upd (PG_FUNCTION_ARGS); +extern Datum RI_FKey_cascade_del (PG_FUNCTION_ARGS); +extern Datum RI_FKey_cascade_upd (PG_FUNCTION_ARGS); +extern Datum RI_FKey_restrict_del (PG_FUNCTION_ARGS); +extern Datum RI_FKey_restrict_upd (PG_FUNCTION_ARGS); +extern Datum RI_FKey_setnull_del (PG_FUNCTION_ARGS); +extern Datum RI_FKey_setnull_upd (PG_FUNCTION_ARGS); +extern Datum RI_FKey_setdefault_del (PG_FUNCTION_ARGS); +extern Datum RI_FKey_setdefault_upd (PG_FUNCTION_ARGS); +extern Datum RI_FKey_noaction_del (PG_FUNCTION_ARGS); +extern Datum RI_FKey_noaction_upd (PG_FUNCTION_ARGS); +extern Datum pg_get_triggerdef (PG_FUNCTION_ARGS); +extern Datum pg_get_serial_sequence (PG_FUNCTION_ARGS); +extern Datum bit_and (PG_FUNCTION_ARGS); +extern Datum bit_or (PG_FUNCTION_ARGS); +extern Datum bitxor (PG_FUNCTION_ARGS); +extern Datum bitnot (PG_FUNCTION_ARGS); +extern Datum bitshiftleft (PG_FUNCTION_ARGS); +extern Datum bitshiftright (PG_FUNCTION_ARGS); +extern Datum bitcat (PG_FUNCTION_ARGS); +extern Datum bitsubstr (PG_FUNCTION_ARGS); +extern Datum bitlength (PG_FUNCTION_ARGS); +extern Datum bitoctetlength (PG_FUNCTION_ARGS); +extern Datum bitfromint4 (PG_FUNCTION_ARGS); +extern Datum bittoint4 (PG_FUNCTION_ARGS); +extern Datum bit (PG_FUNCTION_ARGS); +extern Datum pg_get_keywords (PG_FUNCTION_ARGS); +extern Datum varbit (PG_FUNCTION_ARGS); +extern Datum time_hash (PG_FUNCTION_ARGS); +extern Datum aclexplode (PG_FUNCTION_ARGS); +extern Datum time_mi_time (PG_FUNCTION_ARGS); +extern Datum boolle (PG_FUNCTION_ARGS); +extern Datum boolge (PG_FUNCTION_ARGS); +extern Datum btboolcmp (PG_FUNCTION_ARGS); +extern Datum timetz_hash (PG_FUNCTION_ARGS); +extern Datum interval_hash (PG_FUNCTION_ARGS); +extern Datum bitposition (PG_FUNCTION_ARGS); +extern Datum bitsubstr_no_len (PG_FUNCTION_ARGS); +extern Datum numeric_in (PG_FUNCTION_ARGS); +extern Datum numeric_out (PG_FUNCTION_ARGS); +extern Datum numeric (PG_FUNCTION_ARGS); +extern Datum numeric_abs (PG_FUNCTION_ARGS); +extern Datum numeric_sign (PG_FUNCTION_ARGS); +extern Datum numeric_round (PG_FUNCTION_ARGS); +extern Datum numeric_trunc (PG_FUNCTION_ARGS); +extern Datum numeric_ceil (PG_FUNCTION_ARGS); +extern Datum numeric_floor (PG_FUNCTION_ARGS); +extern Datum length_in_encoding (PG_FUNCTION_ARGS); +extern Datum pg_convert_from (PG_FUNCTION_ARGS); +extern Datum inet_to_cidr (PG_FUNCTION_ARGS); +extern Datum pg_get_expr (PG_FUNCTION_ARGS); +extern Datum pg_convert_to (PG_FUNCTION_ARGS); +extern Datum numeric_eq (PG_FUNCTION_ARGS); +extern Datum numeric_ne (PG_FUNCTION_ARGS); +extern Datum numeric_gt (PG_FUNCTION_ARGS); +extern Datum numeric_ge (PG_FUNCTION_ARGS); +extern Datum numeric_lt (PG_FUNCTION_ARGS); +extern Datum numeric_le (PG_FUNCTION_ARGS); +extern Datum numeric_add (PG_FUNCTION_ARGS); +extern Datum numeric_sub (PG_FUNCTION_ARGS); +extern Datum numeric_mul (PG_FUNCTION_ARGS); +extern Datum numeric_div (PG_FUNCTION_ARGS); +extern Datum numeric_mod (PG_FUNCTION_ARGS); +extern Datum numeric_sqrt (PG_FUNCTION_ARGS); +extern Datum numeric_exp (PG_FUNCTION_ARGS); +extern Datum numeric_ln (PG_FUNCTION_ARGS); +extern Datum numeric_log (PG_FUNCTION_ARGS); +extern Datum numeric_power (PG_FUNCTION_ARGS); +extern Datum int4_numeric (PG_FUNCTION_ARGS); +extern Datum float4_numeric (PG_FUNCTION_ARGS); +extern Datum float8_numeric (PG_FUNCTION_ARGS); +extern Datum numeric_int4 (PG_FUNCTION_ARGS); +extern Datum numeric_float4 (PG_FUNCTION_ARGS); +extern Datum numeric_float8 (PG_FUNCTION_ARGS); +extern Datum time_pl_interval (PG_FUNCTION_ARGS); +extern Datum time_mi_interval (PG_FUNCTION_ARGS); +extern Datum timetz_pl_interval (PG_FUNCTION_ARGS); +extern Datum timetz_mi_interval (PG_FUNCTION_ARGS); +extern Datum numeric_inc (PG_FUNCTION_ARGS); +extern Datum setval3_oid (PG_FUNCTION_ARGS); +extern Datum numeric_smaller (PG_FUNCTION_ARGS); +extern Datum numeric_larger (PG_FUNCTION_ARGS); +extern Datum interval_to_char (PG_FUNCTION_ARGS); +extern Datum numeric_cmp (PG_FUNCTION_ARGS); +extern Datum timestamptz_to_char (PG_FUNCTION_ARGS); +extern Datum numeric_uminus (PG_FUNCTION_ARGS); +extern Datum numeric_to_char (PG_FUNCTION_ARGS); +extern Datum int4_to_char (PG_FUNCTION_ARGS); +extern Datum int8_to_char (PG_FUNCTION_ARGS); +extern Datum float4_to_char (PG_FUNCTION_ARGS); +extern Datum float8_to_char (PG_FUNCTION_ARGS); +extern Datum numeric_to_number (PG_FUNCTION_ARGS); +extern Datum to_timestamp (PG_FUNCTION_ARGS); +extern Datum numeric_int8 (PG_FUNCTION_ARGS); +extern Datum to_date (PG_FUNCTION_ARGS); +extern Datum int8_numeric (PG_FUNCTION_ARGS); +extern Datum int2_numeric (PG_FUNCTION_ARGS); +extern Datum numeric_int2 (PG_FUNCTION_ARGS); +extern Datum oidin (PG_FUNCTION_ARGS); +extern Datum oidout (PG_FUNCTION_ARGS); +extern Datum pg_convert (PG_FUNCTION_ARGS); +extern Datum iclikesel (PG_FUNCTION_ARGS); +extern Datum icnlikesel (PG_FUNCTION_ARGS); +extern Datum iclikejoinsel (PG_FUNCTION_ARGS); +extern Datum icnlikejoinsel (PG_FUNCTION_ARGS); +extern Datum regexeqsel (PG_FUNCTION_ARGS); +extern Datum likesel (PG_FUNCTION_ARGS); +extern Datum icregexeqsel (PG_FUNCTION_ARGS); +extern Datum regexnesel (PG_FUNCTION_ARGS); +extern Datum nlikesel (PG_FUNCTION_ARGS); +extern Datum icregexnesel (PG_FUNCTION_ARGS); +extern Datum regexeqjoinsel (PG_FUNCTION_ARGS); +extern Datum likejoinsel (PG_FUNCTION_ARGS); +extern Datum icregexeqjoinsel (PG_FUNCTION_ARGS); +extern Datum regexnejoinsel (PG_FUNCTION_ARGS); +extern Datum nlikejoinsel (PG_FUNCTION_ARGS); +extern Datum icregexnejoinsel (PG_FUNCTION_ARGS); +extern Datum float8_avg (PG_FUNCTION_ARGS); +extern Datum float8_var_samp (PG_FUNCTION_ARGS); +extern Datum float8_stddev_samp (PG_FUNCTION_ARGS); +extern Datum numeric_accum (PG_FUNCTION_ARGS); +extern Datum int2_accum (PG_FUNCTION_ARGS); +extern Datum int4_accum (PG_FUNCTION_ARGS); +extern Datum int8_accum (PG_FUNCTION_ARGS); +extern Datum numeric_avg (PG_FUNCTION_ARGS); +extern Datum numeric_var_samp (PG_FUNCTION_ARGS); +extern Datum numeric_stddev_samp (PG_FUNCTION_ARGS); +extern Datum int2_sum (PG_FUNCTION_ARGS); +extern Datum int4_sum (PG_FUNCTION_ARGS); +extern Datum int8_sum (PG_FUNCTION_ARGS); +extern Datum interval_accum (PG_FUNCTION_ARGS); +extern Datum interval_avg (PG_FUNCTION_ARGS); +extern Datum to_ascii_default (PG_FUNCTION_ARGS); +extern Datum to_ascii_enc (PG_FUNCTION_ARGS); +extern Datum to_ascii_encname (PG_FUNCTION_ARGS); +extern Datum int28eq (PG_FUNCTION_ARGS); +extern Datum int28ne (PG_FUNCTION_ARGS); +extern Datum int28lt (PG_FUNCTION_ARGS); +extern Datum int28gt (PG_FUNCTION_ARGS); +extern Datum int28le (PG_FUNCTION_ARGS); +extern Datum int28ge (PG_FUNCTION_ARGS); +extern Datum int82eq (PG_FUNCTION_ARGS); +extern Datum int82ne (PG_FUNCTION_ARGS); +extern Datum int82lt (PG_FUNCTION_ARGS); +extern Datum int82gt (PG_FUNCTION_ARGS); +extern Datum int82le (PG_FUNCTION_ARGS); +extern Datum int82ge (PG_FUNCTION_ARGS); +extern Datum int2and (PG_FUNCTION_ARGS); +extern Datum int2or (PG_FUNCTION_ARGS); +extern Datum int2xor (PG_FUNCTION_ARGS); +extern Datum int2not (PG_FUNCTION_ARGS); +extern Datum int2shl (PG_FUNCTION_ARGS); +extern Datum int2shr (PG_FUNCTION_ARGS); +extern Datum int4and (PG_FUNCTION_ARGS); +extern Datum int4or (PG_FUNCTION_ARGS); +extern Datum int4xor (PG_FUNCTION_ARGS); +extern Datum int4not (PG_FUNCTION_ARGS); +extern Datum int4shl (PG_FUNCTION_ARGS); +extern Datum int4shr (PG_FUNCTION_ARGS); +extern Datum int8and (PG_FUNCTION_ARGS); +extern Datum int8or (PG_FUNCTION_ARGS); +extern Datum int8xor (PG_FUNCTION_ARGS); +extern Datum int8not (PG_FUNCTION_ARGS); +extern Datum int8shl (PG_FUNCTION_ARGS); +extern Datum int8shr (PG_FUNCTION_ARGS); +extern Datum int8up (PG_FUNCTION_ARGS); +extern Datum int2up (PG_FUNCTION_ARGS); +extern Datum int4up (PG_FUNCTION_ARGS); +extern Datum float4up (PG_FUNCTION_ARGS); +extern Datum float8up (PG_FUNCTION_ARGS); +extern Datum numeric_uplus (PG_FUNCTION_ARGS); +extern Datum has_table_privilege_name_name (PG_FUNCTION_ARGS); +extern Datum has_table_privilege_name_id (PG_FUNCTION_ARGS); +extern Datum has_table_privilege_id_name (PG_FUNCTION_ARGS); +extern Datum has_table_privilege_id_id (PG_FUNCTION_ARGS); +extern Datum has_table_privilege_name (PG_FUNCTION_ARGS); +extern Datum has_table_privilege_id (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_numscans (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_tuples_returned (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_tuples_fetched (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_tuples_inserted (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_tuples_updated (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_tuples_deleted (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_blocks_fetched (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_blocks_hit (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_backend_idset (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_backend_pid (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_backend_dbid (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_backend_userid (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_backend_activity (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_db_numbackends (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_db_xact_commit (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_db_xact_rollback (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_db_blocks_fetched (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_db_blocks_hit (PG_FUNCTION_ARGS); +extern Datum binary_encode (PG_FUNCTION_ARGS); +extern Datum binary_decode (PG_FUNCTION_ARGS); +extern Datum byteaeq (PG_FUNCTION_ARGS); +extern Datum bytealt (PG_FUNCTION_ARGS); +extern Datum byteale (PG_FUNCTION_ARGS); +extern Datum byteagt (PG_FUNCTION_ARGS); +extern Datum byteage (PG_FUNCTION_ARGS); +extern Datum byteane (PG_FUNCTION_ARGS); +extern Datum byteacmp (PG_FUNCTION_ARGS); +extern Datum timestamp_scale (PG_FUNCTION_ARGS); +extern Datum int2_avg_accum (PG_FUNCTION_ARGS); +extern Datum int4_avg_accum (PG_FUNCTION_ARGS); +extern Datum int8_avg (PG_FUNCTION_ARGS); +extern Datum oidlarger (PG_FUNCTION_ARGS); +extern Datum oidsmaller (PG_FUNCTION_ARGS); +extern Datum timestamptz_scale (PG_FUNCTION_ARGS); +extern Datum time_scale (PG_FUNCTION_ARGS); +extern Datum timetz_scale (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_tuples_hot_updated (PG_FUNCTION_ARGS); +extern Datum numeric_div_trunc (PG_FUNCTION_ARGS); +extern Datum bytealike (PG_FUNCTION_ARGS); +extern Datum byteanlike (PG_FUNCTION_ARGS); +extern Datum like_escape_bytea (PG_FUNCTION_ARGS); +extern Datum byteacat (PG_FUNCTION_ARGS); +extern Datum bytea_substr (PG_FUNCTION_ARGS); +extern Datum bytea_substr_no_len (PG_FUNCTION_ARGS); +extern Datum byteapos (PG_FUNCTION_ARGS); +extern Datum byteatrim (PG_FUNCTION_ARGS); +extern Datum timestamptz_time (PG_FUNCTION_ARGS); +extern Datum timestamp_trunc (PG_FUNCTION_ARGS); +extern Datum timestamp_part (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_activity (PG_FUNCTION_ARGS); +extern Datum abstime_timestamp (PG_FUNCTION_ARGS); +extern Datum date_timestamp (PG_FUNCTION_ARGS); +extern Datum pg_backend_pid (PG_FUNCTION_ARGS); +extern Datum timestamptz_timestamp (PG_FUNCTION_ARGS); +extern Datum timestamp_timestamptz (PG_FUNCTION_ARGS); +extern Datum timestamp_date (PG_FUNCTION_ARGS); +extern Datum timestamp_abstime (PG_FUNCTION_ARGS); +extern Datum timestamp_pl_interval (PG_FUNCTION_ARGS); +extern Datum timestamp_mi_interval (PG_FUNCTION_ARGS); +extern Datum pg_conf_load_time (PG_FUNCTION_ARGS); +extern Datum timetz_zone (PG_FUNCTION_ARGS); +extern Datum timetz_izone (PG_FUNCTION_ARGS); +extern Datum timestamp_hash (PG_FUNCTION_ARGS); +extern Datum timetz_time (PG_FUNCTION_ARGS); +extern Datum time_timetz (PG_FUNCTION_ARGS); +extern Datum timestamp_to_char (PG_FUNCTION_ARGS); +extern Datum aggregate_dummy (PG_FUNCTION_ARGS); +extern Datum timestamp_age (PG_FUNCTION_ARGS); +extern Datum timestamp_zone (PG_FUNCTION_ARGS); +extern Datum timestamp_izone (PG_FUNCTION_ARGS); +extern Datum date_pl_interval (PG_FUNCTION_ARGS); +extern Datum date_mi_interval (PG_FUNCTION_ARGS); +extern Datum textregexsubstr (PG_FUNCTION_ARGS); +extern Datum bitfromint8 (PG_FUNCTION_ARGS); +extern Datum bittoint8 (PG_FUNCTION_ARGS); +extern Datum show_config_by_name (PG_FUNCTION_ARGS); +extern Datum set_config_by_name (PG_FUNCTION_ARGS); +extern Datum pg_table_is_visible (PG_FUNCTION_ARGS); +extern Datum pg_type_is_visible (PG_FUNCTION_ARGS); +extern Datum pg_function_is_visible (PG_FUNCTION_ARGS); +extern Datum pg_operator_is_visible (PG_FUNCTION_ARGS); +extern Datum pg_opclass_is_visible (PG_FUNCTION_ARGS); +extern Datum show_all_settings (PG_FUNCTION_ARGS); +extern Datum replace_text (PG_FUNCTION_ARGS); +extern Datum split_text (PG_FUNCTION_ARGS); +extern Datum to_hex32 (PG_FUNCTION_ARGS); +extern Datum to_hex64 (PG_FUNCTION_ARGS); +extern Datum array_lower (PG_FUNCTION_ARGS); +extern Datum array_upper (PG_FUNCTION_ARGS); +extern Datum pg_conversion_is_visible (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_backend_activity_start (PG_FUNCTION_ARGS); +extern Datum pg_terminate_backend (PG_FUNCTION_ARGS); +extern Datum pg_get_functiondef (PG_FUNCTION_ARGS); +extern Datum text_pattern_lt (PG_FUNCTION_ARGS); +extern Datum text_pattern_le (PG_FUNCTION_ARGS); +extern Datum pg_get_function_arguments (PG_FUNCTION_ARGS); +extern Datum text_pattern_ge (PG_FUNCTION_ARGS); +extern Datum text_pattern_gt (PG_FUNCTION_ARGS); +extern Datum pg_get_function_result (PG_FUNCTION_ARGS); +extern Datum bttext_pattern_cmp (PG_FUNCTION_ARGS); +extern Datum pg_database_size_name (PG_FUNCTION_ARGS); +extern Datum width_bucket_numeric (PG_FUNCTION_ARGS); +extern Datum pg_cancel_backend (PG_FUNCTION_ARGS); +extern Datum pg_start_backup (PG_FUNCTION_ARGS); +extern Datum pg_stop_backup (PG_FUNCTION_ARGS); +extern Datum bpchar_pattern_lt (PG_FUNCTION_ARGS); +extern Datum bpchar_pattern_le (PG_FUNCTION_ARGS); +extern Datum array_length (PG_FUNCTION_ARGS); +extern Datum bpchar_pattern_ge (PG_FUNCTION_ARGS); +extern Datum bpchar_pattern_gt (PG_FUNCTION_ARGS); +extern Datum gist_point_consistent (PG_FUNCTION_ARGS); +extern Datum btbpchar_pattern_cmp (PG_FUNCTION_ARGS); +extern Datum has_sequence_privilege_name_name (PG_FUNCTION_ARGS); +extern Datum has_sequence_privilege_name_id (PG_FUNCTION_ARGS); +extern Datum has_sequence_privilege_id_name (PG_FUNCTION_ARGS); +extern Datum has_sequence_privilege_id_id (PG_FUNCTION_ARGS); +extern Datum has_sequence_privilege_name (PG_FUNCTION_ARGS); +extern Datum has_sequence_privilege_id (PG_FUNCTION_ARGS); +extern Datum btint48cmp (PG_FUNCTION_ARGS); +extern Datum btint84cmp (PG_FUNCTION_ARGS); +extern Datum btint24cmp (PG_FUNCTION_ARGS); +extern Datum btint42cmp (PG_FUNCTION_ARGS); +extern Datum btint28cmp (PG_FUNCTION_ARGS); +extern Datum btint82cmp (PG_FUNCTION_ARGS); +extern Datum btfloat48cmp (PG_FUNCTION_ARGS); +extern Datum btfloat84cmp (PG_FUNCTION_ARGS); +extern Datum inet_client_addr (PG_FUNCTION_ARGS); +extern Datum inet_client_port (PG_FUNCTION_ARGS); +extern Datum inet_server_addr (PG_FUNCTION_ARGS); +extern Datum inet_server_port (PG_FUNCTION_ARGS); +extern Datum regprocedurein (PG_FUNCTION_ARGS); +extern Datum regprocedureout (PG_FUNCTION_ARGS); +extern Datum regoperin (PG_FUNCTION_ARGS); +extern Datum regoperout (PG_FUNCTION_ARGS); +extern Datum regoperatorin (PG_FUNCTION_ARGS); +extern Datum regoperatorout (PG_FUNCTION_ARGS); +extern Datum regclassin (PG_FUNCTION_ARGS); +extern Datum regclassout (PG_FUNCTION_ARGS); +extern Datum regtypein (PG_FUNCTION_ARGS); +extern Datum regtypeout (PG_FUNCTION_ARGS); +extern Datum pg_stat_clear_snapshot (PG_FUNCTION_ARGS); +extern Datum pg_get_function_identity_arguments (PG_FUNCTION_ARGS); +extern Datum fmgr_internal_validator (PG_FUNCTION_ARGS); +extern Datum fmgr_c_validator (PG_FUNCTION_ARGS); +extern Datum fmgr_sql_validator (PG_FUNCTION_ARGS); +extern Datum has_database_privilege_name_name (PG_FUNCTION_ARGS); +extern Datum has_database_privilege_name_id (PG_FUNCTION_ARGS); +extern Datum has_database_privilege_id_name (PG_FUNCTION_ARGS); +extern Datum has_database_privilege_id_id (PG_FUNCTION_ARGS); +extern Datum has_database_privilege_name (PG_FUNCTION_ARGS); +extern Datum has_database_privilege_id (PG_FUNCTION_ARGS); +extern Datum has_function_privilege_name_name (PG_FUNCTION_ARGS); +extern Datum has_function_privilege_name_id (PG_FUNCTION_ARGS); +extern Datum has_function_privilege_id_name (PG_FUNCTION_ARGS); +extern Datum has_function_privilege_id_id (PG_FUNCTION_ARGS); +extern Datum has_function_privilege_name (PG_FUNCTION_ARGS); +extern Datum has_function_privilege_id (PG_FUNCTION_ARGS); +extern Datum has_language_privilege_name_name (PG_FUNCTION_ARGS); +extern Datum has_language_privilege_name_id (PG_FUNCTION_ARGS); +extern Datum has_language_privilege_id_name (PG_FUNCTION_ARGS); +extern Datum has_language_privilege_id_id (PG_FUNCTION_ARGS); +extern Datum has_language_privilege_name (PG_FUNCTION_ARGS); +extern Datum has_language_privilege_id (PG_FUNCTION_ARGS); +extern Datum has_schema_privilege_name_name (PG_FUNCTION_ARGS); +extern Datum has_schema_privilege_name_id (PG_FUNCTION_ARGS); +extern Datum has_schema_privilege_id_name (PG_FUNCTION_ARGS); +extern Datum has_schema_privilege_id_id (PG_FUNCTION_ARGS); +extern Datum has_schema_privilege_name (PG_FUNCTION_ARGS); +extern Datum has_schema_privilege_id (PG_FUNCTION_ARGS); +extern Datum pg_stat_reset (PG_FUNCTION_ARGS); +extern Datum textregexreplace_noopt (PG_FUNCTION_ARGS); +extern Datum textregexreplace (PG_FUNCTION_ARGS); +extern Datum pg_total_relation_size (PG_FUNCTION_ARGS); +extern Datum pg_size_pretty (PG_FUNCTION_ARGS); +extern Datum pg_options_to_table (PG_FUNCTION_ARGS); +extern Datum record_in (PG_FUNCTION_ARGS); +extern Datum record_out (PG_FUNCTION_ARGS); +extern Datum cstring_in (PG_FUNCTION_ARGS); +extern Datum cstring_out (PG_FUNCTION_ARGS); +extern Datum any_in (PG_FUNCTION_ARGS); +extern Datum any_out (PG_FUNCTION_ARGS); +extern Datum anyarray_in (PG_FUNCTION_ARGS); +extern Datum anyarray_out (PG_FUNCTION_ARGS); +extern Datum void_in (PG_FUNCTION_ARGS); +extern Datum void_out (PG_FUNCTION_ARGS); +extern Datum trigger_in (PG_FUNCTION_ARGS); +extern Datum trigger_out (PG_FUNCTION_ARGS); +extern Datum language_handler_in (PG_FUNCTION_ARGS); +extern Datum language_handler_out (PG_FUNCTION_ARGS); +extern Datum internal_in (PG_FUNCTION_ARGS); +extern Datum internal_out (PG_FUNCTION_ARGS); +extern Datum opaque_in (PG_FUNCTION_ARGS); +extern Datum opaque_out (PG_FUNCTION_ARGS); +extern Datum dceil (PG_FUNCTION_ARGS); +extern Datum dfloor (PG_FUNCTION_ARGS); +extern Datum dsign (PG_FUNCTION_ARGS); +extern Datum md5_text (PG_FUNCTION_ARGS); +extern Datum anyelement_in (PG_FUNCTION_ARGS); +extern Datum anyelement_out (PG_FUNCTION_ARGS); +extern Datum postgresql_fdw_validator (PG_FUNCTION_ARGS); +extern Datum pg_encoding_max_length_sql (PG_FUNCTION_ARGS); +extern Datum md5_bytea (PG_FUNCTION_ARGS); +extern Datum pg_tablespace_size_oid (PG_FUNCTION_ARGS); +extern Datum pg_tablespace_size_name (PG_FUNCTION_ARGS); +extern Datum pg_database_size_oid (PG_FUNCTION_ARGS); +extern Datum array_unnest (PG_FUNCTION_ARGS); +extern Datum pg_relation_size (PG_FUNCTION_ARGS); +extern Datum array_agg_transfn (PG_FUNCTION_ARGS); +extern Datum array_agg_finalfn (PG_FUNCTION_ARGS); +extern Datum date_lt_timestamp (PG_FUNCTION_ARGS); +extern Datum date_le_timestamp (PG_FUNCTION_ARGS); +extern Datum date_eq_timestamp (PG_FUNCTION_ARGS); +extern Datum date_gt_timestamp (PG_FUNCTION_ARGS); +extern Datum date_ge_timestamp (PG_FUNCTION_ARGS); +extern Datum date_ne_timestamp (PG_FUNCTION_ARGS); +extern Datum date_cmp_timestamp (PG_FUNCTION_ARGS); +extern Datum date_lt_timestamptz (PG_FUNCTION_ARGS); +extern Datum date_le_timestamptz (PG_FUNCTION_ARGS); +extern Datum date_eq_timestamptz (PG_FUNCTION_ARGS); +extern Datum date_gt_timestamptz (PG_FUNCTION_ARGS); +extern Datum date_ge_timestamptz (PG_FUNCTION_ARGS); +extern Datum date_ne_timestamptz (PG_FUNCTION_ARGS); +extern Datum date_cmp_timestamptz (PG_FUNCTION_ARGS); +extern Datum timestamp_lt_date (PG_FUNCTION_ARGS); +extern Datum timestamp_le_date (PG_FUNCTION_ARGS); +extern Datum timestamp_eq_date (PG_FUNCTION_ARGS); +extern Datum timestamp_gt_date (PG_FUNCTION_ARGS); +extern Datum timestamp_ge_date (PG_FUNCTION_ARGS); +extern Datum timestamp_ne_date (PG_FUNCTION_ARGS); +extern Datum timestamp_cmp_date (PG_FUNCTION_ARGS); +extern Datum timestamptz_lt_date (PG_FUNCTION_ARGS); +extern Datum timestamptz_le_date (PG_FUNCTION_ARGS); +extern Datum timestamptz_eq_date (PG_FUNCTION_ARGS); +extern Datum timestamptz_gt_date (PG_FUNCTION_ARGS); +extern Datum timestamptz_ge_date (PG_FUNCTION_ARGS); +extern Datum timestamptz_ne_date (PG_FUNCTION_ARGS); +extern Datum timestamptz_cmp_date (PG_FUNCTION_ARGS); +extern Datum has_tablespace_privilege_name_name (PG_FUNCTION_ARGS); +extern Datum has_tablespace_privilege_name_id (PG_FUNCTION_ARGS); +extern Datum has_tablespace_privilege_id_name (PG_FUNCTION_ARGS); +extern Datum has_tablespace_privilege_id_id (PG_FUNCTION_ARGS); +extern Datum has_tablespace_privilege_name (PG_FUNCTION_ARGS); +extern Datum has_tablespace_privilege_id (PG_FUNCTION_ARGS); +extern Datum shell_in (PG_FUNCTION_ARGS); +extern Datum shell_out (PG_FUNCTION_ARGS); +extern Datum array_recv (PG_FUNCTION_ARGS); +extern Datum array_send (PG_FUNCTION_ARGS); +extern Datum record_recv (PG_FUNCTION_ARGS); +extern Datum record_send (PG_FUNCTION_ARGS); +extern Datum int2recv (PG_FUNCTION_ARGS); +extern Datum int2send (PG_FUNCTION_ARGS); +extern Datum int4recv (PG_FUNCTION_ARGS); +extern Datum int4send (PG_FUNCTION_ARGS); +extern Datum int8recv (PG_FUNCTION_ARGS); +extern Datum int8send (PG_FUNCTION_ARGS); +extern Datum int2vectorrecv (PG_FUNCTION_ARGS); +extern Datum int2vectorsend (PG_FUNCTION_ARGS); +extern Datum bytearecv (PG_FUNCTION_ARGS); +extern Datum byteasend (PG_FUNCTION_ARGS); +extern Datum textrecv (PG_FUNCTION_ARGS); +extern Datum textsend (PG_FUNCTION_ARGS); +extern Datum unknownrecv (PG_FUNCTION_ARGS); +extern Datum unknownsend (PG_FUNCTION_ARGS); +extern Datum oidrecv (PG_FUNCTION_ARGS); +extern Datum oidsend (PG_FUNCTION_ARGS); +extern Datum oidvectorrecv (PG_FUNCTION_ARGS); +extern Datum oidvectorsend (PG_FUNCTION_ARGS); +extern Datum namerecv (PG_FUNCTION_ARGS); +extern Datum namesend (PG_FUNCTION_ARGS); +extern Datum float4recv (PG_FUNCTION_ARGS); +extern Datum float4send (PG_FUNCTION_ARGS); +extern Datum float8recv (PG_FUNCTION_ARGS); +extern Datum float8send (PG_FUNCTION_ARGS); +extern Datum point_recv (PG_FUNCTION_ARGS); +extern Datum point_send (PG_FUNCTION_ARGS); +extern Datum bpcharrecv (PG_FUNCTION_ARGS); +extern Datum bpcharsend (PG_FUNCTION_ARGS); +extern Datum varcharrecv (PG_FUNCTION_ARGS); +extern Datum varcharsend (PG_FUNCTION_ARGS); +extern Datum charrecv (PG_FUNCTION_ARGS); +extern Datum charsend (PG_FUNCTION_ARGS); +extern Datum boolrecv (PG_FUNCTION_ARGS); +extern Datum boolsend (PG_FUNCTION_ARGS); +extern Datum tidrecv (PG_FUNCTION_ARGS); +extern Datum tidsend (PG_FUNCTION_ARGS); +extern Datum xidrecv (PG_FUNCTION_ARGS); +extern Datum xidsend (PG_FUNCTION_ARGS); +extern Datum cidrecv (PG_FUNCTION_ARGS); +extern Datum cidsend (PG_FUNCTION_ARGS); +extern Datum regprocrecv (PG_FUNCTION_ARGS); +extern Datum regprocsend (PG_FUNCTION_ARGS); +extern Datum regprocedurerecv (PG_FUNCTION_ARGS); +extern Datum regproceduresend (PG_FUNCTION_ARGS); +extern Datum regoperrecv (PG_FUNCTION_ARGS); +extern Datum regopersend (PG_FUNCTION_ARGS); +extern Datum regoperatorrecv (PG_FUNCTION_ARGS); +extern Datum regoperatorsend (PG_FUNCTION_ARGS); +extern Datum regclassrecv (PG_FUNCTION_ARGS); +extern Datum regclasssend (PG_FUNCTION_ARGS); +extern Datum regtyperecv (PG_FUNCTION_ARGS); +extern Datum regtypesend (PG_FUNCTION_ARGS); +extern Datum bit_recv (PG_FUNCTION_ARGS); +extern Datum bit_send (PG_FUNCTION_ARGS); +extern Datum varbit_recv (PG_FUNCTION_ARGS); +extern Datum varbit_send (PG_FUNCTION_ARGS); +extern Datum numeric_recv (PG_FUNCTION_ARGS); +extern Datum numeric_send (PG_FUNCTION_ARGS); +extern Datum abstimerecv (PG_FUNCTION_ARGS); +extern Datum abstimesend (PG_FUNCTION_ARGS); +extern Datum reltimerecv (PG_FUNCTION_ARGS); +extern Datum reltimesend (PG_FUNCTION_ARGS); +extern Datum tintervalrecv (PG_FUNCTION_ARGS); +extern Datum tintervalsend (PG_FUNCTION_ARGS); +extern Datum date_recv (PG_FUNCTION_ARGS); +extern Datum date_send (PG_FUNCTION_ARGS); +extern Datum time_recv (PG_FUNCTION_ARGS); +extern Datum time_send (PG_FUNCTION_ARGS); +extern Datum timetz_recv (PG_FUNCTION_ARGS); +extern Datum timetz_send (PG_FUNCTION_ARGS); +extern Datum timestamp_recv (PG_FUNCTION_ARGS); +extern Datum timestamp_send (PG_FUNCTION_ARGS); +extern Datum timestamptz_recv (PG_FUNCTION_ARGS); +extern Datum timestamptz_send (PG_FUNCTION_ARGS); +extern Datum interval_recv (PG_FUNCTION_ARGS); +extern Datum interval_send (PG_FUNCTION_ARGS); +extern Datum lseg_recv (PG_FUNCTION_ARGS); +extern Datum lseg_send (PG_FUNCTION_ARGS); +extern Datum path_recv (PG_FUNCTION_ARGS); +extern Datum path_send (PG_FUNCTION_ARGS); +extern Datum box_recv (PG_FUNCTION_ARGS); +extern Datum box_send (PG_FUNCTION_ARGS); +extern Datum poly_recv (PG_FUNCTION_ARGS); +extern Datum poly_send (PG_FUNCTION_ARGS); +extern Datum line_recv (PG_FUNCTION_ARGS); +extern Datum line_send (PG_FUNCTION_ARGS); +extern Datum circle_recv (PG_FUNCTION_ARGS); +extern Datum circle_send (PG_FUNCTION_ARGS); +extern Datum cash_recv (PG_FUNCTION_ARGS); +extern Datum cash_send (PG_FUNCTION_ARGS); +extern Datum macaddr_recv (PG_FUNCTION_ARGS); +extern Datum macaddr_send (PG_FUNCTION_ARGS); +extern Datum inet_recv (PG_FUNCTION_ARGS); +extern Datum inet_send (PG_FUNCTION_ARGS); +extern Datum cidr_recv (PG_FUNCTION_ARGS); +extern Datum cidr_send (PG_FUNCTION_ARGS); +extern Datum cstring_recv (PG_FUNCTION_ARGS); +extern Datum cstring_send (PG_FUNCTION_ARGS); +extern Datum anyarray_recv (PG_FUNCTION_ARGS); +extern Datum anyarray_send (PG_FUNCTION_ARGS); +extern Datum pg_get_ruledef_ext (PG_FUNCTION_ARGS); +extern Datum pg_get_viewdef_name_ext (PG_FUNCTION_ARGS); +extern Datum pg_get_viewdef_ext (PG_FUNCTION_ARGS); +extern Datum pg_get_indexdef_ext (PG_FUNCTION_ARGS); +extern Datum pg_get_constraintdef_ext (PG_FUNCTION_ARGS); +extern Datum pg_get_expr_ext (PG_FUNCTION_ARGS); +extern Datum pg_prepared_statement (PG_FUNCTION_ARGS); +extern Datum pg_cursor (PG_FUNCTION_ARGS); +extern Datum float8_var_pop (PG_FUNCTION_ARGS); +extern Datum float8_stddev_pop (PG_FUNCTION_ARGS); +extern Datum numeric_var_pop (PG_FUNCTION_ARGS); +extern Datum booland_statefunc (PG_FUNCTION_ARGS); +extern Datum boolor_statefunc (PG_FUNCTION_ARGS); +extern Datum timestamp_lt_timestamptz (PG_FUNCTION_ARGS); +extern Datum timestamp_le_timestamptz (PG_FUNCTION_ARGS); +extern Datum timestamp_eq_timestamptz (PG_FUNCTION_ARGS); +extern Datum timestamp_gt_timestamptz (PG_FUNCTION_ARGS); +extern Datum timestamp_ge_timestamptz (PG_FUNCTION_ARGS); +extern Datum timestamp_ne_timestamptz (PG_FUNCTION_ARGS); +extern Datum timestamp_cmp_timestamptz (PG_FUNCTION_ARGS); +extern Datum timestamptz_lt_timestamp (PG_FUNCTION_ARGS); +extern Datum timestamptz_le_timestamp (PG_FUNCTION_ARGS); +extern Datum timestamptz_eq_timestamp (PG_FUNCTION_ARGS); +extern Datum timestamptz_gt_timestamp (PG_FUNCTION_ARGS); +extern Datum timestamptz_ge_timestamp (PG_FUNCTION_ARGS); +extern Datum timestamptz_ne_timestamp (PG_FUNCTION_ARGS); +extern Datum timestamptz_cmp_timestamp (PG_FUNCTION_ARGS); +extern Datum pg_tablespace_databases (PG_FUNCTION_ARGS); +extern Datum int4_bool (PG_FUNCTION_ARGS); +extern Datum bool_int4 (PG_FUNCTION_ARGS); +extern Datum lastval (PG_FUNCTION_ARGS); +extern Datum pg_postmaster_start_time (PG_FUNCTION_ARGS); +extern Datum gistvacuumcleanup (PG_FUNCTION_ARGS); +extern Datum box_below (PG_FUNCTION_ARGS); +extern Datum box_overbelow (PG_FUNCTION_ARGS); +extern Datum box_overabove (PG_FUNCTION_ARGS); +extern Datum box_above (PG_FUNCTION_ARGS); +extern Datum poly_below (PG_FUNCTION_ARGS); +extern Datum poly_overbelow (PG_FUNCTION_ARGS); +extern Datum poly_overabove (PG_FUNCTION_ARGS); +extern Datum poly_above (PG_FUNCTION_ARGS); +extern Datum gist_box_consistent (PG_FUNCTION_ARGS); +extern Datum gist_box_compress (PG_FUNCTION_ARGS); +extern Datum gist_box_decompress (PG_FUNCTION_ARGS); +extern Datum gist_box_penalty (PG_FUNCTION_ARGS); +extern Datum gist_box_picksplit (PG_FUNCTION_ARGS); +extern Datum gist_box_union (PG_FUNCTION_ARGS); +extern Datum gist_box_same (PG_FUNCTION_ARGS); +extern Datum gist_poly_consistent (PG_FUNCTION_ARGS); +extern Datum gist_poly_compress (PG_FUNCTION_ARGS); +extern Datum circle_overbelow (PG_FUNCTION_ARGS); +extern Datum circle_overabove (PG_FUNCTION_ARGS); +extern Datum gist_circle_consistent (PG_FUNCTION_ARGS); +extern Datum gist_circle_compress (PG_FUNCTION_ARGS); +extern Datum numeric_stddev_pop (PG_FUNCTION_ARGS); +extern Datum domain_in (PG_FUNCTION_ARGS); +extern Datum domain_recv (PG_FUNCTION_ARGS); +extern Datum pg_timezone_abbrevs (PG_FUNCTION_ARGS); +extern Datum xmlexists (PG_FUNCTION_ARGS); +extern Datum pg_reload_conf (PG_FUNCTION_ARGS); +extern Datum pg_rotate_logfile (PG_FUNCTION_ARGS); +extern Datum pg_stat_file (PG_FUNCTION_ARGS); +extern Datum pg_read_file (PG_FUNCTION_ARGS); +extern Datum pg_ls_dir (PG_FUNCTION_ARGS); +extern Datum pg_sleep (PG_FUNCTION_ARGS); +extern Datum inetnot (PG_FUNCTION_ARGS); +extern Datum inetand (PG_FUNCTION_ARGS); +extern Datum inetor (PG_FUNCTION_ARGS); +extern Datum inetpl (PG_FUNCTION_ARGS); +extern Datum inetmi_int8 (PG_FUNCTION_ARGS); +extern Datum inetmi (PG_FUNCTION_ARGS); +extern Datum statement_timestamp (PG_FUNCTION_ARGS); +extern Datum clock_timestamp (PG_FUNCTION_ARGS); +extern Datum gin_cmp_prefix (PG_FUNCTION_ARGS); +extern Datum pg_has_role_name_name (PG_FUNCTION_ARGS); +extern Datum pg_has_role_name_id (PG_FUNCTION_ARGS); +extern Datum pg_has_role_id_name (PG_FUNCTION_ARGS); +extern Datum pg_has_role_id_id (PG_FUNCTION_ARGS); +extern Datum pg_has_role_name (PG_FUNCTION_ARGS); +extern Datum pg_has_role_id (PG_FUNCTION_ARGS); +extern Datum interval_justify_interval (PG_FUNCTION_ARGS); +extern Datum pg_get_triggerdef_ext (PG_FUNCTION_ARGS); +extern Datum gingetbitmap (PG_FUNCTION_ARGS); +extern Datum gininsert (PG_FUNCTION_ARGS); +extern Datum ginbeginscan (PG_FUNCTION_ARGS); +extern Datum ginrescan (PG_FUNCTION_ARGS); +extern Datum ginendscan (PG_FUNCTION_ARGS); +extern Datum ginmarkpos (PG_FUNCTION_ARGS); +extern Datum ginrestrpos (PG_FUNCTION_ARGS); +extern Datum ginbuild (PG_FUNCTION_ARGS); +extern Datum ginbulkdelete (PG_FUNCTION_ARGS); +extern Datum ginvacuumcleanup (PG_FUNCTION_ARGS); +extern Datum gincostestimate (PG_FUNCTION_ARGS); +extern Datum ginarrayextract (PG_FUNCTION_ARGS); +extern Datum ginarrayconsistent (PG_FUNCTION_ARGS); +extern Datum int8_avg_accum (PG_FUNCTION_ARGS); +extern Datum arrayoverlap (PG_FUNCTION_ARGS); +extern Datum arraycontains (PG_FUNCTION_ARGS); +extern Datum arraycontained (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_db_tuples_returned (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_db_tuples_fetched (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_db_tuples_inserted (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_db_tuples_updated (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_db_tuples_deleted (PG_FUNCTION_ARGS); +extern Datum regexp_matches_no_flags (PG_FUNCTION_ARGS); +extern Datum regexp_matches (PG_FUNCTION_ARGS); +extern Datum regexp_split_to_table_no_flags (PG_FUNCTION_ARGS); +extern Datum regexp_split_to_table (PG_FUNCTION_ARGS); +extern Datum regexp_split_to_array_no_flags (PG_FUNCTION_ARGS); +extern Datum regexp_split_to_array (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_bgwriter_timed_checkpoints (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_bgwriter_requested_checkpoints (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_bgwriter_buf_written_checkpoints (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_bgwriter_buf_written_clean (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_bgwriter_maxwritten_clean (PG_FUNCTION_ARGS); +extern Datum ginqueryarrayextract (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_buf_written_backend (PG_FUNCTION_ARGS); +extern Datum anynonarray_in (PG_FUNCTION_ARGS); +extern Datum anynonarray_out (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_last_vacuum_time (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_last_autovacuum_time (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_last_analyze_time (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_last_autoanalyze_time (PG_FUNCTION_ARGS); +extern Datum btoptions (PG_FUNCTION_ARGS); +extern Datum hashoptions (PG_FUNCTION_ARGS); +extern Datum gistoptions (PG_FUNCTION_ARGS); +extern Datum ginoptions (PG_FUNCTION_ARGS); +extern Datum tidgt (PG_FUNCTION_ARGS); +extern Datum tidlt (PG_FUNCTION_ARGS); +extern Datum tidge (PG_FUNCTION_ARGS); +extern Datum tidle (PG_FUNCTION_ARGS); +extern Datum bttidcmp (PG_FUNCTION_ARGS); +extern Datum tidlarger (PG_FUNCTION_ARGS); +extern Datum tidsmaller (PG_FUNCTION_ARGS); +extern Datum int8inc_any (PG_FUNCTION_ARGS); +extern Datum int8inc_float8_float8 (PG_FUNCTION_ARGS); +extern Datum float8_regr_accum (PG_FUNCTION_ARGS); +extern Datum float8_regr_sxx (PG_FUNCTION_ARGS); +extern Datum float8_regr_syy (PG_FUNCTION_ARGS); +extern Datum float8_regr_sxy (PG_FUNCTION_ARGS); +extern Datum float8_regr_avgx (PG_FUNCTION_ARGS); +extern Datum float8_regr_avgy (PG_FUNCTION_ARGS); +extern Datum float8_regr_r2 (PG_FUNCTION_ARGS); +extern Datum float8_regr_slope (PG_FUNCTION_ARGS); +extern Datum float8_regr_intercept (PG_FUNCTION_ARGS); +extern Datum float8_covar_pop (PG_FUNCTION_ARGS); +extern Datum float8_covar_samp (PG_FUNCTION_ARGS); +extern Datum float8_corr (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_db_blk_read_time (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_db_blk_write_time (PG_FUNCTION_ARGS); +extern Datum pg_switch_xlog (PG_FUNCTION_ARGS); +extern Datum pg_current_xlog_location (PG_FUNCTION_ARGS); +extern Datum pg_xlogfile_name_offset (PG_FUNCTION_ARGS); +extern Datum pg_xlogfile_name (PG_FUNCTION_ARGS); +extern Datum pg_current_xlog_insert_location (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_backend_waiting (PG_FUNCTION_ARGS); +extern Datum pg_my_temp_schema (PG_FUNCTION_ARGS); +extern Datum pg_is_other_temp_schema (PG_FUNCTION_ARGS); +extern Datum pg_timezone_names (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_backend_xact_start (PG_FUNCTION_ARGS); +extern Datum numeric_avg_accum (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_buf_alloc (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_live_tuples (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_dead_tuples (PG_FUNCTION_ARGS); +extern Datum pg_advisory_lock_int8 (PG_FUNCTION_ARGS); +extern Datum pg_advisory_lock_shared_int8 (PG_FUNCTION_ARGS); +extern Datum pg_try_advisory_lock_int8 (PG_FUNCTION_ARGS); +extern Datum pg_try_advisory_lock_shared_int8 (PG_FUNCTION_ARGS); +extern Datum pg_advisory_unlock_int8 (PG_FUNCTION_ARGS); +extern Datum pg_advisory_unlock_shared_int8 (PG_FUNCTION_ARGS); +extern Datum pg_advisory_lock_int4 (PG_FUNCTION_ARGS); +extern Datum pg_advisory_lock_shared_int4 (PG_FUNCTION_ARGS); +extern Datum pg_try_advisory_lock_int4 (PG_FUNCTION_ARGS); +extern Datum pg_try_advisory_lock_shared_int4 (PG_FUNCTION_ARGS); +extern Datum pg_advisory_unlock_int4 (PG_FUNCTION_ARGS); +extern Datum pg_advisory_unlock_shared_int4 (PG_FUNCTION_ARGS); +extern Datum pg_advisory_unlock_all (PG_FUNCTION_ARGS); +extern Datum xml_in (PG_FUNCTION_ARGS); +extern Datum xml_out (PG_FUNCTION_ARGS); +extern Datum xmlcomment (PG_FUNCTION_ARGS); +extern Datum texttoxml (PG_FUNCTION_ARGS); +extern Datum xmlvalidate (PG_FUNCTION_ARGS); +extern Datum xml_recv (PG_FUNCTION_ARGS); +extern Datum xml_send (PG_FUNCTION_ARGS); +extern Datum xmlconcat2 (PG_FUNCTION_ARGS); +extern Datum varbittypmodin (PG_FUNCTION_ARGS); +extern Datum intervaltypmodin (PG_FUNCTION_ARGS); +extern Datum intervaltypmodout (PG_FUNCTION_ARGS); +extern Datum timestamptypmodin (PG_FUNCTION_ARGS); +extern Datum timestamptypmodout (PG_FUNCTION_ARGS); +extern Datum timestamptztypmodin (PG_FUNCTION_ARGS); +extern Datum timestamptztypmodout (PG_FUNCTION_ARGS); +extern Datum timetypmodin (PG_FUNCTION_ARGS); +extern Datum timetypmodout (PG_FUNCTION_ARGS); +extern Datum timetztypmodin (PG_FUNCTION_ARGS); +extern Datum timetztypmodout (PG_FUNCTION_ARGS); +extern Datum bpchartypmodin (PG_FUNCTION_ARGS); +extern Datum bpchartypmodout (PG_FUNCTION_ARGS); +extern Datum varchartypmodin (PG_FUNCTION_ARGS); +extern Datum varchartypmodout (PG_FUNCTION_ARGS); +extern Datum numerictypmodin (PG_FUNCTION_ARGS); +extern Datum numerictypmodout (PG_FUNCTION_ARGS); +extern Datum bittypmodin (PG_FUNCTION_ARGS); +extern Datum bittypmodout (PG_FUNCTION_ARGS); +extern Datum varbittypmodout (PG_FUNCTION_ARGS); +extern Datum xmltotext (PG_FUNCTION_ARGS); +extern Datum table_to_xml (PG_FUNCTION_ARGS); +extern Datum query_to_xml (PG_FUNCTION_ARGS); +extern Datum cursor_to_xml (PG_FUNCTION_ARGS); +extern Datum table_to_xmlschema (PG_FUNCTION_ARGS); +extern Datum query_to_xmlschema (PG_FUNCTION_ARGS); +extern Datum cursor_to_xmlschema (PG_FUNCTION_ARGS); +extern Datum table_to_xml_and_xmlschema (PG_FUNCTION_ARGS); +extern Datum query_to_xml_and_xmlschema (PG_FUNCTION_ARGS); +extern Datum xpath (PG_FUNCTION_ARGS); +extern Datum schema_to_xml (PG_FUNCTION_ARGS); +extern Datum schema_to_xmlschema (PG_FUNCTION_ARGS); +extern Datum schema_to_xml_and_xmlschema (PG_FUNCTION_ARGS); +extern Datum database_to_xml (PG_FUNCTION_ARGS); +extern Datum database_to_xmlschema (PG_FUNCTION_ARGS); +extern Datum database_to_xml_and_xmlschema (PG_FUNCTION_ARGS); +extern Datum txid_snapshot_in (PG_FUNCTION_ARGS); +extern Datum txid_snapshot_out (PG_FUNCTION_ARGS); +extern Datum txid_snapshot_recv (PG_FUNCTION_ARGS); +extern Datum txid_snapshot_send (PG_FUNCTION_ARGS); +extern Datum txid_current (PG_FUNCTION_ARGS); +extern Datum txid_current_snapshot (PG_FUNCTION_ARGS); +extern Datum txid_snapshot_xmin (PG_FUNCTION_ARGS); +extern Datum txid_snapshot_xmax (PG_FUNCTION_ARGS); +extern Datum txid_snapshot_xip (PG_FUNCTION_ARGS); +extern Datum txid_visible_in_snapshot (PG_FUNCTION_ARGS); +extern Datum uuid_in (PG_FUNCTION_ARGS); +extern Datum uuid_out (PG_FUNCTION_ARGS); +extern Datum uuid_lt (PG_FUNCTION_ARGS); +extern Datum uuid_le (PG_FUNCTION_ARGS); +extern Datum uuid_eq (PG_FUNCTION_ARGS); +extern Datum uuid_ge (PG_FUNCTION_ARGS); +extern Datum uuid_gt (PG_FUNCTION_ARGS); +extern Datum uuid_ne (PG_FUNCTION_ARGS); +extern Datum uuid_cmp (PG_FUNCTION_ARGS); +extern Datum uuid_recv (PG_FUNCTION_ARGS); +extern Datum uuid_send (PG_FUNCTION_ARGS); +extern Datum uuid_hash (PG_FUNCTION_ARGS); +extern Datum booltext (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_function_calls (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_function_total_time (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_function_self_time (PG_FUNCTION_ARGS); +extern Datum record_eq (PG_FUNCTION_ARGS); +extern Datum record_ne (PG_FUNCTION_ARGS); +extern Datum record_lt (PG_FUNCTION_ARGS); +extern Datum record_gt (PG_FUNCTION_ARGS); +extern Datum record_le (PG_FUNCTION_ARGS); +extern Datum record_ge (PG_FUNCTION_ARGS); +extern Datum btrecordcmp (PG_FUNCTION_ARGS); +extern Datum pg_table_size (PG_FUNCTION_ARGS); +extern Datum pg_indexes_size (PG_FUNCTION_ARGS); +extern Datum pg_relation_filenode (PG_FUNCTION_ARGS); +extern Datum has_foreign_data_wrapper_privilege_name_name (PG_FUNCTION_ARGS); +extern Datum has_foreign_data_wrapper_privilege_name_id (PG_FUNCTION_ARGS); +extern Datum has_foreign_data_wrapper_privilege_id_name (PG_FUNCTION_ARGS); +extern Datum has_foreign_data_wrapper_privilege_id_id (PG_FUNCTION_ARGS); +extern Datum has_foreign_data_wrapper_privilege_name (PG_FUNCTION_ARGS); +extern Datum has_foreign_data_wrapper_privilege_id (PG_FUNCTION_ARGS); +extern Datum has_server_privilege_name_name (PG_FUNCTION_ARGS); +extern Datum has_server_privilege_name_id (PG_FUNCTION_ARGS); +extern Datum has_server_privilege_id_name (PG_FUNCTION_ARGS); +extern Datum has_server_privilege_id_id (PG_FUNCTION_ARGS); +extern Datum has_server_privilege_name (PG_FUNCTION_ARGS); +extern Datum has_server_privilege_id (PG_FUNCTION_ARGS); +extern Datum has_column_privilege_name_name_name (PG_FUNCTION_ARGS); +extern Datum has_column_privilege_name_name_attnum (PG_FUNCTION_ARGS); +extern Datum has_column_privilege_name_id_name (PG_FUNCTION_ARGS); +extern Datum has_column_privilege_name_id_attnum (PG_FUNCTION_ARGS); +extern Datum has_column_privilege_id_name_name (PG_FUNCTION_ARGS); +extern Datum has_column_privilege_id_name_attnum (PG_FUNCTION_ARGS); +extern Datum has_column_privilege_id_id_name (PG_FUNCTION_ARGS); +extern Datum has_column_privilege_id_id_attnum (PG_FUNCTION_ARGS); +extern Datum has_column_privilege_name_name (PG_FUNCTION_ARGS); +extern Datum has_column_privilege_name_attnum (PG_FUNCTION_ARGS); +extern Datum has_column_privilege_id_name (PG_FUNCTION_ARGS); +extern Datum has_column_privilege_id_attnum (PG_FUNCTION_ARGS); +extern Datum has_any_column_privilege_name_name (PG_FUNCTION_ARGS); +extern Datum has_any_column_privilege_name_id (PG_FUNCTION_ARGS); +extern Datum has_any_column_privilege_id_name (PG_FUNCTION_ARGS); +extern Datum has_any_column_privilege_id_id (PG_FUNCTION_ARGS); +extern Datum has_any_column_privilege_name (PG_FUNCTION_ARGS); +extern Datum has_any_column_privilege_id (PG_FUNCTION_ARGS); +extern Datum bitoverlay (PG_FUNCTION_ARGS); +extern Datum bitoverlay_no_len (PG_FUNCTION_ARGS); +extern Datum bitgetbit (PG_FUNCTION_ARGS); +extern Datum bitsetbit (PG_FUNCTION_ARGS); +extern Datum pg_relation_filepath (PG_FUNCTION_ARGS); +extern Datum pg_listening_channels (PG_FUNCTION_ARGS); +extern Datum pg_notify (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_xact_numscans (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_xact_tuples_returned (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_xact_tuples_fetched (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_xact_tuples_inserted (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_xact_tuples_updated (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_xact_tuples_deleted (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_xact_tuples_hot_updated (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_xact_blocks_fetched (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_xact_blocks_hit (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_xact_function_calls (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_xact_function_total_time (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_xact_function_self_time (PG_FUNCTION_ARGS); +extern Datum xpath_exists (PG_FUNCTION_ARGS); +extern Datum xml_is_well_formed (PG_FUNCTION_ARGS); +extern Datum xml_is_well_formed_document (PG_FUNCTION_ARGS); +extern Datum xml_is_well_formed_content (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_vacuum_count (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_autovacuum_count (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_analyze_count (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_autoanalyze_count (PG_FUNCTION_ARGS); +extern Datum text_concat (PG_FUNCTION_ARGS); +extern Datum text_concat_ws (PG_FUNCTION_ARGS); +extern Datum text_left (PG_FUNCTION_ARGS); +extern Datum text_right (PG_FUNCTION_ARGS); +extern Datum text_reverse (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_buf_fsync_backend (PG_FUNCTION_ARGS); +extern Datum gist_point_distance (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_db_conflict_tablespace (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_db_conflict_lock (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_db_conflict_snapshot (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_db_conflict_bufferpin (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_db_conflict_startup_deadlock (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_db_conflict_all (PG_FUNCTION_ARGS); +extern Datum pg_xlog_replay_pause (PG_FUNCTION_ARGS); +extern Datum pg_xlog_replay_resume (PG_FUNCTION_ARGS); +extern Datum pg_is_xlog_replay_paused (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_db_stat_reset_time (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_bgwriter_stat_reset_time (PG_FUNCTION_ARGS); +extern Datum ginarrayextract_2args (PG_FUNCTION_ARGS); +extern Datum gin_extract_tsvector_2args (PG_FUNCTION_ARGS); +extern Datum pg_sequence_parameters (PG_FUNCTION_ARGS); +extern Datum pg_available_extensions (PG_FUNCTION_ARGS); +extern Datum pg_available_extension_versions (PG_FUNCTION_ARGS); +extern Datum pg_extension_update_paths (PG_FUNCTION_ARGS); +extern Datum pg_extension_config_dump (PG_FUNCTION_ARGS); +extern Datum gin_extract_tsquery_5args (PG_FUNCTION_ARGS); +extern Datum gin_tsquery_consistent_6args (PG_FUNCTION_ARGS); +extern Datum pg_advisory_xact_lock_int8 (PG_FUNCTION_ARGS); +extern Datum pg_advisory_xact_lock_shared_int8 (PG_FUNCTION_ARGS); +extern Datum pg_try_advisory_xact_lock_int8 (PG_FUNCTION_ARGS); +extern Datum pg_try_advisory_xact_lock_shared_int8 (PG_FUNCTION_ARGS); +extern Datum pg_advisory_xact_lock_int4 (PG_FUNCTION_ARGS); +extern Datum pg_advisory_xact_lock_shared_int4 (PG_FUNCTION_ARGS); +extern Datum pg_try_advisory_xact_lock_int4 (PG_FUNCTION_ARGS); +extern Datum pg_try_advisory_xact_lock_shared_int4 (PG_FUNCTION_ARGS); +extern Datum varchar_transform (PG_FUNCTION_ARGS); +extern Datum pg_create_restore_point (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_wal_senders (PG_FUNCTION_ARGS); +extern Datum window_row_number (PG_FUNCTION_ARGS); +extern Datum window_rank (PG_FUNCTION_ARGS); +extern Datum window_dense_rank (PG_FUNCTION_ARGS); +extern Datum window_percent_rank (PG_FUNCTION_ARGS); +extern Datum window_cume_dist (PG_FUNCTION_ARGS); +extern Datum window_ntile (PG_FUNCTION_ARGS); +extern Datum window_lag (PG_FUNCTION_ARGS); +extern Datum window_lag_with_offset (PG_FUNCTION_ARGS); +extern Datum window_lag_with_offset_and_default (PG_FUNCTION_ARGS); +extern Datum window_lead (PG_FUNCTION_ARGS); +extern Datum window_lead_with_offset (PG_FUNCTION_ARGS); +extern Datum window_lead_with_offset_and_default (PG_FUNCTION_ARGS); +extern Datum window_first_value (PG_FUNCTION_ARGS); +extern Datum window_last_value (PG_FUNCTION_ARGS); +extern Datum window_nth_value (PG_FUNCTION_ARGS); +extern Datum fdw_handler_in (PG_FUNCTION_ARGS); +extern Datum fdw_handler_out (PG_FUNCTION_ARGS); +extern Datum void_recv (PG_FUNCTION_ARGS); +extern Datum void_send (PG_FUNCTION_ARGS); +extern Datum btint2sortsupport (PG_FUNCTION_ARGS); +extern Datum btint4sortsupport (PG_FUNCTION_ARGS); +extern Datum btint8sortsupport (PG_FUNCTION_ARGS); +extern Datum btfloat4sortsupport (PG_FUNCTION_ARGS); +extern Datum btfloat8sortsupport (PG_FUNCTION_ARGS); +extern Datum btoidsortsupport (PG_FUNCTION_ARGS); +extern Datum btnamesortsupport (PG_FUNCTION_ARGS); +extern Datum date_sortsupport (PG_FUNCTION_ARGS); +extern Datum timestamp_sortsupport (PG_FUNCTION_ARGS); +extern Datum has_type_privilege_name_name (PG_FUNCTION_ARGS); +extern Datum has_type_privilege_name_id (PG_FUNCTION_ARGS); +extern Datum has_type_privilege_id_name (PG_FUNCTION_ARGS); +extern Datum has_type_privilege_id_id (PG_FUNCTION_ARGS); +extern Datum has_type_privilege_name (PG_FUNCTION_ARGS); +extern Datum has_type_privilege_id (PG_FUNCTION_ARGS); +extern Datum macaddr_not (PG_FUNCTION_ARGS); +extern Datum macaddr_and (PG_FUNCTION_ARGS); +extern Datum macaddr_or (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_db_temp_files (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_db_temp_bytes (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_db_deadlocks (PG_FUNCTION_ARGS); +extern Datum array_to_json (PG_FUNCTION_ARGS); +extern Datum array_to_json_pretty (PG_FUNCTION_ARGS); +extern Datum row_to_json (PG_FUNCTION_ARGS); +extern Datum row_to_json_pretty (PG_FUNCTION_ARGS); +extern Datum numeric_transform (PG_FUNCTION_ARGS); +extern Datum varbit_transform (PG_FUNCTION_ARGS); +extern Datum pg_get_viewdef_wrap (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_checkpoint_write_time (PG_FUNCTION_ARGS); +extern Datum pg_stat_get_checkpoint_sync_time (PG_FUNCTION_ARGS); +extern Datum pg_collation_for (PG_FUNCTION_ARGS); +extern Datum pg_trigger_depth (PG_FUNCTION_ARGS); +extern Datum pg_xlog_location_diff (PG_FUNCTION_ARGS); +extern Datum pg_size_pretty_numeric (PG_FUNCTION_ARGS); +extern Datum anyenum_in (PG_FUNCTION_ARGS); +extern Datum anyenum_out (PG_FUNCTION_ARGS); +extern Datum enum_in (PG_FUNCTION_ARGS); +extern Datum enum_out (PG_FUNCTION_ARGS); +extern Datum enum_eq (PG_FUNCTION_ARGS); +extern Datum enum_ne (PG_FUNCTION_ARGS); +extern Datum enum_lt (PG_FUNCTION_ARGS); +extern Datum enum_gt (PG_FUNCTION_ARGS); +extern Datum enum_le (PG_FUNCTION_ARGS); +extern Datum enum_ge (PG_FUNCTION_ARGS); +extern Datum enum_cmp (PG_FUNCTION_ARGS); +extern Datum hashenum (PG_FUNCTION_ARGS); +extern Datum enum_smaller (PG_FUNCTION_ARGS); +extern Datum enum_larger (PG_FUNCTION_ARGS); +extern Datum enum_first (PG_FUNCTION_ARGS); +extern Datum enum_last (PG_FUNCTION_ARGS); +extern Datum enum_range_bounds (PG_FUNCTION_ARGS); +extern Datum enum_range_all (PG_FUNCTION_ARGS); +extern Datum enum_recv (PG_FUNCTION_ARGS); +extern Datum enum_send (PG_FUNCTION_ARGS); +extern Datum string_agg_transfn (PG_FUNCTION_ARGS); +extern Datum string_agg_finalfn (PG_FUNCTION_ARGS); +extern Datum pg_describe_object (PG_FUNCTION_ARGS); +extern Datum text_format (PG_FUNCTION_ARGS); +extern Datum text_format_nv (PG_FUNCTION_ARGS); +extern Datum bytea_string_agg_transfn (PG_FUNCTION_ARGS); +extern Datum bytea_string_agg_finalfn (PG_FUNCTION_ARGS); +extern Datum tsvectorin (PG_FUNCTION_ARGS); +extern Datum tsvectorout (PG_FUNCTION_ARGS); +extern Datum tsqueryin (PG_FUNCTION_ARGS); +extern Datum tsqueryout (PG_FUNCTION_ARGS); +extern Datum tsvector_lt (PG_FUNCTION_ARGS); +extern Datum tsvector_le (PG_FUNCTION_ARGS); +extern Datum tsvector_eq (PG_FUNCTION_ARGS); +extern Datum tsvector_ne (PG_FUNCTION_ARGS); +extern Datum tsvector_ge (PG_FUNCTION_ARGS); +extern Datum tsvector_gt (PG_FUNCTION_ARGS); +extern Datum tsvector_cmp (PG_FUNCTION_ARGS); +extern Datum tsvector_strip (PG_FUNCTION_ARGS); +extern Datum tsvector_setweight (PG_FUNCTION_ARGS); +extern Datum tsvector_concat (PG_FUNCTION_ARGS); +extern Datum ts_match_vq (PG_FUNCTION_ARGS); +extern Datum ts_match_qv (PG_FUNCTION_ARGS); +extern Datum tsvectorsend (PG_FUNCTION_ARGS); +extern Datum tsvectorrecv (PG_FUNCTION_ARGS); +extern Datum tsquerysend (PG_FUNCTION_ARGS); +extern Datum tsqueryrecv (PG_FUNCTION_ARGS); +extern Datum gtsvectorin (PG_FUNCTION_ARGS); +extern Datum gtsvectorout (PG_FUNCTION_ARGS); +extern Datum gtsvector_compress (PG_FUNCTION_ARGS); +extern Datum gtsvector_decompress (PG_FUNCTION_ARGS); +extern Datum gtsvector_picksplit (PG_FUNCTION_ARGS); +extern Datum gtsvector_union (PG_FUNCTION_ARGS); +extern Datum gtsvector_same (PG_FUNCTION_ARGS); +extern Datum gtsvector_penalty (PG_FUNCTION_ARGS); +extern Datum gtsvector_consistent (PG_FUNCTION_ARGS); +extern Datum gin_extract_tsvector (PG_FUNCTION_ARGS); +extern Datum gin_extract_tsquery (PG_FUNCTION_ARGS); +extern Datum gin_tsquery_consistent (PG_FUNCTION_ARGS); +extern Datum tsquery_lt (PG_FUNCTION_ARGS); +extern Datum tsquery_le (PG_FUNCTION_ARGS); +extern Datum tsquery_eq (PG_FUNCTION_ARGS); +extern Datum tsquery_ne (PG_FUNCTION_ARGS); +extern Datum tsquery_ge (PG_FUNCTION_ARGS); +extern Datum tsquery_gt (PG_FUNCTION_ARGS); +extern Datum tsquery_cmp (PG_FUNCTION_ARGS); +extern Datum tsquery_and (PG_FUNCTION_ARGS); +extern Datum tsquery_or (PG_FUNCTION_ARGS); +extern Datum tsquery_not (PG_FUNCTION_ARGS); +extern Datum tsquery_numnode (PG_FUNCTION_ARGS); +extern Datum tsquerytree (PG_FUNCTION_ARGS); +extern Datum tsquery_rewrite (PG_FUNCTION_ARGS); +extern Datum tsquery_rewrite_query (PG_FUNCTION_ARGS); +extern Datum tsmatchsel (PG_FUNCTION_ARGS); +extern Datum tsmatchjoinsel (PG_FUNCTION_ARGS); +extern Datum ts_typanalyze (PG_FUNCTION_ARGS); +extern Datum ts_stat1 (PG_FUNCTION_ARGS); +extern Datum ts_stat2 (PG_FUNCTION_ARGS); +extern Datum tsq_mcontains (PG_FUNCTION_ARGS); +extern Datum tsq_mcontained (PG_FUNCTION_ARGS); +extern Datum gtsquery_compress (PG_FUNCTION_ARGS); +extern Datum gtsquery_decompress (PG_FUNCTION_ARGS); +extern Datum gtsquery_picksplit (PG_FUNCTION_ARGS); +extern Datum gtsquery_union (PG_FUNCTION_ARGS); +extern Datum gtsquery_same (PG_FUNCTION_ARGS); +extern Datum gtsquery_penalty (PG_FUNCTION_ARGS); +extern Datum gtsquery_consistent (PG_FUNCTION_ARGS); +extern Datum ts_rank_wttf (PG_FUNCTION_ARGS); +extern Datum ts_rank_wtt (PG_FUNCTION_ARGS); +extern Datum ts_rank_ttf (PG_FUNCTION_ARGS); +extern Datum ts_rank_tt (PG_FUNCTION_ARGS); +extern Datum ts_rankcd_wttf (PG_FUNCTION_ARGS); +extern Datum ts_rankcd_wtt (PG_FUNCTION_ARGS); +extern Datum ts_rankcd_ttf (PG_FUNCTION_ARGS); +extern Datum ts_rankcd_tt (PG_FUNCTION_ARGS); +extern Datum tsvector_length (PG_FUNCTION_ARGS); +extern Datum ts_token_type_byid (PG_FUNCTION_ARGS); +extern Datum ts_token_type_byname (PG_FUNCTION_ARGS); +extern Datum ts_parse_byid (PG_FUNCTION_ARGS); +extern Datum ts_parse_byname (PG_FUNCTION_ARGS); +extern Datum prsd_start (PG_FUNCTION_ARGS); +extern Datum prsd_nexttoken (PG_FUNCTION_ARGS); +extern Datum prsd_end (PG_FUNCTION_ARGS); +extern Datum prsd_headline (PG_FUNCTION_ARGS); +extern Datum prsd_lextype (PG_FUNCTION_ARGS); +extern Datum ts_lexize (PG_FUNCTION_ARGS); +extern Datum gin_cmp_tslexeme (PG_FUNCTION_ARGS); +extern Datum dsimple_init (PG_FUNCTION_ARGS); +extern Datum dsimple_lexize (PG_FUNCTION_ARGS); +extern Datum dsynonym_init (PG_FUNCTION_ARGS); +extern Datum dsynonym_lexize (PG_FUNCTION_ARGS); +extern Datum dispell_init (PG_FUNCTION_ARGS); +extern Datum dispell_lexize (PG_FUNCTION_ARGS); +extern Datum regconfigin (PG_FUNCTION_ARGS); +extern Datum regconfigout (PG_FUNCTION_ARGS); +extern Datum regconfigrecv (PG_FUNCTION_ARGS); +extern Datum regconfigsend (PG_FUNCTION_ARGS); +extern Datum thesaurus_init (PG_FUNCTION_ARGS); +extern Datum thesaurus_lexize (PG_FUNCTION_ARGS); +extern Datum ts_headline_byid_opt (PG_FUNCTION_ARGS); +extern Datum ts_headline_byid (PG_FUNCTION_ARGS); +extern Datum to_tsvector_byid (PG_FUNCTION_ARGS); +extern Datum to_tsquery_byid (PG_FUNCTION_ARGS); +extern Datum plainto_tsquery_byid (PG_FUNCTION_ARGS); +extern Datum to_tsvector (PG_FUNCTION_ARGS); +extern Datum to_tsquery (PG_FUNCTION_ARGS); +extern Datum plainto_tsquery (PG_FUNCTION_ARGS); +extern Datum tsvector_update_trigger_byid (PG_FUNCTION_ARGS); +extern Datum tsvector_update_trigger_bycolumn (PG_FUNCTION_ARGS); +extern Datum ts_headline_opt (PG_FUNCTION_ARGS); +extern Datum ts_headline (PG_FUNCTION_ARGS); +extern Datum pg_ts_parser_is_visible (PG_FUNCTION_ARGS); +extern Datum pg_ts_dict_is_visible (PG_FUNCTION_ARGS); +extern Datum pg_ts_config_is_visible (PG_FUNCTION_ARGS); +extern Datum get_current_ts_config (PG_FUNCTION_ARGS); +extern Datum ts_match_tt (PG_FUNCTION_ARGS); +extern Datum ts_match_tq (PG_FUNCTION_ARGS); +extern Datum pg_ts_template_is_visible (PG_FUNCTION_ARGS); +extern Datum regdictionaryin (PG_FUNCTION_ARGS); +extern Datum regdictionaryout (PG_FUNCTION_ARGS); +extern Datum regdictionaryrecv (PG_FUNCTION_ARGS); +extern Datum regdictionarysend (PG_FUNCTION_ARGS); +extern Datum pg_stat_reset_shared (PG_FUNCTION_ARGS); +extern Datum pg_stat_reset_single_table_counters (PG_FUNCTION_ARGS); +extern Datum pg_stat_reset_single_function_counters (PG_FUNCTION_ARGS); +extern Datum pg_tablespace_location (PG_FUNCTION_ARGS); +extern Datum pg_export_snapshot (PG_FUNCTION_ARGS); +extern Datum pg_is_in_recovery (PG_FUNCTION_ARGS); +extern Datum int4_cash (PG_FUNCTION_ARGS); +extern Datum int8_cash (PG_FUNCTION_ARGS); +extern Datum pg_collation_is_visible (PG_FUNCTION_ARGS); +extern Datum array_typanalyze (PG_FUNCTION_ARGS); +extern Datum arraycontsel (PG_FUNCTION_ARGS); +extern Datum arraycontjoinsel (PG_FUNCTION_ARGS); +extern Datum pg_last_xlog_receive_location (PG_FUNCTION_ARGS); +extern Datum pg_last_xlog_replay_location (PG_FUNCTION_ARGS); +extern Datum cash_div_cash (PG_FUNCTION_ARGS); +extern Datum cash_numeric (PG_FUNCTION_ARGS); +extern Datum numeric_cash (PG_FUNCTION_ARGS); +extern Datum pg_read_file_all (PG_FUNCTION_ARGS); +extern Datum pg_read_binary_file (PG_FUNCTION_ARGS); +extern Datum pg_read_binary_file_all (PG_FUNCTION_ARGS); +extern Datum pg_opfamily_is_visible (PG_FUNCTION_ARGS); +extern Datum pg_last_xact_replay_timestamp (PG_FUNCTION_ARGS); +extern Datum anyrange_in (PG_FUNCTION_ARGS); +extern Datum anyrange_out (PG_FUNCTION_ARGS); +extern Datum range_in (PG_FUNCTION_ARGS); +extern Datum range_out (PG_FUNCTION_ARGS); +extern Datum range_recv (PG_FUNCTION_ARGS); +extern Datum range_send (PG_FUNCTION_ARGS); +extern Datum range_constructor2 (PG_FUNCTION_ARGS); +extern Datum range_constructor3 (PG_FUNCTION_ARGS); +extern Datum range_lower (PG_FUNCTION_ARGS); +extern Datum range_upper (PG_FUNCTION_ARGS); +extern Datum range_empty (PG_FUNCTION_ARGS); +extern Datum range_lower_inc (PG_FUNCTION_ARGS); +extern Datum range_upper_inc (PG_FUNCTION_ARGS); +extern Datum range_lower_inf (PG_FUNCTION_ARGS); +extern Datum range_upper_inf (PG_FUNCTION_ARGS); +extern Datum range_eq (PG_FUNCTION_ARGS); +extern Datum range_ne (PG_FUNCTION_ARGS); +extern Datum range_overlaps (PG_FUNCTION_ARGS); +extern Datum range_contains_elem (PG_FUNCTION_ARGS); +extern Datum range_contains (PG_FUNCTION_ARGS); +extern Datum elem_contained_by_range (PG_FUNCTION_ARGS); +extern Datum range_contained_by (PG_FUNCTION_ARGS); +extern Datum range_adjacent (PG_FUNCTION_ARGS); +extern Datum range_before (PG_FUNCTION_ARGS); +extern Datum range_after (PG_FUNCTION_ARGS); +extern Datum range_overleft (PG_FUNCTION_ARGS); +extern Datum range_overright (PG_FUNCTION_ARGS); +extern Datum range_union (PG_FUNCTION_ARGS); +extern Datum range_intersect (PG_FUNCTION_ARGS); +extern Datum range_minus (PG_FUNCTION_ARGS); +extern Datum range_cmp (PG_FUNCTION_ARGS); +extern Datum range_lt (PG_FUNCTION_ARGS); +extern Datum range_le (PG_FUNCTION_ARGS); +extern Datum range_ge (PG_FUNCTION_ARGS); +extern Datum range_gt (PG_FUNCTION_ARGS); +extern Datum range_gist_consistent (PG_FUNCTION_ARGS); +extern Datum range_gist_union (PG_FUNCTION_ARGS); +extern Datum range_gist_compress (PG_FUNCTION_ARGS); +extern Datum range_gist_decompress (PG_FUNCTION_ARGS); +extern Datum range_gist_penalty (PG_FUNCTION_ARGS); +extern Datum range_gist_picksplit (PG_FUNCTION_ARGS); +extern Datum range_gist_same (PG_FUNCTION_ARGS); +extern Datum hash_range (PG_FUNCTION_ARGS); +extern Datum int4range_canonical (PG_FUNCTION_ARGS); +extern Datum daterange_canonical (PG_FUNCTION_ARGS); +extern Datum range_typanalyze (PG_FUNCTION_ARGS); +extern Datum timestamp_transform (PG_FUNCTION_ARGS); +extern Datum interval_transform (PG_FUNCTION_ARGS); +extern Datum int4range_subdiff (PG_FUNCTION_ARGS); +extern Datum int8range_subdiff (PG_FUNCTION_ARGS); +extern Datum numrange_subdiff (PG_FUNCTION_ARGS); +extern Datum daterange_subdiff (PG_FUNCTION_ARGS); +extern Datum int8range_canonical (PG_FUNCTION_ARGS); +extern Datum tsrange_subdiff (PG_FUNCTION_ARGS); +extern Datum tstzrange_subdiff (PG_FUNCTION_ARGS); +extern Datum acldefault_sql (PG_FUNCTION_ARGS); +extern Datum time_transform (PG_FUNCTION_ARGS); +extern Datum spggettuple (PG_FUNCTION_ARGS); +extern Datum spggetbitmap (PG_FUNCTION_ARGS); +extern Datum spginsert (PG_FUNCTION_ARGS); +extern Datum spgbeginscan (PG_FUNCTION_ARGS); +extern Datum spgrescan (PG_FUNCTION_ARGS); +extern Datum spgendscan (PG_FUNCTION_ARGS); +extern Datum spgmarkpos (PG_FUNCTION_ARGS); +extern Datum spgrestrpos (PG_FUNCTION_ARGS); +extern Datum spgbuild (PG_FUNCTION_ARGS); +extern Datum spgbuildempty (PG_FUNCTION_ARGS); +extern Datum spgbulkdelete (PG_FUNCTION_ARGS); +extern Datum spgvacuumcleanup (PG_FUNCTION_ARGS); +extern Datum spgcostestimate (PG_FUNCTION_ARGS); +extern Datum spgoptions (PG_FUNCTION_ARGS); +extern Datum spg_quad_config (PG_FUNCTION_ARGS); +extern Datum spg_quad_choose (PG_FUNCTION_ARGS); +extern Datum spg_quad_picksplit (PG_FUNCTION_ARGS); +extern Datum spg_quad_inner_consistent (PG_FUNCTION_ARGS); +extern Datum spg_quad_leaf_consistent (PG_FUNCTION_ARGS); +extern Datum spg_kd_config (PG_FUNCTION_ARGS); +extern Datum spg_kd_choose (PG_FUNCTION_ARGS); +extern Datum spg_kd_picksplit (PG_FUNCTION_ARGS); +extern Datum spg_kd_inner_consistent (PG_FUNCTION_ARGS); +extern Datum spg_text_config (PG_FUNCTION_ARGS); +extern Datum spg_text_choose (PG_FUNCTION_ARGS); +extern Datum spg_text_picksplit (PG_FUNCTION_ARGS); +extern Datum spg_text_inner_consistent (PG_FUNCTION_ARGS); +extern Datum spg_text_leaf_consistent (PG_FUNCTION_ARGS); +extern Datum spgcanreturn (PG_FUNCTION_ARGS); + +const FmgrBuiltin fmgr_builtins[] = { + { 31, "byteaout", 1, true, false, byteaout }, + { 33, "charout", 1, true, false, charout }, + { 34, "namein", 1, true, false, namein }, + { 35, "nameout", 1, true, false, nameout }, + { 38, "int2in", 1, true, false, int2in }, + { 39, "int2out", 1, true, false, int2out }, + { 40, "int2vectorin", 1, true, false, int2vectorin }, + { 41, "int2vectorout", 1, true, false, int2vectorout }, + { 42, "int4in", 1, true, false, int4in }, + { 43, "int4out", 1, true, false, int4out }, + { 44, "regprocin", 1, true, false, regprocin }, + { 45, "regprocout", 1, true, false, regprocout }, + { 46, "textin", 1, true, false, textin }, + { 47, "textout", 1, true, false, textout }, + { 48, "tidin", 1, true, false, tidin }, + { 49, "tidout", 1, true, false, tidout }, + { 50, "xidin", 1, true, false, xidin }, + { 51, "xidout", 1, true, false, xidout }, + { 52, "cidin", 1, true, false, cidin }, + { 53, "cidout", 1, true, false, cidout }, + { 54, "oidvectorin", 1, true, false, oidvectorin }, + { 55, "oidvectorout", 1, true, false, oidvectorout }, + { 56, "boollt", 2, true, false, boollt }, + { 57, "boolgt", 2, true, false, boolgt }, + { 60, "booleq", 2, true, false, booleq }, + { 61, "chareq", 2, true, false, chareq }, + { 62, "nameeq", 2, true, false, nameeq }, + { 63, "int2eq", 2, true, false, int2eq }, + { 64, "int2lt", 2, true, false, int2lt }, + { 65, "int4eq", 2, true, false, int4eq }, + { 66, "int4lt", 2, true, false, int4lt }, + { 67, "texteq", 2, true, false, texteq }, + { 68, "xideq", 2, true, false, xideq }, + { 69, "cideq", 2, true, false, cideq }, + { 70, "charne", 2, true, false, charne }, + { 72, "charle", 2, true, false, charle }, + { 73, "chargt", 2, true, false, chargt }, + { 74, "charge", 2, true, false, charge }, + { 77, "chartoi4", 1, true, false, chartoi4 }, + { 78, "i4tochar", 1, true, false, i4tochar }, + { 79, "nameregexeq", 2, true, false, nameregexeq }, + { 84, "boolne", 2, true, false, boolne }, + { 89, "pgsql_version", 0, true, false, pgsql_version }, + { 101, "eqsel", 4, true, false, eqsel }, + { 102, "neqsel", 4, true, false, neqsel }, + { 103, "scalarltsel", 4, true, false, scalarltsel }, + { 104, "scalargtsel", 4, true, false, scalargtsel }, + { 105, "eqjoinsel", 5, true, false, eqjoinsel }, + { 106, "neqjoinsel", 5, true, false, neqjoinsel }, + { 107, "scalarltjoinsel", 5, true, false, scalarltjoinsel }, + { 108, "scalargtjoinsel", 5, true, false, scalargtjoinsel }, + { 109, "unknownin", 1, true, false, unknownin }, + { 110, "unknownout", 1, true, false, unknownout }, + { 111, "numeric_fac", 1, true, false, numeric_fac }, + { 115, "box_above_eq", 2, true, false, box_above_eq }, + { 116, "box_below_eq", 2, true, false, box_below_eq }, + { 117, "point_in", 1, true, false, point_in }, + { 118, "point_out", 1, true, false, point_out }, + { 119, "lseg_in", 1, true, false, lseg_in }, + { 120, "lseg_out", 1, true, false, lseg_out }, + { 121, "path_in", 1, true, false, path_in }, + { 122, "path_out", 1, true, false, path_out }, + { 123, "box_in", 1, true, false, box_in }, + { 124, "box_out", 1, true, false, box_out }, + { 125, "box_overlap", 2, true, false, box_overlap }, + { 126, "box_ge", 2, true, false, box_ge }, + { 127, "box_gt", 2, true, false, box_gt }, + { 128, "box_eq", 2, true, false, box_eq }, + { 129, "box_lt", 2, true, false, box_lt }, + { 130, "box_le", 2, true, false, box_le }, + { 131, "point_above", 2, true, false, point_above }, + { 132, "point_left", 2, true, false, point_left }, + { 133, "point_right", 2, true, false, point_right }, + { 134, "point_below", 2, true, false, point_below }, + { 135, "point_eq", 2, true, false, point_eq }, + { 136, "on_pb", 2, true, false, on_pb }, + { 137, "on_ppath", 2, true, false, on_ppath }, + { 138, "box_center", 1, true, false, box_center }, + { 139, "areasel", 4, true, false, areasel }, + { 140, "areajoinsel", 5, true, false, areajoinsel }, + { 141, "int4mul", 2, true, false, int4mul }, + { 144, "int4ne", 2, true, false, int4ne }, + { 145, "int2ne", 2, true, false, int2ne }, + { 146, "int2gt", 2, true, false, int2gt }, + { 147, "int4gt", 2, true, false, int4gt }, + { 148, "int2le", 2, true, false, int2le }, + { 149, "int4le", 2, true, false, int4le }, + { 150, "int4ge", 2, true, false, int4ge }, + { 151, "int2ge", 2, true, false, int2ge }, + { 152, "int2mul", 2, true, false, int2mul }, + { 153, "int2div", 2, true, false, int2div }, + { 154, "int4div", 2, true, false, int4div }, + { 155, "int2mod", 2, true, false, int2mod }, + { 156, "int4mod", 2, true, false, int4mod }, + { 157, "textne", 2, true, false, textne }, + { 158, "int24eq", 2, true, false, int24eq }, + { 159, "int42eq", 2, true, false, int42eq }, + { 160, "int24lt", 2, true, false, int24lt }, + { 161, "int42lt", 2, true, false, int42lt }, + { 162, "int24gt", 2, true, false, int24gt }, + { 163, "int42gt", 2, true, false, int42gt }, + { 164, "int24ne", 2, true, false, int24ne }, + { 165, "int42ne", 2, true, false, int42ne }, + { 166, "int24le", 2, true, false, int24le }, + { 167, "int42le", 2, true, false, int42le }, + { 168, "int24ge", 2, true, false, int24ge }, + { 169, "int42ge", 2, true, false, int42ge }, + { 170, "int24mul", 2, true, false, int24mul }, + { 171, "int42mul", 2, true, false, int42mul }, + { 172, "int24div", 2, true, false, int24div }, + { 173, "int42div", 2, true, false, int42div }, + { 176, "int2pl", 2, true, false, int2pl }, + { 177, "int4pl", 2, true, false, int4pl }, + { 178, "int24pl", 2, true, false, int24pl }, + { 179, "int42pl", 2, true, false, int42pl }, + { 180, "int2mi", 2, true, false, int2mi }, + { 181, "int4mi", 2, true, false, int4mi }, + { 182, "int24mi", 2, true, false, int24mi }, + { 183, "int42mi", 2, true, false, int42mi }, + { 184, "oideq", 2, true, false, oideq }, + { 185, "oidne", 2, true, false, oidne }, + { 186, "box_same", 2, true, false, box_same }, + { 187, "box_contain", 2, true, false, box_contain }, + { 188, "box_left", 2, true, false, box_left }, + { 189, "box_overleft", 2, true, false, box_overleft }, + { 190, "box_overright", 2, true, false, box_overright }, + { 191, "box_right", 2, true, false, box_right }, + { 192, "box_contained", 2, true, false, box_contained }, + { 193, "box_contain_pt", 2, true, false, box_contain_pt }, + { 195, "pg_node_tree_in", 1, true, false, pg_node_tree_in }, + { 196, "pg_node_tree_out", 1, true, false, pg_node_tree_out }, + { 197, "pg_node_tree_recv", 1, true, false, pg_node_tree_recv }, + { 198, "pg_node_tree_send", 1, true, false, pg_node_tree_send }, + { 200, "float4in", 1, true, false, float4in }, + { 201, "float4out", 1, true, false, float4out }, + { 202, "float4mul", 2, true, false, float4mul }, + { 203, "float4div", 2, true, false, float4div }, + { 204, "float4pl", 2, true, false, float4pl }, + { 205, "float4mi", 2, true, false, float4mi }, + { 206, "float4um", 1, true, false, float4um }, + { 207, "float4abs", 1, true, false, float4abs }, + { 208, "float4_accum", 2, true, false, float4_accum }, + { 209, "float4larger", 2, true, false, float4larger }, + { 211, "float4smaller", 2, true, false, float4smaller }, + { 212, "int4um", 1, true, false, int4um }, + { 213, "int2um", 1, true, false, int2um }, + { 214, "float8in", 1, true, false, float8in }, + { 215, "float8out", 1, true, false, float8out }, + { 216, "float8mul", 2, true, false, float8mul }, + { 217, "float8div", 2, true, false, float8div }, + { 218, "float8pl", 2, true, false, float8pl }, + { 219, "float8mi", 2, true, false, float8mi }, + { 220, "float8um", 1, true, false, float8um }, + { 221, "float8abs", 1, true, false, float8abs }, + { 222, "float8_accum", 2, true, false, float8_accum }, + { 223, "float8larger", 2, true, false, float8larger }, + { 224, "float8smaller", 2, true, false, float8smaller }, + { 225, "lseg_center", 1, true, false, lseg_center }, + { 226, "path_center", 1, true, false, path_center }, + { 227, "poly_center", 1, true, false, poly_center }, + { 228, "dround", 1, true, false, dround }, + { 229, "dtrunc", 1, true, false, dtrunc }, + { 230, "dsqrt", 1, true, false, dsqrt }, + { 231, "dcbrt", 1, true, false, dcbrt }, + { 232, "dpow", 2, true, false, dpow }, + { 233, "dexp", 1, true, false, dexp }, + { 234, "dlog1", 1, true, false, dlog1 }, + { 235, "i2tod", 1, true, false, i2tod }, + { 236, "i2tof", 1, true, false, i2tof }, + { 237, "dtoi2", 1, true, false, dtoi2 }, + { 238, "ftoi2", 1, true, false, ftoi2 }, + { 239, "line_distance", 2, true, false, line_distance }, + { 240, "abstimein", 1, true, false, abstimein }, + { 241, "abstimeout", 1, true, false, abstimeout }, + { 242, "reltimein", 1, true, false, reltimein }, + { 243, "reltimeout", 1, true, false, reltimeout }, + { 244, "timepl", 2, true, false, timepl }, + { 245, "timemi", 2, true, false, timemi }, + { 246, "tintervalin", 1, true, false, tintervalin }, + { 247, "tintervalout", 1, true, false, tintervalout }, + { 248, "intinterval", 2, true, false, intinterval }, + { 249, "tintervalrel", 1, true, false, tintervalrel }, + { 250, "timenow", 0, true, false, timenow }, + { 251, "abstimeeq", 2, true, false, abstimeeq }, + { 252, "abstimene", 2, true, false, abstimene }, + { 253, "abstimelt", 2, true, false, abstimelt }, + { 254, "abstimegt", 2, true, false, abstimegt }, + { 255, "abstimele", 2, true, false, abstimele }, + { 256, "abstimege", 2, true, false, abstimege }, + { 257, "reltimeeq", 2, true, false, reltimeeq }, + { 258, "reltimene", 2, true, false, reltimene }, + { 259, "reltimelt", 2, true, false, reltimelt }, + { 260, "reltimegt", 2, true, false, reltimegt }, + { 261, "reltimele", 2, true, false, reltimele }, + { 262, "reltimege", 2, true, false, reltimege }, + { 263, "tintervalsame", 2, true, false, tintervalsame }, + { 264, "tintervalct", 2, true, false, tintervalct }, + { 265, "tintervalov", 2, true, false, tintervalov }, + { 266, "tintervalleneq", 2, true, false, tintervalleneq }, + { 267, "tintervallenne", 2, true, false, tintervallenne }, + { 268, "tintervallenlt", 2, true, false, tintervallenlt }, + { 269, "tintervallengt", 2, true, false, tintervallengt }, + { 270, "tintervallenle", 2, true, false, tintervallenle }, + { 271, "tintervallenge", 2, true, false, tintervallenge }, + { 272, "tintervalstart", 1, true, false, tintervalstart }, + { 273, "tintervalend", 1, true, false, tintervalend }, + { 274, "timeofday", 0, true, false, timeofday }, + { 275, "abstime_finite", 1, true, false, abstime_finite }, + { 276, "btcanreturn", 1, true, false, btcanreturn }, + { 277, "inter_sl", 2, true, false, inter_sl }, + { 278, "inter_lb", 2, true, false, inter_lb }, + { 279, "float48mul", 2, true, false, float48mul }, + { 280, "float48div", 2, true, false, float48div }, + { 281, "float48pl", 2, true, false, float48pl }, + { 282, "float48mi", 2, true, false, float48mi }, + { 283, "float84mul", 2, true, false, float84mul }, + { 284, "float84div", 2, true, false, float84div }, + { 285, "float84pl", 2, true, false, float84pl }, + { 286, "float84mi", 2, true, false, float84mi }, + { 287, "float4eq", 2, true, false, float4eq }, + { 288, "float4ne", 2, true, false, float4ne }, + { 289, "float4lt", 2, true, false, float4lt }, + { 290, "float4le", 2, true, false, float4le }, + { 291, "float4gt", 2, true, false, float4gt }, + { 292, "float4ge", 2, true, false, float4ge }, + { 293, "float8eq", 2, true, false, float8eq }, + { 294, "float8ne", 2, true, false, float8ne }, + { 295, "float8lt", 2, true, false, float8lt }, + { 296, "float8le", 2, true, false, float8le }, + { 297, "float8gt", 2, true, false, float8gt }, + { 298, "float8ge", 2, true, false, float8ge }, + { 299, "float48eq", 2, true, false, float48eq }, + { 300, "float48ne", 2, true, false, float48ne }, + { 301, "float48lt", 2, true, false, float48lt }, + { 302, "float48le", 2, true, false, float48le }, + { 303, "float48gt", 2, true, false, float48gt }, + { 304, "float48ge", 2, true, false, float48ge }, + { 305, "float84eq", 2, true, false, float84eq }, + { 306, "float84ne", 2, true, false, float84ne }, + { 307, "float84lt", 2, true, false, float84lt }, + { 308, "float84le", 2, true, false, float84le }, + { 309, "float84gt", 2, true, false, float84gt }, + { 310, "float84ge", 2, true, false, float84ge }, + { 311, "ftod", 1, true, false, ftod }, + { 312, "dtof", 1, true, false, dtof }, + { 313, "i2toi4", 1, true, false, i2toi4 }, + { 314, "i4toi2", 1, true, false, i4toi2 }, + { 315, "int2vectoreq", 2, true, false, int2vectoreq }, + { 316, "i4tod", 1, true, false, i4tod }, + { 317, "dtoi4", 1, true, false, dtoi4 }, + { 318, "i4tof", 1, true, false, i4tof }, + { 319, "ftoi4", 1, true, false, ftoi4 }, + { 320, "width_bucket_float8", 4, true, false, width_bucket_float8 }, + { 321, "json_in", 1, true, false, json_in }, + { 322, "json_out", 1, true, false, json_out }, + { 323, "json_recv", 1, true, false, json_recv }, + { 324, "json_send", 1, true, false, json_send }, + { 325, "ginbuildempty", 1, true, false, ginbuildempty }, + { 326, "gistbuildempty", 1, true, false, gistbuildempty }, + { 327, "hashbuildempty", 1, true, false, hashbuildempty }, + { 328, "btbuildempty", 1, true, false, btbuildempty }, + { 329, "hash_aclitem", 1, true, false, hash_aclitem }, + { 330, "btgettuple", 2, true, false, btgettuple }, + { 331, "btinsert", 6, true, false, btinsert }, + { 332, "btbulkdelete", 4, true, false, btbulkdelete }, + { 333, "btbeginscan", 3, true, false, btbeginscan }, + { 334, "btrescan", 5, true, false, btrescan }, + { 335, "btendscan", 1, true, false, btendscan }, + { 336, "btmarkpos", 1, true, false, btmarkpos }, + { 337, "btrestrpos", 1, true, false, btrestrpos }, + { 338, "btbuild", 3, true, false, btbuild }, + { 339, "poly_same", 2, true, false, poly_same }, + { 340, "poly_contain", 2, true, false, poly_contain }, + { 341, "poly_left", 2, true, false, poly_left }, + { 342, "poly_overleft", 2, true, false, poly_overleft }, + { 343, "poly_overright", 2, true, false, poly_overright }, + { 344, "poly_right", 2, true, false, poly_right }, + { 345, "poly_contained", 2, true, false, poly_contained }, + { 346, "poly_overlap", 2, true, false, poly_overlap }, + { 347, "poly_in", 1, true, false, poly_in }, + { 348, "poly_out", 1, true, false, poly_out }, + { 350, "btint2cmp", 2, true, false, btint2cmp }, + { 351, "btint4cmp", 2, true, false, btint4cmp }, + { 354, "btfloat4cmp", 2, true, false, btfloat4cmp }, + { 355, "btfloat8cmp", 2, true, false, btfloat8cmp }, + { 356, "btoidcmp", 2, true, false, btoidcmp }, + { 357, "btabstimecmp", 2, true, false, btabstimecmp }, + { 358, "btcharcmp", 2, true, false, btcharcmp }, + { 359, "btnamecmp", 2, true, false, btnamecmp }, + { 360, "bttextcmp", 2, true, false, bttextcmp }, + { 361, "lseg_distance", 2, true, false, lseg_distance }, + { 362, "lseg_interpt", 2, true, false, lseg_interpt }, + { 363, "dist_ps", 2, true, false, dist_ps }, + { 364, "dist_pb", 2, true, false, dist_pb }, + { 365, "dist_sb", 2, true, false, dist_sb }, + { 366, "close_ps", 2, true, false, close_ps }, + { 367, "close_pb", 2, true, false, close_pb }, + { 368, "close_sb", 2, true, false, close_sb }, + { 369, "on_ps", 2, true, false, on_ps }, + { 370, "path_distance", 2, true, false, path_distance }, + { 371, "dist_ppath", 2, true, false, dist_ppath }, + { 372, "on_sb", 2, true, false, on_sb }, + { 373, "inter_sb", 2, true, false, inter_sb }, + { 376, "text_to_array_null", 3, false, false, text_to_array_null }, + { 377, "cash_cmp", 2, true, false, cash_cmp }, + { 378, "array_push", 2, false, false, array_push }, + { 379, "array_push", 2, false, false, array_push }, + { 380, "btreltimecmp", 2, true, false, btreltimecmp }, + { 381, "bttintervalcmp", 2, true, false, bttintervalcmp }, + { 382, "btarraycmp", 2, true, false, btarraycmp }, + { 383, "array_cat", 2, false, false, array_cat }, + { 384, "array_to_text_null", 3, false, false, array_to_text_null }, + { 390, "array_ne", 2, true, false, array_ne }, + { 391, "array_lt", 2, true, false, array_lt }, + { 392, "array_gt", 2, true, false, array_gt }, + { 393, "array_le", 2, true, false, array_le }, + { 394, "text_to_array", 2, false, false, text_to_array }, + { 395, "array_to_text", 2, true, false, array_to_text }, + { 396, "array_ge", 2, true, false, array_ge }, + { 398, "hashint2vector", 1, true, false, hashint2vector }, + { 399, "hashmacaddr", 1, true, false, hashmacaddr }, + { 400, "hashtext", 1, true, false, hashtext }, + { 401, "rtrim1", 1, true, false, rtrim1 }, + { 404, "btoidvectorcmp", 2, true, false, btoidvectorcmp }, + { 406, "name_text", 1, true, false, name_text }, + { 407, "text_name", 1, true, false, text_name }, + { 408, "name_bpchar", 1, true, false, name_bpchar }, + { 409, "bpchar_name", 1, true, false, bpchar_name }, + { 422, "hashinet", 1, true, false, hashinet }, + { 425, "hashvacuumcleanup", 2, true, false, hashvacuumcleanup }, + { 432, "hash_numeric", 1, true, false, hash_numeric }, + { 436, "macaddr_in", 1, true, false, macaddr_in }, + { 437, "macaddr_out", 1, true, false, macaddr_out }, + { 438, "hashcostestimate", 7, true, false, hashcostestimate }, + { 440, "hashgettuple", 2, true, false, hashgettuple }, + { 441, "hashinsert", 6, true, false, hashinsert }, + { 442, "hashbulkdelete", 4, true, false, hashbulkdelete }, + { 443, "hashbeginscan", 3, true, false, hashbeginscan }, + { 444, "hashrescan", 5, true, false, hashrescan }, + { 445, "hashendscan", 1, true, false, hashendscan }, + { 446, "hashmarkpos", 1, true, false, hashmarkpos }, + { 447, "hashrestrpos", 1, true, false, hashrestrpos }, + { 448, "hashbuild", 3, true, false, hashbuild }, + { 449, "hashint2", 1, true, false, hashint2 }, + { 450, "hashint4", 1, true, false, hashint4 }, + { 451, "hashfloat4", 1, true, false, hashfloat4 }, + { 452, "hashfloat8", 1, true, false, hashfloat8 }, + { 453, "hashoid", 1, true, false, hashoid }, + { 454, "hashchar", 1, true, false, hashchar }, + { 455, "hashname", 1, true, false, hashname }, + { 456, "hashvarlena", 1, true, false, hashvarlena }, + { 457, "hashoidvector", 1, true, false, hashoidvector }, + { 458, "text_larger", 2, true, false, text_larger }, + { 459, "text_smaller", 2, true, false, text_smaller }, + { 460, "int8in", 1, true, false, int8in }, + { 461, "int8out", 1, true, false, int8out }, + { 462, "int8um", 1, true, false, int8um }, + { 463, "int8pl", 2, true, false, int8pl }, + { 464, "int8mi", 2, true, false, int8mi }, + { 465, "int8mul", 2, true, false, int8mul }, + { 466, "int8div", 2, true, false, int8div }, + { 467, "int8eq", 2, true, false, int8eq }, + { 468, "int8ne", 2, true, false, int8ne }, + { 469, "int8lt", 2, true, false, int8lt }, + { 470, "int8gt", 2, true, false, int8gt }, + { 471, "int8le", 2, true, false, int8le }, + { 472, "int8ge", 2, true, false, int8ge }, + { 474, "int84eq", 2, true, false, int84eq }, + { 475, "int84ne", 2, true, false, int84ne }, + { 476, "int84lt", 2, true, false, int84lt }, + { 477, "int84gt", 2, true, false, int84gt }, + { 478, "int84le", 2, true, false, int84le }, + { 479, "int84ge", 2, true, false, int84ge }, + { 480, "int84", 1, true, false, int84 }, + { 481, "int48", 1, true, false, int48 }, + { 482, "i8tod", 1, true, false, i8tod }, + { 483, "dtoi8", 1, true, false, dtoi8 }, + { 515, "array_larger", 2, true, false, array_larger }, + { 516, "array_smaller", 2, true, false, array_smaller }, + { 598, "inet_abbrev", 1, true, false, inet_abbrev }, + { 599, "cidr_abbrev", 1, true, false, cidr_abbrev }, + { 605, "inet_set_masklen", 2, true, false, inet_set_masklen }, + { 619, "oidvectorne", 2, true, false, oidvectorne }, + { 626, "hash_array", 1, true, false, hash_array }, + { 635, "cidr_set_masklen", 2, true, false, cidr_set_masklen }, + { 636, "btgetbitmap", 2, true, false, btgetbitmap }, + { 637, "hashgetbitmap", 2, true, false, hashgetbitmap }, + { 638, "gistgetbitmap", 2, true, false, gistgetbitmap }, + { 652, "i8tof", 1, true, false, i8tof }, + { 653, "ftoi8", 1, true, false, ftoi8 }, + { 655, "namelt", 2, true, false, namelt }, + { 656, "namele", 2, true, false, namele }, + { 657, "namegt", 2, true, false, namegt }, + { 658, "namege", 2, true, false, namege }, + { 659, "namene", 2, true, false, namene }, + { 668, "bpchar", 3, true, false, bpchar }, + { 669, "varchar", 3, true, false, varchar }, + { 676, "mktinterval", 2, true, false, mktinterval }, + { 677, "oidvectorlt", 2, true, false, oidvectorlt }, + { 678, "oidvectorle", 2, true, false, oidvectorle }, + { 679, "oidvectoreq", 2, true, false, oidvectoreq }, + { 680, "oidvectorge", 2, true, false, oidvectorge }, + { 681, "oidvectorgt", 2, true, false, oidvectorgt }, + { 683, "network_network", 1, true, false, network_network }, + { 696, "network_netmask", 1, true, false, network_netmask }, + { 697, "network_masklen", 1, true, false, network_masklen }, + { 698, "network_broadcast", 1, true, false, network_broadcast }, + { 699, "network_host", 1, true, false, network_host }, + { 710, "current_user", 0, true, false, current_user }, + { 711, "network_family", 1, true, false, network_family }, + { 714, "int82", 1, true, false, int82 }, + { 715, "lo_create", 1, true, false, lo_create }, + { 716, "oidlt", 2, true, false, oidlt }, + { 717, "oidle", 2, true, false, oidle }, + { 720, "byteaoctetlen", 1, true, false, byteaoctetlen }, + { 721, "byteaGetByte", 2, true, false, byteaGetByte }, + { 722, "byteaSetByte", 3, true, false, byteaSetByte }, + { 723, "byteaGetBit", 2, true, false, byteaGetBit }, + { 724, "byteaSetBit", 3, true, false, byteaSetBit }, + { 725, "dist_pl", 2, true, false, dist_pl }, + { 726, "dist_lb", 2, true, false, dist_lb }, + { 727, "dist_sl", 2, true, false, dist_sl }, + { 728, "dist_cpoly", 2, true, false, dist_cpoly }, + { 729, "poly_distance", 2, true, false, poly_distance }, + { 730, "network_show", 1, true, false, network_show }, + { 740, "text_lt", 2, true, false, text_lt }, + { 741, "text_le", 2, true, false, text_le }, + { 742, "text_gt", 2, true, false, text_gt }, + { 743, "text_ge", 2, true, false, text_ge }, + { 744, "array_eq", 2, true, false, array_eq }, + { 745, "current_user", 0, true, false, current_user }, + { 746, "session_user", 0, true, false, session_user }, + { 747, "array_dims", 1, true, false, array_dims }, + { 748, "array_ndims", 1, true, false, array_ndims }, + { 749, "byteaoverlay", 4, true, false, byteaoverlay }, + { 750, "array_in", 3, true, false, array_in }, + { 751, "array_out", 1, true, false, array_out }, + { 752, "byteaoverlay_no_len", 3, true, false, byteaoverlay_no_len }, + { 753, "macaddr_trunc", 1, true, false, macaddr_trunc }, + { 754, "int28", 1, true, false, int28 }, + { 760, "smgrin", 1, true, false, smgrin }, + { 761, "smgrout", 1, true, false, smgrout }, + { 762, "smgreq", 2, true, false, smgreq }, + { 763, "smgrne", 2, true, false, smgrne }, + { 764, "lo_import", 1, true, false, lo_import }, + { 765, "lo_export", 2, true, false, lo_export }, + { 766, "int4inc", 1, true, false, int4inc }, + { 767, "lo_import_with_oid", 2, true, false, lo_import_with_oid }, + { 768, "int4larger", 2, true, false, int4larger }, + { 769, "int4smaller", 2, true, false, int4smaller }, + { 770, "int2larger", 2, true, false, int2larger }, + { 771, "int2smaller", 2, true, false, int2smaller }, + { 772, "gistcostestimate", 7, true, false, gistcostestimate }, + { 774, "gistgettuple", 2, true, false, gistgettuple }, + { 775, "gistinsert", 6, true, false, gistinsert }, + { 776, "gistbulkdelete", 4, true, false, gistbulkdelete }, + { 777, "gistbeginscan", 3, true, false, gistbeginscan }, + { 778, "gistrescan", 5, true, false, gistrescan }, + { 779, "gistendscan", 1, true, false, gistendscan }, + { 780, "gistmarkpos", 1, true, false, gistmarkpos }, + { 781, "gistrestrpos", 1, true, false, gistrestrpos }, + { 782, "gistbuild", 3, true, false, gistbuild }, + { 784, "tintervaleq", 2, true, false, tintervaleq }, + { 785, "tintervalne", 2, true, false, tintervalne }, + { 786, "tintervallt", 2, true, false, tintervallt }, + { 787, "tintervalgt", 2, true, false, tintervalgt }, + { 788, "tintervalle", 2, true, false, tintervalle }, + { 789, "tintervalge", 2, true, false, tintervalge }, + { 810, "pg_client_encoding", 0, true, false, pg_client_encoding }, + { 817, "current_query", 0, false, false, current_query }, + { 830, "macaddr_eq", 2, true, false, macaddr_eq }, + { 831, "macaddr_lt", 2, true, false, macaddr_lt }, + { 832, "macaddr_le", 2, true, false, macaddr_le }, + { 833, "macaddr_gt", 2, true, false, macaddr_gt }, + { 834, "macaddr_ge", 2, true, false, macaddr_ge }, + { 835, "macaddr_ne", 2, true, false, macaddr_ne }, + { 836, "macaddr_cmp", 2, true, false, macaddr_cmp }, + { 837, "int82pl", 2, true, false, int82pl }, + { 838, "int82mi", 2, true, false, int82mi }, + { 839, "int82mul", 2, true, false, int82mul }, + { 840, "int82div", 2, true, false, int82div }, + { 841, "int28pl", 2, true, false, int28pl }, + { 842, "btint8cmp", 2, true, false, btint8cmp }, + { 846, "cash_mul_flt4", 2, true, false, cash_mul_flt4 }, + { 847, "cash_div_flt4", 2, true, false, cash_div_flt4 }, + { 848, "flt4_mul_cash", 2, true, false, flt4_mul_cash }, + { 849, "textpos", 2, true, false, textpos }, + { 850, "textlike", 2, true, false, textlike }, + { 851, "textnlike", 2, true, false, textnlike }, + { 852, "int48eq", 2, true, false, int48eq }, + { 853, "int48ne", 2, true, false, int48ne }, + { 854, "int48lt", 2, true, false, int48lt }, + { 855, "int48gt", 2, true, false, int48gt }, + { 856, "int48le", 2, true, false, int48le }, + { 857, "int48ge", 2, true, false, int48ge }, + { 858, "namelike", 2, true, false, namelike }, + { 859, "namenlike", 2, true, false, namenlike }, + { 860, "char_bpchar", 1, true, false, char_bpchar }, + { 861, "current_database", 0, true, false, current_database }, + { 862, "int4_mul_cash", 2, true, false, int4_mul_cash }, + { 863, "int2_mul_cash", 2, true, false, int2_mul_cash }, + { 864, "cash_mul_int4", 2, true, false, cash_mul_int4 }, + { 865, "cash_div_int4", 2, true, false, cash_div_int4 }, + { 866, "cash_mul_int2", 2, true, false, cash_mul_int2 }, + { 867, "cash_div_int2", 2, true, false, cash_div_int2 }, + { 868, "textpos", 2, true, false, textpos }, + { 870, "lower", 1, true, false, lower }, + { 871, "upper", 1, true, false, upper }, + { 872, "initcap", 1, true, false, initcap }, + { 873, "lpad", 3, true, false, lpad }, + { 874, "rpad", 3, true, false, rpad }, + { 875, "ltrim", 2, true, false, ltrim }, + { 876, "rtrim", 2, true, false, rtrim }, + { 877, "text_substr", 3, true, false, text_substr }, + { 878, "translate", 3, true, false, translate }, + { 881, "ltrim1", 1, true, false, ltrim1 }, + { 882, "rtrim1", 1, true, false, rtrim1 }, + { 883, "text_substr_no_len", 2, true, false, text_substr_no_len }, + { 884, "btrim", 2, true, false, btrim }, + { 885, "btrim1", 1, true, false, btrim1 }, + { 886, "cash_in", 1, true, false, cash_in }, + { 887, "cash_out", 1, true, false, cash_out }, + { 888, "cash_eq", 2, true, false, cash_eq }, + { 889, "cash_ne", 2, true, false, cash_ne }, + { 890, "cash_lt", 2, true, false, cash_lt }, + { 891, "cash_le", 2, true, false, cash_le }, + { 892, "cash_gt", 2, true, false, cash_gt }, + { 893, "cash_ge", 2, true, false, cash_ge }, + { 894, "cash_pl", 2, true, false, cash_pl }, + { 895, "cash_mi", 2, true, false, cash_mi }, + { 896, "cash_mul_flt8", 2, true, false, cash_mul_flt8 }, + { 897, "cash_div_flt8", 2, true, false, cash_div_flt8 }, + { 898, "cashlarger", 2, true, false, cashlarger }, + { 899, "cashsmaller", 2, true, false, cashsmaller }, + { 910, "inet_in", 1, true, false, inet_in }, + { 911, "inet_out", 1, true, false, inet_out }, + { 919, "flt8_mul_cash", 2, true, false, flt8_mul_cash }, + { 920, "network_eq", 2, true, false, network_eq }, + { 921, "network_lt", 2, true, false, network_lt }, + { 922, "network_le", 2, true, false, network_le }, + { 923, "network_gt", 2, true, false, network_gt }, + { 924, "network_ge", 2, true, false, network_ge }, + { 925, "network_ne", 2, true, false, network_ne }, + { 926, "network_cmp", 2, true, false, network_cmp }, + { 927, "network_sub", 2, true, false, network_sub }, + { 928, "network_subeq", 2, true, false, network_subeq }, + { 929, "network_sup", 2, true, false, network_sup }, + { 930, "network_supeq", 2, true, false, network_supeq }, + { 935, "cash_words", 1, true, false, cash_words }, + { 936, "text_substr", 3, true, false, text_substr }, + { 937, "text_substr_no_len", 2, true, false, text_substr_no_len }, + { 938, "generate_series_timestamp", 3, true, true, generate_series_timestamp }, + { 939, "generate_series_timestamptz", 3, true, true, generate_series_timestamptz }, + { 940, "int2mod", 2, true, false, int2mod }, + { 941, "int4mod", 2, true, false, int4mod }, + { 942, "int28mi", 2, true, false, int28mi }, + { 943, "int28mul", 2, true, false, int28mul }, + { 944, "text_char", 1, true, false, text_char }, + { 945, "int8mod", 2, true, false, int8mod }, + { 946, "char_text", 1, true, false, char_text }, + { 947, "int8mod", 2, true, false, int8mod }, + { 948, "int28div", 2, true, false, int28div }, + { 949, "hashint8", 1, true, false, hashint8 }, + { 952, "lo_open", 2, true, false, lo_open }, + { 953, "lo_close", 1, true, false, lo_close }, + { 954, "loread", 2, true, false, loread }, + { 955, "lowrite", 2, true, false, lowrite }, + { 956, "lo_lseek", 3, true, false, lo_lseek }, + { 957, "lo_creat", 1, true, false, lo_creat }, + { 958, "lo_tell", 1, true, false, lo_tell }, + { 959, "on_pl", 2, true, false, on_pl }, + { 960, "on_sl", 2, true, false, on_sl }, + { 961, "close_pl", 2, true, false, close_pl }, + { 962, "close_sl", 2, true, false, close_sl }, + { 963, "close_lb", 2, true, false, close_lb }, + { 964, "lo_unlink", 1, true, false, lo_unlink }, + { 972, "btvacuumcleanup", 2, true, false, btvacuumcleanup }, + { 973, "path_inter", 2, true, false, path_inter }, + { 975, "box_area", 1, true, false, box_area }, + { 976, "box_width", 1, true, false, box_width }, + { 977, "box_height", 1, true, false, box_height }, + { 978, "box_distance", 2, true, false, box_distance }, + { 979, "path_area", 1, true, false, path_area }, + { 980, "box_intersect", 2, true, false, box_intersect }, + { 981, "box_diagonal", 1, true, false, box_diagonal }, + { 982, "path_n_lt", 2, true, false, path_n_lt }, + { 983, "path_n_gt", 2, true, false, path_n_gt }, + { 984, "path_n_eq", 2, true, false, path_n_eq }, + { 985, "path_n_le", 2, true, false, path_n_le }, + { 986, "path_n_ge", 2, true, false, path_n_ge }, + { 987, "path_length", 1, true, false, path_length }, + { 988, "point_ne", 2, true, false, point_ne }, + { 989, "point_vert", 2, true, false, point_vert }, + { 990, "point_horiz", 2, true, false, point_horiz }, + { 991, "point_distance", 2, true, false, point_distance }, + { 992, "point_slope", 2, true, false, point_slope }, + { 993, "lseg_construct", 2, true, false, lseg_construct }, + { 994, "lseg_intersect", 2, true, false, lseg_intersect }, + { 995, "lseg_parallel", 2, true, false, lseg_parallel }, + { 996, "lseg_perp", 2, true, false, lseg_perp }, + { 997, "lseg_vertical", 1, true, false, lseg_vertical }, + { 998, "lseg_horizontal", 1, true, false, lseg_horizontal }, + { 999, "lseg_eq", 2, true, false, lseg_eq }, + { 1004, "lo_truncate", 2, true, false, lo_truncate }, + { 1026, "timestamptz_izone", 2, true, false, timestamptz_izone }, + { 1030, "gist_point_compress", 1, true, false, gist_point_compress }, + { 1031, "aclitemin", 1, true, false, aclitemin }, + { 1032, "aclitemout", 1, true, false, aclitemout }, + { 1035, "aclinsert", 2, true, false, aclinsert }, + { 1036, "aclremove", 2, true, false, aclremove }, + { 1037, "aclcontains", 2, true, false, aclcontains }, + { 1039, "getdatabaseencoding", 0, true, false, getdatabaseencoding }, + { 1044, "bpcharin", 3, true, false, bpcharin }, + { 1045, "bpcharout", 1, true, false, bpcharout }, + { 1046, "varcharin", 3, true, false, varcharin }, + { 1047, "varcharout", 1, true, false, varcharout }, + { 1048, "bpchareq", 2, true, false, bpchareq }, + { 1049, "bpcharlt", 2, true, false, bpcharlt }, + { 1050, "bpcharle", 2, true, false, bpcharle }, + { 1051, "bpchargt", 2, true, false, bpchargt }, + { 1052, "bpcharge", 2, true, false, bpcharge }, + { 1053, "bpcharne", 2, true, false, bpcharne }, + { 1062, "aclitem_eq", 2, true, false, aclitem_eq }, + { 1063, "bpchar_larger", 2, true, false, bpchar_larger }, + { 1064, "bpchar_smaller", 2, true, false, bpchar_smaller }, + { 1065, "pg_prepared_xact", 0, true, true, pg_prepared_xact }, + { 1066, "generate_series_step_int4", 3, true, true, generate_series_step_int4 }, + { 1067, "generate_series_int4", 2, true, true, generate_series_int4 }, + { 1068, "generate_series_step_int8", 3, true, true, generate_series_step_int8 }, + { 1069, "generate_series_int8", 2, true, true, generate_series_int8 }, + { 1078, "bpcharcmp", 2, true, false, bpcharcmp }, + { 1079, "text_regclass", 1, true, false, text_regclass }, + { 1080, "hashbpchar", 1, true, false, hashbpchar }, + { 1081, "format_type", 2, false, false, format_type }, + { 1084, "date_in", 1, true, false, date_in }, + { 1085, "date_out", 1, true, false, date_out }, + { 1086, "date_eq", 2, true, false, date_eq }, + { 1087, "date_lt", 2, true, false, date_lt }, + { 1088, "date_le", 2, true, false, date_le }, + { 1089, "date_gt", 2, true, false, date_gt }, + { 1090, "date_ge", 2, true, false, date_ge }, + { 1091, "date_ne", 2, true, false, date_ne }, + { 1092, "date_cmp", 2, true, false, date_cmp }, + { 1102, "time_lt", 2, true, false, time_lt }, + { 1103, "time_le", 2, true, false, time_le }, + { 1104, "time_gt", 2, true, false, time_gt }, + { 1105, "time_ge", 2, true, false, time_ge }, + { 1106, "time_ne", 2, true, false, time_ne }, + { 1107, "time_cmp", 2, true, false, time_cmp }, + { 1138, "date_larger", 2, true, false, date_larger }, + { 1139, "date_smaller", 2, true, false, date_smaller }, + { 1140, "date_mi", 2, true, false, date_mi }, + { 1141, "date_pli", 2, true, false, date_pli }, + { 1142, "date_mii", 2, true, false, date_mii }, + { 1143, "time_in", 3, true, false, time_in }, + { 1144, "time_out", 1, true, false, time_out }, + { 1145, "time_eq", 2, true, false, time_eq }, + { 1146, "circle_add_pt", 2, true, false, circle_add_pt }, + { 1147, "circle_sub_pt", 2, true, false, circle_sub_pt }, + { 1148, "circle_mul_pt", 2, true, false, circle_mul_pt }, + { 1149, "circle_div_pt", 2, true, false, circle_div_pt }, + { 1150, "timestamptz_in", 3, true, false, timestamptz_in }, + { 1151, "timestamptz_out", 1, true, false, timestamptz_out }, + { 1152, "timestamp_eq", 2, true, false, timestamp_eq }, + { 1153, "timestamp_ne", 2, true, false, timestamp_ne }, + { 1154, "timestamp_lt", 2, true, false, timestamp_lt }, + { 1155, "timestamp_le", 2, true, false, timestamp_le }, + { 1156, "timestamp_ge", 2, true, false, timestamp_ge }, + { 1157, "timestamp_gt", 2, true, false, timestamp_gt }, + { 1159, "timestamptz_zone", 2, true, false, timestamptz_zone }, + { 1160, "interval_in", 3, true, false, interval_in }, + { 1161, "interval_out", 1, true, false, interval_out }, + { 1162, "interval_eq", 2, true, false, interval_eq }, + { 1163, "interval_ne", 2, true, false, interval_ne }, + { 1164, "interval_lt", 2, true, false, interval_lt }, + { 1165, "interval_le", 2, true, false, interval_le }, + { 1166, "interval_ge", 2, true, false, interval_ge }, + { 1167, "interval_gt", 2, true, false, interval_gt }, + { 1168, "interval_um", 1, true, false, interval_um }, + { 1169, "interval_pl", 2, true, false, interval_pl }, + { 1170, "interval_mi", 2, true, false, interval_mi }, + { 1171, "timestamptz_part", 2, true, false, timestamptz_part }, + { 1172, "interval_part", 2, true, false, interval_part }, + { 1173, "abstime_timestamptz", 1, true, false, abstime_timestamptz }, + { 1174, "date_timestamptz", 1, true, false, date_timestamptz }, + { 1175, "interval_justify_hours", 1, true, false, interval_justify_hours }, + { 1177, "reltime_interval", 1, true, false, reltime_interval }, + { 1178, "timestamptz_date", 1, true, false, timestamptz_date }, + { 1179, "abstime_date", 1, true, false, abstime_date }, + { 1180, "timestamptz_abstime", 1, true, false, timestamptz_abstime }, + { 1181, "xid_age", 1, true, false, xid_age }, + { 1188, "timestamp_mi", 2, true, false, timestamp_mi }, + { 1189, "timestamptz_pl_interval", 2, true, false, timestamptz_pl_interval }, + { 1190, "timestamptz_mi_interval", 2, true, false, timestamptz_mi_interval }, + { 1191, "generate_subscripts", 3, true, true, generate_subscripts }, + { 1192, "generate_subscripts_nodir", 2, true, true, generate_subscripts_nodir }, + { 1193, "array_fill", 2, false, false, array_fill }, + { 1194, "interval_reltime", 1, true, false, interval_reltime }, + { 1195, "timestamp_smaller", 2, true, false, timestamp_smaller }, + { 1196, "timestamp_larger", 2, true, false, timestamp_larger }, + { 1197, "interval_smaller", 2, true, false, interval_smaller }, + { 1198, "interval_larger", 2, true, false, interval_larger }, + { 1199, "timestamptz_age", 2, true, false, timestamptz_age }, + { 1200, "interval_scale", 2, true, false, interval_scale }, + { 1217, "timestamptz_trunc", 2, true, false, timestamptz_trunc }, + { 1218, "interval_trunc", 2, true, false, interval_trunc }, + { 1219, "int8inc", 1, true, false, int8inc }, + { 1230, "int8abs", 1, true, false, int8abs }, + { 1236, "int8larger", 2, true, false, int8larger }, + { 1237, "int8smaller", 2, true, false, int8smaller }, + { 1238, "texticregexeq", 2, true, false, texticregexeq }, + { 1239, "texticregexne", 2, true, false, texticregexne }, + { 1240, "nameicregexeq", 2, true, false, nameicregexeq }, + { 1241, "nameicregexne", 2, true, false, nameicregexne }, + { 1242, "boolin", 1, true, false, boolin }, + { 1243, "boolout", 1, true, false, boolout }, + { 1244, "byteain", 1, true, false, byteain }, + { 1245, "charin", 1, true, false, charin }, + { 1246, "charlt", 2, true, false, charlt }, + { 1250, "unique_key_recheck", 0, true, false, unique_key_recheck }, + { 1251, "int4abs", 1, true, false, int4abs }, + { 1252, "nameregexne", 2, true, false, nameregexne }, + { 1253, "int2abs", 1, true, false, int2abs }, + { 1254, "textregexeq", 2, true, false, textregexeq }, + { 1256, "textregexne", 2, true, false, textregexne }, + { 1257, "textlen", 1, true, false, textlen }, + { 1258, "textcat", 2, true, false, textcat }, + { 1264, "PG_char_to_encoding", 1, true, false, PG_char_to_encoding }, + { 1265, "tidne", 2, true, false, tidne }, + { 1267, "cidr_in", 1, true, false, cidr_in }, + { 1268, "btcostestimate", 7, true, false, btcostestimate }, + { 1269, "pg_column_size", 1, true, false, pg_column_size }, + { 1271, "overlaps_timetz", 4, false, false, overlaps_timetz }, + { 1272, "datetime_timestamp", 2, true, false, datetime_timestamp }, + { 1273, "timetz_part", 2, true, false, timetz_part }, + { 1274, "int84pl", 2, true, false, int84pl }, + { 1275, "int84mi", 2, true, false, int84mi }, + { 1276, "int84mul", 2, true, false, int84mul }, + { 1277, "int84div", 2, true, false, int84div }, + { 1278, "int48pl", 2, true, false, int48pl }, + { 1279, "int48mi", 2, true, false, int48mi }, + { 1280, "int48mul", 2, true, false, int48mul }, + { 1281, "int48div", 2, true, false, int48div }, + { 1282, "quote_ident", 1, true, false, quote_ident }, + { 1283, "quote_literal", 1, true, false, quote_literal }, + { 1286, "array_fill_with_lower_bounds", 3, false, false, array_fill_with_lower_bounds }, + { 1287, "i8tooid", 1, true, false, i8tooid }, + { 1288, "oidtoi8", 1, true, false, oidtoi8 }, + { 1289, "quote_nullable", 1, false, false, quote_nullable }, + { 1291, "suppress_redundant_updates_trigger", 0, true, false, suppress_redundant_updates_trigger }, + { 1292, "tideq", 2, true, false, tideq }, + { 1293, "currtid_byreloid", 2, true, false, currtid_byreloid }, + { 1294, "currtid_byrelname", 2, true, false, currtid_byrelname }, + { 1295, "interval_justify_days", 1, true, false, interval_justify_days }, + { 1297, "datetimetz_timestamptz", 2, true, false, datetimetz_timestamptz }, + { 1299, "now", 0, true, false, now }, + { 1300, "positionsel", 4, true, false, positionsel }, + { 1301, "positionjoinsel", 5, true, false, positionjoinsel }, + { 1302, "contsel", 4, true, false, contsel }, + { 1303, "contjoinsel", 5, true, false, contjoinsel }, + { 1304, "overlaps_timestamp", 4, false, false, overlaps_timestamp }, + { 1308, "overlaps_time", 4, false, false, overlaps_time }, + { 1312, "timestamp_in", 3, true, false, timestamp_in }, + { 1313, "timestamp_out", 1, true, false, timestamp_out }, + { 1314, "timestamp_cmp", 2, true, false, timestamp_cmp }, + { 1315, "interval_cmp", 2, true, false, interval_cmp }, + { 1316, "timestamp_time", 1, true, false, timestamp_time }, + { 1317, "textlen", 1, true, false, textlen }, + { 1318, "bpcharlen", 1, true, false, bpcharlen }, + { 1319, "xideq", 2, true, false, xideq }, + { 1326, "interval_div", 2, true, false, interval_div }, + { 1339, "dlog10", 1, true, false, dlog10 }, + { 1340, "dlog10", 1, true, false, dlog10 }, + { 1341, "dlog1", 1, true, false, dlog1 }, + { 1342, "dround", 1, true, false, dround }, + { 1343, "dtrunc", 1, true, false, dtrunc }, + { 1344, "dsqrt", 1, true, false, dsqrt }, + { 1345, "dcbrt", 1, true, false, dcbrt }, + { 1346, "dpow", 2, true, false, dpow }, + { 1347, "dexp", 1, true, false, dexp }, + { 1349, "oidvectortypes", 1, true, false, oidvectortypes }, + { 1350, "timetz_in", 3, true, false, timetz_in }, + { 1351, "timetz_out", 1, true, false, timetz_out }, + { 1352, "timetz_eq", 2, true, false, timetz_eq }, + { 1353, "timetz_ne", 2, true, false, timetz_ne }, + { 1354, "timetz_lt", 2, true, false, timetz_lt }, + { 1355, "timetz_le", 2, true, false, timetz_le }, + { 1356, "timetz_ge", 2, true, false, timetz_ge }, + { 1357, "timetz_gt", 2, true, false, timetz_gt }, + { 1358, "timetz_cmp", 2, true, false, timetz_cmp }, + { 1359, "datetimetz_timestamptz", 2, true, false, datetimetz_timestamptz }, + { 1362, "network_hostmask", 1, true, false, network_hostmask }, + { 1365, "makeaclitem", 4, true, false, makeaclitem }, + { 1367, "bpcharlen", 1, true, false, bpcharlen }, + { 1368, "dpow", 2, true, false, dpow }, + { 1369, "textlen", 1, true, false, textlen }, + { 1370, "time_interval", 1, true, false, time_interval }, + { 1371, "pg_lock_status", 0, true, true, pg_lock_status }, + { 1372, "bpcharlen", 1, true, false, bpcharlen }, + { 1373, "date_finite", 1, true, false, date_finite }, + { 1374, "textoctetlen", 1, true, false, textoctetlen }, + { 1375, "bpcharoctetlen", 1, true, false, bpcharoctetlen }, + { 1376, "numeric_fac", 1, true, false, numeric_fac }, + { 1377, "time_larger", 2, true, false, time_larger }, + { 1378, "time_smaller", 2, true, false, time_smaller }, + { 1379, "timetz_larger", 2, true, false, timetz_larger }, + { 1380, "timetz_smaller", 2, true, false, timetz_smaller }, + { 1381, "textlen", 1, true, false, textlen }, + { 1385, "time_part", 2, true, false, time_part }, + { 1387, "pg_get_constraintdef", 1, true, false, pg_get_constraintdef }, + { 1388, "timestamptz_timetz", 1, true, false, timestamptz_timetz }, + { 1389, "timestamp_finite", 1, true, false, timestamp_finite }, + { 1390, "interval_finite", 1, true, false, interval_finite }, + { 1391, "pg_stat_get_backend_start", 1, true, false, pg_stat_get_backend_start }, + { 1392, "pg_stat_get_backend_client_addr", 1, true, false, pg_stat_get_backend_client_addr }, + { 1393, "pg_stat_get_backend_client_port", 1, true, false, pg_stat_get_backend_client_port }, + { 1394, "float4abs", 1, true, false, float4abs }, + { 1395, "float8abs", 1, true, false, float8abs }, + { 1396, "int8abs", 1, true, false, int8abs }, + { 1397, "int4abs", 1, true, false, int4abs }, + { 1398, "int2abs", 1, true, false, int2abs }, + { 1400, "text_name", 1, true, false, text_name }, + { 1401, "name_text", 1, true, false, name_text }, + { 1402, "current_schema", 0, true, false, current_schema }, + { 1403, "current_schemas", 1, true, false, current_schemas }, + { 1404, "textoverlay", 4, true, false, textoverlay }, + { 1405, "textoverlay_no_len", 3, true, false, textoverlay_no_len }, + { 1406, "point_vert", 2, true, false, point_vert }, + { 1407, "point_horiz", 2, true, false, point_horiz }, + { 1408, "lseg_parallel", 2, true, false, lseg_parallel }, + { 1409, "lseg_perp", 2, true, false, lseg_perp }, + { 1410, "lseg_vertical", 1, true, false, lseg_vertical }, + { 1411, "lseg_horizontal", 1, true, false, lseg_horizontal }, + { 1412, "line_parallel", 2, true, false, line_parallel }, + { 1413, "line_perp", 2, true, false, line_perp }, + { 1414, "line_vertical", 1, true, false, line_vertical }, + { 1415, "line_horizontal", 1, true, false, line_horizontal }, + { 1416, "circle_center", 1, true, false, circle_center }, + { 1419, "interval_time", 1, true, false, interval_time }, + { 1421, "points_box", 2, true, false, points_box }, + { 1422, "box_add", 2, true, false, box_add }, + { 1423, "box_sub", 2, true, false, box_sub }, + { 1424, "box_mul", 2, true, false, box_mul }, + { 1425, "box_div", 2, true, false, box_div }, + { 1427, "cidr_out", 1, true, false, cidr_out }, + { 1428, "poly_contain_pt", 2, true, false, poly_contain_pt }, + { 1429, "pt_contained_poly", 2, true, false, pt_contained_poly }, + { 1430, "path_isclosed", 1, true, false, path_isclosed }, + { 1431, "path_isopen", 1, true, false, path_isopen }, + { 1432, "path_npoints", 1, true, false, path_npoints }, + { 1433, "path_close", 1, true, false, path_close }, + { 1434, "path_open", 1, true, false, path_open }, + { 1435, "path_add", 2, true, false, path_add }, + { 1436, "path_add_pt", 2, true, false, path_add_pt }, + { 1437, "path_sub_pt", 2, true, false, path_sub_pt }, + { 1438, "path_mul_pt", 2, true, false, path_mul_pt }, + { 1439, "path_div_pt", 2, true, false, path_div_pt }, + { 1440, "construct_point", 2, true, false, construct_point }, + { 1441, "point_add", 2, true, false, point_add }, + { 1442, "point_sub", 2, true, false, point_sub }, + { 1443, "point_mul", 2, true, false, point_mul }, + { 1444, "point_div", 2, true, false, point_div }, + { 1445, "poly_npoints", 1, true, false, poly_npoints }, + { 1446, "poly_box", 1, true, false, poly_box }, + { 1447, "poly_path", 1, true, false, poly_path }, + { 1448, "box_poly", 1, true, false, box_poly }, + { 1449, "path_poly", 1, true, false, path_poly }, + { 1450, "circle_in", 1, true, false, circle_in }, + { 1451, "circle_out", 1, true, false, circle_out }, + { 1452, "circle_same", 2, true, false, circle_same }, + { 1453, "circle_contain", 2, true, false, circle_contain }, + { 1454, "circle_left", 2, true, false, circle_left }, + { 1455, "circle_overleft", 2, true, false, circle_overleft }, + { 1456, "circle_overright", 2, true, false, circle_overright }, + { 1457, "circle_right", 2, true, false, circle_right }, + { 1458, "circle_contained", 2, true, false, circle_contained }, + { 1459, "circle_overlap", 2, true, false, circle_overlap }, + { 1460, "circle_below", 2, true, false, circle_below }, + { 1461, "circle_above", 2, true, false, circle_above }, + { 1462, "circle_eq", 2, true, false, circle_eq }, + { 1463, "circle_ne", 2, true, false, circle_ne }, + { 1464, "circle_lt", 2, true, false, circle_lt }, + { 1465, "circle_gt", 2, true, false, circle_gt }, + { 1466, "circle_le", 2, true, false, circle_le }, + { 1467, "circle_ge", 2, true, false, circle_ge }, + { 1468, "circle_area", 1, true, false, circle_area }, + { 1469, "circle_diameter", 1, true, false, circle_diameter }, + { 1470, "circle_radius", 1, true, false, circle_radius }, + { 1471, "circle_distance", 2, true, false, circle_distance }, + { 1472, "circle_center", 1, true, false, circle_center }, + { 1473, "cr_circle", 2, true, false, cr_circle }, + { 1474, "poly_circle", 1, true, false, poly_circle }, + { 1475, "circle_poly", 2, true, false, circle_poly }, + { 1476, "dist_pc", 2, true, false, dist_pc }, + { 1477, "circle_contain_pt", 2, true, false, circle_contain_pt }, + { 1478, "pt_contained_circle", 2, true, false, pt_contained_circle }, + { 1479, "box_circle", 1, true, false, box_circle }, + { 1480, "circle_box", 1, true, false, circle_box }, + { 1481, "mktinterval", 2, true, false, mktinterval }, + { 1482, "lseg_ne", 2, true, false, lseg_ne }, + { 1483, "lseg_lt", 2, true, false, lseg_lt }, + { 1484, "lseg_le", 2, true, false, lseg_le }, + { 1485, "lseg_gt", 2, true, false, lseg_gt }, + { 1486, "lseg_ge", 2, true, false, lseg_ge }, + { 1487, "lseg_length", 1, true, false, lseg_length }, + { 1488, "close_ls", 2, true, false, close_ls }, + { 1489, "close_lseg", 2, true, false, close_lseg }, + { 1490, "line_in", 1, true, false, line_in }, + { 1491, "line_out", 1, true, false, line_out }, + { 1492, "line_eq", 2, true, false, line_eq }, + { 1493, "line_construct_pp", 2, true, false, line_construct_pp }, + { 1494, "line_interpt", 2, true, false, line_interpt }, + { 1495, "line_intersect", 2, true, false, line_intersect }, + { 1496, "line_parallel", 2, true, false, line_parallel }, + { 1497, "line_perp", 2, true, false, line_perp }, + { 1498, "line_vertical", 1, true, false, line_vertical }, + { 1499, "line_horizontal", 1, true, false, line_horizontal }, + { 1530, "lseg_length", 1, true, false, lseg_length }, + { 1531, "path_length", 1, true, false, path_length }, + { 1532, "lseg_center", 1, true, false, lseg_center }, + { 1533, "path_center", 1, true, false, path_center }, + { 1534, "box_center", 1, true, false, box_center }, + { 1540, "poly_center", 1, true, false, poly_center }, + { 1541, "box_diagonal", 1, true, false, box_diagonal }, + { 1542, "box_center", 1, true, false, box_center }, + { 1543, "circle_center", 1, true, false, circle_center }, + { 1545, "path_npoints", 1, true, false, path_npoints }, + { 1556, "poly_npoints", 1, true, false, poly_npoints }, + { 1564, "bit_in", 3, true, false, bit_in }, + { 1565, "bit_out", 1, true, false, bit_out }, + { 1569, "textlike", 2, true, false, textlike }, + { 1570, "textnlike", 2, true, false, textnlike }, + { 1571, "namelike", 2, true, false, namelike }, + { 1572, "namenlike", 2, true, false, namenlike }, + { 1573, "pg_get_ruledef", 1, true, false, pg_get_ruledef }, + { 1574, "nextval_oid", 1, true, false, nextval_oid }, + { 1575, "currval_oid", 1, true, false, currval_oid }, + { 1576, "setval_oid", 2, true, false, setval_oid }, + { 1579, "varbit_in", 3, true, false, varbit_in }, + { 1580, "varbit_out", 1, true, false, varbit_out }, + { 1581, "biteq", 2, true, false, biteq }, + { 1582, "bitne", 2, true, false, bitne }, + { 1592, "bitge", 2, true, false, bitge }, + { 1593, "bitgt", 2, true, false, bitgt }, + { 1594, "bitle", 2, true, false, bitle }, + { 1595, "bitlt", 2, true, false, bitlt }, + { 1596, "bitcmp", 2, true, false, bitcmp }, + { 1597, "PG_encoding_to_char", 1, true, false, PG_encoding_to_char }, + { 1598, "drandom", 0, true, false, drandom }, + { 1599, "setseed", 1, true, false, setseed }, + { 1600, "dasin", 1, true, false, dasin }, + { 1601, "dacos", 1, true, false, dacos }, + { 1602, "datan", 1, true, false, datan }, + { 1603, "datan2", 2, true, false, datan2 }, + { 1604, "dsin", 1, true, false, dsin }, + { 1605, "dcos", 1, true, false, dcos }, + { 1606, "dtan", 1, true, false, dtan }, + { 1607, "dcot", 1, true, false, dcot }, + { 1608, "degrees", 1, true, false, degrees }, + { 1609, "radians", 1, true, false, radians }, + { 1610, "dpi", 0, true, false, dpi }, + { 1618, "interval_mul", 2, true, false, interval_mul }, + { 1619, "pg_typeof", 1, false, false, pg_typeof }, + { 1620, "ascii", 1, true, false, ascii }, + { 1621, "chr", 1, true, false, chr }, + { 1622, "repeat", 2, true, false, repeat }, + { 1623, "similar_escape", 2, false, false, similar_escape }, + { 1624, "mul_d_interval", 2, true, false, mul_d_interval }, + { 1631, "textlike", 2, true, false, textlike }, + { 1632, "textnlike", 2, true, false, textnlike }, + { 1633, "texticlike", 2, true, false, texticlike }, + { 1634, "texticnlike", 2, true, false, texticnlike }, + { 1635, "nameiclike", 2, true, false, nameiclike }, + { 1636, "nameicnlike", 2, true, false, nameicnlike }, + { 1637, "like_escape", 2, true, false, like_escape }, + { 1638, "oidgt", 2, true, false, oidgt }, + { 1639, "oidge", 2, true, false, oidge }, + { 1640, "pg_get_viewdef_name", 1, true, false, pg_get_viewdef_name }, + { 1641, "pg_get_viewdef", 1, true, false, pg_get_viewdef }, + { 1642, "pg_get_userbyid", 1, true, false, pg_get_userbyid }, + { 1643, "pg_get_indexdef", 1, true, false, pg_get_indexdef }, + { 1644, "RI_FKey_check_ins", 0, true, false, RI_FKey_check_ins }, + { 1645, "RI_FKey_check_upd", 0, true, false, RI_FKey_check_upd }, + { 1646, "RI_FKey_cascade_del", 0, true, false, RI_FKey_cascade_del }, + { 1647, "RI_FKey_cascade_upd", 0, true, false, RI_FKey_cascade_upd }, + { 1648, "RI_FKey_restrict_del", 0, true, false, RI_FKey_restrict_del }, + { 1649, "RI_FKey_restrict_upd", 0, true, false, RI_FKey_restrict_upd }, + { 1650, "RI_FKey_setnull_del", 0, true, false, RI_FKey_setnull_del }, + { 1651, "RI_FKey_setnull_upd", 0, true, false, RI_FKey_setnull_upd }, + { 1652, "RI_FKey_setdefault_del", 0, true, false, RI_FKey_setdefault_del }, + { 1653, "RI_FKey_setdefault_upd", 0, true, false, RI_FKey_setdefault_upd }, + { 1654, "RI_FKey_noaction_del", 0, true, false, RI_FKey_noaction_del }, + { 1655, "RI_FKey_noaction_upd", 0, true, false, RI_FKey_noaction_upd }, + { 1656, "texticregexeq", 2, true, false, texticregexeq }, + { 1657, "texticregexne", 2, true, false, texticregexne }, + { 1658, "textregexeq", 2, true, false, textregexeq }, + { 1659, "textregexne", 2, true, false, textregexne }, + { 1660, "texticlike", 2, true, false, texticlike }, + { 1661, "texticnlike", 2, true, false, texticnlike }, + { 1662, "pg_get_triggerdef", 1, true, false, pg_get_triggerdef }, + { 1665, "pg_get_serial_sequence", 2, true, false, pg_get_serial_sequence }, + { 1666, "biteq", 2, true, false, biteq }, + { 1667, "bitne", 2, true, false, bitne }, + { 1668, "bitge", 2, true, false, bitge }, + { 1669, "bitgt", 2, true, false, bitgt }, + { 1670, "bitle", 2, true, false, bitle }, + { 1671, "bitlt", 2, true, false, bitlt }, + { 1672, "bitcmp", 2, true, false, bitcmp }, + { 1673, "bit_and", 2, true, false, bit_and }, + { 1674, "bit_or", 2, true, false, bit_or }, + { 1675, "bitxor", 2, true, false, bitxor }, + { 1676, "bitnot", 1, true, false, bitnot }, + { 1677, "bitshiftleft", 2, true, false, bitshiftleft }, + { 1678, "bitshiftright", 2, true, false, bitshiftright }, + { 1679, "bitcat", 2, true, false, bitcat }, + { 1680, "bitsubstr", 3, true, false, bitsubstr }, + { 1681, "bitlength", 1, true, false, bitlength }, + { 1682, "bitoctetlength", 1, true, false, bitoctetlength }, + { 1683, "bitfromint4", 2, true, false, bitfromint4 }, + { 1684, "bittoint4", 1, true, false, bittoint4 }, + { 1685, "bit", 3, true, false, bit }, + { 1686, "pg_get_keywords", 0, true, true, pg_get_keywords }, + { 1687, "varbit", 3, true, false, varbit }, + { 1688, "time_hash", 1, true, false, time_hash }, + { 1689, "aclexplode", 1, true, true, aclexplode }, + { 1690, "time_mi_time", 2, true, false, time_mi_time }, + { 1691, "boolle", 2, true, false, boolle }, + { 1692, "boolge", 2, true, false, boolge }, + { 1693, "btboolcmp", 2, true, false, btboolcmp }, + { 1696, "timetz_hash", 1, true, false, timetz_hash }, + { 1697, "interval_hash", 1, true, false, interval_hash }, + { 1698, "bitposition", 2, true, false, bitposition }, + { 1699, "bitsubstr_no_len", 2, true, false, bitsubstr_no_len }, + { 1701, "numeric_in", 3, true, false, numeric_in }, + { 1702, "numeric_out", 1, true, false, numeric_out }, + { 1703, "numeric", 2, true, false, numeric }, + { 1704, "numeric_abs", 1, true, false, numeric_abs }, + { 1705, "numeric_abs", 1, true, false, numeric_abs }, + { 1706, "numeric_sign", 1, true, false, numeric_sign }, + { 1707, "numeric_round", 2, true, false, numeric_round }, + { 1709, "numeric_trunc", 2, true, false, numeric_trunc }, + { 1711, "numeric_ceil", 1, true, false, numeric_ceil }, + { 1712, "numeric_floor", 1, true, false, numeric_floor }, + { 1713, "length_in_encoding", 2, true, false, length_in_encoding }, + { 1714, "pg_convert_from", 2, true, false, pg_convert_from }, + { 1715, "inet_to_cidr", 1, true, false, inet_to_cidr }, + { 1716, "pg_get_expr", 2, true, false, pg_get_expr }, + { 1717, "pg_convert_to", 2, true, false, pg_convert_to }, + { 1718, "numeric_eq", 2, true, false, numeric_eq }, + { 1719, "numeric_ne", 2, true, false, numeric_ne }, + { 1720, "numeric_gt", 2, true, false, numeric_gt }, + { 1721, "numeric_ge", 2, true, false, numeric_ge }, + { 1722, "numeric_lt", 2, true, false, numeric_lt }, + { 1723, "numeric_le", 2, true, false, numeric_le }, + { 1724, "numeric_add", 2, true, false, numeric_add }, + { 1725, "numeric_sub", 2, true, false, numeric_sub }, + { 1726, "numeric_mul", 2, true, false, numeric_mul }, + { 1727, "numeric_div", 2, true, false, numeric_div }, + { 1728, "numeric_mod", 2, true, false, numeric_mod }, + { 1729, "numeric_mod", 2, true, false, numeric_mod }, + { 1730, "numeric_sqrt", 1, true, false, numeric_sqrt }, + { 1731, "numeric_sqrt", 1, true, false, numeric_sqrt }, + { 1732, "numeric_exp", 1, true, false, numeric_exp }, + { 1733, "numeric_exp", 1, true, false, numeric_exp }, + { 1734, "numeric_ln", 1, true, false, numeric_ln }, + { 1735, "numeric_ln", 1, true, false, numeric_ln }, + { 1736, "numeric_log", 2, true, false, numeric_log }, + { 1737, "numeric_log", 2, true, false, numeric_log }, + { 1738, "numeric_power", 2, true, false, numeric_power }, + { 1739, "numeric_power", 2, true, false, numeric_power }, + { 1740, "int4_numeric", 1, true, false, int4_numeric }, + { 1742, "float4_numeric", 1, true, false, float4_numeric }, + { 1743, "float8_numeric", 1, true, false, float8_numeric }, + { 1744, "numeric_int4", 1, true, false, numeric_int4 }, + { 1745, "numeric_float4", 1, true, false, numeric_float4 }, + { 1746, "numeric_float8", 1, true, false, numeric_float8 }, + { 1747, "time_pl_interval", 2, true, false, time_pl_interval }, + { 1748, "time_mi_interval", 2, true, false, time_mi_interval }, + { 1749, "timetz_pl_interval", 2, true, false, timetz_pl_interval }, + { 1750, "timetz_mi_interval", 2, true, false, timetz_mi_interval }, + { 1764, "numeric_inc", 1, true, false, numeric_inc }, + { 1765, "setval3_oid", 3, true, false, setval3_oid }, + { 1766, "numeric_smaller", 2, true, false, numeric_smaller }, + { 1767, "numeric_larger", 2, true, false, numeric_larger }, + { 1768, "interval_to_char", 2, true, false, interval_to_char }, + { 1769, "numeric_cmp", 2, true, false, numeric_cmp }, + { 1770, "timestamptz_to_char", 2, true, false, timestamptz_to_char }, + { 1771, "numeric_uminus", 1, true, false, numeric_uminus }, + { 1772, "numeric_to_char", 2, true, false, numeric_to_char }, + { 1773, "int4_to_char", 2, true, false, int4_to_char }, + { 1774, "int8_to_char", 2, true, false, int8_to_char }, + { 1775, "float4_to_char", 2, true, false, float4_to_char }, + { 1776, "float8_to_char", 2, true, false, float8_to_char }, + { 1777, "numeric_to_number", 2, true, false, numeric_to_number }, + { 1778, "to_timestamp", 2, true, false, to_timestamp }, + { 1779, "numeric_int8", 1, true, false, numeric_int8 }, + { 1780, "to_date", 2, true, false, to_date }, + { 1781, "int8_numeric", 1, true, false, int8_numeric }, + { 1782, "int2_numeric", 1, true, false, int2_numeric }, + { 1783, "numeric_int2", 1, true, false, numeric_int2 }, + { 1798, "oidin", 1, true, false, oidin }, + { 1799, "oidout", 1, true, false, oidout }, + { 1813, "pg_convert", 3, true, false, pg_convert }, + { 1814, "iclikesel", 4, true, false, iclikesel }, + { 1815, "icnlikesel", 4, true, false, icnlikesel }, + { 1816, "iclikejoinsel", 5, true, false, iclikejoinsel }, + { 1817, "icnlikejoinsel", 5, true, false, icnlikejoinsel }, + { 1818, "regexeqsel", 4, true, false, regexeqsel }, + { 1819, "likesel", 4, true, false, likesel }, + { 1820, "icregexeqsel", 4, true, false, icregexeqsel }, + { 1821, "regexnesel", 4, true, false, regexnesel }, + { 1822, "nlikesel", 4, true, false, nlikesel }, + { 1823, "icregexnesel", 4, true, false, icregexnesel }, + { 1824, "regexeqjoinsel", 5, true, false, regexeqjoinsel }, + { 1825, "likejoinsel", 5, true, false, likejoinsel }, + { 1826, "icregexeqjoinsel", 5, true, false, icregexeqjoinsel }, + { 1827, "regexnejoinsel", 5, true, false, regexnejoinsel }, + { 1828, "nlikejoinsel", 5, true, false, nlikejoinsel }, + { 1829, "icregexnejoinsel", 5, true, false, icregexnejoinsel }, + { 1830, "float8_avg", 1, true, false, float8_avg }, + { 1831, "float8_var_samp", 1, true, false, float8_var_samp }, + { 1832, "float8_stddev_samp", 1, true, false, float8_stddev_samp }, + { 1833, "numeric_accum", 2, true, false, numeric_accum }, + { 1834, "int2_accum", 2, true, false, int2_accum }, + { 1835, "int4_accum", 2, true, false, int4_accum }, + { 1836, "int8_accum", 2, true, false, int8_accum }, + { 1837, "numeric_avg", 1, true, false, numeric_avg }, + { 1838, "numeric_var_samp", 1, true, false, numeric_var_samp }, + { 1839, "numeric_stddev_samp", 1, true, false, numeric_stddev_samp }, + { 1840, "int2_sum", 2, false, false, int2_sum }, + { 1841, "int4_sum", 2, false, false, int4_sum }, + { 1842, "int8_sum", 2, false, false, int8_sum }, + { 1843, "interval_accum", 2, true, false, interval_accum }, + { 1844, "interval_avg", 1, true, false, interval_avg }, + { 1845, "to_ascii_default", 1, true, false, to_ascii_default }, + { 1846, "to_ascii_enc", 2, true, false, to_ascii_enc }, + { 1847, "to_ascii_encname", 2, true, false, to_ascii_encname }, + { 1850, "int28eq", 2, true, false, int28eq }, + { 1851, "int28ne", 2, true, false, int28ne }, + { 1852, "int28lt", 2, true, false, int28lt }, + { 1853, "int28gt", 2, true, false, int28gt }, + { 1854, "int28le", 2, true, false, int28le }, + { 1855, "int28ge", 2, true, false, int28ge }, + { 1856, "int82eq", 2, true, false, int82eq }, + { 1857, "int82ne", 2, true, false, int82ne }, + { 1858, "int82lt", 2, true, false, int82lt }, + { 1859, "int82gt", 2, true, false, int82gt }, + { 1860, "int82le", 2, true, false, int82le }, + { 1861, "int82ge", 2, true, false, int82ge }, + { 1892, "int2and", 2, true, false, int2and }, + { 1893, "int2or", 2, true, false, int2or }, + { 1894, "int2xor", 2, true, false, int2xor }, + { 1895, "int2not", 1, true, false, int2not }, + { 1896, "int2shl", 2, true, false, int2shl }, + { 1897, "int2shr", 2, true, false, int2shr }, + { 1898, "int4and", 2, true, false, int4and }, + { 1899, "int4or", 2, true, false, int4or }, + { 1900, "int4xor", 2, true, false, int4xor }, + { 1901, "int4not", 1, true, false, int4not }, + { 1902, "int4shl", 2, true, false, int4shl }, + { 1903, "int4shr", 2, true, false, int4shr }, + { 1904, "int8and", 2, true, false, int8and }, + { 1905, "int8or", 2, true, false, int8or }, + { 1906, "int8xor", 2, true, false, int8xor }, + { 1907, "int8not", 1, true, false, int8not }, + { 1908, "int8shl", 2, true, false, int8shl }, + { 1909, "int8shr", 2, true, false, int8shr }, + { 1910, "int8up", 1, true, false, int8up }, + { 1911, "int2up", 1, true, false, int2up }, + { 1912, "int4up", 1, true, false, int4up }, + { 1913, "float4up", 1, true, false, float4up }, + { 1914, "float8up", 1, true, false, float8up }, + { 1915, "numeric_uplus", 1, true, false, numeric_uplus }, + { 1922, "has_table_privilege_name_name", 3, true, false, has_table_privilege_name_name }, + { 1923, "has_table_privilege_name_id", 3, true, false, has_table_privilege_name_id }, + { 1924, "has_table_privilege_id_name", 3, true, false, has_table_privilege_id_name }, + { 1925, "has_table_privilege_id_id", 3, true, false, has_table_privilege_id_id }, + { 1926, "has_table_privilege_name", 2, true, false, has_table_privilege_name }, + { 1927, "has_table_privilege_id", 2, true, false, has_table_privilege_id }, + { 1928, "pg_stat_get_numscans", 1, true, false, pg_stat_get_numscans }, + { 1929, "pg_stat_get_tuples_returned", 1, true, false, pg_stat_get_tuples_returned }, + { 1930, "pg_stat_get_tuples_fetched", 1, true, false, pg_stat_get_tuples_fetched }, + { 1931, "pg_stat_get_tuples_inserted", 1, true, false, pg_stat_get_tuples_inserted }, + { 1932, "pg_stat_get_tuples_updated", 1, true, false, pg_stat_get_tuples_updated }, + { 1933, "pg_stat_get_tuples_deleted", 1, true, false, pg_stat_get_tuples_deleted }, + { 1934, "pg_stat_get_blocks_fetched", 1, true, false, pg_stat_get_blocks_fetched }, + { 1935, "pg_stat_get_blocks_hit", 1, true, false, pg_stat_get_blocks_hit }, + { 1936, "pg_stat_get_backend_idset", 0, true, true, pg_stat_get_backend_idset }, + { 1937, "pg_stat_get_backend_pid", 1, true, false, pg_stat_get_backend_pid }, + { 1938, "pg_stat_get_backend_dbid", 1, true, false, pg_stat_get_backend_dbid }, + { 1939, "pg_stat_get_backend_userid", 1, true, false, pg_stat_get_backend_userid }, + { 1940, "pg_stat_get_backend_activity", 1, true, false, pg_stat_get_backend_activity }, + { 1941, "pg_stat_get_db_numbackends", 1, true, false, pg_stat_get_db_numbackends }, + { 1942, "pg_stat_get_db_xact_commit", 1, true, false, pg_stat_get_db_xact_commit }, + { 1943, "pg_stat_get_db_xact_rollback", 1, true, false, pg_stat_get_db_xact_rollback }, + { 1944, "pg_stat_get_db_blocks_fetched", 1, true, false, pg_stat_get_db_blocks_fetched }, + { 1945, "pg_stat_get_db_blocks_hit", 1, true, false, pg_stat_get_db_blocks_hit }, + { 1946, "binary_encode", 2, true, false, binary_encode }, + { 1947, "binary_decode", 2, true, false, binary_decode }, + { 1948, "byteaeq", 2, true, false, byteaeq }, + { 1949, "bytealt", 2, true, false, bytealt }, + { 1950, "byteale", 2, true, false, byteale }, + { 1951, "byteagt", 2, true, false, byteagt }, + { 1952, "byteage", 2, true, false, byteage }, + { 1953, "byteane", 2, true, false, byteane }, + { 1954, "byteacmp", 2, true, false, byteacmp }, + { 1961, "timestamp_scale", 2, true, false, timestamp_scale }, + { 1962, "int2_avg_accum", 2, true, false, int2_avg_accum }, + { 1963, "int4_avg_accum", 2, true, false, int4_avg_accum }, + { 1964, "int8_avg", 1, true, false, int8_avg }, + { 1965, "oidlarger", 2, true, false, oidlarger }, + { 1966, "oidsmaller", 2, true, false, oidsmaller }, + { 1967, "timestamptz_scale", 2, true, false, timestamptz_scale }, + { 1968, "time_scale", 2, true, false, time_scale }, + { 1969, "timetz_scale", 2, true, false, timetz_scale }, + { 1972, "pg_stat_get_tuples_hot_updated", 1, true, false, pg_stat_get_tuples_hot_updated }, + { 1973, "numeric_div_trunc", 2, true, false, numeric_div_trunc }, + { 1980, "numeric_div_trunc", 2, true, false, numeric_div_trunc }, + { 2005, "bytealike", 2, true, false, bytealike }, + { 2006, "byteanlike", 2, true, false, byteanlike }, + { 2007, "bytealike", 2, true, false, bytealike }, + { 2008, "byteanlike", 2, true, false, byteanlike }, + { 2009, "like_escape_bytea", 2, true, false, like_escape_bytea }, + { 2010, "byteaoctetlen", 1, true, false, byteaoctetlen }, + { 2011, "byteacat", 2, true, false, byteacat }, + { 2012, "bytea_substr", 3, true, false, bytea_substr }, + { 2013, "bytea_substr_no_len", 2, true, false, bytea_substr_no_len }, + { 2014, "byteapos", 2, true, false, byteapos }, + { 2015, "byteatrim", 2, true, false, byteatrim }, + { 2019, "timestamptz_time", 1, true, false, timestamptz_time }, + { 2020, "timestamp_trunc", 2, true, false, timestamp_trunc }, + { 2021, "timestamp_part", 2, true, false, timestamp_part }, + { 2022, "pg_stat_get_activity", 1, false, true, pg_stat_get_activity }, + { 2023, "abstime_timestamp", 1, true, false, abstime_timestamp }, + { 2024, "date_timestamp", 1, true, false, date_timestamp }, + { 2025, "datetime_timestamp", 2, true, false, datetime_timestamp }, + { 2026, "pg_backend_pid", 0, true, false, pg_backend_pid }, + { 2027, "timestamptz_timestamp", 1, true, false, timestamptz_timestamp }, + { 2028, "timestamp_timestamptz", 1, true, false, timestamp_timestamptz }, + { 2029, "timestamp_date", 1, true, false, timestamp_date }, + { 2030, "timestamp_abstime", 1, true, false, timestamp_abstime }, + { 2031, "timestamp_mi", 2, true, false, timestamp_mi }, + { 2032, "timestamp_pl_interval", 2, true, false, timestamp_pl_interval }, + { 2033, "timestamp_mi_interval", 2, true, false, timestamp_mi_interval }, + { 2034, "pg_conf_load_time", 0, true, false, pg_conf_load_time }, + { 2035, "timestamp_smaller", 2, true, false, timestamp_smaller }, + { 2036, "timestamp_larger", 2, true, false, timestamp_larger }, + { 2037, "timetz_zone", 2, true, false, timetz_zone }, + { 2038, "timetz_izone", 2, true, false, timetz_izone }, + { 2039, "timestamp_hash", 1, true, false, timestamp_hash }, + { 2041, "overlaps_timestamp", 4, false, false, overlaps_timestamp }, + { 2045, "timestamp_cmp", 2, true, false, timestamp_cmp }, + { 2046, "timetz_time", 1, true, false, timetz_time }, + { 2047, "time_timetz", 1, true, false, time_timetz }, + { 2048, "timestamp_finite", 1, true, false, timestamp_finite }, + { 2049, "timestamp_to_char", 2, true, false, timestamp_to_char }, + { 2050, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2051, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2052, "timestamp_eq", 2, true, false, timestamp_eq }, + { 2053, "timestamp_ne", 2, true, false, timestamp_ne }, + { 2054, "timestamp_lt", 2, true, false, timestamp_lt }, + { 2055, "timestamp_le", 2, true, false, timestamp_le }, + { 2056, "timestamp_ge", 2, true, false, timestamp_ge }, + { 2057, "timestamp_gt", 2, true, false, timestamp_gt }, + { 2058, "timestamp_age", 2, true, false, timestamp_age }, + { 2069, "timestamp_zone", 2, true, false, timestamp_zone }, + { 2070, "timestamp_izone", 2, true, false, timestamp_izone }, + { 2071, "date_pl_interval", 2, true, false, date_pl_interval }, + { 2072, "date_mi_interval", 2, true, false, date_mi_interval }, + { 2073, "textregexsubstr", 2, true, false, textregexsubstr }, + { 2075, "bitfromint8", 2, true, false, bitfromint8 }, + { 2076, "bittoint8", 1, true, false, bittoint8 }, + { 2077, "show_config_by_name", 1, true, false, show_config_by_name }, + { 2078, "set_config_by_name", 3, false, false, set_config_by_name }, + { 2079, "pg_table_is_visible", 1, true, false, pg_table_is_visible }, + { 2080, "pg_type_is_visible", 1, true, false, pg_type_is_visible }, + { 2081, "pg_function_is_visible", 1, true, false, pg_function_is_visible }, + { 2082, "pg_operator_is_visible", 1, true, false, pg_operator_is_visible }, + { 2083, "pg_opclass_is_visible", 1, true, false, pg_opclass_is_visible }, + { 2084, "show_all_settings", 0, true, true, show_all_settings }, + { 2085, "bytea_substr", 3, true, false, bytea_substr }, + { 2086, "bytea_substr_no_len", 2, true, false, bytea_substr_no_len }, + { 2087, "replace_text", 3, true, false, replace_text }, + { 2088, "split_text", 3, true, false, split_text }, + { 2089, "to_hex32", 1, true, false, to_hex32 }, + { 2090, "to_hex64", 1, true, false, to_hex64 }, + { 2091, "array_lower", 2, true, false, array_lower }, + { 2092, "array_upper", 2, true, false, array_upper }, + { 2093, "pg_conversion_is_visible", 1, true, false, pg_conversion_is_visible }, + { 2094, "pg_stat_get_backend_activity_start", 1, true, false, pg_stat_get_backend_activity_start }, + { 2096, "pg_terminate_backend", 1, true, false, pg_terminate_backend }, + { 2098, "pg_get_functiondef", 1, true, false, pg_get_functiondef }, + { 2100, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2101, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2102, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2103, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2104, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2105, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2106, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2107, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2108, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2109, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2110, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2111, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2112, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2113, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2114, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2115, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2116, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2117, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2118, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2119, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2120, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2121, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2122, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2123, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2124, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2125, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2126, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2127, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2128, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2129, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2130, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2131, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2132, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2133, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2134, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2135, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2136, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2137, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2138, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2139, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2140, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2141, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2142, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2143, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2144, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2145, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2146, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2147, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2148, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2149, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2150, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2151, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2152, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2153, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2154, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2155, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2156, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2157, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2158, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2159, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2160, "text_pattern_lt", 2, true, false, text_pattern_lt }, + { 2161, "text_pattern_le", 2, true, false, text_pattern_le }, + { 2162, "pg_get_function_arguments", 1, true, false, pg_get_function_arguments }, + { 2163, "text_pattern_ge", 2, true, false, text_pattern_ge }, + { 2164, "text_pattern_gt", 2, true, false, text_pattern_gt }, + { 2165, "pg_get_function_result", 1, true, false, pg_get_function_result }, + { 2166, "bttext_pattern_cmp", 2, true, false, bttext_pattern_cmp }, + { 2167, "numeric_ceil", 1, true, false, numeric_ceil }, + { 2168, "pg_database_size_name", 1, true, false, pg_database_size_name }, + { 2169, "numeric_power", 2, true, false, numeric_power }, + { 2170, "width_bucket_numeric", 4, true, false, width_bucket_numeric }, + { 2171, "pg_cancel_backend", 1, true, false, pg_cancel_backend }, + { 2172, "pg_start_backup", 2, true, false, pg_start_backup }, + { 2173, "pg_stop_backup", 0, true, false, pg_stop_backup }, + { 2174, "bpchar_pattern_lt", 2, true, false, bpchar_pattern_lt }, + { 2175, "bpchar_pattern_le", 2, true, false, bpchar_pattern_le }, + { 2176, "array_length", 2, true, false, array_length }, + { 2177, "bpchar_pattern_ge", 2, true, false, bpchar_pattern_ge }, + { 2178, "bpchar_pattern_gt", 2, true, false, bpchar_pattern_gt }, + { 2179, "gist_point_consistent", 5, true, false, gist_point_consistent }, + { 2180, "btbpchar_pattern_cmp", 2, true, false, btbpchar_pattern_cmp }, + { 2181, "has_sequence_privilege_name_name", 3, true, false, has_sequence_privilege_name_name }, + { 2182, "has_sequence_privilege_name_id", 3, true, false, has_sequence_privilege_name_id }, + { 2183, "has_sequence_privilege_id_name", 3, true, false, has_sequence_privilege_id_name }, + { 2184, "has_sequence_privilege_id_id", 3, true, false, has_sequence_privilege_id_id }, + { 2185, "has_sequence_privilege_name", 2, true, false, has_sequence_privilege_name }, + { 2186, "has_sequence_privilege_id", 2, true, false, has_sequence_privilege_id }, + { 2188, "btint48cmp", 2, true, false, btint48cmp }, + { 2189, "btint84cmp", 2, true, false, btint84cmp }, + { 2190, "btint24cmp", 2, true, false, btint24cmp }, + { 2191, "btint42cmp", 2, true, false, btint42cmp }, + { 2192, "btint28cmp", 2, true, false, btint28cmp }, + { 2193, "btint82cmp", 2, true, false, btint82cmp }, + { 2194, "btfloat48cmp", 2, true, false, btfloat48cmp }, + { 2195, "btfloat84cmp", 2, true, false, btfloat84cmp }, + { 2196, "inet_client_addr", 0, false, false, inet_client_addr }, + { 2197, "inet_client_port", 0, false, false, inet_client_port }, + { 2198, "inet_server_addr", 0, false, false, inet_server_addr }, + { 2199, "inet_server_port", 0, false, false, inet_server_port }, + { 2212, "regprocedurein", 1, true, false, regprocedurein }, + { 2213, "regprocedureout", 1, true, false, regprocedureout }, + { 2214, "regoperin", 1, true, false, regoperin }, + { 2215, "regoperout", 1, true, false, regoperout }, + { 2216, "regoperatorin", 1, true, false, regoperatorin }, + { 2217, "regoperatorout", 1, true, false, regoperatorout }, + { 2218, "regclassin", 1, true, false, regclassin }, + { 2219, "regclassout", 1, true, false, regclassout }, + { 2220, "regtypein", 1, true, false, regtypein }, + { 2221, "regtypeout", 1, true, false, regtypeout }, + { 2230, "pg_stat_clear_snapshot", 0, false, false, pg_stat_clear_snapshot }, + { 2232, "pg_get_function_identity_arguments", 1, true, false, pg_get_function_identity_arguments }, + { 2236, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2237, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2238, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2239, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2240, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2241, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2242, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2243, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2244, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2245, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2246, "fmgr_internal_validator", 1, true, false, fmgr_internal_validator }, + { 2247, "fmgr_c_validator", 1, true, false, fmgr_c_validator }, + { 2248, "fmgr_sql_validator", 1, true, false, fmgr_sql_validator }, + { 2250, "has_database_privilege_name_name", 3, true, false, has_database_privilege_name_name }, + { 2251, "has_database_privilege_name_id", 3, true, false, has_database_privilege_name_id }, + { 2252, "has_database_privilege_id_name", 3, true, false, has_database_privilege_id_name }, + { 2253, "has_database_privilege_id_id", 3, true, false, has_database_privilege_id_id }, + { 2254, "has_database_privilege_name", 2, true, false, has_database_privilege_name }, + { 2255, "has_database_privilege_id", 2, true, false, has_database_privilege_id }, + { 2256, "has_function_privilege_name_name", 3, true, false, has_function_privilege_name_name }, + { 2257, "has_function_privilege_name_id", 3, true, false, has_function_privilege_name_id }, + { 2258, "has_function_privilege_id_name", 3, true, false, has_function_privilege_id_name }, + { 2259, "has_function_privilege_id_id", 3, true, false, has_function_privilege_id_id }, + { 2260, "has_function_privilege_name", 2, true, false, has_function_privilege_name }, + { 2261, "has_function_privilege_id", 2, true, false, has_function_privilege_id }, + { 2262, "has_language_privilege_name_name", 3, true, false, has_language_privilege_name_name }, + { 2263, "has_language_privilege_name_id", 3, true, false, has_language_privilege_name_id }, + { 2264, "has_language_privilege_id_name", 3, true, false, has_language_privilege_id_name }, + { 2265, "has_language_privilege_id_id", 3, true, false, has_language_privilege_id_id }, + { 2266, "has_language_privilege_name", 2, true, false, has_language_privilege_name }, + { 2267, "has_language_privilege_id", 2, true, false, has_language_privilege_id }, + { 2268, "has_schema_privilege_name_name", 3, true, false, has_schema_privilege_name_name }, + { 2269, "has_schema_privilege_name_id", 3, true, false, has_schema_privilege_name_id }, + { 2270, "has_schema_privilege_id_name", 3, true, false, has_schema_privilege_id_name }, + { 2271, "has_schema_privilege_id_id", 3, true, false, has_schema_privilege_id_id }, + { 2272, "has_schema_privilege_name", 2, true, false, has_schema_privilege_name }, + { 2273, "has_schema_privilege_id", 2, true, false, has_schema_privilege_id }, + { 2274, "pg_stat_reset", 0, false, false, pg_stat_reset }, + { 2284, "textregexreplace_noopt", 3, true, false, textregexreplace_noopt }, + { 2285, "textregexreplace", 4, true, false, textregexreplace }, + { 2286, "pg_total_relation_size", 1, true, false, pg_total_relation_size }, + { 2288, "pg_size_pretty", 1, true, false, pg_size_pretty }, + { 2289, "pg_options_to_table", 1, true, true, pg_options_to_table }, + { 2290, "record_in", 3, true, false, record_in }, + { 2291, "record_out", 1, true, false, record_out }, + { 2292, "cstring_in", 1, true, false, cstring_in }, + { 2293, "cstring_out", 1, true, false, cstring_out }, + { 2294, "any_in", 1, true, false, any_in }, + { 2295, "any_out", 1, true, false, any_out }, + { 2296, "anyarray_in", 1, true, false, anyarray_in }, + { 2297, "anyarray_out", 1, true, false, anyarray_out }, + { 2298, "void_in", 1, true, false, void_in }, + { 2299, "void_out", 1, true, false, void_out }, + { 2300, "trigger_in", 1, false, false, trigger_in }, + { 2301, "trigger_out", 1, true, false, trigger_out }, + { 2302, "language_handler_in", 1, false, false, language_handler_in }, + { 2303, "language_handler_out", 1, true, false, language_handler_out }, + { 2304, "internal_in", 1, false, false, internal_in }, + { 2305, "internal_out", 1, true, false, internal_out }, + { 2306, "opaque_in", 1, false, false, opaque_in }, + { 2307, "opaque_out", 1, true, false, opaque_out }, + { 2308, "dceil", 1, true, false, dceil }, + { 2309, "dfloor", 1, true, false, dfloor }, + { 2310, "dsign", 1, true, false, dsign }, + { 2311, "md5_text", 1, true, false, md5_text }, + { 2312, "anyelement_in", 1, true, false, anyelement_in }, + { 2313, "anyelement_out", 1, true, false, anyelement_out }, + { 2316, "postgresql_fdw_validator", 2, true, false, postgresql_fdw_validator }, + { 2319, "pg_encoding_max_length_sql", 1, true, false, pg_encoding_max_length_sql }, + { 2320, "dceil", 1, true, false, dceil }, + { 2321, "md5_bytea", 1, true, false, md5_bytea }, + { 2322, "pg_tablespace_size_oid", 1, true, false, pg_tablespace_size_oid }, + { 2323, "pg_tablespace_size_name", 1, true, false, pg_tablespace_size_name }, + { 2324, "pg_database_size_oid", 1, true, false, pg_database_size_oid }, + { 2331, "array_unnest", 1, true, true, array_unnest }, + { 2332, "pg_relation_size", 2, true, false, pg_relation_size }, + { 2333, "array_agg_transfn", 2, false, false, array_agg_transfn }, + { 2334, "array_agg_finalfn", 1, false, false, array_agg_finalfn }, + { 2335, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2338, "date_lt_timestamp", 2, true, false, date_lt_timestamp }, + { 2339, "date_le_timestamp", 2, true, false, date_le_timestamp }, + { 2340, "date_eq_timestamp", 2, true, false, date_eq_timestamp }, + { 2341, "date_gt_timestamp", 2, true, false, date_gt_timestamp }, + { 2342, "date_ge_timestamp", 2, true, false, date_ge_timestamp }, + { 2343, "date_ne_timestamp", 2, true, false, date_ne_timestamp }, + { 2344, "date_cmp_timestamp", 2, true, false, date_cmp_timestamp }, + { 2351, "date_lt_timestamptz", 2, true, false, date_lt_timestamptz }, + { 2352, "date_le_timestamptz", 2, true, false, date_le_timestamptz }, + { 2353, "date_eq_timestamptz", 2, true, false, date_eq_timestamptz }, + { 2354, "date_gt_timestamptz", 2, true, false, date_gt_timestamptz }, + { 2355, "date_ge_timestamptz", 2, true, false, date_ge_timestamptz }, + { 2356, "date_ne_timestamptz", 2, true, false, date_ne_timestamptz }, + { 2357, "date_cmp_timestamptz", 2, true, false, date_cmp_timestamptz }, + { 2364, "timestamp_lt_date", 2, true, false, timestamp_lt_date }, + { 2365, "timestamp_le_date", 2, true, false, timestamp_le_date }, + { 2366, "timestamp_eq_date", 2, true, false, timestamp_eq_date }, + { 2367, "timestamp_gt_date", 2, true, false, timestamp_gt_date }, + { 2368, "timestamp_ge_date", 2, true, false, timestamp_ge_date }, + { 2369, "timestamp_ne_date", 2, true, false, timestamp_ne_date }, + { 2370, "timestamp_cmp_date", 2, true, false, timestamp_cmp_date }, + { 2377, "timestamptz_lt_date", 2, true, false, timestamptz_lt_date }, + { 2378, "timestamptz_le_date", 2, true, false, timestamptz_le_date }, + { 2379, "timestamptz_eq_date", 2, true, false, timestamptz_eq_date }, + { 2380, "timestamptz_gt_date", 2, true, false, timestamptz_gt_date }, + { 2381, "timestamptz_ge_date", 2, true, false, timestamptz_ge_date }, + { 2382, "timestamptz_ne_date", 2, true, false, timestamptz_ne_date }, + { 2383, "timestamptz_cmp_date", 2, true, false, timestamptz_cmp_date }, + { 2390, "has_tablespace_privilege_name_name", 3, true, false, has_tablespace_privilege_name_name }, + { 2391, "has_tablespace_privilege_name_id", 3, true, false, has_tablespace_privilege_name_id }, + { 2392, "has_tablespace_privilege_id_name", 3, true, false, has_tablespace_privilege_id_name }, + { 2393, "has_tablespace_privilege_id_id", 3, true, false, has_tablespace_privilege_id_id }, + { 2394, "has_tablespace_privilege_name", 2, true, false, has_tablespace_privilege_name }, + { 2395, "has_tablespace_privilege_id", 2, true, false, has_tablespace_privilege_id }, + { 2398, "shell_in", 1, false, false, shell_in }, + { 2399, "shell_out", 1, true, false, shell_out }, + { 2400, "array_recv", 3, true, false, array_recv }, + { 2401, "array_send", 1, true, false, array_send }, + { 2402, "record_recv", 3, true, false, record_recv }, + { 2403, "record_send", 1, true, false, record_send }, + { 2404, "int2recv", 1, true, false, int2recv }, + { 2405, "int2send", 1, true, false, int2send }, + { 2406, "int4recv", 1, true, false, int4recv }, + { 2407, "int4send", 1, true, false, int4send }, + { 2408, "int8recv", 1, true, false, int8recv }, + { 2409, "int8send", 1, true, false, int8send }, + { 2410, "int2vectorrecv", 1, true, false, int2vectorrecv }, + { 2411, "int2vectorsend", 1, true, false, int2vectorsend }, + { 2412, "bytearecv", 1, true, false, bytearecv }, + { 2413, "byteasend", 1, true, false, byteasend }, + { 2414, "textrecv", 1, true, false, textrecv }, + { 2415, "textsend", 1, true, false, textsend }, + { 2416, "unknownrecv", 1, true, false, unknownrecv }, + { 2417, "unknownsend", 1, true, false, unknownsend }, + { 2418, "oidrecv", 1, true, false, oidrecv }, + { 2419, "oidsend", 1, true, false, oidsend }, + { 2420, "oidvectorrecv", 1, true, false, oidvectorrecv }, + { 2421, "oidvectorsend", 1, true, false, oidvectorsend }, + { 2422, "namerecv", 1, true, false, namerecv }, + { 2423, "namesend", 1, true, false, namesend }, + { 2424, "float4recv", 1, true, false, float4recv }, + { 2425, "float4send", 1, true, false, float4send }, + { 2426, "float8recv", 1, true, false, float8recv }, + { 2427, "float8send", 1, true, false, float8send }, + { 2428, "point_recv", 1, true, false, point_recv }, + { 2429, "point_send", 1, true, false, point_send }, + { 2430, "bpcharrecv", 3, true, false, bpcharrecv }, + { 2431, "bpcharsend", 1, true, false, bpcharsend }, + { 2432, "varcharrecv", 3, true, false, varcharrecv }, + { 2433, "varcharsend", 1, true, false, varcharsend }, + { 2434, "charrecv", 1, true, false, charrecv }, + { 2435, "charsend", 1, true, false, charsend }, + { 2436, "boolrecv", 1, true, false, boolrecv }, + { 2437, "boolsend", 1, true, false, boolsend }, + { 2438, "tidrecv", 1, true, false, tidrecv }, + { 2439, "tidsend", 1, true, false, tidsend }, + { 2440, "xidrecv", 1, true, false, xidrecv }, + { 2441, "xidsend", 1, true, false, xidsend }, + { 2442, "cidrecv", 1, true, false, cidrecv }, + { 2443, "cidsend", 1, true, false, cidsend }, + { 2444, "regprocrecv", 1, true, false, regprocrecv }, + { 2445, "regprocsend", 1, true, false, regprocsend }, + { 2446, "regprocedurerecv", 1, true, false, regprocedurerecv }, + { 2447, "regproceduresend", 1, true, false, regproceduresend }, + { 2448, "regoperrecv", 1, true, false, regoperrecv }, + { 2449, "regopersend", 1, true, false, regopersend }, + { 2450, "regoperatorrecv", 1, true, false, regoperatorrecv }, + { 2451, "regoperatorsend", 1, true, false, regoperatorsend }, + { 2452, "regclassrecv", 1, true, false, regclassrecv }, + { 2453, "regclasssend", 1, true, false, regclasssend }, + { 2454, "regtyperecv", 1, true, false, regtyperecv }, + { 2455, "regtypesend", 1, true, false, regtypesend }, + { 2456, "bit_recv", 3, true, false, bit_recv }, + { 2457, "bit_send", 1, true, false, bit_send }, + { 2458, "varbit_recv", 3, true, false, varbit_recv }, + { 2459, "varbit_send", 1, true, false, varbit_send }, + { 2460, "numeric_recv", 3, true, false, numeric_recv }, + { 2461, "numeric_send", 1, true, false, numeric_send }, + { 2462, "abstimerecv", 1, true, false, abstimerecv }, + { 2463, "abstimesend", 1, true, false, abstimesend }, + { 2464, "reltimerecv", 1, true, false, reltimerecv }, + { 2465, "reltimesend", 1, true, false, reltimesend }, + { 2466, "tintervalrecv", 1, true, false, tintervalrecv }, + { 2467, "tintervalsend", 1, true, false, tintervalsend }, + { 2468, "date_recv", 1, true, false, date_recv }, + { 2469, "date_send", 1, true, false, date_send }, + { 2470, "time_recv", 3, true, false, time_recv }, + { 2471, "time_send", 1, true, false, time_send }, + { 2472, "timetz_recv", 3, true, false, timetz_recv }, + { 2473, "timetz_send", 1, true, false, timetz_send }, + { 2474, "timestamp_recv", 3, true, false, timestamp_recv }, + { 2475, "timestamp_send", 1, true, false, timestamp_send }, + { 2476, "timestamptz_recv", 3, true, false, timestamptz_recv }, + { 2477, "timestamptz_send", 1, true, false, timestamptz_send }, + { 2478, "interval_recv", 3, true, false, interval_recv }, + { 2479, "interval_send", 1, true, false, interval_send }, + { 2480, "lseg_recv", 1, true, false, lseg_recv }, + { 2481, "lseg_send", 1, true, false, lseg_send }, + { 2482, "path_recv", 1, true, false, path_recv }, + { 2483, "path_send", 1, true, false, path_send }, + { 2484, "box_recv", 1, true, false, box_recv }, + { 2485, "box_send", 1, true, false, box_send }, + { 2486, "poly_recv", 1, true, false, poly_recv }, + { 2487, "poly_send", 1, true, false, poly_send }, + { 2488, "line_recv", 1, true, false, line_recv }, + { 2489, "line_send", 1, true, false, line_send }, + { 2490, "circle_recv", 1, true, false, circle_recv }, + { 2491, "circle_send", 1, true, false, circle_send }, + { 2492, "cash_recv", 1, true, false, cash_recv }, + { 2493, "cash_send", 1, true, false, cash_send }, + { 2494, "macaddr_recv", 1, true, false, macaddr_recv }, + { 2495, "macaddr_send", 1, true, false, macaddr_send }, + { 2496, "inet_recv", 1, true, false, inet_recv }, + { 2497, "inet_send", 1, true, false, inet_send }, + { 2498, "cidr_recv", 1, true, false, cidr_recv }, + { 2499, "cidr_send", 1, true, false, cidr_send }, + { 2500, "cstring_recv", 1, true, false, cstring_recv }, + { 2501, "cstring_send", 1, true, false, cstring_send }, + { 2502, "anyarray_recv", 1, true, false, anyarray_recv }, + { 2503, "anyarray_send", 1, true, false, anyarray_send }, + { 2504, "pg_get_ruledef_ext", 2, true, false, pg_get_ruledef_ext }, + { 2505, "pg_get_viewdef_name_ext", 2, true, false, pg_get_viewdef_name_ext }, + { 2506, "pg_get_viewdef_ext", 2, true, false, pg_get_viewdef_ext }, + { 2507, "pg_get_indexdef_ext", 3, true, false, pg_get_indexdef_ext }, + { 2508, "pg_get_constraintdef_ext", 2, true, false, pg_get_constraintdef_ext }, + { 2509, "pg_get_expr_ext", 3, true, false, pg_get_expr_ext }, + { 2510, "pg_prepared_statement", 0, true, true, pg_prepared_statement }, + { 2511, "pg_cursor", 0, true, true, pg_cursor }, + { 2512, "float8_var_pop", 1, true, false, float8_var_pop }, + { 2513, "float8_stddev_pop", 1, true, false, float8_stddev_pop }, + { 2514, "numeric_var_pop", 1, true, false, numeric_var_pop }, + { 2515, "booland_statefunc", 2, true, false, booland_statefunc }, + { 2516, "boolor_statefunc", 2, true, false, boolor_statefunc }, + { 2517, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2518, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2519, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2520, "timestamp_lt_timestamptz", 2, true, false, timestamp_lt_timestamptz }, + { 2521, "timestamp_le_timestamptz", 2, true, false, timestamp_le_timestamptz }, + { 2522, "timestamp_eq_timestamptz", 2, true, false, timestamp_eq_timestamptz }, + { 2523, "timestamp_gt_timestamptz", 2, true, false, timestamp_gt_timestamptz }, + { 2524, "timestamp_ge_timestamptz", 2, true, false, timestamp_ge_timestamptz }, + { 2525, "timestamp_ne_timestamptz", 2, true, false, timestamp_ne_timestamptz }, + { 2526, "timestamp_cmp_timestamptz", 2, true, false, timestamp_cmp_timestamptz }, + { 2527, "timestamptz_lt_timestamp", 2, true, false, timestamptz_lt_timestamp }, + { 2528, "timestamptz_le_timestamp", 2, true, false, timestamptz_le_timestamp }, + { 2529, "timestamptz_eq_timestamp", 2, true, false, timestamptz_eq_timestamp }, + { 2530, "timestamptz_gt_timestamp", 2, true, false, timestamptz_gt_timestamp }, + { 2531, "timestamptz_ge_timestamp", 2, true, false, timestamptz_ge_timestamp }, + { 2532, "timestamptz_ne_timestamp", 2, true, false, timestamptz_ne_timestamp }, + { 2533, "timestamptz_cmp_timestamp", 2, true, false, timestamptz_cmp_timestamp }, + { 2556, "pg_tablespace_databases", 1, true, true, pg_tablespace_databases }, + { 2557, "int4_bool", 1, true, false, int4_bool }, + { 2558, "bool_int4", 1, true, false, bool_int4 }, + { 2559, "lastval", 0, true, false, lastval }, + { 2560, "pg_postmaster_start_time", 0, true, false, pg_postmaster_start_time }, + { 2561, "gistvacuumcleanup", 2, true, false, gistvacuumcleanup }, + { 2562, "box_below", 2, true, false, box_below }, + { 2563, "box_overbelow", 2, true, false, box_overbelow }, + { 2564, "box_overabove", 2, true, false, box_overabove }, + { 2565, "box_above", 2, true, false, box_above }, + { 2566, "poly_below", 2, true, false, poly_below }, + { 2567, "poly_overbelow", 2, true, false, poly_overbelow }, + { 2568, "poly_overabove", 2, true, false, poly_overabove }, + { 2569, "poly_above", 2, true, false, poly_above }, + { 2578, "gist_box_consistent", 5, true, false, gist_box_consistent }, + { 2579, "gist_box_compress", 1, true, false, gist_box_compress }, + { 2580, "gist_box_decompress", 1, true, false, gist_box_decompress }, + { 2581, "gist_box_penalty", 3, true, false, gist_box_penalty }, + { 2582, "gist_box_picksplit", 2, true, false, gist_box_picksplit }, + { 2583, "gist_box_union", 2, true, false, gist_box_union }, + { 2584, "gist_box_same", 3, true, false, gist_box_same }, + { 2585, "gist_poly_consistent", 5, true, false, gist_poly_consistent }, + { 2586, "gist_poly_compress", 1, true, false, gist_poly_compress }, + { 2587, "circle_overbelow", 2, true, false, circle_overbelow }, + { 2588, "circle_overabove", 2, true, false, circle_overabove }, + { 2591, "gist_circle_consistent", 5, true, false, gist_circle_consistent }, + { 2592, "gist_circle_compress", 1, true, false, gist_circle_compress }, + { 2596, "numeric_stddev_pop", 1, true, false, numeric_stddev_pop }, + { 2597, "domain_in", 3, false, false, domain_in }, + { 2598, "domain_recv", 3, false, false, domain_recv }, + { 2599, "pg_timezone_abbrevs", 0, true, true, pg_timezone_abbrevs }, + { 2614, "xmlexists", 2, true, false, xmlexists }, + { 2621, "pg_reload_conf", 0, true, false, pg_reload_conf }, + { 2622, "pg_rotate_logfile", 0, true, false, pg_rotate_logfile }, + { 2623, "pg_stat_file", 1, true, false, pg_stat_file }, + { 2624, "pg_read_file", 3, true, false, pg_read_file }, + { 2625, "pg_ls_dir", 1, true, true, pg_ls_dir }, + { 2626, "pg_sleep", 1, true, false, pg_sleep }, + { 2627, "inetnot", 1, true, false, inetnot }, + { 2628, "inetand", 2, true, false, inetand }, + { 2629, "inetor", 2, true, false, inetor }, + { 2630, "inetpl", 2, true, false, inetpl }, + { 2632, "inetmi_int8", 2, true, false, inetmi_int8 }, + { 2633, "inetmi", 2, true, false, inetmi }, + { 2641, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2642, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2643, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2644, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2645, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2646, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2647, "now", 0, true, false, now }, + { 2648, "statement_timestamp", 0, true, false, statement_timestamp }, + { 2649, "clock_timestamp", 0, true, false, clock_timestamp }, + { 2700, "gin_cmp_prefix", 4, true, false, gin_cmp_prefix }, + { 2705, "pg_has_role_name_name", 3, true, false, pg_has_role_name_name }, + { 2706, "pg_has_role_name_id", 3, true, false, pg_has_role_name_id }, + { 2707, "pg_has_role_id_name", 3, true, false, pg_has_role_id_name }, + { 2708, "pg_has_role_id_id", 3, true, false, pg_has_role_id_id }, + { 2709, "pg_has_role_name", 2, true, false, pg_has_role_name }, + { 2710, "pg_has_role_id", 2, true, false, pg_has_role_id }, + { 2711, "interval_justify_interval", 1, true, false, interval_justify_interval }, + { 2712, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2713, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2714, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2715, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2716, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2717, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2718, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2719, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2720, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2721, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2722, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2723, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2724, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2725, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2726, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2727, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2728, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2729, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2730, "pg_get_triggerdef_ext", 2, true, false, pg_get_triggerdef_ext }, + { 2731, "gingetbitmap", 2, true, false, gingetbitmap }, + { 2732, "gininsert", 6, true, false, gininsert }, + { 2733, "ginbeginscan", 3, true, false, ginbeginscan }, + { 2734, "ginrescan", 5, true, false, ginrescan }, + { 2735, "ginendscan", 1, true, false, ginendscan }, + { 2736, "ginmarkpos", 1, true, false, ginmarkpos }, + { 2737, "ginrestrpos", 1, true, false, ginrestrpos }, + { 2738, "ginbuild", 3, true, false, ginbuild }, + { 2739, "ginbulkdelete", 4, true, false, ginbulkdelete }, + { 2740, "ginvacuumcleanup", 2, true, false, ginvacuumcleanup }, + { 2741, "gincostestimate", 7, true, false, gincostestimate }, + { 2743, "ginarrayextract", 3, true, false, ginarrayextract }, + { 2744, "ginarrayconsistent", 8, true, false, ginarrayconsistent }, + { 2746, "int8_avg_accum", 2, true, false, int8_avg_accum }, + { 2747, "arrayoverlap", 2, true, false, arrayoverlap }, + { 2748, "arraycontains", 2, true, false, arraycontains }, + { 2749, "arraycontained", 2, true, false, arraycontained }, + { 2758, "pg_stat_get_db_tuples_returned", 1, true, false, pg_stat_get_db_tuples_returned }, + { 2759, "pg_stat_get_db_tuples_fetched", 1, true, false, pg_stat_get_db_tuples_fetched }, + { 2760, "pg_stat_get_db_tuples_inserted", 1, true, false, pg_stat_get_db_tuples_inserted }, + { 2761, "pg_stat_get_db_tuples_updated", 1, true, false, pg_stat_get_db_tuples_updated }, + { 2762, "pg_stat_get_db_tuples_deleted", 1, true, false, pg_stat_get_db_tuples_deleted }, + { 2763, "regexp_matches_no_flags", 2, true, true, regexp_matches_no_flags }, + { 2764, "regexp_matches", 3, true, true, regexp_matches }, + { 2765, "regexp_split_to_table_no_flags", 2, true, true, regexp_split_to_table_no_flags }, + { 2766, "regexp_split_to_table", 3, true, true, regexp_split_to_table }, + { 2767, "regexp_split_to_array_no_flags", 2, true, false, regexp_split_to_array_no_flags }, + { 2768, "regexp_split_to_array", 3, true, false, regexp_split_to_array }, + { 2769, "pg_stat_get_bgwriter_timed_checkpoints", 0, true, false, pg_stat_get_bgwriter_timed_checkpoints }, + { 2770, "pg_stat_get_bgwriter_requested_checkpoints", 0, true, false, pg_stat_get_bgwriter_requested_checkpoints }, + { 2771, "pg_stat_get_bgwriter_buf_written_checkpoints", 0, true, false, pg_stat_get_bgwriter_buf_written_checkpoints }, + { 2772, "pg_stat_get_bgwriter_buf_written_clean", 0, true, false, pg_stat_get_bgwriter_buf_written_clean }, + { 2773, "pg_stat_get_bgwriter_maxwritten_clean", 0, true, false, pg_stat_get_bgwriter_maxwritten_clean }, + { 2774, "ginqueryarrayextract", 7, true, false, ginqueryarrayextract }, + { 2775, "pg_stat_get_buf_written_backend", 0, true, false, pg_stat_get_buf_written_backend }, + { 2777, "anynonarray_in", 1, true, false, anynonarray_in }, + { 2778, "anynonarray_out", 1, true, false, anynonarray_out }, + { 2781, "pg_stat_get_last_vacuum_time", 1, true, false, pg_stat_get_last_vacuum_time }, + { 2782, "pg_stat_get_last_autovacuum_time", 1, true, false, pg_stat_get_last_autovacuum_time }, + { 2783, "pg_stat_get_last_analyze_time", 1, true, false, pg_stat_get_last_analyze_time }, + { 2784, "pg_stat_get_last_autoanalyze_time", 1, true, false, pg_stat_get_last_autoanalyze_time }, + { 2785, "btoptions", 2, true, false, btoptions }, + { 2786, "hashoptions", 2, true, false, hashoptions }, + { 2787, "gistoptions", 2, true, false, gistoptions }, + { 2788, "ginoptions", 2, true, false, ginoptions }, + { 2790, "tidgt", 2, true, false, tidgt }, + { 2791, "tidlt", 2, true, false, tidlt }, + { 2792, "tidge", 2, true, false, tidge }, + { 2793, "tidle", 2, true, false, tidle }, + { 2794, "bttidcmp", 2, true, false, bttidcmp }, + { 2795, "tidlarger", 2, true, false, tidlarger }, + { 2796, "tidsmaller", 2, true, false, tidsmaller }, + { 2797, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2798, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2803, "aggregate_dummy", 0, false, false, aggregate_dummy }, + { 2804, "int8inc_any", 2, true, false, int8inc_any }, + { 2805, "int8inc_float8_float8", 3, true, false, int8inc_float8_float8 }, + { 2806, "float8_regr_accum", 3, true, false, float8_regr_accum }, + { 2807, "float8_regr_sxx", 1, true, false, float8_regr_sxx }, + { 2808, "float8_regr_syy", 1, true, false, float8_regr_syy }, + { 2809, "float8_regr_sxy", 1, true, false, float8_regr_sxy }, + { 2810, "float8_regr_avgx", 1, true, false, float8_regr_avgx }, + { 2811, "float8_regr_avgy", 1, true, false, float8_regr_avgy }, + { 2812, "float8_regr_r2", 1, true, false, float8_regr_r2 }, + { 2813, "float8_regr_slope", 1, true, false, float8_regr_slope }, + { 2814, "float8_regr_intercept", 1, true, false, float8_regr_intercept }, + { 2815, "float8_covar_pop", 1, true, false, float8_covar_pop }, + { 2816, "float8_covar_samp", 1, true, false, float8_covar_samp }, + { 2817, "float8_corr", 1, true, false, float8_corr }, + { 2818, "aggregate_dummy", 2, false, false, aggregate_dummy }, + { 2819, "aggregate_dummy", 2, false, false, aggregate_dummy }, + { 2820, "aggregate_dummy", 2, false, false, aggregate_dummy }, + { 2821, "aggregate_dummy", 2, false, false, aggregate_dummy }, + { 2822, "aggregate_dummy", 2, false, false, aggregate_dummy }, + { 2823, "aggregate_dummy", 2, false, false, aggregate_dummy }, + { 2824, "aggregate_dummy", 2, false, false, aggregate_dummy }, + { 2825, "aggregate_dummy", 2, false, false, aggregate_dummy }, + { 2826, "aggregate_dummy", 2, false, false, aggregate_dummy }, + { 2827, "aggregate_dummy", 2, false, false, aggregate_dummy }, + { 2828, "aggregate_dummy", 2, false, false, aggregate_dummy }, + { 2829, "aggregate_dummy", 2, false, false, aggregate_dummy }, + { 2844, "pg_stat_get_db_blk_read_time", 1, true, false, pg_stat_get_db_blk_read_time }, + { 2845, "pg_stat_get_db_blk_write_time", 1, true, false, pg_stat_get_db_blk_write_time }, + { 2848, "pg_switch_xlog", 0, true, false, pg_switch_xlog }, + { 2849, "pg_current_xlog_location", 0, true, false, pg_current_xlog_location }, + { 2850, "pg_xlogfile_name_offset", 1, true, false, pg_xlogfile_name_offset }, + { 2851, "pg_xlogfile_name", 1, true, false, pg_xlogfile_name }, + { 2852, "pg_current_xlog_insert_location", 0, true, false, pg_current_xlog_insert_location }, + { 2853, "pg_stat_get_backend_waiting", 1, true, false, pg_stat_get_backend_waiting }, + { 2854, "pg_my_temp_schema", 0, true, false, pg_my_temp_schema }, + { 2855, "pg_is_other_temp_schema", 1, true, false, pg_is_other_temp_schema }, + { 2856, "pg_timezone_names", 0, true, true, pg_timezone_names }, + { 2857, "pg_stat_get_backend_xact_start", 1, true, false, pg_stat_get_backend_xact_start }, + { 2858, "numeric_avg_accum", 2, true, false, numeric_avg_accum }, + { 2859, "pg_stat_get_buf_alloc", 0, true, false, pg_stat_get_buf_alloc }, + { 2878, "pg_stat_get_live_tuples", 1, true, false, pg_stat_get_live_tuples }, + { 2879, "pg_stat_get_dead_tuples", 1, true, false, pg_stat_get_dead_tuples }, + { 2880, "pg_advisory_lock_int8", 1, true, false, pg_advisory_lock_int8 }, + { 2881, "pg_advisory_lock_shared_int8", 1, true, false, pg_advisory_lock_shared_int8 }, + { 2882, "pg_try_advisory_lock_int8", 1, true, false, pg_try_advisory_lock_int8 }, + { 2883, "pg_try_advisory_lock_shared_int8", 1, true, false, pg_try_advisory_lock_shared_int8 }, + { 2884, "pg_advisory_unlock_int8", 1, true, false, pg_advisory_unlock_int8 }, + { 2885, "pg_advisory_unlock_shared_int8", 1, true, false, pg_advisory_unlock_shared_int8 }, + { 2886, "pg_advisory_lock_int4", 2, true, false, pg_advisory_lock_int4 }, + { 2887, "pg_advisory_lock_shared_int4", 2, true, false, pg_advisory_lock_shared_int4 }, + { 2888, "pg_try_advisory_lock_int4", 2, true, false, pg_try_advisory_lock_int4 }, + { 2889, "pg_try_advisory_lock_shared_int4", 2, true, false, pg_try_advisory_lock_shared_int4 }, + { 2890, "pg_advisory_unlock_int4", 2, true, false, pg_advisory_unlock_int4 }, + { 2891, "pg_advisory_unlock_shared_int4", 2, true, false, pg_advisory_unlock_shared_int4 }, + { 2892, "pg_advisory_unlock_all", 0, true, false, pg_advisory_unlock_all }, + { 2893, "xml_in", 1, true, false, xml_in }, + { 2894, "xml_out", 1, true, false, xml_out }, + { 2895, "xmlcomment", 1, true, false, xmlcomment }, + { 2896, "texttoxml", 1, true, false, texttoxml }, + { 2897, "xmlvalidate", 2, true, false, xmlvalidate }, + { 2898, "xml_recv", 1, true, false, xml_recv }, + { 2899, "xml_send", 1, true, false, xml_send }, + { 2900, "xmlconcat2", 2, false, false, xmlconcat2 }, + { 2901, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 2902, "varbittypmodin", 1, true, false, varbittypmodin }, + { 2903, "intervaltypmodin", 1, true, false, intervaltypmodin }, + { 2904, "intervaltypmodout", 1, true, false, intervaltypmodout }, + { 2905, "timestamptypmodin", 1, true, false, timestamptypmodin }, + { 2906, "timestamptypmodout", 1, true, false, timestamptypmodout }, + { 2907, "timestamptztypmodin", 1, true, false, timestamptztypmodin }, + { 2908, "timestamptztypmodout", 1, true, false, timestamptztypmodout }, + { 2909, "timetypmodin", 1, true, false, timetypmodin }, + { 2910, "timetypmodout", 1, true, false, timetypmodout }, + { 2911, "timetztypmodin", 1, true, false, timetztypmodin }, + { 2912, "timetztypmodout", 1, true, false, timetztypmodout }, + { 2913, "bpchartypmodin", 1, true, false, bpchartypmodin }, + { 2914, "bpchartypmodout", 1, true, false, bpchartypmodout }, + { 2915, "varchartypmodin", 1, true, false, varchartypmodin }, + { 2916, "varchartypmodout", 1, true, false, varchartypmodout }, + { 2917, "numerictypmodin", 1, true, false, numerictypmodin }, + { 2918, "numerictypmodout", 1, true, false, numerictypmodout }, + { 2919, "bittypmodin", 1, true, false, bittypmodin }, + { 2920, "bittypmodout", 1, true, false, bittypmodout }, + { 2921, "varbittypmodout", 1, true, false, varbittypmodout }, + { 2922, "xmltotext", 1, true, false, xmltotext }, + { 2923, "table_to_xml", 4, true, false, table_to_xml }, + { 2924, "query_to_xml", 4, true, false, query_to_xml }, + { 2925, "cursor_to_xml", 5, true, false, cursor_to_xml }, + { 2926, "table_to_xmlschema", 4, true, false, table_to_xmlschema }, + { 2927, "query_to_xmlschema", 4, true, false, query_to_xmlschema }, + { 2928, "cursor_to_xmlschema", 4, true, false, cursor_to_xmlschema }, + { 2929, "table_to_xml_and_xmlschema", 4, true, false, table_to_xml_and_xmlschema }, + { 2930, "query_to_xml_and_xmlschema", 4, true, false, query_to_xml_and_xmlschema }, + { 2931, "xpath", 3, true, false, xpath }, + { 2933, "schema_to_xml", 4, true, false, schema_to_xml }, + { 2934, "schema_to_xmlschema", 4, true, false, schema_to_xmlschema }, + { 2935, "schema_to_xml_and_xmlschema", 4, true, false, schema_to_xml_and_xmlschema }, + { 2936, "database_to_xml", 3, true, false, database_to_xml }, + { 2937, "database_to_xmlschema", 3, true, false, database_to_xmlschema }, + { 2938, "database_to_xml_and_xmlschema", 3, true, false, database_to_xml_and_xmlschema }, + { 2939, "txid_snapshot_in", 1, true, false, txid_snapshot_in }, + { 2940, "txid_snapshot_out", 1, true, false, txid_snapshot_out }, + { 2941, "txid_snapshot_recv", 1, true, false, txid_snapshot_recv }, + { 2942, "txid_snapshot_send", 1, true, false, txid_snapshot_send }, + { 2943, "txid_current", 0, true, false, txid_current }, + { 2944, "txid_current_snapshot", 0, true, false, txid_current_snapshot }, + { 2945, "txid_snapshot_xmin", 1, true, false, txid_snapshot_xmin }, + { 2946, "txid_snapshot_xmax", 1, true, false, txid_snapshot_xmax }, + { 2947, "txid_snapshot_xip", 1, true, true, txid_snapshot_xip }, + { 2948, "txid_visible_in_snapshot", 2, true, false, txid_visible_in_snapshot }, + { 2952, "uuid_in", 1, true, false, uuid_in }, + { 2953, "uuid_out", 1, true, false, uuid_out }, + { 2954, "uuid_lt", 2, true, false, uuid_lt }, + { 2955, "uuid_le", 2, true, false, uuid_le }, + { 2956, "uuid_eq", 2, true, false, uuid_eq }, + { 2957, "uuid_ge", 2, true, false, uuid_ge }, + { 2958, "uuid_gt", 2, true, false, uuid_gt }, + { 2959, "uuid_ne", 2, true, false, uuid_ne }, + { 2960, "uuid_cmp", 2, true, false, uuid_cmp }, + { 2961, "uuid_recv", 1, true, false, uuid_recv }, + { 2962, "uuid_send", 1, true, false, uuid_send }, + { 2963, "uuid_hash", 1, true, false, uuid_hash }, + { 2971, "booltext", 1, true, false, booltext }, + { 2978, "pg_stat_get_function_calls", 1, true, false, pg_stat_get_function_calls }, + { 2979, "pg_stat_get_function_total_time", 1, true, false, pg_stat_get_function_total_time }, + { 2980, "pg_stat_get_function_self_time", 1, true, false, pg_stat_get_function_self_time }, + { 2981, "record_eq", 2, true, false, record_eq }, + { 2982, "record_ne", 2, true, false, record_ne }, + { 2983, "record_lt", 2, true, false, record_lt }, + { 2984, "record_gt", 2, true, false, record_gt }, + { 2985, "record_le", 2, true, false, record_le }, + { 2986, "record_ge", 2, true, false, record_ge }, + { 2987, "btrecordcmp", 2, true, false, btrecordcmp }, + { 2997, "pg_table_size", 1, true, false, pg_table_size }, + { 2998, "pg_indexes_size", 1, true, false, pg_indexes_size }, + { 2999, "pg_relation_filenode", 1, true, false, pg_relation_filenode }, + { 3000, "has_foreign_data_wrapper_privilege_name_name", 3, true, false, has_foreign_data_wrapper_privilege_name_name }, + { 3001, "has_foreign_data_wrapper_privilege_name_id", 3, true, false, has_foreign_data_wrapper_privilege_name_id }, + { 3002, "has_foreign_data_wrapper_privilege_id_name", 3, true, false, has_foreign_data_wrapper_privilege_id_name }, + { 3003, "has_foreign_data_wrapper_privilege_id_id", 3, true, false, has_foreign_data_wrapper_privilege_id_id }, + { 3004, "has_foreign_data_wrapper_privilege_name", 2, true, false, has_foreign_data_wrapper_privilege_name }, + { 3005, "has_foreign_data_wrapper_privilege_id", 2, true, false, has_foreign_data_wrapper_privilege_id }, + { 3006, "has_server_privilege_name_name", 3, true, false, has_server_privilege_name_name }, + { 3007, "has_server_privilege_name_id", 3, true, false, has_server_privilege_name_id }, + { 3008, "has_server_privilege_id_name", 3, true, false, has_server_privilege_id_name }, + { 3009, "has_server_privilege_id_id", 3, true, false, has_server_privilege_id_id }, + { 3010, "has_server_privilege_name", 2, true, false, has_server_privilege_name }, + { 3011, "has_server_privilege_id", 2, true, false, has_server_privilege_id }, + { 3012, "has_column_privilege_name_name_name", 4, true, false, has_column_privilege_name_name_name }, + { 3013, "has_column_privilege_name_name_attnum", 4, true, false, has_column_privilege_name_name_attnum }, + { 3014, "has_column_privilege_name_id_name", 4, true, false, has_column_privilege_name_id_name }, + { 3015, "has_column_privilege_name_id_attnum", 4, true, false, has_column_privilege_name_id_attnum }, + { 3016, "has_column_privilege_id_name_name", 4, true, false, has_column_privilege_id_name_name }, + { 3017, "has_column_privilege_id_name_attnum", 4, true, false, has_column_privilege_id_name_attnum }, + { 3018, "has_column_privilege_id_id_name", 4, true, false, has_column_privilege_id_id_name }, + { 3019, "has_column_privilege_id_id_attnum", 4, true, false, has_column_privilege_id_id_attnum }, + { 3020, "has_column_privilege_name_name", 3, true, false, has_column_privilege_name_name }, + { 3021, "has_column_privilege_name_attnum", 3, true, false, has_column_privilege_name_attnum }, + { 3022, "has_column_privilege_id_name", 3, true, false, has_column_privilege_id_name }, + { 3023, "has_column_privilege_id_attnum", 3, true, false, has_column_privilege_id_attnum }, + { 3024, "has_any_column_privilege_name_name", 3, true, false, has_any_column_privilege_name_name }, + { 3025, "has_any_column_privilege_name_id", 3, true, false, has_any_column_privilege_name_id }, + { 3026, "has_any_column_privilege_id_name", 3, true, false, has_any_column_privilege_id_name }, + { 3027, "has_any_column_privilege_id_id", 3, true, false, has_any_column_privilege_id_id }, + { 3028, "has_any_column_privilege_name", 2, true, false, has_any_column_privilege_name }, + { 3029, "has_any_column_privilege_id", 2, true, false, has_any_column_privilege_id }, + { 3030, "bitoverlay", 4, true, false, bitoverlay }, + { 3031, "bitoverlay_no_len", 3, true, false, bitoverlay_no_len }, + { 3032, "bitgetbit", 2, true, false, bitgetbit }, + { 3033, "bitsetbit", 3, true, false, bitsetbit }, + { 3034, "pg_relation_filepath", 1, true, false, pg_relation_filepath }, + { 3035, "pg_listening_channels", 0, true, true, pg_listening_channels }, + { 3036, "pg_notify", 2, false, false, pg_notify }, + { 3037, "pg_stat_get_xact_numscans", 1, true, false, pg_stat_get_xact_numscans }, + { 3038, "pg_stat_get_xact_tuples_returned", 1, true, false, pg_stat_get_xact_tuples_returned }, + { 3039, "pg_stat_get_xact_tuples_fetched", 1, true, false, pg_stat_get_xact_tuples_fetched }, + { 3040, "pg_stat_get_xact_tuples_inserted", 1, true, false, pg_stat_get_xact_tuples_inserted }, + { 3041, "pg_stat_get_xact_tuples_updated", 1, true, false, pg_stat_get_xact_tuples_updated }, + { 3042, "pg_stat_get_xact_tuples_deleted", 1, true, false, pg_stat_get_xact_tuples_deleted }, + { 3043, "pg_stat_get_xact_tuples_hot_updated", 1, true, false, pg_stat_get_xact_tuples_hot_updated }, + { 3044, "pg_stat_get_xact_blocks_fetched", 1, true, false, pg_stat_get_xact_blocks_fetched }, + { 3045, "pg_stat_get_xact_blocks_hit", 1, true, false, pg_stat_get_xact_blocks_hit }, + { 3046, "pg_stat_get_xact_function_calls", 1, true, false, pg_stat_get_xact_function_calls }, + { 3047, "pg_stat_get_xact_function_total_time", 1, true, false, pg_stat_get_xact_function_total_time }, + { 3048, "pg_stat_get_xact_function_self_time", 1, true, false, pg_stat_get_xact_function_self_time }, + { 3049, "xpath_exists", 3, true, false, xpath_exists }, + { 3051, "xml_is_well_formed", 1, true, false, xml_is_well_formed }, + { 3052, "xml_is_well_formed_document", 1, true, false, xml_is_well_formed_document }, + { 3053, "xml_is_well_formed_content", 1, true, false, xml_is_well_formed_content }, + { 3054, "pg_stat_get_vacuum_count", 1, true, false, pg_stat_get_vacuum_count }, + { 3055, "pg_stat_get_autovacuum_count", 1, true, false, pg_stat_get_autovacuum_count }, + { 3056, "pg_stat_get_analyze_count", 1, true, false, pg_stat_get_analyze_count }, + { 3057, "pg_stat_get_autoanalyze_count", 1, true, false, pg_stat_get_autoanalyze_count }, + { 3058, "text_concat", 1, false, false, text_concat }, + { 3059, "text_concat_ws", 2, false, false, text_concat_ws }, + { 3060, "text_left", 2, true, false, text_left }, + { 3061, "text_right", 2, true, false, text_right }, + { 3062, "text_reverse", 1, true, false, text_reverse }, + { 3063, "pg_stat_get_buf_fsync_backend", 0, true, false, pg_stat_get_buf_fsync_backend }, + { 3064, "gist_point_distance", 4, true, false, gist_point_distance }, + { 3065, "pg_stat_get_db_conflict_tablespace", 1, true, false, pg_stat_get_db_conflict_tablespace }, + { 3066, "pg_stat_get_db_conflict_lock", 1, true, false, pg_stat_get_db_conflict_lock }, + { 3067, "pg_stat_get_db_conflict_snapshot", 1, true, false, pg_stat_get_db_conflict_snapshot }, + { 3068, "pg_stat_get_db_conflict_bufferpin", 1, true, false, pg_stat_get_db_conflict_bufferpin }, + { 3069, "pg_stat_get_db_conflict_startup_deadlock", 1, true, false, pg_stat_get_db_conflict_startup_deadlock }, + { 3070, "pg_stat_get_db_conflict_all", 1, true, false, pg_stat_get_db_conflict_all }, + { 3071, "pg_xlog_replay_pause", 0, true, false, pg_xlog_replay_pause }, + { 3072, "pg_xlog_replay_resume", 0, true, false, pg_xlog_replay_resume }, + { 3073, "pg_is_xlog_replay_paused", 0, true, false, pg_is_xlog_replay_paused }, + { 3074, "pg_stat_get_db_stat_reset_time", 1, true, false, pg_stat_get_db_stat_reset_time }, + { 3075, "pg_stat_get_bgwriter_stat_reset_time", 0, true, false, pg_stat_get_bgwriter_stat_reset_time }, + { 3076, "ginarrayextract_2args", 2, true, false, ginarrayextract_2args }, + { 3077, "gin_extract_tsvector_2args", 2, true, false, gin_extract_tsvector_2args }, + { 3078, "pg_sequence_parameters", 1, true, false, pg_sequence_parameters }, + { 3082, "pg_available_extensions", 0, true, true, pg_available_extensions }, + { 3083, "pg_available_extension_versions", 0, true, true, pg_available_extension_versions }, + { 3084, "pg_extension_update_paths", 1, true, true, pg_extension_update_paths }, + { 3086, "pg_extension_config_dump", 2, true, false, pg_extension_config_dump }, + { 3087, "gin_extract_tsquery_5args", 5, true, false, gin_extract_tsquery_5args }, + { 3088, "gin_tsquery_consistent_6args", 6, true, false, gin_tsquery_consistent_6args }, + { 3089, "pg_advisory_xact_lock_int8", 1, true, false, pg_advisory_xact_lock_int8 }, + { 3090, "pg_advisory_xact_lock_shared_int8", 1, true, false, pg_advisory_xact_lock_shared_int8 }, + { 3091, "pg_try_advisory_xact_lock_int8", 1, true, false, pg_try_advisory_xact_lock_int8 }, + { 3092, "pg_try_advisory_xact_lock_shared_int8", 1, true, false, pg_try_advisory_xact_lock_shared_int8 }, + { 3093, "pg_advisory_xact_lock_int4", 2, true, false, pg_advisory_xact_lock_int4 }, + { 3094, "pg_advisory_xact_lock_shared_int4", 2, true, false, pg_advisory_xact_lock_shared_int4 }, + { 3095, "pg_try_advisory_xact_lock_int4", 2, true, false, pg_try_advisory_xact_lock_int4 }, + { 3096, "pg_try_advisory_xact_lock_shared_int4", 2, true, false, pg_try_advisory_xact_lock_shared_int4 }, + { 3097, "varchar_transform", 1, true, false, varchar_transform }, + { 3098, "pg_create_restore_point", 1, true, false, pg_create_restore_point }, + { 3099, "pg_stat_get_wal_senders", 0, false, true, pg_stat_get_wal_senders }, + { 3100, "window_row_number", 0, false, false, window_row_number }, + { 3101, "window_rank", 0, false, false, window_rank }, + { 3102, "window_dense_rank", 0, false, false, window_dense_rank }, + { 3103, "window_percent_rank", 0, false, false, window_percent_rank }, + { 3104, "window_cume_dist", 0, false, false, window_cume_dist }, + { 3105, "window_ntile", 1, true, false, window_ntile }, + { 3106, "window_lag", 1, true, false, window_lag }, + { 3107, "window_lag_with_offset", 2, true, false, window_lag_with_offset }, + { 3108, "window_lag_with_offset_and_default", 3, true, false, window_lag_with_offset_and_default }, + { 3109, "window_lead", 1, true, false, window_lead }, + { 3110, "window_lead_with_offset", 2, true, false, window_lead_with_offset }, + { 3111, "window_lead_with_offset_and_default", 3, true, false, window_lead_with_offset_and_default }, + { 3112, "window_first_value", 1, true, false, window_first_value }, + { 3113, "window_last_value", 1, true, false, window_last_value }, + { 3114, "window_nth_value", 2, true, false, window_nth_value }, + { 3116, "fdw_handler_in", 1, false, false, fdw_handler_in }, + { 3117, "fdw_handler_out", 1, true, false, fdw_handler_out }, + { 3120, "void_recv", 1, true, false, void_recv }, + { 3121, "void_send", 1, true, false, void_send }, + { 3129, "btint2sortsupport", 1, true, false, btint2sortsupport }, + { 3130, "btint4sortsupport", 1, true, false, btint4sortsupport }, + { 3131, "btint8sortsupport", 1, true, false, btint8sortsupport }, + { 3132, "btfloat4sortsupport", 1, true, false, btfloat4sortsupport }, + { 3133, "btfloat8sortsupport", 1, true, false, btfloat8sortsupport }, + { 3134, "btoidsortsupport", 1, true, false, btoidsortsupport }, + { 3135, "btnamesortsupport", 1, true, false, btnamesortsupport }, + { 3136, "date_sortsupport", 1, true, false, date_sortsupport }, + { 3137, "timestamp_sortsupport", 1, true, false, timestamp_sortsupport }, + { 3138, "has_type_privilege_name_name", 3, true, false, has_type_privilege_name_name }, + { 3139, "has_type_privilege_name_id", 3, true, false, has_type_privilege_name_id }, + { 3140, "has_type_privilege_id_name", 3, true, false, has_type_privilege_id_name }, + { 3141, "has_type_privilege_id_id", 3, true, false, has_type_privilege_id_id }, + { 3142, "has_type_privilege_name", 2, true, false, has_type_privilege_name }, + { 3143, "has_type_privilege_id", 2, true, false, has_type_privilege_id }, + { 3144, "macaddr_not", 1, true, false, macaddr_not }, + { 3145, "macaddr_and", 2, true, false, macaddr_and }, + { 3146, "macaddr_or", 2, true, false, macaddr_or }, + { 3150, "pg_stat_get_db_temp_files", 1, true, false, pg_stat_get_db_temp_files }, + { 3151, "pg_stat_get_db_temp_bytes", 1, true, false, pg_stat_get_db_temp_bytes }, + { 3152, "pg_stat_get_db_deadlocks", 1, true, false, pg_stat_get_db_deadlocks }, + { 3153, "array_to_json", 1, true, false, array_to_json }, + { 3154, "array_to_json_pretty", 2, true, false, array_to_json_pretty }, + { 3155, "row_to_json", 1, true, false, row_to_json }, + { 3156, "row_to_json_pretty", 2, true, false, row_to_json_pretty }, + { 3157, "numeric_transform", 1, true, false, numeric_transform }, + { 3158, "varbit_transform", 1, true, false, varbit_transform }, + { 3159, "pg_get_viewdef_wrap", 2, true, false, pg_get_viewdef_wrap }, + { 3160, "pg_stat_get_checkpoint_write_time", 0, true, false, pg_stat_get_checkpoint_write_time }, + { 3161, "pg_stat_get_checkpoint_sync_time", 0, true, false, pg_stat_get_checkpoint_sync_time }, + { 3162, "pg_collation_for", 1, false, false, pg_collation_for }, + { 3163, "pg_trigger_depth", 0, true, false, pg_trigger_depth }, + { 3165, "pg_xlog_location_diff", 2, true, false, pg_xlog_location_diff }, + { 3166, "pg_size_pretty_numeric", 1, true, false, pg_size_pretty_numeric }, + { 3504, "anyenum_in", 1, true, false, anyenum_in }, + { 3505, "anyenum_out", 1, true, false, anyenum_out }, + { 3506, "enum_in", 2, true, false, enum_in }, + { 3507, "enum_out", 1, true, false, enum_out }, + { 3508, "enum_eq", 2, true, false, enum_eq }, + { 3509, "enum_ne", 2, true, false, enum_ne }, + { 3510, "enum_lt", 2, true, false, enum_lt }, + { 3511, "enum_gt", 2, true, false, enum_gt }, + { 3512, "enum_le", 2, true, false, enum_le }, + { 3513, "enum_ge", 2, true, false, enum_ge }, + { 3514, "enum_cmp", 2, true, false, enum_cmp }, + { 3515, "hashenum", 1, true, false, hashenum }, + { 3524, "enum_smaller", 2, true, false, enum_smaller }, + { 3525, "enum_larger", 2, true, false, enum_larger }, + { 3526, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 3527, "aggregate_dummy", 1, false, false, aggregate_dummy }, + { 3528, "enum_first", 1, false, false, enum_first }, + { 3529, "enum_last", 1, false, false, enum_last }, + { 3530, "enum_range_bounds", 2, false, false, enum_range_bounds }, + { 3531, "enum_range_all", 1, false, false, enum_range_all }, + { 3532, "enum_recv", 2, true, false, enum_recv }, + { 3533, "enum_send", 1, true, false, enum_send }, + { 3535, "string_agg_transfn", 3, false, false, string_agg_transfn }, + { 3536, "string_agg_finalfn", 1, false, false, string_agg_finalfn }, + { 3537, "pg_describe_object", 3, true, false, pg_describe_object }, + { 3538, "aggregate_dummy", 2, false, false, aggregate_dummy }, + { 3539, "text_format", 2, false, false, text_format }, + { 3540, "text_format_nv", 1, false, false, text_format_nv }, + { 3543, "bytea_string_agg_transfn", 3, false, false, bytea_string_agg_transfn }, + { 3544, "bytea_string_agg_finalfn", 1, false, false, bytea_string_agg_finalfn }, + { 3545, "aggregate_dummy", 2, false, false, aggregate_dummy }, + { 3610, "tsvectorin", 1, true, false, tsvectorin }, + { 3611, "tsvectorout", 1, true, false, tsvectorout }, + { 3612, "tsqueryin", 1, true, false, tsqueryin }, + { 3613, "tsqueryout", 1, true, false, tsqueryout }, + { 3616, "tsvector_lt", 2, true, false, tsvector_lt }, + { 3617, "tsvector_le", 2, true, false, tsvector_le }, + { 3618, "tsvector_eq", 2, true, false, tsvector_eq }, + { 3619, "tsvector_ne", 2, true, false, tsvector_ne }, + { 3620, "tsvector_ge", 2, true, false, tsvector_ge }, + { 3621, "tsvector_gt", 2, true, false, tsvector_gt }, + { 3622, "tsvector_cmp", 2, true, false, tsvector_cmp }, + { 3623, "tsvector_strip", 1, true, false, tsvector_strip }, + { 3624, "tsvector_setweight", 2, true, false, tsvector_setweight }, + { 3625, "tsvector_concat", 2, true, false, tsvector_concat }, + { 3634, "ts_match_vq", 2, true, false, ts_match_vq }, + { 3635, "ts_match_qv", 2, true, false, ts_match_qv }, + { 3638, "tsvectorsend", 1, true, false, tsvectorsend }, + { 3639, "tsvectorrecv", 1, true, false, tsvectorrecv }, + { 3640, "tsquerysend", 1, true, false, tsquerysend }, + { 3641, "tsqueryrecv", 1, true, false, tsqueryrecv }, + { 3646, "gtsvectorin", 1, true, false, gtsvectorin }, + { 3647, "gtsvectorout", 1, true, false, gtsvectorout }, + { 3648, "gtsvector_compress", 1, true, false, gtsvector_compress }, + { 3649, "gtsvector_decompress", 1, true, false, gtsvector_decompress }, + { 3650, "gtsvector_picksplit", 2, true, false, gtsvector_picksplit }, + { 3651, "gtsvector_union", 2, true, false, gtsvector_union }, + { 3652, "gtsvector_same", 3, true, false, gtsvector_same }, + { 3653, "gtsvector_penalty", 3, true, false, gtsvector_penalty }, + { 3654, "gtsvector_consistent", 5, true, false, gtsvector_consistent }, + { 3656, "gin_extract_tsvector", 3, true, false, gin_extract_tsvector }, + { 3657, "gin_extract_tsquery", 7, true, false, gin_extract_tsquery }, + { 3658, "gin_tsquery_consistent", 8, true, false, gin_tsquery_consistent }, + { 3662, "tsquery_lt", 2, true, false, tsquery_lt }, + { 3663, "tsquery_le", 2, true, false, tsquery_le }, + { 3664, "tsquery_eq", 2, true, false, tsquery_eq }, + { 3665, "tsquery_ne", 2, true, false, tsquery_ne }, + { 3666, "tsquery_ge", 2, true, false, tsquery_ge }, + { 3667, "tsquery_gt", 2, true, false, tsquery_gt }, + { 3668, "tsquery_cmp", 2, true, false, tsquery_cmp }, + { 3669, "tsquery_and", 2, true, false, tsquery_and }, + { 3670, "tsquery_or", 2, true, false, tsquery_or }, + { 3671, "tsquery_not", 1, true, false, tsquery_not }, + { 3672, "tsquery_numnode", 1, true, false, tsquery_numnode }, + { 3673, "tsquerytree", 1, true, false, tsquerytree }, + { 3684, "tsquery_rewrite", 3, true, false, tsquery_rewrite }, + { 3685, "tsquery_rewrite_query", 2, true, false, tsquery_rewrite_query }, + { 3686, "tsmatchsel", 4, true, false, tsmatchsel }, + { 3687, "tsmatchjoinsel", 5, true, false, tsmatchjoinsel }, + { 3688, "ts_typanalyze", 1, true, false, ts_typanalyze }, + { 3689, "ts_stat1", 1, true, true, ts_stat1 }, + { 3690, "ts_stat2", 2, true, true, ts_stat2 }, + { 3691, "tsq_mcontains", 2, true, false, tsq_mcontains }, + { 3692, "tsq_mcontained", 2, true, false, tsq_mcontained }, + { 3695, "gtsquery_compress", 1, true, false, gtsquery_compress }, + { 3696, "gtsquery_decompress", 1, true, false, gtsquery_decompress }, + { 3697, "gtsquery_picksplit", 2, true, false, gtsquery_picksplit }, + { 3698, "gtsquery_union", 2, true, false, gtsquery_union }, + { 3699, "gtsquery_same", 3, true, false, gtsquery_same }, + { 3700, "gtsquery_penalty", 3, true, false, gtsquery_penalty }, + { 3701, "gtsquery_consistent", 5, true, false, gtsquery_consistent }, + { 3703, "ts_rank_wttf", 4, true, false, ts_rank_wttf }, + { 3704, "ts_rank_wtt", 3, true, false, ts_rank_wtt }, + { 3705, "ts_rank_ttf", 3, true, false, ts_rank_ttf }, + { 3706, "ts_rank_tt", 2, true, false, ts_rank_tt }, + { 3707, "ts_rankcd_wttf", 4, true, false, ts_rankcd_wttf }, + { 3708, "ts_rankcd_wtt", 3, true, false, ts_rankcd_wtt }, + { 3709, "ts_rankcd_ttf", 3, true, false, ts_rankcd_ttf }, + { 3710, "ts_rankcd_tt", 2, true, false, ts_rankcd_tt }, + { 3711, "tsvector_length", 1, true, false, tsvector_length }, + { 3713, "ts_token_type_byid", 1, true, true, ts_token_type_byid }, + { 3714, "ts_token_type_byname", 1, true, true, ts_token_type_byname }, + { 3715, "ts_parse_byid", 2, true, true, ts_parse_byid }, + { 3716, "ts_parse_byname", 2, true, true, ts_parse_byname }, + { 3717, "prsd_start", 2, true, false, prsd_start }, + { 3718, "prsd_nexttoken", 3, true, false, prsd_nexttoken }, + { 3719, "prsd_end", 1, true, false, prsd_end }, + { 3720, "prsd_headline", 3, true, false, prsd_headline }, + { 3721, "prsd_lextype", 1, true, false, prsd_lextype }, + { 3723, "ts_lexize", 2, true, false, ts_lexize }, + { 3724, "gin_cmp_tslexeme", 2, true, false, gin_cmp_tslexeme }, + { 3725, "dsimple_init", 1, true, false, dsimple_init }, + { 3726, "dsimple_lexize", 4, true, false, dsimple_lexize }, + { 3728, "dsynonym_init", 1, true, false, dsynonym_init }, + { 3729, "dsynonym_lexize", 4, true, false, dsynonym_lexize }, + { 3731, "dispell_init", 1, true, false, dispell_init }, + { 3732, "dispell_lexize", 4, true, false, dispell_lexize }, + { 3736, "regconfigin", 1, true, false, regconfigin }, + { 3737, "regconfigout", 1, true, false, regconfigout }, + { 3738, "regconfigrecv", 1, true, false, regconfigrecv }, + { 3739, "regconfigsend", 1, true, false, regconfigsend }, + { 3740, "thesaurus_init", 1, true, false, thesaurus_init }, + { 3741, "thesaurus_lexize", 4, true, false, thesaurus_lexize }, + { 3743, "ts_headline_byid_opt", 4, true, false, ts_headline_byid_opt }, + { 3744, "ts_headline_byid", 3, true, false, ts_headline_byid }, + { 3745, "to_tsvector_byid", 2, true, false, to_tsvector_byid }, + { 3746, "to_tsquery_byid", 2, true, false, to_tsquery_byid }, + { 3747, "plainto_tsquery_byid", 2, true, false, plainto_tsquery_byid }, + { 3749, "to_tsvector", 1, true, false, to_tsvector }, + { 3750, "to_tsquery", 1, true, false, to_tsquery }, + { 3751, "plainto_tsquery", 1, true, false, plainto_tsquery }, + { 3752, "tsvector_update_trigger_byid", 0, false, false, tsvector_update_trigger_byid }, + { 3753, "tsvector_update_trigger_bycolumn", 0, false, false, tsvector_update_trigger_bycolumn }, + { 3754, "ts_headline_opt", 3, true, false, ts_headline_opt }, + { 3755, "ts_headline", 2, true, false, ts_headline }, + { 3756, "pg_ts_parser_is_visible", 1, true, false, pg_ts_parser_is_visible }, + { 3757, "pg_ts_dict_is_visible", 1, true, false, pg_ts_dict_is_visible }, + { 3758, "pg_ts_config_is_visible", 1, true, false, pg_ts_config_is_visible }, + { 3759, "get_current_ts_config", 0, true, false, get_current_ts_config }, + { 3760, "ts_match_tt", 2, true, false, ts_match_tt }, + { 3761, "ts_match_tq", 2, true, false, ts_match_tq }, + { 3768, "pg_ts_template_is_visible", 1, true, false, pg_ts_template_is_visible }, + { 3771, "regdictionaryin", 1, true, false, regdictionaryin }, + { 3772, "regdictionaryout", 1, true, false, regdictionaryout }, + { 3773, "regdictionaryrecv", 1, true, false, regdictionaryrecv }, + { 3774, "regdictionarysend", 1, true, false, regdictionarysend }, + { 3775, "pg_stat_reset_shared", 1, true, false, pg_stat_reset_shared }, + { 3776, "pg_stat_reset_single_table_counters", 1, false, false, pg_stat_reset_single_table_counters }, + { 3777, "pg_stat_reset_single_function_counters", 1, false, false, pg_stat_reset_single_function_counters }, + { 3778, "pg_tablespace_location", 1, true, false, pg_tablespace_location }, + { 3809, "pg_export_snapshot", 0, true, false, pg_export_snapshot }, + { 3810, "pg_is_in_recovery", 0, true, false, pg_is_in_recovery }, + { 3811, "int4_cash", 1, true, false, int4_cash }, + { 3812, "int8_cash", 1, true, false, int8_cash }, + { 3815, "pg_collation_is_visible", 1, true, false, pg_collation_is_visible }, + { 3816, "array_typanalyze", 1, true, false, array_typanalyze }, + { 3817, "arraycontsel", 4, true, false, arraycontsel }, + { 3818, "arraycontjoinsel", 5, true, false, arraycontjoinsel }, + { 3820, "pg_last_xlog_receive_location", 0, true, false, pg_last_xlog_receive_location }, + { 3821, "pg_last_xlog_replay_location", 0, true, false, pg_last_xlog_replay_location }, + { 3822, "cash_div_cash", 2, true, false, cash_div_cash }, + { 3823, "cash_numeric", 1, true, false, cash_numeric }, + { 3824, "numeric_cash", 1, true, false, numeric_cash }, + { 3826, "pg_read_file_all", 1, true, false, pg_read_file_all }, + { 3827, "pg_read_binary_file", 3, true, false, pg_read_binary_file }, + { 3828, "pg_read_binary_file_all", 1, true, false, pg_read_binary_file_all }, + { 3829, "pg_opfamily_is_visible", 1, true, false, pg_opfamily_is_visible }, + { 3830, "pg_last_xact_replay_timestamp", 0, true, false, pg_last_xact_replay_timestamp }, + { 3832, "anyrange_in", 3, true, false, anyrange_in }, + { 3833, "anyrange_out", 1, true, false, anyrange_out }, + { 3834, "range_in", 3, true, false, range_in }, + { 3835, "range_out", 1, true, false, range_out }, + { 3836, "range_recv", 3, true, false, range_recv }, + { 3837, "range_send", 1, true, false, range_send }, + { 3840, "range_constructor2", 2, false, false, range_constructor2 }, + { 3841, "range_constructor3", 3, false, false, range_constructor3 }, + { 3844, "range_constructor2", 2, false, false, range_constructor2 }, + { 3845, "range_constructor3", 3, false, false, range_constructor3 }, + { 3848, "range_lower", 1, true, false, range_lower }, + { 3849, "range_upper", 1, true, false, range_upper }, + { 3850, "range_empty", 1, true, false, range_empty }, + { 3851, "range_lower_inc", 1, true, false, range_lower_inc }, + { 3852, "range_upper_inc", 1, true, false, range_upper_inc }, + { 3853, "range_lower_inf", 1, true, false, range_lower_inf }, + { 3854, "range_upper_inf", 1, true, false, range_upper_inf }, + { 3855, "range_eq", 2, true, false, range_eq }, + { 3856, "range_ne", 2, true, false, range_ne }, + { 3857, "range_overlaps", 2, true, false, range_overlaps }, + { 3858, "range_contains_elem", 2, true, false, range_contains_elem }, + { 3859, "range_contains", 2, true, false, range_contains }, + { 3860, "elem_contained_by_range", 2, true, false, elem_contained_by_range }, + { 3861, "range_contained_by", 2, true, false, range_contained_by }, + { 3862, "range_adjacent", 2, true, false, range_adjacent }, + { 3863, "range_before", 2, true, false, range_before }, + { 3864, "range_after", 2, true, false, range_after }, + { 3865, "range_overleft", 2, true, false, range_overleft }, + { 3866, "range_overright", 2, true, false, range_overright }, + { 3867, "range_union", 2, true, false, range_union }, + { 3868, "range_intersect", 2, true, false, range_intersect }, + { 3869, "range_minus", 2, true, false, range_minus }, + { 3870, "range_cmp", 2, true, false, range_cmp }, + { 3871, "range_lt", 2, true, false, range_lt }, + { 3872, "range_le", 2, true, false, range_le }, + { 3873, "range_ge", 2, true, false, range_ge }, + { 3874, "range_gt", 2, true, false, range_gt }, + { 3875, "range_gist_consistent", 5, true, false, range_gist_consistent }, + { 3876, "range_gist_union", 2, true, false, range_gist_union }, + { 3877, "range_gist_compress", 1, true, false, range_gist_compress }, + { 3878, "range_gist_decompress", 1, true, false, range_gist_decompress }, + { 3879, "range_gist_penalty", 3, true, false, range_gist_penalty }, + { 3880, "range_gist_picksplit", 2, true, false, range_gist_picksplit }, + { 3881, "range_gist_same", 3, true, false, range_gist_same }, + { 3902, "hash_range", 1, true, false, hash_range }, + { 3914, "int4range_canonical", 1, true, false, int4range_canonical }, + { 3915, "daterange_canonical", 1, true, false, daterange_canonical }, + { 3916, "range_typanalyze", 1, true, false, range_typanalyze }, + { 3917, "timestamp_transform", 1, true, false, timestamp_transform }, + { 3918, "interval_transform", 1, true, false, interval_transform }, + { 3922, "int4range_subdiff", 2, true, false, int4range_subdiff }, + { 3923, "int8range_subdiff", 2, true, false, int8range_subdiff }, + { 3924, "numrange_subdiff", 2, true, false, numrange_subdiff }, + { 3925, "daterange_subdiff", 2, true, false, daterange_subdiff }, + { 3928, "int8range_canonical", 1, true, false, int8range_canonical }, + { 3929, "tsrange_subdiff", 2, true, false, tsrange_subdiff }, + { 3930, "tstzrange_subdiff", 2, true, false, tstzrange_subdiff }, + { 3933, "range_constructor2", 2, false, false, range_constructor2 }, + { 3934, "range_constructor3", 3, false, false, range_constructor3 }, + { 3937, "range_constructor2", 2, false, false, range_constructor2 }, + { 3938, "range_constructor3", 3, false, false, range_constructor3 }, + { 3941, "range_constructor2", 2, false, false, range_constructor2 }, + { 3942, "range_constructor3", 3, false, false, range_constructor3 }, + { 3943, "acldefault_sql", 2, true, false, acldefault_sql }, + { 3944, "time_transform", 1, true, false, time_transform }, + { 3945, "range_constructor2", 2, false, false, range_constructor2 }, + { 3946, "range_constructor3", 3, false, false, range_constructor3 }, + { 4001, "spggettuple", 2, true, false, spggettuple }, + { 4002, "spggetbitmap", 2, true, false, spggetbitmap }, + { 4003, "spginsert", 6, true, false, spginsert }, + { 4004, "spgbeginscan", 3, true, false, spgbeginscan }, + { 4005, "spgrescan", 5, true, false, spgrescan }, + { 4006, "spgendscan", 1, true, false, spgendscan }, + { 4007, "spgmarkpos", 1, true, false, spgmarkpos }, + { 4008, "spgrestrpos", 1, true, false, spgrestrpos }, + { 4009, "spgbuild", 3, true, false, spgbuild }, + { 4010, "spgbuildempty", 1, true, false, spgbuildempty }, + { 4011, "spgbulkdelete", 4, true, false, spgbulkdelete }, + { 4012, "spgvacuumcleanup", 2, true, false, spgvacuumcleanup }, + { 4013, "spgcostestimate", 7, true, false, spgcostestimate }, + { 4014, "spgoptions", 2, true, false, spgoptions }, + { 4018, "spg_quad_config", 2, true, false, spg_quad_config }, + { 4019, "spg_quad_choose", 2, true, false, spg_quad_choose }, + { 4020, "spg_quad_picksplit", 2, true, false, spg_quad_picksplit }, + { 4021, "spg_quad_inner_consistent", 2, true, false, spg_quad_inner_consistent }, + { 4022, "spg_quad_leaf_consistent", 2, true, false, spg_quad_leaf_consistent }, + { 4023, "spg_kd_config", 2, true, false, spg_kd_config }, + { 4024, "spg_kd_choose", 2, true, false, spg_kd_choose }, + { 4025, "spg_kd_picksplit", 2, true, false, spg_kd_picksplit }, + { 4026, "spg_kd_inner_consistent", 2, true, false, spg_kd_inner_consistent }, + { 4027, "spg_text_config", 2, true, false, spg_text_config }, + { 4028, "spg_text_choose", 2, true, false, spg_text_choose }, + { 4029, "spg_text_picksplit", 2, true, false, spg_text_picksplit }, + { 4030, "spg_text_inner_consistent", 2, true, false, spg_text_inner_consistent }, + { 4031, "spg_text_leaf_consistent", 2, true, false, spg_text_leaf_consistent }, + { 4032, "spgcanreturn", 1, true, false, spgcanreturn }, + /* dummy entry is easier than getting rid of comma after last real one */ + /* (not that there has ever been anything wrong with *having* a + comma after the last field in an array initializer) */ + { 0, NULL, 0, false, false, NULL } +}; + +/* Note fmgr_nbuiltins excludes the dummy entry */ +const int fmgr_nbuiltins = (sizeof(fmgr_builtins) / sizeof(FmgrBuiltin)) - 1; diff --git a/src/backend/utils/mb/conversion_procs/.gitignore b/src/backend/utils/mb/conversion_procs/.gitignore deleted file mode 100644 index 3e30742a1..000000000 --- a/src/backend/utils/mb/conversion_procs/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/conversion_create.sql diff --git a/src/backend/utils/misc/.gitignore b/src/backend/utils/misc/.gitignore deleted file mode 100644 index 495b1aec7..000000000 --- a/src/backend/utils/misc/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/guc-file.c diff --git a/src/backend/utils/misc/guc-file.c b/src/backend/utils/misc/guc-file.c new file mode 100644 index 000000000..6f4f412fe --- /dev/null +++ b/src/backend/utils/misc/guc-file.c @@ -0,0 +1,2547 @@ +#line 2 "guc-file.c" + +#line 4 "guc-file.c" + +#define YY_INT_ALIGNED short int + +/* A lexical scanner generated by flex */ + +#define yy_create_buffer GUC_yy_create_buffer +#define yy_delete_buffer GUC_yy_delete_buffer +#define yy_flex_debug GUC_yy_flex_debug +#define yy_init_buffer GUC_yy_init_buffer +#define yy_flush_buffer GUC_yy_flush_buffer +#define yy_load_buffer_state GUC_yy_load_buffer_state +#define yy_switch_to_buffer GUC_yy_switch_to_buffer +#define yyin GUC_yyin +#define yyleng GUC_yyleng +#define yylex GUC_yylex +#define yylineno GUC_yylineno +#define yyout GUC_yyout +#define yyrestart GUC_yyrestart +#define yytext GUC_yytext +#define yywrap GUC_yywrap +#define yyalloc GUC_yyalloc +#define yyrealloc GUC_yyrealloc +#define yyfree GUC_yyfree + +#define FLEX_SCANNER +#define YY_FLEX_MAJOR_VERSION 2 +#define YY_FLEX_MINOR_VERSION 5 +#define YY_FLEX_SUBMINOR_VERSION 35 +#if YY_FLEX_SUBMINOR_VERSION > 0 +#define FLEX_BETA +#endif + +/* First, we deal with platform-specific or compiler-specific issues. */ + +/* begin standard C headers. */ +#include +#include +#include +#include + +/* end standard C headers. */ + +/* flex integer type definitions */ + +#ifndef FLEXINT_H +#define FLEXINT_H + +/* C99 systems have . Non-C99 systems may or may not. */ + +#if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L + +/* C99 says to define __STDC_LIMIT_MACROS before including stdint.h, + * if you want the limit (max/min) macros for int types. + */ +#ifndef __STDC_LIMIT_MACROS +#define __STDC_LIMIT_MACROS 1 +#endif + +#include +typedef int8_t flex_int8_t; +typedef uint8_t flex_uint8_t; +typedef int16_t flex_int16_t; +typedef uint16_t flex_uint16_t; +typedef int32_t flex_int32_t; +typedef uint32_t flex_uint32_t; +#else +typedef signed char flex_int8_t; +typedef short int flex_int16_t; +typedef int flex_int32_t; +typedef unsigned char flex_uint8_t; +typedef unsigned short int flex_uint16_t; +typedef unsigned int flex_uint32_t; + +/* Limits of integral types. */ +#ifndef INT8_MIN +#define INT8_MIN (-128) +#endif +#ifndef INT16_MIN +#define INT16_MIN (-32767-1) +#endif +#ifndef INT32_MIN +#define INT32_MIN (-2147483647-1) +#endif +#ifndef INT8_MAX +#define INT8_MAX (127) +#endif +#ifndef INT16_MAX +#define INT16_MAX (32767) +#endif +#ifndef INT32_MAX +#define INT32_MAX (2147483647) +#endif +#ifndef UINT8_MAX +#define UINT8_MAX (255U) +#endif +#ifndef UINT16_MAX +#define UINT16_MAX (65535U) +#endif +#ifndef UINT32_MAX +#define UINT32_MAX (4294967295U) +#endif + +#endif /* ! C99 */ + +#endif /* ! FLEXINT_H */ + +#ifdef __cplusplus + +/* The "const" storage-class-modifier is valid. */ +#define YY_USE_CONST + +#else /* ! __cplusplus */ + +/* C99 requires __STDC__ to be defined as 1. */ +#if defined (__STDC__) + +#define YY_USE_CONST + +#endif /* defined (__STDC__) */ +#endif /* ! __cplusplus */ + +#ifdef YY_USE_CONST +#define yyconst const +#else +#define yyconst +#endif + +/* Returned upon end-of-file. */ +#define YY_NULL 0 + +/* Promotes a possibly negative, possibly signed char to an unsigned + * integer for use as an array index. If the signed char is negative, + * we want to instead treat it as an 8-bit unsigned char, hence the + * double cast. + */ +#define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c) + +/* Enter a start condition. This macro really ought to take a parameter, + * but we do it the disgusting crufty way forced on us by the ()-less + * definition of BEGIN. + */ +#define BEGIN (yy_start) = 1 + 2 * + +/* Translate the current start state into a value that can be later handed + * to BEGIN to return to the state. The YYSTATE alias is for lex + * compatibility. + */ +#define YY_START (((yy_start) - 1) / 2) +#define YYSTATE YY_START + +/* Action number for EOF rule of a given start state. */ +#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1) + +/* Special action meaning "start processing a new file". */ +#define YY_NEW_FILE GUC_yyrestart(GUC_yyin ) + +#define YY_END_OF_BUFFER_CHAR 0 + +/* Size of default input buffer. */ +#ifndef YY_BUF_SIZE +#ifdef __ia64__ +/* On IA-64, the buffer size is 16k, not 8k. + * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case. + * Ditto for the __ia64__ case accordingly. + */ +#define YY_BUF_SIZE 32768 +#else +#define YY_BUF_SIZE 16384 +#endif /* __ia64__ */ +#endif + +/* The state buf must be large enough to hold one state per character in the main buffer. + */ +#define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type)) + +#ifndef YY_TYPEDEF_YY_BUFFER_STATE +#define YY_TYPEDEF_YY_BUFFER_STATE +typedef struct yy_buffer_state *YY_BUFFER_STATE; +#endif + +extern int GUC_yyleng; + +extern FILE *GUC_yyin, *GUC_yyout; + +#define EOB_ACT_CONTINUE_SCAN 0 +#define EOB_ACT_END_OF_FILE 1 +#define EOB_ACT_LAST_MATCH 2 + + #define YY_LESS_LINENO(n) + +/* Return all but the first "n" matched characters back to the input stream. */ +#define yyless(n) \ + do \ + { \ + /* Undo effects of setting up GUC_yytext. */ \ + int yyless_macro_arg = (n); \ + YY_LESS_LINENO(yyless_macro_arg);\ + *yy_cp = (yy_hold_char); \ + YY_RESTORE_YY_MORE_OFFSET \ + (yy_c_buf_p) = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \ + YY_DO_BEFORE_ACTION; /* set up GUC_yytext again */ \ + } \ + while ( 0 ) + +#define unput(c) yyunput( c, (yytext_ptr) ) + +#ifndef YY_TYPEDEF_YY_SIZE_T +#define YY_TYPEDEF_YY_SIZE_T +typedef size_t yy_size_t; +#endif + +#ifndef YY_STRUCT_YY_BUFFER_STATE +#define YY_STRUCT_YY_BUFFER_STATE +struct yy_buffer_state + { + FILE *yy_input_file; + + char *yy_ch_buf; /* input buffer */ + char *yy_buf_pos; /* current position in input buffer */ + + /* Size of input buffer in bytes, not including room for EOB + * characters. + */ + yy_size_t yy_buf_size; + + /* Number of characters read into yy_ch_buf, not including EOB + * characters. + */ + int yy_n_chars; + + /* Whether we "own" the buffer - i.e., we know we created it, + * and can realloc() it to grow it, and should free() it to + * delete it. + */ + int yy_is_our_buffer; + + /* Whether this is an "interactive" input source; if so, and + * if we're using stdio for input, then we want to use getc() + * instead of fread(), to make sure we stop fetching input after + * each newline. + */ + int yy_is_interactive; + + /* Whether we're considered to be at the beginning of a line. + * If so, '^' rules will be active on the next match, otherwise + * not. + */ + int yy_at_bol; + + int yy_bs_lineno; /**< The line count. */ + int yy_bs_column; /**< The column count. */ + + /* Whether to try to fill the input buffer when we reach the + * end of it. + */ + int yy_fill_buffer; + + int yy_buffer_status; + +#define YY_BUFFER_NEW 0 +#define YY_BUFFER_NORMAL 1 + /* When an EOF's been seen but there's still some text to process + * then we mark the buffer as YY_EOF_PENDING, to indicate that we + * shouldn't try reading from the input source any more. We might + * still have a bunch of tokens to match, though, because of + * possible backing-up. + * + * When we actually see the EOF, we change the status to "new" + * (via GUC_yyrestart()), so that the user can continue scanning by + * just pointing GUC_yyin at a new input file. + */ +#define YY_BUFFER_EOF_PENDING 2 + + }; +#endif /* !YY_STRUCT_YY_BUFFER_STATE */ + +/* Stack of input buffers. */ +static size_t yy_buffer_stack_top = 0; /**< index of top of stack. */ +static size_t yy_buffer_stack_max = 0; /**< capacity of stack. */ +static YY_BUFFER_STATE * yy_buffer_stack = 0; /**< Stack as an array. */ + +/* We provide macros for accessing buffer states in case in the + * future we want to put the buffer states in a more general + * "scanner state". + * + * Returns the top of the stack, or NULL. + */ +#define YY_CURRENT_BUFFER ( (yy_buffer_stack) \ + ? (yy_buffer_stack)[(yy_buffer_stack_top)] \ + : NULL) + +/* Same as previous macro, but useful when we know that the buffer stack is not + * NULL or when we need an lvalue. For internal use only. + */ +#define YY_CURRENT_BUFFER_LVALUE (yy_buffer_stack)[(yy_buffer_stack_top)] + +/* yy_hold_char holds the character lost when GUC_yytext is formed. */ +static char yy_hold_char; +static int yy_n_chars; /* number of characters read into yy_ch_buf */ +int GUC_yyleng; + +/* Points to current character in buffer. */ +static char *yy_c_buf_p = (char *) 0; +static int yy_init = 0; /* whether we need to initialize */ +static int yy_start = 0; /* start state number */ + +/* Flag which is used to allow GUC_yywrap()'s to do buffer switches + * instead of setting up a fresh GUC_yyin. A bit of a hack ... + */ +static int yy_did_buffer_switch_on_eof; + +void GUC_yyrestart (FILE *input_file ); +void GUC_yy_switch_to_buffer (YY_BUFFER_STATE new_buffer ); +YY_BUFFER_STATE GUC_yy_create_buffer (FILE *file,int size ); +void GUC_yy_delete_buffer (YY_BUFFER_STATE b ); +void GUC_yy_flush_buffer (YY_BUFFER_STATE b ); +void GUC_yypush_buffer_state (YY_BUFFER_STATE new_buffer ); +void GUC_yypop_buffer_state (void ); + +static void GUC_yyensure_buffer_stack (void ); +static void GUC_yy_load_buffer_state (void ); +static void GUC_yy_init_buffer (YY_BUFFER_STATE b,FILE *file ); + +#define YY_FLUSH_BUFFER GUC_yy_flush_buffer(YY_CURRENT_BUFFER ) + +YY_BUFFER_STATE GUC_yy_scan_buffer (char *base,yy_size_t size ); +YY_BUFFER_STATE GUC_yy_scan_string (yyconst char *yy_str ); +YY_BUFFER_STATE GUC_yy_scan_bytes (yyconst char *bytes,int len ); + +void *GUC_yyalloc (yy_size_t ); +void *GUC_yyrealloc (void *,yy_size_t ); +void GUC_yyfree (void * ); + +#define yy_new_buffer GUC_yy_create_buffer + +#define yy_set_interactive(is_interactive) \ + { \ + if ( ! YY_CURRENT_BUFFER ){ \ + GUC_yyensure_buffer_stack (); \ + YY_CURRENT_BUFFER_LVALUE = \ + GUC_yy_create_buffer(GUC_yyin,YY_BUF_SIZE ); \ + } \ + YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \ + } + +#define yy_set_bol(at_bol) \ + { \ + if ( ! YY_CURRENT_BUFFER ){\ + GUC_yyensure_buffer_stack (); \ + YY_CURRENT_BUFFER_LVALUE = \ + GUC_yy_create_buffer(GUC_yyin,YY_BUF_SIZE ); \ + } \ + YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \ + } + +#define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol) + +/* Begin user sect3 */ + +#define GUC_yywrap(n) 1 +#define YY_SKIP_YYWRAP + +typedef unsigned char YY_CHAR; + +FILE *GUC_yyin = (FILE *) 0, *GUC_yyout = (FILE *) 0; + +typedef int yy_state_type; + +extern int GUC_yylineno; + +int GUC_yylineno = 1; + +extern char *GUC_yytext; +#define yytext_ptr GUC_yytext + +static yy_state_type yy_get_previous_state (void ); +static yy_state_type yy_try_NUL_trans (yy_state_type current_state ); +static int yy_get_next_buffer (void ); +static void yy_fatal_error (yyconst char msg[] ); + +/* Done after the current pattern has been matched and before the + * corresponding action - sets up GUC_yytext. + */ +#define YY_DO_BEFORE_ACTION \ + (yytext_ptr) = yy_bp; \ + GUC_yyleng = (size_t) (yy_cp - yy_bp); \ + (yy_hold_char) = *yy_cp; \ + *yy_cp = '\0'; \ + (yy_c_buf_p) = yy_cp; + +#define YY_NUM_RULES 12 +#define YY_END_OF_BUFFER 13 +/* This struct is not used in this scanner, + but its presence is necessary. */ +struct yy_trans_info + { + flex_int32_t yy_verify; + flex_int32_t yy_nxt; + }; +static yyconst flex_int16_t yy_accept[41] = + { 0, + 0, 0, 13, 11, 2, 1, 3, 11, 11, 9, + 8, 8, 10, 4, 2, 3, 0, 6, 0, 9, + 8, 8, 9, 0, 8, 8, 7, 7, 4, 4, + 0, 9, 8, 8, 7, 5, 5, 5, 5, 0 + } ; + +static yyconst flex_int32_t yy_ec[256] = + { 0, + 1, 1, 1, 1, 1, 1, 1, 1, 2, 3, + 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 2, 1, 1, 4, 1, 1, 1, 5, 1, + 1, 1, 6, 1, 7, 8, 9, 10, 11, 11, + 11, 11, 11, 11, 11, 11, 11, 9, 1, 1, + 12, 1, 1, 1, 13, 13, 13, 13, 14, 13, + 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, + 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, + 1, 16, 1, 1, 17, 1, 13, 13, 13, 13, + + 14, 13, 15, 15, 15, 15, 15, 15, 15, 15, + 15, 15, 15, 15, 15, 15, 15, 15, 15, 18, + 15, 15, 1, 1, 1, 1, 1, 19, 19, 19, + 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, + 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, + 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, + 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, + 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, + 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, + 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, + + 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, + 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, + 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, + 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, + 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, + 19, 19, 19, 19, 19 + } ; + +static yyconst flex_int32_t yy_meta[20] = + { 0, + 1, 1, 2, 1, 1, 1, 3, 3, 3, 4, + 4, 1, 5, 6, 5, 1, 3, 5, 3 + } ; + +static yyconst flex_int16_t yy_base[48] = + { 0, + 0, 0, 50, 148, 43, 148, 0, 15, 24, 30, + 28, 22, 148, 40, 35, 0, 17, 25, 0, 15, + 0, 10, 0, 52, 0, 54, 10, 66, 79, 0, + 13, 15, 0, 0, 4, 90, 101, 0, 0, 148, + 118, 124, 127, 131, 133, 137, 141 + } ; + +static yyconst flex_int16_t yy_def[48] = + { 0, + 40, 1, 40, 40, 40, 40, 41, 42, 40, 43, + 40, 11, 40, 44, 40, 41, 42, 40, 42, 43, + 11, 11, 20, 40, 45, 40, 46, 40, 44, 29, + 40, 40, 26, 26, 46, 47, 47, 37, 37, 0, + 40, 40, 40, 40, 40, 40, 40 + } ; + +static yyconst flex_int16_t yy_nxt[168] = + { 0, + 4, 5, 6, 7, 8, 9, 9, 10, 4, 11, + 12, 13, 14, 14, 14, 4, 14, 14, 14, 18, + 35, 18, 32, 32, 32, 32, 35, 25, 24, 17, + 19, 20, 19, 21, 22, 20, 15, 22, 22, 25, + 25, 25, 25, 24, 15, 26, 27, 28, 27, 40, + 40, 40, 40, 40, 40, 40, 30, 31, 31, 40, + 40, 32, 32, 33, 33, 40, 34, 34, 25, 40, + 40, 25, 27, 27, 27, 27, 27, 40, 36, 36, + 36, 40, 37, 36, 36, 27, 28, 27, 40, 40, + 40, 40, 40, 40, 40, 30, 27, 27, 27, 40, + + 40, 40, 40, 40, 40, 40, 39, 27, 27, 27, + 40, 40, 40, 40, 40, 40, 40, 39, 16, 40, + 16, 16, 16, 16, 17, 40, 17, 17, 17, 17, + 23, 40, 23, 29, 29, 29, 29, 25, 25, 27, + 27, 27, 27, 38, 38, 38, 38, 3, 40, 40, + 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, + 40, 40, 40, 40, 40, 40, 40 + } ; + +static yyconst flex_int16_t yy_chk[168] = + { 0, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 8, + 35, 17, 31, 31, 32, 32, 27, 22, 20, 18, + 8, 9, 17, 9, 9, 11, 15, 11, 11, 12, + 11, 11, 11, 10, 5, 11, 14, 14, 14, 3, + 0, 0, 0, 0, 0, 0, 14, 24, 24, 0, + 0, 24, 24, 26, 26, 0, 26, 26, 26, 0, + 0, 26, 28, 28, 28, 28, 28, 0, 28, 28, + 28, 0, 28, 28, 28, 29, 29, 29, 0, 0, + 0, 0, 0, 0, 0, 29, 36, 36, 36, 0, + + 0, 0, 0, 0, 0, 0, 36, 37, 37, 37, + 0, 0, 0, 0, 0, 0, 0, 37, 41, 0, + 41, 41, 41, 41, 42, 0, 42, 42, 42, 42, + 43, 0, 43, 44, 44, 44, 44, 45, 45, 46, + 46, 46, 46, 47, 47, 47, 47, 40, 40, 40, + 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, + 40, 40, 40, 40, 40, 40, 40 + } ; + +static yy_state_type yy_last_accepting_state; +static char *yy_last_accepting_cpos; + +extern int GUC_yy_flex_debug; +int GUC_yy_flex_debug = 0; + +/* The intent behind this definition is that it'll catch + * any uses of REJECT which flex missed. + */ +#define REJECT reject_used_but_not_detected +#define yymore() yymore_used_but_not_detected +#define YY_MORE_ADJ 0 +#define YY_RESTORE_YY_MORE_OFFSET +char *GUC_yytext; +#line 1 "guc-file.l" +/* -*-pgsql-c-*- */ +/* + * Scanner for the configuration file + * + * Copyright (c) 2000-2012, PostgreSQL Global Development Group + * + * src/backend/utils/misc/guc-file.l + */ +#line 11 "guc-file.l" + +#include "postgres.h" + +#include +#include + +#include "mb/pg_wchar.h" +#include "miscadmin.h" +#include "storage/fd.h" +#include "utils/guc.h" + + +/* + * flex emits a yy_fatal_error() function that it calls in response to + * critical errors like malloc failure, file I/O errors, and detection of + * internal inconsistency. That function prints a message and calls exit(). + * Mutate it to instead call our handler, which jumps out of the parser. + */ +#undef fprintf +#define fprintf(file, fmt, msg) GUC_flex_fatal(msg) + +enum { + GUC_ID = 1, + GUC_STRING = 2, + GUC_INTEGER = 3, + GUC_REAL = 4, + GUC_EQUALS = 5, + GUC_UNQUOTED_STRING = 6, + GUC_QUALIFIED_ID = 7, + GUC_EOL = 99, + GUC_ERROR = 100 +}; + +static unsigned int ConfigFileLineno; +static const char *GUC_flex_fatal_errmsg; +static sigjmp_buf *GUC_flex_fatal_jmp; + +/* flex fails to supply a prototype for GUC_yylex, so provide one */ +int GUC_yylex(void); + +static int GUC_flex_fatal(const char *msg); +static char *GUC_scanstr(const char *s); + +#define YY_NO_INPUT 1 +#line 580 "guc-file.c" + +#define INITIAL 0 + +#ifndef YY_NO_UNISTD_H +/* Special case for "unistd.h", since it is non-ANSI. We include it way + * down here because we want the user's section 1 to have been scanned first. + * The user has a chance to override it with an option. + */ +#include +#endif + +#ifndef YY_EXTRA_TYPE +#define YY_EXTRA_TYPE void * +#endif + +static int yy_init_globals (void ); + +/* Accessor methods to globals. + These are made visible to non-reentrant scanners for convenience. */ + +int GUC_yylex_destroy (void ); + +int GUC_yyget_debug (void ); + +void GUC_yyset_debug (int debug_flag ); + +YY_EXTRA_TYPE GUC_yyget_extra (void ); + +void GUC_yyset_extra (YY_EXTRA_TYPE user_defined ); + +FILE *GUC_yyget_in (void ); + +void GUC_yyset_in (FILE * in_str ); + +FILE *GUC_yyget_out (void ); + +void GUC_yyset_out (FILE * out_str ); + +int GUC_yyget_leng (void ); + +char *GUC_yyget_text (void ); + +int GUC_yyget_lineno (void ); + +void GUC_yyset_lineno (int line_number ); + +/* Macros after this point can all be overridden by user definitions in + * section 1. + */ + +#ifndef YY_SKIP_YYWRAP +#ifdef __cplusplus +extern "C" int GUC_yywrap (void ); +#else +extern int GUC_yywrap (void ); +#endif +#endif + +#ifndef yytext_ptr +static void yy_flex_strncpy (char *,yyconst char *,int ); +#endif + +#ifdef YY_NEED_STRLEN +static int yy_flex_strlen (yyconst char * ); +#endif + +#ifndef YY_NO_INPUT + +#ifdef __cplusplus +static int yyinput (void ); +#else +static int input (void ); +#endif + +#endif + +/* Amount of stuff to slurp up with each read. */ +#ifndef YY_READ_BUF_SIZE +#ifdef __ia64__ +/* On IA-64, the buffer size is 16k, not 8k */ +#define YY_READ_BUF_SIZE 16384 +#else +#define YY_READ_BUF_SIZE 8192 +#endif /* __ia64__ */ +#endif + +/* Copy whatever the last rule matched to the standard output. */ +#ifndef ECHO +/* This used to be an fputs(), but since the string might contain NUL's, + * we now use fwrite(). + */ +#define ECHO do { if (fwrite( GUC_yytext, GUC_yyleng, 1, GUC_yyout )) {} } while (0) +#endif + +/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL, + * is returned in "result". + */ +#ifndef YY_INPUT +#define YY_INPUT(buf,result,max_size) \ + if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \ + { \ + int c = '*'; \ + size_t n; \ + for ( n = 0; n < max_size && \ + (c = getc( GUC_yyin )) != EOF && c != '\n'; ++n ) \ + buf[n] = (char) c; \ + if ( c == '\n' ) \ + buf[n++] = (char) c; \ + if ( c == EOF && ferror( GUC_yyin ) ) \ + YY_FATAL_ERROR( "input in flex scanner failed" ); \ + result = n; \ + } \ + else \ + { \ + errno=0; \ + while ( (result = fread(buf, 1, max_size, GUC_yyin))==0 && ferror(GUC_yyin)) \ + { \ + if( errno != EINTR) \ + { \ + YY_FATAL_ERROR( "input in flex scanner failed" ); \ + break; \ + } \ + errno=0; \ + clearerr(GUC_yyin); \ + } \ + }\ +\ + +#endif + +/* No semi-colon after return; correct usage is to write "yyterminate();" - + * we don't want an extra ';' after the "return" because that will cause + * some compilers to complain about unreachable statements. + */ +#ifndef yyterminate +#define yyterminate() return YY_NULL +#endif + +/* Number of entries by which start-condition stack grows. */ +#ifndef YY_START_STACK_INCR +#define YY_START_STACK_INCR 25 +#endif + +/* Report a fatal error. */ +#ifndef YY_FATAL_ERROR +#define YY_FATAL_ERROR(msg) yy_fatal_error( msg ) +#endif + +/* end tables serialization structures and prototypes */ + +/* Default declaration of generated scanner - a define so the user can + * easily add parameters. + */ +#ifndef YY_DECL +#define YY_DECL_IS_OURS 1 + +extern int GUC_yylex (void); + +#define YY_DECL int GUC_yylex (void) +#endif /* !YY_DECL */ + +/* Code executed at the beginning of each rule, after GUC_yytext and GUC_yyleng + * have been set up. + */ +#ifndef YY_USER_ACTION +#define YY_USER_ACTION +#endif + +/* Code executed at the end of each rule. */ +#ifndef YY_BREAK +#define YY_BREAK break; +#endif + +#define YY_RULE_SETUP \ + YY_USER_ACTION + +/** The main scanner function which does all the work. + */ +YY_DECL +{ + register yy_state_type yy_current_state; + register char *yy_cp, *yy_bp; + register int yy_act; + +#line 86 "guc-file.l" + + +#line 768 "guc-file.c" + + if ( !(yy_init) ) + { + (yy_init) = 1; + +#ifdef YY_USER_INIT + YY_USER_INIT; +#endif + + if ( ! (yy_start) ) + (yy_start) = 1; /* first start state */ + + if ( ! GUC_yyin ) + GUC_yyin = stdin; + + if ( ! GUC_yyout ) + GUC_yyout = stdout; + + if ( ! YY_CURRENT_BUFFER ) { + GUC_yyensure_buffer_stack (); + YY_CURRENT_BUFFER_LVALUE = + GUC_yy_create_buffer(GUC_yyin,YY_BUF_SIZE ); + } + + GUC_yy_load_buffer_state( ); + } + + while ( 1 ) /* loops until end-of-file is reached */ + { + yy_cp = (yy_c_buf_p); + + /* Support of GUC_yytext. */ + *yy_cp = (yy_hold_char); + + /* yy_bp points to the position in yy_ch_buf of the start of + * the current run. + */ + yy_bp = yy_cp; + + yy_current_state = (yy_start); +yy_match: + do + { + register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)]; + if ( yy_accept[yy_current_state] ) + { + (yy_last_accepting_state) = yy_current_state; + (yy_last_accepting_cpos) = yy_cp; + } + while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) + { + yy_current_state = (int) yy_def[yy_current_state]; + if ( yy_current_state >= 41 ) + yy_c = yy_meta[(unsigned int) yy_c]; + } + yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; + ++yy_cp; + } + while ( yy_current_state != 40 ); + yy_cp = (yy_last_accepting_cpos); + yy_current_state = (yy_last_accepting_state); + +yy_find_action: + yy_act = yy_accept[yy_current_state]; + + YY_DO_BEFORE_ACTION; + +do_action: /* This label is used only to access EOF actions. */ + + switch ( yy_act ) + { /* beginning of action switch */ + case 0: /* must back up */ + /* undo the effects of YY_DO_BEFORE_ACTION */ + *yy_cp = (yy_hold_char); + yy_cp = (yy_last_accepting_cpos); + yy_current_state = (yy_last_accepting_state); + goto yy_find_action; + +case 1: +/* rule 1 can match eol */ +YY_RULE_SETUP +#line 88 "guc-file.l" +ConfigFileLineno++; return GUC_EOL; + YY_BREAK +case 2: +YY_RULE_SETUP +#line 89 "guc-file.l" +/* eat whitespace */ + YY_BREAK +case 3: +YY_RULE_SETUP +#line 90 "guc-file.l" +/* eat comment (.* matches anything until newline) */ + YY_BREAK +case 4: +YY_RULE_SETUP +#line 92 "guc-file.l" +return GUC_ID; + YY_BREAK +case 5: +YY_RULE_SETUP +#line 93 "guc-file.l" +return GUC_QUALIFIED_ID; + YY_BREAK +case 6: +YY_RULE_SETUP +#line 94 "guc-file.l" +return GUC_STRING; + YY_BREAK +case 7: +YY_RULE_SETUP +#line 95 "guc-file.l" +return GUC_UNQUOTED_STRING; + YY_BREAK +case 8: +YY_RULE_SETUP +#line 96 "guc-file.l" +return GUC_INTEGER; + YY_BREAK +case 9: +YY_RULE_SETUP +#line 97 "guc-file.l" +return GUC_REAL; + YY_BREAK +case 10: +YY_RULE_SETUP +#line 98 "guc-file.l" +return GUC_EQUALS; + YY_BREAK +case 11: +YY_RULE_SETUP +#line 100 "guc-file.l" +return GUC_ERROR; + YY_BREAK +case 12: +YY_RULE_SETUP +#line 102 "guc-file.l" +YY_FATAL_ERROR( "flex scanner jammed" ); + YY_BREAK +#line 908 "guc-file.c" +case YY_STATE_EOF(INITIAL): + yyterminate(); + + case YY_END_OF_BUFFER: + { + /* Amount of text matched not including the EOB char. */ + int yy_amount_of_matched_text = (int) (yy_cp - (yytext_ptr)) - 1; + + /* Undo the effects of YY_DO_BEFORE_ACTION. */ + *yy_cp = (yy_hold_char); + YY_RESTORE_YY_MORE_OFFSET + + if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW ) + { + /* We're scanning a new file or input source. It's + * possible that this happened because the user + * just pointed GUC_yyin at a new source and called + * GUC_yylex(). If so, then we have to assure + * consistency between YY_CURRENT_BUFFER and our + * globals. Here is the right place to do so, because + * this is the first action (other than possibly a + * back-up) that will match for the new input source. + */ + (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars; + YY_CURRENT_BUFFER_LVALUE->yy_input_file = GUC_yyin; + YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL; + } + + /* Note that here we test for yy_c_buf_p "<=" to the position + * of the first EOB in the buffer, since yy_c_buf_p will + * already have been incremented past the NUL character + * (since all states make transitions on EOB to the + * end-of-buffer state). Contrast this with the test + * in input(). + */ + if ( (yy_c_buf_p) <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] ) + { /* This was really a NUL. */ + yy_state_type yy_next_state; + + (yy_c_buf_p) = (yytext_ptr) + yy_amount_of_matched_text; + + yy_current_state = yy_get_previous_state( ); + + /* Okay, we're now positioned to make the NUL + * transition. We couldn't have + * yy_get_previous_state() go ahead and do it + * for us because it doesn't know how to deal + * with the possibility of jamming (and we don't + * want to build jamming into it because then it + * will run more slowly). + */ + + yy_next_state = yy_try_NUL_trans( yy_current_state ); + + yy_bp = (yytext_ptr) + YY_MORE_ADJ; + + if ( yy_next_state ) + { + /* Consume the NUL. */ + yy_cp = ++(yy_c_buf_p); + yy_current_state = yy_next_state; + goto yy_match; + } + + else + { + yy_cp = (yy_last_accepting_cpos); + yy_current_state = (yy_last_accepting_state); + goto yy_find_action; + } + } + + else switch ( yy_get_next_buffer( ) ) + { + case EOB_ACT_END_OF_FILE: + { + (yy_did_buffer_switch_on_eof) = 0; + + if ( GUC_yywrap( ) ) + { + /* Note: because we've taken care in + * yy_get_next_buffer() to have set up + * GUC_yytext, we can now set up + * yy_c_buf_p so that if some total + * hoser (like flex itself) wants to + * call the scanner after we return the + * YY_NULL, it'll still work - another + * YY_NULL will get returned. + */ + (yy_c_buf_p) = (yytext_ptr) + YY_MORE_ADJ; + + yy_act = YY_STATE_EOF(YY_START); + goto do_action; + } + + else + { + if ( ! (yy_did_buffer_switch_on_eof) ) + YY_NEW_FILE; + } + break; + } + + case EOB_ACT_CONTINUE_SCAN: + (yy_c_buf_p) = + (yytext_ptr) + yy_amount_of_matched_text; + + yy_current_state = yy_get_previous_state( ); + + yy_cp = (yy_c_buf_p); + yy_bp = (yytext_ptr) + YY_MORE_ADJ; + goto yy_match; + + case EOB_ACT_LAST_MATCH: + (yy_c_buf_p) = + &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)]; + + yy_current_state = yy_get_previous_state( ); + + yy_cp = (yy_c_buf_p); + yy_bp = (yytext_ptr) + YY_MORE_ADJ; + goto yy_find_action; + } + break; + } + + default: + YY_FATAL_ERROR( + "fatal flex scanner internal error--no action found" ); + } /* end of action switch */ + } /* end of scanning one token */ +} /* end of GUC_yylex */ + +/* yy_get_next_buffer - try to read in a new buffer + * + * Returns a code representing an action: + * EOB_ACT_LAST_MATCH - + * EOB_ACT_CONTINUE_SCAN - continue scanning from current position + * EOB_ACT_END_OF_FILE - end of file + */ +static int yy_get_next_buffer (void) +{ + register char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf; + register char *source = (yytext_ptr); + register int number_to_move, i; + int ret_val; + + if ( (yy_c_buf_p) > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] ) + YY_FATAL_ERROR( + "fatal flex scanner internal error--end of buffer missed" ); + + if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 ) + { /* Don't try to fill the buffer, so this is an EOF. */ + if ( (yy_c_buf_p) - (yytext_ptr) - YY_MORE_ADJ == 1 ) + { + /* We matched a single character, the EOB, so + * treat this as a final EOF. + */ + return EOB_ACT_END_OF_FILE; + } + + else + { + /* We matched some text prior to the EOB, first + * process it. + */ + return EOB_ACT_LAST_MATCH; + } + } + + /* Try to read more data. */ + + /* First move last chars to start of buffer. */ + number_to_move = (int) ((yy_c_buf_p) - (yytext_ptr)) - 1; + + for ( i = 0; i < number_to_move; ++i ) + *(dest++) = *(source++); + + if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING ) + /* don't do the read, it's not guaranteed to return an EOF, + * just force an EOF + */ + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars) = 0; + + else + { + int num_to_read = + YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1; + + while ( num_to_read <= 0 ) + { /* Not enough room in the buffer - grow it. */ + + /* just a shorter name for the current buffer */ + YY_BUFFER_STATE b = YY_CURRENT_BUFFER; + + int yy_c_buf_p_offset = + (int) ((yy_c_buf_p) - b->yy_ch_buf); + + if ( b->yy_is_our_buffer ) + { + int new_size = b->yy_buf_size * 2; + + if ( new_size <= 0 ) + b->yy_buf_size += b->yy_buf_size / 8; + else + b->yy_buf_size *= 2; + + b->yy_ch_buf = (char *) + /* Include room in for 2 EOB chars. */ + GUC_yyrealloc((void *) b->yy_ch_buf,b->yy_buf_size + 2 ); + } + else + /* Can't grow it, we don't own it. */ + b->yy_ch_buf = 0; + + if ( ! b->yy_ch_buf ) + YY_FATAL_ERROR( + "fatal error - scanner input buffer overflow" ); + + (yy_c_buf_p) = &b->yy_ch_buf[yy_c_buf_p_offset]; + + num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size - + number_to_move - 1; + + } + + if ( num_to_read > YY_READ_BUF_SIZE ) + num_to_read = YY_READ_BUF_SIZE; + + /* Read in more data. */ + YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]), + (yy_n_chars), (size_t) num_to_read ); + + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); + } + + if ( (yy_n_chars) == 0 ) + { + if ( number_to_move == YY_MORE_ADJ ) + { + ret_val = EOB_ACT_END_OF_FILE; + GUC_yyrestart(GUC_yyin ); + } + + else + { + ret_val = EOB_ACT_LAST_MATCH; + YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = + YY_BUFFER_EOF_PENDING; + } + } + + else + ret_val = EOB_ACT_CONTINUE_SCAN; + + if ((yy_size_t) ((yy_n_chars) + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) { + /* Extend the array by 50%, plus the number we really need. */ + yy_size_t new_size = (yy_n_chars) + number_to_move + ((yy_n_chars) >> 1); + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) GUC_yyrealloc((void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,new_size ); + if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf ) + YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" ); + } + + (yy_n_chars) += number_to_move; + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] = YY_END_OF_BUFFER_CHAR; + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] = YY_END_OF_BUFFER_CHAR; + + (yytext_ptr) = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0]; + + return ret_val; +} + +/* yy_get_previous_state - get the state just before the EOB char was reached */ + + static yy_state_type yy_get_previous_state (void) +{ + register yy_state_type yy_current_state; + register char *yy_cp; + + yy_current_state = (yy_start); + + for ( yy_cp = (yytext_ptr) + YY_MORE_ADJ; yy_cp < (yy_c_buf_p); ++yy_cp ) + { + register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1); + if ( yy_accept[yy_current_state] ) + { + (yy_last_accepting_state) = yy_current_state; + (yy_last_accepting_cpos) = yy_cp; + } + while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) + { + yy_current_state = (int) yy_def[yy_current_state]; + if ( yy_current_state >= 41 ) + yy_c = yy_meta[(unsigned int) yy_c]; + } + yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; + } + + return yy_current_state; +} + +/* yy_try_NUL_trans - try to make a transition on the NUL character + * + * synopsis + * next_state = yy_try_NUL_trans( current_state ); + */ + static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state ) +{ + register int yy_is_jam; + register char *yy_cp = (yy_c_buf_p); + + register YY_CHAR yy_c = 1; + if ( yy_accept[yy_current_state] ) + { + (yy_last_accepting_state) = yy_current_state; + (yy_last_accepting_cpos) = yy_cp; + } + while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) + { + yy_current_state = (int) yy_def[yy_current_state]; + if ( yy_current_state >= 41 ) + yy_c = yy_meta[(unsigned int) yy_c]; + } + yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; + yy_is_jam = (yy_current_state == 40); + + return yy_is_jam ? 0 : yy_current_state; +} + +#ifndef YY_NO_INPUT +#ifdef __cplusplus + static int yyinput (void) +#else + static int input (void) +#endif + +{ + int c; + + *(yy_c_buf_p) = (yy_hold_char); + + if ( *(yy_c_buf_p) == YY_END_OF_BUFFER_CHAR ) + { + /* yy_c_buf_p now points to the character we want to return. + * If this occurs *before* the EOB characters, then it's a + * valid NUL; if not, then we've hit the end of the buffer. + */ + if ( (yy_c_buf_p) < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] ) + /* This was really a NUL. */ + *(yy_c_buf_p) = '\0'; + + else + { /* need more input */ + int offset = (yy_c_buf_p) - (yytext_ptr); + ++(yy_c_buf_p); + + switch ( yy_get_next_buffer( ) ) + { + case EOB_ACT_LAST_MATCH: + /* This happens because yy_g_n_b() + * sees that we've accumulated a + * token and flags that we need to + * try matching the token before + * proceeding. But for input(), + * there's no matching to consider. + * So convert the EOB_ACT_LAST_MATCH + * to EOB_ACT_END_OF_FILE. + */ + + /* Reset buffer status. */ + GUC_yyrestart(GUC_yyin ); + + /*FALLTHROUGH*/ + + case EOB_ACT_END_OF_FILE: + { + if ( GUC_yywrap( ) ) + return EOF; + + if ( ! (yy_did_buffer_switch_on_eof) ) + YY_NEW_FILE; +#ifdef __cplusplus + return yyinput(); +#else + return input(); +#endif + } + + case EOB_ACT_CONTINUE_SCAN: + (yy_c_buf_p) = (yytext_ptr) + offset; + break; + } + } + } + + c = *(unsigned char *) (yy_c_buf_p); /* cast for 8-bit char's */ + *(yy_c_buf_p) = '\0'; /* preserve GUC_yytext */ + (yy_hold_char) = *++(yy_c_buf_p); + + return c; +} +#endif /* ifndef YY_NO_INPUT */ + +/** Immediately switch to a different input stream. + * @param input_file A readable stream. + * + * @note This function does not reset the start condition to @c INITIAL . + */ + void GUC_yyrestart (FILE * input_file ) +{ + + if ( ! YY_CURRENT_BUFFER ){ + GUC_yyensure_buffer_stack (); + YY_CURRENT_BUFFER_LVALUE = + GUC_yy_create_buffer(GUC_yyin,YY_BUF_SIZE ); + } + + GUC_yy_init_buffer(YY_CURRENT_BUFFER,input_file ); + GUC_yy_load_buffer_state( ); +} + +/** Switch to a different input buffer. + * @param new_buffer The new input buffer. + * + */ + void GUC_yy_switch_to_buffer (YY_BUFFER_STATE new_buffer ) +{ + + /* TODO. We should be able to replace this entire function body + * with + * GUC_yypop_buffer_state(); + * GUC_yypush_buffer_state(new_buffer); + */ + GUC_yyensure_buffer_stack (); + if ( YY_CURRENT_BUFFER == new_buffer ) + return; + + if ( YY_CURRENT_BUFFER ) + { + /* Flush out information for old buffer. */ + *(yy_c_buf_p) = (yy_hold_char); + YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p); + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); + } + + YY_CURRENT_BUFFER_LVALUE = new_buffer; + GUC_yy_load_buffer_state( ); + + /* We don't actually know whether we did this switch during + * EOF (GUC_yywrap()) processing, but the only time this flag + * is looked at is after GUC_yywrap() is called, so it's safe + * to go ahead and always set it. + */ + (yy_did_buffer_switch_on_eof) = 1; +} + +static void GUC_yy_load_buffer_state (void) +{ + (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars; + (yytext_ptr) = (yy_c_buf_p) = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos; + GUC_yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file; + (yy_hold_char) = *(yy_c_buf_p); +} + +/** Allocate and initialize an input buffer state. + * @param file A readable stream. + * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE. + * + * @return the allocated buffer state. + */ + YY_BUFFER_STATE GUC_yy_create_buffer (FILE * file, int size ) +{ + YY_BUFFER_STATE b; + + b = (YY_BUFFER_STATE) GUC_yyalloc(sizeof( struct yy_buffer_state ) ); + if ( ! b ) + YY_FATAL_ERROR( "out of dynamic memory in GUC_yy_create_buffer()" ); + + b->yy_buf_size = size; + + /* yy_ch_buf has to be 2 characters longer than the size given because + * we need to put in 2 end-of-buffer characters. + */ + b->yy_ch_buf = (char *) GUC_yyalloc(b->yy_buf_size + 2 ); + if ( ! b->yy_ch_buf ) + YY_FATAL_ERROR( "out of dynamic memory in GUC_yy_create_buffer()" ); + + b->yy_is_our_buffer = 1; + + GUC_yy_init_buffer(b,file ); + + return b; +} + +/** Destroy the buffer. + * @param b a buffer created with GUC_yy_create_buffer() + * + */ + void GUC_yy_delete_buffer (YY_BUFFER_STATE b ) +{ + + if ( ! b ) + return; + + if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */ + YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0; + + if ( b->yy_is_our_buffer ) + GUC_yyfree((void *) b->yy_ch_buf ); + + GUC_yyfree((void *) b ); +} + +/* Initializes or reinitializes a buffer. + * This function is sometimes called more than once on the same buffer, + * such as during a GUC_yyrestart() or at EOF. + */ + static void GUC_yy_init_buffer (YY_BUFFER_STATE b, FILE * file ) + +{ + int oerrno = errno; + + GUC_yy_flush_buffer(b ); + + b->yy_input_file = file; + b->yy_fill_buffer = 1; + + /* If b is the current buffer, then GUC_yy_init_buffer was _probably_ + * called from GUC_yyrestart() or through yy_get_next_buffer. + * In that case, we don't want to reset the lineno or column. + */ + if (b != YY_CURRENT_BUFFER){ + b->yy_bs_lineno = 1; + b->yy_bs_column = 0; + } + + b->yy_is_interactive = 0; + + errno = oerrno; +} + +/** Discard all buffered characters. On the next scan, YY_INPUT will be called. + * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER. + * + */ + void GUC_yy_flush_buffer (YY_BUFFER_STATE b ) +{ + if ( ! b ) + return; + + b->yy_n_chars = 0; + + /* We always need two end-of-buffer characters. The first causes + * a transition to the end-of-buffer state. The second causes + * a jam in that state. + */ + b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR; + b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR; + + b->yy_buf_pos = &b->yy_ch_buf[0]; + + b->yy_at_bol = 1; + b->yy_buffer_status = YY_BUFFER_NEW; + + if ( b == YY_CURRENT_BUFFER ) + GUC_yy_load_buffer_state( ); +} + +/** Pushes the new state onto the stack. The new state becomes + * the current state. This function will allocate the stack + * if necessary. + * @param new_buffer The new state. + * + */ +void GUC_yypush_buffer_state (YY_BUFFER_STATE new_buffer ) +{ + if (new_buffer == NULL) + return; + + GUC_yyensure_buffer_stack(); + + /* This block is copied from GUC_yy_switch_to_buffer. */ + if ( YY_CURRENT_BUFFER ) + { + /* Flush out information for old buffer. */ + *(yy_c_buf_p) = (yy_hold_char); + YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p); + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); + } + + /* Only push if top exists. Otherwise, replace top. */ + if (YY_CURRENT_BUFFER) + (yy_buffer_stack_top)++; + YY_CURRENT_BUFFER_LVALUE = new_buffer; + + /* copied from GUC_yy_switch_to_buffer. */ + GUC_yy_load_buffer_state( ); + (yy_did_buffer_switch_on_eof) = 1; +} + +/** Removes and deletes the top of the stack, if present. + * The next element becomes the new top. + * + */ +void GUC_yypop_buffer_state (void) +{ + if (!YY_CURRENT_BUFFER) + return; + + GUC_yy_delete_buffer(YY_CURRENT_BUFFER ); + YY_CURRENT_BUFFER_LVALUE = NULL; + if ((yy_buffer_stack_top) > 0) + --(yy_buffer_stack_top); + + if (YY_CURRENT_BUFFER) { + GUC_yy_load_buffer_state( ); + (yy_did_buffer_switch_on_eof) = 1; + } +} + +/* Allocates the stack if it does not exist. + * Guarantees space for at least one push. + */ +static void GUC_yyensure_buffer_stack (void) +{ + int num_to_alloc; + + if (!(yy_buffer_stack)) { + + /* First allocation is just for 2 elements, since we don't know if this + * scanner will even need a stack. We use 2 instead of 1 to avoid an + * immediate realloc on the next call. + */ + num_to_alloc = 1; + (yy_buffer_stack) = (struct yy_buffer_state**)GUC_yyalloc + (num_to_alloc * sizeof(struct yy_buffer_state*) + ); + if ( ! (yy_buffer_stack) ) + YY_FATAL_ERROR( "out of dynamic memory in GUC_yyensure_buffer_stack()" ); + + memset((yy_buffer_stack), 0, num_to_alloc * sizeof(struct yy_buffer_state*)); + + (yy_buffer_stack_max) = num_to_alloc; + (yy_buffer_stack_top) = 0; + return; + } + + if ((yy_buffer_stack_top) >= ((yy_buffer_stack_max)) - 1){ + + /* Increase the buffer to prepare for a possible push. */ + int grow_size = 8 /* arbitrary grow size */; + + num_to_alloc = (yy_buffer_stack_max) + grow_size; + (yy_buffer_stack) = (struct yy_buffer_state**)GUC_yyrealloc + ((yy_buffer_stack), + num_to_alloc * sizeof(struct yy_buffer_state*) + ); + if ( ! (yy_buffer_stack) ) + YY_FATAL_ERROR( "out of dynamic memory in GUC_yyensure_buffer_stack()" ); + + /* zero only the new slots.*/ + memset((yy_buffer_stack) + (yy_buffer_stack_max), 0, grow_size * sizeof(struct yy_buffer_state*)); + (yy_buffer_stack_max) = num_to_alloc; + } +} + +/** Setup the input buffer state to scan directly from a user-specified character buffer. + * @param base the character buffer + * @param size the size in bytes of the character buffer + * + * @return the newly allocated buffer state object. + */ +YY_BUFFER_STATE GUC_yy_scan_buffer (char * base, yy_size_t size ) +{ + YY_BUFFER_STATE b; + + if ( size < 2 || + base[size-2] != YY_END_OF_BUFFER_CHAR || + base[size-1] != YY_END_OF_BUFFER_CHAR ) + /* They forgot to leave room for the EOB's. */ + return 0; + + b = (YY_BUFFER_STATE) GUC_yyalloc(sizeof( struct yy_buffer_state ) ); + if ( ! b ) + YY_FATAL_ERROR( "out of dynamic memory in GUC_yy_scan_buffer()" ); + + b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */ + b->yy_buf_pos = b->yy_ch_buf = base; + b->yy_is_our_buffer = 0; + b->yy_input_file = 0; + b->yy_n_chars = b->yy_buf_size; + b->yy_is_interactive = 0; + b->yy_at_bol = 1; + b->yy_fill_buffer = 0; + b->yy_buffer_status = YY_BUFFER_NEW; + + GUC_yy_switch_to_buffer(b ); + + return b; +} + +/** Setup the input buffer state to scan a string. The next call to GUC_yylex() will + * scan from a @e copy of @a str. + * @param yystr a NUL-terminated string to scan + * + * @return the newly allocated buffer state object. + * @note If you want to scan bytes that may contain NUL values, then use + * GUC_yy_scan_bytes() instead. + */ +YY_BUFFER_STATE GUC_yy_scan_string (yyconst char * yystr ) +{ + + return GUC_yy_scan_bytes(yystr,strlen(yystr) ); +} + +/** Setup the input buffer state to scan the given bytes. The next call to GUC_yylex() will + * scan from a @e copy of @a bytes. + * @param yybytes the byte buffer to scan + * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes. + * + * @return the newly allocated buffer state object. + */ +YY_BUFFER_STATE GUC_yy_scan_bytes (yyconst char * yybytes, int _yybytes_len ) +{ + YY_BUFFER_STATE b; + char *buf; + yy_size_t n; + int i; + + /* Get memory for full buffer, including space for trailing EOB's. */ + n = _yybytes_len + 2; + buf = (char *) GUC_yyalloc(n ); + if ( ! buf ) + YY_FATAL_ERROR( "out of dynamic memory in GUC_yy_scan_bytes()" ); + + for ( i = 0; i < _yybytes_len; ++i ) + buf[i] = yybytes[i]; + + buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR; + + b = GUC_yy_scan_buffer(buf,n ); + if ( ! b ) + YY_FATAL_ERROR( "bad buffer in GUC_yy_scan_bytes()" ); + + /* It's okay to grow etc. this buffer, and we should throw it + * away when we're done. + */ + b->yy_is_our_buffer = 1; + + return b; +} + +#ifndef YY_EXIT_FAILURE +#define YY_EXIT_FAILURE 2 +#endif + +static void yy_fatal_error (yyconst char* msg ) +{ + (void) fprintf( stderr, "%s\n", msg ); + exit( YY_EXIT_FAILURE ); +} + +/* Redefine yyless() so it works in section 3 code. */ + +#undef yyless +#define yyless(n) \ + do \ + { \ + /* Undo effects of setting up GUC_yytext. */ \ + int yyless_macro_arg = (n); \ + YY_LESS_LINENO(yyless_macro_arg);\ + GUC_yytext[GUC_yyleng] = (yy_hold_char); \ + (yy_c_buf_p) = GUC_yytext + yyless_macro_arg; \ + (yy_hold_char) = *(yy_c_buf_p); \ + *(yy_c_buf_p) = '\0'; \ + GUC_yyleng = yyless_macro_arg; \ + } \ + while ( 0 ) + +/* Accessor methods (get/set functions) to struct members. */ + +/** Get the current line number. + * + */ +int GUC_yyget_lineno (void) +{ + + return GUC_yylineno; +} + +/** Get the input stream. + * + */ +FILE *GUC_yyget_in (void) +{ + return GUC_yyin; +} + +/** Get the output stream. + * + */ +FILE *GUC_yyget_out (void) +{ + return GUC_yyout; +} + +/** Get the length of the current token. + * + */ +int GUC_yyget_leng (void) +{ + return GUC_yyleng; +} + +/** Get the current token. + * + */ + +char *GUC_yyget_text (void) +{ + return GUC_yytext; +} + +/** Set the current line number. + * @param line_number + * + */ +void GUC_yyset_lineno (int line_number ) +{ + + GUC_yylineno = line_number; +} + +/** Set the input stream. This does not discard the current + * input buffer. + * @param in_str A readable stream. + * + * @see GUC_yy_switch_to_buffer + */ +void GUC_yyset_in (FILE * in_str ) +{ + GUC_yyin = in_str ; +} + +void GUC_yyset_out (FILE * out_str ) +{ + GUC_yyout = out_str ; +} + +int GUC_yyget_debug (void) +{ + return GUC_yy_flex_debug; +} + +void GUC_yyset_debug (int bdebug ) +{ + GUC_yy_flex_debug = bdebug ; +} + +static int yy_init_globals (void) +{ + /* Initialization is the same as for the non-reentrant scanner. + * This function is called from GUC_yylex_destroy(), so don't allocate here. + */ + + (yy_buffer_stack) = 0; + (yy_buffer_stack_top) = 0; + (yy_buffer_stack_max) = 0; + (yy_c_buf_p) = (char *) 0; + (yy_init) = 0; + (yy_start) = 0; + +/* Defined in main.c */ +#ifdef YY_STDINIT + GUC_yyin = stdin; + GUC_yyout = stdout; +#else + GUC_yyin = (FILE *) 0; + GUC_yyout = (FILE *) 0; +#endif + + /* For future reference: Set errno on error, since we are called by + * GUC_yylex_init() + */ + return 0; +} + +/* GUC_yylex_destroy is for both reentrant and non-reentrant scanners. */ +int GUC_yylex_destroy (void) +{ + + /* Pop the buffer stack, destroying each element. */ + while(YY_CURRENT_BUFFER){ + GUC_yy_delete_buffer(YY_CURRENT_BUFFER ); + YY_CURRENT_BUFFER_LVALUE = NULL; + GUC_yypop_buffer_state(); + } + + /* Destroy the stack itself. */ + GUC_yyfree((yy_buffer_stack) ); + (yy_buffer_stack) = NULL; + + /* Reset the globals. This is important in a non-reentrant scanner so the next time + * GUC_yylex() is called, initialization will occur. */ + yy_init_globals( ); + + return 0; +} + +/* + * Internal utility routines. + */ + +#ifndef yytext_ptr +static void yy_flex_strncpy (char* s1, yyconst char * s2, int n ) +{ + register int i; + for ( i = 0; i < n; ++i ) + s1[i] = s2[i]; +} +#endif + +#ifdef YY_NEED_STRLEN +static int yy_flex_strlen (yyconst char * s ) +{ + register int n; + for ( n = 0; s[n]; ++n ) + ; + + return n; +} +#endif + +void *GUC_yyalloc (yy_size_t size ) +{ + return (void *) malloc( size ); +} + +void *GUC_yyrealloc (void * ptr, yy_size_t size ) +{ + /* The cast to (char *) in the following accommodates both + * implementations that use char* generic pointers, and those + * that use void* generic pointers. It works with the latter + * because both ANSI C and C++ allow castless assignment from + * any pointer type to void*, and deal with argument conversions + * as though doing an assignment. + */ + return (void *) realloc( (char *) ptr, size ); +} + +void GUC_yyfree (void * ptr ) +{ + free( (char *) ptr ); /* see GUC_yyrealloc() for (char *) cast */ +} + +#define YYTABLES_NAME "yytables" + +#line 102 "guc-file.l" + + + + + +/* + * Exported function to read and process the configuration file. The + * parameter indicates in what context the file is being read --- either + * postmaster startup (including standalone-backend startup) or SIGHUP. + * All options mentioned in the configuration file are set to new values. + * If an error occurs, no values will be changed. + */ +void +ProcessConfigFile(GucContext context) +{ + bool error = false; + bool apply = false; + int elevel; + ConfigVariable *item, + *head, + *tail; + int i; + + /* + * Config files are processed on startup (by the postmaster only) + * and on SIGHUP (by the postmaster and its children) + */ + Assert((context == PGC_POSTMASTER && !IsUnderPostmaster) || + context == PGC_SIGHUP); + + /* + * To avoid cluttering the log, only the postmaster bleats loudly + * about problems with the config file. + */ + elevel = IsUnderPostmaster ? DEBUG2 : LOG; + + /* Parse the file into a list of option names and values */ + head = tail = NULL; + + if (!ParseConfigFile(ConfigFileName, NULL, true, 0, elevel, &head, &tail)) + { + /* Syntax error(s) detected in the file, so bail out */ + error = true; + goto cleanup_list; + } + + /* + * Mark all extant GUC variables as not present in the config file. + * We need this so that we can tell below which ones have been removed + * from the file since we last processed it. + */ + for (i = 0; i < num_guc_variables; i++) + { + struct config_generic *gconf = guc_variables[i]; + + gconf->status &= ~GUC_IS_IN_FILE; + } + + /* + * Check if all the supplied option names are valid, as an additional + * quasi-syntactic check on the validity of the config file. It is + * important that the postmaster and all backends agree on the results + * of this phase, else we will have strange inconsistencies about which + * processes accept a config file update and which don't. Hence, unknown + * custom variable names have to be accepted without complaint. For the + * same reason, we don't attempt to validate the options' values here. + * + * In addition, the GUC_IS_IN_FILE flag is set on each existing GUC + * variable mentioned in the file. + */ + for (item = head; item; item = item->next) + { + struct config_generic *record; + + /* + * Try to find the variable; but do not create a custom placeholder + * if it's not there already. + */ + record = find_option(item->name, false, elevel); + + if (record) + { + /* Found, so mark it as present in file */ + record->status |= GUC_IS_IN_FILE; + } + else if (strchr(item->name, GUC_QUALIFIER_SEPARATOR) == NULL) + { + /* Invalid non-custom variable, so complain */ + ereport(elevel, + (errcode(ERRCODE_UNDEFINED_OBJECT), + errmsg("unrecognized configuration parameter \"%s\" in file \"%s\" line %u", + item->name, + item->filename, item->sourceline))); + error = true; + } + } + + /* + * If we've detected any errors so far, we don't want to risk applying + * any changes. + */ + if (error) + goto cleanup_list; + + /* Otherwise, set flag that we're beginning to apply changes */ + apply = true; + + /* + * Check for variables having been removed from the config file, and + * revert their reset values (and perhaps also effective values) to the + * boot-time defaults. If such a variable can't be changed after startup, + * report that and continue. + */ + for (i = 0; i < num_guc_variables; i++) + { + struct config_generic *gconf = guc_variables[i]; + GucStack *stack; + + if (gconf->reset_source != PGC_S_FILE || + (gconf->status & GUC_IS_IN_FILE)) + continue; + if (gconf->context < PGC_SIGHUP) + { + ereport(elevel, + (errcode(ERRCODE_CANT_CHANGE_RUNTIME_PARAM), + errmsg("parameter \"%s\" cannot be changed without restarting the server", + gconf->name))); + error = true; + continue; + } + + /* + * Reset any "file" sources to "default", else set_config_option + * will not override those settings. + */ + if (gconf->reset_source == PGC_S_FILE) + gconf->reset_source = PGC_S_DEFAULT; + if (gconf->source == PGC_S_FILE) + gconf->source = PGC_S_DEFAULT; + for (stack = gconf->stack; stack; stack = stack->prev) + { + if (stack->source == PGC_S_FILE) + stack->source = PGC_S_DEFAULT; + } + + /* Now we can re-apply the wired-in default (i.e., the boot_val) */ + if (set_config_option(gconf->name, NULL, + context, PGC_S_DEFAULT, + GUC_ACTION_SET, true, 0) > 0) + { + /* Log the change if appropriate */ + if (context == PGC_SIGHUP) + ereport(elevel, + (errmsg("parameter \"%s\" removed from configuration file, reset to default", + gconf->name))); + } + } + + /* + * Restore any variables determined by environment variables or + * dynamically-computed defaults. This is a no-op except in the case + * where one of these had been in the config file and is now removed. + * + * In particular, we *must not* do this during the postmaster's + * initial loading of the file, since the timezone functions in + * particular should be run only after initialization is complete. + * + * XXX this is an unmaintainable crock, because we have to know how + * to set (or at least what to call to set) every variable that could + * potentially have PGC_S_DYNAMIC_DEFAULT or PGC_S_ENV_VAR source. + * However, there's no time to redesign it for 9.1. + */ + if (context == PGC_SIGHUP) + { + InitializeGUCOptionsFromEnvironment(); + pg_timezone_abbrev_initialize(); + /* this selects SQL_ASCII in processes not connected to a database */ + SetConfigOption("client_encoding", GetDatabaseEncodingName(), + PGC_BACKEND, PGC_S_DYNAMIC_DEFAULT); + } + + /* + * Now apply the values from the config file. + */ + for (item = head; item; item = item->next) + { + char *pre_value = NULL; + int scres; + + /* In SIGHUP cases in the postmaster, we want to report changes */ + if (context == PGC_SIGHUP && !IsUnderPostmaster) + { + const char *preval = GetConfigOption(item->name, true, false); + + /* If option doesn't exist yet or is NULL, treat as empty string */ + if (!preval) + preval = ""; + /* must dup, else might have dangling pointer below */ + pre_value = pstrdup(preval); + } + + scres = set_config_option(item->name, item->value, + context, PGC_S_FILE, + GUC_ACTION_SET, true, 0); + if (scres > 0) + { + /* variable was updated, so log the change if appropriate */ + if (pre_value) + { + const char *post_value = GetConfigOption(item->name, true, false); + + if (!post_value) + post_value = ""; + if (strcmp(pre_value, post_value) != 0) + ereport(elevel, + (errmsg("parameter \"%s\" changed to \"%s\"", + item->name, item->value))); + } + } + else if (scres == 0) + error = true; + /* else no error but variable's active value was not changed */ + + /* + * We should update source location unless there was an error, since + * even if the active value didn't change, the reset value might have. + * (In the postmaster, there won't be a difference, but it does matter + * in backends.) + */ + if (scres != 0) + set_config_sourcefile(item->name, item->filename, + item->sourceline); + + if (pre_value) + pfree(pre_value); + } + + /* Remember when we last successfully loaded the config file. */ + PgReloadTime = GetCurrentTimestamp(); + + cleanup_list: + FreeConfigVariables(head); + + if (error) + { + /* During postmaster startup, any error is fatal */ + if (context == PGC_POSTMASTER) + ereport(ERROR, + (errcode(ERRCODE_CONFIG_FILE_ERROR), + errmsg("configuration file \"%s\" contains errors", + ConfigFileName))); + else if (apply) + ereport(elevel, + (errcode(ERRCODE_CONFIG_FILE_ERROR), + errmsg("configuration file \"%s\" contains errors; unaffected changes were applied", + ConfigFileName))); + else + ereport(elevel, + (errcode(ERRCODE_CONFIG_FILE_ERROR), + errmsg("configuration file \"%s\" contains errors; no changes were applied", + ConfigFileName))); + } +} + +/* + * Read and parse a single configuration file. This function recurses + * to handle "include" directives. + * + * See ParseConfigFp for details. This one merely adds opening the + * file rather than working from a caller-supplied file descriptor, + * and absolute-ifying the path name if necessary. + */ +bool +ParseConfigFile(const char *config_file, const char *calling_file, bool strict, + int depth, int elevel, + ConfigVariable **head_p, + ConfigVariable **tail_p) +{ + bool OK = true; + FILE *fp; + char abs_path[MAXPGPATH]; + + /* + * Reject too-deep include nesting depth. This is just a safety check + * to avoid dumping core due to stack overflow if an include file loops + * back to itself. The maximum nesting depth is pretty arbitrary. + */ + if (depth > 10) + { + ereport(elevel, + (errcode(ERRCODE_PROGRAM_LIMIT_EXCEEDED), + errmsg("could not open configuration file \"%s\": maximum nesting depth exceeded", + config_file))); + return false; + } + + /* + * If config_file is a relative path, convert to absolute. We consider + * it to be relative to the directory holding the calling file. + */ + if (!is_absolute_path(config_file)) + { + if (calling_file != NULL) + { + strlcpy(abs_path, calling_file, sizeof(abs_path)); + get_parent_directory(abs_path); + join_path_components(abs_path, abs_path, config_file); + canonicalize_path(abs_path); + config_file = abs_path; + } + else + { + /* + * calling_file is NULL, we make an absolute path from $PGDATA + */ + join_path_components(abs_path, data_directory, config_file); + canonicalize_path(abs_path); + config_file = abs_path; + } + } + + fp = AllocateFile(config_file, "r"); + if (!fp) + { + if (strict) + { + ereport(elevel, + (errcode_for_file_access(), + errmsg("could not open configuration file \"%s\": %m", + config_file))); + return false; + } + + ereport(LOG, + (errmsg("skipping missing configuration file \"%s\"", + config_file))); + return OK; + } + + OK = ParseConfigFp(fp, config_file, depth, elevel, head_p, tail_p); + + FreeFile(fp); + + return OK; +} + +/* + * Flex fatal errors bring us here. Stash the error message and jump back to + * ParseConfigFp(). Assume all msg arguments point to string constants; this + * holds for flex 2.5.31 (earliest we support) and flex 2.5.35 (latest as of + * this writing). Otherwise, we would need to copy the message. + * + * We return "int" since this takes the place of calls to fprintf(). +*/ +static int +GUC_flex_fatal(const char *msg) +{ + GUC_flex_fatal_errmsg = msg; + siglongjmp(*GUC_flex_fatal_jmp, 1); + return 0; /* keep compiler quiet */ +} + +/* + * Read and parse a single configuration file. This function recurses + * to handle "include" directives. + * + * Input parameters: + * fp: file pointer from AllocateFile for the configuration file to parse + * config_file: absolute or relative path name of the configuration file + * depth: recursion depth (should be 0 in the outermost call) + * elevel: error logging level to use + * Output parameters: + * head_p, tail_p: head and tail of linked list of name/value pairs + * + * *head_p and *tail_p must be initialized to NULL before calling the outer + * recursion level. On exit, they contain a list of name-value pairs read + * from the input file(s). + * + * Returns TRUE if successful, FALSE if an error occurred. The error has + * already been ereport'd, it is only necessary for the caller to clean up + * its own state and release the ConfigVariable list. + * + * Note: if elevel >= ERROR then an error will not return control to the + * caller, so there is no need to check the return value in that case. + */ +bool +ParseConfigFp(FILE *fp, const char *config_file, int depth, int elevel, + ConfigVariable **head_p, ConfigVariable **tail_p) +{ + volatile bool OK = true; + unsigned int save_ConfigFileLineno = ConfigFileLineno; + sigjmp_buf *save_GUC_flex_fatal_jmp = GUC_flex_fatal_jmp; + sigjmp_buf flex_fatal_jmp; + volatile YY_BUFFER_STATE lex_buffer = NULL; + int errorcount; + int token; + + if (sigsetjmp(flex_fatal_jmp, 1) == 0) + GUC_flex_fatal_jmp = &flex_fatal_jmp; + else + { + /* + * Regain control after a fatal, internal flex error. It may have + * corrupted parser state. Consequently, abandon the file, but trust + * that the state remains sane enough for GUC_yy_delete_buffer(). + */ + elog(elevel, "%s at file \"%s\" line %u", + GUC_flex_fatal_errmsg, config_file, ConfigFileLineno); + + OK = false; + goto cleanup; + } + + /* + * Parse + */ + ConfigFileLineno = 1; + errorcount = 0; + + lex_buffer = GUC_yy_create_buffer(fp,YY_BUF_SIZE); + GUC_yy_switch_to_buffer(lex_buffer); + + /* This loop iterates once per logical line */ + while ((token = GUC_yylex())) + { + char *opt_name = NULL; + char *opt_value = NULL; + ConfigVariable *item; + + if (token == GUC_EOL) /* empty or comment line */ + continue; + + /* first token on line is option name */ + if (token != GUC_ID && token != GUC_QUALIFIED_ID) + goto parse_error; + opt_name = pstrdup(GUC_yytext); + + /* next we have an optional equal sign; discard if present */ + token = GUC_yylex(); + if (token == GUC_EQUALS) + token = GUC_yylex(); + + /* now we must have the option value */ + if (token != GUC_ID && + token != GUC_STRING && + token != GUC_INTEGER && + token != GUC_REAL && + token != GUC_UNQUOTED_STRING) + goto parse_error; + if (token == GUC_STRING) /* strip quotes and escapes */ + opt_value = GUC_scanstr(GUC_yytext); + else + opt_value = pstrdup(GUC_yytext); + + /* now we'd like an end of line, or possibly EOF */ + token = GUC_yylex(); + if (token != GUC_EOL) + { + if (token != 0) + goto parse_error; + /* treat EOF like \n for line numbering purposes, cf bug 4752 */ + ConfigFileLineno++; + } + + /* OK, process the option name and value */ + if (guc_name_compare(opt_name, "include_if_exists") == 0) + { + /* + * An include_if_exists directive isn't a variable and should be + * processed immediately. + */ + if (!ParseConfigFile(opt_value, config_file, false, + depth + 1, elevel, + head_p, tail_p)) + OK = false; + GUC_yy_switch_to_buffer(lex_buffer); + pfree(opt_name); + pfree(opt_value); + } + else if (guc_name_compare(opt_name, "include") == 0) + { + /* + * An include directive isn't a variable and should be processed + * immediately. + */ + if (!ParseConfigFile(opt_value, config_file, true, + depth + 1, elevel, + head_p, tail_p)) + OK = false; + GUC_yy_switch_to_buffer(lex_buffer); + pfree(opt_name); + pfree(opt_value); + } + else + { + /* ordinary variable, append to list */ + item = palloc(sizeof *item); + item->name = opt_name; + item->value = opt_value; + item->filename = pstrdup(config_file); + item->sourceline = ConfigFileLineno-1; + item->next = NULL; + if (*head_p == NULL) + *head_p = item; + else + (*tail_p)->next = item; + *tail_p = item; + } + + /* break out of loop if read EOF, else loop for next line */ + if (token == 0) + break; + continue; + + parse_error: + /* release storage if we allocated any on this line */ + if (opt_name) + pfree(opt_name); + if (opt_value) + pfree(opt_value); + + /* report the error */ + if (token == GUC_EOL || token == 0) + ereport(elevel, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("syntax error in file \"%s\" line %u, near end of line", + config_file, ConfigFileLineno - 1))); + else + ereport(elevel, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("syntax error in file \"%s\" line %u, near token \"%s\"", + config_file, ConfigFileLineno, GUC_yytext))); + OK = false; + errorcount++; + + /* + * To avoid producing too much noise when fed a totally bogus file, + * give up after 100 syntax errors per file (an arbitrary number). + * Also, if we're only logging the errors at DEBUG level anyway, + * might as well give up immediately. (This prevents postmaster + * children from bloating the logs with duplicate complaints.) + */ + if (errorcount >= 100 || elevel <= DEBUG1) + { + ereport(elevel, + (errcode(ERRCODE_PROGRAM_LIMIT_EXCEEDED), + errmsg("too many syntax errors found, abandoning file \"%s\"", + config_file))); + break; + } + + /* resync to next end-of-line or EOF */ + while (token != GUC_EOL && token != 0) + token = GUC_yylex(); + /* break out of loop on EOF */ + if (token == 0) + break; + } + +cleanup: + GUC_yy_delete_buffer(lex_buffer); + /* Each recursion level must save and restore these static variables. */ + ConfigFileLineno = save_ConfigFileLineno; + GUC_flex_fatal_jmp = save_GUC_flex_fatal_jmp; + return OK; +} + + +/* + * Free a list of ConfigVariables, including the names and the values + */ +void +FreeConfigVariables(ConfigVariable *list) +{ + ConfigVariable *item; + + item = list; + while (item) + { + ConfigVariable *next = item->next; + + pfree(item->name); + pfree(item->value); + pfree(item->filename); + pfree(item); + item = next; + } +} + + +/* + * scanstr + * + * Strip the quotes surrounding the given string, and collapse any embedded + * '' sequences and backslash escapes. + * + * the string returned is palloc'd and should eventually be pfree'd by the + * caller. + */ +static char * +GUC_scanstr(const char *s) +{ + char *newStr; + int len, + i, + j; + + Assert(s != NULL && s[0] == '\''); + len = strlen(s); + Assert(len >= 2); + Assert(s[len-1] == '\''); + + /* Skip the leading quote; we'll handle the trailing quote below */ + s++, len--; + + /* Since len still includes trailing quote, this is enough space */ + newStr = palloc(len); + + for (i = 0, j = 0; i < len; i++) + { + if (s[i] == '\\') + { + i++; + switch (s[i]) + { + case 'b': + newStr[j] = '\b'; + break; + case 'f': + newStr[j] = '\f'; + break; + case 'n': + newStr[j] = '\n'; + break; + case 'r': + newStr[j] = '\r'; + break; + case 't': + newStr[j] = '\t'; + break; + case '0': + case '1': + case '2': + case '3': + case '4': + case '5': + case '6': + case '7': + { + int k; + long octVal = 0; + + for (k = 0; + s[i + k] >= '0' && s[i + k] <= '7' && k < 3; + k++) + octVal = (octVal << 3) + (s[i + k] - '0'); + i += k - 1; + newStr[j] = ((char) octVal); + } + break; + default: + newStr[j] = s[i]; + break; + } /* switch */ + } + else if (s[i] == '\'' && s[i+1] == '\'') + { + /* doubled quote becomes just one quote */ + newStr[j] = s[++i]; + } + else + newStr[j] = s[i]; + j++; + } + + /* We copied the ending quote to newStr, so replace with \0 */ + Assert(j > 0 && j <= len); + newStr[--j] = '\0'; + + return newStr; +} + diff --git a/src/backend/utils/sort/.gitignore b/src/backend/utils/sort/.gitignore deleted file mode 100644 index f2958633e..000000000 --- a/src/backend/utils/sort/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/qsort_tuple.c diff --git a/src/backend/utils/sort/qsort_tuple.c b/src/backend/utils/sort/qsort_tuple.c new file mode 100644 index 000000000..cea0206f0 --- /dev/null +++ b/src/backend/utils/sort/qsort_tuple.c @@ -0,0 +1,280 @@ +/* + * autogenerated by src/backend/utils/sort/gen_qsort_tuple.pl, do not edit + * This file is included by tuplesort.c, rather than compiled separately. + */ + +/* $NetBSD: qsort.c,v 1.13 2003/08/07 16:43:42 agc Exp $ */ + +/*- + * Copyright (c) 1992, 1993 + * The Regents of the University of California. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +/* + * Qsort routine based on J. L. Bentley and M. D. McIlroy, + * "Engineering a sort function", + * Software--Practice and Experience 23 (1993) 1249-1265. + * We have modified their original by adding a check for already-sorted input, + * which seems to be a win per discussions on pgsql-hackers around 2006-03-21. + */ + +static void +swapfunc(SortTuple *a, SortTuple *b, size_t n) +{ + do + { + SortTuple t = *a; + *a++ = *b; + *b++ = t; + } while (--n > 0); +} + +#define swap(a, b) \ + do { \ + SortTuple t = *(a); \ + *(a) = *(b); \ + *(b) = t; \ + } while (0); + +#define vecswap(a, b, n) if ((n) > 0) swapfunc((a), (b), (size_t)(n)) +static SortTuple * +med3_tuple(SortTuple *a, SortTuple *b, SortTuple *c, SortTupleComparator cmp_tuple, Tuplesortstate *state) +{ + return cmp_tuple(a, b, state) < 0 ? + (cmp_tuple(b, c, state) < 0 ? b : + (cmp_tuple(a, c, state) < 0 ? c : a)) + : (cmp_tuple(b, c, state) > 0 ? b : + (cmp_tuple(a, c, state) < 0 ? a : c)); +} + +static void +qsort_tuple(SortTuple *a, size_t n, SortTupleComparator cmp_tuple, Tuplesortstate *state) +{ + SortTuple *pa, + *pb, + *pc, + *pd, + *pl, + *pm, + *pn; + int d, + r, + presorted; + +loop: + CHECK_FOR_INTERRUPTS(); + if (n < 7) + { + for (pm = a + 1; pm < a + n; pm++) + for (pl = pm; pl > a && cmp_tuple(pl - 1, pl, state) > 0; pl--) + swap(pl, pl - 1); + return; + } + presorted = 1; + for (pm = a + 1; pm < a + n; pm++) + { + CHECK_FOR_INTERRUPTS(); + if (cmp_tuple(pm - 1, pm, state) > 0) + { + presorted = 0; + break; + } + } + if (presorted) + return; + pm = a + (n / 2); + if (n > 7) + { + pl = a; + pn = a + (n - 1); + if (n > 40) + { + d = (n / 8); + pl = med3_tuple(pl, pl + d, pl + 2 * d, cmp_tuple, state); + pm = med3_tuple(pm - d, pm, pm + d, cmp_tuple, state); + pn = med3_tuple(pn - 2 * d, pn - d, pn, cmp_tuple, state); + } + pm = med3_tuple(pl, pm, pn, cmp_tuple, state); + } + swap(a, pm); + pa = pb = a + 1; + pc = pd = a + (n - 1); + for (;;) + { + while (pb <= pc && (r = cmp_tuple(pb, a, state)) <= 0) + { + CHECK_FOR_INTERRUPTS(); + if (r == 0) + { + swap(pa, pb); + pa++; + } + pb++; + } + while (pb <= pc && (r = cmp_tuple(pc, a, state)) >= 0) + { + CHECK_FOR_INTERRUPTS(); + if (r == 0) + { + swap(pc, pd); + pd--; + } + pc--; + } + if (pb > pc) + break; + swap(pb, pc); + pb++; + pc--; + } + pn = a + n; + r = Min(pa - a, pb - pa); + vecswap(a, pb - r, r); + r = Min(pd - pc, pn - pd - 1); + vecswap(pb, pn - r, r); + if ((r = pb - pa) > 1) + qsort_tuple(a, r, cmp_tuple, state); + if ((r = pd - pc) > 1) + { + /* Iterate rather than recurse to save stack space */ + a = pn - r; + n = r; + goto loop; + } +/* qsort_tuple(pn - r, r, cmp_tuple, state);*/ +} + +#define cmp_ssup(a, b, ssup) \ + ApplySortComparator((a)->datum1, (a)->isnull1, \ + (b)->datum1, (b)->isnull1, ssup) +static SortTuple * +med3_ssup(SortTuple *a, SortTuple *b, SortTuple *c, SortSupport ssup) +{ + return cmp_ssup(a, b, ssup) < 0 ? + (cmp_ssup(b, c, ssup) < 0 ? b : + (cmp_ssup(a, c, ssup) < 0 ? c : a)) + : (cmp_ssup(b, c, ssup) > 0 ? b : + (cmp_ssup(a, c, ssup) < 0 ? a : c)); +} + +static void +qsort_ssup(SortTuple *a, size_t n, SortSupport ssup) +{ + SortTuple *pa, + *pb, + *pc, + *pd, + *pl, + *pm, + *pn; + int d, + r, + presorted; + +loop: + CHECK_FOR_INTERRUPTS(); + if (n < 7) + { + for (pm = a + 1; pm < a + n; pm++) + for (pl = pm; pl > a && cmp_ssup(pl - 1, pl, ssup) > 0; pl--) + swap(pl, pl - 1); + return; + } + presorted = 1; + for (pm = a + 1; pm < a + n; pm++) + { + CHECK_FOR_INTERRUPTS(); + if (cmp_ssup(pm - 1, pm, ssup) > 0) + { + presorted = 0; + break; + } + } + if (presorted) + return; + pm = a + (n / 2); + if (n > 7) + { + pl = a; + pn = a + (n - 1); + if (n > 40) + { + d = (n / 8); + pl = med3_ssup(pl, pl + d, pl + 2 * d, ssup); + pm = med3_ssup(pm - d, pm, pm + d, ssup); + pn = med3_ssup(pn - 2 * d, pn - d, pn, ssup); + } + pm = med3_ssup(pl, pm, pn, ssup); + } + swap(a, pm); + pa = pb = a + 1; + pc = pd = a + (n - 1); + for (;;) + { + while (pb <= pc && (r = cmp_ssup(pb, a, ssup)) <= 0) + { + CHECK_FOR_INTERRUPTS(); + if (r == 0) + { + swap(pa, pb); + pa++; + } + pb++; + } + while (pb <= pc && (r = cmp_ssup(pc, a, ssup)) >= 0) + { + CHECK_FOR_INTERRUPTS(); + if (r == 0) + { + swap(pc, pd); + pd--; + } + pc--; + } + if (pb > pc) + break; + swap(pb, pc); + pb++; + pc--; + } + pn = a + n; + r = Min(pa - a, pb - pa); + vecswap(a, pb - r, r); + r = Min(pd - pc, pn - pd - 1); + vecswap(pb, pn - r, r); + if ((r = pb - pa) > 1) + qsort_ssup(a, r, ssup); + if ((r = pd - pc) > 1) + { + /* Iterate rather than recurse to save stack space */ + a = pn - r; + n = r; + goto loop; + } +/* qsort_ssup(pn - r, r, ssup);*/ +} + diff --git a/src/bin/initdb/.gitignore b/src/bin/initdb/.gitignore deleted file mode 100644 index c0ed2e8d1..000000000 --- a/src/bin/initdb/.gitignore +++ /dev/null @@ -1,5 +0,0 @@ -/encnames.c -/pqsignal.c -/localtime.c - -/initdb diff --git a/src/bin/pg_basebackup/.gitignore b/src/bin/pg_basebackup/.gitignore deleted file mode 100644 index 1334a1f77..000000000 --- a/src/bin/pg_basebackup/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -/pg_basebackup -/pg_receivexlog diff --git a/src/bin/pg_config/.gitignore b/src/bin/pg_config/.gitignore deleted file mode 100644 index 169bc766d..000000000 --- a/src/bin/pg_config/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/pg_config diff --git a/src/bin/pg_controldata/.gitignore b/src/bin/pg_controldata/.gitignore deleted file mode 100644 index eab0c28a8..000000000 --- a/src/bin/pg_controldata/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/pg_controldata diff --git a/src/bin/pg_ctl/.gitignore b/src/bin/pg_ctl/.gitignore deleted file mode 100644 index c90c1030e..000000000 --- a/src/bin/pg_ctl/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/pg_ctl diff --git a/src/bin/pg_dump/.gitignore b/src/bin/pg_dump/.gitignore deleted file mode 100644 index c2c8677bd..000000000 --- a/src/bin/pg_dump/.gitignore +++ /dev/null @@ -1,5 +0,0 @@ -/kwlookup.c - -/pg_dump -/pg_dumpall -/pg_restore diff --git a/src/bin/pg_resetxlog/.gitignore b/src/bin/pg_resetxlog/.gitignore deleted file mode 100644 index 6b84208ee..000000000 --- a/src/bin/pg_resetxlog/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/pg_resetxlog diff --git a/src/bin/psql/.gitignore b/src/bin/psql/.gitignore deleted file mode 100644 index 4fbec70bf..000000000 --- a/src/bin/psql/.gitignore +++ /dev/null @@ -1,8 +0,0 @@ -/psqlscan.c -/sql_help.h -/sql_help.c -/dumputils.c -/keywords.c -/kwlookup.c - -/psql diff --git a/src/bin/psql/psqlscan.c b/src/bin/psql/psqlscan.c new file mode 100644 index 000000000..3c3f8e617 --- /dev/null +++ b/src/bin/psql/psqlscan.c @@ -0,0 +1,7681 @@ +#line 2 "psqlscan.c" + +#line 4 "psqlscan.c" + +#define YY_INT_ALIGNED short int + +/* A lexical scanner generated by flex */ + +#define FLEX_SCANNER +#define YY_FLEX_MAJOR_VERSION 2 +#define YY_FLEX_MINOR_VERSION 5 +#define YY_FLEX_SUBMINOR_VERSION 35 +#if YY_FLEX_SUBMINOR_VERSION > 0 +#define FLEX_BETA +#endif + +/* First, we deal with platform-specific or compiler-specific issues. */ + +/* begin standard C headers. */ +#include +#include +#include +#include + +/* end standard C headers. */ + +/* flex integer type definitions */ + +#ifndef FLEXINT_H +#define FLEXINT_H + +/* C99 systems have . Non-C99 systems may or may not. */ + +#if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L + +/* C99 says to define __STDC_LIMIT_MACROS before including stdint.h, + * if you want the limit (max/min) macros for int types. + */ +#ifndef __STDC_LIMIT_MACROS +#define __STDC_LIMIT_MACROS 1 +#endif + +#include +typedef int8_t flex_int8_t; +typedef uint8_t flex_uint8_t; +typedef int16_t flex_int16_t; +typedef uint16_t flex_uint16_t; +typedef int32_t flex_int32_t; +typedef uint32_t flex_uint32_t; +#else +typedef signed char flex_int8_t; +typedef short int flex_int16_t; +typedef int flex_int32_t; +typedef unsigned char flex_uint8_t; +typedef unsigned short int flex_uint16_t; +typedef unsigned int flex_uint32_t; + +/* Limits of integral types. */ +#ifndef INT8_MIN +#define INT8_MIN (-128) +#endif +#ifndef INT16_MIN +#define INT16_MIN (-32767-1) +#endif +#ifndef INT32_MIN +#define INT32_MIN (-2147483647-1) +#endif +#ifndef INT8_MAX +#define INT8_MAX (127) +#endif +#ifndef INT16_MAX +#define INT16_MAX (32767) +#endif +#ifndef INT32_MAX +#define INT32_MAX (2147483647) +#endif +#ifndef UINT8_MAX +#define UINT8_MAX (255U) +#endif +#ifndef UINT16_MAX +#define UINT16_MAX (65535U) +#endif +#ifndef UINT32_MAX +#define UINT32_MAX (4294967295U) +#endif + +#endif /* ! C99 */ + +#endif /* ! FLEXINT_H */ + +#ifdef __cplusplus + +/* The "const" storage-class-modifier is valid. */ +#define YY_USE_CONST + +#else /* ! __cplusplus */ + +/* C99 requires __STDC__ to be defined as 1. */ +#if defined (__STDC__) + +#define YY_USE_CONST + +#endif /* defined (__STDC__) */ +#endif /* ! __cplusplus */ + +#ifdef YY_USE_CONST +#define yyconst const +#else +#define yyconst +#endif + +/* Returned upon end-of-file. */ +#define YY_NULL 0 + +/* Promotes a possibly negative, possibly signed char to an unsigned + * integer for use as an array index. If the signed char is negative, + * we want to instead treat it as an 8-bit unsigned char, hence the + * double cast. + */ +#define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c) + +/* Enter a start condition. This macro really ought to take a parameter, + * but we do it the disgusting crufty way forced on us by the ()-less + * definition of BEGIN. + */ +#define BEGIN (yy_start) = 1 + 2 * + +/* Translate the current start state into a value that can be later handed + * to BEGIN to return to the state. The YYSTATE alias is for lex + * compatibility. + */ +#define YY_START (((yy_start) - 1) / 2) +#define YYSTATE YY_START + +/* Action number for EOF rule of a given start state. */ +#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1) + +/* Special action meaning "start processing a new file". */ +#define YY_NEW_FILE yyrestart(yyin ) + +#define YY_END_OF_BUFFER_CHAR 0 + +/* Size of default input buffer. */ +#ifndef YY_BUF_SIZE +#ifdef __ia64__ +/* On IA-64, the buffer size is 16k, not 8k. + * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case. + * Ditto for the __ia64__ case accordingly. + */ +#define YY_BUF_SIZE 32768 +#else +#define YY_BUF_SIZE 16384 +#endif /* __ia64__ */ +#endif + +/* The state buf must be large enough to hold one state per character in the main buffer. + */ +#define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type)) + +#ifndef YY_TYPEDEF_YY_BUFFER_STATE +#define YY_TYPEDEF_YY_BUFFER_STATE +typedef struct yy_buffer_state *YY_BUFFER_STATE; +#endif + +extern int yyleng; + +extern FILE *yyin, *yyout; + +#define EOB_ACT_CONTINUE_SCAN 0 +#define EOB_ACT_END_OF_FILE 1 +#define EOB_ACT_LAST_MATCH 2 + + #define YY_LESS_LINENO(n) + +/* Return all but the first "n" matched characters back to the input stream. */ +#define yyless(n) \ + do \ + { \ + /* Undo effects of setting up yytext. */ \ + int yyless_macro_arg = (n); \ + YY_LESS_LINENO(yyless_macro_arg);\ + *yy_cp = (yy_hold_char); \ + YY_RESTORE_YY_MORE_OFFSET \ + (yy_c_buf_p) = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \ + YY_DO_BEFORE_ACTION; /* set up yytext again */ \ + } \ + while ( 0 ) + +#define unput(c) yyunput( c, (yytext_ptr) ) + +#ifndef YY_TYPEDEF_YY_SIZE_T +#define YY_TYPEDEF_YY_SIZE_T +typedef size_t yy_size_t; +#endif + +#ifndef YY_STRUCT_YY_BUFFER_STATE +#define YY_STRUCT_YY_BUFFER_STATE +struct yy_buffer_state + { + FILE *yy_input_file; + + char *yy_ch_buf; /* input buffer */ + char *yy_buf_pos; /* current position in input buffer */ + + /* Size of input buffer in bytes, not including room for EOB + * characters. + */ + yy_size_t yy_buf_size; + + /* Number of characters read into yy_ch_buf, not including EOB + * characters. + */ + int yy_n_chars; + + /* Whether we "own" the buffer - i.e., we know we created it, + * and can realloc() it to grow it, and should free() it to + * delete it. + */ + int yy_is_our_buffer; + + /* Whether this is an "interactive" input source; if so, and + * if we're using stdio for input, then we want to use getc() + * instead of fread(), to make sure we stop fetching input after + * each newline. + */ + int yy_is_interactive; + + /* Whether we're considered to be at the beginning of a line. + * If so, '^' rules will be active on the next match, otherwise + * not. + */ + int yy_at_bol; + + int yy_bs_lineno; /**< The line count. */ + int yy_bs_column; /**< The column count. */ + + /* Whether to try to fill the input buffer when we reach the + * end of it. + */ + int yy_fill_buffer; + + int yy_buffer_status; + +#define YY_BUFFER_NEW 0 +#define YY_BUFFER_NORMAL 1 + /* When an EOF's been seen but there's still some text to process + * then we mark the buffer as YY_EOF_PENDING, to indicate that we + * shouldn't try reading from the input source any more. We might + * still have a bunch of tokens to match, though, because of + * possible backing-up. + * + * When we actually see the EOF, we change the status to "new" + * (via yyrestart()), so that the user can continue scanning by + * just pointing yyin at a new input file. + */ +#define YY_BUFFER_EOF_PENDING 2 + + }; +#endif /* !YY_STRUCT_YY_BUFFER_STATE */ + +/* Stack of input buffers. */ +static size_t yy_buffer_stack_top = 0; /**< index of top of stack. */ +static size_t yy_buffer_stack_max = 0; /**< capacity of stack. */ +static YY_BUFFER_STATE * yy_buffer_stack = 0; /**< Stack as an array. */ + +/* We provide macros for accessing buffer states in case in the + * future we want to put the buffer states in a more general + * "scanner state". + * + * Returns the top of the stack, or NULL. + */ +#define YY_CURRENT_BUFFER ( (yy_buffer_stack) \ + ? (yy_buffer_stack)[(yy_buffer_stack_top)] \ + : NULL) + +/* Same as previous macro, but useful when we know that the buffer stack is not + * NULL or when we need an lvalue. For internal use only. + */ +#define YY_CURRENT_BUFFER_LVALUE (yy_buffer_stack)[(yy_buffer_stack_top)] + +/* yy_hold_char holds the character lost when yytext is formed. */ +static char yy_hold_char; +static int yy_n_chars; /* number of characters read into yy_ch_buf */ +int yyleng; + +/* Points to current character in buffer. */ +static char *yy_c_buf_p = (char *) 0; +static int yy_init = 0; /* whether we need to initialize */ +static int yy_start = 0; /* start state number */ + +/* Flag which is used to allow yywrap()'s to do buffer switches + * instead of setting up a fresh yyin. A bit of a hack ... + */ +static int yy_did_buffer_switch_on_eof; + +void yyrestart (FILE *input_file ); +void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer ); +YY_BUFFER_STATE yy_create_buffer (FILE *file,int size ); +void yy_delete_buffer (YY_BUFFER_STATE b ); +void yy_flush_buffer (YY_BUFFER_STATE b ); +void yypush_buffer_state (YY_BUFFER_STATE new_buffer ); +void yypop_buffer_state (void ); + +static void yyensure_buffer_stack (void ); +static void yy_load_buffer_state (void ); +static void yy_init_buffer (YY_BUFFER_STATE b,FILE *file ); + +#define YY_FLUSH_BUFFER yy_flush_buffer(YY_CURRENT_BUFFER ) + +YY_BUFFER_STATE yy_scan_buffer (char *base,yy_size_t size ); +YY_BUFFER_STATE yy_scan_string (yyconst char *yy_str ); +YY_BUFFER_STATE yy_scan_bytes (yyconst char *bytes,int len ); + +void *yyalloc (yy_size_t ); +void *yyrealloc (void *,yy_size_t ); +void yyfree (void * ); + +#define yy_new_buffer yy_create_buffer + +#define yy_set_interactive(is_interactive) \ + { \ + if ( ! YY_CURRENT_BUFFER ){ \ + yyensure_buffer_stack (); \ + YY_CURRENT_BUFFER_LVALUE = \ + yy_create_buffer(yyin,YY_BUF_SIZE ); \ + } \ + YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \ + } + +#define yy_set_bol(at_bol) \ + { \ + if ( ! YY_CURRENT_BUFFER ){\ + yyensure_buffer_stack (); \ + YY_CURRENT_BUFFER_LVALUE = \ + yy_create_buffer(yyin,YY_BUF_SIZE ); \ + } \ + YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \ + } + +#define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol) + +/* Begin user sect3 */ + +#define yywrap(n) 1 +#define YY_SKIP_YYWRAP + +typedef unsigned char YY_CHAR; + +FILE *yyin = (FILE *) 0, *yyout = (FILE *) 0; + +typedef int yy_state_type; + +extern int yylineno; + +int yylineno = 1; + +extern char *yytext; +#define yytext_ptr yytext +static yyconst flex_int16_t yy_nxt[][45] = + { + { + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0 + }, + + { + 37, 38, 39, 40, 39, 41, 42, 43, 44, 41, + 45, 46, 47, 44, 44, 48, 49, 50, 51, 52, + 52, 53, 54, 44, 55, 56, 55, 55, 57, 55, + 58, 55, 55, 59, 60, 61, 41, 56, 55, 58, + 55, 55, 59, 60, 41 + + }, + + { + 37, 38, 39, 40, 39, 41, 42, 43, 44, 41, + 45, 46, 47, 44, 44, 48, 49, 50, 51, 52, + 52, 53, 54, 44, 55, 56, 55, 55, 57, 55, + 58, 55, 55, 59, 60, 61, 41, 56, 55, 58, + 55, 55, 59, 60, 41 + }, + + { + 37, 62, 62, 62, 62, 62, 62, 62, 62, 62, + 63, 62, 62, 62, 62, 62, 62, 62, 62, 62, + 62, 62, 62, 62, 62, 62, 62, 62, 62, 62, + 62, 62, 62, 62, 62, 62, 62, 62, 62, 62, + 62, 62, 62, 62, 62 + + }, + + { + 37, 62, 62, 62, 62, 62, 62, 62, 62, 62, + 63, 62, 62, 62, 62, 62, 62, 62, 62, 62, + 62, 62, 62, 62, 62, 62, 62, 62, 62, 62, + 62, 62, 62, 62, 62, 62, 62, 62, 62, 62, + 62, 62, 62, 62, 62 + }, + + { + 37, 64, 64, 64, 64, 65, 64, 64, 65, 65, + 64, 64, 64, 66, 65, 64, 65, 64, 67, 64, + 64, 64, 64, 65, 64, 64, 64, 64, 64, 64, + 64, 64, 64, 64, 64, 64, 65, 64, 64, 64, + 64, 64, 64, 64, 65 + + }, + + { + 37, 64, 64, 64, 64, 65, 64, 64, 65, 65, + 64, 64, 64, 66, 65, 64, 65, 64, 67, 64, + 64, 64, 64, 65, 64, 64, 64, 64, 64, 64, + 64, 64, 64, 64, 64, 64, 65, 64, 64, 64, + 64, 64, 64, 64, 65 + }, + + { + 37, 68, 68, 68, 68, 68, 69, 68, 68, 68, + 68, 68, 68, 68, 68, 68, 68, 68, 68, 68, + 68, 68, 68, 68, 68, 68, 68, 68, 68, 68, + 68, 68, 68, 68, 68, 68, 68, 68, 68, 68, + 68, 68, 68, 68, 68 + + }, + + { + 37, 68, 68, 68, 68, 68, 69, 68, 68, 68, + 68, 68, 68, 68, 68, 68, 68, 68, 68, 68, + 68, 68, 68, 68, 68, 68, 68, 68, 68, 68, + 68, 68, 68, 68, 68, 68, 68, 68, 68, 68, + 68, 68, 68, 68, 68 + }, + + { + 37, 70, 70, 70, 70, 70, 70, 70, 70, 70, + 71, 70, 70, 70, 70, 70, 70, 70, 70, 70, + 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, + 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, + 70, 70, 70, 70, 70 + + }, + + { + 37, 70, 70, 70, 70, 70, 70, 70, 70, 70, + 71, 70, 70, 70, 70, 70, 70, 70, 70, 70, + 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, + 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, + 70, 70, 70, 70, 70 + }, + + { + 37, 72, 72, 73, 72, 72, 72, 72, 72, 72, + 74, 72, 72, 72, 72, 72, 72, 72, 72, 72, + 72, 72, 72, 72, 72, 72, 72, 72, 72, 72, + 72, 72, 72, 72, 72, 75, 72, 72, 72, 72, + 72, 72, 72, 72, 72 + + }, + + { + 37, 72, 72, 73, 72, 72, 72, 72, 72, 72, + 74, 72, 72, 72, 72, 72, 72, 72, 72, 72, + 72, 72, 72, 72, 72, 72, 72, 72, 72, 72, + 72, 72, 72, 72, 72, 75, 72, 72, 72, 72, + 72, 72, 72, 72, 72 + }, + + { + 37, 76, 76, 76, 76, 76, 76, 76, 76, 76, + 77, 76, 76, 76, 76, 76, 76, 76, 76, 76, + 76, 76, 76, 76, 76, 76, 76, 76, 76, 76, + 76, 76, 76, 76, 76, 76, 76, 76, 76, 76, + 76, 76, 76, 76, 76 + + }, + + { + 37, 76, 76, 76, 76, 76, 76, 76, 76, 76, + 77, 76, 76, 76, 76, 76, 76, 76, 76, 76, + 76, 76, 76, 76, 76, 76, 76, 76, 76, 76, + 76, 76, 76, 76, 76, 76, 76, 76, 76, 76, + 76, 76, 76, 76, 76 + }, + + { + 37, 78, 78, 79, 78, 78, 78, 80, 78, 78, + 78, 78, 78, 78, 78, 78, 78, 78, 78, 78, + 78, 78, 78, 78, 78, 78, 78, 78, 78, 78, + 78, 78, 78, 78, 78, 78, 78, 78, 78, 78, + 78, 78, 78, 78, 78 + + }, + + { + 37, 78, 78, 79, 78, 78, 78, 80, 78, 78, + 78, 78, 78, 78, 78, 78, 78, 78, 78, 78, + 78, 78, 78, 78, 78, 78, 78, 78, 78, 78, + 78, 78, 78, 78, 78, 78, 78, 78, 78, 78, + 78, 78, 78, 78, 78 + }, + + { + 37, 68, 68, 68, 68, 68, 81, 68, 68, 68, + 68, 68, 68, 68, 68, 68, 68, 68, 68, 68, + 68, 68, 68, 68, 68, 68, 68, 68, 68, 68, + 68, 68, 68, 68, 68, 68, 68, 68, 68, 68, + 68, 68, 68, 68, 68 + + }, + + { + 37, 68, 68, 68, 68, 68, 81, 68, 68, 68, + 68, 68, 68, 68, 68, 68, 68, 68, 68, 68, + 68, 68, 68, 68, 68, 68, 68, 68, 68, 68, + 68, 68, 68, 68, 68, 68, 68, 68, 68, 68, + 68, 68, 68, 68, 68 + }, + + { + 37, 76, 76, 76, 76, 76, 76, 76, 76, 76, + 82, 76, 76, 76, 76, 76, 76, 76, 76, 76, + 76, 76, 76, 76, 76, 76, 76, 76, 76, 76, + 76, 76, 76, 76, 76, 76, 76, 76, 76, 76, + 76, 76, 76, 76, 76 + + }, + + { + 37, 76, 76, 76, 76, 76, 76, 76, 76, 76, + 82, 76, 76, 76, 76, 76, 76, 76, 76, 76, + 76, 76, 76, 76, 76, 76, 76, 76, 76, 76, + 76, 76, 76, 76, 76, 76, 76, 76, 76, 76, + 76, 76, 76, 76, 76 + }, + + { + 37, 83, 84, 85, 84, 83, 83, 83, 83, 83, + 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, + 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, + 83, 83, 83, 83, 83, 84, 83, 83, 83, 83, + 83, 83, 83, 83, 83 + + }, + + { + 37, 83, 84, 85, 84, 83, 83, 83, 83, 83, + 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, + 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, + 83, 83, 83, 83, 83, 84, 83, 83, 83, 83, + 83, 83, 83, 83, 83 + }, + + { + 37, 86, 87, 88, 87, 86, 86, 86, 86, 86, + 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, + 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, + 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, + 86, 86, 86, 86, 89 + + }, + + { + 37, 86, 87, 88, 87, 86, 86, 86, 86, 86, + 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, + 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, + 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, + 86, 86, 86, 86, 89 + }, + + { + 37, 90, 91, 92, 91, 90, 93, 90, 90, 90, + 94, 90, 90, 90, 90, 90, 90, 90, 90, 90, + 90, 95, 90, 90, 90, 90, 90, 90, 90, 90, + 90, 90, 90, 90, 90, 91, 96, 90, 90, 90, + 90, 90, 90, 90, 90 + + }, + + { + 37, 90, 91, 92, 91, 90, 93, 90, 90, 90, + 94, 90, 90, 90, 90, 90, 90, 90, 90, 90, + 90, 95, 90, 90, 90, 90, 90, 90, 90, 90, + 90, 90, 90, 90, 90, 91, 96, 90, 90, 90, + 90, 90, 90, 90, 90 + }, + + { + 37, 97, 97, 97, 97, 97, 97, 97, 97, 97, + 98, 97, 97, 97, 97, 97, 97, 97, 97, 97, + 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, + 97, 97, 97, 97, 97, 99, 97, 97, 97, 97, + 97, 97, 97, 97, 97 + + }, + + { + 37, 97, 97, 97, 97, 97, 97, 97, 97, 97, + 98, 97, 97, 97, 97, 97, 97, 97, 97, 97, + 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, + 97, 97, 97, 97, 97, 99, 97, 97, 97, 97, + 97, 97, 97, 97, 97 + }, + + { + 37, 100, 100, 100, 100, 100, 100, 100, 100, 100, + 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, + 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, + 100, 100, 100, 100, 100, 100, 101, 100, 100, 100, + 100, 100, 100, 100, 100 + + }, + + { + 37, 100, 100, 100, 100, 100, 100, 100, 100, 100, + 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, + 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, + 100, 100, 100, 100, 100, 100, 101, 100, 100, 100, + 100, 100, 100, 100, 100 + }, + + { + 37, 102, 102, 102, 102, 102, 103, 102, 102, 102, + 102, 102, 102, 102, 102, 102, 102, 102, 102, 102, + 102, 102, 102, 102, 102, 102, 102, 102, 102, 102, + 102, 102, 102, 102, 102, 102, 102, 102, 102, 102, + 102, 102, 102, 102, 102 + + }, + + { + 37, 102, 102, 102, 102, 102, 103, 102, 102, 102, + 102, 102, 102, 102, 102, 102, 102, 102, 102, 102, + 102, 102, 102, 102, 102, 102, 102, 102, 102, 102, + 102, 102, 102, 102, 102, 102, 102, 102, 102, 102, + 102, 102, 102, 102, 102 + }, + + { + 37, 104, 105, 106, 105, 104, 104, 104, 104, 104, + 104, 104, 104, 104, 104, 104, 104, 104, 104, 104, + 104, 104, 104, 104, 104, 104, 104, 104, 104, 104, + 104, 104, 104, 104, 104, 104, 104, 104, 104, 104, + 104, 104, 104, 104, 104 + + }, + + { + 37, 104, 105, 106, 105, 104, 104, 104, 104, 104, + 104, 104, 104, 104, 104, 104, 104, 104, 104, 104, + 104, 104, 104, 104, 104, 104, 104, 104, 104, 104, + 104, 104, 104, 104, 104, 104, 104, 104, 104, 104, + 104, 104, 104, 104, 104 + }, + + { + 37, 107, 107, 107, 107, 107, 107, 107, 107, 107, + 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, + 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, + 107, 107, 107, 107, 107, 108, 107, 107, 107, 107, + 107, 107, 107, 107, 107 + + }, + + { + 37, 107, 107, 107, 107, 107, 107, 107, 107, 107, + 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, + 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, + 107, 107, 107, 107, 107, 108, 107, 107, 107, 107, + 107, 107, 107, 107, 107 + }, + + { + -37, -37, -37, -37, -37, -37, -37, -37, -37, -37, + -37, -37, -37, -37, -37, -37, -37, -37, -37, -37, + -37, -37, -37, -37, -37, -37, -37, -37, -37, -37, + -37, -37, -37, -37, -37, -37, -37, -37, -37, -37, + -37, -37, -37, -37, -37 + + }, + + { + 37, -38, -38, -38, -38, -38, -38, -38, -38, -38, + -38, -38, -38, -38, -38, -38, -38, -38, -38, -38, + -38, -38, -38, -38, -38, -38, -38, -38, -38, -38, + -38, -38, -38, -38, -38, -38, -38, -38, -38, -38, + -38, -38, -38, -38, -38 + }, + + { + 37, -39, 109, 109, 109, -39, -39, -39, -39, -39, + -39, -39, -39, -39, -39, -39, -39, -39, -39, -39, + -39, -39, -39, -39, -39, -39, -39, -39, -39, -39, + -39, -39, -39, -39, -39, -39, -39, -39, -39, -39, + -39, -39, -39, -39, -39 + + }, + + { + 37, -40, 109, 109, 109, -40, -40, -40, -40, -40, + -40, -40, -40, -40, -40, -40, -40, -40, -40, -40, + -40, -40, -40, -40, -40, -40, -40, -40, -40, -40, + -40, -40, -40, -40, -40, -40, -40, -40, -40, -40, + -40, -40, -40, -40, -40 + }, + + { + 37, -41, -41, -41, -41, 110, -41, -41, 110, 110, + -41, -41, -41, 110, 110, -41, 110, -41, 110, -41, + -41, -41, -41, 110, -41, -41, -41, -41, -41, -41, + -41, -41, -41, -41, -41, -41, 110, -41, -41, -41, + -41, -41, -41, -41, 110 + + }, + + { + 37, -42, -42, -42, -42, -42, -42, -42, -42, -42, + -42, -42, -42, -42, -42, -42, -42, -42, -42, -42, + -42, -42, -42, -42, -42, -42, -42, -42, -42, -42, + -42, -42, -42, -42, -42, -42, -42, -42, -42, -42, + -42, -42, -42, -42, -42 + }, + + { + 37, -43, -43, -43, -43, -43, -43, 111, -43, -43, + -43, -43, -43, -43, -43, -43, -43, -43, -43, 112, + 112, -43, -43, -43, 113, 113, 113, 113, 113, 113, + 113, 113, 113, 113, 113, -43, -43, 113, 113, 113, + 113, 113, 113, 113, -43 + + }, + + { + 37, -44, -44, -44, -44, 110, -44, -44, 110, 110, + -44, -44, -44, 110, 110, -44, 110, -44, 110, -44, + -44, -44, -44, 110, -44, -44, -44, -44, -44, -44, + -44, -44, -44, -44, -44, -44, 110, -44, -44, -44, + -44, -44, -44, -44, 110 + }, + + { + 37, -45, -45, -45, -45, -45, -45, -45, -45, -45, + -45, -45, -45, -45, -45, -45, -45, -45, -45, -45, + -45, -45, -45, -45, -45, -45, -45, -45, -45, -45, + -45, -45, -45, -45, -45, -45, -45, -45, -45, -45, + -45, -45, -45, -45, -45 + + }, + + { + 37, -46, -46, -46, -46, -46, -46, -46, -46, -46, + -46, -46, -46, -46, -46, -46, -46, -46, -46, -46, + -46, -46, -46, -46, -46, -46, -46, -46, -46, -46, + -46, -46, -46, -46, -46, -46, -46, -46, -46, -46, + -46, -46, -46, -46, -46 + }, + + { + 37, -47, -47, -47, -47, -47, -47, -47, -47, -47, + -47, -47, -47, -47, -47, -47, -47, -47, -47, -47, + -47, -47, -47, -47, -47, -47, -47, -47, -47, -47, + -47, -47, -47, -47, -47, -47, -47, -47, -47, -47, + -47, -47, -47, -47, -47 + + }, + + { + 37, -48, -48, -48, -48, -48, -48, -48, -48, -48, + -48, -48, -48, -48, -48, -48, -48, -48, -48, -48, + -48, -48, -48, -48, -48, -48, -48, -48, -48, -48, + -48, -48, -48, -48, -48, -48, -48, -48, -48, -48, + -48, -48, -48, -48, -48 + }, + + { + 37, -49, -49, -49, -49, 110, -49, -49, 110, 110, + -49, -49, -49, 110, 110, -49, 114, -49, 110, -49, + -49, -49, -49, 110, -49, -49, -49, -49, -49, -49, + -49, -49, -49, -49, -49, -49, 110, -49, -49, -49, + -49, -49, -49, -49, 110 + + }, + + { + 37, -50, -50, -50, -50, -50, -50, -50, -50, -50, + -50, -50, -50, -50, -50, -50, -50, 115, -50, 116, + 116, -50, -50, -50, -50, -50, -50, -50, -50, -50, + -50, -50, -50, -50, -50, -50, -50, -50, -50, -50, + -50, -50, -50, -50, -50 + }, + + { + 37, -51, -51, -51, -51, 110, -51, -51, 110, 110, + -51, -51, -51, 117, 110, -51, 110, -51, 110, -51, + -51, -51, -51, 110, -51, -51, -51, -51, -51, -51, + -51, -51, -51, -51, -51, -51, 110, -51, -51, -51, + -51, -51, -51, -51, 110 + + }, + + { + 37, -52, -52, -52, -52, -52, -52, -52, -52, -52, + -52, -52, -52, -52, -52, -52, -52, 118, -52, 119, + 119, -52, -52, -52, -52, -52, -52, -52, 120, -52, + -52, -52, -52, -52, -52, -52, -52, -52, -52, -52, + -52, -52, -52, -52, -52 + }, + + { + 37, -53, -53, -53, -53, -53, 121, -53, -53, -53, + 122, -53, -53, -53, -53, -53, -53, -53, -53, 123, + 123, 124, -53, 125, 123, 123, 123, 123, 123, 123, + 123, 123, 123, 123, 123, -53, -53, 123, 123, 123, + 123, 123, 123, 123, -53 + + }, + + { + 37, -54, -54, -54, -54, -54, -54, -54, -54, -54, + -54, -54, -54, -54, -54, -54, -54, -54, -54, -54, + -54, -54, -54, -54, -54, -54, -54, -54, -54, -54, + -54, -54, -54, -54, -54, -54, -54, -54, -54, -54, + -54, -54, -54, -54, -54 + }, + + { + 37, -55, -55, -55, -55, -55, -55, 126, -55, -55, + -55, -55, -55, -55, -55, -55, -55, -55, -55, 126, + 126, -55, -55, -55, 126, 126, 126, 126, 126, 126, + 126, 126, 126, 126, 126, -55, -55, 126, 126, 126, + 126, 126, 126, 126, -55 + + }, + + { + 37, -56, -56, -56, -56, -56, -56, 126, -56, -56, + 127, -56, -56, -56, -56, -56, -56, -56, -56, 126, + 126, -56, -56, -56, 126, 126, 126, 126, 126, 126, + 126, 126, 126, 126, 126, -56, -56, 126, 126, 126, + 126, 126, 126, 126, -56 + }, + + { + 37, -57, -57, -57, -57, -57, -57, 126, -57, -57, + 128, -57, -57, -57, -57, -57, -57, -57, -57, 126, + 126, -57, -57, -57, 126, 126, 126, 126, 126, 126, + 126, 126, 126, 126, 126, -57, -57, 126, 126, 126, + 126, 126, 126, 126, -57 + + }, + + { + 37, -58, -58, -58, -58, -58, -58, 126, -58, -58, + 129, -58, -58, -58, -58, -58, -58, -58, -58, 126, + 126, -58, -58, -58, 126, 126, 126, 126, 126, 126, + 126, 126, 126, 126, 126, -58, -58, 126, 126, 126, + 126, 126, 126, 126, -58 + }, + + { + 37, -59, -59, -59, -59, -59, -59, 126, -59, 130, + -59, -59, -59, -59, -59, -59, -59, -59, -59, 126, + 126, -59, -59, -59, 126, 126, 126, 126, 126, 126, + 126, 126, 126, 126, 126, -59, -59, 126, 126, 126, + 126, 126, 126, 126, -59 + + }, + + { + 37, -60, -60, -60, -60, -60, -60, 126, -60, -60, + 131, -60, -60, -60, -60, -60, -60, -60, -60, 126, + 126, -60, -60, -60, 126, 126, 126, 126, 126, 126, + 126, 126, 126, 126, 126, -60, -60, 126, 126, 126, + 126, 126, 126, 126, -60 + }, + + { + 37, -61, -61, -61, -61, -61, -61, -61, -61, -61, + -61, -61, -61, -61, -61, -61, -61, -61, -61, -61, + -61, 132, 132, -61, -61, -61, -61, -61, -61, -61, + -61, -61, -61, -61, -61, -61, -61, -61, -61, -61, + -61, -61, -61, -61, -61 + + }, + + { + 37, 133, 133, 133, 133, 133, 133, 133, 133, 133, + -62, 133, 133, 133, 133, 133, 133, 133, 133, 133, + 133, 133, 133, 133, 133, 133, 133, 133, 133, 133, + 133, 133, 133, 133, 133, 133, 133, 133, 133, 133, + 133, 133, 133, 133, 133 + }, + + { + 37, -63, 134, 135, 135, -63, -63, -63, -63, -63, + -63, -63, -63, -63, -63, -63, 136, -63, -63, -63, + -63, -63, -63, -63, -63, -63, -63, -63, -63, -63, + -63, -63, -63, -63, -63, -63, -63, -63, -63, -63, + -63, -63, -63, -63, -63 + + }, + + { + 37, 137, 137, 137, 137, 137, 137, 137, 137, 137, + 137, 137, 137, -64, 137, 137, 137, 137, -64, 137, + 137, 137, 137, 137, 137, 137, 137, 137, 137, 137, + 137, 137, 137, 137, 137, 137, 137, 137, 137, 137, + 137, 137, 137, 137, 137 + }, + + { + 37, 137, 137, 137, 137, 137, 137, 137, 137, 137, + 137, 137, 137, -65, 137, 137, 137, 137, -65, 137, + 137, 137, 137, 137, 137, 137, 137, 137, 137, 137, + 137, 137, 137, 137, 137, 137, 137, 137, 137, 137, + 137, 137, 137, 137, 137 + + }, + + { + 37, -66, -66, -66, -66, -66, -66, -66, -66, -66, + -66, -66, -66, 138, -66, -66, -66, -66, 139, -66, + -66, -66, -66, -66, -66, -66, -66, -66, -66, -66, + -66, -66, -66, -66, -66, -66, -66, -66, -66, -66, + -66, -66, -66, -66, -66 + }, + + { + 37, -67, -67, -67, -67, -67, -67, -67, -67, -67, + -67, -67, -67, 140, -67, -67, -67, -67, -67, -67, + -67, -67, -67, -67, -67, -67, -67, -67, -67, -67, + -67, -67, -67, -67, -67, -67, -67, -67, -67, -67, + -67, -67, -67, -67, -67 + + }, + + { + 37, 141, 141, 141, 141, 141, -68, 141, 141, 141, + 141, 141, 141, 141, 141, 141, 141, 141, 141, 141, + 141, 141, 141, 141, 141, 141, 141, 141, 141, 141, + 141, 141, 141, 141, 141, 141, 141, 141, 141, 141, + 141, 141, 141, 141, 141 + }, + + { + 37, -69, -69, -69, -69, -69, 142, -69, -69, -69, + -69, -69, -69, -69, -69, -69, -69, -69, -69, -69, + -69, -69, -69, -69, -69, -69, -69, -69, -69, -69, + -69, -69, -69, -69, -69, -69, -69, -69, -69, -69, + -69, -69, -69, -69, -69 + + }, + + { + 37, 143, 143, 143, 143, 143, 143, 143, 143, 143, + -70, 143, 143, 143, 143, 143, 143, 143, 143, 143, + 143, 143, 143, 143, 143, 143, 143, 143, 143, 143, + 143, 143, 143, 143, 143, 143, 143, 143, 143, 143, + 143, 143, 143, 143, 143 + }, + + { + 37, -71, 144, 145, 145, -71, -71, -71, -71, -71, + -71, -71, -71, -71, -71, -71, 146, -71, -71, -71, + -71, -71, -71, -71, -71, -71, -71, -71, -71, -71, + -71, -71, -71, -71, -71, -71, -71, -71, -71, -71, + -71, -71, -71, -71, -71 + + }, + + { + 37, 147, 147, 147, 147, 147, 147, 147, 147, 147, + -72, 147, 147, 147, 147, 147, 147, 147, 147, 147, + 147, 147, 147, 147, 147, 147, 147, 147, 147, 147, + 147, 147, 147, 147, 147, -72, 147, 147, 147, 147, + 147, 147, 147, 147, 147 + }, + + { + 37, 147, 147, 147, 147, 147, 147, 147, 147, 147, + -73, 147, 147, 147, 147, 147, 147, 147, 147, 147, + 147, 147, 147, 147, 147, 147, 147, 147, 147, 147, + 147, 147, 147, 147, 147, -73, 147, 147, 147, 147, + 147, 147, 147, 147, 147 + + }, + + { + 37, -74, 148, 149, 149, -74, -74, -74, -74, -74, + 150, -74, -74, -74, -74, -74, 151, -74, -74, -74, + -74, -74, -74, -74, -74, -74, -74, -74, -74, -74, + -74, -74, -74, -74, -74, -74, -74, -74, -74, -74, + -74, -74, -74, -74, -74 + }, + + { + 37, 152, 152, 152, 152, 152, 152, 152, 152, 152, + 152, 152, 152, 152, 152, 152, 152, 152, 152, 153, + 152, 152, 152, 152, 152, 152, 152, 152, 152, 152, + 152, 152, 152, 154, 152, 152, 152, 152, 152, 152, + 152, 152, 155, 156, 152 + + }, + + { + 37, 157, 157, 157, 157, 157, 157, 157, 157, 157, + -76, 157, 157, 157, 157, 157, 157, 157, 157, 157, + 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, + 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, + 157, 157, 157, 157, 157 + }, + + { + 37, -77, 148, 149, 149, -77, -77, -77, -77, -77, + 150, -77, -77, -77, -77, -77, 151, -77, -77, -77, + -77, -77, -77, -77, -77, -77, -77, -77, -77, -77, + -77, -77, -77, -77, -77, -77, -77, -77, -77, -77, + -77, -77, -77, -77, -77 + + }, + + { + 37, 158, 158, 158, 158, 158, 158, -78, 158, 158, + 158, 158, 158, 158, 158, 158, 158, 158, 158, 158, + 158, 158, 158, 158, 158, 158, 158, 158, 158, 158, + 158, 158, 158, 158, 158, 158, 158, 158, 158, 158, + 158, 158, 158, 158, 158 + }, + + { + 37, 158, 158, 158, 158, 158, 158, -79, 158, 158, + 158, 158, 158, 158, 158, 158, 158, 158, 158, 158, + 158, 158, 158, 158, 158, 158, 158, 158, 158, 158, + 158, 158, 158, 158, 158, 158, 158, 158, 158, 158, + 158, 158, 158, 158, 158 + + }, + + { + 37, -80, -80, -80, -80, -80, -80, 159, -80, -80, + -80, -80, -80, -80, -80, -80, -80, -80, -80, -80, + -80, -80, -80, -80, 160, 160, 160, 160, 160, 160, + 160, 160, 160, 160, 160, -80, -80, 160, 160, 160, + 160, 160, 160, 160, -80 + }, + + { + 37, -81, 161, 161, 161, -81, 142, -81, -81, -81, + -81, -81, -81, -81, -81, -81, 162, -81, -81, -81, + -81, -81, -81, -81, -81, -81, -81, -81, -81, -81, + -81, -81, -81, 163, -81, -81, -81, -81, -81, -81, + -81, -81, 163, -81, -81 + + }, + + { + 37, -82, 164, 165, 165, -82, -82, -82, -82, -82, + 150, -82, -82, -82, -82, -82, 166, -82, -82, -82, + -82, -82, -82, -82, -82, -82, -82, -82, -82, -82, + -82, -82, -82, 167, -82, -82, -82, -82, -82, -82, + -82, -82, 167, -82, -82 + }, + + { + 37, -83, -83, -83, -83, -83, -83, -83, -83, -83, + -83, -83, -83, -83, -83, -83, -83, -83, -83, -83, + -83, -83, -83, -83, -83, -83, -83, -83, -83, -83, + -83, -83, -83, -83, -83, -83, -83, -83, -83, -83, + -83, -83, -83, -83, -83 + + }, + + { + 37, -84, -84, -84, -84, -84, -84, -84, -84, -84, + -84, -84, -84, -84, -84, -84, -84, -84, -84, -84, + -84, -84, -84, -84, -84, -84, -84, -84, -84, -84, + -84, -84, -84, -84, -84, -84, -84, -84, -84, -84, + -84, -84, -84, -84, -84 + }, + + { + 37, -85, -85, -85, -85, -85, -85, -85, -85, -85, + -85, -85, -85, -85, -85, -85, -85, -85, -85, -85, + -85, -85, -85, -85, -85, -85, -85, -85, -85, -85, + -85, -85, -85, -85, -85, -85, -85, -85, -85, -85, + -85, -85, -85, -85, -85 + + }, + + { + 37, -86, -86, -86, -86, -86, -86, -86, -86, -86, + -86, -86, -86, -86, -86, -86, -86, -86, -86, -86, + -86, -86, -86, -86, -86, -86, -86, -86, -86, -86, + -86, -86, -86, -86, -86, -86, -86, -86, -86, -86, + -86, -86, -86, -86, -86 + }, + + { + 37, -87, 168, 168, 168, -87, -87, -87, -87, -87, + -87, -87, -87, -87, -87, -87, -87, -87, -87, -87, + -87, -87, -87, -87, -87, -87, -87, -87, -87, -87, + -87, -87, -87, -87, -87, -87, -87, -87, -87, -87, + -87, -87, -87, -87, -87 + + }, + + { + 37, -88, 168, 168, 168, -88, -88, -88, -88, -88, + -88, -88, -88, -88, -88, -88, -88, -88, -88, -88, + -88, -88, -88, -88, -88, -88, -88, -88, -88, -88, + -88, -88, -88, -88, -88, -88, -88, -88, -88, -88, + -88, -88, -88, -88, -88 + }, + + { + 37, -89, -89, -89, -89, -89, -89, -89, -89, -89, + -89, -89, -89, -89, -89, -89, -89, -89, -89, -89, + -89, -89, -89, -89, -89, -89, -89, -89, -89, -89, + -89, -89, -89, -89, -89, -89, -89, -89, -89, -89, + -89, -89, -89, -89, -89 + + }, + + { + 37, -90, -90, -90, -90, -90, -90, -90, -90, -90, + -90, -90, -90, -90, -90, -90, -90, -90, -90, -90, + -90, -90, -90, -90, -90, -90, -90, -90, -90, -90, + -90, -90, -90, -90, -90, -90, -90, -90, -90, -90, + -90, -90, -90, -90, -90 + }, + + { + 37, -91, -91, -91, -91, -91, -91, -91, -91, -91, + -91, -91, -91, -91, -91, -91, -91, -91, -91, -91, + -91, -91, -91, -91, -91, -91, -91, -91, -91, -91, + -91, -91, -91, -91, -91, -91, -91, -91, -91, -91, + -91, -91, -91, -91, -91 + + }, + + { + 37, -92, -92, -92, -92, -92, -92, -92, -92, -92, + -92, -92, -92, -92, -92, -92, -92, -92, -92, -92, + -92, -92, -92, -92, -92, -92, -92, -92, -92, -92, + -92, -92, -92, -92, -92, -92, -92, -92, -92, -92, + -92, -92, -92, -92, -92 + }, + + { + 37, -93, -93, -93, -93, -93, -93, -93, -93, -93, + -93, -93, -93, -93, -93, -93, -93, -93, -93, -93, + -93, -93, -93, -93, -93, -93, -93, -93, -93, -93, + -93, -93, -93, -93, -93, -93, -93, -93, -93, -93, + -93, -93, -93, -93, -93 + + }, + + { + 37, -94, -94, -94, -94, -94, -94, -94, -94, -94, + -94, -94, -94, -94, -94, -94, -94, -94, -94, -94, + -94, -94, -94, -94, -94, -94, -94, -94, -94, -94, + -94, -94, -94, -94, -94, -94, -94, -94, -94, -94, + -94, -94, -94, -94, -94 + }, + + { + 37, -95, -95, -95, -95, -95, 169, -95, -95, -95, + 170, -95, -95, -95, -95, -95, -95, -95, -95, 171, + 171, -95, -95, -95, 171, 171, 171, 171, 171, 171, + 171, 171, 171, 171, 171, -95, -95, 171, 171, 171, + 171, 171, 171, 171, -95 + + }, + + { + 37, -96, -96, -96, -96, -96, -96, -96, -96, -96, + -96, -96, -96, -96, -96, -96, -96, -96, -96, -96, + -96, -96, -96, -96, -96, -96, -96, -96, -96, -96, + -96, -96, -96, -96, -96, -96, -96, -96, -96, -96, + -96, -96, -96, -96, -96 + }, + + { + 37, -97, -97, -97, -97, -97, -97, -97, -97, -97, + -97, -97, -97, -97, -97, -97, -97, -97, -97, -97, + -97, -97, -97, -97, -97, -97, -97, -97, -97, -97, + -97, -97, -97, -97, -97, -97, -97, -97, -97, -97, + -97, -97, -97, -97, -97 + + }, + + { + 37, -98, -98, -98, -98, -98, -98, -98, -98, -98, + 172, -98, -98, -98, -98, -98, -98, -98, -98, -98, + -98, -98, -98, -98, -98, -98, -98, -98, -98, -98, + -98, -98, -98, -98, -98, -98, -98, -98, -98, -98, + -98, -98, -98, -98, -98 + }, + + { + 37, 173, 173, -99, 173, 173, 173, 173, 173, 173, + 173, 173, 173, 173, 173, 173, 173, 173, 173, 174, + 173, 173, 173, 173, 173, 173, 173, 173, 173, 173, + 173, 173, 173, 173, 173, 173, 173, 175, 176, 177, + 178, 179, 173, 180, 173 + + }, + + { + 37, -100, -100, -100, -100, -100, -100, -100, -100, -100, + -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, + -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, + -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, + -100, -100, -100, -100, -100 + }, + + { + 37, -101, -101, -101, -101, -101, -101, -101, -101, -101, + -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, + -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, + -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, + -101, -101, -101, -101, -101 + + }, + + { + 37, -102, -102, -102, -102, -102, -102, -102, -102, -102, + -102, -102, -102, -102, -102, -102, -102, -102, -102, -102, + -102, -102, -102, -102, -102, -102, -102, -102, -102, -102, + -102, -102, -102, -102, -102, -102, -102, -102, -102, -102, + -102, -102, -102, -102, -102 + }, + + { + 37, -103, -103, -103, -103, -103, -103, -103, -103, -103, + -103, -103, -103, -103, -103, -103, -103, -103, -103, -103, + -103, -103, -103, -103, -103, -103, -103, -103, -103, -103, + -103, -103, -103, -103, -103, -103, -103, -103, -103, -103, + -103, -103, -103, -103, -103 + + }, + + { + 37, -104, -104, -104, -104, -104, -104, -104, -104, -104, + -104, -104, -104, -104, -104, -104, -104, -104, -104, -104, + -104, -104, -104, -104, -104, -104, -104, -104, -104, -104, + -104, -104, -104, -104, -104, -104, -104, -104, -104, -104, + -104, -104, -104, -104, -104 + }, + + { + 37, -105, 181, 181, 181, -105, -105, -105, -105, -105, + -105, -105, -105, -105, -105, -105, -105, -105, -105, -105, + -105, -105, -105, -105, -105, -105, -105, -105, -105, -105, + -105, -105, -105, -105, -105, -105, -105, -105, -105, -105, + -105, -105, -105, -105, -105 + + }, + + { + 37, -106, 181, 181, 181, -106, -106, -106, -106, -106, + -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, + -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, + -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, + -106, -106, -106, -106, -106 + }, + + { + 37, -107, -107, -107, -107, -107, -107, -107, -107, -107, + -107, -107, -107, -107, -107, -107, -107, -107, -107, -107, + -107, -107, -107, -107, -107, -107, -107, -107, -107, -107, + -107, -107, -107, -107, -107, -107, -107, -107, -107, -107, + -107, -107, -107, -107, -107 + + }, + + { + 37, -108, -108, -108, -108, -108, -108, -108, -108, -108, + -108, -108, -108, -108, -108, -108, -108, -108, -108, -108, + -108, -108, -108, -108, -108, -108, -108, -108, -108, -108, + -108, -108, -108, -108, -108, 182, -108, -108, -108, -108, + -108, -108, -108, -108, -108 + }, + + { + 37, -109, 109, 109, 109, -109, -109, -109, -109, -109, + -109, -109, -109, -109, -109, -109, -109, -109, -109, -109, + -109, -109, -109, -109, -109, -109, -109, -109, -109, -109, + -109, -109, -109, -109, -109, -109, -109, -109, -109, -109, + -109, -109, -109, -109, -109 + + }, + + { + 37, -110, -110, -110, -110, 110, -110, -110, 110, 110, + -110, -110, -110, 110, 110, -110, 110, -110, 110, -110, + -110, -110, -110, 110, -110, -110, -110, -110, -110, -110, + -110, -110, -110, -110, -110, -110, 110, -110, -110, -110, + -110, -110, -110, -110, 110 + }, + + { + 37, -111, -111, -111, -111, -111, -111, -111, -111, -111, + -111, -111, -111, -111, -111, -111, -111, -111, -111, -111, + -111, -111, -111, -111, -111, -111, -111, -111, -111, -111, + -111, -111, -111, -111, -111, -111, -111, -111, -111, -111, + -111, -111, -111, -111, -111 + + }, + + { + 37, -112, -112, -112, -112, -112, -112, -112, -112, -112, + -112, -112, -112, -112, -112, -112, -112, -112, -112, 112, + 112, -112, -112, -112, -112, -112, -112, -112, -112, -112, + -112, -112, -112, -112, -112, -112, -112, -112, -112, -112, + -112, -112, -112, -112, -112 + }, + + { + 37, -113, -113, -113, -113, -113, -113, 111, -113, -113, + -113, -113, -113, -113, -113, -113, -113, -113, -113, 183, + 183, -113, -113, -113, 183, 183, 183, 183, 183, 183, + 183, 183, 183, 183, 183, -113, -113, 183, 183, 183, + 183, 183, 183, 183, -113 + + }, + + { + 37, 184, 184, -114, -114, 185, 184, 184, 185, 185, + 184, 184, 184, 185, 185, 184, 185, 184, 185, 184, + 184, 184, 184, 185, 184, 184, 184, 184, 184, 184, + 184, 184, 184, 184, 184, 184, 185, 184, 184, 184, + 184, 184, 184, 184, 185 + }, + + { + 37, -115, -115, -115, -115, -115, -115, -115, -115, -115, + -115, -115, -115, -115, -115, -115, -115, -115, -115, -115, + -115, -115, -115, -115, -115, -115, -115, -115, -115, -115, + -115, -115, -115, -115, -115, -115, -115, -115, -115, -115, + -115, -115, -115, -115, -115 + + }, + + { + 37, -116, -116, -116, -116, -116, -116, -116, -116, -116, + -116, -116, -116, -116, -116, -116, -116, -116, -116, 116, + 116, -116, -116, -116, -116, -116, -116, -116, 120, -116, + -116, -116, -116, -116, -116, -116, -116, -116, -116, -116, + -116, -116, -116, -116, -116 + }, + + { + 37, -117, -117, -117, -117, 186, -117, -117, 186, 186, + -117, -117, -117, 186, 186, -117, 186, -117, 186, -117, + -117, -117, -117, 186, -117, -117, -117, -117, -117, -117, + -117, -117, -117, -117, -117, -117, 186, -117, -117, -117, + -117, -117, -117, -117, 186 + + }, + + { + 37, -118, -118, -118, -118, -118, -118, -118, -118, -118, + -118, -118, -118, -118, -118, -118, -118, 187, -118, 188, + 188, -118, -118, -118, -118, -118, -118, -118, 120, -118, + -118, -118, -118, -118, -118, -118, -118, -118, -118, -118, + -118, -118, -118, -118, -118 + }, + + { + 37, -119, -119, -119, -119, -119, -119, -119, -119, -119, + -119, -119, -119, -119, -119, -119, -119, 118, -119, 119, + 119, -119, -119, -119, -119, -119, -119, -119, 120, -119, + -119, -119, -119, -119, -119, -119, -119, -119, -119, -119, + -119, -119, -119, -119, -119 + + }, + + { + 37, -120, -120, -120, -120, -120, -120, -120, -120, -120, + -120, -120, -120, -120, 189, -120, 189, -120, -120, 190, + 190, -120, -120, -120, -120, -120, -120, -120, -120, -120, + -120, -120, -120, -120, -120, -120, -120, -120, -120, -120, + -120, -120, -120, -120, -120 + }, + + { + 37, -121, -121, -121, -121, -121, -121, -121, -121, -121, + -121, -121, -121, -121, -121, -121, -121, -121, -121, 191, + 191, -121, -121, -121, 191, 191, 191, 191, 191, 191, + 191, 191, 191, 191, 191, -121, -121, 191, 191, 191, + 191, 191, 191, 191, -121 + + }, + + { + 37, -122, -122, -122, -122, -122, -122, -122, -122, -122, + -122, -122, -122, -122, -122, -122, -122, -122, -122, 192, + 192, -122, -122, -122, 192, 192, 192, 192, 192, 192, + 192, 192, 192, 192, 192, -122, -122, 192, 192, 192, + 192, 192, 192, 192, -122 + }, + + { + 37, -123, -123, -123, -123, -123, -123, -123, -123, -123, + -123, -123, -123, -123, -123, -123, -123, -123, -123, 123, + 123, -123, -123, -123, 123, 123, 123, 123, 123, 123, + 123, 123, 123, 123, 123, -123, -123, 123, 123, 123, + 123, 123, 123, 123, -123 + + }, + + { + 37, -124, -124, -124, -124, -124, -124, -124, -124, -124, + -124, -124, -124, -124, -124, -124, -124, -124, -124, -124, + -124, -124, -124, -124, -124, -124, -124, -124, -124, -124, + -124, -124, -124, -124, -124, -124, -124, -124, -124, -124, + -124, -124, -124, -124, -124 + }, + + { + 37, -125, -125, -125, -125, -125, -125, -125, -125, -125, + -125, -125, -125, -125, -125, -125, -125, -125, -125, -125, + -125, -125, -125, -125, -125, -125, -125, -125, -125, -125, + -125, -125, -125, -125, -125, -125, -125, -125, -125, -125, + -125, -125, -125, -125, -125 + + }, + + { + 37, -126, -126, -126, -126, -126, -126, 126, -126, -126, + -126, -126, -126, -126, -126, -126, -126, -126, -126, 126, + 126, -126, -126, -126, 126, 126, 126, 126, 126, 126, + 126, 126, 126, 126, 126, -126, -126, 126, 126, 126, + 126, 126, 126, 126, -126 + }, + + { + 37, -127, -127, -127, -127, -127, -127, -127, -127, -127, + -127, -127, -127, -127, -127, -127, -127, -127, -127, -127, + -127, -127, -127, -127, -127, -127, -127, -127, -127, -127, + -127, -127, -127, -127, -127, -127, -127, -127, -127, -127, + -127, -127, -127, -127, -127 + + }, + + { + 37, -128, -128, -128, -128, -128, -128, -128, -128, -128, + -128, -128, -128, -128, -128, -128, -128, -128, -128, -128, + -128, -128, -128, -128, -128, -128, -128, -128, -128, -128, + -128, -128, -128, -128, -128, -128, -128, -128, -128, -128, + -128, -128, -128, -128, -128 + }, + + { + 37, -129, -129, -129, -129, -129, -129, -129, -129, -129, + -129, -129, -129, -129, -129, -129, -129, -129, -129, -129, + -129, -129, -129, -129, -129, -129, -129, -129, -129, -129, + -129, -129, -129, -129, -129, -129, -129, -129, -129, -129, + -129, -129, -129, -129, -129 + + }, + + { + 37, -130, -130, -130, -130, -130, 193, -130, -130, -130, + 194, -130, -130, -130, -130, -130, -130, -130, -130, -130, + -130, -130, -130, -130, -130, -130, -130, -130, -130, -130, + -130, -130, -130, -130, -130, -130, -130, -130, -130, -130, + -130, -130, -130, -130, -130 + }, + + { + 37, -131, -131, -131, -131, -131, -131, -131, -131, -131, + -131, -131, -131, -131, -131, -131, -131, -131, -131, -131, + -131, -131, -131, -131, -131, -131, -131, -131, -131, -131, + -131, -131, -131, -131, -131, -131, -131, -131, -131, -131, + -131, -131, -131, -131, -131 + + }, + + { + 37, -132, -132, -132, -132, -132, -132, -132, -132, -132, + -132, -132, -132, -132, -132, -132, -132, -132, -132, -132, + -132, -132, -132, -132, -132, -132, -132, -132, -132, -132, + -132, -132, -132, -132, -132, -132, -132, -132, -132, -132, + -132, -132, -132, -132, -132 + }, + + { + 37, 133, 133, 133, 133, 133, 133, 133, 133, 133, + -133, 133, 133, 133, 133, 133, 133, 133, 133, 133, + 133, 133, 133, 133, 133, 133, 133, 133, 133, 133, + 133, 133, 133, 133, 133, 133, 133, 133, 133, 133, + 133, 133, 133, 133, 133 + + }, + + { + 37, -134, 134, 135, 135, -134, -134, -134, -134, -134, + -134, -134, -134, -134, -134, -134, 136, -134, -134, -134, + -134, -134, -134, -134, -134, -134, -134, -134, -134, -134, + -134, -134, -134, -134, -134, -134, -134, -134, -134, -134, + -134, -134, -134, -134, -134 + }, + + { + 37, -135, 195, 195, 195, -135, -135, -135, -135, -135, + 196, -135, -135, -135, -135, -135, 197, -135, -135, -135, + -135, -135, -135, -135, -135, -135, -135, -135, -135, -135, + -135, -135, -135, -135, -135, -135, -135, -135, -135, -135, + -135, -135, -135, -135, -135 + + }, + + { + 37, -136, -136, -136, -136, -136, -136, -136, -136, -136, + -136, -136, -136, -136, -136, -136, 198, -136, -136, -136, + -136, -136, -136, -136, -136, -136, -136, -136, -136, -136, + -136, -136, -136, -136, -136, -136, -136, -136, -136, -136, + -136, -136, -136, -136, -136 + }, + + { + 37, 137, 137, 137, 137, 137, 137, 137, 137, 137, + 137, 137, 137, -137, 137, 137, 137, 137, -137, 137, + 137, 137, 137, 137, 137, 137, 137, 137, 137, 137, + 137, 137, 137, 137, 137, 137, 137, 137, 137, 137, + 137, 137, 137, 137, 137 + + }, + + { + 37, -138, -138, -138, -138, -138, -138, -138, -138, -138, + -138, -138, -138, 138, -138, -138, -138, -138, 139, -138, + -138, -138, -138, -138, -138, -138, -138, -138, -138, -138, + -138, -138, -138, -138, -138, -138, -138, -138, -138, -138, + -138, -138, -138, -138, -138 + }, + + { + 37, -139, -139, -139, -139, -139, -139, -139, -139, -139, + -139, -139, -139, -139, -139, -139, -139, -139, -139, -139, + -139, -139, -139, -139, -139, -139, -139, -139, -139, -139, + -139, -139, -139, -139, -139, -139, -139, -139, -139, -139, + -139, -139, -139, -139, -139 + + }, + + { + 37, -140, -140, -140, -140, 199, -140, -140, 199, 199, + -140, -140, -140, 199, 199, -140, 199, -140, 199, -140, + -140, -140, -140, 199, -140, -140, -140, -140, -140, -140, + -140, -140, -140, -140, -140, -140, 199, -140, -140, -140, + -140, -140, -140, -140, 199 + }, + + { + 37, 141, 141, 141, 141, 141, -141, 141, 141, 141, + 141, 141, 141, 141, 141, 141, 141, 141, 141, 141, + 141, 141, 141, 141, 141, 141, 141, 141, 141, 141, + 141, 141, 141, 141, 141, 141, 141, 141, 141, 141, + 141, 141, 141, 141, 141 + + }, + + { + 37, -142, -142, -142, -142, -142, -142, -142, -142, -142, + -142, -142, -142, -142, -142, -142, -142, -142, -142, -142, + -142, -142, -142, -142, -142, -142, -142, -142, -142, -142, + -142, -142, -142, -142, -142, -142, -142, -142, -142, -142, + -142, -142, -142, -142, -142 + }, + + { + 37, 143, 143, 143, 143, 143, 143, 143, 143, 143, + -143, 143, 143, 143, 143, 143, 143, 143, 143, 143, + 143, 143, 143, 143, 143, 143, 143, 143, 143, 143, + 143, 143, 143, 143, 143, 143, 143, 143, 143, 143, + 143, 143, 143, 143, 143 + + }, + + { + 37, -144, 144, 145, 145, -144, -144, -144, -144, -144, + -144, -144, -144, -144, -144, -144, 146, -144, -144, -144, + -144, -144, -144, -144, -144, -144, -144, -144, -144, -144, + -144, -144, -144, -144, -144, -144, -144, -144, -144, -144, + -144, -144, -144, -144, -144 + }, + + { + 37, -145, 200, 200, 200, -145, -145, -145, -145, -145, + 201, -145, -145, -145, -145, -145, 202, -145, -145, -145, + -145, -145, -145, -145, -145, -145, -145, -145, -145, -145, + -145, -145, -145, -145, -145, -145, -145, -145, -145, -145, + -145, -145, -145, -145, -145 + + }, + + { + 37, -146, -146, -146, -146, -146, -146, -146, -146, -146, + -146, -146, -146, -146, -146, -146, 203, -146, -146, -146, + -146, -146, -146, -146, -146, -146, -146, -146, -146, -146, + -146, -146, -146, -146, -146, -146, -146, -146, -146, -146, + -146, -146, -146, -146, -146 + }, + + { + 37, 147, 147, 147, 147, 147, 147, 147, 147, 147, + -147, 147, 147, 147, 147, 147, 147, 147, 147, 147, + 147, 147, 147, 147, 147, 147, 147, 147, 147, 147, + 147, 147, 147, 147, 147, -147, 147, 147, 147, 147, + 147, 147, 147, 147, 147 + + }, + + { + 37, -148, 148, 149, 149, -148, -148, -148, -148, -148, + -148, -148, -148, -148, -148, -148, 151, -148, -148, -148, + -148, -148, -148, -148, -148, -148, -148, -148, -148, -148, + -148, -148, -148, -148, -148, -148, -148, -148, -148, -148, + -148, -148, -148, -148, -148 + }, + + { + 37, -149, 204, 204, 204, -149, -149, -149, -149, -149, + 205, -149, -149, -149, -149, -149, 206, -149, -149, -149, + -149, -149, -149, -149, -149, -149, -149, -149, -149, -149, + -149, -149, -149, -149, -149, -149, -149, -149, -149, -149, + -149, -149, -149, -149, -149 + + }, + + { + 37, -150, -150, -150, -150, -150, -150, -150, -150, -150, + -150, -150, -150, -150, -150, -150, -150, -150, -150, -150, + -150, -150, -150, -150, -150, -150, -150, -150, -150, -150, + -150, -150, -150, -150, -150, -150, -150, -150, -150, -150, + -150, -150, -150, -150, -150 + }, + + { + 37, -151, -151, -151, -151, -151, -151, -151, -151, -151, + -151, -151, -151, -151, -151, -151, 207, -151, -151, -151, + -151, -151, -151, -151, -151, -151, -151, -151, -151, -151, + -151, -151, -151, -151, -151, -151, -151, -151, -151, -151, + -151, -151, -151, -151, -151 + + }, + + { + 37, -152, -152, -152, -152, -152, -152, -152, -152, -152, + -152, -152, -152, -152, -152, -152, -152, -152, -152, -152, + -152, -152, -152, -152, -152, -152, -152, -152, -152, -152, + -152, -152, -152, -152, -152, -152, -152, -152, -152, -152, + -152, -152, -152, -152, -152 + }, + + { + 37, -153, -153, -153, -153, -153, -153, -153, -153, -153, + -153, -153, -153, -153, -153, -153, -153, -153, -153, 208, + -153, -153, -153, -153, -153, -153, -153, -153, -153, -153, + -153, -153, -153, -153, -153, -153, -153, -153, -153, -153, + -153, -153, -153, -153, -153 + + }, + + { + 37, -154, -154, -154, -154, -154, -154, -154, -154, -154, + -154, -154, -154, -154, -154, -154, -154, -154, -154, 209, + 209, -154, -154, -154, 209, 209, 209, 209, 209, -154, + -154, -154, -154, -154, -154, -154, -154, 209, 209, -154, + -154, -154, -154, -154, -154 + }, + + { + 37, -155, -155, -155, -155, -155, -155, -155, -155, -155, + -155, -155, -155, -155, -155, -155, -155, -155, -155, 210, + 210, -155, -155, -155, 210, 210, 210, 210, 210, -155, + -155, -155, -155, -155, -155, -155, -155, 210, 210, -155, + -155, -155, -155, -155, -155 + + }, + + { + 37, -156, -156, -156, -156, -156, -156, -156, -156, -156, + -156, -156, -156, -156, -156, -156, -156, -156, -156, 211, + 211, -156, -156, -156, 211, 211, 211, 211, 211, -156, + -156, -156, -156, -156, -156, -156, -156, 211, 211, -156, + -156, -156, -156, -156, -156 + }, + + { + 37, 157, 157, 157, 157, 157, 157, 157, 157, 157, + -157, 157, 157, 157, 157, 157, 157, 157, 157, 157, + 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, + 157, 157, 157, 157, 157, 157, 157, 157, 157, 157, + 157, 157, 157, 157, 157 + + }, + + { + 37, 158, 158, 158, 158, 158, 158, -158, 158, 158, + 158, 158, 158, 158, 158, 158, 158, 158, 158, 158, + 158, 158, 158, 158, 158, 158, 158, 158, 158, 158, + 158, 158, 158, 158, 158, 158, 158, 158, 158, 158, + 158, 158, 158, 158, 158 + }, + + { + 37, -159, -159, -159, -159, -159, -159, -159, -159, -159, + -159, -159, -159, -159, -159, -159, -159, -159, -159, -159, + -159, -159, -159, -159, -159, -159, -159, -159, -159, -159, + -159, -159, -159, -159, -159, -159, -159, -159, -159, -159, + -159, -159, -159, -159, -159 + + }, + + { + 37, -160, -160, -160, -160, -160, -160, 159, -160, -160, + -160, -160, -160, -160, -160, -160, -160, -160, -160, 212, + 212, -160, -160, -160, 212, 212, 212, 212, 212, 212, + 212, 212, 212, 212, 212, -160, -160, 212, 212, 212, + 212, 212, 212, 212, -160 + }, + + { + 37, -161, 161, 161, 161, -161, -161, -161, -161, -161, + -161, -161, -161, -161, -161, -161, 162, -161, -161, -161, + -161, -161, -161, -161, -161, -161, -161, -161, -161, -161, + -161, -161, -161, 163, -161, -161, -161, -161, -161, -161, + -161, -161, 163, -161, -161 + + }, + + { + 37, -162, -162, -162, -162, -162, -162, -162, -162, -162, + -162, -162, -162, -162, -162, -162, 213, -162, -162, -162, + -162, -162, -162, -162, -162, -162, -162, -162, -162, -162, + -162, -162, -162, -162, -162, -162, -162, -162, -162, -162, + -162, -162, -162, -162, -162 + }, + + { + 37, -163, -163, -163, -163, -163, -163, -163, -163, -163, + -163, -163, -163, -163, -163, -163, -163, -163, -163, -163, + -163, -163, -163, -163, -163, -163, -163, -163, 214, -163, + -163, -163, -163, -163, -163, -163, -163, -163, -163, -163, + -163, -163, -163, -163, -163 + + }, + + { + 37, -164, 164, 165, 165, -164, -164, -164, -164, -164, + -164, -164, -164, -164, -164, -164, 166, -164, -164, -164, + -164, -164, -164, -164, -164, -164, -164, -164, -164, -164, + -164, -164, -164, 167, -164, -164, -164, -164, -164, -164, + -164, -164, 167, -164, -164 + }, + + { + 37, -165, 215, 215, 215, -165, -165, -165, -165, -165, + 205, -165, -165, -165, -165, -165, 216, -165, -165, -165, + -165, -165, -165, -165, -165, -165, -165, -165, -165, -165, + -165, -165, -165, 167, -165, -165, -165, -165, -165, -165, + -165, -165, 167, -165, -165 + + }, + + { + 37, -166, -166, -166, -166, -166, -166, -166, -166, -166, + -166, -166, -166, -166, -166, -166, 217, -166, -166, -166, + -166, -166, -166, -166, -166, -166, -166, -166, -166, -166, + -166, -166, -166, -166, -166, -166, -166, -166, -166, -166, + -166, -166, -166, -166, -166 + }, + + { + 37, -167, -167, -167, -167, -167, -167, -167, -167, -167, + -167, -167, -167, -167, -167, -167, -167, -167, -167, -167, + -167, -167, -167, -167, -167, -167, -167, -167, 218, -167, + -167, -167, -167, -167, -167, -167, -167, -167, -167, -167, + -167, -167, -167, -167, -167 + + }, + + { + 37, -168, 168, 168, 168, -168, -168, -168, -168, -168, + -168, -168, -168, -168, -168, -168, -168, -168, -168, -168, + -168, -168, -168, -168, -168, -168, -168, -168, -168, -168, + -168, -168, -168, -168, -168, -168, -168, -168, -168, -168, + -168, -168, -168, -168, -168 + }, + + { + 37, -169, -169, -169, -169, -169, -169, -169, -169, -169, + -169, -169, -169, -169, -169, -169, -169, -169, -169, 219, + 219, -169, -169, -169, 219, 219, 219, 219, 219, 219, + 219, 219, 219, 219, 219, -169, -169, 219, 219, 219, + 219, 219, 219, 219, -169 + + }, + + { + 37, -170, -170, -170, -170, -170, -170, -170, -170, -170, + -170, -170, -170, -170, -170, -170, -170, -170, -170, 220, + 220, -170, -170, -170, 220, 220, 220, 220, 220, 220, + 220, 220, 220, 220, 220, -170, -170, 220, 220, 220, + 220, 220, 220, 220, -170 + }, + + { + 37, -171, -171, -171, -171, -171, -171, -171, -171, -171, + -171, -171, -171, -171, -171, -171, -171, -171, -171, 171, + 171, -171, -171, -171, 171, 171, 171, 171, 171, 171, + 171, 171, 171, 171, 171, -171, -171, 171, 171, 171, + 171, 171, 171, 171, -171 + + }, + + { + 37, -172, -172, -172, -172, -172, -172, -172, -172, -172, + -172, -172, -172, -172, -172, -172, -172, -172, -172, -172, + -172, -172, -172, -172, -172, -172, -172, -172, -172, -172, + -172, -172, -172, -172, -172, -172, -172, -172, -172, -172, + -172, -172, -172, -172, -172 + }, + + { + 37, -173, -173, -173, -173, -173, -173, -173, -173, -173, + -173, -173, -173, -173, -173, -173, -173, -173, -173, -173, + -173, -173, -173, -173, -173, -173, -173, -173, -173, -173, + -173, -173, -173, -173, -173, -173, -173, -173, -173, -173, + -173, -173, -173, -173, -173 + + }, + + { + 37, -174, -174, -174, -174, -174, -174, -174, -174, -174, + -174, -174, -174, -174, -174, -174, -174, -174, -174, 221, + -174, -174, -174, -174, -174, -174, -174, -174, -174, -174, + -174, -174, -174, -174, -174, -174, -174, -174, -174, -174, + -174, -174, -174, -174, -174 + }, + + { + 37, -175, -175, -175, -175, -175, -175, -175, -175, -175, + -175, -175, -175, -175, -175, -175, -175, -175, -175, -175, + -175, -175, -175, -175, -175, -175, -175, -175, -175, -175, + -175, -175, -175, -175, -175, -175, -175, -175, -175, -175, + -175, -175, -175, -175, -175 + + }, + + { + 37, -176, -176, -176, -176, -176, -176, -176, -176, -176, + -176, -176, -176, -176, -176, -176, -176, -176, -176, -176, + -176, -176, -176, -176, -176, -176, -176, -176, -176, -176, + -176, -176, -176, -176, -176, -176, -176, -176, -176, -176, + -176, -176, -176, -176, -176 + }, + + { + 37, -177, -177, -177, -177, -177, -177, -177, -177, -177, + -177, -177, -177, -177, -177, -177, -177, -177, -177, -177, + -177, -177, -177, -177, -177, -177, -177, -177, -177, -177, + -177, -177, -177, -177, -177, -177, -177, -177, -177, -177, + -177, -177, -177, -177, -177 + + }, + + { + 37, -178, -178, -178, -178, -178, -178, -178, -178, -178, + -178, -178, -178, -178, -178, -178, -178, -178, -178, -178, + -178, -178, -178, -178, -178, -178, -178, -178, -178, -178, + -178, -178, -178, -178, -178, -178, -178, -178, -178, -178, + -178, -178, -178, -178, -178 + }, + + { + 37, -179, -179, -179, -179, -179, -179, -179, -179, -179, + -179, -179, -179, -179, -179, -179, -179, -179, -179, -179, + -179, -179, -179, -179, -179, -179, -179, -179, -179, -179, + -179, -179, -179, -179, -179, -179, -179, -179, -179, -179, + -179, -179, -179, -179, -179 + + }, + + { + 37, -180, -180, -180, -180, -180, -180, -180, -180, -180, + -180, -180, -180, -180, -180, -180, -180, -180, -180, 222, + 222, -180, -180, -180, 222, 222, 222, 222, 222, -180, + -180, -180, -180, -180, -180, -180, -180, 222, 222, -180, + -180, -180, -180, -180, -180 + }, + + { + 37, -181, 181, 181, 181, -181, -181, -181, -181, -181, + -181, -181, -181, -181, -181, -181, -181, -181, -181, -181, + -181, -181, -181, -181, -181, -181, -181, -181, -181, -181, + -181, -181, -181, -181, -181, -181, -181, -181, -181, -181, + -181, -181, -181, -181, -181 + + }, + + { + 37, -182, -182, -182, -182, -182, -182, -182, -182, -182, + -182, -182, -182, -182, -182, -182, -182, -182, -182, -182, + -182, -182, -182, -182, -182, -182, -182, -182, -182, -182, + -182, -182, -182, -182, -182, -182, -182, -182, -182, -182, + -182, -182, -182, -182, -182 + }, + + { + 37, -183, -183, -183, -183, -183, -183, 111, -183, -183, + -183, -183, -183, -183, -183, -183, -183, -183, -183, 183, + 183, -183, -183, -183, 183, 183, 183, 183, 183, 183, + 183, 183, 183, 183, 183, -183, -183, 183, 183, 183, + 183, 183, 183, 183, -183 + + }, + + { + 37, 184, 184, -184, -184, 184, 184, 184, 184, 184, + 184, 184, 184, 184, 184, 184, 184, 184, 184, 184, + 184, 184, 184, 184, 184, 184, 184, 184, 184, 184, + 184, 184, 184, 184, 184, 184, 184, 184, 184, 184, + 184, 184, 184, 184, 184 + }, + + { + 37, 184, 184, -185, -185, 185, 184, 184, 185, 185, + 184, 184, 184, 185, 185, 184, 185, 184, 185, 184, + 184, 184, 184, 185, 184, 184, 184, 184, 184, 184, + 184, 184, 184, 184, 184, 184, 185, 184, 184, 184, + 184, 184, 184, 184, 185 + + }, + + { + 37, -186, -186, -186, -186, 186, -186, -186, 186, 186, + -186, -186, -186, 186, 186, -186, 186, -186, 186, -186, + -186, -186, -186, 186, -186, -186, -186, -186, -186, -186, + -186, -186, -186, -186, -186, -186, 186, -186, -186, -186, + -186, -186, -186, -186, 186 + }, + + { + 37, -187, -187, -187, -187, -187, -187, -187, -187, -187, + -187, -187, -187, -187, -187, -187, -187, -187, -187, -187, + -187, -187, -187, -187, -187, -187, -187, -187, -187, -187, + -187, -187, -187, -187, -187, -187, -187, -187, -187, -187, + -187, -187, -187, -187, -187 + + }, + + { + 37, -188, -188, -188, -188, -188, -188, -188, -188, -188, + -188, -188, -188, -188, -188, -188, -188, -188, -188, 188, + 188, -188, -188, -188, -188, -188, -188, -188, 120, -188, + -188, -188, -188, -188, -188, -188, -188, -188, -188, -188, + -188, -188, -188, -188, -188 + }, + + { + 37, -189, -189, -189, -189, -189, -189, -189, -189, -189, + -189, -189, -189, -189, -189, -189, -189, -189, -189, 190, + 190, -189, -189, -189, -189, -189, -189, -189, -189, -189, + -189, -189, -189, -189, -189, -189, -189, -189, -189, -189, + -189, -189, -189, -189, -189 + + }, + + { + 37, -190, -190, -190, -190, -190, -190, -190, -190, -190, + -190, -190, -190, -190, -190, -190, -190, -190, -190, 190, + 190, -190, -190, -190, -190, -190, -190, -190, -190, -190, + -190, -190, -190, -190, -190, -190, -190, -190, -190, -190, + -190, -190, -190, -190, -190 + }, + + { + 37, -191, -191, -191, -191, -191, 223, -191, -191, -191, + -191, -191, -191, -191, -191, -191, -191, -191, -191, 191, + 191, -191, -191, -191, 191, 191, 191, 191, 191, 191, + 191, 191, 191, 191, 191, -191, -191, 191, 191, 191, + 191, 191, 191, 191, -191 + + }, + + { + 37, -192, -192, -192, -192, -192, -192, -192, -192, -192, + 224, -192, -192, -192, -192, -192, -192, -192, -192, 192, + 192, -192, -192, -192, 192, 192, 192, 192, 192, 192, + 192, 192, 192, 192, 192, -192, -192, 192, 192, 192, + 192, 192, 192, 192, -192 + }, + + { + 37, -193, -193, -193, -193, -193, -193, -193, -193, -193, + -193, -193, -193, -193, -193, -193, -193, -193, -193, -193, + -193, -193, -193, -193, -193, -193, -193, -193, -193, -193, + -193, -193, -193, -193, -193, -193, -193, -193, -193, -193, + -193, -193, -193, -193, -193 + + }, + + { + 37, -194, -194, -194, -194, -194, -194, -194, -194, -194, + -194, -194, -194, -194, -194, -194, -194, -194, -194, -194, + -194, -194, -194, -194, -194, -194, -194, -194, -194, -194, + -194, -194, -194, -194, -194, -194, -194, -194, -194, -194, + -194, -194, -194, -194, -194 + }, + + { + 37, -195, 195, 195, 195, -195, -195, -195, -195, -195, + 196, -195, -195, -195, -195, -195, 197, -195, -195, -195, + -195, -195, -195, -195, -195, -195, -195, -195, -195, -195, + -195, -195, -195, -195, -195, -195, -195, -195, -195, -195, + -195, -195, -195, -195, -195 + + }, + + { + 37, -196, -196, -196, -196, -196, -196, -196, -196, -196, + -196, -196, -196, -196, -196, -196, -196, -196, -196, -196, + -196, -196, -196, -196, -196, -196, -196, -196, -196, -196, + -196, -196, -196, -196, -196, -196, -196, -196, -196, -196, + -196, -196, -196, -196, -196 + }, + + { + 37, -197, -197, -197, -197, -197, -197, -197, -197, -197, + -197, -197, -197, -197, -197, -197, 225, -197, -197, -197, + -197, -197, -197, -197, -197, -197, -197, -197, -197, -197, + -197, -197, -197, -197, -197, -197, -197, -197, -197, -197, + -197, -197, -197, -197, -197 + + }, + + { + 37, 226, 227, 135, 135, 226, 226, 226, 226, 226, + 226, 226, 226, 226, 226, 226, 228, 226, 226, 226, + 226, 226, 226, 226, 226, 226, 226, 226, 226, 226, + 226, 226, 226, 226, 226, 226, 226, 226, 226, 226, + 226, 226, 226, 226, 226 + }, + + { + 37, -199, -199, -199, -199, 199, -199, -199, 199, 199, + -199, -199, -199, 199, 199, -199, 199, -199, 199, -199, + -199, -199, -199, 199, -199, -199, -199, -199, -199, -199, + -199, -199, -199, -199, -199, -199, 199, -199, -199, -199, + -199, -199, -199, -199, 199 + + }, + + { + 37, -200, 200, 200, 200, -200, -200, -200, -200, -200, + 201, -200, -200, -200, -200, -200, 202, -200, -200, -200, + -200, -200, -200, -200, -200, -200, -200, -200, -200, -200, + -200, -200, -200, -200, -200, -200, -200, -200, -200, -200, + -200, -200, -200, -200, -200 + }, + + { + 37, -201, -201, -201, -201, -201, -201, -201, -201, -201, + -201, -201, -201, -201, -201, -201, -201, -201, -201, -201, + -201, -201, -201, -201, -201, -201, -201, -201, -201, -201, + -201, -201, -201, -201, -201, -201, -201, -201, -201, -201, + -201, -201, -201, -201, -201 + + }, + + { + 37, -202, -202, -202, -202, -202, -202, -202, -202, -202, + -202, -202, -202, -202, -202, -202, 229, -202, -202, -202, + -202, -202, -202, -202, -202, -202, -202, -202, -202, -202, + -202, -202, -202, -202, -202, -202, -202, -202, -202, -202, + -202, -202, -202, -202, -202 + }, + + { + 37, 230, 231, 145, 145, 230, 230, 230, 230, 230, + 230, 230, 230, 230, 230, 230, 232, 230, 230, 230, + 230, 230, 230, 230, 230, 230, 230, 230, 230, 230, + 230, 230, 230, 230, 230, 230, 230, 230, 230, 230, + 230, 230, 230, 230, 230 + + }, + + { + 37, -204, 204, 204, 204, -204, -204, -204, -204, -204, + 205, -204, -204, -204, -204, -204, 206, -204, -204, -204, + -204, -204, -204, -204, -204, -204, -204, -204, -204, -204, + -204, -204, -204, -204, -204, -204, -204, -204, -204, -204, + -204, -204, -204, -204, -204 + }, + + { + 37, -205, -205, -205, -205, -205, -205, -205, -205, -205, + -205, -205, -205, -205, -205, -205, -205, -205, -205, -205, + -205, -205, -205, -205, -205, -205, -205, -205, -205, -205, + -205, -205, -205, -205, -205, -205, -205, -205, -205, -205, + -205, -205, -205, -205, -205 + + }, + + { + 37, -206, -206, -206, -206, -206, -206, -206, -206, -206, + -206, -206, -206, -206, -206, -206, 233, -206, -206, -206, + -206, -206, -206, -206, -206, -206, -206, -206, -206, -206, + -206, -206, -206, -206, -206, -206, -206, -206, -206, -206, + -206, -206, -206, -206, -206 + }, + + { + 37, 234, 235, 149, 149, 234, 234, 234, 234, 234, + 234, 234, 234, 234, 234, 234, 236, 234, 234, 234, + 234, 234, 234, 234, 234, 234, 234, 234, 234, 234, + 234, 234, 234, 234, 234, 234, 234, 234, 234, 234, + 234, 234, 234, 234, 234 + + }, + + { + 37, -208, -208, -208, -208, -208, -208, -208, -208, -208, + -208, -208, -208, -208, -208, -208, -208, -208, -208, 237, + -208, -208, -208, -208, -208, -208, -208, -208, -208, -208, + -208, -208, -208, -208, -208, -208, -208, -208, -208, -208, + -208, -208, -208, -208, -208 + }, + + { + 37, -209, -209, -209, -209, -209, -209, -209, -209, -209, + -209, -209, -209, -209, -209, -209, -209, -209, -209, 238, + 238, -209, -209, -209, 238, 238, 238, 238, 238, -209, + -209, -209, -209, -209, -209, -209, -209, 238, 238, -209, + -209, -209, -209, -209, -209 + + }, + + { + 37, -210, -210, -210, -210, -210, -210, -210, -210, -210, + -210, -210, -210, -210, -210, -210, -210, -210, -210, 239, + 239, -210, -210, -210, 239, 239, 239, 239, 239, -210, + -210, -210, -210, -210, -210, -210, -210, 239, 239, -210, + -210, -210, -210, -210, -210 + }, + + { + 37, -211, -211, -211, -211, -211, -211, -211, -211, -211, + -211, -211, -211, -211, -211, -211, -211, -211, -211, 240, + 240, -211, -211, -211, 240, 240, 240, 240, 240, -211, + -211, -211, -211, -211, -211, -211, -211, 240, 240, -211, + -211, -211, -211, -211, -211 + + }, + + { + 37, -212, -212, -212, -212, -212, -212, 159, -212, -212, + -212, -212, -212, -212, -212, -212, -212, -212, -212, 212, + 212, -212, -212, -212, 212, 212, 212, 212, 212, 212, + 212, 212, 212, 212, 212, -212, -212, 212, 212, 212, + 212, 212, 212, 212, -212 + }, + + { + 37, 241, 242, 161, 161, 241, 241, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 243, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 241, 241, 241, 241, + 241, 241, 241, 244, 241, 241, 241, 241, 241, 241, + 241, 241, 244, 241, 241 + + }, + + { + 37, -214, -214, -214, -214, -214, -214, -214, -214, -214, + -214, -214, -214, -214, -214, -214, -214, -214, -214, -214, + -214, -214, -214, -214, -214, -214, -214, -214, -214, -214, + -214, -214, 245, -214, -214, -214, -214, -214, -214, -214, + -214, -214, -214, -214, -214 + }, + + { + 37, -215, 215, 215, 215, -215, -215, -215, -215, -215, + 205, -215, -215, -215, -215, -215, 216, -215, -215, -215, + -215, -215, -215, -215, -215, -215, -215, -215, -215, -215, + -215, -215, -215, 167, -215, -215, -215, -215, -215, -215, + -215, -215, 167, -215, -215 + + }, + + { + 37, -216, -216, -216, -216, -216, -216, -216, -216, -216, + -216, -216, -216, -216, -216, -216, 246, -216, -216, -216, + -216, -216, -216, -216, -216, -216, -216, -216, -216, -216, + -216, -216, -216, -216, -216, -216, -216, -216, -216, -216, + -216, -216, -216, -216, -216 + }, + + { + 37, 247, 248, 165, 165, 247, 247, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 249, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 247, 247, 247, 247, + 247, 247, 247, 250, 247, 247, 247, 247, 247, 247, + 247, 247, 250, 247, 247 + + }, + + { + 37, -218, -218, -218, -218, -218, -218, -218, -218, -218, + -218, -218, -218, -218, -218, -218, -218, -218, -218, -218, + -218, -218, -218, -218, -218, -218, -218, -218, -218, -218, + -218, -218, 251, -218, -218, -218, -218, -218, -218, -218, + -218, -218, -218, -218, -218 + }, + + { + 37, -219, -219, -219, -219, -219, 252, -219, -219, -219, + -219, -219, -219, -219, -219, -219, -219, -219, -219, 219, + 219, -219, -219, -219, 219, 219, 219, 219, 219, 219, + 219, 219, 219, 219, 219, -219, -219, 219, 219, 219, + 219, 219, 219, 219, -219 + + }, + + { + 37, -220, -220, -220, -220, -220, -220, -220, -220, -220, + 253, -220, -220, -220, -220, -220, -220, -220, -220, 220, + 220, -220, -220, -220, 220, 220, 220, 220, 220, 220, + 220, 220, 220, 220, 220, -220, -220, 220, 220, 220, + 220, 220, 220, 220, -220 + }, + + { + 37, -221, -221, -221, -221, -221, -221, -221, -221, -221, + -221, -221, -221, -221, -221, -221, -221, -221, -221, 254, + -221, -221, -221, -221, -221, -221, -221, -221, -221, -221, + -221, -221, -221, -221, -221, -221, -221, -221, -221, -221, + -221, -221, -221, -221, -221 + + }, + + { + 37, -222, -222, -222, -222, -222, -222, -222, -222, -222, + -222, -222, -222, -222, -222, -222, -222, -222, -222, 255, + 255, -222, -222, -222, 255, 255, 255, 255, 255, -222, + -222, -222, -222, -222, -222, -222, -222, 255, 255, -222, + -222, -222, -222, -222, -222 + }, + + { + 37, -223, -223, -223, -223, -223, -223, -223, -223, -223, + -223, -223, -223, -223, -223, -223, -223, -223, -223, -223, + -223, -223, -223, -223, -223, -223, -223, -223, -223, -223, + -223, -223, -223, -223, -223, -223, -223, -223, -223, -223, + -223, -223, -223, -223, -223 + + }, + + { + 37, -224, -224, -224, -224, -224, -224, -224, -224, -224, + -224, -224, -224, -224, -224, -224, -224, -224, -224, -224, + -224, -224, -224, -224, -224, -224, -224, -224, -224, -224, + -224, -224, -224, -224, -224, -224, -224, -224, -224, -224, + -224, -224, -224, -224, -224 + }, + + { + 37, 256, 257, 258, 258, 256, 256, 256, 256, 256, + 256, 256, 256, 256, 256, 256, 259, 256, 256, 256, + 256, 256, 256, 256, 256, 256, 256, 256, 256, 256, + 256, 256, 256, 256, 256, 256, 256, 256, 256, 256, + 256, 256, 256, 256, 256 + + }, + + { + 37, 226, 227, 135, 135, 226, 226, 226, 226, 226, + 226, 226, 226, 226, 226, 226, 228, 226, 226, 226, + 226, 226, 226, 226, 226, 226, 226, 226, 226, 226, + 226, 226, 226, 226, 226, 226, 226, 226, 226, 226, + 226, 226, 226, 226, 226 + }, + + { + 37, 226, 227, 135, 135, 226, 226, 226, 226, 226, + 226, 226, 226, 226, 226, 226, 228, 226, 226, 226, + 226, 226, 226, 226, 226, 226, 226, 226, 226, 226, + 226, 226, 226, 226, 226, 226, 226, 226, 226, 226, + 226, 226, 226, 226, 226 + + }, + + { + 37, 226, 227, 135, 135, 226, 226, 226, 226, 226, + 226, 226, 226, 226, 226, 226, 260, 226, 226, 226, + 226, 226, 226, 226, 226, 226, 226, 226, 226, 226, + 226, 226, 226, 226, 226, 226, 226, 226, 226, 226, + 226, 226, 226, 226, 226 + }, + + { + 37, 261, 262, 263, 263, 261, 261, 261, 261, 261, + 261, 261, 261, 261, 261, 261, 264, 261, 261, 261, + 261, 261, 261, 261, 261, 261, 261, 261, 261, 261, + 261, 261, 261, 261, 261, 261, 261, 261, 261, 261, + 261, 261, 261, 261, 261 + + }, + + { + 37, 230, 231, 145, 145, 230, 230, 230, 230, 230, + 230, 230, 230, 230, 230, 230, 232, 230, 230, 230, + 230, 230, 230, 230, 230, 230, 230, 230, 230, 230, + 230, 230, 230, 230, 230, 230, 230, 230, 230, 230, + 230, 230, 230, 230, 230 + }, + + { + 37, 230, 231, 145, 145, 230, 230, 230, 230, 230, + 230, 230, 230, 230, 230, 230, 232, 230, 230, 230, + 230, 230, 230, 230, 230, 230, 230, 230, 230, 230, + 230, 230, 230, 230, 230, 230, 230, 230, 230, 230, + 230, 230, 230, 230, 230 + + }, + + { + 37, 230, 231, 145, 145, 230, 230, 230, 230, 230, + 230, 230, 230, 230, 230, 230, 265, 230, 230, 230, + 230, 230, 230, 230, 230, 230, 230, 230, 230, 230, + 230, 230, 230, 230, 230, 230, 230, 230, 230, 230, + 230, 230, 230, 230, 230 + }, + + { + 37, 266, 267, 268, 268, 266, 266, 266, 266, 266, + 266, 266, 266, 266, 266, 266, 269, 266, 266, 266, + 266, 266, 266, 266, 266, 266, 266, 266, 266, 266, + 266, 266, 266, 266, 266, 266, 266, 266, 266, 266, + 266, 266, 266, 266, 266 + + }, + + { + 37, 234, 235, 149, 149, 234, 234, 234, 234, 234, + 234, 234, 234, 234, 234, 234, 236, 234, 234, 234, + 234, 234, 234, 234, 234, 234, 234, 234, 234, 234, + 234, 234, 234, 234, 234, 234, 234, 234, 234, 234, + 234, 234, 234, 234, 234 + }, + + { + 37, 234, 235, 149, 149, 234, 234, 234, 234, 234, + 234, 234, 234, 234, 234, 234, 236, 234, 234, 234, + 234, 234, 234, 234, 234, 234, 234, 234, 234, 234, + 234, 234, 234, 234, 234, 234, 234, 234, 234, 234, + 234, 234, 234, 234, 234 + + }, + + { + 37, 234, 235, 149, 149, 234, 234, 234, 234, 234, + 234, 234, 234, 234, 234, 234, 270, 234, 234, 234, + 234, 234, 234, 234, 234, 234, 234, 234, 234, 234, + 234, 234, 234, 234, 234, 234, 234, 234, 234, 234, + 234, 234, 234, 234, 234 + }, + + { + 37, -237, -237, -237, -237, -237, -237, -237, -237, -237, + -237, -237, -237, -237, -237, -237, -237, -237, -237, -237, + -237, -237, -237, -237, -237, -237, -237, -237, -237, -237, + -237, -237, -237, -237, -237, -237, -237, -237, -237, -237, + -237, -237, -237, -237, -237 + + }, + + { + 37, -238, -238, -238, -238, -238, -238, -238, -238, -238, + -238, -238, -238, -238, -238, -238, -238, -238, -238, 271, + 271, -238, -238, -238, 271, 271, 271, 271, 271, -238, + -238, -238, -238, -238, -238, -238, -238, 271, 271, -238, + -238, -238, -238, -238, -238 + }, + + { + 37, -239, -239, -239, -239, -239, -239, -239, -239, -239, + -239, -239, -239, -239, -239, -239, -239, -239, -239, 272, + 272, -239, -239, -239, 272, 272, 272, 272, 272, -239, + -239, -239, -239, -239, -239, -239, -239, 272, 272, -239, + -239, -239, -239, -239, -239 + + }, + + { + 37, -240, -240, -240, -240, -240, -240, -240, -240, -240, + -240, -240, -240, -240, -240, -240, -240, -240, -240, -240, + -240, -240, -240, -240, -240, -240, -240, -240, -240, -240, + -240, -240, -240, -240, -240, -240, -240, -240, -240, -240, + -240, -240, -240, -240, -240 + }, + + { + 37, 241, 242, 161, 161, 241, 241, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 243, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 241, 241, 241, 241, + 241, 241, 241, 244, 241, 241, 241, 241, 241, 241, + 241, 241, 244, 241, 241 + + }, + + { + 37, 241, 242, 161, 161, 241, 241, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 243, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 241, 241, 241, 241, + 241, 241, 241, 244, 241, 241, 241, 241, 241, 241, + 241, 241, 244, 241, 241 + }, + + { + 37, 241, 242, 161, 161, 241, 241, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 273, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 241, 241, 241, 241, + 241, 241, 241, 244, 241, 241, 241, 241, 241, 241, + 241, 241, 244, 241, 241 + + }, + + { + 37, 241, 242, 161, 161, 241, 241, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 243, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 241, 241, 274, 241, + 241, 241, 241, 244, 241, 241, 241, 241, 241, 241, + 241, 241, 244, 241, 241 + }, + + { + 37, -245, -245, -245, -245, -245, -245, -245, -245, -245, + -245, -245, -245, -245, -245, -245, -245, -245, -245, -245, + -245, -245, -245, -245, -245, -245, 275, -245, -245, -245, + -245, -245, -245, -245, -245, -245, -245, -245, -245, -245, + -245, -245, -245, -245, -245 + + }, + + { + 37, 276, 277, 278, 278, 276, 276, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 279, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 276, 276, 276, 276, + 276, 276, 276, 280, 276, 276, 276, 276, 276, 276, + 276, 276, 280, 276, 276 + }, + + { + 37, 247, 248, 165, 165, 247, 247, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 249, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 247, 247, 247, 247, + 247, 247, 247, 250, 247, 247, 247, 247, 247, 247, + 247, 247, 250, 247, 247 + + }, + + { + 37, 247, 248, 165, 165, 247, 247, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 249, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 247, 247, 247, 247, + 247, 247, 247, 250, 247, 247, 247, 247, 247, 247, + 247, 247, 250, 247, 247 + }, + + { + 37, 247, 248, 165, 165, 247, 247, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 281, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 247, 247, 247, 247, + 247, 247, 247, 250, 247, 247, 247, 247, 247, 247, + 247, 247, 250, 247, 247 + + }, + + { + 37, 247, 248, 165, 165, 247, 247, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 249, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 247, 247, 282, 247, + 247, 247, 247, 250, 247, 247, 247, 247, 247, 247, + 247, 247, 250, 247, 247 + }, + + { + 37, -251, -251, -251, -251, -251, -251, -251, -251, -251, + -251, -251, -251, -251, -251, -251, -251, -251, -251, -251, + -251, -251, -251, -251, -251, -251, 283, -251, -251, -251, + -251, -251, -251, -251, -251, -251, -251, -251, -251, -251, + -251, -251, -251, -251, -251 + + }, + + { + 37, -252, -252, -252, -252, -252, -252, -252, -252, -252, + -252, -252, -252, -252, -252, -252, -252, -252, -252, -252, + -252, -252, -252, -252, -252, -252, -252, -252, -252, -252, + -252, -252, -252, -252, -252, -252, -252, -252, -252, -252, + -252, -252, -252, -252, -252 + }, + + { + 37, -253, -253, -253, -253, -253, -253, -253, -253, -253, + -253, -253, -253, -253, -253, -253, -253, -253, -253, -253, + -253, -253, -253, -253, -253, -253, -253, -253, -253, -253, + -253, -253, -253, -253, -253, -253, -253, -253, -253, -253, + -253, -253, -253, -253, -253 + + }, + + { + 37, -254, -254, -254, -254, -254, -254, -254, -254, -254, + -254, -254, -254, -254, -254, -254, -254, -254, -254, -254, + -254, -254, -254, -254, -254, -254, -254, -254, -254, -254, + -254, -254, -254, -254, -254, -254, -254, -254, -254, -254, + -254, -254, -254, -254, -254 + }, + + { + 37, -255, -255, -255, -255, -255, -255, -255, -255, -255, + -255, -255, -255, -255, -255, -255, -255, -255, -255, -255, + -255, -255, -255, -255, -255, -255, -255, -255, -255, -255, + -255, -255, -255, -255, -255, -255, -255, -255, -255, -255, + -255, -255, -255, -255, -255 + + }, + + { + 37, 256, 257, 258, 258, 256, 256, 256, 256, 256, + 256, 256, 256, 256, 256, 256, 259, 256, 256, 256, + 256, 256, 256, 256, 256, 256, 256, 256, 256, 256, + 256, 256, 256, 256, 256, 256, 256, 256, 256, 256, + 256, 256, 256, 256, 256 + }, + + { + 37, 256, 257, 258, 258, 256, 256, 256, 256, 256, + 256, 256, 256, 256, 256, 256, 259, 256, 256, 256, + 256, 256, 256, 256, 256, 256, 256, 256, 256, 256, + 256, 256, 256, 256, 256, 256, 256, 256, 256, 256, + 256, 256, 256, 256, 256 + + }, + + { + 37, -258, 195, 195, 195, -258, -258, -258, -258, -258, + 196, -258, -258, -258, -258, -258, 197, -258, -258, -258, + -258, -258, -258, -258, -258, -258, -258, -258, -258, -258, + -258, -258, -258, -258, -258, -258, -258, -258, -258, -258, + -258, -258, -258, -258, -258 + }, + + { + 37, 256, 257, 258, 258, 256, 256, 256, 256, 256, + 256, 256, 256, 256, 256, 256, 284, 256, 256, 256, + 256, 256, 256, 256, 256, 256, 256, 256, 256, 256, + 256, 256, 256, 256, 256, 256, 256, 256, 256, 256, + 256, 256, 256, 256, 256 + + }, + + { + 37, 226, 227, 135, 135, 226, 226, 226, 226, 226, + 226, 226, 226, 226, 226, 226, 260, 226, 226, 226, + 226, 226, 226, 226, 226, 226, 226, 226, 226, 226, + 226, 226, 226, 226, 226, 226, 226, 226, 226, 226, + 226, 226, 226, 226, 226 + }, + + { + 37, 261, 262, 263, 263, 261, 261, 261, 261, 261, + 261, 261, 261, 261, 261, 261, 264, 261, 261, 261, + 261, 261, 261, 261, 261, 261, 261, 261, 261, 261, + 261, 261, 261, 261, 261, 261, 261, 261, 261, 261, + 261, 261, 261, 261, 261 + + }, + + { + 37, 261, 262, 263, 263, 261, 261, 261, 261, 261, + 261, 261, 261, 261, 261, 261, 264, 261, 261, 261, + 261, 261, 261, 261, 261, 261, 261, 261, 261, 261, + 261, 261, 261, 261, 261, 261, 261, 261, 261, 261, + 261, 261, 261, 261, 261 + }, + + { + 37, -263, 200, 200, 200, -263, -263, -263, -263, -263, + 201, -263, -263, -263, -263, -263, 202, -263, -263, -263, + -263, -263, -263, -263, -263, -263, -263, -263, -263, -263, + -263, -263, -263, -263, -263, -263, -263, -263, -263, -263, + -263, -263, -263, -263, -263 + + }, + + { + 37, 261, 262, 263, 263, 261, 261, 261, 261, 261, + 261, 261, 261, 261, 261, 261, 285, 261, 261, 261, + 261, 261, 261, 261, 261, 261, 261, 261, 261, 261, + 261, 261, 261, 261, 261, 261, 261, 261, 261, 261, + 261, 261, 261, 261, 261 + }, + + { + 37, 230, 231, 145, 145, 230, 230, 230, 230, 230, + 230, 230, 230, 230, 230, 230, 265, 230, 230, 230, + 230, 230, 230, 230, 230, 230, 230, 230, 230, 230, + 230, 230, 230, 230, 230, 230, 230, 230, 230, 230, + 230, 230, 230, 230, 230 + + }, + + { + 37, 266, 267, 268, 268, 266, 266, 266, 266, 266, + 266, 266, 266, 266, 266, 266, 269, 266, 266, 266, + 266, 266, 266, 266, 266, 266, 266, 266, 266, 266, + 266, 266, 266, 266, 266, 266, 266, 266, 266, 266, + 266, 266, 266, 266, 266 + }, + + { + 37, 266, 267, 268, 268, 266, 266, 266, 266, 266, + 266, 266, 266, 266, 266, 266, 269, 266, 266, 266, + 266, 266, 266, 266, 266, 266, 266, 266, 266, 266, + 266, 266, 266, 266, 266, 266, 266, 266, 266, 266, + 266, 266, 266, 266, 266 + + }, + + { + 37, -268, 204, 204, 204, -268, -268, -268, -268, -268, + 205, -268, -268, -268, -268, -268, 206, -268, -268, -268, + -268, -268, -268, -268, -268, -268, -268, -268, -268, -268, + -268, -268, -268, -268, -268, -268, -268, -268, -268, -268, + -268, -268, -268, -268, -268 + }, + + { + 37, 266, 267, 268, 268, 266, 266, 266, 266, 266, + 266, 266, 266, 266, 266, 266, 286, 266, 266, 266, + 266, 266, 266, 266, 266, 266, 266, 266, 266, 266, + 266, 266, 266, 266, 266, 266, 266, 266, 266, 266, + 266, 266, 266, 266, 266 + + }, + + { + 37, 234, 235, 149, 149, 234, 234, 234, 234, 234, + 234, 234, 234, 234, 234, 234, 270, 234, 234, 234, + 234, 234, 234, 234, 234, 234, 234, 234, 234, 234, + 234, 234, 234, 234, 234, 234, 234, 234, 234, 234, + 234, 234, 234, 234, 234 + }, + + { + 37, -271, -271, -271, -271, -271, -271, -271, -271, -271, + -271, -271, -271, -271, -271, -271, -271, -271, -271, 287, + 287, -271, -271, -271, 287, 287, 287, 287, 287, -271, + -271, -271, -271, -271, -271, -271, -271, 287, 287, -271, + -271, -271, -271, -271, -271 + + }, + + { + 37, -272, -272, -272, -272, -272, -272, -272, -272, -272, + -272, -272, -272, -272, -272, -272, -272, -272, -272, 288, + 288, -272, -272, -272, 288, 288, 288, 288, 288, -272, + -272, -272, -272, -272, -272, -272, -272, 288, 288, -272, + -272, -272, -272, -272, -272 + }, + + { + 37, 241, 242, 161, 161, 241, 241, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 273, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 241, 241, 241, 241, + 241, 241, 241, 244, 241, 241, 241, 241, 241, 241, + 241, 241, 244, 241, 241 + + }, + + { + 37, 241, 242, 161, 161, 241, 241, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 243, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 241, 241, 241, 241, + 241, 241, 289, 244, 241, 241, 241, 241, 241, 241, + 241, 241, 244, 241, 241 + }, + + { + 37, -275, -275, -275, -275, -275, -275, -275, -275, -275, + -275, -275, -275, -275, -275, -275, -275, -275, -275, -275, + -275, -275, -275, -275, 290, -275, -275, -275, -275, -275, + -275, -275, -275, -275, -275, -275, -275, -275, -275, -275, + -275, -275, -275, -275, -275 + + }, + + { + 37, 276, 277, 278, 278, 276, 276, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 279, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 276, 276, 276, 276, + 276, 276, 276, 280, 276, 276, 276, 276, 276, 276, + 276, 276, 280, 276, 276 + }, + + { + 37, 276, 277, 278, 278, 276, 276, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 279, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 276, 276, 276, 276, + 276, 276, 276, 280, 276, 276, 276, 276, 276, 276, + 276, 276, 280, 276, 276 + + }, + + { + 37, -278, 215, 215, 215, -278, -278, -278, -278, -278, + 205, -278, -278, -278, -278, -278, 216, -278, -278, -278, + -278, -278, -278, -278, -278, -278, -278, -278, -278, -278, + -278, -278, -278, 167, -278, -278, -278, -278, -278, -278, + -278, -278, 167, -278, -278 + }, + + { + 37, 276, 277, 278, 278, 276, 276, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 291, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 276, 276, 276, 276, + 276, 276, 276, 280, 276, 276, 276, 276, 276, 276, + 276, 276, 280, 276, 276 + + }, + + { + 37, 276, 277, 278, 278, 276, 276, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 279, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 276, 276, 292, 276, + 276, 276, 276, 280, 276, 276, 276, 276, 276, 276, + 276, 276, 280, 276, 276 + }, + + { + 37, 247, 248, 165, 165, 247, 247, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 281, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 247, 247, 247, 247, + 247, 247, 247, 250, 247, 247, 247, 247, 247, 247, + 247, 247, 250, 247, 247 + + }, + + { + 37, 247, 248, 165, 165, 247, 247, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 249, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 247, 247, 247, 247, + 247, 247, 293, 250, 247, 247, 247, 247, 247, 247, + 247, 247, 250, 247, 247 + }, + + { + 37, -283, -283, -283, -283, -283, -283, -283, -283, -283, + -283, -283, -283, -283, -283, -283, -283, -283, -283, -283, + -283, -283, -283, -283, 294, -283, -283, -283, -283, -283, + -283, -283, -283, -283, -283, -283, -283, -283, -283, -283, + -283, -283, -283, -283, -283 + + }, + + { + 37, 256, 257, 258, 258, 256, 256, 256, 256, 256, + 256, 256, 256, 256, 256, 256, 284, 256, 256, 256, + 256, 256, 256, 256, 256, 256, 256, 256, 256, 256, + 256, 256, 256, 256, 256, 256, 256, 256, 256, 256, + 256, 256, 256, 256, 256 + }, + + { + 37, 261, 262, 263, 263, 261, 261, 261, 261, 261, + 261, 261, 261, 261, 261, 261, 285, 261, 261, 261, + 261, 261, 261, 261, 261, 261, 261, 261, 261, 261, + 261, 261, 261, 261, 261, 261, 261, 261, 261, 261, + 261, 261, 261, 261, 261 + + }, + + { + 37, 266, 267, 268, 268, 266, 266, 266, 266, 266, + 266, 266, 266, 266, 266, 266, 286, 266, 266, 266, + 266, 266, 266, 266, 266, 266, 266, 266, 266, 266, + 266, 266, 266, 266, 266, 266, 266, 266, 266, 266, + 266, 266, 266, 266, 266 + }, + + { + 37, -287, -287, -287, -287, -287, -287, -287, -287, -287, + -287, -287, -287, -287, -287, -287, -287, -287, -287, 295, + 295, -287, -287, -287, 295, 295, 295, 295, 295, -287, + -287, -287, -287, -287, -287, -287, -287, 295, 295, -287, + -287, -287, -287, -287, -287 + + }, + + { + 37, -288, -288, -288, -288, -288, -288, -288, -288, -288, + -288, -288, -288, -288, -288, -288, -288, -288, -288, -288, + -288, -288, -288, -288, -288, -288, -288, -288, -288, -288, + -288, -288, -288, -288, -288, -288, -288, -288, -288, -288, + -288, -288, -288, -288, -288 + }, + + { + 37, 241, 242, 161, 161, 241, 241, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 243, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 296, 241, 241, 241, + 241, 241, 241, 244, 241, 241, 241, 241, 241, 241, + 241, 241, 244, 241, 241 + + }, + + { + 37, -290, -290, -290, -290, -290, -290, -290, -290, -290, + -290, -290, -290, -290, -290, -290, -290, -290, -290, -290, + -290, -290, -290, -290, -290, -290, -290, -290, -290, -290, + -290, 297, -290, -290, -290, -290, -290, -290, -290, -290, + -290, -290, -290, -290, -290 + }, + + { + 37, 276, 277, 278, 278, 276, 276, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 291, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 276, 276, 276, 276, + 276, 276, 276, 280, 276, 276, 276, 276, 276, 276, + 276, 276, 280, 276, 276 + + }, + + { + 37, 276, 277, 278, 278, 276, 276, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 279, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 276, 276, 276, 276, + 276, 276, 298, 280, 276, 276, 276, 276, 276, 276, + 276, 276, 280, 276, 276 + }, + + { + 37, 247, 248, 165, 165, 247, 247, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 249, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 299, 247, 247, 247, + 247, 247, 247, 250, 247, 247, 247, 247, 247, 247, + 247, 247, 250, 247, 247 + + }, + + { + 37, -294, -294, -294, -294, -294, -294, -294, -294, -294, + -294, -294, -294, -294, -294, -294, -294, -294, -294, -294, + -294, -294, -294, -294, -294, -294, -294, -294, -294, -294, + -294, 300, -294, -294, -294, -294, -294, -294, -294, -294, + -294, -294, -294, -294, -294 + }, + + { + 37, -295, -295, -295, -295, -295, -295, -295, -295, -295, + -295, -295, -295, -295, -295, -295, -295, -295, -295, 301, + 301, -295, -295, -295, 301, 301, 301, 301, 301, -295, + -295, -295, -295, -295, -295, -295, -295, 301, 301, -295, + -295, -295, -295, -295, -295 + + }, + + { + 37, 241, 242, 161, 161, 241, 241, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 243, 241, 241, 241, + 241, 241, 241, 241, 302, 241, 241, 241, 241, 241, + 241, 241, 241, 244, 241, 241, 241, 241, 241, 241, + 241, 241, 244, 241, 241 + }, + + { + 37, -297, -297, -297, -297, -297, -297, -297, -297, -297, + -297, -297, -297, -297, -297, -297, -297, -297, -297, -297, + -297, -297, -297, -297, -297, -297, -297, -297, 303, -297, + -297, -297, -297, -297, -297, -297, -297, -297, -297, -297, + -297, -297, -297, -297, -297 + + }, + + { + 37, 276, 277, 278, 278, 276, 276, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 279, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 304, 276, 276, 276, + 276, 276, 276, 280, 276, 276, 276, 276, 276, 276, + 276, 276, 280, 276, 276 + }, + + { + 37, 247, 248, 165, 165, 247, 247, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 249, 247, 247, 247, + 247, 247, 247, 247, 305, 247, 247, 247, 247, 247, + 247, 247, 247, 250, 247, 247, 247, 247, 247, 247, + 247, 247, 250, 247, 247 + + }, + + { + 37, -300, -300, -300, -300, -300, -300, -300, -300, -300, + -300, -300, -300, -300, -300, -300, -300, -300, -300, -300, + -300, -300, -300, -300, -300, -300, -300, -300, 306, -300, + -300, -300, -300, -300, -300, -300, -300, -300, -300, -300, + -300, -300, -300, -300, -300 + }, + + { + 37, -301, -301, -301, -301, -301, -301, -301, -301, -301, + -301, -301, -301, -301, -301, -301, -301, -301, -301, 307, + 307, -301, -301, -301, 307, 307, 307, 307, 307, -301, + -301, -301, -301, -301, -301, -301, -301, 307, 307, -301, + -301, -301, -301, -301, -301 + + }, + + { + 37, 241, 242, 161, 161, 241, 241, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 243, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 241, 241, 241, 241, + 241, 308, 241, 244, 241, 241, 241, 241, 241, 241, + 241, 241, 244, 241, 241 + }, + + { + 37, -303, 309, 309, 309, -303, -303, -303, -303, -303, + 310, -303, -303, -303, -303, -303, 311, -303, -303, -303, + -303, -303, -303, -303, -303, -303, -303, -303, -303, -303, + -303, -303, -303, -303, -303, -303, -303, -303, -303, -303, + -303, -303, -303, -303, -303 + + }, + + { + 37, 276, 277, 278, 278, 276, 276, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 279, 276, 276, 276, + 276, 276, 276, 276, 312, 276, 276, 276, 276, 276, + 276, 276, 276, 280, 276, 276, 276, 276, 276, 276, + 276, 276, 280, 276, 276 + }, + + { + 37, 247, 248, 165, 165, 247, 247, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 249, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 247, 247, 247, 247, + 247, 313, 247, 250, 247, 247, 247, 247, 247, 247, + 247, 247, 250, 247, 247 + + }, + + { + 37, -306, 314, 314, 314, -306, -306, -306, -306, -306, + 315, -306, -306, -306, -306, -306, 316, -306, -306, -306, + -306, -306, -306, -306, -306, -306, -306, -306, -306, -306, + -306, -306, -306, -306, -306, -306, -306, -306, -306, -306, + -306, -306, -306, -306, -306 + }, + + { + 37, -307, -307, -307, -307, -307, -307, -307, -307, -307, + -307, -307, -307, -307, -307, -307, -307, -307, -307, 288, + 288, -307, -307, -307, 288, 288, 288, 288, 288, -307, + -307, -307, -307, -307, -307, -307, -307, 288, 288, -307, + -307, -307, -307, -307, -307 + + }, + + { + 37, 241, 242, 161, 161, 241, 241, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 243, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 241, 241, 317, 241, + 241, 241, 241, 244, 241, 241, 241, 241, 241, 241, + 241, 241, 244, 241, 241 + }, + + { + 37, -309, 309, 309, 309, -309, -309, -309, -309, -309, + 310, -309, -309, -309, -309, -309, 311, -309, -309, -309, + -309, -309, -309, -309, -309, -309, -309, -309, -309, -309, + -309, -309, -309, -309, -309, -309, -309, -309, -309, -309, + -309, -309, -309, -309, -309 + + }, + + { + 37, 318, 318, 318, 318, 318, 318, 318, 318, 318, + -310, 318, 318, 318, 318, 318, 318, 318, 318, 318, + 318, 318, 318, 318, 318, 318, 318, 318, 318, 318, + 318, 318, 318, 318, 318, 318, 318, 318, 318, 318, + 318, 318, 318, 318, 318 + }, + + { + 37, -311, -311, -311, -311, -311, -311, -311, -311, -311, + -311, -311, -311, -311, -311, -311, 319, -311, -311, -311, + -311, -311, -311, -311, -311, -311, -311, -311, -311, -311, + -311, -311, -311, -311, -311, -311, -311, -311, -311, -311, + -311, -311, -311, -311, -311 + + }, + + { + 37, 276, 277, 278, 278, 276, 276, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 279, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 276, 276, 276, 276, + 276, 320, 276, 280, 276, 276, 276, 276, 276, 276, + 276, 276, 280, 276, 276 + }, + + { + 37, 247, 248, 165, 165, 247, 247, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 249, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 247, 247, 321, 247, + 247, 247, 247, 250, 247, 247, 247, 247, 247, 247, + 247, 247, 250, 247, 247 + + }, + + { + 37, -314, 314, 314, 314, -314, -314, -314, -314, -314, + 315, -314, -314, -314, -314, -314, 316, -314, -314, -314, + -314, -314, -314, -314, -314, -314, -314, -314, -314, -314, + -314, -314, -314, -314, -314, -314, -314, -314, -314, -314, + -314, -314, -314, -314, -314 + }, + + { + 37, 322, 322, 322, 322, 322, 322, 322, 322, 322, + -315, 322, 322, 322, 322, 322, 322, 322, 322, 322, + 322, 322, 322, 322, 322, 322, 322, 322, 322, 322, + 322, 322, 322, 322, 322, 322, 322, 322, 322, 322, + 322, 322, 322, 322, 322 + + }, + + { + 37, -316, -316, -316, -316, -316, -316, -316, -316, -316, + -316, -316, -316, -316, -316, -316, 323, -316, -316, -316, + -316, -316, -316, -316, -316, -316, -316, -316, -316, -316, + -316, -316, -316, -316, -316, -316, -316, -316, -316, -316, + -316, -316, -316, -316, -316 + }, + + { + 37, 241, 324, 325, 325, 241, 241, 241, 241, 241, + 326, 241, 241, 241, 241, 241, 327, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 241, 241, 241, 241, + 241, 241, 241, 244, 241, 241, 241, 241, 241, 241, + 241, 241, 244, 241, 241 + + }, + + { + 37, -318, -318, -318, -318, -318, -318, -318, -318, -318, + 328, -318, -318, -318, -318, -318, -318, -318, -318, -318, + -318, -318, -318, -318, -318, -318, -318, -318, -318, -318, + -318, -318, -318, -318, -318, -318, -318, -318, -318, -318, + -318, -318, -318, -318, -318 + }, + + { + 37, 329, 330, 309, 309, 329, 329, 329, 329, 329, + 331, 329, 329, 329, 329, 329, 332, 329, 329, 329, + 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, + 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, + 329, 329, 329, 329, 329 + + }, + + { + 37, 276, 277, 278, 278, 276, 276, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 279, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 276, 276, 333, 276, + 276, 276, 276, 280, 276, 276, 276, 276, 276, 276, + 276, 276, 280, 276, 276 + }, + + { + 37, 247, 334, 335, 335, 247, 247, 247, 247, 247, + 336, 247, 247, 247, 247, 247, 337, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 247, 247, 247, 247, + 247, 247, 247, 250, 247, 247, 247, 247, 247, 247, + 247, 247, 250, 247, 247 + + }, + + { + 37, -322, -322, -322, -322, -322, -322, -322, -322, -322, + 338, -322, -322, -322, -322, -322, -322, -322, -322, -322, + -322, -322, -322, -322, -322, -322, -322, -322, -322, -322, + -322, -322, -322, -322, -322, -322, -322, -322, -322, -322, + -322, -322, -322, -322, -322 + }, + + { + 37, 339, 340, 314, 314, 339, 339, 339, 339, 339, + 341, 339, 339, 339, 339, 339, 342, 339, 339, 339, + 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, + 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, + 339, 339, 339, 339, 339 + + }, + + { + 37, 241, 324, 325, 325, 241, 241, 241, 241, 241, + 326, 241, 241, 241, 241, 241, 327, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 241, 241, 241, 241, + 241, 241, 241, 244, 241, 241, 241, 241, 241, 241, + 241, 241, 244, 241, 241 + }, + + { + 37, -325, 325, 325, 325, -325, -325, -325, -325, -325, + 310, -325, -325, -325, -325, -325, 343, -325, -325, -325, + -325, -325, -325, -325, -325, -325, -325, -325, -325, -325, + -325, -325, -325, 163, -325, -325, -325, -325, -325, -325, + -325, -325, 163, -325, -325 + + }, + + { + 37, 344, 345, 346, 346, 344, 344, 344, 344, 344, + 241, 344, 344, 344, 344, 344, 347, 344, 344, 344, + 344, 344, 344, 344, 344, 344, 344, 344, 344, 344, + 344, 344, 344, 348, 344, 344, 344, 344, 344, 344, + 344, 344, 348, 344, 344 + }, + + { + 37, 241, 242, 161, 161, 241, 241, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 349, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 241, 241, 241, 241, + 241, 241, 241, 244, 241, 241, 241, 241, 241, 241, + 241, 241, 244, 241, 241 + + }, + + { + 37, -328, -328, -328, -328, -328, -328, -328, -328, -328, + -328, -328, -328, -328, -328, -328, -328, -328, -328, -328, + -328, -328, -328, -328, -328, -328, -328, -328, -328, -328, + -328, -328, -328, -328, -328, -328, -328, -328, -328, -328, + -328, -328, -328, -328, -328 + }, + + { + 37, 329, 330, 309, 309, 329, 329, 329, 329, 329, + 331, 329, 329, 329, 329, 329, 332, 329, 329, 329, + 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, + 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, + 329, 329, 329, 329, 329 + + }, + + { + 37, 329, 330, 309, 309, 329, 329, 329, 329, 329, + 331, 329, 329, 329, 329, 329, 332, 329, 329, 329, + 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, + 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, + 329, 329, 329, 329, 329 + }, + + { + 37, 350, 351, 352, 352, 350, 350, 350, 350, 350, + 331, 350, 350, 350, 350, 350, 353, 350, 350, 350, + 350, 350, 350, 350, 350, 350, 350, 350, 350, 350, + 350, 350, 350, 350, 350, 350, 350, 350, 350, 350, + 350, 350, 350, 350, 350 + + }, + + { + 37, 329, 330, 309, 309, 329, 329, 329, 329, 329, + 331, 329, 329, 329, 329, 329, 354, 329, 329, 329, + 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, + 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, + 329, 329, 329, 329, 329 + }, + + { + 37, 276, 355, 356, 356, 276, 276, 276, 276, 276, + 357, 276, 276, 276, 276, 276, 358, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 276, 276, 276, 276, + 276, 276, 276, 280, 276, 276, 276, 276, 276, 276, + 276, 276, 280, 276, 276 + + }, + + { + 37, 247, 334, 335, 335, 247, 247, 247, 247, 247, + 336, 247, 247, 247, 247, 247, 337, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 247, 247, 247, 247, + 247, 247, 247, 250, 247, 247, 247, 247, 247, 247, + 247, 247, 250, 247, 247 + }, + + { + 37, -335, 359, 359, 359, -335, -335, -335, -335, -335, + 360, -335, -335, -335, -335, -335, 361, -335, -335, -335, + -335, -335, -335, -335, -335, -335, -335, -335, -335, -335, + -335, -335, -335, 167, -335, -335, -335, -335, -335, -335, + -335, -335, 167, -335, -335 + + }, + + { + 37, 362, 363, 364, 364, 362, 362, 362, 362, 362, + 247, 362, 362, 362, 362, 362, 365, 362, 362, 362, + 362, 362, 362, 362, 362, 362, 362, 362, 362, 362, + 362, 362, 362, 366, 362, 362, 362, 362, 362, 362, + 362, 362, 366, 362, 362 + }, + + { + 37, 247, 248, 165, 165, 247, 247, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 367, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 247, 247, 247, 247, + 247, 247, 247, 250, 247, 247, 247, 247, 247, 247, + 247, 247, 250, 247, 247 + + }, + + { + 37, -338, -338, -338, -338, -338, -338, -338, -338, -338, + -338, -338, -338, -338, -338, -338, -338, -338, -338, -338, + -338, -338, -338, -338, -338, -338, -338, -338, -338, -338, + -338, -338, -338, -338, -338, -338, -338, -338, -338, -338, + -338, -338, -338, -338, -338 + }, + + { + 37, 339, 340, 314, 314, 339, 339, 339, 339, 339, + 341, 339, 339, 339, 339, 339, 342, 339, 339, 339, + 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, + 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, + 339, 339, 339, 339, 339 + + }, + + { + 37, 339, 340, 314, 314, 339, 339, 339, 339, 339, + 341, 339, 339, 339, 339, 339, 342, 339, 339, 339, + 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, + 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, + 339, 339, 339, 339, 339 + }, + + { + 37, 368, 369, 370, 370, 368, 368, 368, 368, 368, + 341, 368, 368, 368, 368, 368, 371, 368, 368, 368, + 368, 368, 368, 368, 368, 368, 368, 368, 368, 368, + 368, 368, 368, 368, 368, 368, 368, 368, 368, 368, + 368, 368, 368, 368, 368 + + }, + + { + 37, 339, 340, 314, 314, 339, 339, 339, 339, 339, + 341, 339, 339, 339, 339, 339, 372, 339, 339, 339, + 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, + 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, + 339, 339, 339, 339, 339 + }, + + { + 37, -343, -343, -343, -343, -343, -343, -343, -343, -343, + -343, -343, -343, -343, -343, -343, 373, -343, -343, -343, + -343, -343, -343, -343, -343, -343, -343, -343, -343, -343, + -343, -343, -343, -343, -343, -343, -343, -343, -343, -343, + -343, -343, -343, -343, -343 + + }, + + { + 37, 241, 242, 161, 161, 241, 241, 241, 241, 241, + 374, 241, 241, 241, 241, 241, 243, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 241, 241, 241, 241, + 241, 241, 241, 244, 241, 241, 241, 241, 241, 241, + 241, 241, 244, 241, 241 + }, + + { + 37, 241, 242, 161, 161, 241, 241, 241, 241, 241, + 374, 241, 241, 241, 241, 241, 243, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 241, 241, 241, 241, + 241, 241, 241, 244, 241, 241, 241, 241, 241, 241, + 241, 241, 244, 241, 241 + + }, + + { + 37, -346, 161, 161, 161, -346, -346, -346, -346, -346, + 328, -346, -346, -346, -346, -346, 162, -346, -346, -346, + -346, -346, -346, -346, -346, -346, -346, -346, -346, -346, + -346, -346, -346, 163, -346, -346, -346, -346, -346, -346, + -346, -346, 163, -346, -346 + }, + + { + 37, 241, 242, 161, 161, 241, 241, 241, 241, 241, + 374, 241, 241, 241, 241, 241, 273, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 241, 241, 241, 241, + 241, 241, 241, 244, 241, 241, 241, 241, 241, 241, + 241, 241, 244, 241, 241 + + }, + + { + 37, 241, 242, 161, 161, 241, 241, 241, 241, 241, + 374, 241, 241, 241, 241, 241, 243, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 241, 241, 274, 241, + 241, 241, 241, 244, 241, 241, 241, 241, 241, 241, + 241, 241, 244, 241, 241 + }, + + { + 37, 375, 376, 325, 325, 375, 375, 375, 375, 375, + 377, 375, 375, 375, 375, 375, 378, 375, 375, 375, + 375, 375, 375, 375, 375, 375, 375, 375, 375, 375, + 375, 375, 375, 379, 375, 375, 375, 375, 375, 375, + 375, 375, 379, 375, 375 + + }, + + { + 37, 329, 330, 309, 309, 329, 329, 329, 329, 329, + 380, 329, 329, 329, 329, 329, 332, 329, 329, 329, + 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, + 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, + 329, 329, 329, 329, 329 + }, + + { + 37, 329, 330, 309, 309, 329, 329, 329, 329, 329, + 380, 329, 329, 329, 329, 329, 332, 329, 329, 329, + 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, + 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, + 329, 329, 329, 329, 329 + + }, + + { + 37, -352, 309, 309, 309, -352, -352, -352, -352, -352, + 381, -352, -352, -352, -352, -352, 311, -352, -352, -352, + -352, -352, -352, -352, -352, -352, -352, -352, -352, -352, + -352, -352, -352, -352, -352, -352, -352, -352, -352, -352, + -352, -352, -352, -352, -352 + }, + + { + 37, 329, 330, 309, 309, 329, 329, 329, 329, 329, + 380, 329, 329, 329, 329, 329, 354, 329, 329, 329, + 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, + 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, + 329, 329, 329, 329, 329 + + }, + + { + 37, 329, 330, 309, 309, 329, 329, 329, 329, 329, + 331, 329, 329, 329, 329, 329, 354, 329, 329, 329, + 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, + 329, 329, 329, 329, 329, 329, 329, 329, 329, 329, + 329, 329, 329, 329, 329 + }, + + { + 37, 276, 355, 356, 356, 276, 276, 276, 276, 276, + 357, 276, 276, 276, 276, 276, 358, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 276, 276, 276, 276, + 276, 276, 276, 280, 276, 276, 276, 276, 276, 276, + 276, 276, 280, 276, 276 + + }, + + { + 37, -356, 359, 359, 359, -356, -356, -356, -356, -356, + 360, -356, -356, -356, -356, -356, 361, -356, -356, -356, + -356, -356, -356, -356, -356, -356, -356, -356, -356, -356, + -356, -356, -356, 167, -356, -356, -356, -356, -356, -356, + -356, -356, 167, -356, -356 + }, + + { + 37, 382, 383, 384, 384, 382, 382, 382, 382, 382, + 276, 382, 382, 382, 382, 382, 385, 382, 382, 382, + 382, 382, 382, 382, 382, 382, 382, 382, 382, 382, + 382, 382, 382, 386, 382, 382, 382, 382, 382, 382, + 382, 382, 386, 382, 382 + + }, + + { + 37, 276, 277, 278, 278, 276, 276, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 387, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 276, 276, 276, 276, + 276, 276, 276, 280, 276, 276, 276, 276, 276, 276, + 276, 276, 280, 276, 276 + }, + + { + 37, -359, 359, 359, 359, -359, -359, -359, -359, -359, + 360, -359, -359, -359, -359, -359, 361, -359, -359, -359, + -359, -359, -359, -359, -359, -359, -359, -359, -359, -359, + -359, -359, -359, 167, -359, -359, -359, -359, -359, -359, + -359, -359, 167, -359, -359 + + }, + + { + 37, 322, 322, 322, 322, 322, 322, 322, 322, 322, + -360, 322, 322, 322, 322, 322, 322, 322, 322, 322, + 322, 322, 322, 322, 322, 322, 322, 322, 322, 322, + 322, 322, 322, 322, 322, 322, 322, 322, 322, 322, + 322, 322, 322, 322, 322 + }, + + { + 37, -361, -361, -361, -361, -361, -361, -361, -361, -361, + -361, -361, -361, -361, -361, -361, 388, -361, -361, -361, + -361, -361, -361, -361, -361, -361, -361, -361, -361, -361, + -361, -361, -361, -361, -361, -361, -361, -361, -361, -361, + -361, -361, -361, -361, -361 + + }, + + { + 37, 247, 248, 165, 165, 247, 247, 247, 247, 247, + 389, 247, 247, 247, 247, 247, 249, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 247, 247, 247, 247, + 247, 247, 247, 250, 247, 247, 247, 247, 247, 247, + 247, 247, 250, 247, 247 + }, + + { + 37, 247, 248, 165, 165, 247, 247, 247, 247, 247, + 389, 247, 247, 247, 247, 247, 249, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 247, 247, 247, 247, + 247, 247, 247, 250, 247, 247, 247, 247, 247, 247, + 247, 247, 250, 247, 247 + + }, + + { + 37, -364, 215, 215, 215, -364, -364, -364, -364, -364, + 390, -364, -364, -364, -364, -364, 216, -364, -364, -364, + -364, -364, -364, -364, -364, -364, -364, -364, -364, -364, + -364, -364, -364, 167, -364, -364, -364, -364, -364, -364, + -364, -364, 167, -364, -364 + }, + + { + 37, 247, 248, 165, 165, 247, 247, 247, 247, 247, + 389, 247, 247, 247, 247, 247, 281, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 247, 247, 247, 247, + 247, 247, 247, 250, 247, 247, 247, 247, 247, 247, + 247, 247, 250, 247, 247 + + }, + + { + 37, 247, 248, 165, 165, 247, 247, 247, 247, 247, + 389, 247, 247, 247, 247, 247, 249, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 247, 247, 282, 247, + 247, 247, 247, 250, 247, 247, 247, 247, 247, 247, + 247, 247, 250, 247, 247 + }, + + { + 37, 391, 392, 335, 335, 391, 391, 391, 391, 391, + 393, 391, 391, 391, 391, 391, 394, 391, 391, 391, + 391, 391, 391, 391, 391, 391, 391, 391, 391, 391, + 391, 391, 391, 395, 391, 391, 391, 391, 391, 391, + 391, 391, 395, 391, 391 + + }, + + { + 37, 339, 340, 314, 314, 339, 339, 339, 339, 339, + 396, 339, 339, 339, 339, 339, 342, 339, 339, 339, + 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, + 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, + 339, 339, 339, 339, 339 + }, + + { + 37, 339, 340, 314, 314, 339, 339, 339, 339, 339, + 396, 339, 339, 339, 339, 339, 342, 339, 339, 339, + 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, + 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, + 339, 339, 339, 339, 339 + + }, + + { + 37, -370, 314, 314, 314, -370, -370, -370, -370, -370, + 397, -370, -370, -370, -370, -370, 316, -370, -370, -370, + -370, -370, -370, -370, -370, -370, -370, -370, -370, -370, + -370, -370, -370, -370, -370, -370, -370, -370, -370, -370, + -370, -370, -370, -370, -370 + }, + + { + 37, 339, 340, 314, 314, 339, 339, 339, 339, 339, + 396, 339, 339, 339, 339, 339, 372, 339, 339, 339, + 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, + 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, + 339, 339, 339, 339, 339 + + }, + + { + 37, 339, 340, 314, 314, 339, 339, 339, 339, 339, + 341, 339, 339, 339, 339, 339, 372, 339, 339, 339, + 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, + 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, + 339, 339, 339, 339, 339 + }, + + { + 37, 375, 376, 325, 325, 375, 375, 375, 375, 375, + 377, 375, 375, 375, 375, 375, 398, 375, 375, 375, + 375, 375, 375, 375, 375, 375, 375, 375, 375, 375, + 375, 375, 375, 379, 375, 375, 375, 375, 375, 375, + 375, 375, 379, 375, 375 + + }, + + { + 37, 241, 242, 161, 161, 241, 241, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 243, 241, 241, 241, + 241, 241, 241, 241, 241, 241, 241, 241, 241, 241, + 241, 241, 241, 244, 241, 241, 241, 241, 241, 241, + 241, 241, 244, 241, 241 + }, + + { + 37, 375, 376, 325, 325, 375, 375, 375, 375, 375, + 377, 375, 375, 375, 375, 375, 398, 375, 375, 375, + 375, 375, 375, 375, 375, 375, 375, 375, 375, 375, + 375, 375, 375, 379, 375, 375, 375, 375, 375, 375, + 375, 375, 379, 375, 375 + + }, + + { + 37, 375, 376, 325, 325, 375, 375, 375, 375, 375, + 377, 375, 375, 375, 375, 375, 398, 375, 375, 375, + 375, 375, 375, 375, 375, 375, 375, 375, 375, 375, + 375, 375, 375, 379, 375, 375, 375, 375, 375, 375, + 375, 375, 379, 375, 375 + }, + + { + 37, 399, 400, 401, 401, 399, 399, 399, 399, 399, + 377, 399, 399, 399, 399, 399, 402, 399, 399, 399, + 399, 399, 399, 399, 399, 399, 399, 399, 399, 399, + 399, 399, 399, 403, 399, 399, 399, 399, 399, 399, + 399, 399, 403, 399, 399 + + }, + + { + 37, 375, 376, 325, 325, 375, 375, 375, 375, 375, + 377, 375, 375, 375, 375, 375, 404, 375, 375, 375, + 375, 375, 375, 375, 375, 375, 375, 375, 375, 375, + 375, 375, 375, 379, 375, 375, 375, 375, 375, 375, + 375, 375, 379, 375, 375 + }, + + { + 37, 375, 376, 325, 325, 375, 375, 375, 375, 375, + 377, 375, 375, 375, 375, 375, 398, 375, 375, 375, + 375, 375, 375, 375, 375, 375, 375, 375, 405, 375, + 375, 375, 375, 379, 375, 375, 375, 375, 375, 375, + 375, 375, 379, 375, 375 + + }, + + { + 37, 350, 351, 352, 352, 350, 350, 350, 350, 350, + 331, 350, 350, 350, 350, 350, 353, 350, 350, 350, + 350, 350, 350, 350, 350, 350, 350, 350, 350, 350, + 350, 350, 350, 350, 350, 350, 350, 350, 350, 350, + 350, 350, 350, 350, 350 + }, + + { + 37, 318, 318, 318, 318, 318, 318, 318, 318, 318, + -381, 318, 318, 318, 318, 318, 318, 318, 318, 318, + 318, 318, 318, 318, 318, 318, 318, 318, 318, 318, + 318, 318, 318, 318, 318, 318, 318, 318, 318, 318, + 318, 318, 318, 318, 318 + + }, + + { + 37, 276, 277, 278, 278, 276, 276, 276, 276, 276, + 406, 276, 276, 276, 276, 276, 279, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 276, 276, 276, 276, + 276, 276, 276, 280, 276, 276, 276, 276, 276, 276, + 276, 276, 280, 276, 276 + }, + + { + 37, 276, 277, 278, 278, 276, 276, 276, 276, 276, + 406, 276, 276, 276, 276, 276, 279, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 276, 276, 276, 276, + 276, 276, 276, 280, 276, 276, 276, 276, 276, 276, + 276, 276, 280, 276, 276 + + }, + + { + 37, -384, 215, 215, 215, -384, -384, -384, -384, -384, + 390, -384, -384, -384, -384, -384, 216, -384, -384, -384, + -384, -384, -384, -384, -384, -384, -384, -384, -384, -384, + -384, -384, -384, 167, -384, -384, -384, -384, -384, -384, + -384, -384, 167, -384, -384 + }, + + { + 37, 276, 277, 278, 278, 276, 276, 276, 276, 276, + 406, 276, 276, 276, 276, 276, 291, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 276, 276, 276, 276, + 276, 276, 276, 280, 276, 276, 276, 276, 276, 276, + 276, 276, 280, 276, 276 + + }, + + { + 37, 276, 277, 278, 278, 276, 276, 276, 276, 276, + 406, 276, 276, 276, 276, 276, 279, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 276, 276, 292, 276, + 276, 276, 276, 280, 276, 276, 276, 276, 276, 276, + 276, 276, 280, 276, 276 + }, + + { + 37, 407, 408, 356, 356, 407, 407, 407, 407, 407, + 409, 407, 407, 407, 407, 407, 410, 407, 407, 407, + 407, 407, 407, 407, 407, 407, 407, 407, 407, 407, + 407, 407, 407, 411, 407, 407, 407, 407, 407, 407, + 407, 407, 411, 407, 407 + + }, + + { + 37, 407, 408, 356, 356, 407, 407, 407, 407, 407, + 409, 407, 407, 407, 407, 407, 412, 407, 407, 407, + 407, 407, 407, 407, 407, 407, 407, 407, 407, 407, + 407, 407, 407, 411, 407, 407, 407, 407, 407, 407, + 407, 407, 411, 407, 407 + }, + + { + 37, 247, 248, 165, 165, 247, 247, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 249, 247, 247, 247, + 247, 247, 247, 247, 247, 247, 247, 247, 247, 247, + 247, 247, 247, 250, 247, 247, 247, 247, 247, 247, + 247, 247, 250, 247, 247 + + }, + + { + 37, -390, -390, -390, -390, -390, -390, -390, -390, -390, + -390, -390, -390, -390, -390, -390, -390, -390, -390, -390, + -390, -390, -390, -390, -390, -390, -390, -390, -390, -390, + -390, -390, -390, -390, -390, -390, -390, -390, -390, -390, + -390, -390, -390, -390, -390 + }, + + { + 37, 391, 392, 335, 335, 391, 391, 391, 391, 391, + 393, 391, 391, 391, 391, 391, 413, 391, 391, 391, + 391, 391, 391, 391, 391, 391, 391, 391, 391, 391, + 391, 391, 391, 395, 391, 391, 391, 391, 391, 391, + 391, 391, 395, 391, 391 + + }, + + { + 37, 391, 392, 335, 335, 391, 391, 391, 391, 391, + 393, 391, 391, 391, 391, 391, 413, 391, 391, 391, + 391, 391, 391, 391, 391, 391, 391, 391, 391, 391, + 391, 391, 391, 395, 391, 391, 391, 391, 391, 391, + 391, 391, 395, 391, 391 + }, + + { + 37, 414, 415, 416, 416, 414, 414, 414, 414, 414, + 393, 414, 414, 414, 414, 414, 417, 414, 414, 414, + 414, 414, 414, 414, 414, 414, 414, 414, 414, 414, + 414, 414, 414, 418, 414, 414, 414, 414, 414, 414, + 414, 414, 418, 414, 414 + + }, + + { + 37, 391, 392, 335, 335, 391, 391, 391, 391, 391, + 393, 391, 391, 391, 391, 391, 419, 391, 391, 391, + 391, 391, 391, 391, 391, 391, 391, 391, 391, 391, + 391, 391, 391, 395, 391, 391, 391, 391, 391, 391, + 391, 391, 395, 391, 391 + }, + + { + 37, 391, 392, 335, 335, 391, 391, 391, 391, 391, + 393, 391, 391, 391, 391, 391, 413, 391, 391, 391, + 391, 391, 391, 391, 391, 391, 391, 391, 420, 391, + 391, 391, 391, 395, 391, 391, 391, 391, 391, 391, + 391, 391, 395, 391, 391 + + }, + + { + 37, 368, 369, 370, 370, 368, 368, 368, 368, 368, + 341, 368, 368, 368, 368, 368, 371, 368, 368, 368, + 368, 368, 368, 368, 368, 368, 368, 368, 368, 368, + 368, 368, 368, 368, 368, 368, 368, 368, 368, 368, + 368, 368, 368, 368, 368 + }, + + { + 37, 322, 322, 322, 322, 322, 322, 322, 322, 322, + -397, 322, 322, 322, 322, 322, 322, 322, 322, 322, + 322, 322, 322, 322, 322, 322, 322, 322, 322, 322, + 322, 322, 322, 322, 322, 322, 322, 322, 322, 322, + 322, 322, 322, 322, 322 + + }, + + { + 37, 375, 376, 325, 325, 375, 375, 375, 375, 375, + 377, 375, 375, 375, 375, 375, 404, 375, 375, 375, + 375, 375, 375, 375, 375, 375, 375, 375, 375, 375, + 375, 375, 375, 379, 375, 375, 375, 375, 375, 375, + 375, 375, 379, 375, 375 + }, + + { + 37, 375, 376, 325, 325, 375, 375, 375, 375, 375, + 421, 375, 375, 375, 375, 375, 398, 375, 375, 375, + 375, 375, 375, 375, 375, 375, 375, 375, 375, 375, + 375, 375, 375, 379, 375, 375, 375, 375, 375, 375, + 375, 375, 379, 375, 375 + + }, + + { + 37, 375, 376, 325, 325, 375, 375, 375, 375, 375, + 421, 375, 375, 375, 375, 375, 398, 375, 375, 375, + 375, 375, 375, 375, 375, 375, 375, 375, 375, 375, + 375, 375, 375, 379, 375, 375, 375, 375, 375, 375, + 375, 375, 379, 375, 375 + }, + + { + 37, -401, 325, 325, 325, -401, -401, -401, -401, -401, + 381, -401, -401, -401, -401, -401, 343, -401, -401, -401, + -401, -401, -401, -401, -401, -401, -401, -401, -401, -401, + -401, -401, -401, 163, -401, -401, -401, -401, -401, -401, + -401, -401, 163, -401, -401 + + }, + + { + 37, 375, 376, 325, 325, 375, 375, 375, 375, 375, + 421, 375, 375, 375, 375, 375, 404, 375, 375, 375, + 375, 375, 375, 375, 375, 375, 375, 375, 375, 375, + 375, 375, 375, 379, 375, 375, 375, 375, 375, 375, + 375, 375, 379, 375, 375 + }, + + { + 37, 375, 376, 325, 325, 375, 375, 375, 375, 375, + 421, 375, 375, 375, 375, 375, 398, 375, 375, 375, + 375, 375, 375, 375, 375, 375, 375, 375, 405, 375, + 375, 375, 375, 379, 375, 375, 375, 375, 375, 375, + 375, 375, 379, 375, 375 + + }, + + { + 37, 375, 376, 325, 325, 375, 375, 375, 375, 375, + 377, 375, 375, 375, 375, 375, 404, 375, 375, 375, + 375, 375, 375, 375, 375, 375, 375, 375, 375, 375, + 375, 375, 375, 379, 375, 375, 375, 375, 375, 375, + 375, 375, 379, 375, 375 + }, + + { + 37, 375, 376, 325, 325, 375, 375, 375, 375, 375, + 377, 375, 375, 375, 375, 375, 398, 375, 375, 375, + 375, 375, 375, 375, 375, 375, 375, 375, 375, 375, + 375, 375, 422, 379, 375, 375, 375, 375, 375, 375, + 375, 375, 379, 375, 375 + + }, + + { + 37, 276, 277, 278, 278, 276, 276, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 279, 276, 276, 276, + 276, 276, 276, 276, 276, 276, 276, 276, 276, 276, + 276, 276, 276, 280, 276, 276, 276, 276, 276, 276, + 276, 276, 280, 276, 276 + }, + + { + 37, 407, 408, 356, 356, 407, 407, 407, 407, 407, + 409, 407, 407, 407, 407, 407, 412, 407, 407, 407, + 407, 407, 407, 407, 407, 407, 407, 407, 407, 407, + 407, 407, 407, 411, 407, 407, 407, 407, 407, 407, + 407, 407, 411, 407, 407 + + }, + + { + 37, 407, 408, 356, 356, 407, 407, 407, 407, 407, + 409, 407, 407, 407, 407, 407, 412, 407, 407, 407, + 407, 407, 407, 407, 407, 407, 407, 407, 407, 407, + 407, 407, 407, 411, 407, 407, 407, 407, 407, 407, + 407, 407, 411, 407, 407 + }, + + { + 37, 423, 424, 425, 425, 423, 423, 423, 423, 423, + 409, 423, 423, 423, 423, 423, 426, 423, 423, 423, + 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, + 423, 423, 423, 427, 423, 423, 423, 423, 423, 423, + 423, 423, 427, 423, 423 + + }, + + { + 37, 407, 408, 356, 356, 407, 407, 407, 407, 407, + 409, 407, 407, 407, 407, 407, 428, 407, 407, 407, + 407, 407, 407, 407, 407, 407, 407, 407, 407, 407, + 407, 407, 407, 411, 407, 407, 407, 407, 407, 407, + 407, 407, 411, 407, 407 + }, + + { + 37, 407, 408, 356, 356, 407, 407, 407, 407, 407, + 409, 407, 407, 407, 407, 407, 412, 407, 407, 407, + 407, 407, 407, 407, 407, 407, 407, 407, 429, 407, + 407, 407, 407, 411, 407, 407, 407, 407, 407, 407, + 407, 407, 411, 407, 407 + + }, + + { + 37, 407, 408, 356, 356, 407, 407, 407, 407, 407, + 409, 407, 407, 407, 407, 407, 428, 407, 407, 407, + 407, 407, 407, 407, 407, 407, 407, 407, 407, 407, + 407, 407, 407, 411, 407, 407, 407, 407, 407, 407, + 407, 407, 411, 407, 407 + }, + + { + 37, 391, 392, 335, 335, 391, 391, 391, 391, 391, + 393, 391, 391, 391, 391, 391, 419, 391, 391, 391, + 391, 391, 391, 391, 391, 391, 391, 391, 391, 391, + 391, 391, 391, 395, 391, 391, 391, 391, 391, 391, + 391, 391, 395, 391, 391 + + }, + + { + 37, 391, 392, 335, 335, 391, 391, 391, 391, 391, + 430, 391, 391, 391, 391, 391, 413, 391, 391, 391, + 391, 391, 391, 391, 391, 391, 391, 391, 391, 391, + 391, 391, 391, 395, 391, 391, 391, 391, 391, 391, + 391, 391, 395, 391, 391 + }, + + { + 37, 391, 392, 335, 335, 391, 391, 391, 391, 391, + 430, 391, 391, 391, 391, 391, 413, 391, 391, 391, + 391, 391, 391, 391, 391, 391, 391, 391, 391, 391, + 391, 391, 391, 395, 391, 391, 391, 391, 391, 391, + 391, 391, 395, 391, 391 + + }, + + { + 37, -416, 359, 359, 359, -416, -416, -416, -416, -416, + 431, -416, -416, -416, -416, -416, 361, -416, -416, -416, + -416, -416, -416, -416, -416, -416, -416, -416, -416, -416, + -416, -416, -416, 167, -416, -416, -416, -416, -416, -416, + -416, -416, 167, -416, -416 + }, + + { + 37, 391, 392, 335, 335, 391, 391, 391, 391, 391, + 430, 391, 391, 391, 391, 391, 419, 391, 391, 391, + 391, 391, 391, 391, 391, 391, 391, 391, 391, 391, + 391, 391, 391, 395, 391, 391, 391, 391, 391, 391, + 391, 391, 395, 391, 391 + + }, + + { + 37, 391, 392, 335, 335, 391, 391, 391, 391, 391, + 430, 391, 391, 391, 391, 391, 413, 391, 391, 391, + 391, 391, 391, 391, 391, 391, 391, 391, 420, 391, + 391, 391, 391, 395, 391, 391, 391, 391, 391, 391, + 391, 391, 395, 391, 391 + }, + + { + 37, 391, 392, 335, 335, 391, 391, 391, 391, 391, + 393, 391, 391, 391, 391, 391, 419, 391, 391, 391, + 391, 391, 391, 391, 391, 391, 391, 391, 391, 391, + 391, 391, 391, 395, 391, 391, 391, 391, 391, 391, + 391, 391, 395, 391, 391 + + }, + + { + 37, 391, 392, 335, 335, 391, 391, 391, 391, 391, + 393, 391, 391, 391, 391, 391, 413, 391, 391, 391, + 391, 391, 391, 391, 391, 391, 391, 391, 391, 391, + 391, 391, 432, 395, 391, 391, 391, 391, 391, 391, + 391, 391, 395, 391, 391 + }, + + { + 37, 399, 400, 401, 401, 399, 399, 399, 399, 399, + 377, 399, 399, 399, 399, 399, 402, 399, 399, 399, + 399, 399, 399, 399, 399, 399, 399, 399, 399, 399, + 399, 399, 399, 403, 399, 399, 399, 399, 399, 399, + 399, 399, 403, 399, 399 + + }, + + { + 37, 375, 376, 325, 325, 375, 375, 375, 375, 375, + 377, 375, 375, 375, 375, 375, 398, 375, 375, 375, + 375, 375, 375, 375, 375, 375, 433, 375, 375, 375, + 375, 375, 375, 379, 375, 375, 375, 375, 375, 375, + 375, 375, 379, 375, 375 + }, + + { + 37, 407, 408, 356, 356, 407, 407, 407, 407, 407, + 434, 407, 407, 407, 407, 407, 412, 407, 407, 407, + 407, 407, 407, 407, 407, 407, 407, 407, 407, 407, + 407, 407, 407, 411, 407, 407, 407, 407, 407, 407, + 407, 407, 411, 407, 407 + + }, + + { + 37, 407, 408, 356, 356, 407, 407, 407, 407, 407, + 434, 407, 407, 407, 407, 407, 412, 407, 407, 407, + 407, 407, 407, 407, 407, 407, 407, 407, 407, 407, + 407, 407, 407, 411, 407, 407, 407, 407, 407, 407, + 407, 407, 411, 407, 407 + }, + + { + 37, -425, 359, 359, 359, -425, -425, -425, -425, -425, + 431, -425, -425, -425, -425, -425, 361, -425, -425, -425, + -425, -425, -425, -425, -425, -425, -425, -425, -425, -425, + -425, -425, -425, 167, -425, -425, -425, -425, -425, -425, + -425, -425, 167, -425, -425 + + }, + + { + 37, 407, 408, 356, 356, 407, 407, 407, 407, 407, + 434, 407, 407, 407, 407, 407, 428, 407, 407, 407, + 407, 407, 407, 407, 407, 407, 407, 407, 407, 407, + 407, 407, 407, 411, 407, 407, 407, 407, 407, 407, + 407, 407, 411, 407, 407 + }, + + { + 37, 407, 408, 356, 356, 407, 407, 407, 407, 407, + 434, 407, 407, 407, 407, 407, 412, 407, 407, 407, + 407, 407, 407, 407, 407, 407, 407, 407, 429, 407, + 407, 407, 407, 411, 407, 407, 407, 407, 407, 407, + 407, 407, 411, 407, 407 + + }, + + { + 37, 407, 408, 356, 356, 407, 407, 407, 407, 407, + 409, 407, 407, 407, 407, 407, 428, 407, 407, 407, + 407, 407, 407, 407, 407, 407, 407, 407, 407, 407, + 407, 407, 407, 411, 407, 407, 407, 407, 407, 407, + 407, 407, 411, 407, 407 + }, + + { + 37, 407, 408, 356, 356, 407, 407, 407, 407, 407, + 409, 407, 407, 407, 407, 407, 412, 407, 407, 407, + 407, 407, 407, 407, 407, 407, 407, 407, 407, 407, + 407, 407, 435, 411, 407, 407, 407, 407, 407, 407, + 407, 407, 411, 407, 407 + + }, + + { + 37, 414, 415, 416, 416, 414, 414, 414, 414, 414, + 393, 414, 414, 414, 414, 414, 417, 414, 414, 414, + 414, 414, 414, 414, 414, 414, 414, 414, 414, 414, + 414, 414, 414, 418, 414, 414, 414, 414, 414, 414, + 414, 414, 418, 414, 414 + }, + + { + 37, 322, 322, 322, 322, 322, 322, 322, 322, 322, + -431, 322, 322, 322, 322, 322, 322, 322, 322, 322, + 322, 322, 322, 322, 322, 322, 322, 322, 322, 322, + 322, 322, 322, 322, 322, 322, 322, 322, 322, 322, + 322, 322, 322, 322, 322 + + }, + + { + 37, 391, 392, 335, 335, 391, 391, 391, 391, 391, + 393, 391, 391, 391, 391, 391, 413, 391, 391, 391, + 391, 391, 391, 391, 391, 391, 436, 391, 391, 391, + 391, 391, 391, 395, 391, 391, 391, 391, 391, 391, + 391, 391, 395, 391, 391 + }, + + { + 37, 375, 376, 325, 325, 375, 375, 375, 375, 375, + 377, 375, 375, 375, 375, 375, 398, 375, 375, 375, + 375, 375, 375, 375, 437, 375, 375, 375, 375, 375, + 375, 375, 375, 379, 375, 375, 375, 375, 375, 375, + 375, 375, 379, 375, 375 + + }, + + { + 37, 423, 424, 425, 425, 423, 423, 423, 423, 423, + 409, 423, 423, 423, 423, 423, 426, 423, 423, 423, + 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, + 423, 423, 423, 427, 423, 423, 423, 423, 423, 423, + 423, 423, 427, 423, 423 + }, + + { + 37, 407, 408, 356, 356, 407, 407, 407, 407, 407, + 409, 407, 407, 407, 407, 407, 412, 407, 407, 407, + 407, 407, 407, 407, 407, 407, 438, 407, 407, 407, + 407, 407, 407, 411, 407, 407, 407, 407, 407, 407, + 407, 407, 411, 407, 407 + + }, + + { + 37, 391, 392, 335, 335, 391, 391, 391, 391, 391, + 393, 391, 391, 391, 391, 391, 413, 391, 391, 391, + 391, 391, 391, 391, 439, 391, 391, 391, 391, 391, + 391, 391, 391, 395, 391, 391, 391, 391, 391, 391, + 391, 391, 395, 391, 391 + }, + + { + 37, 375, 376, 325, 325, 375, 375, 375, 375, 375, + 377, 375, 375, 375, 375, 375, 398, 375, 375, 375, + 375, 375, 375, 375, 375, 375, 375, 375, 375, 375, + 375, 440, 375, 379, 375, 375, 375, 375, 375, 375, + 375, 375, 379, 375, 375 + + }, + + { + 37, 407, 408, 356, 356, 407, 407, 407, 407, 407, + 409, 407, 407, 407, 407, 407, 412, 407, 407, 407, + 407, 407, 407, 407, 441, 407, 407, 407, 407, 407, + 407, 407, 407, 411, 407, 407, 407, 407, 407, 407, + 407, 407, 411, 407, 407 + }, + + { + 37, 391, 392, 335, 335, 391, 391, 391, 391, 391, + 393, 391, 391, 391, 391, 391, 413, 391, 391, 391, + 391, 391, 391, 391, 391, 391, 391, 391, 391, 391, + 391, 442, 391, 395, 391, 391, 391, 391, 391, 391, + 391, 391, 395, 391, 391 + + }, + + { + 37, 375, 376, 325, 325, 375, 375, 375, 375, 375, + 377, 375, 375, 375, 375, 375, 398, 375, 375, 375, + 375, 375, 375, 375, 375, 375, 375, 375, 443, 375, + 375, 375, 375, 379, 375, 375, 375, 375, 375, 375, + 375, 375, 379, 375, 375 + }, + + { + 37, 407, 408, 356, 356, 407, 407, 407, 407, 407, + 409, 407, 407, 407, 407, 407, 412, 407, 407, 407, + 407, 407, 407, 407, 407, 407, 407, 407, 407, 407, + 407, 444, 407, 411, 407, 407, 407, 407, 407, 407, + 407, 407, 411, 407, 407 + + }, + + { + 37, 391, 392, 335, 335, 391, 391, 391, 391, 391, + 393, 391, 391, 391, 391, 391, 413, 391, 391, 391, + 391, 391, 391, 391, 391, 391, 391, 391, 445, 391, + 391, 391, 391, 395, 391, 391, 391, 391, 391, 391, + 391, 391, 395, 391, 391 + }, + + { + 37, 375, 376, 325, 325, 375, 375, 375, 375, 375, + 377, 375, 375, 375, 375, 375, 398, 375, 375, 375, + 375, 375, 375, 375, 375, 375, 375, 375, 375, 375, + 375, 375, 375, 379, 375, 375, 375, 375, 375, 375, + 375, 375, 379, 375, 375 + + }, + + { + 37, 407, 408, 356, 356, 407, 407, 407, 407, 407, + 409, 407, 407, 407, 407, 407, 412, 407, 407, 407, + 407, 407, 407, 407, 407, 407, 407, 407, 446, 407, + 407, 407, 407, 411, 407, 407, 407, 407, 407, 407, + 407, 407, 411, 407, 407 + }, + + { + 37, 391, 392, 335, 335, 391, 391, 391, 391, 391, + 393, 391, 391, 391, 391, 391, 413, 391, 391, 391, + 391, 391, 391, 391, 391, 391, 391, 391, 391, 391, + 391, 391, 391, 395, 391, 391, 391, 391, 391, 391, + 391, 391, 395, 391, 391 + + }, + + { + 37, 407, 408, 356, 356, 407, 407, 407, 407, 407, + 409, 407, 407, 407, 407, 407, 412, 407, 407, 407, + 407, 407, 407, 407, 407, 407, 407, 407, 407, 407, + 407, 407, 407, 411, 407, 407, 407, 407, 407, 407, + 407, 407, 411, 407, 407 + }, + + } ; + +static yy_state_type yy_get_previous_state (void ); +static yy_state_type yy_try_NUL_trans (yy_state_type current_state ); +static int yy_get_next_buffer (void ); +static void yy_fatal_error (yyconst char msg[] ); + +/* Done after the current pattern has been matched and before the + * corresponding action - sets up yytext. + */ +#define YY_DO_BEFORE_ACTION \ + (yytext_ptr) = yy_bp; \ + yyleng = (size_t) (yy_cp - yy_bp); \ + (yy_hold_char) = *yy_cp; \ + *yy_cp = '\0'; \ + (yy_c_buf_p) = yy_cp; + +#define YY_NUM_RULES 108 +#define YY_END_OF_BUFFER 109 +/* This struct is not used in this scanner, + but its presence is necessary. */ +struct yy_trans_info + { + flex_int32_t yy_verify; + flex_int32_t yy_nxt; + }; +static yyconst flex_int16_t yy_accept[447] = + { 0, + 0, 0, 12, 12, 0, 0, 0, 0, 11, 11, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 109, 73, 1, 1, + 64, 42, 73, 63, 19, 53, 54, 63, 63, 63, + 63, 66, 63, 55, 72, 72, 72, 72, 72, 72, + 57, 12, 9, 5, 5, 6, 6, 48, 44, 11, + 16, 28, 28, 22, 35, 27, 22, 39, 39, 41, + 45, 24, 75, 74, 74, 78, 76, 76, 77, 88, + 79, 79, 82, 80, 88, 81, 99, 89, 99, 101, + + 100, 103, 102, 105, 104, 104, 107, 107, 1, 64, + 36, 65, 37, 1, 51, 67, 2, 67, 66, 70, + 62, 61, 58, 50, 52, 72, 8, 20, 18, 49, + 15, 56, 12, 9, 9, 10, 5, 7, 4, 3, + 48, 47, 11, 16, 16, 17, 28, 22, 22, 26, + 23, 31, 32, 30, 30, 31, 27, 39, 38, 40, + 45, 45, 45, 24, 24, 24, 24, 76, 87, 86, + 83, 90, 98, 96, 93, 95, 91, 94, 92, 98, + 104, 106, 37, 1, 1, 2, 68, 67, 71, 69, + 62, 61, 43, 21, 9, 14, 10, 9, 3, 16, + + 13, 17, 16, 22, 34, 23, 22, 32, 30, 30, + 33, 40, 45, 45, 24, 24, 24, 24, 87, 86, + 96, 97, 60, 59, 9, 9, 9, 9, 16, 16, + 16, 16, 22, 22, 22, 22, 32, 30, 30, 33, + 45, 45, 45, 45, 45, 24, 24, 24, 24, 24, + 24, 85, 84, 96, 97, 9, 9, 9, 9, 9, + 16, 16, 16, 16, 16, 22, 22, 22, 22, 22, + 30, 30, 45, 45, 45, 24, 24, 24, 24, 24, + 24, 24, 24, 9, 16, 22, 30, 29, 45, 45, + 24, 24, 24, 24, 30, 45, 45, 24, 24, 24, + + 30, 45, 45, 24, 24, 24, 30, 45, 45, 45, + 45, 24, 24, 24, 24, 24, 45, 45, 45, 24, + 24, 24, 24, 45, 45, 45, 45, 46, 45, 45, + 45, 45, 24, 24, 24, 24, 24, 25, 24, 24, + 24, 24, 45, 45, 45, 45, 45, 45, 45, 45, + 45, 45, 45, 45, 24, 24, 24, 24, 24, 24, + 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, + 24, 24, 45, 45, 45, 45, 45, 45, 45, 45, + 45, 24, 24, 24, 24, 24, 24, 24, 24, 25, + 24, 24, 24, 24, 24, 24, 24, 45, 45, 45, + + 45, 45, 45, 45, 45, 24, 24, 24, 24, 24, + 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, + 45, 45, 24, 24, 24, 24, 24, 24, 24, 24, + 24, 24, 45, 24, 24, 24, 45, 24, 24, 45, + 24, 24, 45, 24, 24, 24 + } ; + +static yyconst flex_int32_t yy_ec[256] = + { 0, + 1, 1, 1, 1, 1, 1, 1, 1, 2, 3, + 1, 2, 4, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 2, 5, 6, 5, 7, 8, 9, 10, 11, + 12, 13, 14, 15, 16, 17, 18, 19, 19, 19, + 19, 19, 19, 19, 19, 20, 20, 21, 22, 8, + 23, 8, 5, 5, 24, 25, 26, 27, 28, 27, + 29, 29, 29, 29, 29, 29, 29, 30, 29, 31, + 29, 29, 32, 29, 33, 29, 29, 34, 29, 29, + 15, 35, 15, 8, 29, 36, 24, 37, 26, 27, + + 28, 38, 29, 29, 29, 29, 29, 29, 29, 39, + 29, 31, 29, 40, 32, 41, 42, 29, 29, 43, + 29, 29, 1, 44, 1, 5, 1, 29, 29, 29, + 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, + 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, + 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, + 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, + 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, + 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, + 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, + + 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, + 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, + 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, + 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, + 29, 29, 29, 29, 29, 29, 29, 29, 29, 29, + 29, 29, 29, 29, 29 + } ; + +extern int yy_flex_debug; +int yy_flex_debug = 0; + +/* The intent behind this definition is that it'll catch + * any uses of REJECT which flex missed. + */ +#define REJECT reject_used_but_not_detected +#define yymore() yymore_used_but_not_detected +#define YY_MORE_ADJ 0 +#define YY_RESTORE_YY_MORE_OFFSET +char *yytext; +#line 1 "psqlscan.l" +#line 2 "psqlscan.l" +/*------------------------------------------------------------------------- + * + * psqlscan.l + * lexical scanner for psql + * + * This code is mainly needed to determine where the end of a SQL statement + * is: we are looking for semicolons that are not within quotes, comments, + * or parentheses. The most reliable way to handle this is to borrow the + * backend's flex lexer rules, lock, stock, and barrel. The rules below + * are (except for a few) the same as the backend's, but their actions are + * just ECHO whereas the backend's actions generally do other things. + * + * XXX The rules in this file must be kept in sync with the backend lexer!!! + * + * XXX Avoid creating backtracking cases --- see the backend lexer for info. + * + * The most difficult aspect of this code is that we need to work in multibyte + * encodings that are not ASCII-safe. A "safe" encoding is one in which each + * byte of a multibyte character has the high bit set (it's >= 0x80). Since + * all our lexing rules treat all high-bit-set characters alike, we don't + * really need to care whether such a byte is part of a sequence or not. + * In an "unsafe" encoding, we still expect the first byte of a multibyte + * sequence to be >= 0x80, but later bytes might not be. If we scan such + * a sequence as-is, the lexing rules could easily be fooled into matching + * such bytes to ordinary ASCII characters. Our solution for this is to + * substitute 0xFF for each non-first byte within the data presented to flex. + * The flex rules will then pass the FF's through unmolested. The emit() + * subroutine is responsible for looking back to the original string and + * replacing FF's with the corresponding original bytes. + * + * Portions Copyright (c) 1996-2012, PostgreSQL Global Development Group + * Portions Copyright (c) 1994, Regents of the University of California + * + * IDENTIFICATION + * src/bin/psql/psqlscan.l + * + *------------------------------------------------------------------------- + */ +#include "postgres_fe.h" + +#include "psqlscan.h" + +#include + +#include "common.h" +#include "settings.h" +#include "variables.h" + + +/* + * We use a stack of flex buffers to handle substitution of psql variables. + * Each stacked buffer contains the as-yet-unread text from one psql variable. + * When we pop the stack all the way, we resume reading from the outer buffer + * identified by scanbufhandle. + */ +typedef struct StackElem +{ + YY_BUFFER_STATE buf; /* flex input control structure */ + char *bufstring; /* data actually being scanned by flex */ + char *origstring; /* copy of original data, if needed */ + char *varname; /* name of variable providing data, or NULL */ + struct StackElem *next; +} StackElem; + +/* + * All working state of the lexer must be stored in PsqlScanStateData + * between calls. This allows us to have multiple open lexer operations, + * which is needed for nested include files. The lexer itself is not + * recursive, but it must be re-entrant. + */ +typedef struct PsqlScanStateData +{ + StackElem *buffer_stack; /* stack of variable expansion buffers */ + /* + * These variables always refer to the outer buffer, never to any + * stacked variable-expansion buffer. + */ + YY_BUFFER_STATE scanbufhandle; + char *scanbuf; /* start of outer-level input buffer */ + const char *scanline; /* current input line at outer level */ + + /* safe_encoding, curline, refline are used by emit() to replace FFs */ + int encoding; /* encoding being used now */ + bool safe_encoding; /* is current encoding "safe"? */ + const char *curline; /* actual flex input string for cur buf */ + const char *refline; /* original data for cur buffer */ + + /* + * All this state lives across successive input lines, until explicitly + * reset by psql_scan_reset. + */ + int start_state; /* saved YY_START */ + int paren_depth; /* depth of nesting in parentheses */ + int xcdepth; /* depth of nesting in slash-star comments */ + char *dolqstart; /* current $foo$ quote start string */ +} PsqlScanStateData; + +static PsqlScanState cur_state; /* current state while active */ + +static PQExpBuffer output_buf; /* current output buffer */ + +/* these variables do not need to be saved across calls */ +static enum slash_option_type option_type; +static char *option_quote; +static int unquoted_option_chars; +static int backtick_start_offset; + + +/* Return values from yylex() */ +#define LEXRES_EOL 0 /* end of input */ +#define LEXRES_SEMI 1 /* command-terminating semicolon found */ +#define LEXRES_BACKSLASH 2 /* backslash command start */ +#define LEXRES_OK 3 /* OK completion of backslash argument */ + + +int yylex(void); + +static void evaluate_backtick(void); +static void push_new_buffer(const char *newstr, const char *varname); +static void pop_buffer_stack(PsqlScanState state); +static bool var_is_current_source(PsqlScanState state, const char *varname); +static YY_BUFFER_STATE prepare_buffer(const char *txt, int len, + char **txtcopy); +static void emit(const char *txt, int len); +static char *extract_substring(const char *txt, int len); +static void escape_variable(bool as_ident); + +#define ECHO emit(yytext, yyleng) + +#define YY_NO_INPUT 1 +/* + * All of the following definitions and rules should exactly match + * src/backend/parser/scan.l so far as the flex patterns are concerned. + * The rule bodies are just ECHO as opposed to what the backend does, + * however. (But be sure to duplicate code that affects the lexing process, + * such as BEGIN().) Also, psqlscan uses a single <> rule whereas + * scan.l has a separate one for each exclusive state. + */ +/* + * OK, here is a short description of lex/flex rules behavior. + * The longest pattern which matches an input string is always chosen. + * For equal-length patterns, the first occurring in the rules list is chosen. + * INITIAL is the starting state, to which all non-conditional rules apply. + * Exclusive states change parsing rules while the state is active. When in + * an exclusive state, only those rules defined for that state apply. + * + * We use exclusive states for quoted strings, extended comments, + * and to eliminate parsing troubles for numeric strings. + * Exclusive states: + * bit string literal + * extended C-style comments + * delimited identifiers (double-quoted identifiers) + * hexadecimal numeric string + * standard quoted strings + * extended quoted strings (support backslash escape sequences) + * $foo$ quoted strings + * quoted identifier with Unicode escapes + * quoted string with Unicode escapes + * + * Note: we intentionally don't mimic the backend's state; we have + * no need to distinguish it from state, and no good way to get out + * of it in error cases. The backend just throws yyerror() in those + * cases, but that's not an option here. + */ + + + + + + + + + +/* Additional exclusive states for psql only: lex backslash commands */ + + + + + + + + +/* + * In order to make the world safe for Windows and Mac clients as well as + * Unix ones, we accept either \n or \r as a newline. A DOS-style \r\n + * sequence will be seen as two successive newlines, but that doesn't cause + * any problems. Comments that start with -- and extend to the next + * newline are treated as equivalent to a single whitespace character. + * + * NOTE a fine point: if there is no newline following --, we will absorb + * everything to the end of the input as a comment. This is correct. Older + * versions of Postgres failed to recognize -- as a comment if the input + * did not end with a newline. + * + * XXX perhaps \f (formfeed) should be treated as a newline as well? + * + * XXX if you change the set of whitespace characters, fix scanner_isspace() + * to agree, and see also the plpgsql lexer. + */ +/* + * SQL requires at least one newline in the whitespace separating + * string literals that are to be concatenated. Silly, but who are we + * to argue? Note that {whitespace_with_newline} should not have * after + * it, whereas {whitespace} should generally have a * after it... + */ +/* + * To ensure that {quotecontinue} can be scanned without having to back up + * if the full pattern isn't matched, we include trailing whitespace in + * {quotestop}. This matches all cases where {quotecontinue} fails to match, + * except for {quote} followed by whitespace and just one "-" (not two, + * which would start a {comment}). To cover that we have {quotefail}. + * The actions for {quotestop} and {quotefail} must throw back characters + * beyond the quote proper. + */ +/* Bit string + * It is tempting to scan the string for only those characters + * which are allowed. However, this leads to silently swallowed + * characters if illegal characters are included in the string. + * For example, if xbinside is [01] then B'ABCD' is interpreted + * as a zero-length string, and the ABCD' is lost! + * Better to pass the string forward and let the input routines + * validate the contents. + */ +/* Hexadecimal number */ +/* National character */ +/* Quoted string that allows backslash escapes */ +/* Extended quote + * xqdouble implements embedded quote, '''' + */ +/* $foo$ style quotes ("dollar quoting") + * The quoted string starts with $foo$ where "foo" is an optional string + * in the form of an identifier, except that it may not contain "$", + * and extends to the first occurrence of an identical string. + * There is *no* processing of the quoted text. + * + * {dolqfailed} is an error rule to avoid scanner backup when {dolqdelim} + * fails to match its trailing "$". + */ +/* Double quote + * Allows embedded spaces and other special characters into identifiers. + */ +/* Unicode escapes */ +/* error rule to avoid backup */ +/* Quoted identifier with Unicode escapes */ +/* Quoted string with Unicode escapes */ +/* error rule to avoid backup */ +/* C-style comments + * + * The "extended comment" syntax closely resembles allowable operator syntax. + * The tricky part here is to get lex to recognize a string starting with + * slash-star as a comment, when interpreting it as an operator would produce + * a longer match --- remember lex will prefer a longer match! Also, if we + * have something like plus-slash-star, lex will think this is a 3-character + * operator whereas we want to see it as a + operator and a comment start. + * The solution is two-fold: + * 1. append {op_chars}* to xcstart so that it matches as much text as + * {operator} would. Then the tie-breaker (first matching rule of same + * length) ensures xcstart wins. We put back the extra stuff with yyless() + * in case it contains a star-slash that should terminate the comment. + * 2. In the operator rule, check for slash-star within the operator, and + * if found throw it back with yyless(). This handles the plus-slash-star + * problem. + * Dash-dash comments have similar interactions with the operator rule. + */ +/* + * "self" is the set of chars that should be returned as single-character + * tokens. "op_chars" is the set of chars that can make up "Op" tokens, + * which can be one or more characters long (but if a single-char token + * appears in the "self" set, it is not to be returned as an Op). Note + * that the sets overlap, but each has some chars that are not in the other. + * + * If you change either set, adjust the character lists appearing in the + * rule for "operator"! + */ +/* we no longer allow unary minus in numbers. + * instead we pass it separately to parser. there it gets + * coerced via doNegate() -- Leon aug 20 1999 + * + * {decimalfail} is used because we would like "1..10" to lex as 1, dot_dot, 10. + * + * {realfail1} and {realfail2} are added to prevent the need for scanner + * backup when the {real} rule fails to match completely. + */ +/* psql-specific: characters allowed in variable names */ +/* + * Dollar quoted strings are totally opaque, and no escaping is done on them. + * Other quoted strings must allow some special characters such as single-quote + * and newline. + * Embedded single-quotes are implemented both in the SQL standard + * style of two adjacent single quotes "''" and in the Postgres/Java style + * of escaped-quote "\'". + * Other embedded escaped characters are matched explicitly and the leading + * backslash is dropped from the string. + * Note that xcstart must appear before operator, as explained above! + * Also whitespace (comment) must appear before operator. + */ +#line 4581 "psqlscan.c" + +#define INITIAL 0 +#define xb 1 +#define xc 2 +#define xd 3 +#define xh 4 +#define xe 5 +#define xq 6 +#define xdolq 7 +#define xui 8 +#define xus 9 +#define xslashcmd 10 +#define xslashargstart 11 +#define xslasharg 12 +#define xslashquote 13 +#define xslashbackquote 14 +#define xslashdquote 15 +#define xslashwholeline 16 +#define xslashend 17 + +#ifndef YY_NO_UNISTD_H +/* Special case for "unistd.h", since it is non-ANSI. We include it way + * down here because we want the user's section 1 to have been scanned first. + * The user has a chance to override it with an option. + */ +#include +#endif + +#ifndef YY_EXTRA_TYPE +#define YY_EXTRA_TYPE void * +#endif + +static int yy_init_globals (void ); + +/* Accessor methods to globals. + These are made visible to non-reentrant scanners for convenience. */ + +int yylex_destroy (void ); + +int yyget_debug (void ); + +void yyset_debug (int debug_flag ); + +YY_EXTRA_TYPE yyget_extra (void ); + +void yyset_extra (YY_EXTRA_TYPE user_defined ); + +FILE *yyget_in (void ); + +void yyset_in (FILE * in_str ); + +FILE *yyget_out (void ); + +void yyset_out (FILE * out_str ); + +int yyget_leng (void ); + +char *yyget_text (void ); + +int yyget_lineno (void ); + +void yyset_lineno (int line_number ); + +/* Macros after this point can all be overridden by user definitions in + * section 1. + */ + +#ifndef YY_SKIP_YYWRAP +#ifdef __cplusplus +extern "C" int yywrap (void ); +#else +extern int yywrap (void ); +#endif +#endif + +#ifndef yytext_ptr +static void yy_flex_strncpy (char *,yyconst char *,int ); +#endif + +#ifdef YY_NEED_STRLEN +static int yy_flex_strlen (yyconst char * ); +#endif + +#ifndef YY_NO_INPUT + +#ifdef __cplusplus +static int yyinput (void ); +#else +static int input (void ); +#endif + +#endif + +/* Amount of stuff to slurp up with each read. */ +#ifndef YY_READ_BUF_SIZE +#ifdef __ia64__ +/* On IA-64, the buffer size is 16k, not 8k */ +#define YY_READ_BUF_SIZE 16384 +#else +#define YY_READ_BUF_SIZE 8192 +#endif /* __ia64__ */ +#endif + +/* Copy whatever the last rule matched to the standard output. */ +#ifndef ECHO +/* This used to be an fputs(), but since the string might contain NUL's, + * we now use fwrite(). + */ +#define ECHO do { if (fwrite( yytext, yyleng, 1, yyout )) {} } while (0) +#endif + +/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL, + * is returned in "result". + */ +#ifndef YY_INPUT +#define YY_INPUT(buf,result,max_size) \ + if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \ + { \ + int c = '*'; \ + size_t n; \ + for ( n = 0; n < max_size && \ + (c = getc( yyin )) != EOF && c != '\n'; ++n ) \ + buf[n] = (char) c; \ + if ( c == '\n' ) \ + buf[n++] = (char) c; \ + if ( c == EOF && ferror( yyin ) ) \ + YY_FATAL_ERROR( "input in flex scanner failed" ); \ + result = n; \ + } \ + else \ + { \ + errno=0; \ + while ( (result = fread(buf, 1, max_size, yyin))==0 && ferror(yyin)) \ + { \ + if( errno != EINTR) \ + { \ + YY_FATAL_ERROR( "input in flex scanner failed" ); \ + break; \ + } \ + errno=0; \ + clearerr(yyin); \ + } \ + }\ +\ + +#endif + +/* No semi-colon after return; correct usage is to write "yyterminate();" - + * we don't want an extra ';' after the "return" because that will cause + * some compilers to complain about unreachable statements. + */ +#ifndef yyterminate +#define yyterminate() return YY_NULL +#endif + +/* Number of entries by which start-condition stack grows. */ +#ifndef YY_START_STACK_INCR +#define YY_START_STACK_INCR 25 +#endif + +/* Report a fatal error. */ +#ifndef YY_FATAL_ERROR +#define YY_FATAL_ERROR(msg) yy_fatal_error( msg ) +#endif + +/* end tables serialization structures and prototypes */ + +/* Default declaration of generated scanner - a define so the user can + * easily add parameters. + */ +#ifndef YY_DECL +#define YY_DECL_IS_OURS 1 + +extern int yylex (void); + +#define YY_DECL int yylex (void) +#endif /* !YY_DECL */ + +/* Code executed at the beginning of each rule, after yytext and yyleng + * have been set up. + */ +#ifndef YY_USER_ACTION +#define YY_USER_ACTION +#endif + +/* Code executed at the end of each rule. */ +#ifndef YY_BREAK +#define YY_BREAK break; +#endif + +#define YY_RULE_SETUP \ + YY_USER_ACTION + +/** The main scanner function which does all the work. + */ +YY_DECL +{ + register yy_state_type yy_current_state; + register char *yy_cp, *yy_bp; + register int yy_act; + +#line 409 "psqlscan.l" + + +#line 4786 "psqlscan.c" + + if ( !(yy_init) ) + { + (yy_init) = 1; + +#ifdef YY_USER_INIT + YY_USER_INIT; +#endif + + if ( ! (yy_start) ) + (yy_start) = 1; /* first start state */ + + if ( ! yyin ) + yyin = stdin; + + if ( ! yyout ) + yyout = stdout; + + if ( ! YY_CURRENT_BUFFER ) { + yyensure_buffer_stack (); + YY_CURRENT_BUFFER_LVALUE = + yy_create_buffer(yyin,YY_BUF_SIZE ); + } + + yy_load_buffer_state( ); + } + + while ( 1 ) /* loops until end-of-file is reached */ + { + yy_cp = (yy_c_buf_p); + + /* Support of yytext. */ + *yy_cp = (yy_hold_char); + + /* yy_bp points to the position in yy_ch_buf of the start of + * the current run. + */ + yy_bp = yy_cp; + + yy_current_state = (yy_start); +yy_match: + while ( (yy_current_state = yy_nxt[yy_current_state][ yy_ec[YY_SC_TO_UI(*yy_cp)] ]) > 0 ) + ++yy_cp; + + yy_current_state = -yy_current_state; + +yy_find_action: + yy_act = yy_accept[yy_current_state]; + + YY_DO_BEFORE_ACTION; + +do_action: /* This label is used only to access EOF actions. */ + + switch ( yy_act ) + { /* beginning of action switch */ +case 1: +/* rule 1 can match eol */ +YY_RULE_SETUP +#line 411 "psqlscan.l" +{ + /* + * Note that the whitespace rule includes both true + * whitespace and single-line ("--" style) comments. + * We suppress whitespace at the start of the query + * buffer. We also suppress all single-line comments, + * which is pretty dubious but is the historical + * behavior. + */ + if (!(output_buf->len == 0 || yytext[0] == '-')) + ECHO; + } + YY_BREAK +case 2: +YY_RULE_SETUP +#line 424 "psqlscan.l" +{ + cur_state->xcdepth = 0; + BEGIN(xc); + /* Put back any characters past slash-star; see above */ + yyless(2); + ECHO; + } + YY_BREAK +case 3: +YY_RULE_SETUP +#line 432 "psqlscan.l" +{ + cur_state->xcdepth++; + /* Put back any characters past slash-star; see above */ + yyless(2); + ECHO; + } + YY_BREAK +case 4: +YY_RULE_SETUP +#line 439 "psqlscan.l" +{ + if (cur_state->xcdepth <= 0) + { + BEGIN(INITIAL); + } + else + cur_state->xcdepth--; + ECHO; + } + YY_BREAK +case 5: +/* rule 5 can match eol */ +YY_RULE_SETUP +#line 449 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 6: +YY_RULE_SETUP +#line 453 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 7: +YY_RULE_SETUP +#line 457 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 8: +YY_RULE_SETUP +#line 461 "psqlscan.l" +{ + BEGIN(xb); + ECHO; + } + YY_BREAK +case 9: +/* rule 9 can match eol */ +#line 466 "psqlscan.l" +case 10: +/* rule 10 can match eol */ +YY_RULE_SETUP +#line 466 "psqlscan.l" +{ + yyless(1); + BEGIN(INITIAL); + ECHO; + } + YY_BREAK +case 11: +/* rule 11 can match eol */ +#line 472 "psqlscan.l" +case 12: +/* rule 12 can match eol */ +YY_RULE_SETUP +#line 472 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 13: +/* rule 13 can match eol */ +#line 476 "psqlscan.l" +case 14: +/* rule 14 can match eol */ +YY_RULE_SETUP +#line 476 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 15: +YY_RULE_SETUP +#line 480 "psqlscan.l" +{ + /* Hexadecimal bit type. + * At some point we should simply pass the string + * forward to the parser and label it there. + * In the meantime, place a leading "x" on the string + * to mark it for the input routine as a hex string. + */ + BEGIN(xh); + ECHO; + } + YY_BREAK +case 16: +/* rule 16 can match eol */ +#line 491 "psqlscan.l" +case 17: +/* rule 17 can match eol */ +YY_RULE_SETUP +#line 491 "psqlscan.l" +{ + yyless(1); + BEGIN(INITIAL); + ECHO; + } + YY_BREAK +case 18: +YY_RULE_SETUP +#line 497 "psqlscan.l" +{ + yyless(1); /* eat only 'n' this time */ + ECHO; + } + YY_BREAK +case 19: +YY_RULE_SETUP +#line 502 "psqlscan.l" +{ + if (standard_strings()) + BEGIN(xq); + else + BEGIN(xe); + ECHO; + } + YY_BREAK +case 20: +YY_RULE_SETUP +#line 509 "psqlscan.l" +{ + BEGIN(xe); + ECHO; + } + YY_BREAK +case 21: +YY_RULE_SETUP +#line 513 "psqlscan.l" +{ + BEGIN(xus); + ECHO; + } + YY_BREAK +case 22: +/* rule 22 can match eol */ +#line 518 "psqlscan.l" +case 23: +/* rule 23 can match eol */ +YY_RULE_SETUP +#line 518 "psqlscan.l" +{ + yyless(1); + BEGIN(INITIAL); + ECHO; + } + YY_BREAK +case 24: +/* rule 24 can match eol */ +YY_RULE_SETUP +#line 523 "psqlscan.l" +{ + yyless(1); + BEGIN(INITIAL); + ECHO; + } + YY_BREAK +case 25: +/* rule 25 can match eol */ +YY_RULE_SETUP +#line 528 "psqlscan.l" +{ + BEGIN(INITIAL); + ECHO; + } + YY_BREAK +case 26: +YY_RULE_SETUP +#line 532 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 27: +/* rule 27 can match eol */ +YY_RULE_SETUP +#line 535 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 28: +/* rule 28 can match eol */ +YY_RULE_SETUP +#line 538 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 29: +YY_RULE_SETUP +#line 541 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 30: +YY_RULE_SETUP +#line 544 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 31: +/* rule 31 can match eol */ +YY_RULE_SETUP +#line 547 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 32: +YY_RULE_SETUP +#line 550 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 33: +YY_RULE_SETUP +#line 553 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 34: +/* rule 34 can match eol */ +YY_RULE_SETUP +#line 556 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 35: +YY_RULE_SETUP +#line 559 "psqlscan.l" +{ + /* This is only needed for \ just before EOF */ + ECHO; + } + YY_BREAK +case 36: +YY_RULE_SETUP +#line 564 "psqlscan.l" +{ + cur_state->dolqstart = pg_strdup(yytext); + BEGIN(xdolq); + ECHO; + } + YY_BREAK +case 37: +YY_RULE_SETUP +#line 569 "psqlscan.l" +{ + /* throw back all but the initial "$" */ + yyless(1); + ECHO; + } + YY_BREAK +case 38: +YY_RULE_SETUP +#line 574 "psqlscan.l" +{ + if (strcmp(yytext, cur_state->dolqstart) == 0) + { + free(cur_state->dolqstart); + cur_state->dolqstart = NULL; + BEGIN(INITIAL); + } + else + { + /* + * When we fail to match $...$ to dolqstart, transfer + * the $... part to the output, but put back the final + * $ for rescanning. Consider $delim$...$junk$delim$ + */ + yyless(yyleng-1); + } + ECHO; + } + YY_BREAK +case 39: +/* rule 39 can match eol */ +YY_RULE_SETUP +#line 592 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 40: +YY_RULE_SETUP +#line 595 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 41: +YY_RULE_SETUP +#line 598 "psqlscan.l" +{ + /* This is only needed for $ inside the quoted text */ + ECHO; + } + YY_BREAK +case 42: +YY_RULE_SETUP +#line 603 "psqlscan.l" +{ + BEGIN(xd); + ECHO; + } + YY_BREAK +case 43: +YY_RULE_SETUP +#line 607 "psqlscan.l" +{ + BEGIN(xui); + ECHO; + } + YY_BREAK +case 44: +YY_RULE_SETUP +#line 611 "psqlscan.l" +{ + BEGIN(INITIAL); + ECHO; + } + YY_BREAK +case 45: +/* rule 45 can match eol */ +YY_RULE_SETUP +#line 615 "psqlscan.l" +{ + yyless(1); + BEGIN(INITIAL); + ECHO; + } + YY_BREAK +case 46: +/* rule 46 can match eol */ +YY_RULE_SETUP +#line 620 "psqlscan.l" +{ + BEGIN(INITIAL); + ECHO; + } + YY_BREAK +case 47: +YY_RULE_SETUP +#line 624 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 48: +/* rule 48 can match eol */ +YY_RULE_SETUP +#line 627 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 49: +YY_RULE_SETUP +#line 631 "psqlscan.l" +{ + /* throw back all but the initial u/U */ + yyless(1); + ECHO; + } + YY_BREAK +case 50: +YY_RULE_SETUP +#line 637 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 51: +YY_RULE_SETUP +#line 641 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 52: +YY_RULE_SETUP +#line 645 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +/* + * These rules are specific to psql --- they implement parenthesis + * counting and detection of command-ending semicolon. These must + * appear before the {self} rule so that they take precedence over it. + */ +case 53: +YY_RULE_SETUP +#line 655 "psqlscan.l" +{ + cur_state->paren_depth++; + ECHO; + } + YY_BREAK +case 54: +YY_RULE_SETUP +#line 660 "psqlscan.l" +{ + if (cur_state->paren_depth > 0) + cur_state->paren_depth--; + ECHO; + } + YY_BREAK +case 55: +YY_RULE_SETUP +#line 666 "psqlscan.l" +{ + ECHO; + if (cur_state->paren_depth == 0) + { + /* Terminate lexing temporarily */ + return LEXRES_SEMI; + } + } + YY_BREAK +/* + * psql-specific rules to handle backslash commands and variable + * substitution. We want these before {self}, also. + */ +case 56: +YY_RULE_SETUP +#line 680 "psqlscan.l" +{ + /* Force a semicolon or colon into the query buffer */ + emit(yytext + 1, 1); + } + YY_BREAK +case 57: +YY_RULE_SETUP +#line 685 "psqlscan.l" +{ + /* Terminate lexing temporarily */ + return LEXRES_BACKSLASH; + } + YY_BREAK +case 58: +YY_RULE_SETUP +#line 690 "psqlscan.l" +{ + /* Possible psql variable substitution */ + char *varname; + const char *value; + + varname = extract_substring(yytext + 1, yyleng - 1); + value = GetVariable(pset.vars, varname); + + if (value) + { + /* It is a variable, check for recursion */ + if (var_is_current_source(cur_state, varname)) + { + /* Recursive expansion --- don't go there */ + psql_error("skipping recursive expansion of variable \"%s\"\n", + varname); + /* Instead copy the string as is */ + ECHO; + } + else + { + /* OK, perform substitution */ + push_new_buffer(value, varname); + /* yy_scan_string already made buffer active */ + } + } + else + { + /* + * if the variable doesn't exist we'll copy the + * string as is + */ + ECHO; + } + + free(varname); + } + YY_BREAK +case 59: +YY_RULE_SETUP +#line 728 "psqlscan.l" +{ + escape_variable(false); + } + YY_BREAK +case 60: +YY_RULE_SETUP +#line 732 "psqlscan.l" +{ + escape_variable(true); + } + YY_BREAK +/* + * These rules just avoid the need for scanner backup if one of the + * two rules above fails to match completely. + */ +case 61: +YY_RULE_SETUP +#line 741 "psqlscan.l" +{ + /* Throw back everything but the colon */ + yyless(1); + ECHO; + } + YY_BREAK +case 62: +YY_RULE_SETUP +#line 747 "psqlscan.l" +{ + /* Throw back everything but the colon */ + yyless(1); + ECHO; + } + YY_BREAK +/* + * Back to backend-compatible rules. + */ +case 63: +YY_RULE_SETUP +#line 757 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 64: +YY_RULE_SETUP +#line 761 "psqlscan.l" +{ + /* + * Check for embedded slash-star or dash-dash; those + * are comment starts, so operator must stop there. + * Note that slash-star or dash-dash at the first + * character will match a prior rule, not this one. + */ + int nchars = yyleng; + char *slashstar = strstr(yytext, "/*"); + char *dashdash = strstr(yytext, "--"); + + if (slashstar && dashdash) + { + /* if both appear, take the first one */ + if (slashstar > dashdash) + slashstar = dashdash; + } + else if (!slashstar) + slashstar = dashdash; + if (slashstar) + nchars = slashstar - yytext; + + /* + * For SQL compatibility, '+' and '-' cannot be the + * last char of a multi-char operator unless the operator + * contains chars that are not in SQL operators. + * The idea is to lex '=-' as two operators, but not + * to forbid operator names like '?-' that could not be + * sequences of SQL operators. + */ + while (nchars > 1 && + (yytext[nchars-1] == '+' || + yytext[nchars-1] == '-')) + { + int ic; + + for (ic = nchars-2; ic >= 0; ic--) + { + if (strchr("~!@#^&|`?%", yytext[ic])) + break; + } + if (ic >= 0) + break; /* found a char that makes it OK */ + nchars--; /* else remove the +/-, and check again */ + } + + if (nchars < yyleng) + { + /* Strip the unwanted chars from the token */ + yyless(nchars); + } + ECHO; + } + YY_BREAK +case 65: +YY_RULE_SETUP +#line 815 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 66: +YY_RULE_SETUP +#line 819 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 67: +YY_RULE_SETUP +#line 822 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 68: +YY_RULE_SETUP +#line 825 "psqlscan.l" +{ + /* throw back the .., and treat as integer */ + yyless(yyleng-2); + ECHO; + } + YY_BREAK +case 69: +YY_RULE_SETUP +#line 830 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 70: +YY_RULE_SETUP +#line 833 "psqlscan.l" +{ + /* + * throw back the [Ee], and treat as {decimal}. Note + * that it is possible the input is actually {integer}, + * but since this case will almost certainly lead to a + * syntax error anyway, we don't bother to distinguish. + */ + yyless(yyleng-1); + ECHO; + } + YY_BREAK +case 71: +YY_RULE_SETUP +#line 843 "psqlscan.l" +{ + /* throw back the [Ee][+-], and proceed as above */ + yyless(yyleng-2); + ECHO; + } + YY_BREAK +case 72: +YY_RULE_SETUP +#line 850 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +case 73: +YY_RULE_SETUP +#line 854 "psqlscan.l" +{ + ECHO; + } + YY_BREAK +/* + * Everything from here down is psql-specific. + */ +case YY_STATE_EOF(INITIAL): +case YY_STATE_EOF(xb): +case YY_STATE_EOF(xc): +case YY_STATE_EOF(xd): +case YY_STATE_EOF(xh): +case YY_STATE_EOF(xe): +case YY_STATE_EOF(xq): +case YY_STATE_EOF(xdolq): +case YY_STATE_EOF(xui): +case YY_STATE_EOF(xus): +case YY_STATE_EOF(xslashcmd): +case YY_STATE_EOF(xslashargstart): +case YY_STATE_EOF(xslasharg): +case YY_STATE_EOF(xslashquote): +case YY_STATE_EOF(xslashbackquote): +case YY_STATE_EOF(xslashdquote): +case YY_STATE_EOF(xslashwholeline): +case YY_STATE_EOF(xslashend): +#line 863 "psqlscan.l" +{ + StackElem *stackelem = cur_state->buffer_stack; + + if (stackelem == NULL) + return LEXRES_EOL; /* end of input reached */ + + /* + * We were expanding a variable, so pop the inclusion + * stack and keep lexing + */ + pop_buffer_stack(cur_state); + + stackelem = cur_state->buffer_stack; + if (stackelem != NULL) + { + yy_switch_to_buffer(stackelem->buf); + cur_state->curline = stackelem->bufstring; + cur_state->refline = stackelem->origstring ? stackelem->origstring : stackelem->bufstring; + } + else + { + yy_switch_to_buffer(cur_state->scanbufhandle); + cur_state->curline = cur_state->scanbuf; + cur_state->refline = cur_state->scanline; + } + } + YY_BREAK +/* + * Exclusive lexer states to handle backslash command lexing + */ + +/* command name ends at whitespace or backslash; eat all else */ +case 74: +/* rule 74 can match eol */ +YY_RULE_SETUP +#line 897 "psqlscan.l" +{ + yyless(0); + return LEXRES_OK; + } + YY_BREAK +case 75: +YY_RULE_SETUP +#line 902 "psqlscan.l" +{ ECHO; } + YY_BREAK + + +/* + * Discard any whitespace before argument, then go to xslasharg state. + * An exception is that "|" is only special at start of argument, so we + * check for it here. + */ +case 76: +/* rule 76 can match eol */ +YY_RULE_SETUP +#line 913 "psqlscan.l" +{ } + YY_BREAK +case 77: +YY_RULE_SETUP +#line 915 "psqlscan.l" +{ + if (option_type == OT_FILEPIPE) + { + /* treat like whole-string case */ + ECHO; + BEGIN(xslashwholeline); + } + else + { + /* vertical bar is not special otherwise */ + yyless(0); + BEGIN(xslasharg); + } + } + YY_BREAK +case 78: +YY_RULE_SETUP +#line 930 "psqlscan.l" +{ + yyless(0); + BEGIN(xslasharg); + } + YY_BREAK + + +/* + * Default processing of text in a slash command's argument. + * + * Note: unquoted_option_chars counts the number of characters at the + * end of the argument that were not subject to any form of quoting. + * psql_scan_slash_option needs this to strip trailing semicolons safely. + */ +case 79: +/* rule 79 can match eol */ +YY_RULE_SETUP +#line 946 "psqlscan.l" +{ + /* + * Unquoted space is end of arg; do not eat. Likewise + * backslash is end of command or next command, do not eat + * + * XXX this means we can't conveniently accept options + * that include unquoted backslashes; therefore, option + * processing that encourages use of backslashes is rather + * broken. + */ + yyless(0); + return LEXRES_OK; + } + YY_BREAK +case 80: +YY_RULE_SETUP +#line 960 "psqlscan.l" +{ + *option_quote = '\''; + unquoted_option_chars = 0; + BEGIN(xslashquote); + } + YY_BREAK +case 81: +YY_RULE_SETUP +#line 966 "psqlscan.l" +{ + backtick_start_offset = output_buf->len; + *option_quote = '`'; + unquoted_option_chars = 0; + BEGIN(xslashbackquote); + } + YY_BREAK +case 82: +YY_RULE_SETUP +#line 973 "psqlscan.l" +{ + ECHO; + *option_quote = '"'; + unquoted_option_chars = 0; + BEGIN(xslashdquote); + } + YY_BREAK +case 83: +YY_RULE_SETUP +#line 980 "psqlscan.l" +{ + /* Possible psql variable substitution */ + if (option_type == OT_NO_EVAL) + ECHO; + else + { + char *varname; + const char *value; + + varname = extract_substring(yytext + 1, yyleng - 1); + value = GetVariable(pset.vars, varname); + free(varname); + + /* + * The variable value is just emitted without any + * further examination. This is consistent with the + * pre-8.0 code behavior, if not with the way that + * variables are handled outside backslash commands. + * Note that we needn't guard against recursion here. + */ + if (value) + appendPQExpBufferStr(output_buf, value); + else + ECHO; + + *option_quote = ':'; + } + unquoted_option_chars = 0; + } + YY_BREAK +case 84: +YY_RULE_SETUP +#line 1010 "psqlscan.l" +{ + if (option_type == OT_NO_EVAL) + ECHO; + else + { + escape_variable(false); + *option_quote = ':'; + } + unquoted_option_chars = 0; + } + YY_BREAK +case 85: +YY_RULE_SETUP +#line 1022 "psqlscan.l" +{ + if (option_type == OT_NO_EVAL) + ECHO; + else + { + escape_variable(true); + *option_quote = ':'; + } + unquoted_option_chars = 0; + } + YY_BREAK +case 86: +YY_RULE_SETUP +#line 1033 "psqlscan.l" +{ + /* Throw back everything but the colon */ + yyless(1); + unquoted_option_chars++; + ECHO; + } + YY_BREAK +case 87: +YY_RULE_SETUP +#line 1040 "psqlscan.l" +{ + /* Throw back everything but the colon */ + yyless(1); + unquoted_option_chars++; + ECHO; + } + YY_BREAK +case 88: +YY_RULE_SETUP +#line 1047 "psqlscan.l" +{ + unquoted_option_chars++; + ECHO; + } + YY_BREAK + + +/* + * single-quoted text: copy literally except for '' and backslash + * sequences + */ +case 89: +YY_RULE_SETUP +#line 1060 "psqlscan.l" +{ BEGIN(xslasharg); } + YY_BREAK +case 90: +YY_RULE_SETUP +#line 1062 "psqlscan.l" +{ appendPQExpBufferChar(output_buf, '\''); } + YY_BREAK +case 91: +YY_RULE_SETUP +#line 1064 "psqlscan.l" +{ appendPQExpBufferChar(output_buf, '\n'); } + YY_BREAK +case 92: +YY_RULE_SETUP +#line 1065 "psqlscan.l" +{ appendPQExpBufferChar(output_buf, '\t'); } + YY_BREAK +case 93: +YY_RULE_SETUP +#line 1066 "psqlscan.l" +{ appendPQExpBufferChar(output_buf, '\b'); } + YY_BREAK +case 94: +YY_RULE_SETUP +#line 1067 "psqlscan.l" +{ appendPQExpBufferChar(output_buf, '\r'); } + YY_BREAK +case 95: +YY_RULE_SETUP +#line 1068 "psqlscan.l" +{ appendPQExpBufferChar(output_buf, '\f'); } + YY_BREAK +case 96: +YY_RULE_SETUP +#line 1070 "psqlscan.l" +{ + /* octal case */ + appendPQExpBufferChar(output_buf, + (char) strtol(yytext + 1, NULL, 8)); + } + YY_BREAK +case 97: +YY_RULE_SETUP +#line 1076 "psqlscan.l" +{ + /* hex case */ + appendPQExpBufferChar(output_buf, + (char) strtol(yytext + 2, NULL, 16)); + } + YY_BREAK +case 98: +YY_RULE_SETUP +#line 1082 "psqlscan.l" +{ emit(yytext + 1, 1); } + YY_BREAK +case 99: +/* rule 99 can match eol */ +YY_RULE_SETUP +#line 1084 "psqlscan.l" +{ ECHO; } + YY_BREAK + + +/* + * backticked text: copy everything until next backquote, then evaluate. + * + * XXX Possible future behavioral change: substitute for :VARIABLE? + */ +case 100: +YY_RULE_SETUP +#line 1095 "psqlscan.l" +{ + /* In NO_EVAL mode, don't evaluate the command */ + if (option_type != OT_NO_EVAL) + evaluate_backtick(); + BEGIN(xslasharg); + } + YY_BREAK +case 101: +/* rule 101 can match eol */ +YY_RULE_SETUP +#line 1102 "psqlscan.l" +{ ECHO; } + YY_BREAK + + +/* double-quoted text: copy verbatim, including the double quotes */ +case 102: +YY_RULE_SETUP +#line 1109 "psqlscan.l" +{ + ECHO; + BEGIN(xslasharg); + } + YY_BREAK +case 103: +/* rule 103 can match eol */ +YY_RULE_SETUP +#line 1114 "psqlscan.l" +{ ECHO; } + YY_BREAK + + +/* copy everything until end of input line */ +/* but suppress leading whitespace */ +case 104: +/* rule 104 can match eol */ +YY_RULE_SETUP +#line 1122 "psqlscan.l" +{ + if (output_buf->len > 0) + ECHO; + } + YY_BREAK +case 105: +YY_RULE_SETUP +#line 1127 "psqlscan.l" +{ ECHO; } + YY_BREAK + + +/* at end of command, eat a double backslash, but not anything else */ +case 106: +YY_RULE_SETUP +#line 1134 "psqlscan.l" +{ return LEXRES_OK; } + YY_BREAK +case 107: +/* rule 107 can match eol */ +YY_RULE_SETUP +#line 1136 "psqlscan.l" +{ + yyless(0); + return LEXRES_OK; + } + YY_BREAK + +case 108: +YY_RULE_SETUP +#line 1143 "psqlscan.l" +YY_FATAL_ERROR( "flex scanner jammed" ); + YY_BREAK +#line 5953 "psqlscan.c" + + case YY_END_OF_BUFFER: + { + /* Amount of text matched not including the EOB char. */ + int yy_amount_of_matched_text = (int) (yy_cp - (yytext_ptr)) - 1; + + /* Undo the effects of YY_DO_BEFORE_ACTION. */ + *yy_cp = (yy_hold_char); + YY_RESTORE_YY_MORE_OFFSET + + if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW ) + { + /* We're scanning a new file or input source. It's + * possible that this happened because the user + * just pointed yyin at a new source and called + * yylex(). If so, then we have to assure + * consistency between YY_CURRENT_BUFFER and our + * globals. Here is the right place to do so, because + * this is the first action (other than possibly a + * back-up) that will match for the new input source. + */ + (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars; + YY_CURRENT_BUFFER_LVALUE->yy_input_file = yyin; + YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL; + } + + /* Note that here we test for yy_c_buf_p "<=" to the position + * of the first EOB in the buffer, since yy_c_buf_p will + * already have been incremented past the NUL character + * (since all states make transitions on EOB to the + * end-of-buffer state). Contrast this with the test + * in input(). + */ + if ( (yy_c_buf_p) <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] ) + { /* This was really a NUL. */ + yy_state_type yy_next_state; + + (yy_c_buf_p) = (yytext_ptr) + yy_amount_of_matched_text; + + yy_current_state = yy_get_previous_state( ); + + /* Okay, we're now positioned to make the NUL + * transition. We couldn't have + * yy_get_previous_state() go ahead and do it + * for us because it doesn't know how to deal + * with the possibility of jamming (and we don't + * want to build jamming into it because then it + * will run more slowly). + */ + + yy_next_state = yy_try_NUL_trans( yy_current_state ); + + yy_bp = (yytext_ptr) + YY_MORE_ADJ; + + if ( yy_next_state ) + { + /* Consume the NUL. */ + yy_cp = ++(yy_c_buf_p); + yy_current_state = yy_next_state; + goto yy_match; + } + + else + { + yy_cp = (yy_c_buf_p); + goto yy_find_action; + } + } + + else switch ( yy_get_next_buffer( ) ) + { + case EOB_ACT_END_OF_FILE: + { + (yy_did_buffer_switch_on_eof) = 0; + + if ( yywrap( ) ) + { + /* Note: because we've taken care in + * yy_get_next_buffer() to have set up + * yytext, we can now set up + * yy_c_buf_p so that if some total + * hoser (like flex itself) wants to + * call the scanner after we return the + * YY_NULL, it'll still work - another + * YY_NULL will get returned. + */ + (yy_c_buf_p) = (yytext_ptr) + YY_MORE_ADJ; + + yy_act = YY_STATE_EOF(YY_START); + goto do_action; + } + + else + { + if ( ! (yy_did_buffer_switch_on_eof) ) + YY_NEW_FILE; + } + break; + } + + case EOB_ACT_CONTINUE_SCAN: + (yy_c_buf_p) = + (yytext_ptr) + yy_amount_of_matched_text; + + yy_current_state = yy_get_previous_state( ); + + yy_cp = (yy_c_buf_p); + yy_bp = (yytext_ptr) + YY_MORE_ADJ; + goto yy_match; + + case EOB_ACT_LAST_MATCH: + (yy_c_buf_p) = + &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)]; + + yy_current_state = yy_get_previous_state( ); + + yy_cp = (yy_c_buf_p); + yy_bp = (yytext_ptr) + YY_MORE_ADJ; + goto yy_find_action; + } + break; + } + + default: + YY_FATAL_ERROR( + "fatal flex scanner internal error--no action found" ); + } /* end of action switch */ + } /* end of scanning one token */ +} /* end of yylex */ + +/* yy_get_next_buffer - try to read in a new buffer + * + * Returns a code representing an action: + * EOB_ACT_LAST_MATCH - + * EOB_ACT_CONTINUE_SCAN - continue scanning from current position + * EOB_ACT_END_OF_FILE - end of file + */ +static int yy_get_next_buffer (void) +{ + register char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf; + register char *source = (yytext_ptr); + register int number_to_move, i; + int ret_val; + + if ( (yy_c_buf_p) > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] ) + YY_FATAL_ERROR( + "fatal flex scanner internal error--end of buffer missed" ); + + if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 ) + { /* Don't try to fill the buffer, so this is an EOF. */ + if ( (yy_c_buf_p) - (yytext_ptr) - YY_MORE_ADJ == 1 ) + { + /* We matched a single character, the EOB, so + * treat this as a final EOF. + */ + return EOB_ACT_END_OF_FILE; + } + + else + { + /* We matched some text prior to the EOB, first + * process it. + */ + return EOB_ACT_LAST_MATCH; + } + } + + /* Try to read more data. */ + + /* First move last chars to start of buffer. */ + number_to_move = (int) ((yy_c_buf_p) - (yytext_ptr)) - 1; + + for ( i = 0; i < number_to_move; ++i ) + *(dest++) = *(source++); + + if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING ) + /* don't do the read, it's not guaranteed to return an EOF, + * just force an EOF + */ + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars) = 0; + + else + { + int num_to_read = + YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1; + + while ( num_to_read <= 0 ) + { /* Not enough room in the buffer - grow it. */ + + /* just a shorter name for the current buffer */ + YY_BUFFER_STATE b = YY_CURRENT_BUFFER; + + int yy_c_buf_p_offset = + (int) ((yy_c_buf_p) - b->yy_ch_buf); + + if ( b->yy_is_our_buffer ) + { + int new_size = b->yy_buf_size * 2; + + if ( new_size <= 0 ) + b->yy_buf_size += b->yy_buf_size / 8; + else + b->yy_buf_size *= 2; + + b->yy_ch_buf = (char *) + /* Include room in for 2 EOB chars. */ + yyrealloc((void *) b->yy_ch_buf,b->yy_buf_size + 2 ); + } + else + /* Can't grow it, we don't own it. */ + b->yy_ch_buf = 0; + + if ( ! b->yy_ch_buf ) + YY_FATAL_ERROR( + "fatal error - scanner input buffer overflow" ); + + (yy_c_buf_p) = &b->yy_ch_buf[yy_c_buf_p_offset]; + + num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size - + number_to_move - 1; + + } + + if ( num_to_read > YY_READ_BUF_SIZE ) + num_to_read = YY_READ_BUF_SIZE; + + /* Read in more data. */ + YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]), + (yy_n_chars), (size_t) num_to_read ); + + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); + } + + if ( (yy_n_chars) == 0 ) + { + if ( number_to_move == YY_MORE_ADJ ) + { + ret_val = EOB_ACT_END_OF_FILE; + yyrestart(yyin ); + } + + else + { + ret_val = EOB_ACT_LAST_MATCH; + YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = + YY_BUFFER_EOF_PENDING; + } + } + + else + ret_val = EOB_ACT_CONTINUE_SCAN; + + if ((yy_size_t) ((yy_n_chars) + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) { + /* Extend the array by 50%, plus the number we really need. */ + yy_size_t new_size = (yy_n_chars) + number_to_move + ((yy_n_chars) >> 1); + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) yyrealloc((void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,new_size ); + if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf ) + YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" ); + } + + (yy_n_chars) += number_to_move; + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] = YY_END_OF_BUFFER_CHAR; + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] = YY_END_OF_BUFFER_CHAR; + + (yytext_ptr) = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0]; + + return ret_val; +} + +/* yy_get_previous_state - get the state just before the EOB char was reached */ + + static yy_state_type yy_get_previous_state (void) +{ + register yy_state_type yy_current_state; + register char *yy_cp; + + yy_current_state = (yy_start); + + for ( yy_cp = (yytext_ptr) + YY_MORE_ADJ; yy_cp < (yy_c_buf_p); ++yy_cp ) + { + yy_current_state = yy_nxt[yy_current_state][(*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1)]; + } + + return yy_current_state; +} + +/* yy_try_NUL_trans - try to make a transition on the NUL character + * + * synopsis + * next_state = yy_try_NUL_trans( current_state ); + */ + static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state ) +{ + register int yy_is_jam; + + yy_current_state = yy_nxt[yy_current_state][1]; + yy_is_jam = (yy_current_state <= 0); + + return yy_is_jam ? 0 : yy_current_state; +} + +#ifndef YY_NO_INPUT +#ifdef __cplusplus + static int yyinput (void) +#else + static int input (void) +#endif + +{ + int c; + + *(yy_c_buf_p) = (yy_hold_char); + + if ( *(yy_c_buf_p) == YY_END_OF_BUFFER_CHAR ) + { + /* yy_c_buf_p now points to the character we want to return. + * If this occurs *before* the EOB characters, then it's a + * valid NUL; if not, then we've hit the end of the buffer. + */ + if ( (yy_c_buf_p) < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] ) + /* This was really a NUL. */ + *(yy_c_buf_p) = '\0'; + + else + { /* need more input */ + int offset = (yy_c_buf_p) - (yytext_ptr); + ++(yy_c_buf_p); + + switch ( yy_get_next_buffer( ) ) + { + case EOB_ACT_LAST_MATCH: + /* This happens because yy_g_n_b() + * sees that we've accumulated a + * token and flags that we need to + * try matching the token before + * proceeding. But for input(), + * there's no matching to consider. + * So convert the EOB_ACT_LAST_MATCH + * to EOB_ACT_END_OF_FILE. + */ + + /* Reset buffer status. */ + yyrestart(yyin ); + + /*FALLTHROUGH*/ + + case EOB_ACT_END_OF_FILE: + { + if ( yywrap( ) ) + return EOF; + + if ( ! (yy_did_buffer_switch_on_eof) ) + YY_NEW_FILE; +#ifdef __cplusplus + return yyinput(); +#else + return input(); +#endif + } + + case EOB_ACT_CONTINUE_SCAN: + (yy_c_buf_p) = (yytext_ptr) + offset; + break; + } + } + } + + c = *(unsigned char *) (yy_c_buf_p); /* cast for 8-bit char's */ + *(yy_c_buf_p) = '\0'; /* preserve yytext */ + (yy_hold_char) = *++(yy_c_buf_p); + + return c; +} +#endif /* ifndef YY_NO_INPUT */ + +/** Immediately switch to a different input stream. + * @param input_file A readable stream. + * + * @note This function does not reset the start condition to @c INITIAL . + */ + void yyrestart (FILE * input_file ) +{ + + if ( ! YY_CURRENT_BUFFER ){ + yyensure_buffer_stack (); + YY_CURRENT_BUFFER_LVALUE = + yy_create_buffer(yyin,YY_BUF_SIZE ); + } + + yy_init_buffer(YY_CURRENT_BUFFER,input_file ); + yy_load_buffer_state( ); +} + +/** Switch to a different input buffer. + * @param new_buffer The new input buffer. + * + */ + void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer ) +{ + + /* TODO. We should be able to replace this entire function body + * with + * yypop_buffer_state(); + * yypush_buffer_state(new_buffer); + */ + yyensure_buffer_stack (); + if ( YY_CURRENT_BUFFER == new_buffer ) + return; + + if ( YY_CURRENT_BUFFER ) + { + /* Flush out information for old buffer. */ + *(yy_c_buf_p) = (yy_hold_char); + YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p); + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); + } + + YY_CURRENT_BUFFER_LVALUE = new_buffer; + yy_load_buffer_state( ); + + /* We don't actually know whether we did this switch during + * EOF (yywrap()) processing, but the only time this flag + * is looked at is after yywrap() is called, so it's safe + * to go ahead and always set it. + */ + (yy_did_buffer_switch_on_eof) = 1; +} + +static void yy_load_buffer_state (void) +{ + (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars; + (yytext_ptr) = (yy_c_buf_p) = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos; + yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file; + (yy_hold_char) = *(yy_c_buf_p); +} + +/** Allocate and initialize an input buffer state. + * @param file A readable stream. + * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE. + * + * @return the allocated buffer state. + */ + YY_BUFFER_STATE yy_create_buffer (FILE * file, int size ) +{ + YY_BUFFER_STATE b; + + b = (YY_BUFFER_STATE) yyalloc(sizeof( struct yy_buffer_state ) ); + if ( ! b ) + YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" ); + + b->yy_buf_size = size; + + /* yy_ch_buf has to be 2 characters longer than the size given because + * we need to put in 2 end-of-buffer characters. + */ + b->yy_ch_buf = (char *) yyalloc(b->yy_buf_size + 2 ); + if ( ! b->yy_ch_buf ) + YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" ); + + b->yy_is_our_buffer = 1; + + yy_init_buffer(b,file ); + + return b; +} + +/** Destroy the buffer. + * @param b a buffer created with yy_create_buffer() + * + */ + void yy_delete_buffer (YY_BUFFER_STATE b ) +{ + + if ( ! b ) + return; + + if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */ + YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0; + + if ( b->yy_is_our_buffer ) + yyfree((void *) b->yy_ch_buf ); + + yyfree((void *) b ); +} + +/* Initializes or reinitializes a buffer. + * This function is sometimes called more than once on the same buffer, + * such as during a yyrestart() or at EOF. + */ + static void yy_init_buffer (YY_BUFFER_STATE b, FILE * file ) + +{ + int oerrno = errno; + + yy_flush_buffer(b ); + + b->yy_input_file = file; + b->yy_fill_buffer = 1; + + /* If b is the current buffer, then yy_init_buffer was _probably_ + * called from yyrestart() or through yy_get_next_buffer. + * In that case, we don't want to reset the lineno or column. + */ + if (b != YY_CURRENT_BUFFER){ + b->yy_bs_lineno = 1; + b->yy_bs_column = 0; + } + + b->yy_is_interactive = 0; + + errno = oerrno; +} + +/** Discard all buffered characters. On the next scan, YY_INPUT will be called. + * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER. + * + */ + void yy_flush_buffer (YY_BUFFER_STATE b ) +{ + if ( ! b ) + return; + + b->yy_n_chars = 0; + + /* We always need two end-of-buffer characters. The first causes + * a transition to the end-of-buffer state. The second causes + * a jam in that state. + */ + b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR; + b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR; + + b->yy_buf_pos = &b->yy_ch_buf[0]; + + b->yy_at_bol = 1; + b->yy_buffer_status = YY_BUFFER_NEW; + + if ( b == YY_CURRENT_BUFFER ) + yy_load_buffer_state( ); +} + +/** Pushes the new state onto the stack. The new state becomes + * the current state. This function will allocate the stack + * if necessary. + * @param new_buffer The new state. + * + */ +void yypush_buffer_state (YY_BUFFER_STATE new_buffer ) +{ + if (new_buffer == NULL) + return; + + yyensure_buffer_stack(); + + /* This block is copied from yy_switch_to_buffer. */ + if ( YY_CURRENT_BUFFER ) + { + /* Flush out information for old buffer. */ + *(yy_c_buf_p) = (yy_hold_char); + YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p); + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); + } + + /* Only push if top exists. Otherwise, replace top. */ + if (YY_CURRENT_BUFFER) + (yy_buffer_stack_top)++; + YY_CURRENT_BUFFER_LVALUE = new_buffer; + + /* copied from yy_switch_to_buffer. */ + yy_load_buffer_state( ); + (yy_did_buffer_switch_on_eof) = 1; +} + +/** Removes and deletes the top of the stack, if present. + * The next element becomes the new top. + * + */ +void yypop_buffer_state (void) +{ + if (!YY_CURRENT_BUFFER) + return; + + yy_delete_buffer(YY_CURRENT_BUFFER ); + YY_CURRENT_BUFFER_LVALUE = NULL; + if ((yy_buffer_stack_top) > 0) + --(yy_buffer_stack_top); + + if (YY_CURRENT_BUFFER) { + yy_load_buffer_state( ); + (yy_did_buffer_switch_on_eof) = 1; + } +} + +/* Allocates the stack if it does not exist. + * Guarantees space for at least one push. + */ +static void yyensure_buffer_stack (void) +{ + int num_to_alloc; + + if (!(yy_buffer_stack)) { + + /* First allocation is just for 2 elements, since we don't know if this + * scanner will even need a stack. We use 2 instead of 1 to avoid an + * immediate realloc on the next call. + */ + num_to_alloc = 1; + (yy_buffer_stack) = (struct yy_buffer_state**)yyalloc + (num_to_alloc * sizeof(struct yy_buffer_state*) + ); + if ( ! (yy_buffer_stack) ) + YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" ); + + memset((yy_buffer_stack), 0, num_to_alloc * sizeof(struct yy_buffer_state*)); + + (yy_buffer_stack_max) = num_to_alloc; + (yy_buffer_stack_top) = 0; + return; + } + + if ((yy_buffer_stack_top) >= ((yy_buffer_stack_max)) - 1){ + + /* Increase the buffer to prepare for a possible push. */ + int grow_size = 8 /* arbitrary grow size */; + + num_to_alloc = (yy_buffer_stack_max) + grow_size; + (yy_buffer_stack) = (struct yy_buffer_state**)yyrealloc + ((yy_buffer_stack), + num_to_alloc * sizeof(struct yy_buffer_state*) + ); + if ( ! (yy_buffer_stack) ) + YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" ); + + /* zero only the new slots.*/ + memset((yy_buffer_stack) + (yy_buffer_stack_max), 0, grow_size * sizeof(struct yy_buffer_state*)); + (yy_buffer_stack_max) = num_to_alloc; + } +} + +/** Setup the input buffer state to scan directly from a user-specified character buffer. + * @param base the character buffer + * @param size the size in bytes of the character buffer + * + * @return the newly allocated buffer state object. + */ +YY_BUFFER_STATE yy_scan_buffer (char * base, yy_size_t size ) +{ + YY_BUFFER_STATE b; + + if ( size < 2 || + base[size-2] != YY_END_OF_BUFFER_CHAR || + base[size-1] != YY_END_OF_BUFFER_CHAR ) + /* They forgot to leave room for the EOB's. */ + return 0; + + b = (YY_BUFFER_STATE) yyalloc(sizeof( struct yy_buffer_state ) ); + if ( ! b ) + YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" ); + + b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */ + b->yy_buf_pos = b->yy_ch_buf = base; + b->yy_is_our_buffer = 0; + b->yy_input_file = 0; + b->yy_n_chars = b->yy_buf_size; + b->yy_is_interactive = 0; + b->yy_at_bol = 1; + b->yy_fill_buffer = 0; + b->yy_buffer_status = YY_BUFFER_NEW; + + yy_switch_to_buffer(b ); + + return b; +} + +/** Setup the input buffer state to scan a string. The next call to yylex() will + * scan from a @e copy of @a str. + * @param yystr a NUL-terminated string to scan + * + * @return the newly allocated buffer state object. + * @note If you want to scan bytes that may contain NUL values, then use + * yy_scan_bytes() instead. + */ +YY_BUFFER_STATE yy_scan_string (yyconst char * yystr ) +{ + + return yy_scan_bytes(yystr,strlen(yystr) ); +} + +/** Setup the input buffer state to scan the given bytes. The next call to yylex() will + * scan from a @e copy of @a bytes. + * @param yybytes the byte buffer to scan + * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes. + * + * @return the newly allocated buffer state object. + */ +YY_BUFFER_STATE yy_scan_bytes (yyconst char * yybytes, int _yybytes_len ) +{ + YY_BUFFER_STATE b; + char *buf; + yy_size_t n; + int i; + + /* Get memory for full buffer, including space for trailing EOB's. */ + n = _yybytes_len + 2; + buf = (char *) yyalloc(n ); + if ( ! buf ) + YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" ); + + for ( i = 0; i < _yybytes_len; ++i ) + buf[i] = yybytes[i]; + + buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR; + + b = yy_scan_buffer(buf,n ); + if ( ! b ) + YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" ); + + /* It's okay to grow etc. this buffer, and we should throw it + * away when we're done. + */ + b->yy_is_our_buffer = 1; + + return b; +} + +#ifndef YY_EXIT_FAILURE +#define YY_EXIT_FAILURE 2 +#endif + +static void yy_fatal_error (yyconst char* msg ) +{ + (void) fprintf( stderr, "%s\n", msg ); + exit( YY_EXIT_FAILURE ); +} + +/* Redefine yyless() so it works in section 3 code. */ + +#undef yyless +#define yyless(n) \ + do \ + { \ + /* Undo effects of setting up yytext. */ \ + int yyless_macro_arg = (n); \ + YY_LESS_LINENO(yyless_macro_arg);\ + yytext[yyleng] = (yy_hold_char); \ + (yy_c_buf_p) = yytext + yyless_macro_arg; \ + (yy_hold_char) = *(yy_c_buf_p); \ + *(yy_c_buf_p) = '\0'; \ + yyleng = yyless_macro_arg; \ + } \ + while ( 0 ) + +/* Accessor methods (get/set functions) to struct members. */ + +/** Get the current line number. + * + */ +int yyget_lineno (void) +{ + + return yylineno; +} + +/** Get the input stream. + * + */ +FILE *yyget_in (void) +{ + return yyin; +} + +/** Get the output stream. + * + */ +FILE *yyget_out (void) +{ + return yyout; +} + +/** Get the length of the current token. + * + */ +int yyget_leng (void) +{ + return yyleng; +} + +/** Get the current token. + * + */ + +char *yyget_text (void) +{ + return yytext; +} + +/** Set the current line number. + * @param line_number + * + */ +void yyset_lineno (int line_number ) +{ + + yylineno = line_number; +} + +/** Set the input stream. This does not discard the current + * input buffer. + * @param in_str A readable stream. + * + * @see yy_switch_to_buffer + */ +void yyset_in (FILE * in_str ) +{ + yyin = in_str ; +} + +void yyset_out (FILE * out_str ) +{ + yyout = out_str ; +} + +int yyget_debug (void) +{ + return yy_flex_debug; +} + +void yyset_debug (int bdebug ) +{ + yy_flex_debug = bdebug ; +} + +static int yy_init_globals (void) +{ + /* Initialization is the same as for the non-reentrant scanner. + * This function is called from yylex_destroy(), so don't allocate here. + */ + + (yy_buffer_stack) = 0; + (yy_buffer_stack_top) = 0; + (yy_buffer_stack_max) = 0; + (yy_c_buf_p) = (char *) 0; + (yy_init) = 0; + (yy_start) = 0; + +/* Defined in main.c */ +#ifdef YY_STDINIT + yyin = stdin; + yyout = stdout; +#else + yyin = (FILE *) 0; + yyout = (FILE *) 0; +#endif + + /* For future reference: Set errno on error, since we are called by + * yylex_init() + */ + return 0; +} + +/* yylex_destroy is for both reentrant and non-reentrant scanners. */ +int yylex_destroy (void) +{ + + /* Pop the buffer stack, destroying each element. */ + while(YY_CURRENT_BUFFER){ + yy_delete_buffer(YY_CURRENT_BUFFER ); + YY_CURRENT_BUFFER_LVALUE = NULL; + yypop_buffer_state(); + } + + /* Destroy the stack itself. */ + yyfree((yy_buffer_stack) ); + (yy_buffer_stack) = NULL; + + /* Reset the globals. This is important in a non-reentrant scanner so the next time + * yylex() is called, initialization will occur. */ + yy_init_globals( ); + + return 0; +} + +/* + * Internal utility routines. + */ + +#ifndef yytext_ptr +static void yy_flex_strncpy (char* s1, yyconst char * s2, int n ) +{ + register int i; + for ( i = 0; i < n; ++i ) + s1[i] = s2[i]; +} +#endif + +#ifdef YY_NEED_STRLEN +static int yy_flex_strlen (yyconst char * s ) +{ + register int n; + for ( n = 0; s[n]; ++n ) + ; + + return n; +} +#endif + +void *yyalloc (yy_size_t size ) +{ + return (void *) malloc( size ); +} + +void *yyrealloc (void * ptr, yy_size_t size ) +{ + /* The cast to (char *) in the following accommodates both + * implementations that use char* generic pointers, and those + * that use void* generic pointers. It works with the latter + * because both ANSI C and C++ allow castless assignment from + * any pointer type to void*, and deal with argument conversions + * as though doing an assignment. + */ + return (void *) realloc( (char *) ptr, size ); +} + +void yyfree (void * ptr ) +{ + free( (char *) ptr ); /* see yyrealloc() for (char *) cast */ +} + +#define YYTABLES_NAME "yytables" + +#line 1143 "psqlscan.l" + + + +/* + * Create a lexer working state struct. + */ +PsqlScanState +psql_scan_create(void) +{ + PsqlScanState state; + + state = (PsqlScanStateData *) pg_malloc_zero(sizeof(PsqlScanStateData)); + + psql_scan_reset(state); + + return state; +} + +/* + * Destroy a lexer working state struct, releasing all resources. + */ +void +psql_scan_destroy(PsqlScanState state) +{ + psql_scan_finish(state); + + psql_scan_reset(state); + + free(state); +} + +/* + * Set up to perform lexing of the given input line. + * + * The text at *line, extending for line_len bytes, will be scanned by + * subsequent calls to the psql_scan routines. psql_scan_finish should + * be called when scanning is complete. Note that the lexer retains + * a pointer to the storage at *line --- this string must not be altered + * or freed until after psql_scan_finish is called. + */ +void +psql_scan_setup(PsqlScanState state, + const char *line, int line_len) +{ + /* Mustn't be scanning already */ + psql_assert(state->scanbufhandle == NULL); + psql_assert(state->buffer_stack == NULL); + + /* Do we need to hack the character set encoding? */ + state->encoding = pset.encoding; + state->safe_encoding = pg_valid_server_encoding_id(state->encoding); + + /* needed for prepare_buffer */ + cur_state = state; + + /* Set up flex input buffer with appropriate translation and padding */ + state->scanbufhandle = prepare_buffer(line, line_len, + &state->scanbuf); + state->scanline = line; + + /* Set lookaside data in case we have to map unsafe encoding */ + state->curline = state->scanbuf; + state->refline = state->scanline; +} + +/* + * Do lexical analysis of SQL command text. + * + * The text previously passed to psql_scan_setup is scanned, and appended + * (possibly with transformation) to query_buf. + * + * The return value indicates the condition that stopped scanning: + * + * PSCAN_SEMICOLON: found a command-ending semicolon. (The semicolon is + * transferred to query_buf.) The command accumulated in query_buf should + * be executed, then clear query_buf and call again to scan the remainder + * of the line. + * + * PSCAN_BACKSLASH: found a backslash that starts a psql special command. + * Any previous data on the line has been transferred to query_buf. + * The caller will typically next call psql_scan_slash_command(), + * perhaps psql_scan_slash_option(), and psql_scan_slash_command_end(). + * + * PSCAN_INCOMPLETE: the end of the line was reached, but we have an + * incomplete SQL command. *prompt is set to the appropriate prompt type. + * + * PSCAN_EOL: the end of the line was reached, and there is no lexical + * reason to consider the command incomplete. The caller may or may not + * choose to send it. *prompt is set to the appropriate prompt type if + * the caller chooses to collect more input. + * + * In the PSCAN_INCOMPLETE and PSCAN_EOL cases, psql_scan_finish() should + * be called next, then the cycle may be repeated with a fresh input line. + * + * In all cases, *prompt is set to an appropriate prompt type code for the + * next line-input operation. + */ +PsqlScanResult +psql_scan(PsqlScanState state, + PQExpBuffer query_buf, + promptStatus_t *prompt) +{ + PsqlScanResult result; + int lexresult; + + /* Must be scanning already */ + psql_assert(state->scanbufhandle); + + /* Set up static variables that will be used by yylex */ + cur_state = state; + output_buf = query_buf; + + if (state->buffer_stack != NULL) + yy_switch_to_buffer(state->buffer_stack->buf); + else + yy_switch_to_buffer(state->scanbufhandle); + + BEGIN(state->start_state); + + /* And lex. */ + lexresult = yylex(); + + /* Update static vars back to the state struct */ + state->start_state = YY_START; + + /* + * Check termination state and return appropriate result info. + */ + switch (lexresult) + { + case LEXRES_EOL: /* end of input */ + switch (state->start_state) + { + /* This switch must cover all non-slash-command states. */ + case INITIAL: + if (state->paren_depth > 0) + { + result = PSCAN_INCOMPLETE; + *prompt = PROMPT_PAREN; + } + else if (query_buf->len > 0) + { + result = PSCAN_EOL; + *prompt = PROMPT_CONTINUE; + } + else + { + /* never bother to send an empty buffer */ + result = PSCAN_INCOMPLETE; + *prompt = PROMPT_READY; + } + break; + case xb: + result = PSCAN_INCOMPLETE; + *prompt = PROMPT_SINGLEQUOTE; + break; + case xc: + result = PSCAN_INCOMPLETE; + *prompt = PROMPT_COMMENT; + break; + case xd: + result = PSCAN_INCOMPLETE; + *prompt = PROMPT_DOUBLEQUOTE; + break; + case xh: + result = PSCAN_INCOMPLETE; + *prompt = PROMPT_SINGLEQUOTE; + break; + case xe: + result = PSCAN_INCOMPLETE; + *prompt = PROMPT_SINGLEQUOTE; + break; + case xq: + result = PSCAN_INCOMPLETE; + *prompt = PROMPT_SINGLEQUOTE; + break; + case xdolq: + result = PSCAN_INCOMPLETE; + *prompt = PROMPT_DOLLARQUOTE; + break; + case xui: + result = PSCAN_INCOMPLETE; + *prompt = PROMPT_DOUBLEQUOTE; + break; + case xus: + result = PSCAN_INCOMPLETE; + *prompt = PROMPT_SINGLEQUOTE; + break; + default: + /* can't get here */ + fprintf(stderr, "invalid YY_START\n"); + exit(1); + } + break; + case LEXRES_SEMI: /* semicolon */ + result = PSCAN_SEMICOLON; + *prompt = PROMPT_READY; + break; + case LEXRES_BACKSLASH: /* backslash */ + result = PSCAN_BACKSLASH; + *prompt = PROMPT_READY; + break; + default: + /* can't get here */ + fprintf(stderr, "invalid yylex result\n"); + exit(1); + } + + return result; +} + +/* + * Clean up after scanning a string. This flushes any unread input and + * releases resources (but not the PsqlScanState itself). Note however + * that this does not reset the lexer scan state; that can be done by + * psql_scan_reset(), which is an orthogonal operation. + * + * It is legal to call this when not scanning anything (makes it easier + * to deal with error recovery). + */ +void +psql_scan_finish(PsqlScanState state) +{ + /* Drop any incomplete variable expansions. */ + while (state->buffer_stack != NULL) + pop_buffer_stack(state); + + /* Done with the outer scan buffer, too */ + if (state->scanbufhandle) + yy_delete_buffer(state->scanbufhandle); + state->scanbufhandle = NULL; + if (state->scanbuf) + free(state->scanbuf); + state->scanbuf = NULL; +} + +/* + * Reset lexer scanning state to start conditions. This is appropriate + * for executing \r psql commands (or any other time that we discard the + * prior contents of query_buf). It is not, however, necessary to do this + * when we execute and clear the buffer after getting a PSCAN_SEMICOLON or + * PSCAN_EOL scan result, because the scan state must be INITIAL when those + * conditions are returned. + * + * Note that this is unrelated to flushing unread input; that task is + * done by psql_scan_finish(). + */ +void +psql_scan_reset(PsqlScanState state) +{ + state->start_state = INITIAL; + state->paren_depth = 0; + state->xcdepth = 0; /* not really necessary */ + if (state->dolqstart) + free(state->dolqstart); + state->dolqstart = NULL; +} + +/* + * Return true if lexer is currently in an "inside quotes" state. + * + * This is pretty grotty but is needed to preserve the old behavior + * that mainloop.c drops blank lines not inside quotes without even + * echoing them. + */ +bool +psql_scan_in_quote(PsqlScanState state) +{ + return state->start_state != INITIAL; +} + +/* + * Scan the command name of a psql backslash command. This should be called + * after psql_scan() returns PSCAN_BACKSLASH. It is assumed that the input + * has been consumed through the leading backslash. + * + * The return value is a malloc'd copy of the command name, as parsed off + * from the input. + */ +char * +psql_scan_slash_command(PsqlScanState state) +{ + PQExpBufferData mybuf; + + /* Must be scanning already */ + psql_assert(state->scanbufhandle); + + /* Build a local buffer that we'll return the data of */ + initPQExpBuffer(&mybuf); + + /* Set up static variables that will be used by yylex */ + cur_state = state; + output_buf = &mybuf; + + if (state->buffer_stack != NULL) + yy_switch_to_buffer(state->buffer_stack->buf); + else + yy_switch_to_buffer(state->scanbufhandle); + + BEGIN(xslashcmd); + + /* And lex. */ + yylex(); + + /* There are no possible errors in this lex state... */ + + return mybuf.data; +} + +/* + * Parse off the next argument for a backslash command, and return it as a + * malloc'd string. If there are no more arguments, returns NULL. + * + * type tells what processing, if any, to perform on the option string; + * for example, if it's a SQL identifier, we want to downcase any unquoted + * letters. + * + * if quote is not NULL, *quote is set to 0 if no quoting was found, else + * the last quote symbol used in the argument. + * + * if semicolon is true, unquoted trailing semicolon(s) that would otherwise + * be taken as part of the option string will be stripped. + * + * NOTE: the only possible syntax errors for backslash options are unmatched + * quotes, which are detected when we run out of input. Therefore, on a + * syntax error we just throw away the string and return NULL; there is no + * need to worry about flushing remaining input. + */ +char * +psql_scan_slash_option(PsqlScanState state, + enum slash_option_type type, + char *quote, + bool semicolon) +{ + PQExpBufferData mybuf; + int lexresult PG_USED_FOR_ASSERTS_ONLY; + char local_quote; + + /* Must be scanning already */ + psql_assert(state->scanbufhandle); + + if (quote == NULL) + quote = &local_quote; + *quote = 0; + + /* Build a local buffer that we'll return the data of */ + initPQExpBuffer(&mybuf); + + /* Set up static variables that will be used by yylex */ + cur_state = state; + output_buf = &mybuf; + option_type = type; + option_quote = quote; + unquoted_option_chars = 0; + + if (state->buffer_stack != NULL) + yy_switch_to_buffer(state->buffer_stack->buf); + else + yy_switch_to_buffer(state->scanbufhandle); + + if (type == OT_WHOLE_LINE) + BEGIN(xslashwholeline); + else + BEGIN(xslashargstart); + + /* And lex. */ + lexresult = yylex(); + + /* + * Check the lex result: we should have gotten back either LEXRES_OK + * or LEXRES_EOL (the latter indicating end of string). If we were inside + * a quoted string, as indicated by YY_START, EOL is an error. + */ + psql_assert(lexresult == LEXRES_EOL || lexresult == LEXRES_OK); + + switch (YY_START) + { + case xslashargstart: + /* empty arg */ + break; + case xslasharg: + /* Strip any unquoted trailing semi-colons if requested */ + if (semicolon) + { + while (unquoted_option_chars-- > 0 && + mybuf.len > 0 && + mybuf.data[mybuf.len - 1] == ';') + { + mybuf.data[--mybuf.len] = '\0'; + } + } + + /* + * If SQL identifier processing was requested, then we strip out + * excess double quotes and downcase unquoted letters. + * Doubled double-quotes become output double-quotes, per spec. + * + * Note that a string like FOO"BAR"BAZ will be converted to + * fooBARbaz; this is somewhat inconsistent with the SQL spec, + * which would have us parse it as several identifiers. But + * for psql's purposes, we want a string like "foo"."bar" to + * be treated as one option, so there's little choice. + */ + if (type == OT_SQLID || type == OT_SQLIDHACK) + { + bool inquotes = false; + char *cp = mybuf.data; + + while (*cp) + { + if (*cp == '"') + { + if (inquotes && cp[1] == '"') + { + /* Keep the first quote, remove the second */ + cp++; + } + inquotes = !inquotes; + /* Collapse out quote at *cp */ + memmove(cp, cp + 1, strlen(cp)); + mybuf.len--; + /* do not advance cp */ + } + else + { + if (!inquotes && type == OT_SQLID) + *cp = pg_tolower((unsigned char) *cp); + cp += PQmblen(cp, pset.encoding); + } + } + } + break; + case xslashquote: + case xslashbackquote: + case xslashdquote: + /* must have hit EOL inside quotes */ + psql_error("unterminated quoted string\n"); + termPQExpBuffer(&mybuf); + return NULL; + case xslashwholeline: + /* always okay */ + break; + default: + /* can't get here */ + fprintf(stderr, "invalid YY_START\n"); + exit(1); + } + + /* + * An unquoted empty argument isn't possible unless we are at end of + * command. Return NULL instead. + */ + if (mybuf.len == 0 && *quote == 0) + { + termPQExpBuffer(&mybuf); + return NULL; + } + + /* Else return the completed string. */ + return mybuf.data; +} + +/* + * Eat up any unused \\ to complete a backslash command. + */ +void +psql_scan_slash_command_end(PsqlScanState state) +{ + /* Must be scanning already */ + psql_assert(state->scanbufhandle); + + /* Set up static variables that will be used by yylex */ + cur_state = state; + output_buf = NULL; + + if (state->buffer_stack != NULL) + yy_switch_to_buffer(state->buffer_stack->buf); + else + yy_switch_to_buffer(state->scanbufhandle); + + BEGIN(xslashend); + + /* And lex. */ + yylex(); + + /* There are no possible errors in this lex state... */ +} + +/* + * Evaluate a backticked substring of a slash command's argument. + * + * The portion of output_buf starting at backtick_start_offset is evaluated + * as a shell command and then replaced by the command's output. + */ +static void +evaluate_backtick(void) +{ + char *cmd = output_buf->data + backtick_start_offset; + PQExpBufferData cmd_output; + FILE *fd; + bool error = false; + char buf[512]; + size_t result; + + initPQExpBuffer(&cmd_output); + + fd = popen(cmd, PG_BINARY_R); + if (!fd) + { + psql_error("%s: %s\n", cmd, strerror(errno)); + error = true; + } + + if (!error) + { + do + { + result = fread(buf, 1, sizeof(buf), fd); + if (ferror(fd)) + { + psql_error("%s: %s\n", cmd, strerror(errno)); + error = true; + break; + } + appendBinaryPQExpBuffer(&cmd_output, buf, result); + } while (!feof(fd)); + } + + if (fd && pclose(fd) == -1) + { + psql_error("%s: %s\n", cmd, strerror(errno)); + error = true; + } + + if (PQExpBufferDataBroken(cmd_output)) + { + psql_error("%s: out of memory\n", cmd); + error = true; + } + + /* Now done with cmd, delete it from output_buf */ + output_buf->len = backtick_start_offset; + output_buf->data[output_buf->len] = '\0'; + + /* If no error, transfer result to output_buf */ + if (!error) + { + /* strip any trailing newline */ + if (cmd_output.len > 0 && + cmd_output.data[cmd_output.len - 1] == '\n') + cmd_output.len--; + appendBinaryPQExpBuffer(output_buf, cmd_output.data, cmd_output.len); + } + + termPQExpBuffer(&cmd_output); +} + +/* + * Push the given string onto the stack of stuff to scan. + * + * cur_state must point to the active PsqlScanState. + * + * NOTE SIDE EFFECT: the new buffer is made the active flex input buffer. + */ +static void +push_new_buffer(const char *newstr, const char *varname) +{ + StackElem *stackelem; + + stackelem = (StackElem *) pg_malloc(sizeof(StackElem)); + + /* + * In current usage, the passed varname points at the current flex + * input buffer; we must copy it before calling prepare_buffer() + * because that will change the buffer state. + */ + stackelem->varname = varname ? pg_strdup(varname) : NULL; + + stackelem->buf = prepare_buffer(newstr, strlen(newstr), + &stackelem->bufstring); + cur_state->curline = stackelem->bufstring; + if (cur_state->safe_encoding) + { + stackelem->origstring = NULL; + cur_state->refline = stackelem->bufstring; + } + else + { + stackelem->origstring = pg_strdup(newstr); + cur_state->refline = stackelem->origstring; + } + stackelem->next = cur_state->buffer_stack; + cur_state->buffer_stack = stackelem; +} + +/* + * Pop the topmost buffer stack item (there must be one!) + * + * NB: after this, the flex input state is unspecified; caller must + * switch to an appropriate buffer to continue lexing. + */ +static void +pop_buffer_stack(PsqlScanState state) +{ + StackElem *stackelem = state->buffer_stack; + + state->buffer_stack = stackelem->next; + yy_delete_buffer(stackelem->buf); + free(stackelem->bufstring); + if (stackelem->origstring) + free(stackelem->origstring); + if (stackelem->varname) + free(stackelem->varname); + free(stackelem); +} + +/* + * Check if specified variable name is the source for any string + * currently being scanned + */ +static bool +var_is_current_source(PsqlScanState state, const char *varname) +{ + StackElem *stackelem; + + for (stackelem = state->buffer_stack; + stackelem != NULL; + stackelem = stackelem->next) + { + if (stackelem->varname && strcmp(stackelem->varname, varname) == 0) + return true; + } + return false; +} + +/* + * Set up a flex input buffer to scan the given data. We always make a + * copy of the data. If working in an unsafe encoding, the copy has + * multibyte sequences replaced by FFs to avoid fooling the lexer rules. + * + * cur_state must point to the active PsqlScanState. + * + * NOTE SIDE EFFECT: the new buffer is made the active flex input buffer. + */ +static YY_BUFFER_STATE +prepare_buffer(const char *txt, int len, char **txtcopy) +{ + char *newtxt; + + /* Flex wants two \0 characters after the actual data */ + newtxt = pg_malloc(len + 2); + *txtcopy = newtxt; + newtxt[len] = newtxt[len + 1] = YY_END_OF_BUFFER_CHAR; + + if (cur_state->safe_encoding) + memcpy(newtxt, txt, len); + else + { + /* Gotta do it the hard way */ + int i = 0; + + while (i < len) + { + int thislen = PQmblen(txt + i, cur_state->encoding); + + /* first byte should always be okay... */ + newtxt[i] = txt[i]; + i++; + while (--thislen > 0 && i < len) + newtxt[i++] = (char) 0xFF; + } + } + + return yy_scan_buffer(newtxt,len + 2); +} + +/* + * emit() --- body for ECHO macro + * + * NB: this must be used for ALL and ONLY the text copied from the flex + * input data. If you pass it something that is not part of the yytext + * string, you are making a mistake. Internally generated text can be + * appended directly to output_buf. + */ +static void +emit(const char *txt, int len) +{ + if (cur_state->safe_encoding) + appendBinaryPQExpBuffer(output_buf, txt, len); + else + { + /* Gotta do it the hard way */ + const char *reference = cur_state->refline; + int i; + + reference += (txt - cur_state->curline); + + for (i = 0; i < len; i++) + { + char ch = txt[i]; + + if (ch == (char) 0xFF) + ch = reference[i]; + appendPQExpBufferChar(output_buf, ch); + } + } +} + +/* + * extract_substring --- fetch the true value of (part of) the current token + * + * This is like emit(), except that the data is returned as a malloc'd string + * rather than being pushed directly to output_buf. + */ +static char * +extract_substring(const char *txt, int len) +{ + char *result = (char *) pg_malloc(len + 1); + + if (cur_state->safe_encoding) + memcpy(result, txt, len); + else + { + /* Gotta do it the hard way */ + const char *reference = cur_state->refline; + int i; + + reference += (txt - cur_state->curline); + + for (i = 0; i < len; i++) + { + char ch = txt[i]; + + if (ch == (char) 0xFF) + ch = reference[i]; + result[i] = ch; + } + } + result[len] = '\0'; + return result; +} + +/* + * escape_variable --- process :'VARIABLE' or :"VARIABLE" + * + * If the variable name is found, escape its value using the appropriate + * quoting method and emit the value to output_buf. (Since the result is + * surely quoted, there is never any reason to rescan it.) If we don't + * find the variable or the escaping function fails, emit the token as-is. + */ +static void +escape_variable(bool as_ident) +{ + char *varname; + const char *value; + + /* Variable lookup. */ + varname = extract_substring(yytext + 2, yyleng - 3); + value = GetVariable(pset.vars, varname); + free(varname); + + /* Escaping. */ + if (value) + { + if (!pset.db) + psql_error("can't escape without active connection\n"); + else + { + char *escaped_value; + + if (as_ident) + escaped_value = + PQescapeIdentifier(pset.db, value, strlen(value)); + else + escaped_value = + PQescapeLiteral(pset.db, value, strlen(value)); + + if (escaped_value == NULL) + { + const char *error = PQerrorMessage(pset.db); + + psql_error("%s", error); + } + else + { + appendPQExpBufferStr(output_buf, escaped_value); + PQfreemem(escaped_value); + return; + } + } + } + + /* + * If we reach this point, some kind of error has occurred. Emit the + * original text into the output buffer. + */ + emit(yytext, yyleng); +} + diff --git a/src/bin/psql/sql_help.c b/src/bin/psql/sql_help.c new file mode 100644 index 000000000..d359e7939 --- /dev/null +++ b/src/bin/psql/sql_help.c @@ -0,0 +1,3346 @@ +/* + * *** Do not change this file by hand. It is automatically + * *** generated from the DocBook documentation. + * + * generated by + * /usr/bin/perl create_help.pl ../../../doc/src/sgml/ref sql_help + * + */ + +#include "sql_help.h" + +void +sql_help_ABORT(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ABORT [ WORK | TRANSACTION ]"); +} + +void +sql_help_ALTER_AGGREGATE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER AGGREGATE %s ( %s [ , ... ] ) RENAME TO %s\n" + "ALTER AGGREGATE %s ( %s [ , ... ] ) OWNER TO %s\n" + "ALTER AGGREGATE %s ( %s [ , ... ] ) SET SCHEMA %s", + _("name"), + _("argtype"), + _("new_name"), + _("name"), + _("argtype"), + _("new_owner"), + _("name"), + _("argtype"), + _("new_schema")); +} + +void +sql_help_ALTER_COLLATION(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER COLLATION %s RENAME TO %s\n" + "ALTER COLLATION %s OWNER TO %s\n" + "ALTER COLLATION %s SET SCHEMA %s", + _("name"), + _("new_name"), + _("name"), + _("new_owner"), + _("name"), + _("new_schema")); +} + +void +sql_help_ALTER_CONVERSION(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER CONVERSION %s RENAME TO %s\n" + "ALTER CONVERSION %s OWNER TO %s\n" + "ALTER CONVERSION %s SET SCHEMA %s", + _("name"), + _("new_name"), + _("name"), + _("new_owner"), + _("name"), + _("new_schema")); +} + +void +sql_help_ALTER_DATABASE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER DATABASE %s [ [ WITH ] %s [ ... ] ]\n" + "\n" + "%s\n" + "\n" + " CONNECTION LIMIT %s\n" + "\n" + "ALTER DATABASE %s RENAME TO %s\n" + "\n" + "ALTER DATABASE %s OWNER TO %s\n" + "\n" + "ALTER DATABASE %s SET TABLESPACE %s\n" + "\n" + "ALTER DATABASE %s SET %s { TO | = } { %s | DEFAULT }\n" + "ALTER DATABASE %s SET %s FROM CURRENT\n" + "ALTER DATABASE %s RESET %s\n" + "ALTER DATABASE %s RESET ALL", + _("name"), + _("option"), + _("where option can be:"), + _("connlimit"), + _("name"), + _("new_name"), + _("name"), + _("new_owner"), + _("name"), + _("new_tablespace"), + _("name"), + _("configuration_parameter"), + _("value"), + _("name"), + _("configuration_parameter"), + _("name"), + _("configuration_parameter"), + _("name")); +} + +void +sql_help_ALTER_DEFAULT_PRIVILEGES(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER DEFAULT PRIVILEGES\n" + " [ FOR { ROLE | USER } %s [, ...] ]\n" + " [ IN SCHEMA %s [, ...] ]\n" + " %s\n" + "\n" + "%s\n" + "\n" + "GRANT { { SELECT | INSERT | UPDATE | DELETE | TRUNCATE | REFERENCES | TRIGGER }\n" + " [, ...] | ALL [ PRIVILEGES ] }\n" + " ON TABLES\n" + " TO { [ GROUP ] %s | PUBLIC } [, ...] [ WITH GRANT OPTION ]\n" + "\n" + "GRANT { { USAGE | SELECT | UPDATE }\n" + " [, ...] | ALL [ PRIVILEGES ] }\n" + " ON SEQUENCES\n" + " TO { [ GROUP ] %s | PUBLIC } [, ...] [ WITH GRANT OPTION ]\n" + "\n" + "GRANT { EXECUTE | ALL [ PRIVILEGES ] }\n" + " ON FUNCTIONS\n" + " TO { [ GROUP ] %s | PUBLIC } [, ...] [ WITH GRANT OPTION ]\n" + "\n" + "GRANT { USAGE | ALL [ PRIVILEGES ] }\n" + " ON TYPES\n" + " TO { [ GROUP ] %s | PUBLIC } [, ...] [ WITH GRANT OPTION ]\n" + "\n" + "REVOKE [ GRANT OPTION FOR ]\n" + " { { SELECT | INSERT | UPDATE | DELETE | TRUNCATE | REFERENCES | TRIGGER }\n" + " [, ...] | ALL [ PRIVILEGES ] }\n" + " ON TABLES\n" + " FROM { [ GROUP ] %s | PUBLIC } [, ...]\n" + " [ CASCADE | RESTRICT ]\n" + "\n" + "REVOKE [ GRANT OPTION FOR ]\n" + " { { USAGE | SELECT | UPDATE }\n" + " [, ...] | ALL [ PRIVILEGES ] }\n" + " ON SEQUENCES\n" + " FROM { [ GROUP ] %s | PUBLIC } [, ...]\n" + " [ CASCADE | RESTRICT ]\n" + "\n" + "REVOKE [ GRANT OPTION FOR ]\n" + " { EXECUTE | ALL [ PRIVILEGES ] }\n" + " ON FUNCTIONS\n" + " FROM { [ GROUP ] %s | PUBLIC } [, ...]\n" + " [ CASCADE | RESTRICT ]\n" + "\n" + "REVOKE [ GRANT OPTION FOR ]\n" + " { USAGE | ALL [ PRIVILEGES ] }\n" + " ON TYPES\n" + " FROM { [ GROUP ] %s | PUBLIC } [, ...]\n" + " [ CASCADE | RESTRICT ]", + _("target_role"), + _("schema_name"), + _("abbreviated_grant_or_revoke"), + _("where abbreviated_grant_or_revoke is one of:"), + _("role_name"), + _("role_name"), + _("role_name"), + _("role_name"), + _("role_name"), + _("role_name"), + _("role_name"), + _("role_name")); +} + +void +sql_help_ALTER_DOMAIN(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER DOMAIN %s\n" + " { SET DEFAULT %s | DROP DEFAULT }\n" + "ALTER DOMAIN %s\n" + " { SET | DROP } NOT NULL\n" + "ALTER DOMAIN %s\n" + " ADD %s [ NOT VALID ]\n" + "ALTER DOMAIN %s\n" + " DROP CONSTRAINT [ IF EXISTS ] %s [ RESTRICT | CASCADE ]\n" + "ALTER DOMAIN %s\n" + " RENAME CONSTRAINT %s TO %s\n" + "ALTER DOMAIN %s\n" + " VALIDATE CONSTRAINT %s\n" + "ALTER DOMAIN %s\n" + " OWNER TO %s\n" + "ALTER DOMAIN %s\n" + " RENAME TO %s\n" + "ALTER DOMAIN %s\n" + " SET SCHEMA %s", + _("name"), + _("expression"), + _("name"), + _("name"), + _("domain_constraint"), + _("name"), + _("constraint_name"), + _("name"), + _("constraint_name"), + _("new_constraint_name"), + _("name"), + _("constraint_name"), + _("name"), + _("new_owner"), + _("name"), + _("new_name"), + _("name"), + _("new_schema")); +} + +void +sql_help_ALTER_EXTENSION(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER EXTENSION %s UPDATE [ TO %s ]\n" + "ALTER EXTENSION %s SET SCHEMA %s\n" + "ALTER EXTENSION %s ADD %s\n" + "ALTER EXTENSION %s DROP %s\n" + "\n" + "%s\n" + "\n" + " AGGREGATE %s (%s [, ...] ) |\n" + " CAST (%s AS %s) |\n" + " COLLATION %s |\n" + " CONVERSION %s |\n" + " DOMAIN %s |\n" + " FOREIGN DATA WRAPPER %s |\n" + " FOREIGN TABLE %s |\n" + " FUNCTION %s ( [ [ %s ] [ %s ] %s [, ...] ] ) |\n" + " OPERATOR %s (%s, %s) |\n" + " OPERATOR CLASS %s USING %s |\n" + " OPERATOR FAMILY %s USING %s |\n" + " [ PROCEDURAL ] LANGUAGE %s |\n" + " SCHEMA %s |\n" + " SEQUENCE %s |\n" + " SERVER %s |\n" + " TABLE %s |\n" + " TEXT SEARCH CONFIGURATION %s |\n" + " TEXT SEARCH DICTIONARY %s |\n" + " TEXT SEARCH PARSER %s |\n" + " TEXT SEARCH TEMPLATE %s |\n" + " TYPE %s |\n" + " VIEW %s", + _("name"), + _("new_version"), + _("name"), + _("new_schema"), + _("name"), + _("member_object"), + _("name"), + _("member_object"), + _("where member_object is:"), + _("agg_name"), + _("agg_type"), + _("source_type"), + _("target_type"), + _("object_name"), + _("object_name"), + _("object_name"), + _("object_name"), + _("object_name"), + _("function_name"), + _("argmode"), + _("argname"), + _("argtype"), + _("operator_name"), + _("left_type"), + _("right_type"), + _("object_name"), + _("index_method"), + _("object_name"), + _("index_method"), + _("object_name"), + _("object_name"), + _("object_name"), + _("object_name"), + _("object_name"), + _("object_name"), + _("object_name"), + _("object_name"), + _("object_name"), + _("object_name"), + _("object_name")); +} + +void +sql_help_ALTER_FOREIGN_DATA_WRAPPER(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER FOREIGN DATA WRAPPER %s\n" + " [ HANDLER %s | NO HANDLER ]\n" + " [ VALIDATOR %s | NO VALIDATOR ]\n" + " [ OPTIONS ( [ ADD | SET | DROP ] %s ['%s'] [, ... ]) ]\n" + "ALTER FOREIGN DATA WRAPPER %s OWNER TO %s\n" + "ALTER FOREIGN DATA WRAPPER %s RENAME TO %s", + _("name"), + _("handler_function"), + _("validator_function"), + _("option"), + _("value"), + _("name"), + _("new_owner"), + _("name"), + _("new_name")); +} + +void +sql_help_ALTER_FOREIGN_TABLE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER FOREIGN TABLE [ IF EXISTS ] %s\n" + " %s [, ... ]\n" + "ALTER FOREIGN TABLE [ IF EXISTS ] %s\n" + " RENAME [ COLUMN ] %s TO %s\n" + "ALTER FOREIGN TABLE [ IF EXISTS ] %s\n" + " RENAME TO %s\n" + "ALTER FOREIGN TABLE [ IF EXISTS ] %s\n" + " SET SCHEMA %s\n" + "\n" + "%s\n" + "\n" + " ADD [ COLUMN ] %s %s [ NULL | NOT NULL ]\n" + " DROP [ COLUMN ] [ IF EXISTS ] %s [ RESTRICT | CASCADE ]\n" + " ALTER [ COLUMN ] %s [ SET DATA ] TYPE %s\n" + " ALTER [ COLUMN ] %s { SET | DROP } NOT NULL\n" + " ALTER [ COLUMN ] %s SET STATISTICS %s\n" + " ALTER [ COLUMN ] %s SET ( %s = %s [, ... ] )\n" + " ALTER [ COLUMN ] %s RESET ( %s [, ... ] )\n" + " ALTER [ COLUMN ] %s OPTIONS ( [ ADD | SET | DROP ] %s ['%s'] [, ... ])\n" + " OWNER TO %s\n" + " OPTIONS ( [ ADD | SET | DROP ] %s ['%s'] [, ... ])", + _("name"), + _("action"), + _("name"), + _("column_name"), + _("new_column_name"), + _("name"), + _("new_name"), + _("name"), + _("new_schema"), + _("where action is one of:"), + _("column_name"), + _("data_type"), + _("column_name"), + _("column_name"), + _("data_type"), + _("column_name"), + _("column_name"), + _("integer"), + _("column_name"), + _("attribute_option"), + _("value"), + _("column_name"), + _("attribute_option"), + _("column_name"), + _("option"), + _("value"), + _("new_owner"), + _("option"), + _("value")); +} + +void +sql_help_ALTER_FUNCTION(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER FUNCTION %s ( [ [ %s ] [ %s ] %s [, ...] ] )\n" + " %s [ ... ] [ RESTRICT ]\n" + "ALTER FUNCTION %s ( [ [ %s ] [ %s ] %s [, ...] ] )\n" + " RENAME TO %s\n" + "ALTER FUNCTION %s ( [ [ %s ] [ %s ] %s [, ...] ] )\n" + " OWNER TO %s\n" + "ALTER FUNCTION %s ( [ [ %s ] [ %s ] %s [, ...] ] )\n" + " SET SCHEMA %s\n" + "\n" + "%s\n" + "\n" + " CALLED ON NULL INPUT | RETURNS NULL ON NULL INPUT | STRICT\n" + " IMMUTABLE | STABLE | VOLATILE | [ NOT ] LEAKPROOF\n" + " [ EXTERNAL ] SECURITY INVOKER | [ EXTERNAL ] SECURITY DEFINER\n" + " COST %s\n" + " ROWS %s\n" + " SET %s { TO | = } { %s | DEFAULT }\n" + " SET %s FROM CURRENT\n" + " RESET %s\n" + " RESET ALL", + _("name"), + _("argmode"), + _("argname"), + _("argtype"), + _("action"), + _("name"), + _("argmode"), + _("argname"), + _("argtype"), + _("new_name"), + _("name"), + _("argmode"), + _("argname"), + _("argtype"), + _("new_owner"), + _("name"), + _("argmode"), + _("argname"), + _("argtype"), + _("new_schema"), + _("where action is one of:"), + _("execution_cost"), + _("result_rows"), + _("configuration_parameter"), + _("value"), + _("configuration_parameter"), + _("configuration_parameter")); +} + +void +sql_help_ALTER_GROUP(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER GROUP %s ADD USER %s [, ... ]\n" + "ALTER GROUP %s DROP USER %s [, ... ]\n" + "\n" + "ALTER GROUP %s RENAME TO %s", + _("group_name"), + _("user_name"), + _("group_name"), + _("user_name"), + _("group_name"), + _("new_name")); +} + +void +sql_help_ALTER_INDEX(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER INDEX [ IF EXISTS ] %s RENAME TO %s\n" + "ALTER INDEX [ IF EXISTS ] %s SET TABLESPACE %s\n" + "ALTER INDEX [ IF EXISTS ] %s SET ( %s = %s [, ... ] )\n" + "ALTER INDEX [ IF EXISTS ] %s RESET ( %s [, ... ] )", + _("name"), + _("new_name"), + _("name"), + _("tablespace_name"), + _("name"), + _("storage_parameter"), + _("value"), + _("name"), + _("storage_parameter")); +} + +void +sql_help_ALTER_LANGUAGE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER [ PROCEDURAL ] LANGUAGE %s RENAME TO %s\n" + "ALTER [ PROCEDURAL ] LANGUAGE %s OWNER TO %s", + _("name"), + _("new_name"), + _("name"), + _("new_owner")); +} + +void +sql_help_ALTER_LARGE_OBJECT(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER LARGE OBJECT %s OWNER TO %s", + _("large_object_oid"), + _("new_owner")); +} + +void +sql_help_ALTER_OPERATOR(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER OPERATOR %s ( { %s | NONE } , { %s | NONE } ) OWNER TO %s\n" + "ALTER OPERATOR %s ( { %s | NONE } , { %s | NONE } ) SET SCHEMA %s", + _("name"), + _("left_type"), + _("right_type"), + _("new_owner"), + _("name"), + _("left_type"), + _("right_type"), + _("new_schema")); +} + +void +sql_help_ALTER_OPERATOR_CLASS(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER OPERATOR CLASS %s USING %s RENAME TO %s\n" + "ALTER OPERATOR CLASS %s USING %s OWNER TO %s\n" + "ALTER OPERATOR CLASS %s USING %s SET SCHEMA %s", + _("name"), + _("index_method"), + _("new_name"), + _("name"), + _("index_method"), + _("new_owner"), + _("name"), + _("index_method"), + _("new_schema")); +} + +void +sql_help_ALTER_OPERATOR_FAMILY(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER OPERATOR FAMILY %s USING %s ADD\n" + " { OPERATOR %s %s ( %s, %s ) [ FOR SEARCH | FOR ORDER BY %s ]\n" + " | FUNCTION %s [ ( %s [ , %s ] ) ] %s ( %s [, ...] )\n" + " } [, ... ]\n" + "ALTER OPERATOR FAMILY %s USING %s DROP\n" + " { OPERATOR %s ( %s [ , %s ] )\n" + " | FUNCTION %s ( %s [ , %s ] )\n" + " } [, ... ]\n" + "ALTER OPERATOR FAMILY %s USING %s RENAME TO %s\n" + "ALTER OPERATOR FAMILY %s USING %s OWNER TO %s\n" + "ALTER OPERATOR FAMILY %s USING %s SET SCHEMA %s", + _("name"), + _("index_method"), + _("strategy_number"), + _("operator_name"), + _("op_type"), + _("op_type"), + _("sort_family_name"), + _("support_number"), + _("op_type"), + _("op_type"), + _("function_name"), + _("argument_type"), + _("name"), + _("index_method"), + _("strategy_number"), + _("op_type"), + _("op_type"), + _("support_number"), + _("op_type"), + _("op_type"), + _("name"), + _("index_method"), + _("new_name"), + _("name"), + _("index_method"), + _("new_owner"), + _("name"), + _("index_method"), + _("new_schema")); +} + +void +sql_help_ALTER_ROLE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER ROLE %s [ [ WITH ] %s [ ... ] ]\n" + "\n" + "%s\n" + "\n" + " SUPERUSER | NOSUPERUSER\n" + " | CREATEDB | NOCREATEDB\n" + " | CREATEROLE | NOCREATEROLE\n" + " | CREATEUSER | NOCREATEUSER\n" + " | INHERIT | NOINHERIT\n" + " | LOGIN | NOLOGIN\n" + " | REPLICATION | NOREPLICATION\n" + " | CONNECTION LIMIT %s\n" + " | [ ENCRYPTED | UNENCRYPTED ] PASSWORD '%s'\n" + " | VALID UNTIL '%s'\n" + "\n" + "ALTER ROLE %s RENAME TO %s\n" + "\n" + "ALTER ROLE %s [ IN DATABASE %s ] SET %s { TO | = } { %s | DEFAULT }\n" + "ALTER ROLE %s [ IN DATABASE %s ] SET %s FROM CURRENT\n" + "ALTER ROLE %s [ IN DATABASE %s ] RESET %s\n" + "ALTER ROLE %s [ IN DATABASE %s ] RESET ALL", + _("name"), + _("option"), + _("where option can be:"), + _("connlimit"), + _("password"), + _("timestamp"), + _("name"), + _("new_name"), + _("name"), + _("database_name"), + _("configuration_parameter"), + _("value"), + _("name"), + _("database_name"), + _("configuration_parameter"), + _("name"), + _("database_name"), + _("configuration_parameter"), + _("name"), + _("database_name")); +} + +void +sql_help_ALTER_SCHEMA(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER SCHEMA %s RENAME TO %s\n" + "ALTER SCHEMA %s OWNER TO %s", + _("name"), + _("new_name"), + _("name"), + _("new_owner")); +} + +void +sql_help_ALTER_SEQUENCE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER SEQUENCE [ IF EXISTS ] %s [ INCREMENT [ BY ] %s ]\n" + " [ MINVALUE %s | NO MINVALUE ] [ MAXVALUE %s | NO MAXVALUE ]\n" + " [ START [ WITH ] %s ]\n" + " [ RESTART [ [ WITH ] %s ] ]\n" + " [ CACHE %s ] [ [ NO ] CYCLE ]\n" + " [ OWNED BY { %s.%s | NONE } ]\n" + "ALTER SEQUENCE [ IF EXISTS ] %s OWNER TO %s\n" + "ALTER SEQUENCE [ IF EXISTS ] %s RENAME TO %s\n" + "ALTER SEQUENCE [ IF EXISTS ] %s SET SCHEMA %s", + _("name"), + _("increment"), + _("minvalue"), + _("maxvalue"), + _("start"), + _("restart"), + _("cache"), + _("table_name"), + _("column_name"), + _("name"), + _("new_owner"), + _("name"), + _("new_name"), + _("name"), + _("new_schema")); +} + +void +sql_help_ALTER_SERVER(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER SERVER %s [ VERSION '%s' ]\n" + " [ OPTIONS ( [ ADD | SET | DROP ] %s ['%s'] [, ... ] ) ]\n" + "ALTER SERVER %s OWNER TO %s\n" + "ALTER SERVER %s RENAME TO %s", + _("name"), + _("new_version"), + _("option"), + _("value"), + _("name"), + _("new_owner"), + _("name"), + _("new_name")); +} + +void +sql_help_ALTER_TABLE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER TABLE [ IF EXISTS ] [ ONLY ] %s [ * ]\n" + " %s [, ... ]\n" + "ALTER TABLE [ IF EXISTS ] [ ONLY ] %s [ * ]\n" + " RENAME [ COLUMN ] %s TO %s\n" + "ALTER TABLE [ IF EXISTS ] [ ONLY ] %s [ * ]\n" + " RENAME CONSTRAINT %s TO %s\n" + "ALTER TABLE [ IF EXISTS ] %s\n" + " RENAME TO %s\n" + "ALTER TABLE [ IF EXISTS ] %s\n" + " SET SCHEMA %s\n" + "\n" + "%s\n" + "\n" + " ADD [ COLUMN ] %s %s [ COLLATE %s ] [ %s [ ... ] ]\n" + " DROP [ COLUMN ] [ IF EXISTS ] %s [ RESTRICT | CASCADE ]\n" + " ALTER [ COLUMN ] %s [ SET DATA ] TYPE %s [ COLLATE %s ] [ USING %s ]\n" + " ALTER [ COLUMN ] %s SET DEFAULT %s\n" + " ALTER [ COLUMN ] %s DROP DEFAULT\n" + " ALTER [ COLUMN ] %s { SET | DROP } NOT NULL\n" + " ALTER [ COLUMN ] %s SET STATISTICS %s\n" + " ALTER [ COLUMN ] %s SET ( %s = %s [, ... ] )\n" + " ALTER [ COLUMN ] %s RESET ( %s [, ... ] )\n" + " ALTER [ COLUMN ] %s SET STORAGE { PLAIN | EXTERNAL | EXTENDED | MAIN }\n" + " ADD %s [ NOT VALID ]\n" + " ADD %s\n" + " VALIDATE CONSTRAINT %s\n" + " DROP CONSTRAINT [ IF EXISTS ] %s [ RESTRICT | CASCADE ]\n" + " DISABLE TRIGGER [ %s | ALL | USER ]\n" + " ENABLE TRIGGER [ %s | ALL | USER ]\n" + " ENABLE REPLICA TRIGGER %s\n" + " ENABLE ALWAYS TRIGGER %s\n" + " DISABLE RULE %s\n" + " ENABLE RULE %s\n" + " ENABLE REPLICA RULE %s\n" + " ENABLE ALWAYS RULE %s\n" + " CLUSTER ON %s\n" + " SET WITHOUT CLUSTER\n" + " SET WITH OIDS\n" + " SET WITHOUT OIDS\n" + " SET ( %s = %s [, ... ] )\n" + " RESET ( %s [, ... ] )\n" + " INHERIT %s\n" + " NO INHERIT %s\n" + " OF %s\n" + " NOT OF\n" + " OWNER TO %s\n" + " SET TABLESPACE %s\n" + "\n" + "%s\n" + "\n" + " [ CONSTRAINT %s ]\n" + " { UNIQUE | PRIMARY KEY } USING INDEX %s\n" + " [ DEFERRABLE | NOT DEFERRABLE ] [ INITIALLY DEFERRED | INITIALLY IMMEDIATE ]", + _("name"), + _("action"), + _("name"), + _("column_name"), + _("new_column_name"), + _("name"), + _("constraint_name"), + _("new_constraint_name"), + _("name"), + _("new_name"), + _("name"), + _("new_schema"), + _("where action is one of:"), + _("column_name"), + _("data_type"), + _("collation"), + _("column_constraint"), + _("column_name"), + _("column_name"), + _("data_type"), + _("collation"), + _("expression"), + _("column_name"), + _("expression"), + _("column_name"), + _("column_name"), + _("column_name"), + _("integer"), + _("column_name"), + _("attribute_option"), + _("value"), + _("column_name"), + _("attribute_option"), + _("column_name"), + _("table_constraint"), + _("table_constraint_using_index"), + _("constraint_name"), + _("constraint_name"), + _("trigger_name"), + _("trigger_name"), + _("trigger_name"), + _("trigger_name"), + _("rewrite_rule_name"), + _("rewrite_rule_name"), + _("rewrite_rule_name"), + _("rewrite_rule_name"), + _("index_name"), + _("storage_parameter"), + _("value"), + _("storage_parameter"), + _("parent_table"), + _("parent_table"), + _("type_name"), + _("new_owner"), + _("new_tablespace"), + _("and table_constraint_using_index is:"), + _("constraint_name"), + _("index_name")); +} + +void +sql_help_ALTER_TABLESPACE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER TABLESPACE %s RENAME TO %s\n" + "ALTER TABLESPACE %s OWNER TO %s\n" + "ALTER TABLESPACE %s SET ( %s = %s [, ... ] )\n" + "ALTER TABLESPACE %s RESET ( %s [, ... ] )", + _("name"), + _("new_name"), + _("name"), + _("new_owner"), + _("name"), + _("tablespace_option"), + _("value"), + _("name"), + _("tablespace_option")); +} + +void +sql_help_ALTER_TEXT_SEARCH_CONFIGURATION(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER TEXT SEARCH CONFIGURATION %s\n" + " ADD MAPPING FOR %s [, ... ] WITH %s [, ... ]\n" + "ALTER TEXT SEARCH CONFIGURATION %s\n" + " ALTER MAPPING FOR %s [, ... ] WITH %s [, ... ]\n" + "ALTER TEXT SEARCH CONFIGURATION %s\n" + " ALTER MAPPING REPLACE %s WITH %s\n" + "ALTER TEXT SEARCH CONFIGURATION %s\n" + " ALTER MAPPING FOR %s [, ... ] REPLACE %s WITH %s\n" + "ALTER TEXT SEARCH CONFIGURATION %s\n" + " DROP MAPPING [ IF EXISTS ] FOR %s [, ... ]\n" + "ALTER TEXT SEARCH CONFIGURATION %s RENAME TO %s\n" + "ALTER TEXT SEARCH CONFIGURATION %s OWNER TO %s\n" + "ALTER TEXT SEARCH CONFIGURATION %s SET SCHEMA %s", + _("name"), + _("token_type"), + _("dictionary_name"), + _("name"), + _("token_type"), + _("dictionary_name"), + _("name"), + _("old_dictionary"), + _("new_dictionary"), + _("name"), + _("token_type"), + _("old_dictionary"), + _("new_dictionary"), + _("name"), + _("token_type"), + _("name"), + _("new_name"), + _("name"), + _("new_owner"), + _("name"), + _("new_schema")); +} + +void +sql_help_ALTER_TEXT_SEARCH_DICTIONARY(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER TEXT SEARCH DICTIONARY %s (\n" + " %s [ = %s ] [, ... ]\n" + ")\n" + "ALTER TEXT SEARCH DICTIONARY %s RENAME TO %s\n" + "ALTER TEXT SEARCH DICTIONARY %s OWNER TO %s\n" + "ALTER TEXT SEARCH DICTIONARY %s SET SCHEMA %s", + _("name"), + _("option"), + _("value"), + _("name"), + _("new_name"), + _("name"), + _("new_owner"), + _("name"), + _("new_schema")); +} + +void +sql_help_ALTER_TEXT_SEARCH_PARSER(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER TEXT SEARCH PARSER %s RENAME TO %s\n" + "ALTER TEXT SEARCH PARSER %s SET SCHEMA %s", + _("name"), + _("new_name"), + _("name"), + _("new_schema")); +} + +void +sql_help_ALTER_TEXT_SEARCH_TEMPLATE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER TEXT SEARCH TEMPLATE %s RENAME TO %s\n" + "ALTER TEXT SEARCH TEMPLATE %s SET SCHEMA %s", + _("name"), + _("new_name"), + _("name"), + _("new_schema")); +} + +void +sql_help_ALTER_TRIGGER(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER TRIGGER %s ON %s RENAME TO %s", + _("name"), + _("table_name"), + _("new_name")); +} + +void +sql_help_ALTER_TYPE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER TYPE %s %s [, ... ]\n" + "ALTER TYPE %s OWNER TO %s\n" + "ALTER TYPE %s RENAME ATTRIBUTE %s TO %s\n" + "ALTER TYPE %s RENAME TO %s [ CASCADE | RESTRICT ]\n" + "ALTER TYPE %s SET SCHEMA %s\n" + "ALTER TYPE %s ADD VALUE %s [ { BEFORE | AFTER } %s ]\n" + "\n" + "%s\n" + "\n" + " ADD ATTRIBUTE %s %s [ COLLATE %s ] [ CASCADE | RESTRICT ]\n" + " DROP ATTRIBUTE [ IF EXISTS ] %s [ CASCADE | RESTRICT ]\n" + " ALTER ATTRIBUTE %s [ SET DATA ] TYPE %s [ COLLATE %s ] [ CASCADE | RESTRICT ]", + _("name"), + _("action"), + _("name"), + _("new_owner"), + _("name"), + _("attribute_name"), + _("new_attribute_name"), + _("name"), + _("new_name"), + _("name"), + _("new_schema"), + _("name"), + _("new_enum_value"), + _("existing_enum_value"), + _("where action is one of:"), + _("attribute_name"), + _("data_type"), + _("collation"), + _("attribute_name"), + _("attribute_name"), + _("data_type"), + _("collation")); +} + +void +sql_help_ALTER_USER(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER USER %s [ [ WITH ] %s [ ... ] ]\n" + "\n" + "%s\n" + "\n" + " SUPERUSER | NOSUPERUSER\n" + " | CREATEDB | NOCREATEDB\n" + " | CREATEROLE | NOCREATEROLE\n" + " | CREATEUSER | NOCREATEUSER\n" + " | INHERIT | NOINHERIT\n" + " | LOGIN | NOLOGIN\n" + " | REPLICATION | NOREPLICATION\n" + " | CONNECTION LIMIT %s\n" + " | [ ENCRYPTED | UNENCRYPTED ] PASSWORD '%s'\n" + " | VALID UNTIL '%s'\n" + "\n" + "ALTER USER %s RENAME TO %s\n" + "\n" + "ALTER USER %s SET %s { TO | = } { %s | DEFAULT }\n" + "ALTER USER %s SET %s FROM CURRENT\n" + "ALTER USER %s RESET %s\n" + "ALTER USER %s RESET ALL", + _("name"), + _("option"), + _("where option can be:"), + _("connlimit"), + _("password"), + _("timestamp"), + _("name"), + _("new_name"), + _("name"), + _("configuration_parameter"), + _("value"), + _("name"), + _("configuration_parameter"), + _("name"), + _("configuration_parameter"), + _("name")); +} + +void +sql_help_ALTER_USER_MAPPING(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER USER MAPPING FOR { %s | USER | CURRENT_USER | PUBLIC }\n" + " SERVER %s\n" + " OPTIONS ( [ ADD | SET | DROP ] %s ['%s'] [, ... ] )", + _("user_name"), + _("server_name"), + _("option"), + _("value")); +} + +void +sql_help_ALTER_VIEW(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ALTER VIEW [ IF EXISTS ] %s ALTER [ COLUMN ] %s SET DEFAULT %s\n" + "ALTER VIEW [ IF EXISTS ] %s ALTER [ COLUMN ] %s DROP DEFAULT\n" + "ALTER VIEW [ IF EXISTS ] %s OWNER TO %s\n" + "ALTER VIEW [ IF EXISTS ] %s RENAME TO %s\n" + "ALTER VIEW [ IF EXISTS ] %s SET SCHEMA %s\n" + "ALTER VIEW [ IF EXISTS ] %s SET ( %s [= %s] [, ... ] )\n" + "ALTER VIEW [ IF EXISTS ] %s RESET ( %s [, ... ] )", + _("name"), + _("column_name"), + _("expression"), + _("name"), + _("column_name"), + _("name"), + _("new_owner"), + _("name"), + _("new_name"), + _("name"), + _("new_schema"), + _("name"), + _("view_option_name"), + _("view_option_value"), + _("name"), + _("view_option_name")); +} + +void +sql_help_ANALYZE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ANALYZE [ VERBOSE ] [ %s [ ( %s [, ...] ) ] ]", + _("table_name"), + _("column_name")); +} + +void +sql_help_BEGIN(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "BEGIN [ WORK | TRANSACTION ] [ %s [, ...] ]\n" + "\n" + "%s\n" + "\n" + " ISOLATION LEVEL { SERIALIZABLE | REPEATABLE READ | READ COMMITTED | READ UNCOMMITTED }\n" + " READ WRITE | READ ONLY\n" + " [ NOT ] DEFERRABLE", + _("transaction_mode"), + _("where transaction_mode is one of:")); +} + +void +sql_help_CHECKPOINT(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CHECKPOINT"); +} + +void +sql_help_CLOSE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CLOSE { %s | ALL }", + _("name")); +} + +void +sql_help_CLUSTER(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CLUSTER [VERBOSE] %s [ USING %s ]\n" + "CLUSTER [VERBOSE]", + _("table_name"), + _("index_name")); +} + +void +sql_help_COMMENT(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "COMMENT ON\n" + "{\n" + " AGGREGATE %s (%s [, ...] ) |\n" + " CAST (%s AS %s) |\n" + " COLLATION %s |\n" + " COLUMN %s.%s |\n" + " CONSTRAINT %s ON %s |\n" + " CONVERSION %s |\n" + " DATABASE %s |\n" + " DOMAIN %s |\n" + " EXTENSION %s |\n" + " FOREIGN DATA WRAPPER %s |\n" + " FOREIGN TABLE %s |\n" + " FUNCTION %s ( [ [ %s ] [ %s ] %s [, ...] ] ) |\n" + " INDEX %s |\n" + " LARGE OBJECT %s |\n" + " OPERATOR %s (%s, %s) |\n" + " OPERATOR CLASS %s USING %s |\n" + " OPERATOR FAMILY %s USING %s |\n" + " [ PROCEDURAL ] LANGUAGE %s |\n" + " ROLE %s |\n" + " RULE %s ON %s |\n" + " SCHEMA %s |\n" + " SEQUENCE %s |\n" + " SERVER %s |\n" + " TABLE %s |\n" + " TABLESPACE %s |\n" + " TEXT SEARCH CONFIGURATION %s |\n" + " TEXT SEARCH DICTIONARY %s |\n" + " TEXT SEARCH PARSER %s |\n" + " TEXT SEARCH TEMPLATE %s |\n" + " TRIGGER %s ON %s |\n" + " TYPE %s |\n" + " VIEW %s\n" + "} IS '%s'", + _("agg_name"), + _("agg_type"), + _("source_type"), + _("target_type"), + _("object_name"), + _("relation_name"), + _("column_name"), + _("constraint_name"), + _("table_name"), + _("object_name"), + _("object_name"), + _("object_name"), + _("object_name"), + _("object_name"), + _("object_name"), + _("function_name"), + _("argmode"), + _("argname"), + _("argtype"), + _("object_name"), + _("large_object_oid"), + _("operator_name"), + _("left_type"), + _("right_type"), + _("object_name"), + _("index_method"), + _("object_name"), + _("index_method"), + _("object_name"), + _("object_name"), + _("rule_name"), + _("table_name"), + _("object_name"), + _("object_name"), + _("object_name"), + _("object_name"), + _("object_name"), + _("object_name"), + _("object_name"), + _("object_name"), + _("object_name"), + _("trigger_name"), + _("table_name"), + _("object_name"), + _("object_name"), + _("text")); +} + +void +sql_help_COMMIT(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "COMMIT [ WORK | TRANSACTION ]"); +} + +void +sql_help_COMMIT_PREPARED(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "COMMIT PREPARED %s", + _("transaction_id")); +} + +void +sql_help_COPY(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "COPY %s [ ( %s [, ...] ) ]\n" + " FROM { '%s' | STDIN }\n" + " [ [ WITH ] ( %s [, ...] ) ]\n" + "\n" + "COPY { %s [ ( %s [, ...] ) ] | ( %s ) }\n" + " TO { '%s' | STDOUT }\n" + " [ [ WITH ] ( %s [, ...] ) ]\n" + "\n" + "%s\n" + "\n" + " FORMAT %s\n" + " OIDS [ %s ]\n" + " DELIMITER '%s'\n" + " NULL '%s'\n" + " HEADER [ %s ]\n" + " QUOTE '%s'\n" + " ESCAPE '%s'\n" + " FORCE_QUOTE { ( %s [, ...] ) | * }\n" + " FORCE_NOT_NULL ( %s [, ...] ) |\n" + " ENCODING '%s'", + _("table_name"), + _("column_name"), + _("filename"), + _("option"), + _("table_name"), + _("column_name"), + _("query"), + _("filename"), + _("option"), + _("where option can be one of:"), + _("format_name"), + _("boolean"), + _("delimiter_character"), + _("null_string"), + _("boolean"), + _("quote_character"), + _("escape_character"), + _("column_name"), + _("column_name"), + _("encoding_name")); +} + +void +sql_help_CREATE_AGGREGATE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE AGGREGATE %s ( %s [ , ... ] ) (\n" + " SFUNC = %s,\n" + " STYPE = %s\n" + " [ , FINALFUNC = %s ]\n" + " [ , INITCOND = %s ]\n" + " [ , SORTOP = %s ]\n" + ")\n" + "\n" + "%s\n" + "\n" + "CREATE AGGREGATE %s (\n" + " BASETYPE = %s,\n" + " SFUNC = %s,\n" + " STYPE = %s\n" + " [ , FINALFUNC = %s ]\n" + " [ , INITCOND = %s ]\n" + " [ , SORTOP = %s ]\n" + ")", + _("name"), + _("input_data_type"), + _("sfunc"), + _("state_data_type"), + _("ffunc"), + _("initial_condition"), + _("sort_operator"), + _("or the old syntax"), + _("name"), + _("base_type"), + _("sfunc"), + _("state_data_type"), + _("ffunc"), + _("initial_condition"), + _("sort_operator")); +} + +void +sql_help_CREATE_CAST(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE CAST (%s AS %s)\n" + " WITH FUNCTION %s (%s [, ...])\n" + " [ AS ASSIGNMENT | AS IMPLICIT ]\n" + "\n" + "CREATE CAST (%s AS %s)\n" + " WITHOUT FUNCTION\n" + " [ AS ASSIGNMENT | AS IMPLICIT ]\n" + "\n" + "CREATE CAST (%s AS %s)\n" + " WITH INOUT\n" + " [ AS ASSIGNMENT | AS IMPLICIT ]", + _("source_type"), + _("target_type"), + _("function_name"), + _("argument_type"), + _("source_type"), + _("target_type"), + _("source_type"), + _("target_type")); +} + +void +sql_help_CREATE_COLLATION(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE COLLATION %s (\n" + " [ LOCALE = %s, ]\n" + " [ LC_COLLATE = %s, ]\n" + " [ LC_CTYPE = %s ]\n" + ")\n" + "CREATE COLLATION %s FROM %s", + _("name"), + _("locale"), + _("lc_collate"), + _("lc_ctype"), + _("name"), + _("existing_collation")); +} + +void +sql_help_CREATE_CONVERSION(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE [ DEFAULT ] CONVERSION %s\n" + " FOR %s TO %s FROM %s", + _("name"), + _("source_encoding"), + _("dest_encoding"), + _("function_name")); +} + +void +sql_help_CREATE_DATABASE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE DATABASE %s\n" + " [ [ WITH ] [ OWNER [=] %s ]\n" + " [ TEMPLATE [=] %s ]\n" + " [ ENCODING [=] %s ]\n" + " [ LC_COLLATE [=] %s ]\n" + " [ LC_CTYPE [=] %s ]\n" + " [ TABLESPACE [=] %s ]\n" + " [ CONNECTION LIMIT [=] %s ] ]", + _("name"), + _("user_name"), + _("template"), + _("encoding"), + _("lc_collate"), + _("lc_ctype"), + _("tablespace_name"), + _("connlimit")); +} + +void +sql_help_CREATE_DOMAIN(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE DOMAIN %s [ AS ] %s\n" + " [ COLLATE %s ]\n" + " [ DEFAULT %s ]\n" + " [ %s [ ... ] ]\n" + "\n" + "%s\n" + "\n" + "[ CONSTRAINT %s ]\n" + "{ NOT NULL | NULL | CHECK (%s) }", + _("name"), + _("data_type"), + _("collation"), + _("expression"), + _("constraint"), + _("where constraint is:"), + _("constraint_name"), + _("expression")); +} + +void +sql_help_CREATE_EXTENSION(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE EXTENSION [ IF NOT EXISTS ] %s\n" + " [ WITH ] [ SCHEMA %s ]\n" + " [ VERSION %s ]\n" + " [ FROM %s ]", + _("extension_name"), + _("schema_name"), + _("version"), + _("old_version")); +} + +void +sql_help_CREATE_FOREIGN_DATA_WRAPPER(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE FOREIGN DATA WRAPPER %s\n" + " [ HANDLER %s | NO HANDLER ]\n" + " [ VALIDATOR %s | NO VALIDATOR ]\n" + " [ OPTIONS ( %s '%s' [, ... ] ) ]", + _("name"), + _("handler_function"), + _("validator_function"), + _("option"), + _("value")); +} + +void +sql_help_CREATE_FOREIGN_TABLE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE FOREIGN TABLE [ IF NOT EXISTS ] %s ( [\n" + " { %s %s [ OPTIONS ( %s '%s' [, ... ] ) ] [ NULL | NOT NULL ] }\n" + " [, ... ]\n" + "] )\n" + " SERVER %s\n" + "[ OPTIONS ( %s '%s' [, ... ] ) ]", + _("table_name"), + _("column_name"), + _("data_type"), + _("option"), + _("value"), + _("server_name"), + _("option"), + _("value")); +} + +void +sql_help_CREATE_FUNCTION(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE [ OR REPLACE ] FUNCTION\n" + " %s ( [ [ %s ] [ %s ] %s [ { DEFAULT | = } %s ] [, ...] ] )\n" + " [ RETURNS %s\n" + " | RETURNS TABLE ( %s %s [, ...] ) ]\n" + " { LANGUAGE %s\n" + " | WINDOW\n" + " | IMMUTABLE | STABLE | VOLATILE | [ NOT ] LEAKPROOF\n" + " | CALLED ON NULL INPUT | RETURNS NULL ON NULL INPUT | STRICT\n" + " | [ EXTERNAL ] SECURITY INVOKER | [ EXTERNAL ] SECURITY DEFINER\n" + " | COST %s\n" + " | ROWS %s\n" + " | SET %s { TO %s | = %s | FROM CURRENT }\n" + " | AS '%s'\n" + " | AS '%s', '%s'\n" + " } ...\n" + " [ WITH ( %s [, ...] ) ]", + _("name"), + _("argmode"), + _("argname"), + _("argtype"), + _("default_expr"), + _("rettype"), + _("column_name"), + _("column_type"), + _("lang_name"), + _("execution_cost"), + _("result_rows"), + _("configuration_parameter"), + _("value"), + _("value"), + _("definition"), + _("obj_file"), + _("link_symbol"), + _("attribute")); +} + +void +sql_help_CREATE_GROUP(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE GROUP %s [ [ WITH ] %s [ ... ] ]\n" + "\n" + "%s\n" + "\n" + " SUPERUSER | NOSUPERUSER\n" + " | CREATEDB | NOCREATEDB\n" + " | CREATEROLE | NOCREATEROLE\n" + " | CREATEUSER | NOCREATEUSER\n" + " | INHERIT | NOINHERIT\n" + " | LOGIN | NOLOGIN\n" + " | [ ENCRYPTED | UNENCRYPTED ] PASSWORD '%s'\n" + " | VALID UNTIL '%s'\n" + " | IN ROLE %s [, ...]\n" + " | IN GROUP %s [, ...]\n" + " | ROLE %s [, ...]\n" + " | ADMIN %s [, ...]\n" + " | USER %s [, ...]\n" + " | SYSID %s", + _("name"), + _("option"), + _("where option can be:"), + _("password"), + _("timestamp"), + _("role_name"), + _("role_name"), + _("role_name"), + _("role_name"), + _("role_name"), + _("uid")); +} + +void +sql_help_CREATE_INDEX(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE [ UNIQUE ] INDEX [ CONCURRENTLY ] [ %s ] ON %s [ USING %s ]\n" + " ( { %s | ( %s ) } [ COLLATE %s ] [ %s ] [ ASC | DESC ] [ NULLS { FIRST | LAST } ] [, ...] )\n" + " [ WITH ( %s = %s [, ... ] ) ]\n" + " [ TABLESPACE %s ]\n" + " [ WHERE %s ]", + _("name"), + _("table_name"), + _("method"), + _("column_name"), + _("expression"), + _("collation"), + _("opclass"), + _("storage_parameter"), + _("value"), + _("tablespace_name"), + _("predicate")); +} + +void +sql_help_CREATE_LANGUAGE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE [ OR REPLACE ] [ PROCEDURAL ] LANGUAGE %s\n" + "CREATE [ OR REPLACE ] [ TRUSTED ] [ PROCEDURAL ] LANGUAGE %s\n" + " HANDLER %s [ INLINE %s ] [ VALIDATOR %s ]", + _("name"), + _("name"), + _("call_handler"), + _("inline_handler"), + _("valfunction")); +} + +void +sql_help_CREATE_OPERATOR(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE OPERATOR %s (\n" + " PROCEDURE = %s\n" + " [, LEFTARG = %s ] [, RIGHTARG = %s ]\n" + " [, COMMUTATOR = %s ] [, NEGATOR = %s ]\n" + " [, RESTRICT = %s ] [, JOIN = %s ]\n" + " [, HASHES ] [, MERGES ]\n" + ")", + _("name"), + _("function_name"), + _("left_type"), + _("right_type"), + _("com_op"), + _("neg_op"), + _("res_proc"), + _("join_proc")); +} + +void +sql_help_CREATE_OPERATOR_CLASS(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE OPERATOR CLASS %s [ DEFAULT ] FOR TYPE %s\n" + " USING %s [ FAMILY %s ] AS\n" + " { OPERATOR %s %s [ ( %s, %s ) ] [ FOR SEARCH | FOR ORDER BY %s ]\n" + " | FUNCTION %s [ ( %s [ , %s ] ) ] %s ( %s [, ...] )\n" + " | STORAGE %s\n" + " } [, ... ]", + _("name"), + _("data_type"), + _("index_method"), + _("family_name"), + _("strategy_number"), + _("operator_name"), + _("op_type"), + _("op_type"), + _("sort_family_name"), + _("support_number"), + _("op_type"), + _("op_type"), + _("function_name"), + _("argument_type"), + _("storage_type")); +} + +void +sql_help_CREATE_OPERATOR_FAMILY(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE OPERATOR FAMILY %s USING %s", + _("name"), + _("index_method")); +} + +void +sql_help_CREATE_ROLE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE ROLE %s [ [ WITH ] %s [ ... ] ]\n" + "\n" + "%s\n" + "\n" + " SUPERUSER | NOSUPERUSER\n" + " | CREATEDB | NOCREATEDB\n" + " | CREATEROLE | NOCREATEROLE\n" + " | CREATEUSER | NOCREATEUSER\n" + " | INHERIT | NOINHERIT\n" + " | LOGIN | NOLOGIN\n" + " | REPLICATION | NOREPLICATION\n" + " | CONNECTION LIMIT %s\n" + " | [ ENCRYPTED | UNENCRYPTED ] PASSWORD '%s'\n" + " | VALID UNTIL '%s'\n" + " | IN ROLE %s [, ...]\n" + " | IN GROUP %s [, ...]\n" + " | ROLE %s [, ...]\n" + " | ADMIN %s [, ...]\n" + " | USER %s [, ...]\n" + " | SYSID %s", + _("name"), + _("option"), + _("where option can be:"), + _("connlimit"), + _("password"), + _("timestamp"), + _("role_name"), + _("role_name"), + _("role_name"), + _("role_name"), + _("role_name"), + _("uid")); +} + +void +sql_help_CREATE_RULE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE [ OR REPLACE ] RULE %s AS ON %s\n" + " TO %s [ WHERE %s ]\n" + " DO [ ALSO | INSTEAD ] { NOTHING | %s | ( %s ; %s ... ) }", + _("name"), + _("event"), + _("table_name"), + _("condition"), + _("command"), + _("command"), + _("command")); +} + +void +sql_help_CREATE_SCHEMA(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE SCHEMA %s [ AUTHORIZATION %s ] [ %s [ ... ] ]\n" + "CREATE SCHEMA AUTHORIZATION %s [ %s [ ... ] ]", + _("schema_name"), + _("user_name"), + _("schema_element"), + _("user_name"), + _("schema_element")); +} + +void +sql_help_CREATE_SEQUENCE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE [ TEMPORARY | TEMP ] SEQUENCE %s [ INCREMENT [ BY ] %s ]\n" + " [ MINVALUE %s | NO MINVALUE ] [ MAXVALUE %s | NO MAXVALUE ]\n" + " [ START [ WITH ] %s ] [ CACHE %s ] [ [ NO ] CYCLE ]\n" + " [ OWNED BY { %s.%s | NONE } ]", + _("name"), + _("increment"), + _("minvalue"), + _("maxvalue"), + _("start"), + _("cache"), + _("table_name"), + _("column_name")); +} + +void +sql_help_CREATE_SERVER(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE SERVER %s [ TYPE '%s' ] [ VERSION '%s' ]\n" + " FOREIGN DATA WRAPPER %s\n" + " [ OPTIONS ( %s '%s' [, ... ] ) ]", + _("server_name"), + _("server_type"), + _("server_version"), + _("fdw_name"), + _("option"), + _("value")); +} + +void +sql_help_CREATE_TABLE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE [ [ GLOBAL | LOCAL ] { TEMPORARY | TEMP } | UNLOGGED ] TABLE [ IF NOT EXISTS ] %s ( [\n" + " { %s %s [ COLLATE %s ] [ %s [ ... ] ]\n" + " | %s\n" + " | LIKE %s [ %s ... ] }\n" + " [, ... ]\n" + "] )\n" + "[ INHERITS ( %s [, ... ] ) ]\n" + "[ WITH ( %s [= %s] [, ... ] ) | WITH OIDS | WITHOUT OIDS ]\n" + "[ ON COMMIT { PRESERVE ROWS | DELETE ROWS | DROP } ]\n" + "[ TABLESPACE %s ]\n" + "\n" + "CREATE [ [ GLOBAL | LOCAL ] { TEMPORARY | TEMP } | UNLOGGED ] TABLE [ IF NOT EXISTS ] %s\n" + " OF %s [ (\n" + " { %s WITH OPTIONS [ %s [ ... ] ]\n" + " | %s }\n" + " [, ... ]\n" + ") ]\n" + "[ WITH ( %s [= %s] [, ... ] ) | WITH OIDS | WITHOUT OIDS ]\n" + "[ ON COMMIT { PRESERVE ROWS | DELETE ROWS | DROP } ]\n" + "[ TABLESPACE %s ]\n" + "\n" + "%s\n" + "\n" + "[ CONSTRAINT %s ]\n" + "{ NOT NULL |\n" + " NULL |\n" + " CHECK ( %s ) [ NO INHERIT ] |\n" + " DEFAULT %s |\n" + " UNIQUE %s |\n" + " PRIMARY KEY %s |\n" + " REFERENCES %s [ ( %s ) ] [ MATCH FULL | MATCH PARTIAL | MATCH SIMPLE ]\n" + " [ ON DELETE %s ] [ ON UPDATE %s ] }\n" + "[ DEFERRABLE | NOT DEFERRABLE ] [ INITIALLY DEFERRED | INITIALLY IMMEDIATE ]\n" + "\n" + "%s\n" + "\n" + "[ CONSTRAINT %s ]\n" + "{ CHECK ( %s ) [ NO INHERIT ] |\n" + " UNIQUE ( %s [, ... ] ) %s |\n" + " PRIMARY KEY ( %s [, ... ] ) %s |\n" + " EXCLUDE [ USING %s ] ( %s WITH %s [, ... ] ) %s [ WHERE ( %s ) ] |\n" + " FOREIGN KEY ( %s [, ... ] ) REFERENCES %s [ ( %s [, ... ] ) ]\n" + " [ MATCH FULL | MATCH PARTIAL | MATCH SIMPLE ] [ ON DELETE %s ] [ ON UPDATE %s ] }\n" + "[ DEFERRABLE | NOT DEFERRABLE ] [ INITIALLY DEFERRED | INITIALLY IMMEDIATE ]\n" + "\n" + "%s\n" + "\n" + "{ INCLUDING | EXCLUDING } { DEFAULTS | CONSTRAINTS | INDEXES | STORAGE | COMMENTS | ALL }\n" + "\n" + "%s\n" + "\n" + "[ WITH ( %s [= %s] [, ... ] ) ]\n" + "[ USING INDEX TABLESPACE %s ]\n" + "\n" + "%s\n" + "\n" + "{ %s | ( %s ) } [ %s ] [ ASC | DESC ] [ NULLS { FIRST | LAST } ]", + _("table_name"), + _("column_name"), + _("data_type"), + _("collation"), + _("column_constraint"), + _("table_constraint"), + _("source_table"), + _("like_option"), + _("parent_table"), + _("storage_parameter"), + _("value"), + _("tablespace_name"), + _("table_name"), + _("type_name"), + _("column_name"), + _("column_constraint"), + _("table_constraint"), + _("storage_parameter"), + _("value"), + _("tablespace_name"), + _("where column_constraint is:"), + _("constraint_name"), + _("expression"), + _("default_expr"), + _("index_parameters"), + _("index_parameters"), + _("reftable"), + _("refcolumn"), + _("action"), + _("action"), + _("and table_constraint is:"), + _("constraint_name"), + _("expression"), + _("column_name"), + _("index_parameters"), + _("column_name"), + _("index_parameters"), + _("index_method"), + _("exclude_element"), + _("operator"), + _("index_parameters"), + _("predicate"), + _("column_name"), + _("reftable"), + _("refcolumn"), + _("action"), + _("action"), + _("and like_option is:"), + _("index_parameters in UNIQUE, PRIMARY KEY, and EXCLUDE constraints are:"), + _("storage_parameter"), + _("value"), + _("tablespace_name"), + _("exclude_element in an EXCLUDE constraint is:"), + _("column_name"), + _("expression"), + _("opclass")); +} + +void +sql_help_CREATE_TABLE_AS(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE [ [ GLOBAL | LOCAL ] { TEMPORARY | TEMP } | UNLOGGED ] TABLE %s\n" + " [ (%s [, ...] ) ]\n" + " [ WITH ( %s [= %s] [, ... ] ) | WITH OIDS | WITHOUT OIDS ]\n" + " [ ON COMMIT { PRESERVE ROWS | DELETE ROWS | DROP } ]\n" + " [ TABLESPACE %s ]\n" + " AS %s\n" + " [ WITH [ NO ] DATA ]", + _("table_name"), + _("column_name"), + _("storage_parameter"), + _("value"), + _("tablespace_name"), + _("query")); +} + +void +sql_help_CREATE_TABLESPACE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE TABLESPACE %s [ OWNER %s ] LOCATION '%s'", + _("tablespace_name"), + _("user_name"), + _("directory")); +} + +void +sql_help_CREATE_TEXT_SEARCH_CONFIGURATION(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE TEXT SEARCH CONFIGURATION %s (\n" + " PARSER = %s |\n" + " COPY = %s\n" + ")", + _("name"), + _("parser_name"), + _("source_config")); +} + +void +sql_help_CREATE_TEXT_SEARCH_DICTIONARY(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE TEXT SEARCH DICTIONARY %s (\n" + " TEMPLATE = %s\n" + " [, %s = %s [, ... ]]\n" + ")", + _("name"), + _("template"), + _("option"), + _("value")); +} + +void +sql_help_CREATE_TEXT_SEARCH_PARSER(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE TEXT SEARCH PARSER %s (\n" + " START = %s ,\n" + " GETTOKEN = %s ,\n" + " END = %s ,\n" + " LEXTYPES = %s\n" + " [, HEADLINE = %s ]\n" + ")", + _("name"), + _("start_function"), + _("gettoken_function"), + _("end_function"), + _("lextypes_function"), + _("headline_function")); +} + +void +sql_help_CREATE_TEXT_SEARCH_TEMPLATE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE TEXT SEARCH TEMPLATE %s (\n" + " [ INIT = %s , ]\n" + " LEXIZE = %s\n" + ")", + _("name"), + _("init_function"), + _("lexize_function")); +} + +void +sql_help_CREATE_TRIGGER(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE [ CONSTRAINT ] TRIGGER %s { BEFORE | AFTER | INSTEAD OF } { %s [ OR ... ] }\n" + " ON %s\n" + " [ FROM %s ]\n" + " { NOT DEFERRABLE | [ DEFERRABLE ] { INITIALLY IMMEDIATE | INITIALLY DEFERRED } }\n" + " [ FOR [ EACH ] { ROW | STATEMENT } ]\n" + " [ WHEN ( %s ) ]\n" + " EXECUTE PROCEDURE %s ( %s )\n" + "\n" + "%s\n" + "\n" + " INSERT\n" + " UPDATE [ OF %s [, ... ] ]\n" + " DELETE\n" + " TRUNCATE", + _("name"), + _("event"), + _("table_name"), + _("referenced_table_name"), + _("condition"), + _("function_name"), + _("arguments"), + _("where event can be one of:"), + _("column_name")); +} + +void +sql_help_CREATE_TYPE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE TYPE %s AS\n" + " ( [ %s %s [ COLLATE %s ] [, ... ] ] )\n" + "\n" + "CREATE TYPE %s AS ENUM\n" + " ( [ '%s' [, ... ] ] )\n" + "\n" + "CREATE TYPE %s AS RANGE (\n" + " SUBTYPE = %s\n" + " [ , SUBTYPE_OPCLASS = %s ]\n" + " [ , COLLATION = %s ]\n" + " [ , CANONICAL = %s ]\n" + " [ , SUBTYPE_DIFF = %s ]\n" + ")\n" + "\n" + "CREATE TYPE %s (\n" + " INPUT = %s,\n" + " OUTPUT = %s\n" + " [ , RECEIVE = %s ]\n" + " [ , SEND = %s ]\n" + " [ , TYPMOD_IN = %s ]\n" + " [ , TYPMOD_OUT = %s ]\n" + " [ , ANALYZE = %s ]\n" + " [ , INTERNALLENGTH = { %s | VARIABLE } ]\n" + " [ , PASSEDBYVALUE ]\n" + " [ , ALIGNMENT = %s ]\n" + " [ , STORAGE = %s ]\n" + " [ , LIKE = %s ]\n" + " [ , CATEGORY = %s ]\n" + " [ , PREFERRED = %s ]\n" + " [ , DEFAULT = %s ]\n" + " [ , ELEMENT = %s ]\n" + " [ , DELIMITER = %s ]\n" + " [ , COLLATABLE = %s ]\n" + ")\n" + "\n" + "CREATE TYPE %s", + _("name"), + _("attribute_name"), + _("data_type"), + _("collation"), + _("name"), + _("label"), + _("name"), + _("subtype"), + _("subtype_operator_class"), + _("collation"), + _("canonical_function"), + _("subtype_diff_function"), + _("name"), + _("input_function"), + _("output_function"), + _("receive_function"), + _("send_function"), + _("type_modifier_input_function"), + _("type_modifier_output_function"), + _("analyze_function"), + _("internallength"), + _("alignment"), + _("storage"), + _("like_type"), + _("category"), + _("preferred"), + _("default"), + _("element"), + _("delimiter"), + _("collatable"), + _("name")); +} + +void +sql_help_CREATE_USER(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE USER %s [ [ WITH ] %s [ ... ] ]\n" + "\n" + "%s\n" + "\n" + " SUPERUSER | NOSUPERUSER\n" + " | CREATEDB | NOCREATEDB\n" + " | CREATEROLE | NOCREATEROLE\n" + " | CREATEUSER | NOCREATEUSER\n" + " | INHERIT | NOINHERIT\n" + " | LOGIN | NOLOGIN\n" + " | REPLICATION | NOREPLICATION\n" + " | CONNECTION LIMIT %s\n" + " | [ ENCRYPTED | UNENCRYPTED ] PASSWORD '%s'\n" + " | VALID UNTIL '%s'\n" + " | IN ROLE %s [, ...]\n" + " | IN GROUP %s [, ...]\n" + " | ROLE %s [, ...]\n" + " | ADMIN %s [, ...]\n" + " | USER %s [, ...]\n" + " | SYSID %s", + _("name"), + _("option"), + _("where option can be:"), + _("connlimit"), + _("password"), + _("timestamp"), + _("role_name"), + _("role_name"), + _("role_name"), + _("role_name"), + _("role_name"), + _("uid")); +} + +void +sql_help_CREATE_USER_MAPPING(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE USER MAPPING FOR { %s | USER | CURRENT_USER | PUBLIC }\n" + " SERVER %s\n" + " [ OPTIONS ( %s '%s' [ , ... ] ) ]", + _("user_name"), + _("server_name"), + _("option"), + _("value")); +} + +void +sql_help_CREATE_VIEW(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "CREATE [ OR REPLACE ] [ TEMP | TEMPORARY ] VIEW %s [ ( %s [, ...] ) ]\n" + " [ WITH ( %s [= %s] [, ... ] ) ]\n" + " AS %s", + _("name"), + _("column_name"), + _("view_option_name"), + _("view_option_value"), + _("query")); +} + +void +sql_help_DEALLOCATE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DEALLOCATE [ PREPARE ] { %s | ALL }", + _("name")); +} + +void +sql_help_DECLARE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DECLARE %s [ BINARY ] [ INSENSITIVE ] [ [ NO ] SCROLL ]\n" + " CURSOR [ { WITH | WITHOUT } HOLD ] FOR %s", + _("name"), + _("query")); +} + +void +sql_help_DELETE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "[ WITH [ RECURSIVE ] %s [, ...] ]\n" + "DELETE FROM [ ONLY ] %s [ * ] [ [ AS ] %s ]\n" + " [ USING %s ]\n" + " [ WHERE %s | WHERE CURRENT OF %s ]\n" + " [ RETURNING * | %s [ [ AS ] %s ] [, ...] ]", + _("with_query"), + _("table_name"), + _("alias"), + _("using_list"), + _("condition"), + _("cursor_name"), + _("output_expression"), + _("output_name")); +} + +void +sql_help_DISCARD(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DISCARD { ALL | PLANS | TEMPORARY | TEMP }"); +} + +void +sql_help_DO(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DO [ LANGUAGE %s ] %s", + _("lang_name"), + _("code")); +} + +void +sql_help_DROP_AGGREGATE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP AGGREGATE [ IF EXISTS ] %s ( %s [ , ... ] ) [ CASCADE | RESTRICT ]", + _("name"), + _("argtype")); +} + +void +sql_help_DROP_CAST(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP CAST [ IF EXISTS ] (%s AS %s) [ CASCADE | RESTRICT ]", + _("source_type"), + _("target_type")); +} + +void +sql_help_DROP_COLLATION(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP COLLATION [ IF EXISTS ] %s [ CASCADE | RESTRICT ]", + _("name")); +} + +void +sql_help_DROP_CONVERSION(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP CONVERSION [ IF EXISTS ] %s [ CASCADE | RESTRICT ]", + _("name")); +} + +void +sql_help_DROP_DATABASE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP DATABASE [ IF EXISTS ] %s", + _("name")); +} + +void +sql_help_DROP_DOMAIN(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP DOMAIN [ IF EXISTS ] %s [, ...] [ CASCADE | RESTRICT ]", + _("name")); +} + +void +sql_help_DROP_EXTENSION(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP EXTENSION [ IF EXISTS ] %s [, ...] [ CASCADE | RESTRICT ]", + _("name")); +} + +void +sql_help_DROP_FOREIGN_DATA_WRAPPER(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP FOREIGN DATA WRAPPER [ IF EXISTS ] %s [ CASCADE | RESTRICT ]", + _("name")); +} + +void +sql_help_DROP_FOREIGN_TABLE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP FOREIGN TABLE [ IF EXISTS ] %s [, ...] [ CASCADE | RESTRICT ]", + _("name")); +} + +void +sql_help_DROP_FUNCTION(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP FUNCTION [ IF EXISTS ] %s ( [ [ %s ] [ %s ] %s [, ...] ] )\n" + " [ CASCADE | RESTRICT ]", + _("name"), + _("argmode"), + _("argname"), + _("argtype")); +} + +void +sql_help_DROP_GROUP(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP GROUP [ IF EXISTS ] %s [, ...]", + _("name")); +} + +void +sql_help_DROP_INDEX(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP INDEX [ CONCURRENTLY ] [ IF EXISTS ] %s [, ...] [ CASCADE | RESTRICT ]", + _("name")); +} + +void +sql_help_DROP_LANGUAGE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP [ PROCEDURAL ] LANGUAGE [ IF EXISTS ] %s [ CASCADE | RESTRICT ]", + _("name")); +} + +void +sql_help_DROP_OPERATOR(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP OPERATOR [ IF EXISTS ] %s ( { %s | NONE } , { %s | NONE } ) [ CASCADE | RESTRICT ]", + _("name"), + _("left_type"), + _("right_type")); +} + +void +sql_help_DROP_OPERATOR_CLASS(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP OPERATOR CLASS [ IF EXISTS ] %s USING %s [ CASCADE | RESTRICT ]", + _("name"), + _("index_method")); +} + +void +sql_help_DROP_OPERATOR_FAMILY(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP OPERATOR FAMILY [ IF EXISTS ] %s USING %s [ CASCADE | RESTRICT ]", + _("name"), + _("index_method")); +} + +void +sql_help_DROP_OWNED(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP OWNED BY %s [, ...] [ CASCADE | RESTRICT ]", + _("name")); +} + +void +sql_help_DROP_ROLE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP ROLE [ IF EXISTS ] %s [, ...]", + _("name")); +} + +void +sql_help_DROP_RULE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP RULE [ IF EXISTS ] %s ON %s [ CASCADE | RESTRICT ]", + _("name"), + _("table_name")); +} + +void +sql_help_DROP_SCHEMA(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP SCHEMA [ IF EXISTS ] %s [, ...] [ CASCADE | RESTRICT ]", + _("name")); +} + +void +sql_help_DROP_SEQUENCE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP SEQUENCE [ IF EXISTS ] %s [, ...] [ CASCADE | RESTRICT ]", + _("name")); +} + +void +sql_help_DROP_SERVER(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP SERVER [ IF EXISTS ] %s [ CASCADE | RESTRICT ]", + _("name")); +} + +void +sql_help_DROP_TABLE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP TABLE [ IF EXISTS ] %s [, ...] [ CASCADE | RESTRICT ]", + _("name")); +} + +void +sql_help_DROP_TABLESPACE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP TABLESPACE [ IF EXISTS ] %s", + _("name")); +} + +void +sql_help_DROP_TEXT_SEARCH_CONFIGURATION(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP TEXT SEARCH CONFIGURATION [ IF EXISTS ] %s [ CASCADE | RESTRICT ]", + _("name")); +} + +void +sql_help_DROP_TEXT_SEARCH_DICTIONARY(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP TEXT SEARCH DICTIONARY [ IF EXISTS ] %s [ CASCADE | RESTRICT ]", + _("name")); +} + +void +sql_help_DROP_TEXT_SEARCH_PARSER(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP TEXT SEARCH PARSER [ IF EXISTS ] %s [ CASCADE | RESTRICT ]", + _("name")); +} + +void +sql_help_DROP_TEXT_SEARCH_TEMPLATE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP TEXT SEARCH TEMPLATE [ IF EXISTS ] %s [ CASCADE | RESTRICT ]", + _("name")); +} + +void +sql_help_DROP_TRIGGER(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP TRIGGER [ IF EXISTS ] %s ON %s [ CASCADE | RESTRICT ]", + _("name"), + _("table_name")); +} + +void +sql_help_DROP_TYPE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP TYPE [ IF EXISTS ] %s [, ...] [ CASCADE | RESTRICT ]", + _("name")); +} + +void +sql_help_DROP_USER(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP USER [ IF EXISTS ] %s [, ...]", + _("name")); +} + +void +sql_help_DROP_USER_MAPPING(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP USER MAPPING [ IF EXISTS ] FOR { %s | USER | CURRENT_USER | PUBLIC } SERVER %s", + _("user_name"), + _("server_name")); +} + +void +sql_help_DROP_VIEW(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "DROP VIEW [ IF EXISTS ] %s [, ...] [ CASCADE | RESTRICT ]", + _("name")); +} + +void +sql_help_END(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "END [ WORK | TRANSACTION ]"); +} + +void +sql_help_EXECUTE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "EXECUTE %s [ ( %s [, ...] ) ]", + _("name"), + _("parameter")); +} + +void +sql_help_EXPLAIN(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "EXPLAIN [ ( %s [, ...] ) ] %s\n" + "EXPLAIN [ ANALYZE ] [ VERBOSE ] %s\n" + "\n" + "%s\n" + "\n" + " ANALYZE [ %s ]\n" + " VERBOSE [ %s ]\n" + " COSTS [ %s ]\n" + " BUFFERS [ %s ]\n" + " TIMING [ %s ]\n" + " FORMAT { TEXT | XML | JSON | YAML }", + _("option"), + _("statement"), + _("statement"), + _("where option can be one of:"), + _("boolean"), + _("boolean"), + _("boolean"), + _("boolean"), + _("boolean")); +} + +void +sql_help_FETCH(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "FETCH [ %s [ FROM | IN ] ] %s\n" + "\n" + "%s\n" + "\n" + " NEXT\n" + " PRIOR\n" + " FIRST\n" + " LAST\n" + " ABSOLUTE %s\n" + " RELATIVE %s\n" + " %s\n" + " ALL\n" + " FORWARD\n" + " FORWARD %s\n" + " FORWARD ALL\n" + " BACKWARD\n" + " BACKWARD %s\n" + " BACKWARD ALL", + _("direction"), + _("cursor_name"), + _("where direction can be empty or one of:"), + _("count"), + _("count"), + _("count"), + _("count"), + _("count")); +} + +void +sql_help_GRANT(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "GRANT { { SELECT | INSERT | UPDATE | DELETE | TRUNCATE | REFERENCES | TRIGGER }\n" + " [, ...] | ALL [ PRIVILEGES ] }\n" + " ON { [ TABLE ] %s [, ...]\n" + " | ALL TABLES IN SCHEMA %s [, ...] }\n" + " TO { [ GROUP ] %s | PUBLIC } [, ...] [ WITH GRANT OPTION ]\n" + "\n" + "GRANT { { SELECT | INSERT | UPDATE | REFERENCES } ( %s [, ...] )\n" + " [, ...] | ALL [ PRIVILEGES ] ( %s [, ...] ) }\n" + " ON [ TABLE ] %s [, ...]\n" + " TO { [ GROUP ] %s | PUBLIC } [, ...] [ WITH GRANT OPTION ]\n" + "\n" + "GRANT { { USAGE | SELECT | UPDATE }\n" + " [, ...] | ALL [ PRIVILEGES ] }\n" + " ON { SEQUENCE %s [, ...]\n" + " | ALL SEQUENCES IN SCHEMA %s [, ...] }\n" + " TO { [ GROUP ] %s | PUBLIC } [, ...] [ WITH GRANT OPTION ]\n" + "\n" + "GRANT { { CREATE | CONNECT | TEMPORARY | TEMP } [, ...] | ALL [ PRIVILEGES ] }\n" + " ON DATABASE %s [, ...]\n" + " TO { [ GROUP ] %s | PUBLIC } [, ...] [ WITH GRANT OPTION ]\n" + "\n" + "GRANT { USAGE | ALL [ PRIVILEGES ] }\n" + " ON DOMAIN %s [, ...]\n" + " TO { [ GROUP ] %s | PUBLIC } [, ...] [ WITH GRANT OPTION ]\n" + "\n" + "GRANT { USAGE | ALL [ PRIVILEGES ] }\n" + " ON FOREIGN DATA WRAPPER %s [, ...]\n" + " TO { [ GROUP ] %s | PUBLIC } [, ...] [ WITH GRANT OPTION ]\n" + "\n" + "GRANT { USAGE | ALL [ PRIVILEGES ] }\n" + " ON FOREIGN SERVER %s [, ...]\n" + " TO { [ GROUP ] %s | PUBLIC } [, ...] [ WITH GRANT OPTION ]\n" + "\n" + "GRANT { EXECUTE | ALL [ PRIVILEGES ] }\n" + " ON { FUNCTION %s ( [ [ %s ] [ %s ] %s [, ...] ] ) [, ...]\n" + " | ALL FUNCTIONS IN SCHEMA %s [, ...] }\n" + " TO { [ GROUP ] %s | PUBLIC } [, ...] [ WITH GRANT OPTION ]\n" + "\n" + "GRANT { USAGE | ALL [ PRIVILEGES ] }\n" + " ON LANGUAGE %s [, ...]\n" + " TO { [ GROUP ] %s | PUBLIC } [, ...] [ WITH GRANT OPTION ]\n" + "\n" + "GRANT { { SELECT | UPDATE } [, ...] | ALL [ PRIVILEGES ] }\n" + " ON LARGE OBJECT %s [, ...]\n" + " TO { [ GROUP ] %s | PUBLIC } [, ...] [ WITH GRANT OPTION ]\n" + "\n" + "GRANT { { CREATE | USAGE } [, ...] | ALL [ PRIVILEGES ] }\n" + " ON SCHEMA %s [, ...]\n" + " TO { [ GROUP ] %s | PUBLIC } [, ...] [ WITH GRANT OPTION ]\n" + "\n" + "GRANT { CREATE | ALL [ PRIVILEGES ] }\n" + " ON TABLESPACE %s [, ...]\n" + " TO { [ GROUP ] %s | PUBLIC } [, ...] [ WITH GRANT OPTION ]\n" + "\n" + "GRANT { USAGE | ALL [ PRIVILEGES ] }\n" + " ON TYPE %s [, ...]\n" + " TO { [ GROUP ] %s | PUBLIC } [, ...] [ WITH GRANT OPTION ]\n" + "\n" + "GRANT %s [, ...] TO %s [, ...] [ WITH ADMIN OPTION ]", + _("table_name"), + _("schema_name"), + _("role_name"), + _("column_name"), + _("column_name"), + _("table_name"), + _("role_name"), + _("sequence_name"), + _("schema_name"), + _("role_name"), + _("database_name"), + _("role_name"), + _("domain_name"), + _("role_name"), + _("fdw_name"), + _("role_name"), + _("server_name"), + _("role_name"), + _("function_name"), + _("argmode"), + _("arg_name"), + _("arg_type"), + _("schema_name"), + _("role_name"), + _("lang_name"), + _("role_name"), + _("loid"), + _("role_name"), + _("schema_name"), + _("role_name"), + _("tablespace_name"), + _("role_name"), + _("type_name"), + _("role_name"), + _("role_name"), + _("role_name")); +} + +void +sql_help_INSERT(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "[ WITH [ RECURSIVE ] %s [, ...] ]\n" + "INSERT INTO %s [ ( %s [, ...] ) ]\n" + " { DEFAULT VALUES | VALUES ( { %s | DEFAULT } [, ...] ) [, ...] | %s }\n" + " [ RETURNING * | %s [ [ AS ] %s ] [, ...] ]", + _("with_query"), + _("table_name"), + _("column_name"), + _("expression"), + _("query"), + _("output_expression"), + _("output_name")); +} + +void +sql_help_LISTEN(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "LISTEN %s", + _("channel")); +} + +void +sql_help_LOAD(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "LOAD '%s'", + _("filename")); +} + +void +sql_help_LOCK(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "LOCK [ TABLE ] [ ONLY ] %s [ * ] [, ...] [ IN %s MODE ] [ NOWAIT ]\n" + "\n" + "%s\n" + "\n" + " ACCESS SHARE | ROW SHARE | ROW EXCLUSIVE | SHARE UPDATE EXCLUSIVE\n" + " | SHARE | SHARE ROW EXCLUSIVE | EXCLUSIVE | ACCESS EXCLUSIVE", + _("name"), + _("lockmode"), + _("where lockmode is one of:")); +} + +void +sql_help_MOVE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "MOVE [ %s [ FROM | IN ] ] %s\n" + "\n" + "%s\n" + "\n" + " NEXT\n" + " PRIOR\n" + " FIRST\n" + " LAST\n" + " ABSOLUTE %s\n" + " RELATIVE %s\n" + " %s\n" + " ALL\n" + " FORWARD\n" + " FORWARD %s\n" + " FORWARD ALL\n" + " BACKWARD\n" + " BACKWARD %s\n" + " BACKWARD ALL", + _("direction"), + _("cursor_name"), + _("where direction can be empty or one of:"), + _("count"), + _("count"), + _("count"), + _("count"), + _("count")); +} + +void +sql_help_NOTIFY(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "NOTIFY %s [ , %s ]", + _("channel"), + _("payload")); +} + +void +sql_help_PREPARE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "PREPARE %s [ ( %s [, ...] ) ] AS %s", + _("name"), + _("data_type"), + _("statement")); +} + +void +sql_help_PREPARE_TRANSACTION(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "PREPARE TRANSACTION %s", + _("transaction_id")); +} + +void +sql_help_REASSIGN_OWNED(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "REASSIGN OWNED BY %s [, ...] TO %s", + _("old_role"), + _("new_role")); +} + +void +sql_help_REINDEX(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "REINDEX { INDEX | TABLE | DATABASE | SYSTEM } %s [ FORCE ]", + _("name")); +} + +void +sql_help_RELEASE_SAVEPOINT(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "RELEASE [ SAVEPOINT ] %s", + _("savepoint_name")); +} + +void +sql_help_RESET(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "RESET %s\n" + "RESET ALL", + _("configuration_parameter")); +} + +void +sql_help_REVOKE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "REVOKE [ GRANT OPTION FOR ]\n" + " { { SELECT | INSERT | UPDATE | DELETE | TRUNCATE | REFERENCES | TRIGGER }\n" + " [, ...] | ALL [ PRIVILEGES ] }\n" + " ON { [ TABLE ] %s [, ...]\n" + " | ALL TABLES IN SCHEMA %s [, ...] }\n" + " FROM { [ GROUP ] %s | PUBLIC } [, ...]\n" + " [ CASCADE | RESTRICT ]\n" + "\n" + "REVOKE [ GRANT OPTION FOR ]\n" + " { { SELECT | INSERT | UPDATE | REFERENCES } ( %s [, ...] )\n" + " [, ...] | ALL [ PRIVILEGES ] ( %s [, ...] ) }\n" + " ON [ TABLE ] %s [, ...]\n" + " FROM { [ GROUP ] %s | PUBLIC } [, ...]\n" + " [ CASCADE | RESTRICT ]\n" + "\n" + "REVOKE [ GRANT OPTION FOR ]\n" + " { { USAGE | SELECT | UPDATE }\n" + " [, ...] | ALL [ PRIVILEGES ] }\n" + " ON { SEQUENCE %s [, ...]\n" + " | ALL SEQUENCES IN SCHEMA %s [, ...] }\n" + " FROM { [ GROUP ] %s | PUBLIC } [, ...]\n" + " [ CASCADE | RESTRICT ]\n" + "\n" + "REVOKE [ GRANT OPTION FOR ]\n" + " { { CREATE | CONNECT | TEMPORARY | TEMP } [, ...] | ALL [ PRIVILEGES ] }\n" + " ON DATABASE %s [, ...]\n" + " FROM { [ GROUP ] %s | PUBLIC } [, ...]\n" + " [ CASCADE | RESTRICT ]\n" + "\n" + "REVOKE [ GRANT OPTION FOR ]\n" + " { USAGE | ALL [ PRIVILEGES ] }\n" + " ON DOMAIN %s [, ...]\n" + " FROM { [ GROUP ] %s | PUBLIC } [, ...]\n" + " [ CASCADE | RESTRICT ]\n" + "\n" + "REVOKE [ GRANT OPTION FOR ]\n" + " { USAGE | ALL [ PRIVILEGES ] }\n" + " ON FOREIGN DATA WRAPPER %s [, ...]\n" + " FROM { [ GROUP ] %s | PUBLIC } [, ...]\n" + " [ CASCADE | RESTRICT ]\n" + "\n" + "REVOKE [ GRANT OPTION FOR ]\n" + " { USAGE | ALL [ PRIVILEGES ] }\n" + " ON FOREIGN SERVER %s [, ...]\n" + " FROM { [ GROUP ] %s | PUBLIC } [, ...]\n" + " [ CASCADE | RESTRICT ]\n" + "\n" + "REVOKE [ GRANT OPTION FOR ]\n" + " { EXECUTE | ALL [ PRIVILEGES ] }\n" + " ON { FUNCTION %s ( [ [ %s ] [ %s ] %s [, ...] ] ) [, ...]\n" + " | ALL FUNCTIONS IN SCHEMA %s [, ...] }\n" + " FROM { [ GROUP ] %s | PUBLIC } [, ...]\n" + " [ CASCADE | RESTRICT ]\n" + "\n" + "REVOKE [ GRANT OPTION FOR ]\n" + " { USAGE | ALL [ PRIVILEGES ] }\n" + " ON LANGUAGE %s [, ...]\n" + " FROM { [ GROUP ] %s | PUBLIC } [, ...]\n" + " [ CASCADE | RESTRICT ]\n" + "\n" + "REVOKE [ GRANT OPTION FOR ]\n" + " { { SELECT | UPDATE } [, ...] | ALL [ PRIVILEGES ] }\n" + " ON LARGE OBJECT %s [, ...]\n" + " FROM { [ GROUP ] %s | PUBLIC } [, ...]\n" + " [ CASCADE | RESTRICT ]\n" + "\n" + "REVOKE [ GRANT OPTION FOR ]\n" + " { { CREATE | USAGE } [, ...] | ALL [ PRIVILEGES ] }\n" + " ON SCHEMA %s [, ...]\n" + " FROM { [ GROUP ] %s | PUBLIC } [, ...]\n" + " [ CASCADE | RESTRICT ]\n" + "\n" + "REVOKE [ GRANT OPTION FOR ]\n" + " { CREATE | ALL [ PRIVILEGES ] }\n" + " ON TABLESPACE %s [, ...]\n" + " FROM { [ GROUP ] %s | PUBLIC } [, ...]\n" + " [ CASCADE | RESTRICT ]\n" + "\n" + "REVOKE [ GRANT OPTION FOR ]\n" + " { USAGE | ALL [ PRIVILEGES ] }\n" + " ON TYPE %s [, ...]\n" + " FROM { [ GROUP ] %s | PUBLIC } [, ...]\n" + " [ CASCADE | RESTRICT ]\n" + "\n" + "REVOKE [ ADMIN OPTION FOR ]\n" + " %s [, ...] FROM %s [, ...]\n" + " [ CASCADE | RESTRICT ]", + _("table_name"), + _("schema_name"), + _("role_name"), + _("column_name"), + _("column_name"), + _("table_name"), + _("role_name"), + _("sequence_name"), + _("schema_name"), + _("role_name"), + _("database_name"), + _("role_name"), + _("domain_name"), + _("role_name"), + _("fdw_name"), + _("role_name"), + _("server_name"), + _("role_name"), + _("function_name"), + _("argmode"), + _("arg_name"), + _("arg_type"), + _("schema_name"), + _("role_name"), + _("lang_name"), + _("role_name"), + _("loid"), + _("role_name"), + _("schema_name"), + _("role_name"), + _("tablespace_name"), + _("role_name"), + _("type_name"), + _("role_name"), + _("role_name"), + _("role_name")); +} + +void +sql_help_ROLLBACK(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ROLLBACK [ WORK | TRANSACTION ]"); +} + +void +sql_help_ROLLBACK_PREPARED(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ROLLBACK PREPARED %s", + _("transaction_id")); +} + +void +sql_help_ROLLBACK_TO_SAVEPOINT(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "ROLLBACK [ WORK | TRANSACTION ] TO [ SAVEPOINT ] %s", + _("savepoint_name")); +} + +void +sql_help_SAVEPOINT(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "SAVEPOINT %s", + _("savepoint_name")); +} + +void +sql_help_SECURITY_LABEL(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "SECURITY LABEL [ FOR %s ] ON\n" + "{\n" + " TABLE %s |\n" + " COLUMN %s.%s |\n" + " AGGREGATE %s (%s [, ...] ) |\n" + " DATABASE %s |\n" + " DOMAIN %s |\n" + " FOREIGN TABLE %s\n" + " FUNCTION %s ( [ [ %s ] [ %s ] %s [, ...] ] ) |\n" + " LARGE OBJECT %s |\n" + " [ PROCEDURAL ] LANGUAGE %s |\n" + " ROLE %s |\n" + " SCHEMA %s |\n" + " SEQUENCE %s |\n" + " TABLESPACE %s |\n" + " TYPE %s |\n" + " VIEW %s\n" + "} IS '%s'", + _("provider"), + _("object_name"), + _("table_name"), + _("column_name"), + _("agg_name"), + _("agg_type"), + _("object_name"), + _("object_name"), + _("object_name"), + _("function_name"), + _("argmode"), + _("argname"), + _("argtype"), + _("large_object_oid"), + _("object_name"), + _("object_name"), + _("object_name"), + _("object_name"), + _("object_name"), + _("object_name"), + _("object_name"), + _("label")); +} + +void +sql_help_SELECT(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "[ WITH [ RECURSIVE ] %s [, ...] ]\n" + "SELECT [ ALL | DISTINCT [ ON ( %s [, ...] ) ] ]\n" + " * | %s [ [ AS ] %s ] [, ...]\n" + " [ FROM %s [, ...] ]\n" + " [ WHERE %s ]\n" + " [ GROUP BY %s [, ...] ]\n" + " [ HAVING %s [, ...] ]\n" + " [ WINDOW %s AS ( %s ) [, ...] ]\n" + " [ { UNION | INTERSECT | EXCEPT } [ ALL | DISTINCT ] %s ]\n" + " [ ORDER BY %s [ ASC | DESC | USING %s ] [ NULLS { FIRST | LAST } ] [, ...] ]\n" + " [ LIMIT { %s | ALL } ]\n" + " [ OFFSET %s [ ROW | ROWS ] ]\n" + " [ FETCH { FIRST | NEXT } [ %s ] { ROW | ROWS } ONLY ]\n" + " [ FOR { UPDATE | SHARE } [ OF %s [, ...] ] [ NOWAIT ] [...] ]\n" + "\n" + "%s\n" + "\n" + " [ ONLY ] %s [ * ] [ [ AS ] %s [ ( %s [, ...] ) ] ]\n" + " ( %s ) [ AS ] %s [ ( %s [, ...] ) ]\n" + " %s [ [ AS ] %s [ ( %s [, ...] ) ] ]\n" + " %s ( [ %s [, ...] ] ) [ AS ] %s [ ( %s [, ...] | %s [, ...] ) ]\n" + " %s ( [ %s [, ...] ] ) AS ( %s [, ...] )\n" + " %s [ NATURAL ] %s %s [ ON %s | USING ( %s [, ...] ) ]\n" + "\n" + "%s\n" + "\n" + " %s [ ( %s [, ...] ) ] AS ( %s | %s | %s | %s | %s )\n" + "\n" + "TABLE [ ONLY ] %s [ * ]", + _("with_query"), + _("expression"), + _("expression"), + _("output_name"), + _("from_item"), + _("condition"), + _("expression"), + _("condition"), + _("window_name"), + _("window_definition"), + _("select"), + _("expression"), + _("operator"), + _("count"), + _("start"), + _("count"), + _("table_name"), + _("where from_item can be one of:"), + _("table_name"), + _("alias"), + _("column_alias"), + _("select"), + _("alias"), + _("column_alias"), + _("with_query_name"), + _("alias"), + _("column_alias"), + _("function_name"), + _("argument"), + _("alias"), + _("column_alias"), + _("column_definition"), + _("function_name"), + _("argument"), + _("column_definition"), + _("from_item"), + _("join_type"), + _("from_item"), + _("join_condition"), + _("join_column"), + _("and with_query is:"), + _("with_query_name"), + _("column_name"), + _("select"), + _("values"), + _("insert"), + _("update"), + _("delete"), + _("table_name")); +} + +void +sql_help_SELECT_INTO(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "[ WITH [ RECURSIVE ] %s [, ...] ]\n" + "SELECT [ ALL | DISTINCT [ ON ( %s [, ...] ) ] ]\n" + " * | %s [ [ AS ] %s ] [, ...]\n" + " INTO [ TEMPORARY | TEMP | UNLOGGED ] [ TABLE ] %s\n" + " [ FROM %s [, ...] ]\n" + " [ WHERE %s ]\n" + " [ GROUP BY %s [, ...] ]\n" + " [ HAVING %s [, ...] ]\n" + " [ WINDOW %s AS ( %s ) [, ...] ]\n" + " [ { UNION | INTERSECT | EXCEPT } [ ALL | DISTINCT ] %s ]\n" + " [ ORDER BY %s [ ASC | DESC | USING %s ] [ NULLS { FIRST | LAST } ] [, ...] ]\n" + " [ LIMIT { %s | ALL } ]\n" + " [ OFFSET %s [ ROW | ROWS ] ]\n" + " [ FETCH { FIRST | NEXT } [ %s ] { ROW | ROWS } ONLY ]\n" + " [ FOR { UPDATE | SHARE } [ OF %s [, ...] ] [ NOWAIT ] [...] ]", + _("with_query"), + _("expression"), + _("expression"), + _("output_name"), + _("new_table"), + _("from_item"), + _("condition"), + _("expression"), + _("condition"), + _("window_name"), + _("window_definition"), + _("select"), + _("expression"), + _("operator"), + _("count"), + _("start"), + _("count"), + _("table_name")); +} + +void +sql_help_SET(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "SET [ SESSION | LOCAL ] %s { TO | = } { %s | '%s' | DEFAULT }\n" + "SET [ SESSION | LOCAL ] TIME ZONE { %s | LOCAL | DEFAULT }", + _("configuration_parameter"), + _("value"), + _("value"), + _("timezone")); +} + +void +sql_help_SET_CONSTRAINTS(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "SET CONSTRAINTS { ALL | %s [, ...] } { DEFERRED | IMMEDIATE }", + _("name")); +} + +void +sql_help_SET_ROLE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "SET [ SESSION | LOCAL ] ROLE %s\n" + "SET [ SESSION | LOCAL ] ROLE NONE\n" + "RESET ROLE", + _("role_name")); +} + +void +sql_help_SET_SESSION_AUTHORIZATION(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "SET [ SESSION | LOCAL ] SESSION AUTHORIZATION %s\n" + "SET [ SESSION | LOCAL ] SESSION AUTHORIZATION DEFAULT\n" + "RESET SESSION AUTHORIZATION", + _("user_name")); +} + +void +sql_help_SET_TRANSACTION(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "SET TRANSACTION %s [, ...]\n" + "SET TRANSACTION SNAPSHOT %s\n" + "SET SESSION CHARACTERISTICS AS TRANSACTION %s [, ...]\n" + "\n" + "%s\n" + "\n" + " ISOLATION LEVEL { SERIALIZABLE | REPEATABLE READ | READ COMMITTED | READ UNCOMMITTED }\n" + " READ WRITE | READ ONLY\n" + " [ NOT ] DEFERRABLE", + _("transaction_mode"), + _("snapshot_id"), + _("transaction_mode"), + _("where transaction_mode is one of:")); +} + +void +sql_help_SHOW(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "SHOW %s\n" + "SHOW ALL", + _("name")); +} + +void +sql_help_START_TRANSACTION(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "START TRANSACTION [ %s [, ...] ]\n" + "\n" + "%s\n" + "\n" + " ISOLATION LEVEL { SERIALIZABLE | REPEATABLE READ | READ COMMITTED | READ UNCOMMITTED }\n" + " READ WRITE | READ ONLY\n" + " [ NOT ] DEFERRABLE", + _("transaction_mode"), + _("where transaction_mode is one of:")); +} + +void +sql_help_TABLE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "[ WITH [ RECURSIVE ] %s [, ...] ]\n" + "SELECT [ ALL | DISTINCT [ ON ( %s [, ...] ) ] ]\n" + " * | %s [ [ AS ] %s ] [, ...]\n" + " [ FROM %s [, ...] ]\n" + " [ WHERE %s ]\n" + " [ GROUP BY %s [, ...] ]\n" + " [ HAVING %s [, ...] ]\n" + " [ WINDOW %s AS ( %s ) [, ...] ]\n" + " [ { UNION | INTERSECT | EXCEPT } [ ALL | DISTINCT ] %s ]\n" + " [ ORDER BY %s [ ASC | DESC | USING %s ] [ NULLS { FIRST | LAST } ] [, ...] ]\n" + " [ LIMIT { %s | ALL } ]\n" + " [ OFFSET %s [ ROW | ROWS ] ]\n" + " [ FETCH { FIRST | NEXT } [ %s ] { ROW | ROWS } ONLY ]\n" + " [ FOR { UPDATE | SHARE } [ OF %s [, ...] ] [ NOWAIT ] [...] ]\n" + "\n" + "%s\n" + "\n" + " [ ONLY ] %s [ * ] [ [ AS ] %s [ ( %s [, ...] ) ] ]\n" + " ( %s ) [ AS ] %s [ ( %s [, ...] ) ]\n" + " %s [ [ AS ] %s [ ( %s [, ...] ) ] ]\n" + " %s ( [ %s [, ...] ] ) [ AS ] %s [ ( %s [, ...] | %s [, ...] ) ]\n" + " %s ( [ %s [, ...] ] ) AS ( %s [, ...] )\n" + " %s [ NATURAL ] %s %s [ ON %s | USING ( %s [, ...] ) ]\n" + "\n" + "%s\n" + "\n" + " %s [ ( %s [, ...] ) ] AS ( %s | %s | %s | %s | %s )\n" + "\n" + "TABLE [ ONLY ] %s [ * ]", + _("with_query"), + _("expression"), + _("expression"), + _("output_name"), + _("from_item"), + _("condition"), + _("expression"), + _("condition"), + _("window_name"), + _("window_definition"), + _("select"), + _("expression"), + _("operator"), + _("count"), + _("start"), + _("count"), + _("table_name"), + _("where from_item can be one of:"), + _("table_name"), + _("alias"), + _("column_alias"), + _("select"), + _("alias"), + _("column_alias"), + _("with_query_name"), + _("alias"), + _("column_alias"), + _("function_name"), + _("argument"), + _("alias"), + _("column_alias"), + _("column_definition"), + _("function_name"), + _("argument"), + _("column_definition"), + _("from_item"), + _("join_type"), + _("from_item"), + _("join_condition"), + _("join_column"), + _("and with_query is:"), + _("with_query_name"), + _("column_name"), + _("select"), + _("values"), + _("insert"), + _("update"), + _("delete"), + _("table_name")); +} + +void +sql_help_TRUNCATE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "TRUNCATE [ TABLE ] [ ONLY ] %s [ * ] [, ... ]\n" + " [ RESTART IDENTITY | CONTINUE IDENTITY ] [ CASCADE | RESTRICT ]", + _("name")); +} + +void +sql_help_UNLISTEN(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "UNLISTEN { %s | * }", + _("channel")); +} + +void +sql_help_UPDATE(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "[ WITH [ RECURSIVE ] %s [, ...] ]\n" + "UPDATE [ ONLY ] %s [ * ] [ [ AS ] %s ]\n" + " SET { %s = { %s | DEFAULT } |\n" + " ( %s [, ...] ) = ( { %s | DEFAULT } [, ...] ) } [, ...]\n" + " [ FROM %s ]\n" + " [ WHERE %s | WHERE CURRENT OF %s ]\n" + " [ RETURNING * | %s [ [ AS ] %s ] [, ...] ]", + _("with_query"), + _("table_name"), + _("alias"), + _("column_name"), + _("expression"), + _("column_name"), + _("expression"), + _("from_list"), + _("condition"), + _("cursor_name"), + _("output_expression"), + _("output_name")); +} + +void +sql_help_VACUUM(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "VACUUM [ ( { FULL | FREEZE | VERBOSE | ANALYZE } [, ...] ) ] [ %s [ (%s [, ...] ) ] ]\n" + "VACUUM [ FULL ] [ FREEZE ] [ VERBOSE ] [ %s ]\n" + "VACUUM [ FULL ] [ FREEZE ] [ VERBOSE ] ANALYZE [ %s [ (%s [, ...] ) ] ]", + _("table_name"), + _("column_name"), + _("table_name"), + _("table_name"), + _("column_name")); +} + +void +sql_help_VALUES(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "VALUES ( %s [, ...] ) [, ...]\n" + " [ ORDER BY %s [ ASC | DESC | USING %s ] [, ...] ]\n" + " [ LIMIT { %s | ALL } ]\n" + " [ OFFSET %s [ ROW | ROWS ] ]\n" + " [ FETCH { FIRST | NEXT } [ %s ] { ROW | ROWS } ONLY ]", + _("expression"), + _("sort_expression"), + _("operator"), + _("count"), + _("start"), + _("count")); +} + +void +sql_help_WITH(PQExpBuffer buf) +{ + appendPQExpBuffer(buf, + "[ WITH [ RECURSIVE ] %s [, ...] ]\n" + "SELECT [ ALL | DISTINCT [ ON ( %s [, ...] ) ] ]\n" + " * | %s [ [ AS ] %s ] [, ...]\n" + " [ FROM %s [, ...] ]\n" + " [ WHERE %s ]\n" + " [ GROUP BY %s [, ...] ]\n" + " [ HAVING %s [, ...] ]\n" + " [ WINDOW %s AS ( %s ) [, ...] ]\n" + " [ { UNION | INTERSECT | EXCEPT } [ ALL | DISTINCT ] %s ]\n" + " [ ORDER BY %s [ ASC | DESC | USING %s ] [ NULLS { FIRST | LAST } ] [, ...] ]\n" + " [ LIMIT { %s | ALL } ]\n" + " [ OFFSET %s [ ROW | ROWS ] ]\n" + " [ FETCH { FIRST | NEXT } [ %s ] { ROW | ROWS } ONLY ]\n" + " [ FOR { UPDATE | SHARE } [ OF %s [, ...] ] [ NOWAIT ] [...] ]\n" + "\n" + "%s\n" + "\n" + " [ ONLY ] %s [ * ] [ [ AS ] %s [ ( %s [, ...] ) ] ]\n" + " ( %s ) [ AS ] %s [ ( %s [, ...] ) ]\n" + " %s [ [ AS ] %s [ ( %s [, ...] ) ] ]\n" + " %s ( [ %s [, ...] ] ) [ AS ] %s [ ( %s [, ...] | %s [, ...] ) ]\n" + " %s ( [ %s [, ...] ] ) AS ( %s [, ...] )\n" + " %s [ NATURAL ] %s %s [ ON %s | USING ( %s [, ...] ) ]\n" + "\n" + "%s\n" + "\n" + " %s [ ( %s [, ...] ) ] AS ( %s | %s | %s | %s | %s )\n" + "\n" + "TABLE [ ONLY ] %s [ * ]", + _("with_query"), + _("expression"), + _("expression"), + _("output_name"), + _("from_item"), + _("condition"), + _("expression"), + _("condition"), + _("window_name"), + _("window_definition"), + _("select"), + _("expression"), + _("operator"), + _("count"), + _("start"), + _("count"), + _("table_name"), + _("where from_item can be one of:"), + _("table_name"), + _("alias"), + _("column_alias"), + _("select"), + _("alias"), + _("column_alias"), + _("with_query_name"), + _("alias"), + _("column_alias"), + _("function_name"), + _("argument"), + _("alias"), + _("column_alias"), + _("column_definition"), + _("function_name"), + _("argument"), + _("column_definition"), + _("from_item"), + _("join_type"), + _("from_item"), + _("join_condition"), + _("join_column"), + _("and with_query is:"), + _("with_query_name"), + _("column_name"), + _("select"), + _("values"), + _("insert"), + _("update"), + _("delete"), + _("table_name")); +} + diff --git a/src/bin/psql/sql_help.h b/src/bin/psql/sql_help.h new file mode 100644 index 000000000..db8b4fd05 --- /dev/null +++ b/src/bin/psql/sql_help.h @@ -0,0 +1,950 @@ +/* + * *** Do not change this file by hand. It is automatically + * *** generated from the DocBook documentation. + * + * generated by + * /usr/bin/perl create_help.pl ../../../doc/src/sgml/ref sql_help + * + */ + +#ifndef SQL_HELP_H +#define SQL_HELP_H + +#define N_(x) (x) /* gettext noop */ + +#include "postgres_fe.h" +#include "pqexpbuffer.h" + +struct _helpStruct +{ + const char *cmd; /* the command name */ + const char *help; /* the help associated with it */ + void (*syntaxfunc)(PQExpBuffer); /* function that prints the syntax associated with it */ + int nl_count; /* number of newlines in syntax (for pager) */ +}; + +extern void sql_help_ABORT(PQExpBuffer buf); +extern void sql_help_ALTER_AGGREGATE(PQExpBuffer buf); +extern void sql_help_ALTER_COLLATION(PQExpBuffer buf); +extern void sql_help_ALTER_CONVERSION(PQExpBuffer buf); +extern void sql_help_ALTER_DATABASE(PQExpBuffer buf); +extern void sql_help_ALTER_DEFAULT_PRIVILEGES(PQExpBuffer buf); +extern void sql_help_ALTER_DOMAIN(PQExpBuffer buf); +extern void sql_help_ALTER_EXTENSION(PQExpBuffer buf); +extern void sql_help_ALTER_FOREIGN_DATA_WRAPPER(PQExpBuffer buf); +extern void sql_help_ALTER_FOREIGN_TABLE(PQExpBuffer buf); +extern void sql_help_ALTER_FUNCTION(PQExpBuffer buf); +extern void sql_help_ALTER_GROUP(PQExpBuffer buf); +extern void sql_help_ALTER_INDEX(PQExpBuffer buf); +extern void sql_help_ALTER_LANGUAGE(PQExpBuffer buf); +extern void sql_help_ALTER_LARGE_OBJECT(PQExpBuffer buf); +extern void sql_help_ALTER_OPERATOR(PQExpBuffer buf); +extern void sql_help_ALTER_OPERATOR_CLASS(PQExpBuffer buf); +extern void sql_help_ALTER_OPERATOR_FAMILY(PQExpBuffer buf); +extern void sql_help_ALTER_ROLE(PQExpBuffer buf); +extern void sql_help_ALTER_SCHEMA(PQExpBuffer buf); +extern void sql_help_ALTER_SEQUENCE(PQExpBuffer buf); +extern void sql_help_ALTER_SERVER(PQExpBuffer buf); +extern void sql_help_ALTER_TABLE(PQExpBuffer buf); +extern void sql_help_ALTER_TABLESPACE(PQExpBuffer buf); +extern void sql_help_ALTER_TEXT_SEARCH_CONFIGURATION(PQExpBuffer buf); +extern void sql_help_ALTER_TEXT_SEARCH_DICTIONARY(PQExpBuffer buf); +extern void sql_help_ALTER_TEXT_SEARCH_PARSER(PQExpBuffer buf); +extern void sql_help_ALTER_TEXT_SEARCH_TEMPLATE(PQExpBuffer buf); +extern void sql_help_ALTER_TRIGGER(PQExpBuffer buf); +extern void sql_help_ALTER_TYPE(PQExpBuffer buf); +extern void sql_help_ALTER_USER(PQExpBuffer buf); +extern void sql_help_ALTER_USER_MAPPING(PQExpBuffer buf); +extern void sql_help_ALTER_VIEW(PQExpBuffer buf); +extern void sql_help_ANALYZE(PQExpBuffer buf); +extern void sql_help_BEGIN(PQExpBuffer buf); +extern void sql_help_CHECKPOINT(PQExpBuffer buf); +extern void sql_help_CLOSE(PQExpBuffer buf); +extern void sql_help_CLUSTER(PQExpBuffer buf); +extern void sql_help_COMMENT(PQExpBuffer buf); +extern void sql_help_COMMIT(PQExpBuffer buf); +extern void sql_help_COMMIT_PREPARED(PQExpBuffer buf); +extern void sql_help_COPY(PQExpBuffer buf); +extern void sql_help_CREATE_AGGREGATE(PQExpBuffer buf); +extern void sql_help_CREATE_CAST(PQExpBuffer buf); +extern void sql_help_CREATE_COLLATION(PQExpBuffer buf); +extern void sql_help_CREATE_CONVERSION(PQExpBuffer buf); +extern void sql_help_CREATE_DATABASE(PQExpBuffer buf); +extern void sql_help_CREATE_DOMAIN(PQExpBuffer buf); +extern void sql_help_CREATE_EXTENSION(PQExpBuffer buf); +extern void sql_help_CREATE_FOREIGN_DATA_WRAPPER(PQExpBuffer buf); +extern void sql_help_CREATE_FOREIGN_TABLE(PQExpBuffer buf); +extern void sql_help_CREATE_FUNCTION(PQExpBuffer buf); +extern void sql_help_CREATE_GROUP(PQExpBuffer buf); +extern void sql_help_CREATE_INDEX(PQExpBuffer buf); +extern void sql_help_CREATE_LANGUAGE(PQExpBuffer buf); +extern void sql_help_CREATE_OPERATOR(PQExpBuffer buf); +extern void sql_help_CREATE_OPERATOR_CLASS(PQExpBuffer buf); +extern void sql_help_CREATE_OPERATOR_FAMILY(PQExpBuffer buf); +extern void sql_help_CREATE_ROLE(PQExpBuffer buf); +extern void sql_help_CREATE_RULE(PQExpBuffer buf); +extern void sql_help_CREATE_SCHEMA(PQExpBuffer buf); +extern void sql_help_CREATE_SEQUENCE(PQExpBuffer buf); +extern void sql_help_CREATE_SERVER(PQExpBuffer buf); +extern void sql_help_CREATE_TABLE(PQExpBuffer buf); +extern void sql_help_CREATE_TABLE_AS(PQExpBuffer buf); +extern void sql_help_CREATE_TABLESPACE(PQExpBuffer buf); +extern void sql_help_CREATE_TEXT_SEARCH_CONFIGURATION(PQExpBuffer buf); +extern void sql_help_CREATE_TEXT_SEARCH_DICTIONARY(PQExpBuffer buf); +extern void sql_help_CREATE_TEXT_SEARCH_PARSER(PQExpBuffer buf); +extern void sql_help_CREATE_TEXT_SEARCH_TEMPLATE(PQExpBuffer buf); +extern void sql_help_CREATE_TRIGGER(PQExpBuffer buf); +extern void sql_help_CREATE_TYPE(PQExpBuffer buf); +extern void sql_help_CREATE_USER(PQExpBuffer buf); +extern void sql_help_CREATE_USER_MAPPING(PQExpBuffer buf); +extern void sql_help_CREATE_VIEW(PQExpBuffer buf); +extern void sql_help_DEALLOCATE(PQExpBuffer buf); +extern void sql_help_DECLARE(PQExpBuffer buf); +extern void sql_help_DELETE(PQExpBuffer buf); +extern void sql_help_DISCARD(PQExpBuffer buf); +extern void sql_help_DO(PQExpBuffer buf); +extern void sql_help_DROP_AGGREGATE(PQExpBuffer buf); +extern void sql_help_DROP_CAST(PQExpBuffer buf); +extern void sql_help_DROP_COLLATION(PQExpBuffer buf); +extern void sql_help_DROP_CONVERSION(PQExpBuffer buf); +extern void sql_help_DROP_DATABASE(PQExpBuffer buf); +extern void sql_help_DROP_DOMAIN(PQExpBuffer buf); +extern void sql_help_DROP_EXTENSION(PQExpBuffer buf); +extern void sql_help_DROP_FOREIGN_DATA_WRAPPER(PQExpBuffer buf); +extern void sql_help_DROP_FOREIGN_TABLE(PQExpBuffer buf); +extern void sql_help_DROP_FUNCTION(PQExpBuffer buf); +extern void sql_help_DROP_GROUP(PQExpBuffer buf); +extern void sql_help_DROP_INDEX(PQExpBuffer buf); +extern void sql_help_DROP_LANGUAGE(PQExpBuffer buf); +extern void sql_help_DROP_OPERATOR(PQExpBuffer buf); +extern void sql_help_DROP_OPERATOR_CLASS(PQExpBuffer buf); +extern void sql_help_DROP_OPERATOR_FAMILY(PQExpBuffer buf); +extern void sql_help_DROP_OWNED(PQExpBuffer buf); +extern void sql_help_DROP_ROLE(PQExpBuffer buf); +extern void sql_help_DROP_RULE(PQExpBuffer buf); +extern void sql_help_DROP_SCHEMA(PQExpBuffer buf); +extern void sql_help_DROP_SEQUENCE(PQExpBuffer buf); +extern void sql_help_DROP_SERVER(PQExpBuffer buf); +extern void sql_help_DROP_TABLE(PQExpBuffer buf); +extern void sql_help_DROP_TABLESPACE(PQExpBuffer buf); +extern void sql_help_DROP_TEXT_SEARCH_CONFIGURATION(PQExpBuffer buf); +extern void sql_help_DROP_TEXT_SEARCH_DICTIONARY(PQExpBuffer buf); +extern void sql_help_DROP_TEXT_SEARCH_PARSER(PQExpBuffer buf); +extern void sql_help_DROP_TEXT_SEARCH_TEMPLATE(PQExpBuffer buf); +extern void sql_help_DROP_TRIGGER(PQExpBuffer buf); +extern void sql_help_DROP_TYPE(PQExpBuffer buf); +extern void sql_help_DROP_USER(PQExpBuffer buf); +extern void sql_help_DROP_USER_MAPPING(PQExpBuffer buf); +extern void sql_help_DROP_VIEW(PQExpBuffer buf); +extern void sql_help_END(PQExpBuffer buf); +extern void sql_help_EXECUTE(PQExpBuffer buf); +extern void sql_help_EXPLAIN(PQExpBuffer buf); +extern void sql_help_FETCH(PQExpBuffer buf); +extern void sql_help_GRANT(PQExpBuffer buf); +extern void sql_help_INSERT(PQExpBuffer buf); +extern void sql_help_LISTEN(PQExpBuffer buf); +extern void sql_help_LOAD(PQExpBuffer buf); +extern void sql_help_LOCK(PQExpBuffer buf); +extern void sql_help_MOVE(PQExpBuffer buf); +extern void sql_help_NOTIFY(PQExpBuffer buf); +extern void sql_help_PREPARE(PQExpBuffer buf); +extern void sql_help_PREPARE_TRANSACTION(PQExpBuffer buf); +extern void sql_help_REASSIGN_OWNED(PQExpBuffer buf); +extern void sql_help_REINDEX(PQExpBuffer buf); +extern void sql_help_RELEASE_SAVEPOINT(PQExpBuffer buf); +extern void sql_help_RESET(PQExpBuffer buf); +extern void sql_help_REVOKE(PQExpBuffer buf); +extern void sql_help_ROLLBACK(PQExpBuffer buf); +extern void sql_help_ROLLBACK_PREPARED(PQExpBuffer buf); +extern void sql_help_ROLLBACK_TO_SAVEPOINT(PQExpBuffer buf); +extern void sql_help_SAVEPOINT(PQExpBuffer buf); +extern void sql_help_SECURITY_LABEL(PQExpBuffer buf); +extern void sql_help_SELECT(PQExpBuffer buf); +extern void sql_help_SELECT_INTO(PQExpBuffer buf); +extern void sql_help_SET(PQExpBuffer buf); +extern void sql_help_SET_CONSTRAINTS(PQExpBuffer buf); +extern void sql_help_SET_ROLE(PQExpBuffer buf); +extern void sql_help_SET_SESSION_AUTHORIZATION(PQExpBuffer buf); +extern void sql_help_SET_TRANSACTION(PQExpBuffer buf); +extern void sql_help_SHOW(PQExpBuffer buf); +extern void sql_help_START_TRANSACTION(PQExpBuffer buf); +extern void sql_help_TABLE(PQExpBuffer buf); +extern void sql_help_TRUNCATE(PQExpBuffer buf); +extern void sql_help_UNLISTEN(PQExpBuffer buf); +extern void sql_help_UPDATE(PQExpBuffer buf); +extern void sql_help_VACUUM(PQExpBuffer buf); +extern void sql_help_VALUES(PQExpBuffer buf); +extern void sql_help_WITH(PQExpBuffer buf); + + +static const struct _helpStruct QL_HELP[] = { + { "ABORT", + N_("abort the current transaction"), + sql_help_ABORT, + 0 }, + + { "ALTER AGGREGATE", + N_("change the definition of an aggregate function"), + sql_help_ALTER_AGGREGATE, + 2 }, + + { "ALTER COLLATION", + N_("change the definition of a collation"), + sql_help_ALTER_COLLATION, + 2 }, + + { "ALTER CONVERSION", + N_("change the definition of a conversion"), + sql_help_ALTER_CONVERSION, + 2 }, + + { "ALTER DATABASE", + N_("change a database"), + sql_help_ALTER_DATABASE, + 15 }, + + { "ALTER DEFAULT PRIVILEGES", + N_("define default access privileges"), + sql_help_ALTER_DEFAULT_PRIVILEGES, + 49 }, + + { "ALTER DOMAIN", + N_("change the definition of a domain"), + sql_help_ALTER_DOMAIN, + 17 }, + + { "ALTER EXTENSION", + N_("change the definition of an extension"), + sql_help_ALTER_EXTENSION, + 28 }, + + { "ALTER FOREIGN DATA WRAPPER", + N_("change the definition of a foreign-data wrapper"), + sql_help_ALTER_FOREIGN_DATA_WRAPPER, + 5 }, + + { "ALTER FOREIGN TABLE", + N_("change the definition of a foreign table"), + sql_help_ALTER_FOREIGN_TABLE, + 20 }, + + { "ALTER FUNCTION", + N_("change the definition of a function"), + sql_help_ALTER_FUNCTION, + 19 }, + + { "ALTER GROUP", + N_("change role name or membership"), + sql_help_ALTER_GROUP, + 3 }, + + { "ALTER INDEX", + N_("change the definition of an index"), + sql_help_ALTER_INDEX, + 3 }, + + { "ALTER LANGUAGE", + N_("change the definition of a procedural language"), + sql_help_ALTER_LANGUAGE, + 1 }, + + { "ALTER LARGE OBJECT", + N_("change the definition of a large object"), + sql_help_ALTER_LARGE_OBJECT, + 0 }, + + { "ALTER OPERATOR", + N_("change the definition of an operator"), + sql_help_ALTER_OPERATOR, + 1 }, + + { "ALTER OPERATOR CLASS", + N_("change the definition of an operator class"), + sql_help_ALTER_OPERATOR_CLASS, + 2 }, + + { "ALTER OPERATOR FAMILY", + N_("change the definition of an operator family"), + sql_help_ALTER_OPERATOR_FAMILY, + 10 }, + + { "ALTER ROLE", + N_("change a database role"), + sql_help_ALTER_ROLE, + 20 }, + + { "ALTER SCHEMA", + N_("change the definition of a schema"), + sql_help_ALTER_SCHEMA, + 1 }, + + { "ALTER SEQUENCE", + N_("change the definition of a sequence generator"), + sql_help_ALTER_SEQUENCE, + 8 }, + + { "ALTER SERVER", + N_("change the definition of a foreign server"), + sql_help_ALTER_SERVER, + 3 }, + + { "ALTER TABLE", + N_("change the definition of a table"), + sql_help_ALTER_TABLE, + 52 }, + + { "ALTER TABLESPACE", + N_("change the definition of a tablespace"), + sql_help_ALTER_TABLESPACE, + 3 }, + + { "ALTER TEXT SEARCH CONFIGURATION", + N_("change the definition of a text search configuration"), + sql_help_ALTER_TEXT_SEARCH_CONFIGURATION, + 12 }, + + { "ALTER TEXT SEARCH DICTIONARY", + N_("change the definition of a text search dictionary"), + sql_help_ALTER_TEXT_SEARCH_DICTIONARY, + 5 }, + + { "ALTER TEXT SEARCH PARSER", + N_("change the definition of a text search parser"), + sql_help_ALTER_TEXT_SEARCH_PARSER, + 1 }, + + { "ALTER TEXT SEARCH TEMPLATE", + N_("change the definition of a text search template"), + sql_help_ALTER_TEXT_SEARCH_TEMPLATE, + 1 }, + + { "ALTER TRIGGER", + N_("change the definition of a trigger"), + sql_help_ALTER_TRIGGER, + 0 }, + + { "ALTER TYPE", + N_("change the definition of a type"), + sql_help_ALTER_TYPE, + 11 }, + + { "ALTER USER", + N_("change a database role"), + sql_help_ALTER_USER, + 20 }, + + { "ALTER USER MAPPING", + N_("change the definition of a user mapping"), + sql_help_ALTER_USER_MAPPING, + 2 }, + + { "ALTER VIEW", + N_("change the definition of a view"), + sql_help_ALTER_VIEW, + 6 }, + + { "ANALYZE", + N_("collect statistics about a database"), + sql_help_ANALYZE, + 0 }, + + { "BEGIN", + N_("start a transaction block"), + sql_help_BEGIN, + 6 }, + + { "CHECKPOINT", + N_("force a transaction log checkpoint"), + sql_help_CHECKPOINT, + 0 }, + + { "CLOSE", + N_("close a cursor"), + sql_help_CLOSE, + 0 }, + + { "CLUSTER", + N_("cluster a table according to an index"), + sql_help_CLUSTER, + 1 }, + + { "COMMENT", + N_("define or change the comment of an object"), + sql_help_COMMENT, + 34 }, + + { "COMMIT", + N_("commit the current transaction"), + sql_help_COMMIT, + 0 }, + + { "COMMIT PREPARED", + N_("commit a transaction that was earlier prepared for two-phase commit"), + sql_help_COMMIT_PREPARED, + 0 }, + + { "COPY", + N_("copy data between a file and a table"), + sql_help_COPY, + 19 }, + + { "CREATE AGGREGATE", + N_("define a new aggregate function"), + sql_help_CREATE_AGGREGATE, + 17 }, + + { "CREATE CAST", + N_("define a new cast"), + sql_help_CREATE_CAST, + 10 }, + + { "CREATE COLLATION", + N_("define a new collation"), + sql_help_CREATE_COLLATION, + 5 }, + + { "CREATE CONVERSION", + N_("define a new encoding conversion"), + sql_help_CREATE_CONVERSION, + 1 }, + + { "CREATE DATABASE", + N_("create a new database"), + sql_help_CREATE_DATABASE, + 7 }, + + { "CREATE DOMAIN", + N_("define a new domain"), + sql_help_CREATE_DOMAIN, + 8 }, + + { "CREATE EXTENSION", + N_("install an extension"), + sql_help_CREATE_EXTENSION, + 3 }, + + { "CREATE FOREIGN DATA WRAPPER", + N_("define a new foreign-data wrapper"), + sql_help_CREATE_FOREIGN_DATA_WRAPPER, + 3 }, + + { "CREATE FOREIGN TABLE", + N_("define a new foreign table"), + sql_help_CREATE_FOREIGN_TABLE, + 5 }, + + { "CREATE FUNCTION", + N_("define a new function"), + sql_help_CREATE_FUNCTION, + 15 }, + + { "CREATE GROUP", + N_("define a new database role"), + sql_help_CREATE_GROUP, + 17 }, + + { "CREATE INDEX", + N_("define a new index"), + sql_help_CREATE_INDEX, + 4 }, + + { "CREATE LANGUAGE", + N_("define a new procedural language"), + sql_help_CREATE_LANGUAGE, + 2 }, + + { "CREATE OPERATOR", + N_("define a new operator"), + sql_help_CREATE_OPERATOR, + 6 }, + + { "CREATE OPERATOR CLASS", + N_("define a new operator class"), + sql_help_CREATE_OPERATOR_CLASS, + 5 }, + + { "CREATE OPERATOR FAMILY", + N_("define a new operator family"), + sql_help_CREATE_OPERATOR_FAMILY, + 0 }, + + { "CREATE ROLE", + N_("define a new database role"), + sql_help_CREATE_ROLE, + 19 }, + + { "CREATE RULE", + N_("define a new rewrite rule"), + sql_help_CREATE_RULE, + 2 }, + + { "CREATE SCHEMA", + N_("define a new schema"), + sql_help_CREATE_SCHEMA, + 1 }, + + { "CREATE SEQUENCE", + N_("define a new sequence generator"), + sql_help_CREATE_SEQUENCE, + 3 }, + + { "CREATE SERVER", + N_("define a new foreign server"), + sql_help_CREATE_SERVER, + 2 }, + + { "CREATE TABLE", + N_("define a new table"), + sql_help_CREATE_TABLE, + 56 }, + + { "CREATE TABLE AS", + N_("define a new table from the results of a query"), + sql_help_CREATE_TABLE_AS, + 6 }, + + { "CREATE TABLESPACE", + N_("define a new tablespace"), + sql_help_CREATE_TABLESPACE, + 0 }, + + { "CREATE TEXT SEARCH CONFIGURATION", + N_("define a new text search configuration"), + sql_help_CREATE_TEXT_SEARCH_CONFIGURATION, + 3 }, + + { "CREATE TEXT SEARCH DICTIONARY", + N_("define a new text search dictionary"), + sql_help_CREATE_TEXT_SEARCH_DICTIONARY, + 3 }, + + { "CREATE TEXT SEARCH PARSER", + N_("define a new text search parser"), + sql_help_CREATE_TEXT_SEARCH_PARSER, + 6 }, + + { "CREATE TEXT SEARCH TEMPLATE", + N_("define a new text search template"), + sql_help_CREATE_TEXT_SEARCH_TEMPLATE, + 3 }, + + { "CREATE TRIGGER", + N_("define a new trigger"), + sql_help_CREATE_TRIGGER, + 13 }, + + { "CREATE TYPE", + N_("define a new data type"), + sql_help_CREATE_TYPE, + 35 }, + + { "CREATE USER", + N_("define a new database role"), + sql_help_CREATE_USER, + 19 }, + + { "CREATE USER MAPPING", + N_("define a new mapping of a user to a foreign server"), + sql_help_CREATE_USER_MAPPING, + 2 }, + + { "CREATE VIEW", + N_("define a new view"), + sql_help_CREATE_VIEW, + 2 }, + + { "DEALLOCATE", + N_("deallocate a prepared statement"), + sql_help_DEALLOCATE, + 0 }, + + { "DECLARE", + N_("define a cursor"), + sql_help_DECLARE, + 1 }, + + { "DELETE", + N_("delete rows of a table"), + sql_help_DELETE, + 4 }, + + { "DISCARD", + N_("discard session state"), + sql_help_DISCARD, + 0 }, + + { "DO", + N_("execute an anonymous code block"), + sql_help_DO, + 0 }, + + { "DROP AGGREGATE", + N_("remove an aggregate function"), + sql_help_DROP_AGGREGATE, + 0 }, + + { "DROP CAST", + N_("remove a cast"), + sql_help_DROP_CAST, + 0 }, + + { "DROP COLLATION", + N_("remove a collation"), + sql_help_DROP_COLLATION, + 0 }, + + { "DROP CONVERSION", + N_("remove a conversion"), + sql_help_DROP_CONVERSION, + 0 }, + + { "DROP DATABASE", + N_("remove a database"), + sql_help_DROP_DATABASE, + 0 }, + + { "DROP DOMAIN", + N_("remove a domain"), + sql_help_DROP_DOMAIN, + 0 }, + + { "DROP EXTENSION", + N_("remove an extension"), + sql_help_DROP_EXTENSION, + 0 }, + + { "DROP FOREIGN DATA WRAPPER", + N_("remove a foreign-data wrapper"), + sql_help_DROP_FOREIGN_DATA_WRAPPER, + 0 }, + + { "DROP FOREIGN TABLE", + N_("remove a foreign table"), + sql_help_DROP_FOREIGN_TABLE, + 0 }, + + { "DROP FUNCTION", + N_("remove a function"), + sql_help_DROP_FUNCTION, + 1 }, + + { "DROP GROUP", + N_("remove a database role"), + sql_help_DROP_GROUP, + 0 }, + + { "DROP INDEX", + N_("remove an index"), + sql_help_DROP_INDEX, + 0 }, + + { "DROP LANGUAGE", + N_("remove a procedural language"), + sql_help_DROP_LANGUAGE, + 0 }, + + { "DROP OPERATOR", + N_("remove an operator"), + sql_help_DROP_OPERATOR, + 0 }, + + { "DROP OPERATOR CLASS", + N_("remove an operator class"), + sql_help_DROP_OPERATOR_CLASS, + 0 }, + + { "DROP OPERATOR FAMILY", + N_("remove an operator family"), + sql_help_DROP_OPERATOR_FAMILY, + 0 }, + + { "DROP OWNED", + N_("remove database objects owned by a database role"), + sql_help_DROP_OWNED, + 0 }, + + { "DROP ROLE", + N_("remove a database role"), + sql_help_DROP_ROLE, + 0 }, + + { "DROP RULE", + N_("remove a rewrite rule"), + sql_help_DROP_RULE, + 0 }, + + { "DROP SCHEMA", + N_("remove a schema"), + sql_help_DROP_SCHEMA, + 0 }, + + { "DROP SEQUENCE", + N_("remove a sequence"), + sql_help_DROP_SEQUENCE, + 0 }, + + { "DROP SERVER", + N_("remove a foreign server descriptor"), + sql_help_DROP_SERVER, + 0 }, + + { "DROP TABLE", + N_("remove a table"), + sql_help_DROP_TABLE, + 0 }, + + { "DROP TABLESPACE", + N_("remove a tablespace"), + sql_help_DROP_TABLESPACE, + 0 }, + + { "DROP TEXT SEARCH CONFIGURATION", + N_("remove a text search configuration"), + sql_help_DROP_TEXT_SEARCH_CONFIGURATION, + 0 }, + + { "DROP TEXT SEARCH DICTIONARY", + N_("remove a text search dictionary"), + sql_help_DROP_TEXT_SEARCH_DICTIONARY, + 0 }, + + { "DROP TEXT SEARCH PARSER", + N_("remove a text search parser"), + sql_help_DROP_TEXT_SEARCH_PARSER, + 0 }, + + { "DROP TEXT SEARCH TEMPLATE", + N_("remove a text search template"), + sql_help_DROP_TEXT_SEARCH_TEMPLATE, + 0 }, + + { "DROP TRIGGER", + N_("remove a trigger"), + sql_help_DROP_TRIGGER, + 0 }, + + { "DROP TYPE", + N_("remove a data type"), + sql_help_DROP_TYPE, + 0 }, + + { "DROP USER", + N_("remove a database role"), + sql_help_DROP_USER, + 0 }, + + { "DROP USER MAPPING", + N_("remove a user mapping for a foreign server"), + sql_help_DROP_USER_MAPPING, + 0 }, + + { "DROP VIEW", + N_("remove a view"), + sql_help_DROP_VIEW, + 0 }, + + { "END", + N_("commit the current transaction"), + sql_help_END, + 0 }, + + { "EXECUTE", + N_("execute a prepared statement"), + sql_help_EXECUTE, + 0 }, + + { "EXPLAIN", + N_("show the execution plan of a statement"), + sql_help_EXPLAIN, + 10 }, + + { "FETCH", + N_("retrieve rows from a query using a cursor"), + sql_help_FETCH, + 17 }, + + { "GRANT", + N_("define access privileges"), + sql_help_GRANT, + 58 }, + + { "INSERT", + N_("create new rows in a table"), + sql_help_INSERT, + 3 }, + + { "LISTEN", + N_("listen for a notification"), + sql_help_LISTEN, + 0 }, + + { "LOAD", + N_("load a shared library file"), + sql_help_LOAD, + 0 }, + + { "LOCK", + N_("lock a table"), + sql_help_LOCK, + 5 }, + + { "MOVE", + N_("position a cursor"), + sql_help_MOVE, + 17 }, + + { "NOTIFY", + N_("generate a notification"), + sql_help_NOTIFY, + 0 }, + + { "PREPARE", + N_("prepare a statement for execution"), + sql_help_PREPARE, + 0 }, + + { "PREPARE TRANSACTION", + N_("prepare the current transaction for two-phase commit"), + sql_help_PREPARE_TRANSACTION, + 0 }, + + { "REASSIGN OWNED", + N_("change the ownership of database objects owned by a database role"), + sql_help_REASSIGN_OWNED, + 0 }, + + { "REINDEX", + N_("rebuild indexes"), + sql_help_REINDEX, + 0 }, + + { "RELEASE SAVEPOINT", + N_("destroy a previously defined savepoint"), + sql_help_RELEASE_SAVEPOINT, + 0 }, + + { "RESET", + N_("restore the value of a run-time parameter to the default value"), + sql_help_RESET, + 1 }, + + { "REVOKE", + N_("remove access privileges"), + sql_help_REVOKE, + 86 }, + + { "ROLLBACK", + N_("abort the current transaction"), + sql_help_ROLLBACK, + 0 }, + + { "ROLLBACK PREPARED", + N_("cancel a transaction that was earlier prepared for two-phase commit"), + sql_help_ROLLBACK_PREPARED, + 0 }, + + { "ROLLBACK TO SAVEPOINT", + N_("roll back to a savepoint"), + sql_help_ROLLBACK_TO_SAVEPOINT, + 0 }, + + { "SAVEPOINT", + N_("define a new savepoint within the current transaction"), + sql_help_SAVEPOINT, + 0 }, + + { "SECURITY LABEL", + N_("define or change a security label applied to an object"), + sql_help_SECURITY_LABEL, + 17 }, + + { "SELECT", + N_("retrieve rows from a table or view"), + sql_help_SELECT, + 28 }, + + { "SELECT INTO", + N_("define a new table from the results of a query"), + sql_help_SELECT_INTO, + 14 }, + + { "SET", + N_("change a run-time parameter"), + sql_help_SET, + 1 }, + + { "SET CONSTRAINTS", + N_("set constraint check timing for the current transaction"), + sql_help_SET_CONSTRAINTS, + 0 }, + + { "SET ROLE", + N_("set the current user identifier of the current session"), + sql_help_SET_ROLE, + 2 }, + + { "SET SESSION AUTHORIZATION", + N_("set the session user identifier and the current user identifier of the current session"), + sql_help_SET_SESSION_AUTHORIZATION, + 2 }, + + { "SET TRANSACTION", + N_("set the characteristics of the current transaction"), + sql_help_SET_TRANSACTION, + 8 }, + + { "SHOW", + N_("show the value of a run-time parameter"), + sql_help_SHOW, + 1 }, + + { "START TRANSACTION", + N_("start a transaction block"), + sql_help_START_TRANSACTION, + 6 }, + + { "TABLE", + N_("retrieve rows from a table or view"), + sql_help_TABLE, + 28 }, + + { "TRUNCATE", + N_("empty a table or set of tables"), + sql_help_TRUNCATE, + 1 }, + + { "UNLISTEN", + N_("stop listening for a notification"), + sql_help_UNLISTEN, + 0 }, + + { "UPDATE", + N_("update rows of a table"), + sql_help_UPDATE, + 6 }, + + { "VACUUM", + N_("garbage-collect and optionally analyze a database"), + sql_help_VACUUM, + 2 }, + + { "VALUES", + N_("compute a set of rows"), + sql_help_VALUES, + 4 }, + + { "WITH", + N_("retrieve rows from a table or view"), + sql_help_WITH, + 28 }, + + + { NULL, NULL, NULL } /* End of list marker */ +}; + + +#define QL_HELP_COUNT 152 /* number of help items */ +#define QL_MAX_CMD_LEN 32 /* largest strlen(cmd) */ + + +#endif /* SQL_HELP_H */ diff --git a/src/bin/scripts/.gitignore b/src/bin/scripts/.gitignore deleted file mode 100644 index e62f4b03a..000000000 --- a/src/bin/scripts/.gitignore +++ /dev/null @@ -1,15 +0,0 @@ -/clusterdb -/createdb -/createlang -/createuser -/dropdb -/droplang -/dropuser -/reindexdb -/vacuumdb - -/dumputils.c -/keywords.c -/kwlookup.c -/mbprint.c -/print.c diff --git a/src/include/.gitignore b/src/include/.gitignore deleted file mode 100644 index fa285a160..000000000 --- a/src/include/.gitignore +++ /dev/null @@ -1,5 +0,0 @@ -/stamp-h -/pg_config.h -/pg_config_os.h -/dynloader.h - diff --git a/src/include/catalog/.gitignore b/src/include/catalog/.gitignore deleted file mode 100644 index 650202eb7..000000000 --- a/src/include/catalog/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/schemapg.h diff --git a/src/include/parser/.gitignore b/src/include/parser/.gitignore deleted file mode 100644 index 19ea9554a..000000000 --- a/src/include/parser/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/gram.h diff --git a/src/include/utils/.gitignore b/src/include/utils/.gitignore deleted file mode 100644 index 808826d14..000000000 --- a/src/include/utils/.gitignore +++ /dev/null @@ -1,3 +0,0 @@ -/fmgroids.h -/probes.h -/errcodes.h diff --git a/src/interfaces/ecpg/compatlib/.gitignore b/src/interfaces/ecpg/compatlib/.gitignore deleted file mode 100644 index 926385c6b..000000000 --- a/src/interfaces/ecpg/compatlib/.gitignore +++ /dev/null @@ -1,3 +0,0 @@ -/compatlib.def -/blibecpg_compatdll.def -/exports.list diff --git a/src/interfaces/ecpg/compatlib/blibecpg_compatdll.def b/src/interfaces/ecpg/compatlib/blibecpg_compatdll.def new file mode 100644 index 000000000..1056b3686 --- /dev/null +++ b/src/interfaces/ecpg/compatlib/blibecpg_compatdll.def @@ -0,0 +1,89 @@ +; DEF file for Borland C++ Builder +LIBRARY BLIBECPG_COMPAT +EXPORTS + _ECPG_informix_get_var @ 1 + _ECPG_informix_set_var @ 2 + _decadd @ 3 + _deccmp @ 4 + _deccopy @ 5 + _deccvasc @ 6 + _deccvdbl @ 7 + _deccvint @ 8 + _deccvlong @ 9 + _decdiv @ 10 + _decmul @ 11 + _decsub @ 12 + _dectoasc @ 13 + _dectodbl @ 14 + _dectoint @ 15 + _dectolong @ 16 + _dtcurrent @ 17 + _dtcvasc @ 18 + _dtcvfmtasc @ 19 + _dtsub @ 20 + _dttoasc @ 21 + _dttofmtasc @ 22 + _intoasc @ 23 + _rdatestr @ 24 + _rdayofweek @ 25 + _rdefmtdate @ 26 + _rfmtdate @ 27 + _rfmtlong @ 28 + _rgetmsg @ 29 + _risnull @ 30 + _rjulmdy @ 31 + _rmdyjul @ 32 + _rsetnull @ 33 + _rstrdate @ 34 + _rtoday @ 35 + _rtypalign @ 36 + _rtypmsize @ 37 + _rtypwidth @ 38 + _rupshift @ 39 + _ldchar @ 40 + _byleng @ 41 + _ECPG_informix_reset_sqlca @ 42 + +; Aliases for MS compatible names + ECPG_informix_get_var = _ECPG_informix_get_var + ECPG_informix_set_var = _ECPG_informix_set_var + decadd = _decadd + deccmp = _deccmp + deccopy = _deccopy + deccvasc = _deccvasc + deccvdbl = _deccvdbl + deccvint = _deccvint + deccvlong = _deccvlong + decdiv = _decdiv + decmul = _decmul + decsub = _decsub + dectoasc = _dectoasc + dectodbl = _dectodbl + dectoint = _dectoint + dectolong = _dectolong + dtcurrent = _dtcurrent + dtcvasc = _dtcvasc + dtcvfmtasc = _dtcvfmtasc + dtsub = _dtsub + dttoasc = _dttoasc + dttofmtasc = _dttofmtasc + intoasc = _intoasc + rdatestr = _rdatestr + rdayofweek = _rdayofweek + rdefmtdate = _rdefmtdate + rfmtdate = _rfmtdate + rfmtlong = _rfmtlong + rgetmsg = _rgetmsg + risnull = _risnull + rjulmdy = _rjulmdy + rmdyjul = _rmdyjul + rsetnull = _rsetnull + rstrdate = _rstrdate + rtoday = _rtoday + rtypalign = _rtypalign + rtypmsize = _rtypmsize + rtypwidth = _rtypwidth + rupshift = _rupshift + ldchar = _ldchar + byleng = _byleng + ECPG_informix_reset_sqlca = _ECPG_informix_reset_sqlca diff --git a/src/interfaces/ecpg/compatlib/libecpg_compatddll.def b/src/interfaces/ecpg/compatlib/libecpg_compatddll.def new file mode 100644 index 000000000..941643b29 --- /dev/null +++ b/src/interfaces/ecpg/compatlib/libecpg_compatddll.def @@ -0,0 +1,45 @@ +; DEF file for MS VC++ +LIBRARY LIBECPG_COMPATD +EXPORTS + ECPG_informix_get_var @ 1 + ECPG_informix_set_var @ 2 + decadd @ 3 + deccmp @ 4 + deccopy @ 5 + deccvasc @ 6 + deccvdbl @ 7 + deccvint @ 8 + deccvlong @ 9 + decdiv @ 10 + decmul @ 11 + decsub @ 12 + dectoasc @ 13 + dectodbl @ 14 + dectoint @ 15 + dectolong @ 16 + dtcurrent @ 17 + dtcvasc @ 18 + dtcvfmtasc @ 19 + dtsub @ 20 + dttoasc @ 21 + dttofmtasc @ 22 + intoasc @ 23 + rdatestr @ 24 + rdayofweek @ 25 + rdefmtdate @ 26 + rfmtdate @ 27 + rfmtlong @ 28 + rgetmsg @ 29 + risnull @ 30 + rjulmdy @ 31 + rmdyjul @ 32 + rsetnull @ 33 + rstrdate @ 34 + rtoday @ 35 + rtypalign @ 36 + rtypmsize @ 37 + rtypwidth @ 38 + rupshift @ 39 + ldchar @ 40 + byleng @ 41 + ECPG_informix_reset_sqlca @ 42 diff --git a/src/interfaces/ecpg/compatlib/libecpg_compatdll.def b/src/interfaces/ecpg/compatlib/libecpg_compatdll.def new file mode 100644 index 000000000..cdbac6067 --- /dev/null +++ b/src/interfaces/ecpg/compatlib/libecpg_compatdll.def @@ -0,0 +1,45 @@ +; DEF file for MS VC++ +LIBRARY LIBECPG_COMPAT +EXPORTS + ECPG_informix_get_var @ 1 + ECPG_informix_set_var @ 2 + decadd @ 3 + deccmp @ 4 + deccopy @ 5 + deccvasc @ 6 + deccvdbl @ 7 + deccvint @ 8 + deccvlong @ 9 + decdiv @ 10 + decmul @ 11 + decsub @ 12 + dectoasc @ 13 + dectodbl @ 14 + dectoint @ 15 + dectolong @ 16 + dtcurrent @ 17 + dtcvasc @ 18 + dtcvfmtasc @ 19 + dtsub @ 20 + dttoasc @ 21 + dttofmtasc @ 22 + intoasc @ 23 + rdatestr @ 24 + rdayofweek @ 25 + rdefmtdate @ 26 + rfmtdate @ 27 + rfmtlong @ 28 + rgetmsg @ 29 + risnull @ 30 + rjulmdy @ 31 + rmdyjul @ 32 + rsetnull @ 33 + rstrdate @ 34 + rtoday @ 35 + rtypalign @ 36 + rtypmsize @ 37 + rtypwidth @ 38 + rupshift @ 39 + ldchar @ 40 + byleng @ 41 + ECPG_informix_reset_sqlca @ 42 diff --git a/src/interfaces/ecpg/ecpglib/.gitignore b/src/interfaces/ecpg/ecpglib/.gitignore deleted file mode 100644 index 351f43775..000000000 --- a/src/interfaces/ecpg/ecpglib/.gitignore +++ /dev/null @@ -1,8 +0,0 @@ -/ecpglib.def -/blibecpgdll.def -/exports.list - -/path.c -/pgstrcasecmp.c -/strlcpy.c -/thread.c diff --git a/src/interfaces/ecpg/ecpglib/blibecpgdll.def b/src/interfaces/ecpg/ecpglib/blibecpgdll.def new file mode 100644 index 000000000..328e2fdb1 --- /dev/null +++ b/src/interfaces/ecpg/ecpglib/blibecpgdll.def @@ -0,0 +1,63 @@ +; DEF file for Borland C++ Builder +LIBRARY BLIBECPG +EXPORTS + _ECPGallocate_desc @ 1 + _ECPGconnect @ 2 + _ECPGdeallocate @ 3 + _ECPGdeallocate_all @ 4 + _ECPGdeallocate_desc @ 5 + _ECPGdebug @ 6 + _ECPGdescribe @ 7 + _ECPGdisconnect @ 8 + _ECPGdo @ 9 + _ECPGdo_descriptor @ 10 + _ECPGfree_auto_mem @ 11 + _ECPGget_desc @ 12 + _ECPGget_desc_header @ 13 + _ECPGget_sqlca @ 14 + _ECPGis_noind_null @ 15 + _ECPGprepare @ 16 + _ECPGprepared_statement @ 17 + _ECPGset_desc @ 18 + _ECPGset_desc_header @ 19 + _ECPGset_noind_null @ 20 + _ECPGsetcommit @ 21 + _ECPGsetconn @ 22 + _ECPGstatus @ 23 + _ECPGtrans @ 24 + _sqlprint @ 25 + _ECPGget_PGconn @ 26 + _ECPGtransactionStatus @ 27 + _ECPGset_var @ 28 + _ECPGget_var @ 29 + +; Aliases for MS compatible names + ECPGallocate_desc = _ECPGallocate_desc + ECPGconnect = _ECPGconnect + ECPGdeallocate = _ECPGdeallocate + ECPGdeallocate_all = _ECPGdeallocate_all + ECPGdeallocate_desc = _ECPGdeallocate_desc + ECPGdebug = _ECPGdebug + ECPGdescribe = _ECPGdescribe + ECPGdisconnect = _ECPGdisconnect + ECPGdo = _ECPGdo + ECPGdo_descriptor = _ECPGdo_descriptor + ECPGfree_auto_mem = _ECPGfree_auto_mem + ECPGget_desc = _ECPGget_desc + ECPGget_desc_header = _ECPGget_desc_header + ECPGget_sqlca = _ECPGget_sqlca + ECPGis_noind_null = _ECPGis_noind_null + ECPGprepare = _ECPGprepare + ECPGprepared_statement = _ECPGprepared_statement + ECPGset_desc = _ECPGset_desc + ECPGset_desc_header = _ECPGset_desc_header + ECPGset_noind_null = _ECPGset_noind_null + ECPGsetcommit = _ECPGsetcommit + ECPGsetconn = _ECPGsetconn + ECPGstatus = _ECPGstatus + ECPGtrans = _ECPGtrans + sqlprint = _sqlprint + ECPGget_PGconn = _ECPGget_PGconn + ECPGtransactionStatus = _ECPGtransactionStatus + ECPGset_var = _ECPGset_var + ECPGget_var = _ECPGget_var diff --git a/src/interfaces/ecpg/ecpglib/libecpgddll.def b/src/interfaces/ecpg/ecpglib/libecpgddll.def new file mode 100644 index 000000000..6a8f53b93 --- /dev/null +++ b/src/interfaces/ecpg/ecpglib/libecpgddll.def @@ -0,0 +1,32 @@ +; DEF file for MS VC++ +LIBRARY LIBECPGD +EXPORTS + ECPGallocate_desc @ 1 + ECPGconnect @ 2 + ECPGdeallocate @ 3 + ECPGdeallocate_all @ 4 + ECPGdeallocate_desc @ 5 + ECPGdebug @ 6 + ECPGdescribe @ 7 + ECPGdisconnect @ 8 + ECPGdo @ 9 + ECPGdo_descriptor @ 10 + ECPGfree_auto_mem @ 11 + ECPGget_desc @ 12 + ECPGget_desc_header @ 13 + ECPGget_sqlca @ 14 + ECPGis_noind_null @ 15 + ECPGprepare @ 16 + ECPGprepared_statement @ 17 + ECPGset_desc @ 18 + ECPGset_desc_header @ 19 + ECPGset_noind_null @ 20 + ECPGsetcommit @ 21 + ECPGsetconn @ 22 + ECPGstatus @ 23 + ECPGtrans @ 24 + sqlprint @ 25 + ECPGget_PGconn @ 26 + ECPGtransactionStatus @ 27 + ECPGset_var @ 28 + ECPGget_var @ 29 diff --git a/src/interfaces/ecpg/ecpglib/libecpgdll.def b/src/interfaces/ecpg/ecpglib/libecpgdll.def new file mode 100644 index 000000000..212bcb823 --- /dev/null +++ b/src/interfaces/ecpg/ecpglib/libecpgdll.def @@ -0,0 +1,32 @@ +; DEF file for MS VC++ +LIBRARY LIBECPG +EXPORTS + ECPGallocate_desc @ 1 + ECPGconnect @ 2 + ECPGdeallocate @ 3 + ECPGdeallocate_all @ 4 + ECPGdeallocate_desc @ 5 + ECPGdebug @ 6 + ECPGdescribe @ 7 + ECPGdisconnect @ 8 + ECPGdo @ 9 + ECPGdo_descriptor @ 10 + ECPGfree_auto_mem @ 11 + ECPGget_desc @ 12 + ECPGget_desc_header @ 13 + ECPGget_sqlca @ 14 + ECPGis_noind_null @ 15 + ECPGprepare @ 16 + ECPGprepared_statement @ 17 + ECPGset_desc @ 18 + ECPGset_desc_header @ 19 + ECPGset_noind_null @ 20 + ECPGsetcommit @ 21 + ECPGsetconn @ 22 + ECPGstatus @ 23 + ECPGtrans @ 24 + sqlprint @ 25 + ECPGget_PGconn @ 26 + ECPGtransactionStatus @ 27 + ECPGset_var @ 28 + ECPGget_var @ 29 diff --git a/src/interfaces/ecpg/include/.gitignore b/src/interfaces/ecpg/include/.gitignore deleted file mode 100644 index 608493dbb..000000000 --- a/src/interfaces/ecpg/include/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -/ecpg_config.h -/stamp-h diff --git a/src/interfaces/ecpg/pgtypeslib/.gitignore b/src/interfaces/ecpg/pgtypeslib/.gitignore deleted file mode 100644 index 4ee58ea95..000000000 --- a/src/interfaces/ecpg/pgtypeslib/.gitignore +++ /dev/null @@ -1,5 +0,0 @@ -/pgtypeslib.def -/blibpgtypesdll.def -/exports.list - -/pgstrcasecmp.c diff --git a/src/interfaces/ecpg/pgtypeslib/blibpgtypesdll.def b/src/interfaces/ecpg/pgtypeslib/blibpgtypesdll.def new file mode 100644 index 000000000..650e08673 --- /dev/null +++ b/src/interfaces/ecpg/pgtypeslib/blibpgtypesdll.def @@ -0,0 +1,95 @@ +; DEF file for Borland C++ Builder +LIBRARY BLIBPGTYPES +EXPORTS + _PGTYPESdate_dayofweek @ 1 + _PGTYPESdate_defmt_asc @ 2 + _PGTYPESdate_fmt_asc @ 3 + _PGTYPESdate_free @ 4 + _PGTYPESdate_from_asc @ 5 + _PGTYPESdate_from_timestamp @ 6 + _PGTYPESdate_julmdy @ 7 + _PGTYPESdate_mdyjul @ 8 + _PGTYPESdate_new @ 9 + _PGTYPESdate_to_asc @ 10 + _PGTYPESdate_today @ 11 + _PGTYPESdecimal_free @ 12 + _PGTYPESdecimal_new @ 13 + _PGTYPESinterval_copy @ 14 + _PGTYPESinterval_free @ 15 + _PGTYPESinterval_from_asc @ 16 + _PGTYPESinterval_new @ 17 + _PGTYPESinterval_to_asc @ 18 + _PGTYPESnumeric_add @ 19 + _PGTYPESnumeric_cmp @ 20 + _PGTYPESnumeric_copy @ 21 + _PGTYPESnumeric_div @ 22 + _PGTYPESnumeric_free @ 23 + _PGTYPESnumeric_from_asc @ 24 + _PGTYPESnumeric_from_decimal @ 25 + _PGTYPESnumeric_from_double @ 26 + _PGTYPESnumeric_from_int @ 27 + _PGTYPESnumeric_from_long @ 28 + _PGTYPESnumeric_mul @ 29 + _PGTYPESnumeric_new @ 30 + _PGTYPESnumeric_sub @ 31 + _PGTYPESnumeric_to_asc @ 32 + _PGTYPESnumeric_to_decimal @ 33 + _PGTYPESnumeric_to_double @ 34 + _PGTYPESnumeric_to_int @ 35 + _PGTYPESnumeric_to_long @ 36 + _PGTYPEStimestamp_add_interval @ 37 + _PGTYPEStimestamp_current @ 38 + _PGTYPEStimestamp_defmt_asc @ 39 + _PGTYPEStimestamp_defmt_scan @ 40 + _PGTYPEStimestamp_fmt_asc @ 41 + _PGTYPEStimestamp_from_asc @ 42 + _PGTYPEStimestamp_sub @ 43 + _PGTYPEStimestamp_sub_interval @ 44 + _PGTYPEStimestamp_to_asc @ 45 + +; Aliases for MS compatible names + PGTYPESdate_dayofweek = _PGTYPESdate_dayofweek + PGTYPESdate_defmt_asc = _PGTYPESdate_defmt_asc + PGTYPESdate_fmt_asc = _PGTYPESdate_fmt_asc + PGTYPESdate_free = _PGTYPESdate_free + PGTYPESdate_from_asc = _PGTYPESdate_from_asc + PGTYPESdate_from_timestamp = _PGTYPESdate_from_timestamp + PGTYPESdate_julmdy = _PGTYPESdate_julmdy + PGTYPESdate_mdyjul = _PGTYPESdate_mdyjul + PGTYPESdate_new = _PGTYPESdate_new + PGTYPESdate_to_asc = _PGTYPESdate_to_asc + PGTYPESdate_today = _PGTYPESdate_today + PGTYPESdecimal_free = _PGTYPESdecimal_free + PGTYPESdecimal_new = _PGTYPESdecimal_new + PGTYPESinterval_copy = _PGTYPESinterval_copy + PGTYPESinterval_free = _PGTYPESinterval_free + PGTYPESinterval_from_asc = _PGTYPESinterval_from_asc + PGTYPESinterval_new = _PGTYPESinterval_new + PGTYPESinterval_to_asc = _PGTYPESinterval_to_asc + PGTYPESnumeric_add = _PGTYPESnumeric_add + PGTYPESnumeric_cmp = _PGTYPESnumeric_cmp + PGTYPESnumeric_copy = _PGTYPESnumeric_copy + PGTYPESnumeric_div = _PGTYPESnumeric_div + PGTYPESnumeric_free = _PGTYPESnumeric_free + PGTYPESnumeric_from_asc = _PGTYPESnumeric_from_asc + PGTYPESnumeric_from_decimal = _PGTYPESnumeric_from_decimal + PGTYPESnumeric_from_double = _PGTYPESnumeric_from_double + PGTYPESnumeric_from_int = _PGTYPESnumeric_from_int + PGTYPESnumeric_from_long = _PGTYPESnumeric_from_long + PGTYPESnumeric_mul = _PGTYPESnumeric_mul + PGTYPESnumeric_new = _PGTYPESnumeric_new + PGTYPESnumeric_sub = _PGTYPESnumeric_sub + PGTYPESnumeric_to_asc = _PGTYPESnumeric_to_asc + PGTYPESnumeric_to_decimal = _PGTYPESnumeric_to_decimal + PGTYPESnumeric_to_double = _PGTYPESnumeric_to_double + PGTYPESnumeric_to_int = _PGTYPESnumeric_to_int + PGTYPESnumeric_to_long = _PGTYPESnumeric_to_long + PGTYPEStimestamp_add_interval = _PGTYPEStimestamp_add_interval + PGTYPEStimestamp_current = _PGTYPEStimestamp_current + PGTYPEStimestamp_defmt_asc = _PGTYPEStimestamp_defmt_asc + PGTYPEStimestamp_defmt_scan = _PGTYPEStimestamp_defmt_scan + PGTYPEStimestamp_fmt_asc = _PGTYPEStimestamp_fmt_asc + PGTYPEStimestamp_from_asc = _PGTYPEStimestamp_from_asc + PGTYPEStimestamp_sub = _PGTYPEStimestamp_sub + PGTYPEStimestamp_sub_interval = _PGTYPEStimestamp_sub_interval + PGTYPEStimestamp_to_asc = _PGTYPEStimestamp_to_asc diff --git a/src/interfaces/ecpg/pgtypeslib/libpgtypesddll.def b/src/interfaces/ecpg/pgtypeslib/libpgtypesddll.def new file mode 100644 index 000000000..fa514a2a8 --- /dev/null +++ b/src/interfaces/ecpg/pgtypeslib/libpgtypesddll.def @@ -0,0 +1,48 @@ +; DEF file for MS VC++ +LIBRARY LIBPGTYPESD +EXPORTS + PGTYPESdate_dayofweek @ 1 + PGTYPESdate_defmt_asc @ 2 + PGTYPESdate_fmt_asc @ 3 + PGTYPESdate_free @ 4 + PGTYPESdate_from_asc @ 5 + PGTYPESdate_from_timestamp @ 6 + PGTYPESdate_julmdy @ 7 + PGTYPESdate_mdyjul @ 8 + PGTYPESdate_new @ 9 + PGTYPESdate_to_asc @ 10 + PGTYPESdate_today @ 11 + PGTYPESdecimal_free @ 12 + PGTYPESdecimal_new @ 13 + PGTYPESinterval_copy @ 14 + PGTYPESinterval_free @ 15 + PGTYPESinterval_from_asc @ 16 + PGTYPESinterval_new @ 17 + PGTYPESinterval_to_asc @ 18 + PGTYPESnumeric_add @ 19 + PGTYPESnumeric_cmp @ 20 + PGTYPESnumeric_copy @ 21 + PGTYPESnumeric_div @ 22 + PGTYPESnumeric_free @ 23 + PGTYPESnumeric_from_asc @ 24 + PGTYPESnumeric_from_decimal @ 25 + PGTYPESnumeric_from_double @ 26 + PGTYPESnumeric_from_int @ 27 + PGTYPESnumeric_from_long @ 28 + PGTYPESnumeric_mul @ 29 + PGTYPESnumeric_new @ 30 + PGTYPESnumeric_sub @ 31 + PGTYPESnumeric_to_asc @ 32 + PGTYPESnumeric_to_decimal @ 33 + PGTYPESnumeric_to_double @ 34 + PGTYPESnumeric_to_int @ 35 + PGTYPESnumeric_to_long @ 36 + PGTYPEStimestamp_add_interval @ 37 + PGTYPEStimestamp_current @ 38 + PGTYPEStimestamp_defmt_asc @ 39 + PGTYPEStimestamp_defmt_scan @ 40 + PGTYPEStimestamp_fmt_asc @ 41 + PGTYPEStimestamp_from_asc @ 42 + PGTYPEStimestamp_sub @ 43 + PGTYPEStimestamp_sub_interval @ 44 + PGTYPEStimestamp_to_asc @ 45 diff --git a/src/interfaces/ecpg/pgtypeslib/libpgtypesdll.def b/src/interfaces/ecpg/pgtypeslib/libpgtypesdll.def new file mode 100644 index 000000000..0c32f7cc2 --- /dev/null +++ b/src/interfaces/ecpg/pgtypeslib/libpgtypesdll.def @@ -0,0 +1,48 @@ +; DEF file for MS VC++ +LIBRARY LIBPGTYPES +EXPORTS + PGTYPESdate_dayofweek @ 1 + PGTYPESdate_defmt_asc @ 2 + PGTYPESdate_fmt_asc @ 3 + PGTYPESdate_free @ 4 + PGTYPESdate_from_asc @ 5 + PGTYPESdate_from_timestamp @ 6 + PGTYPESdate_julmdy @ 7 + PGTYPESdate_mdyjul @ 8 + PGTYPESdate_new @ 9 + PGTYPESdate_to_asc @ 10 + PGTYPESdate_today @ 11 + PGTYPESdecimal_free @ 12 + PGTYPESdecimal_new @ 13 + PGTYPESinterval_copy @ 14 + PGTYPESinterval_free @ 15 + PGTYPESinterval_from_asc @ 16 + PGTYPESinterval_new @ 17 + PGTYPESinterval_to_asc @ 18 + PGTYPESnumeric_add @ 19 + PGTYPESnumeric_cmp @ 20 + PGTYPESnumeric_copy @ 21 + PGTYPESnumeric_div @ 22 + PGTYPESnumeric_free @ 23 + PGTYPESnumeric_from_asc @ 24 + PGTYPESnumeric_from_decimal @ 25 + PGTYPESnumeric_from_double @ 26 + PGTYPESnumeric_from_int @ 27 + PGTYPESnumeric_from_long @ 28 + PGTYPESnumeric_mul @ 29 + PGTYPESnumeric_new @ 30 + PGTYPESnumeric_sub @ 31 + PGTYPESnumeric_to_asc @ 32 + PGTYPESnumeric_to_decimal @ 33 + PGTYPESnumeric_to_double @ 34 + PGTYPESnumeric_to_int @ 35 + PGTYPESnumeric_to_long @ 36 + PGTYPEStimestamp_add_interval @ 37 + PGTYPEStimestamp_current @ 38 + PGTYPEStimestamp_defmt_asc @ 39 + PGTYPEStimestamp_defmt_scan @ 40 + PGTYPEStimestamp_fmt_asc @ 41 + PGTYPEStimestamp_from_asc @ 42 + PGTYPEStimestamp_sub @ 43 + PGTYPEStimestamp_sub_interval @ 44 + PGTYPEStimestamp_to_asc @ 45 diff --git a/src/interfaces/ecpg/preproc/.gitignore b/src/interfaces/ecpg/preproc/.gitignore deleted file mode 100644 index 6fca9aff5..000000000 --- a/src/interfaces/ecpg/preproc/.gitignore +++ /dev/null @@ -1,7 +0,0 @@ -/preproc.y -/preproc.c -/preproc.h -/pgc.c - -/ecpg -/kwlookup.c diff --git a/src/interfaces/ecpg/preproc/pgc.c b/src/interfaces/ecpg/preproc/pgc.c new file mode 100644 index 000000000..b6073d91d --- /dev/null +++ b/src/interfaces/ecpg/preproc/pgc.c @@ -0,0 +1,5158 @@ +#line 2 "pgc.c" + +#line 4 "pgc.c" + +#define YY_INT_ALIGNED short int + +/* A lexical scanner generated by flex */ + +#define FLEX_SCANNER +#define YY_FLEX_MAJOR_VERSION 2 +#define YY_FLEX_MINOR_VERSION 5 +#define YY_FLEX_SUBMINOR_VERSION 35 +#if YY_FLEX_SUBMINOR_VERSION > 0 +#define FLEX_BETA +#endif + +/* First, we deal with platform-specific or compiler-specific issues. */ + +/* begin standard C headers. */ +#include +#include +#include +#include + +/* end standard C headers. */ + +/* flex integer type definitions */ + +#ifndef FLEXINT_H +#define FLEXINT_H + +/* C99 systems have . Non-C99 systems may or may not. */ + +#if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L + +/* C99 says to define __STDC_LIMIT_MACROS before including stdint.h, + * if you want the limit (max/min) macros for int types. + */ +#ifndef __STDC_LIMIT_MACROS +#define __STDC_LIMIT_MACROS 1 +#endif + +#include +typedef int8_t flex_int8_t; +typedef uint8_t flex_uint8_t; +typedef int16_t flex_int16_t; +typedef uint16_t flex_uint16_t; +typedef int32_t flex_int32_t; +typedef uint32_t flex_uint32_t; +#else +typedef signed char flex_int8_t; +typedef short int flex_int16_t; +typedef int flex_int32_t; +typedef unsigned char flex_uint8_t; +typedef unsigned short int flex_uint16_t; +typedef unsigned int flex_uint32_t; + +/* Limits of integral types. */ +#ifndef INT8_MIN +#define INT8_MIN (-128) +#endif +#ifndef INT16_MIN +#define INT16_MIN (-32767-1) +#endif +#ifndef INT32_MIN +#define INT32_MIN (-2147483647-1) +#endif +#ifndef INT8_MAX +#define INT8_MAX (127) +#endif +#ifndef INT16_MAX +#define INT16_MAX (32767) +#endif +#ifndef INT32_MAX +#define INT32_MAX (2147483647) +#endif +#ifndef UINT8_MAX +#define UINT8_MAX (255U) +#endif +#ifndef UINT16_MAX +#define UINT16_MAX (65535U) +#endif +#ifndef UINT32_MAX +#define UINT32_MAX (4294967295U) +#endif + +#endif /* ! C99 */ + +#endif /* ! FLEXINT_H */ + +#ifdef __cplusplus + +/* The "const" storage-class-modifier is valid. */ +#define YY_USE_CONST + +#else /* ! __cplusplus */ + +/* C99 requires __STDC__ to be defined as 1. */ +#if defined (__STDC__) + +#define YY_USE_CONST + +#endif /* defined (__STDC__) */ +#endif /* ! __cplusplus */ + +#ifdef YY_USE_CONST +#define yyconst const +#else +#define yyconst +#endif + +/* Returned upon end-of-file. */ +#define YY_NULL 0 + +/* Promotes a possibly negative, possibly signed char to an unsigned + * integer for use as an array index. If the signed char is negative, + * we want to instead treat it as an 8-bit unsigned char, hence the + * double cast. + */ +#define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c) + +/* Enter a start condition. This macro really ought to take a parameter, + * but we do it the disgusting crufty way forced on us by the ()-less + * definition of BEGIN. + */ +#define BEGIN (yy_start) = 1 + 2 * + +/* Translate the current start state into a value that can be later handed + * to BEGIN to return to the state. The YYSTATE alias is for lex + * compatibility. + */ +#define YY_START (((yy_start) - 1) / 2) +#define YYSTATE YY_START + +/* Action number for EOF rule of a given start state. */ +#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1) + +/* Special action meaning "start processing a new file". */ +#define YY_NEW_FILE yyrestart(yyin ) + +#define YY_END_OF_BUFFER_CHAR 0 + +/* Size of default input buffer. */ +#ifndef YY_BUF_SIZE +#ifdef __ia64__ +/* On IA-64, the buffer size is 16k, not 8k. + * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case. + * Ditto for the __ia64__ case accordingly. + */ +#define YY_BUF_SIZE 32768 +#else +#define YY_BUF_SIZE 16384 +#endif /* __ia64__ */ +#endif + +/* The state buf must be large enough to hold one state per character in the main buffer. + */ +#define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type)) + +#ifndef YY_TYPEDEF_YY_BUFFER_STATE +#define YY_TYPEDEF_YY_BUFFER_STATE +typedef struct yy_buffer_state *YY_BUFFER_STATE; +#endif + +extern int yyleng; + +extern FILE *yyin, *yyout; + +#define EOB_ACT_CONTINUE_SCAN 0 +#define EOB_ACT_END_OF_FILE 1 +#define EOB_ACT_LAST_MATCH 2 + + /* Note: We specifically omit the test for yy_rule_can_match_eol because it requires + * access to the local variable yy_act. Since yyless() is a macro, it would break + * existing scanners that call yyless() from OUTSIDE yylex. + * One obvious solution it to make yy_act a global. I tried that, and saw + * a 5% performance hit in a non-yylineno scanner, because yy_act is + * normally declared as a register variable-- so it is not worth it. + */ + #define YY_LESS_LINENO(n) \ + do { \ + int yyl;\ + for ( yyl = n; yyl < yyleng; ++yyl )\ + if ( yytext[yyl] == '\n' )\ + --yylineno;\ + }while(0) + +/* Return all but the first "n" matched characters back to the input stream. */ +#define yyless(n) \ + do \ + { \ + /* Undo effects of setting up yytext. */ \ + int yyless_macro_arg = (n); \ + YY_LESS_LINENO(yyless_macro_arg);\ + *yy_cp = (yy_hold_char); \ + YY_RESTORE_YY_MORE_OFFSET \ + (yy_c_buf_p) = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \ + YY_DO_BEFORE_ACTION; /* set up yytext again */ \ + } \ + while ( 0 ) + +#define unput(c) yyunput( c, (yytext_ptr) ) + +#ifndef YY_TYPEDEF_YY_SIZE_T +#define YY_TYPEDEF_YY_SIZE_T +typedef size_t yy_size_t; +#endif + +#ifndef YY_STRUCT_YY_BUFFER_STATE +#define YY_STRUCT_YY_BUFFER_STATE +struct yy_buffer_state + { + FILE *yy_input_file; + + char *yy_ch_buf; /* input buffer */ + char *yy_buf_pos; /* current position in input buffer */ + + /* Size of input buffer in bytes, not including room for EOB + * characters. + */ + yy_size_t yy_buf_size; + + /* Number of characters read into yy_ch_buf, not including EOB + * characters. + */ + int yy_n_chars; + + /* Whether we "own" the buffer - i.e., we know we created it, + * and can realloc() it to grow it, and should free() it to + * delete it. + */ + int yy_is_our_buffer; + + /* Whether this is an "interactive" input source; if so, and + * if we're using stdio for input, then we want to use getc() + * instead of fread(), to make sure we stop fetching input after + * each newline. + */ + int yy_is_interactive; + + /* Whether we're considered to be at the beginning of a line. + * If so, '^' rules will be active on the next match, otherwise + * not. + */ + int yy_at_bol; + + int yy_bs_lineno; /**< The line count. */ + int yy_bs_column; /**< The column count. */ + + /* Whether to try to fill the input buffer when we reach the + * end of it. + */ + int yy_fill_buffer; + + int yy_buffer_status; + +#define YY_BUFFER_NEW 0 +#define YY_BUFFER_NORMAL 1 + /* When an EOF's been seen but there's still some text to process + * then we mark the buffer as YY_EOF_PENDING, to indicate that we + * shouldn't try reading from the input source any more. We might + * still have a bunch of tokens to match, though, because of + * possible backing-up. + * + * When we actually see the EOF, we change the status to "new" + * (via yyrestart()), so that the user can continue scanning by + * just pointing yyin at a new input file. + */ +#define YY_BUFFER_EOF_PENDING 2 + + }; +#endif /* !YY_STRUCT_YY_BUFFER_STATE */ + +/* Stack of input buffers. */ +static size_t yy_buffer_stack_top = 0; /**< index of top of stack. */ +static size_t yy_buffer_stack_max = 0; /**< capacity of stack. */ +static YY_BUFFER_STATE * yy_buffer_stack = 0; /**< Stack as an array. */ + +/* We provide macros for accessing buffer states in case in the + * future we want to put the buffer states in a more general + * "scanner state". + * + * Returns the top of the stack, or NULL. + */ +#define YY_CURRENT_BUFFER ( (yy_buffer_stack) \ + ? (yy_buffer_stack)[(yy_buffer_stack_top)] \ + : NULL) + +/* Same as previous macro, but useful when we know that the buffer stack is not + * NULL or when we need an lvalue. For internal use only. + */ +#define YY_CURRENT_BUFFER_LVALUE (yy_buffer_stack)[(yy_buffer_stack_top)] + +/* yy_hold_char holds the character lost when yytext is formed. */ +static char yy_hold_char; +static int yy_n_chars; /* number of characters read into yy_ch_buf */ +int yyleng; + +/* Points to current character in buffer. */ +static char *yy_c_buf_p = (char *) 0; +static int yy_init = 0; /* whether we need to initialize */ +static int yy_start = 0; /* start state number */ + +/* Flag which is used to allow yywrap()'s to do buffer switches + * instead of setting up a fresh yyin. A bit of a hack ... + */ +static int yy_did_buffer_switch_on_eof; + +void yyrestart (FILE *input_file ); +void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer ); +YY_BUFFER_STATE yy_create_buffer (FILE *file,int size ); +void yy_delete_buffer (YY_BUFFER_STATE b ); +void yy_flush_buffer (YY_BUFFER_STATE b ); +void yypush_buffer_state (YY_BUFFER_STATE new_buffer ); +void yypop_buffer_state (void ); + +static void yyensure_buffer_stack (void ); +static void yy_load_buffer_state (void ); +static void yy_init_buffer (YY_BUFFER_STATE b,FILE *file ); + +#define YY_FLUSH_BUFFER yy_flush_buffer(YY_CURRENT_BUFFER ) + +YY_BUFFER_STATE yy_scan_buffer (char *base,yy_size_t size ); +YY_BUFFER_STATE yy_scan_string (yyconst char *yy_str ); +YY_BUFFER_STATE yy_scan_bytes (yyconst char *bytes,int len ); + +void *yyalloc (yy_size_t ); +void *yyrealloc (void *,yy_size_t ); +void yyfree (void * ); + +#define yy_new_buffer yy_create_buffer + +#define yy_set_interactive(is_interactive) \ + { \ + if ( ! YY_CURRENT_BUFFER ){ \ + yyensure_buffer_stack (); \ + YY_CURRENT_BUFFER_LVALUE = \ + yy_create_buffer(yyin,YY_BUF_SIZE ); \ + } \ + YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \ + } + +#define yy_set_bol(at_bol) \ + { \ + if ( ! YY_CURRENT_BUFFER ){\ + yyensure_buffer_stack (); \ + YY_CURRENT_BUFFER_LVALUE = \ + yy_create_buffer(yyin,YY_BUF_SIZE ); \ + } \ + YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \ + } + +#define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol) + +/* Begin user sect3 */ + +#define yywrap(n) 1 +#define YY_SKIP_YYWRAP + +typedef unsigned char YY_CHAR; + +FILE *yyin = (FILE *) 0, *yyout = (FILE *) 0; + +typedef int yy_state_type; + +extern int yylineno; + +int yylineno = 1; + +extern char *yytext; +#define yytext_ptr yytext + +static yy_state_type yy_get_previous_state (void ); +static yy_state_type yy_try_NUL_trans (yy_state_type current_state ); +static int yy_get_next_buffer (void ); +static void yy_fatal_error (yyconst char msg[] ); + +/* Done after the current pattern has been matched and before the + * corresponding action - sets up yytext. + */ +#define YY_DO_BEFORE_ACTION \ + (yytext_ptr) = yy_bp; \ + yyleng = (size_t) (yy_cp - yy_bp); \ + (yy_hold_char) = *yy_cp; \ + *yy_cp = '\0'; \ + (yy_c_buf_p) = yy_cp; + +#define YY_NUM_RULES 142 +#define YY_END_OF_BUFFER 143 +/* This struct is not used in this scanner, + but its presence is necessary. */ +struct yy_trans_info + { + flex_int32_t yy_verify; + flex_int32_t yy_nxt; + }; +static yyconst flex_int16_t yy_accept[794] = + { 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 12, 12, 0, 0, 0, 0, + 0, 0, 11, 11, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 143, 141, 111, 89, 89, 111, 53, 111, + 72, 83, 111, 19, 87, 88, 82, 85, 81, 86, + 111, 84, 62, 62, 79, 80, 111, 94, 111, 78, + 78, 92, 93, 90, 111, 91, 70, 1, 1, 60, + 46, 60, 58, 59, 20, 59, 59, 59, 59, 62, + 59, 69, 69, 69, 69, 69, 69, 140, 140, 140, + + 140, 136, 136, 135, 134, 133, 117, 117, 12, 9, + 5, 5, 6, 6, 52, 48, 54, 49, 54, 11, + 16, 33, 33, 25, 39, 32, 27, 23, 23, 32, + 43, 43, 45, 132, 132, 130, 89, 89, 130, 130, + 50, 29, 0, 0, 103, 0, 0, 0, 0, 0, + 0, 0, 108, 99, 106, 100, 104, 101, 105, 95, + 110, 64, 2, 0, 107, 64, 62, 0, 74, 97, + 102, 96, 78, 78, 98, 1, 0, 60, 60, 0, + 0, 41, 61, 40, 1, 56, 64, 2, 64, 62, + 66, 55, 57, 68, 69, 8, 21, 18, 0, 15, + + 0, 139, 0, 0, 0, 135, 133, 0, 0, 116, + 12, 9, 9, 10, 5, 7, 4, 3, 52, 51, + 54, 11, 16, 16, 17, 33, 25, 25, 30, 26, + 35, 36, 35, 35, 35, 32, 27, 27, 28, 23, + 23, 24, 31, 43, 42, 44, 0, 0, 131, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 77, + 77, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 109, 2, 0, 73, 64, + 0, 65, 74, 78, 60, 40, 1, 1, 2, 64, + 62, 67, 68, 0, 0, 0, 47, 22, 138, 137, + + 9, 14, 10, 9, 3, 16, 13, 17, 16, 25, + 38, 26, 25, 36, 0, 0, 37, 27, 28, 27, + 23, 24, 23, 44, 0, 0, 0, 0, 0, 0, + 0, 0, 77, 77, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 78, 0, 64, 62, 68, 0, 0, 0, 68, 138, + 138, 137, 137, 9, 9, 9, 9, 16, 16, 16, + 16, 25, 25, 25, 25, 36, 0, 0, 37, 27, + 27, 27, 27, 23, 23, 23, 23, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + + 0, 0, 0, 0, 0, 0, 0, 0, 125, 0, + 0, 0, 0, 0, 0, 0, 78, 0, 64, 64, + 68, 0, 0, 0, 0, 9, 9, 9, 9, 9, + 16, 16, 13, 16, 16, 25, 25, 25, 25, 25, + 0, 0, 27, 27, 27, 27, 27, 23, 23, 23, + 23, 23, 0, 0, 0, 0, 0, 0, 0, 38, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 125, 0, 127, 0, 121, 0, + 0, 115, 0, 78, 0, 0, 64, 0, 0, 0, + 0, 68, 68, 9, 16, 25, 0, 34, 27, 23, + + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 113, 0, 129, 121, 123, 0, 115, 0, 71, 63, + 0, 0, 0, 0, 0, 68, 0, 0, 0, 0, + 0, 0, 0, 75, 75, 113, 123, 119, 71, 71, + 78, 78, 78, 78, 63, 68, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 75, 75, 75, 0, 75, + 0, 119, 0, 0, 0, 78, 78, 78, 78, 78, + 78, 63, 68, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 78, 78, 78, 78, 78, 78, 78, 78, 0, + + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 78, 78, 78, 78, + 78, 78, 78, 78, 124, 0, 0, 0, 0, 0, + 0, 0, 0, 50, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 29, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 78, 124, 0, 126, 78, 78, 78, + 78, 78, 0, 120, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 38, + 0, 38, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 76, 76, 0, 0, 114, 78, + + 0, 128, 120, 78, 78, 114, 122, 0, 50, 0, + 0, 0, 0, 0, 50, 50, 0, 0, 0, 0, + 0, 0, 0, 29, 29, 0, 0, 0, 0, 0, + 29, 29, 76, 76, 76, 76, 112, 0, 112, 122, + 78, 0, 0, 0, 0, 0, 0, 0, 0, 29, + 0, 0, 38, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 118, 118, 50, 0, 0, 0, + 0, 0, 0, 0, 0, 29, 29, 0, 0, 29, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0 + + } ; + +static yyconst flex_int32_t yy_ec[256] = + { 0, + 1, 1, 1, 1, 1, 1, 1, 1, 2, 3, + 1, 2, 4, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 2, 5, 6, 7, 8, 9, 10, 11, 12, + 13, 14, 15, 16, 17, 18, 19, 20, 21, 21, + 21, 21, 21, 21, 21, 22, 22, 23, 24, 25, + 26, 27, 28, 28, 29, 30, 31, 32, 33, 34, + 35, 35, 36, 35, 35, 37, 38, 39, 40, 41, + 42, 43, 44, 45, 46, 35, 35, 47, 35, 35, + 48, 49, 50, 51, 52, 28, 29, 30, 31, 32, + + 33, 34, 35, 35, 53, 35, 35, 37, 38, 39, + 40, 41, 42, 43, 44, 45, 54, 35, 35, 55, + 35, 35, 56, 57, 58, 28, 1, 59, 59, 59, + 59, 59, 59, 59, 59, 59, 59, 59, 59, 59, + 59, 59, 59, 59, 59, 59, 59, 59, 59, 59, + 59, 59, 59, 59, 59, 59, 59, 59, 59, 59, + 59, 59, 59, 59, 59, 59, 59, 59, 59, 59, + 59, 59, 59, 59, 59, 59, 59, 59, 59, 59, + 59, 59, 59, 59, 59, 59, 59, 59, 59, 59, + 59, 59, 59, 59, 59, 59, 59, 59, 59, 59, + + 59, 59, 59, 59, 59, 59, 59, 59, 59, 59, + 59, 59, 59, 59, 59, 59, 59, 59, 59, 59, + 59, 59, 59, 59, 59, 59, 59, 59, 59, 59, + 59, 59, 59, 59, 59, 59, 59, 59, 59, 59, + 59, 59, 59, 59, 59, 59, 59, 59, 59, 59, + 59, 59, 59, 59, 59 + } ; + +static yyconst flex_int32_t yy_meta[60] = + { 0, + 1, 2, 3, 3, 4, 5, 4, 6, 7, 4, + 8, 9, 9, 10, 7, 1, 11, 12, 10, 13, + 13, 13, 14, 15, 16, 17, 18, 4, 19, 19, + 19, 19, 19, 19, 20, 20, 20, 20, 20, 20, + 20, 20, 20, 20, 20, 20, 20, 12, 21, 9, + 4, 20, 20, 20, 20, 1, 4, 1, 20 + } ; + +static yyconst flex_int16_t yy_base[882] = + { 0, + 0, 0, 0, 0, 59, 0, 113, 117, 122, 125, + 149, 0, 208, 0, 1750, 1745, 263, 316, 1749, 1745, + 263, 268, 1730, 1728, 273, 283, 1727, 1723, 1717, 1716, + 260, 264, 127, 128, 373, 0, 294, 303, 1707, 1704, + 1697, 1696, 1697, 4982, 4982, 297, 343, 1669, 4982, 86, + 316, 1667, 1680, 4982, 4982, 4982, 1655, 106, 4982, 266, + 337, 289, 415, 420, 4982, 4982, 1646, 1644, 1638, 0, + 232, 4982, 4982, 4982, 1603, 4982, 4982, 361, 442, 0, + 4982, 466, 435, 0, 4982, 4982, 1642, 443, 1641, 466, + 122, 0, 1643, 1641, 1639, 1639, 1636, 1622, 0, 4982, + + 0, 4982, 336, 4982, 4982, 0, 4982, 448, 0, 465, + 0, 0, 305, 1627, 0, 1633, 4982, 4982, 279, 0, + 493, 0, 0, 501, 480, 0, 504, 525, 528, 1627, + 0, 0, 1628, 4982, 535, 4982, 4982, 4982, 301, 263, + 544, 549, 560, 319, 4982, 603, 420, 440, 1601, 472, + 322, 1594, 4982, 4982, 4982, 4982, 4982, 4982, 4982, 1617, + 4982, 535, 0, 1625, 4982, 549, 554, 563, 0, 4982, + 4982, 4982, 0, 1593, 4982, 589, 424, 0, 658, 109, + 482, 4982, 579, 1617, 711, 4982, 649, 0, 658, 672, + 680, 4982, 4982, 496, 0, 4982, 4982, 4982, 360, 4982, + + 1598, 4982, 1614, 1590, 708, 4982, 0, 720, 731, 4982, + 0, 739, 743, 1595, 0, 420, 4982, 0, 0, 4982, + 4982, 0, 746, 755, 1590, 0, 767, 771, 4982, 1580, + 4982, 113, 0, 0, 0, 0, 774, 783, 1579, 793, + 800, 1574, 4982, 0, 4982, 1572, 777, 803, 4982, 1541, + 1531, 811, 1542, 1515, 816, 820, 1526, 1505, 846, 4982, + 0, 0, 685, 501, 1486, 1491, 526, 1470, 1470, 1463, + 660, 1463, 547, 1463, 1453, 4982, 0, 1476, 4982, 686, + 731, 814, 0, 1447, 897, 1461, 0, 950, 0, 820, + 825, 828, 681, 1440, 0, 892, 4982, 4982, 915, 925, + + 852, 4982, 1449, 928, 0, 933, 4982, 1446, 949, 968, + 4982, 1445, 978, 469, 0, 0, 0, 985, 1433, 988, + 995, 1431, 1006, 1419, 1391, 1011, 1371, 1014, 1392, 1017, + 1361, 0, 0, 0, 1357, 1357, 1338, 1339, 1339, 1337, + 1321, 1314, 488, 1304, 1301, 541, 1296, 1296, 1288, 1291, + 869, 839, 1015, 1020, 781, 1041, 1047, 1052, 1070, 959, + 4982, 1074, 4982, 1078, 1082, 1090, 1102, 1106, 1109, 1112, + 1128, 1131, 1134, 1137, 1153, 4982, 0, 0, 4982, 1156, + 1159, 1162, 1178, 1181, 1184, 1187, 1203, 1206, 1209, 1212, + 1215, 1219, 1290, 1231, 1236, 1242, 1272, 1276, 1289, 1283, + + 1280, 1261, 527, 1261, 1261, 1249, 543, 1252, 1268, 1295, + 1253, 1252, 1251, 620, 1249, 1298, 1239, 1285, 1290, 1294, + 791, 1342, 1333, 1399, 1337, 1360, 1371, 1393, 1453, 1377, + 1457, 1469, 1473, 1485, 1489, 1496, 1501, 1506, 1517, 1512, + 0, 0, 1522, 1533, 1538, 1543, 1549, 1554, 1559, 1570, + 1575, 1565, 1421, 1226, 1581, 1586, 1238, 1591, 1602, 1607, + 1612, 1640, 1660, 1665, 1235, 0, 1228, 1215, 1222, 0, + 1217, 1204, 1215, 1208, 1329, 1382, 4982, 1597, 1353, 1203, + 1199, 1479, 1188, 1191, 1510, 1654, 1658, 1719, 0, 0, + 1210, 850, 1776, 1681, 1685, 1701, 0, 4982, 1729, 1746, + + 1188, 1750, 1183, 1795, 1798, 1814, 1162, 1169, 0, 1167, + 1697, 1713, 4982, 1756, 1762, 1166, 1769, 1160, 1867, 1762, + 1178, 1177, 700, 1893, 0, 1951, 0, 1825, 1818, 1160, + 1863, 1954, 1145, 1830, 1834, 1851, 1873, 1881, 2007, 0, + 1144, 728, 515, 1133, 1867, 2061, 0, 1908, 753, 1137, + 1971, 1978, 2002, 2119, 2012, 1888, 1893, 1902, 1086, 1912, + 1085, 1947, 1070, 642, 1062, 1066, 890, 1051, 793, 1048, + 1043, 4982, 0, 0, 950, 1038, 812, 2122, 2024, 0, + 1049, 2126, 2129, 2034, 0, 1045, 1026, 1014, 1005, 998, + 979, 678, 970, 967, 867, 960, 952, 921, 914, 881, + + 877, 885, 875, 832, 2146, 841, 2167, 2184, 2187, 819, + 2203, 850, 886, 920, 789, 788, 777, 1982, 1994, 778, + 759, 731, 976, 727, 1988, 2018, 706, 669, 631, 2207, + 2223, 2233, 2243, 4982, 2253, 2263, 2279, 2282, 2298, 2301, + 2317, 2320, 2323, 4982, 2339, 2356, 2376, 2379, 557, 543, + 504, 978, 491, 489, 2030, 2150, 4982, 2219, 2055, 464, + 434, 2138, 2382, 2269, 413, 336, 2396, 2399, 2415, 2418, + 2435, 2445, 2456, 2473, 2476, 2492, 2502, 2512, 2522, 2532, + 2542, 0, 312, 2552, 2568, 2578, 2588, 2598, 2608, 2624, + 2634, 2644, 2654, 2664, 2304, 2421, 283, 263, 2498, 2508, + + 2518, 4982, 2528, 2548, 248, 2558, 2571, 2674, 2670, 2686, + 2690, 2702, 2706, 2747, 2751, 0, 2767, 2770, 2786, 2803, + 2806, 2824, 2827, 2844, 4982, 2851, 2863, 2882, 2885, 2904, + 2908, 0, 2614, 2680, 2696, 2723, 2727, 87, 2731, 2735, + 2739, 2930, 2940, 2950, 2960, 2970, 2986, 2996, 3018, 3006, + 3034, 3044, 3054, 3064, 3074, 3092, 3102, 3112, 3122, 3132, + 3148, 3158, 3168, 3179, 2743, 2763, 3196, 3207, 3217, 3228, + 3245, 3255, 3273, 3276, 3293, 3309, 0, 3312, 3331, 3342, + 3367, 3370, 3389, 3400, 3416, 3434, 3438, 3457, 3461, 3483, + 3493, 3510, 4982, 3564, 3585, 3606, 3627, 3648, 3669, 3690, + + 3711, 3732, 3753, 3774, 3795, 3816, 3832, 3849, 3862, 3869, + 3884, 3904, 3925, 3946, 3962, 3981, 4001, 4022, 4043, 4064, + 4085, 4105, 4126, 4147, 1237, 4167, 4184, 4202, 770, 4218, + 4238, 4256, 4269, 4286, 927, 955, 1033, 4299, 1007, 4318, + 4338, 4359, 4380, 1048, 1077, 1108, 4401, 4422, 4443, 4464, + 4480, 4500, 4521, 4542, 1109, 1130, 4563, 4584, 4605, 4626, + 1131, 1133, 4646, 1134, 1155, 1156, 4666, 4687, 4708, 4729, + 4750, 4771, 4792, 4813, 4834, 4855, 4876, 4897, 4918, 4939, + 4960 + } ; + +static yyconst flex_int16_t yy_def[882] = + { 0, + 794, 794, 793, 3, 793, 5, 795, 795, 796, 796, + 793, 11, 793, 13, 797, 797, 798, 798, 799, 799, + 800, 800, 801, 801, 802, 802, 803, 803, 803, 803, + 803, 803, 804, 804, 793, 35, 805, 805, 799, 799, + 803, 803, 793, 793, 793, 793, 793, 793, 793, 806, + 793, 793, 793, 793, 793, 793, 793, 793, 793, 793, + 793, 793, 793, 793, 793, 793, 793, 793, 793, 807, + 807, 793, 793, 793, 793, 793, 793, 793, 793, 808, + 793, 806, 809, 808, 793, 793, 808, 793, 808, 793, + 810, 811, 811, 811, 811, 811, 811, 812, 813, 793, + + 814, 793, 793, 793, 793, 815, 793, 816, 817, 793, + 818, 818, 793, 793, 819, 793, 793, 793, 793, 820, + 793, 821, 821, 793, 822, 823, 793, 793, 793, 823, + 824, 824, 825, 793, 826, 793, 793, 793, 793, 793, + 793, 793, 793, 806, 793, 793, 146, 793, 793, 793, + 793, 793, 793, 793, 793, 793, 793, 793, 793, 793, + 793, 793, 827, 828, 793, 793, 793, 793, 829, 793, + 793, 793, 807, 807, 793, 793, 806, 808, 146, 146, + 793, 793, 793, 830, 831, 793, 793, 832, 793, 793, + 793, 793, 793, 833, 811, 793, 793, 793, 793, 793, + + 812, 793, 813, 814, 793, 793, 815, 793, 816, 793, + 817, 793, 793, 793, 818, 793, 793, 834, 819, 793, + 793, 820, 793, 793, 793, 821, 793, 793, 793, 793, + 793, 793, 835, 836, 837, 823, 793, 793, 793, 793, + 793, 793, 793, 824, 793, 838, 793, 826, 793, 793, + 793, 793, 793, 793, 793, 793, 793, 793, 146, 793, + 259, 146, 259, 146, 146, 146, 259, 793, 793, 793, + 793, 793, 793, 793, 793, 793, 827, 828, 793, 793, + 793, 793, 829, 807, 259, 830, 831, 831, 832, 793, + 793, 793, 833, 793, 839, 840, 793, 793, 793, 793, + + 793, 793, 793, 841, 834, 793, 793, 793, 842, 793, + 793, 793, 843, 793, 844, 845, 846, 793, 793, 847, + 793, 793, 848, 838, 793, 849, 793, 793, 793, 850, + 793, 259, 259, 259, 146, 146, 146, 146, 259, 259, + 793, 793, 793, 793, 793, 793, 793, 793, 793, 793, + 807, 793, 793, 793, 851, 840, 840, 840, 840, 793, + 793, 793, 793, 852, 841, 841, 841, 853, 842, 842, + 842, 854, 843, 843, 843, 793, 855, 856, 793, 857, + 847, 847, 847, 858, 848, 848, 848, 793, 849, 849, + 849, 849, 793, 859, 850, 850, 850, 850, 793, 146, + + 146, 146, 146, 259, 259, 793, 793, 793, 793, 793, + 793, 793, 793, 793, 793, 793, 807, 793, 793, 793, + 851, 860, 840, 793, 840, 852, 852, 852, 852, 841, + 853, 853, 853, 853, 842, 854, 854, 854, 854, 843, + 861, 862, 857, 857, 857, 857, 847, 858, 858, 858, + 858, 848, 793, 793, 849, 849, 793, 859, 859, 859, + 859, 859, 850, 850, 793, 146, 146, 146, 146, 259, + 259, 793, 793, 793, 793, 793, 793, 793, 793, 793, + 793, 793, 793, 807, 793, 793, 793, 860, 488, 488, + 488, 488, 863, 852, 853, 854, 864, 793, 857, 858, + + 793, 849, 793, 859, 859, 850, 793, 146, 259, 793, + 793, 793, 793, 793, 793, 793, 793, 793, 807, 793, + 793, 488, 488, 488, 488, 863, 865, 793, 849, 793, + 859, 850, 793, 146, 793, 793, 793, 793, 793, 539, + 807, 807, 807, 807, 793, 793, 866, 793, 793, 793, + 849, 793, 859, 850, 793, 259, 793, 259, 259, 793, + 793, 793, 793, 793, 793, 807, 807, 807, 807, 807, + 807, 793, 546, 862, 793, 793, 793, 849, 793, 867, + 793, 859, 850, 793, 868, 793, 259, 793, 793, 793, + 793, 807, 807, 807, 807, 807, 807, 807, 807, 793, + + 793, 793, 793, 793, 849, 793, 869, 859, 850, 793, + 870, 259, 793, 793, 793, 793, 807, 807, 807, 807, + 807, 807, 807, 807, 793, 793, 793, 793, 793, 849, + 793, 871, 849, 793, 869, 869, 872, 869, 859, 850, + 793, 873, 850, 793, 870, 870, 874, 870, 259, 793, + 793, 793, 793, 807, 793, 793, 793, 807, 807, 807, + 807, 807, 793, 793, 793, 793, 849, 849, 793, 849, + 849, 875, 869, 869, 793, 869, 869, 859, 793, 876, + 859, 868, 793, 850, 850, 793, 850, 850, 877, 870, + 870, 793, 870, 870, 259, 793, 793, 793, 793, 807, + + 793, 793, 793, 807, 807, 793, 793, 875, 849, 875, + 875, 878, 875, 875, 872, 867, 859, 859, 793, 859, + 859, 879, 879, 850, 793, 877, 877, 880, 877, 877, + 874, 868, 259, 793, 259, 793, 793, 793, 793, 793, + 807, 875, 875, 875, 793, 875, 875, 875, 875, 859, + 879, 879, 881, 879, 879, 879, 877, 877, 877, 793, + 877, 877, 877, 877, 793, 793, 878, 875, 879, 879, + 793, 879, 879, 879, 879, 880, 868, 877, 875, 881, + 879, 877, 875, 879, 877, 875, 879, 877, 875, 879, + 877, 879, 0, 793, 793, 793, 793, 793, 793, 793, + + 793, 793, 793, 793, 793, 793, 793, 793, 793, 793, + 793, 793, 793, 793, 793, 793, 793, 793, 793, 793, + 793, 793, 793, 793, 793, 793, 793, 793, 793, 793, + 793, 793, 793, 793, 793, 793, 793, 793, 793, 793, + 793, 793, 793, 793, 793, 793, 793, 793, 793, 793, + 793, 793, 793, 793, 793, 793, 793, 793, 793, 793, + 793, 793, 793, 793, 793, 793, 793, 793, 793, 793, + 793, 793, 793, 793, 793, 793, 793, 793, 793, 793, + 793 + } ; + +static yyconst flex_int16_t yy_nxt[5042] = + { 0, + 45, 46, 47, 46, 48, 49, 50, 51, 52, 53, + 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, + 64, 64, 65, 66, 67, 68, 69, 45, 70, 70, + 70, 70, 71, 70, 70, 70, 70, 70, 70, 70, + 70, 70, 70, 70, 70, 70, 70, 72, 45, 73, + 45, 70, 70, 70, 70, 74, 75, 76, 70, 77, + 78, 79, 78, 80, 81, 82, 83, 84, 80, 85, + 86, 86, 84, 84, 86, 87, 88, 89, 90, 90, + 90, 91, 86, 84, 84, 84, 80, 92, 93, 92, + 92, 94, 92, 92, 92, 92, 92, 95, 92, 92, + + 92, 92, 92, 92, 96, 97, 86, 77, 86, 84, + 92, 92, 96, 97, 77, 80, 77, 92, 99, 765, + 156, 147, 99, 103, 103, 103, 103, 103, 103, 132, + 132, 157, 314, 314, 133, 133, 100, 101, 148, 100, + 100, 101, 264, 100, 192, 104, 265, 193, 104, 105, + 105, 105, 105, 105, 105, 105, 105, 105, 105, 105, + 105, 105, 105, 105, 105, 105, 105, 105, 105, 105, + 105, 105, 105, 105, 105, 105, 105, 106, 106, 106, + 106, 106, 106, 106, 106, 106, 106, 106, 106, 106, + 106, 106, 106, 106, 106, 106, 105, 105, 105, 105, + + 106, 106, 106, 106, 105, 105, 105, 106, 107, 107, + 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, + 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, + 107, 107, 107, 107, 107, 107, 108, 108, 108, 108, + 108, 108, 108, 108, 108, 108, 108, 108, 108, 108, + 108, 108, 108, 108, 108, 107, 107, 107, 107, 108, + 108, 108, 108, 107, 107, 107, 108, 112, 118, 112, + 129, 112, 112, 118, 129, 123, 113, 112, 174, 112, + 741, 114, 158, 124, 221, 123, 174, 112, 112, 112, + 112, 159, 160, 124, 738, 137, 138, 137, 143, 143, + + 143, 139, 163, 144, 137, 138, 137, 164, 130, 251, + 139, 119, 130, 112, 165, 737, 119, 251, 216, 112, + 112, 125, 112, 217, 112, 112, 140, 221, 723, 113, + 112, 125, 112, 150, 114, 140, 250, 205, 205, 205, + 112, 112, 112, 112, 143, 143, 143, 149, 150, 144, + 161, 151, 708, 250, 147, 273, 162, 162, 162, 206, + 274, 152, 176, 176, 176, 297, 112, 177, 151, 152, + 298, 148, 112, 134, 134, 134, 134, 134, 134, 134, + 134, 134, 134, 134, 134, 134, 134, 134, 134, 134, + 134, 134, 134, 134, 134, 134, 134, 134, 134, 134, + + 134, 135, 135, 135, 135, 135, 135, 135, 135, 135, + 135, 135, 135, 135, 135, 135, 135, 135, 135, 135, + 134, 134, 134, 134, 135, 135, 135, 135, 134, 134, + 134, 135, 166, 216, 167, 167, 167, 166, 217, 167, + 167, 167, 182, 176, 176, 176, 707, 168, 177, 208, + 208, 208, 168, 264, 183, 183, 183, 265, 266, 180, + 186, 169, 187, 187, 187, 705, 212, 213, 213, 169, + 179, 210, 179, 267, 179, 179, 181, 268, 269, 179, + 179, 214, 179, 189, 179, 190, 190, 190, 376, 376, + 179, 179, 179, 179, 223, 224, 224, 704, 191, 232, + + 232, 180, 227, 228, 228, 237, 238, 238, 271, 225, + 272, 229, 294, 295, 229, 267, 179, 230, 181, 268, + 239, 700, 179, 408, 699, 233, 240, 241, 241, 240, + 241, 241, 335, 234, 235, 229, 247, 247, 247, 336, + 408, 242, 697, 296, 242, 252, 252, 252, 569, 220, + 255, 256, 256, 570, 162, 162, 162, 339, 249, 229, + 253, 143, 143, 143, 340, 257, 144, 168, 280, 280, + 280, 166, 469, 167, 167, 167, 411, 281, 347, 281, + 469, 168, 282, 282, 282, 348, 168, 696, 473, 254, + 176, 176, 176, 411, 258, 177, 473, 254, 183, 183, + + 183, 695, 258, 259, 259, 260, 261, 259, 259, 259, + 259, 259, 259, 259, 259, 259, 259, 259, 259, 259, + 259, 259, 259, 259, 259, 259, 259, 259, 259, 259, + 259, 262, 262, 262, 262, 262, 262, 262, 262, 262, + 262, 262, 262, 262, 262, 262, 262, 262, 262, 262, + 259, 263, 259, 259, 259, 262, 262, 262, 259, 259, + 259, 259, 285, 665, 285, 481, 285, 285, 187, 187, + 187, 285, 285, 481, 285, 577, 285, 290, 290, 290, + 590, 191, 285, 285, 285, 285, 332, 333, 334, 189, + 191, 291, 291, 291, 292, 344, 292, 294, 295, 282, + + 282, 282, 664, 345, 191, 280, 280, 280, 285, 205, + 205, 205, 344, 617, 285, 288, 491, 288, 168, 288, + 288, 208, 208, 208, 288, 288, 524, 288, 296, 288, + 617, 206, 208, 208, 208, 288, 288, 288, 288, 663, + 212, 213, 213, 210, 301, 301, 301, 223, 224, 224, + 282, 282, 282, 302, 210, 214, 306, 306, 306, 303, + 662, 288, 225, 660, 567, 307, 568, 288, 227, 228, + 228, 308, 310, 310, 310, 237, 238, 238, 247, 247, + 247, 311, 283, 230, 318, 318, 318, 312, 283, 575, + 239, 576, 659, 311, 240, 241, 241, 294, 295, 319, + + 249, 321, 321, 321, 247, 247, 247, 294, 295, 242, + 311, 658, 252, 252, 252, 654, 322, 255, 256, 256, + 653, 328, 328, 328, 596, 652, 249, 253, 296, 644, + 311, 597, 257, 282, 282, 282, 329, 352, 296, 353, + 353, 353, 189, 603, 354, 354, 354, 282, 282, 282, + 604, 634, 191, 301, 301, 301, 254, 191, 418, 418, + 418, 258, 302, 629, 254, 258, 523, 524, 303, 258, + 416, 416, 416, 258, 259, 259, 259, 259, 259, 259, + 259, 259, 259, 259, 259, 259, 259, 259, 259, 259, + 259, 259, 259, 356, 356, 356, 649, 525, 259, 259, + + 259, 285, 620, 285, 649, 285, 285, 628, 358, 626, + 285, 285, 417, 285, 625, 285, 360, 360, 360, 620, + 627, 285, 285, 285, 285, 593, 362, 362, 362, 366, + 213, 213, 650, 594, 306, 306, 306, 627, 361, 315, + 650, 359, 593, 307, 367, 315, 624, 285, 363, 308, + 370, 224, 224, 285, 288, 651, 288, 623, 288, 288, + 360, 360, 360, 288, 288, 371, 288, 316, 288, 310, + 310, 310, 651, 316, 288, 288, 288, 288, 311, 374, + 228, 228, 361, 622, 312, 600, 318, 318, 318, 382, + 238, 238, 621, 601, 375, 311, 321, 321, 321, 619, + + 288, 319, 600, 618, 383, 311, 288, 386, 241, 241, + 616, 322, 390, 252, 252, 328, 328, 328, 396, 256, + 256, 661, 387, 698, 311, 355, 355, 391, 615, 661, + 329, 698, 352, 397, 419, 419, 419, 420, 614, 354, + 354, 354, 356, 356, 356, 317, 613, 191, 356, 356, + 356, 317, 191, 356, 356, 356, 392, 358, 612, 258, + 377, 611, 398, 358, 392, 607, 377, 258, 422, 602, + 398, 356, 356, 356, 599, 362, 362, 362, 598, 427, + 301, 301, 595, 366, 213, 213, 423, 424, 428, 378, + 359, 366, 213, 213, 429, 378, 359, 363, 367, 592, + + 591, 359, 589, 366, 213, 213, 367, 432, 306, 306, + 370, 224, 224, 370, 224, 224, 433, 425, 430, 359, + 379, 441, 434, 588, 587, 371, 379, 441, 371, 370, + 224, 224, 437, 310, 310, 374, 228, 228, 374, 228, + 228, 438, 442, 497, 435, 498, 527, 439, 442, 497, + 375, 498, 527, 375, 374, 228, 228, 444, 318, 318, + 382, 238, 238, 382, 238, 238, 445, 547, 574, 440, + 577, 571, 446, 547, 574, 383, 566, 555, 383, 382, + 238, 238, 449, 321, 321, 386, 241, 241, 386, 241, + 241, 450, 552, 491, 447, 485, 539, 451, 538, 535, + + 387, 534, 533, 387, 386, 241, 241, 453, 453, 453, + 390, 252, 252, 390, 252, 252, 390, 252, 252, 452, + 390, 252, 252, 530, 528, 391, 491, 519, 391, 518, + 516, 455, 459, 328, 328, 391, 515, 396, 256, 256, + 511, 460, 246, 396, 256, 256, 510, 461, 509, 454, + 470, 456, 397, 508, 392, 246, 246, 392, 397, 466, + 392, 466, 392, 507, 392, 392, 503, 501, 392, 475, + 475, 475, 392, 396, 256, 256, 462, 396, 256, 256, + 484, 398, 482, 480, 462, 479, 478, 398, 463, 398, + 474, 472, 397, 471, 470, 398, 476, 476, 476, 416, + + 416, 416, 485, 468, 486, 486, 486, 352, 464, 487, + 487, 487, 467, 487, 487, 487, 466, 398, 477, 465, + 457, 398, 191, 415, 414, 398, 191, 413, 412, 398, + 475, 475, 475, 410, 356, 356, 356, 409, 356, 356, + 356, 483, 488, 489, 356, 356, 488, 488, 488, 422, + 407, 488, 488, 358, 514, 514, 514, 488, 491, 424, + 406, 427, 301, 301, 488, 488, 488, 488, 405, 488, + 428, 404, 427, 301, 301, 403, 429, 402, 366, 213, + 213, 428, 359, 476, 476, 476, 359, 429, 401, 400, + 488, 492, 488, 430, 427, 301, 301, 488, 488, 488, + + 356, 356, 356, 428, 399, 477, 357, 357, 394, 429, + 357, 357, 357, 357, 393, 358, 357, 357, 357, 357, + 357, 388, 453, 453, 453, 357, 245, 493, 493, 493, + 493, 493, 493, 493, 493, 493, 493, 493, 493, 493, + 493, 493, 493, 493, 493, 493, 357, 384, 359, 380, + 493, 493, 493, 493, 427, 301, 301, 493, 432, 306, + 306, 372, 368, 428, 454, 364, 295, 433, 182, 494, + 432, 306, 306, 434, 432, 306, 306, 351, 279, 433, + 517, 517, 517, 433, 350, 434, 432, 306, 306, 434, + 370, 224, 224, 349, 346, 433, 343, 437, 310, 310, + + 342, 495, 437, 310, 310, 435, 438, 437, 310, 310, + 341, 438, 439, 374, 228, 228, 438, 439, 437, 310, + 310, 338, 439, 444, 318, 318, 337, 438, 440, 520, + 520, 520, 445, 496, 444, 318, 318, 331, 446, 444, + 318, 318, 330, 445, 444, 318, 318, 327, 445, 446, + 382, 238, 238, 445, 446, 449, 321, 321, 326, 499, + 449, 321, 321, 325, 450, 447, 386, 241, 241, 450, + 451, 449, 321, 321, 273, 451, 449, 321, 321, 245, + 450, 452, 390, 252, 252, 450, 451, 390, 252, 252, + 323, 500, 459, 328, 328, 320, 313, 455, 512, 512, + + 512, 460, 391, 459, 328, 328, 309, 461, 459, 328, + 328, 304, 460, 459, 328, 328, 300, 460, 461, 299, + 513, 202, 460, 461, 182, 284, 392, 279, 504, 502, + 276, 392, 275, 270, 392, 245, 462, 243, 220, 392, + 218, 459, 328, 328, 462, 202, 200, 462, 199, 198, + 460, 197, 462, 196, 188, 462, 461, 462, 185, 175, + 462, 396, 256, 256, 172, 462, 396, 256, 256, 171, + 170, 485, 505, 521, 521, 521, 463, 487, 487, 487, + 155, 397, 427, 301, 301, 462, 432, 306, 306, 154, + 191, 428, 153, 462, 145, 433, 793, 494, 536, 536, + + 536, 495, 437, 310, 310, 398, 142, 142, 506, 141, + 398, 438, 141, 398, 512, 512, 512, 496, 398, 488, + 489, 356, 356, 488, 488, 488, 128, 128, 488, 488, + 444, 318, 318, 127, 488, 522, 513, 127, 121, 445, + 121, 488, 488, 488, 488, 499, 488, 449, 321, 321, + 116, 390, 252, 252, 116, 110, 450, 514, 514, 514, + 110, 793, 500, 537, 537, 537, 391, 488, 492, 488, + 517, 517, 517, 793, 488, 488, 488, 356, 356, 356, + 529, 545, 545, 545, 357, 793, 793, 357, 357, 357, + 357, 793, 423, 424, 357, 392, 459, 328, 328, 459, + + 328, 328, 357, 392, 793, 460, 793, 793, 460, 793, + 793, 504, 793, 793, 461, 396, 256, 256, 793, 390, + 252, 252, 793, 425, 793, 359, 548, 548, 548, 793, + 397, 556, 557, 558, 391, 560, 560, 560, 793, 793, + 462, 531, 793, 462, 532, 793, 551, 793, 462, 793, + 793, 462, 536, 536, 536, 793, 793, 549, 793, 398, + 550, 793, 793, 392, 459, 328, 328, 398, 540, 540, + 540, 392, 793, 460, 537, 537, 537, 550, 793, 461, + 793, 559, 562, 562, 562, 561, 572, 572, 572, 556, + 557, 558, 793, 553, 560, 560, 560, 793, 541, 542, + + 793, 793, 543, 556, 557, 558, 793, 793, 462, 548, + 548, 548, 544, 560, 560, 560, 462, 793, 793, 543, + 544, 546, 546, 546, 546, 546, 546, 546, 546, 546, + 546, 546, 546, 546, 546, 546, 546, 546, 546, 546, + 549, 793, 793, 550, 546, 546, 546, 546, 562, 562, + 562, 546, 356, 356, 356, 396, 256, 256, 793, 357, + 550, 793, 357, 357, 357, 357, 793, 423, 424, 357, + 397, 793, 390, 252, 252, 793, 793, 357, 793, 579, + 579, 579, 554, 655, 655, 655, 793, 391, 580, 655, + 655, 655, 793, 793, 581, 656, 656, 656, 425, 398, + + 359, 793, 793, 459, 328, 328, 793, 398, 540, 540, + 540, 578, 460, 584, 584, 584, 392, 657, 461, 656, + 656, 656, 585, 793, 392, 579, 579, 579, 586, 793, + 582, 655, 655, 655, 580, 584, 584, 584, 563, 549, + 581, 657, 564, 793, 585, 793, 793, 462, 793, 793, + 586, 793, 565, 793, 793, 462, 703, 703, 703, 564, + 565, 488, 489, 356, 356, 488, 488, 488, 573, 490, + 488, 488, 490, 490, 490, 490, 488, 523, 524, 490, + 573, 573, 573, 488, 488, 488, 488, 490, 488, 573, + 573, 573, 573, 573, 573, 573, 573, 573, 573, 573, + + 573, 573, 573, 573, 573, 573, 573, 573, 525, 488, + 492, 488, 573, 573, 573, 573, 488, 488, 488, 573, + 396, 256, 256, 390, 252, 252, 793, 459, 328, 328, + 396, 256, 256, 793, 793, 397, 460, 793, 391, 706, + 706, 706, 461, 793, 793, 397, 793, 630, 631, 631, + 793, 656, 656, 656, 605, 793, 632, 793, 793, 583, + 793, 609, 633, 793, 398, 793, 608, 392, 636, 579, + 579, 462, 398, 657, 398, 392, 793, 637, 793, 462, + 793, 793, 398, 638, 793, 459, 328, 328, 640, 641, + 641, 392, 793, 793, 460, 793, 793, 642, 793, 392, + + 461, 793, 793, 643, 646, 584, 584, 793, 630, 631, + 631, 793, 793, 647, 793, 793, 639, 632, 793, 648, + 701, 701, 701, 633, 631, 631, 631, 793, 793, 462, + 793, 793, 398, 580, 668, 669, 669, 462, 793, 666, + 398, 793, 702, 389, 390, 252, 252, 793, 793, 670, + 793, 793, 392, 793, 636, 579, 579, 793, 793, 672, + 392, 793, 793, 637, 636, 579, 579, 793, 254, 638, + 703, 703, 703, 637, 793, 793, 254, 793, 671, 638, + 674, 675, 675, 636, 579, 579, 671, 793, 392, 637, + 793, 793, 637, 793, 793, 676, 392, 793, 677, 678, + + 679, 679, 640, 641, 641, 733, 734, 735, 680, 793, + 793, 642, 793, 793, 681, 793, 793, 643, 679, 679, + 679, 685, 686, 686, 396, 256, 256, 682, 793, 793, + 395, 793, 793, 683, 793, 793, 687, 793, 793, 689, + 646, 584, 584, 462, 793, 793, 398, 793, 793, 647, + 793, 462, 793, 793, 398, 648, 793, 646, 584, 584, + 793, 793, 258, 793, 793, 688, 647, 793, 398, 793, + 258, 793, 648, 688, 793, 793, 398, 691, 692, 692, + 646, 584, 584, 701, 701, 701, 647, 793, 793, 647, + 793, 793, 693, 793, 793, 694, 793, 390, 252, 252, + + 390, 252, 252, 793, 793, 702, 709, 793, 793, 709, + 793, 793, 391, 793, 793, 391, 252, 252, 252, 390, + 252, 252, 736, 736, 736, 634, 793, 793, 709, 793, + 793, 253, 793, 793, 455, 793, 390, 252, 252, 793, + 793, 392, 793, 793, 392, 709, 711, 631, 631, 392, + 793, 391, 392, 793, 793, 712, 793, 636, 579, 579, + 254, 713, 793, 392, 793, 793, 715, 456, 254, 793, + 793, 392, 638, 793, 636, 579, 579, 579, 579, 579, + 392, 793, 793, 715, 793, 793, 716, 793, 392, 638, + 714, 793, 581, 636, 579, 579, 793, 793, 714, 706, + + 706, 706, 715, 636, 579, 579, 793, 793, 677, 739, + 739, 739, 637, 678, 679, 679, 793, 793, 677, 701, + 701, 701, 680, 679, 679, 679, 793, 793, 681, 703, + 703, 703, 682, 718, 719, 719, 793, 793, 683, 793, + 793, 702, 460, 459, 328, 328, 793, 793, 720, 740, + 740, 740, 460, 396, 256, 256, 793, 462, 722, 706, + 706, 706, 724, 793, 793, 462, 793, 258, 397, 396, + 256, 256, 740, 740, 740, 258, 793, 721, 724, 328, + 328, 328, 793, 793, 397, 721, 793, 462, 725, 396, + 256, 256, 793, 793, 329, 462, 793, 398, 724, 396, + + 256, 256, 793, 793, 463, 398, 793, 793, 724, 727, + 641, 641, 793, 398, 397, 733, 734, 735, 728, 793, + 793, 398, 793, 258, 729, 646, 584, 584, 793, 793, + 464, 258, 793, 398, 731, 646, 584, 584, 793, 793, + 648, 398, 793, 398, 731, 584, 584, 584, 793, 793, + 648, 398, 793, 730, 732, 646, 584, 584, 793, 793, + 586, 730, 793, 793, 731, 646, 584, 584, 793, 793, + 694, 390, 252, 252, 647, 711, 631, 631, 793, 793, + 694, 736, 736, 736, 712, 793, 391, 711, 631, 631, + 742, 711, 631, 631, 793, 793, 712, 733, 734, 735, + + 712, 793, 742, 744, 745, 745, 742, 711, 631, 631, + 793, 793, 712, 793, 793, 392, 712, 793, 746, 714, + 793, 793, 748, 392, 736, 736, 736, 714, 739, 739, + 739, 714, 739, 739, 739, 714, 740, 740, 740, 714, + 766, 766, 766, 714, 766, 766, 766, 747, 711, 631, + 631, 714, 674, 675, 675, 747, 793, 712, 793, 714, + 793, 637, 793, 742, 766, 766, 766, 676, 459, 328, + 328, 459, 328, 328, 793, 793, 793, 750, 793, 749, + 750, 793, 793, 461, 793, 793, 461, 328, 328, 328, + 793, 793, 714, 793, 793, 793, 725, 793, 793, 793, + + 714, 793, 329, 793, 459, 328, 328, 459, 328, 328, + 793, 793, 462, 750, 793, 462, 750, 793, 793, 504, + 462, 793, 461, 462, 793, 752, 679, 679, 752, 679, + 679, 258, 793, 793, 753, 793, 793, 753, 505, 258, + 754, 793, 793, 756, 793, 396, 256, 256, 462, 793, + 793, 462, 727, 641, 641, 793, 462, 793, 793, 462, + 397, 728, 793, 793, 727, 641, 641, 757, 793, 755, + 793, 793, 755, 728, 793, 793, 793, 755, 793, 757, + 755, 793, 793, 759, 760, 760, 727, 641, 641, 398, + 793, 793, 728, 793, 793, 728, 730, 398, 761, 793, + + 793, 763, 793, 793, 730, 727, 641, 641, 730, 691, + 692, 692, 793, 793, 728, 793, 730, 793, 647, 793, + 757, 793, 793, 793, 693, 793, 793, 762, 793, 793, + 730, 711, 631, 631, 793, 762, 764, 793, 730, 793, + 712, 711, 631, 631, 793, 793, 748, 793, 793, 730, + 767, 711, 631, 631, 793, 793, 742, 730, 793, 793, + 767, 631, 631, 631, 793, 793, 742, 793, 793, 793, + 716, 711, 631, 631, 793, 714, 666, 793, 793, 793, + 767, 793, 793, 714, 793, 714, 748, 711, 631, 631, + 793, 793, 793, 714, 793, 714, 767, 711, 631, 631, + + 793, 793, 742, 714, 793, 254, 712, 459, 328, 328, + 793, 793, 748, 254, 793, 714, 460, 793, 749, 711, + 631, 631, 461, 714, 793, 793, 793, 793, 712, 793, + 793, 714, 793, 793, 742, 752, 679, 679, 793, 714, + 793, 714, 793, 793, 753, 752, 679, 679, 793, 714, + 756, 462, 793, 793, 753, 770, 771, 771, 793, 462, + 756, 768, 793, 714, 753, 752, 679, 679, 793, 793, + 772, 714, 793, 793, 753, 752, 679, 679, 793, 755, + 774, 793, 793, 793, 753, 793, 793, 755, 793, 755, + 756, 793, 793, 752, 679, 679, 793, 755, 793, 773, + + 793, 793, 753, 727, 641, 641, 775, 773, 774, 755, + 793, 793, 728, 727, 641, 641, 793, 755, 763, 755, + 793, 793, 776, 727, 641, 641, 793, 755, 757, 793, + 793, 793, 776, 679, 679, 679, 793, 755, 757, 793, + 793, 793, 777, 793, 793, 755, 793, 730, 683, 727, + 641, 641, 793, 793, 793, 730, 793, 730, 776, 727, + 641, 641, 793, 793, 763, 730, 793, 730, 776, 727, + 641, 641, 793, 793, 757, 730, 793, 258, 728, 793, + 727, 641, 641, 793, 763, 258, 793, 793, 793, 728, + 764, 793, 793, 730, 793, 757, 793, 744, 745, 745, + + 793, 730, 793, 730, 793, 793, 712, 793, 711, 631, + 631, 730, 746, 730, 793, 793, 793, 712, 752, 679, + 679, 730, 778, 742, 730, 793, 793, 780, 793, 752, + 679, 679, 730, 756, 793, 793, 793, 779, 780, 793, + 793, 747, 793, 793, 756, 793, 679, 679, 679, 747, + 793, 793, 714, 793, 793, 777, 752, 679, 679, 793, + 714, 683, 755, 793, 793, 780, 793, 793, 793, 793, + 755, 774, 793, 755, 752, 679, 679, 752, 679, 679, + 793, 755, 793, 780, 793, 793, 753, 793, 793, 756, + 258, 793, 774, 793, 752, 679, 679, 793, 258, 793, + + 755, 793, 793, 753, 793, 775, 793, 793, 755, 756, + 759, 760, 760, 727, 641, 641, 793, 793, 755, 728, + 793, 755, 728, 793, 793, 761, 755, 793, 757, 755, + 793, 793, 711, 631, 631, 793, 781, 793, 755, 793, + 793, 712, 782, 770, 771, 771, 755, 742, 793, 793, + 793, 793, 753, 793, 762, 793, 793, 730, 772, 783, + 793, 793, 762, 793, 793, 730, 793, 793, 752, 679, + 679, 727, 641, 641, 793, 793, 714, 753, 793, 793, + 728, 793, 793, 756, 714, 793, 757, 773, 793, 793, + 711, 631, 631, 793, 793, 773, 793, 784, 785, 712, + + 793, 752, 679, 679, 793, 742, 793, 793, 793, 793, + 753, 793, 755, 793, 793, 730, 756, 727, 641, 641, + 755, 793, 793, 730, 793, 793, 728, 793, 787, 786, + 793, 793, 757, 793, 714, 711, 631, 631, 793, 752, + 679, 679, 714, 793, 712, 755, 793, 793, 753, 793, + 742, 793, 793, 755, 756, 793, 788, 793, 727, 641, + 641, 730, 711, 631, 631, 793, 789, 728, 793, 730, + 793, 712, 793, 757, 793, 793, 793, 742, 790, 714, + 793, 793, 793, 755, 752, 679, 679, 714, 793, 791, + 793, 755, 793, 753, 727, 641, 641, 793, 793, 756, + + 793, 793, 730, 728, 793, 793, 714, 793, 793, 757, + 730, 752, 679, 679, 714, 792, 793, 793, 793, 793, + 753, 793, 793, 793, 793, 793, 756, 793, 755, 793, + 793, 793, 793, 793, 793, 793, 755, 793, 730, 793, + 793, 793, 793, 793, 793, 793, 730, 793, 793, 793, + 793, 793, 793, 793, 793, 755, 793, 793, 793, 793, + 793, 793, 793, 755, 44, 44, 44, 44, 44, 44, + 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, + 44, 44, 44, 44, 44, 98, 98, 98, 98, 98, + 98, 98, 98, 98, 98, 98, 98, 98, 98, 98, + + 98, 98, 98, 98, 98, 98, 102, 102, 102, 102, + 102, 102, 102, 102, 102, 102, 102, 102, 102, 102, + 102, 102, 102, 102, 102, 102, 102, 109, 109, 109, + 109, 109, 109, 109, 109, 109, 109, 109, 109, 109, + 109, 109, 109, 109, 109, 109, 109, 109, 111, 111, + 111, 111, 111, 111, 111, 111, 111, 111, 111, 111, + 111, 111, 111, 111, 111, 111, 111, 111, 111, 115, + 115, 115, 115, 115, 115, 115, 115, 115, 115, 115, + 115, 115, 115, 115, 115, 115, 115, 115, 115, 115, + 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, + + 117, 117, 117, 117, 117, 117, 117, 117, 117, 117, + 117, 120, 120, 120, 120, 120, 120, 120, 120, 120, + 120, 120, 120, 120, 120, 120, 120, 120, 120, 120, + 120, 120, 122, 122, 122, 122, 122, 122, 122, 122, + 122, 122, 122, 122, 122, 122, 122, 122, 122, 122, + 122, 122, 122, 126, 126, 126, 126, 126, 126, 126, + 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, + 126, 126, 126, 126, 131, 131, 131, 131, 131, 131, + 131, 131, 131, 131, 131, 131, 131, 131, 131, 131, + 131, 131, 131, 131, 131, 136, 136, 136, 136, 136, + + 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, + 136, 136, 136, 136, 136, 136, 146, 146, 146, 146, + 146, 146, 146, 146, 146, 146, 146, 146, 146, 146, + 146, 146, 146, 146, 146, 146, 146, 173, 793, 793, + 793, 793, 793, 793, 173, 793, 793, 793, 793, 793, + 173, 173, 178, 793, 793, 178, 793, 793, 178, 178, + 793, 793, 793, 793, 178, 178, 178, 184, 793, 793, + 793, 793, 793, 793, 184, 793, 793, 793, 793, 793, + 184, 184, 194, 793, 793, 194, 793, 194, 194, 195, + 793, 793, 793, 793, 793, 793, 195, 793, 793, 793, + + 793, 793, 195, 195, 201, 201, 201, 201, 793, 201, + 201, 201, 201, 201, 201, 201, 201, 201, 201, 793, + 201, 793, 201, 201, 201, 203, 203, 203, 203, 793, + 203, 203, 203, 203, 203, 203, 203, 203, 203, 203, + 203, 203, 203, 203, 203, 203, 204, 204, 204, 204, + 204, 204, 204, 204, 204, 204, 204, 204, 204, 204, + 204, 204, 204, 793, 204, 204, 204, 207, 793, 793, + 793, 793, 793, 793, 207, 793, 793, 793, 793, 793, + 207, 207, 209, 209, 793, 793, 209, 793, 793, 793, + 793, 793, 793, 209, 793, 209, 793, 793, 793, 209, + + 209, 211, 211, 211, 211, 211, 211, 211, 793, 211, + 211, 211, 211, 211, 211, 211, 211, 211, 211, 211, + 211, 211, 215, 215, 215, 215, 215, 215, 215, 215, + 215, 793, 215, 215, 215, 215, 215, 215, 215, 215, + 215, 215, 215, 219, 219, 219, 219, 793, 219, 219, + 219, 219, 219, 219, 219, 219, 219, 219, 219, 219, + 219, 219, 219, 219, 222, 222, 222, 222, 222, 222, + 222, 793, 222, 222, 222, 222, 222, 222, 222, 222, + 222, 222, 222, 222, 222, 226, 226, 226, 226, 226, + 226, 226, 793, 226, 226, 226, 226, 226, 226, 226, + + 226, 226, 226, 226, 226, 231, 231, 231, 231, 231, + 231, 231, 231, 231, 231, 231, 231, 231, 231, 231, + 231, 231, 231, 231, 231, 231, 236, 236, 236, 236, + 236, 236, 236, 793, 236, 236, 236, 236, 236, 236, + 236, 236, 236, 236, 236, 236, 236, 244, 244, 244, + 244, 244, 793, 244, 244, 244, 244, 244, 244, 244, + 244, 244, 244, 244, 244, 244, 244, 244, 248, 248, + 793, 793, 248, 793, 793, 793, 793, 793, 793, 248, + 793, 248, 793, 793, 793, 248, 248, 277, 793, 793, + 277, 793, 793, 277, 277, 793, 793, 793, 793, 277, + + 277, 277, 278, 278, 278, 278, 278, 278, 278, 278, + 278, 278, 278, 278, 278, 278, 278, 278, 278, 278, + 278, 278, 278, 286, 793, 793, 793, 793, 793, 793, + 286, 793, 793, 793, 793, 793, 286, 286, 287, 287, + 793, 287, 287, 287, 287, 287, 287, 287, 287, 287, + 287, 287, 287, 287, 287, 287, 287, 287, 287, 289, + 793, 793, 289, 793, 793, 289, 289, 793, 793, 793, + 793, 289, 289, 289, 293, 793, 793, 793, 793, 293, + 293, 293, 793, 793, 793, 793, 793, 293, 293, 305, + 793, 793, 305, 793, 793, 305, 305, 793, 793, 793, + + 793, 305, 305, 305, 324, 793, 793, 793, 793, 793, + 793, 324, 793, 793, 793, 793, 793, 324, 324, 357, + 357, 793, 793, 357, 357, 793, 357, 357, 357, 357, + 357, 793, 793, 793, 793, 357, 357, 357, 365, 365, + 365, 365, 365, 365, 365, 365, 365, 365, 365, 365, + 365, 365, 365, 365, 365, 365, 365, 365, 365, 369, + 369, 369, 369, 369, 369, 369, 369, 369, 369, 369, + 369, 369, 369, 369, 369, 369, 369, 369, 369, 369, + 373, 373, 373, 373, 373, 373, 373, 373, 373, 373, + 373, 373, 373, 373, 373, 373, 373, 373, 373, 373, + + 373, 381, 381, 381, 381, 381, 381, 381, 381, 381, + 381, 381, 381, 381, 381, 381, 381, 381, 381, 381, + 381, 381, 385, 385, 385, 385, 385, 385, 385, 385, + 385, 385, 385, 385, 385, 385, 385, 385, 385, 385, + 385, 385, 385, 389, 389, 389, 389, 389, 389, 389, + 389, 389, 389, 389, 389, 389, 389, 389, 389, 389, + 389, 389, 389, 389, 395, 395, 395, 395, 395, 395, + 395, 395, 395, 395, 395, 395, 395, 395, 395, 395, + 395, 395, 395, 395, 395, 421, 793, 793, 793, 793, + 421, 421, 421, 793, 793, 793, 793, 793, 421, 421, + + 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, + 426, 426, 426, 426, 426, 426, 426, 426, 426, 426, + 426, 431, 431, 431, 431, 431, 431, 431, 431, 431, + 431, 431, 431, 431, 431, 431, 431, 431, 431, 431, + 431, 431, 436, 436, 436, 436, 436, 436, 436, 436, + 436, 436, 436, 436, 436, 436, 436, 436, 436, 436, + 436, 436, 436, 443, 443, 443, 443, 443, 443, 443, + 443, 443, 443, 443, 443, 443, 443, 443, 443, 443, + 443, 443, 443, 443, 448, 448, 448, 448, 448, 448, + 448, 448, 448, 448, 448, 448, 448, 448, 448, 448, + + 448, 448, 448, 448, 448, 458, 458, 458, 458, 458, + 458, 458, 458, 458, 458, 458, 458, 458, 458, 458, + 458, 458, 458, 458, 458, 458, 490, 490, 490, 490, + 490, 490, 490, 490, 490, 490, 490, 490, 490, 490, + 490, 490, 490, 490, 490, 490, 490, 526, 526, 793, + 793, 526, 526, 793, 526, 526, 526, 526, 526, 793, + 793, 793, 793, 526, 526, 526, 606, 606, 606, 606, + 606, 606, 606, 793, 606, 606, 606, 606, 606, 606, + 606, 606, 606, 606, 606, 606, 606, 610, 610, 610, + 610, 610, 610, 610, 793, 610, 610, 610, 610, 610, + + 610, 610, 610, 610, 610, 610, 610, 610, 635, 635, + 635, 635, 635, 635, 635, 635, 635, 635, 635, 635, + 635, 635, 635, 635, 635, 635, 635, 635, 635, 645, + 645, 645, 645, 645, 645, 645, 645, 645, 645, 645, + 645, 645, 645, 645, 645, 645, 645, 645, 645, 645, + 667, 667, 667, 667, 667, 667, 667, 667, 667, 667, + 667, 667, 667, 667, 667, 667, 667, 667, 667, 667, + 667, 673, 673, 673, 673, 673, 673, 673, 673, 673, + 673, 673, 673, 673, 673, 673, 673, 673, 673, 673, + 673, 673, 684, 684, 684, 684, 684, 684, 684, 684, + + 684, 684, 684, 684, 684, 684, 684, 684, 684, 684, + 684, 684, 684, 690, 690, 690, 690, 690, 690, 690, + 690, 690, 690, 690, 690, 690, 690, 690, 690, 690, + 690, 690, 690, 690, 710, 710, 710, 710, 710, 710, + 710, 710, 710, 710, 710, 710, 710, 710, 710, 710, + 710, 710, 710, 710, 710, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 717, 717, 717, 717, + 717, 717, 717, 717, 717, 717, 726, 726, 726, 726, + 726, 726, 726, 726, 726, 726, 726, 726, 726, 726, + 726, 726, 726, 726, 726, 726, 726, 743, 743, 743, + + 743, 743, 743, 743, 743, 743, 743, 743, 743, 743, + 743, 743, 743, 743, 743, 743, 743, 743, 751, 751, + 751, 751, 751, 751, 751, 751, 751, 751, 751, 751, + 751, 751, 751, 751, 751, 751, 751, 751, 751, 758, + 758, 758, 758, 758, 758, 758, 758, 758, 758, 758, + 758, 758, 758, 758, 758, 758, 758, 758, 758, 758, + 769, 769, 769, 769, 769, 769, 769, 769, 769, 769, + 769, 769, 769, 769, 769, 769, 769, 769, 769, 769, + 769, 43, 793, 793, 793, 793, 793, 793, 793, 793, + 793, 793, 793, 793, 793, 793, 793, 793, 793, 793, + + 793, 793, 793, 793, 793, 793, 793, 793, 793, 793, + 793, 793, 793, 793, 793, 793, 793, 793, 793, 793, + 793, 793, 793, 793, 793, 793, 793, 793, 793, 793, + 793, 793, 793, 793, 793, 793, 793, 793, 793, 793, + 793 + } ; + +static yyconst flex_int16_t yy_chk[5042] = + { 0, + 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, + 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, + 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, + 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, + 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, + 3, 3, 3, 3, 3, 3, 3, 3, 3, 5, + 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, + 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, + 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, + 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, + + 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, + 5, 5, 5, 5, 5, 5, 5, 5, 7, 738, + 58, 50, 8, 9, 9, 9, 10, 10, 10, 33, + 34, 58, 232, 232, 33, 34, 7, 7, 50, 7, + 8, 8, 180, 8, 91, 9, 180, 91, 10, 11, + 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, + 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, + 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, + 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, + 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, + + 11, 11, 11, 11, 11, 11, 11, 11, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, + 13, 13, 13, 13, 13, 13, 13, 17, 21, 17, + 31, 17, 17, 22, 32, 25, 17, 17, 71, 17, + 705, 17, 60, 25, 119, 26, 71, 17, 17, 17, + 17, 60, 60, 26, 698, 37, 37, 37, 46, 46, + + 46, 37, 62, 46, 38, 38, 38, 62, 31, 140, + 38, 21, 32, 17, 62, 697, 22, 140, 113, 17, + 18, 25, 18, 113, 18, 18, 37, 119, 683, 18, + 18, 26, 18, 139, 18, 38, 139, 103, 103, 103, + 18, 18, 18, 18, 47, 47, 47, 51, 51, 47, + 61, 51, 666, 139, 144, 151, 61, 61, 61, 103, + 151, 51, 78, 78, 78, 199, 18, 78, 51, 51, + 199, 144, 18, 35, 35, 35, 35, 35, 35, 35, + 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, + 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, + + 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, + 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, + 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, + 35, 35, 63, 216, 63, 63, 63, 64, 216, 64, + 64, 64, 83, 79, 79, 79, 665, 63, 79, 108, + 108, 108, 64, 147, 83, 83, 83, 147, 147, 177, + 88, 63, 88, 88, 88, 661, 110, 110, 110, 63, + 82, 108, 82, 148, 82, 82, 177, 148, 148, 82, + 82, 110, 82, 90, 82, 90, 90, 90, 314, 314, + 82, 82, 82, 82, 121, 121, 121, 660, 90, 125, + + 125, 82, 124, 124, 124, 127, 127, 127, 150, 121, + 150, 124, 194, 194, 127, 181, 82, 124, 82, 181, + 127, 654, 82, 343, 653, 125, 128, 128, 128, 129, + 129, 129, 264, 125, 125, 128, 135, 135, 135, 264, + 343, 128, 651, 194, 129, 141, 141, 141, 543, 141, + 142, 142, 142, 543, 162, 162, 162, 267, 135, 142, + 141, 143, 143, 143, 267, 142, 143, 162, 166, 166, + 166, 167, 403, 167, 167, 167, 346, 168, 273, 168, + 403, 166, 168, 168, 168, 273, 167, 650, 407, 141, + 176, 176, 176, 346, 142, 176, 407, 141, 183, 183, + + 183, 649, 142, 146, 146, 146, 146, 146, 146, 146, + 146, 146, 146, 146, 146, 146, 146, 146, 146, 146, + 146, 146, 146, 146, 146, 146, 146, 146, 146, 146, + 146, 146, 146, 146, 146, 146, 146, 146, 146, 146, + 146, 146, 146, 146, 146, 146, 146, 146, 146, 146, + 146, 146, 146, 146, 146, 146, 146, 146, 146, 146, + 146, 146, 179, 629, 179, 414, 179, 179, 187, 187, + 187, 179, 179, 414, 179, 564, 179, 189, 189, 189, + 564, 187, 179, 179, 179, 179, 263, 263, 263, 190, + 189, 190, 190, 190, 191, 271, 191, 293, 293, 191, + + 191, 191, 628, 271, 190, 280, 280, 280, 179, 205, + 205, 205, 271, 592, 179, 185, 523, 185, 280, 185, + 185, 208, 208, 208, 185, 185, 523, 185, 293, 185, + 592, 205, 209, 209, 209, 185, 185, 185, 185, 627, + 212, 212, 212, 208, 213, 213, 213, 223, 223, 223, + 281, 281, 281, 213, 209, 212, 224, 224, 224, 213, + 624, 185, 223, 622, 542, 224, 542, 185, 227, 227, + 227, 224, 228, 228, 228, 237, 237, 237, 247, 247, + 247, 228, 829, 227, 238, 238, 238, 228, 829, 549, + 237, 549, 621, 238, 240, 240, 240, 355, 355, 238, + + 247, 241, 241, 241, 248, 248, 248, 421, 421, 240, + 241, 620, 252, 252, 252, 617, 241, 255, 255, 255, + 616, 256, 256, 256, 569, 615, 248, 252, 355, 610, + 256, 569, 255, 282, 282, 282, 256, 290, 421, 290, + 290, 290, 291, 577, 291, 291, 291, 292, 292, 292, + 577, 606, 290, 301, 301, 301, 252, 291, 352, 352, + 352, 255, 301, 604, 252, 256, 492, 492, 301, 255, + 351, 351, 351, 256, 259, 259, 259, 259, 259, 259, + 259, 259, 259, 259, 259, 259, 259, 259, 259, 259, + 259, 259, 259, 296, 296, 296, 612, 492, 259, 259, + + 259, 285, 595, 285, 612, 285, 285, 603, 296, 601, + 285, 285, 351, 285, 600, 285, 299, 299, 299, 595, + 602, 285, 285, 285, 285, 567, 300, 300, 300, 304, + 304, 304, 613, 567, 306, 306, 306, 602, 299, 835, + 613, 296, 567, 306, 304, 835, 599, 285, 300, 306, + 309, 309, 309, 285, 288, 614, 288, 598, 288, 288, + 360, 360, 360, 288, 288, 309, 288, 836, 288, 310, + 310, 310, 614, 836, 288, 288, 288, 288, 310, 313, + 313, 313, 360, 597, 310, 575, 318, 318, 318, 320, + 320, 320, 596, 575, 313, 318, 321, 321, 321, 594, + + 288, 318, 575, 593, 320, 321, 288, 323, 323, 323, + 591, 321, 326, 326, 326, 328, 328, 328, 330, 330, + 330, 623, 323, 652, 328, 839, 839, 326, 590, 623, + 328, 652, 353, 330, 353, 353, 353, 354, 589, 354, + 354, 354, 356, 356, 356, 837, 588, 353, 357, 357, + 357, 837, 354, 358, 358, 358, 326, 356, 587, 328, + 844, 586, 330, 357, 326, 581, 844, 328, 358, 576, + 330, 359, 359, 359, 571, 362, 362, 362, 570, 364, + 364, 364, 568, 365, 365, 365, 359, 359, 364, 845, + 356, 366, 366, 366, 364, 845, 357, 362, 365, 566, + + 565, 358, 563, 367, 367, 367, 366, 368, 368, 368, + 369, 369, 369, 370, 370, 370, 368, 359, 367, 359, + 846, 855, 368, 561, 559, 369, 846, 855, 370, 371, + 371, 371, 372, 372, 372, 373, 373, 373, 374, 374, + 374, 372, 856, 861, 371, 862, 864, 372, 856, 861, + 373, 862, 864, 374, 375, 375, 375, 380, 380, 380, + 381, 381, 381, 382, 382, 382, 380, 865, 866, 375, + 550, 544, 380, 865, 866, 381, 541, 533, 382, 383, + 383, 383, 384, 384, 384, 385, 385, 385, 386, 386, + 386, 384, 530, 522, 383, 521, 518, 384, 516, 510, + + 385, 508, 507, 386, 387, 387, 387, 388, 388, 388, + 389, 389, 389, 390, 390, 390, 391, 391, 391, 387, + 392, 392, 392, 503, 501, 389, 491, 484, 390, 483, + 481, 391, 394, 394, 394, 392, 480, 395, 395, 395, + 474, 394, 825, 396, 396, 396, 473, 394, 472, 388, + 471, 392, 395, 469, 389, 825, 825, 390, 396, 468, + 391, 467, 389, 465, 392, 390, 457, 454, 391, 409, + 409, 409, 392, 397, 397, 397, 394, 398, 398, 398, + 417, 395, 415, 413, 394, 412, 411, 396, 397, 395, + 408, 406, 398, 405, 404, 396, 410, 410, 410, 416, + + 416, 416, 418, 402, 418, 418, 418, 419, 398, 419, + 419, 419, 401, 420, 420, 420, 400, 397, 410, 399, + 393, 398, 419, 350, 349, 397, 420, 348, 347, 398, + 475, 475, 475, 345, 423, 423, 423, 344, 425, 425, + 425, 416, 422, 422, 422, 422, 422, 422, 422, 423, + 342, 422, 422, 425, 479, 479, 479, 422, 422, 423, + 341, 426, 426, 426, 422, 422, 422, 422, 340, 422, + 426, 339, 427, 427, 427, 338, 426, 337, 430, 430, + 430, 427, 423, 476, 476, 476, 425, 427, 336, 335, + 422, 422, 422, 430, 428, 428, 428, 422, 422, 422, + + 424, 424, 424, 428, 331, 476, 424, 424, 329, 428, + 424, 424, 424, 424, 327, 424, 424, 424, 424, 424, + 424, 325, 453, 453, 453, 424, 324, 424, 424, 424, + 424, 424, 424, 424, 424, 424, 424, 424, 424, 424, + 424, 424, 424, 424, 424, 424, 424, 322, 424, 319, + 424, 424, 424, 424, 429, 429, 429, 424, 431, 431, + 431, 312, 308, 429, 453, 303, 294, 431, 286, 429, + 432, 432, 432, 431, 433, 433, 433, 284, 278, 432, + 482, 482, 482, 433, 275, 432, 434, 434, 434, 433, + 435, 435, 435, 274, 272, 434, 270, 436, 436, 436, + + 269, 434, 437, 437, 437, 435, 436, 438, 438, 438, + 268, 437, 436, 440, 440, 440, 438, 437, 439, 439, + 439, 266, 438, 443, 443, 443, 265, 439, 440, 485, + 485, 485, 443, 439, 444, 444, 444, 258, 443, 445, + 445, 445, 257, 444, 446, 446, 446, 254, 445, 444, + 447, 447, 447, 446, 445, 448, 448, 448, 253, 446, + 449, 449, 449, 251, 448, 447, 452, 452, 452, 449, + 448, 450, 450, 450, 250, 449, 451, 451, 451, 246, + 450, 452, 455, 455, 455, 451, 450, 456, 456, 456, + 242, 451, 458, 458, 458, 239, 230, 455, 478, 478, + + 478, 458, 456, 459, 459, 459, 225, 458, 460, 460, + 460, 214, 459, 461, 461, 461, 204, 460, 459, 203, + 478, 201, 461, 460, 184, 174, 455, 164, 461, 456, + 160, 456, 152, 149, 455, 133, 458, 130, 116, 456, + 114, 462, 462, 462, 458, 98, 97, 459, 96, 95, + 462, 94, 460, 93, 89, 459, 462, 461, 87, 75, + 460, 463, 463, 463, 69, 461, 464, 464, 464, 68, + 67, 486, 462, 486, 486, 486, 463, 487, 487, 487, + 57, 464, 494, 494, 494, 462, 495, 495, 495, 53, + 487, 494, 52, 462, 48, 495, 43, 494, 511, 511, + + 511, 495, 496, 496, 496, 463, 42, 41, 464, 40, + 464, 496, 39, 463, 512, 512, 512, 496, 464, 488, + 488, 488, 488, 488, 488, 488, 30, 29, 488, 488, + 499, 499, 499, 28, 488, 488, 512, 27, 24, 499, + 23, 488, 488, 488, 488, 499, 488, 500, 500, 500, + 20, 502, 502, 502, 19, 16, 500, 514, 514, 514, + 15, 0, 500, 515, 515, 515, 502, 488, 488, 488, + 517, 517, 517, 0, 488, 488, 488, 493, 493, 493, + 502, 520, 520, 520, 493, 0, 0, 493, 493, 493, + 493, 0, 493, 493, 493, 502, 504, 504, 504, 505, + + 505, 505, 493, 502, 0, 504, 0, 0, 505, 0, + 0, 504, 0, 0, 505, 506, 506, 506, 0, 529, + 529, 529, 0, 493, 0, 493, 528, 528, 528, 0, + 506, 534, 534, 534, 529, 535, 535, 535, 0, 0, + 504, 505, 0, 505, 506, 0, 529, 0, 504, 0, + 0, 505, 536, 536, 536, 0, 0, 528, 0, 506, + 528, 0, 0, 529, 531, 531, 531, 506, 519, 519, + 519, 529, 0, 531, 537, 537, 537, 528, 0, 531, + 0, 534, 538, 538, 538, 535, 545, 545, 545, 556, + 556, 556, 0, 531, 557, 557, 557, 0, 519, 519, + + 0, 0, 519, 558, 558, 558, 0, 0, 531, 548, + 548, 548, 519, 560, 560, 560, 531, 0, 0, 519, + 519, 524, 524, 524, 524, 524, 524, 524, 524, 524, + 524, 524, 524, 524, 524, 524, 524, 524, 524, 524, + 548, 0, 0, 548, 524, 524, 524, 524, 562, 562, + 562, 524, 526, 526, 526, 532, 532, 532, 0, 526, + 548, 0, 526, 526, 526, 526, 0, 526, 526, 526, + 532, 0, 551, 551, 551, 0, 0, 526, 0, 552, + 552, 552, 532, 618, 618, 618, 0, 551, 552, 625, + 625, 625, 0, 0, 552, 619, 619, 619, 526, 532, + + 526, 0, 0, 553, 553, 553, 0, 532, 539, 539, + 539, 551, 553, 555, 555, 555, 551, 619, 553, 626, + 626, 626, 555, 0, 551, 579, 579, 579, 555, 0, + 553, 655, 655, 655, 579, 584, 584, 584, 539, 539, + 579, 626, 539, 0, 584, 0, 0, 553, 0, 0, + 584, 0, 539, 0, 0, 553, 659, 659, 659, 539, + 539, 546, 546, 546, 546, 546, 546, 546, 546, 546, + 546, 546, 546, 546, 546, 546, 546, 546, 546, 546, + 546, 546, 546, 546, 546, 546, 546, 546, 546, 546, + 546, 546, 546, 546, 546, 546, 546, 546, 546, 546, + + 546, 546, 546, 546, 546, 546, 546, 546, 546, 546, + 546, 546, 546, 546, 546, 546, 546, 546, 546, 546, + 554, 554, 554, 578, 578, 578, 0, 582, 582, 582, + 583, 583, 583, 0, 0, 554, 582, 0, 578, 662, + 662, 662, 582, 0, 0, 583, 0, 605, 605, 605, + 0, 656, 656, 656, 578, 0, 605, 0, 0, 554, + 0, 583, 605, 0, 554, 0, 582, 578, 607, 607, + 607, 582, 554, 656, 583, 578, 0, 607, 0, 582, + 0, 0, 583, 607, 0, 608, 608, 608, 609, 609, + 609, 605, 0, 0, 608, 0, 0, 609, 0, 605, + + 608, 0, 0, 609, 611, 611, 611, 0, 630, 630, + 630, 0, 0, 611, 0, 0, 608, 630, 0, 611, + 658, 658, 658, 630, 631, 631, 631, 0, 0, 608, + 0, 0, 609, 631, 632, 632, 632, 608, 0, 631, + 609, 0, 658, 632, 633, 633, 633, 0, 0, 632, + 0, 0, 630, 0, 635, 635, 635, 0, 0, 633, + 630, 0, 0, 635, 636, 636, 636, 0, 631, 635, + 664, 664, 664, 636, 0, 0, 631, 0, 632, 636, + 637, 637, 637, 638, 638, 638, 632, 0, 633, 637, + 0, 0, 638, 0, 0, 637, 633, 0, 638, 639, + + 639, 639, 640, 640, 640, 695, 695, 695, 639, 0, + 0, 640, 0, 0, 639, 0, 0, 640, 641, 641, + 641, 642, 642, 642, 643, 643, 643, 641, 0, 0, + 642, 0, 0, 641, 0, 0, 642, 0, 0, 643, + 645, 645, 645, 639, 0, 0, 640, 0, 0, 645, + 0, 639, 0, 0, 640, 645, 0, 646, 646, 646, + 0, 0, 641, 0, 0, 642, 646, 0, 643, 0, + 641, 0, 646, 642, 0, 0, 643, 647, 647, 647, + 648, 648, 648, 663, 663, 663, 647, 0, 0, 648, + 0, 0, 647, 0, 0, 648, 0, 667, 667, 667, + + 668, 668, 668, 0, 0, 663, 667, 0, 0, 668, + 0, 0, 667, 0, 0, 668, 669, 669, 669, 670, + 670, 670, 696, 696, 696, 669, 0, 0, 670, 0, + 0, 669, 0, 0, 670, 0, 671, 671, 671, 0, + 0, 667, 0, 0, 668, 671, 672, 672, 672, 667, + 0, 671, 668, 0, 0, 672, 0, 673, 673, 673, + 669, 672, 0, 670, 0, 0, 673, 671, 669, 0, + 0, 670, 673, 0, 674, 674, 674, 675, 675, 675, + 671, 0, 0, 674, 0, 0, 675, 0, 671, 674, + 672, 0, 675, 676, 676, 676, 0, 0, 672, 699, + + 699, 699, 676, 677, 677, 677, 0, 0, 676, 700, + 700, 700, 677, 678, 678, 678, 0, 0, 677, 701, + 701, 701, 678, 679, 679, 679, 0, 0, 678, 703, + 703, 703, 679, 680, 680, 680, 0, 0, 679, 0, + 0, 701, 680, 681, 681, 681, 0, 0, 680, 704, + 704, 704, 681, 684, 684, 684, 0, 678, 681, 706, + 706, 706, 684, 0, 0, 678, 0, 679, 684, 685, + 685, 685, 707, 707, 707, 679, 0, 680, 685, 686, + 686, 686, 0, 0, 685, 680, 0, 681, 686, 687, + 687, 687, 0, 0, 686, 681, 0, 684, 687, 688, + + 688, 688, 0, 0, 687, 684, 0, 0, 688, 689, + 689, 689, 0, 685, 688, 733, 733, 733, 689, 0, + 0, 685, 0, 686, 689, 690, 690, 690, 0, 0, + 688, 686, 0, 687, 690, 691, 691, 691, 0, 0, + 690, 687, 0, 688, 691, 692, 692, 692, 0, 0, + 691, 688, 0, 689, 692, 693, 693, 693, 0, 0, + 692, 689, 0, 0, 693, 694, 694, 694, 0, 0, + 693, 709, 709, 709, 694, 708, 708, 708, 0, 0, + 694, 734, 734, 734, 708, 0, 709, 710, 710, 710, + 708, 711, 711, 711, 0, 0, 710, 735, 735, 735, + + 711, 0, 710, 712, 712, 712, 711, 713, 713, 713, + 0, 0, 712, 0, 0, 709, 713, 0, 712, 708, + 0, 0, 713, 709, 736, 736, 736, 708, 737, 737, + 737, 710, 739, 739, 739, 711, 740, 740, 740, 710, + 741, 741, 741, 711, 765, 765, 765, 712, 714, 714, + 714, 713, 715, 715, 715, 712, 0, 714, 0, 713, + 0, 715, 0, 714, 766, 766, 766, 715, 717, 717, + 717, 718, 718, 718, 0, 0, 0, 717, 0, 714, + 718, 0, 0, 717, 0, 0, 718, 719, 719, 719, + 0, 0, 714, 0, 0, 0, 719, 0, 0, 0, + + 714, 0, 719, 0, 720, 720, 720, 721, 721, 721, + 0, 0, 717, 720, 0, 718, 721, 0, 0, 720, + 717, 0, 721, 718, 0, 722, 722, 722, 723, 723, + 723, 719, 0, 0, 722, 0, 0, 723, 721, 719, + 722, 0, 0, 723, 0, 724, 724, 724, 720, 0, + 0, 721, 726, 726, 726, 0, 720, 0, 0, 721, + 724, 726, 0, 0, 727, 727, 727, 726, 0, 722, + 0, 0, 723, 727, 0, 0, 0, 722, 0, 727, + 723, 0, 0, 728, 728, 728, 729, 729, 729, 724, + 0, 0, 728, 0, 0, 729, 726, 724, 728, 0, + + 0, 729, 0, 0, 726, 730, 730, 730, 727, 731, + 731, 731, 0, 0, 730, 0, 727, 0, 731, 0, + 730, 0, 0, 0, 731, 0, 0, 728, 0, 0, + 729, 742, 742, 742, 0, 728, 730, 0, 729, 0, + 742, 743, 743, 743, 0, 0, 742, 0, 0, 730, + 743, 744, 744, 744, 0, 0, 743, 730, 0, 0, + 744, 745, 745, 745, 0, 0, 744, 0, 0, 0, + 745, 746, 746, 746, 0, 742, 745, 0, 0, 0, + 746, 0, 0, 742, 0, 743, 746, 747, 747, 747, + 0, 0, 0, 743, 0, 744, 747, 748, 748, 748, + + 0, 0, 747, 744, 0, 745, 748, 750, 750, 750, + 0, 0, 748, 745, 0, 746, 750, 0, 747, 749, + 749, 749, 750, 746, 0, 0, 0, 0, 749, 0, + 0, 747, 0, 0, 749, 751, 751, 751, 0, 747, + 0, 748, 0, 0, 751, 752, 752, 752, 0, 748, + 751, 750, 0, 0, 752, 753, 753, 753, 0, 750, + 752, 749, 0, 749, 753, 754, 754, 754, 0, 0, + 753, 749, 0, 0, 754, 755, 755, 755, 0, 751, + 754, 0, 0, 0, 755, 0, 0, 751, 0, 752, + 755, 0, 0, 756, 756, 756, 0, 752, 0, 753, + + 0, 0, 756, 757, 757, 757, 755, 753, 756, 754, + 0, 0, 757, 758, 758, 758, 0, 754, 757, 755, + 0, 0, 758, 759, 759, 759, 0, 755, 758, 0, + 0, 0, 759, 760, 760, 760, 0, 756, 759, 0, + 0, 0, 760, 0, 0, 756, 0, 757, 760, 761, + 761, 761, 0, 0, 0, 757, 0, 758, 761, 762, + 762, 762, 0, 0, 761, 758, 0, 759, 762, 763, + 763, 763, 0, 0, 762, 759, 0, 760, 763, 0, + 764, 764, 764, 0, 763, 760, 0, 0, 0, 764, + 762, 0, 0, 761, 0, 764, 0, 767, 767, 767, + + 0, 761, 0, 762, 0, 0, 767, 0, 768, 768, + 768, 762, 767, 763, 0, 0, 0, 768, 769, 769, + 769, 763, 764, 768, 764, 0, 0, 769, 0, 770, + 770, 770, 764, 769, 0, 0, 0, 768, 770, 0, + 0, 767, 0, 0, 770, 0, 771, 771, 771, 767, + 0, 0, 768, 0, 0, 771, 772, 772, 772, 0, + 768, 771, 769, 0, 0, 772, 0, 0, 0, 0, + 769, 772, 0, 770, 773, 773, 773, 774, 774, 774, + 0, 770, 0, 773, 0, 0, 774, 0, 0, 773, + 771, 0, 774, 0, 775, 775, 775, 0, 771, 0, + + 772, 0, 0, 775, 0, 773, 0, 0, 772, 775, + 776, 776, 776, 778, 778, 778, 0, 0, 773, 776, + 0, 774, 778, 0, 0, 776, 773, 0, 778, 774, + 0, 0, 779, 779, 779, 0, 775, 0, 775, 0, + 0, 779, 778, 780, 780, 780, 775, 779, 0, 0, + 0, 0, 780, 0, 776, 0, 0, 778, 780, 779, + 0, 0, 776, 0, 0, 778, 0, 0, 781, 781, + 781, 782, 782, 782, 0, 0, 779, 781, 0, 0, + 782, 0, 0, 781, 779, 0, 782, 780, 0, 0, + 783, 783, 783, 0, 0, 780, 0, 781, 782, 783, + + 0, 784, 784, 784, 0, 783, 0, 0, 0, 0, + 784, 0, 781, 0, 0, 782, 784, 785, 785, 785, + 781, 0, 0, 782, 0, 0, 785, 0, 784, 783, + 0, 0, 785, 0, 783, 786, 786, 786, 0, 787, + 787, 787, 783, 0, 786, 784, 0, 0, 787, 0, + 786, 0, 0, 784, 787, 0, 785, 0, 788, 788, + 788, 785, 789, 789, 789, 0, 786, 788, 0, 785, + 0, 789, 0, 788, 0, 0, 0, 789, 787, 786, + 0, 0, 0, 787, 790, 790, 790, 786, 0, 788, + 0, 787, 0, 790, 791, 791, 791, 0, 0, 790, + + 0, 0, 788, 791, 0, 0, 789, 0, 0, 791, + 788, 792, 792, 792, 789, 790, 0, 0, 0, 0, + 792, 0, 0, 0, 0, 0, 792, 0, 790, 0, + 0, 0, 0, 0, 0, 0, 790, 0, 791, 0, + 0, 0, 0, 0, 0, 0, 791, 0, 0, 0, + 0, 0, 0, 0, 0, 792, 0, 0, 0, 0, + 0, 0, 0, 792, 794, 794, 794, 794, 794, 794, + 794, 794, 794, 794, 794, 794, 794, 794, 794, 794, + 794, 794, 794, 794, 794, 795, 795, 795, 795, 795, + 795, 795, 795, 795, 795, 795, 795, 795, 795, 795, + + 795, 795, 795, 795, 795, 795, 796, 796, 796, 796, + 796, 796, 796, 796, 796, 796, 796, 796, 796, 796, + 796, 796, 796, 796, 796, 796, 796, 797, 797, 797, + 797, 797, 797, 797, 797, 797, 797, 797, 797, 797, + 797, 797, 797, 797, 797, 797, 797, 797, 798, 798, + 798, 798, 798, 798, 798, 798, 798, 798, 798, 798, + 798, 798, 798, 798, 798, 798, 798, 798, 798, 799, + 799, 799, 799, 799, 799, 799, 799, 799, 799, 799, + 799, 799, 799, 799, 799, 799, 799, 799, 799, 799, + 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, + + 800, 800, 800, 800, 800, 800, 800, 800, 800, 800, + 800, 801, 801, 801, 801, 801, 801, 801, 801, 801, + 801, 801, 801, 801, 801, 801, 801, 801, 801, 801, + 801, 801, 802, 802, 802, 802, 802, 802, 802, 802, + 802, 802, 802, 802, 802, 802, 802, 802, 802, 802, + 802, 802, 802, 803, 803, 803, 803, 803, 803, 803, + 803, 803, 803, 803, 803, 803, 803, 803, 803, 803, + 803, 803, 803, 803, 804, 804, 804, 804, 804, 804, + 804, 804, 804, 804, 804, 804, 804, 804, 804, 804, + 804, 804, 804, 804, 804, 805, 805, 805, 805, 805, + + 805, 805, 805, 805, 805, 805, 805, 805, 805, 805, + 805, 805, 805, 805, 805, 805, 806, 806, 806, 806, + 806, 806, 806, 806, 806, 806, 806, 806, 806, 806, + 806, 806, 806, 806, 806, 806, 806, 807, 0, 0, + 0, 0, 0, 0, 807, 0, 0, 0, 0, 0, + 807, 807, 808, 0, 0, 808, 0, 0, 808, 808, + 0, 0, 0, 0, 808, 808, 808, 809, 0, 0, + 0, 0, 0, 0, 809, 0, 0, 0, 0, 0, + 809, 809, 810, 0, 0, 810, 0, 810, 810, 811, + 0, 0, 0, 0, 0, 0, 811, 0, 0, 0, + + 0, 0, 811, 811, 812, 812, 812, 812, 0, 812, + 812, 812, 812, 812, 812, 812, 812, 812, 812, 0, + 812, 0, 812, 812, 812, 813, 813, 813, 813, 0, + 813, 813, 813, 813, 813, 813, 813, 813, 813, 813, + 813, 813, 813, 813, 813, 813, 814, 814, 814, 814, + 814, 814, 814, 814, 814, 814, 814, 814, 814, 814, + 814, 814, 814, 0, 814, 814, 814, 815, 0, 0, + 0, 0, 0, 0, 815, 0, 0, 0, 0, 0, + 815, 815, 816, 816, 0, 0, 816, 0, 0, 0, + 0, 0, 0, 816, 0, 816, 0, 0, 0, 816, + + 816, 817, 817, 817, 817, 817, 817, 817, 0, 817, + 817, 817, 817, 817, 817, 817, 817, 817, 817, 817, + 817, 817, 818, 818, 818, 818, 818, 818, 818, 818, + 818, 0, 818, 818, 818, 818, 818, 818, 818, 818, + 818, 818, 818, 819, 819, 819, 819, 0, 819, 819, + 819, 819, 819, 819, 819, 819, 819, 819, 819, 819, + 819, 819, 819, 819, 820, 820, 820, 820, 820, 820, + 820, 0, 820, 820, 820, 820, 820, 820, 820, 820, + 820, 820, 820, 820, 820, 821, 821, 821, 821, 821, + 821, 821, 0, 821, 821, 821, 821, 821, 821, 821, + + 821, 821, 821, 821, 821, 822, 822, 822, 822, 822, + 822, 822, 822, 822, 822, 822, 822, 822, 822, 822, + 822, 822, 822, 822, 822, 822, 823, 823, 823, 823, + 823, 823, 823, 0, 823, 823, 823, 823, 823, 823, + 823, 823, 823, 823, 823, 823, 823, 824, 824, 824, + 824, 824, 0, 824, 824, 824, 824, 824, 824, 824, + 824, 824, 824, 824, 824, 824, 824, 824, 826, 826, + 0, 0, 826, 0, 0, 0, 0, 0, 0, 826, + 0, 826, 0, 0, 0, 826, 826, 827, 0, 0, + 827, 0, 0, 827, 827, 0, 0, 0, 0, 827, + + 827, 827, 828, 828, 828, 828, 828, 828, 828, 828, + 828, 828, 828, 828, 828, 828, 828, 828, 828, 828, + 828, 828, 828, 830, 0, 0, 0, 0, 0, 0, + 830, 0, 0, 0, 0, 0, 830, 830, 831, 831, + 0, 831, 831, 831, 831, 831, 831, 831, 831, 831, + 831, 831, 831, 831, 831, 831, 831, 831, 831, 832, + 0, 0, 832, 0, 0, 832, 832, 0, 0, 0, + 0, 832, 832, 832, 833, 0, 0, 0, 0, 833, + 833, 833, 0, 0, 0, 0, 0, 833, 833, 834, + 0, 0, 834, 0, 0, 834, 834, 0, 0, 0, + + 0, 834, 834, 834, 838, 0, 0, 0, 0, 0, + 0, 838, 0, 0, 0, 0, 0, 838, 838, 840, + 840, 0, 0, 840, 840, 0, 840, 840, 840, 840, + 840, 0, 0, 0, 0, 840, 840, 840, 841, 841, + 841, 841, 841, 841, 841, 841, 841, 841, 841, 841, + 841, 841, 841, 841, 841, 841, 841, 841, 841, 842, + 842, 842, 842, 842, 842, 842, 842, 842, 842, 842, + 842, 842, 842, 842, 842, 842, 842, 842, 842, 842, + 843, 843, 843, 843, 843, 843, 843, 843, 843, 843, + 843, 843, 843, 843, 843, 843, 843, 843, 843, 843, + + 843, 847, 847, 847, 847, 847, 847, 847, 847, 847, + 847, 847, 847, 847, 847, 847, 847, 847, 847, 847, + 847, 847, 848, 848, 848, 848, 848, 848, 848, 848, + 848, 848, 848, 848, 848, 848, 848, 848, 848, 848, + 848, 848, 848, 849, 849, 849, 849, 849, 849, 849, + 849, 849, 849, 849, 849, 849, 849, 849, 849, 849, + 849, 849, 849, 849, 850, 850, 850, 850, 850, 850, + 850, 850, 850, 850, 850, 850, 850, 850, 850, 850, + 850, 850, 850, 850, 850, 851, 0, 0, 0, 0, + 851, 851, 851, 0, 0, 0, 0, 0, 851, 851, + + 852, 852, 852, 852, 852, 852, 852, 852, 852, 852, + 852, 852, 852, 852, 852, 852, 852, 852, 852, 852, + 852, 853, 853, 853, 853, 853, 853, 853, 853, 853, + 853, 853, 853, 853, 853, 853, 853, 853, 853, 853, + 853, 853, 854, 854, 854, 854, 854, 854, 854, 854, + 854, 854, 854, 854, 854, 854, 854, 854, 854, 854, + 854, 854, 854, 857, 857, 857, 857, 857, 857, 857, + 857, 857, 857, 857, 857, 857, 857, 857, 857, 857, + 857, 857, 857, 857, 858, 858, 858, 858, 858, 858, + 858, 858, 858, 858, 858, 858, 858, 858, 858, 858, + + 858, 858, 858, 858, 858, 859, 859, 859, 859, 859, + 859, 859, 859, 859, 859, 859, 859, 859, 859, 859, + 859, 859, 859, 859, 859, 859, 860, 860, 860, 860, + 860, 860, 860, 860, 860, 860, 860, 860, 860, 860, + 860, 860, 860, 860, 860, 860, 860, 863, 863, 0, + 0, 863, 863, 0, 863, 863, 863, 863, 863, 0, + 0, 0, 0, 863, 863, 863, 867, 867, 867, 867, + 867, 867, 867, 0, 867, 867, 867, 867, 867, 867, + 867, 867, 867, 867, 867, 867, 867, 868, 868, 868, + 868, 868, 868, 868, 0, 868, 868, 868, 868, 868, + + 868, 868, 868, 868, 868, 868, 868, 868, 869, 869, + 869, 869, 869, 869, 869, 869, 869, 869, 869, 869, + 869, 869, 869, 869, 869, 869, 869, 869, 869, 870, + 870, 870, 870, 870, 870, 870, 870, 870, 870, 870, + 870, 870, 870, 870, 870, 870, 870, 870, 870, 870, + 871, 871, 871, 871, 871, 871, 871, 871, 871, 871, + 871, 871, 871, 871, 871, 871, 871, 871, 871, 871, + 871, 872, 872, 872, 872, 872, 872, 872, 872, 872, + 872, 872, 872, 872, 872, 872, 872, 872, 872, 872, + 872, 872, 873, 873, 873, 873, 873, 873, 873, 873, + + 873, 873, 873, 873, 873, 873, 873, 873, 873, 873, + 873, 873, 873, 874, 874, 874, 874, 874, 874, 874, + 874, 874, 874, 874, 874, 874, 874, 874, 874, 874, + 874, 874, 874, 874, 875, 875, 875, 875, 875, 875, + 875, 875, 875, 875, 875, 875, 875, 875, 875, 875, + 875, 875, 875, 875, 875, 876, 876, 876, 876, 876, + 876, 876, 876, 876, 876, 876, 876, 876, 876, 876, + 876, 876, 876, 876, 876, 876, 877, 877, 877, 877, + 877, 877, 877, 877, 877, 877, 877, 877, 877, 877, + 877, 877, 877, 877, 877, 877, 877, 878, 878, 878, + + 878, 878, 878, 878, 878, 878, 878, 878, 878, 878, + 878, 878, 878, 878, 878, 878, 878, 878, 879, 879, + 879, 879, 879, 879, 879, 879, 879, 879, 879, 879, + 879, 879, 879, 879, 879, 879, 879, 879, 879, 880, + 880, 880, 880, 880, 880, 880, 880, 880, 880, 880, + 880, 880, 880, 880, 880, 880, 880, 880, 880, 880, + 881, 881, 881, 881, 881, 881, 881, 881, 881, 881, + 881, 881, 881, 881, 881, 881, 881, 881, 881, 881, + 881, 793, 793, 793, 793, 793, 793, 793, 793, 793, + 793, 793, 793, 793, 793, 793, 793, 793, 793, 793, + + 793, 793, 793, 793, 793, 793, 793, 793, 793, 793, + 793, 793, 793, 793, 793, 793, 793, 793, 793, 793, + 793, 793, 793, 793, 793, 793, 793, 793, 793, 793, + 793, 793, 793, 793, 793, 793, 793, 793, 793, 793, + 793 + } ; + +/* Table of booleans, true if rule could match eol. */ +static yyconst flex_int32_t yy_rule_can_match_eol[143] = + { 0, +1, 0, 0, 0, 1, 0, 0, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 0, 0, + 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 1, 0, 1, 0, 0, 1, 0, + 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 1, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 1, 0, 1, 1, 1, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 0, 1, 1, 1, 1, 1, 1, + 1, 1, 0, }; + +static yy_state_type yy_last_accepting_state; +static char *yy_last_accepting_cpos; + +extern int yy_flex_debug; +int yy_flex_debug = 0; + +/* The intent behind this definition is that it'll catch + * any uses of REJECT which flex missed. + */ +#define REJECT reject_used_but_not_detected +#define yymore() yymore_used_but_not_detected +#define YY_MORE_ADJ 0 +#define YY_RESTORE_YY_MORE_OFFSET +char *yytext; +#line 1 "pgc.l" +#line 2 "pgc.l" +/*------------------------------------------------------------------------- + * + * pgc.l + * lexical scanner for ecpg + * + * This is a modified version of src/backend/parser/scan.l + * + * + * Portions Copyright (c) 1996-2012, PostgreSQL Global Development Group + * Portions Copyright (c) 1994, Regents of the University of California + * + * + * IDENTIFICATION + * src/interfaces/ecpg/preproc/pgc.l + * + *------------------------------------------------------------------------- + */ +#include "postgres_fe.h" + +#include +#include +#include + +#include "extern.h" + +extern YYSTYPE yylval; + +static int xcdepth = 0; /* depth of nesting in slash-star comments */ +static char *dolqstart; /* current $foo$ quote start string */ +static YY_BUFFER_STATE scanbufhandle; +static char *scanbuf; + +/* + * literalbuf is used to accumulate literal values when multiple rules + * are needed to parse a single literal. Call startlit to reset buffer + * to empty, addlit to add text. Note that the buffer is permanently + * malloc'd to the largest size needed so far in the current run. + */ +static char *literalbuf = NULL; /* expandable buffer */ +static int literallen; /* actual current length */ +static int literalalloc; /* current allocated buffer size */ + +/* Used for detecting global state together with braces_open */ +static int parenths_open; + +/* Used to tell parse_include() whether the command was #include or #include_next */ +static bool include_next; + +#define startlit() (literalbuf[0] = '\0', literallen = 0) +static void addlit(char *ytext, int yleng); +static void addlitchar (unsigned char); +static void parse_include (void); +static bool ecpg_isspace(char ch); +static bool isdefine(void); +static bool isinformixdefine(void); + +char *token_start; +int state_before; + +struct _yy_buffer +{ + YY_BUFFER_STATE buffer; + long lineno; + char *filename; + struct _yy_buffer *next; +} *yy_buffer = NULL; + +static char *old; + +#define MAX_NESTED_IF 128 +static short preproc_tos; +static short ifcond; +static struct _if_value +{ + short condition; + short else_branch; +} stacked_if_value[MAX_NESTED_IF]; + +#define YY_NO_INPUT 1 + +/* + * OK, here is a short description of lex/flex rules behavior. + * The longest pattern which matches an input string is always chosen. + * For equal-length patterns, the first occurring in the rules list is chosen. + * INITIAL is the starting state, to which all non-conditional rules apply. + * Exclusive states change parsing rules while the state is active. When in + * an exclusive state, only those rules defined for that state apply. + * + * We use exclusive states for quoted strings, extended comments, + * and to eliminate parsing troubles for numeric strings. + * Exclusive states: + * bit string literal + * extended C-style comments - thomas 1997-07-12 + * delimited identifiers (double-quoted identifiers) - thomas 1997-10-27 + * hexadecimal numeric string - thomas 1997-11-16 + * standard quoted strings - thomas 1997-07-30 + * standard quoted strings in C - michael + * extended quoted strings (support backslash escape sequences) + * national character quoted strings + * $foo$ quoted strings + * quoted identifier with Unicode escapes + * quoted string with Unicode escapes + */ + + + + + + + + + + + + + + +/* Bit string + */ +/* Hexadecimal number */ +/* National character */ +/* Quoted string that allows backslash escapes */ +/* C version of hex number */ +/* Extended quote + * xqdouble implements embedded quote, '''' + */ +/* $foo$ style quotes ("dollar quoting") + * The quoted string starts with $foo$ where "foo" is an optional string + * in the form of an identifier, except that it may not contain "$", + * and extends to the first occurrence of an identical string. + * There is *no* processing of the quoted text. + * + * {dolqfailed} is an error rule to avoid scanner backup when {dolqdelim} + * fails to match its trailing "$". + */ +/* Double quote + * Allows embedded spaces and other special characters into identifiers. + */ +/* Unicode escapes */ +/* (The ecpg scanner is not backup-free, so the fail rules in scan.l are not needed here, but could be added if desired.) */ +/* Quoted identifier with Unicode escapes */ +/* Quoted string with Unicode escapes */ +/* special stuff for C strings */ +/* C-style comments + * + * The "extended comment" syntax closely resembles allowable operator syntax. + * The tricky part here is to get lex to recognize a string starting with + * slash-star as a comment, when interpreting it as an operator would produce + * a longer match --- remember lex will prefer a longer match! Also, if we + * have something like plus-slash-star, lex will think this is a 3-character + * operator whereas we want to see it as a + operator and a comment start. + * The solution is two-fold: + * 1. append {op_chars}* to xcstart so that it matches as much text as + * {operator} would. Then the tie-breaker (first matching rule of same + * length) ensures xcstart wins. We put back the extra stuff with yyless() + * in case it contains a star-slash that should terminate the comment. + * 2. In the operator rule, check for slash-star within the operator, and + * if found throw it back with yyless(). This handles the plus-slash-star + * problem. + * Dash-dash comments have similar interactions with the operator rule. + */ +/* + * "self" is the set of chars that should be returned as single-character + * tokens. "op_chars" is the set of chars that can make up "Op" tokens, + * which can be one or more characters long (but if a single-char token + * appears in the "self" set, it is not to be returned as an Op). Note + * that the sets overlap, but each has some chars that are not in the other. + * + * If you change either set, adjust the character lists appearing in the + * rule for "operator"! + */ +/* we no longer allow unary minus in numbers. + * instead we pass it separately to parser. there it gets + * coerced via doNegate() -- Leon aug 20 1999 + * + * {realfail1} and {realfail2} are added to prevent the need for scanner + * backup when the {real} rule fails to match completely. + */ +/* + * In order to make the world safe for Windows and Mac clients as well as + * Unix ones, we accept either \n or \r as a newline. A DOS-style \r\n + * sequence will be seen as two successive newlines, but that doesn't cause + * any problems. SQL92-style comments, which start with -- and extend to the + * next newline, are treated as equivalent to a single whitespace character. + * + * NOTE a fine point: if there is no newline following --, we will absorb + * everything to the end of the input as a comment. This is correct. Older + * versions of Postgres failed to recognize -- as a comment if the input + * did not end with a newline. + * + * XXX perhaps \f (formfeed) should be treated as a newline as well? + * + * XXX if you change the set of whitespace characters, fix ecpg_isspace() + * to agree. + */ +/* + * SQL92 requires at least one newline in the whitespace separating + * string literals that are to be concatenated. Silly, but who are we + * to argue? Note that {whitespace_with_newline} should not have * after + * it, whereas {whitespace} should generally have a * after it... + */ +/* special characters for other dbms */ +/* we have to react differently in compat mode */ +/* some stuff needed for ecpg */ +/* we might want to parse all cpp include files */ +/* take care of cpp lines, they may also be continuated */ +/* first a general line for all commands not starting with "i" */ +/* and then the other commands starting with "i", we have to add these + * separately because the cppline production would match on "include" too */ +/* + * Dollar quoted strings are totally opaque, and no escaping is done on them. + * Other quoted strings must allow some special characters such as single-quote + * and newline. + * Embedded single-quotes are implemented both in the SQL standard + * style of two adjacent single quotes "''" and in the Postgres/Java style + * of escaped-quote "\'". + * Other embedded escaped characters are matched explicitly and the leading + * backslash is dropped from the string. - thomas 1997-09-24 + * Note that xcstart must appear before operator, as explained above! + * Also whitespace (comment) must appear before operator. + */ +#line 2101 "pgc.c" + +#define INITIAL 0 +#define C 1 +#define SQL 2 +#define incl 3 +#define def 4 +#define def_ident 5 +#define undef 6 +#define xb 7 +#define xc 8 +#define xd 9 +#define xdc 10 +#define xh 11 +#define xe 12 +#define xn 13 +#define xq 14 +#define xqc 15 +#define xdolq 16 +#define xcond 17 +#define xskip 18 +#define xui 19 +#define xus 20 + +#ifndef YY_NO_UNISTD_H +/* Special case for "unistd.h", since it is non-ANSI. We include it way + * down here because we want the user's section 1 to have been scanned first. + * The user has a chance to override it with an option. + */ +#include +#endif + +#ifndef YY_EXTRA_TYPE +#define YY_EXTRA_TYPE void * +#endif + +static int yy_init_globals (void ); + +/* Accessor methods to globals. + These are made visible to non-reentrant scanners for convenience. */ + +int yylex_destroy (void ); + +int yyget_debug (void ); + +void yyset_debug (int debug_flag ); + +YY_EXTRA_TYPE yyget_extra (void ); + +void yyset_extra (YY_EXTRA_TYPE user_defined ); + +FILE *yyget_in (void ); + +void yyset_in (FILE * in_str ); + +FILE *yyget_out (void ); + +void yyset_out (FILE * out_str ); + +int yyget_leng (void ); + +char *yyget_text (void ); + +int yyget_lineno (void ); + +void yyset_lineno (int line_number ); + +/* Macros after this point can all be overridden by user definitions in + * section 1. + */ + +#ifndef YY_SKIP_YYWRAP +#ifdef __cplusplus +extern "C" int yywrap (void ); +#else +extern int yywrap (void ); +#endif +#endif + + static void yyunput (int c,char *buf_ptr ); + +#ifndef yytext_ptr +static void yy_flex_strncpy (char *,yyconst char *,int ); +#endif + +#ifdef YY_NEED_STRLEN +static int yy_flex_strlen (yyconst char * ); +#endif + +#ifndef YY_NO_INPUT + +#ifdef __cplusplus +static int yyinput (void ); +#else +static int input (void ); +#endif + +#endif + +/* Amount of stuff to slurp up with each read. */ +#ifndef YY_READ_BUF_SIZE +#ifdef __ia64__ +/* On IA-64, the buffer size is 16k, not 8k */ +#define YY_READ_BUF_SIZE 16384 +#else +#define YY_READ_BUF_SIZE 8192 +#endif /* __ia64__ */ +#endif + +/* Copy whatever the last rule matched to the standard output. */ +#ifndef ECHO +/* This used to be an fputs(), but since the string might contain NUL's, + * we now use fwrite(). + */ +#define ECHO do { if (fwrite( yytext, yyleng, 1, yyout )) {} } while (0) +#endif + +/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL, + * is returned in "result". + */ +#ifndef YY_INPUT +#define YY_INPUT(buf,result,max_size) \ + if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \ + { \ + int c = '*'; \ + size_t n; \ + for ( n = 0; n < max_size && \ + (c = getc( yyin )) != EOF && c != '\n'; ++n ) \ + buf[n] = (char) c; \ + if ( c == '\n' ) \ + buf[n++] = (char) c; \ + if ( c == EOF && ferror( yyin ) ) \ + YY_FATAL_ERROR( "input in flex scanner failed" ); \ + result = n; \ + } \ + else \ + { \ + errno=0; \ + while ( (result = fread(buf, 1, max_size, yyin))==0 && ferror(yyin)) \ + { \ + if( errno != EINTR) \ + { \ + YY_FATAL_ERROR( "input in flex scanner failed" ); \ + break; \ + } \ + errno=0; \ + clearerr(yyin); \ + } \ + }\ +\ + +#endif + +/* No semi-colon after return; correct usage is to write "yyterminate();" - + * we don't want an extra ';' after the "return" because that will cause + * some compilers to complain about unreachable statements. + */ +#ifndef yyterminate +#define yyterminate() return YY_NULL +#endif + +/* Number of entries by which start-condition stack grows. */ +#ifndef YY_START_STACK_INCR +#define YY_START_STACK_INCR 25 +#endif + +/* Report a fatal error. */ +#ifndef YY_FATAL_ERROR +#define YY_FATAL_ERROR(msg) yy_fatal_error( msg ) +#endif + +/* end tables serialization structures and prototypes */ + +/* Default declaration of generated scanner - a define so the user can + * easily add parameters. + */ +#ifndef YY_DECL +#define YY_DECL_IS_OURS 1 + +extern int yylex (void); + +#define YY_DECL int yylex (void) +#endif /* !YY_DECL */ + +/* Code executed at the beginning of each rule, after yytext and yyleng + * have been set up. + */ +#ifndef YY_USER_ACTION +#define YY_USER_ACTION +#endif + +/* Code executed at the end of each rule. */ +#ifndef YY_BREAK +#define YY_BREAK break; +#endif + +#define YY_RULE_SETUP \ + YY_USER_ACTION + +/** The main scanner function which does all the work. + */ +YY_DECL +{ + register yy_state_type yy_current_state; + register char *yy_cp, *yy_bp; + register int yy_act; + +#line 363 "pgc.l" + + + + /* code to execute during start of each call of yylex() */ + token_start = NULL; + + +#line 2316 "pgc.c" + + if ( !(yy_init) ) + { + (yy_init) = 1; + +#ifdef YY_USER_INIT + YY_USER_INIT; +#endif + + if ( ! (yy_start) ) + (yy_start) = 1; /* first start state */ + + if ( ! yyin ) + yyin = stdin; + + if ( ! yyout ) + yyout = stdout; + + if ( ! YY_CURRENT_BUFFER ) { + yyensure_buffer_stack (); + YY_CURRENT_BUFFER_LVALUE = + yy_create_buffer(yyin,YY_BUF_SIZE ); + } + + yy_load_buffer_state( ); + } + + while ( 1 ) /* loops until end-of-file is reached */ + { + yy_cp = (yy_c_buf_p); + + /* Support of yytext. */ + *yy_cp = (yy_hold_char); + + /* yy_bp points to the position in yy_ch_buf of the start of + * the current run. + */ + yy_bp = yy_cp; + + yy_current_state = (yy_start); +yy_match: + do + { + register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)]; + if ( yy_accept[yy_current_state] ) + { + (yy_last_accepting_state) = yy_current_state; + (yy_last_accepting_cpos) = yy_cp; + } + while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) + { + yy_current_state = (int) yy_def[yy_current_state]; + if ( yy_current_state >= 794 ) + yy_c = yy_meta[(unsigned int) yy_c]; + } + yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; + ++yy_cp; + } + while ( yy_current_state != 793 ); + yy_cp = (yy_last_accepting_cpos); + yy_current_state = (yy_last_accepting_state); + +yy_find_action: + yy_act = yy_accept[yy_current_state]; + + YY_DO_BEFORE_ACTION; + + if ( yy_act != YY_END_OF_BUFFER && yy_rule_can_match_eol[yy_act] ) + { + int yyl; + for ( yyl = 0; yyl < yyleng; ++yyl ) + if ( yytext[yyl] == '\n' ) + + yylineno++; +; + } + +do_action: /* This label is used only to access EOF actions. */ + + switch ( yy_act ) + { /* beginning of action switch */ + case 0: /* must back up */ + /* undo the effects of YY_DO_BEFORE_ACTION */ + *yy_cp = (yy_hold_char); + yy_cp = (yy_last_accepting_cpos); + yy_current_state = (yy_last_accepting_state); + goto yy_find_action; + +case 1: +/* rule 1 can match eol */ +YY_RULE_SETUP +#line 370 "pgc.l" +{ /* ignore */ } + YY_BREAK +case 2: +YY_RULE_SETUP +#line 372 "pgc.l" +{ + token_start = yytext; + state_before = YYSTATE; + xcdepth = 0; + BEGIN(xc); + /* Put back any characters past slash-star; see above */ + yyless(2); + fputs("/*", yyout); + } + YY_BREAK +case 3: +YY_RULE_SETUP +#line 381 "pgc.l" +{ + xcdepth++; + /* Put back any characters past slash-star; see above */ + yyless(2); + fputs("/*", yyout); + } + YY_BREAK +case 4: +YY_RULE_SETUP +#line 388 "pgc.l" +{ + ECHO; + if (xcdepth <= 0) + { + BEGIN(state_before); + token_start = NULL; + } + else + xcdepth--; + } + YY_BREAK +case 5: +/* rule 5 can match eol */ +YY_RULE_SETUP +#line 399 "pgc.l" +{ ECHO; } + YY_BREAK +case 6: +YY_RULE_SETUP +#line 400 "pgc.l" +{ ECHO; } + YY_BREAK +case 7: +YY_RULE_SETUP +#line 401 "pgc.l" +{ ECHO; } + YY_BREAK +case YY_STATE_EOF(xc): +#line 403 "pgc.l" +{ mmerror(PARSE_ERROR, ET_FATAL, "unterminated /* comment"); } + YY_BREAK +case 8: +YY_RULE_SETUP +#line 405 "pgc.l" +{ + token_start = yytext; + BEGIN(xb); + startlit(); + addlitchar('b'); + } + YY_BREAK +case 9: +/* rule 9 can match eol */ +#line 412 "pgc.l" +case 10: +/* rule 10 can match eol */ +YY_RULE_SETUP +#line 412 "pgc.l" +{ + yyless(1); + BEGIN(SQL); + if (literalbuf[strspn(literalbuf, "01") + 1] != '\0') + mmerror(PARSE_ERROR, ET_ERROR, "invalid bit string literal"); + yylval.str = mm_strdup(literalbuf); + return BCONST; + } + YY_BREAK +case 11: +/* rule 11 can match eol */ +#line 422 "pgc.l" +case 12: +/* rule 12 can match eol */ +YY_RULE_SETUP +#line 422 "pgc.l" +{ addlit(yytext, yyleng); } + YY_BREAK +case 13: +/* rule 13 can match eol */ +#line 424 "pgc.l" +case 14: +/* rule 14 can match eol */ +YY_RULE_SETUP +#line 424 "pgc.l" +{ /* ignore */ } + YY_BREAK +case YY_STATE_EOF(xb): +#line 425 "pgc.l" +{ mmerror(PARSE_ERROR, ET_FATAL, "unterminated bit string literal"); } + YY_BREAK +case 15: +YY_RULE_SETUP +#line 427 "pgc.l" +{ + token_start = yytext; + BEGIN(xh); + startlit(); + addlitchar('x'); + } + YY_BREAK +case 16: +/* rule 16 can match eol */ +#line 434 "pgc.l" +case 17: +/* rule 17 can match eol */ +YY_RULE_SETUP +#line 434 "pgc.l" +{ + yyless(1); + BEGIN(SQL); + yylval.str = mm_strdup(literalbuf); + return XCONST; + } + YY_BREAK +case YY_STATE_EOF(xh): +#line 441 "pgc.l" +{ mmerror(PARSE_ERROR, ET_FATAL, "unterminated hexadecimal string literal"); } + YY_BREAK +case 18: +YY_RULE_SETUP +#line 442 "pgc.l" +{ + /* National character. + * Transfer it as-is to the backend. + */ + token_start = yytext; + state_before = YYSTATE; + BEGIN(xn); + startlit(); + } + YY_BREAK +case 19: +YY_RULE_SETUP +#line 451 "pgc.l" +{ + token_start = yytext; + state_before = YYSTATE; + BEGIN(xqc); + startlit(); + } + YY_BREAK +case 20: +YY_RULE_SETUP +#line 457 "pgc.l" +{ + token_start = yytext; + state_before = YYSTATE; + BEGIN(xq); + startlit(); + } + YY_BREAK +case 21: +YY_RULE_SETUP +#line 463 "pgc.l" +{ + token_start = yytext; + state_before = YYSTATE; + BEGIN(xe); + startlit(); + } + YY_BREAK +case 22: +YY_RULE_SETUP +#line 469 "pgc.l" +{ + token_start = yytext; + state_before = YYSTATE; + BEGIN(xus); + startlit(); + addlit(yytext, yyleng); + } + YY_BREAK +case 23: +/* rule 23 can match eol */ +#line 477 "pgc.l" +case 24: +/* rule 24 can match eol */ +YY_RULE_SETUP +#line 477 "pgc.l" +{ + yyless(1); + BEGIN(state_before); + yylval.str = mm_strdup(literalbuf); + return SCONST; + } + YY_BREAK +case 25: +/* rule 25 can match eol */ +#line 484 "pgc.l" +case 26: +/* rule 26 can match eol */ +YY_RULE_SETUP +#line 484 "pgc.l" +{ + yyless(1); + BEGIN(state_before); + yylval.str = mm_strdup(literalbuf); + return ECONST; + } + YY_BREAK +case 27: +/* rule 27 can match eol */ +#line 491 "pgc.l" +case 28: +/* rule 28 can match eol */ +YY_RULE_SETUP +#line 491 "pgc.l" +{ + yyless(1); + BEGIN(state_before); + yylval.str = mm_strdup(literalbuf); + return NCONST; + } + YY_BREAK +case 29: +/* rule 29 can match eol */ +YY_RULE_SETUP +#line 497 "pgc.l" +{ + addlit(yytext, yyleng); + BEGIN(state_before); + yylval.str = mm_strdup(literalbuf); + return UCONST; + } + YY_BREAK +case 30: +YY_RULE_SETUP +#line 503 "pgc.l" +{ addlitchar('\''); } + YY_BREAK +case 31: +YY_RULE_SETUP +#line 504 "pgc.l" +{ + addlitchar('\\'); + addlitchar('\''); + } + YY_BREAK +case 32: +/* rule 32 can match eol */ +YY_RULE_SETUP +#line 508 "pgc.l" +{ addlit(yytext, yyleng); } + YY_BREAK +case 33: +/* rule 33 can match eol */ +YY_RULE_SETUP +#line 509 "pgc.l" +{ addlit(yytext, yyleng); } + YY_BREAK +case 34: +YY_RULE_SETUP +#line 510 "pgc.l" +{ addlit(yytext, yyleng); } + YY_BREAK +case 35: +/* rule 35 can match eol */ +YY_RULE_SETUP +#line 511 "pgc.l" +{ addlit(yytext, yyleng); } + YY_BREAK +case 36: +YY_RULE_SETUP +#line 512 "pgc.l" +{ addlit(yytext, yyleng); } + YY_BREAK +case 37: +YY_RULE_SETUP +#line 513 "pgc.l" +{ addlit(yytext, yyleng); } + YY_BREAK +case 38: +/* rule 38 can match eol */ +YY_RULE_SETUP +#line 514 "pgc.l" +{ /* ignore */ } + YY_BREAK +case 39: +YY_RULE_SETUP +#line 515 "pgc.l" +{ + /* This is only needed for \ just before EOF */ + addlitchar(yytext[0]); + } + YY_BREAK +case YY_STATE_EOF(xq): +case YY_STATE_EOF(xqc): +case YY_STATE_EOF(xe): +case YY_STATE_EOF(xn): +case YY_STATE_EOF(xus): +#line 519 "pgc.l" +{ mmerror(PARSE_ERROR, ET_FATAL, "unterminated quoted string"); } + YY_BREAK +case 40: +YY_RULE_SETUP +#line 520 "pgc.l" +{ + /* throw back all but the initial "$" */ + yyless(1); + /* and treat it as {other} */ + return yytext[0]; + } + YY_BREAK +case 41: +YY_RULE_SETUP +#line 526 "pgc.l" +{ + token_start = yytext; + dolqstart = mm_strdup(yytext); + BEGIN(xdolq); + startlit(); + addlit(yytext, yyleng); + } + YY_BREAK +case 42: +YY_RULE_SETUP +#line 533 "pgc.l" +{ + if (strcmp(yytext, dolqstart) == 0) + { + addlit(yytext, yyleng); + free(dolqstart); + BEGIN(SQL); + yylval.str = mm_strdup(literalbuf); + return DOLCONST; + } + else + { + /* + * When we fail to match $...$ to dolqstart, transfer + * the $... part to the output, but put back the final + * $ for rescanning. Consider $delim$...$junk$delim$ + */ + addlit(yytext, yyleng-1); + yyless(yyleng-1); + } + } + YY_BREAK +case 43: +/* rule 43 can match eol */ +YY_RULE_SETUP +#line 553 "pgc.l" +{ addlit(yytext, yyleng); } + YY_BREAK +case 44: +YY_RULE_SETUP +#line 554 "pgc.l" +{ addlit(yytext, yyleng); } + YY_BREAK +case 45: +YY_RULE_SETUP +#line 555 "pgc.l" +{ + /* single quote or dollar sign */ + addlitchar(yytext[0]); + } + YY_BREAK +case YY_STATE_EOF(xdolq): +#line 559 "pgc.l" +{ base_yyerror("unterminated dollar-quoted string"); } + YY_BREAK +case 46: +YY_RULE_SETUP +#line 560 "pgc.l" +{ + state_before = YYSTATE; + BEGIN(xd); + startlit(); + } + YY_BREAK +case 47: +YY_RULE_SETUP +#line 565 "pgc.l" +{ + state_before = YYSTATE; + BEGIN(xui); + startlit(); + addlit(yytext, yyleng); + } + YY_BREAK +case 48: +YY_RULE_SETUP +#line 571 "pgc.l" +{ + BEGIN(state_before); + if (literallen == 0) + mmerror(PARSE_ERROR, ET_ERROR, "zero-length delimited identifier"); + /* The backend will truncate the identifier here. We do not as it does not change the result. */ + yylval.str = mm_strdup(literalbuf); + return CSTRING; + } + YY_BREAK +case 49: +YY_RULE_SETUP +#line 579 "pgc.l" +{ + BEGIN(state_before); + yylval.str = mm_strdup(literalbuf); + return CSTRING; + } + YY_BREAK +case 50: +/* rule 50 can match eol */ +YY_RULE_SETUP +#line 584 "pgc.l" +{ + BEGIN(state_before); + if (literallen == 2) /* "U&" */ + mmerror(PARSE_ERROR, ET_ERROR, "zero-length delimited identifier"); + /* The backend will truncate the identifier here. We do not as it does not change the result. */ + addlit(yytext, yyleng); + yylval.str = mm_strdup(literalbuf); + return UIDENT; + } + YY_BREAK +case 51: +YY_RULE_SETUP +#line 593 "pgc.l" +{ addlitchar('"'); } + YY_BREAK +case 52: +/* rule 52 can match eol */ +YY_RULE_SETUP +#line 594 "pgc.l" +{ addlit(yytext, yyleng); } + YY_BREAK +case YY_STATE_EOF(xd): +case YY_STATE_EOF(xdc): +case YY_STATE_EOF(xui): +#line 595 "pgc.l" +{ mmerror(PARSE_ERROR, ET_FATAL, "unterminated quoted identifier"); } + YY_BREAK +case 53: +YY_RULE_SETUP +#line 596 "pgc.l" +{ + state_before = YYSTATE; + BEGIN(xdc); + startlit(); + } + YY_BREAK +case 54: +/* rule 54 can match eol */ +YY_RULE_SETUP +#line 601 "pgc.l" +{ addlit(yytext, yyleng); } + YY_BREAK +case 55: +YY_RULE_SETUP +#line 602 "pgc.l" +{ return TYPECAST; } + YY_BREAK +case 56: +YY_RULE_SETUP +#line 603 "pgc.l" +{ return DOT_DOT; } + YY_BREAK +case 57: +YY_RULE_SETUP +#line 604 "pgc.l" +{ return COLON_EQUALS; } + YY_BREAK +case 58: +YY_RULE_SETUP +#line 605 "pgc.l" +{ + /* are we simulating Informix? */ + if (INFORMIX_MODE) + { + unput(':'); + } + else + return yytext[0]; + } + YY_BREAK +case 59: +YY_RULE_SETUP +#line 614 "pgc.l" +{ /* + * We may find a ';' inside a structure + * definition in a TYPE or VAR statement. + * This is not an EOL marker. + */ + if (yytext[0] == ';' && struct_level == 0) + BEGIN(C); + return yytext[0]; + } + YY_BREAK +case 60: +YY_RULE_SETUP +#line 623 "pgc.l" +{ + /* + * Check for embedded slash-star or dash-dash; those + * are comment starts, so operator must stop there. + * Note that slash-star or dash-dash at the first + * character will match a prior rule, not this one. + */ + int nchars = yyleng; + char *slashstar = strstr(yytext, "/*"); + char *dashdash = strstr(yytext, "--"); + + if (slashstar && dashdash) + { + /* if both appear, take the first one */ + if (slashstar > dashdash) + slashstar = dashdash; + } + else if (!slashstar) + slashstar = dashdash; + if (slashstar) + nchars = slashstar - yytext; + + /* + * For SQL compatibility, '+' and '-' cannot be the + * last char of a multi-char operator unless the operator + * contains chars that are not in SQL operators. + * The idea is to lex '=-' as two operators, but not + * to forbid operator names like '?-' that could not be + * sequences of SQL operators. + */ + while (nchars > 1 && + (yytext[nchars-1] == '+' || + yytext[nchars-1] == '-')) + { + int ic; + + for (ic = nchars-2; ic >= 0; ic--) + { + if (strchr("~!@#^&|`?%", yytext[ic])) + break; + } + if (ic >= 0) + break; /* found a char that makes it OK */ + nchars--; /* else remove the +/-, and check again */ + } + + if (nchars < yyleng) + { + /* Strip the unwanted chars from the token */ + yyless(nchars); + /* + * If what we have left is only one char, and it's + * one of the characters matching "self", then + * return it as a character token the same way + * that the "self" rule would have. + */ + if (nchars == 1 && + strchr(",()[].;:+-*/%^<>=", yytext[0])) + return yytext[0]; + } + + /* Convert "!=" operator to "<>" for compatibility */ + if (strcmp(yytext, "!=") == 0) + yylval.str = mm_strdup("<>"); + else + yylval.str = mm_strdup(yytext); + return Op; + } + YY_BREAK +case 61: +YY_RULE_SETUP +#line 691 "pgc.l" +{ + yylval.ival = atol(yytext+1); + return PARAM; + } + YY_BREAK +case 62: +YY_RULE_SETUP +#line 695 "pgc.l" +{ + long val; + char* endptr; + + errno = 0; + val = strtol((char *)yytext, &endptr,10); + if (*endptr != '\0' || errno == ERANGE +#ifdef HAVE_LONG_INT_64 + /* if long > 32 bits, check for overflow of int4 */ + || val != (long) ((int32) val) +#endif + ) + { + errno = 0; + yylval.str = mm_strdup(yytext); + return FCONST; + } + yylval.ival = val; + return ICONST; + } + YY_BREAK +case 63: +YY_RULE_SETUP +#line 715 "pgc.l" +{ + yylval.str = mm_strdup(yytext); + return IP; + } + YY_BREAK +case 64: +YY_RULE_SETUP +#line 719 "pgc.l" +{ + yylval.str = mm_strdup(yytext); + return FCONST; + } + YY_BREAK +case 65: +YY_RULE_SETUP +#line 723 "pgc.l" +{ + yylval.str = mm_strdup(yytext); + return FCONST; + } + YY_BREAK +case 66: +YY_RULE_SETUP +#line 727 "pgc.l" +{ + yyless(yyleng-1); + yylval.str = mm_strdup(yytext); + return FCONST; + } + YY_BREAK +case 67: +YY_RULE_SETUP +#line 732 "pgc.l" +{ + yyless(yyleng-2); + yylval.str = mm_strdup(yytext); + return FCONST; + } + YY_BREAK +case 68: +/* rule 68 can match eol */ +YY_RULE_SETUP +#line 737 "pgc.l" +{ + yylval.str = mm_strdup(yytext+1); + return(CVARIABLE); + } + YY_BREAK +case 69: +YY_RULE_SETUP +#line 741 "pgc.l" +{ + const ScanKeyword *keyword; + + if (!isdefine()) + { + /* Is it an SQL/ECPG keyword? */ + keyword = ScanECPGKeywordLookup(yytext); + if (keyword != NULL) + return keyword->value; + + /* Is it a C keyword? */ + keyword = ScanCKeywordLookup(yytext); + if (keyword != NULL) + return keyword->value; + + /* + * None of the above. Return it as an identifier. + * + * The backend will attempt to truncate and case-fold + * the identifier, but I see no good reason for ecpg + * to do so; that's just another way that ecpg could get + * out of step with the backend. + */ + yylval.str = mm_strdup(yytext); + return IDENT; + } + } + YY_BREAK +case 70: +YY_RULE_SETUP +#line 768 "pgc.l" +{ return yytext[0]; } + YY_BREAK +case 71: +/* rule 71 can match eol */ +YY_RULE_SETUP +#line 769 "pgc.l" +{ BEGIN(SQL); return SQL_START; } + YY_BREAK +case 72: +YY_RULE_SETUP +#line 770 "pgc.l" +{ + /* are we simulating Informix? */ + if (INFORMIX_MODE) + { + BEGIN(SQL); + return SQL_START; + } + else + return S_ANYTHING; + } + YY_BREAK +case 73: +/* rule 73 can match eol */ +YY_RULE_SETUP +#line 780 "pgc.l" +{ ECHO; } + YY_BREAK +case 74: +YY_RULE_SETUP +#line 781 "pgc.l" +{ + char* endptr; + + errno = 0; + yylval.ival = strtoul((char *)yytext,&endptr,16); + if (*endptr != '\0' || errno == ERANGE) + { + errno = 0; + yylval.str = mm_strdup(yytext); + return SCONST; + } + return ICONST; + } + YY_BREAK +case 75: +/* rule 75 can match eol */ +YY_RULE_SETUP +#line 794 "pgc.l" +{ + if (system_includes) + { + include_next = false; + BEGIN(incl); + } + else + { + yylval.str = mm_strdup(yytext); + return(CPP_LINE); + } + } + YY_BREAK +case 76: +/* rule 76 can match eol */ +YY_RULE_SETUP +#line 806 "pgc.l" +{ + if (system_includes) + { + include_next = true; + BEGIN(incl); + } + else + { + yylval.str = mm_strdup(yytext); + return(CPP_LINE); + } + } + YY_BREAK +case 77: +/* rule 77 can match eol */ +YY_RULE_SETUP +#line 818 "pgc.l" +{ + yylval.str = mm_strdup(yytext); + return(CPP_LINE); + } + YY_BREAK +case 78: +YY_RULE_SETUP +#line 822 "pgc.l" +{ + const ScanKeyword *keyword; + + /* + * Try to detect a function name: + * look for identifiers at the global scope + * keep the last identifier before the first '(' and '{' */ + if (braces_open == 0 && parenths_open == 0) + { + if (current_function) + free(current_function); + current_function = mm_strdup(yytext); + } + /* Informix uses SQL defines only in SQL space */ + /* however, some defines have to be taken care of for compatibility */ + if ((!INFORMIX_MODE || !isinformixdefine()) && !isdefine()) + { + keyword = ScanCKeywordLookup(yytext); + if (keyword != NULL) + return keyword->value; + else + { + yylval.str = mm_strdup(yytext); + return IDENT; + } + } + } + YY_BREAK +case 79: +YY_RULE_SETUP +#line 849 "pgc.l" +{ return(':'); } + YY_BREAK +case 80: +YY_RULE_SETUP +#line 850 "pgc.l" +{ return(';'); } + YY_BREAK +case 81: +YY_RULE_SETUP +#line 851 "pgc.l" +{ return(','); } + YY_BREAK +case 82: +YY_RULE_SETUP +#line 852 "pgc.l" +{ return('*'); } + YY_BREAK +case 83: +YY_RULE_SETUP +#line 853 "pgc.l" +{ return('%'); } + YY_BREAK +case 84: +YY_RULE_SETUP +#line 854 "pgc.l" +{ return('/'); } + YY_BREAK +case 85: +YY_RULE_SETUP +#line 855 "pgc.l" +{ return('+'); } + YY_BREAK +case 86: +YY_RULE_SETUP +#line 856 "pgc.l" +{ return('-'); } + YY_BREAK +case 87: +YY_RULE_SETUP +#line 857 "pgc.l" +{ parenths_open++; return('('); } + YY_BREAK +case 88: +YY_RULE_SETUP +#line 858 "pgc.l" +{ parenths_open--; return(')'); } + YY_BREAK +case 89: +/* rule 89 can match eol */ +YY_RULE_SETUP +#line 859 "pgc.l" +{ ECHO; } + YY_BREAK +case 90: +YY_RULE_SETUP +#line 860 "pgc.l" +{ return('{'); } + YY_BREAK +case 91: +YY_RULE_SETUP +#line 861 "pgc.l" +{ return('}'); } + YY_BREAK +case 92: +YY_RULE_SETUP +#line 862 "pgc.l" +{ return('['); } + YY_BREAK +case 93: +YY_RULE_SETUP +#line 863 "pgc.l" +{ return(']'); } + YY_BREAK +case 94: +YY_RULE_SETUP +#line 864 "pgc.l" +{ return('='); } + YY_BREAK +case 95: +YY_RULE_SETUP +#line 865 "pgc.l" +{ return(S_MEMBER); } + YY_BREAK +case 96: +YY_RULE_SETUP +#line 866 "pgc.l" +{ return(S_RSHIFT); } + YY_BREAK +case 97: +YY_RULE_SETUP +#line 867 "pgc.l" +{ return(S_LSHIFT); } + YY_BREAK +case 98: +YY_RULE_SETUP +#line 868 "pgc.l" +{ return(S_OR); } + YY_BREAK +case 99: +YY_RULE_SETUP +#line 869 "pgc.l" +{ return(S_AND); } + YY_BREAK +case 100: +YY_RULE_SETUP +#line 870 "pgc.l" +{ return(S_INC); } + YY_BREAK +case 101: +YY_RULE_SETUP +#line 871 "pgc.l" +{ return(S_DEC); } + YY_BREAK +case 102: +YY_RULE_SETUP +#line 872 "pgc.l" +{ return(S_EQUAL); } + YY_BREAK +case 103: +YY_RULE_SETUP +#line 873 "pgc.l" +{ return(S_NEQUAL); } + YY_BREAK +case 104: +YY_RULE_SETUP +#line 874 "pgc.l" +{ return(S_ADD); } + YY_BREAK +case 105: +YY_RULE_SETUP +#line 875 "pgc.l" +{ return(S_SUB); } + YY_BREAK +case 106: +YY_RULE_SETUP +#line 876 "pgc.l" +{ return(S_MUL); } + YY_BREAK +case 107: +YY_RULE_SETUP +#line 877 "pgc.l" +{ return(S_DIV); } + YY_BREAK +case 108: +YY_RULE_SETUP +#line 878 "pgc.l" +{ return(S_MOD); } + YY_BREAK +case 109: +YY_RULE_SETUP +#line 879 "pgc.l" +{ return(S_MEMPOINT); } + YY_BREAK +case 110: +YY_RULE_SETUP +#line 880 "pgc.l" +{ return(S_DOTPOINT); } + YY_BREAK +case 111: +YY_RULE_SETUP +#line 881 "pgc.l" +{ return S_ANYTHING; } + YY_BREAK +case 112: +/* rule 112 can match eol */ +YY_RULE_SETUP +#line 882 "pgc.l" +{ BEGIN(def_ident); } + YY_BREAK +case 113: +/* rule 113 can match eol */ +YY_RULE_SETUP +#line 883 "pgc.l" +{ + /* are we simulating Informix? */ + if (INFORMIX_MODE) + { + BEGIN(def_ident); + } + else + { + yyless(1); + return (S_ANYTHING); + } + } + YY_BREAK +case 114: +/* rule 114 can match eol */ +YY_RULE_SETUP +#line 895 "pgc.l" +{ BEGIN(undef); } + YY_BREAK +case 115: +/* rule 115 can match eol */ +YY_RULE_SETUP +#line 896 "pgc.l" +{ + /* are we simulating Informix? */ + if (INFORMIX_MODE) + { + BEGIN(undef); + } + else + { + yyless(1); + return (S_ANYTHING); + } + } + YY_BREAK +case 116: +/* rule 116 can match eol */ +YY_RULE_SETUP +#line 908 "pgc.l" +{ + struct _defines *ptr, *ptr2 = NULL; + int i; + + /* + * Skip the ";" and trailing whitespace. Note that yytext + * contains at least one non-space character plus the ";" + */ + for (i = strlen(yytext)-2; + i > 0 && ecpg_isspace(yytext[i]); + i-- ) + ; + yytext[i+1] = '\0'; + + + for (ptr = defines; ptr != NULL; ptr2 = ptr, ptr = ptr->next) + { + if (strcmp(yytext, ptr->old) == 0) + { + if (ptr2 == NULL) + defines = ptr->next; + else + ptr2->next = ptr->next; + free(ptr->new); + free(ptr->old); + free(ptr); + break; + } + } + + BEGIN(C); + } + YY_BREAK +case 117: +/* rule 117 can match eol */ +YY_RULE_SETUP +#line 940 "pgc.l" +{ + mmerror(PARSE_ERROR, ET_FATAL, "missing identifier in EXEC SQL UNDEF command"); + yyterminate(); + } + YY_BREAK +case 118: +/* rule 118 can match eol */ +YY_RULE_SETUP +#line 944 "pgc.l" +{ BEGIN(incl); } + YY_BREAK +case 119: +/* rule 119 can match eol */ +YY_RULE_SETUP +#line 945 "pgc.l" +{ + /* are we simulating Informix? */ + if (INFORMIX_MODE) + { + BEGIN(incl); + } + else + { + yyless(1); + return (S_ANYTHING); + } + } + YY_BREAK +case 120: +/* rule 120 can match eol */ +YY_RULE_SETUP +#line 957 "pgc.l" +{ ifcond = TRUE; BEGIN(xcond); } + YY_BREAK +case 121: +/* rule 121 can match eol */ +YY_RULE_SETUP +#line 958 "pgc.l" +{ + /* are we simulating Informix? */ + if (INFORMIX_MODE) + { + ifcond = TRUE; + BEGIN(xcond); + } + else + { + yyless(1); + return (S_ANYTHING); + } + } + YY_BREAK +case 122: +/* rule 122 can match eol */ +YY_RULE_SETUP +#line 971 "pgc.l" +{ ifcond = FALSE; BEGIN(xcond); } + YY_BREAK +case 123: +/* rule 123 can match eol */ +YY_RULE_SETUP +#line 972 "pgc.l" +{ + /* are we simulating Informix? */ + if (INFORMIX_MODE) + { + ifcond = FALSE; + BEGIN(xcond); + } + else + { + yyless(1); + return (S_ANYTHING); + } + } + YY_BREAK +case 124: +/* rule 124 can match eol */ +YY_RULE_SETUP +#line 985 "pgc.l" +{ /* pop stack */ + if ( preproc_tos == 0 ) { + mmerror(PARSE_ERROR, ET_FATAL, "missing matching \"EXEC SQL IFDEF\" / \"EXEC SQL IFNDEF\""); + } + else if ( stacked_if_value[preproc_tos].else_branch ) + mmerror(PARSE_ERROR, ET_FATAL, "missing \"EXEC SQL ENDIF;\""); + else + preproc_tos--; + + ifcond = TRUE; BEGIN(xcond); + } + YY_BREAK +case 125: +/* rule 125 can match eol */ +YY_RULE_SETUP +#line 996 "pgc.l" +{ + /* are we simulating Informix? */ + if (INFORMIX_MODE) + { + if (preproc_tos == 0) + mmerror(PARSE_ERROR, ET_FATAL, "missing matching \"EXEC SQL IFDEF\" / \"EXEC SQL IFNDEF\""); + else if (stacked_if_value[preproc_tos].else_branch) + mmerror(PARSE_ERROR, ET_FATAL, "missing \"EXEC SQL ENDIF;\""); + else + preproc_tos--; + + ifcond = TRUE; + BEGIN(xcond); + } + else + { + yyless(1); + return (S_ANYTHING); + } + } + YY_BREAK +case 126: +/* rule 126 can match eol */ +YY_RULE_SETUP +#line 1017 "pgc.l" +{ /* only exec sql endif pops the stack, so take care of duplicated 'else' */ + if (stacked_if_value[preproc_tos].else_branch) + mmerror(PARSE_ERROR, ET_FATAL, "more than one EXEC SQL ELSE"); + else + { + stacked_if_value[preproc_tos].else_branch = TRUE; + stacked_if_value[preproc_tos].condition = + (stacked_if_value[preproc_tos-1].condition && + !stacked_if_value[preproc_tos].condition); + + if (stacked_if_value[preproc_tos].condition) + BEGIN(C); + else + BEGIN(xskip); + } + } + YY_BREAK +case 127: +/* rule 127 can match eol */ +YY_RULE_SETUP +#line 1033 "pgc.l" +{ + /* are we simulating Informix? */ + if (INFORMIX_MODE) + { + if (stacked_if_value[preproc_tos].else_branch) + mmerror(PARSE_ERROR, ET_FATAL, "more than one EXEC SQL ELSE"); + else + { + stacked_if_value[preproc_tos].else_branch = TRUE; + stacked_if_value[preproc_tos].condition = + (stacked_if_value[preproc_tos-1].condition && + !stacked_if_value[preproc_tos].condition); + + if (stacked_if_value[preproc_tos].condition) + BEGIN(C); + else + BEGIN(xskip); + } + } + else + { + yyless(1); + return (S_ANYTHING); + } + } + YY_BREAK +case 128: +/* rule 128 can match eol */ +YY_RULE_SETUP +#line 1058 "pgc.l" +{ + if (preproc_tos == 0) + mmerror(PARSE_ERROR, ET_FATAL, "unmatched EXEC SQL ENDIF"); + else + preproc_tos--; + + if (stacked_if_value[preproc_tos].condition) + BEGIN(C); + else + BEGIN(xskip); + } + YY_BREAK +case 129: +/* rule 129 can match eol */ +YY_RULE_SETUP +#line 1069 "pgc.l" +{ + /* are we simulating Informix? */ + if (INFORMIX_MODE) + { + if (preproc_tos == 0) + mmerror(PARSE_ERROR, ET_FATAL, "unmatched EXEC SQL ENDIF"); + else + preproc_tos--; + + if (stacked_if_value[preproc_tos].condition) + BEGIN(C); + else + BEGIN(xskip); + } + else + { + yyless(1); + return (S_ANYTHING); + } + } + YY_BREAK +case 130: +YY_RULE_SETUP +#line 1090 "pgc.l" +{ /* ignore */ } + YY_BREAK +case 131: +/* rule 131 can match eol */ +YY_RULE_SETUP +#line 1092 "pgc.l" +{ + if (preproc_tos >= MAX_NESTED_IF-1) + mmerror(PARSE_ERROR, ET_FATAL, "too many nested EXEC SQL IFDEF conditions"); + else + { + struct _defines *defptr; + unsigned int i; + + /* + * Skip the ";" and trailing whitespace. Note that yytext + * contains at least one non-space character plus the ";" + */ + for (i = strlen(yytext)-2; + i > 0 && ecpg_isspace(yytext[i]); + i-- ) + ; + yytext[i+1] = '\0'; + + for (defptr = defines; + defptr != NULL && strcmp(yytext, defptr->old) != 0; + defptr = defptr->next); + + preproc_tos++; + stacked_if_value[preproc_tos].else_branch = FALSE; + stacked_if_value[preproc_tos].condition = + (defptr ? ifcond : !ifcond) && stacked_if_value[preproc_tos-1].condition; + } + + if (stacked_if_value[preproc_tos].condition) + BEGIN(C); + else + BEGIN(xskip); + } + YY_BREAK +case 132: +/* rule 132 can match eol */ +YY_RULE_SETUP +#line 1126 "pgc.l" +{ + mmerror(PARSE_ERROR, ET_FATAL, "missing identifier in EXEC SQL IFDEF command"); + yyterminate(); + } + YY_BREAK +case 133: +YY_RULE_SETUP +#line 1130 "pgc.l" +{ + old = mm_strdup(yytext); + BEGIN(def); + startlit(); + } + YY_BREAK +case 134: +/* rule 134 can match eol */ +YY_RULE_SETUP +#line 1135 "pgc.l" +{ + mmerror(PARSE_ERROR, ET_FATAL, "missing identifier in EXEC SQL DEFINE command"); + yyterminate(); + } + YY_BREAK +case 135: +/* rule 135 can match eol */ +YY_RULE_SETUP +#line 1139 "pgc.l" +{ + struct _defines *ptr, *this; + + for (ptr = defines; ptr != NULL; ptr = ptr->next) + { + if (strcmp(old, ptr->old) == 0) + { + free(ptr->new); + ptr->new = mm_strdup(literalbuf); + } + } + if (ptr == NULL) + { + this = (struct _defines *) mm_alloc(sizeof(struct _defines)); + + /* initial definition */ + this->old = old; + this->new = mm_strdup(literalbuf); + this->next = defines; + this->used = NULL; + defines = this; + } + + BEGIN(C); + } + YY_BREAK +case 136: +/* rule 136 can match eol */ +YY_RULE_SETUP +#line 1164 "pgc.l" +{ addlit(yytext, yyleng); } + YY_BREAK +case 137: +/* rule 137 can match eol */ +YY_RULE_SETUP +#line 1165 "pgc.l" +{ parse_include(); } + YY_BREAK +case 138: +/* rule 138 can match eol */ +YY_RULE_SETUP +#line 1166 "pgc.l" +{ parse_include(); } + YY_BREAK +case 139: +/* rule 139 can match eol */ +YY_RULE_SETUP +#line 1167 "pgc.l" +{ parse_include(); } + YY_BREAK +case 140: +/* rule 140 can match eol */ +YY_RULE_SETUP +#line 1168 "pgc.l" +{ + mmerror(PARSE_ERROR, ET_FATAL, "syntax error in EXEC SQL INCLUDE command"); + yyterminate(); + } + YY_BREAK +case YY_STATE_EOF(INITIAL): +case YY_STATE_EOF(C): +case YY_STATE_EOF(SQL): +case YY_STATE_EOF(incl): +case YY_STATE_EOF(def): +case YY_STATE_EOF(def_ident): +case YY_STATE_EOF(undef): +case YY_STATE_EOF(xcond): +case YY_STATE_EOF(xskip): +#line 1173 "pgc.l" +{ + if (yy_buffer == NULL) + { + if ( preproc_tos > 0 ) + { + preproc_tos = 0; + mmerror(PARSE_ERROR, ET_FATAL, "missing \"EXEC SQL ENDIF;\""); + } + yyterminate(); + } + else + { + struct _yy_buffer *yb = yy_buffer; + int i; + struct _defines *ptr; + + for (ptr = defines; ptr; ptr = ptr->next) + if (ptr->used == yy_buffer) + { + ptr->used = NULL; + break; + } + + if (yyin != NULL) + fclose(yyin); + + yy_delete_buffer(YY_CURRENT_BUFFER ); + yy_switch_to_buffer(yy_buffer->buffer); + + yylineno = yy_buffer->lineno; + + /* We have to output the filename only if we change files here */ + i = strcmp(input_filename, yy_buffer->filename); + + free(input_filename); + input_filename = yy_buffer->filename; + + yy_buffer = yy_buffer->next; + free(yb); + + if (i != 0) + output_line_number(); + + } + } + YY_BREAK +case 141: +/* rule 141 can match eol */ +YY_RULE_SETUP +#line 1218 "pgc.l" +{ mmerror(PARSE_ERROR, ET_FATAL, "internal error: unreachable state; please report this to "); } + YY_BREAK +case 142: +YY_RULE_SETUP +#line 1219 "pgc.l" +YY_FATAL_ERROR( "flex scanner jammed" ); + YY_BREAK +#line 3884 "pgc.c" + + case YY_END_OF_BUFFER: + { + /* Amount of text matched not including the EOB char. */ + int yy_amount_of_matched_text = (int) (yy_cp - (yytext_ptr)) - 1; + + /* Undo the effects of YY_DO_BEFORE_ACTION. */ + *yy_cp = (yy_hold_char); + YY_RESTORE_YY_MORE_OFFSET + + if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW ) + { + /* We're scanning a new file or input source. It's + * possible that this happened because the user + * just pointed yyin at a new source and called + * yylex(). If so, then we have to assure + * consistency between YY_CURRENT_BUFFER and our + * globals. Here is the right place to do so, because + * this is the first action (other than possibly a + * back-up) that will match for the new input source. + */ + (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars; + YY_CURRENT_BUFFER_LVALUE->yy_input_file = yyin; + YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL; + } + + /* Note that here we test for yy_c_buf_p "<=" to the position + * of the first EOB in the buffer, since yy_c_buf_p will + * already have been incremented past the NUL character + * (since all states make transitions on EOB to the + * end-of-buffer state). Contrast this with the test + * in input(). + */ + if ( (yy_c_buf_p) <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] ) + { /* This was really a NUL. */ + yy_state_type yy_next_state; + + (yy_c_buf_p) = (yytext_ptr) + yy_amount_of_matched_text; + + yy_current_state = yy_get_previous_state( ); + + /* Okay, we're now positioned to make the NUL + * transition. We couldn't have + * yy_get_previous_state() go ahead and do it + * for us because it doesn't know how to deal + * with the possibility of jamming (and we don't + * want to build jamming into it because then it + * will run more slowly). + */ + + yy_next_state = yy_try_NUL_trans( yy_current_state ); + + yy_bp = (yytext_ptr) + YY_MORE_ADJ; + + if ( yy_next_state ) + { + /* Consume the NUL. */ + yy_cp = ++(yy_c_buf_p); + yy_current_state = yy_next_state; + goto yy_match; + } + + else + { + yy_cp = (yy_last_accepting_cpos); + yy_current_state = (yy_last_accepting_state); + goto yy_find_action; + } + } + + else switch ( yy_get_next_buffer( ) ) + { + case EOB_ACT_END_OF_FILE: + { + (yy_did_buffer_switch_on_eof) = 0; + + if ( yywrap( ) ) + { + /* Note: because we've taken care in + * yy_get_next_buffer() to have set up + * yytext, we can now set up + * yy_c_buf_p so that if some total + * hoser (like flex itself) wants to + * call the scanner after we return the + * YY_NULL, it'll still work - another + * YY_NULL will get returned. + */ + (yy_c_buf_p) = (yytext_ptr) + YY_MORE_ADJ; + + yy_act = YY_STATE_EOF(YY_START); + goto do_action; + } + + else + { + if ( ! (yy_did_buffer_switch_on_eof) ) + YY_NEW_FILE; + } + break; + } + + case EOB_ACT_CONTINUE_SCAN: + (yy_c_buf_p) = + (yytext_ptr) + yy_amount_of_matched_text; + + yy_current_state = yy_get_previous_state( ); + + yy_cp = (yy_c_buf_p); + yy_bp = (yytext_ptr) + YY_MORE_ADJ; + goto yy_match; + + case EOB_ACT_LAST_MATCH: + (yy_c_buf_p) = + &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)]; + + yy_current_state = yy_get_previous_state( ); + + yy_cp = (yy_c_buf_p); + yy_bp = (yytext_ptr) + YY_MORE_ADJ; + goto yy_find_action; + } + break; + } + + default: + YY_FATAL_ERROR( + "fatal flex scanner internal error--no action found" ); + } /* end of action switch */ + } /* end of scanning one token */ +} /* end of yylex */ + +/* yy_get_next_buffer - try to read in a new buffer + * + * Returns a code representing an action: + * EOB_ACT_LAST_MATCH - + * EOB_ACT_CONTINUE_SCAN - continue scanning from current position + * EOB_ACT_END_OF_FILE - end of file + */ +static int yy_get_next_buffer (void) +{ + register char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf; + register char *source = (yytext_ptr); + register int number_to_move, i; + int ret_val; + + if ( (yy_c_buf_p) > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] ) + YY_FATAL_ERROR( + "fatal flex scanner internal error--end of buffer missed" ); + + if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 ) + { /* Don't try to fill the buffer, so this is an EOF. */ + if ( (yy_c_buf_p) - (yytext_ptr) - YY_MORE_ADJ == 1 ) + { + /* We matched a single character, the EOB, so + * treat this as a final EOF. + */ + return EOB_ACT_END_OF_FILE; + } + + else + { + /* We matched some text prior to the EOB, first + * process it. + */ + return EOB_ACT_LAST_MATCH; + } + } + + /* Try to read more data. */ + + /* First move last chars to start of buffer. */ + number_to_move = (int) ((yy_c_buf_p) - (yytext_ptr)) - 1; + + for ( i = 0; i < number_to_move; ++i ) + *(dest++) = *(source++); + + if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING ) + /* don't do the read, it's not guaranteed to return an EOF, + * just force an EOF + */ + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars) = 0; + + else + { + int num_to_read = + YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1; + + while ( num_to_read <= 0 ) + { /* Not enough room in the buffer - grow it. */ + + /* just a shorter name for the current buffer */ + YY_BUFFER_STATE b = YY_CURRENT_BUFFER; + + int yy_c_buf_p_offset = + (int) ((yy_c_buf_p) - b->yy_ch_buf); + + if ( b->yy_is_our_buffer ) + { + int new_size = b->yy_buf_size * 2; + + if ( new_size <= 0 ) + b->yy_buf_size += b->yy_buf_size / 8; + else + b->yy_buf_size *= 2; + + b->yy_ch_buf = (char *) + /* Include room in for 2 EOB chars. */ + yyrealloc((void *) b->yy_ch_buf,b->yy_buf_size + 2 ); + } + else + /* Can't grow it, we don't own it. */ + b->yy_ch_buf = 0; + + if ( ! b->yy_ch_buf ) + YY_FATAL_ERROR( + "fatal error - scanner input buffer overflow" ); + + (yy_c_buf_p) = &b->yy_ch_buf[yy_c_buf_p_offset]; + + num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size - + number_to_move - 1; + + } + + if ( num_to_read > YY_READ_BUF_SIZE ) + num_to_read = YY_READ_BUF_SIZE; + + /* Read in more data. */ + YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]), + (yy_n_chars), (size_t) num_to_read ); + + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); + } + + if ( (yy_n_chars) == 0 ) + { + if ( number_to_move == YY_MORE_ADJ ) + { + ret_val = EOB_ACT_END_OF_FILE; + yyrestart(yyin ); + } + + else + { + ret_val = EOB_ACT_LAST_MATCH; + YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = + YY_BUFFER_EOF_PENDING; + } + } + + else + ret_val = EOB_ACT_CONTINUE_SCAN; + + if ((yy_size_t) ((yy_n_chars) + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) { + /* Extend the array by 50%, plus the number we really need. */ + yy_size_t new_size = (yy_n_chars) + number_to_move + ((yy_n_chars) >> 1); + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) yyrealloc((void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,new_size ); + if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf ) + YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" ); + } + + (yy_n_chars) += number_to_move; + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] = YY_END_OF_BUFFER_CHAR; + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] = YY_END_OF_BUFFER_CHAR; + + (yytext_ptr) = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0]; + + return ret_val; +} + +/* yy_get_previous_state - get the state just before the EOB char was reached */ + + static yy_state_type yy_get_previous_state (void) +{ + register yy_state_type yy_current_state; + register char *yy_cp; + + yy_current_state = (yy_start); + + for ( yy_cp = (yytext_ptr) + YY_MORE_ADJ; yy_cp < (yy_c_buf_p); ++yy_cp ) + { + register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1); + if ( yy_accept[yy_current_state] ) + { + (yy_last_accepting_state) = yy_current_state; + (yy_last_accepting_cpos) = yy_cp; + } + while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) + { + yy_current_state = (int) yy_def[yy_current_state]; + if ( yy_current_state >= 794 ) + yy_c = yy_meta[(unsigned int) yy_c]; + } + yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; + } + + return yy_current_state; +} + +/* yy_try_NUL_trans - try to make a transition on the NUL character + * + * synopsis + * next_state = yy_try_NUL_trans( current_state ); + */ + static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state ) +{ + register int yy_is_jam; + register char *yy_cp = (yy_c_buf_p); + + register YY_CHAR yy_c = 1; + if ( yy_accept[yy_current_state] ) + { + (yy_last_accepting_state) = yy_current_state; + (yy_last_accepting_cpos) = yy_cp; + } + while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) + { + yy_current_state = (int) yy_def[yy_current_state]; + if ( yy_current_state >= 794 ) + yy_c = yy_meta[(unsigned int) yy_c]; + } + yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; + yy_is_jam = (yy_current_state == 793); + + return yy_is_jam ? 0 : yy_current_state; +} + + static void yyunput (int c, register char * yy_bp ) +{ + register char *yy_cp; + + yy_cp = (yy_c_buf_p); + + /* undo effects of setting up yytext */ + *yy_cp = (yy_hold_char); + + if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 ) + { /* need to shift things up to make room */ + /* +2 for EOB chars. */ + register int number_to_move = (yy_n_chars) + 2; + register char *dest = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[ + YY_CURRENT_BUFFER_LVALUE->yy_buf_size + 2]; + register char *source = + &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]; + + while ( source > YY_CURRENT_BUFFER_LVALUE->yy_ch_buf ) + *--dest = *--source; + + yy_cp += (int) (dest - source); + yy_bp += (int) (dest - source); + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = + (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_buf_size; + + if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 ) + YY_FATAL_ERROR( "flex scanner push-back overflow" ); + } + + *--yy_cp = (char) c; + + if ( c == '\n' ){ + --yylineno; + } + + (yytext_ptr) = yy_bp; + (yy_hold_char) = *yy_cp; + (yy_c_buf_p) = yy_cp; +} + +#ifndef YY_NO_INPUT +#ifdef __cplusplus + static int yyinput (void) +#else + static int input (void) +#endif + +{ + int c; + + *(yy_c_buf_p) = (yy_hold_char); + + if ( *(yy_c_buf_p) == YY_END_OF_BUFFER_CHAR ) + { + /* yy_c_buf_p now points to the character we want to return. + * If this occurs *before* the EOB characters, then it's a + * valid NUL; if not, then we've hit the end of the buffer. + */ + if ( (yy_c_buf_p) < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] ) + /* This was really a NUL. */ + *(yy_c_buf_p) = '\0'; + + else + { /* need more input */ + int offset = (yy_c_buf_p) - (yytext_ptr); + ++(yy_c_buf_p); + + switch ( yy_get_next_buffer( ) ) + { + case EOB_ACT_LAST_MATCH: + /* This happens because yy_g_n_b() + * sees that we've accumulated a + * token and flags that we need to + * try matching the token before + * proceeding. But for input(), + * there's no matching to consider. + * So convert the EOB_ACT_LAST_MATCH + * to EOB_ACT_END_OF_FILE. + */ + + /* Reset buffer status. */ + yyrestart(yyin ); + + /*FALLTHROUGH*/ + + case EOB_ACT_END_OF_FILE: + { + if ( yywrap( ) ) + return EOF; + + if ( ! (yy_did_buffer_switch_on_eof) ) + YY_NEW_FILE; +#ifdef __cplusplus + return yyinput(); +#else + return input(); +#endif + } + + case EOB_ACT_CONTINUE_SCAN: + (yy_c_buf_p) = (yytext_ptr) + offset; + break; + } + } + } + + c = *(unsigned char *) (yy_c_buf_p); /* cast for 8-bit char's */ + *(yy_c_buf_p) = '\0'; /* preserve yytext */ + (yy_hold_char) = *++(yy_c_buf_p); + + if ( c == '\n' ) + + yylineno++; +; + + return c; +} +#endif /* ifndef YY_NO_INPUT */ + +/** Immediately switch to a different input stream. + * @param input_file A readable stream. + * + * @note This function does not reset the start condition to @c INITIAL . + */ + void yyrestart (FILE * input_file ) +{ + + if ( ! YY_CURRENT_BUFFER ){ + yyensure_buffer_stack (); + YY_CURRENT_BUFFER_LVALUE = + yy_create_buffer(yyin,YY_BUF_SIZE ); + } + + yy_init_buffer(YY_CURRENT_BUFFER,input_file ); + yy_load_buffer_state( ); +} + +/** Switch to a different input buffer. + * @param new_buffer The new input buffer. + * + */ + void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer ) +{ + + /* TODO. We should be able to replace this entire function body + * with + * yypop_buffer_state(); + * yypush_buffer_state(new_buffer); + */ + yyensure_buffer_stack (); + if ( YY_CURRENT_BUFFER == new_buffer ) + return; + + if ( YY_CURRENT_BUFFER ) + { + /* Flush out information for old buffer. */ + *(yy_c_buf_p) = (yy_hold_char); + YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p); + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); + } + + YY_CURRENT_BUFFER_LVALUE = new_buffer; + yy_load_buffer_state( ); + + /* We don't actually know whether we did this switch during + * EOF (yywrap()) processing, but the only time this flag + * is looked at is after yywrap() is called, so it's safe + * to go ahead and always set it. + */ + (yy_did_buffer_switch_on_eof) = 1; +} + +static void yy_load_buffer_state (void) +{ + (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars; + (yytext_ptr) = (yy_c_buf_p) = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos; + yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file; + (yy_hold_char) = *(yy_c_buf_p); +} + +/** Allocate and initialize an input buffer state. + * @param file A readable stream. + * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE. + * + * @return the allocated buffer state. + */ + YY_BUFFER_STATE yy_create_buffer (FILE * file, int size ) +{ + YY_BUFFER_STATE b; + + b = (YY_BUFFER_STATE) yyalloc(sizeof( struct yy_buffer_state ) ); + if ( ! b ) + YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" ); + + b->yy_buf_size = size; + + /* yy_ch_buf has to be 2 characters longer than the size given because + * we need to put in 2 end-of-buffer characters. + */ + b->yy_ch_buf = (char *) yyalloc(b->yy_buf_size + 2 ); + if ( ! b->yy_ch_buf ) + YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" ); + + b->yy_is_our_buffer = 1; + + yy_init_buffer(b,file ); + + return b; +} + +/** Destroy the buffer. + * @param b a buffer created with yy_create_buffer() + * + */ + void yy_delete_buffer (YY_BUFFER_STATE b ) +{ + + if ( ! b ) + return; + + if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */ + YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0; + + if ( b->yy_is_our_buffer ) + yyfree((void *) b->yy_ch_buf ); + + yyfree((void *) b ); +} + +/* Initializes or reinitializes a buffer. + * This function is sometimes called more than once on the same buffer, + * such as during a yyrestart() or at EOF. + */ + static void yy_init_buffer (YY_BUFFER_STATE b, FILE * file ) + +{ + int oerrno = errno; + + yy_flush_buffer(b ); + + b->yy_input_file = file; + b->yy_fill_buffer = 1; + + /* If b is the current buffer, then yy_init_buffer was _probably_ + * called from yyrestart() or through yy_get_next_buffer. + * In that case, we don't want to reset the lineno or column. + */ + if (b != YY_CURRENT_BUFFER){ + b->yy_bs_lineno = 1; + b->yy_bs_column = 0; + } + + b->yy_is_interactive = 0; + + errno = oerrno; +} + +/** Discard all buffered characters. On the next scan, YY_INPUT will be called. + * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER. + * + */ + void yy_flush_buffer (YY_BUFFER_STATE b ) +{ + if ( ! b ) + return; + + b->yy_n_chars = 0; + + /* We always need two end-of-buffer characters. The first causes + * a transition to the end-of-buffer state. The second causes + * a jam in that state. + */ + b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR; + b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR; + + b->yy_buf_pos = &b->yy_ch_buf[0]; + + b->yy_at_bol = 1; + b->yy_buffer_status = YY_BUFFER_NEW; + + if ( b == YY_CURRENT_BUFFER ) + yy_load_buffer_state( ); +} + +/** Pushes the new state onto the stack. The new state becomes + * the current state. This function will allocate the stack + * if necessary. + * @param new_buffer The new state. + * + */ +void yypush_buffer_state (YY_BUFFER_STATE new_buffer ) +{ + if (new_buffer == NULL) + return; + + yyensure_buffer_stack(); + + /* This block is copied from yy_switch_to_buffer. */ + if ( YY_CURRENT_BUFFER ) + { + /* Flush out information for old buffer. */ + *(yy_c_buf_p) = (yy_hold_char); + YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p); + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); + } + + /* Only push if top exists. Otherwise, replace top. */ + if (YY_CURRENT_BUFFER) + (yy_buffer_stack_top)++; + YY_CURRENT_BUFFER_LVALUE = new_buffer; + + /* copied from yy_switch_to_buffer. */ + yy_load_buffer_state( ); + (yy_did_buffer_switch_on_eof) = 1; +} + +/** Removes and deletes the top of the stack, if present. + * The next element becomes the new top. + * + */ +void yypop_buffer_state (void) +{ + if (!YY_CURRENT_BUFFER) + return; + + yy_delete_buffer(YY_CURRENT_BUFFER ); + YY_CURRENT_BUFFER_LVALUE = NULL; + if ((yy_buffer_stack_top) > 0) + --(yy_buffer_stack_top); + + if (YY_CURRENT_BUFFER) { + yy_load_buffer_state( ); + (yy_did_buffer_switch_on_eof) = 1; + } +} + +/* Allocates the stack if it does not exist. + * Guarantees space for at least one push. + */ +static void yyensure_buffer_stack (void) +{ + int num_to_alloc; + + if (!(yy_buffer_stack)) { + + /* First allocation is just for 2 elements, since we don't know if this + * scanner will even need a stack. We use 2 instead of 1 to avoid an + * immediate realloc on the next call. + */ + num_to_alloc = 1; + (yy_buffer_stack) = (struct yy_buffer_state**)yyalloc + (num_to_alloc * sizeof(struct yy_buffer_state*) + ); + if ( ! (yy_buffer_stack) ) + YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" ); + + memset((yy_buffer_stack), 0, num_to_alloc * sizeof(struct yy_buffer_state*)); + + (yy_buffer_stack_max) = num_to_alloc; + (yy_buffer_stack_top) = 0; + return; + } + + if ((yy_buffer_stack_top) >= ((yy_buffer_stack_max)) - 1){ + + /* Increase the buffer to prepare for a possible push. */ + int grow_size = 8 /* arbitrary grow size */; + + num_to_alloc = (yy_buffer_stack_max) + grow_size; + (yy_buffer_stack) = (struct yy_buffer_state**)yyrealloc + ((yy_buffer_stack), + num_to_alloc * sizeof(struct yy_buffer_state*) + ); + if ( ! (yy_buffer_stack) ) + YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" ); + + /* zero only the new slots.*/ + memset((yy_buffer_stack) + (yy_buffer_stack_max), 0, grow_size * sizeof(struct yy_buffer_state*)); + (yy_buffer_stack_max) = num_to_alloc; + } +} + +/** Setup the input buffer state to scan directly from a user-specified character buffer. + * @param base the character buffer + * @param size the size in bytes of the character buffer + * + * @return the newly allocated buffer state object. + */ +YY_BUFFER_STATE yy_scan_buffer (char * base, yy_size_t size ) +{ + YY_BUFFER_STATE b; + + if ( size < 2 || + base[size-2] != YY_END_OF_BUFFER_CHAR || + base[size-1] != YY_END_OF_BUFFER_CHAR ) + /* They forgot to leave room for the EOB's. */ + return 0; + + b = (YY_BUFFER_STATE) yyalloc(sizeof( struct yy_buffer_state ) ); + if ( ! b ) + YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" ); + + b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */ + b->yy_buf_pos = b->yy_ch_buf = base; + b->yy_is_our_buffer = 0; + b->yy_input_file = 0; + b->yy_n_chars = b->yy_buf_size; + b->yy_is_interactive = 0; + b->yy_at_bol = 1; + b->yy_fill_buffer = 0; + b->yy_buffer_status = YY_BUFFER_NEW; + + yy_switch_to_buffer(b ); + + return b; +} + +/** Setup the input buffer state to scan a string. The next call to yylex() will + * scan from a @e copy of @a str. + * @param yystr a NUL-terminated string to scan + * + * @return the newly allocated buffer state object. + * @note If you want to scan bytes that may contain NUL values, then use + * yy_scan_bytes() instead. + */ +YY_BUFFER_STATE yy_scan_string (yyconst char * yystr ) +{ + + return yy_scan_bytes(yystr,strlen(yystr) ); +} + +/** Setup the input buffer state to scan the given bytes. The next call to yylex() will + * scan from a @e copy of @a bytes. + * @param yybytes the byte buffer to scan + * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes. + * + * @return the newly allocated buffer state object. + */ +YY_BUFFER_STATE yy_scan_bytes (yyconst char * yybytes, int _yybytes_len ) +{ + YY_BUFFER_STATE b; + char *buf; + yy_size_t n; + int i; + + /* Get memory for full buffer, including space for trailing EOB's. */ + n = _yybytes_len + 2; + buf = (char *) yyalloc(n ); + if ( ! buf ) + YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" ); + + for ( i = 0; i < _yybytes_len; ++i ) + buf[i] = yybytes[i]; + + buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR; + + b = yy_scan_buffer(buf,n ); + if ( ! b ) + YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" ); + + /* It's okay to grow etc. this buffer, and we should throw it + * away when we're done. + */ + b->yy_is_our_buffer = 1; + + return b; +} + +#ifndef YY_EXIT_FAILURE +#define YY_EXIT_FAILURE 2 +#endif + +static void yy_fatal_error (yyconst char* msg ) +{ + (void) fprintf( stderr, "%s\n", msg ); + exit( YY_EXIT_FAILURE ); +} + +/* Redefine yyless() so it works in section 3 code. */ + +#undef yyless +#define yyless(n) \ + do \ + { \ + /* Undo effects of setting up yytext. */ \ + int yyless_macro_arg = (n); \ + YY_LESS_LINENO(yyless_macro_arg);\ + yytext[yyleng] = (yy_hold_char); \ + (yy_c_buf_p) = yytext + yyless_macro_arg; \ + (yy_hold_char) = *(yy_c_buf_p); \ + *(yy_c_buf_p) = '\0'; \ + yyleng = yyless_macro_arg; \ + } \ + while ( 0 ) + +/* Accessor methods (get/set functions) to struct members. */ + +/** Get the current line number. + * + */ +int yyget_lineno (void) +{ + + return yylineno; +} + +/** Get the input stream. + * + */ +FILE *yyget_in (void) +{ + return yyin; +} + +/** Get the output stream. + * + */ +FILE *yyget_out (void) +{ + return yyout; +} + +/** Get the length of the current token. + * + */ +int yyget_leng (void) +{ + return yyleng; +} + +/** Get the current token. + * + */ + +char *yyget_text (void) +{ + return yytext; +} + +/** Set the current line number. + * @param line_number + * + */ +void yyset_lineno (int line_number ) +{ + + yylineno = line_number; +} + +/** Set the input stream. This does not discard the current + * input buffer. + * @param in_str A readable stream. + * + * @see yy_switch_to_buffer + */ +void yyset_in (FILE * in_str ) +{ + yyin = in_str ; +} + +void yyset_out (FILE * out_str ) +{ + yyout = out_str ; +} + +int yyget_debug (void) +{ + return yy_flex_debug; +} + +void yyset_debug (int bdebug ) +{ + yy_flex_debug = bdebug ; +} + +static int yy_init_globals (void) +{ + /* Initialization is the same as for the non-reentrant scanner. + * This function is called from yylex_destroy(), so don't allocate here. + */ + + /* We do not touch yylineno unless the option is enabled. */ + yylineno = 1; + + (yy_buffer_stack) = 0; + (yy_buffer_stack_top) = 0; + (yy_buffer_stack_max) = 0; + (yy_c_buf_p) = (char *) 0; + (yy_init) = 0; + (yy_start) = 0; + +/* Defined in main.c */ +#ifdef YY_STDINIT + yyin = stdin; + yyout = stdout; +#else + yyin = (FILE *) 0; + yyout = (FILE *) 0; +#endif + + /* For future reference: Set errno on error, since we are called by + * yylex_init() + */ + return 0; +} + +/* yylex_destroy is for both reentrant and non-reentrant scanners. */ +int yylex_destroy (void) +{ + + /* Pop the buffer stack, destroying each element. */ + while(YY_CURRENT_BUFFER){ + yy_delete_buffer(YY_CURRENT_BUFFER ); + YY_CURRENT_BUFFER_LVALUE = NULL; + yypop_buffer_state(); + } + + /* Destroy the stack itself. */ + yyfree((yy_buffer_stack) ); + (yy_buffer_stack) = NULL; + + /* Reset the globals. This is important in a non-reentrant scanner so the next time + * yylex() is called, initialization will occur. */ + yy_init_globals( ); + + return 0; +} + +/* + * Internal utility routines. + */ + +#ifndef yytext_ptr +static void yy_flex_strncpy (char* s1, yyconst char * s2, int n ) +{ + register int i; + for ( i = 0; i < n; ++i ) + s1[i] = s2[i]; +} +#endif + +#ifdef YY_NEED_STRLEN +static int yy_flex_strlen (yyconst char * s ) +{ + register int n; + for ( n = 0; s[n]; ++n ) + ; + + return n; +} +#endif + +void *yyalloc (yy_size_t size ) +{ + return (void *) malloc( size ); +} + +void *yyrealloc (void * ptr, yy_size_t size ) +{ + /* The cast to (char *) in the following accommodates both + * implementations that use char* generic pointers, and those + * that use void* generic pointers. It works with the latter + * because both ANSI C and C++ allow castless assignment from + * any pointer type to void*, and deal with argument conversions + * as though doing an assignment. + */ + return (void *) realloc( (char *) ptr, size ); +} + +void yyfree (void * ptr ) +{ + free( (char *) ptr ); /* see yyrealloc() for (char *) cast */ +} + +#define YYTABLES_NAME "yytables" + +#line 1219 "pgc.l" + + +void +lex_init(void) +{ + braces_open = 0; + parenths_open = 0; + current_function = NULL; + + preproc_tos = 0; + yylineno = 1; + ifcond = TRUE; + stacked_if_value[preproc_tos].condition = ifcond; + stacked_if_value[preproc_tos].else_branch = FALSE; + + /* initialize literal buffer to a reasonable but expansible size */ + if (literalbuf == NULL) + { + literalalloc = 1024; + literalbuf = (char *) malloc(literalalloc); + } + startlit(); + + BEGIN(C); +} + +static void +addlit(char *ytext, int yleng) +{ + /* enlarge buffer if needed */ + if ((literallen+yleng) >= literalalloc) + { + do + literalalloc *= 2; + while ((literallen+yleng) >= literalalloc); + literalbuf = (char *) realloc(literalbuf, literalalloc); + } + /* append new data, add trailing null */ + memcpy(literalbuf+literallen, ytext, yleng); + literallen += yleng; + literalbuf[literallen] = '\0'; +} + +static void +addlitchar(unsigned char ychar) +{ + /* enlarge buffer if needed */ + if ((literallen+1) >= literalalloc) + { + literalalloc *= 2; + literalbuf = (char *) realloc(literalbuf, literalalloc); + } + /* append new data, add trailing null */ + literalbuf[literallen] = ychar; + literallen += 1; + literalbuf[literallen] = '\0'; +} + +static void +parse_include(void) +{ + /* got the include file name */ + struct _yy_buffer *yb; + struct _include_path *ip; + char inc_file[MAXPGPATH]; + unsigned int i; + + yb = mm_alloc(sizeof(struct _yy_buffer)); + + yb->buffer = YY_CURRENT_BUFFER; + yb->lineno = yylineno; + yb->filename = input_filename; + yb->next = yy_buffer; + + yy_buffer = yb; + + /* + * skip the ";" if there is one and trailing whitespace. Note that + * yytext contains at least one non-space character plus the ";" + */ + for (i = strlen(yytext)-2; + i > 0 && ecpg_isspace(yytext[i]); + i--) + ; + + if (yytext[i] == ';') + i--; + + yytext[i+1] = '\0'; + + yyin = NULL; + + /* If file name is enclosed in '"' remove these and look only in '.' */ + /* Informix does look into all include paths though, except filename starts with '/' */ + if (yytext[0] == '"' && yytext[i] == '"' && + ((compat != ECPG_COMPAT_INFORMIX && compat != ECPG_COMPAT_INFORMIX_SE) || yytext[1] == '/')) + { + yytext[i] = '\0'; + memmove(yytext, yytext+1, strlen(yytext)); + + strncpy(inc_file, yytext, sizeof(inc_file)); + yyin = fopen(inc_file, "r"); + if (!yyin) + { + if (strcmp(inc_file + strlen(inc_file) - 2, ".h") != 0) + { + strcat(inc_file, ".h"); + yyin = fopen(inc_file, "r"); + } + } + + } + else + { + if ((yytext[0] == '"' && yytext[i] == '"') || (yytext[0] == '<' && yytext[i] == '>')) + { + yytext[i] = '\0'; + memmove(yytext, yytext+1, strlen(yytext)); + } + + for (ip = include_paths; yyin == NULL && ip != NULL; ip = ip->next) + { + if (strlen(ip->path) + strlen(yytext) + 3 > MAXPGPATH) + { + fprintf(stderr, _("Error: include path \"%s/%s\" is too long on line %d, skipping\n"), ip->path, yytext, yylineno); + continue; + } + snprintf (inc_file, sizeof(inc_file), "%s/%s", ip->path, yytext); + yyin = fopen(inc_file, "r"); + if (!yyin) + { + if (strcmp(inc_file + strlen(inc_file) - 2, ".h") != 0) + { + strcat(inc_file, ".h"); + yyin = fopen( inc_file, "r" ); + } + } + /* if the command was "include_next" we have to disregard the first hit */ + if (yyin && include_next) + { + yyin = NULL; + include_next = false; + } + } + } + if (!yyin) + mmerror(NO_INCLUDE_FILE, ET_FATAL, "could not open include file \"%s\" on line %d", yytext, yylineno); + + input_filename = mm_strdup(inc_file); + yy_switch_to_buffer(yy_create_buffer(yyin,YY_BUF_SIZE )); + yylineno = 1; + output_line_number(); + + BEGIN(C); +} + +/* + * ecpg_isspace() --- return TRUE if flex scanner considers char whitespace + */ +static bool +ecpg_isspace(char ch) +{ + if (ch == ' ' || + ch == '\t' || + ch == '\n' || + ch == '\r' || + ch == '\f') + return true; + return false; +} + +static bool isdefine(void) +{ + struct _defines *ptr; + + /* is it a define? */ + for (ptr = defines; ptr; ptr = ptr->next) + { + if (strcmp(yytext, ptr->old) == 0 && ptr->used == NULL) + { + struct _yy_buffer *yb; + + yb = mm_alloc(sizeof(struct _yy_buffer)); + + yb->buffer = YY_CURRENT_BUFFER; + yb->lineno = yylineno; + yb->filename = mm_strdup(input_filename); + yb->next = yy_buffer; + + ptr->used = yy_buffer = yb; + + yy_scan_string(ptr->new); + return true; + } + } + + return false; +} + +static bool isinformixdefine(void) +{ + const char *new = NULL; + + if (strcmp(yytext, "dec_t") == 0) + new = "decimal"; + else if (strcmp(yytext, "intrvl_t") == 0) + new = "interval"; + else if (strcmp(yytext, "dtime_t") == 0) + new = "timestamp"; + + if (new) + { + struct _yy_buffer *yb; + + yb = mm_alloc(sizeof(struct _yy_buffer)); + + yb->buffer = YY_CURRENT_BUFFER; + yb->lineno = yylineno; + yb->filename = mm_strdup(input_filename); + yb->next = yy_buffer; + yy_buffer = yb; + + yy_scan_string(new); + return true; + } + + return false; +} + +/* + * Called before any actual parsing is done + */ +void +scanner_init(const char *str) +{ + Size slen = strlen(str); + + /* + * Might be left over after ereport() + */ + if (YY_CURRENT_BUFFER) + yy_delete_buffer(YY_CURRENT_BUFFER); + + /* + * Make a scan buffer with special termination needed by flex. + */ + scanbuf = mm_alloc(slen + 2); + memcpy(scanbuf, str, slen); + scanbuf[slen] = scanbuf[slen + 1] = YY_END_OF_BUFFER_CHAR; + scanbufhandle = yy_scan_buffer(scanbuf,slen + 2); + + /* initialize literal buffer to a reasonable but expansible size */ + literalalloc = 128; + literalbuf = (char *) mm_alloc(literalalloc); + startlit(); + + BEGIN(INITIAL); +} + + +/* + * Called after parsing is done to clean up after scanner_init() + */ +void +scanner_finish(void) +{ + yy_delete_buffer(scanbufhandle); + free(scanbuf); +} + diff --git a/src/interfaces/ecpg/preproc/preproc.c b/src/interfaces/ecpg/preproc/preproc.c new file mode 100644 index 000000000..82d9a5b54 --- /dev/null +++ b/src/interfaces/ecpg/preproc/preproc.c @@ -0,0 +1,51699 @@ + +/* A Bison parser, made by GNU Bison 2.4.1. */ + +/* Skeleton implementation for Bison's Yacc-like parsers in C + + Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 + Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . */ + +/* As a special exception, you may create a larger work that contains + part or all of the Bison parser skeleton and distribute that work + under terms of your choice, so long as that work isn't itself a + parser generator using the skeleton or a modified version thereof + as a parser skeleton. Alternatively, if you modify or redistribute + the parser skeleton itself, you may (at your option) remove this + special exception, which will cause the skeleton and the resulting + Bison output files to be licensed under the GNU General Public + License without this special exception. + + This special exception was added by the Free Software Foundation in + version 2.2 of Bison. */ + +/* C LALR(1) parser skeleton written by Richard Stallman, by + simplifying the original so-called "semantic" parser. */ + +/* All symbols defined below should begin with yy or YY, to avoid + infringing on user name space. This should be done even for local + variables, as they might otherwise be expanded by user macros. + There are some unavoidable exceptions within include files to + define necessary library symbols; they are noted "INFRINGES ON + USER NAME SPACE" below. */ + +/* Identify Bison output. */ +#define YYBISON 1 + +/* Bison version. */ +#define YYBISON_VERSION "2.4.1" + +/* Skeleton name. */ +#define YYSKELETON_NAME "yacc.c" + +/* Pure parsers. */ +#define YYPURE 0 + +/* Push parsers. */ +#define YYPUSH 0 + +/* Pull parsers. */ +#define YYPULL 1 + +/* Using locations. */ +#define YYLSP_NEEDED 1 + +/* Substitute the variable and function names. */ +#define yyparse base_yyparse +#define yylex base_yylex +#define yyerror base_yyerror +#define yylval base_yylval +#define yychar base_yychar +#define yydebug base_yydebug +#define yynerrs base_yynerrs +#define yylloc base_yylloc + +/* Copy the first part of user declarations. */ + +/* Line 189 of yacc.c */ +#line 5 "preproc.y" + +#include "postgres_fe.h" + +#include "extern.h" +#include "ecpg_config.h" +#include + +/* Location tracking support --- simpler than bison's default */ +#define YYLLOC_DEFAULT(Current, Rhs, N) \ + do { \ + if (N) \ + (Current) = (Rhs)[1]; \ + else \ + (Current) = (Rhs)[0]; \ + } while (0) + +/* + * The %name-prefix option below will make bison call base_yylex, but we + * really want it to call filtered_base_yylex (see parser.c). + */ +#define base_yylex filtered_base_yylex + +/* + * This is only here so the string gets into the POT. Bison uses it + * internally. + */ +#define bison_gettext_dummy gettext_noop("syntax error") + +/* + * Variables containing simple states. + */ +int struct_level = 0; +int braces_open; /* brace level counter */ +char *current_function; +int ecpg_internal_var = 0; +char *connection = NULL; +char *input_filename = NULL; + +static int FoundInto = 0; +static int initializer = 0; +static int pacounter = 1; +static char pacounter_buffer[sizeof(int) * CHAR_BIT * 10 / 3]; /* a rough guess at the size we need */ +static struct this_type actual_type[STRUCT_DEPTH]; +static char *actual_startline[STRUCT_DEPTH]; +static int varchar_counter = 1; + +/* temporarily store struct members while creating the data structure */ +struct ECPGstruct_member *struct_member_list[STRUCT_DEPTH] = { NULL }; + +/* also store struct type so we can do a sizeof() later */ +static char *ECPGstruct_sizeof = NULL; + +/* for forward declarations we have to store some data as well */ +static char *forward_name = NULL; + +struct ECPGtype ecpg_no_indicator = {ECPGt_NO_INDICATOR, NULL, NULL, NULL, {NULL}, 0}; +struct variable no_indicator = {"no_indicator", &ecpg_no_indicator, 0, NULL}; + +struct ECPGtype ecpg_query = {ECPGt_char_variable, NULL, NULL, NULL, {NULL}, 0}; + +/* + * Handle parsing errors and warnings + */ +void +mmerror(int error_code, enum errortype type, const char *error, ...) +{ + va_list ap; + + /* internationalize the error message string */ + error = _(error); + + fprintf(stderr, "%s:%d: ", input_filename, yylineno); + + switch(type) + { + case ET_WARNING: + fprintf(stderr, _("WARNING: ")); + break; + case ET_ERROR: + case ET_FATAL: + fprintf(stderr, _("ERROR: ")); + break; + } + + va_start(ap, error); + vfprintf(stderr, error, ap); + va_end(ap); + + fprintf(stderr, "\n"); + + switch(type) + { + case ET_WARNING: + break; + case ET_ERROR: + ret_value = error_code; + break; + case ET_FATAL: + if (yyin) + fclose(yyin); + if (yyout) + fclose(yyout); + + if (strcmp(output_filename, "-") != 0 && unlink(output_filename) != 0) + fprintf(stderr, _("could not remove output file \"%s\"\n"), output_filename); + exit(error_code); + } +} + +/* + * string concatenation + */ + +static char * +cat2_str(char *str1, char *str2) +{ + char * res_str = (char *)mm_alloc(strlen(str1) + strlen(str2) + 2); + + strcpy(res_str, str1); + if (strlen(str1) != 0 && strlen(str2) != 0) + strcat(res_str, " "); + strcat(res_str, str2); + free(str1); + free(str2); + return(res_str); +} + +static char * +cat_str(int count, ...) +{ + va_list args; + int i; + char *res_str; + + va_start(args, count); + + res_str = va_arg(args, char *); + + /* now add all other strings */ + for (i = 1; i < count; i++) + res_str = cat2_str(res_str, va_arg(args, char *)); + + va_end(args); + + return(res_str); +} + +static char * +make2_str(char *str1, char *str2) +{ + char * res_str = (char *)mm_alloc(strlen(str1) + strlen(str2) + 1); + + strcpy(res_str, str1); + strcat(res_str, str2); + free(str1); + free(str2); + return(res_str); +} + +static char * +make3_str(char *str1, char *str2, char *str3) +{ + char * res_str = (char *)mm_alloc(strlen(str1) + strlen(str2) +strlen(str3) + 1); + + strcpy(res_str, str1); + strcat(res_str, str2); + strcat(res_str, str3); + free(str1); + free(str2); + free(str3); + return(res_str); +} + +/* and the rest */ +static char * +make_name(void) +{ + return mm_strdup(yytext); +} + +static char * +create_questionmarks(char *name, bool array) +{ + struct variable *p = find_variable(name); + int count; + char *result = EMPTY; + + /* In case we have a struct, we have to print as many "?" as there are attributes in the struct + * An array is only allowed together with an element argument + * This is essantially only used for inserts, but using a struct as input parameter is an error anywhere else + * so we don't have to worry here. */ + + if (p->type->type == ECPGt_struct || (array && p->type->type == ECPGt_array && p->type->u.element->type == ECPGt_struct)) + { + struct ECPGstruct_member *m; + + if (p->type->type == ECPGt_struct) + m = p->type->u.members; + else + m = p->type->u.element->u.members; + + for (count = 0; m != NULL; m=m->next, count++); + } + else + count = 1; + + for (; count > 0; count --) + { + sprintf(pacounter_buffer, "$%d", pacounter++); + result = cat_str(3, result, mm_strdup(pacounter_buffer), mm_strdup(" , ")); + } + + /* removed the trailing " ," */ + + result[strlen(result)-3] = '\0'; + return(result); +} + +static char * +adjust_outofscope_cursor_vars(struct cursor *cur) +{ + /* Informix accepts DECLARE with variables that are out of scope when OPEN is called. + * For instance you can DECLARE a cursor in one function, and OPEN/FETCH/CLOSE + * it in another functions. This is very useful for e.g. event-driver programming, + * but may also lead to dangerous programming. The limitation when this is allowed + * and doesn't cause problems have to be documented, like the allocated variables + * must not be realloc()'ed. + * + * We have to change the variables to our own struct and just store the pointer + * instead of the variable. Do it only for local variables, not for globals. + */ + + char *result = EMPTY; + int insert; + + for (insert = 1; insert >= 0; insert--) + { + struct arguments *list; + struct arguments *ptr; + struct arguments *newlist = NULL; + struct variable *newvar, *newind; + + list = (insert ? cur->argsinsert : cur->argsresult); + + for (ptr = list; ptr != NULL; ptr = ptr->next) + { + char var_text[20]; + char *original_var; + bool skip_set_var = false; + bool var_ptr = false; + + /* change variable name to "ECPGget_var()" */ + original_var = ptr->variable->name; + sprintf(var_text, "%d))", ecpg_internal_var); + + /* Don't emit ECPGset_var() calls for global variables */ + if (ptr->variable->brace_level == 0) + { + newvar = ptr->variable; + skip_set_var = true; + } + else if ((ptr->variable->type->type == ECPGt_char_variable) + && (strncmp(ptr->variable->name, "ECPGprepared_statement", strlen("ECPGprepared_statement")) == 0)) + { + newvar = ptr->variable; + skip_set_var = true; + } + else if ((ptr->variable->type->type != ECPGt_varchar + && ptr->variable->type->type != ECPGt_char + && ptr->variable->type->type != ECPGt_unsigned_char + && ptr->variable->type->type != ECPGt_string) + && atoi(ptr->variable->type->size) > 1) + { + newvar = new_variable(cat_str(4, mm_strdup("("), + mm_strdup(ecpg_type_name(ptr->variable->type->u.element->type)), + mm_strdup(" *)(ECPGget_var("), + mm_strdup(var_text)), + ECPGmake_array_type(ECPGmake_simple_type(ptr->variable->type->u.element->type, + mm_strdup("1"), + ptr->variable->type->u.element->counter), + ptr->variable->type->size), + 0); + } + else if ((ptr->variable->type->type == ECPGt_varchar + || ptr->variable->type->type == ECPGt_char + || ptr->variable->type->type == ECPGt_unsigned_char + || ptr->variable->type->type == ECPGt_string) + && atoi(ptr->variable->type->size) > 1) + { + newvar = new_variable(cat_str(4, mm_strdup("("), + mm_strdup(ecpg_type_name(ptr->variable->type->type)), + mm_strdup(" *)(ECPGget_var("), + mm_strdup(var_text)), + ECPGmake_simple_type(ptr->variable->type->type, + ptr->variable->type->size, + ptr->variable->type->counter), + 0); + if (ptr->variable->type->type == ECPGt_varchar) + var_ptr = true; + } + else if (ptr->variable->type->type == ECPGt_struct + || ptr->variable->type->type == ECPGt_union) + { + newvar = new_variable(cat_str(5, mm_strdup("(*("), + mm_strdup(ptr->variable->type->type_name), + mm_strdup(" *)(ECPGget_var("), + mm_strdup(var_text), + mm_strdup(")")), + ECPGmake_struct_type(ptr->variable->type->u.members, + ptr->variable->type->type, + ptr->variable->type->type_name, + ptr->variable->type->struct_sizeof), + 0); + var_ptr = true; + } + else if (ptr->variable->type->type == ECPGt_array) + { + if (ptr->variable->type->u.element->type == ECPGt_struct + || ptr->variable->type->u.element->type == ECPGt_union) + { + newvar = new_variable(cat_str(5, mm_strdup("(*("), + mm_strdup(ptr->variable->type->u.element->type_name), + mm_strdup(" *)(ECPGget_var("), + mm_strdup(var_text), + mm_strdup(")")), + ECPGmake_struct_type(ptr->variable->type->u.element->u.members, + ptr->variable->type->u.element->type, + ptr->variable->type->u.element->type_name, + ptr->variable->type->u.element->struct_sizeof), + 0); + } + else + { + newvar = new_variable(cat_str(4, mm_strdup("("), + mm_strdup(ecpg_type_name(ptr->variable->type->type)), + mm_strdup(" *)(ECPGget_var("), + mm_strdup(var_text)), + ECPGmake_array_type(ECPGmake_simple_type(ptr->variable->type->u.element->type, + ptr->variable->type->u.element->size, + ptr->variable->type->u.element->counter), + ptr->variable->type->size), + 0); + var_ptr = true; + } + } + else + { + newvar = new_variable(cat_str(4, mm_strdup("*("), + mm_strdup(ecpg_type_name(ptr->variable->type->type)), + mm_strdup(" *)(ECPGget_var("), + mm_strdup(var_text)), + ECPGmake_simple_type(ptr->variable->type->type, + ptr->variable->type->size, + ptr->variable->type->counter), + 0); + var_ptr = true; + } + + /* create call to "ECPGset_var(, , . )" */ + if (!skip_set_var) + { + sprintf(var_text, "%d, %s", ecpg_internal_var++, var_ptr ? "&(" : "("); + result = cat_str(5, result, mm_strdup("ECPGset_var("), + mm_strdup(var_text), mm_strdup(original_var), + mm_strdup("), __LINE__);\n")); + } + + /* now the indicator if there is one and it's not a global variable */ + if ((ptr->indicator->type->type == ECPGt_NO_INDICATOR) || (ptr->indicator->brace_level == 0)) + { + newind = ptr->indicator; + } + else + { + /* change variable name to "ECPGget_var()" */ + original_var = ptr->indicator->name; + sprintf(var_text, "%d))", ecpg_internal_var); + var_ptr = false; + + if (ptr->indicator->type->type == ECPGt_struct + || ptr->indicator->type->type == ECPGt_union) + { + newind = new_variable(cat_str(5, mm_strdup("(*("), + mm_strdup(ptr->indicator->type->type_name), + mm_strdup(" *)(ECPGget_var("), + mm_strdup(var_text), + mm_strdup(")")), + ECPGmake_struct_type(ptr->indicator->type->u.members, + ptr->indicator->type->type, + ptr->indicator->type->type_name, + ptr->indicator->type->struct_sizeof), + 0); + var_ptr = true; + } + else if (ptr->indicator->type->type == ECPGt_array) + { + if (ptr->indicator->type->u.element->type == ECPGt_struct + || ptr->indicator->type->u.element->type == ECPGt_union) + { + newind = new_variable(cat_str(5, mm_strdup("(*("), + mm_strdup(ptr->indicator->type->u.element->type_name), + mm_strdup(" *)(ECPGget_var("), + mm_strdup(var_text), + mm_strdup(")")), + ECPGmake_struct_type(ptr->indicator->type->u.element->u.members, + ptr->indicator->type->u.element->type, + ptr->indicator->type->u.element->type_name, + ptr->indicator->type->u.element->struct_sizeof), + 0); + } + else + { + newind = new_variable(cat_str(4, mm_strdup("("), + mm_strdup(ecpg_type_name(ptr->indicator->type->u.element->type)), + mm_strdup(" *)(ECPGget_var("), mm_strdup(var_text)), + ECPGmake_array_type(ECPGmake_simple_type(ptr->indicator->type->u.element->type, + ptr->indicator->type->u.element->size, + ptr->indicator->type->u.element->counter), + ptr->indicator->type->size), + 0); + var_ptr = true; + } + } + else if (atoi(ptr->indicator->type->size) > 1) + { + newind = new_variable(cat_str(4, mm_strdup("("), + mm_strdup(ecpg_type_name(ptr->indicator->type->type)), + mm_strdup(" *)(ECPGget_var("), + mm_strdup(var_text)), + ECPGmake_simple_type(ptr->indicator->type->type, + ptr->indicator->type->size, + ptr->variable->type->counter), + 0); + } + else + { + newind = new_variable(cat_str(4, mm_strdup("*("), + mm_strdup(ecpg_type_name(ptr->indicator->type->type)), + mm_strdup(" *)(ECPGget_var("), + mm_strdup(var_text)), + ECPGmake_simple_type(ptr->indicator->type->type, + ptr->indicator->type->size, + ptr->variable->type->counter), + 0); + var_ptr = true; + } + + /* create call to "ECPGset_var(, . )" */ + sprintf(var_text, "%d, %s", ecpg_internal_var++, var_ptr ? "&(" : "("); + result = cat_str(5, result, mm_strdup("ECPGset_var("), + mm_strdup(var_text), mm_strdup(original_var), + mm_strdup("), __LINE__);\n")); + } + + add_variable_to_tail(&newlist, newvar, newind); + } + + if (insert) + cur->argsinsert_oos = newlist; + else + cur->argsresult_oos = newlist; + } + + return result; +} + +/* This tests whether the cursor was declared and opened in the same function. */ +#define SAMEFUNC(cur) \ + ((cur->function == NULL) || \ + (cur->function != NULL && strcmp(cur->function, current_function) == 0)) + +static struct cursor * +add_additional_variables(char *name, bool insert) +{ + struct cursor *ptr; + struct arguments *p; + int (* strcmp_fn)(const char *, const char *) = (name[0] == ':' ? strcmp : pg_strcasecmp); + + for (ptr = cur; ptr != NULL; ptr=ptr->next) + { + if (strcmp_fn(ptr->name, name) == 0) + break; + } + + if (ptr == NULL) + { + mmerror(PARSE_ERROR, ET_ERROR, "cursor \"%s\" does not exist", name); + return NULL; + } + + if (insert) + { + /* add all those input variables that were given earlier + * note that we have to append here but have to keep the existing order */ + for (p = (SAMEFUNC(ptr) ? ptr->argsinsert : ptr->argsinsert_oos); p; p = p->next) + add_variable_to_tail(&argsinsert, p->variable, p->indicator); + } + + /* add all those output variables that were given earlier */ + for (p = (SAMEFUNC(ptr) ? ptr->argsresult : ptr->argsresult_oos); p; p = p->next) + add_variable_to_tail(&argsresult, p->variable, p->indicator); + + return ptr; +} + +static void +add_typedef(char *name, char *dimension, char *length, enum ECPGttype type_enum, + char *type_dimension, char *type_index, int initializer, int array) +{ + /* add entry to list */ + struct typedefs *ptr, *this; + + if ((type_enum == ECPGt_struct || + type_enum == ECPGt_union) && + initializer == 1) + mmerror(PARSE_ERROR, ET_ERROR, "initializer not allowed in type definition"); + else if (INFORMIX_MODE && strcmp(name, "string") == 0) + mmerror(PARSE_ERROR, ET_ERROR, "type name \"string\" is reserved in Informix mode"); + else + { + for (ptr = types; ptr != NULL; ptr = ptr->next) + { + if (strcmp(name, ptr->name) == 0) + /* re-definition is a bug */ + mmerror(PARSE_ERROR, ET_ERROR, "type \"%s\" is already defined", name); + } + adjust_array(type_enum, &dimension, &length, type_dimension, type_index, array, true); + + this = (struct typedefs *) mm_alloc(sizeof(struct typedefs)); + + /* initial definition */ + this->next = types; + this->name = name; + this->brace_level = braces_open; + this->type = (struct this_type *) mm_alloc(sizeof(struct this_type)); + this->type->type_enum = type_enum; + this->type->type_str = mm_strdup(name); + this->type->type_dimension = dimension; /* dimension of array */ + this->type->type_index = length; /* length of string */ + this->type->type_sizeof = ECPGstruct_sizeof; + this->struct_member_list = (type_enum == ECPGt_struct || type_enum == ECPGt_union) ? + ECPGstruct_member_dup(struct_member_list[struct_level]) : NULL; + + if (type_enum != ECPGt_varchar && + type_enum != ECPGt_char && + type_enum != ECPGt_unsigned_char && + type_enum != ECPGt_string && + atoi(this->type->type_index) >= 0) + mmerror(PARSE_ERROR, ET_ERROR, "multidimensional arrays for simple data types are not supported"); + + types = this; + } +} + + +/* Line 189 of yacc.c */ +#line 637 "preproc.c" + +/* Enabling traces. */ +#ifndef YYDEBUG +# define YYDEBUG 0 +#endif + +/* Enabling verbose error messages. */ +#ifdef YYERROR_VERBOSE +# undef YYERROR_VERBOSE +# define YYERROR_VERBOSE 1 +#else +# define YYERROR_VERBOSE 0 +#endif + +/* Enabling the token table. */ +#ifndef YYTOKEN_TABLE +# define YYTOKEN_TABLE 0 +#endif + + +/* Tokens. */ +#ifndef YYTOKENTYPE +# define YYTOKENTYPE + /* Put the tokens into the symbol table, so that GDB and other debuggers + know about them. */ + enum yytokentype { + SQL_ALLOCATE = 258, + SQL_AUTOCOMMIT = 259, + SQL_BOOL = 260, + SQL_BREAK = 261, + SQL_CALL = 262, + SQL_CARDINALITY = 263, + SQL_CONNECT = 264, + SQL_COUNT = 265, + SQL_DATETIME_INTERVAL_CODE = 266, + SQL_DATETIME_INTERVAL_PRECISION = 267, + SQL_DESCRIBE = 268, + SQL_DESCRIPTOR = 269, + SQL_DISCONNECT = 270, + SQL_FOUND = 271, + SQL_FREE = 272, + SQL_GET = 273, + SQL_GO = 274, + SQL_GOTO = 275, + SQL_IDENTIFIED = 276, + SQL_INDICATOR = 277, + SQL_KEY_MEMBER = 278, + SQL_LENGTH = 279, + SQL_LONG = 280, + SQL_NULLABLE = 281, + SQL_OCTET_LENGTH = 282, + SQL_OPEN = 283, + SQL_OUTPUT = 284, + SQL_REFERENCE = 285, + SQL_RETURNED_LENGTH = 286, + SQL_RETURNED_OCTET_LENGTH = 287, + SQL_SCALE = 288, + SQL_SECTION = 289, + SQL_SHORT = 290, + SQL_SIGNED = 291, + SQL_SQL = 292, + SQL_SQLERROR = 293, + SQL_SQLPRINT = 294, + SQL_SQLWARNING = 295, + SQL_START = 296, + SQL_STOP = 297, + SQL_STRUCT = 298, + SQL_UNSIGNED = 299, + SQL_VAR = 300, + SQL_WHENEVER = 301, + S_ADD = 302, + S_AND = 303, + S_ANYTHING = 304, + S_AUTO = 305, + S_CONST = 306, + S_DEC = 307, + S_DIV = 308, + S_DOTPOINT = 309, + S_EQUAL = 310, + S_EXTERN = 311, + S_INC = 312, + S_LSHIFT = 313, + S_MEMPOINT = 314, + S_MEMBER = 315, + S_MOD = 316, + S_MUL = 317, + S_NEQUAL = 318, + S_OR = 319, + S_REGISTER = 320, + S_RSHIFT = 321, + S_STATIC = 322, + S_SUB = 323, + S_VOLATILE = 324, + S_TYPEDEF = 325, + CSTRING = 326, + CVARIABLE = 327, + CPP_LINE = 328, + IP = 329, + DOLCONST = 330, + ECONST = 331, + NCONST = 332, + UCONST = 333, + UIDENT = 334, + IDENT = 335, + FCONST = 336, + SCONST = 337, + BCONST = 338, + XCONST = 339, + Op = 340, + ICONST = 341, + PARAM = 342, + TYPECAST = 343, + DOT_DOT = 344, + COLON_EQUALS = 345, + ABORT_P = 346, + ABSOLUTE_P = 347, + ACCESS = 348, + ACTION = 349, + ADD_P = 350, + ADMIN = 351, + AFTER = 352, + AGGREGATE = 353, + ALL = 354, + ALSO = 355, + ALTER = 356, + ALWAYS = 357, + ANALYSE = 358, + ANALYZE = 359, + AND = 360, + ANY = 361, + ARRAY = 362, + AS = 363, + ASC = 364, + ASSERTION = 365, + ASSIGNMENT = 366, + ASYMMETRIC = 367, + AT = 368, + ATTRIBUTE = 369, + AUTHORIZATION = 370, + BACKWARD = 371, + BEFORE = 372, + BEGIN_P = 373, + BETWEEN = 374, + BIGINT = 375, + BINARY = 376, + BIT = 377, + BOOLEAN_P = 378, + BOTH = 379, + BY = 380, + CACHE = 381, + CALLED = 382, + CASCADE = 383, + CASCADED = 384, + CASE = 385, + CAST = 386, + CATALOG_P = 387, + CHAIN = 388, + CHAR_P = 389, + CHARACTER = 390, + CHARACTERISTICS = 391, + CHECK = 392, + CHECKPOINT = 393, + CLASS = 394, + CLOSE = 395, + CLUSTER = 396, + COALESCE = 397, + COLLATE = 398, + COLLATION = 399, + COLUMN = 400, + COMMENT = 401, + COMMENTS = 402, + COMMIT = 403, + COMMITTED = 404, + CONCURRENTLY = 405, + CONFIGURATION = 406, + CONNECTION = 407, + CONSTRAINT = 408, + CONSTRAINTS = 409, + CONTENT_P = 410, + CONTINUE_P = 411, + CONVERSION_P = 412, + COPY = 413, + COST = 414, + CREATE = 415, + CROSS = 416, + CSV = 417, + CURRENT_P = 418, + CURRENT_CATALOG = 419, + CURRENT_DATE = 420, + CURRENT_ROLE = 421, + CURRENT_SCHEMA = 422, + CURRENT_TIME = 423, + CURRENT_TIMESTAMP = 424, + CURRENT_USER = 425, + CURSOR = 426, + CYCLE = 427, + DATA_P = 428, + DATABASE = 429, + DAY_P = 430, + DEALLOCATE = 431, + DEC = 432, + DECIMAL_P = 433, + DECLARE = 434, + DEFAULT = 435, + DEFAULTS = 436, + DEFERRABLE = 437, + DEFERRED = 438, + DEFINER = 439, + DELETE_P = 440, + DELIMITER = 441, + DELIMITERS = 442, + DESC = 443, + DICTIONARY = 444, + DISABLE_P = 445, + DISCARD = 446, + DISTINCT = 447, + DO = 448, + DOCUMENT_P = 449, + DOMAIN_P = 450, + DOUBLE_P = 451, + DROP = 452, + EACH = 453, + ELSE = 454, + ENABLE_P = 455, + ENCODING = 456, + ENCRYPTED = 457, + END_P = 458, + ENUM_P = 459, + ESCAPE = 460, + EXCEPT = 461, + EXCLUDE = 462, + EXCLUDING = 463, + EXCLUSIVE = 464, + EXECUTE = 465, + EXISTS = 466, + EXPLAIN = 467, + EXTENSION = 468, + EXTERNAL = 469, + EXTRACT = 470, + FALSE_P = 471, + FAMILY = 472, + FETCH = 473, + FIRST_P = 474, + FLOAT_P = 475, + FOLLOWING = 476, + FOR = 477, + FORCE = 478, + FOREIGN = 479, + FORWARD = 480, + FREEZE = 481, + FROM = 482, + FULL = 483, + FUNCTION = 484, + FUNCTIONS = 485, + GLOBAL = 486, + GRANT = 487, + GRANTED = 488, + GREATEST = 489, + GROUP_P = 490, + HANDLER = 491, + HAVING = 492, + HEADER_P = 493, + HOLD = 494, + HOUR_P = 495, + IDENTITY_P = 496, + IF_P = 497, + ILIKE = 498, + IMMEDIATE = 499, + IMMUTABLE = 500, + IMPLICIT_P = 501, + IN_P = 502, + INCLUDING = 503, + INCREMENT = 504, + INDEX = 505, + INDEXES = 506, + INHERIT = 507, + INHERITS = 508, + INITIALLY = 509, + INLINE_P = 510, + INNER_P = 511, + INOUT = 512, + INPUT_P = 513, + INSENSITIVE = 514, + INSERT = 515, + INSTEAD = 516, + INT_P = 517, + INTEGER = 518, + INTERSECT = 519, + INTERVAL = 520, + INTO = 521, + INVOKER = 522, + IS = 523, + ISNULL = 524, + ISOLATION = 525, + JOIN = 526, + KEY = 527, + LABEL = 528, + LANGUAGE = 529, + LARGE_P = 530, + LAST_P = 531, + LC_COLLATE_P = 532, + LC_CTYPE_P = 533, + LEADING = 534, + LEAKPROOF = 535, + LEAST = 536, + LEFT = 537, + LEVEL = 538, + LIKE = 539, + LIMIT = 540, + LISTEN = 541, + LOAD = 542, + LOCAL = 543, + LOCALTIME = 544, + LOCALTIMESTAMP = 545, + LOCATION = 546, + LOCK_P = 547, + MAPPING = 548, + MATCH = 549, + MAXVALUE = 550, + MINUTE_P = 551, + MINVALUE = 552, + MODE = 553, + MONTH_P = 554, + MOVE = 555, + NAME_P = 556, + NAMES = 557, + NATIONAL = 558, + NATURAL = 559, + NCHAR = 560, + NEXT = 561, + NO = 562, + NONE = 563, + NOT = 564, + NOTHING = 565, + NOTIFY = 566, + NOTNULL = 567, + NOWAIT = 568, + NULL_P = 569, + NULLIF = 570, + NULLS_P = 571, + NUMERIC = 572, + OBJECT_P = 573, + OF = 574, + OFF = 575, + OFFSET = 576, + OIDS = 577, + ON = 578, + ONLY = 579, + OPERATOR = 580, + OPTION = 581, + OPTIONS = 582, + OR = 583, + ORDER = 584, + OUT_P = 585, + OUTER_P = 586, + OVER = 587, + OVERLAPS = 588, + OVERLAY = 589, + OWNED = 590, + OWNER = 591, + PARSER = 592, + PARTIAL = 593, + PARTITION = 594, + PASSING = 595, + PASSWORD = 596, + PLACING = 597, + PLANS = 598, + POSITION = 599, + PRECEDING = 600, + PRECISION = 601, + PRESERVE = 602, + PREPARE = 603, + PREPARED = 604, + PRIMARY = 605, + PRIOR = 606, + PRIVILEGES = 607, + PROCEDURAL = 608, + PROCEDURE = 609, + QUOTE = 610, + RANGE = 611, + READ = 612, + REAL = 613, + REASSIGN = 614, + RECHECK = 615, + RECURSIVE = 616, + REF = 617, + REFERENCES = 618, + REINDEX = 619, + RELATIVE_P = 620, + RELEASE = 621, + RENAME = 622, + REPEATABLE = 623, + REPLACE = 624, + REPLICA = 625, + RESET = 626, + RESTART = 627, + RESTRICT = 628, + RETURNING = 629, + RETURNS = 630, + REVOKE = 631, + RIGHT = 632, + ROLE = 633, + ROLLBACK = 634, + ROW = 635, + ROWS = 636, + RULE = 637, + SAVEPOINT = 638, + SCHEMA = 639, + SCROLL = 640, + SEARCH = 641, + SECOND_P = 642, + SECURITY = 643, + SELECT = 644, + SEQUENCE = 645, + SEQUENCES = 646, + SERIALIZABLE = 647, + SERVER = 648, + SESSION = 649, + SESSION_USER = 650, + SET = 651, + SETOF = 652, + SHARE = 653, + SHOW = 654, + SIMILAR = 655, + SIMPLE = 656, + SMALLINT = 657, + SNAPSHOT = 658, + SOME = 659, + STABLE = 660, + STANDALONE_P = 661, + START = 662, + STATEMENT = 663, + STATISTICS = 664, + STDIN = 665, + STDOUT = 666, + STORAGE = 667, + STRICT_P = 668, + STRIP_P = 669, + SUBSTRING = 670, + SYMMETRIC = 671, + SYSID = 672, + SYSTEM_P = 673, + TABLE = 674, + TABLES = 675, + TABLESPACE = 676, + TEMP = 677, + TEMPLATE = 678, + TEMPORARY = 679, + TEXT_P = 680, + THEN = 681, + TIME = 682, + TIMESTAMP = 683, + TO = 684, + TRAILING = 685, + TRANSACTION = 686, + TREAT = 687, + TRIGGER = 688, + TRIM = 689, + TRUE_P = 690, + TRUNCATE = 691, + TRUSTED = 692, + TYPE_P = 693, + TYPES_P = 694, + UNBOUNDED = 695, + UNCOMMITTED = 696, + UNENCRYPTED = 697, + UNION = 698, + UNIQUE = 699, + UNKNOWN = 700, + UNLISTEN = 701, + UNLOGGED = 702, + UNTIL = 703, + UPDATE = 704, + USER = 705, + USING = 706, + VACUUM = 707, + VALID = 708, + VALIDATE = 709, + VALIDATOR = 710, + VALUE_P = 711, + VALUES = 712, + VARCHAR = 713, + VARIADIC = 714, + VARYING = 715, + VERBOSE = 716, + VERSION_P = 717, + VIEW = 718, + VOLATILE = 719, + WHEN = 720, + WHERE = 721, + WHITESPACE_P = 722, + WINDOW = 723, + WITH = 724, + WITHOUT = 725, + WORK = 726, + WRAPPER = 727, + WRITE = 728, + XML_P = 729, + XMLATTRIBUTES = 730, + XMLCONCAT = 731, + XMLELEMENT = 732, + XMLEXISTS = 733, + XMLFOREST = 734, + XMLPARSE = 735, + XMLPI = 736, + XMLROOT = 737, + XMLSERIALIZE = 738, + YEAR_P = 739, + YES_P = 740, + ZONE = 741, + NULLS_FIRST = 742, + NULLS_LAST = 743, + WITH_TIME = 744, + POSTFIXOP = 745, + UMINUS = 746 + }; +#endif + + + +#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED +typedef union YYSTYPE +{ + +/* Line 214 of yacc.c */ +#line 564 "preproc.y" + + double dval; + char *str; + int ival; + struct when action; + struct index index; + int tagname; + struct this_type type; + enum ECPGttype type_enum; + enum ECPGdtype dtype_enum; + struct fetch_desc descriptor; + struct su_symbol struct_union; + struct prep prep; + + + +/* Line 214 of yacc.c */ +#line 1181 "preproc.c" +} YYSTYPE; +# define YYSTYPE_IS_TRIVIAL 1 +# define yystype YYSTYPE /* obsolescent; will be withdrawn */ +# define YYSTYPE_IS_DECLARED 1 +#endif + +#if ! defined YYLTYPE && ! defined YYLTYPE_IS_DECLARED +typedef struct YYLTYPE +{ + int first_line; + int first_column; + int last_line; + int last_column; +} YYLTYPE; +# define yyltype YYLTYPE /* obsolescent; will be withdrawn */ +# define YYLTYPE_IS_DECLARED 1 +# define YYLTYPE_IS_TRIVIAL 1 +#endif + + +/* Copy the second part of user declarations. */ + + +/* Line 264 of yacc.c */ +#line 1206 "preproc.c" + +#ifdef short +# undef short +#endif + +#ifdef YYTYPE_UINT8 +typedef YYTYPE_UINT8 yytype_uint8; +#else +typedef unsigned char yytype_uint8; +#endif + +#ifdef YYTYPE_INT8 +typedef YYTYPE_INT8 yytype_int8; +#elif (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +typedef signed char yytype_int8; +#else +typedef short int yytype_int8; +#endif + +#ifdef YYTYPE_UINT16 +typedef YYTYPE_UINT16 yytype_uint16; +#else +typedef unsigned short int yytype_uint16; +#endif + +#ifdef YYTYPE_INT16 +typedef YYTYPE_INT16 yytype_int16; +#else +typedef short int yytype_int16; +#endif + +#ifndef YYSIZE_T +# ifdef __SIZE_TYPE__ +# define YYSIZE_T __SIZE_TYPE__ +# elif defined size_t +# define YYSIZE_T size_t +# elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +# include /* INFRINGES ON USER NAME SPACE */ +# define YYSIZE_T size_t +# else +# define YYSIZE_T unsigned int +# endif +#endif + +#define YYSIZE_MAXIMUM ((YYSIZE_T) -1) + +#ifndef YY_ +# if YYENABLE_NLS +# if ENABLE_NLS +# include /* INFRINGES ON USER NAME SPACE */ +# define YY_(msgid) dgettext ("bison-runtime", msgid) +# endif +# endif +# ifndef YY_ +# define YY_(msgid) msgid +# endif +#endif + +/* Suppress unused-variable warnings by "using" E. */ +#if ! defined lint || defined __GNUC__ +# define YYUSE(e) ((void) (e)) +#else +# define YYUSE(e) /* empty */ +#endif + +/* Identity function, used to suppress warnings about constant conditions. */ +#ifndef lint +# define YYID(n) (n) +#else +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static int +YYID (int yyi) +#else +static int +YYID (yyi) + int yyi; +#endif +{ + return yyi; +} +#endif + +#if ! defined yyoverflow || YYERROR_VERBOSE + +/* The parser invokes alloca or malloc; define the necessary symbols. */ + +# ifdef YYSTACK_USE_ALLOCA +# if YYSTACK_USE_ALLOCA +# ifdef __GNUC__ +# define YYSTACK_ALLOC __builtin_alloca +# elif defined __BUILTIN_VA_ARG_INCR +# include /* INFRINGES ON USER NAME SPACE */ +# elif defined _AIX +# define YYSTACK_ALLOC __alloca +# elif defined _MSC_VER +# include /* INFRINGES ON USER NAME SPACE */ +# define alloca _alloca +# else +# define YYSTACK_ALLOC alloca +# if ! defined _ALLOCA_H && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +# include /* INFRINGES ON USER NAME SPACE */ +# ifndef _STDLIB_H +# define _STDLIB_H 1 +# endif +# endif +# endif +# endif +# endif + +# ifdef YYSTACK_ALLOC + /* Pacify GCC's `empty if-body' warning. */ +# define YYSTACK_FREE(Ptr) do { /* empty */; } while (YYID (0)) +# ifndef YYSTACK_ALLOC_MAXIMUM + /* The OS might guarantee only one guard page at the bottom of the stack, + and a page size can be as small as 4096 bytes. So we cannot safely + invoke alloca (N) if N exceeds 4096. Use a slightly smaller number + to allow for a few compiler-allocated temporary stack slots. */ +# define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */ +# endif +# else +# define YYSTACK_ALLOC YYMALLOC +# define YYSTACK_FREE YYFREE +# ifndef YYSTACK_ALLOC_MAXIMUM +# define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM +# endif +# if (defined __cplusplus && ! defined _STDLIB_H \ + && ! ((defined YYMALLOC || defined malloc) \ + && (defined YYFREE || defined free))) +# include /* INFRINGES ON USER NAME SPACE */ +# ifndef _STDLIB_H +# define _STDLIB_H 1 +# endif +# endif +# ifndef YYMALLOC +# define YYMALLOC malloc +# if ! defined malloc && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */ +# endif +# endif +# ifndef YYFREE +# define YYFREE free +# if ! defined free && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +void free (void *); /* INFRINGES ON USER NAME SPACE */ +# endif +# endif +# endif +#endif /* ! defined yyoverflow || YYERROR_VERBOSE */ + + +#if (! defined yyoverflow \ + && (! defined __cplusplus \ + || (defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL \ + && defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) + +/* A type that is properly aligned for any stack member. */ +union yyalloc +{ + yytype_int16 yyss_alloc; + YYSTYPE yyvs_alloc; + YYLTYPE yyls_alloc; +}; + +/* The size of the maximum gap between one aligned stack and the next. */ +# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1) + +/* The size of an array large to enough to hold all stacks, each with + N elements. */ +# define YYSTACK_BYTES(N) \ + ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE) + sizeof (YYLTYPE)) \ + + 2 * YYSTACK_GAP_MAXIMUM) + +/* Copy COUNT objects from FROM to TO. The source and destination do + not overlap. */ +# ifndef YYCOPY +# if defined __GNUC__ && 1 < __GNUC__ +# define YYCOPY(To, From, Count) \ + __builtin_memcpy (To, From, (Count) * sizeof (*(From))) +# else +# define YYCOPY(To, From, Count) \ + do \ + { \ + YYSIZE_T yyi; \ + for (yyi = 0; yyi < (Count); yyi++) \ + (To)[yyi] = (From)[yyi]; \ + } \ + while (YYID (0)) +# endif +# endif + +/* Relocate STACK from its old location to the new one. The + local variables YYSIZE and YYSTACKSIZE give the old and new number of + elements in the stack, and YYPTR gives the new location of the + stack. Advance YYPTR to a properly aligned location for the next + stack. */ +# define YYSTACK_RELOCATE(Stack_alloc, Stack) \ + do \ + { \ + YYSIZE_T yynewbytes; \ + YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \ + Stack = &yyptr->Stack_alloc; \ + yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ + yyptr += yynewbytes / sizeof (*yyptr); \ + } \ + while (YYID (0)) + +#endif + +/* YYFINAL -- State number of the termination state. */ +#define YYFINAL 3 +/* YYLAST -- Last index in YYTABLE. */ +#define YYLAST 103637 + +/* YYNTOKENS -- Number of terminals. */ +#define YYNTOKENS 511 +/* YYNNTS -- Number of nonterminals. */ +#define YYNNTS 686 +/* YYNRULES -- Number of rules. */ +#define YYNRULES 2729 +/* YYNRULES -- Number of states. */ +#define YYNSTATES 4944 + +/* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */ +#define YYUNDEFTOK 2 +#define YYMAXUTOK 746 + +#define YYTRANSLATE(YYX) \ + ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) + +/* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */ +static const yytype_uint16 yytranslate[] = +{ + 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 498, 2, 2, + 503, 504, 496, 494, 506, 495, 505, 497, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 508, 507, + 491, 490, 492, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 501, 2, 502, 499, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 509, 2, 510, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 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, 92, 93, 94, + 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, + 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, + 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, + 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, + 135, 136, 137, 138, 139, 140, 141, 142, 143, 144, + 145, 146, 147, 148, 149, 150, 151, 152, 153, 154, + 155, 156, 157, 158, 159, 160, 161, 162, 163, 164, + 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, + 175, 176, 177, 178, 179, 180, 181, 182, 183, 184, + 185, 186, 187, 188, 189, 190, 191, 192, 193, 194, + 195, 196, 197, 198, 199, 200, 201, 202, 203, 204, + 205, 206, 207, 208, 209, 210, 211, 212, 213, 214, + 215, 216, 217, 218, 219, 220, 221, 222, 223, 224, + 225, 226, 227, 228, 229, 230, 231, 232, 233, 234, + 235, 236, 237, 238, 239, 240, 241, 242, 243, 244, + 245, 246, 247, 248, 249, 250, 251, 252, 253, 254, + 255, 256, 257, 258, 259, 260, 261, 262, 263, 264, + 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, + 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, + 285, 286, 287, 288, 289, 290, 291, 292, 293, 294, + 295, 296, 297, 298, 299, 300, 301, 302, 303, 304, + 305, 306, 307, 308, 309, 310, 311, 312, 313, 314, + 315, 316, 317, 318, 319, 320, 321, 322, 323, 324, + 325, 326, 327, 328, 329, 330, 331, 332, 333, 334, + 335, 336, 337, 338, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 351, 352, 353, 354, + 355, 356, 357, 358, 359, 360, 361, 362, 363, 364, + 365, 366, 367, 368, 369, 370, 371, 372, 373, 374, + 375, 376, 377, 378, 379, 380, 381, 382, 383, 384, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, + 415, 416, 417, 418, 419, 420, 421, 422, 423, 424, + 425, 426, 427, 428, 429, 430, 431, 432, 433, 434, + 435, 436, 437, 438, 439, 440, 441, 442, 443, 444, + 445, 446, 447, 448, 449, 450, 451, 452, 453, 454, + 455, 456, 457, 458, 459, 460, 461, 462, 463, 464, + 465, 466, 467, 468, 469, 470, 471, 472, 473, 474, + 475, 476, 477, 478, 479, 480, 481, 482, 483, 484, + 485, 486, 487, 488, 489, 493, 500 +}; + +#if YYDEBUG +/* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in + YYRHS. */ +static const yytype_uint16 yyprhs[] = +{ + 0, 0, 3, 5, 7, 9, 11, 13, 15, 17, + 19, 21, 23, 25, 27, 29, 31, 33, 35, 37, + 39, 41, 43, 45, 47, 49, 51, 53, 55, 57, + 59, 61, 63, 65, 67, 69, 71, 73, 75, 77, + 79, 81, 83, 85, 87, 89, 91, 93, 95, 97, + 99, 101, 103, 105, 107, 109, 111, 113, 115, 117, + 119, 121, 123, 125, 127, 129, 131, 133, 135, 137, + 139, 141, 143, 145, 147, 149, 151, 153, 155, 157, + 159, 161, 163, 165, 167, 169, 171, 173, 175, 177, + 179, 181, 183, 185, 187, 189, 191, 193, 195, 197, + 199, 201, 203, 205, 207, 209, 211, 213, 215, 217, + 219, 221, 223, 225, 227, 229, 231, 233, 235, 237, + 239, 241, 243, 245, 247, 249, 251, 253, 255, 257, + 259, 261, 263, 264, 270, 272, 273, 276, 277, 280, + 281, 284, 287, 291, 295, 297, 301, 305, 308, 310, + 312, 315, 318, 321, 325, 329, 335, 341, 342, 346, + 352, 358, 363, 367, 373, 377, 383, 389, 396, 398, + 400, 404, 410, 417, 422, 424, 425, 428, 429, 431, + 433, 435, 437, 439, 441, 444, 448, 452, 455, 461, + 463, 467, 471, 475, 479, 483, 487, 490, 493, 496, + 499, 503, 507, 511, 515, 517, 521, 523, 527, 529, + 531, 534, 537, 540, 542, 544, 546, 548, 550, 552, + 554, 558, 565, 567, 569, 571, 573, 575, 576, 578, + 580, 583, 587, 592, 596, 599, 602, 604, 607, 609, + 613, 618, 624, 629, 632, 637, 639, 641, 643, 645, + 647, 650, 653, 656, 659, 664, 671, 676, 683, 688, + 695, 700, 707, 709, 713, 716, 720, 725, 732, 739, + 746, 752, 758, 765, 772, 777, 786, 791, 794, 798, + 805, 810, 814, 818, 822, 826, 830, 835, 840, 844, + 848, 852, 856, 860, 864, 869, 874, 878, 881, 885, + 888, 891, 895, 899, 902, 905, 907, 911, 914, 916, + 918, 919, 922, 923, 926, 927, 931, 934, 935, 937, + 941, 945, 947, 953, 957, 962, 964, 968, 973, 980, + 985, 994, 997, 1000, 1011, 1018, 1020, 1022, 1024, 1026, + 1028, 1030, 1034, 1037, 1038, 1040, 1042, 1046, 1050, 1052, + 1054, 1058, 1062, 1066, 1070, 1075, 1078, 1080, 1081, 1084, + 1085, 1089, 1090, 1092, 1093, 1095, 1099, 1102, 1104, 1106, + 1108, 1112, 1113, 1115, 1119, 1121, 1133, 1148, 1159, 1173, + 1175, 1177, 1180, 1183, 1186, 1189, 1191, 1192, 1194, 1195, + 1199, 1200, 1202, 1206, 1208, 1212, 1214, 1216, 1218, 1220, + 1222, 1227, 1232, 1235, 1236, 1240, 1242, 1244, 1247, 1250, + 1252, 1256, 1261, 1267, 1270, 1276, 1278, 1281, 1284, 1287, + 1291, 1295, 1299, 1300, 1302, 1304, 1306, 1308, 1310, 1312, + 1316, 1318, 1324, 1332, 1336, 1345, 1350, 1360, 1372, 1375, + 1376, 1380, 1381, 1383, 1387, 1389, 1392, 1395, 1398, 1399, + 1401, 1405, 1409, 1416, 1421, 1422, 1424, 1426, 1429, 1432, + 1433, 1437, 1441, 1444, 1446, 1448, 1451, 1454, 1459, 1460, + 1463, 1466, 1469, 1470, 1474, 1479, 1484, 1485, 1488, 1489, + 1494, 1495, 1499, 1505, 1508, 1512, 1513, 1519, 1524, 1531, + 1533, 1534, 1536, 1539, 1542, 1544, 1547, 1551, 1554, 1557, + 1560, 1563, 1567, 1571, 1573, 1577, 1579, 1580, 1582, 1585, + 1587, 1589, 1593, 1600, 1611, 1613, 1614, 1616, 1619, 1622, + 1623, 1626, 1629, 1631, 1632, 1638, 1646, 1648, 1649, 1656, + 1659, 1660, 1664, 1670, 1676, 1685, 1688, 1689, 1692, 1695, + 1698, 1704, 1707, 1708, 1711, 1719, 1730, 1737, 1744, 1751, + 1758, 1766, 1774, 1784, 1794, 1801, 1808, 1817, 1826, 1835, + 1844, 1851, 1858, 1866, 1875, 1882, 1889, 1897, 1900, 1903, + 1906, 1909, 1911, 1914, 1916, 1917, 1924, 1933, 1941, 1948, + 1953, 1954, 1956, 1960, 1965, 1967, 1971, 1973, 1976, 1979, + 1982, 1985, 1987, 1989, 2000, 2003, 2004, 2007, 2010, 2012, + 2013, 2018, 2025, 2031, 2036, 2041, 2050, 2062, 2066, 2069, + 2071, 2075, 2077, 2083, 2091, 2100, 2102, 2104, 2106, 2114, + 2124, 2133, 2149, 2170, 2172, 2174, 2177, 2179, 2183, 2185, + 2187, 2189, 2193, 2195, 2199, 2200, 2202, 2203, 2205, 2207, + 2212, 2213, 2215, 2219, 2220, 2222, 2224, 2226, 2228, 2231, + 2232, 2233, 2236, 2239, 2241, 2244, 2247, 2250, 2253, 2260, + 2269, 2278, 2283, 2289, 2294, 2299, 2304, 2308, 2316, 2325, + 2332, 2339, 2346, 2353, 2360, 2365, 2371, 2375, 2377, 2381, + 2385, 2387, 2389, 2391, 2393, 2395, 2397, 2401, 2405, 2409, + 2411, 2415, 2419, 2421, 2422, 2424, 2428, 2435, 2444, 2453, + 2467, 2469, 2473, 2479, 2486, 2491, 2499, 2502, 2504, 2505, + 2508, 2509, 2512, 2517, 2518, 2520, 2521, 2528, 2537, 2546, + 2548, 2552, 2558, 2564, 2572, 2582, 2590, 2600, 2606, 2613, + 2620, 2625, 2631, 2639, 2641, 2643, 2645, 2647, 2650, 2652, + 2654, 2656, 2658, 2660, 2662, 2666, 2670, 2674, 2678, 2680, + 2684, 2686, 2689, 2692, 2696, 2702, 2705, 2708, 2709, 2716, + 2724, 2732, 2740, 2749, 2758, 2765, 2774, 2784, 2794, 2802, + 2813, 2821, 2830, 2839, 2848, 2857, 2859, 2861, 2863, 2865, + 2867, 2869, 2871, 2873, 2875, 2877, 2879, 2881, 2883, 2885, + 2888, 2890, 2894, 2896, 2898, 2907, 2917, 2927, 2937, 2947, + 2950, 2951, 2953, 2955, 2958, 2960, 2962, 2964, 2966, 2968, + 2970, 2972, 2974, 2976, 2978, 2981, 2984, 2988, 2993, 2999, + 3004, 3010, 3014, 3019, 3023, 3028, 3030, 3033, 3037, 3041, + 3045, 3049, 3054, 3059, 3063, 3067, 3072, 3077, 3082, 3087, + 3089, 3091, 3093, 3094, 3102, 3110, 3121, 3123, 3125, 3128, + 3133, 3139, 3141, 3145, 3148, 3151, 3154, 3157, 3159, 3162, + 3165, 3170, 3174, 3177, 3180, 3183, 3186, 3190, 3193, 3196, + 3199, 3205, 3211, 3217, 3219, 3223, 3225, 3228, 3232, 3233, + 3235, 3239, 3242, 3249, 3256, 3266, 3270, 3271, 3275, 3276, + 3282, 3285, 3286, 3290, 3294, 3298, 3306, 3314, 3325, 3327, + 3329, 3331, 3333, 3348, 3350, 3351, 3353, 3354, 3356, 3357, + 3360, 3361, 3363, 3367, 3373, 3379, 3387, 3390, 3391, 3393, + 3396, 3397, 3399, 3401, 3402, 3404, 3406, 3407, 3417, 3430, + 3438, 3441, 3442, 3446, 3449, 3451, 3455, 3459, 3462, 3464, + 3468, 3472, 3476, 3479, 3482, 3484, 3486, 3488, 3490, 3493, + 3495, 3497, 3499, 3501, 3506, 3512, 3514, 3518, 3522, 3524, + 3527, 3532, 3538, 3540, 3542, 3544, 3546, 3550, 3554, 3557, + 3560, 3562, 3565, 3568, 3571, 3573, 3576, 3579, 3581, 3583, + 3585, 3589, 3592, 3593, 3596, 3598, 3602, 3608, 3610, 3613, + 3615, 3616, 3622, 3630, 3636, 3644, 3650, 3658, 3662, 3668, + 3674, 3680, 3682, 3686, 3689, 3691, 3694, 3696, 3699, 3711, + 3722, 3733, 3736, 3739, 3740, 3750, 3753, 3754, 3759, 3764, + 3769, 3771, 3773, 3775, 3776, 3784, 3791, 3798, 3805, 3812, + 3821, 3830, 3837, 3844, 3852, 3862, 3872, 3879, 3886, 3893, + 3902, 3909, 3918, 3925, 3934, 3941, 3950, 3958, 3968, 3977, + 3988, 3997, 4007, 4019, 4028, 4035, 4042, 4049, 4055, 4061, + 4070, 4079, 4088, 4097, 4104, 4114, 4116, 4117, 4120, 4121, + 4129, 4136, 4143, 4150, 4157, 4164, 4172, 4182, 4192, 4199, + 4208, 4217, 4226, 4235, 4244, 4251, 4260, 4267, 4276, 4284, + 4294, 4301, 4309, 4316, 4323, 4330, 4337, 4344, 4352, 4360, + 4368, 4378, 4388, 4395, 4402, 4409, 4418, 4427, 4436, 4443, + 4457, 4459, 4461, 4465, 4469, 4471, 4473, 4475, 4477, 4479, + 4481, 4483, 4484, 4486, 4488, 4490, 4492, 4494, 4496, 4497, + 4504, 4513, 4517, 4520, 4521, 4524, 4527, 4530, 4533, 4537, + 4541, 4544, 4547, 4550, 4553, 4557, 4560, 4566, 4571, 4575, + 4579, 4583, 4585, 4587, 4588, 4592, 4595, 4598, 4600, 4603, + 4605, 4609, 4612, 4614, 4615, 4625, 4637, 4641, 4646, 4651, + 4652, 4655, 4661, 4664, 4665, 4669, 4673, 4677, 4681, 4685, + 4689, 4693, 4697, 4701, 4705, 4709, 4713, 4717, 4722, 4726, + 4730, 4732, 4733, 4739, 4746, 4751, 4754, 4755, 4760, 4764, + 4770, 4777, 4782, 4789, 4796, 4802, 4810, 4820, 4827, 4829, + 4830, 4837, 4849, 4861, 4873, 4887, 4897, 4909, 4920, 4925, + 4928, 4934, 4937, 4938, 4943, 4949, 4955, 4960, 4967, 4969, + 4973, 4975, 4977, 4979, 4981, 4984, 4989, 4991, 4993, 4995, + 4996, 4998, 4999, 5001, 5002, 5006, 5007, 5010, 5015, 5019, + 5025, 5027, 5029, 5031, 5033, 5035, 5037, 5039, 5041, 5045, + 5048, 5050, 5052, 5054, 5056, 5058, 5059, 5065, 5070, 5074, + 5075, 5077, 5079, 5081, 5083, 5088, 5098, 5102, 5103, 5110, + 5112, 5117, 5120, 5122, 5126, 5129, 5133, 5134, 5142, 5145, + 5146, 5152, 5156, 5157, 5160, 5163, 5166, 5170, 5172, 5176, + 5178, 5181, 5183, 5184, 5193, 5195, 5199, 5201, 5203, 5207, + 5213, 5216, 5218, 5222, 5230, 5232, 5234, 5235, 5239, 5242, + 5245, 5248, 5249, 5252, 5255, 5257, 5259, 5263, 5267, 5269, + 5272, 5277, 5282, 5285, 5289, 5295, 5301, 5303, 5305, 5315, + 5317, 5320, 5325, 5330, 5335, 5338, 5342, 5344, 5348, 5355, + 5357, 5358, 5361, 5363, 5364, 5368, 5372, 5377, 5382, 5387, + 5392, 5396, 5399, 5401, 5403, 5404, 5406, 5408, 5409, 5411, + 5417, 5419, 5420, 5422, 5423, 5427, 5429, 5433, 5438, 5442, + 5445, 5448, 5450, 5452, 5454, 5455, 5458, 5463, 5469, 5472, + 5476, 5478, 5480, 5482, 5484, 5488, 5489, 5491, 5493, 5495, + 5497, 5499, 5503, 5504, 5507, 5508, 5510, 5514, 5516, 5517, + 5519, 5522, 5527, 5532, 5535, 5536, 5539, 5543, 5546, 5547, + 5549, 5553, 5555, 5558, 5560, 5563, 5569, 5576, 5582, 5584, + 5587, 5589, 5594, 5598, 5603, 5609, 5614, 5620, 5625, 5631, + 5634, 5639, 5641, 5644, 5647, 5650, 5652, 5654, 5655, 5660, + 5663, 5665, 5668, 5671, 5676, 5678, 5682, 5684, 5687, 5691, + 5693, 5696, 5697, 5700, 5705, 5706, 5708, 5709, 5711, 5715, + 5719, 5722, 5726, 5732, 5739, 5742, 5746, 5750, 5755, 5756, + 5758, 5760, 5762, 5764, 5766, 5769, 5775, 5777, 5779, 5781, + 5783, 5786, 5790, 5794, 5795, 5797, 5799, 5801, 5803, 5805, + 5808, 5811, 5814, 5817, 5820, 5822, 5826, 5827, 5829, 5831, + 5833, 5835, 5841, 5844, 5846, 5848, 5850, 5852, 5858, 5861, + 5864, 5867, 5869, 5873, 5877, 5880, 5882, 5883, 5887, 5888, + 5894, 5897, 5903, 5906, 5908, 5911, 5915, 5916, 5918, 5920, + 5922, 5924, 5926, 5928, 5932, 5936, 5940, 5944, 5948, 5952, + 5956, 5957, 5959, 5964, 5966, 5970, 5974, 5980, 5983, 5986, + 5990, 5994, 5998, 6002, 6006, 6010, 6014, 6018, 6022, 6026, + 6029, 6032, 6036, 6040, 6043, 6047, 6053, 6058, 6065, 6069, + 6075, 6080, 6087, 6092, 6099, 6105, 6113, 6117, 6120, 6125, + 6128, 6132, 6136, 6141, 6145, 6150, 6154, 6159, 6165, 6172, + 6179, 6187, 6194, 6202, 6209, 6217, 6221, 6226, 6231, 6238, + 6241, 6245, 6250, 6252, 6256, 6259, 6262, 6266, 6270, 6274, + 6278, 6282, 6286, 6290, 6294, 6298, 6302, 6305, 6308, 6314, + 6321, 6328, 6336, 6340, 6345, 6347, 6349, 6352, 6357, 6359, + 6361, 6363, 6366, 6369, 6372, 6374, 6379, 6385, 6392, 6401, + 6408, 6416, 6424, 6430, 6436, 6438, 6440, 6445, 6447, 6452, + 6454, 6459, 6461, 6466, 6468, 6470, 6472, 6474, 6476, 6478, + 6485, 6490, 6495, 6500, 6505, 6512, 6518, 6524, 6530, 6535, + 6542, 6547, 6552, 6557, 6562, 6568, 6576, 6584, 6594, 6600, + 6605, 6612, 6618, 6626, 6634, 6642, 6645, 6649, 6653, 6657, + 6662, 6663, 6668, 6670, 6674, 6678, 6680, 6682, 6684, 6687, + 6690, 6691, 6694, 6699, 6704, 6711, 6714, 6715, 6717, 6721, + 6725, 6728, 6731, 6732, 6739, 6741, 6742, 6746, 6747, 6750, + 6753, 6754, 6756, 6761, 6764, 6767, 6770, 6773, 6776, 6781, + 6785, 6791, 6793, 6795, 6797, 6799, 6801, 6803, 6805, 6807, + 6809, 6811, 6813, 6815, 6817, 6819, 6821, 6826, 6828, 6833, + 6835, 6840, 6842, 6845, 6847, 6850, 6852, 6856, 6858, 6862, + 6864, 6868, 6870, 6874, 6878, 6882, 6885, 6887, 6891, 6895, + 6896, 6898, 6900, 6902, 6904, 6906, 6908, 6910, 6912, 6917, + 6921, 6924, 6928, 6929, 6933, 6937, 6940, 6943, 6945, 6946, + 6949, 6952, 6956, 6959, 6961, 6963, 6967, 6973, 6975, 6978, + 6983, 6986, 6987, 6989, 6990, 6992, 6995, 6998, 7001, 7005, + 7011, 7013, 7016, 7017, 7020, 7022, 7023, 7025, 7027, 7029, + 7033, 7037, 7039, 7043, 7047, 7050, 7052, 7054, 7056, 7060, + 7062, 7065, 7067, 7071, 7073, 7075, 7077, 7079, 7081, 7083, + 7085, 7088, 7090, 7092, 7094, 7096, 7098, 7101, 7107, 7110, + 7114, 7121, 7123, 7125, 7127, 7129, 7131, 7133, 7135, 7137, + 7139, 7142, 7145, 7147, 7149, 7151, 7153, 7155, 7157, 7159, + 7161, 7163, 7165, 7167, 7169, 7171, 7173, 7175, 7177, 7179, + 7181, 7183, 7185, 7187, 7189, 7191, 7193, 7195, 7197, 7199, + 7201, 7203, 7205, 7207, 7209, 7211, 7213, 7215, 7217, 7219, + 7221, 7223, 7225, 7227, 7229, 7231, 7233, 7235, 7237, 7239, + 7241, 7243, 7245, 7247, 7249, 7251, 7253, 7255, 7257, 7259, + 7261, 7263, 7265, 7267, 7269, 7271, 7273, 7275, 7277, 7279, + 7281, 7283, 7285, 7287, 7289, 7291, 7293, 7295, 7297, 7299, + 7301, 7303, 7305, 7307, 7309, 7311, 7313, 7315, 7317, 7319, + 7321, 7323, 7325, 7327, 7329, 7331, 7333, 7335, 7337, 7339, + 7341, 7343, 7345, 7347, 7349, 7351, 7353, 7355, 7357, 7359, + 7361, 7363, 7365, 7367, 7369, 7371, 7373, 7375, 7377, 7379, + 7381, 7383, 7385, 7387, 7389, 7391, 7393, 7395, 7397, 7399, + 7401, 7403, 7405, 7407, 7409, 7411, 7413, 7415, 7417, 7419, + 7421, 7423, 7425, 7427, 7429, 7431, 7433, 7435, 7437, 7439, + 7441, 7443, 7445, 7447, 7449, 7451, 7453, 7455, 7457, 7459, + 7461, 7463, 7465, 7467, 7469, 7471, 7473, 7475, 7477, 7479, + 7481, 7483, 7485, 7487, 7489, 7491, 7493, 7495, 7497, 7499, + 7501, 7503, 7505, 7507, 7509, 7511, 7513, 7515, 7517, 7519, + 7521, 7523, 7525, 7527, 7529, 7531, 7533, 7535, 7537, 7539, + 7541, 7543, 7545, 7547, 7549, 7551, 7553, 7555, 7557, 7559, + 7561, 7563, 7565, 7567, 7569, 7571, 7573, 7575, 7577, 7579, + 7581, 7583, 7585, 7587, 7589, 7591, 7593, 7595, 7597, 7599, + 7601, 7603, 7605, 7607, 7609, 7611, 7613, 7615, 7617, 7619, + 7621, 7623, 7625, 7627, 7629, 7631, 7633, 7635, 7637, 7639, + 7641, 7643, 7645, 7647, 7649, 7651, 7653, 7655, 7657, 7659, + 7661, 7663, 7665, 7667, 7669, 7671, 7673, 7675, 7677, 7679, + 7681, 7683, 7685, 7687, 7689, 7691, 7693, 7695, 7697, 7699, + 7701, 7703, 7705, 7707, 7709, 7711, 7713, 7715, 7717, 7719, + 7721, 7723, 7725, 7727, 7729, 7731, 7733, 7735, 7737, 7739, + 7741, 7743, 7745, 7747, 7749, 7751, 7753, 7755, 7757, 7759, + 7761, 7763, 7765, 7767, 7769, 7771, 7773, 7775, 7777, 7779, + 7781, 7783, 7785, 7787, 7789, 7791, 7793, 7795, 7797, 7799, + 7801, 7803, 7805, 7807, 7809, 7811, 7813, 7815, 7817, 7819, + 7821, 7823, 7825, 7827, 7829, 7831, 7833, 7835, 7837, 7839, + 7841, 7843, 7845, 7847, 7849, 7851, 7853, 7855, 7857, 7859, + 7861, 7863, 7865, 7867, 7869, 7871, 7873, 7875, 7877, 7879, + 7881, 7883, 7885, 7887, 7889, 7891, 7893, 7895, 7897, 7899, + 7901, 7903, 7905, 7907, 7909, 7910, 7913, 7918, 7922, 7925, + 7927, 7929, 7931, 7933, 7935, 7936, 7945, 7948, 7954, 7958, + 7961, 7964, 7968, 7976, 7978, 7980, 7982, 7983, 7986, 7989, + 7991, 7992, 7994, 7998, 8000, 8003, 8004, 8007, 8008, 8011, + 8012, 8014, 8018, 8023, 8027, 8029, 8031, 8033, 8035, 8038, + 8039, 8042, 8047, 8048, 8051, 8054, 8057, 8059, 8061, 8069, + 8073, 8075, 8077, 8079, 8081, 8084, 8085, 8087, 8091, 8095, + 8099, 8103, 8104, 8109, 8115, 8121, 8122, 8124, 8126, 8128, + 8131, 8134, 8136, 8139, 8140, 8148, 8149, 8155, 8156, 8161, + 8164, 8167, 8168, 8171, 8173, 8175, 8177, 8179, 8181, 8183, + 8185, 8187, 8189, 8191, 8193, 8199, 8202, 8204, 8208, 8211, + 8214, 8218, 8219, 8225, 8227, 8228, 8234, 8237, 8240, 8242, + 8244, 8246, 8249, 8252, 8256, 8258, 8261, 8264, 8268, 8272, + 8277, 8280, 8282, 8285, 8287, 8289, 8292, 8295, 8299, 8301, + 8303, 8305, 8307, 8308, 8310, 8314, 8320, 8321, 8324, 8325, + 8327, 8330, 8334, 8337, 8339, 8341, 8343, 8344, 8346, 8348, + 8350, 8352, 8354, 8357, 8360, 8364, 8365, 8367, 8370, 8372, + 8377, 8381, 8386, 8390, 8393, 8395, 8399, 8401, 8403, 8405, + 8407, 8410, 8413, 8415, 8418, 8421, 8423, 8425, 8427, 8432, + 8437, 8442, 8447, 8452, 8454, 8455, 8459, 8463, 8468, 8470, + 8474, 8478, 8483, 8485, 8489, 8493, 8495, 8497, 8499, 8506, + 8508, 8512, 8516, 8523, 8525, 8529, 8533, 8535, 8537, 8540, + 8543, 8545, 8547, 8549, 8551, 8553, 8555, 8557, 8559, 8561, + 8563, 8565, 8567, 8569, 8571, 8573, 8575, 8580, 8585, 8587, + 8589, 8594, 8599, 8603, 8604, 8612, 8614, 8615, 8616, 8624, + 8628, 8633, 8637, 8639, 8641, 8643, 8646, 8650, 8656, 8659, + 8665, 8668, 8670, 8672, 8674, 8676, 8678, 8680, 8682, 8684, + 8686, 8688, 8690, 8692, 8694, 8696, 8698, 8700, 8702, 8704, + 8706, 8708, 8710, 8712, 8714, 8716, 8718, 8720, 8722, 8724, + 8726, 8728, 8730, 8732, 8734, 8736, 8738, 8740, 8742, 8744, + 8746, 8748, 8750, 8752, 8754, 8756, 8758, 8760, 8762, 8764, + 8766, 8768, 8770, 8772, 8774, 8776, 8778, 8780, 8782, 8784, + 8786, 8788, 8790, 8792, 8794, 8796, 8798, 8800, 8802, 8804, + 8806, 8808, 8810, 8812, 8814, 8816, 8818, 8820, 8822, 8824, + 8826, 8828, 8830, 8832, 8834, 8836, 8838, 8840, 8842, 8844, + 8846, 8848, 8850, 8852, 8854, 8856, 8858, 8860, 8862, 8864, + 8868, 8870, 8871, 8873, 8876, 8878, 8881, 8883, 8885, 8887, + 8890, 8893, 8895, 8897, 8899, 8901, 8903, 8905, 8907, 8909, + 8911, 8913, 8915, 8917, 8919, 8921, 8923, 8925, 8928, 8932, + 8934, 8937, 8939, 8943, 8945, 8949, 8951, 8953, 8955, 8957, + 8959, 8961, 8963, 8965, 8967, 8969, 8971, 8973, 8975, 8977, + 8979, 8981, 8983, 8985, 8987, 8989, 8991, 8993, 8995, 8997, + 8999, 9001, 9003, 9005, 9007, 9009, 9011, 9013, 9015, 9017, + 9019, 9021, 9023, 9025, 9027, 9029, 9031, 9033, 9035, 9037, + 9039, 9041, 9043, 9045, 9047, 9049, 9051, 9053, 9055, 9057, + 9059, 9061, 9063, 9065, 9067, 9069, 9071, 9074, 9078, 9081, + 9085, 9087, 9091, 9095, 9099, 9103, 9107, 9111, 9113, 9115, + 9116, 9119, 9122, 9124, 9126, 9129, 9131, 9133, 9135, 9136 +}; + +/* YYRHS -- A `-1'-separated list of the rules' RHS. */ +static const yytype_int16 yyrhs[] = +{ + 512, 0, -1, 1048, -1, 838, -1, 839, -1, 756, + -1, 844, -1, 707, -1, 647, -1, 650, -1, 656, + -1, 670, -1, 675, -1, 791, -1, 529, -1, 812, + -1, 813, -1, 626, -1, 556, -1, 567, -1, 523, + -1, 521, -1, 847, -1, 846, -1, 679, -1, 525, + -1, 524, -1, 854, -1, 554, -1, 570, -1, 849, + -1, 730, -1, 551, -1, 571, -1, 1050, -1, 694, + -1, 802, -1, 848, -1, 843, -1, 644, -1, 651, + -1, 665, -1, 671, -1, 772, -1, 528, -1, 708, + -1, 715, -1, 716, -1, 633, -1, 532, -1, 625, + -1, 586, -1, 641, -1, 680, -1, 514, -1, 520, + -1, 676, -1, 834, -1, 1191, -1, 889, -1, 696, + -1, 876, -1, 555, -1, 799, -1, 695, -1, 804, + -1, 655, -1, 669, -1, 531, -1, 719, -1, 720, + -1, 721, -1, 639, -1, 821, -1, 723, -1, 643, + -1, 693, -1, 526, -1, 527, -1, 678, -1, 842, + -1, 869, -1, 860, -1, 737, -1, 741, -1, 752, + -1, 761, -1, 871, -1, 824, -1, 833, -1, 878, + -1, 822, -1, 866, -1, 722, -1, 806, -1, 795, + -1, 794, -1, 796, -1, 809, -1, 742, -1, 753, + -1, 814, -1, 733, -1, 893, -1, 826, -1, 728, + -1, 825, -1, 882, -1, 851, -1, 547, -1, 536, + -1, 550, -1, 831, -1, 1127, -1, 1053, -1, 1070, + -1, 1128, -1, 1110, -1, 1125, -1, 1111, -1, 1071, + -1, 1115, -1, 1137, -1, 1129, -1, 1116, -1, 1145, + -1, 1147, -1, 1140, -1, 1132, -1, 1148, -1, 1151, + -1, 1153, -1, -1, 160, 378, 1042, 515, 516, -1, + 469, -1, -1, 516, 519, -1, -1, 517, 518, -1, + -1, 341, 1181, -1, 341, 314, -1, 202, 341, 1181, + -1, 442, 341, 1181, -1, 252, -1, 152, 285, 1043, + -1, 453, 448, 1181, -1, 450, 1032, -1, 1183, -1, + 518, -1, 417, 1041, -1, 96, 1032, -1, 378, 1032, + -1, 247, 378, 1032, -1, 247, 235, 1032, -1, 160, + 450, 1042, 515, 516, -1, 101, 378, 1042, 515, 517, + -1, -1, 247, 174, 1034, -1, 101, 378, 1042, 522, + 548, -1, 101, 450, 1042, 515, 517, -1, 101, 450, + 1042, 548, -1, 197, 378, 1032, -1, 197, 378, 242, + 211, 1032, -1, 197, 450, 1032, -1, 197, 450, 242, + 211, 1032, -1, 160, 235, 1042, 515, 516, -1, 101, + 235, 1042, 530, 450, 1032, -1, 95, -1, 197, -1, + 197, 235, 1032, -1, 197, 235, 242, 211, 1032, -1, + 160, 384, 533, 115, 1042, 534, -1, 160, 384, 1161, + 534, -1, 1161, -1, -1, 534, 535, -1, -1, 586, + -1, 761, -1, 625, -1, 680, -1, 741, -1, 831, + -1, 396, 537, -1, 396, 288, 537, -1, 396, 394, + 537, -1, 431, 829, -1, 394, 136, 108, 431, 829, + -1, 538, -1, 539, 429, 540, -1, 539, 490, 540, + -1, 539, 429, 180, -1, 539, 490, 180, -1, 539, + 227, 163, -1, 427, 486, 544, -1, 132, 1181, -1, + 384, 1181, -1, 302, 545, -1, 378, 546, -1, 394, + 115, 546, -1, 394, 115, 180, -1, 474, 326, 979, + -1, 431, 403, 1181, -1, 1160, -1, 539, 505, 1161, + -1, 541, -1, 540, 506, 541, -1, 543, -1, 631, + -1, 357, 441, -1, 357, 149, -1, 368, 357, -1, + 392, -1, 435, -1, 216, -1, 323, -1, 546, -1, + 1181, -1, 1183, -1, 966, 1181, 968, -1, 966, 503, + 1041, 504, 1181, 968, -1, 631, -1, 180, -1, 288, + -1, 1181, -1, 180, -1, -1, 1161, -1, 1181, -1, + 371, 539, -1, 371, 427, 486, -1, 371, 431, 270, + 283, -1, 371, 394, 115, -1, 371, 99, -1, 396, + 537, -1, 547, -1, 396, 538, -1, 547, -1, 399, + 539, 1194, -1, 399, 427, 486, 1194, -1, 399, 431, + 270, 283, 1194, -1, 399, 394, 115, 1194, -1, 399, + 99, -1, 396, 154, 552, 553, -1, 99, -1, 1030, + -1, 183, -1, 244, -1, 138, -1, 191, 99, -1, + 191, 422, -1, 191, 424, -1, 191, 343, -1, 101, + 419, 937, 557, -1, 101, 419, 242, 211, 937, 557, + -1, 101, 250, 1031, 557, -1, 101, 250, 242, 211, + 1031, 557, -1, 101, 390, 1031, 557, -1, 101, 390, + 242, 211, 1031, 557, -1, 101, 463, 1031, 557, -1, + 101, 463, 242, 211, 1031, 557, -1, 558, -1, 557, + 506, 558, -1, 95, 594, -1, 95, 145, 594, -1, + 101, 810, 1161, 559, -1, 101, 810, 1161, 197, 309, + 314, -1, 101, 810, 1161, 396, 309, 314, -1, 101, + 810, 1161, 396, 409, 1043, -1, 101, 810, 1161, 396, + 563, -1, 101, 810, 1161, 371, 563, -1, 101, 810, + 1161, 396, 412, 1161, -1, 197, 810, 242, 211, 1161, + 560, -1, 197, 810, 1161, 560, -1, 101, 810, 1161, + 811, 438, 946, 561, 562, -1, 101, 810, 1161, 659, + -1, 95, 603, -1, 454, 153, 1033, -1, 197, 153, + 242, 211, 1033, 560, -1, 197, 153, 1033, 560, -1, + 396, 469, 322, -1, 396, 470, 322, -1, 141, 323, + 1033, -1, 396, 470, 141, -1, 200, 433, 1033, -1, + 200, 102, 433, 1033, -1, 200, 370, 433, 1033, -1, + 200, 433, 99, -1, 200, 433, 450, -1, 190, 433, + 1033, -1, 190, 433, 99, -1, 190, 433, 450, -1, + 200, 382, 1033, -1, 200, 102, 382, 1033, -1, 200, + 370, 382, 1033, -1, 190, 382, 1033, -1, 252, 1031, + -1, 307, 252, 1031, -1, 319, 726, -1, 309, 319, + -1, 336, 429, 1042, -1, 396, 421, 1033, -1, 396, + 563, -1, 371, 563, -1, 659, -1, 396, 180, 970, + -1, 197, 180, -1, 128, -1, 373, -1, -1, 143, + 726, -1, -1, 451, 970, -1, -1, 503, 565, 504, + -1, 469, 563, -1, -1, 566, -1, 565, 506, 566, + -1, 1163, 490, 700, -1, 1163, -1, 1163, 505, 1163, + 490, 700, -1, 1163, 505, 1163, -1, 101, 438, 726, + 568, -1, 569, -1, 568, 506, 569, -1, 95, 114, + 945, 560, -1, 197, 114, 242, 211, 1161, 560, -1, + 197, 114, 1161, 560, -1, 101, 114, 1161, 811, 438, + 946, 561, 560, -1, 140, 890, -1, 140, 99, -1, + 158, 577, 1031, 606, 578, 572, 573, 579, 515, 574, + -1, 158, 894, 429, 573, 515, 574, -1, 227, -1, + 429, -1, 1181, -1, 410, -1, 411, -1, 575, -1, + 503, 581, 504, -1, 575, 576, -1, -1, 121, -1, + 322, -1, 186, 845, 1181, -1, 314, 845, 1181, -1, + 162, -1, 238, -1, 355, 845, 1181, -1, 205, 845, + 1181, -1, 223, 355, 607, -1, 223, 355, 496, -1, + 223, 309, 314, 607, -1, 201, 1181, -1, 121, -1, + -1, 469, 322, -1, -1, 580, 187, 1181, -1, -1, + 451, -1, -1, 582, -1, 581, 506, 582, -1, 1163, + 583, -1, 543, -1, 631, -1, 496, -1, 503, 584, + 504, -1, -1, 585, -1, 584, 506, 585, -1, 543, + -1, 160, 587, 419, 1031, 503, 588, 504, 617, 618, + 619, 620, -1, 160, 587, 419, 242, 309, 211, 1031, + 503, 588, 504, 617, 618, 619, 620, -1, 160, 587, + 419, 1031, 319, 726, 589, 618, 619, 620, -1, 160, + 587, 419, 242, 309, 211, 1031, 319, 726, 589, 618, + 619, 620, -1, 424, -1, 422, -1, 288, 424, -1, + 288, 422, -1, 231, 424, -1, 231, 422, -1, 447, + -1, -1, 590, -1, -1, 503, 591, 504, -1, -1, + 592, -1, 590, 506, 592, -1, 593, -1, 591, 506, + 593, -1, 594, -1, 600, -1, 603, -1, 595, -1, + 603, -1, 1161, 946, 657, 596, -1, 1161, 469, 327, + 596, -1, 596, 597, -1, -1, 153, 1033, 598, -1, + 598, -1, 599, -1, 143, 726, -1, 309, 314, -1, + 314, -1, 444, 788, 621, -1, 350, 272, 788, 621, + -1, 137, 503, 970, 504, 605, -1, 180, 971, -1, + 363, 1031, 606, 609, 613, -1, 182, -1, 309, 182, + -1, 254, 183, -1, 254, 244, -1, 284, 1031, 601, + -1, 601, 248, 602, -1, 601, 208, 602, -1, -1, + 181, -1, 154, -1, 251, -1, 412, -1, 147, -1, + 99, -1, 153, 1033, 604, -1, 604, -1, 137, 503, + 970, 504, 691, -1, 444, 503, 607, 504, 788, 621, + 691, -1, 444, 622, 691, -1, 350, 272, 503, 607, + 504, 788, 621, 691, -1, 350, 272, 622, 691, -1, + 207, 765, 503, 610, 504, 788, 621, 612, 691, -1, + 224, 272, 503, 607, 504, 363, 1031, 606, 609, 613, + 691, -1, 307, 252, -1, -1, 503, 607, 504, -1, + -1, 608, -1, 607, 506, 608, -1, 1161, -1, 294, + 228, -1, 294, 338, -1, 294, 401, -1, -1, 611, + -1, 610, 506, 611, -1, 767, 469, 798, -1, 767, + 469, 325, 503, 798, 504, -1, 466, 503, 970, 504, + -1, -1, 614, -1, 615, -1, 614, 615, -1, 615, + 614, -1, -1, 323, 449, 616, -1, 323, 185, 616, + -1, 307, 94, -1, 373, -1, 128, -1, 396, 314, + -1, 396, 180, -1, 253, 503, 1030, 504, -1, -1, + 469, 563, -1, 469, 322, -1, 470, 322, -1, -1, + 323, 148, 197, -1, 323, 148, 185, 381, -1, 323, + 148, 347, 381, -1, -1, 421, 1033, -1, -1, 451, + 250, 421, 1033, -1, -1, 451, 250, 1037, -1, 1031, + 606, 618, 619, 620, -1, 469, 173, -1, 469, 307, + 173, -1, -1, 160, 587, 390, 1031, 627, -1, 101, + 390, 1031, 628, -1, 101, 390, 242, 211, 1031, 628, + -1, 628, -1, -1, 629, -1, 628, 629, -1, 126, + 631, -1, 172, -1, 307, 172, -1, 249, 630, 631, + -1, 295, 631, -1, 297, 631, -1, 307, 295, -1, + 307, 297, -1, 335, 125, 726, -1, 407, 515, 631, + -1, 372, -1, 372, 515, 631, -1, 125, -1, -1, + 1180, -1, 495, 1180, -1, 1043, -1, 631, -1, 632, + 506, 631, -1, 160, 773, 634, 640, 274, 546, -1, + 160, 773, 634, 640, 274, 546, 236, 635, 636, 638, + -1, 437, -1, -1, 1033, -1, 1033, 727, -1, 255, + 635, -1, -1, 455, 635, -1, 307, 455, -1, 637, + -1, -1, 197, 640, 274, 546, 560, -1, 197, 640, + 274, 242, 211, 546, 560, -1, 353, -1, -1, 160, + 421, 1033, 642, 291, 1181, -1, 336, 1033, -1, -1, + 197, 421, 1033, -1, 197, 421, 242, 211, 1033, -1, + 160, 213, 1033, 515, 645, -1, 160, 213, 242, 309, + 211, 1033, 515, 645, -1, 645, 646, -1, -1, 384, + 1033, -1, 462, 546, -1, 227, 546, -1, 101, 213, + 1033, 449, 648, -1, 648, 649, -1, -1, 429, 546, + -1, 101, 213, 1033, 530, 98, 1039, 701, -1, 101, + 213, 1033, 530, 131, 503, 946, 108, 946, 504, -1, + 101, 213, 1033, 530, 144, 726, -1, 101, 213, 1033, + 530, 157, 726, -1, 101, 213, 1033, 530, 195, 726, + -1, 101, 213, 1033, 530, 229, 751, -1, 101, 213, + 1033, 530, 640, 274, 1033, -1, 101, 213, 1033, 530, + 325, 798, 797, -1, 101, 213, 1033, 530, 325, 139, + 726, 451, 1035, -1, 101, 213, 1033, 530, 325, 217, + 726, 451, 1035, -1, 101, 213, 1033, 530, 384, 1033, + -1, 101, 213, 1033, 530, 419, 726, -1, 101, 213, + 1033, 530, 425, 386, 337, 726, -1, 101, 213, 1033, + 530, 425, 386, 189, 726, -1, 101, 213, 1033, 530, + 425, 386, 423, 726, -1, 101, 213, 1033, 530, 425, + 386, 151, 726, -1, 101, 213, 1033, 530, 390, 726, + -1, 101, 213, 1033, 530, 463, 726, -1, 101, 213, + 1033, 530, 224, 419, 726, -1, 101, 213, 1033, 530, + 224, 173, 472, 1033, -1, 101, 213, 1033, 530, 393, + 1033, -1, 101, 213, 1033, 530, 438, 726, -1, 160, + 224, 173, 472, 1033, 654, 657, -1, 236, 635, -1, + 307, 236, -1, 455, 635, -1, 307, 455, -1, 652, + -1, 653, 652, -1, 653, -1, -1, 197, 224, 173, + 472, 1033, 560, -1, 197, 224, 173, 472, 242, 211, + 1033, 560, -1, 101, 224, 173, 472, 1033, 654, 659, + -1, 101, 224, 173, 472, 1033, 653, -1, 327, 503, + 658, 504, -1, -1, 662, -1, 658, 506, 662, -1, + 327, 503, 660, 504, -1, 661, -1, 660, 506, 661, + -1, 662, -1, 396, 662, -1, 95, 662, -1, 197, + 663, -1, 663, 664, -1, 1163, -1, 1181, -1, 160, + 393, 1033, 666, 668, 224, 173, 472, 1033, 657, -1, + 438, 1181, -1, -1, 462, 1181, -1, 462, 314, -1, + 667, -1, -1, 197, 393, 1033, 560, -1, 197, 393, + 242, 211, 1033, 560, -1, 101, 393, 1033, 667, 659, + -1, 101, 393, 1033, 667, -1, 101, 393, 1033, 659, + -1, 160, 224, 419, 1031, 672, 393, 1033, 657, -1, + 160, 224, 419, 242, 309, 211, 1031, 672, 393, 1033, + 657, -1, 503, 673, 504, -1, 503, 504, -1, 674, + -1, 673, 506, 674, -1, 594, -1, 101, 224, 419, + 937, 557, -1, 101, 224, 419, 242, 211, 937, 557, + -1, 160, 450, 293, 222, 677, 393, 1033, 657, -1, + 170, -1, 450, -1, 1042, -1, 197, 450, 293, 222, + 677, 393, 1033, -1, 197, 450, 293, 242, 211, 222, + 677, 393, 1033, -1, 101, 450, 293, 222, 677, 393, + 1033, 659, -1, 160, 433, 1033, 681, 682, 323, 1031, + 684, 687, 210, 354, 1039, 503, 688, 504, -1, 160, + 153, 433, 1033, 97, 682, 323, 1031, 690, 691, 222, + 198, 380, 687, 210, 354, 1039, 503, 688, 504, -1, + 117, -1, 97, -1, 261, 319, -1, 683, -1, 682, + 328, 683, -1, 260, -1, 185, -1, 449, -1, 449, + 319, 607, -1, 436, -1, 222, 685, 686, -1, -1, + 198, -1, -1, 380, -1, 408, -1, 465, 503, 970, + 504, -1, -1, 689, -1, 688, 506, 689, -1, -1, + 1041, -1, 1180, -1, 1181, -1, 1163, -1, 227, 1031, + -1, -1, -1, 691, 692, -1, 309, 182, -1, 182, + -1, 254, 244, -1, 254, 183, -1, 309, 453, -1, + 307, 252, -1, 197, 433, 1033, 323, 726, 560, -1, + 197, 433, 242, 211, 1033, 323, 726, 560, -1, 160, + 110, 1033, 137, 503, 970, 504, 691, -1, 197, 110, + 1033, 560, -1, 160, 98, 1039, 701, 697, -1, 160, + 98, 1039, 702, -1, 160, 325, 798, 697, -1, 160, + 438, 726, 697, -1, 160, 438, 726, -1, 160, 438, + 726, 108, 503, 943, 504, -1, 160, 438, 726, 108, + 204, 503, 705, 504, -1, 160, 438, 726, 108, 356, + 697, -1, 160, 425, 386, 337, 726, 697, -1, 160, + 425, 386, 189, 726, 697, -1, 160, 425, 386, 423, + 726, 697, -1, 160, 425, 386, 151, 726, 697, -1, + 160, 144, 726, 697, -1, 160, 144, 726, 227, 726, + -1, 503, 698, 504, -1, 699, -1, 698, 506, 699, + -1, 1163, 490, 700, -1, 1163, -1, 782, -1, 1047, + -1, 997, -1, 631, -1, 1181, -1, 503, 1002, 504, + -1, 503, 496, 504, -1, 503, 703, 504, -1, 704, + -1, 703, 506, 704, -1, 1183, 490, 700, -1, 706, + -1, -1, 1181, -1, 706, 506, 1181, -1, 101, 438, + 726, 95, 456, 1181, -1, 101, 438, 726, 95, 456, + 1181, 117, 1181, -1, 101, 438, 726, 95, 456, 1181, + 97, 1181, -1, 160, 325, 139, 726, 711, 222, 438, + 946, 451, 1035, 712, 108, 709, -1, 710, -1, 709, + 506, 710, -1, 325, 1041, 798, 713, 714, -1, 325, + 1041, 798, 797, 713, 714, -1, 229, 1041, 1039, 774, + -1, 229, 1041, 503, 1002, 504, 1039, 774, -1, 412, + 946, -1, 180, -1, -1, 217, 726, -1, -1, 222, + 386, -1, 222, 329, 125, 726, -1, -1, 360, -1, + -1, 160, 325, 217, 726, 451, 1035, -1, 101, 325, + 217, 726, 451, 1035, 95, 709, -1, 101, 325, 217, + 726, 451, 1035, 197, 717, -1, 718, -1, 717, 506, + 718, -1, 325, 1041, 503, 1002, 504, -1, 229, 1041, + 503, 1002, 504, -1, 197, 325, 139, 726, 451, 1035, + 560, -1, 197, 325, 139, 242, 211, 726, 451, 1035, + 560, -1, 197, 325, 217, 726, 451, 1035, 560, -1, + 197, 325, 217, 242, 211, 726, 451, 1035, 560, -1, + 197, 335, 125, 1032, 560, -1, 359, 335, 125, 1032, + 429, 1033, -1, 197, 724, 242, 211, 725, 560, -1, + 197, 724, 725, 560, -1, 197, 250, 150, 725, 560, + -1, 197, 250, 150, 242, 211, 725, 560, -1, 419, + -1, 390, -1, 463, -1, 250, -1, 224, 419, -1, + 438, -1, 195, -1, 144, -1, 157, -1, 384, -1, + 213, -1, 425, 386, 337, -1, 425, 386, 189, -1, + 425, 386, 423, -1, 425, 386, 151, -1, 726, -1, + 725, 506, 726, -1, 1161, -1, 1161, 727, -1, 505, + 1036, -1, 727, 505, 1036, -1, 436, 904, 938, 729, + 560, -1, 156, 241, -1, 372, 241, -1, -1, 146, + 323, 731, 726, 268, 732, -1, 146, 323, 98, 1039, + 701, 268, 732, -1, 146, 323, 229, 1039, 774, 268, + 732, -1, 146, 323, 325, 798, 797, 268, 732, -1, + 146, 323, 153, 1033, 323, 726, 268, 732, -1, 146, + 323, 382, 1033, 323, 726, 268, 732, -1, 146, 323, + 382, 1033, 268, 732, -1, 146, 323, 433, 1033, 323, + 726, 268, 732, -1, 146, 323, 325, 139, 726, 451, + 1035, 268, 732, -1, 146, 323, 325, 217, 726, 451, + 1035, 268, 732, -1, 146, 323, 275, 318, 631, 268, + 732, -1, 146, 323, 131, 503, 946, 108, 946, 504, + 268, 732, -1, 146, 323, 640, 274, 726, 268, 732, + -1, 146, 323, 425, 386, 337, 726, 268, 732, -1, + 146, 323, 425, 386, 189, 726, 268, 732, -1, 146, + 323, 425, 386, 423, 726, 268, 732, -1, 146, 323, + 425, 386, 151, 726, 268, 732, -1, 145, -1, 174, + -1, 384, -1, 250, -1, 390, -1, 419, -1, 195, + -1, 438, -1, 463, -1, 144, -1, 157, -1, 421, + -1, 213, -1, 378, -1, 224, 419, -1, 393, -1, + 224, 173, 472, -1, 1181, -1, 314, -1, 388, 273, + 734, 323, 735, 726, 268, 736, -1, 388, 273, 734, + 323, 98, 1039, 701, 268, 736, -1, 388, 273, 734, + 323, 229, 1039, 774, 268, 736, -1, 388, 273, 734, + 323, 275, 318, 631, 268, 736, -1, 388, 273, 734, + 323, 640, 274, 726, 268, 736, -1, 222, 546, -1, + -1, 145, -1, 174, -1, 224, 419, -1, 384, -1, + 390, -1, 419, -1, 195, -1, 378, -1, 421, -1, + 438, -1, 463, -1, 1181, -1, 314, -1, 218, 738, + -1, 300, 738, -1, 218, 738, 1195, -1, 218, 225, + 890, 1196, -1, 218, 225, 739, 890, 1196, -1, 218, + 116, 890, 1196, -1, 218, 116, 739, 890, 1196, -1, + 300, 225, 890, -1, 300, 225, 739, 890, -1, 300, + 116, 890, -1, 300, 116, 739, 890, -1, 890, -1, + 739, 890, -1, 306, 740, 890, -1, 351, 740, 890, + -1, 219, 740, 890, -1, 276, 740, 890, -1, 92, + 1043, 740, 890, -1, 365, 1043, 740, 890, -1, 1043, + 740, 890, -1, 99, 740, 890, -1, 225, 1043, 740, + 890, -1, 225, 99, 740, 890, -1, 116, 1043, 740, + 890, -1, 116, 99, 740, 890, -1, 227, -1, 247, + -1, 739, -1, -1, 232, 743, 323, 746, 429, 747, + 749, -1, 376, 743, 323, 746, 227, 747, 560, -1, + 376, 232, 326, 222, 743, 323, 746, 227, 747, 560, + -1, 744, -1, 99, -1, 99, 352, -1, 99, 503, + 607, 504, -1, 99, 352, 503, 607, 504, -1, 745, + -1, 744, 506, 745, -1, 389, 606, -1, 363, 606, + -1, 160, 606, -1, 1161, 606, -1, 1030, -1, 419, + 1030, -1, 390, 1030, -1, 224, 173, 472, 1032, -1, + 224, 393, 1032, -1, 229, 750, -1, 174, 1032, -1, + 195, 725, -1, 274, 1032, -1, 275, 318, 632, -1, + 384, 1032, -1, 421, 1032, -1, 438, 725, -1, 99, + 420, 247, 384, 1032, -1, 99, 391, 247, 384, 1032, + -1, 99, 230, 247, 384, 1032, -1, 748, -1, 747, + 506, 748, -1, 1042, -1, 235, 1042, -1, 469, 232, + 326, -1, -1, 751, -1, 750, 506, 751, -1, 1039, + 774, -1, 232, 744, 429, 1032, 754, 755, -1, 376, + 744, 227, 1032, 755, 560, -1, 376, 96, 326, 222, + 744, 227, 1032, 755, 560, -1, 469, 96, 326, -1, + -1, 233, 125, 1042, -1, -1, 101, 180, 352, 757, + 759, -1, 757, 758, -1, -1, 247, 384, 1032, -1, + 222, 378, 1032, -1, 222, 450, 1032, -1, 232, 743, + 323, 760, 429, 747, 749, -1, 376, 743, 323, 760, + 227, 747, 560, -1, 376, 232, 326, 222, 743, 323, + 760, 227, 747, 560, -1, 420, -1, 230, -1, 391, + -1, 439, -1, 160, 762, 250, 763, 764, 323, 1031, + 765, 503, 766, 504, 564, 620, 941, -1, 444, -1, + -1, 150, -1, -1, 1037, -1, -1, 451, 1035, -1, + -1, 767, -1, 766, 506, 767, -1, 1161, 768, 769, + 770, 771, -1, 973, 768, 769, 770, 771, -1, 503, + 970, 504, 768, 769, 770, 771, -1, 143, 726, -1, + -1, 726, -1, 451, 726, -1, -1, 109, -1, 188, + -1, -1, 487, -1, 488, -1, -1, 160, 773, 229, + 1039, 776, 375, 781, 784, 788, -1, 160, 773, 229, + 1039, 776, 375, 419, 503, 790, 504, 784, 788, -1, + 160, 773, 229, 1039, 776, 784, 788, -1, 328, 369, + -1, -1, 503, 775, 504, -1, 503, 504, -1, 778, + -1, 775, 506, 778, -1, 503, 777, 504, -1, 503, + 504, -1, 783, -1, 777, 506, 783, -1, 779, 780, + 782, -1, 780, 779, 782, -1, 780, 782, -1, 779, + 782, -1, 782, -1, 247, -1, 330, -1, 257, -1, + 247, 330, -1, 459, -1, 1162, -1, 782, -1, 946, + -1, 1162, 727, 498, 438, -1, 397, 1162, 727, 498, + 438, -1, 778, -1, 778, 180, 970, -1, 778, 490, + 970, -1, 786, -1, 784, 786, -1, 127, 323, 314, + 258, -1, 375, 314, 323, 314, 258, -1, 413, -1, + 245, -1, 405, -1, 464, -1, 214, 388, 184, -1, + 214, 388, 267, -1, 388, 184, -1, 388, 267, -1, + 280, -1, 309, 280, -1, 159, 631, -1, 381, 631, + -1, 549, -1, 108, 787, -1, 274, 546, -1, 468, + -1, 785, -1, 1181, -1, 1181, 506, 1181, -1, 469, + 697, -1, -1, 780, 782, -1, 789, -1, 790, 506, + 789, -1, 101, 229, 751, 792, 793, -1, 785, -1, + 792, 785, -1, 373, -1, -1, 197, 229, 1039, 774, + 560, -1, 197, 229, 242, 211, 1039, 774, 560, -1, + 197, 98, 1039, 701, 560, -1, 197, 98, 242, 211, + 1039, 701, 560, -1, 197, 325, 798, 797, 560, -1, + 197, 325, 242, 211, 798, 797, 560, -1, 503, 946, + 504, -1, 503, 946, 506, 946, 504, -1, 503, 308, + 506, 946, 504, -1, 503, 946, 506, 308, 504, -1, + 994, -1, 1161, 505, 798, -1, 193, 800, -1, 801, + -1, 800, 801, -1, 1181, -1, 274, 546, -1, 160, + 131, 503, 946, 108, 946, 504, 469, 229, 751, 803, + -1, 160, 131, 503, 946, 108, 946, 504, 470, 229, + 803, -1, 160, 131, 503, 946, 108, 946, 504, 469, + 257, 803, -1, 108, 246, -1, 108, 111, -1, -1, + 197, 131, 805, 503, 946, 108, 946, 504, 560, -1, + 242, 211, -1, -1, 364, 807, 1031, 808, -1, 364, + 418, 1033, 808, -1, 364, 174, 1033, 808, -1, 250, + -1, 419, -1, 223, -1, -1, 101, 98, 1039, 701, + 367, 429, 1033, -1, 101, 144, 726, 367, 429, 1033, + -1, 101, 157, 726, 367, 429, 1033, -1, 101, 174, + 1034, 367, 429, 1034, -1, 101, 195, 726, 367, 429, + 1033, -1, 101, 195, 726, 367, 153, 1033, 429, 1033, + -1, 101, 224, 173, 472, 1033, 367, 429, 1033, -1, + 101, 229, 751, 367, 429, 1033, -1, 101, 235, 1042, + 367, 429, 1042, -1, 101, 640, 274, 1033, 367, 429, + 1033, -1, 101, 325, 139, 726, 451, 1035, 367, 429, + 1033, -1, 101, 325, 217, 726, 451, 1035, 367, 429, + 1033, -1, 101, 384, 1033, 367, 429, 1033, -1, 101, + 393, 1033, 367, 429, 1033, -1, 101, 419, 937, 367, + 429, 1033, -1, 101, 419, 242, 211, 937, 367, 429, + 1033, -1, 101, 390, 1031, 367, 429, 1033, -1, 101, + 390, 242, 211, 1031, 367, 429, 1033, -1, 101, 463, + 1031, 367, 429, 1033, -1, 101, 463, 242, 211, 1031, + 367, 429, 1033, -1, 101, 250, 1031, 367, 429, 1033, + -1, 101, 250, 242, 211, 1031, 367, 429, 1033, -1, + 101, 224, 419, 937, 367, 429, 1033, -1, 101, 224, + 419, 242, 211, 937, 367, 429, 1033, -1, 101, 419, + 937, 367, 810, 1033, 429, 1033, -1, 101, 419, 242, + 211, 937, 367, 810, 1033, 429, 1033, -1, 101, 419, + 937, 367, 153, 1033, 429, 1033, -1, 101, 224, 419, + 937, 367, 810, 1033, 429, 1033, -1, 101, 224, 419, + 242, 211, 937, 367, 810, 1033, 429, 1033, -1, 101, + 433, 1033, 323, 1031, 367, 429, 1033, -1, 101, 378, + 1042, 367, 429, 1042, -1, 101, 450, 1042, 367, 429, + 1042, -1, 101, 421, 1033, 367, 429, 1033, -1, 101, + 421, 1033, 396, 563, -1, 101, 421, 1033, 371, 563, + -1, 101, 425, 386, 337, 726, 367, 429, 1033, -1, + 101, 425, 386, 189, 726, 367, 429, 1033, -1, 101, + 425, 386, 423, 726, 367, 429, 1033, -1, 101, 425, + 386, 151, 726, 367, 429, 1033, -1, 101, 438, 726, + 367, 429, 1033, -1, 101, 438, 726, 367, 114, 1033, + 429, 1033, 560, -1, 145, -1, -1, 396, 173, -1, + -1, 101, 98, 1039, 701, 396, 384, 1033, -1, 101, + 144, 726, 396, 384, 1033, -1, 101, 157, 726, 396, + 384, 1033, -1, 101, 195, 726, 396, 384, 1033, -1, + 101, 213, 726, 396, 384, 1033, -1, 101, 229, 751, + 396, 384, 1033, -1, 101, 325, 798, 797, 396, 384, + 1033, -1, 101, 325, 139, 726, 451, 1035, 396, 384, + 1033, -1, 101, 325, 217, 726, 451, 1035, 396, 384, + 1033, -1, 101, 419, 937, 396, 384, 1033, -1, 101, + 419, 242, 211, 937, 396, 384, 1033, -1, 101, 425, + 386, 337, 726, 396, 384, 1033, -1, 101, 425, 386, + 189, 726, 396, 384, 1033, -1, 101, 425, 386, 423, + 726, 396, 384, 1033, -1, 101, 425, 386, 151, 726, + 396, 384, 1033, -1, 101, 390, 1031, 396, 384, 1033, + -1, 101, 390, 242, 211, 1031, 396, 384, 1033, -1, + 101, 463, 1031, 396, 384, 1033, -1, 101, 463, 242, + 211, 1031, 396, 384, 1033, -1, 101, 224, 419, 937, + 396, 384, 1033, -1, 101, 224, 419, 242, 211, 937, + 396, 384, 1033, -1, 101, 438, 726, 396, 384, 1033, + -1, 101, 98, 1039, 701, 336, 429, 1042, -1, 101, + 144, 726, 336, 429, 1042, -1, 101, 157, 726, 336, + 429, 1042, -1, 101, 174, 1034, 336, 429, 1042, -1, + 101, 195, 726, 336, 429, 1042, -1, 101, 229, 751, + 336, 429, 1042, -1, 101, 640, 274, 1033, 336, 429, + 1042, -1, 101, 275, 318, 631, 336, 429, 1042, -1, + 101, 325, 798, 797, 336, 429, 1042, -1, 101, 325, + 139, 726, 451, 1035, 336, 429, 1042, -1, 101, 325, + 217, 726, 451, 1035, 336, 429, 1042, -1, 101, 384, + 1033, 336, 429, 1042, -1, 101, 438, 726, 336, 429, + 1042, -1, 101, 421, 1033, 336, 429, 1042, -1, 101, + 425, 386, 189, 726, 336, 429, 1042, -1, 101, 425, + 386, 151, 726, 336, 429, 1042, -1, 101, 224, 173, + 472, 1033, 336, 429, 1042, -1, 101, 393, 1033, 336, + 429, 1042, -1, 160, 773, 382, 1033, 108, 323, 819, + 429, 1031, 941, 193, 820, 815, -1, 310, -1, 817, + -1, 503, 816, 504, -1, 816, 507, 818, -1, 818, + -1, 893, -1, 871, -1, 882, -1, 876, -1, 822, + -1, 817, -1, -1, 389, -1, 449, -1, 185, -1, + 260, -1, 261, -1, 100, -1, -1, 197, 382, 1033, + 323, 726, 560, -1, 197, 382, 242, 211, 1033, 323, + 726, 560, -1, 311, 1161, 823, -1, 506, 1181, -1, + -1, 286, 1161, -1, 446, 1161, -1, 446, 496, -1, + 91, 827, -1, 118, 827, 830, -1, 407, 431, 830, + -1, 148, 827, -1, 203, 827, -1, 379, 827, -1, + 383, 1161, -1, 366, 383, 1161, -1, 366, 1161, -1, + 379, 827, 429, 383, 1161, -1, 379, 827, 429, 1161, + -1, 348, 431, 1181, -1, 148, 349, 1181, -1, 379, + 349, 1181, -1, 471, -1, 431, -1, -1, 270, 283, + 542, -1, 357, 324, -1, 357, 473, -1, 182, -1, + 309, 182, -1, 828, -1, 829, 506, 828, -1, 829, + 828, -1, 829, -1, -1, 160, 587, 463, 1031, 606, + 564, 108, 893, 832, -1, 160, 328, 369, 587, 463, + 1031, 606, 564, 108, 893, 832, -1, 469, 137, 326, + -1, 469, 129, 137, 326, -1, 469, 288, 137, 326, + -1, -1, 287, 1038, -1, 160, 174, 1034, 515, 835, + -1, 835, 836, -1, -1, 421, 837, 1033, -1, 421, + 837, 180, -1, 291, 837, 1181, -1, 291, 837, 180, + -1, 423, 837, 1033, -1, 423, 837, 180, -1, 201, + 837, 1181, -1, 201, 837, 1041, -1, 201, 837, 180, + -1, 277, 837, 1181, -1, 277, 837, 180, -1, 278, + 837, 1181, -1, 278, 837, 180, -1, 152, 285, 837, + 1043, -1, 336, 837, 1033, -1, 336, 837, 180, -1, + 490, -1, -1, 101, 174, 1034, 515, 840, -1, 101, + 174, 1034, 396, 421, 1033, -1, 101, 174, 1034, 548, + -1, 840, 841, -1, -1, 152, 285, 837, 1043, -1, + 197, 174, 1034, -1, 197, 174, 242, 211, 1034, -1, + 160, 195, 726, 845, 946, 596, -1, 101, 195, 726, + 559, -1, 101, 195, 726, 197, 309, 314, -1, 101, + 195, 726, 396, 309, 314, -1, 101, 195, 726, 95, + 603, -1, 101, 195, 726, 197, 153, 1033, 560, -1, + 101, 195, 726, 197, 153, 242, 211, 1033, 560, -1, + 101, 195, 726, 454, 153, 1033, -1, 108, -1, -1, + 101, 425, 386, 189, 726, 697, -1, 101, 425, 386, + 151, 726, 95, 293, 222, 1032, 469, 725, -1, 101, + 425, 386, 151, 726, 101, 293, 222, 1032, 469, 725, + -1, 101, 425, 386, 151, 726, 101, 293, 369, 726, + 469, 726, -1, 101, 425, 386, 151, 726, 101, 293, + 222, 1032, 369, 726, 469, 726, -1, 101, 425, 386, + 151, 726, 197, 293, 222, 1032, -1, 101, 425, 386, + 151, 726, 197, 293, 242, 211, 222, 1032, -1, 160, + 711, 157, 726, 222, 1181, 429, 1181, 227, 726, -1, + 141, 856, 1031, 850, -1, 141, 856, -1, 141, 856, + 1037, 323, 1031, -1, 451, 1037, -1, -1, 452, 857, + 858, 856, -1, 452, 857, 858, 856, 1031, -1, 452, + 857, 858, 856, 854, -1, 452, 503, 852, 504, -1, + 452, 503, 852, 504, 1031, 859, -1, 853, -1, 852, + 506, 853, -1, 855, -1, 461, -1, 226, -1, 228, + -1, 855, 856, -1, 855, 856, 1031, 859, -1, 104, + -1, 103, -1, 461, -1, -1, 228, -1, -1, 226, + -1, -1, 503, 1032, 504, -1, -1, 212, 861, -1, + 212, 855, 856, 861, -1, 212, 461, 861, -1, 212, + 503, 862, 504, 861, -1, 893, -1, 871, -1, 882, + -1, 876, -1, 889, -1, 1050, -1, 869, -1, 863, + -1, 862, 506, 863, -1, 864, 865, -1, 1161, -1, + 855, -1, 461, -1, 543, -1, 631, -1, -1, 348, + 1069, 867, 108, 868, -1, 348, 1069, 227, 1114, -1, + 503, 1002, 504, -1, -1, 893, -1, 871, -1, 882, + -1, 876, -1, 210, 1069, 870, 1193, -1, 160, 587, + 419, 623, 108, 210, 1033, 870, 624, -1, 503, 999, + 504, -1, -1, 901, 260, 266, 1031, 872, 875, -1, + 893, -1, 503, 873, 504, 893, -1, 180, 457, -1, + 874, -1, 873, 506, 874, -1, 1161, 1023, -1, 374, + 1028, 1194, -1, -1, 901, 185, 227, 939, 877, 942, + 875, -1, 451, 930, -1, -1, 292, 904, 938, 879, + 881, -1, 247, 880, 298, -1, -1, 93, 398, -1, + 380, 398, -1, 380, 209, -1, 398, 449, 209, -1, + 398, -1, 398, 380, 209, -1, 209, -1, 93, 209, + -1, 313, -1, -1, 901, 449, 939, 396, 883, 929, + 942, 875, -1, 884, -1, 883, 506, 884, -1, 885, + -1, 886, -1, 887, 490, 1025, -1, 503, 888, 504, + 490, 1027, -1, 1161, 1023, -1, 887, -1, 888, 506, + 887, -1, 179, 890, 891, 171, 892, 222, 893, -1, + 1033, -1, 1174, -1, -1, 891, 307, 385, -1, 891, + 385, -1, 891, 121, -1, 891, 259, -1, -1, 469, + 239, -1, 470, 239, -1, 895, -1, 894, -1, 503, + 895, 504, -1, 503, 894, 504, -1, 897, -1, 896, + 908, -1, 896, 907, 923, 912, -1, 896, 907, 911, + 924, -1, 898, 896, -1, 898, 896, 908, -1, 898, + 896, 907, 923, 912, -1, 898, 896, 907, 911, 924, + -1, 897, -1, 894, -1, 389, 906, 1028, 902, 929, + 941, 921, 922, 982, -1, 928, -1, 419, 937, -1, + 896, 443, 905, 896, -1, 896, 264, 905, 896, -1, + 896, 206, 905, 896, -1, 469, 899, -1, 469, 361, + 899, -1, 900, -1, 899, 506, 900, -1, 1033, 859, + 108, 503, 868, 504, -1, 898, -1, -1, 266, 903, + -1, 1194, -1, -1, 424, 904, 1031, -1, 422, 904, + 1031, -1, 288, 424, 904, 1031, -1, 288, 422, 904, + 1031, -1, 231, 424, 904, 1031, -1, 231, 422, 904, + 1031, -1, 447, 904, 1031, -1, 419, 1031, -1, 1031, + -1, 419, -1, -1, 99, -1, 192, -1, -1, 192, + -1, 192, 323, 503, 999, 504, -1, 99, -1, -1, + 908, -1, -1, 329, 125, 909, -1, 910, -1, 909, + 506, 910, -1, 970, 451, 997, 771, -1, 970, 770, + 771, -1, 913, 914, -1, 914, 913, -1, 913, -1, + 914, -1, 911, -1, -1, 285, 915, -1, 285, 915, + 506, 916, -1, 218, 920, 917, 919, 324, -1, 321, + 916, -1, 321, 918, 919, -1, 970, -1, 99, -1, + 970, -1, 1043, -1, 503, 970, 504, -1, -1, 972, + -1, 380, -1, 381, -1, 219, -1, 306, -1, 235, + 125, 999, -1, -1, 237, 970, -1, -1, 925, -1, + 222, 357, 324, -1, 923, -1, -1, 926, -1, 925, + 926, -1, 222, 449, 927, 881, -1, 222, 398, 927, + 881, -1, 319, 1030, -1, -1, 457, 1027, -1, 928, + 506, 1027, -1, 227, 930, -1, -1, 931, -1, 930, + 506, 931, -1, 937, -1, 937, 933, -1, 940, -1, + 940, 933, -1, 940, 108, 503, 944, 504, -1, 940, + 108, 1161, 503, 944, 504, -1, 940, 1161, 503, 944, + 504, -1, 894, -1, 894, 933, -1, 932, -1, 503, + 932, 504, 933, -1, 503, 932, 504, -1, 931, 161, + 271, 931, -1, 931, 934, 271, 931, 936, -1, 931, + 271, 931, 936, -1, 931, 304, 934, 271, 931, -1, + 931, 304, 271, 931, -1, 108, 1161, 503, 1032, 504, + -1, 108, 1161, -1, 1161, 503, 1032, 504, -1, 1161, + -1, 228, 935, -1, 282, 935, -1, 377, 935, -1, + 256, -1, 331, -1, -1, 451, 503, 1032, 504, -1, + 323, 970, -1, 1031, -1, 1031, 496, -1, 324, 1031, + -1, 324, 503, 1031, 504, -1, 937, -1, 938, 506, + 937, -1, 937, -1, 937, 1161, -1, 937, 108, 1161, + -1, 973, -1, 466, 970, -1, -1, 466, 970, -1, + 466, 163, 319, 890, -1, -1, 944, -1, -1, 945, + -1, 944, 506, 945, -1, 1161, 946, 561, -1, 948, + 947, -1, 397, 948, 947, -1, 948, 107, 501, 1041, + 502, -1, 397, 948, 107, 501, 1041, 502, -1, 948, + 107, -1, 397, 948, 107, -1, 947, 501, 502, -1, + 947, 501, 1192, 502, -1, -1, 950, -1, 952, -1, + 954, -1, 958, -1, 965, -1, 966, 968, -1, 966, + 503, 1041, 504, 968, -1, 952, -1, 955, -1, 959, + -1, 965, -1, 1162, 951, -1, 1162, 727, 951, -1, + 503, 999, 504, -1, -1, 262, -1, 263, -1, 402, + -1, 120, -1, 358, -1, 220, 953, -1, 196, 346, + -1, 178, 951, -1, 177, 951, -1, 317, 951, -1, + 123, -1, 503, 1041, 504, -1, -1, 956, -1, 957, + -1, 956, -1, 957, -1, 122, 963, 503, 999, 504, + -1, 122, 963, -1, 960, -1, 961, -1, 960, -1, + 961, -1, 962, 503, 1041, 504, 964, -1, 962, 964, + -1, 135, 963, -1, 134, 963, -1, 458, -1, 303, + 135, 963, -1, 303, 134, 963, -1, 305, 963, -1, + 460, -1, -1, 135, 396, 1161, -1, -1, 428, 503, + 1041, 504, 967, -1, 428, 967, -1, 427, 503, 1041, + 504, 967, -1, 427, 967, -1, 265, -1, 489, 486, + -1, 470, 427, 486, -1, -1, 484, -1, 299, -1, + 175, -1, 240, -1, 296, -1, 969, -1, 484, 429, + 299, -1, 175, 429, 240, -1, 175, 429, 296, -1, + 175, 429, 969, -1, 240, 429, 296, -1, 240, 429, + 969, -1, 296, 429, 969, -1, -1, 387, -1, 387, + 503, 1041, 504, -1, 972, -1, 970, 88, 946, -1, + 970, 143, 726, -1, 970, 113, 427, 486, 970, -1, + 494, 970, -1, 495, 970, -1, 970, 494, 970, -1, + 970, 495, 970, -1, 970, 496, 970, -1, 970, 497, + 970, -1, 970, 498, 970, -1, 970, 499, 970, -1, + 970, 491, 970, -1, 970, 492, 970, -1, 970, 490, + 970, -1, 970, 996, 970, -1, 996, 970, -1, 970, + 996, -1, 970, 105, 970, -1, 970, 328, 970, -1, + 309, 970, -1, 970, 284, 970, -1, 970, 284, 970, + 205, 970, -1, 970, 309, 284, 970, -1, 970, 309, + 284, 970, 205, 970, -1, 970, 243, 970, -1, 970, + 243, 970, 205, 970, -1, 970, 309, 243, 970, -1, + 970, 309, 243, 970, 205, 970, -1, 970, 400, 429, + 970, -1, 970, 400, 429, 970, 205, 970, -1, 970, + 309, 400, 429, 970, -1, 970, 309, 400, 429, 970, + 205, 970, -1, 970, 268, 314, -1, 970, 269, -1, + 970, 268, 309, 314, -1, 970, 312, -1, 992, 333, + 992, -1, 970, 268, 435, -1, 970, 268, 309, 435, + -1, 970, 268, 216, -1, 970, 268, 309, 216, -1, + 970, 268, 445, -1, 970, 268, 309, 445, -1, 970, + 268, 192, 227, 970, -1, 970, 268, 309, 192, 227, + 970, -1, 970, 268, 319, 503, 1002, 504, -1, 970, + 268, 309, 319, 503, 1002, 504, -1, 970, 119, 1024, + 971, 105, 971, -1, 970, 309, 119, 1024, 971, 105, + 971, -1, 970, 119, 416, 971, 105, 971, -1, 970, + 309, 119, 416, 971, 105, 971, -1, 970, 247, 1014, + -1, 970, 309, 247, 1014, -1, 970, 998, 993, 894, + -1, 970, 998, 993, 503, 970, 504, -1, 444, 894, + -1, 970, 268, 194, -1, 970, 268, 309, 194, -1, + 972, -1, 971, 88, 946, -1, 494, 971, -1, 495, + 971, -1, 971, 494, 971, -1, 971, 495, 971, -1, + 971, 496, 971, -1, 971, 497, 971, -1, 971, 498, + 971, -1, 971, 499, 971, -1, 971, 491, 971, -1, + 971, 492, 971, -1, 971, 490, 971, -1, 971, 996, + 971, -1, 996, 971, -1, 971, 996, -1, 971, 268, + 192, 227, 971, -1, 971, 268, 309, 192, 227, 971, + -1, 971, 268, 319, 503, 1002, 504, -1, 971, 268, + 309, 319, 503, 1002, 504, -1, 971, 268, 194, -1, + 971, 268, 309, 194, -1, 1020, -1, 1040, -1, 1178, + 1023, -1, 503, 970, 504, 1023, -1, 1015, -1, 973, + -1, 894, -1, 211, 894, -1, 107, 894, -1, 107, + 1003, -1, 992, -1, 1039, 503, 504, 985, -1, 1039, + 503, 1000, 504, 985, -1, 1039, 503, 459, 1001, 504, + 985, -1, 1039, 503, 1000, 506, 459, 1001, 504, 985, + -1, 1039, 503, 1000, 908, 504, 985, -1, 1039, 503, + 99, 1000, 907, 504, 985, -1, 1039, 503, 192, 1000, + 907, 504, 985, -1, 1039, 503, 496, 504, 985, -1, + 144, 222, 503, 970, 504, -1, 165, -1, 168, -1, + 168, 503, 1041, 504, -1, 169, -1, 169, 503, 1041, + 504, -1, 289, -1, 289, 503, 1041, 504, -1, 290, + -1, 290, 503, 1041, 504, -1, 166, -1, 170, -1, + 395, -1, 450, -1, 164, -1, 167, -1, 131, 503, + 970, 108, 946, 504, -1, 215, 503, 1005, 504, -1, + 334, 503, 1007, 504, -1, 344, 503, 1009, 504, -1, + 415, 503, 1010, 504, -1, 432, 503, 970, 108, 946, + 504, -1, 434, 503, 124, 1013, 504, -1, 434, 503, + 279, 1013, 504, -1, 434, 503, 430, 1013, 504, -1, + 434, 503, 1013, 504, -1, 315, 503, 970, 506, 970, + 504, -1, 142, 503, 999, 504, -1, 234, 503, 999, + 504, -1, 281, 503, 999, 504, -1, 476, 503, 999, + 504, -1, 477, 503, 301, 1163, 504, -1, 477, 503, + 301, 1163, 506, 976, 504, -1, 477, 503, 301, 1163, + 506, 999, 504, -1, 477, 503, 301, 1163, 506, 976, + 506, 999, 504, -1, 478, 503, 972, 981, 504, -1, + 479, 503, 977, 504, -1, 480, 503, 979, 970, 980, + 504, -1, 481, 503, 301, 1163, 504, -1, 481, 503, + 301, 1163, 506, 970, 504, -1, 482, 503, 970, 506, + 974, 975, 504, -1, 483, 503, 979, 970, 108, 948, + 504, -1, 462, 970, -1, 462, 307, 456, -1, 506, + 406, 485, -1, 506, 406, 307, -1, 506, 406, 307, + 456, -1, -1, 475, 503, 977, 504, -1, 978, -1, + 977, 506, 978, -1, 970, 108, 1163, -1, 970, -1, + 194, -1, 155, -1, 347, 467, -1, 414, 467, -1, + -1, 340, 972, -1, 340, 972, 125, 362, -1, 340, + 125, 362, 972, -1, 340, 125, 362, 972, 125, 362, + -1, 468, 983, -1, -1, 984, -1, 983, 506, 984, + -1, 1161, 108, 986, -1, 332, 986, -1, 332, 1161, + -1, -1, 503, 987, 988, 907, 989, 504, -1, 1161, + -1, -1, 339, 125, 999, -1, -1, 356, 990, -1, + 381, 990, -1, -1, 991, -1, 119, 991, 105, 991, + -1, 440, 345, -1, 440, 221, -1, 163, 380, -1, + 970, 345, -1, 970, 221, -1, 380, 503, 999, 504, + -1, 380, 503, 504, -1, 503, 999, 506, 970, 504, + -1, 106, -1, 404, -1, 99, -1, 85, -1, 995, + -1, 494, -1, 495, -1, 496, -1, 497, -1, 498, + -1, 499, -1, 491, -1, 492, -1, 490, -1, 85, + -1, 325, 503, 798, 504, -1, 994, -1, 325, 503, + 798, 504, -1, 994, -1, 325, 503, 798, 504, -1, + 284, -1, 309, 284, -1, 243, -1, 309, 243, -1, + 970, -1, 999, 506, 970, -1, 1001, -1, 1000, 506, + 1001, -1, 970, -1, 780, 90, 970, -1, 946, -1, + 1002, 506, 946, -1, 501, 999, 502, -1, 501, 1004, + 502, -1, 501, 502, -1, 1003, -1, 1004, 506, 1003, + -1, 1006, 227, 970, -1, -1, 1183, -1, 484, -1, + 299, -1, 175, -1, 240, -1, 296, -1, 387, -1, + 1181, -1, 970, 1008, 1011, 1012, -1, 970, 1008, 1011, + -1, 342, 970, -1, 971, 247, 971, -1, -1, 970, + 1011, 1012, -1, 970, 1012, 1011, -1, 970, 1011, -1, + 970, 1012, -1, 999, -1, -1, 227, 970, -1, 222, + 970, -1, 970, 227, 999, -1, 227, 999, -1, 999, + -1, 894, -1, 503, 999, 504, -1, 130, 1019, 1016, + 1018, 203, -1, 1017, -1, 1016, 1017, -1, 465, 970, + 426, 970, -1, 199, 970, -1, -1, 970, -1, -1, + 1161, -1, 1161, 1022, -1, 505, 1036, -1, 505, 496, + -1, 501, 970, 502, -1, 501, 970, 508, 970, 502, + -1, 1021, -1, 1022, 1021, -1, -1, 1023, 1021, -1, + 112, -1, -1, 970, -1, 180, -1, 1025, -1, 1026, + 506, 1025, -1, 503, 1026, 504, -1, 1029, -1, 1028, + 506, 1029, -1, 970, 108, 1163, -1, 970, 1183, -1, + 970, -1, 496, -1, 1031, -1, 1030, 506, 1031, -1, + 1161, -1, 1161, 1022, -1, 1033, -1, 1032, 506, 1033, + -1, 1161, -1, 1161, -1, 1161, -1, 1163, -1, 1161, + -1, 1181, -1, 1162, -1, 1161, 1022, -1, 1041, -1, + 1180, -1, 1181, -1, 1179, -1, 84, -1, 1039, 1181, + -1, 1039, 503, 1000, 504, 1181, -1, 949, 1181, -1, + 966, 1181, 968, -1, 966, 503, 1041, 504, 1181, 968, + -1, 435, -1, 216, -1, 314, -1, 1175, -1, 1173, + -1, 86, -1, 1161, -1, 1041, -1, 1175, -1, 494, + 1041, -1, 495, 1041, -1, 91, -1, 92, -1, 93, + -1, 94, -1, 95, -1, 96, -1, 97, -1, 98, + -1, 100, -1, 101, -1, 102, -1, 110, -1, 111, + -1, 113, -1, 114, -1, 116, -1, 117, -1, 118, + -1, 125, -1, 126, -1, 127, -1, 128, -1, 129, + -1, 132, -1, 133, -1, 136, -1, 138, -1, 139, + -1, 140, -1, 141, -1, 146, -1, 147, -1, 148, + -1, 149, -1, 151, -1, 154, -1, 155, -1, 156, + -1, 157, -1, 158, -1, 159, -1, 162, -1, 171, + -1, 172, -1, 173, -1, 174, -1, 176, -1, 179, + -1, 181, -1, 183, -1, 184, -1, 185, -1, 186, + -1, 187, -1, 189, -1, 190, -1, 191, -1, 194, + -1, 195, -1, 196, -1, 197, -1, 198, -1, 200, + -1, 201, -1, 202, -1, 204, -1, 205, -1, 207, + -1, 208, -1, 209, -1, 210, -1, 212, -1, 213, + -1, 214, -1, 217, -1, 219, -1, 221, -1, 223, + -1, 225, -1, 229, -1, 230, -1, 231, -1, 233, + -1, 236, -1, 238, -1, 239, -1, 241, -1, 242, + -1, 244, -1, 245, -1, 246, -1, 248, -1, 249, + -1, 250, -1, 251, -1, 252, -1, 253, -1, 255, + -1, 259, -1, 260, -1, 261, -1, 267, -1, 270, + -1, 272, -1, 273, -1, 274, -1, 275, -1, 276, + -1, 277, -1, 278, -1, 280, -1, 283, -1, 286, + -1, 287, -1, 288, -1, 291, -1, 292, -1, 293, + -1, 294, -1, 295, -1, 297, -1, 298, -1, 300, + -1, 301, -1, 302, -1, 306, -1, 307, -1, 310, + -1, 311, -1, 313, -1, 316, -1, 318, -1, 319, + -1, 320, -1, 322, -1, 325, -1, 326, -1, 327, + -1, 335, -1, 336, -1, 337, -1, 338, -1, 339, + -1, 340, -1, 341, -1, 343, -1, 345, -1, 348, + -1, 349, -1, 347, -1, 351, -1, 352, -1, 353, + -1, 354, -1, 355, -1, 356, -1, 357, -1, 359, + -1, 360, -1, 361, -1, 362, -1, 364, -1, 365, + -1, 366, -1, 367, -1, 368, -1, 369, -1, 370, + -1, 371, -1, 372, -1, 373, -1, 375, -1, 376, + -1, 378, -1, 379, -1, 381, -1, 382, -1, 383, + -1, 384, -1, 385, -1, 386, -1, 388, -1, 390, + -1, 391, -1, 392, -1, 393, -1, 394, -1, 396, + -1, 398, -1, 399, -1, 401, -1, 403, -1, 405, + -1, 406, -1, 407, -1, 408, -1, 409, -1, 410, + -1, 411, -1, 412, -1, 413, -1, 414, -1, 417, + -1, 418, -1, 420, -1, 421, -1, 422, -1, 423, + -1, 424, -1, 425, -1, 431, -1, 433, -1, 436, + -1, 437, -1, 438, -1, 439, -1, 440, -1, 441, + -1, 442, -1, 445, -1, 446, -1, 447, -1, 448, + -1, 449, -1, 452, -1, 453, -1, 454, -1, 455, + -1, 456, -1, 460, -1, 462, -1, 463, -1, 464, + -1, 467, -1, 470, -1, 471, -1, 472, -1, 473, + -1, 474, -1, 485, -1, 486, -1, 119, -1, 120, + -1, 122, -1, 123, -1, 135, -1, 142, -1, 177, + -1, 178, -1, 211, -1, 215, -1, 220, -1, 234, + -1, 257, -1, 263, -1, 265, -1, 281, -1, 303, + -1, 305, -1, 308, -1, 315, -1, 317, -1, 330, + -1, 334, -1, 344, -1, 346, -1, 358, -1, 380, + -1, 397, -1, 402, -1, 415, -1, 427, -1, 428, + -1, 432, -1, 434, -1, 458, -1, 475, -1, 476, + -1, 477, -1, 478, -1, 479, -1, 480, -1, 481, + -1, 482, -1, 483, -1, 115, -1, 121, -1, 144, + -1, 150, -1, 161, -1, 167, -1, 226, -1, 228, + -1, 243, -1, 256, -1, 268, -1, 269, -1, 271, + -1, 282, -1, 284, -1, 304, -1, 312, -1, 331, + -1, 332, -1, 333, -1, 377, -1, 400, -1, 461, + -1, 99, -1, 103, -1, 104, -1, 105, -1, 106, + -1, 107, -1, 108, -1, 109, -1, 112, -1, 124, + -1, 130, -1, 131, -1, 137, -1, 143, -1, 145, + -1, 153, -1, 160, -1, 164, -1, 165, -1, 166, + -1, 168, -1, 169, -1, 170, -1, 180, -1, 182, + -1, 188, -1, 192, -1, 193, -1, 199, -1, 203, + -1, 206, -1, 216, -1, 218, -1, 222, -1, 224, + -1, 227, -1, 232, -1, 235, -1, 237, -1, 247, + -1, 254, -1, 264, -1, 266, -1, 279, -1, 285, + -1, 289, -1, 290, -1, 309, -1, 314, -1, 321, + -1, 323, -1, 324, -1, 328, -1, 329, -1, 342, + -1, 350, -1, 363, -1, 374, -1, 389, -1, 395, + -1, 404, -1, 416, -1, 419, -1, 426, -1, 430, + -1, 435, -1, 444, -1, 450, -1, 451, -1, 459, + -1, 465, -1, 466, -1, 468, -1, 469, -1, -1, + 1048, 1049, -1, 1170, 1052, 513, 507, -1, 1170, 513, + 507, -1, 1170, 1072, -1, 1077, -1, 1189, -1, 73, + -1, 509, -1, 510, -1, -1, 160, 587, 419, 623, + 108, 1051, 893, 624, -1, 113, 1113, -1, 9, 429, + 1054, 1061, 1062, -1, 9, 429, 180, -1, 9, 1063, + -1, 174, 1054, -1, 1055, 1058, 1060, -1, 1056, 508, + 1057, 1060, 497, 1055, 1066, -1, 1065, -1, 1181, -1, + 1034, -1, -1, 1183, 1177, -1, 85, 1059, -1, 1057, + -1, -1, 1161, -1, 1161, 505, 1059, -1, 74, -1, + 508, 1041, -1, -1, 108, 1113, -1, -1, 450, 1063, + -1, -1, 1064, -1, 1064, 497, 1064, -1, 1064, 21, + 125, 1064, -1, 1064, 451, 1064, -1, 1042, -1, 1181, + -1, 1175, -1, 1177, -1, 85, 1067, -1, -1, 1161, + 1068, -1, 1161, 1068, 85, 1067, -1, -1, 490, 1041, + -1, 490, 1183, -1, 490, 1175, -1, 1033, -1, 1065, + -1, 179, 890, 891, 171, 892, 222, 1069, -1, 210, + 244, 1114, -1, 1073, -1, 1084, -1, 1086, -1, 631, + -1, 506, 631, -1, -1, 968, -1, 484, 429, 296, + -1, 484, 429, 387, -1, 175, 429, 175, -1, 299, + 429, 299, -1, -1, 1079, 1078, 1081, 1080, -1, 1170, + 118, 179, 34, 507, -1, 1170, 203, 179, 34, 507, + -1, -1, 1082, -1, 1073, -1, 73, -1, 1082, 1073, + -1, 1082, 73, -1, 1086, -1, 1083, 1086, -1, -1, + 70, 1085, 1093, 1109, 1165, 947, 507, -1, -1, 1090, + 1093, 1087, 1106, 507, -1, -1, 1093, 1088, 1106, 507, + -1, 1096, 507, -1, 508, 1041, -1, -1, 1091, 1092, + -1, 1091, -1, 1092, -1, 56, -1, 67, -1, 65, + -1, 50, -1, 51, -1, 69, -1, 1102, -1, 1098, + -1, 1094, -1, 1165, 503, 1074, 1075, 504, -1, 1165, + 1076, -1, 1100, -1, 204, 1159, 1095, -1, 204, 1095, + -1, 204, 1159, -1, 509, 1187, 510, -1, -1, 1100, + 1097, 509, 1083, 510, -1, 1096, -1, -1, 1101, 1099, + 509, 1083, 510, -1, 43, 1159, -1, 443, 1159, -1, + 43, -1, 443, -1, 1103, -1, 1105, 1104, -1, 44, + 35, -1, 44, 35, 262, -1, 44, -1, 44, 262, + -1, 44, 25, -1, 44, 25, 262, -1, 44, 25, + 25, -1, 44, 25, 25, 262, -1, 44, 134, -1, + 35, -1, 35, 262, -1, 262, -1, 25, -1, 25, + 262, -1, 25, 25, -1, 25, 25, 262, -1, 5, + -1, 134, -1, 196, -1, 36, -1, -1, 1107, -1, + 1106, 506, 1107, -1, 1109, 1164, 947, 1089, 1108, -1, + -1, 490, 1188, -1, -1, 496, -1, 496, 496, -1, + 179, 408, 1183, -1, 15, 1112, -1, 1113, -1, 163, + -1, 99, -1, -1, 1034, -1, 180, -1, 1065, -1, + 1065, -1, 71, -1, 17, 890, -1, 17, 99, -1, + 28, 890, 1117, -1, -1, 1118, -1, 451, 1122, -1, + 1119, -1, 451, 37, 14, 1184, -1, 451, 14, 1033, + -1, 266, 37, 14, 1184, -1, 266, 14, 1033, -1, + 266, 1033, -1, 1123, -1, 1123, 506, 1122, -1, 1124, + -1, 1175, -1, 1173, -1, 1041, -1, 494, 1041, -1, + 495, 1041, -1, 1180, -1, 494, 1180, -1, 495, 1180, + -1, 1181, -1, 1179, -1, 1182, -1, 13, 258, 1069, + 1119, -1, 13, 1126, 1069, 1119, -1, 13, 1126, 1069, + 1120, -1, 13, 258, 1069, 1121, -1, 13, 1126, 1069, + 1121, -1, 29, -1, -1, 3, 14, 1184, -1, 176, + 14, 1184, -1, 18, 14, 1184, 1130, -1, 1131, -1, + 1130, 506, 1131, -1, 1177, 490, 1136, -1, 396, 14, + 1184, 1133, -1, 1134, -1, 1133, 506, 1134, -1, 1136, + 490, 1135, -1, 1041, -1, 1177, -1, 10, -1, 18, + 14, 1184, 456, 1135, 1138, -1, 1139, -1, 1138, 506, + 1139, -1, 1177, 490, 1144, -1, 396, 14, 1184, 456, + 1135, 1141, -1, 1142, -1, 1141, 506, 1142, -1, 1144, + 490, 1143, -1, 1180, -1, 1135, -1, 495, 1180, -1, + 495, 1041, -1, 1181, -1, 8, -1, 173, -1, 11, + -1, 12, -1, 22, -1, 23, -1, 24, -1, 301, + -1, 26, -1, 27, -1, 346, -1, 31, -1, 32, + -1, 33, -1, 438, -1, 396, 4, 490, 1146, -1, + 396, 4, 429, 1146, -1, 323, -1, 320, -1, 396, + 152, 429, 1113, -1, 396, 152, 490, 1113, -1, 396, + 152, 1113, -1, -1, 438, 1149, 1165, 268, 1093, 947, + 1150, -1, 30, -1, -1, -1, 45, 1152, 1163, 268, + 1093, 947, 1150, -1, 46, 38, 1154, -1, 46, 309, + 16, 1154, -1, 46, 40, 1154, -1, 156, -1, 39, + -1, 42, -1, 20, 1033, -1, 19, 429, 1033, -1, + 193, 1033, 503, 1171, 504, -1, 193, 6, -1, 7, + 1033, 503, 1171, 504, -1, 7, 1033, -1, 1156, -1, + 1157, -1, 6, -1, 7, -1, 8, -1, 10, -1, + 11, -1, 12, -1, 16, -1, 19, -1, 20, -1, + 21, -1, 22, -1, 23, -1, 24, -1, 26, -1, + 27, -1, 31, -1, 32, -1, 33, -1, 34, -1, + 37, -1, 38, -1, 39, -1, 40, -1, 42, -1, + 9, -1, 13, -1, 15, -1, 28, -1, 45, -1, + 46, -1, 5, -1, 25, -1, 29, -1, 35, -1, + 43, -1, 36, -1, 44, -1, 1163, -1, 1183, -1, + 1044, -1, 1045, -1, 1168, -1, 1155, -1, 1166, -1, + 134, -1, 457, -1, 1183, -1, 1167, -1, 1045, -1, + 1155, -1, 1166, -1, 134, -1, 457, -1, 1183, -1, + 1167, -1, 1046, -1, 1155, -1, 1166, -1, 1158, -1, + 1164, -1, 1158, -1, 134, -1, 163, -1, 258, -1, + 262, -1, 429, -1, 443, -1, 457, -1, 1166, -1, + 1168, -1, 1165, -1, 1044, -1, 1047, -1, 1157, -1, + 152, -1, 1183, -1, 1045, -1, 1046, -1, 1156, -1, + 50, -1, 51, -1, 56, -1, 65, -1, 67, -1, + 70, -1, 69, -1, 1044, -1, 1168, -1, 152, -1, + 175, -1, 240, -1, 296, -1, 299, -1, 387, -1, + 484, -1, 1172, -1, 1169, 506, 1172, -1, 41, -1, + -1, 1187, -1, 1177, 1176, -1, 1177, -1, 1177, 1176, + -1, 1065, -1, 1177, -1, 1177, -1, 22, 1177, -1, + 22, 1033, -1, 72, -1, 87, -1, 83, -1, 81, + -1, 82, -1, 76, -1, 77, -1, 78, -1, 75, + -1, 84, -1, 80, -1, 71, -1, 79, -1, 1033, + -1, 1065, -1, 1190, -1, 503, 504, -1, 503, 1186, + 504, -1, 1185, -1, 1186, 1185, -1, 1188, -1, 1187, + 506, 1188, -1, 1186, -1, 509, 1187, 510, -1, 1190, + -1, 503, -1, 504, -1, 506, -1, 507, -1, 1183, + -1, 1041, -1, 1180, -1, 1181, -1, 496, -1, 494, + -1, 495, -1, 497, -1, 498, -1, 314, -1, 47, + -1, 48, -1, 49, -1, 50, -1, 51, -1, 52, + -1, 53, -1, 54, -1, 55, -1, 56, -1, 57, + -1, 58, -1, 60, -1, 59, -1, 61, -1, 62, + -1, 63, -1, 64, -1, 65, -1, 66, -1, 67, + -1, 68, -1, 70, -1, 69, -1, 5, -1, 204, + -1, 240, -1, 262, -1, 25, -1, 296, -1, 299, + -1, 387, -1, 35, -1, 36, -1, 43, -1, 44, + -1, 484, -1, 134, -1, 220, -1, 429, -1, 443, + -1, 458, -1, 501, -1, 502, -1, 490, -1, 508, + -1, 176, 1069, -1, 176, 348, 1069, -1, 176, 99, + -1, 176, 348, 99, -1, 1041, -1, 503, 1192, 504, + -1, 1192, 494, 1192, -1, 1192, 495, 1192, -1, 1192, + 496, 1192, -1, 1192, 497, 1192, -1, 1192, 498, 1192, + -1, 1181, -1, 1161, -1, -1, 1118, 1194, -1, 1194, + 1118, -1, 1118, -1, 1194, -1, 266, 1169, -1, 1120, + -1, 1194, -1, 1119, -1, -1, 1195, -1 +}; + +/* YYRLINE[YYN] -- source line where rule number YYN was defined. */ +static const yytype_uint16 yyrline[] = +{ + 0, 1464, 1464, 1467, 1469, 1471, 1473, 1475, 1477, 1479, + 1481, 1483, 1485, 1487, 1489, 1491, 1493, 1495, 1497, 1499, + 1501, 1503, 1505, 1507, 1509, 1511, 1513, 1515, 1517, 1519, + 1537, 1539, 1541, 1543, 1545, 1547, 1549, 1551, 1553, 1555, + 1557, 1559, 1561, 1563, 1565, 1567, 1569, 1571, 1573, 1575, + 1577, 1579, 1581, 1583, 1585, 1587, 1589, 1591, 1593, 1597, + 1599, 1601, 1603, 1605, 1607, 1609, 1611, 1613, 1615, 1617, + 1619, 1621, 1623, 1625, 1627, 1629, 1631, 1633, 1635, 1637, + 1639, 1641, 1643, 1645, 1647, 1649, 1651, 1653, 1655, 1657, + 1659, 1661, 1663, 1670, 1672, 1674, 1676, 1678, 1680, 1682, + 1684, 1686, 1688, 1690, 1692, 1698, 1700, 1702, 1704, 1706, + 1708, 1710, 1712, 1714, 1720, 1730, 1734, 1740, 1744, 1754, + 1764, 1765, 1779, 1786, 1792, 1803, 1809, 1818, 1825, 1831, + 1840, 1847, 1855, 1860, 1868, 1873, 1879, 1884, 1890, 1895, + 1901, 1905, 1909, 1913, 1917, 1921, 1925, 1929, 1933, 1941, + 1945, 1949, 1953, 1957, 1961, 1969, 1977, 1986, 1988, 1996, + 2004, 2012, 2020, 2024, 2032, 2036, 2044, 2052, 2060, 2064, + 2072, 2076, 2084, 2088, 2096, 2101, 2107, 2112, 2118, 2122, + 2126, 2130, 2134, 2138, 2146, 2150, 2154, 2162, 2166, 2170, + 2178, 2182, 2186, 2190, 2194, 2198, 2202, 2207, 2211, 2215, + 2219, 2223, 2227, 2231, 2239, 2243, 2251, 2255, 2263, 2267, + 2281, 2285, 2289, 2293, 2301, 2305, 2309, 2313, 2321, 2325, + 2329, 2333, 2337, 2341, 2345, 2353, 2357, 2362, 2368, 2372, + 2380, 2384, 2388, 2392, 2396, 2404, 2408, 2416, 2420, 2428, + 2432, 2436, 2440, 2444, 2453, 2461, 2465, 2473, 2477, 2485, + 2493, 2497, 2501, 2505, 2513, 2517, 2521, 2525, 2529, 2533, + 2537, 2541, 2549, 2553, 2561, 2565, 2569, 2573, 2577, 2581, + 2585, 2589, 2593, 2597, 2601, 2605, 2609, 2613, 2617, 2621, + 2625, 2629, 2633, 2637, 2641, 2645, 2649, 2653, 2657, 2661, + 2665, 2669, 2673, 2677, 2681, 2685, 2689, 2693, 2697, 2701, + 2705, 2709, 2713, 2717, 2721, 2725, 2733, 2737, 2745, 2749, + 2754, 2760, 2765, 2771, 2776, 2782, 2790, 2795, 2801, 2805, + 2813, 2817, 2821, 2825, 2833, 2841, 2845, 2853, 2857, 2861, + 2865, 2873, 2878, 2886, 2897, 2908, 2912, 2920, 2924, 2928, + 2936, 2940, 2948, 2953, 2959, 2963, 2967, 2971, 2975, 2979, + 2983, 2987, 2991, 2995, 2999, 3003, 3011, 3016, 3022, 3027, + 3033, 3038, 3044, 3049, 3055, 3059, 3067, 3075, 3079, 3083, + 3087, 3092, 3098, 3102, 3110, 3118, 3122, 3126, 3130, 3138, + 3142, 3146, 3150, 3154, 3158, 3162, 3167, 3173, 3178, 3184, + 3189, 3195, 3199, 3207, 3211, 3219, 3223, 3227, 3235, 3239, + 3247, 3255, 3263, 3268, 3274, 3278, 3282, 3286, 3294, 3298, + 3302, 3306, 3310, 3314, 3318, 3326, 3330, 3334, 3338, 3346, + 3354, 3358, 3363, 3369, 3373, 3377, 3381, 3385, 3389, 3397, + 3401, 3409, 3413, 3417, 3421, 3425, 3429, 3433, 3441, 3446, + 3452, 3457, 3463, 3467, 3475, 3483, 3487, 3492, 3497, 3503, + 3507, 3515, 3519, 3527, 3532, 3538, 3542, 3546, 3550, 3555, + 3561, 3569, 3577, 3581, 3585, 3589, 3593, 3601, 3606, 3612, + 3616, 3620, 3625, 3631, 3635, 3639, 3644, 3650, 3655, 3661, + 3666, 3672, 3680, 3688, 3692, 3697, 3703, 3711, 3715, 3723, + 3728, 3734, 3738, 3746, 3750, 3754, 3758, 3762, 3766, 3770, + 3774, 3778, 3782, 3786, 3790, 3798, 3803, 3809, 3813, 3817, + 3825, 3829, 3837, 3841, 3849, 3854, 3860, 3864, 3872, 3877, + 3883, 3887, 3895, 3900, 3906, 3910, 3918, 3923, 3929, 3937, + 3942, 3948, 3952, 3960, 3964, 3972, 3977, 3983, 3987, 3991, + 3999, 4007, 4012, 4018, 4026, 4030, 4034, 4038, 4042, 4046, + 4050, 4054, 4058, 4062, 4066, 4070, 4074, 4078, 4082, 4086, + 4090, 4094, 4098, 4102, 4106, 4110, 4118, 4126, 4130, 4134, + 4138, 4146, 4150, 4158, 4163, 4169, 4173, 4181, 4185, 4193, + 4198, 4204, 4208, 4216, 4224, 4228, 4236, 4240, 4244, 4248, + 4256, 4264, 4272, 4280, 4288, 4293, 4299, 4303, 4311, 4316, + 4322, 4326, 4334, 4338, 4342, 4350, 4354, 4362, 4366, 4374, + 4378, 4386, 4394, 4398, 4406, 4414, 4418, 4422, 4430, 4434, + 4442, 4450, 4454, 4462, 4466, 4470, 4478, 4482, 4490, 4494, + 4498, 4502, 4506, 4514, 4519, 4525, 4530, 4536, 4540, 4548, + 4553, 4559, 4563, 4568, 4574, 4578, 4582, 4586, 4594, 4599, + 4606, 4608, 4616, 4620, 4624, 4628, 4632, 4636, 4644, 4648, + 4656, 4665, 4674, 4678, 4682, 4686, 4690, 4694, 4698, 4702, + 4706, 4710, 4714, 4718, 4722, 4726, 4734, 4742, 4746, 4754, + 4758, 4766, 4770, 4774, 4778, 4782, 4790, 4794, 4802, 4810, + 4814, 4822, 4830, 4835, 4841, 4845, 4853, 4857, 4861, 4869, + 4877, 4881, 4889, 4893, 4897, 4901, 4905, 4913, 4918, 4924, + 4929, 4935, 4939, 4944, 4950, 4956, 4962, 4970, 4974, 4982, + 4986, 4994, 4998, 5006, 5010, 5018, 5022, 5030, 5038, 5046, + 5050, 5054, 5058, 5066, 5070, 5074, 5078, 5082, 5086, 5090, + 5094, 5098, 5102, 5106, 5110, 5114, 5118, 5122, 5130, 5134, + 5142, 5146, 5154, 5158, 5166, 5174, 5178, 5183, 5189, 5193, + 5197, 5201, 5205, 5209, 5213, 5217, 5221, 5225, 5229, 5233, + 5237, 5241, 5245, 5249, 5253, 5261, 5265, 5269, 5273, 5277, + 5281, 5285, 5289, 5293, 5297, 5301, 5305, 5309, 5313, 5317, + 5321, 5325, 5333, 5337, 5345, 5349, 5353, 5357, 5361, 5369, + 5374, 5380, 5384, 5388, 5392, 5396, 5400, 5404, 5408, 5412, + 5416, 5420, 5428, 5432, 5440, 5444, 5448, 5452, 5458, 5464, + 5470, 5476, 5482, 5488, 5494, 5504, 5515, 5526, 5537, 5548, + 5559, 5570, 5586, 5602, 5618, 5629, 5645, 5656, 5672, 5687, + 5691, 5699, 5704, 5710, 5718, 5722, 5730, 5734, 5738, 5742, + 5746, 5754, 5758, 5766, 5770, 5774, 5778, 5786, 5790, 5794, + 5798, 5802, 5806, 5810, 5814, 5818, 5822, 5826, 5830, 5834, + 5838, 5842, 5846, 5854, 5858, 5866, 5870, 5878, 5883, 5889, + 5893, 5901, 5909, 5917, 5921, 5929, 5934, 5940, 5945, 5951, + 5959, 5964, 5970, 5974, 5978, 5986, 5990, 5994, 6002, 6006, + 6010, 6014, 6022, 6030, 6035, 6041, 6046, 6052, 6057, 6063, + 6068, 6074, 6078, 6086, 6090, 6094, 6102, 6107, 6113, 6117, + 6122, 6128, 6132, 6137, 6143, 6147, 6152, 6158, 6162, 6166, + 6174, 6179, 6185, 6189, 6197, 6201, 6209, 6213, 6221, 6225, + 6233, 6237, 6241, 6245, 6249, 6257, 6261, 6265, 6269, 6273, + 6281, 6289, 6297, 6301, 6305, 6313, 6317, 6321, 6329, 6333, + 6341, 6345, 6349, 6353, 6357, 6361, 6365, 6369, 6373, 6377, + 6381, 6385, 6389, 6393, 6397, 6405, 6409, 6413, 6417, 6425, + 6429, 6437, 6442, 6448, 6456, 6460, 6468, 6476, 6480, 6488, + 6493, 6499, 6503, 6511, 6515, 6523, 6527, 6535, 6539, 6543, + 6547, 6555, 6559, 6567, 6575, 6579, 6587, 6591, 6599, 6603, + 6607, 6615, 6619, 6624, 6630, 6638, 6643, 6649, 6653, 6657, + 6665, 6669, 6677, 6682, 6688, 6692, 6696, 6700, 6704, 6708, + 6712, 6716, 6720, 6724, 6728, 6732, 6736, 6740, 6744, 6748, + 6752, 6756, 6760, 6764, 6768, 6772, 6776, 6780, 6784, 6788, + 6792, 6796, 6800, 6804, 6808, 6812, 6816, 6820, 6824, 6828, + 6832, 6836, 6840, 6844, 6848, 6856, 6861, 6867, 6872, 6878, + 6882, 6886, 6890, 6894, 6898, 6902, 6906, 6910, 6914, 6918, + 6922, 6926, 6930, 6934, 6938, 6942, 6946, 6950, 6954, 6958, + 6962, 6970, 6974, 6978, 6982, 6986, 6990, 6994, 6998, 7002, + 7006, 7010, 7014, 7018, 7022, 7026, 7030, 7034, 7038, 7046, + 7054, 7058, 7062, 7070, 7074, 7082, 7086, 7090, 7094, 7098, + 7106, 7111, 7117, 7121, 7125, 7129, 7137, 7141, 7146, 7152, + 7156, 7164, 7172, 7177, 7183, 7191, 7195, 7203, 7207, 7211, + 7215, 7219, 7223, 7227, 7231, 7235, 7239, 7243, 7247, 7251, + 7255, 7263, 7267, 7272, 7278, 7282, 7286, 7290, 7294, 7302, + 7306, 7310, 7318, 7323, 7329, 7333, 7341, 7346, 7351, 7357, + 7363, 7371, 7379, 7384, 7390, 7394, 7398, 7402, 7406, 7410, + 7414, 7418, 7422, 7426, 7430, 7434, 7438, 7442, 7446, 7450, + 7458, 7463, 7469, 7473, 7481, 7489, 7494, 7500, 7508, 7512, + 7520, 7528, 7532, 7536, 7540, 7544, 7548, 7552, 7560, 7565, + 7571, 7579, 7583, 7587, 7591, 7595, 7599, 7607, 7615, 7619, + 7623, 7631, 7636, 7642, 7646, 7650, 7654, 7658, 7666, 7670, + 7678, 7682, 7686, 7690, 7698, 7702, 7710, 7714, 7722, 7727, + 7733, 7738, 7744, 7749, 7755, 7760, 7766, 7770, 7774, 7778, + 7786, 7790, 7794, 7798, 7802, 7806, 7810, 7818, 7822, 7830, + 7838, 7842, 7846, 7854, 7858, 7863, 7869, 7875, 7885, 7890, + 7896, 7900, 7904, 7908, 7916, 7918, 7926, 7931, 7937, 7945, + 7949, 7953, 7961, 7965, 7973, 7981, 7986, 7992, 8000, 8005, + 8011, 8019, 8024, 8030, 8034, 8038, 8042, 8046, 8050, 8054, + 8058, 8066, 8071, 8077, 8085, 8089, 8097, 8101, 8109, 8117, + 8125, 8133, 8137, 8145, 8198, 8202, 8215, 8217, 8221, 8225, + 8229, 8238, 8244, 8248, 8256, 8260, 8268, 8272, 8280, 8284, + 8288, 8292, 8296, 8300, 8304, 8308, 8316, 8320, 8328, 8332, + 8336, 8340, 8344, 8348, 8356, 8360, 8368, 8372, 8380, 8388, + 8393, 8399, 8404, 8406, 8412, 8416, 8420, 8424, 8428, 8432, + 8436, 8440, 8444, 8452, 8457, 8463, 8467, 8472, 8478, 8482, + 8486, 8491, 8497, 8502, 8508, 8516, 8520, 8528, 8532, 8540, + 8544, 8548, 8552, 8560, 8565, 8571, 8575, 8580, 8588, 8592, + 8600, 8604, 8612, 8620, 8624, 8629, 8635, 8643, 8647, 8655, + 8659, 8667, 8672, 8678, 8683, 8689, 8693, 8701, 8706, 8712, + 8716, 8724, 8728, 8736, 8741, 8747, 8751, 8759, 8764, 8770, + 8774, 8782, 8786, 8790, 8794, 8798, 8802, 8806, 8810, 8816, + 8820, 8824, 8832, 8836, 8840, 8844, 8848, 8852, 8860, 8864, + 8868, 8872, 8880, 8884, 8888, 8892, 8900, 8905, 8911, 8915, + 8923, 8927, 8931, 8935, 8943, 8947, 8955, 8959, 8963, 8971, + 8979, 8984, 8990, 8994, 9000, 9006, 9011, 9017, 9021, 9029, + 9037, 9039, 9041, 9045, 9049, 9053, 9061, 9071, 9082, 9091, + 9095, 9099, 9103, 9107, 9111, 9115, 9123, 9127, 9131, 9135, + 9143, 9147, 9155, 9160, 9166, 9170, 9174, 9178, 9182, 9186, + 9190, 9194, 9198, 9202, 9206, 9214, 9219, 9225, 9229, 9237, + 9241, 9249, 9257, 9265, 9269, 9277, 9281, 9289, 9297, 9305, + 9309, 9313, 9317, 9321, 9325, 9333, 9338, 9344, 9349, 9355, + 9359, 9363, 9367, 9375, 9383, 9387, 9392, 9398, 9402, 9406, + 9410, 9414, 9418, 9422, 9426, 9430, 9434, 9438, 9442, 9446, + 9451, 9457, 9461, 9469, 9473, 9477, 9481, 9485, 9489, 9493, + 9497, 9501, 9505, 9509, 9513, 9517, 9521, 9525, 9529, 9533, + 9537, 9541, 9545, 9549, 9553, 9557, 9561, 9565, 9569, 9573, + 9577, 9581, 9585, 9589, 9593, 9597, 9601, 9605, 9609, 9613, + 9617, 9621, 9625, 9629, 9633, 9637, 9641, 9645, 9649, 9653, + 9657, 9661, 9665, 9669, 9673, 9677, 9681, 9685, 9689, 9693, + 9698, 9702, 9710, 9714, 9718, 9722, 9726, 9730, 9734, 9738, + 9742, 9746, 9750, 9754, 9758, 9762, 9766, 9770, 9774, 9778, + 9782, 9786, 9790, 9794, 9802, 9806, 9810, 9814, 9818, 9822, + 9826, 9830, 9834, 9838, 9842, 9850, 9854, 9858, 9862, 9866, + 9870, 9874, 9878, 9882, 9886, 9890, 9894, 9898, 9902, 9906, + 9910, 9914, 9918, 9922, 9926, 9930, 9934, 9938, 9942, 9946, + 9950, 9954, 9958, 9962, 9966, 9970, 9974, 9978, 9982, 9986, + 9990, 9994, 9998, 10002, 10006, 10010, 10014, 10018, 10022, 10026, + 10030, 10034, 10038, 10042, 10046, 10054, 10058, 10066, 10070, 10074, + 10079, 10085, 10093, 10097, 10105, 10109, 10117, 10121, 10129, 10133, + 10138, 10144, 10148, 10152, 10156, 10164, 10169, 10175, 10179, 10187, + 10195, 10199, 10204, 10210, 10218, 10222, 10229, 10234, 10240, 10245, + 10250, 10256, 10260, 10268, 10272, 10276, 10280, 10284, 10292, 10296, + 10300, 10308, 10312, 10316, 10324, 10328, 10336, 10340, 10344, 10348, + 10352, 10356, 10360, 10364, 10368, 10376, 10380, 10388, 10392, 10400, + 10404, 10408, 10412, 10416, 10420, 10428, 10432, 10440, 10444, 10452, + 10456, 10464, 10468, 10476, 10480, 10484, 10492, 10496, 10504, 10509, + 10515, 10519, 10523, 10527, 10531, 10535, 10539, 10543, 10551, 10555, + 10563, 10571, 10576, 10582, 10586, 10590, 10594, 10598, 10603, 10609, + 10617, 10625, 10629, 10633, 10641, 10645, 10653, 10661, 10665, 10673, + 10681, 10686, 10692, 10697, 10703, 10707, 10715, 10719, 10723, 10727, + 10735, 10739, 10748, 10750, 10758, 10763, 10769, 10773, 10781, 10785, + 10793, 10801, 10805, 10813, 10817, 10821, 10825, 10833, 10837, 10845, + 10849, 10857, 10861, 10869, 10877, 10885, 10893, 10901, 10909, 10917, + 10921, 10929, 10933, 10937, 10941, 10945, 10949, 10953, 10957, 10961, + 10965, 10969, 10973, 10977, 10981, 10982, 10987, 10993, 11001, 11005, + 11006, 11010, 11018, 11022, 11026, 11030, 11034, 11038, 11042, 11046, + 11050, 11054, 11058, 11062, 11066, 11070, 11074, 11078, 11082, 11086, + 11090, 11094, 11098, 11102, 11106, 11110, 11114, 11118, 11122, 11126, + 11130, 11134, 11138, 11142, 11146, 11150, 11154, 11158, 11162, 11166, + 11170, 11174, 11178, 11182, 11186, 11190, 11194, 11198, 11202, 11206, + 11210, 11214, 11218, 11222, 11226, 11230, 11234, 11238, 11242, 11246, + 11250, 11254, 11258, 11262, 11266, 11270, 11274, 11278, 11282, 11286, + 11290, 11294, 11298, 11302, 11306, 11310, 11314, 11318, 11322, 11326, + 11330, 11334, 11338, 11342, 11346, 11350, 11354, 11358, 11362, 11366, + 11370, 11374, 11378, 11382, 11386, 11390, 11394, 11398, 11402, 11406, + 11410, 11414, 11418, 11422, 11426, 11430, 11434, 11438, 11442, 11446, + 11450, 11454, 11458, 11462, 11466, 11470, 11474, 11478, 11482, 11486, + 11490, 11494, 11498, 11502, 11506, 11510, 11514, 11518, 11522, 11526, + 11530, 11534, 11538, 11542, 11546, 11550, 11554, 11558, 11562, 11566, + 11570, 11574, 11578, 11582, 11586, 11590, 11594, 11598, 11602, 11606, + 11610, 11614, 11618, 11622, 11626, 11630, 11634, 11638, 11642, 11646, + 11650, 11654, 11658, 11662, 11666, 11670, 11674, 11678, 11682, 11686, + 11690, 11694, 11698, 11702, 11706, 11710, 11714, 11718, 11722, 11726, + 11730, 11734, 11738, 11742, 11746, 11750, 11754, 11758, 11762, 11766, + 11770, 11774, 11778, 11782, 11786, 11790, 11794, 11798, 11802, 11806, + 11810, 11814, 11818, 11822, 11826, 11830, 11834, 11838, 11842, 11846, + 11850, 11854, 11858, 11862, 11866, 11870, 11874, 11878, 11882, 11886, + 11890, 11894, 11898, 11902, 11906, 11910, 11914, 11918, 11922, 11926, + 11930, 11934, 11938, 11942, 11946, 11950, 11954, 11958, 11962, 11966, + 11970, 11974, 11978, 11986, 11990, 11994, 11998, 12002, 12006, 12010, + 12014, 12018, 12022, 12026, 12030, 12034, 12038, 12042, 12046, 12050, + 12054, 12058, 12062, 12066, 12070, 12074, 12078, 12082, 12086, 12090, + 12094, 12098, 12102, 12106, 12110, 12114, 12118, 12122, 12126, 12130, + 12134, 12138, 12142, 12146, 12150, 12154, 12158, 12166, 12170, 12174, + 12178, 12182, 12186, 12190, 12194, 12198, 12202, 12206, 12210, 12214, + 12218, 12222, 12226, 12230, 12234, 12238, 12242, 12246, 12250, 12254, + 12262, 12266, 12270, 12274, 12278, 12282, 12286, 12290, 12294, 12298, + 12302, 12306, 12310, 12314, 12318, 12322, 12326, 12330, 12334, 12338, + 12342, 12346, 12350, 12354, 12358, 12362, 12366, 12370, 12374, 12378, + 12382, 12386, 12390, 12394, 12398, 12402, 12406, 12410, 12414, 12418, + 12422, 12426, 12430, 12434, 12438, 12442, 12446, 12450, 12454, 12458, + 12462, 12466, 12470, 12474, 12478, 12482, 12486, 12490, 12494, 12498, + 12502, 12506, 12510, 12514, 12518, 12522, 12526, 12530, 12534, 12538, + 12542, 12546, 12550, 12554, 12564, 12565, 12568, 12569, 12570, 12576, + 12577, 12578, 12579, 12580, 12593, 12593, 12602, 12617, 12619, 12622, + 12624, 12628, 12640, 12656, 12660, 12671, 12672, 12675, 12687, 12696, + 12697, 12700, 12701, 12702, 12705, 12706, 12709, 12710, 12713, 12714, + 12717, 12719, 12721, 12723, 12727, 12734, 12741, 12757, 12791, 12801, + 12804, 12808, 12821, 12822, 12824, 12826, 12830, 12844, 12851, 12912, + 12921, 12923, 12924, 12927, 12929, 12930, 12933, 12934, 12935, 12936, + 12937, 12944, 12943, 12953, 12955, 12957, 12958, 12961, 12962, 12963, + 12964, 12967, 12968, 12972, 12971, 12988, 12986, 13002, 13001, 13015, + 13021, 13022, 13025, 13027, 13028, 13031, 13032, 13033, 13034, 13037, + 13038, 13041, 13049, 13066, 13074, 13097, 13203, 13237, 13239, 13241, + 13245, 13249, 13248, 13299, 13301, 13300, 13315, 13321, 13328, 13333, + 13339, 13340, 13343, 13344, 13345, 13346, 13347, 13348, 13349, 13357, + 13365, 13368, 13369, 13370, 13371, 13372, 13373, 13381, 13389, 13390, + 13391, 13394, 13395, 13398, 13400, 13404, 13492, 13493, 13500, 13501, + 13502, 13508, 13517, 13520, 13521, 13522, 13523, 13526, 13527, 13528, + 13531, 13533, 13541, 13542, 13548, 13556, 13557, 13560, 13561, 13564, + 13569, 13576, 13581, 13588, 13595, 13595, 13597, 13604, 13605, 13608, + 13609, 13610, 13611, 13612, 13613, 13614, 13615, 13616, 13622, 13629, + 13641, 13647, 13654, 13662, 13663, 13675, 13686, 13697, 13701, 13702, + 13705, 13710, 13714, 13715, 13718, 13724, 13732, 13738, 13745, 13749, + 13750, 13753, 13756, 13760, 13761, 13764, 13770, 13779, 13784, 13794, + 13804, 13816, 13817, 13818, 13819, 13820, 13821, 13822, 13823, 13824, + 13825, 13826, 13827, 13828, 13829, 13830, 13837, 13838, 13841, 13842, + 13849, 13850, 13851, 13858, 13857, 13874, 13875, 13882, 13881, 13951, + 13957, 13963, 13971, 13977, 13983, 13989, 13995, 14001, 14007, 14013, + 14019, 14030, 14031, 14034, 14035, 14036, 14037, 14038, 14039, 14040, + 14041, 14042, 14043, 14044, 14045, 14046, 14047, 14048, 14049, 14050, + 14051, 14052, 14053, 14054, 14055, 14056, 14057, 14060, 14061, 14062, + 14063, 14064, 14065, 14069, 14070, 14071, 14072, 14073, 14074, 14075, + 14078, 14081, 14082, 14083, 14084, 14085, 14086, 14087, 14088, 14101, + 14102, 14103, 14104, 14105, 14106, 14107, 14112, 14113, 14114, 14115, + 14116, 14117, 14123, 14124, 14125, 14126, 14127, 14128, 14129, 14130, + 14131, 14132, 14133, 14136, 14137, 14138, 14139, 14140, 14143, 14144, + 14145, 14146, 14149, 14150, 14151, 14152, 14153, 14154, 14155, 14172, + 14173, 14174, 14177, 14178, 14179, 14180, 14181, 14182, 14186, 14186, + 14189, 14195, 14196, 14199, 14201, 14206, 14216, 14227, 14234, 14235, + 14236, 14239, 14272, 14274, 14276, 14279, 14289, 14299, 14309, 14310, + 14313, 14315, 14316, 14317, 14320, 14322, 14330, 14331, 14332, 14336, + 14337, 14341, 14342, 14345, 14346, 14349, 14350, 14351, 14352, 14353, + 14356, 14357, 14358, 14359, 14360, 14361, 14362, 14363, 14364, 14365, + 14366, 14367, 14368, 14369, 14370, 14371, 14372, 14373, 14374, 14375, + 14376, 14377, 14378, 14379, 14380, 14381, 14382, 14383, 14384, 14385, + 14386, 14387, 14388, 14389, 14390, 14391, 14392, 14393, 14394, 14395, + 14396, 14397, 14398, 14399, 14400, 14401, 14402, 14403, 14404, 14405, + 14406, 14407, 14408, 14409, 14410, 14411, 14414, 14415, 14416, 14417, + 14420, 14421, 14422, 14423, 14424, 14425, 14426, 14427, 14428, 14431, + 14432, 14433, 14434, 14435, 14438, 14439, 14442, 14443, 14454, 14455 +}; +#endif + +#if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE +/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM. + First, the terminals, then, starting at YYNTOKENS, nonterminals. */ +static const char *const yytname[] = +{ + "$end", "error", "$undefined", "SQL_ALLOCATE", "SQL_AUTOCOMMIT", + "SQL_BOOL", "SQL_BREAK", "SQL_CALL", "SQL_CARDINALITY", "SQL_CONNECT", + "SQL_COUNT", "SQL_DATETIME_INTERVAL_CODE", + "SQL_DATETIME_INTERVAL_PRECISION", "SQL_DESCRIBE", "SQL_DESCRIPTOR", + "SQL_DISCONNECT", "SQL_FOUND", "SQL_FREE", "SQL_GET", "SQL_GO", + "SQL_GOTO", "SQL_IDENTIFIED", "SQL_INDICATOR", "SQL_KEY_MEMBER", + "SQL_LENGTH", "SQL_LONG", "SQL_NULLABLE", "SQL_OCTET_LENGTH", "SQL_OPEN", + "SQL_OUTPUT", "SQL_REFERENCE", "SQL_RETURNED_LENGTH", + "SQL_RETURNED_OCTET_LENGTH", "SQL_SCALE", "SQL_SECTION", "SQL_SHORT", + "SQL_SIGNED", "SQL_SQL", "SQL_SQLERROR", "SQL_SQLPRINT", + "SQL_SQLWARNING", "SQL_START", "SQL_STOP", "SQL_STRUCT", "SQL_UNSIGNED", + "SQL_VAR", "SQL_WHENEVER", "S_ADD", "S_AND", "S_ANYTHING", "S_AUTO", + "S_CONST", "S_DEC", "S_DIV", "S_DOTPOINT", "S_EQUAL", "S_EXTERN", + "S_INC", "S_LSHIFT", "S_MEMPOINT", "S_MEMBER", "S_MOD", "S_MUL", + "S_NEQUAL", "S_OR", "S_REGISTER", "S_RSHIFT", "S_STATIC", "S_SUB", + "S_VOLATILE", "S_TYPEDEF", "CSTRING", "CVARIABLE", "CPP_LINE", "IP", + "DOLCONST", "ECONST", "NCONST", "UCONST", "UIDENT", "IDENT", "FCONST", + "SCONST", "BCONST", "XCONST", "Op", "ICONST", "PARAM", "TYPECAST", + "DOT_DOT", "COLON_EQUALS", "ABORT_P", "ABSOLUTE_P", "ACCESS", "ACTION", + "ADD_P", "ADMIN", "AFTER", "AGGREGATE", "ALL", "ALSO", "ALTER", "ALWAYS", + "ANALYSE", "ANALYZE", "AND", "ANY", "ARRAY", "AS", "ASC", "ASSERTION", + "ASSIGNMENT", "ASYMMETRIC", "AT", "ATTRIBUTE", "AUTHORIZATION", + "BACKWARD", "BEFORE", "BEGIN_P", "BETWEEN", "BIGINT", "BINARY", "BIT", + "BOOLEAN_P", "BOTH", "BY", "CACHE", "CALLED", "CASCADE", "CASCADED", + "CASE", "CAST", "CATALOG_P", "CHAIN", "CHAR_P", "CHARACTER", + "CHARACTERISTICS", "CHECK", "CHECKPOINT", "CLASS", "CLOSE", "CLUSTER", + "COALESCE", "COLLATE", "COLLATION", "COLUMN", "COMMENT", "COMMENTS", + "COMMIT", "COMMITTED", "CONCURRENTLY", "CONFIGURATION", "CONNECTION", + "CONSTRAINT", "CONSTRAINTS", "CONTENT_P", "CONTINUE_P", "CONVERSION_P", + "COPY", "COST", "CREATE", "CROSS", "CSV", "CURRENT_P", "CURRENT_CATALOG", + "CURRENT_DATE", "CURRENT_ROLE", "CURRENT_SCHEMA", "CURRENT_TIME", + "CURRENT_TIMESTAMP", "CURRENT_USER", "CURSOR", "CYCLE", "DATA_P", + "DATABASE", "DAY_P", "DEALLOCATE", "DEC", "DECIMAL_P", "DECLARE", + "DEFAULT", "DEFAULTS", "DEFERRABLE", "DEFERRED", "DEFINER", "DELETE_P", + "DELIMITER", "DELIMITERS", "DESC", "DICTIONARY", "DISABLE_P", "DISCARD", + "DISTINCT", "DO", "DOCUMENT_P", "DOMAIN_P", "DOUBLE_P", "DROP", "EACH", + "ELSE", "ENABLE_P", "ENCODING", "ENCRYPTED", "END_P", "ENUM_P", "ESCAPE", + "EXCEPT", "EXCLUDE", "EXCLUDING", "EXCLUSIVE", "EXECUTE", "EXISTS", + "EXPLAIN", "EXTENSION", "EXTERNAL", "EXTRACT", "FALSE_P", "FAMILY", + "FETCH", "FIRST_P", "FLOAT_P", "FOLLOWING", "FOR", "FORCE", "FOREIGN", + "FORWARD", "FREEZE", "FROM", "FULL", "FUNCTION", "FUNCTIONS", "GLOBAL", + "GRANT", "GRANTED", "GREATEST", "GROUP_P", "HANDLER", "HAVING", + "HEADER_P", "HOLD", "HOUR_P", "IDENTITY_P", "IF_P", "ILIKE", "IMMEDIATE", + "IMMUTABLE", "IMPLICIT_P", "IN_P", "INCLUDING", "INCREMENT", "INDEX", + "INDEXES", "INHERIT", "INHERITS", "INITIALLY", "INLINE_P", "INNER_P", + "INOUT", "INPUT_P", "INSENSITIVE", "INSERT", "INSTEAD", "INT_P", + "INTEGER", "INTERSECT", "INTERVAL", "INTO", "INVOKER", "IS", "ISNULL", + "ISOLATION", "JOIN", "KEY", "LABEL", "LANGUAGE", "LARGE_P", "LAST_P", + "LC_COLLATE_P", "LC_CTYPE_P", "LEADING", "LEAKPROOF", "LEAST", "LEFT", + "LEVEL", "LIKE", "LIMIT", "LISTEN", "LOAD", "LOCAL", "LOCALTIME", + "LOCALTIMESTAMP", "LOCATION", "LOCK_P", "MAPPING", "MATCH", "MAXVALUE", + "MINUTE_P", "MINVALUE", "MODE", "MONTH_P", "MOVE", "NAME_P", "NAMES", + "NATIONAL", "NATURAL", "NCHAR", "NEXT", "NO", "NONE", "NOT", "NOTHING", + "NOTIFY", "NOTNULL", "NOWAIT", "NULL_P", "NULLIF", "NULLS_P", "NUMERIC", + "OBJECT_P", "OF", "OFF", "OFFSET", "OIDS", "ON", "ONLY", "OPERATOR", + "OPTION", "OPTIONS", "OR", "ORDER", "OUT_P", "OUTER_P", "OVER", + "OVERLAPS", "OVERLAY", "OWNED", "OWNER", "PARSER", "PARTIAL", + "PARTITION", "PASSING", "PASSWORD", "PLACING", "PLANS", "POSITION", + "PRECEDING", "PRECISION", "PRESERVE", "PREPARE", "PREPARED", "PRIMARY", + "PRIOR", "PRIVILEGES", "PROCEDURAL", "PROCEDURE", "QUOTE", "RANGE", + "READ", "REAL", "REASSIGN", "RECHECK", "RECURSIVE", "REF", "REFERENCES", + "REINDEX", "RELATIVE_P", "RELEASE", "RENAME", "REPEATABLE", "REPLACE", + "REPLICA", "RESET", "RESTART", "RESTRICT", "RETURNING", "RETURNS", + "REVOKE", "RIGHT", "ROLE", "ROLLBACK", "ROW", "ROWS", "RULE", + "SAVEPOINT", "SCHEMA", "SCROLL", "SEARCH", "SECOND_P", "SECURITY", + "SELECT", "SEQUENCE", "SEQUENCES", "SERIALIZABLE", "SERVER", "SESSION", + "SESSION_USER", "SET", "SETOF", "SHARE", "SHOW", "SIMILAR", "SIMPLE", + "SMALLINT", "SNAPSHOT", "SOME", "STABLE", "STANDALONE_P", "START", + "STATEMENT", "STATISTICS", "STDIN", "STDOUT", "STORAGE", "STRICT_P", + "STRIP_P", "SUBSTRING", "SYMMETRIC", "SYSID", "SYSTEM_P", "TABLE", + "TABLES", "TABLESPACE", "TEMP", "TEMPLATE", "TEMPORARY", "TEXT_P", + "THEN", "TIME", "TIMESTAMP", "TO", "TRAILING", "TRANSACTION", "TREAT", + "TRIGGER", "TRIM", "TRUE_P", "TRUNCATE", "TRUSTED", "TYPE_P", "TYPES_P", + "UNBOUNDED", "UNCOMMITTED", "UNENCRYPTED", "UNION", "UNIQUE", "UNKNOWN", + "UNLISTEN", "UNLOGGED", "UNTIL", "UPDATE", "USER", "USING", "VACUUM", + "VALID", "VALIDATE", "VALIDATOR", "VALUE_P", "VALUES", "VARCHAR", + "VARIADIC", "VARYING", "VERBOSE", "VERSION_P", "VIEW", "VOLATILE", + "WHEN", "WHERE", "WHITESPACE_P", "WINDOW", "WITH", "WITHOUT", "WORK", + "WRAPPER", "WRITE", "XML_P", "XMLATTRIBUTES", "XMLCONCAT", "XMLELEMENT", + "XMLEXISTS", "XMLFOREST", "XMLPARSE", "XMLPI", "XMLROOT", "XMLSERIALIZE", + "YEAR_P", "YES_P", "ZONE", "NULLS_FIRST", "NULLS_LAST", "WITH_TIME", + "'='", "'<'", "'>'", "POSTFIXOP", "'+'", "'-'", "'*'", "'/'", "'%'", + "'^'", "UMINUS", "'['", "']'", "'('", "')'", "'.'", "','", "';'", "':'", + "'{'", "'}'", "$accept", "prog", "stmt", "CreateRoleStmt", "opt_with", + "OptRoleList", "AlterOptRoleList", "AlterOptRoleElem", + "CreateOptRoleElem", "CreateUserStmt", "AlterRoleStmt", + "opt_in_database", "AlterRoleSetStmt", "AlterUserStmt", + "AlterUserSetStmt", "DropRoleStmt", "DropUserStmt", "CreateGroupStmt", + "AlterGroupStmt", "add_drop", "DropGroupStmt", "CreateSchemaStmt", + "OptSchemaName", "OptSchemaEltList", "schema_stmt", "VariableSetStmt", + "set_rest", "set_rest_more", "var_name", "var_list", "var_value", + "iso_level", "opt_boolean_or_string", "zone_value", "opt_encoding", + "ColId_or_Sconst", "VariableResetStmt", "SetResetClause", + "FunctionSetResetClause", "VariableShowStmt", "ConstraintsSetStmt", + "constraints_set_list", "constraints_set_mode", "CheckPointStmt", + "DiscardStmt", "AlterTableStmt", "alter_table_cmds", "alter_table_cmd", + "alter_column_default", "opt_drop_behavior", "opt_collate_clause", + "alter_using", "reloptions", "opt_reloptions", "reloption_list", + "reloption_elem", "AlterCompositeTypeStmt", "alter_type_cmds", + "alter_type_cmd", "ClosePortalStmt", "CopyStmt", "copy_from", + "copy_file_name", "copy_options", "copy_opt_list", "copy_opt_item", + "opt_binary", "opt_oids", "copy_delimiter", "opt_using", + "copy_generic_opt_list", "copy_generic_opt_elem", "copy_generic_opt_arg", + "copy_generic_opt_arg_list", "copy_generic_opt_arg_list_item", + "CreateStmt", "OptTemp", "OptTableElementList", + "OptTypedTableElementList", "TableElementList", "TypedTableElementList", + "TableElement", "TypedTableElement", "columnDef", "columnOptions", + "ColQualList", "ColConstraint", "ColConstraintElem", "ConstraintAttr", + "TableLikeClause", "TableLikeOptionList", "TableLikeOption", + "TableConstraint", "ConstraintElem", "opt_no_inherit", "opt_column_list", + "columnList", "columnElem", "key_match", "ExclusionConstraintList", + "ExclusionConstraintElem", "ExclusionWhereClause", "key_actions", + "key_update", "key_delete", "key_action", "OptInherit", "OptWith", + "OnCommitOption", "OptTableSpace", "OptConsTableSpace", "ExistingIndex", + "create_as_target", "opt_with_data", "CreateSeqStmt", "AlterSeqStmt", + "OptSeqOptList", "SeqOptList", "SeqOptElem", "opt_by", "NumericOnly", + "NumericOnly_list", "CreatePLangStmt", "opt_trusted", "handler_name", + "opt_inline_handler", "validator_clause", "opt_validator", + "DropPLangStmt", "opt_procedural", "CreateTableSpaceStmt", + "OptTableSpaceOwner", "DropTableSpaceStmt", "CreateExtensionStmt", + "create_extension_opt_list", "create_extension_opt_item", + "AlterExtensionStmt", "alter_extension_opt_list", + "alter_extension_opt_item", "AlterExtensionContentsStmt", + "CreateFdwStmt", "fdw_option", "fdw_options", "opt_fdw_options", + "DropFdwStmt", "AlterFdwStmt", "create_generic_options", + "generic_option_list", "alter_generic_options", + "alter_generic_option_list", "alter_generic_option_elem", + "generic_option_elem", "generic_option_name", "generic_option_arg", + "CreateForeignServerStmt", "opt_type", "foreign_server_version", + "opt_foreign_server_version", "DropForeignServerStmt", + "AlterForeignServerStmt", "CreateForeignTableStmt", + "OptForeignTableElementList", "ForeignTableElementList", + "ForeignTableElement", "AlterForeignTableStmt", "CreateUserMappingStmt", + "auth_ident", "DropUserMappingStmt", "AlterUserMappingStmt", + "CreateTrigStmt", "TriggerActionTime", "TriggerEvents", + "TriggerOneEvent", "TriggerForSpec", "TriggerForOptEach", + "TriggerForType", "TriggerWhen", "TriggerFuncArgs", "TriggerFuncArg", + "OptConstrFromTable", "ConstraintAttributeSpec", + "ConstraintAttributeElem", "DropTrigStmt", "CreateAssertStmt", + "DropAssertStmt", "DefineStmt", "definition", "def_list", "def_elem", + "def_arg", "aggr_args", "old_aggr_definition", "old_aggr_list", + "old_aggr_elem", "opt_enum_val_list", "enum_val_list", "AlterEnumStmt", + "CreateOpClassStmt", "opclass_item_list", "opclass_item", "opt_default", + "opt_opfamily", "opclass_purpose", "opt_recheck", "CreateOpFamilyStmt", + "AlterOpFamilyStmt", "opclass_drop_list", "opclass_drop", + "DropOpClassStmt", "DropOpFamilyStmt", "DropOwnedStmt", + "ReassignOwnedStmt", "DropStmt", "drop_type", "any_name_list", + "any_name", "attrs", "TruncateStmt", "opt_restart_seqs", "CommentStmt", + "comment_type", "comment_text", "SecLabelStmt", "opt_provider", + "security_label_type", "security_label", "FetchStmt", "fetch_args", + "from_in", "opt_from_in", "GrantStmt", "RevokeStmt", "privileges", + "privilege_list", "privilege", "privilege_target", "grantee_list", + "grantee", "opt_grant_grant_option", "function_with_argtypes_list", + "function_with_argtypes", "GrantRoleStmt", "RevokeRoleStmt", + "opt_grant_admin_option", "opt_granted_by", "AlterDefaultPrivilegesStmt", + "DefACLOptionList", "DefACLOption", "DefACLAction", + "defacl_privilege_target", "IndexStmt", "opt_unique", "opt_concurrently", + "opt_index_name", "access_method_clause", "index_params", "index_elem", + "opt_collate", "opt_class", "opt_asc_desc", "opt_nulls_order", + "CreateFunctionStmt", "opt_or_replace", "func_args", "func_args_list", + "func_args_with_defaults", "func_args_with_defaults_list", "func_arg", + "arg_class", "param_name", "func_return", "func_type", + "func_arg_with_default", "createfunc_opt_list", "common_func_opt_item", + "createfunc_opt_item", "func_as", "opt_definition", "table_func_column", + "table_func_column_list", "AlterFunctionStmt", "alterfunc_opt_list", + "opt_restrict", "RemoveFuncStmt", "RemoveAggrStmt", "RemoveOperStmt", + "oper_argtypes", "any_operator", "DoStmt", "dostmt_opt_list", + "dostmt_opt_item", "CreateCastStmt", "cast_context", "DropCastStmt", + "opt_if_exists", "ReindexStmt", "reindex_type", "opt_force", + "RenameStmt", "opt_column", "opt_set_data", "AlterObjectSchemaStmt", + "AlterOwnerStmt", "RuleStmt", "RuleActionList", "RuleActionMulti", + "RuleActionStmt", "RuleActionStmtOrEmpty", "event", "opt_instead", + "DropRuleStmt", "NotifyStmt", "notify_payload", "ListenStmt", + "UnlistenStmt", "TransactionStmt", "opt_transaction", + "transaction_mode_item", "transaction_mode_list", + "transaction_mode_list_or_empty", "ViewStmt", "opt_check_option", + "LoadStmt", "CreatedbStmt", "createdb_opt_list", "createdb_opt_item", + "opt_equal", "AlterDatabaseStmt", "AlterDatabaseSetStmt", + "alterdb_opt_list", "alterdb_opt_item", "DropdbStmt", "CreateDomainStmt", + "AlterDomainStmt", "opt_as", "AlterTSDictionaryStmt", + "AlterTSConfigurationStmt", "CreateConversionStmt", "ClusterStmt", + "cluster_index_specification", "VacuumStmt", "vacuum_option_list", + "vacuum_option_elem", "AnalyzeStmt", "analyze_keyword", "opt_verbose", + "opt_full", "opt_freeze", "opt_name_list", "ExplainStmt", + "ExplainableStmt", "explain_option_list", "explain_option_elem", + "explain_option_name", "explain_option_arg", "PrepareStmt", + "prep_type_clause", "PreparableStmt", "ExecuteStmt", + "execute_param_clause", "InsertStmt", "insert_rest", + "insert_column_list", "insert_column_item", "returning_clause", + "DeleteStmt", "using_clause", "LockStmt", "opt_lock", "lock_type", + "opt_nowait", "UpdateStmt", "set_clause_list", "set_clause", + "single_set_clause", "multiple_set_clause", "set_target", + "set_target_list", "DeclareCursorStmt", "cursor_name", "cursor_options", + "opt_hold", "SelectStmt", "select_with_parens", "select_no_parens", + "select_clause", "simple_select", "with_clause", "cte_list", + "common_table_expr", "opt_with_clause", "into_clause", + "OptTempTableName", "opt_table", "opt_all", "opt_distinct", + "opt_sort_clause", "sort_clause", "sortby_list", "sortby", + "select_limit", "opt_select_limit", "limit_clause", "offset_clause", + "select_limit_value", "select_offset_value", + "opt_select_fetch_first_value", "select_offset_value2", "row_or_rows", + "first_or_next", "group_clause", "having_clause", "for_locking_clause", + "opt_for_locking_clause", "for_locking_items", "for_locking_item", + "locked_rels_list", "values_clause", "from_clause", "from_list", + "table_ref", "joined_table", "alias_clause", "join_type", "join_outer", + "join_qual", "relation_expr", "relation_expr_list", + "relation_expr_opt_alias", "func_table", "where_clause", + "where_or_current_clause", "OptTableFuncElementList", + "TableFuncElementList", "TableFuncElement", "Typename", + "opt_array_bounds", "SimpleTypename", "ConstTypename", "GenericType", + "opt_type_modifiers", "Numeric", "opt_float", "Bit", "ConstBit", + "BitWithLength", "BitWithoutLength", "Character", "ConstCharacter", + "CharacterWithLength", "CharacterWithoutLength", "character", + "opt_varying", "opt_charset", "ConstDatetime", "ConstInterval", + "opt_timezone", "opt_interval", "interval_second", "a_expr", "b_expr", + "c_expr", "func_expr", "xml_root_version", "opt_xml_root_standalone", + "xml_attributes", "xml_attribute_list", "xml_attribute_el", + "document_or_content", "xml_whitespace_option", "xmlexists_argument", + "window_clause", "window_definition_list", "window_definition", + "over_clause", "window_specification", "opt_existing_window_name", + "opt_partition_clause", "opt_frame_clause", "frame_extent", + "frame_bound", "row", "sub_type", "all_Op", "MathOp", "qual_Op", + "qual_all_Op", "subquery_Op", "expr_list", "func_arg_list", + "func_arg_expr", "type_list", "array_expr", "array_expr_list", + "extract_list", "extract_arg", "overlay_list", "overlay_placing", + "position_list", "substr_list", "substr_from", "substr_for", "trim_list", + "in_expr", "case_expr", "when_clause_list", "when_clause", + "case_default", "case_arg", "columnref", "indirection_el", "indirection", + "opt_indirection", "opt_asymmetric", "ctext_expr", "ctext_expr_list", + "ctext_row", "target_list", "target_el", "qualified_name_list", + "qualified_name", "name_list", "name", "database_name", "access_method", + "attr_name", "index_name", "file_name", "func_name", "AexprConst", + "Iconst", "RoleId", "SignedIconst", "unreserved_keyword", + "col_name_keyword", "type_func_name_keyword", "reserved_keyword", + "statements", "statement", "CreateAsStmt", "$@1", "at", "ECPGConnect", + "connection_target", "opt_database_name", "db_prefix", "server", + "opt_server", "server_name", "opt_port", "opt_connection_name", + "opt_user", "ora_user", "user_name", "char_variable", "opt_options", + "connect_options", "opt_opt_value", "prepared_name", "ECPGCursorStmt", + "ECPGExecuteImmediateStmt", "ECPGVarDeclaration", + "single_vt_declaration", "precision", "opt_scale", "ecpg_interval", + "ECPGDeclaration", "$@2", "sql_startdeclare", "sql_enddeclare", + "var_type_declarations", "vt_declarations", "variable_declarations", + "type_declaration", "$@3", "var_declaration", "$@4", "$@5", + "opt_bit_field", "storage_declaration", "storage_clause", + "storage_modifier", "var_type", "enum_type", "enum_definition", + "struct_union_type_with_symbol", "$@6", "struct_union_type", "$@7", + "s_struct_union_symbol", "s_struct_union", "simple_type", + "unsigned_type", "signed_type", "opt_signed", "variable_list", + "variable", "opt_initializer", "opt_pointer", "ECPGDeclare", + "ECPGDisconnect", "dis_name", "connection_object", "execstring", + "ECPGFree", "ECPGOpen", "opt_ecpg_using", "ecpg_using", + "using_descriptor", "into_descriptor", "into_sqlda", "using_list", + "UsingValue", "UsingConst", "ECPGDescribe", "opt_output", + "ECPGAllocateDescr", "ECPGDeallocateDescr", "ECPGGetDescriptorHeader", + "ECPGGetDescHeaderItems", "ECPGGetDescHeaderItem", + "ECPGSetDescriptorHeader", "ECPGSetDescHeaderItems", + "ECPGSetDescHeaderItem", "IntConstVar", "desc_header_item", + "ECPGGetDescriptor", "ECPGGetDescItems", "ECPGGetDescItem", + "ECPGSetDescriptor", "ECPGSetDescItems", "ECPGSetDescItem", + "AllConstVar", "descriptor_item", "ECPGSetAutocommit", "on_off", + "ECPGSetConnection", "ECPGTypedef", "$@8", "opt_reference", "ECPGVar", + "$@9", "ECPGWhenever", "action", "ECPGKeywords", "ECPGKeywords_vanames", + "ECPGKeywords_rest", "ECPGTypeName", "symbol", "ECPGColId", "ColId", + "type_function_name", "ColLabel", "ECPGColLabel", "ECPGColLabelCommon", + "ECPGCKeywords", "all_unreserved_keyword", "ECPGunreserved_interval", + "into_list", "ecpgstart", "c_args", "coutputvariable", "civarind", + "char_civar", "civar", "indicator", "cvariable", "ecpg_param", + "ecpg_bconst", "ecpg_fconst", "ecpg_sconst", "ecpg_xconst", "ecpg_ident", + "quoted_ident_stringvar", "c_stuff_item", "c_stuff", "c_list", "c_term", + "c_thing", "c_anything", "DeallocateStmt", "Iresult", "execute_rest", + "ecpg_into", "ecpg_fetch_into", "opt_ecpg_fetch_into", 0 +}; +#endif + +# ifdef YYPRINT +/* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to + token YYLEX-NUM. */ +static const yytype_uint16 yytoknum[] = +{ + 0, 256, 257, 258, 259, 260, 261, 262, 263, 264, + 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, + 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, + 285, 286, 287, 288, 289, 290, 291, 292, 293, 294, + 295, 296, 297, 298, 299, 300, 301, 302, 303, 304, + 305, 306, 307, 308, 309, 310, 311, 312, 313, 314, + 315, 316, 317, 318, 319, 320, 321, 322, 323, 324, + 325, 326, 327, 328, 329, 330, 331, 332, 333, 334, + 335, 336, 337, 338, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 351, 352, 353, 354, + 355, 356, 357, 358, 359, 360, 361, 362, 363, 364, + 365, 366, 367, 368, 369, 370, 371, 372, 373, 374, + 375, 376, 377, 378, 379, 380, 381, 382, 383, 384, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, + 415, 416, 417, 418, 419, 420, 421, 422, 423, 424, + 425, 426, 427, 428, 429, 430, 431, 432, 433, 434, + 435, 436, 437, 438, 439, 440, 441, 442, 443, 444, + 445, 446, 447, 448, 449, 450, 451, 452, 453, 454, + 455, 456, 457, 458, 459, 460, 461, 462, 463, 464, + 465, 466, 467, 468, 469, 470, 471, 472, 473, 474, + 475, 476, 477, 478, 479, 480, 481, 482, 483, 484, + 485, 486, 487, 488, 489, 490, 491, 492, 493, 494, + 495, 496, 497, 498, 499, 500, 501, 502, 503, 504, + 505, 506, 507, 508, 509, 510, 511, 512, 513, 514, + 515, 516, 517, 518, 519, 520, 521, 522, 523, 524, + 525, 526, 527, 528, 529, 530, 531, 532, 533, 534, + 535, 536, 537, 538, 539, 540, 541, 542, 543, 544, + 545, 546, 547, 548, 549, 550, 551, 552, 553, 554, + 555, 556, 557, 558, 559, 560, 561, 562, 563, 564, + 565, 566, 567, 568, 569, 570, 571, 572, 573, 574, + 575, 576, 577, 578, 579, 580, 581, 582, 583, 584, + 585, 586, 587, 588, 589, 590, 591, 592, 593, 594, + 595, 596, 597, 598, 599, 600, 601, 602, 603, 604, + 605, 606, 607, 608, 609, 610, 611, 612, 613, 614, + 615, 616, 617, 618, 619, 620, 621, 622, 623, 624, + 625, 626, 627, 628, 629, 630, 631, 632, 633, 634, + 635, 636, 637, 638, 639, 640, 641, 642, 643, 644, + 645, 646, 647, 648, 649, 650, 651, 652, 653, 654, + 655, 656, 657, 658, 659, 660, 661, 662, 663, 664, + 665, 666, 667, 668, 669, 670, 671, 672, 673, 674, + 675, 676, 677, 678, 679, 680, 681, 682, 683, 684, + 685, 686, 687, 688, 689, 690, 691, 692, 693, 694, + 695, 696, 697, 698, 699, 700, 701, 702, 703, 704, + 705, 706, 707, 708, 709, 710, 711, 712, 713, 714, + 715, 716, 717, 718, 719, 720, 721, 722, 723, 724, + 725, 726, 727, 728, 729, 730, 731, 732, 733, 734, + 735, 736, 737, 738, 739, 740, 741, 742, 743, 744, + 61, 60, 62, 745, 43, 45, 42, 47, 37, 94, + 746, 91, 93, 40, 41, 46, 44, 59, 58, 123, + 125 +}; +# endif + +/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ +static const yytype_uint16 yyr1[] = +{ + 0, 511, 512, 513, 513, 513, 513, 513, 513, 513, + 513, 513, 513, 513, 513, 513, 513, 513, 513, 513, + 513, 513, 513, 513, 513, 513, 513, 513, 513, 513, + 513, 513, 513, 513, 513, 513, 513, 513, 513, 513, + 513, 513, 513, 513, 513, 513, 513, 513, 513, 513, + 513, 513, 513, 513, 513, 513, 513, 513, 513, 513, + 513, 513, 513, 513, 513, 513, 513, 513, 513, 513, + 513, 513, 513, 513, 513, 513, 513, 513, 513, 513, + 513, 513, 513, 513, 513, 513, 513, 513, 513, 513, + 513, 513, 513, 513, 513, 513, 513, 513, 513, 513, + 513, 513, 513, 513, 513, 513, 513, 513, 513, 513, + 513, 513, 513, 513, 513, 513, 513, 513, 513, 513, + 513, 513, 513, 513, 513, 513, 513, 513, 513, 513, + 513, 513, 513, 514, 515, 515, 516, 516, 517, 517, + 518, 518, 518, 518, 518, 518, 518, 518, 518, 519, + 519, 519, 519, 519, 519, 520, 521, 522, 522, 523, + 524, 525, 526, 526, 527, 527, 528, 529, 530, 530, + 531, 531, 532, 532, 533, 533, 534, 534, 535, 535, + 535, 535, 535, 535, 536, 536, 536, 537, 537, 537, + 538, 538, 538, 538, 538, 538, 538, 538, 538, 538, + 538, 538, 538, 538, 539, 539, 540, 540, 541, 541, + 542, 542, 542, 542, 543, 543, 543, 543, 544, 544, + 544, 544, 544, 544, 544, 545, 545, 545, 546, 546, + 547, 547, 547, 547, 547, 548, 548, 549, 549, 550, + 550, 550, 550, 550, 551, 552, 552, 553, 553, 554, + 555, 555, 555, 555, 556, 556, 556, 556, 556, 556, + 556, 556, 557, 557, 558, 558, 558, 558, 558, 558, + 558, 558, 558, 558, 558, 558, 558, 558, 558, 558, + 558, 558, 558, 558, 558, 558, 558, 558, 558, 558, + 558, 558, 558, 558, 558, 558, 558, 558, 558, 558, + 558, 558, 558, 558, 558, 558, 559, 559, 560, 560, + 560, 561, 561, 562, 562, 563, 564, 564, 565, 565, + 566, 566, 566, 566, 567, 568, 568, 569, 569, 569, + 569, 570, 570, 571, 571, 572, 572, 573, 573, 573, + 574, 574, 575, 575, 576, 576, 576, 576, 576, 576, + 576, 576, 576, 576, 576, 576, 577, 577, 578, 578, + 579, 579, 580, 580, 581, 581, 582, 583, 583, 583, + 583, 583, 584, 584, 585, 586, 586, 586, 586, 587, + 587, 587, 587, 587, 587, 587, 587, 588, 588, 589, + 589, 590, 590, 591, 591, 592, 592, 592, 593, 593, + 594, 595, 596, 596, 597, 597, 597, 597, 598, 598, + 598, 598, 598, 598, 598, 599, 599, 599, 599, 600, + 601, 601, 601, 602, 602, 602, 602, 602, 602, 603, + 603, 604, 604, 604, 604, 604, 604, 604, 605, 605, + 606, 606, 607, 607, 608, 609, 609, 609, 609, 610, + 610, 611, 611, 612, 612, 613, 613, 613, 613, 613, + 614, 615, 616, 616, 616, 616, 616, 617, 617, 618, + 618, 618, 618, 619, 619, 619, 619, 620, 620, 621, + 621, 622, 623, 624, 624, 624, 625, 626, 626, 627, + 627, 628, 628, 629, 629, 629, 629, 629, 629, 629, + 629, 629, 629, 629, 629, 630, 630, 631, 631, 631, + 632, 632, 633, 633, 634, 634, 635, 635, 636, 636, + 637, 637, 638, 638, 639, 639, 640, 640, 641, 642, + 642, 643, 643, 644, 644, 645, 645, 646, 646, 646, + 647, 648, 648, 649, 650, 650, 650, 650, 650, 650, + 650, 650, 650, 650, 650, 650, 650, 650, 650, 650, + 650, 650, 650, 650, 650, 650, 651, 652, 652, 652, + 652, 653, 653, 654, 654, 655, 655, 656, 656, 657, + 657, 658, 658, 659, 660, 660, 661, 661, 661, 661, + 662, 663, 664, 665, 666, 666, 667, 667, 668, 668, + 669, 669, 670, 670, 670, 671, 671, 672, 672, 673, + 673, 674, 675, 675, 676, 677, 677, 677, 678, 678, + 679, 680, 680, 681, 681, 681, 682, 682, 683, 683, + 683, 683, 683, 684, 684, 685, 685, 686, 686, 687, + 687, 688, 688, 688, 689, 689, 689, 689, 690, 690, + 691, 691, 692, 692, 692, 692, 692, 692, 693, 693, + 694, 695, 696, 696, 696, 696, 696, 696, 696, 696, + 696, 696, 696, 696, 696, 696, 697, 698, 698, 699, + 699, 700, 700, 700, 700, 700, 701, 701, 702, 703, + 703, 704, 705, 705, 706, 706, 707, 707, 707, 708, + 709, 709, 710, 710, 710, 710, 710, 711, 711, 712, + 712, 713, 713, 713, 714, 714, 715, 716, 716, 717, + 717, 718, 718, 719, 719, 720, 720, 721, 722, 723, + 723, 723, 723, 724, 724, 724, 724, 724, 724, 724, + 724, 724, 724, 724, 724, 724, 724, 724, 725, 725, + 726, 726, 727, 727, 728, 729, 729, 729, 730, 730, + 730, 730, 730, 730, 730, 730, 730, 730, 730, 730, + 730, 730, 730, 730, 730, 731, 731, 731, 731, 731, + 731, 731, 731, 731, 731, 731, 731, 731, 731, 731, + 731, 731, 732, 732, 733, 733, 733, 733, 733, 734, + 734, 735, 735, 735, 735, 735, 735, 735, 735, 735, + 735, 735, 736, 736, 737, 737, 737, 737, 737, 737, + 737, 737, 737, 737, 737, 738, 738, 738, 738, 738, + 738, 738, 738, 738, 738, 738, 738, 738, 738, 739, + 739, 740, 740, 741, 742, 742, 743, 743, 743, 743, + 743, 744, 744, 745, 745, 745, 745, 746, 746, 746, + 746, 746, 746, 746, 746, 746, 746, 746, 746, 746, + 746, 746, 746, 747, 747, 748, 748, 749, 749, 750, + 750, 751, 752, 753, 753, 754, 754, 755, 755, 756, + 757, 757, 758, 758, 758, 759, 759, 759, 760, 760, + 760, 760, 761, 762, 762, 763, 763, 764, 764, 765, + 765, 766, 766, 767, 767, 767, 768, 768, 769, 769, + 769, 770, 770, 770, 771, 771, 771, 772, 772, 772, + 773, 773, 774, 774, 775, 775, 776, 776, 777, 777, + 778, 778, 778, 778, 778, 779, 779, 779, 779, 779, + 780, 781, 782, 782, 782, 783, 783, 783, 784, 784, + 785, 785, 785, 785, 785, 785, 785, 785, 785, 785, + 785, 785, 785, 785, 785, 786, 786, 786, 786, 787, + 787, 788, 788, 789, 790, 790, 791, 792, 792, 793, + 793, 794, 794, 795, 795, 796, 796, 797, 797, 797, + 797, 798, 798, 799, 800, 800, 801, 801, 802, 802, + 802, 803, 803, 803, 804, 805, 805, 806, 806, 806, + 807, 807, 808, 808, 809, 809, 809, 809, 809, 809, + 809, 809, 809, 809, 809, 809, 809, 809, 809, 809, + 809, 809, 809, 809, 809, 809, 809, 809, 809, 809, + 809, 809, 809, 809, 809, 809, 809, 809, 809, 809, + 809, 809, 809, 809, 809, 810, 810, 811, 811, 812, + 812, 812, 812, 812, 812, 812, 812, 812, 812, 812, + 812, 812, 812, 812, 812, 812, 812, 812, 812, 812, + 812, 813, 813, 813, 813, 813, 813, 813, 813, 813, + 813, 813, 813, 813, 813, 813, 813, 813, 813, 814, + 815, 815, 815, 816, 816, 817, 817, 817, 817, 817, + 818, 818, 819, 819, 819, 819, 820, 820, 820, 821, + 821, 822, 823, 823, 824, 825, 825, 826, 826, 826, + 826, 826, 826, 826, 826, 826, 826, 826, 826, 826, + 826, 827, 827, 827, 828, 828, 828, 828, 828, 829, + 829, 829, 830, 830, 831, 831, 832, 832, 832, 832, + 833, 834, 835, 835, 836, 836, 836, 836, 836, 836, + 836, 836, 836, 836, 836, 836, 836, 836, 836, 836, + 837, 837, 838, 838, 839, 840, 840, 841, 842, 842, + 843, 844, 844, 844, 844, 844, 844, 844, 845, 845, + 846, 847, 847, 847, 847, 847, 847, 848, 849, 849, + 849, 850, 850, 851, 851, 851, 851, 851, 852, 852, + 853, 853, 853, 853, 854, 854, 855, 855, 856, 856, + 857, 857, 858, 858, 859, 859, 860, 860, 860, 860, + 861, 861, 861, 861, 861, 861, 861, 862, 862, 863, + 864, 864, 864, 865, 865, 865, 866, 866, 867, 867, + 868, 868, 868, 868, 869, 869, 870, 870, 871, 872, + 872, 872, 873, 873, 874, 875, 875, 876, 877, 877, + 878, 879, 879, 880, 880, 880, 880, 880, 880, 880, + 880, 881, 881, 882, 883, 883, 884, 884, 885, 886, + 887, 888, 888, 889, 890, 890, 891, 891, 891, 891, + 891, 892, 892, 892, 893, 893, 894, 894, 895, 895, + 895, 895, 895, 895, 895, 895, 896, 896, 897, 897, + 897, 897, 897, 897, 898, 898, 899, 899, 900, 901, + 901, 902, 902, 902, 903, 903, 903, 903, 903, 903, + 903, 903, 903, 904, 904, 905, 905, 905, 906, 906, + 906, 906, 907, 907, 908, 909, 909, 910, 910, 911, + 911, 911, 911, 912, 912, 913, 913, 913, 914, 914, + 915, 915, 916, 917, 917, 917, 918, 919, 919, 920, + 920, 921, 921, 922, 922, 923, 923, 924, 924, 925, + 925, 926, 926, 927, 927, 928, 928, 929, 929, 930, + 930, 931, 931, 931, 931, 931, 931, 931, 931, 931, + 931, 931, 932, 932, 932, 932, 932, 932, 933, 933, + 933, 933, 934, 934, 934, 934, 935, 935, 936, 936, + 937, 937, 937, 937, 938, 938, 939, 939, 939, 940, + 941, 941, 942, 942, 942, 943, 943, 944, 944, 945, + 946, 946, 946, 946, 946, 946, 947, 947, 947, 948, + 948, 948, 948, 948, 948, 948, 949, 949, 949, 949, + 950, 950, 951, 951, 952, 952, 952, 952, 952, 952, + 952, 952, 952, 952, 952, 953, 953, 954, 954, 955, + 955, 956, 957, 958, 958, 959, 959, 960, 961, 962, + 962, 962, 962, 962, 962, 963, 963, 964, 964, 965, + 965, 965, 965, 966, 967, 967, 967, 968, 968, 968, + 968, 968, 968, 968, 968, 968, 968, 968, 968, 968, + 968, 969, 969, 970, 970, 970, 970, 970, 970, 970, + 970, 970, 970, 970, 970, 970, 970, 970, 970, 970, + 970, 970, 970, 970, 970, 970, 970, 970, 970, 970, + 970, 970, 970, 970, 970, 970, 970, 970, 970, 970, + 970, 970, 970, 970, 970, 970, 970, 970, 970, 970, + 970, 970, 970, 970, 970, 970, 970, 970, 970, 970, + 970, 970, 971, 971, 971, 971, 971, 971, 971, 971, + 971, 971, 971, 971, 971, 971, 971, 971, 971, 971, + 971, 971, 971, 971, 972, 972, 972, 972, 972, 972, + 972, 972, 972, 972, 972, 973, 973, 973, 973, 973, + 973, 973, 973, 973, 973, 973, 973, 973, 973, 973, + 973, 973, 973, 973, 973, 973, 973, 973, 973, 973, + 973, 973, 973, 973, 973, 973, 973, 973, 973, 973, + 973, 973, 973, 973, 973, 973, 973, 973, 973, 973, + 973, 973, 973, 973, 973, 974, 974, 975, 975, 975, + 975, 976, 977, 977, 978, 978, 979, 979, 980, 980, + 980, 981, 981, 981, 981, 982, 982, 983, 983, 984, + 985, 985, 985, 986, 987, 987, 988, 988, 989, 989, + 989, 990, 990, 991, 991, 991, 991, 991, 992, 992, + 992, 993, 993, 993, 994, 994, 995, 995, 995, 995, + 995, 995, 995, 995, 995, 996, 996, 997, 997, 998, + 998, 998, 998, 998, 998, 999, 999, 1000, 1000, 1001, + 1001, 1002, 1002, 1003, 1003, 1003, 1004, 1004, 1005, 1005, + 1006, 1006, 1006, 1006, 1006, 1006, 1006, 1006, 1007, 1007, + 1008, 1009, 1009, 1010, 1010, 1010, 1010, 1010, 1010, 1011, + 1012, 1013, 1013, 1013, 1014, 1014, 1015, 1016, 1016, 1017, + 1018, 1018, 1019, 1019, 1020, 1020, 1021, 1021, 1021, 1021, + 1022, 1022, 1023, 1023, 1024, 1024, 1025, 1025, 1026, 1026, + 1027, 1028, 1028, 1029, 1029, 1029, 1029, 1030, 1030, 1031, + 1031, 1032, 1032, 1033, 1034, 1035, 1036, 1037, 1038, 1039, + 1039, 1040, 1040, 1040, 1040, 1040, 1040, 1040, 1040, 1040, + 1040, 1040, 1040, 1040, 1040, 1040, 1041, 1042, 1043, 1043, + 1043, 1043, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, + 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, + 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, + 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, + 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, + 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, + 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, + 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, + 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, + 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, + 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, + 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, + 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, + 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, + 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, + 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, + 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, + 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, + 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, + 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, + 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, + 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, + 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, + 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, 1044, + 1044, 1044, 1044, 1045, 1045, 1045, 1045, 1045, 1045, 1045, + 1045, 1045, 1045, 1045, 1045, 1045, 1045, 1045, 1045, 1045, + 1045, 1045, 1045, 1045, 1045, 1045, 1045, 1045, 1045, 1045, + 1045, 1045, 1045, 1045, 1045, 1045, 1045, 1045, 1045, 1045, + 1045, 1045, 1045, 1045, 1045, 1045, 1045, 1046, 1046, 1046, + 1046, 1046, 1046, 1046, 1046, 1046, 1046, 1046, 1046, 1046, + 1046, 1046, 1046, 1046, 1046, 1046, 1046, 1046, 1046, 1046, + 1047, 1047, 1047, 1047, 1047, 1047, 1047, 1047, 1047, 1047, + 1047, 1047, 1047, 1047, 1047, 1047, 1047, 1047, 1047, 1047, + 1047, 1047, 1047, 1047, 1047, 1047, 1047, 1047, 1047, 1047, + 1047, 1047, 1047, 1047, 1047, 1047, 1047, 1047, 1047, 1047, + 1047, 1047, 1047, 1047, 1047, 1047, 1047, 1047, 1047, 1047, + 1047, 1047, 1047, 1047, 1047, 1047, 1047, 1047, 1047, 1047, + 1047, 1047, 1047, 1047, 1047, 1047, 1047, 1047, 1047, 1047, + 1047, 1047, 1047, 1047, 1048, 1048, 1049, 1049, 1049, 1049, + 1049, 1049, 1049, 1049, 1051, 1050, 1052, 1053, 1053, 1053, + 1053, 1054, 1054, 1054, 1054, 1055, 1055, 1056, 1057, 1058, + 1058, 1059, 1059, 1059, 1060, 1060, 1061, 1061, 1062, 1062, + 1063, 1063, 1063, 1063, 1064, 1064, 1064, 1065, 1066, 1066, + 1067, 1067, 1068, 1068, 1068, 1068, 1069, 1069, 1070, 1071, + 1072, 1073, 1073, 1074, 1075, 1075, 1076, 1076, 1076, 1076, + 1076, 1078, 1077, 1079, 1080, 1081, 1081, 1082, 1082, 1082, + 1082, 1083, 1083, 1085, 1084, 1087, 1086, 1088, 1086, 1086, + 1089, 1089, 1090, 1090, 1090, 1091, 1091, 1091, 1091, 1092, + 1092, 1093, 1093, 1093, 1093, 1093, 1093, 1094, 1094, 1094, + 1095, 1097, 1096, 1098, 1099, 1098, 1100, 1100, 1101, 1101, + 1102, 1102, 1103, 1103, 1103, 1103, 1103, 1103, 1103, 1103, + 1103, 1104, 1104, 1104, 1104, 1104, 1104, 1104, 1104, 1104, + 1104, 1105, 1105, 1106, 1106, 1107, 1108, 1108, 1109, 1109, + 1109, 1110, 1111, 1112, 1112, 1112, 1112, 1113, 1113, 1113, + 1114, 1114, 1115, 1115, 1116, 1117, 1117, 1118, 1118, 1119, + 1119, 1120, 1120, 1121, 1122, 1122, 1123, 1123, 1123, 1124, + 1124, 1124, 1124, 1124, 1124, 1124, 1124, 1124, 1125, 1125, + 1125, 1125, 1125, 1126, 1126, 1127, 1128, 1129, 1130, 1130, + 1131, 1132, 1133, 1133, 1134, 1135, 1135, 1136, 1137, 1138, + 1138, 1139, 1140, 1141, 1141, 1142, 1143, 1143, 1143, 1143, + 1143, 1144, 1144, 1144, 1144, 1144, 1144, 1144, 1144, 1144, + 1144, 1144, 1144, 1144, 1144, 1144, 1145, 1145, 1146, 1146, + 1147, 1147, 1147, 1149, 1148, 1150, 1150, 1152, 1151, 1153, + 1153, 1153, 1154, 1154, 1154, 1154, 1154, 1154, 1154, 1154, + 1154, 1155, 1155, 1156, 1156, 1156, 1156, 1156, 1156, 1156, + 1156, 1156, 1156, 1156, 1156, 1156, 1156, 1156, 1156, 1156, + 1156, 1156, 1156, 1156, 1156, 1156, 1156, 1157, 1157, 1157, + 1157, 1157, 1157, 1158, 1158, 1158, 1158, 1158, 1158, 1158, + 1159, 1160, 1160, 1160, 1160, 1160, 1160, 1160, 1160, 1161, + 1161, 1161, 1161, 1161, 1161, 1161, 1162, 1162, 1162, 1162, + 1162, 1162, 1163, 1163, 1163, 1163, 1163, 1163, 1163, 1163, + 1163, 1163, 1163, 1164, 1164, 1164, 1164, 1164, 1165, 1165, + 1165, 1165, 1166, 1166, 1166, 1166, 1166, 1166, 1166, 1167, + 1167, 1167, 1168, 1168, 1168, 1168, 1168, 1168, 1169, 1169, + 1170, 1171, 1171, 1172, 1172, 1173, 1174, 1175, 1176, 1176, + 1176, 1177, 1178, 1179, 1180, 1181, 1181, 1181, 1181, 1181, + 1182, 1183, 1183, 1183, 1184, 1184, 1185, 1185, 1185, 1186, + 1186, 1187, 1187, 1188, 1188, 1189, 1189, 1189, 1189, 1189, + 1190, 1190, 1190, 1190, 1190, 1190, 1190, 1190, 1190, 1190, + 1190, 1190, 1190, 1190, 1190, 1190, 1190, 1190, 1190, 1190, + 1190, 1190, 1190, 1190, 1190, 1190, 1190, 1190, 1190, 1190, + 1190, 1190, 1190, 1190, 1190, 1190, 1190, 1190, 1190, 1190, + 1190, 1190, 1190, 1190, 1190, 1190, 1190, 1190, 1190, 1190, + 1190, 1190, 1190, 1190, 1190, 1190, 1191, 1191, 1191, 1191, + 1192, 1192, 1192, 1192, 1192, 1192, 1192, 1192, 1192, 1193, + 1193, 1193, 1193, 1193, 1194, 1194, 1195, 1195, 1196, 1196 +}; + +/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */ +static const yytype_uint8 yyr2[] = +{ + 0, 2, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 0, 5, 1, 0, 2, 0, 2, 0, + 2, 2, 3, 3, 1, 3, 3, 2, 1, 1, + 2, 2, 2, 3, 3, 5, 5, 0, 3, 5, + 5, 4, 3, 5, 3, 5, 5, 6, 1, 1, + 3, 5, 6, 4, 1, 0, 2, 0, 1, 1, + 1, 1, 1, 1, 2, 3, 3, 2, 5, 1, + 3, 3, 3, 3, 3, 3, 2, 2, 2, 2, + 3, 3, 3, 3, 1, 3, 1, 3, 1, 1, + 2, 2, 2, 1, 1, 1, 1, 1, 1, 1, + 3, 6, 1, 1, 1, 1, 1, 0, 1, 1, + 2, 3, 4, 3, 2, 2, 1, 2, 1, 3, + 4, 5, 4, 2, 4, 1, 1, 1, 1, 1, + 2, 2, 2, 2, 4, 6, 4, 6, 4, 6, + 4, 6, 1, 3, 2, 3, 4, 6, 6, 6, + 5, 5, 6, 6, 4, 8, 4, 2, 3, 6, + 4, 3, 3, 3, 3, 3, 4, 4, 3, 3, + 3, 3, 3, 3, 4, 4, 3, 2, 3, 2, + 2, 3, 3, 2, 2, 1, 3, 2, 1, 1, + 0, 2, 0, 2, 0, 3, 2, 0, 1, 3, + 3, 1, 5, 3, 4, 1, 3, 4, 6, 4, + 8, 2, 2, 10, 6, 1, 1, 1, 1, 1, + 1, 3, 2, 0, 1, 1, 3, 3, 1, 1, + 3, 3, 3, 3, 4, 2, 1, 0, 2, 0, + 3, 0, 1, 0, 1, 3, 2, 1, 1, 1, + 3, 0, 1, 3, 1, 11, 14, 10, 13, 1, + 1, 2, 2, 2, 2, 1, 0, 1, 0, 3, + 0, 1, 3, 1, 3, 1, 1, 1, 1, 1, + 4, 4, 2, 0, 3, 1, 1, 2, 2, 1, + 3, 4, 5, 2, 5, 1, 2, 2, 2, 3, + 3, 3, 0, 1, 1, 1, 1, 1, 1, 3, + 1, 5, 7, 3, 8, 4, 9, 11, 2, 0, + 3, 0, 1, 3, 1, 2, 2, 2, 0, 1, + 3, 3, 6, 4, 0, 1, 1, 2, 2, 0, + 3, 3, 2, 1, 1, 2, 2, 4, 0, 2, + 2, 2, 0, 3, 4, 4, 0, 2, 0, 4, + 0, 3, 5, 2, 3, 0, 5, 4, 6, 1, + 0, 1, 2, 2, 1, 2, 3, 2, 2, 2, + 2, 3, 3, 1, 3, 1, 0, 1, 2, 1, + 1, 3, 6, 10, 1, 0, 1, 2, 2, 0, + 2, 2, 1, 0, 5, 7, 1, 0, 6, 2, + 0, 3, 5, 5, 8, 2, 0, 2, 2, 2, + 5, 2, 0, 2, 7, 10, 6, 6, 6, 6, + 7, 7, 9, 9, 6, 6, 8, 8, 8, 8, + 6, 6, 7, 8, 6, 6, 7, 2, 2, 2, + 2, 1, 2, 1, 0, 6, 8, 7, 6, 4, + 0, 1, 3, 4, 1, 3, 1, 2, 2, 2, + 2, 1, 1, 10, 2, 0, 2, 2, 1, 0, + 4, 6, 5, 4, 4, 8, 11, 3, 2, 1, + 3, 1, 5, 7, 8, 1, 1, 1, 7, 9, + 8, 15, 20, 1, 1, 2, 1, 3, 1, 1, + 1, 3, 1, 3, 0, 1, 0, 1, 1, 4, + 0, 1, 3, 0, 1, 1, 1, 1, 2, 0, + 0, 2, 2, 1, 2, 2, 2, 2, 6, 8, + 8, 4, 5, 4, 4, 4, 3, 7, 8, 6, + 6, 6, 6, 6, 4, 5, 3, 1, 3, 3, + 1, 1, 1, 1, 1, 1, 3, 3, 3, 1, + 3, 3, 1, 0, 1, 3, 6, 8, 8, 13, + 1, 3, 5, 6, 4, 7, 2, 1, 0, 2, + 0, 2, 4, 0, 1, 0, 6, 8, 8, 1, + 3, 5, 5, 7, 9, 7, 9, 5, 6, 6, + 4, 5, 7, 1, 1, 1, 1, 2, 1, 1, + 1, 1, 1, 1, 3, 3, 3, 3, 1, 3, + 1, 2, 2, 3, 5, 2, 2, 0, 6, 7, + 7, 7, 8, 8, 6, 8, 9, 9, 7, 10, + 7, 8, 8, 8, 8, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, + 1, 3, 1, 1, 8, 9, 9, 9, 9, 2, + 0, 1, 1, 2, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 2, 2, 3, 4, 5, 4, + 5, 3, 4, 3, 4, 1, 2, 3, 3, 3, + 3, 4, 4, 3, 3, 4, 4, 4, 4, 1, + 1, 1, 0, 7, 7, 10, 1, 1, 2, 4, + 5, 1, 3, 2, 2, 2, 2, 1, 2, 2, + 4, 3, 2, 2, 2, 2, 3, 2, 2, 2, + 5, 5, 5, 1, 3, 1, 2, 3, 0, 1, + 3, 2, 6, 6, 9, 3, 0, 3, 0, 5, + 2, 0, 3, 3, 3, 7, 7, 10, 1, 1, + 1, 1, 14, 1, 0, 1, 0, 1, 0, 2, + 0, 1, 3, 5, 5, 7, 2, 0, 1, 2, + 0, 1, 1, 0, 1, 1, 0, 9, 12, 7, + 2, 0, 3, 2, 1, 3, 3, 2, 1, 3, + 3, 3, 2, 2, 1, 1, 1, 1, 2, 1, + 1, 1, 1, 4, 5, 1, 3, 3, 1, 2, + 4, 5, 1, 1, 1, 1, 3, 3, 2, 2, + 1, 2, 2, 2, 1, 2, 2, 1, 1, 1, + 3, 2, 0, 2, 1, 3, 5, 1, 2, 1, + 0, 5, 7, 5, 7, 5, 7, 3, 5, 5, + 5, 1, 3, 2, 1, 2, 1, 2, 11, 10, + 10, 2, 2, 0, 9, 2, 0, 4, 4, 4, + 1, 1, 1, 0, 7, 6, 6, 6, 6, 8, + 8, 6, 6, 7, 9, 9, 6, 6, 6, 8, + 6, 8, 6, 8, 6, 8, 7, 9, 8, 10, + 8, 9, 11, 8, 6, 6, 6, 5, 5, 8, + 8, 8, 8, 6, 9, 1, 0, 2, 0, 7, + 6, 6, 6, 6, 6, 7, 9, 9, 6, 8, + 8, 8, 8, 8, 6, 8, 6, 8, 7, 9, + 6, 7, 6, 6, 6, 6, 6, 7, 7, 7, + 9, 9, 6, 6, 6, 8, 8, 8, 6, 13, + 1, 1, 3, 3, 1, 1, 1, 1, 1, 1, + 1, 0, 1, 1, 1, 1, 1, 1, 0, 6, + 8, 3, 2, 0, 2, 2, 2, 2, 3, 3, + 2, 2, 2, 2, 3, 2, 5, 4, 3, 3, + 3, 1, 1, 0, 3, 2, 2, 1, 2, 1, + 3, 2, 1, 0, 9, 11, 3, 4, 4, 0, + 2, 5, 2, 0, 3, 3, 3, 3, 3, 3, + 3, 3, 3, 3, 3, 3, 3, 4, 3, 3, + 1, 0, 5, 6, 4, 2, 0, 4, 3, 5, + 6, 4, 6, 6, 5, 7, 9, 6, 1, 0, + 6, 11, 11, 11, 13, 9, 11, 10, 4, 2, + 5, 2, 0, 4, 5, 5, 4, 6, 1, 3, + 1, 1, 1, 1, 2, 4, 1, 1, 1, 0, + 1, 0, 1, 0, 3, 0, 2, 4, 3, 5, + 1, 1, 1, 1, 1, 1, 1, 1, 3, 2, + 1, 1, 1, 1, 1, 0, 5, 4, 3, 0, + 1, 1, 1, 1, 4, 9, 3, 0, 6, 1, + 4, 2, 1, 3, 2, 3, 0, 7, 2, 0, + 5, 3, 0, 2, 2, 2, 3, 1, 3, 1, + 2, 1, 0, 8, 1, 3, 1, 1, 3, 5, + 2, 1, 3, 7, 1, 1, 0, 3, 2, 2, + 2, 0, 2, 2, 1, 1, 3, 3, 1, 2, + 4, 4, 2, 3, 5, 5, 1, 1, 9, 1, + 2, 4, 4, 4, 2, 3, 1, 3, 6, 1, + 0, 2, 1, 0, 3, 3, 4, 4, 4, 4, + 3, 2, 1, 1, 0, 1, 1, 0, 1, 5, + 1, 0, 1, 0, 3, 1, 3, 4, 3, 2, + 2, 1, 1, 1, 0, 2, 4, 5, 2, 3, + 1, 1, 1, 1, 3, 0, 1, 1, 1, 1, + 1, 3, 0, 2, 0, 1, 3, 1, 0, 1, + 2, 4, 4, 2, 0, 2, 3, 2, 0, 1, + 3, 1, 2, 1, 2, 5, 6, 5, 1, 2, + 1, 4, 3, 4, 5, 4, 5, 4, 5, 2, + 4, 1, 2, 2, 2, 1, 1, 0, 4, 2, + 1, 2, 2, 4, 1, 3, 1, 2, 3, 1, + 2, 0, 2, 4, 0, 1, 0, 1, 3, 3, + 2, 3, 5, 6, 2, 3, 3, 4, 0, 1, + 1, 1, 1, 1, 2, 5, 1, 1, 1, 1, + 2, 3, 3, 0, 1, 1, 1, 1, 1, 2, + 2, 2, 2, 2, 1, 3, 0, 1, 1, 1, + 1, 5, 2, 1, 1, 1, 1, 5, 2, 2, + 2, 1, 3, 3, 2, 1, 0, 3, 0, 5, + 2, 5, 2, 1, 2, 3, 0, 1, 1, 1, + 1, 1, 1, 3, 3, 3, 3, 3, 3, 3, + 0, 1, 4, 1, 3, 3, 5, 2, 2, 3, + 3, 3, 3, 3, 3, 3, 3, 3, 3, 2, + 2, 3, 3, 2, 3, 5, 4, 6, 3, 5, + 4, 6, 4, 6, 5, 7, 3, 2, 4, 2, + 3, 3, 4, 3, 4, 3, 4, 5, 6, 6, + 7, 6, 7, 6, 7, 3, 4, 4, 6, 2, + 3, 4, 1, 3, 2, 2, 3, 3, 3, 3, + 3, 3, 3, 3, 3, 3, 2, 2, 5, 6, + 6, 7, 3, 4, 1, 1, 2, 4, 1, 1, + 1, 2, 2, 2, 1, 4, 5, 6, 8, 6, + 7, 7, 5, 5, 1, 1, 4, 1, 4, 1, + 4, 1, 4, 1, 1, 1, 1, 1, 1, 6, + 4, 4, 4, 4, 6, 5, 5, 5, 4, 6, + 4, 4, 4, 4, 5, 7, 7, 9, 5, 4, + 6, 5, 7, 7, 7, 2, 3, 3, 3, 4, + 0, 4, 1, 3, 3, 1, 1, 1, 2, 2, + 0, 2, 4, 4, 6, 2, 0, 1, 3, 3, + 2, 2, 0, 6, 1, 0, 3, 0, 2, 2, + 0, 1, 4, 2, 2, 2, 2, 2, 4, 3, + 5, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 4, 1, 4, 1, + 4, 1, 2, 1, 2, 1, 3, 1, 3, 1, + 3, 1, 3, 3, 3, 2, 1, 3, 3, 0, + 1, 1, 1, 1, 1, 1, 1, 1, 4, 3, + 2, 3, 0, 3, 3, 2, 2, 1, 0, 2, + 2, 3, 2, 1, 1, 3, 5, 1, 2, 4, + 2, 0, 1, 0, 1, 2, 2, 2, 3, 5, + 1, 2, 0, 2, 1, 0, 1, 1, 1, 3, + 3, 1, 3, 3, 2, 1, 1, 1, 3, 1, + 2, 1, 3, 1, 1, 1, 1, 1, 1, 1, + 2, 1, 1, 1, 1, 1, 2, 5, 2, 3, + 6, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 2, 2, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 0, 2, 4, 3, 2, 1, + 1, 1, 1, 1, 0, 8, 2, 5, 3, 2, + 2, 3, 7, 1, 1, 1, 0, 2, 2, 1, + 0, 1, 3, 1, 2, 0, 2, 0, 2, 0, + 1, 3, 4, 3, 1, 1, 1, 1, 2, 0, + 2, 4, 0, 2, 2, 2, 1, 1, 7, 3, + 1, 1, 1, 1, 2, 0, 1, 3, 3, 3, + 3, 0, 4, 5, 5, 0, 1, 1, 1, 2, + 2, 1, 2, 0, 7, 0, 5, 0, 4, 2, + 2, 0, 2, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 5, 2, 1, 3, 2, 2, + 3, 0, 5, 1, 0, 5, 2, 2, 1, 1, + 1, 2, 2, 3, 1, 2, 2, 3, 3, 4, + 2, 1, 2, 1, 1, 2, 2, 3, 1, 1, + 1, 1, 0, 1, 3, 5, 0, 2, 0, 1, + 2, 3, 2, 1, 1, 1, 0, 1, 1, 1, + 1, 1, 2, 2, 3, 0, 1, 2, 1, 4, + 3, 4, 3, 2, 1, 3, 1, 1, 1, 1, + 2, 2, 1, 2, 2, 1, 1, 1, 4, 4, + 4, 4, 4, 1, 0, 3, 3, 4, 1, 3, + 3, 4, 1, 3, 3, 1, 1, 1, 6, 1, + 3, 3, 6, 1, 3, 3, 1, 1, 2, 2, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 4, 4, 1, 1, + 4, 4, 3, 0, 7, 1, 0, 0, 7, 3, + 4, 3, 1, 1, 1, 2, 3, 5, 2, 5, + 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 3, + 1, 0, 1, 2, 1, 2, 1, 1, 1, 2, + 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 2, 3, 1, + 2, 1, 3, 1, 3, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 2, 3, 2, 3, + 1, 3, 3, 3, 3, 3, 3, 1, 1, 0, + 2, 2, 1, 1, 2, 1, 1, 1, 0, 1 +}; + +/* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state + STATE-NUM when YYTABLE doesn't specify something else to do. Zero + means the default is an error. */ +static const yytype_uint16 yydefact[] = +{ + 2254, 0, 2, 1, 2684, 2688, 2692, 2693, 2610, 2694, + 2695, 2660, 2661, 2662, 2663, 2664, 2665, 2666, 2667, 2668, + 2669, 2670, 2671, 2673, 2672, 2674, 2675, 2676, 2677, 2678, + 2679, 2680, 2681, 2683, 2682, 2632, 2261, 2629, 2626, 2627, + 2628, 2633, 2631, 2624, 2625, 1866, 2697, 2685, 2698, 2686, + 2687, 2689, 2690, 2659, 2691, 2699, 2700, 2701, 2696, 2704, + 2655, 2656, 2654, 2657, 2658, 2702, 2703, 2646, 2647, 2648, + 2649, 2705, 2262, 2263, 2651, 2255, 2259, 2321, 2392, 2652, + 2653, 2650, 2260, 2645, 2392, 0, 2513, 2514, 2515, 0, + 2516, 2517, 2518, 2444, 2406, 2519, 0, 0, 2520, 2521, + 2522, 2523, 2524, 2525, 2526, 2527, 0, 2528, 2529, 2530, + 2531, 2391, 2532, 2533, 2534, 2535, 2536, 2368, 2374, 2497, + 0, 2348, 2349, 2345, 2347, 2346, 2350, 2333, 1153, 527, + 1237, 1236, 0, 2157, 1153, 2113, 2114, 2158, 2115, 2116, + 2117, 249, 0, 1239, 2118, 2159, 0, 1153, 2160, 357, + 931, 2161, 2162, 2276, 0, 2119, 2120, 0, 0, 0, + 527, 1153, 0, 0, 2121, 1350, 2122, 0, 2123, 2163, + 2164, 0, 2124, 2165, 2166, 2125, 2126, 2127, 2167, 2168, + 2169, 2128, 2170, 2171, 0, 0, 1364, 0, 2129, 2172, + 2130, 2131, 0, 2173, 2132, 2133, 2134, 2174, 2175, 2176, + 2135, 2136, 2137, 0, 2138, 0, 0, 0, 0, 0, + 2177, 1153, 2139, 0, 0, 1371, 0, 2140, 0, 2178, + 2141, 0, 2142, 0, 2143, 2144, 2145, 2146, 1364, 2493, + 2369, 0, 1241, 0, 2147, 2179, 0, 2148, 2149, 2150, + 2151, 2152, 2153, 2154, 2155, 2156, 0, 0, 54, 55, + 21, 20, 26, 25, 77, 78, 44, 14, 68, 49, + 110, 109, 111, 32, 28, 62, 18, 19, 29, 33, + 51, 50, 17, 48, 72, 52, 75, 39, 8, 9, + 40, 66, 10, 41, 67, 11, 42, 12, 56, 79, + 24, 53, 76, 35, 64, 60, 7, 45, 46, 47, + 69, 70, 71, 93, 74, 105, 31, 102, 83, 84, + 99, 85, 100, 5, 86, 43, 13, 96, 95, 97, + 63, 36, 65, 94, 98, 15, 16, 101, 73, 91, + 88, 106, 104, 112, 89, 57, 3, 4, 80, 38, + 6, 23, 22, 37, 30, 108, 27, 1239, 82, 92, + 81, 87, 61, 90, 107, 59, 103, 1337, 1324, 1373, + 1336, 1349, 0, 1339, 2589, 2590, 34, 1350, 114, 115, + 120, 2258, 2310, 2311, 2312, 2392, 2343, 2344, 2337, 2353, + 2363, 2352, 2356, 2364, 2351, 2370, 0, 117, 119, 121, + 124, 118, 113, 116, 123, 128, 122, 127, 125, 126, + 129, 130, 131, 2591, 1550, 2588, 58, 2328, 2327, 0, + 2392, 0, 2537, 2538, 2539, 2540, 2541, 2542, 2592, 2593, + 2594, 2595, 2596, 2598, 2597, 2621, 1872, 1873, 1874, 1875, + 1876, 1877, 1878, 1879, 1880, 1881, 1882, 1883, 1884, 1885, + 1886, 1887, 1888, 1889, 1890, 1891, 1892, 1893, 1894, 1895, + 1896, 2564, 1897, 1898, 1899, 1900, 1901, 1902, 1903, 1904, + 1905, 1906, 2601, 1907, 1908, 1909, 1910, 1911, 1912, 1913, + 1914, 1915, 1916, 1917, 2602, 1918, 1919, 1920, 1921, 1922, + 1923, 1924, 1925, 1926, 1927, 1928, 1929, 1930, 1931, 1932, + 1933, 1934, 1935, 1936, 1937, 1938, 1939, 1940, 1941, 1942, + 1943, 1944, 1945, 1946, 1947, 1948, 1949, 1950, 1951, 1952, + 1953, 1954, 1955, 1956, 1957, 2603, 1958, 1959, 1960, 1961, + 1962, 1963, 1964, 1965, 1966, 1967, 1968, 1969, 1970, 1971, + 1972, 1973, 1974, 1975, 1976, 1977, 1978, 1979, 1980, 1981, + 1982, 1983, 1984, 1985, 1986, 1987, 1988, 1989, 1990, 1991, + 2604, 1992, 1993, 2605, 1994, 1995, 1996, 1997, 1998, 1999, + 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, + 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2021, + 2019, 2020, 2022, 2023, 2024, 2025, 2026, 2027, 2028, 2029, + 2030, 2031, 2032, 2033, 2034, 2035, 2036, 2037, 2038, 2039, + 2040, 2041, 2042, 2043, 2044, 2045, 2046, 2047, 2048, 2049, + 2050, 2051, 2052, 2606, 2053, 2054, 2055, 2056, 2057, 2058, + 2059, 2060, 2061, 2062, 2063, 2064, 2065, 2066, 2067, 2068, + 2069, 2070, 2071, 2072, 2073, 2074, 2075, 2076, 2077, 2078, + 2079, 2080, 2081, 2276, 2082, 2083, 2084, 2085, 2086, 2087, + 2088, 2089, 2090, 2091, 2092, 2093, 2094, 2095, 2096, 2097, + 2098, 2099, 2100, 2565, 2101, 2102, 2103, 2104, 2105, 2106, + 2107, 2108, 2109, 2110, 2607, 2111, 2112, 2294, 2599, 2561, + 2269, 2290, 2562, 2511, 2512, 1867, 2563, 2560, 2600, 2296, + 2617, 2295, 2559, 2443, 0, 0, 2405, 2404, 2408, 2407, + 2409, 2402, 2403, 1844, 2297, 2413, 2412, 1314, 2616, 1843, + 1315, 0, 2415, 2543, 2544, 2545, 2546, 2548, 2547, 2549, + 2180, 2181, 2182, 2183, 2184, 2185, 2186, 2187, 2188, 2189, + 2190, 2191, 2574, 2192, 2193, 2194, 2587, 2195, 2196, 2575, + 2197, 2198, 2199, 2200, 2201, 2202, 2203, 2204, 2205, 2206, + 2207, 2208, 2209, 2210, 2211, 2212, 2213, 2214, 2215, 2216, + 2217, 2218, 2219, 2220, 2576, 2577, 2221, 2222, 2223, 2224, + 2225, 2226, 2227, 2228, 2229, 2230, 2231, 2232, 2233, 2234, + 2235, 2236, 2237, 2238, 2239, 2240, 2241, 2242, 2243, 2578, + 2244, 2245, 2579, 2246, 2247, 2248, 2580, 2249, 2250, 2251, + 2252, 2253, 2584, 2585, 2586, 2573, 2366, 2550, 2572, 2583, + 2581, 2582, 2376, 2372, 2380, 2375, 0, 0, 0, 0, + 2392, 1152, 1151, 1137, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 526, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 2266, 0, 1163, 332, 331, 1238, 1219, 527, 0, 1140, + 356, 0, 0, 0, 0, 0, 0, 0, 0, 707, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 175, + 0, 0, 380, 379, 0, 0, 0, 903, 385, 0, + 0, 0, 0, 515, 2275, 2270, 2280, 0, 2273, 2274, + 2559, 0, 2708, 2019, 2306, 2307, 2706, 2067, 1316, 250, + 253, 251, 252, 0, 1003, 1004, 1006, 0, 0, 1016, + 740, 741, 0, 739, 743, 0, 0, 0, 736, 0, + 0, 0, 0, 742, 734, 0, 733, 0, 0, 0, + 738, 0, 735, 0, 0, 1141, 0, 2358, 2359, 1960, + 1277, 386, 0, 0, 1350, 0, 1239, 1246, 1256, 1251, + 1253, 1252, 1254, 1250, 1255, 1873, 842, 1887, 842, 1950, + 839, 840, 842, 842, 842, 2034, 0, 0, 814, 0, + 825, 1868, 842, 1869, 2617, 847, 441, 441, 441, 0, + 846, 851, 441, 1134, 1170, 1848, 1363, 0, 1887, 1950, + 815, 1133, 2082, 1269, 0, 0, 1020, 0, 1021, 0, + 2049, 1145, 234, 2557, 2058, 2143, 2082, 2558, 230, 2552, + 2553, 2555, 204, 2556, 2554, 2551, 1877, 0, 0, 846, + 0, 1142, 1143, 800, 1370, 1368, 0, 0, 0, 1895, + 0, 1907, 1986, 227, 2045, 2050, 2058, 2143, 2082, 2110, + 184, 189, 0, 243, 2058, 2143, 2082, 0, 1163, 0, + 1340, 1450, 1839, 0, 0, 2367, 1136, 1135, 1240, 0, + 1243, 0, 1415, 2031, 1344, 1346, 1245, 1337, 0, 0, + 2257, 1234, 1367, 1367, 0, 1367, 0, 1329, 1337, 1332, + 1336, 0, 0, 0, 0, 1153, 0, 2335, 2363, 2342, + 2398, 2339, 0, 0, 2388, 2384, 2381, 2389, 2390, 2383, + 2371, 1539, 1540, 1541, 1538, 1551, 1537, 0, 2316, 1542, + 2355, 2322, 0, 2330, 2329, 2634, 2635, 2445, 2268, 2287, + 0, 0, 0, 0, 0, 0, 0, 2414, 2416, 2418, + 2378, 2377, 2373, 0, 0, 0, 0, 2503, 2504, 2502, + 0, 2499, 2501, 0, 2398, 0, 2568, 2562, 2571, 0, + 1849, 2563, 2560, 2559, 0, 750, 0, 135, 891, 0, + 0, 0, 1843, 0, 0, 0, 0, 0, 1959, 0, + 0, 1744, 1899, 1946, 1754, 1752, 1753, 1746, 1747, 1748, + 1749, 1750, 1751, 0, 1001, 1745, 0, 135, 0, 1959, + 0, 0, 1959, 0, 0, 0, 0, 0, 1989, 135, + 1959, 0, 0, 0, 1157, 0, 0, 0, 1159, 1162, + 1138, 1222, 0, 1839, 0, 0, 784, 775, 0, 785, + 776, 781, 787, 0, 0, 778, 0, 0, 788, 0, + 777, 779, 790, 780, 786, 0, 0, 782, 783, 0, + 0, 1149, 441, 0, 0, 0, 0, 0, 0, 135, + 1209, 1959, 135, 0, 0, 384, 383, 135, 382, 381, + 1899, 1946, 0, 930, 135, 0, 177, 595, 530, 0, + 0, 666, 1989, 135, 0, 0, 0, 0, 906, 0, + 0, 514, 527, 0, 2279, 2285, 0, 2277, 2446, 2709, + 2707, 2401, 0, 1007, 228, 229, 1005, 1959, 0, 310, + 0, 0, 1959, 1198, 0, 737, 1959, 0, 1959, 170, + 1841, 0, 1899, 1946, 1959, 0, 0, 1959, 162, 1959, + 0, 1959, 310, 1959, 531, 0, 1959, 0, 1959, 1989, + 164, 0, 1959, 310, 748, 0, 0, 2639, 2643, 0, + 2641, 2636, 2357, 2411, 2410, 2309, 0, 2719, 0, 1316, + 1248, 2565, 1262, 1261, 0, 1257, 1265, 1260, 1350, 842, + 841, 0, 842, 0, 2728, 842, 0, 842, 0, 2728, + 842, 0, 0, 0, 842, 1870, 1871, 0, 0, 2727, + 2725, 2726, 816, 826, 0, 848, 0, 0, 855, 854, + 853, 0, 0, 0, 856, 1454, 1292, 0, 823, 0, + 821, 0, 1131, 1148, 0, 0, 0, 0, 1023, 1023, + 1023, 1144, 233, 231, 0, 0, 0, 0, 0, 0, + 1150, 0, 0, 0, 0, 2623, 1855, 1755, 2622, 0, + 2114, 2115, 2116, 1813, 0, 2564, 2117, 2118, 2159, 1667, + 1654, 1663, 1668, 1655, 1657, 1664, 2119, 2120, 1931, 2121, + 2122, 1862, 2123, 2124, 1494, 2126, 2127, 2128, 1659, 1661, + 2129, 2130, 0, 1863, 2132, 2133, 2007, 2135, 2136, 2138, + 2139, 1665, 2141, 2142, 2143, 2144, 2145, 2146, 1861, 0, + 1666, 2147, 2149, 2150, 2151, 2152, 2153, 2154, 2155, 2156, + 0, 0, 1836, 0, 1640, 0, 1486, 1487, 1509, 1510, + 1488, 1515, 1516, 1528, 1489, 0, 1835, 1553, 1639, 1644, + 0, 1638, 1634, 1353, 1831, 0, 1635, 1851, 1814, 1865, + 1864, 2617, 1822, 1854, 1852, 1853, 0, 0, 0, 196, + 0, 0, 2492, 245, 0, 246, 1837, 2058, 185, 226, + 198, 225, 199, 197, 0, 1897, 186, 0, 0, 187, + 0, 0, 0, 0, 0, 0, 0, 239, 1139, 0, + 1452, 1451, 0, 0, 1820, 1840, 757, 0, 1232, 1233, + 1231, 0, 1228, 1230, 1242, 1239, 1827, 1826, 1828, 0, + 1345, 0, 0, 0, 1327, 1326, 1245, 1365, 1366, 0, + 0, 0, 0, 0, 0, 0, 0, 1408, 1381, 1382, + 1384, 1405, 1409, 0, 1333, 0, 0, 1456, 0, 1416, + 2256, 2398, 2399, 0, 2393, 0, 2392, 2392, 2386, 2385, + 2382, 0, 0, 0, 0, 0, 0, 0, 2313, 509, + 2315, 507, 0, 0, 2289, 0, 2293, 2291, 0, 2438, + 2441, 0, 2439, 2440, 2442, 0, 2447, 2448, 0, 0, + 0, 2630, 0, 0, 2429, 2417, 2424, 2426, 2428, 2427, + 2436, 2432, 2435, 2437, 2379, 2392, 2510, 0, 2505, 2508, + 0, 2500, 0, 0, 0, 1850, 0, 0, 0, 0, + 751, 0, 0, 0, 0, 0, 0, 134, 1196, 236, + 1194, 0, 0, 0, 0, 0, 0, 0, 1201, 0, + 168, 169, 542, 527, 0, 1959, 0, 0, 0, 0, + 963, 970, 0, 0, 0, 0, 0, 0, 0, 964, + 962, 965, 238, 974, 987, 990, 0, 881, 0, 0, + 0, 0, 1066, 0, 0, 1066, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 256, 262, 305, + 0, 0, 0, 0, 0, 0, 0, 0, 139, 0, + 0, 0, 0, 0, 494, 506, 0, 0, 0, 0, + 0, 503, 0, 135, 258, 487, 491, 0, 0, 0, + 604, 603, 0, 1066, 0, 254, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 324, 325, 0, 0, 0, 139, 161, 0, 0, + 0, 260, 0, 2323, 0, 1158, 1155, 1156, 0, 1161, + 0, 1218, 0, 0, 0, 0, 0, 789, 0, 0, + 1899, 1946, 0, 0, 0, 0, 0, 0, 359, 338, + 339, 135, 337, 0, 0, 663, 0, 1497, 1526, 1504, + 1526, 1526, 1493, 1493, 1506, 1495, 1533, 0, 1526, 1493, + 1498, 0, 1496, 1536, 1536, 1521, 0, 1478, 1479, 1480, + 1481, 1507, 1508, 1482, 1513, 1514, 1483, 1550, 2569, 1493, + 2570, 2567, 2566, 0, 0, 674, 0, 1173, 1208, 0, + 0, 536, 0, 1959, 0, 137, 708, 0, 664, 0, + 137, 0, 173, 0, 599, 0, 0, 0, 0, 0, + 0, 624, 623, 0, 0, 0, 665, 0, 137, 490, + 1959, 0, 441, 441, 0, 905, 908, 0, 0, 0, + 2283, 2278, 2281, 0, 2271, 2285, 1319, 1321, 1320, 0, + 1318, 0, 310, 308, 309, 661, 1015, 0, 0, 0, + 0, 310, 0, 0, 1959, 310, 1959, 0, 1959, 0, + 0, 310, 310, 0, 0, 0, 0, 600, 0, 747, + 745, 744, 746, 0, 0, 0, 0, 0, 1959, 310, + 0, 0, 730, 2637, 0, 0, 2640, 0, 2360, 1765, + 0, 2722, 1274, 2723, 0, 0, 1350, 0, 215, 216, + 214, 1263, 217, 1264, 1259, 1247, 0, 834, 0, 2728, + 2729, 819, 0, 829, 0, 2728, 817, 0, 830, 827, + 828, 0, 0, 0, 2724, 2608, 2614, 833, 0, 0, + 442, 444, 0, 0, 1917, 1930, 0, 1951, 1977, 1978, + 2050, 2054, 0, 2077, 2086, 0, 857, 886, 852, 0, + 0, 1302, 824, 822, 1132, 1267, 1771, 0, 1350, 0, + 1022, 1019, 1018, 1017, 232, 205, 0, 0, 0, 888, + 2049, 1147, 799, 527, 0, 0, 1642, 1643, 1525, 1512, + 1812, 0, 0, 1520, 1519, 0, 0, 0, 0, 0, + 1502, 1501, 1500, 1641, 1779, 0, 1499, 0, 0, 0, + 0, 1526, 1526, 1524, 1573, 0, 1503, 0, 0, 1792, + 0, 1798, 0, 0, 0, 1532, 0, 1530, 0, 0, + 1609, 0, 0, 0, 0, 0, 0, 0, 0, 1557, + 1558, 1640, 1765, 0, 1858, 0, 0, 1518, 0, 1550, + 1755, 0, 0, 0, 0, 1825, 0, 1763, 0, 0, + 1587, 1761, 0, 1589, 0, 0, 0, 1754, 1752, 1753, + 1746, 1747, 1748, 1749, 1750, 1751, 1759, 1570, 0, 1834, + 0, 1569, 0, 0, 1418, 1352, 0, 1856, 1815, 0, + 2615, 2618, 1636, 2489, 2488, 2487, 2486, 2457, 0, 2451, + 2452, 0, 2490, 2491, 247, 248, 244, 0, 0, 201, + 200, 0, 223, 224, 195, 222, 0, 218, 219, 203, + 1707, 1706, 202, 194, 192, 190, 206, 208, 209, 193, + 191, 242, 240, 0, 0, 0, 1817, 1816, 1846, 1821, + 0, 0, 310, 2392, 1226, 0, 1223, 1830, 0, 1347, + 0, 0, 1235, 1343, 1342, 1374, 1375, 923, 1341, 1399, + 1400, 1395, 0, 1414, 1414, 1391, 1385, 1390, 1388, 0, + 1392, 1553, 1407, 1331, 1379, 1380, 1383, 1330, 0, 1410, + 1408, 1384, 1289, 0, 0, 1457, 0, 0, 2400, 2398, + 2338, 1478, 2392, 2331, 2392, 2387, 2319, 1544, 1545, 1546, + 1547, 1548, 1549, 2320, 0, 2317, 1543, 2318, 508, 0, + 0, 0, 2286, 0, 2267, 2292, 2423, 2532, 2455, 0, + 2456, 0, 0, 2420, 0, 2430, 2433, 2431, 2434, 0, + 1478, 2611, 2506, 2611, 1478, 0, 0, 0, 0, 0, + 0, 0, 0, 752, 0, 0, 0, 0, 0, 0, + 2077, 235, 1192, 0, 0, 0, 0, 890, 889, 0, + 0, 910, 0, 0, 0, 1204, 430, 0, 307, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 540, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 574, 0, 1066, 0, 612, + 0, 972, 0, 971, 0, 0, 0, 973, 968, 969, + 2050, 2058, 2082, 237, 989, 0, 988, 986, 945, 947, + 946, 0, 949, 933, 0, 934, 0, 0, 944, 952, + 950, 0, 0, 0, 0, 1939, 264, 277, 0, 1065, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 297, 0, 300, 299, 0, 0, 0, 0, 304, 0, + 0, 0, 303, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1002, 0, 0, 156, 159, 0, 0, 0, + 493, 505, 0, 497, 498, 495, 499, 500, 0, 0, + 0, 0, 0, 0, 492, 0, 0, 597, 596, 602, + 0, 0, 0, 0, 0, 0, 0, 1058, 1057, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 615, 616, 0, 617, 0, 160, 0, + 0, 0, 0, 0, 0, 0, 213, 1154, 1160, 1221, + 1847, 1220, 0, 0, 0, 791, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 343, 0, 689, 2566, 662, 0, 1478, 0, + 1474, 1470, 1539, 1538, 1537, 0, 1484, 1493, 1490, 675, + 0, 677, 680, 0, 1171, 403, 0, 533, 574, 0, + 0, 0, 166, 0, 0, 0, 133, 177, 386, 0, + 176, 178, 180, 181, 182, 179, 183, 594, 598, 0, + 529, 0, 0, 0, 0, 0, 625, 629, 628, 632, + 630, 0, 626, 0, 0, 1466, 0, 155, 486, 489, + 0, 2264, 0, 388, 472, 317, 0, 0, 907, 0, + 0, 0, 0, 0, 2284, 0, 0, 0, 0, 1317, + 0, 993, 0, 1199, 1959, 310, 0, 991, 171, 1842, + 0, 731, 0, 0, 0, 0, 0, 995, 727, 163, + 0, 310, 310, 532, 0, 310, 165, 0, 0, 0, + 524, 310, 749, 2638, 2644, 2642, 1276, 0, 2720, 2721, + 441, 1321, 1249, 1258, 831, 838, 820, 837, 836, 818, + 835, 832, 2422, 0, 0, 2613, 0, 849, 0, 440, + 0, 0, 0, 863, 864, 0, 0, 862, 879, 865, + 0, 867, 859, 858, 868, 869, 0, 0, 888, 0, + 1299, 0, 1297, 0, 1455, 1301, 1290, 1268, 0, 1266, + 1271, 1273, 1272, 1270, 0, 0, 0, 846, 0, 0, + 310, 1146, 0, 801, 802, 807, 0, 0, 0, 808, + 804, 805, 806, 809, 810, 811, 0, 0, 0, 1775, + 0, 1776, 0, 0, 0, 1811, 1807, 0, 0, 0, + 0, 0, 0, 1783, 1784, 1785, 1782, 1786, 1781, 0, + 0, 1787, 1780, 0, 0, 0, 0, 0, 1523, 1522, + 0, 0, 0, 0, 0, 0, 0, 1612, 1644, 0, + 0, 1739, 0, 1765, 1797, 0, 0, 1534, 0, 0, + 0, 0, 0, 0, 0, 1765, 1803, 0, 0, 0, + 0, 1705, 0, 1702, 0, 0, 0, 0, 1822, 0, + 0, 0, 0, 1859, 1554, 1571, 1833, 0, 1824, 0, + 0, 1555, 1578, 0, 1804, 1605, 0, 1610, 1593, 0, + 1586, 0, 1591, 1595, 1574, 1825, 1764, 0, 1762, 0, + 0, 1572, 0, 1567, 1565, 1566, 1559, 1560, 1561, 1562, + 1563, 1564, 1568, 1743, 1741, 1742, 0, 0, 0, 1590, + 1953, 1986, 0, 1364, 1364, 1364, 1351, 1362, 1832, 0, + 1461, 0, 0, 0, 0, 1722, 0, 1769, 0, 1767, + 1849, 2620, 2619, 1823, 0, 0, 0, 1838, 0, 0, + 1550, 0, 241, 1453, 1818, 0, 755, 756, 754, 1478, + 1245, 1229, 1225, 1224, 1829, 1244, 1350, 0, 921, 922, + 0, 926, 0, 0, 1393, 1406, 0, 1302, 1302, 0, + 1397, 1398, 1389, 1335, 1334, 0, 1464, 0, 0, 1286, + 1279, 1458, 0, 1418, 1304, 1306, 1307, 0, 1822, 2336, + 2394, 2341, 2362, 2332, 2365, 1552, 2314, 2354, 0, 2288, + 2458, 2459, 0, 2449, 2450, 2419, 2425, 2496, 0, 2612, + 0, 0, 687, 686, 0, 0, 0, 1092, 1025, 1070, + 753, 1093, 1026, 1071, 1094, 1027, 1193, 0, 1195, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 650, 1959, 310, 1202, 1095, 0, 1028, + 306, 1203, 1072, 1207, 1073, 0, 541, 0, 0, 546, + 547, 548, 0, 0, 549, 1899, 1946, 0, 554, 560, + 564, 555, 0, 565, 561, 0, 0, 0, 0, 0, + 0, 571, 573, 0, 0, 0, 0, 0, 0, 966, + 967, 1096, 1031, 0, 1074, 948, 1493, 932, 0, 0, + 943, 0, 942, 1493, 1493, 1032, 167, 0, 257, 265, + 580, 1068, 283, 296, 291, 292, 290, 1959, 310, 1959, + 310, 0, 0, 0, 0, 293, 288, 289, 285, 298, + 1876, 1932, 2059, 0, 584, 586, 0, 591, 301, 1044, + 0, 318, 321, 302, 281, 284, 282, 278, 263, 0, + 0, 1845, 0, 0, 997, 0, 0, 0, 158, 1054, + 0, 0, 144, 0, 0, 0, 0, 138, 148, 1102, + 1036, 0, 0, 259, 488, 496, 501, 1040, 504, 1084, + 502, 1108, 1037, 1066, 0, 255, 0, 1038, 0, 1078, + 1104, 1056, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1210, 0, 0, 0, 0, 0, 310, 0, 696, + 1068, 1959, 310, 1103, 0, 1063, 1090, 0, 326, 0, + 1055, 0, 0, 261, 1042, 1086, 0, 0, 211, 210, + 212, 0, 0, 0, 0, 0, 0, 0, 0, 793, + 764, 792, 0, 0, 0, 0, 0, 0, 0, 758, + 358, 335, 336, 0, 0, 334, 340, 688, 0, 0, + 0, 1475, 1471, 0, 0, 0, 0, 0, 0, 1491, + 676, 0, 0, 0, 0, 1191, 1191, 1191, 1191, 1191, + 1191, 1191, 1172, 1200, 135, 0, 0, 0, 535, 573, + 580, 0, 608, 611, 0, 609, 0, 0, 0, 0, + 0, 149, 136, 0, 716, 441, 172, 0, 0, 0, + 528, 673, 671, 670, 672, 0, 0, 0, 693, 669, + 0, 1465, 1467, 0, 0, 0, 0, 390, 0, 0, + 387, 391, 395, 396, 397, 444, 0, 0, 476, 0, + 0, 0, 0, 937, 0, 955, 938, 0, 0, 0, + 977, 982, 978, 958, 0, 512, 2282, 2276, 1322, 1323, + 0, 310, 0, 0, 575, 310, 310, 0, 310, 0, + 310, 310, 0, 1129, 601, 0, 658, 0, 0, 310, + 729, 1766, 0, 2421, 2609, 850, 443, 0, 0, 0, + 0, 861, 0, 510, 866, 0, 878, 873, 875, 0, + 882, 1300, 1293, 1295, 1294, 0, 0, 1291, 1772, 728, + 0, 0, 310, 0, 883, 0, 803, 0, 0, 0, + 0, 1369, 1773, 1774, 0, 0, 0, 0, 1808, 0, + 0, 1680, 0, 1656, 1658, 1492, 1670, 0, 1505, 1681, + 1682, 1660, 1662, 0, 1756, 0, 0, 1671, 1614, 1615, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1627, 1626, 1672, 1738, 0, 0, 1795, + 1796, 1673, 1535, 1536, 1536, 0, 0, 1802, 0, 0, + 0, 1678, 1683, 0, 0, 0, 0, 1689, 0, 1710, + 0, 0, 0, 1637, 1766, 1527, 1528, 0, 0, 0, + 0, 0, 0, 0, 0, 1611, 1594, 1588, 0, 1592, + 1596, 0, 0, 0, 0, 1580, 1606, 1576, 0, 0, + 1582, 0, 1607, 1364, 1364, 1364, 1364, 1361, 0, 0, + 0, 0, 1428, 1417, 1419, 1430, 1421, 1423, 1459, 0, + 1839, 0, 1402, 1373, 1373, 0, 1722, 0, 1645, 0, + 1722, 0, 0, 2471, 2473, 2474, 2475, 2476, 2477, 2479, + 2480, 2482, 2483, 2484, 2472, 2478, 2481, 2485, 2462, 2463, + 0, 2453, 2454, 188, 0, 220, 207, 0, 2496, 1227, + 0, 1376, 0, 1757, 926, 924, 925, 1378, 0, 0, + 1413, 1412, 1411, 1386, 1288, 0, 1286, 1281, 0, 1282, + 1822, 0, 1278, 1311, 0, 0, 1464, 0, 1310, 0, + 2396, 2324, 0, 0, 2495, 2498, 2509, 2507, 2334, 1091, + 1024, 1069, 1191, 893, 894, 0, 892, 0, 0, 0, + 429, 909, 0, 0, 0, 650, 0, 0, 433, 0, + 1205, 0, 543, 544, 0, 0, 562, 0, 0, 551, + 0, 0, 0, 0, 550, 567, 516, 568, 570, 0, + 0, 569, 572, 577, 1066, 0, 613, 1046, 0, 1088, + 960, 0, 1493, 935, 940, 941, 0, 0, 0, 403, + 0, 0, 0, 266, 276, 0, 0, 280, 0, 274, + 294, 286, 295, 287, 588, 589, 587, 583, 0, 590, + 592, 315, 0, 0, 0, 1098, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 1099, 1075, 0, + 0, 141, 140, 0, 147, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 327, 312, 0, + 0, 0, 0, 0, 329, 0, 0, 0, 0, 1097, + 1033, 759, 0, 0, 760, 768, 0, 0, 761, 0, + 0, 0, 0, 0, 0, 770, 361, 0, 364, 371, + 344, 348, 1209, 0, 1209, 0, 349, 1209, 345, 1209, + 342, 690, 0, 2007, 1746, 1747, 684, 691, 681, 683, + 682, 685, 650, 0, 0, 0, 1476, 0, 2710, 2718, + 2717, 0, 1550, 678, 679, 0, 1191, 1190, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 415, + 0, 0, 409, 0, 0, 982, 402, 405, 406, 536, + 539, 537, 538, 566, 0, 607, 0, 580, 151, 0, + 0, 152, 150, 0, 317, 386, 0, 0, 631, 634, + 627, 0, 692, 694, 667, 0, 580, 0, 1277, 485, + 0, 472, 422, 468, 0, 470, 469, 471, 0, 478, + 316, 0, 0, 910, 936, 0, 0, 0, 975, 979, + 976, 0, 0, 951, 0, 959, 929, 1124, 1125, 1122, + 1123, 0, 0, 2299, 1313, 2308, 994, 0, 310, 992, + 732, 0, 723, 0, 725, 996, 310, 310, 618, 0, + 525, 0, 0, 0, 0, 860, 880, 0, 876, 0, + 0, 843, 885, 1298, 1296, 888, 0, 844, 887, 0, + 0, 0, 0, 0, 1777, 1511, 0, 1810, 1806, 0, + 1653, 1778, 0, 1790, 1789, 1613, 1791, 0, 1632, 0, + 0, 1624, 1622, 1623, 1616, 1617, 1618, 1619, 1620, 1621, + 1625, 1800, 1799, 1793, 1794, 1531, 1529, 0, 1675, 1676, + 1677, 1801, 1684, 0, 1890, 1711, 1688, 1704, 1703, 0, + 0, 0, 1691, 0, 0, 1700, 0, 1740, 1517, 1550, + 1556, 0, 0, 1579, 1805, 1597, 0, 0, 0, 1575, + 0, 0, 0, 0, 1584, 1756, 0, 0, 0, 0, + 0, 0, 1355, 1354, 1360, 1337, 0, 1430, 0, 1429, + 1441, 0, 0, 1447, 1445, 0, 1447, 0, 1447, 0, + 1422, 0, 1424, 1441, 0, 1840, 1460, 0, 1404, 0, + 0, 1372, 0, 1722, 1652, 1725, 1720, 1721, 1770, 1646, + 1857, 0, 1768, 1722, 0, 0, 0, 1819, 2494, 1348, + 0, 1377, 1394, 1387, 0, 1462, 1287, 0, 0, 1284, + 0, 0, 0, 1305, 1286, 1308, 2340, 0, 2395, 2460, + 2461, 0, 899, 900, 898, 901, 0, 0, 0, 650, + 0, 0, 449, 0, 917, 917, 0, 0, 435, 481, + 982, 653, 0, 0, 0, 651, 310, 1029, 0, 563, + 0, 0, 559, 557, 556, 558, 517, 1107, 1030, 0, + 0, 0, 0, 961, 0, 953, 1045, 0, 400, 0, + 271, 1067, 0, 0, 0, 270, 0, 310, 310, 585, + 319, 320, 323, 0, 0, 0, 0, 0, 0, 717, + 700, 0, 0, 718, 719, 0, 0, 0, 999, 1000, + 998, 145, 142, 143, 146, 1041, 1085, 1039, 0, 1079, + 1050, 1048, 0, 0, 0, 0, 0, 1106, 1062, 1083, + 1105, 1060, 1081, 1059, 1080, 1061, 1082, 1053, 0, 1469, + 698, 697, 0, 310, 310, 620, 1043, 1087, 0, 762, + 0, 0, 763, 774, 772, 771, 773, 765, 362, 135, + 0, 341, 0, 369, 0, 367, 366, 368, 0, 355, + 0, 0, 0, 0, 0, 660, 0, 0, 0, 1472, + 0, 0, 0, 0, 0, 0, 1477, 1485, 649, 0, + 1182, 1181, 1180, 1184, 1183, 1186, 1185, 1177, 1176, 1189, + 1188, 1175, 1174, 1179, 1178, 0, 407, 0, 413, 417, + 418, 416, 408, 982, 441, 480, 534, 0, 610, 605, + 154, 153, 0, 0, 0, 0, 636, 640, 668, 0, + 1468, 614, 0, 388, 485, 0, 2265, 0, 393, 398, + 399, 0, 476, 419, 0, 472, 392, 0, 0, 482, + 1169, 0, 0, 939, 956, 957, 0, 0, 982, 981, + 0, 519, 0, 2272, 310, 576, 310, 310, 1130, 659, + 0, 872, 871, 870, 511, 0, 874, 310, 0, 0, + 0, 0, 0, 813, 794, 812, 1809, 1669, 1679, 1788, + 0, 0, 1633, 0, 0, 1674, 2148, 0, 0, 0, + 0, 1708, 1709, 1690, 0, 1998, 1695, 0, 0, 0, + 1860, 1603, 1601, 1598, 0, 1599, 0, 0, 1581, 1577, + 0, 1583, 1608, 1359, 1358, 1357, 1356, 1432, 1439, 0, + 1420, 0, 1446, 1442, 0, 1443, 0, 0, 1444, 0, + 0, 1439, 0, 0, 0, 0, 1716, 1722, 1722, 1647, + 1727, 1724, 0, 1649, 2464, 0, 2467, 2465, 2466, 2470, + 1550, 0, 0, 1280, 1283, 1285, 0, 1312, 1303, 2397, + 1197, 0, 0, 0, 431, 0, 982, 0, 0, 0, + 920, 920, 0, 982, 480, 655, 654, 657, 652, 656, + 1206, 0, 552, 553, 1047, 0, 1089, 1051, 954, 0, + 581, 267, 268, 269, 272, 312, 279, 273, 0, 1100, + 1034, 1076, 0, 0, 706, 0, 0, 0, 0, 1101, + 1035, 1077, 0, 0, 0, 0, 1215, 0, 311, 312, + 328, 1064, 0, 766, 767, 343, 0, 365, 374, 0, + 372, 346, 351, 0, 353, 352, 347, 350, 1473, 0, + 1013, 1013, 2711, 2712, 2713, 2714, 2715, 2716, 0, 650, + 1187, 0, 0, 404, 480, 448, 0, 410, 0, 0, + 0, 388, 580, 635, 0, 0, 0, 695, 390, 0, + 1275, 483, 0, 389, 0, 0, 478, 0, 0, 0, + 476, 0, 473, 0, 477, 0, 1164, 0, 0, 980, + 0, 984, 0, 950, 927, 1461, 0, 523, 2298, 2302, + 1014, 724, 726, 619, 877, 884, 310, 795, 796, 797, + 798, 1628, 0, 0, 0, 0, 1685, 0, 1686, 1713, + 1712, 1692, 1696, 0, 1693, 1694, 1600, 1604, 1602, 1585, + 1431, 0, 0, 1433, 0, 0, 1435, 1437, 0, 0, + 0, 0, 0, 1843, 1722, 1401, 1403, 0, 1338, 1650, + 1651, 0, 1373, 1722, 2469, 2468, 221, 1758, 1463, 1309, + 878, 0, 310, 917, 480, 450, 2007, 451, 916, 0, + 918, 923, 923, 0, 480, 650, 545, 0, 579, 0, + 314, 322, 0, 0, 713, 701, 0, 0, 720, 1049, + 0, 0, 0, 0, 0, 310, 769, 333, 360, 370, + 0, 354, 1013, 0, 1010, 1009, 648, 0, 439, 411, + 0, 459, 0, 580, 710, 1169, 593, 637, 638, 633, + 0, 0, 472, 468, 484, 394, 403, 377, 428, 427, + 424, 423, 425, 426, 421, 420, 0, 478, 474, 475, + 0, 0, 0, 1217, 0, 911, 983, 0, 0, 0, + 518, 0, 0, 522, 513, 0, 2300, 845, 1629, 0, + 1630, 0, 0, 0, 1698, 1697, 0, 1440, 1449, 0, + 1436, 1434, 1425, 0, 1427, 1715, 1717, 0, 0, 1730, + 1648, 895, 0, 896, 920, 454, 0, 919, 926, 926, + 441, 650, 432, 1052, 582, 0, 275, 0, 704, 0, + 715, 713, 0, 0, 1211, 0, 1212, 1213, 1216, 330, + 373, 1008, 1012, 1011, 0, 0, 412, 445, 446, 447, + 0, 414, 455, 456, 0, 606, 0, 0, 1165, 0, + 0, 476, 472, 401, 467, 375, 0, 1166, 0, 317, + 0, 982, 985, 1128, 521, 520, 2303, 2305, 2304, 0, + 1631, 1701, 1687, 1714, 1699, 1438, 0, 1426, 0, 0, + 1726, 0, 0, 0, 0, 923, 0, 650, 0, 914, + 913, 448, 434, 313, 0, 0, 711, 714, 702, 715, + 722, 721, 0, 0, 438, 0, 0, 0, 457, 0, + 458, 479, 709, 0, 639, 0, 478, 476, 1167, 1168, + 478, 912, 928, 1127, 1126, 1350, 2301, 1448, 1718, 1719, + 2113, 0, 2088, 0, 1728, 1731, 1729, 1723, 310, 926, + 0, 436, 452, 459, 0, 0, 703, 1214, 640, 464, + 0, 463, 0, 461, 460, 699, 643, 378, 478, 1461, + 1110, 1350, 1109, 1111, 1119, 1116, 1118, 1117, 1115, 0, + 1735, 1734, 1733, 1737, 1736, 897, 915, 0, 650, 705, + 712, 0, 462, 466, 465, 0, 641, 644, 647, 645, + 646, 376, 902, 0, 1120, 1114, 1337, 1324, 0, 453, + 437, 0, 621, 0, 1112, 1350, 1732, 0, 642, 1113, + 0, 643, 0, 622 +}; + +/* YYDEFGOTO[NTERM-NUM]. */ +static const yytype_int16 yydefgoto[] = +{ + -1, 1, 247, 248, 1698, 2592, 2475, 3281, 3282, 249, + 250, 1769, 251, 252, 253, 254, 255, 256, 257, 1713, + 258, 259, 1275, 1912, 2600, 260, 2351, 1051, 1052, 2225, + 2226, 2537, 2227, 2214, 1550, 2012, 1732, 1700, 1733, 262, + 263, 1544, 2206, 264, 265, 266, 1757, 1758, 1708, 1955, + 4179, 4746, 2462, 3320, 3120, 3121, 267, 1811, 1812, 268, + 269, 3233, 1851, 3235, 3236, 3770, 861, 2561, 4199, 4200, + 3757, 3758, 4206, 4479, 4480, 270, 1909, 3309, 3851, 3310, + 4277, 3311, 4278, 3312, 4279, 3263, 3816, 3817, 3818, 3313, + 4283, 4684, 3314, 2366, 4766, 2634, 2042, 2040, 4661, 4081, + 4082, 4817, 4771, 4772, 4773, 4883, 4285, 3318, 3859, 4289, + 4507, 3023, 1931, 4276, 271, 272, 2628, 1785, 1786, 2482, + 3776, 3374, 273, 1292, 3635, 4547, 4703, 4704, 274, 849, + 275, 1916, 276, 277, 2587, 3268, 278, 2378, 3036, 279, + 280, 3061, 3062, 3063, 281, 282, 3659, 4439, 1759, 3113, + 3114, 3115, 3116, 3679, 283, 1914, 1791, 2609, 284, 285, + 286, 2591, 3274, 3275, 287, 288, 2525, 289, 290, 291, + 1924, 2621, 2622, 4267, 4514, 4669, 4516, 4915, 4916, 4499, + 3618, 4095, 292, 293, 294, 295, 1895, 2580, 2581, 3777, + 1684, 1855, 2563, 2564, 3841, 3842, 296, 297, 4139, 4140, + 891, 4777, 4750, 4828, 298, 299, 4143, 4144, 300, 301, + 302, 303, 304, 944, 1343, 1344, 1690, 305, 2242, 306, + 1250, 3220, 307, 1433, 2767, 4324, 308, 978, 1370, 1371, + 309, 310, 989, 2747, 991, 2055, 3376, 3377, 3911, 2717, + 1175, 311, 312, 2728, 2750, 313, 1701, 2357, 2358, 4076, + 314, 892, 1936, 2637, 3018, 4694, 4083, 4420, 4621, 2941, + 3567, 315, 893, 1737, 2424, 2640, 3324, 3325, 2426, 2906, + 3872, 2428, 3326, 3331, 3332, 3333, 3868, 3876, 4541, 4542, + 316, 1735, 2417, 317, 318, 319, 1764, 1193, 320, 914, + 915, 321, 4654, 322, 1311, 323, 1009, 2071, 324, 2440, + 3665, 325, 326, 327, 4892, 4923, 4924, 4925, 3881, 4855, + 328, 4894, 1412, 330, 331, 332, 852, 1218, 1219, 1220, + 333, 4536, 334, 335, 2584, 3262, 3798, 336, 337, 2352, + 3008, 338, 339, 340, 1899, 341, 342, 343, 344, 1831, + 345, 1581, 1582, 346, 347, 856, 1070, 1585, 1593, 348, + 957, 1364, 1365, 1366, 2014, 349, 1416, 2739, 958, 1357, + 959, 2959, 3578, 3579, 3582, 960, 2956, 353, 2061, 2733, + 2736, 961, 2963, 2964, 2965, 2966, 2967, 3584, 962, 980, + 1302, 2648, 963, 1504, 358, 359, 360, 1079, 1074, 1075, + 362, 2184, 2896, 997, 1599, 1036, 1086, 4031, 2255, 2256, + 2276, 2277, 1608, 1609, 2266, 2268, 2943, 2269, 2952, 2261, + 4028, 4386, 2272, 2273, 1611, 1612, 2947, 363, 2900, 3513, + 3514, 3515, 4009, 4019, 4373, 4586, 3516, 1406, 1618, 3517, + 3522, 3576, 3300, 3301, 3302, 2429, 2571, 1877, 1505, 1878, + 2578, 1506, 2106, 1880, 1507, 1508, 1509, 1883, 1510, 1511, + 1512, 1513, 2089, 2147, 1514, 1515, 2125, 1118, 1119, 1999, + 2806, 1517, 1518, 3975, 4348, 4337, 2832, 2833, 2222, 3971, + 3465, 4598, 4725, 4726, 4039, 4036, 4390, 4602, 4813, 4864, + 4865, 1519, 2886, 2176, 1195, 1520, 3779, 2178, 2826, 2908, + 2909, 2336, 2087, 2772, 2789, 2790, 2803, 3426, 2810, 2815, + 3449, 3450, 2827, 2855, 1521, 2775, 2776, 3409, 2091, 1522, + 1574, 1575, 2192, 2850, 1588, 1589, 1072, 1523, 1524, 2056, + 1061, 4582, 1320, 699, 3130, 2237, 1222, 994, 1525, 1526, + 1527, 3378, 1639, 678, 679, 1156, 803, 2, 75, 964, + 3306, 367, 368, 895, 896, 897, 1294, 1295, 1941, 1944, + 1644, 2314, 680, 681, 708, 4303, 4548, 4706, 950, 369, + 370, 371, 372, 1640, 2310, 1120, 76, 84, 77, 1121, + 409, 410, 2292, 373, 820, 374, 1621, 1100, 3590, 375, + 376, 377, 378, 379, 947, 380, 1102, 381, 1103, 382, + 383, 384, 385, 1110, 386, 1623, 1624, 4068, 1625, 387, + 388, 701, 702, 1355, 389, 390, 1137, 1138, 1389, 1390, + 1650, 1665, 1666, 1667, 391, 695, 392, 393, 394, 1656, + 1657, 395, 2199, 2200, 2319, 2201, 396, 2980, 2981, 397, + 3548, 3549, 4397, 3550, 398, 2195, 399, 400, 1064, 3595, + 401, 816, 402, 1151, 682, 683, 684, 1158, 806, 1022, + 709, 1160, 3117, 808, 809, 686, 687, 688, 2034, 78, + 2988, 2035, 1529, 710, 1530, 2190, 1531, 1532, 1533, 1534, + 1535, 1673, 692, 1127, 1347, 1348, 2989, 1350, 82, 1351, + 406, 3791, 2002, 1391, 2020, 2021 +}; + +/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing + STATE-NUM. */ +#define YYPACT_NINF -4498 +static const int yypact[] = +{ + -4498, 400, 10072, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, 22586, -4498, + -4498, -4498, -4498, -4498,101242, 493, -4498, -4498, -4498, 61800, + -4498, -4498, -4498, 248, 67091, -4498, 70458, 997, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, 74306, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, 54573, 1323, -4498, + 438, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -49, 7071, + -4498, -4498, 70939, -4498, 153, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, 71420, 814, -4498, -4498, 986, 1293, -4498, 86, + 14019, -4498, -4498, 62762, 68053, -4498, -4498, 74787, 343, 1695, + 4268, -49, 22102, 75268, -4498, 1899, -4498, 51164, -4498, -4498, + -4498, 67572, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, 82483, 2369, 989, 51654, -4498, -4498, + -4498, -4498, 82483, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, 75749, -4498, 1161, 1138, 82964, 83445, 64686, + -4498, 1386, -4498, 82483, 1254, 1032, 53609, -4498, 83926, -4498, + -4498, 1141, -4498, 76230, -4498, -4498, -4498, -4498, 989, -4498, + 54573, 48730, 17, 1102, -4498, -4498, 84407, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, 1630, 1148, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, 814, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, 292, -4498, 969, + 462, 1555, 230, 1196, -4498, -4498, -4498, 9438, -4498, -4498, + -4498, -4498, -4498, -4498, -4498,102676, 1993, -4498, -4498, -4498, + 1297, -4498, 1456, -4498, -4498, -4498, 1631, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, 392, -4498, -4498, -4498, -4498, 1860, + 101720, 74306, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, 62281, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, 172, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, 74306, 74306, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, 74306, 1590, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, 403, 1789, -4498, -4498, 54573, 2567, 2567, 2047, + 102676, -4498, -4498, -4498, 55537, 82483, 82483, 82483, 1805, 82483, + 82483, 79, 55537, 82483, 84888, 1804, 44307, -4498, 82483, 82483, + 85369, 82483, 76711, 82483, 1755, 82483, 82483, 85850, 86331, 1888, + -4498, 2148, 1624, -4498, -4498, -4498, 82483, 6357, 2369, -4498, + -4498, 82483, 1766, 55537, 82483, 1747, 82483, 1845, 82483, -4498, + 82483, 86812, 259, 1782, 82483, 1951, 44801, 1885, 82483, 82483, + 82483, 82483, -4498, -4498, 1907, 82483, 82483, -4498, -4498, 87293, + 1523, 2143, 2061, 1008, -4498, -4498, 2232, 1840, -4498, -4498, + 2271, 74306, -4498, 71901, -4498, -4498, -4498, 317, -4498, -4498, + -4498, -4498, -4498, 65167, 1695, -4498, -4498, 56019, 82483, 2134, + -4498, -4498, 87774, -4498, -4498, 637, 56501, 88255, 2201, 45295, + 2257, 88736, 89217, -4498, -4498, 89698, -4498, 90179, 2004, 90660, + -4498, 91141, -4498, 2126, 91622, -4498, 14812, -4498, 1909, 1859, + 1926, 759, 74306, 74306, 1272, 39933, 814, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, 195, 1191, 52144, 541, 52634, + -4498, -4498, 709, 792, 1026, 195, 2347, 2347, 28, 74306, + -4498, -4498, 1191, -4498, 627, -57, 1935, 1935, 1935, 2178, + 1120, -4498, 1935, -4498, -4498, -4498, -4498, 76230, 52144, 52634, + -4498, 2015, 2369, 106, 2332, 82483, -4498, 82483, -4498, 82483, + 82483, -4498, -4498, -4498, 2356, 2006, 2240, -4498, 2022, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, 2205, 2220, 2224, 70, + 2369, 2123, -4498, 2340, -4498, 2249, 27583, 463, 74306, 2369, + 53124, 77192, 98837, 210, 65167, 2369, 92103, 2077, 1487, 2247, + -4498, -4498, 690, -4498, 2482, 2099, 2321, 211, 1624, 41873, + -4498, 2120, 424, 76230,103154, -4498, -4498, -4498, -4498, 366, + 2386, 28082, -4498, 82483, 2111, -4498, 2128, 2119, 2122, 1555, + -4498, 82483, 1129, 1129, 2507, 1129, 1256, 1924, -4498, 2290, + -4498, 2408, 2374, 76230, 1102, -49, 2137, -4498, -4498, -4498, + 2149, -4498, 2132, 2172, -4498, 514, 2410, -4498, -4498, -4498, + -4498, 2255, 2258, 2263, 2264, 2194, 2274, 258, -4498, -4498, + -4498, -4498, 2510, -4498, -4498, -4498, -4498, -4498, -4498, 2592, + 2591, 62762, 62762, 41, 121, 139, 265, -4498, -4498, -4498, + 2460, -4498, -4498, 2453, 82483, 2299, 82483, -4498, -4498, -4498, + 92584, -4498, -4498, 2567, 2149, 2236, -4498, 277, -4498, 424, + -4498, 329, 409, 427, 1423, 2226, 1724, 1646, -4498, 705, + 2357, 188, 797, 2284, 77673, 4527, 2261, 758, 2564, 2101, + 258, -4498, 82483, 82483, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, 2283, -4498, -4498, 2303, 1383, 898, 2589, + 7841, 1612, 2593, 2399, 1567, 730, 2491, 831, 2595, 1243, + 2607, 5600, 82483, 2317, -4498, 2545, 2652, -35, -4498, 57, + -4498, 2387, 2526, 1112, 55537, 2336, -4498, -4498, 82483, -4498, + -4498, -4498, -4498, 693, 55537, -4498, 2528, 45789, -4498, 82483, + -4498, -4498, -4498, -4498, -4498, 2472, 82483, -4498, -4498, 2597, + 82483, -4498, 1935, 988, 2360, 2730, 58911, 130, 82483, 2403, + 2767, 2569, 2403, 2409, 93065, -4498, -4498, 2403, -4498, -4498, + 82483, 82483, 2379, 1402, 2403, 2773, 2779, 2487, 2584, 763, + 1370, 107, 2706, 2403, 82483, 93546, 82483, 82483, 2783, 55537, + 82483, -4498, 2581, 78154, -4498, 2429, 2232, -4498, -4498, -4498, + -4498, -4498, 1236, -4498, -4498, -4498, -4498, 2727, 2236, 576, + 2737, 2449, 2748, -4498, 2495, -4498, 2772, 2261, 2777, 2490, + -4498, 94027, 94508, 94989, 2786, 2283, 82483, 2789, 2490, 2795, + 2687, 2804, 576, 2830, -4498, 806, 2847, 2728, 2851, 1811, + 2490, 65648, 2853, 85, -4498, 23047, 14812, -4498, 23610, 1668, + -4498, -4498, -4498, -4498, -4498, -4498, 31575, 508, 2647, -4498, + -4498, 1102, -4498, -4498, 1831, -4498, 50674, -4498, 1272, 1191, + -4498, 74306, 1191, 74306, 28, 1191, 74306, 1191, 74306, 28, + 1191, 74306, 74306, 74306, 1191, -4498, -4498, 1913, 1684, -4498, + -4498, -4498, -4498, -4498, 74306, 2565, 82483, 82483, -4498, -4498, + -4498, 68534, 82483, 69015, -4498, -4498, 242, 74306, -4498, 74306, + -4498, 2369, -4498, -4498, 1859, 58911, 2959, 82483, 2846, 2846, + 2846, -4498, -4498, -4498, 2787, 82483, 2849, 2850, 68534, 82483, + -4498, 95470, 65167, 2750, 2571, -4498, -4498, -4498, -4498, 1931, + 2582, 247, 2827, 31575, 2572, 235, 235, 2575, 2859, -4498, + -4498, -4498, 436, 2579, 2583, -4498, 182, 182, 2738, 2585, + 2586, -4498, 484, 2590, -4498, 2840, 505, 2596, 2598, 2600, + 1017, 235, 31575, -4498, 2601, 182, 2602, 2603, 2604, 2854, + 2608, -4498, 2879, 2609, 379, 419, 2612, 2614, -4498, 2585, + -4498, 473, 2616, 2617, 2618, 2619, 2620, 2621, 2622, 2623, + 31575, 31575, -4498, 26585, -4498, 2369, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, 87, -4498, 523, 5467, -4498, -4498, 2752, + 31575, -4498, -4498, -13, -4498, 708, -4498, -4498, 424, -4498, + -4498, 1242, -4498, -4498, -4498, -4498, 1781, 1781, 200, -4498, + 70939, 70939, -4498, -4498, 1276, 2594, -4498, 263, -4498, -4498, + -4498, -4498, -4498, -4498, 63243, 2984, -4498, 1016, 2369, 57, + 1435, 2932, 49694, 50184, 2832, 2832, 2813, -4498, -4498, 82483, + -4498, -4498, 31575, 47766, -4498, 424, 63, 2848, -4498, -4498, + -4498, 1970, -4498, -4498, -4498, 814, -4498, 13383, -4498, 1998, + 2111, 82483, 82483, 3019, -4498, -4498, 2128, -4498, -4498, 1555, + 1555, 31575, 1555, 666, 1302, 28581, 31575, 2907, 2811, 159, + 1307, 2912, -4498, 1256, 1924, 76230, 82483, 95951, 2739, -4498, + -4498, 2149, 2640, 1446, -4498, 60838,102198,102198, 2875, -4498, + -4498, 1121, 23, 2751, 2841, 2347, 1583, 1714, -4498, -4498, + 2633, -4498, 2962, 70939, 2693, 62762, -4498, -4498, 82483, -4498, + -4498, 78635, -4498, -4498, -4498, 1962, 2638, -4498, 2655, 82483, + 3133, -4498, 1714, 1714, -4498, -4498, 2642, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498,102676, 2646, 82483, -4498, 2648, + 2649, -4498,103154, 48248, 1937, 424, 2721, 2724, 2771, 54573, + 2651, 2729, 2731, 2778, 2732, 2744, 99318, -4498, -4498, -4498, + -4498, 1571, 1300, 1379, 2745, 197, 662, 3004, -4498, 2782, + -4498, -4498, -4498, 3624, 82483, 2964, 5966, 2855, 258, 2788, + -4498, -4498, 2897, 2753, 2754, 2865, 258, 125, 99799, -4498, + -4498, -4498, -4498, -4498, -4498, 3289, 25114, -4498, 2755, 2735, + 82483, 63724, 3035, 2858, 466, 1887, 243, 82483, 2935, 2873, + 82483, 2690, 2766, 2769, 2697, 1876, 3043, 2700, -4498, -4498, + 2871, 2757, 2758, 57947, 1110, 46283, 3037, 2784, -4498, 1416, + 2785, 2790, 82483, 258, -4498, 3087, 258, 258, 1609, 3090, + 2791, 308, 1716, 2403, 2700, 1573, -4498, 2792, 2793, 955, + -4498, 2889, 76230, 219, 1806, 2700, 2794, 2796, 2697, 2697, + 82483, 82483, 82483, 82483, 82483, 115, 3104, 3110, 2798, 123, + 2844, 2723, -4498, 72382, 2801, 98837, -4498, -4498, 82483, 2802, + 1918, 2700, 1089, -4498, 1861, -4498, -4498, -4498, 1624, -4498, + 82483, -4498, 82483, 2236, 58911, 2910, 2762, -4498, 2261, 258, + 82483, 82483, 2283, 1152, 958, 2915, 82483, 2971, 2776, -4498, + -4498, 2403, -4498, 48248, 2379, -4498, 2749, -4498, 2781, -4498, + 2781, 2781, 2756, 2756, 2759, -4498, -4498, 1017, 2781, 2756, + -4498, 59875, -4498, 1710, 1833, -4498, 3134, 3141, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, 849, -4498, 2013, + -4498, -4498, -4498, 82483, 54573, -4498, 3156, -4498, -4498, 58911, + 3044, -4498, 82483, 2945, 2760, -4498, 3076, 2806, -4498, 2812, + -4498, 82483, 1241, 2369, 2799, 82483, 2973, 82483, 82483, 82483, + 82483, -4498, -4498, 2953, 1014, 222, -4498, 72382, -4498, 1573, + 2965, 3168, -37, 1935, 3055, -4498, 82483, 2775, 3171, 3006, + -4498, -4498, 2797, 2347, -4498, 2429, -4498, 1507, -4498, 2896, + -4498, 55537, 576, -4498, -4498, -4498, -4498, 58911, 82483, 96432, + 55537, 576, 82483, 82483, 3071, 85, 3080, 2842, 3081, 2845, + 46283, 576, 90, 82483, 82483, 82483, 82483, -4498, 82483, -4498, + -4498, -4498, -4498, 82483, 82483, 82483, 72382, 3084, 3094, 576, + 82483, 82483, -4498, -4498, 23136, 1673, -4498, 14812, -4498, 13383, + 2016, 2832, -4498, 1590, 82483, 1363, 1272, 69496, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, 74306, -4498, 74306, 28, + -4498, -4498, 74306, -4498, 74306, 28, -4498, 74306, -4498, -4498, + -4498, 74306, 82483, 3293, 2803, -4498, 1242, -4498, 82483, 2024, + -4498, -4498, 2030, 1049, 82483, 82483, 600, 55537, 82483, 2990, + 82483, 82483, 82483, 82483, 82483, 2881, 2594, 928, -4498, 472, + 76230, 3002, -4498, -4498, -4498, -4498, -4498, 2064, 1630, 1137, + -4498, -4498, -4498, -4498, -4498, -4498, 69015, 67572, 3091, 105, + 82483, -4498, -4498, 3807, 31575, 27084, -4498, -4498, -4498, 2822, + 13383, 2852, 31575, -4498, -4498, 31575, 2823, 2347, 2347, 31575, + -4498, -4498, -4498, -4498, 3309, 2347, -4498, 31575, 31575, 2347, + 2347, 2781, 2781, -4498, 6209, 31575, -4498, 46283, 31575, 33072, + 24614, 31575, 2904, 2856, 2347, -4498, 2347, -4498, 31575, 26086, + -4498, 31575, 3031, 34070, 31575, 1435, 3032, 31575, 1435, 3246, + 3246, 1085, 6555, 2831, -4498, 2942, 2347, -4498, 2347, 746, + 280, 58911, 31575, 54573, 2916, 126, 82483, 31575, 2836, 1762, + -4498, 31575, 736, -4498, 2843, 31575, 2920, 31575, 31575, 31575, + 31575, 31575, 31575, 31575, 31575, 31575, -4498, 35040, 314, -4498, + 540, 1786, 69977, 27583, 3117, -4498, 24114, -4498, 198, 74306, + -4498, -4498, 424, -4498, -4498, -4498, -4498, -4498, 1962, 2839, + -4498, 2861, -4498, -4498, -4498, -4498, -4498, 82483, 2984, -4498, + -4498, 2921, -4498, -4498, -4498, -4498, 787, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, 2857, -4498, -4498, -4498, -4498, + 2857, -4498, -4498, 2832, 2860, 5737, -4498, -4498, -4498, -4498, + 3112, 3113, 576,102676, 82483, 366, 72863, -4498, 28082, -4498, + 2065, 2862, -4498, 3092, -4498, 2863, -4498, 9110, 3092, -4498, + -4498, 160, 3033, 3036, 3036, -4498, 2866, 13383, -4498, 1835, + 13383, 1852, -4498, -4498, -4498, -4498, -4498, -4498, 852, -4498, + 2907, 1307, 2908, 617, 82483, -4498, 42358, 1780, -4498, 2149, + -4498, -4498, 21067, -4498, 21552, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, 2864, -4498, -4498, -4498, -4498, 258, + 2872, 3327, -4498, 62762, -4498, -4498, -4498, 3293, -4498, 2271, + -4498, 2271, 3352, -4498, 74306, -4498, -4498, -4498, -4498, 1764, + -4498, 14812, -4498, 14812, -4498, 2878, 2096, 2937, 2938, 2991, + 82483, 82483, 82483, -4498, 54573, 82483, 82483, 82483, 82483, 82483, + 82483, -4498, 3225, -20, 67572, 2995, 66129, -4498, -4498, 2880, + 82483, 2939, 3121, 3122, 660, -4498, -4498, 96913, -4498, 3082, + 82483, 82483, 82483, 31575, 3083, 82483, 82483, 82483, 2969, 55537, + 2898, 82483, 82483, 82483, 702, 55537, 46777, 82483, 82483, 82483, + 82483, 3013, 82483, 82483, 3126, 1365, 76230, 96, 1996, 2700, + 3089, -4498, 181, -4498, 82483, 82483, 3086, -4498, -4498, -4498, + 65167, 3291, 3001, -4498, -4498,100280, -4498, -4498, 3088, -4498, + -4498, 59875, -4498, -4498, 2163, -4498, 59393, 56983, -4498, -4498, + 699, 82483, 82483, 6444, 82483, 1227, -4498, -4498, 58911, -4498, + 82483, 82483, 82483, 73344, 97394, 97875, 1294, 1356, 82483, 73825, + -4498, 82483, -4498, -4498, 55055, 82483, 82483, 54573, -4498, 82483, + 3095, 150, -4498, 82483, 5878, 2983, 82483, 82483, 2914, 2164, + 2985, 3029, -4498, 82483, 82483, 866, -4498, 82483, 82483, 10869, + -4498, -4498, 258, -4498, -4498, -4498, -4498, -4498, 82483, 82483, + 258, 82483, 258, 1419, -4498, 82483, 82483, -4498, -4498, -4498, + 6721, 82483, 82483, 82483, 82483, 82483, 82483, -4498, -4498, 1326, + 1097, 791, 1286, 3059, 82483, 2369, 82483, 98356, 82483, 82483, + 82483, 82483, 1657, -4498, -4498, 3034, -4498, 82483, 866, 6811, + 82483, 82483, 3015, 3018, 94, 3073, -4498, -4498, -4498, -4498, + -4498, -4498, 3163, 3334, 82483, -4498, 3181, 3182, 3000, 3003, + 3184, 1732, 82483, 82483, 82483, 82483, 82483, 82483, 3187, 1732, + 3135, 727, 2956, 2169, -4498, 2966, -4498, 31575, 3354, 58911, + 2967, 2968, 3038, -4498, 3041, 2347, -4498, 2117, -4498, -4498, + 2192, -4498, 2975, 1014, 1296, -4498, 82483, 902, 691, 3252, + 38464, 3079, 2427, 3249, 82483, 82483, 2427, -4498, 2548, 67572, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, 3250, + -4498, 2369, 2379, 2379, 2379, 2379, -4498, -4498, -4498, -4498, + 3159, 1816, -4498, 2972, 2379, 82483, 3093, 2427, -4498, 1573, + 3269, 3272, 82483, 64205, 1854, 3014, 2369, 3162, -4498, 25600, + 4369, 3164, 65167, 78154, -4498, 2996, 3255, 3258, 3266, -4498, + 2236, -4498, 3390, -4498, 3290, 576, 2261, -4498, 2490, -4498, + 82483, -4498, 82483, 82483, 82483, 82483, 2283, -4498, -4498, 2490, + 3179, 576, 576, -4498, 3183, 576, 2490, 3111, 3283, 65167, + -4498, 85, -4498, -4498, -4498, -4498, -4498, 31575, -4498, -4498, + 1935, 1507, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, 74306, 2271, -4498, 2203, -4498, 82483, -4498, + 3260, 3261, 3263, 2490, 3005, 3040, 82483, 3007, -4498, 2490, + 258, 2490, 2594, 2594, 2490, 3005, 79116, 3418, 3282, 75, + -4498, 629, 1082, 3218, -4498, -4498, -4498, -4498, 58911, -4498, + -4498, -4498, -4498, -4498, 82483, 134, 3194, 3016, 79116, 3395, + 576, -4498, 55537, -4498, -4498, -4498, 3102, 55537, 3205, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, 3254, 82483, 2208, -4498, + 1327, -4498, 1745, 31575, 31575, 199, -4498, 12109, 2223, 31575, + 3020, 3026, 2228, -4498, -4498, -4498, -4498, -4498, -4498, 3027, + 3305, -4498, -4498, 3039, 2234, 2238, 3042, 3046, -4498, -4498, + 5290, 3047, 12195, 3049, 33072, 33072, 1424, -4498, -4498, 33072, + 3051, -4498, 2241, 11460, 3030, 3053, 3054, -4498, 3057, 3060, + 12372, 29080, 31575, 29080, 29080, 12760, 3030, 3062, 2245, 54573, + 3195, 12633, 2248, -4498, 31575, 54573, 6167, 31575, -4498, 31575, + 82483, 3063, 3064, -4498, -4498, 6209, -4498, 3056, -4498, 33072, + 33072, -4498, 4045, 26585, -4498, -4498, 3312, -4498, -4498, 1679, + -4498, 3045, -4498, -4498, 4861, 157, 31575, 2836, 31575, 3118, + 46283, 13506, 31575, 4973, 5725, 5725, 743, 743, 135, 135, + 135, 1649, 1786, -4498, -4498, -4498, 3067, 2608, 31575, -4498, + 2341, 2345, 82483, 3494, 9046, 10021, -4498, -4498, -4498, 36523, + 3075, 31575, 31575, 31575, 3068, 3227, 3473, 13383, 859, -4498, + 3481, -4498, -4498, -4498, 239, 3352, 1962, -4498, 1624, 2347, + 746, 50674, -4498, -4498, -4498, 31575, -4498, -4498, -4498, -4498, + 2128, -4498, -4498, -4498, -4498, -4498, 1630, 31575, -4498, -4498, + 585, 1879, 31575, 1835, -4498, -4498, 82483, 3002, 3002, 31575, + -4498, -4498, -4498, -4498, -4498, 36523, 3109, 3120, 41388, 3204, + -4498, -4498, 82483, 213, -4498, -4498, -4498, 3098, -4498, -4498, + -4498, 1702, -4498, -4498, -4498, -4498, -4498, -4498, 3074, -4498, + 3077, -4498, 3099, -4498, -4498, -4498, -4498, 166, 3096, 3097, + 3100, 1572, -4498, -4498, 82483, 82483, 82483, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, 3295, -4498, 82483, + 82483, 3259, 82483, 3267, 3271, 31575, 238, 82483, 3103, 3106, + 1335, 3345, 82483, -4498, 3373, 576, -4498, -4498, 3167, -4498, + 13383, -4498, -4498, -4498, -4498, 65167, -4498, 2236, 58911, -4498, + -4498, -4498, 3127, 82483, -4498, 82483, 82483, 2283, -4498, -4498, + -4498, -4498, 981, -4498, -4498, 82483, 82483, 20, 3172, 3173, + 82483, -4498, 655, 2889, 7458, 82483, 82483, 82483, 3349, -4498, + -4498, -4498, -4498, 3297, -4498, -4498, 2013, -4498, 56983, 59393, + -4498, 59393, -4498, 2013, 1810, -4498, 2490, 3188, 2700, -4498, + 3285, 1013, -4498, -4498, -4498, -4498, -4498, 3405, 576, 3407, + 576, 82483, 82483, 82483, 82483, -4498, -4498, -4498, -4498, -4498, + 54573, 54573, 54573, 2276, -4498, -4498, 2369, -4498, -4498, -4498, + 2295, -4498, 1235, -4498, -4498, -4498, -4498, -4498, -4498, 82483, + 1953, -4498, 788, 58911, -4498, 58429, 82483, 82483, -4498, -4498, + 3335, 3278, -4498, 1809, 3284, 82483, 3180, -4498, -4498, -4498, + -4498, 3198, 2074, 2700, 1573, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, 264, 2135, 2700, 3200, -4498, 3201, -4498, + -4498, -4498, 3340, 3341, 3342, 3207, 3208, 3256, 3209, 3212, + 3262, -4498, 3214, 3268, 3216, 3273, 3221, 576, 58911, 1972, + 3257, 3440, 576, -4498, 3226, -4498, -4498, 3544, -4498, 82483, + -4498, 3230, 2145, 2700, -4498, -4498, 82483, 82483, -4498, -4498, + -4498, 1732, 58911, 3393, 1732, 1732, 82483, 82483, 1732, -4498, + -4498, -4498, 3397, 3398, 3400, 3401, 3403, 3404, 1732, -4498, + -4498, -4498, -4498, 988, 54573, -4498, 2109, -4498, 317, 43813, + 7145, 3177, 2968, 3169, 2347, 39448, 1310, 3364, 3170, -4498, + -4498, 54573, 43813, 1830, 3394, 3196, 3196, 3196, 3196, 3196, + 3196, 3196, -4498, 2396, 2403, 65167, 82483, 65167, -4498, 691, + 3285, 82483, -4498, -4498, 2309, -4498, 82483, 82483, 625, 82483, + 2347, -4498, -4498, 3253, -4498, 1935, 1241, 3315, 1645, 3515, + -4498, -4498, -4498, -4498, -4498, 82483, 82483, 1014, 2369, -4498, + 3186, 3197, -4498, 82483, 82483, 82483, 1630, 3189, 82483, 3202, + 3199, -4498, -4498, -4498, -4498, 58911, 518, 3371, 3378, 2697, + 3600, 3281, 82483, -4498, 2319, 64, -4498, 2369, 65167, 57465, + -4498, 4843, -4498, -4498, 624, 3475, -4498, 82483, -4498, -4498, + 40903, 576, 58911, 82483, -4498, 576, 85, 3264, 576, 3274, + 576, 576, 82483, -4498, -4498, 82483, -4498, 82483, 72382, 576, + -4498, 13383, 3491, -4498, -4498, -4498, -4498, 3330, 3336, 3339, + 82483, 2490, 55537, -4498, 3213, 82483, 1440, -4498, -4498, 3392, + -4498, -4498, -4498, -4498, -4498, 3518, 3519, -4498, -4498, -4498, + 82483, 68534, 98, 82483, -4498, 2236, -4498, 2261, 258, 82483, + 3456, -4498, -4498, -4498, 3229, 2325, 12686, 31575, -4498, 3529, + 58911, -4498, 7292, -4498, -4498, -4498, -4498, 31575, -4498, -4498, + -4498, -4498, -4498, 31575, -4498, 31575, 3506, -4498, 3646, 3646, + 58911, 33072, 1591, 2602, 33072, 33072, 33072, 33072, 33072, 33072, + 33072, 33072, 33072, 35539, 556, -4498, -4498, 31575, 31575, 3513, + 3506, -4498, -4498, 1341, 1341, 58911, 3232, 3030, 3234, 3235, + 31575, -4498, -4498, 2339, 34555, 3236, 54573, -4498, 31575, 11308, + 2348, 3279, 13243, 424, 7409, -4498, 3607, 2369, 31575, 1770, + 1987, 31575, 2351, 31575, 3517, -4498, -4498, -4498, 3242, -4498, + -4498, 58911, 31575, 33072, 33072, 6228, -4498, 7091, 31575, 3243, + 7428, 26585, -4498, 989, 989, 989, 989, -4498, 82483, 82483, + 82483, 36038, 79597, 3244, 1607, -4498, 79597, 80078, -4498, 3245, + 424, 31575, 3530, 631, 631, 3248, 3227, 42843, -4498, 31575, + 1181, 29579, 3265, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, 3270, -4498, + 3277, -4498, -4498, 57, 3280, -4498, -4498, 11384, 166, -4498, + 3287, -4498, 3251, -4498, 1879, -4498, -4498, -4498, 8195, 3446, + 2594, -4498, -4498, -4498, 3244, 30078, 3204, -4498, 2355, -4498, + -4498, 27583, -4498, -4498, 2381, 42358, 3109, 28082, 424, 2347, + 3288, -4498, 2271, 239, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, 3196, 2490, 2490, 1080, 2490, 3542, 1080, 8218, + -4498, -4498, 37008, 82483, 82483, -4498, 82483, 2389, 1963, 82483, + -4498, 82483, -4498, -4498, 3663, 82483, -4498, 3321, 3322, -4498, + 82483, 82483, 82483, 82483, -4498, -4498, 2226, -4498, -4498, 82483, + 82483, -4498, -4498, -4498, 273, 2327, 2700, -4498, 3346, -4498, + -4498, 3516, 1896, -4498, -4498, -4498, 3344, 82483, 3292, -4498, + 1086, 2697, 808, -4498, -4498, 3347, 82483, -4498, 82483, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, 55055, -4498, + -4498, -4498, 54573, 43813, 54573, -4498, 3363, 3365, 3413, 943, + 99, 3369, 3372, 3419, 3298, 3301, 3304, -4498, -4498, 195, + 2369, -4498, -4498, 2369, 2490, 2369, 82483, 82483, 82483, 82483, + 82483, 82483, 82483, 3587, 112, 1828, 82483, 82483, 82483, 82483, + 82483, 82483, 82483, 82483, 82483, 82483, 82483, -4498, 3667, 2369, + 2369, 3638, 3376, 82483, -4498, 82483, 2889, 82483, 82483, -4498, + -4498, -4498, 3313, 1732, -4498, -4498, 3548, 3550, -4498, 1732, + 1732, 1732, 1732, 1732, 1732, -4498, 236, 2402, -4498, 38950, + -4498, -4498, 2767, 2369, 2767, 592, -4498, 2767, -4498, 2767, + -4498, -4498, 2966, 3251, 2347, 1714, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, 2347, 1984, 3318, -4498, 40418, -4498, -4498, + -4498, 1965, 746, -4498, -4498, 82483, 3196, -4498, 2613, 2506, + 2734, 2814, 80559, 81040, 81521, 3319, 82483, 82483, 33072, -4498, + 1277, 133, -4498, 3549, 82483, 3355, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, 2760, -4498, 82483, 3285, 2490, 82483, + 82483, 2490, -4498, 58911, 3014, 759, 93546, 3353, 3323, 3605, + -4498, 3324, 3332, -4498, -4498, 82483, 3285, -21, 1926, 3370, + 66610, 1854, -4498, 3588, 64205, -4498, -4498, -4498, 3692, 3422, + -4498, 1630, 2369, 2939, -4498, 56983, 31575, 31575, -4498, 3343, + -4498, 3351, 5036, -4498, 2379, -4498, -4498, -4498, -4498, -4498, + -4498, 3421, 82483, 3762, -4498, -4498, -4498, 3348, 576, -4498, + -4498, 82483, -4498, 82483, -4498, -4498, 576, 576, -4498, 3465, + -4498, 1630, 82483, 82483, 82483, 2490, -4498, 258, -4498, 3628, + 79116, -4498, -4498, -4498, -4498, 105, 3634, -4498, -4498, 3598, + 3599, 3601, 3603, 2116, -4498, -4498, 31575, 13383, -4498, 3368, + -4498, 13383, 8502, 13383, 3513, -4498, 2558, 3647, -4498, 1091, + 3375, 2558, 1531, 1531, 295, 295, 116, 116, 116, 3646, + 556, 13383, 13383, -4498, -4498, -4498, -4498, 3381, -4498, -4498, + -4498, 3030, -4498, 32074, 3511, 3750, -4498, -4498, -4498, 3409, + 3412, 3382, -4498, 31575, 32573, 3383, 59875, -4498, -4498, 746, + 1521, 33072, 33072, 1740, -4498, 1066, 31575, 58911, 2406, 1740, + 2293, 2673, 31575, 31575, 10236, 337, 31575, 8741, 82483, 82483, + 82483, 82483, -4498, -4498, -4498, 37978, 1607, 3384, 82483, -4498, + 3387, 36523, 3621, 3563, -4498, 36523, 3563, 1992, 3563, 3629, + -4498, 43328, -4498, 3396, 24114, 1986, 13383, 3770, 3664, 31575, + 3402, -4498, 3408, 3227, -4498,100761, -4498, -4498, 13383, -4498, + -4498, 31575, -4498, 3227, 239, 455, 2369, -4498, -4498, -4498, + 46283, -4498, -4498, -4498, 3583, 13383, -4498, 1630, 82483, 424, + 488, 3414, 82483, -4498, 3204, -4498, -4498, 14812, -4498, -4498, + -4498, 195, -4498, -4498, -4498, -4498, 3478, 67572, 3681, -4498, + 31575, 2415, -4498, 3442, 3766, 307, 2420, 2439, 1963, -4498, + 3355, -4498, 1403, 3662, 252, -4498, 576, -4498, 58911, -4498, + 82483, 82483, -4498, -4498, -4498, -4498, 2651, -4498, -4498, 82483, + 82483, 82483, 82483, -4498, 3477, -4498, -4498, 54573, 2396, 3602, + -4498, -4498, 3608, 195, 82483, -4498, 58911, 576, 576, -4498, + -4498, -4498, 3429, 82483, 82483, 82483, 2347, 2347, 58911, 3415, + -4498, 2347, 2347, 3417, -4498, 82483, 82483, 82483, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, 3496, -4498, + -4498, -4498, 82483, 82483, 82483, 82483, 3715, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, 82483, -4498, + -4498, -4498, 58911, 576, 576, -4498, -4498, -4498, 3659, -4498, + 1732, 1732, -4498, -4498, -4498, -4498, -4498, -4498, -4498, 2403, + 3742, -4498, 54573, -4498, 61319, -4498, -4498, -4498, 2369, -4498, + 2369, 3616, 49212, 2369, 2369, 1963, 3431, 145, 3702, -4498, + 2158, 40418, 40418, 40418, 40418, 40418, -4498, -4498, 3707, 195, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, 31575, -4498, 1231, 2558, -4498, + -4498, -4498, -4498, 3355, 1935, 3484, 902, 3543, -4498, -4498, + 2490, 2490, 3488, 3834, 532, 82483, 3745, 3479, -4498, 2369, + -4498, -4498, 82483, 64205, 3370, 158, -4498, 2440, -4498, -4498, + -4498, 3482, 3378, 680, 3443, 1854, -4498, 1332, 82483, -4498, + 3485, 3720, 3447, -4498, 13383, 13383, 2369, 60357, 4843, -4498, + 82483, 3698, 82483, -4498, 576, -4498, 576, 576, -4498, -4498, + 82483, 2490, 2490, 2490, -4498, 3630, -4498, 576, 79116, 2116, + 2116, 2116, 2116, -4498, -4498, -4498, 13383, -4498, -4498, -4498, + 33072, 3728, -4498, 3455, 58911, -4498, 3461, 2445, 2454, 34070, + 3597, -4498, -4498, -4498, 10094, 3509, 13383, 3560, 3463, 3464, + -4498, 1212, 1212, 1066, 2458, -4498, 33072, 33072, 1740, 1740, + 31575, 1740, -4498, -4498, -4498, -4498, -4498, 79597, 3467, 82483, + 1607, 36523, -4498, -4498, 1392, -4498, 36523, 3704, -4498, 36523, + 82483, 3470, 82483, 896, 31575, 31575, 3508, 3227, 3227, -4498, + 3643, -4498, 3483, -4498, -4498, 1714, -4498, -4498, -4498, -4498, + 746, 3489, 74306, -4498, -4498, -4498, 1102, -4498, -4498, -4498, + -4498, 79116, 3660, 79116, 1963, 10209, 3355, 37008, 47271, 82483, + 82002, 82002, 3625, 3355, 3484, -4498, -4498, -4498, -4498, -4498, + -4498, 3492, -4498, -4498, -4498, 3568, -4498, -4498, -4498, 2459, + -4498, -4498, -4498, -4498, -4498, 3667, -4498, -4498, 43813, -4498, + -4498, -4498, 37493, 46283, -4498, 943, 3486, 3497, 99, -4498, + -4498, -4498, 82483, 1467, 854, 3523, 2490, 3783, -4498, 3667, + -4498, -4498, 1732, -4498, -4498, 2956, 2369, -4498, -4498, 2467, + -4498, -4498, -4498, 82483, -4498, 3323, -4498, -4498, -4498, 55537, + 3899, 3899, -4498, 1726, 1726, -4498, -4498, -4498, 82483, -4498, + -4498, 10657, 3696, -4498, 3484, 3717, 3765, -4498, 82483, 82483, + 1630, 64205, 3285, -4498, 1581, 3520, 3802, -4498, 3189, 3512, + -4498, -4498, 3845, -4498, 66610, 3694, 3422, 1031, 1031, 82483, + 3378, 3645, -4498, 3648, -4498, 1036, -4498, 82483, 37008, -4498, + 59393, -4498, 2470, -4498, -4498, 3075, 82483, 449, -4498, 3534, + -4498, -4498, -4498, -4498, -4498, -4498, 98, -4498, -4498, -4498, + -4498, 609, 33072, 58911, 2471, 31575, -4498, 31575, -4498, 3894, + -4498, -4498, -4498, 527, -4498, -4498, -4498, 1212, 1212, 1740, + -4498, 82483, 2476, -4498, 31575, 3525, -4498, -4498, 36523, 1392, + 2480, 82483, 2483, 58911, 3227, 3030, 13383, 82483, -4498, -4498, + -4498, 3905, 3703, 3227, -4498, -4498, -4498, -4498, -4498, -4498, + 1440, 1080, 98, 3766, 3484, -4498, 3531, -4498, -4498, 82483, + -4498, 1535, 1535, 82483, 3484, -4498, -4498, 82483, -4498, 54573, + 3582, -4498, 58911, 2261, 13, -4498, 58911, 58911, -4498, -4498, + 82483, 82483, 82483, 82483, 82483, 576, -4498, -4498, -4498, -4498, + 61319, 3323, 3899, 205, -4498, -4498, -4498, 1777, 3731, -4498, + 940, 3712, 3619, 3285, 3824, 3485, -4498, -4498, -4498, -4498, + 31575, 3688, 1854, 3588, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, 2497, 3422, -4498, -4498, + 3907, 3719, 3909, -4498, 2501, -4498, -4498, 5036, 60357, 3854, + -4498, 3593, 82483, -4498, -4498, 2370, 3965, -4498, 609, 2505, + -4498, 2508, 2512, 3689, 3596, -4498, 2515, -4498, 13383, 82483, + -4498, -4498, -4498, 2516, -4498, 3547, -4498, 3946, 31575, 1407, + -4498, -4498, 3828, -4498, 82002, 3594, 46283, -4498, 1879, 1879, + 1935, -4498, 1963, -4498, -4498, 31575, -4498, 2519, -4498, 884, + 3699, 3839, 2522, 2523, 3005, 3595, 3005, -4498, 2490, -4498, + -4498, -4498, -4498, -4498, 3865, 3815, -4498, -4498, -4498, -4498, + 315, -4498, 3746, 3747, 82483, -4498, 82483, 3960, -4498, 11025, + 55537, 3378, 1854, 2396, -4498, -4498, 3748, -4498, 3751, 3014, + 37008, 4843, -4498, 360, -4498, -4498, -4498, -4498, -4498, 82483, + -4498, -4498, -4498, -4498, -4498, -4498, 2529, -4498, 82483, 3569, + 3030, 30577, 30577, 3567, 79116, 1535, 3570, -4498, 3572, -4498, + -4498, 3717, 1963, 13383, 55537, 3954, -4498, -4498, -4498, 3699, + -4498, -4498, 82483, 3700, -4498, 1043, 1043, 3896, -4498, 3635, + -4498, -4498, -4498, 943, -4498, 3580, 3422, 3378, -4498, -4498, + 3422, -4498, -4498, -4498, -4498, 2214, -4498, -4498, -4498, -4498, + 33571, 3705, 595, 11918, -4498, -4498, -4498, -4498, 98, 1879, + 31575, 1963, -4498, 3712, 2261, 82483, -4498, -4498, 3479, -4498, + 3992, -4498, 659, -4498, -4498, 3415, 54091, -4498, 3422, 3075, + -4498, 1837, -4498, -4498, -4498, -4498, -4498, -4498, -4498, 3984, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, 11168, -4498, -4498, + -4498, 3880, -4498, -4498, -4498, 2533, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, 1812, -4498, -4498, 1821, 2122, 31076, -4498, + 1963, 3737, -4498, 54091, -4498, 1837, -4498, 55537, -4498, -4498, + 3589, 54091, 2536, -4498 +}; + +/* YYPGOTO[NTERM-NUM]. */ +static const yytype_int16 yypgoto[] = +{ + -4498, -4498, 3726, -4498, -1153, 184, 2278, -2107, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, 2918, + -4498, -4498, -4498, 1500, -4498, -4498, -41, -1561, 1839, 2535, + 1178, -4498, -1344, -4498, -4498, -858, 9, -1030, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -1074, 1636, 1010, 3078, + -2727, -4498, -1651, -3673, -4498, 420, -4498, -4498, 1582, -4498, + -4498, -4498, 870, -370, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -94, -4498, -4498, -543, -1807, -108, -164, -407, -4498, + -4498, 260, -412, -1683, -4498, -3502, -4498, -131, -4498, -4498, + -4498, -411, -1674, 1103, -4498, -951, -1370, 1410, -700, -4498, + -295, -4498, -750, -648, -646, -705, -539, -3692, -4101, -4271, + -2623, 1115, -4498, -136, -1801, -4498, -4498, -1735, -1678, -4498, + -716, -4498, -4498, -4498, -2966, -4498, -4498, -4498, -4498, -95, + -4498, -4498, -4498, -4498, 318, -4498, -4498, -4498, -4498, -4498, + -4498, -2759, 1551, 1552, -4498, -4498, -3175, -4498, -1156, -4498, + 464, -3002, 1030, -4498, -4498, -4498, 2229, -4498, -4498, -4498, + -4498, 320, -4498, 319, -4498, -4498, -1823, -4498, -4498, -1800, + -4498, 1563, 850, -4498, -4498, -4498, -729, -790, -781, -4498, + -3461, -4498, -4498, -4498, -4498, -4498, -1238, -4498, 903, -3113, + -1206, -4498, -4498, 915, -4498, -4498, -4498, -4498, -688, -299, + 2251, -4498, -590, -666, -4498, -4498, -4498, -293, -4498, -4498, + -4498, -4498, -4498, -4498, -1282, 11796, -1799, -4498, -4498, -4498, + -4498, -2505, -4498, -4498, -4498, -1762, -4498, 3979, 1, 167, + -1796, -4498, -200, -112, 2764, -1375, -2680, 261, -442, -4498, + -2001, -4498, -4498, -4498, -2585, -4498, -4498, -4498, -4498, -3450, + -1795, -4498, -4498, -4498, 306, -4498, -3783, -3896, -4190, -3430, + -3433, -4498, -4498, -1309, -4498, -4498, -4498, -1617, 1746, -1705, + -4498, -2352, 309, -3706, -995, -3239, -4498, -3641, -526, -4498, + -4498, -4498, -4498, -4498, -4498, -4498, -1304, -856, -4498, -4498, + 3275, -4498, -3553, -4498, -4498, -4498, -4498, 1118, -4498, -1661, + 985, -4498, -4498, -4498, -4498, -4498, -679, -758, -4498, -4498, + -4498, 152, -4498, -4498, -4498, -4498, 2000, -1190, -977, 3123, + -1794, -487, -4498, -4498, -4498, -4498, -3059, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -1378, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, 1934, 1936, -105, -213, -4498, -4498, -1476, -4498, + -812, -4498, 2176, -4498, -4498, -4498, -4498, 1250, 156, 339, + -68, -4498, -4498, 140, -3391, -63, -4498, -4498, -4498, -4498, + -406, -62, -4498, 607, -4498, -4498, -2827, -4498, 278, -56, + 2834, 1508, -71, 437, -243, -220, -206, -74, 3129, 2624, + -4498, -4498, -4498, -217, 1976, -4498, -1084, -358, -4498, 1266, + -902, 1923, 2599, 2606, -4498, 1258, -4498, -4498, 1267, -4498, + -4498, -4498, -881, 1929, -4498, 2625, 1947, -4498, 1249, 1274, + -3362, 716, -3352, 215, -971, -359, -196, 3174, 2626, -4498, + -4325, 647, -4498, -3447, -2387, -431, -2109, -1824, -4498, -4498, + -1395, 11078, -4498, -4498, -4498, 15985, 16006, -4498, -4498, 16751, + 17121, -4498, -1254, 762, 17527, 6763, -1433, -1849, -1533, 14662, + 782, 995, -2722, -4498, -4498, -4498, -330, 771, 226, -4498, + -4498, -4498, -4498, -566, -2812, -565, -4498, -4498, -4498, -564, + -4497, 2051, -4498, -804, -4498, 16127, 1309, -4498, -1350, -2757, + -2753, -1366, -1962, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -1538, -3259, -466, 1380, -4498, -4498, 1476, -4498, -4498, -4498, + -1545, -1135, -2662, 1388, -2135, -4498, -1092, 673, 2072, -1029, + 15201, 4983, 12582, -135, -2345, -1511, -1749, -4498, 345, -4498, + 1428, 2809, -154, 209, 2431, 78, -3106, -4498, -4498, 284, + -4498, -4498, -4498, 3613, 920, -4498, 2963, -4498, 1615, 2315, + -4498, -4498, 1948, -923, -75, -4498, -537, -4498, -137, -4498, + -4498, -4498, 143, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + -4498, -4498, 2636, -4498, -4498, -1457, -4498, -4498, -4498, -4498, + -4498, 3888, -292, -4498, 3317, -286, -4498, -4498, -4498, -4498, + -4498, -4498, -4498, -4498, -4498, 2645, 1978, -4498, 3114, -4498, + -4498, -4498, -36, 2867, -4498, -4498, -4498, -1186, -588, 3137, + 3138, 1940, -4498, -4498, -4498, -4498, -4498, -4498, -4498, -4498, + 1956, -4498, -4498, 1364, -2121, 1960, -4498, -4498, 686, -4498, + -4498, 240, -4498, 692, -4498, 2746, -4498, -4498, -4498, 728, + -4498, -4498, -4498, -606, 9958, 1405, 786, 173, 744, -4498, + 4758, 6770, -92, 2664, -15, 7608, 14493, 512, -4498, 3885, + 1966, 1596, -1000, -4498, 3620, 2265, 14214, -4498, -984, 21, + 83, -4498, -2, -647, -1175, 2957, -743, -1946, -4498, 4301, + -4498, -3563, -4498, -1043, 3331, -1196 +}; + +/* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If + positive, shift that token. If negative, reduce the rule which + number is the opposite. If zero, do what YYDEFACT says. + If YYTABLE_NINF, syntax error. */ +#define YYTABLE_NINF -2571 +static const yytype_int16 yytable[] = +{ + 81, 1087, 1619, 1078, 361, 1613, 2000, 356, 1961, 1028, + 351, 1063, 1545, 982, 1567, 352, 354, 906, 894, 700, + 1272, 1971, 2011, 79, 1685, 807, 2039, 1060, 2365, 1829, + 2239, 2427, 1194, 982, 1908, 1398, 1399, 1400, 2576, 1965, + 706, 1404, 890, 1926, 1768, 1790, 2718, 2568, 1854, 2067, + 712, 2685, 2127, 2078, 3229, 1303, 1816, 700, 2436, 990, + 956, 2100, 2101, 404, 1135, 943, 1003, 2437, 3392, 404, + 807, 1559, 1194, 1325, 3080, 3082, 405, 2914, 898, 905, + 2116, 2539, 405, 1097, 2445, 80, 854, 261, 905, 1098, + 2577, 361, 3875, 3528, 3641, 3823, 850, 1029, 2299, 2301, + 2302, 908, 1952, 2458, 2626, 2601, 1897, 2494, 3674, 1901, + 3676, 2602, 2603, 2934, 1905, 405, 2604, 2605, 2606, 2425, + 2252, 1910, 3132, 2771, 1139, 1194, 1784, 3187, 905, 1795, + 1928, 4051, 2503, 3780, 1081, 3583, 1668, 1821, 807, 3794, + 2239, 1089, 1360, 3380, 3523, 3524, 3780, 2507, 2508, 4006, + 3525, 900, 1670, 2143, 4088, 1090, 365, 4118, 4078, 4282, + 405, 4263, 365, 2677, 4020, 4022, 4298, 2413, 979, 2293, + 2293, 2001, 691, 1996, 4255, 1050, 3473, 3518, 2343, 1817, + 1734, 4526, 2971, 2026, 1607, 4056, 1552, 2638, 979, 4421, + 3953, 2093, 2094, 1130, 2629, 365, 3594, 3799, 3800, 3801, + 3802, 3803, 3804, 1349, 3430, 1610, 1025, 860, 1646, 1647, + 2197, 425, 1152, 1953, 1025, 1925, 1025, 2113, 1953, 2240, + 4699, 2987, 2145, 2151, 4220, 2991, 1953, 408, 405, 2514, + 329, 4622, 425, 3518, 350, 4749, 899, 2519, 2848, 1214, + 365, 2439, 916, 3208, 3866, 1068, 45, 3533, 2154, 3284, + 3534, 3535, 1173, 2182, 1298, 4677, 3637, -1493, -1493, -1493, + -1493, 3536, 3537, 3538, -1493, 3539, 3540, 425, 995, 2848, + 3541, 3542, 3543, -1850, -1850, -1850, -1850, 693, 2156, 1659, + -1850, 45, 2632, 1710, 3381, 37, 38, 39, 40, 1826, + 805, 3125, 44, 361, 1387, 1395, 356, 1429, 4272, 351, + 2843, 1848, 1660, 3642, 352, 354, 3588, 1648, 365, 2408, + -1526, -1526, -1526, -1526, 2003, 4251, 4762, -1526, 3348, 2300, + 3350, 4215, -1526, -1526, -1526, -1526, 802, 1215, 4141, -1526, + 425, 4521, 851, 1414, 4163, 805, 1126, 425, 2749, 43, + 37, 38, 39, 40, 45, 2446, 43, 44, 1435, 1661, + 2371, 45, -2569, -2569, -2569, -2569, 355, 1893, 3009, -2569, + 404, 3390, 366, 4899, 2439, 3069, 1216, -2569, 3147, 1829, + -1526, 802, 2501, 405, 4489, 2359, 261, 1603, 1554, -1744, + -135, 1842, 821, 3430, 3044, 1711, -1744, 1651, 35, -135, + 1549, 1538, 2409, 2188, -135, 404, 41, 42, 3407, 2208, + 3, 1638, 4490, 805, -2570, -2570, -2570, -2570, 405, 2439, + 1115, -2570, 3544, 2883, 1217, 1091, 4785, 1019, 2439, -2570, + 2884, 3147, 822, -363, 4142, 1019, 2623, 1019, 1140, 4687, + 3010, 4936, 1263, 1194, 4428, 2241, -1760, -1996, 1827, 802, + 2899, 2127, 909, -1760, 1605, 2361, 1396, 4252, 3070, 4424, + 4419, 4763, -1325, 365, -1536, -1536, -1536, -1536, 1954, 3242, + 4853, -1536, 2362, 1954, 1760, 4522, 2633, 2100, 2101, 130, + 131, 1954, 3126, 3382, 2116, 3638, 817, 1387, 818, 1388, + 2185, 4164, 4273, 1989, -2567, -2567, -2567, -2567, 365, 2059, + 1092, -2567, 1388, 2183, -1536, -1536, -1536, -1536, 1174, -2567, + 4835, -1536, -2566, -2566, -2566, -2566, 694, 411, 894, -2566, + 3642, -2162, -2162, -2162, -2162, 357, 1763, -2566, -2162, 329, + 1069, 2231, 2232, 350, -1325, 3065, -2162, 425, 1154, 2546, + 37, 38, 39, 40, 1098, 3209, 43, 44, 2550, 1628, + 3545, 45, 2849, 4071, 4815, 1649, 1652, 1681, -1521, -1521, + -1521, -1521, 2520, 1124, 3867, -1521, 2015, 1133, 1134, -1506, + -1506, -1506, -1506, 1828, 4922, 2729, -1506, 1111, 898, 2060, + 4131, 2515, 1388, 3493, 2082, 4887, 1403, 3780, 2624, 4889, + -1533, -1533, -1533, -1533, 821, 3546, 862, -1533, 2363, 246, + 2146, 1991, 1578, 4530, 1579, 1655, 1963, 2568, 37, 38, + 39, 40, 357, 1995, 3910, 44, 2093, 2094, -1521, 1415, + 1894, 1963, 4504, 2447, 2113, 3442, 2566, 4921, 4414, 905, + 905, 4854, -1328, 1131, 822, 2448, 2372, 2542, 2490, 811, + 2492, 3084, 1112, 1894, 2175, 2499, 1126, 1712, 2538, -1996, + 1403, 900, 2399, 2239, 3430, 355, 1203, 2913, 2502, 4370, + 2013, 366, 4259, 4374, 976, 977, 2198, 4544, 4493, 4494, + 4495, 4496, 4497, 2942, 2774, 1141, -1325, 3245, 2706, 1132, + 1181, 4271, 3611, 4408, 811, 4329, 2449, 3547, 1264, 1093, + 4846, 2730, 2364, 1077, -1744, 2099, 910, 4198, 1113, 976, + 977, 1114, 1167, 3708, -1328, 2088, 2210, 3430, 2562, 1572, + -1996, -1850, 4109, 1573, 1953, 4429, 3741, 2088, 2681, 3744, + 3745, 2280, 1078, 3748, 4034, -1996, 1425, 4734, 2885, 3585, + 1024, 3079, 2315, 3755, 1143, 2625, 899, 3654, 1024, 3655, + 1024, 1614, 2281, 1259, 2768, 2770, 3066, 4229, -1526, 2476, + 2416, -1760, 811, 1368, 3154, 2778, 4888, 819, 2060, 2782, + -1526, 3089, 976, 1637, 1387, 4695, 4701, 2794, 2795, 1662, + 1663, -1325, 1249, 2714, 4836, 911, 1300, 912, 970, 1139, + 2812, 2814, 2725, 2715, 1387, 4614, 1629, 1697, 4042, 1115, + -2569, 2828, 4624, 37, 38, 39, 40, 1313, 971, 3518, + 44, 3439, 3440, 3441, 3442, 3552, -1325, 2957, 1088, -1325, + 1702, 1405, -135, -135, 357, 404, -1493, -1947, 1572, 3877, + 1314, 1369, 1573, 1375, 405, 1380, 4901, 2689, 405, 1996, + 3558, 1384, 1163, 2696, 3432, 1876, 1126, 1580, 905, 2699, + 1163, 2151, -2570, 3000, 4714, 2973, -1328, 2973, 3383, 4913, + 3855, 2215, 2373, 1358, 1375, 1380, 2228, 2228, 2442, 2122, + 1363, 2632, 2731, 1710, 2413, 2865, 2154, 2798, 2799, 1089, + 3829, 1163, 37, 38, 39, 40, 1836, 1405, 2123, 44, + 2732, 3746, 3747, 1090, 1354, 3042, 1116, -2571, 905, -1493, + 361, 1800, 2124, 3689, 3878, 2259, 2156, 3778, 4527, 2122, + 4084, 3056, 1536, -2297, 365, 1117, 1359, 1617, 365, 2443, + 3778, 4211, 1703, 804, 4702, 1301, 948, 3273, 2123, 2472, + 3562, 1374, -2567, 1379, 1917, 1163, 4301, 1561, 4059, 1801, + 2887, 2572, 2126, 1393, 1163, 1572, 1805, 3056, 4528, 1573, + -2566, -1328, 1806, 4590, 2427, 4592, 970, 35, 4655, -2162, + 4902, 1251, 1408, 1410, 81, 41, 42, 4212, 804, 1954, + 4395, 2494, 1918, 1537, 3231, 1711, 971, 1979, 2688, 1136, + 1084, 1194, 3057, 1126, 1583, 700, -1328, 79, 1373, -1328, + 1378, 2374, 2260, 4914, 1065, -1979, -1521, 3873, 1716, 2866, + 4781, 4121, 2635, 2867, 2066, 3690, 1112, 2105, 2373, 805, + 873, 4791, -1947, 2716, 2183, 1980, 1305, 916, 3057, 1407, + 1409, 1548, 2401, 3830, 1542, 1556, 215, 4851, -1533, 4583, + 2407, 711, 4715, 3879, 4587, 4580, 804, 4589, 3140, 970, + 2868, 2457, 2722, 2723, 2572, 802, 2148, 3384, 1807, 80, + 37, 38, 39, 40, 1163, 4511, 223, 44, 4657, 971, + 1025, 1704, 1113, 2888, 1025, 2573, 2375, 875, -1947, 1577, + 3437, 3438, 3439, 3440, 3441, 3442, 1315, 2480, -1997, 3875, + 2483, 2484, 405, 37, 38, 39, 40, 1802, 3141, 1163, + 44, 3555, 1705, 3880, 233, 1184, 1185, 1186, -2297, 1187, + 1188, 1189, 1190, 1191, 1192, 1413, 236, 35, 425, 1112, + 4847, 37, 38, 39, 40, 41, 42, 43, 44, 4761, + 1919, 1706, 45, 3437, 3438, 3439, 3440, 3441, 3442, 2553, + 3060, 3021, 1837, 1430, 2666, 4440, 4850, 4122, 3142, 1562, + 2958, 3043, 1539, 2547, 3691, 1738, 1551, 1305, 1553, 3265, + 4678, 1034, 3630, 1115, -2297, 1376, 2869, 4029, 1641, 1381, + 1382, 1383, 365, 1981, 4723, 1113, 3060, 2554, 2573, 1394, + 4852, 2111, 2112, 1803, 2151, 3692, 3232, 1671, 3182, 1707, + -1979, 4732, -578, 3022, 4742, 4690, 1194, 1808, 4767, 1155, + 3631, 4879, 4136, 4691, 4783, 1082, 1699, 1176, 4679, 2154, + 1563, 882, 3249, 883, 3693, 4680, 1920, 3183, 1084, -1493, + 2922, 4738, 4739, -750, 2692, 1425, 2212, 1939, 1809, 2617, + -1493, 1641, 2099, -1493, 1689, -1493, 888, 3143, 1254, 2156, + 3660, 2186, 4681, 4825, 691, 691, -1979, 4123, 1699, 1672, + 4124, 4389, 1163, 4641, 1035, 1084, 4720, 1810, 1597, 1982, + 2574, 4393, 1163, 1083, 1770, 4407, 1115, 1289, 4189, 2172, + 2173, 2174, 2175, -1997, 4192, 4193, 4194, 4195, 4196, 4197, + 2263, 1019, 2066, 970, 1892, 1019, 37, 38, 39, 40, + 1078, 2801, 1308, 44, 2189, 1771, 2368, 4383, 4137, 2497, + 4826, 1317, 3181, 971, 2618, 855, 4042, 3652, 4768, 2710, + 4822, 1866, 4682, 4331, 3084, 4332, 3266, 1163, 4392, 3518, + 2919, -1337, -2022, 3518, 361, 2555, 2296, 1437, 1084, -1997, + 3430, 2264, 1689, -1337, 2213, 4819, 4820, -1337, 3144, 857, + 4072, 2457, 1005, 1194, 425, 2017, 3145, 2019, 3632, 3146, + 2023, 1598, 2025, 4642, 4692, 2028, 2029, 2030, 811, 1668, + 4317, 3778, 2469, 2574, -2571, 4631, 1852, 4666, 2037, 1354, + 1751, 4769, 3780, 81, 81, 1670, 81, 3345, 812, -1337, + 4880, 2062, 2575, 2063, 1163, 4138, 4871, 1946, 813, 3088, + 1963, 2297, 3351, 3530, 3267, 3531, 79, 79, 3805, 79, + -1337, 3906, 2246, 2427, 3291, 3292, 3293, 3294, 3346, 2253, + 2254, 2556, 2258, 2330, 3661, 4869, 3299, 1641, 1006, 1098, + 1290, 357, 1077, 1090, 1090, 4119, 1090, 2727, 1849, 1850, + 4594, 2598, 3531, 2543, 3633, 3153, -1337, 1947, 996, 3662, + 4333, 3808, 1085, 1892, -1337, 1139, 4881, 2298, 970, 1617, + 2551, 3172, 2066, 3405, 1305, 2532, 3165, 3173, 80, 80, + 74, 80, 951, 3178, 1963, -1847, 4906, 2359, 971, 4882, + 2711, 1163, 3924, 4683, 3341, 1291, 2470, 4930, 3254, 1305, + 2619, 952, 4065, 2360, 3559, 3203, 2533, 814, 4270, 2204, + 4249, 3653, 3385, 2620, 3179, 700, 700, 1921, 2585, 2712, + 1163, 4073, 3457, 2599, 1603, 2552, 2494, -2022, 1604, 2601, + 3432, 2238, 953, 403, 1946, 2602, 2603, 1922, 4775, 403, + 2604, 2605, 2606, 3180, 2064, 1948, 1004, 3255, 1163, 1163, + 4074, 1163, 3709, 3482, 2202, 2203, 2471, 2361, 1115, 1437, + 976, 1637, 3430, 3527, 2179, 1305, 1088, 4531, 1163, 4075, + 2205, 4250, 403, 3174, 2362, 1603, 2652, 1033, -1337, 4532, + 3047, 3386, 2367, -2022, 2691, 3899, 2016, 3433, 2143, 2018, + 4502, 1605, 2022, 1949, 2024, 3812, 4306, 2027, 4307, 1402, + 2297, 2031, 3875, 4012, 1024, 2218, 1007, 1008, 1024, 2368, + 2170, 2171, 2172, 2173, 2174, 2175, 2744, 403, 700, 1833, + 1163, 405, 1058, 3256, 3257, 4599, 4600, 1606, 1641, 1838, + 4700, 3813, 1194, 1641, 1641, 815, 4425, 3258, 2144, 1594, + 2220, 2485, 1605, 2976, 3814, 981, 2500, 2238, 2149, 1163, + 1894, 3056, 804, 1163, 1163, 1071, 2298, 2312, 2187, 2151, + 1814, 404, 404, 1572, 208, 981, 1437, 1573, 2394, 3430, + 4013, 1950, 1948, 405, 405, 405, 1403, 4744, 1606, 2221, + 1766, 1923, 3259, 873, 1937, 403, 1104, 1305, 4556, 1815, + 2217, 2219, 858, 1963, 2938, 1305, 1305, 4426, 4014, 3518, + 2363, 365, 3617, 3184, 3518, 1080, 1105, 3518, 2308, 2262, + 404, 215, 3175, 4015, 2156, 3856, 1106, 2334, 3860, 1214, + 1949, 3431, 3057, 405, 4016, 3815, 3101, 2985, 3017, 4533, + 405, 1892, 3185, 2326, 2328, 4473, 4474, 405, 2369, 3249, + 875, 223, 3432, 3176, 1025, 4084, 4017, 1115, 1659, 1773, + 2263, 3058, 1094, 365, 365, 365, 3437, 3438, 3439, 3440, + 3441, 3442, 1697, 2299, 2486, 4584, 2487, 3260, 4630, 3261, + 2844, 1660, 3177, 2939, 821, 3683, 1025, 3102, 691, 233, + -910, 4610, 3059, 4612, 1892, 1030, 4795, 2151, 3103, 1641, + 3684, 236, 4645, 3629, 2364, 1774, 805, 1641, 1950, 3433, + 1767, 2264, 3197, 365, -157, 4432, 4433, 1215, 1806, 1686, + 365, 1892, 2154, 4811, 822, 1107, 3155, 365, 4012, 4018, + 37, 38, 39, 40, 3158, 246, 3160, 44, 1699, -157, + 403, 2485, 802, 3937, 3335, 3938, 3021, 208, 4812, 3104, + 1687, 4730, 2156, 2353, 1641, 43, 1216, 1641, 1641, 3432, + 45, 4625, 2582, 2354, 1101, 357, 1214, 37, 38, 39, + 40, 2122, 1815, 1025, 44, 403, 4084, 821, 2355, 1688, + 3060, 3359, 1775, 2653, 882, 2150, 883, 1108, 2151, 3402, + 2123, 3623, 1892, 2687, 802, 4013, 425, 4106, 3614, 37, + 38, 39, 40, 4585, 1217, 43, 44, 1435, 1661, 888, + 45, 2565, 1697, 2154, 1807, 1437, 3433, 822, 3430, 2155, + 1641, 2451, 805, 4014, 2734, -386, 3518, 4089, 1776, 1892, + 1777, 3484, 2498, 3485, 2151, 3981, 2086, 2746, 4015, 2305, + 2493, 4659, 2306, 2156, 37, 38, 39, 40, 3934, 4016, + 1558, 44, 405, 1109, 1215, 3486, 2103, 1892, 802, 2154, + 3939, 8, 1363, 1796, 2486, 1019, 2487, 3643, 1779, 3909, + 3940, 4017, 3954, 1284, 3434, 3435, 3436, 3570, 3437, 3438, + 3439, 3440, 3441, 3442, 4396, 3838, 2130, 2032, 2913, 2156, + 1353, 425, 361, 1216, 1797, 3664, 4640, 1019, 1798, 1751, + 2141, 3553, 1285, 4227, 215, 1781, 3910, 2356, 1787, 1163, + 2033, 2929, 2289, 2290, 2856, 1892, 2857, 1098, 1163, 4091, + 2694, 4667, 2695, 1799, 2745, -2361, 2697, 4646, 2698, 913, + 2307, 2700, 365, 1963, 223, 2701, 2646, 2647, 2858, 1788, + 1783, 1217, 1694, 4110, 4018, 425, 1286, 2158, 2766, 4668, + 3646, 4735, 81, 3487, 361, 81, 2607, 2743, 3488, 4764, + 2740, 4741, 130, 131, 3373, 2741, 2742, 3090, 2159, 2160, + 4120, 4125, 233, 1695, 3499, 79, 3916, 208, 79, 215, + 3955, 3956, -2571, -2571, 1019, 3437, 3438, 3439, 3440, 3441, + 3442, 4092, 2439, 1986, 425, 1284, 1088, 1088, 3432, 1088, + 2444, 1136, 1696, 2913, 122, 1163, 3219, 1018, 45, 223, + 4165, 1142, 2163, 1987, 2159, 2160, 3363, 1057, 246, 951, + 1691, 2846, 126, 1153, 3836, 2164, 1194, 805, 4084, 3729, + 4166, 2859, 1437, 3245, 1789, 3430, 2860, 80, 952, 3598, + 80, 2861, 1163, 1163, 4093, 811, 4094, 233, 3920, 3730, + 1163, 1692, 3982, 1163, 2596, 3433, 3778, 1163, 2163, 236, + 2491, 2193, 2792, 802, 2194, 1163, 1163, 2944, 1286, 953, + 3961, 3819, 2627, 1163, 3489, 1697, 1163, 1163, 1163, 1163, + 1693, 4409, 1180, 3701, 3490, 3988, 1163, 1163, 823, 1163, + 4350, 1163, 1163, 246, 4868, 1163, 3563, 2459, 3243, 3296, + 1583, 1205, -1372, 3273, 3297, 4091, -1372, 859, 192, 1892, + 1163, 405, 4349, 3795, 3011, 1163, 3014, 1168, 3297, 1163, + 2427, 945, 1212, 1163, 4664, 1163, 1163, 1163, 1163, 1163, + 1163, 1163, 1163, 1163, 1997, 1163, 4280, 3622, 1998, 1997, + 2122, 1163, 1213, 2684, 1163, 2460, 2461, 2791, 4696, 3919, + 2504, 37, 38, 39, 40, 1253, 1741, 2862, 44, 2123, + 3064, 811, 1742, 3245, 1265, 2228, 1266, 2863, 1024, -1372, + 3589, 1031, 2960, 2124, 3005, 2950, 2951, 4092, 2534, 2457, + 4013, 403, 4223, 4224, 4225, 403, 215, 2459, 404, 2535, + 3760, 365, -1396, -1396, 2170, 2171, 2172, 2173, 2174, 2175, + 1024, 405, 1743, 4086, 4087, -1372, 1163, 3403, 4014, 1126, + 1256, 3404, 2238, 2536, 1273, 3432, 223, 3249, 1662, 1663, + 3434, 3435, 3436, 4376, 3437, 3438, 3439, 3440, 3441, 3442, + 4093, 3761, 4094, 2337, 4016, 2460, 2461, 404, 1258, 404, + 2170, 2171, 2172, 2173, 2174, 2175, 2289, 2969, 215, 3686, + 405, 1744, 405, 1279, 233, 3762, 2650, 2459, 1745, 2920, + 1287, 1746, 2531, 2122, 2338, 2656, 236, 3388, 3656, 2457, + 3763, 1288, 3433, 2099, 3764, 2344, 4934, 1293, 223, 4935, + 3687, 365, 2123, 3316, 3317, 1594, 805, 1024, -1325, 81, + 1641, 81, 3765, 2339, 3834, 2006, 2126, 2007, 3138, 2459, + 246, -1121, 405, 425, -1121, 2460, 2461, 3766, 1296, 3688, + 1671, 1321, 79, 1747, 79, 3456, 233, 3458, 3459, 804, + 954, 2834, 802, 1829, 2837, 3122, 3565, 3566, 236, 4018, + 365, 1163, 365, 1268, 74, 1269, 1310, 1163, 1437, 2457, + 3067, 3430, 1326, 1163, 4208, 4025, 4210, 2460, 2461, 4213, + 1335, 4214, 1176, 981, 4114, 981, 691, 981, 4356, 2099, + 1341, 2344, 955, 981, 1385, 1386, 811, 3820, 1748, 3822, + 1749, 804, 1672, 1025, 80, 4205, 80, 2459, 946, 1892, + 1750, 2457, 365, 3767, 1892, 1892, 981, 981, 1751, 1356, + 4323, 3768, 2085, 45, 246, 3563, 1892, 1752, 1397, 4030, + 4032, 35, 425, 357, 37, 38, 39, 40, 3563, 41, + 42, 44, 405, 4217, 4218, 405, 45, 1417, 3707, 4221, + 4222, 4223, 4224, 4225, 3769, 2460, 2461, 4226, 1753, 403, + 3870, 1422, 1754, 3148, 2244, 804, 2245, 3434, 3435, 3436, + 2239, 3437, 3438, 3439, 3440, 3441, 3442, 1572, 4652, -1850, + 3288, 1573, 1423, 1553, 1741, 2459, 1082, 1755, 35, 2457, + 1742, 1401, 2247, 1641, 2248, 357, 41, 42, -1373, 364, + 1424, 1641, -1373, 1641, 2913, 364, 2099, 805, 1689, 3710, + 2686, 1411, 2687, 3277, 4890, 192, 3148, 1425, 2707, 3738, + 2708, 1426, 365, 3805, 2709, 365, 2708, 2072, 2073, 3806, + 1743, 3571, 3572, 2460, 2461, 981, 1427, 1428, 364, 3807, + 3532, 4606, 1431, 802, 1083, 1756, 2459, 4557, 4558, 4559, + 4560, 3432, 1432, 1557, 1664, 1163, 2459, 1892, 2737, 2935, + 2738, 1963, 1434, 1560, 1144, -1373, 3808, 2457, 3809, 3140, + 4185, 37, 38, 39, 40, 1565, 1145, 1146, 44, 1744, + 3148, 1566, 4540, 364, 3148, 2854, 1745, 1564, 3189, 1746, + 2993, 2271, 2738, 215, 2460, 2461, 1147, 3624, 981, 1148, + 1078, -1373, 1584, 4338, 2460, 2461, 1571, 1591, 3433, 1084, + 2099, 4354, 2344, 1594, 1019, 3148, 1595, 805, 1126, 3141, + 805, 1592, 1601, 223, 3221, 1615, 4299, 1892, 2457, 1020, + 1616, 1626, 3221, 1437, 1620, 1622, 3430, 1020, 2457, 1020, + 3810, 1747, 4221, 4222, 4223, 4224, 4225, -1497, -1497, -1497, + -1497, 364, 4492, 802, -1497, 811, 802, 3077, 3134, 3078, + 3135, 233, 1630, 3237, 3278, 3238, 3508, 3509, 3510, 3142, + 804, 1627, 3921, 236, 1631, 1163, 4233, 1632, 37, 38, + 39, 40, 1633, 1634, 3290, 44, 3250, 1635, 3251, 45, + 1643, 867, 3694, 1636, 3696, 3811, 1748, 3365, 1749, 2708, + 3812, 4111, 3401, 1642, 2687, 1078, 1645, 4891, 1750, 3321, + 357, 1675, 1674, 1149, 3037, 1305, 1751, 3411, 1677, 2687, + 1176, 1689, 3415, 1085, 2687, 1752, 1892, 3463, 3419, 1683, + 2687, 1641, 3420, 3470, 2687, 3446, 3813, 2687, 2459, 3462, + 1163, 2687, 3467, 1709, 3468, 1163, 1714, 3728, 1437, 3814, + 1150, 3430, 1305, 3503, 1736, 3504, 1793, 3505, 3143, 3506, + 1754, 1163, 1163, 74, 74, 1740, 74, 1163, 4357, 873, + 3677, 3742, 3678, 3434, 3435, 3436, 1763, 3437, 3438, 3439, + 3440, 3441, 3442, 4230, 981, 1794, 2460, 2461, -904, 3681, + 1772, 3682, 1163, 1163, 1792, 3279, 364, 1163, 1765, 37, + 38, 39, 40, 3825, 1804, 3826, 44, 1813, 1818, 1163, + 1163, 1163, 1163, 3864, 1823, 3865, 3432, 405, 1824, 3925, + 2457, 2687, 1163, 405, 1825, 1163, 875, 1163, 1830, 1834, + 3815, 364, 4485, 3962, 3280, 3963, 1839, 1163, 1163, 1832, + 4280, 1163, 3972, 1756, 3973, 3984, 811, 2687, 1844, 4057, + 4478, 4058, 361, 1853, 1163, 2743, 1163, 1856, 2740, 3144, + 1163, 1846, 1697, 2741, 2742, 1898, 3287, 3145, 1900, 3563, + 3146, 1902, 1894, 3433, 3090, 4061, 1163, 4062, 1911, 37, + 38, 39, 40, 4090, -174, 2708, 44, 1163, 677, 1163, + 1163, 1163, -1504, -1504, -1504, -1504, 4201, 365, 4202, -1504, + 4355, 3887, 2738, 365, 4235, -1495, -1495, -1495, -1495, 4416, + 1915, 4417, -1495, 1163, 4422, 1913, 2708, 1024, 1927, -1498, + -1498, -1498, -1498, 1935, 837, 1163, -1498, 1943, 1951, 804, + 1163, 3432, 1641, 4423, 4523, 2708, 4524, 1163, 1956, 4566, + 1685, 4567, 1957, 1163, -1496, -1496, -1496, -1496, 4568, 1958, + 2687, -1496, 4576, 4628, 2738, 4629, 811, 1959, 4564, 811, + 882, 4649, 883, 4650, 4697, 4710, 4698, 2738, 403, 3929, + 4717, 885, 1963, 1960, 4722, 981, 3845, 4724, 1962, 3845, + 981, 981, 887, 4540, 4237, 888, 1963, 1970, 3433, 3935, + 1973, 4784, 805, 2207, 1305, 4789, 1974, 4790, 805, 4800, + 1975, 2738, 4801, 1163, 3468, 1976, 4802, 4405, 2687, 4805, + 4807, 1963, 3845, 4824, 3957, 2738, 4830, 4831, 2738, 2738, + 403, 403, 403, 4857, 4595, 1963, 1892, 4932, 802, 4933, + 4943, 1978, 4933, 4207, 802, 4375, 4475, 4378, 3434, 3435, + 3436, 1984, 3437, 3438, 3439, 3440, 3441, 3442, 1983, 1600, + 2066, 1602, 1985, 2304, 1990, 1386, 2004, 2068, 2038, 2070, + 2074, 2076, 2077, 2083, 2084, 2092, 1892, 1892, 2095, 1892, + 403, 2096, 2097, 2318, 2102, 2180, 2098, 403, 246, 2104, + 2325, 2327, 2211, 2107, 403, 2223, 2233, 3395, 1387, 2108, + 2207, 2109, 3397, 2110, 2115, 2117, 2118, 2119, 405, 405, + 405, 2120, 2121, 4651, 2807, 2128, 2243, 2129, 1305, 2131, + 2132, 2133, 2134, 2135, 2136, 2137, 2138, 2251, 2830, 1604, + 804, 1892, 1606, 1892, 2278, 2286, 2288, 2295, 1115, 2309, + 2303, 2311, 3759, 2313, 2321, 2322, 981, 2324, 2329, 2331, + 2340, -2513, 2333, 2341, 981, 2342, 2344, 2376, 2345, 2582, + 2346, 2348, 2347, 3434, 3435, 3436, 2377, 3437, 3438, 3439, + 3440, 3441, 3442, 2349, 2370, 2396, 2402, 2403, 2400, 2406, + 2439, 2441, 2404, 2405, 2431, 2432, 1892, 2451, 365, 365, + 365, 4314, 2452, 2454, 4401, 2455, 2463, 4709, 2456, 3680, + 2457, 981, 894, 3885, 981, 981, 2464, 2465, 2466, 2467, + 1892, 2473, 2481, 2474, 2477, 2488, 1751, 4712, 2516, 2478, + 2489, 2495, 2496, 2505, 2517, 2506, 3702, 2518, 2521, 2522, + 2527, 2530, 405, 2544, 2545, 3849, 3772, 1892, 2557, 2559, + 804, 2088, 2569, 804, 3519, 2560, 1194, 364, 2570, 405, + 1892, 364, 2567, 2583, 2589, 2586, 869, 2594, 1078, 2099, + 1641, 1789, 2105, 2590, 2611, 905, 4747, 981, 1078, 3884, + 4752, 4753, 2616, 1641, 2630, 2595, 2631, 2636, 2639, 2641, + 2642, 2649, 2660, 805, 805, 805, 3998, 3999, 4000, 4001, + 2141, 2662, 2664, 2663, 3221, 2678, 2665, 3221, 3221, 403, + 3519, 3221, 2643, 4505, 2854, 2679, 4478, 2703, 2720, 2704, + 2726, 3221, 365, 1892, 4609, 2735, 1852, 2774, 2748, 802, + 802, 802, 3781, 3502, 4748, 2773, 2779, 1892, 3790, 365, + 4751, 2816, 2829, 2835, 2151, 3781, 3512, 2839, 2840, 2853, + 1892, 811, 2817, 2847, 2899, 2915, 2870, 811, 1305, 2872, + 1305, 2916, 2918, 2926, 2927, 2946, 1083, 2945, 4754, 2955, + 4756, 2978, 2197, 2921, 2923, 2936, 2994, 2995, 2975, 2937, + 1163, 2644, 2949, 357, 3967, 2996, 2977, 3007, 4810, 3012, + 35, 3843, 2992, 3015, 37, 38, 39, 40, 41, 42, + 3017, 44, 3512, 3019, 3020, 1077, 3026, 3031, 3035, 3052, + 3055, 3038, 4262, 3068, 1558, 1163, 1554, 805, 1892, 3073, + 3869, 1305, 3129, 3137, 3136, 1163, 1717, 3124, 3075, 1641, + 3133, 1163, 74, 1163, 805, 74, 3186, 3199, 1892, 1163, + 3210, 3211, 1163, 1163, 1163, 1163, 1163, 1163, 1163, 1163, + 1163, 1163, 3212, 802, 3206, 1163, 1163, 3207, 1718, 3214, + 3215, 3216, 3218, 1892, 3217, 3228, 3239, 3230, 1163, 3234, + 802, 3241, 1163, 3271, 405, 3252, 1163, 3246, 3244, 3245, + 3247, 3283, 3276, 1020, 3289, 3298, 1163, 1020, 3295, 1163, + 3304, 1163, 3305, 3319, 2783, 3322, 3303, 3334, 3340, 1892, + 1163, 1163, 1163, 3337, 3338, 364, 1163, 3339, 3342, 1163, + 4686, 3343, 3352, 1719, 3357, 3358, 3355, 3367, 3368, 1163, + 3369, 1991, 3370, 3372, 3379, 2749, 3387, 3391, 4729, 1163, + 3393, 3396, 1403, 3398, 3413, 2780, 2781, 1163, 3399, 1163, + 3414, 3416, 3417, 2793, 1720, 3464, 2687, 2796, 2797, 3483, + 3452, 3521, 3478, 3418, 365, 4151, 3421, 3498, 3491, 2784, + 3422, 3424, 2818, 3427, 2819, 3445, 2066, 3451, 403, 3527, + 3979, 3453, 4617, 3529, 3454, 4909, 3461, 3476, 3477, 1721, + 3501, -950, 3526, 1163, 2841, 3575, 2842, 3577, 3581, 1163, + 3602, 3591, 3605, 3592, 3619, 1163, 3428, 3429, 3587, 3593, + 3122, 3444, 4132, 3607, 3608, 3616, 3621, 4634, 1722, 3625, + 3596, 3639, 3640, 1997, 3597, 2785, 3612, 3650, 2786, 3613, + 1163, 3651, 3658, 4040, 1194, 804, 3666, 3657, 3668, 3700, + 3699, 804, 811, 811, 811, 3703, 2318, 3706, 3705, 3711, + 3712, 3479, 3480, 3713, 3714, 3715, 3716, 3717, 3719, 805, + 3718, 3720, 1177, 3722, 3563, 3724, 3721, 1197, 403, 1194, + 3726, 3733, 3723, 3731, -2078, 3735, 1209, 3725, 2514, 3737, + 208, 3743, 2414, 2306, 1725, 3749, 3750, 4431, 3751, 3752, + 1726, 3753, 3754, 3784, 3792, 802, 405, 1727, 3783, 3796, + 405, 1892, 405, 1267, 3835, 2415, 3797, 1274, 3837, 981, + 3844, 3833, 3850, 3857, 1729, 4445, 2787, 403, 1283, 403, + -2078, 3858, 1730, 3845, 1641, 3854, 3853, 4454, 3861, 689, + 3862, 3882, -2078, 3901, 3902, 3891, -2078, 1176, 3912, 3907, + 3903, -2078, 2379, 3904, 3923, 3893, -2078, 3913, 3914, -2078, + 2085, -2078, 3928, 3448, 3430, 3447, 3958, 981, 3959, 3960, + 3966, 3974, 2145, 357, 3986, 3987, 811, 3995, 4024, 403, + 4011, 4469, 4033, 1731, 4050, 2380, 365, 1664, -2078, 74, + 365, 74, 365, 811, 4077, 4027, 3781, 4045, 2381, 4043, + 4053, 4098, 4100, 4101, 4113, 4112, 4044, 357, 4067, -2078, + 1641, 2382, 4115, 4152, 4046, 4126, 4153, 983, 4154, 4821, + 4290, 4049, 4133, 2788, 4134, 4117, 2308, 4135, 4145, 2807, + 2807, 4146, 4148, 4147, 2807, 4149, 1163, 983, 4150, 4162, + 4178, 4121, 4180, 4181, 4182, -2078, 4190, 4188, 4191, 2383, + 4219, 4253, 4245, -2078, 3874, 4265, 3221, 4266, 4268, 2708, + 3884, 1892, 3221, 3221, 3221, 3221, 3221, 3221, 4269, 4275, + 4287, 4284, 1305, 4288, 2807, 2807, 4209, 4302, 2384, 4296, + 4300, 805, 4304, 2385, 4297, 805, 3519, 805, 4310, 403, + 4315, 4318, 403, 1892, 1163, 1163, 4319, 4320, -2078, 4321, + 3790, 4322, 4327, 4339, 4330, 4340, 4341, 4412, 4334, 4342, + 4818, 4232, 4234, 4236, 4238, 4335, 4343, 802, 4367, 4347, + 4369, 802, 4371, 802, 4372, 4384, 804, 804, 804, 4382, + 4379, 4385, 4402, 2066, 4406, 2752, 4387, 4411, 4413, 4419, + 981, 4418, 4388, 996, 4427, 4438, 4441, 4410, 981, 4448, + 981, 4455, 4442, 4458, 1163, 4462, 4467, 4472, 1641, 4476, + 4483, 4491, 1194, 4488, 4498, 4506, 4508, -2078, 2141, 4509, + 677, 677, 4510, 4513, 4515, 4291, 4529, 4537, 4005, 2386, + 4538, 4525, 2753, 4546, 4535, 4562, 4554, 3519, 4563, 4570, + -2078, 1163, -2078, -2078, 4565, 4572, 4573, 4574, 4575, 4443, + 4581, 1163, 1163, 4591, 1892, 4588, 4597, 837, 811, 1163, + 1163, 2754, 4601, 4611, 1163, 1892, 4403, 4603, 4623, 4636, + 1163, 1163, 4643, 4607, 1163, -2078, 4626, 4627, -2078, -2078, + 4637, -2078, 2755, 3248, 364, 4644, 4325, 4653, 2387, 1163, + 4252, 4660, 4671, 1163, 2388, 4662, 4673, 2389, 4674, 4713, + 804, 4676, 1163, 4670, 4705, 3532, 4688, 1163, 4719, 4689, + 4728, 2756, 1084, 4745, 4736, 4770, 2757, 804, 4765, 1163, + 4774, 4776, 4780, 2390, 4786, 4787, 4788, 4793, 4794, 2391, + 4799, 4803, 4804, 4808, 4809, 4814, 364, 364, 364, 4827, + 4816, 4749, 2392, 4833, 4832, 81, 4398, 4834, 4843, 4837, + 4839, 4867, 4035, 4870, 4848, 4500, 4872, 4849, 1163, 4875, + 4878, 4835, 2758, 4886, 4836, 4900, 4912, 2393, 79, 4928, + 4931, 4937, 4941, 1096, 2528, 1739, 1892, 3286, 2230, 3556, + 3128, 3663, 4130, 3756, 3198, 4647, 364, 4760, 4477, 4519, + 3759, 4672, 4675, 364, 4286, 405, 4503, 4685, 3366, 3610, + 364, 4873, 4615, 4908, 1892, 4840, 4838, 1020, 4399, 4400, + 2150, 4884, 2066, 2151, 4782, 3615, 1892, 4256, 4520, 3269, + 3270, 3675, 4129, 2608, 4257, 4258, 3253, 3840, 981, 4911, + 80, 4942, 4938, 3771, 3793, 4885, 4635, 2593, 2154, 1020, + 837, 4829, 3728, 4876, 2155, 4638, 1000, 2058, 4731, 4292, + 2808, 4316, 4792, 3081, 4293, 3732, 4893, 4939, 4778, 2931, + 1892, 1568, 2932, 2693, 2808, 2759, 3560, 4274, 2156, 1306, + 811, 2760, 4063, 2005, 811, 365, 811, 2761, 4404, 3362, + 405, 2066, 1590, 3561, 2954, 2066, 2066, 3573, 2275, 2953, + 3569, 2948, 3586, 3936, 2274, 2249, 3941, 3942, 3943, 3944, + 3945, 3946, 3947, 3948, 3949, 3950, 2762, 4007, 2763, 3574, + 4721, 2889, 4377, 4064, 403, 4711, 2279, 1576, 3978, 3968, + 403, 2282, 4858, 1163, 4859, 2764, 1020, 3496, 4866, 3564, + 3481, 3408, 804, 3494, 4060, 2898, 1129, 3883, 3336, 1945, + 2645, 2979, 4856, 2294, 1099, 1352, 2287, 2970, 1682, 2986, + 2765, 1653, 1654, 3221, 3221, 3990, 3991, 2983, 4069, 3551, + 365, 2065, 2984, 2196, 4394, 4070, 4048, 1305, -2571, 2291, + 805, 4481, 2158, 4482, 1122, 1892, 4486, 4487, 357, 2990, + 3364, 2705, 1994, 83, 3790, 3790, 3790, 3790, 3790, 1392, + 0, 0, 0, 2159, 2160, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 364, 802, 0, 1163, -2571, + 0, 0, 1892, 0, 0, 0, 0, 1163, 357, 0, + 0, 0, 0, 0, 2318, 0, 4608, 3554, 0, 981, + 0, 0, 4517, 0, 1163, 1163, 3519, 2163, 1163, 0, + 3519, 0, 0, 0, 0, 0, 917, 0, 0, 1163, + 2164, 0, 0, 0, 1163, 805, 0, 1163, 918, 4539, + 0, 0, 1163, 1163, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 919, + 0, 0, 4325, 4325, 4325, 4325, 0, 0, 0, 0, + 1977, 802, 920, 0, 0, 1163, 4605, 0, 0, 0, + 0, 1992, 0, 0, 0, 921, 2807, 0, 0, 2807, + 2807, 2807, 2807, 2807, 2807, 2807, 2807, 2807, 2807, 4665, + 0, 0, 922, 0, 0, -2571, 1892, 0, 3512, 0, + 1163, 0, 3512, 0, 677, 0, 0, 0, 0, 3965, + 0, 0, 0, 923, 804, 0, 0, 0, 804, 1641, + 804, 0, 0, 0, 0, 0, 0, 3327, 0, 0, + 0, 924, 0, 0, 0, 0, 0, 1163, 2807, 2807, + 0, 0, 925, 0, 357, 0, 1717, 926, 0, 0, + 0, 0, 0, 927, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 403, 403, 403, 928, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1718, 0, + 0, 3781, 0, 0, 0, 0, 1163, 0, 1892, 2170, + 2171, 2172, 2173, 2174, 2175, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 3221, 0, 0, 0, 4648, + 1163, 1892, 0, 1163, 0, 1163, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1163, 1719, 364, 983, 1163, 983, 0, 983, + 4248, 1892, 0, 929, 0, 983, 0, 0, 0, 0, + 0, 0, 0, 930, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1720, 0, 0, 0, 983, 983, + 0, 837, 2526, 0, 0, 0, 0, 405, 0, 811, + 1892, 0, 0, 0, 1892, 1892, 0, 0, 0, 403, + 0, 0, 0, 3328, 0, 0, 931, 0, 4927, 1721, + 932, 0, 933, 0, 1717, 0, 403, 0, 934, 0, + 0, 935, 0, 0, 0, 0, 0, 981, 1163, 0, + 0, 0, 3785, 3788, 364, 0, 0, 0, 1722, 0, + 981, 0, 0, 0, 0, 0, 1718, 936, 0, 937, + 0, 0, 0, 938, 0, 0, 1892, 0, 0, 0, + 0, 939, 0, 4798, 0, 0, 940, 365, 3832, 0, + 0, 0, 0, 0, 811, 0, 3519, 0, 941, 0, + 2597, 3519, 0, 364, 3519, 364, 1163, 0, 0, 0, + 0, 942, 0, 1305, 0, 0, 2526, 983, 0, 0, + 208, 1719, 0, 1163, 3329, 0, 0, 0, 0, 0, + 1726, 689, 689, 0, 0, 0, 1669, 1727, 0, 0, + 0, 0, 3519, 4351, 4352, 2415, 0, 0, 0, 0, + 0, 0, 1720, 0, 1729, 364, 0, 0, 1163, 0, + 0, 361, 1730, 0, 4898, 0, 0, 4895, 1163, 0, + 0, 0, 4896, 4897, 4918, 2526, 0, 4633, 0, 0, + 983, 0, 805, 2807, 0, 0, 0, 1721, 3512, 1163, + 1163, 0, 0, 3512, 0, 0, 3512, 361, 0, 0, + 4898, 0, 1163, 4895, 0, 0, 981, 0, 4896, 4897, + 0, 0, 0, 1731, 1176, 0, 1722, 3330, 802, 0, + 0, 4918, 0, 0, 0, 0, 1020, 685, 0, 4918, + 0, 0, 703, 0, 0, 2808, 2808, 0, 1163, 0, + 2808, 361, 0, 1723, 4898, 0, 0, 4895, 1163, 0, + 0, 403, 4896, 4897, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 3519, 405, 364, 0, 0, 364, 0, + 703, 0, 0, 0, 1724, 0, 0, 0, 208, 0, + 2808, 2808, 1725, 804, 0, 0, 0, 4919, 1726, 0, + 0, 703, 0, 0, 0, 1727, 0, 0, 0, 0, + 0, 0, 0, 1728, 0, 0, 1163, 0, 0, 992, + 0, 405, 1729, 3519, 0, 1163, 0, 0, 0, 405, + 1730, 0, 993, 0, 0, 0, 2150, 357, 0, 2151, + 1001, 3327, 0, 0, 4919, 0, 0, 0, 0, 0, + 0, 0, 4919, 0, 365, 1011, 0, 992, 0, 4920, + 1717, 1032, 0, 0, 2154, 0, 2807, 2807, 0, 0, + 2155, 1062, 0, 0, 0, 0, 983, 0, 804, 1067, + 0, 1731, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1718, 0, 2156, 0, 0, 0, 0, 0, + 0, 365, 0, 0, 0, 0, 4920, 4066, 0, 365, + 0, 0, 0, 0, 4920, 3512, 0, 0, 0, 0, + 2651, 0, 0, 0, 0, 0, 0, 0, 0, 2657, + 0, 0, 0, 2661, 0, 0, 0, 0, 0, 2667, + 2668, 0, 0, 0, 0, 0, 0, 1719, 2150, 805, + 0, 2151, 0, 0, 0, 0, 3492, 2680, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 403, 0, 0, 2154, 403, 1720, 403, + 0, 0, 2155, 0, 0, 802, 0, 0, 0, 0, + 0, 0, 0, 0, -2571, 0, 805, 0, 2158, 0, + 0, 981, 4561, 0, 805, 0, 2156, 3328, 0, 0, + 0, 0, 677, 1721, 0, 4845, 0, 981, 0, 2159, + 2160, 0, 0, 0, 0, 3519, 0, 0, 4577, 4578, + 0, 811, 802, 0, 3327, -2571, 0, 0, 0, 2997, + 802, 0, 1722, 0, 3001, 0, 0, 3004, 0, 0, + 0, 0, 0, 1717, 0, 0, 0, 0, 0, 4874, + 0, 0, 0, 2163, 0, 0, 0, 983, 0, 3027, + 0, 0, 983, 983, 0, 0, 2164, 981, 0, 0, + 0, 0, 0, 0, 0, 1718, 0, 0, 0, 0, + 0, 0, 1385, 1386, 0, 0, 0, 0, 0, 0, + 0, 4216, 0, 3071, 208, 3788, 2157, 0, 1725, 0, + 2158, 0, 0, 0, 1726, 0, 4231, 0, 0, 0, + 0, 1727, 0, 0, 0, 0, 0, 0, 0, 2415, + 3085, 2159, 2160, 0, 0, 0, 0, 0, 1729, 0, + 1719, 0, 0, 0, 0, 0, 1730, 2161, 0, 0, + 364, -2571, 0, 0, 3118, 689, 364, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1720, 4940, 3139, 0, 2163, 3149, 0, 0, 0, + 0, 0, 357, 0, 0, 0, 0, 0, 2164, 0, + 0, 0, 0, 0, 3161, 0, 0, 1731, 0, 0, + 3328, 3330, 3874, 0, 3170, 0, 1721, 0, 0, 0, + 2928, 0, 0, 0, 0, 2807, 0, 3193, 4926, 0, + 0, 0, 0, 0, 4569, 981, 3200, 0, 983, 0, + 0, 0, 0, 0, 4708, 1722, 983, 0, 0, 0, + 0, 2807, 2807, 0, 0, 2170, 2171, 2172, 2173, 2174, + 2175, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 357, 2166, 0, 2150, 0, 0, 2151, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 983, 0, 2152, 983, 983, 811, 0, + 0, 703, 0, 2154, 0, 0, 0, 208, 0, 2155, + 0, 1725, 0, 0, 0, 804, 0, 1726, 0, 0, + 0, 0, 0, 0, 1727, 0, 0, 0, 0, 0, + 0, 0, 2415, 2156, 0, 0, 0, 0, 0, 0, + 0, 1729, 0, 0, 0, 811, 0, 0, 0, 1730, + 0, 0, 0, 811, 0, 0, 0, 0, 0, 983, + 0, 0, 0, 2167, 2168, 2169, 0, 2170, 2171, 2172, + 2173, 2174, 2175, 2318, 0, 0, 0, 0, 0, 0, + 0, 0, 2808, 0, 0, 2808, 2808, 2808, 2808, 2808, + 2808, 2808, 2808, 2808, 2808, 74, 0, 0, 0, 981, + 1731, 0, 0, 0, 3330, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 2808, 0, 0, 0, 0, + 0, 0, 403, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 2157, 0, 0, 0, 2158, 35, 0, + 0, 364, 364, 364, 2808, 2808, 41, 42, 0, 0, + 0, 981, 2150, 0, 0, 2151, 0, 2807, 2159, 2160, + 0, 0, 0, 0, 4452, 4453, 0, 0, 0, 4456, + 4457, 0, 2152, 0, 2161, 2153, 0, 0, 0, 0, + 2154, 0, 1159, 1165, 1165, 703, 2155, 1165, 1172, 0, + 1159, 685, 1062, 0, 1196, 0, 685, 0, 1062, 2162, + 1062, 0, 2163, 0, 1165, 685, 1062, 403, 0, 0, + 2156, 0, 0, 0, 1223, 2164, 0, 0, 2165, 1062, + 0, 1159, 0, 0, 1165, 0, 703, 0, 1165, 0, + 0, 0, 685, 0, 1196, 0, 685, 1276, 0, 0, + 0, 0, 0, 0, 1165, 0, 0, 685, 0, 3788, + 3788, 3788, 3788, 3788, 0, 0, 0, 981, 0, 0, + 0, 0, 0, 0, 0, 364, 0, 0, 0, 0, + 0, 1304, 804, 0, 0, 1159, 0, 0, 0, 0, + 703, 0, 364, 0, 1159, 0, 0, 1196, 0, 0, + 2166, 0, 0, 0, 0, 1741, 0, 0, 0, 0, + 0, 1742, 1165, 0, 0, 0, 0, 0, 0, 0, + 2157, 0, 0, 1367, 2158, 0, 0, 0, 0, 804, + 0, 0, 0, 0, 0, 0, 0, 804, 0, 0, + 0, 0, 0, 3344, 0, 2159, 2160, 0, 0, 0, + 0, 1743, 0, 0, 0, 0, 0, 0, 0, 3353, + 3354, 2161, 0, 3356, 0, 1062, 0, 0, 0, 3360, + 0, 0, 0, 0, 0, 0, 0, 1062, 1421, 0, + 0, 0, 0, 0, 0, 0, 2162, 0, 0, 2163, + 2167, 2168, 2169, 0, 2170, 2171, 2172, 2173, 2174, 2175, + 1744, 0, 2164, 0, 1528, 2165, 3423, 1745, 703, 1062, + 1746, 0, 1304, 3599, 0, 0, 0, 0, 0, 0, + 2150, 0, 0, 2151, 0, 0, 0, 1062, 0, 0, + 0, 1062, 2150, 4604, 0, 2151, 0, 0, 3394, 1528, + 0, 0, 0, 0, 0, 0, 0, 0, 2154, 1062, + 0, 0, 2152, 0, 2155, 0, 0, 0, 0, 0, + 2154, 1062, 1747, 0, 0, 0, 2155, 0, 0, 2808, + 0, 0, 0, 0, 0, 0, 0, 2166, 2156, 0, + 0, 0, 0, 0, 0, 0, 981, 0, 0, 0, + 2156, 983, 0, 0, 0, 0, 0, 0, 0, 685, + 685, 0, 0, 0, 0, 0, 0, 364, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 1748, 0, 1749, + 1319, 0, 0, 0, 1328, 0, 0, 0, 0, 1750, + 0, 0, 0, 0, 1340, 0, 0, 1751, 0, 983, + 0, 0, 1062, 689, 0, 0, 1752, 0, 3685, 0, + 1165, 1165, 0, 0, 0, 3697, 0, 0, 0, 1669, + 0, 0, 0, 0, 0, 0, 0, 2167, 2168, 2169, + 0, 2170, 2171, 2172, 2173, 2174, 2175, 1819, 2157, 0, + 0, 1754, 2158, 1741, 0, 0, 0, 0, 0, 1742, + 2157, 0, 1159, 0, 2158, 0, 0, 0, 0, 0, + 0, 0, 1159, 2159, 2160, 1196, 1820, 0, 0, 0, + 0, 0, 0, 0, 0, 2159, 2160, 0, 1165, 2161, + 0, 0, 0, 0, 0, 3739, 0, 0, 0, 1743, + 0, 2161, 1062, 0, 0, 0, 0, 0, 1165, 1165, + 0, 0, 2808, 2808, 403, 0, 0, 2163, 0, 0, + 0, 0, 1062, 1062, 1062, 1165, 2162, 1159, 0, 2163, + 2164, 1942, 0, 0, 1756, 0, 0, 0, 0, 0, + 0, 1741, 2164, 0, 0, 2165, 0, 1742, 1744, 0, + 0, 0, 0, 0, 0, 1745, 0, 0, 1746, 1165, + 1165, 1165, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1304, + 0, 0, 983, 3620, 0, 0, 0, 1743, 0, 364, + 983, 0, 983, 364, 1528, 364, 0, 0, 0, 0, + 0, 0, 0, 0, 1304, 2166, 0, 0, 0, 0, + 1747, 0, 0, 4796, 0, 0, 0, 2166, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 2041, 2041, 1744, 0, 0, 1062, + 0, 992, 0, 1745, 0, 0, 1746, 2526, 0, 0, + 0, 0, 0, 0, 0, 0, 3667, 0, 3669, 0, + 0, 0, 0, 2075, 3908, 1748, 1062, 1749, 0, 2081, + 1304, 0, 0, 0, 0, 0, 0, 1750, 0, 0, + 0, 1528, 3918, 0, 0, 1751, 0, 0, 0, 0, + 0, 0, 0, 0, 1752, 0, -2571, -2571, 1747, 2170, + 2171, 2172, 2173, 2174, 2175, 0, 0, 2167, 2168, 2169, + 1528, 2170, 2171, 2172, 2173, 2174, 2175, 0, 0, 2924, + 0, 0, 0, 0, 0, 2925, 0, 0, 0, 1754, + 0, 0, 2150, 0, 0, 2151, 0, 0, 1528, 1528, + 0, 1528, 0, 0, 0, 3727, 0, 0, 0, 0, + 3734, 0, 2152, 1748, 1755, 1749, 0, 0, 1528, 0, + 2154, 0, 0, 0, 0, 1750, 2155, 0, 0, 0, + 0, 403, 0, 1751, 2150, 0, 0, 2151, 703, 703, + 0, 0, 1752, 0, 0, 0, 0, 0, 0, 1972, + 2156, 0, 1304, 2150, 4917, 0, 2151, 0, 0, 0, + 1304, 1304, 2154, 0, 0, 0, 0, 1062, 2155, 0, + 1528, 0, 1756, 2397, 0, 0, 0, 1754, 403, 0, + 983, 2154, 0, 0, 0, 0, 403, 2155, 0, 0, + 0, 0, 2156, 0, 0, 0, 0, 0, 0, 1528, + 0, 4917, 2398, 1528, 1528, 0, 0, 0, 0, 4917, + 0, 2156, 0, 1062, 1062, 2285, 0, 0, 0, 0, + 0, 2808, 0, 0, 0, 2057, 0, 0, 0, 0, + 2808, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 2069, 703, 0, 685, 0, 0, 0, 2808, 2808, 0, + 2157, 0, 2079, 0, 2158, 0, 0, 0, 0, 3886, + 1756, 0, 0, 3889, 3890, 0, 3892, 0, 3894, 3895, + 0, 0, 0, 3992, 0, 2159, 2160, 3900, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 4107, 0, + 0, 2161, 2157, 0, 0, 1224, 2158, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 3917, -2571, 0, 0, 0, 2158, 2162, 2159, 2160, 2163, + 0, 0, 0, 0, 0, 0, 0, 0, 1225, 0, + 0, 0, 2164, 2161, 0, 2165, 2159, 2160, 1062, 2438, + 0, 1226, 1227, 0, 0, 1062, 0, 0, 1165, 0, + 1228, 0, -2571, 0, 1229, 0, 0, 0, 2162, 0, + 0, 2163, 0, 1196, 0, 4167, 0, 0, 4170, 0, + 1062, 1230, 0, 0, 2164, 0, 0, 0, 0, 1741, + 2163, 983, 0, 0, 0, 1742, 0, 0, 364, 0, + 1062, 0, 1231, 2164, 0, 0, 0, 0, 1165, 1165, + 1165, 1165, 1062, 0, 0, 0, 0, 2166, 0, 0, + 1232, 685, 0, 0, 0, 2250, 1062, 0, 0, 0, + 0, 1233, 0, 0, 0, 1743, 1234, 0, 2540, 0, + 1062, 0, 0, 0, 0, 0, 0, 0, 1165, 1165, + 0, 0, 0, 0, 1165, 0, 0, 1235, 0, 2166, + 0, 0, 0, 2808, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, -2571, 0, + 0, 0, 1236, 364, 1744, 0, 0, 0, 0, 0, + 2150, 1745, 0, 2151, 1746, 0, 0, 0, 0, 0, + 0, 1165, 0, 0, 0, 0, 0, 2167, 2168, 2169, + 2152, 2170, 2171, 2172, 2173, 2174, 2175, 0, 2154, 685, + 0, 0, 0, 3471, 2155, 1165, 1165, 1165, 1165, 0, + 0, 0, 1237, 0, 0, 685, 0, 0, 0, 0, + 0, 0, 0, 0, 2540, 0, 1747, 0, 2156, 2167, + 2168, 2169, 0, 2170, 2171, 2172, 2173, 2174, 2175, 1159, + 837, 0, 0, 0, 0, 0, 703, 0, 1159, 0, + 0, 0, 2170, 2171, 2172, 2173, 2174, 2175, 1196, 0, + 0, 0, 0, 1165, 0, 1238, 0, 0, 0, 1239, + 0, 1240, 1165, 0, 685, 0, 0, 1241, 1165, 1165, + 1242, 1748, 0, 1749, 0, 0, 0, 0, 0, 0, + 0, 0, 1062, 1750, 0, 1367, 0, 0, 0, 0, + 0, 1751, 0, 0, 0, 0, 1243, 0, 1244, 0, + 1752, 0, 1245, 0, 0, 0, 0, 0, 0, 0, + 1246, 0, 0, 0, 0, 1247, 2041, 0, 2157, 0, + 0, 0, 2158, 1165, 0, 1159, 0, 0, 0, 1062, + 1062, 3087, 1165, 0, 0, 1754, 1741, 0, 1062, 0, + 1248, 0, 1742, 2159, 2160, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 992, 992, 0, 0, 2751, 2161, + 1755, 0, 1528, 1528, 0, 0, 0, 0, 0, 0, + 1528, 0, 0, 1528, 0, 0, 0, 1528, 0, 983, + 0, 0, 1743, 0, 2162, 1528, 1528, 2163, 0, 0, + 0, 0, 983, 1528, 0, 1196, 1528, 1528, 1528, 1528, + 2164, 0, 0, 2165, 0, 0, 1528, 1528, 0, 1528, + 0, 1528, 1528, 0, 0, 1528, 0, 0, 1756, 0, + 0, 0, 0, 0, 0, 0, 1741, 0, 0, 0, + 1528, 1744, 1742, 0, 1165, 1528, 0, 0, 1745, 1528, + 0, 1746, 0, 1528, 0, 1528, 1528, 1528, 1528, 1528, + 1528, 1528, 1528, 1528, 0, 1528, 0, 0, 0, 0, + 1062, 1528, 4449, 0, 1528, 2658, 0, 0, 0, 0, + 0, 0, 1743, 0, 4459, 2166, 2669, 0, 0, 0, + 0, 0, 0, 0, 0, 1062, 4305, 0, 2676, 0, + 0, 0, 0, 1747, 4308, 4309, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1744, 1062, 0, 1062, 0, 1528, 0, 1745, 0, + 0, 1746, 0, 0, 0, 0, 0, 0, 983, 0, + 0, 0, 0, 0, 0, 0, 0, 2713, 1748, 0, + 1749, 2719, 0, 2721, 0, 0, 2724, 0, 0, 0, + 1750, 0, 2961, 0, 2968, 2167, 2168, 2169, 1751, 2170, + 2171, 2172, 2173, 2174, 2175, 0, 0, 1752, 0, 2838, + 364, 0, 0, 1747, 0, 0, 0, 0, 0, 0, + 0, 685, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 3163, 0, + 0, 0, 1754, 0, 0, 0, 0, 0, 685, 0, + 0, 0, 0, 685, 0, 0, 685, 703, 0, 0, + 0, 0, 992, 0, 992, 0, 0, 3164, 1748, 0, + 1749, 0, 0, 0, 0, 0, 0, 0, 685, 0, + 1750, 1528, 0, 0, 0, 0, 0, 1159, 1751, 1165, + 1165, 1165, 0, 1159, 1196, 0, 1165, 1752, 1165, 0, + 1165, 1165, 0, 0, 1062, 0, 0, 0, 0, 0, + 0, 0, 685, 0, 0, 0, 0, 0, 0, 824, + 0, 0, 0, 0, 4430, 1756, 2150, 0, 3201, 2151, + 0, 0, 1754, 0, 0, 0, 0, 0, 0, 685, + 0, 0, 2438, 0, 0, 0, 0, 0, 3091, 0, + 0, 0, 0, 3100, 2154, 4446, 4447, 3202, 0, 1062, + 2155, 0, 0, 685, 0, 825, 0, 0, 0, 0, + 0, 0, 0, 0, 3131, 3131, 0, 0, 826, 0, + 2150, 703, 685, 2151, 2156, 685, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 827, 1165, 0, 0, 0, + 2152, 828, 0, 685, 0, 0, 0, 0, 2154, 0, + 0, 4470, 4471, 685, 2155, 1756, 829, 0, 0, 0, + 0, 0, 3188, 0, 3190, 3192, 685, 0, 0, 0, + 0, 0, 0, 0, 830, 685, 0, 0, 2156, 0, + 0, 0, 0, 0, 0, 831, 3993, 0, 0, 0, + 832, 0, 1165, 983, 0, 0, 833, 0, 0, 0, + 1165, 1165, 1165, 1165, 1165, 1165, 0, 364, 0, 983, + 0, 834, 0, 0, 0, 1528, 0, 0, 0, 0, + 0, 0, 0, 0, -2571, 0, 0, 0, 2158, 0, + 0, 0, 0, 0, 0, 0, 835, 0, 2438, 0, + 0, 0, 3131, 1062, 0, 0, 0, 992, 0, 2159, + 2160, 0, 0, 0, 364, 0, 0, 0, 0, 0, + 0, 0, 364, 0, 0, -2571, 0, 2150, 0, 983, + 2151, 0, 4550, 3188, 4551, 4552, 0, 0, 2157, 0, + 1165, 3315, 2158, 0, 0, 4555, 836, 2152, 0, 0, + 1304, 1942, 0, 2163, 0, 2154, 0, 0, 0, 0, + 0, 2155, 0, 2159, 2160, 3086, 2164, 0, 1165, 0, + 1165, 3131, 1165, 3131, 837, 0, 0, 0, 0, 2161, + 0, 0, 0, 0, 0, 2156, 0, 1304, 0, 0, + 0, 0, 0, 0, 0, 1528, 0, 0, 0, 838, + 0, 0, 0, 0, 2162, 839, 0, 2163, 0, 0, + 0, 840, 0, 0, 841, 0, 2041, 0, 0, 0, + 2164, 0, 0, 2165, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 685, 0, 0, 0, 0, 0, + 842, -2571, 843, 0, 2150, 0, 844, 2151, 0, 0, + 0, 0, 0, 0, 845, 0, 685, 0, 0, 846, + 1159, 0, 0, 2150, 2152, 1159, 2151, 0, 0, 0, + 0, 847, 2154, 0, 0, 1165, 0, 983, 2155, 0, + 0, 1528, 1528, 0, 848, 2157, 0, 1528, 0, 2158, + 0, 2154, 0, 0, 0, 2166, 0, 2155, 0, 0, + 0, 0, 2156, 1741, 0, 0, 0, 0, 0, 1742, + 2159, 2160, 1528, 1528, 0, 0, 0, 1528, 0, 0, + 0, 2156, 0, 0, 0, 0, 2161, 0, 0, 1528, + 1528, 1528, 1528, 0, 0, 2170, 2171, 2172, 2173, 2174, + 2175, 0, 1528, 0, 0, 1528, 0, 1528, 3475, 1743, + 0, 2162, 0, 0, 2163, 0, 0, 1528, 1528, 0, + 0, 1528, 0, 0, 0, 0, 0, 2164, 0, 0, + 2165, 0, 0, 0, 1528, 0, 1528, 0, 1196, 0, + 1528, 0, 0, 3996, 4707, 2167, 2168, 2169, 0, 2170, + 2171, 2172, 2173, 2174, 2175, 0, 1528, 0, 1744, 3782, + 1062, 0, 2157, 0, 0, 1745, 2158, 3520, 1746, 1528, + 1528, 1528, 0, 0, 0, 0, 0, 0, 0, 0, + 0, -2571, 0, 0, 0, 2158, 0, 2159, 2160, 1304, + 0, 0, 0, 1528, 0, 0, 0, 0, 0, 0, + 4733, 983, 2166, 2161, 0, 1528, 2159, 2160, 0, 3371, + 1528, 0, 0, 0, 1062, 0, 0, 1528, 0, 0, + 1747, 0, -2571, 3520, 0, 0, 3580, 0, 2162, 0, + 2968, 2163, 0, 4759, 0, 810, 0, 0, 0, 0, + 0, 0, 0, 0, 2164, 0, 0, 2165, 0, 0, + 2163, 0, 0, 983, 0, 0, 0, 0, 0, 0, + 0, 0, 685, 2164, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1748, 0, 1749, 0, 0, + 810, 0, 0, 1528, 0, 3131, 0, 1750, 0, 0, + 2041, 0, 2167, 2168, 2169, 1751, 2170, 2171, 2172, 2173, + 2174, 2175, 0, 1304, 1752, 0, 3930, 0, 0, 0, + 0, 1165, 0, 1165, 1165, 0, 0, 0, 0, 2166, + 0, 0, 0, 0, 0, 0, 1023, 0, 0, 0, + 0, 0, 0, 0, 1023, 3644, 1023, 0, -2571, 1754, + 0, 0, 0, 0, 0, 0, 0, 0, 810, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 983, + 0, 0, 0, 0, 3645, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 685, 0, 0, + 0, 0, 0, 0, 685, 0, 0, 0, 0, 2167, + 2168, 2169, 0, 2170, 2171, 2172, 2173, 2174, 2175, 0, + 0, 0, 1756, 3977, 0, 0, 0, 0, 0, 0, + 0, 0, 2170, 2171, 2172, 2173, 2174, 2175, 0, 0, + 0, 0, 0, 0, 0, 0, 1741, 0, 0, 0, + 0, 0, 1742, 0, 0, 0, 4905, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 685, 0, 0, 1773, 0, 0, + 0, 0, 0, 0, 3131, 3131, 0, 0, 0, 0, + 0, 0, 1743, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 3603, 3604, 0, 3606, 0, 0, 0, 0, + 0, 0, 0, 3789, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1774, 0, 0, 0, 0, 0, 1887, + 0, 0, 0, 1304, 0, 1304, 1889, 0, 0, 1062, + 0, 1744, 0, 0, 0, 0, 0, 0, 1745, 0, + 0, 1746, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 2041, 1062, 0, 0, 0, 0, 0, + 0, 0, 1062, 0, 0, 0, 1062, 0, 983, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1062, 0, 0, 0, 0, 0, 1304, 0, 0, 0, + 1775, 0, 0, 1747, 0, 703, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1165, 0, 0, 1165, 0, 0, 685, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 3704, 0, + 1159, 0, 0, 685, 0, 0, 1776, 0, 1777, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1778, 1062, + 1749, 685, 0, 0, 0, 0, 0, 1165, 0, 0, + 1750, 0, 0, 0, 0, 1528, 0, 0, 1751, 0, + 0, 0, 0, 0, 0, 1528, 1779, 1752, 1887, 0, + 0, 1528, 0, 1528, 0, 1889, 0, 0, 0, 1528, + 0, 0, 1528, 1528, 1528, 1528, 1528, 1528, 1528, 1528, + 1528, 1528, 0, 0, 0, 1528, 1528, 0, 1780, 0, + 0, 0, 1754, 1781, 0, 0, 0, 0, 1528, 0, + 0, 0, 1528, 0, 0, 0, 1528, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1528, 1782, 0, 1528, + 0, 1528, 0, 0, 0, 0, 0, 0, 1783, 0, + 1528, 1528, 1528, 0, 0, 0, 1528, 0, 0, 1528, + 3828, 0, 3831, 0, 0, 0, 1062, 1062, 1062, 3520, + 4010, 0, 0, 0, 4010, 4023, 0, 0, 0, 1528, + 2150, 0, 0, 2151, 0, 4037, 0, 1528, 0, 1528, + 0, 0, 0, 0, 0, 1756, 0, 0, 0, 0, + 2152, 0, 0, 2150, 0, 0, 2151, 0, 2154, 0, + 0, 0, 0, 0, 2155, 0, 0, 0, 0, 0, + 2216, 0, 0, 2152, 0, 4797, 0, 0, 0, 0, + 0, 2154, 0, 1528, 0, 0, 0, 2155, 2156, 1528, + 0, 0, 0, 2968, 0, 1528, 0, 0, 0, 0, + 0, 0, 0, 3905, 0, 0, 0, 0, 0, 0, + 0, 2156, 0, 0, 0, 0, 0, 0, 0, 0, + 4085, 2041, 2041, 3915, 2540, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1165, 1165, + 1165, 1165, 0, 0, 0, 0, 0, 685, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 810, 0, 4128, 0, 0, 0, + 0, 0, 1161, 0, 0, 0, 0, 0, 2157, 0, + 1161, 0, 2158, 0, 0, 0, 1887, 0, 0, 0, + 0, 0, 0, 1889, 0, 0, 0, 0, 0, 0, + 0, 2157, 0, 2159, 2160, 2158, 0, 0, 0, 0, + 0, 1161, 0, 0, 685, 0, 0, 685, 0, 2161, + 0, 0, 0, 0, 0, 0, 2159, 2160, 0, 0, + 0, 4183, 0, 0, 0, 0, 0, 0, 0, 1887, + 0, 0, 2161, 0, 2162, 0, 2430, 2163, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 1304, 0, 0, + 2164, 0, 0, 2165, 0, 1161, 1887, 2162, 0, 0, + 2163, 0, 0, 1889, 1161, 0, 0, 0, 0, 0, + 0, 0, 0, 2164, 0, 3789, 2165, 0, 0, 0, + 0, 0, 0, 1062, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1165, 0, 1528, 0, 0, 0, + 0, 0, 1062, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 2438, 0, 0, 2150, 0, 0, + 2151, 0, 0, 0, 1062, 2166, 0, 1887, 0, 0, + 0, 0, 0, 3188, 1889, 0, 0, 2152, 4281, 0, + 0, 0, 2438, 0, 0, 2154, 1887, 0, 2166, 0, + 0, 2155, 0, 1889, 1528, 1528, 0, 0, 0, 0, + 0, 0, 0, 0, 1887, 0, 0, 0, 0, 0, + 0, 1889, 0, 0, 1161, 2156, 0, 0, 0, 3131, + 1023, 3131, 0, 0, 1023, 0, 0, 0, 0, 0, + 0, 0, 1887, 0, 0, 0, 0, 0, 685, 1889, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1161, + 0, 0, 0, 0, 1528, 2167, 2168, 2169, 0, 2170, + 2171, 2172, 2173, 2174, 2175, 0, 0, 0, 0, 4052, + 0, 0, 0, 0, 0, 0, 0, 0, 2167, 2168, + 2169, 0, 2170, 2171, 2172, 2173, 2174, 2175, 0, 0, + 1887, 1528, 4079, 0, 0, 0, 0, 1889, 0, 0, + 0, 1528, 1528, 0, 0, 0, 0, 0, 0, 1528, + 1528, 0, 0, 0, 1528, 2157, 0, 0, 0, 2158, + 1528, 1528, 0, 0, 1528, 0, 1062, 1062, 1062, 1062, + 0, 0, 0, 4010, 0, 0, 4368, 0, 0, 3520, + 2159, 2160, 0, 3520, 0, 0, 0, 0, 0, 4381, + 0, 0, 1528, 0, 0, 0, 2161, 1528, 0, 0, + 0, 0, 0, 4391, 0, 0, 0, 0, 0, 1528, + 0, 0, 0, 0, 0, 0, 0, 0, 1196, 0, + 0, 2162, 4260, 4261, 2163, 0, 3580, 0, 0, 0, + 2968, 0, 0, 0, 0, 0, 2150, 2164, 0, 2151, + 2165, 0, 1161, 0, 0, 992, 0, 0, 1528, 0, + 0, 0, 1161, 0, 0, 0, 2152, 0, 0, 0, + 0, 0, 0, 0, 2154, 0, 0, 0, 3131, 3131, + 2155, 0, 0, 0, 1890, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 4444, 0, 2156, 4311, 4312, 4313, 0, 0, + 0, 685, 0, 0, 0, 0, 0, 1161, 0, 0, + 0, 0, 2166, 685, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1887, 0, 0, 0, 0, 0, + 0, 1889, 1165, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1165, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 2910, 0, 0, 0, + 0, 0, 1304, 0, 1161, 0, 0, 0, 0, 0, + 2041, 0, 0, 0, 0, 0, 0, 0, 0, 3789, + 3789, 3789, 3789, 3789, 2157, 0, 0, 0, 2158, 0, + 0, 0, 2167, 2168, 2169, 0, 2170, 2171, 2172, 2173, + 2174, 2175, 0, 1528, 0, 0, 4328, 0, 0, 2159, + 2160, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1890, 0, 2161, 0, 0, 0, 0, + 1165, 2438, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 2162, 1161, 0, 2163, 0, 0, 0, 0, 1062, 0, + 4549, 0, 0, 0, 0, 0, 2164, 0, 0, 2165, + 0, 0, 0, 0, 0, 0, 685, 0, 0, 0, + 1161, 0, 0, 0, 0, 0, 0, 0, 1528, 0, + 0, 0, 0, 0, 0, 0, 0, 1528, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1161, 1161, + 0, 1161, 0, 0, 1528, 1528, 0, 0, 1528, 0, + 0, 0, 0, 0, 0, 4010, 0, 0, 1161, 3520, + 0, 0, 0, 0, 3520, 0, 0, 3520, 3188, 0, + 4593, 2166, 1528, 1528, 0, 4463, 4464, 0, 4466, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 685, + 0, 685, 0, 0, 0, 4085, 1196, 1165, 1165, 1165, + 1161, 810, 0, 0, 1887, 0, 0, 0, 0, 1887, + 1887, 3076, 0, 0, 0, 2150, 2430, 3083, 2151, 0, + 0, 1887, 0, 0, 0, 0, -2080, 0, 1889, 1161, + 1159, 1196, 0, 1161, 1161, 2152, 0, 0, 0, 2938, + 0, 0, 0, 2154, 0, 0, 0, 0, 0, 2155, + 0, 2167, 2168, 2169, 0, 2170, 2171, 2172, 2173, 2174, + 2175, 2041, 0, 0, 0, 4362, 0, 1159, 0, 0, + 0, 0, -2080, 2156, 0, 0, 1062, 0, 0, 0, + 0, 0, 0, 0, -2080, 0, 0, 3131, -2080, 2438, + 0, 0, 0, -2080, 0, 0, 0, 0, -2080, 0, + 0, -2080, 4281, -2080, 0, 0, 0, 1062, 0, 0, + 0, 1890, 0, 0, 0, 1165, 4085, 810, 2939, 0, + 0, 0, 0, 0, 1023, 0, 0, 0, 0, 0, + -2080, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1528, 0, 0, 1528, 0, 1528, 0, 0, 0, 0, + 0, -2080, 1887, 0, 0, 0, 1023, 0, 0, 1889, + 0, 0, 1528, 0, 1890, 0, 3520, 0, 0, 4593, + 0, 0, 0, 2157, 0, 4727, 0, 2158, 0, 0, + 0, 0, 0, 0, 0, 0, 0, -2080, 0, 0, + 0, 1890, 0, 0, 0, -2080, 0, 1165, 2159, 2160, + 0, 1062, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 2161, 0, 0, 0, 1165, 1165, + 1165, 1165, 1887, 0, 0, 0, 0, 0, 1304, 2430, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 2162, + -2080, 0, 2163, 1023, 0, 0, 0, 0, 1528, 0, + 0, 0, 0, 0, 0, 2164, 0, 0, 2165, 0, + 0, 85, 1890, 0, 0, 0, 0, 89, 0, 0, + 0, 93, 0, 94, 0, 96, 97, 0, 0, 0, + 0, 1890, 0, 0, 0, 996, 106, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1890, + 0, 0, 0, 119, 120, 0, 1528, 0, 0, -2080, + 0, 0, 1165, 0, 1196, 0, 0, 0, 0, 0, + 0, 1887, 810, 1528, 0, 0, 0, 1890, 1889, 0, + 2166, 0, -2080, 0, -2080, -2080, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, + 0, 0, 0, 0, 1165, 0, 0, 0, 1159, 129, + 0, 130, 131, 0, 0, 0, 0, -2080, 4085, 0, + -2080, -2080, 0, -2080, 0, 0, 1095, 4549, 0, 1161, + 0, 2940, 0, 0, 4716, 1890, 4727, 0, 1161, 1528, + 1528, 0, 685, 0, 4716, 0, 141, 0, 142, 143, + 0, 0, 1159, 0, 146, 0, 147, 0, 0, 0, + 1165, 0, 0, 0, 0, 0, 149, 0, 150, 0, + 2167, 2168, 2169, 0, 2170, 2171, 2172, 2173, 2174, 2175, + 0, 0, 153, 0, 154, 0, 0, 157, 1528, 0, + 0, 0, 0, 0, 0, 0, 0, 4758, 1528, 158, + 0, 159, 0, 1165, 0, 160, 0, 0, 0, 0, + 0, 161, 0, 0, 0, 0, 0, 0, 163, 0, + 165, 0, 0, 0, 0, 1161, 167, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 171, 2910, 2910, 2910, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1528, 0, 0, 0, + 0, 0, 1161, 1161, 0, 1159, 0, 0, 0, 0, + 1161, 0, 4806, 1161, 0, 0, 0, 1161, 0, 0, + 0, 0, 0, 0, 0, 1161, 1161, 0, 0, 0, + 0, 0, 0, 1161, 184, 185, 1161, 1161, 1161, 1161, + 186, 0, 0, 0, 0, 0, 1161, 1161, 187, 1161, + 0, 1161, 1161, 0, 0, 1161, 0, 0, 0, 192, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1890, + 1161, 810, 0, 0, 0, 1161, 0, 0, 0, 1161, + 0, 0, 0, 1161, 0, 1161, 1161, 1161, 1161, 1161, + 1161, 1161, 1161, 1161, 0, 1161, 203, 0, 0, 0, + 0, 1161, 0, 0, 1161, 0, 0, 205, 0, 0, + 0, 1887, 206, 0, 207, 0, 0, 0, 1889, 208, + 0, 0, 0, 0, 209, 0, 0, 211, 0, 0, + 0, 213, 0, 0, 0, 0, 214, 215, 0, 0, + 0, 0, 0, 0, 216, 0, 0, 218, 0, 0, + 0, 1887, 1887, 0, 1887, 221, 0, 0, 2430, 3083, + 0, 3083, 0, 0, 0, 0, 1161, 223, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 228, 0, 229, 0, 0, 0, + 0, 0, 0, 0, 231, 0, 0, 0, 0, 0, + 232, 0, 0, 0, 0, 233, 1887, 0, 1887, 0, + 0, 0, 0, 1889, 0, 1889, 0, 236, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 246, 0, 0, 0, -132, 0, 0, 0, 0, + 0, 1887, 810, 0, 0, 0, 0, 0, 1889, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1887, 0, 0, 0, 0, + 0, 1161, 1889, 0, 0, 0, 0, 1161, 0, 0, + 0, 0, 0, 1161, 0, 0, 0, 0, 0, 0, + 0, 0, 1887, 0, 0, 0, 0, 0, 0, 3083, + 0, 0, 0, 0, 0, 1887, 0, 0, 0, 0, + 0, 0, 3083, 1023, 0, 0, 0, 0, 0, 1890, + 0, 0, 0, 0, 1890, 1890, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1890, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 810, 0, 0, 810, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 4, 1887, 0, + 0, 0, 0, 0, 0, 1889, 0, 0, 0, 0, + 0, 0, 1887, 0, 0, 0, 0, 5, 0, 3083, + 0, 0, 0, 0, 0, 1887, 0, 6, 7, 0, + 0, 0, 1889, 8, 0, 9, 10, 0, 0, 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, 0, 36, 0, 37, 38, 39, + 40, 41, 42, 43, 44, 0, 0, 0, 45, 0, + 0, 0, 0, 0, 0, 0, 1021, 0, 0, 0, + 0, 0, 0, 1887, 1021, 1161, 1021, 1890, 0, 2150, + 1889, -2093, 2151, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1887, 0, 0, 0, 0, 0, 2152, + 1889, 0, 0, 0, 0, 0, 46, 2154, 0, 0, + 0, 0, 0, 2155, 0, 0, 0, 0, 1887, 0, + 0, 0, 0, 0, 0, 1889, 0, -2093, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 2156, 0, -2093, + 0, 0, 0, -2093, 0, 0, 0, 1890, -2093, 0, + 0, 0, 0, -2093, 1887, 0, -2093, 0, -2093, 0, + 0, 1889, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 47, 0, 0, 0, + 0, 0, 0, 0, 0, -2093, 0, 0, 0, 0, + 0, 0, 48, 0, 2150, 1161, 0, 2151, 0, 0, + 0, 2910, 0, 0, 0, 0, -2093, 0, 0, 0, + 0, 0, 49, 0, 2152, 0, 0, 0, 0, 0, + 0, 2150, 2154, 0, 2151, 0, 0, 0, 2155, 0, + 0, 0, 0, 0, 50, 0, 0, 2157, 0, 0, + 0, 2158, -2093, 0, 0, 0, 1890, 0, 0, 2154, + -2093, 0, 2156, 0, 0, 2155, 0, 0, 0, 0, + 1161, 0, 2159, 2160, 0, 1161, 0, 0, 51, 0, + 0, 52, 0, 0, 0, 0, 0, 0, 2161, 2156, + 0, 1161, 1161, 0, 0, 0, 53, 1161, 0, 0, + 0, 0, 0, 0, 0, -2093, 0, 0, 0, 0, + 0, 0, 0, 2162, 0, 0, 2163, 0, 0, 0, + 0, 0, 1161, 1161, 0, 0, 0, 1161, 0, 2164, + 0, 0, 2165, 0, 0, 0, 0, 0, 0, 1161, + 1161, 1161, 1161, 0, 0, 0, 0, 810, 0, 0, + 996, 4360, 1161, 810, 0, 1161, 1887, 1161, 0, 0, + 0, 0, 2157, 3083, 0, 0, 2158, 1161, 1161, 54, + 0, 1161, 0, 0, -2093, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1161, 0, 1161, 2159, 2160, -2571, + 1161, 0, 0, 2158, 0, 0, 0, -2093, 0, -2093, + -2093, 0, 0, 2161, 2166, 0, 1161, 0, 0, 0, + 0, 55, 0, 0, 2159, 2160, 0, 1161, 0, 1161, + 1161, 1161, 0, 0, 0, 56, 0, 0, 2162, 0, + -2571, 2163, -2093, 0, 0, -2093, -2093, 0, -2093, 0, + 57, 0, 0, 1161, 2164, 0, 0, 2165, 0, 0, + 0, 0, 0, 0, 0, 1161, 0, 0, 2163, 0, + 1161, 0, 0, 0, 0, 0, 58, 1161, 0, 0, + 0, 2164, 59, 1161, 0, 0, 60, 61, 62, 63, + 64, 0, 0, 65, 66, 67, 68, 0, 69, 70, + 71, 72, 73, 0, 2167, 2168, 2169, 0, 2170, 2171, + 2172, 2173, 2174, 2175, 0, 0, 1887, 0, 4571, 0, + 0, 0, 0, 1889, 0, 0, 0, 0, 0, 2166, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1161, 0, 0, 0, 0, 1887, 0, + 0, 0, 0, 0, 0, 2430, -2571, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1890, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1890, 1890, 0, 1890, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 2167, + 2168, 2169, 0, 2170, 2171, 2172, 2173, 2174, 2175, 0, + 0, 0, 0, 4613, 0, 0, 0, 0, 810, 810, + 810, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 2170, 2171, 2172, 2173, 2174, 2175, 0, 0, 0, 1887, + 0, 1890, 2150, 1890, 0, 2151, 1889, 0, 0, 0, + 1887, 0, 0, 0, 0, 0, 0, 1889, 0, 0, + 0, 0, 2152, 0, 0, 0, 0, 0, 0, 0, + 2154, 0, 0, 0, 0, 0, 2155, 0, 0, 0, + 0, 0, 1157, 0, 0, 0, 0, 0, 0, 0, + 1157, 0, 0, 0, 2910, 0, 1890, 0, 0, 2910, + 2156, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 2910, 0, 0, 0, 0, 0, 0, 0, 0, + 1890, 1157, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 810, 0, 0, 0, 0, 1890, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 810, + 1890, 1887, 0, 0, 0, 0, 0, 0, 1889, 0, + 0, 0, 0, 0, 0, 1157, 0, 0, 0, 0, + 0, 0, 0, 0, 1157, 0, 0, 0, 0, 1887, + 0, 0, 0, 0, 0, 0, 1889, 0, 0, 0, + 2157, 1887, 0, 0, 2158, 0, 0, 0, 1889, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1890, 0, 2159, 2160, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 1890, 0, 0, + 0, 2161, 0, 0, 0, 1887, 0, 0, 0, 0, + 1890, 0, 1889, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1741, 0, 2162, 0, 0, 2163, + 1742, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1161, 0, 2164, 0, 0, 2165, 0, 0, 0, 0, + 0, 0, 0, 0, 1157, 1773, 0, 0, 0, 0, + 1021, 0, 0, 0, 1021, 0, 0, 0, 0, 0, + 1743, 0, 0, 0, 0, 1161, 0, 0, 1890, 0, + 0, 0, 0, 0, 0, 1161, 0, 0, 0, 1157, + 0, 1161, 0, 1161, 0, 0, 0, 0, 1890, 1161, + 0, 1774, 1161, 1161, 1161, 1161, 1161, 1161, 1161, 1161, + 1161, 1161, 0, 0, 0, 1161, 1161, 2166, 0, 1744, + 0, 0, 0, 1890, 0, 0, 1745, 4543, 1161, 1746, + 0, 0, 1161, 0, 810, 0, 1161, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1161, 0, 0, 1161, + 0, 1161, 0, 0, 0, 0, 0, 1887, 0, 1890, + 1161, 1161, 1161, 0, 1889, 0, 1161, 0, 0, 1161, + 2150, 0, 0, 2151, 0, 0, 0, 0, 1775, 1161, + 0, 1747, 0, 0, 0, 0, 0, 0, 0, 1161, + 2152, 0, 0, 0, 0, 0, 0, 1161, 2154, 1161, + 0, 0, 0, 0, 2155, 0, 0, 2167, 2168, 2169, + 0, 2170, 2171, 2172, 2173, 2174, 2175, 0, 0, 0, + 0, 4658, 0, 0, 1776, 0, 1777, 0, 2156, 0, + 0, 0, 0, 0, 0, 0, 1778, 0, 1749, 0, + 0, 0, 1157, 1161, 0, 0, 0, 0, 1750, 1161, + 0, 0, 1157, 0, 0, 1161, 1751, 0, 0, 0, + 0, 0, 0, 0, 1779, 1752, 0, 0, 0, 0, + 0, 1887, 0, 0, 1888, 0, 0, 0, 3083, 0, + 1161, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 3151, 0, 0, 0, + 1754, 1781, 0, 0, 0, 0, 0, 1157, 0, 0, + 0, 0, 0, 2150, 0, 0, 2151, 0, 0, 0, + 0, 0, 0, 0, 0, 3152, 0, 0, 2157, 0, + 0, 0, 2158, 2152, 0, 0, 1783, 0, 0, 0, + 0, 2154, 0, 0, 0, 0, 810, 2155, 0, 0, + 810, 1890, 810, 2159, 2160, 0, 0, 0, 0, 0, + 0, 0, 0, 1887, 0, 0, 0, 0, 0, 2161, + 3083, 2156, 0, 0, 1157, 0, 0, 0, 0, 0, + 0, 0, 0, 1756, 0, 0, 1887, 0, 0, 0, + 0, 0, 0, 1889, 2162, 0, 0, 2163, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 2164, 0, 0, 2165, 0, 0, 1887, 0, 0, 0, + 0, 0, 0, 1889, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1888, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 2150, 0, 1887, 2151, 0, 0, 1887, + 1887, 1157, 1889, 0, 0, 0, 1889, 1889, 0, 0, + 0, 2157, 0, 2152, 0, 2158, 1161, 0, 0, 0, + 0, 2154, 0, 0, 0, 2166, 0, 2155, 0, 0, + 1157, 0, 0, 0, 0, 0, 2159, 2160, 0, 0, + 0, 1890, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 2156, 2161, 0, 0, 0, 0, 0, 1157, 1157, + 0, 1157, 0, 0, 0, 0, 0, 0, 4543, 2150, + 0, 0, 2151, 1890, 1161, 1161, 0, 2162, 1157, 0, + 2163, 0, 0, 0, 0, 0, 0, 0, 0, 2152, + 0, 0, 0, 2164, 0, 0, 2165, 2154, 0, 0, + 0, 0, 0, 2155, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 2167, 2168, 2169, 0, 2170, + 2171, 2172, 2173, 2174, 2175, 0, 0, 2156, 0, 4844, + 1157, 0, 0, 0, 1161, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 2150, 0, 0, 2151, 0, + 0, 2157, 0, 0, 0, 2158, 0, 0, 0, 1157, + 0, 0, 0, 1157, 1157, 2152, 0, 0, 2166, 0, + 0, 1161, 0, 2154, 0, 0, 2159, 2160, 0, 2155, + 0, 1161, 1161, 0, 1890, 0, 0, 0, 0, 1161, + 1161, 0, 2161, 0, 1161, 1890, 0, 0, 0, 0, + 1161, 1161, 0, 2156, 1161, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 2162, 0, 1161, + 2163, 0, 0, 1161, 0, 0, 0, 2157, 0, 0, + 0, 2158, 1161, 2164, 0, 0, 2165, 1161, 0, 0, + 0, 1888, 0, 0, 0, 0, 0, 0, 0, 1161, + 0, 0, 2159, 2160, 1021, 3969, 0, 0, 2167, 2168, + 2169, 0, 2170, 2171, 2172, 2173, 2174, 2175, 2161, 0, + 0, 0, 4929, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 3447, 0, 0, 0, 1021, 3448, 1161, 0, + 0, 0, 0, 2162, 1888, 0, 2163, 0, 0, 0, + 0, 0, 0, 2157, 0, 0, 1890, 2158, 2166, 2164, + 0, 0, 2165, 0, 0, 0, 0, 0, 0, 0, + 0, 1888, 3970, 0, 0, 810, 0, 0, 2159, 2160, + 0, 0, 0, 0, 1890, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 2161, 0, 1890, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 2162, + 0, 0, 2163, 1021, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 2166, 2164, 0, 0, 2165, 0, + 1890, 0, 1888, 0, 0, 0, 0, 0, 2167, 2168, + 2169, 0, 2170, 2171, 2172, 2173, 2174, 2175, 0, 0, + 810, 1888, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1888, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1161, 0, 0, 0, 1888, 0, 0, + 2166, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 2167, 2168, 2169, 0, 2170, 2171, + 2172, 2173, 2174, 2175, 0, 0, 4047, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1890, 0, 0, 0, 1157, + 0, 0, 0, 0, 0, 1888, 0, 0, 1157, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1161, 0, + 0, 0, 1890, 0, 0, 0, 0, 1161, 0, 0, + 2167, 2168, 2169, 0, 2170, 2171, 2172, 2173, 2174, 2175, + 0, 0, 0, 0, 1161, 1161, 0, 0, 1161, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1161, + 0, 0, 0, 0, 1161, 0, 0, 1161, 0, 0, + 0, 0, 1161, 1161, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 2150, 0, 1157, 2151, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 2152, 0, 1161, 0, 0, 0, 0, + 0, 2154, 0, 0, 0, 0, 0, 2155, 0, 0, + 0, 0, 1157, 1157, 0, 0, 0, 0, 0, 0, + 1157, 0, 0, 1157, 0, 0, 1890, 1157, 0, 0, + 1161, 2156, 0, 0, 0, 1157, 1157, 0, 0, 0, + 0, 0, 0, 1157, 0, 0, 1157, 1157, 1157, 1157, + 0, 0, 0, 0, 0, 0, 1157, 1157, 0, 1157, + 0, 1157, 1157, 0, 0, 1157, 0, 1161, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1888, + 1157, 0, 0, 0, 0, 1157, 0, 0, 0, 1157, + 0, 0, 0, 1157, 0, 1157, 1157, 1157, 1157, 1157, + 1157, 1157, 1157, 1157, 0, 1157, 0, 0, 0, 4903, + 0, 1157, 0, 0, 1157, 0, 1161, 0, 1890, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 2157, 0, 0, 0, 2158, 0, 0, 0, 0, + 1161, 1890, 0, 1161, 0, 1161, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 2159, 2160, 0, 0, + 0, 0, 1161, 0, 2150, 0, 1161, 2151, 0, 0, + 0, 1890, 2161, 0, 0, 0, 1157, 0, 0, 0, + 0, 0, 0, 0, 2152, 0, 0, 3410, 0, 0, + 0, 0, 2154, 0, 0, 0, 0, 2162, 2155, 0, + 2163, 0, 0, 0, 0, 0, 0, 810, 0, 0, + 1890, 0, 0, 2164, 1890, 1890, 2165, 0, 0, 0, + 0, 0, 2156, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 4904, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1161, 0, + 2150, 0, 0, 2151, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 2152, 0, 0, 0, 0, 0, 1890, 0, 2154, 0, + 0, 0, 0, 0, 2155, 0, 0, 0, 2166, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1157, 0, 0, 1879, 0, 1161, 1157, 2156, 0, + 0, 0, 0, 1157, 0, 0, 0, 0, 0, 0, + 0, 0, 2157, 1161, 0, 0, 2158, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1021, 0, 0, 0, 2159, 2160, 1888, + 0, 0, 0, 0, 1888, 1888, 0, 0, 1161, 0, + 0, 0, 0, 2161, 0, 0, 1888, 0, 1161, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 2167, 2168, + 2169, 0, 2170, 2171, 2172, 2173, 2174, 2175, 2162, 1161, + 1161, 2163, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1161, 0, 2164, 0, 0, 2165, 2157, 0, + 0, 0, 2158, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 2150, 0, 0, + 2151, 0, 0, 2159, 2160, 0, 0, 0, 1161, 0, + 0, 0, 0, 0, 0, 0, 0, 2152, 1161, 2161, + 3455, 0, 0, 0, 0, 2154, 0, 0, 0, 0, + 0, 2155, 0, 1879, 810, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 2162, 0, 0, 2163, 0, 2166, + 0, 0, 0, 0, 0, 2156, 0, 0, 0, 0, + 2164, 0, 0, 2165, 0, 1157, 0, 1888, 0, 0, + 0, 0, 0, 0, 0, 0, 1161, 3425, 0, 0, + 0, 810, 0, 0, 0, 1161, 0, 0, 0, 810, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 2166, 0, 1888, 0, 2167, + 2168, 2169, 0, 2170, 2171, 2172, 2173, 2174, 2175, 0, + 0, 0, 0, 0, 0, 2157, 0, 0, 0, 2158, + 0, 1164, 1166, 0, 0, 1169, 1170, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 2159, 2160, 1207, 0, 0, 1157, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 2161, 0, 0, 0, + 0, 0, 1257, 0, 0, 0, 1260, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 707, 0, + 0, 2162, 1281, 0, 2163, 2167, 2168, 2169, 707, 2170, + 2171, 2172, 2173, 2174, 2175, 0, 1888, 2164, 0, 0, + 2165, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1157, 0, 0, 0, 0, 1157, 0, 0, 2150, 0, + 0, 2151, 0, 0, 707, 0, 0, 0, 0, 0, + 0, 1157, 1157, 0, 0, 0, 904, 1157, 2152, 707, + 0, 3466, 0, 0, 0, 904, 2154, 0, 0, 707, + 0, 0, 2155, 0, 0, 0, 0, 0, 0, 0, + 0, 1879, 1157, 1157, 0, 0, 0, 1157, 0, 707, + 0, 2150, 2166, 0, 2151, 0, 2156, 0, 0, 1157, + 1157, 1157, 1157, 0, 0, 904, 0, 0, 0, 0, + 0, 2152, 1157, 0, 0, 1157, 0, 1157, 0, 2154, + 0, 0, 0, 0, 0, 2155, 0, 1157, 1157, 0, + 0, 1157, 0, 0, 1879, 0, 0, 0, 1076, 0, + 0, 0, 0, 0, 1157, 0, 1157, 0, 0, 2156, + 1157, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1879, 0, 0, 0, 2150, 1157, 0, 2151, 0, + 0, 0, 0, 0, 0, 0, 0, 1157, 0, 1157, + 1157, 1157, 2167, 2168, 2169, 2152, 2170, 2171, 2172, 2173, + 2174, 2175, 0, 2154, 0, 0, 2157, 0, 0, 2155, + 2158, 0, 0, 1157, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1157, 0, 0, 0, 0, + 1157, 2159, 2160, 2156, 0, 0, 0, 1157, 0, 0, + 0, 0, 1879, 1157, 0, 0, 0, 2161, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 2157, + 0, 1879, 0, 2158, 0, 0, 0, 0, 0, 0, + 0, 0, 2162, 0, 0, 2163, 0, 0, 0, 1879, + 0, 0, 0, 0, 2159, 2160, 0, 0, 2164, 0, + 0, 2165, 0, 0, 0, 0, 0, 0, 0, 0, + 2161, 0, 0, 1157, 0, 0, 0, 1879, 1761, 1762, + 0, 0, 0, 0, 0, 0, 0, 3460, 0, 0, + 0, 0, 0, 1125, 0, 2162, 1888, 0, 2163, 0, + 0, 0, 0, 2157, 0, 0, 0, 2158, 0, 0, + 0, 2164, 0, 0, 2165, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 2159, 2160, + 0, 0, 0, 2166, 0, 1879, 1888, 1888, 0, 1888, + 0, 0, 0, 0, 2161, 0, 1847, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1906, 1907, 0, 2162, + 0, 0, 2163, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1934, 0, 2164, 2166, 0, 2165, 0, + 0, 1888, 0, 1888, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 3926, 0, 0, 0, 0, 0, 1967, 1969, + 0, 0, 0, 2167, 2168, 2169, 0, 2170, 2171, 2172, + 2173, 2174, 2175, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1888, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 2166, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1888, 0, 0, 0, 0, 0, 2167, 2168, 2169, 0, + 2170, 2171, 2172, 2173, 2174, 2175, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 1888, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1888, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1879, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 2167, 2168, 2169, 0, 2170, 2171, 2172, 2173, 2174, 2175, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1888, 0, 0, 904, 904, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 1888, 0, 0, + 0, 0, 0, 1125, 0, 0, 0, 0, 0, 0, + 1888, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 2150, 0, + 1157, 2151, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 2152, 0, + 0, 3976, 0, 0, 0, 0, 2154, 0, 0, 0, + 0, 0, 2155, 0, 0, 1157, 0, 0, 1888, 0, + 0, 0, 0, 0, 0, 1157, 0, 0, 0, 0, + 0, 1157, 0, 1157, 0, 0, 2156, 0, 1888, 1157, + 0, 0, 1157, 1157, 1157, 1157, 1157, 1157, 1157, 1157, + 1157, 1157, 0, 0, 0, 1157, 1157, 0, 0, 0, + 0, 0, 1171, 1888, 0, 0, 0, 0, 1157, 0, + 0, 1198, 1157, 1201, 0, 1204, 1157, 1206, 0, 0, + 0, 0, 0, 0, 0, 0, 1157, 0, 0, 1157, + 0, 1157, 0, 0, 0, 0, 1255, 0, 0, 1888, + 1157, 1157, 1157, 1262, 0, 0, 1157, 0, 0, 1157, + 0, 0, 1277, 1278, 0, 0, 0, 1280, 2150, 1157, + 0, 2151, 0, 0, 0, 0, 0, 0, 0, 1157, + 0, 0, 0, 1125, 0, 904, 2157, 1157, 2152, 1157, + 2158, 0, 0, 0, 0, 0, 2154, 0, 0, 1879, + 1309, 0, 2155, 0, 1879, 1879, 0, 0, 0, 0, + 0, 2159, 2160, 0, 1330, 0, 1879, 1332, 0, 1334, + 0, 1337, 0, 0, 0, 0, 2156, 2161, 0, 0, + 0, 0, 0, 1157, 707, 904, 0, 0, 0, 1157, + 0, 0, 0, 0, 0, 1157, 2453, 0, 0, 707, + 0, 707, 2162, 0, 0, 2163, 0, 0, 0, 0, + 0, 707, 0, 0, 0, 0, 0, 0, 2164, 0, + 1157, 2165, 0, 0, 0, 0, 0, 0, 0, 0, + 707, 707, 0, 0, 0, 0, 0, 1418, 0, 1419, + 0, 2150, 0, 0, 2151, 0, 2509, 2510, 2511, 2512, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 2152, 0, 0, 0, 0, 0, 0, 0, 2154, + 1125, 0, 0, 0, 0, 2155, 2157, 0, 0, 0, + 2158, 0, 0, 0, 0, 0, 2548, 2549, 0, 0, + 0, 1888, 2558, 2166, 0, 0, 0, 1879, 0, 2156, + 0, 2159, 2160, 0, 0, 1076, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 2161, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 2579, + 0, 0, 2162, 0, 0, 2163, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 2164, 0, + 0, 2165, 0, 2612, 2613, 2614, 2615, 1879, 0, 0, + 0, 0, 0, 0, 0, 0, 1676, 0, 1678, 0, + 0, 0, 1680, 2167, 2168, 2169, 0, 2170, 2171, 2172, + 2173, 2174, 2175, 0, 0, 0, 0, 0, 0, 2157, + 0, 0, 0, 2158, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1157, 0, 0, 0, + 0, 2671, 0, 0, 2159, 2160, 0, 0, 0, 0, + 2675, 0, 0, 2166, 0, 0, 0, 2682, 0, 0, + 2161, 1888, 0, 0, 1822, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1835, 0, 0, 0, 0, 2162, 1879, 0, 2163, 0, + 0, 1843, 0, 1888, 1157, 1157, 0, 0, 1845, 0, + 0, 2164, 0, 0, 0, 0, 0, 0, 0, 0, + 1896, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1938, 2167, 2168, 2169, 0, 2170, 2171, 2172, + 2173, 2174, 2175, 0, 1157, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 2166, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1157, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1157, 1157, 0, 1888, 0, 0, 0, 0, 1157, + 1157, 0, 0, 0, 1157, 1888, 0, 0, 0, 0, + 1157, 1157, 2851, 707, 1157, 707, 0, 0, 707, 0, + 707, 0, 0, 707, 707, 707, 0, 0, 0, 1157, + 0, 0, 0, 1157, 0, 0, 707, 0, 0, 0, + 0, 0, 1157, 0, 0, 0, 0, 1157, 0, 707, + 0, 707, 0, 0, 0, 0, 2167, 2168, 2169, 1157, + 2170, 2171, 2172, 2173, 2174, 2175, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1157, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1888, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1888, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1888, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1879, 863, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 864, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1888, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 865, 0, 0, 0, 0, 0, 1879, 1879, 0, 1879, + 0, 0, 0, 866, 0, 0, 0, 0, 0, 0, + 0, 0, 867, 1076, 0, 0, -708, 3039, 3040, 3041, + 0, 0, 0, 0, 3049, 0, 3051, 0, 3053, 3054, + 0, 0, 0, 868, 0, 0, 0, 0, 0, 869, + 0, 0, 0, 1157, 0, 0, 0, 0, 0, 0, + 0, 1879, 0, 1879, 870, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 2316, 0, 871, 2316, 0, 0, 0, 0, 0, 0, + 0, 2323, 0, 872, 0, 0, 0, 0, 0, 0, + 873, 0, 0, 0, 874, 1888, 0, 0, 0, 2332, + 0, 0, 0, 0, 0, 0, 1879, 0, 0, -904, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 3156, 0, 0, 0, 1157, 0, + 1879, 0, 1888, 0, 0, 0, 2395, 1157, 0, 0, + 0, 0, 0, 690, 0, 0, 0, 875, 704, 0, + 704, 0, 0, 0, 1157, 1157, 0, 1879, 1157, 0, + 704, 0, 0, 0, 0, 0, 0, 0, 0, 1157, + 1879, 0, 0, 0, 1157, 0, 0, 1157, 0, 0, + 3213, 0, 1157, 1157, 876, 0, 704, 877, 3222, 3223, + 3224, 3225, 3226, 3227, 0, 0, 704, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 704, 704, 0, + 0, 704, 0, 0, 0, 1157, 0, 704, 0, 0, + 0, 984, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1879, 0, 0, 0, 878, 0, 0, + 0, 984, 0, 879, 0, 0, 1888, 1879, 0, -386, + 1157, 0, 880, 0, 0, 0, 0, 704, 0, 0, + 1879, 0, 0, 0, 0, 0, 0, 0, 3307, 0, + 0, 0, 0, 0, 0, 0, 0, 0, -386, 0, + 881, 882, 0, 883, 884, 0, 0, 1157, 0, 0, + 0, 0, 885, 0, 0, 0, 0, 886, 3347, 0, + 3349, 0, 0, 887, 0, 0, 888, 0, 0, 889, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, -386, 0, 2588, 0, 0, 0, 1879, 0, + 0, 0, 0, 0, 0, 0, 1157, 2610, 1888, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1879, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1157, 1888, 0, 1157, 0, 1157, 0, 0, 0, 0, + 0, 0, 0, 1879, 0, 0, 0, 0, 0, 0, + 0, 2655, 1157, 0, 0, 2659, 1157, 0, 0, 0, + 0, 1888, 0, 0, 0, 0, 2670, 0, 2672, 0, + 2673, 0, 0, 3400, 0, 2674, 0, 0, 0, 1879, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1888, 0, 0, 0, 1888, 1888, 0, 0, 707, 0, + 707, 0, 0, 0, 707, 0, 707, 0, 0, 707, + 0, 0, 0, 707, 2702, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 704, 0, 0, 1157, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1888, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1157, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1157, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1157, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1157, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1879, 0, 0, 0, 0, 0, 0, 0, 1157, + 1157, 2911, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1157, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 4, 1157, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1157, 0, + 0, 0, 0, 0, 0, 0, 0, 5, 0, 3626, + 0, 3627, 3628, 0, 0, 0, 0, 6, 7, 0, + 0, 0, 0, 0, 0, 9, 10, 704, 0, 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, 0, 0, 1157, 37, 38, 39, + 40, 41, 42, 43, 44, 1157, 0, 0, 45, 0, + 0, 0, 0, 0, 0, 0, 1125, 0, 704, 704, + 0, 1879, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 2998, 2999, 704, 0, 0, 3002, 3003, + 0, 0, 3006, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 3016, 1879, 0, 0, 46, 0, 0, 3025, + 0, 0, 0, 3028, 3029, 0, 0, 3032, 3033, 3034, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 3048, + 0, 3050, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 3072, 0, 0, + 0, 0, 3074, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 47, 0, 0, 0, + 0, 0, 0, 3092, 3093, 3096, 3098, 0, 0, 0, + 3105, 3108, 48, 0, 0, 0, 0, 0, 3119, 0, + 0, 3123, 0, 0, 0, 3127, 0, 0, 0, 0, + 0, 0, 49, 0, 1879, 0, 0, 0, 0, 0, + 3150, 0, 0, 0, 0, 1879, 0, 0, 0, 0, + 0, 3157, 0, 3159, 50, 0, 0, 0, 3162, 0, + 0, 0, 0, 3166, 3167, 3168, 3169, 0, 3171, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 3194, 3195, 3196, 0, 0, 0, 0, 51, 0, + 0, 52, 3204, 3205, 1297, 704, 0, 704, 0, 0, + 0, 0, 0, 0, 0, 0, 53, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 3896, 0, + 0, 3897, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 704, 0, 0, 704, 704, 3264, 0, + 0, 0, 0, 0, 0, 0, 1879, 0, 0, 690, + 0, 984, 0, 984, 0, 0, 0, 0, 0, 690, + 0, 0, 0, 704, 0, 3922, 0, 0, 0, 54, + 0, 0, 0, 0, 1879, 0, 0, 0, 0, 0, + 0, 0, 984, 984, 0, 0, 1879, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 55, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 704, 0, 704, 56, 0, 0, 0, 0, + 1879, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 57, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1125, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 58, 0, 0, 0, + 0, 0, 59, 0, 0, 0, 60, 61, 62, 63, + 64, 0, 0, 65, 66, 1345, 0, 1162, 0, 0, + 71, 1346, 0, 0, 0, 1162, 3389, 0, 0, 0, + 0, 690, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 690, 690, 0, 0, 1658, + 0, 0, 0, 0, 0, 0, 1162, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 690, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1162, 0, 1879, 0, 0, 0, 0, 0, 0, 1162, + 0, 0, 0, 0, 0, 0, 4102, 4103, 4104, 4105, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1879, 0, 0, 1162, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1162, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 3600, 3601, 0, + 690, 0, 0, 0, 0, 704, 0, 704, 0, 0, + 704, 0, 704, 0, 0, 704, 704, 704, 0, 0, + 0, 2036, 4246, 0, 0, 0, 0, 0, 704, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1879, 0, + 0, 704, 0, 704, 0, 0, 0, 0, 704, 0, + 0, 0, 0, 0, 0, 0, 0, 3634, 3636, 0, + 0, 1879, 3636, 0, 0, 0, 0, 3647, 3648, 3649, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1879, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 3670, 3671, 3672, 3673, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1516, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1879, 0, 0, 0, 1879, 1879, 0, 1162, 0, 3698, + 0, 0, 0, 0, 0, 0, 0, 1162, 0, 0, + 0, 0, 0, 1587, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 2191, 0, 0, 0, 1891, + 0, 0, 0, 0, 704, 704, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 690, 0, 0, 0, 0, 690, 690, 0, 0, + 0, 3736, 1162, 0, 0, 0, 0, 0, 0, 3740, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 3821, 1162, + 0, 0, 0, 0, 0, 0, 0, 704, 3827, 690, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 2320, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 3846, 0, 3848, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1891, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 904, 0, 0, 3888, 0, 0, 0, 0, + 0, 0, 690, 0, 0, 0, 1162, 0, 0, 3898, + 690, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 4465, 0, 0, 0, 0, 1162, 0, 0, 0, 0, + 0, 0, 0, 0, 4468, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 690, 0, 0, + 690, 690, 0, 1162, 1162, 0, 1162, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1162, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1179, 0, 0, 0, 0, + 0, 1200, 0, 0, 0, 0, 0, 0, 0, 1211, + 0, 0, 0, 690, 0, 0, 0, 1221, 0, 0, + 0, 0, 1252, 0, 0, 1162, 0, 0, 4518, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1162, 0, 0, 0, 1162, 1162, + 0, 0, 0, 0, 0, 2090, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 2114, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 2139, 2140, 0, 2142, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1891, 0, 0, 0, + 0, 0, 2181, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 4096, 0, 4097, 0, 0, 0, 4099, 0, 0, + 1420, 0, 0, 0, 0, 4618, 4620, 4620, 0, 0, + 0, 0, 4108, 0, 0, 0, 0, 0, 0, 1891, + 704, 0, 704, 0, 2235, 0, 704, 0, 704, 4116, + 0, 704, 1546, 0, 0, 704, 0, 0, 4127, 0, + 2191, 0, 0, 0, 0, 0, 1891, 0, 0, 0, + 1570, 0, 0, 2257, 0, 0, 0, 2267, 2270, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1596, 0, 0, 0, 0, 0, 4155, 4156, + 4157, 4158, 4159, 4160, 4161, 0, 0, 0, 0, 4168, + 4169, 0, 4171, 4172, 4173, 4174, 4175, 4176, 4177, 0, + 0, 0, 0, 0, 0, 0, 0, 4184, 0, 4186, + 4187, 0, 0, 0, 0, 0, 0, 1891, 0, 0, + 0, 0, 0, 4693, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1891, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1891, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 4240, 4242, 4244, 0, 0, 4247, + 0, 0, 1891, 0, 0, 0, 2036, 0, 0, 0, + 0, 0, 0, 2912, 0, 0, 0, 0, 0, 0, + 0, 0, 2320, 0, 0, 4737, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 4755, 0, 4757, + 0, 0, 0, 0, 1162, 0, 0, 0, 0, 0, + 1891, 0, 0, 1162, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 3636, 1904, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 690, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1929, 1932, 1933, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 690, 0, 0, 0, 690, 0, 0, + 4620, 0, 0, 2982, 0, 1658, 0, 0, 704, 0, + 1162, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 4842, 0, 0, 0, 0, 1162, 1162, 0, + 0, 0, 0, 0, 0, 1162, 0, 0, 1162, 0, + 0, 0, 1162, 0, 0, 0, 0, 0, 0, 0, + 1162, 1162, 1546, 0, 0, 0, 0, 0, 1162, 0, + 0, 1162, 1162, 1162, 1162, 0, 0, 0, 0, 0, + 0, 1162, 1162, 0, 1162, 0, 1162, 1162, 4877, 1546, + 1162, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1891, 1162, 0, 0, 0, 0, + 1162, 0, 0, 0, 1162, 0, 0, 0, 1162, 0, + 1162, 1162, 1162, 1162, 1162, 1162, 1162, 1162, 1162, 0, + 1162, 4910, 0, 0, 0, 0, 1162, 0, 0, 1162, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 4434, 4435, 4436, 4437, 0, 690, 0, 0, 0, + 0, 0, 0, 0, 690, 0, 690, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 4450, 4451, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 4460, 4461, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1162, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 2777, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 2234, 0, 0, 0, 0, 0, 0, 2800, 0, 0, + 2802, 0, 0, 2813, 0, 0, 0, 0, 0, 0, + 2820, 2825, 0, 0, 0, 0, 2831, 0, 0, 2836, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 2845, 0, 0, 2283, 0, 2852, + 0, 0, 0, 2864, 0, 0, 0, 2871, 0, 2873, + 2874, 2875, 2876, 2877, 2878, 2879, 2880, 2881, 0, 2882, + 0, 0, 0, 0, 0, 1516, 0, 4512, 2907, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1162, 0, 0, 0, + 4534, 0, 1162, 0, 0, 0, 0, 0, 1162, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 4553, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1587, 0, 0, 0, 1891, 0, 0, 704, 2036, 1891, + 1891, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1891, 0, 0, 690, 0, 0, 0, 0, 0, + 0, 2433, 0, 0, 0, 0, 0, 0, 2450, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 2479, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 707, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 2513, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 2529, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 2541, 0, 3030, 0, 0, 0, 0, + 0, 0, 0, 0, 4639, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1162, 0, 1891, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 4663, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 3636, 0, + 2320, 0, 1891, 0, 0, 690, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1162, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 2690, 0, 0, 0, 4743, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 3240, + 0, 1891, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1881, 0, 0, 0, 1162, 0, 0, 0, 0, + 1162, 0, 1546, 1546, 0, 0, 0, 0, 0, 0, + 0, 0, 1882, 0, 0, 0, 1162, 1162, 0, 0, + 0, 0, 1162, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 3636, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 1162, 1162, 0, + 0, 0, 1162, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1162, 1162, 1162, 1162, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 1162, 0, 0, + 1162, 0, 1162, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1162, 1162, 0, 0, 1162, 0, 0, 3361, + 0, 0, 0, 0, 0, 0, 4841, 0, 0, 1162, + 0, 1162, 0, 0, 0, 1162, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1162, 0, 2897, 0, 0, 0, 0, 0, 0, + 0, 0, 1162, 0, 1162, 1162, 1162, 0, 0, 0, + 1881, 0, 0, 0, 0, 0, 0, 0, 2917, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1162, 0, + 0, 1882, 0, 0, 0, 0, 0, 0, 0, 0, + 1162, 0, 0, 0, 0, 1162, 3406, 0, 0, 0, + 0, 3412, 1162, 0, 0, 2930, 0, 2933, 1162, 0, + 0, 0, 0, 690, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 690, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 2825, 0, 2825, 2825, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 3469, 0, 0, 3472, + 0, 3474, 0, 0, 0, 0, 0, 0, 1162, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 3495, 0, + 3497, 1891, 0, 0, 3500, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 704, 0, 0, 0, 0, 0, + 0, 0, 0, 2907, 2907, 2907, 0, 0, 0, 0, + 0, 1891, 1891, 0, 1891, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 3557, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 2257, + 0, 0, 0, 0, 3568, 0, 0, 0, 0, 0, + 0, 2270, 690, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1891, 0, 1891, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 2177, 0, 0, 0, 0, 0, 0, + 0, 0, 3109, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1881, 0, + 0, 0, 0, 0, 0, 0, 0, 3609, 0, 0, + 0, 1891, 0, 0, 0, 0, 0, 0, 0, 1882, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1891, 0, 0, 0, 0, + 0, 0, 0, 0, 2177, 0, 0, 0, 0, 0, + 0, 1881, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1891, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1882, 0, 0, 1891, 0, 0, 1881, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1882, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 3285, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 2982, 0, 1891, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1881, + 0, 0, 1891, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1891, 0, 0, 1881, 0, + 1882, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1881, 0, 0, 1882, + 0, 0, 0, 0, 0, 1162, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 1882, 0, 0, + 0, 0, 0, 0, 1881, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 690, 0, 0, + 1162, 0, 0, 1891, 0, 1882, 0, 0, 0, 0, + 1162, 0, 0, 690, 0, 0, 1162, 0, 1162, 0, + 0, 0, 0, 1891, 1162, 0, 0, 1162, 1162, 1162, + 1162, 1162, 1162, 1162, 1162, 1162, 1162, 0, 0, 0, + 1162, 1162, 1881, 0, 0, 0, 0, 0, 1891, 0, + 0, 0, 0, 1162, 0, 0, 0, 1162, 0, 0, + 0, 1162, 0, 1882, 0, 0, 0, 0, 0, 0, + 0, 1162, 0, 690, 1162, 0, 1162, 0, 0, 0, + 0, 0, 0, 0, 1891, 1162, 1162, 1162, 0, 0, + 0, 1162, 0, 0, 1162, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1162, 0, 0, 1884, 0, 0, + 0, 0, 0, 0, 1162, 0, 0, 0, 0, 0, + 0, 0, 1162, 0, 1162, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1162, 3927, + 0, 0, 0, 0, 1162, 0, 0, 0, 0, 3931, + 1162, 0, 0, 0, 0, 3932, 0, 3933, 0, 0, + 0, 0, 0, 3507, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1162, 0, 0, 0, 3951, + 3952, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 690, 0, 0, 0, 0, 2177, 0, 0, 0, + 2831, 0, 0, 0, 0, 0, 1881, 0, 0, 0, + 3980, 0, 0, 3983, 0, 3985, 0, 1546, 0, 0, + 0, 0, 0, 0, 3989, 0, 0, 1882, 0, 0, + 3994, 0, 0, 3997, 0, 0, 1884, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1891, 0, 0, 0, + 0, 0, 0, 4026, 0, 0, 0, 0, 0, 0, + 0, 4038, 0, 2907, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 2177, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 4055, 0, 0, + 0, 2177, 0, 1516, 0, 0, 2809, 0, 0, 1587, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 2320, + 0, 0, 0, 0, 0, 0, 2177, 2177, 0, 2177, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 690, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1162, 0, 0, 0, 0, 0, 0, 2177, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1891, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 690, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1891, 1162, + 1162, 0, 2177, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 1885, 0, 0, + 0, 0, 0, 0, 2177, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 2177, 0, 0, 2177, 0, 0, + 0, 0, 0, 0, 0, 0, 1881, 0, 0, 0, + 0, 1881, 1881, 0, 0, 0, 0, 0, 0, 1162, + 0, 0, 0, 1881, 0, 0, 0, 1882, 0, 0, + 0, 0, 1882, 1882, 1884, 0, 0, 0, 0, 0, + 0, 0, 0, 690, 1882, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1162, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1162, 1162, 0, 1891, + 0, 0, 3824, 0, 1162, 1162, 0, 0, 0, 1162, + 1891, 0, 0, 0, 0, 1162, 1162, 1884, 0, 1162, + 0, 0, 0, 0, 0, 0, 0, 3839, 0, 0, + 0, 0, 0, 0, 1162, 3847, 0, 0, 1162, 3852, + 0, 0, 0, 0, 1884, 0, 0, 1162, 0, 0, + 0, 0, 1162, 3863, 0, 0, 0, 0, 4294, 4295, + 0, 0, 0, 0, 1162, 0, 1885, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1881, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1162, 0, 1882, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1884, 0, 0, 4326, 0, + 0, 1891, 1546, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1884, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 704, 0, 0, 1891, + 0, 0, 1884, 0, 1881, 0, 0, 0, 0, 0, + 0, 1891, 0, 0, 0, 4344, 4346, 0, 0, 0, + 0, 0, 0, 0, 0, 1882, 0, 0, 4353, 0, + 1884, 0, 0, 0, 4358, 4359, 0, 0, 4361, 0, + 0, 0, 690, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1891, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 2907, 0, 0, 0, + 0, 2907, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 2907, 0, 0, 0, 0, 1884, 4002, + 4003, 4004, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1881, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1162, 0, + 0, 0, 4415, 0, 1882, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1886, 0, 0, 0, 0, 0, 0, + 1891, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1885, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1162, 0, 0, 0, 1891, 0, 0, + 0, 0, 1162, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1162, + 1162, 0, 0, 1162, 0, 0, 0, 1885, 0, 0, + 0, 0, 0, 0, 1162, 0, 0, 0, 0, 1162, + 0, 0, 1162, 0, 0, 0, 0, 1162, 1162, 0, + 0, 0, 0, 0, 1885, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1884, 0, 2177, 0, 0, 4501, 0, 0, + 1162, 0, 0, 0, 0, 0, 0, 0, 0, 690, + 0, 0, 0, 0, 0, 0, 0, 2177, 0, 2177, + 0, 2809, 2809, 3443, 0, 0, 2809, 0, 0, 0, + 2177, 1891, 1886, 0, 0, 1162, 0, 2177, 0, 0, + 0, 0, 2177, 0, 0, 1885, 0, 0, 2177, 0, + 0, 0, 0, 2177, 0, 0, 0, 0, 0, 0, + 0, 0, 2177, 0, 1885, 0, 2809, 2809, 0, 2177, + 0, 0, 1162, 0, 0, 0, 0, 0, 0, 0, + 0, 2177, 1885, 0, 0, 0, 4228, 0, 2177, 0, + 2177, 2177, 2177, 2177, 2177, 2177, 2177, 2177, 2177, 2177, + 0, 0, 0, 0, 0, 4254, 0, 0, 0, 0, + 1885, 0, 4579, 1881, 0, 0, 0, 0, 0, 0, + 0, 1162, 0, 1891, 2177, 0, 0, 4264, 0, 0, + 0, 0, 0, 0, 1882, 0, 0, 4596, 0, 0, + 0, 0, 0, 0, 0, 1162, 1891, 0, 1162, 0, + 1162, 0, 0, 1881, 1881, 0, 1881, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 1162, 1885, 0, + 0, 1162, 0, 0, 1882, 1882, 1891, 1882, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1881, 0, + 1881, 0, 0, 0, 0, 1891, 0, 0, 0, 1891, + 1891, 0, 0, 0, 0, 0, 0, 0, 0, 1882, + 0, 1882, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 2177, 0, 0, + 0, 0, 0, 1162, 0, 0, 0, 0, 0, 0, + 0, 0, 1884, 1881, 0, 0, 0, 1884, 1884, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1884, + 0, 1891, 0, 0, 1882, 0, 0, 1881, 0, 4363, + 4364, 4365, 4366, 0, 0, 0, 0, 0, 0, 0, + 1886, 0, 0, 0, 0, 0, 0, 0, 1882, 0, + 0, 1162, 0, 0, 1881, 0, 0, 2831, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 1881, 1162, 0, + 0, 0, 0, 0, 0, 1882, 4718, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1882, 0, + 0, 0, 0, 1886, 0, 0, 0, 0, 0, 0, + 0, 0, 1885, 1162, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1162, 0, 0, 0, 0, 0, 0, + 1886, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1881, 0, 0, 0, 1162, 1162, 0, 0, 0, 0, + 0, 0, 0, 0, 1881, 0, 0, 1162, 0, 0, + 1884, 1882, 0, 0, 0, 0, 0, 1881, 0, 0, + 0, 0, 4779, 0, 0, 1882, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1882, 0, + 0, 0, 0, 1162, 0, 0, 0, 0, 0, 0, + 0, 1886, 0, 1162, 0, 0, 0, 2177, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1886, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1884, 0, 0, 0, 0, 1881, 0, 0, 1886, 0, + 0, 0, 0, 0, 0, 0, 0, 4823, 0, 0, + 0, 0, 0, 0, 0, 1881, 1882, 0, 0, 0, + 0, 1162, 0, 0, 0, 0, 1886, 0, 0, 0, + 1162, 0, 0, 0, 0, 0, 1882, 0, 0, 0, + 1881, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1882, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 4863, 4863, 0, 1881, 0, 0, 0, + 0, 0, 0, 0, 1886, 0, 0, 0, 2177, 1884, + 0, 0, 0, 0, 0, 0, 0, 1882, 0, 0, + 0, 4545, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 4863, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 4907, 2177, 0, 0, 0, 0, 0, 2177, + 0, 0, 1885, 0, 0, 0, 0, 1885, 1885, 0, + 0, 0, 0, 0, 0, 3443, 3443, 0, 2809, 1885, + 0, 2809, 2809, 2809, 2809, 2809, 2809, 2809, 2809, 2809, + 2809, 3443, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 4863, 0, 0, 0, 0, 0, 2177, 0, 0, 2177, + 0, 2177, 0, 0, 0, 0, 3443, 3443, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 2809, 2809, 2177, 0, 2177, 0, 0, 2177, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1881, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1886, 0, + 0, 0, 0, 0, 2177, 0, 0, 0, 0, 1882, + 1885, 0, 0, 0, 0, 2177, 0, 0, 0, 4656, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1546, 0, 0, 0, 0, 0, 2177, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1885, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1884, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1881, 0, + 0, 0, 0, 0, 4740, 0, 0, 0, 0, 1884, + 1884, 0, 1884, 0, 0, 0, 0, 0, 0, 1882, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1881, 0, 0, 0, 0, 0, 0, 0, 0, 1885, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1882, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1884, 0, 1884, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 2809, 0, 0, 0, 1884, + 0, 0, 0, 0, 0, 0, 0, 0, 1886, 0, + 0, 0, 0, 1886, 1886, 0, 0, 0, 0, 0, + 0, 1881, 0, 1884, 0, 1886, 0, 0, 0, 0, + 0, 0, 1881, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1882, 0, 0, 0, 0, 0, 0, 0, + 1884, 0, 0, 1882, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1884, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 2177, 0, 0, 0, 2177, 2177, + 2177, 0, 0, 3443, 0, 0, 1884, 0, 3443, 3443, + 3443, 3443, 3443, 3443, 3443, 3443, 3443, 3443, 2177, 2177, + 1884, 0, 0, 1881, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1884, 0, 0, 1886, 0, 0, 0, + 0, 0, 0, 0, 1882, 0, 0, 2177, 2809, 2809, + 2177, 1881, 2177, 0, 0, 0, 2177, 3443, 3443, 0, + 0, 2177, 0, 1881, 2177, 0, 0, 0, 0, 0, + 0, 0, 1882, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1882, 0, 0, 0, 0, 0, + 0, 0, 0, 2177, 0, 0, 0, 0, 0, 1885, + 0, 1884, 0, 0, 0, 2177, 1886, 1881, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 1884, 2177, 0, 0, 0, 0, 0, 1882, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1885, + 1885, 0, 1885, 0, 0, 0, 1884, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1884, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1885, 0, 1885, 0, 0, 0, + 0, 0, 0, 0, 0, 1886, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1885, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1881, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1885, 0, 0, 0, 0, 0, 0, + 1882, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1885, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1885, 0, 3443, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 2177, 2177, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1881, 1884, 0, 1885, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1885, 0, 0, 2177, 1882, 0, 0, 2809, 0, 0, + 0, 0, 0, 1885, 0, 0, 0, 0, 0, 0, + 0, 2177, 0, 2177, 0, 0, 0, 0, 3443, 3443, + 2177, 0, 0, 2809, 2809, 2177, 2177, 0, 2177, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1881, 0, 0, 0, 0, + 0, 1885, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 2177, 0, 0, 0, 1882, 0, 1881, 0, + 0, 1885, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 1886, 0, 0, 0, 1882, + 0, 0, 0, 0, 0, 0, 1885, 0, 1881, 0, + 0, 0, 0, 0, 1884, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1882, + 0, 0, 0, 0, 0, 1886, 1886, 0, 1886, 0, + 0, 0, 1885, 0, 0, 0, 1884, 1881, 0, 0, + 0, 1881, 1881, 0, 0, 0, 0, 0, 2177, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1882, 0, + 0, 0, 1882, 1882, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1886, 0, 1886, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 3443, 2809, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 3443, 3443, 2177, 0, 0, 0, + 0, 0, 0, 0, 0, 1886, 0, 0, 0, 0, + 0, 0, 0, 2177, 0, 0, 0, 1884, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1884, 1886, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 1886, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1886, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 1885, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 3443, 0, 0, 0, 0, + 0, 0, 1886, 0, 0, 2177, 0, 0, 0, 1884, + 0, 0, 0, 0, 0, 0, 1886, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1886, + 0, 0, 0, 0, 0, 0, 0, 1884, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1884, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 2177, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1884, 0, 0, 0, 1886, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 2177, 0, 0, 0, 1885, 0, 0, 1886, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1886, 0, 0, 0, 1885, 0, 0, 0, + 2177, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 1886, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 2177, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 86, 87, 88, 0, 90, 91, 92, + 0, 0, 0, 95, 0, 1884, 98, 99, 100, 101, + 102, 103, 0, 104, 105, 0, 0, 1885, 107, 108, + 109, 110, 0, 111, 112, 113, 114, 115, 1885, 116, + 117, 118, 0, 0, 0, 0, 0, 121, 122, 0, + 0, 0, 0, 123, 0, 0, 0, 0, 0, 0, + 0, 0, 124, 0, 125, 0, 126, 0, 35, 0, + 0, 0, 0, 0, 0, 0, 41, 42, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 133, 0, 0, 0, 135, 136, 137, 138, + 139, 0, 0, 0, 0, 0, 0, 0, 0, 1884, + 0, 0, 140, 0, 0, 0, 0, 0, 0, 144, + 1886, 145, 0, 0, 0, 0, 0, 148, 0, 1885, + 0, 0, 0, 0, 0, 0, 0, 0, 151, 0, + 0, 0, 0, 0, 152, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 155, 156, 0, 1885, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 1885, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 162, 0, 0, 0, 0, 0, 0, 164, 0, + 0, 0, 166, 0, 0, 0, 0, 168, 0, 0, + 0, 1884, 0, 169, 0, 170, 0, 0, 0, 0, + 0, 172, 0, 1885, 0, 0, 0, 0, 0, 0, + 173, 0, 0, 0, 1884, 0, 0, 0, 0, 0, + 0, 0, 0, 174, 175, 0, 0, 0, 0, 0, + 176, 0, 177, 0, 0, 178, 179, 0, 180, 0, + 0, 0, 0, 0, 1884, 0, 0, 0, 181, 182, + 0, 183, 0, 0, 0, 0, 0, 0, 0, 0, + 1886, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 188, 189, 190, 0, 0, 191, 0, 0, 0, 193, + 0, 0, 194, 1884, 195, 0, 0, 1884, 1884, 0, + 0, 0, 1886, 0, 0, 0, 0, 196, 197, 198, + 199, 200, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 201, 0, 202, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 204, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 210, 0, 0, 212, 0, 0, + 0, 0, 0, 0, 0, 1885, 0, 0, 0, 0, + 0, 0, 0, 0, 217, 0, 0, 219, 0, 220, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 222, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 224, 225, 0, 0, 0, 226, + 0, 227, 0, 1886, 0, 0, 0, 0, 0, 0, + 230, 0, 0, 0, 1886, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 234, 0, 0, 235, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 237, 238, 239, 240, 241, 242, 243, 244, + 245, 0, 0, 0, 0, 0, 0, 0, 86, 87, + 88, 0, 90, 91, 92, 0, 0, 0, 95, 1885, + 0, 98, 99, 100, 101, 102, 103, 2972, 104, 105, + 0, 0, 0, 107, 108, 109, 110, 0, 111, 112, + 113, 114, 115, 0, 116, 117, 118, 0, 0, 0, + 0, 0, 121, 122, 0, 0, 0, 0, 123, 0, + 0, 0, 0, 0, 0, 0, 0, 124, 0, 125, + 0, 126, 0, 35, 0, 1886, 0, 0, 0, 0, + 0, 41, 42, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1886, 0, 0, 0, 0, 0, 0, + 0, 1885, 0, 0, 0, 1886, 0, 133, 0, 0, + 0, 135, 136, 137, 138, 139, 0, 0, 0, 0, + 0, 0, 0, 0, 1885, 0, 0, 140, 0, 0, + 0, 0, 0, 0, 144, 0, 145, 0, 0, 0, + 0, 0, 148, 0, 0, 0, 0, 0, 0, 1886, + 0, 0, 0, 151, 1885, 0, 0, 0, 0, 152, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 155, + 156, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1885, 0, 0, 162, 1885, 1885, 0, + 0, 0, 0, 164, 0, 0, 0, 166, 0, 0, + 0, 0, 168, 0, 0, 0, 0, 0, 169, 0, + 170, 0, 0, 0, 0, 0, 172, 0, 0, 0, + 0, 0, 0, 0, 0, 173, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 174, 175, + 0, 0, 0, 0, 0, 176, 0, 177, 0, 0, + 178, 179, 0, 180, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 181, 182, 0, 183, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 188, 189, 190, 0, 0, + 191, 1886, 0, 0, 193, 0, 0, 194, 0, 195, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 196, 197, 198, 199, 200, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 201, 0, 202, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 204, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 210, + 0, 0, 212, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 217, + 0, 0, 219, 0, 220, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 222, 0, 0, + 0, 0, 0, 0, 0, 1886, 0, 0, 0, 224, + 225, 0, 0, 0, 226, 0, 227, 0, 0, 0, + 0, 0, 0, 0, 0, 230, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 234, 0, 0, 235, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 237, 238, 239, + 240, 241, 242, 243, 244, 245, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 2974, 0, 0, 0, 0, 1886, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 1886, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 713, 86, 87, + 88, 412, 90, 91, 92, 413, 0, 414, 95, 0, + 1886, 98, 99, 100, 101, 102, 103, 714, 104, 105, + 415, 715, 0, 107, 108, 109, 110, 716, 717, 112, + 113, 114, 115, 0, 116, 718, 719, 416, 417, 0, + 0, 0, 418, 419, 0, 0, 0, 0, 420, 1886, + 0, 0, 0, 1886, 1886, 0, 0, 421, 0, 422, + 0, 423, 424, 35, 0, 0, 0, 0, 0, 0, + 0, 41, 42, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 426, 427, 428, 429, 430, 431, 432, + 433, 720, 434, 435, 436, 721, 722, 723, 724, 725, + 726, 727, 437, 438, 728, 439, 440, 133, 441, 442, + 443, 135, 136, 137, 138, 139, 729, 444, 445, 446, + 447, 448, 730, 731, 449, 450, 732, 140, 452, 733, + 453, 454, 455, 456, 144, 734, 145, 735, 457, 458, + 459, 460, 148, 461, 736, 737, 463, 464, 465, 466, + 467, 468, 738, 151, 469, 739, 740, 741, 742, 152, + 743, 744, 745, 470, 471, 472, 473, 474, 475, 155, + 156, 476, 746, 477, 747, 478, 479, 480, 481, 482, + 748, 483, 484, 485, 749, 750, 486, 487, 488, 489, + 490, 751, 491, 492, 493, 752, 494, 495, 753, 496, + 497, 498, 499, 164, 500, 501, 502, 166, 754, 503, + 755, 504, 168, 505, 756, 506, 757, 507, 169, 758, + 170, 508, 509, 510, 759, 511, 172, 760, 512, 761, + 513, 514, 515, 516, 517, 173, 518, 519, 520, 762, + 521, 522, 523, 524, 525, 526, 763, 527, 174, 175, + 764, 528, 529, 530, 765, 176, 766, 177, 767, 531, + 178, 179, 532, 180, 533, 534, 535, 536, 537, 538, + 539, 768, 540, 181, 182, 541, 183, 769, 542, 543, + 544, 770, 771, 545, 546, 547, 548, 549, 550, 551, + 552, 553, 554, 555, 556, 188, 189, 190, 557, 558, + 191, 772, 559, 560, 193, 561, 773, 194, 562, 195, + 563, 564, 565, 774, 566, 775, 776, 567, 568, 569, + 777, 778, 196, 197, 198, 199, 200, 570, 571, 572, + 573, 574, 575, 576, 779, 577, 201, 578, 202, 579, + 580, 581, 780, 582, 583, 584, 585, 586, 587, 588, + 204, 589, 590, 591, 592, 781, 593, 594, 595, 596, + 597, 598, 599, 600, 601, 602, 782, 603, 604, 210, + 605, 606, 212, 607, 608, 609, 610, 611, 612, 613, + 614, 783, 615, 616, 617, 618, 619, 784, 620, 217, + 621, 622, 219, 623, 220, 624, 785, 625, 626, 627, + 628, 629, 630, 631, 632, 633, 634, 222, 786, 635, + 636, 787, 637, 638, 639, 640, 641, 642, 788, 224, + 225, 789, 790, 644, 226, 645, 227, 791, 646, 647, + 648, 649, 650, 651, 652, 792, 793, 653, 654, 655, + 656, 657, 794, 795, 658, 659, 660, 661, 662, 796, + 234, 797, 664, 235, 665, 666, 667, 798, 799, 668, + 800, 801, 669, 670, 671, 672, 673, 237, 238, 239, + 240, 241, 242, 243, 244, 245, 674, 675, 676, 85, + 0, 0, 86, 87, 88, 89, 90, 91, 92, 93, + 0, 94, 95, 96, 97, 98, 99, 100, 101, 102, + 103, 946, 104, 105, 106, 0, 0, 107, 108, 109, + 110, 0, 111, 112, 113, 114, 115, 0, 116, 117, + 118, 119, 120, 0, 0, 0, 121, 122, 0, 0, + 0, 0, 123, 0, 0, 0, 0, 0, 0, 0, + 0, 124, 0, 125, 0, 126, 127, 35, 0, 0, + 0, 0, 0, 0, 0, 41, 42, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 128, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 129, 0, 130, + 131, 0, 0, 0, 0, 0, 0, 0, 0, 132, + 0, 133, 0, 0, 134, 135, 136, 137, 138, 139, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 140, 0, 0, 141, 0, 142, 143, 144, 0, + 145, 0, 146, 0, 147, 0, 148, 0, 0, 0, + 0, 0, 0, 0, 149, 0, 150, 151, 0, 0, + 0, 0, 0, 152, 0, 0, 0, 0, 0, 0, + 153, 0, 154, 155, 156, 157, 0, 0, 0, 0, + 0, -1350, 0, 0, 0, 0, 0, 158, 0, 159, + 0, 0, 0, 160, 0, 0, 0, 0, 0, 161, + 162, 0, 0, 0, 0, 0, 163, 164, 165, 0, + 0, 166, 0, 0, 167, 0, 168, 0, 0, 0, + 0, 0, 169, 0, 170, 0, 0, 0, 171, 0, + 172, 0, 0, 0, 0, 0, 0, 0, 0, 173, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 174, 175, 0, 0, -1350, 0, 0, 176, + 0, 177, 0, 0, 178, 179, 0, 180, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 181, 182, 0, + 183, 0, 184, 185, 0, 0, 0, 0, 186, 0, + 0, 0, 0, 0, 0, 0, 187, 0, 0, 188, + 189, 190, 0, 0, 191, 0, 0, 192, 193, 0, + 0, 194, 0, 195, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 196, 197, 198, 199, + 200, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 201, 0, 202, 0, 203, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 204, 205, 0, 0, 0, 0, + 206, 0, 207, 0, 0, 0, 0, 208, 0, 0, + 0, 0, 209, 210, 0, 211, 212, 0, 0, 213, + 0, 0, 0, 0, 214, 215, 0, 0, 0, 0, + 0, 0, 216, 217, 0, 218, 219, 0, 220, 0, + 0, 0, 0, 221, 0, 0, 0, 0, 0, 0, + 0, 222, 0, 0, 0, 223, 0, 0, 0, 0, + 0, 0, 0, 224, 225, 0, 0, 0, 226, 0, + 227, 0, 228, 0, 229, 0, 0, 0, 0, 230, + 0, 0, 231, 0, 0, -1350, 0, 0, 232, 0, + 0, 0, 0, 233, 234, 0, 0, 235, 0, 0, + 0, 0, 4, 0, 0, 236, 0, 0, 0, 0, + 0, 237, 238, 239, 240, 241, 242, 243, 244, 245, + 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 6, 7, 0, 0, 0, 0, 0, 246, + 9, 10, 0, -132, 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, 0, + 0, 0, 37, 38, 39, 40, 41, 42, 43, 44, + 0, 0, 0, 45, 0, 0, 0, 0, 0, 0, + 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 6, 7, 0, 0, 0, 0, 0, 0, 9, + 10, 46, 0, 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, 0, 0, + 0, 37, 38, 39, 40, 41, 42, 43, 44, 0, + 0, 0, 45, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 47, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 48, 0, 0, + 46, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 49, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 50, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 47, 0, 0, 51, 0, 0, 52, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 48, 0, 0, 0, + 0, 53, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 49, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 50, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 51, 0, 54, 52, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 53, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 55, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 56, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 57, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 54, 0, 0, 0, 0, 0, 0, + 0, 58, 0, 0, 0, 0, 0, 59, 0, 0, + 0, 60, 61, 62, 63, 64, 0, 0, 65, 66, + 1345, 1993, 0, 0, 0, 71, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 55, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 56, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 57, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, + 58, 0, 0, 0, 0, 0, 59, 0, 0, 0, + 60, 61, 62, 63, 64, 5, 0, 65, 66, 1345, + 2683, 0, 0, 0, 71, 6, 7, 0, 0, 0, + 0, 0, 0, 9, 10, 0, 0, 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, 0, 0, 0, 37, 38, 39, 40, 41, + 42, 43, 44, 0, 0, 0, 45, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 46, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 47, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 49, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 50, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 51, 0, 0, 52, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 53, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 54, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 55, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 56, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 57, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 58, 0, 0, 0, 0, 0, + 59, 0, 0, 0, 60, 61, 62, 63, 64, 0, + 0, 65, 66, 1345, 0, 0, 0, 0, 71, 713, + 86, 87, 88, 412, 90, 91, 92, 413, 0, 414, + 95, 0, 0, 98, 99, 100, 101, 102, 103, 714, + 104, 105, 415, 715, 0, 107, 108, 109, 110, 716, + 717, 112, 113, 114, 115, 0, 116, 718, 719, 416, + 417, 0, 0, 0, 418, 419, 0, 0, 0, 0, + 420, 0, 0, 0, 0, 0, 0, 0, 0, 421, + 0, 422, 0, 423, 424, 35, 425, 0, 0, 37, + 38, 39, 40, 41, 42, 43, 44, 1435, 1436, 1437, + 45, 1438, 0, 0, 0, 426, 427, 428, 429, 430, + 431, 432, 433, 2901, 434, 435, 436, 0, 0, 0, + 0, 1439, 0, 0, 437, 438, 0, 439, 440, 133, + 441, 442, 443, 135, 1440, 137, 1441, 1442, 0, 444, + 445, 446, 447, 448, 1443, 1444, 449, 450, 1445, 1446, + 452, 0, 453, 454, 455, 456, 1447, 0, 1448, 0, + 457, 458, 459, 460, 148, 461, 462, 0, 463, 464, + 465, 466, 467, 468, 0, 151, 469, 0, 1449, 1450, + 1451, 1452, 1453, 1454, 1455, 470, 471, 472, 473, 474, + 475, 1456, 1457, 476, 0, 477, 0, 478, 479, 480, + 481, 482, 0, 483, 484, 485, 2902, 0, 486, 487, + 1458, 489, 490, 0, 491, 492, 493, 0, 494, 495, + 0, 496, 497, 498, 499, 1459, 500, 501, 502, 1460, + 1461, 503, 0, 504, 1462, 505, 0, 506, 0, 507, + 169, 0, 170, 508, 509, 510, 0, 511, 1463, 0, + 512, 0, 513, 514, 515, 516, 517, 173, 518, 519, + 520, 0, 521, 522, 523, 524, 525, 526, 0, 527, + 174, 175, 0, 528, 529, 530, 1464, 1465, 0, 1466, + 0, 531, 178, 179, 532, 180, 533, 534, 535, 536, + 537, 538, 539, 0, 540, 1467, 182, 541, 183, 0, + 542, 543, 544, 1468, 1469, 545, 546, 547, 548, 549, + 550, 551, 552, 553, 554, 555, 556, 1470, 189, 1471, + 557, 558, 191, 1472, 559, 560, 193, 561, 1473, 1474, + 562, 1475, 563, 564, 565, 0, 566, 0, 0, 1476, + 568, 569, 0, 0, 196, 197, 198, 199, 1477, 570, + 571, 572, 573, 574, 575, 576, 0, 577, 1478, 578, + 202, 579, 580, 581, 0, 582, 583, 584, 585, 586, + 587, 588, 1479, 589, 590, 591, 592, 0, 593, 594, + 595, 596, 597, 598, 599, 600, 601, 602, 0, 603, + 604, 210, 605, 606, 1480, 607, 608, 609, 610, 611, + 612, 613, 614, 0, 615, 616, 617, 618, 619, 1481, + 620, 217, 621, 622, 219, 623, 1482, 624, 0, 625, + 626, 627, 628, 629, 630, 631, 632, 633, 634, 1483, + 0, 635, 636, 0, 637, 638, 639, 640, 641, 642, + 0, 1484, 1485, 0, 0, 644, 1486, 645, 1487, 1488, + 646, 647, 648, 649, 650, 651, 652, 0, 1489, 653, + 654, 655, 656, 657, 1490, 0, 658, 659, 660, 661, + 662, 663, 1491, 2903, 664, 235, 665, 666, 667, 0, + 0, 668, 0, 0, 669, 670, 671, 672, 673, 237, + 1492, 1493, 1494, 1495, 1496, 1497, 1498, 1499, 674, 675, + 676, 0, 0, 0, 0, 0, 0, 0, 1500, 1501, + 2904, 0, 0, 0, 0, 0, 0, 1503, 2905, 713, + 86, 87, 88, 412, 90, 91, 92, 413, 0, 414, + 95, 0, 0, 98, 99, 100, 101, 102, 103, 714, + 104, 105, 415, 715, 0, 107, 108, 109, 110, 716, + 717, 112, 113, 114, 115, 0, 116, 718, 719, 416, + 417, 0, 0, 0, 418, 419, 0, 0, 0, 0, + 420, 0, 0, 0, 0, 0, 0, 0, 0, 421, + 0, 422, 0, 423, 424, 35, 425, 0, 0, 37, + 38, 39, 40, 41, 42, 43, 44, 1435, 1436, 1437, + 45, 1438, 0, 0, 0, 426, 427, 428, 429, 430, + 431, 432, 433, 0, 434, 435, 436, 0, 0, 0, + 0, 1439, 0, 0, 437, 438, 0, 439, 440, 133, + 441, 442, 443, 135, 1440, 137, 1441, 1442, 0, 444, + 445, 446, 447, 448, 1443, 1444, 449, 450, 1445, 1446, + 452, 0, 453, 454, 455, 456, 1447, 0, 1448, 0, + 457, 458, 459, 460, 148, 461, 462, 0, 463, 464, + 465, 466, 467, 468, 0, 151, 469, 0, 1449, 1450, + 1451, 1452, 1453, 1454, 1455, 470, 471, 472, 473, 474, + 475, 1456, 1457, 476, 0, 477, 0, 478, 479, 480, + 481, 482, 0, 483, 484, 485, 0, 0, 486, 487, + 1458, 489, 490, 0, 491, 492, 493, 0, 494, 495, + 0, 496, 497, 498, 499, 1459, 500, 501, 502, 1460, + 1461, 503, 0, 504, 1462, 505, 0, 506, 0, 507, + 169, 0, 170, 508, 509, 510, 0, 511, 1463, 0, + 512, 0, 513, 514, 515, 516, 517, 173, 518, 519, + 520, 0, 521, 522, 523, 524, 525, 526, 0, 527, + 174, 175, 0, 528, 529, 530, 1464, 1465, 0, 1466, + 0, 531, 178, 179, 532, 180, 533, 534, 535, 536, + 537, 538, 539, 0, 540, 1467, 182, 541, 183, 0, + 542, 543, 544, 1468, 1469, 545, 546, 547, 548, 549, + 550, 551, 552, 553, 554, 555, 556, 1470, 189, 1471, + 557, 558, 191, 1472, 559, 560, 193, 561, 1473, 1474, + 562, 1475, 563, 564, 565, 0, 566, 0, 0, 1476, + 568, 569, 0, 0, 196, 197, 198, 199, 1477, 570, + 571, 572, 573, 574, 575, 576, 0, 577, 1478, 578, + 202, 579, 580, 581, 0, 582, 583, 584, 585, 586, + 587, 588, 1479, 589, 590, 591, 592, 0, 593, 594, + 595, 596, 597, 598, 599, 600, 601, 602, 0, 603, + 604, 210, 605, 606, 1480, 607, 608, 609, 610, 611, + 612, 613, 614, 0, 615, 616, 617, 618, 619, 1481, + 620, 217, 621, 622, 219, 623, 1482, 624, 0, 625, + 626, 627, 628, 629, 630, 631, 632, 633, 634, 1483, + 0, 635, 636, 0, 637, 638, 639, 640, 641, 642, + 0, 1484, 1485, 0, 0, 644, 1486, 645, 1487, 1488, + 646, 647, 648, 649, 650, 651, 652, 0, 1489, 653, + 654, 655, 656, 657, 1490, 0, 658, 659, 660, 661, + 662, 663, 1491, 0, 664, 235, 665, 666, 667, 0, + 0, 668, 0, 0, 669, 670, 671, 672, 673, 237, + 1492, 1493, 1494, 1495, 1496, 1497, 1498, 1499, 674, 675, + 676, 0, 0, 0, 0, 0, 0, 0, 1500, 1501, + 0, 0, 0, 0, 0, 0, 0, 1503, 2811, 713, + 86, 87, 88, 412, 90, 91, 92, 413, 0, 414, + 95, 0, 0, 98, 99, 100, 101, 102, 103, 714, + 104, 105, 415, 715, 0, 107, 108, 109, 110, 716, + 717, 112, 113, 114, 115, 0, 116, 718, 719, 416, + 417, 0, 0, 0, 418, 419, 0, 0, 0, 0, + 420, 0, 0, 0, 0, 0, 0, 0, 0, 421, + 0, 422, 0, 423, 424, 35, 0, 0, 0, 0, + 0, 0, 0, 41, 42, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 426, 427, 428, 429, 430, + 431, 432, 433, 0, 434, 435, 436, 0, 0, 0, + 0, 0, 0, 0, 437, 438, 0, 439, 440, 133, + 441, 442, 443, 0, 1857, 137, 1858, 1859, 0, 444, + 445, 446, 447, 448, 0, 0, 449, 450, 1860, 1861, + 452, 0, 453, 454, 455, 456, 0, 0, 145, 0, + 457, 458, 459, 460, 148, 461, 462, 0, 463, 464, + 465, 466, 467, 468, 0, 151, 469, 0, 0, 0, + 0, 152, 0, 0, 0, 470, 471, 472, 473, 474, + 475, 1862, 1863, 476, 0, 477, 0, 478, 479, 480, + 481, 482, 0, 483, 484, 485, 0, 0, 486, 487, + 1458, 489, 490, 0, 491, 492, 493, 0, 494, 495, + 0, 496, 497, 498, 499, 0, 500, 501, 502, 0, + 0, 503, 0, 504, 1864, 505, 0, 506, 0, 507, + 169, 0, 170, 508, 509, 510, 0, 511, 0, 0, + 512, 0, 513, 514, 515, 516, 517, 173, 518, 519, + 520, 2418, 521, 522, 523, 524, 525, 526, 0, 527, + 174, 2419, 0, 528, 529, 530, 1464, 1865, 0, 1866, + 0, 531, 178, 179, 532, 180, 533, 534, 535, 536, + 537, 538, 539, 0, 540, 0, 182, 541, 183, 0, + 542, 543, 544, 0, 0, 545, 546, 547, 548, 549, + 550, 551, 552, 553, 554, 555, 556, 1867, 189, 1868, + 557, 558, 0, 0, 559, 560, 193, 561, 0, 0, + 562, 1869, 563, 564, 565, 0, 566, 0, 0, 567, + 568, 569, 0, 0, 2420, 197, 198, 199, 0, 570, + 571, 572, 573, 574, 575, 576, 0, 577, 0, 578, + 0, 579, 580, 581, 0, 582, 583, 584, 585, 586, + 587, 588, 1870, 589, 590, 591, 592, 0, 593, 594, + 595, 596, 597, 598, 599, 600, 601, 602, 0, 603, + 604, 210, 605, 606, 0, 607, 608, 609, 610, 611, + 612, 613, 614, 0, 615, 616, 617, 618, 619, 0, + 620, 2421, 621, 622, 219, 623, 1872, 624, 0, 625, + 626, 627, 628, 629, 630, 631, 632, 633, 634, 0, + 0, 635, 636, 0, 637, 638, 639, 640, 641, 642, + 0, 1873, 1874, 0, 0, 644, 0, 645, 0, 0, + 646, 647, 648, 649, 650, 651, 652, 0, 0, 653, + 654, 655, 656, 657, 0, 0, 658, 659, 660, 661, + 662, 0, 1875, 2422, 664, 235, 665, 666, 667, 0, + 0, 668, 0, 0, 669, 670, 671, 672, 673, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 674, 675, + 676, 0, 0, 0, 0, 713, 86, 87, 88, 412, + 90, 91, 92, 413, 0, 414, 95, 0, 2423, 98, + 99, 100, 101, 102, 103, 714, 104, 105, 415, 715, + 0, 107, 108, 109, 110, 716, 717, 112, 113, 114, + 115, 0, 116, 718, 719, 416, 417, 0, 0, 0, + 418, 419, 0, 0, 0, 0, 420, 0, 0, 0, + 0, 0, 0, 0, 0, 421, 0, 422, 0, 423, + 424, 35, 0, 0, 0, 0, 0, 0, 0, 41, + 42, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 426, 427, 428, 429, 430, 431, 432, 433, 0, + 434, 435, 436, 0, 0, 0, 0, 0, 0, 0, + 437, 438, 0, 439, 440, 133, 441, 442, 443, 0, + 1857, 137, 1858, 1859, 0, 444, 445, 446, 447, 448, + 0, 0, 449, 450, 1860, 1861, 452, 0, 453, 454, + 455, 456, 0, 0, 145, 0, 457, 458, 459, 460, + 148, 461, 462, 0, 463, 464, 465, 466, 467, 468, + 0, 151, 469, 0, 0, 0, 0, 152, 0, 0, + 0, 470, 471, 472, 473, 474, 475, 1862, 1863, 476, + 0, 477, 0, 478, 479, 480, 481, 482, 0, 483, + 484, 485, 0, 0, 486, 487, 1458, 489, 490, 0, + 491, 492, 493, 0, 494, 495, 0, 496, 497, 498, + 499, 0, 500, 501, 502, 0, 0, 503, 0, 504, + 1864, 505, 0, 506, 0, 507, 169, 0, 170, 508, + 509, 510, 0, 511, 0, 0, 512, 0, 513, 514, + 515, 516, 517, 173, 518, 519, 520, 2418, 521, 522, + 523, 524, 525, 526, 0, 527, 174, 2419, 0, 528, + 529, 530, 1464, 1865, 0, 1866, 0, 531, 178, 179, + 532, 180, 533, 534, 535, 536, 537, 538, 539, 0, + 540, 0, 182, 541, 183, 0, 542, 543, 544, 0, + 0, 545, 546, 547, 548, 549, 550, 551, 552, 553, + 554, 555, 556, 1867, 189, 1868, 557, 558, 0, 0, + 559, 560, 193, 561, 0, 0, 562, 1869, 563, 564, + 565, 0, 566, 0, 0, 567, 568, 569, 0, 0, + 2420, 197, 198, 199, 0, 570, 571, 572, 573, 574, + 575, 576, 0, 577, 0, 578, 0, 579, 580, 581, + 0, 582, 583, 584, 585, 586, 587, 588, 1870, 589, + 590, 591, 592, 0, 593, 594, 595, 596, 597, 598, + 599, 600, 601, 602, 0, 603, 604, 210, 605, 606, + 0, 607, 608, 609, 610, 611, 612, 613, 614, 0, + 615, 616, 617, 618, 619, 0, 620, 2421, 621, 622, + 219, 623, 1872, 624, 0, 625, 626, 627, 628, 629, + 630, 631, 632, 633, 634, 0, 0, 635, 636, 0, + 637, 638, 639, 640, 641, 642, 0, 1873, 1874, 0, + 0, 644, 0, 645, 0, 0, 646, 647, 648, 649, + 650, 651, 652, 0, 0, 653, 654, 655, 656, 657, + 0, 0, 658, 659, 660, 661, 662, 0, 1875, 2422, + 664, 235, 665, 666, 667, 0, 0, 668, 0, 0, + 669, 670, 671, 672, 673, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 674, 675, 676, 0, 0, 0, + 0, 713, 86, 87, 88, 412, 90, 91, 92, 413, + 0, 414, 95, 0, 3323, 98, 99, 100, 101, 102, + 103, 714, 104, 105, 415, 715, 0, 107, 108, 109, + 110, 716, 717, 112, 113, 114, 115, 0, 116, 718, + 719, 416, 417, 0, 0, 0, 418, 419, 0, 0, + 0, 0, 420, 0, 0, 0, 0, 0, 0, 0, + 0, 421, 0, 422, 0, 423, 424, 35, 425, 0, + 0, 37, 38, 39, 40, 41, 42, 43, 44, 1435, + 1436, 1437, 45, 1438, 0, 0, 0, 426, 427, 428, + 429, 430, 431, 432, 433, 0, 434, 435, 436, 0, + 0, 0, 0, 1439, 0, 0, 437, 438, 0, 439, + 440, 133, 441, 442, 443, 135, 1440, 137, 1441, 1442, + 2821, 444, 445, 446, 447, 448, 1443, 1444, 449, 450, + 1445, 1446, 452, 0, 453, 454, 455, 456, 1447, 0, + 1448, 0, 457, 458, 459, 460, 148, 461, 462, 0, + 463, 464, 465, 466, 467, 468, 0, 151, 469, 0, + 1449, 1450, 1451, 1452, 1453, 1454, 1455, 470, 471, 472, + 473, 474, 475, 1456, 1457, 476, 0, 477, 0, 478, + 479, 480, 481, 482, 0, 483, 484, 485, 0, 0, + 486, 487, 1458, 489, 490, 0, 491, 492, 493, 0, + 494, 495, 0, 496, 497, 498, 499, 1459, 500, 501, + 502, 1460, 1461, 503, 0, 504, 1462, 505, 0, 506, + 0, 507, 169, 2822, 170, 508, 509, 510, 0, 511, + 1463, 0, 512, 0, 513, 514, 515, 516, 517, 173, + 518, 519, 520, 0, 521, 522, 523, 524, 525, 526, + 0, 527, 174, 175, 0, 528, 529, 530, 1464, 1465, + 0, 1466, 0, 531, 178, 179, 532, 180, 533, 534, + 535, 536, 537, 538, 539, 2823, 540, 1467, 182, 541, + 183, 0, 542, 543, 544, 1468, 1469, 545, 546, 547, + 548, 549, 550, 551, 552, 553, 554, 555, 556, 1470, + 189, 1471, 557, 558, 191, 1472, 559, 560, 193, 561, + 1473, 1474, 562, 1475, 563, 564, 565, 0, 566, 0, + 0, 1476, 568, 569, 0, 0, 196, 197, 198, 199, + 1477, 570, 571, 572, 573, 574, 575, 576, 0, 577, + 1478, 578, 202, 579, 580, 581, 0, 582, 583, 584, + 585, 586, 587, 588, 1479, 589, 590, 591, 592, 0, + 593, 594, 595, 596, 597, 598, 599, 600, 601, 602, + 0, 603, 604, 210, 605, 606, 1480, 607, 608, 609, + 610, 611, 612, 613, 614, 0, 615, 616, 617, 618, + 619, 1481, 620, 217, 621, 622, 219, 623, 1482, 624, + 0, 625, 626, 627, 628, 629, 630, 631, 632, 633, + 634, 1483, 0, 635, 636, 0, 637, 638, 639, 640, + 641, 642, 0, 1484, 1485, 0, 2824, 644, 1486, 645, + 1487, 1488, 646, 647, 648, 649, 650, 651, 652, 0, + 1489, 653, 654, 655, 656, 657, 1490, 0, 658, 659, + 660, 661, 662, 663, 1491, 0, 664, 235, 665, 666, + 667, 0, 0, 668, 0, 0, 669, 670, 671, 672, + 673, 237, 1492, 1493, 1494, 1495, 1496, 1497, 1498, 1499, + 674, 675, 676, 0, 0, 0, 0, 0, 0, 0, + 1500, 1501, 0, 0, 0, 0, 0, 0, 0, 1503, + 713, 86, 87, 88, 412, 90, 91, 92, 413, 0, + 414, 95, 0, 0, 98, 99, 100, 101, 102, 103, + 714, 104, 105, 415, 715, 0, 107, 108, 109, 110, + 716, 717, 112, 113, 114, 115, 0, 116, 718, 719, + 416, 417, 0, 0, 0, 418, 419, 0, 0, 0, + 0, 420, 0, 0, 0, 0, 0, 0, 0, 0, + 421, 0, 422, 0, 423, 424, 35, 425, 0, 0, + 37, 38, 39, 40, 41, 42, 43, 44, 1435, 1436, + 1437, 45, 1438, 0, 0, 0, 426, 427, 428, 429, + 430, 431, 432, 433, 0, 434, 435, 436, 0, 0, + 0, 0, 1439, 0, 0, 437, 438, 0, 439, 440, + 133, 441, 442, 443, 135, 1440, 137, 1441, 1442, 0, + 444, 445, 446, 447, 448, 1443, 1444, 449, 450, 1445, + 1446, 452, 0, 453, 454, 455, 456, 1447, 0, 1448, + 0, 457, 458, 459, 460, 148, 461, 462, 0, 463, + 464, 465, 466, 467, 468, 0, 151, 469, 0, 1449, + 1450, 1451, 1452, 1453, 1454, 1455, 470, 471, 472, 473, + 474, 475, 1456, 1457, 476, 0, 477, 0, 478, 479, + 480, 481, 482, 0, 483, 484, 485, 0, 0, 486, + 487, 1458, 489, 490, 0, 491, 492, 493, 0, 494, + 495, 0, 496, 497, 498, 499, 1459, 500, 501, 502, + 1460, 1461, 503, 0, 504, 1462, 505, 0, 506, 0, + 507, 169, 0, 170, 508, 509, 510, 0, 511, 1463, + 0, 512, 0, 513, 514, 515, 516, 517, 173, 518, + 519, 520, 0, 521, 522, 523, 524, 525, 526, 0, + 527, 174, 175, 0, 528, 529, 530, 1464, 1465, 0, + 1466, 0, 531, 178, 179, 532, 180, 533, 534, 535, + 536, 537, 538, 539, 0, 540, 1467, 182, 541, 183, + 0, 542, 543, 544, 1468, 1469, 545, 546, 547, 548, + 549, 550, 551, 552, 553, 554, 555, 556, 1470, 189, + 1471, 557, 558, 191, 1472, 559, 560, 193, 561, 1473, + 1474, 562, 1475, 563, 564, 565, 0, 566, 0, 0, + 1476, 568, 569, 0, 0, 196, 197, 198, 199, 1477, + 570, 571, 572, 573, 574, 575, 576, 0, 577, 1478, + 578, 202, 579, 580, 581, 0, 582, 583, 584, 585, + 586, 587, 588, 1479, 589, 590, 591, 592, 0, 593, + 594, 595, 596, 597, 598, 599, 600, 601, 602, 0, + 603, 604, 210, 605, 606, 1480, 607, 608, 609, 610, + 611, 612, 613, 614, 215, 615, 616, 617, 618, 619, + 1481, 620, 217, 621, 622, 219, 623, 1482, 624, 0, + 625, 626, 627, 628, 629, 630, 631, 632, 633, 634, + 1483, 0, 635, 636, 223, 637, 638, 639, 640, 641, + 642, 0, 1484, 1485, 0, 0, 644, 1486, 645, 1487, + 1488, 646, 647, 648, 649, 650, 651, 652, 0, 1489, + 653, 654, 655, 656, 657, 1490, 0, 658, 659, 660, + 661, 662, 1361, 1491, 0, 664, 235, 665, 666, 667, + 0, 0, 668, 0, 236, 669, 670, 671, 672, 673, + 237, 1492, 1493, 1494, 1495, 1496, 1497, 1498, 1499, 674, + 675, 676, 0, 0, 0, 0, 0, 0, 0, 1500, + 1501, 0, 0, 0, 0, 0, 0, 0, 1503, 713, + 86, 87, 88, 412, 90, 91, 92, 413, 0, 414, + 95, 0, 0, 98, 99, 100, 101, 102, 103, 714, + 104, 105, 415, 715, 0, 107, 108, 109, 110, 716, + 717, 112, 113, 114, 115, 0, 116, 718, 719, 416, + 417, 0, 0, 0, 418, 419, 0, 0, 0, 0, + 420, 0, 0, 0, 0, 0, 0, 0, 0, 421, + 0, 422, 0, 423, 424, 35, 425, 0, 0, 37, + 38, 39, 40, 41, 42, 43, 44, 1435, 1436, 1437, + 45, 1438, 0, 0, 0, 426, 427, 428, 429, 430, + 431, 432, 433, 0, 434, 435, 436, 0, 0, 0, + 0, 1439, 0, 0, 437, 438, 0, 439, 440, 133, + 441, 442, 443, 135, 1440, 137, 1441, 1442, 0, 444, + 445, 446, 447, 448, 1443, 1444, 449, 450, 1445, 1446, + 452, 0, 453, 454, 455, 456, 1447, 0, 1448, 0, + 457, 458, 459, 460, 148, 461, 462, 0, 463, 464, + 465, 466, 467, 468, 0, 151, 469, 0, 1449, 1450, + 1451, 1452, 1453, 1454, 1455, 470, 471, 472, 473, 474, + 475, 1456, 1457, 476, 0, 477, 0, 478, 479, 480, + 481, 482, 0, 483, 484, 485, 0, 0, 486, 487, + 1458, 489, 490, 0, 491, 492, 493, 0, 494, 495, + 0, 496, 497, 498, 499, 1459, 500, 501, 502, 1460, + 1461, 503, 0, 504, 1462, 505, 0, 506, 0, 507, + 169, 0, 170, 508, 509, 510, 0, 511, 1463, 0, + 512, 0, 513, 514, 515, 516, 517, 173, 518, 519, + 520, 0, 521, 522, 523, 524, 525, 526, 0, 527, + 174, 175, 0, 528, 529, 530, 1464, 1465, 0, 1466, + 0, 531, 178, 179, 532, 180, 533, 534, 535, 536, + 537, 538, 539, 0, 540, 1467, 182, 541, 183, 0, + 542, 543, 544, 1468, 1469, 545, 546, 547, 548, 549, + 550, 551, 552, 553, 554, 555, 556, 1470, 189, 1471, + 557, 558, 191, 1472, 559, 560, 193, 561, 1473, 1474, + 562, 1475, 563, 564, 565, 0, 566, 0, 0, 1476, + 568, 569, 0, 0, 196, 197, 198, 199, 1477, 570, + 571, 572, 573, 574, 575, 576, 0, 577, 1478, 578, + 202, 579, 580, 581, 0, 582, 583, 584, 585, 586, + 587, 588, 1479, 589, 590, 591, 592, 0, 593, 594, + 595, 596, 597, 598, 599, 600, 601, 602, 0, 603, + 604, 210, 605, 606, 1480, 607, 608, 609, 610, 611, + 612, 613, 614, 0, 615, 616, 617, 618, 619, 1481, + 620, 217, 621, 622, 219, 623, 1482, 624, 0, 625, + 626, 627, 628, 629, 630, 631, 632, 633, 634, 1483, + 0, 635, 636, 0, 637, 638, 639, 640, 641, 642, + 0, 1484, 1485, 0, 0, 644, 1486, 645, 1487, 1488, + 646, 647, 648, 649, 650, 651, 652, 0, 1489, 653, + 654, 655, 656, 657, 1490, 0, 658, 659, 660, 661, + 662, 663, 1491, 0, 664, 235, 665, 666, 667, 0, + 0, 668, 0, 0, 669, 670, 671, 672, 673, 237, + 1492, 1493, 1494, 1495, 1496, 1497, 1498, 1499, 674, 675, + 676, 0, 0, 0, 0, 0, 0, 0, 1500, 1501, + 0, 0, 0, 0, 0, 2085, 2769, 1503, 713, 86, + 87, 88, 412, 90, 91, 92, 413, 0, 414, 95, + 0, 0, 98, 99, 100, 101, 102, 103, 714, 104, + 105, 415, 715, 0, 107, 108, 109, 110, 716, 717, + 112, 113, 114, 115, 0, 116, 718, 719, 416, 417, + 0, 0, 0, 418, 419, 0, 0, 0, 0, 420, + 0, 0, 0, 0, 0, 0, 0, 0, 421, 0, + 422, 0, 423, 424, 35, 425, 0, 0, 37, 38, + 39, 40, 41, 42, 43, 44, 1435, 1436, 1437, 45, + 1438, 0, 0, 0, 426, 427, 428, 429, 430, 431, + 432, 433, 0, 434, 435, 436, 0, 0, 0, 0, + 1439, 0, 0, 437, 438, 0, 439, 440, 133, 441, + 442, 443, 135, 1440, 137, 1441, 1442, 0, 444, 445, + 446, 447, 448, 1443, 1444, 449, 450, 1445, 1446, 452, + 0, 453, 454, 455, 456, 1447, 0, 1448, 0, 457, + 458, 459, 460, 148, 461, 462, 0, 463, 464, 465, + 466, 467, 468, 0, 151, 469, 0, 1449, 1450, 1451, + 1452, 1453, 1454, 1455, 470, 471, 472, 473, 474, 475, + 1456, 1457, 476, 0, 477, 0, 478, 479, 480, 481, + 482, 0, 483, 484, 485, 0, 0, 486, 487, 1458, + 489, 490, 0, 491, 492, 493, 0, 494, 495, 0, + 496, 497, 498, 499, 1459, 500, 501, 502, 1460, 1461, + 503, 0, 504, 1462, 505, 0, 506, 0, 507, 169, + 0, 170, 508, 509, 510, 0, 511, 1463, 0, 512, + 0, 513, 514, 515, 516, 517, 173, 518, 519, 520, + 0, 521, 522, 523, 524, 525, 526, 0, 527, 174, + 175, 0, 528, 529, 530, 1464, 1465, 0, 1466, 0, + 531, 178, 179, 532, 180, 533, 534, 535, 536, 537, + 538, 539, 0, 540, 1467, 182, 541, 183, 0, 542, + 543, 544, 1468, 1469, 545, 546, 547, 548, 549, 550, + 551, 552, 553, 554, 555, 556, 1470, 189, 1471, 557, + 558, 191, 1472, 559, 560, 193, 561, 1473, 1474, 562, + 1475, 563, 564, 565, 0, 566, 0, 0, 1476, 568, + 569, 0, 0, 196, 197, 198, 199, 1477, 570, 571, + 572, 573, 574, 575, 576, 0, 577, 1478, 578, 202, + 579, 580, 581, 0, 582, 583, 584, 585, 586, 587, + 588, 1479, 589, 590, 591, 592, 0, 593, 594, 595, + 596, 597, 598, 599, 600, 601, 602, 0, 603, 604, + 210, 605, 606, 1480, 607, 608, 609, 610, 611, 612, + 613, 614, 0, 615, 616, 617, 618, 619, 1481, 620, + 217, 621, 622, 219, 623, 1482, 624, 0, 625, 626, + 627, 628, 629, 630, 631, 632, 633, 634, 1483, 0, + 635, 636, 0, 637, 638, 639, 640, 641, 642, 0, + 1484, 1485, 0, 0, 644, 1486, 645, 1487, 1488, 646, + 647, 648, 649, 650, 651, 652, 0, 1489, 653, 654, + 655, 656, 657, 1490, 0, 658, 659, 660, 661, 662, + 663, 1491, 0, 664, 235, 665, 666, 667, 0, 0, + 668, 0, 0, 669, 670, 671, 672, 673, 237, 1492, + 1493, 1494, 1495, 1496, 1497, 1498, 1499, 674, 675, 676, + 0, 0, 0, 0, 0, 0, 0, 1500, 1501, 1502, + 0, 0, 0, 0, 0, 0, 1503, 713, 86, 87, + 88, 412, 90, 91, 92, 413, 0, 414, 95, 0, + 0, 98, 99, 100, 101, 102, 103, 714, 104, 105, + 415, 715, 0, 107, 108, 109, 110, 716, 717, 112, + 113, 114, 115, 0, 116, 718, 719, 416, 417, 0, + 0, 0, 418, 419, 0, 0, 0, 0, 420, 0, + 0, 0, 0, 0, 0, 0, 0, 421, 0, 422, + 0, 423, 424, 35, 425, 0, 0, 37, 38, 39, + 40, 41, 42, 43, 44, 1435, 1436, 1437, 45, 1438, + 0, 0, 0, 426, 427, 428, 429, 430, 431, 432, + 433, 0, 434, 435, 436, 0, 0, 0, 0, 1439, + 0, 0, 437, 438, 0, 439, 440, 133, 441, 442, + 443, 135, 1440, 137, 1441, 1442, 0, 444, 445, 446, + 447, 448, 1443, 1444, 449, 450, 1445, 1446, 452, 0, + 453, 454, 455, 456, 1447, 0, 1448, 0, 457, 458, + 459, 460, 148, 461, 462, 0, 463, 464, 465, 466, + 467, 468, 0, 151, 469, 0, 1449, 1450, 1451, 1452, + 1453, 1454, 1455, 470, 471, 472, 473, 474, 475, 1456, + 1457, 476, 1586, 477, 0, 478, 479, 480, 481, 482, + 0, 483, 484, 485, 0, 0, 486, 487, 1458, 489, + 490, 0, 491, 492, 493, 0, 494, 495, 0, 496, + 497, 498, 499, 1459, 500, 501, 502, 1460, 1461, 503, + 0, 504, 1462, 505, 0, 506, 0, 507, 169, 0, + 170, 508, 509, 510, 0, 511, 1463, 0, 512, 0, + 513, 514, 515, 516, 517, 173, 518, 519, 520, 0, + 521, 522, 523, 524, 525, 526, 0, 527, 174, 175, + 0, 528, 529, 530, 1464, 1465, 0, 1466, 0, 531, + 178, 179, 532, 180, 533, 534, 535, 536, 537, 538, + 539, 0, 540, 1467, 182, 541, 183, 0, 542, 543, + 544, 1468, 1469, 545, 546, 547, 548, 549, 550, 551, + 552, 553, 554, 555, 556, 1470, 189, 1471, 557, 558, + 191, 1472, 559, 560, 193, 561, 1473, 1474, 562, 1475, + 563, 564, 565, 0, 566, 0, 0, 1476, 568, 569, + 0, 0, 196, 197, 198, 199, 1477, 570, 571, 572, + 573, 574, 575, 576, 0, 577, 1478, 578, 202, 579, + 580, 581, 0, 582, 583, 584, 585, 586, 587, 588, + 1479, 589, 590, 591, 592, 0, 593, 594, 595, 596, + 597, 598, 599, 600, 601, 602, 0, 603, 604, 210, + 605, 606, 1480, 607, 608, 609, 610, 611, 612, 613, + 614, 0, 615, 616, 617, 618, 619, 1481, 620, 217, + 621, 622, 219, 623, 1482, 624, 0, 625, 626, 627, + 628, 629, 630, 631, 632, 633, 634, 1483, 0, 635, + 636, 0, 637, 638, 639, 640, 641, 642, 0, 1484, + 1485, 0, 0, 644, 1486, 645, 1487, 1488, 646, 647, + 648, 649, 650, 651, 652, 0, 1489, 653, 654, 655, + 656, 657, 1490, 0, 658, 659, 660, 661, 662, 663, + 1491, 0, 664, 235, 665, 666, 667, 0, 0, 668, + 0, 0, 669, 670, 671, 672, 673, 237, 1492, 1493, + 1494, 1495, 1496, 1497, 1498, 1499, 674, 675, 676, 0, + 0, 0, 0, 0, 0, 0, 1500, 1501, 0, 0, + 0, 0, 0, 0, 0, 1503, 713, 86, 87, 88, + 412, 90, 91, 92, 413, 0, 414, 95, 0, 0, + 98, 99, 100, 101, 102, 103, 714, 104, 105, 415, + 715, 0, 107, 108, 109, 110, 716, 717, 112, 113, + 114, 115, 0, 116, 718, 719, 416, 417, 0, 0, + 0, 418, 419, 0, 0, 0, 0, 420, 0, 0, + 0, 0, 0, 0, 0, 0, 421, 0, 422, 0, + 423, 424, 35, 425, 0, 0, 37, 38, 39, 40, + 41, 42, 43, 44, 1435, 1436, 1437, 45, 1438, 0, + 0, 0, 426, 427, 428, 429, 430, 431, 432, 433, + 2265, 434, 435, 436, 0, 0, 0, 0, 1439, 0, + 0, 437, 438, 0, 439, 440, 133, 441, 442, 443, + 135, 1440, 137, 1441, 1442, 0, 444, 445, 446, 447, + 448, 1443, 1444, 449, 450, 1445, 1446, 452, 0, 453, + 454, 455, 456, 1447, 0, 1448, 0, 457, 458, 459, + 460, 148, 461, 462, 0, 463, 464, 465, 466, 467, + 468, 0, 151, 469, 0, 1449, 1450, 1451, 1452, 1453, + 1454, 1455, 470, 471, 472, 473, 474, 475, 1456, 1457, + 476, 0, 477, 0, 478, 479, 480, 481, 482, 0, + 483, 484, 485, 0, 0, 486, 487, 1458, 489, 490, + 0, 491, 492, 493, 0, 494, 495, 0, 496, 497, + 498, 499, 1459, 500, 501, 502, 1460, 1461, 503, 0, + 504, 1462, 505, 0, 506, 0, 507, 169, 0, 170, + 508, 509, 510, 0, 511, 1463, 0, 512, 0, 513, + 514, 515, 516, 517, 173, 518, 519, 520, 0, 521, + 522, 523, 524, 525, 526, 0, 527, 174, 175, 0, + 528, 529, 530, 1464, 1465, 0, 1466, 0, 531, 178, + 179, 532, 180, 533, 534, 535, 536, 537, 538, 539, + 0, 540, 1467, 182, 541, 183, 0, 542, 543, 544, + 1468, 1469, 545, 546, 547, 548, 549, 550, 551, 552, + 553, 554, 555, 556, 1470, 189, 1471, 557, 558, 191, + 1472, 559, 560, 193, 561, 1473, 1474, 562, 1475, 563, + 564, 565, 0, 566, 0, 0, 1476, 568, 569, 0, + 0, 196, 197, 198, 199, 1477, 570, 571, 572, 573, + 574, 575, 576, 0, 577, 1478, 578, 202, 579, 580, + 581, 0, 582, 583, 584, 585, 586, 587, 588, 1479, + 589, 590, 591, 592, 0, 593, 594, 595, 596, 597, + 598, 599, 600, 601, 602, 0, 603, 604, 210, 605, + 606, 1480, 607, 608, 609, 610, 611, 612, 613, 614, + 0, 615, 616, 617, 618, 619, 1481, 620, 217, 621, + 622, 219, 623, 1482, 624, 0, 625, 626, 627, 628, + 629, 630, 631, 632, 633, 634, 1483, 0, 635, 636, + 0, 637, 638, 639, 640, 641, 642, 0, 1484, 1485, + 0, 0, 644, 1486, 645, 1487, 1488, 646, 647, 648, + 649, 650, 651, 652, 0, 1489, 653, 654, 655, 656, + 657, 1490, 0, 658, 659, 660, 661, 662, 663, 1491, + 0, 664, 235, 665, 666, 667, 0, 0, 668, 0, + 0, 669, 670, 671, 672, 673, 237, 1492, 1493, 1494, + 1495, 1496, 1497, 1498, 1499, 674, 675, 676, 0, 0, + 0, 0, 0, 0, 0, 1500, 1501, 0, 0, 0, + 0, 0, 0, 0, 1503, 713, 86, 87, 88, 412, + 90, 91, 92, 413, 0, 414, 95, 0, 0, 98, + 99, 100, 101, 102, 103, 714, 104, 105, 415, 715, + 0, 107, 108, 109, 110, 716, 717, 112, 113, 114, + 115, 0, 116, 718, 719, 416, 417, 0, 0, 0, + 418, 419, 0, 0, 0, 0, 420, 0, 0, 0, + 0, 0, 0, 0, 0, 421, 0, 422, 0, 423, + 424, 35, 425, 0, 0, 37, 38, 39, 40, 41, + 42, 43, 44, 1435, 1436, 1437, 45, 1438, 0, 0, + 0, 426, 427, 428, 429, 430, 431, 432, 433, 0, + 434, 435, 436, 0, 0, 0, 0, 1439, 0, 0, + 437, 438, 0, 439, 440, 133, 441, 442, 443, 135, + 1440, 137, 1441, 1442, 0, 444, 445, 446, 447, 448, + 1443, 1444, 449, 450, 1445, 1446, 452, 0, 453, 454, + 455, 456, 1447, 0, 1448, 0, 457, 458, 459, 460, + 148, 461, 462, 0, 463, 464, 465, 466, 467, 468, + 0, 151, 469, 0, 1449, 1450, 1451, 1452, 1453, 1454, + 1455, 470, 471, 472, 473, 474, 475, 1456, 1457, 476, + 0, 477, 0, 478, 479, 480, 481, 482, 0, 483, + 484, 485, 0, 0, 486, 487, 1458, 489, 490, 0, + 491, 492, 493, 0, 494, 495, 0, 496, 497, 498, + 499, 1459, 500, 501, 502, 1460, 1461, 503, 0, 504, + 1462, 505, 0, 506, 0, 507, 169, 2822, 170, 508, + 509, 510, 0, 511, 1463, 0, 512, 0, 513, 514, + 515, 516, 517, 173, 518, 519, 520, 0, 521, 522, + 523, 524, 525, 526, 0, 527, 174, 175, 0, 528, + 529, 530, 1464, 1465, 0, 1466, 0, 531, 178, 179, + 532, 180, 533, 534, 535, 536, 537, 538, 539, 0, + 540, 1467, 182, 541, 183, 0, 542, 543, 544, 1468, + 1469, 545, 546, 547, 548, 549, 550, 551, 552, 553, + 554, 555, 556, 1470, 189, 1471, 557, 558, 191, 1472, + 559, 560, 193, 561, 1473, 1474, 562, 1475, 563, 564, + 565, 0, 566, 0, 0, 1476, 568, 569, 0, 0, + 196, 197, 198, 199, 1477, 570, 571, 572, 573, 574, + 575, 576, 0, 577, 1478, 578, 202, 579, 580, 581, + 0, 582, 583, 584, 585, 586, 587, 588, 1479, 589, + 590, 591, 592, 0, 593, 594, 595, 596, 597, 598, + 599, 600, 601, 602, 0, 603, 604, 210, 605, 606, + 1480, 607, 608, 609, 610, 611, 612, 613, 614, 0, + 615, 616, 617, 618, 619, 1481, 620, 217, 621, 622, + 219, 623, 1482, 624, 0, 625, 626, 627, 628, 629, + 630, 631, 632, 633, 634, 1483, 0, 635, 636, 0, + 637, 638, 639, 640, 641, 642, 0, 1484, 1485, 0, + 0, 644, 1486, 645, 1487, 1488, 646, 647, 648, 649, + 650, 651, 652, 0, 1489, 653, 654, 655, 656, 657, + 1490, 0, 658, 659, 660, 661, 662, 663, 1491, 0, + 664, 235, 665, 666, 667, 0, 0, 668, 0, 0, + 669, 670, 671, 672, 673, 237, 1492, 1493, 1494, 1495, + 1496, 1497, 1498, 1499, 674, 675, 676, 0, 0, 0, + 0, 0, 0, 0, 1500, 1501, 0, 0, 0, 0, + 0, 0, 0, 1503, 713, 86, 87, 88, 412, 90, + 91, 92, 413, 0, 414, 95, 0, 0, 98, 99, + 100, 101, 102, 103, 714, 104, 105, 415, 715, 0, + 107, 108, 109, 110, 716, 717, 112, 113, 114, 115, + 0, 116, 718, 719, 416, 417, 0, 0, 0, 418, + 419, 0, 0, 0, 0, 420, 0, 0, 0, 0, + 0, 0, 0, 0, 421, 0, 422, 0, 423, 424, + 35, 425, 0, 0, 37, 38, 39, 40, 41, 42, + 43, 44, 1435, 1436, 1437, 45, 1438, 0, 0, 0, + 426, 427, 428, 429, 430, 431, 432, 433, 0, 434, + 435, 436, 0, 0, 0, 0, 1439, 0, 0, 437, + 438, 0, 439, 440, 133, 441, 442, 443, 135, 1440, + 137, 1441, 1442, 0, 444, 445, 446, 447, 448, 1443, + 1444, 449, 450, 1445, 1446, 452, 0, 453, 454, 455, + 456, 1447, 0, 1448, 0, 457, 458, 459, 460, 148, + 461, 462, 0, 463, 464, 465, 466, 467, 468, 0, + 151, 469, 0, 1449, 1450, 1451, 1452, 1453, 1454, 1455, + 470, 471, 472, 473, 474, 475, 1456, 1457, 476, 0, + 477, 0, 478, 479, 480, 481, 482, 0, 483, 484, + 485, 0, 0, 486, 487, 1458, 489, 490, 0, 491, + 492, 493, 0, 494, 495, 0, 496, 497, 498, 499, + 1459, 500, 501, 502, 1460, 1461, 503, 0, 504, 1462, + 505, 0, 506, 0, 507, 169, 0, 170, 508, 509, + 510, 0, 511, 1463, 0, 512, 0, 513, 514, 515, + 516, 517, 173, 518, 519, 520, 0, 521, 522, 523, + 524, 525, 526, 0, 527, 174, 175, 0, 528, 529, + 530, 1464, 1465, 0, 1466, 0, 531, 178, 179, 532, + 180, 533, 534, 535, 536, 537, 538, 539, 0, 540, + 1467, 182, 541, 183, 0, 542, 543, 544, 1468, 1469, + 545, 546, 547, 548, 549, 550, 551, 552, 553, 554, + 555, 556, 1470, 189, 1471, 557, 558, 191, 1472, 559, + 560, 193, 561, 1473, 1474, 562, 1475, 563, 564, 565, + 0, 566, 0, 0, 1476, 568, 569, 0, 0, 196, + 197, 198, 199, 1477, 570, 571, 572, 573, 574, 575, + 576, 0, 577, 1478, 578, 202, 579, 580, 581, 0, + 582, 583, 584, 585, 586, 587, 588, 1479, 589, 590, + 591, 592, 0, 593, 594, 595, 596, 597, 598, 599, + 600, 601, 602, 0, 603, 604, 210, 605, 606, 1480, + 607, 608, 609, 610, 611, 612, 613, 614, 0, 615, + 616, 617, 618, 619, 1481, 620, 217, 621, 622, 219, + 623, 1482, 624, 0, 625, 626, 627, 628, 629, 630, + 631, 632, 633, 634, 1483, 0, 635, 636, 0, 637, + 638, 639, 640, 641, 642, 0, 1484, 1485, 0, 0, + 644, 1486, 645, 1487, 1488, 646, 647, 648, 649, 650, + 651, 652, 0, 1489, 653, 654, 655, 656, 657, 1490, + 0, 658, 659, 660, 661, 662, 663, 1491, 4041, 664, + 235, 665, 666, 667, 0, 0, 668, 0, 0, 669, + 670, 671, 672, 673, 237, 1492, 1493, 1494, 1495, 1496, + 1497, 1498, 1499, 674, 675, 676, 0, 0, 0, 0, + 0, 0, 0, 1500, 1501, 0, 0, 0, 0, 0, + 0, 0, 1503, 713, 86, 87, 88, 412, 90, 91, + 92, 413, 0, 414, 95, 0, 0, 98, 99, 100, + 101, 102, 103, 714, 104, 105, 415, 715, 0, 107, + 108, 109, 110, 716, 717, 112, 113, 114, 115, 0, + 116, 718, 719, 416, 417, 0, 0, 0, 418, 419, + 0, 0, 0, 0, 420, 0, 0, 0, 0, 0, + 0, 0, 0, 421, 0, 422, 0, 423, 424, 35, + 425, 0, 0, 37, 38, 39, 40, 41, 42, 43, + 44, 1435, 1436, 1437, 45, 1438, 0, 0, 0, 426, + 427, 428, 429, 430, 431, 432, 433, 0, 434, 435, + 436, 0, 0, 0, 0, 1439, 0, 0, 437, 438, + 0, 439, 440, 133, 441, 442, 443, 135, 1440, 137, + 1441, 1442, 0, 444, 445, 446, 447, 448, 1443, 1444, + 449, 450, 1445, 1446, 452, 0, 453, 454, 455, 456, + 1447, 0, 1448, 0, 457, 458, 459, 460, 148, 461, + 462, 0, 463, 464, 465, 466, 467, 468, 0, 151, + 469, 4054, 1449, 1450, 1451, 1452, 1453, 1454, 1455, 470, + 471, 472, 473, 474, 475, 1456, 1457, 476, 0, 477, + 0, 478, 479, 480, 481, 482, 0, 483, 484, 485, + 0, 0, 486, 487, 1458, 489, 490, 0, 491, 492, + 493, 0, 494, 495, 0, 496, 497, 498, 499, 1459, + 500, 501, 502, 1460, 1461, 503, 0, 504, 1462, 505, + 0, 506, 0, 507, 169, 0, 170, 508, 509, 510, + 0, 511, 1463, 0, 512, 0, 513, 514, 515, 516, + 517, 173, 518, 519, 520, 0, 521, 522, 523, 524, + 525, 526, 0, 527, 174, 175, 0, 528, 529, 530, + 1464, 1465, 0, 1466, 0, 531, 178, 179, 532, 180, + 533, 534, 535, 536, 537, 538, 539, 0, 540, 1467, + 182, 541, 183, 0, 542, 543, 544, 1468, 1469, 545, + 546, 547, 548, 549, 550, 551, 552, 553, 554, 555, + 556, 1470, 189, 1471, 557, 558, 191, 1472, 559, 560, + 193, 561, 1473, 1474, 562, 1475, 563, 564, 565, 0, + 566, 0, 0, 1476, 568, 569, 0, 0, 196, 197, + 198, 199, 1477, 570, 571, 572, 573, 574, 575, 576, + 0, 577, 1478, 578, 202, 579, 580, 581, 0, 582, + 583, 584, 585, 586, 587, 588, 1479, 589, 590, 591, + 592, 0, 593, 594, 595, 596, 597, 598, 599, 600, + 601, 602, 0, 603, 604, 210, 605, 606, 1480, 607, + 608, 609, 610, 611, 612, 613, 614, 0, 615, 616, + 617, 618, 619, 1481, 620, 217, 621, 622, 219, 623, + 1482, 624, 0, 625, 626, 627, 628, 629, 630, 631, + 632, 633, 634, 1483, 0, 635, 636, 0, 637, 638, + 639, 640, 641, 642, 0, 1484, 1485, 0, 0, 644, + 1486, 645, 1487, 1488, 646, 647, 648, 649, 650, 651, + 652, 0, 1489, 653, 654, 655, 656, 657, 1490, 0, + 658, 659, 660, 661, 662, 663, 1491, 0, 664, 235, + 665, 666, 667, 0, 0, 668, 0, 0, 669, 670, + 671, 672, 673, 237, 1492, 1493, 1494, 1495, 1496, 1497, + 1498, 1499, 674, 675, 676, 0, 0, 0, 0, 0, + 0, 0, 1500, 1501, 0, 0, 0, 0, 0, 0, + 0, 1503, 713, 86, 87, 88, 412, 90, 91, 92, + 413, 0, 414, 95, 0, 0, 98, 99, 100, 101, + 102, 103, 714, 104, 105, 415, 715, 0, 107, 108, + 109, 110, 716, 717, 112, 113, 114, 115, 0, 116, + 718, 719, 416, 417, 0, 0, 0, 418, 419, 0, + 0, 0, 0, 420, 0, 0, 0, 0, 0, 0, + 0, 0, 421, 0, 422, 0, 423, 424, 35, 425, + 0, 0, 37, 38, 39, 40, 41, 42, 43, 44, + 1435, 1436, 1437, 45, 1438, 0, 0, 0, 426, 427, + 428, 429, 430, 431, 432, 433, 0, 434, 435, 436, + 0, 0, 0, 0, 1439, 0, 0, 437, 438, 0, + 439, 440, 133, 441, 442, 443, 4860, 1440, 137, 1441, + 1442, 0, 444, 445, 446, 447, 448, 1443, 1444, 449, + 450, 1445, 1446, 452, 0, 453, 454, 455, 456, 1447, + 0, 1448, 0, 457, 458, 459, 460, 148, 461, 462, + 0, 463, 464, 465, 466, 467, 468, 0, 151, 469, + 4861, 1449, 1450, 1451, 1452, 1453, 1454, 1455, 470, 471, + 472, 473, 474, 475, 1456, 1457, 476, 0, 477, 0, + 478, 479, 480, 481, 482, 0, 483, 484, 485, 0, + 0, 486, 487, 1458, 489, 490, 0, 491, 492, 493, + 0, 494, 495, 0, 496, 497, 498, 499, 1459, 500, + 501, 502, 1460, 1461, 503, 0, 504, 1462, 505, 0, + 506, 0, 507, 169, 0, 170, 508, 509, 510, 0, + 511, 1463, 0, 512, 0, 513, 514, 515, 516, 517, + 173, 518, 519, 520, 0, 521, 522, 523, 524, 525, + 526, 0, 527, 174, 175, 0, 528, 529, 530, 1464, + 1465, 0, 1466, 0, 531, 178, 179, 532, 180, 533, + 534, 535, 536, 537, 538, 539, 0, 540, 1467, 182, + 541, 183, 0, 542, 543, 544, 1468, 1469, 545, 546, + 547, 548, 549, 550, 551, 552, 553, 554, 555, 556, + 1470, 189, 1471, 557, 558, 191, 1472, 559, 560, 193, + 561, 1473, 1474, 562, 1475, 563, 564, 565, 0, 566, + 0, 0, 1476, 568, 569, 0, 0, 196, 197, 198, + 199, 1477, 570, 571, 572, 573, 574, 575, 576, 0, + 577, 1478, 578, 202, 579, 580, 581, 0, 582, 583, + 584, 585, 586, 587, 588, 1479, 589, 590, 591, 592, + 0, 593, 594, 595, 596, 597, 598, 599, 600, 601, + 602, 0, 603, 604, 210, 605, 606, 1480, 607, 608, + 609, 610, 611, 612, 613, 614, 0, 615, 616, 617, + 618, 619, 1481, 620, 217, 621, 622, 219, 623, 1482, + 624, 0, 625, 626, 627, 628, 629, 630, 631, 632, + 633, 634, 1483, 0, 635, 636, 0, 637, 638, 639, + 640, 641, 642, 0, 1484, 1485, 0, 0, 644, 1486, + 645, 1487, 1488, 646, 647, 648, 649, 4862, 651, 652, + 0, 1489, 653, 654, 655, 656, 657, 1490, 0, 658, + 659, 660, 661, 662, 663, 1491, 0, 664, 235, 665, + 666, 667, 0, 0, 668, 0, 0, 669, 670, 671, + 672, 673, 237, 1492, 1493, 1494, 1495, 1496, 1497, 1498, + 1499, 674, 675, 676, 0, 0, 0, 0, 0, 0, + 0, 1500, 1501, 0, 0, 0, 0, 0, 0, 0, + 1503, 713, 86, 87, 88, 412, 90, 91, 92, 413, + 0, 414, 95, 0, 0, 98, 99, 100, 101, 102, + 103, 714, 104, 105, 415, 715, 0, 107, 108, 109, + 110, 716, 717, 112, 113, 114, 115, 0, 116, 718, + 719, 416, 417, 0, 0, 0, 418, 419, 0, 0, + 0, 0, 420, 0, 0, 0, 0, 0, 0, 0, + 0, 421, 0, 422, 0, 423, 424, 35, 425, 0, + 0, 37, 38, 39, 40, 41, 42, 43, 44, 1435, + 1436, 1437, 45, 1438, 0, 0, 0, 426, 427, 428, + 429, 430, 431, 432, 433, 0, 434, 435, 436, 0, + 0, 0, 0, 1439, 0, 0, 437, 438, 0, 439, + 440, 133, 441, 442, 443, 135, 1440, 137, 1441, 1442, + 0, 444, 445, 446, 447, 448, 1443, 1444, 449, 450, + 1445, 1446, 452, 0, 453, 454, 455, 456, 1447, 0, + 1448, 0, 457, 458, 459, 460, 148, 461, 462, 0, + 463, 464, 465, 466, 467, 468, 0, 151, 469, 4861, + 1449, 1450, 1451, 1452, 1453, 1454, 1455, 470, 471, 472, + 473, 474, 475, 1456, 1457, 476, 0, 477, 0, 478, + 479, 480, 481, 482, 0, 483, 484, 485, 0, 0, + 486, 487, 1458, 489, 490, 0, 491, 492, 493, 0, + 494, 495, 0, 496, 497, 498, 499, 1459, 500, 501, + 502, 1460, 1461, 503, 0, 504, 1462, 505, 0, 506, + 0, 507, 169, 0, 170, 508, 509, 510, 0, 511, + 1463, 0, 512, 0, 513, 514, 515, 516, 517, 173, + 518, 519, 520, 0, 521, 522, 523, 524, 525, 526, + 0, 527, 174, 175, 0, 528, 529, 530, 1464, 1465, + 0, 1466, 0, 531, 178, 179, 532, 180, 533, 534, + 535, 536, 537, 538, 539, 0, 540, 1467, 182, 541, + 183, 0, 542, 543, 544, 1468, 1469, 545, 546, 547, + 548, 549, 550, 551, 552, 553, 554, 555, 556, 1470, + 189, 1471, 557, 558, 191, 1472, 559, 560, 193, 561, + 1473, 1474, 562, 1475, 563, 564, 565, 0, 566, 0, + 0, 1476, 568, 569, 0, 0, 196, 197, 198, 199, + 1477, 570, 571, 572, 573, 574, 575, 576, 0, 577, + 1478, 578, 202, 579, 580, 581, 0, 582, 583, 584, + 585, 586, 587, 588, 1479, 589, 590, 591, 592, 0, + 593, 594, 595, 596, 597, 598, 599, 600, 601, 602, + 0, 603, 604, 210, 605, 606, 1480, 607, 608, 609, + 610, 611, 612, 613, 614, 0, 615, 616, 617, 618, + 619, 1481, 620, 217, 621, 622, 219, 623, 1482, 624, + 0, 625, 626, 627, 628, 629, 630, 631, 632, 633, + 634, 1483, 0, 635, 636, 0, 637, 638, 639, 640, + 641, 642, 0, 1484, 1485, 0, 0, 644, 1486, 645, + 1487, 1488, 646, 647, 648, 649, 4862, 651, 652, 0, + 1489, 653, 654, 655, 656, 657, 1490, 0, 658, 659, + 660, 661, 662, 663, 1491, 0, 664, 235, 665, 666, + 667, 0, 0, 668, 0, 0, 669, 670, 671, 672, + 673, 237, 1492, 1493, 1494, 1495, 1496, 1497, 1498, 1499, + 674, 675, 676, 0, 0, 0, 0, 0, 0, 0, + 1500, 1501, 0, 0, 0, 0, 0, 0, 0, 1503, + 713, 86, 87, 88, 412, 90, 91, 92, 413, 0, + 414, 95, 0, 0, 98, 99, 100, 101, 102, 103, + 714, 104, 105, 415, 715, 0, 107, 108, 109, 110, + 716, 717, 112, 113, 114, 115, 0, 116, 718, 719, + 416, 417, 0, 0, 0, 418, 419, 0, 0, 0, + 0, 420, 0, 0, 0, 0, 0, 0, 0, 0, + 421, 0, 422, 0, 423, 424, 35, 425, 0, 0, + 37, 38, 39, 40, 41, 42, 43, 44, 1435, 1436, + 1437, 45, 1438, 0, 0, 0, 426, 427, 428, 429, + 430, 431, 432, 433, 0, 434, 435, 436, 0, 0, + 0, 0, 1439, 0, 0, 437, 438, 0, 439, 440, + 133, 441, 442, 443, 135, 1440, 137, 1441, 1442, 0, + 444, 445, 446, 447, 448, 1443, 1444, 449, 450, 1445, + 1446, 452, 0, 453, 454, 455, 456, 1447, 0, 1448, + 0, 457, 458, 459, 460, 148, 461, 462, 0, 463, + 464, 465, 466, 467, 468, 0, 151, 469, 0, 1449, + 1450, 1451, 1452, 1453, 1454, 1455, 470, 471, 472, 473, + 474, 475, 1456, 1457, 476, 0, 477, 0, 478, 479, + 480, 481, 482, 0, 483, 484, 485, 0, 0, 486, + 487, 1458, 489, 490, 0, 491, 492, 493, 0, 494, + 495, 0, 496, 497, 498, 499, 1459, 500, 501, 502, + 1460, 1461, 503, 0, 504, 1462, 505, 0, 506, 0, + 507, 169, 0, 170, 508, 509, 510, 0, 511, 1463, + 0, 512, 0, 513, 514, 515, 516, 517, 173, 518, + 519, 520, 0, 521, 522, 523, 524, 525, 526, 0, + 527, 174, 175, 0, 528, 529, 530, 1464, 1465, 0, + 1466, 0, 531, 178, 179, 532, 180, 533, 534, 535, + 536, 537, 538, 539, 0, 540, 1467, 182, 541, 183, + 0, 542, 543, 544, 1468, 1469, 545, 546, 547, 548, + 549, 550, 551, 552, 553, 554, 555, 556, 1470, 189, + 1471, 557, 558, 191, 1472, 559, 560, 193, 561, 1473, + 1474, 562, 1475, 563, 564, 565, 0, 566, 0, 0, + 1476, 568, 569, 0, 0, 196, 197, 198, 199, 1477, + 570, 571, 572, 573, 574, 575, 576, 0, 577, 1478, + 578, 202, 579, 580, 581, 0, 582, 583, 584, 585, + 586, 587, 588, 1479, 589, 590, 591, 592, 0, 593, + 594, 595, 596, 597, 598, 599, 600, 601, 602, 0, + 603, 604, 210, 605, 606, 1480, 607, 608, 609, 610, + 611, 612, 613, 614, 0, 615, 616, 617, 618, 619, + 1481, 620, 217, 621, 622, 219, 623, 1482, 624, 0, + 625, 626, 627, 628, 629, 630, 631, 632, 633, 634, + 1483, 0, 635, 636, 0, 637, 638, 639, 640, 641, + 642, 0, 1484, 1485, 0, 0, 644, 1486, 645, 1487, + 1488, 646, 647, 648, 649, 650, 651, 652, 0, 1489, + 653, 654, 655, 656, 657, 1490, 0, 658, 659, 660, + 661, 662, 663, 1491, 0, 664, 235, 665, 666, 667, + 0, 0, 668, 0, 0, 669, 670, 671, 672, 673, + 237, 1492, 1493, 1494, 1495, 1496, 1497, 1498, 1499, 674, + 675, 676, 0, 0, 0, 0, 0, 0, 0, 1500, + 1501, 0, 0, 0, 0, 0, 0, 0, 1503, 713, + 86, 87, 88, 412, 90, 91, 92, 413, 0, 414, + 95, 0, 0, 98, 99, 100, 101, 102, 103, 714, + 104, 105, 415, 715, 0, 107, 108, 109, 110, 716, + 717, 112, 113, 114, 115, 0, 116, 718, 719, 416, + 417, 0, 0, 0, 418, 419, 0, 0, 0, 0, + 420, 0, 0, 0, 0, 0, 0, 0, 0, 421, + 0, 422, 0, 423, 424, 35, 425, 0, 0, 37, + 38, 39, 40, 41, 42, 43, 44, 1435, 1436, 1437, + 45, 1438, 0, 0, 0, 426, 427, 428, 429, 430, + 431, 432, 433, 0, 434, 435, 436, 0, 0, 0, + 0, 1439, 0, 0, 437, 438, 0, 439, 440, 133, + 441, 442, 443, 135, 1440, 137, 1441, 1442, 0, 444, + 445, 446, 447, 448, 1443, 1444, 449, 450, 1445, 1446, + 452, 0, 453, 454, 455, 456, 1447, 0, 1448, 0, + 457, 458, 459, 460, 148, 461, 462, 0, 463, 464, + 465, 466, 467, 468, 0, 151, 469, 0, 1449, 1450, + 1451, 1452, 1453, 1454, 1455, 470, 471, 472, 473, 474, + 475, 1456, 1457, 476, 0, 477, 0, 478, 479, 480, + 481, 482, 0, 483, 484, 485, 0, 0, 486, 487, + 1458, 489, 490, 0, 491, 492, 493, 0, 494, 495, + 0, 496, 497, 498, 499, 1459, 500, 501, 502, 1460, + 1461, 503, 0, 504, 1462, 505, 0, 506, 0, 507, + 169, 0, 170, 508, 509, 510, 0, 511, 1463, 0, + 512, 0, 513, 514, 515, 516, 517, 173, 518, 519, + 520, 0, 521, 522, 523, 524, 525, 526, 0, 527, + 174, 175, 0, 528, 529, 530, 1464, 1465, 0, 1466, + 0, 531, 178, 179, 532, 180, 533, 534, 535, 536, + 537, 538, 539, 0, 540, 1467, 182, 541, 183, 0, + 542, 543, 544, 1468, 1469, 545, 546, 547, 548, 549, + 550, 551, 552, 553, 554, 555, 556, 1470, 189, 1471, + 557, 558, 191, 1472, 559, 560, 193, 561, 1473, 1474, + 562, 1475, 563, 564, 565, 0, 566, 0, 0, 1476, + 568, 569, 0, 0, 196, 197, 198, 199, 1477, 570, + 571, 572, 573, 574, 575, 576, 0, 577, 1478, 578, + 202, 579, 580, 581, 0, 582, 583, 584, 585, 586, + 587, 588, 1479, 589, 590, 591, 592, 0, 593, 594, + 595, 596, 597, 598, 599, 600, 601, 602, 0, 603, + 604, 210, 605, 606, 1480, 607, 608, 609, 610, 611, + 612, 613, 614, 0, 615, 616, 617, 618, 619, 1481, + 620, 217, 621, 622, 219, 623, 1482, 624, 0, 625, + 626, 627, 628, 629, 630, 631, 632, 633, 634, 1483, + 0, 635, 636, 0, 637, 638, 639, 640, 641, 642, + 0, 1484, 1485, 0, 0, 644, 1486, 645, 1487, 1488, + 646, 647, 648, 649, 650, 651, 652, 0, 1489, 653, + 654, 655, 656, 657, 1490, 0, 658, 659, 660, 661, + 662, 663, 1491, 0, 664, 235, 665, 666, 667, 0, + 0, 668, 0, 0, 669, 670, 671, 672, 673, 4336, + 1492, 1493, 1494, 1495, 1496, 1497, 1498, 1499, 674, 675, + 676, 0, 0, 0, 0, 0, 0, 0, 1500, 1501, + 0, 0, 0, 0, 0, 0, 0, 1503, 713, 86, + 87, 88, 412, 90, 91, 92, 413, 0, 414, 95, + 0, 0, 98, 99, 100, 101, 102, 103, 714, 104, + 105, 415, 715, 0, 107, 108, 109, 110, 716, 717, + 112, 113, 114, 115, 0, 116, 718, 719, 416, 417, + 0, 0, 0, 418, 419, 0, 0, 0, 0, 420, + 0, 0, 0, 0, 0, 0, 0, 0, 421, 0, + 422, 0, 423, 424, 35, 425, 0, 0, 37, 38, + 39, 40, 41, 42, 43, 44, 1435, 1436, 1437, 45, + 1438, 0, 0, 0, 426, 427, 428, 429, 430, 431, + 432, 433, 0, 434, 435, 436, 0, 0, 0, 0, + 1439, 0, 0, 437, 438, 0, 439, 440, 133, 441, + 442, 443, 135, 1440, 137, 1441, 1442, 0, 444, 445, + 446, 447, 448, 1443, 1444, 449, 450, 1445, 1446, 452, + 0, 453, 454, 455, 456, 1447, 0, 1448, 0, 457, + 458, 459, 460, 148, 461, 462, 0, 463, 464, 465, + 466, 467, 468, 0, 151, 469, 0, 1449, 1450, 1451, + 1452, 1453, 1454, 1455, 470, 471, 472, 473, 474, 475, + 1456, 1457, 476, 0, 477, 0, 478, 479, 480, 481, + 482, 0, 483, 484, 485, 0, 0, 486, 487, 1458, + 489, 490, 0, 491, 492, 493, 0, 494, 495, 0, + 496, 497, 498, 499, 1459, 500, 501, 502, 1460, 1461, + 503, 0, 504, 1462, 505, 0, 506, 0, 507, 169, + 0, 170, 508, 509, 510, 0, 511, 1463, 0, 512, + 0, 513, 514, 515, 516, 517, 173, 518, 519, 520, + 0, 521, 522, 523, 524, 525, 526, 0, 527, 174, + 175, 0, 528, 529, 530, 1464, 1465, 0, 1466, 0, + 531, 178, 179, 532, 180, 533, 534, 535, 536, 537, + 538, 539, 0, 540, 1467, 182, 541, 183, 0, 542, + 543, 544, 1468, 1469, 545, 546, 547, 548, 549, 550, + 551, 552, 553, 554, 555, 556, 1470, 189, 1471, 557, + 4345, 191, 1472, 559, 560, 193, 561, 1473, 1474, 562, + 1475, 563, 564, 565, 0, 566, 0, 0, 1476, 568, + 569, 0, 0, 196, 197, 198, 199, 1477, 570, 571, + 572, 573, 574, 575, 576, 0, 577, 1478, 578, 202, + 579, 580, 581, 0, 582, 583, 584, 585, 586, 587, + 588, 1479, 589, 590, 591, 592, 0, 593, 594, 595, + 596, 597, 598, 599, 600, 601, 602, 0, 603, 604, + 210, 605, 606, 1480, 607, 608, 609, 610, 611, 612, + 613, 614, 0, 615, 616, 617, 618, 619, 1481, 620, + 217, 621, 622, 219, 623, 1482, 624, 0, 625, 626, + 627, 628, 629, 630, 631, 632, 633, 634, 1483, 0, + 635, 636, 0, 637, 638, 639, 640, 641, 642, 0, + 1484, 1485, 0, 0, 644, 1486, 645, 1487, 1488, 646, + 647, 648, 649, 650, 651, 652, 0, 1489, 653, 654, + 655, 656, 657, 1490, 0, 658, 659, 660, 661, 662, + 663, 1491, 0, 664, 235, 665, 666, 667, 0, 0, + 668, 0, 0, 669, 670, 671, 672, 673, 237, 1492, + 1493, 1494, 1495, 1496, 1497, 1498, 1499, 674, 675, 676, + 0, 0, 0, 0, 0, 0, 0, 1500, 1501, 0, + 0, 0, 0, 0, 0, 0, 1503, 713, 86, 87, + 88, 412, 90, 91, 92, 413, 0, 414, 95, 0, + 0, 98, 99, 100, 101, 102, 103, 714, 104, 105, + 415, 715, 0, 107, 108, 109, 110, 716, 717, 112, + 113, 114, 115, 0, 116, 718, 719, 416, 417, 0, + 0, 0, 418, 419, 0, 0, 0, 0, 420, 0, + 0, 0, 0, 0, 0, 0, 0, 421, 0, 422, + 0, 423, 424, 35, 425, 0, 0, 37, 38, 39, + 40, 41, 42, 43, 44, 1435, 1436, 1437, 45, 1438, + 0, 0, 0, 426, 427, 428, 429, 430, 431, 432, + 433, 0, 434, 435, 436, 0, 0, 0, 0, 1439, + 0, 0, 437, 438, 0, 439, 440, 133, 441, 442, + 443, 135, 1440, 137, 1441, 1442, 0, 444, 445, 446, + 447, 448, 1443, 1444, 449, 450, 1445, 1446, 452, 0, + 453, 454, 455, 456, 1447, 0, 1448, 0, 457, 458, + 459, 460, 148, 461, 462, 0, 463, 464, 465, 466, + 467, 468, 0, 151, 469, 0, 1449, 1450, 1451, 1452, + 1453, 1454, 1455, 470, 471, 472, 473, 474, 475, 1456, + 1457, 476, 0, 477, 0, 478, 479, 480, 481, 482, + 0, 483, 484, 485, 0, 0, 486, 487, 1458, 489, + 490, 0, 491, 492, 493, 0, 494, 495, 0, 496, + 497, 498, 499, 1459, 500, 501, 502, 1460, 1461, 503, + 0, 504, 1462, 505, 0, 506, 0, 507, 169, 0, + 170, 508, 509, 510, 0, 511, 1463, 0, 512, 0, + 513, 514, 515, 516, 517, 173, 518, 519, 520, 0, + 521, 522, 523, 524, 525, 526, 0, 527, 174, 175, + 0, 528, 529, 530, 1464, 1465, 0, 1466, 0, 531, + 178, 179, 532, 180, 533, 534, 535, 536, 537, 538, + 539, 0, 540, 1467, 182, 541, 183, 0, 542, 543, + 544, 1468, 1469, 545, 546, 547, 548, 549, 550, 551, + 552, 553, 554, 555, 556, 1470, 189, 1471, 557, 558, + 191, 0, 559, 560, 193, 561, 1473, 1474, 562, 1475, + 563, 564, 565, 0, 566, 0, 0, 1476, 568, 569, + 0, 0, 196, 197, 198, 199, 1477, 570, 571, 572, + 573, 574, 575, 576, 0, 577, 1478, 578, 202, 579, + 580, 581, 0, 582, 583, 584, 585, 586, 587, 588, + 1479, 589, 590, 591, 592, 0, 593, 594, 595, 596, + 597, 598, 599, 600, 601, 602, 0, 603, 604, 210, + 605, 606, 1480, 607, 608, 609, 610, 611, 612, 613, + 614, 0, 615, 616, 617, 618, 619, 1481, 620, 217, + 621, 622, 219, 623, 1482, 624, 0, 625, 626, 627, + 628, 629, 630, 631, 632, 633, 634, 1483, 0, 635, + 636, 0, 637, 638, 639, 640, 641, 642, 0, 1484, + 1485, 0, 0, 644, 1486, 645, 1487, 1488, 646, 647, + 648, 649, 650, 651, 652, 0, 0, 653, 654, 655, + 656, 657, 1490, 0, 658, 659, 660, 661, 662, 663, + 1491, 0, 664, 235, 665, 666, 667, 0, 0, 668, + 0, 0, 669, 670, 671, 672, 673, 237, 1492, 1493, + 1494, 1495, 1496, 1497, 1498, 1499, 674, 675, 676, 0, + 0, 0, 0, 0, 0, 0, 2804, 2805, 0, 0, + 0, 0, 0, 0, 0, 1503, 713, 86, 87, 88, + 412, 90, 91, 92, 413, 0, 414, 95, 0, 0, + 98, 99, 100, 101, 102, 103, 714, 104, 105, 415, + 715, 0, 107, 108, 109, 110, 716, 717, 112, 113, + 114, 115, 0, 116, 718, 719, 416, 417, 0, 0, + 0, 418, 419, 0, 0, 0, 0, 420, 0, 0, + 0, 0, 0, 0, 0, 0, 421, 0, 422, 0, + 423, 424, 35, 425, 0, 0, 37, 38, 39, 40, + 41, 42, 43, 44, 1435, 1436, 1437, 45, 1438, 0, + 0, 0, 426, 427, 428, 429, 430, 431, 432, 433, + 0, 434, 435, 436, 0, 0, 0, 0, 1439, 0, + 0, 437, 438, 0, 439, 440, 133, 441, 442, 443, + -2571, 1440, 137, 1441, 1442, 0, 444, 445, 446, 447, + 448, 1443, 1444, 449, 450, 1445, 1446, 452, 0, 453, + 454, 455, 456, 1447, 0, 1448, 0, 457, 458, 459, + 460, 148, 461, 462, 0, 463, 464, 465, 466, 467, + 468, 0, 151, 469, 4861, 1449, 1450, 1451, 1452, 1453, + 1454, 1455, 470, 471, 472, 473, 474, 475, 1456, 1457, + 476, 0, 477, 0, 478, 479, 480, 481, 482, 0, + 483, 484, 485, 0, 0, 486, 487, 1458, 489, 490, + 0, 491, 492, 493, 0, 494, 495, 0, 496, 497, + 498, 499, 1459, 500, 501, 502, 1460, 1461, 503, 0, + 504, 1462, 505, 0, 506, 0, 507, 169, 0, 170, + 508, 509, 510, 0, 511, 1463, 0, 512, 0, 513, + 514, 515, 516, 517, 0, 518, 519, 520, 0, 521, + 522, 523, 524, 525, 526, 0, 527, 174, 175, 0, + 528, 529, 530, 1464, 1465, 0, 1466, 0, 531, 178, + 179, 532, 180, 533, 534, 535, 536, 537, 538, 539, + 0, 540, 1467, 182, 541, 0, 0, 542, 543, 544, + 1468, 1469, 545, 546, 547, 548, 549, 550, 551, 552, + 553, 554, 555, 556, 1470, 189, 1471, 557, 558, 191, + 0, 559, 560, 193, 561, 1473, 1474, 562, 1475, 563, + 564, 565, 0, 566, 0, 0, 1476, 568, 569, 0, + 0, 196, 197, 198, 199, 1477, 570, 571, 572, 573, + 574, 575, 576, 0, 577, 1478, 578, 202, 579, 580, + 581, 0, 582, 583, 584, 585, 586, 587, 588, 1479, + 589, 590, 591, 592, 0, 593, 594, 595, 596, 597, + 598, 599, 600, 601, 602, 0, 603, 604, 210, 605, + 606, 1480, 607, 608, 609, 610, 611, 612, 613, 614, + 0, 615, 616, 617, 618, 619, 1481, 620, 217, 621, + 622, 0, 623, 1482, 624, 0, 625, 626, 627, 628, + 629, 630, 631, 632, 633, 634, 1483, 0, 635, 636, + 0, 637, 638, 639, 640, 641, 642, 0, 1484, 1485, + 0, 0, 644, 1486, 645, 1487, 1488, 646, 647, 648, + 649, 4862, 651, 652, 0, 1489, 653, 654, 655, 656, + 657, 1490, 0, 658, 659, 660, 661, 662, 663, 1491, + 0, 664, 235, 665, 666, 667, 0, 0, 668, 0, + 0, 669, 670, 671, 672, 673, 237, 1492, 1493, 1494, + 1495, 1496, 1497, 1498, 1499, 674, 675, 676, 0, 0, + 0, 0, 0, 0, 0, 1500, 1501, 0, 0, 0, + 0, 0, 0, 0, 1503, 713, 86, 87, 88, 412, + 90, 91, 92, 413, 0, 414, 95, 0, 0, 98, + 99, 100, 101, 102, 103, 714, 104, 105, 415, 715, + 0, 107, 108, 109, 110, 716, 717, 112, 113, 114, + 115, 0, 116, 718, 719, 416, 417, 0, 0, 0, + 418, 419, 0, 0, 0, 0, 420, 0, 0, 0, + 0, 0, 0, 0, 0, 421, 0, 422, 0, 423, + 424, 35, 425, 0, 0, 37, 38, 39, 40, 41, + 42, 43, 44, 1435, 1436, 0, 45, 1438, 0, 0, + 0, 426, 427, 428, 429, 430, 431, 432, 433, 0, + 434, 435, 436, 0, 0, 0, 0, 1439, 0, 0, + 437, 438, 0, 439, 440, 133, 441, 442, 443, 135, + 1440, 137, 1441, 1442, 0, 444, 445, 446, 447, 448, + 1443, 1444, 449, 450, 1445, 1446, 452, 0, 453, 454, + 455, 456, 1447, 0, 1448, 0, 457, 458, 459, 460, + 148, 461, 462, 0, 463, 464, 465, 466, 467, 468, + 0, 151, 469, 0, 1449, 1450, 1451, 1452, 1453, 1454, + 1455, 470, 471, 472, 473, 474, 475, 1456, 1457, 476, + 0, 477, 0, 478, 479, 480, 481, 482, 0, 483, + 484, 485, 0, 0, 486, 487, 1458, 489, 490, 0, + 491, 492, 493, 0, 494, 495, 0, 496, 497, 498, + 499, 1459, 500, 501, 502, 1460, 1461, 503, 0, 504, + 1462, 505, 0, 506, 0, 507, 169, 0, 170, 508, + 509, 510, 0, 511, 1463, 0, 512, 0, 513, 514, + 515, 516, 517, 173, 518, 519, 520, 0, 521, 522, + 523, 524, 525, 526, 0, 527, 174, 175, 0, 528, + 529, 530, 1464, 1465, 0, 1466, 0, 531, 178, 179, + 532, 180, 533, 534, 535, 536, 537, 538, 539, 0, + 540, 1467, 182, 541, 183, 0, 542, 543, 544, 1468, + 1469, 545, 546, 547, 548, 549, 550, 551, 552, 553, + 554, 555, 556, 1470, 189, 1471, 557, 558, 191, 0, + 559, 560, 193, 561, 1473, 1474, 562, 1475, 563, 564, + 565, 0, 566, 0, 0, 567, 568, 569, 0, 0, + 196, 197, 198, 199, 1477, 570, 571, 572, 573, 574, + 575, 576, 0, 577, 1478, 578, 202, 579, 580, 581, + 0, 582, 583, 584, 585, 586, 587, 588, 1479, 589, + 590, 591, 592, 0, 593, 594, 595, 596, 597, 598, + 599, 600, 601, 602, 0, 603, 604, 210, 605, 606, + 1480, 607, 608, 609, 610, 611, 612, 613, 614, 0, + 615, 616, 617, 618, 619, 1481, 620, 217, 621, 622, + 219, 623, 1482, 624, 0, 625, 626, 627, 628, 629, + 630, 631, 632, 633, 634, 1483, 0, 635, 636, 0, + 637, 638, 639, 640, 641, 642, 0, 1484, 1485, 0, + 0, 644, 1486, 645, 1487, 1488, 646, 647, 648, 649, + 650, 651, 652, 0, 0, 653, 654, 655, 656, 657, + 1490, 0, 658, 659, 660, 661, 662, 663, 1491, 0, + 664, 235, 665, 666, 667, 0, 0, 668, 0, 0, + 669, 670, 671, 672, 673, 237, 1492, 1493, 1494, 1495, + 1496, 1497, 1498, 1499, 674, 675, 676, 0, 0, 0, + 713, 86, 87, 88, 412, 90, 91, 92, 413, 0, + 414, 95, 0, 1503, 98, 99, 100, 101, 102, 103, + 714, 104, 105, 415, 715, 0, 107, 108, 109, 110, + 716, 717, 112, 113, 114, 115, 0, 116, 718, 719, + 416, 417, 0, 0, 0, 418, 419, 0, 0, 0, + 0, 420, 0, 0, 0, 0, 0, 0, 0, 0, + 421, 0, 422, 0, 423, 424, 35, 425, 0, 0, + 37, 38, 39, 40, 41, 42, 43, 44, 1435, 1436, + 0, 45, 1438, 0, 0, 0, 426, 427, 428, 429, + 430, 431, 432, 433, 0, 434, 435, 436, 0, 0, + 0, 0, 1439, 0, 0, 437, 438, 0, 439, 440, + 133, 441, 442, 443, 135, 1440, 137, 1441, 1442, 0, + 3964, 445, 446, 447, 448, 1443, 1444, 449, 450, 1445, + 1446, 452, 0, 453, 454, 455, 456, 1447, 0, 1448, + 0, 457, 458, 459, 460, 148, 461, 462, 0, 463, + 464, 465, 466, 467, 468, 0, 151, 469, 0, 1449, + 1450, 1451, 1452, 1453, 1454, 1455, 470, 471, 472, 473, + 474, 475, 1456, 1457, 476, 0, 477, 0, 478, 479, + 480, 481, 482, 0, 483, 484, 485, 0, 0, 486, + 487, 1458, 489, 490, 0, 491, 492, 493, 0, 494, + 495, 0, 496, 497, 498, 499, 1459, 500, 501, 502, + 1460, 1461, 503, 0, 504, 1462, 505, 0, 506, 0, + 507, 169, 0, 170, 508, 509, 510, 0, 511, 1463, + 0, 512, 0, 513, 514, 515, 516, 517, 173, 518, + 519, 520, 0, 521, 522, 523, 524, 525, 526, 0, + 527, 174, 175, 0, 528, 529, 530, 1464, 1465, 0, + 1466, 0, 531, 178, 179, 532, 180, 533, 534, 535, + 536, 537, 538, 539, 0, 540, 1467, 182, 541, 183, + 0, 542, 543, 544, 1468, 1469, 545, 546, 547, 548, + 549, 550, 551, 552, 553, 554, 555, 556, 1470, 189, + 1471, 557, 558, 191, 0, 559, 560, 193, 561, 1473, + 1474, 562, 1475, 563, 564, 565, 0, 566, 0, 0, + 567, 568, 569, 0, 0, 196, 197, 198, 199, 1477, + 570, 571, 572, 573, 574, 575, 576, 0, 577, 1478, + 578, 202, 579, 580, 581, 0, 582, 583, 584, 585, + 586, 587, 588, 1479, 589, 590, 591, 592, 0, 593, + 594, 595, 596, 597, 598, 599, 600, 601, 602, 0, + 603, 604, 210, 605, 606, 1480, 607, 608, 609, 610, + 611, 612, 613, 614, 0, 615, 616, 617, 618, 619, + 1481, 620, 217, 621, 622, 219, 623, 1482, 624, 0, + 625, 626, 627, 628, 629, 630, 631, 632, 633, 634, + 1483, 0, 635, 636, 0, 637, 638, 639, 640, 641, + 642, 0, 1484, 1485, 0, 0, 644, 1486, 645, 1487, + 1488, 646, 647, 648, 649, 650, 651, 652, 0, 0, + 653, 654, 655, 656, 657, 1490, 0, 658, 659, 660, + 661, 662, 663, 1491, 0, 664, 235, 665, 666, 667, + 0, 0, 668, 0, 0, 669, 670, 671, 672, 673, + 237, 1492, 1493, 1494, 1495, 1496, 1497, 1498, 1499, 674, + 675, 676, 0, 0, 0, 713, 86, 87, 88, 412, + 90, 91, 92, 413, 0, 414, 95, 0, 1503, 98, + 99, 100, 101, 102, 103, 714, 104, 105, 415, 715, + 0, 107, 108, 109, 110, 716, 717, 112, 113, 114, + 115, 0, 116, 718, 719, 416, 417, 0, 0, 0, + 418, 419, 0, 0, 0, 0, 420, 0, 0, 0, + 0, 0, 0, 0, 0, 421, 0, 422, 0, 423, + 424, 35, 425, 0, 0, 37, 38, 39, 40, 41, + 42, 43, 44, 1435, 1436, 1437, 45, 1438, 0, 0, + 0, 426, 427, 428, 429, 430, 431, 432, 433, 0, + 434, 435, 436, 0, 0, 0, 0, 1439, 0, 0, + 437, 438, 0, 439, 440, 133, 441, 442, 443, 0, + 1440, 137, 1441, 1442, 0, 444, 445, 446, 447, 448, + 1443, 1444, 449, 450, 1445, 1446, 452, 0, 453, 454, + 455, 456, 1447, 0, 1448, 0, 457, 458, 459, 460, + 148, 461, 462, 0, 463, 464, 465, 466, 467, 468, + 0, 151, 469, 0, 1449, 1450, 1451, 1452, 1453, 1454, + 1455, 470, 471, 472, 473, 474, 475, 1456, 1457, 476, + 0, 477, 0, 478, 479, 480, 481, 482, 0, 483, + 484, 485, 0, 0, 486, 487, 1458, 489, 490, 0, + 491, 492, 493, 0, 494, 0, 0, 496, 497, 498, + 499, 1459, 500, 501, 502, 1460, 1461, 503, 0, 504, + 1462, 505, 0, 506, 0, 507, 169, 0, 170, 508, + 509, 510, 0, 511, 1463, 0, 512, 0, 513, 514, + 515, 516, 517, 0, 518, 519, 520, 0, 521, 522, + 523, 524, 525, 526, 0, 527, 174, 175, 0, 528, + 529, 530, 1464, 1465, 0, 1466, 0, 531, 178, 179, + 532, 180, 533, 534, 535, 536, 537, 538, 539, 0, + 540, 1467, 182, 541, 0, 0, 542, 543, 544, 1468, + 1469, 545, 546, 547, 548, 549, 550, 551, 552, 553, + 554, 555, 556, 1470, 189, 1471, 557, 558, 191, 0, + 559, 560, 193, 561, 1473, 1474, 562, 1475, 563, 564, + 565, 0, 566, 0, 0, 1476, 568, 569, 0, 0, + 196, 197, 198, 199, 1477, 570, 571, 572, 573, 574, + 575, 576, 0, 577, 1478, 578, 202, 579, 580, 581, + 0, 582, 583, 584, 585, 586, 587, 588, 1479, 589, + 590, 591, 592, 0, 593, 594, 595, 596, 597, 598, + 599, 600, 601, 602, 0, 603, 604, 210, 605, 606, + 1480, 607, 608, 609, 610, 611, 612, 613, 614, 0, + 615, 616, 617, 618, 619, 1481, 620, 217, 621, 622, + 0, 623, 1482, 624, 0, 625, 626, 627, 628, 629, + 630, 631, 632, 633, 634, 1483, 0, 635, 636, 0, + 637, 638, 639, 640, 641, 642, 0, 1484, 1485, 0, + 0, 644, 1486, 645, 1487, 1488, 646, 647, 648, 649, + 650, 651, 652, 0, 1489, 653, 654, 655, 656, 657, + 1490, 0, 658, 659, 660, 661, 662, 663, 1491, 0, + 664, 235, 665, 666, 667, 0, 0, 668, 0, 0, + 669, 670, 671, 672, 673, 237, 1492, 1493, 1494, 1495, + 1496, 1497, 1498, 1499, 674, 675, 676, 0, 0, 0, + 0, 0, 0, 0, 1500, 1501, 0, 0, 0, 0, + 0, 0, 0, 1503, 713, 86, 87, 88, 412, 90, + 91, 92, 413, 0, 414, 95, 0, 0, 98, 99, + 100, 101, 102, 103, 714, 104, 105, 415, 715, 0, + 107, 108, 109, 110, 716, 717, 112, 113, 114, 115, + 0, 116, 718, 719, 416, 417, 0, 0, 0, 418, + 419, 0, 0, 0, 0, 420, 0, 0, 0, 0, + 0, 0, 0, 0, 421, 0, 422, 0, 423, 424, + 35, 425, 0, 0, 37, 38, 39, 40, 41, 42, + 43, 44, 1435, 1436, 1437, 45, 1438, 0, 0, 0, + 426, 427, 428, 429, 430, 431, 432, 433, 0, 434, + 435, 436, 0, 0, 0, 0, 1439, 0, 0, 437, + 438, 0, 439, 440, 133, 441, 442, 443, 0, 1440, + 137, 1441, 1442, 0, 444, 445, 446, 447, 448, 1443, + 1444, 449, 450, 1445, 1446, 452, 0, 453, 454, 455, + 456, 1447, 0, 1448, 0, 457, 458, 459, 460, 148, + 461, 462, 0, 463, 464, 465, 466, 467, 468, 0, + 151, 469, 0, 1449, 1450, 1451, 1452, 1453, 1454, 1455, + 470, 471, 472, 473, 474, 475, 1456, 1457, 476, 0, + 477, 0, 478, 479, 480, 481, 482, 0, 483, 484, + 485, 0, 0, 486, 487, 1458, 489, 490, 0, 491, + 492, 493, 0, 494, 0, 0, 496, 497, 498, 499, + 1459, 500, 501, 502, 1460, 1461, 503, 0, 504, 1462, + 505, 0, 506, 0, 507, 169, 0, 170, 508, 509, + 510, 0, 511, 1463, 0, 512, 0, 513, 514, 515, + 516, 517, 0, 518, 519, 520, 0, 521, 522, 523, + 524, 525, 526, 0, 527, 174, 175, 0, 528, 529, + 530, 1464, 1465, 0, 1466, 0, 531, 178, 179, 532, + 180, 533, 534, 535, 536, 537, 538, 539, 0, 540, + 1467, 182, 541, 0, 0, 542, 543, 544, 1468, 1469, + 545, 546, 547, 548, 549, 550, 551, 552, 553, 554, + 555, 556, 1470, 189, 1471, 557, 558, 191, 0, 559, + 560, 193, 561, 1473, 1474, 562, 1475, 563, 564, 565, + 0, 566, 0, 0, 1476, 568, 569, 0, 0, 196, + 197, 198, 199, 1477, 570, 571, 572, 573, 574, 575, + 576, 0, 577, 1478, 578, 202, 579, 580, 581, 0, + 582, 583, 584, 585, 586, 587, 588, 1479, 589, 590, + 591, 592, 0, 593, 594, 595, 596, 597, 598, 599, + 600, 601, 602, 0, 603, 604, 210, 605, 606, 1480, + 607, 608, 609, 610, 611, 612, 613, 614, 0, 615, + 616, 617, 618, 619, 1481, 620, 217, 621, 622, 0, + 623, 1482, 624, 0, 625, 626, 627, 628, 629, 630, + 631, 632, 633, 634, 1483, 0, 635, 636, 0, 637, + 638, 639, 640, 641, 642, 0, 1484, 1485, 0, 0, + 644, 1486, 645, 1487, 1488, 646, 647, 648, 649, 650, + 651, 652, 0, 0, 653, 654, 655, 656, 657, 1490, + 0, 658, 659, 660, 661, 662, 663, 1491, 0, 664, + 235, 665, 666, 667, 0, 0, 668, 0, 0, 669, + 670, 671, 672, 673, 237, 1492, 1493, 1494, 1495, 1496, + 1497, 1498, 1499, 674, 675, 676, 0, 0, 0, 0, + 0, 0, 0, 2804, 2805, 0, 0, 0, 0, 0, + 0, 0, 1503, 713, 86, 87, 88, 412, 90, 91, + 92, 413, 0, 414, 95, 0, 0, 98, 99, 100, + 101, 102, 103, 714, 104, 105, 415, 715, 0, 107, + 108, 109, 110, 716, 717, 112, 113, 114, 115, 0, + 116, 718, 719, 416, 417, 0, 0, 0, 418, 419, + 0, 0, 0, 0, 420, 0, 0, 0, 0, 0, + 0, 0, 0, 421, 0, 422, 0, 423, 424, 35, + 0, 0, 0, 0, 0, 0, 0, 41, 42, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 426, + 427, 428, 429, 430, 431, 432, 433, 0, 434, 435, + 436, 0, 0, 0, 0, 0, 0, 0, 437, 438, + 0, 439, 440, 133, 441, 442, 443, 135, 136, 137, + 138, 139, 0, 444, 445, 446, 447, 448, 0, 1444, + 449, 450, 451, 140, 452, 0, 453, 454, 455, 456, + 1447, 0, 1448, 0, 457, 458, 459, 460, 148, 461, + 462, 0, 463, 464, 465, 466, 467, 468, 0, 151, + 469, 0, 1449, 1450, 1451, 1452, 1453, 1454, 1455, 470, + 471, 472, 473, 474, 475, 155, 156, 476, 0, 477, + 0, 478, 479, 480, 481, 482, 0, 483, 484, 485, + 0, 0, 486, 487, 488, 489, 490, 0, 491, 492, + 493, 0, 494, 495, 0, 496, 497, 498, 499, 164, + 500, 501, 502, 1460, 0, 503, 0, 504, 168, 505, + 0, 506, 0, 507, 169, 0, 170, 508, 509, 510, + 0, 511, 1463, 0, 512, 0, 513, 514, 515, 516, + 517, 173, 518, 519, 520, 0, 521, 522, 523, 524, + 525, 526, 0, 527, 174, 175, 0, 528, 529, 530, + 0, 176, 0, 177, 0, 531, 178, 179, 532, 180, + 533, 534, 535, 536, 537, 538, 539, 0, 540, 1467, + 182, 541, 183, 0, 542, 543, 544, 1468, 1469, 545, + 546, 547, 548, 549, 550, 551, 552, 553, 554, 555, + 556, 188, 189, 190, 557, 558, 191, 0, 559, 560, + 193, 561, 0, 1474, 562, 195, 563, 564, 565, 0, + 566, 0, 1059, 567, 568, 569, 0, 0, 196, 197, + 198, 199, 1477, 570, 571, 572, 573, 574, 575, 576, + 0, 577, 1478, 578, 202, 579, 580, 581, 0, 582, + 583, 584, 585, 586, 587, 588, 204, 589, 590, 591, + 592, 0, 593, 594, 595, 596, 597, 598, 599, 600, + 601, 602, 0, 603, 604, 210, 605, 606, 212, 607, + 608, 609, 610, 611, 612, 613, 614, 215, 615, 616, + 617, 618, 619, 1481, 620, 217, 621, 622, 219, 623, + 220, 624, 0, 625, 626, 627, 628, 629, 630, 631, + 632, 633, 634, 1483, 0, 635, 636, 223, 637, 638, + 639, 640, 641, 642, 0, 224, 225, 0, 0, 644, + 1486, 645, 1487, 0, 646, 647, 648, 649, 650, 651, + 652, 0, 0, 653, 654, 655, 656, 657, 1490, 0, + 658, 659, 660, 661, 662, 1361, 234, 0, 664, 235, + 665, 666, 667, 0, 0, 668, 0, 236, 669, 670, + 671, 672, 673, 237, 1492, 1493, 1494, 1495, 1496, 1497, + 1498, 1499, 674, 675, 676, 0, 0, 0, 713, 86, + 87, 88, 412, 90, 91, 92, 413, 0, 414, 95, + 0, 3511, 98, 99, 100, 101, 102, 103, 714, 104, + 105, 415, 715, 0, 107, 108, 109, 110, 716, 717, + 112, 113, 114, 115, 0, 116, 718, 719, 416, 417, + 0, 0, 0, 418, 419, 0, 0, 0, 0, 420, + 0, 0, 0, 0, 0, 0, 0, 0, 421, 0, + 422, 0, 423, 424, 35, 0, 0, 0, 0, 0, + 0, 0, 41, 42, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 426, 427, 428, 429, 430, 431, + 432, 433, 0, 434, 435, 436, 0, 0, 0, 0, + 0, 0, 0, 437, 438, 0, 439, 440, 133, 441, + 442, 443, 135, 136, 137, 138, 139, 0, 444, 445, + 446, 447, 448, 0, 1444, 449, 450, 451, 140, 452, + 0, 453, 454, 455, 456, 1447, 0, 1448, 0, 457, + 458, 459, 460, 148, 461, 462, 0, 463, 464, 465, + 466, 467, 468, 0, 151, 469, 0, 1449, 1450, 1451, + 1452, 1453, 1454, 1455, 470, 471, 472, 473, 474, 475, + 155, 156, 476, 0, 477, 0, 478, 479, 480, 481, + 482, 0, 483, 484, 485, 0, 0, 486, 487, 488, + 489, 490, 0, 491, 492, 493, 0, 494, 495, 0, + 496, 497, 498, 499, 164, 500, 501, 502, 1460, 0, + 503, 0, 504, 168, 505, 0, 506, 0, 507, 169, + 0, 170, 508, 509, 510, 0, 511, 1463, 0, 512, + 0, 513, 514, 515, 516, 517, 173, 518, 519, 520, + 0, 521, 522, 523, 524, 525, 526, 0, 527, 174, + 175, 0, 528, 529, 530, 0, 176, 0, 177, 0, + 531, 178, 179, 532, 180, 533, 534, 535, 536, 537, + 538, 539, 0, 540, 1467, 182, 541, 183, 0, 542, + 543, 544, 1468, 1469, 545, 546, 547, 548, 549, 550, + 551, 552, 553, 554, 555, 556, 188, 189, 190, 557, + 558, 191, 0, 559, 560, 193, 561, 0, 1474, 562, + 195, 563, 564, 565, 0, 566, 0, 1059, 567, 568, + 569, 0, 0, 196, 197, 198, 199, 1477, 570, 571, + 572, 573, 574, 575, 576, 0, 577, 1478, 578, 202, + 579, 580, 581, 0, 582, 583, 584, 585, 586, 587, + 588, 204, 589, 590, 591, 592, 0, 593, 594, 595, + 596, 597, 598, 599, 600, 601, 602, 0, 603, 604, + 210, 605, 606, 212, 607, 608, 609, 610, 611, 612, + 613, 614, 0, 615, 616, 617, 618, 619, 1481, 620, + 217, 621, 622, 219, 623, 220, 624, 0, 625, 626, + 627, 628, 629, 630, 631, 632, 633, 634, 1483, 0, + 635, 636, 0, 637, 638, 639, 640, 641, 642, 0, + 224, 225, 0, 0, 644, 1486, 645, 1487, 0, 646, + 647, 648, 649, 650, 651, 652, 0, 0, 653, 654, + 655, 656, 657, 1490, 0, 658, 659, 660, 661, 662, + 663, 234, 0, 664, 235, 665, 666, 667, 0, 0, + 668, 0, 0, 669, 670, 671, 672, 673, 237, 1492, + 1493, 1494, 1495, 1496, 1497, 1498, 1499, 674, 675, 676, + 0, 0, 0, 713, 86, 87, 88, 412, 90, 91, + 92, 413, 0, 414, 95, 0, 3511, 98, 99, 100, + 101, 102, 103, 714, 104, 105, 415, 715, 0, 107, + 108, 109, 110, 716, 717, 112, 113, 114, 115, 0, + 116, 718, 719, 416, 417, 0, 0, 0, 418, 419, + 0, 0, 0, 0, 420, 0, 0, 0, 0, 0, + 0, 0, 0, 421, 0, 422, 0, 423, 424, 35, + 0, 0, 0, 0, 0, 0, 0, 41, 42, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 426, + 427, 428, 429, 430, 431, 432, 433, 0, 434, 435, + 436, 0, 0, 0, 0, 0, 0, 0, 437, 438, + 0, 439, 440, 133, 441, 442, 443, 135, 136, 137, + 138, 139, 0, 444, 445, 446, 447, 448, 0, 1444, + 449, 450, 451, 140, 452, 0, 453, 454, 455, 456, + 1447, 0, 1448, 0, 457, 458, 459, 460, 148, 461, + 462, 0, 463, 464, 465, 466, 467, 468, 0, 151, + 469, 0, 1449, 1450, 1451, 1452, 1453, 1454, 1455, 470, + 471, 472, 473, 474, 475, 155, 156, 476, 0, 477, + 0, 478, 479, 480, 481, 482, 0, 483, 484, 485, + 0, 0, 486, 487, 488, 489, 490, 0, 491, 492, + 493, 0, 494, 495, 0, 496, 497, 498, 499, 164, + 500, 501, 502, 1460, 0, 503, 0, 504, 168, 505, + 0, 506, 0, 507, 169, 0, 170, 508, 509, 510, + 0, 511, 1463, 0, 512, 0, 513, 514, 515, 516, + 517, 173, 518, 519, 520, 0, 521, 522, 523, 524, + 525, 526, 0, 527, 174, 175, 0, 528, 529, 530, + 0, 176, 0, 177, 0, 531, 178, 179, 532, 180, + 533, 534, 535, 536, 537, 538, 539, 0, 540, 1467, + 182, 541, 183, 0, 542, 543, 544, 1468, 1469, 545, + 546, 547, 548, 549, 550, 551, 552, 553, 554, 555, + 556, 188, 189, 190, 557, 558, 191, 0, 559, 560, + 193, 561, 0, 1474, 562, 195, 563, 564, 565, 0, + 566, 0, 0, 567, 568, 569, 0, 0, 196, 197, + 198, 199, 1477, 570, 571, 572, 573, 574, 575, 576, + 0, 577, 1478, 578, 202, 579, 580, 581, 0, 582, + 583, 584, 585, 586, 587, 588, 204, 589, 590, 591, + 592, 0, 593, 594, 595, 596, 597, 598, 599, 600, + 601, 602, 0, 603, 604, 210, 605, 606, 212, 607, + 608, 609, 610, 611, 612, 613, 614, 0, 615, 616, + 617, 618, 619, 1481, 620, 217, 621, 622, 219, 623, + 220, 624, 0, 625, 626, 627, 628, 629, 630, 631, + 632, 633, 634, 1483, 0, 635, 636, 0, 637, 638, + 639, 640, 641, 642, 0, 224, 225, 0, 0, 644, + 1486, 645, 1487, 0, 646, 647, 648, 649, 650, 651, + 652, 0, 0, 653, 654, 655, 656, 657, 1490, 0, + 658, 659, 660, 661, 662, 663, 234, 0, 664, 235, + 665, 666, 667, 0, 0, 668, 0, 0, 669, 670, + 671, 672, 673, 237, 1492, 1493, 1494, 1495, 1496, 1497, + 1498, 1499, 674, 675, 676, 0, 0, 0, 713, 86, + 87, 88, 412, 90, 91, 92, 413, 0, 414, 95, + 0, 4080, 98, 99, 100, 101, 102, 103, 714, 104, + 105, 415, 715, 0, 107, 108, 109, 110, 716, 717, + 112, 113, 114, 115, 0, 116, 718, 719, 416, 417, + 0, 0, 0, 418, 419, 0, 0, 0, 0, 420, + 0, 0, 0, 0, 0, 0, 0, 0, 421, 0, + 422, 0, 423, 424, 35, 0, 0, 0, 0, 0, + 0, 0, 41, 42, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 426, 427, 428, 429, 430, 431, + 432, 433, 0, 434, 435, 436, 0, 0, 0, 0, + 0, 0, 0, 437, 438, 0, 439, 440, 133, 441, + 442, 443, 135, 136, 137, 138, 139, 0, 444, 445, + 446, 447, 448, 0, 0, 449, 450, 451, 140, 452, + 0, 453, 454, 455, 456, 144, 0, 145, 0, 457, + 458, 459, 460, 148, 461, 462, 0, 463, 464, 465, + 466, 467, 468, 0, 151, 469, 0, 0, 0, 0, + 152, 0, 0, 0, 470, 471, 472, 473, 474, 475, + 155, 156, 476, 0, 477, 0, 478, 479, 480, 481, + 482, 0, 483, 484, 485, 0, 0, 486, 487, 488, + 489, 490, 0, 491, 492, 493, 0, 494, 495, 0, + 496, 497, 498, 499, 164, 500, 501, 502, 166, 0, + 503, 0, 504, 168, 505, 0, 506, 0, 507, 169, + 0, 170, 508, 509, 510, 0, 511, 172, 0, 512, + 0, 513, 514, 515, 516, 517, 173, 518, 519, 520, + 0, 521, 522, 523, 524, 525, 526, 0, 527, 174, + 175, 0, 528, 529, 530, 0, 176, 0, 177, 0, + 531, 178, 179, 532, 180, 533, 534, 535, 536, 537, + 538, 539, 0, 540, 181, 182, 541, 183, 0, 542, + 543, 544, 0, 0, 545, 546, 547, 548, 549, 550, + 551, 552, 553, 554, 555, 556, 188, 189, 190, 557, + 558, 191, 0, 559, 560, 193, 561, 0, 194, 562, + 195, 563, 564, 565, 0, 566, 0, 0, 567, 568, + 569, 0, 0, 196, 197, 198, 199, 200, 570, 571, + 572, 573, 574, 575, 576, 0, 577, 201, 578, 202, + 579, 580, 581, 0, 582, 583, 584, 585, 586, 587, + 588, 204, 589, 590, 591, 592, 0, 593, 594, 595, + 596, 597, 598, 599, 600, 601, 602, 0, 603, 604, + 210, 605, 606, 212, 607, 608, 609, 610, 611, 612, + 613, 614, 0, 615, 616, 617, 618, 619, 0, 620, + 217, 621, 622, 219, 623, 220, 624, 0, 625, 626, + 627, 628, 629, 630, 631, 632, 633, 634, 222, 0, + 635, 636, 0, 637, 638, 639, 640, 641, 642, 0, + 224, 225, 0, 0, 644, 226, 645, 227, 0, 646, + 647, 648, 649, 650, 651, 652, 0, 0, 653, 654, + 655, 656, 657, 0, 0, 658, 659, 660, 661, 662, + 663, 234, 0, 664, 235, 665, 666, 667, 0, 0, + 668, 0, 0, 669, 670, 671, 672, 673, 237, 238, + 239, 240, 241, 242, 243, 244, 245, 674, 675, 676, + 0, 0, 0, 0, 86, 87, 88, 412, 90, 91, + 92, 413, 0, 414, 95, 0, 4632, 98, 99, 100, + 101, 102, 103, 0, 104, 105, 415, 0, 0, 107, + 108, 109, 110, 0, 0, 112, 113, 114, 115, 0, + 116, 0, 0, 416, 417, 0, 0, 0, 418, 419, + 0, 0, 0, 0, 420, 0, 0, 0, 0, 0, + 0, 0, 0, 421, 0, 422, 0, 423, 424, 35, + 0, 0, 0, 0, 0, 0, 0, 41, 42, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 426, + 427, 428, 429, 430, 431, 432, 433, 0, 434, 435, + 436, 0, 0, 0, 0, 0, 4008, 0, 437, 438, + 0, 439, 440, 0, 441, 442, 443, 135, 136, 0, + 138, 139, 0, 444, 445, 446, 447, 448, 0, 0, + 449, 450, 451, 140, 452, 0, 453, 454, 455, 456, + 144, 0, 0, 0, 457, 458, 459, 460, 0, 461, + 462, 0, 463, 464, 465, 466, 467, 468, 0, -1428, + 469, 0, 0, 0, 0, 0, 0, 0, 0, 470, + 471, 472, 473, 474, 475, 155, 156, 476, 0, 477, + 0, 478, 479, 480, 481, 482, 0, 483, 484, 485, + 0, 0, 486, 487, 488, 489, 490, 0, 491, 492, + 493, 0, 494, 495, 0, 496, 497, 498, 499, 164, + 500, 501, 502, 166, 0, 503, 0, 504, 168, 505, + 0, 506, 0, 507, 0, 0, -1428, 508, 509, 510, + 0, 511, 172, 0, 512, 0, 513, 514, 515, 516, + 517, 0, 518, 519, 520, 0, 521, 522, 523, 524, + 525, 526, 0, 527, -1428, 175, 0, 528, 529, 530, + 0, 176, 0, 177, 0, 531, 0, 0, 532, -1428, + 533, 534, 535, 536, 537, 538, 539, 0, 540, 181, + -1428, 541, 0, 0, 542, 543, 544, 0, 0, 545, + 546, 547, 548, 549, 550, 551, 552, 553, 554, 555, + 556, 188, -1428, 190, 557, 558, 191, 0, 559, 560, + 0, 561, 0, 194, 562, 195, 563, 564, 565, 0, + 566, 0, 0, 567, 568, 569, 0, 0, 196, 0, + 0, 0, 200, 570, 571, 572, 573, 574, 575, 576, + 0, 577, 201, 578, 202, 579, 580, 581, 0, 582, + 583, 584, 585, 586, 587, 588, 204, 589, 590, 591, + 592, 0, 593, 594, 595, 596, 597, 598, 599, 600, + 601, 602, 0, 603, 604, -1428, 605, 606, 212, 607, + 608, 609, 610, 611, 612, 613, 614, 0, 615, 616, + 617, 618, 619, 0, 620, 217, 621, 622, 0, 623, + 220, 624, 0, 625, 626, 627, 628, 629, 630, 631, + 632, 633, 634, 222, 0, 635, 636, 0, 637, 638, + 639, 640, 641, 642, 0, 224, 225, 0, 0, 644, + 226, 645, 227, 0, 646, 647, 648, 649, 650, 651, + 652, 0, 0, 653, 654, 655, 656, 657, 0, 0, + 658, 659, 660, 661, 662, 663, 234, 0, 664, 0, + 665, 666, 667, 0, 0, 668, 0, 0, 669, 670, + 671, 672, 673, 237, 238, 239, 240, 241, 242, 243, + 244, 245, 674, 675, 676, 0, 0, 0, 0, 0, + 86, 87, 88, 412, 90, 91, 92, 413, 0, 414, + 95, 0, 1594, 98, 99, 100, 101, 102, 103, 0, + 104, 105, 415, 0, 0, 107, 108, 109, 110, 0, + 0, 112, 113, 114, 115, 0, 116, 0, 0, 416, + 417, 0, 0, 0, 418, 419, 0, 0, 0, 0, + 420, 0, 0, 0, 0, 0, 0, 0, 0, 421, + 0, 422, 0, 423, 424, 35, 0, 0, 0, 0, + 0, 0, 0, 41, 42, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 426, 427, 428, 429, 430, + 431, 432, 433, 0, 434, 435, 436, 0, 0, 0, + 0, 0, 0, 0, 437, 438, 0, 439, 440, 0, + 441, 442, 443, 135, 136, 0, 138, 139, 0, 444, + 445, 446, 447, 448, 0, 0, 449, 450, 451, 140, + 452, 0, 453, 454, 455, 456, 144, 0, 0, 0, + 457, 458, 459, 460, 0, 461, 462, 0, 463, 464, + 465, 466, 467, 468, 0, 0, 469, 0, 0, 0, + 0, 0, 0, 0, 0, 470, 471, 472, 473, 474, + 475, 155, 156, 476, 0, 477, 0, 478, 479, 480, + 481, 482, 0, 483, 484, 485, 0, 0, 486, 487, + 488, 489, 490, 0, 491, 492, 493, 0, 494, 495, + 0, 496, 497, 498, 499, 164, 500, 501, 502, 166, + 0, 503, 0, 504, 168, 505, 0, 506, 0, 507, + 0, 0, 0, 508, 509, 510, 0, 511, 172, 0, + 512, 0, 513, 514, 515, 516, 517, 0, 518, 519, + 520, 0, 521, 522, 523, 524, 525, 526, 0, 527, + 0, 175, 0, 528, 529, 530, 0, 176, 0, 177, + 0, 531, 0, 0, 532, 0, 533, 534, 535, 536, + 537, 538, 539, 0, 540, 181, 0, 541, 0, 0, + 542, 543, 544, 0, 0, 545, 546, 547, 548, 549, + 550, 551, 552, 553, 554, 555, 556, 188, 0, 190, + 557, 558, 191, 0, 559, 560, 0, 561, 0, 194, + 562, 195, 563, 564, 565, 0, 566, 0, 0, 567, + 568, 569, 0, 0, 196, 0, 0, 0, 200, 570, + 571, 572, 573, 574, 575, 576, 0, 577, 201, 578, + 202, 579, 580, 581, 0, 582, 583, 584, 585, 586, + 587, 588, 204, 589, 590, 591, 592, 0, 593, 594, + 595, 596, 597, 598, 599, 600, 601, 602, 0, 603, + 604, 0, 605, 606, 212, 607, 608, 609, 610, 611, + 612, 613, 614, 0, 615, 616, 617, 618, 619, 0, + 620, 217, 621, 622, 0, 623, 220, 624, 0, 625, + 626, 627, 628, 629, 630, 631, 632, 633, 634, 222, + 0, 635, 636, 0, 637, 638, 639, 640, 641, 642, + 0, 224, 225, 0, 0, 644, 226, 645, 227, 0, + 646, 647, 648, 649, 650, 651, 652, 0, 0, 653, + 654, 655, 656, 657, 0, 0, 658, 659, 660, 661, + 662, 663, 234, 0, 664, 0, 665, 666, 667, 0, + 0, 668, 0, 0, 669, 670, 671, 672, 673, 237, + 238, 239, 240, 241, 242, 243, 244, 245, 674, 675, + 676, 0, 0, 0, 0, 0, 86, 87, 88, 412, + 90, 91, 92, 413, 0, 414, 95, 0, 3272, 98, + 99, 100, 101, 102, 103, 0, 104, 105, 415, 0, + 0, 107, 108, 109, 110, 0, 0, 112, 113, 114, + 115, 0, 116, 0, 0, 416, 417, 0, 0, 0, + 418, 419, 0, 0, 0, 0, 420, 0, 0, 0, + 0, 0, 0, 0, 0, 421, 0, 422, 0, 423, + 424, 35, 425, 0, 0, 37, 38, 39, 40, 41, + 42, 43, 44, 0, 0, 0, 45, 0, 0, 0, + 0, 426, 427, 428, 429, 430, 431, 432, 433, 0, + 434, 435, 436, 0, 0, 0, 0, 0, 0, 0, + 437, 438, 0, 439, 440, 0, 441, 442, 443, 135, + 136, 0, 138, 139, 0, 444, 445, 446, 447, 448, + 0, 0, 449, 450, 451, 140, 452, 0, 453, 454, + 455, 456, 144, 0, 0, 0, 457, 458, 459, 460, + 0, 461, 462, 0, 463, 464, 465, 466, 467, 468, + 0, 0, 469, 0, 0, 0, 0, 0, 0, 0, + 0, 470, 471, 472, 473, 474, 475, 155, 156, 476, + 0, 477, 0, 478, 479, 480, 481, 482, 0, 483, + 484, 485, 0, 0, 486, 487, 488, 489, 490, 0, + 491, 492, 493, 0, 494, 495, 0, 496, 497, 498, + 499, 164, 500, 501, 502, 166, 2008, 503, 0, 504, + 168, 505, 0, 506, 0, 507, 0, 0, 0, 508, + 509, 510, 0, 511, 172, 0, 512, 0, 513, 514, + 515, 516, 517, 0, 518, 519, 520, 0, 521, 522, + 523, 524, 525, 526, 0, 527, 0, 175, 0, 528, + 529, 530, 0, 176, 0, 177, 0, 531, 0, 0, + 532, 0, 533, 534, 535, 536, 537, 538, 539, 0, + 540, 181, 0, 541, 0, 0, 542, 543, 544, 0, + 0, 545, 546, 547, 548, 549, 550, 551, 552, 553, + 554, 555, 556, 188, 0, 190, 557, 558, 191, 0, + 559, 560, 0, 561, 0, 194, 562, 195, 563, 564, + 565, 0, 566, 2009, 0, 567, 568, 569, 0, 0, + 196, 0, 0, 0, 200, 570, 571, 572, 573, 574, + 575, 576, 0, 577, 201, 578, 202, 579, 580, 581, + 0, 582, 583, 584, 585, 586, 587, 588, 204, 589, + 590, 591, 592, 0, 593, 594, 595, 596, 597, 598, + 599, 600, 601, 602, 0, 603, 604, 0, 605, 606, + 212, 607, 608, 609, 610, 611, 612, 613, 614, 0, + 615, 616, 617, 618, 619, 0, 620, 217, 621, 622, + 0, 623, 220, 624, 0, 625, 626, 627, 628, 629, + 630, 631, 632, 633, 634, 222, 0, 635, 636, 0, + 637, 638, 639, 640, 641, 642, 0, 224, 225, 0, + 0, 644, 226, 645, 227, 2010, 646, 647, 648, 649, + 650, 651, 652, 0, 0, 653, 654, 655, 656, 657, + 0, 0, 658, 659, 660, 661, 662, 663, 234, 0, + 664, 0, 665, 666, 667, 0, 0, 668, 0, 0, + 669, 670, 671, 672, 673, 237, 238, 239, 240, 241, + 242, 243, 244, 245, 674, 675, 676, 0, 0, 0, + 0, 0, 0, 0, 976, 1637, 4203, 0, 0, 0, + 0, 0, 0, 4204, 86, 87, 88, 412, 90, 91, + 92, 413, 0, 414, 95, 0, 0, 98, 99, 100, + 101, 102, 103, 0, 104, 105, 415, 0, 0, 107, + 108, 109, 110, 0, 0, 112, 113, 114, 115, 0, + 116, 0, 0, 416, 417, 0, 0, 0, 418, 419, + 0, 0, 0, 0, 420, 0, 0, 0, 0, 0, + 0, 0, 0, 421, 0, 422, 0, 423, 424, 35, + 0, 0, 0, 37, 38, 39, 40, 41, 42, 0, + 44, 0, 0, 0, 45, 0, 0, 0, 0, 426, + 427, 428, 429, 430, 431, 432, 433, 0, 434, 435, + 436, 0, 0, 0, 0, 0, 0, 0, 437, 438, + 0, 439, 440, 0, 441, 442, 443, 135, 136, 0, + 138, 139, 0, 444, 445, 446, 447, 448, 0, 0, + 449, 450, 451, 140, 452, 0, 453, 454, 455, 456, + 144, 0, 0, 0, 457, 458, 459, 460, 0, 461, + 462, 0, 463, 464, 465, 466, 467, 468, 0, 0, + 469, 0, 0, 0, 0, 0, 0, 0, 0, 470, + 471, 472, 473, 474, 475, 155, 156, 476, 0, 477, + 0, 478, 479, 480, 481, 482, 0, 483, 484, 485, + 0, 0, 486, 487, 488, 489, 490, 0, 491, 492, + 493, 0, 494, 495, 0, 496, 497, 498, 499, 164, + 500, 501, 502, 166, 0, 503, 0, 504, 168, 505, + 0, 506, 0, 507, 0, 0, 0, 508, 509, 510, + 0, 511, 172, 0, 512, 0, 513, 514, 515, 516, + 517, 0, 518, 519, 520, 0, 521, 522, 523, 524, + 525, 526, 0, 527, 0, 175, 0, 528, 529, 530, + 0, 176, 0, 177, 0, 531, 0, 0, 532, 0, + 533, 534, 535, 536, 537, 538, 539, 0, 540, 181, + 0, 541, 0, 0, 542, 543, 544, 0, 0, 545, + 546, 547, 548, 549, 550, 551, 552, 553, 554, 555, + 556, 188, 0, 190, 557, 558, 191, 0, 559, 560, + 0, 561, 0, 194, 562, 195, 563, 564, 565, 0, + 566, 0, 0, 567, 568, 569, 0, 0, 196, 0, + 0, 0, 200, 570, 571, 572, 573, 574, 575, 576, + 0, 577, 201, 578, 202, 579, 580, 581, 0, 582, + 583, 584, 585, 586, 587, 588, 204, 589, 590, 591, + 592, 0, 593, 594, 595, 596, 597, 598, 599, 600, + 601, 602, 0, 603, 604, 0, 605, 606, 212, 607, + 608, 609, 610, 611, 612, 613, 614, 0, 615, 616, + 617, 618, 619, 0, 620, 217, 621, 622, 0, 623, + 220, 624, 0, 625, 626, 627, 628, 629, 630, 631, + 632, 633, 634, 222, 0, 635, 636, 0, 637, 638, + 639, 640, 641, 642, 0, 224, 225, 0, 0, 644, + 226, 645, 227, 0, 646, 647, 648, 649, 650, 651, + 652, 0, 0, 653, 654, 655, 656, 657, 0, 0, + 658, 659, 660, 661, 662, 663, 234, 0, 664, 0, + 665, 666, 667, 0, 0, 668, 0, 0, 669, 670, + 671, 672, 673, 237, 238, 239, 240, 241, 242, 243, + 244, 245, 674, 675, 676, 0, 0, 0, 0, 86, + 87, 88, 412, 90, 91, 92, 413, 0, 414, 95, + 3786, 3787, 98, 99, 100, 101, 102, 103, 0, 104, + 105, 415, 0, 0, 107, 108, 109, 110, 0, 0, + 112, 113, 114, 115, 0, 116, 0, 0, 416, 417, + 0, 0, 0, 418, 419, 0, 0, 0, 0, 420, + 0, 0, 0, 0, 0, 0, 0, 0, 421, 0, + 422, 0, 423, 424, 35, 0, 0, 0, 0, 0, + 0, 0, 41, 42, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 426, 427, 428, 429, 430, 431, + 432, 433, 0, 434, 435, 436, 130, 131, 0, 0, + 0, 0, 0, 437, 438, 0, 439, 440, 0, 441, + 442, 443, 135, 136, 0, 138, 139, 0, 444, 445, + 446, 447, 448, 0, 0, 449, 450, 451, 140, 452, + 0, 453, 454, 455, 456, 144, 0, 0, 0, 457, + 458, 459, 460, 0, 461, 462, 0, 463, 464, 465, + 466, 467, 468, 0, 0, 469, 0, 0, 0, 0, + 0, 0, 0, 0, 470, 471, 472, 473, 474, 475, + 155, 156, 476, 0, 477, 0, 478, 479, 480, 481, + 482, 0, 483, 484, 485, 0, 0, 486, 487, 488, + 489, 490, 0, 491, 492, 493, 0, 494, 495, 0, + 496, 497, 498, 499, 164, 500, 501, 502, 166, 0, + 503, 0, 504, 168, 505, 0, 506, 0, 507, 0, + 0, 0, 508, 509, 510, 0, 511, 172, 0, 512, + 0, 513, 514, 515, 516, 517, 0, 518, 519, 520, + 0, 521, 522, 523, 524, 525, 526, 0, 527, 0, + 175, 0, 528, 529, 530, 0, 176, 0, 177, 0, + 531, 0, 0, 532, 0, 533, 534, 535, 536, 537, + 538, 539, 0, 540, 181, 0, 541, 0, 0, 542, + 543, 544, 0, 0, 545, 546, 547, 548, 549, 550, + 551, 552, 553, 554, 555, 556, 188, 0, 190, 557, + 558, 191, 0, 559, 560, 0, 561, 0, 194, 562, + 195, 563, 564, 565, 0, 566, 0, 0, 567, 568, + 569, 0, 0, 196, 0, 0, 0, 200, 570, 571, + 572, 573, 574, 575, 576, 0, 577, 201, 578, 202, + 579, 580, 581, 0, 582, 583, 584, 585, 586, 587, + 588, 204, 589, 590, 591, 592, 0, 593, 594, 595, + 596, 597, 598, 599, 600, 601, 602, 0, 603, 604, + 0, 605, 606, 212, 607, 608, 609, 610, 611, 612, + 613, 614, 215, 615, 616, 617, 618, 619, 0, 620, + 217, 621, 622, 0, 623, 220, 624, 0, 625, 626, + 627, 628, 629, 630, 631, 632, 633, 634, 222, 0, + 635, 636, 223, 637, 638, 639, 640, 641, 642, 0, + 224, 225, 0, 0, 644, 226, 645, 227, 0, 646, + 647, 648, 649, 650, 651, 652, 0, 0, 653, 654, + 655, 656, 657, 0, 0, 658, 659, 660, 661, 662, + 1361, 234, 0, 664, 1362, 665, 666, 667, 0, 0, + 668, 0, 236, 669, 670, 671, 672, 673, 237, 238, + 239, 240, 241, 242, 243, 244, 245, 674, 675, 676, + 0, 0, 0, 0, 86, 87, 88, 412, 90, 91, + 92, 413, 0, 414, 95, 0, 246, 98, 99, 100, + 101, 102, 103, 0, 104, 105, 415, 0, 0, 107, + 108, 109, 110, 0, 0, 112, 113, 114, 115, 0, + 116, 0, 0, 416, 417, 0, 0, 0, 418, 419, + 0, 0, 0, 0, 420, 0, 0, 0, 0, 0, + 0, 0, 0, 421, 0, 422, 0, 423, 424, 35, + 0, 0, 0, 37, 38, 39, 40, 41, 42, 0, + 44, 0, 0, 0, 45, 0, 0, 0, 0, 426, + 427, 428, 429, 430, 431, 432, 433, 0, 434, 435, + 436, 0, 0, 0, 0, 0, 0, 0, 437, 438, + 0, 439, 440, 0, 441, 442, 443, 135, 136, 0, + 138, 139, 0, 444, 445, 446, 447, 448, 0, 0, + 449, 450, 451, 140, 452, 0, 453, 454, 455, 456, + 144, 0, 0, 0, 457, 458, 459, 460, 0, 461, + 462, 0, 463, 464, 465, 466, 467, 468, 0, 0, + 469, 0, 0, 0, 0, 0, 0, 0, 0, 470, + 471, 472, 473, 474, 475, 155, 156, 476, 0, 477, + 0, 478, 479, 480, 481, 482, 0, 483, 484, 485, + 0, 0, 486, 487, 488, 489, 490, 0, 491, 492, + 493, 0, 494, 495, 0, 496, 497, 498, 499, 164, + 500, 501, 502, 166, 0, 503, 0, 504, 168, 505, + 0, 506, 0, 507, 0, 0, 0, 508, 509, 510, + 0, 511, 172, 0, 512, 0, 513, 514, 515, 516, + 517, 0, 518, 519, 520, 0, 521, 522, 523, 524, + 525, 526, 0, 527, 0, 175, 0, 528, 529, 530, + 0, 176, 0, 177, 0, 531, 0, 0, 532, 0, + 533, 534, 535, 536, 537, 538, 539, 0, 540, 181, + 0, 541, 0, 0, 542, 543, 544, 0, 0, 545, + 546, 547, 548, 549, 550, 551, 552, 553, 554, 555, + 556, 188, 0, 190, 557, 558, 191, 0, 559, 560, + 0, 561, 0, 194, 562, 195, 563, 564, 565, 0, + 566, 0, 0, 567, 568, 569, 0, 0, 196, 0, + 0, 0, 200, 570, 571, 572, 573, 574, 575, 576, + 0, 577, 201, 578, 202, 579, 580, 581, 0, 582, + 583, 584, 585, 586, 587, 588, 204, 589, 590, 591, + 592, 0, 593, 594, 595, 596, 597, 598, 599, 600, + 601, 602, 0, 603, 604, 0, 605, 606, 212, 607, + 608, 609, 610, 611, 612, 613, 614, 0, 615, 616, + 617, 618, 619, 0, 620, 217, 621, 622, 0, 623, + 220, 624, 0, 625, 626, 627, 628, 629, 630, 631, + 632, 633, 634, 222, 0, 635, 636, 0, 637, 638, + 639, 640, 641, 642, 0, 224, 225, 0, 0, 644, + 226, 645, 227, 0, 646, 647, 648, 649, 650, 651, + 652, 0, 0, 653, 654, 655, 656, 657, 0, 0, + 658, 659, 660, 661, 662, 663, 234, 0, 664, 0, + 665, 666, 667, 0, 0, 668, 0, 0, 669, 670, + 671, 672, 673, 237, 238, 239, 240, 241, 242, 243, + 244, 245, 674, 675, 676, 0, 0, 0, 0, 86, + 87, 88, 412, 90, 91, 92, 413, 0, 414, 95, + 0, 3787, 98, 99, 100, 101, 102, 103, 0, 104, + 105, 415, 0, 0, 107, 108, 109, 110, 0, 0, + 112, 113, 114, 115, 0, 116, 0, 0, 416, 417, + 0, 0, 0, 418, 419, 0, 0, 0, 0, 420, + 0, 0, 0, 0, 0, 0, 0, 0, 421, 0, + 422, 0, 423, 424, 35, 425, 0, 0, 0, 0, + 0, 0, 41, 42, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 426, 427, 428, 429, 430, 431, + 432, 433, 0, 434, 435, 436, 0, 0, 0, 0, + 0, 0, 0, 437, 438, 0, 439, 440, 0, 441, + 442, 443, 135, 136, 0, 138, 139, 0, 444, 445, + 446, 447, 448, 0, 0, 449, 450, 451, 140, 452, + 0, 453, 454, 455, 456, 144, 0, 0, 0, 457, + 458, 459, 460, 0, 461, 462, 0, 463, 464, 465, + 466, 467, 468, 0, 0, 469, 0, 0, 0, 0, + 0, 0, 0, 0, 470, 471, 472, 473, 474, 475, + 155, 156, 476, 0, 477, 0, 478, 479, 480, 481, + 482, 0, 483, 484, 485, 0, 0, 486, 487, 488, + 489, 490, 0, 491, 492, 493, 0, 494, 495, 0, + 496, 497, 498, 499, 164, 500, 501, 502, 166, 0, + 503, 0, 504, 168, 505, 0, 506, 0, 507, 0, + 0, 0, 508, 509, 510, 0, 511, 172, 0, 512, + 0, 513, 514, 515, 516, 517, 0, 518, 519, 520, + 0, 521, 522, 523, 524, 525, 526, 0, 527, 0, + 175, 0, 528, 529, 530, 0, 176, 0, 177, 0, + 531, 0, 0, 532, 0, 533, 534, 535, 536, 537, + 538, 539, 0, 540, 181, 0, 541, 0, 0, 542, + 543, 544, 0, 0, 545, 546, 547, 548, 549, 550, + 551, 552, 553, 554, 555, 556, 188, 0, 190, 557, + 558, 191, 0, 559, 560, 0, 561, 0, 194, 562, + 195, 563, 564, 565, 0, 566, 0, 0, 567, 568, + 569, 0, 0, 196, 0, 0, 0, 200, 570, 571, + 572, 573, 574, 575, 576, 0, 577, 201, 578, 202, + 579, 580, 581, 0, 582, 583, 584, 585, 586, 587, + 588, 204, 589, 590, 591, 592, 0, 593, 594, 595, + 596, 597, 598, 599, 600, 601, 602, 0, 603, 604, + 0, 605, 606, 212, 607, 608, 609, 610, 611, 612, + 613, 614, 215, 615, 616, 617, 618, 619, 0, 620, + 217, 621, 622, 0, 623, 220, 624, 0, 625, 626, + 627, 628, 629, 630, 631, 632, 633, 634, 222, 0, + 635, 636, 223, 637, 638, 639, 640, 641, 642, 0, + 224, 225, 0, 0, 644, 226, 645, 227, 0, 646, + 647, 648, 649, 650, 651, 652, 0, 0, 653, 654, + 655, 656, 657, 0, 0, 658, 659, 660, 661, 662, + 1361, 234, 0, 664, 0, 665, 666, 667, 0, 0, + 668, 0, 236, 669, 670, 671, 672, 673, 237, 238, + 239, 240, 241, 242, 243, 244, 245, 674, 675, 676, + 0, 0, 0, 0, 86, 87, 88, 412, 90, 91, + 92, 413, 0, 414, 95, 0, 246, 98, 99, 100, + 101, 102, 103, 0, 104, 105, 415, 0, 0, 107, + 108, 109, 110, 0, 0, 112, 113, 114, 115, 0, + 116, 0, 0, 416, 417, 0, 0, 0, 418, 419, + 0, 0, 0, 0, 420, 0, 0, 0, 0, 0, + 0, 0, 0, 421, 0, 422, 0, 423, 424, 35, + 0, 0, 0, 0, 0, 0, 0, 41, 42, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 426, + 427, 428, 429, 430, 431, 432, 433, 0, 434, 435, + 436, 0, 0, 0, 0, 0, 0, 0, 437, 438, + 0, 439, 440, 0, 441, 442, 443, 135, 136, 0, + 138, 139, 0, 444, 445, 446, 447, 448, 0, 0, + 449, 450, 451, 140, 452, 0, 453, 454, 455, 456, + 144, 0, 0, 0, 457, 458, 459, 460, 0, 461, + 462, 0, 463, 464, 465, 466, 467, 468, 0, 0, + 469, 0, 0, 0, 0, 0, 0, 0, 0, 470, + 471, 472, 473, 474, 475, 155, 156, 476, 0, 477, + 0, 478, 479, 480, 481, 482, 0, 483, 484, 485, + 0, 0, 486, 487, 488, 489, 490, 0, 491, 492, + 493, 0, 494, 495, 0, 496, 497, 498, 499, 164, + 500, 501, 502, 166, 0, 503, 0, 504, 168, 505, + 0, 506, 0, 507, 0, 0, 0, 508, 509, 510, + 0, 511, 172, 0, 512, 0, 513, 514, 515, 516, + 517, 0, 518, 519, 520, 0, 521, 522, 523, 524, + 525, 526, 0, 527, 0, 175, 0, 528, 529, 530, + 0, 176, 0, 177, 0, 531, 0, 0, 532, 0, + 533, 534, 535, 536, 537, 538, 539, 0, 540, 181, + 0, 541, 0, 0, 542, 543, 544, 0, 0, 545, + 546, 547, 548, 549, 550, 551, 552, 553, 554, 555, + 556, 188, 0, 190, 557, 558, 191, 0, 559, 560, + 0, 561, 0, 194, 562, 195, 563, 564, 565, 0, + 566, 0, 0, 567, 568, 569, 0, 0, 196, 0, + 0, 0, 200, 570, 571, 572, 573, 574, 575, 576, + 0, 577, 201, 578, 202, 579, 580, 581, 0, 582, + 583, 584, 585, 586, 587, 588, 204, 589, 590, 591, + 592, 0, 593, 594, 595, 596, 597, 598, 599, 600, + 601, 602, 0, 603, 604, 0, 605, 606, 212, 607, + 608, 609, 610, 611, 612, 613, 614, 215, 615, 616, + 617, 618, 619, 0, 620, 217, 621, 622, 0, 623, + 220, 624, 0, 625, 626, 627, 628, 629, 630, 631, + 632, 633, 634, 222, 0, 635, 636, 223, 637, 638, + 639, 640, 641, 642, 0, 224, 225, 0, 0, 644, + 226, 645, 227, 0, 646, 647, 648, 649, 650, 651, + 652, 0, 0, 653, 654, 655, 656, 657, 0, 0, + 658, 659, 660, 661, 662, 1361, 234, 0, 664, 0, + 665, 666, 667, 0, 0, 668, 0, 236, 669, 670, + 671, 672, 673, 237, 238, 239, 240, 241, 242, 243, + 244, 245, 674, 675, 676, 0, 0, 0, 0, 86, + 87, 88, 412, 90, 91, 92, 413, 0, 414, 95, + 0, 246, 98, 99, 100, 101, 102, 103, 0, 104, + 105, 415, 0, 0, 107, 108, 109, 110, 0, 0, + 112, 113, 114, 115, 0, 116, 0, 0, 416, 417, + 0, 0, 0, 418, 419, 0, 0, 0, 0, 420, + 0, 0, 0, 0, 0, 0, 0, 0, 421, 0, + 422, 0, 423, 424, 35, 0, 0, 0, 0, 0, + 0, 0, 41, 42, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 426, 427, 428, 429, 430, 431, + 432, 433, 0, 434, 435, 436, 0, 0, 0, 0, + 0, 0, 0, 437, 438, 0, 439, 440, 0, 441, + 442, 443, 135, 136, 0, 138, 139, 0, 444, 445, + 446, 447, 448, 0, 0, 449, 450, 451, 140, 452, + 0, 453, 454, 455, 456, 144, 0, 0, 0, 457, + 458, 459, 460, 0, 461, 462, 0, 463, 464, 465, + 466, 467, 468, 0, 0, 469, 0, 0, 0, 0, + 0, 0, 0, 0, 470, 471, 472, 473, 474, 475, + 155, 156, 476, 0, 477, 0, 478, 479, 480, 481, + 482, 0, 483, 484, 485, 0, 0, 486, 487, 488, + 489, 490, 0, 491, 492, 493, 0, 494, 495, 0, + 496, 497, 498, 499, 164, 500, 501, 502, 166, 0, + 503, 0, 504, 168, 505, 0, 506, 0, 507, 0, + 0, 0, 508, 509, 510, 0, 511, 172, 0, 512, + 0, 513, 514, 515, 516, 517, 0, 518, 519, 520, + 0, 521, 522, 523, 524, 525, 526, 0, 527, 0, + 175, 0, 528, 529, 530, 0, 176, 0, 177, 0, + 531, 0, 0, 532, 0, 533, 534, 535, 536, 537, + 538, 539, 0, 540, 181, 0, 541, 0, 0, 542, + 543, 544, 0, 0, 545, 546, 547, 548, 549, 550, + 551, 552, 553, 554, 555, 556, 188, 0, 190, 557, + 558, 191, 0, 559, 560, 0, 561, 0, 194, 562, + 195, 563, 564, 565, 0, 566, 0, 0, 567, 568, + 569, 0, 0, 196, 0, 0, 0, 200, 570, 571, + 572, 573, 574, 575, 576, 0, 577, 201, 578, 202, + 579, 580, 581, 0, 582, 583, 584, 585, 586, 587, + 588, 204, 589, 590, 591, 592, 0, 593, 594, 595, + 596, 597, 598, 599, 600, 601, 602, 0, 603, 604, + 0, 605, 606, 212, 607, 608, 609, 610, 611, 612, + 613, 614, 0, 615, 616, 617, 618, 619, 0, 620, + 217, 621, 622, 0, 623, 220, 624, 0, 625, 626, + 627, 628, 629, 630, 631, 632, 633, 634, 222, 0, + 635, 636, 0, 637, 638, 639, 640, 641, 642, 0, + 224, 225, 0, 0, 644, 226, 645, 227, 0, 646, + 647, 648, 649, 650, 651, 652, 0, 0, 653, 654, + 655, 656, 657, 0, 0, 658, 659, 660, 661, 662, + 663, 234, 0, 664, 0, 665, 666, 667, 0, 0, + 668, 0, 0, 669, 670, 671, 672, 673, 237, 238, + 239, 240, 241, 242, 243, 244, 245, 674, 675, 676, + 0, 0, 0, 0, 86, 87, 88, 412, 90, 91, + 92, 413, 0, 414, 95, 0, 1569, 98, 99, 100, + 101, 102, 103, 0, 104, 105, 415, 0, 0, 107, + 108, 109, 110, 0, 0, 112, 113, 114, 115, 0, + 116, 0, 0, 416, 417, 0, 0, 0, 418, 419, + 0, 0, 0, 0, 420, 0, 0, 0, 0, 0, + 0, 0, 0, 421, 0, 422, 0, 423, 424, 35, + 0, 0, 0, 0, 0, 0, 0, 41, 42, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 426, + 427, 428, 429, 430, 431, 432, 433, 0, 434, 435, + 436, 0, 0, 0, 0, 0, 0, 0, 437, 438, + 0, 439, 440, 0, 441, 442, 443, 135, 136, 0, + 138, 139, 0, 444, 445, 446, 447, 448, 0, 0, + 449, 450, 451, 140, 452, 0, 453, 454, 455, 456, + 144, 0, 0, 0, 457, 458, 459, 460, 0, 461, + 462, 0, 463, 464, 465, 466, 467, 468, 0, 0, + 469, 0, 0, 0, 0, 0, 0, 0, 0, 470, + 471, 472, 473, 474, 475, 155, 156, 476, 0, 477, + 0, 478, 479, 480, 481, 482, 0, 483, 484, 485, + 0, 0, 486, 487, 488, 489, 490, 0, 491, 492, + 493, 0, 494, 495, 0, 496, 497, 498, 499, 164, + 500, 501, 502, 166, 0, 503, 0, 504, 168, 505, + 0, 506, 0, 507, 0, 0, 0, 508, 509, 510, + 0, 511, 172, 0, 512, 0, 513, 514, 515, 516, + 517, 0, 518, 519, 520, 0, 521, 522, 523, 524, + 525, 526, 0, 527, 0, 175, 0, 528, 529, 530, + 0, 176, 0, 177, 0, 531, 0, 0, 532, 0, + 533, 534, 535, 536, 537, 538, 539, 0, 540, 181, + 0, 541, 0, 0, 542, 543, 544, 0, 0, 545, + 546, 547, 548, 549, 550, 551, 552, 553, 554, 555, + 556, 188, 0, 190, 557, 558, 191, 0, 559, 560, + 0, 561, 0, 194, 562, 195, 563, 564, 565, 0, + 566, 0, 0, 567, 568, 569, 0, 0, 196, 0, + 0, 0, 200, 570, 571, 572, 573, 574, 575, 576, + 0, 577, 201, 578, 202, 579, 580, 581, 0, 582, + 583, 584, 585, 586, 587, 588, 204, 589, 590, 591, + 592, 0, 593, 594, 595, 596, 597, 598, 599, 600, + 601, 602, 0, 603, 604, 0, 605, 606, 212, 607, + 608, 609, 610, 611, 612, 613, 614, 0, 615, 616, + 617, 618, 619, 0, 620, 217, 621, 622, 0, 623, + 220, 624, 0, 625, 626, 627, 628, 629, 630, 631, + 632, 633, 634, 222, 0, 635, 636, 0, 637, 638, + 639, 640, 641, 642, 0, 224, 225, 0, 0, 644, + 226, 645, 227, 0, 646, 647, 648, 649, 650, 651, + 652, 0, 0, 653, 654, 655, 656, 657, 0, 0, + 658, 659, 660, 661, 662, 663, 234, 0, 664, 0, + 665, 666, 667, 0, 0, 668, 0, 0, 669, 670, + 671, 672, 673, 237, 238, 239, 240, 241, 242, 243, + 244, 245, 674, 675, 676, 0, 0, 0, 0, 86, + 87, 88, 412, 90, 91, 92, 413, 0, 414, 95, + 0, 2962, 98, 99, 100, 101, 102, 103, 0, 104, + 105, 415, 0, 0, 107, 108, 109, 110, 0, 0, + 112, 113, 114, 115, 0, 116, 0, 0, 416, 417, + 0, 0, 0, 418, 419, 0, 0, 0, 0, 420, + 0, 0, 0, 0, 0, 0, 0, 0, 421, 0, + 422, 0, 423, 424, 35, 0, 0, 0, 0, 0, + 0, 0, 41, 42, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 426, 427, 428, 429, 430, 431, + 432, 433, 0, 434, 435, 436, 0, 0, 0, 0, + 0, 0, 0, 437, 438, 0, 439, 440, 0, 441, + 442, 443, 135, 136, 0, 138, 139, 0, 444, 445, + 446, 447, 448, 0, 0, 449, 450, 451, 140, 452, + 0, 453, 454, 455, 456, 144, 0, 0, 0, 457, + 458, 459, 460, 0, 461, 462, 0, 463, 464, 465, + 466, 467, 468, 0, 0, 469, 0, 0, 0, 0, + 0, 0, 0, 0, 470, 471, 472, 473, 474, 475, + 155, 156, 476, 0, 477, 0, 478, 479, 480, 481, + 482, 0, 483, 484, 485, 0, 0, 486, 487, 488, + 489, 490, 0, 491, 492, 493, 0, 494, 495, 0, + 496, 497, 498, 499, 164, 500, 501, 502, 166, 0, + 503, 0, 504, 168, 505, 0, 506, 0, 507, 0, + 0, 0, 508, 509, 510, 0, 511, 172, 0, 512, + 0, 513, 514, 515, 516, 517, 0, 518, 519, 520, + 0, 521, 522, 523, 524, 525, 526, 0, 527, 0, + 175, 0, 528, 529, 530, 0, 176, 0, 177, 0, + 531, 0, 0, 532, 0, 533, 534, 535, 536, 537, + 538, 539, 0, 540, 181, 0, 541, 0, 0, 542, + 543, 544, 0, 0, 545, 546, 547, 548, 549, 550, + 551, 552, 553, 554, 555, 556, 188, 0, 190, 557, + 558, 191, 0, 559, 560, 0, 561, 0, 194, 562, + 195, 563, 564, 565, 0, 566, 0, 0, 567, 568, + 569, 0, 0, 196, 0, 0, 0, 200, 570, 571, + 572, 573, 574, 575, 576, 0, 577, 201, 578, 202, + 579, 580, 581, 0, 582, 583, 584, 585, 586, 587, + 588, 204, 589, 590, 591, 592, 0, 593, 594, 595, + 596, 597, 598, 599, 600, 601, 602, 0, 603, 604, + 0, 605, 606, 212, 607, 608, 609, 610, 611, 612, + 613, 614, 0, 615, 616, 617, 618, 619, 0, 620, + 217, 621, 622, 0, 623, 220, 624, 0, 625, 626, + 627, 628, 629, 630, 631, 632, 633, 634, 222, 0, + 635, 636, 0, 637, 638, 639, 640, 641, 642, 0, + 224, 225, 0, 0, 644, 226, 645, 227, 0, 646, + 647, 648, 649, 650, 651, 652, 0, 0, 653, 654, + 655, 656, 657, 0, 0, 658, 659, 660, 661, 662, + 663, 234, 0, 664, 0, 665, 666, 667, 0, 0, + 668, 0, 0, 669, 670, 671, 672, 673, 237, 238, + 239, 240, 241, 242, 243, 244, 245, 674, 675, 676, + 0, 0, 0, 0, 86, 87, 88, 412, 90, 91, + 92, 413, 0, 414, 95, 0, 4035, 98, 99, 100, + 101, 102, 103, 0, 104, 105, 415, 0, 0, 107, + 108, 109, 110, 0, 0, 112, 113, 114, 115, 0, + 116, 0, 0, 416, 417, 0, 0, 0, 418, 419, + 0, 0, 0, 0, 420, 0, 0, 0, 0, 0, + 0, 0, 0, 421, 0, 422, 0, 423, 424, 35, + 0, 0, 0, 0, 0, 0, 0, 41, 42, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 426, + 427, 428, 429, 430, 431, 432, 433, 0, 434, 435, + 436, 0, 0, 0, 0, 0, 0, 0, 437, 438, + 0, 439, 440, 0, 441, 442, 443, 135, 136, 0, + 138, 139, 0, 444, 445, 446, 447, 448, 0, 0, + 449, 450, 451, 140, 452, 0, 453, 454, 455, 456, + 144, 0, 0, 0, 457, 458, 459, 460, 0, 461, + 462, 0, 463, 464, 465, 466, 467, 468, 0, 0, + 469, 0, 0, 0, 0, 0, 0, 0, 0, 470, + 471, 472, 473, 474, 475, 155, 156, 476, 0, 477, + 0, 478, 479, 480, 481, 482, 0, 483, 484, 485, + 0, 0, 486, 487, 488, 489, 490, 0, 491, 492, + 493, 0, 494, 495, 0, 496, 497, 498, 499, 164, + 500, 501, 502, 166, 0, 503, 0, 504, 168, 505, + 0, 506, 0, 507, 0, 0, 0, 508, 509, 510, + 0, 511, 172, 0, 512, 0, 513, 514, 515, 516, + 517, 0, 518, 519, 520, 0, 521, 522, 523, 524, + 525, 526, 0, 527, 0, 175, 0, 528, 529, 530, + 0, 176, 0, 177, 0, 531, 0, 0, 532, 0, + 533, 534, 535, 536, 537, 538, 539, 0, 540, 181, + 0, 541, 0, 0, 542, 543, 544, 0, 0, 545, + 546, 547, 548, 549, 550, 551, 552, 553, 554, 555, + 556, 188, 0, 190, 557, 558, 191, 0, 559, 560, + 0, 561, 0, 194, 562, 195, 563, 564, 565, 0, + 566, 0, 0, 567, 568, 569, 0, 0, 196, 0, + 0, 0, 200, 570, 571, 572, 573, 574, 575, 576, + 0, 577, 201, 578, 202, 579, 580, 581, 0, 582, + 583, 584, 585, 586, 587, 588, 204, 589, 590, 591, + 592, 0, 593, 594, 595, 596, 597, 598, 599, 600, + 601, 602, 0, 603, 604, 0, 605, 606, 212, 607, + 608, 609, 610, 611, 612, 613, 614, 0, 615, 616, + 617, 618, 619, 0, 620, 217, 621, 622, 0, 623, + 220, 624, 0, 625, 626, 627, 628, 629, 630, 631, + 632, 633, 634, 222, 0, 635, 636, 0, 637, 638, + 639, 640, 641, 642, 0, 224, 225, 0, 0, 644, + 226, 645, 227, 0, 646, 647, 648, 649, 650, 651, + 652, 0, 0, 653, 654, 655, 656, 657, 0, 0, + 658, 659, 660, 661, 662, 663, 234, 0, 664, 0, + 665, 666, 667, 0, 0, 668, 0, 0, 669, 670, + 671, 672, 673, 237, 238, 239, 240, 241, 242, 243, + 244, 245, 674, 675, 676, 0, 0, 0, 713, 86, + 87, 88, 412, 90, 91, 92, 413, 0, 414, 95, + 0, 4380, 98, 99, 100, 101, 102, 103, 714, 104, + 105, 415, 715, 0, 107, 108, 109, 110, 716, 717, + 112, 113, 114, 115, 0, 116, 718, 719, 416, 417, + 0, 0, 0, 418, 419, 0, 0, 0, 0, 420, + 0, 0, 0, 0, 0, 0, 0, 0, 421, 0, + 422, 0, 423, 424, 35, 425, 0, 0, 37, 38, + 39, 40, 41, 42, 43, 44, 0, 0, 1181, 45, + 0, 0, 0, 0, 426, 427, 428, 429, 430, 431, + 432, 433, 720, 434, 435, 436, 721, 722, 723, 724, + 725, 726, 727, 437, 438, 728, 439, 440, 133, 441, + 442, 443, 0, 1857, 137, 1858, 1859, 729, 444, 445, + 446, 447, 448, 730, 731, 449, 450, 1860, 1861, 452, + 733, 453, 454, 455, 456, 0, 734, 145, 735, 457, + 458, 459, 460, 148, 461, 462, 737, 463, 464, 465, + 466, 467, 468, 738, 151, 469, 0, 740, 741, 742, + 152, 743, 744, 745, 470, 471, 472, 473, 474, 475, + 1862, 1863, 476, 746, 477, 747, 478, 479, 480, 481, + 482, 748, 483, 484, 485, 749, 750, 486, 487, 1458, + 489, 490, 751, 491, 492, 493, 752, 494, 495, 753, + 496, 497, 498, 499, 0, 500, 501, 502, 0, 754, + 503, 755, 504, 1864, 505, 756, 506, 757, 507, 169, + 758, 170, 508, 509, 510, 759, 511, 0, 760, 512, + 761, 513, 514, 515, 516, 517, 173, 518, 519, 520, + 762, 521, 522, 523, 524, 525, 526, 763, 527, 174, + 0, 0, 528, 529, 530, 1464, 1865, 766, 1866, 767, + 531, 178, 179, 532, 180, 533, 534, 535, 536, 537, + 538, 539, 768, 540, 0, 182, 541, 183, 769, 542, + 543, 544, 770, 771, 545, 546, 547, 548, 549, 550, + 551, 552, 553, 554, 555, 556, 1867, 189, 1868, 557, + 558, 0, 772, 559, 560, 193, 561, 773, 0, 562, + 1869, 563, 564, 565, 774, 566, 775, 776, 3773, 568, + 569, 777, 778, 0, 197, 198, 199, 0, 570, 571, + 572, 573, 574, 575, 576, 779, 577, 0, 578, 0, + 579, 580, 581, 780, 582, 583, 584, 585, 586, 587, + 588, 1870, 589, 590, 591, 592, 781, 593, 594, 595, + 596, 597, 598, 599, 600, 601, 602, 782, 603, 604, + 210, 605, 606, 0, 607, 608, 609, 610, 611, 612, + 613, 614, 783, 615, 616, 617, 618, 619, 784, 620, + 2421, 621, 622, 219, 623, 1872, 624, 785, 625, 626, + 627, 628, 629, 630, 631, 632, 633, 634, 0, 786, + 635, 636, 787, 637, 638, 639, 640, 641, 642, 788, + 1873, 1874, 0, 790, 644, 0, 645, 0, 791, 646, + 647, 648, 649, 650, 651, 652, 0, 793, 653, 654, + 655, 656, 657, 794, 795, 658, 659, 660, 661, 662, + 0, 1875, 797, 664, 235, 665, 666, 667, 798, 799, + 668, 800, 801, 669, 670, 671, 672, 673, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 674, 675, 676, + 0, 0, 0, 1184, 1185, 1186, 0, 3774, 3775, 1189, + 1190, 1191, 1192, 86, 87, 88, 412, 90, 91, 92, + 413, 0, 414, 95, 0, 0, 98, 99, 100, 101, + 102, 103, 0, 104, 105, 415, 0, 0, 107, 108, + 109, 110, 0, 0, 112, 113, 114, 115, 0, 116, + 0, 0, 416, 417, 0, 0, 0, 418, 419, 0, + 0, 0, 0, 420, 0, 0, 0, 0, 0, 0, + 0, 0, 421, 0, 422, 0, 423, 424, 35, 0, + 0, 0, 0, 0, 0, 0, 41, 42, 0, 0, + 0, 0, 1181, 0, 0, 0, 0, 0, 426, 427, + 428, 429, 430, 431, 432, 433, 0, 434, 435, 436, + 0, 0, 0, 0, 0, 0, 0, 437, 438, 0, + 439, 440, 0, 441, 442, 443, 135, 136, 0, 138, + 139, 0, 444, 445, 446, 447, 448, 0, 0, 449, + 450, 451, 140, 452, 0, 453, 1182, 455, 456, 144, + 0, 0, 0, 457, 458, 459, 460, 0, 461, 462, + 0, 463, 464, 465, 466, 467, 468, 0, 0, 469, + 0, 0, 0, 0, 0, 0, 0, 0, 470, 471, + 472, 473, 474, 475, 155, 156, 476, 0, 477, 0, + 478, 479, 480, 481, 482, 0, 483, 484, 485, 0, + 0, 486, 487, 488, 489, 490, 0, 491, 492, 493, + 0, 494, 495, 0, 496, 497, 498, 499, 164, 500, + 501, 502, 166, 0, 1183, 0, 504, 168, 505, 0, + 506, 0, 507, 0, 0, 0, 508, 509, 510, 0, + 511, 172, 0, 512, 0, 513, 514, 515, 516, 517, + 0, 518, 519, 520, 0, 521, 522, 523, 524, 525, + 526, 0, 527, 0, 175, 0, 528, 529, 530, 0, + 176, 0, 177, 0, 531, 0, 0, 532, 0, 533, + 534, 535, 536, 537, 538, 539, 0, 540, 181, 0, + 541, 0, 0, 542, 543, 544, 0, 0, 545, 546, + 547, 548, 549, 550, 551, 552, 553, 554, 555, 556, + 188, 0, 190, 557, 558, 191, 0, 559, 560, 0, + 561, 0, 194, 562, 195, 563, 564, 565, 0, 566, + 0, 0, 567, 568, 569, 0, 0, 196, 0, 0, + 0, 200, 570, 571, 572, 573, 574, 575, 576, 0, + 577, 201, 578, 202, 579, 580, 581, 0, 582, 583, + 584, 585, 586, 587, 588, 204, 589, 590, 591, 592, + 0, 593, 594, 595, 596, 597, 598, 599, 600, 601, + 602, 0, 603, 604, 0, 605, 606, 212, 607, 608, + 609, 610, 611, 612, 613, 614, 0, 615, 616, 617, + 618, 619, 0, 620, 217, 621, 622, 0, 623, 220, + 624, 0, 625, 626, 627, 628, 629, 630, 631, 632, + 633, 634, 222, 0, 635, 636, 0, 637, 638, 639, + 640, 641, 642, 0, 224, 225, 0, 0, 644, 226, + 645, 227, 0, 646, 647, 648, 649, 650, 651, 652, + 0, 0, 653, 654, 655, 656, 657, 0, 0, 658, + 659, 660, 661, 662, 663, 234, 0, 664, 0, 665, + 666, 667, 0, 0, 668, 0, 0, 669, 670, 671, + 672, 673, 237, 238, 239, 240, 241, 242, 243, 244, + 245, 674, 675, 676, 0, 0, 0, 1184, 1185, 1186, + 0, 1187, 1188, 1189, 1190, 1191, 1192, 86, 87, 88, + 412, 90, 91, 92, 413, 0, 414, 95, 0, 0, + 98, 99, 100, 101, 102, 103, 0, 104, 105, 415, + 0, 0, 107, 108, 109, 110, 0, 0, 112, 113, + 114, 115, 0, 116, 0, 0, 416, 417, 0, 0, + 0, 418, 419, 0, 0, 0, 0, 420, 0, 0, + 0, 0, 0, 0, 0, 0, 421, 0, 422, 0, + 423, 424, 35, 0, 0, 0, 0, 0, 0, 0, + 41, 42, 0, 0, 0, 0, 1181, 0, 0, 0, + 0, 0, 426, 427, 428, 429, 430, 431, 432, 433, + 0, 434, 435, 436, 0, 0, 0, 0, 0, 0, + 0, 437, 438, 0, 439, 440, 0, 441, 442, 443, + 135, 136, 0, 138, 139, 0, 444, 445, 446, 447, + 448, 0, 0, 449, 450, 451, 140, 452, 0, 453, + 1270, 455, 456, 144, 0, 0, 0, 457, 458, 459, + 460, 0, 461, 462, 0, 463, 464, 465, 466, 467, + 468, 0, 0, 469, 0, 0, 0, 0, 0, 0, + 0, 0, 470, 471, 472, 473, 474, 475, 155, 156, + 476, 0, 477, 0, 478, 479, 480, 481, 482, 0, + 483, 484, 485, 0, 0, 486, 487, 488, 489, 490, + 0, 491, 492, 493, 0, 494, 495, 0, 496, 497, + 498, 499, 164, 500, 501, 502, 166, 0, 1271, 0, + 504, 168, 505, 0, 506, 0, 507, 0, 0, 0, + 508, 509, 510, 0, 511, 172, 0, 512, 0, 513, + 514, 515, 516, 517, 0, 518, 519, 520, 0, 521, + 522, 523, 524, 525, 526, 0, 527, 0, 175, 0, + 528, 529, 530, 0, 176, 0, 177, 0, 531, 0, + 0, 532, 0, 533, 534, 535, 536, 537, 538, 539, + 0, 540, 181, 0, 541, 0, 0, 542, 543, 544, + 0, 0, 545, 546, 547, 548, 549, 550, 551, 552, + 553, 554, 555, 556, 188, 0, 190, 557, 558, 191, + 0, 559, 560, 0, 561, 0, 194, 562, 195, 563, + 564, 565, 0, 566, 0, 0, 567, 568, 569, 0, + 0, 196, 0, 0, 0, 200, 570, 571, 572, 573, + 574, 575, 576, 0, 577, 201, 578, 202, 579, 580, + 581, 0, 582, 583, 584, 585, 586, 587, 588, 204, + 589, 590, 591, 592, 0, 593, 594, 595, 596, 597, + 598, 599, 600, 601, 602, 0, 603, 604, 0, 605, + 606, 212, 607, 608, 609, 610, 611, 612, 613, 614, + 0, 615, 616, 617, 618, 619, 0, 620, 217, 621, + 622, 0, 623, 220, 624, 0, 625, 626, 627, 628, + 629, 630, 631, 632, 633, 634, 222, 0, 635, 636, + 0, 637, 638, 639, 640, 641, 642, 0, 224, 225, + 0, 0, 644, 226, 645, 227, 0, 646, 647, 648, + 649, 650, 651, 652, 0, 0, 653, 654, 655, 656, + 657, 0, 0, 658, 659, 660, 661, 662, 663, 234, + 0, 664, 0, 665, 666, 667, 0, 0, 668, 0, + 0, 669, 670, 671, 672, 673, 237, 238, 239, 240, + 241, 242, 243, 244, 245, 674, 675, 676, 0, 0, + 0, 1184, 1185, 1186, 0, 1187, 1188, 1189, 1190, 1191, + 1192, 86, 87, 88, 412, 90, 91, 92, 413, 0, + 414, 95, 0, 0, 98, 99, 100, 101, 102, 103, + 0, 104, 105, 415, 0, 0, 107, 108, 109, 110, + 0, 0, 112, 113, 114, 115, 0, 116, 0, 0, + 416, 417, 0, 0, 0, 418, 419, 0, 0, 0, + 0, 420, 0, 0, 0, 0, 0, 0, 0, 0, + 421, 0, 422, 0, 423, 424, 35, 0, 0, 0, + 0, 0, 0, 0, 41, 42, 0, 0, 0, 0, + 1181, 0, 0, 0, 0, 0, 426, 427, 428, 429, + 430, 431, 432, 433, 0, 434, 435, 436, 0, 0, + 0, 0, 0, 0, 0, 437, 438, 0, 439, 440, + 0, 441, 442, 443, 135, 136, 0, 138, 139, 0, + 444, 445, 446, 447, 448, 0, 0, 449, 450, 451, + 140, 452, 0, 453, 1322, 455, 456, 144, 0, 0, + 0, 457, 458, 459, 460, 0, 461, 462, 0, 463, + 464, 465, 466, 467, 468, 0, 0, 469, 0, 0, + 0, 0, 0, 0, 0, 0, 470, 471, 472, 473, + 474, 475, 155, 156, 476, 0, 477, 0, 478, 479, + 480, 481, 482, 0, 483, 484, 485, 0, 0, 486, + 487, 488, 489, 490, 0, 491, 492, 493, 0, 494, + 495, 0, 496, 497, 498, 499, 164, 500, 501, 502, + 166, 0, 1323, 0, 504, 168, 505, 0, 506, 0, + 507, 0, 0, 0, 508, 509, 510, 0, 511, 172, + 0, 512, 0, 513, 514, 515, 516, 1324, 0, 518, + 519, 520, 0, 521, 522, 523, 524, 525, 526, 0, + 527, 0, 175, 0, 528, 529, 530, 0, 176, 0, + 177, 0, 531, 0, 0, 532, 0, 533, 534, 535, + 536, 537, 538, 539, 0, 540, 181, 0, 541, 0, + 0, 542, 543, 544, 0, 0, 545, 546, 547, 548, + 549, 550, 551, 552, 553, 554, 555, 556, 188, 0, + 190, 557, 558, 191, 0, 559, 560, 0, 561, 0, + 194, 562, 195, 563, 564, 565, 0, 566, 0, 0, + 567, 568, 569, 0, 0, 196, 0, 0, 0, 200, + 570, 571, 572, 573, 574, 575, 576, 0, 577, 201, + 578, 202, 579, 580, 581, 0, 582, 583, 584, 585, + 586, 587, 588, 204, 589, 590, 591, 592, 0, 593, + 594, 595, 596, 597, 598, 599, 600, 601, 602, 0, + 603, 604, 0, 605, 606, 212, 607, 608, 609, 610, + 611, 612, 613, 614, 0, 615, 616, 617, 618, 619, + 0, 620, 217, 621, 622, 0, 623, 220, 624, 0, + 625, 626, 627, 628, 629, 630, 631, 632, 633, 634, + 222, 0, 635, 636, 0, 637, 638, 639, 640, 641, + 642, 0, 224, 225, 0, 0, 644, 226, 645, 227, + 0, 646, 647, 648, 649, 650, 651, 652, 0, 0, + 653, 654, 655, 656, 657, 0, 0, 658, 659, 660, + 661, 662, 663, 234, 0, 664, 0, 665, 666, 667, + 0, 0, 668, 0, 0, 669, 670, 671, 672, 673, + 237, 238, 239, 240, 241, 242, 243, 244, 245, 674, + 675, 676, 0, 0, 0, 1184, 1185, 1186, 0, 1187, + 1188, 1189, 1190, 1191, 1192, 86, 87, 88, 412, 90, + 91, 92, 413, 0, 414, 95, 0, 0, 98, 99, + 100, 101, 102, 103, 0, 104, 105, 415, 0, 0, + 107, 108, 109, 110, 0, 0, 112, 113, 114, 115, + 0, 116, 0, 0, 416, 417, 0, 0, 0, 418, + 419, 0, 0, 0, 0, 420, 0, 0, 0, 0, + 0, 0, 0, 0, 421, 0, 422, 0, 423, 424, + 35, 0, 0, 0, 0, 0, 0, 0, 41, 42, + 0, 0, 0, 0, 1181, 0, 0, 0, 0, 0, + 426, 427, 428, 429, 430, 431, 432, 433, 0, 434, + 435, 436, 0, 0, 0, 0, 0, 0, 0, 437, + 438, 0, 439, 440, 0, 441, 442, 443, 135, 136, + 0, 138, 139, 0, 444, 445, 446, 447, 448, 0, + 0, 449, 450, 451, 140, 452, 0, 453, 1840, 455, + 456, 144, 0, 0, 0, 457, 458, 459, 460, 0, + 461, 462, 0, 463, 464, 465, 466, 467, 468, 0, + 0, 469, 0, 0, 0, 0, 0, 0, 0, 0, + 470, 471, 472, 473, 474, 475, 155, 156, 476, 0, + 477, 0, 478, 479, 480, 481, 482, 0, 483, 484, + 485, 0, 0, 486, 487, 488, 489, 490, 0, 491, + 492, 493, 0, 494, 495, 0, 496, 497, 498, 499, + 164, 500, 501, 502, 166, 0, 1841, 0, 504, 168, + 505, 0, 506, 0, 507, 0, 0, 0, 508, 509, + 510, 0, 511, 172, 0, 512, 0, 513, 514, 515, + 516, 517, 0, 518, 519, 520, 0, 521, 522, 523, + 524, 525, 526, 0, 527, 0, 175, 0, 528, 529, + 530, 0, 176, 0, 177, 0, 531, 0, 0, 532, + 0, 533, 534, 535, 536, 537, 538, 539, 0, 540, + 181, 0, 541, 0, 0, 542, 543, 544, 0, 0, + 545, 546, 547, 548, 549, 550, 551, 552, 553, 554, + 555, 556, 188, 0, 190, 557, 558, 191, 0, 559, + 560, 0, 561, 0, 194, 562, 195, 563, 564, 565, + 0, 566, 0, 0, 567, 568, 569, 0, 0, 196, + 0, 0, 0, 200, 570, 571, 572, 573, 574, 575, + 576, 0, 577, 201, 578, 202, 579, 580, 581, 0, + 582, 583, 584, 585, 586, 587, 588, 204, 589, 590, + 591, 592, 0, 593, 594, 595, 596, 597, 598, 599, + 600, 601, 602, 0, 603, 604, 0, 605, 606, 212, + 607, 608, 609, 610, 611, 612, 613, 614, 0, 615, + 616, 617, 618, 619, 0, 620, 217, 621, 622, 0, + 623, 220, 624, 0, 625, 626, 627, 628, 629, 630, + 631, 632, 633, 634, 222, 0, 635, 636, 0, 637, + 638, 639, 640, 641, 642, 0, 224, 225, 0, 0, + 644, 226, 645, 227, 0, 646, 647, 648, 649, 650, + 651, 652, 0, 0, 653, 654, 655, 656, 657, 0, + 0, 658, 659, 660, 661, 662, 663, 234, 0, 664, + 0, 665, 666, 667, 0, 0, 668, 0, 0, 669, + 670, 671, 672, 673, 237, 238, 239, 240, 241, 242, + 243, 244, 245, 674, 675, 676, 0, 0, 0, 1184, + 1185, 1186, 0, 1187, 1188, 1189, 1190, 1191, 1192, 86, + 87, 88, 412, 90, 91, 92, 413, 0, 414, 95, + 0, 0, 98, 99, 100, 101, 102, 103, 0, 104, + 105, 415, 0, 0, 107, 108, 109, 110, 0, 0, + 112, 113, 114, 115, 0, 116, 0, 0, 416, 417, + 0, 0, 0, 418, 419, 0, 0, 0, 0, 420, + 0, 0, 0, 0, 0, 0, 0, 0, 421, 0, + 422, 0, 423, 424, 35, 0, 0, 0, 0, 0, + 0, 0, 41, 42, 0, 0, 0, 0, 1181, 0, + 0, 0, 0, 0, 426, 427, 428, 429, 430, 431, + 432, 433, 0, 434, 435, 436, 0, 0, 0, 0, + 0, 0, 0, 437, 438, 0, 439, 440, 0, 441, + 442, 443, 135, 136, 0, 138, 139, 0, 444, 445, + 446, 447, 448, 0, 0, 449, 450, 451, 140, 452, + 0, 453, 454, 455, 456, 144, 0, 0, 0, 457, + 458, 459, 460, 0, 461, 462, 0, 463, 464, 465, + 466, 467, 468, 0, 0, 469, 0, 0, 0, 0, + 0, 0, 0, 0, 470, 471, 472, 473, 474, 475, + 155, 156, 476, 0, 477, 0, 478, 479, 480, 481, + 482, 0, 483, 484, 485, 0, 0, 486, 487, 488, + 489, 490, 0, 491, 492, 493, 0, 494, 495, 0, + 496, 497, 498, 499, 164, 500, 501, 502, 166, 0, + 503, 0, 504, 168, 505, 0, 506, 0, 507, 0, + 0, 0, 508, 509, 510, 0, 511, 172, 0, 512, + 0, 513, 514, 515, 516, 517, 0, 518, 519, 520, + 0, 521, 522, 523, 524, 525, 526, 0, 527, 0, + 175, 0, 528, 529, 530, 0, 176, 0, 177, 0, + 531, 0, 0, 532, 0, 533, 534, 535, 536, 537, + 538, 539, 0, 540, 181, 0, 541, 0, 0, 542, + 543, 544, 0, 0, 545, 546, 547, 548, 549, 550, + 551, 552, 553, 554, 555, 556, 188, 0, 190, 557, + 558, 191, 0, 559, 560, 0, 561, 0, 194, 562, + 195, 563, 564, 565, 0, 566, 0, 0, 567, 568, + 569, 0, 0, 196, 0, 0, 0, 200, 570, 571, + 572, 573, 574, 575, 576, 0, 577, 201, 578, 202, + 579, 580, 581, 0, 582, 583, 584, 585, 586, 587, + 588, 204, 589, 590, 591, 592, 0, 593, 594, 595, + 596, 597, 598, 599, 600, 601, 602, 0, 603, 604, + 0, 605, 606, 212, 607, 608, 609, 610, 611, 612, + 613, 614, 0, 615, 616, 617, 618, 619, 0, 620, + 217, 621, 622, 0, 623, 220, 624, 0, 625, 626, + 627, 628, 629, 630, 631, 632, 633, 634, 222, 0, + 635, 636, 0, 637, 638, 639, 640, 641, 642, 0, + 224, 225, 0, 0, 644, 226, 645, 227, 0, 646, + 647, 648, 649, 650, 651, 652, 0, 0, 653, 654, + 655, 656, 657, 0, 0, 658, 659, 660, 661, 662, + 663, 234, 0, 664, 0, 665, 666, 667, 0, 0, + 668, 0, 0, 669, 670, 671, 672, 673, 237, 238, + 239, 240, 241, 242, 243, 244, 245, 674, 675, 676, + 0, 0, 0, 1184, 1185, 1186, 0, 1187, 1188, 1189, + 1190, 1191, 1192, 86, 87, 88, 412, 90, 91, 92, + 413, 0, 414, 95, 0, 0, 98, 99, 100, 101, + 102, 103, 0, 104, 105, 415, 0, 0, 107, 108, + 109, 110, 0, 0, 112, 113, 114, 115, 0, 116, + 0, 0, 416, 417, 0, 0, 0, 418, 419, 0, + 0, 0, 0, 420, 0, 0, 0, 0, 0, 0, + 0, 0, 421, 0, 422, 0, 423, 424, 35, 0, + 0, 0, 0, 0, 0, 0, 41, 42, 0, 0, + 0, 0, 1181, 0, 0, 0, 0, 0, 426, 427, + 428, 429, 430, 431, 432, 433, 0, 434, 435, 436, + 0, 0, 0, 0, 0, 0, 0, 437, 438, 0, + 439, 440, 0, 441, 442, 443, 135, 136, 0, 138, + 139, 0, 444, 445, 446, 447, 448, 0, 0, 449, + 450, 451, 140, 452, 0, 453, 3045, 455, 456, 144, + 0, 0, 0, 457, 458, 459, 460, 0, 461, 462, + 0, 463, 464, 465, 466, 467, 468, 0, 0, 469, + 0, 0, 0, 0, 0, 0, 0, 0, 470, 471, + 472, 473, 474, 475, 155, 156, 476, 0, 477, 0, + 478, 479, 480, 481, 482, 0, 483, 484, 485, 0, + 0, 486, 487, 488, 489, 490, 0, 491, 492, 493, + 0, 494, 495, 0, 496, 497, 498, 499, 164, 500, + 501, 502, 166, 0, 3046, 0, 504, 168, 505, 0, + 506, 0, 507, 0, 0, 0, 508, 509, 510, 0, + 511, 172, 0, 512, 0, 513, 514, 515, 516, 517, + 0, 518, 519, 520, 0, 521, 522, 523, 524, 525, + 526, 0, 527, 0, 175, 0, 528, 529, 530, 0, + 176, 0, 177, 0, 531, 0, 0, 532, 0, 533, + 534, 535, 536, 537, 538, 539, 0, 540, 181, 0, + 541, 0, 0, 542, 543, 544, 0, 0, 545, 546, + 547, 548, 549, 550, 551, 552, 553, 554, 555, 556, + 188, 0, 190, 557, 558, 191, 0, 559, 560, 0, + 561, 0, 194, 562, 195, 563, 564, 565, 0, 566, + 0, 0, 567, 568, 569, 0, 0, 196, 0, 0, + 0, 200, 570, 571, 572, 573, 574, 575, 576, 0, + 577, 201, 578, 202, 579, 580, 581, 0, 582, 583, + 584, 585, 586, 587, 588, 204, 589, 590, 591, 592, + 0, 593, 594, 595, 596, 597, 598, 599, 600, 601, + 602, 0, 603, 604, 0, 605, 606, 212, 607, 608, + 609, 610, 611, 612, 613, 614, 0, 615, 616, 617, + 618, 619, 0, 620, 217, 621, 622, 0, 623, 220, + 624, 0, 625, 626, 627, 628, 629, 630, 631, 632, + 633, 634, 222, 0, 635, 636, 0, 637, 638, 639, + 640, 641, 642, 0, 224, 225, 0, 0, 644, 226, + 645, 227, 0, 646, 647, 648, 649, 650, 651, 652, + 0, 0, 653, 654, 655, 656, 657, 0, 0, 658, + 659, 660, 661, 662, 663, 234, 0, 664, 0, 665, + 666, 667, 0, 0, 668, 0, 0, 669, 670, 671, + 672, 673, 237, 238, 239, 240, 241, 242, 243, 244, + 245, 674, 675, 676, 0, 0, 0, 1184, 1185, 1186, + 0, 1187, 1188, 1189, 1190, 1191, 1192, 86, 87, 88, + 412, 90, 91, 92, 413, 0, 414, 95, 0, 0, + 98, 99, 100, 101, 102, 103, 0, 104, 105, 415, + 0, 0, 107, 108, 109, 110, 0, 0, 112, 113, + 114, 115, 0, 116, 0, 0, 416, 417, 0, 0, + 0, 418, 419, 0, 0, 0, 0, 420, 0, 0, + 0, 0, 0, 0, 0, 0, 421, 0, 422, 0, + 423, 424, 35, 0, 0, 0, 0, 0, 0, 0, + 41, 42, 0, 0, 0, 0, 1181, 0, 0, 0, + 0, 0, 426, 427, 428, 429, 430, 431, 432, 433, + 0, 434, 435, 436, 0, 0, 0, 0, 0, 0, + 0, 437, 438, 0, 439, 440, 0, 441, 442, 443, + 135, 136, 0, 138, 139, 0, 444, 445, 446, 447, + 448, 0, 0, 449, 450, 451, 140, 452, 0, 453, + 454, 455, 456, 144, 0, 0, 0, 457, 458, 459, + 460, 0, 461, 462, 0, 463, 464, 465, 466, 467, + 468, 0, 0, 469, 0, 0, 0, 0, 0, 0, + 0, 0, 470, 471, 472, 473, 474, 475, 155, 156, + 476, 0, 477, 0, 478, 479, 480, 481, 482, 0, + 483, 484, 485, 0, 0, 486, 487, 488, 489, 490, + 0, 491, 492, 493, 0, 494, 495, 0, 496, 497, + 498, 499, 164, 500, 501, 502, 166, 0, 503, 0, + 504, 168, 505, 0, 506, 0, 507, 0, 0, 0, + 508, 509, 510, 0, 511, 172, 0, 512, 0, 513, + 514, 515, 516, 517, 0, 518, 519, 520, 0, 521, + 522, 523, 524, 525, 526, 0, 527, 0, 175, 0, + 528, 529, 530, 0, 176, 0, 177, 0, 531, 0, + 0, 532, 0, 533, 534, 535, 536, 537, 538, 539, + 0, 540, 181, 0, 541, 0, 0, 542, 543, 544, + 0, 0, 545, 546, 547, 548, 549, 550, 551, 552, + 553, 554, 555, 556, 188, 0, 190, 557, 558, 191, + 0, 559, 560, 0, 561, 0, 194, 562, 195, 563, + 564, 565, 0, 566, 0, 0, 4616, 568, 569, 0, + 0, 196, 0, 0, 0, 200, 570, 571, 572, 573, + 574, 575, 576, 0, 577, 201, 578, 202, 579, 580, + 581, 0, 582, 583, 584, 585, 586, 587, 588, 204, + 589, 590, 591, 592, 0, 593, 594, 595, 596, 597, + 598, 599, 600, 601, 602, 0, 603, 604, 0, 605, + 606, 212, 607, 608, 609, 610, 611, 612, 613, 614, + 0, 615, 616, 617, 618, 619, 0, 620, 217, 621, + 622, 0, 623, 220, 624, 0, 625, 626, 627, 628, + 629, 630, 631, 632, 633, 634, 222, 0, 635, 636, + 0, 637, 638, 639, 640, 641, 642, 0, 224, 225, + 0, 0, 644, 226, 645, 227, 0, 646, 647, 648, + 649, 650, 651, 652, 0, 0, 653, 654, 655, 656, + 657, 0, 0, 658, 659, 660, 661, 662, 663, 234, + 0, 664, 0, 665, 666, 667, 0, 0, 668, 0, + 0, 669, 670, 671, 672, 673, 237, 238, 239, 240, + 241, 242, 243, 244, 245, 674, 675, 676, 0, 0, + 0, 1184, 1185, 1186, 0, 1187, 1188, 1189, 1190, 1191, + 1192, 713, 86, 87, 88, 412, 90, 91, 92, 413, + 0, 414, 95, 0, 0, 98, 99, 100, 101, 102, + 103, 714, 104, 105, 415, 715, 0, 107, 108, 109, + 110, 716, 717, 112, 113, 114, 115, 0, 116, 718, + 719, 416, 417, 0, 0, 0, 418, 419, 0, 0, + 0, 0, 420, 0, 0, 0, 0, 0, 0, 0, + 0, 421, 0, 422, 0, 423, 424, 35, 0, 0, + 0, 0, 0, 0, 0, 41, 42, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 426, 427, 428, + 429, 430, 431, 432, 433, 720, 434, 435, 436, 721, + 722, 723, 724, 725, 726, 727, 437, 438, 728, 439, + 440, 133, 441, 442, 443, 135, 136, 137, 138, 139, + 729, 444, 445, 446, 447, 448, 730, 731, 449, 450, + 732, 140, 452, 733, 453, 454, 455, 456, 144, 734, + 145, 735, 457, 458, 459, 460, 148, 461, 736, 737, + 463, 464, 465, 466, 467, 468, 738, 151, 469, 739, + 740, 741, 742, 152, 743, 744, 745, 470, 471, 472, + 473, 474, 475, 155, 156, 476, 746, 477, 747, 478, + 479, 480, 481, 482, 748, 483, 484, 485, 749, 750, + 486, 487, 488, 489, 490, 751, 491, 492, 493, 752, + 494, 495, 753, 496, 497, 498, 499, 164, 500, 501, + 502, 166, 754, 503, 755, 504, 168, 505, 756, 506, + 757, 507, 169, 758, 170, 508, 509, 510, 759, 511, + 172, 760, 512, 761, 513, 514, 515, 516, 517, 173, + 518, 519, 520, 762, 521, 522, 523, 524, 525, 526, + 763, 527, 174, 175, 764, 528, 529, 530, 765, 176, + 766, 177, 767, 531, 178, 179, 532, 180, 533, 534, + 535, 536, 537, 538, 539, 768, 540, 181, 182, 541, + 183, 769, 542, 543, 544, 770, 771, 545, 546, 547, + 548, 549, 550, 551, 552, 553, 554, 555, 556, 188, + 189, 190, 557, 558, 191, 772, 559, 560, 193, 561, + 773, 194, 562, 195, 563, 564, 565, 774, 566, 775, + 776, 567, 568, 569, 777, 778, 196, 197, 198, 199, + 200, 570, 571, 572, 573, 574, 575, 576, 779, 577, + 201, 578, 202, 579, 580, 581, 780, 582, 583, 584, + 585, 586, 587, 588, 204, 589, 590, 591, 592, 781, + 593, 594, 595, 596, 597, 598, 599, 600, 601, 602, + 782, 603, 604, 210, 605, 606, 212, 607, 608, 609, + 610, 611, 612, 613, 614, 783, 615, 616, 617, 618, + 619, 784, 620, 217, 621, 622, 219, 623, 220, 624, + 785, 625, 626, 627, 628, 629, 630, 631, 632, 633, + 634, 222, 786, 635, 636, 787, 637, 638, 639, 640, + 641, 642, 788, 224, 225, 789, 790, 644, 226, 645, + 227, 791, 646, 647, 648, 649, 650, 651, 652, 792, + 793, 653, 654, 655, 656, 657, 794, 795, 658, 659, + 660, 661, 662, 796, 234, 797, 664, 235, 665, 666, + 667, 798, 799, 668, 800, 801, 669, 670, 671, 672, + 673, 237, 238, 239, 240, 241, 242, 243, 244, 245, + 674, 675, 676, 713, 86, 87, 88, 412, 90, 91, + 92, 413, 2236, 414, 95, 0, 0, 98, 99, 100, + 101, 102, 103, 714, 104, 105, 415, 715, 0, 107, + 108, 109, 110, 716, 717, 112, 113, 114, 115, 0, + 116, 718, 719, 416, 417, 0, 0, 0, 418, 419, + 0, 0, 0, 0, 420, 0, 0, 0, 0, 0, + 0, 0, 0, 421, 0, 422, 0, 423, 424, 35, + 0, 0, 0, 0, 0, 0, 0, 41, 42, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 426, + 427, 428, 429, 430, 431, 432, 433, 0, 434, 435, + 436, 0, 0, 0, 0, 0, 0, 0, 437, 438, + 0, 439, 440, 133, 441, 442, 443, 0, 1857, 137, + 1858, 1859, 0, 444, 445, 446, 447, 448, 0, 0, + 449, 450, 1860, 1861, 452, 0, 453, 454, 455, 456, + 0, 0, 145, 0, 457, 458, 459, 460, 148, 461, + 462, 0, 463, 464, 465, 466, 467, 468, 0, 151, + 469, 0, 0, 0, 0, 152, 0, 0, 0, 470, + 471, 472, 473, 474, 475, 1862, 1863, 476, 0, 477, + 0, 478, 479, 480, 481, 482, 0, 483, 484, 485, + 0, 0, 486, 487, 1458, 489, 490, 0, 491, 492, + 493, 0, 494, 495, 0, 496, 497, 498, 499, 0, + 500, 501, 502, 0, 0, 503, 0, 504, 1864, 505, + 0, 506, 0, 507, 169, 0, 170, 508, 509, 510, + 0, 511, 0, 0, 512, 0, 513, 514, 515, 516, + 517, 173, 518, 519, 520, 0, 521, 522, 523, 524, + 525, 526, 0, 527, 174, 0, 0, 528, 529, 530, + 1464, 1865, 0, 1866, 0, 531, 178, 179, 532, 180, + 533, 534, 535, 536, 537, 538, 539, 0, 540, 0, + 182, 541, 183, 0, 542, 543, 544, 0, 0, 545, + 546, 547, 548, 549, 550, 551, 552, 553, 554, 555, + 556, 1867, 189, 1868, 557, 558, 0, 0, 559, 560, + 193, 561, 0, 0, 562, 1869, 563, 564, 565, 0, + 566, 0, 0, 567, 568, 569, 0, 0, 0, 197, + 198, 199, 0, 570, 571, 572, 573, 574, 575, 576, + 0, 577, 0, 578, 0, 579, 580, 581, 0, 582, + 583, 584, 585, 586, 587, 588, 1870, 589, 590, 591, + 592, 0, 593, 594, 595, 596, 597, 598, 599, 600, + 601, 602, 0, 603, 604, 210, 605, 606, 0, 607, + 608, 609, 610, 611, 612, 613, 614, 0, 615, 616, + 617, 618, 619, 0, 620, 1871, 621, 622, 219, 623, + 1872, 624, 0, 625, 626, 627, 628, 629, 630, 631, + 632, 633, 634, 0, 0, 635, 636, 0, 637, 638, + 639, 640, 641, 642, 0, 1873, 1874, 0, 0, 644, + 0, 645, 0, 0, 646, 647, 648, 649, 650, 651, + 652, 0, 0, 653, 654, 655, 656, 657, 0, 0, + 658, 659, 660, 661, 662, 0, 1875, 0, 664, 235, + 665, 666, 667, 0, 0, 668, 0, 0, 669, 670, + 671, 672, 673, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 674, 675, 676, 0, 86, 87, 88, 412, + 90, 91, 92, 413, 2335, 414, 95, 0, 0, 98, + 99, 100, 101, 102, 103, 0, 104, 105, 415, 0, + 0, 107, 108, 109, 110, 0, 0, 112, 113, 114, + 115, 0, 116, 0, 0, 416, 417, 0, 0, 0, + 418, 419, 0, 0, 0, 0, 420, 0, 0, 0, + 0, 0, 0, 0, 0, 421, 0, 422, 0, 423, + 424, 35, 0, 0, 0, 0, 0, 0, 0, 41, + 42, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 426, 427, 428, 429, 430, 431, 432, 433, 0, + 434, 435, 436, 0, 0, 0, 0, 0, 0, 0, + 437, 438, 0, 439, 440, 0, 441, 442, 443, 135, + 136, 0, 138, 139, 0, 444, 445, 446, 447, 448, + 0, 0, 449, 450, 451, 140, 452, 0, 453, 454, + 455, 456, 144, 0, 0, 0, 457, 458, 459, 460, + 0, 461, 462, 0, 463, 464, 465, 466, 467, 468, + 0, 0, 469, 0, 0, 0, 0, 0, 0, 0, + 0, 470, 471, 472, 473, 474, 475, 155, 156, 476, + 0, 477, 0, 478, 479, 480, 481, 482, 0, 483, + 484, 485, 0, 0, 486, 487, 488, 489, 490, 0, + 491, 492, 493, 0, 494, 495, 0, 496, 497, 498, + 499, 164, 500, 501, 502, 166, 0, 503, 0, 504, + 168, 505, 0, 506, 0, 507, 0, 0, 0, 508, + 509, 510, 0, 511, 172, 0, 512, 0, 513, 514, + 515, 516, 517, 0, 518, 519, 520, 0, 521, 522, + 523, 524, 525, 526, 0, 527, 0, 175, 0, 528, + 529, 530, 0, 176, 0, 177, 0, 531, 0, 0, + 532, 0, 533, 534, 535, 536, 537, 538, 539, 0, + 540, 181, 0, 541, 0, 0, 542, 543, 544, 0, + 0, 545, 546, 547, 548, 549, 550, 551, 552, 553, + 554, 555, 556, 188, 0, 190, 557, 558, 191, 0, + 559, 560, 0, 561, 0, 194, 562, 195, 563, 564, + 565, 0, 566, 0, 0, 567, 568, 569, 0, 0, + 196, 0, 0, 0, 200, 570, 571, 572, 573, 574, + 575, 576, 0, 577, 201, 578, 202, 579, 580, 581, + 0, 582, 583, 584, 585, 586, 587, 588, 204, 589, + 590, 591, 592, 0, 593, 594, 595, 596, 597, 598, + 599, 600, 601, 602, 0, 603, 604, 0, 605, 606, + 212, 607, 608, 609, 610, 611, 612, 613, 614, 0, + 615, 616, 617, 618, 619, 0, 620, 217, 621, 622, + 0, 623, 220, 624, 0, 625, 626, 627, 628, 629, + 630, 631, 632, 633, 634, 222, 0, 635, 636, 0, + 637, 638, 639, 640, 641, 642, 0, 224, 225, 0, + 0, 644, 226, 645, 227, 0, 646, 647, 648, 649, + 650, 651, 652, 0, 0, 653, 654, 655, 656, 657, + 0, 0, 658, 659, 660, 661, 662, 663, 234, 0, + 664, 0, 665, 666, 667, 0, 0, 668, 0, 0, + 669, 670, 671, 672, 673, 237, 238, 239, 240, 241, + 242, 243, 244, 245, 674, 675, 676, 0, 86, 87, + 88, 412, 90, 91, 92, 413, 1066, 414, 95, 0, + 0, 98, 99, 100, 101, 102, 103, 0, 104, 105, + 415, 0, 0, 107, 108, 109, 110, 0, 0, 112, + 113, 114, 115, 0, 116, 0, 0, 416, 417, 0, + 0, 0, 418, 419, 0, 0, 0, 0, 420, 0, + 0, 0, 0, 0, 0, 0, 0, 421, 0, 422, + 0, 423, 424, 35, 0, 0, 0, 0, 0, 0, + 0, 41, 42, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 426, 427, 428, 429, 430, 431, 432, + 433, 0, 434, 435, 436, 0, 0, 0, 0, 0, + 0, 0, 437, 438, 0, 439, 440, 0, 441, 442, + 443, 135, 136, 0, 138, 139, 0, 444, 445, 446, + 447, 448, 0, 0, 449, 450, 451, 140, 452, 0, + 453, 454, 455, 456, 144, 0, 0, 0, 457, 458, + 459, 460, 0, 461, 462, 0, 463, 464, 465, 466, + 467, 468, 0, 0, 469, 0, 0, 0, 0, 0, + 0, 0, 0, 470, 471, 472, 473, 474, 475, 155, + 156, 476, 0, 477, 0, 478, 479, 480, 481, 482, + 0, 483, 484, 485, 0, 0, 486, 487, 488, 489, + 490, 0, 491, 492, 493, 0, 494, 495, 0, 496, + 497, 498, 499, 164, 500, 501, 502, 166, 0, 503, + 0, 504, 168, 505, 0, 506, 0, 507, 0, 0, + 0, 508, 509, 510, 0, 511, 172, 0, 512, 0, + 513, 514, 515, 516, 517, 0, 518, 519, 520, 0, + 521, 522, 523, 524, 525, 526, 0, 527, 0, 175, + 0, 528, 529, 530, 0, 176, 0, 177, 0, 531, + 0, 0, 532, 0, 533, 534, 535, 536, 537, 538, + 539, 0, 540, 181, 0, 541, 0, 0, 542, 543, + 544, 0, 0, 545, 546, 547, 548, 549, 550, 551, + 552, 553, 554, 555, 556, 188, 0, 190, 557, 558, + 191, 0, 559, 560, 0, 561, 0, 194, 562, 195, + 563, 564, 565, 0, 566, 0, 0, 567, 568, 569, + 0, 0, 196, 0, 0, 0, 200, 570, 571, 572, + 573, 574, 575, 576, 0, 577, 201, 578, 202, 579, + 580, 581, 0, 582, 583, 584, 585, 586, 587, 588, + 204, 589, 590, 591, 592, 0, 593, 594, 595, 596, + 597, 598, 599, 600, 601, 602, 0, 603, 604, 0, + 605, 606, 212, 607, 608, 609, 610, 611, 612, 613, + 614, 0, 615, 616, 617, 618, 619, 0, 620, 217, + 621, 622, 0, 623, 220, 624, 0, 625, 626, 627, + 628, 629, 630, 631, 632, 633, 634, 222, 0, 635, + 636, 0, 637, 638, 639, 640, 641, 642, 0, 224, + 225, 0, 0, 644, 226, 645, 227, 0, 646, 647, + 648, 649, 650, 651, 652, 0, 0, 653, 654, 655, + 656, 657, 0, 0, 658, 659, 660, 661, 662, 663, + 234, 0, 664, 0, 665, 666, 667, 0, 0, 668, + 0, 0, 669, 670, 671, 672, 673, 237, 238, 239, + 240, 241, 242, 243, 244, 245, 674, 675, 676, 0, + 86, 87, 88, 412, 90, 91, 92, 413, 4484, 414, + 95, 0, 0, 98, 99, 100, 101, 102, 103, 0, + 104, 105, 415, 0, 0, 107, 108, 109, 110, 0, + 0, 112, 113, 114, 115, 0, 116, 0, 0, 416, + 417, 0, 0, 0, 418, 419, 0, 0, 0, 0, + 420, 0, 0, 0, 0, 0, 0, 0, 0, 421, + 0, 422, 0, 423, 424, 35, 425, 0, 0, 37, + 38, 39, 40, 41, 42, 43, 44, 0, 0, 0, + 45, 0, 0, 0, 0, 426, 427, 428, 429, 430, + 431, 432, 433, 0, 434, 435, 436, 0, 0, 0, + 0, 0, 0, 0, 437, 438, 0, 439, 440, 0, + 441, 442, 443, 135, 136, 0, 138, 139, 0, 444, + 445, 446, 447, 448, 0, 0, 449, 450, 451, 140, + 452, 0, 453, 454, 455, 456, 144, 0, 0, 0, + 457, 458, 459, 460, 0, 461, 462, 0, 463, 464, + 465, 466, 467, 468, 0, 0, 469, 0, 0, 0, + 0, 0, 0, 0, 0, 470, 471, 472, 473, 474, + 475, 155, 156, 476, 2224, 477, 0, 478, 479, 480, + 481, 482, 0, 483, 484, 485, 0, 0, 486, 487, + 488, 489, 490, 0, 491, 492, 493, 0, 494, 495, + 0, 496, 497, 498, 499, 164, 500, 501, 502, 166, + 2008, 503, 0, 504, 168, 505, 0, 506, 0, 507, + 0, 0, 0, 508, 509, 510, 0, 511, 172, 0, + 512, 0, 513, 514, 515, 516, 517, 0, 518, 519, + 520, 0, 521, 522, 523, 524, 525, 526, 0, 527, + 0, 175, 0, 528, 529, 530, 0, 176, 0, 177, + 0, 531, 0, 0, 532, 0, 533, 534, 535, 536, + 537, 538, 539, 0, 540, 181, 0, 541, 0, 0, + 542, 543, 544, 0, 0, 545, 546, 547, 548, 549, + 550, 551, 552, 553, 554, 555, 556, 188, 0, 190, + 557, 558, 191, 0, 559, 560, 0, 561, 0, 194, + 562, 195, 563, 564, 565, 0, 566, 2009, 0, 567, + 568, 569, 0, 0, 196, 0, 0, 0, 200, 570, + 571, 572, 573, 574, 575, 576, 0, 577, 201, 578, + 202, 579, 580, 581, 0, 582, 583, 584, 585, 586, + 587, 588, 204, 589, 590, 591, 592, 0, 593, 594, + 595, 596, 597, 598, 599, 600, 601, 602, 0, 603, + 604, 0, 605, 606, 212, 607, 608, 609, 610, 611, + 612, 613, 614, 0, 615, 616, 617, 618, 619, 0, + 620, 217, 621, 622, 0, 623, 220, 624, 0, 625, + 626, 627, 628, 629, 630, 631, 632, 633, 634, 222, + 0, 635, 636, 0, 637, 638, 639, 640, 641, 642, + 0, 224, 225, 0, 0, 644, 226, 645, 227, 2010, + 646, 647, 648, 649, 650, 651, 652, 0, 0, 653, + 654, 655, 656, 657, 0, 0, 658, 659, 660, 661, + 662, 663, 234, 0, 664, 0, 665, 666, 667, 0, + 0, 668, 0, 0, 669, 670, 671, 672, 673, 237, + 238, 239, 240, 241, 242, 243, 244, 245, 674, 675, + 676, 0, 0, 0, 0, 0, 0, 0, 976, 1637, + 86, 87, 88, 412, 90, 91, 92, 413, 0, 414, + 95, 0, 0, 98, 99, 100, 101, 102, 103, 0, + 104, 105, 415, 0, 0, 107, 108, 109, 110, 0, + 0, 112, 113, 114, 115, 0, 116, 0, 0, 416, + 417, 0, 0, 0, 418, 419, 0, 0, 0, 0, + 420, 0, 0, 0, 0, 0, 0, 0, 0, 421, + 0, 422, 0, 423, 424, 35, 425, 0, 0, 37, + 38, 39, 40, 41, 42, 43, 44, 0, 0, 0, + 45, 0, 0, 0, 0, 426, 427, 428, 429, 430, + 431, 432, 433, 0, 434, 435, 436, 0, 0, 0, + 0, 0, 0, 0, 437, 438, 0, 439, 440, 0, + 441, 442, 443, 135, 136, 0, 138, 139, 0, 444, + 445, 446, 447, 448, 0, 0, 449, 450, 451, 140, + 452, 0, 453, 454, 455, 456, 144, 0, 0, 0, + 457, 458, 459, 460, 0, 461, 462, 0, 463, 464, + 465, 466, 467, 468, 0, 0, 469, 0, 0, 0, + 0, 0, 0, 0, 0, 470, 471, 472, 473, 474, + 475, 155, 156, 476, 2229, 477, 0, 478, 479, 480, + 481, 482, 0, 483, 484, 485, 0, 0, 486, 487, + 488, 489, 490, 0, 491, 492, 493, 0, 494, 495, + 0, 496, 497, 498, 499, 164, 500, 501, 502, 166, + 2008, 503, 0, 504, 168, 505, 0, 506, 0, 507, + 0, 0, 0, 508, 509, 510, 0, 511, 172, 0, + 512, 0, 513, 514, 515, 516, 517, 0, 518, 519, + 520, 0, 521, 522, 523, 524, 525, 526, 0, 527, + 0, 175, 0, 528, 529, 530, 0, 176, 0, 177, + 0, 531, 0, 0, 532, 0, 533, 534, 535, 536, + 537, 538, 539, 0, 540, 181, 0, 541, 0, 0, + 542, 543, 544, 0, 0, 545, 546, 547, 548, 549, + 550, 551, 552, 553, 554, 555, 556, 188, 0, 190, + 557, 558, 191, 0, 559, 560, 0, 561, 0, 194, + 562, 195, 563, 564, 565, 0, 566, 2009, 0, 567, + 568, 569, 0, 0, 196, 0, 0, 0, 200, 570, + 571, 572, 573, 574, 575, 576, 0, 577, 201, 578, + 202, 579, 580, 581, 0, 582, 583, 584, 585, 586, + 587, 588, 204, 589, 590, 591, 592, 0, 593, 594, + 595, 596, 597, 598, 599, 600, 601, 602, 0, 603, + 604, 0, 605, 606, 212, 607, 608, 609, 610, 611, + 612, 613, 614, 0, 615, 616, 617, 618, 619, 0, + 620, 217, 621, 622, 0, 623, 220, 624, 0, 625, + 626, 627, 628, 629, 630, 631, 632, 633, 634, 222, + 0, 635, 636, 0, 637, 638, 639, 640, 641, 642, + 0, 224, 225, 0, 0, 644, 226, 645, 227, 2010, + 646, 647, 648, 649, 650, 651, 652, 0, 0, 653, + 654, 655, 656, 657, 0, 0, 658, 659, 660, 661, + 662, 663, 234, 0, 664, 0, 665, 666, 667, 0, + 0, 668, 0, 0, 669, 670, 671, 672, 673, 237, + 238, 239, 240, 241, 242, 243, 244, 245, 674, 675, + 676, 0, 0, 0, 0, 0, 0, 0, 976, 1637, + 86, 87, 88, 412, 90, 91, 92, 413, 0, 414, + 95, 0, 0, 98, 99, 100, 101, 102, 103, 0, + 104, 105, 415, 0, 0, 107, 108, 109, 110, 0, + 0, 112, 113, 114, 115, 0, 116, 0, 0, 416, + 417, 0, 0, 0, 418, 419, 0, 0, 0, 0, + 420, 0, 0, 0, 0, 0, 0, 0, 0, 421, + 0, 422, 0, 423, 424, 35, 425, 0, 0, 37, + 38, 39, 40, 41, 42, 43, 44, 0, 0, 0, + 45, 0, 0, 0, 0, 426, 427, 428, 429, 430, + 431, 432, 433, 0, 434, 435, 436, 0, 0, 0, + 0, 0, 0, 0, 437, 438, 0, 439, 440, 0, + 441, 442, 443, 135, 136, 0, 138, 139, 0, 444, + 445, 446, 447, 448, 0, 0, 449, 450, 451, 140, + 452, 0, 453, 454, 455, 456, 144, 0, 0, 0, + 457, 458, 459, 460, 0, 461, 462, 0, 463, 464, + 465, 466, 467, 468, 0, 0, 469, 0, 0, 0, + 0, 0, 0, 0, 0, 470, 471, 472, 473, 474, + 475, 155, 156, 476, 0, 477, 0, 478, 479, 480, + 481, 482, 0, 483, 484, 485, 0, 0, 486, 487, + 488, 489, 490, 0, 491, 492, 493, 0, 494, 495, + 0, 496, 497, 498, 499, 164, 500, 501, 502, 166, + 2008, 503, 0, 504, 168, 505, 0, 506, 0, 507, + 0, 0, 0, 508, 509, 510, 0, 511, 172, 0, + 512, 0, 513, 514, 515, 516, 517, 0, 518, 519, + 520, 0, 521, 522, 523, 524, 525, 526, 0, 527, + 0, 175, 0, 528, 529, 530, 0, 176, 0, 177, + 0, 531, 0, 0, 532, 0, 533, 534, 535, 536, + 537, 538, 539, 0, 540, 181, 0, 541, 0, 0, + 542, 543, 544, 0, 0, 545, 546, 547, 548, 549, + 550, 551, 552, 553, 554, 555, 556, 188, 0, 190, + 557, 558, 191, 0, 559, 560, 0, 561, 0, 194, + 562, 195, 563, 564, 565, 0, 566, 2009, 0, 567, + 568, 569, 0, 0, 196, 0, 0, 0, 200, 570, + 571, 572, 573, 574, 575, 576, 0, 577, 201, 578, + 202, 579, 580, 581, 0, 582, 583, 584, 585, 586, + 587, 588, 204, 589, 590, 591, 592, 0, 593, 594, + 595, 596, 597, 598, 599, 600, 601, 602, 0, 603, + 604, 0, 605, 606, 212, 607, 608, 609, 610, 611, + 612, 613, 614, 0, 615, 616, 617, 618, 619, 0, + 620, 217, 621, 622, 0, 623, 220, 624, 0, 625, + 626, 627, 628, 629, 630, 631, 632, 633, 634, 222, + 0, 635, 636, 0, 637, 638, 639, 640, 641, 642, + 0, 224, 225, 0, 0, 644, 226, 645, 227, 2010, + 646, 647, 648, 649, 650, 651, 652, 0, 0, 653, + 654, 655, 656, 657, 0, 0, 658, 659, 660, 661, + 662, 663, 234, 0, 664, 0, 665, 666, 667, 0, + 0, 668, 0, 0, 669, 670, 671, 672, 673, 237, + 238, 239, 240, 241, 242, 243, 244, 245, 674, 675, + 676, 0, 0, 0, 0, 0, 0, 0, 976, 1637, + 86, 87, 88, 412, 90, 91, 92, 413, 0, 414, + 95, 0, 0, 98, 99, 100, 101, 102, 103, 0, + 104, 105, 415, 0, 0, 107, 108, 109, 110, 0, + 0, 112, 113, 114, 115, 0, 116, 0, 0, 416, + 417, 0, 0, 0, 418, 419, 0, 0, 0, 0, + 420, 0, 0, 0, 0, 0, 0, 0, 0, 421, + 0, 422, 0, 423, 424, 35, 425, 0, 0, 0, + 0, 0, 0, 41, 42, 0, 0, 0, 0, 0, + 45, 0, 0, 0, 0, 426, 965, 428, 429, 430, + 431, 432, 433, 966, 434, 435, 436, 0, 0, 0, + 0, 0, 0, 0, 437, 438, 0, 439, 440, 0, + 967, 442, 443, 135, 136, 0, 138, 139, 0, 444, + 445, 446, 447, 448, 0, 0, 449, 450, 451, 140, + 452, 0, 453, 454, 455, 456, 144, 0, 0, 0, + 457, 458, 459, 460, 0, 461, 462, 0, 463, 464, + 465, 466, 467, 468, 0, 0, 469, 0, 0, 0, + 0, 0, 0, 0, 0, 470, 471, 472, 473, 474, + 475, 155, 156, 476, 0, 477, 0, 478, 479, 480, + 481, 482, 0, 483, 484, 485, 0, 0, 486, 487, + 488, 489, 490, 0, 491, 492, 493, 0, 494, 495, + 0, 496, 497, 498, 499, 164, 500, 501, 502, 166, + 0, 503, 0, 968, 168, 505, 0, 506, 0, 969, + 0, 970, 0, 508, 509, 510, 0, 511, 172, 0, + 512, 0, 513, 514, 515, 516, 517, 0, 518, 519, + 520, 971, 521, 522, 523, 524, 525, 526, 0, 527, + 0, 175, 0, 528, 529, 530, 0, 176, 0, 177, + 0, 531, 0, 0, 532, 0, 533, 534, 535, 536, + 972, 538, 539, 0, 540, 181, 0, 541, 0, 0, + 542, 543, 544, 0, 0, 545, 546, 547, 548, 549, + 550, 551, 552, 553, 554, 555, 556, 188, 0, 190, + 973, 558, 191, 0, 559, 560, 0, 561, 0, 194, + 562, 195, 563, 564, 565, 0, 566, 0, 0, 567, + 568, 569, 0, 0, 196, 0, 0, 0, 200, 570, + 571, 572, 573, 574, 575, 576, 0, 577, 201, 578, + 202, 579, 580, 581, 0, 974, 583, 584, 585, 586, + 587, 588, 204, 589, 590, 591, 592, 0, 593, 975, + 595, 596, 597, 598, 599, 600, 601, 602, 0, 603, + 604, 0, 605, 606, 212, 607, 608, 609, 610, 611, + 612, 613, 614, 0, 615, 616, 617, 618, 619, 0, + 620, 217, 621, 622, 0, 623, 220, 624, 0, 625, + 626, 627, 628, 629, 630, 631, 632, 633, 634, 222, + 0, 635, 636, 0, 637, 638, 639, 640, 641, 642, + 0, 224, 225, 0, 0, 644, 226, 645, 227, 0, + 646, 647, 648, 649, 650, 651, 652, 0, 0, 653, + 654, 655, 656, 657, 0, 0, 658, 659, 660, 661, + 662, 663, 234, 0, 664, 0, 665, 666, 667, 0, + 0, 668, 0, 0, 669, 670, 671, 672, 673, 237, + 238, 239, 240, 241, 242, 243, 244, 245, 674, 675, + 676, 0, 0, 0, 0, 0, 0, 0, 976, 977, + 86, 87, 88, 412, 90, 91, 92, 413, 0, 414, + 95, 0, 0, 98, 99, 100, 101, 102, 103, 0, + 104, 105, 415, 0, 0, 107, 108, 109, 110, 0, + 0, 112, 113, 114, 115, 0, 116, 0, 0, 416, + 417, 0, 0, 0, 418, 419, 0, 0, 0, 0, + 420, 0, 0, 0, 0, 0, 0, 0, 0, 421, + 0, 422, 0, 423, 424, 35, 425, 0, 0, 0, + 0, 0, 0, 41, 42, 0, 0, 0, 0, 0, + 45, 0, 0, 0, 0, 426, 965, 428, 429, 430, + 431, 432, 433, 966, 434, 435, 436, 0, 0, 0, + 0, 0, 0, 0, 437, 438, 0, 439, 440, 0, + 998, 442, 443, 135, 136, 0, 138, 139, 0, 444, + 445, 446, 447, 448, 0, 0, 449, 450, 451, 140, + 452, 0, 453, 454, 455, 456, 144, 0, 0, 0, + 457, 458, 459, 460, 0, 461, 462, 0, 463, 464, + 465, 466, 467, 468, 0, 0, 469, 0, 0, 0, + 0, 0, 0, 0, 0, 470, 471, 472, 473, 474, + 475, 155, 156, 476, 0, 477, 0, 478, 479, 480, + 481, 482, 0, 483, 484, 485, 0, 0, 486, 487, + 488, 489, 490, 0, 491, 492, 493, 0, 494, 495, + 0, 496, 497, 498, 499, 164, 500, 501, 502, 166, + 0, 503, 0, 968, 168, 505, 0, 506, 0, 999, + 0, 970, 0, 508, 509, 510, 0, 511, 172, 0, + 512, 0, 513, 514, 515, 516, 517, 0, 518, 519, + 520, 971, 521, 522, 523, 524, 525, 526, 0, 527, + 0, 175, 0, 528, 529, 530, 0, 176, 0, 177, + 0, 531, 0, 0, 532, 0, 533, 534, 535, 536, + 972, 538, 539, 0, 540, 181, 0, 541, 0, 0, + 542, 543, 544, 0, 0, 545, 546, 547, 548, 549, + 550, 551, 552, 553, 554, 555, 556, 188, 0, 190, + 973, 558, 191, 0, 559, 560, 0, 561, 0, 194, + 562, 195, 563, 564, 565, 0, 566, 0, 0, 567, + 568, 569, 0, 0, 196, 0, 0, 0, 200, 570, + 571, 572, 573, 574, 575, 576, 0, 577, 201, 578, + 202, 579, 580, 581, 0, 974, 583, 584, 585, 586, + 587, 588, 204, 589, 590, 591, 592, 0, 593, 975, + 595, 596, 597, 598, 599, 600, 601, 602, 0, 603, + 604, 0, 605, 606, 212, 607, 608, 609, 610, 611, + 612, 613, 614, 0, 615, 616, 617, 618, 619, 0, + 620, 217, 621, 622, 0, 623, 220, 624, 0, 625, + 626, 627, 628, 629, 630, 631, 632, 633, 634, 222, + 0, 635, 636, 0, 637, 638, 639, 640, 641, 642, + 0, 224, 225, 0, 0, 644, 226, 645, 227, 0, + 646, 647, 648, 649, 650, 651, 652, 0, 0, 653, + 654, 655, 656, 657, 0, 0, 658, 659, 660, 661, + 662, 663, 234, 0, 664, 0, 665, 666, 667, 0, + 0, 668, 0, 0, 669, 670, 671, 672, 673, 237, + 238, 239, 240, 241, 242, 243, 244, 245, 674, 675, + 676, 0, 0, 0, 0, 0, 0, 0, 976, 977, + 86, 87, 88, 412, 90, 91, 92, 413, 0, 414, + 95, 0, 0, 98, 99, 100, 101, 102, 103, 0, + 104, 105, 415, 0, 0, 107, 108, 109, 110, 0, + 0, 112, 113, 114, 115, 0, 116, 0, 0, 416, + 417, 0, 0, 0, 418, 419, 0, 0, 0, 0, + 420, 0, 0, 0, 0, 0, 0, 0, 0, 421, + 0, 422, 0, 423, 424, 35, 425, 0, 0, 0, + 0, 0, 0, 41, 42, 0, 0, 0, 0, 0, + 45, 0, 0, 0, 0, 426, 427, 428, 429, 430, + 431, 432, 433, 1372, 434, 435, 436, 0, 0, 0, + 0, 0, 0, 0, 437, 438, 0, 439, 440, 0, + 441, 442, 443, 135, 136, 0, 138, 139, 0, 444, + 445, 446, 447, 448, 0, 0, 449, 450, 451, 140, + 452, 0, 453, 454, 455, 456, 144, 0, 0, 0, + 457, 458, 459, 460, 0, 461, 462, 0, 463, 464, + 465, 466, 467, 468, 0, 0, 469, 0, 0, 0, + 0, 0, 0, 0, 0, 470, 471, 472, 473, 474, + 475, 155, 156, 476, 0, 477, 0, 478, 479, 480, + 481, 482, 0, 483, 484, 485, 0, 0, 486, 487, + 488, 489, 490, 0, 491, 492, 493, 0, 494, 495, + 0, 496, 497, 498, 499, 164, 500, 501, 502, 166, + 0, 503, 0, 504, 168, 505, 0, 506, 0, 507, + 0, 970, 0, 508, 509, 510, 0, 511, 172, 0, + 512, 0, 513, 514, 515, 516, 517, 0, 518, 519, + 520, 971, 521, 522, 523, 524, 525, 526, 0, 527, + 0, 175, 0, 528, 529, 530, 0, 176, 0, 177, + 0, 531, 0, 0, 532, 0, 533, 534, 535, 536, + 537, 538, 539, 0, 540, 181, 0, 541, 0, 0, + 542, 543, 544, 0, 0, 545, 546, 547, 548, 549, + 550, 551, 552, 553, 554, 555, 556, 188, 0, 190, + 557, 558, 191, 0, 559, 560, 0, 561, 0, 194, + 562, 195, 563, 564, 565, 0, 566, 0, 0, 567, + 568, 569, 0, 0, 196, 0, 0, 0, 200, 570, + 571, 572, 573, 574, 575, 576, 0, 577, 201, 578, + 202, 579, 580, 581, 0, 582, 583, 584, 585, 586, + 587, 588, 204, 589, 590, 591, 592, 0, 593, 594, + 595, 596, 597, 598, 599, 600, 601, 602, 0, 603, + 604, 0, 605, 606, 212, 607, 608, 609, 610, 611, + 612, 613, 614, 0, 615, 616, 617, 618, 619, 0, + 620, 217, 621, 622, 0, 623, 220, 624, 0, 625, + 626, 627, 628, 629, 630, 631, 632, 633, 634, 222, + 0, 635, 636, 0, 637, 638, 639, 640, 641, 642, + 0, 224, 225, 0, 0, 644, 226, 645, 227, 0, + 646, 647, 648, 649, 650, 651, 652, 0, 0, 653, + 654, 655, 656, 657, 0, 0, 658, 659, 660, 661, + 662, 663, 234, 0, 664, 0, 665, 666, 667, 0, + 0, 668, 0, 0, 669, 670, 671, 672, 673, 237, + 238, 239, 240, 241, 242, 243, 244, 245, 674, 675, + 676, 0, 0, 0, 0, 0, 0, 0, 976, 977, + 86, 87, 88, 412, 90, 91, 92, 413, 0, 414, + 95, 0, 0, 98, 99, 100, 101, 102, 103, 0, + 104, 105, 415, 0, 0, 107, 108, 109, 110, 0, + 0, 112, 113, 114, 115, 0, 116, 0, 0, 416, + 417, 0, 0, 0, 418, 419, 0, 0, 0, 0, + 420, 0, 0, 0, 0, 0, 0, 0, 0, 421, + 0, 422, 0, 423, 424, 35, 425, 0, 0, 0, + 0, 0, 0, 41, 42, 0, 0, 0, 0, 0, + 45, 0, 0, 0, 0, 426, 427, 428, 429, 430, + 431, 432, 433, 1377, 434, 435, 436, 0, 0, 0, + 0, 0, 0, 0, 437, 438, 0, 439, 440, 0, + 441, 442, 443, 135, 136, 0, 138, 139, 0, 444, + 445, 446, 447, 448, 0, 0, 449, 450, 451, 140, + 452, 0, 453, 454, 455, 456, 144, 0, 0, 0, + 457, 458, 459, 460, 0, 461, 462, 0, 463, 464, + 465, 466, 467, 468, 0, 0, 469, 0, 0, 0, + 0, 0, 0, 0, 0, 470, 471, 472, 473, 474, + 475, 155, 156, 476, 0, 477, 0, 478, 479, 480, + 481, 482, 0, 483, 484, 485, 0, 0, 486, 487, + 488, 489, 490, 0, 491, 492, 493, 0, 494, 495, + 0, 496, 497, 498, 499, 164, 500, 501, 502, 166, + 0, 503, 0, 504, 168, 505, 0, 506, 0, 507, + 0, 970, 0, 508, 509, 510, 0, 511, 172, 0, + 512, 0, 513, 514, 515, 516, 517, 0, 518, 519, + 520, 971, 521, 522, 523, 524, 525, 526, 0, 527, + 0, 175, 0, 528, 529, 530, 0, 176, 0, 177, + 0, 531, 0, 0, 532, 0, 533, 534, 535, 536, + 537, 538, 539, 0, 540, 181, 0, 541, 0, 0, + 542, 543, 544, 0, 0, 545, 546, 547, 548, 549, + 550, 551, 552, 553, 554, 555, 556, 188, 0, 190, + 557, 558, 191, 0, 559, 560, 0, 561, 0, 194, + 562, 195, 563, 564, 565, 0, 566, 0, 0, 567, + 568, 569, 0, 0, 196, 0, 0, 0, 200, 570, + 571, 572, 573, 574, 575, 576, 0, 577, 201, 578, + 202, 579, 580, 581, 0, 582, 583, 584, 585, 586, + 587, 588, 204, 589, 590, 591, 592, 0, 593, 594, + 595, 596, 597, 598, 599, 600, 601, 602, 0, 603, + 604, 0, 605, 606, 212, 607, 608, 609, 610, 611, + 612, 613, 614, 0, 615, 616, 617, 618, 619, 0, + 620, 217, 621, 622, 0, 623, 220, 624, 0, 625, + 626, 627, 628, 629, 630, 631, 632, 633, 634, 222, + 0, 635, 636, 0, 637, 638, 639, 640, 641, 642, + 0, 224, 225, 0, 0, 644, 226, 645, 227, 0, + 646, 647, 648, 649, 650, 651, 652, 0, 0, 653, + 654, 655, 656, 657, 0, 0, 658, 659, 660, 661, + 662, 663, 234, 0, 664, 0, 665, 666, 667, 0, + 0, 668, 0, 0, 669, 670, 671, 672, 673, 237, + 238, 239, 240, 241, 242, 243, 244, 245, 674, 675, + 676, 0, 0, 0, 0, 0, 0, 0, 976, 977, + 86, 87, 88, 412, 90, 91, 92, 413, 0, 414, + 95, 0, 0, 98, 99, 100, 101, 102, 103, 0, + 104, 105, 415, 0, 0, 107, 108, 109, 110, 0, + 0, 112, 113, 114, 115, 0, 116, 0, 0, 416, + 417, 0, 0, 0, 418, 419, 0, 0, 0, 0, + 420, 0, 0, 0, 0, 0, 0, 0, 0, 421, + 0, 422, 0, 423, 424, 35, 425, 0, 0, 0, + 0, 0, 0, 41, 42, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 426, 427, 428, 429, 430, + 431, 432, 433, 0, 434, 435, 436, 0, 0, 0, + 0, 0, 0, 0, 437, 438, 0, 439, 440, 0, + 441, 442, 443, 135, 136, 0, 138, 139, 0, 444, + 445, 446, 447, 448, 0, 0, 449, 450, 451, 140, + 452, 0, 453, 454, 455, 456, 144, 0, 0, 0, + 457, 458, 459, 460, 0, 461, 462, 0, 463, 464, + 465, 466, 467, 468, 0, 0, 469, 0, 0, 0, + 0, 0, 0, 0, 0, 470, 471, 472, 473, 474, + 475, 155, 156, 476, 698, 477, 0, 478, 479, 480, + 481, 482, 0, 483, 484, 485, 0, 0, 486, 487, + 488, 489, 490, 0, 491, 492, 493, 0, 494, 495, + 0, 496, 497, 498, 499, 164, 500, 501, 502, 166, + 0, 503, 0, 504, 168, 505, 0, 506, 0, 507, + 0, 0, 0, 508, 509, 510, 0, 511, 172, 0, + 512, 0, 513, 514, 515, 516, 517, 0, 518, 519, + 520, 0, 521, 522, 523, 524, 525, 526, 0, 527, + 0, 175, 0, 528, 529, 530, 0, 176, 0, 177, + 0, 531, 0, 0, 532, 0, 533, 534, 535, 536, + 537, 538, 539, 0, 540, 181, 0, 541, 0, 0, + 542, 543, 544, 0, 0, 545, 546, 547, 548, 549, + 550, 551, 552, 553, 554, 555, 556, 188, 0, 190, + 557, 558, 191, 0, 559, 560, 0, 561, 0, 194, + 562, 195, 563, 564, 565, 0, 566, 0, 0, 567, + 568, 569, 0, 0, 196, 0, 0, 0, 200, 570, + 571, 572, 573, 574, 575, 576, 0, 577, 201, 578, + 202, 579, 580, 581, 0, 582, 583, 584, 585, 586, + 587, 588, 204, 589, 590, 591, 592, 0, 593, 594, + 595, 596, 597, 598, 599, 600, 601, 602, 0, 603, + 604, 0, 605, 606, 212, 607, 608, 609, 610, 611, + 612, 613, 614, 0, 615, 616, 617, 618, 619, 0, + 620, 217, 621, 622, 0, 623, 220, 624, 0, 625, + 626, 627, 628, 629, 630, 631, 632, 633, 634, 222, + 0, 635, 636, 0, 637, 638, 639, 640, 641, 642, + 0, 224, 225, 1540, 0, 644, 226, 645, 227, 0, + 646, 647, 648, 649, 650, 651, 652, 0, 0, 653, + 654, 655, 656, 657, 0, 0, 658, 659, 660, 661, + 662, 663, 234, 0, 664, 0, 665, 666, 667, 0, + 0, 668, 0, 0, 669, 670, 671, 672, 673, 237, + 238, 239, 240, 241, 242, 243, 244, 245, 674, 675, + 676, 0, 0, 1037, 1541, 86, 87, 88, 412, 90, + 91, 92, 413, 1038, 414, 95, 0, 0, 98, 99, + 100, 101, 102, 103, 0, 104, 105, 415, 0, 0, + 107, 108, 109, 110, 0, 0, 112, 113, 114, 115, + 0, 116, 0, 0, 416, 417, 0, 0, 0, 418, + 419, 0, 0, 0, 0, 420, 0, 0, 0, 0, + 0, 0, 0, 0, 421, 0, 422, 0, 423, 424, + 35, 0, 0, 0, 0, 0, 0, 0, 41, 42, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 426, 427, 428, 429, 430, 431, 432, 433, 0, 434, + 435, 436, 0, 0, 0, 0, 0, 0, 0, 437, + 438, 0, 439, 440, 0, 441, 442, 443, 135, 136, + 0, 138, 139, 0, 444, 445, 446, 447, 448, 0, + 0, 1039, 450, 1013, 140, 452, 0, 453, 454, 455, + 456, 144, 0, 0, 0, 457, 458, 459, 460, 0, + 461, 1040, 0, 1041, 464, 465, 466, 467, 468, 0, + 0, 469, 0, 0, 0, 0, 0, 0, 0, 0, + 470, 471, 472, 473, 474, 475, 155, 156, 476, 0, + 477, 0, 478, 479, 480, 481, 482, 0, 483, 484, + 485, 0, 0, 486, 487, 488, 489, 490, 0, 491, + 492, 493, 0, 494, 495, 0, 496, 497, 498, 499, + 164, 500, 501, 502, 166, 0, 503, 0, 504, 168, + 505, 0, 506, 0, 507, 0, 0, 0, 508, 509, + 510, 0, 511, 172, 0, 512, 0, 513, 514, 515, + 516, 517, 0, 518, 519, 520, 0, 521, 522, 523, + 524, 525, 526, 0, 527, 0, 175, 0, 528, 529, + 530, 0, 176, 0, 177, 0, 531, 0, 0, 532, + 0, 533, 534, 535, 536, 537, 538, 539, 0, 540, + 181, 0, 541, 0, 0, 542, 543, 1042, 0, 0, + 545, 546, 547, 548, 549, 550, 551, 552, 553, 554, + 555, 1043, 188, 0, 190, 557, 558, 191, 0, 559, + 560, 0, 561, 0, 194, 562, 195, 563, 564, 565, + 0, 566, 0, 0, 567, 568, 569, 0, 0, 196, + 0, 0, 0, 200, 570, 571, 572, 573, 574, 575, + 576, 0, 577, 201, 578, 202, 579, 580, 581, 0, + 582, 583, 584, 585, 586, 587, 588, 204, 589, 590, + 591, 592, 0, 593, 594, 595, 596, 597, 598, 599, + 600, 601, 602, 0, 603, 604, 0, 1044, 606, 212, + 607, 608, 609, 1045, 611, 612, 613, 614, 0, 615, + 616, 617, 618, 1046, 0, 620, 217, 621, 622, 0, + 623, 220, 624, 0, 625, 626, 627, 628, 629, 630, + 631, 632, 633, 634, 222, 0, 635, 636, 0, 637, + 638, 639, 640, 641, 642, 0, 1047, 225, 0, 0, + 1048, 226, 645, 227, 0, 646, 647, 648, 649, 650, + 651, 652, 0, 0, 653, 654, 655, 656, 657, 0, + 0, 658, 659, 660, 661, 662, 1017, 234, 0, 664, + 0, 665, 666, 667, 0, 0, 668, 0, 0, 669, + 670, 671, 672, 1049, 237, 238, 239, 240, 241, 242, + 243, 244, 245, 674, 675, 676, 713, 86, 87, 88, + 412, 90, 91, 92, 413, 0, 414, 95, 0, 0, + 98, 99, 100, 101, 102, 103, 714, 104, 105, 415, + 715, 0, 107, 108, 109, 110, 716, 717, 112, 113, + 114, 115, 0, 116, 718, 719, 416, 417, 0, 0, + 0, 418, 419, 0, 0, 0, 0, 420, 0, 0, + 0, 0, 0, 0, 0, 0, 421, 0, 422, 0, + 423, 424, 35, 0, 0, 0, 37, 38, 39, 40, + 41, 42, 43, 44, 0, 0, 0, 45, 0, 0, + 0, 0, 426, 427, 428, 429, 430, 431, 432, 433, + 720, 434, 435, 436, 721, 722, 723, 724, 725, 726, + 727, 437, 438, 728, 439, 440, 133, 441, 442, 443, + 135, 136, 137, 138, 139, 729, 444, 445, 446, 447, + 448, 730, 731, 449, 450, 732, 140, 452, 733, 453, + 454, 455, 456, 144, 734, 145, 735, 457, 458, 459, + 460, 148, 461, 736, 737, 463, 464, 465, 466, 467, + 468, 738, 151, 469, 739, 740, 741, 742, 152, 743, + 744, 745, 470, 471, 472, 473, 474, 475, 155, 156, + 476, 746, 477, 747, 478, 479, 480, 481, 482, 748, + 483, 484, 485, 749, 750, 486, 487, 488, 489, 490, + 751, 491, 492, 493, 752, 494, 495, 753, 496, 497, + 498, 499, 164, 500, 501, 502, 166, 754, 503, 755, + 504, 168, 505, 756, 506, 757, 507, 169, 758, 170, + 508, 509, 510, 759, 511, 172, 760, 512, 761, 513, + 514, 515, 516, 517, 173, 518, 519, 520, 762, 521, + 522, 523, 524, 525, 526, 763, 527, 174, 175, 764, + 528, 529, 530, 765, 176, 766, 177, 767, 531, 178, + 179, 532, 180, 533, 534, 535, 536, 537, 538, 539, + 768, 540, 181, 182, 541, 183, 769, 542, 543, 544, + 770, 771, 545, 546, 547, 548, 549, 550, 551, 552, + 553, 554, 555, 556, 188, 189, 190, 557, 558, 191, + 772, 559, 560, 193, 561, 773, 194, 562, 195, 563, + 564, 565, 774, 566, 775, 776, 567, 568, 569, 777, + 778, 196, 197, 198, 199, 200, 570, 571, 572, 573, + 574, 575, 576, 779, 577, 201, 578, 202, 579, 580, + 581, 780, 582, 583, 584, 585, 586, 587, 588, 204, + 589, 590, 591, 592, 781, 593, 594, 595, 596, 597, + 598, 599, 600, 601, 602, 782, 603, 604, 210, 605, + 606, 212, 607, 608, 609, 610, 611, 612, 613, 614, + 783, 615, 616, 617, 618, 619, 784, 620, 217, 621, + 622, 219, 623, 220, 624, 785, 625, 626, 627, 628, + 629, 630, 631, 632, 633, 634, 222, 786, 635, 636, + 787, 637, 638, 639, 640, 641, 642, 788, 224, 225, + 789, 790, 644, 226, 645, 227, 791, 646, 647, 648, + 649, 650, 651, 652, 792, 793, 653, 654, 655, 656, + 657, 794, 795, 658, 659, 660, 661, 662, 796, 234, + 797, 664, 235, 665, 666, 667, 798, 799, 668, 800, + 801, 669, 670, 671, 672, 673, 237, 238, 239, 240, + 241, 242, 243, 244, 245, 674, 675, 676, 713, 86, + 87, 88, 412, 90, 91, 92, 413, 0, 414, 95, + 0, 0, 98, 99, 100, 101, 102, 103, 714, 104, + 105, 415, 715, 0, 107, 108, 109, 110, 716, 717, + 112, 113, 114, 115, 0, 116, 718, 719, 416, 417, + 0, 0, 0, 418, 419, 0, 0, 0, 0, 420, + 0, 0, 0, 0, 0, 0, 0, 0, 421, 0, + 422, 0, 423, 424, 35, 0, 0, 0, 0, 0, + 0, 0, 41, 42, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 426, 427, 428, 429, 430, 431, + 432, 433, 720, 434, 435, 436, 721, 722, 723, 724, + 725, 726, 727, 437, 438, 728, 439, 440, 133, 441, + 442, 443, 135, 136, 137, 138, 139, 729, 444, 445, + 446, 447, 448, 730, 731, 449, 450, 732, 140, 452, + 733, 453, 454, 455, 456, 144, 734, 145, 735, 457, + 458, 459, 460, 148, 461, 736, 737, 463, 464, 465, + 466, 467, 468, 738, 151, 469, 739, 740, 741, 742, + 152, 743, 744, 745, 470, 471, 472, 473, 474, 475, + 155, 156, 476, 746, 477, 747, 478, 479, 480, 481, + 482, 748, 483, 484, 485, 749, 750, 486, 487, 488, + 489, 490, 751, 491, 492, 493, 752, 494, 495, 753, + 496, 497, 498, 499, 164, 500, 501, 502, 166, 754, + 503, 755, 504, 168, 505, 756, 506, 757, 507, 169, + 758, 170, 508, 509, 510, 759, 511, 172, 760, 512, + 761, 513, 514, 515, 516, 517, 173, 518, 519, 520, + 762, 521, 522, 523, 524, 525, 526, 763, 527, 174, + 175, 764, 528, 529, 530, 765, 176, 766, 177, 767, + 531, 178, 179, 532, 180, 533, 534, 535, 536, 537, + 538, 539, 768, 540, 181, 182, 541, 183, 769, 542, + 543, 544, 770, 771, 545, 546, 547, 548, 549, 550, + 551, 552, 553, 554, 555, 556, 188, 189, 190, 557, + 558, 191, 772, 559, 560, 193, 561, 773, 194, 562, + 195, 563, 564, 565, 774, 566, 775, 776, 567, 568, + 569, 777, 778, 196, 197, 198, 199, 200, 570, 571, + 572, 573, 574, 575, 576, 779, 577, 201, 578, 202, + 579, 580, 581, 780, 582, 583, 584, 585, 586, 587, + 588, 204, 589, 590, 591, 592, 781, 593, 594, 595, + 596, 597, 598, 599, 600, 601, 602, 782, 603, 604, + 210, 605, 606, 212, 607, 608, 609, 610, 611, 612, + 613, 614, 783, 615, 616, 617, 618, 619, 784, 620, + 217, 621, 622, 219, 623, 220, 624, 785, 625, 626, + 627, 628, 629, 630, 631, 632, 633, 634, 222, 786, + 635, 636, 787, 637, 638, 639, 640, 641, 642, 788, + 224, 225, 789, 790, 644, 226, 645, 227, 791, 646, + 647, 648, 649, 650, 651, 652, 792, 793, 653, 654, + 655, 656, 657, 794, 795, 658, 659, 660, 661, 662, + 796, 234, 797, 664, 235, 665, 666, 667, 798, 799, + 668, 800, 801, 669, 670, 671, 672, 673, 237, 238, + 239, 240, 241, 242, 243, 244, 245, 674, 675, 676, + 713, 86, 87, 88, 412, 90, 91, 92, 413, 0, + 414, 95, 0, 0, 98, 99, 100, 101, 102, 103, + 714, 104, 105, 415, 715, 0, 107, 108, 109, 110, + 716, 717, 112, 113, 114, 115, 0, 116, 718, 719, + 416, 417, 0, 0, 0, 418, 419, 0, 0, 0, + 0, 420, 0, 0, 0, 0, 0, 0, 0, 0, + 421, 0, 422, 0, 423, 424, 35, 0, 0, 0, + 0, 0, 0, 0, 41, 42, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 426, 427, 428, 429, + 3110, 431, 432, 433, 720, 434, 435, 436, 721, 722, + 723, 724, 725, 726, 727, 437, 438, 728, 439, 440, + 133, 441, 442, 443, 135, 136, 137, 138, 139, 729, + 444, 445, 446, 447, 448, 730, 731, 449, 450, 732, + 140, 452, 733, 453, 454, 455, 456, 144, 734, 145, + 735, 457, 458, 459, 460, 148, 461, 736, 737, 463, + 464, 465, 466, 467, 468, 738, 151, 469, 739, 740, + 741, 742, 152, 743, 744, 745, 470, 471, 472, 473, + 474, 475, 155, 156, 476, 746, 477, 747, 478, 479, + 480, 481, 482, 748, 483, 484, 485, 749, 750, 486, + 487, 488, 3111, 490, 751, 491, 492, 493, 752, 494, + 495, 753, 496, 497, 498, 499, 164, 500, 501, 502, + 166, 754, 503, 755, 504, 168, 505, 756, 506, 757, + 507, 169, 758, 170, 508, 509, 510, 759, 511, 172, + 760, 512, 761, 513, 514, 515, 516, 517, 173, 518, + 519, 520, 762, 521, 522, 523, 524, 525, 526, 763, + 527, 174, 175, 764, 528, 529, 530, 765, 176, 766, + 177, 767, 531, 178, 179, 532, 180, 533, 534, 535, + 536, 537, 538, 539, 768, 540, 181, 182, 541, 183, + 769, 542, 543, 544, 770, 771, 545, 546, 547, 548, + 549, 550, 551, 552, 553, 554, 555, 556, 188, 189, + 190, 557, 558, 191, 772, 559, 560, 193, 561, 773, + 194, 562, 195, 563, 564, 565, 774, 566, 775, 776, + 567, 568, 569, 777, 778, 196, 197, 198, 199, 200, + 570, 571, 572, 573, 574, 575, 576, 779, 577, 201, + 578, 202, 579, 580, 581, 780, 582, 583, 584, 585, + 586, 587, 588, 204, 589, 590, 591, 592, 781, 593, + 594, 595, 596, 597, 598, 599, 600, 601, 602, 782, + 603, 604, 210, 605, 606, 212, 607, 608, 609, 610, + 611, 612, 613, 614, 783, 615, 616, 617, 618, 619, + 784, 3112, 217, 621, 622, 219, 623, 220, 624, 785, + 625, 626, 627, 628, 629, 630, 631, 632, 633, 634, + 222, 786, 635, 636, 787, 637, 638, 639, 640, 641, + 642, 788, 224, 225, 789, 790, 644, 226, 645, 227, + 791, 646, 647, 648, 649, 650, 651, 652, 792, 793, + 653, 654, 655, 656, 657, 794, 795, 658, 659, 660, + 661, 662, 796, 234, 797, 664, 235, 665, 666, 667, + 798, 799, 668, 800, 801, 669, 670, 671, 672, 673, + 237, 238, 239, 240, 241, 242, 243, 244, 245, 674, + 675, 676, 713, 86, 87, 88, 412, 90, 91, 92, + 413, 0, 414, 95, 0, 0, 98, 99, 100, 101, + 102, 103, 714, 104, 105, 415, 715, 0, 107, 108, + 109, 110, 716, 717, 112, 113, 114, 115, 0, 116, + 718, 719, 416, 417, 0, 0, 0, 418, 419, 0, + 0, 0, 0, 420, 0, 0, 0, 0, 0, 0, + 0, 0, 421, 0, 422, 0, 423, 424, 35, 0, + 0, 0, 0, 0, 0, 0, 41, 42, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 426, 427, + 428, 429, 430, 431, 432, 433, 0, 434, 435, 436, + 0, 0, 0, 0, 0, 0, 0, 437, 438, 0, + 439, 440, 133, 441, 442, 443, 135, 136, 137, 138, + 139, 0, 444, 445, 446, 447, 448, 0, 0, 449, + 450, 451, 140, 452, 0, 453, 454, 455, 456, 144, + 0, 145, 0, 457, 458, 459, 460, 148, 461, 462, + 0, 463, 464, 465, 466, 467, 468, 0, 151, 469, + 0, 0, 0, 0, 152, 0, 0, 0, 470, 471, + 472, 473, 474, 475, 155, 156, 476, 0, 477, 0, + 478, 479, 480, 481, 482, 0, 483, 484, 485, 0, + 0, 486, 487, 488, 489, 490, 0, 491, 492, 493, + 0, 494, 495, 0, 496, 497, 498, 499, 164, 500, + 501, 502, 166, 0, 503, 0, 504, 168, 505, 0, + 506, 0, 507, 169, 0, 170, 508, 509, 510, 0, + 511, 172, 0, 512, 0, 513, 514, 515, 516, 517, + 173, 518, 519, 520, 0, 521, 522, 523, 524, 525, + 526, 0, 527, 174, 175, 0, 528, 529, 530, 0, + 176, 0, 177, 0, 531, 178, 179, 532, 180, 533, + 534, 535, 536, 537, 538, 539, 0, 540, 181, 182, + 541, 183, 0, 542, 543, 544, 0, 0, 545, 546, + 547, 548, 549, 550, 551, 552, 553, 554, 555, 556, + 188, 189, 190, 557, 558, 191, 0, 559, 560, 193, + 561, 0, 194, 562, 195, 563, 564, 565, 0, 566, + 0, 0, 567, 568, 569, 0, 0, 196, 197, 198, + 199, 200, 570, 571, 572, 573, 574, 575, 576, 0, + 577, 201, 578, 202, 579, 580, 581, 0, 582, 583, + 584, 585, 586, 587, 588, 204, 589, 590, 591, 592, + 0, 593, 594, 595, 596, 597, 598, 599, 600, 601, + 602, 0, 603, 604, 210, 605, 606, 212, 607, 608, + 609, 610, 611, 612, 613, 614, 0, 615, 616, 617, + 618, 619, 0, 620, 217, 621, 622, 219, 623, 220, + 624, 0, 625, 626, 627, 628, 629, 630, 631, 632, + 633, 634, 222, 0, 635, 636, 0, 637, 638, 639, + 640, 641, 642, 0, 224, 225, 0, 0, 644, 226, + 645, 227, 0, 646, 647, 648, 649, 650, 651, 652, + 0, 0, 653, 654, 655, 656, 657, 0, 0, 658, + 659, 660, 661, 662, 663, 234, 0, 664, 235, 665, + 666, 667, 0, 0, 668, 0, 0, 669, 670, 671, + 672, 673, 237, 238, 239, 240, 241, 242, 243, 244, + 245, 674, 675, 676, 713, 86, 87, 88, 412, 90, + 91, 92, 413, 0, 414, 95, 0, 0, 98, 99, + 100, 101, 102, 103, 714, 104, 105, 415, 715, 0, + 107, 108, 109, 110, 716, 717, 112, 113, 114, 115, + 0, 116, 718, 719, 416, 417, 0, 0, 0, 418, + 419, 0, 0, 0, 0, 420, 0, 0, 0, 0, + 0, 0, 0, 0, 421, 0, 422, 0, 423, 424, + 35, 0, 0, 0, 0, 0, 0, 0, 41, 42, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 426, 427, 428, 429, 430, 431, 432, 433, 0, 434, + 435, 436, 0, 0, 0, 0, 0, 0, 0, 437, + 438, 0, 439, 440, 133, 441, 442, 443, 135, 136, + 137, 138, 139, 0, 444, 445, 446, 447, 448, 0, + 0, 449, 450, 451, 140, 452, 0, 453, 454, 455, + 456, 144, 0, 145, 0, 457, 458, 459, 460, 148, + 461, 462, 0, 463, 464, 465, 466, 467, 468, 0, + 151, 469, 0, 0, 0, 0, 152, 0, 0, 0, + 470, 471, 472, 473, 474, 475, 155, 156, 476, 0, + 477, 0, 478, 479, 480, 481, 482, 0, 483, 484, + 485, 0, 0, 486, 487, 488, 489, 490, 0, 491, + 492, 493, 0, 494, 495, 0, 496, 497, 498, 499, + 164, 500, 501, 502, 166, 0, 503, 0, 504, 168, + 505, 0, 506, 0, 507, 169, 0, 170, 508, 509, + 510, 0, 511, 172, 0, 512, 0, 513, 514, 515, + 516, 1307, 173, 518, 519, 520, 0, 521, 522, 523, + 524, 525, 526, 0, 527, 174, 175, 0, 528, 529, + 530, 0, 176, 0, 177, 0, 531, 178, 179, 532, + 180, 533, 534, 535, 536, 537, 538, 539, 0, 540, + 181, 182, 541, 183, 0, 542, 543, 544, 0, 0, + 545, 546, 547, 548, 549, 550, 551, 552, 553, 554, + 555, 556, 188, 189, 190, 557, 558, 191, 0, 559, + 560, 193, 561, 0, 194, 562, 195, 563, 564, 565, + 0, 566, 0, 0, 567, 568, 569, 0, 0, 196, + 197, 198, 199, 200, 570, 571, 572, 573, 574, 575, + 576, 0, 577, 201, 578, 202, 579, 580, 581, 0, + 582, 583, 584, 585, 586, 587, 588, 204, 589, 590, + 591, 592, 0, 593, 594, 595, 596, 597, 598, 599, + 600, 601, 602, 0, 603, 604, 210, 605, 606, 212, + 607, 608, 609, 610, 611, 612, 613, 614, 0, 615, + 616, 617, 618, 619, 0, 620, 217, 621, 622, 219, + 623, 220, 624, 0, 625, 626, 627, 628, 629, 630, + 631, 632, 633, 634, 222, 0, 635, 636, 0, 637, + 638, 639, 640, 641, 642, 0, 224, 225, 0, 0, + 644, 226, 645, 227, 0, 646, 647, 648, 649, 650, + 651, 652, 0, 0, 653, 654, 655, 656, 657, 0, + 0, 658, 659, 660, 661, 662, 663, 234, 0, 664, + 235, 665, 666, 667, 0, 0, 668, 0, 0, 669, + 670, 671, 672, 673, 237, 238, 239, 240, 241, 242, + 243, 244, 245, 674, 675, 676, 713, 86, 87, 88, + 412, 90, 91, 92, 413, 0, 414, 95, 0, 0, + 98, 99, 100, 101, 102, 103, 714, 104, 105, 415, + 715, 0, 107, 108, 109, 110, 716, 717, 112, 113, + 114, 115, 0, 116, 718, 719, 416, 417, 0, 0, + 0, 418, 419, 0, 0, 0, 0, 420, 0, 0, + 0, 0, 0, 0, 0, 0, 421, 0, 422, 0, + 423, 424, 35, 0, 0, 0, 0, 0, 0, 0, + 41, 42, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 426, 427, 428, 429, 430, 431, 432, 433, + 0, 434, 435, 436, 0, 0, 0, 0, 0, 0, + 0, 437, 438, 0, 439, 440, 133, 441, 442, 443, + 135, 136, 137, 138, 139, 0, 444, 445, 446, 447, + 448, 0, 0, 449, 450, 451, 140, 452, 0, 453, + 454, 455, 456, 144, 0, 145, 0, 457, 458, 459, + 460, 148, 461, 462, 0, 463, 464, 465, 466, 467, + 468, 0, 151, 469, 0, 0, 0, 0, 152, 0, + 0, 0, 470, 471, 472, 473, 474, 475, 155, 156, + 476, 0, 477, 0, 478, 479, 480, 481, 482, 0, + 483, 484, 485, 0, 0, 486, 487, 488, 489, 490, + 0, 491, 492, 493, 0, 494, 495, 0, 496, 497, + 498, 499, 164, 500, 501, 502, 166, 0, 503, 0, + 504, 168, 505, 0, 506, 0, 507, 169, 0, 170, + 508, 509, 510, 0, 511, 172, 0, 512, 0, 513, + 514, 515, 516, 1316, 173, 518, 519, 520, 0, 521, + 522, 523, 524, 525, 526, 0, 527, 174, 175, 0, + 528, 529, 530, 0, 176, 0, 177, 0, 531, 178, + 179, 532, 180, 533, 534, 535, 536, 537, 538, 539, + 0, 540, 181, 182, 541, 183, 0, 542, 543, 544, + 0, 0, 545, 546, 547, 548, 549, 550, 551, 552, + 553, 554, 555, 556, 188, 189, 190, 557, 558, 191, + 0, 559, 560, 193, 561, 0, 194, 562, 195, 563, + 564, 565, 0, 566, 0, 0, 567, 568, 569, 0, + 0, 196, 197, 198, 199, 200, 570, 571, 572, 573, + 574, 575, 576, 0, 577, 201, 578, 202, 579, 580, + 581, 0, 582, 583, 584, 585, 586, 587, 588, 204, + 589, 590, 591, 592, 0, 593, 594, 595, 596, 597, + 598, 599, 600, 601, 602, 0, 603, 604, 210, 605, + 606, 212, 607, 608, 609, 610, 611, 612, 613, 614, + 0, 615, 616, 617, 618, 619, 0, 620, 217, 621, + 622, 219, 623, 220, 624, 0, 625, 626, 627, 628, + 629, 630, 631, 632, 633, 634, 222, 0, 635, 636, + 0, 637, 638, 639, 640, 641, 642, 0, 224, 225, + 0, 0, 644, 226, 645, 227, 0, 646, 647, 648, + 649, 650, 651, 652, 0, 0, 653, 654, 655, 656, + 657, 0, 0, 658, 659, 660, 661, 662, 663, 234, + 0, 664, 235, 665, 666, 667, 0, 0, 668, 0, + 0, 669, 670, 671, 672, 673, 237, 238, 239, 240, + 241, 242, 243, 244, 245, 674, 675, 676, 713, 86, + 87, 88, 412, 90, 91, 92, 413, 0, 414, 95, + 0, 0, 98, 99, 100, 101, 102, 103, 714, 104, + 105, 415, 715, 0, 107, 108, 109, 110, 716, 717, + 112, 113, 114, 115, 0, 116, 718, 719, 416, 417, + 0, 0, 0, 418, 419, 0, 0, 0, 0, 420, + 0, 0, 0, 0, 0, 0, 0, 0, 421, 0, + 422, 0, 423, 424, 35, 0, 0, 0, 0, 0, + 0, 0, 41, 42, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 426, 427, 428, 429, 430, 431, + 432, 433, 0, 434, 435, 436, 0, 0, 0, 0, + 0, 0, 0, 437, 438, 0, 439, 440, 133, 441, + 442, 443, 0, 1857, 137, 1858, 1859, 0, 444, 445, + 446, 447, 448, 0, 0, 449, 450, 1860, 1861, 452, + 0, 453, 454, 455, 456, 0, 0, 145, 0, 457, + 458, 459, 460, 148, 461, 462, 0, 463, 464, 465, + 466, 467, 468, 0, 151, 469, 0, 0, 0, 0, + 152, 0, 0, 0, 470, 471, 472, 473, 474, 475, + 1862, 1863, 476, 0, 477, 0, 478, 479, 480, 481, + 482, 0, 483, 484, 485, 0, 0, 486, 487, 1458, + 489, 490, 0, 491, 492, 493, 0, 494, 495, 0, + 496, 497, 498, 499, 0, 500, 501, 502, 0, 0, + 503, 0, 504, 1864, 505, 0, 506, 0, 507, 169, + 0, 170, 508, 509, 510, 0, 511, 0, 0, 512, + 0, 513, 514, 515, 516, 517, 173, 518, 519, 520, + 2418, 521, 522, 523, 524, 525, 526, 0, 527, 174, + 2419, 0, 528, 529, 530, 1464, 1865, 0, 1866, 0, + 531, 178, 179, 532, 180, 533, 534, 535, 536, 537, + 538, 539, 0, 540, 0, 182, 541, 183, 0, 542, + 543, 544, 0, 0, 545, 546, 547, 548, 549, 550, + 551, 552, 553, 554, 555, 556, 1867, 189, 1868, 557, + 558, 0, 0, 559, 560, 193, 561, 0, 0, 562, + 1869, 563, 564, 565, 0, 566, 0, 0, 567, 568, + 569, 0, 0, 2420, 197, 198, 199, 0, 570, 571, + 572, 573, 574, 575, 576, 0, 577, 0, 578, 0, + 579, 580, 581, 0, 582, 583, 584, 585, 586, 587, + 588, 1870, 589, 590, 591, 592, 0, 593, 594, 595, + 596, 597, 598, 599, 600, 601, 602, 0, 603, 604, + 210, 605, 606, 0, 607, 608, 609, 610, 611, 612, + 613, 614, 0, 615, 616, 617, 618, 619, 0, 620, + 2421, 621, 622, 219, 623, 1872, 624, 0, 625, 626, + 627, 628, 629, 630, 631, 632, 633, 634, 0, 0, + 635, 636, 0, 637, 638, 639, 640, 641, 642, 0, + 1873, 1874, 0, 0, 644, 0, 645, 0, 0, 646, + 647, 648, 649, 650, 651, 652, 0, 0, 653, 654, + 655, 656, 657, 0, 0, 658, 659, 660, 661, 662, + 0, 1875, 2422, 664, 235, 665, 666, 667, 0, 0, + 668, 0, 0, 669, 670, 671, 672, 673, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 674, 675, 676, + 713, 86, 87, 88, 412, 90, 91, 92, 413, 0, + 414, 95, 0, 0, 98, 99, 100, 101, 102, 103, + 714, 104, 105, 415, 715, 0, 107, 108, 109, 110, + 716, 717, 112, 113, 114, 115, 0, 116, 718, 719, + 416, 417, 0, 0, 0, 418, 419, 0, 0, 0, + 0, 420, 0, 0, 0, 0, 0, 0, 0, 0, + 421, 0, 422, 0, 423, 424, 35, 0, 0, 0, + 0, 0, 0, 0, 41, 42, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 426, 427, 428, 429, + 430, 431, 432, 433, 0, 434, 435, 436, 0, 0, + 0, 0, 0, 0, 0, 437, 438, 0, 439, 440, + 133, 441, 442, 443, 0, 1857, 137, 1858, 1859, 0, + 444, 445, 446, 447, 448, 0, 0, 449, 450, 1860, + 1861, 452, 0, 453, 454, 455, 456, 0, 0, 145, + 0, 457, 458, 459, 460, 148, 461, 462, 0, 463, + 464, 465, 466, 467, 468, 0, 151, 469, 0, 0, + 0, 0, 152, 0, 0, 0, 470, 471, 472, 473, + 474, 475, 1862, 1863, 476, 0, 477, 0, 478, 479, + 480, 481, 482, 0, 483, 484, 485, 0, 0, 486, + 487, 1458, 489, 490, 0, 491, 492, 493, 0, 494, + 495, 0, 496, 497, 498, 499, 0, 500, 501, 502, + 0, 0, 503, 0, 504, 1864, 505, 0, 506, 0, + 507, 169, 0, 170, 508, 509, 510, 0, 511, 0, + 0, 512, 0, 513, 514, 515, 516, 517, 173, 518, + 519, 520, 0, 521, 522, 523, 524, 525, 526, 0, + 527, 174, 0, 0, 528, 529, 530, 1464, 1865, 0, + 1866, 0, 531, 178, 179, 532, 180, 533, 534, 535, + 536, 537, 538, 539, 0, 540, 0, 182, 541, 183, + 0, 542, 543, 544, 0, 0, 545, 546, 547, 548, + 549, 550, 551, 552, 553, 554, 555, 556, 1867, 189, + 1868, 557, 558, 0, 0, 559, 560, 193, 561, 2406, + 0, 562, 1869, 563, 564, 565, 0, 566, 0, 0, + 567, 568, 569, 0, 0, 0, 197, 198, 199, 0, + 570, 571, 572, 573, 574, 575, 576, 0, 577, 0, + 578, 0, 579, 580, 581, 0, 582, 583, 584, 585, + 586, 587, 588, 1870, 589, 590, 591, 592, 0, 593, + 594, 595, 596, 597, 598, 599, 600, 601, 602, 0, + 603, 604, 210, 605, 606, 0, 607, 608, 609, 610, + 611, 612, 613, 614, 0, 615, 616, 617, 618, 619, + 0, 620, 2421, 621, 622, 219, 623, 1872, 624, 0, + 625, 626, 627, 628, 629, 630, 631, 632, 633, 634, + 0, 0, 635, 636, 3871, 637, 638, 639, 640, 641, + 642, 0, 1873, 1874, 0, 0, 644, 0, 645, 0, + 0, 646, 647, 648, 649, 650, 651, 652, 0, 0, + 653, 654, 655, 656, 657, 0, 0, 658, 659, 660, + 661, 662, 0, 1875, 0, 664, 235, 665, 666, 667, + 0, 0, 668, 0, 0, 669, 670, 671, 672, 673, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 674, + 675, 676, 713, 86, 87, 88, 412, 90, 91, 92, + 413, 0, 414, 95, 0, 0, 98, 99, 100, 101, + 102, 103, 714, 104, 105, 415, 715, 0, 107, 108, + 109, 110, 716, 717, 112, 113, 114, 115, 0, 116, + 718, 719, 416, 417, 0, 0, 0, 418, 419, 0, + 0, 0, 0, 420, 0, 0, 0, 0, 0, 0, + 0, 0, 421, 0, 422, 0, 423, 424, 35, 0, + 0, 0, 0, 0, 0, 0, 41, 42, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 426, 427, + 428, 429, 430, 431, 432, 433, 0, 434, 435, 436, + 0, 0, 0, 0, 0, 0, 0, 437, 438, 0, + 439, 440, 133, 441, 442, 443, 0, 1857, 137, 1858, + 1859, 0, 444, 445, 446, 447, 448, 0, 0, 449, + 450, 1860, 1861, 452, 0, 453, 454, 455, 456, 0, + 0, 145, 0, 457, 458, 459, 460, 148, 461, 462, + 0, 463, 464, 465, 466, 467, 468, 0, 151, 469, + 0, 0, 0, 0, 152, 0, 0, 0, 470, 471, + 472, 473, 474, 475, 1862, 1863, 476, 0, 477, 0, + 478, 479, 480, 481, 482, 0, 483, 484, 485, 0, + 0, 486, 487, 1458, 489, 490, 0, 491, 492, 493, + 0, 494, 495, 0, 496, 497, 498, 499, 0, 500, + 501, 502, 0, 0, 503, 0, 504, 1864, 505, 0, + 506, 0, 507, 169, 0, 170, 508, 509, 510, 0, + 511, 0, 0, 512, 0, 513, 514, 515, 516, 517, + 173, 518, 519, 520, 0, 521, 522, 523, 524, 525, + 526, 0, 527, 174, 0, 0, 528, 529, 530, 1464, + 1865, 0, 1866, 0, 531, 178, 179, 532, 180, 533, + 534, 535, 536, 537, 538, 539, 0, 540, 0, 182, + 541, 183, 0, 542, 543, 544, 0, 0, 545, 546, + 547, 548, 549, 550, 551, 552, 553, 554, 555, 556, + 1867, 189, 1868, 557, 558, 2468, 0, 559, 560, 193, + 561, 0, 0, 562, 1869, 563, 564, 565, 0, 566, + 0, 0, 567, 568, 569, 0, 0, 0, 197, 198, + 199, 0, 570, 571, 572, 573, 574, 575, 576, 0, + 577, 0, 578, 0, 579, 580, 581, 0, 582, 583, + 584, 585, 586, 587, 588, 1870, 589, 590, 591, 592, + 0, 593, 594, 595, 596, 597, 598, 599, 600, 601, + 602, 0, 603, 604, 210, 605, 606, 0, 607, 608, + 609, 610, 611, 612, 613, 614, 0, 615, 616, 617, + 618, 619, 0, 620, 1871, 621, 622, 219, 623, 1872, + 624, 0, 625, 626, 627, 628, 629, 630, 631, 632, + 633, 634, 0, 0, 635, 636, 0, 637, 638, 639, + 640, 641, 642, 0, 1873, 1874, 0, 0, 644, 0, + 645, 0, 0, 646, 647, 648, 649, 650, 651, 652, + 0, 0, 653, 654, 655, 656, 657, 0, 0, 658, + 659, 660, 661, 662, 0, 1875, 0, 664, 235, 665, + 666, 667, 0, 0, 668, 0, 0, 669, 670, 671, + 672, 673, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 674, 675, 676, 713, 86, 87, 88, 412, 90, + 91, 92, 413, 0, 414, 95, 0, 0, 98, 99, + 100, 101, 102, 103, 714, 104, 105, 415, 715, 0, + 107, 108, 109, 110, 716, 717, 112, 113, 114, 115, + 0, 116, 718, 719, 416, 417, 0, 0, 0, 418, + 419, 0, 0, 0, 0, 420, 0, 0, 0, 0, + 0, 0, 0, 0, 421, 0, 422, 0, 423, 424, + 35, 0, 0, 0, 0, 0, 0, 0, 41, 42, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 426, 427, 428, 429, 430, 431, 432, 433, 0, 434, + 435, 436, 0, 0, 0, 0, 0, 0, 0, 437, + 438, 0, 439, 440, 133, 441, 442, 443, 0, 1857, + 137, 1858, 1859, 0, 444, 445, 446, 447, 448, 0, + 0, 449, 450, 1860, 1861, 452, 0, 453, 454, 455, + 456, 0, 0, 145, 0, 457, 458, 459, 460, 148, + 461, 462, 0, 463, 464, 465, 466, 467, 468, 0, + 151, 469, 0, 0, 0, 0, 152, 0, 0, 0, + 470, 471, 472, 473, 474, 475, 1862, 1863, 476, 0, + 477, 0, 478, 479, 480, 481, 482, 0, 483, 484, + 485, 0, 0, 486, 487, 1458, 489, 490, 0, 491, + 492, 493, 0, 494, 495, 0, 496, 497, 498, 499, + 0, 500, 501, 502, 0, 0, 503, 0, 504, 1864, + 505, 0, 506, 0, 507, 169, 0, 170, 508, 509, + 510, 0, 511, 0, 0, 512, 0, 513, 514, 515, + 516, 517, 173, 518, 519, 520, 0, 521, 522, 523, + 524, 525, 526, 0, 527, 174, 0, 0, 528, 529, + 530, 1464, 1865, 0, 1866, 0, 531, 178, 179, 532, + 180, 533, 534, 535, 536, 537, 538, 539, 0, 540, + 0, 182, 541, 183, 0, 542, 543, 544, 0, 0, + 545, 546, 547, 548, 549, 550, 551, 552, 553, 554, + 555, 556, 1867, 189, 1868, 557, 558, 3695, 0, 559, + 560, 193, 561, 0, 0, 562, 1869, 563, 564, 565, + 0, 566, 0, 0, 567, 568, 569, 0, 0, 0, + 197, 198, 199, 0, 570, 571, 572, 573, 574, 575, + 576, 0, 577, 0, 578, 0, 579, 580, 581, 0, + 582, 583, 584, 585, 586, 587, 588, 1870, 589, 590, + 591, 592, 0, 593, 594, 595, 596, 597, 598, 599, + 600, 601, 602, 0, 603, 604, 210, 605, 606, 0, + 607, 608, 609, 610, 611, 612, 613, 614, 0, 615, + 616, 617, 618, 619, 0, 620, 1871, 621, 622, 219, + 623, 1872, 624, 0, 625, 626, 627, 628, 629, 630, + 631, 632, 633, 634, 0, 0, 635, 636, 0, 637, + 638, 639, 640, 641, 642, 0, 1873, 1874, 0, 0, + 644, 0, 645, 0, 0, 646, 647, 648, 649, 650, + 651, 652, 0, 0, 653, 654, 655, 656, 657, 0, + 0, 658, 659, 660, 661, 662, 0, 1875, 0, 664, + 235, 665, 666, 667, 0, 0, 668, 0, 0, 669, + 670, 671, 672, 673, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 674, 675, 676, 713, 86, 87, 88, + 412, 90, 91, 92, 413, 0, 414, 95, 0, 0, + 98, 99, 100, 101, 102, 103, 714, 104, 105, 415, + 715, 0, 107, 108, 109, 110, 716, 717, 112, 113, + 114, 115, 0, 116, 718, 719, 416, 417, 0, 0, + 0, 418, 419, 0, 0, 0, 0, 420, 0, 0, + 0, 0, 0, 0, 0, 0, 421, 0, 422, 0, + 423, 424, 35, 0, 0, 0, 0, 0, 0, 0, + 41, 42, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 426, 427, 428, 429, 430, 431, 432, 433, + 0, 434, 435, 436, 0, 0, 0, 0, 0, 0, + 0, 437, 438, 0, 439, 440, 133, 441, 442, 443, + 0, 1857, 137, 1858, 1859, 0, 444, 445, 446, 447, + 448, 0, 0, 449, 450, 1860, 1861, 452, 0, 453, + 454, 455, 456, 0, 0, 145, 0, 457, 458, 459, + 460, 148, 461, 462, 0, 463, 464, 465, 466, 467, + 468, 0, 151, 469, 0, 0, 0, 0, 152, 0, + 0, 0, 470, 471, 472, 473, 474, 475, 1862, 1863, + 476, 0, 477, 0, 478, 479, 480, 481, 482, 0, + 483, 484, 485, 0, 0, 486, 487, 1458, 489, 490, + 0, 491, 492, 493, 0, 494, 495, 0, 496, 497, + 498, 499, 0, 500, 501, 502, 0, 0, 503, 0, + 504, 1864, 505, 0, 506, 0, 507, 169, 0, 170, + 508, 509, 510, 0, 511, 0, 0, 512, 0, 513, + 514, 515, 516, 517, 173, 518, 519, 520, 0, 521, + 522, 523, 524, 525, 526, 0, 527, 174, 0, 0, + 528, 529, 530, 1464, 1865, 0, 1866, 0, 531, 178, + 179, 532, 180, 533, 534, 535, 536, 537, 538, 539, + 0, 540, 0, 182, 541, 183, 0, 542, 543, 544, + 0, 0, 545, 546, 547, 548, 549, 550, 551, 552, + 553, 554, 555, 556, 1867, 189, 1868, 557, 558, 0, + 0, 559, 560, 193, 561, 0, 0, 562, 1869, 563, + 564, 565, 0, 566, 0, 0, 567, 568, 569, 0, + 0, 0, 197, 198, 199, 0, 570, 571, 572, 573, + 574, 575, 576, 0, 577, 0, 578, 0, 579, 580, + 581, 0, 582, 583, 584, 585, 586, 587, 588, 1870, + 589, 590, 591, 592, 0, 593, 594, 595, 596, 597, + 598, 599, 600, 601, 602, 0, 603, 604, 210, 605, + 606, 0, 607, 608, 609, 610, 611, 612, 613, 614, + 0, 615, 616, 617, 618, 619, 0, 620, 1871, 621, + 622, 219, 623, 1872, 624, 0, 625, 626, 627, 628, + 629, 630, 631, 632, 633, 634, 0, 0, 635, 636, + 0, 637, 638, 639, 640, 641, 642, 0, 1873, 1874, + 0, 0, 644, 0, 645, 0, 0, 646, 647, 648, + 649, 650, 651, 652, 0, 0, 653, 654, 655, 656, + 657, 0, 0, 658, 659, 660, 661, 662, 0, 1875, + 0, 664, 235, 665, 666, 667, 0, 0, 668, 0, + 0, 669, 670, 671, 672, 673, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 674, 675, 676, 713, 86, + 87, 88, 412, 90, 91, 92, 413, 0, 414, 95, + 0, 0, 98, 99, 100, 101, 102, 103, 714, 104, + 105, 415, 715, 0, 107, 108, 109, 110, 716, 717, + 112, 113, 114, 115, 0, 116, 718, 719, 416, 417, + 0, 0, 0, 418, 419, 0, 0, 0, 0, 420, + 0, 0, 0, 0, 0, 0, 0, 0, 421, 0, + 422, 0, 423, 424, 35, 0, 0, 0, 0, 0, + 0, 0, 41, 42, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 426, 427, 428, 429, 430, 431, + 432, 433, 0, 434, 435, 436, 0, 0, 0, 0, + 0, 0, 0, 437, 438, 0, 439, 440, 133, 441, + 442, 443, 0, 1857, 137, 1858, 1859, 0, 444, 445, + 446, 447, 448, 0, 0, 449, 450, 1860, 1861, 452, + 0, 453, 454, 455, 456, 0, 0, 145, 0, 457, + 458, 459, 460, 148, 461, 462, 0, 463, 464, 465, + 466, 467, 468, 0, 151, 469, 0, 0, 0, 0, + 152, 0, 0, 0, 470, 471, 472, 473, 474, 475, + 1862, 1863, 476, 0, 477, 0, 478, 479, 480, 481, + 482, 0, 483, 484, 485, 0, 0, 486, 487, 1458, + 489, 490, 0, 491, 492, 493, 0, 494, 495, 0, + 496, 497, 498, 499, 0, 500, 501, 502, 0, 0, + 503, 0, 504, 1864, 505, 0, 506, 0, 507, 169, + 0, 170, 508, 509, 510, 0, 511, 0, 0, 512, + 0, 513, 514, 515, 516, 517, 173, 518, 519, 520, + 0, 521, 522, 523, 524, 525, 526, 0, 527, 174, + 0, 0, 528, 529, 530, 1464, 1865, 0, 1866, 0, + 531, 178, 179, 532, 180, 533, 534, 535, 536, 537, + 538, 539, 0, 540, 0, 182, 541, 183, 0, 542, + 543, 544, 0, 0, 545, 546, 547, 548, 549, 550, + 551, 552, 553, 554, 555, 556, 1867, 189, 1868, 557, + 558, 0, 0, 559, 560, 193, 561, 0, 0, 562, + 1869, 563, 564, 565, 0, 566, 0, 0, 567, 568, + 569, 0, 0, 0, 197, 198, 199, 0, 570, 571, + 572, 573, 574, 575, 576, 0, 577, 0, 578, 0, + 579, 580, 581, 0, 582, 583, 584, 585, 586, 587, + 588, 1870, 589, 590, 591, 592, 0, 593, 594, 595, + 596, 597, 598, 599, 600, 601, 602, 0, 603, 604, + 210, 605, 606, 0, 607, 608, 609, 610, 611, 612, + 613, 614, 0, 615, 616, 617, 618, 619, 0, 620, + 2421, 621, 622, 219, 623, 1872, 624, 0, 625, 626, + 627, 628, 629, 630, 631, 632, 633, 634, 0, 0, + 635, 636, 0, 637, 638, 639, 640, 641, 642, 0, + 1873, 1874, 0, 0, 644, 0, 645, 0, 0, 646, + 647, 648, 649, 650, 651, 652, 0, 0, 653, 654, + 655, 656, 657, 0, 0, 658, 659, 660, 661, 662, + 0, 1875, 0, 664, 235, 665, 666, 667, 0, 0, + 668, 0, 0, 669, 670, 671, 672, 673, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 674, 675, 676, + 713, 86, 87, 88, 412, 90, 91, 92, 413, 0, + 414, 95, 0, 0, 98, 99, 100, 101, 102, 103, + 714, 104, 105, 415, 715, 0, 107, 108, 109, 110, + 716, 717, 112, 113, 114, 115, 0, 116, 718, 719, + 416, 417, 0, 0, 0, 418, 419, 0, 0, 0, + 0, 420, 0, 0, 0, 0, 0, 0, 0, 0, + 421, 0, 422, 0, 423, 424, 35, 0, 0, 0, + 0, 0, 0, 0, 41, 42, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 426, 427, 428, 429, + 430, 431, 432, 433, 0, 434, 435, 436, 0, 0, + 0, 0, 0, 0, 0, 437, 438, 0, 439, 440, + 133, 441, 442, 443, 0, 1857, 137, 1858, 1859, 0, + 444, 445, 446, 447, 448, 0, 0, 449, 450, 1860, + 1861, 452, 0, 453, 454, 455, 456, 0, 0, 145, + 0, 457, 458, 459, 460, 148, 461, 462, 0, 463, + 464, 465, 466, 467, 468, 0, 151, 469, 0, 0, + 0, 0, 152, 0, 0, 0, 470, 471, 472, 473, + 474, 475, 1862, 1863, 476, 0, 477, 0, 478, 479, + 480, 481, 482, 0, 483, 484, 485, 0, 0, 486, + 487, 1458, 489, 490, 0, 491, 492, 493, 0, 494, + 495, 0, 496, 497, 498, 499, 0, 500, 501, 502, + 0, 0, 503, 0, 504, 1864, 505, 0, 506, 0, + 507, 169, 0, 170, 508, 509, 510, 0, 511, 0, + 0, 512, 0, 513, 514, 515, 516, 517, 173, 518, + 519, 520, 0, 521, 522, 523, 524, 525, 526, 0, + 527, 174, 0, 0, 528, 529, 530, 1464, 1865, 0, + 1866, 0, 531, 178, 179, 532, 180, 533, 534, 535, + 536, 537, 538, 539, 0, 540, 0, 182, 541, 183, + 0, 542, 543, 544, 0, 0, 545, 546, 547, 548, + 549, 550, 551, 552, 553, 554, 555, 556, 1867, 189, + 1868, 557, 558, 0, 0, 559, 560, 193, 561, 0, + 0, 562, 1869, 563, 564, 565, 0, 566, 0, 0, + 567, 568, 569, 0, 0, 0, 197, 198, 199, 0, + 570, 571, 572, 573, 574, 575, 576, 0, 577, 0, + 578, 0, 579, 580, 581, 0, 582, 583, 584, 585, + 586, 587, 588, 1870, 589, 590, 591, 592, 0, 593, + 594, 595, 596, 597, 598, 599, 600, 601, 602, 0, + 603, 604, 210, 605, 606, 0, 607, 608, 609, 610, + 611, 612, 613, 614, 0, 615, 616, 617, 618, 619, + 0, 620, 0, 621, 622, 219, 623, 1872, 624, 0, + 625, 626, 627, 628, 629, 630, 631, 632, 633, 634, + 0, 0, 635, 636, 0, 637, 638, 639, 640, 641, + 642, 0, 1873, 1874, 0, 0, 644, 0, 645, 0, + 0, 646, 647, 648, 649, 650, 651, 652, 0, 0, + 653, 654, 655, 656, 657, 0, 0, 658, 659, 660, + 661, 662, 0, 1875, 0, 664, 235, 665, 666, 667, + 0, 0, 668, 0, 0, 669, 670, 671, 672, 673, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 674, + 675, 676, 713, 86, 87, 88, 412, 90, 91, 92, + 413, 0, 414, 95, 0, 0, 98, 99, 100, 101, + 102, 103, 714, 104, 105, 415, 715, 0, 107, 108, + 109, 110, 716, 717, 112, 113, 114, 115, 0, 116, + 718, 719, 416, 417, 0, 0, 0, 418, 419, 0, + 0, 0, 0, 420, 0, 0, 0, 0, 0, 0, + 0, 0, 421, 0, 422, 0, 423, 424, 35, 0, + 0, 0, 0, 0, 0, 0, 41, 42, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 426, 427, + 428, 429, 430, 431, 432, 433, 0, 434, 435, 436, + 0, 0, 0, 0, 0, 0, 0, 437, 438, 0, + 439, 440, 133, 441, 442, 443, 0, 0, 137, 0, + 0, 0, 444, 445, 446, 447, 448, 0, 0, 449, + 450, 0, 0, 452, 0, 453, 454, 455, 456, 0, + 0, 145, 0, 457, 458, 459, 460, 148, 461, 462, + 0, 463, 464, 465, 466, 467, 468, 0, 151, 469, + 0, 0, 0, 0, 152, 0, 0, 0, 470, 471, + 472, 473, 474, 475, 0, 0, 476, 0, 477, 0, + 478, 479, 480, 481, 482, 0, 483, 484, 485, 0, + 0, 486, 487, 488, 489, 490, 0, 491, 492, 493, + 0, 494, 495, 0, 496, 497, 498, 499, 0, 500, + 501, 502, 0, 0, 503, 0, 504, 0, 505, 0, + 506, 0, 507, 169, 0, 170, 508, 509, 510, 0, + 511, 0, 0, 512, 0, 513, 514, 515, 516, 517, + 173, 518, 519, 520, 0, 521, 522, 523, 524, 525, + 526, 0, 527, 174, 0, 0, 528, 529, 530, 0, + 0, 0, 0, 0, 531, 178, 179, 532, 180, 533, + 534, 535, 536, 537, 538, 539, 0, 540, 0, 182, + 541, 183, 0, 542, 543, 544, 0, 0, 545, 546, + 547, 548, 549, 550, 551, 552, 553, 554, 555, 556, + 0, 189, 0, 557, 558, 0, 0, 559, 560, 193, + 561, 0, 0, 562, 0, 563, 564, 565, 0, 566, + 0, 0, 567, 568, 569, 0, 0, 0, 197, 198, + 199, 0, 570, 571, 572, 573, 574, 575, 576, 0, + 577, 0, 578, 0, 579, 580, 581, 0, 582, 583, + 584, 585, 586, 587, 588, 0, 589, 590, 591, 592, + 0, 593, 594, 595, 596, 597, 598, 599, 600, 601, + 602, 0, 603, 604, 210, 605, 606, 0, 607, 608, + 609, 610, 611, 612, 613, 614, 0, 615, 616, 617, + 618, 619, 0, 620, 0, 621, 622, 219, 623, 0, + 624, 0, 625, 626, 627, 628, 629, 630, 631, 632, + 633, 634, 0, 0, 635, 636, 0, 637, 638, 639, + 640, 641, 642, 0, 0, 0, 0, 0, 644, 0, + 645, 0, 0, 646, 647, 648, 649, 650, 651, 652, + 0, 0, 653, 654, 655, 656, 657, 0, 0, 658, + 659, 660, 661, 662, 0, 0, 0, 664, 235, 665, + 666, 667, 0, 0, 668, 0, 0, 669, 670, 671, + 672, 673, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 674, 675, 676, 86, 87, 88, 412, 90, 91, + 92, 413, 0, 414, 95, 0, 0, 98, 99, 100, + 101, 102, 103, 0, 104, 105, 415, 0, 0, 107, + 108, 109, 110, 0, 0, 112, 113, 114, 115, 0, + 116, 0, 0, 416, 417, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 35, + 0, 0, 0, 0, 0, 0, 0, 41, 42, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 426, + 427, 428, 429, 430, 431, 432, 433, 720, 434, 435, + 436, 721, 722, 723, 724, 725, 726, 727, 437, 438, + 728, 439, 440, 133, 441, 442, 443, 135, 136, 137, + 138, 139, 729, 444, 445, 446, 447, 448, 730, 731, + 449, 450, 0, 140, 452, 733, 453, 454, 455, 456, + 144, 734, 145, 735, 457, 458, 459, 460, 148, 461, + 736, 737, 463, 464, 465, 466, 467, 468, 738, 151, + 469, 0, 740, 741, 742, 152, 743, 744, 745, 470, + 471, 472, 473, 0, 475, 155, 156, 476, 746, 477, + 747, 478, 479, 480, 481, 482, 748, 483, 484, 485, + 749, 750, 486, 487, 488, 489, 490, 751, 491, 492, + 493, 752, 494, 495, 753, 496, 497, 498, 499, 164, + 500, 501, 502, 166, 754, 503, 755, 504, 168, 505, + 756, 506, 757, 507, 169, 758, 170, 508, 509, 510, + 759, 511, 172, 760, 512, 761, 513, 514, 0, 516, + 517, 173, 518, 519, 520, 762, 521, 522, 523, 524, + 525, 526, 763, 527, 174, 175, 0, 528, 529, 530, + 0, 176, 766, 177, 767, 531, 178, 179, 532, 180, + 533, 534, 535, 536, 537, 538, 539, 768, 540, 181, + 182, 541, 183, 769, 542, 543, 544, 770, 771, 545, + 546, 547, 548, 549, 0, 551, 552, 0, 554, 555, + 556, 188, 189, 190, 557, 558, 191, 772, 559, 560, + 193, 561, 773, 194, 562, 195, 563, 564, 565, 774, + 566, 775, 776, 567, 568, 569, 777, 778, 196, 197, + 198, 199, 200, 570, 571, 572, 573, 574, 575, 576, + 779, 577, 201, 578, 202, 579, 580, 581, 780, 582, + 583, 584, 585, 586, 587, 588, 204, 589, 590, 591, + 592, 781, 593, 594, 595, 596, 597, 598, 599, 600, + 601, 602, 782, 603, 604, 210, 605, 606, 212, 607, + 608, 609, 610, 611, 612, 0, 614, 783, 615, 616, + 617, 618, 619, 784, 620, 217, 621, 622, 219, 623, + 220, 624, 785, 625, 626, 627, 628, 629, 630, 631, + 632, 633, 634, 222, 786, 635, 636, 787, 637, 638, + 639, 640, 641, 642, 788, 224, 225, 0, 790, 644, + 226, 645, 227, 791, 646, 647, 648, 649, 650, 651, + 652, 0, 793, 653, 654, 655, 656, 657, 794, 795, + 658, 659, 660, 661, 662, 0, 234, 797, 664, 235, + 665, 666, 667, 798, 799, 668, 800, 801, 669, 670, + 671, 672, 673, 237, 238, 239, 240, 241, 242, 243, + 244, 245, 0, 675, 676, 86, 87, 88, 412, 90, + 91, 92, 413, 0, 414, 95, 0, 0, 98, 99, + 100, 101, 102, 103, 0, 104, 105, 415, 0, 0, + 107, 108, 109, 110, 0, 0, 112, 113, 114, 115, + 0, 116, 0, 0, 416, 417, 0, 0, 0, 418, + 419, 0, 0, 0, 0, 420, 0, 0, 0, 0, + 0, 0, 0, 0, 421, 0, 422, 0, 423, 424, + 35, 0, 0, 0, 37, 38, 39, 40, 41, 42, + 0, 44, 0, 0, 0, 0, 0, 0, 0, 0, + 426, 427, 428, 429, 430, 431, 432, 433, 0, 434, + 435, 436, 0, 0, 0, 0, 0, 0, 0, 437, + 438, 0, 439, 440, 0, 441, 442, 443, 135, 136, + 0, 138, 139, 0, 444, 445, 446, 447, 448, 0, + 0, 449, 450, 451, 140, 452, 0, 453, 454, 455, + 456, 144, 0, 0, 0, 457, 458, 459, 460, 0, + 461, 462, 0, 463, 464, 465, 466, 467, 468, 0, + 0, 469, 0, 0, 0, 0, 0, 0, 0, 0, + 470, 471, 472, 473, 474, 475, 155, 156, 476, 0, + 477, 0, 478, 479, 480, 481, 482, 0, 483, 484, + 485, 0, 0, 486, 487, 488, 489, 490, 0, 491, + 492, 493, 0, 494, 495, 0, 496, 497, 498, 499, + 164, 500, 501, 502, 166, 2008, 503, 0, 504, 168, + 505, 0, 506, 0, 507, 0, 0, 0, 508, 509, + 510, 0, 511, 172, 0, 512, 0, 513, 514, 515, + 516, 517, 0, 518, 519, 520, 0, 521, 522, 523, + 524, 525, 526, 0, 527, 0, 175, 0, 528, 529, + 530, 0, 176, 0, 177, 0, 531, 0, 0, 532, + 0, 533, 534, 535, 536, 537, 538, 539, 0, 540, + 181, 0, 541, 0, 0, 542, 543, 544, 0, 0, + 545, 546, 547, 548, 549, 550, 551, 552, 553, 554, + 555, 556, 188, 0, 190, 557, 558, 191, 0, 559, + 560, 0, 561, 0, 194, 562, 195, 563, 564, 565, + 0, 566, 2009, 0, 567, 568, 569, 0, 0, 196, + 0, 0, 0, 200, 570, 571, 572, 573, 574, 575, + 576, 0, 577, 201, 578, 202, 579, 580, 581, 0, + 582, 583, 584, 585, 586, 587, 588, 204, 589, 590, + 591, 592, 0, 593, 594, 595, 596, 597, 598, 599, + 600, 601, 602, 0, 603, 604, 0, 605, 606, 212, + 607, 608, 609, 610, 611, 612, 613, 614, 0, 615, + 616, 617, 618, 619, 0, 620, 217, 621, 622, 0, + 623, 220, 624, 0, 625, 626, 627, 628, 629, 630, + 631, 632, 633, 634, 222, 0, 635, 636, 0, 637, + 638, 639, 640, 641, 642, 0, 224, 225, 0, 0, + 644, 226, 645, 227, 2010, 646, 647, 648, 649, 650, + 651, 652, 0, 0, 653, 654, 655, 656, 657, 0, + 0, 658, 659, 660, 661, 662, 663, 234, 0, 664, + 0, 665, 666, 667, 0, 0, 668, 0, 0, 669, + 670, 671, 672, 673, 237, 238, 239, 240, 241, 242, + 243, 244, 245, 674, 675, 676, 86, 87, 88, 412, + 90, 91, 92, 413, 0, 414, 95, 0, 0, 98, + 99, 100, 101, 102, 103, 0, 104, 105, 415, 0, + 0, 107, 108, 109, 110, 0, 0, 112, 113, 114, + 115, 0, 116, 0, 0, 416, 417, 0, 0, 0, + 418, 419, 0, 0, 0, 0, 420, 0, 0, 0, + 0, 0, 0, 0, 0, 421, 0, 422, 0, 423, + 424, 35, 425, 0, 0, 37, 38, 39, 40, 41, + 42, 0, 44, 0, 0, 0, 0, 0, 0, 0, + 0, 426, 427, 428, 429, 430, 431, 432, 433, 0, + 434, 435, 436, 0, 0, 0, 0, 0, 0, 0, + 437, 438, 0, 439, 440, 0, 441, 442, 443, 135, + 136, 0, 138, 139, 0, 444, 445, 446, 447, 448, + 0, 0, 449, 450, 451, 140, 452, 0, 453, 454, + 455, 456, 144, 0, 0, 0, 457, 458, 459, 460, + 0, 461, 462, 0, 463, 464, 465, 466, 467, 468, + 0, 0, 469, 0, 0, 0, 0, 0, 0, 0, + 0, 470, 471, 472, 473, 474, 475, 155, 156, 476, + 0, 477, 0, 478, 479, 480, 481, 482, 0, 483, + 484, 485, 0, 0, 486, 487, 488, 489, 490, 0, + 491, 492, 493, 0, 494, 495, 0, 496, 497, 498, + 499, 164, 500, 501, 502, 166, 0, 503, 0, 504, + 168, 505, 0, 506, 0, 507, 0, 0, 0, 508, + 509, 510, 0, 511, 172, 0, 512, 0, 513, 514, + 515, 516, 517, 0, 518, 519, 520, 0, 521, 522, + 523, 524, 525, 526, 0, 527, 0, 175, 0, 528, + 529, 530, 0, 176, 0, 177, 0, 531, 0, 0, + 532, 0, 533, 534, 535, 536, 537, 538, 539, 0, + 540, 181, 0, 541, 0, 0, 542, 543, 544, 0, + 0, 545, 546, 547, 548, 549, 550, 551, 552, 553, + 554, 555, 556, 188, 0, 190, 557, 558, 191, 0, + 559, 560, 0, 561, 0, 194, 562, 195, 563, 564, + 565, 0, 566, 0, 0, 567, 568, 569, 0, 0, + 196, 0, 0, 0, 200, 570, 571, 572, 573, 574, + 575, 576, 0, 577, 201, 578, 202, 579, 580, 581, + 0, 582, 583, 584, 585, 586, 587, 588, 204, 589, + 590, 591, 592, 0, 593, 594, 595, 596, 597, 598, + 599, 600, 601, 602, 0, 603, 604, 0, 605, 606, + 212, 607, 608, 609, 610, 611, 612, 613, 614, 0, + 615, 616, 617, 618, 619, 0, 620, 217, 621, 622, + 0, 623, 220, 624, 0, 625, 626, 627, 628, 629, + 630, 631, 632, 633, 634, 222, 0, 635, 636, 0, + 637, 638, 639, 640, 641, 642, 0, 224, 225, 643, + 0, 644, 226, 645, 227, 0, 646, 647, 648, 649, + 650, 651, 652, 0, 0, 653, 654, 655, 656, 657, + 0, 0, 658, 659, 660, 661, 662, 663, 234, 0, + 664, 0, 665, 666, 667, 0, 0, 668, 0, 0, + 669, 670, 671, 672, 673, 237, 238, 239, 240, 241, + 242, 243, 244, 245, 674, 675, 676, 86, 87, 88, + 412, 90, 91, 92, 413, 0, 414, 95, 0, 0, + 98, 99, 100, 101, 102, 103, 0, 104, 105, 415, + 0, 0, 107, 108, 109, 110, 0, 0, 112, 113, + 114, 115, 0, 116, 0, 0, 416, 417, 0, 0, + 0, 418, 419, 0, 0, 0, 0, 420, 0, 0, + 0, 0, 0, 0, 0, 0, 421, 0, 422, 0, + 423, 424, 35, 425, 0, 0, 37, 38, 39, 40, + 41, 42, 0, 44, 0, 0, 0, 0, 0, 0, + 0, 0, 426, 427, 428, 429, 430, 431, 432, 433, + 0, 434, 435, 436, 0, 0, 0, 0, 0, 0, + 0, 437, 438, 0, 439, 440, 0, 441, 442, 443, + 135, 136, 0, 138, 139, 0, 444, 445, 446, 447, + 448, 0, 0, 449, 450, 451, 140, 452, 0, 453, + 454, 455, 456, 144, 0, 0, 0, 457, 458, 459, + 460, 0, 461, 462, 0, 463, 464, 465, 466, 467, + 468, 0, 0, 469, 0, 0, 0, 0, 0, 0, + 0, 0, 470, 471, 472, 473, 474, 475, 155, 156, + 476, 1128, 477, 0, 478, 479, 480, 481, 482, 0, + 483, 484, 485, 0, 0, 486, 487, 488, 489, 490, + 0, 491, 492, 493, 0, 494, 495, 0, 496, 497, + 498, 499, 164, 500, 501, 502, 166, 0, 503, 0, + 504, 168, 505, 0, 506, 0, 507, 0, 0, 0, + 508, 509, 510, 0, 511, 172, 0, 512, 0, 513, + 514, 515, 516, 517, 0, 518, 519, 520, 0, 521, + 522, 523, 524, 525, 526, 0, 527, 0, 175, 0, + 528, 529, 530, 0, 176, 0, 177, 0, 531, 0, + 0, 532, 0, 533, 534, 535, 536, 537, 538, 539, + 0, 540, 181, 0, 541, 0, 0, 542, 543, 544, + 0, 0, 545, 546, 547, 548, 549, 550, 551, 552, + 553, 554, 555, 556, 188, 0, 190, 557, 558, 191, + 0, 559, 560, 0, 561, 0, 194, 562, 195, 563, + 564, 565, 0, 566, 0, 0, 567, 568, 569, 0, + 0, 196, 0, 0, 0, 200, 570, 571, 572, 573, + 574, 575, 576, 0, 577, 201, 578, 202, 579, 580, + 581, 0, 582, 583, 584, 585, 586, 587, 588, 204, + 589, 590, 591, 592, 0, 593, 594, 595, 596, 597, + 598, 599, 600, 601, 602, 0, 603, 604, 0, 605, + 606, 212, 607, 608, 609, 610, 611, 612, 613, 614, + 0, 615, 616, 617, 618, 619, 0, 620, 217, 621, + 622, 0, 623, 220, 624, 0, 625, 626, 627, 628, + 629, 630, 631, 632, 633, 634, 222, 0, 635, 636, + 0, 637, 638, 639, 640, 641, 642, 0, 224, 225, + 0, 0, 644, 226, 645, 227, 0, 646, 647, 648, + 649, 650, 651, 652, 0, 0, 653, 654, 655, 656, + 657, 0, 0, 658, 659, 660, 661, 662, 663, 234, + 0, 664, 0, 665, 666, 667, 0, 0, 668, 0, + 0, 669, 670, 671, 672, 673, 237, 238, 239, 240, + 241, 242, 243, 244, 245, 674, 675, 676, 86, 87, + 88, 412, 90, 91, 92, 413, 0, 414, 95, 0, + 0, 98, 99, 100, 101, 102, 103, 0, 104, 105, + 415, 0, 0, 107, 108, 109, 110, 0, 0, 112, + 113, 114, 115, 0, 116, 0, 0, 416, 417, 0, + 0, 0, 418, 419, 0, 0, 0, 0, 420, 0, + 0, 0, 0, 0, 0, 0, 0, 421, 0, 422, + 0, 423, 424, 35, 425, 0, 0, 37, 38, 39, + 40, 41, 42, 0, 44, 0, 0, 0, 0, 0, + 0, 0, 0, 426, 427, 428, 429, 430, 431, 432, + 433, 0, 434, 435, 436, 0, 0, 0, 0, 0, + 0, 0, 437, 438, 0, 439, 440, 0, 441, 442, + 443, 135, 136, 0, 138, 139, 0, 444, 445, 446, + 447, 448, 0, 0, 449, 450, 451, 140, 452, 0, + 453, 454, 455, 456, 144, 0, 0, 0, 457, 458, + 459, 460, 0, 461, 462, 0, 463, 464, 465, 466, + 467, 468, 0, 0, 469, 0, 0, 0, 0, 0, + 0, 0, 0, 470, 471, 472, 473, 474, 475, 155, + 156, 476, 0, 477, 0, 478, 479, 480, 481, 482, + 0, 483, 484, 485, 0, 0, 486, 487, 488, 489, + 490, 0, 491, 492, 493, 0, 494, 495, 0, 496, + 497, 498, 499, 164, 500, 501, 502, 166, 0, 503, + 0, 504, 168, 505, 0, 506, 0, 507, 0, 0, + 0, 508, 509, 510, 0, 511, 172, 0, 512, 0, + 513, 514, 515, 516, 517, 0, 518, 519, 520, 0, + 521, 522, 523, 524, 525, 526, 0, 527, 0, 175, + 0, 528, 529, 530, 0, 176, 0, 177, 0, 531, + 0, 0, 532, 0, 533, 534, 535, 536, 537, 538, + 539, 0, 540, 181, 0, 541, 0, 0, 542, 543, + 544, 0, 0, 545, 546, 547, 548, 549, 550, 551, + 552, 553, 554, 555, 556, 188, 0, 190, 557, 558, + 191, 0, 559, 560, 0, 561, 0, 194, 562, 195, + 563, 564, 565, 0, 566, 0, 0, 567, 568, 569, + 0, 0, 196, 0, 0, 0, 200, 570, 571, 572, + 573, 574, 575, 576, 0, 577, 201, 578, 202, 579, + 580, 581, 0, 582, 583, 584, 585, 586, 587, 588, + 204, 589, 590, 591, 592, 0, 593, 594, 595, 596, + 597, 598, 599, 600, 601, 602, 0, 603, 604, 0, + 605, 606, 212, 607, 608, 609, 610, 611, 612, 613, + 614, 0, 615, 616, 617, 618, 619, 0, 620, 217, + 621, 622, 0, 623, 220, 624, 0, 625, 626, 627, + 628, 629, 630, 631, 632, 633, 634, 222, 0, 635, + 636, 0, 637, 638, 639, 640, 641, 642, 0, 224, + 225, 0, 0, 644, 226, 645, 227, 0, 646, 647, + 648, 649, 650, 651, 652, 0, 0, 653, 654, 655, + 656, 657, 0, 0, 658, 659, 660, 661, 662, 663, + 234, 0, 664, 0, 665, 666, 667, 0, 0, 668, + 0, 0, 669, 670, 671, 672, 673, 237, 238, 239, + 240, 241, 242, 243, 244, 245, 674, 675, 676, 86, + 87, 88, 412, 90, 91, 92, 413, 0, 414, 95, + 0, 0, 98, 99, 100, 101, 102, 103, 0, 104, + 105, 415, 0, 0, 107, 108, 109, 110, 0, 0, + 112, 113, 114, 115, 0, 116, 0, 0, 416, 417, + 0, 0, 0, 418, 419, 0, 0, 0, 0, 420, + 0, 0, 0, 0, 0, 0, 0, 0, 421, 0, + 422, 0, 423, 424, 35, 0, 0, 0, 37, 38, + 39, 40, 41, 42, 0, 44, 0, 0, 0, 0, + 0, 0, 0, 0, 426, 427, 428, 429, 430, 431, + 432, 433, 0, 434, 435, 436, 0, 0, 0, 0, + 0, 0, 0, 437, 438, 0, 439, 440, 0, 441, + 442, 443, 135, 136, 0, 138, 139, 0, 444, 445, + 446, 447, 448, 0, 0, 449, 450, 451, 140, 452, + 0, 453, 454, 455, 456, 144, 0, 0, 0, 457, + 458, 459, 460, 0, 461, 462, 0, 463, 464, 465, + 466, 467, 468, 0, 0, 469, 0, 0, 0, 0, + 0, 0, 0, 0, 470, 471, 472, 473, 474, 475, + 155, 156, 476, 2209, 477, 0, 478, 479, 480, 481, + 482, 0, 483, 484, 485, 0, 0, 486, 487, 488, + 489, 490, 0, 491, 492, 493, 0, 494, 495, 0, + 496, 497, 498, 499, 164, 500, 501, 502, 166, 0, + 503, 0, 504, 168, 505, 0, 506, 0, 507, 0, + 0, 0, 508, 509, 510, 0, 511, 172, 0, 512, + 0, 513, 514, 515, 516, 517, 0, 518, 519, 520, + 0, 521, 522, 523, 524, 525, 526, 0, 527, 0, + 175, 0, 528, 529, 530, 0, 176, 0, 177, 0, + 531, 0, 0, 532, 0, 533, 534, 535, 536, 537, + 538, 539, 0, 540, 181, 0, 541, 0, 0, 542, + 543, 544, 0, 0, 545, 546, 547, 548, 549, 550, + 551, 552, 553, 554, 555, 556, 188, 0, 190, 557, + 558, 191, 0, 559, 560, 0, 561, 0, 194, 562, + 195, 563, 564, 565, 0, 566, 0, 0, 567, 568, + 569, 0, 0, 196, 0, 0, 0, 200, 570, 571, + 572, 573, 574, 575, 576, 0, 577, 201, 578, 202, + 579, 580, 581, 0, 582, 583, 584, 585, 586, 587, + 588, 204, 589, 590, 591, 592, 0, 593, 594, 595, + 596, 597, 598, 599, 600, 601, 602, 0, 603, 604, + 0, 605, 606, 212, 607, 608, 609, 610, 611, 612, + 613, 614, 0, 615, 616, 617, 618, 619, 0, 620, + 217, 621, 622, 0, 623, 220, 624, 0, 625, 626, + 627, 628, 629, 630, 631, 632, 633, 634, 222, 0, + 635, 636, 0, 637, 638, 639, 640, 641, 642, 0, + 224, 225, 0, 0, 644, 226, 645, 227, 0, 646, + 647, 648, 649, 650, 651, 652, 0, 0, 653, 654, + 655, 656, 657, 0, 0, 658, 659, 660, 661, 662, + 663, 234, 0, 664, 0, 665, 666, 667, 0, 0, + 668, 0, 0, 669, 670, 671, 672, 673, 237, 238, + 239, 240, 241, 242, 243, 244, 245, 674, 675, 676, + 86, 87, 88, 412, 90, 91, 92, 413, 0, 414, + 95, 0, 0, 98, 99, 100, 101, 102, 103, 0, + 104, 105, 415, 0, 0, 107, 108, 109, 110, 0, + 0, 112, 113, 114, 115, 0, 116, 0, 0, 416, + 417, 0, 0, 0, 418, 419, 0, 0, 0, 0, + 420, 0, 0, 0, 0, 0, 0, 0, 0, 421, + 0, 422, 0, 423, 424, 35, 0, 0, 0, 0, + 0, 0, 0, 41, 42, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 426, 427, 428, 429, 430, + 431, 432, 433, 0, 434, 435, 436, 0, 0, 0, + 0, 0, 0, 0, 437, 438, 0, 439, 440, 0, + 441, 442, 443, 135, 136, 0, 138, 139, 0, 444, + 445, 446, 447, 448, 0, 0, 449, 450, 451, 140, + 452, 2359, 453, 454, 455, 456, 144, 0, 0, 2434, + 457, 458, 459, 460, 0, 461, 462, 2360, 463, 464, + 465, 466, 467, 468, 0, 0, 469, 0, 0, 0, + 0, 0, 0, 0, 0, 470, 471, 472, 473, 474, + 475, 155, 156, 476, 0, 477, 0, 478, 479, 480, + 481, 482, 0, 483, 484, 485, 0, 0, 486, 487, + 488, 489, 490, 0, 491, 492, 493, 0, 494, 495, + 0, 2435, 497, 498, 499, 164, 500, 501, 502, 166, + 0, 503, 0, 504, 168, 505, 0, 506, 2362, 507, + 0, 0, 0, 508, 509, 510, 0, 511, 172, 0, + 512, 0, 513, 514, 515, 516, 517, 0, 518, 519, + 520, 0, 521, 522, 523, 524, 525, 526, 0, 527, + 0, 175, 0, 528, 529, 530, 0, 176, 0, 177, + 0, 531, 0, 0, 532, 0, 533, 534, 535, 536, + 537, 538, 539, 0, 540, 181, 0, 541, 0, 0, + 542, 543, 544, 0, 0, 545, 546, 547, 548, 549, + 550, 551, 552, 553, 554, 555, 556, 188, 0, 190, + 557, 558, 191, 0, 559, 560, 0, 561, 0, 194, + 562, 195, 563, 564, 565, 0, 566, 0, 0, 567, + 568, 569, 0, 0, 196, 0, 0, 0, 200, 570, + 571, 572, 573, 574, 575, 576, 0, 577, 201, 578, + 202, 579, 580, 581, 2363, 582, 583, 584, 585, 586, + 587, 588, 204, 589, 590, 591, 592, 0, 593, 594, + 595, 596, 597, 598, 599, 600, 601, 602, 0, 603, + 604, 0, 605, 606, 212, 607, 608, 609, 610, 611, + 612, 613, 614, 0, 615, 616, 617, 618, 619, 0, + 620, 217, 621, 622, 0, 623, 220, 624, 0, 625, + 626, 627, 628, 629, 630, 631, 632, 633, 634, 222, + 0, 635, 636, 0, 637, 638, 639, 640, 641, 642, + 0, 224, 225, 0, 0, 644, 226, 645, 227, 0, + 646, 647, 648, 649, 650, 651, 652, 0, 2364, 653, + 654, 655, 656, 657, 0, 0, 658, 659, 660, 661, + 662, 663, 234, 0, 664, 0, 665, 666, 667, 0, + 0, 668, 0, 0, 669, 670, 671, 672, 673, 237, + 238, 239, 240, 241, 242, 243, 244, 245, 674, 675, + 676, 86, 87, 88, 412, 90, 91, 92, 413, 0, + 414, 95, 0, 0, 98, 99, 100, 101, 102, 103, + 0, 104, 105, 415, 0, 0, 107, 108, 109, 110, + 0, 0, 112, 113, 114, 115, 0, 116, 0, 0, + 416, 417, 0, 0, 0, 418, 419, 0, 0, 0, + 0, 420, 0, 0, 0, 0, 0, 0, 0, 0, + 421, 0, 422, 0, 423, 424, 35, 0, 0, 0, + 0, 0, 0, 0, 41, 42, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 426, 427, 428, 429, + 430, 431, 432, 433, 0, 434, 435, 436, 0, 0, + 0, 0, 0, 0, 0, 437, 438, 0, 439, 440, + 0, 441, 442, 443, 135, 136, 0, 138, 139, 0, + 444, 445, 446, 447, 448, 0, 0, 449, 450, 451, + 140, 452, 2359, 453, 454, 455, 456, 144, 0, 0, + 0, 457, 458, 459, 460, 0, 461, 462, 2360, 463, + 464, 465, 466, 467, 468, 0, 0, 469, 0, 0, + 0, 0, 0, 0, 0, 0, 470, 471, 472, 473, + 474, 475, 155, 156, 476, 0, 477, 0, 478, 479, + 480, 481, 482, 0, 483, 484, 485, 0, 0, 486, + 487, 488, 489, 490, 0, 491, 492, 493, 0, 494, + 495, 0, 2435, 497, 498, 499, 164, 500, 501, 502, + 166, 0, 503, 0, 504, 168, 505, 0, 506, 2362, + 507, 0, 0, 0, 508, 509, 510, 0, 511, 172, + 0, 512, 0, 513, 514, 515, 516, 517, 0, 518, + 519, 520, 0, 521, 522, 523, 524, 525, 526, 0, + 527, 0, 175, 0, 528, 529, 530, 0, 176, 0, + 177, 0, 531, 0, 0, 532, 0, 533, 534, 535, + 536, 537, 538, 539, 0, 540, 181, 0, 541, 3308, + 0, 542, 543, 544, 0, 0, 545, 546, 547, 548, + 549, 550, 551, 552, 553, 554, 555, 556, 188, 0, + 190, 557, 558, 191, 0, 559, 560, 0, 561, 0, + 194, 562, 195, 563, 564, 565, 0, 566, 0, 0, + 567, 568, 569, 0, 0, 196, 0, 0, 0, 200, + 570, 571, 572, 573, 574, 575, 576, 0, 577, 201, + 578, 202, 579, 580, 581, 2363, 582, 583, 584, 585, + 586, 587, 588, 204, 589, 590, 591, 592, 0, 593, + 594, 595, 596, 597, 598, 599, 600, 601, 602, 0, + 603, 604, 0, 605, 606, 212, 607, 608, 609, 610, + 611, 612, 613, 614, 0, 615, 616, 617, 618, 619, + 0, 620, 217, 621, 622, 0, 623, 220, 624, 0, + 625, 626, 627, 628, 629, 630, 631, 632, 633, 634, + 222, 0, 635, 636, 0, 637, 638, 639, 640, 641, + 642, 0, 224, 225, 0, 0, 644, 226, 645, 227, + 0, 646, 647, 648, 649, 650, 651, 652, 0, 2364, + 653, 654, 655, 656, 657, 0, 0, 658, 659, 660, + 661, 662, 663, 234, 0, 664, 0, 665, 666, 667, + 0, 0, 668, 0, 0, 669, 670, 671, 672, 673, + 237, 238, 239, 240, 241, 242, 243, 244, 245, 674, + 675, 676, 86, 87, 88, 412, 90, 91, 92, 413, + 0, 414, 95, 0, 0, 98, 99, 100, 101, 102, + 103, 0, 104, 105, 415, 0, 0, 107, 108, 109, + 110, 0, 0, 112, 113, 114, 115, 0, 116, 0, + 0, 416, 417, 0, 0, 0, 418, 419, 0, 0, + 0, 0, 420, 0, 0, 0, 0, 0, 0, 0, + 0, 421, 0, 422, 0, 423, 424, 35, 0, 0, + 0, 0, 0, 0, 0, 41, 42, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 426, 427, 428, + 429, 430, 1026, 432, 433, 985, 434, 435, 436, 0, + 0, 0, 0, 0, 0, 0, 437, 438, 0, 439, + 440, 0, 441, 442, 443, 135, 136, 0, 138, 139, + 0, 444, 445, 446, 447, 448, 0, 0, 449, 450, + 451, 140, 452, 0, 453, 454, 455, 456, 144, 0, + 0, 0, 457, 458, 459, 460, 0, 461, 462, 0, + 463, 464, 465, 466, 467, 468, 986, 0, 469, 0, + 0, 0, 0, 0, 0, 0, 0, 470, 471, 472, + 473, 474, 475, 155, 156, 476, 0, 477, 0, 478, + 479, 480, 481, 482, 0, 483, 484, 485, 0, 0, + 486, 487, 488, 489, 490, 0, 491, 492, 493, 0, + 494, 495, 0, 496, 497, 498, 499, 164, 500, 501, + 502, 166, 0, 503, 0, 504, 168, 505, 0, 506, + 0, 507, 0, 0, 0, 508, 509, 510, 1027, 511, + 172, 0, 512, 0, 513, 514, 515, 516, 517, 0, + 518, 519, 520, 0, 521, 522, 523, 524, 525, 526, + 0, 527, 0, 175, 0, 528, 529, 530, 0, 176, + 0, 177, 0, 531, 0, 0, 532, 0, 533, 534, + 535, 536, 537, 538, 539, 0, 540, 181, 0, 541, + 0, 0, 542, 543, 544, 0, 0, 545, 546, 547, + 548, 549, 550, 551, 552, 553, 554, 555, 556, 188, + 0, 190, 557, 558, 191, 0, 559, 560, 0, 561, + 0, 194, 562, 195, 563, 564, 565, 0, 566, 0, + 0, 567, 568, 569, 0, 0, 196, 0, 0, 0, + 200, 570, 571, 572, 573, 574, 575, 576, 0, 577, + 201, 578, 202, 579, 580, 581, 0, 582, 583, 584, + 585, 586, 587, 588, 204, 589, 590, 591, 592, 987, + 593, 594, 595, 596, 597, 598, 599, 600, 601, 602, + 0, 603, 604, 0, 605, 606, 212, 607, 608, 609, + 610, 611, 612, 613, 614, 988, 615, 616, 617, 618, + 619, 0, 620, 217, 621, 622, 0, 623, 220, 624, + 0, 625, 626, 627, 628, 629, 630, 631, 632, 633, + 634, 222, 0, 635, 636, 0, 637, 638, 639, 640, + 641, 642, 0, 224, 225, 0, 0, 644, 226, 645, + 227, 0, 646, 647, 648, 649, 650, 651, 652, 0, + 0, 653, 654, 655, 656, 657, 0, 0, 658, 659, + 660, 661, 662, 663, 234, 0, 664, 0, 665, 666, + 667, 0, 0, 668, 0, 0, 669, 670, 671, 672, + 673, 237, 238, 239, 240, 241, 242, 243, 244, 245, + 674, 675, 676, 86, 87, 88, 412, 90, 91, 92, + 413, 0, 414, 95, 0, 0, 98, 99, 100, 101, + 102, 103, 0, 104, 105, 415, 0, 0, 107, 108, + 109, 110, 0, 0, 112, 113, 114, 115, 0, 116, + 0, 0, 416, 417, 0, 0, 0, 418, 419, 0, + 0, 0, 0, 420, 0, 0, 0, 0, 0, 0, + 0, 0, 421, 0, 422, 0, 423, 424, 35, 0, + 0, 0, 37, 38, 39, 40, 41, 42, 0, 44, + 0, 0, 0, 0, 0, 0, 0, 0, 426, 427, + 428, 429, 430, 431, 432, 433, 0, 434, 435, 436, + 0, 0, 0, 0, 0, 0, 0, 437, 438, 0, + 439, 440, 0, 441, 442, 443, 135, 136, 0, 138, + 139, 0, 444, 445, 446, 447, 448, 0, 0, 449, + 450, 451, 140, 452, 0, 453, 454, 455, 456, 144, + 0, 0, 0, 457, 458, 459, 460, 0, 461, 462, + 0, 463, 464, 465, 466, 467, 468, 0, 0, 469, + 0, 0, 0, 0, 0, 0, 0, 0, 470, 471, + 472, 473, 474, 475, 155, 156, 476, 0, 477, 0, + 478, 479, 480, 481, 482, 0, 483, 484, 485, 0, + 0, 486, 487, 488, 489, 490, 0, 491, 492, 493, + 0, 494, 495, 0, 496, 497, 498, 499, 164, 500, + 501, 502, 166, 0, 503, 0, 504, 168, 505, 0, + 506, 0, 507, 0, 0, 0, 508, 509, 510, 0, + 511, 172, 0, 512, 0, 513, 514, 515, 516, 517, + 0, 518, 519, 520, 0, 521, 522, 523, 524, 525, + 526, 0, 527, 0, 175, 0, 528, 529, 530, 0, + 176, 0, 177, 0, 531, 0, 0, 532, 0, 533, + 534, 535, 536, 537, 538, 539, 0, 540, 181, 0, + 541, 0, 0, 542, 543, 544, 0, 0, 545, 546, + 547, 548, 549, 550, 551, 552, 553, 554, 555, 556, + 188, 0, 190, 557, 558, 191, 0, 559, 560, 0, + 561, 0, 194, 562, 195, 563, 564, 565, 0, 566, + 0, 0, 567, 568, 569, 0, 0, 196, 0, 0, + 0, 200, 570, 571, 572, 573, 574, 575, 576, 0, + 577, 201, 578, 202, 579, 580, 581, 0, 582, 583, + 584, 585, 586, 587, 588, 204, 589, 590, 591, 592, + 0, 593, 594, 595, 596, 597, 598, 599, 600, 601, + 602, 0, 603, 604, 0, 605, 606, 212, 607, 608, + 609, 610, 611, 612, 613, 614, 0, 615, 616, 617, + 618, 619, 0, 620, 217, 621, 622, 0, 623, 220, + 624, 0, 625, 626, 627, 628, 629, 630, 631, 632, + 633, 634, 222, 0, 635, 636, 0, 637, 638, 639, + 640, 641, 642, 0, 224, 225, 0, 0, 644, 226, + 645, 227, 0, 646, 647, 648, 649, 650, 651, 652, + 0, 0, 653, 654, 655, 656, 657, 0, 0, 658, + 659, 660, 661, 662, 663, 234, 0, 664, 0, 665, + 666, 667, 0, 0, 668, 0, 0, 669, 670, 671, + 672, 673, 237, 238, 239, 240, 241, 242, 243, 244, + 245, 674, 675, 676, 86, 87, 88, 412, 90, 91, + 92, 413, 0, 414, 95, 0, 0, 98, 99, 100, + 101, 102, 103, 0, 104, 105, 415, 0, 0, 107, + 108, 109, 110, 0, 0, 112, 113, 114, 115, 0, + 116, 0, 0, 416, 417, 0, 0, 0, 418, 419, + 0, 0, 0, 0, 420, 0, 0, 0, 0, 0, + 0, 0, 0, 421, 0, 422, 0, 423, 424, 35, + 0, 0, 0, 37, 38, 39, 40, 41, 42, 0, + 44, 0, 0, 0, 0, 0, 0, 0, 0, 426, + 427, 428, 429, 430, 431, 432, 433, 0, 434, 435, + 436, 0, 0, 0, 0, 0, 0, 0, 437, 438, + 0, 439, 440, 0, 441, 442, 443, 135, 136, 0, + 138, 139, 0, 444, 445, 446, 447, 448, 0, 0, + 449, 450, 451, 140, 452, 0, 453, 454, 455, 456, + 144, 0, 0, 0, 457, 458, 459, 460, 0, 461, + 462, 0, 463, 464, 465, 466, 467, 468, 0, 0, + 469, 0, 0, 0, 0, 0, 0, 0, 0, 470, + 471, 472, 473, 474, 475, 155, 156, 476, 0, 477, + 0, 478, 479, 480, 481, 482, 0, 483, 484, 485, + 0, 0, 486, 487, 488, 489, 490, 0, 491, 492, + 493, 0, 494, 495, 0, 496, 497, 498, 499, 164, + 500, 501, 502, 166, 0, 503, 0, 504, 168, 505, + 0, 506, 0, 507, 0, 0, 0, 508, 509, 510, + 0, 511, 172, 0, 512, 0, 513, 514, 515, 516, + 1988, 0, 518, 519, 520, 0, 521, 522, 523, 524, + 525, 526, 0, 527, 0, 175, 0, 528, 529, 530, + 0, 176, 0, 177, 0, 531, 0, 0, 532, 0, + 533, 534, 535, 536, 537, 538, 539, 0, 540, 181, + 0, 541, 0, 0, 542, 543, 544, 0, 0, 545, + 546, 547, 548, 549, 550, 551, 552, 553, 554, 555, + 556, 188, 0, 190, 557, 558, 191, 0, 559, 560, + 0, 561, 0, 194, 562, 195, 563, 564, 565, 0, + 566, 0, 0, 567, 568, 569, 0, 0, 196, 0, + 0, 0, 200, 570, 571, 572, 573, 574, 575, 576, + 0, 577, 201, 578, 202, 579, 580, 581, 0, 582, + 583, 584, 585, 586, 587, 588, 204, 589, 590, 591, + 592, 0, 593, 594, 595, 596, 597, 598, 599, 600, + 601, 602, 0, 603, 604, 0, 605, 606, 212, 607, + 608, 609, 610, 611, 612, 613, 614, 0, 615, 616, + 617, 618, 619, 0, 620, 217, 621, 622, 0, 623, + 220, 624, 0, 625, 626, 627, 628, 629, 630, 631, + 632, 633, 634, 222, 0, 635, 636, 0, 637, 638, + 639, 640, 641, 642, 0, 224, 225, 0, 0, 644, + 226, 645, 227, 0, 646, 647, 648, 649, 650, 651, + 652, 0, 0, 653, 654, 655, 656, 657, 0, 0, + 658, 659, 660, 661, 662, 663, 234, 0, 664, 0, + 665, 666, 667, 0, 0, 668, 0, 0, 669, 670, + 671, 672, 673, 237, 238, 239, 240, 241, 242, 243, + 244, 245, 674, 675, 676, 86, 87, 88, 412, 90, + 91, 92, 413, 0, 414, 95, 0, 0, 98, 99, + 100, 101, 102, 103, 0, 104, 105, 415, 0, 0, + 107, 108, 109, 110, 0, 0, 112, 113, 114, 115, + 0, 116, 0, 0, 416, 417, 0, 0, 0, 418, + 419, 0, 0, 0, 0, 420, 0, 0, 0, 0, + 0, 0, 0, 0, 421, 0, 422, 0, 423, 424, + 35, 0, 0, 0, 0, 0, 0, 0, 41, 42, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 426, 427, 428, 429, 430, 431, 432, 433, 985, 434, + 435, 436, 0, 0, 0, 0, 0, 0, 0, 437, + 438, 0, 439, 440, 0, 441, 442, 443, 135, 136, + 0, 138, 139, 0, 444, 445, 446, 447, 448, 0, + 0, 449, 450, 451, 140, 452, 0, 453, 454, 455, + 456, 144, 0, 0, 0, 457, 458, 459, 460, 0, + 461, 462, 0, 463, 464, 465, 466, 467, 468, 986, + 0, 469, 0, 0, 0, 0, 0, 0, 0, 0, + 470, 471, 472, 473, 474, 475, 155, 156, 476, 0, + 477, 0, 478, 479, 480, 481, 482, 0, 483, 484, + 485, 0, 0, 486, 487, 488, 489, 490, 0, 491, + 492, 493, 0, 494, 495, 0, 496, 497, 498, 499, + 164, 500, 501, 502, 166, 0, 503, 0, 504, 168, + 505, 0, 506, 0, 507, 0, 0, 0, 508, 509, + 510, 3013, 511, 172, 0, 512, 0, 513, 514, 515, + 516, 517, 0, 518, 519, 520, 0, 521, 522, 523, + 524, 525, 526, 0, 527, 0, 175, 0, 528, 529, + 530, 0, 176, 0, 177, 0, 531, 0, 0, 532, + 0, 533, 534, 535, 536, 537, 538, 539, 0, 540, + 181, 0, 541, 0, 0, 542, 543, 544, 0, 0, + 545, 546, 547, 548, 549, 550, 551, 552, 553, 554, + 555, 556, 188, 0, 190, 557, 558, 191, 0, 559, + 560, 0, 561, 0, 194, 562, 195, 563, 564, 565, + 0, 566, 0, 0, 567, 568, 569, 0, 0, 196, + 0, 0, 0, 200, 570, 571, 572, 573, 574, 575, + 576, 0, 577, 201, 578, 202, 579, 580, 581, 0, + 582, 583, 584, 585, 586, 587, 588, 204, 589, 590, + 591, 592, 987, 593, 594, 595, 596, 597, 598, 599, + 600, 601, 602, 0, 603, 604, 0, 605, 606, 212, + 607, 608, 609, 610, 611, 612, 613, 614, 988, 615, + 616, 617, 618, 619, 0, 620, 217, 621, 622, 0, + 623, 220, 624, 0, 625, 626, 627, 628, 629, 630, + 631, 632, 633, 634, 222, 0, 635, 636, 0, 637, + 638, 639, 640, 641, 642, 0, 224, 225, 0, 0, + 644, 226, 645, 227, 0, 646, 647, 648, 649, 650, + 651, 652, 0, 0, 653, 654, 655, 656, 657, 0, + 0, 658, 659, 660, 661, 662, 663, 234, 0, 664, + 0, 665, 666, 667, 0, 0, 668, 0, 0, 669, + 670, 671, 672, 673, 237, 238, 239, 240, 241, 242, + 243, 244, 245, 674, 675, 676, 86, 87, 88, 412, + 90, 91, 92, 413, 0, 414, 95, 0, 0, 98, + 99, 100, 101, 102, 103, 0, 104, 105, 415, 0, + 0, 107, 108, 109, 110, 0, 0, 112, 113, 114, + 115, 0, 116, 0, 0, 416, 417, 0, 0, 0, + 418, 419, 0, 0, 0, 0, 420, 0, 0, 0, + 0, 0, 0, 0, 0, 421, 0, 422, 0, 423, + 424, 35, 0, 0, 0, 0, 0, 0, 0, 41, + 42, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 426, 427, 428, 429, 430, 431, 432, 433, 0, + 434, 435, 436, 0, 0, 0, 0, 0, 0, 0, + 437, 438, 0, 439, 440, 0, 441, 442, 443, 135, + 136, 0, 138, 139, 0, 444, 445, 446, 447, 448, + 0, 0, 449, 450, 451, 140, 452, 2359, 453, 454, + 455, 456, 144, 0, 0, 0, 457, 458, 459, 460, + 0, 461, 462, 2360, 463, 464, 465, 466, 467, 468, + 0, 0, 469, 0, 0, 0, 0, 0, 0, 0, + 0, 470, 471, 472, 473, 474, 475, 155, 156, 476, + 0, 477, 0, 478, 479, 480, 481, 482, 0, 483, + 484, 485, 0, 0, 486, 487, 488, 489, 490, 0, + 491, 492, 493, 0, 494, 495, 0, 2435, 497, 498, + 499, 164, 500, 501, 502, 166, 0, 503, 0, 504, + 168, 505, 0, 506, 2362, 507, 0, 0, 0, 508, + 509, 510, 0, 511, 172, 0, 512, 0, 513, 514, + 515, 516, 517, 0, 518, 519, 520, 0, 521, 522, + 523, 524, 525, 526, 0, 527, 0, 175, 0, 528, + 529, 530, 0, 176, 0, 177, 0, 531, 0, 0, + 532, 0, 533, 534, 535, 536, 537, 538, 539, 0, + 540, 181, 0, 541, 0, 0, 542, 543, 544, 0, + 0, 545, 546, 547, 548, 549, 550, 551, 552, 553, + 554, 555, 556, 188, 0, 190, 557, 558, 191, 0, + 559, 560, 0, 561, 0, 194, 562, 195, 563, 564, + 565, 0, 566, 0, 0, 567, 568, 569, 0, 0, + 196, 0, 0, 0, 200, 570, 571, 572, 573, 574, + 575, 576, 0, 577, 201, 578, 202, 579, 580, 581, + 2363, 582, 583, 584, 585, 586, 587, 588, 204, 589, + 590, 591, 592, 0, 593, 594, 595, 596, 597, 598, + 599, 600, 601, 602, 0, 603, 604, 0, 605, 606, + 212, 607, 608, 609, 610, 611, 612, 613, 614, 0, + 615, 616, 617, 618, 619, 0, 620, 217, 621, 622, + 0, 623, 220, 624, 0, 625, 626, 627, 628, 629, + 630, 631, 632, 633, 634, 222, 0, 635, 636, 0, + 637, 638, 639, 640, 641, 642, 0, 224, 225, 0, + 0, 644, 226, 645, 227, 0, 646, 647, 648, 649, + 650, 651, 652, 0, 2364, 653, 654, 655, 656, 657, + 0, 0, 658, 659, 660, 661, 662, 663, 234, 0, + 664, 0, 665, 666, 667, 0, 0, 668, 0, 0, + 669, 670, 671, 672, 673, 237, 238, 239, 240, 241, + 242, 243, 244, 245, 674, 675, 676, 86, 87, 88, + 412, 90, 91, 92, 413, 0, 414, 95, 0, 0, + 98, 99, 100, 101, 102, 103, 0, 104, 105, 415, + 0, 0, 107, 108, 109, 110, 0, 0, 112, 113, + 114, 115, 0, 116, 0, 0, 416, 417, 0, 0, + 0, 418, 419, 0, 0, 0, 0, 420, 0, 0, + 0, 0, 0, 0, 0, 0, 421, 0, 422, 0, + 423, 424, 35, 425, 0, 0, 0, 0, 0, 0, + 41, 42, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 426, 427, 428, 429, 430, 431, 432, 433, + 696, 434, 435, 436, 0, 0, 0, 0, 0, 0, + 0, 437, 438, 0, 439, 440, 0, 441, 442, 443, + 135, 136, 0, 138, 139, 0, 444, 445, 446, 447, + 448, 0, 0, 449, 450, 451, 140, 452, 0, 453, + 454, 455, 456, 144, 0, 0, 0, 457, 458, 459, + 460, 0, 461, 462, 0, 463, 464, 465, 466, 467, + 468, 0, 0, 469, 697, 0, 0, 0, 0, 0, + 0, 0, 470, 471, 472, 473, 474, 475, 155, 156, + 476, 698, 477, 0, 478, 479, 480, 481, 482, 0, + 483, 484, 485, 0, 0, 486, 487, 488, 489, 490, + 0, 491, 492, 493, 0, 494, 495, 0, 496, 497, + 498, 499, 164, 500, 501, 502, 166, 0, 503, 0, + 504, 168, 505, 0, 506, 0, 507, 0, 0, 0, + 508, 509, 510, 0, 511, 172, 0, 512, 0, 513, + 514, 515, 516, 517, 0, 518, 519, 520, 0, 521, + 522, 523, 524, 525, 526, 0, 527, 0, 175, 0, + 528, 529, 530, 0, 176, 0, 177, 0, 531, 0, + 0, 532, 0, 533, 534, 535, 536, 537, 538, 539, + 0, 540, 181, 0, 541, 0, 0, 542, 543, 544, + 0, 0, 545, 546, 547, 548, 549, 550, 551, 552, + 553, 554, 555, 556, 188, 0, 190, 557, 558, 191, + 0, 559, 560, 0, 561, 0, 194, 562, 195, 563, + 564, 565, 0, 566, 0, 0, 567, 568, 569, 0, + 0, 196, 0, 0, 0, 200, 570, 571, 572, 573, + 574, 575, 576, 0, 577, 201, 578, 202, 579, 580, + 581, 0, 582, 583, 584, 585, 586, 587, 588, 204, + 589, 590, 591, 592, 0, 593, 594, 595, 596, 597, + 598, 599, 600, 601, 602, 0, 603, 604, 0, 605, + 606, 212, 607, 608, 609, 610, 611, 612, 613, 614, + 0, 615, 616, 617, 618, 619, 0, 620, 217, 621, + 622, 0, 623, 220, 624, 0, 625, 626, 627, 628, + 629, 630, 631, 632, 633, 634, 222, 0, 635, 636, + 0, 637, 638, 639, 640, 641, 642, 0, 224, 225, + 0, 0, 644, 226, 645, 227, 0, 646, 647, 648, + 649, 650, 651, 652, 0, 0, 653, 654, 655, 656, + 657, 0, 0, 658, 659, 660, 661, 662, 663, 234, + 0, 664, 0, 665, 666, 667, 0, 0, 668, 0, + 0, 669, 670, 671, 672, 673, 237, 238, 239, 240, + 241, 242, 243, 244, 245, 674, 675, 676, 86, 87, + 88, 412, 90, 91, 92, 413, 0, 414, 95, 0, + 0, 98, 99, 100, 101, 102, 103, 0, 104, 105, + 415, 0, 0, 107, 108, 109, 110, 0, 0, 112, + 113, 114, 115, 0, 116, 0, 0, 416, 417, 0, + 0, 0, 418, 419, 0, 0, 0, 0, 420, 0, + 0, 0, 0, 0, 0, 0, 0, 421, 0, 422, + 0, 423, 424, 35, 0, 0, 0, 0, 0, 0, + 0, 41, 42, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 426, 427, 428, 429, 430, 431, 432, + 433, 985, 434, 435, 436, 0, 0, 0, 0, 0, + 0, 0, 437, 438, 0, 439, 440, 0, 441, 442, + 443, 135, 136, 0, 138, 139, 0, 444, 445, 446, + 447, 448, 0, 0, 449, 450, 451, 140, 452, 0, + 453, 454, 455, 456, 144, 0, 0, 0, 457, 458, + 459, 460, 0, 461, 462, 0, 463, 464, 465, 466, + 467, 468, 986, 0, 469, 0, 0, 0, 0, 0, + 0, 0, 0, 470, 471, 472, 473, 474, 475, 155, + 156, 476, 0, 477, 0, 478, 479, 480, 481, 482, + 0, 483, 484, 485, 0, 0, 486, 487, 488, 489, + 490, 0, 491, 492, 493, 0, 494, 495, 0, 496, + 497, 498, 499, 164, 500, 501, 502, 166, 0, 503, + 0, 504, 168, 505, 0, 506, 0, 507, 0, 0, + 0, 508, 509, 510, 0, 511, 172, 0, 512, 0, + 513, 514, 515, 516, 517, 0, 518, 519, 520, 0, + 521, 522, 523, 524, 525, 526, 0, 527, 0, 175, + 0, 528, 529, 530, 0, 176, 0, 177, 0, 531, + 0, 0, 532, 0, 533, 534, 535, 536, 537, 538, + 539, 0, 540, 181, 0, 541, 0, 0, 542, 543, + 544, 0, 0, 545, 546, 547, 548, 549, 550, 551, + 552, 553, 554, 555, 556, 188, 0, 190, 557, 558, + 191, 0, 559, 560, 0, 561, 0, 194, 562, 195, + 563, 564, 565, 0, 566, 0, 0, 567, 568, 569, + 0, 0, 196, 0, 0, 0, 200, 570, 571, 572, + 573, 574, 575, 576, 0, 577, 201, 578, 202, 579, + 580, 581, 0, 582, 583, 584, 585, 586, 587, 588, + 204, 589, 590, 591, 592, 987, 593, 594, 595, 596, + 597, 598, 599, 600, 601, 602, 0, 603, 604, 0, + 605, 606, 212, 607, 608, 609, 610, 611, 612, 613, + 614, 988, 615, 616, 617, 618, 619, 0, 620, 217, + 621, 622, 0, 623, 220, 624, 0, 625, 626, 627, + 628, 629, 630, 631, 632, 633, 634, 222, 0, 635, + 636, 0, 637, 638, 639, 640, 641, 642, 0, 224, + 225, 0, 0, 644, 226, 645, 227, 0, 646, 647, + 648, 649, 650, 651, 652, 0, 0, 653, 654, 655, + 656, 657, 0, 0, 658, 659, 660, 661, 662, 663, + 234, 0, 664, 0, 665, 666, 667, 0, 0, 668, + 0, 0, 669, 670, 671, 672, 673, 237, 238, 239, + 240, 241, 242, 243, 244, 245, 674, 675, 676, 86, + 87, 88, 412, 90, 91, 92, 413, 901, 414, 95, + 0, 0, 98, 99, 100, 101, 102, 103, 0, 104, + 105, 415, 0, 0, 107, 108, 109, 110, 0, 0, + 112, 113, 114, 115, 0, 116, 0, 0, 416, 417, + 0, 0, 0, 418, 419, 0, 0, 0, 0, 420, + 0, 0, 0, 0, 0, 0, 0, 0, 421, 0, + 422, 0, 423, 424, 35, 425, 0, 0, 0, 0, + 0, 0, 41, 42, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 426, 427, 428, 429, 430, 431, + 432, 433, 902, 434, 435, 436, 0, 0, 0, 0, + 0, 0, 0, 437, 438, 0, 439, 440, 0, 441, + 442, 443, 135, 136, 0, 138, 139, 0, 444, 445, + 446, 447, 448, 0, 0, 449, 450, 451, 140, 452, + 0, 453, 454, 455, 456, 144, 0, 0, 0, 457, + 458, 459, 460, 0, 461, 462, 0, 463, 464, 465, + 466, 467, 468, 0, 0, 469, 0, 0, 0, 0, + 0, 0, 0, 0, 470, 471, 472, 473, 474, 475, + 155, 156, 476, 0, 477, 0, 478, 479, 480, 481, + 482, 0, 483, 484, 485, 0, 0, 486, 487, 488, + 489, 490, 0, 491, 492, 493, 0, 494, 495, 0, + 496, 497, 498, 499, 164, 500, 501, 502, 166, 0, + 503, 0, 504, 168, 505, 0, 506, 0, 507, 0, + 0, 0, 508, 509, 510, 0, 511, 172, 0, 512, + 0, 513, 514, 515, 516, 517, 0, 518, 519, 520, + 0, 521, 522, 523, 524, 525, 526, 0, 527, 0, + 175, 0, 528, 529, 530, 0, 176, 0, 177, 0, + 531, 0, 0, 532, 0, 533, 534, 535, 536, 537, + 538, 539, 0, 540, 181, 0, 541, 0, 0, 542, + 543, 544, 0, 0, 545, 546, 547, 548, 549, 550, + 551, 552, 553, 554, 555, 556, 188, 0, 190, 557, + 558, 191, 0, 559, 560, 0, 561, 0, 194, 562, + 195, 563, 564, 565, 0, 566, 0, 0, 567, 568, + 569, 0, 0, 196, 0, 0, 0, 200, 570, 571, + 572, 573, 574, 575, 576, 0, 577, 201, 578, 202, + 579, 903, 581, 0, 582, 583, 584, 585, 586, 587, + 588, 204, 589, 590, 591, 592, 0, 593, 594, 595, + 596, 597, 598, 599, 600, 601, 602, 0, 603, 604, + 0, 605, 606, 212, 607, 608, 609, 610, 611, 612, + 613, 614, 0, 615, 616, 617, 618, 619, 0, 620, + 217, 621, 622, 0, 623, 220, 624, 0, 625, 626, + 627, 628, 629, 630, 631, 632, 633, 634, 222, 0, + 635, 636, 0, 637, 638, 639, 640, 641, 642, 0, + 224, 225, 0, 0, 644, 226, 645, 227, 0, 646, + 647, 648, 649, 650, 651, 652, 0, 0, 653, 654, + 655, 656, 657, 0, 0, 658, 659, 660, 661, 662, + 663, 234, 0, 664, 0, 665, 666, 667, 0, 0, + 668, 0, 0, 669, 670, 671, 672, 673, 237, 238, + 239, 240, 241, 242, 243, 244, 245, 674, 675, 676, + 86, 87, 88, 412, 90, 91, 92, 413, 0, 414, + 95, 0, 0, 98, 99, 100, 101, 102, 103, 0, + 104, 105, 415, 0, 0, 107, 108, 109, 110, 0, + 0, 112, 113, 114, 115, 0, 116, 0, 0, 416, + 417, 0, 0, 0, 418, 419, 0, 0, 0, 0, + 420, 0, 0, 0, 0, 0, 0, 0, 0, 421, + 0, 422, 0, 423, 424, 35, 0, 0, 0, 0, + 0, 0, 0, 41, 42, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 426, 427, 428, 429, 430, + 431, 432, 433, 2043, 434, 435, 436, 0, 0, 0, + 0, 0, 0, 0, 437, 438, 0, 439, 440, 0, + 441, 442, 443, 135, 136, 0, 138, 139, 0, 444, + 445, 446, 447, 448, 0, 0, 449, 450, 451, 140, + 452, 0, 453, 454, 455, 456, 144, 0, 0, 0, + 457, 458, 459, 460, 0, 461, 462, 0, 463, 464, + 465, 466, 467, 468, 0, 0, 469, 0, 0, 0, + 0, 0, 0, 0, 0, 470, 471, 472, 2044, 474, + 475, 155, 156, 476, 0, 477, 0, 478, 479, 480, + 481, 482, 0, 483, 484, 485, 0, 0, 486, 2045, + 488, 489, 490, 0, 491, 492, 493, 0, 494, 495, + 0, 496, 497, 498, 499, 164, 500, 501, 502, 166, + 0, 503, 0, 504, 168, 505, 0, 506, 2046, 507, + 0, 0, 0, 2047, 509, 510, 0, 511, 172, 0, + 512, 0, 513, 514, 515, 516, 517, 0, 518, 519, + 520, 0, 521, 522, 523, 524, 525, 526, 0, 527, + 0, 175, 0, 528, 529, 530, 0, 176, 0, 177, + 0, 531, 0, 0, 532, 0, 533, 534, 2048, 2049, + 537, 538, 539, 0, 540, 181, 0, 541, 0, 0, + 542, 543, 544, 0, 0, 545, 546, 547, 548, 549, + 550, 551, 552, 553, 554, 555, 556, 188, 0, 190, + 557, 558, 191, 0, 559, 560, 0, 561, 0, 194, + 562, 195, 563, 564, 565, 0, 566, 0, 0, 567, + 568, 569, 0, 0, 196, 0, 0, 0, 200, 570, + 571, 572, 573, 574, 575, 576, 0, 577, 201, 578, + 202, 579, 580, 581, 0, 582, 583, 584, 585, 586, + 587, 588, 204, 589, 590, 591, 592, 0, 593, 594, + 595, 596, 597, 598, 599, 600, 601, 602, 0, 603, + 604, 0, 605, 606, 212, 607, 608, 609, 2050, 611, + 612, 613, 614, 0, 2051, 616, 617, 618, 619, 0, + 620, 217, 621, 622, 0, 623, 220, 624, 0, 625, + 626, 627, 628, 629, 630, 631, 632, 633, 634, 222, + 0, 635, 636, 2052, 637, 2053, 639, 640, 641, 642, + 0, 224, 225, 0, 0, 644, 226, 645, 227, 0, + 646, 647, 2054, 649, 650, 651, 652, 0, 0, 653, + 654, 655, 656, 657, 0, 0, 658, 659, 660, 661, + 662, 663, 234, 0, 664, 0, 665, 666, 667, 0, + 0, 668, 0, 0, 669, 670, 671, 672, 673, 237, + 238, 239, 240, 241, 242, 243, 244, 245, 674, 675, + 676, 86, 87, 88, 412, 90, 91, 92, 413, 0, + 414, 95, 0, 0, 98, 99, 100, 101, 102, 103, + 0, 104, 105, 415, 0, 0, 107, 108, 109, 110, + 0, 0, 112, 113, 114, 115, 0, 116, 0, 0, + 416, 417, 0, 0, 0, 418, 419, 0, 0, 0, + 0, 420, 0, 0, 0, 0, 0, 0, 0, 0, + 421, 0, 422, 0, 423, 424, 35, 0, 0, 0, + 0, 0, 0, 0, 41, 42, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 426, 427, 428, 429, + 430, 431, 432, 433, 0, 434, 435, 436, 0, 0, + 0, 0, 0, 0, 0, 437, 438, 0, 439, 440, + 0, 441, 442, 443, 135, 136, 0, 138, 139, 0, + 444, 445, 446, 447, 448, 0, 0, 449, 450, 451, + 140, 452, 0, 453, 454, 455, 456, 144, 0, 0, + 0, 457, 458, 459, 460, 0, 461, 462, 0, 463, + 464, 465, 466, 467, 468, 986, 0, 469, 0, 0, + 0, 0, 0, 0, 0, 0, 470, 471, 472, 473, + 474, 475, 155, 156, 476, 0, 477, 0, 478, 479, + 480, 481, 482, 0, 483, 484, 485, 0, 0, 486, + 487, 488, 489, 490, 0, 491, 492, 493, 0, 494, + 495, 0, 496, 497, 498, 499, 164, 500, 501, 502, + 166, 0, 503, 0, 504, 168, 505, 0, 506, 0, + 507, 0, 0, 0, 508, 509, 510, 0, 511, 172, + 0, 512, 0, 513, 514, 515, 516, 517, 0, 518, + 519, 520, 0, 521, 522, 523, 524, 525, 526, 0, + 527, 0, 175, 0, 528, 529, 530, 0, 176, 0, + 177, 0, 531, 0, 0, 532, 0, 533, 534, 535, + 536, 537, 538, 539, 0, 540, 181, 0, 541, 0, + 0, 542, 543, 544, 0, 0, 545, 546, 547, 548, + 549, 550, 551, 552, 553, 554, 555, 556, 188, 0, + 190, 557, 558, 191, 0, 559, 560, 0, 561, 0, + 194, 562, 195, 563, 564, 565, 0, 566, 0, 0, + 567, 568, 569, 0, 0, 196, 0, 0, 0, 200, + 570, 571, 572, 573, 574, 575, 576, 0, 577, 201, + 578, 202, 579, 580, 581, 0, 582, 583, 584, 585, + 586, 587, 588, 204, 589, 590, 591, 592, 987, 593, + 594, 595, 596, 597, 598, 599, 600, 601, 602, 0, + 603, 604, 0, 605, 606, 212, 607, 608, 609, 610, + 611, 612, 613, 614, 988, 615, 616, 617, 618, 619, + 0, 620, 217, 621, 622, 0, 623, 220, 624, 0, + 625, 626, 627, 628, 629, 630, 631, 632, 633, 634, + 222, 0, 635, 636, 0, 637, 638, 639, 640, 641, + 642, 0, 224, 225, 0, 0, 644, 226, 645, 227, + 0, 646, 647, 648, 649, 650, 651, 652, 0, 0, + 653, 654, 655, 656, 657, 0, 0, 658, 659, 660, + 661, 662, 663, 234, 0, 664, 0, 665, 666, 667, + 0, 0, 668, 0, 0, 669, 670, 671, 672, 673, + 237, 238, 239, 240, 241, 242, 243, 244, 245, 674, + 675, 676, 86, 87, 88, 412, 90, 91, 92, 413, + 0, 414, 95, 0, 0, 98, 99, 100, 101, 102, + 103, 0, 104, 105, 415, 0, 0, 107, 108, 109, + 110, 0, 0, 112, 113, 114, 115, 0, 116, 0, + 0, 416, 417, 0, 0, 0, 418, 419, 0, 0, + 0, 0, 420, 0, 0, 0, 0, 0, 0, 0, + 0, 421, 0, 422, 0, 423, 424, 35, 0, 0, + 0, 0, 0, 0, 0, 41, 42, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 426, 427, 428, + 429, 430, 431, 432, 433, 0, 434, 435, 436, 130, + 131, 0, 0, 0, 0, 0, 437, 438, 0, 439, + 440, 0, 441, 442, 443, 135, 136, 0, 138, 139, + 0, 444, 445, 446, 447, 448, 0, 0, 449, 450, + 451, 140, 452, 0, 453, 454, 455, 456, 144, 0, + 0, 0, 457, 458, 459, 460, 0, 461, 462, 0, + 463, 464, 465, 466, 467, 468, 0, 0, 469, 0, + 0, 0, 0, 0, 0, 0, 0, 470, 471, 472, + 473, 474, 475, 155, 156, 476, 0, 477, 0, 478, + 479, 480, 481, 482, 0, 483, 484, 485, 0, 0, + 486, 487, 488, 489, 490, 0, 491, 492, 493, 0, + 494, 495, 0, 496, 497, 498, 499, 164, 500, 501, + 502, 166, 0, 503, 0, 504, 168, 505, 0, 506, + 0, 507, 0, 0, 0, 508, 509, 510, 0, 511, + 172, 0, 512, 0, 513, 514, 515, 516, 517, 0, + 518, 519, 520, 0, 521, 522, 523, 524, 525, 526, + 0, 527, 0, 175, 0, 528, 529, 530, 0, 176, + 0, 177, 0, 531, 0, 0, 532, 0, 533, 534, + 535, 536, 537, 538, 539, 0, 540, 181, 0, 541, + 0, 0, 542, 543, 544, 0, 0, 545, 546, 547, + 548, 549, 550, 551, 552, 553, 554, 555, 556, 188, + 0, 190, 557, 558, 191, 0, 559, 560, 0, 561, + 0, 194, 562, 195, 563, 564, 565, 0, 566, 0, + 0, 567, 568, 569, 0, 0, 196, 0, 0, 0, + 200, 570, 571, 572, 573, 574, 575, 576, 0, 577, + 201, 578, 202, 579, 580, 581, 0, 582, 583, 584, + 585, 586, 587, 588, 204, 589, 590, 591, 592, 0, + 593, 594, 595, 596, 597, 598, 599, 600, 601, 602, + 0, 603, 604, 0, 605, 606, 212, 607, 608, 609, + 610, 611, 612, 613, 614, 0, 615, 616, 617, 618, + 619, 0, 620, 217, 621, 622, 0, 623, 220, 624, + 0, 625, 626, 627, 628, 629, 630, 631, 632, 633, + 634, 222, 0, 635, 636, 0, 637, 638, 639, 640, + 641, 642, 0, 224, 225, 0, 0, 644, 226, 645, + 227, 0, 646, 647, 648, 649, 650, 651, 652, 0, + 0, 653, 654, 655, 656, 657, 0, 0, 658, 659, + 660, 661, 662, 663, 234, 0, 664, 1362, 665, 666, + 667, 0, 0, 668, 0, 0, 669, 670, 671, 672, + 673, 237, 238, 239, 240, 241, 242, 243, 244, 245, + 674, 675, 676, 86, 87, 88, 412, 90, 91, 92, + 413, 2032, 414, 95, 0, 0, 98, 99, 100, 101, + 102, 103, 0, 104, 105, 415, 0, 0, 107, 108, + 109, 110, 0, 0, 2317, 113, 114, 115, 0, 116, + 0, 0, 416, 417, 0, 0, 0, 418, 419, 0, + 0, 0, 0, 420, 0, 0, 0, 0, 0, 0, + 0, 0, 421, 0, 422, 0, 423, 424, 35, 425, + 0, 0, 0, 0, 0, 0, 41, 42, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 426, 427, + 428, 429, 430, 431, 432, 433, 0, 434, 435, 436, + 0, 0, 0, 0, 0, 0, 0, 437, 438, 0, + 439, 440, 0, 441, 442, 443, 135, 136, 0, 138, + 139, 0, 444, 445, 446, 447, 448, 0, 0, 449, + 450, 451, 140, 452, 0, 453, 454, 455, 456, 144, + 0, 0, 0, 457, 458, 459, 460, 0, 461, 462, + 0, 463, 464, 465, 466, 467, 468, 0, 0, 469, + 0, 0, 0, 0, 0, 0, 0, 0, 470, 471, + 472, 473, 474, 475, 155, 156, 476, 0, 477, 0, + 478, 479, 480, 481, 482, 0, 483, 484, 485, 0, + 0, 486, 487, 488, 489, 490, 0, 491, 492, 493, + 0, 494, 495, 0, 496, 497, 498, 499, 164, 500, + 501, 502, 166, 0, 503, 0, 504, 168, 505, 0, + 506, 0, 507, 0, 0, 0, 508, 509, 2890, 0, + 511, 172, 0, 512, 0, 513, 514, 515, 516, 517, + 0, 518, 519, 520, 0, 521, 522, 523, 524, 525, + 526, 0, 527, 0, 175, 0, 528, 529, 530, 0, + 176, 0, 177, 0, 531, 0, 0, 532, 0, 533, + 534, 535, 536, 537, 538, 539, 0, 540, 181, 0, + 541, 0, 0, 542, 543, 2891, 0, 0, 545, 546, + 547, 548, 549, 550, 551, 552, 553, 554, 555, 556, + 188, 0, 190, 557, 558, 191, 0, 559, 560, 0, + 561, 0, 194, 562, 195, 563, 564, 565, 0, 566, + 0, 0, 567, 568, 569, 0, 0, 196, 0, 0, + 0, 200, 570, 571, 572, 573, 574, 575, 576, 0, + 577, 201, 578, 202, 579, 580, 581, 0, 582, 583, + 584, 585, 586, 587, 588, 204, 589, 590, 591, 592, + 0, 593, 594, 595, 596, 597, 598, 599, 600, 601, + 602, 0, 603, 604, 0, 605, 606, 212, 607, 608, + 609, 610, 611, 612, 613, 614, 0, 615, 616, 617, + 618, 619, 0, 620, 217, 621, 622, 0, 623, 220, + 624, 0, 625, 626, 627, 628, 629, 630, 631, 632, + 633, 634, 222, 0, 635, 636, 2892, 637, 638, 2893, + 640, 2894, 642, 0, 224, 225, 0, 0, 644, 226, + 645, 227, 0, 646, 647, 648, 649, 650, 651, 652, + 0, 0, 653, 654, 2895, 656, 657, 0, 0, 658, + 659, 660, 661, 662, 663, 234, 0, 664, 0, 665, + 666, 667, 0, 0, 668, 0, 0, 669, 670, 671, + 672, 673, 237, 238, 239, 240, 241, 242, 243, 244, + 245, 674, 675, 676, 86, 87, 88, 412, 90, 91, + 92, 413, 0, 414, 95, 0, 0, 98, 99, 100, + 101, 102, 103, 0, 104, 105, 415, 0, 0, 107, + 108, 109, 110, 0, 0, 112, 113, 114, 115, 0, + 116, 0, 0, 416, 417, 0, 0, 0, 418, 419, + 0, 0, 0, 0, 420, 0, 0, 0, 0, 0, + 0, 0, 0, 421, 0, 422, 0, 423, 424, 35, + 425, 0, 0, 0, 0, 0, 0, 41, 42, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 426, + 427, 428, 429, 430, 431, 432, 433, 705, 434, 435, + 436, 0, 0, 0, 0, 0, 0, 0, 437, 438, + 0, 439, 440, 0, 441, 442, 443, 135, 136, 0, + 138, 139, 0, 444, 445, 446, 447, 448, 0, 0, + 449, 450, 451, 140, 452, 0, 453, 454, 455, 456, + 144, 0, 0, 0, 457, 458, 459, 460, 0, 461, + 462, 0, 463, 464, 465, 466, 467, 468, 0, 0, + 469, 0, 0, 0, 0, 0, 0, 0, 0, 470, + 471, 472, 473, 474, 475, 155, 156, 476, 0, 477, + 0, 478, 479, 480, 481, 482, 0, 483, 484, 485, + 0, 0, 486, 487, 488, 489, 490, 0, 491, 492, + 493, 0, 494, 495, 0, 496, 497, 498, 499, 164, + 500, 501, 502, 166, 0, 503, 0, 504, 168, 505, + 0, 506, 0, 507, 0, 0, 0, 508, 509, 510, + 0, 511, 172, 0, 512, 0, 513, 514, 515, 516, + 517, 0, 518, 519, 520, 0, 521, 522, 523, 524, + 525, 526, 0, 527, 0, 175, 0, 528, 529, 530, + 0, 176, 0, 177, 0, 531, 0, 0, 532, 0, + 533, 534, 535, 536, 537, 538, 539, 0, 540, 181, + 0, 541, 0, 0, 542, 543, 544, 0, 0, 545, + 546, 547, 548, 549, 550, 551, 552, 553, 554, 555, + 556, 188, 0, 190, 557, 558, 191, 0, 559, 560, + 0, 561, 0, 194, 562, 195, 563, 564, 565, 0, + 566, 0, 0, 567, 568, 569, 0, 0, 196, 0, + 0, 0, 200, 570, 571, 572, 573, 574, 575, 576, + 0, 577, 201, 578, 202, 579, 580, 581, 0, 582, + 583, 584, 585, 586, 587, 588, 204, 589, 590, 591, + 592, 0, 593, 594, 595, 596, 597, 598, 599, 600, + 601, 602, 0, 603, 604, 0, 605, 606, 212, 607, + 608, 609, 610, 611, 612, 613, 614, 0, 615, 616, + 617, 618, 619, 0, 620, 217, 621, 622, 0, 623, + 220, 624, 0, 625, 626, 627, 628, 629, 630, 631, + 632, 633, 634, 222, 0, 635, 636, 0, 637, 638, + 639, 640, 641, 642, 0, 224, 225, 0, 0, 644, + 226, 645, 227, 0, 646, 647, 648, 649, 650, 651, + 652, 0, 0, 653, 654, 655, 656, 657, 0, 0, + 658, 659, 660, 661, 662, 663, 234, 0, 664, 0, + 665, 666, 667, 0, 0, 668, 0, 0, 669, 670, + 671, 672, 673, 237, 238, 239, 240, 241, 242, 243, + 244, 245, 674, 675, 676, 86, 87, 88, 412, 90, + 91, 92, 413, 0, 414, 95, 0, 0, 98, 99, + 100, 101, 102, 103, 0, 104, 105, 415, 0, 0, + 107, 108, 109, 110, 0, 0, 112, 113, 114, 115, + 0, 116, 0, 0, 416, 417, 0, 0, 0, 418, + 419, 0, 0, 0, 0, 420, 0, 0, 0, 0, + 0, 0, 0, 0, 421, 0, 422, 0, 423, 424, + 35, 425, 0, 0, 0, 0, 0, 0, 41, 42, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 426, 427, 428, 429, 430, 431, 432, 433, 0, 434, + 435, 436, 0, 0, 0, 0, 0, 0, 0, 437, + 438, 0, 439, 440, 0, 441, 442, 443, 135, 136, + 0, 138, 139, 0, 444, 445, 446, 447, 448, 0, + 0, 449, 450, 451, 140, 452, 0, 453, 454, 455, + 456, 144, 0, 0, 0, 457, 458, 459, 460, 0, + 461, 462, 0, 463, 464, 465, 466, 467, 468, 0, + 0, 469, 0, 0, 0, 0, 0, 0, 0, 0, + 470, 471, 472, 473, 474, 475, 155, 156, 476, 698, + 477, 0, 478, 479, 480, 481, 482, 0, 483, 484, + 485, 0, 0, 486, 487, 488, 489, 490, 0, 491, + 492, 493, 0, 494, 495, 0, 496, 497, 498, 499, + 164, 500, 501, 502, 166, 0, 503, 0, 504, 168, + 505, 0, 506, 0, 507, 0, 0, 0, 508, 509, + 510, 0, 511, 172, 0, 512, 0, 513, 514, 515, + 516, 517, 0, 518, 519, 520, 0, 521, 522, 523, + 524, 525, 526, 0, 527, 0, 175, 0, 528, 529, + 530, 0, 176, 0, 177, 0, 531, 0, 0, 532, + 0, 533, 534, 535, 536, 537, 538, 539, 0, 540, + 181, 0, 541, 0, 0, 542, 543, 544, 0, 0, + 545, 546, 547, 548, 549, 550, 551, 552, 553, 554, + 555, 556, 188, 0, 190, 557, 558, 191, 0, 559, + 560, 0, 561, 0, 194, 562, 195, 563, 564, 565, + 0, 566, 0, 0, 567, 568, 569, 0, 0, 196, + 0, 0, 0, 200, 570, 571, 572, 573, 574, 575, + 576, 0, 577, 201, 578, 202, 579, 580, 581, 0, + 582, 583, 584, 585, 586, 587, 588, 204, 589, 590, + 591, 592, 0, 593, 594, 595, 596, 597, 598, 599, + 600, 601, 602, 0, 603, 604, 0, 605, 606, 212, + 607, 608, 609, 610, 611, 612, 613, 614, 0, 615, + 616, 617, 618, 619, 0, 620, 217, 621, 622, 0, + 623, 220, 624, 0, 625, 626, 627, 628, 629, 630, + 631, 632, 633, 634, 222, 0, 635, 636, 0, 637, + 638, 639, 640, 641, 642, 0, 224, 225, 0, 0, + 644, 226, 645, 227, 0, 646, 647, 648, 649, 650, + 651, 652, 0, 0, 653, 654, 655, 656, 657, 0, + 0, 658, 659, 660, 661, 662, 663, 234, 0, 664, + 0, 665, 666, 667, 0, 0, 668, 0, 0, 669, + 670, 671, 672, 673, 237, 238, 239, 240, 241, 242, + 243, 244, 245, 674, 675, 676, 86, 87, 88, 412, + 90, 91, 92, 413, 0, 414, 95, 0, 0, 98, + 99, 100, 101, 102, 103, 0, 104, 105, 415, 0, + 0, 107, 108, 109, 110, 0, 0, 112, 113, 114, + 115, 0, 116, 0, 0, 416, 417, 0, 0, 0, + 418, 419, 0, 0, 0, 0, 420, 0, 0, 0, + 0, 0, 0, 0, 0, 421, 0, 422, 0, 423, + 424, 35, 425, 0, 0, 0, 0, 0, 0, 41, + 42, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 426, 427, 428, 429, 430, 431, 432, 433, 853, + 434, 435, 436, 0, 0, 0, 0, 0, 0, 0, + 437, 438, 0, 439, 440, 0, 441, 442, 443, 135, + 136, 0, 138, 139, 0, 444, 445, 446, 447, 448, + 0, 0, 449, 450, 451, 140, 452, 0, 453, 454, + 455, 456, 144, 0, 0, 0, 457, 458, 459, 460, + 0, 461, 462, 0, 463, 464, 465, 466, 467, 468, + 0, 0, 469, 0, 0, 0, 0, 0, 0, 0, + 0, 470, 471, 472, 473, 474, 475, 155, 156, 476, + 0, 477, 0, 478, 479, 480, 481, 482, 0, 483, + 484, 485, 0, 0, 486, 487, 488, 489, 490, 0, + 491, 492, 493, 0, 494, 495, 0, 496, 497, 498, + 499, 164, 500, 501, 502, 166, 0, 503, 0, 504, + 168, 505, 0, 506, 0, 507, 0, 0, 0, 508, + 509, 510, 0, 511, 172, 0, 512, 0, 513, 514, + 515, 516, 517, 0, 518, 519, 520, 0, 521, 522, + 523, 524, 525, 526, 0, 527, 0, 175, 0, 528, + 529, 530, 0, 176, 0, 177, 0, 531, 0, 0, + 532, 0, 533, 534, 535, 536, 537, 538, 539, 0, + 540, 181, 0, 541, 0, 0, 542, 543, 544, 0, + 0, 545, 546, 547, 548, 549, 550, 551, 552, 553, + 554, 555, 556, 188, 0, 190, 557, 558, 191, 0, + 559, 560, 0, 561, 0, 194, 562, 195, 563, 564, + 565, 0, 566, 0, 0, 567, 568, 569, 0, 0, + 196, 0, 0, 0, 200, 570, 571, 572, 573, 574, + 575, 576, 0, 577, 201, 578, 202, 579, 580, 581, + 0, 582, 583, 584, 585, 586, 587, 588, 204, 589, + 590, 591, 592, 0, 593, 594, 595, 596, 597, 598, + 599, 600, 601, 602, 0, 603, 604, 0, 605, 606, + 212, 607, 608, 609, 610, 611, 612, 613, 614, 0, + 615, 616, 617, 618, 619, 0, 620, 217, 621, 622, + 0, 623, 220, 624, 0, 625, 626, 627, 628, 629, + 630, 631, 632, 633, 634, 222, 0, 635, 636, 0, + 637, 638, 639, 640, 641, 642, 0, 224, 225, 0, + 0, 644, 226, 645, 227, 0, 646, 647, 648, 649, + 650, 651, 652, 0, 0, 653, 654, 655, 656, 657, + 0, 0, 658, 659, 660, 661, 662, 663, 234, 0, + 664, 0, 665, 666, 667, 0, 0, 668, 0, 0, + 669, 670, 671, 672, 673, 237, 238, 239, 240, 241, + 242, 243, 244, 245, 674, 675, 676, 86, 87, 88, + 412, 90, 91, 92, 413, 0, 414, 95, 0, 0, + 98, 99, 100, 101, 102, 103, 0, 104, 105, 415, + 0, 0, 107, 108, 109, 110, 0, 0, 112, 113, + 114, 115, 0, 116, 0, 0, 416, 417, 0, 0, + 0, 418, 419, 0, 0, 0, 0, 420, 0, 0, + 0, 0, 0, 0, 0, 0, 421, 0, 422, 0, + 423, 424, 35, 425, 0, 0, 0, 0, 0, 0, + 41, 42, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 426, 427, 428, 429, 430, 431, 432, 433, + 1299, 434, 435, 436, 0, 0, 0, 0, 0, 0, + 0, 437, 438, 0, 439, 440, 0, 441, 442, 443, + 135, 136, 0, 138, 139, 0, 444, 445, 446, 447, + 448, 0, 0, 449, 450, 451, 140, 452, 0, 453, + 454, 455, 456, 144, 0, 0, 0, 457, 458, 459, + 460, 0, 461, 462, 0, 463, 464, 465, 466, 467, + 468, 0, 0, 469, 0, 0, 0, 0, 0, 0, + 0, 0, 470, 471, 472, 473, 474, 475, 155, 156, + 476, 0, 477, 0, 478, 479, 480, 481, 482, 0, + 483, 484, 485, 0, 0, 486, 487, 488, 489, 490, + 0, 491, 492, 493, 0, 494, 495, 0, 496, 497, + 498, 499, 164, 500, 501, 502, 166, 0, 503, 0, + 504, 168, 505, 0, 506, 0, 507, 0, 0, 0, + 508, 509, 510, 0, 511, 172, 0, 512, 0, 513, + 514, 515, 516, 517, 0, 518, 519, 520, 0, 521, + 522, 523, 524, 525, 526, 0, 527, 0, 175, 0, + 528, 529, 530, 0, 176, 0, 177, 0, 531, 0, + 0, 532, 0, 533, 534, 535, 536, 537, 538, 539, + 0, 540, 181, 0, 541, 0, 0, 542, 543, 544, + 0, 0, 545, 546, 547, 548, 549, 550, 551, 552, + 553, 554, 555, 556, 188, 0, 190, 557, 558, 191, + 0, 559, 560, 0, 561, 0, 194, 562, 195, 563, + 564, 565, 0, 566, 0, 0, 567, 568, 569, 0, + 0, 196, 0, 0, 0, 200, 570, 571, 572, 573, + 574, 575, 576, 0, 577, 201, 578, 202, 579, 580, + 581, 0, 582, 583, 584, 585, 586, 587, 588, 204, + 589, 590, 591, 592, 0, 593, 594, 595, 596, 597, + 598, 599, 600, 601, 602, 0, 603, 604, 0, 605, + 606, 212, 607, 608, 609, 610, 611, 612, 613, 614, + 0, 615, 616, 617, 618, 619, 0, 620, 217, 621, + 622, 0, 623, 220, 624, 0, 625, 626, 627, 628, + 629, 630, 631, 632, 633, 634, 222, 0, 635, 636, + 0, 637, 638, 639, 640, 641, 642, 0, 224, 225, + 0, 0, 644, 226, 645, 227, 0, 646, 647, 648, + 649, 650, 651, 652, 0, 0, 653, 654, 655, 656, + 657, 0, 0, 658, 659, 660, 661, 662, 663, 234, + 0, 664, 0, 665, 666, 667, 0, 0, 668, 0, + 0, 669, 670, 671, 672, 673, 237, 238, 239, 240, + 241, 242, 243, 244, 245, 674, 675, 676, 86, 87, + 88, 412, 90, 91, 92, 413, 0, 414, 95, 0, + 0, 98, 99, 100, 101, 102, 103, 0, 104, 105, + 415, 0, 0, 107, 108, 109, 110, 0, 0, 112, + 113, 114, 115, 0, 116, 0, 0, 416, 417, 0, + 0, 0, 418, 419, 0, 0, 0, 0, 420, 0, + 0, 0, 0, 0, 0, 0, 0, 421, 0, 422, + 0, 423, 424, 35, 0, 0, 0, 0, 0, 0, + 0, 41, 42, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 426, 427, 428, 429, 430, 431, 432, + 433, 0, 434, 435, 436, 0, 0, 0, 0, 0, + 0, 0, 437, 438, 0, 439, 440, 0, 441, 442, + 443, 135, 136, 0, 138, 139, 0, 444, 445, 446, + 447, 448, 0, 0, 449, 450, 451, 140, 452, 0, + 453, 454, 455, 456, 144, 0, 0, 0, 457, 458, + 459, 460, 0, 461, 462, 0, 463, 464, 465, 466, + 467, 468, 0, 0, 469, 0, 0, 0, 0, 0, + 0, 0, 2523, 470, 471, 472, 473, 474, 475, 155, + 156, 476, 0, 477, 0, 478, 479, 480, 481, 482, + 0, 483, 484, 485, 0, 0, 486, 487, 488, 489, + 490, 0, 491, 492, 493, 0, 494, 495, 0, 496, + 497, 498, 499, 164, 500, 501, 502, 166, 0, 503, + 0, 504, 168, 505, 0, 506, 0, 507, 0, 0, + 0, 508, 509, 510, 0, 511, 172, 0, 512, 0, + 513, 514, 515, 516, 517, 0, 518, 519, 520, 0, + 521, 522, 523, 524, 525, 526, 0, 527, 0, 175, + 0, 528, 529, 530, 0, 176, 0, 177, 0, 531, + 0, 0, 532, 0, 533, 534, 535, 536, 537, 538, + 539, 0, 540, 181, 0, 541, 0, 0, 542, 543, + 544, 0, 0, 545, 546, 547, 548, 549, 550, 551, + 552, 553, 554, 555, 556, 188, 0, 190, 557, 558, + 191, 0, 559, 560, 0, 561, 0, 194, 562, 195, + 563, 564, 565, 0, 566, 0, 0, 567, 568, 569, + 0, 0, 196, 0, 0, 0, 200, 570, 571, 572, + 573, 574, 575, 576, 0, 577, 201, 578, 202, 579, + 580, 581, 0, 582, 583, 584, 585, 586, 587, 588, + 204, 589, 590, 591, 592, 0, 593, 594, 595, 596, + 597, 598, 599, 600, 601, 602, 0, 603, 604, 0, + 605, 606, 212, 607, 608, 609, 610, 611, 612, 613, + 614, 0, 615, 616, 617, 618, 619, 0, 620, 217, + 621, 622, 0, 623, 220, 624, 0, 625, 626, 627, + 628, 629, 630, 631, 632, 633, 634, 222, 0, 635, + 636, 0, 637, 638, 639, 640, 641, 642, 0, 224, + 225, 0, 0, 644, 226, 645, 227, 0, 646, 647, + 648, 649, 650, 651, 652, 0, 0, 653, 654, 655, + 656, 657, 2524, 0, 658, 659, 660, 661, 662, 663, + 234, 0, 664, 0, 665, 666, 667, 0, 0, 668, + 0, 0, 669, 670, 671, 672, 673, 237, 238, 239, + 240, 241, 242, 243, 244, 245, 674, 675, 676, 86, + 87, 88, 412, 90, 91, 92, 413, 0, 414, 95, + 0, 0, 98, 99, 100, 101, 102, 103, 0, 104, + 105, 415, 0, 0, 107, 108, 109, 110, 0, 0, + 112, 113, 114, 115, 0, 116, 0, 0, 416, 417, + 0, 0, 0, 418, 419, 0, 0, 0, 0, 420, + 0, 0, 0, 0, 0, 0, 0, 0, 421, 0, + 422, 0, 423, 424, 35, 0, 0, 0, 0, 0, + 0, 0, 41, 42, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 426, 427, 428, 429, 430, 431, + 432, 433, 0, 434, 435, 436, 130, 131, 0, 0, + 0, 0, 0, 437, 438, 0, 439, 440, 0, 441, + 442, 443, 135, 136, 0, 138, 139, 0, 444, 445, + 446, 447, 448, 0, 0, 449, 450, 451, 140, 452, + 0, 453, 454, 455, 456, 144, 0, 0, 0, 457, + 458, 459, 460, 0, 461, 462, 0, 463, 464, 465, + 466, 467, 468, 0, 0, 469, 0, 0, 0, 0, + 0, 0, 0, 0, 470, 471, 472, 473, 474, 475, + 155, 156, 476, 0, 477, 0, 478, 479, 480, 481, + 482, 0, 483, 484, 485, 0, 0, 486, 487, 488, + 489, 490, 0, 491, 492, 493, 0, 494, 495, 0, + 496, 497, 498, 499, 164, 500, 501, 502, 166, 0, + 503, 0, 504, 168, 505, 0, 506, 0, 507, 0, + 0, 0, 508, 509, 510, 0, 511, 172, 0, 512, + 0, 513, 514, 515, 516, 517, 0, 518, 519, 520, + 0, 521, 522, 523, 524, 525, 526, 0, 527, 0, + 175, 0, 528, 529, 530, 0, 176, 0, 177, 0, + 531, 0, 0, 532, 0, 533, 534, 535, 536, 537, + 538, 539, 0, 540, 181, 0, 541, 0, 0, 542, + 543, 544, 0, 0, 545, 546, 547, 548, 549, 550, + 551, 552, 553, 554, 555, 556, 188, 0, 190, 557, + 558, 191, 0, 559, 560, 0, 561, 0, 194, 562, + 195, 563, 564, 565, 0, 566, 0, 0, 567, 568, + 569, 0, 0, 196, 0, 0, 0, 200, 570, 571, + 572, 573, 574, 575, 576, 0, 577, 201, 578, 202, + 579, 580, 581, 0, 582, 583, 584, 585, 586, 587, + 588, 204, 589, 590, 591, 592, 0, 593, 594, 595, + 596, 597, 598, 599, 600, 601, 602, 0, 603, 604, + 0, 605, 606, 212, 607, 608, 609, 610, 611, 612, + 613, 614, 0, 615, 616, 617, 618, 619, 0, 620, + 217, 621, 622, 0, 623, 220, 624, 0, 625, 626, + 627, 628, 629, 630, 631, 632, 633, 634, 222, 0, + 635, 636, 0, 637, 638, 639, 640, 641, 642, 0, + 224, 225, 0, 0, 644, 226, 645, 227, 0, 646, + 647, 648, 649, 650, 651, 652, 0, 0, 653, 654, + 655, 656, 657, 0, 0, 658, 659, 660, 661, 662, + 663, 234, 0, 664, 0, 665, 666, 667, 0, 0, + 668, 0, 0, 669, 670, 671, 672, 673, 237, 238, + 239, 240, 241, 242, 243, 244, 245, 674, 675, 676, + 86, 87, 88, 412, 90, 91, 92, 413, 0, 414, + 95, 0, 0, 98, 99, 100, 101, 102, 103, 0, + 104, 105, 415, 0, 0, 107, 108, 109, 110, 0, + 0, 112, 113, 114, 115, 0, 116, 0, 0, 416, + 417, 0, 0, 0, 418, 419, 0, 0, 0, 0, + 420, 0, 0, 0, 0, 0, 0, 0, 0, 421, + 0, 422, 0, 423, 424, 35, 0, 0, 0, 0, + 0, 0, 0, 41, 42, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 426, 427, 428, 429, 430, + 431, 432, 433, 3094, 434, 435, 436, 0, 0, 0, + 0, 0, 0, 0, 437, 438, 0, 439, 440, 0, + 441, 442, 443, 135, 136, 0, 138, 139, 0, 444, + 445, 446, 447, 448, 0, 0, 449, 450, 451, 140, + 452, 0, 453, 454, 455, 456, 144, 0, 0, 0, + 457, 458, 459, 460, 0, 461, 462, 0, 463, 464, + 465, 466, 467, 468, 0, 0, 469, 0, 0, 0, + 0, 0, 0, 0, 0, 470, 471, 472, 473, 474, + 475, 155, 156, 476, 0, 477, 0, 478, 479, 480, + 481, 482, 0, 483, 484, 485, 0, 0, 486, 487, + 488, 489, 490, 0, 491, 492, 493, 0, 494, 495, + 0, 496, 497, 498, 499, 164, 500, 501, 502, 166, + 0, 503, 0, 504, 168, 505, 0, 506, 0, 507, + 0, 0, 0, 508, 509, 510, 0, 511, 172, 0, + 512, 0, 513, 514, 515, 516, 517, 0, 518, 519, + 520, 0, 521, 522, 523, 524, 525, 526, 0, 527, + 0, 175, 0, 528, 529, 530, 0, 176, 0, 177, + 0, 531, 0, 0, 532, 0, 533, 534, 535, 536, + 537, 538, 539, 0, 540, 181, 0, 541, 0, 0, + 542, 543, 544, 0, 0, 545, 546, 547, 548, 549, + 550, 551, 552, 553, 554, 555, 556, 188, 0, 190, + 557, 558, 191, 0, 559, 560, 0, 561, 0, 194, + 562, 195, 563, 564, 565, 0, 566, 0, 0, 567, + 568, 569, 0, 0, 196, 0, 0, 0, 200, 570, + 571, 572, 573, 574, 575, 576, 0, 577, 201, 578, + 202, 579, 580, 581, 0, 582, 583, 584, 585, 586, + 587, 588, 204, 589, 590, 591, 592, 0, 593, 594, + 595, 596, 597, 598, 599, 600, 601, 602, 0, 603, + 604, 0, 605, 606, 212, 607, 608, 609, 610, 611, + 612, 613, 614, 0, 615, 616, 617, 618, 619, 0, + 620, 217, 621, 622, 0, 623, 220, 624, 0, 625, + 626, 627, 628, 629, 630, 631, 632, 633, 634, 222, + 0, 635, 636, 0, 637, 638, 639, 640, 641, 642, + 0, 224, 225, 0, 0, 644, 226, 645, 227, 0, + 646, 647, 648, 649, 650, 651, 652, 0, 0, 653, + 654, 655, 656, 657, 3095, 0, 658, 659, 660, 661, + 662, 663, 234, 0, 664, 0, 665, 666, 667, 0, + 0, 668, 0, 0, 669, 670, 671, 672, 673, 237, + 238, 239, 240, 241, 242, 243, 244, 245, 674, 675, + 676, 86, 87, 88, 412, 90, 91, 92, 413, 0, + 414, 95, 0, 0, 98, 99, 100, 101, 102, 103, + 0, 104, 105, 415, 0, 0, 107, 108, 109, 110, + 0, 0, 112, 113, 114, 115, 0, 116, 0, 0, + 416, 417, 0, 0, 0, 418, 419, 0, 0, 0, + 0, 420, 0, 0, 0, 0, 0, 0, 0, 0, + 421, 0, 422, 0, 423, 424, 35, 0, 0, 0, + 0, 0, 0, 0, 41, 42, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 426, 427, 428, 429, + 430, 431, 432, 433, 3106, 434, 435, 436, 0, 0, + 0, 0, 0, 0, 0, 437, 438, 0, 439, 440, + 0, 441, 442, 443, 135, 136, 0, 138, 139, 0, + 444, 445, 446, 447, 448, 0, 0, 449, 450, 451, + 140, 452, 0, 453, 454, 455, 456, 144, 0, 0, + 0, 457, 458, 459, 460, 0, 461, 462, 0, 463, + 464, 465, 466, 467, 468, 0, 0, 469, 0, 0, + 0, 0, 0, 0, 0, 0, 470, 471, 472, 473, + 474, 475, 155, 156, 476, 0, 477, 0, 478, 479, + 480, 481, 482, 0, 483, 484, 485, 0, 0, 486, + 487, 488, 489, 490, 0, 491, 492, 493, 0, 494, + 495, 0, 496, 497, 498, 499, 164, 500, 501, 502, + 166, 0, 503, 0, 504, 168, 505, 0, 506, 0, + 507, 0, 0, 0, 508, 509, 510, 0, 511, 172, + 0, 512, 0, 513, 514, 515, 516, 517, 0, 518, + 519, 520, 0, 521, 522, 523, 524, 525, 526, 0, + 527, 0, 175, 0, 528, 529, 530, 0, 176, 0, + 177, 0, 531, 0, 0, 532, 0, 533, 534, 535, + 536, 537, 538, 539, 0, 540, 181, 0, 541, 0, + 0, 542, 543, 544, 0, 0, 545, 546, 547, 548, + 549, 550, 551, 552, 553, 554, 555, 556, 188, 0, + 190, 557, 558, 191, 0, 559, 560, 0, 561, 0, + 194, 562, 195, 563, 564, 565, 0, 566, 0, 0, + 567, 568, 569, 0, 0, 196, 0, 0, 0, 200, + 570, 571, 572, 573, 574, 575, 576, 0, 577, 201, + 578, 202, 579, 580, 581, 0, 582, 583, 584, 585, + 586, 587, 588, 204, 589, 590, 591, 592, 0, 593, + 594, 595, 596, 597, 598, 599, 600, 601, 602, 0, + 603, 604, 0, 605, 606, 212, 607, 608, 609, 610, + 611, 612, 613, 614, 0, 615, 616, 617, 618, 619, + 0, 620, 217, 621, 622, 0, 623, 220, 624, 0, + 625, 626, 627, 628, 629, 630, 631, 632, 633, 634, + 222, 0, 635, 636, 0, 637, 638, 639, 640, 641, + 642, 0, 224, 225, 0, 0, 644, 226, 645, 227, + 0, 646, 647, 648, 649, 650, 651, 652, 0, 0, + 653, 654, 655, 656, 657, 3107, 0, 658, 659, 660, + 661, 662, 663, 234, 0, 664, 0, 665, 666, 667, + 0, 0, 668, 0, 0, 669, 670, 671, 672, 673, + 237, 238, 239, 240, 241, 242, 243, 244, 245, 674, + 675, 676, 86, 87, 88, 412, 90, 91, 92, 413, + 0, 414, 95, 0, 0, 98, 99, 100, 101, 102, + 103, 0, 104, 105, 415, 0, 0, 107, 108, 109, + 110, 0, 0, 112, 113, 114, 115, 0, 116, 0, + 0, 416, 417, 0, 0, 0, 418, 419, 0, 0, + 0, 0, 420, 0, 0, 0, 0, 0, 0, 0, + 0, 421, 0, 422, 0, 423, 424, 35, 425, 0, + 0, 0, 0, 0, 0, 41, 42, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 426, 427, 428, + 429, 430, 431, 432, 433, 0, 434, 435, 436, 0, + 0, 0, 0, 0, 0, 0, 437, 438, 0, 439, + 440, 0, 441, 442, 443, 135, 136, 0, 138, 139, + 0, 444, 445, 446, 447, 448, 0, 0, 449, 450, + 451, 140, 452, 0, 453, 454, 455, 456, 144, 0, + 0, 0, 457, 458, 459, 460, 0, 461, 462, 0, + 463, 464, 465, 466, 467, 468, 0, 0, 469, 0, + 0, 0, 0, 0, 0, 0, 0, 470, 471, 472, + 473, 474, 475, 155, 156, 476, 0, 477, 0, 478, + 479, 480, 481, 482, 0, 483, 484, 485, 0, 0, + 486, 487, 488, 489, 490, 0, 491, 492, 493, 0, + 494, 495, 0, 496, 497, 498, 499, 164, 500, 501, + 502, 166, 0, 503, 0, 504, 168, 505, 0, 506, + 0, 507, 0, 0, 0, 508, 509, 510, 0, 511, + 172, 0, 512, 0, 513, 514, 515, 516, 517, 0, + 518, 519, 520, 0, 521, 522, 523, 524, 525, 526, + 0, 527, 0, 175, 0, 528, 529, 530, 0, 176, + 0, 177, 0, 531, 0, 0, 532, 0, 533, 534, + 535, 536, 537, 538, 539, 0, 540, 181, 0, 541, + 0, 0, 542, 543, 544, 0, 0, 545, 546, 547, + 548, 549, 550, 551, 552, 553, 554, 555, 556, 188, + 0, 190, 557, 558, 191, 0, 559, 560, 0, 561, + 0, 194, 562, 195, 563, 564, 565, 0, 566, 0, + 0, 567, 568, 569, 0, 0, 196, 0, 0, 0, + 200, 570, 571, 572, 573, 574, 575, 576, 0, 577, + 201, 578, 202, 579, 580, 581, 0, 582, 583, 584, + 585, 586, 587, 588, 204, 589, 590, 591, 592, 0, + 593, 594, 595, 596, 597, 598, 599, 600, 601, 602, + 0, 603, 604, 0, 605, 606, 212, 607, 608, 609, + 610, 611, 612, 613, 614, 0, 615, 616, 617, 618, + 619, 0, 620, 217, 621, 622, 0, 623, 220, 624, + 0, 625, 626, 627, 628, 629, 630, 631, 632, 633, + 634, 222, 0, 635, 636, 0, 637, 638, 639, 640, + 641, 642, 0, 224, 225, 0, 0, 644, 226, 645, + 227, 0, 646, 647, 648, 649, 650, 651, 652, 0, + 0, 653, 654, 655, 656, 657, 0, 0, 658, 659, + 660, 661, 662, 663, 234, 0, 664, 0, 665, 666, + 667, 0, 0, 668, 0, 0, 669, 670, 671, 672, + 673, 237, 238, 239, 240, 241, 242, 243, 244, 245, + 674, 675, 676, 86, 87, 88, 412, 90, 91, 92, + 413, 0, 414, 95, 0, 0, 98, 99, 100, 101, + 102, 103, 0, 104, 105, 415, 0, 0, 107, 108, + 109, 110, 0, 0, 112, 113, 114, 115, 0, 116, + 0, 0, 416, 417, 0, 0, 0, 418, 419, 0, + 0, 0, 0, 420, 0, 0, 0, 0, 0, 0, + 0, 0, 421, 0, 422, 0, 423, 424, 35, 425, + 0, 0, 0, 0, 0, 0, 41, 42, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 426, 427, + 428, 429, 430, 431, 432, 433, 0, 434, 435, 436, + 0, 0, 0, 0, 0, 0, 0, 437, 438, 0, + 439, 440, 0, 441, 442, 443, 135, 136, 0, 138, + 139, 0, 444, 445, 446, 447, 448, 0, 0, 449, + 450, 451, 140, 452, 0, 453, 454, 455, 456, 144, + 0, 0, 0, 457, 458, 459, 460, 0, 461, 462, + 0, 463, 464, 465, 466, 467, 468, 0, 0, 469, + 0, 0, 0, 0, 0, 0, 0, 0, 470, 471, + 472, 473, 474, 475, 155, 156, 476, 0, 477, 0, + 478, 479, 480, 481, 482, 0, 483, 484, 485, 0, + 0, 486, 487, 488, 489, 490, 0, 491, 492, 493, + 0, 494, 495, 0, 496, 497, 498, 499, 164, 500, + 501, 502, 166, 0, 503, 0, 504, 168, 505, 0, + 506, 0, 507, 0, 0, 0, 508, 509, 510, 0, + 511, 172, 0, 512, 0, 513, 514, 515, 516, 517, + 0, 518, 519, 520, 0, 521, 522, 523, 524, 525, + 526, 0, 527, 0, 175, 0, 528, 529, 530, 0, + 176, 0, 177, 0, 531, 0, 0, 532, 0, 533, + 534, 535, 536, 537, 538, 539, 0, 540, 181, 0, + 541, 0, 0, 542, 543, 544, 0, 0, 545, 546, + 547, 548, 549, 550, 551, 552, 553, 554, 555, 556, + 188, 0, 190, 557, 558, 191, 0, 559, 560, 0, + 561, 0, 194, 562, 195, 563, 564, 565, 0, 566, + 0, 0, 567, 568, 569, 0, 0, 196, 0, 0, + 0, 200, 570, 571, 572, 573, 574, 575, 576, 0, + 577, 201, 578, 202, 579, 580, 581, 0, 582, 583, + 584, 585, 586, 587, 588, 204, 589, 590, 591, 592, + 0, 593, 594, 595, 596, 597, 598, 599, 600, 601, + 602, 0, 603, 604, 0, 605, 606, 212, 607, 608, + 609, 610, 611, 612, 613, 614, 0, 615, 616, 617, + 618, 619, 0, 620, 217, 621, 622, 0, 623, 220, + 624, 0, 625, 626, 627, 907, 629, 630, 631, 632, + 633, 634, 222, 0, 635, 636, 0, 637, 638, 639, + 640, 641, 642, 0, 224, 225, 0, 0, 644, 226, + 645, 227, 0, 646, 647, 648, 649, 650, 651, 652, + 0, 0, 653, 654, 655, 656, 657, 0, 0, 658, + 659, 660, 661, 662, 663, 234, 0, 664, 0, 665, + 666, 667, 0, 0, 668, 0, 0, 669, 670, 671, + 672, 673, 237, 238, 239, 240, 241, 242, 243, 244, + 245, 674, 675, 676, 86, 87, 88, 412, 90, 91, + 92, 413, 0, 414, 95, 0, 0, 98, 99, 100, + 101, 102, 103, 0, 104, 105, 415, 0, 0, 107, + 108, 109, 110, 0, 0, 112, 113, 114, 115, 0, + 116, 0, 0, 416, 417, 0, 0, 0, 418, 419, + 0, 0, 0, 0, 420, 0, 0, 0, 0, 0, + 0, 0, 0, 421, 0, 422, 0, 423, 424, 35, + 425, 0, 0, 0, 0, 0, 0, 41, 42, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 426, + 427, 428, 429, 430, 431, 432, 433, 0, 434, 435, + 436, 0, 0, 0, 0, 0, 0, 0, 437, 438, + 0, 439, 440, 0, 441, 442, 443, 135, 136, 0, + 138, 139, 0, 444, 445, 446, 447, 448, 0, 0, + 449, 450, 451, 140, 452, 0, 453, 454, 455, 456, + 144, 0, 0, 0, 457, 458, 459, 460, 0, 461, + 462, 0, 463, 464, 465, 466, 467, 468, 0, 0, + 469, 0, 0, 0, 0, 0, 0, 0, 0, 470, + 471, 472, 473, 474, 475, 155, 156, 476, 0, 477, + 0, 478, 479, 480, 481, 482, 0, 483, 484, 485, + 0, 0, 486, 487, 488, 489, 490, 0, 491, 492, + 493, 0, 494, 495, 0, 496, 497, 498, 499, 164, + 500, 501, 502, 166, 0, 503, 0, 504, 168, 505, + 0, 506, 0, 507, 0, 0, 0, 508, 509, 510, + 0, 511, 172, 0, 512, 0, 513, 514, 515, 516, + 517, 0, 949, 519, 520, 0, 521, 522, 523, 524, + 525, 526, 0, 527, 0, 175, 0, 528, 529, 530, + 0, 176, 0, 177, 0, 531, 0, 0, 532, 0, + 533, 534, 535, 536, 537, 538, 539, 0, 540, 181, + 0, 541, 0, 0, 542, 543, 544, 0, 0, 545, + 546, 547, 548, 549, 550, 551, 552, 553, 554, 555, + 556, 188, 0, 190, 557, 558, 191, 0, 559, 560, + 0, 561, 0, 194, 562, 195, 563, 564, 565, 0, + 566, 0, 0, 567, 568, 569, 0, 0, 196, 0, + 0, 0, 200, 570, 571, 572, 573, 574, 575, 576, + 0, 577, 201, 578, 202, 579, 580, 581, 0, 582, + 583, 584, 585, 586, 587, 588, 204, 589, 590, 591, + 592, 0, 593, 594, 595, 596, 597, 598, 599, 600, + 601, 602, 0, 603, 604, 0, 605, 606, 212, 607, + 608, 609, 610, 611, 612, 613, 614, 0, 615, 616, + 617, 618, 619, 0, 620, 217, 621, 622, 0, 623, + 220, 624, 0, 625, 626, 627, 628, 629, 630, 631, + 632, 633, 634, 222, 0, 635, 636, 0, 637, 638, + 639, 640, 641, 642, 0, 224, 225, 0, 0, 644, + 226, 645, 227, 0, 646, 647, 648, 649, 650, 651, + 652, 0, 0, 653, 654, 655, 656, 657, 0, 0, + 658, 659, 660, 661, 662, 663, 234, 0, 664, 0, + 665, 666, 667, 0, 0, 668, 0, 0, 669, 670, + 671, 672, 673, 237, 238, 239, 240, 241, 242, 243, + 244, 245, 674, 675, 676, 86, 87, 88, 412, 90, + 91, 92, 413, 0, 414, 95, 0, 0, 98, 99, + 100, 101, 102, 103, 0, 104, 105, 415, 0, 0, + 107, 108, 109, 110, 0, 0, 112, 113, 114, 115, + 0, 116, 0, 0, 416, 417, 0, 0, 0, 418, + 419, 0, 0, 0, 0, 420, 0, 0, 0, 0, + 0, 0, 0, 0, 421, 0, 422, 0, 423, 424, + 35, 425, 0, 0, 0, 0, 0, 0, 41, 42, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 426, 427, 428, 429, 430, 431, 432, 433, 0, 434, + 435, 436, 0, 0, 0, 0, 0, 0, 0, 437, + 438, 0, 439, 440, 0, 441, 442, 443, 135, 136, + 0, 138, 139, 0, 444, 445, 446, 447, 448, 0, + 0, 449, 450, 451, 140, 452, 0, 453, 454, 455, + 456, 144, 0, 0, 0, 457, 458, 459, 460, 0, + 461, 462, 0, 463, 464, 465, 466, 467, 468, 0, + 0, 469, 0, 0, 0, 0, 0, 0, 0, 0, + 470, 471, 472, 473, 474, 475, 155, 156, 476, 0, + 477, 0, 478, 479, 480, 481, 482, 0, 483, 484, + 485, 0, 0, 486, 487, 488, 489, 490, 0, 491, + 492, 493, 0, 494, 495, 0, 496, 497, 498, 499, + 164, 500, 501, 502, 166, 0, 503, 0, 504, 168, + 505, 0, 506, 0, 507, 0, 0, 0, 508, 509, + 510, 0, 511, 172, 0, 512, 0, 513, 514, 515, + 516, 517, 0, 518, 519, 520, 0, 521, 522, 523, + 524, 525, 526, 0, 527, 0, 175, 0, 528, 529, + 530, 0, 176, 0, 177, 0, 531, 0, 0, 532, + 0, 533, 534, 535, 536, 537, 538, 539, 0, 540, + 181, 0, 541, 0, 0, 542, 543, 544, 0, 0, + 545, 546, 547, 548, 549, 550, 551, 552, 553, 554, + 555, 556, 188, 0, 190, 557, 558, 191, 0, 559, + 560, 0, 561, 0, 194, 562, 195, 563, 564, 565, + 0, 566, 0, 0, 567, 568, 569, 0, 0, 196, + 0, 0, 0, 200, 570, 571, 572, 573, 574, 575, + 576, 0, 577, 201, 578, 202, 579, 580, 581, 0, + 582, 583, 584, 585, 586, 587, 588, 204, 589, 590, + 591, 592, 0, 593, 594, 595, 596, 597, 598, 599, + 600, 601, 602, 0, 603, 604, 0, 605, 606, 212, + 607, 608, 609, 610, 611, 612, 613, 614, 0, 615, + 616, 617, 618, 619, 0, 620, 217, 621, 622, 0, + 623, 220, 624, 0, 625, 626, 627, 628, 629, 630, + 631, 632, 633, 634, 222, 0, 635, 636, 0, 637, + 638, 639, 640, 641, 642, 0, 224, 225, 0, 0, + 1002, 226, 645, 227, 0, 646, 647, 648, 649, 650, + 651, 652, 0, 0, 653, 654, 655, 656, 657, 0, + 0, 658, 659, 660, 661, 662, 663, 234, 0, 664, + 0, 665, 666, 667, 0, 0, 668, 0, 0, 669, + 670, 671, 672, 673, 237, 238, 239, 240, 241, 242, + 243, 244, 245, 674, 675, 676, 86, 87, 88, 412, + 90, 91, 92, 413, 0, 414, 95, 0, 0, 98, + 99, 100, 101, 102, 103, 0, 104, 105, 415, 0, + 0, 107, 108, 109, 110, 0, 0, 112, 113, 114, + 115, 0, 116, 0, 0, 416, 417, 0, 0, 0, + 418, 419, 0, 0, 0, 0, 420, 0, 0, 0, + 0, 0, 0, 0, 0, 421, 0, 422, 0, 423, + 424, 35, 0, 0, 0, 0, 0, 0, 0, 41, + 42, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 426, 427, 428, 429, 430, 431, 432, 433, 0, + 434, 435, 436, 0, 0, 0, 0, 0, 0, 0, + 437, 438, 0, 439, 440, 0, 441, 442, 443, 135, + 136, 0, 138, 139, 0, 444, 445, 446, 447, 448, + 0, 0, 449, 450, 451, 140, 452, 0, 453, 454, + 455, 456, 144, 0, 0, 0, 457, 458, 459, 460, + 0, 461, 462, 0, 463, 464, 465, 466, 467, 468, + 0, 0, 469, 0, 0, 0, 0, 0, 0, 0, + 0, 470, 471, 472, 473, 474, 475, 155, 156, 476, + 0, 477, 0, 478, 479, 480, 481, 482, 0, 483, + 484, 485, 0, 0, 486, 487, 488, 489, 490, 0, + 491, 492, 493, 0, 494, 495, 0, 496, 497, 498, + 499, 164, 500, 501, 502, 166, 0, 503, 0, 504, + 168, 505, 0, 506, 0, 507, 0, 0, 0, 508, + 509, 510, 0, 511, 172, 0, 512, 0, 513, 514, + 515, 516, 517, 0, 518, 519, 520, 0, 521, 522, + 523, 524, 525, 526, 0, 527, 0, 175, 0, 528, + 529, 530, 0, 176, 0, 177, 0, 531, 0, 0, + 532, 0, 533, 534, 535, 536, 537, 538, 539, 0, + 540, 181, 0, 541, 0, 0, 542, 543, 544, 0, + 0, 545, 546, 547, 548, 549, 550, 551, 552, 553, + 554, 555, 556, 188, 0, 190, 557, 558, 191, 0, + 559, 560, 0, 561, 0, 194, 562, 195, 563, 564, + 565, 0, 566, 0, 1059, 567, 568, 569, 0, 0, + 196, 0, 0, 0, 200, 570, 571, 572, 573, 574, + 575, 576, 0, 577, 201, 578, 202, 579, 580, 581, + 0, 582, 583, 584, 585, 586, 587, 588, 204, 589, + 590, 591, 592, 0, 593, 594, 595, 596, 597, 598, + 599, 600, 601, 602, 0, 603, 604, 0, 605, 606, + 212, 607, 608, 609, 610, 611, 612, 613, 614, 0, + 615, 616, 617, 618, 619, 0, 620, 217, 621, 622, + 0, 623, 220, 624, 0, 625, 626, 627, 628, 629, + 630, 631, 632, 633, 634, 222, 0, 635, 636, 0, + 637, 638, 639, 640, 641, 642, 0, 224, 225, 0, + 0, 644, 226, 645, 227, 0, 646, 647, 648, 649, + 650, 651, 652, 0, 0, 653, 654, 655, 656, 657, + 0, 0, 658, 659, 660, 661, 662, 663, 234, 0, + 664, 0, 665, 666, 667, 0, 0, 668, 0, 0, + 669, 670, 671, 672, 673, 237, 238, 239, 240, 241, + 242, 243, 244, 245, 674, 675, 676, 86, 87, 88, + 412, 90, 91, 92, 413, 0, 414, 95, 0, 0, + 98, 99, 100, 101, 102, 103, 0, 104, 105, 415, + 0, 0, 107, 108, 109, 110, 0, 0, 112, 113, + 114, 115, 0, 116, 0, 0, 416, 417, 0, 0, + 0, 418, 419, 0, 0, 0, 0, 420, 0, 0, + 0, 0, 0, 0, 0, 0, 421, 0, 422, 0, + 423, 424, 35, 0, 0, 0, 0, 0, 0, 0, + 41, 42, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 426, 427, 428, 429, 430, 431, 432, 433, + 0, 434, 435, 436, 0, 0, 0, 0, 0, 0, + 0, 437, 438, 0, 439, 440, 0, 441, 442, 443, + 135, 136, 0, 138, 139, 0, 444, 445, 446, 447, + 448, 0, 0, 449, 450, 451, 140, 452, 0, 453, + 454, 455, 456, 144, 0, 0, 0, 457, 458, 459, + 460, 0, 461, 462, 0, 463, 464, 465, 466, 467, + 468, 0, 0, 469, 0, 0, 0, 0, 0, 0, + 0, 0, 470, 471, 472, 473, 474, 475, 155, 156, + 476, 0, 477, 0, 478, 479, 480, 481, 482, 0, + 483, 484, 485, 0, 0, 486, 487, 488, 489, 490, + 0, 491, 492, 493, 0, 494, 495, 0, 496, 497, + 498, 499, 164, 500, 501, 502, 166, 0, 503, 0, + 504, 168, 505, 0, 506, 0, 507, 0, 0, 0, + 508, 509, 510, 0, 511, 172, 0, 512, 0, 513, + 514, 515, 516, 1202, 0, 518, 519, 520, 0, 521, + 522, 523, 524, 525, 526, 0, 527, 0, 175, 0, + 528, 529, 530, 0, 176, 0, 177, 0, 531, 0, + 0, 532, 0, 533, 534, 535, 536, 537, 538, 539, + 0, 540, 181, 0, 541, 0, 0, 542, 543, 544, + 0, 0, 545, 546, 547, 548, 549, 550, 551, 552, + 553, 554, 555, 556, 188, 0, 190, 557, 558, 191, + 0, 559, 560, 0, 561, 0, 194, 562, 195, 563, + 564, 565, 0, 566, 0, 1059, 567, 568, 569, 0, + 0, 196, 0, 0, 0, 200, 570, 571, 572, 573, + 574, 575, 576, 0, 577, 201, 578, 202, 579, 580, + 581, 0, 582, 583, 584, 585, 586, 587, 588, 204, + 589, 590, 591, 592, 0, 593, 594, 595, 596, 597, + 598, 599, 600, 601, 602, 0, 603, 604, 0, 605, + 606, 212, 607, 608, 609, 610, 611, 612, 613, 614, + 0, 615, 616, 617, 618, 619, 0, 620, 217, 621, + 622, 0, 623, 220, 624, 0, 625, 626, 627, 628, + 629, 630, 631, 632, 633, 634, 222, 0, 635, 636, + 0, 637, 638, 639, 640, 641, 642, 0, 224, 225, + 0, 0, 644, 226, 645, 227, 0, 646, 647, 648, + 649, 650, 651, 652, 0, 0, 653, 654, 655, 656, + 657, 0, 0, 658, 659, 660, 661, 662, 663, 234, + 0, 664, 0, 665, 666, 667, 0, 0, 668, 0, + 0, 669, 670, 671, 672, 673, 237, 238, 239, 240, + 241, 242, 243, 244, 245, 674, 675, 676, 86, 87, + 88, 412, 90, 91, 92, 413, 0, 414, 95, 0, + 0, 98, 99, 100, 101, 102, 103, 0, 104, 105, + 415, 0, 0, 107, 108, 109, 110, 0, 0, 112, + 113, 114, 115, 0, 116, 0, 0, 416, 417, 0, + 0, 0, 418, 419, 0, 0, 0, 0, 420, 0, + 0, 0, 0, 0, 0, 0, 0, 421, 0, 422, + 0, 423, 424, 35, 0, 0, 0, 0, 0, 0, + 0, 41, 42, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 426, 427, 428, 429, 430, 431, 432, + 433, 1543, 434, 435, 436, 0, 0, 0, 0, 0, + 0, 0, 437, 438, 0, 439, 440, 0, 441, 442, + 443, 135, 136, 0, 138, 139, 0, 444, 445, 446, + 447, 448, 0, 0, 449, 450, 451, 140, 452, 0, + 453, 454, 455, 456, 144, 0, 0, 0, 457, 458, + 459, 460, 0, 461, 462, 0, 463, 464, 465, 466, + 467, 468, 0, 0, 469, 0, 0, 0, 0, 0, + 0, 0, 0, 470, 471, 472, 473, 474, 475, 155, + 156, 476, 0, 477, 0, 478, 479, 480, 481, 482, + 0, 483, 484, 485, 0, 0, 486, 487, 488, 489, + 490, 0, 491, 492, 493, 0, 494, 495, 0, 496, + 497, 498, 499, 164, 500, 501, 502, 166, 0, 503, + 0, 504, 168, 505, 0, 506, 0, 507, 0, 0, + 0, 508, 509, 510, 0, 511, 172, 0, 512, 0, + 513, 514, 515, 516, 517, 0, 518, 519, 520, 0, + 521, 522, 523, 524, 525, 526, 0, 527, 0, 175, + 0, 528, 529, 530, 0, 176, 0, 177, 0, 531, + 0, 0, 532, 0, 533, 534, 535, 536, 537, 538, + 539, 0, 540, 181, 0, 541, 0, 0, 542, 543, + 544, 0, 0, 545, 546, 547, 548, 549, 550, 551, + 552, 553, 554, 555, 556, 188, 0, 190, 557, 558, + 191, 0, 559, 560, 0, 561, 0, 194, 562, 195, + 563, 564, 565, 0, 566, 0, 0, 567, 568, 569, + 0, 0, 196, 0, 0, 0, 200, 570, 571, 572, + 573, 574, 575, 576, 0, 577, 201, 578, 202, 579, + 580, 581, 0, 582, 583, 584, 585, 586, 587, 588, + 204, 589, 590, 591, 592, 0, 593, 594, 595, 596, + 597, 598, 599, 600, 601, 602, 0, 603, 604, 0, + 605, 606, 212, 607, 608, 609, 610, 611, 612, 613, + 614, 0, 615, 616, 617, 618, 619, 0, 620, 217, + 621, 622, 0, 623, 220, 624, 0, 625, 626, 627, + 628, 629, 630, 631, 632, 633, 634, 222, 0, 635, + 636, 0, 637, 638, 639, 640, 641, 642, 0, 224, + 225, 0, 0, 644, 226, 645, 227, 0, 646, 647, + 648, 649, 650, 651, 652, 0, 0, 653, 654, 655, + 656, 657, 0, 0, 658, 659, 660, 661, 662, 663, + 234, 0, 664, 0, 665, 666, 667, 0, 0, 668, + 0, 0, 669, 670, 671, 672, 673, 237, 238, 239, + 240, 241, 242, 243, 244, 245, 674, 675, 676, 86, + 87, 88, 412, 90, 91, 92, 413, 0, 414, 95, + 0, 0, 98, 99, 100, 101, 102, 103, 0, 104, + 105, 415, 0, 0, 107, 108, 109, 110, 0, 0, + 112, 113, 114, 115, 0, 116, 0, 0, 416, 417, + 0, 0, 0, 418, 419, 0, 0, 0, 0, 420, + 0, 0, 0, 0, 0, 0, 0, 0, 421, 0, + 422, 0, 423, 424, 35, 0, 0, 0, 0, 0, + 0, 0, 41, 42, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 426, 427, 428, 429, 430, 431, + 432, 433, 0, 434, 435, 436, 0, 0, 0, 0, + 0, 0, 0, 437, 438, 0, 439, 440, 0, 441, + 442, 443, 135, 136, 0, 138, 139, 0, 444, 445, + 446, 447, 448, 0, 0, 449, 450, 451, 140, 452, + 0, 453, 454, 455, 456, 144, 0, 0, 0, 457, + 458, 459, 460, 0, 461, 462, 0, 463, 464, 465, + 466, 467, 468, 0, 0, 469, 0, 0, 0, 0, + 0, 0, 0, 0, 470, 471, 472, 473, 474, 475, + 155, 156, 476, 0, 477, 0, 478, 479, 480, 481, + 482, 0, 483, 484, 485, 0, 0, 486, 487, 488, + 489, 490, 0, 491, 492, 493, 0, 494, 495, 0, + 496, 497, 498, 499, 164, 500, 501, 502, 166, 0, + 503, 0, 504, 168, 505, 0, 506, 0, 507, 0, + 0, 0, 508, 509, 510, 0, 511, 172, 0, 512, + 0, 513, 514, 515, 516, 1715, 0, 518, 519, 520, + 0, 521, 522, 523, 524, 525, 526, 0, 527, 0, + 175, 0, 528, 529, 530, 0, 176, 0, 177, 0, + 531, 0, 0, 532, 0, 533, 534, 535, 536, 537, + 538, 539, 0, 540, 181, 0, 541, 0, 0, 542, + 543, 544, 0, 0, 545, 546, 547, 548, 549, 550, + 551, 552, 553, 554, 555, 556, 188, 0, 190, 557, + 558, 191, 0, 559, 560, 0, 561, 0, 194, 562, + 195, 563, 564, 565, 0, 566, 0, 1059, 567, 568, + 569, 0, 0, 196, 0, 0, 0, 200, 570, 571, + 572, 573, 574, 575, 576, 0, 577, 201, 578, 202, + 579, 580, 581, 0, 582, 583, 584, 585, 586, 587, + 588, 204, 589, 590, 591, 592, 0, 593, 594, 595, + 596, 597, 598, 599, 600, 601, 602, 0, 603, 604, + 0, 605, 606, 212, 607, 608, 609, 610, 611, 612, + 613, 614, 0, 615, 616, 617, 618, 619, 0, 620, + 217, 621, 622, 0, 623, 220, 624, 0, 625, 626, + 627, 628, 629, 630, 631, 632, 633, 634, 222, 0, + 635, 636, 0, 637, 638, 639, 640, 641, 642, 0, + 224, 225, 0, 0, 644, 226, 645, 227, 0, 646, + 647, 648, 649, 650, 651, 652, 0, 0, 653, 654, + 655, 656, 657, 0, 0, 658, 659, 660, 661, 662, + 663, 234, 0, 664, 0, 665, 666, 667, 0, 0, + 668, 0, 0, 669, 670, 671, 672, 673, 237, 238, + 239, 240, 241, 242, 243, 244, 245, 674, 675, 676, + 86, 87, 88, 412, 90, 91, 92, 413, 0, 414, + 95, 0, 0, 98, 99, 100, 101, 102, 103, 0, + 104, 105, 415, 0, 0, 107, 108, 109, 110, 0, + 0, 112, 113, 114, 115, 0, 116, 0, 0, 416, + 417, 0, 0, 0, 418, 419, 0, 0, 0, 0, + 420, 0, 0, 0, 0, 0, 0, 0, 0, 421, + 0, 422, 0, 423, 424, 35, 0, 0, 1940, 0, + 0, 0, 0, 41, 42, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 426, 427, 428, 429, 430, + 431, 432, 433, 0, 434, 435, 436, 0, 0, 0, + 0, 0, 0, 0, 437, 438, 0, 439, 440, 0, + 441, 442, 443, 135, 136, 0, 138, 139, 0, 444, + 445, 446, 447, 448, 0, 0, 449, 450, 451, 140, + 452, 0, 453, 454, 455, 456, 144, 0, 0, 0, + 457, 458, 459, 460, 0, 461, 462, 0, 463, 464, + 465, 466, 467, 468, 0, 0, 469, 0, 0, 0, + 0, 0, 0, 0, 0, 470, 471, 472, 473, 474, + 475, 155, 156, 476, 0, 477, 0, 478, 479, 480, + 481, 482, 0, 483, 484, 485, 0, 0, 486, 487, + 488, 489, 490, 0, 491, 492, 493, 0, 494, 495, + 0, 496, 497, 498, 499, 164, 500, 501, 502, 166, + 0, 503, 0, 504, 168, 505, 0, 506, 0, 507, + 0, 0, 0, 508, 509, 510, 0, 511, 172, 0, + 512, 0, 513, 514, 515, 516, 517, 0, 518, 519, + 520, 0, 521, 522, 523, 524, 525, 526, 0, 527, + 0, 175, 0, 528, 529, 530, 0, 176, 0, 177, + 0, 531, 0, 0, 532, 0, 533, 534, 535, 536, + 537, 538, 539, 0, 540, 181, 0, 541, 0, 0, + 542, 543, 544, 0, 0, 545, 546, 547, 548, 549, + 550, 551, 552, 553, 554, 555, 556, 188, 0, 190, + 557, 558, 191, 0, 559, 560, 0, 561, 0, 194, + 562, 195, 563, 564, 565, 0, 566, 0, 0, 567, + 568, 569, 0, 0, 196, 0, 0, 0, 200, 570, + 571, 572, 573, 574, 575, 576, 0, 577, 201, 578, + 202, 579, 580, 581, 0, 582, 583, 584, 585, 586, + 587, 588, 204, 589, 590, 591, 592, 0, 593, 594, + 595, 596, 597, 598, 599, 600, 601, 602, 0, 603, + 604, 0, 605, 606, 212, 607, 608, 609, 610, 611, + 612, 613, 614, 0, 615, 616, 617, 618, 619, 0, + 620, 217, 621, 622, 0, 623, 220, 624, 0, 625, + 626, 627, 628, 629, 630, 631, 632, 633, 634, 222, + 0, 635, 636, 0, 637, 638, 639, 640, 641, 642, + 0, 224, 225, 0, 0, 644, 226, 645, 227, 0, + 646, 647, 648, 649, 650, 651, 652, 0, 0, 653, + 654, 655, 656, 657, 0, 0, 658, 659, 660, 661, + 662, 663, 234, 0, 664, 0, 665, 666, 667, 0, + 0, 668, 0, 0, 669, 670, 671, 672, 673, 237, + 238, 239, 240, 241, 242, 243, 244, 245, 674, 675, + 676, 86, 87, 88, 412, 90, 91, 92, 413, 2032, + 414, 95, 0, 0, 98, 99, 100, 101, 102, 103, + 0, 104, 105, 415, 0, 0, 107, 108, 109, 110, + 0, 0, 2317, 113, 114, 115, 0, 116, 0, 0, + 416, 417, 0, 0, 0, 418, 419, 0, 0, 0, + 0, 420, 0, 0, 0, 0, 0, 0, 0, 0, + 421, 0, 422, 0, 423, 424, 35, 0, 0, 0, + 0, 0, 0, 0, 41, 42, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 426, 427, 428, 429, + 430, 431, 432, 433, 0, 434, 435, 436, 0, 0, + 0, 0, 0, 0, 0, 437, 438, 0, 439, 440, + 0, 441, 442, 443, 135, 136, 0, 138, 139, 0, + 444, 445, 446, 447, 448, 0, 0, 449, 450, 451, + 140, 452, 0, 453, 454, 455, 456, 144, 0, 0, + 0, 457, 458, 459, 460, 0, 461, 462, 0, 463, + 464, 465, 466, 467, 468, 0, 0, 469, 0, 0, + 0, 0, 0, 0, 0, 0, 470, 471, 472, 473, + 474, 475, 155, 156, 476, 0, 477, 0, 478, 479, + 480, 481, 482, 0, 483, 484, 485, 0, 0, 486, + 487, 488, 489, 490, 0, 491, 492, 493, 0, 494, + 495, 0, 496, 497, 498, 499, 164, 500, 501, 502, + 166, 0, 503, 0, 504, 168, 505, 0, 506, 0, + 507, 0, 0, 0, 508, 509, 510, 0, 511, 172, + 0, 512, 0, 513, 514, 515, 516, 517, 0, 518, + 519, 520, 0, 521, 522, 523, 524, 525, 526, 0, + 527, 0, 175, 0, 528, 529, 530, 0, 176, 0, + 177, 0, 531, 0, 0, 532, 0, 533, 534, 535, + 536, 537, 538, 539, 0, 540, 181, 0, 541, 0, + 0, 542, 543, 544, 0, 0, 545, 546, 547, 548, + 549, 550, 551, 552, 553, 554, 555, 556, 188, 0, + 190, 557, 558, 191, 0, 559, 560, 0, 561, 0, + 194, 562, 195, 563, 564, 565, 0, 566, 0, 0, + 567, 568, 569, 0, 0, 196, 0, 0, 0, 200, + 570, 571, 572, 573, 574, 575, 576, 0, 577, 201, + 578, 202, 579, 580, 581, 0, 582, 583, 584, 585, + 586, 587, 588, 204, 589, 590, 591, 592, 0, 593, + 594, 595, 596, 597, 598, 599, 600, 601, 602, 0, + 603, 604, 0, 605, 606, 212, 607, 608, 609, 610, + 611, 612, 613, 614, 0, 615, 616, 617, 618, 619, + 0, 620, 217, 621, 622, 0, 623, 220, 624, 0, + 625, 626, 627, 628, 629, 630, 631, 632, 633, 634, + 222, 0, 635, 636, 0, 637, 638, 639, 640, 641, + 642, 0, 224, 225, 0, 0, 644, 226, 645, 227, + 0, 646, 647, 648, 649, 650, 651, 652, 0, 0, + 653, 654, 655, 656, 657, 0, 0, 658, 659, 660, + 661, 662, 663, 234, 0, 664, 0, 665, 666, 667, + 0, 0, 668, 0, 0, 669, 670, 671, 672, 673, + 237, 238, 239, 240, 241, 242, 243, 244, 245, 674, + 675, 676, 86, 87, 88, 412, 90, 91, 92, 413, + 0, 414, 95, 0, 0, 98, 99, 100, 101, 102, + 103, 0, 104, 105, 415, 0, 0, 107, 108, 109, + 110, 0, 0, 112, 113, 114, 115, 0, 116, 0, + 0, 416, 417, 0, 0, 0, 418, 419, 0, 0, + 0, 0, 420, 0, 0, 0, 0, 0, 0, 0, + 0, 421, 0, 422, 0, 423, 424, 35, 0, 0, + 0, 0, 0, 0, 0, 41, 42, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 426, 427, 428, + 429, 430, 431, 432, 433, 0, 434, 435, 436, 0, + 0, 0, 0, 0, 0, 0, 437, 438, 0, 439, + 440, 0, 441, 442, 443, 135, 136, 0, 138, 139, + 0, 444, 445, 446, 447, 448, 0, 0, 449, 450, + 451, 140, 452, 0, 453, 454, 455, 456, 144, 0, + 0, 0, 457, 458, 459, 460, 0, 461, 462, 0, + 463, 464, 465, 466, 467, 468, 0, 0, 469, 0, + 0, 0, 0, 0, 0, 0, 0, 470, 471, 472, + 473, 474, 475, 155, 156, 476, 0, 477, 0, 478, + 479, 480, 481, 482, 0, 483, 484, 485, 0, 0, + 486, 487, 488, 489, 490, 0, 491, 492, 493, 0, + 494, 495, 0, 496, 497, 498, 499, 164, 500, 501, + 502, 166, 0, 503, 0, 504, 168, 505, 0, 506, + 0, 507, 0, 0, 0, 508, 509, 510, 0, 511, + 172, 3375, 512, 0, 513, 514, 515, 516, 517, 0, + 518, 519, 520, 0, 521, 522, 523, 524, 525, 526, + 0, 527, 0, 175, 0, 528, 529, 530, 0, 176, + 0, 177, 0, 531, 0, 0, 532, 0, 533, 534, + 535, 536, 537, 538, 539, 0, 540, 181, 0, 541, + 0, 0, 542, 543, 544, 0, 0, 545, 546, 547, + 548, 549, 550, 551, 552, 553, 554, 555, 556, 188, + 0, 190, 557, 558, 191, 0, 559, 560, 0, 561, + 0, 194, 562, 195, 563, 564, 565, 0, 566, 0, + 0, 567, 568, 569, 0, 0, 196, 0, 0, 0, + 200, 570, 571, 572, 573, 574, 575, 576, 0, 577, + 201, 578, 202, 579, 580, 581, 0, 582, 583, 584, + 585, 586, 587, 588, 204, 589, 590, 591, 592, 0, + 593, 594, 595, 596, 597, 598, 599, 600, 601, 602, + 0, 603, 604, 0, 605, 606, 212, 607, 608, 609, + 610, 611, 612, 613, 614, 0, 615, 616, 617, 618, + 619, 0, 620, 217, 621, 622, 0, 623, 220, 624, + 0, 625, 626, 627, 628, 629, 630, 631, 632, 633, + 634, 222, 0, 635, 636, 0, 637, 638, 639, 640, + 641, 642, 0, 224, 225, 0, 0, 644, 226, 645, + 227, 0, 646, 647, 648, 649, 650, 651, 652, 0, + 0, 653, 654, 655, 656, 657, 0, 0, 658, 659, + 660, 661, 662, 663, 234, 0, 664, 0, 665, 666, + 667, 0, 0, 668, 0, 0, 669, 670, 671, 672, + 673, 237, 238, 239, 240, 241, 242, 243, 244, 245, + 674, 675, 676, 86, 87, 88, 412, 90, 91, 92, + 413, 0, 414, 95, 0, 0, 98, 99, 100, 101, + 102, 103, 0, 104, 105, 415, 0, 0, 107, 108, + 109, 110, 0, 0, 112, 113, 114, 115, 0, 116, + 0, 0, 416, 417, 0, 0, 0, 418, 419, 0, + 0, 0, 0, 420, 0, 0, 0, 0, 0, 0, + 0, 0, 421, 0, 422, 0, 423, 424, 35, 0, + 0, 0, 0, 0, 0, 0, 41, 42, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 426, 427, + 428, 429, 430, 431, 432, 433, 0, 434, 435, 436, + 0, 0, 0, 0, 0, 4008, 0, 437, 438, 0, + 439, 440, 0, 441, 442, 443, 135, 136, 0, 138, + 139, 0, 444, 445, 446, 447, 448, 0, 0, 449, + 450, 451, 140, 452, 0, 453, 454, 455, 456, 144, + 0, 0, 0, 457, 458, 459, 460, 0, 461, 462, + 0, 463, 464, 465, 466, 467, 468, 0, 0, 469, + 0, 0, 0, 0, 0, 0, 0, 0, 470, 471, + 472, 473, 474, 475, 155, 156, 476, 0, 477, 0, + 478, 479, 480, 481, 482, 0, 483, 484, 485, 0, + 0, 486, 487, 488, 489, 490, 0, 491, 492, 493, + 0, 494, 495, 0, 496, 497, 498, 499, 164, 500, + 501, 502, 166, 0, 503, 0, 504, 168, 505, 0, + 506, 0, 507, 0, 0, 0, 508, 509, 510, 0, + 511, 172, 0, 512, 0, 513, 514, 515, 516, 517, + 0, 518, 519, 520, 0, 521, 522, 523, 524, 525, + 526, 0, 527, 0, 175, 0, 528, 529, 530, 0, + 176, 0, 177, 0, 531, 0, 0, 532, 0, 533, + 534, 535, 536, 537, 538, 539, 0, 540, 181, 0, + 541, 0, 0, 542, 543, 544, 0, 0, 545, 546, + 547, 548, 549, 550, 551, 552, 553, 554, 555, 556, + 188, 0, 190, 557, 558, 191, 0, 559, 560, 0, + 561, 0, 194, 562, 195, 563, 564, 565, 0, 566, + 0, 0, 567, 568, 569, 0, 0, 196, 0, 0, + 0, 200, 570, 571, 572, 573, 574, 575, 576, 0, + 577, 201, 578, 202, 579, 580, 581, 0, 582, 583, + 584, 585, 586, 587, 588, 204, 589, 590, 591, 592, + 0, 593, 594, 595, 596, 597, 598, 599, 600, 601, + 602, 0, 603, 604, 0, 605, 606, 212, 607, 608, + 609, 610, 611, 612, 613, 614, 0, 615, 616, 617, + 618, 619, 0, 620, 217, 621, 622, 0, 623, 220, + 624, 0, 625, 626, 627, 628, 629, 630, 631, 632, + 633, 634, 222, 0, 635, 636, 0, 637, 638, 639, + 640, 641, 642, 0, 224, 225, 0, 0, 644, 226, + 645, 227, 0, 646, 647, 648, 649, 650, 651, 652, + 0, 0, 653, 654, 655, 656, 657, 0, 0, 658, + 659, 660, 661, 662, 663, 234, 0, 664, 0, 665, + 666, 667, 0, 0, 668, 0, 0, 669, 670, 671, + 672, 673, 237, 238, 239, 240, 241, 242, 243, 244, + 245, 674, 675, 676, 86, 87, 88, 412, 90, 91, + 92, 413, 0, 414, 95, 0, 0, 98, 99, 100, + 101, 102, 103, 0, 104, 105, 415, 0, 0, 107, + 108, 109, 110, 0, 0, 112, 113, 114, 115, 0, + 116, 0, 0, 416, 417, 0, 0, 0, 418, 419, + 0, 0, 0, 0, 420, 0, 0, 0, 0, 0, + 0, 0, 0, 421, 0, 422, 0, 423, 424, 35, + 0, 0, 0, 0, 0, 0, 0, 41, 42, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 426, + 427, 428, 429, 430, 431, 432, 433, 0, 434, 435, + 436, 0, 0, 0, 0, 0, 4021, 0, 437, 438, + 0, 439, 440, 0, 441, 442, 443, 135, 136, 0, + 138, 139, 0, 444, 445, 446, 447, 448, 0, 0, + 449, 450, 451, 140, 452, 0, 453, 454, 455, 456, + 144, 0, 0, 0, 457, 458, 459, 460, 0, 461, + 462, 0, 463, 464, 465, 466, 467, 468, 0, 0, + 469, 0, 0, 0, 0, 0, 0, 0, 0, 470, + 471, 472, 473, 474, 475, 155, 156, 476, 0, 477, + 0, 478, 479, 480, 481, 482, 0, 483, 484, 485, + 0, 0, 486, 487, 488, 489, 490, 0, 491, 492, + 493, 0, 494, 495, 0, 496, 497, 498, 499, 164, + 500, 501, 502, 166, 0, 503, 0, 504, 168, 505, + 0, 506, 0, 507, 0, 0, 0, 508, 509, 510, + 0, 511, 172, 0, 512, 0, 513, 514, 515, 516, + 517, 0, 518, 519, 520, 0, 521, 522, 523, 524, + 525, 526, 0, 527, 0, 175, 0, 528, 529, 530, + 0, 176, 0, 177, 0, 531, 0, 0, 532, 0, + 533, 534, 535, 536, 537, 538, 539, 0, 540, 181, + 0, 541, 0, 0, 542, 543, 544, 0, 0, 545, + 546, 547, 548, 549, 550, 551, 552, 553, 554, 555, + 556, 188, 0, 190, 557, 558, 191, 0, 559, 560, + 0, 561, 0, 194, 562, 195, 563, 564, 565, 0, + 566, 0, 0, 567, 568, 569, 0, 0, 196, 0, + 0, 0, 200, 570, 571, 572, 573, 574, 575, 576, + 0, 577, 201, 578, 202, 579, 580, 581, 0, 582, + 583, 584, 585, 586, 587, 588, 204, 589, 590, 591, + 592, 0, 593, 594, 595, 596, 597, 598, 599, 600, + 601, 602, 0, 603, 604, 0, 605, 606, 212, 607, + 608, 609, 610, 611, 612, 613, 614, 0, 615, 616, + 617, 618, 619, 0, 620, 217, 621, 622, 0, 623, + 220, 624, 0, 625, 626, 627, 628, 629, 630, 631, + 632, 633, 634, 222, 0, 635, 636, 0, 637, 638, + 639, 640, 641, 642, 0, 224, 225, 0, 0, 644, + 226, 645, 227, 0, 646, 647, 648, 649, 650, 651, + 652, 0, 0, 653, 654, 655, 656, 657, 0, 0, + 658, 659, 660, 661, 662, 663, 234, 0, 664, 0, + 665, 666, 667, 0, 0, 668, 0, 0, 669, 670, + 671, 672, 673, 237, 238, 239, 240, 241, 242, 243, + 244, 245, 674, 675, 676, 86, 87, 88, 412, 90, + 91, 92, 413, 0, 414, 95, 0, 0, 98, 99, + 100, 101, 102, 103, 0, 104, 105, 415, 0, 0, + 107, 108, 109, 110, 0, 0, 112, 113, 114, 115, + 0, 116, 0, 0, 416, 417, 0, 0, 0, 418, + 419, 0, 0, 0, 0, 420, 0, 0, 0, 0, + 0, 0, 0, 0, 421, 0, 422, 0, 423, 424, + 35, 0, 0, 0, 0, 0, 0, 0, 41, 42, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 426, 427, 428, 429, 430, 431, 432, 433, 0, 434, + 435, 436, 0, 0, 0, 0, 0, 0, 0, 437, + 438, 0, 439, 440, 0, 441, 442, 443, 135, 136, + 0, 138, 139, 0, 444, 445, 446, 447, 448, 0, + 0, 449, 450, 451, 140, 452, 0, 453, 454, 455, + 456, 144, 0, 0, 0, 457, 458, 459, 460, 0, + 461, 462, 0, 463, 464, 465, 466, 467, 468, 0, + 0, 469, 0, 0, 0, 0, 0, 0, 0, 0, + 470, 471, 472, 473, 474, 475, 155, 156, 476, 4239, + 477, 0, 478, 479, 480, 481, 482, 0, 483, 484, + 485, 0, 0, 486, 487, 488, 489, 490, 0, 491, + 492, 493, 0, 494, 495, 0, 496, 497, 498, 499, + 164, 500, 501, 502, 166, 0, 503, 0, 504, 168, + 505, 0, 506, 0, 507, 0, 0, 0, 508, 509, + 510, 0, 511, 172, 0, 512, 0, 513, 514, 515, + 516, 517, 0, 518, 519, 520, 0, 521, 522, 523, + 524, 525, 526, 0, 527, 0, 175, 0, 528, 529, + 530, 0, 176, 0, 177, 0, 531, 0, 0, 532, + 0, 533, 534, 535, 536, 537, 538, 539, 0, 540, + 181, 0, 541, 0, 0, 542, 543, 544, 0, 0, + 545, 546, 547, 548, 549, 550, 551, 552, 553, 554, + 555, 556, 188, 0, 190, 557, 558, 191, 0, 559, + 560, 0, 561, 0, 194, 562, 195, 563, 564, 565, + 0, 566, 0, 0, 567, 568, 569, 0, 0, 196, + 0, 0, 0, 200, 570, 571, 572, 573, 574, 575, + 576, 0, 577, 201, 578, 202, 579, 580, 581, 0, + 582, 583, 584, 585, 586, 587, 588, 204, 589, 590, + 591, 592, 0, 593, 594, 595, 596, 597, 598, 599, + 600, 601, 602, 0, 603, 604, 0, 605, 606, 212, + 607, 608, 609, 610, 611, 612, 613, 614, 0, 615, + 616, 617, 618, 619, 0, 620, 217, 621, 622, 0, + 623, 220, 624, 0, 625, 626, 627, 628, 629, 630, + 631, 632, 633, 634, 222, 0, 635, 636, 0, 637, + 638, 639, 640, 641, 642, 0, 224, 225, 0, 0, + 644, 226, 645, 227, 0, 646, 647, 648, 649, 650, + 651, 652, 0, 0, 653, 654, 655, 656, 657, 0, + 0, 658, 659, 660, 661, 662, 663, 234, 0, 664, + 0, 665, 666, 667, 0, 0, 668, 0, 0, 669, + 670, 671, 672, 673, 237, 238, 239, 240, 241, 242, + 243, 244, 245, 674, 675, 676, 86, 87, 88, 412, + 90, 91, 92, 413, 0, 414, 95, 0, 0, 98, + 99, 100, 101, 102, 103, 0, 104, 105, 415, 0, + 0, 107, 108, 109, 110, 0, 0, 112, 113, 114, + 115, 0, 116, 0, 0, 416, 417, 0, 0, 0, + 418, 419, 0, 0, 0, 0, 420, 0, 0, 0, + 0, 0, 0, 0, 0, 421, 0, 422, 0, 423, + 424, 35, 0, 0, 0, 0, 0, 0, 0, 41, + 42, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 426, 427, 428, 429, 430, 431, 432, 433, 0, + 434, 435, 436, 0, 0, 0, 0, 0, 0, 0, + 437, 438, 0, 439, 440, 0, 441, 442, 443, 135, + 136, 0, 138, 139, 0, 444, 445, 446, 447, 448, + 0, 0, 449, 450, 451, 140, 452, 0, 453, 454, + 455, 456, 144, 0, 0, 0, 457, 458, 459, 460, + 0, 461, 462, 0, 463, 464, 465, 466, 467, 468, + 0, 0, 469, 0, 0, 0, 0, 0, 0, 0, + 0, 470, 471, 472, 473, 474, 475, 155, 156, 476, + 4241, 477, 0, 478, 479, 480, 481, 482, 0, 483, + 484, 485, 0, 0, 486, 487, 488, 489, 490, 0, + 491, 492, 493, 0, 494, 495, 0, 496, 497, 498, + 499, 164, 500, 501, 502, 166, 0, 503, 0, 504, + 168, 505, 0, 506, 0, 507, 0, 0, 0, 508, + 509, 510, 0, 511, 172, 0, 512, 0, 513, 514, + 515, 516, 517, 0, 518, 519, 520, 0, 521, 522, + 523, 524, 525, 526, 0, 527, 0, 175, 0, 528, + 529, 530, 0, 176, 0, 177, 0, 531, 0, 0, + 532, 0, 533, 534, 535, 536, 537, 538, 539, 0, + 540, 181, 0, 541, 0, 0, 542, 543, 544, 0, + 0, 545, 546, 547, 548, 549, 550, 551, 552, 553, + 554, 555, 556, 188, 0, 190, 557, 558, 191, 0, + 559, 560, 0, 561, 0, 194, 562, 195, 563, 564, + 565, 0, 566, 0, 0, 567, 568, 569, 0, 0, + 196, 0, 0, 0, 200, 570, 571, 572, 573, 574, + 575, 576, 0, 577, 201, 578, 202, 579, 580, 581, + 0, 582, 583, 584, 585, 586, 587, 588, 204, 589, + 590, 591, 592, 0, 593, 594, 595, 596, 597, 598, + 599, 600, 601, 602, 0, 603, 604, 0, 605, 606, + 212, 607, 608, 609, 610, 611, 612, 613, 614, 0, + 615, 616, 617, 618, 619, 0, 620, 217, 621, 622, + 0, 623, 220, 624, 0, 625, 626, 627, 628, 629, + 630, 631, 632, 633, 634, 222, 0, 635, 636, 0, + 637, 638, 639, 640, 641, 642, 0, 224, 225, 0, + 0, 644, 226, 645, 227, 0, 646, 647, 648, 649, + 650, 651, 652, 0, 0, 653, 654, 655, 656, 657, + 0, 0, 658, 659, 660, 661, 662, 663, 234, 0, + 664, 0, 665, 666, 667, 0, 0, 668, 0, 0, + 669, 670, 671, 672, 673, 237, 238, 239, 240, 241, + 242, 243, 244, 245, 674, 675, 676, 86, 87, 88, + 412, 90, 91, 92, 413, 0, 414, 95, 0, 0, + 98, 99, 100, 101, 102, 103, 0, 104, 105, 415, + 0, 0, 107, 108, 109, 110, 0, 0, 112, 113, + 114, 115, 0, 116, 0, 0, 416, 417, 0, 0, + 0, 418, 419, 0, 0, 0, 0, 420, 0, 0, + 0, 0, 0, 0, 0, 0, 421, 0, 422, 0, + 423, 424, 35, 0, 0, 0, 0, 0, 0, 0, + 41, 42, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 426, 427, 428, 429, 430, 431, 432, 433, + 0, 434, 435, 436, 0, 0, 0, 0, 0, 0, + 0, 437, 438, 0, 439, 440, 0, 441, 442, 443, + 135, 136, 0, 138, 139, 0, 444, 445, 446, 447, + 448, 0, 0, 449, 450, 451, 140, 452, 0, 453, + 454, 455, 456, 144, 0, 0, 0, 457, 458, 459, + 460, 0, 461, 462, 0, 463, 464, 465, 466, 467, + 468, 0, 0, 469, 0, 0, 0, 0, 0, 0, + 0, 0, 470, 471, 472, 473, 474, 475, 155, 156, + 476, 4243, 477, 0, 478, 479, 480, 481, 482, 0, + 483, 484, 485, 0, 0, 486, 487, 488, 489, 490, + 0, 491, 492, 493, 0, 494, 495, 0, 496, 497, + 498, 499, 164, 500, 501, 502, 166, 0, 503, 0, + 504, 168, 505, 0, 506, 0, 507, 0, 0, 0, + 508, 509, 510, 0, 511, 172, 0, 512, 0, 513, + 514, 515, 516, 517, 0, 518, 519, 520, 0, 521, + 522, 523, 524, 525, 526, 0, 527, 0, 175, 0, + 528, 529, 530, 0, 176, 0, 177, 0, 531, 0, + 0, 532, 0, 533, 534, 535, 536, 537, 538, 539, + 0, 540, 181, 0, 541, 0, 0, 542, 543, 544, + 0, 0, 545, 546, 547, 548, 549, 550, 551, 552, + 553, 554, 555, 556, 188, 0, 190, 557, 558, 191, + 0, 559, 560, 0, 561, 0, 194, 562, 195, 563, + 564, 565, 0, 566, 0, 0, 567, 568, 569, 0, + 0, 196, 0, 0, 0, 200, 570, 571, 572, 573, + 574, 575, 576, 0, 577, 201, 578, 202, 579, 580, + 581, 0, 582, 583, 584, 585, 586, 587, 588, 204, + 589, 590, 591, 592, 0, 593, 594, 595, 596, 597, + 598, 599, 600, 601, 602, 0, 603, 604, 0, 605, + 606, 212, 607, 608, 609, 610, 611, 612, 613, 614, + 0, 615, 616, 617, 618, 619, 0, 620, 217, 621, + 622, 0, 623, 220, 624, 0, 625, 626, 627, 628, + 629, 630, 631, 632, 633, 634, 222, 0, 635, 636, + 0, 637, 638, 639, 640, 641, 642, 0, 224, 225, + 0, 0, 644, 226, 645, 227, 0, 646, 647, 648, + 649, 650, 651, 652, 0, 0, 653, 654, 655, 656, + 657, 0, 0, 658, 659, 660, 661, 662, 663, 234, + 0, 664, 0, 665, 666, 667, 0, 0, 668, 0, + 0, 669, 670, 671, 672, 673, 237, 238, 239, 240, + 241, 242, 243, 244, 245, 674, 675, 676, 86, 87, + 88, 412, 90, 91, 92, 413, 0, 414, 95, 0, + 0, 98, 99, 100, 101, 102, 103, 0, 104, 105, + 415, 0, 0, 107, 108, 109, 110, 0, 0, 112, + 113, 114, 115, 0, 116, 0, 0, 416, 417, 0, + 0, 0, 418, 419, 0, 0, 0, 0, 420, 0, + 0, 0, 0, 0, 0, 0, 0, 421, 0, 422, + 0, 423, 424, 35, 0, 0, 0, 0, 0, 0, + 0, 41, 42, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 426, 427, 428, 429, 430, 431, 432, + 433, 0, 434, 435, 436, 0, 0, 0, 0, 0, + 0, 0, 437, 438, 0, 439, 440, 0, 441, 442, + 443, 135, 136, 0, 138, 139, 0, 444, 445, 446, + 447, 448, 0, 0, 449, 450, 451, 140, 452, 0, + 453, 454, 455, 456, 144, 0, 0, 0, 457, 458, + 459, 460, 0, 461, 462, 0, 463, 464, 465, 466, + 467, 468, 0, 0, 469, 0, 0, 0, 0, 0, + 0, 0, 0, 470, 471, 472, 473, 474, 475, 155, + 156, 476, 0, 477, 0, 478, 479, 480, 481, 482, + 0, 483, 484, 485, 0, 0, 486, 487, 488, 489, + 490, 0, 491, 492, 493, 0, 494, 495, 0, 496, + 497, 498, 499, 164, 500, 501, 502, 166, 0, 503, + 0, 504, 168, 505, 0, 506, 0, 507, 0, 0, + 0, 508, 509, 510, 0, 511, 172, 0, 512, 0, + 513, 514, 515, 516, 517, 0, 518, 519, 520, 0, + 521, 522, 523, 524, 525, 526, 0, 527, 0, 175, + 0, 528, 529, 530, 0, 176, 0, 177, 0, 531, + 0, 0, 532, 0, 533, 534, 535, 536, 537, 538, + 539, 0, 540, 181, 0, 541, 0, 0, 542, 543, + 544, 0, 0, 545, 546, 547, 548, 549, 550, 551, + 552, 553, 554, 555, 556, 188, 0, 190, 557, 558, + 191, 0, 559, 560, 0, 561, 0, 194, 562, 195, + 563, 564, 565, 0, 566, 0, 0, 567, 568, 569, + 0, 0, 196, 0, 0, 0, 200, 570, 571, 572, + 573, 574, 575, 576, 0, 577, 201, 578, 202, 579, + 580, 581, 0, 582, 583, 584, 585, 586, 587, 588, + 204, 589, 590, 591, 592, 0, 593, 594, 595, 596, + 597, 598, 599, 600, 601, 602, 0, 603, 604, 0, + 605, 606, 212, 607, 608, 609, 610, 611, 612, 613, + 614, 0, 615, 616, 617, 618, 619, 0, 620, 217, + 621, 622, 0, 623, 220, 624, 0, 625, 626, 627, + 628, 629, 630, 631, 632, 633, 634, 222, 0, 635, + 636, 0, 637, 638, 639, 640, 641, 642, 0, 224, + 225, 0, 0, 644, 226, 645, 227, 0, 646, 647, + 648, 649, 650, 651, 652, 0, 0, 653, 654, 655, + 656, 657, 0, 4619, 658, 659, 660, 661, 662, 663, + 234, 0, 664, 0, 665, 666, 667, 0, 0, 668, + 0, 0, 669, 670, 671, 672, 673, 237, 238, 239, + 240, 241, 242, 243, 244, 245, 674, 675, 676, 86, + 87, 88, 412, 90, 91, 92, 413, 0, 414, 95, + 0, 0, 98, 99, 100, 101, 102, 103, 0, 104, + 105, 415, 0, 0, 107, 108, 109, 110, 0, 0, + 112, 113, 114, 115, 0, 116, 0, 0, 416, 417, + 0, 0, 0, 418, 419, 0, 0, 0, 0, 420, + 0, 0, 0, 0, 0, 0, 0, 0, 421, 0, + 422, 0, 423, 424, 35, 0, 0, 0, 0, 0, + 0, 0, 41, 42, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 426, 427, 428, 429, 430, 431, + 432, 433, 0, 434, 435, 436, 0, 0, 0, 0, + 0, 0, 0, 437, 438, 0, 439, 440, 0, 441, + 442, 443, 135, 136, 0, 138, 139, 0, 444, 445, + 446, 447, 448, 0, 0, 449, 450, 451, 140, 452, + 0, 453, 454, 455, 456, 144, 0, 0, 0, 457, + 458, 459, 460, 0, 461, 462, 0, 463, 464, 465, + 466, 467, 468, 0, 0, 469, 0, 0, 0, 0, + 0, 0, 0, 0, 470, 471, 472, 473, 474, 475, + 155, 156, 476, 0, 477, 0, 478, 479, 480, 481, + 482, 0, 483, 484, 485, 0, 0, 486, 487, 488, + 489, 490, 0, 491, 492, 493, 0, 494, 495, 0, + 496, 497, 498, 499, 164, 500, 501, 502, 166, 0, + 503, 0, 504, 168, 505, 0, 506, 0, 507, 0, + 0, 0, 508, 509, 510, 0, 511, 172, 0, 512, + 0, 513, 514, 515, 516, 517, 0, 518, 519, 520, + 0, 521, 522, 523, 524, 525, 526, 0, 527, 0, + 175, 0, 528, 529, 530, 0, 176, 0, 177, 0, + 531, 0, 0, 532, 0, 533, 534, 535, 536, 537, + 538, 539, 0, 540, 181, 0, 541, 0, 0, 542, + 543, 544, 0, 0, 545, 546, 547, 548, 549, 550, + 551, 552, 553, 554, 555, 556, 188, 0, 190, 557, + 558, 191, 0, 559, 560, 0, 561, 0, 194, 562, + 195, 563, 564, 565, 0, 566, 0, 0, 567, 568, + 569, 0, 0, 196, 0, 0, 0, 200, 570, 571, + 572, 573, 574, 575, 576, 0, 577, 201, 578, 202, + 579, 580, 581, 0, 582, 583, 584, 585, 586, 587, + 588, 204, 589, 590, 591, 592, 0, 593, 594, 595, + 596, 597, 598, 599, 600, 601, 602, 0, 603, 604, + 0, 605, 606, 212, 607, 608, 609, 610, 611, 612, + 613, 614, 0, 615, 616, 617, 618, 619, 0, 620, + 217, 621, 622, 0, 623, 220, 624, 0, 625, 626, + 627, 628, 629, 630, 631, 632, 633, 634, 222, 0, + 635, 636, 0, 637, 638, 639, 640, 641, 642, 0, + 224, 225, 0, 0, 644, 226, 645, 227, 0, 646, + 647, 648, 649, 650, 651, 652, 0, 0, 653, 654, + 655, 656, 657, 0, 0, 658, 659, 660, 661, 662, + 663, 234, 0, 664, 0, 665, 666, 667, 0, 0, + 668, 0, 0, 669, 670, 671, 672, 673, 237, 238, + 239, 240, 241, 242, 243, 244, 245, 674, 675, 676, + 86, 87, 88, 412, 90, 91, 92, 413, 0, 414, + 95, 0, 0, 98, 99, 100, 101, 102, 103, 0, + 104, 105, 415, 0, 0, 107, 108, 109, 110, 0, + 0, 112, 113, 114, 115, 0, 116, 0, 0, 416, + 417, 0, 0, 0, 418, 419, 0, 0, 0, 0, + 420, 0, 0, 0, 0, 0, 0, 0, 0, 421, + 0, 422, 0, 423, 424, 35, 0, 0, 0, 0, + 0, 0, 0, 41, 42, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 426, 427, 428, 429, 430, + 431, 432, 433, 0, 434, 435, 436, 0, 0, 0, + 0, 0, 0, 0, 437, 438, 0, 439, 440, 0, + 441, 442, 443, 135, 136, 0, 138, 139, 0, 444, + 445, 446, 447, 448, 0, 0, 449, 450, 451, 140, + 452, 0, 453, 454, 455, 456, 144, 0, 0, 0, + 457, 458, 459, 460, 0, 461, 462, 0, 463, 464, + 465, 466, 467, 468, 0, 0, 469, 0, 0, 0, + 0, 0, 0, 0, 0, 470, 471, 472, 473, 474, + 475, 155, 156, 476, 0, 477, 0, 478, 479, 480, + 481, 482, 0, 483, 484, 485, 0, 0, 486, 487, + 488, 489, 490, 0, 491, 492, 493, 0, 494, 495, + 0, 496, 497, 498, 499, 164, 500, 501, 502, 166, + 0, 503, 0, 504, 168, 505, 0, 506, 0, 507, + 0, 0, 0, 508, 509, 510, 0, 511, 172, 0, + 512, 0, 513, 514, 515, 516, 517, 0, 518, 519, + 520, 0, 521, 522, 523, 524, 525, 526, 0, 527, + 0, 175, 0, 528, 529, 530, 0, 176, 0, 177, + 0, 531, 0, 0, 532, 0, 533, 534, 535, 536, + 537, 538, 539, 0, 540, 181, 0, 541, 0, 0, + 542, 543, 544, 0, 0, 545, 546, 547, 548, 549, + 550, 551, 552, 553, 554, 555, 556, 188, 0, 190, + 557, 558, 191, 0, 559, 560, 0, 561, 0, 194, + 562, 195, 563, 564, 565, 0, 566, 0, 0, 567, + 568, 569, 0, 0, 196, 0, 0, 0, 200, 570, + 571, 572, 573, 574, 575, 576, 0, 577, 201, 578, + 202, 579, 580, 581, 0, 582, 583, 584, 585, 586, + 587, 588, 204, 589, 590, 591, 592, 0, 593, 594, + 595, 596, 597, 598, 599, 600, 601, 602, 0, 603, + 604, 0, 605, 606, 212, 607, 608, 1010, 610, 611, + 612, 613, 614, 0, 615, 616, 617, 618, 619, 0, + 620, 217, 621, 622, 0, 623, 220, 624, 0, 625, + 626, 627, 628, 629, 630, 631, 632, 633, 634, 222, + 0, 635, 636, 0, 637, 638, 639, 640, 641, 642, + 0, 224, 225, 0, 0, 644, 226, 645, 227, 0, + 646, 647, 648, 649, 650, 651, 652, 0, 0, 653, + 654, 655, 656, 657, 0, 0, 658, 659, 660, 661, + 662, 663, 234, 0, 664, 0, 665, 666, 667, 0, + 0, 668, 0, 0, 669, 670, 671, 672, 673, 237, + 238, 239, 240, 241, 242, 243, 244, 245, 674, 675, + 676, 86, 87, 88, 412, 90, 91, 92, 413, 0, + 414, 95, 0, 0, 98, 99, 100, 101, 102, 103, + 0, 104, 105, 415, 0, 0, 107, 108, 109, 110, + 0, 0, 112, 113, 114, 115, 0, 116, 0, 0, + 416, 417, 0, 0, 0, 418, 419, 0, 0, 0, + 0, 420, 0, 0, 0, 0, 0, 0, 0, 0, + 421, 0, 422, 0, 423, 424, 35, 0, 0, 0, + 0, 0, 0, 0, 41, 42, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 426, 427, 428, 429, + 430, 431, 432, 433, 1012, 434, 435, 436, 0, 0, + 0, 0, 0, 0, 0, 437, 438, 0, 439, 440, + 0, 441, 442, 443, 135, 136, 0, 138, 139, 0, + 444, 445, 446, 447, 448, 0, 0, 449, 450, 1013, + 140, 452, 0, 453, 454, 455, 456, 144, 0, 0, + 0, 457, 458, 459, 460, 0, 461, 0, 0, 463, + 464, 465, 466, 467, 468, 0, 0, 469, 0, 0, + 0, 0, 0, 0, 0, 0, 470, 471, 472, 473, + 474, 475, 155, 156, 476, 0, 477, 0, 478, 479, + 480, 481, 482, 0, 483, 484, 485, 0, 0, 486, + 487, 488, 489, 490, 0, 491, 492, 493, 0, 494, + 495, 0, 496, 497, 498, 499, 164, 500, 501, 502, + 166, 0, 503, 0, 504, 168, 505, 0, 506, 0, + 507, 0, 0, 0, 508, 509, 510, 0, 511, 172, + 0, 512, 0, 513, 514, 515, 516, 517, 0, 518, + 519, 520, 0, 521, 522, 523, 524, 525, 526, 0, + 527, 0, 175, 0, 528, 529, 530, 0, 176, 0, + 177, 0, 531, 0, 0, 532, 0, 533, 534, 535, + 536, 537, 538, 539, 0, 540, 181, 0, 541, 0, + 0, 542, 543, 544, 0, 0, 545, 546, 547, 548, + 549, 550, 551, 552, 553, 554, 555, 556, 188, 0, + 190, 557, 558, 191, 0, 559, 560, 0, 561, 0, + 194, 562, 195, 563, 564, 565, 0, 566, 0, 0, + 567, 568, 569, 0, 0, 196, 0, 0, 0, 200, + 570, 571, 572, 573, 574, 575, 576, 0, 577, 201, + 578, 202, 579, 580, 581, 0, 582, 583, 584, 585, + 586, 587, 588, 204, 589, 590, 591, 592, 0, 593, + 594, 595, 596, 597, 598, 599, 600, 601, 602, 0, + 603, 604, 0, 605, 606, 212, 607, 608, 609, 610, + 611, 612, 613, 614, 0, 615, 616, 617, 618, 1014, + 0, 620, 217, 621, 622, 0, 623, 220, 624, 0, + 625, 626, 627, 628, 629, 630, 631, 632, 633, 634, + 222, 0, 635, 636, 0, 637, 638, 639, 640, 641, + 642, 0, 1015, 225, 0, 0, 1016, 226, 645, 227, + 0, 646, 647, 648, 649, 650, 651, 652, 0, 0, + 653, 654, 655, 656, 657, 0, 0, 658, 659, 660, + 661, 662, 1017, 234, 0, 664, 0, 665, 666, 667, + 0, 0, 668, 0, 0, 669, 670, 671, 672, 673, + 237, 238, 239, 240, 241, 242, 243, 244, 245, 674, + 675, 676, 86, 87, 88, 412, 90, 91, 92, 413, + 0, 414, 95, 0, 0, 98, 99, 100, 101, 102, + 103, 0, 104, 105, 415, 0, 0, 107, 108, 109, + 110, 0, 0, 112, 113, 114, 115, 0, 116, 0, + 0, 416, 417, 0, 0, 0, 418, 419, 0, 0, + 0, 0, 420, 0, 0, 0, 0, 0, 0, 0, + 0, 421, 0, 422, 0, 423, 424, 35, 0, 0, + 0, 0, 0, 0, 0, 41, 42, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 426, 427, 428, + 429, 430, 431, 432, 433, 1053, 434, 435, 436, 0, + 0, 0, 0, 0, 0, 0, 437, 438, 0, 439, + 440, 0, 441, 442, 443, 135, 136, 0, 138, 139, + 0, 444, 445, 446, 447, 448, 0, 0, 449, 450, + 1013, 140, 452, 0, 453, 454, 455, 456, 144, 0, + 0, 0, 457, 458, 459, 460, 0, 461, 0, 0, + 463, 464, 465, 466, 467, 468, 0, 0, 469, 0, + 0, 0, 0, 0, 0, 0, 0, 470, 471, 472, + 473, 474, 475, 155, 156, 476, 0, 477, 0, 478, + 479, 480, 481, 482, 0, 483, 484, 485, 0, 0, + 486, 487, 488, 489, 490, 0, 491, 492, 493, 0, + 494, 495, 0, 496, 497, 498, 499, 164, 500, 501, + 502, 166, 0, 503, 0, 504, 168, 505, 0, 506, + 0, 507, 0, 0, 0, 508, 509, 510, 0, 511, + 172, 0, 512, 0, 513, 514, 515, 516, 517, 0, + 518, 519, 520, 0, 521, 522, 523, 524, 525, 526, + 0, 527, 0, 175, 0, 528, 529, 530, 0, 176, + 0, 177, 0, 531, 0, 0, 532, 0, 533, 534, + 535, 536, 537, 538, 539, 0, 540, 181, 0, 541, + 0, 0, 542, 543, 544, 0, 0, 545, 546, 547, + 548, 549, 550, 551, 552, 553, 554, 555, 556, 188, + 0, 190, 557, 558, 191, 0, 559, 560, 0, 561, + 0, 194, 562, 195, 563, 564, 565, 0, 566, 0, + 0, 567, 568, 569, 0, 0, 196, 0, 0, 0, + 200, 570, 571, 572, 573, 574, 575, 576, 0, 577, + 201, 578, 202, 579, 580, 581, 0, 582, 583, 584, + 585, 586, 587, 588, 204, 589, 590, 591, 592, 0, + 593, 594, 595, 596, 597, 598, 599, 600, 601, 602, + 0, 603, 604, 0, 605, 606, 212, 607, 608, 609, + 610, 611, 612, 613, 614, 0, 615, 616, 617, 618, + 1054, 0, 620, 217, 621, 622, 0, 623, 220, 624, + 0, 625, 626, 627, 628, 629, 630, 631, 632, 633, + 634, 222, 0, 635, 636, 0, 637, 638, 639, 640, + 641, 642, 0, 1055, 225, 0, 0, 1056, 226, 645, + 227, 0, 646, 647, 648, 649, 650, 651, 652, 0, + 0, 653, 654, 655, 656, 657, 0, 0, 658, 659, + 660, 661, 662, 1017, 234, 0, 664, 0, 665, 666, + 667, 0, 0, 668, 0, 0, 669, 670, 671, 672, + 673, 237, 238, 239, 240, 241, 242, 243, 244, 245, + 674, 675, 676, 86, 87, 88, 412, 90, 91, 92, + 413, 0, 414, 95, 0, 0, 98, 99, 100, 101, + 102, 103, 0, 104, 105, 415, 0, 0, 107, 108, + 109, 110, 0, 0, 112, 113, 114, 115, 0, 116, + 0, 0, 416, 417, 0, 0, 0, 418, 419, 0, + 0, 0, 0, 420, 0, 0, 0, 0, 0, 0, + 0, 0, 421, 0, 422, 0, 423, 424, 35, 0, + 0, 0, 0, 0, 0, 0, 41, 42, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 426, 427, + 428, 429, 430, 431, 432, 433, 0, 434, 435, 436, + 0, 0, 0, 0, 0, 0, 0, 437, 438, 0, + 439, 440, 0, 441, 442, 443, 135, 136, 0, 138, + 139, 0, 444, 445, 446, 447, 448, 0, 0, 449, + 450, 451, 140, 452, 0, 453, 454, 455, 456, 144, + 0, 0, 0, 457, 458, 459, 460, 0, 461, 462, + 0, 463, 464, 465, 466, 467, 468, 0, 0, 469, + 0, 0, 0, 0, 0, 0, 0, 0, 470, 471, + 472, 473, 474, 475, 155, 156, 476, 0, 477, 0, + 478, 479, 480, 481, 482, 0, 483, 484, 485, 0, + 0, 486, 487, 488, 489, 490, 0, 491, 492, 493, + 0, 494, 495, 0, 496, 497, 498, 499, 164, 500, + 501, 502, 166, 0, 503, 0, 504, 168, 505, 0, + 506, 0, 507, 0, 0, 0, 508, 509, 510, 0, + 511, 172, 0, 512, 0, 513, 514, 515, 516, 517, + 0, 518, 519, 520, 0, 521, 522, 523, 524, 525, + 526, 0, 527, 0, 175, 0, 528, 529, 530, 0, + 176, 0, 177, 0, 531, 0, 0, 532, 0, 533, + 534, 535, 536, 537, 538, 539, 0, 540, 181, 0, + 541, 0, 0, 542, 543, 544, 0, 0, 545, 546, + 547, 548, 549, 550, 551, 552, 553, 554, 555, 556, + 188, 0, 190, 557, 558, 191, 0, 559, 560, 0, + 561, 0, 194, 562, 195, 563, 564, 565, 0, 566, + 0, 0, 567, 568, 569, 0, 0, 196, 0, 0, + 0, 200, 570, 571, 572, 573, 574, 575, 576, 0, + 577, 201, 578, 202, 579, 580, 581, 0, 582, 583, + 584, 585, 586, 587, 588, 204, 589, 590, 1073, 592, + 0, 593, 594, 595, 596, 597, 598, 599, 600, 601, + 602, 0, 603, 604, 0, 605, 606, 212, 607, 608, + 609, 610, 611, 612, 613, 614, 0, 615, 616, 617, + 618, 619, 0, 620, 217, 621, 622, 0, 623, 220, + 624, 0, 625, 626, 627, 628, 629, 630, 631, 632, + 633, 634, 222, 0, 635, 636, 0, 637, 638, 639, + 640, 641, 642, 0, 224, 225, 0, 0, 644, 226, + 645, 227, 0, 646, 647, 648, 649, 650, 651, 652, + 0, 0, 653, 654, 655, 656, 657, 0, 0, 658, + 659, 660, 661, 662, 663, 234, 0, 664, 0, 665, + 666, 667, 0, 0, 668, 0, 0, 669, 670, 671, + 672, 673, 237, 238, 239, 240, 241, 242, 243, 244, + 245, 674, 675, 676, 86, 87, 88, 412, 90, 91, + 92, 413, 0, 414, 95, 0, 0, 98, 99, 100, + 101, 102, 103, 0, 104, 105, 415, 0, 0, 107, + 108, 109, 110, 0, 0, 112, 113, 114, 115, 0, + 116, 0, 0, 416, 417, 0, 0, 0, 418, 419, + 0, 0, 0, 0, 420, 0, 0, 0, 0, 0, + 0, 0, 0, 421, 0, 422, 0, 423, 424, 35, + 0, 0, 0, 0, 0, 0, 0, 41, 42, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 426, + 427, 428, 429, 430, 431, 432, 433, 0, 434, 435, + 436, 0, 0, 0, 0, 0, 0, 0, 437, 438, + 0, 439, 440, 0, 441, 442, 443, 135, 136, 0, + 138, 139, 0, 444, 445, 446, 447, 448, 0, 0, + 449, 450, 451, 140, 452, 0, 453, 454, 455, 456, + 144, 0, 0, 0, 457, 458, 459, 460, 0, 461, + 462, 0, 463, 464, 465, 466, 467, 468, 0, 0, + 469, 0, 0, 0, 0, 0, 0, 0, 0, 470, + 471, 472, 473, 474, 475, 155, 156, 476, 0, 477, + 0, 478, 479, 480, 481, 482, 0, 483, 484, 485, + 0, 0, 486, 487, 488, 489, 490, 0, 491, 492, + 493, 0, 494, 495, 0, 496, 497, 498, 499, 164, + 500, 501, 502, 166, 0, 503, 0, 504, 168, 505, + 0, 506, 0, 507, 0, 0, 0, 508, 509, 510, + 0, 511, 172, 0, 512, 0, 513, 514, 515, 516, + 1178, 0, 518, 519, 520, 0, 521, 522, 523, 524, + 525, 526, 0, 527, 0, 175, 0, 528, 529, 530, + 0, 176, 0, 177, 0, 531, 0, 0, 532, 0, + 533, 534, 535, 536, 537, 538, 539, 0, 540, 181, + 0, 541, 0, 0, 542, 543, 544, 0, 0, 545, + 546, 547, 548, 549, 550, 551, 552, 553, 554, 555, + 556, 188, 0, 190, 557, 558, 191, 0, 559, 560, + 0, 561, 0, 194, 562, 195, 563, 564, 565, 0, + 566, 0, 0, 567, 568, 569, 0, 0, 196, 0, + 0, 0, 200, 570, 571, 572, 573, 574, 575, 576, + 0, 577, 201, 578, 202, 579, 580, 581, 0, 582, + 583, 584, 585, 586, 587, 588, 204, 589, 590, 591, + 592, 0, 593, 594, 595, 596, 597, 598, 599, 600, + 601, 602, 0, 603, 604, 0, 605, 606, 212, 607, + 608, 609, 610, 611, 612, 613, 614, 0, 615, 616, + 617, 618, 619, 0, 620, 217, 621, 622, 0, 623, + 220, 624, 0, 625, 626, 627, 628, 629, 630, 631, + 632, 633, 634, 222, 0, 635, 636, 0, 637, 638, + 639, 640, 641, 642, 0, 224, 225, 0, 0, 644, + 226, 645, 227, 0, 646, 647, 648, 649, 650, 651, + 652, 0, 0, 653, 654, 655, 656, 657, 0, 0, + 658, 659, 660, 661, 662, 663, 234, 0, 664, 0, + 665, 666, 667, 0, 0, 668, 0, 0, 669, 670, + 671, 672, 673, 237, 238, 239, 240, 241, 242, 243, + 244, 245, 674, 675, 676, 86, 87, 88, 412, 90, + 91, 92, 413, 0, 414, 95, 0, 0, 98, 99, + 100, 101, 102, 103, 0, 104, 105, 415, 0, 0, + 107, 108, 109, 110, 0, 0, 112, 113, 114, 115, + 0, 116, 0, 0, 416, 417, 0, 0, 0, 418, + 419, 0, 0, 0, 0, 420, 0, 0, 0, 0, + 0, 0, 0, 0, 421, 0, 422, 0, 423, 424, + 35, 0, 0, 0, 0, 0, 0, 0, 41, 42, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 426, 427, 428, 429, 430, 431, 432, 433, 0, 434, + 435, 436, 0, 0, 0, 0, 0, 0, 0, 437, + 438, 0, 439, 440, 0, 441, 442, 443, 135, 136, + 0, 138, 139, 0, 444, 445, 446, 447, 448, 0, + 0, 449, 450, 451, 140, 452, 0, 453, 454, 455, + 456, 144, 0, 0, 0, 457, 458, 459, 460, 0, + 461, 462, 0, 463, 464, 465, 466, 467, 468, 0, + 0, 469, 0, 0, 0, 0, 0, 0, 0, 0, + 470, 471, 472, 473, 474, 475, 155, 156, 476, 0, + 477, 0, 478, 479, 480, 481, 482, 0, 483, 484, + 485, 0, 0, 486, 487, 488, 489, 490, 0, 491, + 492, 493, 0, 494, 495, 0, 496, 497, 498, 499, + 164, 500, 501, 502, 166, 0, 503, 0, 504, 168, + 505, 0, 506, 0, 507, 0, 0, 0, 508, 509, + 510, 0, 511, 172, 0, 512, 0, 513, 514, 515, + 516, 1199, 0, 518, 519, 520, 0, 521, 522, 523, + 524, 525, 526, 0, 527, 0, 175, 0, 528, 529, + 530, 0, 176, 0, 177, 0, 531, 0, 0, 532, + 0, 533, 534, 535, 536, 537, 538, 539, 0, 540, + 181, 0, 541, 0, 0, 542, 543, 544, 0, 0, + 545, 546, 547, 548, 549, 550, 551, 552, 553, 554, + 555, 556, 188, 0, 190, 557, 558, 191, 0, 559, + 560, 0, 561, 0, 194, 562, 195, 563, 564, 565, + 0, 566, 0, 0, 567, 568, 569, 0, 0, 196, + 0, 0, 0, 200, 570, 571, 572, 573, 574, 575, + 576, 0, 577, 201, 578, 202, 579, 580, 581, 0, + 582, 583, 584, 585, 586, 587, 588, 204, 589, 590, + 591, 592, 0, 593, 594, 595, 596, 597, 598, 599, + 600, 601, 602, 0, 603, 604, 0, 605, 606, 212, + 607, 608, 609, 610, 611, 612, 613, 614, 0, 615, + 616, 617, 618, 619, 0, 620, 217, 621, 622, 0, + 623, 220, 624, 0, 625, 626, 627, 628, 629, 630, + 631, 632, 633, 634, 222, 0, 635, 636, 0, 637, + 638, 639, 640, 641, 642, 0, 224, 225, 0, 0, + 644, 226, 645, 227, 0, 646, 647, 648, 649, 650, + 651, 652, 0, 0, 653, 654, 655, 656, 657, 0, + 0, 658, 659, 660, 661, 662, 663, 234, 0, 664, + 0, 665, 666, 667, 0, 0, 668, 0, 0, 669, + 670, 671, 672, 673, 237, 238, 239, 240, 241, 242, + 243, 244, 245, 674, 675, 676, 86, 87, 88, 412, + 90, 91, 92, 413, 0, 414, 95, 0, 0, 98, + 99, 100, 101, 102, 103, 0, 104, 105, 415, 0, + 0, 107, 108, 109, 110, 0, 0, 112, 113, 114, + 115, 0, 116, 0, 0, 416, 417, 0, 0, 0, + 418, 419, 0, 0, 0, 0, 420, 0, 0, 0, + 0, 0, 0, 0, 0, 421, 0, 422, 0, 423, + 424, 35, 0, 0, 0, 0, 0, 0, 0, 41, + 42, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 426, 427, 428, 429, 430, 431, 432, 433, 0, + 434, 435, 436, 0, 0, 0, 0, 0, 0, 0, + 437, 438, 0, 439, 440, 0, 441, 442, 443, 135, + 136, 0, 138, 139, 0, 444, 445, 446, 447, 448, + 0, 0, 449, 450, 451, 140, 452, 0, 453, 454, + 455, 456, 144, 0, 0, 0, 457, 458, 459, 460, + 0, 461, 462, 0, 463, 464, 465, 466, 467, 468, + 0, 0, 469, 0, 0, 0, 0, 0, 0, 0, + 0, 470, 471, 472, 473, 474, 475, 155, 156, 476, + 0, 477, 0, 478, 479, 480, 481, 482, 0, 483, + 484, 485, 0, 0, 486, 487, 488, 489, 490, 0, + 491, 492, 493, 0, 494, 495, 0, 496, 497, 498, + 499, 164, 500, 501, 502, 166, 0, 503, 0, 504, + 168, 505, 0, 506, 0, 507, 0, 0, 0, 508, + 509, 510, 0, 511, 172, 0, 512, 0, 513, 514, + 515, 516, 517, 0, 518, 519, 520, 0, 521, 522, + 523, 524, 525, 526, 0, 527, 0, 175, 0, 528, + 529, 530, 0, 176, 0, 177, 0, 531, 0, 0, + 532, 0, 533, 534, 535, 536, 537, 538, 539, 0, + 540, 181, 0, 541, 0, 0, 542, 543, 544, 0, + 0, 545, 546, 1208, 548, 549, 550, 551, 552, 553, + 554, 555, 556, 188, 0, 190, 557, 558, 191, 0, + 559, 560, 0, 561, 0, 194, 562, 195, 563, 564, + 565, 0, 566, 0, 0, 567, 568, 569, 0, 0, + 196, 0, 0, 0, 200, 570, 571, 572, 573, 574, + 575, 576, 0, 577, 201, 578, 202, 579, 580, 581, + 0, 582, 583, 584, 585, 586, 587, 588, 204, 589, + 590, 591, 592, 0, 593, 594, 595, 596, 597, 598, + 599, 600, 601, 602, 0, 603, 604, 0, 605, 606, + 212, 607, 608, 609, 610, 611, 612, 613, 614, 0, + 615, 616, 617, 618, 619, 0, 620, 217, 621, 622, + 0, 623, 220, 624, 0, 625, 626, 627, 628, 629, + 630, 631, 632, 633, 634, 222, 0, 635, 636, 0, + 637, 638, 639, 640, 641, 642, 0, 224, 225, 0, + 0, 644, 226, 645, 227, 0, 646, 647, 648, 649, + 650, 651, 652, 0, 0, 653, 654, 655, 656, 657, + 0, 0, 658, 659, 660, 661, 662, 663, 234, 0, + 664, 0, 665, 666, 667, 0, 0, 668, 0, 0, + 669, 670, 671, 672, 673, 237, 238, 239, 240, 241, + 242, 243, 244, 245, 674, 675, 676, 86, 87, 88, + 412, 90, 91, 92, 413, 0, 414, 95, 0, 0, + 98, 99, 100, 101, 102, 103, 0, 104, 105, 415, + 0, 0, 107, 108, 109, 110, 0, 0, 112, 113, + 114, 115, 0, 116, 0, 0, 416, 417, 0, 0, + 0, 418, 419, 0, 0, 0, 0, 420, 0, 0, + 0, 0, 0, 0, 0, 0, 421, 0, 422, 0, + 423, 424, 35, 0, 0, 0, 0, 0, 0, 0, + 41, 42, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 426, 427, 428, 429, 430, 431, 432, 433, + 0, 434, 435, 436, 0, 0, 0, 0, 0, 0, + 0, 437, 438, 0, 439, 440, 0, 441, 442, 443, + 135, 136, 0, 138, 139, 0, 444, 445, 446, 447, + 448, 0, 0, 449, 450, 451, 140, 452, 0, 453, + 454, 455, 456, 144, 0, 0, 0, 457, 458, 459, + 460, 0, 461, 462, 0, 463, 464, 465, 466, 467, + 468, 0, 0, 469, 0, 0, 0, 0, 0, 0, + 0, 0, 470, 471, 472, 473, 474, 475, 155, 156, + 476, 0, 477, 0, 478, 479, 480, 481, 482, 0, + 483, 484, 485, 0, 0, 486, 487, 488, 489, 490, + 0, 491, 492, 493, 0, 494, 495, 0, 496, 497, + 498, 499, 164, 500, 501, 502, 166, 0, 503, 0, + 504, 168, 505, 0, 506, 0, 507, 0, 0, 0, + 508, 509, 510, 0, 511, 172, 0, 512, 0, 513, + 514, 515, 516, 1210, 0, 518, 519, 520, 0, 521, + 522, 523, 524, 525, 526, 0, 527, 0, 175, 0, + 528, 529, 530, 0, 176, 0, 177, 0, 531, 0, + 0, 532, 0, 533, 534, 535, 536, 537, 538, 539, + 0, 540, 181, 0, 541, 0, 0, 542, 543, 544, + 0, 0, 545, 546, 547, 548, 549, 550, 551, 552, + 553, 554, 555, 556, 188, 0, 190, 557, 558, 191, + 0, 559, 560, 0, 561, 0, 194, 562, 195, 563, + 564, 565, 0, 566, 0, 0, 567, 568, 569, 0, + 0, 196, 0, 0, 0, 200, 570, 571, 572, 573, + 574, 575, 576, 0, 577, 201, 578, 202, 579, 580, + 581, 0, 582, 583, 584, 585, 586, 587, 588, 204, + 589, 590, 591, 592, 0, 593, 594, 595, 596, 597, + 598, 599, 600, 601, 602, 0, 603, 604, 0, 605, + 606, 212, 607, 608, 609, 610, 611, 612, 613, 614, + 0, 615, 616, 617, 618, 619, 0, 620, 217, 621, + 622, 0, 623, 220, 624, 0, 625, 626, 627, 628, + 629, 630, 631, 632, 633, 634, 222, 0, 635, 636, + 0, 637, 638, 639, 640, 641, 642, 0, 224, 225, + 0, 0, 644, 226, 645, 227, 0, 646, 647, 648, + 649, 650, 651, 652, 0, 0, 653, 654, 655, 656, + 657, 0, 0, 658, 659, 660, 661, 662, 663, 234, + 0, 664, 0, 665, 666, 667, 0, 0, 668, 0, + 0, 669, 670, 671, 672, 673, 237, 238, 239, 240, + 241, 242, 243, 244, 245, 674, 675, 676, 86, 87, + 88, 412, 90, 91, 92, 413, 0, 414, 95, 0, + 0, 98, 99, 100, 101, 102, 103, 0, 104, 105, + 415, 0, 0, 107, 108, 109, 110, 0, 0, 112, + 113, 114, 115, 0, 116, 0, 0, 416, 417, 0, + 0, 0, 418, 419, 0, 0, 0, 0, 420, 0, + 0, 0, 0, 0, 0, 0, 0, 421, 0, 422, + 0, 423, 424, 35, 0, 0, 0, 0, 0, 0, + 0, 41, 42, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 426, 427, 428, 429, 430, 431, 432, + 433, 0, 434, 435, 436, 0, 0, 0, 0, 0, + 0, 0, 437, 438, 0, 439, 440, 0, 441, 442, + 443, 135, 136, 0, 138, 139, 0, 444, 445, 446, + 447, 448, 0, 0, 449, 450, 451, 140, 452, 0, + 453, 454, 455, 456, 144, 0, 0, 0, 457, 458, + 459, 460, 0, 461, 462, 0, 463, 464, 465, 466, + 467, 468, 0, 0, 469, 0, 0, 0, 0, 0, + 0, 0, 0, 470, 471, 472, 473, 474, 475, 155, + 156, 476, 0, 477, 0, 478, 479, 480, 481, 482, + 0, 483, 484, 485, 0, 0, 486, 487, 488, 489, + 490, 0, 491, 492, 493, 0, 494, 495, 0, 496, + 497, 498, 499, 164, 500, 501, 502, 166, 0, 503, + 0, 504, 168, 505, 0, 506, 0, 507, 0, 0, + 0, 508, 509, 510, 0, 511, 172, 0, 512, 0, + 513, 514, 515, 516, 1261, 0, 518, 519, 520, 0, + 521, 522, 523, 524, 525, 526, 0, 527, 0, 175, + 0, 528, 529, 530, 0, 176, 0, 177, 0, 531, + 0, 0, 532, 0, 533, 534, 535, 536, 537, 538, + 539, 0, 540, 181, 0, 541, 0, 0, 542, 543, + 544, 0, 0, 545, 546, 547, 548, 549, 550, 551, + 552, 553, 554, 555, 556, 188, 0, 190, 557, 558, + 191, 0, 559, 560, 0, 561, 0, 194, 562, 195, + 563, 564, 565, 0, 566, 0, 0, 567, 568, 569, + 0, 0, 196, 0, 0, 0, 200, 570, 571, 572, + 573, 574, 575, 576, 0, 577, 201, 578, 202, 579, + 580, 581, 0, 582, 583, 584, 585, 586, 587, 588, + 204, 589, 590, 591, 592, 0, 593, 594, 595, 596, + 597, 598, 599, 600, 601, 602, 0, 603, 604, 0, + 605, 606, 212, 607, 608, 609, 610, 611, 612, 613, + 614, 0, 615, 616, 617, 618, 619, 0, 620, 217, + 621, 622, 0, 623, 220, 624, 0, 625, 626, 627, + 628, 629, 630, 631, 632, 633, 634, 222, 0, 635, + 636, 0, 637, 638, 639, 640, 641, 642, 0, 224, + 225, 0, 0, 644, 226, 645, 227, 0, 646, 647, + 648, 649, 650, 651, 652, 0, 0, 653, 654, 655, + 656, 657, 0, 0, 658, 659, 660, 661, 662, 663, + 234, 0, 664, 0, 665, 666, 667, 0, 0, 668, + 0, 0, 669, 670, 671, 672, 673, 237, 238, 239, + 240, 241, 242, 243, 244, 245, 674, 675, 676, 86, + 87, 88, 412, 90, 91, 92, 413, 0, 414, 95, + 0, 0, 98, 99, 100, 101, 102, 103, 0, 104, + 105, 415, 0, 0, 107, 108, 109, 110, 0, 0, + 112, 113, 114, 115, 0, 116, 0, 0, 416, 417, + 0, 0, 0, 418, 419, 0, 0, 0, 0, 420, + 0, 0, 0, 0, 0, 0, 0, 0, 421, 0, + 422, 0, 423, 424, 35, 0, 0, 0, 0, 0, + 0, 0, 41, 42, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 426, 427, 428, 429, 430, 431, + 432, 433, 0, 434, 435, 436, 0, 0, 0, 0, + 0, 0, 0, 437, 438, 0, 439, 440, 0, 441, + 442, 443, 135, 136, 0, 138, 139, 0, 444, 445, + 446, 447, 448, 0, 0, 449, 450, 451, 140, 452, + 0, 453, 454, 455, 456, 144, 0, 0, 0, 457, + 458, 459, 460, 0, 461, 462, 0, 463, 464, 465, + 466, 467, 468, 0, 0, 469, 0, 0, 0, 0, + 0, 0, 0, 0, 470, 471, 472, 473, 474, 475, + 155, 156, 476, 0, 477, 0, 478, 479, 480, 481, + 482, 0, 483, 484, 485, 0, 0, 486, 487, 488, + 489, 490, 0, 491, 492, 493, 0, 494, 495, 0, + 496, 497, 498, 499, 164, 500, 501, 502, 166, 0, + 503, 0, 504, 168, 505, 0, 506, 0, 507, 0, + 0, 0, 508, 509, 510, 0, 511, 172, 0, 512, + 0, 513, 514, 515, 516, 517, 0, 518, 519, 520, + 0, 521, 522, 523, 524, 525, 526, 0, 527, 0, + 175, 0, 528, 529, 530, 0, 176, 0, 177, 0, + 531, 0, 0, 532, 0, 533, 534, 535, 536, 537, + 538, 539, 0, 540, 181, 0, 541, 0, 0, 542, + 543, 544, 0, 0, 545, 546, 1282, 548, 549, 550, + 551, 552, 553, 554, 555, 556, 188, 0, 190, 557, + 558, 191, 0, 559, 560, 0, 561, 0, 194, 562, + 195, 563, 564, 565, 0, 566, 0, 0, 567, 568, + 569, 0, 0, 196, 0, 0, 0, 200, 570, 571, + 572, 573, 574, 575, 576, 0, 577, 201, 578, 202, + 579, 580, 581, 0, 582, 583, 584, 585, 586, 587, + 588, 204, 589, 590, 591, 592, 0, 593, 594, 595, + 596, 597, 598, 599, 600, 601, 602, 0, 603, 604, + 0, 605, 606, 212, 607, 608, 609, 610, 611, 612, + 613, 614, 0, 615, 616, 617, 618, 619, 0, 620, + 217, 621, 622, 0, 623, 220, 624, 0, 625, 626, + 627, 628, 629, 630, 631, 632, 633, 634, 222, 0, + 635, 636, 0, 637, 638, 639, 640, 641, 642, 0, + 224, 225, 0, 0, 644, 226, 645, 227, 0, 646, + 647, 648, 649, 650, 651, 652, 0, 0, 653, 654, + 655, 656, 657, 0, 0, 658, 659, 660, 661, 662, + 663, 234, 0, 664, 0, 665, 666, 667, 0, 0, + 668, 0, 0, 669, 670, 671, 672, 673, 237, 238, + 239, 240, 241, 242, 243, 244, 245, 674, 675, 676, + 86, 87, 88, 412, 90, 91, 92, 413, 0, 414, + 95, 0, 0, 98, 99, 100, 101, 102, 103, 0, + 104, 105, 415, 0, 0, 107, 108, 109, 110, 0, + 0, 112, 113, 114, 115, 0, 116, 0, 0, 416, + 417, 0, 0, 0, 418, 419, 0, 0, 0, 0, + 420, 0, 0, 0, 0, 0, 0, 0, 0, 421, + 0, 422, 0, 423, 424, 35, 0, 0, 0, 0, + 0, 0, 0, 41, 42, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 426, 427, 428, 429, 430, + 431, 432, 433, 0, 434, 435, 436, 0, 0, 0, + 0, 0, 0, 0, 437, 438, 0, 439, 440, 0, + 441, 442, 443, 135, 136, 0, 138, 139, 0, 444, + 445, 446, 447, 448, 0, 0, 449, 450, 451, 140, + 452, 0, 453, 454, 455, 456, 144, 0, 0, 0, + 457, 458, 459, 460, 0, 461, 462, 0, 463, 464, + 465, 466, 467, 468, 0, 0, 469, 0, 0, 0, + 0, 0, 0, 0, 0, 470, 471, 472, 473, 474, + 475, 155, 156, 476, 0, 477, 0, 478, 479, 480, + 481, 482, 0, 483, 484, 485, 0, 0, 486, 487, + 488, 489, 490, 0, 491, 492, 493, 0, 494, 495, + 0, 496, 497, 498, 499, 164, 500, 501, 502, 166, + 0, 503, 0, 504, 168, 505, 0, 506, 0, 507, + 0, 0, 0, 508, 509, 510, 0, 511, 172, 0, + 512, 0, 513, 514, 515, 516, 1312, 0, 518, 519, + 520, 0, 521, 522, 523, 524, 525, 526, 0, 527, + 0, 175, 0, 528, 529, 530, 0, 176, 0, 177, + 0, 531, 0, 0, 532, 0, 533, 534, 535, 536, + 537, 538, 539, 0, 540, 181, 0, 541, 0, 0, + 542, 543, 544, 0, 0, 545, 546, 547, 548, 549, + 550, 551, 552, 553, 554, 555, 556, 188, 0, 190, + 557, 558, 191, 0, 559, 560, 0, 561, 0, 194, + 562, 195, 563, 564, 565, 0, 566, 0, 0, 567, + 568, 569, 0, 0, 196, 0, 0, 0, 200, 570, + 571, 572, 573, 574, 575, 576, 0, 577, 201, 578, + 202, 579, 580, 581, 0, 582, 583, 584, 585, 586, + 587, 588, 204, 589, 590, 591, 592, 0, 593, 594, + 595, 596, 597, 598, 599, 600, 601, 602, 0, 603, + 604, 0, 605, 606, 212, 607, 608, 609, 610, 611, + 612, 613, 614, 0, 615, 616, 617, 618, 619, 0, + 620, 217, 621, 622, 0, 623, 220, 624, 0, 625, + 626, 627, 628, 629, 630, 631, 632, 633, 634, 222, + 0, 635, 636, 0, 637, 638, 639, 640, 641, 642, + 0, 224, 225, 0, 0, 644, 226, 645, 227, 0, + 646, 647, 648, 649, 650, 651, 652, 0, 0, 653, + 654, 655, 656, 657, 0, 0, 658, 659, 660, 661, + 662, 663, 234, 0, 664, 0, 665, 666, 667, 0, + 0, 668, 0, 0, 669, 670, 671, 672, 673, 237, + 238, 239, 240, 241, 242, 243, 244, 245, 674, 675, + 676, 86, 87, 88, 412, 90, 91, 92, 413, 0, + 414, 95, 0, 0, 98, 99, 100, 101, 102, 103, + 0, 104, 105, 415, 0, 0, 107, 108, 109, 110, + 0, 0, 112, 113, 114, 115, 0, 116, 0, 0, + 416, 417, 0, 0, 0, 418, 419, 0, 0, 0, + 0, 420, 0, 0, 0, 0, 0, 0, 0, 0, + 421, 0, 422, 0, 423, 424, 35, 0, 0, 0, + 0, 0, 0, 0, 41, 42, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 426, 427, 428, 429, + 430, 431, 432, 433, 0, 434, 435, 436, 0, 0, + 0, 0, 0, 0, 0, 437, 438, 0, 439, 440, + 0, 441, 442, 443, 135, 136, 0, 138, 139, 0, + 444, 445, 446, 447, 448, 0, 0, 449, 450, 451, + 140, 452, 0, 453, 454, 455, 456, 144, 0, 0, + 0, 457, 458, 459, 460, 0, 461, 462, 0, 463, + 464, 465, 466, 467, 468, 0, 0, 469, 0, 0, + 0, 0, 0, 0, 0, 0, 470, 471, 472, 473, + 474, 475, 155, 156, 476, 0, 477, 0, 478, 479, + 480, 481, 482, 0, 483, 484, 485, 0, 0, 486, + 487, 488, 489, 490, 0, 491, 492, 493, 0, 494, + 495, 0, 496, 497, 498, 499, 164, 500, 501, 502, + 166, 0, 503, 0, 504, 168, 505, 0, 506, 0, + 507, 0, 0, 0, 508, 509, 510, 0, 511, 172, + 0, 512, 0, 513, 514, 515, 516, 1318, 0, 518, + 519, 520, 0, 521, 522, 523, 524, 525, 526, 0, + 527, 0, 175, 0, 528, 529, 530, 0, 176, 0, + 177, 0, 531, 0, 0, 532, 0, 533, 534, 535, + 536, 537, 538, 539, 0, 540, 181, 0, 541, 0, + 0, 542, 543, 544, 0, 0, 545, 546, 547, 548, + 549, 550, 551, 552, 553, 554, 555, 556, 188, 0, + 190, 557, 558, 191, 0, 559, 560, 0, 561, 0, + 194, 562, 195, 563, 564, 565, 0, 566, 0, 0, + 567, 568, 569, 0, 0, 196, 0, 0, 0, 200, + 570, 571, 572, 573, 574, 575, 576, 0, 577, 201, + 578, 202, 579, 580, 581, 0, 582, 583, 584, 585, + 586, 587, 588, 204, 589, 590, 591, 592, 0, 593, + 594, 595, 596, 597, 598, 599, 600, 601, 602, 0, + 603, 604, 0, 605, 606, 212, 607, 608, 609, 610, + 611, 612, 613, 614, 0, 615, 616, 617, 618, 619, + 0, 620, 217, 621, 622, 0, 623, 220, 624, 0, + 625, 626, 627, 628, 629, 630, 631, 632, 633, 634, + 222, 0, 635, 636, 0, 637, 638, 639, 640, 641, + 642, 0, 224, 225, 0, 0, 644, 226, 645, 227, + 0, 646, 647, 648, 649, 650, 651, 652, 0, 0, + 653, 654, 655, 656, 657, 0, 0, 658, 659, 660, + 661, 662, 663, 234, 0, 664, 0, 665, 666, 667, + 0, 0, 668, 0, 0, 669, 670, 671, 672, 673, + 237, 238, 239, 240, 241, 242, 243, 244, 245, 674, + 675, 676, 86, 87, 88, 412, 90, 91, 92, 413, + 0, 414, 95, 0, 0, 98, 99, 100, 101, 102, + 103, 0, 104, 105, 415, 0, 0, 107, 108, 109, + 110, 0, 0, 112, 113, 114, 115, 0, 116, 0, + 0, 416, 417, 0, 0, 0, 418, 419, 0, 0, + 0, 0, 420, 0, 0, 0, 0, 0, 0, 0, + 0, 421, 0, 422, 0, 423, 424, 35, 0, 0, + 0, 0, 0, 0, 0, 41, 42, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 426, 427, 428, + 429, 430, 431, 432, 433, 0, 434, 435, 436, 0, + 0, 0, 0, 0, 0, 0, 437, 438, 0, 439, + 440, 0, 441, 442, 443, 135, 136, 0, 138, 139, + 0, 444, 445, 446, 447, 448, 0, 0, 449, 450, + 451, 140, 452, 0, 453, 454, 455, 456, 144, 0, + 0, 0, 457, 458, 459, 460, 0, 461, 462, 0, + 463, 464, 465, 466, 467, 468, 0, 0, 469, 0, + 0, 0, 0, 0, 0, 0, 0, 470, 471, 472, + 473, 474, 475, 155, 156, 476, 0, 477, 0, 478, + 479, 480, 481, 482, 0, 483, 484, 485, 0, 0, + 486, 487, 488, 489, 490, 0, 491, 492, 493, 0, + 494, 495, 0, 496, 497, 498, 499, 164, 500, 501, + 502, 166, 0, 503, 0, 504, 168, 505, 0, 506, + 0, 507, 0, 0, 0, 508, 509, 510, 0, 511, + 172, 0, 512, 0, 513, 514, 515, 516, 1327, 0, + 518, 519, 520, 0, 521, 522, 523, 524, 525, 526, + 0, 527, 0, 175, 0, 528, 529, 530, 0, 176, + 0, 177, 0, 531, 0, 0, 532, 0, 533, 534, + 535, 536, 537, 538, 539, 0, 540, 181, 0, 541, + 0, 0, 542, 543, 544, 0, 0, 545, 546, 547, + 548, 549, 550, 551, 552, 553, 554, 555, 556, 188, + 0, 190, 557, 558, 191, 0, 559, 560, 0, 561, + 0, 194, 562, 195, 563, 564, 565, 0, 566, 0, + 0, 567, 568, 569, 0, 0, 196, 0, 0, 0, + 200, 570, 571, 572, 573, 574, 575, 576, 0, 577, + 201, 578, 202, 579, 580, 581, 0, 582, 583, 584, + 585, 586, 587, 588, 204, 589, 590, 591, 592, 0, + 593, 594, 595, 596, 597, 598, 599, 600, 601, 602, + 0, 603, 604, 0, 605, 606, 212, 607, 608, 609, + 610, 611, 612, 613, 614, 0, 615, 616, 617, 618, + 619, 0, 620, 217, 621, 622, 0, 623, 220, 624, + 0, 625, 626, 627, 628, 629, 630, 631, 632, 633, + 634, 222, 0, 635, 636, 0, 637, 638, 639, 640, + 641, 642, 0, 224, 225, 0, 0, 644, 226, 645, + 227, 0, 646, 647, 648, 649, 650, 651, 652, 0, + 0, 653, 654, 655, 656, 657, 0, 0, 658, 659, + 660, 661, 662, 663, 234, 0, 664, 0, 665, 666, + 667, 0, 0, 668, 0, 0, 669, 670, 671, 672, + 673, 237, 238, 239, 240, 241, 242, 243, 244, 245, + 674, 675, 676, 86, 87, 88, 412, 90, 91, 92, + 413, 0, 414, 95, 0, 0, 98, 99, 100, 101, + 102, 103, 0, 104, 105, 415, 0, 0, 107, 108, + 109, 110, 0, 0, 112, 113, 114, 115, 0, 116, + 0, 0, 416, 417, 0, 0, 0, 418, 419, 0, + 0, 0, 0, 420, 0, 0, 0, 0, 0, 0, + 0, 0, 421, 0, 422, 0, 423, 424, 35, 0, + 0, 0, 0, 0, 0, 0, 41, 42, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 426, 427, + 428, 429, 430, 431, 432, 433, 0, 434, 435, 436, + 0, 0, 0, 0, 0, 0, 0, 437, 438, 0, + 439, 440, 0, 441, 442, 443, 135, 136, 0, 138, + 139, 0, 444, 445, 446, 447, 448, 0, 0, 449, + 450, 451, 140, 452, 0, 453, 454, 455, 456, 144, + 0, 0, 0, 457, 458, 459, 460, 0, 461, 462, + 0, 463, 464, 465, 466, 467, 468, 0, 0, 469, + 0, 0, 0, 0, 0, 0, 0, 0, 470, 471, + 472, 473, 474, 475, 155, 156, 476, 0, 477, 0, + 478, 479, 480, 481, 482, 0, 483, 484, 485, 0, + 0, 486, 487, 488, 489, 490, 0, 491, 492, 493, + 0, 494, 495, 0, 496, 497, 498, 499, 164, 500, + 501, 502, 166, 0, 503, 0, 504, 168, 505, 0, + 506, 0, 507, 0, 0, 0, 508, 509, 510, 0, + 511, 172, 0, 512, 0, 513, 514, 515, 516, 1329, + 0, 518, 519, 520, 0, 521, 522, 523, 524, 525, + 526, 0, 527, 0, 175, 0, 528, 529, 530, 0, + 176, 0, 177, 0, 531, 0, 0, 532, 0, 533, + 534, 535, 536, 537, 538, 539, 0, 540, 181, 0, + 541, 0, 0, 542, 543, 544, 0, 0, 545, 546, + 547, 548, 549, 550, 551, 552, 553, 554, 555, 556, + 188, 0, 190, 557, 558, 191, 0, 559, 560, 0, + 561, 0, 194, 562, 195, 563, 564, 565, 0, 566, + 0, 0, 567, 568, 569, 0, 0, 196, 0, 0, + 0, 200, 570, 571, 572, 573, 574, 575, 576, 0, + 577, 201, 578, 202, 579, 580, 581, 0, 582, 583, + 584, 585, 586, 587, 588, 204, 589, 590, 591, 592, + 0, 593, 594, 595, 596, 597, 598, 599, 600, 601, + 602, 0, 603, 604, 0, 605, 606, 212, 607, 608, + 609, 610, 611, 612, 613, 614, 0, 615, 616, 617, + 618, 619, 0, 620, 217, 621, 622, 0, 623, 220, + 624, 0, 625, 626, 627, 628, 629, 630, 631, 632, + 633, 634, 222, 0, 635, 636, 0, 637, 638, 639, + 640, 641, 642, 0, 224, 225, 0, 0, 644, 226, + 645, 227, 0, 646, 647, 648, 649, 650, 651, 652, + 0, 0, 653, 654, 655, 656, 657, 0, 0, 658, + 659, 660, 661, 662, 663, 234, 0, 664, 0, 665, + 666, 667, 0, 0, 668, 0, 0, 669, 670, 671, + 672, 673, 237, 238, 239, 240, 241, 242, 243, 244, + 245, 674, 675, 676, 86, 87, 88, 412, 90, 91, + 92, 413, 0, 414, 95, 0, 0, 98, 99, 100, + 101, 102, 103, 0, 104, 105, 415, 0, 0, 107, + 108, 109, 110, 0, 0, 112, 113, 114, 115, 0, + 116, 0, 0, 416, 417, 0, 0, 0, 418, 419, + 0, 0, 0, 0, 420, 0, 0, 0, 0, 0, + 0, 0, 0, 421, 0, 422, 0, 423, 424, 35, + 0, 0, 0, 0, 0, 0, 0, 41, 42, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 426, + 427, 428, 429, 430, 431, 432, 433, 0, 434, 435, + 436, 0, 0, 0, 0, 0, 0, 0, 437, 438, + 0, 439, 440, 0, 441, 442, 443, 135, 136, 0, + 138, 139, 0, 444, 445, 446, 447, 448, 0, 0, + 449, 450, 451, 140, 452, 0, 453, 454, 455, 456, + 144, 0, 0, 0, 457, 458, 459, 460, 0, 461, + 462, 0, 463, 464, 465, 466, 467, 468, 0, 0, + 469, 0, 0, 0, 0, 0, 0, 0, 0, 470, + 471, 472, 473, 474, 475, 155, 156, 476, 0, 477, + 0, 478, 479, 480, 481, 482, 0, 483, 484, 485, + 0, 0, 486, 487, 488, 489, 490, 0, 491, 492, + 493, 0, 494, 495, 0, 496, 497, 498, 499, 164, + 500, 501, 502, 166, 0, 503, 0, 504, 168, 505, + 0, 506, 0, 507, 0, 0, 0, 508, 509, 510, + 0, 511, 172, 0, 512, 0, 513, 514, 515, 516, + 1331, 0, 518, 519, 520, 0, 521, 522, 523, 524, + 525, 526, 0, 527, 0, 175, 0, 528, 529, 530, + 0, 176, 0, 177, 0, 531, 0, 0, 532, 0, + 533, 534, 535, 536, 537, 538, 539, 0, 540, 181, + 0, 541, 0, 0, 542, 543, 544, 0, 0, 545, + 546, 547, 548, 549, 550, 551, 552, 553, 554, 555, + 556, 188, 0, 190, 557, 558, 191, 0, 559, 560, + 0, 561, 0, 194, 562, 195, 563, 564, 565, 0, + 566, 0, 0, 567, 568, 569, 0, 0, 196, 0, + 0, 0, 200, 570, 571, 572, 573, 574, 575, 576, + 0, 577, 201, 578, 202, 579, 580, 581, 0, 582, + 583, 584, 585, 586, 587, 588, 204, 589, 590, 591, + 592, 0, 593, 594, 595, 596, 597, 598, 599, 600, + 601, 602, 0, 603, 604, 0, 605, 606, 212, 607, + 608, 609, 610, 611, 612, 613, 614, 0, 615, 616, + 617, 618, 619, 0, 620, 217, 621, 622, 0, 623, + 220, 624, 0, 625, 626, 627, 628, 629, 630, 631, + 632, 633, 634, 222, 0, 635, 636, 0, 637, 638, + 639, 640, 641, 642, 0, 224, 225, 0, 0, 644, + 226, 645, 227, 0, 646, 647, 648, 649, 650, 651, + 652, 0, 0, 653, 654, 655, 656, 657, 0, 0, + 658, 659, 660, 661, 662, 663, 234, 0, 664, 0, + 665, 666, 667, 0, 0, 668, 0, 0, 669, 670, + 671, 672, 673, 237, 238, 239, 240, 241, 242, 243, + 244, 245, 674, 675, 676, 86, 87, 88, 412, 90, + 91, 92, 413, 0, 414, 95, 0, 0, 98, 99, + 100, 101, 102, 103, 0, 104, 105, 415, 0, 0, + 107, 108, 109, 110, 0, 0, 112, 113, 114, 115, + 0, 116, 0, 0, 416, 417, 0, 0, 0, 418, + 419, 0, 0, 0, 0, 420, 0, 0, 0, 0, + 0, 0, 0, 0, 421, 0, 422, 0, 423, 424, + 35, 0, 0, 0, 0, 0, 0, 0, 41, 42, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 426, 427, 428, 429, 430, 431, 432, 433, 0, 434, + 435, 436, 0, 0, 0, 0, 0, 0, 0, 437, + 438, 0, 439, 440, 0, 441, 442, 443, 135, 136, + 0, 138, 139, 0, 444, 445, 446, 447, 448, 0, + 0, 449, 450, 451, 140, 452, 0, 453, 454, 455, + 456, 144, 0, 0, 0, 457, 458, 459, 460, 0, + 461, 462, 0, 463, 464, 465, 466, 467, 468, 0, + 0, 469, 0, 0, 0, 0, 0, 0, 0, 0, + 470, 471, 472, 473, 474, 475, 155, 156, 476, 0, + 477, 0, 478, 479, 480, 481, 482, 0, 483, 484, + 485, 0, 0, 486, 487, 488, 489, 490, 0, 491, + 492, 493, 0, 494, 495, 0, 496, 497, 498, 499, + 164, 500, 501, 502, 166, 0, 503, 0, 504, 168, + 505, 0, 506, 0, 507, 0, 0, 0, 508, 509, + 510, 0, 511, 172, 0, 512, 0, 513, 514, 515, + 516, 1333, 0, 518, 519, 520, 0, 521, 522, 523, + 524, 525, 526, 0, 527, 0, 175, 0, 528, 529, + 530, 0, 176, 0, 177, 0, 531, 0, 0, 532, + 0, 533, 534, 535, 536, 537, 538, 539, 0, 540, + 181, 0, 541, 0, 0, 542, 543, 544, 0, 0, + 545, 546, 547, 548, 549, 550, 551, 552, 553, 554, + 555, 556, 188, 0, 190, 557, 558, 191, 0, 559, + 560, 0, 561, 0, 194, 562, 195, 563, 564, 565, + 0, 566, 0, 0, 567, 568, 569, 0, 0, 196, + 0, 0, 0, 200, 570, 571, 572, 573, 574, 575, + 576, 0, 577, 201, 578, 202, 579, 580, 581, 0, + 582, 583, 584, 585, 586, 587, 588, 204, 589, 590, + 591, 592, 0, 593, 594, 595, 596, 597, 598, 599, + 600, 601, 602, 0, 603, 604, 0, 605, 606, 212, + 607, 608, 609, 610, 611, 612, 613, 614, 0, 615, + 616, 617, 618, 619, 0, 620, 217, 621, 622, 0, + 623, 220, 624, 0, 625, 626, 627, 628, 629, 630, + 631, 632, 633, 634, 222, 0, 635, 636, 0, 637, + 638, 639, 640, 641, 642, 0, 224, 225, 0, 0, + 644, 226, 645, 227, 0, 646, 647, 648, 649, 650, + 651, 652, 0, 0, 653, 654, 655, 656, 657, 0, + 0, 658, 659, 660, 661, 662, 663, 234, 0, 664, + 0, 665, 666, 667, 0, 0, 668, 0, 0, 669, + 670, 671, 672, 673, 237, 238, 239, 240, 241, 242, + 243, 244, 245, 674, 675, 676, 86, 87, 88, 412, + 90, 91, 92, 413, 0, 414, 95, 0, 0, 98, + 99, 100, 101, 102, 103, 0, 104, 105, 415, 0, + 0, 107, 108, 109, 110, 0, 0, 112, 113, 114, + 115, 0, 116, 0, 0, 416, 417, 0, 0, 0, + 418, 419, 0, 0, 0, 0, 420, 0, 0, 0, + 0, 0, 0, 0, 0, 421, 0, 422, 0, 423, + 424, 35, 0, 0, 0, 0, 0, 0, 0, 41, + 42, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 426, 427, 428, 429, 430, 431, 432, 433, 0, + 434, 435, 436, 0, 0, 0, 0, 0, 0, 0, + 437, 438, 0, 439, 440, 0, 441, 442, 443, 135, + 136, 0, 138, 139, 0, 444, 445, 446, 447, 448, + 0, 0, 449, 450, 451, 140, 452, 0, 453, 454, + 455, 456, 144, 0, 0, 0, 457, 458, 459, 460, + 0, 461, 462, 0, 463, 464, 465, 466, 467, 468, + 0, 0, 469, 0, 0, 0, 0, 0, 0, 0, + 0, 470, 471, 472, 473, 474, 475, 155, 156, 476, + 0, 477, 0, 478, 479, 480, 481, 482, 0, 483, + 484, 485, 0, 0, 486, 487, 488, 489, 490, 0, + 491, 492, 493, 0, 494, 495, 0, 496, 497, 498, + 499, 164, 500, 501, 502, 166, 0, 503, 0, 504, + 168, 505, 0, 506, 0, 507, 0, 0, 0, 508, + 509, 510, 0, 511, 172, 0, 512, 0, 513, 514, + 515, 516, 1336, 0, 518, 519, 520, 0, 521, 522, + 523, 524, 525, 526, 0, 527, 0, 175, 0, 528, + 529, 530, 0, 176, 0, 177, 0, 531, 0, 0, + 532, 0, 533, 534, 535, 536, 537, 538, 539, 0, + 540, 181, 0, 541, 0, 0, 542, 543, 544, 0, + 0, 545, 546, 547, 548, 549, 550, 551, 552, 553, + 554, 555, 556, 188, 0, 190, 557, 558, 191, 0, + 559, 560, 0, 561, 0, 194, 562, 195, 563, 564, + 565, 0, 566, 0, 0, 567, 568, 569, 0, 0, + 196, 0, 0, 0, 200, 570, 571, 572, 573, 574, + 575, 576, 0, 577, 201, 578, 202, 579, 580, 581, + 0, 582, 583, 584, 585, 586, 587, 588, 204, 589, + 590, 591, 592, 0, 593, 594, 595, 596, 597, 598, + 599, 600, 601, 602, 0, 603, 604, 0, 605, 606, + 212, 607, 608, 609, 610, 611, 612, 613, 614, 0, + 615, 616, 617, 618, 619, 0, 620, 217, 621, 622, + 0, 623, 220, 624, 0, 625, 626, 627, 628, 629, + 630, 631, 632, 633, 634, 222, 0, 635, 636, 0, + 637, 638, 639, 640, 641, 642, 0, 224, 225, 0, + 0, 644, 226, 645, 227, 0, 646, 647, 648, 649, + 650, 651, 652, 0, 0, 653, 654, 655, 656, 657, + 0, 0, 658, 659, 660, 661, 662, 663, 234, 0, + 664, 0, 665, 666, 667, 0, 0, 668, 0, 0, + 669, 670, 671, 672, 673, 237, 238, 239, 240, 241, + 242, 243, 244, 245, 674, 675, 676, 86, 87, 88, + 412, 90, 91, 92, 413, 0, 414, 95, 0, 0, + 98, 99, 100, 101, 102, 103, 0, 104, 105, 415, + 0, 0, 107, 108, 109, 110, 0, 0, 112, 113, + 114, 115, 0, 116, 0, 0, 416, 417, 0, 0, + 0, 418, 419, 0, 0, 0, 0, 420, 0, 0, + 0, 0, 0, 0, 0, 0, 421, 0, 422, 0, + 423, 424, 35, 0, 0, 0, 0, 0, 0, 0, + 41, 42, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 426, 427, 428, 429, 430, 431, 432, 433, + 0, 434, 435, 436, 0, 0, 0, 0, 0, 0, + 0, 437, 438, 0, 439, 440, 0, 441, 442, 443, + 135, 136, 0, 138, 139, 0, 444, 445, 446, 447, + 448, 0, 0, 449, 450, 451, 140, 452, 0, 453, + 454, 455, 456, 144, 0, 0, 0, 457, 458, 459, + 460, 0, 461, 462, 0, 463, 464, 465, 466, 467, + 468, 0, 0, 469, 0, 0, 0, 0, 0, 0, + 0, 0, 470, 471, 472, 473, 474, 475, 155, 156, + 476, 0, 477, 0, 478, 479, 480, 481, 482, 0, + 483, 484, 485, 0, 0, 486, 487, 488, 489, 490, + 0, 491, 492, 493, 0, 494, 495, 0, 496, 497, + 498, 499, 164, 500, 501, 502, 166, 0, 503, 0, + 504, 168, 505, 0, 506, 0, 507, 0, 0, 0, + 508, 509, 510, 0, 511, 172, 0, 512, 0, 513, + 514, 515, 516, 1338, 0, 518, 519, 520, 0, 521, + 522, 523, 524, 525, 526, 0, 527, 0, 175, 0, + 528, 529, 530, 0, 176, 0, 177, 0, 531, 0, + 0, 532, 0, 533, 534, 535, 536, 537, 538, 539, + 0, 540, 181, 0, 541, 0, 0, 542, 543, 544, + 0, 0, 545, 546, 1339, 548, 549, 550, 551, 552, + 553, 554, 555, 556, 188, 0, 190, 557, 558, 191, + 0, 559, 560, 0, 561, 0, 194, 562, 195, 563, + 564, 565, 0, 566, 0, 0, 567, 568, 569, 0, + 0, 196, 0, 0, 0, 200, 570, 571, 572, 573, + 574, 575, 576, 0, 577, 201, 578, 202, 579, 580, + 581, 0, 582, 583, 584, 585, 586, 587, 588, 204, + 589, 590, 591, 592, 0, 593, 594, 595, 596, 597, + 598, 599, 600, 601, 602, 0, 603, 604, 0, 605, + 606, 212, 607, 608, 609, 610, 611, 612, 613, 614, + 0, 615, 616, 617, 618, 619, 0, 620, 217, 621, + 622, 0, 623, 220, 624, 0, 625, 626, 627, 628, + 629, 630, 631, 632, 633, 634, 222, 0, 635, 636, + 0, 637, 638, 639, 640, 641, 642, 0, 224, 225, + 0, 0, 644, 226, 645, 227, 0, 646, 647, 648, + 649, 650, 651, 652, 0, 0, 653, 654, 655, 656, + 657, 0, 0, 658, 659, 660, 661, 662, 663, 234, + 0, 664, 0, 665, 666, 667, 0, 0, 668, 0, + 0, 669, 670, 671, 672, 673, 237, 238, 239, 240, + 241, 242, 243, 244, 245, 674, 675, 676, 86, 87, + 88, 412, 90, 91, 92, 413, 0, 414, 95, 0, + 0, 98, 99, 100, 101, 102, 103, 0, 104, 105, + 415, 0, 0, 107, 108, 109, 110, 0, 0, 112, + 113, 114, 115, 0, 116, 0, 0, 416, 417, 0, + 0, 0, 418, 419, 0, 0, 0, 0, 420, 0, + 0, 0, 0, 0, 0, 0, 0, 421, 0, 422, + 0, 423, 424, 35, 0, 0, 0, 0, 0, 0, + 0, 41, 42, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 426, 427, 428, 429, 430, 431, 432, + 433, 0, 434, 435, 436, 0, 0, 0, 0, 0, + 0, 0, 437, 438, 0, 439, 440, 0, 441, 442, + 443, 135, 136, 0, 138, 139, 0, 444, 445, 446, + 447, 448, 0, 0, 449, 450, 451, 140, 452, 0, + 453, 454, 455, 456, 144, 0, 0, 0, 457, 458, + 459, 460, 0, 461, 462, 0, 463, 464, 465, 466, + 467, 468, 0, 0, 469, 0, 0, 0, 0, 0, + 0, 0, 0, 470, 471, 472, 473, 474, 475, 155, + 156, 476, 0, 477, 0, 478, 479, 480, 481, 482, + 0, 483, 484, 485, 0, 0, 486, 487, 488, 489, + 490, 0, 491, 492, 493, 0, 494, 495, 0, 496, + 497, 498, 499, 164, 500, 501, 502, 166, 0, 503, + 0, 504, 168, 505, 0, 506, 0, 507, 0, 0, + 0, 508, 509, 510, 0, 511, 172, 0, 512, 0, + 513, 514, 515, 516, 1342, 0, 518, 519, 520, 0, + 521, 522, 523, 524, 525, 526, 0, 527, 0, 175, + 0, 528, 529, 530, 0, 176, 0, 177, 0, 531, + 0, 0, 532, 0, 533, 534, 535, 536, 537, 538, + 539, 0, 540, 181, 0, 541, 0, 0, 542, 543, + 544, 0, 0, 545, 546, 547, 548, 549, 550, 551, + 552, 553, 554, 555, 556, 188, 0, 190, 557, 558, + 191, 0, 559, 560, 0, 561, 0, 194, 562, 195, + 563, 564, 565, 0, 566, 0, 0, 567, 568, 569, + 0, 0, 196, 0, 0, 0, 200, 570, 571, 572, + 573, 574, 575, 576, 0, 577, 201, 578, 202, 579, + 580, 581, 0, 582, 583, 584, 585, 586, 587, 588, + 204, 589, 590, 591, 592, 0, 593, 594, 595, 596, + 597, 598, 599, 600, 601, 602, 0, 603, 604, 0, + 605, 606, 212, 607, 608, 609, 610, 611, 612, 613, + 614, 0, 615, 616, 617, 618, 619, 0, 620, 217, + 621, 622, 0, 623, 220, 624, 0, 625, 626, 627, + 628, 629, 630, 631, 632, 633, 634, 222, 0, 635, + 636, 0, 637, 638, 639, 640, 641, 642, 0, 224, + 225, 0, 0, 644, 226, 645, 227, 0, 646, 647, + 648, 649, 650, 651, 652, 0, 0, 653, 654, 655, + 656, 657, 0, 0, 658, 659, 660, 661, 662, 663, + 234, 0, 664, 0, 665, 666, 667, 0, 0, 668, + 0, 0, 669, 670, 671, 672, 673, 237, 238, 239, + 240, 241, 242, 243, 244, 245, 674, 675, 676, 86, + 87, 88, 412, 90, 91, 92, 413, 0, 414, 95, + 0, 0, 98, 99, 100, 101, 102, 103, 0, 104, + 105, 415, 0, 0, 107, 108, 109, 110, 0, 0, + 112, 113, 114, 115, 0, 116, 0, 0, 416, 417, + 0, 0, 0, 418, 419, 0, 0, 0, 0, 420, + 0, 0, 0, 0, 0, 0, 0, 0, 421, 0, + 422, 0, 423, 424, 35, 0, 0, 0, 0, 0, + 0, 0, 41, 42, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 426, 427, 428, 429, 430, 431, + 432, 433, 0, 434, 435, 436, 0, 0, 0, 0, + 0, 0, 0, 437, 438, 0, 439, 440, 1554, 441, + 442, 443, 135, 136, 0, 138, 139, 0, 444, 445, + 446, 447, 448, 0, 0, 1039, 450, 1013, 140, 1555, + 0, 453, 454, 455, 456, 144, 0, 0, 0, 457, + 458, 459, 460, 0, 461, 0, 0, 463, 464, 465, + 466, 467, 468, 0, 0, 469, 0, 0, 0, 0, + 0, 0, 0, 0, 470, 471, 472, 473, 474, 475, + 155, 156, 476, 0, 477, 0, 478, 479, 480, 481, + 482, 0, 483, 484, 485, 0, 0, 486, 487, 488, + 489, 490, 0, 491, 492, 493, 0, 494, 495, 0, + 496, 497, 498, 499, 164, 500, 501, 502, 166, 0, + 503, 0, 504, 168, 505, 0, 506, 0, 507, 0, + 0, 0, 508, 509, 510, 0, 511, 172, 0, 512, + 0, 513, 514, 515, 516, 517, 0, 518, 519, 520, + 0, 521, 522, 523, 524, 525, 526, 0, 527, 0, + 175, 0, 528, 529, 530, 0, 176, 0, 177, 0, + 531, 0, 0, 532, 0, 533, 534, 535, 536, 537, + 538, 539, 0, 540, 181, 0, 541, 0, 0, 542, + 543, 544, 0, 0, 545, 546, 547, 548, 549, 550, + 551, 552, 553, 554, 555, 1043, 188, 0, 190, 557, + 558, 191, 0, 559, 560, 0, 561, 0, 194, 562, + 195, 563, 564, 565, 0, 566, 0, 0, 567, 568, + 569, 0, 0, 196, 0, 0, 0, 200, 570, 571, + 572, 573, 574, 575, 576, 0, 577, 201, 578, 202, + 579, 580, 581, 0, 582, 583, 584, 585, 586, 587, + 588, 204, 589, 590, 591, 592, 0, 593, 594, 595, + 596, 597, 598, 599, 600, 601, 602, 0, 603, 604, + 0, 1044, 606, 212, 607, 608, 609, 1045, 611, 612, + 613, 614, 0, 615, 616, 617, 618, 1547, 0, 620, + 217, 621, 622, 0, 623, 220, 624, 0, 625, 626, + 627, 628, 629, 630, 631, 632, 633, 634, 222, 0, + 635, 636, 0, 637, 638, 639, 640, 641, 642, 0, + 1047, 225, 0, 0, 1048, 226, 645, 227, 0, 646, + 647, 648, 649, 650, 651, 652, 0, 0, 653, 654, + 655, 656, 657, 0, 0, 658, 659, 660, 661, 662, + 1017, 234, 0, 664, 0, 665, 666, 667, 0, 0, + 668, 0, 0, 669, 670, 671, 672, 1049, 237, 238, + 239, 240, 241, 242, 243, 244, 245, 674, 675, 676, + 1679, 87, 88, 412, 90, 91, 92, 413, 0, 414, + 95, 0, 0, 98, 99, 100, 101, 102, 103, 0, + 104, 105, 415, 0, 0, 107, 108, 109, 110, 0, + 0, 112, 113, 114, 115, 0, 116, 0, 0, 416, + 417, 0, 0, 0, 418, 419, 0, 0, 0, 0, + 420, 0, 0, 0, 0, 0, 0, 0, 0, 421, + 0, 422, 0, 423, 424, 35, 0, 0, 0, 0, + 0, 0, 0, 41, 42, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 426, 427, 428, 429, 430, + 431, 432, 433, 0, 434, 435, 436, 0, 0, 0, + 0, 0, 0, 0, 437, 438, 0, 439, 440, 0, + 441, 442, 443, 135, 136, 0, 138, 139, 0, 444, + 445, 446, 447, 448, 0, 0, 449, 450, 451, 140, + 452, 0, 453, 454, 455, 456, 144, 0, 0, 0, + 457, 458, 459, 460, 0, 461, 462, 0, 463, 464, + 465, 466, 467, 468, 0, 0, 469, 0, 0, 0, + 0, 0, 0, 0, 0, 470, 471, 472, 473, 474, + 475, 155, 156, 476, 0, 477, 0, 478, 479, 480, + 481, 482, 0, 483, 484, 485, 0, 0, 486, 487, + 488, 489, 490, 0, 491, 492, 493, 0, 494, 495, + 0, 496, 497, 498, 499, 164, 500, 501, 502, 166, + 0, 503, 0, 504, 168, 505, 0, 506, 0, 507, + 0, 0, 0, 508, 509, 510, 0, 511, 172, 0, + 512, 0, 513, 514, 515, 516, 517, 0, 518, 519, + 520, 0, 521, 522, 523, 524, 525, 526, 0, 527, + 0, 175, 0, 528, 529, 530, 0, 176, 0, 177, + 0, 531, 0, 0, 532, 0, 533, 534, 535, 536, + 537, 538, 539, 0, 540, 181, 0, 541, 0, 0, + 542, 543, 544, 0, 0, 545, 546, 547, 548, 549, + 550, 551, 552, 553, 554, 555, 556, 188, 0, 190, + 557, 558, 191, 0, 559, 560, 0, 561, 0, 194, + 562, 195, 563, 564, 565, 0, 566, 0, 0, 567, + 568, 569, 0, 0, 196, 0, 0, 0, 200, 570, + 571, 572, 573, 574, 575, 576, 0, 577, 201, 578, + 202, 579, 580, 581, 0, 582, 583, 584, 585, 586, + 587, 588, 204, 589, 590, 591, 592, 0, 593, 594, + 595, 596, 597, 598, 599, 600, 601, 602, 0, 603, + 604, 0, 605, 606, 212, 607, 608, 609, 610, 611, + 612, 613, 614, 0, 615, 616, 617, 618, 619, 0, + 620, 217, 621, 622, 0, 623, 220, 624, 0, 625, + 626, 627, 628, 629, 630, 631, 632, 633, 634, 222, + 0, 635, 636, 0, 637, 638, 639, 640, 641, 642, + 0, 224, 225, 0, 0, 644, 226, 645, 227, 0, + 646, 647, 648, 649, 650, 651, 652, 0, 0, 653, + 654, 655, 656, 657, 0, 0, 658, 659, 660, 661, + 662, 663, 234, 0, 664, 0, 665, 666, 667, 0, + 0, 668, 0, 0, 669, 670, 671, 672, 673, 237, + 238, 239, 240, 241, 242, 243, 244, 245, 674, 675, + 676, 86, 87, 88, 412, 90, 91, 92, 413, 0, + 414, 95, 0, 0, 98, 99, 100, 101, 102, 103, + 0, 104, 105, 415, 0, 0, 107, 108, 109, 110, + 0, 0, 112, 113, 114, 115, 0, 116, 0, 0, + 416, 417, 0, 0, 0, 418, 419, 0, 0, 0, + 0, 420, 0, 0, 0, 0, 0, 0, 0, 0, + 421, 0, 422, 0, 423, 424, 35, 0, 0, 0, + 0, 0, 0, 0, 41, 42, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 426, 427, 428, 429, + 430, 431, 432, 433, 0, 434, 435, 436, 0, 0, + 0, 0, 0, 0, 0, 437, 438, 0, 439, 440, + 0, 441, 442, 443, 135, 136, 0, 138, 139, 0, + 444, 445, 446, 447, 448, 0, 0, 449, 450, 451, + 140, 452, 0, 453, 454, 455, 456, 144, 0, 0, + 0, 457, 458, 459, 460, 0, 461, 462, 0, 463, + 464, 465, 466, 467, 468, 0, 0, 469, 0, 0, + 0, 0, 0, 0, 0, 0, 470, 471, 472, 473, + 474, 475, 155, 156, 476, 0, 477, 0, 478, 479, + 480, 481, 482, 0, 483, 484, 485, 0, 0, 486, + 487, 488, 489, 490, 0, 491, 492, 493, 0, 494, + 495, 0, 496, 497, 498, 499, 164, 500, 501, 502, + 166, 0, 503, 0, 504, 168, 505, 0, 506, 0, + 507, 0, 0, 0, 508, 509, 510, 0, 511, 172, + 0, 512, 0, 513, 514, 515, 516, 1903, 0, 518, + 519, 520, 0, 521, 522, 523, 524, 525, 526, 0, + 527, 0, 175, 0, 528, 529, 530, 0, 176, 0, + 177, 0, 531, 0, 0, 532, 0, 533, 534, 535, + 536, 537, 538, 539, 0, 540, 181, 0, 541, 0, + 0, 542, 543, 544, 0, 0, 545, 546, 547, 548, + 549, 550, 551, 552, 553, 554, 555, 556, 188, 0, + 190, 557, 558, 191, 0, 559, 560, 0, 561, 0, + 194, 562, 195, 563, 564, 565, 0, 566, 0, 0, + 567, 568, 569, 0, 0, 196, 0, 0, 0, 200, + 570, 571, 572, 573, 574, 575, 576, 0, 577, 201, + 578, 202, 579, 580, 581, 0, 582, 583, 584, 585, + 586, 587, 588, 204, 589, 590, 591, 592, 0, 593, + 594, 595, 596, 597, 598, 599, 600, 601, 602, 0, + 603, 604, 0, 605, 606, 212, 607, 608, 609, 610, + 611, 612, 613, 614, 0, 615, 616, 617, 618, 619, + 0, 620, 217, 621, 622, 0, 623, 220, 624, 0, + 625, 626, 627, 628, 629, 630, 631, 632, 633, 634, + 222, 0, 635, 636, 0, 637, 638, 639, 640, 641, + 642, 0, 224, 225, 0, 0, 644, 226, 645, 227, + 0, 646, 647, 648, 649, 650, 651, 652, 0, 0, + 653, 654, 655, 656, 657, 0, 0, 658, 659, 660, + 661, 662, 663, 234, 0, 664, 0, 665, 666, 667, + 0, 0, 668, 0, 0, 669, 670, 671, 672, 673, + 237, 238, 239, 240, 241, 242, 243, 244, 245, 674, + 675, 676, 86, 87, 88, 412, 90, 91, 92, 413, + 0, 414, 95, 0, 0, 98, 99, 100, 101, 102, + 103, 0, 104, 105, 415, 0, 0, 107, 108, 109, + 110, 0, 0, 112, 113, 114, 115, 0, 116, 0, + 0, 416, 417, 0, 0, 0, 418, 419, 0, 0, + 0, 0, 420, 0, 0, 0, 0, 0, 0, 0, + 0, 421, 0, 422, 0, 423, 424, 35, 0, 0, + 0, 0, 0, 0, 0, 41, 42, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 426, 427, 428, + 429, 430, 431, 432, 433, 0, 434, 435, 436, 0, + 0, 0, 0, 0, 0, 0, 437, 438, 0, 439, + 440, 0, 441, 442, 443, 135, 136, 0, 138, 139, + 0, 444, 445, 446, 447, 448, 0, 0, 449, 450, + 451, 140, 452, 0, 453, 454, 455, 456, 144, 0, + 0, 0, 457, 458, 459, 460, 0, 461, 462, 0, + 463, 464, 465, 466, 467, 468, 0, 0, 469, 0, + 0, 0, 0, 0, 0, 0, 0, 470, 471, 472, + 473, 474, 475, 155, 156, 476, 0, 477, 0, 478, + 479, 480, 481, 482, 0, 483, 484, 485, 0, 0, + 486, 487, 488, 489, 490, 0, 491, 492, 493, 0, + 494, 495, 0, 496, 497, 498, 499, 164, 500, 501, + 502, 166, 0, 503, 0, 504, 168, 505, 0, 506, + 0, 507, 0, 0, 0, 508, 509, 510, 0, 511, + 172, 0, 512, 0, 513, 514, 515, 516, 1930, 0, + 518, 519, 520, 0, 521, 522, 523, 524, 525, 526, + 0, 527, 0, 175, 0, 528, 529, 530, 0, 176, + 0, 177, 0, 531, 0, 0, 532, 0, 533, 534, + 535, 536, 537, 538, 539, 0, 540, 181, 0, 541, + 0, 0, 542, 543, 544, 0, 0, 545, 546, 547, + 548, 549, 550, 551, 552, 553, 554, 555, 556, 188, + 0, 190, 557, 558, 191, 0, 559, 560, 0, 561, + 0, 194, 562, 195, 563, 564, 565, 0, 566, 0, + 0, 567, 568, 569, 0, 0, 196, 0, 0, 0, + 200, 570, 571, 572, 573, 574, 575, 576, 0, 577, + 201, 578, 202, 579, 580, 581, 0, 582, 583, 584, + 585, 586, 587, 588, 204, 589, 590, 591, 592, 0, + 593, 594, 595, 596, 597, 598, 599, 600, 601, 602, + 0, 603, 604, 0, 605, 606, 212, 607, 608, 609, + 610, 611, 612, 613, 614, 0, 615, 616, 617, 618, + 619, 0, 620, 217, 621, 622, 0, 623, 220, 624, + 0, 625, 626, 627, 628, 629, 630, 631, 632, 633, + 634, 222, 0, 635, 636, 0, 637, 638, 639, 640, + 641, 642, 0, 224, 225, 0, 0, 644, 226, 645, + 227, 0, 646, 647, 648, 649, 650, 651, 652, 0, + 0, 653, 654, 655, 656, 657, 0, 0, 658, 659, + 660, 661, 662, 663, 234, 0, 664, 0, 665, 666, + 667, 0, 0, 668, 0, 0, 669, 670, 671, 672, + 673, 237, 238, 239, 240, 241, 242, 243, 244, 245, + 674, 675, 676, 86, 87, 88, 412, 90, 91, 92, + 413, 0, 414, 95, 0, 0, 98, 99, 100, 101, + 102, 103, 0, 104, 105, 415, 0, 0, 107, 108, + 109, 110, 0, 0, 112, 113, 114, 115, 0, 116, + 0, 0, 416, 417, 0, 0, 0, 418, 419, 0, + 0, 0, 0, 420, 0, 0, 0, 0, 0, 0, + 0, 0, 421, 0, 422, 0, 423, 424, 35, 0, + 0, 0, 0, 0, 0, 0, 41, 42, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 426, 427, + 428, 429, 430, 431, 432, 433, 0, 434, 435, 436, + 0, 0, 0, 0, 0, 0, 0, 437, 438, 0, + 439, 440, 0, 441, 442, 443, 135, 136, 0, 138, + 139, 0, 444, 445, 446, 447, 448, 0, 0, 449, + 450, 451, 140, 452, 0, 453, 454, 455, 456, 144, + 0, 0, 0, 457, 458, 459, 460, 0, 461, 462, + 0, 463, 464, 465, 466, 467, 468, 0, 0, 469, + 0, 0, 0, 0, 0, 0, 0, 0, 470, 471, + 472, 473, 474, 475, 155, 156, 476, 0, 477, 0, + 478, 479, 480, 481, 482, 0, 483, 484, 485, 0, + 0, 486, 487, 488, 489, 490, 0, 491, 492, 493, + 0, 494, 495, 0, 496, 497, 498, 499, 164, 500, + 501, 502, 166, 0, 503, 0, 504, 168, 505, 0, + 506, 0, 507, 0, 0, 0, 508, 509, 510, 0, + 511, 172, 0, 512, 0, 513, 514, 515, 516, 1964, + 0, 518, 519, 520, 0, 521, 522, 523, 524, 525, + 526, 0, 527, 0, 175, 0, 528, 529, 530, 0, + 176, 0, 177, 0, 531, 0, 0, 532, 0, 533, + 534, 535, 536, 537, 538, 539, 0, 540, 181, 0, + 541, 0, 0, 542, 543, 544, 0, 0, 545, 546, + 547, 548, 549, 550, 551, 552, 553, 554, 555, 556, + 188, 0, 190, 557, 558, 191, 0, 559, 560, 0, + 561, 0, 194, 562, 195, 563, 564, 565, 0, 566, + 0, 0, 567, 568, 569, 0, 0, 196, 0, 0, + 0, 200, 570, 571, 572, 573, 574, 575, 576, 0, + 577, 201, 578, 202, 579, 580, 581, 0, 582, 583, + 584, 585, 586, 587, 588, 204, 589, 590, 591, 592, + 0, 593, 594, 595, 596, 597, 598, 599, 600, 601, + 602, 0, 603, 604, 0, 605, 606, 212, 607, 608, + 609, 610, 611, 612, 613, 614, 0, 615, 616, 617, + 618, 619, 0, 620, 217, 621, 622, 0, 623, 220, + 624, 0, 625, 626, 627, 628, 629, 630, 631, 632, + 633, 634, 222, 0, 635, 636, 0, 637, 638, 639, + 640, 641, 642, 0, 224, 225, 0, 0, 644, 226, + 645, 227, 0, 646, 647, 648, 649, 650, 651, 652, + 0, 0, 653, 654, 655, 656, 657, 0, 0, 658, + 659, 660, 661, 662, 663, 234, 0, 664, 0, 665, + 666, 667, 0, 0, 668, 0, 0, 669, 670, 671, + 672, 673, 237, 238, 239, 240, 241, 242, 243, 244, + 245, 674, 675, 676, 86, 87, 88, 412, 90, 91, + 92, 413, 0, 414, 95, 0, 0, 98, 99, 100, + 101, 102, 103, 0, 104, 105, 415, 0, 0, 107, + 108, 109, 110, 0, 0, 112, 113, 114, 115, 0, + 116, 0, 0, 416, 417, 0, 0, 0, 418, 419, + 0, 0, 0, 0, 420, 0, 0, 0, 0, 0, + 0, 0, 0, 421, 0, 422, 0, 423, 424, 35, + 0, 0, 0, 0, 0, 0, 0, 41, 42, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 426, + 427, 428, 429, 430, 431, 432, 433, 0, 434, 435, + 436, 0, 0, 0, 0, 0, 0, 0, 437, 438, + 0, 439, 440, 0, 441, 442, 443, 135, 136, 0, + 138, 139, 0, 444, 445, 446, 447, 448, 0, 0, + 449, 450, 451, 140, 452, 0, 453, 454, 455, 456, + 144, 0, 0, 0, 457, 458, 459, 460, 0, 461, + 462, 0, 463, 464, 465, 466, 467, 468, 0, 0, + 469, 0, 0, 0, 0, 0, 0, 0, 0, 470, + 471, 472, 473, 474, 475, 155, 156, 476, 0, 477, + 0, 478, 479, 480, 481, 482, 0, 483, 484, 485, + 0, 0, 486, 487, 488, 489, 490, 0, 491, 492, + 493, 0, 494, 495, 0, 496, 497, 498, 499, 164, + 500, 501, 502, 166, 0, 503, 0, 504, 168, 505, + 0, 506, 0, 507, 0, 0, 0, 508, 509, 510, + 0, 511, 172, 0, 512, 0, 513, 514, 515, 516, + 1966, 0, 518, 519, 520, 0, 521, 522, 523, 524, + 525, 526, 0, 527, 0, 175, 0, 528, 529, 530, + 0, 176, 0, 177, 0, 531, 0, 0, 532, 0, + 533, 534, 535, 536, 537, 538, 539, 0, 540, 181, + 0, 541, 0, 0, 542, 543, 544, 0, 0, 545, + 546, 547, 548, 549, 550, 551, 552, 553, 554, 555, + 556, 188, 0, 190, 557, 558, 191, 0, 559, 560, + 0, 561, 0, 194, 562, 195, 563, 564, 565, 0, + 566, 0, 0, 567, 568, 569, 0, 0, 196, 0, + 0, 0, 200, 570, 571, 572, 573, 574, 575, 576, + 0, 577, 201, 578, 202, 579, 580, 581, 0, 582, + 583, 584, 585, 586, 587, 588, 204, 589, 590, 591, + 592, 0, 593, 594, 595, 596, 597, 598, 599, 600, + 601, 602, 0, 603, 604, 0, 605, 606, 212, 607, + 608, 609, 610, 611, 612, 613, 614, 0, 615, 616, + 617, 618, 619, 0, 620, 217, 621, 622, 0, 623, + 220, 624, 0, 625, 626, 627, 628, 629, 630, 631, + 632, 633, 634, 222, 0, 635, 636, 0, 637, 638, + 639, 640, 641, 642, 0, 224, 225, 0, 0, 644, + 226, 645, 227, 0, 646, 647, 648, 649, 650, 651, + 652, 0, 0, 653, 654, 655, 656, 657, 0, 0, + 658, 659, 660, 661, 662, 663, 234, 0, 664, 0, + 665, 666, 667, 0, 0, 668, 0, 0, 669, 670, + 671, 672, 673, 237, 238, 239, 240, 241, 242, 243, + 244, 245, 674, 675, 676, 86, 87, 88, 412, 90, + 91, 92, 413, 0, 414, 95, 0, 0, 98, 99, + 100, 101, 102, 103, 0, 104, 105, 415, 0, 0, + 107, 108, 109, 110, 0, 0, 112, 113, 114, 115, + 0, 116, 0, 0, 416, 417, 0, 0, 0, 418, + 419, 0, 0, 0, 0, 420, 0, 0, 0, 0, + 0, 0, 0, 0, 421, 0, 422, 0, 423, 424, + 35, 0, 0, 0, 0, 0, 0, 0, 41, 42, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 426, 427, 428, 429, 430, 431, 432, 433, 0, 434, + 435, 436, 0, 0, 0, 0, 0, 0, 0, 437, + 438, 0, 439, 440, 0, 441, 442, 443, 135, 136, + 0, 138, 139, 0, 444, 445, 446, 447, 448, 0, + 0, 449, 450, 451, 140, 452, 0, 453, 454, 455, + 456, 144, 0, 0, 0, 457, 458, 459, 460, 0, + 461, 462, 0, 463, 464, 465, 466, 467, 468, 0, + 0, 469, 0, 0, 0, 0, 0, 0, 0, 0, + 470, 471, 472, 473, 474, 475, 155, 156, 476, 0, + 477, 0, 478, 479, 480, 481, 482, 0, 483, 484, + 485, 0, 0, 486, 487, 488, 489, 490, 0, 491, + 492, 493, 0, 494, 495, 0, 496, 497, 498, 499, + 164, 500, 501, 502, 166, 0, 503, 0, 504, 168, + 505, 0, 506, 0, 507, 0, 0, 0, 508, 509, + 510, 0, 511, 172, 0, 512, 0, 513, 514, 515, + 516, 1968, 0, 518, 519, 520, 0, 521, 522, 523, + 524, 525, 526, 0, 527, 0, 175, 0, 528, 529, + 530, 0, 176, 0, 177, 0, 531, 0, 0, 532, + 0, 533, 534, 535, 536, 537, 538, 539, 0, 540, + 181, 0, 541, 0, 0, 542, 543, 544, 0, 0, + 545, 546, 547, 548, 549, 550, 551, 552, 553, 554, + 555, 556, 188, 0, 190, 557, 558, 191, 0, 559, + 560, 0, 561, 0, 194, 562, 195, 563, 564, 565, + 0, 566, 0, 0, 567, 568, 569, 0, 0, 196, + 0, 0, 0, 200, 570, 571, 572, 573, 574, 575, + 576, 0, 577, 201, 578, 202, 579, 580, 581, 0, + 582, 583, 584, 585, 586, 587, 588, 204, 589, 590, + 591, 592, 0, 593, 594, 595, 596, 597, 598, 599, + 600, 601, 602, 0, 603, 604, 0, 605, 606, 212, + 607, 608, 609, 610, 611, 612, 613, 614, 0, 615, + 616, 617, 618, 619, 0, 620, 217, 621, 622, 0, + 623, 220, 624, 0, 625, 626, 627, 628, 629, 630, + 631, 632, 633, 634, 222, 0, 635, 636, 0, 637, + 638, 639, 640, 641, 642, 0, 224, 225, 0, 0, + 644, 226, 645, 227, 0, 646, 647, 648, 649, 650, + 651, 652, 0, 0, 653, 654, 655, 656, 657, 0, + 0, 658, 659, 660, 661, 662, 663, 234, 0, 664, + 0, 665, 666, 667, 0, 0, 668, 0, 0, 669, + 670, 671, 672, 673, 237, 238, 239, 240, 241, 242, + 243, 244, 245, 674, 675, 676, 86, 87, 88, 412, + 90, 91, 92, 413, 0, 414, 95, 0, 0, 98, + 99, 100, 101, 102, 103, 0, 104, 105, 415, 0, + 0, 107, 108, 109, 110, 0, 0, 112, 113, 114, + 115, 0, 116, 0, 0, 416, 417, 0, 0, 0, + 418, 419, 0, 0, 0, 0, 420, 0, 0, 0, + 0, 0, 0, 0, 0, 421, 0, 422, 0, 423, + 424, 35, 0, 0, 0, 0, 0, 0, 0, 41, + 42, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 426, 427, 428, 429, 430, 431, 432, 433, 0, + 434, 435, 436, 0, 0, 0, 0, 0, 0, 0, + 437, 438, 0, 439, 440, 0, 441, 442, 443, 135, + 136, 0, 138, 139, 0, 444, 445, 446, 447, 448, + 0, 0, 449, 450, 451, 140, 452, 0, 453, 454, + 455, 456, 144, 0, 0, 0, 457, 458, 459, 460, + 0, 461, 462, 0, 463, 464, 465, 466, 467, 468, + 0, 0, 469, 0, 0, 0, 0, 0, 0, 0, + 0, 470, 471, 472, 473, 474, 475, 155, 156, 476, + 0, 477, 0, 478, 479, 480, 481, 482, 0, 483, + 484, 485, 0, 0, 486, 487, 488, 489, 490, 0, + 491, 492, 493, 0, 494, 495, 0, 496, 497, 498, + 499, 164, 500, 501, 502, 166, 0, 503, 0, 504, + 168, 505, 0, 506, 0, 507, 0, 0, 0, 508, + 509, 510, 0, 511, 172, 0, 512, 0, 513, 514, + 515, 516, 517, 0, 518, 519, 520, 0, 521, 522, + 523, 524, 525, 526, 0, 527, 0, 175, 0, 528, + 529, 530, 0, 176, 0, 177, 0, 531, 0, 0, + 532, 0, 533, 534, 535, 536, 537, 538, 539, 0, + 540, 181, 0, 541, 0, 0, 542, 543, 544, 0, + 0, 545, 546, 547, 548, 549, 550, 551, 552, 553, + 554, 555, 556, 188, 0, 190, 557, 558, 191, 0, + 559, 560, 0, 561, 0, 194, 562, 195, 563, 564, + 565, 0, 566, 0, 0, 567, 568, 569, 0, 0, + 196, 0, 0, 0, 200, 570, 571, 572, 573, 574, + 575, 576, 0, 577, 201, 578, 202, 579, 580, 581, + 0, 582, 583, 584, 585, 586, 587, 588, 204, 589, + 590, 591, 592, 0, 593, 594, 595, 596, 597, 598, + 599, 600, 601, 602, 0, 603, 604, 0, 605, 606, + 212, 607, 608, 2080, 610, 611, 612, 613, 614, 0, + 615, 616, 617, 618, 619, 0, 620, 217, 621, 622, + 0, 623, 220, 624, 0, 625, 626, 627, 628, 629, + 630, 631, 632, 633, 634, 222, 0, 635, 636, 0, + 637, 638, 639, 640, 641, 642, 0, 224, 225, 0, + 0, 644, 226, 645, 227, 0, 646, 647, 648, 649, + 650, 651, 652, 0, 0, 653, 654, 655, 656, 657, + 0, 0, 658, 659, 660, 661, 662, 663, 234, 0, + 664, 0, 665, 666, 667, 0, 0, 668, 0, 0, + 669, 670, 671, 672, 673, 237, 238, 239, 240, 241, + 242, 243, 244, 245, 674, 675, 676, 86, 87, 88, + 412, 90, 91, 92, 413, 0, 414, 95, 0, 0, + 98, 99, 100, 101, 102, 103, 0, 104, 105, 415, + 0, 0, 107, 108, 109, 110, 0, 0, 112, 113, + 114, 115, 0, 116, 0, 0, 416, 417, 0, 0, + 0, 418, 419, 0, 0, 0, 0, 420, 0, 0, + 0, 0, 0, 0, 0, 0, 421, 0, 422, 0, + 423, 424, 35, 0, 0, 0, 0, 0, 0, 0, + 41, 42, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 426, 427, 428, 429, 430, 431, 432, 433, + 0, 434, 435, 436, 0, 0, 0, 0, 0, 2284, + 0, 437, 438, 0, 439, 440, 0, 441, 442, 443, + 135, 136, 0, 138, 139, 0, 444, 445, 446, 447, + 448, 0, 0, 449, 450, 451, 140, 452, 0, 453, + 454, 455, 456, 144, 0, 0, 0, 457, 458, 459, + 460, 0, 461, 462, 0, 463, 464, 465, 466, 467, + 468, 0, 0, 469, 0, 0, 0, 0, 0, 0, + 0, 0, 470, 471, 472, 473, 474, 475, 155, 156, + 476, 0, 477, 0, 478, 479, 480, 481, 482, 0, + 483, 484, 485, 0, 0, 486, 487, 488, 489, 490, + 0, 491, 492, 493, 0, 494, 495, 0, 496, 497, + 498, 499, 164, 500, 501, 502, 166, 0, 503, 0, + 504, 168, 505, 0, 506, 0, 507, 0, 0, 0, + 508, 509, 510, 0, 511, 172, 0, 512, 0, 513, + 514, 515, 516, 517, 0, 518, 519, 520, 0, 521, + 522, 523, 524, 525, 526, 0, 527, 0, 175, 0, + 528, 529, 530, 0, 176, 0, 177, 0, 531, 0, + 0, 532, 0, 533, 534, 535, 536, 537, 538, 539, + 0, 540, 181, 0, 541, 0, 0, 542, 543, 544, + 0, 0, 545, 546, 547, 548, 549, 550, 551, 552, + 553, 554, 555, 556, 188, 0, 190, 557, 558, 191, + 0, 559, 560, 0, 561, 0, 194, 562, 195, 563, + 564, 565, 0, 566, 0, 0, 567, 568, 569, 0, + 0, 196, 0, 0, 0, 200, 570, 571, 572, 573, + 574, 575, 576, 0, 577, 201, 578, 202, 579, 580, + 581, 0, 582, 583, 584, 585, 586, 587, 588, 204, + 589, 590, 591, 592, 0, 593, 594, 595, 596, 597, + 598, 599, 600, 601, 602, 0, 603, 604, 0, 605, + 606, 212, 607, 608, 609, 610, 611, 612, 613, 614, + 0, 615, 616, 617, 618, 619, 0, 0, 217, 621, + 622, 0, 623, 220, 624, 0, 625, 626, 627, 628, + 629, 630, 631, 632, 633, 634, 222, 0, 635, 636, + 0, 637, 638, 639, 640, 641, 642, 0, 224, 225, + 0, 0, 644, 226, 645, 227, 0, 646, 647, 648, + 649, 650, 651, 652, 0, 0, 653, 654, 655, 656, + 657, 0, 0, 658, 659, 660, 661, 662, 663, 234, + 0, 664, 0, 665, 666, 667, 0, 0, 668, 0, + 0, 669, 670, 671, 672, 673, 237, 238, 239, 240, + 241, 242, 243, 244, 245, 674, 675, 676, 86, 87, + 88, 412, 90, 91, 92, 413, 0, 414, 95, 0, + 0, 98, 99, 100, 101, 102, 103, 0, 104, 105, + 415, 0, 0, 107, 108, 109, 110, 0, 0, 112, + 113, 114, 115, 0, 116, 0, 0, 416, 417, 0, + 0, 0, 418, 419, 0, 0, 0, 0, 420, 0, + 0, 0, 0, 0, 0, 0, 0, 421, 0, 422, + 0, 423, 424, 35, 0, 0, 0, 0, 0, 0, + 0, 41, 42, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 426, 427, 428, 429, 430, 431, 432, + 433, 0, 434, 435, 436, 0, 0, 0, 0, 0, + 0, 0, 437, 438, 0, 439, 440, 0, 441, 442, + 443, 135, 136, 0, 138, 139, 0, 444, 445, 446, + 447, 448, 0, 0, 449, 450, 451, 140, 452, 0, + 453, 454, 455, 456, 144, 0, 0, 0, 457, 458, + 459, 460, 0, 461, 462, 0, 463, 464, 465, 466, + 467, 468, 0, 0, 469, 0, 0, 0, 0, 0, + 0, 0, 0, 470, 471, 472, 473, 474, 475, 155, + 156, 476, 0, 477, 0, 478, 479, 480, 481, 482, + 0, 483, 484, 485, 0, 0, 486, 487, 488, 489, + 490, 0, 491, 492, 493, 0, 494, 495, 0, 496, + 497, 498, 499, 164, 500, 501, 502, 166, 0, 503, + 0, 504, 168, 505, 0, 506, 0, 507, 0, 0, + 0, 508, 509, 510, 0, 511, 172, 0, 512, 0, + 513, 514, 515, 516, 2654, 0, 518, 519, 520, 0, + 521, 522, 523, 524, 525, 526, 0, 527, 0, 175, + 0, 528, 529, 530, 0, 176, 0, 177, 0, 531, + 0, 0, 532, 0, 533, 534, 535, 536, 537, 538, + 539, 0, 540, 181, 0, 541, 0, 0, 542, 543, + 544, 0, 0, 545, 546, 547, 548, 549, 550, 551, + 552, 553, 554, 555, 556, 188, 0, 190, 557, 558, + 191, 0, 559, 560, 0, 561, 0, 194, 562, 195, + 563, 564, 565, 0, 566, 0, 0, 567, 568, 569, + 0, 0, 196, 0, 0, 0, 200, 570, 571, 572, + 573, 574, 575, 576, 0, 577, 201, 578, 202, 579, + 580, 581, 0, 582, 583, 584, 585, 586, 587, 588, + 204, 589, 590, 591, 592, 0, 593, 594, 595, 596, + 597, 598, 599, 600, 601, 602, 0, 603, 604, 0, + 605, 606, 212, 607, 608, 609, 610, 611, 612, 613, + 614, 0, 615, 616, 617, 618, 619, 0, 620, 217, + 621, 622, 0, 623, 220, 624, 0, 625, 626, 627, + 628, 629, 630, 631, 632, 633, 634, 222, 0, 635, + 636, 0, 637, 638, 639, 640, 641, 642, 0, 224, + 225, 0, 0, 644, 226, 645, 227, 0, 646, 647, + 648, 649, 650, 651, 652, 0, 0, 653, 654, 655, + 656, 657, 0, 0, 658, 659, 660, 661, 662, 663, + 234, 0, 664, 0, 665, 666, 667, 0, 0, 668, + 0, 0, 669, 670, 671, 672, 673, 237, 238, 239, + 240, 241, 242, 243, 244, 245, 674, 675, 676, 86, + 87, 88, 412, 90, 91, 92, 413, 0, 414, 95, + 0, 0, 98, 99, 100, 101, 102, 103, 0, 104, + 105, 415, 0, 0, 107, 108, 109, 110, 0, 0, + 112, 113, 114, 115, 0, 116, 0, 0, 416, 417, + 0, 0, 0, 418, 419, 0, 0, 0, 0, 420, + 0, 0, 0, 0, 0, 0, 0, 0, 421, 0, + 422, 0, 423, 424, 35, 0, 0, 0, 0, 0, + 0, 0, 41, 42, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 426, 427, 428, 429, 430, 431, + 432, 433, 0, 434, 435, 436, 0, 0, 0, 0, + 0, 0, 0, 437, 438, 0, 439, 440, 0, 441, + 442, 443, 135, 136, 0, 138, 139, 0, 444, 445, + 446, 447, 448, 0, 0, 449, 450, 451, 140, 452, + 0, 453, 454, 455, 456, 144, 0, 0, 0, 457, + 458, 459, 460, 0, 461, 462, 0, 463, 464, 465, + 466, 467, 468, 0, 0, 469, 0, 0, 0, 0, + 0, 0, 0, 0, 470, 471, 472, 473, 474, 475, + 155, 156, 476, 0, 477, 0, 478, 479, 480, 481, + 482, 0, 483, 484, 485, 0, 0, 486, 487, 488, + 489, 490, 0, 491, 492, 493, 0, 494, 495, 0, + 496, 497, 498, 499, 164, 500, 501, 502, 166, 0, + 503, 0, 504, 168, 505, 0, 506, 0, 507, 0, + 0, 0, 508, 509, 510, 0, 511, 172, 0, 512, + 0, 513, 514, 515, 516, 3024, 0, 518, 519, 520, + 0, 521, 522, 523, 524, 525, 526, 0, 527, 0, + 175, 0, 528, 529, 530, 0, 176, 0, 177, 0, + 531, 0, 0, 532, 0, 533, 534, 535, 536, 537, + 538, 539, 0, 540, 181, 0, 541, 0, 0, 542, + 543, 544, 0, 0, 545, 546, 547, 548, 549, 550, + 551, 552, 553, 554, 555, 556, 188, 0, 190, 557, + 558, 191, 0, 559, 560, 0, 561, 0, 194, 562, + 195, 563, 564, 565, 0, 566, 0, 0, 567, 568, + 569, 0, 0, 196, 0, 0, 0, 200, 570, 571, + 572, 573, 574, 575, 576, 0, 577, 201, 578, 202, + 579, 580, 581, 0, 582, 583, 584, 585, 586, 587, + 588, 204, 589, 590, 591, 592, 0, 593, 594, 595, + 596, 597, 598, 599, 600, 601, 602, 0, 603, 604, + 0, 605, 606, 212, 607, 608, 609, 610, 611, 612, + 613, 614, 0, 615, 616, 617, 618, 619, 0, 620, + 217, 621, 622, 0, 623, 220, 624, 0, 625, 626, + 627, 628, 629, 630, 631, 632, 633, 634, 222, 0, + 635, 636, 0, 637, 638, 639, 640, 641, 642, 0, + 224, 225, 0, 0, 644, 226, 645, 227, 0, 646, + 647, 648, 649, 650, 651, 652, 0, 0, 653, 654, + 655, 656, 657, 0, 0, 658, 659, 660, 661, 662, + 663, 234, 0, 664, 0, 665, 666, 667, 0, 0, + 668, 0, 0, 669, 670, 671, 672, 673, 237, 238, + 239, 240, 241, 242, 243, 244, 245, 674, 675, 676, + 86, 87, 88, 412, 90, 91, 92, 413, 0, 414, + 95, 0, 0, 98, 99, 100, 101, 102, 103, 0, + 104, 105, 415, 0, 0, 107, 108, 109, 110, 0, + 0, 112, 113, 114, 115, 0, 116, 0, 0, 416, + 417, 0, 0, 0, 418, 419, 0, 0, 0, 0, + 420, 0, 0, 0, 0, 0, 0, 0, 0, 421, + 0, 422, 0, 423, 424, 35, 0, 0, 0, 0, + 0, 0, 0, 41, 42, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 426, 427, 428, 429, 430, + 431, 432, 433, 0, 434, 435, 436, 0, 0, 0, + 0, 0, 0, 0, 437, 438, 0, 439, 440, 0, + 441, 442, 443, 135, 136, 0, 138, 139, 0, 444, + 445, 446, 447, 448, 0, 0, 449, 450, 451, 140, + 452, 0, 453, 454, 455, 456, 144, 0, 0, 0, + 457, 458, 459, 460, 0, 461, 462, 0, 463, 464, + 465, 466, 467, 468, 0, 0, 469, 0, 0, 0, + 0, 0, 0, 0, 0, 470, 471, 472, 473, 474, + 475, 155, 156, 476, 0, 477, 0, 478, 479, 480, + 481, 482, 0, 483, 484, 485, 0, 0, 486, 487, + 488, 489, 490, 0, 491, 492, 493, 0, 494, 495, + 0, 496, 497, 498, 499, 164, 500, 501, 502, 166, + 0, 503, 0, 504, 168, 505, 0, 506, 0, 507, + 0, 0, 0, 508, 509, 510, 0, 511, 172, 0, + 512, 0, 513, 514, 515, 516, 3097, 0, 518, 519, + 520, 0, 521, 522, 523, 524, 525, 526, 0, 527, + 0, 175, 0, 528, 529, 530, 0, 176, 0, 177, + 0, 531, 0, 0, 532, 0, 533, 534, 535, 536, + 537, 538, 539, 0, 540, 181, 0, 541, 0, 0, + 542, 543, 544, 0, 0, 545, 546, 547, 548, 549, + 550, 551, 552, 553, 554, 555, 556, 188, 0, 190, + 557, 558, 191, 0, 559, 560, 0, 561, 0, 194, + 562, 195, 563, 564, 565, 0, 566, 0, 0, 567, + 568, 569, 0, 0, 196, 0, 0, 0, 200, 570, + 571, 572, 573, 574, 575, 576, 0, 577, 201, 578, + 202, 579, 580, 581, 0, 582, 583, 584, 585, 586, + 587, 588, 204, 589, 590, 591, 592, 0, 593, 594, + 595, 596, 597, 598, 599, 600, 601, 602, 0, 603, + 604, 0, 605, 606, 212, 607, 608, 609, 610, 611, + 612, 613, 614, 0, 615, 616, 617, 618, 619, 0, + 620, 217, 621, 622, 0, 623, 220, 624, 0, 625, + 626, 627, 628, 629, 630, 631, 632, 633, 634, 222, + 0, 635, 636, 0, 637, 638, 639, 640, 641, 642, + 0, 224, 225, 0, 0, 644, 226, 645, 227, 0, + 646, 647, 648, 649, 650, 651, 652, 0, 0, 653, + 654, 655, 656, 657, 0, 0, 658, 659, 660, 661, + 662, 663, 234, 0, 664, 0, 665, 666, 667, 0, + 0, 668, 0, 0, 669, 670, 671, 672, 673, 237, + 238, 239, 240, 241, 242, 243, 244, 245, 674, 675, + 676, 86, 87, 88, 412, 90, 91, 92, 413, 0, + 414, 95, 0, 0, 98, 99, 100, 101, 102, 103, + 0, 104, 105, 415, 0, 0, 107, 108, 109, 110, + 0, 0, 112, 113, 114, 115, 0, 116, 0, 0, + 416, 417, 0, 0, 0, 418, 419, 0, 0, 0, + 0, 420, 0, 0, 0, 0, 0, 0, 0, 0, + 421, 0, 422, 0, 423, 424, 35, 0, 0, 0, + 0, 0, 0, 0, 41, 42, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 426, 427, 428, 429, + 430, 431, 432, 433, 0, 434, 435, 436, 0, 0, + 0, 0, 0, 0, 0, 437, 438, 0, 439, 440, + 0, 441, 442, 443, 135, 136, 0, 138, 139, 0, + 444, 445, 446, 447, 448, 0, 0, 449, 450, 451, + 140, 452, 0, 453, 454, 455, 456, 144, 0, 0, + 0, 457, 458, 459, 460, 0, 461, 462, 0, 463, + 464, 465, 466, 467, 468, 0, 0, 469, 0, 0, + 0, 0, 0, 0, 0, 0, 470, 471, 472, 473, + 474, 475, 155, 156, 476, 0, 477, 0, 478, 479, + 480, 481, 482, 0, 483, 484, 485, 0, 0, 486, + 487, 488, 489, 490, 0, 491, 492, 493, 0, 494, + 495, 0, 496, 497, 498, 499, 164, 500, 501, 502, + 166, 0, 503, 0, 504, 168, 505, 0, 506, 0, + 507, 0, 0, 0, 508, 509, 510, 0, 511, 172, + 0, 512, 0, 513, 514, 515, 516, 3099, 0, 518, + 519, 520, 0, 521, 522, 523, 524, 525, 526, 0, + 527, 0, 175, 0, 528, 529, 530, 0, 176, 0, + 177, 0, 531, 0, 0, 532, 0, 533, 534, 535, + 536, 537, 538, 539, 0, 540, 181, 0, 541, 0, + 0, 542, 543, 544, 0, 0, 545, 546, 547, 548, + 549, 550, 551, 552, 553, 554, 555, 556, 188, 0, + 190, 557, 558, 191, 0, 559, 560, 0, 561, 0, + 194, 562, 195, 563, 564, 565, 0, 566, 0, 0, + 567, 568, 569, 0, 0, 196, 0, 0, 0, 200, + 570, 571, 572, 573, 574, 575, 576, 0, 577, 201, + 578, 202, 579, 580, 581, 0, 582, 583, 584, 585, + 586, 587, 588, 204, 589, 590, 591, 592, 0, 593, + 594, 595, 596, 597, 598, 599, 600, 601, 602, 0, + 603, 604, 0, 605, 606, 212, 607, 608, 609, 610, + 611, 612, 613, 614, 0, 615, 616, 617, 618, 619, + 0, 620, 217, 621, 622, 0, 623, 220, 624, 0, + 625, 626, 627, 628, 629, 630, 631, 632, 633, 634, + 222, 0, 635, 636, 0, 637, 638, 639, 640, 641, + 642, 0, 224, 225, 0, 0, 644, 226, 645, 227, + 0, 646, 647, 648, 649, 650, 651, 652, 0, 0, + 653, 654, 655, 656, 657, 0, 0, 658, 659, 660, + 661, 662, 663, 234, 0, 664, 0, 665, 666, 667, + 0, 0, 668, 0, 0, 669, 670, 671, 672, 673, + 237, 238, 239, 240, 241, 242, 243, 244, 245, 674, + 675, 676, 86, 87, 88, 412, 90, 91, 92, 413, + 0, 414, 95, 0, 0, 98, 99, 100, 101, 102, + 103, 0, 104, 105, 415, 0, 0, 107, 108, 109, + 110, 0, 0, 112, 113, 114, 115, 0, 116, 0, + 0, 416, 417, 0, 0, 0, 418, 419, 0, 0, + 0, 0, 420, 0, 0, 0, 0, 0, 0, 0, + 0, 421, 0, 422, 0, 423, 424, 35, 0, 0, + 0, 0, 0, 0, 0, 41, 42, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 426, 427, 428, + 429, 430, 431, 432, 433, 0, 434, 435, 436, 0, + 0, 0, 0, 0, 0, 0, 437, 438, 0, 439, + 440, 0, 441, 442, 443, 135, 136, 0, 138, 139, + 0, 444, 445, 446, 447, 448, 0, 0, 449, 450, + 451, 140, 452, 0, 453, 454, 455, 456, 144, 0, + 0, 0, 457, 458, 459, 460, 0, 461, 462, 0, + 463, 464, 465, 466, 467, 468, 0, 0, 469, 0, + 0, 0, 0, 0, 0, 0, 0, 470, 471, 472, + 473, 474, 475, 155, 156, 476, 0, 477, 0, 478, + 479, 480, 481, 482, 0, 483, 484, 485, 0, 0, + 486, 487, 488, 489, 490, 0, 491, 492, 493, 0, + 494, 495, 0, 496, 497, 498, 499, 164, 500, 501, + 502, 166, 0, 503, 0, 504, 168, 505, 0, 506, + 0, 507, 0, 0, 0, 508, 509, 510, 0, 511, + 172, 0, 512, 0, 513, 514, 515, 516, 3191, 0, + 518, 519, 520, 0, 521, 522, 523, 524, 525, 526, + 0, 527, 0, 175, 0, 528, 529, 530, 0, 176, + 0, 177, 0, 531, 0, 0, 532, 0, 533, 534, + 535, 536, 537, 538, 539, 0, 540, 181, 0, 541, + 0, 0, 542, 543, 544, 0, 0, 545, 546, 547, + 548, 549, 550, 551, 552, 553, 554, 555, 556, 188, + 0, 190, 557, 558, 191, 0, 559, 560, 0, 561, + 0, 194, 562, 195, 563, 564, 565, 0, 566, 0, + 0, 567, 568, 569, 0, 0, 196, 0, 0, 0, + 200, 570, 571, 572, 573, 574, 575, 576, 0, 577, + 201, 578, 202, 579, 580, 581, 0, 582, 583, 584, + 585, 586, 587, 588, 204, 589, 590, 591, 592, 0, + 593, 594, 595, 596, 597, 598, 599, 600, 601, 602, + 0, 603, 604, 0, 605, 606, 212, 607, 608, 609, + 610, 611, 612, 613, 614, 0, 615, 616, 617, 618, + 619, 0, 620, 217, 621, 622, 0, 623, 220, 624, + 0, 625, 626, 627, 628, 629, 630, 631, 632, 633, + 634, 222, 0, 635, 636, 0, 637, 638, 639, 640, + 641, 642, 0, 224, 225, 0, 0, 644, 226, 645, + 227, 0, 646, 647, 648, 649, 650, 651, 652, 0, + 0, 653, 654, 655, 656, 657, 0, 0, 658, 659, + 660, 661, 662, 663, 234, 0, 664, 0, 665, 666, + 667, 0, 0, 668, 0, 0, 669, 670, 671, 672, + 673, 237, 238, 239, 240, 241, 242, 243, 244, 245, + 674, 675, 676, 86, 87, 88, 412, 90, 91, 92, + 413, 0, 414, 95, 0, 0, 98, 99, 100, 101, + 102, 103, 0, 104, 105, 415, 0, 0, 107, 108, + 109, 110, 0, 0, 112, 113, 114, 115, 0, 116, + 0, 0, 416, 417, 0, 0, 0, 418, 419, 0, + 0, 0, 0, 420, 0, 0, 0, 0, 0, 0, + 0, 0, 421, 0, 422, 0, 423, 424, 35, 0, + 0, 0, 0, 0, 0, 0, 41, 42, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 426, 427, + 428, 429, 430, 431, 432, 433, 0, 434, 435, 436, + 0, 0, 0, 0, 0, 0, 0, 437, 438, 0, + 439, 440, 0, 441, 442, 443, 135, 136, 0, 138, + 139, 0, 444, 445, 446, 447, 448, 0, 0, 1039, + 450, 1013, 140, 452, 0, 453, 454, 455, 456, 144, + 0, 0, 0, 457, 458, 459, 460, 0, 461, 0, + 0, 463, 464, 465, 466, 467, 468, 0, 0, 469, + 0, 0, 0, 0, 0, 0, 0, 0, 470, 471, + 472, 473, 474, 475, 155, 156, 476, 0, 477, 0, + 478, 479, 480, 481, 482, 0, 483, 484, 485, 0, + 0, 486, 487, 488, 489, 490, 0, 491, 492, 493, + 0, 494, 495, 0, 496, 497, 498, 499, 164, 500, + 501, 502, 166, 0, 503, 0, 504, 168, 505, 0, + 506, 0, 507, 0, 0, 0, 508, 509, 510, 0, + 511, 172, 0, 512, 0, 513, 514, 515, 516, 517, + 0, 518, 519, 520, 0, 521, 522, 523, 524, 525, + 526, 0, 527, 0, 175, 0, 528, 529, 530, 0, + 176, 0, 177, 0, 531, 0, 0, 532, 0, 533, + 534, 535, 536, 537, 538, 539, 0, 540, 181, 0, + 541, 0, 0, 542, 543, 544, 0, 0, 545, 546, + 547, 548, 549, 550, 551, 552, 553, 554, 555, 1043, + 188, 0, 190, 557, 558, 191, 0, 559, 560, 0, + 561, 0, 194, 562, 195, 563, 564, 565, 0, 566, + 0, 0, 567, 568, 569, 0, 0, 196, 0, 0, + 0, 200, 570, 571, 572, 573, 574, 575, 576, 0, + 577, 201, 578, 202, 579, 580, 581, 0, 582, 583, + 584, 585, 586, 587, 588, 204, 589, 590, 591, 592, + 0, 593, 594, 595, 596, 597, 598, 599, 600, 601, + 602, 0, 603, 604, 0, 1044, 606, 212, 607, 608, + 609, 1045, 611, 612, 613, 614, 0, 615, 616, 617, + 618, 1547, 0, 620, 217, 621, 622, 0, 623, 220, + 624, 0, 625, 626, 627, 628, 629, 630, 631, 632, + 633, 634, 222, 0, 635, 636, 0, 637, 638, 639, + 640, 641, 642, 0, 1047, 225, 0, 0, 1048, 226, + 645, 227, 0, 646, 647, 648, 649, 650, 651, 652, + 0, 0, 653, 654, 655, 656, 657, 0, 0, 658, + 659, 660, 661, 662, 1017, 234, 0, 664, 0, 665, + 666, 667, 0, 0, 668, 0, 0, 669, 670, 671, + 672, 1049, 237, 238, 239, 240, 241, 242, 243, 244, + 245, 674, 675, 676, 86, 87, 88, 412, 90, 91, + 92, 413, 0, 414, 95, 0, 0, 98, 99, 100, + 101, 102, 103, 0, 104, 105, 415, 0, 0, 107, + 108, 109, 110, 0, 0, 112, 113, 114, 115, 0, + 116, 0, 0, 416, 417, 0, 0, 0, 418, 419, + 0, 0, 0, 0, 420, 0, 0, 0, 0, 0, + 0, 0, 0, 421, 0, 422, 0, 423, 424, 35, + 0, 0, 0, 0, 0, 0, 0, 41, 42, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 426, + 427, 428, 429, 430, 431, 432, 433, 0, 434, 435, + 436, 0, 0, 0, 0, 0, 0, 0, 437, 438, + 0, 439, 440, 0, 441, 442, 443, 135, 136, 0, + 138, 139, 0, 444, 445, 446, 447, 448, 0, 0, + 1039, 450, 1013, 140, 452, 0, 453, 454, 455, 456, + 144, 0, 0, 0, 457, 458, 459, 460, 0, 461, + 0, 0, 463, 464, 465, 466, 467, 468, 0, 0, + 469, 0, 0, 0, 0, 0, 0, 0, 0, 470, + 471, 472, 473, 474, 475, 155, 156, 476, 0, 477, + 0, 478, 479, 480, 481, 482, 0, 483, 484, 485, + 0, 0, 486, 487, 488, 489, 490, 0, 491, 492, + 493, 0, 494, 495, 0, 496, 497, 498, 499, 164, + 500, 501, 502, 166, 0, 503, 0, 504, 168, 505, + 0, 506, 0, 507, 0, 0, 0, 508, 509, 510, + 0, 511, 172, 0, 512, 0, 513, 514, 515, 516, + 517, 0, 518, 519, 520, 0, 521, 522, 523, 524, + 525, 526, 0, 527, 0, 175, 0, 528, 529, 530, + 0, 176, 0, 177, 0, 531, 0, 0, 532, 0, + 533, 534, 535, 536, 537, 538, 539, 0, 540, 181, + 0, 541, 0, 0, 542, 543, 544, 0, 0, 545, + 546, 547, 548, 549, 550, 551, 552, 553, 554, 555, + 1043, 188, 0, 190, 557, 558, 191, 0, 559, 560, + 0, 561, 0, 194, 562, 195, 563, 564, 565, 0, + 566, 0, 0, 567, 568, 569, 0, 0, 196, 0, + 0, 0, 200, 570, 571, 572, 573, 574, 575, 576, + 0, 577, 201, 578, 202, 579, 580, 581, 0, 582, + 583, 584, 585, 586, 587, 588, 204, 589, 590, 591, + 592, 0, 593, 594, 595, 596, 597, 598, 599, 600, + 601, 602, 0, 603, 604, 0, 1044, 606, 212, 607, + 608, 609, 1045, 611, 612, 613, 614, 0, 615, 616, + 617, 618, 1547, 0, 620, 217, 621, 622, 0, 623, + 220, 624, 0, 625, 626, 627, 628, 629, 630, 631, + 632, 633, 634, 222, 0, 635, 636, 0, 637, 2350, + 639, 640, 641, 642, 0, 1047, 225, 0, 0, 1048, + 226, 645, 227, 0, 646, 647, 648, 649, 650, 651, + 652, 0, 0, 653, 654, 655, 656, 657, 0, 0, + 658, 659, 660, 661, 662, 1017, 234, 0, 664, 0, + 665, 666, 667, 0, 0, 668, 0, 0, 669, 670, + 671, 672, 1049, 237, 238, 239, 240, 241, 242, 243, + 244, 245, 674, 675, 676, 86, 87, 88, 412, 90, + 91, 92, 413, 0, 414, 95, 0, 0, 98, 99, + 100, 101, 102, 103, 0, 104, 105, 415, 0, 0, + 107, 108, 109, 110, 0, 0, 112, 113, 114, 115, + 0, 116, 0, 0, 416, 417, 0, 0, 0, 418, + 419, 0, 0, 0, 0, 420, 0, 0, 0, 0, + 0, 0, 0, 0, 421, 0, 422, 0, 423, 424, + 35, 0, 0, 0, 0, 0, 0, 0, 41, 42, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 426, 427, 428, 429, 430, 431, 432, 433, 0, 434, + 435, 436, 0, 0, 0, 0, 0, 0, 0, 437, + 438, 0, 439, 440, 0, 441, 442, 443, 135, 136, + 0, 138, 139, 0, 444, 445, 446, 447, 448, 0, + 0, 1039, 450, 1013, 140, 452, 0, 453, 454, 455, + 456, 144, 0, 0, 0, 457, 458, 459, 460, 0, + 461, 0, 0, 463, 464, 465, 466, 467, 468, 0, + 0, 469, 0, 0, 0, 0, 0, 0, 0, 0, + 470, 471, 472, 473, 474, 475, 155, 156, 476, 0, + 477, 0, 478, 479, 480, 481, 482, 0, 483, 484, + 485, 0, 0, 486, 487, 488, 489, 490, 0, 491, + 492, 493, 0, 494, 495, 0, 496, 497, 498, 499, + 164, 500, 501, 502, 166, 0, 503, 0, 504, 168, + 505, 0, 506, 0, 507, 0, 0, 0, 508, 509, + 510, 0, 511, 172, 0, 512, 0, 513, 514, 515, + 516, 517, 0, 518, 519, 520, 0, 521, 522, 523, + 524, 525, 526, 0, 527, 0, 175, 0, 528, 529, + 530, 0, 176, 0, 177, 0, 531, 0, 0, 532, + 0, 533, 534, 535, 536, 537, 538, 539, 0, 540, + 181, 0, 541, 0, 0, 542, 543, 544, 0, 0, + 545, 546, 547, 548, 549, 550, 551, 552, 553, 554, + 555, 1043, 188, 0, 190, 557, 558, 191, 0, 559, + 560, 0, 561, 0, 194, 562, 195, 563, 564, 565, + 0, 566, 0, 0, 567, 568, 569, 0, 0, 196, + 0, 0, 0, 200, 570, 571, 572, 573, 574, 575, + 576, 0, 577, 201, 578, 202, 579, 580, 581, 0, + 582, 583, 584, 585, 586, 587, 588, 204, 589, 590, + 591, 592, 0, 593, 594, 595, 596, 597, 598, 599, + 600, 601, 602, 0, 603, 604, 0, 1044, 606, 212, + 607, 608, 609, 2410, 611, 612, 613, 614, 0, 615, + 616, 617, 618, 2411, 0, 620, 217, 621, 622, 0, + 623, 220, 624, 0, 625, 626, 627, 628, 629, 630, + 631, 632, 633, 634, 222, 0, 635, 636, 0, 637, + 638, 639, 640, 641, 642, 0, 1047, 225, 0, 0, + 2412, 226, 645, 227, 0, 646, 647, 648, 649, 650, + 651, 652, 0, 0, 653, 654, 655, 656, 657, 0, + 0, 658, 659, 660, 661, 662, 1017, 234, 0, 664, + 0, 665, 666, 667, 0, 0, 668, 0, 0, 669, + 670, 671, 672, 1049, 237, 238, 239, 240, 241, 242, + 243, 244, 245, 674, 675, 676, 86, 87, 88, 412, + 90, 91, 92, 413, 0, 414, 95, 0, 0, 98, + 99, 100, 101, 102, 103, 0, 104, 105, 415, 0, + 0, 107, 108, 109, 110, 0, 0, 112, 113, 114, + 115, 0, 116, 0, 0, 416, 417, 0, 0, 0, + 418, 419, 0, 0, 0, 0, 420, 0, 0, 0, + 0, 0, 0, 0, 0, 421, 0, 422, 0, 423, + 424, 35, 0, 0, 0, 0, 0, 0, 0, 41, + 42, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 426, 427, 428, 429, 430, 431, 432, 433, 0, + 434, 435, 436, 0, 0, 0, 0, 0, 0, 0, + 437, 438, 0, 439, 440, 0, 441, 442, 443, 135, + 136, 0, 138, 139, 0, 444, 445, 446, 447, 448, + 0, 0, 1039, 450, 1013, 140, 452, 0, 453, 454, + 455, 456, 144, 0, 0, 0, 457, 458, 459, 460, + 0, 461, 0, 0, 463, 464, 465, 466, 467, 468, + 0, 0, 469, 0, 0, 0, 0, 0, 0, 0, + 0, 470, 471, 472, 473, 474, 475, 155, 156, 476, + 0, 477, 0, 478, 479, 480, 481, 482, 0, 483, + 484, 485, 0, 0, 486, 487, 488, 489, 490, 0, + 491, 492, 493, 0, 494, 495, 0, 496, 497, 498, + 499, 164, 500, 501, 502, 166, 0, 503, 0, 504, + 168, 505, 0, 506, 0, 507, 0, 0, 0, 508, + 509, 510, 0, 511, 172, 0, 512, 0, 513, 514, + 515, 516, 517, 0, 518, 519, 520, 0, 521, 522, + 523, 524, 525, 526, 0, 527, 0, 175, 0, 528, + 529, 530, 0, 176, 0, 177, 0, 531, 0, 0, + 532, 0, 533, 534, 535, 536, 537, 538, 539, 0, + 540, 181, 0, 541, 0, 0, 542, 543, 544, 0, + 0, 545, 546, 547, 548, 549, 550, 551, 552, 553, + 554, 555, 1043, 188, 0, 190, 557, 558, 191, 0, + 559, 560, 0, 561, 0, 194, 562, 195, 563, 564, + 565, 0, 566, 0, 0, 567, 568, 569, 0, 0, + 196, 0, 0, 0, 200, 570, 571, 572, 573, 574, + 575, 576, 0, 577, 201, 578, 202, 579, 580, 581, + 0, 582, 583, 584, 585, 586, 587, 588, 204, 589, + 590, 591, 592, 0, 593, 594, 595, 596, 597, 598, + 599, 600, 601, 602, 0, 603, 604, 0, 1044, 606, + 212, 607, 608, 609, 1045, 611, 612, 613, 614, 0, + 615, 616, 617, 618, 2411, 0, 620, 217, 621, 622, + 0, 623, 220, 624, 0, 625, 626, 627, 628, 629, + 630, 631, 632, 633, 634, 222, 0, 635, 636, 0, + 637, 638, 639, 640, 641, 642, 0, 1047, 225, 0, + 0, 2412, 226, 645, 227, 0, 646, 647, 648, 649, + 650, 651, 652, 0, 0, 653, 654, 655, 656, 657, + 0, 0, 658, 659, 660, 661, 662, 1017, 234, 0, + 664, 0, 665, 666, 667, 0, 0, 668, 0, 0, + 669, 670, 671, 672, 1049, 237, 238, 239, 240, 241, + 242, 243, 244, 245, 674, 675, 676, 86, 87, 88, + 412, 90, 91, 92, 413, 0, 414, 95, 0, 0, + 98, 99, 100, 101, 102, 103, 0, 104, 105, 415, + 0, 0, 107, 108, 109, 110, 0, 0, 112, 113, + 114, 115, 0, 116, 0, 0, 416, 417, 0, 0, + 0, 418, 419, 0, 0, 0, 0, 420, 0, 0, + 0, 0, 0, 0, 0, 0, 421, 0, 422, 0, + 423, 424, 35, 0, 0, 0, 0, 0, 0, 0, + 41, 42, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 426, 427, 428, 429, 430, 431, 432, 433, + 0, 434, 435, 436, 0, 0, 0, 0, 0, 0, + 0, 437, 438, 0, 439, 440, 0, 441, 442, 443, + 135, 136, 0, 138, 139, 0, 444, 445, 446, 447, + 448, 0, 0, 449, 450, 451, 140, 452, 0, 453, + 454, 455, 456, 144, 0, 0, 0, 457, 458, 459, + 460, 0, 461, 462, 0, 463, 464, 465, 466, 467, + 468, 0, 0, 469, 0, 0, 0, 0, 0, 0, + 0, 0, 470, 471, 472, 473, 474, 475, 155, 156, + 476, 0, 477, 0, 478, 479, 480, 481, 482, 0, + 483, 484, 485, 0, 0, 486, 487, 488, 489, 490, + 0, 491, 492, 493, 0, 494, 495, 0, 496, 497, + 498, 499, 164, 500, 501, 502, 166, 0, 503, 0, + 504, 168, 505, 0, 506, 0, 507, 0, 0, 0, + 508, 509, 510, 0, 511, 172, 0, 512, 0, 513, + 514, 515, 516, 517, 0, 518, 519, 520, 0, 521, + 522, 523, 524, 525, 526, 0, 527, 0, 175, 0, + 528, 529, 530, 0, 176, 0, 177, 0, 531, 0, + 0, 532, 0, 533, 534, 535, 536, 537, 538, 539, + 0, 540, 181, 0, 541, 0, 0, 542, 543, 544, + 0, 0, 545, 546, 547, 548, 549, 550, 551, 552, + 553, 554, 555, 556, 188, 0, 190, 557, 558, 191, + 0, 559, 560, 0, 561, 0, 194, 562, 195, 563, + 564, 565, 0, 566, 0, 0, 567, 568, 569, 0, + 0, 196, 0, 0, 0, 200, 570, 571, 572, 573, + 0, 575, 576, 0, 577, 201, 578, 202, 579, 580, + 581, 0, 582, 583, 584, 585, 586, 0, 588, 204, + 589, 590, 591, 592, 0, 593, 594, 595, 596, 597, + 598, 599, 600, 601, 602, 0, 603, 604, 0, 605, + 606, 212, 0, 608, 609, 610, 611, 612, 613, 614, + 0, 615, 616, 617, 618, 619, 0, 620, 217, 621, + 622, 0, 623, 220, 624, 0, 625, 626, 627, 628, + 629, 630, 631, 632, 633, 634, 222, 0, 635, 636, + 0, 637, 638, 639, 640, 641, 642, 0, 224, 225, + 0, 0, 644, 226, 645, 227, 0, 646, 647, 648, + 649, 650, 651, 652, 0, 0, 653, 654, 655, 656, + 657, 0, 0, 658, 659, 660, 661, 662, 663, 234, + 0, 664, 0, 665, 666, 667, 0, 0, 668, 0, + 0, 669, 670, 671, 672, 673, 237, 238, 239, 240, + 241, 242, 243, 244, 245, 674, 675, 676, 86, 87, + 88, 0, 90, 91, 92, 0, 0, 0, 95, 0, + 0, 98, 99, 100, 101, 102, 103, 0, 104, 105, + 0, 0, 0, 107, 108, 109, 110, 0, 111, 112, + 113, 114, 115, -2325, 116, 117, 118, 0, 0, 0, + 0, 0, 121, 122, 0, 0, 0, 0, 123, 0, + 0, 0, 0, 0, 0, 0, 0, 124, 0, 125, + 0, 126, 127, 35, 0, 407, 0, 0, 0, 0, + 0, 41, 42, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 133, 0, 0, + 0, 135, 136, 137, 138, 139, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 140, 0, 0, + 0, 0, 0, 0, 144, 0, 145, 0, 0, 0, + 0, 0, 148, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 151, 0, 0, 0, 0, 0, 152, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 155, + 156, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 162, 0, 0, 0, + 0, 0, 0, 164, 0, 0, 0, 166, 0, 0, + 0, 0, 168, 0, 0, 0, 0, 0, 169, 0, + 170, 0, 0, 0, 0, 0, 172, 0, 0, 0, + 0, 0, 0, 0, 0, 173, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 174, 175, + 0, 0, 0, 0, 0, 176, 0, 177, 0, 0, + 178, 179, 0, 180, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 181, 182, 0, 183, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 188, 189, 190, 0, 0, + 191, 0, 0, 0, 193, 0, 0, 194, 0, 195, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 196, 197, 198, 199, 200, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 201, 0, 202, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 204, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 210, + 0, 0, 212, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 217, + 0, 0, 219, 0, 220, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 222, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 224, + 225, 0, 0, 0, 226, 0, 227, 0, 0, 0, + 0, 0, 0, 0, 0, 230, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 234, 0, 0, 235, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 237, 238, 239, + 240, 241, 242, 243, 244, 245, 86, 87, 88, 0, + 90, 91, 92, 0, 0, 0, 95, 0, 0, 98, + 99, 100, 101, 102, 103, 0, 104, 105, 0, 0, + 0, 107, 108, 109, 110, 0, 111, 112, 113, 114, + 115, -2326, 116, 117, 118, 0, 0, 0, 0, 0, + 121, 122, 0, 0, 0, 0, 123, 0, 0, 0, + 0, 0, 0, 0, 0, 124, 0, 125, 0, 126, + 127, 35, 0, 1123, 0, 0, 0, 0, 0, 41, + 42, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 133, 0, 0, 0, 135, + 136, 137, 138, 139, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 140, 0, 0, 0, 0, + 0, 0, 144, 0, 145, 0, 0, 0, 0, 0, + 148, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 151, 0, 0, 0, 0, 0, 152, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 155, 156, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 162, 0, 0, 0, 0, 0, + 0, 164, 0, 0, 0, 166, 0, 0, 0, 0, + 168, 0, 0, 0, 0, 0, 169, 0, 170, 0, + 0, 0, 0, 0, 172, 0, 0, 0, 0, 0, + 0, 0, 0, 173, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 174, 175, 0, 0, + 0, 0, 0, 176, 0, 177, 0, 0, 178, 179, + 0, 180, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 181, 182, 0, 183, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 188, 189, 190, 0, 0, 191, 0, + 0, 0, 193, 0, 0, 194, 0, 195, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 196, 197, 198, 199, 200, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 201, 0, 202, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 204, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 210, 0, 0, + 212, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 217, 0, 0, + 219, 0, 220, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 222, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 224, 225, 0, + 0, 0, 226, 0, 227, 0, 0, 0, 0, 0, + 0, 0, 0, 230, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 234, 0, + 0, 235, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 237, 238, 239, 240, 241, + 242, 243, 244, 245, 86, 87, 88, 0, 90, 91, + 92, 0, 0, 0, 95, 0, 0, 98, 99, 100, + 101, 102, 103, 0, 104, 105, 0, 0, 0, 107, + 108, 109, 110, 0, 111, 112, 113, 114, 115, 0, + 116, 117, 118, 0, 0, 0, 0, 0, 121, 122, + 0, 0, 0, 0, 123, 0, 0, 0, 0, 0, + 0, 0, 0, 124, 0, 125, 0, 126, 0, 35, + 0, 0, 0, 0, 0, 0, 0, 41, 42, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 133, 0, 0, 0, 135, 136, 137, + 138, 139, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 140, 0, 0, 0, 0, 0, 0, + 144, 0, 145, 0, 0, 0, 0, 0, 148, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 151, + 0, 0, 0, 0, 0, 152, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 155, 156, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 162, 0, 0, 0, 0, 0, 0, 164, + 0, 0, 0, 166, 0, 0, 0, 0, 168, 0, + 0, 0, 0, 0, 169, 0, 170, 0, 0, 0, + 0, 0, 172, 0, 0, 0, 0, 0, 0, 0, + 0, 173, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 174, 175, 0, 0, 0, 0, + 0, 176, 0, 177, 0, 0, 178, 179, 0, 180, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 181, + 182, 0, 183, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 188, 189, 190, 0, 0, 191, 0, 0, 0, + 193, 0, 0, 194, 0, 195, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 196, 197, + 198, 199, 200, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 201, 0, 202, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 204, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 210, 0, 0, 212, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 217, 0, 0, 219, 0, + 220, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 222, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 224, 225, 0, 0, 0, + 226, 0, 227, 0, 0, 0, 0, 0, 0, 0, + 0, 230, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 234, 0, 0, 235, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 237, 238, 239, 240, 241, 242, 243, + 244, 245, 86, 87, 88, 0, 90, 91, 92, 0, + 0, 0, 95, 0, 0, 98, 99, 100, 101, 102, + 103, 0, 104, 105, 0, 0, 0, 107, 108, 109, + 110, 0, 111, 112, 113, 114, 115, 0, 116, 117, + 118, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 35, 0, 0, + 0, 0, 0, 0, 0, 41, 42, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 133, 0, 0, 0, 135, 136, 137, 138, 139, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 140, 0, 0, 0, 0, 0, 0, 144, 0, + 145, 0, 0, 0, 0, 0, 148, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 151, 0, 0, + 0, 0, 0, 152, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 155, 156, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 162, 0, 0, 0, 0, 0, 0, 164, 0, 0, + 0, 166, 0, 0, 0, 0, 168, 0, 0, 0, + 0, 0, 169, 0, 170, 0, 0, 0, 0, 0, + 172, 0, 0, 0, 0, 0, 0, 0, 0, 173, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 174, 175, 0, 0, 0, 0, 0, 176, + 0, 177, 0, 0, 178, 179, 0, 180, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 181, 182, 0, + 183, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 188, + 189, 190, 0, 0, 191, 0, 0, 0, 193, 0, + 0, 194, 0, 195, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 196, 197, 198, 199, + 200, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 201, 0, 202, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 204, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 210, 0, 0, 212, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 217, 0, 0, 219, 0, 220, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 222, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 224, 225, 0, 0, 0, 226, 0, + 227, 0, 0, 0, 0, 0, 0, 0, 0, 230, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 234, 0, 0, 235, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 237, 238, 239, 240, 241, 242, 243, 244, 245, + 86, 87, 88, 0, 90, 91, 92, 0, 0, 0, + 95, 0, 0, 98, 99, 100, 101, 102, 103, 0, + 104, 105, 0, 0, 0, 107, 108, 109, 110, 0, + 0, 112, 113, 114, 115, 0, 116, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 35, 0, 0, 0, 0, + 0, 0, 0, 41, 42, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 133, + 0, 0, 0, 135, 136, 137, 138, 139, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 140, + 0, 0, 0, 0, 0, 0, 144, 0, 145, 0, + 0, 0, 0, 0, 148, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 151, 0, 0, 0, 0, + 0, 152, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 155, 156, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 164, 0, 0, 0, 166, + 0, 0, 0, 0, 168, 0, 0, 0, 0, 0, + 169, 0, 170, 0, 0, 0, 0, 0, 172, 0, + 0, 0, 0, 0, 0, 0, 0, 173, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 174, 175, 0, 0, 0, 0, 0, 176, 0, 177, + 0, 0, 178, 179, 0, 180, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 181, 182, 0, 183, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 188, 189, 190, + 0, 0, 191, 0, 0, 0, 193, 0, 0, 194, + 0, 195, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 196, 197, 198, 199, 200, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 201, 0, + 202, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 204, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 210, 0, 0, 212, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 217, 0, 0, 219, 0, 220, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 222, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 224, 225, 0, 0, 0, 226, 0, 227, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 234, 0, 0, 235, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 237, + 238, 239, 240, 241, 242, 243, 244, 245 +}; + +static const yytype_int16 yycheck[] = +{ + 2, 359, 1094, 246, 78, 1089, 1356, 78, 1317, 209, + 78, 228, 1041, 167, 1057, 78, 78, 154, 153, 94, + 876, 1325, 1366, 2, 1159, 117, 1396, 223, 1702, 1219, + 1575, 1736, 836, 187, 1272, 986, 987, 988, 1887, 1321, + 96, 992, 150, 1281, 1197, 1201, 2047, 1871, 1254, 1415, + 106, 1997, 1485, 1428, 2559, 913, 1209, 132, 1741, 171, + 165, 1456, 1457, 78, 711, 160, 203, 1741, 2748, 84, + 162, 1048, 876, 929, 2426, 2427, 78, 2198, 153, 154, + 1475, 1830, 84, 375, 1745, 2, 142, 78, 163, 375, + 1889, 165, 3331, 2905, 3060, 3270, 132, 209, 1631, 1632, + 1633, 157, 1308, 1754, 1927, 1912, 1259, 1785, 3110, 1262, + 3112, 1912, 1912, 2248, 1267, 117, 1912, 1912, 1912, 1736, + 1596, 1274, 2467, 2085, 712, 929, 1200, 2514, 203, 1203, + 1283, 3564, 1793, 3239, 347, 2962, 1136, 1211, 230, 3252, + 1685, 361, 954, 2728, 2901, 2902, 3252, 1798, 1799, 3511, + 2903, 153, 1136, 1503, 3615, 361, 78, 3659, 3608, 3851, + 162, 3834, 84, 1986, 3516, 3517, 3872, 1728, 167, 1626, + 1627, 1357, 89, 1348, 3815, 216, 2838, 2899, 1689, 1209, + 1175, 4282, 2291, 1379, 1086, 3576, 1044, 1936, 187, 4085, + 3449, 1445, 1446, 21, 1929, 117, 30, 3256, 3257, 3258, + 3259, 3260, 3261, 946, 88, 1086, 208, 121, 1131, 1132, + 10, 72, 818, 128, 216, 108, 218, 1471, 128, 156, + 4545, 2330, 135, 88, 3787, 2334, 128, 84, 230, 114, + 78, 4421, 72, 2955, 78, 222, 153, 114, 112, 182, + 162, 145, 159, 149, 180, 228, 86, 8, 113, 2594, + 11, 12, 173, 266, 901, 4526, 236, 75, 76, 77, + 78, 22, 23, 24, 82, 26, 27, 72, 185, 112, + 31, 32, 33, 75, 76, 77, 78, 29, 143, 14, + 82, 86, 319, 95, 209, 75, 76, 77, 78, 324, + 117, 141, 82, 367, 266, 352, 367, 227, 319, 367, + 2149, 1252, 37, 3062, 367, 367, 2968, 266, 230, 184, + 75, 76, 77, 78, 1357, 182, 111, 82, 2663, 296, + 2665, 3782, 75, 76, 77, 78, 117, 270, 229, 82, + 72, 173, 179, 227, 222, 162, 411, 72, 233, 81, + 75, 76, 77, 78, 86, 102, 81, 82, 83, 84, + 153, 86, 75, 76, 77, 78, 78, 227, 378, 82, + 375, 227, 78, 4860, 145, 184, 309, 90, 2475, 1559, + 135, 162, 153, 375, 229, 137, 367, 218, 115, 99, + 72, 1237, 431, 88, 2385, 197, 106, 266, 71, 81, + 180, 1038, 267, 1528, 86, 410, 79, 80, 199, 136, + 0, 1117, 257, 230, 75, 76, 77, 78, 410, 145, + 387, 82, 173, 99, 357, 185, 4687, 208, 145, 90, + 106, 2528, 471, 187, 325, 216, 204, 218, 25, 4530, + 450, 4928, 173, 1237, 182, 372, 99, 227, 473, 230, + 227, 1874, 99, 106, 285, 207, 503, 314, 267, 4090, + 143, 246, 160, 375, 75, 76, 77, 78, 373, 2568, + 100, 82, 224, 373, 1180, 307, 503, 1862, 1863, 103, + 104, 373, 322, 398, 1869, 455, 38, 266, 40, 451, + 1523, 369, 503, 1341, 75, 76, 77, 78, 410, 247, + 260, 82, 451, 506, 75, 76, 77, 78, 419, 90, + 185, 82, 75, 76, 77, 78, 258, 14, 643, 82, + 3269, 75, 76, 77, 78, 78, 503, 90, 82, 367, + 503, 1564, 1565, 367, 232, 429, 90, 72, 820, 1838, + 75, 76, 77, 78, 820, 441, 81, 82, 1842, 25, + 301, 86, 416, 3602, 4734, 1133, 1134, 1153, 75, 76, + 77, 78, 429, 410, 490, 82, 1368, 694, 695, 75, + 76, 77, 78, 506, 4889, 93, 82, 175, 643, 506, + 3683, 456, 451, 416, 1432, 4846, 506, 3683, 356, 4850, + 75, 76, 77, 78, 431, 346, 149, 82, 350, 503, + 503, 506, 226, 4285, 228, 456, 506, 2421, 75, 76, + 77, 78, 165, 1346, 506, 82, 1860, 1861, 135, 503, + 503, 506, 4253, 370, 1868, 499, 1854, 4888, 4079, 694, + 695, 261, 160, 451, 471, 382, 429, 1833, 1781, 117, + 1783, 2430, 240, 503, 499, 1791, 711, 449, 1828, 429, + 506, 643, 1716, 2188, 88, 367, 842, 2192, 429, 4011, + 1366, 367, 3827, 4015, 494, 495, 456, 4298, 4221, 4222, + 4223, 4224, 4225, 503, 465, 262, 374, 501, 2038, 497, + 85, 3846, 3017, 4064, 162, 3934, 433, 438, 419, 449, + 4781, 209, 444, 246, 404, 503, 343, 451, 296, 494, + 495, 299, 827, 429, 232, 460, 1554, 88, 1851, 501, + 490, 503, 429, 505, 128, 453, 3211, 460, 1990, 3214, + 3215, 1613, 955, 3218, 3526, 505, 505, 4613, 404, 506, + 208, 2426, 1645, 3228, 816, 503, 643, 3079, 216, 3081, + 218, 1089, 1613, 868, 2084, 2085, 2397, 3796, 503, 1769, + 1735, 404, 230, 956, 2479, 2095, 4847, 309, 506, 2099, + 503, 2434, 494, 495, 266, 4538, 307, 2107, 2108, 494, + 495, 469, 857, 2045, 449, 422, 903, 424, 227, 1357, + 2120, 2121, 2054, 173, 266, 4416, 262, 469, 3531, 387, + 503, 2131, 4423, 75, 76, 77, 78, 922, 247, 3511, + 82, 496, 497, 498, 499, 2916, 504, 180, 361, 507, + 95, 997, 494, 495, 367, 820, 107, 266, 501, 185, + 173, 965, 505, 967, 816, 969, 221, 2003, 820, 1994, + 2929, 975, 824, 2019, 268, 1256, 901, 461, 903, 2025, + 832, 88, 503, 2344, 307, 2292, 374, 2294, 209, 180, + 322, 1557, 180, 951, 998, 999, 1562, 1563, 382, 470, + 955, 319, 380, 95, 2415, 119, 113, 2111, 2112, 1079, + 235, 863, 75, 76, 77, 78, 173, 1063, 489, 82, + 398, 3216, 3217, 1079, 949, 173, 484, 268, 953, 180, + 954, 151, 503, 95, 260, 219, 143, 3239, 208, 470, + 3612, 236, 429, 266, 816, 503, 952, 1093, 820, 433, + 3252, 309, 197, 117, 455, 907, 162, 2590, 489, 1765, + 325, 967, 503, 969, 151, 917, 3882, 227, 3580, 189, + 380, 175, 503, 979, 926, 501, 95, 236, 248, 505, + 503, 469, 101, 4380, 2639, 4382, 227, 71, 4491, 503, + 345, 858, 998, 999, 946, 79, 80, 355, 162, 373, + 495, 2629, 189, 490, 227, 197, 247, 151, 2001, 451, + 329, 1765, 307, 1038, 1069, 1040, 504, 946, 967, 507, + 969, 309, 306, 314, 230, 266, 503, 3329, 1174, 243, + 4672, 173, 1933, 247, 1415, 197, 240, 503, 180, 816, + 231, 4697, 451, 393, 506, 189, 913, 914, 307, 998, + 999, 1042, 1718, 378, 1040, 1046, 389, 4790, 503, 4371, + 1726, 14, 485, 389, 4376, 4367, 230, 4379, 152, 227, + 284, 503, 2051, 2052, 175, 816, 503, 398, 197, 946, + 75, 76, 77, 78, 1036, 503, 419, 82, 4499, 247, + 1042, 336, 296, 503, 1046, 299, 384, 288, 507, 1064, + 494, 495, 496, 497, 498, 499, 419, 1773, 266, 4298, + 1776, 1777, 1064, 75, 76, 77, 78, 337, 202, 1071, + 82, 2920, 367, 449, 457, 490, 491, 492, 451, 494, + 495, 496, 497, 498, 499, 1002, 469, 71, 72, 240, + 4782, 75, 76, 77, 78, 79, 80, 81, 82, 4652, + 337, 396, 86, 494, 495, 496, 497, 498, 499, 151, + 455, 451, 419, 1030, 1970, 4117, 4789, 309, 252, 429, + 503, 419, 1039, 1839, 336, 367, 1043, 1044, 1045, 227, + 99, 99, 151, 387, 507, 968, 400, 506, 1117, 972, + 973, 974, 1064, 337, 4591, 296, 455, 189, 299, 982, + 4791, 134, 135, 423, 88, 367, 429, 1136, 367, 454, + 451, 4611, 507, 503, 4625, 129, 1970, 336, 228, 824, + 189, 128, 229, 137, 4676, 206, 1167, 832, 147, 113, + 490, 422, 2577, 424, 396, 154, 423, 396, 329, 490, + 2233, 4621, 4622, 396, 2006, 505, 180, 1292, 367, 185, + 501, 1180, 503, 504, 505, 506, 447, 341, 863, 143, + 197, 503, 181, 329, 1131, 1132, 507, 409, 1209, 1136, + 412, 4033, 1224, 369, 192, 329, 4588, 396, 99, 423, + 484, 4043, 1234, 264, 336, 4062, 387, 229, 3743, 496, + 497, 498, 499, 451, 3749, 3750, 3751, 3752, 3753, 3754, + 398, 1042, 1683, 227, 1256, 1046, 75, 76, 77, 78, + 1503, 2117, 917, 82, 22, 367, 180, 4024, 325, 314, + 386, 926, 2510, 247, 260, 461, 4029, 3076, 338, 230, + 4741, 265, 251, 192, 3083, 194, 384, 1289, 4041, 4011, + 503, 206, 266, 4015, 1368, 337, 175, 85, 329, 507, + 88, 449, 505, 218, 288, 4738, 4739, 222, 442, 323, + 230, 503, 174, 2117, 72, 1371, 450, 1373, 337, 453, + 1376, 192, 1378, 469, 288, 1381, 1382, 1383, 816, 2329, + 3915, 3683, 1763, 484, 268, 4448, 1253, 4512, 1394, 1414, + 327, 401, 4448, 1345, 1346, 2329, 1348, 2656, 25, 264, + 307, 1407, 503, 1409, 1356, 412, 4817, 121, 35, 2433, + 506, 240, 2666, 504, 462, 506, 1345, 1346, 137, 1348, + 285, 3372, 1585, 3078, 2612, 2613, 2614, 2615, 2660, 1599, + 1600, 423, 1602, 1675, 371, 4815, 2624, 1366, 250, 1675, + 382, 954, 955, 1599, 1600, 309, 1602, 469, 410, 411, + 504, 160, 506, 1834, 423, 2479, 321, 171, 419, 396, + 319, 180, 443, 1415, 329, 2003, 373, 296, 227, 1615, + 268, 95, 1853, 2773, 1341, 336, 2500, 101, 1345, 1346, + 2, 1348, 160, 336, 506, 323, 4869, 137, 247, 396, + 391, 1443, 3404, 412, 2650, 437, 336, 4908, 152, 1366, + 436, 179, 3587, 153, 2930, 2529, 367, 134, 3845, 183, + 183, 3078, 380, 449, 367, 1540, 1541, 97, 1899, 420, + 1472, 391, 2822, 232, 218, 323, 3154, 451, 222, 3286, + 268, 1573, 210, 78, 121, 3286, 3286, 117, 4663, 84, + 3286, 3286, 3286, 396, 1411, 259, 335, 201, 1500, 1501, + 420, 1503, 3163, 2853, 1540, 1541, 396, 207, 387, 85, + 494, 495, 88, 332, 1516, 1432, 1079, 185, 1520, 439, + 244, 244, 117, 197, 224, 218, 1957, 273, 443, 197, + 2386, 449, 153, 507, 171, 3358, 1369, 325, 2888, 1372, + 309, 285, 1375, 307, 1377, 314, 3891, 1380, 3893, 429, + 240, 1384, 4791, 161, 1042, 1557, 418, 419, 1046, 180, + 494, 495, 496, 497, 498, 499, 429, 162, 1643, 1224, + 1572, 1573, 431, 277, 278, 4387, 4388, 321, 1557, 1234, + 4546, 350, 2386, 1562, 1563, 262, 183, 291, 1505, 504, + 155, 172, 285, 2309, 363, 167, 1792, 1689, 1515, 1601, + 503, 236, 816, 1605, 1606, 503, 296, 1643, 1525, 88, + 367, 1626, 1627, 501, 371, 187, 85, 505, 1713, 88, + 228, 385, 259, 1625, 1626, 1627, 506, 4629, 321, 194, + 247, 261, 336, 231, 1289, 230, 5, 1554, 4318, 396, + 1557, 1558, 349, 506, 109, 1562, 1563, 244, 256, 4371, + 350, 1573, 3022, 367, 4376, 507, 25, 4379, 1637, 357, + 1675, 389, 336, 271, 143, 3316, 35, 1682, 3319, 182, + 307, 247, 307, 1675, 282, 444, 382, 2324, 451, 347, + 1682, 1683, 396, 1662, 1663, 4190, 4191, 1689, 309, 3084, + 288, 419, 268, 367, 1696, 4417, 304, 387, 14, 126, + 398, 336, 506, 1625, 1626, 1627, 494, 495, 496, 497, + 498, 499, 469, 3246, 295, 323, 297, 421, 4445, 423, + 2151, 37, 396, 188, 431, 490, 1728, 433, 1645, 457, + 503, 4411, 367, 4413, 1736, 349, 4702, 88, 382, 1718, + 505, 469, 4469, 3047, 444, 172, 1573, 1726, 385, 325, + 367, 449, 95, 1675, 371, 4100, 4101, 270, 101, 336, + 1682, 1763, 113, 356, 471, 134, 2482, 1689, 161, 377, + 75, 76, 77, 78, 2490, 503, 2492, 82, 1769, 396, + 375, 172, 1573, 192, 2642, 194, 451, 371, 381, 433, + 367, 4603, 143, 222, 1773, 81, 309, 1776, 1777, 268, + 86, 4424, 1894, 232, 507, 1368, 182, 75, 76, 77, + 78, 470, 396, 1815, 82, 410, 4538, 431, 247, 396, + 455, 2679, 249, 1958, 422, 85, 424, 196, 88, 502, + 489, 3037, 1834, 506, 1625, 228, 72, 3636, 503, 75, + 76, 77, 78, 451, 357, 81, 82, 83, 84, 447, + 86, 1853, 469, 113, 197, 85, 325, 471, 88, 119, + 1839, 252, 1689, 256, 2060, 463, 4588, 3616, 295, 1871, + 297, 192, 1789, 194, 88, 105, 1439, 2077, 271, 296, + 307, 4504, 299, 143, 75, 76, 77, 78, 3426, 282, + 403, 82, 1894, 262, 270, 216, 1459, 1899, 1689, 113, + 309, 41, 2007, 336, 295, 1696, 297, 3063, 335, 469, + 319, 304, 3450, 390, 490, 491, 492, 2946, 494, 495, + 496, 497, 498, 499, 4045, 3295, 1489, 14, 3473, 143, + 71, 72, 2006, 309, 367, 3091, 469, 1728, 371, 327, + 1503, 2918, 419, 3792, 389, 372, 506, 376, 336, 1951, + 37, 2243, 506, 507, 192, 1957, 194, 2243, 1960, 182, + 2016, 380, 2018, 396, 2076, 509, 2022, 4472, 2024, 274, + 387, 2027, 1894, 506, 419, 2031, 469, 470, 216, 367, + 407, 357, 336, 3644, 377, 72, 463, 247, 2083, 408, + 3064, 4614, 1994, 314, 2068, 1997, 1913, 2068, 319, 222, + 2068, 4624, 103, 104, 2720, 2068, 2068, 2438, 268, 269, + 3661, 3662, 457, 367, 2870, 1994, 3391, 371, 1997, 389, + 3453, 3454, 491, 492, 1815, 494, 495, 496, 497, 498, + 499, 254, 145, 222, 72, 390, 1599, 1600, 268, 1602, + 153, 451, 396, 3588, 51, 2047, 314, 208, 86, 419, + 222, 262, 312, 242, 268, 269, 2703, 218, 503, 160, + 336, 2153, 69, 16, 419, 325, 2870, 1894, 4790, 97, + 242, 309, 85, 501, 462, 88, 314, 1994, 179, 507, + 1997, 319, 2084, 2085, 307, 1573, 309, 457, 3397, 117, + 2092, 367, 105, 2095, 1910, 325, 4448, 2099, 312, 469, + 384, 320, 2104, 1894, 323, 2107, 2108, 2261, 463, 210, + 3460, 3264, 1928, 2115, 435, 469, 2118, 2119, 2120, 2121, + 396, 4067, 318, 314, 445, 3491, 2128, 2129, 128, 2131, + 3979, 2133, 2134, 503, 4814, 2137, 2940, 421, 2569, 323, + 2245, 386, 218, 3826, 328, 182, 222, 147, 311, 2151, + 2152, 2153, 3976, 323, 2354, 2157, 2356, 352, 328, 2161, + 3865, 161, 274, 2165, 4509, 2167, 2168, 2169, 2170, 2171, + 2172, 2173, 2174, 2175, 506, 2177, 3850, 3035, 510, 506, + 470, 2183, 34, 510, 2186, 469, 470, 2104, 4540, 3395, + 384, 75, 76, 77, 78, 429, 95, 435, 82, 489, + 2396, 1689, 101, 501, 422, 2921, 424, 445, 1696, 285, + 508, 211, 2283, 503, 2349, 380, 381, 254, 357, 503, + 228, 816, 496, 497, 498, 820, 389, 421, 2243, 368, + 121, 2153, 380, 381, 494, 495, 496, 497, 498, 499, + 1728, 2243, 141, 3613, 3614, 321, 2248, 502, 256, 2324, + 503, 506, 2344, 392, 369, 268, 419, 3652, 494, 495, + 490, 491, 492, 271, 494, 495, 496, 497, 498, 499, + 307, 162, 309, 336, 282, 469, 470, 2292, 433, 2294, + 494, 495, 496, 497, 498, 499, 506, 507, 389, 336, + 2292, 190, 2294, 386, 457, 186, 1951, 421, 197, 2216, + 157, 200, 384, 470, 367, 1960, 469, 2738, 498, 503, + 201, 250, 325, 503, 205, 505, 504, 85, 419, 507, + 367, 2243, 489, 469, 470, 504, 2153, 1815, 507, 2331, + 2309, 2333, 223, 396, 3285, 504, 503, 506, 2473, 421, + 503, 504, 2344, 72, 507, 469, 470, 238, 508, 396, + 2329, 150, 2331, 252, 2333, 2821, 457, 2823, 2824, 1573, + 461, 2135, 2153, 3553, 2138, 2457, 487, 488, 469, 377, + 2292, 2373, 2294, 422, 946, 424, 242, 2379, 85, 503, + 384, 88, 125, 2385, 3762, 3520, 3764, 469, 470, 3767, + 386, 3769, 2047, 965, 498, 967, 2313, 969, 105, 503, + 274, 505, 503, 975, 976, 977, 1894, 3265, 307, 3267, + 309, 1625, 2329, 2415, 2331, 3759, 2333, 421, 509, 2421, + 319, 503, 2344, 314, 2426, 2427, 998, 999, 327, 503, + 314, 322, 501, 86, 503, 3239, 2438, 336, 503, 3523, + 3524, 71, 72, 2006, 75, 76, 77, 78, 3252, 79, + 80, 82, 2454, 469, 470, 2457, 86, 125, 384, 494, + 495, 496, 497, 498, 355, 469, 470, 502, 367, 1064, + 3328, 115, 371, 2475, 504, 1689, 506, 490, 491, 492, + 4025, 494, 495, 496, 497, 498, 499, 501, 4489, 503, + 2598, 505, 486, 2410, 95, 421, 206, 396, 71, 503, + 101, 323, 504, 2482, 506, 2068, 79, 80, 218, 78, + 270, 2490, 222, 2492, 4059, 84, 503, 2344, 505, 384, + 504, 506, 506, 96, 310, 311, 2528, 505, 504, 384, + 506, 326, 2454, 137, 504, 2457, 506, 1419, 1420, 143, + 141, 2947, 2948, 469, 470, 1117, 326, 323, 117, 153, + 2908, 4400, 429, 2344, 264, 454, 421, 4319, 4320, 4321, + 4322, 268, 222, 486, 1136, 2567, 421, 2569, 504, 504, + 506, 506, 323, 326, 7, 285, 180, 503, 182, 152, + 3736, 75, 76, 77, 78, 486, 19, 20, 82, 190, + 2592, 270, 4297, 162, 2596, 2158, 197, 115, 2515, 200, + 504, 1606, 506, 389, 469, 470, 39, 3038, 1180, 42, + 2853, 321, 226, 3963, 469, 470, 496, 506, 325, 329, + 503, 3987, 505, 504, 2415, 2627, 504, 2454, 2703, 202, + 2457, 503, 125, 419, 2551, 227, 3874, 2639, 503, 208, + 266, 509, 2559, 85, 507, 496, 88, 216, 503, 218, + 254, 252, 494, 495, 496, 497, 498, 75, 76, 77, + 78, 230, 504, 2454, 82, 2153, 2457, 504, 504, 506, + 506, 457, 262, 504, 247, 506, 2893, 2894, 2895, 252, + 1894, 509, 3398, 469, 429, 2687, 180, 429, 75, 76, + 77, 78, 429, 429, 2611, 82, 504, 503, 506, 86, + 108, 153, 3133, 429, 3135, 309, 307, 504, 309, 506, + 314, 384, 504, 203, 506, 2958, 125, 503, 319, 2636, + 2283, 268, 262, 156, 2379, 2642, 327, 504, 429, 506, + 2385, 505, 504, 443, 506, 336, 2738, 2829, 504, 503, + 506, 2720, 504, 2835, 506, 504, 350, 506, 421, 504, + 2752, 506, 504, 396, 506, 2757, 472, 3188, 85, 363, + 193, 88, 2679, 422, 503, 424, 367, 422, 341, 424, + 371, 2773, 2774, 1345, 1346, 211, 1348, 2779, 105, 231, + 504, 3212, 506, 490, 491, 492, 503, 494, 495, 496, + 497, 498, 499, 180, 1366, 396, 469, 470, 250, 504, + 211, 506, 2804, 2805, 211, 378, 375, 2809, 505, 75, + 76, 77, 78, 504, 323, 506, 82, 222, 211, 2821, + 2822, 2823, 2824, 504, 507, 506, 268, 2829, 283, 504, + 503, 506, 2834, 2835, 182, 2837, 288, 2839, 451, 503, + 444, 410, 4212, 504, 417, 506, 318, 2849, 2850, 323, + 4524, 2853, 504, 454, 506, 504, 2344, 506, 386, 504, + 4204, 506, 2936, 503, 2866, 2936, 2868, 137, 2936, 442, + 2872, 274, 469, 2936, 2936, 108, 328, 450, 309, 3683, + 453, 472, 503, 325, 3315, 504, 2888, 506, 115, 75, + 76, 77, 78, 504, 115, 506, 82, 2899, 89, 2901, + 2902, 2903, 75, 76, 77, 78, 504, 2829, 506, 82, + 504, 3342, 506, 2835, 180, 75, 76, 77, 78, 504, + 336, 506, 82, 2925, 504, 438, 506, 2415, 222, 75, + 76, 77, 78, 150, 353, 2937, 82, 508, 211, 2153, + 2942, 268, 2921, 504, 504, 506, 506, 2949, 211, 504, + 4085, 506, 503, 2955, 75, 76, 77, 78, 504, 211, + 506, 82, 504, 504, 506, 506, 2454, 472, 4334, 2457, + 422, 504, 424, 506, 504, 504, 506, 506, 1573, 3410, + 504, 433, 506, 211, 504, 1557, 506, 504, 211, 506, + 1562, 1563, 444, 4698, 180, 447, 506, 211, 325, 3430, + 211, 504, 2829, 506, 2921, 504, 211, 506, 2835, 504, + 323, 506, 504, 3015, 506, 211, 504, 4060, 506, 504, + 504, 506, 506, 504, 3455, 506, 504, 504, 506, 506, + 1625, 1626, 1627, 504, 4384, 506, 3038, 504, 2829, 506, + 504, 211, 506, 3759, 2835, 4016, 4199, 4018, 490, 491, + 492, 323, 494, 495, 496, 497, 498, 499, 211, 1083, + 3491, 1085, 211, 1635, 211, 1637, 419, 108, 503, 223, + 283, 222, 222, 323, 503, 503, 3078, 3079, 503, 3081, + 1675, 222, 503, 1655, 346, 333, 503, 1682, 503, 503, + 1662, 1663, 108, 503, 1689, 163, 283, 2752, 266, 503, + 506, 503, 2757, 503, 503, 503, 503, 503, 3110, 3111, + 3112, 503, 503, 4483, 2119, 503, 268, 503, 3035, 503, + 503, 503, 503, 503, 503, 503, 503, 108, 2133, 222, + 2344, 3133, 321, 3135, 222, 396, 496, 262, 387, 506, + 299, 179, 3234, 450, 506, 490, 1718, 14, 506, 503, + 429, 503, 503, 429, 1726, 384, 505, 153, 429, 3251, + 429, 429, 384, 490, 491, 492, 384, 494, 495, 496, + 497, 498, 499, 429, 429, 211, 388, 280, 323, 314, + 145, 323, 429, 429, 429, 450, 3188, 252, 3110, 3111, + 3112, 3907, 319, 503, 4050, 429, 153, 4563, 429, 3116, + 503, 1773, 3337, 3340, 1776, 1777, 506, 336, 451, 451, + 3212, 174, 125, 429, 429, 125, 327, 4567, 114, 429, + 429, 429, 429, 429, 114, 429, 3143, 429, 384, 506, + 429, 429, 3234, 323, 472, 3306, 3238, 3239, 323, 268, + 2454, 460, 108, 2457, 2899, 469, 4050, 816, 107, 3251, + 3252, 820, 503, 97, 309, 211, 180, 451, 3501, 503, + 3239, 462, 503, 503, 291, 3340, 4632, 1839, 3511, 3340, + 4636, 4637, 319, 3252, 309, 463, 108, 222, 503, 108, + 274, 385, 211, 3110, 3111, 3112, 3503, 3504, 3505, 3506, + 2853, 211, 211, 451, 3211, 211, 451, 3214, 3215, 1894, + 2955, 3218, 505, 4254, 2867, 211, 4650, 14, 318, 506, + 429, 3228, 3234, 3315, 4406, 313, 3233, 465, 227, 3110, + 3111, 3112, 3239, 2886, 4633, 503, 503, 3329, 3245, 3251, + 4634, 427, 301, 301, 88, 3252, 2899, 506, 396, 503, + 3342, 2829, 486, 427, 227, 506, 503, 2835, 3265, 429, + 3267, 490, 431, 241, 241, 319, 264, 324, 4640, 451, + 4642, 34, 10, 506, 504, 503, 429, 429, 504, 506, + 3372, 1943, 506, 2936, 3466, 384, 504, 152, 4728, 384, + 71, 3298, 504, 503, 75, 76, 77, 78, 79, 80, + 451, 82, 2955, 272, 272, 2958, 314, 314, 429, 386, + 274, 503, 3833, 314, 403, 3407, 115, 3234, 3410, 323, + 3327, 3328, 429, 384, 429, 3417, 127, 322, 330, 3398, + 506, 3423, 1994, 3425, 3251, 1997, 367, 393, 3430, 3431, + 357, 268, 3434, 3435, 3436, 3437, 3438, 3439, 3440, 3441, + 3442, 3443, 108, 3234, 429, 3447, 3448, 429, 159, 268, + 268, 451, 268, 3455, 451, 268, 490, 322, 3460, 503, + 3251, 107, 3464, 211, 3466, 490, 3468, 429, 501, 501, + 429, 222, 393, 1042, 224, 503, 3478, 1046, 319, 3481, + 211, 3483, 210, 469, 175, 323, 393, 323, 222, 3491, + 3492, 3493, 3494, 497, 239, 1064, 3498, 239, 108, 3501, + 4529, 211, 323, 214, 393, 222, 323, 247, 247, 3511, + 247, 506, 472, 506, 96, 233, 298, 323, 4602, 3521, + 125, 419, 506, 318, 504, 2097, 2098, 3529, 274, 3531, + 504, 504, 227, 2105, 245, 340, 506, 2109, 2110, 227, + 486, 466, 486, 504, 3466, 3699, 504, 429, 503, 240, + 504, 504, 2124, 504, 2126, 504, 3987, 504, 2153, 332, + 3477, 504, 4418, 90, 504, 4874, 504, 504, 504, 280, + 503, 90, 504, 3575, 2146, 466, 2148, 457, 374, 3581, + 285, 507, 323, 506, 211, 3587, 2804, 2805, 490, 490, + 3682, 2809, 3684, 326, 323, 250, 429, 4453, 309, 472, + 504, 429, 429, 506, 504, 296, 503, 258, 299, 503, + 3612, 314, 327, 3530, 4418, 2829, 211, 429, 211, 341, + 285, 2835, 3110, 3111, 3112, 341, 2198, 429, 448, 429, + 429, 2849, 2850, 293, 293, 293, 429, 429, 429, 3466, + 384, 429, 833, 429, 4448, 429, 384, 838, 2243, 4453, + 429, 211, 384, 396, 160, 429, 847, 384, 114, 429, + 371, 268, 373, 299, 375, 268, 268, 4098, 268, 268, + 381, 268, 268, 504, 504, 3466, 3678, 388, 501, 285, + 3682, 3683, 3684, 874, 369, 396, 490, 878, 173, 2261, + 504, 438, 503, 322, 405, 4126, 387, 2292, 889, 2294, + 206, 323, 413, 506, 3683, 506, 504, 4138, 108, 89, + 429, 236, 218, 222, 384, 451, 222, 3372, 326, 506, + 384, 227, 98, 384, 268, 451, 232, 209, 209, 235, + 501, 237, 203, 227, 88, 222, 504, 2309, 504, 504, + 504, 462, 135, 3306, 227, 503, 3234, 504, 503, 2344, + 506, 4182, 504, 464, 503, 131, 3678, 2329, 264, 2331, + 3682, 2333, 3684, 3251, 222, 235, 3683, 490, 144, 504, + 324, 108, 451, 451, 258, 429, 506, 3340, 490, 285, + 3759, 157, 438, 3700, 504, 438, 3703, 167, 3705, 4740, + 3861, 504, 429, 484, 429, 503, 3775, 384, 429, 2804, + 2805, 429, 504, 384, 2809, 504, 3808, 187, 504, 222, + 143, 173, 3729, 3730, 438, 321, 268, 504, 268, 195, + 502, 272, 503, 329, 469, 472, 3743, 222, 504, 506, + 3901, 3833, 3749, 3750, 3751, 3752, 3753, 3754, 506, 469, + 148, 253, 3759, 421, 2849, 2850, 3763, 85, 224, 506, + 429, 3678, 504, 229, 503, 3682, 3511, 3684, 393, 2454, + 232, 227, 2457, 3865, 3866, 3867, 268, 268, 374, 268, + 3787, 268, 504, 362, 227, 125, 467, 4077, 503, 467, + 4736, 3798, 3799, 3800, 3801, 504, 504, 3678, 504, 506, + 503, 3682, 271, 3684, 331, 125, 3110, 3111, 3112, 503, + 271, 237, 319, 4334, 490, 98, 504, 429, 227, 143, + 2482, 469, 504, 419, 252, 438, 314, 4071, 2490, 490, + 2492, 506, 314, 506, 3926, 429, 211, 268, 3907, 187, + 314, 229, 4736, 502, 227, 451, 393, 443, 3501, 451, + 1131, 1132, 108, 198, 465, 3862, 503, 227, 3511, 325, + 503, 469, 145, 255, 469, 227, 326, 3612, 503, 362, + 466, 3963, 468, 469, 503, 456, 406, 504, 504, 4123, + 503, 3973, 3974, 503, 3976, 271, 468, 353, 3466, 3981, + 3982, 174, 339, 323, 3986, 3987, 4057, 504, 363, 503, + 3992, 3993, 469, 504, 3996, 501, 504, 429, 504, 505, + 503, 507, 195, 2575, 1573, 222, 3923, 108, 384, 4011, + 314, 294, 210, 4015, 390, 250, 504, 393, 173, 125, + 3234, 327, 4024, 503, 490, 4383, 381, 4029, 503, 381, + 125, 224, 329, 451, 503, 323, 229, 3251, 307, 4041, + 421, 217, 354, 419, 137, 326, 137, 193, 455, 425, + 85, 362, 456, 506, 108, 227, 1625, 1626, 1627, 360, + 466, 222, 438, 198, 469, 4067, 4045, 252, 108, 323, + 323, 504, 503, 503, 326, 4229, 504, 326, 4080, 125, + 380, 185, 275, 503, 449, 380, 94, 463, 4067, 105, + 210, 354, 503, 367, 1816, 1177, 4098, 2597, 1563, 2921, + 2464, 3091, 3682, 3233, 2522, 4475, 1675, 4650, 4202, 4273, + 4202, 4518, 4524, 1682, 3854, 4117, 4247, 4528, 2708, 3016, + 1689, 4821, 4417, 4873, 4126, 4773, 4772, 1696, 4045, 4046, + 85, 4836, 4563, 88, 4673, 3020, 4138, 3819, 4274, 2588, + 2588, 3111, 3678, 1914, 3824, 3826, 2583, 3297, 2720, 4878, + 4067, 4941, 4933, 3238, 3251, 4843, 4455, 1906, 113, 1728, + 353, 4751, 4593, 4829, 119, 4458, 187, 1403, 4610, 3863, + 2119, 3910, 4698, 2427, 3865, 3190, 4855, 4935, 4665, 2245, + 4182, 1058, 2246, 2007, 2133, 378, 2936, 3848, 143, 914, + 3678, 384, 3585, 1359, 3682, 4117, 3684, 390, 4058, 2691, + 4202, 4632, 1073, 2937, 2281, 4636, 4637, 2949, 1609, 2280, + 2943, 2264, 2963, 3431, 1608, 1591, 3434, 3435, 3436, 3437, + 3438, 3439, 3440, 3441, 3442, 3443, 419, 3511, 421, 2955, + 4589, 2180, 4017, 3586, 2829, 4565, 1611, 1063, 3476, 3468, + 2835, 1615, 4808, 4245, 4809, 438, 1815, 2867, 4812, 2940, + 205, 2775, 3466, 2865, 3581, 2183, 643, 3337, 2643, 1296, + 1945, 2313, 4799, 1627, 376, 948, 1621, 2289, 1154, 2329, + 463, 1134, 1134, 4190, 4191, 3493, 3494, 2321, 3592, 2915, + 4202, 1414, 2322, 1537, 4044, 3593, 3558, 4204, 243, 1625, + 4117, 4208, 247, 4210, 409, 4297, 4213, 4214, 3861, 2333, + 2704, 2036, 1345, 2, 4221, 4222, 4223, 4224, 4225, 978, + -1, -1, -1, 268, 269, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 1894, 4117, -1, 4330, 284, + -1, -1, 4334, -1, -1, -1, -1, 4339, 3901, -1, + -1, -1, -1, -1, 2916, -1, 4402, 2919, -1, 2921, + -1, -1, 4269, -1, 4356, 4357, 4011, 312, 4360, -1, + 4015, -1, -1, -1, -1, -1, 98, -1, -1, 4371, + 325, -1, -1, -1, 4376, 4202, -1, 4379, 110, 4296, + -1, -1, 4384, 4385, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 131, + -1, -1, 4319, 4320, 4321, 4322, -1, -1, -1, -1, + 1332, 4202, 144, -1, -1, 4417, 4395, -1, -1, -1, + -1, 1343, -1, -1, -1, 157, 3431, -1, -1, 3434, + 3435, 3436, 3437, 3438, 3439, 3440, 3441, 3442, 3443, 4510, + -1, -1, 174, -1, -1, 400, 4448, -1, 4011, -1, + 4452, -1, 4015, -1, 1645, -1, -1, -1, -1, 3464, + -1, -1, -1, 195, 3678, -1, -1, -1, 3682, 4448, + 3684, -1, -1, -1, -1, -1, -1, 108, -1, -1, + -1, 213, -1, -1, -1, -1, -1, 4489, 3493, 3494, + -1, -1, 224, -1, 4057, -1, 127, 229, -1, -1, + -1, -1, -1, 235, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 3110, 3111, 3112, 250, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 159, -1, + -1, 4448, -1, -1, -1, -1, 4538, -1, 4540, 494, + 495, 496, 497, 498, 499, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 4472, -1, -1, -1, 4476, + 4562, 4563, -1, 4565, -1, 4567, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 4584, 214, 2153, 965, 4588, 967, -1, 969, + 3808, 4593, -1, 325, -1, 975, -1, -1, -1, -1, + -1, -1, -1, 335, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 245, -1, -1, -1, 998, 999, + -1, 353, 1813, -1, -1, -1, -1, 4629, -1, 4117, + 4632, -1, -1, -1, 4636, 4637, -1, -1, -1, 3234, + -1, -1, -1, 274, -1, -1, 378, -1, 4891, 280, + 382, -1, 384, -1, 127, -1, 3251, -1, 390, -1, + -1, 393, -1, -1, -1, -1, -1, 3239, 4670, -1, + -1, -1, 3244, 3245, 2243, -1, -1, -1, 309, -1, + 3252, -1, -1, -1, -1, -1, 159, 419, -1, 421, + -1, -1, -1, 425, -1, -1, 4698, -1, -1, -1, + -1, 433, -1, 4705, -1, -1, 438, 4629, 3280, -1, + -1, -1, -1, -1, 4202, -1, 4371, -1, 450, -1, + 1911, 4376, -1, 2292, 4379, 2294, 4728, -1, -1, -1, + -1, 463, -1, 4650, -1, -1, 1927, 1117, -1, -1, + 371, 214, -1, 4745, 375, -1, -1, -1, -1, -1, + 381, 1131, 1132, -1, -1, -1, 1136, 388, -1, -1, + -1, -1, 4417, 3981, 3982, 396, -1, -1, -1, -1, + -1, -1, 245, -1, 405, 2344, -1, -1, 4780, -1, + -1, 4855, 413, -1, 4855, -1, -1, 4855, 4790, -1, + -1, -1, 4855, 4855, 4886, 1986, -1, 4452, -1, -1, + 1180, -1, 4629, 3808, -1, -1, -1, 280, 4371, 4811, + 4812, -1, -1, 4376, -1, -1, 4379, 4891, -1, -1, + 4891, -1, 4824, 4891, -1, -1, 3398, -1, 4891, 4891, + -1, -1, -1, 464, 4489, -1, 309, 468, 4629, -1, + -1, 4933, -1, -1, -1, -1, 2415, 89, -1, 4941, + -1, -1, 94, -1, -1, 2804, 2805, -1, 4860, -1, + 2809, 4935, -1, 336, 4935, -1, -1, 4935, 4870, -1, + -1, 3466, 4935, 4935, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 4538, 4886, 2454, -1, -1, 2457, -1, + 132, -1, -1, -1, 367, -1, -1, -1, 371, -1, + 2849, 2850, 375, 4117, -1, -1, -1, 4886, 381, -1, + -1, 153, -1, -1, -1, 388, -1, -1, -1, -1, + -1, -1, -1, 396, -1, -1, 4928, -1, -1, 171, + -1, 4933, 405, 4588, -1, 4937, -1, -1, -1, 4941, + 413, -1, 184, -1, -1, -1, 85, 4510, -1, 88, + 192, 108, -1, -1, 4933, -1, -1, -1, -1, -1, + -1, -1, 4941, -1, 4886, 207, -1, 209, -1, 4886, + 127, 213, -1, -1, 113, -1, 3981, 3982, -1, -1, + 119, 223, -1, -1, -1, -1, 1366, -1, 4202, 231, + -1, 464, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 159, -1, 143, -1, -1, -1, -1, -1, + -1, 4933, -1, -1, -1, -1, 4933, 3589, -1, 4941, + -1, -1, -1, -1, 4941, 4588, -1, -1, -1, -1, + 1952, -1, -1, -1, -1, -1, -1, -1, -1, 1961, + -1, -1, -1, 1965, -1, -1, -1, -1, -1, 1971, + 1972, -1, -1, -1, -1, -1, -1, 214, 85, 4886, + -1, 88, -1, -1, -1, -1, 205, 1989, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 3678, -1, -1, 113, 3682, 245, 3684, + -1, -1, 119, -1, -1, 4886, -1, -1, -1, -1, + -1, -1, -1, -1, 243, -1, 4933, -1, 247, -1, + -1, 3683, 4330, -1, 4941, -1, 143, 274, -1, -1, + -1, -1, 2313, 280, -1, 4780, -1, 3699, -1, 268, + 269, -1, -1, -1, -1, 4790, -1, -1, 4356, 4357, + -1, 4629, 4933, -1, 108, 284, -1, -1, -1, 2340, + 4941, -1, 309, -1, 2345, -1, -1, 2348, -1, -1, + -1, -1, -1, 127, -1, -1, -1, -1, -1, 4824, + -1, -1, -1, 312, -1, -1, -1, 1557, -1, 2370, + -1, -1, 1562, 1563, -1, -1, 325, 3759, -1, -1, + -1, -1, -1, -1, -1, 159, -1, -1, -1, -1, + -1, -1, 3774, 3775, -1, -1, -1, -1, -1, -1, + -1, 3783, -1, 2404, 371, 3787, 243, -1, 375, -1, + 247, -1, -1, -1, 381, -1, 3798, -1, -1, -1, + -1, 388, -1, -1, -1, -1, -1, -1, -1, 396, + 2431, 268, 269, -1, -1, -1, -1, -1, 405, -1, + 214, -1, -1, -1, -1, -1, 413, 284, -1, -1, + 2829, 400, -1, -1, 2455, 1645, 2835, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 245, 4937, 2474, -1, 312, 2477, -1, -1, -1, + -1, -1, 4855, -1, -1, -1, -1, -1, 325, -1, + -1, -1, -1, -1, 2495, -1, -1, 464, -1, -1, + 274, 468, 469, -1, 2505, -1, 280, -1, -1, -1, + 2242, -1, -1, -1, -1, 4330, -1, 2518, 4891, -1, + -1, -1, -1, -1, 4339, 3907, 2527, -1, 1718, -1, + -1, -1, -1, -1, 4562, 309, 1726, -1, -1, -1, + -1, 4356, 4357, -1, -1, 494, 495, 496, 497, 498, + 499, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 4935, 400, -1, 85, -1, -1, 88, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 1773, -1, 105, 1776, 1777, 4886, -1, + -1, 643, -1, 113, -1, -1, -1, 371, -1, 119, + -1, 375, -1, -1, -1, 4629, -1, 381, -1, -1, + -1, -1, -1, -1, 388, -1, -1, -1, -1, -1, + -1, -1, 396, 143, -1, -1, -1, -1, -1, -1, + -1, 405, -1, -1, -1, 4933, -1, -1, -1, 413, + -1, -1, -1, 4941, -1, -1, -1, -1, -1, 1839, + -1, -1, -1, 490, 491, 492, -1, 494, 495, 496, + 497, 498, 499, 4045, -1, -1, -1, -1, -1, -1, + -1, -1, 3431, -1, -1, 3434, 3435, 3436, 3437, 3438, + 3439, 3440, 3441, 3442, 3443, 4067, -1, -1, -1, 4071, + 464, -1, -1, -1, 468, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 3464, -1, -1, -1, -1, + -1, -1, 4117, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 243, -1, -1, -1, 247, 71, -1, + -1, 3110, 3111, 3112, 3493, 3494, 79, 80, -1, -1, + -1, 4123, 85, -1, -1, 88, -1, 4562, 268, 269, + -1, -1, -1, -1, 4136, 4137, -1, -1, -1, 4141, + 4142, -1, 105, -1, 284, 108, -1, -1, -1, -1, + 113, -1, 824, 825, 826, 827, 119, 829, 830, -1, + 832, 833, 834, -1, 836, -1, 838, -1, 840, 309, + 842, -1, 312, -1, 846, 847, 848, 4202, -1, -1, + 143, -1, -1, -1, 856, 325, -1, -1, 328, 861, + -1, 863, -1, -1, 866, -1, 868, -1, 870, -1, + -1, -1, 874, -1, 876, -1, 878, 879, -1, -1, + -1, -1, -1, -1, 886, -1, -1, 889, -1, 4221, + 4222, 4223, 4224, 4225, -1, -1, -1, 4229, -1, -1, + -1, -1, -1, -1, -1, 3234, -1, -1, -1, -1, + -1, 913, 4886, -1, -1, 917, -1, -1, -1, -1, + 922, -1, 3251, -1, 926, -1, -1, 929, -1, -1, + 400, -1, -1, -1, -1, 95, -1, -1, -1, -1, + -1, 101, 944, -1, -1, -1, -1, -1, -1, -1, + 243, -1, -1, 955, 247, -1, -1, -1, -1, 4933, + -1, -1, -1, -1, -1, -1, -1, 4941, -1, -1, + -1, -1, -1, 2655, -1, 268, 269, -1, -1, -1, + -1, 141, -1, -1, -1, -1, -1, -1, -1, 2671, + 2672, 284, -1, 2675, -1, 997, -1, -1, -1, 2681, + -1, -1, -1, -1, -1, -1, -1, 1009, 1010, -1, + -1, -1, -1, -1, -1, -1, 309, -1, -1, 312, + 490, 491, 492, -1, 494, 495, 496, 497, 498, 499, + 190, -1, 325, -1, 1036, 328, 506, 197, 1040, 1041, + 200, -1, 1044, 2994, -1, -1, -1, -1, -1, -1, + 85, -1, -1, 88, -1, -1, -1, 1059, -1, -1, + -1, 1063, 85, 4395, -1, 88, -1, -1, 2750, 1071, + -1, -1, -1, -1, -1, -1, -1, -1, 113, 1081, + -1, -1, 105, -1, 119, -1, -1, -1, -1, -1, + 113, 1093, 252, -1, -1, -1, 119, -1, -1, 3808, + -1, -1, -1, -1, -1, -1, -1, 400, 143, -1, + -1, -1, -1, -1, -1, -1, 4448, -1, -1, -1, + 143, 2261, -1, -1, -1, -1, -1, -1, -1, 1131, + 1132, -1, -1, -1, -1, -1, -1, 3466, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 307, -1, 309, + 927, -1, -1, -1, 931, -1, -1, -1, -1, 319, + -1, -1, -1, -1, 941, -1, -1, 327, -1, 2309, + -1, -1, 1174, 2313, -1, -1, 336, -1, 3129, -1, + 1182, 1183, -1, -1, -1, 3136, -1, -1, -1, 2329, + -1, -1, -1, -1, -1, -1, -1, 490, 491, 492, + -1, 494, 495, 496, 497, 498, 499, 367, 243, -1, + -1, 371, 247, 95, -1, -1, -1, -1, -1, 101, + 243, -1, 1224, -1, 247, -1, -1, -1, -1, -1, + -1, -1, 1234, 268, 269, 1237, 396, -1, -1, -1, + -1, -1, -1, -1, -1, 268, 269, -1, 1250, 284, + -1, -1, -1, -1, -1, 3206, -1, -1, -1, 141, + -1, 284, 1264, -1, -1, -1, -1, -1, 1270, 1271, + -1, -1, 3981, 3982, 4629, -1, -1, 312, -1, -1, + -1, -1, 1284, 1285, 1286, 1287, 309, 1289, -1, 312, + 325, 1293, -1, -1, 454, -1, -1, -1, -1, -1, + -1, 95, 325, -1, -1, 328, -1, 101, 190, -1, + -1, -1, -1, -1, -1, 197, -1, -1, 200, 1321, + 1322, 1323, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 1341, + -1, -1, 2482, 3025, -1, -1, -1, 141, -1, 3678, + 2490, -1, 2492, 3682, 1356, 3684, -1, -1, -1, -1, + -1, -1, -1, -1, 1366, 400, -1, -1, -1, -1, + 252, -1, -1, 4705, -1, -1, -1, 400, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 1396, 1397, 190, -1, -1, 1401, + -1, 1403, -1, 197, -1, -1, 200, 3358, -1, -1, + -1, -1, -1, -1, -1, -1, 3098, -1, 3100, -1, + -1, -1, -1, 1425, 3375, 307, 1428, 309, -1, 1431, + 1432, -1, -1, -1, -1, -1, -1, 319, -1, -1, + -1, 1443, 3393, -1, -1, 327, -1, -1, -1, -1, + -1, -1, -1, -1, 336, -1, 491, 492, 252, 494, + 495, 496, 497, 498, 499, -1, -1, 490, 491, 492, + 1472, 494, 495, 496, 497, 498, 499, -1, -1, 502, + -1, -1, -1, -1, -1, 508, -1, -1, -1, 371, + -1, -1, 85, -1, -1, 88, -1, -1, 1500, 1501, + -1, 1503, -1, -1, -1, 3187, -1, -1, -1, -1, + 3192, -1, 105, 307, 396, 309, -1, -1, 1520, -1, + 113, -1, -1, -1, -1, 319, 119, -1, -1, -1, + -1, 4886, -1, 327, 85, -1, -1, 88, 1540, 1541, + -1, -1, 336, -1, -1, -1, -1, -1, -1, 1326, + 143, -1, 1554, 85, 4886, -1, 88, -1, -1, -1, + 1562, 1563, 113, -1, -1, -1, -1, 1569, 119, -1, + 1572, -1, 454, 367, -1, -1, -1, 371, 4933, -1, + 2720, 113, -1, -1, -1, -1, 4941, 119, -1, -1, + -1, -1, 143, -1, -1, -1, -1, -1, -1, 1601, + -1, 4933, 396, 1605, 1606, -1, -1, -1, -1, 4941, + -1, 143, -1, 1615, 1616, 1617, -1, -1, -1, -1, + -1, 4330, -1, -1, -1, 1402, -1, -1, -1, -1, + 4339, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 1417, 1643, -1, 1645, -1, -1, -1, 4356, 4357, -1, + 243, -1, 1429, -1, 247, -1, -1, -1, -1, 3341, + 454, -1, -1, 3345, 3346, -1, 3348, -1, 3350, 3351, + -1, -1, -1, 205, -1, 268, 269, 3359, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 3639, -1, + -1, 284, 243, -1, -1, 98, 247, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 3392, 243, -1, -1, -1, 247, 309, 268, 269, 312, + -1, -1, -1, -1, -1, -1, -1, -1, 131, -1, + -1, -1, 325, 284, -1, 328, 268, 269, 1740, 1741, + -1, 144, 145, -1, -1, 1747, -1, -1, 1750, -1, + 153, -1, 284, -1, 157, -1, -1, -1, 309, -1, + -1, 312, -1, 1765, -1, 3716, -1, -1, 3719, -1, + 1772, 174, -1, -1, 325, -1, -1, -1, -1, 95, + 312, 2921, -1, -1, -1, 101, -1, -1, 4117, -1, + 1792, -1, 195, 325, -1, -1, -1, -1, 1800, 1801, + 1802, 1803, 1804, -1, -1, -1, -1, 400, -1, -1, + 213, 1813, -1, -1, -1, 1592, 1818, -1, -1, -1, + -1, 224, -1, -1, -1, 141, 229, -1, 1830, -1, + 1832, -1, -1, -1, -1, -1, -1, -1, 1840, 1841, + -1, -1, -1, -1, 1846, -1, -1, 250, -1, 400, + -1, -1, -1, 4562, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 400, -1, + -1, -1, 275, 4202, 190, -1, -1, -1, -1, -1, + 85, 197, -1, 88, 200, -1, -1, -1, -1, -1, + -1, 1893, -1, -1, -1, -1, -1, 490, 491, 492, + 105, 494, 495, 496, 497, 498, 499, -1, 113, 1911, + -1, -1, -1, 506, 119, 1917, 1918, 1919, 1920, -1, + -1, -1, 325, -1, -1, 1927, -1, -1, -1, -1, + -1, -1, -1, -1, 1936, -1, 252, -1, 143, 490, + 491, 492, -1, 494, 495, 496, 497, 498, 499, 1951, + 353, -1, -1, -1, -1, -1, 1958, -1, 1960, -1, + -1, -1, 494, 495, 496, 497, 498, 499, 1970, -1, + -1, -1, -1, 1975, -1, 378, -1, -1, -1, 382, + -1, 384, 1984, -1, 1986, -1, -1, 390, 1990, 1991, + 393, 307, -1, 309, -1, -1, -1, -1, -1, -1, + -1, -1, 2004, 319, -1, 2007, -1, -1, -1, -1, + -1, 327, -1, -1, -1, -1, 419, -1, 421, -1, + 336, -1, 425, -1, -1, -1, -1, -1, -1, -1, + 433, -1, -1, -1, -1, 438, 2038, -1, 243, -1, + -1, -1, 247, 2045, -1, 2047, -1, -1, -1, 2051, + 2052, 367, 2054, -1, -1, 371, 95, -1, 2060, -1, + 463, -1, 101, 268, 269, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 2076, 2077, -1, -1, 2080, 284, + 396, -1, 2084, 2085, -1, -1, -1, -1, -1, -1, + 2092, -1, -1, 2095, -1, -1, -1, 2099, -1, 3239, + -1, -1, 141, -1, 309, 2107, 2108, 312, -1, -1, + -1, -1, 3252, 2115, -1, 2117, 2118, 2119, 2120, 2121, + 325, -1, -1, 328, -1, -1, 2128, 2129, -1, 2131, + -1, 2133, 2134, -1, -1, 2137, -1, -1, 454, -1, + -1, -1, -1, -1, -1, -1, 95, -1, -1, -1, + 2152, 190, 101, -1, 2156, 2157, -1, -1, 197, 2161, + -1, 200, -1, 2165, -1, 2167, 2168, 2169, 2170, 2171, + 2172, 2173, 2174, 2175, -1, 2177, -1, -1, -1, -1, + 2182, 2183, 4133, -1, 2186, 1962, -1, -1, -1, -1, + -1, -1, 141, -1, 4145, 400, 1973, -1, -1, -1, + -1, -1, -1, -1, -1, 2207, 3888, -1, 1985, -1, + -1, -1, -1, 252, 3896, 3897, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 190, 2244, -1, 2246, -1, 2248, -1, 197, -1, + -1, 200, -1, -1, -1, -1, -1, -1, 3398, -1, + -1, -1, -1, -1, -1, -1, -1, 2044, 307, -1, + 309, 2048, -1, 2050, -1, -1, 2053, -1, -1, -1, + 319, -1, 2284, -1, 2286, 490, 491, 492, 327, 494, + 495, 496, 497, 498, 499, -1, -1, 336, -1, 504, + 4629, -1, -1, 252, -1, -1, -1, -1, -1, -1, + -1, 2313, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 367, -1, + -1, -1, 371, -1, -1, -1, -1, -1, 2340, -1, + -1, -1, -1, 2345, -1, -1, 2348, 2349, -1, -1, + -1, -1, 2354, -1, 2356, -1, -1, 396, 307, -1, + 309, -1, -1, -1, -1, -1, -1, -1, 2370, -1, + 319, 2373, -1, -1, -1, -1, -1, 2379, 327, 2381, + 2382, 2383, -1, 2385, 2386, -1, 2388, 336, 2390, -1, + 2392, 2393, -1, -1, 2396, -1, -1, -1, -1, -1, + -1, -1, 2404, -1, -1, -1, -1, -1, -1, 98, + -1, -1, -1, -1, 4096, 454, 85, -1, 367, 88, + -1, -1, 371, -1, -1, -1, -1, -1, -1, 2431, + -1, -1, 2434, -1, -1, -1, -1, -1, 2440, -1, + -1, -1, -1, 2445, 113, 4127, 4128, 396, -1, 2451, + 119, -1, -1, 2455, -1, 144, -1, -1, -1, -1, + -1, -1, -1, -1, 2466, 2467, -1, -1, 157, -1, + 85, 2473, 2474, 88, 143, 2477, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 174, 2488, -1, -1, -1, + 105, 180, -1, 2495, -1, -1, -1, -1, 113, -1, + -1, 4183, 4184, 2505, 119, 454, 195, -1, -1, -1, + -1, -1, 2514, -1, 2516, 2517, 2518, -1, -1, -1, + -1, -1, -1, -1, 213, 2527, -1, -1, 143, -1, + -1, -1, -1, -1, -1, 224, 205, -1, -1, -1, + 229, -1, 2544, 3683, -1, -1, 235, -1, -1, -1, + 2552, 2553, 2554, 2555, 2556, 2557, -1, 4886, -1, 3699, + -1, 250, -1, -1, -1, 2567, -1, -1, -1, -1, + -1, -1, -1, -1, 243, -1, -1, -1, 247, -1, + -1, -1, -1, -1, -1, -1, 275, -1, 2590, -1, + -1, -1, 2594, 2595, -1, -1, -1, 2599, -1, 268, + 269, -1, -1, -1, 4933, -1, -1, -1, -1, -1, + -1, -1, 4941, -1, -1, 284, -1, 85, -1, 3759, + 88, -1, 4304, 2625, 4306, 4307, -1, -1, 243, -1, + 2632, 2633, 247, -1, -1, 4317, 325, 105, -1, -1, + 2642, 2643, -1, 312, -1, 113, -1, -1, -1, -1, + -1, 119, -1, 268, 269, 2432, 325, -1, 2660, -1, + 2662, 2663, 2664, 2665, 353, -1, -1, -1, -1, 284, + -1, -1, -1, -1, -1, 143, -1, 2679, -1, -1, + -1, -1, -1, -1, -1, 2687, -1, -1, -1, 378, + -1, -1, -1, -1, 309, 384, -1, 312, -1, -1, + -1, 390, -1, -1, 393, -1, 2708, -1, -1, -1, + 325, -1, -1, 328, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 2726, -1, -1, -1, -1, -1, + 419, 400, 421, -1, 85, -1, 425, 88, -1, -1, + -1, -1, -1, -1, 433, -1, 2748, -1, -1, 438, + 2752, -1, -1, 85, 105, 2757, 88, -1, -1, -1, + -1, 450, 113, -1, -1, 2767, -1, 3907, 119, -1, + -1, 2773, 2774, -1, 463, 243, -1, 2779, -1, 247, + -1, 113, -1, -1, -1, 400, -1, 119, -1, -1, + -1, -1, 143, 95, -1, -1, -1, -1, -1, 101, + 268, 269, 2804, 2805, -1, -1, -1, 2809, -1, -1, + -1, 143, -1, -1, -1, -1, 284, -1, -1, 2821, + 2822, 2823, 2824, -1, -1, 494, 495, 496, 497, 498, + 499, -1, 2834, -1, -1, 2837, -1, 2839, 2840, 141, + -1, 309, -1, -1, 312, -1, -1, 2849, 2850, -1, + -1, 2853, -1, -1, -1, -1, -1, 325, -1, -1, + 328, -1, -1, -1, 2866, -1, 2868, -1, 2870, -1, + 2872, -1, -1, 205, 4556, 490, 491, 492, -1, 494, + 495, 496, 497, 498, 499, -1, 2888, -1, 190, 504, + 2892, -1, 243, -1, -1, 197, 247, 2899, 200, 2901, + 2902, 2903, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 243, -1, -1, -1, 247, -1, 268, 269, 2921, + -1, -1, -1, 2925, -1, -1, -1, -1, -1, -1, + 4612, 4071, 400, 284, -1, 2937, 268, 269, -1, 2716, + 2942, -1, -1, -1, 2946, -1, -1, 2949, -1, -1, + 252, -1, 284, 2955, -1, -1, 2958, -1, 309, -1, + 2962, 312, -1, 4645, -1, 117, -1, -1, -1, -1, + -1, -1, -1, -1, 325, -1, -1, 328, -1, -1, + 312, -1, -1, 4123, -1, -1, -1, -1, -1, -1, + -1, -1, 2994, 325, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 307, -1, 309, -1, -1, + 162, -1, -1, 3015, -1, 3017, -1, 319, -1, -1, + 3022, -1, 490, 491, 492, 327, 494, 495, 496, 497, + 498, 499, -1, 3035, 336, -1, 504, -1, -1, -1, + -1, 3043, -1, 3045, 3046, -1, -1, -1, -1, 400, + -1, -1, -1, -1, -1, -1, 208, -1, -1, -1, + -1, -1, -1, -1, 216, 367, 218, -1, 400, 371, + -1, -1, -1, -1, -1, -1, -1, -1, 230, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 4229, + -1, -1, -1, -1, 396, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 3129, -1, -1, + -1, -1, -1, -1, 3136, -1, -1, -1, -1, 490, + 491, 492, -1, 494, 495, 496, 497, 498, 499, -1, + -1, -1, 454, 504, -1, -1, -1, -1, -1, -1, + -1, -1, 494, 495, 496, 497, 498, 499, -1, -1, + -1, -1, -1, -1, -1, -1, 95, -1, -1, -1, + -1, -1, 101, -1, -1, -1, 4868, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 3206, -1, -1, 126, -1, -1, + -1, -1, -1, -1, 3216, 3217, -1, -1, -1, -1, + -1, -1, 141, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 3009, 3010, -1, 3012, -1, -1, -1, -1, + -1, -1, -1, 3245, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 172, -1, -1, -1, -1, -1, 1256, + -1, -1, -1, 3265, -1, 3267, 1256, -1, -1, 3271, + -1, 190, -1, -1, -1, -1, -1, -1, 197, -1, + -1, 200, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 3295, 3296, -1, -1, -1, -1, -1, + -1, -1, 3304, -1, -1, -1, 3308, -1, 4448, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 3322, -1, -1, -1, -1, -1, 3328, -1, -1, -1, + 249, -1, -1, 252, -1, 3337, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 3352, -1, -1, 3355, -1, -1, 3358, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 3145, -1, + 3372, -1, -1, 3375, -1, -1, 295, -1, 297, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 307, 3391, + 309, 3393, -1, -1, -1, -1, -1, 3399, -1, -1, + 319, -1, -1, -1, -1, 3407, -1, -1, 327, -1, + -1, -1, -1, -1, -1, 3417, 335, 336, 1415, -1, + -1, 3423, -1, 3425, -1, 1415, -1, -1, -1, 3431, + -1, -1, 3434, 3435, 3436, 3437, 3438, 3439, 3440, 3441, + 3442, 3443, -1, -1, -1, 3447, 3448, -1, 367, -1, + -1, -1, 371, 372, -1, -1, -1, -1, 3460, -1, + -1, -1, 3464, -1, -1, -1, 3468, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3478, 396, -1, 3481, + -1, 3483, -1, -1, -1, -1, -1, -1, 407, -1, + 3492, 3493, 3494, -1, -1, -1, 3498, -1, -1, 3501, + 3277, -1, 3279, -1, -1, -1, 3508, 3509, 3510, 3511, + 3512, -1, -1, -1, 3516, 3517, -1, -1, -1, 3521, + 85, -1, -1, 88, -1, 3527, -1, 3529, -1, 3531, + -1, -1, -1, -1, -1, 454, -1, -1, -1, -1, + 105, -1, -1, 85, -1, -1, 88, -1, 113, -1, + -1, -1, -1, -1, 119, -1, -1, -1, -1, -1, + 1557, -1, -1, 105, -1, 4705, -1, -1, -1, -1, + -1, 113, -1, 3575, -1, -1, -1, 119, 143, 3581, + -1, -1, -1, 3585, -1, 3587, -1, -1, -1, -1, + -1, -1, -1, 3370, -1, -1, -1, -1, -1, -1, + -1, 143, -1, -1, -1, -1, -1, -1, -1, -1, + 3612, 3613, 3614, 3390, 3616, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 3630, 3631, + 3632, 3633, -1, -1, -1, -1, -1, 3639, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 816, -1, 3668, -1, -1, -1, + -1, -1, 824, -1, -1, -1, -1, -1, 243, -1, + 832, -1, 247, -1, -1, -1, 1683, -1, -1, -1, + -1, -1, -1, 1683, -1, -1, -1, -1, -1, -1, + -1, 243, -1, 268, 269, 247, -1, -1, -1, -1, + -1, 863, -1, -1, 3716, -1, -1, 3719, -1, 284, + -1, -1, -1, -1, -1, -1, 268, 269, -1, -1, + -1, 3733, -1, -1, -1, -1, -1, -1, -1, 1736, + -1, -1, 284, -1, 309, -1, 1736, 312, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 3759, -1, -1, + 325, -1, -1, 328, -1, 917, 1763, 309, -1, -1, + 312, -1, -1, 1763, 926, -1, -1, -1, -1, -1, + -1, -1, -1, 325, -1, 3787, 328, -1, -1, -1, + -1, -1, -1, 3795, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 3806, -1, 3808, -1, -1, -1, + -1, -1, 3814, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 3826, -1, -1, 85, -1, -1, + 88, -1, -1, -1, 3836, 400, -1, 1834, -1, -1, + -1, -1, -1, 3845, 1834, -1, -1, 105, 3850, -1, + -1, -1, 3854, -1, -1, 113, 1853, -1, 400, -1, + -1, 119, -1, 1853, 3866, 3867, -1, -1, -1, -1, + -1, -1, -1, -1, 1871, -1, -1, -1, -1, -1, + -1, 1871, -1, -1, 1036, 143, -1, -1, -1, 3891, + 1042, 3893, -1, -1, 1046, -1, -1, -1, -1, -1, + -1, -1, 1899, -1, -1, -1, -1, -1, 3910, 1899, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 1071, + -1, -1, -1, -1, 3926, 490, 491, 492, -1, 494, + 495, 496, 497, 498, 499, -1, -1, -1, -1, 504, + -1, -1, -1, -1, -1, -1, -1, -1, 490, 491, + 492, -1, 494, 495, 496, 497, 498, 499, -1, -1, + 1957, 3963, 504, -1, -1, -1, -1, 1957, -1, -1, + -1, 3973, 3974, -1, -1, -1, -1, -1, -1, 3981, + 3982, -1, -1, -1, 3986, 243, -1, -1, -1, 247, + 3992, 3993, -1, -1, 3996, -1, 3998, 3999, 4000, 4001, + -1, -1, -1, 4005, -1, -1, 4008, -1, -1, 4011, + 268, 269, -1, 4015, -1, -1, -1, -1, -1, 4021, + -1, -1, 4024, -1, -1, -1, 284, 4029, -1, -1, + -1, -1, -1, 4035, -1, -1, -1, -1, -1, 4041, + -1, -1, -1, -1, -1, -1, -1, -1, 4050, -1, + -1, 309, 3829, 3830, 312, -1, 4058, -1, -1, -1, + 4062, -1, -1, -1, -1, -1, 85, 325, -1, 88, + 328, -1, 1224, -1, -1, 4077, -1, -1, 4080, -1, + -1, -1, 1234, -1, -1, -1, 105, -1, -1, -1, + -1, -1, -1, -1, 113, -1, -1, -1, 4100, 4101, + 119, -1, -1, -1, 1256, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 4124, -1, 143, 3902, 3903, 3904, -1, -1, + -1, 4133, -1, -1, -1, -1, -1, 1289, -1, -1, + -1, -1, 400, 4145, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 2151, -1, -1, -1, -1, -1, + -1, 2151, 4164, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 4178, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 2186, -1, -1, -1, + -1, -1, 4204, -1, 1356, -1, -1, -1, -1, -1, + 4212, -1, -1, -1, -1, -1, -1, -1, -1, 4221, + 4222, 4223, 4224, 4225, 243, -1, -1, -1, 247, -1, + -1, -1, 490, 491, 492, -1, 494, 495, 496, 497, + 498, 499, -1, 4245, -1, -1, 504, -1, -1, 268, + 269, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 1415, -1, 284, -1, -1, -1, -1, + 4272, 4273, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 309, 1443, -1, 312, -1, -1, -1, -1, 4300, -1, + 4302, -1, -1, -1, -1, -1, 325, -1, -1, 328, + -1, -1, -1, -1, -1, -1, 4318, -1, -1, -1, + 1472, -1, -1, -1, -1, -1, -1, -1, 4330, -1, + -1, -1, -1, -1, -1, -1, -1, 4339, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 1500, 1501, + -1, 1503, -1, -1, 4356, 4357, -1, -1, 4360, -1, + -1, -1, -1, -1, -1, 4367, -1, -1, 1520, 4371, + -1, -1, -1, -1, 4376, -1, -1, 4379, 4380, -1, + 4382, 400, 4384, 4385, -1, 4162, 4163, -1, 4165, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 4411, + -1, 4413, -1, -1, -1, 4417, 4418, 4419, 4420, 4421, + 1572, 1573, -1, -1, 2421, -1, -1, -1, -1, 2426, + 2427, 2421, -1, -1, -1, 85, 2426, 2427, 88, -1, + -1, 2438, -1, -1, -1, -1, 160, -1, 2438, 1601, + 4452, 4453, -1, 1605, 1606, 105, -1, -1, -1, 109, + -1, -1, -1, 113, -1, -1, -1, -1, -1, 119, + -1, 490, 491, 492, -1, 494, 495, 496, 497, 498, + 499, 4483, -1, -1, -1, 504, -1, 4489, -1, -1, + -1, -1, 206, 143, -1, -1, 4498, -1, -1, -1, + -1, -1, -1, -1, 218, -1, -1, 4509, 222, 4511, + -1, -1, -1, 227, -1, -1, -1, -1, 232, -1, + -1, 235, 4524, 237, -1, -1, -1, 4529, -1, -1, + -1, 1683, -1, -1, -1, 4537, 4538, 1689, 188, -1, + -1, -1, -1, -1, 1696, -1, -1, -1, -1, -1, + 264, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 4562, -1, -1, 4565, -1, 4567, -1, -1, -1, -1, + -1, 285, 2569, -1, -1, -1, 1728, -1, -1, 2569, + -1, -1, 4584, -1, 1736, -1, 4588, -1, -1, 4591, + -1, -1, -1, 243, -1, 4597, -1, 247, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 321, -1, -1, + -1, 1763, -1, -1, -1, 329, -1, 4619, 268, 269, + -1, 4623, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 284, -1, -1, -1, 4640, 4641, + 4642, 4643, 2639, -1, -1, -1, -1, -1, 4650, 2639, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 309, + 374, -1, 312, 1815, -1, -1, -1, -1, 4670, -1, + -1, -1, -1, -1, -1, 325, -1, -1, 328, -1, + -1, 3, 1834, -1, -1, -1, -1, 9, -1, -1, + -1, 13, -1, 15, -1, 17, 18, -1, -1, -1, + -1, 1853, -1, -1, -1, 419, 28, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 1871, + -1, -1, -1, 45, 46, -1, 4728, -1, -1, 443, + -1, -1, 4734, -1, 4736, -1, -1, -1, -1, -1, + -1, 2738, 1894, 4745, -1, -1, -1, 1899, 2738, -1, + 400, -1, 466, -1, 468, 469, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 91, + -1, -1, -1, -1, 4776, -1, -1, -1, 4780, 101, + -1, 103, 104, -1, -1, -1, -1, 501, 4790, -1, + 504, 505, -1, 507, -1, -1, 118, 4799, -1, 1951, + -1, 451, -1, -1, 4581, 1957, 4808, -1, 1960, 4811, + 4812, -1, 4814, -1, 4591, -1, 138, -1, 140, 141, + -1, -1, 4824, -1, 146, -1, 148, -1, -1, -1, + 4832, -1, -1, -1, -1, -1, 158, -1, 160, -1, + 490, 491, 492, -1, 494, 495, 496, 497, 498, 499, + -1, -1, 174, -1, 176, -1, -1, 179, 4860, -1, + -1, -1, -1, -1, -1, -1, -1, 4644, 4870, 191, + -1, 193, -1, 4875, -1, 197, -1, -1, -1, -1, + -1, 203, -1, -1, -1, -1, -1, -1, 210, -1, + 212, -1, -1, -1, -1, 2047, 218, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 232, 2901, 2902, 2903, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 4928, -1, -1, -1, + -1, -1, 2084, 2085, -1, 4937, -1, -1, -1, -1, + 2092, -1, 4719, 2095, -1, -1, -1, 2099, -1, -1, + -1, -1, -1, -1, -1, 2107, 2108, -1, -1, -1, + -1, -1, -1, 2115, 286, 287, 2118, 2119, 2120, 2121, + 292, -1, -1, -1, -1, -1, 2128, 2129, 300, 2131, + -1, 2133, 2134, -1, -1, 2137, -1, -1, -1, 311, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 2151, + 2152, 2153, -1, -1, -1, 2157, -1, -1, -1, 2161, + -1, -1, -1, 2165, -1, 2167, 2168, 2169, 2170, 2171, + 2172, 2173, 2174, 2175, -1, 2177, 348, -1, -1, -1, + -1, 2183, -1, -1, 2186, -1, -1, 359, -1, -1, + -1, 3038, 364, -1, 366, -1, -1, -1, 3038, 371, + -1, -1, -1, -1, 376, -1, -1, 379, -1, -1, + -1, 383, -1, -1, -1, -1, 388, 389, -1, -1, + -1, -1, -1, -1, 396, -1, -1, 399, -1, -1, + -1, 3078, 3079, -1, 3081, 407, -1, -1, 3078, 3079, + -1, 3081, -1, -1, -1, -1, 2248, 419, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 436, -1, 438, -1, -1, -1, + -1, -1, -1, -1, 446, -1, -1, -1, -1, -1, + 452, -1, -1, -1, -1, 457, 3133, -1, 3135, -1, + -1, -1, -1, 3133, -1, 3135, -1, 469, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 503, -1, -1, -1, 507, -1, -1, -1, -1, + -1, 3188, 2344, -1, -1, -1, -1, -1, 3188, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 3212, -1, -1, -1, -1, + -1, 2373, 3212, -1, -1, -1, -1, 2379, -1, -1, + -1, -1, -1, 2385, -1, -1, -1, -1, -1, -1, + -1, -1, 3239, -1, -1, -1, -1, -1, -1, 3239, + -1, -1, -1, -1, -1, 3252, -1, -1, -1, -1, + -1, -1, 3252, 2415, -1, -1, -1, -1, -1, 2421, + -1, -1, -1, -1, 2426, 2427, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 2438, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 2454, -1, -1, 2457, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 5, 3315, -1, + -1, -1, -1, -1, -1, 3315, -1, -1, -1, -1, + -1, -1, 3329, -1, -1, -1, -1, 25, -1, 3329, + -1, -1, -1, -1, -1, 3342, -1, 35, 36, -1, + -1, -1, 3342, 41, -1, 43, 44, -1, -1, 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, -1, 73, -1, 75, 76, 77, + 78, 79, 80, 81, 82, -1, -1, -1, 86, -1, + -1, -1, -1, -1, -1, -1, 208, -1, -1, -1, + -1, -1, -1, 3410, 216, 2567, 218, 2569, -1, 85, + 3410, 160, 88, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 3430, -1, -1, -1, -1, -1, 105, + 3430, -1, -1, -1, -1, -1, 134, 113, -1, -1, + -1, -1, -1, 119, -1, -1, -1, -1, 3455, -1, + -1, -1, -1, -1, -1, 3455, -1, 206, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 143, -1, 218, + -1, -1, -1, 222, -1, -1, -1, 2639, 227, -1, + -1, -1, -1, 232, 3491, -1, 235, -1, 237, -1, + -1, 3491, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 204, -1, -1, -1, + -1, -1, -1, -1, -1, 264, -1, -1, -1, -1, + -1, -1, 220, -1, 85, 2687, -1, 88, -1, -1, + -1, 3531, -1, -1, -1, -1, 285, -1, -1, -1, + -1, -1, 240, -1, 105, -1, -1, -1, -1, -1, + -1, 85, 113, -1, 88, -1, -1, -1, 119, -1, + -1, -1, -1, -1, 262, -1, -1, 243, -1, -1, + -1, 247, 321, -1, -1, -1, 2738, -1, -1, 113, + 329, -1, 143, -1, -1, 119, -1, -1, -1, -1, + 2752, -1, 268, 269, -1, 2757, -1, -1, 296, -1, + -1, 299, -1, -1, -1, -1, -1, -1, 284, 143, + -1, 2773, 2774, -1, -1, -1, 314, 2779, -1, -1, + -1, -1, -1, -1, -1, 374, -1, -1, -1, -1, + -1, -1, -1, 309, -1, -1, 312, -1, -1, -1, + -1, -1, 2804, 2805, -1, -1, -1, 2809, -1, 325, + -1, -1, 328, -1, -1, -1, -1, -1, -1, 2821, + 2822, 2823, 2824, -1, -1, -1, -1, 2829, -1, -1, + 419, 205, 2834, 2835, -1, 2837, 3683, 2839, -1, -1, + -1, -1, 243, 3683, -1, -1, 247, 2849, 2850, 387, + -1, 2853, -1, -1, 443, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 2866, -1, 2868, 268, 269, 243, + 2872, -1, -1, 247, -1, -1, -1, 466, -1, 468, + 469, -1, -1, 284, 400, -1, 2888, -1, -1, -1, + -1, 429, -1, -1, 268, 269, -1, 2899, -1, 2901, + 2902, 2903, -1, -1, -1, 443, -1, -1, 309, -1, + 284, 312, 501, -1, -1, 504, 505, -1, 507, -1, + 458, -1, -1, 2925, 325, -1, -1, 328, -1, -1, + -1, -1, -1, -1, -1, 2937, -1, -1, 312, -1, + 2942, -1, -1, -1, -1, -1, 484, 2949, -1, -1, + -1, 325, 490, 2955, -1, -1, 494, 495, 496, 497, + 498, -1, -1, 501, 502, 503, 504, -1, 506, 507, + 508, 509, 510, -1, 490, 491, 492, -1, 494, 495, + 496, 497, 498, 499, -1, -1, 3833, -1, 504, -1, + -1, -1, -1, 3833, -1, -1, -1, -1, -1, 400, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 3015, -1, -1, -1, -1, 3865, -1, + -1, -1, -1, -1, -1, 3865, 400, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3038, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3078, 3079, -1, 3081, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 490, + 491, 492, -1, 494, 495, 496, 497, 498, 499, -1, + -1, -1, -1, 504, -1, -1, -1, -1, 3110, 3111, + 3112, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 494, 495, 496, 497, 498, 499, -1, -1, -1, 3976, + -1, 3133, 85, 3135, -1, 88, 3976, -1, -1, -1, + 3987, -1, -1, -1, -1, -1, -1, 3987, -1, -1, + -1, -1, 105, -1, -1, -1, -1, -1, -1, -1, + 113, -1, -1, -1, -1, -1, 119, -1, -1, -1, + -1, -1, 824, -1, -1, -1, -1, -1, -1, -1, + 832, -1, -1, -1, 4024, -1, 3188, -1, -1, 4029, + 143, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 4041, -1, -1, -1, -1, -1, -1, -1, -1, + 3212, 863, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 3234, -1, -1, -1, -1, 3239, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 3251, + 3252, 4098, -1, -1, -1, -1, -1, -1, 4098, -1, + -1, -1, -1, -1, -1, 917, -1, -1, -1, -1, + -1, -1, -1, -1, 926, -1, -1, -1, -1, 4126, + -1, -1, -1, -1, -1, -1, 4126, -1, -1, -1, + 243, 4138, -1, -1, 247, -1, -1, -1, 4138, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 3315, -1, 268, 269, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 3329, -1, -1, + -1, 284, -1, -1, -1, 4182, -1, -1, -1, -1, + 3342, -1, 4182, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 95, -1, 309, -1, -1, 312, + 101, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 3372, -1, 325, -1, -1, 328, -1, -1, -1, -1, + -1, -1, -1, -1, 1036, 126, -1, -1, -1, -1, + 1042, -1, -1, -1, 1046, -1, -1, -1, -1, -1, + 141, -1, -1, -1, -1, 3407, -1, -1, 3410, -1, + -1, -1, -1, -1, -1, 3417, -1, -1, -1, 1071, + -1, 3423, -1, 3425, -1, -1, -1, -1, 3430, 3431, + -1, 172, 3434, 3435, 3436, 3437, 3438, 3439, 3440, 3441, + 3442, 3443, -1, -1, -1, 3447, 3448, 400, -1, 190, + -1, -1, -1, 3455, -1, -1, 197, 4297, 3460, 200, + -1, -1, 3464, -1, 3466, -1, 3468, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3478, -1, -1, 3481, + -1, 3483, -1, -1, -1, -1, -1, 4334, -1, 3491, + 3492, 3493, 3494, -1, 4334, -1, 3498, -1, -1, 3501, + 85, -1, -1, 88, -1, -1, -1, -1, 249, 3511, + -1, 252, -1, -1, -1, -1, -1, -1, -1, 3521, + 105, -1, -1, -1, -1, -1, -1, 3529, 113, 3531, + -1, -1, -1, -1, 119, -1, -1, 490, 491, 492, + -1, 494, 495, 496, 497, 498, 499, -1, -1, -1, + -1, 504, -1, -1, 295, -1, 297, -1, 143, -1, + -1, -1, -1, -1, -1, -1, 307, -1, 309, -1, + -1, -1, 1224, 3575, -1, -1, -1, -1, 319, 3581, + -1, -1, 1234, -1, -1, 3587, 327, -1, -1, -1, + -1, -1, -1, -1, 335, 336, -1, -1, -1, -1, + -1, 4448, -1, -1, 1256, -1, -1, -1, 4448, -1, + 3612, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 367, -1, -1, -1, + 371, 372, -1, -1, -1, -1, -1, 1289, -1, -1, + -1, -1, -1, 85, -1, -1, 88, -1, -1, -1, + -1, -1, -1, -1, -1, 396, -1, -1, 243, -1, + -1, -1, 247, 105, -1, -1, 407, -1, -1, -1, + -1, 113, -1, -1, -1, -1, 3678, 119, -1, -1, + 3682, 3683, 3684, 268, 269, -1, -1, -1, -1, -1, + -1, -1, -1, 4540, -1, -1, -1, -1, -1, 284, + 4540, 143, -1, -1, 1356, -1, -1, -1, -1, -1, + -1, -1, -1, 454, -1, -1, 4563, -1, -1, -1, + -1, -1, -1, 4563, 309, -1, -1, 312, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 325, -1, -1, 328, -1, -1, 4593, -1, -1, -1, + -1, -1, -1, 4593, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 1415, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 85, -1, 4632, 88, -1, -1, 4636, + 4637, 1443, 4632, -1, -1, -1, 4636, 4637, -1, -1, + -1, 243, -1, 105, -1, 247, 3808, -1, -1, -1, + -1, 113, -1, -1, -1, 400, -1, 119, -1, -1, + 1472, -1, -1, -1, -1, -1, 268, 269, -1, -1, + -1, 3833, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 143, 284, -1, -1, -1, -1, -1, 1500, 1501, + -1, 1503, -1, -1, -1, -1, -1, -1, 4698, 85, + -1, -1, 88, 3865, 3866, 3867, -1, 309, 1520, -1, + 312, -1, -1, -1, -1, -1, -1, -1, -1, 105, + -1, -1, -1, 325, -1, -1, 328, 113, -1, -1, + -1, -1, -1, 119, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 490, 491, 492, -1, 494, + 495, 496, 497, 498, 499, -1, -1, 143, -1, 504, + 1572, -1, -1, -1, 3926, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 85, -1, -1, 88, -1, + -1, 243, -1, -1, -1, 247, -1, -1, -1, 1601, + -1, -1, -1, 1605, 1606, 105, -1, -1, 400, -1, + -1, 3963, -1, 113, -1, -1, 268, 269, -1, 119, + -1, 3973, 3974, -1, 3976, -1, -1, -1, -1, 3981, + 3982, -1, 284, -1, 3986, 3987, -1, -1, -1, -1, + 3992, 3993, -1, 143, 3996, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 309, -1, 4011, + 312, -1, -1, 4015, -1, -1, -1, 243, -1, -1, + -1, 247, 4024, 325, -1, -1, 328, 4029, -1, -1, + -1, 1683, -1, -1, -1, -1, -1, -1, -1, 4041, + -1, -1, 268, 269, 1696, 347, -1, -1, 490, 491, + 492, -1, 494, 495, 496, 497, 498, 499, 284, -1, + -1, -1, 504, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 222, -1, -1, -1, 1728, 227, 4080, -1, + -1, -1, -1, 309, 1736, -1, 312, -1, -1, -1, + -1, -1, -1, 243, -1, -1, 4098, 247, 400, 325, + -1, -1, 328, -1, -1, -1, -1, -1, -1, -1, + -1, 1763, 414, -1, -1, 4117, -1, -1, 268, 269, + -1, -1, -1, -1, 4126, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 284, -1, 4138, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 309, + -1, -1, 312, 1815, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 400, 325, -1, -1, 328, -1, + 4182, -1, 1834, -1, -1, -1, -1, -1, 490, 491, + 492, -1, 494, 495, 496, 497, 498, 499, -1, -1, + 4202, 1853, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 1871, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 4245, -1, -1, -1, 1899, -1, -1, + 400, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 490, 491, 492, -1, 494, 495, + 496, 497, 498, 499, -1, -1, 502, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 4297, -1, -1, -1, 1951, + -1, -1, -1, -1, -1, 1957, -1, -1, 1960, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 4330, -1, + -1, -1, 4334, -1, -1, -1, -1, 4339, -1, -1, + 490, 491, 492, -1, 494, 495, 496, 497, 498, 499, + -1, -1, -1, -1, 4356, 4357, -1, -1, 4360, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 4371, + -1, -1, -1, -1, 4376, -1, -1, 4379, -1, -1, + -1, -1, 4384, 4385, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 85, -1, 2047, 88, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 105, -1, 4417, -1, -1, -1, -1, + -1, 113, -1, -1, -1, -1, -1, 119, -1, -1, + -1, -1, 2084, 2085, -1, -1, -1, -1, -1, -1, + 2092, -1, -1, 2095, -1, -1, 4448, 2099, -1, -1, + 4452, 143, -1, -1, -1, 2107, 2108, -1, -1, -1, + -1, -1, -1, 2115, -1, -1, 2118, 2119, 2120, 2121, + -1, -1, -1, -1, -1, -1, 2128, 2129, -1, 2131, + -1, 2133, 2134, -1, -1, 2137, -1, 4489, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 2151, + 2152, -1, -1, -1, -1, 2157, -1, -1, -1, 2161, + -1, -1, -1, 2165, -1, 2167, 2168, 2169, 2170, 2171, + 2172, 2173, 2174, 2175, -1, 2177, -1, -1, -1, 221, + -1, 2183, -1, -1, 2186, -1, 4538, -1, 4540, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 243, -1, -1, -1, 247, -1, -1, -1, -1, + 4562, 4563, -1, 4565, -1, 4567, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 268, 269, -1, -1, + -1, -1, 4584, -1, 85, -1, 4588, 88, -1, -1, + -1, 4593, 284, -1, -1, -1, 2248, -1, -1, -1, + -1, -1, -1, -1, 105, -1, -1, 108, -1, -1, + -1, -1, 113, -1, -1, -1, -1, 309, 119, -1, + 312, -1, -1, -1, -1, -1, -1, 4629, -1, -1, + 4632, -1, -1, 325, 4636, 4637, 328, -1, -1, -1, + -1, -1, 143, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 345, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 4670, -1, + 85, -1, -1, 88, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 105, -1, -1, -1, -1, -1, 4698, -1, 113, -1, + -1, -1, -1, -1, 119, -1, -1, -1, 400, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 2373, -1, -1, 1256, -1, 4728, 2379, 143, -1, + -1, -1, -1, 2385, -1, -1, -1, -1, -1, -1, + -1, -1, 243, 4745, -1, -1, 247, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 2415, -1, -1, -1, 268, 269, 2421, + -1, -1, -1, -1, 2426, 2427, -1, -1, 4780, -1, + -1, -1, -1, 284, -1, -1, 2438, -1, 4790, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 490, 491, + 492, -1, 494, 495, 496, 497, 498, 499, 309, 4811, + 4812, 312, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 4824, -1, 325, -1, -1, 328, 243, -1, + -1, -1, 247, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 85, -1, -1, + 88, -1, -1, 268, 269, -1, -1, -1, 4860, -1, + -1, -1, -1, -1, -1, -1, -1, 105, 4870, 284, + 108, -1, -1, -1, -1, 113, -1, -1, -1, -1, + -1, 119, -1, 1415, 4886, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 309, -1, -1, 312, -1, 400, + -1, -1, -1, -1, -1, 143, -1, -1, -1, -1, + 325, -1, -1, 328, -1, 2567, -1, 2569, -1, -1, + -1, -1, -1, -1, -1, -1, 4928, 342, -1, -1, + -1, 4933, -1, -1, -1, 4937, -1, -1, -1, 4941, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 400, -1, 2639, -1, 490, + 491, 492, -1, 494, 495, 496, 497, 498, 499, -1, + -1, -1, -1, -1, -1, 243, -1, -1, -1, 247, + -1, 825, 826, -1, -1, 829, 830, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 268, 269, 846, -1, -1, 2687, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 284, -1, -1, -1, + -1, -1, 866, -1, -1, -1, 870, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 96, -1, + -1, 309, 886, -1, 312, 490, 491, 492, 106, 494, + 495, 496, 497, 498, 499, -1, 2738, 325, -1, -1, + 328, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 2752, -1, -1, -1, -1, 2757, -1, -1, 85, -1, + -1, 88, -1, -1, 142, -1, -1, -1, -1, -1, + -1, 2773, 2774, -1, -1, -1, 154, 2779, 105, 157, + -1, 108, -1, -1, -1, 163, 113, -1, -1, 167, + -1, -1, 119, -1, -1, -1, -1, -1, -1, -1, + -1, 1683, 2804, 2805, -1, -1, -1, 2809, -1, 187, + -1, 85, 400, -1, 88, -1, 143, -1, -1, 2821, + 2822, 2823, 2824, -1, -1, 203, -1, -1, -1, -1, + -1, 105, 2834, -1, -1, 2837, -1, 2839, -1, 113, + -1, -1, -1, -1, -1, 119, -1, 2849, 2850, -1, + -1, 2853, -1, -1, 1736, -1, -1, -1, 236, -1, + -1, -1, -1, -1, 2866, -1, 2868, -1, -1, 143, + 2872, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 1763, -1, -1, -1, 85, 2888, -1, 88, -1, + -1, -1, -1, -1, -1, -1, -1, 2899, -1, 2901, + 2902, 2903, 490, 491, 492, 105, 494, 495, 496, 497, + 498, 499, -1, 113, -1, -1, 243, -1, -1, 119, + 247, -1, -1, 2925, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 2937, -1, -1, -1, -1, + 2942, 268, 269, 143, -1, -1, -1, 2949, -1, -1, + -1, -1, 1834, 2955, -1, -1, -1, 284, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 243, + -1, 1853, -1, 247, -1, -1, -1, -1, -1, -1, + -1, -1, 309, -1, -1, 312, -1, -1, -1, 1871, + -1, -1, -1, -1, 268, 269, -1, -1, 325, -1, + -1, 328, -1, -1, -1, -1, -1, -1, -1, -1, + 284, -1, -1, 3015, -1, -1, -1, 1899, 1182, 1183, + -1, -1, -1, -1, -1, -1, -1, 227, -1, -1, + -1, -1, -1, 411, -1, 309, 3038, -1, 312, -1, + -1, -1, -1, 243, -1, -1, -1, 247, -1, -1, + -1, 325, -1, -1, 328, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 268, 269, + -1, -1, -1, 400, -1, 1957, 3078, 3079, -1, 3081, + -1, -1, -1, -1, 284, -1, 1250, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 1270, 1271, -1, 309, + -1, -1, 312, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 1287, -1, 325, 400, -1, 328, -1, + -1, 3133, -1, 3135, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 426, -1, -1, -1, -1, -1, 1322, 1323, + -1, -1, -1, 490, 491, 492, -1, 494, 495, 496, + 497, 498, 499, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3188, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 400, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 3212, -1, -1, -1, -1, -1, 490, 491, 492, -1, + 494, 495, 496, 497, 498, 499, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 3239, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 3252, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 2151, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 490, 491, 492, -1, 494, 495, 496, 497, 498, 499, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 3315, -1, -1, 694, 695, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 3329, -1, -1, + -1, -1, -1, 711, -1, -1, -1, -1, -1, -1, + 3342, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 85, -1, + 3372, 88, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 105, -1, + -1, 108, -1, -1, -1, -1, 113, -1, -1, -1, + -1, -1, 119, -1, -1, 3407, -1, -1, 3410, -1, + -1, -1, -1, -1, -1, 3417, -1, -1, -1, -1, + -1, 3423, -1, 3425, -1, -1, 143, -1, 3430, 3431, + -1, -1, 3434, 3435, 3436, 3437, 3438, 3439, 3440, 3441, + 3442, 3443, -1, -1, -1, 3447, 3448, -1, -1, -1, + -1, -1, 830, 3455, -1, -1, -1, -1, 3460, -1, + -1, 839, 3464, 841, -1, 843, 3468, 845, -1, -1, + -1, -1, -1, -1, -1, -1, 3478, -1, -1, 3481, + -1, 3483, -1, -1, -1, -1, 864, -1, -1, 3491, + 3492, 3493, 3494, 871, -1, -1, 3498, -1, -1, 3501, + -1, -1, 880, 881, -1, -1, -1, 885, 85, 3511, + -1, 88, -1, -1, -1, -1, -1, -1, -1, 3521, + -1, -1, -1, 901, -1, 903, 243, 3529, 105, 3531, + 247, -1, -1, -1, -1, -1, 113, -1, -1, 2421, + 918, -1, 119, -1, 2426, 2427, -1, -1, -1, -1, + -1, 268, 269, -1, 932, -1, 2438, 935, -1, 937, + -1, 939, -1, -1, -1, -1, 143, 284, -1, -1, + -1, -1, -1, 3575, 952, 953, -1, -1, -1, 3581, + -1, -1, -1, -1, -1, 3587, 1750, -1, -1, 967, + -1, 969, 309, -1, -1, 312, -1, -1, -1, -1, + -1, 979, -1, -1, -1, -1, -1, -1, 325, -1, + 3612, 328, -1, -1, -1, -1, -1, -1, -1, -1, + 998, 999, -1, -1, -1, -1, -1, 1005, -1, 1007, + -1, 85, -1, -1, 88, -1, 1800, 1801, 1802, 1803, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 105, -1, -1, -1, -1, -1, -1, -1, 113, + 1038, -1, -1, -1, -1, 119, 243, -1, -1, -1, + 247, -1, -1, -1, -1, -1, 1840, 1841, -1, -1, + -1, 3683, 1846, 400, -1, -1, -1, 2569, -1, 143, + -1, 268, 269, -1, -1, 1073, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 284, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 1893, + -1, -1, 309, -1, -1, 312, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 325, -1, + -1, 328, -1, 1917, 1918, 1919, 1920, 2639, -1, -1, + -1, -1, -1, -1, -1, -1, 1144, -1, 1146, -1, + -1, -1, 1150, 490, 491, 492, -1, 494, 495, 496, + 497, 498, 499, -1, -1, -1, -1, -1, -1, 243, + -1, -1, -1, 247, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3808, -1, -1, -1, + -1, 1975, -1, -1, 268, 269, -1, -1, -1, -1, + 1984, -1, -1, 400, -1, -1, -1, 1991, -1, -1, + 284, 3833, -1, -1, 1212, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 1228, -1, -1, -1, -1, 309, 2738, -1, 312, -1, + -1, 1239, -1, 3865, 3866, 3867, -1, -1, 1246, -1, + -1, 325, -1, -1, -1, -1, -1, -1, -1, -1, + 1258, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 1290, 490, 491, 492, -1, 494, 495, 496, + 497, 498, 499, -1, 3926, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 400, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 3963, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 3973, 3974, -1, 3976, -1, -1, -1, -1, 3981, + 3982, -1, -1, -1, 3986, 3987, -1, -1, -1, -1, + 3992, 3993, 2156, 1371, 3996, 1373, -1, -1, 1376, -1, + 1378, -1, -1, 1381, 1382, 1383, -1, -1, -1, 4011, + -1, -1, -1, 4015, -1, -1, 1394, -1, -1, -1, + -1, -1, 4024, -1, -1, -1, -1, 4029, -1, 1407, + -1, 1409, -1, -1, -1, -1, 490, 491, 492, 4041, + 494, 495, 496, 497, 498, 499, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 4080, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 4098, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 4126, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 4138, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3038, 98, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 110, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 4182, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 131, -1, -1, -1, -1, -1, 3078, 3079, -1, 3081, + -1, -1, -1, 144, -1, -1, -1, -1, -1, -1, + -1, -1, 153, 1591, -1, -1, 157, 2381, 2382, 2383, + -1, -1, -1, -1, 2388, -1, 2390, -1, 2392, 2393, + -1, -1, -1, 174, -1, -1, -1, -1, -1, 180, + -1, -1, -1, 4245, -1, -1, -1, -1, -1, -1, + -1, 3133, -1, 3135, 195, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 1648, -1, 213, 1651, -1, -1, -1, -1, -1, -1, + -1, 1659, -1, 224, -1, -1, -1, -1, -1, -1, + 231, -1, -1, -1, 235, 4297, -1, -1, -1, 1677, + -1, -1, -1, -1, -1, -1, 3188, -1, -1, 250, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 2488, -1, -1, -1, 4330, -1, + 3212, -1, 4334, -1, -1, -1, 1714, 4339, -1, -1, + -1, -1, -1, 89, -1, -1, -1, 288, 94, -1, + 96, -1, -1, -1, 4356, 4357, -1, 3239, 4360, -1, + 106, -1, -1, -1, -1, -1, -1, -1, -1, 4371, + 3252, -1, -1, -1, 4376, -1, -1, 4379, -1, -1, + 2544, -1, 4384, 4385, 325, -1, 132, 328, 2552, 2553, + 2554, 2555, 2556, 2557, -1, -1, 142, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 153, 154, -1, + -1, 157, -1, -1, -1, 4417, -1, 163, -1, -1, + -1, 167, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 3315, -1, -1, -1, 378, -1, -1, + -1, 187, -1, 384, -1, -1, 4448, 3329, -1, 390, + 4452, -1, 393, -1, -1, -1, -1, 203, -1, -1, + 3342, -1, -1, -1, -1, -1, -1, -1, 2632, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 419, -1, + 421, 422, -1, 424, 425, -1, -1, 4489, -1, -1, + -1, -1, 433, -1, -1, -1, -1, 438, 2662, -1, + 2664, -1, -1, 444, -1, -1, 447, -1, -1, 450, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 463, -1, 1902, -1, -1, -1, 3410, -1, + -1, -1, -1, -1, -1, -1, 4538, 1915, 4540, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 3430, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 4562, 4563, -1, 4565, -1, 4567, -1, -1, -1, -1, + -1, -1, -1, 3455, -1, -1, -1, -1, -1, -1, + -1, 1959, 4584, -1, -1, 1963, 4588, -1, -1, -1, + -1, 4593, -1, -1, -1, -1, 1974, -1, 1976, -1, + 1978, -1, -1, 2767, -1, 1983, -1, -1, -1, 3491, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 4632, -1, -1, -1, 4636, 4637, -1, -1, 2016, -1, + 2018, -1, -1, -1, 2022, -1, 2024, -1, -1, 2027, + -1, -1, -1, 2031, 2032, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 411, -1, -1, 4670, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 4698, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 4728, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 4745, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 4780, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 4790, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 3683, -1, -1, -1, -1, -1, -1, -1, 4811, + 4812, 2189, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 4824, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 5, 4860, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 4870, -1, + -1, -1, -1, -1, -1, -1, -1, 25, -1, 3043, + -1, 3045, 3046, -1, -1, -1, -1, 35, 36, -1, + -1, -1, -1, -1, -1, 43, 44, 643, -1, 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, -1, -1, 4928, 75, 76, 77, + 78, 79, 80, 81, 82, 4937, -1, -1, 86, -1, + -1, -1, -1, -1, -1, -1, 2324, -1, 694, 695, + -1, 3833, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 2341, 2342, 711, -1, -1, 2346, 2347, + -1, -1, 2350, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 2360, 3865, -1, -1, 134, -1, -1, 2367, + -1, -1, -1, 2371, 2372, -1, -1, 2375, 2376, 2377, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 2387, + -1, 2389, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 2405, -1, -1, + -1, -1, 2410, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 204, -1, -1, -1, + -1, -1, -1, 2441, 2442, 2443, 2444, -1, -1, -1, + 2448, 2449, 220, -1, -1, -1, -1, -1, 2456, -1, + -1, 2459, -1, -1, -1, 2463, -1, -1, -1, -1, + -1, -1, 240, -1, 3976, -1, -1, -1, -1, -1, + 2478, -1, -1, -1, -1, 3987, -1, -1, -1, -1, + -1, 2489, -1, 2491, 262, -1, -1, -1, 2496, -1, + -1, -1, -1, 2501, 2502, 2503, 2504, -1, 2506, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 2519, 2520, 2521, -1, -1, -1, -1, 296, -1, + -1, 299, 2530, 2531, 900, 901, -1, 903, -1, -1, + -1, -1, -1, -1, -1, -1, 314, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 3352, -1, + -1, 3355, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 949, -1, -1, 952, 953, 2586, -1, + -1, -1, -1, -1, -1, -1, 4098, -1, -1, 965, + -1, 967, -1, 969, -1, -1, -1, -1, -1, 975, + -1, -1, -1, 979, -1, 3399, -1, -1, -1, 387, + -1, -1, -1, -1, 4126, -1, -1, -1, -1, -1, + -1, -1, 998, 999, -1, -1, 4138, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 429, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 1038, -1, 1040, 443, -1, -1, -1, -1, + 4182, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 458, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 2703, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 484, -1, -1, -1, + -1, -1, 490, -1, -1, -1, 494, 495, 496, 497, + 498, -1, -1, 501, 502, 503, -1, 824, -1, -1, + 508, 509, -1, -1, -1, 832, 2744, -1, -1, -1, + -1, 1117, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 1131, 1132, -1, -1, 1135, + -1, -1, -1, -1, -1, -1, 863, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 1180, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 917, -1, 4334, -1, -1, -1, -1, -1, -1, 926, + -1, -1, -1, -1, -1, -1, 3630, 3631, 3632, 3633, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 4448, -1, -1, 1036, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 1071, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 2995, 2996, -1, + 1366, -1, -1, -1, -1, 1371, -1, 1373, -1, -1, + 1376, -1, 1378, -1, -1, 1381, 1382, 1383, -1, -1, + -1, 1387, 3806, -1, -1, -1, -1, -1, 1394, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 4540, -1, + -1, 1407, -1, 1409, -1, -1, -1, -1, 1414, -1, + -1, -1, -1, -1, -1, -1, -1, 3055, 3056, -1, + -1, 4563, 3060, -1, -1, -1, -1, 3065, 3066, 3067, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 4593, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 3101, 3102, 3103, 3104, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 1036, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 4632, -1, -1, -1, 4636, 4637, -1, 1224, -1, 3137, + -1, -1, -1, -1, -1, -1, -1, 1234, -1, -1, + -1, -1, -1, 1071, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 1531, -1, -1, -1, 1256, + -1, -1, -1, -1, 1540, 1541, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 1557, -1, -1, -1, -1, 1562, 1563, -1, -1, + -1, 3199, 1289, -1, -1, -1, -1, -1, -1, 3207, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 3266, 1356, + -1, -1, -1, -1, -1, -1, -1, 1643, 3276, 1645, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 1655, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 3303, -1, 3305, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 1415, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 3340, -1, -1, 3343, -1, -1, -1, -1, + -1, -1, 1718, -1, -1, -1, 1443, -1, -1, 3357, + 1726, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 4164, -1, -1, -1, -1, 1472, -1, -1, -1, -1, + -1, -1, -1, -1, 4178, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 1773, -1, -1, + 1776, 1777, -1, 1500, 1501, -1, 1503, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 1520, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 834, -1, -1, -1, -1, + -1, 840, -1, -1, -1, -1, -1, -1, -1, 848, + -1, -1, -1, 1839, -1, -1, -1, 856, -1, -1, + -1, -1, 861, -1, -1, 1572, -1, -1, 4272, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 1601, -1, -1, -1, 1605, 1606, + -1, -1, -1, -1, -1, 1443, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 1472, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 1500, 1501, -1, 1503, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 1683, -1, -1, -1, + -1, -1, 1520, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 3619, -1, 3621, -1, -1, -1, 3625, -1, -1, + 1009, -1, -1, -1, -1, 4419, 4420, 4421, -1, -1, + -1, -1, 3640, -1, -1, -1, -1, -1, -1, 1736, + 2016, -1, 2018, -1, 1572, -1, 2022, -1, 2024, 3657, + -1, 2027, 1041, -1, -1, 2031, -1, -1, 3666, -1, + 2036, -1, -1, -1, -1, -1, 1763, -1, -1, -1, + 1059, -1, -1, 1601, -1, -1, -1, 1605, 1606, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 1081, -1, -1, -1, -1, -1, 3706, 3707, + 3708, 3709, 3710, 3711, 3712, -1, -1, -1, -1, 3717, + 3718, -1, 3720, 3721, 3722, 3723, 3724, 3725, 3726, -1, + -1, -1, -1, -1, -1, -1, -1, 3735, -1, 3737, + 3738, -1, -1, -1, -1, -1, -1, 1834, -1, -1, + -1, -1, -1, 4537, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 1853, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 1871, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 3802, 3803, 3804, -1, -1, 3807, + -1, -1, 1899, -1, -1, -1, 2182, -1, -1, -1, + -1, -1, -1, 2189, -1, -1, -1, -1, -1, -1, + -1, -1, 2198, -1, -1, 4619, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 4641, -1, 4643, + -1, -1, -1, -1, 1951, -1, -1, -1, -1, -1, + 1957, -1, -1, 1960, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 3882, 1264, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 2261, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 1284, 1285, 1286, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 2309, -1, -1, -1, 2313, -1, -1, + 4734, -1, -1, 2319, -1, 2321, -1, -1, 2324, -1, + 2047, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 4776, -1, -1, -1, -1, 2084, 2085, -1, + -1, -1, -1, -1, -1, 2092, -1, -1, 2095, -1, + -1, -1, 2099, -1, -1, -1, -1, -1, -1, -1, + 2107, 2108, 1401, -1, -1, -1, -1, -1, 2115, -1, + -1, 2118, 2119, 2120, 2121, -1, -1, -1, -1, -1, + -1, 2128, 2129, -1, 2131, -1, 2133, 2134, 4832, 1428, + 2137, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 2151, 2152, -1, -1, -1, -1, + 2157, -1, -1, -1, 2161, -1, -1, -1, 2165, -1, + 2167, 2168, 2169, 2170, 2171, 2172, 2173, 2174, 2175, -1, + 2177, 4875, -1, -1, -1, -1, 2183, -1, -1, 2186, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 4109, 4110, 4111, 4112, -1, 2482, -1, -1, -1, + -1, -1, -1, -1, 2490, -1, 2492, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 4134, 4135, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 4146, 4147, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 2248, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 2092, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 1569, -1, -1, -1, -1, -1, -1, 2115, -1, -1, + 2118, -1, -1, 2121, -1, -1, -1, -1, -1, -1, + 2128, 2129, -1, -1, -1, -1, 2134, -1, -1, 2137, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 2152, -1, -1, 1616, -1, 2157, + -1, -1, -1, 2161, -1, -1, -1, 2165, -1, 2167, + 2168, 2169, 2170, 2171, 2172, 2173, 2174, 2175, -1, 2177, + -1, -1, -1, -1, -1, 2183, -1, 4265, 2186, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 2373, -1, -1, -1, + 4288, -1, 2379, -1, -1, -1, -1, -1, 2385, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 4310, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 2248, -1, -1, -1, 2421, -1, -1, 2703, 2704, 2426, + 2427, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 2438, -1, -1, 2720, -1, -1, -1, -1, -1, + -1, 1740, -1, -1, -1, -1, -1, -1, 1747, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 1772, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 4402, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 1804, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 1818, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 1832, -1, 2373, -1, -1, -1, -1, + -1, -1, -1, -1, 4462, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 2567, -1, 2569, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 4508, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 4546, -1, + 2916, -1, 2639, -1, -1, 2921, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 2687, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 2004, -1, -1, -1, 4627, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 2567, + -1, 2738, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 1256, -1, -1, -1, 2752, -1, -1, -1, -1, + 2757, -1, 2051, 2052, -1, -1, -1, -1, -1, -1, + -1, -1, 1256, -1, -1, -1, 2773, 2774, -1, -1, + -1, -1, 2779, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 4702, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 2804, 2805, -1, + -1, -1, 2809, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 2821, 2822, 2823, 2824, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 2834, -1, -1, + 2837, -1, 2839, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 2849, 2850, -1, -1, 2853, -1, -1, 2687, + -1, -1, -1, -1, -1, -1, 4774, -1, -1, 2866, + -1, 2868, -1, -1, -1, 2872, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 2888, -1, 2182, -1, -1, -1, -1, -1, -1, + -1, -1, 2899, -1, 2901, 2902, 2903, -1, -1, -1, + 1415, -1, -1, -1, -1, -1, -1, -1, 2207, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 2925, -1, + -1, 1415, -1, -1, -1, -1, -1, -1, -1, -1, + 2937, -1, -1, -1, -1, 2942, 2774, -1, -1, -1, + -1, 2779, 2949, -1, -1, 2244, -1, 2246, 2955, -1, + -1, -1, -1, 3239, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3252, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 2821, -1, 2823, 2824, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 2834, -1, -1, 2837, + -1, 2839, -1, -1, -1, -1, -1, -1, 3015, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 2866, -1, + 2868, 3038, -1, -1, 2872, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 3340, -1, -1, -1, -1, -1, + -1, -1, -1, 2901, 2902, 2903, -1, -1, -1, -1, + -1, 3078, 3079, -1, 3081, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 2925, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 2937, + -1, -1, -1, -1, 2942, -1, -1, -1, -1, -1, + -1, 2949, 3398, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3133, -1, 3135, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 1516, -1, -1, -1, -1, -1, -1, + -1, -1, 2451, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 1683, -1, + -1, -1, -1, -1, -1, -1, -1, 3015, -1, -1, + -1, 3188, -1, -1, -1, -1, -1, -1, -1, 1683, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 3212, -1, -1, -1, -1, + -1, -1, -1, -1, 1587, -1, -1, -1, -1, -1, + -1, 1736, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 3239, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 1736, -1, -1, 3252, -1, -1, 1763, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 1763, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 2595, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3592, -1, 3315, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 1834, + -1, -1, 3329, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 3342, -1, -1, 1853, -1, + 1834, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 1871, -1, -1, 1853, + -1, -1, -1, -1, -1, 3372, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 1871, -1, -1, + -1, -1, -1, -1, 1899, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 3683, -1, -1, + 3407, -1, -1, 3410, -1, 1899, -1, -1, -1, -1, + 3417, -1, -1, 3699, -1, -1, 3423, -1, 3425, -1, + -1, -1, -1, 3430, 3431, -1, -1, 3434, 3435, 3436, + 3437, 3438, 3439, 3440, 3441, 3442, 3443, -1, -1, -1, + 3447, 3448, 1957, -1, -1, -1, -1, -1, 3455, -1, + -1, -1, -1, 3460, -1, -1, -1, 3464, -1, -1, + -1, 3468, -1, 1957, -1, -1, -1, -1, -1, -1, + -1, 3478, -1, 3759, 3481, -1, 3483, -1, -1, -1, + -1, -1, -1, -1, 3491, 3492, 3493, 3494, -1, -1, + -1, 3498, -1, -1, 3501, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 3511, -1, -1, 1256, -1, -1, + -1, -1, -1, -1, 3521, -1, -1, -1, -1, -1, + -1, -1, 3529, -1, 3531, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 3575, 3407, + -1, -1, -1, -1, 3581, -1, -1, -1, -1, 3417, + 3587, -1, -1, -1, -1, 3423, -1, 3425, -1, -1, + -1, -1, -1, 2892, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 3612, -1, -1, -1, 3447, + 3448, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 3907, -1, -1, -1, -1, 1999, -1, -1, -1, + 3468, -1, -1, -1, -1, -1, 2151, -1, -1, -1, + 3478, -1, -1, 3481, -1, 3483, -1, 2946, -1, -1, + -1, -1, -1, -1, 3492, -1, -1, 2151, -1, -1, + 3498, -1, -1, 3501, -1, -1, 1415, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3683, -1, -1, -1, + -1, -1, -1, 3521, -1, -1, -1, -1, -1, -1, + -1, 3529, -1, 3531, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 2090, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 3575, -1, -1, + -1, 2114, -1, 3581, -1, -1, 2119, -1, -1, 3587, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 4045, + -1, -1, -1, -1, -1, -1, 2139, 2140, -1, 2142, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 4071, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 3808, -1, -1, -1, -1, -1, -1, 2181, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3833, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 4123, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 3865, 3866, + 3867, -1, 2235, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 1256, -1, -1, + -1, -1, -1, -1, 2257, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 2267, -1, -1, 2270, -1, -1, + -1, -1, -1, -1, -1, -1, 2421, -1, -1, -1, + -1, 2426, 2427, -1, -1, -1, -1, -1, -1, 3926, + -1, -1, -1, 2438, -1, -1, -1, 2421, -1, -1, + -1, -1, 2426, 2427, 1683, -1, -1, -1, -1, -1, + -1, -1, -1, 4229, 2438, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3963, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3973, 3974, -1, 3976, + -1, -1, 3271, -1, 3981, 3982, -1, -1, -1, 3986, + 3987, -1, -1, -1, -1, 3992, 3993, 1736, -1, 3996, + -1, -1, -1, -1, -1, -1, -1, 3296, -1, -1, + -1, -1, -1, -1, 4011, 3304, -1, -1, 4015, 3308, + -1, -1, -1, -1, 1763, -1, -1, 4024, -1, -1, + -1, -1, 4029, 3322, -1, -1, -1, -1, 3866, 3867, + -1, -1, -1, -1, 4041, -1, 1415, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 2569, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 4080, -1, 2569, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 1834, -1, -1, 3926, -1, + -1, 4098, 3391, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 1853, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 4402, -1, -1, 4126, + -1, -1, 1871, -1, 2639, -1, -1, -1, -1, -1, + -1, 4138, -1, -1, -1, 3973, 3974, -1, -1, -1, + -1, -1, -1, -1, -1, 2639, -1, -1, 3986, -1, + 1899, -1, -1, -1, 3992, 3993, -1, -1, 3996, -1, + -1, -1, 4448, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 4182, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 4024, -1, -1, -1, + -1, 4029, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 4041, -1, -1, -1, -1, 1957, 3508, + 3509, 3510, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 2738, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 4245, -1, + -1, -1, 4080, -1, 2738, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 1256, -1, -1, -1, -1, -1, -1, + 4297, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 1683, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 4330, -1, -1, -1, 4334, -1, -1, + -1, -1, 4339, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 4356, + 4357, -1, -1, 4360, -1, -1, -1, 1736, -1, -1, + -1, -1, -1, -1, 4371, -1, -1, -1, -1, 4376, + -1, -1, 4379, -1, -1, -1, -1, 4384, 4385, -1, + -1, -1, -1, -1, 1763, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 2151, -1, 2777, -1, -1, 4245, -1, -1, + 4417, -1, -1, -1, -1, -1, -1, -1, -1, 4705, + -1, -1, -1, -1, -1, -1, -1, 2800, -1, 2802, + -1, 2804, 2805, 2806, -1, -1, 2809, -1, -1, -1, + 2813, 4448, 1415, -1, -1, 4452, -1, 2820, -1, -1, + -1, -1, 2825, -1, -1, 1834, -1, -1, 2831, -1, + -1, -1, -1, 2836, -1, -1, -1, -1, -1, -1, + -1, -1, 2845, -1, 1853, -1, 2849, 2850, -1, 2852, + -1, -1, 4489, -1, -1, -1, -1, -1, -1, -1, + -1, 2864, 1871, -1, -1, -1, 3795, -1, 2871, -1, + 2873, 2874, 2875, 2876, 2877, 2878, 2879, 2880, 2881, 2882, + -1, -1, -1, -1, -1, 3814, -1, -1, -1, -1, + 1899, -1, 4360, 3038, -1, -1, -1, -1, -1, -1, + -1, 4538, -1, 4540, 2907, -1, -1, 3836, -1, -1, + -1, -1, -1, -1, 3038, -1, -1, 4385, -1, -1, + -1, -1, -1, -1, -1, 4562, 4563, -1, 4565, -1, + 4567, -1, -1, 3078, 3079, -1, 3081, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 4584, 1957, -1, + -1, 4588, -1, -1, 3078, 3079, 4593, 3081, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 3133, -1, + 3135, -1, -1, -1, -1, 4632, -1, -1, -1, 4636, + 4637, -1, -1, -1, -1, -1, -1, -1, -1, 3133, + -1, 3135, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 3030, -1, -1, + -1, -1, -1, 4670, -1, -1, -1, -1, -1, -1, + -1, -1, 2421, 3188, -1, -1, -1, 2426, 2427, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 2438, + -1, 4698, -1, -1, 3188, -1, -1, 3212, -1, 3998, + 3999, 4000, 4001, -1, -1, -1, -1, -1, -1, -1, + 1683, -1, -1, -1, -1, -1, -1, -1, 3212, -1, + -1, 4728, -1, -1, 3239, -1, -1, 4565, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 3252, 4745, -1, + -1, -1, -1, -1, -1, 3239, 4584, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 3252, -1, + -1, -1, -1, 1736, -1, -1, -1, -1, -1, -1, + -1, -1, 2151, 4780, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 4790, -1, -1, -1, -1, -1, -1, + 1763, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 3315, -1, -1, -1, 4811, 4812, -1, -1, -1, -1, + -1, -1, -1, -1, 3329, -1, -1, 4824, -1, -1, + 2569, 3315, -1, -1, -1, -1, -1, 3342, -1, -1, + -1, -1, 4670, -1, -1, 3329, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 3342, -1, + -1, -1, -1, 4860, -1, -1, -1, -1, -1, -1, + -1, 1834, -1, 4870, -1, -1, -1, 3240, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 1853, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 2639, -1, -1, -1, -1, 3410, -1, -1, 1871, -1, + -1, -1, -1, -1, -1, -1, -1, 4745, -1, -1, + -1, -1, -1, -1, -1, 3430, 3410, -1, -1, -1, + -1, 4928, -1, -1, -1, -1, 1899, -1, -1, -1, + 4937, -1, -1, -1, -1, -1, 3430, -1, -1, -1, + 3455, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 3455, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 4811, 4812, -1, 3491, -1, -1, -1, + -1, -1, -1, -1, 1957, -1, -1, -1, 3361, 2738, + -1, -1, -1, -1, -1, -1, -1, 3491, -1, -1, + -1, 4300, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 4860, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 4870, 3406, -1, -1, -1, -1, -1, 3412, + -1, -1, 2421, -1, -1, -1, -1, 2426, 2427, -1, + -1, -1, -1, -1, -1, 3428, 3429, -1, 3431, 2438, + -1, 3434, 3435, 3436, 3437, 3438, 3439, 3440, 3441, 3442, + 3443, 3444, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 4928, -1, -1, -1, -1, -1, 3469, -1, -1, 3472, + -1, 3474, -1, -1, -1, -1, 3479, 3480, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 3493, 3494, 3495, -1, 3497, -1, -1, 3500, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 3683, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 2151, -1, + -1, -1, -1, -1, 3557, -1, -1, -1, -1, 3683, + 2569, -1, -1, -1, -1, 3568, -1, -1, -1, 4498, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 4529, -1, -1, -1, -1, -1, 3609, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 2639, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 3038, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 3833, -1, + -1, -1, -1, -1, 4623, -1, -1, -1, -1, 3078, + 3079, -1, 3081, -1, -1, -1, -1, -1, -1, 3833, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 3865, -1, -1, -1, -1, -1, -1, -1, -1, 2738, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 3865, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 3133, -1, 3135, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 3808, -1, -1, -1, 3188, + -1, -1, -1, -1, -1, -1, -1, -1, 2421, -1, + -1, -1, -1, 2426, 2427, -1, -1, -1, -1, -1, + -1, 3976, -1, 3212, -1, 2438, -1, -1, -1, -1, + -1, -1, 3987, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 3976, -1, -1, -1, -1, -1, -1, -1, + 3239, -1, -1, 3987, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 3252, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 3927, -1, -1, -1, 3931, 3932, + 3933, -1, -1, 3936, -1, -1, 3315, -1, 3941, 3942, + 3943, 3944, 3945, 3946, 3947, 3948, 3949, 3950, 3951, 3952, + 3329, -1, -1, 4098, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 3342, -1, -1, 2569, -1, -1, -1, + -1, -1, -1, -1, 4098, -1, -1, 3980, 3981, 3982, + 3983, 4126, 3985, -1, -1, -1, 3989, 3990, 3991, -1, + -1, 3994, -1, 4138, 3997, -1, -1, -1, -1, -1, + -1, -1, 4126, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 4138, -1, -1, -1, -1, -1, + -1, -1, -1, 4026, -1, -1, -1, -1, -1, 3038, + -1, 3410, -1, -1, -1, 4038, 2639, 4182, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 3430, 4055, -1, -1, -1, -1, -1, 4182, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 3078, + 3079, -1, 3081, -1, -1, -1, 3455, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 3491, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 3133, -1, 3135, -1, -1, -1, + -1, -1, -1, -1, -1, 2738, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 3188, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 4334, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 3212, -1, -1, -1, -1, -1, -1, + 4334, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 3239, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 3252, -1, 4248, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 4294, 4295, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 4448, 3683, -1, 3315, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 3329, -1, -1, 4326, 4448, -1, -1, 4330, -1, -1, + -1, -1, -1, 3342, -1, -1, -1, -1, -1, -1, + -1, 4344, -1, 4346, -1, -1, -1, -1, 4351, 4352, + 4353, -1, -1, 4356, 4357, 4358, 4359, -1, 4361, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 4540, -1, -1, -1, -1, + -1, 3410, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 4415, -1, -1, -1, 4540, -1, 4563, -1, + -1, 3430, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 3038, -1, -1, -1, 4563, + -1, -1, -1, -1, -1, -1, 3455, -1, 4593, -1, + -1, -1, -1, -1, 3833, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 4593, + -1, -1, -1, -1, -1, 3078, 3079, -1, 3081, -1, + -1, -1, 3491, -1, -1, -1, 3865, 4632, -1, -1, + -1, 4636, 4637, -1, -1, -1, -1, -1, 4501, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 4632, -1, + -1, -1, 4636, 4637, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 3133, -1, 3135, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 4561, 4562, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 4577, 4578, 4579, -1, -1, -1, + -1, -1, -1, -1, -1, 3188, -1, -1, -1, -1, + -1, -1, -1, 4596, -1, -1, -1, 3976, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 3987, 3212, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 3239, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 3252, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 3683, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 4708, -1, -1, -1, -1, + -1, -1, 3315, -1, -1, 4718, -1, -1, -1, 4098, + -1, -1, -1, -1, -1, -1, 3329, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 3342, + -1, -1, -1, -1, -1, -1, -1, 4126, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 4138, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 4779, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 4182, -1, -1, -1, 3410, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 4823, -1, -1, -1, 3833, -1, -1, 3430, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 3455, -1, -1, -1, 3865, -1, -1, -1, + 4863, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 3491, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 4907, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 6, 7, 8, -1, 10, 11, 12, + -1, -1, -1, 16, -1, 4334, 19, 20, 21, 22, + 23, 24, -1, 26, 27, -1, -1, 3976, 31, 32, + 33, 34, -1, 36, 37, 38, 39, 40, 3987, 42, + 43, 44, -1, -1, -1, -1, -1, 50, 51, -1, + -1, -1, -1, 56, -1, -1, -1, -1, -1, -1, + -1, -1, 65, -1, 67, -1, 69, -1, 71, -1, + -1, -1, -1, -1, -1, -1, 79, 80, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 115, -1, -1, -1, 119, 120, 121, 122, + 123, -1, -1, -1, -1, -1, -1, -1, -1, 4448, + -1, -1, 135, -1, -1, -1, -1, -1, -1, 142, + 3683, 144, -1, -1, -1, -1, -1, 150, -1, 4098, + -1, -1, -1, -1, -1, -1, -1, -1, 161, -1, + -1, -1, -1, -1, 167, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 177, 178, -1, 4126, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 4138, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 204, -1, -1, -1, -1, -1, -1, 211, -1, + -1, -1, 215, -1, -1, -1, -1, 220, -1, -1, + -1, 4540, -1, 226, -1, 228, -1, -1, -1, -1, + -1, 234, -1, 4182, -1, -1, -1, -1, -1, -1, + 243, -1, -1, -1, 4563, -1, -1, -1, -1, -1, + -1, -1, -1, 256, 257, -1, -1, -1, -1, -1, + 263, -1, 265, -1, -1, 268, 269, -1, 271, -1, + -1, -1, -1, -1, 4593, -1, -1, -1, 281, 282, + -1, 284, -1, -1, -1, -1, -1, -1, -1, -1, + 3833, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 303, 304, 305, -1, -1, 308, -1, -1, -1, 312, + -1, -1, 315, 4632, 317, -1, -1, 4636, 4637, -1, + -1, -1, 3865, -1, -1, -1, -1, 330, 331, 332, + 333, 334, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 344, -1, 346, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 358, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 377, -1, -1, 380, -1, -1, + -1, -1, -1, -1, -1, 4334, -1, -1, -1, -1, + -1, -1, -1, -1, 397, -1, -1, 400, -1, 402, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 415, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 427, 428, -1, -1, -1, 432, + -1, 434, -1, 3976, -1, -1, -1, -1, -1, -1, + 443, -1, -1, -1, 3987, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 458, -1, -1, 461, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 475, 476, 477, 478, 479, 480, 481, 482, + 483, -1, -1, -1, -1, -1, -1, -1, 6, 7, + 8, -1, 10, 11, 12, -1, -1, -1, 16, 4448, + -1, 19, 20, 21, 22, 23, 24, 510, 26, 27, + -1, -1, -1, 31, 32, 33, 34, -1, 36, 37, + 38, 39, 40, -1, 42, 43, 44, -1, -1, -1, + -1, -1, 50, 51, -1, -1, -1, -1, 56, -1, + -1, -1, -1, -1, -1, -1, -1, 65, -1, 67, + -1, 69, -1, 71, -1, 4098, -1, -1, -1, -1, + -1, 79, 80, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 4126, -1, -1, -1, -1, -1, -1, + -1, 4540, -1, -1, -1, 4138, -1, 115, -1, -1, + -1, 119, 120, 121, 122, 123, -1, -1, -1, -1, + -1, -1, -1, -1, 4563, -1, -1, 135, -1, -1, + -1, -1, -1, -1, 142, -1, 144, -1, -1, -1, + -1, -1, 150, -1, -1, -1, -1, -1, -1, 4182, + -1, -1, -1, 161, 4593, -1, -1, -1, -1, 167, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 177, + 178, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 4632, -1, -1, 204, 4636, 4637, -1, + -1, -1, -1, 211, -1, -1, -1, 215, -1, -1, + -1, -1, 220, -1, -1, -1, -1, -1, 226, -1, + 228, -1, -1, -1, -1, -1, 234, -1, -1, -1, + -1, -1, -1, -1, -1, 243, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 256, 257, + -1, -1, -1, -1, -1, 263, -1, 265, -1, -1, + 268, 269, -1, 271, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 281, 282, -1, 284, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 303, 304, 305, -1, -1, + 308, 4334, -1, -1, 312, -1, -1, 315, -1, 317, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 330, 331, 332, 333, 334, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 344, -1, 346, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 358, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 377, + -1, -1, 380, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 397, + -1, -1, 400, -1, 402, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 415, -1, -1, + -1, -1, -1, -1, -1, 4448, -1, -1, -1, 427, + 428, -1, -1, -1, 432, -1, 434, -1, -1, -1, + -1, -1, -1, -1, -1, 443, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 458, -1, -1, 461, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 475, 476, 477, + 478, 479, 480, 481, 482, 483, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 510, -1, -1, -1, -1, 4540, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 4563, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 5, 6, 7, + 8, 9, 10, 11, 12, 13, -1, 15, 16, -1, + 4593, 19, 20, 21, 22, 23, 24, 25, 26, 27, + 28, 29, -1, 31, 32, 33, 34, 35, 36, 37, + 38, 39, 40, -1, 42, 43, 44, 45, 46, -1, + -1, -1, 50, 51, -1, -1, -1, -1, 56, 4632, + -1, -1, -1, 4636, 4637, -1, -1, 65, -1, 67, + -1, 69, 70, 71, -1, -1, -1, -1, -1, -1, + -1, 79, 80, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 91, 92, 93, 94, 95, 96, 97, + 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, + 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, + 118, 119, 120, 121, 122, 123, 124, 125, 126, 127, + 128, 129, 130, 131, 132, 133, 134, 135, 136, 137, + 138, 139, 140, 141, 142, 143, 144, 145, 146, 147, + 148, 149, 150, 151, 152, 153, 154, 155, 156, 157, + 158, 159, 160, 161, 162, 163, 164, 165, 166, 167, + 168, 169, 170, 171, 172, 173, 174, 175, 176, 177, + 178, 179, 180, 181, 182, 183, 184, 185, 186, 187, + 188, 189, 190, 191, 192, 193, 194, 195, 196, 197, + 198, 199, 200, 201, 202, 203, 204, 205, 206, 207, + 208, 209, 210, 211, 212, 213, 214, 215, 216, 217, + 218, 219, 220, 221, 222, 223, 224, 225, 226, 227, + 228, 229, 230, 231, 232, 233, 234, 235, 236, 237, + 238, 239, 240, 241, 242, 243, 244, 245, 246, 247, + 248, 249, 250, 251, 252, 253, 254, 255, 256, 257, + 258, 259, 260, 261, 262, 263, 264, 265, 266, 267, + 268, 269, 270, 271, 272, 273, 274, 275, 276, 277, + 278, 279, 280, 281, 282, 283, 284, 285, 286, 287, + 288, 289, 290, 291, 292, 293, 294, 295, 296, 297, + 298, 299, 300, 301, 302, 303, 304, 305, 306, 307, + 308, 309, 310, 311, 312, 313, 314, 315, 316, 317, + 318, 319, 320, 321, 322, 323, 324, 325, 326, 327, + 328, 329, 330, 331, 332, 333, 334, 335, 336, 337, + 338, 339, 340, 341, 342, 343, 344, 345, 346, 347, + 348, 349, 350, 351, 352, 353, 354, 355, 356, 357, + 358, 359, 360, 361, 362, 363, 364, 365, 366, 367, + 368, 369, 370, 371, 372, 373, 374, 375, 376, 377, + 378, 379, 380, 381, 382, 383, 384, 385, 386, 387, + 388, 389, 390, 391, 392, 393, 394, 395, 396, 397, + 398, 399, 400, 401, 402, 403, 404, 405, 406, 407, + 408, 409, 410, 411, 412, 413, 414, 415, 416, 417, + 418, 419, 420, 421, 422, 423, 424, 425, 426, 427, + 428, 429, 430, 431, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 442, 443, 444, 445, 446, 447, + 448, 449, 450, 451, 452, 453, 454, 455, 456, 457, + 458, 459, 460, 461, 462, 463, 464, 465, 466, 467, + 468, 469, 470, 471, 472, 473, 474, 475, 476, 477, + 478, 479, 480, 481, 482, 483, 484, 485, 486, 3, + -1, -1, 6, 7, 8, 9, 10, 11, 12, 13, + -1, 15, 16, 17, 18, 19, 20, 21, 22, 23, + 24, 509, 26, 27, 28, -1, -1, 31, 32, 33, + 34, -1, 36, 37, 38, 39, 40, -1, 42, 43, + 44, 45, 46, -1, -1, -1, 50, 51, -1, -1, + -1, -1, 56, -1, -1, -1, -1, -1, -1, -1, + -1, 65, -1, 67, -1, 69, 70, 71, -1, -1, + -1, -1, -1, -1, -1, 79, 80, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 91, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 101, -1, 103, + 104, -1, -1, -1, -1, -1, -1, -1, -1, 113, + -1, 115, -1, -1, 118, 119, 120, 121, 122, 123, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 135, -1, -1, 138, -1, 140, 141, 142, -1, + 144, -1, 146, -1, 148, -1, 150, -1, -1, -1, + -1, -1, -1, -1, 158, -1, 160, 161, -1, -1, + -1, -1, -1, 167, -1, -1, -1, -1, -1, -1, + 174, -1, 176, 177, 178, 179, -1, -1, -1, -1, + -1, 185, -1, -1, -1, -1, -1, 191, -1, 193, + -1, -1, -1, 197, -1, -1, -1, -1, -1, 203, + 204, -1, -1, -1, -1, -1, 210, 211, 212, -1, + -1, 215, -1, -1, 218, -1, 220, -1, -1, -1, + -1, -1, 226, -1, 228, -1, -1, -1, 232, -1, + 234, -1, -1, -1, -1, -1, -1, -1, -1, 243, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 256, 257, -1, -1, 260, -1, -1, 263, + -1, 265, -1, -1, 268, 269, -1, 271, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 281, 282, -1, + 284, -1, 286, 287, -1, -1, -1, -1, 292, -1, + -1, -1, -1, -1, -1, -1, 300, -1, -1, 303, + 304, 305, -1, -1, 308, -1, -1, 311, 312, -1, + -1, 315, -1, 317, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 330, 331, 332, 333, + 334, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 344, -1, 346, -1, 348, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 358, 359, -1, -1, -1, -1, + 364, -1, 366, -1, -1, -1, -1, 371, -1, -1, + -1, -1, 376, 377, -1, 379, 380, -1, -1, 383, + -1, -1, -1, -1, 388, 389, -1, -1, -1, -1, + -1, -1, 396, 397, -1, 399, 400, -1, 402, -1, + -1, -1, -1, 407, -1, -1, -1, -1, -1, -1, + -1, 415, -1, -1, -1, 419, -1, -1, -1, -1, + -1, -1, -1, 427, 428, -1, -1, -1, 432, -1, + 434, -1, 436, -1, 438, -1, -1, -1, -1, 443, + -1, -1, 446, -1, -1, 449, -1, -1, 452, -1, + -1, -1, -1, 457, 458, -1, -1, 461, -1, -1, + -1, -1, 5, -1, -1, 469, -1, -1, -1, -1, + -1, 475, 476, 477, 478, 479, 480, 481, 482, 483, + -1, -1, 25, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 35, 36, -1, -1, -1, -1, -1, 503, + 43, 44, -1, 507, 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, -1, + -1, -1, 75, 76, 77, 78, 79, 80, 81, 82, + -1, -1, -1, 86, -1, -1, -1, -1, -1, -1, + -1, 5, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 25, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 35, 36, -1, -1, -1, -1, -1, -1, 43, + 44, 134, -1, 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, -1, -1, + -1, 75, 76, 77, 78, 79, 80, 81, 82, -1, + -1, -1, 86, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 204, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 220, -1, -1, + 134, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 240, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 262, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 204, -1, -1, 296, -1, -1, 299, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 220, -1, -1, -1, + -1, 314, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 240, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 262, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 296, -1, 387, 299, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 314, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 429, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 443, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 458, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 387, -1, -1, -1, -1, -1, -1, + -1, 484, -1, -1, -1, -1, -1, 490, -1, -1, + -1, 494, 495, 496, 497, 498, -1, -1, 501, 502, + 503, 504, -1, -1, -1, 508, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 429, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 443, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 458, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 5, -1, -1, -1, -1, + 484, -1, -1, -1, -1, -1, 490, -1, -1, -1, + 494, 495, 496, 497, 498, 25, -1, 501, 502, 503, + 504, -1, -1, -1, 508, 35, 36, -1, -1, -1, + -1, -1, -1, 43, 44, -1, -1, 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, -1, -1, -1, 75, 76, 77, 78, 79, + 80, 81, 82, -1, -1, -1, 86, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 134, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 204, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 220, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 240, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 262, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 296, -1, -1, 299, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 314, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 387, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 429, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 443, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 458, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 484, -1, -1, -1, -1, -1, + 490, -1, -1, -1, 494, 495, 496, 497, 498, -1, + -1, 501, 502, 503, -1, -1, -1, -1, 508, 5, + 6, 7, 8, 9, 10, 11, 12, 13, -1, 15, + 16, -1, -1, 19, 20, 21, 22, 23, 24, 25, + 26, 27, 28, 29, -1, 31, 32, 33, 34, 35, + 36, 37, 38, 39, 40, -1, 42, 43, 44, 45, + 46, -1, -1, -1, 50, 51, -1, -1, -1, -1, + 56, -1, -1, -1, -1, -1, -1, -1, -1, 65, + -1, 67, -1, 69, 70, 71, 72, -1, -1, 75, + 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, + 86, 87, -1, -1, -1, 91, 92, 93, 94, 95, + 96, 97, 98, 99, 100, 101, 102, -1, -1, -1, + -1, 107, -1, -1, 110, 111, -1, 113, 114, 115, + 116, 117, 118, 119, 120, 121, 122, 123, -1, 125, + 126, 127, 128, 129, 130, 131, 132, 133, 134, 135, + 136, -1, 138, 139, 140, 141, 142, -1, 144, -1, + 146, 147, 148, 149, 150, 151, 152, -1, 154, 155, + 156, 157, 158, 159, -1, 161, 162, -1, 164, 165, + 166, 167, 168, 169, 170, 171, 172, 173, 174, 175, + 176, 177, 178, 179, -1, 181, -1, 183, 184, 185, + 186, 187, -1, 189, 190, 191, 192, -1, 194, 195, + 196, 197, 198, -1, 200, 201, 202, -1, 204, 205, + -1, 207, 208, 209, 210, 211, 212, 213, 214, 215, + 216, 217, -1, 219, 220, 221, -1, 223, -1, 225, + 226, -1, 228, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, 243, 244, 245, + 246, -1, 248, 249, 250, 251, 252, 253, -1, 255, + 256, 257, -1, 259, 260, 261, 262, 263, -1, 265, + -1, 267, 268, 269, 270, 271, 272, 273, 274, 275, + 276, 277, 278, -1, 280, 281, 282, 283, 284, -1, + 286, 287, 288, 289, 290, 291, 292, 293, 294, 295, + 296, 297, 298, 299, 300, 301, 302, 303, 304, 305, + 306, 307, 308, 309, 310, 311, 312, 313, 314, 315, + 316, 317, 318, 319, 320, -1, 322, -1, -1, 325, + 326, 327, -1, -1, 330, 331, 332, 333, 334, 335, + 336, 337, 338, 339, 340, 341, -1, 343, 344, 345, + 346, 347, 348, 349, -1, 351, 352, 353, 354, 355, + 356, 357, 358, 359, 360, 361, 362, -1, 364, 365, + 366, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, 377, 378, 379, 380, 381, 382, 383, 384, 385, + 386, 387, 388, -1, 390, 391, 392, 393, 394, 395, + 396, 397, 398, 399, 400, 401, 402, 403, -1, 405, + 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, + -1, 417, 418, -1, 420, 421, 422, 423, 424, 425, + -1, 427, 428, -1, -1, 431, 432, 433, 434, 435, + 436, 437, 438, 439, 440, 441, 442, -1, 444, 445, + 446, 447, 448, 449, 450, -1, 452, 453, 454, 455, + 456, 457, 458, 459, 460, 461, 462, 463, 464, -1, + -1, 467, -1, -1, 470, 471, 472, 473, 474, 475, + 476, 477, 478, 479, 480, 481, 482, 483, 484, 485, + 486, -1, -1, -1, -1, -1, -1, -1, 494, 495, + 496, -1, -1, -1, -1, -1, -1, 503, 504, 5, + 6, 7, 8, 9, 10, 11, 12, 13, -1, 15, + 16, -1, -1, 19, 20, 21, 22, 23, 24, 25, + 26, 27, 28, 29, -1, 31, 32, 33, 34, 35, + 36, 37, 38, 39, 40, -1, 42, 43, 44, 45, + 46, -1, -1, -1, 50, 51, -1, -1, -1, -1, + 56, -1, -1, -1, -1, -1, -1, -1, -1, 65, + -1, 67, -1, 69, 70, 71, 72, -1, -1, 75, + 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, + 86, 87, -1, -1, -1, 91, 92, 93, 94, 95, + 96, 97, 98, -1, 100, 101, 102, -1, -1, -1, + -1, 107, -1, -1, 110, 111, -1, 113, 114, 115, + 116, 117, 118, 119, 120, 121, 122, 123, -1, 125, + 126, 127, 128, 129, 130, 131, 132, 133, 134, 135, + 136, -1, 138, 139, 140, 141, 142, -1, 144, -1, + 146, 147, 148, 149, 150, 151, 152, -1, 154, 155, + 156, 157, 158, 159, -1, 161, 162, -1, 164, 165, + 166, 167, 168, 169, 170, 171, 172, 173, 174, 175, + 176, 177, 178, 179, -1, 181, -1, 183, 184, 185, + 186, 187, -1, 189, 190, 191, -1, -1, 194, 195, + 196, 197, 198, -1, 200, 201, 202, -1, 204, 205, + -1, 207, 208, 209, 210, 211, 212, 213, 214, 215, + 216, 217, -1, 219, 220, 221, -1, 223, -1, 225, + 226, -1, 228, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, 243, 244, 245, + 246, -1, 248, 249, 250, 251, 252, 253, -1, 255, + 256, 257, -1, 259, 260, 261, 262, 263, -1, 265, + -1, 267, 268, 269, 270, 271, 272, 273, 274, 275, + 276, 277, 278, -1, 280, 281, 282, 283, 284, -1, + 286, 287, 288, 289, 290, 291, 292, 293, 294, 295, + 296, 297, 298, 299, 300, 301, 302, 303, 304, 305, + 306, 307, 308, 309, 310, 311, 312, 313, 314, 315, + 316, 317, 318, 319, 320, -1, 322, -1, -1, 325, + 326, 327, -1, -1, 330, 331, 332, 333, 334, 335, + 336, 337, 338, 339, 340, 341, -1, 343, 344, 345, + 346, 347, 348, 349, -1, 351, 352, 353, 354, 355, + 356, 357, 358, 359, 360, 361, 362, -1, 364, 365, + 366, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, 377, 378, 379, 380, 381, 382, 383, 384, 385, + 386, 387, 388, -1, 390, 391, 392, 393, 394, 395, + 396, 397, 398, 399, 400, 401, 402, 403, -1, 405, + 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, + -1, 417, 418, -1, 420, 421, 422, 423, 424, 425, + -1, 427, 428, -1, -1, 431, 432, 433, 434, 435, + 436, 437, 438, 439, 440, 441, 442, -1, 444, 445, + 446, 447, 448, 449, 450, -1, 452, 453, 454, 455, + 456, 457, 458, -1, 460, 461, 462, 463, 464, -1, + -1, 467, -1, -1, 470, 471, 472, 473, 474, 475, + 476, 477, 478, 479, 480, 481, 482, 483, 484, 485, + 486, -1, -1, -1, -1, -1, -1, -1, 494, 495, + -1, -1, -1, -1, -1, -1, -1, 503, 504, 5, + 6, 7, 8, 9, 10, 11, 12, 13, -1, 15, + 16, -1, -1, 19, 20, 21, 22, 23, 24, 25, + 26, 27, 28, 29, -1, 31, 32, 33, 34, 35, + 36, 37, 38, 39, 40, -1, 42, 43, 44, 45, + 46, -1, -1, -1, 50, 51, -1, -1, -1, -1, + 56, -1, -1, -1, -1, -1, -1, -1, -1, 65, + -1, 67, -1, 69, 70, 71, -1, -1, -1, -1, + -1, -1, -1, 79, 80, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 91, 92, 93, 94, 95, + 96, 97, 98, -1, 100, 101, 102, -1, -1, -1, + -1, -1, -1, -1, 110, 111, -1, 113, 114, 115, + 116, 117, 118, -1, 120, 121, 122, 123, -1, 125, + 126, 127, 128, 129, -1, -1, 132, 133, 134, 135, + 136, -1, 138, 139, 140, 141, -1, -1, 144, -1, + 146, 147, 148, 149, 150, 151, 152, -1, 154, 155, + 156, 157, 158, 159, -1, 161, 162, -1, -1, -1, + -1, 167, -1, -1, -1, 171, 172, 173, 174, 175, + 176, 177, 178, 179, -1, 181, -1, 183, 184, 185, + 186, 187, -1, 189, 190, 191, -1, -1, 194, 195, + 196, 197, 198, -1, 200, 201, 202, -1, 204, 205, + -1, 207, 208, 209, 210, -1, 212, 213, 214, -1, + -1, 217, -1, 219, 220, 221, -1, 223, -1, 225, + 226, -1, 228, 229, 230, 231, -1, 233, -1, -1, + 236, -1, 238, 239, 240, 241, 242, 243, 244, 245, + 246, 247, 248, 249, 250, 251, 252, 253, -1, 255, + 256, 257, -1, 259, 260, 261, 262, 263, -1, 265, + -1, 267, 268, 269, 270, 271, 272, 273, 274, 275, + 276, 277, 278, -1, 280, -1, 282, 283, 284, -1, + 286, 287, 288, -1, -1, 291, 292, 293, 294, 295, + 296, 297, 298, 299, 300, 301, 302, 303, 304, 305, + 306, 307, -1, -1, 310, 311, 312, 313, -1, -1, + 316, 317, 318, 319, 320, -1, 322, -1, -1, 325, + 326, 327, -1, -1, 330, 331, 332, 333, -1, 335, + 336, 337, 338, 339, 340, 341, -1, 343, -1, 345, + -1, 347, 348, 349, -1, 351, 352, 353, 354, 355, + 356, 357, 358, 359, 360, 361, 362, -1, 364, 365, + 366, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, 377, 378, 379, -1, 381, 382, 383, 384, 385, + 386, 387, 388, -1, 390, 391, 392, 393, 394, -1, + 396, 397, 398, 399, 400, 401, 402, 403, -1, 405, + 406, 407, 408, 409, 410, 411, 412, 413, 414, -1, + -1, 417, 418, -1, 420, 421, 422, 423, 424, 425, + -1, 427, 428, -1, -1, 431, -1, 433, -1, -1, + 436, 437, 438, 439, 440, 441, 442, -1, -1, 445, + 446, 447, 448, 449, -1, -1, 452, 453, 454, 455, + 456, -1, 458, 459, 460, 461, 462, 463, 464, -1, + -1, 467, -1, -1, 470, 471, 472, 473, 474, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 484, 485, + 486, -1, -1, -1, -1, 5, 6, 7, 8, 9, + 10, 11, 12, 13, -1, 15, 16, -1, 504, 19, + 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, + -1, 31, 32, 33, 34, 35, 36, 37, 38, 39, + 40, -1, 42, 43, 44, 45, 46, -1, -1, -1, + 50, 51, -1, -1, -1, -1, 56, -1, -1, -1, + -1, -1, -1, -1, -1, 65, -1, 67, -1, 69, + 70, 71, -1, -1, -1, -1, -1, -1, -1, 79, + 80, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 91, 92, 93, 94, 95, 96, 97, 98, -1, + 100, 101, 102, -1, -1, -1, -1, -1, -1, -1, + 110, 111, -1, 113, 114, 115, 116, 117, 118, -1, + 120, 121, 122, 123, -1, 125, 126, 127, 128, 129, + -1, -1, 132, 133, 134, 135, 136, -1, 138, 139, + 140, 141, -1, -1, 144, -1, 146, 147, 148, 149, + 150, 151, 152, -1, 154, 155, 156, 157, 158, 159, + -1, 161, 162, -1, -1, -1, -1, 167, -1, -1, + -1, 171, 172, 173, 174, 175, 176, 177, 178, 179, + -1, 181, -1, 183, 184, 185, 186, 187, -1, 189, + 190, 191, -1, -1, 194, 195, 196, 197, 198, -1, + 200, 201, 202, -1, 204, 205, -1, 207, 208, 209, + 210, -1, 212, 213, 214, -1, -1, 217, -1, 219, + 220, 221, -1, 223, -1, 225, 226, -1, 228, 229, + 230, 231, -1, 233, -1, -1, 236, -1, 238, 239, + 240, 241, 242, 243, 244, 245, 246, 247, 248, 249, + 250, 251, 252, 253, -1, 255, 256, 257, -1, 259, + 260, 261, 262, 263, -1, 265, -1, 267, 268, 269, + 270, 271, 272, 273, 274, 275, 276, 277, 278, -1, + 280, -1, 282, 283, 284, -1, 286, 287, 288, -1, + -1, 291, 292, 293, 294, 295, 296, 297, 298, 299, + 300, 301, 302, 303, 304, 305, 306, 307, -1, -1, + 310, 311, 312, 313, -1, -1, 316, 317, 318, 319, + 320, -1, 322, -1, -1, 325, 326, 327, -1, -1, + 330, 331, 332, 333, -1, 335, 336, 337, 338, 339, + 340, 341, -1, 343, -1, 345, -1, 347, 348, 349, + -1, 351, 352, 353, 354, 355, 356, 357, 358, 359, + 360, 361, 362, -1, 364, 365, 366, 367, 368, 369, + 370, 371, 372, 373, -1, 375, 376, 377, 378, 379, + -1, 381, 382, 383, 384, 385, 386, 387, 388, -1, + 390, 391, 392, 393, 394, -1, 396, 397, 398, 399, + 400, 401, 402, 403, -1, 405, 406, 407, 408, 409, + 410, 411, 412, 413, 414, -1, -1, 417, 418, -1, + 420, 421, 422, 423, 424, 425, -1, 427, 428, -1, + -1, 431, -1, 433, -1, -1, 436, 437, 438, 439, + 440, 441, 442, -1, -1, 445, 446, 447, 448, 449, + -1, -1, 452, 453, 454, 455, 456, -1, 458, 459, + 460, 461, 462, 463, 464, -1, -1, 467, -1, -1, + 470, 471, 472, 473, 474, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 484, 485, 486, -1, -1, -1, + -1, 5, 6, 7, 8, 9, 10, 11, 12, 13, + -1, 15, 16, -1, 504, 19, 20, 21, 22, 23, + 24, 25, 26, 27, 28, 29, -1, 31, 32, 33, + 34, 35, 36, 37, 38, 39, 40, -1, 42, 43, + 44, 45, 46, -1, -1, -1, 50, 51, -1, -1, + -1, -1, 56, -1, -1, -1, -1, -1, -1, -1, + -1, 65, -1, 67, -1, 69, 70, 71, 72, -1, + -1, 75, 76, 77, 78, 79, 80, 81, 82, 83, + 84, 85, 86, 87, -1, -1, -1, 91, 92, 93, + 94, 95, 96, 97, 98, -1, 100, 101, 102, -1, + -1, -1, -1, 107, -1, -1, 110, 111, -1, 113, + 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, + 124, 125, 126, 127, 128, 129, 130, 131, 132, 133, + 134, 135, 136, -1, 138, 139, 140, 141, 142, -1, + 144, -1, 146, 147, 148, 149, 150, 151, 152, -1, + 154, 155, 156, 157, 158, 159, -1, 161, 162, -1, + 164, 165, 166, 167, 168, 169, 170, 171, 172, 173, + 174, 175, 176, 177, 178, 179, -1, 181, -1, 183, + 184, 185, 186, 187, -1, 189, 190, 191, -1, -1, + 194, 195, 196, 197, 198, -1, 200, 201, 202, -1, + 204, 205, -1, 207, 208, 209, 210, 211, 212, 213, + 214, 215, 216, 217, -1, 219, 220, 221, -1, 223, + -1, 225, 226, 227, 228, 229, 230, 231, -1, 233, + 234, -1, 236, -1, 238, 239, 240, 241, 242, 243, + 244, 245, 246, -1, 248, 249, 250, 251, 252, 253, + -1, 255, 256, 257, -1, 259, 260, 261, 262, 263, + -1, 265, -1, 267, 268, 269, 270, 271, 272, 273, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, -1, 286, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, 297, 298, 299, 300, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, 312, 313, + 314, 315, 316, 317, 318, 319, 320, -1, 322, -1, + -1, 325, 326, 327, -1, -1, 330, 331, 332, 333, + 334, 335, 336, 337, 338, 339, 340, 341, -1, 343, + 344, 345, 346, 347, 348, 349, -1, 351, 352, 353, + 354, 355, 356, 357, 358, 359, 360, 361, 362, -1, + 364, 365, 366, 367, 368, 369, 370, 371, 372, 373, + -1, 375, 376, 377, 378, 379, 380, 381, 382, 383, + 384, 385, 386, 387, 388, -1, 390, 391, 392, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + -1, 405, 406, 407, 408, 409, 410, 411, 412, 413, + 414, 415, -1, 417, 418, -1, 420, 421, 422, 423, + 424, 425, -1, 427, 428, -1, 430, 431, 432, 433, + 434, 435, 436, 437, 438, 439, 440, 441, 442, -1, + 444, 445, 446, 447, 448, 449, 450, -1, 452, 453, + 454, 455, 456, 457, 458, -1, 460, 461, 462, 463, + 464, -1, -1, 467, -1, -1, 470, 471, 472, 473, + 474, 475, 476, 477, 478, 479, 480, 481, 482, 483, + 484, 485, 486, -1, -1, -1, -1, -1, -1, -1, + 494, 495, -1, -1, -1, -1, -1, -1, -1, 503, + 5, 6, 7, 8, 9, 10, 11, 12, 13, -1, + 15, 16, -1, -1, 19, 20, 21, 22, 23, 24, + 25, 26, 27, 28, 29, -1, 31, 32, 33, 34, + 35, 36, 37, 38, 39, 40, -1, 42, 43, 44, + 45, 46, -1, -1, -1, 50, 51, -1, -1, -1, + -1, 56, -1, -1, -1, -1, -1, -1, -1, -1, + 65, -1, 67, -1, 69, 70, 71, 72, -1, -1, + 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, + 85, 86, 87, -1, -1, -1, 91, 92, 93, 94, + 95, 96, 97, 98, -1, 100, 101, 102, -1, -1, + -1, -1, 107, -1, -1, 110, 111, -1, 113, 114, + 115, 116, 117, 118, 119, 120, 121, 122, 123, -1, + 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, + 135, 136, -1, 138, 139, 140, 141, 142, -1, 144, + -1, 146, 147, 148, 149, 150, 151, 152, -1, 154, + 155, 156, 157, 158, 159, -1, 161, 162, -1, 164, + 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, + 175, 176, 177, 178, 179, -1, 181, -1, 183, 184, + 185, 186, 187, -1, 189, 190, 191, -1, -1, 194, + 195, 196, 197, 198, -1, 200, 201, 202, -1, 204, + 205, -1, 207, 208, 209, 210, 211, 212, 213, 214, + 215, 216, 217, -1, 219, 220, 221, -1, 223, -1, + 225, 226, -1, 228, 229, 230, 231, -1, 233, 234, + -1, 236, -1, 238, 239, 240, 241, 242, 243, 244, + 245, 246, -1, 248, 249, 250, 251, 252, 253, -1, + 255, 256, 257, -1, 259, 260, 261, 262, 263, -1, + 265, -1, 267, 268, 269, 270, 271, 272, 273, 274, + 275, 276, 277, 278, -1, 280, 281, 282, 283, 284, + -1, 286, 287, 288, 289, 290, 291, 292, 293, 294, + 295, 296, 297, 298, 299, 300, 301, 302, 303, 304, + 305, 306, 307, 308, 309, 310, 311, 312, 313, 314, + 315, 316, 317, 318, 319, 320, -1, 322, -1, -1, + 325, 326, 327, -1, -1, 330, 331, 332, 333, 334, + 335, 336, 337, 338, 339, 340, 341, -1, 343, 344, + 345, 346, 347, 348, 349, -1, 351, 352, 353, 354, + 355, 356, 357, 358, 359, 360, 361, 362, -1, 364, + 365, 366, 367, 368, 369, 370, 371, 372, 373, -1, + 375, 376, 377, 378, 379, 380, 381, 382, 383, 384, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 397, 398, 399, 400, 401, 402, 403, -1, + 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, + 415, -1, 417, 418, 419, 420, 421, 422, 423, 424, + 425, -1, 427, 428, -1, -1, 431, 432, 433, 434, + 435, 436, 437, 438, 439, 440, 441, 442, -1, 444, + 445, 446, 447, 448, 449, 450, -1, 452, 453, 454, + 455, 456, 457, 458, -1, 460, 461, 462, 463, 464, + -1, -1, 467, -1, 469, 470, 471, 472, 473, 474, + 475, 476, 477, 478, 479, 480, 481, 482, 483, 484, + 485, 486, -1, -1, -1, -1, -1, -1, -1, 494, + 495, -1, -1, -1, -1, -1, -1, -1, 503, 5, + 6, 7, 8, 9, 10, 11, 12, 13, -1, 15, + 16, -1, -1, 19, 20, 21, 22, 23, 24, 25, + 26, 27, 28, 29, -1, 31, 32, 33, 34, 35, + 36, 37, 38, 39, 40, -1, 42, 43, 44, 45, + 46, -1, -1, -1, 50, 51, -1, -1, -1, -1, + 56, -1, -1, -1, -1, -1, -1, -1, -1, 65, + -1, 67, -1, 69, 70, 71, 72, -1, -1, 75, + 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, + 86, 87, -1, -1, -1, 91, 92, 93, 94, 95, + 96, 97, 98, -1, 100, 101, 102, -1, -1, -1, + -1, 107, -1, -1, 110, 111, -1, 113, 114, 115, + 116, 117, 118, 119, 120, 121, 122, 123, -1, 125, + 126, 127, 128, 129, 130, 131, 132, 133, 134, 135, + 136, -1, 138, 139, 140, 141, 142, -1, 144, -1, + 146, 147, 148, 149, 150, 151, 152, -1, 154, 155, + 156, 157, 158, 159, -1, 161, 162, -1, 164, 165, + 166, 167, 168, 169, 170, 171, 172, 173, 174, 175, + 176, 177, 178, 179, -1, 181, -1, 183, 184, 185, + 186, 187, -1, 189, 190, 191, -1, -1, 194, 195, + 196, 197, 198, -1, 200, 201, 202, -1, 204, 205, + -1, 207, 208, 209, 210, 211, 212, 213, 214, 215, + 216, 217, -1, 219, 220, 221, -1, 223, -1, 225, + 226, -1, 228, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, 243, 244, 245, + 246, -1, 248, 249, 250, 251, 252, 253, -1, 255, + 256, 257, -1, 259, 260, 261, 262, 263, -1, 265, + -1, 267, 268, 269, 270, 271, 272, 273, 274, 275, + 276, 277, 278, -1, 280, 281, 282, 283, 284, -1, + 286, 287, 288, 289, 290, 291, 292, 293, 294, 295, + 296, 297, 298, 299, 300, 301, 302, 303, 304, 305, + 306, 307, 308, 309, 310, 311, 312, 313, 314, 315, + 316, 317, 318, 319, 320, -1, 322, -1, -1, 325, + 326, 327, -1, -1, 330, 331, 332, 333, 334, 335, + 336, 337, 338, 339, 340, 341, -1, 343, 344, 345, + 346, 347, 348, 349, -1, 351, 352, 353, 354, 355, + 356, 357, 358, 359, 360, 361, 362, -1, 364, 365, + 366, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, 377, 378, 379, 380, 381, 382, 383, 384, 385, + 386, 387, 388, -1, 390, 391, 392, 393, 394, 395, + 396, 397, 398, 399, 400, 401, 402, 403, -1, 405, + 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, + -1, 417, 418, -1, 420, 421, 422, 423, 424, 425, + -1, 427, 428, -1, -1, 431, 432, 433, 434, 435, + 436, 437, 438, 439, 440, 441, 442, -1, 444, 445, + 446, 447, 448, 449, 450, -1, 452, 453, 454, 455, + 456, 457, 458, -1, 460, 461, 462, 463, 464, -1, + -1, 467, -1, -1, 470, 471, 472, 473, 474, 475, + 476, 477, 478, 479, 480, 481, 482, 483, 484, 485, + 486, -1, -1, -1, -1, -1, -1, -1, 494, 495, + -1, -1, -1, -1, -1, 501, 502, 503, 5, 6, + 7, 8, 9, 10, 11, 12, 13, -1, 15, 16, + -1, -1, 19, 20, 21, 22, 23, 24, 25, 26, + 27, 28, 29, -1, 31, 32, 33, 34, 35, 36, + 37, 38, 39, 40, -1, 42, 43, 44, 45, 46, + -1, -1, -1, 50, 51, -1, -1, -1, -1, 56, + -1, -1, -1, -1, -1, -1, -1, -1, 65, -1, + 67, -1, 69, 70, 71, 72, -1, -1, 75, 76, + 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, + 87, -1, -1, -1, 91, 92, 93, 94, 95, 96, + 97, 98, -1, 100, 101, 102, -1, -1, -1, -1, + 107, -1, -1, 110, 111, -1, 113, 114, 115, 116, + 117, 118, 119, 120, 121, 122, 123, -1, 125, 126, + 127, 128, 129, 130, 131, 132, 133, 134, 135, 136, + -1, 138, 139, 140, 141, 142, -1, 144, -1, 146, + 147, 148, 149, 150, 151, 152, -1, 154, 155, 156, + 157, 158, 159, -1, 161, 162, -1, 164, 165, 166, + 167, 168, 169, 170, 171, 172, 173, 174, 175, 176, + 177, 178, 179, -1, 181, -1, 183, 184, 185, 186, + 187, -1, 189, 190, 191, -1, -1, 194, 195, 196, + 197, 198, -1, 200, 201, 202, -1, 204, 205, -1, + 207, 208, 209, 210, 211, 212, 213, 214, 215, 216, + 217, -1, 219, 220, 221, -1, 223, -1, 225, 226, + -1, 228, 229, 230, 231, -1, 233, 234, -1, 236, + -1, 238, 239, 240, 241, 242, 243, 244, 245, 246, + -1, 248, 249, 250, 251, 252, 253, -1, 255, 256, + 257, -1, 259, 260, 261, 262, 263, -1, 265, -1, + 267, 268, 269, 270, 271, 272, 273, 274, 275, 276, + 277, 278, -1, 280, 281, 282, 283, 284, -1, 286, + 287, 288, 289, 290, 291, 292, 293, 294, 295, 296, + 297, 298, 299, 300, 301, 302, 303, 304, 305, 306, + 307, 308, 309, 310, 311, 312, 313, 314, 315, 316, + 317, 318, 319, 320, -1, 322, -1, -1, 325, 326, + 327, -1, -1, 330, 331, 332, 333, 334, 335, 336, + 337, 338, 339, 340, 341, -1, 343, 344, 345, 346, + 347, 348, 349, -1, 351, 352, 353, 354, 355, 356, + 357, 358, 359, 360, 361, 362, -1, 364, 365, 366, + 367, 368, 369, 370, 371, 372, 373, -1, 375, 376, + 377, 378, 379, 380, 381, 382, 383, 384, 385, 386, + 387, 388, -1, 390, 391, 392, 393, 394, 395, 396, + 397, 398, 399, 400, 401, 402, 403, -1, 405, 406, + 407, 408, 409, 410, 411, 412, 413, 414, 415, -1, + 417, 418, -1, 420, 421, 422, 423, 424, 425, -1, + 427, 428, -1, -1, 431, 432, 433, 434, 435, 436, + 437, 438, 439, 440, 441, 442, -1, 444, 445, 446, + 447, 448, 449, 450, -1, 452, 453, 454, 455, 456, + 457, 458, -1, 460, 461, 462, 463, 464, -1, -1, + 467, -1, -1, 470, 471, 472, 473, 474, 475, 476, + 477, 478, 479, 480, 481, 482, 483, 484, 485, 486, + -1, -1, -1, -1, -1, -1, -1, 494, 495, 496, + -1, -1, -1, -1, -1, -1, 503, 5, 6, 7, + 8, 9, 10, 11, 12, 13, -1, 15, 16, -1, + -1, 19, 20, 21, 22, 23, 24, 25, 26, 27, + 28, 29, -1, 31, 32, 33, 34, 35, 36, 37, + 38, 39, 40, -1, 42, 43, 44, 45, 46, -1, + -1, -1, 50, 51, -1, -1, -1, -1, 56, -1, + -1, -1, -1, -1, -1, -1, -1, 65, -1, 67, + -1, 69, 70, 71, 72, -1, -1, 75, 76, 77, + 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, + -1, -1, -1, 91, 92, 93, 94, 95, 96, 97, + 98, -1, 100, 101, 102, -1, -1, -1, -1, 107, + -1, -1, 110, 111, -1, 113, 114, 115, 116, 117, + 118, 119, 120, 121, 122, 123, -1, 125, 126, 127, + 128, 129, 130, 131, 132, 133, 134, 135, 136, -1, + 138, 139, 140, 141, 142, -1, 144, -1, 146, 147, + 148, 149, 150, 151, 152, -1, 154, 155, 156, 157, + 158, 159, -1, 161, 162, -1, 164, 165, 166, 167, + 168, 169, 170, 171, 172, 173, 174, 175, 176, 177, + 178, 179, 180, 181, -1, 183, 184, 185, 186, 187, + -1, 189, 190, 191, -1, -1, 194, 195, 196, 197, + 198, -1, 200, 201, 202, -1, 204, 205, -1, 207, + 208, 209, 210, 211, 212, 213, 214, 215, 216, 217, + -1, 219, 220, 221, -1, 223, -1, 225, 226, -1, + 228, 229, 230, 231, -1, 233, 234, -1, 236, -1, + 238, 239, 240, 241, 242, 243, 244, 245, 246, -1, + 248, 249, 250, 251, 252, 253, -1, 255, 256, 257, + -1, 259, 260, 261, 262, 263, -1, 265, -1, 267, + 268, 269, 270, 271, 272, 273, 274, 275, 276, 277, + 278, -1, 280, 281, 282, 283, 284, -1, 286, 287, + 288, 289, 290, 291, 292, 293, 294, 295, 296, 297, + 298, 299, 300, 301, 302, 303, 304, 305, 306, 307, + 308, 309, 310, 311, 312, 313, 314, 315, 316, 317, + 318, 319, 320, -1, 322, -1, -1, 325, 326, 327, + -1, -1, 330, 331, 332, 333, 334, 335, 336, 337, + 338, 339, 340, 341, -1, 343, 344, 345, 346, 347, + 348, 349, -1, 351, 352, 353, 354, 355, 356, 357, + 358, 359, 360, 361, 362, -1, 364, 365, 366, 367, + 368, 369, 370, 371, 372, 373, -1, 375, 376, 377, + 378, 379, 380, 381, 382, 383, 384, 385, 386, 387, + 388, -1, 390, 391, 392, 393, 394, 395, 396, 397, + 398, 399, 400, 401, 402, 403, -1, 405, 406, 407, + 408, 409, 410, 411, 412, 413, 414, 415, -1, 417, + 418, -1, 420, 421, 422, 423, 424, 425, -1, 427, + 428, -1, -1, 431, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 442, -1, 444, 445, 446, 447, + 448, 449, 450, -1, 452, 453, 454, 455, 456, 457, + 458, -1, 460, 461, 462, 463, 464, -1, -1, 467, + -1, -1, 470, 471, 472, 473, 474, 475, 476, 477, + 478, 479, 480, 481, 482, 483, 484, 485, 486, -1, + -1, -1, -1, -1, -1, -1, 494, 495, -1, -1, + -1, -1, -1, -1, -1, 503, 5, 6, 7, 8, + 9, 10, 11, 12, 13, -1, 15, 16, -1, -1, + 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, + 29, -1, 31, 32, 33, 34, 35, 36, 37, 38, + 39, 40, -1, 42, 43, 44, 45, 46, -1, -1, + -1, 50, 51, -1, -1, -1, -1, 56, -1, -1, + -1, -1, -1, -1, -1, -1, 65, -1, 67, -1, + 69, 70, 71, 72, -1, -1, 75, 76, 77, 78, + 79, 80, 81, 82, 83, 84, 85, 86, 87, -1, + -1, -1, 91, 92, 93, 94, 95, 96, 97, 98, + 99, 100, 101, 102, -1, -1, -1, -1, 107, -1, + -1, 110, 111, -1, 113, 114, 115, 116, 117, 118, + 119, 120, 121, 122, 123, -1, 125, 126, 127, 128, + 129, 130, 131, 132, 133, 134, 135, 136, -1, 138, + 139, 140, 141, 142, -1, 144, -1, 146, 147, 148, + 149, 150, 151, 152, -1, 154, 155, 156, 157, 158, + 159, -1, 161, 162, -1, 164, 165, 166, 167, 168, + 169, 170, 171, 172, 173, 174, 175, 176, 177, 178, + 179, -1, 181, -1, 183, 184, 185, 186, 187, -1, + 189, 190, 191, -1, -1, 194, 195, 196, 197, 198, + -1, 200, 201, 202, -1, 204, 205, -1, 207, 208, + 209, 210, 211, 212, 213, 214, 215, 216, 217, -1, + 219, 220, 221, -1, 223, -1, 225, 226, -1, 228, + 229, 230, 231, -1, 233, 234, -1, 236, -1, 238, + 239, 240, 241, 242, 243, 244, 245, 246, -1, 248, + 249, 250, 251, 252, 253, -1, 255, 256, 257, -1, + 259, 260, 261, 262, 263, -1, 265, -1, 267, 268, + 269, 270, 271, 272, 273, 274, 275, 276, 277, 278, + -1, 280, 281, 282, 283, 284, -1, 286, 287, 288, + 289, 290, 291, 292, 293, 294, 295, 296, 297, 298, + 299, 300, 301, 302, 303, 304, 305, 306, 307, 308, + 309, 310, 311, 312, 313, 314, 315, 316, 317, 318, + 319, 320, -1, 322, -1, -1, 325, 326, 327, -1, + -1, 330, 331, 332, 333, 334, 335, 336, 337, 338, + 339, 340, 341, -1, 343, 344, 345, 346, 347, 348, + 349, -1, 351, 352, 353, 354, 355, 356, 357, 358, + 359, 360, 361, 362, -1, 364, 365, 366, 367, 368, + 369, 370, 371, 372, 373, -1, 375, 376, 377, 378, + 379, 380, 381, 382, 383, 384, 385, 386, 387, 388, + -1, 390, 391, 392, 393, 394, 395, 396, 397, 398, + 399, 400, 401, 402, 403, -1, 405, 406, 407, 408, + 409, 410, 411, 412, 413, 414, 415, -1, 417, 418, + -1, 420, 421, 422, 423, 424, 425, -1, 427, 428, + -1, -1, 431, 432, 433, 434, 435, 436, 437, 438, + 439, 440, 441, 442, -1, 444, 445, 446, 447, 448, + 449, 450, -1, 452, 453, 454, 455, 456, 457, 458, + -1, 460, 461, 462, 463, 464, -1, -1, 467, -1, + -1, 470, 471, 472, 473, 474, 475, 476, 477, 478, + 479, 480, 481, 482, 483, 484, 485, 486, -1, -1, + -1, -1, -1, -1, -1, 494, 495, -1, -1, -1, + -1, -1, -1, -1, 503, 5, 6, 7, 8, 9, + 10, 11, 12, 13, -1, 15, 16, -1, -1, 19, + 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, + -1, 31, 32, 33, 34, 35, 36, 37, 38, 39, + 40, -1, 42, 43, 44, 45, 46, -1, -1, -1, + 50, 51, -1, -1, -1, -1, 56, -1, -1, -1, + -1, -1, -1, -1, -1, 65, -1, 67, -1, 69, + 70, 71, 72, -1, -1, 75, 76, 77, 78, 79, + 80, 81, 82, 83, 84, 85, 86, 87, -1, -1, + -1, 91, 92, 93, 94, 95, 96, 97, 98, -1, + 100, 101, 102, -1, -1, -1, -1, 107, -1, -1, + 110, 111, -1, 113, 114, 115, 116, 117, 118, 119, + 120, 121, 122, 123, -1, 125, 126, 127, 128, 129, + 130, 131, 132, 133, 134, 135, 136, -1, 138, 139, + 140, 141, 142, -1, 144, -1, 146, 147, 148, 149, + 150, 151, 152, -1, 154, 155, 156, 157, 158, 159, + -1, 161, 162, -1, 164, 165, 166, 167, 168, 169, + 170, 171, 172, 173, 174, 175, 176, 177, 178, 179, + -1, 181, -1, 183, 184, 185, 186, 187, -1, 189, + 190, 191, -1, -1, 194, 195, 196, 197, 198, -1, + 200, 201, 202, -1, 204, 205, -1, 207, 208, 209, + 210, 211, 212, 213, 214, 215, 216, 217, -1, 219, + 220, 221, -1, 223, -1, 225, 226, 227, 228, 229, + 230, 231, -1, 233, 234, -1, 236, -1, 238, 239, + 240, 241, 242, 243, 244, 245, 246, -1, 248, 249, + 250, 251, 252, 253, -1, 255, 256, 257, -1, 259, + 260, 261, 262, 263, -1, 265, -1, 267, 268, 269, + 270, 271, 272, 273, 274, 275, 276, 277, 278, -1, + 280, 281, 282, 283, 284, -1, 286, 287, 288, 289, + 290, 291, 292, 293, 294, 295, 296, 297, 298, 299, + 300, 301, 302, 303, 304, 305, 306, 307, 308, 309, + 310, 311, 312, 313, 314, 315, 316, 317, 318, 319, + 320, -1, 322, -1, -1, 325, 326, 327, -1, -1, + 330, 331, 332, 333, 334, 335, 336, 337, 338, 339, + 340, 341, -1, 343, 344, 345, 346, 347, 348, 349, + -1, 351, 352, 353, 354, 355, 356, 357, 358, 359, + 360, 361, 362, -1, 364, 365, 366, 367, 368, 369, + 370, 371, 372, 373, -1, 375, 376, 377, 378, 379, + 380, 381, 382, 383, 384, 385, 386, 387, 388, -1, + 390, 391, 392, 393, 394, 395, 396, 397, 398, 399, + 400, 401, 402, 403, -1, 405, 406, 407, 408, 409, + 410, 411, 412, 413, 414, 415, -1, 417, 418, -1, + 420, 421, 422, 423, 424, 425, -1, 427, 428, -1, + -1, 431, 432, 433, 434, 435, 436, 437, 438, 439, + 440, 441, 442, -1, 444, 445, 446, 447, 448, 449, + 450, -1, 452, 453, 454, 455, 456, 457, 458, -1, + 460, 461, 462, 463, 464, -1, -1, 467, -1, -1, + 470, 471, 472, 473, 474, 475, 476, 477, 478, 479, + 480, 481, 482, 483, 484, 485, 486, -1, -1, -1, + -1, -1, -1, -1, 494, 495, -1, -1, -1, -1, + -1, -1, -1, 503, 5, 6, 7, 8, 9, 10, + 11, 12, 13, -1, 15, 16, -1, -1, 19, 20, + 21, 22, 23, 24, 25, 26, 27, 28, 29, -1, + 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, + -1, 42, 43, 44, 45, 46, -1, -1, -1, 50, + 51, -1, -1, -1, -1, 56, -1, -1, -1, -1, + -1, -1, -1, -1, 65, -1, 67, -1, 69, 70, + 71, 72, -1, -1, 75, 76, 77, 78, 79, 80, + 81, 82, 83, 84, 85, 86, 87, -1, -1, -1, + 91, 92, 93, 94, 95, 96, 97, 98, -1, 100, + 101, 102, -1, -1, -1, -1, 107, -1, -1, 110, + 111, -1, 113, 114, 115, 116, 117, 118, 119, 120, + 121, 122, 123, -1, 125, 126, 127, 128, 129, 130, + 131, 132, 133, 134, 135, 136, -1, 138, 139, 140, + 141, 142, -1, 144, -1, 146, 147, 148, 149, 150, + 151, 152, -1, 154, 155, 156, 157, 158, 159, -1, + 161, 162, -1, 164, 165, 166, 167, 168, 169, 170, + 171, 172, 173, 174, 175, 176, 177, 178, 179, -1, + 181, -1, 183, 184, 185, 186, 187, -1, 189, 190, + 191, -1, -1, 194, 195, 196, 197, 198, -1, 200, + 201, 202, -1, 204, 205, -1, 207, 208, 209, 210, + 211, 212, 213, 214, 215, 216, 217, -1, 219, 220, + 221, -1, 223, -1, 225, 226, -1, 228, 229, 230, + 231, -1, 233, 234, -1, 236, -1, 238, 239, 240, + 241, 242, 243, 244, 245, 246, -1, 248, 249, 250, + 251, 252, 253, -1, 255, 256, 257, -1, 259, 260, + 261, 262, 263, -1, 265, -1, 267, 268, 269, 270, + 271, 272, 273, 274, 275, 276, 277, 278, -1, 280, + 281, 282, 283, 284, -1, 286, 287, 288, 289, 290, + 291, 292, 293, 294, 295, 296, 297, 298, 299, 300, + 301, 302, 303, 304, 305, 306, 307, 308, 309, 310, + 311, 312, 313, 314, 315, 316, 317, 318, 319, 320, + -1, 322, -1, -1, 325, 326, 327, -1, -1, 330, + 331, 332, 333, 334, 335, 336, 337, 338, 339, 340, + 341, -1, 343, 344, 345, 346, 347, 348, 349, -1, + 351, 352, 353, 354, 355, 356, 357, 358, 359, 360, + 361, 362, -1, 364, 365, 366, 367, 368, 369, 370, + 371, 372, 373, -1, 375, 376, 377, 378, 379, 380, + 381, 382, 383, 384, 385, 386, 387, 388, -1, 390, + 391, 392, 393, 394, 395, 396, 397, 398, 399, 400, + 401, 402, 403, -1, 405, 406, 407, 408, 409, 410, + 411, 412, 413, 414, 415, -1, 417, 418, -1, 420, + 421, 422, 423, 424, 425, -1, 427, 428, -1, -1, + 431, 432, 433, 434, 435, 436, 437, 438, 439, 440, + 441, 442, -1, 444, 445, 446, 447, 448, 449, 450, + -1, 452, 453, 454, 455, 456, 457, 458, 459, 460, + 461, 462, 463, 464, -1, -1, 467, -1, -1, 470, + 471, 472, 473, 474, 475, 476, 477, 478, 479, 480, + 481, 482, 483, 484, 485, 486, -1, -1, -1, -1, + -1, -1, -1, 494, 495, -1, -1, -1, -1, -1, + -1, -1, 503, 5, 6, 7, 8, 9, 10, 11, + 12, 13, -1, 15, 16, -1, -1, 19, 20, 21, + 22, 23, 24, 25, 26, 27, 28, 29, -1, 31, + 32, 33, 34, 35, 36, 37, 38, 39, 40, -1, + 42, 43, 44, 45, 46, -1, -1, -1, 50, 51, + -1, -1, -1, -1, 56, -1, -1, -1, -1, -1, + -1, -1, -1, 65, -1, 67, -1, 69, 70, 71, + 72, -1, -1, 75, 76, 77, 78, 79, 80, 81, + 82, 83, 84, 85, 86, 87, -1, -1, -1, 91, + 92, 93, 94, 95, 96, 97, 98, -1, 100, 101, + 102, -1, -1, -1, -1, 107, -1, -1, 110, 111, + -1, 113, 114, 115, 116, 117, 118, 119, 120, 121, + 122, 123, -1, 125, 126, 127, 128, 129, 130, 131, + 132, 133, 134, 135, 136, -1, 138, 139, 140, 141, + 142, -1, 144, -1, 146, 147, 148, 149, 150, 151, + 152, -1, 154, 155, 156, 157, 158, 159, -1, 161, + 162, 163, 164, 165, 166, 167, 168, 169, 170, 171, + 172, 173, 174, 175, 176, 177, 178, 179, -1, 181, + -1, 183, 184, 185, 186, 187, -1, 189, 190, 191, + -1, -1, 194, 195, 196, 197, 198, -1, 200, 201, + 202, -1, 204, 205, -1, 207, 208, 209, 210, 211, + 212, 213, 214, 215, 216, 217, -1, 219, 220, 221, + -1, 223, -1, 225, 226, -1, 228, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, 243, 244, 245, 246, -1, 248, 249, 250, 251, + 252, 253, -1, 255, 256, 257, -1, 259, 260, 261, + 262, 263, -1, 265, -1, 267, 268, 269, 270, 271, + 272, 273, 274, 275, 276, 277, 278, -1, 280, 281, + 282, 283, 284, -1, 286, 287, 288, 289, 290, 291, + 292, 293, 294, 295, 296, 297, 298, 299, 300, 301, + 302, 303, 304, 305, 306, 307, 308, 309, 310, 311, + 312, 313, 314, 315, 316, 317, 318, 319, 320, -1, + 322, -1, -1, 325, 326, 327, -1, -1, 330, 331, + 332, 333, 334, 335, 336, 337, 338, 339, 340, 341, + -1, 343, 344, 345, 346, 347, 348, 349, -1, 351, + 352, 353, 354, 355, 356, 357, 358, 359, 360, 361, + 362, -1, 364, 365, 366, 367, 368, 369, 370, 371, + 372, 373, -1, 375, 376, 377, 378, 379, 380, 381, + 382, 383, 384, 385, 386, 387, 388, -1, 390, 391, + 392, 393, 394, 395, 396, 397, 398, 399, 400, 401, + 402, 403, -1, 405, 406, 407, 408, 409, 410, 411, + 412, 413, 414, 415, -1, 417, 418, -1, 420, 421, + 422, 423, 424, 425, -1, 427, 428, -1, -1, 431, + 432, 433, 434, 435, 436, 437, 438, 439, 440, 441, + 442, -1, 444, 445, 446, 447, 448, 449, 450, -1, + 452, 453, 454, 455, 456, 457, 458, -1, 460, 461, + 462, 463, 464, -1, -1, 467, -1, -1, 470, 471, + 472, 473, 474, 475, 476, 477, 478, 479, 480, 481, + 482, 483, 484, 485, 486, -1, -1, -1, -1, -1, + -1, -1, 494, 495, -1, -1, -1, -1, -1, -1, + -1, 503, 5, 6, 7, 8, 9, 10, 11, 12, + 13, -1, 15, 16, -1, -1, 19, 20, 21, 22, + 23, 24, 25, 26, 27, 28, 29, -1, 31, 32, + 33, 34, 35, 36, 37, 38, 39, 40, -1, 42, + 43, 44, 45, 46, -1, -1, -1, 50, 51, -1, + -1, -1, -1, 56, -1, -1, -1, -1, -1, -1, + -1, -1, 65, -1, 67, -1, 69, 70, 71, 72, + -1, -1, 75, 76, 77, 78, 79, 80, 81, 82, + 83, 84, 85, 86, 87, -1, -1, -1, 91, 92, + 93, 94, 95, 96, 97, 98, -1, 100, 101, 102, + -1, -1, -1, -1, 107, -1, -1, 110, 111, -1, + 113, 114, 115, 116, 117, 118, 119, 120, 121, 122, + 123, -1, 125, 126, 127, 128, 129, 130, 131, 132, + 133, 134, 135, 136, -1, 138, 139, 140, 141, 142, + -1, 144, -1, 146, 147, 148, 149, 150, 151, 152, + -1, 154, 155, 156, 157, 158, 159, -1, 161, 162, + 163, 164, 165, 166, 167, 168, 169, 170, 171, 172, + 173, 174, 175, 176, 177, 178, 179, -1, 181, -1, + 183, 184, 185, 186, 187, -1, 189, 190, 191, -1, + -1, 194, 195, 196, 197, 198, -1, 200, 201, 202, + -1, 204, 205, -1, 207, 208, 209, 210, 211, 212, + 213, 214, 215, 216, 217, -1, 219, 220, 221, -1, + 223, -1, 225, 226, -1, 228, 229, 230, 231, -1, + 233, 234, -1, 236, -1, 238, 239, 240, 241, 242, + 243, 244, 245, 246, -1, 248, 249, 250, 251, 252, + 253, -1, 255, 256, 257, -1, 259, 260, 261, 262, + 263, -1, 265, -1, 267, 268, 269, 270, 271, 272, + 273, 274, 275, 276, 277, 278, -1, 280, 281, 282, + 283, 284, -1, 286, 287, 288, 289, 290, 291, 292, + 293, 294, 295, 296, 297, 298, 299, 300, 301, 302, + 303, 304, 305, 306, 307, 308, 309, 310, 311, 312, + 313, 314, 315, 316, 317, 318, 319, 320, -1, 322, + -1, -1, 325, 326, 327, -1, -1, 330, 331, 332, + 333, 334, 335, 336, 337, 338, 339, 340, 341, -1, + 343, 344, 345, 346, 347, 348, 349, -1, 351, 352, + 353, 354, 355, 356, 357, 358, 359, 360, 361, 362, + -1, 364, 365, 366, 367, 368, 369, 370, 371, 372, + 373, -1, 375, 376, 377, 378, 379, 380, 381, 382, + 383, 384, 385, 386, 387, 388, -1, 390, 391, 392, + 393, 394, 395, 396, 397, 398, 399, 400, 401, 402, + 403, -1, 405, 406, 407, 408, 409, 410, 411, 412, + 413, 414, 415, -1, 417, 418, -1, 420, 421, 422, + 423, 424, 425, -1, 427, 428, -1, -1, 431, 432, + 433, 434, 435, 436, 437, 438, 439, 440, 441, 442, + -1, 444, 445, 446, 447, 448, 449, 450, -1, 452, + 453, 454, 455, 456, 457, 458, -1, 460, 461, 462, + 463, 464, -1, -1, 467, -1, -1, 470, 471, 472, + 473, 474, 475, 476, 477, 478, 479, 480, 481, 482, + 483, 484, 485, 486, -1, -1, -1, -1, -1, -1, + -1, 494, 495, -1, -1, -1, -1, -1, -1, -1, + 503, 5, 6, 7, 8, 9, 10, 11, 12, 13, + -1, 15, 16, -1, -1, 19, 20, 21, 22, 23, + 24, 25, 26, 27, 28, 29, -1, 31, 32, 33, + 34, 35, 36, 37, 38, 39, 40, -1, 42, 43, + 44, 45, 46, -1, -1, -1, 50, 51, -1, -1, + -1, -1, 56, -1, -1, -1, -1, -1, -1, -1, + -1, 65, -1, 67, -1, 69, 70, 71, 72, -1, + -1, 75, 76, 77, 78, 79, 80, 81, 82, 83, + 84, 85, 86, 87, -1, -1, -1, 91, 92, 93, + 94, 95, 96, 97, 98, -1, 100, 101, 102, -1, + -1, -1, -1, 107, -1, -1, 110, 111, -1, 113, + 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, + -1, 125, 126, 127, 128, 129, 130, 131, 132, 133, + 134, 135, 136, -1, 138, 139, 140, 141, 142, -1, + 144, -1, 146, 147, 148, 149, 150, 151, 152, -1, + 154, 155, 156, 157, 158, 159, -1, 161, 162, 163, + 164, 165, 166, 167, 168, 169, 170, 171, 172, 173, + 174, 175, 176, 177, 178, 179, -1, 181, -1, 183, + 184, 185, 186, 187, -1, 189, 190, 191, -1, -1, + 194, 195, 196, 197, 198, -1, 200, 201, 202, -1, + 204, 205, -1, 207, 208, 209, 210, 211, 212, 213, + 214, 215, 216, 217, -1, 219, 220, 221, -1, 223, + -1, 225, 226, -1, 228, 229, 230, 231, -1, 233, + 234, -1, 236, -1, 238, 239, 240, 241, 242, 243, + 244, 245, 246, -1, 248, 249, 250, 251, 252, 253, + -1, 255, 256, 257, -1, 259, 260, 261, 262, 263, + -1, 265, -1, 267, 268, 269, 270, 271, 272, 273, + 274, 275, 276, 277, 278, -1, 280, 281, 282, 283, + 284, -1, 286, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, 297, 298, 299, 300, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, 312, 313, + 314, 315, 316, 317, 318, 319, 320, -1, 322, -1, + -1, 325, 326, 327, -1, -1, 330, 331, 332, 333, + 334, 335, 336, 337, 338, 339, 340, 341, -1, 343, + 344, 345, 346, 347, 348, 349, -1, 351, 352, 353, + 354, 355, 356, 357, 358, 359, 360, 361, 362, -1, + 364, 365, 366, 367, 368, 369, 370, 371, 372, 373, + -1, 375, 376, 377, 378, 379, 380, 381, 382, 383, + 384, 385, 386, 387, 388, -1, 390, 391, 392, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + -1, 405, 406, 407, 408, 409, 410, 411, 412, 413, + 414, 415, -1, 417, 418, -1, 420, 421, 422, 423, + 424, 425, -1, 427, 428, -1, -1, 431, 432, 433, + 434, 435, 436, 437, 438, 439, 440, 441, 442, -1, + 444, 445, 446, 447, 448, 449, 450, -1, 452, 453, + 454, 455, 456, 457, 458, -1, 460, 461, 462, 463, + 464, -1, -1, 467, -1, -1, 470, 471, 472, 473, + 474, 475, 476, 477, 478, 479, 480, 481, 482, 483, + 484, 485, 486, -1, -1, -1, -1, -1, -1, -1, + 494, 495, -1, -1, -1, -1, -1, -1, -1, 503, + 5, 6, 7, 8, 9, 10, 11, 12, 13, -1, + 15, 16, -1, -1, 19, 20, 21, 22, 23, 24, + 25, 26, 27, 28, 29, -1, 31, 32, 33, 34, + 35, 36, 37, 38, 39, 40, -1, 42, 43, 44, + 45, 46, -1, -1, -1, 50, 51, -1, -1, -1, + -1, 56, -1, -1, -1, -1, -1, -1, -1, -1, + 65, -1, 67, -1, 69, 70, 71, 72, -1, -1, + 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, + 85, 86, 87, -1, -1, -1, 91, 92, 93, 94, + 95, 96, 97, 98, -1, 100, 101, 102, -1, -1, + -1, -1, 107, -1, -1, 110, 111, -1, 113, 114, + 115, 116, 117, 118, 119, 120, 121, 122, 123, -1, + 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, + 135, 136, -1, 138, 139, 140, 141, 142, -1, 144, + -1, 146, 147, 148, 149, 150, 151, 152, -1, 154, + 155, 156, 157, 158, 159, -1, 161, 162, -1, 164, + 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, + 175, 176, 177, 178, 179, -1, 181, -1, 183, 184, + 185, 186, 187, -1, 189, 190, 191, -1, -1, 194, + 195, 196, 197, 198, -1, 200, 201, 202, -1, 204, + 205, -1, 207, 208, 209, 210, 211, 212, 213, 214, + 215, 216, 217, -1, 219, 220, 221, -1, 223, -1, + 225, 226, -1, 228, 229, 230, 231, -1, 233, 234, + -1, 236, -1, 238, 239, 240, 241, 242, 243, 244, + 245, 246, -1, 248, 249, 250, 251, 252, 253, -1, + 255, 256, 257, -1, 259, 260, 261, 262, 263, -1, + 265, -1, 267, 268, 269, 270, 271, 272, 273, 274, + 275, 276, 277, 278, -1, 280, 281, 282, 283, 284, + -1, 286, 287, 288, 289, 290, 291, 292, 293, 294, + 295, 296, 297, 298, 299, 300, 301, 302, 303, 304, + 305, 306, 307, 308, 309, 310, 311, 312, 313, 314, + 315, 316, 317, 318, 319, 320, -1, 322, -1, -1, + 325, 326, 327, -1, -1, 330, 331, 332, 333, 334, + 335, 336, 337, 338, 339, 340, 341, -1, 343, 344, + 345, 346, 347, 348, 349, -1, 351, 352, 353, 354, + 355, 356, 357, 358, 359, 360, 361, 362, -1, 364, + 365, 366, 367, 368, 369, 370, 371, 372, 373, -1, + 375, 376, 377, 378, 379, 380, 381, 382, 383, 384, + 385, 386, 387, 388, -1, 390, 391, 392, 393, 394, + 395, 396, 397, 398, 399, 400, 401, 402, 403, -1, + 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, + 415, -1, 417, 418, -1, 420, 421, 422, 423, 424, + 425, -1, 427, 428, -1, -1, 431, 432, 433, 434, + 435, 436, 437, 438, 439, 440, 441, 442, -1, 444, + 445, 446, 447, 448, 449, 450, -1, 452, 453, 454, + 455, 456, 457, 458, -1, 460, 461, 462, 463, 464, + -1, -1, 467, -1, -1, 470, 471, 472, 473, 474, + 475, 476, 477, 478, 479, 480, 481, 482, 483, 484, + 485, 486, -1, -1, -1, -1, -1, -1, -1, 494, + 495, -1, -1, -1, -1, -1, -1, -1, 503, 5, + 6, 7, 8, 9, 10, 11, 12, 13, -1, 15, + 16, -1, -1, 19, 20, 21, 22, 23, 24, 25, + 26, 27, 28, 29, -1, 31, 32, 33, 34, 35, + 36, 37, 38, 39, 40, -1, 42, 43, 44, 45, + 46, -1, -1, -1, 50, 51, -1, -1, -1, -1, + 56, -1, -1, -1, -1, -1, -1, -1, -1, 65, + -1, 67, -1, 69, 70, 71, 72, -1, -1, 75, + 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, + 86, 87, -1, -1, -1, 91, 92, 93, 94, 95, + 96, 97, 98, -1, 100, 101, 102, -1, -1, -1, + -1, 107, -1, -1, 110, 111, -1, 113, 114, 115, + 116, 117, 118, 119, 120, 121, 122, 123, -1, 125, + 126, 127, 128, 129, 130, 131, 132, 133, 134, 135, + 136, -1, 138, 139, 140, 141, 142, -1, 144, -1, + 146, 147, 148, 149, 150, 151, 152, -1, 154, 155, + 156, 157, 158, 159, -1, 161, 162, -1, 164, 165, + 166, 167, 168, 169, 170, 171, 172, 173, 174, 175, + 176, 177, 178, 179, -1, 181, -1, 183, 184, 185, + 186, 187, -1, 189, 190, 191, -1, -1, 194, 195, + 196, 197, 198, -1, 200, 201, 202, -1, 204, 205, + -1, 207, 208, 209, 210, 211, 212, 213, 214, 215, + 216, 217, -1, 219, 220, 221, -1, 223, -1, 225, + 226, -1, 228, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, 243, 244, 245, + 246, -1, 248, 249, 250, 251, 252, 253, -1, 255, + 256, 257, -1, 259, 260, 261, 262, 263, -1, 265, + -1, 267, 268, 269, 270, 271, 272, 273, 274, 275, + 276, 277, 278, -1, 280, 281, 282, 283, 284, -1, + 286, 287, 288, 289, 290, 291, 292, 293, 294, 295, + 296, 297, 298, 299, 300, 301, 302, 303, 304, 305, + 306, 307, 308, 309, 310, 311, 312, 313, 314, 315, + 316, 317, 318, 319, 320, -1, 322, -1, -1, 325, + 326, 327, -1, -1, 330, 331, 332, 333, 334, 335, + 336, 337, 338, 339, 340, 341, -1, 343, 344, 345, + 346, 347, 348, 349, -1, 351, 352, 353, 354, 355, + 356, 357, 358, 359, 360, 361, 362, -1, 364, 365, + 366, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, 377, 378, 379, 380, 381, 382, 383, 384, 385, + 386, 387, 388, -1, 390, 391, 392, 393, 394, 395, + 396, 397, 398, 399, 400, 401, 402, 403, -1, 405, + 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, + -1, 417, 418, -1, 420, 421, 422, 423, 424, 425, + -1, 427, 428, -1, -1, 431, 432, 433, 434, 435, + 436, 437, 438, 439, 440, 441, 442, -1, 444, 445, + 446, 447, 448, 449, 450, -1, 452, 453, 454, 455, + 456, 457, 458, -1, 460, 461, 462, 463, 464, -1, + -1, 467, -1, -1, 470, 471, 472, 473, 474, 475, + 476, 477, 478, 479, 480, 481, 482, 483, 484, 485, + 486, -1, -1, -1, -1, -1, -1, -1, 494, 495, + -1, -1, -1, -1, -1, -1, -1, 503, 5, 6, + 7, 8, 9, 10, 11, 12, 13, -1, 15, 16, + -1, -1, 19, 20, 21, 22, 23, 24, 25, 26, + 27, 28, 29, -1, 31, 32, 33, 34, 35, 36, + 37, 38, 39, 40, -1, 42, 43, 44, 45, 46, + -1, -1, -1, 50, 51, -1, -1, -1, -1, 56, + -1, -1, -1, -1, -1, -1, -1, -1, 65, -1, + 67, -1, 69, 70, 71, 72, -1, -1, 75, 76, + 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, + 87, -1, -1, -1, 91, 92, 93, 94, 95, 96, + 97, 98, -1, 100, 101, 102, -1, -1, -1, -1, + 107, -1, -1, 110, 111, -1, 113, 114, 115, 116, + 117, 118, 119, 120, 121, 122, 123, -1, 125, 126, + 127, 128, 129, 130, 131, 132, 133, 134, 135, 136, + -1, 138, 139, 140, 141, 142, -1, 144, -1, 146, + 147, 148, 149, 150, 151, 152, -1, 154, 155, 156, + 157, 158, 159, -1, 161, 162, -1, 164, 165, 166, + 167, 168, 169, 170, 171, 172, 173, 174, 175, 176, + 177, 178, 179, -1, 181, -1, 183, 184, 185, 186, + 187, -1, 189, 190, 191, -1, -1, 194, 195, 196, + 197, 198, -1, 200, 201, 202, -1, 204, 205, -1, + 207, 208, 209, 210, 211, 212, 213, 214, 215, 216, + 217, -1, 219, 220, 221, -1, 223, -1, 225, 226, + -1, 228, 229, 230, 231, -1, 233, 234, -1, 236, + -1, 238, 239, 240, 241, 242, 243, 244, 245, 246, + -1, 248, 249, 250, 251, 252, 253, -1, 255, 256, + 257, -1, 259, 260, 261, 262, 263, -1, 265, -1, + 267, 268, 269, 270, 271, 272, 273, 274, 275, 276, + 277, 278, -1, 280, 281, 282, 283, 284, -1, 286, + 287, 288, 289, 290, 291, 292, 293, 294, 295, 296, + 297, 298, 299, 300, 301, 302, 303, 304, 305, 306, + 307, 308, 309, 310, 311, 312, 313, 314, 315, 316, + 317, 318, 319, 320, -1, 322, -1, -1, 325, 326, + 327, -1, -1, 330, 331, 332, 333, 334, 335, 336, + 337, 338, 339, 340, 341, -1, 343, 344, 345, 346, + 347, 348, 349, -1, 351, 352, 353, 354, 355, 356, + 357, 358, 359, 360, 361, 362, -1, 364, 365, 366, + 367, 368, 369, 370, 371, 372, 373, -1, 375, 376, + 377, 378, 379, 380, 381, 382, 383, 384, 385, 386, + 387, 388, -1, 390, 391, 392, 393, 394, 395, 396, + 397, 398, 399, 400, 401, 402, 403, -1, 405, 406, + 407, 408, 409, 410, 411, 412, 413, 414, 415, -1, + 417, 418, -1, 420, 421, 422, 423, 424, 425, -1, + 427, 428, -1, -1, 431, 432, 433, 434, 435, 436, + 437, 438, 439, 440, 441, 442, -1, 444, 445, 446, + 447, 448, 449, 450, -1, 452, 453, 454, 455, 456, + 457, 458, -1, 460, 461, 462, 463, 464, -1, -1, + 467, -1, -1, 470, 471, 472, 473, 474, 475, 476, + 477, 478, 479, 480, 481, 482, 483, 484, 485, 486, + -1, -1, -1, -1, -1, -1, -1, 494, 495, -1, + -1, -1, -1, -1, -1, -1, 503, 5, 6, 7, + 8, 9, 10, 11, 12, 13, -1, 15, 16, -1, + -1, 19, 20, 21, 22, 23, 24, 25, 26, 27, + 28, 29, -1, 31, 32, 33, 34, 35, 36, 37, + 38, 39, 40, -1, 42, 43, 44, 45, 46, -1, + -1, -1, 50, 51, -1, -1, -1, -1, 56, -1, + -1, -1, -1, -1, -1, -1, -1, 65, -1, 67, + -1, 69, 70, 71, 72, -1, -1, 75, 76, 77, + 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, + -1, -1, -1, 91, 92, 93, 94, 95, 96, 97, + 98, -1, 100, 101, 102, -1, -1, -1, -1, 107, + -1, -1, 110, 111, -1, 113, 114, 115, 116, 117, + 118, 119, 120, 121, 122, 123, -1, 125, 126, 127, + 128, 129, 130, 131, 132, 133, 134, 135, 136, -1, + 138, 139, 140, 141, 142, -1, 144, -1, 146, 147, + 148, 149, 150, 151, 152, -1, 154, 155, 156, 157, + 158, 159, -1, 161, 162, -1, 164, 165, 166, 167, + 168, 169, 170, 171, 172, 173, 174, 175, 176, 177, + 178, 179, -1, 181, -1, 183, 184, 185, 186, 187, + -1, 189, 190, 191, -1, -1, 194, 195, 196, 197, + 198, -1, 200, 201, 202, -1, 204, 205, -1, 207, + 208, 209, 210, 211, 212, 213, 214, 215, 216, 217, + -1, 219, 220, 221, -1, 223, -1, 225, 226, -1, + 228, 229, 230, 231, -1, 233, 234, -1, 236, -1, + 238, 239, 240, 241, 242, 243, 244, 245, 246, -1, + 248, 249, 250, 251, 252, 253, -1, 255, 256, 257, + -1, 259, 260, 261, 262, 263, -1, 265, -1, 267, + 268, 269, 270, 271, 272, 273, 274, 275, 276, 277, + 278, -1, 280, 281, 282, 283, 284, -1, 286, 287, + 288, 289, 290, 291, 292, 293, 294, 295, 296, 297, + 298, 299, 300, 301, 302, 303, 304, 305, 306, 307, + 308, -1, 310, 311, 312, 313, 314, 315, 316, 317, + 318, 319, 320, -1, 322, -1, -1, 325, 326, 327, + -1, -1, 330, 331, 332, 333, 334, 335, 336, 337, + 338, 339, 340, 341, -1, 343, 344, 345, 346, 347, + 348, 349, -1, 351, 352, 353, 354, 355, 356, 357, + 358, 359, 360, 361, 362, -1, 364, 365, 366, 367, + 368, 369, 370, 371, 372, 373, -1, 375, 376, 377, + 378, 379, 380, 381, 382, 383, 384, 385, 386, 387, + 388, -1, 390, 391, 392, 393, 394, 395, 396, 397, + 398, 399, 400, 401, 402, 403, -1, 405, 406, 407, + 408, 409, 410, 411, 412, 413, 414, 415, -1, 417, + 418, -1, 420, 421, 422, 423, 424, 425, -1, 427, + 428, -1, -1, 431, 432, 433, 434, 435, 436, 437, + 438, 439, 440, 441, 442, -1, -1, 445, 446, 447, + 448, 449, 450, -1, 452, 453, 454, 455, 456, 457, + 458, -1, 460, 461, 462, 463, 464, -1, -1, 467, + -1, -1, 470, 471, 472, 473, 474, 475, 476, 477, + 478, 479, 480, 481, 482, 483, 484, 485, 486, -1, + -1, -1, -1, -1, -1, -1, 494, 495, -1, -1, + -1, -1, -1, -1, -1, 503, 5, 6, 7, 8, + 9, 10, 11, 12, 13, -1, 15, 16, -1, -1, + 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, + 29, -1, 31, 32, 33, 34, 35, 36, 37, 38, + 39, 40, -1, 42, 43, 44, 45, 46, -1, -1, + -1, 50, 51, -1, -1, -1, -1, 56, -1, -1, + -1, -1, -1, -1, -1, -1, 65, -1, 67, -1, + 69, 70, 71, 72, -1, -1, 75, 76, 77, 78, + 79, 80, 81, 82, 83, 84, 85, 86, 87, -1, + -1, -1, 91, 92, 93, 94, 95, 96, 97, 98, + -1, 100, 101, 102, -1, -1, -1, -1, 107, -1, + -1, 110, 111, -1, 113, 114, 115, 116, 117, 118, + 119, 120, 121, 122, 123, -1, 125, 126, 127, 128, + 129, 130, 131, 132, 133, 134, 135, 136, -1, 138, + 139, 140, 141, 142, -1, 144, -1, 146, 147, 148, + 149, 150, 151, 152, -1, 154, 155, 156, 157, 158, + 159, -1, 161, 162, 163, 164, 165, 166, 167, 168, + 169, 170, 171, 172, 173, 174, 175, 176, 177, 178, + 179, -1, 181, -1, 183, 184, 185, 186, 187, -1, + 189, 190, 191, -1, -1, 194, 195, 196, 197, 198, + -1, 200, 201, 202, -1, 204, 205, -1, 207, 208, + 209, 210, 211, 212, 213, 214, 215, 216, 217, -1, + 219, 220, 221, -1, 223, -1, 225, 226, -1, 228, + 229, 230, 231, -1, 233, 234, -1, 236, -1, 238, + 239, 240, 241, 242, -1, 244, 245, 246, -1, 248, + 249, 250, 251, 252, 253, -1, 255, 256, 257, -1, + 259, 260, 261, 262, 263, -1, 265, -1, 267, 268, + 269, 270, 271, 272, 273, 274, 275, 276, 277, 278, + -1, 280, 281, 282, 283, -1, -1, 286, 287, 288, + 289, 290, 291, 292, 293, 294, 295, 296, 297, 298, + 299, 300, 301, 302, 303, 304, 305, 306, 307, 308, + -1, 310, 311, 312, 313, 314, 315, 316, 317, 318, + 319, 320, -1, 322, -1, -1, 325, 326, 327, -1, + -1, 330, 331, 332, 333, 334, 335, 336, 337, 338, + 339, 340, 341, -1, 343, 344, 345, 346, 347, 348, + 349, -1, 351, 352, 353, 354, 355, 356, 357, 358, + 359, 360, 361, 362, -1, 364, 365, 366, 367, 368, + 369, 370, 371, 372, 373, -1, 375, 376, 377, 378, + 379, 380, 381, 382, 383, 384, 385, 386, 387, 388, + -1, 390, 391, 392, 393, 394, 395, 396, 397, 398, + 399, -1, 401, 402, 403, -1, 405, 406, 407, 408, + 409, 410, 411, 412, 413, 414, 415, -1, 417, 418, + -1, 420, 421, 422, 423, 424, 425, -1, 427, 428, + -1, -1, 431, 432, 433, 434, 435, 436, 437, 438, + 439, 440, 441, 442, -1, 444, 445, 446, 447, 448, + 449, 450, -1, 452, 453, 454, 455, 456, 457, 458, + -1, 460, 461, 462, 463, 464, -1, -1, 467, -1, + -1, 470, 471, 472, 473, 474, 475, 476, 477, 478, + 479, 480, 481, 482, 483, 484, 485, 486, -1, -1, + -1, -1, -1, -1, -1, 494, 495, -1, -1, -1, + -1, -1, -1, -1, 503, 5, 6, 7, 8, 9, + 10, 11, 12, 13, -1, 15, 16, -1, -1, 19, + 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, + -1, 31, 32, 33, 34, 35, 36, 37, 38, 39, + 40, -1, 42, 43, 44, 45, 46, -1, -1, -1, + 50, 51, -1, -1, -1, -1, 56, -1, -1, -1, + -1, -1, -1, -1, -1, 65, -1, 67, -1, 69, + 70, 71, 72, -1, -1, 75, 76, 77, 78, 79, + 80, 81, 82, 83, 84, -1, 86, 87, -1, -1, + -1, 91, 92, 93, 94, 95, 96, 97, 98, -1, + 100, 101, 102, -1, -1, -1, -1, 107, -1, -1, + 110, 111, -1, 113, 114, 115, 116, 117, 118, 119, + 120, 121, 122, 123, -1, 125, 126, 127, 128, 129, + 130, 131, 132, 133, 134, 135, 136, -1, 138, 139, + 140, 141, 142, -1, 144, -1, 146, 147, 148, 149, + 150, 151, 152, -1, 154, 155, 156, 157, 158, 159, + -1, 161, 162, -1, 164, 165, 166, 167, 168, 169, + 170, 171, 172, 173, 174, 175, 176, 177, 178, 179, + -1, 181, -1, 183, 184, 185, 186, 187, -1, 189, + 190, 191, -1, -1, 194, 195, 196, 197, 198, -1, + 200, 201, 202, -1, 204, 205, -1, 207, 208, 209, + 210, 211, 212, 213, 214, 215, 216, 217, -1, 219, + 220, 221, -1, 223, -1, 225, 226, -1, 228, 229, + 230, 231, -1, 233, 234, -1, 236, -1, 238, 239, + 240, 241, 242, 243, 244, 245, 246, -1, 248, 249, + 250, 251, 252, 253, -1, 255, 256, 257, -1, 259, + 260, 261, 262, 263, -1, 265, -1, 267, 268, 269, + 270, 271, 272, 273, 274, 275, 276, 277, 278, -1, + 280, 281, 282, 283, 284, -1, 286, 287, 288, 289, + 290, 291, 292, 293, 294, 295, 296, 297, 298, 299, + 300, 301, 302, 303, 304, 305, 306, 307, 308, -1, + 310, 311, 312, 313, 314, 315, 316, 317, 318, 319, + 320, -1, 322, -1, -1, 325, 326, 327, -1, -1, + 330, 331, 332, 333, 334, 335, 336, 337, 338, 339, + 340, 341, -1, 343, 344, 345, 346, 347, 348, 349, + -1, 351, 352, 353, 354, 355, 356, 357, 358, 359, + 360, 361, 362, -1, 364, 365, 366, 367, 368, 369, + 370, 371, 372, 373, -1, 375, 376, 377, 378, 379, + 380, 381, 382, 383, 384, 385, 386, 387, 388, -1, + 390, 391, 392, 393, 394, 395, 396, 397, 398, 399, + 400, 401, 402, 403, -1, 405, 406, 407, 408, 409, + 410, 411, 412, 413, 414, 415, -1, 417, 418, -1, + 420, 421, 422, 423, 424, 425, -1, 427, 428, -1, + -1, 431, 432, 433, 434, 435, 436, 437, 438, 439, + 440, 441, 442, -1, -1, 445, 446, 447, 448, 449, + 450, -1, 452, 453, 454, 455, 456, 457, 458, -1, + 460, 461, 462, 463, 464, -1, -1, 467, -1, -1, + 470, 471, 472, 473, 474, 475, 476, 477, 478, 479, + 480, 481, 482, 483, 484, 485, 486, -1, -1, -1, + 5, 6, 7, 8, 9, 10, 11, 12, 13, -1, + 15, 16, -1, 503, 19, 20, 21, 22, 23, 24, + 25, 26, 27, 28, 29, -1, 31, 32, 33, 34, + 35, 36, 37, 38, 39, 40, -1, 42, 43, 44, + 45, 46, -1, -1, -1, 50, 51, -1, -1, -1, + -1, 56, -1, -1, -1, -1, -1, -1, -1, -1, + 65, -1, 67, -1, 69, 70, 71, 72, -1, -1, + 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, + -1, 86, 87, -1, -1, -1, 91, 92, 93, 94, + 95, 96, 97, 98, -1, 100, 101, 102, -1, -1, + -1, -1, 107, -1, -1, 110, 111, -1, 113, 114, + 115, 116, 117, 118, 119, 120, 121, 122, 123, -1, + 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, + 135, 136, -1, 138, 139, 140, 141, 142, -1, 144, + -1, 146, 147, 148, 149, 150, 151, 152, -1, 154, + 155, 156, 157, 158, 159, -1, 161, 162, -1, 164, + 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, + 175, 176, 177, 178, 179, -1, 181, -1, 183, 184, + 185, 186, 187, -1, 189, 190, 191, -1, -1, 194, + 195, 196, 197, 198, -1, 200, 201, 202, -1, 204, + 205, -1, 207, 208, 209, 210, 211, 212, 213, 214, + 215, 216, 217, -1, 219, 220, 221, -1, 223, -1, + 225, 226, -1, 228, 229, 230, 231, -1, 233, 234, + -1, 236, -1, 238, 239, 240, 241, 242, 243, 244, + 245, 246, -1, 248, 249, 250, 251, 252, 253, -1, + 255, 256, 257, -1, 259, 260, 261, 262, 263, -1, + 265, -1, 267, 268, 269, 270, 271, 272, 273, 274, + 275, 276, 277, 278, -1, 280, 281, 282, 283, 284, + -1, 286, 287, 288, 289, 290, 291, 292, 293, 294, + 295, 296, 297, 298, 299, 300, 301, 302, 303, 304, + 305, 306, 307, 308, -1, 310, 311, 312, 313, 314, + 315, 316, 317, 318, 319, 320, -1, 322, -1, -1, + 325, 326, 327, -1, -1, 330, 331, 332, 333, 334, + 335, 336, 337, 338, 339, 340, 341, -1, 343, 344, + 345, 346, 347, 348, 349, -1, 351, 352, 353, 354, + 355, 356, 357, 358, 359, 360, 361, 362, -1, 364, + 365, 366, 367, 368, 369, 370, 371, 372, 373, -1, + 375, 376, 377, 378, 379, 380, 381, 382, 383, 384, + 385, 386, 387, 388, -1, 390, 391, 392, 393, 394, + 395, 396, 397, 398, 399, 400, 401, 402, 403, -1, + 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, + 415, -1, 417, 418, -1, 420, 421, 422, 423, 424, + 425, -1, 427, 428, -1, -1, 431, 432, 433, 434, + 435, 436, 437, 438, 439, 440, 441, 442, -1, -1, + 445, 446, 447, 448, 449, 450, -1, 452, 453, 454, + 455, 456, 457, 458, -1, 460, 461, 462, 463, 464, + -1, -1, 467, -1, -1, 470, 471, 472, 473, 474, + 475, 476, 477, 478, 479, 480, 481, 482, 483, 484, + 485, 486, -1, -1, -1, 5, 6, 7, 8, 9, + 10, 11, 12, 13, -1, 15, 16, -1, 503, 19, + 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, + -1, 31, 32, 33, 34, 35, 36, 37, 38, 39, + 40, -1, 42, 43, 44, 45, 46, -1, -1, -1, + 50, 51, -1, -1, -1, -1, 56, -1, -1, -1, + -1, -1, -1, -1, -1, 65, -1, 67, -1, 69, + 70, 71, 72, -1, -1, 75, 76, 77, 78, 79, + 80, 81, 82, 83, 84, 85, 86, 87, -1, -1, + -1, 91, 92, 93, 94, 95, 96, 97, 98, -1, + 100, 101, 102, -1, -1, -1, -1, 107, -1, -1, + 110, 111, -1, 113, 114, 115, 116, 117, 118, -1, + 120, 121, 122, 123, -1, 125, 126, 127, 128, 129, + 130, 131, 132, 133, 134, 135, 136, -1, 138, 139, + 140, 141, 142, -1, 144, -1, 146, 147, 148, 149, + 150, 151, 152, -1, 154, 155, 156, 157, 158, 159, + -1, 161, 162, -1, 164, 165, 166, 167, 168, 169, + 170, 171, 172, 173, 174, 175, 176, 177, 178, 179, + -1, 181, -1, 183, 184, 185, 186, 187, -1, 189, + 190, 191, -1, -1, 194, 195, 196, 197, 198, -1, + 200, 201, 202, -1, 204, -1, -1, 207, 208, 209, + 210, 211, 212, 213, 214, 215, 216, 217, -1, 219, + 220, 221, -1, 223, -1, 225, 226, -1, 228, 229, + 230, 231, -1, 233, 234, -1, 236, -1, 238, 239, + 240, 241, 242, -1, 244, 245, 246, -1, 248, 249, + 250, 251, 252, 253, -1, 255, 256, 257, -1, 259, + 260, 261, 262, 263, -1, 265, -1, 267, 268, 269, + 270, 271, 272, 273, 274, 275, 276, 277, 278, -1, + 280, 281, 282, 283, -1, -1, 286, 287, 288, 289, + 290, 291, 292, 293, 294, 295, 296, 297, 298, 299, + 300, 301, 302, 303, 304, 305, 306, 307, 308, -1, + 310, 311, 312, 313, 314, 315, 316, 317, 318, 319, + 320, -1, 322, -1, -1, 325, 326, 327, -1, -1, + 330, 331, 332, 333, 334, 335, 336, 337, 338, 339, + 340, 341, -1, 343, 344, 345, 346, 347, 348, 349, + -1, 351, 352, 353, 354, 355, 356, 357, 358, 359, + 360, 361, 362, -1, 364, 365, 366, 367, 368, 369, + 370, 371, 372, 373, -1, 375, 376, 377, 378, 379, + 380, 381, 382, 383, 384, 385, 386, 387, 388, -1, + 390, 391, 392, 393, 394, 395, 396, 397, 398, 399, + -1, 401, 402, 403, -1, 405, 406, 407, 408, 409, + 410, 411, 412, 413, 414, 415, -1, 417, 418, -1, + 420, 421, 422, 423, 424, 425, -1, 427, 428, -1, + -1, 431, 432, 433, 434, 435, 436, 437, 438, 439, + 440, 441, 442, -1, 444, 445, 446, 447, 448, 449, + 450, -1, 452, 453, 454, 455, 456, 457, 458, -1, + 460, 461, 462, 463, 464, -1, -1, 467, -1, -1, + 470, 471, 472, 473, 474, 475, 476, 477, 478, 479, + 480, 481, 482, 483, 484, 485, 486, -1, -1, -1, + -1, -1, -1, -1, 494, 495, -1, -1, -1, -1, + -1, -1, -1, 503, 5, 6, 7, 8, 9, 10, + 11, 12, 13, -1, 15, 16, -1, -1, 19, 20, + 21, 22, 23, 24, 25, 26, 27, 28, 29, -1, + 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, + -1, 42, 43, 44, 45, 46, -1, -1, -1, 50, + 51, -1, -1, -1, -1, 56, -1, -1, -1, -1, + -1, -1, -1, -1, 65, -1, 67, -1, 69, 70, + 71, 72, -1, -1, 75, 76, 77, 78, 79, 80, + 81, 82, 83, 84, 85, 86, 87, -1, -1, -1, + 91, 92, 93, 94, 95, 96, 97, 98, -1, 100, + 101, 102, -1, -1, -1, -1, 107, -1, -1, 110, + 111, -1, 113, 114, 115, 116, 117, 118, -1, 120, + 121, 122, 123, -1, 125, 126, 127, 128, 129, 130, + 131, 132, 133, 134, 135, 136, -1, 138, 139, 140, + 141, 142, -1, 144, -1, 146, 147, 148, 149, 150, + 151, 152, -1, 154, 155, 156, 157, 158, 159, -1, + 161, 162, -1, 164, 165, 166, 167, 168, 169, 170, + 171, 172, 173, 174, 175, 176, 177, 178, 179, -1, + 181, -1, 183, 184, 185, 186, 187, -1, 189, 190, + 191, -1, -1, 194, 195, 196, 197, 198, -1, 200, + 201, 202, -1, 204, -1, -1, 207, 208, 209, 210, + 211, 212, 213, 214, 215, 216, 217, -1, 219, 220, + 221, -1, 223, -1, 225, 226, -1, 228, 229, 230, + 231, -1, 233, 234, -1, 236, -1, 238, 239, 240, + 241, 242, -1, 244, 245, 246, -1, 248, 249, 250, + 251, 252, 253, -1, 255, 256, 257, -1, 259, 260, + 261, 262, 263, -1, 265, -1, 267, 268, 269, 270, + 271, 272, 273, 274, 275, 276, 277, 278, -1, 280, + 281, 282, 283, -1, -1, 286, 287, 288, 289, 290, + 291, 292, 293, 294, 295, 296, 297, 298, 299, 300, + 301, 302, 303, 304, 305, 306, 307, 308, -1, 310, + 311, 312, 313, 314, 315, 316, 317, 318, 319, 320, + -1, 322, -1, -1, 325, 326, 327, -1, -1, 330, + 331, 332, 333, 334, 335, 336, 337, 338, 339, 340, + 341, -1, 343, 344, 345, 346, 347, 348, 349, -1, + 351, 352, 353, 354, 355, 356, 357, 358, 359, 360, + 361, 362, -1, 364, 365, 366, 367, 368, 369, 370, + 371, 372, 373, -1, 375, 376, 377, 378, 379, 380, + 381, 382, 383, 384, 385, 386, 387, 388, -1, 390, + 391, 392, 393, 394, 395, 396, 397, 398, 399, -1, + 401, 402, 403, -1, 405, 406, 407, 408, 409, 410, + 411, 412, 413, 414, 415, -1, 417, 418, -1, 420, + 421, 422, 423, 424, 425, -1, 427, 428, -1, -1, + 431, 432, 433, 434, 435, 436, 437, 438, 439, 440, + 441, 442, -1, -1, 445, 446, 447, 448, 449, 450, + -1, 452, 453, 454, 455, 456, 457, 458, -1, 460, + 461, 462, 463, 464, -1, -1, 467, -1, -1, 470, + 471, 472, 473, 474, 475, 476, 477, 478, 479, 480, + 481, 482, 483, 484, 485, 486, -1, -1, -1, -1, + -1, -1, -1, 494, 495, -1, -1, -1, -1, -1, + -1, -1, 503, 5, 6, 7, 8, 9, 10, 11, + 12, 13, -1, 15, 16, -1, -1, 19, 20, 21, + 22, 23, 24, 25, 26, 27, 28, 29, -1, 31, + 32, 33, 34, 35, 36, 37, 38, 39, 40, -1, + 42, 43, 44, 45, 46, -1, -1, -1, 50, 51, + -1, -1, -1, -1, 56, -1, -1, -1, -1, -1, + -1, -1, -1, 65, -1, 67, -1, 69, 70, 71, + -1, -1, -1, -1, -1, -1, -1, 79, 80, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 91, + 92, 93, 94, 95, 96, 97, 98, -1, 100, 101, + 102, -1, -1, -1, -1, -1, -1, -1, 110, 111, + -1, 113, 114, 115, 116, 117, 118, 119, 120, 121, + 122, 123, -1, 125, 126, 127, 128, 129, -1, 131, + 132, 133, 134, 135, 136, -1, 138, 139, 140, 141, + 142, -1, 144, -1, 146, 147, 148, 149, 150, 151, + 152, -1, 154, 155, 156, 157, 158, 159, -1, 161, + 162, -1, 164, 165, 166, 167, 168, 169, 170, 171, + 172, 173, 174, 175, 176, 177, 178, 179, -1, 181, + -1, 183, 184, 185, 186, 187, -1, 189, 190, 191, + -1, -1, 194, 195, 196, 197, 198, -1, 200, 201, + 202, -1, 204, 205, -1, 207, 208, 209, 210, 211, + 212, 213, 214, 215, -1, 217, -1, 219, 220, 221, + -1, 223, -1, 225, 226, -1, 228, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, 243, 244, 245, 246, -1, 248, 249, 250, 251, + 252, 253, -1, 255, 256, 257, -1, 259, 260, 261, + -1, 263, -1, 265, -1, 267, 268, 269, 270, 271, + 272, 273, 274, 275, 276, 277, 278, -1, 280, 281, + 282, 283, 284, -1, 286, 287, 288, 289, 290, 291, + 292, 293, 294, 295, 296, 297, 298, 299, 300, 301, + 302, 303, 304, 305, 306, 307, 308, -1, 310, 311, + 312, 313, -1, 315, 316, 317, 318, 319, 320, -1, + 322, -1, 324, 325, 326, 327, -1, -1, 330, 331, + 332, 333, 334, 335, 336, 337, 338, 339, 340, 341, + -1, 343, 344, 345, 346, 347, 348, 349, -1, 351, + 352, 353, 354, 355, 356, 357, 358, 359, 360, 361, + 362, -1, 364, 365, 366, 367, 368, 369, 370, 371, + 372, 373, -1, 375, 376, 377, 378, 379, 380, 381, + 382, 383, 384, 385, 386, 387, 388, 389, 390, 391, + 392, 393, 394, 395, 396, 397, 398, 399, 400, 401, + 402, 403, -1, 405, 406, 407, 408, 409, 410, 411, + 412, 413, 414, 415, -1, 417, 418, 419, 420, 421, + 422, 423, 424, 425, -1, 427, 428, -1, -1, 431, + 432, 433, 434, -1, 436, 437, 438, 439, 440, 441, + 442, -1, -1, 445, 446, 447, 448, 449, 450, -1, + 452, 453, 454, 455, 456, 457, 458, -1, 460, 461, + 462, 463, 464, -1, -1, 467, -1, 469, 470, 471, + 472, 473, 474, 475, 476, 477, 478, 479, 480, 481, + 482, 483, 484, 485, 486, -1, -1, -1, 5, 6, + 7, 8, 9, 10, 11, 12, 13, -1, 15, 16, + -1, 503, 19, 20, 21, 22, 23, 24, 25, 26, + 27, 28, 29, -1, 31, 32, 33, 34, 35, 36, + 37, 38, 39, 40, -1, 42, 43, 44, 45, 46, + -1, -1, -1, 50, 51, -1, -1, -1, -1, 56, + -1, -1, -1, -1, -1, -1, -1, -1, 65, -1, + 67, -1, 69, 70, 71, -1, -1, -1, -1, -1, + -1, -1, 79, 80, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 91, 92, 93, 94, 95, 96, + 97, 98, -1, 100, 101, 102, -1, -1, -1, -1, + -1, -1, -1, 110, 111, -1, 113, 114, 115, 116, + 117, 118, 119, 120, 121, 122, 123, -1, 125, 126, + 127, 128, 129, -1, 131, 132, 133, 134, 135, 136, + -1, 138, 139, 140, 141, 142, -1, 144, -1, 146, + 147, 148, 149, 150, 151, 152, -1, 154, 155, 156, + 157, 158, 159, -1, 161, 162, -1, 164, 165, 166, + 167, 168, 169, 170, 171, 172, 173, 174, 175, 176, + 177, 178, 179, -1, 181, -1, 183, 184, 185, 186, + 187, -1, 189, 190, 191, -1, -1, 194, 195, 196, + 197, 198, -1, 200, 201, 202, -1, 204, 205, -1, + 207, 208, 209, 210, 211, 212, 213, 214, 215, -1, + 217, -1, 219, 220, 221, -1, 223, -1, 225, 226, + -1, 228, 229, 230, 231, -1, 233, 234, -1, 236, + -1, 238, 239, 240, 241, 242, 243, 244, 245, 246, + -1, 248, 249, 250, 251, 252, 253, -1, 255, 256, + 257, -1, 259, 260, 261, -1, 263, -1, 265, -1, + 267, 268, 269, 270, 271, 272, 273, 274, 275, 276, + 277, 278, -1, 280, 281, 282, 283, 284, -1, 286, + 287, 288, 289, 290, 291, 292, 293, 294, 295, 296, + 297, 298, 299, 300, 301, 302, 303, 304, 305, 306, + 307, 308, -1, 310, 311, 312, 313, -1, 315, 316, + 317, 318, 319, 320, -1, 322, -1, 324, 325, 326, + 327, -1, -1, 330, 331, 332, 333, 334, 335, 336, + 337, 338, 339, 340, 341, -1, 343, 344, 345, 346, + 347, 348, 349, -1, 351, 352, 353, 354, 355, 356, + 357, 358, 359, 360, 361, 362, -1, 364, 365, 366, + 367, 368, 369, 370, 371, 372, 373, -1, 375, 376, + 377, 378, 379, 380, 381, 382, 383, 384, 385, 386, + 387, 388, -1, 390, 391, 392, 393, 394, 395, 396, + 397, 398, 399, 400, 401, 402, 403, -1, 405, 406, + 407, 408, 409, 410, 411, 412, 413, 414, 415, -1, + 417, 418, -1, 420, 421, 422, 423, 424, 425, -1, + 427, 428, -1, -1, 431, 432, 433, 434, -1, 436, + 437, 438, 439, 440, 441, 442, -1, -1, 445, 446, + 447, 448, 449, 450, -1, 452, 453, 454, 455, 456, + 457, 458, -1, 460, 461, 462, 463, 464, -1, -1, + 467, -1, -1, 470, 471, 472, 473, 474, 475, 476, + 477, 478, 479, 480, 481, 482, 483, 484, 485, 486, + -1, -1, -1, 5, 6, 7, 8, 9, 10, 11, + 12, 13, -1, 15, 16, -1, 503, 19, 20, 21, + 22, 23, 24, 25, 26, 27, 28, 29, -1, 31, + 32, 33, 34, 35, 36, 37, 38, 39, 40, -1, + 42, 43, 44, 45, 46, -1, -1, -1, 50, 51, + -1, -1, -1, -1, 56, -1, -1, -1, -1, -1, + -1, -1, -1, 65, -1, 67, -1, 69, 70, 71, + -1, -1, -1, -1, -1, -1, -1, 79, 80, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 91, + 92, 93, 94, 95, 96, 97, 98, -1, 100, 101, + 102, -1, -1, -1, -1, -1, -1, -1, 110, 111, + -1, 113, 114, 115, 116, 117, 118, 119, 120, 121, + 122, 123, -1, 125, 126, 127, 128, 129, -1, 131, + 132, 133, 134, 135, 136, -1, 138, 139, 140, 141, + 142, -1, 144, -1, 146, 147, 148, 149, 150, 151, + 152, -1, 154, 155, 156, 157, 158, 159, -1, 161, + 162, -1, 164, 165, 166, 167, 168, 169, 170, 171, + 172, 173, 174, 175, 176, 177, 178, 179, -1, 181, + -1, 183, 184, 185, 186, 187, -1, 189, 190, 191, + -1, -1, 194, 195, 196, 197, 198, -1, 200, 201, + 202, -1, 204, 205, -1, 207, 208, 209, 210, 211, + 212, 213, 214, 215, -1, 217, -1, 219, 220, 221, + -1, 223, -1, 225, 226, -1, 228, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, 243, 244, 245, 246, -1, 248, 249, 250, 251, + 252, 253, -1, 255, 256, 257, -1, 259, 260, 261, + -1, 263, -1, 265, -1, 267, 268, 269, 270, 271, + 272, 273, 274, 275, 276, 277, 278, -1, 280, 281, + 282, 283, 284, -1, 286, 287, 288, 289, 290, 291, + 292, 293, 294, 295, 296, 297, 298, 299, 300, 301, + 302, 303, 304, 305, 306, 307, 308, -1, 310, 311, + 312, 313, -1, 315, 316, 317, 318, 319, 320, -1, + 322, -1, -1, 325, 326, 327, -1, -1, 330, 331, + 332, 333, 334, 335, 336, 337, 338, 339, 340, 341, + -1, 343, 344, 345, 346, 347, 348, 349, -1, 351, + 352, 353, 354, 355, 356, 357, 358, 359, 360, 361, + 362, -1, 364, 365, 366, 367, 368, 369, 370, 371, + 372, 373, -1, 375, 376, 377, 378, 379, 380, 381, + 382, 383, 384, 385, 386, 387, 388, -1, 390, 391, + 392, 393, 394, 395, 396, 397, 398, 399, 400, 401, + 402, 403, -1, 405, 406, 407, 408, 409, 410, 411, + 412, 413, 414, 415, -1, 417, 418, -1, 420, 421, + 422, 423, 424, 425, -1, 427, 428, -1, -1, 431, + 432, 433, 434, -1, 436, 437, 438, 439, 440, 441, + 442, -1, -1, 445, 446, 447, 448, 449, 450, -1, + 452, 453, 454, 455, 456, 457, 458, -1, 460, 461, + 462, 463, 464, -1, -1, 467, -1, -1, 470, 471, + 472, 473, 474, 475, 476, 477, 478, 479, 480, 481, + 482, 483, 484, 485, 486, -1, -1, -1, 5, 6, + 7, 8, 9, 10, 11, 12, 13, -1, 15, 16, + -1, 503, 19, 20, 21, 22, 23, 24, 25, 26, + 27, 28, 29, -1, 31, 32, 33, 34, 35, 36, + 37, 38, 39, 40, -1, 42, 43, 44, 45, 46, + -1, -1, -1, 50, 51, -1, -1, -1, -1, 56, + -1, -1, -1, -1, -1, -1, -1, -1, 65, -1, + 67, -1, 69, 70, 71, -1, -1, -1, -1, -1, + -1, -1, 79, 80, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 91, 92, 93, 94, 95, 96, + 97, 98, -1, 100, 101, 102, -1, -1, -1, -1, + -1, -1, -1, 110, 111, -1, 113, 114, 115, 116, + 117, 118, 119, 120, 121, 122, 123, -1, 125, 126, + 127, 128, 129, -1, -1, 132, 133, 134, 135, 136, + -1, 138, 139, 140, 141, 142, -1, 144, -1, 146, + 147, 148, 149, 150, 151, 152, -1, 154, 155, 156, + 157, 158, 159, -1, 161, 162, -1, -1, -1, -1, + 167, -1, -1, -1, 171, 172, 173, 174, 175, 176, + 177, 178, 179, -1, 181, -1, 183, 184, 185, 186, + 187, -1, 189, 190, 191, -1, -1, 194, 195, 196, + 197, 198, -1, 200, 201, 202, -1, 204, 205, -1, + 207, 208, 209, 210, 211, 212, 213, 214, 215, -1, + 217, -1, 219, 220, 221, -1, 223, -1, 225, 226, + -1, 228, 229, 230, 231, -1, 233, 234, -1, 236, + -1, 238, 239, 240, 241, 242, 243, 244, 245, 246, + -1, 248, 249, 250, 251, 252, 253, -1, 255, 256, + 257, -1, 259, 260, 261, -1, 263, -1, 265, -1, + 267, 268, 269, 270, 271, 272, 273, 274, 275, 276, + 277, 278, -1, 280, 281, 282, 283, 284, -1, 286, + 287, 288, -1, -1, 291, 292, 293, 294, 295, 296, + 297, 298, 299, 300, 301, 302, 303, 304, 305, 306, + 307, 308, -1, 310, 311, 312, 313, -1, 315, 316, + 317, 318, 319, 320, -1, 322, -1, -1, 325, 326, + 327, -1, -1, 330, 331, 332, 333, 334, 335, 336, + 337, 338, 339, 340, 341, -1, 343, 344, 345, 346, + 347, 348, 349, -1, 351, 352, 353, 354, 355, 356, + 357, 358, 359, 360, 361, 362, -1, 364, 365, 366, + 367, 368, 369, 370, 371, 372, 373, -1, 375, 376, + 377, 378, 379, 380, 381, 382, 383, 384, 385, 386, + 387, 388, -1, 390, 391, 392, 393, 394, -1, 396, + 397, 398, 399, 400, 401, 402, 403, -1, 405, 406, + 407, 408, 409, 410, 411, 412, 413, 414, 415, -1, + 417, 418, -1, 420, 421, 422, 423, 424, 425, -1, + 427, 428, -1, -1, 431, 432, 433, 434, -1, 436, + 437, 438, 439, 440, 441, 442, -1, -1, 445, 446, + 447, 448, 449, -1, -1, 452, 453, 454, 455, 456, + 457, 458, -1, 460, 461, 462, 463, 464, -1, -1, + 467, -1, -1, 470, 471, 472, 473, 474, 475, 476, + 477, 478, 479, 480, 481, 482, 483, 484, 485, 486, + -1, -1, -1, -1, 6, 7, 8, 9, 10, 11, + 12, 13, -1, 15, 16, -1, 503, 19, 20, 21, + 22, 23, 24, -1, 26, 27, 28, -1, -1, 31, + 32, 33, 34, -1, -1, 37, 38, 39, 40, -1, + 42, -1, -1, 45, 46, -1, -1, -1, 50, 51, + -1, -1, -1, -1, 56, -1, -1, -1, -1, -1, + -1, -1, -1, 65, -1, 67, -1, 69, 70, 71, + -1, -1, -1, -1, -1, -1, -1, 79, 80, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 91, + 92, 93, 94, 95, 96, 97, 98, -1, 100, 101, + 102, -1, -1, -1, -1, -1, 108, -1, 110, 111, + -1, 113, 114, -1, 116, 117, 118, 119, 120, -1, + 122, 123, -1, 125, 126, 127, 128, 129, -1, -1, + 132, 133, 134, 135, 136, -1, 138, 139, 140, 141, + 142, -1, -1, -1, 146, 147, 148, 149, -1, 151, + 152, -1, 154, 155, 156, 157, 158, 159, -1, 161, + 162, -1, -1, -1, -1, -1, -1, -1, -1, 171, + 172, 173, 174, 175, 176, 177, 178, 179, -1, 181, + -1, 183, 184, 185, 186, 187, -1, 189, 190, 191, + -1, -1, 194, 195, 196, 197, 198, -1, 200, 201, + 202, -1, 204, 205, -1, 207, 208, 209, 210, 211, + 212, 213, 214, 215, -1, 217, -1, 219, 220, 221, + -1, 223, -1, 225, -1, -1, 228, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, -1, 244, 245, 246, -1, 248, 249, 250, 251, + 252, 253, -1, 255, 256, 257, -1, 259, 260, 261, + -1, 263, -1, 265, -1, 267, -1, -1, 270, 271, + 272, 273, 274, 275, 276, 277, 278, -1, 280, 281, + 282, 283, -1, -1, 286, 287, 288, -1, -1, 291, + 292, 293, 294, 295, 296, 297, 298, 299, 300, 301, + 302, 303, 304, 305, 306, 307, 308, -1, 310, 311, + -1, 313, -1, 315, 316, 317, 318, 319, 320, -1, + 322, -1, -1, 325, 326, 327, -1, -1, 330, -1, + -1, -1, 334, 335, 336, 337, 338, 339, 340, 341, + -1, 343, 344, 345, 346, 347, 348, 349, -1, 351, + 352, 353, 354, 355, 356, 357, 358, 359, 360, 361, + 362, -1, 364, 365, 366, 367, 368, 369, 370, 371, + 372, 373, -1, 375, 376, 377, 378, 379, 380, 381, + 382, 383, 384, 385, 386, 387, 388, -1, 390, 391, + 392, 393, 394, -1, 396, 397, 398, 399, -1, 401, + 402, 403, -1, 405, 406, 407, 408, 409, 410, 411, + 412, 413, 414, 415, -1, 417, 418, -1, 420, 421, + 422, 423, 424, 425, -1, 427, 428, -1, -1, 431, + 432, 433, 434, -1, 436, 437, 438, 439, 440, 441, + 442, -1, -1, 445, 446, 447, 448, 449, -1, -1, + 452, 453, 454, 455, 456, 457, 458, -1, 460, -1, + 462, 463, 464, -1, -1, 467, -1, -1, 470, 471, + 472, 473, 474, 475, 476, 477, 478, 479, 480, 481, + 482, 483, 484, 485, 486, -1, -1, -1, -1, -1, + 6, 7, 8, 9, 10, 11, 12, 13, -1, 15, + 16, -1, 504, 19, 20, 21, 22, 23, 24, -1, + 26, 27, 28, -1, -1, 31, 32, 33, 34, -1, + -1, 37, 38, 39, 40, -1, 42, -1, -1, 45, + 46, -1, -1, -1, 50, 51, -1, -1, -1, -1, + 56, -1, -1, -1, -1, -1, -1, -1, -1, 65, + -1, 67, -1, 69, 70, 71, -1, -1, -1, -1, + -1, -1, -1, 79, 80, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 91, 92, 93, 94, 95, + 96, 97, 98, -1, 100, 101, 102, -1, -1, -1, + -1, -1, -1, -1, 110, 111, -1, 113, 114, -1, + 116, 117, 118, 119, 120, -1, 122, 123, -1, 125, + 126, 127, 128, 129, -1, -1, 132, 133, 134, 135, + 136, -1, 138, 139, 140, 141, 142, -1, -1, -1, + 146, 147, 148, 149, -1, 151, 152, -1, 154, 155, + 156, 157, 158, 159, -1, -1, 162, -1, -1, -1, + -1, -1, -1, -1, -1, 171, 172, 173, 174, 175, + 176, 177, 178, 179, -1, 181, -1, 183, 184, 185, + 186, 187, -1, 189, 190, 191, -1, -1, 194, 195, + 196, 197, 198, -1, 200, 201, 202, -1, 204, 205, + -1, 207, 208, 209, 210, 211, 212, 213, 214, 215, + -1, 217, -1, 219, 220, 221, -1, 223, -1, 225, + -1, -1, -1, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, -1, 244, 245, + 246, -1, 248, 249, 250, 251, 252, 253, -1, 255, + -1, 257, -1, 259, 260, 261, -1, 263, -1, 265, + -1, 267, -1, -1, 270, -1, 272, 273, 274, 275, + 276, 277, 278, -1, 280, 281, -1, 283, -1, -1, + 286, 287, 288, -1, -1, 291, 292, 293, 294, 295, + 296, 297, 298, 299, 300, 301, 302, 303, -1, 305, + 306, 307, 308, -1, 310, 311, -1, 313, -1, 315, + 316, 317, 318, 319, 320, -1, 322, -1, -1, 325, + 326, 327, -1, -1, 330, -1, -1, -1, 334, 335, + 336, 337, 338, 339, 340, 341, -1, 343, 344, 345, + 346, 347, 348, 349, -1, 351, 352, 353, 354, 355, + 356, 357, 358, 359, 360, 361, 362, -1, 364, 365, + 366, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, -1, 378, 379, 380, 381, 382, 383, 384, 385, + 386, 387, 388, -1, 390, 391, 392, 393, 394, -1, + 396, 397, 398, 399, -1, 401, 402, 403, -1, 405, + 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, + -1, 417, 418, -1, 420, 421, 422, 423, 424, 425, + -1, 427, 428, -1, -1, 431, 432, 433, 434, -1, + 436, 437, 438, 439, 440, 441, 442, -1, -1, 445, + 446, 447, 448, 449, -1, -1, 452, 453, 454, 455, + 456, 457, 458, -1, 460, -1, 462, 463, 464, -1, + -1, 467, -1, -1, 470, 471, 472, 473, 474, 475, + 476, 477, 478, 479, 480, 481, 482, 483, 484, 485, + 486, -1, -1, -1, -1, -1, 6, 7, 8, 9, + 10, 11, 12, 13, -1, 15, 16, -1, 504, 19, + 20, 21, 22, 23, 24, -1, 26, 27, 28, -1, + -1, 31, 32, 33, 34, -1, -1, 37, 38, 39, + 40, -1, 42, -1, -1, 45, 46, -1, -1, -1, + 50, 51, -1, -1, -1, -1, 56, -1, -1, -1, + -1, -1, -1, -1, -1, 65, -1, 67, -1, 69, + 70, 71, 72, -1, -1, 75, 76, 77, 78, 79, + 80, 81, 82, -1, -1, -1, 86, -1, -1, -1, + -1, 91, 92, 93, 94, 95, 96, 97, 98, -1, + 100, 101, 102, -1, -1, -1, -1, -1, -1, -1, + 110, 111, -1, 113, 114, -1, 116, 117, 118, 119, + 120, -1, 122, 123, -1, 125, 126, 127, 128, 129, + -1, -1, 132, 133, 134, 135, 136, -1, 138, 139, + 140, 141, 142, -1, -1, -1, 146, 147, 148, 149, + -1, 151, 152, -1, 154, 155, 156, 157, 158, 159, + -1, -1, 162, -1, -1, -1, -1, -1, -1, -1, + -1, 171, 172, 173, 174, 175, 176, 177, 178, 179, + -1, 181, -1, 183, 184, 185, 186, 187, -1, 189, + 190, 191, -1, -1, 194, 195, 196, 197, 198, -1, + 200, 201, 202, -1, 204, 205, -1, 207, 208, 209, + 210, 211, 212, 213, 214, 215, 216, 217, -1, 219, + 220, 221, -1, 223, -1, 225, -1, -1, -1, 229, + 230, 231, -1, 233, 234, -1, 236, -1, 238, 239, + 240, 241, 242, -1, 244, 245, 246, -1, 248, 249, + 250, 251, 252, 253, -1, 255, -1, 257, -1, 259, + 260, 261, -1, 263, -1, 265, -1, 267, -1, -1, + 270, -1, 272, 273, 274, 275, 276, 277, 278, -1, + 280, 281, -1, 283, -1, -1, 286, 287, 288, -1, + -1, 291, 292, 293, 294, 295, 296, 297, 298, 299, + 300, 301, 302, 303, -1, 305, 306, 307, 308, -1, + 310, 311, -1, 313, -1, 315, 316, 317, 318, 319, + 320, -1, 322, 323, -1, 325, 326, 327, -1, -1, + 330, -1, -1, -1, 334, 335, 336, 337, 338, 339, + 340, 341, -1, 343, 344, 345, 346, 347, 348, 349, + -1, 351, 352, 353, 354, 355, 356, 357, 358, 359, + 360, 361, 362, -1, 364, 365, 366, 367, 368, 369, + 370, 371, 372, 373, -1, 375, 376, -1, 378, 379, + 380, 381, 382, 383, 384, 385, 386, 387, 388, -1, + 390, 391, 392, 393, 394, -1, 396, 397, 398, 399, + -1, 401, 402, 403, -1, 405, 406, 407, 408, 409, + 410, 411, 412, 413, 414, 415, -1, 417, 418, -1, + 420, 421, 422, 423, 424, 425, -1, 427, 428, -1, + -1, 431, 432, 433, 434, 435, 436, 437, 438, 439, + 440, 441, 442, -1, -1, 445, 446, 447, 448, 449, + -1, -1, 452, 453, 454, 455, 456, 457, 458, -1, + 460, -1, 462, 463, 464, -1, -1, 467, -1, -1, + 470, 471, 472, 473, 474, 475, 476, 477, 478, 479, + 480, 481, 482, 483, 484, 485, 486, -1, -1, -1, + -1, -1, -1, -1, 494, 495, 496, -1, -1, -1, + -1, -1, -1, 503, 6, 7, 8, 9, 10, 11, + 12, 13, -1, 15, 16, -1, -1, 19, 20, 21, + 22, 23, 24, -1, 26, 27, 28, -1, -1, 31, + 32, 33, 34, -1, -1, 37, 38, 39, 40, -1, + 42, -1, -1, 45, 46, -1, -1, -1, 50, 51, + -1, -1, -1, -1, 56, -1, -1, -1, -1, -1, + -1, -1, -1, 65, -1, 67, -1, 69, 70, 71, + -1, -1, -1, 75, 76, 77, 78, 79, 80, -1, + 82, -1, -1, -1, 86, -1, -1, -1, -1, 91, + 92, 93, 94, 95, 96, 97, 98, -1, 100, 101, + 102, -1, -1, -1, -1, -1, -1, -1, 110, 111, + -1, 113, 114, -1, 116, 117, 118, 119, 120, -1, + 122, 123, -1, 125, 126, 127, 128, 129, -1, -1, + 132, 133, 134, 135, 136, -1, 138, 139, 140, 141, + 142, -1, -1, -1, 146, 147, 148, 149, -1, 151, + 152, -1, 154, 155, 156, 157, 158, 159, -1, -1, + 162, -1, -1, -1, -1, -1, -1, -1, -1, 171, + 172, 173, 174, 175, 176, 177, 178, 179, -1, 181, + -1, 183, 184, 185, 186, 187, -1, 189, 190, 191, + -1, -1, 194, 195, 196, 197, 198, -1, 200, 201, + 202, -1, 204, 205, -1, 207, 208, 209, 210, 211, + 212, 213, 214, 215, -1, 217, -1, 219, 220, 221, + -1, 223, -1, 225, -1, -1, -1, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, -1, 244, 245, 246, -1, 248, 249, 250, 251, + 252, 253, -1, 255, -1, 257, -1, 259, 260, 261, + -1, 263, -1, 265, -1, 267, -1, -1, 270, -1, + 272, 273, 274, 275, 276, 277, 278, -1, 280, 281, + -1, 283, -1, -1, 286, 287, 288, -1, -1, 291, + 292, 293, 294, 295, 296, 297, 298, 299, 300, 301, + 302, 303, -1, 305, 306, 307, 308, -1, 310, 311, + -1, 313, -1, 315, 316, 317, 318, 319, 320, -1, + 322, -1, -1, 325, 326, 327, -1, -1, 330, -1, + -1, -1, 334, 335, 336, 337, 338, 339, 340, 341, + -1, 343, 344, 345, 346, 347, 348, 349, -1, 351, + 352, 353, 354, 355, 356, 357, 358, 359, 360, 361, + 362, -1, 364, 365, 366, 367, 368, 369, 370, 371, + 372, 373, -1, 375, 376, -1, 378, 379, 380, 381, + 382, 383, 384, 385, 386, 387, 388, -1, 390, 391, + 392, 393, 394, -1, 396, 397, 398, 399, -1, 401, + 402, 403, -1, 405, 406, 407, 408, 409, 410, 411, + 412, 413, 414, 415, -1, 417, 418, -1, 420, 421, + 422, 423, 424, 425, -1, 427, 428, -1, -1, 431, + 432, 433, 434, -1, 436, 437, 438, 439, 440, 441, + 442, -1, -1, 445, 446, 447, 448, 449, -1, -1, + 452, 453, 454, 455, 456, 457, 458, -1, 460, -1, + 462, 463, 464, -1, -1, 467, -1, -1, 470, 471, + 472, 473, 474, 475, 476, 477, 478, 479, 480, 481, + 482, 483, 484, 485, 486, -1, -1, -1, -1, 6, + 7, 8, 9, 10, 11, 12, 13, -1, 15, 16, + 502, 503, 19, 20, 21, 22, 23, 24, -1, 26, + 27, 28, -1, -1, 31, 32, 33, 34, -1, -1, + 37, 38, 39, 40, -1, 42, -1, -1, 45, 46, + -1, -1, -1, 50, 51, -1, -1, -1, -1, 56, + -1, -1, -1, -1, -1, -1, -1, -1, 65, -1, + 67, -1, 69, 70, 71, -1, -1, -1, -1, -1, + -1, -1, 79, 80, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 91, 92, 93, 94, 95, 96, + 97, 98, -1, 100, 101, 102, 103, 104, -1, -1, + -1, -1, -1, 110, 111, -1, 113, 114, -1, 116, + 117, 118, 119, 120, -1, 122, 123, -1, 125, 126, + 127, 128, 129, -1, -1, 132, 133, 134, 135, 136, + -1, 138, 139, 140, 141, 142, -1, -1, -1, 146, + 147, 148, 149, -1, 151, 152, -1, 154, 155, 156, + 157, 158, 159, -1, -1, 162, -1, -1, -1, -1, + -1, -1, -1, -1, 171, 172, 173, 174, 175, 176, + 177, 178, 179, -1, 181, -1, 183, 184, 185, 186, + 187, -1, 189, 190, 191, -1, -1, 194, 195, 196, + 197, 198, -1, 200, 201, 202, -1, 204, 205, -1, + 207, 208, 209, 210, 211, 212, 213, 214, 215, -1, + 217, -1, 219, 220, 221, -1, 223, -1, 225, -1, + -1, -1, 229, 230, 231, -1, 233, 234, -1, 236, + -1, 238, 239, 240, 241, 242, -1, 244, 245, 246, + -1, 248, 249, 250, 251, 252, 253, -1, 255, -1, + 257, -1, 259, 260, 261, -1, 263, -1, 265, -1, + 267, -1, -1, 270, -1, 272, 273, 274, 275, 276, + 277, 278, -1, 280, 281, -1, 283, -1, -1, 286, + 287, 288, -1, -1, 291, 292, 293, 294, 295, 296, + 297, 298, 299, 300, 301, 302, 303, -1, 305, 306, + 307, 308, -1, 310, 311, -1, 313, -1, 315, 316, + 317, 318, 319, 320, -1, 322, -1, -1, 325, 326, + 327, -1, -1, 330, -1, -1, -1, 334, 335, 336, + 337, 338, 339, 340, 341, -1, 343, 344, 345, 346, + 347, 348, 349, -1, 351, 352, 353, 354, 355, 356, + 357, 358, 359, 360, 361, 362, -1, 364, 365, 366, + 367, 368, 369, 370, 371, 372, 373, -1, 375, 376, + -1, 378, 379, 380, 381, 382, 383, 384, 385, 386, + 387, 388, 389, 390, 391, 392, 393, 394, -1, 396, + 397, 398, 399, -1, 401, 402, 403, -1, 405, 406, + 407, 408, 409, 410, 411, 412, 413, 414, 415, -1, + 417, 418, 419, 420, 421, 422, 423, 424, 425, -1, + 427, 428, -1, -1, 431, 432, 433, 434, -1, 436, + 437, 438, 439, 440, 441, 442, -1, -1, 445, 446, + 447, 448, 449, -1, -1, 452, 453, 454, 455, 456, + 457, 458, -1, 460, 461, 462, 463, 464, -1, -1, + 467, -1, 469, 470, 471, 472, 473, 474, 475, 476, + 477, 478, 479, 480, 481, 482, 483, 484, 485, 486, + -1, -1, -1, -1, 6, 7, 8, 9, 10, 11, + 12, 13, -1, 15, 16, -1, 503, 19, 20, 21, + 22, 23, 24, -1, 26, 27, 28, -1, -1, 31, + 32, 33, 34, -1, -1, 37, 38, 39, 40, -1, + 42, -1, -1, 45, 46, -1, -1, -1, 50, 51, + -1, -1, -1, -1, 56, -1, -1, -1, -1, -1, + -1, -1, -1, 65, -1, 67, -1, 69, 70, 71, + -1, -1, -1, 75, 76, 77, 78, 79, 80, -1, + 82, -1, -1, -1, 86, -1, -1, -1, -1, 91, + 92, 93, 94, 95, 96, 97, 98, -1, 100, 101, + 102, -1, -1, -1, -1, -1, -1, -1, 110, 111, + -1, 113, 114, -1, 116, 117, 118, 119, 120, -1, + 122, 123, -1, 125, 126, 127, 128, 129, -1, -1, + 132, 133, 134, 135, 136, -1, 138, 139, 140, 141, + 142, -1, -1, -1, 146, 147, 148, 149, -1, 151, + 152, -1, 154, 155, 156, 157, 158, 159, -1, -1, + 162, -1, -1, -1, -1, -1, -1, -1, -1, 171, + 172, 173, 174, 175, 176, 177, 178, 179, -1, 181, + -1, 183, 184, 185, 186, 187, -1, 189, 190, 191, + -1, -1, 194, 195, 196, 197, 198, -1, 200, 201, + 202, -1, 204, 205, -1, 207, 208, 209, 210, 211, + 212, 213, 214, 215, -1, 217, -1, 219, 220, 221, + -1, 223, -1, 225, -1, -1, -1, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, -1, 244, 245, 246, -1, 248, 249, 250, 251, + 252, 253, -1, 255, -1, 257, -1, 259, 260, 261, + -1, 263, -1, 265, -1, 267, -1, -1, 270, -1, + 272, 273, 274, 275, 276, 277, 278, -1, 280, 281, + -1, 283, -1, -1, 286, 287, 288, -1, -1, 291, + 292, 293, 294, 295, 296, 297, 298, 299, 300, 301, + 302, 303, -1, 305, 306, 307, 308, -1, 310, 311, + -1, 313, -1, 315, 316, 317, 318, 319, 320, -1, + 322, -1, -1, 325, 326, 327, -1, -1, 330, -1, + -1, -1, 334, 335, 336, 337, 338, 339, 340, 341, + -1, 343, 344, 345, 346, 347, 348, 349, -1, 351, + 352, 353, 354, 355, 356, 357, 358, 359, 360, 361, + 362, -1, 364, 365, 366, 367, 368, 369, 370, 371, + 372, 373, -1, 375, 376, -1, 378, 379, 380, 381, + 382, 383, 384, 385, 386, 387, 388, -1, 390, 391, + 392, 393, 394, -1, 396, 397, 398, 399, -1, 401, + 402, 403, -1, 405, 406, 407, 408, 409, 410, 411, + 412, 413, 414, 415, -1, 417, 418, -1, 420, 421, + 422, 423, 424, 425, -1, 427, 428, -1, -1, 431, + 432, 433, 434, -1, 436, 437, 438, 439, 440, 441, + 442, -1, -1, 445, 446, 447, 448, 449, -1, -1, + 452, 453, 454, 455, 456, 457, 458, -1, 460, -1, + 462, 463, 464, -1, -1, 467, -1, -1, 470, 471, + 472, 473, 474, 475, 476, 477, 478, 479, 480, 481, + 482, 483, 484, 485, 486, -1, -1, -1, -1, 6, + 7, 8, 9, 10, 11, 12, 13, -1, 15, 16, + -1, 503, 19, 20, 21, 22, 23, 24, -1, 26, + 27, 28, -1, -1, 31, 32, 33, 34, -1, -1, + 37, 38, 39, 40, -1, 42, -1, -1, 45, 46, + -1, -1, -1, 50, 51, -1, -1, -1, -1, 56, + -1, -1, -1, -1, -1, -1, -1, -1, 65, -1, + 67, -1, 69, 70, 71, 72, -1, -1, -1, -1, + -1, -1, 79, 80, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 91, 92, 93, 94, 95, 96, + 97, 98, -1, 100, 101, 102, -1, -1, -1, -1, + -1, -1, -1, 110, 111, -1, 113, 114, -1, 116, + 117, 118, 119, 120, -1, 122, 123, -1, 125, 126, + 127, 128, 129, -1, -1, 132, 133, 134, 135, 136, + -1, 138, 139, 140, 141, 142, -1, -1, -1, 146, + 147, 148, 149, -1, 151, 152, -1, 154, 155, 156, + 157, 158, 159, -1, -1, 162, -1, -1, -1, -1, + -1, -1, -1, -1, 171, 172, 173, 174, 175, 176, + 177, 178, 179, -1, 181, -1, 183, 184, 185, 186, + 187, -1, 189, 190, 191, -1, -1, 194, 195, 196, + 197, 198, -1, 200, 201, 202, -1, 204, 205, -1, + 207, 208, 209, 210, 211, 212, 213, 214, 215, -1, + 217, -1, 219, 220, 221, -1, 223, -1, 225, -1, + -1, -1, 229, 230, 231, -1, 233, 234, -1, 236, + -1, 238, 239, 240, 241, 242, -1, 244, 245, 246, + -1, 248, 249, 250, 251, 252, 253, -1, 255, -1, + 257, -1, 259, 260, 261, -1, 263, -1, 265, -1, + 267, -1, -1, 270, -1, 272, 273, 274, 275, 276, + 277, 278, -1, 280, 281, -1, 283, -1, -1, 286, + 287, 288, -1, -1, 291, 292, 293, 294, 295, 296, + 297, 298, 299, 300, 301, 302, 303, -1, 305, 306, + 307, 308, -1, 310, 311, -1, 313, -1, 315, 316, + 317, 318, 319, 320, -1, 322, -1, -1, 325, 326, + 327, -1, -1, 330, -1, -1, -1, 334, 335, 336, + 337, 338, 339, 340, 341, -1, 343, 344, 345, 346, + 347, 348, 349, -1, 351, 352, 353, 354, 355, 356, + 357, 358, 359, 360, 361, 362, -1, 364, 365, 366, + 367, 368, 369, 370, 371, 372, 373, -1, 375, 376, + -1, 378, 379, 380, 381, 382, 383, 384, 385, 386, + 387, 388, 389, 390, 391, 392, 393, 394, -1, 396, + 397, 398, 399, -1, 401, 402, 403, -1, 405, 406, + 407, 408, 409, 410, 411, 412, 413, 414, 415, -1, + 417, 418, 419, 420, 421, 422, 423, 424, 425, -1, + 427, 428, -1, -1, 431, 432, 433, 434, -1, 436, + 437, 438, 439, 440, 441, 442, -1, -1, 445, 446, + 447, 448, 449, -1, -1, 452, 453, 454, 455, 456, + 457, 458, -1, 460, -1, 462, 463, 464, -1, -1, + 467, -1, 469, 470, 471, 472, 473, 474, 475, 476, + 477, 478, 479, 480, 481, 482, 483, 484, 485, 486, + -1, -1, -1, -1, 6, 7, 8, 9, 10, 11, + 12, 13, -1, 15, 16, -1, 503, 19, 20, 21, + 22, 23, 24, -1, 26, 27, 28, -1, -1, 31, + 32, 33, 34, -1, -1, 37, 38, 39, 40, -1, + 42, -1, -1, 45, 46, -1, -1, -1, 50, 51, + -1, -1, -1, -1, 56, -1, -1, -1, -1, -1, + -1, -1, -1, 65, -1, 67, -1, 69, 70, 71, + -1, -1, -1, -1, -1, -1, -1, 79, 80, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 91, + 92, 93, 94, 95, 96, 97, 98, -1, 100, 101, + 102, -1, -1, -1, -1, -1, -1, -1, 110, 111, + -1, 113, 114, -1, 116, 117, 118, 119, 120, -1, + 122, 123, -1, 125, 126, 127, 128, 129, -1, -1, + 132, 133, 134, 135, 136, -1, 138, 139, 140, 141, + 142, -1, -1, -1, 146, 147, 148, 149, -1, 151, + 152, -1, 154, 155, 156, 157, 158, 159, -1, -1, + 162, -1, -1, -1, -1, -1, -1, -1, -1, 171, + 172, 173, 174, 175, 176, 177, 178, 179, -1, 181, + -1, 183, 184, 185, 186, 187, -1, 189, 190, 191, + -1, -1, 194, 195, 196, 197, 198, -1, 200, 201, + 202, -1, 204, 205, -1, 207, 208, 209, 210, 211, + 212, 213, 214, 215, -1, 217, -1, 219, 220, 221, + -1, 223, -1, 225, -1, -1, -1, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, -1, 244, 245, 246, -1, 248, 249, 250, 251, + 252, 253, -1, 255, -1, 257, -1, 259, 260, 261, + -1, 263, -1, 265, -1, 267, -1, -1, 270, -1, + 272, 273, 274, 275, 276, 277, 278, -1, 280, 281, + -1, 283, -1, -1, 286, 287, 288, -1, -1, 291, + 292, 293, 294, 295, 296, 297, 298, 299, 300, 301, + 302, 303, -1, 305, 306, 307, 308, -1, 310, 311, + -1, 313, -1, 315, 316, 317, 318, 319, 320, -1, + 322, -1, -1, 325, 326, 327, -1, -1, 330, -1, + -1, -1, 334, 335, 336, 337, 338, 339, 340, 341, + -1, 343, 344, 345, 346, 347, 348, 349, -1, 351, + 352, 353, 354, 355, 356, 357, 358, 359, 360, 361, + 362, -1, 364, 365, 366, 367, 368, 369, 370, 371, + 372, 373, -1, 375, 376, -1, 378, 379, 380, 381, + 382, 383, 384, 385, 386, 387, 388, 389, 390, 391, + 392, 393, 394, -1, 396, 397, 398, 399, -1, 401, + 402, 403, -1, 405, 406, 407, 408, 409, 410, 411, + 412, 413, 414, 415, -1, 417, 418, 419, 420, 421, + 422, 423, 424, 425, -1, 427, 428, -1, -1, 431, + 432, 433, 434, -1, 436, 437, 438, 439, 440, 441, + 442, -1, -1, 445, 446, 447, 448, 449, -1, -1, + 452, 453, 454, 455, 456, 457, 458, -1, 460, -1, + 462, 463, 464, -1, -1, 467, -1, 469, 470, 471, + 472, 473, 474, 475, 476, 477, 478, 479, 480, 481, + 482, 483, 484, 485, 486, -1, -1, -1, -1, 6, + 7, 8, 9, 10, 11, 12, 13, -1, 15, 16, + -1, 503, 19, 20, 21, 22, 23, 24, -1, 26, + 27, 28, -1, -1, 31, 32, 33, 34, -1, -1, + 37, 38, 39, 40, -1, 42, -1, -1, 45, 46, + -1, -1, -1, 50, 51, -1, -1, -1, -1, 56, + -1, -1, -1, -1, -1, -1, -1, -1, 65, -1, + 67, -1, 69, 70, 71, -1, -1, -1, -1, -1, + -1, -1, 79, 80, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 91, 92, 93, 94, 95, 96, + 97, 98, -1, 100, 101, 102, -1, -1, -1, -1, + -1, -1, -1, 110, 111, -1, 113, 114, -1, 116, + 117, 118, 119, 120, -1, 122, 123, -1, 125, 126, + 127, 128, 129, -1, -1, 132, 133, 134, 135, 136, + -1, 138, 139, 140, 141, 142, -1, -1, -1, 146, + 147, 148, 149, -1, 151, 152, -1, 154, 155, 156, + 157, 158, 159, -1, -1, 162, -1, -1, -1, -1, + -1, -1, -1, -1, 171, 172, 173, 174, 175, 176, + 177, 178, 179, -1, 181, -1, 183, 184, 185, 186, + 187, -1, 189, 190, 191, -1, -1, 194, 195, 196, + 197, 198, -1, 200, 201, 202, -1, 204, 205, -1, + 207, 208, 209, 210, 211, 212, 213, 214, 215, -1, + 217, -1, 219, 220, 221, -1, 223, -1, 225, -1, + -1, -1, 229, 230, 231, -1, 233, 234, -1, 236, + -1, 238, 239, 240, 241, 242, -1, 244, 245, 246, + -1, 248, 249, 250, 251, 252, 253, -1, 255, -1, + 257, -1, 259, 260, 261, -1, 263, -1, 265, -1, + 267, -1, -1, 270, -1, 272, 273, 274, 275, 276, + 277, 278, -1, 280, 281, -1, 283, -1, -1, 286, + 287, 288, -1, -1, 291, 292, 293, 294, 295, 296, + 297, 298, 299, 300, 301, 302, 303, -1, 305, 306, + 307, 308, -1, 310, 311, -1, 313, -1, 315, 316, + 317, 318, 319, 320, -1, 322, -1, -1, 325, 326, + 327, -1, -1, 330, -1, -1, -1, 334, 335, 336, + 337, 338, 339, 340, 341, -1, 343, 344, 345, 346, + 347, 348, 349, -1, 351, 352, 353, 354, 355, 356, + 357, 358, 359, 360, 361, 362, -1, 364, 365, 366, + 367, 368, 369, 370, 371, 372, 373, -1, 375, 376, + -1, 378, 379, 380, 381, 382, 383, 384, 385, 386, + 387, 388, -1, 390, 391, 392, 393, 394, -1, 396, + 397, 398, 399, -1, 401, 402, 403, -1, 405, 406, + 407, 408, 409, 410, 411, 412, 413, 414, 415, -1, + 417, 418, -1, 420, 421, 422, 423, 424, 425, -1, + 427, 428, -1, -1, 431, 432, 433, 434, -1, 436, + 437, 438, 439, 440, 441, 442, -1, -1, 445, 446, + 447, 448, 449, -1, -1, 452, 453, 454, 455, 456, + 457, 458, -1, 460, -1, 462, 463, 464, -1, -1, + 467, -1, -1, 470, 471, 472, 473, 474, 475, 476, + 477, 478, 479, 480, 481, 482, 483, 484, 485, 486, + -1, -1, -1, -1, 6, 7, 8, 9, 10, 11, + 12, 13, -1, 15, 16, -1, 503, 19, 20, 21, + 22, 23, 24, -1, 26, 27, 28, -1, -1, 31, + 32, 33, 34, -1, -1, 37, 38, 39, 40, -1, + 42, -1, -1, 45, 46, -1, -1, -1, 50, 51, + -1, -1, -1, -1, 56, -1, -1, -1, -1, -1, + -1, -1, -1, 65, -1, 67, -1, 69, 70, 71, + -1, -1, -1, -1, -1, -1, -1, 79, 80, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 91, + 92, 93, 94, 95, 96, 97, 98, -1, 100, 101, + 102, -1, -1, -1, -1, -1, -1, -1, 110, 111, + -1, 113, 114, -1, 116, 117, 118, 119, 120, -1, + 122, 123, -1, 125, 126, 127, 128, 129, -1, -1, + 132, 133, 134, 135, 136, -1, 138, 139, 140, 141, + 142, -1, -1, -1, 146, 147, 148, 149, -1, 151, + 152, -1, 154, 155, 156, 157, 158, 159, -1, -1, + 162, -1, -1, -1, -1, -1, -1, -1, -1, 171, + 172, 173, 174, 175, 176, 177, 178, 179, -1, 181, + -1, 183, 184, 185, 186, 187, -1, 189, 190, 191, + -1, -1, 194, 195, 196, 197, 198, -1, 200, 201, + 202, -1, 204, 205, -1, 207, 208, 209, 210, 211, + 212, 213, 214, 215, -1, 217, -1, 219, 220, 221, + -1, 223, -1, 225, -1, -1, -1, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, -1, 244, 245, 246, -1, 248, 249, 250, 251, + 252, 253, -1, 255, -1, 257, -1, 259, 260, 261, + -1, 263, -1, 265, -1, 267, -1, -1, 270, -1, + 272, 273, 274, 275, 276, 277, 278, -1, 280, 281, + -1, 283, -1, -1, 286, 287, 288, -1, -1, 291, + 292, 293, 294, 295, 296, 297, 298, 299, 300, 301, + 302, 303, -1, 305, 306, 307, 308, -1, 310, 311, + -1, 313, -1, 315, 316, 317, 318, 319, 320, -1, + 322, -1, -1, 325, 326, 327, -1, -1, 330, -1, + -1, -1, 334, 335, 336, 337, 338, 339, 340, 341, + -1, 343, 344, 345, 346, 347, 348, 349, -1, 351, + 352, 353, 354, 355, 356, 357, 358, 359, 360, 361, + 362, -1, 364, 365, 366, 367, 368, 369, 370, 371, + 372, 373, -1, 375, 376, -1, 378, 379, 380, 381, + 382, 383, 384, 385, 386, 387, 388, -1, 390, 391, + 392, 393, 394, -1, 396, 397, 398, 399, -1, 401, + 402, 403, -1, 405, 406, 407, 408, 409, 410, 411, + 412, 413, 414, 415, -1, 417, 418, -1, 420, 421, + 422, 423, 424, 425, -1, 427, 428, -1, -1, 431, + 432, 433, 434, -1, 436, 437, 438, 439, 440, 441, + 442, -1, -1, 445, 446, 447, 448, 449, -1, -1, + 452, 453, 454, 455, 456, 457, 458, -1, 460, -1, + 462, 463, 464, -1, -1, 467, -1, -1, 470, 471, + 472, 473, 474, 475, 476, 477, 478, 479, 480, 481, + 482, 483, 484, 485, 486, -1, -1, -1, -1, 6, + 7, 8, 9, 10, 11, 12, 13, -1, 15, 16, + -1, 503, 19, 20, 21, 22, 23, 24, -1, 26, + 27, 28, -1, -1, 31, 32, 33, 34, -1, -1, + 37, 38, 39, 40, -1, 42, -1, -1, 45, 46, + -1, -1, -1, 50, 51, -1, -1, -1, -1, 56, + -1, -1, -1, -1, -1, -1, -1, -1, 65, -1, + 67, -1, 69, 70, 71, -1, -1, -1, -1, -1, + -1, -1, 79, 80, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 91, 92, 93, 94, 95, 96, + 97, 98, -1, 100, 101, 102, -1, -1, -1, -1, + -1, -1, -1, 110, 111, -1, 113, 114, -1, 116, + 117, 118, 119, 120, -1, 122, 123, -1, 125, 126, + 127, 128, 129, -1, -1, 132, 133, 134, 135, 136, + -1, 138, 139, 140, 141, 142, -1, -1, -1, 146, + 147, 148, 149, -1, 151, 152, -1, 154, 155, 156, + 157, 158, 159, -1, -1, 162, -1, -1, -1, -1, + -1, -1, -1, -1, 171, 172, 173, 174, 175, 176, + 177, 178, 179, -1, 181, -1, 183, 184, 185, 186, + 187, -1, 189, 190, 191, -1, -1, 194, 195, 196, + 197, 198, -1, 200, 201, 202, -1, 204, 205, -1, + 207, 208, 209, 210, 211, 212, 213, 214, 215, -1, + 217, -1, 219, 220, 221, -1, 223, -1, 225, -1, + -1, -1, 229, 230, 231, -1, 233, 234, -1, 236, + -1, 238, 239, 240, 241, 242, -1, 244, 245, 246, + -1, 248, 249, 250, 251, 252, 253, -1, 255, -1, + 257, -1, 259, 260, 261, -1, 263, -1, 265, -1, + 267, -1, -1, 270, -1, 272, 273, 274, 275, 276, + 277, 278, -1, 280, 281, -1, 283, -1, -1, 286, + 287, 288, -1, -1, 291, 292, 293, 294, 295, 296, + 297, 298, 299, 300, 301, 302, 303, -1, 305, 306, + 307, 308, -1, 310, 311, -1, 313, -1, 315, 316, + 317, 318, 319, 320, -1, 322, -1, -1, 325, 326, + 327, -1, -1, 330, -1, -1, -1, 334, 335, 336, + 337, 338, 339, 340, 341, -1, 343, 344, 345, 346, + 347, 348, 349, -1, 351, 352, 353, 354, 355, 356, + 357, 358, 359, 360, 361, 362, -1, 364, 365, 366, + 367, 368, 369, 370, 371, 372, 373, -1, 375, 376, + -1, 378, 379, 380, 381, 382, 383, 384, 385, 386, + 387, 388, -1, 390, 391, 392, 393, 394, -1, 396, + 397, 398, 399, -1, 401, 402, 403, -1, 405, 406, + 407, 408, 409, 410, 411, 412, 413, 414, 415, -1, + 417, 418, -1, 420, 421, 422, 423, 424, 425, -1, + 427, 428, -1, -1, 431, 432, 433, 434, -1, 436, + 437, 438, 439, 440, 441, 442, -1, -1, 445, 446, + 447, 448, 449, -1, -1, 452, 453, 454, 455, 456, + 457, 458, -1, 460, -1, 462, 463, 464, -1, -1, + 467, -1, -1, 470, 471, 472, 473, 474, 475, 476, + 477, 478, 479, 480, 481, 482, 483, 484, 485, 486, + -1, -1, -1, -1, 6, 7, 8, 9, 10, 11, + 12, 13, -1, 15, 16, -1, 503, 19, 20, 21, + 22, 23, 24, -1, 26, 27, 28, -1, -1, 31, + 32, 33, 34, -1, -1, 37, 38, 39, 40, -1, + 42, -1, -1, 45, 46, -1, -1, -1, 50, 51, + -1, -1, -1, -1, 56, -1, -1, -1, -1, -1, + -1, -1, -1, 65, -1, 67, -1, 69, 70, 71, + -1, -1, -1, -1, -1, -1, -1, 79, 80, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 91, + 92, 93, 94, 95, 96, 97, 98, -1, 100, 101, + 102, -1, -1, -1, -1, -1, -1, -1, 110, 111, + -1, 113, 114, -1, 116, 117, 118, 119, 120, -1, + 122, 123, -1, 125, 126, 127, 128, 129, -1, -1, + 132, 133, 134, 135, 136, -1, 138, 139, 140, 141, + 142, -1, -1, -1, 146, 147, 148, 149, -1, 151, + 152, -1, 154, 155, 156, 157, 158, 159, -1, -1, + 162, -1, -1, -1, -1, -1, -1, -1, -1, 171, + 172, 173, 174, 175, 176, 177, 178, 179, -1, 181, + -1, 183, 184, 185, 186, 187, -1, 189, 190, 191, + -1, -1, 194, 195, 196, 197, 198, -1, 200, 201, + 202, -1, 204, 205, -1, 207, 208, 209, 210, 211, + 212, 213, 214, 215, -1, 217, -1, 219, 220, 221, + -1, 223, -1, 225, -1, -1, -1, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, -1, 244, 245, 246, -1, 248, 249, 250, 251, + 252, 253, -1, 255, -1, 257, -1, 259, 260, 261, + -1, 263, -1, 265, -1, 267, -1, -1, 270, -1, + 272, 273, 274, 275, 276, 277, 278, -1, 280, 281, + -1, 283, -1, -1, 286, 287, 288, -1, -1, 291, + 292, 293, 294, 295, 296, 297, 298, 299, 300, 301, + 302, 303, -1, 305, 306, 307, 308, -1, 310, 311, + -1, 313, -1, 315, 316, 317, 318, 319, 320, -1, + 322, -1, -1, 325, 326, 327, -1, -1, 330, -1, + -1, -1, 334, 335, 336, 337, 338, 339, 340, 341, + -1, 343, 344, 345, 346, 347, 348, 349, -1, 351, + 352, 353, 354, 355, 356, 357, 358, 359, 360, 361, + 362, -1, 364, 365, 366, 367, 368, 369, 370, 371, + 372, 373, -1, 375, 376, -1, 378, 379, 380, 381, + 382, 383, 384, 385, 386, 387, 388, -1, 390, 391, + 392, 393, 394, -1, 396, 397, 398, 399, -1, 401, + 402, 403, -1, 405, 406, 407, 408, 409, 410, 411, + 412, 413, 414, 415, -1, 417, 418, -1, 420, 421, + 422, 423, 424, 425, -1, 427, 428, -1, -1, 431, + 432, 433, 434, -1, 436, 437, 438, 439, 440, 441, + 442, -1, -1, 445, 446, 447, 448, 449, -1, -1, + 452, 453, 454, 455, 456, 457, 458, -1, 460, -1, + 462, 463, 464, -1, -1, 467, -1, -1, 470, 471, + 472, 473, 474, 475, 476, 477, 478, 479, 480, 481, + 482, 483, 484, 485, 486, -1, -1, -1, 5, 6, + 7, 8, 9, 10, 11, 12, 13, -1, 15, 16, + -1, 503, 19, 20, 21, 22, 23, 24, 25, 26, + 27, 28, 29, -1, 31, 32, 33, 34, 35, 36, + 37, 38, 39, 40, -1, 42, 43, 44, 45, 46, + -1, -1, -1, 50, 51, -1, -1, -1, -1, 56, + -1, -1, -1, -1, -1, -1, -1, -1, 65, -1, + 67, -1, 69, 70, 71, 72, -1, -1, 75, 76, + 77, 78, 79, 80, 81, 82, -1, -1, 85, 86, + -1, -1, -1, -1, 91, 92, 93, 94, 95, 96, + 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, + 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, + 117, 118, -1, 120, 121, 122, 123, 124, 125, 126, + 127, 128, 129, 130, 131, 132, 133, 134, 135, 136, + 137, 138, 139, 140, 141, -1, 143, 144, 145, 146, + 147, 148, 149, 150, 151, 152, 153, 154, 155, 156, + 157, 158, 159, 160, 161, 162, -1, 164, 165, 166, + 167, 168, 169, 170, 171, 172, 173, 174, 175, 176, + 177, 178, 179, 180, 181, 182, 183, 184, 185, 186, + 187, 188, 189, 190, 191, 192, 193, 194, 195, 196, + 197, 198, 199, 200, 201, 202, 203, 204, 205, 206, + 207, 208, 209, 210, -1, 212, 213, 214, -1, 216, + 217, 218, 219, 220, 221, 222, 223, 224, 225, 226, + 227, 228, 229, 230, 231, 232, 233, -1, 235, 236, + 237, 238, 239, 240, 241, 242, 243, 244, 245, 246, + 247, 248, 249, 250, 251, 252, 253, 254, 255, 256, + -1, -1, 259, 260, 261, 262, 263, 264, 265, 266, + 267, 268, 269, 270, 271, 272, 273, 274, 275, 276, + 277, 278, 279, 280, -1, 282, 283, 284, 285, 286, + 287, 288, 289, 290, 291, 292, 293, 294, 295, 296, + 297, 298, 299, 300, 301, 302, 303, 304, 305, 306, + 307, -1, 309, 310, 311, 312, 313, 314, -1, 316, + 317, 318, 319, 320, 321, 322, 323, 324, 325, 326, + 327, 328, 329, -1, 331, 332, 333, -1, 335, 336, + 337, 338, 339, 340, 341, 342, 343, -1, 345, -1, + 347, 348, 349, 350, 351, 352, 353, 354, 355, 356, + 357, 358, 359, 360, 361, 362, 363, 364, 365, 366, + 367, 368, 369, 370, 371, 372, 373, 374, 375, 376, + 377, 378, 379, -1, 381, 382, 383, 384, 385, 386, + 387, 388, 389, 390, 391, 392, 393, 394, 395, 396, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 407, 408, 409, 410, 411, 412, 413, 414, -1, 416, + 417, 418, 419, 420, 421, 422, 423, 424, 425, 426, + 427, 428, -1, 430, 431, -1, 433, -1, 435, 436, + 437, 438, 439, 440, 441, 442, -1, 444, 445, 446, + 447, 448, 449, 450, 451, 452, 453, 454, 455, 456, + -1, 458, 459, 460, 461, 462, 463, 464, 465, 466, + 467, 468, 469, 470, 471, 472, 473, 474, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 484, 485, 486, + -1, -1, -1, 490, 491, 492, -1, 494, 495, 496, + 497, 498, 499, 6, 7, 8, 9, 10, 11, 12, + 13, -1, 15, 16, -1, -1, 19, 20, 21, 22, + 23, 24, -1, 26, 27, 28, -1, -1, 31, 32, + 33, 34, -1, -1, 37, 38, 39, 40, -1, 42, + -1, -1, 45, 46, -1, -1, -1, 50, 51, -1, + -1, -1, -1, 56, -1, -1, -1, -1, -1, -1, + -1, -1, 65, -1, 67, -1, 69, 70, 71, -1, + -1, -1, -1, -1, -1, -1, 79, 80, -1, -1, + -1, -1, 85, -1, -1, -1, -1, -1, 91, 92, + 93, 94, 95, 96, 97, 98, -1, 100, 101, 102, + -1, -1, -1, -1, -1, -1, -1, 110, 111, -1, + 113, 114, -1, 116, 117, 118, 119, 120, -1, 122, + 123, -1, 125, 126, 127, 128, 129, -1, -1, 132, + 133, 134, 135, 136, -1, 138, 139, 140, 141, 142, + -1, -1, -1, 146, 147, 148, 149, -1, 151, 152, + -1, 154, 155, 156, 157, 158, 159, -1, -1, 162, + -1, -1, -1, -1, -1, -1, -1, -1, 171, 172, + 173, 174, 175, 176, 177, 178, 179, -1, 181, -1, + 183, 184, 185, 186, 187, -1, 189, 190, 191, -1, + -1, 194, 195, 196, 197, 198, -1, 200, 201, 202, + -1, 204, 205, -1, 207, 208, 209, 210, 211, 212, + 213, 214, 215, -1, 217, -1, 219, 220, 221, -1, + 223, -1, 225, -1, -1, -1, 229, 230, 231, -1, + 233, 234, -1, 236, -1, 238, 239, 240, 241, 242, + -1, 244, 245, 246, -1, 248, 249, 250, 251, 252, + 253, -1, 255, -1, 257, -1, 259, 260, 261, -1, + 263, -1, 265, -1, 267, -1, -1, 270, -1, 272, + 273, 274, 275, 276, 277, 278, -1, 280, 281, -1, + 283, -1, -1, 286, 287, 288, -1, -1, 291, 292, + 293, 294, 295, 296, 297, 298, 299, 300, 301, 302, + 303, -1, 305, 306, 307, 308, -1, 310, 311, -1, + 313, -1, 315, 316, 317, 318, 319, 320, -1, 322, + -1, -1, 325, 326, 327, -1, -1, 330, -1, -1, + -1, 334, 335, 336, 337, 338, 339, 340, 341, -1, + 343, 344, 345, 346, 347, 348, 349, -1, 351, 352, + 353, 354, 355, 356, 357, 358, 359, 360, 361, 362, + -1, 364, 365, 366, 367, 368, 369, 370, 371, 372, + 373, -1, 375, 376, -1, 378, 379, 380, 381, 382, + 383, 384, 385, 386, 387, 388, -1, 390, 391, 392, + 393, 394, -1, 396, 397, 398, 399, -1, 401, 402, + 403, -1, 405, 406, 407, 408, 409, 410, 411, 412, + 413, 414, 415, -1, 417, 418, -1, 420, 421, 422, + 423, 424, 425, -1, 427, 428, -1, -1, 431, 432, + 433, 434, -1, 436, 437, 438, 439, 440, 441, 442, + -1, -1, 445, 446, 447, 448, 449, -1, -1, 452, + 453, 454, 455, 456, 457, 458, -1, 460, -1, 462, + 463, 464, -1, -1, 467, -1, -1, 470, 471, 472, + 473, 474, 475, 476, 477, 478, 479, 480, 481, 482, + 483, 484, 485, 486, -1, -1, -1, 490, 491, 492, + -1, 494, 495, 496, 497, 498, 499, 6, 7, 8, + 9, 10, 11, 12, 13, -1, 15, 16, -1, -1, + 19, 20, 21, 22, 23, 24, -1, 26, 27, 28, + -1, -1, 31, 32, 33, 34, -1, -1, 37, 38, + 39, 40, -1, 42, -1, -1, 45, 46, -1, -1, + -1, 50, 51, -1, -1, -1, -1, 56, -1, -1, + -1, -1, -1, -1, -1, -1, 65, -1, 67, -1, + 69, 70, 71, -1, -1, -1, -1, -1, -1, -1, + 79, 80, -1, -1, -1, -1, 85, -1, -1, -1, + -1, -1, 91, 92, 93, 94, 95, 96, 97, 98, + -1, 100, 101, 102, -1, -1, -1, -1, -1, -1, + -1, 110, 111, -1, 113, 114, -1, 116, 117, 118, + 119, 120, -1, 122, 123, -1, 125, 126, 127, 128, + 129, -1, -1, 132, 133, 134, 135, 136, -1, 138, + 139, 140, 141, 142, -1, -1, -1, 146, 147, 148, + 149, -1, 151, 152, -1, 154, 155, 156, 157, 158, + 159, -1, -1, 162, -1, -1, -1, -1, -1, -1, + -1, -1, 171, 172, 173, 174, 175, 176, 177, 178, + 179, -1, 181, -1, 183, 184, 185, 186, 187, -1, + 189, 190, 191, -1, -1, 194, 195, 196, 197, 198, + -1, 200, 201, 202, -1, 204, 205, -1, 207, 208, + 209, 210, 211, 212, 213, 214, 215, -1, 217, -1, + 219, 220, 221, -1, 223, -1, 225, -1, -1, -1, + 229, 230, 231, -1, 233, 234, -1, 236, -1, 238, + 239, 240, 241, 242, -1, 244, 245, 246, -1, 248, + 249, 250, 251, 252, 253, -1, 255, -1, 257, -1, + 259, 260, 261, -1, 263, -1, 265, -1, 267, -1, + -1, 270, -1, 272, 273, 274, 275, 276, 277, 278, + -1, 280, 281, -1, 283, -1, -1, 286, 287, 288, + -1, -1, 291, 292, 293, 294, 295, 296, 297, 298, + 299, 300, 301, 302, 303, -1, 305, 306, 307, 308, + -1, 310, 311, -1, 313, -1, 315, 316, 317, 318, + 319, 320, -1, 322, -1, -1, 325, 326, 327, -1, + -1, 330, -1, -1, -1, 334, 335, 336, 337, 338, + 339, 340, 341, -1, 343, 344, 345, 346, 347, 348, + 349, -1, 351, 352, 353, 354, 355, 356, 357, 358, + 359, 360, 361, 362, -1, 364, 365, 366, 367, 368, + 369, 370, 371, 372, 373, -1, 375, 376, -1, 378, + 379, 380, 381, 382, 383, 384, 385, 386, 387, 388, + -1, 390, 391, 392, 393, 394, -1, 396, 397, 398, + 399, -1, 401, 402, 403, -1, 405, 406, 407, 408, + 409, 410, 411, 412, 413, 414, 415, -1, 417, 418, + -1, 420, 421, 422, 423, 424, 425, -1, 427, 428, + -1, -1, 431, 432, 433, 434, -1, 436, 437, 438, + 439, 440, 441, 442, -1, -1, 445, 446, 447, 448, + 449, -1, -1, 452, 453, 454, 455, 456, 457, 458, + -1, 460, -1, 462, 463, 464, -1, -1, 467, -1, + -1, 470, 471, 472, 473, 474, 475, 476, 477, 478, + 479, 480, 481, 482, 483, 484, 485, 486, -1, -1, + -1, 490, 491, 492, -1, 494, 495, 496, 497, 498, + 499, 6, 7, 8, 9, 10, 11, 12, 13, -1, + 15, 16, -1, -1, 19, 20, 21, 22, 23, 24, + -1, 26, 27, 28, -1, -1, 31, 32, 33, 34, + -1, -1, 37, 38, 39, 40, -1, 42, -1, -1, + 45, 46, -1, -1, -1, 50, 51, -1, -1, -1, + -1, 56, -1, -1, -1, -1, -1, -1, -1, -1, + 65, -1, 67, -1, 69, 70, 71, -1, -1, -1, + -1, -1, -1, -1, 79, 80, -1, -1, -1, -1, + 85, -1, -1, -1, -1, -1, 91, 92, 93, 94, + 95, 96, 97, 98, -1, 100, 101, 102, -1, -1, + -1, -1, -1, -1, -1, 110, 111, -1, 113, 114, + -1, 116, 117, 118, 119, 120, -1, 122, 123, -1, + 125, 126, 127, 128, 129, -1, -1, 132, 133, 134, + 135, 136, -1, 138, 139, 140, 141, 142, -1, -1, + -1, 146, 147, 148, 149, -1, 151, 152, -1, 154, + 155, 156, 157, 158, 159, -1, -1, 162, -1, -1, + -1, -1, -1, -1, -1, -1, 171, 172, 173, 174, + 175, 176, 177, 178, 179, -1, 181, -1, 183, 184, + 185, 186, 187, -1, 189, 190, 191, -1, -1, 194, + 195, 196, 197, 198, -1, 200, 201, 202, -1, 204, + 205, -1, 207, 208, 209, 210, 211, 212, 213, 214, + 215, -1, 217, -1, 219, 220, 221, -1, 223, -1, + 225, -1, -1, -1, 229, 230, 231, -1, 233, 234, + -1, 236, -1, 238, 239, 240, 241, 242, -1, 244, + 245, 246, -1, 248, 249, 250, 251, 252, 253, -1, + 255, -1, 257, -1, 259, 260, 261, -1, 263, -1, + 265, -1, 267, -1, -1, 270, -1, 272, 273, 274, + 275, 276, 277, 278, -1, 280, 281, -1, 283, -1, + -1, 286, 287, 288, -1, -1, 291, 292, 293, 294, + 295, 296, 297, 298, 299, 300, 301, 302, 303, -1, + 305, 306, 307, 308, -1, 310, 311, -1, 313, -1, + 315, 316, 317, 318, 319, 320, -1, 322, -1, -1, + 325, 326, 327, -1, -1, 330, -1, -1, -1, 334, + 335, 336, 337, 338, 339, 340, 341, -1, 343, 344, + 345, 346, 347, 348, 349, -1, 351, 352, 353, 354, + 355, 356, 357, 358, 359, 360, 361, 362, -1, 364, + 365, 366, 367, 368, 369, 370, 371, 372, 373, -1, + 375, 376, -1, 378, 379, 380, 381, 382, 383, 384, + 385, 386, 387, 388, -1, 390, 391, 392, 393, 394, + -1, 396, 397, 398, 399, -1, 401, 402, 403, -1, + 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, + 415, -1, 417, 418, -1, 420, 421, 422, 423, 424, + 425, -1, 427, 428, -1, -1, 431, 432, 433, 434, + -1, 436, 437, 438, 439, 440, 441, 442, -1, -1, + 445, 446, 447, 448, 449, -1, -1, 452, 453, 454, + 455, 456, 457, 458, -1, 460, -1, 462, 463, 464, + -1, -1, 467, -1, -1, 470, 471, 472, 473, 474, + 475, 476, 477, 478, 479, 480, 481, 482, 483, 484, + 485, 486, -1, -1, -1, 490, 491, 492, -1, 494, + 495, 496, 497, 498, 499, 6, 7, 8, 9, 10, + 11, 12, 13, -1, 15, 16, -1, -1, 19, 20, + 21, 22, 23, 24, -1, 26, 27, 28, -1, -1, + 31, 32, 33, 34, -1, -1, 37, 38, 39, 40, + -1, 42, -1, -1, 45, 46, -1, -1, -1, 50, + 51, -1, -1, -1, -1, 56, -1, -1, -1, -1, + -1, -1, -1, -1, 65, -1, 67, -1, 69, 70, + 71, -1, -1, -1, -1, -1, -1, -1, 79, 80, + -1, -1, -1, -1, 85, -1, -1, -1, -1, -1, + 91, 92, 93, 94, 95, 96, 97, 98, -1, 100, + 101, 102, -1, -1, -1, -1, -1, -1, -1, 110, + 111, -1, 113, 114, -1, 116, 117, 118, 119, 120, + -1, 122, 123, -1, 125, 126, 127, 128, 129, -1, + -1, 132, 133, 134, 135, 136, -1, 138, 139, 140, + 141, 142, -1, -1, -1, 146, 147, 148, 149, -1, + 151, 152, -1, 154, 155, 156, 157, 158, 159, -1, + -1, 162, -1, -1, -1, -1, -1, -1, -1, -1, + 171, 172, 173, 174, 175, 176, 177, 178, 179, -1, + 181, -1, 183, 184, 185, 186, 187, -1, 189, 190, + 191, -1, -1, 194, 195, 196, 197, 198, -1, 200, + 201, 202, -1, 204, 205, -1, 207, 208, 209, 210, + 211, 212, 213, 214, 215, -1, 217, -1, 219, 220, + 221, -1, 223, -1, 225, -1, -1, -1, 229, 230, + 231, -1, 233, 234, -1, 236, -1, 238, 239, 240, + 241, 242, -1, 244, 245, 246, -1, 248, 249, 250, + 251, 252, 253, -1, 255, -1, 257, -1, 259, 260, + 261, -1, 263, -1, 265, -1, 267, -1, -1, 270, + -1, 272, 273, 274, 275, 276, 277, 278, -1, 280, + 281, -1, 283, -1, -1, 286, 287, 288, -1, -1, + 291, 292, 293, 294, 295, 296, 297, 298, 299, 300, + 301, 302, 303, -1, 305, 306, 307, 308, -1, 310, + 311, -1, 313, -1, 315, 316, 317, 318, 319, 320, + -1, 322, -1, -1, 325, 326, 327, -1, -1, 330, + -1, -1, -1, 334, 335, 336, 337, 338, 339, 340, + 341, -1, 343, 344, 345, 346, 347, 348, 349, -1, + 351, 352, 353, 354, 355, 356, 357, 358, 359, 360, + 361, 362, -1, 364, 365, 366, 367, 368, 369, 370, + 371, 372, 373, -1, 375, 376, -1, 378, 379, 380, + 381, 382, 383, 384, 385, 386, 387, 388, -1, 390, + 391, 392, 393, 394, -1, 396, 397, 398, 399, -1, + 401, 402, 403, -1, 405, 406, 407, 408, 409, 410, + 411, 412, 413, 414, 415, -1, 417, 418, -1, 420, + 421, 422, 423, 424, 425, -1, 427, 428, -1, -1, + 431, 432, 433, 434, -1, 436, 437, 438, 439, 440, + 441, 442, -1, -1, 445, 446, 447, 448, 449, -1, + -1, 452, 453, 454, 455, 456, 457, 458, -1, 460, + -1, 462, 463, 464, -1, -1, 467, -1, -1, 470, + 471, 472, 473, 474, 475, 476, 477, 478, 479, 480, + 481, 482, 483, 484, 485, 486, -1, -1, -1, 490, + 491, 492, -1, 494, 495, 496, 497, 498, 499, 6, + 7, 8, 9, 10, 11, 12, 13, -1, 15, 16, + -1, -1, 19, 20, 21, 22, 23, 24, -1, 26, + 27, 28, -1, -1, 31, 32, 33, 34, -1, -1, + 37, 38, 39, 40, -1, 42, -1, -1, 45, 46, + -1, -1, -1, 50, 51, -1, -1, -1, -1, 56, + -1, -1, -1, -1, -1, -1, -1, -1, 65, -1, + 67, -1, 69, 70, 71, -1, -1, -1, -1, -1, + -1, -1, 79, 80, -1, -1, -1, -1, 85, -1, + -1, -1, -1, -1, 91, 92, 93, 94, 95, 96, + 97, 98, -1, 100, 101, 102, -1, -1, -1, -1, + -1, -1, -1, 110, 111, -1, 113, 114, -1, 116, + 117, 118, 119, 120, -1, 122, 123, -1, 125, 126, + 127, 128, 129, -1, -1, 132, 133, 134, 135, 136, + -1, 138, 139, 140, 141, 142, -1, -1, -1, 146, + 147, 148, 149, -1, 151, 152, -1, 154, 155, 156, + 157, 158, 159, -1, -1, 162, -1, -1, -1, -1, + -1, -1, -1, -1, 171, 172, 173, 174, 175, 176, + 177, 178, 179, -1, 181, -1, 183, 184, 185, 186, + 187, -1, 189, 190, 191, -1, -1, 194, 195, 196, + 197, 198, -1, 200, 201, 202, -1, 204, 205, -1, + 207, 208, 209, 210, 211, 212, 213, 214, 215, -1, + 217, -1, 219, 220, 221, -1, 223, -1, 225, -1, + -1, -1, 229, 230, 231, -1, 233, 234, -1, 236, + -1, 238, 239, 240, 241, 242, -1, 244, 245, 246, + -1, 248, 249, 250, 251, 252, 253, -1, 255, -1, + 257, -1, 259, 260, 261, -1, 263, -1, 265, -1, + 267, -1, -1, 270, -1, 272, 273, 274, 275, 276, + 277, 278, -1, 280, 281, -1, 283, -1, -1, 286, + 287, 288, -1, -1, 291, 292, 293, 294, 295, 296, + 297, 298, 299, 300, 301, 302, 303, -1, 305, 306, + 307, 308, -1, 310, 311, -1, 313, -1, 315, 316, + 317, 318, 319, 320, -1, 322, -1, -1, 325, 326, + 327, -1, -1, 330, -1, -1, -1, 334, 335, 336, + 337, 338, 339, 340, 341, -1, 343, 344, 345, 346, + 347, 348, 349, -1, 351, 352, 353, 354, 355, 356, + 357, 358, 359, 360, 361, 362, -1, 364, 365, 366, + 367, 368, 369, 370, 371, 372, 373, -1, 375, 376, + -1, 378, 379, 380, 381, 382, 383, 384, 385, 386, + 387, 388, -1, 390, 391, 392, 393, 394, -1, 396, + 397, 398, 399, -1, 401, 402, 403, -1, 405, 406, + 407, 408, 409, 410, 411, 412, 413, 414, 415, -1, + 417, 418, -1, 420, 421, 422, 423, 424, 425, -1, + 427, 428, -1, -1, 431, 432, 433, 434, -1, 436, + 437, 438, 439, 440, 441, 442, -1, -1, 445, 446, + 447, 448, 449, -1, -1, 452, 453, 454, 455, 456, + 457, 458, -1, 460, -1, 462, 463, 464, -1, -1, + 467, -1, -1, 470, 471, 472, 473, 474, 475, 476, + 477, 478, 479, 480, 481, 482, 483, 484, 485, 486, + -1, -1, -1, 490, 491, 492, -1, 494, 495, 496, + 497, 498, 499, 6, 7, 8, 9, 10, 11, 12, + 13, -1, 15, 16, -1, -1, 19, 20, 21, 22, + 23, 24, -1, 26, 27, 28, -1, -1, 31, 32, + 33, 34, -1, -1, 37, 38, 39, 40, -1, 42, + -1, -1, 45, 46, -1, -1, -1, 50, 51, -1, + -1, -1, -1, 56, -1, -1, -1, -1, -1, -1, + -1, -1, 65, -1, 67, -1, 69, 70, 71, -1, + -1, -1, -1, -1, -1, -1, 79, 80, -1, -1, + -1, -1, 85, -1, -1, -1, -1, -1, 91, 92, + 93, 94, 95, 96, 97, 98, -1, 100, 101, 102, + -1, -1, -1, -1, -1, -1, -1, 110, 111, -1, + 113, 114, -1, 116, 117, 118, 119, 120, -1, 122, + 123, -1, 125, 126, 127, 128, 129, -1, -1, 132, + 133, 134, 135, 136, -1, 138, 139, 140, 141, 142, + -1, -1, -1, 146, 147, 148, 149, -1, 151, 152, + -1, 154, 155, 156, 157, 158, 159, -1, -1, 162, + -1, -1, -1, -1, -1, -1, -1, -1, 171, 172, + 173, 174, 175, 176, 177, 178, 179, -1, 181, -1, + 183, 184, 185, 186, 187, -1, 189, 190, 191, -1, + -1, 194, 195, 196, 197, 198, -1, 200, 201, 202, + -1, 204, 205, -1, 207, 208, 209, 210, 211, 212, + 213, 214, 215, -1, 217, -1, 219, 220, 221, -1, + 223, -1, 225, -1, -1, -1, 229, 230, 231, -1, + 233, 234, -1, 236, -1, 238, 239, 240, 241, 242, + -1, 244, 245, 246, -1, 248, 249, 250, 251, 252, + 253, -1, 255, -1, 257, -1, 259, 260, 261, -1, + 263, -1, 265, -1, 267, -1, -1, 270, -1, 272, + 273, 274, 275, 276, 277, 278, -1, 280, 281, -1, + 283, -1, -1, 286, 287, 288, -1, -1, 291, 292, + 293, 294, 295, 296, 297, 298, 299, 300, 301, 302, + 303, -1, 305, 306, 307, 308, -1, 310, 311, -1, + 313, -1, 315, 316, 317, 318, 319, 320, -1, 322, + -1, -1, 325, 326, 327, -1, -1, 330, -1, -1, + -1, 334, 335, 336, 337, 338, 339, 340, 341, -1, + 343, 344, 345, 346, 347, 348, 349, -1, 351, 352, + 353, 354, 355, 356, 357, 358, 359, 360, 361, 362, + -1, 364, 365, 366, 367, 368, 369, 370, 371, 372, + 373, -1, 375, 376, -1, 378, 379, 380, 381, 382, + 383, 384, 385, 386, 387, 388, -1, 390, 391, 392, + 393, 394, -1, 396, 397, 398, 399, -1, 401, 402, + 403, -1, 405, 406, 407, 408, 409, 410, 411, 412, + 413, 414, 415, -1, 417, 418, -1, 420, 421, 422, + 423, 424, 425, -1, 427, 428, -1, -1, 431, 432, + 433, 434, -1, 436, 437, 438, 439, 440, 441, 442, + -1, -1, 445, 446, 447, 448, 449, -1, -1, 452, + 453, 454, 455, 456, 457, 458, -1, 460, -1, 462, + 463, 464, -1, -1, 467, -1, -1, 470, 471, 472, + 473, 474, 475, 476, 477, 478, 479, 480, 481, 482, + 483, 484, 485, 486, -1, -1, -1, 490, 491, 492, + -1, 494, 495, 496, 497, 498, 499, 6, 7, 8, + 9, 10, 11, 12, 13, -1, 15, 16, -1, -1, + 19, 20, 21, 22, 23, 24, -1, 26, 27, 28, + -1, -1, 31, 32, 33, 34, -1, -1, 37, 38, + 39, 40, -1, 42, -1, -1, 45, 46, -1, -1, + -1, 50, 51, -1, -1, -1, -1, 56, -1, -1, + -1, -1, -1, -1, -1, -1, 65, -1, 67, -1, + 69, 70, 71, -1, -1, -1, -1, -1, -1, -1, + 79, 80, -1, -1, -1, -1, 85, -1, -1, -1, + -1, -1, 91, 92, 93, 94, 95, 96, 97, 98, + -1, 100, 101, 102, -1, -1, -1, -1, -1, -1, + -1, 110, 111, -1, 113, 114, -1, 116, 117, 118, + 119, 120, -1, 122, 123, -1, 125, 126, 127, 128, + 129, -1, -1, 132, 133, 134, 135, 136, -1, 138, + 139, 140, 141, 142, -1, -1, -1, 146, 147, 148, + 149, -1, 151, 152, -1, 154, 155, 156, 157, 158, + 159, -1, -1, 162, -1, -1, -1, -1, -1, -1, + -1, -1, 171, 172, 173, 174, 175, 176, 177, 178, + 179, -1, 181, -1, 183, 184, 185, 186, 187, -1, + 189, 190, 191, -1, -1, 194, 195, 196, 197, 198, + -1, 200, 201, 202, -1, 204, 205, -1, 207, 208, + 209, 210, 211, 212, 213, 214, 215, -1, 217, -1, + 219, 220, 221, -1, 223, -1, 225, -1, -1, -1, + 229, 230, 231, -1, 233, 234, -1, 236, -1, 238, + 239, 240, 241, 242, -1, 244, 245, 246, -1, 248, + 249, 250, 251, 252, 253, -1, 255, -1, 257, -1, + 259, 260, 261, -1, 263, -1, 265, -1, 267, -1, + -1, 270, -1, 272, 273, 274, 275, 276, 277, 278, + -1, 280, 281, -1, 283, -1, -1, 286, 287, 288, + -1, -1, 291, 292, 293, 294, 295, 296, 297, 298, + 299, 300, 301, 302, 303, -1, 305, 306, 307, 308, + -1, 310, 311, -1, 313, -1, 315, 316, 317, 318, + 319, 320, -1, 322, -1, -1, 325, 326, 327, -1, + -1, 330, -1, -1, -1, 334, 335, 336, 337, 338, + 339, 340, 341, -1, 343, 344, 345, 346, 347, 348, + 349, -1, 351, 352, 353, 354, 355, 356, 357, 358, + 359, 360, 361, 362, -1, 364, 365, 366, 367, 368, + 369, 370, 371, 372, 373, -1, 375, 376, -1, 378, + 379, 380, 381, 382, 383, 384, 385, 386, 387, 388, + -1, 390, 391, 392, 393, 394, -1, 396, 397, 398, + 399, -1, 401, 402, 403, -1, 405, 406, 407, 408, + 409, 410, 411, 412, 413, 414, 415, -1, 417, 418, + -1, 420, 421, 422, 423, 424, 425, -1, 427, 428, + -1, -1, 431, 432, 433, 434, -1, 436, 437, 438, + 439, 440, 441, 442, -1, -1, 445, 446, 447, 448, + 449, -1, -1, 452, 453, 454, 455, 456, 457, 458, + -1, 460, -1, 462, 463, 464, -1, -1, 467, -1, + -1, 470, 471, 472, 473, 474, 475, 476, 477, 478, + 479, 480, 481, 482, 483, 484, 485, 486, -1, -1, + -1, 490, 491, 492, -1, 494, 495, 496, 497, 498, + 499, 5, 6, 7, 8, 9, 10, 11, 12, 13, + -1, 15, 16, -1, -1, 19, 20, 21, 22, 23, + 24, 25, 26, 27, 28, 29, -1, 31, 32, 33, + 34, 35, 36, 37, 38, 39, 40, -1, 42, 43, + 44, 45, 46, -1, -1, -1, 50, 51, -1, -1, + -1, -1, 56, -1, -1, -1, -1, -1, -1, -1, + -1, 65, -1, 67, -1, 69, 70, 71, -1, -1, + -1, -1, -1, -1, -1, 79, 80, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 91, 92, 93, + 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, + 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, + 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, + 124, 125, 126, 127, 128, 129, 130, 131, 132, 133, + 134, 135, 136, 137, 138, 139, 140, 141, 142, 143, + 144, 145, 146, 147, 148, 149, 150, 151, 152, 153, + 154, 155, 156, 157, 158, 159, 160, 161, 162, 163, + 164, 165, 166, 167, 168, 169, 170, 171, 172, 173, + 174, 175, 176, 177, 178, 179, 180, 181, 182, 183, + 184, 185, 186, 187, 188, 189, 190, 191, 192, 193, + 194, 195, 196, 197, 198, 199, 200, 201, 202, 203, + 204, 205, 206, 207, 208, 209, 210, 211, 212, 213, + 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, 227, 228, 229, 230, 231, 232, 233, + 234, 235, 236, 237, 238, 239, 240, 241, 242, 243, + 244, 245, 246, 247, 248, 249, 250, 251, 252, 253, + 254, 255, 256, 257, 258, 259, 260, 261, 262, 263, + 264, 265, 266, 267, 268, 269, 270, 271, 272, 273, + 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, + 284, 285, 286, 287, 288, 289, 290, 291, 292, 293, + 294, 295, 296, 297, 298, 299, 300, 301, 302, 303, + 304, 305, 306, 307, 308, 309, 310, 311, 312, 313, + 314, 315, 316, 317, 318, 319, 320, 321, 322, 323, + 324, 325, 326, 327, 328, 329, 330, 331, 332, 333, + 334, 335, 336, 337, 338, 339, 340, 341, 342, 343, + 344, 345, 346, 347, 348, 349, 350, 351, 352, 353, + 354, 355, 356, 357, 358, 359, 360, 361, 362, 363, + 364, 365, 366, 367, 368, 369, 370, 371, 372, 373, + 374, 375, 376, 377, 378, 379, 380, 381, 382, 383, + 384, 385, 386, 387, 388, 389, 390, 391, 392, 393, + 394, 395, 396, 397, 398, 399, 400, 401, 402, 403, + 404, 405, 406, 407, 408, 409, 410, 411, 412, 413, + 414, 415, 416, 417, 418, 419, 420, 421, 422, 423, + 424, 425, 426, 427, 428, 429, 430, 431, 432, 433, + 434, 435, 436, 437, 438, 439, 440, 441, 442, 443, + 444, 445, 446, 447, 448, 449, 450, 451, 452, 453, + 454, 455, 456, 457, 458, 459, 460, 461, 462, 463, + 464, 465, 466, 467, 468, 469, 470, 471, 472, 473, + 474, 475, 476, 477, 478, 479, 480, 481, 482, 483, + 484, 485, 486, 5, 6, 7, 8, 9, 10, 11, + 12, 13, 496, 15, 16, -1, -1, 19, 20, 21, + 22, 23, 24, 25, 26, 27, 28, 29, -1, 31, + 32, 33, 34, 35, 36, 37, 38, 39, 40, -1, + 42, 43, 44, 45, 46, -1, -1, -1, 50, 51, + -1, -1, -1, -1, 56, -1, -1, -1, -1, -1, + -1, -1, -1, 65, -1, 67, -1, 69, 70, 71, + -1, -1, -1, -1, -1, -1, -1, 79, 80, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 91, + 92, 93, 94, 95, 96, 97, 98, -1, 100, 101, + 102, -1, -1, -1, -1, -1, -1, -1, 110, 111, + -1, 113, 114, 115, 116, 117, 118, -1, 120, 121, + 122, 123, -1, 125, 126, 127, 128, 129, -1, -1, + 132, 133, 134, 135, 136, -1, 138, 139, 140, 141, + -1, -1, 144, -1, 146, 147, 148, 149, 150, 151, + 152, -1, 154, 155, 156, 157, 158, 159, -1, 161, + 162, -1, -1, -1, -1, 167, -1, -1, -1, 171, + 172, 173, 174, 175, 176, 177, 178, 179, -1, 181, + -1, 183, 184, 185, 186, 187, -1, 189, 190, 191, + -1, -1, 194, 195, 196, 197, 198, -1, 200, 201, + 202, -1, 204, 205, -1, 207, 208, 209, 210, -1, + 212, 213, 214, -1, -1, 217, -1, 219, 220, 221, + -1, 223, -1, 225, 226, -1, 228, 229, 230, 231, + -1, 233, -1, -1, 236, -1, 238, 239, 240, 241, + 242, 243, 244, 245, 246, -1, 248, 249, 250, 251, + 252, 253, -1, 255, 256, -1, -1, 259, 260, 261, + 262, 263, -1, 265, -1, 267, 268, 269, 270, 271, + 272, 273, 274, 275, 276, 277, 278, -1, 280, -1, + 282, 283, 284, -1, 286, 287, 288, -1, -1, 291, + 292, 293, 294, 295, 296, 297, 298, 299, 300, 301, + 302, 303, 304, 305, 306, 307, -1, -1, 310, 311, + 312, 313, -1, -1, 316, 317, 318, 319, 320, -1, + 322, -1, -1, 325, 326, 327, -1, -1, -1, 331, + 332, 333, -1, 335, 336, 337, 338, 339, 340, 341, + -1, 343, -1, 345, -1, 347, 348, 349, -1, 351, + 352, 353, 354, 355, 356, 357, 358, 359, 360, 361, + 362, -1, 364, 365, 366, 367, 368, 369, 370, 371, + 372, 373, -1, 375, 376, 377, 378, 379, -1, 381, + 382, 383, 384, 385, 386, 387, 388, -1, 390, 391, + 392, 393, 394, -1, 396, 397, 398, 399, 400, 401, + 402, 403, -1, 405, 406, 407, 408, 409, 410, 411, + 412, 413, 414, -1, -1, 417, 418, -1, 420, 421, + 422, 423, 424, 425, -1, 427, 428, -1, -1, 431, + -1, 433, -1, -1, 436, 437, 438, 439, 440, 441, + 442, -1, -1, 445, 446, 447, 448, 449, -1, -1, + 452, 453, 454, 455, 456, -1, 458, -1, 460, 461, + 462, 463, 464, -1, -1, 467, -1, -1, 470, 471, + 472, 473, 474, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 484, 485, 486, -1, 6, 7, 8, 9, + 10, 11, 12, 13, 496, 15, 16, -1, -1, 19, + 20, 21, 22, 23, 24, -1, 26, 27, 28, -1, + -1, 31, 32, 33, 34, -1, -1, 37, 38, 39, + 40, -1, 42, -1, -1, 45, 46, -1, -1, -1, + 50, 51, -1, -1, -1, -1, 56, -1, -1, -1, + -1, -1, -1, -1, -1, 65, -1, 67, -1, 69, + 70, 71, -1, -1, -1, -1, -1, -1, -1, 79, + 80, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 91, 92, 93, 94, 95, 96, 97, 98, -1, + 100, 101, 102, -1, -1, -1, -1, -1, -1, -1, + 110, 111, -1, 113, 114, -1, 116, 117, 118, 119, + 120, -1, 122, 123, -1, 125, 126, 127, 128, 129, + -1, -1, 132, 133, 134, 135, 136, -1, 138, 139, + 140, 141, 142, -1, -1, -1, 146, 147, 148, 149, + -1, 151, 152, -1, 154, 155, 156, 157, 158, 159, + -1, -1, 162, -1, -1, -1, -1, -1, -1, -1, + -1, 171, 172, 173, 174, 175, 176, 177, 178, 179, + -1, 181, -1, 183, 184, 185, 186, 187, -1, 189, + 190, 191, -1, -1, 194, 195, 196, 197, 198, -1, + 200, 201, 202, -1, 204, 205, -1, 207, 208, 209, + 210, 211, 212, 213, 214, 215, -1, 217, -1, 219, + 220, 221, -1, 223, -1, 225, -1, -1, -1, 229, + 230, 231, -1, 233, 234, -1, 236, -1, 238, 239, + 240, 241, 242, -1, 244, 245, 246, -1, 248, 249, + 250, 251, 252, 253, -1, 255, -1, 257, -1, 259, + 260, 261, -1, 263, -1, 265, -1, 267, -1, -1, + 270, -1, 272, 273, 274, 275, 276, 277, 278, -1, + 280, 281, -1, 283, -1, -1, 286, 287, 288, -1, + -1, 291, 292, 293, 294, 295, 296, 297, 298, 299, + 300, 301, 302, 303, -1, 305, 306, 307, 308, -1, + 310, 311, -1, 313, -1, 315, 316, 317, 318, 319, + 320, -1, 322, -1, -1, 325, 326, 327, -1, -1, + 330, -1, -1, -1, 334, 335, 336, 337, 338, 339, + 340, 341, -1, 343, 344, 345, 346, 347, 348, 349, + -1, 351, 352, 353, 354, 355, 356, 357, 358, 359, + 360, 361, 362, -1, 364, 365, 366, 367, 368, 369, + 370, 371, 372, 373, -1, 375, 376, -1, 378, 379, + 380, 381, 382, 383, 384, 385, 386, 387, 388, -1, + 390, 391, 392, 393, 394, -1, 396, 397, 398, 399, + -1, 401, 402, 403, -1, 405, 406, 407, 408, 409, + 410, 411, 412, 413, 414, 415, -1, 417, 418, -1, + 420, 421, 422, 423, 424, 425, -1, 427, 428, -1, + -1, 431, 432, 433, 434, -1, 436, 437, 438, 439, + 440, 441, 442, -1, -1, 445, 446, 447, 448, 449, + -1, -1, 452, 453, 454, 455, 456, 457, 458, -1, + 460, -1, 462, 463, 464, -1, -1, 467, -1, -1, + 470, 471, 472, 473, 474, 475, 476, 477, 478, 479, + 480, 481, 482, 483, 484, 485, 486, -1, 6, 7, + 8, 9, 10, 11, 12, 13, 496, 15, 16, -1, + -1, 19, 20, 21, 22, 23, 24, -1, 26, 27, + 28, -1, -1, 31, 32, 33, 34, -1, -1, 37, + 38, 39, 40, -1, 42, -1, -1, 45, 46, -1, + -1, -1, 50, 51, -1, -1, -1, -1, 56, -1, + -1, -1, -1, -1, -1, -1, -1, 65, -1, 67, + -1, 69, 70, 71, -1, -1, -1, -1, -1, -1, + -1, 79, 80, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 91, 92, 93, 94, 95, 96, 97, + 98, -1, 100, 101, 102, -1, -1, -1, -1, -1, + -1, -1, 110, 111, -1, 113, 114, -1, 116, 117, + 118, 119, 120, -1, 122, 123, -1, 125, 126, 127, + 128, 129, -1, -1, 132, 133, 134, 135, 136, -1, + 138, 139, 140, 141, 142, -1, -1, -1, 146, 147, + 148, 149, -1, 151, 152, -1, 154, 155, 156, 157, + 158, 159, -1, -1, 162, -1, -1, -1, -1, -1, + -1, -1, -1, 171, 172, 173, 174, 175, 176, 177, + 178, 179, -1, 181, -1, 183, 184, 185, 186, 187, + -1, 189, 190, 191, -1, -1, 194, 195, 196, 197, + 198, -1, 200, 201, 202, -1, 204, 205, -1, 207, + 208, 209, 210, 211, 212, 213, 214, 215, -1, 217, + -1, 219, 220, 221, -1, 223, -1, 225, -1, -1, + -1, 229, 230, 231, -1, 233, 234, -1, 236, -1, + 238, 239, 240, 241, 242, -1, 244, 245, 246, -1, + 248, 249, 250, 251, 252, 253, -1, 255, -1, 257, + -1, 259, 260, 261, -1, 263, -1, 265, -1, 267, + -1, -1, 270, -1, 272, 273, 274, 275, 276, 277, + 278, -1, 280, 281, -1, 283, -1, -1, 286, 287, + 288, -1, -1, 291, 292, 293, 294, 295, 296, 297, + 298, 299, 300, 301, 302, 303, -1, 305, 306, 307, + 308, -1, 310, 311, -1, 313, -1, 315, 316, 317, + 318, 319, 320, -1, 322, -1, -1, 325, 326, 327, + -1, -1, 330, -1, -1, -1, 334, 335, 336, 337, + 338, 339, 340, 341, -1, 343, 344, 345, 346, 347, + 348, 349, -1, 351, 352, 353, 354, 355, 356, 357, + 358, 359, 360, 361, 362, -1, 364, 365, 366, 367, + 368, 369, 370, 371, 372, 373, -1, 375, 376, -1, + 378, 379, 380, 381, 382, 383, 384, 385, 386, 387, + 388, -1, 390, 391, 392, 393, 394, -1, 396, 397, + 398, 399, -1, 401, 402, 403, -1, 405, 406, 407, + 408, 409, 410, 411, 412, 413, 414, 415, -1, 417, + 418, -1, 420, 421, 422, 423, 424, 425, -1, 427, + 428, -1, -1, 431, 432, 433, 434, -1, 436, 437, + 438, 439, 440, 441, 442, -1, -1, 445, 446, 447, + 448, 449, -1, -1, 452, 453, 454, 455, 456, 457, + 458, -1, 460, -1, 462, 463, 464, -1, -1, 467, + -1, -1, 470, 471, 472, 473, 474, 475, 476, 477, + 478, 479, 480, 481, 482, 483, 484, 485, 486, -1, + 6, 7, 8, 9, 10, 11, 12, 13, 496, 15, + 16, -1, -1, 19, 20, 21, 22, 23, 24, -1, + 26, 27, 28, -1, -1, 31, 32, 33, 34, -1, + -1, 37, 38, 39, 40, -1, 42, -1, -1, 45, + 46, -1, -1, -1, 50, 51, -1, -1, -1, -1, + 56, -1, -1, -1, -1, -1, -1, -1, -1, 65, + -1, 67, -1, 69, 70, 71, 72, -1, -1, 75, + 76, 77, 78, 79, 80, 81, 82, -1, -1, -1, + 86, -1, -1, -1, -1, 91, 92, 93, 94, 95, + 96, 97, 98, -1, 100, 101, 102, -1, -1, -1, + -1, -1, -1, -1, 110, 111, -1, 113, 114, -1, + 116, 117, 118, 119, 120, -1, 122, 123, -1, 125, + 126, 127, 128, 129, -1, -1, 132, 133, 134, 135, + 136, -1, 138, 139, 140, 141, 142, -1, -1, -1, + 146, 147, 148, 149, -1, 151, 152, -1, 154, 155, + 156, 157, 158, 159, -1, -1, 162, -1, -1, -1, + -1, -1, -1, -1, -1, 171, 172, 173, 174, 175, + 176, 177, 178, 179, 180, 181, -1, 183, 184, 185, + 186, 187, -1, 189, 190, 191, -1, -1, 194, 195, + 196, 197, 198, -1, 200, 201, 202, -1, 204, 205, + -1, 207, 208, 209, 210, 211, 212, 213, 214, 215, + 216, 217, -1, 219, 220, 221, -1, 223, -1, 225, + -1, -1, -1, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, -1, 244, 245, + 246, -1, 248, 249, 250, 251, 252, 253, -1, 255, + -1, 257, -1, 259, 260, 261, -1, 263, -1, 265, + -1, 267, -1, -1, 270, -1, 272, 273, 274, 275, + 276, 277, 278, -1, 280, 281, -1, 283, -1, -1, + 286, 287, 288, -1, -1, 291, 292, 293, 294, 295, + 296, 297, 298, 299, 300, 301, 302, 303, -1, 305, + 306, 307, 308, -1, 310, 311, -1, 313, -1, 315, + 316, 317, 318, 319, 320, -1, 322, 323, -1, 325, + 326, 327, -1, -1, 330, -1, -1, -1, 334, 335, + 336, 337, 338, 339, 340, 341, -1, 343, 344, 345, + 346, 347, 348, 349, -1, 351, 352, 353, 354, 355, + 356, 357, 358, 359, 360, 361, 362, -1, 364, 365, + 366, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, -1, 378, 379, 380, 381, 382, 383, 384, 385, + 386, 387, 388, -1, 390, 391, 392, 393, 394, -1, + 396, 397, 398, 399, -1, 401, 402, 403, -1, 405, + 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, + -1, 417, 418, -1, 420, 421, 422, 423, 424, 425, + -1, 427, 428, -1, -1, 431, 432, 433, 434, 435, + 436, 437, 438, 439, 440, 441, 442, -1, -1, 445, + 446, 447, 448, 449, -1, -1, 452, 453, 454, 455, + 456, 457, 458, -1, 460, -1, 462, 463, 464, -1, + -1, 467, -1, -1, 470, 471, 472, 473, 474, 475, + 476, 477, 478, 479, 480, 481, 482, 483, 484, 485, + 486, -1, -1, -1, -1, -1, -1, -1, 494, 495, + 6, 7, 8, 9, 10, 11, 12, 13, -1, 15, + 16, -1, -1, 19, 20, 21, 22, 23, 24, -1, + 26, 27, 28, -1, -1, 31, 32, 33, 34, -1, + -1, 37, 38, 39, 40, -1, 42, -1, -1, 45, + 46, -1, -1, -1, 50, 51, -1, -1, -1, -1, + 56, -1, -1, -1, -1, -1, -1, -1, -1, 65, + -1, 67, -1, 69, 70, 71, 72, -1, -1, 75, + 76, 77, 78, 79, 80, 81, 82, -1, -1, -1, + 86, -1, -1, -1, -1, 91, 92, 93, 94, 95, + 96, 97, 98, -1, 100, 101, 102, -1, -1, -1, + -1, -1, -1, -1, 110, 111, -1, 113, 114, -1, + 116, 117, 118, 119, 120, -1, 122, 123, -1, 125, + 126, 127, 128, 129, -1, -1, 132, 133, 134, 135, + 136, -1, 138, 139, 140, 141, 142, -1, -1, -1, + 146, 147, 148, 149, -1, 151, 152, -1, 154, 155, + 156, 157, 158, 159, -1, -1, 162, -1, -1, -1, + -1, -1, -1, -1, -1, 171, 172, 173, 174, 175, + 176, 177, 178, 179, 180, 181, -1, 183, 184, 185, + 186, 187, -1, 189, 190, 191, -1, -1, 194, 195, + 196, 197, 198, -1, 200, 201, 202, -1, 204, 205, + -1, 207, 208, 209, 210, 211, 212, 213, 214, 215, + 216, 217, -1, 219, 220, 221, -1, 223, -1, 225, + -1, -1, -1, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, -1, 244, 245, + 246, -1, 248, 249, 250, 251, 252, 253, -1, 255, + -1, 257, -1, 259, 260, 261, -1, 263, -1, 265, + -1, 267, -1, -1, 270, -1, 272, 273, 274, 275, + 276, 277, 278, -1, 280, 281, -1, 283, -1, -1, + 286, 287, 288, -1, -1, 291, 292, 293, 294, 295, + 296, 297, 298, 299, 300, 301, 302, 303, -1, 305, + 306, 307, 308, -1, 310, 311, -1, 313, -1, 315, + 316, 317, 318, 319, 320, -1, 322, 323, -1, 325, + 326, 327, -1, -1, 330, -1, -1, -1, 334, 335, + 336, 337, 338, 339, 340, 341, -1, 343, 344, 345, + 346, 347, 348, 349, -1, 351, 352, 353, 354, 355, + 356, 357, 358, 359, 360, 361, 362, -1, 364, 365, + 366, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, -1, 378, 379, 380, 381, 382, 383, 384, 385, + 386, 387, 388, -1, 390, 391, 392, 393, 394, -1, + 396, 397, 398, 399, -1, 401, 402, 403, -1, 405, + 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, + -1, 417, 418, -1, 420, 421, 422, 423, 424, 425, + -1, 427, 428, -1, -1, 431, 432, 433, 434, 435, + 436, 437, 438, 439, 440, 441, 442, -1, -1, 445, + 446, 447, 448, 449, -1, -1, 452, 453, 454, 455, + 456, 457, 458, -1, 460, -1, 462, 463, 464, -1, + -1, 467, -1, -1, 470, 471, 472, 473, 474, 475, + 476, 477, 478, 479, 480, 481, 482, 483, 484, 485, + 486, -1, -1, -1, -1, -1, -1, -1, 494, 495, + 6, 7, 8, 9, 10, 11, 12, 13, -1, 15, + 16, -1, -1, 19, 20, 21, 22, 23, 24, -1, + 26, 27, 28, -1, -1, 31, 32, 33, 34, -1, + -1, 37, 38, 39, 40, -1, 42, -1, -1, 45, + 46, -1, -1, -1, 50, 51, -1, -1, -1, -1, + 56, -1, -1, -1, -1, -1, -1, -1, -1, 65, + -1, 67, -1, 69, 70, 71, 72, -1, -1, 75, + 76, 77, 78, 79, 80, 81, 82, -1, -1, -1, + 86, -1, -1, -1, -1, 91, 92, 93, 94, 95, + 96, 97, 98, -1, 100, 101, 102, -1, -1, -1, + -1, -1, -1, -1, 110, 111, -1, 113, 114, -1, + 116, 117, 118, 119, 120, -1, 122, 123, -1, 125, + 126, 127, 128, 129, -1, -1, 132, 133, 134, 135, + 136, -1, 138, 139, 140, 141, 142, -1, -1, -1, + 146, 147, 148, 149, -1, 151, 152, -1, 154, 155, + 156, 157, 158, 159, -1, -1, 162, -1, -1, -1, + -1, -1, -1, -1, -1, 171, 172, 173, 174, 175, + 176, 177, 178, 179, -1, 181, -1, 183, 184, 185, + 186, 187, -1, 189, 190, 191, -1, -1, 194, 195, + 196, 197, 198, -1, 200, 201, 202, -1, 204, 205, + -1, 207, 208, 209, 210, 211, 212, 213, 214, 215, + 216, 217, -1, 219, 220, 221, -1, 223, -1, 225, + -1, -1, -1, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, -1, 244, 245, + 246, -1, 248, 249, 250, 251, 252, 253, -1, 255, + -1, 257, -1, 259, 260, 261, -1, 263, -1, 265, + -1, 267, -1, -1, 270, -1, 272, 273, 274, 275, + 276, 277, 278, -1, 280, 281, -1, 283, -1, -1, + 286, 287, 288, -1, -1, 291, 292, 293, 294, 295, + 296, 297, 298, 299, 300, 301, 302, 303, -1, 305, + 306, 307, 308, -1, 310, 311, -1, 313, -1, 315, + 316, 317, 318, 319, 320, -1, 322, 323, -1, 325, + 326, 327, -1, -1, 330, -1, -1, -1, 334, 335, + 336, 337, 338, 339, 340, 341, -1, 343, 344, 345, + 346, 347, 348, 349, -1, 351, 352, 353, 354, 355, + 356, 357, 358, 359, 360, 361, 362, -1, 364, 365, + 366, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, -1, 378, 379, 380, 381, 382, 383, 384, 385, + 386, 387, 388, -1, 390, 391, 392, 393, 394, -1, + 396, 397, 398, 399, -1, 401, 402, 403, -1, 405, + 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, + -1, 417, 418, -1, 420, 421, 422, 423, 424, 425, + -1, 427, 428, -1, -1, 431, 432, 433, 434, 435, + 436, 437, 438, 439, 440, 441, 442, -1, -1, 445, + 446, 447, 448, 449, -1, -1, 452, 453, 454, 455, + 456, 457, 458, -1, 460, -1, 462, 463, 464, -1, + -1, 467, -1, -1, 470, 471, 472, 473, 474, 475, + 476, 477, 478, 479, 480, 481, 482, 483, 484, 485, + 486, -1, -1, -1, -1, -1, -1, -1, 494, 495, + 6, 7, 8, 9, 10, 11, 12, 13, -1, 15, + 16, -1, -1, 19, 20, 21, 22, 23, 24, -1, + 26, 27, 28, -1, -1, 31, 32, 33, 34, -1, + -1, 37, 38, 39, 40, -1, 42, -1, -1, 45, + 46, -1, -1, -1, 50, 51, -1, -1, -1, -1, + 56, -1, -1, -1, -1, -1, -1, -1, -1, 65, + -1, 67, -1, 69, 70, 71, 72, -1, -1, -1, + -1, -1, -1, 79, 80, -1, -1, -1, -1, -1, + 86, -1, -1, -1, -1, 91, 92, 93, 94, 95, + 96, 97, 98, 99, 100, 101, 102, -1, -1, -1, + -1, -1, -1, -1, 110, 111, -1, 113, 114, -1, + 116, 117, 118, 119, 120, -1, 122, 123, -1, 125, + 126, 127, 128, 129, -1, -1, 132, 133, 134, 135, + 136, -1, 138, 139, 140, 141, 142, -1, -1, -1, + 146, 147, 148, 149, -1, 151, 152, -1, 154, 155, + 156, 157, 158, 159, -1, -1, 162, -1, -1, -1, + -1, -1, -1, -1, -1, 171, 172, 173, 174, 175, + 176, 177, 178, 179, -1, 181, -1, 183, 184, 185, + 186, 187, -1, 189, 190, 191, -1, -1, 194, 195, + 196, 197, 198, -1, 200, 201, 202, -1, 204, 205, + -1, 207, 208, 209, 210, 211, 212, 213, 214, 215, + -1, 217, -1, 219, 220, 221, -1, 223, -1, 225, + -1, 227, -1, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, -1, 244, 245, + 246, 247, 248, 249, 250, 251, 252, 253, -1, 255, + -1, 257, -1, 259, 260, 261, -1, 263, -1, 265, + -1, 267, -1, -1, 270, -1, 272, 273, 274, 275, + 276, 277, 278, -1, 280, 281, -1, 283, -1, -1, + 286, 287, 288, -1, -1, 291, 292, 293, 294, 295, + 296, 297, 298, 299, 300, 301, 302, 303, -1, 305, + 306, 307, 308, -1, 310, 311, -1, 313, -1, 315, + 316, 317, 318, 319, 320, -1, 322, -1, -1, 325, + 326, 327, -1, -1, 330, -1, -1, -1, 334, 335, + 336, 337, 338, 339, 340, 341, -1, 343, 344, 345, + 346, 347, 348, 349, -1, 351, 352, 353, 354, 355, + 356, 357, 358, 359, 360, 361, 362, -1, 364, 365, + 366, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, -1, 378, 379, 380, 381, 382, 383, 384, 385, + 386, 387, 388, -1, 390, 391, 392, 393, 394, -1, + 396, 397, 398, 399, -1, 401, 402, 403, -1, 405, + 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, + -1, 417, 418, -1, 420, 421, 422, 423, 424, 425, + -1, 427, 428, -1, -1, 431, 432, 433, 434, -1, + 436, 437, 438, 439, 440, 441, 442, -1, -1, 445, + 446, 447, 448, 449, -1, -1, 452, 453, 454, 455, + 456, 457, 458, -1, 460, -1, 462, 463, 464, -1, + -1, 467, -1, -1, 470, 471, 472, 473, 474, 475, + 476, 477, 478, 479, 480, 481, 482, 483, 484, 485, + 486, -1, -1, -1, -1, -1, -1, -1, 494, 495, + 6, 7, 8, 9, 10, 11, 12, 13, -1, 15, + 16, -1, -1, 19, 20, 21, 22, 23, 24, -1, + 26, 27, 28, -1, -1, 31, 32, 33, 34, -1, + -1, 37, 38, 39, 40, -1, 42, -1, -1, 45, + 46, -1, -1, -1, 50, 51, -1, -1, -1, -1, + 56, -1, -1, -1, -1, -1, -1, -1, -1, 65, + -1, 67, -1, 69, 70, 71, 72, -1, -1, -1, + -1, -1, -1, 79, 80, -1, -1, -1, -1, -1, + 86, -1, -1, -1, -1, 91, 92, 93, 94, 95, + 96, 97, 98, 99, 100, 101, 102, -1, -1, -1, + -1, -1, -1, -1, 110, 111, -1, 113, 114, -1, + 116, 117, 118, 119, 120, -1, 122, 123, -1, 125, + 126, 127, 128, 129, -1, -1, 132, 133, 134, 135, + 136, -1, 138, 139, 140, 141, 142, -1, -1, -1, + 146, 147, 148, 149, -1, 151, 152, -1, 154, 155, + 156, 157, 158, 159, -1, -1, 162, -1, -1, -1, + -1, -1, -1, -1, -1, 171, 172, 173, 174, 175, + 176, 177, 178, 179, -1, 181, -1, 183, 184, 185, + 186, 187, -1, 189, 190, 191, -1, -1, 194, 195, + 196, 197, 198, -1, 200, 201, 202, -1, 204, 205, + -1, 207, 208, 209, 210, 211, 212, 213, 214, 215, + -1, 217, -1, 219, 220, 221, -1, 223, -1, 225, + -1, 227, -1, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, -1, 244, 245, + 246, 247, 248, 249, 250, 251, 252, 253, -1, 255, + -1, 257, -1, 259, 260, 261, -1, 263, -1, 265, + -1, 267, -1, -1, 270, -1, 272, 273, 274, 275, + 276, 277, 278, -1, 280, 281, -1, 283, -1, -1, + 286, 287, 288, -1, -1, 291, 292, 293, 294, 295, + 296, 297, 298, 299, 300, 301, 302, 303, -1, 305, + 306, 307, 308, -1, 310, 311, -1, 313, -1, 315, + 316, 317, 318, 319, 320, -1, 322, -1, -1, 325, + 326, 327, -1, -1, 330, -1, -1, -1, 334, 335, + 336, 337, 338, 339, 340, 341, -1, 343, 344, 345, + 346, 347, 348, 349, -1, 351, 352, 353, 354, 355, + 356, 357, 358, 359, 360, 361, 362, -1, 364, 365, + 366, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, -1, 378, 379, 380, 381, 382, 383, 384, 385, + 386, 387, 388, -1, 390, 391, 392, 393, 394, -1, + 396, 397, 398, 399, -1, 401, 402, 403, -1, 405, + 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, + -1, 417, 418, -1, 420, 421, 422, 423, 424, 425, + -1, 427, 428, -1, -1, 431, 432, 433, 434, -1, + 436, 437, 438, 439, 440, 441, 442, -1, -1, 445, + 446, 447, 448, 449, -1, -1, 452, 453, 454, 455, + 456, 457, 458, -1, 460, -1, 462, 463, 464, -1, + -1, 467, -1, -1, 470, 471, 472, 473, 474, 475, + 476, 477, 478, 479, 480, 481, 482, 483, 484, 485, + 486, -1, -1, -1, -1, -1, -1, -1, 494, 495, + 6, 7, 8, 9, 10, 11, 12, 13, -1, 15, + 16, -1, -1, 19, 20, 21, 22, 23, 24, -1, + 26, 27, 28, -1, -1, 31, 32, 33, 34, -1, + -1, 37, 38, 39, 40, -1, 42, -1, -1, 45, + 46, -1, -1, -1, 50, 51, -1, -1, -1, -1, + 56, -1, -1, -1, -1, -1, -1, -1, -1, 65, + -1, 67, -1, 69, 70, 71, 72, -1, -1, -1, + -1, -1, -1, 79, 80, -1, -1, -1, -1, -1, + 86, -1, -1, -1, -1, 91, 92, 93, 94, 95, + 96, 97, 98, 99, 100, 101, 102, -1, -1, -1, + -1, -1, -1, -1, 110, 111, -1, 113, 114, -1, + 116, 117, 118, 119, 120, -1, 122, 123, -1, 125, + 126, 127, 128, 129, -1, -1, 132, 133, 134, 135, + 136, -1, 138, 139, 140, 141, 142, -1, -1, -1, + 146, 147, 148, 149, -1, 151, 152, -1, 154, 155, + 156, 157, 158, 159, -1, -1, 162, -1, -1, -1, + -1, -1, -1, -1, -1, 171, 172, 173, 174, 175, + 176, 177, 178, 179, -1, 181, -1, 183, 184, 185, + 186, 187, -1, 189, 190, 191, -1, -1, 194, 195, + 196, 197, 198, -1, 200, 201, 202, -1, 204, 205, + -1, 207, 208, 209, 210, 211, 212, 213, 214, 215, + -1, 217, -1, 219, 220, 221, -1, 223, -1, 225, + -1, 227, -1, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, -1, 244, 245, + 246, 247, 248, 249, 250, 251, 252, 253, -1, 255, + -1, 257, -1, 259, 260, 261, -1, 263, -1, 265, + -1, 267, -1, -1, 270, -1, 272, 273, 274, 275, + 276, 277, 278, -1, 280, 281, -1, 283, -1, -1, + 286, 287, 288, -1, -1, 291, 292, 293, 294, 295, + 296, 297, 298, 299, 300, 301, 302, 303, -1, 305, + 306, 307, 308, -1, 310, 311, -1, 313, -1, 315, + 316, 317, 318, 319, 320, -1, 322, -1, -1, 325, + 326, 327, -1, -1, 330, -1, -1, -1, 334, 335, + 336, 337, 338, 339, 340, 341, -1, 343, 344, 345, + 346, 347, 348, 349, -1, 351, 352, 353, 354, 355, + 356, 357, 358, 359, 360, 361, 362, -1, 364, 365, + 366, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, -1, 378, 379, 380, 381, 382, 383, 384, 385, + 386, 387, 388, -1, 390, 391, 392, 393, 394, -1, + 396, 397, 398, 399, -1, 401, 402, 403, -1, 405, + 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, + -1, 417, 418, -1, 420, 421, 422, 423, 424, 425, + -1, 427, 428, -1, -1, 431, 432, 433, 434, -1, + 436, 437, 438, 439, 440, 441, 442, -1, -1, 445, + 446, 447, 448, 449, -1, -1, 452, 453, 454, 455, + 456, 457, 458, -1, 460, -1, 462, 463, 464, -1, + -1, 467, -1, -1, 470, 471, 472, 473, 474, 475, + 476, 477, 478, 479, 480, 481, 482, 483, 484, 485, + 486, -1, -1, -1, -1, -1, -1, -1, 494, 495, + 6, 7, 8, 9, 10, 11, 12, 13, -1, 15, + 16, -1, -1, 19, 20, 21, 22, 23, 24, -1, + 26, 27, 28, -1, -1, 31, 32, 33, 34, -1, + -1, 37, 38, 39, 40, -1, 42, -1, -1, 45, + 46, -1, -1, -1, 50, 51, -1, -1, -1, -1, + 56, -1, -1, -1, -1, -1, -1, -1, -1, 65, + -1, 67, -1, 69, 70, 71, 72, -1, -1, -1, + -1, -1, -1, 79, 80, -1, -1, -1, -1, -1, + 86, -1, -1, -1, -1, 91, 92, 93, 94, 95, + 96, 97, 98, 99, 100, 101, 102, -1, -1, -1, + -1, -1, -1, -1, 110, 111, -1, 113, 114, -1, + 116, 117, 118, 119, 120, -1, 122, 123, -1, 125, + 126, 127, 128, 129, -1, -1, 132, 133, 134, 135, + 136, -1, 138, 139, 140, 141, 142, -1, -1, -1, + 146, 147, 148, 149, -1, 151, 152, -1, 154, 155, + 156, 157, 158, 159, -1, -1, 162, -1, -1, -1, + -1, -1, -1, -1, -1, 171, 172, 173, 174, 175, + 176, 177, 178, 179, -1, 181, -1, 183, 184, 185, + 186, 187, -1, 189, 190, 191, -1, -1, 194, 195, + 196, 197, 198, -1, 200, 201, 202, -1, 204, 205, + -1, 207, 208, 209, 210, 211, 212, 213, 214, 215, + -1, 217, -1, 219, 220, 221, -1, 223, -1, 225, + -1, 227, -1, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, -1, 244, 245, + 246, 247, 248, 249, 250, 251, 252, 253, -1, 255, + -1, 257, -1, 259, 260, 261, -1, 263, -1, 265, + -1, 267, -1, -1, 270, -1, 272, 273, 274, 275, + 276, 277, 278, -1, 280, 281, -1, 283, -1, -1, + 286, 287, 288, -1, -1, 291, 292, 293, 294, 295, + 296, 297, 298, 299, 300, 301, 302, 303, -1, 305, + 306, 307, 308, -1, 310, 311, -1, 313, -1, 315, + 316, 317, 318, 319, 320, -1, 322, -1, -1, 325, + 326, 327, -1, -1, 330, -1, -1, -1, 334, 335, + 336, 337, 338, 339, 340, 341, -1, 343, 344, 345, + 346, 347, 348, 349, -1, 351, 352, 353, 354, 355, + 356, 357, 358, 359, 360, 361, 362, -1, 364, 365, + 366, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, -1, 378, 379, 380, 381, 382, 383, 384, 385, + 386, 387, 388, -1, 390, 391, 392, 393, 394, -1, + 396, 397, 398, 399, -1, 401, 402, 403, -1, 405, + 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, + -1, 417, 418, -1, 420, 421, 422, 423, 424, 425, + -1, 427, 428, -1, -1, 431, 432, 433, 434, -1, + 436, 437, 438, 439, 440, 441, 442, -1, -1, 445, + 446, 447, 448, 449, -1, -1, 452, 453, 454, 455, + 456, 457, 458, -1, 460, -1, 462, 463, 464, -1, + -1, 467, -1, -1, 470, 471, 472, 473, 474, 475, + 476, 477, 478, 479, 480, 481, 482, 483, 484, 485, + 486, -1, -1, -1, -1, -1, -1, -1, 494, 495, + 6, 7, 8, 9, 10, 11, 12, 13, -1, 15, + 16, -1, -1, 19, 20, 21, 22, 23, 24, -1, + 26, 27, 28, -1, -1, 31, 32, 33, 34, -1, + -1, 37, 38, 39, 40, -1, 42, -1, -1, 45, + 46, -1, -1, -1, 50, 51, -1, -1, -1, -1, + 56, -1, -1, -1, -1, -1, -1, -1, -1, 65, + -1, 67, -1, 69, 70, 71, 72, -1, -1, -1, + -1, -1, -1, 79, 80, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 91, 92, 93, 94, 95, + 96, 97, 98, -1, 100, 101, 102, -1, -1, -1, + -1, -1, -1, -1, 110, 111, -1, 113, 114, -1, + 116, 117, 118, 119, 120, -1, 122, 123, -1, 125, + 126, 127, 128, 129, -1, -1, 132, 133, 134, 135, + 136, -1, 138, 139, 140, 141, 142, -1, -1, -1, + 146, 147, 148, 149, -1, 151, 152, -1, 154, 155, + 156, 157, 158, 159, -1, -1, 162, -1, -1, -1, + -1, -1, -1, -1, -1, 171, 172, 173, 174, 175, + 176, 177, 178, 179, 180, 181, -1, 183, 184, 185, + 186, 187, -1, 189, 190, 191, -1, -1, 194, 195, + 196, 197, 198, -1, 200, 201, 202, -1, 204, 205, + -1, 207, 208, 209, 210, 211, 212, 213, 214, 215, + -1, 217, -1, 219, 220, 221, -1, 223, -1, 225, + -1, -1, -1, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, -1, 244, 245, + 246, -1, 248, 249, 250, 251, 252, 253, -1, 255, + -1, 257, -1, 259, 260, 261, -1, 263, -1, 265, + -1, 267, -1, -1, 270, -1, 272, 273, 274, 275, + 276, 277, 278, -1, 280, 281, -1, 283, -1, -1, + 286, 287, 288, -1, -1, 291, 292, 293, 294, 295, + 296, 297, 298, 299, 300, 301, 302, 303, -1, 305, + 306, 307, 308, -1, 310, 311, -1, 313, -1, 315, + 316, 317, 318, 319, 320, -1, 322, -1, -1, 325, + 326, 327, -1, -1, 330, -1, -1, -1, 334, 335, + 336, 337, 338, 339, 340, 341, -1, 343, 344, 345, + 346, 347, 348, 349, -1, 351, 352, 353, 354, 355, + 356, 357, 358, 359, 360, 361, 362, -1, 364, 365, + 366, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, -1, 378, 379, 380, 381, 382, 383, 384, 385, + 386, 387, 388, -1, 390, 391, 392, 393, 394, -1, + 396, 397, 398, 399, -1, 401, 402, 403, -1, 405, + 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, + -1, 417, 418, -1, 420, 421, 422, 423, 424, 425, + -1, 427, 428, 429, -1, 431, 432, 433, 434, -1, + 436, 437, 438, 439, 440, 441, 442, -1, -1, 445, + 446, 447, 448, 449, -1, -1, 452, 453, 454, 455, + 456, 457, 458, -1, 460, -1, 462, 463, 464, -1, + -1, 467, -1, -1, 470, 471, 472, 473, 474, 475, + 476, 477, 478, 479, 480, 481, 482, 483, 484, 485, + 486, -1, -1, 4, 490, 6, 7, 8, 9, 10, + 11, 12, 13, 14, 15, 16, -1, -1, 19, 20, + 21, 22, 23, 24, -1, 26, 27, 28, -1, -1, + 31, 32, 33, 34, -1, -1, 37, 38, 39, 40, + -1, 42, -1, -1, 45, 46, -1, -1, -1, 50, + 51, -1, -1, -1, -1, 56, -1, -1, -1, -1, + -1, -1, -1, -1, 65, -1, 67, -1, 69, 70, + 71, -1, -1, -1, -1, -1, -1, -1, 79, 80, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 91, 92, 93, 94, 95, 96, 97, 98, -1, 100, + 101, 102, -1, -1, -1, -1, -1, -1, -1, 110, + 111, -1, 113, 114, -1, 116, 117, 118, 119, 120, + -1, 122, 123, -1, 125, 126, 127, 128, 129, -1, + -1, 132, 133, 134, 135, 136, -1, 138, 139, 140, + 141, 142, -1, -1, -1, 146, 147, 148, 149, -1, + 151, 152, -1, 154, 155, 156, 157, 158, 159, -1, + -1, 162, -1, -1, -1, -1, -1, -1, -1, -1, + 171, 172, 173, 174, 175, 176, 177, 178, 179, -1, + 181, -1, 183, 184, 185, 186, 187, -1, 189, 190, + 191, -1, -1, 194, 195, 196, 197, 198, -1, 200, + 201, 202, -1, 204, 205, -1, 207, 208, 209, 210, + 211, 212, 213, 214, 215, -1, 217, -1, 219, 220, + 221, -1, 223, -1, 225, -1, -1, -1, 229, 230, + 231, -1, 233, 234, -1, 236, -1, 238, 239, 240, + 241, 242, -1, 244, 245, 246, -1, 248, 249, 250, + 251, 252, 253, -1, 255, -1, 257, -1, 259, 260, + 261, -1, 263, -1, 265, -1, 267, -1, -1, 270, + -1, 272, 273, 274, 275, 276, 277, 278, -1, 280, + 281, -1, 283, -1, -1, 286, 287, 288, -1, -1, + 291, 292, 293, 294, 295, 296, 297, 298, 299, 300, + 301, 302, 303, -1, 305, 306, 307, 308, -1, 310, + 311, -1, 313, -1, 315, 316, 317, 318, 319, 320, + -1, 322, -1, -1, 325, 326, 327, -1, -1, 330, + -1, -1, -1, 334, 335, 336, 337, 338, 339, 340, + 341, -1, 343, 344, 345, 346, 347, 348, 349, -1, + 351, 352, 353, 354, 355, 356, 357, 358, 359, 360, + 361, 362, -1, 364, 365, 366, 367, 368, 369, 370, + 371, 372, 373, -1, 375, 376, -1, 378, 379, 380, + 381, 382, 383, 384, 385, 386, 387, 388, -1, 390, + 391, 392, 393, 394, -1, 396, 397, 398, 399, -1, + 401, 402, 403, -1, 405, 406, 407, 408, 409, 410, + 411, 412, 413, 414, 415, -1, 417, 418, -1, 420, + 421, 422, 423, 424, 425, -1, 427, 428, -1, -1, + 431, 432, 433, 434, -1, 436, 437, 438, 439, 440, + 441, 442, -1, -1, 445, 446, 447, 448, 449, -1, + -1, 452, 453, 454, 455, 456, 457, 458, -1, 460, + -1, 462, 463, 464, -1, -1, 467, -1, -1, 470, + 471, 472, 473, 474, 475, 476, 477, 478, 479, 480, + 481, 482, 483, 484, 485, 486, 5, 6, 7, 8, + 9, 10, 11, 12, 13, -1, 15, 16, -1, -1, + 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, + 29, -1, 31, 32, 33, 34, 35, 36, 37, 38, + 39, 40, -1, 42, 43, 44, 45, 46, -1, -1, + -1, 50, 51, -1, -1, -1, -1, 56, -1, -1, + -1, -1, -1, -1, -1, -1, 65, -1, 67, -1, + 69, 70, 71, -1, -1, -1, 75, 76, 77, 78, + 79, 80, 81, 82, -1, -1, -1, 86, -1, -1, + -1, -1, 91, 92, 93, 94, 95, 96, 97, 98, + 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, + 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, + 119, 120, 121, 122, 123, 124, 125, 126, 127, 128, + 129, 130, 131, 132, 133, 134, 135, 136, 137, 138, + 139, 140, 141, 142, 143, 144, 145, 146, 147, 148, + 149, 150, 151, 152, 153, 154, 155, 156, 157, 158, + 159, 160, 161, 162, 163, 164, 165, 166, 167, 168, + 169, 170, 171, 172, 173, 174, 175, 176, 177, 178, + 179, 180, 181, 182, 183, 184, 185, 186, 187, 188, + 189, 190, 191, 192, 193, 194, 195, 196, 197, 198, + 199, 200, 201, 202, 203, 204, 205, 206, 207, 208, + 209, 210, 211, 212, 213, 214, 215, 216, 217, 218, + 219, 220, 221, 222, 223, 224, 225, 226, 227, 228, + 229, 230, 231, 232, 233, 234, 235, 236, 237, 238, + 239, 240, 241, 242, 243, 244, 245, 246, 247, 248, + 249, 250, 251, 252, 253, 254, 255, 256, 257, 258, + 259, 260, 261, 262, 263, 264, 265, 266, 267, 268, + 269, 270, 271, 272, 273, 274, 275, 276, 277, 278, + 279, 280, 281, 282, 283, 284, 285, 286, 287, 288, + 289, 290, 291, 292, 293, 294, 295, 296, 297, 298, + 299, 300, 301, 302, 303, 304, 305, 306, 307, 308, + 309, 310, 311, 312, 313, 314, 315, 316, 317, 318, + 319, 320, 321, 322, 323, 324, 325, 326, 327, 328, + 329, 330, 331, 332, 333, 334, 335, 336, 337, 338, + 339, 340, 341, 342, 343, 344, 345, 346, 347, 348, + 349, 350, 351, 352, 353, 354, 355, 356, 357, 358, + 359, 360, 361, 362, 363, 364, 365, 366, 367, 368, + 369, 370, 371, 372, 373, 374, 375, 376, 377, 378, + 379, 380, 381, 382, 383, 384, 385, 386, 387, 388, + 389, 390, 391, 392, 393, 394, 395, 396, 397, 398, + 399, 400, 401, 402, 403, 404, 405, 406, 407, 408, + 409, 410, 411, 412, 413, 414, 415, 416, 417, 418, + 419, 420, 421, 422, 423, 424, 425, 426, 427, 428, + 429, 430, 431, 432, 433, 434, 435, 436, 437, 438, + 439, 440, 441, 442, 443, 444, 445, 446, 447, 448, + 449, 450, 451, 452, 453, 454, 455, 456, 457, 458, + 459, 460, 461, 462, 463, 464, 465, 466, 467, 468, + 469, 470, 471, 472, 473, 474, 475, 476, 477, 478, + 479, 480, 481, 482, 483, 484, 485, 486, 5, 6, + 7, 8, 9, 10, 11, 12, 13, -1, 15, 16, + -1, -1, 19, 20, 21, 22, 23, 24, 25, 26, + 27, 28, 29, -1, 31, 32, 33, 34, 35, 36, + 37, 38, 39, 40, -1, 42, 43, 44, 45, 46, + -1, -1, -1, 50, 51, -1, -1, -1, -1, 56, + -1, -1, -1, -1, -1, -1, -1, -1, 65, -1, + 67, -1, 69, 70, 71, -1, -1, -1, -1, -1, + -1, -1, 79, 80, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 91, 92, 93, 94, 95, 96, + 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, + 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, + 117, 118, 119, 120, 121, 122, 123, 124, 125, 126, + 127, 128, 129, 130, 131, 132, 133, 134, 135, 136, + 137, 138, 139, 140, 141, 142, 143, 144, 145, 146, + 147, 148, 149, 150, 151, 152, 153, 154, 155, 156, + 157, 158, 159, 160, 161, 162, 163, 164, 165, 166, + 167, 168, 169, 170, 171, 172, 173, 174, 175, 176, + 177, 178, 179, 180, 181, 182, 183, 184, 185, 186, + 187, 188, 189, 190, 191, 192, 193, 194, 195, 196, + 197, 198, 199, 200, 201, 202, 203, 204, 205, 206, + 207, 208, 209, 210, 211, 212, 213, 214, 215, 216, + 217, 218, 219, 220, 221, 222, 223, 224, 225, 226, + 227, 228, 229, 230, 231, 232, 233, 234, 235, 236, + 237, 238, 239, 240, 241, 242, 243, 244, 245, 246, + 247, 248, 249, 250, 251, 252, 253, 254, 255, 256, + 257, 258, 259, 260, 261, 262, 263, 264, 265, 266, + 267, 268, 269, 270, 271, 272, 273, 274, 275, 276, + 277, 278, 279, 280, 281, 282, 283, 284, 285, 286, + 287, 288, 289, 290, 291, 292, 293, 294, 295, 296, + 297, 298, 299, 300, 301, 302, 303, 304, 305, 306, + 307, 308, 309, 310, 311, 312, 313, 314, 315, 316, + 317, 318, 319, 320, 321, 322, 323, 324, 325, 326, + 327, 328, 329, 330, 331, 332, 333, 334, 335, 336, + 337, 338, 339, 340, 341, 342, 343, 344, 345, 346, + 347, 348, 349, 350, 351, 352, 353, 354, 355, 356, + 357, 358, 359, 360, 361, 362, 363, 364, 365, 366, + 367, 368, 369, 370, 371, 372, 373, 374, 375, 376, + 377, 378, 379, 380, 381, 382, 383, 384, 385, 386, + 387, 388, 389, 390, 391, 392, 393, 394, 395, 396, + 397, 398, 399, 400, 401, 402, 403, 404, 405, 406, + 407, 408, 409, 410, 411, 412, 413, 414, 415, 416, + 417, 418, 419, 420, 421, 422, 423, 424, 425, 426, + 427, 428, 429, 430, 431, 432, 433, 434, 435, 436, + 437, 438, 439, 440, 441, 442, 443, 444, 445, 446, + 447, 448, 449, 450, 451, 452, 453, 454, 455, 456, + 457, 458, 459, 460, 461, 462, 463, 464, 465, 466, + 467, 468, 469, 470, 471, 472, 473, 474, 475, 476, + 477, 478, 479, 480, 481, 482, 483, 484, 485, 486, + 5, 6, 7, 8, 9, 10, 11, 12, 13, -1, + 15, 16, -1, -1, 19, 20, 21, 22, 23, 24, + 25, 26, 27, 28, 29, -1, 31, 32, 33, 34, + 35, 36, 37, 38, 39, 40, -1, 42, 43, 44, + 45, 46, -1, -1, -1, 50, 51, -1, -1, -1, + -1, 56, -1, -1, -1, -1, -1, -1, -1, -1, + 65, -1, 67, -1, 69, 70, 71, -1, -1, -1, + -1, -1, -1, -1, 79, 80, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 91, 92, 93, 94, + 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, + 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, + 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, + 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, + 135, 136, 137, 138, 139, 140, 141, 142, 143, 144, + 145, 146, 147, 148, 149, 150, 151, 152, 153, 154, + 155, 156, 157, 158, 159, 160, 161, 162, 163, 164, + 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, + 175, 176, 177, 178, 179, 180, 181, 182, 183, 184, + 185, 186, 187, 188, 189, 190, 191, 192, 193, 194, + 195, 196, 197, 198, 199, 200, 201, 202, 203, 204, + 205, 206, 207, 208, 209, 210, 211, 212, 213, 214, + 215, 216, 217, 218, 219, 220, 221, 222, 223, 224, + 225, 226, 227, 228, 229, 230, 231, 232, 233, 234, + 235, 236, 237, 238, 239, 240, 241, 242, 243, 244, + 245, 246, 247, 248, 249, 250, 251, 252, 253, 254, + 255, 256, 257, 258, 259, 260, 261, 262, 263, 264, + 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, + 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, + 285, 286, 287, 288, 289, 290, 291, 292, 293, 294, + 295, 296, 297, 298, 299, 300, 301, 302, 303, 304, + 305, 306, 307, 308, 309, 310, 311, 312, 313, 314, + 315, 316, 317, 318, 319, 320, 321, 322, 323, 324, + 325, 326, 327, 328, 329, 330, 331, 332, 333, 334, + 335, 336, 337, 338, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 351, 352, 353, 354, + 355, 356, 357, 358, 359, 360, 361, 362, 363, 364, + 365, 366, 367, 368, 369, 370, 371, 372, 373, 374, + 375, 376, 377, 378, 379, 380, 381, 382, 383, 384, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + 395, 396, 397, 398, 399, 400, 401, 402, 403, 404, + 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, + 415, 416, 417, 418, 419, 420, 421, 422, 423, 424, + 425, 426, 427, 428, 429, 430, 431, 432, 433, 434, + 435, 436, 437, 438, 439, 440, 441, 442, 443, 444, + 445, 446, 447, 448, 449, 450, 451, 452, 453, 454, + 455, 456, 457, 458, 459, 460, 461, 462, 463, 464, + 465, 466, 467, 468, 469, 470, 471, 472, 473, 474, + 475, 476, 477, 478, 479, 480, 481, 482, 483, 484, + 485, 486, 5, 6, 7, 8, 9, 10, 11, 12, + 13, -1, 15, 16, -1, -1, 19, 20, 21, 22, + 23, 24, 25, 26, 27, 28, 29, -1, 31, 32, + 33, 34, 35, 36, 37, 38, 39, 40, -1, 42, + 43, 44, 45, 46, -1, -1, -1, 50, 51, -1, + -1, -1, -1, 56, -1, -1, -1, -1, -1, -1, + -1, -1, 65, -1, 67, -1, 69, 70, 71, -1, + -1, -1, -1, -1, -1, -1, 79, 80, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 91, 92, + 93, 94, 95, 96, 97, 98, -1, 100, 101, 102, + -1, -1, -1, -1, -1, -1, -1, 110, 111, -1, + 113, 114, 115, 116, 117, 118, 119, 120, 121, 122, + 123, -1, 125, 126, 127, 128, 129, -1, -1, 132, + 133, 134, 135, 136, -1, 138, 139, 140, 141, 142, + -1, 144, -1, 146, 147, 148, 149, 150, 151, 152, + -1, 154, 155, 156, 157, 158, 159, -1, 161, 162, + -1, -1, -1, -1, 167, -1, -1, -1, 171, 172, + 173, 174, 175, 176, 177, 178, 179, -1, 181, -1, + 183, 184, 185, 186, 187, -1, 189, 190, 191, -1, + -1, 194, 195, 196, 197, 198, -1, 200, 201, 202, + -1, 204, 205, -1, 207, 208, 209, 210, 211, 212, + 213, 214, 215, -1, 217, -1, 219, 220, 221, -1, + 223, -1, 225, 226, -1, 228, 229, 230, 231, -1, + 233, 234, -1, 236, -1, 238, 239, 240, 241, 242, + 243, 244, 245, 246, -1, 248, 249, 250, 251, 252, + 253, -1, 255, 256, 257, -1, 259, 260, 261, -1, + 263, -1, 265, -1, 267, 268, 269, 270, 271, 272, + 273, 274, 275, 276, 277, 278, -1, 280, 281, 282, + 283, 284, -1, 286, 287, 288, -1, -1, 291, 292, + 293, 294, 295, 296, 297, 298, 299, 300, 301, 302, + 303, 304, 305, 306, 307, 308, -1, 310, 311, 312, + 313, -1, 315, 316, 317, 318, 319, 320, -1, 322, + -1, -1, 325, 326, 327, -1, -1, 330, 331, 332, + 333, 334, 335, 336, 337, 338, 339, 340, 341, -1, + 343, 344, 345, 346, 347, 348, 349, -1, 351, 352, + 353, 354, 355, 356, 357, 358, 359, 360, 361, 362, + -1, 364, 365, 366, 367, 368, 369, 370, 371, 372, + 373, -1, 375, 376, 377, 378, 379, 380, 381, 382, + 383, 384, 385, 386, 387, 388, -1, 390, 391, 392, + 393, 394, -1, 396, 397, 398, 399, 400, 401, 402, + 403, -1, 405, 406, 407, 408, 409, 410, 411, 412, + 413, 414, 415, -1, 417, 418, -1, 420, 421, 422, + 423, 424, 425, -1, 427, 428, -1, -1, 431, 432, + 433, 434, -1, 436, 437, 438, 439, 440, 441, 442, + -1, -1, 445, 446, 447, 448, 449, -1, -1, 452, + 453, 454, 455, 456, 457, 458, -1, 460, 461, 462, + 463, 464, -1, -1, 467, -1, -1, 470, 471, 472, + 473, 474, 475, 476, 477, 478, 479, 480, 481, 482, + 483, 484, 485, 486, 5, 6, 7, 8, 9, 10, + 11, 12, 13, -1, 15, 16, -1, -1, 19, 20, + 21, 22, 23, 24, 25, 26, 27, 28, 29, -1, + 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, + -1, 42, 43, 44, 45, 46, -1, -1, -1, 50, + 51, -1, -1, -1, -1, 56, -1, -1, -1, -1, + -1, -1, -1, -1, 65, -1, 67, -1, 69, 70, + 71, -1, -1, -1, -1, -1, -1, -1, 79, 80, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 91, 92, 93, 94, 95, 96, 97, 98, -1, 100, + 101, 102, -1, -1, -1, -1, -1, -1, -1, 110, + 111, -1, 113, 114, 115, 116, 117, 118, 119, 120, + 121, 122, 123, -1, 125, 126, 127, 128, 129, -1, + -1, 132, 133, 134, 135, 136, -1, 138, 139, 140, + 141, 142, -1, 144, -1, 146, 147, 148, 149, 150, + 151, 152, -1, 154, 155, 156, 157, 158, 159, -1, + 161, 162, -1, -1, -1, -1, 167, -1, -1, -1, + 171, 172, 173, 174, 175, 176, 177, 178, 179, -1, + 181, -1, 183, 184, 185, 186, 187, -1, 189, 190, + 191, -1, -1, 194, 195, 196, 197, 198, -1, 200, + 201, 202, -1, 204, 205, -1, 207, 208, 209, 210, + 211, 212, 213, 214, 215, -1, 217, -1, 219, 220, + 221, -1, 223, -1, 225, 226, -1, 228, 229, 230, + 231, -1, 233, 234, -1, 236, -1, 238, 239, 240, + 241, 242, 243, 244, 245, 246, -1, 248, 249, 250, + 251, 252, 253, -1, 255, 256, 257, -1, 259, 260, + 261, -1, 263, -1, 265, -1, 267, 268, 269, 270, + 271, 272, 273, 274, 275, 276, 277, 278, -1, 280, + 281, 282, 283, 284, -1, 286, 287, 288, -1, -1, + 291, 292, 293, 294, 295, 296, 297, 298, 299, 300, + 301, 302, 303, 304, 305, 306, 307, 308, -1, 310, + 311, 312, 313, -1, 315, 316, 317, 318, 319, 320, + -1, 322, -1, -1, 325, 326, 327, -1, -1, 330, + 331, 332, 333, 334, 335, 336, 337, 338, 339, 340, + 341, -1, 343, 344, 345, 346, 347, 348, 349, -1, + 351, 352, 353, 354, 355, 356, 357, 358, 359, 360, + 361, 362, -1, 364, 365, 366, 367, 368, 369, 370, + 371, 372, 373, -1, 375, 376, 377, 378, 379, 380, + 381, 382, 383, 384, 385, 386, 387, 388, -1, 390, + 391, 392, 393, 394, -1, 396, 397, 398, 399, 400, + 401, 402, 403, -1, 405, 406, 407, 408, 409, 410, + 411, 412, 413, 414, 415, -1, 417, 418, -1, 420, + 421, 422, 423, 424, 425, -1, 427, 428, -1, -1, + 431, 432, 433, 434, -1, 436, 437, 438, 439, 440, + 441, 442, -1, -1, 445, 446, 447, 448, 449, -1, + -1, 452, 453, 454, 455, 456, 457, 458, -1, 460, + 461, 462, 463, 464, -1, -1, 467, -1, -1, 470, + 471, 472, 473, 474, 475, 476, 477, 478, 479, 480, + 481, 482, 483, 484, 485, 486, 5, 6, 7, 8, + 9, 10, 11, 12, 13, -1, 15, 16, -1, -1, + 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, + 29, -1, 31, 32, 33, 34, 35, 36, 37, 38, + 39, 40, -1, 42, 43, 44, 45, 46, -1, -1, + -1, 50, 51, -1, -1, -1, -1, 56, -1, -1, + -1, -1, -1, -1, -1, -1, 65, -1, 67, -1, + 69, 70, 71, -1, -1, -1, -1, -1, -1, -1, + 79, 80, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 91, 92, 93, 94, 95, 96, 97, 98, + -1, 100, 101, 102, -1, -1, -1, -1, -1, -1, + -1, 110, 111, -1, 113, 114, 115, 116, 117, 118, + 119, 120, 121, 122, 123, -1, 125, 126, 127, 128, + 129, -1, -1, 132, 133, 134, 135, 136, -1, 138, + 139, 140, 141, 142, -1, 144, -1, 146, 147, 148, + 149, 150, 151, 152, -1, 154, 155, 156, 157, 158, + 159, -1, 161, 162, -1, -1, -1, -1, 167, -1, + -1, -1, 171, 172, 173, 174, 175, 176, 177, 178, + 179, -1, 181, -1, 183, 184, 185, 186, 187, -1, + 189, 190, 191, -1, -1, 194, 195, 196, 197, 198, + -1, 200, 201, 202, -1, 204, 205, -1, 207, 208, + 209, 210, 211, 212, 213, 214, 215, -1, 217, -1, + 219, 220, 221, -1, 223, -1, 225, 226, -1, 228, + 229, 230, 231, -1, 233, 234, -1, 236, -1, 238, + 239, 240, 241, 242, 243, 244, 245, 246, -1, 248, + 249, 250, 251, 252, 253, -1, 255, 256, 257, -1, + 259, 260, 261, -1, 263, -1, 265, -1, 267, 268, + 269, 270, 271, 272, 273, 274, 275, 276, 277, 278, + -1, 280, 281, 282, 283, 284, -1, 286, 287, 288, + -1, -1, 291, 292, 293, 294, 295, 296, 297, 298, + 299, 300, 301, 302, 303, 304, 305, 306, 307, 308, + -1, 310, 311, 312, 313, -1, 315, 316, 317, 318, + 319, 320, -1, 322, -1, -1, 325, 326, 327, -1, + -1, 330, 331, 332, 333, 334, 335, 336, 337, 338, + 339, 340, 341, -1, 343, 344, 345, 346, 347, 348, + 349, -1, 351, 352, 353, 354, 355, 356, 357, 358, + 359, 360, 361, 362, -1, 364, 365, 366, 367, 368, + 369, 370, 371, 372, 373, -1, 375, 376, 377, 378, + 379, 380, 381, 382, 383, 384, 385, 386, 387, 388, + -1, 390, 391, 392, 393, 394, -1, 396, 397, 398, + 399, 400, 401, 402, 403, -1, 405, 406, 407, 408, + 409, 410, 411, 412, 413, 414, 415, -1, 417, 418, + -1, 420, 421, 422, 423, 424, 425, -1, 427, 428, + -1, -1, 431, 432, 433, 434, -1, 436, 437, 438, + 439, 440, 441, 442, -1, -1, 445, 446, 447, 448, + 449, -1, -1, 452, 453, 454, 455, 456, 457, 458, + -1, 460, 461, 462, 463, 464, -1, -1, 467, -1, + -1, 470, 471, 472, 473, 474, 475, 476, 477, 478, + 479, 480, 481, 482, 483, 484, 485, 486, 5, 6, + 7, 8, 9, 10, 11, 12, 13, -1, 15, 16, + -1, -1, 19, 20, 21, 22, 23, 24, 25, 26, + 27, 28, 29, -1, 31, 32, 33, 34, 35, 36, + 37, 38, 39, 40, -1, 42, 43, 44, 45, 46, + -1, -1, -1, 50, 51, -1, -1, -1, -1, 56, + -1, -1, -1, -1, -1, -1, -1, -1, 65, -1, + 67, -1, 69, 70, 71, -1, -1, -1, -1, -1, + -1, -1, 79, 80, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 91, 92, 93, 94, 95, 96, + 97, 98, -1, 100, 101, 102, -1, -1, -1, -1, + -1, -1, -1, 110, 111, -1, 113, 114, 115, 116, + 117, 118, -1, 120, 121, 122, 123, -1, 125, 126, + 127, 128, 129, -1, -1, 132, 133, 134, 135, 136, + -1, 138, 139, 140, 141, -1, -1, 144, -1, 146, + 147, 148, 149, 150, 151, 152, -1, 154, 155, 156, + 157, 158, 159, -1, 161, 162, -1, -1, -1, -1, + 167, -1, -1, -1, 171, 172, 173, 174, 175, 176, + 177, 178, 179, -1, 181, -1, 183, 184, 185, 186, + 187, -1, 189, 190, 191, -1, -1, 194, 195, 196, + 197, 198, -1, 200, 201, 202, -1, 204, 205, -1, + 207, 208, 209, 210, -1, 212, 213, 214, -1, -1, + 217, -1, 219, 220, 221, -1, 223, -1, 225, 226, + -1, 228, 229, 230, 231, -1, 233, -1, -1, 236, + -1, 238, 239, 240, 241, 242, 243, 244, 245, 246, + 247, 248, 249, 250, 251, 252, 253, -1, 255, 256, + 257, -1, 259, 260, 261, 262, 263, -1, 265, -1, + 267, 268, 269, 270, 271, 272, 273, 274, 275, 276, + 277, 278, -1, 280, -1, 282, 283, 284, -1, 286, + 287, 288, -1, -1, 291, 292, 293, 294, 295, 296, + 297, 298, 299, 300, 301, 302, 303, 304, 305, 306, + 307, -1, -1, 310, 311, 312, 313, -1, -1, 316, + 317, 318, 319, 320, -1, 322, -1, -1, 325, 326, + 327, -1, -1, 330, 331, 332, 333, -1, 335, 336, + 337, 338, 339, 340, 341, -1, 343, -1, 345, -1, + 347, 348, 349, -1, 351, 352, 353, 354, 355, 356, + 357, 358, 359, 360, 361, 362, -1, 364, 365, 366, + 367, 368, 369, 370, 371, 372, 373, -1, 375, 376, + 377, 378, 379, -1, 381, 382, 383, 384, 385, 386, + 387, 388, -1, 390, 391, 392, 393, 394, -1, 396, + 397, 398, 399, 400, 401, 402, 403, -1, 405, 406, + 407, 408, 409, 410, 411, 412, 413, 414, -1, -1, + 417, 418, -1, 420, 421, 422, 423, 424, 425, -1, + 427, 428, -1, -1, 431, -1, 433, -1, -1, 436, + 437, 438, 439, 440, 441, 442, -1, -1, 445, 446, + 447, 448, 449, -1, -1, 452, 453, 454, 455, 456, + -1, 458, 459, 460, 461, 462, 463, 464, -1, -1, + 467, -1, -1, 470, 471, 472, 473, 474, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 484, 485, 486, + 5, 6, 7, 8, 9, 10, 11, 12, 13, -1, + 15, 16, -1, -1, 19, 20, 21, 22, 23, 24, + 25, 26, 27, 28, 29, -1, 31, 32, 33, 34, + 35, 36, 37, 38, 39, 40, -1, 42, 43, 44, + 45, 46, -1, -1, -1, 50, 51, -1, -1, -1, + -1, 56, -1, -1, -1, -1, -1, -1, -1, -1, + 65, -1, 67, -1, 69, 70, 71, -1, -1, -1, + -1, -1, -1, -1, 79, 80, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 91, 92, 93, 94, + 95, 96, 97, 98, -1, 100, 101, 102, -1, -1, + -1, -1, -1, -1, -1, 110, 111, -1, 113, 114, + 115, 116, 117, 118, -1, 120, 121, 122, 123, -1, + 125, 126, 127, 128, 129, -1, -1, 132, 133, 134, + 135, 136, -1, 138, 139, 140, 141, -1, -1, 144, + -1, 146, 147, 148, 149, 150, 151, 152, -1, 154, + 155, 156, 157, 158, 159, -1, 161, 162, -1, -1, + -1, -1, 167, -1, -1, -1, 171, 172, 173, 174, + 175, 176, 177, 178, 179, -1, 181, -1, 183, 184, + 185, 186, 187, -1, 189, 190, 191, -1, -1, 194, + 195, 196, 197, 198, -1, 200, 201, 202, -1, 204, + 205, -1, 207, 208, 209, 210, -1, 212, 213, 214, + -1, -1, 217, -1, 219, 220, 221, -1, 223, -1, + 225, 226, -1, 228, 229, 230, 231, -1, 233, -1, + -1, 236, -1, 238, 239, 240, 241, 242, 243, 244, + 245, 246, -1, 248, 249, 250, 251, 252, 253, -1, + 255, 256, -1, -1, 259, 260, 261, 262, 263, -1, + 265, -1, 267, 268, 269, 270, 271, 272, 273, 274, + 275, 276, 277, 278, -1, 280, -1, 282, 283, 284, + -1, 286, 287, 288, -1, -1, 291, 292, 293, 294, + 295, 296, 297, 298, 299, 300, 301, 302, 303, 304, + 305, 306, 307, -1, -1, 310, 311, 312, 313, 314, + -1, 316, 317, 318, 319, 320, -1, 322, -1, -1, + 325, 326, 327, -1, -1, -1, 331, 332, 333, -1, + 335, 336, 337, 338, 339, 340, 341, -1, 343, -1, + 345, -1, 347, 348, 349, -1, 351, 352, 353, 354, + 355, 356, 357, 358, 359, 360, 361, 362, -1, 364, + 365, 366, 367, 368, 369, 370, 371, 372, 373, -1, + 375, 376, 377, 378, 379, -1, 381, 382, 383, 384, + 385, 386, 387, 388, -1, 390, 391, 392, 393, 394, + -1, 396, 397, 398, 399, 400, 401, 402, 403, -1, + 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, + -1, -1, 417, 418, 419, 420, 421, 422, 423, 424, + 425, -1, 427, 428, -1, -1, 431, -1, 433, -1, + -1, 436, 437, 438, 439, 440, 441, 442, -1, -1, + 445, 446, 447, 448, 449, -1, -1, 452, 453, 454, + 455, 456, -1, 458, -1, 460, 461, 462, 463, 464, + -1, -1, 467, -1, -1, 470, 471, 472, 473, 474, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 484, + 485, 486, 5, 6, 7, 8, 9, 10, 11, 12, + 13, -1, 15, 16, -1, -1, 19, 20, 21, 22, + 23, 24, 25, 26, 27, 28, 29, -1, 31, 32, + 33, 34, 35, 36, 37, 38, 39, 40, -1, 42, + 43, 44, 45, 46, -1, -1, -1, 50, 51, -1, + -1, -1, -1, 56, -1, -1, -1, -1, -1, -1, + -1, -1, 65, -1, 67, -1, 69, 70, 71, -1, + -1, -1, -1, -1, -1, -1, 79, 80, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 91, 92, + 93, 94, 95, 96, 97, 98, -1, 100, 101, 102, + -1, -1, -1, -1, -1, -1, -1, 110, 111, -1, + 113, 114, 115, 116, 117, 118, -1, 120, 121, 122, + 123, -1, 125, 126, 127, 128, 129, -1, -1, 132, + 133, 134, 135, 136, -1, 138, 139, 140, 141, -1, + -1, 144, -1, 146, 147, 148, 149, 150, 151, 152, + -1, 154, 155, 156, 157, 158, 159, -1, 161, 162, + -1, -1, -1, -1, 167, -1, -1, -1, 171, 172, + 173, 174, 175, 176, 177, 178, 179, -1, 181, -1, + 183, 184, 185, 186, 187, -1, 189, 190, 191, -1, + -1, 194, 195, 196, 197, 198, -1, 200, 201, 202, + -1, 204, 205, -1, 207, 208, 209, 210, -1, 212, + 213, 214, -1, -1, 217, -1, 219, 220, 221, -1, + 223, -1, 225, 226, -1, 228, 229, 230, 231, -1, + 233, -1, -1, 236, -1, 238, 239, 240, 241, 242, + 243, 244, 245, 246, -1, 248, 249, 250, 251, 252, + 253, -1, 255, 256, -1, -1, 259, 260, 261, 262, + 263, -1, 265, -1, 267, 268, 269, 270, 271, 272, + 273, 274, 275, 276, 277, 278, -1, 280, -1, 282, + 283, 284, -1, 286, 287, 288, -1, -1, 291, 292, + 293, 294, 295, 296, 297, 298, 299, 300, 301, 302, + 303, 304, 305, 306, 307, 308, -1, 310, 311, 312, + 313, -1, -1, 316, 317, 318, 319, 320, -1, 322, + -1, -1, 325, 326, 327, -1, -1, -1, 331, 332, + 333, -1, 335, 336, 337, 338, 339, 340, 341, -1, + 343, -1, 345, -1, 347, 348, 349, -1, 351, 352, + 353, 354, 355, 356, 357, 358, 359, 360, 361, 362, + -1, 364, 365, 366, 367, 368, 369, 370, 371, 372, + 373, -1, 375, 376, 377, 378, 379, -1, 381, 382, + 383, 384, 385, 386, 387, 388, -1, 390, 391, 392, + 393, 394, -1, 396, 397, 398, 399, 400, 401, 402, + 403, -1, 405, 406, 407, 408, 409, 410, 411, 412, + 413, 414, -1, -1, 417, 418, -1, 420, 421, 422, + 423, 424, 425, -1, 427, 428, -1, -1, 431, -1, + 433, -1, -1, 436, 437, 438, 439, 440, 441, 442, + -1, -1, 445, 446, 447, 448, 449, -1, -1, 452, + 453, 454, 455, 456, -1, 458, -1, 460, 461, 462, + 463, 464, -1, -1, 467, -1, -1, 470, 471, 472, + 473, 474, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 484, 485, 486, 5, 6, 7, 8, 9, 10, + 11, 12, 13, -1, 15, 16, -1, -1, 19, 20, + 21, 22, 23, 24, 25, 26, 27, 28, 29, -1, + 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, + -1, 42, 43, 44, 45, 46, -1, -1, -1, 50, + 51, -1, -1, -1, -1, 56, -1, -1, -1, -1, + -1, -1, -1, -1, 65, -1, 67, -1, 69, 70, + 71, -1, -1, -1, -1, -1, -1, -1, 79, 80, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 91, 92, 93, 94, 95, 96, 97, 98, -1, 100, + 101, 102, -1, -1, -1, -1, -1, -1, -1, 110, + 111, -1, 113, 114, 115, 116, 117, 118, -1, 120, + 121, 122, 123, -1, 125, 126, 127, 128, 129, -1, + -1, 132, 133, 134, 135, 136, -1, 138, 139, 140, + 141, -1, -1, 144, -1, 146, 147, 148, 149, 150, + 151, 152, -1, 154, 155, 156, 157, 158, 159, -1, + 161, 162, -1, -1, -1, -1, 167, -1, -1, -1, + 171, 172, 173, 174, 175, 176, 177, 178, 179, -1, + 181, -1, 183, 184, 185, 186, 187, -1, 189, 190, + 191, -1, -1, 194, 195, 196, 197, 198, -1, 200, + 201, 202, -1, 204, 205, -1, 207, 208, 209, 210, + -1, 212, 213, 214, -1, -1, 217, -1, 219, 220, + 221, -1, 223, -1, 225, 226, -1, 228, 229, 230, + 231, -1, 233, -1, -1, 236, -1, 238, 239, 240, + 241, 242, 243, 244, 245, 246, -1, 248, 249, 250, + 251, 252, 253, -1, 255, 256, -1, -1, 259, 260, + 261, 262, 263, -1, 265, -1, 267, 268, 269, 270, + 271, 272, 273, 274, 275, 276, 277, 278, -1, 280, + -1, 282, 283, 284, -1, 286, 287, 288, -1, -1, + 291, 292, 293, 294, 295, 296, 297, 298, 299, 300, + 301, 302, 303, 304, 305, 306, 307, 308, -1, 310, + 311, 312, 313, -1, -1, 316, 317, 318, 319, 320, + -1, 322, -1, -1, 325, 326, 327, -1, -1, -1, + 331, 332, 333, -1, 335, 336, 337, 338, 339, 340, + 341, -1, 343, -1, 345, -1, 347, 348, 349, -1, + 351, 352, 353, 354, 355, 356, 357, 358, 359, 360, + 361, 362, -1, 364, 365, 366, 367, 368, 369, 370, + 371, 372, 373, -1, 375, 376, 377, 378, 379, -1, + 381, 382, 383, 384, 385, 386, 387, 388, -1, 390, + 391, 392, 393, 394, -1, 396, 397, 398, 399, 400, + 401, 402, 403, -1, 405, 406, 407, 408, 409, 410, + 411, 412, 413, 414, -1, -1, 417, 418, -1, 420, + 421, 422, 423, 424, 425, -1, 427, 428, -1, -1, + 431, -1, 433, -1, -1, 436, 437, 438, 439, 440, + 441, 442, -1, -1, 445, 446, 447, 448, 449, -1, + -1, 452, 453, 454, 455, 456, -1, 458, -1, 460, + 461, 462, 463, 464, -1, -1, 467, -1, -1, 470, + 471, 472, 473, 474, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 484, 485, 486, 5, 6, 7, 8, + 9, 10, 11, 12, 13, -1, 15, 16, -1, -1, + 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, + 29, -1, 31, 32, 33, 34, 35, 36, 37, 38, + 39, 40, -1, 42, 43, 44, 45, 46, -1, -1, + -1, 50, 51, -1, -1, -1, -1, 56, -1, -1, + -1, -1, -1, -1, -1, -1, 65, -1, 67, -1, + 69, 70, 71, -1, -1, -1, -1, -1, -1, -1, + 79, 80, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 91, 92, 93, 94, 95, 96, 97, 98, + -1, 100, 101, 102, -1, -1, -1, -1, -1, -1, + -1, 110, 111, -1, 113, 114, 115, 116, 117, 118, + -1, 120, 121, 122, 123, -1, 125, 126, 127, 128, + 129, -1, -1, 132, 133, 134, 135, 136, -1, 138, + 139, 140, 141, -1, -1, 144, -1, 146, 147, 148, + 149, 150, 151, 152, -1, 154, 155, 156, 157, 158, + 159, -1, 161, 162, -1, -1, -1, -1, 167, -1, + -1, -1, 171, 172, 173, 174, 175, 176, 177, 178, + 179, -1, 181, -1, 183, 184, 185, 186, 187, -1, + 189, 190, 191, -1, -1, 194, 195, 196, 197, 198, + -1, 200, 201, 202, -1, 204, 205, -1, 207, 208, + 209, 210, -1, 212, 213, 214, -1, -1, 217, -1, + 219, 220, 221, -1, 223, -1, 225, 226, -1, 228, + 229, 230, 231, -1, 233, -1, -1, 236, -1, 238, + 239, 240, 241, 242, 243, 244, 245, 246, -1, 248, + 249, 250, 251, 252, 253, -1, 255, 256, -1, -1, + 259, 260, 261, 262, 263, -1, 265, -1, 267, 268, + 269, 270, 271, 272, 273, 274, 275, 276, 277, 278, + -1, 280, -1, 282, 283, 284, -1, 286, 287, 288, + -1, -1, 291, 292, 293, 294, 295, 296, 297, 298, + 299, 300, 301, 302, 303, 304, 305, 306, 307, -1, + -1, 310, 311, 312, 313, -1, -1, 316, 317, 318, + 319, 320, -1, 322, -1, -1, 325, 326, 327, -1, + -1, -1, 331, 332, 333, -1, 335, 336, 337, 338, + 339, 340, 341, -1, 343, -1, 345, -1, 347, 348, + 349, -1, 351, 352, 353, 354, 355, 356, 357, 358, + 359, 360, 361, 362, -1, 364, 365, 366, 367, 368, + 369, 370, 371, 372, 373, -1, 375, 376, 377, 378, + 379, -1, 381, 382, 383, 384, 385, 386, 387, 388, + -1, 390, 391, 392, 393, 394, -1, 396, 397, 398, + 399, 400, 401, 402, 403, -1, 405, 406, 407, 408, + 409, 410, 411, 412, 413, 414, -1, -1, 417, 418, + -1, 420, 421, 422, 423, 424, 425, -1, 427, 428, + -1, -1, 431, -1, 433, -1, -1, 436, 437, 438, + 439, 440, 441, 442, -1, -1, 445, 446, 447, 448, + 449, -1, -1, 452, 453, 454, 455, 456, -1, 458, + -1, 460, 461, 462, 463, 464, -1, -1, 467, -1, + -1, 470, 471, 472, 473, 474, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 484, 485, 486, 5, 6, + 7, 8, 9, 10, 11, 12, 13, -1, 15, 16, + -1, -1, 19, 20, 21, 22, 23, 24, 25, 26, + 27, 28, 29, -1, 31, 32, 33, 34, 35, 36, + 37, 38, 39, 40, -1, 42, 43, 44, 45, 46, + -1, -1, -1, 50, 51, -1, -1, -1, -1, 56, + -1, -1, -1, -1, -1, -1, -1, -1, 65, -1, + 67, -1, 69, 70, 71, -1, -1, -1, -1, -1, + -1, -1, 79, 80, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 91, 92, 93, 94, 95, 96, + 97, 98, -1, 100, 101, 102, -1, -1, -1, -1, + -1, -1, -1, 110, 111, -1, 113, 114, 115, 116, + 117, 118, -1, 120, 121, 122, 123, -1, 125, 126, + 127, 128, 129, -1, -1, 132, 133, 134, 135, 136, + -1, 138, 139, 140, 141, -1, -1, 144, -1, 146, + 147, 148, 149, 150, 151, 152, -1, 154, 155, 156, + 157, 158, 159, -1, 161, 162, -1, -1, -1, -1, + 167, -1, -1, -1, 171, 172, 173, 174, 175, 176, + 177, 178, 179, -1, 181, -1, 183, 184, 185, 186, + 187, -1, 189, 190, 191, -1, -1, 194, 195, 196, + 197, 198, -1, 200, 201, 202, -1, 204, 205, -1, + 207, 208, 209, 210, -1, 212, 213, 214, -1, -1, + 217, -1, 219, 220, 221, -1, 223, -1, 225, 226, + -1, 228, 229, 230, 231, -1, 233, -1, -1, 236, + -1, 238, 239, 240, 241, 242, 243, 244, 245, 246, + -1, 248, 249, 250, 251, 252, 253, -1, 255, 256, + -1, -1, 259, 260, 261, 262, 263, -1, 265, -1, + 267, 268, 269, 270, 271, 272, 273, 274, 275, 276, + 277, 278, -1, 280, -1, 282, 283, 284, -1, 286, + 287, 288, -1, -1, 291, 292, 293, 294, 295, 296, + 297, 298, 299, 300, 301, 302, 303, 304, 305, 306, + 307, -1, -1, 310, 311, 312, 313, -1, -1, 316, + 317, 318, 319, 320, -1, 322, -1, -1, 325, 326, + 327, -1, -1, -1, 331, 332, 333, -1, 335, 336, + 337, 338, 339, 340, 341, -1, 343, -1, 345, -1, + 347, 348, 349, -1, 351, 352, 353, 354, 355, 356, + 357, 358, 359, 360, 361, 362, -1, 364, 365, 366, + 367, 368, 369, 370, 371, 372, 373, -1, 375, 376, + 377, 378, 379, -1, 381, 382, 383, 384, 385, 386, + 387, 388, -1, 390, 391, 392, 393, 394, -1, 396, + 397, 398, 399, 400, 401, 402, 403, -1, 405, 406, + 407, 408, 409, 410, 411, 412, 413, 414, -1, -1, + 417, 418, -1, 420, 421, 422, 423, 424, 425, -1, + 427, 428, -1, -1, 431, -1, 433, -1, -1, 436, + 437, 438, 439, 440, 441, 442, -1, -1, 445, 446, + 447, 448, 449, -1, -1, 452, 453, 454, 455, 456, + -1, 458, -1, 460, 461, 462, 463, 464, -1, -1, + 467, -1, -1, 470, 471, 472, 473, 474, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 484, 485, 486, + 5, 6, 7, 8, 9, 10, 11, 12, 13, -1, + 15, 16, -1, -1, 19, 20, 21, 22, 23, 24, + 25, 26, 27, 28, 29, -1, 31, 32, 33, 34, + 35, 36, 37, 38, 39, 40, -1, 42, 43, 44, + 45, 46, -1, -1, -1, 50, 51, -1, -1, -1, + -1, 56, -1, -1, -1, -1, -1, -1, -1, -1, + 65, -1, 67, -1, 69, 70, 71, -1, -1, -1, + -1, -1, -1, -1, 79, 80, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 91, 92, 93, 94, + 95, 96, 97, 98, -1, 100, 101, 102, -1, -1, + -1, -1, -1, -1, -1, 110, 111, -1, 113, 114, + 115, 116, 117, 118, -1, 120, 121, 122, 123, -1, + 125, 126, 127, 128, 129, -1, -1, 132, 133, 134, + 135, 136, -1, 138, 139, 140, 141, -1, -1, 144, + -1, 146, 147, 148, 149, 150, 151, 152, -1, 154, + 155, 156, 157, 158, 159, -1, 161, 162, -1, -1, + -1, -1, 167, -1, -1, -1, 171, 172, 173, 174, + 175, 176, 177, 178, 179, -1, 181, -1, 183, 184, + 185, 186, 187, -1, 189, 190, 191, -1, -1, 194, + 195, 196, 197, 198, -1, 200, 201, 202, -1, 204, + 205, -1, 207, 208, 209, 210, -1, 212, 213, 214, + -1, -1, 217, -1, 219, 220, 221, -1, 223, -1, + 225, 226, -1, 228, 229, 230, 231, -1, 233, -1, + -1, 236, -1, 238, 239, 240, 241, 242, 243, 244, + 245, 246, -1, 248, 249, 250, 251, 252, 253, -1, + 255, 256, -1, -1, 259, 260, 261, 262, 263, -1, + 265, -1, 267, 268, 269, 270, 271, 272, 273, 274, + 275, 276, 277, 278, -1, 280, -1, 282, 283, 284, + -1, 286, 287, 288, -1, -1, 291, 292, 293, 294, + 295, 296, 297, 298, 299, 300, 301, 302, 303, 304, + 305, 306, 307, -1, -1, 310, 311, 312, 313, -1, + -1, 316, 317, 318, 319, 320, -1, 322, -1, -1, + 325, 326, 327, -1, -1, -1, 331, 332, 333, -1, + 335, 336, 337, 338, 339, 340, 341, -1, 343, -1, + 345, -1, 347, 348, 349, -1, 351, 352, 353, 354, + 355, 356, 357, 358, 359, 360, 361, 362, -1, 364, + 365, 366, 367, 368, 369, 370, 371, 372, 373, -1, + 375, 376, 377, 378, 379, -1, 381, 382, 383, 384, + 385, 386, 387, 388, -1, 390, 391, 392, 393, 394, + -1, 396, -1, 398, 399, 400, 401, 402, 403, -1, + 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, + -1, -1, 417, 418, -1, 420, 421, 422, 423, 424, + 425, -1, 427, 428, -1, -1, 431, -1, 433, -1, + -1, 436, 437, 438, 439, 440, 441, 442, -1, -1, + 445, 446, 447, 448, 449, -1, -1, 452, 453, 454, + 455, 456, -1, 458, -1, 460, 461, 462, 463, 464, + -1, -1, 467, -1, -1, 470, 471, 472, 473, 474, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 484, + 485, 486, 5, 6, 7, 8, 9, 10, 11, 12, + 13, -1, 15, 16, -1, -1, 19, 20, 21, 22, + 23, 24, 25, 26, 27, 28, 29, -1, 31, 32, + 33, 34, 35, 36, 37, 38, 39, 40, -1, 42, + 43, 44, 45, 46, -1, -1, -1, 50, 51, -1, + -1, -1, -1, 56, -1, -1, -1, -1, -1, -1, + -1, -1, 65, -1, 67, -1, 69, 70, 71, -1, + -1, -1, -1, -1, -1, -1, 79, 80, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 91, 92, + 93, 94, 95, 96, 97, 98, -1, 100, 101, 102, + -1, -1, -1, -1, -1, -1, -1, 110, 111, -1, + 113, 114, 115, 116, 117, 118, -1, -1, 121, -1, + -1, -1, 125, 126, 127, 128, 129, -1, -1, 132, + 133, -1, -1, 136, -1, 138, 139, 140, 141, -1, + -1, 144, -1, 146, 147, 148, 149, 150, 151, 152, + -1, 154, 155, 156, 157, 158, 159, -1, 161, 162, + -1, -1, -1, -1, 167, -1, -1, -1, 171, 172, + 173, 174, 175, 176, -1, -1, 179, -1, 181, -1, + 183, 184, 185, 186, 187, -1, 189, 190, 191, -1, + -1, 194, 195, 196, 197, 198, -1, 200, 201, 202, + -1, 204, 205, -1, 207, 208, 209, 210, -1, 212, + 213, 214, -1, -1, 217, -1, 219, -1, 221, -1, + 223, -1, 225, 226, -1, 228, 229, 230, 231, -1, + 233, -1, -1, 236, -1, 238, 239, 240, 241, 242, + 243, 244, 245, 246, -1, 248, 249, 250, 251, 252, + 253, -1, 255, 256, -1, -1, 259, 260, 261, -1, + -1, -1, -1, -1, 267, 268, 269, 270, 271, 272, + 273, 274, 275, 276, 277, 278, -1, 280, -1, 282, + 283, 284, -1, 286, 287, 288, -1, -1, 291, 292, + 293, 294, 295, 296, 297, 298, 299, 300, 301, 302, + -1, 304, -1, 306, 307, -1, -1, 310, 311, 312, + 313, -1, -1, 316, -1, 318, 319, 320, -1, 322, + -1, -1, 325, 326, 327, -1, -1, -1, 331, 332, + 333, -1, 335, 336, 337, 338, 339, 340, 341, -1, + 343, -1, 345, -1, 347, 348, 349, -1, 351, 352, + 353, 354, 355, 356, 357, -1, 359, 360, 361, 362, + -1, 364, 365, 366, 367, 368, 369, 370, 371, 372, + 373, -1, 375, 376, 377, 378, 379, -1, 381, 382, + 383, 384, 385, 386, 387, 388, -1, 390, 391, 392, + 393, 394, -1, 396, -1, 398, 399, 400, 401, -1, + 403, -1, 405, 406, 407, 408, 409, 410, 411, 412, + 413, 414, -1, -1, 417, 418, -1, 420, 421, 422, + 423, 424, 425, -1, -1, -1, -1, -1, 431, -1, + 433, -1, -1, 436, 437, 438, 439, 440, 441, 442, + -1, -1, 445, 446, 447, 448, 449, -1, -1, 452, + 453, 454, 455, 456, -1, -1, -1, 460, 461, 462, + 463, 464, -1, -1, 467, -1, -1, 470, 471, 472, + 473, 474, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 484, 485, 486, 6, 7, 8, 9, 10, 11, + 12, 13, -1, 15, 16, -1, -1, 19, 20, 21, + 22, 23, 24, -1, 26, 27, 28, -1, -1, 31, + 32, 33, 34, -1, -1, 37, 38, 39, 40, -1, + 42, -1, -1, 45, 46, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 71, + -1, -1, -1, -1, -1, -1, -1, 79, 80, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 91, + 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, + 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, + 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, + 122, 123, 124, 125, 126, 127, 128, 129, 130, 131, + 132, 133, -1, 135, 136, 137, 138, 139, 140, 141, + 142, 143, 144, 145, 146, 147, 148, 149, 150, 151, + 152, 153, 154, 155, 156, 157, 158, 159, 160, 161, + 162, -1, 164, 165, 166, 167, 168, 169, 170, 171, + 172, 173, 174, -1, 176, 177, 178, 179, 180, 181, + 182, 183, 184, 185, 186, 187, 188, 189, 190, 191, + 192, 193, 194, 195, 196, 197, 198, 199, 200, 201, + 202, 203, 204, 205, 206, 207, 208, 209, 210, 211, + 212, 213, 214, 215, 216, 217, 218, 219, 220, 221, + 222, 223, 224, 225, 226, 227, 228, 229, 230, 231, + 232, 233, 234, 235, 236, 237, 238, 239, -1, 241, + 242, 243, 244, 245, 246, 247, 248, 249, 250, 251, + 252, 253, 254, 255, 256, 257, -1, 259, 260, 261, + -1, 263, 264, 265, 266, 267, 268, 269, 270, 271, + 272, 273, 274, 275, 276, 277, 278, 279, 280, 281, + 282, 283, 284, 285, 286, 287, 288, 289, 290, 291, + 292, 293, 294, 295, -1, 297, 298, -1, 300, 301, + 302, 303, 304, 305, 306, 307, 308, 309, 310, 311, + 312, 313, 314, 315, 316, 317, 318, 319, 320, 321, + 322, 323, 324, 325, 326, 327, 328, 329, 330, 331, + 332, 333, 334, 335, 336, 337, 338, 339, 340, 341, + 342, 343, 344, 345, 346, 347, 348, 349, 350, 351, + 352, 353, 354, 355, 356, 357, 358, 359, 360, 361, + 362, 363, 364, 365, 366, 367, 368, 369, 370, 371, + 372, 373, 374, 375, 376, 377, 378, 379, 380, 381, + 382, 383, 384, 385, 386, -1, 388, 389, 390, 391, + 392, 393, 394, 395, 396, 397, 398, 399, 400, 401, + 402, 403, 404, 405, 406, 407, 408, 409, 410, 411, + 412, 413, 414, 415, 416, 417, 418, 419, 420, 421, + 422, 423, 424, 425, 426, 427, 428, -1, 430, 431, + 432, 433, 434, 435, 436, 437, 438, 439, 440, 441, + 442, -1, 444, 445, 446, 447, 448, 449, 450, 451, + 452, 453, 454, 455, 456, -1, 458, 459, 460, 461, + 462, 463, 464, 465, 466, 467, 468, 469, 470, 471, + 472, 473, 474, 475, 476, 477, 478, 479, 480, 481, + 482, 483, -1, 485, 486, 6, 7, 8, 9, 10, + 11, 12, 13, -1, 15, 16, -1, -1, 19, 20, + 21, 22, 23, 24, -1, 26, 27, 28, -1, -1, + 31, 32, 33, 34, -1, -1, 37, 38, 39, 40, + -1, 42, -1, -1, 45, 46, -1, -1, -1, 50, + 51, -1, -1, -1, -1, 56, -1, -1, -1, -1, + -1, -1, -1, -1, 65, -1, 67, -1, 69, 70, + 71, -1, -1, -1, 75, 76, 77, 78, 79, 80, + -1, 82, -1, -1, -1, -1, -1, -1, -1, -1, + 91, 92, 93, 94, 95, 96, 97, 98, -1, 100, + 101, 102, -1, -1, -1, -1, -1, -1, -1, 110, + 111, -1, 113, 114, -1, 116, 117, 118, 119, 120, + -1, 122, 123, -1, 125, 126, 127, 128, 129, -1, + -1, 132, 133, 134, 135, 136, -1, 138, 139, 140, + 141, 142, -1, -1, -1, 146, 147, 148, 149, -1, + 151, 152, -1, 154, 155, 156, 157, 158, 159, -1, + -1, 162, -1, -1, -1, -1, -1, -1, -1, -1, + 171, 172, 173, 174, 175, 176, 177, 178, 179, -1, + 181, -1, 183, 184, 185, 186, 187, -1, 189, 190, + 191, -1, -1, 194, 195, 196, 197, 198, -1, 200, + 201, 202, -1, 204, 205, -1, 207, 208, 209, 210, + 211, 212, 213, 214, 215, 216, 217, -1, 219, 220, + 221, -1, 223, -1, 225, -1, -1, -1, 229, 230, + 231, -1, 233, 234, -1, 236, -1, 238, 239, 240, + 241, 242, -1, 244, 245, 246, -1, 248, 249, 250, + 251, 252, 253, -1, 255, -1, 257, -1, 259, 260, + 261, -1, 263, -1, 265, -1, 267, -1, -1, 270, + -1, 272, 273, 274, 275, 276, 277, 278, -1, 280, + 281, -1, 283, -1, -1, 286, 287, 288, -1, -1, + 291, 292, 293, 294, 295, 296, 297, 298, 299, 300, + 301, 302, 303, -1, 305, 306, 307, 308, -1, 310, + 311, -1, 313, -1, 315, 316, 317, 318, 319, 320, + -1, 322, 323, -1, 325, 326, 327, -1, -1, 330, + -1, -1, -1, 334, 335, 336, 337, 338, 339, 340, + 341, -1, 343, 344, 345, 346, 347, 348, 349, -1, + 351, 352, 353, 354, 355, 356, 357, 358, 359, 360, + 361, 362, -1, 364, 365, 366, 367, 368, 369, 370, + 371, 372, 373, -1, 375, 376, -1, 378, 379, 380, + 381, 382, 383, 384, 385, 386, 387, 388, -1, 390, + 391, 392, 393, 394, -1, 396, 397, 398, 399, -1, + 401, 402, 403, -1, 405, 406, 407, 408, 409, 410, + 411, 412, 413, 414, 415, -1, 417, 418, -1, 420, + 421, 422, 423, 424, 425, -1, 427, 428, -1, -1, + 431, 432, 433, 434, 435, 436, 437, 438, 439, 440, + 441, 442, -1, -1, 445, 446, 447, 448, 449, -1, + -1, 452, 453, 454, 455, 456, 457, 458, -1, 460, + -1, 462, 463, 464, -1, -1, 467, -1, -1, 470, + 471, 472, 473, 474, 475, 476, 477, 478, 479, 480, + 481, 482, 483, 484, 485, 486, 6, 7, 8, 9, + 10, 11, 12, 13, -1, 15, 16, -1, -1, 19, + 20, 21, 22, 23, 24, -1, 26, 27, 28, -1, + -1, 31, 32, 33, 34, -1, -1, 37, 38, 39, + 40, -1, 42, -1, -1, 45, 46, -1, -1, -1, + 50, 51, -1, -1, -1, -1, 56, -1, -1, -1, + -1, -1, -1, -1, -1, 65, -1, 67, -1, 69, + 70, 71, 72, -1, -1, 75, 76, 77, 78, 79, + 80, -1, 82, -1, -1, -1, -1, -1, -1, -1, + -1, 91, 92, 93, 94, 95, 96, 97, 98, -1, + 100, 101, 102, -1, -1, -1, -1, -1, -1, -1, + 110, 111, -1, 113, 114, -1, 116, 117, 118, 119, + 120, -1, 122, 123, -1, 125, 126, 127, 128, 129, + -1, -1, 132, 133, 134, 135, 136, -1, 138, 139, + 140, 141, 142, -1, -1, -1, 146, 147, 148, 149, + -1, 151, 152, -1, 154, 155, 156, 157, 158, 159, + -1, -1, 162, -1, -1, -1, -1, -1, -1, -1, + -1, 171, 172, 173, 174, 175, 176, 177, 178, 179, + -1, 181, -1, 183, 184, 185, 186, 187, -1, 189, + 190, 191, -1, -1, 194, 195, 196, 197, 198, -1, + 200, 201, 202, -1, 204, 205, -1, 207, 208, 209, + 210, 211, 212, 213, 214, 215, -1, 217, -1, 219, + 220, 221, -1, 223, -1, 225, -1, -1, -1, 229, + 230, 231, -1, 233, 234, -1, 236, -1, 238, 239, + 240, 241, 242, -1, 244, 245, 246, -1, 248, 249, + 250, 251, 252, 253, -1, 255, -1, 257, -1, 259, + 260, 261, -1, 263, -1, 265, -1, 267, -1, -1, + 270, -1, 272, 273, 274, 275, 276, 277, 278, -1, + 280, 281, -1, 283, -1, -1, 286, 287, 288, -1, + -1, 291, 292, 293, 294, 295, 296, 297, 298, 299, + 300, 301, 302, 303, -1, 305, 306, 307, 308, -1, + 310, 311, -1, 313, -1, 315, 316, 317, 318, 319, + 320, -1, 322, -1, -1, 325, 326, 327, -1, -1, + 330, -1, -1, -1, 334, 335, 336, 337, 338, 339, + 340, 341, -1, 343, 344, 345, 346, 347, 348, 349, + -1, 351, 352, 353, 354, 355, 356, 357, 358, 359, + 360, 361, 362, -1, 364, 365, 366, 367, 368, 369, + 370, 371, 372, 373, -1, 375, 376, -1, 378, 379, + 380, 381, 382, 383, 384, 385, 386, 387, 388, -1, + 390, 391, 392, 393, 394, -1, 396, 397, 398, 399, + -1, 401, 402, 403, -1, 405, 406, 407, 408, 409, + 410, 411, 412, 413, 414, 415, -1, 417, 418, -1, + 420, 421, 422, 423, 424, 425, -1, 427, 428, 429, + -1, 431, 432, 433, 434, -1, 436, 437, 438, 439, + 440, 441, 442, -1, -1, 445, 446, 447, 448, 449, + -1, -1, 452, 453, 454, 455, 456, 457, 458, -1, + 460, -1, 462, 463, 464, -1, -1, 467, -1, -1, + 470, 471, 472, 473, 474, 475, 476, 477, 478, 479, + 480, 481, 482, 483, 484, 485, 486, 6, 7, 8, + 9, 10, 11, 12, 13, -1, 15, 16, -1, -1, + 19, 20, 21, 22, 23, 24, -1, 26, 27, 28, + -1, -1, 31, 32, 33, 34, -1, -1, 37, 38, + 39, 40, -1, 42, -1, -1, 45, 46, -1, -1, + -1, 50, 51, -1, -1, -1, -1, 56, -1, -1, + -1, -1, -1, -1, -1, -1, 65, -1, 67, -1, + 69, 70, 71, 72, -1, -1, 75, 76, 77, 78, + 79, 80, -1, 82, -1, -1, -1, -1, -1, -1, + -1, -1, 91, 92, 93, 94, 95, 96, 97, 98, + -1, 100, 101, 102, -1, -1, -1, -1, -1, -1, + -1, 110, 111, -1, 113, 114, -1, 116, 117, 118, + 119, 120, -1, 122, 123, -1, 125, 126, 127, 128, + 129, -1, -1, 132, 133, 134, 135, 136, -1, 138, + 139, 140, 141, 142, -1, -1, -1, 146, 147, 148, + 149, -1, 151, 152, -1, 154, 155, 156, 157, 158, + 159, -1, -1, 162, -1, -1, -1, -1, -1, -1, + -1, -1, 171, 172, 173, 174, 175, 176, 177, 178, + 179, 180, 181, -1, 183, 184, 185, 186, 187, -1, + 189, 190, 191, -1, -1, 194, 195, 196, 197, 198, + -1, 200, 201, 202, -1, 204, 205, -1, 207, 208, + 209, 210, 211, 212, 213, 214, 215, -1, 217, -1, + 219, 220, 221, -1, 223, -1, 225, -1, -1, -1, + 229, 230, 231, -1, 233, 234, -1, 236, -1, 238, + 239, 240, 241, 242, -1, 244, 245, 246, -1, 248, + 249, 250, 251, 252, 253, -1, 255, -1, 257, -1, + 259, 260, 261, -1, 263, -1, 265, -1, 267, -1, + -1, 270, -1, 272, 273, 274, 275, 276, 277, 278, + -1, 280, 281, -1, 283, -1, -1, 286, 287, 288, + -1, -1, 291, 292, 293, 294, 295, 296, 297, 298, + 299, 300, 301, 302, 303, -1, 305, 306, 307, 308, + -1, 310, 311, -1, 313, -1, 315, 316, 317, 318, + 319, 320, -1, 322, -1, -1, 325, 326, 327, -1, + -1, 330, -1, -1, -1, 334, 335, 336, 337, 338, + 339, 340, 341, -1, 343, 344, 345, 346, 347, 348, + 349, -1, 351, 352, 353, 354, 355, 356, 357, 358, + 359, 360, 361, 362, -1, 364, 365, 366, 367, 368, + 369, 370, 371, 372, 373, -1, 375, 376, -1, 378, + 379, 380, 381, 382, 383, 384, 385, 386, 387, 388, + -1, 390, 391, 392, 393, 394, -1, 396, 397, 398, + 399, -1, 401, 402, 403, -1, 405, 406, 407, 408, + 409, 410, 411, 412, 413, 414, 415, -1, 417, 418, + -1, 420, 421, 422, 423, 424, 425, -1, 427, 428, + -1, -1, 431, 432, 433, 434, -1, 436, 437, 438, + 439, 440, 441, 442, -1, -1, 445, 446, 447, 448, + 449, -1, -1, 452, 453, 454, 455, 456, 457, 458, + -1, 460, -1, 462, 463, 464, -1, -1, 467, -1, + -1, 470, 471, 472, 473, 474, 475, 476, 477, 478, + 479, 480, 481, 482, 483, 484, 485, 486, 6, 7, + 8, 9, 10, 11, 12, 13, -1, 15, 16, -1, + -1, 19, 20, 21, 22, 23, 24, -1, 26, 27, + 28, -1, -1, 31, 32, 33, 34, -1, -1, 37, + 38, 39, 40, -1, 42, -1, -1, 45, 46, -1, + -1, -1, 50, 51, -1, -1, -1, -1, 56, -1, + -1, -1, -1, -1, -1, -1, -1, 65, -1, 67, + -1, 69, 70, 71, 72, -1, -1, 75, 76, 77, + 78, 79, 80, -1, 82, -1, -1, -1, -1, -1, + -1, -1, -1, 91, 92, 93, 94, 95, 96, 97, + 98, -1, 100, 101, 102, -1, -1, -1, -1, -1, + -1, -1, 110, 111, -1, 113, 114, -1, 116, 117, + 118, 119, 120, -1, 122, 123, -1, 125, 126, 127, + 128, 129, -1, -1, 132, 133, 134, 135, 136, -1, + 138, 139, 140, 141, 142, -1, -1, -1, 146, 147, + 148, 149, -1, 151, 152, -1, 154, 155, 156, 157, + 158, 159, -1, -1, 162, -1, -1, -1, -1, -1, + -1, -1, -1, 171, 172, 173, 174, 175, 176, 177, + 178, 179, -1, 181, -1, 183, 184, 185, 186, 187, + -1, 189, 190, 191, -1, -1, 194, 195, 196, 197, + 198, -1, 200, 201, 202, -1, 204, 205, -1, 207, + 208, 209, 210, 211, 212, 213, 214, 215, -1, 217, + -1, 219, 220, 221, -1, 223, -1, 225, -1, -1, + -1, 229, 230, 231, -1, 233, 234, -1, 236, -1, + 238, 239, 240, 241, 242, -1, 244, 245, 246, -1, + 248, 249, 250, 251, 252, 253, -1, 255, -1, 257, + -1, 259, 260, 261, -1, 263, -1, 265, -1, 267, + -1, -1, 270, -1, 272, 273, 274, 275, 276, 277, + 278, -1, 280, 281, -1, 283, -1, -1, 286, 287, + 288, -1, -1, 291, 292, 293, 294, 295, 296, 297, + 298, 299, 300, 301, 302, 303, -1, 305, 306, 307, + 308, -1, 310, 311, -1, 313, -1, 315, 316, 317, + 318, 319, 320, -1, 322, -1, -1, 325, 326, 327, + -1, -1, 330, -1, -1, -1, 334, 335, 336, 337, + 338, 339, 340, 341, -1, 343, 344, 345, 346, 347, + 348, 349, -1, 351, 352, 353, 354, 355, 356, 357, + 358, 359, 360, 361, 362, -1, 364, 365, 366, 367, + 368, 369, 370, 371, 372, 373, -1, 375, 376, -1, + 378, 379, 380, 381, 382, 383, 384, 385, 386, 387, + 388, -1, 390, 391, 392, 393, 394, -1, 396, 397, + 398, 399, -1, 401, 402, 403, -1, 405, 406, 407, + 408, 409, 410, 411, 412, 413, 414, 415, -1, 417, + 418, -1, 420, 421, 422, 423, 424, 425, -1, 427, + 428, -1, -1, 431, 432, 433, 434, -1, 436, 437, + 438, 439, 440, 441, 442, -1, -1, 445, 446, 447, + 448, 449, -1, -1, 452, 453, 454, 455, 456, 457, + 458, -1, 460, -1, 462, 463, 464, -1, -1, 467, + -1, -1, 470, 471, 472, 473, 474, 475, 476, 477, + 478, 479, 480, 481, 482, 483, 484, 485, 486, 6, + 7, 8, 9, 10, 11, 12, 13, -1, 15, 16, + -1, -1, 19, 20, 21, 22, 23, 24, -1, 26, + 27, 28, -1, -1, 31, 32, 33, 34, -1, -1, + 37, 38, 39, 40, -1, 42, -1, -1, 45, 46, + -1, -1, -1, 50, 51, -1, -1, -1, -1, 56, + -1, -1, -1, -1, -1, -1, -1, -1, 65, -1, + 67, -1, 69, 70, 71, -1, -1, -1, 75, 76, + 77, 78, 79, 80, -1, 82, -1, -1, -1, -1, + -1, -1, -1, -1, 91, 92, 93, 94, 95, 96, + 97, 98, -1, 100, 101, 102, -1, -1, -1, -1, + -1, -1, -1, 110, 111, -1, 113, 114, -1, 116, + 117, 118, 119, 120, -1, 122, 123, -1, 125, 126, + 127, 128, 129, -1, -1, 132, 133, 134, 135, 136, + -1, 138, 139, 140, 141, 142, -1, -1, -1, 146, + 147, 148, 149, -1, 151, 152, -1, 154, 155, 156, + 157, 158, 159, -1, -1, 162, -1, -1, -1, -1, + -1, -1, -1, -1, 171, 172, 173, 174, 175, 176, + 177, 178, 179, 180, 181, -1, 183, 184, 185, 186, + 187, -1, 189, 190, 191, -1, -1, 194, 195, 196, + 197, 198, -1, 200, 201, 202, -1, 204, 205, -1, + 207, 208, 209, 210, 211, 212, 213, 214, 215, -1, + 217, -1, 219, 220, 221, -1, 223, -1, 225, -1, + -1, -1, 229, 230, 231, -1, 233, 234, -1, 236, + -1, 238, 239, 240, 241, 242, -1, 244, 245, 246, + -1, 248, 249, 250, 251, 252, 253, -1, 255, -1, + 257, -1, 259, 260, 261, -1, 263, -1, 265, -1, + 267, -1, -1, 270, -1, 272, 273, 274, 275, 276, + 277, 278, -1, 280, 281, -1, 283, -1, -1, 286, + 287, 288, -1, -1, 291, 292, 293, 294, 295, 296, + 297, 298, 299, 300, 301, 302, 303, -1, 305, 306, + 307, 308, -1, 310, 311, -1, 313, -1, 315, 316, + 317, 318, 319, 320, -1, 322, -1, -1, 325, 326, + 327, -1, -1, 330, -1, -1, -1, 334, 335, 336, + 337, 338, 339, 340, 341, -1, 343, 344, 345, 346, + 347, 348, 349, -1, 351, 352, 353, 354, 355, 356, + 357, 358, 359, 360, 361, 362, -1, 364, 365, 366, + 367, 368, 369, 370, 371, 372, 373, -1, 375, 376, + -1, 378, 379, 380, 381, 382, 383, 384, 385, 386, + 387, 388, -1, 390, 391, 392, 393, 394, -1, 396, + 397, 398, 399, -1, 401, 402, 403, -1, 405, 406, + 407, 408, 409, 410, 411, 412, 413, 414, 415, -1, + 417, 418, -1, 420, 421, 422, 423, 424, 425, -1, + 427, 428, -1, -1, 431, 432, 433, 434, -1, 436, + 437, 438, 439, 440, 441, 442, -1, -1, 445, 446, + 447, 448, 449, -1, -1, 452, 453, 454, 455, 456, + 457, 458, -1, 460, -1, 462, 463, 464, -1, -1, + 467, -1, -1, 470, 471, 472, 473, 474, 475, 476, + 477, 478, 479, 480, 481, 482, 483, 484, 485, 486, + 6, 7, 8, 9, 10, 11, 12, 13, -1, 15, + 16, -1, -1, 19, 20, 21, 22, 23, 24, -1, + 26, 27, 28, -1, -1, 31, 32, 33, 34, -1, + -1, 37, 38, 39, 40, -1, 42, -1, -1, 45, + 46, -1, -1, -1, 50, 51, -1, -1, -1, -1, + 56, -1, -1, -1, -1, -1, -1, -1, -1, 65, + -1, 67, -1, 69, 70, 71, -1, -1, -1, -1, + -1, -1, -1, 79, 80, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 91, 92, 93, 94, 95, + 96, 97, 98, -1, 100, 101, 102, -1, -1, -1, + -1, -1, -1, -1, 110, 111, -1, 113, 114, -1, + 116, 117, 118, 119, 120, -1, 122, 123, -1, 125, + 126, 127, 128, 129, -1, -1, 132, 133, 134, 135, + 136, 137, 138, 139, 140, 141, 142, -1, -1, 145, + 146, 147, 148, 149, -1, 151, 152, 153, 154, 155, + 156, 157, 158, 159, -1, -1, 162, -1, -1, -1, + -1, -1, -1, -1, -1, 171, 172, 173, 174, 175, + 176, 177, 178, 179, -1, 181, -1, 183, 184, 185, + 186, 187, -1, 189, 190, 191, -1, -1, 194, 195, + 196, 197, 198, -1, 200, 201, 202, -1, 204, 205, + -1, 207, 208, 209, 210, 211, 212, 213, 214, 215, + -1, 217, -1, 219, 220, 221, -1, 223, 224, 225, + -1, -1, -1, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, -1, 244, 245, + 246, -1, 248, 249, 250, 251, 252, 253, -1, 255, + -1, 257, -1, 259, 260, 261, -1, 263, -1, 265, + -1, 267, -1, -1, 270, -1, 272, 273, 274, 275, + 276, 277, 278, -1, 280, 281, -1, 283, -1, -1, + 286, 287, 288, -1, -1, 291, 292, 293, 294, 295, + 296, 297, 298, 299, 300, 301, 302, 303, -1, 305, + 306, 307, 308, -1, 310, 311, -1, 313, -1, 315, + 316, 317, 318, 319, 320, -1, 322, -1, -1, 325, + 326, 327, -1, -1, 330, -1, -1, -1, 334, 335, + 336, 337, 338, 339, 340, 341, -1, 343, 344, 345, + 346, 347, 348, 349, 350, 351, 352, 353, 354, 355, + 356, 357, 358, 359, 360, 361, 362, -1, 364, 365, + 366, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, -1, 378, 379, 380, 381, 382, 383, 384, 385, + 386, 387, 388, -1, 390, 391, 392, 393, 394, -1, + 396, 397, 398, 399, -1, 401, 402, 403, -1, 405, + 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, + -1, 417, 418, -1, 420, 421, 422, 423, 424, 425, + -1, 427, 428, -1, -1, 431, 432, 433, 434, -1, + 436, 437, 438, 439, 440, 441, 442, -1, 444, 445, + 446, 447, 448, 449, -1, -1, 452, 453, 454, 455, + 456, 457, 458, -1, 460, -1, 462, 463, 464, -1, + -1, 467, -1, -1, 470, 471, 472, 473, 474, 475, + 476, 477, 478, 479, 480, 481, 482, 483, 484, 485, + 486, 6, 7, 8, 9, 10, 11, 12, 13, -1, + 15, 16, -1, -1, 19, 20, 21, 22, 23, 24, + -1, 26, 27, 28, -1, -1, 31, 32, 33, 34, + -1, -1, 37, 38, 39, 40, -1, 42, -1, -1, + 45, 46, -1, -1, -1, 50, 51, -1, -1, -1, + -1, 56, -1, -1, -1, -1, -1, -1, -1, -1, + 65, -1, 67, -1, 69, 70, 71, -1, -1, -1, + -1, -1, -1, -1, 79, 80, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 91, 92, 93, 94, + 95, 96, 97, 98, -1, 100, 101, 102, -1, -1, + -1, -1, -1, -1, -1, 110, 111, -1, 113, 114, + -1, 116, 117, 118, 119, 120, -1, 122, 123, -1, + 125, 126, 127, 128, 129, -1, -1, 132, 133, 134, + 135, 136, 137, 138, 139, 140, 141, 142, -1, -1, + -1, 146, 147, 148, 149, -1, 151, 152, 153, 154, + 155, 156, 157, 158, 159, -1, -1, 162, -1, -1, + -1, -1, -1, -1, -1, -1, 171, 172, 173, 174, + 175, 176, 177, 178, 179, -1, 181, -1, 183, 184, + 185, 186, 187, -1, 189, 190, 191, -1, -1, 194, + 195, 196, 197, 198, -1, 200, 201, 202, -1, 204, + 205, -1, 207, 208, 209, 210, 211, 212, 213, 214, + 215, -1, 217, -1, 219, 220, 221, -1, 223, 224, + 225, -1, -1, -1, 229, 230, 231, -1, 233, 234, + -1, 236, -1, 238, 239, 240, 241, 242, -1, 244, + 245, 246, -1, 248, 249, 250, 251, 252, 253, -1, + 255, -1, 257, -1, 259, 260, 261, -1, 263, -1, + 265, -1, 267, -1, -1, 270, -1, 272, 273, 274, + 275, 276, 277, 278, -1, 280, 281, -1, 283, 284, + -1, 286, 287, 288, -1, -1, 291, 292, 293, 294, + 295, 296, 297, 298, 299, 300, 301, 302, 303, -1, + 305, 306, 307, 308, -1, 310, 311, -1, 313, -1, + 315, 316, 317, 318, 319, 320, -1, 322, -1, -1, + 325, 326, 327, -1, -1, 330, -1, -1, -1, 334, + 335, 336, 337, 338, 339, 340, 341, -1, 343, 344, + 345, 346, 347, 348, 349, 350, 351, 352, 353, 354, + 355, 356, 357, 358, 359, 360, 361, 362, -1, 364, + 365, 366, 367, 368, 369, 370, 371, 372, 373, -1, + 375, 376, -1, 378, 379, 380, 381, 382, 383, 384, + 385, 386, 387, 388, -1, 390, 391, 392, 393, 394, + -1, 396, 397, 398, 399, -1, 401, 402, 403, -1, + 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, + 415, -1, 417, 418, -1, 420, 421, 422, 423, 424, + 425, -1, 427, 428, -1, -1, 431, 432, 433, 434, + -1, 436, 437, 438, 439, 440, 441, 442, -1, 444, + 445, 446, 447, 448, 449, -1, -1, 452, 453, 454, + 455, 456, 457, 458, -1, 460, -1, 462, 463, 464, + -1, -1, 467, -1, -1, 470, 471, 472, 473, 474, + 475, 476, 477, 478, 479, 480, 481, 482, 483, 484, + 485, 486, 6, 7, 8, 9, 10, 11, 12, 13, + -1, 15, 16, -1, -1, 19, 20, 21, 22, 23, + 24, -1, 26, 27, 28, -1, -1, 31, 32, 33, + 34, -1, -1, 37, 38, 39, 40, -1, 42, -1, + -1, 45, 46, -1, -1, -1, 50, 51, -1, -1, + -1, -1, 56, -1, -1, -1, -1, -1, -1, -1, + -1, 65, -1, 67, -1, 69, 70, 71, -1, -1, + -1, -1, -1, -1, -1, 79, 80, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 91, 92, 93, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + -1, -1, -1, -1, -1, -1, 110, 111, -1, 113, + 114, -1, 116, 117, 118, 119, 120, -1, 122, 123, + -1, 125, 126, 127, 128, 129, -1, -1, 132, 133, + 134, 135, 136, -1, 138, 139, 140, 141, 142, -1, + -1, -1, 146, 147, 148, 149, -1, 151, 152, -1, + 154, 155, 156, 157, 158, 159, 160, -1, 162, -1, + -1, -1, -1, -1, -1, -1, -1, 171, 172, 173, + 174, 175, 176, 177, 178, 179, -1, 181, -1, 183, + 184, 185, 186, 187, -1, 189, 190, 191, -1, -1, + 194, 195, 196, 197, 198, -1, 200, 201, 202, -1, + 204, 205, -1, 207, 208, 209, 210, 211, 212, 213, + 214, 215, -1, 217, -1, 219, 220, 221, -1, 223, + -1, 225, -1, -1, -1, 229, 230, 231, 232, 233, + 234, -1, 236, -1, 238, 239, 240, 241, 242, -1, + 244, 245, 246, -1, 248, 249, 250, 251, 252, 253, + -1, 255, -1, 257, -1, 259, 260, 261, -1, 263, + -1, 265, -1, 267, -1, -1, 270, -1, 272, 273, + 274, 275, 276, 277, 278, -1, 280, 281, -1, 283, + -1, -1, 286, 287, 288, -1, -1, 291, 292, 293, + 294, 295, 296, 297, 298, 299, 300, 301, 302, 303, + -1, 305, 306, 307, 308, -1, 310, 311, -1, 313, + -1, 315, 316, 317, 318, 319, 320, -1, 322, -1, + -1, 325, 326, 327, -1, -1, 330, -1, -1, -1, + 334, 335, 336, 337, 338, 339, 340, 341, -1, 343, + 344, 345, 346, 347, 348, 349, -1, 351, 352, 353, + 354, 355, 356, 357, 358, 359, 360, 361, 362, 363, + 364, 365, 366, 367, 368, 369, 370, 371, 372, 373, + -1, 375, 376, -1, 378, 379, 380, 381, 382, 383, + 384, 385, 386, 387, 388, 389, 390, 391, 392, 393, + 394, -1, 396, 397, 398, 399, -1, 401, 402, 403, + -1, 405, 406, 407, 408, 409, 410, 411, 412, 413, + 414, 415, -1, 417, 418, -1, 420, 421, 422, 423, + 424, 425, -1, 427, 428, -1, -1, 431, 432, 433, + 434, -1, 436, 437, 438, 439, 440, 441, 442, -1, + -1, 445, 446, 447, 448, 449, -1, -1, 452, 453, + 454, 455, 456, 457, 458, -1, 460, -1, 462, 463, + 464, -1, -1, 467, -1, -1, 470, 471, 472, 473, + 474, 475, 476, 477, 478, 479, 480, 481, 482, 483, + 484, 485, 486, 6, 7, 8, 9, 10, 11, 12, + 13, -1, 15, 16, -1, -1, 19, 20, 21, 22, + 23, 24, -1, 26, 27, 28, -1, -1, 31, 32, + 33, 34, -1, -1, 37, 38, 39, 40, -1, 42, + -1, -1, 45, 46, -1, -1, -1, 50, 51, -1, + -1, -1, -1, 56, -1, -1, -1, -1, -1, -1, + -1, -1, 65, -1, 67, -1, 69, 70, 71, -1, + -1, -1, 75, 76, 77, 78, 79, 80, -1, 82, + -1, -1, -1, -1, -1, -1, -1, -1, 91, 92, + 93, 94, 95, 96, 97, 98, -1, 100, 101, 102, + -1, -1, -1, -1, -1, -1, -1, 110, 111, -1, + 113, 114, -1, 116, 117, 118, 119, 120, -1, 122, + 123, -1, 125, 126, 127, 128, 129, -1, -1, 132, + 133, 134, 135, 136, -1, 138, 139, 140, 141, 142, + -1, -1, -1, 146, 147, 148, 149, -1, 151, 152, + -1, 154, 155, 156, 157, 158, 159, -1, -1, 162, + -1, -1, -1, -1, -1, -1, -1, -1, 171, 172, + 173, 174, 175, 176, 177, 178, 179, -1, 181, -1, + 183, 184, 185, 186, 187, -1, 189, 190, 191, -1, + -1, 194, 195, 196, 197, 198, -1, 200, 201, 202, + -1, 204, 205, -1, 207, 208, 209, 210, 211, 212, + 213, 214, 215, -1, 217, -1, 219, 220, 221, -1, + 223, -1, 225, -1, -1, -1, 229, 230, 231, -1, + 233, 234, -1, 236, -1, 238, 239, 240, 241, 242, + -1, 244, 245, 246, -1, 248, 249, 250, 251, 252, + 253, -1, 255, -1, 257, -1, 259, 260, 261, -1, + 263, -1, 265, -1, 267, -1, -1, 270, -1, 272, + 273, 274, 275, 276, 277, 278, -1, 280, 281, -1, + 283, -1, -1, 286, 287, 288, -1, -1, 291, 292, + 293, 294, 295, 296, 297, 298, 299, 300, 301, 302, + 303, -1, 305, 306, 307, 308, -1, 310, 311, -1, + 313, -1, 315, 316, 317, 318, 319, 320, -1, 322, + -1, -1, 325, 326, 327, -1, -1, 330, -1, -1, + -1, 334, 335, 336, 337, 338, 339, 340, 341, -1, + 343, 344, 345, 346, 347, 348, 349, -1, 351, 352, + 353, 354, 355, 356, 357, 358, 359, 360, 361, 362, + -1, 364, 365, 366, 367, 368, 369, 370, 371, 372, + 373, -1, 375, 376, -1, 378, 379, 380, 381, 382, + 383, 384, 385, 386, 387, 388, -1, 390, 391, 392, + 393, 394, -1, 396, 397, 398, 399, -1, 401, 402, + 403, -1, 405, 406, 407, 408, 409, 410, 411, 412, + 413, 414, 415, -1, 417, 418, -1, 420, 421, 422, + 423, 424, 425, -1, 427, 428, -1, -1, 431, 432, + 433, 434, -1, 436, 437, 438, 439, 440, 441, 442, + -1, -1, 445, 446, 447, 448, 449, -1, -1, 452, + 453, 454, 455, 456, 457, 458, -1, 460, -1, 462, + 463, 464, -1, -1, 467, -1, -1, 470, 471, 472, + 473, 474, 475, 476, 477, 478, 479, 480, 481, 482, + 483, 484, 485, 486, 6, 7, 8, 9, 10, 11, + 12, 13, -1, 15, 16, -1, -1, 19, 20, 21, + 22, 23, 24, -1, 26, 27, 28, -1, -1, 31, + 32, 33, 34, -1, -1, 37, 38, 39, 40, -1, + 42, -1, -1, 45, 46, -1, -1, -1, 50, 51, + -1, -1, -1, -1, 56, -1, -1, -1, -1, -1, + -1, -1, -1, 65, -1, 67, -1, 69, 70, 71, + -1, -1, -1, 75, 76, 77, 78, 79, 80, -1, + 82, -1, -1, -1, -1, -1, -1, -1, -1, 91, + 92, 93, 94, 95, 96, 97, 98, -1, 100, 101, + 102, -1, -1, -1, -1, -1, -1, -1, 110, 111, + -1, 113, 114, -1, 116, 117, 118, 119, 120, -1, + 122, 123, -1, 125, 126, 127, 128, 129, -1, -1, + 132, 133, 134, 135, 136, -1, 138, 139, 140, 141, + 142, -1, -1, -1, 146, 147, 148, 149, -1, 151, + 152, -1, 154, 155, 156, 157, 158, 159, -1, -1, + 162, -1, -1, -1, -1, -1, -1, -1, -1, 171, + 172, 173, 174, 175, 176, 177, 178, 179, -1, 181, + -1, 183, 184, 185, 186, 187, -1, 189, 190, 191, + -1, -1, 194, 195, 196, 197, 198, -1, 200, 201, + 202, -1, 204, 205, -1, 207, 208, 209, 210, 211, + 212, 213, 214, 215, -1, 217, -1, 219, 220, 221, + -1, 223, -1, 225, -1, -1, -1, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, -1, 244, 245, 246, -1, 248, 249, 250, 251, + 252, 253, -1, 255, -1, 257, -1, 259, 260, 261, + -1, 263, -1, 265, -1, 267, -1, -1, 270, -1, + 272, 273, 274, 275, 276, 277, 278, -1, 280, 281, + -1, 283, -1, -1, 286, 287, 288, -1, -1, 291, + 292, 293, 294, 295, 296, 297, 298, 299, 300, 301, + 302, 303, -1, 305, 306, 307, 308, -1, 310, 311, + -1, 313, -1, 315, 316, 317, 318, 319, 320, -1, + 322, -1, -1, 325, 326, 327, -1, -1, 330, -1, + -1, -1, 334, 335, 336, 337, 338, 339, 340, 341, + -1, 343, 344, 345, 346, 347, 348, 349, -1, 351, + 352, 353, 354, 355, 356, 357, 358, 359, 360, 361, + 362, -1, 364, 365, 366, 367, 368, 369, 370, 371, + 372, 373, -1, 375, 376, -1, 378, 379, 380, 381, + 382, 383, 384, 385, 386, 387, 388, -1, 390, 391, + 392, 393, 394, -1, 396, 397, 398, 399, -1, 401, + 402, 403, -1, 405, 406, 407, 408, 409, 410, 411, + 412, 413, 414, 415, -1, 417, 418, -1, 420, 421, + 422, 423, 424, 425, -1, 427, 428, -1, -1, 431, + 432, 433, 434, -1, 436, 437, 438, 439, 440, 441, + 442, -1, -1, 445, 446, 447, 448, 449, -1, -1, + 452, 453, 454, 455, 456, 457, 458, -1, 460, -1, + 462, 463, 464, -1, -1, 467, -1, -1, 470, 471, + 472, 473, 474, 475, 476, 477, 478, 479, 480, 481, + 482, 483, 484, 485, 486, 6, 7, 8, 9, 10, + 11, 12, 13, -1, 15, 16, -1, -1, 19, 20, + 21, 22, 23, 24, -1, 26, 27, 28, -1, -1, + 31, 32, 33, 34, -1, -1, 37, 38, 39, 40, + -1, 42, -1, -1, 45, 46, -1, -1, -1, 50, + 51, -1, -1, -1, -1, 56, -1, -1, -1, -1, + -1, -1, -1, -1, 65, -1, 67, -1, 69, 70, + 71, -1, -1, -1, -1, -1, -1, -1, 79, 80, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, + 101, 102, -1, -1, -1, -1, -1, -1, -1, 110, + 111, -1, 113, 114, -1, 116, 117, 118, 119, 120, + -1, 122, 123, -1, 125, 126, 127, 128, 129, -1, + -1, 132, 133, 134, 135, 136, -1, 138, 139, 140, + 141, 142, -1, -1, -1, 146, 147, 148, 149, -1, + 151, 152, -1, 154, 155, 156, 157, 158, 159, 160, + -1, 162, -1, -1, -1, -1, -1, -1, -1, -1, + 171, 172, 173, 174, 175, 176, 177, 178, 179, -1, + 181, -1, 183, 184, 185, 186, 187, -1, 189, 190, + 191, -1, -1, 194, 195, 196, 197, 198, -1, 200, + 201, 202, -1, 204, 205, -1, 207, 208, 209, 210, + 211, 212, 213, 214, 215, -1, 217, -1, 219, 220, + 221, -1, 223, -1, 225, -1, -1, -1, 229, 230, + 231, 232, 233, 234, -1, 236, -1, 238, 239, 240, + 241, 242, -1, 244, 245, 246, -1, 248, 249, 250, + 251, 252, 253, -1, 255, -1, 257, -1, 259, 260, + 261, -1, 263, -1, 265, -1, 267, -1, -1, 270, + -1, 272, 273, 274, 275, 276, 277, 278, -1, 280, + 281, -1, 283, -1, -1, 286, 287, 288, -1, -1, + 291, 292, 293, 294, 295, 296, 297, 298, 299, 300, + 301, 302, 303, -1, 305, 306, 307, 308, -1, 310, + 311, -1, 313, -1, 315, 316, 317, 318, 319, 320, + -1, 322, -1, -1, 325, 326, 327, -1, -1, 330, + -1, -1, -1, 334, 335, 336, 337, 338, 339, 340, + 341, -1, 343, 344, 345, 346, 347, 348, 349, -1, + 351, 352, 353, 354, 355, 356, 357, 358, 359, 360, + 361, 362, 363, 364, 365, 366, 367, 368, 369, 370, + 371, 372, 373, -1, 375, 376, -1, 378, 379, 380, + 381, 382, 383, 384, 385, 386, 387, 388, 389, 390, + 391, 392, 393, 394, -1, 396, 397, 398, 399, -1, + 401, 402, 403, -1, 405, 406, 407, 408, 409, 410, + 411, 412, 413, 414, 415, -1, 417, 418, -1, 420, + 421, 422, 423, 424, 425, -1, 427, 428, -1, -1, + 431, 432, 433, 434, -1, 436, 437, 438, 439, 440, + 441, 442, -1, -1, 445, 446, 447, 448, 449, -1, + -1, 452, 453, 454, 455, 456, 457, 458, -1, 460, + -1, 462, 463, 464, -1, -1, 467, -1, -1, 470, + 471, 472, 473, 474, 475, 476, 477, 478, 479, 480, + 481, 482, 483, 484, 485, 486, 6, 7, 8, 9, + 10, 11, 12, 13, -1, 15, 16, -1, -1, 19, + 20, 21, 22, 23, 24, -1, 26, 27, 28, -1, + -1, 31, 32, 33, 34, -1, -1, 37, 38, 39, + 40, -1, 42, -1, -1, 45, 46, -1, -1, -1, + 50, 51, -1, -1, -1, -1, 56, -1, -1, -1, + -1, -1, -1, -1, -1, 65, -1, 67, -1, 69, + 70, 71, -1, -1, -1, -1, -1, -1, -1, 79, + 80, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 91, 92, 93, 94, 95, 96, 97, 98, -1, + 100, 101, 102, -1, -1, -1, -1, -1, -1, -1, + 110, 111, -1, 113, 114, -1, 116, 117, 118, 119, + 120, -1, 122, 123, -1, 125, 126, 127, 128, 129, + -1, -1, 132, 133, 134, 135, 136, 137, 138, 139, + 140, 141, 142, -1, -1, -1, 146, 147, 148, 149, + -1, 151, 152, 153, 154, 155, 156, 157, 158, 159, + -1, -1, 162, -1, -1, -1, -1, -1, -1, -1, + -1, 171, 172, 173, 174, 175, 176, 177, 178, 179, + -1, 181, -1, 183, 184, 185, 186, 187, -1, 189, + 190, 191, -1, -1, 194, 195, 196, 197, 198, -1, + 200, 201, 202, -1, 204, 205, -1, 207, 208, 209, + 210, 211, 212, 213, 214, 215, -1, 217, -1, 219, + 220, 221, -1, 223, 224, 225, -1, -1, -1, 229, + 230, 231, -1, 233, 234, -1, 236, -1, 238, 239, + 240, 241, 242, -1, 244, 245, 246, -1, 248, 249, + 250, 251, 252, 253, -1, 255, -1, 257, -1, 259, + 260, 261, -1, 263, -1, 265, -1, 267, -1, -1, + 270, -1, 272, 273, 274, 275, 276, 277, 278, -1, + 280, 281, -1, 283, -1, -1, 286, 287, 288, -1, + -1, 291, 292, 293, 294, 295, 296, 297, 298, 299, + 300, 301, 302, 303, -1, 305, 306, 307, 308, -1, + 310, 311, -1, 313, -1, 315, 316, 317, 318, 319, + 320, -1, 322, -1, -1, 325, 326, 327, -1, -1, + 330, -1, -1, -1, 334, 335, 336, 337, 338, 339, + 340, 341, -1, 343, 344, 345, 346, 347, 348, 349, + 350, 351, 352, 353, 354, 355, 356, 357, 358, 359, + 360, 361, 362, -1, 364, 365, 366, 367, 368, 369, + 370, 371, 372, 373, -1, 375, 376, -1, 378, 379, + 380, 381, 382, 383, 384, 385, 386, 387, 388, -1, + 390, 391, 392, 393, 394, -1, 396, 397, 398, 399, + -1, 401, 402, 403, -1, 405, 406, 407, 408, 409, + 410, 411, 412, 413, 414, 415, -1, 417, 418, -1, + 420, 421, 422, 423, 424, 425, -1, 427, 428, -1, + -1, 431, 432, 433, 434, -1, 436, 437, 438, 439, + 440, 441, 442, -1, 444, 445, 446, 447, 448, 449, + -1, -1, 452, 453, 454, 455, 456, 457, 458, -1, + 460, -1, 462, 463, 464, -1, -1, 467, -1, -1, + 470, 471, 472, 473, 474, 475, 476, 477, 478, 479, + 480, 481, 482, 483, 484, 485, 486, 6, 7, 8, + 9, 10, 11, 12, 13, -1, 15, 16, -1, -1, + 19, 20, 21, 22, 23, 24, -1, 26, 27, 28, + -1, -1, 31, 32, 33, 34, -1, -1, 37, 38, + 39, 40, -1, 42, -1, -1, 45, 46, -1, -1, + -1, 50, 51, -1, -1, -1, -1, 56, -1, -1, + -1, -1, -1, -1, -1, -1, 65, -1, 67, -1, + 69, 70, 71, 72, -1, -1, -1, -1, -1, -1, + 79, 80, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 91, 92, 93, 94, 95, 96, 97, 98, + 99, 100, 101, 102, -1, -1, -1, -1, -1, -1, + -1, 110, 111, -1, 113, 114, -1, 116, 117, 118, + 119, 120, -1, 122, 123, -1, 125, 126, 127, 128, + 129, -1, -1, 132, 133, 134, 135, 136, -1, 138, + 139, 140, 141, 142, -1, -1, -1, 146, 147, 148, + 149, -1, 151, 152, -1, 154, 155, 156, 157, 158, + 159, -1, -1, 162, 163, -1, -1, -1, -1, -1, + -1, -1, 171, 172, 173, 174, 175, 176, 177, 178, + 179, 180, 181, -1, 183, 184, 185, 186, 187, -1, + 189, 190, 191, -1, -1, 194, 195, 196, 197, 198, + -1, 200, 201, 202, -1, 204, 205, -1, 207, 208, + 209, 210, 211, 212, 213, 214, 215, -1, 217, -1, + 219, 220, 221, -1, 223, -1, 225, -1, -1, -1, + 229, 230, 231, -1, 233, 234, -1, 236, -1, 238, + 239, 240, 241, 242, -1, 244, 245, 246, -1, 248, + 249, 250, 251, 252, 253, -1, 255, -1, 257, -1, + 259, 260, 261, -1, 263, -1, 265, -1, 267, -1, + -1, 270, -1, 272, 273, 274, 275, 276, 277, 278, + -1, 280, 281, -1, 283, -1, -1, 286, 287, 288, + -1, -1, 291, 292, 293, 294, 295, 296, 297, 298, + 299, 300, 301, 302, 303, -1, 305, 306, 307, 308, + -1, 310, 311, -1, 313, -1, 315, 316, 317, 318, + 319, 320, -1, 322, -1, -1, 325, 326, 327, -1, + -1, 330, -1, -1, -1, 334, 335, 336, 337, 338, + 339, 340, 341, -1, 343, 344, 345, 346, 347, 348, + 349, -1, 351, 352, 353, 354, 355, 356, 357, 358, + 359, 360, 361, 362, -1, 364, 365, 366, 367, 368, + 369, 370, 371, 372, 373, -1, 375, 376, -1, 378, + 379, 380, 381, 382, 383, 384, 385, 386, 387, 388, + -1, 390, 391, 392, 393, 394, -1, 396, 397, 398, + 399, -1, 401, 402, 403, -1, 405, 406, 407, 408, + 409, 410, 411, 412, 413, 414, 415, -1, 417, 418, + -1, 420, 421, 422, 423, 424, 425, -1, 427, 428, + -1, -1, 431, 432, 433, 434, -1, 436, 437, 438, + 439, 440, 441, 442, -1, -1, 445, 446, 447, 448, + 449, -1, -1, 452, 453, 454, 455, 456, 457, 458, + -1, 460, -1, 462, 463, 464, -1, -1, 467, -1, + -1, 470, 471, 472, 473, 474, 475, 476, 477, 478, + 479, 480, 481, 482, 483, 484, 485, 486, 6, 7, + 8, 9, 10, 11, 12, 13, -1, 15, 16, -1, + -1, 19, 20, 21, 22, 23, 24, -1, 26, 27, + 28, -1, -1, 31, 32, 33, 34, -1, -1, 37, + 38, 39, 40, -1, 42, -1, -1, 45, 46, -1, + -1, -1, 50, 51, -1, -1, -1, -1, 56, -1, + -1, -1, -1, -1, -1, -1, -1, 65, -1, 67, + -1, 69, 70, 71, -1, -1, -1, -1, -1, -1, + -1, 79, 80, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 91, 92, 93, 94, 95, 96, 97, + 98, 99, 100, 101, 102, -1, -1, -1, -1, -1, + -1, -1, 110, 111, -1, 113, 114, -1, 116, 117, + 118, 119, 120, -1, 122, 123, -1, 125, 126, 127, + 128, 129, -1, -1, 132, 133, 134, 135, 136, -1, + 138, 139, 140, 141, 142, -1, -1, -1, 146, 147, + 148, 149, -1, 151, 152, -1, 154, 155, 156, 157, + 158, 159, 160, -1, 162, -1, -1, -1, -1, -1, + -1, -1, -1, 171, 172, 173, 174, 175, 176, 177, + 178, 179, -1, 181, -1, 183, 184, 185, 186, 187, + -1, 189, 190, 191, -1, -1, 194, 195, 196, 197, + 198, -1, 200, 201, 202, -1, 204, 205, -1, 207, + 208, 209, 210, 211, 212, 213, 214, 215, -1, 217, + -1, 219, 220, 221, -1, 223, -1, 225, -1, -1, + -1, 229, 230, 231, -1, 233, 234, -1, 236, -1, + 238, 239, 240, 241, 242, -1, 244, 245, 246, -1, + 248, 249, 250, 251, 252, 253, -1, 255, -1, 257, + -1, 259, 260, 261, -1, 263, -1, 265, -1, 267, + -1, -1, 270, -1, 272, 273, 274, 275, 276, 277, + 278, -1, 280, 281, -1, 283, -1, -1, 286, 287, + 288, -1, -1, 291, 292, 293, 294, 295, 296, 297, + 298, 299, 300, 301, 302, 303, -1, 305, 306, 307, + 308, -1, 310, 311, -1, 313, -1, 315, 316, 317, + 318, 319, 320, -1, 322, -1, -1, 325, 326, 327, + -1, -1, 330, -1, -1, -1, 334, 335, 336, 337, + 338, 339, 340, 341, -1, 343, 344, 345, 346, 347, + 348, 349, -1, 351, 352, 353, 354, 355, 356, 357, + 358, 359, 360, 361, 362, 363, 364, 365, 366, 367, + 368, 369, 370, 371, 372, 373, -1, 375, 376, -1, + 378, 379, 380, 381, 382, 383, 384, 385, 386, 387, + 388, 389, 390, 391, 392, 393, 394, -1, 396, 397, + 398, 399, -1, 401, 402, 403, -1, 405, 406, 407, + 408, 409, 410, 411, 412, 413, 414, 415, -1, 417, + 418, -1, 420, 421, 422, 423, 424, 425, -1, 427, + 428, -1, -1, 431, 432, 433, 434, -1, 436, 437, + 438, 439, 440, 441, 442, -1, -1, 445, 446, 447, + 448, 449, -1, -1, 452, 453, 454, 455, 456, 457, + 458, -1, 460, -1, 462, 463, 464, -1, -1, 467, + -1, -1, 470, 471, 472, 473, 474, 475, 476, 477, + 478, 479, 480, 481, 482, 483, 484, 485, 486, 6, + 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, + -1, -1, 19, 20, 21, 22, 23, 24, -1, 26, + 27, 28, -1, -1, 31, 32, 33, 34, -1, -1, + 37, 38, 39, 40, -1, 42, -1, -1, 45, 46, + -1, -1, -1, 50, 51, -1, -1, -1, -1, 56, + -1, -1, -1, -1, -1, -1, -1, -1, 65, -1, + 67, -1, 69, 70, 71, 72, -1, -1, -1, -1, + -1, -1, 79, 80, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 91, 92, 93, 94, 95, 96, + 97, 98, 99, 100, 101, 102, -1, -1, -1, -1, + -1, -1, -1, 110, 111, -1, 113, 114, -1, 116, + 117, 118, 119, 120, -1, 122, 123, -1, 125, 126, + 127, 128, 129, -1, -1, 132, 133, 134, 135, 136, + -1, 138, 139, 140, 141, 142, -1, -1, -1, 146, + 147, 148, 149, -1, 151, 152, -1, 154, 155, 156, + 157, 158, 159, -1, -1, 162, -1, -1, -1, -1, + -1, -1, -1, -1, 171, 172, 173, 174, 175, 176, + 177, 178, 179, -1, 181, -1, 183, 184, 185, 186, + 187, -1, 189, 190, 191, -1, -1, 194, 195, 196, + 197, 198, -1, 200, 201, 202, -1, 204, 205, -1, + 207, 208, 209, 210, 211, 212, 213, 214, 215, -1, + 217, -1, 219, 220, 221, -1, 223, -1, 225, -1, + -1, -1, 229, 230, 231, -1, 233, 234, -1, 236, + -1, 238, 239, 240, 241, 242, -1, 244, 245, 246, + -1, 248, 249, 250, 251, 252, 253, -1, 255, -1, + 257, -1, 259, 260, 261, -1, 263, -1, 265, -1, + 267, -1, -1, 270, -1, 272, 273, 274, 275, 276, + 277, 278, -1, 280, 281, -1, 283, -1, -1, 286, + 287, 288, -1, -1, 291, 292, 293, 294, 295, 296, + 297, 298, 299, 300, 301, 302, 303, -1, 305, 306, + 307, 308, -1, 310, 311, -1, 313, -1, 315, 316, + 317, 318, 319, 320, -1, 322, -1, -1, 325, 326, + 327, -1, -1, 330, -1, -1, -1, 334, 335, 336, + 337, 338, 339, 340, 341, -1, 343, 344, 345, 346, + 347, 348, 349, -1, 351, 352, 353, 354, 355, 356, + 357, 358, 359, 360, 361, 362, -1, 364, 365, 366, + 367, 368, 369, 370, 371, 372, 373, -1, 375, 376, + -1, 378, 379, 380, 381, 382, 383, 384, 385, 386, + 387, 388, -1, 390, 391, 392, 393, 394, -1, 396, + 397, 398, 399, -1, 401, 402, 403, -1, 405, 406, + 407, 408, 409, 410, 411, 412, 413, 414, 415, -1, + 417, 418, -1, 420, 421, 422, 423, 424, 425, -1, + 427, 428, -1, -1, 431, 432, 433, 434, -1, 436, + 437, 438, 439, 440, 441, 442, -1, -1, 445, 446, + 447, 448, 449, -1, -1, 452, 453, 454, 455, 456, + 457, 458, -1, 460, -1, 462, 463, 464, -1, -1, + 467, -1, -1, 470, 471, 472, 473, 474, 475, 476, + 477, 478, 479, 480, 481, 482, 483, 484, 485, 486, + 6, 7, 8, 9, 10, 11, 12, 13, -1, 15, + 16, -1, -1, 19, 20, 21, 22, 23, 24, -1, + 26, 27, 28, -1, -1, 31, 32, 33, 34, -1, + -1, 37, 38, 39, 40, -1, 42, -1, -1, 45, + 46, -1, -1, -1, 50, 51, -1, -1, -1, -1, + 56, -1, -1, -1, -1, -1, -1, -1, -1, 65, + -1, 67, -1, 69, 70, 71, -1, -1, -1, -1, + -1, -1, -1, 79, 80, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 91, 92, 93, 94, 95, + 96, 97, 98, 99, 100, 101, 102, -1, -1, -1, + -1, -1, -1, -1, 110, 111, -1, 113, 114, -1, + 116, 117, 118, 119, 120, -1, 122, 123, -1, 125, + 126, 127, 128, 129, -1, -1, 132, 133, 134, 135, + 136, -1, 138, 139, 140, 141, 142, -1, -1, -1, + 146, 147, 148, 149, -1, 151, 152, -1, 154, 155, + 156, 157, 158, 159, -1, -1, 162, -1, -1, -1, + -1, -1, -1, -1, -1, 171, 172, 173, 174, 175, + 176, 177, 178, 179, -1, 181, -1, 183, 184, 185, + 186, 187, -1, 189, 190, 191, -1, -1, 194, 195, + 196, 197, 198, -1, 200, 201, 202, -1, 204, 205, + -1, 207, 208, 209, 210, 211, 212, 213, 214, 215, + -1, 217, -1, 219, 220, 221, -1, 223, 224, 225, + -1, -1, -1, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, -1, 244, 245, + 246, -1, 248, 249, 250, 251, 252, 253, -1, 255, + -1, 257, -1, 259, 260, 261, -1, 263, -1, 265, + -1, 267, -1, -1, 270, -1, 272, 273, 274, 275, + 276, 277, 278, -1, 280, 281, -1, 283, -1, -1, + 286, 287, 288, -1, -1, 291, 292, 293, 294, 295, + 296, 297, 298, 299, 300, 301, 302, 303, -1, 305, + 306, 307, 308, -1, 310, 311, -1, 313, -1, 315, + 316, 317, 318, 319, 320, -1, 322, -1, -1, 325, + 326, 327, -1, -1, 330, -1, -1, -1, 334, 335, + 336, 337, 338, 339, 340, 341, -1, 343, 344, 345, + 346, 347, 348, 349, -1, 351, 352, 353, 354, 355, + 356, 357, 358, 359, 360, 361, 362, -1, 364, 365, + 366, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, -1, 378, 379, 380, 381, 382, 383, 384, 385, + 386, 387, 388, -1, 390, 391, 392, 393, 394, -1, + 396, 397, 398, 399, -1, 401, 402, 403, -1, 405, + 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, + -1, 417, 418, 419, 420, 421, 422, 423, 424, 425, + -1, 427, 428, -1, -1, 431, 432, 433, 434, -1, + 436, 437, 438, 439, 440, 441, 442, -1, -1, 445, + 446, 447, 448, 449, -1, -1, 452, 453, 454, 455, + 456, 457, 458, -1, 460, -1, 462, 463, 464, -1, + -1, 467, -1, -1, 470, 471, 472, 473, 474, 475, + 476, 477, 478, 479, 480, 481, 482, 483, 484, 485, + 486, 6, 7, 8, 9, 10, 11, 12, 13, -1, + 15, 16, -1, -1, 19, 20, 21, 22, 23, 24, + -1, 26, 27, 28, -1, -1, 31, 32, 33, 34, + -1, -1, 37, 38, 39, 40, -1, 42, -1, -1, + 45, 46, -1, -1, -1, 50, 51, -1, -1, -1, + -1, 56, -1, -1, -1, -1, -1, -1, -1, -1, + 65, -1, 67, -1, 69, 70, 71, -1, -1, -1, + -1, -1, -1, -1, 79, 80, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 91, 92, 93, 94, + 95, 96, 97, 98, -1, 100, 101, 102, -1, -1, + -1, -1, -1, -1, -1, 110, 111, -1, 113, 114, + -1, 116, 117, 118, 119, 120, -1, 122, 123, -1, + 125, 126, 127, 128, 129, -1, -1, 132, 133, 134, + 135, 136, -1, 138, 139, 140, 141, 142, -1, -1, + -1, 146, 147, 148, 149, -1, 151, 152, -1, 154, + 155, 156, 157, 158, 159, 160, -1, 162, -1, -1, + -1, -1, -1, -1, -1, -1, 171, 172, 173, 174, + 175, 176, 177, 178, 179, -1, 181, -1, 183, 184, + 185, 186, 187, -1, 189, 190, 191, -1, -1, 194, + 195, 196, 197, 198, -1, 200, 201, 202, -1, 204, + 205, -1, 207, 208, 209, 210, 211, 212, 213, 214, + 215, -1, 217, -1, 219, 220, 221, -1, 223, -1, + 225, -1, -1, -1, 229, 230, 231, -1, 233, 234, + -1, 236, -1, 238, 239, 240, 241, 242, -1, 244, + 245, 246, -1, 248, 249, 250, 251, 252, 253, -1, + 255, -1, 257, -1, 259, 260, 261, -1, 263, -1, + 265, -1, 267, -1, -1, 270, -1, 272, 273, 274, + 275, 276, 277, 278, -1, 280, 281, -1, 283, -1, + -1, 286, 287, 288, -1, -1, 291, 292, 293, 294, + 295, 296, 297, 298, 299, 300, 301, 302, 303, -1, + 305, 306, 307, 308, -1, 310, 311, -1, 313, -1, + 315, 316, 317, 318, 319, 320, -1, 322, -1, -1, + 325, 326, 327, -1, -1, 330, -1, -1, -1, 334, + 335, 336, 337, 338, 339, 340, 341, -1, 343, 344, + 345, 346, 347, 348, 349, -1, 351, 352, 353, 354, + 355, 356, 357, 358, 359, 360, 361, 362, 363, 364, + 365, 366, 367, 368, 369, 370, 371, 372, 373, -1, + 375, 376, -1, 378, 379, 380, 381, 382, 383, 384, + 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, + -1, 396, 397, 398, 399, -1, 401, 402, 403, -1, + 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, + 415, -1, 417, 418, -1, 420, 421, 422, 423, 424, + 425, -1, 427, 428, -1, -1, 431, 432, 433, 434, + -1, 436, 437, 438, 439, 440, 441, 442, -1, -1, + 445, 446, 447, 448, 449, -1, -1, 452, 453, 454, + 455, 456, 457, 458, -1, 460, -1, 462, 463, 464, + -1, -1, 467, -1, -1, 470, 471, 472, 473, 474, + 475, 476, 477, 478, 479, 480, 481, 482, 483, 484, + 485, 486, 6, 7, 8, 9, 10, 11, 12, 13, + -1, 15, 16, -1, -1, 19, 20, 21, 22, 23, + 24, -1, 26, 27, 28, -1, -1, 31, 32, 33, + 34, -1, -1, 37, 38, 39, 40, -1, 42, -1, + -1, 45, 46, -1, -1, -1, 50, 51, -1, -1, + -1, -1, 56, -1, -1, -1, -1, -1, -1, -1, + -1, 65, -1, 67, -1, 69, 70, 71, -1, -1, + -1, -1, -1, -1, -1, 79, 80, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 91, 92, 93, + 94, 95, 96, 97, 98, -1, 100, 101, 102, 103, + 104, -1, -1, -1, -1, -1, 110, 111, -1, 113, + 114, -1, 116, 117, 118, 119, 120, -1, 122, 123, + -1, 125, 126, 127, 128, 129, -1, -1, 132, 133, + 134, 135, 136, -1, 138, 139, 140, 141, 142, -1, + -1, -1, 146, 147, 148, 149, -1, 151, 152, -1, + 154, 155, 156, 157, 158, 159, -1, -1, 162, -1, + -1, -1, -1, -1, -1, -1, -1, 171, 172, 173, + 174, 175, 176, 177, 178, 179, -1, 181, -1, 183, + 184, 185, 186, 187, -1, 189, 190, 191, -1, -1, + 194, 195, 196, 197, 198, -1, 200, 201, 202, -1, + 204, 205, -1, 207, 208, 209, 210, 211, 212, 213, + 214, 215, -1, 217, -1, 219, 220, 221, -1, 223, + -1, 225, -1, -1, -1, 229, 230, 231, -1, 233, + 234, -1, 236, -1, 238, 239, 240, 241, 242, -1, + 244, 245, 246, -1, 248, 249, 250, 251, 252, 253, + -1, 255, -1, 257, -1, 259, 260, 261, -1, 263, + -1, 265, -1, 267, -1, -1, 270, -1, 272, 273, + 274, 275, 276, 277, 278, -1, 280, 281, -1, 283, + -1, -1, 286, 287, 288, -1, -1, 291, 292, 293, + 294, 295, 296, 297, 298, 299, 300, 301, 302, 303, + -1, 305, 306, 307, 308, -1, 310, 311, -1, 313, + -1, 315, 316, 317, 318, 319, 320, -1, 322, -1, + -1, 325, 326, 327, -1, -1, 330, -1, -1, -1, + 334, 335, 336, 337, 338, 339, 340, 341, -1, 343, + 344, 345, 346, 347, 348, 349, -1, 351, 352, 353, + 354, 355, 356, 357, 358, 359, 360, 361, 362, -1, + 364, 365, 366, 367, 368, 369, 370, 371, 372, 373, + -1, 375, 376, -1, 378, 379, 380, 381, 382, 383, + 384, 385, 386, 387, 388, -1, 390, 391, 392, 393, + 394, -1, 396, 397, 398, 399, -1, 401, 402, 403, + -1, 405, 406, 407, 408, 409, 410, 411, 412, 413, + 414, 415, -1, 417, 418, -1, 420, 421, 422, 423, + 424, 425, -1, 427, 428, -1, -1, 431, 432, 433, + 434, -1, 436, 437, 438, 439, 440, 441, 442, -1, + -1, 445, 446, 447, 448, 449, -1, -1, 452, 453, + 454, 455, 456, 457, 458, -1, 460, 461, 462, 463, + 464, -1, -1, 467, -1, -1, 470, 471, 472, 473, + 474, 475, 476, 477, 478, 479, 480, 481, 482, 483, + 484, 485, 486, 6, 7, 8, 9, 10, 11, 12, + 13, 14, 15, 16, -1, -1, 19, 20, 21, 22, + 23, 24, -1, 26, 27, 28, -1, -1, 31, 32, + 33, 34, -1, -1, 37, 38, 39, 40, -1, 42, + -1, -1, 45, 46, -1, -1, -1, 50, 51, -1, + -1, -1, -1, 56, -1, -1, -1, -1, -1, -1, + -1, -1, 65, -1, 67, -1, 69, 70, 71, 72, + -1, -1, -1, -1, -1, -1, 79, 80, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 91, 92, + 93, 94, 95, 96, 97, 98, -1, 100, 101, 102, + -1, -1, -1, -1, -1, -1, -1, 110, 111, -1, + 113, 114, -1, 116, 117, 118, 119, 120, -1, 122, + 123, -1, 125, 126, 127, 128, 129, -1, -1, 132, + 133, 134, 135, 136, -1, 138, 139, 140, 141, 142, + -1, -1, -1, 146, 147, 148, 149, -1, 151, 152, + -1, 154, 155, 156, 157, 158, 159, -1, -1, 162, + -1, -1, -1, -1, -1, -1, -1, -1, 171, 172, + 173, 174, 175, 176, 177, 178, 179, -1, 181, -1, + 183, 184, 185, 186, 187, -1, 189, 190, 191, -1, + -1, 194, 195, 196, 197, 198, -1, 200, 201, 202, + -1, 204, 205, -1, 207, 208, 209, 210, 211, 212, + 213, 214, 215, -1, 217, -1, 219, 220, 221, -1, + 223, -1, 225, -1, -1, -1, 229, 230, 231, -1, + 233, 234, -1, 236, -1, 238, 239, 240, 241, 242, + -1, 244, 245, 246, -1, 248, 249, 250, 251, 252, + 253, -1, 255, -1, 257, -1, 259, 260, 261, -1, + 263, -1, 265, -1, 267, -1, -1, 270, -1, 272, + 273, 274, 275, 276, 277, 278, -1, 280, 281, -1, + 283, -1, -1, 286, 287, 288, -1, -1, 291, 292, + 293, 294, 295, 296, 297, 298, 299, 300, 301, 302, + 303, -1, 305, 306, 307, 308, -1, 310, 311, -1, + 313, -1, 315, 316, 317, 318, 319, 320, -1, 322, + -1, -1, 325, 326, 327, -1, -1, 330, -1, -1, + -1, 334, 335, 336, 337, 338, 339, 340, 341, -1, + 343, 344, 345, 346, 347, 348, 349, -1, 351, 352, + 353, 354, 355, 356, 357, 358, 359, 360, 361, 362, + -1, 364, 365, 366, 367, 368, 369, 370, 371, 372, + 373, -1, 375, 376, -1, 378, 379, 380, 381, 382, + 383, 384, 385, 386, 387, 388, -1, 390, 391, 392, + 393, 394, -1, 396, 397, 398, 399, -1, 401, 402, + 403, -1, 405, 406, 407, 408, 409, 410, 411, 412, + 413, 414, 415, -1, 417, 418, 419, 420, 421, 422, + 423, 424, 425, -1, 427, 428, -1, -1, 431, 432, + 433, 434, -1, 436, 437, 438, 439, 440, 441, 442, + -1, -1, 445, 446, 447, 448, 449, -1, -1, 452, + 453, 454, 455, 456, 457, 458, -1, 460, -1, 462, + 463, 464, -1, -1, 467, -1, -1, 470, 471, 472, + 473, 474, 475, 476, 477, 478, 479, 480, 481, 482, + 483, 484, 485, 486, 6, 7, 8, 9, 10, 11, + 12, 13, -1, 15, 16, -1, -1, 19, 20, 21, + 22, 23, 24, -1, 26, 27, 28, -1, -1, 31, + 32, 33, 34, -1, -1, 37, 38, 39, 40, -1, + 42, -1, -1, 45, 46, -1, -1, -1, 50, 51, + -1, -1, -1, -1, 56, -1, -1, -1, -1, -1, + -1, -1, -1, 65, -1, 67, -1, 69, 70, 71, + 72, -1, -1, -1, -1, -1, -1, 79, 80, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 91, + 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, + 102, -1, -1, -1, -1, -1, -1, -1, 110, 111, + -1, 113, 114, -1, 116, 117, 118, 119, 120, -1, + 122, 123, -1, 125, 126, 127, 128, 129, -1, -1, + 132, 133, 134, 135, 136, -1, 138, 139, 140, 141, + 142, -1, -1, -1, 146, 147, 148, 149, -1, 151, + 152, -1, 154, 155, 156, 157, 158, 159, -1, -1, + 162, -1, -1, -1, -1, -1, -1, -1, -1, 171, + 172, 173, 174, 175, 176, 177, 178, 179, -1, 181, + -1, 183, 184, 185, 186, 187, -1, 189, 190, 191, + -1, -1, 194, 195, 196, 197, 198, -1, 200, 201, + 202, -1, 204, 205, -1, 207, 208, 209, 210, 211, + 212, 213, 214, 215, -1, 217, -1, 219, 220, 221, + -1, 223, -1, 225, -1, -1, -1, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, -1, 244, 245, 246, -1, 248, 249, 250, 251, + 252, 253, -1, 255, -1, 257, -1, 259, 260, 261, + -1, 263, -1, 265, -1, 267, -1, -1, 270, -1, + 272, 273, 274, 275, 276, 277, 278, -1, 280, 281, + -1, 283, -1, -1, 286, 287, 288, -1, -1, 291, + 292, 293, 294, 295, 296, 297, 298, 299, 300, 301, + 302, 303, -1, 305, 306, 307, 308, -1, 310, 311, + -1, 313, -1, 315, 316, 317, 318, 319, 320, -1, + 322, -1, -1, 325, 326, 327, -1, -1, 330, -1, + -1, -1, 334, 335, 336, 337, 338, 339, 340, 341, + -1, 343, 344, 345, 346, 347, 348, 349, -1, 351, + 352, 353, 354, 355, 356, 357, 358, 359, 360, 361, + 362, -1, 364, 365, 366, 367, 368, 369, 370, 371, + 372, 373, -1, 375, 376, -1, 378, 379, 380, 381, + 382, 383, 384, 385, 386, 387, 388, -1, 390, 391, + 392, 393, 394, -1, 396, 397, 398, 399, -1, 401, + 402, 403, -1, 405, 406, 407, 408, 409, 410, 411, + 412, 413, 414, 415, -1, 417, 418, -1, 420, 421, + 422, 423, 424, 425, -1, 427, 428, -1, -1, 431, + 432, 433, 434, -1, 436, 437, 438, 439, 440, 441, + 442, -1, -1, 445, 446, 447, 448, 449, -1, -1, + 452, 453, 454, 455, 456, 457, 458, -1, 460, -1, + 462, 463, 464, -1, -1, 467, -1, -1, 470, 471, + 472, 473, 474, 475, 476, 477, 478, 479, 480, 481, + 482, 483, 484, 485, 486, 6, 7, 8, 9, 10, + 11, 12, 13, -1, 15, 16, -1, -1, 19, 20, + 21, 22, 23, 24, -1, 26, 27, 28, -1, -1, + 31, 32, 33, 34, -1, -1, 37, 38, 39, 40, + -1, 42, -1, -1, 45, 46, -1, -1, -1, 50, + 51, -1, -1, -1, -1, 56, -1, -1, -1, -1, + -1, -1, -1, -1, 65, -1, 67, -1, 69, 70, + 71, 72, -1, -1, -1, -1, -1, -1, 79, 80, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 91, 92, 93, 94, 95, 96, 97, 98, -1, 100, + 101, 102, -1, -1, -1, -1, -1, -1, -1, 110, + 111, -1, 113, 114, -1, 116, 117, 118, 119, 120, + -1, 122, 123, -1, 125, 126, 127, 128, 129, -1, + -1, 132, 133, 134, 135, 136, -1, 138, 139, 140, + 141, 142, -1, -1, -1, 146, 147, 148, 149, -1, + 151, 152, -1, 154, 155, 156, 157, 158, 159, -1, + -1, 162, -1, -1, -1, -1, -1, -1, -1, -1, + 171, 172, 173, 174, 175, 176, 177, 178, 179, 180, + 181, -1, 183, 184, 185, 186, 187, -1, 189, 190, + 191, -1, -1, 194, 195, 196, 197, 198, -1, 200, + 201, 202, -1, 204, 205, -1, 207, 208, 209, 210, + 211, 212, 213, 214, 215, -1, 217, -1, 219, 220, + 221, -1, 223, -1, 225, -1, -1, -1, 229, 230, + 231, -1, 233, 234, -1, 236, -1, 238, 239, 240, + 241, 242, -1, 244, 245, 246, -1, 248, 249, 250, + 251, 252, 253, -1, 255, -1, 257, -1, 259, 260, + 261, -1, 263, -1, 265, -1, 267, -1, -1, 270, + -1, 272, 273, 274, 275, 276, 277, 278, -1, 280, + 281, -1, 283, -1, -1, 286, 287, 288, -1, -1, + 291, 292, 293, 294, 295, 296, 297, 298, 299, 300, + 301, 302, 303, -1, 305, 306, 307, 308, -1, 310, + 311, -1, 313, -1, 315, 316, 317, 318, 319, 320, + -1, 322, -1, -1, 325, 326, 327, -1, -1, 330, + -1, -1, -1, 334, 335, 336, 337, 338, 339, 340, + 341, -1, 343, 344, 345, 346, 347, 348, 349, -1, + 351, 352, 353, 354, 355, 356, 357, 358, 359, 360, + 361, 362, -1, 364, 365, 366, 367, 368, 369, 370, + 371, 372, 373, -1, 375, 376, -1, 378, 379, 380, + 381, 382, 383, 384, 385, 386, 387, 388, -1, 390, + 391, 392, 393, 394, -1, 396, 397, 398, 399, -1, + 401, 402, 403, -1, 405, 406, 407, 408, 409, 410, + 411, 412, 413, 414, 415, -1, 417, 418, -1, 420, + 421, 422, 423, 424, 425, -1, 427, 428, -1, -1, + 431, 432, 433, 434, -1, 436, 437, 438, 439, 440, + 441, 442, -1, -1, 445, 446, 447, 448, 449, -1, + -1, 452, 453, 454, 455, 456, 457, 458, -1, 460, + -1, 462, 463, 464, -1, -1, 467, -1, -1, 470, + 471, 472, 473, 474, 475, 476, 477, 478, 479, 480, + 481, 482, 483, 484, 485, 486, 6, 7, 8, 9, + 10, 11, 12, 13, -1, 15, 16, -1, -1, 19, + 20, 21, 22, 23, 24, -1, 26, 27, 28, -1, + -1, 31, 32, 33, 34, -1, -1, 37, 38, 39, + 40, -1, 42, -1, -1, 45, 46, -1, -1, -1, + 50, 51, -1, -1, -1, -1, 56, -1, -1, -1, + -1, -1, -1, -1, -1, 65, -1, 67, -1, 69, + 70, 71, 72, -1, -1, -1, -1, -1, -1, 79, + 80, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 91, 92, 93, 94, 95, 96, 97, 98, 99, + 100, 101, 102, -1, -1, -1, -1, -1, -1, -1, + 110, 111, -1, 113, 114, -1, 116, 117, 118, 119, + 120, -1, 122, 123, -1, 125, 126, 127, 128, 129, + -1, -1, 132, 133, 134, 135, 136, -1, 138, 139, + 140, 141, 142, -1, -1, -1, 146, 147, 148, 149, + -1, 151, 152, -1, 154, 155, 156, 157, 158, 159, + -1, -1, 162, -1, -1, -1, -1, -1, -1, -1, + -1, 171, 172, 173, 174, 175, 176, 177, 178, 179, + -1, 181, -1, 183, 184, 185, 186, 187, -1, 189, + 190, 191, -1, -1, 194, 195, 196, 197, 198, -1, + 200, 201, 202, -1, 204, 205, -1, 207, 208, 209, + 210, 211, 212, 213, 214, 215, -1, 217, -1, 219, + 220, 221, -1, 223, -1, 225, -1, -1, -1, 229, + 230, 231, -1, 233, 234, -1, 236, -1, 238, 239, + 240, 241, 242, -1, 244, 245, 246, -1, 248, 249, + 250, 251, 252, 253, -1, 255, -1, 257, -1, 259, + 260, 261, -1, 263, -1, 265, -1, 267, -1, -1, + 270, -1, 272, 273, 274, 275, 276, 277, 278, -1, + 280, 281, -1, 283, -1, -1, 286, 287, 288, -1, + -1, 291, 292, 293, 294, 295, 296, 297, 298, 299, + 300, 301, 302, 303, -1, 305, 306, 307, 308, -1, + 310, 311, -1, 313, -1, 315, 316, 317, 318, 319, + 320, -1, 322, -1, -1, 325, 326, 327, -1, -1, + 330, -1, -1, -1, 334, 335, 336, 337, 338, 339, + 340, 341, -1, 343, 344, 345, 346, 347, 348, 349, + -1, 351, 352, 353, 354, 355, 356, 357, 358, 359, + 360, 361, 362, -1, 364, 365, 366, 367, 368, 369, + 370, 371, 372, 373, -1, 375, 376, -1, 378, 379, + 380, 381, 382, 383, 384, 385, 386, 387, 388, -1, + 390, 391, 392, 393, 394, -1, 396, 397, 398, 399, + -1, 401, 402, 403, -1, 405, 406, 407, 408, 409, + 410, 411, 412, 413, 414, 415, -1, 417, 418, -1, + 420, 421, 422, 423, 424, 425, -1, 427, 428, -1, + -1, 431, 432, 433, 434, -1, 436, 437, 438, 439, + 440, 441, 442, -1, -1, 445, 446, 447, 448, 449, + -1, -1, 452, 453, 454, 455, 456, 457, 458, -1, + 460, -1, 462, 463, 464, -1, -1, 467, -1, -1, + 470, 471, 472, 473, 474, 475, 476, 477, 478, 479, + 480, 481, 482, 483, 484, 485, 486, 6, 7, 8, + 9, 10, 11, 12, 13, -1, 15, 16, -1, -1, + 19, 20, 21, 22, 23, 24, -1, 26, 27, 28, + -1, -1, 31, 32, 33, 34, -1, -1, 37, 38, + 39, 40, -1, 42, -1, -1, 45, 46, -1, -1, + -1, 50, 51, -1, -1, -1, -1, 56, -1, -1, + -1, -1, -1, -1, -1, -1, 65, -1, 67, -1, + 69, 70, 71, 72, -1, -1, -1, -1, -1, -1, + 79, 80, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 91, 92, 93, 94, 95, 96, 97, 98, + 99, 100, 101, 102, -1, -1, -1, -1, -1, -1, + -1, 110, 111, -1, 113, 114, -1, 116, 117, 118, + 119, 120, -1, 122, 123, -1, 125, 126, 127, 128, + 129, -1, -1, 132, 133, 134, 135, 136, -1, 138, + 139, 140, 141, 142, -1, -1, -1, 146, 147, 148, + 149, -1, 151, 152, -1, 154, 155, 156, 157, 158, + 159, -1, -1, 162, -1, -1, -1, -1, -1, -1, + -1, -1, 171, 172, 173, 174, 175, 176, 177, 178, + 179, -1, 181, -1, 183, 184, 185, 186, 187, -1, + 189, 190, 191, -1, -1, 194, 195, 196, 197, 198, + -1, 200, 201, 202, -1, 204, 205, -1, 207, 208, + 209, 210, 211, 212, 213, 214, 215, -1, 217, -1, + 219, 220, 221, -1, 223, -1, 225, -1, -1, -1, + 229, 230, 231, -1, 233, 234, -1, 236, -1, 238, + 239, 240, 241, 242, -1, 244, 245, 246, -1, 248, + 249, 250, 251, 252, 253, -1, 255, -1, 257, -1, + 259, 260, 261, -1, 263, -1, 265, -1, 267, -1, + -1, 270, -1, 272, 273, 274, 275, 276, 277, 278, + -1, 280, 281, -1, 283, -1, -1, 286, 287, 288, + -1, -1, 291, 292, 293, 294, 295, 296, 297, 298, + 299, 300, 301, 302, 303, -1, 305, 306, 307, 308, + -1, 310, 311, -1, 313, -1, 315, 316, 317, 318, + 319, 320, -1, 322, -1, -1, 325, 326, 327, -1, + -1, 330, -1, -1, -1, 334, 335, 336, 337, 338, + 339, 340, 341, -1, 343, 344, 345, 346, 347, 348, + 349, -1, 351, 352, 353, 354, 355, 356, 357, 358, + 359, 360, 361, 362, -1, 364, 365, 366, 367, 368, + 369, 370, 371, 372, 373, -1, 375, 376, -1, 378, + 379, 380, 381, 382, 383, 384, 385, 386, 387, 388, + -1, 390, 391, 392, 393, 394, -1, 396, 397, 398, + 399, -1, 401, 402, 403, -1, 405, 406, 407, 408, + 409, 410, 411, 412, 413, 414, 415, -1, 417, 418, + -1, 420, 421, 422, 423, 424, 425, -1, 427, 428, + -1, -1, 431, 432, 433, 434, -1, 436, 437, 438, + 439, 440, 441, 442, -1, -1, 445, 446, 447, 448, + 449, -1, -1, 452, 453, 454, 455, 456, 457, 458, + -1, 460, -1, 462, 463, 464, -1, -1, 467, -1, + -1, 470, 471, 472, 473, 474, 475, 476, 477, 478, + 479, 480, 481, 482, 483, 484, 485, 486, 6, 7, + 8, 9, 10, 11, 12, 13, -1, 15, 16, -1, + -1, 19, 20, 21, 22, 23, 24, -1, 26, 27, + 28, -1, -1, 31, 32, 33, 34, -1, -1, 37, + 38, 39, 40, -1, 42, -1, -1, 45, 46, -1, + -1, -1, 50, 51, -1, -1, -1, -1, 56, -1, + -1, -1, -1, -1, -1, -1, -1, 65, -1, 67, + -1, 69, 70, 71, -1, -1, -1, -1, -1, -1, + -1, 79, 80, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 91, 92, 93, 94, 95, 96, 97, + 98, -1, 100, 101, 102, -1, -1, -1, -1, -1, + -1, -1, 110, 111, -1, 113, 114, -1, 116, 117, + 118, 119, 120, -1, 122, 123, -1, 125, 126, 127, + 128, 129, -1, -1, 132, 133, 134, 135, 136, -1, + 138, 139, 140, 141, 142, -1, -1, -1, 146, 147, + 148, 149, -1, 151, 152, -1, 154, 155, 156, 157, + 158, 159, -1, -1, 162, -1, -1, -1, -1, -1, + -1, -1, 170, 171, 172, 173, 174, 175, 176, 177, + 178, 179, -1, 181, -1, 183, 184, 185, 186, 187, + -1, 189, 190, 191, -1, -1, 194, 195, 196, 197, + 198, -1, 200, 201, 202, -1, 204, 205, -1, 207, + 208, 209, 210, 211, 212, 213, 214, 215, -1, 217, + -1, 219, 220, 221, -1, 223, -1, 225, -1, -1, + -1, 229, 230, 231, -1, 233, 234, -1, 236, -1, + 238, 239, 240, 241, 242, -1, 244, 245, 246, -1, + 248, 249, 250, 251, 252, 253, -1, 255, -1, 257, + -1, 259, 260, 261, -1, 263, -1, 265, -1, 267, + -1, -1, 270, -1, 272, 273, 274, 275, 276, 277, + 278, -1, 280, 281, -1, 283, -1, -1, 286, 287, + 288, -1, -1, 291, 292, 293, 294, 295, 296, 297, + 298, 299, 300, 301, 302, 303, -1, 305, 306, 307, + 308, -1, 310, 311, -1, 313, -1, 315, 316, 317, + 318, 319, 320, -1, 322, -1, -1, 325, 326, 327, + -1, -1, 330, -1, -1, -1, 334, 335, 336, 337, + 338, 339, 340, 341, -1, 343, 344, 345, 346, 347, + 348, 349, -1, 351, 352, 353, 354, 355, 356, 357, + 358, 359, 360, 361, 362, -1, 364, 365, 366, 367, + 368, 369, 370, 371, 372, 373, -1, 375, 376, -1, + 378, 379, 380, 381, 382, 383, 384, 385, 386, 387, + 388, -1, 390, 391, 392, 393, 394, -1, 396, 397, + 398, 399, -1, 401, 402, 403, -1, 405, 406, 407, + 408, 409, 410, 411, 412, 413, 414, 415, -1, 417, + 418, -1, 420, 421, 422, 423, 424, 425, -1, 427, + 428, -1, -1, 431, 432, 433, 434, -1, 436, 437, + 438, 439, 440, 441, 442, -1, -1, 445, 446, 447, + 448, 449, 450, -1, 452, 453, 454, 455, 456, 457, + 458, -1, 460, -1, 462, 463, 464, -1, -1, 467, + -1, -1, 470, 471, 472, 473, 474, 475, 476, 477, + 478, 479, 480, 481, 482, 483, 484, 485, 486, 6, + 7, 8, 9, 10, 11, 12, 13, -1, 15, 16, + -1, -1, 19, 20, 21, 22, 23, 24, -1, 26, + 27, 28, -1, -1, 31, 32, 33, 34, -1, -1, + 37, 38, 39, 40, -1, 42, -1, -1, 45, 46, + -1, -1, -1, 50, 51, -1, -1, -1, -1, 56, + -1, -1, -1, -1, -1, -1, -1, -1, 65, -1, + 67, -1, 69, 70, 71, -1, -1, -1, -1, -1, + -1, -1, 79, 80, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 91, 92, 93, 94, 95, 96, + 97, 98, -1, 100, 101, 102, 103, 104, -1, -1, + -1, -1, -1, 110, 111, -1, 113, 114, -1, 116, + 117, 118, 119, 120, -1, 122, 123, -1, 125, 126, + 127, 128, 129, -1, -1, 132, 133, 134, 135, 136, + -1, 138, 139, 140, 141, 142, -1, -1, -1, 146, + 147, 148, 149, -1, 151, 152, -1, 154, 155, 156, + 157, 158, 159, -1, -1, 162, -1, -1, -1, -1, + -1, -1, -1, -1, 171, 172, 173, 174, 175, 176, + 177, 178, 179, -1, 181, -1, 183, 184, 185, 186, + 187, -1, 189, 190, 191, -1, -1, 194, 195, 196, + 197, 198, -1, 200, 201, 202, -1, 204, 205, -1, + 207, 208, 209, 210, 211, 212, 213, 214, 215, -1, + 217, -1, 219, 220, 221, -1, 223, -1, 225, -1, + -1, -1, 229, 230, 231, -1, 233, 234, -1, 236, + -1, 238, 239, 240, 241, 242, -1, 244, 245, 246, + -1, 248, 249, 250, 251, 252, 253, -1, 255, -1, + 257, -1, 259, 260, 261, -1, 263, -1, 265, -1, + 267, -1, -1, 270, -1, 272, 273, 274, 275, 276, + 277, 278, -1, 280, 281, -1, 283, -1, -1, 286, + 287, 288, -1, -1, 291, 292, 293, 294, 295, 296, + 297, 298, 299, 300, 301, 302, 303, -1, 305, 306, + 307, 308, -1, 310, 311, -1, 313, -1, 315, 316, + 317, 318, 319, 320, -1, 322, -1, -1, 325, 326, + 327, -1, -1, 330, -1, -1, -1, 334, 335, 336, + 337, 338, 339, 340, 341, -1, 343, 344, 345, 346, + 347, 348, 349, -1, 351, 352, 353, 354, 355, 356, + 357, 358, 359, 360, 361, 362, -1, 364, 365, 366, + 367, 368, 369, 370, 371, 372, 373, -1, 375, 376, + -1, 378, 379, 380, 381, 382, 383, 384, 385, 386, + 387, 388, -1, 390, 391, 392, 393, 394, -1, 396, + 397, 398, 399, -1, 401, 402, 403, -1, 405, 406, + 407, 408, 409, 410, 411, 412, 413, 414, 415, -1, + 417, 418, -1, 420, 421, 422, 423, 424, 425, -1, + 427, 428, -1, -1, 431, 432, 433, 434, -1, 436, + 437, 438, 439, 440, 441, 442, -1, -1, 445, 446, + 447, 448, 449, -1, -1, 452, 453, 454, 455, 456, + 457, 458, -1, 460, -1, 462, 463, 464, -1, -1, + 467, -1, -1, 470, 471, 472, 473, 474, 475, 476, + 477, 478, 479, 480, 481, 482, 483, 484, 485, 486, + 6, 7, 8, 9, 10, 11, 12, 13, -1, 15, + 16, -1, -1, 19, 20, 21, 22, 23, 24, -1, + 26, 27, 28, -1, -1, 31, 32, 33, 34, -1, + -1, 37, 38, 39, 40, -1, 42, -1, -1, 45, + 46, -1, -1, -1, 50, 51, -1, -1, -1, -1, + 56, -1, -1, -1, -1, -1, -1, -1, -1, 65, + -1, 67, -1, 69, 70, 71, -1, -1, -1, -1, + -1, -1, -1, 79, 80, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 91, 92, 93, 94, 95, + 96, 97, 98, 99, 100, 101, 102, -1, -1, -1, + -1, -1, -1, -1, 110, 111, -1, 113, 114, -1, + 116, 117, 118, 119, 120, -1, 122, 123, -1, 125, + 126, 127, 128, 129, -1, -1, 132, 133, 134, 135, + 136, -1, 138, 139, 140, 141, 142, -1, -1, -1, + 146, 147, 148, 149, -1, 151, 152, -1, 154, 155, + 156, 157, 158, 159, -1, -1, 162, -1, -1, -1, + -1, -1, -1, -1, -1, 171, 172, 173, 174, 175, + 176, 177, 178, 179, -1, 181, -1, 183, 184, 185, + 186, 187, -1, 189, 190, 191, -1, -1, 194, 195, + 196, 197, 198, -1, 200, 201, 202, -1, 204, 205, + -1, 207, 208, 209, 210, 211, 212, 213, 214, 215, + -1, 217, -1, 219, 220, 221, -1, 223, -1, 225, + -1, -1, -1, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, -1, 244, 245, + 246, -1, 248, 249, 250, 251, 252, 253, -1, 255, + -1, 257, -1, 259, 260, 261, -1, 263, -1, 265, + -1, 267, -1, -1, 270, -1, 272, 273, 274, 275, + 276, 277, 278, -1, 280, 281, -1, 283, -1, -1, + 286, 287, 288, -1, -1, 291, 292, 293, 294, 295, + 296, 297, 298, 299, 300, 301, 302, 303, -1, 305, + 306, 307, 308, -1, 310, 311, -1, 313, -1, 315, + 316, 317, 318, 319, 320, -1, 322, -1, -1, 325, + 326, 327, -1, -1, 330, -1, -1, -1, 334, 335, + 336, 337, 338, 339, 340, 341, -1, 343, 344, 345, + 346, 347, 348, 349, -1, 351, 352, 353, 354, 355, + 356, 357, 358, 359, 360, 361, 362, -1, 364, 365, + 366, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, -1, 378, 379, 380, 381, 382, 383, 384, 385, + 386, 387, 388, -1, 390, 391, 392, 393, 394, -1, + 396, 397, 398, 399, -1, 401, 402, 403, -1, 405, + 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, + -1, 417, 418, -1, 420, 421, 422, 423, 424, 425, + -1, 427, 428, -1, -1, 431, 432, 433, 434, -1, + 436, 437, 438, 439, 440, 441, 442, -1, -1, 445, + 446, 447, 448, 449, 450, -1, 452, 453, 454, 455, + 456, 457, 458, -1, 460, -1, 462, 463, 464, -1, + -1, 467, -1, -1, 470, 471, 472, 473, 474, 475, + 476, 477, 478, 479, 480, 481, 482, 483, 484, 485, + 486, 6, 7, 8, 9, 10, 11, 12, 13, -1, + 15, 16, -1, -1, 19, 20, 21, 22, 23, 24, + -1, 26, 27, 28, -1, -1, 31, 32, 33, 34, + -1, -1, 37, 38, 39, 40, -1, 42, -1, -1, + 45, 46, -1, -1, -1, 50, 51, -1, -1, -1, + -1, 56, -1, -1, -1, -1, -1, -1, -1, -1, + 65, -1, 67, -1, 69, 70, 71, -1, -1, -1, + -1, -1, -1, -1, 79, 80, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 91, 92, 93, 94, + 95, 96, 97, 98, 99, 100, 101, 102, -1, -1, + -1, -1, -1, -1, -1, 110, 111, -1, 113, 114, + -1, 116, 117, 118, 119, 120, -1, 122, 123, -1, + 125, 126, 127, 128, 129, -1, -1, 132, 133, 134, + 135, 136, -1, 138, 139, 140, 141, 142, -1, -1, + -1, 146, 147, 148, 149, -1, 151, 152, -1, 154, + 155, 156, 157, 158, 159, -1, -1, 162, -1, -1, + -1, -1, -1, -1, -1, -1, 171, 172, 173, 174, + 175, 176, 177, 178, 179, -1, 181, -1, 183, 184, + 185, 186, 187, -1, 189, 190, 191, -1, -1, 194, + 195, 196, 197, 198, -1, 200, 201, 202, -1, 204, + 205, -1, 207, 208, 209, 210, 211, 212, 213, 214, + 215, -1, 217, -1, 219, 220, 221, -1, 223, -1, + 225, -1, -1, -1, 229, 230, 231, -1, 233, 234, + -1, 236, -1, 238, 239, 240, 241, 242, -1, 244, + 245, 246, -1, 248, 249, 250, 251, 252, 253, -1, + 255, -1, 257, -1, 259, 260, 261, -1, 263, -1, + 265, -1, 267, -1, -1, 270, -1, 272, 273, 274, + 275, 276, 277, 278, -1, 280, 281, -1, 283, -1, + -1, 286, 287, 288, -1, -1, 291, 292, 293, 294, + 295, 296, 297, 298, 299, 300, 301, 302, 303, -1, + 305, 306, 307, 308, -1, 310, 311, -1, 313, -1, + 315, 316, 317, 318, 319, 320, -1, 322, -1, -1, + 325, 326, 327, -1, -1, 330, -1, -1, -1, 334, + 335, 336, 337, 338, 339, 340, 341, -1, 343, 344, + 345, 346, 347, 348, 349, -1, 351, 352, 353, 354, + 355, 356, 357, 358, 359, 360, 361, 362, -1, 364, + 365, 366, 367, 368, 369, 370, 371, 372, 373, -1, + 375, 376, -1, 378, 379, 380, 381, 382, 383, 384, + 385, 386, 387, 388, -1, 390, 391, 392, 393, 394, + -1, 396, 397, 398, 399, -1, 401, 402, 403, -1, + 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, + 415, -1, 417, 418, -1, 420, 421, 422, 423, 424, + 425, -1, 427, 428, -1, -1, 431, 432, 433, 434, + -1, 436, 437, 438, 439, 440, 441, 442, -1, -1, + 445, 446, 447, 448, 449, 450, -1, 452, 453, 454, + 455, 456, 457, 458, -1, 460, -1, 462, 463, 464, + -1, -1, 467, -1, -1, 470, 471, 472, 473, 474, + 475, 476, 477, 478, 479, 480, 481, 482, 483, 484, + 485, 486, 6, 7, 8, 9, 10, 11, 12, 13, + -1, 15, 16, -1, -1, 19, 20, 21, 22, 23, + 24, -1, 26, 27, 28, -1, -1, 31, 32, 33, + 34, -1, -1, 37, 38, 39, 40, -1, 42, -1, + -1, 45, 46, -1, -1, -1, 50, 51, -1, -1, + -1, -1, 56, -1, -1, -1, -1, -1, -1, -1, + -1, 65, -1, 67, -1, 69, 70, 71, 72, -1, + -1, -1, -1, -1, -1, 79, 80, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 91, 92, 93, + 94, 95, 96, 97, 98, -1, 100, 101, 102, -1, + -1, -1, -1, -1, -1, -1, 110, 111, -1, 113, + 114, -1, 116, 117, 118, 119, 120, -1, 122, 123, + -1, 125, 126, 127, 128, 129, -1, -1, 132, 133, + 134, 135, 136, -1, 138, 139, 140, 141, 142, -1, + -1, -1, 146, 147, 148, 149, -1, 151, 152, -1, + 154, 155, 156, 157, 158, 159, -1, -1, 162, -1, + -1, -1, -1, -1, -1, -1, -1, 171, 172, 173, + 174, 175, 176, 177, 178, 179, -1, 181, -1, 183, + 184, 185, 186, 187, -1, 189, 190, 191, -1, -1, + 194, 195, 196, 197, 198, -1, 200, 201, 202, -1, + 204, 205, -1, 207, 208, 209, 210, 211, 212, 213, + 214, 215, -1, 217, -1, 219, 220, 221, -1, 223, + -1, 225, -1, -1, -1, 229, 230, 231, -1, 233, + 234, -1, 236, -1, 238, 239, 240, 241, 242, -1, + 244, 245, 246, -1, 248, 249, 250, 251, 252, 253, + -1, 255, -1, 257, -1, 259, 260, 261, -1, 263, + -1, 265, -1, 267, -1, -1, 270, -1, 272, 273, + 274, 275, 276, 277, 278, -1, 280, 281, -1, 283, + -1, -1, 286, 287, 288, -1, -1, 291, 292, 293, + 294, 295, 296, 297, 298, 299, 300, 301, 302, 303, + -1, 305, 306, 307, 308, -1, 310, 311, -1, 313, + -1, 315, 316, 317, 318, 319, 320, -1, 322, -1, + -1, 325, 326, 327, -1, -1, 330, -1, -1, -1, + 334, 335, 336, 337, 338, 339, 340, 341, -1, 343, + 344, 345, 346, 347, 348, 349, -1, 351, 352, 353, + 354, 355, 356, 357, 358, 359, 360, 361, 362, -1, + 364, 365, 366, 367, 368, 369, 370, 371, 372, 373, + -1, 375, 376, -1, 378, 379, 380, 381, 382, 383, + 384, 385, 386, 387, 388, -1, 390, 391, 392, 393, + 394, -1, 396, 397, 398, 399, -1, 401, 402, 403, + -1, 405, 406, 407, 408, 409, 410, 411, 412, 413, + 414, 415, -1, 417, 418, -1, 420, 421, 422, 423, + 424, 425, -1, 427, 428, -1, -1, 431, 432, 433, + 434, -1, 436, 437, 438, 439, 440, 441, 442, -1, + -1, 445, 446, 447, 448, 449, -1, -1, 452, 453, + 454, 455, 456, 457, 458, -1, 460, -1, 462, 463, + 464, -1, -1, 467, -1, -1, 470, 471, 472, 473, + 474, 475, 476, 477, 478, 479, 480, 481, 482, 483, + 484, 485, 486, 6, 7, 8, 9, 10, 11, 12, + 13, -1, 15, 16, -1, -1, 19, 20, 21, 22, + 23, 24, -1, 26, 27, 28, -1, -1, 31, 32, + 33, 34, -1, -1, 37, 38, 39, 40, -1, 42, + -1, -1, 45, 46, -1, -1, -1, 50, 51, -1, + -1, -1, -1, 56, -1, -1, -1, -1, -1, -1, + -1, -1, 65, -1, 67, -1, 69, 70, 71, 72, + -1, -1, -1, -1, -1, -1, 79, 80, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 91, 92, + 93, 94, 95, 96, 97, 98, -1, 100, 101, 102, + -1, -1, -1, -1, -1, -1, -1, 110, 111, -1, + 113, 114, -1, 116, 117, 118, 119, 120, -1, 122, + 123, -1, 125, 126, 127, 128, 129, -1, -1, 132, + 133, 134, 135, 136, -1, 138, 139, 140, 141, 142, + -1, -1, -1, 146, 147, 148, 149, -1, 151, 152, + -1, 154, 155, 156, 157, 158, 159, -1, -1, 162, + -1, -1, -1, -1, -1, -1, -1, -1, 171, 172, + 173, 174, 175, 176, 177, 178, 179, -1, 181, -1, + 183, 184, 185, 186, 187, -1, 189, 190, 191, -1, + -1, 194, 195, 196, 197, 198, -1, 200, 201, 202, + -1, 204, 205, -1, 207, 208, 209, 210, 211, 212, + 213, 214, 215, -1, 217, -1, 219, 220, 221, -1, + 223, -1, 225, -1, -1, -1, 229, 230, 231, -1, + 233, 234, -1, 236, -1, 238, 239, 240, 241, 242, + -1, 244, 245, 246, -1, 248, 249, 250, 251, 252, + 253, -1, 255, -1, 257, -1, 259, 260, 261, -1, + 263, -1, 265, -1, 267, -1, -1, 270, -1, 272, + 273, 274, 275, 276, 277, 278, -1, 280, 281, -1, + 283, -1, -1, 286, 287, 288, -1, -1, 291, 292, + 293, 294, 295, 296, 297, 298, 299, 300, 301, 302, + 303, -1, 305, 306, 307, 308, -1, 310, 311, -1, + 313, -1, 315, 316, 317, 318, 319, 320, -1, 322, + -1, -1, 325, 326, 327, -1, -1, 330, -1, -1, + -1, 334, 335, 336, 337, 338, 339, 340, 341, -1, + 343, 344, 345, 346, 347, 348, 349, -1, 351, 352, + 353, 354, 355, 356, 357, 358, 359, 360, 361, 362, + -1, 364, 365, 366, 367, 368, 369, 370, 371, 372, + 373, -1, 375, 376, -1, 378, 379, 380, 381, 382, + 383, 384, 385, 386, 387, 388, -1, 390, 391, 392, + 393, 394, -1, 396, 397, 398, 399, -1, 401, 402, + 403, -1, 405, 406, 407, 408, 409, 410, 411, 412, + 413, 414, 415, -1, 417, 418, -1, 420, 421, 422, + 423, 424, 425, -1, 427, 428, -1, -1, 431, 432, + 433, 434, -1, 436, 437, 438, 439, 440, 441, 442, + -1, -1, 445, 446, 447, 448, 449, -1, -1, 452, + 453, 454, 455, 456, 457, 458, -1, 460, -1, 462, + 463, 464, -1, -1, 467, -1, -1, 470, 471, 472, + 473, 474, 475, 476, 477, 478, 479, 480, 481, 482, + 483, 484, 485, 486, 6, 7, 8, 9, 10, 11, + 12, 13, -1, 15, 16, -1, -1, 19, 20, 21, + 22, 23, 24, -1, 26, 27, 28, -1, -1, 31, + 32, 33, 34, -1, -1, 37, 38, 39, 40, -1, + 42, -1, -1, 45, 46, -1, -1, -1, 50, 51, + -1, -1, -1, -1, 56, -1, -1, -1, -1, -1, + -1, -1, -1, 65, -1, 67, -1, 69, 70, 71, + 72, -1, -1, -1, -1, -1, -1, 79, 80, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 91, + 92, 93, 94, 95, 96, 97, 98, -1, 100, 101, + 102, -1, -1, -1, -1, -1, -1, -1, 110, 111, + -1, 113, 114, -1, 116, 117, 118, 119, 120, -1, + 122, 123, -1, 125, 126, 127, 128, 129, -1, -1, + 132, 133, 134, 135, 136, -1, 138, 139, 140, 141, + 142, -1, -1, -1, 146, 147, 148, 149, -1, 151, + 152, -1, 154, 155, 156, 157, 158, 159, -1, -1, + 162, -1, -1, -1, -1, -1, -1, -1, -1, 171, + 172, 173, 174, 175, 176, 177, 178, 179, -1, 181, + -1, 183, 184, 185, 186, 187, -1, 189, 190, 191, + -1, -1, 194, 195, 196, 197, 198, -1, 200, 201, + 202, -1, 204, 205, -1, 207, 208, 209, 210, 211, + 212, 213, 214, 215, -1, 217, -1, 219, 220, 221, + -1, 223, -1, 225, -1, -1, -1, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, -1, 244, 245, 246, -1, 248, 249, 250, 251, + 252, 253, -1, 255, -1, 257, -1, 259, 260, 261, + -1, 263, -1, 265, -1, 267, -1, -1, 270, -1, + 272, 273, 274, 275, 276, 277, 278, -1, 280, 281, + -1, 283, -1, -1, 286, 287, 288, -1, -1, 291, + 292, 293, 294, 295, 296, 297, 298, 299, 300, 301, + 302, 303, -1, 305, 306, 307, 308, -1, 310, 311, + -1, 313, -1, 315, 316, 317, 318, 319, 320, -1, + 322, -1, -1, 325, 326, 327, -1, -1, 330, -1, + -1, -1, 334, 335, 336, 337, 338, 339, 340, 341, + -1, 343, 344, 345, 346, 347, 348, 349, -1, 351, + 352, 353, 354, 355, 356, 357, 358, 359, 360, 361, + 362, -1, 364, 365, 366, 367, 368, 369, 370, 371, + 372, 373, -1, 375, 376, -1, 378, 379, 380, 381, + 382, 383, 384, 385, 386, 387, 388, -1, 390, 391, + 392, 393, 394, -1, 396, 397, 398, 399, -1, 401, + 402, 403, -1, 405, 406, 407, 408, 409, 410, 411, + 412, 413, 414, 415, -1, 417, 418, -1, 420, 421, + 422, 423, 424, 425, -1, 427, 428, -1, -1, 431, + 432, 433, 434, -1, 436, 437, 438, 439, 440, 441, + 442, -1, -1, 445, 446, 447, 448, 449, -1, -1, + 452, 453, 454, 455, 456, 457, 458, -1, 460, -1, + 462, 463, 464, -1, -1, 467, -1, -1, 470, 471, + 472, 473, 474, 475, 476, 477, 478, 479, 480, 481, + 482, 483, 484, 485, 486, 6, 7, 8, 9, 10, + 11, 12, 13, -1, 15, 16, -1, -1, 19, 20, + 21, 22, 23, 24, -1, 26, 27, 28, -1, -1, + 31, 32, 33, 34, -1, -1, 37, 38, 39, 40, + -1, 42, -1, -1, 45, 46, -1, -1, -1, 50, + 51, -1, -1, -1, -1, 56, -1, -1, -1, -1, + -1, -1, -1, -1, 65, -1, 67, -1, 69, 70, + 71, 72, -1, -1, -1, -1, -1, -1, 79, 80, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 91, 92, 93, 94, 95, 96, 97, 98, -1, 100, + 101, 102, -1, -1, -1, -1, -1, -1, -1, 110, + 111, -1, 113, 114, -1, 116, 117, 118, 119, 120, + -1, 122, 123, -1, 125, 126, 127, 128, 129, -1, + -1, 132, 133, 134, 135, 136, -1, 138, 139, 140, + 141, 142, -1, -1, -1, 146, 147, 148, 149, -1, + 151, 152, -1, 154, 155, 156, 157, 158, 159, -1, + -1, 162, -1, -1, -1, -1, -1, -1, -1, -1, + 171, 172, 173, 174, 175, 176, 177, 178, 179, -1, + 181, -1, 183, 184, 185, 186, 187, -1, 189, 190, + 191, -1, -1, 194, 195, 196, 197, 198, -1, 200, + 201, 202, -1, 204, 205, -1, 207, 208, 209, 210, + 211, 212, 213, 214, 215, -1, 217, -1, 219, 220, + 221, -1, 223, -1, 225, -1, -1, -1, 229, 230, + 231, -1, 233, 234, -1, 236, -1, 238, 239, 240, + 241, 242, -1, 244, 245, 246, -1, 248, 249, 250, + 251, 252, 253, -1, 255, -1, 257, -1, 259, 260, + 261, -1, 263, -1, 265, -1, 267, -1, -1, 270, + -1, 272, 273, 274, 275, 276, 277, 278, -1, 280, + 281, -1, 283, -1, -1, 286, 287, 288, -1, -1, + 291, 292, 293, 294, 295, 296, 297, 298, 299, 300, + 301, 302, 303, -1, 305, 306, 307, 308, -1, 310, + 311, -1, 313, -1, 315, 316, 317, 318, 319, 320, + -1, 322, -1, -1, 325, 326, 327, -1, -1, 330, + -1, -1, -1, 334, 335, 336, 337, 338, 339, 340, + 341, -1, 343, 344, 345, 346, 347, 348, 349, -1, + 351, 352, 353, 354, 355, 356, 357, 358, 359, 360, + 361, 362, -1, 364, 365, 366, 367, 368, 369, 370, + 371, 372, 373, -1, 375, 376, -1, 378, 379, 380, + 381, 382, 383, 384, 385, 386, 387, 388, -1, 390, + 391, 392, 393, 394, -1, 396, 397, 398, 399, -1, + 401, 402, 403, -1, 405, 406, 407, 408, 409, 410, + 411, 412, 413, 414, 415, -1, 417, 418, -1, 420, + 421, 422, 423, 424, 425, -1, 427, 428, -1, -1, + 431, 432, 433, 434, -1, 436, 437, 438, 439, 440, + 441, 442, -1, -1, 445, 446, 447, 448, 449, -1, + -1, 452, 453, 454, 455, 456, 457, 458, -1, 460, + -1, 462, 463, 464, -1, -1, 467, -1, -1, 470, + 471, 472, 473, 474, 475, 476, 477, 478, 479, 480, + 481, 482, 483, 484, 485, 486, 6, 7, 8, 9, + 10, 11, 12, 13, -1, 15, 16, -1, -1, 19, + 20, 21, 22, 23, 24, -1, 26, 27, 28, -1, + -1, 31, 32, 33, 34, -1, -1, 37, 38, 39, + 40, -1, 42, -1, -1, 45, 46, -1, -1, -1, + 50, 51, -1, -1, -1, -1, 56, -1, -1, -1, + -1, -1, -1, -1, -1, 65, -1, 67, -1, 69, + 70, 71, -1, -1, -1, -1, -1, -1, -1, 79, + 80, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 91, 92, 93, 94, 95, 96, 97, 98, -1, + 100, 101, 102, -1, -1, -1, -1, -1, -1, -1, + 110, 111, -1, 113, 114, -1, 116, 117, 118, 119, + 120, -1, 122, 123, -1, 125, 126, 127, 128, 129, + -1, -1, 132, 133, 134, 135, 136, -1, 138, 139, + 140, 141, 142, -1, -1, -1, 146, 147, 148, 149, + -1, 151, 152, -1, 154, 155, 156, 157, 158, 159, + -1, -1, 162, -1, -1, -1, -1, -1, -1, -1, + -1, 171, 172, 173, 174, 175, 176, 177, 178, 179, + -1, 181, -1, 183, 184, 185, 186, 187, -1, 189, + 190, 191, -1, -1, 194, 195, 196, 197, 198, -1, + 200, 201, 202, -1, 204, 205, -1, 207, 208, 209, + 210, 211, 212, 213, 214, 215, -1, 217, -1, 219, + 220, 221, -1, 223, -1, 225, -1, -1, -1, 229, + 230, 231, -1, 233, 234, -1, 236, -1, 238, 239, + 240, 241, 242, -1, 244, 245, 246, -1, 248, 249, + 250, 251, 252, 253, -1, 255, -1, 257, -1, 259, + 260, 261, -1, 263, -1, 265, -1, 267, -1, -1, + 270, -1, 272, 273, 274, 275, 276, 277, 278, -1, + 280, 281, -1, 283, -1, -1, 286, 287, 288, -1, + -1, 291, 292, 293, 294, 295, 296, 297, 298, 299, + 300, 301, 302, 303, -1, 305, 306, 307, 308, -1, + 310, 311, -1, 313, -1, 315, 316, 317, 318, 319, + 320, -1, 322, -1, 324, 325, 326, 327, -1, -1, + 330, -1, -1, -1, 334, 335, 336, 337, 338, 339, + 340, 341, -1, 343, 344, 345, 346, 347, 348, 349, + -1, 351, 352, 353, 354, 355, 356, 357, 358, 359, + 360, 361, 362, -1, 364, 365, 366, 367, 368, 369, + 370, 371, 372, 373, -1, 375, 376, -1, 378, 379, + 380, 381, 382, 383, 384, 385, 386, 387, 388, -1, + 390, 391, 392, 393, 394, -1, 396, 397, 398, 399, + -1, 401, 402, 403, -1, 405, 406, 407, 408, 409, + 410, 411, 412, 413, 414, 415, -1, 417, 418, -1, + 420, 421, 422, 423, 424, 425, -1, 427, 428, -1, + -1, 431, 432, 433, 434, -1, 436, 437, 438, 439, + 440, 441, 442, -1, -1, 445, 446, 447, 448, 449, + -1, -1, 452, 453, 454, 455, 456, 457, 458, -1, + 460, -1, 462, 463, 464, -1, -1, 467, -1, -1, + 470, 471, 472, 473, 474, 475, 476, 477, 478, 479, + 480, 481, 482, 483, 484, 485, 486, 6, 7, 8, + 9, 10, 11, 12, 13, -1, 15, 16, -1, -1, + 19, 20, 21, 22, 23, 24, -1, 26, 27, 28, + -1, -1, 31, 32, 33, 34, -1, -1, 37, 38, + 39, 40, -1, 42, -1, -1, 45, 46, -1, -1, + -1, 50, 51, -1, -1, -1, -1, 56, -1, -1, + -1, -1, -1, -1, -1, -1, 65, -1, 67, -1, + 69, 70, 71, -1, -1, -1, -1, -1, -1, -1, + 79, 80, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 91, 92, 93, 94, 95, 96, 97, 98, + -1, 100, 101, 102, -1, -1, -1, -1, -1, -1, + -1, 110, 111, -1, 113, 114, -1, 116, 117, 118, + 119, 120, -1, 122, 123, -1, 125, 126, 127, 128, + 129, -1, -1, 132, 133, 134, 135, 136, -1, 138, + 139, 140, 141, 142, -1, -1, -1, 146, 147, 148, + 149, -1, 151, 152, -1, 154, 155, 156, 157, 158, + 159, -1, -1, 162, -1, -1, -1, -1, -1, -1, + -1, -1, 171, 172, 173, 174, 175, 176, 177, 178, + 179, -1, 181, -1, 183, 184, 185, 186, 187, -1, + 189, 190, 191, -1, -1, 194, 195, 196, 197, 198, + -1, 200, 201, 202, -1, 204, 205, -1, 207, 208, + 209, 210, 211, 212, 213, 214, 215, -1, 217, -1, + 219, 220, 221, -1, 223, -1, 225, -1, -1, -1, + 229, 230, 231, -1, 233, 234, -1, 236, -1, 238, + 239, 240, 241, 242, -1, 244, 245, 246, -1, 248, + 249, 250, 251, 252, 253, -1, 255, -1, 257, -1, + 259, 260, 261, -1, 263, -1, 265, -1, 267, -1, + -1, 270, -1, 272, 273, 274, 275, 276, 277, 278, + -1, 280, 281, -1, 283, -1, -1, 286, 287, 288, + -1, -1, 291, 292, 293, 294, 295, 296, 297, 298, + 299, 300, 301, 302, 303, -1, 305, 306, 307, 308, + -1, 310, 311, -1, 313, -1, 315, 316, 317, 318, + 319, 320, -1, 322, -1, 324, 325, 326, 327, -1, + -1, 330, -1, -1, -1, 334, 335, 336, 337, 338, + 339, 340, 341, -1, 343, 344, 345, 346, 347, 348, + 349, -1, 351, 352, 353, 354, 355, 356, 357, 358, + 359, 360, 361, 362, -1, 364, 365, 366, 367, 368, + 369, 370, 371, 372, 373, -1, 375, 376, -1, 378, + 379, 380, 381, 382, 383, 384, 385, 386, 387, 388, + -1, 390, 391, 392, 393, 394, -1, 396, 397, 398, + 399, -1, 401, 402, 403, -1, 405, 406, 407, 408, + 409, 410, 411, 412, 413, 414, 415, -1, 417, 418, + -1, 420, 421, 422, 423, 424, 425, -1, 427, 428, + -1, -1, 431, 432, 433, 434, -1, 436, 437, 438, + 439, 440, 441, 442, -1, -1, 445, 446, 447, 448, + 449, -1, -1, 452, 453, 454, 455, 456, 457, 458, + -1, 460, -1, 462, 463, 464, -1, -1, 467, -1, + -1, 470, 471, 472, 473, 474, 475, 476, 477, 478, + 479, 480, 481, 482, 483, 484, 485, 486, 6, 7, + 8, 9, 10, 11, 12, 13, -1, 15, 16, -1, + -1, 19, 20, 21, 22, 23, 24, -1, 26, 27, + 28, -1, -1, 31, 32, 33, 34, -1, -1, 37, + 38, 39, 40, -1, 42, -1, -1, 45, 46, -1, + -1, -1, 50, 51, -1, -1, -1, -1, 56, -1, + -1, -1, -1, -1, -1, -1, -1, 65, -1, 67, + -1, 69, 70, 71, -1, -1, -1, -1, -1, -1, + -1, 79, 80, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 91, 92, 93, 94, 95, 96, 97, + 98, 99, 100, 101, 102, -1, -1, -1, -1, -1, + -1, -1, 110, 111, -1, 113, 114, -1, 116, 117, + 118, 119, 120, -1, 122, 123, -1, 125, 126, 127, + 128, 129, -1, -1, 132, 133, 134, 135, 136, -1, + 138, 139, 140, 141, 142, -1, -1, -1, 146, 147, + 148, 149, -1, 151, 152, -1, 154, 155, 156, 157, + 158, 159, -1, -1, 162, -1, -1, -1, -1, -1, + -1, -1, -1, 171, 172, 173, 174, 175, 176, 177, + 178, 179, -1, 181, -1, 183, 184, 185, 186, 187, + -1, 189, 190, 191, -1, -1, 194, 195, 196, 197, + 198, -1, 200, 201, 202, -1, 204, 205, -1, 207, + 208, 209, 210, 211, 212, 213, 214, 215, -1, 217, + -1, 219, 220, 221, -1, 223, -1, 225, -1, -1, + -1, 229, 230, 231, -1, 233, 234, -1, 236, -1, + 238, 239, 240, 241, 242, -1, 244, 245, 246, -1, + 248, 249, 250, 251, 252, 253, -1, 255, -1, 257, + -1, 259, 260, 261, -1, 263, -1, 265, -1, 267, + -1, -1, 270, -1, 272, 273, 274, 275, 276, 277, + 278, -1, 280, 281, -1, 283, -1, -1, 286, 287, + 288, -1, -1, 291, 292, 293, 294, 295, 296, 297, + 298, 299, 300, 301, 302, 303, -1, 305, 306, 307, + 308, -1, 310, 311, -1, 313, -1, 315, 316, 317, + 318, 319, 320, -1, 322, -1, -1, 325, 326, 327, + -1, -1, 330, -1, -1, -1, 334, 335, 336, 337, + 338, 339, 340, 341, -1, 343, 344, 345, 346, 347, + 348, 349, -1, 351, 352, 353, 354, 355, 356, 357, + 358, 359, 360, 361, 362, -1, 364, 365, 366, 367, + 368, 369, 370, 371, 372, 373, -1, 375, 376, -1, + 378, 379, 380, 381, 382, 383, 384, 385, 386, 387, + 388, -1, 390, 391, 392, 393, 394, -1, 396, 397, + 398, 399, -1, 401, 402, 403, -1, 405, 406, 407, + 408, 409, 410, 411, 412, 413, 414, 415, -1, 417, + 418, -1, 420, 421, 422, 423, 424, 425, -1, 427, + 428, -1, -1, 431, 432, 433, 434, -1, 436, 437, + 438, 439, 440, 441, 442, -1, -1, 445, 446, 447, + 448, 449, -1, -1, 452, 453, 454, 455, 456, 457, + 458, -1, 460, -1, 462, 463, 464, -1, -1, 467, + -1, -1, 470, 471, 472, 473, 474, 475, 476, 477, + 478, 479, 480, 481, 482, 483, 484, 485, 486, 6, + 7, 8, 9, 10, 11, 12, 13, -1, 15, 16, + -1, -1, 19, 20, 21, 22, 23, 24, -1, 26, + 27, 28, -1, -1, 31, 32, 33, 34, -1, -1, + 37, 38, 39, 40, -1, 42, -1, -1, 45, 46, + -1, -1, -1, 50, 51, -1, -1, -1, -1, 56, + -1, -1, -1, -1, -1, -1, -1, -1, 65, -1, + 67, -1, 69, 70, 71, -1, -1, -1, -1, -1, + -1, -1, 79, 80, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 91, 92, 93, 94, 95, 96, + 97, 98, -1, 100, 101, 102, -1, -1, -1, -1, + -1, -1, -1, 110, 111, -1, 113, 114, -1, 116, + 117, 118, 119, 120, -1, 122, 123, -1, 125, 126, + 127, 128, 129, -1, -1, 132, 133, 134, 135, 136, + -1, 138, 139, 140, 141, 142, -1, -1, -1, 146, + 147, 148, 149, -1, 151, 152, -1, 154, 155, 156, + 157, 158, 159, -1, -1, 162, -1, -1, -1, -1, + -1, -1, -1, -1, 171, 172, 173, 174, 175, 176, + 177, 178, 179, -1, 181, -1, 183, 184, 185, 186, + 187, -1, 189, 190, 191, -1, -1, 194, 195, 196, + 197, 198, -1, 200, 201, 202, -1, 204, 205, -1, + 207, 208, 209, 210, 211, 212, 213, 214, 215, -1, + 217, -1, 219, 220, 221, -1, 223, -1, 225, -1, + -1, -1, 229, 230, 231, -1, 233, 234, -1, 236, + -1, 238, 239, 240, 241, 242, -1, 244, 245, 246, + -1, 248, 249, 250, 251, 252, 253, -1, 255, -1, + 257, -1, 259, 260, 261, -1, 263, -1, 265, -1, + 267, -1, -1, 270, -1, 272, 273, 274, 275, 276, + 277, 278, -1, 280, 281, -1, 283, -1, -1, 286, + 287, 288, -1, -1, 291, 292, 293, 294, 295, 296, + 297, 298, 299, 300, 301, 302, 303, -1, 305, 306, + 307, 308, -1, 310, 311, -1, 313, -1, 315, 316, + 317, 318, 319, 320, -1, 322, -1, 324, 325, 326, + 327, -1, -1, 330, -1, -1, -1, 334, 335, 336, + 337, 338, 339, 340, 341, -1, 343, 344, 345, 346, + 347, 348, 349, -1, 351, 352, 353, 354, 355, 356, + 357, 358, 359, 360, 361, 362, -1, 364, 365, 366, + 367, 368, 369, 370, 371, 372, 373, -1, 375, 376, + -1, 378, 379, 380, 381, 382, 383, 384, 385, 386, + 387, 388, -1, 390, 391, 392, 393, 394, -1, 396, + 397, 398, 399, -1, 401, 402, 403, -1, 405, 406, + 407, 408, 409, 410, 411, 412, 413, 414, 415, -1, + 417, 418, -1, 420, 421, 422, 423, 424, 425, -1, + 427, 428, -1, -1, 431, 432, 433, 434, -1, 436, + 437, 438, 439, 440, 441, 442, -1, -1, 445, 446, + 447, 448, 449, -1, -1, 452, 453, 454, 455, 456, + 457, 458, -1, 460, -1, 462, 463, 464, -1, -1, + 467, -1, -1, 470, 471, 472, 473, 474, 475, 476, + 477, 478, 479, 480, 481, 482, 483, 484, 485, 486, + 6, 7, 8, 9, 10, 11, 12, 13, -1, 15, + 16, -1, -1, 19, 20, 21, 22, 23, 24, -1, + 26, 27, 28, -1, -1, 31, 32, 33, 34, -1, + -1, 37, 38, 39, 40, -1, 42, -1, -1, 45, + 46, -1, -1, -1, 50, 51, -1, -1, -1, -1, + 56, -1, -1, -1, -1, -1, -1, -1, -1, 65, + -1, 67, -1, 69, 70, 71, -1, -1, 74, -1, + -1, -1, -1, 79, 80, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 91, 92, 93, 94, 95, + 96, 97, 98, -1, 100, 101, 102, -1, -1, -1, + -1, -1, -1, -1, 110, 111, -1, 113, 114, -1, + 116, 117, 118, 119, 120, -1, 122, 123, -1, 125, + 126, 127, 128, 129, -1, -1, 132, 133, 134, 135, + 136, -1, 138, 139, 140, 141, 142, -1, -1, -1, + 146, 147, 148, 149, -1, 151, 152, -1, 154, 155, + 156, 157, 158, 159, -1, -1, 162, -1, -1, -1, + -1, -1, -1, -1, -1, 171, 172, 173, 174, 175, + 176, 177, 178, 179, -1, 181, -1, 183, 184, 185, + 186, 187, -1, 189, 190, 191, -1, -1, 194, 195, + 196, 197, 198, -1, 200, 201, 202, -1, 204, 205, + -1, 207, 208, 209, 210, 211, 212, 213, 214, 215, + -1, 217, -1, 219, 220, 221, -1, 223, -1, 225, + -1, -1, -1, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, -1, 244, 245, + 246, -1, 248, 249, 250, 251, 252, 253, -1, 255, + -1, 257, -1, 259, 260, 261, -1, 263, -1, 265, + -1, 267, -1, -1, 270, -1, 272, 273, 274, 275, + 276, 277, 278, -1, 280, 281, -1, 283, -1, -1, + 286, 287, 288, -1, -1, 291, 292, 293, 294, 295, + 296, 297, 298, 299, 300, 301, 302, 303, -1, 305, + 306, 307, 308, -1, 310, 311, -1, 313, -1, 315, + 316, 317, 318, 319, 320, -1, 322, -1, -1, 325, + 326, 327, -1, -1, 330, -1, -1, -1, 334, 335, + 336, 337, 338, 339, 340, 341, -1, 343, 344, 345, + 346, 347, 348, 349, -1, 351, 352, 353, 354, 355, + 356, 357, 358, 359, 360, 361, 362, -1, 364, 365, + 366, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, -1, 378, 379, 380, 381, 382, 383, 384, 385, + 386, 387, 388, -1, 390, 391, 392, 393, 394, -1, + 396, 397, 398, 399, -1, 401, 402, 403, -1, 405, + 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, + -1, 417, 418, -1, 420, 421, 422, 423, 424, 425, + -1, 427, 428, -1, -1, 431, 432, 433, 434, -1, + 436, 437, 438, 439, 440, 441, 442, -1, -1, 445, + 446, 447, 448, 449, -1, -1, 452, 453, 454, 455, + 456, 457, 458, -1, 460, -1, 462, 463, 464, -1, + -1, 467, -1, -1, 470, 471, 472, 473, 474, 475, + 476, 477, 478, 479, 480, 481, 482, 483, 484, 485, + 486, 6, 7, 8, 9, 10, 11, 12, 13, 14, + 15, 16, -1, -1, 19, 20, 21, 22, 23, 24, + -1, 26, 27, 28, -1, -1, 31, 32, 33, 34, + -1, -1, 37, 38, 39, 40, -1, 42, -1, -1, + 45, 46, -1, -1, -1, 50, 51, -1, -1, -1, + -1, 56, -1, -1, -1, -1, -1, -1, -1, -1, + 65, -1, 67, -1, 69, 70, 71, -1, -1, -1, + -1, -1, -1, -1, 79, 80, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 91, 92, 93, 94, + 95, 96, 97, 98, -1, 100, 101, 102, -1, -1, + -1, -1, -1, -1, -1, 110, 111, -1, 113, 114, + -1, 116, 117, 118, 119, 120, -1, 122, 123, -1, + 125, 126, 127, 128, 129, -1, -1, 132, 133, 134, + 135, 136, -1, 138, 139, 140, 141, 142, -1, -1, + -1, 146, 147, 148, 149, -1, 151, 152, -1, 154, + 155, 156, 157, 158, 159, -1, -1, 162, -1, -1, + -1, -1, -1, -1, -1, -1, 171, 172, 173, 174, + 175, 176, 177, 178, 179, -1, 181, -1, 183, 184, + 185, 186, 187, -1, 189, 190, 191, -1, -1, 194, + 195, 196, 197, 198, -1, 200, 201, 202, -1, 204, + 205, -1, 207, 208, 209, 210, 211, 212, 213, 214, + 215, -1, 217, -1, 219, 220, 221, -1, 223, -1, + 225, -1, -1, -1, 229, 230, 231, -1, 233, 234, + -1, 236, -1, 238, 239, 240, 241, 242, -1, 244, + 245, 246, -1, 248, 249, 250, 251, 252, 253, -1, + 255, -1, 257, -1, 259, 260, 261, -1, 263, -1, + 265, -1, 267, -1, -1, 270, -1, 272, 273, 274, + 275, 276, 277, 278, -1, 280, 281, -1, 283, -1, + -1, 286, 287, 288, -1, -1, 291, 292, 293, 294, + 295, 296, 297, 298, 299, 300, 301, 302, 303, -1, + 305, 306, 307, 308, -1, 310, 311, -1, 313, -1, + 315, 316, 317, 318, 319, 320, -1, 322, -1, -1, + 325, 326, 327, -1, -1, 330, -1, -1, -1, 334, + 335, 336, 337, 338, 339, 340, 341, -1, 343, 344, + 345, 346, 347, 348, 349, -1, 351, 352, 353, 354, + 355, 356, 357, 358, 359, 360, 361, 362, -1, 364, + 365, 366, 367, 368, 369, 370, 371, 372, 373, -1, + 375, 376, -1, 378, 379, 380, 381, 382, 383, 384, + 385, 386, 387, 388, -1, 390, 391, 392, 393, 394, + -1, 396, 397, 398, 399, -1, 401, 402, 403, -1, + 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, + 415, -1, 417, 418, -1, 420, 421, 422, 423, 424, + 425, -1, 427, 428, -1, -1, 431, 432, 433, 434, + -1, 436, 437, 438, 439, 440, 441, 442, -1, -1, + 445, 446, 447, 448, 449, -1, -1, 452, 453, 454, + 455, 456, 457, 458, -1, 460, -1, 462, 463, 464, + -1, -1, 467, -1, -1, 470, 471, 472, 473, 474, + 475, 476, 477, 478, 479, 480, 481, 482, 483, 484, + 485, 486, 6, 7, 8, 9, 10, 11, 12, 13, + -1, 15, 16, -1, -1, 19, 20, 21, 22, 23, + 24, -1, 26, 27, 28, -1, -1, 31, 32, 33, + 34, -1, -1, 37, 38, 39, 40, -1, 42, -1, + -1, 45, 46, -1, -1, -1, 50, 51, -1, -1, + -1, -1, 56, -1, -1, -1, -1, -1, -1, -1, + -1, 65, -1, 67, -1, 69, 70, 71, -1, -1, + -1, -1, -1, -1, -1, 79, 80, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 91, 92, 93, + 94, 95, 96, 97, 98, -1, 100, 101, 102, -1, + -1, -1, -1, -1, -1, -1, 110, 111, -1, 113, + 114, -1, 116, 117, 118, 119, 120, -1, 122, 123, + -1, 125, 126, 127, 128, 129, -1, -1, 132, 133, + 134, 135, 136, -1, 138, 139, 140, 141, 142, -1, + -1, -1, 146, 147, 148, 149, -1, 151, 152, -1, + 154, 155, 156, 157, 158, 159, -1, -1, 162, -1, + -1, -1, -1, -1, -1, -1, -1, 171, 172, 173, + 174, 175, 176, 177, 178, 179, -1, 181, -1, 183, + 184, 185, 186, 187, -1, 189, 190, 191, -1, -1, + 194, 195, 196, 197, 198, -1, 200, 201, 202, -1, + 204, 205, -1, 207, 208, 209, 210, 211, 212, 213, + 214, 215, -1, 217, -1, 219, 220, 221, -1, 223, + -1, 225, -1, -1, -1, 229, 230, 231, -1, 233, + 234, 235, 236, -1, 238, 239, 240, 241, 242, -1, + 244, 245, 246, -1, 248, 249, 250, 251, 252, 253, + -1, 255, -1, 257, -1, 259, 260, 261, -1, 263, + -1, 265, -1, 267, -1, -1, 270, -1, 272, 273, + 274, 275, 276, 277, 278, -1, 280, 281, -1, 283, + -1, -1, 286, 287, 288, -1, -1, 291, 292, 293, + 294, 295, 296, 297, 298, 299, 300, 301, 302, 303, + -1, 305, 306, 307, 308, -1, 310, 311, -1, 313, + -1, 315, 316, 317, 318, 319, 320, -1, 322, -1, + -1, 325, 326, 327, -1, -1, 330, -1, -1, -1, + 334, 335, 336, 337, 338, 339, 340, 341, -1, 343, + 344, 345, 346, 347, 348, 349, -1, 351, 352, 353, + 354, 355, 356, 357, 358, 359, 360, 361, 362, -1, + 364, 365, 366, 367, 368, 369, 370, 371, 372, 373, + -1, 375, 376, -1, 378, 379, 380, 381, 382, 383, + 384, 385, 386, 387, 388, -1, 390, 391, 392, 393, + 394, -1, 396, 397, 398, 399, -1, 401, 402, 403, + -1, 405, 406, 407, 408, 409, 410, 411, 412, 413, + 414, 415, -1, 417, 418, -1, 420, 421, 422, 423, + 424, 425, -1, 427, 428, -1, -1, 431, 432, 433, + 434, -1, 436, 437, 438, 439, 440, 441, 442, -1, + -1, 445, 446, 447, 448, 449, -1, -1, 452, 453, + 454, 455, 456, 457, 458, -1, 460, -1, 462, 463, + 464, -1, -1, 467, -1, -1, 470, 471, 472, 473, + 474, 475, 476, 477, 478, 479, 480, 481, 482, 483, + 484, 485, 486, 6, 7, 8, 9, 10, 11, 12, + 13, -1, 15, 16, -1, -1, 19, 20, 21, 22, + 23, 24, -1, 26, 27, 28, -1, -1, 31, 32, + 33, 34, -1, -1, 37, 38, 39, 40, -1, 42, + -1, -1, 45, 46, -1, -1, -1, 50, 51, -1, + -1, -1, -1, 56, -1, -1, -1, -1, -1, -1, + -1, -1, 65, -1, 67, -1, 69, 70, 71, -1, + -1, -1, -1, -1, -1, -1, 79, 80, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 91, 92, + 93, 94, 95, 96, 97, 98, -1, 100, 101, 102, + -1, -1, -1, -1, -1, 108, -1, 110, 111, -1, + 113, 114, -1, 116, 117, 118, 119, 120, -1, 122, + 123, -1, 125, 126, 127, 128, 129, -1, -1, 132, + 133, 134, 135, 136, -1, 138, 139, 140, 141, 142, + -1, -1, -1, 146, 147, 148, 149, -1, 151, 152, + -1, 154, 155, 156, 157, 158, 159, -1, -1, 162, + -1, -1, -1, -1, -1, -1, -1, -1, 171, 172, + 173, 174, 175, 176, 177, 178, 179, -1, 181, -1, + 183, 184, 185, 186, 187, -1, 189, 190, 191, -1, + -1, 194, 195, 196, 197, 198, -1, 200, 201, 202, + -1, 204, 205, -1, 207, 208, 209, 210, 211, 212, + 213, 214, 215, -1, 217, -1, 219, 220, 221, -1, + 223, -1, 225, -1, -1, -1, 229, 230, 231, -1, + 233, 234, -1, 236, -1, 238, 239, 240, 241, 242, + -1, 244, 245, 246, -1, 248, 249, 250, 251, 252, + 253, -1, 255, -1, 257, -1, 259, 260, 261, -1, + 263, -1, 265, -1, 267, -1, -1, 270, -1, 272, + 273, 274, 275, 276, 277, 278, -1, 280, 281, -1, + 283, -1, -1, 286, 287, 288, -1, -1, 291, 292, + 293, 294, 295, 296, 297, 298, 299, 300, 301, 302, + 303, -1, 305, 306, 307, 308, -1, 310, 311, -1, + 313, -1, 315, 316, 317, 318, 319, 320, -1, 322, + -1, -1, 325, 326, 327, -1, -1, 330, -1, -1, + -1, 334, 335, 336, 337, 338, 339, 340, 341, -1, + 343, 344, 345, 346, 347, 348, 349, -1, 351, 352, + 353, 354, 355, 356, 357, 358, 359, 360, 361, 362, + -1, 364, 365, 366, 367, 368, 369, 370, 371, 372, + 373, -1, 375, 376, -1, 378, 379, 380, 381, 382, + 383, 384, 385, 386, 387, 388, -1, 390, 391, 392, + 393, 394, -1, 396, 397, 398, 399, -1, 401, 402, + 403, -1, 405, 406, 407, 408, 409, 410, 411, 412, + 413, 414, 415, -1, 417, 418, -1, 420, 421, 422, + 423, 424, 425, -1, 427, 428, -1, -1, 431, 432, + 433, 434, -1, 436, 437, 438, 439, 440, 441, 442, + -1, -1, 445, 446, 447, 448, 449, -1, -1, 452, + 453, 454, 455, 456, 457, 458, -1, 460, -1, 462, + 463, 464, -1, -1, 467, -1, -1, 470, 471, 472, + 473, 474, 475, 476, 477, 478, 479, 480, 481, 482, + 483, 484, 485, 486, 6, 7, 8, 9, 10, 11, + 12, 13, -1, 15, 16, -1, -1, 19, 20, 21, + 22, 23, 24, -1, 26, 27, 28, -1, -1, 31, + 32, 33, 34, -1, -1, 37, 38, 39, 40, -1, + 42, -1, -1, 45, 46, -1, -1, -1, 50, 51, + -1, -1, -1, -1, 56, -1, -1, -1, -1, -1, + -1, -1, -1, 65, -1, 67, -1, 69, 70, 71, + -1, -1, -1, -1, -1, -1, -1, 79, 80, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 91, + 92, 93, 94, 95, 96, 97, 98, -1, 100, 101, + 102, -1, -1, -1, -1, -1, 108, -1, 110, 111, + -1, 113, 114, -1, 116, 117, 118, 119, 120, -1, + 122, 123, -1, 125, 126, 127, 128, 129, -1, -1, + 132, 133, 134, 135, 136, -1, 138, 139, 140, 141, + 142, -1, -1, -1, 146, 147, 148, 149, -1, 151, + 152, -1, 154, 155, 156, 157, 158, 159, -1, -1, + 162, -1, -1, -1, -1, -1, -1, -1, -1, 171, + 172, 173, 174, 175, 176, 177, 178, 179, -1, 181, + -1, 183, 184, 185, 186, 187, -1, 189, 190, 191, + -1, -1, 194, 195, 196, 197, 198, -1, 200, 201, + 202, -1, 204, 205, -1, 207, 208, 209, 210, 211, + 212, 213, 214, 215, -1, 217, -1, 219, 220, 221, + -1, 223, -1, 225, -1, -1, -1, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, -1, 244, 245, 246, -1, 248, 249, 250, 251, + 252, 253, -1, 255, -1, 257, -1, 259, 260, 261, + -1, 263, -1, 265, -1, 267, -1, -1, 270, -1, + 272, 273, 274, 275, 276, 277, 278, -1, 280, 281, + -1, 283, -1, -1, 286, 287, 288, -1, -1, 291, + 292, 293, 294, 295, 296, 297, 298, 299, 300, 301, + 302, 303, -1, 305, 306, 307, 308, -1, 310, 311, + -1, 313, -1, 315, 316, 317, 318, 319, 320, -1, + 322, -1, -1, 325, 326, 327, -1, -1, 330, -1, + -1, -1, 334, 335, 336, 337, 338, 339, 340, 341, + -1, 343, 344, 345, 346, 347, 348, 349, -1, 351, + 352, 353, 354, 355, 356, 357, 358, 359, 360, 361, + 362, -1, 364, 365, 366, 367, 368, 369, 370, 371, + 372, 373, -1, 375, 376, -1, 378, 379, 380, 381, + 382, 383, 384, 385, 386, 387, 388, -1, 390, 391, + 392, 393, 394, -1, 396, 397, 398, 399, -1, 401, + 402, 403, -1, 405, 406, 407, 408, 409, 410, 411, + 412, 413, 414, 415, -1, 417, 418, -1, 420, 421, + 422, 423, 424, 425, -1, 427, 428, -1, -1, 431, + 432, 433, 434, -1, 436, 437, 438, 439, 440, 441, + 442, -1, -1, 445, 446, 447, 448, 449, -1, -1, + 452, 453, 454, 455, 456, 457, 458, -1, 460, -1, + 462, 463, 464, -1, -1, 467, -1, -1, 470, 471, + 472, 473, 474, 475, 476, 477, 478, 479, 480, 481, + 482, 483, 484, 485, 486, 6, 7, 8, 9, 10, + 11, 12, 13, -1, 15, 16, -1, -1, 19, 20, + 21, 22, 23, 24, -1, 26, 27, 28, -1, -1, + 31, 32, 33, 34, -1, -1, 37, 38, 39, 40, + -1, 42, -1, -1, 45, 46, -1, -1, -1, 50, + 51, -1, -1, -1, -1, 56, -1, -1, -1, -1, + -1, -1, -1, -1, 65, -1, 67, -1, 69, 70, + 71, -1, -1, -1, -1, -1, -1, -1, 79, 80, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 91, 92, 93, 94, 95, 96, 97, 98, -1, 100, + 101, 102, -1, -1, -1, -1, -1, -1, -1, 110, + 111, -1, 113, 114, -1, 116, 117, 118, 119, 120, + -1, 122, 123, -1, 125, 126, 127, 128, 129, -1, + -1, 132, 133, 134, 135, 136, -1, 138, 139, 140, + 141, 142, -1, -1, -1, 146, 147, 148, 149, -1, + 151, 152, -1, 154, 155, 156, 157, 158, 159, -1, + -1, 162, -1, -1, -1, -1, -1, -1, -1, -1, + 171, 172, 173, 174, 175, 176, 177, 178, 179, 180, + 181, -1, 183, 184, 185, 186, 187, -1, 189, 190, + 191, -1, -1, 194, 195, 196, 197, 198, -1, 200, + 201, 202, -1, 204, 205, -1, 207, 208, 209, 210, + 211, 212, 213, 214, 215, -1, 217, -1, 219, 220, + 221, -1, 223, -1, 225, -1, -1, -1, 229, 230, + 231, -1, 233, 234, -1, 236, -1, 238, 239, 240, + 241, 242, -1, 244, 245, 246, -1, 248, 249, 250, + 251, 252, 253, -1, 255, -1, 257, -1, 259, 260, + 261, -1, 263, -1, 265, -1, 267, -1, -1, 270, + -1, 272, 273, 274, 275, 276, 277, 278, -1, 280, + 281, -1, 283, -1, -1, 286, 287, 288, -1, -1, + 291, 292, 293, 294, 295, 296, 297, 298, 299, 300, + 301, 302, 303, -1, 305, 306, 307, 308, -1, 310, + 311, -1, 313, -1, 315, 316, 317, 318, 319, 320, + -1, 322, -1, -1, 325, 326, 327, -1, -1, 330, + -1, -1, -1, 334, 335, 336, 337, 338, 339, 340, + 341, -1, 343, 344, 345, 346, 347, 348, 349, -1, + 351, 352, 353, 354, 355, 356, 357, 358, 359, 360, + 361, 362, -1, 364, 365, 366, 367, 368, 369, 370, + 371, 372, 373, -1, 375, 376, -1, 378, 379, 380, + 381, 382, 383, 384, 385, 386, 387, 388, -1, 390, + 391, 392, 393, 394, -1, 396, 397, 398, 399, -1, + 401, 402, 403, -1, 405, 406, 407, 408, 409, 410, + 411, 412, 413, 414, 415, -1, 417, 418, -1, 420, + 421, 422, 423, 424, 425, -1, 427, 428, -1, -1, + 431, 432, 433, 434, -1, 436, 437, 438, 439, 440, + 441, 442, -1, -1, 445, 446, 447, 448, 449, -1, + -1, 452, 453, 454, 455, 456, 457, 458, -1, 460, + -1, 462, 463, 464, -1, -1, 467, -1, -1, 470, + 471, 472, 473, 474, 475, 476, 477, 478, 479, 480, + 481, 482, 483, 484, 485, 486, 6, 7, 8, 9, + 10, 11, 12, 13, -1, 15, 16, -1, -1, 19, + 20, 21, 22, 23, 24, -1, 26, 27, 28, -1, + -1, 31, 32, 33, 34, -1, -1, 37, 38, 39, + 40, -1, 42, -1, -1, 45, 46, -1, -1, -1, + 50, 51, -1, -1, -1, -1, 56, -1, -1, -1, + -1, -1, -1, -1, -1, 65, -1, 67, -1, 69, + 70, 71, -1, -1, -1, -1, -1, -1, -1, 79, + 80, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 91, 92, 93, 94, 95, 96, 97, 98, -1, + 100, 101, 102, -1, -1, -1, -1, -1, -1, -1, + 110, 111, -1, 113, 114, -1, 116, 117, 118, 119, + 120, -1, 122, 123, -1, 125, 126, 127, 128, 129, + -1, -1, 132, 133, 134, 135, 136, -1, 138, 139, + 140, 141, 142, -1, -1, -1, 146, 147, 148, 149, + -1, 151, 152, -1, 154, 155, 156, 157, 158, 159, + -1, -1, 162, -1, -1, -1, -1, -1, -1, -1, + -1, 171, 172, 173, 174, 175, 176, 177, 178, 179, + 180, 181, -1, 183, 184, 185, 186, 187, -1, 189, + 190, 191, -1, -1, 194, 195, 196, 197, 198, -1, + 200, 201, 202, -1, 204, 205, -1, 207, 208, 209, + 210, 211, 212, 213, 214, 215, -1, 217, -1, 219, + 220, 221, -1, 223, -1, 225, -1, -1, -1, 229, + 230, 231, -1, 233, 234, -1, 236, -1, 238, 239, + 240, 241, 242, -1, 244, 245, 246, -1, 248, 249, + 250, 251, 252, 253, -1, 255, -1, 257, -1, 259, + 260, 261, -1, 263, -1, 265, -1, 267, -1, -1, + 270, -1, 272, 273, 274, 275, 276, 277, 278, -1, + 280, 281, -1, 283, -1, -1, 286, 287, 288, -1, + -1, 291, 292, 293, 294, 295, 296, 297, 298, 299, + 300, 301, 302, 303, -1, 305, 306, 307, 308, -1, + 310, 311, -1, 313, -1, 315, 316, 317, 318, 319, + 320, -1, 322, -1, -1, 325, 326, 327, -1, -1, + 330, -1, -1, -1, 334, 335, 336, 337, 338, 339, + 340, 341, -1, 343, 344, 345, 346, 347, 348, 349, + -1, 351, 352, 353, 354, 355, 356, 357, 358, 359, + 360, 361, 362, -1, 364, 365, 366, 367, 368, 369, + 370, 371, 372, 373, -1, 375, 376, -1, 378, 379, + 380, 381, 382, 383, 384, 385, 386, 387, 388, -1, + 390, 391, 392, 393, 394, -1, 396, 397, 398, 399, + -1, 401, 402, 403, -1, 405, 406, 407, 408, 409, + 410, 411, 412, 413, 414, 415, -1, 417, 418, -1, + 420, 421, 422, 423, 424, 425, -1, 427, 428, -1, + -1, 431, 432, 433, 434, -1, 436, 437, 438, 439, + 440, 441, 442, -1, -1, 445, 446, 447, 448, 449, + -1, -1, 452, 453, 454, 455, 456, 457, 458, -1, + 460, -1, 462, 463, 464, -1, -1, 467, -1, -1, + 470, 471, 472, 473, 474, 475, 476, 477, 478, 479, + 480, 481, 482, 483, 484, 485, 486, 6, 7, 8, + 9, 10, 11, 12, 13, -1, 15, 16, -1, -1, + 19, 20, 21, 22, 23, 24, -1, 26, 27, 28, + -1, -1, 31, 32, 33, 34, -1, -1, 37, 38, + 39, 40, -1, 42, -1, -1, 45, 46, -1, -1, + -1, 50, 51, -1, -1, -1, -1, 56, -1, -1, + -1, -1, -1, -1, -1, -1, 65, -1, 67, -1, + 69, 70, 71, -1, -1, -1, -1, -1, -1, -1, + 79, 80, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 91, 92, 93, 94, 95, 96, 97, 98, + -1, 100, 101, 102, -1, -1, -1, -1, -1, -1, + -1, 110, 111, -1, 113, 114, -1, 116, 117, 118, + 119, 120, -1, 122, 123, -1, 125, 126, 127, 128, + 129, -1, -1, 132, 133, 134, 135, 136, -1, 138, + 139, 140, 141, 142, -1, -1, -1, 146, 147, 148, + 149, -1, 151, 152, -1, 154, 155, 156, 157, 158, + 159, -1, -1, 162, -1, -1, -1, -1, -1, -1, + -1, -1, 171, 172, 173, 174, 175, 176, 177, 178, + 179, 180, 181, -1, 183, 184, 185, 186, 187, -1, + 189, 190, 191, -1, -1, 194, 195, 196, 197, 198, + -1, 200, 201, 202, -1, 204, 205, -1, 207, 208, + 209, 210, 211, 212, 213, 214, 215, -1, 217, -1, + 219, 220, 221, -1, 223, -1, 225, -1, -1, -1, + 229, 230, 231, -1, 233, 234, -1, 236, -1, 238, + 239, 240, 241, 242, -1, 244, 245, 246, -1, 248, + 249, 250, 251, 252, 253, -1, 255, -1, 257, -1, + 259, 260, 261, -1, 263, -1, 265, -1, 267, -1, + -1, 270, -1, 272, 273, 274, 275, 276, 277, 278, + -1, 280, 281, -1, 283, -1, -1, 286, 287, 288, + -1, -1, 291, 292, 293, 294, 295, 296, 297, 298, + 299, 300, 301, 302, 303, -1, 305, 306, 307, 308, + -1, 310, 311, -1, 313, -1, 315, 316, 317, 318, + 319, 320, -1, 322, -1, -1, 325, 326, 327, -1, + -1, 330, -1, -1, -1, 334, 335, 336, 337, 338, + 339, 340, 341, -1, 343, 344, 345, 346, 347, 348, + 349, -1, 351, 352, 353, 354, 355, 356, 357, 358, + 359, 360, 361, 362, -1, 364, 365, 366, 367, 368, + 369, 370, 371, 372, 373, -1, 375, 376, -1, 378, + 379, 380, 381, 382, 383, 384, 385, 386, 387, 388, + -1, 390, 391, 392, 393, 394, -1, 396, 397, 398, + 399, -1, 401, 402, 403, -1, 405, 406, 407, 408, + 409, 410, 411, 412, 413, 414, 415, -1, 417, 418, + -1, 420, 421, 422, 423, 424, 425, -1, 427, 428, + -1, -1, 431, 432, 433, 434, -1, 436, 437, 438, + 439, 440, 441, 442, -1, -1, 445, 446, 447, 448, + 449, -1, -1, 452, 453, 454, 455, 456, 457, 458, + -1, 460, -1, 462, 463, 464, -1, -1, 467, -1, + -1, 470, 471, 472, 473, 474, 475, 476, 477, 478, + 479, 480, 481, 482, 483, 484, 485, 486, 6, 7, + 8, 9, 10, 11, 12, 13, -1, 15, 16, -1, + -1, 19, 20, 21, 22, 23, 24, -1, 26, 27, + 28, -1, -1, 31, 32, 33, 34, -1, -1, 37, + 38, 39, 40, -1, 42, -1, -1, 45, 46, -1, + -1, -1, 50, 51, -1, -1, -1, -1, 56, -1, + -1, -1, -1, -1, -1, -1, -1, 65, -1, 67, + -1, 69, 70, 71, -1, -1, -1, -1, -1, -1, + -1, 79, 80, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 91, 92, 93, 94, 95, 96, 97, + 98, -1, 100, 101, 102, -1, -1, -1, -1, -1, + -1, -1, 110, 111, -1, 113, 114, -1, 116, 117, + 118, 119, 120, -1, 122, 123, -1, 125, 126, 127, + 128, 129, -1, -1, 132, 133, 134, 135, 136, -1, + 138, 139, 140, 141, 142, -1, -1, -1, 146, 147, + 148, 149, -1, 151, 152, -1, 154, 155, 156, 157, + 158, 159, -1, -1, 162, -1, -1, -1, -1, -1, + -1, -1, -1, 171, 172, 173, 174, 175, 176, 177, + 178, 179, -1, 181, -1, 183, 184, 185, 186, 187, + -1, 189, 190, 191, -1, -1, 194, 195, 196, 197, + 198, -1, 200, 201, 202, -1, 204, 205, -1, 207, + 208, 209, 210, 211, 212, 213, 214, 215, -1, 217, + -1, 219, 220, 221, -1, 223, -1, 225, -1, -1, + -1, 229, 230, 231, -1, 233, 234, -1, 236, -1, + 238, 239, 240, 241, 242, -1, 244, 245, 246, -1, + 248, 249, 250, 251, 252, 253, -1, 255, -1, 257, + -1, 259, 260, 261, -1, 263, -1, 265, -1, 267, + -1, -1, 270, -1, 272, 273, 274, 275, 276, 277, + 278, -1, 280, 281, -1, 283, -1, -1, 286, 287, + 288, -1, -1, 291, 292, 293, 294, 295, 296, 297, + 298, 299, 300, 301, 302, 303, -1, 305, 306, 307, + 308, -1, 310, 311, -1, 313, -1, 315, 316, 317, + 318, 319, 320, -1, 322, -1, -1, 325, 326, 327, + -1, -1, 330, -1, -1, -1, 334, 335, 336, 337, + 338, 339, 340, 341, -1, 343, 344, 345, 346, 347, + 348, 349, -1, 351, 352, 353, 354, 355, 356, 357, + 358, 359, 360, 361, 362, -1, 364, 365, 366, 367, + 368, 369, 370, 371, 372, 373, -1, 375, 376, -1, + 378, 379, 380, 381, 382, 383, 384, 385, 386, 387, + 388, -1, 390, 391, 392, 393, 394, -1, 396, 397, + 398, 399, -1, 401, 402, 403, -1, 405, 406, 407, + 408, 409, 410, 411, 412, 413, 414, 415, -1, 417, + 418, -1, 420, 421, 422, 423, 424, 425, -1, 427, + 428, -1, -1, 431, 432, 433, 434, -1, 436, 437, + 438, 439, 440, 441, 442, -1, -1, 445, 446, 447, + 448, 449, -1, 451, 452, 453, 454, 455, 456, 457, + 458, -1, 460, -1, 462, 463, 464, -1, -1, 467, + -1, -1, 470, 471, 472, 473, 474, 475, 476, 477, + 478, 479, 480, 481, 482, 483, 484, 485, 486, 6, + 7, 8, 9, 10, 11, 12, 13, -1, 15, 16, + -1, -1, 19, 20, 21, 22, 23, 24, -1, 26, + 27, 28, -1, -1, 31, 32, 33, 34, -1, -1, + 37, 38, 39, 40, -1, 42, -1, -1, 45, 46, + -1, -1, -1, 50, 51, -1, -1, -1, -1, 56, + -1, -1, -1, -1, -1, -1, -1, -1, 65, -1, + 67, -1, 69, 70, 71, -1, -1, -1, -1, -1, + -1, -1, 79, 80, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 91, 92, 93, 94, 95, 96, + 97, 98, -1, 100, 101, 102, -1, -1, -1, -1, + -1, -1, -1, 110, 111, -1, 113, 114, -1, 116, + 117, 118, 119, 120, -1, 122, 123, -1, 125, 126, + 127, 128, 129, -1, -1, 132, 133, 134, 135, 136, + -1, 138, 139, 140, 141, 142, -1, -1, -1, 146, + 147, 148, 149, -1, 151, 152, -1, 154, 155, 156, + 157, 158, 159, -1, -1, 162, -1, -1, -1, -1, + -1, -1, -1, -1, 171, 172, 173, 174, 175, 176, + 177, 178, 179, -1, 181, -1, 183, 184, 185, 186, + 187, -1, 189, 190, 191, -1, -1, 194, 195, 196, + 197, 198, -1, 200, 201, 202, -1, 204, 205, -1, + 207, 208, 209, 210, 211, 212, 213, 214, 215, -1, + 217, -1, 219, 220, 221, -1, 223, -1, 225, -1, + -1, -1, 229, 230, 231, -1, 233, 234, -1, 236, + -1, 238, 239, 240, 241, 242, -1, 244, 245, 246, + -1, 248, 249, 250, 251, 252, 253, -1, 255, -1, + 257, -1, 259, 260, 261, -1, 263, -1, 265, -1, + 267, -1, -1, 270, -1, 272, 273, 274, 275, 276, + 277, 278, -1, 280, 281, -1, 283, -1, -1, 286, + 287, 288, -1, -1, 291, 292, 293, 294, 295, 296, + 297, 298, 299, 300, 301, 302, 303, -1, 305, 306, + 307, 308, -1, 310, 311, -1, 313, -1, 315, 316, + 317, 318, 319, 320, -1, 322, -1, -1, 325, 326, + 327, -1, -1, 330, -1, -1, -1, 334, 335, 336, + 337, 338, 339, 340, 341, -1, 343, 344, 345, 346, + 347, 348, 349, -1, 351, 352, 353, 354, 355, 356, + 357, 358, 359, 360, 361, 362, -1, 364, 365, 366, + 367, 368, 369, 370, 371, 372, 373, -1, 375, 376, + -1, 378, 379, 380, 381, 382, 383, 384, 385, 386, + 387, 388, -1, 390, 391, 392, 393, 394, -1, 396, + 397, 398, 399, -1, 401, 402, 403, -1, 405, 406, + 407, 408, 409, 410, 411, 412, 413, 414, 415, -1, + 417, 418, -1, 420, 421, 422, 423, 424, 425, -1, + 427, 428, -1, -1, 431, 432, 433, 434, -1, 436, + 437, 438, 439, 440, 441, 442, -1, -1, 445, 446, + 447, 448, 449, -1, -1, 452, 453, 454, 455, 456, + 457, 458, -1, 460, -1, 462, 463, 464, -1, -1, + 467, -1, -1, 470, 471, 472, 473, 474, 475, 476, + 477, 478, 479, 480, 481, 482, 483, 484, 485, 486, + 6, 7, 8, 9, 10, 11, 12, 13, -1, 15, + 16, -1, -1, 19, 20, 21, 22, 23, 24, -1, + 26, 27, 28, -1, -1, 31, 32, 33, 34, -1, + -1, 37, 38, 39, 40, -1, 42, -1, -1, 45, + 46, -1, -1, -1, 50, 51, -1, -1, -1, -1, + 56, -1, -1, -1, -1, -1, -1, -1, -1, 65, + -1, 67, -1, 69, 70, 71, -1, -1, -1, -1, + -1, -1, -1, 79, 80, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 91, 92, 93, 94, 95, + 96, 97, 98, -1, 100, 101, 102, -1, -1, -1, + -1, -1, -1, -1, 110, 111, -1, 113, 114, -1, + 116, 117, 118, 119, 120, -1, 122, 123, -1, 125, + 126, 127, 128, 129, -1, -1, 132, 133, 134, 135, + 136, -1, 138, 139, 140, 141, 142, -1, -1, -1, + 146, 147, 148, 149, -1, 151, 152, -1, 154, 155, + 156, 157, 158, 159, -1, -1, 162, -1, -1, -1, + -1, -1, -1, -1, -1, 171, 172, 173, 174, 175, + 176, 177, 178, 179, -1, 181, -1, 183, 184, 185, + 186, 187, -1, 189, 190, 191, -1, -1, 194, 195, + 196, 197, 198, -1, 200, 201, 202, -1, 204, 205, + -1, 207, 208, 209, 210, 211, 212, 213, 214, 215, + -1, 217, -1, 219, 220, 221, -1, 223, -1, 225, + -1, -1, -1, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, -1, 244, 245, + 246, -1, 248, 249, 250, 251, 252, 253, -1, 255, + -1, 257, -1, 259, 260, 261, -1, 263, -1, 265, + -1, 267, -1, -1, 270, -1, 272, 273, 274, 275, + 276, 277, 278, -1, 280, 281, -1, 283, -1, -1, + 286, 287, 288, -1, -1, 291, 292, 293, 294, 295, + 296, 297, 298, 299, 300, 301, 302, 303, -1, 305, + 306, 307, 308, -1, 310, 311, -1, 313, -1, 315, + 316, 317, 318, 319, 320, -1, 322, -1, -1, 325, + 326, 327, -1, -1, 330, -1, -1, -1, 334, 335, + 336, 337, 338, 339, 340, 341, -1, 343, 344, 345, + 346, 347, 348, 349, -1, 351, 352, 353, 354, 355, + 356, 357, 358, 359, 360, 361, 362, -1, 364, 365, + 366, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, -1, 378, 379, 380, 381, 382, 383, 384, 385, + 386, 387, 388, -1, 390, 391, 392, 393, 394, -1, + 396, 397, 398, 399, -1, 401, 402, 403, -1, 405, + 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, + -1, 417, 418, -1, 420, 421, 422, 423, 424, 425, + -1, 427, 428, -1, -1, 431, 432, 433, 434, -1, + 436, 437, 438, 439, 440, 441, 442, -1, -1, 445, + 446, 447, 448, 449, -1, -1, 452, 453, 454, 455, + 456, 457, 458, -1, 460, -1, 462, 463, 464, -1, + -1, 467, -1, -1, 470, 471, 472, 473, 474, 475, + 476, 477, 478, 479, 480, 481, 482, 483, 484, 485, + 486, 6, 7, 8, 9, 10, 11, 12, 13, -1, + 15, 16, -1, -1, 19, 20, 21, 22, 23, 24, + -1, 26, 27, 28, -1, -1, 31, 32, 33, 34, + -1, -1, 37, 38, 39, 40, -1, 42, -1, -1, + 45, 46, -1, -1, -1, 50, 51, -1, -1, -1, + -1, 56, -1, -1, -1, -1, -1, -1, -1, -1, + 65, -1, 67, -1, 69, 70, 71, -1, -1, -1, + -1, -1, -1, -1, 79, 80, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 91, 92, 93, 94, + 95, 96, 97, 98, 99, 100, 101, 102, -1, -1, + -1, -1, -1, -1, -1, 110, 111, -1, 113, 114, + -1, 116, 117, 118, 119, 120, -1, 122, 123, -1, + 125, 126, 127, 128, 129, -1, -1, 132, 133, 134, + 135, 136, -1, 138, 139, 140, 141, 142, -1, -1, + -1, 146, 147, 148, 149, -1, 151, -1, -1, 154, + 155, 156, 157, 158, 159, -1, -1, 162, -1, -1, + -1, -1, -1, -1, -1, -1, 171, 172, 173, 174, + 175, 176, 177, 178, 179, -1, 181, -1, 183, 184, + 185, 186, 187, -1, 189, 190, 191, -1, -1, 194, + 195, 196, 197, 198, -1, 200, 201, 202, -1, 204, + 205, -1, 207, 208, 209, 210, 211, 212, 213, 214, + 215, -1, 217, -1, 219, 220, 221, -1, 223, -1, + 225, -1, -1, -1, 229, 230, 231, -1, 233, 234, + -1, 236, -1, 238, 239, 240, 241, 242, -1, 244, + 245, 246, -1, 248, 249, 250, 251, 252, 253, -1, + 255, -1, 257, -1, 259, 260, 261, -1, 263, -1, + 265, -1, 267, -1, -1, 270, -1, 272, 273, 274, + 275, 276, 277, 278, -1, 280, 281, -1, 283, -1, + -1, 286, 287, 288, -1, -1, 291, 292, 293, 294, + 295, 296, 297, 298, 299, 300, 301, 302, 303, -1, + 305, 306, 307, 308, -1, 310, 311, -1, 313, -1, + 315, 316, 317, 318, 319, 320, -1, 322, -1, -1, + 325, 326, 327, -1, -1, 330, -1, -1, -1, 334, + 335, 336, 337, 338, 339, 340, 341, -1, 343, 344, + 345, 346, 347, 348, 349, -1, 351, 352, 353, 354, + 355, 356, 357, 358, 359, 360, 361, 362, -1, 364, + 365, 366, 367, 368, 369, 370, 371, 372, 373, -1, + 375, 376, -1, 378, 379, 380, 381, 382, 383, 384, + 385, 386, 387, 388, -1, 390, 391, 392, 393, 394, + -1, 396, 397, 398, 399, -1, 401, 402, 403, -1, + 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, + 415, -1, 417, 418, -1, 420, 421, 422, 423, 424, + 425, -1, 427, 428, -1, -1, 431, 432, 433, 434, + -1, 436, 437, 438, 439, 440, 441, 442, -1, -1, + 445, 446, 447, 448, 449, -1, -1, 452, 453, 454, + 455, 456, 457, 458, -1, 460, -1, 462, 463, 464, + -1, -1, 467, -1, -1, 470, 471, 472, 473, 474, + 475, 476, 477, 478, 479, 480, 481, 482, 483, 484, + 485, 486, 6, 7, 8, 9, 10, 11, 12, 13, + -1, 15, 16, -1, -1, 19, 20, 21, 22, 23, + 24, -1, 26, 27, 28, -1, -1, 31, 32, 33, + 34, -1, -1, 37, 38, 39, 40, -1, 42, -1, + -1, 45, 46, -1, -1, -1, 50, 51, -1, -1, + -1, -1, 56, -1, -1, -1, -1, -1, -1, -1, + -1, 65, -1, 67, -1, 69, 70, 71, -1, -1, + -1, -1, -1, -1, -1, 79, 80, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 91, 92, 93, + 94, 95, 96, 97, 98, 99, 100, 101, 102, -1, + -1, -1, -1, -1, -1, -1, 110, 111, -1, 113, + 114, -1, 116, 117, 118, 119, 120, -1, 122, 123, + -1, 125, 126, 127, 128, 129, -1, -1, 132, 133, + 134, 135, 136, -1, 138, 139, 140, 141, 142, -1, + -1, -1, 146, 147, 148, 149, -1, 151, -1, -1, + 154, 155, 156, 157, 158, 159, -1, -1, 162, -1, + -1, -1, -1, -1, -1, -1, -1, 171, 172, 173, + 174, 175, 176, 177, 178, 179, -1, 181, -1, 183, + 184, 185, 186, 187, -1, 189, 190, 191, -1, -1, + 194, 195, 196, 197, 198, -1, 200, 201, 202, -1, + 204, 205, -1, 207, 208, 209, 210, 211, 212, 213, + 214, 215, -1, 217, -1, 219, 220, 221, -1, 223, + -1, 225, -1, -1, -1, 229, 230, 231, -1, 233, + 234, -1, 236, -1, 238, 239, 240, 241, 242, -1, + 244, 245, 246, -1, 248, 249, 250, 251, 252, 253, + -1, 255, -1, 257, -1, 259, 260, 261, -1, 263, + -1, 265, -1, 267, -1, -1, 270, -1, 272, 273, + 274, 275, 276, 277, 278, -1, 280, 281, -1, 283, + -1, -1, 286, 287, 288, -1, -1, 291, 292, 293, + 294, 295, 296, 297, 298, 299, 300, 301, 302, 303, + -1, 305, 306, 307, 308, -1, 310, 311, -1, 313, + -1, 315, 316, 317, 318, 319, 320, -1, 322, -1, + -1, 325, 326, 327, -1, -1, 330, -1, -1, -1, + 334, 335, 336, 337, 338, 339, 340, 341, -1, 343, + 344, 345, 346, 347, 348, 349, -1, 351, 352, 353, + 354, 355, 356, 357, 358, 359, 360, 361, 362, -1, + 364, 365, 366, 367, 368, 369, 370, 371, 372, 373, + -1, 375, 376, -1, 378, 379, 380, 381, 382, 383, + 384, 385, 386, 387, 388, -1, 390, 391, 392, 393, + 394, -1, 396, 397, 398, 399, -1, 401, 402, 403, + -1, 405, 406, 407, 408, 409, 410, 411, 412, 413, + 414, 415, -1, 417, 418, -1, 420, 421, 422, 423, + 424, 425, -1, 427, 428, -1, -1, 431, 432, 433, + 434, -1, 436, 437, 438, 439, 440, 441, 442, -1, + -1, 445, 446, 447, 448, 449, -1, -1, 452, 453, + 454, 455, 456, 457, 458, -1, 460, -1, 462, 463, + 464, -1, -1, 467, -1, -1, 470, 471, 472, 473, + 474, 475, 476, 477, 478, 479, 480, 481, 482, 483, + 484, 485, 486, 6, 7, 8, 9, 10, 11, 12, + 13, -1, 15, 16, -1, -1, 19, 20, 21, 22, + 23, 24, -1, 26, 27, 28, -1, -1, 31, 32, + 33, 34, -1, -1, 37, 38, 39, 40, -1, 42, + -1, -1, 45, 46, -1, -1, -1, 50, 51, -1, + -1, -1, -1, 56, -1, -1, -1, -1, -1, -1, + -1, -1, 65, -1, 67, -1, 69, 70, 71, -1, + -1, -1, -1, -1, -1, -1, 79, 80, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 91, 92, + 93, 94, 95, 96, 97, 98, -1, 100, 101, 102, + -1, -1, -1, -1, -1, -1, -1, 110, 111, -1, + 113, 114, -1, 116, 117, 118, 119, 120, -1, 122, + 123, -1, 125, 126, 127, 128, 129, -1, -1, 132, + 133, 134, 135, 136, -1, 138, 139, 140, 141, 142, + -1, -1, -1, 146, 147, 148, 149, -1, 151, 152, + -1, 154, 155, 156, 157, 158, 159, -1, -1, 162, + -1, -1, -1, -1, -1, -1, -1, -1, 171, 172, + 173, 174, 175, 176, 177, 178, 179, -1, 181, -1, + 183, 184, 185, 186, 187, -1, 189, 190, 191, -1, + -1, 194, 195, 196, 197, 198, -1, 200, 201, 202, + -1, 204, 205, -1, 207, 208, 209, 210, 211, 212, + 213, 214, 215, -1, 217, -1, 219, 220, 221, -1, + 223, -1, 225, -1, -1, -1, 229, 230, 231, -1, + 233, 234, -1, 236, -1, 238, 239, 240, 241, 242, + -1, 244, 245, 246, -1, 248, 249, 250, 251, 252, + 253, -1, 255, -1, 257, -1, 259, 260, 261, -1, + 263, -1, 265, -1, 267, -1, -1, 270, -1, 272, + 273, 274, 275, 276, 277, 278, -1, 280, 281, -1, + 283, -1, -1, 286, 287, 288, -1, -1, 291, 292, + 293, 294, 295, 296, 297, 298, 299, 300, 301, 302, + 303, -1, 305, 306, 307, 308, -1, 310, 311, -1, + 313, -1, 315, 316, 317, 318, 319, 320, -1, 322, + -1, -1, 325, 326, 327, -1, -1, 330, -1, -1, + -1, 334, 335, 336, 337, 338, 339, 340, 341, -1, + 343, 344, 345, 346, 347, 348, 349, -1, 351, 352, + 353, 354, 355, 356, 357, 358, 359, 360, 361, 362, + -1, 364, 365, 366, 367, 368, 369, 370, 371, 372, + 373, -1, 375, 376, -1, 378, 379, 380, 381, 382, + 383, 384, 385, 386, 387, 388, -1, 390, 391, 392, + 393, 394, -1, 396, 397, 398, 399, -1, 401, 402, + 403, -1, 405, 406, 407, 408, 409, 410, 411, 412, + 413, 414, 415, -1, 417, 418, -1, 420, 421, 422, + 423, 424, 425, -1, 427, 428, -1, -1, 431, 432, + 433, 434, -1, 436, 437, 438, 439, 440, 441, 442, + -1, -1, 445, 446, 447, 448, 449, -1, -1, 452, + 453, 454, 455, 456, 457, 458, -1, 460, -1, 462, + 463, 464, -1, -1, 467, -1, -1, 470, 471, 472, + 473, 474, 475, 476, 477, 478, 479, 480, 481, 482, + 483, 484, 485, 486, 6, 7, 8, 9, 10, 11, + 12, 13, -1, 15, 16, -1, -1, 19, 20, 21, + 22, 23, 24, -1, 26, 27, 28, -1, -1, 31, + 32, 33, 34, -1, -1, 37, 38, 39, 40, -1, + 42, -1, -1, 45, 46, -1, -1, -1, 50, 51, + -1, -1, -1, -1, 56, -1, -1, -1, -1, -1, + -1, -1, -1, 65, -1, 67, -1, 69, 70, 71, + -1, -1, -1, -1, -1, -1, -1, 79, 80, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 91, + 92, 93, 94, 95, 96, 97, 98, -1, 100, 101, + 102, -1, -1, -1, -1, -1, -1, -1, 110, 111, + -1, 113, 114, -1, 116, 117, 118, 119, 120, -1, + 122, 123, -1, 125, 126, 127, 128, 129, -1, -1, + 132, 133, 134, 135, 136, -1, 138, 139, 140, 141, + 142, -1, -1, -1, 146, 147, 148, 149, -1, 151, + 152, -1, 154, 155, 156, 157, 158, 159, -1, -1, + 162, -1, -1, -1, -1, -1, -1, -1, -1, 171, + 172, 173, 174, 175, 176, 177, 178, 179, -1, 181, + -1, 183, 184, 185, 186, 187, -1, 189, 190, 191, + -1, -1, 194, 195, 196, 197, 198, -1, 200, 201, + 202, -1, 204, 205, -1, 207, 208, 209, 210, 211, + 212, 213, 214, 215, -1, 217, -1, 219, 220, 221, + -1, 223, -1, 225, -1, -1, -1, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, -1, 244, 245, 246, -1, 248, 249, 250, 251, + 252, 253, -1, 255, -1, 257, -1, 259, 260, 261, + -1, 263, -1, 265, -1, 267, -1, -1, 270, -1, + 272, 273, 274, 275, 276, 277, 278, -1, 280, 281, + -1, 283, -1, -1, 286, 287, 288, -1, -1, 291, + 292, 293, 294, 295, 296, 297, 298, 299, 300, 301, + 302, 303, -1, 305, 306, 307, 308, -1, 310, 311, + -1, 313, -1, 315, 316, 317, 318, 319, 320, -1, + 322, -1, -1, 325, 326, 327, -1, -1, 330, -1, + -1, -1, 334, 335, 336, 337, 338, 339, 340, 341, + -1, 343, 344, 345, 346, 347, 348, 349, -1, 351, + 352, 353, 354, 355, 356, 357, 358, 359, 360, 361, + 362, -1, 364, 365, 366, 367, 368, 369, 370, 371, + 372, 373, -1, 375, 376, -1, 378, 379, 380, 381, + 382, 383, 384, 385, 386, 387, 388, -1, 390, 391, + 392, 393, 394, -1, 396, 397, 398, 399, -1, 401, + 402, 403, -1, 405, 406, 407, 408, 409, 410, 411, + 412, 413, 414, 415, -1, 417, 418, -1, 420, 421, + 422, 423, 424, 425, -1, 427, 428, -1, -1, 431, + 432, 433, 434, -1, 436, 437, 438, 439, 440, 441, + 442, -1, -1, 445, 446, 447, 448, 449, -1, -1, + 452, 453, 454, 455, 456, 457, 458, -1, 460, -1, + 462, 463, 464, -1, -1, 467, -1, -1, 470, 471, + 472, 473, 474, 475, 476, 477, 478, 479, 480, 481, + 482, 483, 484, 485, 486, 6, 7, 8, 9, 10, + 11, 12, 13, -1, 15, 16, -1, -1, 19, 20, + 21, 22, 23, 24, -1, 26, 27, 28, -1, -1, + 31, 32, 33, 34, -1, -1, 37, 38, 39, 40, + -1, 42, -1, -1, 45, 46, -1, -1, -1, 50, + 51, -1, -1, -1, -1, 56, -1, -1, -1, -1, + -1, -1, -1, -1, 65, -1, 67, -1, 69, 70, + 71, -1, -1, -1, -1, -1, -1, -1, 79, 80, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 91, 92, 93, 94, 95, 96, 97, 98, -1, 100, + 101, 102, -1, -1, -1, -1, -1, -1, -1, 110, + 111, -1, 113, 114, -1, 116, 117, 118, 119, 120, + -1, 122, 123, -1, 125, 126, 127, 128, 129, -1, + -1, 132, 133, 134, 135, 136, -1, 138, 139, 140, + 141, 142, -1, -1, -1, 146, 147, 148, 149, -1, + 151, 152, -1, 154, 155, 156, 157, 158, 159, -1, + -1, 162, -1, -1, -1, -1, -1, -1, -1, -1, + 171, 172, 173, 174, 175, 176, 177, 178, 179, -1, + 181, -1, 183, 184, 185, 186, 187, -1, 189, 190, + 191, -1, -1, 194, 195, 196, 197, 198, -1, 200, + 201, 202, -1, 204, 205, -1, 207, 208, 209, 210, + 211, 212, 213, 214, 215, -1, 217, -1, 219, 220, + 221, -1, 223, -1, 225, -1, -1, -1, 229, 230, + 231, -1, 233, 234, -1, 236, -1, 238, 239, 240, + 241, 242, -1, 244, 245, 246, -1, 248, 249, 250, + 251, 252, 253, -1, 255, -1, 257, -1, 259, 260, + 261, -1, 263, -1, 265, -1, 267, -1, -1, 270, + -1, 272, 273, 274, 275, 276, 277, 278, -1, 280, + 281, -1, 283, -1, -1, 286, 287, 288, -1, -1, + 291, 292, 293, 294, 295, 296, 297, 298, 299, 300, + 301, 302, 303, -1, 305, 306, 307, 308, -1, 310, + 311, -1, 313, -1, 315, 316, 317, 318, 319, 320, + -1, 322, -1, -1, 325, 326, 327, -1, -1, 330, + -1, -1, -1, 334, 335, 336, 337, 338, 339, 340, + 341, -1, 343, 344, 345, 346, 347, 348, 349, -1, + 351, 352, 353, 354, 355, 356, 357, 358, 359, 360, + 361, 362, -1, 364, 365, 366, 367, 368, 369, 370, + 371, 372, 373, -1, 375, 376, -1, 378, 379, 380, + 381, 382, 383, 384, 385, 386, 387, 388, -1, 390, + 391, 392, 393, 394, -1, 396, 397, 398, 399, -1, + 401, 402, 403, -1, 405, 406, 407, 408, 409, 410, + 411, 412, 413, 414, 415, -1, 417, 418, -1, 420, + 421, 422, 423, 424, 425, -1, 427, 428, -1, -1, + 431, 432, 433, 434, -1, 436, 437, 438, 439, 440, + 441, 442, -1, -1, 445, 446, 447, 448, 449, -1, + -1, 452, 453, 454, 455, 456, 457, 458, -1, 460, + -1, 462, 463, 464, -1, -1, 467, -1, -1, 470, + 471, 472, 473, 474, 475, 476, 477, 478, 479, 480, + 481, 482, 483, 484, 485, 486, 6, 7, 8, 9, + 10, 11, 12, 13, -1, 15, 16, -1, -1, 19, + 20, 21, 22, 23, 24, -1, 26, 27, 28, -1, + -1, 31, 32, 33, 34, -1, -1, 37, 38, 39, + 40, -1, 42, -1, -1, 45, 46, -1, -1, -1, + 50, 51, -1, -1, -1, -1, 56, -1, -1, -1, + -1, -1, -1, -1, -1, 65, -1, 67, -1, 69, + 70, 71, -1, -1, -1, -1, -1, -1, -1, 79, + 80, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 91, 92, 93, 94, 95, 96, 97, 98, -1, + 100, 101, 102, -1, -1, -1, -1, -1, -1, -1, + 110, 111, -1, 113, 114, -1, 116, 117, 118, 119, + 120, -1, 122, 123, -1, 125, 126, 127, 128, 129, + -1, -1, 132, 133, 134, 135, 136, -1, 138, 139, + 140, 141, 142, -1, -1, -1, 146, 147, 148, 149, + -1, 151, 152, -1, 154, 155, 156, 157, 158, 159, + -1, -1, 162, -1, -1, -1, -1, -1, -1, -1, + -1, 171, 172, 173, 174, 175, 176, 177, 178, 179, + -1, 181, -1, 183, 184, 185, 186, 187, -1, 189, + 190, 191, -1, -1, 194, 195, 196, 197, 198, -1, + 200, 201, 202, -1, 204, 205, -1, 207, 208, 209, + 210, 211, 212, 213, 214, 215, -1, 217, -1, 219, + 220, 221, -1, 223, -1, 225, -1, -1, -1, 229, + 230, 231, -1, 233, 234, -1, 236, -1, 238, 239, + 240, 241, 242, -1, 244, 245, 246, -1, 248, 249, + 250, 251, 252, 253, -1, 255, -1, 257, -1, 259, + 260, 261, -1, 263, -1, 265, -1, 267, -1, -1, + 270, -1, 272, 273, 274, 275, 276, 277, 278, -1, + 280, 281, -1, 283, -1, -1, 286, 287, 288, -1, + -1, 291, 292, 293, 294, 295, 296, 297, 298, 299, + 300, 301, 302, 303, -1, 305, 306, 307, 308, -1, + 310, 311, -1, 313, -1, 315, 316, 317, 318, 319, + 320, -1, 322, -1, -1, 325, 326, 327, -1, -1, + 330, -1, -1, -1, 334, 335, 336, 337, 338, 339, + 340, 341, -1, 343, 344, 345, 346, 347, 348, 349, + -1, 351, 352, 353, 354, 355, 356, 357, 358, 359, + 360, 361, 362, -1, 364, 365, 366, 367, 368, 369, + 370, 371, 372, 373, -1, 375, 376, -1, 378, 379, + 380, 381, 382, 383, 384, 385, 386, 387, 388, -1, + 390, 391, 392, 393, 394, -1, 396, 397, 398, 399, + -1, 401, 402, 403, -1, 405, 406, 407, 408, 409, + 410, 411, 412, 413, 414, 415, -1, 417, 418, -1, + 420, 421, 422, 423, 424, 425, -1, 427, 428, -1, + -1, 431, 432, 433, 434, -1, 436, 437, 438, 439, + 440, 441, 442, -1, -1, 445, 446, 447, 448, 449, + -1, -1, 452, 453, 454, 455, 456, 457, 458, -1, + 460, -1, 462, 463, 464, -1, -1, 467, -1, -1, + 470, 471, 472, 473, 474, 475, 476, 477, 478, 479, + 480, 481, 482, 483, 484, 485, 486, 6, 7, 8, + 9, 10, 11, 12, 13, -1, 15, 16, -1, -1, + 19, 20, 21, 22, 23, 24, -1, 26, 27, 28, + -1, -1, 31, 32, 33, 34, -1, -1, 37, 38, + 39, 40, -1, 42, -1, -1, 45, 46, -1, -1, + -1, 50, 51, -1, -1, -1, -1, 56, -1, -1, + -1, -1, -1, -1, -1, -1, 65, -1, 67, -1, + 69, 70, 71, -1, -1, -1, -1, -1, -1, -1, + 79, 80, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 91, 92, 93, 94, 95, 96, 97, 98, + -1, 100, 101, 102, -1, -1, -1, -1, -1, -1, + -1, 110, 111, -1, 113, 114, -1, 116, 117, 118, + 119, 120, -1, 122, 123, -1, 125, 126, 127, 128, + 129, -1, -1, 132, 133, 134, 135, 136, -1, 138, + 139, 140, 141, 142, -1, -1, -1, 146, 147, 148, + 149, -1, 151, 152, -1, 154, 155, 156, 157, 158, + 159, -1, -1, 162, -1, -1, -1, -1, -1, -1, + -1, -1, 171, 172, 173, 174, 175, 176, 177, 178, + 179, -1, 181, -1, 183, 184, 185, 186, 187, -1, + 189, 190, 191, -1, -1, 194, 195, 196, 197, 198, + -1, 200, 201, 202, -1, 204, 205, -1, 207, 208, + 209, 210, 211, 212, 213, 214, 215, -1, 217, -1, + 219, 220, 221, -1, 223, -1, 225, -1, -1, -1, + 229, 230, 231, -1, 233, 234, -1, 236, -1, 238, + 239, 240, 241, 242, -1, 244, 245, 246, -1, 248, + 249, 250, 251, 252, 253, -1, 255, -1, 257, -1, + 259, 260, 261, -1, 263, -1, 265, -1, 267, -1, + -1, 270, -1, 272, 273, 274, 275, 276, 277, 278, + -1, 280, 281, -1, 283, -1, -1, 286, 287, 288, + -1, -1, 291, 292, 293, 294, 295, 296, 297, 298, + 299, 300, 301, 302, 303, -1, 305, 306, 307, 308, + -1, 310, 311, -1, 313, -1, 315, 316, 317, 318, + 319, 320, -1, 322, -1, -1, 325, 326, 327, -1, + -1, 330, -1, -1, -1, 334, 335, 336, 337, 338, + 339, 340, 341, -1, 343, 344, 345, 346, 347, 348, + 349, -1, 351, 352, 353, 354, 355, 356, 357, 358, + 359, 360, 361, 362, -1, 364, 365, 366, 367, 368, + 369, 370, 371, 372, 373, -1, 375, 376, -1, 378, + 379, 380, 381, 382, 383, 384, 385, 386, 387, 388, + -1, 390, 391, 392, 393, 394, -1, 396, 397, 398, + 399, -1, 401, 402, 403, -1, 405, 406, 407, 408, + 409, 410, 411, 412, 413, 414, 415, -1, 417, 418, + -1, 420, 421, 422, 423, 424, 425, -1, 427, 428, + -1, -1, 431, 432, 433, 434, -1, 436, 437, 438, + 439, 440, 441, 442, -1, -1, 445, 446, 447, 448, + 449, -1, -1, 452, 453, 454, 455, 456, 457, 458, + -1, 460, -1, 462, 463, 464, -1, -1, 467, -1, + -1, 470, 471, 472, 473, 474, 475, 476, 477, 478, + 479, 480, 481, 482, 483, 484, 485, 486, 6, 7, + 8, 9, 10, 11, 12, 13, -1, 15, 16, -1, + -1, 19, 20, 21, 22, 23, 24, -1, 26, 27, + 28, -1, -1, 31, 32, 33, 34, -1, -1, 37, + 38, 39, 40, -1, 42, -1, -1, 45, 46, -1, + -1, -1, 50, 51, -1, -1, -1, -1, 56, -1, + -1, -1, -1, -1, -1, -1, -1, 65, -1, 67, + -1, 69, 70, 71, -1, -1, -1, -1, -1, -1, + -1, 79, 80, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 91, 92, 93, 94, 95, 96, 97, + 98, -1, 100, 101, 102, -1, -1, -1, -1, -1, + -1, -1, 110, 111, -1, 113, 114, -1, 116, 117, + 118, 119, 120, -1, 122, 123, -1, 125, 126, 127, + 128, 129, -1, -1, 132, 133, 134, 135, 136, -1, + 138, 139, 140, 141, 142, -1, -1, -1, 146, 147, + 148, 149, -1, 151, 152, -1, 154, 155, 156, 157, + 158, 159, -1, -1, 162, -1, -1, -1, -1, -1, + -1, -1, -1, 171, 172, 173, 174, 175, 176, 177, + 178, 179, -1, 181, -1, 183, 184, 185, 186, 187, + -1, 189, 190, 191, -1, -1, 194, 195, 196, 197, + 198, -1, 200, 201, 202, -1, 204, 205, -1, 207, + 208, 209, 210, 211, 212, 213, 214, 215, -1, 217, + -1, 219, 220, 221, -1, 223, -1, 225, -1, -1, + -1, 229, 230, 231, -1, 233, 234, -1, 236, -1, + 238, 239, 240, 241, 242, -1, 244, 245, 246, -1, + 248, 249, 250, 251, 252, 253, -1, 255, -1, 257, + -1, 259, 260, 261, -1, 263, -1, 265, -1, 267, + -1, -1, 270, -1, 272, 273, 274, 275, 276, 277, + 278, -1, 280, 281, -1, 283, -1, -1, 286, 287, + 288, -1, -1, 291, 292, 293, 294, 295, 296, 297, + 298, 299, 300, 301, 302, 303, -1, 305, 306, 307, + 308, -1, 310, 311, -1, 313, -1, 315, 316, 317, + 318, 319, 320, -1, 322, -1, -1, 325, 326, 327, + -1, -1, 330, -1, -1, -1, 334, 335, 336, 337, + 338, 339, 340, 341, -1, 343, 344, 345, 346, 347, + 348, 349, -1, 351, 352, 353, 354, 355, 356, 357, + 358, 359, 360, 361, 362, -1, 364, 365, 366, 367, + 368, 369, 370, 371, 372, 373, -1, 375, 376, -1, + 378, 379, 380, 381, 382, 383, 384, 385, 386, 387, + 388, -1, 390, 391, 392, 393, 394, -1, 396, 397, + 398, 399, -1, 401, 402, 403, -1, 405, 406, 407, + 408, 409, 410, 411, 412, 413, 414, 415, -1, 417, + 418, -1, 420, 421, 422, 423, 424, 425, -1, 427, + 428, -1, -1, 431, 432, 433, 434, -1, 436, 437, + 438, 439, 440, 441, 442, -1, -1, 445, 446, 447, + 448, 449, -1, -1, 452, 453, 454, 455, 456, 457, + 458, -1, 460, -1, 462, 463, 464, -1, -1, 467, + -1, -1, 470, 471, 472, 473, 474, 475, 476, 477, + 478, 479, 480, 481, 482, 483, 484, 485, 486, 6, + 7, 8, 9, 10, 11, 12, 13, -1, 15, 16, + -1, -1, 19, 20, 21, 22, 23, 24, -1, 26, + 27, 28, -1, -1, 31, 32, 33, 34, -1, -1, + 37, 38, 39, 40, -1, 42, -1, -1, 45, 46, + -1, -1, -1, 50, 51, -1, -1, -1, -1, 56, + -1, -1, -1, -1, -1, -1, -1, -1, 65, -1, + 67, -1, 69, 70, 71, -1, -1, -1, -1, -1, + -1, -1, 79, 80, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 91, 92, 93, 94, 95, 96, + 97, 98, -1, 100, 101, 102, -1, -1, -1, -1, + -1, -1, -1, 110, 111, -1, 113, 114, -1, 116, + 117, 118, 119, 120, -1, 122, 123, -1, 125, 126, + 127, 128, 129, -1, -1, 132, 133, 134, 135, 136, + -1, 138, 139, 140, 141, 142, -1, -1, -1, 146, + 147, 148, 149, -1, 151, 152, -1, 154, 155, 156, + 157, 158, 159, -1, -1, 162, -1, -1, -1, -1, + -1, -1, -1, -1, 171, 172, 173, 174, 175, 176, + 177, 178, 179, -1, 181, -1, 183, 184, 185, 186, + 187, -1, 189, 190, 191, -1, -1, 194, 195, 196, + 197, 198, -1, 200, 201, 202, -1, 204, 205, -1, + 207, 208, 209, 210, 211, 212, 213, 214, 215, -1, + 217, -1, 219, 220, 221, -1, 223, -1, 225, -1, + -1, -1, 229, 230, 231, -1, 233, 234, -1, 236, + -1, 238, 239, 240, 241, 242, -1, 244, 245, 246, + -1, 248, 249, 250, 251, 252, 253, -1, 255, -1, + 257, -1, 259, 260, 261, -1, 263, -1, 265, -1, + 267, -1, -1, 270, -1, 272, 273, 274, 275, 276, + 277, 278, -1, 280, 281, -1, 283, -1, -1, 286, + 287, 288, -1, -1, 291, 292, 293, 294, 295, 296, + 297, 298, 299, 300, 301, 302, 303, -1, 305, 306, + 307, 308, -1, 310, 311, -1, 313, -1, 315, 316, + 317, 318, 319, 320, -1, 322, -1, -1, 325, 326, + 327, -1, -1, 330, -1, -1, -1, 334, 335, 336, + 337, 338, 339, 340, 341, -1, 343, 344, 345, 346, + 347, 348, 349, -1, 351, 352, 353, 354, 355, 356, + 357, 358, 359, 360, 361, 362, -1, 364, 365, 366, + 367, 368, 369, 370, 371, 372, 373, -1, 375, 376, + -1, 378, 379, 380, 381, 382, 383, 384, 385, 386, + 387, 388, -1, 390, 391, 392, 393, 394, -1, 396, + 397, 398, 399, -1, 401, 402, 403, -1, 405, 406, + 407, 408, 409, 410, 411, 412, 413, 414, 415, -1, + 417, 418, -1, 420, 421, 422, 423, 424, 425, -1, + 427, 428, -1, -1, 431, 432, 433, 434, -1, 436, + 437, 438, 439, 440, 441, 442, -1, -1, 445, 446, + 447, 448, 449, -1, -1, 452, 453, 454, 455, 456, + 457, 458, -1, 460, -1, 462, 463, 464, -1, -1, + 467, -1, -1, 470, 471, 472, 473, 474, 475, 476, + 477, 478, 479, 480, 481, 482, 483, 484, 485, 486, + 6, 7, 8, 9, 10, 11, 12, 13, -1, 15, + 16, -1, -1, 19, 20, 21, 22, 23, 24, -1, + 26, 27, 28, -1, -1, 31, 32, 33, 34, -1, + -1, 37, 38, 39, 40, -1, 42, -1, -1, 45, + 46, -1, -1, -1, 50, 51, -1, -1, -1, -1, + 56, -1, -1, -1, -1, -1, -1, -1, -1, 65, + -1, 67, -1, 69, 70, 71, -1, -1, -1, -1, + -1, -1, -1, 79, 80, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 91, 92, 93, 94, 95, + 96, 97, 98, -1, 100, 101, 102, -1, -1, -1, + -1, -1, -1, -1, 110, 111, -1, 113, 114, -1, + 116, 117, 118, 119, 120, -1, 122, 123, -1, 125, + 126, 127, 128, 129, -1, -1, 132, 133, 134, 135, + 136, -1, 138, 139, 140, 141, 142, -1, -1, -1, + 146, 147, 148, 149, -1, 151, 152, -1, 154, 155, + 156, 157, 158, 159, -1, -1, 162, -1, -1, -1, + -1, -1, -1, -1, -1, 171, 172, 173, 174, 175, + 176, 177, 178, 179, -1, 181, -1, 183, 184, 185, + 186, 187, -1, 189, 190, 191, -1, -1, 194, 195, + 196, 197, 198, -1, 200, 201, 202, -1, 204, 205, + -1, 207, 208, 209, 210, 211, 212, 213, 214, 215, + -1, 217, -1, 219, 220, 221, -1, 223, -1, 225, + -1, -1, -1, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, -1, 244, 245, + 246, -1, 248, 249, 250, 251, 252, 253, -1, 255, + -1, 257, -1, 259, 260, 261, -1, 263, -1, 265, + -1, 267, -1, -1, 270, -1, 272, 273, 274, 275, + 276, 277, 278, -1, 280, 281, -1, 283, -1, -1, + 286, 287, 288, -1, -1, 291, 292, 293, 294, 295, + 296, 297, 298, 299, 300, 301, 302, 303, -1, 305, + 306, 307, 308, -1, 310, 311, -1, 313, -1, 315, + 316, 317, 318, 319, 320, -1, 322, -1, -1, 325, + 326, 327, -1, -1, 330, -1, -1, -1, 334, 335, + 336, 337, 338, 339, 340, 341, -1, 343, 344, 345, + 346, 347, 348, 349, -1, 351, 352, 353, 354, 355, + 356, 357, 358, 359, 360, 361, 362, -1, 364, 365, + 366, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, -1, 378, 379, 380, 381, 382, 383, 384, 385, + 386, 387, 388, -1, 390, 391, 392, 393, 394, -1, + 396, 397, 398, 399, -1, 401, 402, 403, -1, 405, + 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, + -1, 417, 418, -1, 420, 421, 422, 423, 424, 425, + -1, 427, 428, -1, -1, 431, 432, 433, 434, -1, + 436, 437, 438, 439, 440, 441, 442, -1, -1, 445, + 446, 447, 448, 449, -1, -1, 452, 453, 454, 455, + 456, 457, 458, -1, 460, -1, 462, 463, 464, -1, + -1, 467, -1, -1, 470, 471, 472, 473, 474, 475, + 476, 477, 478, 479, 480, 481, 482, 483, 484, 485, + 486, 6, 7, 8, 9, 10, 11, 12, 13, -1, + 15, 16, -1, -1, 19, 20, 21, 22, 23, 24, + -1, 26, 27, 28, -1, -1, 31, 32, 33, 34, + -1, -1, 37, 38, 39, 40, -1, 42, -1, -1, + 45, 46, -1, -1, -1, 50, 51, -1, -1, -1, + -1, 56, -1, -1, -1, -1, -1, -1, -1, -1, + 65, -1, 67, -1, 69, 70, 71, -1, -1, -1, + -1, -1, -1, -1, 79, 80, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 91, 92, 93, 94, + 95, 96, 97, 98, -1, 100, 101, 102, -1, -1, + -1, -1, -1, -1, -1, 110, 111, -1, 113, 114, + -1, 116, 117, 118, 119, 120, -1, 122, 123, -1, + 125, 126, 127, 128, 129, -1, -1, 132, 133, 134, + 135, 136, -1, 138, 139, 140, 141, 142, -1, -1, + -1, 146, 147, 148, 149, -1, 151, 152, -1, 154, + 155, 156, 157, 158, 159, -1, -1, 162, -1, -1, + -1, -1, -1, -1, -1, -1, 171, 172, 173, 174, + 175, 176, 177, 178, 179, -1, 181, -1, 183, 184, + 185, 186, 187, -1, 189, 190, 191, -1, -1, 194, + 195, 196, 197, 198, -1, 200, 201, 202, -1, 204, + 205, -1, 207, 208, 209, 210, 211, 212, 213, 214, + 215, -1, 217, -1, 219, 220, 221, -1, 223, -1, + 225, -1, -1, -1, 229, 230, 231, -1, 233, 234, + -1, 236, -1, 238, 239, 240, 241, 242, -1, 244, + 245, 246, -1, 248, 249, 250, 251, 252, 253, -1, + 255, -1, 257, -1, 259, 260, 261, -1, 263, -1, + 265, -1, 267, -1, -1, 270, -1, 272, 273, 274, + 275, 276, 277, 278, -1, 280, 281, -1, 283, -1, + -1, 286, 287, 288, -1, -1, 291, 292, 293, 294, + 295, 296, 297, 298, 299, 300, 301, 302, 303, -1, + 305, 306, 307, 308, -1, 310, 311, -1, 313, -1, + 315, 316, 317, 318, 319, 320, -1, 322, -1, -1, + 325, 326, 327, -1, -1, 330, -1, -1, -1, 334, + 335, 336, 337, 338, 339, 340, 341, -1, 343, 344, + 345, 346, 347, 348, 349, -1, 351, 352, 353, 354, + 355, 356, 357, 358, 359, 360, 361, 362, -1, 364, + 365, 366, 367, 368, 369, 370, 371, 372, 373, -1, + 375, 376, -1, 378, 379, 380, 381, 382, 383, 384, + 385, 386, 387, 388, -1, 390, 391, 392, 393, 394, + -1, 396, 397, 398, 399, -1, 401, 402, 403, -1, + 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, + 415, -1, 417, 418, -1, 420, 421, 422, 423, 424, + 425, -1, 427, 428, -1, -1, 431, 432, 433, 434, + -1, 436, 437, 438, 439, 440, 441, 442, -1, -1, + 445, 446, 447, 448, 449, -1, -1, 452, 453, 454, + 455, 456, 457, 458, -1, 460, -1, 462, 463, 464, + -1, -1, 467, -1, -1, 470, 471, 472, 473, 474, + 475, 476, 477, 478, 479, 480, 481, 482, 483, 484, + 485, 486, 6, 7, 8, 9, 10, 11, 12, 13, + -1, 15, 16, -1, -1, 19, 20, 21, 22, 23, + 24, -1, 26, 27, 28, -1, -1, 31, 32, 33, + 34, -1, -1, 37, 38, 39, 40, -1, 42, -1, + -1, 45, 46, -1, -1, -1, 50, 51, -1, -1, + -1, -1, 56, -1, -1, -1, -1, -1, -1, -1, + -1, 65, -1, 67, -1, 69, 70, 71, -1, -1, + -1, -1, -1, -1, -1, 79, 80, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 91, 92, 93, + 94, 95, 96, 97, 98, -1, 100, 101, 102, -1, + -1, -1, -1, -1, -1, -1, 110, 111, -1, 113, + 114, -1, 116, 117, 118, 119, 120, -1, 122, 123, + -1, 125, 126, 127, 128, 129, -1, -1, 132, 133, + 134, 135, 136, -1, 138, 139, 140, 141, 142, -1, + -1, -1, 146, 147, 148, 149, -1, 151, 152, -1, + 154, 155, 156, 157, 158, 159, -1, -1, 162, -1, + -1, -1, -1, -1, -1, -1, -1, 171, 172, 173, + 174, 175, 176, 177, 178, 179, -1, 181, -1, 183, + 184, 185, 186, 187, -1, 189, 190, 191, -1, -1, + 194, 195, 196, 197, 198, -1, 200, 201, 202, -1, + 204, 205, -1, 207, 208, 209, 210, 211, 212, 213, + 214, 215, -1, 217, -1, 219, 220, 221, -1, 223, + -1, 225, -1, -1, -1, 229, 230, 231, -1, 233, + 234, -1, 236, -1, 238, 239, 240, 241, 242, -1, + 244, 245, 246, -1, 248, 249, 250, 251, 252, 253, + -1, 255, -1, 257, -1, 259, 260, 261, -1, 263, + -1, 265, -1, 267, -1, -1, 270, -1, 272, 273, + 274, 275, 276, 277, 278, -1, 280, 281, -1, 283, + -1, -1, 286, 287, 288, -1, -1, 291, 292, 293, + 294, 295, 296, 297, 298, 299, 300, 301, 302, 303, + -1, 305, 306, 307, 308, -1, 310, 311, -1, 313, + -1, 315, 316, 317, 318, 319, 320, -1, 322, -1, + -1, 325, 326, 327, -1, -1, 330, -1, -1, -1, + 334, 335, 336, 337, 338, 339, 340, 341, -1, 343, + 344, 345, 346, 347, 348, 349, -1, 351, 352, 353, + 354, 355, 356, 357, 358, 359, 360, 361, 362, -1, + 364, 365, 366, 367, 368, 369, 370, 371, 372, 373, + -1, 375, 376, -1, 378, 379, 380, 381, 382, 383, + 384, 385, 386, 387, 388, -1, 390, 391, 392, 393, + 394, -1, 396, 397, 398, 399, -1, 401, 402, 403, + -1, 405, 406, 407, 408, 409, 410, 411, 412, 413, + 414, 415, -1, 417, 418, -1, 420, 421, 422, 423, + 424, 425, -1, 427, 428, -1, -1, 431, 432, 433, + 434, -1, 436, 437, 438, 439, 440, 441, 442, -1, + -1, 445, 446, 447, 448, 449, -1, -1, 452, 453, + 454, 455, 456, 457, 458, -1, 460, -1, 462, 463, + 464, -1, -1, 467, -1, -1, 470, 471, 472, 473, + 474, 475, 476, 477, 478, 479, 480, 481, 482, 483, + 484, 485, 486, 6, 7, 8, 9, 10, 11, 12, + 13, -1, 15, 16, -1, -1, 19, 20, 21, 22, + 23, 24, -1, 26, 27, 28, -1, -1, 31, 32, + 33, 34, -1, -1, 37, 38, 39, 40, -1, 42, + -1, -1, 45, 46, -1, -1, -1, 50, 51, -1, + -1, -1, -1, 56, -1, -1, -1, -1, -1, -1, + -1, -1, 65, -1, 67, -1, 69, 70, 71, -1, + -1, -1, -1, -1, -1, -1, 79, 80, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 91, 92, + 93, 94, 95, 96, 97, 98, -1, 100, 101, 102, + -1, -1, -1, -1, -1, -1, -1, 110, 111, -1, + 113, 114, -1, 116, 117, 118, 119, 120, -1, 122, + 123, -1, 125, 126, 127, 128, 129, -1, -1, 132, + 133, 134, 135, 136, -1, 138, 139, 140, 141, 142, + -1, -1, -1, 146, 147, 148, 149, -1, 151, 152, + -1, 154, 155, 156, 157, 158, 159, -1, -1, 162, + -1, -1, -1, -1, -1, -1, -1, -1, 171, 172, + 173, 174, 175, 176, 177, 178, 179, -1, 181, -1, + 183, 184, 185, 186, 187, -1, 189, 190, 191, -1, + -1, 194, 195, 196, 197, 198, -1, 200, 201, 202, + -1, 204, 205, -1, 207, 208, 209, 210, 211, 212, + 213, 214, 215, -1, 217, -1, 219, 220, 221, -1, + 223, -1, 225, -1, -1, -1, 229, 230, 231, -1, + 233, 234, -1, 236, -1, 238, 239, 240, 241, 242, + -1, 244, 245, 246, -1, 248, 249, 250, 251, 252, + 253, -1, 255, -1, 257, -1, 259, 260, 261, -1, + 263, -1, 265, -1, 267, -1, -1, 270, -1, 272, + 273, 274, 275, 276, 277, 278, -1, 280, 281, -1, + 283, -1, -1, 286, 287, 288, -1, -1, 291, 292, + 293, 294, 295, 296, 297, 298, 299, 300, 301, 302, + 303, -1, 305, 306, 307, 308, -1, 310, 311, -1, + 313, -1, 315, 316, 317, 318, 319, 320, -1, 322, + -1, -1, 325, 326, 327, -1, -1, 330, -1, -1, + -1, 334, 335, 336, 337, 338, 339, 340, 341, -1, + 343, 344, 345, 346, 347, 348, 349, -1, 351, 352, + 353, 354, 355, 356, 357, 358, 359, 360, 361, 362, + -1, 364, 365, 366, 367, 368, 369, 370, 371, 372, + 373, -1, 375, 376, -1, 378, 379, 380, 381, 382, + 383, 384, 385, 386, 387, 388, -1, 390, 391, 392, + 393, 394, -1, 396, 397, 398, 399, -1, 401, 402, + 403, -1, 405, 406, 407, 408, 409, 410, 411, 412, + 413, 414, 415, -1, 417, 418, -1, 420, 421, 422, + 423, 424, 425, -1, 427, 428, -1, -1, 431, 432, + 433, 434, -1, 436, 437, 438, 439, 440, 441, 442, + -1, -1, 445, 446, 447, 448, 449, -1, -1, 452, + 453, 454, 455, 456, 457, 458, -1, 460, -1, 462, + 463, 464, -1, -1, 467, -1, -1, 470, 471, 472, + 473, 474, 475, 476, 477, 478, 479, 480, 481, 482, + 483, 484, 485, 486, 6, 7, 8, 9, 10, 11, + 12, 13, -1, 15, 16, -1, -1, 19, 20, 21, + 22, 23, 24, -1, 26, 27, 28, -1, -1, 31, + 32, 33, 34, -1, -1, 37, 38, 39, 40, -1, + 42, -1, -1, 45, 46, -1, -1, -1, 50, 51, + -1, -1, -1, -1, 56, -1, -1, -1, -1, -1, + -1, -1, -1, 65, -1, 67, -1, 69, 70, 71, + -1, -1, -1, -1, -1, -1, -1, 79, 80, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 91, + 92, 93, 94, 95, 96, 97, 98, -1, 100, 101, + 102, -1, -1, -1, -1, -1, -1, -1, 110, 111, + -1, 113, 114, -1, 116, 117, 118, 119, 120, -1, + 122, 123, -1, 125, 126, 127, 128, 129, -1, -1, + 132, 133, 134, 135, 136, -1, 138, 139, 140, 141, + 142, -1, -1, -1, 146, 147, 148, 149, -1, 151, + 152, -1, 154, 155, 156, 157, 158, 159, -1, -1, + 162, -1, -1, -1, -1, -1, -1, -1, -1, 171, + 172, 173, 174, 175, 176, 177, 178, 179, -1, 181, + -1, 183, 184, 185, 186, 187, -1, 189, 190, 191, + -1, -1, 194, 195, 196, 197, 198, -1, 200, 201, + 202, -1, 204, 205, -1, 207, 208, 209, 210, 211, + 212, 213, 214, 215, -1, 217, -1, 219, 220, 221, + -1, 223, -1, 225, -1, -1, -1, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, -1, 244, 245, 246, -1, 248, 249, 250, 251, + 252, 253, -1, 255, -1, 257, -1, 259, 260, 261, + -1, 263, -1, 265, -1, 267, -1, -1, 270, -1, + 272, 273, 274, 275, 276, 277, 278, -1, 280, 281, + -1, 283, -1, -1, 286, 287, 288, -1, -1, 291, + 292, 293, 294, 295, 296, 297, 298, 299, 300, 301, + 302, 303, -1, 305, 306, 307, 308, -1, 310, 311, + -1, 313, -1, 315, 316, 317, 318, 319, 320, -1, + 322, -1, -1, 325, 326, 327, -1, -1, 330, -1, + -1, -1, 334, 335, 336, 337, 338, 339, 340, 341, + -1, 343, 344, 345, 346, 347, 348, 349, -1, 351, + 352, 353, 354, 355, 356, 357, 358, 359, 360, 361, + 362, -1, 364, 365, 366, 367, 368, 369, 370, 371, + 372, 373, -1, 375, 376, -1, 378, 379, 380, 381, + 382, 383, 384, 385, 386, 387, 388, -1, 390, 391, + 392, 393, 394, -1, 396, 397, 398, 399, -1, 401, + 402, 403, -1, 405, 406, 407, 408, 409, 410, 411, + 412, 413, 414, 415, -1, 417, 418, -1, 420, 421, + 422, 423, 424, 425, -1, 427, 428, -1, -1, 431, + 432, 433, 434, -1, 436, 437, 438, 439, 440, 441, + 442, -1, -1, 445, 446, 447, 448, 449, -1, -1, + 452, 453, 454, 455, 456, 457, 458, -1, 460, -1, + 462, 463, 464, -1, -1, 467, -1, -1, 470, 471, + 472, 473, 474, 475, 476, 477, 478, 479, 480, 481, + 482, 483, 484, 485, 486, 6, 7, 8, 9, 10, + 11, 12, 13, -1, 15, 16, -1, -1, 19, 20, + 21, 22, 23, 24, -1, 26, 27, 28, -1, -1, + 31, 32, 33, 34, -1, -1, 37, 38, 39, 40, + -1, 42, -1, -1, 45, 46, -1, -1, -1, 50, + 51, -1, -1, -1, -1, 56, -1, -1, -1, -1, + -1, -1, -1, -1, 65, -1, 67, -1, 69, 70, + 71, -1, -1, -1, -1, -1, -1, -1, 79, 80, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 91, 92, 93, 94, 95, 96, 97, 98, -1, 100, + 101, 102, -1, -1, -1, -1, -1, -1, -1, 110, + 111, -1, 113, 114, -1, 116, 117, 118, 119, 120, + -1, 122, 123, -1, 125, 126, 127, 128, 129, -1, + -1, 132, 133, 134, 135, 136, -1, 138, 139, 140, + 141, 142, -1, -1, -1, 146, 147, 148, 149, -1, + 151, 152, -1, 154, 155, 156, 157, 158, 159, -1, + -1, 162, -1, -1, -1, -1, -1, -1, -1, -1, + 171, 172, 173, 174, 175, 176, 177, 178, 179, -1, + 181, -1, 183, 184, 185, 186, 187, -1, 189, 190, + 191, -1, -1, 194, 195, 196, 197, 198, -1, 200, + 201, 202, -1, 204, 205, -1, 207, 208, 209, 210, + 211, 212, 213, 214, 215, -1, 217, -1, 219, 220, + 221, -1, 223, -1, 225, -1, -1, -1, 229, 230, + 231, -1, 233, 234, -1, 236, -1, 238, 239, 240, + 241, 242, -1, 244, 245, 246, -1, 248, 249, 250, + 251, 252, 253, -1, 255, -1, 257, -1, 259, 260, + 261, -1, 263, -1, 265, -1, 267, -1, -1, 270, + -1, 272, 273, 274, 275, 276, 277, 278, -1, 280, + 281, -1, 283, -1, -1, 286, 287, 288, -1, -1, + 291, 292, 293, 294, 295, 296, 297, 298, 299, 300, + 301, 302, 303, -1, 305, 306, 307, 308, -1, 310, + 311, -1, 313, -1, 315, 316, 317, 318, 319, 320, + -1, 322, -1, -1, 325, 326, 327, -1, -1, 330, + -1, -1, -1, 334, 335, 336, 337, 338, 339, 340, + 341, -1, 343, 344, 345, 346, 347, 348, 349, -1, + 351, 352, 353, 354, 355, 356, 357, 358, 359, 360, + 361, 362, -1, 364, 365, 366, 367, 368, 369, 370, + 371, 372, 373, -1, 375, 376, -1, 378, 379, 380, + 381, 382, 383, 384, 385, 386, 387, 388, -1, 390, + 391, 392, 393, 394, -1, 396, 397, 398, 399, -1, + 401, 402, 403, -1, 405, 406, 407, 408, 409, 410, + 411, 412, 413, 414, 415, -1, 417, 418, -1, 420, + 421, 422, 423, 424, 425, -1, 427, 428, -1, -1, + 431, 432, 433, 434, -1, 436, 437, 438, 439, 440, + 441, 442, -1, -1, 445, 446, 447, 448, 449, -1, + -1, 452, 453, 454, 455, 456, 457, 458, -1, 460, + -1, 462, 463, 464, -1, -1, 467, -1, -1, 470, + 471, 472, 473, 474, 475, 476, 477, 478, 479, 480, + 481, 482, 483, 484, 485, 486, 6, 7, 8, 9, + 10, 11, 12, 13, -1, 15, 16, -1, -1, 19, + 20, 21, 22, 23, 24, -1, 26, 27, 28, -1, + -1, 31, 32, 33, 34, -1, -1, 37, 38, 39, + 40, -1, 42, -1, -1, 45, 46, -1, -1, -1, + 50, 51, -1, -1, -1, -1, 56, -1, -1, -1, + -1, -1, -1, -1, -1, 65, -1, 67, -1, 69, + 70, 71, -1, -1, -1, -1, -1, -1, -1, 79, + 80, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 91, 92, 93, 94, 95, 96, 97, 98, -1, + 100, 101, 102, -1, -1, -1, -1, -1, -1, -1, + 110, 111, -1, 113, 114, -1, 116, 117, 118, 119, + 120, -1, 122, 123, -1, 125, 126, 127, 128, 129, + -1, -1, 132, 133, 134, 135, 136, -1, 138, 139, + 140, 141, 142, -1, -1, -1, 146, 147, 148, 149, + -1, 151, 152, -1, 154, 155, 156, 157, 158, 159, + -1, -1, 162, -1, -1, -1, -1, -1, -1, -1, + -1, 171, 172, 173, 174, 175, 176, 177, 178, 179, + -1, 181, -1, 183, 184, 185, 186, 187, -1, 189, + 190, 191, -1, -1, 194, 195, 196, 197, 198, -1, + 200, 201, 202, -1, 204, 205, -1, 207, 208, 209, + 210, 211, 212, 213, 214, 215, -1, 217, -1, 219, + 220, 221, -1, 223, -1, 225, -1, -1, -1, 229, + 230, 231, -1, 233, 234, -1, 236, -1, 238, 239, + 240, 241, 242, -1, 244, 245, 246, -1, 248, 249, + 250, 251, 252, 253, -1, 255, -1, 257, -1, 259, + 260, 261, -1, 263, -1, 265, -1, 267, -1, -1, + 270, -1, 272, 273, 274, 275, 276, 277, 278, -1, + 280, 281, -1, 283, -1, -1, 286, 287, 288, -1, + -1, 291, 292, 293, 294, 295, 296, 297, 298, 299, + 300, 301, 302, 303, -1, 305, 306, 307, 308, -1, + 310, 311, -1, 313, -1, 315, 316, 317, 318, 319, + 320, -1, 322, -1, -1, 325, 326, 327, -1, -1, + 330, -1, -1, -1, 334, 335, 336, 337, 338, 339, + 340, 341, -1, 343, 344, 345, 346, 347, 348, 349, + -1, 351, 352, 353, 354, 355, 356, 357, 358, 359, + 360, 361, 362, -1, 364, 365, 366, 367, 368, 369, + 370, 371, 372, 373, -1, 375, 376, -1, 378, 379, + 380, 381, 382, 383, 384, 385, 386, 387, 388, -1, + 390, 391, 392, 393, 394, -1, 396, 397, 398, 399, + -1, 401, 402, 403, -1, 405, 406, 407, 408, 409, + 410, 411, 412, 413, 414, 415, -1, 417, 418, -1, + 420, 421, 422, 423, 424, 425, -1, 427, 428, -1, + -1, 431, 432, 433, 434, -1, 436, 437, 438, 439, + 440, 441, 442, -1, -1, 445, 446, 447, 448, 449, + -1, -1, 452, 453, 454, 455, 456, 457, 458, -1, + 460, -1, 462, 463, 464, -1, -1, 467, -1, -1, + 470, 471, 472, 473, 474, 475, 476, 477, 478, 479, + 480, 481, 482, 483, 484, 485, 486, 6, 7, 8, + 9, 10, 11, 12, 13, -1, 15, 16, -1, -1, + 19, 20, 21, 22, 23, 24, -1, 26, 27, 28, + -1, -1, 31, 32, 33, 34, -1, -1, 37, 38, + 39, 40, -1, 42, -1, -1, 45, 46, -1, -1, + -1, 50, 51, -1, -1, -1, -1, 56, -1, -1, + -1, -1, -1, -1, -1, -1, 65, -1, 67, -1, + 69, 70, 71, -1, -1, -1, -1, -1, -1, -1, + 79, 80, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 91, 92, 93, 94, 95, 96, 97, 98, + -1, 100, 101, 102, -1, -1, -1, -1, -1, -1, + -1, 110, 111, -1, 113, 114, -1, 116, 117, 118, + 119, 120, -1, 122, 123, -1, 125, 126, 127, 128, + 129, -1, -1, 132, 133, 134, 135, 136, -1, 138, + 139, 140, 141, 142, -1, -1, -1, 146, 147, 148, + 149, -1, 151, 152, -1, 154, 155, 156, 157, 158, + 159, -1, -1, 162, -1, -1, -1, -1, -1, -1, + -1, -1, 171, 172, 173, 174, 175, 176, 177, 178, + 179, -1, 181, -1, 183, 184, 185, 186, 187, -1, + 189, 190, 191, -1, -1, 194, 195, 196, 197, 198, + -1, 200, 201, 202, -1, 204, 205, -1, 207, 208, + 209, 210, 211, 212, 213, 214, 215, -1, 217, -1, + 219, 220, 221, -1, 223, -1, 225, -1, -1, -1, + 229, 230, 231, -1, 233, 234, -1, 236, -1, 238, + 239, 240, 241, 242, -1, 244, 245, 246, -1, 248, + 249, 250, 251, 252, 253, -1, 255, -1, 257, -1, + 259, 260, 261, -1, 263, -1, 265, -1, 267, -1, + -1, 270, -1, 272, 273, 274, 275, 276, 277, 278, + -1, 280, 281, -1, 283, -1, -1, 286, 287, 288, + -1, -1, 291, 292, 293, 294, 295, 296, 297, 298, + 299, 300, 301, 302, 303, -1, 305, 306, 307, 308, + -1, 310, 311, -1, 313, -1, 315, 316, 317, 318, + 319, 320, -1, 322, -1, -1, 325, 326, 327, -1, + -1, 330, -1, -1, -1, 334, 335, 336, 337, 338, + 339, 340, 341, -1, 343, 344, 345, 346, 347, 348, + 349, -1, 351, 352, 353, 354, 355, 356, 357, 358, + 359, 360, 361, 362, -1, 364, 365, 366, 367, 368, + 369, 370, 371, 372, 373, -1, 375, 376, -1, 378, + 379, 380, 381, 382, 383, 384, 385, 386, 387, 388, + -1, 390, 391, 392, 393, 394, -1, 396, 397, 398, + 399, -1, 401, 402, 403, -1, 405, 406, 407, 408, + 409, 410, 411, 412, 413, 414, 415, -1, 417, 418, + -1, 420, 421, 422, 423, 424, 425, -1, 427, 428, + -1, -1, 431, 432, 433, 434, -1, 436, 437, 438, + 439, 440, 441, 442, -1, -1, 445, 446, 447, 448, + 449, -1, -1, 452, 453, 454, 455, 456, 457, 458, + -1, 460, -1, 462, 463, 464, -1, -1, 467, -1, + -1, 470, 471, 472, 473, 474, 475, 476, 477, 478, + 479, 480, 481, 482, 483, 484, 485, 486, 6, 7, + 8, 9, 10, 11, 12, 13, -1, 15, 16, -1, + -1, 19, 20, 21, 22, 23, 24, -1, 26, 27, + 28, -1, -1, 31, 32, 33, 34, -1, -1, 37, + 38, 39, 40, -1, 42, -1, -1, 45, 46, -1, + -1, -1, 50, 51, -1, -1, -1, -1, 56, -1, + -1, -1, -1, -1, -1, -1, -1, 65, -1, 67, + -1, 69, 70, 71, -1, -1, -1, -1, -1, -1, + -1, 79, 80, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 91, 92, 93, 94, 95, 96, 97, + 98, -1, 100, 101, 102, -1, -1, -1, -1, -1, + -1, -1, 110, 111, -1, 113, 114, -1, 116, 117, + 118, 119, 120, -1, 122, 123, -1, 125, 126, 127, + 128, 129, -1, -1, 132, 133, 134, 135, 136, -1, + 138, 139, 140, 141, 142, -1, -1, -1, 146, 147, + 148, 149, -1, 151, 152, -1, 154, 155, 156, 157, + 158, 159, -1, -1, 162, -1, -1, -1, -1, -1, + -1, -1, -1, 171, 172, 173, 174, 175, 176, 177, + 178, 179, -1, 181, -1, 183, 184, 185, 186, 187, + -1, 189, 190, 191, -1, -1, 194, 195, 196, 197, + 198, -1, 200, 201, 202, -1, 204, 205, -1, 207, + 208, 209, 210, 211, 212, 213, 214, 215, -1, 217, + -1, 219, 220, 221, -1, 223, -1, 225, -1, -1, + -1, 229, 230, 231, -1, 233, 234, -1, 236, -1, + 238, 239, 240, 241, 242, -1, 244, 245, 246, -1, + 248, 249, 250, 251, 252, 253, -1, 255, -1, 257, + -1, 259, 260, 261, -1, 263, -1, 265, -1, 267, + -1, -1, 270, -1, 272, 273, 274, 275, 276, 277, + 278, -1, 280, 281, -1, 283, -1, -1, 286, 287, + 288, -1, -1, 291, 292, 293, 294, 295, 296, 297, + 298, 299, 300, 301, 302, 303, -1, 305, 306, 307, + 308, -1, 310, 311, -1, 313, -1, 315, 316, 317, + 318, 319, 320, -1, 322, -1, -1, 325, 326, 327, + -1, -1, 330, -1, -1, -1, 334, 335, 336, 337, + 338, 339, 340, 341, -1, 343, 344, 345, 346, 347, + 348, 349, -1, 351, 352, 353, 354, 355, 356, 357, + 358, 359, 360, 361, 362, -1, 364, 365, 366, 367, + 368, 369, 370, 371, 372, 373, -1, 375, 376, -1, + 378, 379, 380, 381, 382, 383, 384, 385, 386, 387, + 388, -1, 390, 391, 392, 393, 394, -1, 396, 397, + 398, 399, -1, 401, 402, 403, -1, 405, 406, 407, + 408, 409, 410, 411, 412, 413, 414, 415, -1, 417, + 418, -1, 420, 421, 422, 423, 424, 425, -1, 427, + 428, -1, -1, 431, 432, 433, 434, -1, 436, 437, + 438, 439, 440, 441, 442, -1, -1, 445, 446, 447, + 448, 449, -1, -1, 452, 453, 454, 455, 456, 457, + 458, -1, 460, -1, 462, 463, 464, -1, -1, 467, + -1, -1, 470, 471, 472, 473, 474, 475, 476, 477, + 478, 479, 480, 481, 482, 483, 484, 485, 486, 6, + 7, 8, 9, 10, 11, 12, 13, -1, 15, 16, + -1, -1, 19, 20, 21, 22, 23, 24, -1, 26, + 27, 28, -1, -1, 31, 32, 33, 34, -1, -1, + 37, 38, 39, 40, -1, 42, -1, -1, 45, 46, + -1, -1, -1, 50, 51, -1, -1, -1, -1, 56, + -1, -1, -1, -1, -1, -1, -1, -1, 65, -1, + 67, -1, 69, 70, 71, -1, -1, -1, -1, -1, + -1, -1, 79, 80, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 91, 92, 93, 94, 95, 96, + 97, 98, -1, 100, 101, 102, -1, -1, -1, -1, + -1, -1, -1, 110, 111, -1, 113, 114, 115, 116, + 117, 118, 119, 120, -1, 122, 123, -1, 125, 126, + 127, 128, 129, -1, -1, 132, 133, 134, 135, 136, + -1, 138, 139, 140, 141, 142, -1, -1, -1, 146, + 147, 148, 149, -1, 151, -1, -1, 154, 155, 156, + 157, 158, 159, -1, -1, 162, -1, -1, -1, -1, + -1, -1, -1, -1, 171, 172, 173, 174, 175, 176, + 177, 178, 179, -1, 181, -1, 183, 184, 185, 186, + 187, -1, 189, 190, 191, -1, -1, 194, 195, 196, + 197, 198, -1, 200, 201, 202, -1, 204, 205, -1, + 207, 208, 209, 210, 211, 212, 213, 214, 215, -1, + 217, -1, 219, 220, 221, -1, 223, -1, 225, -1, + -1, -1, 229, 230, 231, -1, 233, 234, -1, 236, + -1, 238, 239, 240, 241, 242, -1, 244, 245, 246, + -1, 248, 249, 250, 251, 252, 253, -1, 255, -1, + 257, -1, 259, 260, 261, -1, 263, -1, 265, -1, + 267, -1, -1, 270, -1, 272, 273, 274, 275, 276, + 277, 278, -1, 280, 281, -1, 283, -1, -1, 286, + 287, 288, -1, -1, 291, 292, 293, 294, 295, 296, + 297, 298, 299, 300, 301, 302, 303, -1, 305, 306, + 307, 308, -1, 310, 311, -1, 313, -1, 315, 316, + 317, 318, 319, 320, -1, 322, -1, -1, 325, 326, + 327, -1, -1, 330, -1, -1, -1, 334, 335, 336, + 337, 338, 339, 340, 341, -1, 343, 344, 345, 346, + 347, 348, 349, -1, 351, 352, 353, 354, 355, 356, + 357, 358, 359, 360, 361, 362, -1, 364, 365, 366, + 367, 368, 369, 370, 371, 372, 373, -1, 375, 376, + -1, 378, 379, 380, 381, 382, 383, 384, 385, 386, + 387, 388, -1, 390, 391, 392, 393, 394, -1, 396, + 397, 398, 399, -1, 401, 402, 403, -1, 405, 406, + 407, 408, 409, 410, 411, 412, 413, 414, 415, -1, + 417, 418, -1, 420, 421, 422, 423, 424, 425, -1, + 427, 428, -1, -1, 431, 432, 433, 434, -1, 436, + 437, 438, 439, 440, 441, 442, -1, -1, 445, 446, + 447, 448, 449, -1, -1, 452, 453, 454, 455, 456, + 457, 458, -1, 460, -1, 462, 463, 464, -1, -1, + 467, -1, -1, 470, 471, 472, 473, 474, 475, 476, + 477, 478, 479, 480, 481, 482, 483, 484, 485, 486, + 6, 7, 8, 9, 10, 11, 12, 13, -1, 15, + 16, -1, -1, 19, 20, 21, 22, 23, 24, -1, + 26, 27, 28, -1, -1, 31, 32, 33, 34, -1, + -1, 37, 38, 39, 40, -1, 42, -1, -1, 45, + 46, -1, -1, -1, 50, 51, -1, -1, -1, -1, + 56, -1, -1, -1, -1, -1, -1, -1, -1, 65, + -1, 67, -1, 69, 70, 71, -1, -1, -1, -1, + -1, -1, -1, 79, 80, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 91, 92, 93, 94, 95, + 96, 97, 98, -1, 100, 101, 102, -1, -1, -1, + -1, -1, -1, -1, 110, 111, -1, 113, 114, -1, + 116, 117, 118, 119, 120, -1, 122, 123, -1, 125, + 126, 127, 128, 129, -1, -1, 132, 133, 134, 135, + 136, -1, 138, 139, 140, 141, 142, -1, -1, -1, + 146, 147, 148, 149, -1, 151, 152, -1, 154, 155, + 156, 157, 158, 159, -1, -1, 162, -1, -1, -1, + -1, -1, -1, -1, -1, 171, 172, 173, 174, 175, + 176, 177, 178, 179, -1, 181, -1, 183, 184, 185, + 186, 187, -1, 189, 190, 191, -1, -1, 194, 195, + 196, 197, 198, -1, 200, 201, 202, -1, 204, 205, + -1, 207, 208, 209, 210, 211, 212, 213, 214, 215, + -1, 217, -1, 219, 220, 221, -1, 223, -1, 225, + -1, -1, -1, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, -1, 244, 245, + 246, -1, 248, 249, 250, 251, 252, 253, -1, 255, + -1, 257, -1, 259, 260, 261, -1, 263, -1, 265, + -1, 267, -1, -1, 270, -1, 272, 273, 274, 275, + 276, 277, 278, -1, 280, 281, -1, 283, -1, -1, + 286, 287, 288, -1, -1, 291, 292, 293, 294, 295, + 296, 297, 298, 299, 300, 301, 302, 303, -1, 305, + 306, 307, 308, -1, 310, 311, -1, 313, -1, 315, + 316, 317, 318, 319, 320, -1, 322, -1, -1, 325, + 326, 327, -1, -1, 330, -1, -1, -1, 334, 335, + 336, 337, 338, 339, 340, 341, -1, 343, 344, 345, + 346, 347, 348, 349, -1, 351, 352, 353, 354, 355, + 356, 357, 358, 359, 360, 361, 362, -1, 364, 365, + 366, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, -1, 378, 379, 380, 381, 382, 383, 384, 385, + 386, 387, 388, -1, 390, 391, 392, 393, 394, -1, + 396, 397, 398, 399, -1, 401, 402, 403, -1, 405, + 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, + -1, 417, 418, -1, 420, 421, 422, 423, 424, 425, + -1, 427, 428, -1, -1, 431, 432, 433, 434, -1, + 436, 437, 438, 439, 440, 441, 442, -1, -1, 445, + 446, 447, 448, 449, -1, -1, 452, 453, 454, 455, + 456, 457, 458, -1, 460, -1, 462, 463, 464, -1, + -1, 467, -1, -1, 470, 471, 472, 473, 474, 475, + 476, 477, 478, 479, 480, 481, 482, 483, 484, 485, + 486, 6, 7, 8, 9, 10, 11, 12, 13, -1, + 15, 16, -1, -1, 19, 20, 21, 22, 23, 24, + -1, 26, 27, 28, -1, -1, 31, 32, 33, 34, + -1, -1, 37, 38, 39, 40, -1, 42, -1, -1, + 45, 46, -1, -1, -1, 50, 51, -1, -1, -1, + -1, 56, -1, -1, -1, -1, -1, -1, -1, -1, + 65, -1, 67, -1, 69, 70, 71, -1, -1, -1, + -1, -1, -1, -1, 79, 80, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 91, 92, 93, 94, + 95, 96, 97, 98, -1, 100, 101, 102, -1, -1, + -1, -1, -1, -1, -1, 110, 111, -1, 113, 114, + -1, 116, 117, 118, 119, 120, -1, 122, 123, -1, + 125, 126, 127, 128, 129, -1, -1, 132, 133, 134, + 135, 136, -1, 138, 139, 140, 141, 142, -1, -1, + -1, 146, 147, 148, 149, -1, 151, 152, -1, 154, + 155, 156, 157, 158, 159, -1, -1, 162, -1, -1, + -1, -1, -1, -1, -1, -1, 171, 172, 173, 174, + 175, 176, 177, 178, 179, -1, 181, -1, 183, 184, + 185, 186, 187, -1, 189, 190, 191, -1, -1, 194, + 195, 196, 197, 198, -1, 200, 201, 202, -1, 204, + 205, -1, 207, 208, 209, 210, 211, 212, 213, 214, + 215, -1, 217, -1, 219, 220, 221, -1, 223, -1, + 225, -1, -1, -1, 229, 230, 231, -1, 233, 234, + -1, 236, -1, 238, 239, 240, 241, 242, -1, 244, + 245, 246, -1, 248, 249, 250, 251, 252, 253, -1, + 255, -1, 257, -1, 259, 260, 261, -1, 263, -1, + 265, -1, 267, -1, -1, 270, -1, 272, 273, 274, + 275, 276, 277, 278, -1, 280, 281, -1, 283, -1, + -1, 286, 287, 288, -1, -1, 291, 292, 293, 294, + 295, 296, 297, 298, 299, 300, 301, 302, 303, -1, + 305, 306, 307, 308, -1, 310, 311, -1, 313, -1, + 315, 316, 317, 318, 319, 320, -1, 322, -1, -1, + 325, 326, 327, -1, -1, 330, -1, -1, -1, 334, + 335, 336, 337, 338, 339, 340, 341, -1, 343, 344, + 345, 346, 347, 348, 349, -1, 351, 352, 353, 354, + 355, 356, 357, 358, 359, 360, 361, 362, -1, 364, + 365, 366, 367, 368, 369, 370, 371, 372, 373, -1, + 375, 376, -1, 378, 379, 380, 381, 382, 383, 384, + 385, 386, 387, 388, -1, 390, 391, 392, 393, 394, + -1, 396, 397, 398, 399, -1, 401, 402, 403, -1, + 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, + 415, -1, 417, 418, -1, 420, 421, 422, 423, 424, + 425, -1, 427, 428, -1, -1, 431, 432, 433, 434, + -1, 436, 437, 438, 439, 440, 441, 442, -1, -1, + 445, 446, 447, 448, 449, -1, -1, 452, 453, 454, + 455, 456, 457, 458, -1, 460, -1, 462, 463, 464, + -1, -1, 467, -1, -1, 470, 471, 472, 473, 474, + 475, 476, 477, 478, 479, 480, 481, 482, 483, 484, + 485, 486, 6, 7, 8, 9, 10, 11, 12, 13, + -1, 15, 16, -1, -1, 19, 20, 21, 22, 23, + 24, -1, 26, 27, 28, -1, -1, 31, 32, 33, + 34, -1, -1, 37, 38, 39, 40, -1, 42, -1, + -1, 45, 46, -1, -1, -1, 50, 51, -1, -1, + -1, -1, 56, -1, -1, -1, -1, -1, -1, -1, + -1, 65, -1, 67, -1, 69, 70, 71, -1, -1, + -1, -1, -1, -1, -1, 79, 80, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 91, 92, 93, + 94, 95, 96, 97, 98, -1, 100, 101, 102, -1, + -1, -1, -1, -1, -1, -1, 110, 111, -1, 113, + 114, -1, 116, 117, 118, 119, 120, -1, 122, 123, + -1, 125, 126, 127, 128, 129, -1, -1, 132, 133, + 134, 135, 136, -1, 138, 139, 140, 141, 142, -1, + -1, -1, 146, 147, 148, 149, -1, 151, 152, -1, + 154, 155, 156, 157, 158, 159, -1, -1, 162, -1, + -1, -1, -1, -1, -1, -1, -1, 171, 172, 173, + 174, 175, 176, 177, 178, 179, -1, 181, -1, 183, + 184, 185, 186, 187, -1, 189, 190, 191, -1, -1, + 194, 195, 196, 197, 198, -1, 200, 201, 202, -1, + 204, 205, -1, 207, 208, 209, 210, 211, 212, 213, + 214, 215, -1, 217, -1, 219, 220, 221, -1, 223, + -1, 225, -1, -1, -1, 229, 230, 231, -1, 233, + 234, -1, 236, -1, 238, 239, 240, 241, 242, -1, + 244, 245, 246, -1, 248, 249, 250, 251, 252, 253, + -1, 255, -1, 257, -1, 259, 260, 261, -1, 263, + -1, 265, -1, 267, -1, -1, 270, -1, 272, 273, + 274, 275, 276, 277, 278, -1, 280, 281, -1, 283, + -1, -1, 286, 287, 288, -1, -1, 291, 292, 293, + 294, 295, 296, 297, 298, 299, 300, 301, 302, 303, + -1, 305, 306, 307, 308, -1, 310, 311, -1, 313, + -1, 315, 316, 317, 318, 319, 320, -1, 322, -1, + -1, 325, 326, 327, -1, -1, 330, -1, -1, -1, + 334, 335, 336, 337, 338, 339, 340, 341, -1, 343, + 344, 345, 346, 347, 348, 349, -1, 351, 352, 353, + 354, 355, 356, 357, 358, 359, 360, 361, 362, -1, + 364, 365, 366, 367, 368, 369, 370, 371, 372, 373, + -1, 375, 376, -1, 378, 379, 380, 381, 382, 383, + 384, 385, 386, 387, 388, -1, 390, 391, 392, 393, + 394, -1, 396, 397, 398, 399, -1, 401, 402, 403, + -1, 405, 406, 407, 408, 409, 410, 411, 412, 413, + 414, 415, -1, 417, 418, -1, 420, 421, 422, 423, + 424, 425, -1, 427, 428, -1, -1, 431, 432, 433, + 434, -1, 436, 437, 438, 439, 440, 441, 442, -1, + -1, 445, 446, 447, 448, 449, -1, -1, 452, 453, + 454, 455, 456, 457, 458, -1, 460, -1, 462, 463, + 464, -1, -1, 467, -1, -1, 470, 471, 472, 473, + 474, 475, 476, 477, 478, 479, 480, 481, 482, 483, + 484, 485, 486, 6, 7, 8, 9, 10, 11, 12, + 13, -1, 15, 16, -1, -1, 19, 20, 21, 22, + 23, 24, -1, 26, 27, 28, -1, -1, 31, 32, + 33, 34, -1, -1, 37, 38, 39, 40, -1, 42, + -1, -1, 45, 46, -1, -1, -1, 50, 51, -1, + -1, -1, -1, 56, -1, -1, -1, -1, -1, -1, + -1, -1, 65, -1, 67, -1, 69, 70, 71, -1, + -1, -1, -1, -1, -1, -1, 79, 80, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 91, 92, + 93, 94, 95, 96, 97, 98, -1, 100, 101, 102, + -1, -1, -1, -1, -1, -1, -1, 110, 111, -1, + 113, 114, -1, 116, 117, 118, 119, 120, -1, 122, + 123, -1, 125, 126, 127, 128, 129, -1, -1, 132, + 133, 134, 135, 136, -1, 138, 139, 140, 141, 142, + -1, -1, -1, 146, 147, 148, 149, -1, 151, 152, + -1, 154, 155, 156, 157, 158, 159, -1, -1, 162, + -1, -1, -1, -1, -1, -1, -1, -1, 171, 172, + 173, 174, 175, 176, 177, 178, 179, -1, 181, -1, + 183, 184, 185, 186, 187, -1, 189, 190, 191, -1, + -1, 194, 195, 196, 197, 198, -1, 200, 201, 202, + -1, 204, 205, -1, 207, 208, 209, 210, 211, 212, + 213, 214, 215, -1, 217, -1, 219, 220, 221, -1, + 223, -1, 225, -1, -1, -1, 229, 230, 231, -1, + 233, 234, -1, 236, -1, 238, 239, 240, 241, 242, + -1, 244, 245, 246, -1, 248, 249, 250, 251, 252, + 253, -1, 255, -1, 257, -1, 259, 260, 261, -1, + 263, -1, 265, -1, 267, -1, -1, 270, -1, 272, + 273, 274, 275, 276, 277, 278, -1, 280, 281, -1, + 283, -1, -1, 286, 287, 288, -1, -1, 291, 292, + 293, 294, 295, 296, 297, 298, 299, 300, 301, 302, + 303, -1, 305, 306, 307, 308, -1, 310, 311, -1, + 313, -1, 315, 316, 317, 318, 319, 320, -1, 322, + -1, -1, 325, 326, 327, -1, -1, 330, -1, -1, + -1, 334, 335, 336, 337, 338, 339, 340, 341, -1, + 343, 344, 345, 346, 347, 348, 349, -1, 351, 352, + 353, 354, 355, 356, 357, 358, 359, 360, 361, 362, + -1, 364, 365, 366, 367, 368, 369, 370, 371, 372, + 373, -1, 375, 376, -1, 378, 379, 380, 381, 382, + 383, 384, 385, 386, 387, 388, -1, 390, 391, 392, + 393, 394, -1, 396, 397, 398, 399, -1, 401, 402, + 403, -1, 405, 406, 407, 408, 409, 410, 411, 412, + 413, 414, 415, -1, 417, 418, -1, 420, 421, 422, + 423, 424, 425, -1, 427, 428, -1, -1, 431, 432, + 433, 434, -1, 436, 437, 438, 439, 440, 441, 442, + -1, -1, 445, 446, 447, 448, 449, -1, -1, 452, + 453, 454, 455, 456, 457, 458, -1, 460, -1, 462, + 463, 464, -1, -1, 467, -1, -1, 470, 471, 472, + 473, 474, 475, 476, 477, 478, 479, 480, 481, 482, + 483, 484, 485, 486, 6, 7, 8, 9, 10, 11, + 12, 13, -1, 15, 16, -1, -1, 19, 20, 21, + 22, 23, 24, -1, 26, 27, 28, -1, -1, 31, + 32, 33, 34, -1, -1, 37, 38, 39, 40, -1, + 42, -1, -1, 45, 46, -1, -1, -1, 50, 51, + -1, -1, -1, -1, 56, -1, -1, -1, -1, -1, + -1, -1, -1, 65, -1, 67, -1, 69, 70, 71, + -1, -1, -1, -1, -1, -1, -1, 79, 80, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 91, + 92, 93, 94, 95, 96, 97, 98, -1, 100, 101, + 102, -1, -1, -1, -1, -1, -1, -1, 110, 111, + -1, 113, 114, -1, 116, 117, 118, 119, 120, -1, + 122, 123, -1, 125, 126, 127, 128, 129, -1, -1, + 132, 133, 134, 135, 136, -1, 138, 139, 140, 141, + 142, -1, -1, -1, 146, 147, 148, 149, -1, 151, + 152, -1, 154, 155, 156, 157, 158, 159, -1, -1, + 162, -1, -1, -1, -1, -1, -1, -1, -1, 171, + 172, 173, 174, 175, 176, 177, 178, 179, -1, 181, + -1, 183, 184, 185, 186, 187, -1, 189, 190, 191, + -1, -1, 194, 195, 196, 197, 198, -1, 200, 201, + 202, -1, 204, 205, -1, 207, 208, 209, 210, 211, + 212, 213, 214, 215, -1, 217, -1, 219, 220, 221, + -1, 223, -1, 225, -1, -1, -1, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, -1, 244, 245, 246, -1, 248, 249, 250, 251, + 252, 253, -1, 255, -1, 257, -1, 259, 260, 261, + -1, 263, -1, 265, -1, 267, -1, -1, 270, -1, + 272, 273, 274, 275, 276, 277, 278, -1, 280, 281, + -1, 283, -1, -1, 286, 287, 288, -1, -1, 291, + 292, 293, 294, 295, 296, 297, 298, 299, 300, 301, + 302, 303, -1, 305, 306, 307, 308, -1, 310, 311, + -1, 313, -1, 315, 316, 317, 318, 319, 320, -1, + 322, -1, -1, 325, 326, 327, -1, -1, 330, -1, + -1, -1, 334, 335, 336, 337, 338, 339, 340, 341, + -1, 343, 344, 345, 346, 347, 348, 349, -1, 351, + 352, 353, 354, 355, 356, 357, 358, 359, 360, 361, + 362, -1, 364, 365, 366, 367, 368, 369, 370, 371, + 372, 373, -1, 375, 376, -1, 378, 379, 380, 381, + 382, 383, 384, 385, 386, 387, 388, -1, 390, 391, + 392, 393, 394, -1, 396, 397, 398, 399, -1, 401, + 402, 403, -1, 405, 406, 407, 408, 409, 410, 411, + 412, 413, 414, 415, -1, 417, 418, -1, 420, 421, + 422, 423, 424, 425, -1, 427, 428, -1, -1, 431, + 432, 433, 434, -1, 436, 437, 438, 439, 440, 441, + 442, -1, -1, 445, 446, 447, 448, 449, -1, -1, + 452, 453, 454, 455, 456, 457, 458, -1, 460, -1, + 462, 463, 464, -1, -1, 467, -1, -1, 470, 471, + 472, 473, 474, 475, 476, 477, 478, 479, 480, 481, + 482, 483, 484, 485, 486, 6, 7, 8, 9, 10, + 11, 12, 13, -1, 15, 16, -1, -1, 19, 20, + 21, 22, 23, 24, -1, 26, 27, 28, -1, -1, + 31, 32, 33, 34, -1, -1, 37, 38, 39, 40, + -1, 42, -1, -1, 45, 46, -1, -1, -1, 50, + 51, -1, -1, -1, -1, 56, -1, -1, -1, -1, + -1, -1, -1, -1, 65, -1, 67, -1, 69, 70, + 71, -1, -1, -1, -1, -1, -1, -1, 79, 80, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 91, 92, 93, 94, 95, 96, 97, 98, -1, 100, + 101, 102, -1, -1, -1, -1, -1, -1, -1, 110, + 111, -1, 113, 114, -1, 116, 117, 118, 119, 120, + -1, 122, 123, -1, 125, 126, 127, 128, 129, -1, + -1, 132, 133, 134, 135, 136, -1, 138, 139, 140, + 141, 142, -1, -1, -1, 146, 147, 148, 149, -1, + 151, 152, -1, 154, 155, 156, 157, 158, 159, -1, + -1, 162, -1, -1, -1, -1, -1, -1, -1, -1, + 171, 172, 173, 174, 175, 176, 177, 178, 179, -1, + 181, -1, 183, 184, 185, 186, 187, -1, 189, 190, + 191, -1, -1, 194, 195, 196, 197, 198, -1, 200, + 201, 202, -1, 204, 205, -1, 207, 208, 209, 210, + 211, 212, 213, 214, 215, -1, 217, -1, 219, 220, + 221, -1, 223, -1, 225, -1, -1, -1, 229, 230, + 231, -1, 233, 234, -1, 236, -1, 238, 239, 240, + 241, 242, -1, 244, 245, 246, -1, 248, 249, 250, + 251, 252, 253, -1, 255, -1, 257, -1, 259, 260, + 261, -1, 263, -1, 265, -1, 267, -1, -1, 270, + -1, 272, 273, 274, 275, 276, 277, 278, -1, 280, + 281, -1, 283, -1, -1, 286, 287, 288, -1, -1, + 291, 292, 293, 294, 295, 296, 297, 298, 299, 300, + 301, 302, 303, -1, 305, 306, 307, 308, -1, 310, + 311, -1, 313, -1, 315, 316, 317, 318, 319, 320, + -1, 322, -1, -1, 325, 326, 327, -1, -1, 330, + -1, -1, -1, 334, 335, 336, 337, 338, 339, 340, + 341, -1, 343, 344, 345, 346, 347, 348, 349, -1, + 351, 352, 353, 354, 355, 356, 357, 358, 359, 360, + 361, 362, -1, 364, 365, 366, 367, 368, 369, 370, + 371, 372, 373, -1, 375, 376, -1, 378, 379, 380, + 381, 382, 383, 384, 385, 386, 387, 388, -1, 390, + 391, 392, 393, 394, -1, 396, 397, 398, 399, -1, + 401, 402, 403, -1, 405, 406, 407, 408, 409, 410, + 411, 412, 413, 414, 415, -1, 417, 418, -1, 420, + 421, 422, 423, 424, 425, -1, 427, 428, -1, -1, + 431, 432, 433, 434, -1, 436, 437, 438, 439, 440, + 441, 442, -1, -1, 445, 446, 447, 448, 449, -1, + -1, 452, 453, 454, 455, 456, 457, 458, -1, 460, + -1, 462, 463, 464, -1, -1, 467, -1, -1, 470, + 471, 472, 473, 474, 475, 476, 477, 478, 479, 480, + 481, 482, 483, 484, 485, 486, 6, 7, 8, 9, + 10, 11, 12, 13, -1, 15, 16, -1, -1, 19, + 20, 21, 22, 23, 24, -1, 26, 27, 28, -1, + -1, 31, 32, 33, 34, -1, -1, 37, 38, 39, + 40, -1, 42, -1, -1, 45, 46, -1, -1, -1, + 50, 51, -1, -1, -1, -1, 56, -1, -1, -1, + -1, -1, -1, -1, -1, 65, -1, 67, -1, 69, + 70, 71, -1, -1, -1, -1, -1, -1, -1, 79, + 80, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 91, 92, 93, 94, 95, 96, 97, 98, -1, + 100, 101, 102, -1, -1, -1, -1, -1, -1, -1, + 110, 111, -1, 113, 114, -1, 116, 117, 118, 119, + 120, -1, 122, 123, -1, 125, 126, 127, 128, 129, + -1, -1, 132, 133, 134, 135, 136, -1, 138, 139, + 140, 141, 142, -1, -1, -1, 146, 147, 148, 149, + -1, 151, 152, -1, 154, 155, 156, 157, 158, 159, + -1, -1, 162, -1, -1, -1, -1, -1, -1, -1, + -1, 171, 172, 173, 174, 175, 176, 177, 178, 179, + -1, 181, -1, 183, 184, 185, 186, 187, -1, 189, + 190, 191, -1, -1, 194, 195, 196, 197, 198, -1, + 200, 201, 202, -1, 204, 205, -1, 207, 208, 209, + 210, 211, 212, 213, 214, 215, -1, 217, -1, 219, + 220, 221, -1, 223, -1, 225, -1, -1, -1, 229, + 230, 231, -1, 233, 234, -1, 236, -1, 238, 239, + 240, 241, 242, -1, 244, 245, 246, -1, 248, 249, + 250, 251, 252, 253, -1, 255, -1, 257, -1, 259, + 260, 261, -1, 263, -1, 265, -1, 267, -1, -1, + 270, -1, 272, 273, 274, 275, 276, 277, 278, -1, + 280, 281, -1, 283, -1, -1, 286, 287, 288, -1, + -1, 291, 292, 293, 294, 295, 296, 297, 298, 299, + 300, 301, 302, 303, -1, 305, 306, 307, 308, -1, + 310, 311, -1, 313, -1, 315, 316, 317, 318, 319, + 320, -1, 322, -1, -1, 325, 326, 327, -1, -1, + 330, -1, -1, -1, 334, 335, 336, 337, 338, 339, + 340, 341, -1, 343, 344, 345, 346, 347, 348, 349, + -1, 351, 352, 353, 354, 355, 356, 357, 358, 359, + 360, 361, 362, -1, 364, 365, 366, 367, 368, 369, + 370, 371, 372, 373, -1, 375, 376, -1, 378, 379, + 380, 381, 382, 383, 384, 385, 386, 387, 388, -1, + 390, 391, 392, 393, 394, -1, 396, 397, 398, 399, + -1, 401, 402, 403, -1, 405, 406, 407, 408, 409, + 410, 411, 412, 413, 414, 415, -1, 417, 418, -1, + 420, 421, 422, 423, 424, 425, -1, 427, 428, -1, + -1, 431, 432, 433, 434, -1, 436, 437, 438, 439, + 440, 441, 442, -1, -1, 445, 446, 447, 448, 449, + -1, -1, 452, 453, 454, 455, 456, 457, 458, -1, + 460, -1, 462, 463, 464, -1, -1, 467, -1, -1, + 470, 471, 472, 473, 474, 475, 476, 477, 478, 479, + 480, 481, 482, 483, 484, 485, 486, 6, 7, 8, + 9, 10, 11, 12, 13, -1, 15, 16, -1, -1, + 19, 20, 21, 22, 23, 24, -1, 26, 27, 28, + -1, -1, 31, 32, 33, 34, -1, -1, 37, 38, + 39, 40, -1, 42, -1, -1, 45, 46, -1, -1, + -1, 50, 51, -1, -1, -1, -1, 56, -1, -1, + -1, -1, -1, -1, -1, -1, 65, -1, 67, -1, + 69, 70, 71, -1, -1, -1, -1, -1, -1, -1, + 79, 80, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 91, 92, 93, 94, 95, 96, 97, 98, + -1, 100, 101, 102, -1, -1, -1, -1, -1, 108, + -1, 110, 111, -1, 113, 114, -1, 116, 117, 118, + 119, 120, -1, 122, 123, -1, 125, 126, 127, 128, + 129, -1, -1, 132, 133, 134, 135, 136, -1, 138, + 139, 140, 141, 142, -1, -1, -1, 146, 147, 148, + 149, -1, 151, 152, -1, 154, 155, 156, 157, 158, + 159, -1, -1, 162, -1, -1, -1, -1, -1, -1, + -1, -1, 171, 172, 173, 174, 175, 176, 177, 178, + 179, -1, 181, -1, 183, 184, 185, 186, 187, -1, + 189, 190, 191, -1, -1, 194, 195, 196, 197, 198, + -1, 200, 201, 202, -1, 204, 205, -1, 207, 208, + 209, 210, 211, 212, 213, 214, 215, -1, 217, -1, + 219, 220, 221, -1, 223, -1, 225, -1, -1, -1, + 229, 230, 231, -1, 233, 234, -1, 236, -1, 238, + 239, 240, 241, 242, -1, 244, 245, 246, -1, 248, + 249, 250, 251, 252, 253, -1, 255, -1, 257, -1, + 259, 260, 261, -1, 263, -1, 265, -1, 267, -1, + -1, 270, -1, 272, 273, 274, 275, 276, 277, 278, + -1, 280, 281, -1, 283, -1, -1, 286, 287, 288, + -1, -1, 291, 292, 293, 294, 295, 296, 297, 298, + 299, 300, 301, 302, 303, -1, 305, 306, 307, 308, + -1, 310, 311, -1, 313, -1, 315, 316, 317, 318, + 319, 320, -1, 322, -1, -1, 325, 326, 327, -1, + -1, 330, -1, -1, -1, 334, 335, 336, 337, 338, + 339, 340, 341, -1, 343, 344, 345, 346, 347, 348, + 349, -1, 351, 352, 353, 354, 355, 356, 357, 358, + 359, 360, 361, 362, -1, 364, 365, 366, 367, 368, + 369, 370, 371, 372, 373, -1, 375, 376, -1, 378, + 379, 380, 381, 382, 383, 384, 385, 386, 387, 388, + -1, 390, 391, 392, 393, 394, -1, -1, 397, 398, + 399, -1, 401, 402, 403, -1, 405, 406, 407, 408, + 409, 410, 411, 412, 413, 414, 415, -1, 417, 418, + -1, 420, 421, 422, 423, 424, 425, -1, 427, 428, + -1, -1, 431, 432, 433, 434, -1, 436, 437, 438, + 439, 440, 441, 442, -1, -1, 445, 446, 447, 448, + 449, -1, -1, 452, 453, 454, 455, 456, 457, 458, + -1, 460, -1, 462, 463, 464, -1, -1, 467, -1, + -1, 470, 471, 472, 473, 474, 475, 476, 477, 478, + 479, 480, 481, 482, 483, 484, 485, 486, 6, 7, + 8, 9, 10, 11, 12, 13, -1, 15, 16, -1, + -1, 19, 20, 21, 22, 23, 24, -1, 26, 27, + 28, -1, -1, 31, 32, 33, 34, -1, -1, 37, + 38, 39, 40, -1, 42, -1, -1, 45, 46, -1, + -1, -1, 50, 51, -1, -1, -1, -1, 56, -1, + -1, -1, -1, -1, -1, -1, -1, 65, -1, 67, + -1, 69, 70, 71, -1, -1, -1, -1, -1, -1, + -1, 79, 80, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 91, 92, 93, 94, 95, 96, 97, + 98, -1, 100, 101, 102, -1, -1, -1, -1, -1, + -1, -1, 110, 111, -1, 113, 114, -1, 116, 117, + 118, 119, 120, -1, 122, 123, -1, 125, 126, 127, + 128, 129, -1, -1, 132, 133, 134, 135, 136, -1, + 138, 139, 140, 141, 142, -1, -1, -1, 146, 147, + 148, 149, -1, 151, 152, -1, 154, 155, 156, 157, + 158, 159, -1, -1, 162, -1, -1, -1, -1, -1, + -1, -1, -1, 171, 172, 173, 174, 175, 176, 177, + 178, 179, -1, 181, -1, 183, 184, 185, 186, 187, + -1, 189, 190, 191, -1, -1, 194, 195, 196, 197, + 198, -1, 200, 201, 202, -1, 204, 205, -1, 207, + 208, 209, 210, 211, 212, 213, 214, 215, -1, 217, + -1, 219, 220, 221, -1, 223, -1, 225, -1, -1, + -1, 229, 230, 231, -1, 233, 234, -1, 236, -1, + 238, 239, 240, 241, 242, -1, 244, 245, 246, -1, + 248, 249, 250, 251, 252, 253, -1, 255, -1, 257, + -1, 259, 260, 261, -1, 263, -1, 265, -1, 267, + -1, -1, 270, -1, 272, 273, 274, 275, 276, 277, + 278, -1, 280, 281, -1, 283, -1, -1, 286, 287, + 288, -1, -1, 291, 292, 293, 294, 295, 296, 297, + 298, 299, 300, 301, 302, 303, -1, 305, 306, 307, + 308, -1, 310, 311, -1, 313, -1, 315, 316, 317, + 318, 319, 320, -1, 322, -1, -1, 325, 326, 327, + -1, -1, 330, -1, -1, -1, 334, 335, 336, 337, + 338, 339, 340, 341, -1, 343, 344, 345, 346, 347, + 348, 349, -1, 351, 352, 353, 354, 355, 356, 357, + 358, 359, 360, 361, 362, -1, 364, 365, 366, 367, + 368, 369, 370, 371, 372, 373, -1, 375, 376, -1, + 378, 379, 380, 381, 382, 383, 384, 385, 386, 387, + 388, -1, 390, 391, 392, 393, 394, -1, 396, 397, + 398, 399, -1, 401, 402, 403, -1, 405, 406, 407, + 408, 409, 410, 411, 412, 413, 414, 415, -1, 417, + 418, -1, 420, 421, 422, 423, 424, 425, -1, 427, + 428, -1, -1, 431, 432, 433, 434, -1, 436, 437, + 438, 439, 440, 441, 442, -1, -1, 445, 446, 447, + 448, 449, -1, -1, 452, 453, 454, 455, 456, 457, + 458, -1, 460, -1, 462, 463, 464, -1, -1, 467, + -1, -1, 470, 471, 472, 473, 474, 475, 476, 477, + 478, 479, 480, 481, 482, 483, 484, 485, 486, 6, + 7, 8, 9, 10, 11, 12, 13, -1, 15, 16, + -1, -1, 19, 20, 21, 22, 23, 24, -1, 26, + 27, 28, -1, -1, 31, 32, 33, 34, -1, -1, + 37, 38, 39, 40, -1, 42, -1, -1, 45, 46, + -1, -1, -1, 50, 51, -1, -1, -1, -1, 56, + -1, -1, -1, -1, -1, -1, -1, -1, 65, -1, + 67, -1, 69, 70, 71, -1, -1, -1, -1, -1, + -1, -1, 79, 80, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 91, 92, 93, 94, 95, 96, + 97, 98, -1, 100, 101, 102, -1, -1, -1, -1, + -1, -1, -1, 110, 111, -1, 113, 114, -1, 116, + 117, 118, 119, 120, -1, 122, 123, -1, 125, 126, + 127, 128, 129, -1, -1, 132, 133, 134, 135, 136, + -1, 138, 139, 140, 141, 142, -1, -1, -1, 146, + 147, 148, 149, -1, 151, 152, -1, 154, 155, 156, + 157, 158, 159, -1, -1, 162, -1, -1, -1, -1, + -1, -1, -1, -1, 171, 172, 173, 174, 175, 176, + 177, 178, 179, -1, 181, -1, 183, 184, 185, 186, + 187, -1, 189, 190, 191, -1, -1, 194, 195, 196, + 197, 198, -1, 200, 201, 202, -1, 204, 205, -1, + 207, 208, 209, 210, 211, 212, 213, 214, 215, -1, + 217, -1, 219, 220, 221, -1, 223, -1, 225, -1, + -1, -1, 229, 230, 231, -1, 233, 234, -1, 236, + -1, 238, 239, 240, 241, 242, -1, 244, 245, 246, + -1, 248, 249, 250, 251, 252, 253, -1, 255, -1, + 257, -1, 259, 260, 261, -1, 263, -1, 265, -1, + 267, -1, -1, 270, -1, 272, 273, 274, 275, 276, + 277, 278, -1, 280, 281, -1, 283, -1, -1, 286, + 287, 288, -1, -1, 291, 292, 293, 294, 295, 296, + 297, 298, 299, 300, 301, 302, 303, -1, 305, 306, + 307, 308, -1, 310, 311, -1, 313, -1, 315, 316, + 317, 318, 319, 320, -1, 322, -1, -1, 325, 326, + 327, -1, -1, 330, -1, -1, -1, 334, 335, 336, + 337, 338, 339, 340, 341, -1, 343, 344, 345, 346, + 347, 348, 349, -1, 351, 352, 353, 354, 355, 356, + 357, 358, 359, 360, 361, 362, -1, 364, 365, 366, + 367, 368, 369, 370, 371, 372, 373, -1, 375, 376, + -1, 378, 379, 380, 381, 382, 383, 384, 385, 386, + 387, 388, -1, 390, 391, 392, 393, 394, -1, 396, + 397, 398, 399, -1, 401, 402, 403, -1, 405, 406, + 407, 408, 409, 410, 411, 412, 413, 414, 415, -1, + 417, 418, -1, 420, 421, 422, 423, 424, 425, -1, + 427, 428, -1, -1, 431, 432, 433, 434, -1, 436, + 437, 438, 439, 440, 441, 442, -1, -1, 445, 446, + 447, 448, 449, -1, -1, 452, 453, 454, 455, 456, + 457, 458, -1, 460, -1, 462, 463, 464, -1, -1, + 467, -1, -1, 470, 471, 472, 473, 474, 475, 476, + 477, 478, 479, 480, 481, 482, 483, 484, 485, 486, + 6, 7, 8, 9, 10, 11, 12, 13, -1, 15, + 16, -1, -1, 19, 20, 21, 22, 23, 24, -1, + 26, 27, 28, -1, -1, 31, 32, 33, 34, -1, + -1, 37, 38, 39, 40, -1, 42, -1, -1, 45, + 46, -1, -1, -1, 50, 51, -1, -1, -1, -1, + 56, -1, -1, -1, -1, -1, -1, -1, -1, 65, + -1, 67, -1, 69, 70, 71, -1, -1, -1, -1, + -1, -1, -1, 79, 80, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 91, 92, 93, 94, 95, + 96, 97, 98, -1, 100, 101, 102, -1, -1, -1, + -1, -1, -1, -1, 110, 111, -1, 113, 114, -1, + 116, 117, 118, 119, 120, -1, 122, 123, -1, 125, + 126, 127, 128, 129, -1, -1, 132, 133, 134, 135, + 136, -1, 138, 139, 140, 141, 142, -1, -1, -1, + 146, 147, 148, 149, -1, 151, 152, -1, 154, 155, + 156, 157, 158, 159, -1, -1, 162, -1, -1, -1, + -1, -1, -1, -1, -1, 171, 172, 173, 174, 175, + 176, 177, 178, 179, -1, 181, -1, 183, 184, 185, + 186, 187, -1, 189, 190, 191, -1, -1, 194, 195, + 196, 197, 198, -1, 200, 201, 202, -1, 204, 205, + -1, 207, 208, 209, 210, 211, 212, 213, 214, 215, + -1, 217, -1, 219, 220, 221, -1, 223, -1, 225, + -1, -1, -1, 229, 230, 231, -1, 233, 234, -1, + 236, -1, 238, 239, 240, 241, 242, -1, 244, 245, + 246, -1, 248, 249, 250, 251, 252, 253, -1, 255, + -1, 257, -1, 259, 260, 261, -1, 263, -1, 265, + -1, 267, -1, -1, 270, -1, 272, 273, 274, 275, + 276, 277, 278, -1, 280, 281, -1, 283, -1, -1, + 286, 287, 288, -1, -1, 291, 292, 293, 294, 295, + 296, 297, 298, 299, 300, 301, 302, 303, -1, 305, + 306, 307, 308, -1, 310, 311, -1, 313, -1, 315, + 316, 317, 318, 319, 320, -1, 322, -1, -1, 325, + 326, 327, -1, -1, 330, -1, -1, -1, 334, 335, + 336, 337, 338, 339, 340, 341, -1, 343, 344, 345, + 346, 347, 348, 349, -1, 351, 352, 353, 354, 355, + 356, 357, 358, 359, 360, 361, 362, -1, 364, 365, + 366, 367, 368, 369, 370, 371, 372, 373, -1, 375, + 376, -1, 378, 379, 380, 381, 382, 383, 384, 385, + 386, 387, 388, -1, 390, 391, 392, 393, 394, -1, + 396, 397, 398, 399, -1, 401, 402, 403, -1, 405, + 406, 407, 408, 409, 410, 411, 412, 413, 414, 415, + -1, 417, 418, -1, 420, 421, 422, 423, 424, 425, + -1, 427, 428, -1, -1, 431, 432, 433, 434, -1, + 436, 437, 438, 439, 440, 441, 442, -1, -1, 445, + 446, 447, 448, 449, -1, -1, 452, 453, 454, 455, + 456, 457, 458, -1, 460, -1, 462, 463, 464, -1, + -1, 467, -1, -1, 470, 471, 472, 473, 474, 475, + 476, 477, 478, 479, 480, 481, 482, 483, 484, 485, + 486, 6, 7, 8, 9, 10, 11, 12, 13, -1, + 15, 16, -1, -1, 19, 20, 21, 22, 23, 24, + -1, 26, 27, 28, -1, -1, 31, 32, 33, 34, + -1, -1, 37, 38, 39, 40, -1, 42, -1, -1, + 45, 46, -1, -1, -1, 50, 51, -1, -1, -1, + -1, 56, -1, -1, -1, -1, -1, -1, -1, -1, + 65, -1, 67, -1, 69, 70, 71, -1, -1, -1, + -1, -1, -1, -1, 79, 80, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 91, 92, 93, 94, + 95, 96, 97, 98, -1, 100, 101, 102, -1, -1, + -1, -1, -1, -1, -1, 110, 111, -1, 113, 114, + -1, 116, 117, 118, 119, 120, -1, 122, 123, -1, + 125, 126, 127, 128, 129, -1, -1, 132, 133, 134, + 135, 136, -1, 138, 139, 140, 141, 142, -1, -1, + -1, 146, 147, 148, 149, -1, 151, 152, -1, 154, + 155, 156, 157, 158, 159, -1, -1, 162, -1, -1, + -1, -1, -1, -1, -1, -1, 171, 172, 173, 174, + 175, 176, 177, 178, 179, -1, 181, -1, 183, 184, + 185, 186, 187, -1, 189, 190, 191, -1, -1, 194, + 195, 196, 197, 198, -1, 200, 201, 202, -1, 204, + 205, -1, 207, 208, 209, 210, 211, 212, 213, 214, + 215, -1, 217, -1, 219, 220, 221, -1, 223, -1, + 225, -1, -1, -1, 229, 230, 231, -1, 233, 234, + -1, 236, -1, 238, 239, 240, 241, 242, -1, 244, + 245, 246, -1, 248, 249, 250, 251, 252, 253, -1, + 255, -1, 257, -1, 259, 260, 261, -1, 263, -1, + 265, -1, 267, -1, -1, 270, -1, 272, 273, 274, + 275, 276, 277, 278, -1, 280, 281, -1, 283, -1, + -1, 286, 287, 288, -1, -1, 291, 292, 293, 294, + 295, 296, 297, 298, 299, 300, 301, 302, 303, -1, + 305, 306, 307, 308, -1, 310, 311, -1, 313, -1, + 315, 316, 317, 318, 319, 320, -1, 322, -1, -1, + 325, 326, 327, -1, -1, 330, -1, -1, -1, 334, + 335, 336, 337, 338, 339, 340, 341, -1, 343, 344, + 345, 346, 347, 348, 349, -1, 351, 352, 353, 354, + 355, 356, 357, 358, 359, 360, 361, 362, -1, 364, + 365, 366, 367, 368, 369, 370, 371, 372, 373, -1, + 375, 376, -1, 378, 379, 380, 381, 382, 383, 384, + 385, 386, 387, 388, -1, 390, 391, 392, 393, 394, + -1, 396, 397, 398, 399, -1, 401, 402, 403, -1, + 405, 406, 407, 408, 409, 410, 411, 412, 413, 414, + 415, -1, 417, 418, -1, 420, 421, 422, 423, 424, + 425, -1, 427, 428, -1, -1, 431, 432, 433, 434, + -1, 436, 437, 438, 439, 440, 441, 442, -1, -1, + 445, 446, 447, 448, 449, -1, -1, 452, 453, 454, + 455, 456, 457, 458, -1, 460, -1, 462, 463, 464, + -1, -1, 467, -1, -1, 470, 471, 472, 473, 474, + 475, 476, 477, 478, 479, 480, 481, 482, 483, 484, + 485, 486, 6, 7, 8, 9, 10, 11, 12, 13, + -1, 15, 16, -1, -1, 19, 20, 21, 22, 23, + 24, -1, 26, 27, 28, -1, -1, 31, 32, 33, + 34, -1, -1, 37, 38, 39, 40, -1, 42, -1, + -1, 45, 46, -1, -1, -1, 50, 51, -1, -1, + -1, -1, 56, -1, -1, -1, -1, -1, -1, -1, + -1, 65, -1, 67, -1, 69, 70, 71, -1, -1, + -1, -1, -1, -1, -1, 79, 80, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 91, 92, 93, + 94, 95, 96, 97, 98, -1, 100, 101, 102, -1, + -1, -1, -1, -1, -1, -1, 110, 111, -1, 113, + 114, -1, 116, 117, 118, 119, 120, -1, 122, 123, + -1, 125, 126, 127, 128, 129, -1, -1, 132, 133, + 134, 135, 136, -1, 138, 139, 140, 141, 142, -1, + -1, -1, 146, 147, 148, 149, -1, 151, 152, -1, + 154, 155, 156, 157, 158, 159, -1, -1, 162, -1, + -1, -1, -1, -1, -1, -1, -1, 171, 172, 173, + 174, 175, 176, 177, 178, 179, -1, 181, -1, 183, + 184, 185, 186, 187, -1, 189, 190, 191, -1, -1, + 194, 195, 196, 197, 198, -1, 200, 201, 202, -1, + 204, 205, -1, 207, 208, 209, 210, 211, 212, 213, + 214, 215, -1, 217, -1, 219, 220, 221, -1, 223, + -1, 225, -1, -1, -1, 229, 230, 231, -1, 233, + 234, -1, 236, -1, 238, 239, 240, 241, 242, -1, + 244, 245, 246, -1, 248, 249, 250, 251, 252, 253, + -1, 255, -1, 257, -1, 259, 260, 261, -1, 263, + -1, 265, -1, 267, -1, -1, 270, -1, 272, 273, + 274, 275, 276, 277, 278, -1, 280, 281, -1, 283, + -1, -1, 286, 287, 288, -1, -1, 291, 292, 293, + 294, 295, 296, 297, 298, 299, 300, 301, 302, 303, + -1, 305, 306, 307, 308, -1, 310, 311, -1, 313, + -1, 315, 316, 317, 318, 319, 320, -1, 322, -1, + -1, 325, 326, 327, -1, -1, 330, -1, -1, -1, + 334, 335, 336, 337, 338, 339, 340, 341, -1, 343, + 344, 345, 346, 347, 348, 349, -1, 351, 352, 353, + 354, 355, 356, 357, 358, 359, 360, 361, 362, -1, + 364, 365, 366, 367, 368, 369, 370, 371, 372, 373, + -1, 375, 376, -1, 378, 379, 380, 381, 382, 383, + 384, 385, 386, 387, 388, -1, 390, 391, 392, 393, + 394, -1, 396, 397, 398, 399, -1, 401, 402, 403, + -1, 405, 406, 407, 408, 409, 410, 411, 412, 413, + 414, 415, -1, 417, 418, -1, 420, 421, 422, 423, + 424, 425, -1, 427, 428, -1, -1, 431, 432, 433, + 434, -1, 436, 437, 438, 439, 440, 441, 442, -1, + -1, 445, 446, 447, 448, 449, -1, -1, 452, 453, + 454, 455, 456, 457, 458, -1, 460, -1, 462, 463, + 464, -1, -1, 467, -1, -1, 470, 471, 472, 473, + 474, 475, 476, 477, 478, 479, 480, 481, 482, 483, + 484, 485, 486, 6, 7, 8, 9, 10, 11, 12, + 13, -1, 15, 16, -1, -1, 19, 20, 21, 22, + 23, 24, -1, 26, 27, 28, -1, -1, 31, 32, + 33, 34, -1, -1, 37, 38, 39, 40, -1, 42, + -1, -1, 45, 46, -1, -1, -1, 50, 51, -1, + -1, -1, -1, 56, -1, -1, -1, -1, -1, -1, + -1, -1, 65, -1, 67, -1, 69, 70, 71, -1, + -1, -1, -1, -1, -1, -1, 79, 80, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 91, 92, + 93, 94, 95, 96, 97, 98, -1, 100, 101, 102, + -1, -1, -1, -1, -1, -1, -1, 110, 111, -1, + 113, 114, -1, 116, 117, 118, 119, 120, -1, 122, + 123, -1, 125, 126, 127, 128, 129, -1, -1, 132, + 133, 134, 135, 136, -1, 138, 139, 140, 141, 142, + -1, -1, -1, 146, 147, 148, 149, -1, 151, -1, + -1, 154, 155, 156, 157, 158, 159, -1, -1, 162, + -1, -1, -1, -1, -1, -1, -1, -1, 171, 172, + 173, 174, 175, 176, 177, 178, 179, -1, 181, -1, + 183, 184, 185, 186, 187, -1, 189, 190, 191, -1, + -1, 194, 195, 196, 197, 198, -1, 200, 201, 202, + -1, 204, 205, -1, 207, 208, 209, 210, 211, 212, + 213, 214, 215, -1, 217, -1, 219, 220, 221, -1, + 223, -1, 225, -1, -1, -1, 229, 230, 231, -1, + 233, 234, -1, 236, -1, 238, 239, 240, 241, 242, + -1, 244, 245, 246, -1, 248, 249, 250, 251, 252, + 253, -1, 255, -1, 257, -1, 259, 260, 261, -1, + 263, -1, 265, -1, 267, -1, -1, 270, -1, 272, + 273, 274, 275, 276, 277, 278, -1, 280, 281, -1, + 283, -1, -1, 286, 287, 288, -1, -1, 291, 292, + 293, 294, 295, 296, 297, 298, 299, 300, 301, 302, + 303, -1, 305, 306, 307, 308, -1, 310, 311, -1, + 313, -1, 315, 316, 317, 318, 319, 320, -1, 322, + -1, -1, 325, 326, 327, -1, -1, 330, -1, -1, + -1, 334, 335, 336, 337, 338, 339, 340, 341, -1, + 343, 344, 345, 346, 347, 348, 349, -1, 351, 352, + 353, 354, 355, 356, 357, 358, 359, 360, 361, 362, + -1, 364, 365, 366, 367, 368, 369, 370, 371, 372, + 373, -1, 375, 376, -1, 378, 379, 380, 381, 382, + 383, 384, 385, 386, 387, 388, -1, 390, 391, 392, + 393, 394, -1, 396, 397, 398, 399, -1, 401, 402, + 403, -1, 405, 406, 407, 408, 409, 410, 411, 412, + 413, 414, 415, -1, 417, 418, -1, 420, 421, 422, + 423, 424, 425, -1, 427, 428, -1, -1, 431, 432, + 433, 434, -1, 436, 437, 438, 439, 440, 441, 442, + -1, -1, 445, 446, 447, 448, 449, -1, -1, 452, + 453, 454, 455, 456, 457, 458, -1, 460, -1, 462, + 463, 464, -1, -1, 467, -1, -1, 470, 471, 472, + 473, 474, 475, 476, 477, 478, 479, 480, 481, 482, + 483, 484, 485, 486, 6, 7, 8, 9, 10, 11, + 12, 13, -1, 15, 16, -1, -1, 19, 20, 21, + 22, 23, 24, -1, 26, 27, 28, -1, -1, 31, + 32, 33, 34, -1, -1, 37, 38, 39, 40, -1, + 42, -1, -1, 45, 46, -1, -1, -1, 50, 51, + -1, -1, -1, -1, 56, -1, -1, -1, -1, -1, + -1, -1, -1, 65, -1, 67, -1, 69, 70, 71, + -1, -1, -1, -1, -1, -1, -1, 79, 80, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 91, + 92, 93, 94, 95, 96, 97, 98, -1, 100, 101, + 102, -1, -1, -1, -1, -1, -1, -1, 110, 111, + -1, 113, 114, -1, 116, 117, 118, 119, 120, -1, + 122, 123, -1, 125, 126, 127, 128, 129, -1, -1, + 132, 133, 134, 135, 136, -1, 138, 139, 140, 141, + 142, -1, -1, -1, 146, 147, 148, 149, -1, 151, + -1, -1, 154, 155, 156, 157, 158, 159, -1, -1, + 162, -1, -1, -1, -1, -1, -1, -1, -1, 171, + 172, 173, 174, 175, 176, 177, 178, 179, -1, 181, + -1, 183, 184, 185, 186, 187, -1, 189, 190, 191, + -1, -1, 194, 195, 196, 197, 198, -1, 200, 201, + 202, -1, 204, 205, -1, 207, 208, 209, 210, 211, + 212, 213, 214, 215, -1, 217, -1, 219, 220, 221, + -1, 223, -1, 225, -1, -1, -1, 229, 230, 231, + -1, 233, 234, -1, 236, -1, 238, 239, 240, 241, + 242, -1, 244, 245, 246, -1, 248, 249, 250, 251, + 252, 253, -1, 255, -1, 257, -1, 259, 260, 261, + -1, 263, -1, 265, -1, 267, -1, -1, 270, -1, + 272, 273, 274, 275, 276, 277, 278, -1, 280, 281, + -1, 283, -1, -1, 286, 287, 288, -1, -1, 291, + 292, 293, 294, 295, 296, 297, 298, 299, 300, 301, + 302, 303, -1, 305, 306, 307, 308, -1, 310, 311, + -1, 313, -1, 315, 316, 317, 318, 319, 320, -1, + 322, -1, -1, 325, 326, 327, -1, -1, 330, -1, + -1, -1, 334, 335, 336, 337, 338, 339, 340, 341, + -1, 343, 344, 345, 346, 347, 348, 349, -1, 351, + 352, 353, 354, 355, 356, 357, 358, 359, 360, 361, + 362, -1, 364, 365, 366, 367, 368, 369, 370, 371, + 372, 373, -1, 375, 376, -1, 378, 379, 380, 381, + 382, 383, 384, 385, 386, 387, 388, -1, 390, 391, + 392, 393, 394, -1, 396, 397, 398, 399, -1, 401, + 402, 403, -1, 405, 406, 407, 408, 409, 410, 411, + 412, 413, 414, 415, -1, 417, 418, -1, 420, 421, + 422, 423, 424, 425, -1, 427, 428, -1, -1, 431, + 432, 433, 434, -1, 436, 437, 438, 439, 440, 441, + 442, -1, -1, 445, 446, 447, 448, 449, -1, -1, + 452, 453, 454, 455, 456, 457, 458, -1, 460, -1, + 462, 463, 464, -1, -1, 467, -1, -1, 470, 471, + 472, 473, 474, 475, 476, 477, 478, 479, 480, 481, + 482, 483, 484, 485, 486, 6, 7, 8, 9, 10, + 11, 12, 13, -1, 15, 16, -1, -1, 19, 20, + 21, 22, 23, 24, -1, 26, 27, 28, -1, -1, + 31, 32, 33, 34, -1, -1, 37, 38, 39, 40, + -1, 42, -1, -1, 45, 46, -1, -1, -1, 50, + 51, -1, -1, -1, -1, 56, -1, -1, -1, -1, + -1, -1, -1, -1, 65, -1, 67, -1, 69, 70, + 71, -1, -1, -1, -1, -1, -1, -1, 79, 80, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 91, 92, 93, 94, 95, 96, 97, 98, -1, 100, + 101, 102, -1, -1, -1, -1, -1, -1, -1, 110, + 111, -1, 113, 114, -1, 116, 117, 118, 119, 120, + -1, 122, 123, -1, 125, 126, 127, 128, 129, -1, + -1, 132, 133, 134, 135, 136, -1, 138, 139, 140, + 141, 142, -1, -1, -1, 146, 147, 148, 149, -1, + 151, -1, -1, 154, 155, 156, 157, 158, 159, -1, + -1, 162, -1, -1, -1, -1, -1, -1, -1, -1, + 171, 172, 173, 174, 175, 176, 177, 178, 179, -1, + 181, -1, 183, 184, 185, 186, 187, -1, 189, 190, + 191, -1, -1, 194, 195, 196, 197, 198, -1, 200, + 201, 202, -1, 204, 205, -1, 207, 208, 209, 210, + 211, 212, 213, 214, 215, -1, 217, -1, 219, 220, + 221, -1, 223, -1, 225, -1, -1, -1, 229, 230, + 231, -1, 233, 234, -1, 236, -1, 238, 239, 240, + 241, 242, -1, 244, 245, 246, -1, 248, 249, 250, + 251, 252, 253, -1, 255, -1, 257, -1, 259, 260, + 261, -1, 263, -1, 265, -1, 267, -1, -1, 270, + -1, 272, 273, 274, 275, 276, 277, 278, -1, 280, + 281, -1, 283, -1, -1, 286, 287, 288, -1, -1, + 291, 292, 293, 294, 295, 296, 297, 298, 299, 300, + 301, 302, 303, -1, 305, 306, 307, 308, -1, 310, + 311, -1, 313, -1, 315, 316, 317, 318, 319, 320, + -1, 322, -1, -1, 325, 326, 327, -1, -1, 330, + -1, -1, -1, 334, 335, 336, 337, 338, 339, 340, + 341, -1, 343, 344, 345, 346, 347, 348, 349, -1, + 351, 352, 353, 354, 355, 356, 357, 358, 359, 360, + 361, 362, -1, 364, 365, 366, 367, 368, 369, 370, + 371, 372, 373, -1, 375, 376, -1, 378, 379, 380, + 381, 382, 383, 384, 385, 386, 387, 388, -1, 390, + 391, 392, 393, 394, -1, 396, 397, 398, 399, -1, + 401, 402, 403, -1, 405, 406, 407, 408, 409, 410, + 411, 412, 413, 414, 415, -1, 417, 418, -1, 420, + 421, 422, 423, 424, 425, -1, 427, 428, -1, -1, + 431, 432, 433, 434, -1, 436, 437, 438, 439, 440, + 441, 442, -1, -1, 445, 446, 447, 448, 449, -1, + -1, 452, 453, 454, 455, 456, 457, 458, -1, 460, + -1, 462, 463, 464, -1, -1, 467, -1, -1, 470, + 471, 472, 473, 474, 475, 476, 477, 478, 479, 480, + 481, 482, 483, 484, 485, 486, 6, 7, 8, 9, + 10, 11, 12, 13, -1, 15, 16, -1, -1, 19, + 20, 21, 22, 23, 24, -1, 26, 27, 28, -1, + -1, 31, 32, 33, 34, -1, -1, 37, 38, 39, + 40, -1, 42, -1, -1, 45, 46, -1, -1, -1, + 50, 51, -1, -1, -1, -1, 56, -1, -1, -1, + -1, -1, -1, -1, -1, 65, -1, 67, -1, 69, + 70, 71, -1, -1, -1, -1, -1, -1, -1, 79, + 80, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 91, 92, 93, 94, 95, 96, 97, 98, -1, + 100, 101, 102, -1, -1, -1, -1, -1, -1, -1, + 110, 111, -1, 113, 114, -1, 116, 117, 118, 119, + 120, -1, 122, 123, -1, 125, 126, 127, 128, 129, + -1, -1, 132, 133, 134, 135, 136, -1, 138, 139, + 140, 141, 142, -1, -1, -1, 146, 147, 148, 149, + -1, 151, -1, -1, 154, 155, 156, 157, 158, 159, + -1, -1, 162, -1, -1, -1, -1, -1, -1, -1, + -1, 171, 172, 173, 174, 175, 176, 177, 178, 179, + -1, 181, -1, 183, 184, 185, 186, 187, -1, 189, + 190, 191, -1, -1, 194, 195, 196, 197, 198, -1, + 200, 201, 202, -1, 204, 205, -1, 207, 208, 209, + 210, 211, 212, 213, 214, 215, -1, 217, -1, 219, + 220, 221, -1, 223, -1, 225, -1, -1, -1, 229, + 230, 231, -1, 233, 234, -1, 236, -1, 238, 239, + 240, 241, 242, -1, 244, 245, 246, -1, 248, 249, + 250, 251, 252, 253, -1, 255, -1, 257, -1, 259, + 260, 261, -1, 263, -1, 265, -1, 267, -1, -1, + 270, -1, 272, 273, 274, 275, 276, 277, 278, -1, + 280, 281, -1, 283, -1, -1, 286, 287, 288, -1, + -1, 291, 292, 293, 294, 295, 296, 297, 298, 299, + 300, 301, 302, 303, -1, 305, 306, 307, 308, -1, + 310, 311, -1, 313, -1, 315, 316, 317, 318, 319, + 320, -1, 322, -1, -1, 325, 326, 327, -1, -1, + 330, -1, -1, -1, 334, 335, 336, 337, 338, 339, + 340, 341, -1, 343, 344, 345, 346, 347, 348, 349, + -1, 351, 352, 353, 354, 355, 356, 357, 358, 359, + 360, 361, 362, -1, 364, 365, 366, 367, 368, 369, + 370, 371, 372, 373, -1, 375, 376, -1, 378, 379, + 380, 381, 382, 383, 384, 385, 386, 387, 388, -1, + 390, 391, 392, 393, 394, -1, 396, 397, 398, 399, + -1, 401, 402, 403, -1, 405, 406, 407, 408, 409, + 410, 411, 412, 413, 414, 415, -1, 417, 418, -1, + 420, 421, 422, 423, 424, 425, -1, 427, 428, -1, + -1, 431, 432, 433, 434, -1, 436, 437, 438, 439, + 440, 441, 442, -1, -1, 445, 446, 447, 448, 449, + -1, -1, 452, 453, 454, 455, 456, 457, 458, -1, + 460, -1, 462, 463, 464, -1, -1, 467, -1, -1, + 470, 471, 472, 473, 474, 475, 476, 477, 478, 479, + 480, 481, 482, 483, 484, 485, 486, 6, 7, 8, + 9, 10, 11, 12, 13, -1, 15, 16, -1, -1, + 19, 20, 21, 22, 23, 24, -1, 26, 27, 28, + -1, -1, 31, 32, 33, 34, -1, -1, 37, 38, + 39, 40, -1, 42, -1, -1, 45, 46, -1, -1, + -1, 50, 51, -1, -1, -1, -1, 56, -1, -1, + -1, -1, -1, -1, -1, -1, 65, -1, 67, -1, + 69, 70, 71, -1, -1, -1, -1, -1, -1, -1, + 79, 80, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 91, 92, 93, 94, 95, 96, 97, 98, + -1, 100, 101, 102, -1, -1, -1, -1, -1, -1, + -1, 110, 111, -1, 113, 114, -1, 116, 117, 118, + 119, 120, -1, 122, 123, -1, 125, 126, 127, 128, + 129, -1, -1, 132, 133, 134, 135, 136, -1, 138, + 139, 140, 141, 142, -1, -1, -1, 146, 147, 148, + 149, -1, 151, 152, -1, 154, 155, 156, 157, 158, + 159, -1, -1, 162, -1, -1, -1, -1, -1, -1, + -1, -1, 171, 172, 173, 174, 175, 176, 177, 178, + 179, -1, 181, -1, 183, 184, 185, 186, 187, -1, + 189, 190, 191, -1, -1, 194, 195, 196, 197, 198, + -1, 200, 201, 202, -1, 204, 205, -1, 207, 208, + 209, 210, 211, 212, 213, 214, 215, -1, 217, -1, + 219, 220, 221, -1, 223, -1, 225, -1, -1, -1, + 229, 230, 231, -1, 233, 234, -1, 236, -1, 238, + 239, 240, 241, 242, -1, 244, 245, 246, -1, 248, + 249, 250, 251, 252, 253, -1, 255, -1, 257, -1, + 259, 260, 261, -1, 263, -1, 265, -1, 267, -1, + -1, 270, -1, 272, 273, 274, 275, 276, 277, 278, + -1, 280, 281, -1, 283, -1, -1, 286, 287, 288, + -1, -1, 291, 292, 293, 294, 295, 296, 297, 298, + 299, 300, 301, 302, 303, -1, 305, 306, 307, 308, + -1, 310, 311, -1, 313, -1, 315, 316, 317, 318, + 319, 320, -1, 322, -1, -1, 325, 326, 327, -1, + -1, 330, -1, -1, -1, 334, 335, 336, 337, 338, + -1, 340, 341, -1, 343, 344, 345, 346, 347, 348, + 349, -1, 351, 352, 353, 354, 355, -1, 357, 358, + 359, 360, 361, 362, -1, 364, 365, 366, 367, 368, + 369, 370, 371, 372, 373, -1, 375, 376, -1, 378, + 379, 380, -1, 382, 383, 384, 385, 386, 387, 388, + -1, 390, 391, 392, 393, 394, -1, 396, 397, 398, + 399, -1, 401, 402, 403, -1, 405, 406, 407, 408, + 409, 410, 411, 412, 413, 414, 415, -1, 417, 418, + -1, 420, 421, 422, 423, 424, 425, -1, 427, 428, + -1, -1, 431, 432, 433, 434, -1, 436, 437, 438, + 439, 440, 441, 442, -1, -1, 445, 446, 447, 448, + 449, -1, -1, 452, 453, 454, 455, 456, 457, 458, + -1, 460, -1, 462, 463, 464, -1, -1, 467, -1, + -1, 470, 471, 472, 473, 474, 475, 476, 477, 478, + 479, 480, 481, 482, 483, 484, 485, 486, 6, 7, + 8, -1, 10, 11, 12, -1, -1, -1, 16, -1, + -1, 19, 20, 21, 22, 23, 24, -1, 26, 27, + -1, -1, -1, 31, 32, 33, 34, -1, 36, 37, + 38, 39, 40, 41, 42, 43, 44, -1, -1, -1, + -1, -1, 50, 51, -1, -1, -1, -1, 56, -1, + -1, -1, -1, -1, -1, -1, -1, 65, -1, 67, + -1, 69, 70, 71, -1, 73, -1, -1, -1, -1, + -1, 79, 80, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 115, -1, -1, + -1, 119, 120, 121, 122, 123, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 135, -1, -1, + -1, -1, -1, -1, 142, -1, 144, -1, -1, -1, + -1, -1, 150, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 161, -1, -1, -1, -1, -1, 167, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 177, + 178, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 204, -1, -1, -1, + -1, -1, -1, 211, -1, -1, -1, 215, -1, -1, + -1, -1, 220, -1, -1, -1, -1, -1, 226, -1, + 228, -1, -1, -1, -1, -1, 234, -1, -1, -1, + -1, -1, -1, -1, -1, 243, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 256, 257, + -1, -1, -1, -1, -1, 263, -1, 265, -1, -1, + 268, 269, -1, 271, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 281, 282, -1, 284, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 303, 304, 305, -1, -1, + 308, -1, -1, -1, 312, -1, -1, 315, -1, 317, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 330, 331, 332, 333, 334, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 344, -1, 346, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 358, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 377, + -1, -1, 380, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 397, + -1, -1, 400, -1, 402, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 415, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 427, + 428, -1, -1, -1, 432, -1, 434, -1, -1, -1, + -1, -1, -1, -1, -1, 443, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 458, -1, -1, 461, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 475, 476, 477, + 478, 479, 480, 481, 482, 483, 6, 7, 8, -1, + 10, 11, 12, -1, -1, -1, 16, -1, -1, 19, + 20, 21, 22, 23, 24, -1, 26, 27, -1, -1, + -1, 31, 32, 33, 34, -1, 36, 37, 38, 39, + 40, 41, 42, 43, 44, -1, -1, -1, -1, -1, + 50, 51, -1, -1, -1, -1, 56, -1, -1, -1, + -1, -1, -1, -1, -1, 65, -1, 67, -1, 69, + 70, 71, -1, 73, -1, -1, -1, -1, -1, 79, + 80, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 115, -1, -1, -1, 119, + 120, 121, 122, 123, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 135, -1, -1, -1, -1, + -1, -1, 142, -1, 144, -1, -1, -1, -1, -1, + 150, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 161, -1, -1, -1, -1, -1, 167, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 177, 178, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 204, -1, -1, -1, -1, -1, + -1, 211, -1, -1, -1, 215, -1, -1, -1, -1, + 220, -1, -1, -1, -1, -1, 226, -1, 228, -1, + -1, -1, -1, -1, 234, -1, -1, -1, -1, -1, + -1, -1, -1, 243, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 256, 257, -1, -1, + -1, -1, -1, 263, -1, 265, -1, -1, 268, 269, + -1, 271, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 281, 282, -1, 284, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 303, 304, 305, -1, -1, 308, -1, + -1, -1, 312, -1, -1, 315, -1, 317, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 330, 331, 332, 333, 334, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 344, -1, 346, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 358, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 377, -1, -1, + 380, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 397, -1, -1, + 400, -1, 402, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 415, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 427, 428, -1, + -1, -1, 432, -1, 434, -1, -1, -1, -1, -1, + -1, -1, -1, 443, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 458, -1, + -1, 461, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 475, 476, 477, 478, 479, + 480, 481, 482, 483, 6, 7, 8, -1, 10, 11, + 12, -1, -1, -1, 16, -1, -1, 19, 20, 21, + 22, 23, 24, -1, 26, 27, -1, -1, -1, 31, + 32, 33, 34, -1, 36, 37, 38, 39, 40, -1, + 42, 43, 44, -1, -1, -1, -1, -1, 50, 51, + -1, -1, -1, -1, 56, -1, -1, -1, -1, -1, + -1, -1, -1, 65, -1, 67, -1, 69, -1, 71, + -1, -1, -1, -1, -1, -1, -1, 79, 80, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 115, -1, -1, -1, 119, 120, 121, + 122, 123, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 135, -1, -1, -1, -1, -1, -1, + 142, -1, 144, -1, -1, -1, -1, -1, 150, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 161, + -1, -1, -1, -1, -1, 167, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 177, 178, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 204, -1, -1, -1, -1, -1, -1, 211, + -1, -1, -1, 215, -1, -1, -1, -1, 220, -1, + -1, -1, -1, -1, 226, -1, 228, -1, -1, -1, + -1, -1, 234, -1, -1, -1, -1, -1, -1, -1, + -1, 243, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 256, 257, -1, -1, -1, -1, + -1, 263, -1, 265, -1, -1, 268, 269, -1, 271, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 281, + 282, -1, 284, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 303, 304, 305, -1, -1, 308, -1, -1, -1, + 312, -1, -1, 315, -1, 317, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 330, 331, + 332, 333, 334, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 344, -1, 346, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 358, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 377, -1, -1, 380, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 397, -1, -1, 400, -1, + 402, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 415, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 427, 428, -1, -1, -1, + 432, -1, 434, -1, -1, -1, -1, -1, -1, -1, + -1, 443, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 458, -1, -1, 461, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 475, 476, 477, 478, 479, 480, 481, + 482, 483, 6, 7, 8, -1, 10, 11, 12, -1, + -1, -1, 16, -1, -1, 19, 20, 21, 22, 23, + 24, -1, 26, 27, -1, -1, -1, 31, 32, 33, + 34, -1, 36, 37, 38, 39, 40, -1, 42, 43, + 44, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 71, -1, -1, + -1, -1, -1, -1, -1, 79, 80, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 115, -1, -1, -1, 119, 120, 121, 122, 123, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 135, -1, -1, -1, -1, -1, -1, 142, -1, + 144, -1, -1, -1, -1, -1, 150, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 161, -1, -1, + -1, -1, -1, 167, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 177, 178, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 204, -1, -1, -1, -1, -1, -1, 211, -1, -1, + -1, 215, -1, -1, -1, -1, 220, -1, -1, -1, + -1, -1, 226, -1, 228, -1, -1, -1, -1, -1, + 234, -1, -1, -1, -1, -1, -1, -1, -1, 243, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 256, 257, -1, -1, -1, -1, -1, 263, + -1, 265, -1, -1, 268, 269, -1, 271, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 281, 282, -1, + 284, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 303, + 304, 305, -1, -1, 308, -1, -1, -1, 312, -1, + -1, 315, -1, 317, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, 330, 331, 332, 333, + 334, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 344, -1, 346, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 358, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 377, -1, -1, 380, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 397, -1, -1, 400, -1, 402, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 415, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 427, 428, -1, -1, -1, 432, -1, + 434, -1, -1, -1, -1, -1, -1, -1, -1, 443, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 458, -1, -1, 461, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 475, 476, 477, 478, 479, 480, 481, 482, 483, + 6, 7, 8, -1, 10, 11, 12, -1, -1, -1, + 16, -1, -1, 19, 20, 21, 22, 23, 24, -1, + 26, 27, -1, -1, -1, 31, 32, 33, 34, -1, + -1, 37, 38, 39, 40, -1, 42, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 71, -1, -1, -1, -1, + -1, -1, -1, 79, 80, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 115, + -1, -1, -1, 119, 120, 121, 122, 123, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 135, + -1, -1, -1, -1, -1, -1, 142, -1, 144, -1, + -1, -1, -1, -1, 150, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 161, -1, -1, -1, -1, + -1, 167, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 177, 178, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 211, -1, -1, -1, 215, + -1, -1, -1, -1, 220, -1, -1, -1, -1, -1, + 226, -1, 228, -1, -1, -1, -1, -1, 234, -1, + -1, -1, -1, -1, -1, -1, -1, 243, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 256, 257, -1, -1, -1, -1, -1, 263, -1, 265, + -1, -1, 268, 269, -1, 271, -1, -1, -1, -1, + -1, -1, -1, -1, -1, 281, 282, -1, 284, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, 303, 304, 305, + -1, -1, 308, -1, -1, -1, 312, -1, -1, 315, + -1, 317, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, 330, 331, 332, 333, 334, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 344, -1, + 346, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 358, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 377, -1, -1, 380, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 397, -1, -1, 400, -1, 402, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 415, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, 427, 428, -1, -1, -1, 432, -1, 434, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 458, -1, -1, 461, -1, -1, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 475, + 476, 477, 478, 479, 480, 481, 482, 483 +}; + +/* YYSTOS[STATE-NUM] -- The (internal number of the) accessing + symbol of state STATE-NUM. */ +static const yytype_uint16 yystos[] = +{ + 0, 512, 1048, 0, 5, 25, 35, 36, 41, 43, + 44, 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, 73, 75, 76, 77, + 78, 79, 80, 81, 82, 86, 134, 204, 220, 240, + 262, 296, 299, 314, 387, 429, 443, 458, 484, 490, + 494, 495, 496, 497, 498, 501, 502, 503, 504, 506, + 507, 508, 509, 510, 1041, 1049, 1077, 1079, 1170, 1180, + 1181, 1183, 1189, 1190, 1078, 3, 6, 7, 8, 9, + 10, 11, 12, 13, 15, 16, 17, 18, 19, 20, + 21, 22, 23, 24, 26, 27, 28, 31, 32, 33, + 34, 36, 37, 38, 39, 40, 42, 43, 44, 45, + 46, 50, 51, 56, 65, 67, 69, 70, 91, 101, + 103, 104, 113, 115, 118, 119, 120, 121, 122, 123, + 135, 138, 140, 141, 142, 144, 146, 148, 150, 158, + 160, 161, 167, 174, 176, 177, 178, 179, 191, 193, + 197, 203, 204, 210, 211, 212, 215, 218, 220, 226, + 228, 232, 234, 243, 256, 257, 263, 265, 268, 269, + 271, 281, 282, 284, 286, 287, 292, 300, 303, 304, + 305, 308, 311, 312, 315, 317, 330, 331, 332, 333, + 334, 344, 346, 348, 358, 359, 364, 366, 371, 376, + 377, 379, 380, 383, 388, 389, 396, 397, 399, 400, + 402, 407, 415, 419, 427, 428, 432, 434, 436, 438, + 443, 446, 452, 457, 458, 461, 469, 475, 476, 477, + 478, 479, 480, 481, 482, 483, 503, 513, 514, 520, + 521, 523, 524, 525, 526, 527, 528, 529, 531, 532, + 536, 547, 550, 551, 554, 555, 556, 567, 570, 571, + 586, 625, 626, 633, 639, 641, 643, 644, 647, 650, + 651, 655, 656, 665, 669, 670, 671, 675, 676, 678, + 679, 680, 693, 694, 695, 696, 707, 708, 715, 716, + 719, 720, 721, 722, 723, 728, 730, 733, 737, 741, + 742, 752, 753, 756, 761, 772, 791, 794, 795, 796, + 799, 802, 804, 806, 809, 812, 813, 814, 821, 822, + 824, 825, 826, 831, 833, 834, 838, 839, 842, 843, + 844, 846, 847, 848, 849, 851, 854, 855, 860, 866, + 869, 871, 876, 878, 882, 889, 893, 894, 895, 896, + 897, 898, 901, 928, 1045, 1046, 1050, 1052, 1053, 1070, + 1071, 1072, 1073, 1084, 1086, 1090, 1091, 1092, 1093, 1094, + 1096, 1098, 1100, 1101, 1102, 1103, 1105, 1110, 1111, 1115, + 1116, 1125, 1127, 1128, 1129, 1132, 1137, 1140, 1145, 1147, + 1148, 1151, 1153, 1156, 1165, 1183, 1191, 73, 1073, 1081, + 1082, 14, 9, 13, 15, 28, 45, 46, 50, 51, + 56, 65, 67, 69, 70, 72, 91, 92, 93, 94, + 95, 96, 97, 98, 100, 101, 102, 110, 111, 113, + 114, 116, 117, 118, 125, 126, 127, 128, 129, 132, + 133, 134, 136, 138, 139, 140, 141, 146, 147, 148, + 149, 151, 152, 154, 155, 156, 157, 158, 159, 162, + 171, 172, 173, 174, 175, 176, 179, 181, 183, 184, + 185, 186, 187, 189, 190, 191, 194, 195, 196, 197, + 198, 200, 201, 202, 204, 205, 207, 208, 209, 210, + 212, 213, 214, 217, 219, 221, 223, 225, 229, 230, + 231, 233, 236, 238, 239, 240, 241, 242, 244, 245, + 246, 248, 249, 250, 251, 252, 253, 255, 259, 260, + 261, 267, 270, 272, 273, 274, 275, 276, 277, 278, + 280, 283, 286, 287, 288, 291, 292, 293, 294, 295, + 296, 297, 298, 299, 300, 301, 302, 306, 307, 310, + 311, 313, 316, 318, 319, 320, 322, 325, 326, 327, + 335, 336, 337, 338, 339, 340, 341, 343, 345, 347, + 348, 349, 351, 352, 353, 354, 355, 356, 357, 359, + 360, 361, 362, 364, 365, 366, 367, 368, 369, 370, + 371, 372, 373, 375, 376, 378, 379, 381, 382, 383, + 384, 385, 386, 387, 388, 390, 391, 392, 393, 394, + 396, 398, 399, 401, 403, 405, 406, 407, 408, 409, + 410, 411, 412, 413, 414, 417, 418, 420, 421, 422, + 423, 424, 425, 429, 431, 433, 436, 437, 438, 439, + 440, 441, 442, 445, 446, 447, 448, 449, 452, 453, + 454, 455, 456, 457, 460, 462, 463, 464, 467, 470, + 471, 472, 473, 474, 484, 485, 486, 1042, 1044, 1045, + 1063, 1064, 1155, 1156, 1157, 1161, 1166, 1167, 1168, 1175, + 1177, 1181, 1183, 29, 258, 1126, 99, 163, 180, 1034, + 1065, 1112, 1113, 1161, 1177, 99, 890, 1033, 1065, 1161, + 1174, 14, 890, 5, 25, 29, 35, 36, 43, 44, + 99, 103, 104, 105, 106, 107, 108, 109, 112, 124, + 130, 131, 134, 137, 143, 145, 152, 153, 160, 163, + 164, 165, 166, 168, 169, 170, 180, 182, 188, 192, + 193, 199, 203, 206, 216, 218, 222, 224, 227, 232, + 235, 237, 247, 254, 258, 262, 264, 266, 279, 285, + 289, 290, 309, 314, 321, 323, 324, 328, 329, 342, + 350, 363, 374, 389, 395, 404, 416, 419, 426, 429, + 430, 435, 443, 444, 450, 451, 457, 459, 465, 466, + 468, 469, 1044, 1047, 1157, 1158, 1159, 1163, 1164, 1165, + 1166, 1168, 25, 35, 134, 262, 1152, 38, 40, 309, + 1085, 431, 471, 827, 98, 144, 157, 174, 180, 195, + 213, 224, 229, 235, 250, 275, 325, 353, 378, 384, + 390, 393, 419, 421, 425, 433, 438, 450, 463, 640, + 1113, 179, 827, 99, 890, 461, 856, 323, 349, 827, + 121, 577, 894, 98, 110, 131, 144, 153, 174, 180, + 195, 213, 224, 231, 235, 288, 325, 328, 378, 384, + 393, 421, 422, 424, 425, 433, 438, 444, 447, 450, + 587, 711, 762, 773, 1034, 1054, 1055, 1056, 1065, 1181, + 1183, 14, 99, 348, 1033, 1065, 1069, 408, 890, 99, + 343, 422, 424, 274, 800, 801, 1181, 98, 110, 131, + 144, 157, 174, 195, 213, 224, 229, 235, 250, 325, + 335, 378, 382, 384, 390, 393, 419, 421, 425, 433, + 438, 450, 463, 640, 724, 827, 509, 1095, 1159, 244, + 1069, 160, 179, 210, 461, 503, 855, 861, 869, 871, + 876, 882, 889, 893, 1050, 92, 99, 116, 219, 225, + 227, 247, 276, 306, 351, 365, 494, 495, 738, 739, + 890, 1041, 1043, 1175, 1177, 99, 160, 363, 389, 743, + 744, 745, 1161, 1161, 1038, 1181, 419, 904, 116, 225, + 738, 1161, 431, 1069, 335, 174, 250, 418, 419, 807, + 383, 1161, 99, 134, 394, 427, 431, 457, 539, 1044, + 1045, 1155, 1160, 1166, 1168, 1183, 96, 232, 743, 744, + 349, 827, 1161, 273, 99, 192, 906, 4, 14, 132, + 152, 154, 288, 302, 378, 384, 394, 427, 431, 474, + 537, 538, 539, 99, 394, 427, 431, 539, 431, 324, + 937, 1031, 1161, 904, 1149, 1159, 496, 1161, 228, 503, + 857, 503, 1027, 361, 899, 900, 1033, 894, 895, 898, + 507, 856, 206, 264, 329, 443, 907, 908, 894, 896, + 897, 185, 260, 449, 506, 118, 513, 1093, 1096, 1092, + 1088, 507, 1097, 1099, 5, 25, 35, 134, 196, 262, + 1104, 175, 240, 296, 299, 387, 484, 503, 968, 969, + 1076, 1080, 1170, 73, 1073, 1033, 1065, 1184, 180, 1054, + 21, 451, 497, 1069, 1069, 1184, 451, 1117, 1118, 1119, + 25, 262, 262, 1163, 7, 19, 20, 39, 42, 156, + 193, 1154, 1154, 16, 1093, 1039, 1046, 1155, 1158, 1161, + 1162, 1166, 1167, 1183, 726, 1161, 726, 1034, 352, 726, + 726, 1033, 1161, 173, 419, 751, 1039, 1042, 242, 1031, + 318, 85, 139, 217, 490, 491, 492, 494, 495, 496, + 497, 498, 499, 798, 994, 995, 1161, 1042, 1033, 242, + 1031, 1033, 242, 937, 1033, 386, 1033, 726, 293, 1042, + 242, 1031, 274, 34, 182, 270, 309, 357, 828, 829, + 830, 1031, 1037, 1161, 98, 131, 144, 145, 153, 157, + 174, 195, 213, 224, 229, 250, 275, 325, 378, 382, + 384, 390, 393, 419, 421, 425, 433, 438, 463, 640, + 731, 1181, 1031, 429, 1039, 1033, 503, 726, 433, 1034, + 726, 242, 1033, 173, 419, 422, 424, 1042, 422, 424, + 139, 217, 798, 369, 1042, 533, 1161, 1033, 1033, 386, + 1033, 726, 293, 1042, 390, 419, 463, 157, 250, 229, + 382, 437, 634, 85, 1057, 1058, 508, 1177, 1184, 99, + 1069, 1183, 891, 546, 1161, 1181, 801, 242, 1039, 1033, + 242, 805, 242, 1034, 173, 419, 242, 1039, 242, 1032, + 1033, 150, 139, 217, 242, 798, 125, 242, 1032, 242, + 1033, 242, 1033, 242, 1033, 386, 242, 1033, 242, 293, + 1032, 274, 242, 725, 726, 503, 509, 1185, 1186, 1187, + 1188, 1190, 1095, 71, 1065, 1114, 503, 870, 587, 890, + 861, 457, 461, 855, 862, 863, 864, 1161, 856, 1043, + 739, 740, 99, 739, 890, 1043, 740, 99, 739, 890, + 1043, 740, 740, 740, 1043, 1041, 1041, 266, 451, 1119, + 1120, 1194, 1195, 890, 740, 352, 503, 503, 606, 606, + 606, 323, 429, 506, 606, 937, 938, 739, 890, 739, + 890, 506, 823, 1181, 227, 503, 867, 125, 1033, 1033, + 1031, 1161, 115, 486, 270, 505, 326, 326, 323, 227, + 1181, 429, 222, 734, 323, 83, 84, 85, 87, 107, + 120, 122, 123, 130, 131, 134, 135, 142, 144, 164, + 165, 166, 167, 168, 169, 170, 177, 178, 196, 211, + 215, 216, 220, 234, 262, 263, 265, 281, 289, 290, + 303, 305, 309, 314, 315, 317, 325, 334, 344, 358, + 380, 395, 402, 415, 427, 428, 432, 434, 435, 444, + 450, 458, 476, 477, 478, 479, 480, 481, 482, 483, + 494, 495, 496, 503, 894, 949, 952, 955, 956, 957, + 959, 960, 961, 962, 965, 966, 970, 972, 973, 992, + 996, 1015, 1020, 1028, 1029, 1039, 1040, 1041, 1161, 1173, + 1175, 1177, 1178, 1179, 1180, 1181, 429, 490, 1184, 1181, + 429, 490, 1113, 99, 552, 1030, 1031, 394, 537, 180, + 545, 1181, 546, 1181, 115, 136, 537, 486, 403, 829, + 326, 227, 429, 490, 115, 486, 270, 1194, 830, 503, + 1031, 496, 501, 505, 1021, 1022, 938, 1165, 226, 228, + 461, 852, 853, 855, 226, 858, 180, 970, 1025, 1026, + 899, 506, 503, 859, 504, 504, 1031, 99, 192, 905, + 905, 125, 905, 218, 222, 285, 321, 911, 913, 914, + 923, 925, 926, 907, 908, 227, 266, 937, 939, 1027, + 507, 1087, 496, 1106, 1107, 1109, 509, 509, 25, 262, + 262, 429, 429, 429, 429, 503, 429, 495, 631, 1043, + 1074, 1180, 203, 108, 1061, 125, 1064, 1064, 266, 1119, + 1121, 266, 1119, 1120, 1121, 456, 1130, 1131, 1177, 14, + 37, 84, 494, 495, 1041, 1122, 1123, 1124, 1173, 1175, + 1179, 1180, 1181, 1182, 262, 268, 1033, 429, 1033, 6, + 1033, 1154, 1109, 503, 701, 1022, 336, 367, 396, 505, + 727, 336, 367, 396, 336, 367, 396, 469, 515, 547, + 548, 757, 95, 197, 336, 367, 396, 454, 559, 396, + 95, 197, 449, 530, 472, 242, 937, 127, 159, 214, + 245, 280, 309, 336, 367, 375, 381, 388, 396, 405, + 413, 464, 547, 549, 785, 792, 503, 774, 367, 530, + 211, 95, 101, 141, 190, 197, 200, 252, 307, 309, + 319, 327, 336, 367, 371, 396, 454, 557, 558, 659, + 631, 726, 726, 503, 797, 505, 247, 367, 515, 522, + 336, 367, 211, 126, 172, 249, 295, 297, 307, 335, + 367, 372, 396, 407, 557, 628, 629, 336, 367, 462, + 659, 667, 211, 367, 396, 557, 336, 367, 371, 396, + 151, 189, 337, 423, 323, 95, 101, 197, 336, 367, + 396, 568, 569, 222, 367, 396, 515, 548, 211, 367, + 396, 557, 1033, 507, 283, 182, 324, 473, 506, 828, + 451, 850, 323, 1039, 503, 1033, 173, 419, 1039, 318, + 139, 217, 798, 1033, 386, 1033, 274, 726, 606, 410, + 411, 573, 1181, 503, 701, 702, 137, 120, 122, 123, + 134, 135, 177, 178, 220, 263, 265, 303, 305, 317, + 358, 397, 402, 427, 428, 458, 946, 948, 950, 952, + 954, 956, 957, 958, 960, 961, 965, 966, 1155, 1162, + 1166, 1167, 1183, 227, 503, 697, 1033, 515, 108, 845, + 309, 515, 472, 242, 1031, 515, 726, 726, 697, 587, + 515, 115, 534, 438, 666, 336, 642, 151, 189, 337, + 423, 97, 117, 261, 681, 108, 697, 222, 515, 1031, + 242, 623, 1031, 1031, 726, 150, 763, 1039, 1033, 640, + 74, 1059, 1161, 508, 1060, 1057, 121, 171, 259, 307, + 385, 211, 701, 128, 373, 560, 211, 503, 211, 472, + 211, 774, 211, 506, 242, 725, 242, 726, 242, 726, + 211, 797, 1032, 211, 211, 323, 211, 560, 211, 151, + 189, 337, 423, 211, 323, 211, 222, 242, 242, 546, + 211, 506, 560, 504, 1186, 1187, 1185, 506, 510, 970, + 999, 1118, 1193, 1194, 419, 891, 504, 506, 216, 323, + 435, 543, 546, 631, 865, 861, 740, 890, 740, 890, + 1195, 1196, 740, 890, 740, 890, 1196, 740, 890, 890, + 890, 740, 14, 37, 1169, 1172, 1177, 890, 503, 607, + 608, 1161, 607, 99, 174, 195, 224, 229, 274, 275, + 384, 390, 419, 421, 438, 746, 1030, 1032, 745, 247, + 506, 879, 890, 890, 1181, 1114, 946, 1002, 108, 1032, + 223, 808, 808, 808, 283, 1161, 222, 222, 746, 1032, + 383, 1161, 546, 323, 503, 501, 894, 1003, 460, 963, + 970, 1019, 503, 963, 963, 503, 222, 503, 503, 503, + 951, 951, 346, 894, 503, 503, 953, 503, 503, 503, + 503, 134, 135, 963, 970, 503, 951, 503, 503, 503, + 503, 503, 470, 489, 503, 967, 503, 967, 503, 503, + 894, 503, 503, 503, 503, 503, 503, 503, 503, 970, + 970, 894, 970, 999, 1181, 135, 503, 964, 503, 1181, + 85, 88, 105, 108, 113, 119, 143, 243, 247, 268, + 269, 284, 309, 312, 325, 328, 400, 490, 491, 492, + 494, 495, 496, 497, 498, 499, 994, 996, 998, 1183, + 333, 970, 266, 506, 902, 1194, 503, 1181, 1022, 22, + 1176, 1177, 1023, 320, 323, 1146, 1146, 10, 456, 1133, + 1134, 1136, 1113, 1113, 183, 244, 553, 506, 136, 180, + 546, 108, 180, 288, 544, 631, 966, 1181, 1183, 1181, + 155, 194, 979, 163, 180, 540, 541, 543, 631, 180, + 540, 1194, 1194, 283, 1031, 970, 496, 1036, 1163, 1021, + 156, 372, 729, 268, 504, 506, 856, 504, 506, 900, + 1032, 108, 859, 896, 896, 909, 910, 970, 896, 219, + 306, 920, 357, 398, 449, 99, 915, 970, 916, 918, + 970, 972, 923, 924, 914, 913, 911, 912, 222, 926, + 911, 923, 939, 1031, 108, 1161, 396, 1106, 496, 506, + 507, 1164, 1083, 1086, 1083, 262, 175, 240, 296, 969, + 296, 969, 969, 299, 1041, 296, 299, 387, 1180, 506, + 1075, 179, 1113, 450, 1062, 1064, 1033, 37, 1041, 1135, + 1177, 506, 490, 1033, 14, 1041, 1180, 1041, 1180, 506, + 1093, 503, 1033, 503, 1165, 496, 1002, 336, 367, 396, + 429, 429, 384, 1036, 505, 429, 429, 384, 429, 429, + 421, 537, 840, 222, 232, 247, 376, 758, 759, 137, + 153, 207, 224, 350, 444, 603, 604, 153, 180, 309, + 429, 153, 429, 180, 309, 384, 153, 384, 648, 98, + 131, 144, 157, 195, 224, 229, 325, 384, 390, 393, + 419, 425, 438, 463, 640, 1033, 211, 367, 396, 557, + 323, 631, 388, 280, 429, 429, 314, 631, 184, 267, + 384, 394, 431, 538, 373, 396, 785, 793, 247, 257, + 330, 397, 459, 504, 775, 778, 779, 780, 782, 946, + 1162, 429, 450, 1031, 145, 207, 594, 603, 1161, 145, + 810, 323, 382, 433, 153, 810, 102, 370, 382, 433, + 1031, 252, 319, 726, 503, 429, 429, 503, 563, 421, + 469, 470, 563, 153, 506, 336, 451, 451, 308, 946, + 336, 396, 798, 174, 429, 517, 548, 429, 429, 1031, + 631, 125, 630, 631, 631, 172, 295, 297, 125, 429, + 515, 384, 515, 307, 629, 429, 429, 314, 1181, 659, + 937, 153, 429, 810, 384, 429, 429, 563, 563, 726, + 726, 726, 726, 1031, 114, 456, 114, 114, 429, 114, + 429, 384, 506, 170, 450, 677, 1042, 429, 517, 1031, + 429, 384, 336, 367, 357, 368, 392, 542, 828, 1037, + 1161, 1031, 701, 946, 323, 472, 774, 631, 726, 726, + 797, 268, 323, 151, 189, 337, 423, 323, 726, 268, + 469, 578, 515, 703, 704, 1183, 697, 503, 948, 108, + 107, 947, 175, 299, 484, 503, 968, 727, 951, 726, + 698, 699, 1163, 97, 835, 946, 211, 645, 1033, 309, + 503, 672, 516, 711, 451, 463, 516, 1042, 160, 232, + 535, 586, 625, 680, 741, 761, 831, 1181, 667, 668, + 1033, 291, 726, 726, 726, 726, 319, 185, 260, 436, + 449, 682, 683, 204, 356, 503, 677, 516, 627, 628, + 309, 108, 319, 503, 606, 606, 222, 764, 1037, 503, + 776, 108, 274, 505, 1041, 1060, 469, 470, 892, 385, + 1039, 560, 946, 1034, 242, 1033, 1039, 560, 1032, 1033, + 211, 560, 211, 451, 211, 451, 798, 560, 560, 1032, + 1033, 726, 1033, 1033, 1033, 726, 1032, 677, 211, 211, + 560, 725, 726, 504, 510, 1188, 504, 506, 1194, 1118, + 1031, 171, 861, 863, 890, 890, 1196, 890, 890, 1196, + 890, 890, 1033, 14, 506, 1176, 607, 504, 506, 504, + 230, 391, 420, 1032, 725, 173, 393, 750, 751, 1032, + 318, 1032, 1030, 1030, 1032, 725, 429, 469, 754, 93, + 209, 380, 398, 880, 937, 313, 881, 504, 506, 868, + 871, 876, 882, 893, 429, 744, 743, 744, 227, 233, + 755, 1161, 98, 145, 174, 195, 224, 229, 275, 378, + 384, 390, 419, 421, 438, 463, 640, 735, 999, 502, + 999, 1003, 1004, 503, 465, 1016, 1017, 970, 999, 503, + 1041, 1041, 999, 175, 240, 296, 299, 387, 484, 1005, + 1006, 1181, 1183, 1041, 999, 999, 1041, 1041, 963, 963, + 970, 798, 970, 1007, 494, 495, 971, 972, 992, 996, + 1009, 504, 999, 970, 999, 1010, 427, 486, 1041, 1041, + 970, 124, 227, 279, 430, 970, 999, 1013, 999, 301, + 972, 970, 977, 978, 979, 301, 970, 979, 504, 506, + 396, 1041, 1041, 968, 946, 970, 1163, 427, 112, 416, + 1024, 726, 970, 503, 894, 1014, 192, 194, 216, 309, + 314, 319, 435, 445, 970, 119, 243, 247, 284, 400, + 503, 970, 429, 970, 970, 970, 970, 970, 970, 970, + 970, 970, 970, 99, 106, 404, 993, 380, 503, 992, + 231, 288, 419, 422, 424, 447, 903, 1031, 1029, 227, + 929, 99, 192, 459, 496, 504, 780, 970, 1000, 1001, + 1162, 1033, 1177, 1021, 1135, 506, 490, 1031, 431, 503, + 1181, 506, 1194, 504, 502, 508, 241, 241, 560, 1093, + 1031, 853, 854, 1031, 1025, 504, 503, 506, 109, 188, + 451, 770, 503, 917, 1043, 324, 319, 927, 927, 506, + 380, 381, 919, 924, 912, 451, 877, 180, 503, 872, + 893, 1161, 503, 883, 884, 885, 886, 887, 1161, 507, + 1107, 947, 510, 1086, 510, 504, 631, 504, 34, 1063, + 1138, 1139, 1177, 1131, 1136, 1184, 1122, 947, 1171, 1187, + 1171, 947, 504, 504, 429, 429, 384, 1042, 1033, 1033, + 1036, 1042, 1033, 1033, 1042, 1034, 1033, 152, 841, 378, + 450, 743, 384, 232, 743, 503, 1033, 451, 765, 272, + 272, 451, 503, 622, 242, 1033, 314, 1042, 1033, 1033, + 970, 314, 1033, 1033, 1033, 429, 649, 1039, 503, 726, + 726, 726, 173, 419, 751, 139, 217, 798, 1033, 726, + 1033, 726, 386, 726, 726, 274, 236, 307, 336, 367, + 455, 652, 653, 654, 937, 429, 810, 384, 314, 184, + 267, 1042, 1033, 323, 1033, 330, 1162, 504, 506, 780, + 782, 779, 782, 1162, 727, 1042, 1032, 367, 557, 594, + 946, 1161, 1033, 1033, 99, 450, 1033, 242, 1033, 242, + 1161, 382, 433, 382, 433, 1033, 99, 450, 1033, 1031, + 95, 197, 396, 660, 661, 662, 663, 1163, 1042, 1033, + 565, 566, 1163, 1033, 322, 141, 322, 1033, 558, 429, + 1035, 1161, 1035, 506, 504, 506, 429, 384, 1034, 1042, + 152, 202, 252, 341, 442, 450, 453, 518, 1183, 1042, + 1033, 367, 396, 557, 628, 631, 726, 1033, 631, 1033, + 631, 1042, 1033, 367, 396, 557, 1033, 1033, 1033, 1033, + 1042, 1033, 95, 101, 197, 336, 367, 396, 336, 367, + 396, 697, 367, 396, 367, 396, 367, 945, 1161, 1181, + 1161, 242, 1161, 1042, 1033, 1033, 1033, 95, 569, 393, + 1042, 367, 396, 557, 1033, 1033, 429, 429, 149, 441, + 357, 268, 108, 726, 268, 268, 451, 451, 268, 314, + 732, 1181, 726, 726, 726, 726, 726, 726, 268, 732, + 322, 227, 429, 572, 503, 574, 575, 504, 506, 490, + 970, 107, 947, 946, 501, 501, 429, 429, 1041, 951, + 504, 506, 490, 682, 152, 201, 277, 278, 291, 336, + 421, 423, 836, 596, 1033, 227, 384, 462, 646, 653, + 654, 211, 504, 594, 673, 674, 393, 96, 247, 378, + 417, 518, 519, 222, 1035, 1031, 534, 328, 587, 224, + 1181, 697, 697, 697, 697, 319, 323, 328, 503, 697, + 943, 944, 945, 393, 211, 210, 1051, 726, 284, 588, + 590, 592, 594, 600, 603, 1161, 469, 470, 618, 469, + 564, 1181, 323, 504, 777, 778, 783, 108, 274, 375, + 468, 784, 785, 786, 323, 546, 1059, 497, 239, 239, + 222, 701, 108, 211, 560, 774, 725, 726, 1035, 726, + 1035, 797, 323, 560, 560, 323, 560, 393, 222, 546, + 560, 970, 892, 1184, 1172, 504, 608, 247, 247, 247, + 472, 1032, 506, 631, 632, 235, 747, 748, 1042, 96, + 755, 209, 398, 209, 398, 380, 449, 298, 946, 1033, + 227, 323, 747, 125, 560, 1039, 419, 1039, 318, 274, + 726, 504, 502, 502, 506, 999, 970, 199, 1017, 1018, + 108, 504, 970, 504, 504, 504, 504, 227, 504, 504, + 504, 504, 504, 506, 504, 342, 1008, 504, 971, 971, + 88, 247, 268, 325, 490, 491, 492, 494, 495, 496, + 497, 498, 499, 996, 971, 504, 504, 222, 227, 1011, + 1012, 504, 486, 504, 504, 108, 1013, 999, 1013, 1013, + 227, 504, 504, 1163, 340, 981, 108, 504, 506, 970, + 1163, 506, 970, 1023, 970, 1161, 504, 504, 486, 971, + 971, 205, 999, 227, 192, 194, 216, 314, 319, 435, + 445, 503, 205, 416, 1024, 970, 1014, 970, 429, 798, + 970, 503, 894, 422, 424, 422, 424, 1031, 904, 904, + 904, 503, 894, 930, 931, 932, 937, 940, 973, 1039, + 1161, 466, 941, 1000, 1000, 1001, 504, 332, 985, 90, + 504, 506, 908, 8, 11, 12, 22, 23, 24, 26, + 27, 31, 32, 33, 173, 301, 346, 438, 1141, 1142, + 1144, 1134, 1135, 829, 1041, 968, 541, 970, 947, 859, + 868, 910, 325, 994, 997, 487, 488, 771, 970, 919, + 1030, 881, 881, 916, 930, 466, 942, 457, 873, 874, + 1161, 374, 875, 887, 888, 506, 929, 490, 1023, 508, + 1089, 507, 506, 490, 30, 1150, 504, 504, 507, 1042, + 1033, 1033, 285, 1032, 1032, 323, 1032, 326, 323, 970, + 604, 1035, 503, 503, 503, 622, 250, 607, 691, 211, + 560, 429, 546, 701, 946, 472, 726, 726, 726, 797, + 151, 189, 337, 423, 1033, 635, 1033, 236, 455, 429, + 429, 635, 652, 659, 367, 396, 557, 1033, 1033, 1033, + 258, 314, 727, 778, 782, 782, 498, 429, 327, 657, + 197, 371, 396, 559, 659, 811, 211, 560, 211, 560, + 1033, 1033, 1033, 1033, 662, 663, 662, 504, 506, 664, + 1181, 504, 506, 490, 505, 1042, 336, 367, 396, 95, + 197, 336, 367, 396, 946, 308, 946, 1042, 1033, 285, + 341, 314, 1181, 341, 1032, 448, 429, 384, 429, 810, + 384, 429, 429, 293, 293, 293, 429, 429, 384, 429, + 429, 384, 429, 384, 429, 384, 429, 560, 946, 97, + 117, 396, 811, 211, 560, 429, 1033, 429, 384, 1042, + 1033, 732, 946, 268, 732, 732, 1035, 1035, 732, 268, + 268, 268, 268, 268, 268, 732, 573, 581, 582, 1163, + 121, 162, 186, 201, 205, 223, 238, 314, 322, 355, + 576, 704, 1183, 325, 494, 495, 631, 700, 782, 997, + 1047, 1181, 504, 501, 504, 1041, 502, 503, 1041, 1161, + 1181, 1192, 504, 699, 700, 323, 285, 490, 837, 837, + 837, 837, 837, 837, 837, 137, 143, 153, 180, 182, + 254, 309, 314, 350, 363, 444, 597, 598, 599, 515, + 546, 1033, 546, 657, 1031, 504, 506, 1033, 1032, 235, + 378, 1032, 1041, 438, 606, 369, 419, 173, 607, 1031, + 683, 705, 706, 1181, 504, 506, 1033, 1031, 1033, 893, + 503, 589, 1031, 504, 506, 322, 563, 322, 323, 619, + 563, 108, 429, 1031, 504, 506, 180, 490, 787, 1181, + 546, 419, 781, 782, 469, 786, 788, 185, 260, 389, + 449, 819, 236, 1055, 893, 1069, 560, 946, 1033, 560, + 560, 451, 560, 451, 560, 560, 726, 726, 1033, 677, + 560, 222, 384, 384, 384, 1032, 751, 506, 1042, 469, + 506, 749, 326, 209, 209, 1032, 746, 560, 1042, 701, + 774, 631, 726, 268, 1003, 504, 426, 970, 203, 946, + 504, 970, 970, 970, 1011, 946, 971, 192, 194, 309, + 319, 971, 971, 971, 971, 971, 971, 971, 971, 971, + 971, 970, 970, 1012, 1011, 967, 967, 946, 504, 504, + 504, 999, 504, 506, 125, 972, 504, 1163, 978, 347, + 414, 980, 504, 506, 462, 974, 108, 504, 964, 1181, + 970, 105, 105, 970, 504, 970, 227, 503, 1002, 970, + 971, 971, 205, 205, 970, 504, 205, 970, 904, 904, + 904, 904, 1031, 1031, 1031, 894, 931, 932, 108, 933, + 1161, 506, 161, 228, 256, 271, 282, 304, 377, 934, + 933, 108, 933, 1161, 503, 1022, 970, 235, 921, 506, + 907, 908, 907, 504, 985, 503, 986, 1161, 970, 985, + 1181, 459, 1001, 504, 506, 490, 504, 502, 1150, 504, + 503, 771, 504, 324, 163, 970, 875, 504, 506, 1023, + 1028, 504, 506, 884, 942, 1025, 1041, 490, 1108, 1139, + 1144, 837, 230, 391, 420, 439, 760, 222, 760, 504, + 503, 610, 611, 767, 973, 1161, 607, 607, 691, 1037, + 504, 182, 254, 307, 309, 692, 1033, 1033, 108, 1033, + 451, 451, 726, 726, 726, 726, 727, 1042, 1033, 429, + 810, 384, 429, 258, 498, 438, 1033, 503, 596, 309, + 563, 173, 309, 409, 412, 563, 438, 1033, 1161, 661, + 566, 700, 1163, 429, 429, 384, 229, 325, 412, 709, + 710, 229, 325, 717, 718, 429, 429, 384, 504, 504, + 504, 1043, 1181, 1181, 1181, 1033, 1033, 1033, 1033, 1033, + 1033, 1033, 222, 222, 369, 222, 242, 1042, 1033, 1033, + 1042, 1033, 1033, 1033, 1033, 1033, 1033, 1033, 143, 561, + 1181, 1181, 438, 1161, 1033, 659, 1033, 1033, 504, 732, + 268, 268, 732, 732, 732, 732, 732, 732, 451, 579, + 580, 504, 506, 496, 503, 543, 583, 631, 845, 1181, + 845, 309, 355, 845, 845, 691, 1041, 469, 470, 502, + 1192, 494, 495, 496, 497, 498, 502, 968, 1031, 837, + 180, 1041, 1181, 180, 1181, 180, 1181, 180, 1181, 180, + 1033, 180, 1033, 180, 1033, 503, 726, 1033, 971, 183, + 244, 182, 314, 272, 1031, 788, 645, 672, 674, 657, + 1032, 1032, 946, 564, 1031, 472, 222, 684, 504, 506, + 945, 657, 319, 503, 870, 469, 624, 591, 593, 595, + 603, 1161, 618, 601, 253, 617, 592, 148, 421, 620, + 893, 1181, 765, 783, 970, 970, 506, 503, 784, 697, + 429, 635, 85, 1066, 504, 560, 1035, 1035, 560, 560, + 393, 1032, 1032, 1032, 631, 232, 748, 755, 227, 268, + 268, 268, 268, 314, 736, 1181, 970, 504, 504, 1012, + 227, 192, 194, 319, 503, 504, 475, 976, 999, 362, + 125, 467, 467, 504, 970, 307, 970, 506, 975, 948, + 968, 971, 971, 970, 1002, 504, 105, 105, 970, 970, + 205, 970, 504, 1031, 1031, 1031, 1031, 504, 1161, 503, + 931, 271, 331, 935, 931, 935, 271, 934, 935, 271, + 503, 1161, 503, 1000, 125, 237, 922, 504, 504, 985, + 987, 1161, 1001, 985, 1142, 495, 1135, 1143, 1180, 1181, + 1181, 798, 319, 893, 874, 1194, 490, 887, 875, 1188, + 1043, 429, 743, 227, 691, 970, 504, 506, 469, 143, + 768, 768, 504, 504, 788, 183, 244, 252, 182, 453, + 560, 946, 1035, 1035, 1033, 1033, 1033, 1033, 438, 658, + 662, 314, 314, 1043, 1161, 946, 560, 560, 490, 1042, + 1033, 1033, 1041, 1041, 946, 506, 1041, 1041, 506, 1042, + 1033, 1033, 429, 1032, 1032, 726, 1032, 211, 726, 946, + 560, 560, 268, 732, 732, 515, 187, 582, 543, 584, + 585, 1181, 1181, 314, 496, 607, 1181, 1181, 502, 229, + 257, 229, 504, 1192, 1192, 1192, 1192, 1192, 227, 690, + 1043, 970, 309, 598, 788, 606, 451, 621, 393, 451, + 108, 503, 1033, 198, 685, 465, 687, 1181, 726, 588, + 624, 173, 307, 504, 506, 469, 619, 208, 248, 503, + 618, 185, 197, 347, 1033, 469, 832, 227, 503, 1181, + 780, 789, 790, 1162, 788, 1031, 255, 636, 1067, 1161, + 560, 560, 560, 1033, 326, 560, 747, 736, 736, 736, + 736, 971, 227, 503, 1002, 503, 504, 506, 504, 972, + 362, 504, 456, 406, 504, 504, 504, 971, 971, 970, + 933, 503, 1032, 931, 323, 451, 936, 931, 271, 931, + 944, 503, 944, 1161, 504, 999, 970, 468, 982, 985, + 985, 339, 988, 504, 1041, 1180, 968, 504, 890, 1027, + 747, 323, 747, 504, 788, 611, 325, 798, 726, 451, + 726, 769, 769, 363, 788, 621, 504, 429, 504, 506, + 561, 700, 503, 1039, 798, 710, 503, 503, 718, 1033, + 469, 369, 469, 469, 222, 561, 732, 574, 1181, 504, + 506, 607, 751, 108, 803, 803, 1031, 691, 504, 621, + 294, 609, 250, 1033, 1035, 893, 657, 380, 408, 686, + 503, 210, 589, 504, 173, 593, 327, 620, 99, 147, + 154, 181, 251, 412, 602, 602, 1030, 619, 381, 381, + 129, 137, 288, 726, 766, 767, 782, 504, 506, 941, + 635, 307, 455, 637, 638, 490, 1068, 560, 971, 1002, + 504, 977, 999, 125, 307, 485, 1032, 504, 970, 503, + 931, 936, 504, 944, 504, 983, 984, 1161, 125, 907, + 985, 749, 760, 560, 768, 621, 503, 726, 770, 770, + 1031, 621, 691, 1033, 662, 451, 562, 1002, 774, 222, + 713, 797, 1002, 1002, 725, 726, 725, 726, 1032, 560, + 585, 803, 111, 246, 222, 307, 605, 228, 338, 401, + 323, 613, 614, 615, 421, 657, 217, 712, 832, 970, + 354, 618, 617, 596, 504, 620, 137, 326, 137, 504, + 506, 784, 789, 193, 455, 635, 1041, 1175, 1183, 85, + 504, 504, 504, 362, 456, 504, 1032, 504, 506, 108, + 999, 356, 381, 989, 227, 769, 466, 612, 798, 771, + 771, 606, 691, 970, 504, 329, 386, 360, 714, 713, + 504, 504, 469, 198, 252, 185, 449, 323, 615, 323, + 614, 1033, 726, 108, 504, 1039, 619, 618, 326, 326, + 564, 767, 788, 100, 261, 820, 1067, 504, 984, 986, + 119, 163, 440, 970, 990, 991, 990, 504, 747, 770, + 503, 691, 504, 609, 1039, 125, 714, 726, 380, 128, + 307, 373, 396, 616, 616, 709, 503, 620, 619, 620, + 310, 503, 815, 817, 822, 871, 876, 882, 893, 991, + 380, 221, 345, 221, 345, 560, 771, 970, 613, 774, + 726, 687, 94, 180, 314, 688, 689, 1041, 1163, 1180, + 1181, 620, 941, 816, 817, 818, 894, 895, 105, 504, + 691, 210, 504, 506, 504, 507, 991, 354, 689, 818, + 1039, 503, 688, 504 +}; + +#define yyerrok (yyerrstatus = 0) +#define yyclearin (yychar = YYEMPTY) +#define YYEMPTY (-2) +#define YYEOF 0 + +#define YYACCEPT goto yyacceptlab +#define YYABORT goto yyabortlab +#define YYERROR goto yyerrorlab + + +/* Like YYERROR except do call yyerror. This remains here temporarily + to ease the transition to the new meaning of YYERROR, for GCC. + Once GCC version 2 has supplanted version 1, this can go. */ + +#define YYFAIL goto yyerrlab + +#define YYRECOVERING() (!!yyerrstatus) + +#define YYBACKUP(Token, Value) \ +do \ + if (yychar == YYEMPTY && yylen == 1) \ + { \ + yychar = (Token); \ + yylval = (Value); \ + yytoken = YYTRANSLATE (yychar); \ + YYPOPSTACK (1); \ + goto yybackup; \ + } \ + else \ + { \ + yyerror (YY_("syntax error: cannot back up")); \ + YYERROR; \ + } \ +while (YYID (0)) + + +#define YYTERROR 1 +#define YYERRCODE 256 + + +/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N]. + If N is 0, then set CURRENT to the empty location which ends + the previous symbol: RHS[0] (always defined). */ + +#define YYRHSLOC(Rhs, K) ((Rhs)[K]) +#ifndef YYLLOC_DEFAULT +# define YYLLOC_DEFAULT(Current, Rhs, N) \ + do \ + if (YYID (N)) \ + { \ + (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \ + (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \ + (Current).last_line = YYRHSLOC (Rhs, N).last_line; \ + (Current).last_column = YYRHSLOC (Rhs, N).last_column; \ + } \ + else \ + { \ + (Current).first_line = (Current).last_line = \ + YYRHSLOC (Rhs, 0).last_line; \ + (Current).first_column = (Current).last_column = \ + YYRHSLOC (Rhs, 0).last_column; \ + } \ + while (YYID (0)) +#endif + + +/* YY_LOCATION_PRINT -- Print the location on the stream. + This macro was not mandated originally: define only if we know + we won't break user code: when these are the locations we know. */ + +#ifndef YY_LOCATION_PRINT +# if YYLTYPE_IS_TRIVIAL +# define YY_LOCATION_PRINT(File, Loc) \ + fprintf (File, "%d.%d-%d.%d", \ + (Loc).first_line, (Loc).first_column, \ + (Loc).last_line, (Loc).last_column) +# else +# define YY_LOCATION_PRINT(File, Loc) ((void) 0) +# endif +#endif + + +/* YYLEX -- calling `yylex' with the right arguments. */ + +#ifdef YYLEX_PARAM +# define YYLEX yylex (YYLEX_PARAM) +#else +# define YYLEX yylex () +#endif + +/* Enable debugging if requested. */ +#if YYDEBUG + +# ifndef YYFPRINTF +# include /* INFRINGES ON USER NAME SPACE */ +# define YYFPRINTF fprintf +# endif + +# define YYDPRINTF(Args) \ +do { \ + if (yydebug) \ + YYFPRINTF Args; \ +} while (YYID (0)) + +# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \ +do { \ + if (yydebug) \ + { \ + YYFPRINTF (stderr, "%s ", Title); \ + yy_symbol_print (stderr, \ + Type, Value, Location); \ + YYFPRINTF (stderr, "\n"); \ + } \ +} while (YYID (0)) + + +/*--------------------------------. +| Print this symbol on YYOUTPUT. | +`--------------------------------*/ + +/*ARGSUSED*/ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp) +#else +static void +yy_symbol_value_print (yyoutput, yytype, yyvaluep, yylocationp) + FILE *yyoutput; + int yytype; + YYSTYPE const * const yyvaluep; + YYLTYPE const * const yylocationp; +#endif +{ + if (!yyvaluep) + return; + YYUSE (yylocationp); +# ifdef YYPRINT + if (yytype < YYNTOKENS) + YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep); +# else + YYUSE (yyoutput); +# endif + switch (yytype) + { + default: + break; + } +} + + +/*--------------------------------. +| Print this symbol on YYOUTPUT. | +`--------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp) +#else +static void +yy_symbol_print (yyoutput, yytype, yyvaluep, yylocationp) + FILE *yyoutput; + int yytype; + YYSTYPE const * const yyvaluep; + YYLTYPE const * const yylocationp; +#endif +{ + if (yytype < YYNTOKENS) + YYFPRINTF (yyoutput, "token %s (", yytname[yytype]); + else + YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]); + + YY_LOCATION_PRINT (yyoutput, *yylocationp); + YYFPRINTF (yyoutput, ": "); + yy_symbol_value_print (yyoutput, yytype, yyvaluep, yylocationp); + YYFPRINTF (yyoutput, ")"); +} + +/*------------------------------------------------------------------. +| yy_stack_print -- Print the state stack from its BOTTOM up to its | +| TOP (included). | +`------------------------------------------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop) +#else +static void +yy_stack_print (yybottom, yytop) + yytype_int16 *yybottom; + yytype_int16 *yytop; +#endif +{ + YYFPRINTF (stderr, "Stack now"); + for (; yybottom <= yytop; yybottom++) + { + int yybot = *yybottom; + YYFPRINTF (stderr, " %d", yybot); + } + YYFPRINTF (stderr, "\n"); +} + +# define YY_STACK_PRINT(Bottom, Top) \ +do { \ + if (yydebug) \ + yy_stack_print ((Bottom), (Top)); \ +} while (YYID (0)) + + +/*------------------------------------------------. +| Report that the YYRULE is going to be reduced. | +`------------------------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_reduce_print (YYSTYPE *yyvsp, YYLTYPE *yylsp, int yyrule) +#else +static void +yy_reduce_print (yyvsp, yylsp, yyrule) + YYSTYPE *yyvsp; + YYLTYPE *yylsp; + int yyrule; +#endif +{ + int yynrhs = yyr2[yyrule]; + int yyi; + unsigned long int yylno = yyrline[yyrule]; + YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n", + yyrule - 1, yylno); + /* The symbols being reduced. */ + for (yyi = 0; yyi < yynrhs; yyi++) + { + YYFPRINTF (stderr, " $%d = ", yyi + 1); + yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi], + &(yyvsp[(yyi + 1) - (yynrhs)]) + , &(yylsp[(yyi + 1) - (yynrhs)]) ); + YYFPRINTF (stderr, "\n"); + } +} + +# define YY_REDUCE_PRINT(Rule) \ +do { \ + if (yydebug) \ + yy_reduce_print (yyvsp, yylsp, Rule); \ +} while (YYID (0)) + +/* Nonzero means print parse trace. It is left uninitialized so that + multiple parsers can coexist. */ +int yydebug; +#else /* !YYDEBUG */ +# define YYDPRINTF(Args) +# define YY_SYMBOL_PRINT(Title, Type, Value, Location) +# define YY_STACK_PRINT(Bottom, Top) +# define YY_REDUCE_PRINT(Rule) +#endif /* !YYDEBUG */ + + +/* YYINITDEPTH -- initial size of the parser's stacks. */ +#ifndef YYINITDEPTH +# define YYINITDEPTH 200 +#endif + +/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only + if the built-in stack extension method is used). + + Do not make this value too large; the results are undefined if + YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH) + evaluated with infinite-precision integer arithmetic. */ + +#ifndef YYMAXDEPTH +# define YYMAXDEPTH 10000 +#endif + + + +#if YYERROR_VERBOSE + +# ifndef yystrlen +# if defined __GLIBC__ && defined _STRING_H +# define yystrlen strlen +# else +/* Return the length of YYSTR. */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static YYSIZE_T +yystrlen (const char *yystr) +#else +static YYSIZE_T +yystrlen (yystr) + const char *yystr; +#endif +{ + YYSIZE_T yylen; + for (yylen = 0; yystr[yylen]; yylen++) + continue; + return yylen; +} +# endif +# endif + +# ifndef yystpcpy +# if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE +# define yystpcpy stpcpy +# else +/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in + YYDEST. */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static char * +yystpcpy (char *yydest, const char *yysrc) +#else +static char * +yystpcpy (yydest, yysrc) + char *yydest; + const char *yysrc; +#endif +{ + char *yyd = yydest; + const char *yys = yysrc; + + while ((*yyd++ = *yys++) != '\0') + continue; + + return yyd - 1; +} +# endif +# endif + +# ifndef yytnamerr +/* Copy to YYRES the contents of YYSTR after stripping away unnecessary + quotes and backslashes, so that it's suitable for yyerror. The + heuristic is that double-quoting is unnecessary unless the string + contains an apostrophe, a comma, or backslash (other than + backslash-backslash). YYSTR is taken from yytname. If YYRES is + null, do not copy; instead, return the length of what the result + would have been. */ +static YYSIZE_T +yytnamerr (char *yyres, const char *yystr) +{ + if (*yystr == '"') + { + YYSIZE_T yyn = 0; + char const *yyp = yystr; + + for (;;) + switch (*++yyp) + { + case '\'': + case ',': + goto do_not_strip_quotes; + + case '\\': + if (*++yyp != '\\') + goto do_not_strip_quotes; + /* Fall through. */ + default: + if (yyres) + yyres[yyn] = *yyp; + yyn++; + break; + + case '"': + if (yyres) + yyres[yyn] = '\0'; + return yyn; + } + do_not_strip_quotes: ; + } + + if (! yyres) + return yystrlen (yystr); + + return yystpcpy (yyres, yystr) - yyres; +} +# endif + +/* Copy into YYRESULT an error message about the unexpected token + YYCHAR while in state YYSTATE. Return the number of bytes copied, + including the terminating null byte. If YYRESULT is null, do not + copy anything; just return the number of bytes that would be + copied. As a special case, return 0 if an ordinary "syntax error" + message will do. Return YYSIZE_MAXIMUM if overflow occurs during + size calculation. */ +static YYSIZE_T +yysyntax_error (char *yyresult, int yystate, int yychar) +{ + int yyn = yypact[yystate]; + + if (! (YYPACT_NINF < yyn && yyn <= YYLAST)) + return 0; + else + { + int yytype = YYTRANSLATE (yychar); + YYSIZE_T yysize0 = yytnamerr (0, yytname[yytype]); + YYSIZE_T yysize = yysize0; + YYSIZE_T yysize1; + int yysize_overflow = 0; + enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; + char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; + int yyx; + +# if 0 + /* This is so xgettext sees the translatable formats that are + constructed on the fly. */ + YY_("syntax error, unexpected %s"); + YY_("syntax error, unexpected %s, expecting %s"); + YY_("syntax error, unexpected %s, expecting %s or %s"); + YY_("syntax error, unexpected %s, expecting %s or %s or %s"); + YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"); +# endif + char *yyfmt; + char const *yyf; + static char const yyunexpected[] = "syntax error, unexpected %s"; + static char const yyexpecting[] = ", expecting %s"; + static char const yyor[] = " or %s"; + char yyformat[sizeof yyunexpected + + sizeof yyexpecting - 1 + + ((YYERROR_VERBOSE_ARGS_MAXIMUM - 2) + * (sizeof yyor - 1))]; + char const *yyprefix = yyexpecting; + + /* Start YYX at -YYN if negative to avoid negative indexes in + YYCHECK. */ + int yyxbegin = yyn < 0 ? -yyn : 0; + + /* Stay within bounds of both yycheck and yytname. */ + int yychecklim = YYLAST - yyn + 1; + int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; + int yycount = 1; + + yyarg[0] = yytname[yytype]; + yyfmt = yystpcpy (yyformat, yyunexpected); + + for (yyx = yyxbegin; yyx < yyxend; ++yyx) + if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR) + { + if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) + { + yycount = 1; + yysize = yysize0; + yyformat[sizeof yyunexpected - 1] = '\0'; + break; + } + yyarg[yycount++] = yytname[yyx]; + yysize1 = yysize + yytnamerr (0, yytname[yyx]); + yysize_overflow |= (yysize1 < yysize); + yysize = yysize1; + yyfmt = yystpcpy (yyfmt, yyprefix); + yyprefix = yyor; + } + + yyf = YY_(yyformat); + yysize1 = yysize + yystrlen (yyf); + yysize_overflow |= (yysize1 < yysize); + yysize = yysize1; + + if (yysize_overflow) + return YYSIZE_MAXIMUM; + + if (yyresult) + { + /* Avoid sprintf, as that infringes on the user's name space. + Don't have undefined behavior even if the translation + produced a string with the wrong number of "%s"s. */ + char *yyp = yyresult; + int yyi = 0; + while ((*yyp = *yyf) != '\0') + { + if (*yyp == '%' && yyf[1] == 's' && yyi < yycount) + { + yyp += yytnamerr (yyp, yyarg[yyi++]); + yyf += 2; + } + else + { + yyp++; + yyf++; + } + } + } + return yysize; + } +} +#endif /* YYERROR_VERBOSE */ + + +/*-----------------------------------------------. +| Release the memory associated to this symbol. | +`-----------------------------------------------*/ + +/*ARGSUSED*/ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep, YYLTYPE *yylocationp) +#else +static void +yydestruct (yymsg, yytype, yyvaluep, yylocationp) + const char *yymsg; + int yytype; + YYSTYPE *yyvaluep; + YYLTYPE *yylocationp; +#endif +{ + YYUSE (yyvaluep); + YYUSE (yylocationp); + + if (!yymsg) + yymsg = "Deleting"; + YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp); + + switch (yytype) + { + + default: + break; + } +} + +/* Prevent warnings from -Wmissing-prototypes. */ +#ifdef YYPARSE_PARAM +#if defined __STDC__ || defined __cplusplus +int yyparse (void *YYPARSE_PARAM); +#else +int yyparse (); +#endif +#else /* ! YYPARSE_PARAM */ +#if defined __STDC__ || defined __cplusplus +int yyparse (void); +#else +int yyparse (); +#endif +#endif /* ! YYPARSE_PARAM */ + + +/* The lookahead symbol. */ +int yychar; + +/* The semantic value of the lookahead symbol. */ +YYSTYPE yylval; + +/* Location data for the lookahead symbol. */ +YYLTYPE yylloc; + +/* Number of syntax errors so far. */ +int yynerrs; + + + +/*-------------------------. +| yyparse or yypush_parse. | +`-------------------------*/ + +#ifdef YYPARSE_PARAM +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +int +yyparse (void *YYPARSE_PARAM) +#else +int +yyparse (YYPARSE_PARAM) + void *YYPARSE_PARAM; +#endif +#else /* ! YYPARSE_PARAM */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +int +yyparse (void) +#else +int +yyparse () + +#endif +#endif +{ + + + int yystate; + /* Number of tokens to shift before error messages enabled. */ + int yyerrstatus; + + /* The stacks and their tools: + `yyss': related to states. + `yyvs': related to semantic values. + `yyls': related to locations. + + Refer to the stacks thru separate pointers, to allow yyoverflow + to reallocate them elsewhere. */ + + /* The state stack. */ + yytype_int16 yyssa[YYINITDEPTH]; + yytype_int16 *yyss; + yytype_int16 *yyssp; + + /* The semantic value stack. */ + YYSTYPE yyvsa[YYINITDEPTH]; + YYSTYPE *yyvs; + YYSTYPE *yyvsp; + + /* The location stack. */ + YYLTYPE yylsa[YYINITDEPTH]; + YYLTYPE *yyls; + YYLTYPE *yylsp; + + /* The locations where the error started and ended. */ + YYLTYPE yyerror_range[2]; + + YYSIZE_T yystacksize; + + int yyn; + int yyresult; + /* Lookahead token as an internal (translated) token number. */ + int yytoken; + /* The variables used to return semantic value and location from the + action routines. */ + YYSTYPE yyval; + YYLTYPE yyloc; + +#if YYERROR_VERBOSE + /* Buffer for error messages, and its allocated size. */ + char yymsgbuf[128]; + char *yymsg = yymsgbuf; + YYSIZE_T yymsg_alloc = sizeof yymsgbuf; +#endif + +#define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N), yylsp -= (N)) + + /* The number of symbols on the RHS of the reduced rule. + Keep to zero when no symbol should be popped. */ + int yylen = 0; + + yytoken = 0; + yyss = yyssa; + yyvs = yyvsa; + yyls = yylsa; + yystacksize = YYINITDEPTH; + + YYDPRINTF ((stderr, "Starting parse\n")); + + yystate = 0; + yyerrstatus = 0; + yynerrs = 0; + yychar = YYEMPTY; /* Cause a token to be read. */ + + /* Initialize stack pointers. + Waste one element of value and location stack + so that they stay on the same level as the state stack. + The wasted elements are never initialized. */ + yyssp = yyss; + yyvsp = yyvs; + yylsp = yyls; + +#if YYLTYPE_IS_TRIVIAL + /* Initialize the default location before parsing starts. */ + yylloc.first_line = yylloc.last_line = 1; + yylloc.first_column = yylloc.last_column = 1; +#endif + + goto yysetstate; + +/*------------------------------------------------------------. +| yynewstate -- Push a new state, which is found in yystate. | +`------------------------------------------------------------*/ + yynewstate: + /* In all cases, when you get here, the value and location stacks + have just been pushed. So pushing a state here evens the stacks. */ + yyssp++; + + yysetstate: + *yyssp = yystate; + + if (yyss + yystacksize - 1 <= yyssp) + { + /* Get the current used size of the three stacks, in elements. */ + YYSIZE_T yysize = yyssp - yyss + 1; + +#ifdef yyoverflow + { + /* Give user a chance to reallocate the stack. Use copies of + these so that the &'s don't force the real ones into + memory. */ + YYSTYPE *yyvs1 = yyvs; + yytype_int16 *yyss1 = yyss; + YYLTYPE *yyls1 = yyls; + + /* Each stack pointer address is followed by the size of the + data in use in that stack, in bytes. This used to be a + conditional around just the two extra args, but that might + be undefined if yyoverflow is a macro. */ + yyoverflow (YY_("memory exhausted"), + &yyss1, yysize * sizeof (*yyssp), + &yyvs1, yysize * sizeof (*yyvsp), + &yyls1, yysize * sizeof (*yylsp), + &yystacksize); + + yyls = yyls1; + yyss = yyss1; + yyvs = yyvs1; + } +#else /* no yyoverflow */ +# ifndef YYSTACK_RELOCATE + goto yyexhaustedlab; +# else + /* Extend the stack our own way. */ + if (YYMAXDEPTH <= yystacksize) + goto yyexhaustedlab; + yystacksize *= 2; + if (YYMAXDEPTH < yystacksize) + yystacksize = YYMAXDEPTH; + + { + yytype_int16 *yyss1 = yyss; + union yyalloc *yyptr = + (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize)); + if (! yyptr) + goto yyexhaustedlab; + YYSTACK_RELOCATE (yyss_alloc, yyss); + YYSTACK_RELOCATE (yyvs_alloc, yyvs); + YYSTACK_RELOCATE (yyls_alloc, yyls); +# undef YYSTACK_RELOCATE + if (yyss1 != yyssa) + YYSTACK_FREE (yyss1); + } +# endif +#endif /* no yyoverflow */ + + yyssp = yyss + yysize - 1; + yyvsp = yyvs + yysize - 1; + yylsp = yyls + yysize - 1; + + YYDPRINTF ((stderr, "Stack size increased to %lu\n", + (unsigned long int) yystacksize)); + + if (yyss + yystacksize - 1 <= yyssp) + YYABORT; + } + + YYDPRINTF ((stderr, "Entering state %d\n", yystate)); + + if (yystate == YYFINAL) + YYACCEPT; + + goto yybackup; + +/*-----------. +| yybackup. | +`-----------*/ +yybackup: + + /* Do appropriate processing given the current state. Read a + lookahead token if we need one and don't already have one. */ + + /* First try to decide what to do without reference to lookahead token. */ + yyn = yypact[yystate]; + if (yyn == YYPACT_NINF) + goto yydefault; + + /* Not known => get a lookahead token if don't already have one. */ + + /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */ + if (yychar == YYEMPTY) + { + YYDPRINTF ((stderr, "Reading a token: ")); + yychar = YYLEX; + } + + if (yychar <= YYEOF) + { + yychar = yytoken = YYEOF; + YYDPRINTF ((stderr, "Now at end of input.\n")); + } + else + { + yytoken = YYTRANSLATE (yychar); + YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc); + } + + /* If the proper action on seeing token YYTOKEN is to reduce or to + detect an error, take that action. */ + yyn += yytoken; + if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken) + goto yydefault; + yyn = yytable[yyn]; + if (yyn <= 0) + { + if (yyn == 0 || yyn == YYTABLE_NINF) + goto yyerrlab; + yyn = -yyn; + goto yyreduce; + } + + /* Count tokens shifted since error; after three, turn off error + status. */ + if (yyerrstatus) + yyerrstatus--; + + /* Shift the lookahead token. */ + YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc); + + /* Discard the shifted token. */ + yychar = YYEMPTY; + + yystate = yyn; + *++yyvsp = yylval; + *++yylsp = yylloc; + goto yynewstate; + + +/*-----------------------------------------------------------. +| yydefault -- do the default action for the current state. | +`-----------------------------------------------------------*/ +yydefault: + yyn = yydefact[yystate]; + if (yyn == 0) + goto yyerrlab; + goto yyreduce; + + +/*-----------------------------. +| yyreduce -- Do a reduction. | +`-----------------------------*/ +yyreduce: + /* yyn is the number of a rule to reduce with. */ + yylen = yyr2[yyn]; + + /* If YYLEN is nonzero, implement the default value of the action: + `$$ = $1'. + + Otherwise, the following line sets YYVAL to garbage. + This behavior is undocumented and Bison + users should not rely upon it. Assigning to YYVAL + unconditionally makes the parser a bit smaller, and it avoids a + GCC warning that YYVAL may be used uninitialized. */ + yyval = yyvsp[1-yylen]; + + /* Default location. */ + YYLLOC_DEFAULT (yyloc, (yylsp - yylen), yylen); + YY_REDUCE_PRINT (yyn); + switch (yyn) + { + case 3: + +/* Line 1455 of yacc.c */ +#line 1468 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 4: + +/* Line 1455 of yacc.c */ +#line 1470 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 5: + +/* Line 1455 of yacc.c */ +#line 1472 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 6: + +/* Line 1455 of yacc.c */ +#line 1474 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 7: + +/* Line 1455 of yacc.c */ +#line 1476 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 8: + +/* Line 1455 of yacc.c */ +#line 1478 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 9: + +/* Line 1455 of yacc.c */ +#line 1480 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 10: + +/* Line 1455 of yacc.c */ +#line 1482 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 11: + +/* Line 1455 of yacc.c */ +#line 1484 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 12: + +/* Line 1455 of yacc.c */ +#line 1486 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 13: + +/* Line 1455 of yacc.c */ +#line 1488 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 14: + +/* Line 1455 of yacc.c */ +#line 1490 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 15: + +/* Line 1455 of yacc.c */ +#line 1492 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 16: + +/* Line 1455 of yacc.c */ +#line 1494 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 17: + +/* Line 1455 of yacc.c */ +#line 1496 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 18: + +/* Line 1455 of yacc.c */ +#line 1498 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 19: + +/* Line 1455 of yacc.c */ +#line 1500 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 20: + +/* Line 1455 of yacc.c */ +#line 1502 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 21: + +/* Line 1455 of yacc.c */ +#line 1504 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 22: + +/* Line 1455 of yacc.c */ +#line 1506 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 23: + +/* Line 1455 of yacc.c */ +#line 1508 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 24: + +/* Line 1455 of yacc.c */ +#line 1510 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 25: + +/* Line 1455 of yacc.c */ +#line 1512 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 26: + +/* Line 1455 of yacc.c */ +#line 1514 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 27: + +/* Line 1455 of yacc.c */ +#line 1516 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 28: + +/* Line 1455 of yacc.c */ +#line 1518 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 29: + +/* Line 1455 of yacc.c */ +#line 1520 "preproc.y" + { + if (INFORMIX_MODE) + { + if (pg_strcasecmp((yyvsp[(1) - (1)].str)+strlen("close "), "database") == 0) + { + if (connection) + mmerror(PARSE_ERROR, ET_ERROR, "AT option not allowed in CLOSE DATABASE statement"); + + fprintf(yyout, "{ ECPGdisconnect(__LINE__, \"CURRENT\");"); + whenever_action(2); + free((yyvsp[(1) - (1)].str)); + break; + } + } + + output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); + ;} + break; + + case 30: + +/* Line 1455 of yacc.c */ +#line 1538 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 31: + +/* Line 1455 of yacc.c */ +#line 1540 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 32: + +/* Line 1455 of yacc.c */ +#line 1542 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 33: + +/* Line 1455 of yacc.c */ +#line 1544 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 34: + +/* Line 1455 of yacc.c */ +#line 1546 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 35: + +/* Line 1455 of yacc.c */ +#line 1548 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 36: + +/* Line 1455 of yacc.c */ +#line 1550 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 37: + +/* Line 1455 of yacc.c */ +#line 1552 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 38: + +/* Line 1455 of yacc.c */ +#line 1554 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 39: + +/* Line 1455 of yacc.c */ +#line 1556 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 40: + +/* Line 1455 of yacc.c */ +#line 1558 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 41: + +/* Line 1455 of yacc.c */ +#line 1560 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 42: + +/* Line 1455 of yacc.c */ +#line 1562 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 43: + +/* Line 1455 of yacc.c */ +#line 1564 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 44: + +/* Line 1455 of yacc.c */ +#line 1566 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 45: + +/* Line 1455 of yacc.c */ +#line 1568 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 46: + +/* Line 1455 of yacc.c */ +#line 1570 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 47: + +/* Line 1455 of yacc.c */ +#line 1572 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 48: + +/* Line 1455 of yacc.c */ +#line 1574 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 49: + +/* Line 1455 of yacc.c */ +#line 1576 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 50: + +/* Line 1455 of yacc.c */ +#line 1578 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 51: + +/* Line 1455 of yacc.c */ +#line 1580 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 52: + +/* Line 1455 of yacc.c */ +#line 1582 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 53: + +/* Line 1455 of yacc.c */ +#line 1584 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 54: + +/* Line 1455 of yacc.c */ +#line 1586 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 55: + +/* Line 1455 of yacc.c */ +#line 1588 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 56: + +/* Line 1455 of yacc.c */ +#line 1590 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 57: + +/* Line 1455 of yacc.c */ +#line 1592 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 58: + +/* Line 1455 of yacc.c */ +#line 1594 "preproc.y" + { + output_deallocate_prepare_statement((yyvsp[(1) - (1)].str)); + ;} + break; + + case 59: + +/* Line 1455 of yacc.c */ +#line 1598 "preproc.y" + { output_simple_statement((yyvsp[(1) - (1)].str)); ;} + break; + + case 60: + +/* Line 1455 of yacc.c */ +#line 1600 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 61: + +/* Line 1455 of yacc.c */ +#line 1602 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 1, ECPGst_prepnormal); ;} + break; + + case 62: + +/* Line 1455 of yacc.c */ +#line 1604 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 1, ECPGst_normal); ;} + break; + + case 63: + +/* Line 1455 of yacc.c */ +#line 1606 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 64: + +/* Line 1455 of yacc.c */ +#line 1608 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 65: + +/* Line 1455 of yacc.c */ +#line 1610 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 66: + +/* Line 1455 of yacc.c */ +#line 1612 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 67: + +/* Line 1455 of yacc.c */ +#line 1614 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 68: + +/* Line 1455 of yacc.c */ +#line 1616 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 69: + +/* Line 1455 of yacc.c */ +#line 1618 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 70: + +/* Line 1455 of yacc.c */ +#line 1620 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 71: + +/* Line 1455 of yacc.c */ +#line 1622 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 72: + +/* Line 1455 of yacc.c */ +#line 1624 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 73: + +/* Line 1455 of yacc.c */ +#line 1626 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 74: + +/* Line 1455 of yacc.c */ +#line 1628 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 75: + +/* Line 1455 of yacc.c */ +#line 1630 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 76: + +/* Line 1455 of yacc.c */ +#line 1632 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 77: + +/* Line 1455 of yacc.c */ +#line 1634 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 78: + +/* Line 1455 of yacc.c */ +#line 1636 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 79: + +/* Line 1455 of yacc.c */ +#line 1638 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 80: + +/* Line 1455 of yacc.c */ +#line 1640 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 81: + +/* Line 1455 of yacc.c */ +#line 1642 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 1, ECPGst_execute); ;} + break; + + case 82: + +/* Line 1455 of yacc.c */ +#line 1644 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 83: + +/* Line 1455 of yacc.c */ +#line 1646 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 1, ECPGst_normal); ;} + break; + + case 84: + +/* Line 1455 of yacc.c */ +#line 1648 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 85: + +/* Line 1455 of yacc.c */ +#line 1650 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 86: + +/* Line 1455 of yacc.c */ +#line 1652 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 87: + +/* Line 1455 of yacc.c */ +#line 1654 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 1, ECPGst_prepnormal); ;} + break; + + case 88: + +/* Line 1455 of yacc.c */ +#line 1656 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 89: + +/* Line 1455 of yacc.c */ +#line 1658 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 90: + +/* Line 1455 of yacc.c */ +#line 1660 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 91: + +/* Line 1455 of yacc.c */ +#line 1662 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 92: + +/* Line 1455 of yacc.c */ +#line 1664 "preproc.y" + { + if ((yyvsp[(1) - (1)].prep).type == NULL || strlen((yyvsp[(1) - (1)].prep).type) == 0) + output_prepare_statement((yyvsp[(1) - (1)].prep).name, (yyvsp[(1) - (1)].prep).stmt); + else + output_statement(cat_str(5, mm_strdup("prepare"), (yyvsp[(1) - (1)].prep).name, (yyvsp[(1) - (1)].prep).type, mm_strdup("as"), (yyvsp[(1) - (1)].prep).stmt), 0, ECPGst_normal); + ;} + break; + + case 93: + +/* Line 1455 of yacc.c */ +#line 1671 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 94: + +/* Line 1455 of yacc.c */ +#line 1673 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 95: + +/* Line 1455 of yacc.c */ +#line 1675 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 96: + +/* Line 1455 of yacc.c */ +#line 1677 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 97: + +/* Line 1455 of yacc.c */ +#line 1679 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 98: + +/* Line 1455 of yacc.c */ +#line 1681 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 99: + +/* Line 1455 of yacc.c */ +#line 1683 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 100: + +/* Line 1455 of yacc.c */ +#line 1685 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 101: + +/* Line 1455 of yacc.c */ +#line 1687 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 102: + +/* Line 1455 of yacc.c */ +#line 1689 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 103: + +/* Line 1455 of yacc.c */ +#line 1691 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 1, ECPGst_prepnormal); ;} + break; + + case 104: + +/* Line 1455 of yacc.c */ +#line 1693 "preproc.y" + { + fprintf(yyout, "{ ECPGtrans(__LINE__, %s, \"%s\");", connection ? connection : "NULL", (yyvsp[(1) - (1)].str)); + whenever_action(2); + free((yyvsp[(1) - (1)].str)); + ;} + break; + + case 105: + +/* Line 1455 of yacc.c */ +#line 1699 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 106: + +/* Line 1455 of yacc.c */ +#line 1701 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 107: + +/* Line 1455 of yacc.c */ +#line 1703 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 1, ECPGst_prepnormal); ;} + break; + + case 108: + +/* Line 1455 of yacc.c */ +#line 1705 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 109: + +/* Line 1455 of yacc.c */ +#line 1707 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 110: + +/* Line 1455 of yacc.c */ +#line 1709 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 111: + +/* Line 1455 of yacc.c */ +#line 1711 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 112: + +/* Line 1455 of yacc.c */ +#line 1713 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_normal); ;} + break; + + case 113: + +/* Line 1455 of yacc.c */ +#line 1715 "preproc.y" + { + fprintf(yyout,"ECPGallocate_desc(__LINE__, %s);",(yyvsp[(1) - (1)].str)); + whenever_action(0); + free((yyvsp[(1) - (1)].str)); + ;} + break; + + case 114: + +/* Line 1455 of yacc.c */ +#line 1721 "preproc.y" + { + if (connection) + mmerror(PARSE_ERROR, ET_ERROR, "AT option not allowed in CONNECT statement"); + + fprintf(yyout, "{ ECPGconnect(__LINE__, %d, %s, %d); ", compat, (yyvsp[(1) - (1)].str), autocommit); + reset_variables(); + whenever_action(2); + free((yyvsp[(1) - (1)].str)); + ;} + break; + + case 115: + +/* Line 1455 of yacc.c */ +#line 1731 "preproc.y" + { + output_simple_statement((yyvsp[(1) - (1)].str)); + ;} + break; + + case 116: + +/* Line 1455 of yacc.c */ +#line 1735 "preproc.y" + { + fprintf(yyout,"ECPGdeallocate_desc(__LINE__, %s);",(yyvsp[(1) - (1)].str)); + whenever_action(0); + free((yyvsp[(1) - (1)].str)); + ;} + break; + + case 117: + +/* Line 1455 of yacc.c */ +#line 1741 "preproc.y" + { + output_simple_statement((yyvsp[(1) - (1)].str)); + ;} + break; + + case 118: + +/* Line 1455 of yacc.c */ +#line 1745 "preproc.y" + { + fprintf(yyout, "{ ECPGdescribe(__LINE__, %d, %s,", compat, (yyvsp[(1) - (1)].str)); + dump_variables(argsresult, 1); + fputs("ECPGt_EORT);", yyout); + fprintf(yyout, "}"); + output_line_number(); + + free((yyvsp[(1) - (1)].str)); + ;} + break; + + case 119: + +/* Line 1455 of yacc.c */ +#line 1755 "preproc.y" + { + if (connection) + mmerror(PARSE_ERROR, ET_ERROR, "AT option not allowed in DISCONNECT statement"); + + fprintf(yyout, "{ ECPGdisconnect(__LINE__, %s);", + (yyvsp[(1) - (1)].str) ? (yyvsp[(1) - (1)].str) : "\"CURRENT\""); + whenever_action(2); + free((yyvsp[(1) - (1)].str)); + ;} + break; + + case 120: + +/* Line 1455 of yacc.c */ +#line 1764 "preproc.y" + { output_statement((yyvsp[(1) - (1)].str), 0, ECPGst_exec_immediate); ;} + break; + + case 121: + +/* Line 1455 of yacc.c */ +#line 1766 "preproc.y" + { + const char *con = connection ? connection : "NULL"; + + if (strcmp((yyvsp[(1) - (1)].str), "all") == 0) + fprintf(yyout, "{ ECPGdeallocate_all(__LINE__, %d, %s);", compat, con); + else if ((yyvsp[(1) - (1)].str)[0] == ':') + fprintf(yyout, "{ ECPGdeallocate(__LINE__, %d, %s, %s);", compat, con, (yyvsp[(1) - (1)].str)+1); + else + fprintf(yyout, "{ ECPGdeallocate(__LINE__, %d, %s, \"%s\");", compat, con, (yyvsp[(1) - (1)].str)); + + whenever_action(2); + free((yyvsp[(1) - (1)].str)); + ;} + break; + + case 122: + +/* Line 1455 of yacc.c */ +#line 1780 "preproc.y" + { + lookup_descriptor((yyvsp[(1) - (1)].descriptor).name, connection); + output_get_descr((yyvsp[(1) - (1)].descriptor).name, (yyvsp[(1) - (1)].descriptor).str); + free((yyvsp[(1) - (1)].descriptor).name); + free((yyvsp[(1) - (1)].descriptor).str); + ;} + break; + + case 123: + +/* Line 1455 of yacc.c */ +#line 1787 "preproc.y" + { + lookup_descriptor((yyvsp[(1) - (1)].str), connection); + output_get_descr_header((yyvsp[(1) - (1)].str)); + free((yyvsp[(1) - (1)].str)); + ;} + break; + + case 124: + +/* Line 1455 of yacc.c */ +#line 1793 "preproc.y" + { + struct cursor *ptr; + + if ((ptr = add_additional_variables((yyvsp[(1) - (1)].str), true)) != NULL) + { + connection = ptr->connection ? mm_strdup(ptr->connection) : NULL; + output_statement(mm_strdup(ptr->command), 0, ECPGst_normal); + ptr->opened = true; + } + ;} + break; + + case 125: + +/* Line 1455 of yacc.c */ +#line 1804 "preproc.y" + { + fprintf(yyout, "{ ECPGsetcommit(__LINE__, \"%s\", %s);", (yyvsp[(1) - (1)].str), connection ? connection : "NULL"); + whenever_action(2); + free((yyvsp[(1) - (1)].str)); + ;} + break; + + case 126: + +/* Line 1455 of yacc.c */ +#line 1810 "preproc.y" + { + if (connection) + mmerror(PARSE_ERROR, ET_ERROR, "AT option not allowed in SET CONNECTION statement"); + + fprintf(yyout, "{ ECPGsetconn(__LINE__, %s);", (yyvsp[(1) - (1)].str)); + whenever_action(2); + free((yyvsp[(1) - (1)].str)); + ;} + break; + + case 127: + +/* Line 1455 of yacc.c */ +#line 1819 "preproc.y" + { + lookup_descriptor((yyvsp[(1) - (1)].descriptor).name, connection); + output_set_descr((yyvsp[(1) - (1)].descriptor).name, (yyvsp[(1) - (1)].descriptor).str); + free((yyvsp[(1) - (1)].descriptor).name); + free((yyvsp[(1) - (1)].descriptor).str); + ;} + break; + + case 128: + +/* Line 1455 of yacc.c */ +#line 1826 "preproc.y" + { + lookup_descriptor((yyvsp[(1) - (1)].str), connection); + output_set_descr_header((yyvsp[(1) - (1)].str)); + free((yyvsp[(1) - (1)].str)); + ;} + break; + + case 129: + +/* Line 1455 of yacc.c */ +#line 1832 "preproc.y" + { + if (connection) + mmerror(PARSE_ERROR, ET_ERROR, "AT option not allowed in TYPE statement"); + + fprintf(yyout, "%s", (yyvsp[(1) - (1)].str)); + free((yyvsp[(1) - (1)].str)); + output_line_number(); + ;} + break; + + case 130: + +/* Line 1455 of yacc.c */ +#line 1841 "preproc.y" + { + if (connection) + mmerror(PARSE_ERROR, ET_ERROR, "AT option not allowed in VAR statement"); + + output_simple_statement((yyvsp[(1) - (1)].str)); + ;} + break; + + case 131: + +/* Line 1455 of yacc.c */ +#line 1848 "preproc.y" + { + if (connection) + mmerror(PARSE_ERROR, ET_ERROR, "AT option not allowed in WHENEVER statement"); + + output_simple_statement((yyvsp[(1) - (1)].str)); + ;} + break; + + case 132: + +/* Line 1455 of yacc.c */ +#line 1855 "preproc.y" + { (yyval.str) = NULL; ;} + break; + + case 133: + +/* Line 1455 of yacc.c */ +#line 1861 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("create role"),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 134: + +/* Line 1455 of yacc.c */ +#line 1869 "preproc.y" + { + (yyval.str) = mm_strdup("with"); +;} + break; + + case 135: + +/* Line 1455 of yacc.c */ +#line 1873 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 136: + +/* Line 1455 of yacc.c */ +#line 1880 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 137: + +/* Line 1455 of yacc.c */ +#line 1884 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 138: + +/* Line 1455 of yacc.c */ +#line 1891 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 139: + +/* Line 1455 of yacc.c */ +#line 1895 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 140: + +/* Line 1455 of yacc.c */ +#line 1902 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("password"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 141: + +/* Line 1455 of yacc.c */ +#line 1906 "preproc.y" + { + (yyval.str) = mm_strdup("password null"); +;} + break; + + case 142: + +/* Line 1455 of yacc.c */ +#line 1910 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("encrypted password"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 143: + +/* Line 1455 of yacc.c */ +#line 1914 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("unencrypted password"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 144: + +/* Line 1455 of yacc.c */ +#line 1918 "preproc.y" + { + (yyval.str) = mm_strdup("inherit"); +;} + break; + + case 145: + +/* Line 1455 of yacc.c */ +#line 1922 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("connection limit"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 146: + +/* Line 1455 of yacc.c */ +#line 1926 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("valid until"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 147: + +/* Line 1455 of yacc.c */ +#line 1930 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("user"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 148: + +/* Line 1455 of yacc.c */ +#line 1934 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 149: + +/* Line 1455 of yacc.c */ +#line 1942 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 150: + +/* Line 1455 of yacc.c */ +#line 1946 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("sysid"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 151: + +/* Line 1455 of yacc.c */ +#line 1950 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("admin"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 152: + +/* Line 1455 of yacc.c */ +#line 1954 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("role"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 153: + +/* Line 1455 of yacc.c */ +#line 1958 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("in role"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 154: + +/* Line 1455 of yacc.c */ +#line 1962 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("in group"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 155: + +/* Line 1455 of yacc.c */ +#line 1970 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("create user"),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 156: + +/* Line 1455 of yacc.c */ +#line 1978 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter role"),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 157: + +/* Line 1455 of yacc.c */ +#line 1986 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 158: + +/* Line 1455 of yacc.c */ +#line 1989 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("in database"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 159: + +/* Line 1455 of yacc.c */ +#line 1997 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter role"),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 160: + +/* Line 1455 of yacc.c */ +#line 2005 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter user"),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 161: + +/* Line 1455 of yacc.c */ +#line 2013 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("alter user"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 162: + +/* Line 1455 of yacc.c */ +#line 2021 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("drop role"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 163: + +/* Line 1455 of yacc.c */ +#line 2025 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("drop role if exists"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 164: + +/* Line 1455 of yacc.c */ +#line 2033 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("drop user"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 165: + +/* Line 1455 of yacc.c */ +#line 2037 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("drop user if exists"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 166: + +/* Line 1455 of yacc.c */ +#line 2045 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("create group"),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 167: + +/* Line 1455 of yacc.c */ +#line 2053 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter group"),(yyvsp[(3) - (6)].str),(yyvsp[(4) - (6)].str),mm_strdup("user"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 168: + +/* Line 1455 of yacc.c */ +#line 2061 "preproc.y" + { + (yyval.str) = mm_strdup("add"); +;} + break; + + case 169: + +/* Line 1455 of yacc.c */ +#line 2065 "preproc.y" + { + (yyval.str) = mm_strdup("drop"); +;} + break; + + case 170: + +/* Line 1455 of yacc.c */ +#line 2073 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("drop group"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 171: + +/* Line 1455 of yacc.c */ +#line 2077 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("drop group if exists"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 172: + +/* Line 1455 of yacc.c */ +#line 2085 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("create schema"),(yyvsp[(3) - (6)].str),mm_strdup("authorization"),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 173: + +/* Line 1455 of yacc.c */ +#line 2089 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("create schema"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 174: + +/* Line 1455 of yacc.c */ +#line 2097 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 175: + +/* Line 1455 of yacc.c */ +#line 2101 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 176: + +/* Line 1455 of yacc.c */ +#line 2108 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 177: + +/* Line 1455 of yacc.c */ +#line 2112 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 178: + +/* Line 1455 of yacc.c */ +#line 2119 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 179: + +/* Line 1455 of yacc.c */ +#line 2123 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 180: + +/* Line 1455 of yacc.c */ +#line 2127 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 181: + +/* Line 1455 of yacc.c */ +#line 2131 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 182: + +/* Line 1455 of yacc.c */ +#line 2135 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 183: + +/* Line 1455 of yacc.c */ +#line 2139 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 184: + +/* Line 1455 of yacc.c */ +#line 2147 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("set"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 185: + +/* Line 1455 of yacc.c */ +#line 2151 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("set local"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 186: + +/* Line 1455 of yacc.c */ +#line 2155 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("set session"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 187: + +/* Line 1455 of yacc.c */ +#line 2163 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("transaction"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 188: + +/* Line 1455 of yacc.c */ +#line 2167 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("session characteristics as transaction"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 189: + +/* Line 1455 of yacc.c */ +#line 2171 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 190: + +/* Line 1455 of yacc.c */ +#line 2179 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("to"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 191: + +/* Line 1455 of yacc.c */ +#line 2183 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("="),(yyvsp[(3) - (3)].str)); +;} + break; + + case 192: + +/* Line 1455 of yacc.c */ +#line 2187 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (3)].str),mm_strdup("to default")); +;} + break; + + case 193: + +/* Line 1455 of yacc.c */ +#line 2191 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (3)].str),mm_strdup("= default")); +;} + break; + + case 194: + +/* Line 1455 of yacc.c */ +#line 2195 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (3)].str),mm_strdup("from current")); +;} + break; + + case 195: + +/* Line 1455 of yacc.c */ +#line 2199 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("time zone"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 196: + +/* Line 1455 of yacc.c */ +#line 2203 "preproc.y" + { +mmerror(PARSE_ERROR, ET_WARNING, "unsupported feature will be passed to server"); + (yyval.str) = cat_str(2,mm_strdup("catalog"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 197: + +/* Line 1455 of yacc.c */ +#line 2208 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("schema"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 198: + +/* Line 1455 of yacc.c */ +#line 2212 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("names"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 199: + +/* Line 1455 of yacc.c */ +#line 2216 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("role"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 200: + +/* Line 1455 of yacc.c */ +#line 2220 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("session authorization"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 201: + +/* Line 1455 of yacc.c */ +#line 2224 "preproc.y" + { + (yyval.str) = mm_strdup("session authorization default"); +;} + break; + + case 202: + +/* Line 1455 of yacc.c */ +#line 2228 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("xml option"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 203: + +/* Line 1455 of yacc.c */ +#line 2232 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("transaction snapshot"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 204: + +/* Line 1455 of yacc.c */ +#line 2240 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 205: + +/* Line 1455 of yacc.c */ +#line 2244 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("."),(yyvsp[(3) - (3)].str)); +;} + break; + + case 206: + +/* Line 1455 of yacc.c */ +#line 2252 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 207: + +/* Line 1455 of yacc.c */ +#line 2256 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 208: + +/* Line 1455 of yacc.c */ +#line 2264 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 209: + +/* Line 1455 of yacc.c */ +#line 2268 "preproc.y" + { + if ((yyvsp[(1) - (1)].str)[0] == '$') + { + free((yyvsp[(1) - (1)].str)); + (yyvsp[(1) - (1)].str) = mm_strdup("$0"); + } + + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 210: + +/* Line 1455 of yacc.c */ +#line 2282 "preproc.y" + { + (yyval.str) = mm_strdup("read uncommitted"); +;} + break; + + case 211: + +/* Line 1455 of yacc.c */ +#line 2286 "preproc.y" + { + (yyval.str) = mm_strdup("read committed"); +;} + break; + + case 212: + +/* Line 1455 of yacc.c */ +#line 2290 "preproc.y" + { + (yyval.str) = mm_strdup("repeatable read"); +;} + break; + + case 213: + +/* Line 1455 of yacc.c */ +#line 2294 "preproc.y" + { + (yyval.str) = mm_strdup("serializable"); +;} + break; + + case 214: + +/* Line 1455 of yacc.c */ +#line 2302 "preproc.y" + { + (yyval.str) = mm_strdup("true"); +;} + break; + + case 215: + +/* Line 1455 of yacc.c */ +#line 2306 "preproc.y" + { + (yyval.str) = mm_strdup("false"); +;} + break; + + case 216: + +/* Line 1455 of yacc.c */ +#line 2310 "preproc.y" + { + (yyval.str) = mm_strdup("on"); +;} + break; + + case 217: + +/* Line 1455 of yacc.c */ +#line 2314 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 218: + +/* Line 1455 of yacc.c */ +#line 2322 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 219: + +/* Line 1455 of yacc.c */ +#line 2326 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 220: + +/* Line 1455 of yacc.c */ +#line 2330 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 221: + +/* Line 1455 of yacc.c */ +#line 2334 "preproc.y" + { + (yyval.str) = cat_str(6,(yyvsp[(1) - (6)].str),mm_strdup("("),(yyvsp[(3) - (6)].str),mm_strdup(")"),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 222: + +/* Line 1455 of yacc.c */ +#line 2338 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 223: + +/* Line 1455 of yacc.c */ +#line 2342 "preproc.y" + { + (yyval.str) = mm_strdup("default"); +;} + break; + + case 224: + +/* Line 1455 of yacc.c */ +#line 2346 "preproc.y" + { + (yyval.str) = mm_strdup("local"); +;} + break; + + case 225: + +/* Line 1455 of yacc.c */ +#line 2354 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 226: + +/* Line 1455 of yacc.c */ +#line 2358 "preproc.y" + { + (yyval.str) = mm_strdup("default"); +;} + break; + + case 227: + +/* Line 1455 of yacc.c */ +#line 2362 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 228: + +/* Line 1455 of yacc.c */ +#line 2369 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 229: + +/* Line 1455 of yacc.c */ +#line 2373 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 230: + +/* Line 1455 of yacc.c */ +#line 2381 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("reset"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 231: + +/* Line 1455 of yacc.c */ +#line 2385 "preproc.y" + { + (yyval.str) = mm_strdup("reset time zone"); +;} + break; + + case 232: + +/* Line 1455 of yacc.c */ +#line 2389 "preproc.y" + { + (yyval.str) = mm_strdup("reset transaction isolation level"); +;} + break; + + case 233: + +/* Line 1455 of yacc.c */ +#line 2393 "preproc.y" + { + (yyval.str) = mm_strdup("reset session authorization"); +;} + break; + + case 234: + +/* Line 1455 of yacc.c */ +#line 2397 "preproc.y" + { + (yyval.str) = mm_strdup("reset all"); +;} + break; + + case 235: + +/* Line 1455 of yacc.c */ +#line 2405 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("set"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 236: + +/* Line 1455 of yacc.c */ +#line 2409 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 237: + +/* Line 1455 of yacc.c */ +#line 2417 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("set"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 238: + +/* Line 1455 of yacc.c */ +#line 2421 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 239: + +/* Line 1455 of yacc.c */ +#line 2429 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("show"),(yyvsp[(2) - (3)].str)); +;} + break; + + case 240: + +/* Line 1455 of yacc.c */ +#line 2433 "preproc.y" + { + (yyval.str) = mm_strdup("show time zone"); +;} + break; + + case 241: + +/* Line 1455 of yacc.c */ +#line 2437 "preproc.y" + { + (yyval.str) = mm_strdup("show transaction isolation level"); +;} + break; + + case 242: + +/* Line 1455 of yacc.c */ +#line 2441 "preproc.y" + { + (yyval.str) = mm_strdup("show session authorization"); +;} + break; + + case 243: + +/* Line 1455 of yacc.c */ +#line 2445 "preproc.y" + { + mmerror(PARSE_ERROR, ET_ERROR, "SHOW ALL is not implemented"); + (yyval.str) = EMPTY; + ;} + break; + + case 244: + +/* Line 1455 of yacc.c */ +#line 2454 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("set constraints"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 245: + +/* Line 1455 of yacc.c */ +#line 2462 "preproc.y" + { + (yyval.str) = mm_strdup("all"); +;} + break; + + case 246: + +/* Line 1455 of yacc.c */ +#line 2466 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 247: + +/* Line 1455 of yacc.c */ +#line 2474 "preproc.y" + { + (yyval.str) = mm_strdup("deferred"); +;} + break; + + case 248: + +/* Line 1455 of yacc.c */ +#line 2478 "preproc.y" + { + (yyval.str) = mm_strdup("immediate"); +;} + break; + + case 249: + +/* Line 1455 of yacc.c */ +#line 2486 "preproc.y" + { + (yyval.str) = mm_strdup("checkpoint"); +;} + break; + + case 250: + +/* Line 1455 of yacc.c */ +#line 2494 "preproc.y" + { + (yyval.str) = mm_strdup("discard all"); +;} + break; + + case 251: + +/* Line 1455 of yacc.c */ +#line 2498 "preproc.y" + { + (yyval.str) = mm_strdup("discard temp"); +;} + break; + + case 252: + +/* Line 1455 of yacc.c */ +#line 2502 "preproc.y" + { + (yyval.str) = mm_strdup("discard temporary"); +;} + break; + + case 253: + +/* Line 1455 of yacc.c */ +#line 2506 "preproc.y" + { + (yyval.str) = mm_strdup("discard plans"); +;} + break; + + case 254: + +/* Line 1455 of yacc.c */ +#line 2514 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("alter table"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 255: + +/* Line 1455 of yacc.c */ +#line 2518 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("alter table if exists"),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 256: + +/* Line 1455 of yacc.c */ +#line 2522 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("alter index"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 257: + +/* Line 1455 of yacc.c */ +#line 2526 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("alter index if exists"),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 258: + +/* Line 1455 of yacc.c */ +#line 2530 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("alter sequence"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 259: + +/* Line 1455 of yacc.c */ +#line 2534 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("alter sequence if exists"),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 260: + +/* Line 1455 of yacc.c */ +#line 2538 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("alter view"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 261: + +/* Line 1455 of yacc.c */ +#line 2542 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("alter view if exists"),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 262: + +/* Line 1455 of yacc.c */ +#line 2550 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 263: + +/* Line 1455 of yacc.c */ +#line 2554 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 264: + +/* Line 1455 of yacc.c */ +#line 2562 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("add"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 265: + +/* Line 1455 of yacc.c */ +#line 2566 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("add column"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 266: + +/* Line 1455 of yacc.c */ +#line 2570 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter"),(yyvsp[(2) - (4)].str),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 267: + +/* Line 1455 of yacc.c */ +#line 2574 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter"),(yyvsp[(2) - (6)].str),(yyvsp[(3) - (6)].str),mm_strdup("drop not null")); +;} + break; + + case 268: + +/* Line 1455 of yacc.c */ +#line 2578 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter"),(yyvsp[(2) - (6)].str),(yyvsp[(3) - (6)].str),mm_strdup("set not null")); +;} + break; + + case 269: + +/* Line 1455 of yacc.c */ +#line 2582 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter"),(yyvsp[(2) - (6)].str),(yyvsp[(3) - (6)].str),mm_strdup("set statistics"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 270: + +/* Line 1455 of yacc.c */ +#line 2586 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter"),(yyvsp[(2) - (5)].str),(yyvsp[(3) - (5)].str),mm_strdup("set"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 271: + +/* Line 1455 of yacc.c */ +#line 2590 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter"),(yyvsp[(2) - (5)].str),(yyvsp[(3) - (5)].str),mm_strdup("reset"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 272: + +/* Line 1455 of yacc.c */ +#line 2594 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter"),(yyvsp[(2) - (6)].str),(yyvsp[(3) - (6)].str),mm_strdup("set storage"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 273: + +/* Line 1455 of yacc.c */ +#line 2598 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("drop"),(yyvsp[(2) - (6)].str),mm_strdup("if exists"),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 274: + +/* Line 1455 of yacc.c */ +#line 2602 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("drop"),(yyvsp[(2) - (4)].str),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 275: + +/* Line 1455 of yacc.c */ +#line 2606 "preproc.y" + { + (yyval.str) = cat_str(8,mm_strdup("alter"),(yyvsp[(2) - (8)].str),(yyvsp[(3) - (8)].str),(yyvsp[(4) - (8)].str),mm_strdup("type"),(yyvsp[(6) - (8)].str),(yyvsp[(7) - (8)].str),(yyvsp[(8) - (8)].str)); +;} + break; + + case 276: + +/* Line 1455 of yacc.c */ +#line 2610 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter"),(yyvsp[(2) - (4)].str),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 277: + +/* Line 1455 of yacc.c */ +#line 2614 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("add"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 278: + +/* Line 1455 of yacc.c */ +#line 2618 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("validate constraint"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 279: + +/* Line 1455 of yacc.c */ +#line 2622 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("drop constraint if exists"),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 280: + +/* Line 1455 of yacc.c */ +#line 2626 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("drop constraint"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 281: + +/* Line 1455 of yacc.c */ +#line 2630 "preproc.y" + { + (yyval.str) = mm_strdup("set with oids"); +;} + break; + + case 282: + +/* Line 1455 of yacc.c */ +#line 2634 "preproc.y" + { + (yyval.str) = mm_strdup("set without oids"); +;} + break; + + case 283: + +/* Line 1455 of yacc.c */ +#line 2638 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("cluster on"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 284: + +/* Line 1455 of yacc.c */ +#line 2642 "preproc.y" + { + (yyval.str) = mm_strdup("set without cluster"); +;} + break; + + case 285: + +/* Line 1455 of yacc.c */ +#line 2646 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("enable trigger"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 286: + +/* Line 1455 of yacc.c */ +#line 2650 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("enable always trigger"),(yyvsp[(4) - (4)].str)); +;} + break; + + case 287: + +/* Line 1455 of yacc.c */ +#line 2654 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("enable replica trigger"),(yyvsp[(4) - (4)].str)); +;} + break; + + case 288: + +/* Line 1455 of yacc.c */ +#line 2658 "preproc.y" + { + (yyval.str) = mm_strdup("enable trigger all"); +;} + break; + + case 289: + +/* Line 1455 of yacc.c */ +#line 2662 "preproc.y" + { + (yyval.str) = mm_strdup("enable trigger user"); +;} + break; + + case 290: + +/* Line 1455 of yacc.c */ +#line 2666 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("disable trigger"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 291: + +/* Line 1455 of yacc.c */ +#line 2670 "preproc.y" + { + (yyval.str) = mm_strdup("disable trigger all"); +;} + break; + + case 292: + +/* Line 1455 of yacc.c */ +#line 2674 "preproc.y" + { + (yyval.str) = mm_strdup("disable trigger user"); +;} + break; + + case 293: + +/* Line 1455 of yacc.c */ +#line 2678 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("enable rule"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 294: + +/* Line 1455 of yacc.c */ +#line 2682 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("enable always rule"),(yyvsp[(4) - (4)].str)); +;} + break; + + case 295: + +/* Line 1455 of yacc.c */ +#line 2686 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("enable replica rule"),(yyvsp[(4) - (4)].str)); +;} + break; + + case 296: + +/* Line 1455 of yacc.c */ +#line 2690 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("disable rule"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 297: + +/* Line 1455 of yacc.c */ +#line 2694 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("inherit"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 298: + +/* Line 1455 of yacc.c */ +#line 2698 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("no inherit"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 299: + +/* Line 1455 of yacc.c */ +#line 2702 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("of"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 300: + +/* Line 1455 of yacc.c */ +#line 2706 "preproc.y" + { + (yyval.str) = mm_strdup("not of"); +;} + break; + + case 301: + +/* Line 1455 of yacc.c */ +#line 2710 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("owner to"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 302: + +/* Line 1455 of yacc.c */ +#line 2714 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("set tablespace"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 303: + +/* Line 1455 of yacc.c */ +#line 2718 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("set"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 304: + +/* Line 1455 of yacc.c */ +#line 2722 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("reset"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 305: + +/* Line 1455 of yacc.c */ +#line 2726 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 306: + +/* Line 1455 of yacc.c */ +#line 2734 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("set default"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 307: + +/* Line 1455 of yacc.c */ +#line 2738 "preproc.y" + { + (yyval.str) = mm_strdup("drop default"); +;} + break; + + case 308: + +/* Line 1455 of yacc.c */ +#line 2746 "preproc.y" + { + (yyval.str) = mm_strdup("cascade"); +;} + break; + + case 309: + +/* Line 1455 of yacc.c */ +#line 2750 "preproc.y" + { + (yyval.str) = mm_strdup("restrict"); +;} + break; + + case 310: + +/* Line 1455 of yacc.c */ +#line 2754 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 311: + +/* Line 1455 of yacc.c */ +#line 2761 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("collate"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 312: + +/* Line 1455 of yacc.c */ +#line 2765 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 313: + +/* Line 1455 of yacc.c */ +#line 2772 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("using"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 314: + +/* Line 1455 of yacc.c */ +#line 2776 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 315: + +/* Line 1455 of yacc.c */ +#line 2783 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (3)].str),mm_strdup(")")); +;} + break; + + case 316: + +/* Line 1455 of yacc.c */ +#line 2791 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("with"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 317: + +/* Line 1455 of yacc.c */ +#line 2795 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 318: + +/* Line 1455 of yacc.c */ +#line 2802 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 319: + +/* Line 1455 of yacc.c */ +#line 2806 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 320: + +/* Line 1455 of yacc.c */ +#line 2814 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("="),(yyvsp[(3) - (3)].str)); +;} + break; + + case 321: + +/* Line 1455 of yacc.c */ +#line 2818 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 322: + +/* Line 1455 of yacc.c */ +#line 2822 "preproc.y" + { + (yyval.str) = cat_str(5,(yyvsp[(1) - (5)].str),mm_strdup("."),(yyvsp[(3) - (5)].str),mm_strdup("="),(yyvsp[(5) - (5)].str)); +;} + break; + + case 323: + +/* Line 1455 of yacc.c */ +#line 2826 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("."),(yyvsp[(3) - (3)].str)); +;} + break; + + case 324: + +/* Line 1455 of yacc.c */ +#line 2834 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("alter type"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 325: + +/* Line 1455 of yacc.c */ +#line 2842 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 326: + +/* Line 1455 of yacc.c */ +#line 2846 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 327: + +/* Line 1455 of yacc.c */ +#line 2854 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("add attribute"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 328: + +/* Line 1455 of yacc.c */ +#line 2858 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("drop attribute if exists"),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 329: + +/* Line 1455 of yacc.c */ +#line 2862 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("drop attribute"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 330: + +/* Line 1455 of yacc.c */ +#line 2866 "preproc.y" + { + (yyval.str) = cat_str(7,mm_strdup("alter attribute"),(yyvsp[(3) - (8)].str),(yyvsp[(4) - (8)].str),mm_strdup("type"),(yyvsp[(6) - (8)].str),(yyvsp[(7) - (8)].str),(yyvsp[(8) - (8)].str)); +;} + break; + + case 331: + +/* Line 1455 of yacc.c */ +#line 2874 "preproc.y" + { + char *cursor_marker = (yyvsp[(2) - (2)].str)[0] == ':' ? mm_strdup("$0") : (yyvsp[(2) - (2)].str); + (yyval.str) = cat2_str(mm_strdup("close"), cursor_marker); + ;} + break; + + case 332: + +/* Line 1455 of yacc.c */ +#line 2879 "preproc.y" + { + (yyval.str) = mm_strdup("close all"); +;} + break; + + case 333: + +/* Line 1455 of yacc.c */ +#line 2887 "preproc.y" + { + if (strcmp((yyvsp[(6) - (10)].str), "to") == 0 && strcmp((yyvsp[(7) - (10)].str), "stdin") == 0) + mmerror(PARSE_ERROR, ET_ERROR, "COPY TO STDIN is not possible"); + else if (strcmp((yyvsp[(6) - (10)].str), "from") == 0 && strcmp((yyvsp[(7) - (10)].str), "stdout") == 0) + mmerror(PARSE_ERROR, ET_ERROR, "COPY FROM STDOUT is not possible"); + else if (strcmp((yyvsp[(6) - (10)].str), "from") == 0 && strcmp((yyvsp[(7) - (10)].str), "stdin") == 0) + mmerror(PARSE_ERROR, ET_WARNING, "COPY FROM STDIN is not implemented"); + + (yyval.str) = cat_str(10,mm_strdup("copy"),(yyvsp[(2) - (10)].str),(yyvsp[(3) - (10)].str),(yyvsp[(4) - (10)].str),(yyvsp[(5) - (10)].str),(yyvsp[(6) - (10)].str),(yyvsp[(7) - (10)].str),(yyvsp[(8) - (10)].str),(yyvsp[(9) - (10)].str),(yyvsp[(10) - (10)].str)); +;} + break; + + case 334: + +/* Line 1455 of yacc.c */ +#line 2898 "preproc.y" + { + if (strcmp((yyvsp[(4) - (6)].str), "stdin") == 0) + mmerror(PARSE_ERROR, ET_ERROR, "COPY TO STDIN is not possible"); + + (yyval.str) = cat_str(6,mm_strdup("copy"),(yyvsp[(2) - (6)].str),mm_strdup("to"),(yyvsp[(4) - (6)].str),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 335: + +/* Line 1455 of yacc.c */ +#line 2909 "preproc.y" + { + (yyval.str) = mm_strdup("from"); +;} + break; + + case 336: + +/* Line 1455 of yacc.c */ +#line 2913 "preproc.y" + { + (yyval.str) = mm_strdup("to"); +;} + break; + + case 337: + +/* Line 1455 of yacc.c */ +#line 2921 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 338: + +/* Line 1455 of yacc.c */ +#line 2925 "preproc.y" + { + (yyval.str) = mm_strdup("stdin"); +;} + break; + + case 339: + +/* Line 1455 of yacc.c */ +#line 2929 "preproc.y" + { + (yyval.str) = mm_strdup("stdout"); +;} + break; + + case 340: + +/* Line 1455 of yacc.c */ +#line 2937 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 341: + +/* Line 1455 of yacc.c */ +#line 2941 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (3)].str),mm_strdup(")")); +;} + break; + + case 342: + +/* Line 1455 of yacc.c */ +#line 2949 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 343: + +/* Line 1455 of yacc.c */ +#line 2953 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 344: + +/* Line 1455 of yacc.c */ +#line 2960 "preproc.y" + { + (yyval.str) = mm_strdup("binary"); +;} + break; + + case 345: + +/* Line 1455 of yacc.c */ +#line 2964 "preproc.y" + { + (yyval.str) = mm_strdup("oids"); +;} + break; + + case 346: + +/* Line 1455 of yacc.c */ +#line 2968 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("delimiter"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 347: + +/* Line 1455 of yacc.c */ +#line 2972 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("null"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 348: + +/* Line 1455 of yacc.c */ +#line 2976 "preproc.y" + { + (yyval.str) = mm_strdup("csv"); +;} + break; + + case 349: + +/* Line 1455 of yacc.c */ +#line 2980 "preproc.y" + { + (yyval.str) = mm_strdup("header"); +;} + break; + + case 350: + +/* Line 1455 of yacc.c */ +#line 2984 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("quote"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 351: + +/* Line 1455 of yacc.c */ +#line 2988 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("escape"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 352: + +/* Line 1455 of yacc.c */ +#line 2992 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("force quote"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 353: + +/* Line 1455 of yacc.c */ +#line 2996 "preproc.y" + { + (yyval.str) = mm_strdup("force quote *"); +;} + break; + + case 354: + +/* Line 1455 of yacc.c */ +#line 3000 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("force not null"),(yyvsp[(4) - (4)].str)); +;} + break; + + case 355: + +/* Line 1455 of yacc.c */ +#line 3004 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("encoding"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 356: + +/* Line 1455 of yacc.c */ +#line 3012 "preproc.y" + { + (yyval.str) = mm_strdup("binary"); +;} + break; + + case 357: + +/* Line 1455 of yacc.c */ +#line 3016 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 358: + +/* Line 1455 of yacc.c */ +#line 3023 "preproc.y" + { + (yyval.str) = mm_strdup("with oids"); +;} + break; + + case 359: + +/* Line 1455 of yacc.c */ +#line 3027 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 360: + +/* Line 1455 of yacc.c */ +#line 3034 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("delimiters"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 361: + +/* Line 1455 of yacc.c */ +#line 3038 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 362: + +/* Line 1455 of yacc.c */ +#line 3045 "preproc.y" + { + (yyval.str) = mm_strdup("using"); +;} + break; + + case 363: + +/* Line 1455 of yacc.c */ +#line 3049 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 364: + +/* Line 1455 of yacc.c */ +#line 3056 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 365: + +/* Line 1455 of yacc.c */ +#line 3060 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 366: + +/* Line 1455 of yacc.c */ +#line 3068 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 367: + +/* Line 1455 of yacc.c */ +#line 3076 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 368: + +/* Line 1455 of yacc.c */ +#line 3080 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 369: + +/* Line 1455 of yacc.c */ +#line 3084 "preproc.y" + { + (yyval.str) = mm_strdup("*"); +;} + break; + + case 370: + +/* Line 1455 of yacc.c */ +#line 3088 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (3)].str),mm_strdup(")")); +;} + break; + + case 371: + +/* Line 1455 of yacc.c */ +#line 3092 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 372: + +/* Line 1455 of yacc.c */ +#line 3099 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 373: + +/* Line 1455 of yacc.c */ +#line 3103 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 374: + +/* Line 1455 of yacc.c */ +#line 3111 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 375: + +/* Line 1455 of yacc.c */ +#line 3119 "preproc.y" + { + (yyval.str) = cat_str(11,mm_strdup("create"),(yyvsp[(2) - (11)].str),mm_strdup("table"),(yyvsp[(4) - (11)].str),mm_strdup("("),(yyvsp[(6) - (11)].str),mm_strdup(")"),(yyvsp[(8) - (11)].str),(yyvsp[(9) - (11)].str),(yyvsp[(10) - (11)].str),(yyvsp[(11) - (11)].str)); +;} + break; + + case 376: + +/* Line 1455 of yacc.c */ +#line 3123 "preproc.y" + { + (yyval.str) = cat_str(11,mm_strdup("create"),(yyvsp[(2) - (14)].str),mm_strdup("table if not exists"),(yyvsp[(7) - (14)].str),mm_strdup("("),(yyvsp[(9) - (14)].str),mm_strdup(")"),(yyvsp[(11) - (14)].str),(yyvsp[(12) - (14)].str),(yyvsp[(13) - (14)].str),(yyvsp[(14) - (14)].str)); +;} + break; + + case 377: + +/* Line 1455 of yacc.c */ +#line 3127 "preproc.y" + { + (yyval.str) = cat_str(10,mm_strdup("create"),(yyvsp[(2) - (10)].str),mm_strdup("table"),(yyvsp[(4) - (10)].str),mm_strdup("of"),(yyvsp[(6) - (10)].str),(yyvsp[(7) - (10)].str),(yyvsp[(8) - (10)].str),(yyvsp[(9) - (10)].str),(yyvsp[(10) - (10)].str)); +;} + break; + + case 378: + +/* Line 1455 of yacc.c */ +#line 3131 "preproc.y" + { + (yyval.str) = cat_str(10,mm_strdup("create"),(yyvsp[(2) - (13)].str),mm_strdup("table if not exists"),(yyvsp[(7) - (13)].str),mm_strdup("of"),(yyvsp[(9) - (13)].str),(yyvsp[(10) - (13)].str),(yyvsp[(11) - (13)].str),(yyvsp[(12) - (13)].str),(yyvsp[(13) - (13)].str)); +;} + break; + + case 379: + +/* Line 1455 of yacc.c */ +#line 3139 "preproc.y" + { + (yyval.str) = mm_strdup("temporary"); +;} + break; + + case 380: + +/* Line 1455 of yacc.c */ +#line 3143 "preproc.y" + { + (yyval.str) = mm_strdup("temp"); +;} + break; + + case 381: + +/* Line 1455 of yacc.c */ +#line 3147 "preproc.y" + { + (yyval.str) = mm_strdup("local temporary"); +;} + break; + + case 382: + +/* Line 1455 of yacc.c */ +#line 3151 "preproc.y" + { + (yyval.str) = mm_strdup("local temp"); +;} + break; + + case 383: + +/* Line 1455 of yacc.c */ +#line 3155 "preproc.y" + { + (yyval.str) = mm_strdup("global temporary"); +;} + break; + + case 384: + +/* Line 1455 of yacc.c */ +#line 3159 "preproc.y" + { + (yyval.str) = mm_strdup("global temp"); +;} + break; + + case 385: + +/* Line 1455 of yacc.c */ +#line 3163 "preproc.y" + { + (yyval.str) = mm_strdup("unlogged"); +;} + break; + + case 386: + +/* Line 1455 of yacc.c */ +#line 3167 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 387: + +/* Line 1455 of yacc.c */ +#line 3174 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 388: + +/* Line 1455 of yacc.c */ +#line 3178 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 389: + +/* Line 1455 of yacc.c */ +#line 3185 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (3)].str),mm_strdup(")")); +;} + break; + + case 390: + +/* Line 1455 of yacc.c */ +#line 3189 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 391: + +/* Line 1455 of yacc.c */ +#line 3196 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 392: + +/* Line 1455 of yacc.c */ +#line 3200 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 393: + +/* Line 1455 of yacc.c */ +#line 3208 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 394: + +/* Line 1455 of yacc.c */ +#line 3212 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 395: + +/* Line 1455 of yacc.c */ +#line 3220 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 396: + +/* Line 1455 of yacc.c */ +#line 3224 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 397: + +/* Line 1455 of yacc.c */ +#line 3228 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 398: + +/* Line 1455 of yacc.c */ +#line 3236 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 399: + +/* Line 1455 of yacc.c */ +#line 3240 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 400: + +/* Line 1455 of yacc.c */ +#line 3248 "preproc.y" + { + (yyval.str) = cat_str(4,(yyvsp[(1) - (4)].str),(yyvsp[(2) - (4)].str),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 401: + +/* Line 1455 of yacc.c */ +#line 3256 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (4)].str),mm_strdup("with options"),(yyvsp[(4) - (4)].str)); +;} + break; + + case 402: + +/* Line 1455 of yacc.c */ +#line 3264 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 403: + +/* Line 1455 of yacc.c */ +#line 3268 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 404: + +/* Line 1455 of yacc.c */ +#line 3275 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("constraint"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 405: + +/* Line 1455 of yacc.c */ +#line 3279 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 406: + +/* Line 1455 of yacc.c */ +#line 3283 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 407: + +/* Line 1455 of yacc.c */ +#line 3287 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("collate"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 408: + +/* Line 1455 of yacc.c */ +#line 3295 "preproc.y" + { + (yyval.str) = mm_strdup("not null"); +;} + break; + + case 409: + +/* Line 1455 of yacc.c */ +#line 3299 "preproc.y" + { + (yyval.str) = mm_strdup("null"); +;} + break; + + case 410: + +/* Line 1455 of yacc.c */ +#line 3303 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("unique"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 411: + +/* Line 1455 of yacc.c */ +#line 3307 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("primary key"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 412: + +/* Line 1455 of yacc.c */ +#line 3311 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("check ("),(yyvsp[(3) - (5)].str),mm_strdup(")"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 413: + +/* Line 1455 of yacc.c */ +#line 3315 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("default"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 414: + +/* Line 1455 of yacc.c */ +#line 3319 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("references"),(yyvsp[(2) - (5)].str),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 415: + +/* Line 1455 of yacc.c */ +#line 3327 "preproc.y" + { + (yyval.str) = mm_strdup("deferrable"); +;} + break; + + case 416: + +/* Line 1455 of yacc.c */ +#line 3331 "preproc.y" + { + (yyval.str) = mm_strdup("not deferrable"); +;} + break; + + case 417: + +/* Line 1455 of yacc.c */ +#line 3335 "preproc.y" + { + (yyval.str) = mm_strdup("initially deferred"); +;} + break; + + case 418: + +/* Line 1455 of yacc.c */ +#line 3339 "preproc.y" + { + (yyval.str) = mm_strdup("initially immediate"); +;} + break; + + case 419: + +/* Line 1455 of yacc.c */ +#line 3347 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("like"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 420: + +/* Line 1455 of yacc.c */ +#line 3355 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("including"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 421: + +/* Line 1455 of yacc.c */ +#line 3359 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("excluding"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 422: + +/* Line 1455 of yacc.c */ +#line 3363 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 423: + +/* Line 1455 of yacc.c */ +#line 3370 "preproc.y" + { + (yyval.str) = mm_strdup("defaults"); +;} + break; + + case 424: + +/* Line 1455 of yacc.c */ +#line 3374 "preproc.y" + { + (yyval.str) = mm_strdup("constraints"); +;} + break; + + case 425: + +/* Line 1455 of yacc.c */ +#line 3378 "preproc.y" + { + (yyval.str) = mm_strdup("indexes"); +;} + break; + + case 426: + +/* Line 1455 of yacc.c */ +#line 3382 "preproc.y" + { + (yyval.str) = mm_strdup("storage"); +;} + break; + + case 427: + +/* Line 1455 of yacc.c */ +#line 3386 "preproc.y" + { + (yyval.str) = mm_strdup("comments"); +;} + break; + + case 428: + +/* Line 1455 of yacc.c */ +#line 3390 "preproc.y" + { + (yyval.str) = mm_strdup("all"); +;} + break; + + case 429: + +/* Line 1455 of yacc.c */ +#line 3398 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("constraint"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 430: + +/* Line 1455 of yacc.c */ +#line 3402 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 431: + +/* Line 1455 of yacc.c */ +#line 3410 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("check ("),(yyvsp[(3) - (5)].str),mm_strdup(")"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 432: + +/* Line 1455 of yacc.c */ +#line 3414 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("unique ("),(yyvsp[(3) - (7)].str),mm_strdup(")"),(yyvsp[(5) - (7)].str),(yyvsp[(6) - (7)].str),(yyvsp[(7) - (7)].str)); +;} + break; + + case 433: + +/* Line 1455 of yacc.c */ +#line 3418 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("unique"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 434: + +/* Line 1455 of yacc.c */ +#line 3422 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("primary key ("),(yyvsp[(4) - (8)].str),mm_strdup(")"),(yyvsp[(6) - (8)].str),(yyvsp[(7) - (8)].str),(yyvsp[(8) - (8)].str)); +;} + break; + + case 435: + +/* Line 1455 of yacc.c */ +#line 3426 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("primary key"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 436: + +/* Line 1455 of yacc.c */ +#line 3430 "preproc.y" + { + (yyval.str) = cat_str(9,mm_strdup("exclude"),(yyvsp[(2) - (9)].str),mm_strdup("("),(yyvsp[(4) - (9)].str),mm_strdup(")"),(yyvsp[(6) - (9)].str),(yyvsp[(7) - (9)].str),(yyvsp[(8) - (9)].str),(yyvsp[(9) - (9)].str)); +;} + break; + + case 437: + +/* Line 1455 of yacc.c */ +#line 3434 "preproc.y" + { + (yyval.str) = cat_str(8,mm_strdup("foreign key ("),(yyvsp[(4) - (11)].str),mm_strdup(") references"),(yyvsp[(7) - (11)].str),(yyvsp[(8) - (11)].str),(yyvsp[(9) - (11)].str),(yyvsp[(10) - (11)].str),(yyvsp[(11) - (11)].str)); +;} + break; + + case 438: + +/* Line 1455 of yacc.c */ +#line 3442 "preproc.y" + { + (yyval.str) = mm_strdup("no inherit"); +;} + break; + + case 439: + +/* Line 1455 of yacc.c */ +#line 3446 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 440: + +/* Line 1455 of yacc.c */ +#line 3453 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (3)].str),mm_strdup(")")); +;} + break; + + case 441: + +/* Line 1455 of yacc.c */ +#line 3457 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 442: + +/* Line 1455 of yacc.c */ +#line 3464 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 443: + +/* Line 1455 of yacc.c */ +#line 3468 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 444: + +/* Line 1455 of yacc.c */ +#line 3476 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 445: + +/* Line 1455 of yacc.c */ +#line 3484 "preproc.y" + { + (yyval.str) = mm_strdup("match full"); +;} + break; + + case 446: + +/* Line 1455 of yacc.c */ +#line 3488 "preproc.y" + { +mmerror(PARSE_ERROR, ET_WARNING, "unsupported feature will be passed to server"); + (yyval.str) = mm_strdup("match partial"); +;} + break; + + case 447: + +/* Line 1455 of yacc.c */ +#line 3493 "preproc.y" + { + (yyval.str) = mm_strdup("match simple"); +;} + break; + + case 448: + +/* Line 1455 of yacc.c */ +#line 3497 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 449: + +/* Line 1455 of yacc.c */ +#line 3504 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 450: + +/* Line 1455 of yacc.c */ +#line 3508 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 451: + +/* Line 1455 of yacc.c */ +#line 3516 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("with"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 452: + +/* Line 1455 of yacc.c */ +#line 3520 "preproc.y" + { + (yyval.str) = cat_str(4,(yyvsp[(1) - (6)].str),mm_strdup("with operator ("),(yyvsp[(5) - (6)].str),mm_strdup(")")); +;} + break; + + case 453: + +/* Line 1455 of yacc.c */ +#line 3528 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("where ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 454: + +/* Line 1455 of yacc.c */ +#line 3532 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 455: + +/* Line 1455 of yacc.c */ +#line 3539 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 456: + +/* Line 1455 of yacc.c */ +#line 3543 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 457: + +/* Line 1455 of yacc.c */ +#line 3547 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 458: + +/* Line 1455 of yacc.c */ +#line 3551 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 459: + +/* Line 1455 of yacc.c */ +#line 3555 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 460: + +/* Line 1455 of yacc.c */ +#line 3562 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("on update"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 461: + +/* Line 1455 of yacc.c */ +#line 3570 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("on delete"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 462: + +/* Line 1455 of yacc.c */ +#line 3578 "preproc.y" + { + (yyval.str) = mm_strdup("no action"); +;} + break; + + case 463: + +/* Line 1455 of yacc.c */ +#line 3582 "preproc.y" + { + (yyval.str) = mm_strdup("restrict"); +;} + break; + + case 464: + +/* Line 1455 of yacc.c */ +#line 3586 "preproc.y" + { + (yyval.str) = mm_strdup("cascade"); +;} + break; + + case 465: + +/* Line 1455 of yacc.c */ +#line 3590 "preproc.y" + { + (yyval.str) = mm_strdup("set null"); +;} + break; + + case 466: + +/* Line 1455 of yacc.c */ +#line 3594 "preproc.y" + { + (yyval.str) = mm_strdup("set default"); +;} + break; + + case 467: + +/* Line 1455 of yacc.c */ +#line 3602 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("inherits ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 468: + +/* Line 1455 of yacc.c */ +#line 3606 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 469: + +/* Line 1455 of yacc.c */ +#line 3613 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("with"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 470: + +/* Line 1455 of yacc.c */ +#line 3617 "preproc.y" + { + (yyval.str) = mm_strdup("with oids"); +;} + break; + + case 471: + +/* Line 1455 of yacc.c */ +#line 3621 "preproc.y" + { + (yyval.str) = mm_strdup("without oids"); +;} + break; + + case 472: + +/* Line 1455 of yacc.c */ +#line 3625 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 473: + +/* Line 1455 of yacc.c */ +#line 3632 "preproc.y" + { + (yyval.str) = mm_strdup("on commit drop"); +;} + break; + + case 474: + +/* Line 1455 of yacc.c */ +#line 3636 "preproc.y" + { + (yyval.str) = mm_strdup("on commit delete rows"); +;} + break; + + case 475: + +/* Line 1455 of yacc.c */ +#line 3640 "preproc.y" + { + (yyval.str) = mm_strdup("on commit preserve rows"); +;} + break; + + case 476: + +/* Line 1455 of yacc.c */ +#line 3644 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 477: + +/* Line 1455 of yacc.c */ +#line 3651 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("tablespace"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 478: + +/* Line 1455 of yacc.c */ +#line 3655 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 479: + +/* Line 1455 of yacc.c */ +#line 3662 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("using index tablespace"),(yyvsp[(4) - (4)].str)); +;} + break; + + case 480: + +/* Line 1455 of yacc.c */ +#line 3666 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 481: + +/* Line 1455 of yacc.c */ +#line 3673 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("using index"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 482: + +/* Line 1455 of yacc.c */ +#line 3681 "preproc.y" + { + (yyval.str) = cat_str(5,(yyvsp[(1) - (5)].str),(yyvsp[(2) - (5)].str),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 483: + +/* Line 1455 of yacc.c */ +#line 3689 "preproc.y" + { + (yyval.str) = mm_strdup("with data"); +;} + break; + + case 484: + +/* Line 1455 of yacc.c */ +#line 3693 "preproc.y" + { + (yyval.str) = mm_strdup("with no data"); +;} + break; + + case 485: + +/* Line 1455 of yacc.c */ +#line 3697 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 486: + +/* Line 1455 of yacc.c */ +#line 3704 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("create"),(yyvsp[(2) - (5)].str),mm_strdup("sequence"),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 487: + +/* Line 1455 of yacc.c */ +#line 3712 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("alter sequence"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 488: + +/* Line 1455 of yacc.c */ +#line 3716 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("alter sequence if exists"),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 489: + +/* Line 1455 of yacc.c */ +#line 3724 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 490: + +/* Line 1455 of yacc.c */ +#line 3728 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 491: + +/* Line 1455 of yacc.c */ +#line 3735 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 492: + +/* Line 1455 of yacc.c */ +#line 3739 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 493: + +/* Line 1455 of yacc.c */ +#line 3747 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("cache"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 494: + +/* Line 1455 of yacc.c */ +#line 3751 "preproc.y" + { + (yyval.str) = mm_strdup("cycle"); +;} + break; + + case 495: + +/* Line 1455 of yacc.c */ +#line 3755 "preproc.y" + { + (yyval.str) = mm_strdup("no cycle"); +;} + break; + + case 496: + +/* Line 1455 of yacc.c */ +#line 3759 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("increment"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 497: + +/* Line 1455 of yacc.c */ +#line 3763 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("maxvalue"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 498: + +/* Line 1455 of yacc.c */ +#line 3767 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("minvalue"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 499: + +/* Line 1455 of yacc.c */ +#line 3771 "preproc.y" + { + (yyval.str) = mm_strdup("no maxvalue"); +;} + break; + + case 500: + +/* Line 1455 of yacc.c */ +#line 3775 "preproc.y" + { + (yyval.str) = mm_strdup("no minvalue"); +;} + break; + + case 501: + +/* Line 1455 of yacc.c */ +#line 3779 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("owned by"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 502: + +/* Line 1455 of yacc.c */ +#line 3783 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("start"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 503: + +/* Line 1455 of yacc.c */ +#line 3787 "preproc.y" + { + (yyval.str) = mm_strdup("restart"); +;} + break; + + case 504: + +/* Line 1455 of yacc.c */ +#line 3791 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("restart"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 505: + +/* Line 1455 of yacc.c */ +#line 3799 "preproc.y" + { + (yyval.str) = mm_strdup("by"); +;} + break; + + case 506: + +/* Line 1455 of yacc.c */ +#line 3803 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 507: + +/* Line 1455 of yacc.c */ +#line 3810 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 508: + +/* Line 1455 of yacc.c */ +#line 3814 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("-"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 509: + +/* Line 1455 of yacc.c */ +#line 3818 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 510: + +/* Line 1455 of yacc.c */ +#line 3826 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 511: + +/* Line 1455 of yacc.c */ +#line 3830 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 512: + +/* Line 1455 of yacc.c */ +#line 3838 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("create"),(yyvsp[(2) - (6)].str),(yyvsp[(3) - (6)].str),(yyvsp[(4) - (6)].str),mm_strdup("language"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 513: + +/* Line 1455 of yacc.c */ +#line 3842 "preproc.y" + { + (yyval.str) = cat_str(10,mm_strdup("create"),(yyvsp[(2) - (10)].str),(yyvsp[(3) - (10)].str),(yyvsp[(4) - (10)].str),mm_strdup("language"),(yyvsp[(6) - (10)].str),mm_strdup("handler"),(yyvsp[(8) - (10)].str),(yyvsp[(9) - (10)].str),(yyvsp[(10) - (10)].str)); +;} + break; + + case 514: + +/* Line 1455 of yacc.c */ +#line 3850 "preproc.y" + { + (yyval.str) = mm_strdup("trusted"); +;} + break; + + case 515: + +/* Line 1455 of yacc.c */ +#line 3854 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 516: + +/* Line 1455 of yacc.c */ +#line 3861 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 517: + +/* Line 1455 of yacc.c */ +#line 3865 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 518: + +/* Line 1455 of yacc.c */ +#line 3873 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("inline"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 519: + +/* Line 1455 of yacc.c */ +#line 3877 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 520: + +/* Line 1455 of yacc.c */ +#line 3884 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("validator"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 521: + +/* Line 1455 of yacc.c */ +#line 3888 "preproc.y" + { + (yyval.str) = mm_strdup("no validator"); +;} + break; + + case 522: + +/* Line 1455 of yacc.c */ +#line 3896 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 523: + +/* Line 1455 of yacc.c */ +#line 3900 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 524: + +/* Line 1455 of yacc.c */ +#line 3907 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("drop"),(yyvsp[(2) - (5)].str),mm_strdup("language"),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 525: + +/* Line 1455 of yacc.c */ +#line 3911 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("drop"),(yyvsp[(2) - (7)].str),mm_strdup("language if exists"),(yyvsp[(6) - (7)].str),(yyvsp[(7) - (7)].str)); +;} + break; + + case 526: + +/* Line 1455 of yacc.c */ +#line 3919 "preproc.y" + { + (yyval.str) = mm_strdup("procedural"); +;} + break; + + case 527: + +/* Line 1455 of yacc.c */ +#line 3923 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 528: + +/* Line 1455 of yacc.c */ +#line 3930 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("create tablespace"),(yyvsp[(3) - (6)].str),(yyvsp[(4) - (6)].str),mm_strdup("location"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 529: + +/* Line 1455 of yacc.c */ +#line 3938 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("owner"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 530: + +/* Line 1455 of yacc.c */ +#line 3942 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 531: + +/* Line 1455 of yacc.c */ +#line 3949 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("drop tablespace"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 532: + +/* Line 1455 of yacc.c */ +#line 3953 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("drop tablespace if exists"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 533: + +/* Line 1455 of yacc.c */ +#line 3961 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("create extension"),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 534: + +/* Line 1455 of yacc.c */ +#line 3965 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("create extension if not exists"),(yyvsp[(6) - (8)].str),(yyvsp[(7) - (8)].str),(yyvsp[(8) - (8)].str)); +;} + break; + + case 535: + +/* Line 1455 of yacc.c */ +#line 3973 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 536: + +/* Line 1455 of yacc.c */ +#line 3977 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 537: + +/* Line 1455 of yacc.c */ +#line 3984 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("schema"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 538: + +/* Line 1455 of yacc.c */ +#line 3988 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("version"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 539: + +/* Line 1455 of yacc.c */ +#line 3992 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("from"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 540: + +/* Line 1455 of yacc.c */ +#line 4000 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter extension"),(yyvsp[(3) - (5)].str),mm_strdup("update"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 541: + +/* Line 1455 of yacc.c */ +#line 4008 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 542: + +/* Line 1455 of yacc.c */ +#line 4012 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 543: + +/* Line 1455 of yacc.c */ +#line 4019 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("to"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 544: + +/* Line 1455 of yacc.c */ +#line 4027 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("alter extension"),(yyvsp[(3) - (7)].str),(yyvsp[(4) - (7)].str),mm_strdup("aggregate"),(yyvsp[(6) - (7)].str),(yyvsp[(7) - (7)].str)); +;} + break; + + case 545: + +/* Line 1455 of yacc.c */ +#line 4031 "preproc.y" + { + (yyval.str) = cat_str(8,mm_strdup("alter extension"),(yyvsp[(3) - (10)].str),(yyvsp[(4) - (10)].str),mm_strdup("cast ("),(yyvsp[(7) - (10)].str),mm_strdup("as"),(yyvsp[(9) - (10)].str),mm_strdup(")")); +;} + break; + + case 546: + +/* Line 1455 of yacc.c */ +#line 4035 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter extension"),(yyvsp[(3) - (6)].str),(yyvsp[(4) - (6)].str),mm_strdup("collation"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 547: + +/* Line 1455 of yacc.c */ +#line 4039 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter extension"),(yyvsp[(3) - (6)].str),(yyvsp[(4) - (6)].str),mm_strdup("conversion"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 548: + +/* Line 1455 of yacc.c */ +#line 4043 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter extension"),(yyvsp[(3) - (6)].str),(yyvsp[(4) - (6)].str),mm_strdup("domain"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 549: + +/* Line 1455 of yacc.c */ +#line 4047 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter extension"),(yyvsp[(3) - (6)].str),(yyvsp[(4) - (6)].str),mm_strdup("function"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 550: + +/* Line 1455 of yacc.c */ +#line 4051 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("alter extension"),(yyvsp[(3) - (7)].str),(yyvsp[(4) - (7)].str),(yyvsp[(5) - (7)].str),mm_strdup("language"),(yyvsp[(7) - (7)].str)); +;} + break; + + case 551: + +/* Line 1455 of yacc.c */ +#line 4055 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("alter extension"),(yyvsp[(3) - (7)].str),(yyvsp[(4) - (7)].str),mm_strdup("operator"),(yyvsp[(6) - (7)].str),(yyvsp[(7) - (7)].str)); +;} + break; + + case 552: + +/* Line 1455 of yacc.c */ +#line 4059 "preproc.y" + { + (yyval.str) = cat_str(7,mm_strdup("alter extension"),(yyvsp[(3) - (9)].str),(yyvsp[(4) - (9)].str),mm_strdup("operator class"),(yyvsp[(7) - (9)].str),mm_strdup("using"),(yyvsp[(9) - (9)].str)); +;} + break; + + case 553: + +/* Line 1455 of yacc.c */ +#line 4063 "preproc.y" + { + (yyval.str) = cat_str(7,mm_strdup("alter extension"),(yyvsp[(3) - (9)].str),(yyvsp[(4) - (9)].str),mm_strdup("operator family"),(yyvsp[(7) - (9)].str),mm_strdup("using"),(yyvsp[(9) - (9)].str)); +;} + break; + + case 554: + +/* Line 1455 of yacc.c */ +#line 4067 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter extension"),(yyvsp[(3) - (6)].str),(yyvsp[(4) - (6)].str),mm_strdup("schema"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 555: + +/* Line 1455 of yacc.c */ +#line 4071 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter extension"),(yyvsp[(3) - (6)].str),(yyvsp[(4) - (6)].str),mm_strdup("table"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 556: + +/* Line 1455 of yacc.c */ +#line 4075 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter extension"),(yyvsp[(3) - (8)].str),(yyvsp[(4) - (8)].str),mm_strdup("text search parser"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 557: + +/* Line 1455 of yacc.c */ +#line 4079 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter extension"),(yyvsp[(3) - (8)].str),(yyvsp[(4) - (8)].str),mm_strdup("text search dictionary"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 558: + +/* Line 1455 of yacc.c */ +#line 4083 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter extension"),(yyvsp[(3) - (8)].str),(yyvsp[(4) - (8)].str),mm_strdup("text search template"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 559: + +/* Line 1455 of yacc.c */ +#line 4087 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter extension"),(yyvsp[(3) - (8)].str),(yyvsp[(4) - (8)].str),mm_strdup("text search configuration"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 560: + +/* Line 1455 of yacc.c */ +#line 4091 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter extension"),(yyvsp[(3) - (6)].str),(yyvsp[(4) - (6)].str),mm_strdup("sequence"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 561: + +/* Line 1455 of yacc.c */ +#line 4095 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter extension"),(yyvsp[(3) - (6)].str),(yyvsp[(4) - (6)].str),mm_strdup("view"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 562: + +/* Line 1455 of yacc.c */ +#line 4099 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter extension"),(yyvsp[(3) - (7)].str),(yyvsp[(4) - (7)].str),mm_strdup("foreign table"),(yyvsp[(7) - (7)].str)); +;} + break; + + case 563: + +/* Line 1455 of yacc.c */ +#line 4103 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter extension"),(yyvsp[(3) - (8)].str),(yyvsp[(4) - (8)].str),mm_strdup("foreign data wrapper"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 564: + +/* Line 1455 of yacc.c */ +#line 4107 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter extension"),(yyvsp[(3) - (6)].str),(yyvsp[(4) - (6)].str),mm_strdup("server"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 565: + +/* Line 1455 of yacc.c */ +#line 4111 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter extension"),(yyvsp[(3) - (6)].str),(yyvsp[(4) - (6)].str),mm_strdup("type"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 566: + +/* Line 1455 of yacc.c */ +#line 4119 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("create foreign data wrapper"),(yyvsp[(5) - (7)].str),(yyvsp[(6) - (7)].str),(yyvsp[(7) - (7)].str)); +;} + break; + + case 567: + +/* Line 1455 of yacc.c */ +#line 4127 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("handler"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 568: + +/* Line 1455 of yacc.c */ +#line 4131 "preproc.y" + { + (yyval.str) = mm_strdup("no handler"); +;} + break; + + case 569: + +/* Line 1455 of yacc.c */ +#line 4135 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("validator"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 570: + +/* Line 1455 of yacc.c */ +#line 4139 "preproc.y" + { + (yyval.str) = mm_strdup("no validator"); +;} + break; + + case 571: + +/* Line 1455 of yacc.c */ +#line 4147 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 572: + +/* Line 1455 of yacc.c */ +#line 4151 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 573: + +/* Line 1455 of yacc.c */ +#line 4159 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 574: + +/* Line 1455 of yacc.c */ +#line 4163 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 575: + +/* Line 1455 of yacc.c */ +#line 4170 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("drop foreign data wrapper"),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 576: + +/* Line 1455 of yacc.c */ +#line 4174 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("drop foreign data wrapper if exists"),(yyvsp[(7) - (8)].str),(yyvsp[(8) - (8)].str)); +;} + break; + + case 577: + +/* Line 1455 of yacc.c */ +#line 4182 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter foreign data wrapper"),(yyvsp[(5) - (7)].str),(yyvsp[(6) - (7)].str),(yyvsp[(7) - (7)].str)); +;} + break; + + case 578: + +/* Line 1455 of yacc.c */ +#line 4186 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("alter foreign data wrapper"),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 579: + +/* Line 1455 of yacc.c */ +#line 4194 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("options ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 580: + +/* Line 1455 of yacc.c */ +#line 4198 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 581: + +/* Line 1455 of yacc.c */ +#line 4205 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 582: + +/* Line 1455 of yacc.c */ +#line 4209 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 583: + +/* Line 1455 of yacc.c */ +#line 4217 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("options ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 584: + +/* Line 1455 of yacc.c */ +#line 4225 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 585: + +/* Line 1455 of yacc.c */ +#line 4229 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 586: + +/* Line 1455 of yacc.c */ +#line 4237 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 587: + +/* Line 1455 of yacc.c */ +#line 4241 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("set"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 588: + +/* Line 1455 of yacc.c */ +#line 4245 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("add"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 589: + +/* Line 1455 of yacc.c */ +#line 4249 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("drop"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 590: + +/* Line 1455 of yacc.c */ +#line 4257 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 591: + +/* Line 1455 of yacc.c */ +#line 4265 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 592: + +/* Line 1455 of yacc.c */ +#line 4273 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 593: + +/* Line 1455 of yacc.c */ +#line 4281 "preproc.y" + { + (yyval.str) = cat_str(7,mm_strdup("create server"),(yyvsp[(3) - (10)].str),(yyvsp[(4) - (10)].str),(yyvsp[(5) - (10)].str),mm_strdup("foreign data wrapper"),(yyvsp[(9) - (10)].str),(yyvsp[(10) - (10)].str)); +;} + break; + + case 594: + +/* Line 1455 of yacc.c */ +#line 4289 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("type"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 595: + +/* Line 1455 of yacc.c */ +#line 4293 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 596: + +/* Line 1455 of yacc.c */ +#line 4300 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("version"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 597: + +/* Line 1455 of yacc.c */ +#line 4304 "preproc.y" + { + (yyval.str) = mm_strdup("version null"); +;} + break; + + case 598: + +/* Line 1455 of yacc.c */ +#line 4312 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 599: + +/* Line 1455 of yacc.c */ +#line 4316 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 600: + +/* Line 1455 of yacc.c */ +#line 4323 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("drop server"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 601: + +/* Line 1455 of yacc.c */ +#line 4327 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("drop server if exists"),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 602: + +/* Line 1455 of yacc.c */ +#line 4335 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter server"),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 603: + +/* Line 1455 of yacc.c */ +#line 4339 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("alter server"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 604: + +/* Line 1455 of yacc.c */ +#line 4343 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("alter server"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 605: + +/* Line 1455 of yacc.c */ +#line 4351 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("create foreign table"),(yyvsp[(4) - (8)].str),(yyvsp[(5) - (8)].str),mm_strdup("server"),(yyvsp[(7) - (8)].str),(yyvsp[(8) - (8)].str)); +;} + break; + + case 606: + +/* Line 1455 of yacc.c */ +#line 4355 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("create foreign table if not exists"),(yyvsp[(7) - (11)].str),(yyvsp[(8) - (11)].str),mm_strdup("server"),(yyvsp[(10) - (11)].str),(yyvsp[(11) - (11)].str)); +;} + break; + + case 607: + +/* Line 1455 of yacc.c */ +#line 4363 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (3)].str),mm_strdup(")")); +;} + break; + + case 608: + +/* Line 1455 of yacc.c */ +#line 4367 "preproc.y" + { + (yyval.str) = mm_strdup("( )"); +;} + break; + + case 609: + +/* Line 1455 of yacc.c */ +#line 4375 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 610: + +/* Line 1455 of yacc.c */ +#line 4379 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 611: + +/* Line 1455 of yacc.c */ +#line 4387 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 612: + +/* Line 1455 of yacc.c */ +#line 4395 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("alter foreign table"),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 613: + +/* Line 1455 of yacc.c */ +#line 4399 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("alter foreign table if exists"),(yyvsp[(6) - (7)].str),(yyvsp[(7) - (7)].str)); +;} + break; + + case 614: + +/* Line 1455 of yacc.c */ +#line 4407 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("create user mapping for"),(yyvsp[(5) - (8)].str),mm_strdup("server"),(yyvsp[(7) - (8)].str),(yyvsp[(8) - (8)].str)); +;} + break; + + case 615: + +/* Line 1455 of yacc.c */ +#line 4415 "preproc.y" + { + (yyval.str) = mm_strdup("current_user"); +;} + break; + + case 616: + +/* Line 1455 of yacc.c */ +#line 4419 "preproc.y" + { + (yyval.str) = mm_strdup("user"); +;} + break; + + case 617: + +/* Line 1455 of yacc.c */ +#line 4423 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 618: + +/* Line 1455 of yacc.c */ +#line 4431 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("drop user mapping for"),(yyvsp[(5) - (7)].str),mm_strdup("server"),(yyvsp[(7) - (7)].str)); +;} + break; + + case 619: + +/* Line 1455 of yacc.c */ +#line 4435 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("drop user mapping if exists for"),(yyvsp[(7) - (9)].str),mm_strdup("server"),(yyvsp[(9) - (9)].str)); +;} + break; + + case 620: + +/* Line 1455 of yacc.c */ +#line 4443 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter user mapping for"),(yyvsp[(5) - (8)].str),mm_strdup("server"),(yyvsp[(7) - (8)].str),(yyvsp[(8) - (8)].str)); +;} + break; + + case 621: + +/* Line 1455 of yacc.c */ +#line 4451 "preproc.y" + { + (yyval.str) = cat_str(13,mm_strdup("create trigger"),(yyvsp[(3) - (15)].str),(yyvsp[(4) - (15)].str),(yyvsp[(5) - (15)].str),mm_strdup("on"),(yyvsp[(7) - (15)].str),(yyvsp[(8) - (15)].str),(yyvsp[(9) - (15)].str),mm_strdup("execute procedure"),(yyvsp[(12) - (15)].str),mm_strdup("("),(yyvsp[(14) - (15)].str),mm_strdup(")")); +;} + break; + + case 622: + +/* Line 1455 of yacc.c */ +#line 4455 "preproc.y" + { + (yyval.str) = cat_str(15,mm_strdup("create constraint trigger"),(yyvsp[(4) - (20)].str),mm_strdup("after"),(yyvsp[(6) - (20)].str),mm_strdup("on"),(yyvsp[(8) - (20)].str),(yyvsp[(9) - (20)].str),(yyvsp[(10) - (20)].str),mm_strdup("for each row"),(yyvsp[(14) - (20)].str),mm_strdup("execute procedure"),(yyvsp[(17) - (20)].str),mm_strdup("("),(yyvsp[(19) - (20)].str),mm_strdup(")")); +;} + break; + + case 623: + +/* Line 1455 of yacc.c */ +#line 4463 "preproc.y" + { + (yyval.str) = mm_strdup("before"); +;} + break; + + case 624: + +/* Line 1455 of yacc.c */ +#line 4467 "preproc.y" + { + (yyval.str) = mm_strdup("after"); +;} + break; + + case 625: + +/* Line 1455 of yacc.c */ +#line 4471 "preproc.y" + { + (yyval.str) = mm_strdup("instead of"); +;} + break; + + case 626: + +/* Line 1455 of yacc.c */ +#line 4479 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 627: + +/* Line 1455 of yacc.c */ +#line 4483 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("or"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 628: + +/* Line 1455 of yacc.c */ +#line 4491 "preproc.y" + { + (yyval.str) = mm_strdup("insert"); +;} + break; + + case 629: + +/* Line 1455 of yacc.c */ +#line 4495 "preproc.y" + { + (yyval.str) = mm_strdup("delete"); +;} + break; + + case 630: + +/* Line 1455 of yacc.c */ +#line 4499 "preproc.y" + { + (yyval.str) = mm_strdup("update"); +;} + break; + + case 631: + +/* Line 1455 of yacc.c */ +#line 4503 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("update of"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 632: + +/* Line 1455 of yacc.c */ +#line 4507 "preproc.y" + { + (yyval.str) = mm_strdup("truncate"); +;} + break; + + case 633: + +/* Line 1455 of yacc.c */ +#line 4515 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("for"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 634: + +/* Line 1455 of yacc.c */ +#line 4519 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 635: + +/* Line 1455 of yacc.c */ +#line 4526 "preproc.y" + { + (yyval.str) = mm_strdup("each"); +;} + break; + + case 636: + +/* Line 1455 of yacc.c */ +#line 4530 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 637: + +/* Line 1455 of yacc.c */ +#line 4537 "preproc.y" + { + (yyval.str) = mm_strdup("row"); +;} + break; + + case 638: + +/* Line 1455 of yacc.c */ +#line 4541 "preproc.y" + { + (yyval.str) = mm_strdup("statement"); +;} + break; + + case 639: + +/* Line 1455 of yacc.c */ +#line 4549 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("when ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 640: + +/* Line 1455 of yacc.c */ +#line 4553 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 641: + +/* Line 1455 of yacc.c */ +#line 4560 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 642: + +/* Line 1455 of yacc.c */ +#line 4564 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 643: + +/* Line 1455 of yacc.c */ +#line 4568 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 644: + +/* Line 1455 of yacc.c */ +#line 4575 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 645: + +/* Line 1455 of yacc.c */ +#line 4579 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 646: + +/* Line 1455 of yacc.c */ +#line 4583 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 647: + +/* Line 1455 of yacc.c */ +#line 4587 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 648: + +/* Line 1455 of yacc.c */ +#line 4595 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("from"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 649: + +/* Line 1455 of yacc.c */ +#line 4599 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 650: + +/* Line 1455 of yacc.c */ +#line 4606 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 651: + +/* Line 1455 of yacc.c */ +#line 4609 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 652: + +/* Line 1455 of yacc.c */ +#line 4617 "preproc.y" + { + (yyval.str) = mm_strdup("not deferrable"); +;} + break; + + case 653: + +/* Line 1455 of yacc.c */ +#line 4621 "preproc.y" + { + (yyval.str) = mm_strdup("deferrable"); +;} + break; + + case 654: + +/* Line 1455 of yacc.c */ +#line 4625 "preproc.y" + { + (yyval.str) = mm_strdup("initially immediate"); +;} + break; + + case 655: + +/* Line 1455 of yacc.c */ +#line 4629 "preproc.y" + { + (yyval.str) = mm_strdup("initially deferred"); +;} + break; + + case 656: + +/* Line 1455 of yacc.c */ +#line 4633 "preproc.y" + { + (yyval.str) = mm_strdup("not valid"); +;} + break; + + case 657: + +/* Line 1455 of yacc.c */ +#line 4637 "preproc.y" + { + (yyval.str) = mm_strdup("no inherit"); +;} + break; + + case 658: + +/* Line 1455 of yacc.c */ +#line 4645 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("drop trigger"),(yyvsp[(3) - (6)].str),mm_strdup("on"),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 659: + +/* Line 1455 of yacc.c */ +#line 4649 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("drop trigger if exists"),(yyvsp[(5) - (8)].str),mm_strdup("on"),(yyvsp[(7) - (8)].str),(yyvsp[(8) - (8)].str)); +;} + break; + + case 660: + +/* Line 1455 of yacc.c */ +#line 4657 "preproc.y" + { +mmerror(PARSE_ERROR, ET_WARNING, "unsupported feature will be passed to server"); + (yyval.str) = cat_str(6,mm_strdup("create assertion"),(yyvsp[(3) - (8)].str),mm_strdup("check ("),(yyvsp[(6) - (8)].str),mm_strdup(")"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 661: + +/* Line 1455 of yacc.c */ +#line 4666 "preproc.y" + { +mmerror(PARSE_ERROR, ET_WARNING, "unsupported feature will be passed to server"); + (yyval.str) = cat_str(3,mm_strdup("drop assertion"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 662: + +/* Line 1455 of yacc.c */ +#line 4675 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("create aggregate"),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 663: + +/* Line 1455 of yacc.c */ +#line 4679 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("create aggregate"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 664: + +/* Line 1455 of yacc.c */ +#line 4683 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("create operator"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 665: + +/* Line 1455 of yacc.c */ +#line 4687 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("create type"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 666: + +/* Line 1455 of yacc.c */ +#line 4691 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("create type"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 667: + +/* Line 1455 of yacc.c */ +#line 4695 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("create type"),(yyvsp[(3) - (7)].str),mm_strdup("as ("),(yyvsp[(6) - (7)].str),mm_strdup(")")); +;} + break; + + case 668: + +/* Line 1455 of yacc.c */ +#line 4699 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("create type"),(yyvsp[(3) - (8)].str),mm_strdup("as enum ("),(yyvsp[(7) - (8)].str),mm_strdup(")")); +;} + break; + + case 669: + +/* Line 1455 of yacc.c */ +#line 4703 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("create type"),(yyvsp[(3) - (6)].str),mm_strdup("as range"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 670: + +/* Line 1455 of yacc.c */ +#line 4707 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("create text search parser"),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 671: + +/* Line 1455 of yacc.c */ +#line 4711 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("create text search dictionary"),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 672: + +/* Line 1455 of yacc.c */ +#line 4715 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("create text search template"),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 673: + +/* Line 1455 of yacc.c */ +#line 4719 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("create text search configuration"),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 674: + +/* Line 1455 of yacc.c */ +#line 4723 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("create collation"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 675: + +/* Line 1455 of yacc.c */ +#line 4727 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("create collation"),(yyvsp[(3) - (5)].str),mm_strdup("from"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 676: + +/* Line 1455 of yacc.c */ +#line 4735 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (3)].str),mm_strdup(")")); +;} + break; + + case 677: + +/* Line 1455 of yacc.c */ +#line 4743 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 678: + +/* Line 1455 of yacc.c */ +#line 4747 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 679: + +/* Line 1455 of yacc.c */ +#line 4755 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("="),(yyvsp[(3) - (3)].str)); +;} + break; + + case 680: + +/* Line 1455 of yacc.c */ +#line 4759 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 681: + +/* Line 1455 of yacc.c */ +#line 4767 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 682: + +/* Line 1455 of yacc.c */ +#line 4771 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 683: + +/* Line 1455 of yacc.c */ +#line 4775 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 684: + +/* Line 1455 of yacc.c */ +#line 4779 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 685: + +/* Line 1455 of yacc.c */ +#line 4783 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 686: + +/* Line 1455 of yacc.c */ +#line 4791 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (3)].str),mm_strdup(")")); +;} + break; + + case 687: + +/* Line 1455 of yacc.c */ +#line 4795 "preproc.y" + { + (yyval.str) = mm_strdup("( * )"); +;} + break; + + case 688: + +/* Line 1455 of yacc.c */ +#line 4803 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (3)].str),mm_strdup(")")); +;} + break; + + case 689: + +/* Line 1455 of yacc.c */ +#line 4811 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 690: + +/* Line 1455 of yacc.c */ +#line 4815 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 691: + +/* Line 1455 of yacc.c */ +#line 4823 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("="),(yyvsp[(3) - (3)].str)); +;} + break; + + case 692: + +/* Line 1455 of yacc.c */ +#line 4831 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 693: + +/* Line 1455 of yacc.c */ +#line 4835 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 694: + +/* Line 1455 of yacc.c */ +#line 4842 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 695: + +/* Line 1455 of yacc.c */ +#line 4846 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 696: + +/* Line 1455 of yacc.c */ +#line 4854 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter type"),(yyvsp[(3) - (6)].str),mm_strdup("add value"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 697: + +/* Line 1455 of yacc.c */ +#line 4858 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("alter type"),(yyvsp[(3) - (8)].str),mm_strdup("add value"),(yyvsp[(6) - (8)].str),mm_strdup("before"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 698: + +/* Line 1455 of yacc.c */ +#line 4862 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("alter type"),(yyvsp[(3) - (8)].str),mm_strdup("add value"),(yyvsp[(6) - (8)].str),mm_strdup("after"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 699: + +/* Line 1455 of yacc.c */ +#line 4870 "preproc.y" + { + (yyval.str) = cat_str(10,mm_strdup("create operator class"),(yyvsp[(4) - (13)].str),(yyvsp[(5) - (13)].str),mm_strdup("for type"),(yyvsp[(8) - (13)].str),mm_strdup("using"),(yyvsp[(10) - (13)].str),(yyvsp[(11) - (13)].str),mm_strdup("as"),(yyvsp[(13) - (13)].str)); +;} + break; + + case 700: + +/* Line 1455 of yacc.c */ +#line 4878 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 701: + +/* Line 1455 of yacc.c */ +#line 4882 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 702: + +/* Line 1455 of yacc.c */ +#line 4890 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("operator"),(yyvsp[(2) - (5)].str),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 703: + +/* Line 1455 of yacc.c */ +#line 4894 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("operator"),(yyvsp[(2) - (6)].str),(yyvsp[(3) - (6)].str),(yyvsp[(4) - (6)].str),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 704: + +/* Line 1455 of yacc.c */ +#line 4898 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("function"),(yyvsp[(2) - (4)].str),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 705: + +/* Line 1455 of yacc.c */ +#line 4902 "preproc.y" + { + (yyval.str) = cat_str(7,mm_strdup("function"),(yyvsp[(2) - (7)].str),mm_strdup("("),(yyvsp[(4) - (7)].str),mm_strdup(")"),(yyvsp[(6) - (7)].str),(yyvsp[(7) - (7)].str)); +;} + break; + + case 706: + +/* Line 1455 of yacc.c */ +#line 4906 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("storage"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 707: + +/* Line 1455 of yacc.c */ +#line 4914 "preproc.y" + { + (yyval.str) = mm_strdup("default"); +;} + break; + + case 708: + +/* Line 1455 of yacc.c */ +#line 4918 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 709: + +/* Line 1455 of yacc.c */ +#line 4925 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("family"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 710: + +/* Line 1455 of yacc.c */ +#line 4929 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 711: + +/* Line 1455 of yacc.c */ +#line 4936 "preproc.y" + { + (yyval.str) = mm_strdup("for search"); +;} + break; + + case 712: + +/* Line 1455 of yacc.c */ +#line 4940 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("for order by"),(yyvsp[(4) - (4)].str)); +;} + break; + + case 713: + +/* Line 1455 of yacc.c */ +#line 4944 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 714: + +/* Line 1455 of yacc.c */ +#line 4951 "preproc.y" + { +mmerror(PARSE_ERROR, ET_WARNING, "unsupported feature will be passed to server"); + (yyval.str) = mm_strdup("recheck"); +;} + break; + + case 715: + +/* Line 1455 of yacc.c */ +#line 4956 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 716: + +/* Line 1455 of yacc.c */ +#line 4963 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("create operator family"),(yyvsp[(4) - (6)].str),mm_strdup("using"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 717: + +/* Line 1455 of yacc.c */ +#line 4971 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("alter operator family"),(yyvsp[(4) - (8)].str),mm_strdup("using"),(yyvsp[(6) - (8)].str),mm_strdup("add"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 718: + +/* Line 1455 of yacc.c */ +#line 4975 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("alter operator family"),(yyvsp[(4) - (8)].str),mm_strdup("using"),(yyvsp[(6) - (8)].str),mm_strdup("drop"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 719: + +/* Line 1455 of yacc.c */ +#line 4983 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 720: + +/* Line 1455 of yacc.c */ +#line 4987 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 721: + +/* Line 1455 of yacc.c */ +#line 4995 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("operator"),(yyvsp[(2) - (5)].str),mm_strdup("("),(yyvsp[(4) - (5)].str),mm_strdup(")")); +;} + break; + + case 722: + +/* Line 1455 of yacc.c */ +#line 4999 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("function"),(yyvsp[(2) - (5)].str),mm_strdup("("),(yyvsp[(4) - (5)].str),mm_strdup(")")); +;} + break; + + case 723: + +/* Line 1455 of yacc.c */ +#line 5007 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("drop operator class"),(yyvsp[(4) - (7)].str),mm_strdup("using"),(yyvsp[(6) - (7)].str),(yyvsp[(7) - (7)].str)); +;} + break; + + case 724: + +/* Line 1455 of yacc.c */ +#line 5011 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("drop operator class if exists"),(yyvsp[(6) - (9)].str),mm_strdup("using"),(yyvsp[(8) - (9)].str),(yyvsp[(9) - (9)].str)); +;} + break; + + case 725: + +/* Line 1455 of yacc.c */ +#line 5019 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("drop operator family"),(yyvsp[(4) - (7)].str),mm_strdup("using"),(yyvsp[(6) - (7)].str),(yyvsp[(7) - (7)].str)); +;} + break; + + case 726: + +/* Line 1455 of yacc.c */ +#line 5023 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("drop operator family if exists"),(yyvsp[(6) - (9)].str),mm_strdup("using"),(yyvsp[(8) - (9)].str),(yyvsp[(9) - (9)].str)); +;} + break; + + case 727: + +/* Line 1455 of yacc.c */ +#line 5031 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("drop owned by"),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 728: + +/* Line 1455 of yacc.c */ +#line 5039 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("reassign owned by"),(yyvsp[(4) - (6)].str),mm_strdup("to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 729: + +/* Line 1455 of yacc.c */ +#line 5047 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("drop"),(yyvsp[(2) - (6)].str),mm_strdup("if exists"),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 730: + +/* Line 1455 of yacc.c */ +#line 5051 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("drop"),(yyvsp[(2) - (4)].str),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 731: + +/* Line 1455 of yacc.c */ +#line 5055 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("drop index concurrently"),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 732: + +/* Line 1455 of yacc.c */ +#line 5059 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("drop index concurrently if exists"),(yyvsp[(6) - (7)].str),(yyvsp[(7) - (7)].str)); +;} + break; + + case 733: + +/* Line 1455 of yacc.c */ +#line 5067 "preproc.y" + { + (yyval.str) = mm_strdup("table"); +;} + break; + + case 734: + +/* Line 1455 of yacc.c */ +#line 5071 "preproc.y" + { + (yyval.str) = mm_strdup("sequence"); +;} + break; + + case 735: + +/* Line 1455 of yacc.c */ +#line 5075 "preproc.y" + { + (yyval.str) = mm_strdup("view"); +;} + break; + + case 736: + +/* Line 1455 of yacc.c */ +#line 5079 "preproc.y" + { + (yyval.str) = mm_strdup("index"); +;} + break; + + case 737: + +/* Line 1455 of yacc.c */ +#line 5083 "preproc.y" + { + (yyval.str) = mm_strdup("foreign table"); +;} + break; + + case 738: + +/* Line 1455 of yacc.c */ +#line 5087 "preproc.y" + { + (yyval.str) = mm_strdup("type"); +;} + break; + + case 739: + +/* Line 1455 of yacc.c */ +#line 5091 "preproc.y" + { + (yyval.str) = mm_strdup("domain"); +;} + break; + + case 740: + +/* Line 1455 of yacc.c */ +#line 5095 "preproc.y" + { + (yyval.str) = mm_strdup("collation"); +;} + break; + + case 741: + +/* Line 1455 of yacc.c */ +#line 5099 "preproc.y" + { + (yyval.str) = mm_strdup("conversion"); +;} + break; + + case 742: + +/* Line 1455 of yacc.c */ +#line 5103 "preproc.y" + { + (yyval.str) = mm_strdup("schema"); +;} + break; + + case 743: + +/* Line 1455 of yacc.c */ +#line 5107 "preproc.y" + { + (yyval.str) = mm_strdup("extension"); +;} + break; + + case 744: + +/* Line 1455 of yacc.c */ +#line 5111 "preproc.y" + { + (yyval.str) = mm_strdup("text search parser"); +;} + break; + + case 745: + +/* Line 1455 of yacc.c */ +#line 5115 "preproc.y" + { + (yyval.str) = mm_strdup("text search dictionary"); +;} + break; + + case 746: + +/* Line 1455 of yacc.c */ +#line 5119 "preproc.y" + { + (yyval.str) = mm_strdup("text search template"); +;} + break; + + case 747: + +/* Line 1455 of yacc.c */ +#line 5123 "preproc.y" + { + (yyval.str) = mm_strdup("text search configuration"); +;} + break; + + case 748: + +/* Line 1455 of yacc.c */ +#line 5131 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 749: + +/* Line 1455 of yacc.c */ +#line 5135 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 750: + +/* Line 1455 of yacc.c */ +#line 5143 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 751: + +/* Line 1455 of yacc.c */ +#line 5147 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 752: + +/* Line 1455 of yacc.c */ +#line 5155 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("."),(yyvsp[(2) - (2)].str)); +;} + break; + + case 753: + +/* Line 1455 of yacc.c */ +#line 5159 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("."),(yyvsp[(3) - (3)].str)); +;} + break; + + case 754: + +/* Line 1455 of yacc.c */ +#line 5167 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("truncate"),(yyvsp[(2) - (5)].str),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 755: + +/* Line 1455 of yacc.c */ +#line 5175 "preproc.y" + { + (yyval.str) = mm_strdup("continue identity"); +;} + break; + + case 756: + +/* Line 1455 of yacc.c */ +#line 5179 "preproc.y" + { + (yyval.str) = mm_strdup("restart identity"); +;} + break; + + case 757: + +/* Line 1455 of yacc.c */ +#line 5183 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 758: + +/* Line 1455 of yacc.c */ +#line 5190 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("comment on"),(yyvsp[(3) - (6)].str),(yyvsp[(4) - (6)].str),mm_strdup("is"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 759: + +/* Line 1455 of yacc.c */ +#line 5194 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("comment on aggregate"),(yyvsp[(4) - (7)].str),(yyvsp[(5) - (7)].str),mm_strdup("is"),(yyvsp[(7) - (7)].str)); +;} + break; + + case 760: + +/* Line 1455 of yacc.c */ +#line 5198 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("comment on function"),(yyvsp[(4) - (7)].str),(yyvsp[(5) - (7)].str),mm_strdup("is"),(yyvsp[(7) - (7)].str)); +;} + break; + + case 761: + +/* Line 1455 of yacc.c */ +#line 5202 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("comment on operator"),(yyvsp[(4) - (7)].str),(yyvsp[(5) - (7)].str),mm_strdup("is"),(yyvsp[(7) - (7)].str)); +;} + break; + + case 762: + +/* Line 1455 of yacc.c */ +#line 5206 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("comment on constraint"),(yyvsp[(4) - (8)].str),mm_strdup("on"),(yyvsp[(6) - (8)].str),mm_strdup("is"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 763: + +/* Line 1455 of yacc.c */ +#line 5210 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("comment on rule"),(yyvsp[(4) - (8)].str),mm_strdup("on"),(yyvsp[(6) - (8)].str),mm_strdup("is"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 764: + +/* Line 1455 of yacc.c */ +#line 5214 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("comment on rule"),(yyvsp[(4) - (6)].str),mm_strdup("is"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 765: + +/* Line 1455 of yacc.c */ +#line 5218 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("comment on trigger"),(yyvsp[(4) - (8)].str),mm_strdup("on"),(yyvsp[(6) - (8)].str),mm_strdup("is"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 766: + +/* Line 1455 of yacc.c */ +#line 5222 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("comment on operator class"),(yyvsp[(5) - (9)].str),mm_strdup("using"),(yyvsp[(7) - (9)].str),mm_strdup("is"),(yyvsp[(9) - (9)].str)); +;} + break; + + case 767: + +/* Line 1455 of yacc.c */ +#line 5226 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("comment on operator family"),(yyvsp[(5) - (9)].str),mm_strdup("using"),(yyvsp[(7) - (9)].str),mm_strdup("is"),(yyvsp[(9) - (9)].str)); +;} + break; + + case 768: + +/* Line 1455 of yacc.c */ +#line 5230 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("comment on large object"),(yyvsp[(5) - (7)].str),mm_strdup("is"),(yyvsp[(7) - (7)].str)); +;} + break; + + case 769: + +/* Line 1455 of yacc.c */ +#line 5234 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("comment on cast ("),(yyvsp[(5) - (10)].str),mm_strdup("as"),(yyvsp[(7) - (10)].str),mm_strdup(") is"),(yyvsp[(10) - (10)].str)); +;} + break; + + case 770: + +/* Line 1455 of yacc.c */ +#line 5238 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("comment on"),(yyvsp[(3) - (7)].str),mm_strdup("language"),(yyvsp[(5) - (7)].str),mm_strdup("is"),(yyvsp[(7) - (7)].str)); +;} + break; + + case 771: + +/* Line 1455 of yacc.c */ +#line 5242 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("comment on text search parser"),(yyvsp[(6) - (8)].str),mm_strdup("is"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 772: + +/* Line 1455 of yacc.c */ +#line 5246 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("comment on text search dictionary"),(yyvsp[(6) - (8)].str),mm_strdup("is"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 773: + +/* Line 1455 of yacc.c */ +#line 5250 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("comment on text search template"),(yyvsp[(6) - (8)].str),mm_strdup("is"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 774: + +/* Line 1455 of yacc.c */ +#line 5254 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("comment on text search configuration"),(yyvsp[(6) - (8)].str),mm_strdup("is"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 775: + +/* Line 1455 of yacc.c */ +#line 5262 "preproc.y" + { + (yyval.str) = mm_strdup("column"); +;} + break; + + case 776: + +/* Line 1455 of yacc.c */ +#line 5266 "preproc.y" + { + (yyval.str) = mm_strdup("database"); +;} + break; + + case 777: + +/* Line 1455 of yacc.c */ +#line 5270 "preproc.y" + { + (yyval.str) = mm_strdup("schema"); +;} + break; + + case 778: + +/* Line 1455 of yacc.c */ +#line 5274 "preproc.y" + { + (yyval.str) = mm_strdup("index"); +;} + break; + + case 779: + +/* Line 1455 of yacc.c */ +#line 5278 "preproc.y" + { + (yyval.str) = mm_strdup("sequence"); +;} + break; + + case 780: + +/* Line 1455 of yacc.c */ +#line 5282 "preproc.y" + { + (yyval.str) = mm_strdup("table"); +;} + break; + + case 781: + +/* Line 1455 of yacc.c */ +#line 5286 "preproc.y" + { + (yyval.str) = mm_strdup("domain"); +;} + break; + + case 782: + +/* Line 1455 of yacc.c */ +#line 5290 "preproc.y" + { + (yyval.str) = mm_strdup("type"); +;} + break; + + case 783: + +/* Line 1455 of yacc.c */ +#line 5294 "preproc.y" + { + (yyval.str) = mm_strdup("view"); +;} + break; + + case 784: + +/* Line 1455 of yacc.c */ +#line 5298 "preproc.y" + { + (yyval.str) = mm_strdup("collation"); +;} + break; + + case 785: + +/* Line 1455 of yacc.c */ +#line 5302 "preproc.y" + { + (yyval.str) = mm_strdup("conversion"); +;} + break; + + case 786: + +/* Line 1455 of yacc.c */ +#line 5306 "preproc.y" + { + (yyval.str) = mm_strdup("tablespace"); +;} + break; + + case 787: + +/* Line 1455 of yacc.c */ +#line 5310 "preproc.y" + { + (yyval.str) = mm_strdup("extension"); +;} + break; + + case 788: + +/* Line 1455 of yacc.c */ +#line 5314 "preproc.y" + { + (yyval.str) = mm_strdup("role"); +;} + break; + + case 789: + +/* Line 1455 of yacc.c */ +#line 5318 "preproc.y" + { + (yyval.str) = mm_strdup("foreign table"); +;} + break; + + case 790: + +/* Line 1455 of yacc.c */ +#line 5322 "preproc.y" + { + (yyval.str) = mm_strdup("server"); +;} + break; + + case 791: + +/* Line 1455 of yacc.c */ +#line 5326 "preproc.y" + { + (yyval.str) = mm_strdup("foreign data wrapper"); +;} + break; + + case 792: + +/* Line 1455 of yacc.c */ +#line 5334 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 793: + +/* Line 1455 of yacc.c */ +#line 5338 "preproc.y" + { + (yyval.str) = mm_strdup("null"); +;} + break; + + case 794: + +/* Line 1455 of yacc.c */ +#line 5346 "preproc.y" + { + (yyval.str) = cat_str(7,mm_strdup("security label"),(yyvsp[(3) - (8)].str),mm_strdup("on"),(yyvsp[(5) - (8)].str),(yyvsp[(6) - (8)].str),mm_strdup("is"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 795: + +/* Line 1455 of yacc.c */ +#line 5350 "preproc.y" + { + (yyval.str) = cat_str(7,mm_strdup("security label"),(yyvsp[(3) - (9)].str),mm_strdup("on aggregate"),(yyvsp[(6) - (9)].str),(yyvsp[(7) - (9)].str),mm_strdup("is"),(yyvsp[(9) - (9)].str)); +;} + break; + + case 796: + +/* Line 1455 of yacc.c */ +#line 5354 "preproc.y" + { + (yyval.str) = cat_str(7,mm_strdup("security label"),(yyvsp[(3) - (9)].str),mm_strdup("on function"),(yyvsp[(6) - (9)].str),(yyvsp[(7) - (9)].str),mm_strdup("is"),(yyvsp[(9) - (9)].str)); +;} + break; + + case 797: + +/* Line 1455 of yacc.c */ +#line 5358 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("security label"),(yyvsp[(3) - (9)].str),mm_strdup("on large object"),(yyvsp[(7) - (9)].str),mm_strdup("is"),(yyvsp[(9) - (9)].str)); +;} + break; + + case 798: + +/* Line 1455 of yacc.c */ +#line 5362 "preproc.y" + { + (yyval.str) = cat_str(8,mm_strdup("security label"),(yyvsp[(3) - (9)].str),mm_strdup("on"),(yyvsp[(5) - (9)].str),mm_strdup("language"),(yyvsp[(7) - (9)].str),mm_strdup("is"),(yyvsp[(9) - (9)].str)); +;} + break; + + case 799: + +/* Line 1455 of yacc.c */ +#line 5370 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("for"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 800: + +/* Line 1455 of yacc.c */ +#line 5374 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 801: + +/* Line 1455 of yacc.c */ +#line 5381 "preproc.y" + { + (yyval.str) = mm_strdup("column"); +;} + break; + + case 802: + +/* Line 1455 of yacc.c */ +#line 5385 "preproc.y" + { + (yyval.str) = mm_strdup("database"); +;} + break; + + case 803: + +/* Line 1455 of yacc.c */ +#line 5389 "preproc.y" + { + (yyval.str) = mm_strdup("foreign table"); +;} + break; + + case 804: + +/* Line 1455 of yacc.c */ +#line 5393 "preproc.y" + { + (yyval.str) = mm_strdup("schema"); +;} + break; + + case 805: + +/* Line 1455 of yacc.c */ +#line 5397 "preproc.y" + { + (yyval.str) = mm_strdup("sequence"); +;} + break; + + case 806: + +/* Line 1455 of yacc.c */ +#line 5401 "preproc.y" + { + (yyval.str) = mm_strdup("table"); +;} + break; + + case 807: + +/* Line 1455 of yacc.c */ +#line 5405 "preproc.y" + { + (yyval.str) = mm_strdup("domain"); +;} + break; + + case 808: + +/* Line 1455 of yacc.c */ +#line 5409 "preproc.y" + { + (yyval.str) = mm_strdup("role"); +;} + break; + + case 809: + +/* Line 1455 of yacc.c */ +#line 5413 "preproc.y" + { + (yyval.str) = mm_strdup("tablespace"); +;} + break; + + case 810: + +/* Line 1455 of yacc.c */ +#line 5417 "preproc.y" + { + (yyval.str) = mm_strdup("type"); +;} + break; + + case 811: + +/* Line 1455 of yacc.c */ +#line 5421 "preproc.y" + { + (yyval.str) = mm_strdup("view"); +;} + break; + + case 812: + +/* Line 1455 of yacc.c */ +#line 5429 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 813: + +/* Line 1455 of yacc.c */ +#line 5433 "preproc.y" + { + (yyval.str) = mm_strdup("null"); +;} + break; + + case 814: + +/* Line 1455 of yacc.c */ +#line 5441 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("fetch"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 815: + +/* Line 1455 of yacc.c */ +#line 5445 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("move"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 816: + +/* Line 1455 of yacc.c */ +#line 5449 "preproc.y" + { + (yyval.str) = cat2_str(mm_strdup("fetch"), (yyvsp[(2) - (3)].str)); + ;} + break; + + case 817: + +/* Line 1455 of yacc.c */ +#line 5453 "preproc.y" + { + char *cursor_marker = (yyvsp[(3) - (4)].str)[0] == ':' ? mm_strdup("$0") : (yyvsp[(3) - (4)].str); + add_additional_variables((yyvsp[(3) - (4)].str), false); + (yyval.str) = cat_str(2, mm_strdup("fetch forward"), cursor_marker); + ;} + break; + + case 818: + +/* Line 1455 of yacc.c */ +#line 5459 "preproc.y" + { + char *cursor_marker = (yyvsp[(4) - (5)].str)[0] == ':' ? mm_strdup("$0") : (yyvsp[(4) - (5)].str); + add_additional_variables((yyvsp[(4) - (5)].str), false); + (yyval.str) = cat_str(2, mm_strdup("fetch forward from"), cursor_marker); + ;} + break; + + case 819: + +/* Line 1455 of yacc.c */ +#line 5465 "preproc.y" + { + char *cursor_marker = (yyvsp[(3) - (4)].str)[0] == ':' ? mm_strdup("$0") : (yyvsp[(3) - (4)].str); + add_additional_variables((yyvsp[(3) - (4)].str), false); + (yyval.str) = cat_str(2, mm_strdup("fetch backward"), cursor_marker); + ;} + break; + + case 820: + +/* Line 1455 of yacc.c */ +#line 5471 "preproc.y" + { + char *cursor_marker = (yyvsp[(4) - (5)].str)[0] == ':' ? mm_strdup("$0") : (yyvsp[(4) - (5)].str); + add_additional_variables((yyvsp[(4) - (5)].str), false); + (yyval.str) = cat_str(2, mm_strdup("fetch backward from"), cursor_marker); + ;} + break; + + case 821: + +/* Line 1455 of yacc.c */ +#line 5477 "preproc.y" + { + char *cursor_marker = (yyvsp[(3) - (3)].str)[0] == ':' ? mm_strdup("$0") : (yyvsp[(3) - (3)].str); + add_additional_variables((yyvsp[(3) - (3)].str), false); + (yyval.str) = cat_str(2, mm_strdup("move forward"), cursor_marker); + ;} + break; + + case 822: + +/* Line 1455 of yacc.c */ +#line 5483 "preproc.y" + { + char *cursor_marker = (yyvsp[(4) - (4)].str)[0] == ':' ? mm_strdup("$0") : (yyvsp[(4) - (4)].str); + add_additional_variables((yyvsp[(4) - (4)].str), false); + (yyval.str) = cat_str(2, mm_strdup("move forward from"), cursor_marker); + ;} + break; + + case 823: + +/* Line 1455 of yacc.c */ +#line 5489 "preproc.y" + { + char *cursor_marker = (yyvsp[(3) - (3)].str)[0] == ':' ? mm_strdup("$0") : (yyvsp[(3) - (3)].str); + add_additional_variables((yyvsp[(3) - (3)].str), false); + (yyval.str) = cat_str(2, mm_strdup("move backward"), cursor_marker); + ;} + break; + + case 824: + +/* Line 1455 of yacc.c */ +#line 5495 "preproc.y" + { + char *cursor_marker = (yyvsp[(4) - (4)].str)[0] == ':' ? mm_strdup("$0") : (yyvsp[(4) - (4)].str); + add_additional_variables((yyvsp[(4) - (4)].str), false); + (yyval.str) = cat_str(2, mm_strdup("move backward from"), cursor_marker); + ;} + break; + + case 825: + +/* Line 1455 of yacc.c */ +#line 5505 "preproc.y" + { + add_additional_variables((yyvsp[(1) - (1)].str), false); + if ((yyvsp[(1) - (1)].str)[0] == ':') + { + free((yyvsp[(1) - (1)].str)); + (yyvsp[(1) - (1)].str) = mm_strdup("$0"); + } + + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 826: + +/* Line 1455 of yacc.c */ +#line 5516 "preproc.y" + { + add_additional_variables((yyvsp[(2) - (2)].str), false); + if ((yyvsp[(2) - (2)].str)[0] == ':') + { + free((yyvsp[(2) - (2)].str)); + (yyvsp[(2) - (2)].str) = mm_strdup("$0"); + } + + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 827: + +/* Line 1455 of yacc.c */ +#line 5527 "preproc.y" + { + add_additional_variables((yyvsp[(3) - (3)].str), false); + if ((yyvsp[(3) - (3)].str)[0] == ':') + { + free((yyvsp[(3) - (3)].str)); + (yyvsp[(3) - (3)].str) = mm_strdup("$0"); + } + + (yyval.str) = cat_str(3,mm_strdup("next"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 828: + +/* Line 1455 of yacc.c */ +#line 5538 "preproc.y" + { + add_additional_variables((yyvsp[(3) - (3)].str), false); + if ((yyvsp[(3) - (3)].str)[0] == ':') + { + free((yyvsp[(3) - (3)].str)); + (yyvsp[(3) - (3)].str) = mm_strdup("$0"); + } + + (yyval.str) = cat_str(3,mm_strdup("prior"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 829: + +/* Line 1455 of yacc.c */ +#line 5549 "preproc.y" + { + add_additional_variables((yyvsp[(3) - (3)].str), false); + if ((yyvsp[(3) - (3)].str)[0] == ':') + { + free((yyvsp[(3) - (3)].str)); + (yyvsp[(3) - (3)].str) = mm_strdup("$0"); + } + + (yyval.str) = cat_str(3,mm_strdup("first"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 830: + +/* Line 1455 of yacc.c */ +#line 5560 "preproc.y" + { + add_additional_variables((yyvsp[(3) - (3)].str), false); + if ((yyvsp[(3) - (3)].str)[0] == ':') + { + free((yyvsp[(3) - (3)].str)); + (yyvsp[(3) - (3)].str) = mm_strdup("$0"); + } + + (yyval.str) = cat_str(3,mm_strdup("last"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 831: + +/* Line 1455 of yacc.c */ +#line 5571 "preproc.y" + { + add_additional_variables((yyvsp[(4) - (4)].str), false); + if ((yyvsp[(4) - (4)].str)[0] == ':') + { + free((yyvsp[(4) - (4)].str)); + (yyvsp[(4) - (4)].str) = mm_strdup("$0"); + } + if ((yyvsp[(2) - (4)].str)[0] == '$') + { + free((yyvsp[(2) - (4)].str)); + (yyvsp[(2) - (4)].str) = mm_strdup("$0"); + } + + (yyval.str) = cat_str(4,mm_strdup("absolute"),(yyvsp[(2) - (4)].str),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 832: + +/* Line 1455 of yacc.c */ +#line 5587 "preproc.y" + { + add_additional_variables((yyvsp[(4) - (4)].str), false); + if ((yyvsp[(4) - (4)].str)[0] == ':') + { + free((yyvsp[(4) - (4)].str)); + (yyvsp[(4) - (4)].str) = mm_strdup("$0"); + } + if ((yyvsp[(2) - (4)].str)[0] == '$') + { + free((yyvsp[(2) - (4)].str)); + (yyvsp[(2) - (4)].str) = mm_strdup("$0"); + } + + (yyval.str) = cat_str(4,mm_strdup("relative"),(yyvsp[(2) - (4)].str),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 833: + +/* Line 1455 of yacc.c */ +#line 5603 "preproc.y" + { + add_additional_variables((yyvsp[(3) - (3)].str), false); + if ((yyvsp[(3) - (3)].str)[0] == ':') + { + free((yyvsp[(3) - (3)].str)); + (yyvsp[(3) - (3)].str) = mm_strdup("$0"); + } + if ((yyvsp[(1) - (3)].str)[0] == '$') + { + free((yyvsp[(1) - (3)].str)); + (yyvsp[(1) - (3)].str) = mm_strdup("$0"); + } + + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 834: + +/* Line 1455 of yacc.c */ +#line 5619 "preproc.y" + { + add_additional_variables((yyvsp[(3) - (3)].str), false); + if ((yyvsp[(3) - (3)].str)[0] == ':') + { + free((yyvsp[(3) - (3)].str)); + (yyvsp[(3) - (3)].str) = mm_strdup("$0"); + } + + (yyval.str) = cat_str(3,mm_strdup("all"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 835: + +/* Line 1455 of yacc.c */ +#line 5630 "preproc.y" + { + add_additional_variables((yyvsp[(4) - (4)].str), false); + if ((yyvsp[(4) - (4)].str)[0] == ':') + { + free((yyvsp[(4) - (4)].str)); + (yyvsp[(4) - (4)].str) = mm_strdup("$0"); + } + if ((yyvsp[(2) - (4)].str)[0] == '$') + { + free((yyvsp[(2) - (4)].str)); + (yyvsp[(2) - (4)].str) = mm_strdup("$0"); + } + + (yyval.str) = cat_str(4,mm_strdup("forward"),(yyvsp[(2) - (4)].str),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 836: + +/* Line 1455 of yacc.c */ +#line 5646 "preproc.y" + { + add_additional_variables((yyvsp[(4) - (4)].str), false); + if ((yyvsp[(4) - (4)].str)[0] == ':') + { + free((yyvsp[(4) - (4)].str)); + (yyvsp[(4) - (4)].str) = mm_strdup("$0"); + } + + (yyval.str) = cat_str(3,mm_strdup("forward all"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 837: + +/* Line 1455 of yacc.c */ +#line 5657 "preproc.y" + { + add_additional_variables((yyvsp[(4) - (4)].str), false); + if ((yyvsp[(4) - (4)].str)[0] == ':') + { + free((yyvsp[(4) - (4)].str)); + (yyvsp[(4) - (4)].str) = mm_strdup("$0"); + } + if ((yyvsp[(2) - (4)].str)[0] == '$') + { + free((yyvsp[(2) - (4)].str)); + (yyvsp[(2) - (4)].str) = mm_strdup("$0"); + } + + (yyval.str) = cat_str(4,mm_strdup("backward"),(yyvsp[(2) - (4)].str),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 838: + +/* Line 1455 of yacc.c */ +#line 5673 "preproc.y" + { + add_additional_variables((yyvsp[(4) - (4)].str), false); + if ((yyvsp[(4) - (4)].str)[0] == ':') + { + free((yyvsp[(4) - (4)].str)); + (yyvsp[(4) - (4)].str) = mm_strdup("$0"); + } + + (yyval.str) = cat_str(3,mm_strdup("backward all"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 839: + +/* Line 1455 of yacc.c */ +#line 5688 "preproc.y" + { + (yyval.str) = mm_strdup("from"); +;} + break; + + case 840: + +/* Line 1455 of yacc.c */ +#line 5692 "preproc.y" + { + (yyval.str) = mm_strdup("in"); +;} + break; + + case 841: + +/* Line 1455 of yacc.c */ +#line 5700 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 842: + +/* Line 1455 of yacc.c */ +#line 5704 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 843: + +/* Line 1455 of yacc.c */ +#line 5711 "preproc.y" + { + (yyval.str) = cat_str(7,mm_strdup("grant"),(yyvsp[(2) - (7)].str),mm_strdup("on"),(yyvsp[(4) - (7)].str),mm_strdup("to"),(yyvsp[(6) - (7)].str),(yyvsp[(7) - (7)].str)); +;} + break; + + case 844: + +/* Line 1455 of yacc.c */ +#line 5719 "preproc.y" + { + (yyval.str) = cat_str(7,mm_strdup("revoke"),(yyvsp[(2) - (7)].str),mm_strdup("on"),(yyvsp[(4) - (7)].str),mm_strdup("from"),(yyvsp[(6) - (7)].str),(yyvsp[(7) - (7)].str)); +;} + break; + + case 845: + +/* Line 1455 of yacc.c */ +#line 5723 "preproc.y" + { + (yyval.str) = cat_str(7,mm_strdup("revoke grant option for"),(yyvsp[(5) - (10)].str),mm_strdup("on"),(yyvsp[(7) - (10)].str),mm_strdup("from"),(yyvsp[(9) - (10)].str),(yyvsp[(10) - (10)].str)); +;} + break; + + case 846: + +/* Line 1455 of yacc.c */ +#line 5731 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 847: + +/* Line 1455 of yacc.c */ +#line 5735 "preproc.y" + { + (yyval.str) = mm_strdup("all"); +;} + break; + + case 848: + +/* Line 1455 of yacc.c */ +#line 5739 "preproc.y" + { + (yyval.str) = mm_strdup("all privileges"); +;} + break; + + case 849: + +/* Line 1455 of yacc.c */ +#line 5743 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("all ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 850: + +/* Line 1455 of yacc.c */ +#line 5747 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("all privileges ("),(yyvsp[(4) - (5)].str),mm_strdup(")")); +;} + break; + + case 851: + +/* Line 1455 of yacc.c */ +#line 5755 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 852: + +/* Line 1455 of yacc.c */ +#line 5759 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 853: + +/* Line 1455 of yacc.c */ +#line 5767 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("select"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 854: + +/* Line 1455 of yacc.c */ +#line 5771 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("references"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 855: + +/* Line 1455 of yacc.c */ +#line 5775 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("create"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 856: + +/* Line 1455 of yacc.c */ +#line 5779 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 857: + +/* Line 1455 of yacc.c */ +#line 5787 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 858: + +/* Line 1455 of yacc.c */ +#line 5791 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("table"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 859: + +/* Line 1455 of yacc.c */ +#line 5795 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("sequence"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 860: + +/* Line 1455 of yacc.c */ +#line 5799 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("foreign data wrapper"),(yyvsp[(4) - (4)].str)); +;} + break; + + case 861: + +/* Line 1455 of yacc.c */ +#line 5803 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("foreign server"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 862: + +/* Line 1455 of yacc.c */ +#line 5807 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("function"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 863: + +/* Line 1455 of yacc.c */ +#line 5811 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("database"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 864: + +/* Line 1455 of yacc.c */ +#line 5815 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("domain"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 865: + +/* Line 1455 of yacc.c */ +#line 5819 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("language"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 866: + +/* Line 1455 of yacc.c */ +#line 5823 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("large object"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 867: + +/* Line 1455 of yacc.c */ +#line 5827 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("schema"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 868: + +/* Line 1455 of yacc.c */ +#line 5831 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("tablespace"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 869: + +/* Line 1455 of yacc.c */ +#line 5835 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("type"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 870: + +/* Line 1455 of yacc.c */ +#line 5839 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("all tables in schema"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 871: + +/* Line 1455 of yacc.c */ +#line 5843 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("all sequences in schema"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 872: + +/* Line 1455 of yacc.c */ +#line 5847 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("all functions in schema"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 873: + +/* Line 1455 of yacc.c */ +#line 5855 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 874: + +/* Line 1455 of yacc.c */ +#line 5859 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 875: + +/* Line 1455 of yacc.c */ +#line 5867 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 876: + +/* Line 1455 of yacc.c */ +#line 5871 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("group"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 877: + +/* Line 1455 of yacc.c */ +#line 5879 "preproc.y" + { + (yyval.str) = mm_strdup("with grant option"); +;} + break; + + case 878: + +/* Line 1455 of yacc.c */ +#line 5883 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 879: + +/* Line 1455 of yacc.c */ +#line 5890 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 880: + +/* Line 1455 of yacc.c */ +#line 5894 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 881: + +/* Line 1455 of yacc.c */ +#line 5902 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 882: + +/* Line 1455 of yacc.c */ +#line 5910 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("grant"),(yyvsp[(2) - (6)].str),mm_strdup("to"),(yyvsp[(4) - (6)].str),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 883: + +/* Line 1455 of yacc.c */ +#line 5918 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("revoke"),(yyvsp[(2) - (6)].str),mm_strdup("from"),(yyvsp[(4) - (6)].str),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 884: + +/* Line 1455 of yacc.c */ +#line 5922 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("revoke admin option for"),(yyvsp[(5) - (9)].str),mm_strdup("from"),(yyvsp[(7) - (9)].str),(yyvsp[(8) - (9)].str),(yyvsp[(9) - (9)].str)); +;} + break; + + case 885: + +/* Line 1455 of yacc.c */ +#line 5930 "preproc.y" + { + (yyval.str) = mm_strdup("with admin option"); +;} + break; + + case 886: + +/* Line 1455 of yacc.c */ +#line 5934 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 887: + +/* Line 1455 of yacc.c */ +#line 5941 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("granted by"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 888: + +/* Line 1455 of yacc.c */ +#line 5945 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 889: + +/* Line 1455 of yacc.c */ +#line 5952 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("alter default privileges"),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 890: + +/* Line 1455 of yacc.c */ +#line 5960 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 891: + +/* Line 1455 of yacc.c */ +#line 5964 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 892: + +/* Line 1455 of yacc.c */ +#line 5971 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("in schema"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 893: + +/* Line 1455 of yacc.c */ +#line 5975 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("for role"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 894: + +/* Line 1455 of yacc.c */ +#line 5979 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("for user"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 895: + +/* Line 1455 of yacc.c */ +#line 5987 "preproc.y" + { + (yyval.str) = cat_str(7,mm_strdup("grant"),(yyvsp[(2) - (7)].str),mm_strdup("on"),(yyvsp[(4) - (7)].str),mm_strdup("to"),(yyvsp[(6) - (7)].str),(yyvsp[(7) - (7)].str)); +;} + break; + + case 896: + +/* Line 1455 of yacc.c */ +#line 5991 "preproc.y" + { + (yyval.str) = cat_str(7,mm_strdup("revoke"),(yyvsp[(2) - (7)].str),mm_strdup("on"),(yyvsp[(4) - (7)].str),mm_strdup("from"),(yyvsp[(6) - (7)].str),(yyvsp[(7) - (7)].str)); +;} + break; + + case 897: + +/* Line 1455 of yacc.c */ +#line 5995 "preproc.y" + { + (yyval.str) = cat_str(7,mm_strdup("revoke grant option for"),(yyvsp[(5) - (10)].str),mm_strdup("on"),(yyvsp[(7) - (10)].str),mm_strdup("from"),(yyvsp[(9) - (10)].str),(yyvsp[(10) - (10)].str)); +;} + break; + + case 898: + +/* Line 1455 of yacc.c */ +#line 6003 "preproc.y" + { + (yyval.str) = mm_strdup("tables"); +;} + break; + + case 899: + +/* Line 1455 of yacc.c */ +#line 6007 "preproc.y" + { + (yyval.str) = mm_strdup("functions"); +;} + break; + + case 900: + +/* Line 1455 of yacc.c */ +#line 6011 "preproc.y" + { + (yyval.str) = mm_strdup("sequences"); +;} + break; + + case 901: + +/* Line 1455 of yacc.c */ +#line 6015 "preproc.y" + { + (yyval.str) = mm_strdup("types"); +;} + break; + + case 902: + +/* Line 1455 of yacc.c */ +#line 6023 "preproc.y" + { + (yyval.str) = cat_str(14,mm_strdup("create"),(yyvsp[(2) - (14)].str),mm_strdup("index"),(yyvsp[(4) - (14)].str),(yyvsp[(5) - (14)].str),mm_strdup("on"),(yyvsp[(7) - (14)].str),(yyvsp[(8) - (14)].str),mm_strdup("("),(yyvsp[(10) - (14)].str),mm_strdup(")"),(yyvsp[(12) - (14)].str),(yyvsp[(13) - (14)].str),(yyvsp[(14) - (14)].str)); +;} + break; + + case 903: + +/* Line 1455 of yacc.c */ +#line 6031 "preproc.y" + { + (yyval.str) = mm_strdup("unique"); +;} + break; + + case 904: + +/* Line 1455 of yacc.c */ +#line 6035 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 905: + +/* Line 1455 of yacc.c */ +#line 6042 "preproc.y" + { + (yyval.str) = mm_strdup("concurrently"); +;} + break; + + case 906: + +/* Line 1455 of yacc.c */ +#line 6046 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 907: + +/* Line 1455 of yacc.c */ +#line 6053 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 908: + +/* Line 1455 of yacc.c */ +#line 6057 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 909: + +/* Line 1455 of yacc.c */ +#line 6064 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("using"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 910: + +/* Line 1455 of yacc.c */ +#line 6068 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 911: + +/* Line 1455 of yacc.c */ +#line 6075 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 912: + +/* Line 1455 of yacc.c */ +#line 6079 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 913: + +/* Line 1455 of yacc.c */ +#line 6087 "preproc.y" + { + (yyval.str) = cat_str(5,(yyvsp[(1) - (5)].str),(yyvsp[(2) - (5)].str),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 914: + +/* Line 1455 of yacc.c */ +#line 6091 "preproc.y" + { + (yyval.str) = cat_str(5,(yyvsp[(1) - (5)].str),(yyvsp[(2) - (5)].str),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 915: + +/* Line 1455 of yacc.c */ +#line 6095 "preproc.y" + { + (yyval.str) = cat_str(7,mm_strdup("("),(yyvsp[(2) - (7)].str),mm_strdup(")"),(yyvsp[(4) - (7)].str),(yyvsp[(5) - (7)].str),(yyvsp[(6) - (7)].str),(yyvsp[(7) - (7)].str)); +;} + break; + + case 916: + +/* Line 1455 of yacc.c */ +#line 6103 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("collate"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 917: + +/* Line 1455 of yacc.c */ +#line 6107 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 918: + +/* Line 1455 of yacc.c */ +#line 6114 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 919: + +/* Line 1455 of yacc.c */ +#line 6118 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("using"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 920: + +/* Line 1455 of yacc.c */ +#line 6122 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 921: + +/* Line 1455 of yacc.c */ +#line 6129 "preproc.y" + { + (yyval.str) = mm_strdup("asc"); +;} + break; + + case 922: + +/* Line 1455 of yacc.c */ +#line 6133 "preproc.y" + { + (yyval.str) = mm_strdup("desc"); +;} + break; + + case 923: + +/* Line 1455 of yacc.c */ +#line 6137 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 924: + +/* Line 1455 of yacc.c */ +#line 6144 "preproc.y" + { + (yyval.str) = mm_strdup("nulls first"); +;} + break; + + case 925: + +/* Line 1455 of yacc.c */ +#line 6148 "preproc.y" + { + (yyval.str) = mm_strdup("nulls last"); +;} + break; + + case 926: + +/* Line 1455 of yacc.c */ +#line 6152 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 927: + +/* Line 1455 of yacc.c */ +#line 6159 "preproc.y" + { + (yyval.str) = cat_str(9,mm_strdup("create"),(yyvsp[(2) - (9)].str),mm_strdup("function"),(yyvsp[(4) - (9)].str),(yyvsp[(5) - (9)].str),mm_strdup("returns"),(yyvsp[(7) - (9)].str),(yyvsp[(8) - (9)].str),(yyvsp[(9) - (9)].str)); +;} + break; + + case 928: + +/* Line 1455 of yacc.c */ +#line 6163 "preproc.y" + { + (yyval.str) = cat_str(10,mm_strdup("create"),(yyvsp[(2) - (12)].str),mm_strdup("function"),(yyvsp[(4) - (12)].str),(yyvsp[(5) - (12)].str),mm_strdup("returns table ("),(yyvsp[(9) - (12)].str),mm_strdup(")"),(yyvsp[(11) - (12)].str),(yyvsp[(12) - (12)].str)); +;} + break; + + case 929: + +/* Line 1455 of yacc.c */ +#line 6167 "preproc.y" + { + (yyval.str) = cat_str(7,mm_strdup("create"),(yyvsp[(2) - (7)].str),mm_strdup("function"),(yyvsp[(4) - (7)].str),(yyvsp[(5) - (7)].str),(yyvsp[(6) - (7)].str),(yyvsp[(7) - (7)].str)); +;} + break; + + case 930: + +/* Line 1455 of yacc.c */ +#line 6175 "preproc.y" + { + (yyval.str) = mm_strdup("or replace"); +;} + break; + + case 931: + +/* Line 1455 of yacc.c */ +#line 6179 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 932: + +/* Line 1455 of yacc.c */ +#line 6186 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (3)].str),mm_strdup(")")); +;} + break; + + case 933: + +/* Line 1455 of yacc.c */ +#line 6190 "preproc.y" + { + (yyval.str) = mm_strdup("( )"); +;} + break; + + case 934: + +/* Line 1455 of yacc.c */ +#line 6198 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 935: + +/* Line 1455 of yacc.c */ +#line 6202 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 936: + +/* Line 1455 of yacc.c */ +#line 6210 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (3)].str),mm_strdup(")")); +;} + break; + + case 937: + +/* Line 1455 of yacc.c */ +#line 6214 "preproc.y" + { + (yyval.str) = mm_strdup("( )"); +;} + break; + + case 938: + +/* Line 1455 of yacc.c */ +#line 6222 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 939: + +/* Line 1455 of yacc.c */ +#line 6226 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 940: + +/* Line 1455 of yacc.c */ +#line 6234 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 941: + +/* Line 1455 of yacc.c */ +#line 6238 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 942: + +/* Line 1455 of yacc.c */ +#line 6242 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 943: + +/* Line 1455 of yacc.c */ +#line 6246 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 944: + +/* Line 1455 of yacc.c */ +#line 6250 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 945: + +/* Line 1455 of yacc.c */ +#line 6258 "preproc.y" + { + (yyval.str) = mm_strdup("in"); +;} + break; + + case 946: + +/* Line 1455 of yacc.c */ +#line 6262 "preproc.y" + { + (yyval.str) = mm_strdup("out"); +;} + break; + + case 947: + +/* Line 1455 of yacc.c */ +#line 6266 "preproc.y" + { + (yyval.str) = mm_strdup("inout"); +;} + break; + + case 948: + +/* Line 1455 of yacc.c */ +#line 6270 "preproc.y" + { + (yyval.str) = mm_strdup("in out"); +;} + break; + + case 949: + +/* Line 1455 of yacc.c */ +#line 6274 "preproc.y" + { + (yyval.str) = mm_strdup("variadic"); +;} + break; + + case 950: + +/* Line 1455 of yacc.c */ +#line 6282 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 951: + +/* Line 1455 of yacc.c */ +#line 6290 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 952: + +/* Line 1455 of yacc.c */ +#line 6298 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 953: + +/* Line 1455 of yacc.c */ +#line 6302 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (4)].str),(yyvsp[(2) - (4)].str),mm_strdup("% type")); +;} + break; + + case 954: + +/* Line 1455 of yacc.c */ +#line 6306 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("setof"),(yyvsp[(2) - (5)].str),(yyvsp[(3) - (5)].str),mm_strdup("% type")); +;} + break; + + case 955: + +/* Line 1455 of yacc.c */ +#line 6314 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 956: + +/* Line 1455 of yacc.c */ +#line 6318 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("default"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 957: + +/* Line 1455 of yacc.c */ +#line 6322 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("="),(yyvsp[(3) - (3)].str)); +;} + break; + + case 958: + +/* Line 1455 of yacc.c */ +#line 6330 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 959: + +/* Line 1455 of yacc.c */ +#line 6334 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 960: + +/* Line 1455 of yacc.c */ +#line 6342 "preproc.y" + { + (yyval.str) = mm_strdup("called on null input"); +;} + break; + + case 961: + +/* Line 1455 of yacc.c */ +#line 6346 "preproc.y" + { + (yyval.str) = mm_strdup("returns null on null input"); +;} + break; + + case 962: + +/* Line 1455 of yacc.c */ +#line 6350 "preproc.y" + { + (yyval.str) = mm_strdup("strict"); +;} + break; + + case 963: + +/* Line 1455 of yacc.c */ +#line 6354 "preproc.y" + { + (yyval.str) = mm_strdup("immutable"); +;} + break; + + case 964: + +/* Line 1455 of yacc.c */ +#line 6358 "preproc.y" + { + (yyval.str) = mm_strdup("stable"); +;} + break; + + case 965: + +/* Line 1455 of yacc.c */ +#line 6362 "preproc.y" + { + (yyval.str) = mm_strdup("volatile"); +;} + break; + + case 966: + +/* Line 1455 of yacc.c */ +#line 6366 "preproc.y" + { + (yyval.str) = mm_strdup("external security definer"); +;} + break; + + case 967: + +/* Line 1455 of yacc.c */ +#line 6370 "preproc.y" + { + (yyval.str) = mm_strdup("external security invoker"); +;} + break; + + case 968: + +/* Line 1455 of yacc.c */ +#line 6374 "preproc.y" + { + (yyval.str) = mm_strdup("security definer"); +;} + break; + + case 969: + +/* Line 1455 of yacc.c */ +#line 6378 "preproc.y" + { + (yyval.str) = mm_strdup("security invoker"); +;} + break; + + case 970: + +/* Line 1455 of yacc.c */ +#line 6382 "preproc.y" + { + (yyval.str) = mm_strdup("leakproof"); +;} + break; + + case 971: + +/* Line 1455 of yacc.c */ +#line 6386 "preproc.y" + { + (yyval.str) = mm_strdup("not leakproof"); +;} + break; + + case 972: + +/* Line 1455 of yacc.c */ +#line 6390 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("cost"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 973: + +/* Line 1455 of yacc.c */ +#line 6394 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("rows"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 974: + +/* Line 1455 of yacc.c */ +#line 6398 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 975: + +/* Line 1455 of yacc.c */ +#line 6406 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("as"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 976: + +/* Line 1455 of yacc.c */ +#line 6410 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("language"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 977: + +/* Line 1455 of yacc.c */ +#line 6414 "preproc.y" + { + (yyval.str) = mm_strdup("window"); +;} + break; + + case 978: + +/* Line 1455 of yacc.c */ +#line 6418 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 979: + +/* Line 1455 of yacc.c */ +#line 6426 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 980: + +/* Line 1455 of yacc.c */ +#line 6430 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 981: + +/* Line 1455 of yacc.c */ +#line 6438 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("with"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 982: + +/* Line 1455 of yacc.c */ +#line 6442 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 983: + +/* Line 1455 of yacc.c */ +#line 6449 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 984: + +/* Line 1455 of yacc.c */ +#line 6457 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 985: + +/* Line 1455 of yacc.c */ +#line 6461 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 986: + +/* Line 1455 of yacc.c */ +#line 6469 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter function"),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 987: + +/* Line 1455 of yacc.c */ +#line 6477 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 988: + +/* Line 1455 of yacc.c */ +#line 6481 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 989: + +/* Line 1455 of yacc.c */ +#line 6489 "preproc.y" + { + (yyval.str) = mm_strdup("restrict"); +;} + break; + + case 990: + +/* Line 1455 of yacc.c */ +#line 6493 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 991: + +/* Line 1455 of yacc.c */ +#line 6500 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("drop function"),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 992: + +/* Line 1455 of yacc.c */ +#line 6504 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("drop function if exists"),(yyvsp[(5) - (7)].str),(yyvsp[(6) - (7)].str),(yyvsp[(7) - (7)].str)); +;} + break; + + case 993: + +/* Line 1455 of yacc.c */ +#line 6512 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("drop aggregate"),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 994: + +/* Line 1455 of yacc.c */ +#line 6516 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("drop aggregate if exists"),(yyvsp[(5) - (7)].str),(yyvsp[(6) - (7)].str),(yyvsp[(7) - (7)].str)); +;} + break; + + case 995: + +/* Line 1455 of yacc.c */ +#line 6524 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("drop operator"),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 996: + +/* Line 1455 of yacc.c */ +#line 6528 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("drop operator if exists"),(yyvsp[(5) - (7)].str),(yyvsp[(6) - (7)].str),(yyvsp[(7) - (7)].str)); +;} + break; + + case 997: + +/* Line 1455 of yacc.c */ +#line 6536 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (3)].str),mm_strdup(")")); +;} + break; + + case 998: + +/* Line 1455 of yacc.c */ +#line 6540 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("("),(yyvsp[(2) - (5)].str),mm_strdup(","),(yyvsp[(4) - (5)].str),mm_strdup(")")); +;} + break; + + case 999: + +/* Line 1455 of yacc.c */ +#line 6544 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("( none ,"),(yyvsp[(4) - (5)].str),mm_strdup(")")); +;} + break; + + case 1000: + +/* Line 1455 of yacc.c */ +#line 6548 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (5)].str),mm_strdup(", none )")); +;} + break; + + case 1001: + +/* Line 1455 of yacc.c */ +#line 6556 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1002: + +/* Line 1455 of yacc.c */ +#line 6560 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("."),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1003: + +/* Line 1455 of yacc.c */ +#line 6568 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("do"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1004: + +/* Line 1455 of yacc.c */ +#line 6576 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1005: + +/* Line 1455 of yacc.c */ +#line 6580 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1006: + +/* Line 1455 of yacc.c */ +#line 6588 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1007: + +/* Line 1455 of yacc.c */ +#line 6592 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("language"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1008: + +/* Line 1455 of yacc.c */ +#line 6600 "preproc.y" + { + (yyval.str) = cat_str(7,mm_strdup("create cast ("),(yyvsp[(4) - (11)].str),mm_strdup("as"),(yyvsp[(6) - (11)].str),mm_strdup(") with function"),(yyvsp[(10) - (11)].str),(yyvsp[(11) - (11)].str)); +;} + break; + + case 1009: + +/* Line 1455 of yacc.c */ +#line 6604 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("create cast ("),(yyvsp[(4) - (10)].str),mm_strdup("as"),(yyvsp[(6) - (10)].str),mm_strdup(") without function"),(yyvsp[(10) - (10)].str)); +;} + break; + + case 1010: + +/* Line 1455 of yacc.c */ +#line 6608 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("create cast ("),(yyvsp[(4) - (10)].str),mm_strdup("as"),(yyvsp[(6) - (10)].str),mm_strdup(") with inout"),(yyvsp[(10) - (10)].str)); +;} + break; + + case 1011: + +/* Line 1455 of yacc.c */ +#line 6616 "preproc.y" + { + (yyval.str) = mm_strdup("as implicit"); +;} + break; + + case 1012: + +/* Line 1455 of yacc.c */ +#line 6620 "preproc.y" + { + (yyval.str) = mm_strdup("as assignment"); +;} + break; + + case 1013: + +/* Line 1455 of yacc.c */ +#line 6624 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1014: + +/* Line 1455 of yacc.c */ +#line 6631 "preproc.y" + { + (yyval.str) = cat_str(8,mm_strdup("drop cast"),(yyvsp[(3) - (9)].str),mm_strdup("("),(yyvsp[(5) - (9)].str),mm_strdup("as"),(yyvsp[(7) - (9)].str),mm_strdup(")"),(yyvsp[(9) - (9)].str)); +;} + break; + + case 1015: + +/* Line 1455 of yacc.c */ +#line 6639 "preproc.y" + { + (yyval.str) = mm_strdup("if exists"); +;} + break; + + case 1016: + +/* Line 1455 of yacc.c */ +#line 6643 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1017: + +/* Line 1455 of yacc.c */ +#line 6650 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("reindex"),(yyvsp[(2) - (4)].str),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1018: + +/* Line 1455 of yacc.c */ +#line 6654 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("reindex system"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1019: + +/* Line 1455 of yacc.c */ +#line 6658 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("reindex database"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1020: + +/* Line 1455 of yacc.c */ +#line 6666 "preproc.y" + { + (yyval.str) = mm_strdup("index"); +;} + break; + + case 1021: + +/* Line 1455 of yacc.c */ +#line 6670 "preproc.y" + { + (yyval.str) = mm_strdup("table"); +;} + break; + + case 1022: + +/* Line 1455 of yacc.c */ +#line 6678 "preproc.y" + { + (yyval.str) = mm_strdup("force"); +;} + break; + + case 1023: + +/* Line 1455 of yacc.c */ +#line 6682 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1024: + +/* Line 1455 of yacc.c */ +#line 6689 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter aggregate"),(yyvsp[(3) - (7)].str),(yyvsp[(4) - (7)].str),mm_strdup("rename to"),(yyvsp[(7) - (7)].str)); +;} + break; + + case 1025: + +/* Line 1455 of yacc.c */ +#line 6693 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter collation"),(yyvsp[(3) - (6)].str),mm_strdup("rename to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1026: + +/* Line 1455 of yacc.c */ +#line 6697 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter conversion"),(yyvsp[(3) - (6)].str),mm_strdup("rename to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1027: + +/* Line 1455 of yacc.c */ +#line 6701 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter database"),(yyvsp[(3) - (6)].str),mm_strdup("rename to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1028: + +/* Line 1455 of yacc.c */ +#line 6705 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter domain"),(yyvsp[(3) - (6)].str),mm_strdup("rename to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1029: + +/* Line 1455 of yacc.c */ +#line 6709 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("alter domain"),(yyvsp[(3) - (8)].str),mm_strdup("rename constraint"),(yyvsp[(6) - (8)].str),mm_strdup("to"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1030: + +/* Line 1455 of yacc.c */ +#line 6713 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter foreign data wrapper"),(yyvsp[(5) - (8)].str),mm_strdup("rename to"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1031: + +/* Line 1455 of yacc.c */ +#line 6717 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter function"),(yyvsp[(3) - (6)].str),mm_strdup("rename to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1032: + +/* Line 1455 of yacc.c */ +#line 6721 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter group"),(yyvsp[(3) - (6)].str),mm_strdup("rename to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1033: + +/* Line 1455 of yacc.c */ +#line 6725 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("alter"),(yyvsp[(2) - (7)].str),mm_strdup("language"),(yyvsp[(4) - (7)].str),mm_strdup("rename to"),(yyvsp[(7) - (7)].str)); +;} + break; + + case 1034: + +/* Line 1455 of yacc.c */ +#line 6729 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("alter operator class"),(yyvsp[(4) - (9)].str),mm_strdup("using"),(yyvsp[(6) - (9)].str),mm_strdup("rename to"),(yyvsp[(9) - (9)].str)); +;} + break; + + case 1035: + +/* Line 1455 of yacc.c */ +#line 6733 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("alter operator family"),(yyvsp[(4) - (9)].str),mm_strdup("using"),(yyvsp[(6) - (9)].str),mm_strdup("rename to"),(yyvsp[(9) - (9)].str)); +;} + break; + + case 1036: + +/* Line 1455 of yacc.c */ +#line 6737 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter schema"),(yyvsp[(3) - (6)].str),mm_strdup("rename to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1037: + +/* Line 1455 of yacc.c */ +#line 6741 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter server"),(yyvsp[(3) - (6)].str),mm_strdup("rename to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1038: + +/* Line 1455 of yacc.c */ +#line 6745 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter table"),(yyvsp[(3) - (6)].str),mm_strdup("rename to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1039: + +/* Line 1455 of yacc.c */ +#line 6749 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter table if exists"),(yyvsp[(5) - (8)].str),mm_strdup("rename to"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1040: + +/* Line 1455 of yacc.c */ +#line 6753 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter sequence"),(yyvsp[(3) - (6)].str),mm_strdup("rename to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1041: + +/* Line 1455 of yacc.c */ +#line 6757 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter sequence if exists"),(yyvsp[(5) - (8)].str),mm_strdup("rename to"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1042: + +/* Line 1455 of yacc.c */ +#line 6761 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter view"),(yyvsp[(3) - (6)].str),mm_strdup("rename to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1043: + +/* Line 1455 of yacc.c */ +#line 6765 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter view if exists"),(yyvsp[(5) - (8)].str),mm_strdup("rename to"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1044: + +/* Line 1455 of yacc.c */ +#line 6769 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter index"),(yyvsp[(3) - (6)].str),mm_strdup("rename to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1045: + +/* Line 1455 of yacc.c */ +#line 6773 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter index if exists"),(yyvsp[(5) - (8)].str),mm_strdup("rename to"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1046: + +/* Line 1455 of yacc.c */ +#line 6777 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter foreign table"),(yyvsp[(4) - (7)].str),mm_strdup("rename to"),(yyvsp[(7) - (7)].str)); +;} + break; + + case 1047: + +/* Line 1455 of yacc.c */ +#line 6781 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter foreign table if exists"),(yyvsp[(6) - (9)].str),mm_strdup("rename to"),(yyvsp[(9) - (9)].str)); +;} + break; + + case 1048: + +/* Line 1455 of yacc.c */ +#line 6785 "preproc.y" + { + (yyval.str) = cat_str(7,mm_strdup("alter table"),(yyvsp[(3) - (8)].str),mm_strdup("rename"),(yyvsp[(5) - (8)].str),(yyvsp[(6) - (8)].str),mm_strdup("to"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1049: + +/* Line 1455 of yacc.c */ +#line 6789 "preproc.y" + { + (yyval.str) = cat_str(7,mm_strdup("alter table if exists"),(yyvsp[(5) - (10)].str),mm_strdup("rename"),(yyvsp[(7) - (10)].str),(yyvsp[(8) - (10)].str),mm_strdup("to"),(yyvsp[(10) - (10)].str)); +;} + break; + + case 1050: + +/* Line 1455 of yacc.c */ +#line 6793 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("alter table"),(yyvsp[(3) - (8)].str),mm_strdup("rename constraint"),(yyvsp[(6) - (8)].str),mm_strdup("to"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1051: + +/* Line 1455 of yacc.c */ +#line 6797 "preproc.y" + { + (yyval.str) = cat_str(7,mm_strdup("alter foreign table"),(yyvsp[(4) - (9)].str),mm_strdup("rename"),(yyvsp[(6) - (9)].str),(yyvsp[(7) - (9)].str),mm_strdup("to"),(yyvsp[(9) - (9)].str)); +;} + break; + + case 1052: + +/* Line 1455 of yacc.c */ +#line 6801 "preproc.y" + { + (yyval.str) = cat_str(7,mm_strdup("alter foreign table if exists"),(yyvsp[(6) - (11)].str),mm_strdup("rename"),(yyvsp[(8) - (11)].str),(yyvsp[(9) - (11)].str),mm_strdup("to"),(yyvsp[(11) - (11)].str)); +;} + break; + + case 1053: + +/* Line 1455 of yacc.c */ +#line 6805 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("alter trigger"),(yyvsp[(3) - (8)].str),mm_strdup("on"),(yyvsp[(5) - (8)].str),mm_strdup("rename to"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1054: + +/* Line 1455 of yacc.c */ +#line 6809 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter role"),(yyvsp[(3) - (6)].str),mm_strdup("rename to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1055: + +/* Line 1455 of yacc.c */ +#line 6813 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter user"),(yyvsp[(3) - (6)].str),mm_strdup("rename to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1056: + +/* Line 1455 of yacc.c */ +#line 6817 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter tablespace"),(yyvsp[(3) - (6)].str),mm_strdup("rename to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1057: + +/* Line 1455 of yacc.c */ +#line 6821 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter tablespace"),(yyvsp[(3) - (5)].str),mm_strdup("set"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1058: + +/* Line 1455 of yacc.c */ +#line 6825 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter tablespace"),(yyvsp[(3) - (5)].str),mm_strdup("reset"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1059: + +/* Line 1455 of yacc.c */ +#line 6829 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter text search parser"),(yyvsp[(5) - (8)].str),mm_strdup("rename to"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1060: + +/* Line 1455 of yacc.c */ +#line 6833 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter text search dictionary"),(yyvsp[(5) - (8)].str),mm_strdup("rename to"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1061: + +/* Line 1455 of yacc.c */ +#line 6837 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter text search template"),(yyvsp[(5) - (8)].str),mm_strdup("rename to"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1062: + +/* Line 1455 of yacc.c */ +#line 6841 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter text search configuration"),(yyvsp[(5) - (8)].str),mm_strdup("rename to"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1063: + +/* Line 1455 of yacc.c */ +#line 6845 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter type"),(yyvsp[(3) - (6)].str),mm_strdup("rename to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1064: + +/* Line 1455 of yacc.c */ +#line 6849 "preproc.y" + { + (yyval.str) = cat_str(7,mm_strdup("alter type"),(yyvsp[(3) - (9)].str),mm_strdup("rename attribute"),(yyvsp[(6) - (9)].str),mm_strdup("to"),(yyvsp[(8) - (9)].str),(yyvsp[(9) - (9)].str)); +;} + break; + + case 1065: + +/* Line 1455 of yacc.c */ +#line 6857 "preproc.y" + { + (yyval.str) = mm_strdup("column"); +;} + break; + + case 1066: + +/* Line 1455 of yacc.c */ +#line 6861 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1067: + +/* Line 1455 of yacc.c */ +#line 6868 "preproc.y" + { + (yyval.str) = mm_strdup("set data"); +;} + break; + + case 1068: + +/* Line 1455 of yacc.c */ +#line 6872 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1069: + +/* Line 1455 of yacc.c */ +#line 6879 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter aggregate"),(yyvsp[(3) - (7)].str),(yyvsp[(4) - (7)].str),mm_strdup("set schema"),(yyvsp[(7) - (7)].str)); +;} + break; + + case 1070: + +/* Line 1455 of yacc.c */ +#line 6883 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter collation"),(yyvsp[(3) - (6)].str),mm_strdup("set schema"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1071: + +/* Line 1455 of yacc.c */ +#line 6887 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter conversion"),(yyvsp[(3) - (6)].str),mm_strdup("set schema"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1072: + +/* Line 1455 of yacc.c */ +#line 6891 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter domain"),(yyvsp[(3) - (6)].str),mm_strdup("set schema"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1073: + +/* Line 1455 of yacc.c */ +#line 6895 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter extension"),(yyvsp[(3) - (6)].str),mm_strdup("set schema"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1074: + +/* Line 1455 of yacc.c */ +#line 6899 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter function"),(yyvsp[(3) - (6)].str),mm_strdup("set schema"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1075: + +/* Line 1455 of yacc.c */ +#line 6903 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter operator"),(yyvsp[(3) - (7)].str),(yyvsp[(4) - (7)].str),mm_strdup("set schema"),(yyvsp[(7) - (7)].str)); +;} + break; + + case 1076: + +/* Line 1455 of yacc.c */ +#line 6907 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("alter operator class"),(yyvsp[(4) - (9)].str),mm_strdup("using"),(yyvsp[(6) - (9)].str),mm_strdup("set schema"),(yyvsp[(9) - (9)].str)); +;} + break; + + case 1077: + +/* Line 1455 of yacc.c */ +#line 6911 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("alter operator family"),(yyvsp[(4) - (9)].str),mm_strdup("using"),(yyvsp[(6) - (9)].str),mm_strdup("set schema"),(yyvsp[(9) - (9)].str)); +;} + break; + + case 1078: + +/* Line 1455 of yacc.c */ +#line 6915 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter table"),(yyvsp[(3) - (6)].str),mm_strdup("set schema"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1079: + +/* Line 1455 of yacc.c */ +#line 6919 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter table if exists"),(yyvsp[(5) - (8)].str),mm_strdup("set schema"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1080: + +/* Line 1455 of yacc.c */ +#line 6923 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter text search parser"),(yyvsp[(5) - (8)].str),mm_strdup("set schema"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1081: + +/* Line 1455 of yacc.c */ +#line 6927 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter text search dictionary"),(yyvsp[(5) - (8)].str),mm_strdup("set schema"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1082: + +/* Line 1455 of yacc.c */ +#line 6931 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter text search template"),(yyvsp[(5) - (8)].str),mm_strdup("set schema"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1083: + +/* Line 1455 of yacc.c */ +#line 6935 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter text search configuration"),(yyvsp[(5) - (8)].str),mm_strdup("set schema"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1084: + +/* Line 1455 of yacc.c */ +#line 6939 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter sequence"),(yyvsp[(3) - (6)].str),mm_strdup("set schema"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1085: + +/* Line 1455 of yacc.c */ +#line 6943 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter sequence if exists"),(yyvsp[(5) - (8)].str),mm_strdup("set schema"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1086: + +/* Line 1455 of yacc.c */ +#line 6947 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter view"),(yyvsp[(3) - (6)].str),mm_strdup("set schema"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1087: + +/* Line 1455 of yacc.c */ +#line 6951 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter view if exists"),(yyvsp[(5) - (8)].str),mm_strdup("set schema"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1088: + +/* Line 1455 of yacc.c */ +#line 6955 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter foreign table"),(yyvsp[(4) - (7)].str),mm_strdup("set schema"),(yyvsp[(7) - (7)].str)); +;} + break; + + case 1089: + +/* Line 1455 of yacc.c */ +#line 6959 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter foreign table if exists"),(yyvsp[(6) - (9)].str),mm_strdup("set schema"),(yyvsp[(9) - (9)].str)); +;} + break; + + case 1090: + +/* Line 1455 of yacc.c */ +#line 6963 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter type"),(yyvsp[(3) - (6)].str),mm_strdup("set schema"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1091: + +/* Line 1455 of yacc.c */ +#line 6971 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter aggregate"),(yyvsp[(3) - (7)].str),(yyvsp[(4) - (7)].str),mm_strdup("owner to"),(yyvsp[(7) - (7)].str)); +;} + break; + + case 1092: + +/* Line 1455 of yacc.c */ +#line 6975 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter collation"),(yyvsp[(3) - (6)].str),mm_strdup("owner to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1093: + +/* Line 1455 of yacc.c */ +#line 6979 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter conversion"),(yyvsp[(3) - (6)].str),mm_strdup("owner to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1094: + +/* Line 1455 of yacc.c */ +#line 6983 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter database"),(yyvsp[(3) - (6)].str),mm_strdup("owner to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1095: + +/* Line 1455 of yacc.c */ +#line 6987 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter domain"),(yyvsp[(3) - (6)].str),mm_strdup("owner to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1096: + +/* Line 1455 of yacc.c */ +#line 6991 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter function"),(yyvsp[(3) - (6)].str),mm_strdup("owner to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1097: + +/* Line 1455 of yacc.c */ +#line 6995 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("alter"),(yyvsp[(2) - (7)].str),mm_strdup("language"),(yyvsp[(4) - (7)].str),mm_strdup("owner to"),(yyvsp[(7) - (7)].str)); +;} + break; + + case 1098: + +/* Line 1455 of yacc.c */ +#line 6999 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter large object"),(yyvsp[(4) - (7)].str),mm_strdup("owner to"),(yyvsp[(7) - (7)].str)); +;} + break; + + case 1099: + +/* Line 1455 of yacc.c */ +#line 7003 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter operator"),(yyvsp[(3) - (7)].str),(yyvsp[(4) - (7)].str),mm_strdup("owner to"),(yyvsp[(7) - (7)].str)); +;} + break; + + case 1100: + +/* Line 1455 of yacc.c */ +#line 7007 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("alter operator class"),(yyvsp[(4) - (9)].str),mm_strdup("using"),(yyvsp[(6) - (9)].str),mm_strdup("owner to"),(yyvsp[(9) - (9)].str)); +;} + break; + + case 1101: + +/* Line 1455 of yacc.c */ +#line 7011 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("alter operator family"),(yyvsp[(4) - (9)].str),mm_strdup("using"),(yyvsp[(6) - (9)].str),mm_strdup("owner to"),(yyvsp[(9) - (9)].str)); +;} + break; + + case 1102: + +/* Line 1455 of yacc.c */ +#line 7015 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter schema"),(yyvsp[(3) - (6)].str),mm_strdup("owner to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1103: + +/* Line 1455 of yacc.c */ +#line 7019 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter type"),(yyvsp[(3) - (6)].str),mm_strdup("owner to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1104: + +/* Line 1455 of yacc.c */ +#line 7023 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter tablespace"),(yyvsp[(3) - (6)].str),mm_strdup("owner to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1105: + +/* Line 1455 of yacc.c */ +#line 7027 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter text search dictionary"),(yyvsp[(5) - (8)].str),mm_strdup("owner to"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1106: + +/* Line 1455 of yacc.c */ +#line 7031 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter text search configuration"),(yyvsp[(5) - (8)].str),mm_strdup("owner to"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1107: + +/* Line 1455 of yacc.c */ +#line 7035 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter foreign data wrapper"),(yyvsp[(5) - (8)].str),mm_strdup("owner to"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1108: + +/* Line 1455 of yacc.c */ +#line 7039 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter server"),(yyvsp[(3) - (6)].str),mm_strdup("owner to"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1109: + +/* Line 1455 of yacc.c */ +#line 7047 "preproc.y" + { + (yyval.str) = cat_str(12,mm_strdup("create"),(yyvsp[(2) - (13)].str),mm_strdup("rule"),(yyvsp[(4) - (13)].str),mm_strdup("as on"),(yyvsp[(7) - (13)].str),mm_strdup("to"),(yyvsp[(9) - (13)].str),(yyvsp[(10) - (13)].str),mm_strdup("do"),(yyvsp[(12) - (13)].str),(yyvsp[(13) - (13)].str)); +;} + break; + + case 1110: + +/* Line 1455 of yacc.c */ +#line 7055 "preproc.y" + { + (yyval.str) = mm_strdup("nothing"); +;} + break; + + case 1111: + +/* Line 1455 of yacc.c */ +#line 7059 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1112: + +/* Line 1455 of yacc.c */ +#line 7063 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (3)].str),mm_strdup(")")); +;} + break; + + case 1113: + +/* Line 1455 of yacc.c */ +#line 7071 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(";"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1114: + +/* Line 1455 of yacc.c */ +#line 7075 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1115: + +/* Line 1455 of yacc.c */ +#line 7083 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1116: + +/* Line 1455 of yacc.c */ +#line 7087 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1117: + +/* Line 1455 of yacc.c */ +#line 7091 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1118: + +/* Line 1455 of yacc.c */ +#line 7095 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1119: + +/* Line 1455 of yacc.c */ +#line 7099 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1120: + +/* Line 1455 of yacc.c */ +#line 7107 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1121: + +/* Line 1455 of yacc.c */ +#line 7111 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1122: + +/* Line 1455 of yacc.c */ +#line 7118 "preproc.y" + { + (yyval.str) = mm_strdup("select"); +;} + break; + + case 1123: + +/* Line 1455 of yacc.c */ +#line 7122 "preproc.y" + { + (yyval.str) = mm_strdup("update"); +;} + break; + + case 1124: + +/* Line 1455 of yacc.c */ +#line 7126 "preproc.y" + { + (yyval.str) = mm_strdup("delete"); +;} + break; + + case 1125: + +/* Line 1455 of yacc.c */ +#line 7130 "preproc.y" + { + (yyval.str) = mm_strdup("insert"); +;} + break; + + case 1126: + +/* Line 1455 of yacc.c */ +#line 7138 "preproc.y" + { + (yyval.str) = mm_strdup("instead"); +;} + break; + + case 1127: + +/* Line 1455 of yacc.c */ +#line 7142 "preproc.y" + { + (yyval.str) = mm_strdup("also"); +;} + break; + + case 1128: + +/* Line 1455 of yacc.c */ +#line 7146 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1129: + +/* Line 1455 of yacc.c */ +#line 7153 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("drop rule"),(yyvsp[(3) - (6)].str),mm_strdup("on"),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1130: + +/* Line 1455 of yacc.c */ +#line 7157 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("drop rule if exists"),(yyvsp[(5) - (8)].str),mm_strdup("on"),(yyvsp[(7) - (8)].str),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1131: + +/* Line 1455 of yacc.c */ +#line 7165 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("notify"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1132: + +/* Line 1455 of yacc.c */ +#line 7173 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup(","),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1133: + +/* Line 1455 of yacc.c */ +#line 7177 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1134: + +/* Line 1455 of yacc.c */ +#line 7184 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("listen"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1135: + +/* Line 1455 of yacc.c */ +#line 7192 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("unlisten"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1136: + +/* Line 1455 of yacc.c */ +#line 7196 "preproc.y" + { + (yyval.str) = mm_strdup("unlisten *"); +;} + break; + + case 1137: + +/* Line 1455 of yacc.c */ +#line 7204 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("abort"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1138: + +/* Line 1455 of yacc.c */ +#line 7208 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("begin"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1139: + +/* Line 1455 of yacc.c */ +#line 7212 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("start transaction"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1140: + +/* Line 1455 of yacc.c */ +#line 7216 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("commit"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1141: + +/* Line 1455 of yacc.c */ +#line 7220 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("end"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1142: + +/* Line 1455 of yacc.c */ +#line 7224 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("rollback"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1143: + +/* Line 1455 of yacc.c */ +#line 7228 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("savepoint"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1144: + +/* Line 1455 of yacc.c */ +#line 7232 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("release savepoint"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1145: + +/* Line 1455 of yacc.c */ +#line 7236 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("release"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1146: + +/* Line 1455 of yacc.c */ +#line 7240 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("rollback"),(yyvsp[(2) - (5)].str),mm_strdup("to savepoint"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1147: + +/* Line 1455 of yacc.c */ +#line 7244 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("rollback"),(yyvsp[(2) - (4)].str),mm_strdup("to"),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1148: + +/* Line 1455 of yacc.c */ +#line 7248 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("prepare transaction"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1149: + +/* Line 1455 of yacc.c */ +#line 7252 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("commit prepared"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1150: + +/* Line 1455 of yacc.c */ +#line 7256 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("rollback prepared"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1151: + +/* Line 1455 of yacc.c */ +#line 7264 "preproc.y" + { + (yyval.str) = mm_strdup("work"); +;} + break; + + case 1152: + +/* Line 1455 of yacc.c */ +#line 7268 "preproc.y" + { + (yyval.str) = mm_strdup("transaction"); +;} + break; + + case 1153: + +/* Line 1455 of yacc.c */ +#line 7272 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1154: + +/* Line 1455 of yacc.c */ +#line 7279 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("isolation level"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1155: + +/* Line 1455 of yacc.c */ +#line 7283 "preproc.y" + { + (yyval.str) = mm_strdup("read only"); +;} + break; + + case 1156: + +/* Line 1455 of yacc.c */ +#line 7287 "preproc.y" + { + (yyval.str) = mm_strdup("read write"); +;} + break; + + case 1157: + +/* Line 1455 of yacc.c */ +#line 7291 "preproc.y" + { + (yyval.str) = mm_strdup("deferrable"); +;} + break; + + case 1158: + +/* Line 1455 of yacc.c */ +#line 7295 "preproc.y" + { + (yyval.str) = mm_strdup("not deferrable"); +;} + break; + + case 1159: + +/* Line 1455 of yacc.c */ +#line 7303 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1160: + +/* Line 1455 of yacc.c */ +#line 7307 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1161: + +/* Line 1455 of yacc.c */ +#line 7311 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1162: + +/* Line 1455 of yacc.c */ +#line 7319 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1163: + +/* Line 1455 of yacc.c */ +#line 7323 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1164: + +/* Line 1455 of yacc.c */ +#line 7330 "preproc.y" + { + (yyval.str) = cat_str(9,mm_strdup("create"),(yyvsp[(2) - (9)].str),mm_strdup("view"),(yyvsp[(4) - (9)].str),(yyvsp[(5) - (9)].str),(yyvsp[(6) - (9)].str),mm_strdup("as"),(yyvsp[(8) - (9)].str),(yyvsp[(9) - (9)].str)); +;} + break; + + case 1165: + +/* Line 1455 of yacc.c */ +#line 7334 "preproc.y" + { + (yyval.str) = cat_str(9,mm_strdup("create or replace"),(yyvsp[(4) - (11)].str),mm_strdup("view"),(yyvsp[(6) - (11)].str),(yyvsp[(7) - (11)].str),(yyvsp[(8) - (11)].str),mm_strdup("as"),(yyvsp[(10) - (11)].str),(yyvsp[(11) - (11)].str)); +;} + break; + + case 1166: + +/* Line 1455 of yacc.c */ +#line 7342 "preproc.y" + { +mmerror(PARSE_ERROR, ET_WARNING, "unsupported feature will be passed to server"); + (yyval.str) = mm_strdup("with check option"); +;} + break; + + case 1167: + +/* Line 1455 of yacc.c */ +#line 7347 "preproc.y" + { +mmerror(PARSE_ERROR, ET_WARNING, "unsupported feature will be passed to server"); + (yyval.str) = mm_strdup("with cascaded check option"); +;} + break; + + case 1168: + +/* Line 1455 of yacc.c */ +#line 7352 "preproc.y" + { +mmerror(PARSE_ERROR, ET_WARNING, "unsupported feature will be passed to server"); + (yyval.str) = mm_strdup("with local check option"); +;} + break; + + case 1169: + +/* Line 1455 of yacc.c */ +#line 7357 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1170: + +/* Line 1455 of yacc.c */ +#line 7364 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("load"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1171: + +/* Line 1455 of yacc.c */ +#line 7372 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("create database"),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1172: + +/* Line 1455 of yacc.c */ +#line 7380 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1173: + +/* Line 1455 of yacc.c */ +#line 7384 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1174: + +/* Line 1455 of yacc.c */ +#line 7391 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("tablespace"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1175: + +/* Line 1455 of yacc.c */ +#line 7395 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("tablespace"),(yyvsp[(2) - (3)].str),mm_strdup("default")); +;} + break; + + case 1176: + +/* Line 1455 of yacc.c */ +#line 7399 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("location"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1177: + +/* Line 1455 of yacc.c */ +#line 7403 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("location"),(yyvsp[(2) - (3)].str),mm_strdup("default")); +;} + break; + + case 1178: + +/* Line 1455 of yacc.c */ +#line 7407 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("template"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1179: + +/* Line 1455 of yacc.c */ +#line 7411 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("template"),(yyvsp[(2) - (3)].str),mm_strdup("default")); +;} + break; + + case 1180: + +/* Line 1455 of yacc.c */ +#line 7415 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("encoding"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1181: + +/* Line 1455 of yacc.c */ +#line 7419 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("encoding"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1182: + +/* Line 1455 of yacc.c */ +#line 7423 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("encoding"),(yyvsp[(2) - (3)].str),mm_strdup("default")); +;} + break; + + case 1183: + +/* Line 1455 of yacc.c */ +#line 7427 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("lc_collate"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1184: + +/* Line 1455 of yacc.c */ +#line 7431 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("lc_collate"),(yyvsp[(2) - (3)].str),mm_strdup("default")); +;} + break; + + case 1185: + +/* Line 1455 of yacc.c */ +#line 7435 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("lc_ctype"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1186: + +/* Line 1455 of yacc.c */ +#line 7439 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("lc_ctype"),(yyvsp[(2) - (3)].str),mm_strdup("default")); +;} + break; + + case 1187: + +/* Line 1455 of yacc.c */ +#line 7443 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("connection limit"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1188: + +/* Line 1455 of yacc.c */ +#line 7447 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("owner"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1189: + +/* Line 1455 of yacc.c */ +#line 7451 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("owner"),(yyvsp[(2) - (3)].str),mm_strdup("default")); +;} + break; + + case 1190: + +/* Line 1455 of yacc.c */ +#line 7459 "preproc.y" + { + (yyval.str) = mm_strdup("="); +;} + break; + + case 1191: + +/* Line 1455 of yacc.c */ +#line 7463 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1192: + +/* Line 1455 of yacc.c */ +#line 7470 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter database"),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1193: + +/* Line 1455 of yacc.c */ +#line 7474 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter database"),(yyvsp[(3) - (6)].str),mm_strdup("set tablespace"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1194: + +/* Line 1455 of yacc.c */ +#line 7482 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("alter database"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1195: + +/* Line 1455 of yacc.c */ +#line 7490 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1196: + +/* Line 1455 of yacc.c */ +#line 7494 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1197: + +/* Line 1455 of yacc.c */ +#line 7501 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("connection limit"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1198: + +/* Line 1455 of yacc.c */ +#line 7509 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("drop database"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1199: + +/* Line 1455 of yacc.c */ +#line 7513 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("drop database if exists"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1200: + +/* Line 1455 of yacc.c */ +#line 7521 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("create domain"),(yyvsp[(3) - (6)].str),(yyvsp[(4) - (6)].str),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1201: + +/* Line 1455 of yacc.c */ +#line 7529 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("alter domain"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1202: + +/* Line 1455 of yacc.c */ +#line 7533 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("alter domain"),(yyvsp[(3) - (6)].str),mm_strdup("drop not null")); +;} + break; + + case 1203: + +/* Line 1455 of yacc.c */ +#line 7537 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("alter domain"),(yyvsp[(3) - (6)].str),mm_strdup("set not null")); +;} + break; + + case 1204: + +/* Line 1455 of yacc.c */ +#line 7541 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter domain"),(yyvsp[(3) - (5)].str),mm_strdup("add"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1205: + +/* Line 1455 of yacc.c */ +#line 7545 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter domain"),(yyvsp[(3) - (7)].str),mm_strdup("drop constraint"),(yyvsp[(6) - (7)].str),(yyvsp[(7) - (7)].str)); +;} + break; + + case 1206: + +/* Line 1455 of yacc.c */ +#line 7549 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("alter domain"),(yyvsp[(3) - (9)].str),mm_strdup("drop constraint if exists"),(yyvsp[(8) - (9)].str),(yyvsp[(9) - (9)].str)); +;} + break; + + case 1207: + +/* Line 1455 of yacc.c */ +#line 7553 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter domain"),(yyvsp[(3) - (6)].str),mm_strdup("validate constraint"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1208: + +/* Line 1455 of yacc.c */ +#line 7561 "preproc.y" + { + (yyval.str) = mm_strdup("as"); +;} + break; + + case 1209: + +/* Line 1455 of yacc.c */ +#line 7565 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1210: + +/* Line 1455 of yacc.c */ +#line 7572 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("alter text search dictionary"),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1211: + +/* Line 1455 of yacc.c */ +#line 7580 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("alter text search configuration"),(yyvsp[(5) - (11)].str),mm_strdup("add mapping for"),(yyvsp[(9) - (11)].str),mm_strdup("with"),(yyvsp[(11) - (11)].str)); +;} + break; + + case 1212: + +/* Line 1455 of yacc.c */ +#line 7584 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("alter text search configuration"),(yyvsp[(5) - (11)].str),mm_strdup("alter mapping for"),(yyvsp[(9) - (11)].str),mm_strdup("with"),(yyvsp[(11) - (11)].str)); +;} + break; + + case 1213: + +/* Line 1455 of yacc.c */ +#line 7588 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("alter text search configuration"),(yyvsp[(5) - (11)].str),mm_strdup("alter mapping replace"),(yyvsp[(9) - (11)].str),mm_strdup("with"),(yyvsp[(11) - (11)].str)); +;} + break; + + case 1214: + +/* Line 1455 of yacc.c */ +#line 7592 "preproc.y" + { + (yyval.str) = cat_str(8,mm_strdup("alter text search configuration"),(yyvsp[(5) - (13)].str),mm_strdup("alter mapping for"),(yyvsp[(9) - (13)].str),mm_strdup("replace"),(yyvsp[(11) - (13)].str),mm_strdup("with"),(yyvsp[(13) - (13)].str)); +;} + break; + + case 1215: + +/* Line 1455 of yacc.c */ +#line 7596 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter text search configuration"),(yyvsp[(5) - (9)].str),mm_strdup("drop mapping for"),(yyvsp[(9) - (9)].str)); +;} + break; + + case 1216: + +/* Line 1455 of yacc.c */ +#line 7600 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("alter text search configuration"),(yyvsp[(5) - (11)].str),mm_strdup("drop mapping if exists for"),(yyvsp[(11) - (11)].str)); +;} + break; + + case 1217: + +/* Line 1455 of yacc.c */ +#line 7608 "preproc.y" + { + (yyval.str) = cat_str(10,mm_strdup("create"),(yyvsp[(2) - (10)].str),mm_strdup("conversion"),(yyvsp[(4) - (10)].str),mm_strdup("for"),(yyvsp[(6) - (10)].str),mm_strdup("to"),(yyvsp[(8) - (10)].str),mm_strdup("from"),(yyvsp[(10) - (10)].str)); +;} + break; + + case 1218: + +/* Line 1455 of yacc.c */ +#line 7616 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("cluster"),(yyvsp[(2) - (4)].str),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1219: + +/* Line 1455 of yacc.c */ +#line 7620 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("cluster"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1220: + +/* Line 1455 of yacc.c */ +#line 7624 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("cluster"),(yyvsp[(2) - (5)].str),(yyvsp[(3) - (5)].str),mm_strdup("on"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1221: + +/* Line 1455 of yacc.c */ +#line 7632 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("using"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1222: + +/* Line 1455 of yacc.c */ +#line 7636 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1223: + +/* Line 1455 of yacc.c */ +#line 7643 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("vacuum"),(yyvsp[(2) - (4)].str),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1224: + +/* Line 1455 of yacc.c */ +#line 7647 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("vacuum"),(yyvsp[(2) - (5)].str),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1225: + +/* Line 1455 of yacc.c */ +#line 7651 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("vacuum"),(yyvsp[(2) - (5)].str),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1226: + +/* Line 1455 of yacc.c */ +#line 7655 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("vacuum ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 1227: + +/* Line 1455 of yacc.c */ +#line 7659 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("vacuum ("),(yyvsp[(3) - (6)].str),mm_strdup(")"),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1228: + +/* Line 1455 of yacc.c */ +#line 7667 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1229: + +/* Line 1455 of yacc.c */ +#line 7671 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1230: + +/* Line 1455 of yacc.c */ +#line 7679 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1231: + +/* Line 1455 of yacc.c */ +#line 7683 "preproc.y" + { + (yyval.str) = mm_strdup("verbose"); +;} + break; + + case 1232: + +/* Line 1455 of yacc.c */ +#line 7687 "preproc.y" + { + (yyval.str) = mm_strdup("freeze"); +;} + break; + + case 1233: + +/* Line 1455 of yacc.c */ +#line 7691 "preproc.y" + { + (yyval.str) = mm_strdup("full"); +;} + break; + + case 1234: + +/* Line 1455 of yacc.c */ +#line 7699 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1235: + +/* Line 1455 of yacc.c */ +#line 7703 "preproc.y" + { + (yyval.str) = cat_str(4,(yyvsp[(1) - (4)].str),(yyvsp[(2) - (4)].str),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1236: + +/* Line 1455 of yacc.c */ +#line 7711 "preproc.y" + { + (yyval.str) = mm_strdup("analyze"); +;} + break; + + case 1237: + +/* Line 1455 of yacc.c */ +#line 7715 "preproc.y" + { + (yyval.str) = mm_strdup("analyse"); +;} + break; + + case 1238: + +/* Line 1455 of yacc.c */ +#line 7723 "preproc.y" + { + (yyval.str) = mm_strdup("verbose"); +;} + break; + + case 1239: + +/* Line 1455 of yacc.c */ +#line 7727 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1240: + +/* Line 1455 of yacc.c */ +#line 7734 "preproc.y" + { + (yyval.str) = mm_strdup("full"); +;} + break; + + case 1241: + +/* Line 1455 of yacc.c */ +#line 7738 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1242: + +/* Line 1455 of yacc.c */ +#line 7745 "preproc.y" + { + (yyval.str) = mm_strdup("freeze"); +;} + break; + + case 1243: + +/* Line 1455 of yacc.c */ +#line 7749 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1244: + +/* Line 1455 of yacc.c */ +#line 7756 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (3)].str),mm_strdup(")")); +;} + break; + + case 1245: + +/* Line 1455 of yacc.c */ +#line 7760 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1246: + +/* Line 1455 of yacc.c */ +#line 7767 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("explain"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1247: + +/* Line 1455 of yacc.c */ +#line 7771 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("explain"),(yyvsp[(2) - (4)].str),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1248: + +/* Line 1455 of yacc.c */ +#line 7775 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("explain verbose"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1249: + +/* Line 1455 of yacc.c */ +#line 7779 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("explain ("),(yyvsp[(3) - (5)].str),mm_strdup(")"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1250: + +/* Line 1455 of yacc.c */ +#line 7787 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1251: + +/* Line 1455 of yacc.c */ +#line 7791 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1252: + +/* Line 1455 of yacc.c */ +#line 7795 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1253: + +/* Line 1455 of yacc.c */ +#line 7799 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1254: + +/* Line 1455 of yacc.c */ +#line 7803 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1255: + +/* Line 1455 of yacc.c */ +#line 7807 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1256: + +/* Line 1455 of yacc.c */ +#line 7811 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1257: + +/* Line 1455 of yacc.c */ +#line 7819 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1258: + +/* Line 1455 of yacc.c */ +#line 7823 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1259: + +/* Line 1455 of yacc.c */ +#line 7831 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1260: + +/* Line 1455 of yacc.c */ +#line 7839 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1261: + +/* Line 1455 of yacc.c */ +#line 7843 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1262: + +/* Line 1455 of yacc.c */ +#line 7847 "preproc.y" + { + (yyval.str) = mm_strdup("verbose"); +;} + break; + + case 1263: + +/* Line 1455 of yacc.c */ +#line 7855 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1264: + +/* Line 1455 of yacc.c */ +#line 7859 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1265: + +/* Line 1455 of yacc.c */ +#line 7863 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1266: + +/* Line 1455 of yacc.c */ +#line 7870 "preproc.y" + { + (yyval.prep).name = (yyvsp[(2) - (5)].str); + (yyval.prep).type = (yyvsp[(3) - (5)].str); + (yyval.prep).stmt = cat_str(3, mm_strdup("\""), (yyvsp[(5) - (5)].str), mm_strdup("\"")); + ;} + break; + + case 1267: + +/* Line 1455 of yacc.c */ +#line 7876 "preproc.y" + { + (yyval.prep).name = (yyvsp[(2) - (4)].str); + (yyval.prep).type = NULL; + (yyval.prep).stmt = (yyvsp[(4) - (4)].str); + ;} + break; + + case 1268: + +/* Line 1455 of yacc.c */ +#line 7886 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (3)].str),mm_strdup(")")); +;} + break; + + case 1269: + +/* Line 1455 of yacc.c */ +#line 7890 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1270: + +/* Line 1455 of yacc.c */ +#line 7897 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1271: + +/* Line 1455 of yacc.c */ +#line 7901 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1272: + +/* Line 1455 of yacc.c */ +#line 7905 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1273: + +/* Line 1455 of yacc.c */ +#line 7909 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1274: + +/* Line 1455 of yacc.c */ +#line 7917 "preproc.y" + { (yyval.str) = (yyvsp[(2) - (4)].str); ;} + break; + + case 1275: + +/* Line 1455 of yacc.c */ +#line 7919 "preproc.y" + { + (yyval.str) = cat_str(8,mm_strdup("create"),(yyvsp[(2) - (9)].str),mm_strdup("table"),(yyvsp[(4) - (9)].str),mm_strdup("as execute"),(yyvsp[(7) - (9)].str),(yyvsp[(8) - (9)].str),(yyvsp[(9) - (9)].str)); +;} + break; + + case 1276: + +/* Line 1455 of yacc.c */ +#line 7927 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (3)].str),mm_strdup(")")); +;} + break; + + case 1277: + +/* Line 1455 of yacc.c */ +#line 7931 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1278: + +/* Line 1455 of yacc.c */ +#line 7938 "preproc.y" + { + (yyval.str) = cat_str(5,(yyvsp[(1) - (6)].str),mm_strdup("insert into"),(yyvsp[(4) - (6)].str),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1279: + +/* Line 1455 of yacc.c */ +#line 7946 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1280: + +/* Line 1455 of yacc.c */ +#line 7950 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("("),(yyvsp[(2) - (4)].str),mm_strdup(")"),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1281: + +/* Line 1455 of yacc.c */ +#line 7954 "preproc.y" + { + (yyval.str) = mm_strdup("default values"); +;} + break; + + case 1282: + +/* Line 1455 of yacc.c */ +#line 7962 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1283: + +/* Line 1455 of yacc.c */ +#line 7966 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1284: + +/* Line 1455 of yacc.c */ +#line 7974 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1285: + +/* Line 1455 of yacc.c */ +#line 7982 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("returning"),(yyvsp[(2) - (3)].str)); +;} + break; + + case 1286: + +/* Line 1455 of yacc.c */ +#line 7986 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1287: + +/* Line 1455 of yacc.c */ +#line 7993 "preproc.y" + { + (yyval.str) = cat_str(6,(yyvsp[(1) - (7)].str),mm_strdup("delete from"),(yyvsp[(4) - (7)].str),(yyvsp[(5) - (7)].str),(yyvsp[(6) - (7)].str),(yyvsp[(7) - (7)].str)); +;} + break; + + case 1288: + +/* Line 1455 of yacc.c */ +#line 8001 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("using"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1289: + +/* Line 1455 of yacc.c */ +#line 8005 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1290: + +/* Line 1455 of yacc.c */ +#line 8012 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("lock"),(yyvsp[(2) - (5)].str),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1291: + +/* Line 1455 of yacc.c */ +#line 8020 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("in"),(yyvsp[(2) - (3)].str),mm_strdup("mode")); +;} + break; + + case 1292: + +/* Line 1455 of yacc.c */ +#line 8024 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1293: + +/* Line 1455 of yacc.c */ +#line 8031 "preproc.y" + { + (yyval.str) = mm_strdup("access share"); +;} + break; + + case 1294: + +/* Line 1455 of yacc.c */ +#line 8035 "preproc.y" + { + (yyval.str) = mm_strdup("row share"); +;} + break; + + case 1295: + +/* Line 1455 of yacc.c */ +#line 8039 "preproc.y" + { + (yyval.str) = mm_strdup("row exclusive"); +;} + break; + + case 1296: + +/* Line 1455 of yacc.c */ +#line 8043 "preproc.y" + { + (yyval.str) = mm_strdup("share update exclusive"); +;} + break; + + case 1297: + +/* Line 1455 of yacc.c */ +#line 8047 "preproc.y" + { + (yyval.str) = mm_strdup("share"); +;} + break; + + case 1298: + +/* Line 1455 of yacc.c */ +#line 8051 "preproc.y" + { + (yyval.str) = mm_strdup("share row exclusive"); +;} + break; + + case 1299: + +/* Line 1455 of yacc.c */ +#line 8055 "preproc.y" + { + (yyval.str) = mm_strdup("exclusive"); +;} + break; + + case 1300: + +/* Line 1455 of yacc.c */ +#line 8059 "preproc.y" + { + (yyval.str) = mm_strdup("access exclusive"); +;} + break; + + case 1301: + +/* Line 1455 of yacc.c */ +#line 8067 "preproc.y" + { + (yyval.str) = mm_strdup("nowait"); +;} + break; + + case 1302: + +/* Line 1455 of yacc.c */ +#line 8071 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1303: + +/* Line 1455 of yacc.c */ +#line 8078 "preproc.y" + { + (yyval.str) = cat_str(8,(yyvsp[(1) - (8)].str),mm_strdup("update"),(yyvsp[(3) - (8)].str),mm_strdup("set"),(yyvsp[(5) - (8)].str),(yyvsp[(6) - (8)].str),(yyvsp[(7) - (8)].str),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1304: + +/* Line 1455 of yacc.c */ +#line 8086 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1305: + +/* Line 1455 of yacc.c */ +#line 8090 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1306: + +/* Line 1455 of yacc.c */ +#line 8098 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1307: + +/* Line 1455 of yacc.c */ +#line 8102 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1308: + +/* Line 1455 of yacc.c */ +#line 8110 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("="),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1309: + +/* Line 1455 of yacc.c */ +#line 8118 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("("),(yyvsp[(2) - (5)].str),mm_strdup(") ="),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1310: + +/* Line 1455 of yacc.c */ +#line 8126 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1311: + +/* Line 1455 of yacc.c */ +#line 8134 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1312: + +/* Line 1455 of yacc.c */ +#line 8138 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1313: + +/* Line 1455 of yacc.c */ +#line 8146 "preproc.y" + { + struct cursor *ptr, *this; + char *cursor_marker = (yyvsp[(2) - (7)].str)[0] == ':' ? mm_strdup("$0") : mm_strdup((yyvsp[(2) - (7)].str)); + char *comment, *c1, *c2; + int (* strcmp_fn)(const char *, const char *) = ((yyvsp[(2) - (7)].str)[0] == ':' ? strcmp : pg_strcasecmp); + + for (ptr = cur; ptr != NULL; ptr = ptr->next) + { + if (strcmp_fn((yyvsp[(2) - (7)].str), ptr->name) == 0) + { + if ((yyvsp[(2) - (7)].str)[0] == ':') + mmerror(PARSE_ERROR, ET_ERROR, "using variable \"%s\" in different declare statements is not supported", (yyvsp[(2) - (7)].str)+1); + else + mmerror(PARSE_ERROR, ET_ERROR, "cursor \"%s\" is already defined", (yyvsp[(2) - (7)].str)); + } + } + + this = (struct cursor *) mm_alloc(sizeof(struct cursor)); + + this->next = cur; + this->name = (yyvsp[(2) - (7)].str); + this->function = (current_function ? mm_strdup(current_function) : NULL); + this->connection = connection; + this->opened = false; + this->command = cat_str(7, mm_strdup("declare"), cursor_marker, (yyvsp[(3) - (7)].str), mm_strdup("cursor"), (yyvsp[(5) - (7)].str), mm_strdup("for"), (yyvsp[(7) - (7)].str)); + this->argsinsert = argsinsert; + this->argsinsert_oos = NULL; + this->argsresult = argsresult; + this->argsresult_oos = NULL; + argsinsert = argsresult = NULL; + cur = this; + + c1 = mm_strdup(this->command); + if ((c2 = strstr(c1, "*/")) != NULL) + { + /* We put this text into a comment, so we better remove [*][/]. */ + c2[0] = '.'; + c2[1] = '.'; + } + comment = cat_str(3, mm_strdup("/*"), c1, mm_strdup("*/")); + + if ((braces_open > 0) && INFORMIX_MODE) /* we're in a function */ + (yyval.str) = cat_str(3, adjust_outofscope_cursor_vars(this), + mm_strdup("ECPG_informix_reset_sqlca();"), + comment); + else + (yyval.str) = cat2_str(adjust_outofscope_cursor_vars(this), comment); + ;} + break; + + case 1314: + +/* Line 1455 of yacc.c */ +#line 8199 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1315: + +/* Line 1455 of yacc.c */ +#line 8203 "preproc.y" + { + char *curname = mm_alloc(strlen((yyvsp[(1) - (1)].str)) + 2); + sprintf(curname, ":%s", (yyvsp[(1) - (1)].str)); + free((yyvsp[(1) - (1)].str)); + (yyvsp[(1) - (1)].str) = curname; + (yyval.str) = (yyvsp[(1) - (1)].str); + ;} + break; + + case 1316: + +/* Line 1455 of yacc.c */ +#line 8215 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1317: + +/* Line 1455 of yacc.c */ +#line 8218 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (3)].str),mm_strdup("no scroll")); +;} + break; + + case 1318: + +/* Line 1455 of yacc.c */ +#line 8222 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),mm_strdup("scroll")); +;} + break; + + case 1319: + +/* Line 1455 of yacc.c */ +#line 8226 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),mm_strdup("binary")); +;} + break; + + case 1320: + +/* Line 1455 of yacc.c */ +#line 8230 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),mm_strdup("insensitive")); +;} + break; + + case 1321: + +/* Line 1455 of yacc.c */ +#line 8238 "preproc.y" + { + if (compat == ECPG_COMPAT_INFORMIX_SE && autocommit) + (yyval.str) = mm_strdup("with hold"); + else + (yyval.str) = EMPTY; + ;} + break; + + case 1322: + +/* Line 1455 of yacc.c */ +#line 8245 "preproc.y" + { + (yyval.str) = mm_strdup("with hold"); +;} + break; + + case 1323: + +/* Line 1455 of yacc.c */ +#line 8249 "preproc.y" + { + (yyval.str) = mm_strdup("without hold"); +;} + break; + + case 1324: + +/* Line 1455 of yacc.c */ +#line 8257 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1325: + +/* Line 1455 of yacc.c */ +#line 8261 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1326: + +/* Line 1455 of yacc.c */ +#line 8269 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (3)].str),mm_strdup(")")); +;} + break; + + case 1327: + +/* Line 1455 of yacc.c */ +#line 8273 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (3)].str),mm_strdup(")")); +;} + break; + + case 1328: + +/* Line 1455 of yacc.c */ +#line 8281 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1329: + +/* Line 1455 of yacc.c */ +#line 8285 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1330: + +/* Line 1455 of yacc.c */ +#line 8289 "preproc.y" + { + (yyval.str) = cat_str(4,(yyvsp[(1) - (4)].str),(yyvsp[(2) - (4)].str),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1331: + +/* Line 1455 of yacc.c */ +#line 8293 "preproc.y" + { + (yyval.str) = cat_str(4,(yyvsp[(1) - (4)].str),(yyvsp[(2) - (4)].str),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1332: + +/* Line 1455 of yacc.c */ +#line 8297 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1333: + +/* Line 1455 of yacc.c */ +#line 8301 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1334: + +/* Line 1455 of yacc.c */ +#line 8305 "preproc.y" + { + (yyval.str) = cat_str(5,(yyvsp[(1) - (5)].str),(yyvsp[(2) - (5)].str),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1335: + +/* Line 1455 of yacc.c */ +#line 8309 "preproc.y" + { + (yyval.str) = cat_str(5,(yyvsp[(1) - (5)].str),(yyvsp[(2) - (5)].str),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1336: + +/* Line 1455 of yacc.c */ +#line 8317 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1337: + +/* Line 1455 of yacc.c */ +#line 8321 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1338: + +/* Line 1455 of yacc.c */ +#line 8329 "preproc.y" + { + (yyval.str) = cat_str(9,mm_strdup("select"),(yyvsp[(2) - (9)].str),(yyvsp[(3) - (9)].str),(yyvsp[(4) - (9)].str),(yyvsp[(5) - (9)].str),(yyvsp[(6) - (9)].str),(yyvsp[(7) - (9)].str),(yyvsp[(8) - (9)].str),(yyvsp[(9) - (9)].str)); +;} + break; + + case 1339: + +/* Line 1455 of yacc.c */ +#line 8333 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1340: + +/* Line 1455 of yacc.c */ +#line 8337 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("table"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1341: + +/* Line 1455 of yacc.c */ +#line 8341 "preproc.y" + { + (yyval.str) = cat_str(4,(yyvsp[(1) - (4)].str),mm_strdup("union"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1342: + +/* Line 1455 of yacc.c */ +#line 8345 "preproc.y" + { + (yyval.str) = cat_str(4,(yyvsp[(1) - (4)].str),mm_strdup("intersect"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1343: + +/* Line 1455 of yacc.c */ +#line 8349 "preproc.y" + { + (yyval.str) = cat_str(4,(yyvsp[(1) - (4)].str),mm_strdup("except"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1344: + +/* Line 1455 of yacc.c */ +#line 8357 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("with"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1345: + +/* Line 1455 of yacc.c */ +#line 8361 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("with recursive"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1346: + +/* Line 1455 of yacc.c */ +#line 8369 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1347: + +/* Line 1455 of yacc.c */ +#line 8373 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1348: + +/* Line 1455 of yacc.c */ +#line 8381 "preproc.y" + { + (yyval.str) = cat_str(5,(yyvsp[(1) - (6)].str),(yyvsp[(2) - (6)].str),mm_strdup("as ("),(yyvsp[(5) - (6)].str),mm_strdup(")")); +;} + break; + + case 1349: + +/* Line 1455 of yacc.c */ +#line 8389 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1350: + +/* Line 1455 of yacc.c */ +#line 8393 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1351: + +/* Line 1455 of yacc.c */ +#line 8400 "preproc.y" + { + FoundInto = 1; + (yyval.str)= cat2_str(mm_strdup("into"), (yyvsp[(2) - (2)].str)); + ;} + break; + + case 1352: + +/* Line 1455 of yacc.c */ +#line 8404 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 1353: + +/* Line 1455 of yacc.c */ +#line 8406 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1354: + +/* Line 1455 of yacc.c */ +#line 8413 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("temporary"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1355: + +/* Line 1455 of yacc.c */ +#line 8417 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("temp"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1356: + +/* Line 1455 of yacc.c */ +#line 8421 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("local temporary"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1357: + +/* Line 1455 of yacc.c */ +#line 8425 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("local temp"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1358: + +/* Line 1455 of yacc.c */ +#line 8429 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("global temporary"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1359: + +/* Line 1455 of yacc.c */ +#line 8433 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("global temp"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1360: + +/* Line 1455 of yacc.c */ +#line 8437 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("unlogged"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1361: + +/* Line 1455 of yacc.c */ +#line 8441 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("table"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1362: + +/* Line 1455 of yacc.c */ +#line 8445 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1363: + +/* Line 1455 of yacc.c */ +#line 8453 "preproc.y" + { + (yyval.str) = mm_strdup("table"); +;} + break; + + case 1364: + +/* Line 1455 of yacc.c */ +#line 8457 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1365: + +/* Line 1455 of yacc.c */ +#line 8464 "preproc.y" + { + (yyval.str) = mm_strdup("all"); +;} + break; + + case 1366: + +/* Line 1455 of yacc.c */ +#line 8468 "preproc.y" + { + (yyval.str) = mm_strdup("distinct"); +;} + break; + + case 1367: + +/* Line 1455 of yacc.c */ +#line 8472 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1368: + +/* Line 1455 of yacc.c */ +#line 8479 "preproc.y" + { + (yyval.str) = mm_strdup("distinct"); +;} + break; + + case 1369: + +/* Line 1455 of yacc.c */ +#line 8483 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("distinct on ("),(yyvsp[(4) - (5)].str),mm_strdup(")")); +;} + break; + + case 1370: + +/* Line 1455 of yacc.c */ +#line 8487 "preproc.y" + { + (yyval.str) = mm_strdup("all"); +;} + break; + + case 1371: + +/* Line 1455 of yacc.c */ +#line 8491 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1372: + +/* Line 1455 of yacc.c */ +#line 8498 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1373: + +/* Line 1455 of yacc.c */ +#line 8502 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1374: + +/* Line 1455 of yacc.c */ +#line 8509 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("order by"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1375: + +/* Line 1455 of yacc.c */ +#line 8517 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1376: + +/* Line 1455 of yacc.c */ +#line 8521 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1377: + +/* Line 1455 of yacc.c */ +#line 8529 "preproc.y" + { + (yyval.str) = cat_str(4,(yyvsp[(1) - (4)].str),mm_strdup("using"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1378: + +/* Line 1455 of yacc.c */ +#line 8533 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1379: + +/* Line 1455 of yacc.c */ +#line 8541 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1380: + +/* Line 1455 of yacc.c */ +#line 8545 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1381: + +/* Line 1455 of yacc.c */ +#line 8549 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1382: + +/* Line 1455 of yacc.c */ +#line 8553 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1383: + +/* Line 1455 of yacc.c */ +#line 8561 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1384: + +/* Line 1455 of yacc.c */ +#line 8565 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1385: + +/* Line 1455 of yacc.c */ +#line 8572 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("limit"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1386: + +/* Line 1455 of yacc.c */ +#line 8576 "preproc.y" + { + mmerror(PARSE_ERROR, ET_WARNING, "no longer supported LIMIT #,# syntax passed to server"); + (yyval.str) = cat_str(4, mm_strdup("limit"), (yyvsp[(2) - (4)].str), mm_strdup(","), (yyvsp[(4) - (4)].str)); + ;} + break; + + case 1387: + +/* Line 1455 of yacc.c */ +#line 8581 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("fetch"),(yyvsp[(2) - (5)].str),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),mm_strdup("only")); +;} + break; + + case 1388: + +/* Line 1455 of yacc.c */ +#line 8589 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("offset"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1389: + +/* Line 1455 of yacc.c */ +#line 8593 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("offset"),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1390: + +/* Line 1455 of yacc.c */ +#line 8601 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1391: + +/* Line 1455 of yacc.c */ +#line 8605 "preproc.y" + { + (yyval.str) = mm_strdup("all"); +;} + break; + + case 1392: + +/* Line 1455 of yacc.c */ +#line 8613 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1393: + +/* Line 1455 of yacc.c */ +#line 8621 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1394: + +/* Line 1455 of yacc.c */ +#line 8625 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (3)].str),mm_strdup(")")); +;} + break; + + case 1395: + +/* Line 1455 of yacc.c */ +#line 8629 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1396: + +/* Line 1455 of yacc.c */ +#line 8636 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1397: + +/* Line 1455 of yacc.c */ +#line 8644 "preproc.y" + { + (yyval.str) = mm_strdup("row"); +;} + break; + + case 1398: + +/* Line 1455 of yacc.c */ +#line 8648 "preproc.y" + { + (yyval.str) = mm_strdup("rows"); +;} + break; + + case 1399: + +/* Line 1455 of yacc.c */ +#line 8656 "preproc.y" + { + (yyval.str) = mm_strdup("first"); +;} + break; + + case 1400: + +/* Line 1455 of yacc.c */ +#line 8660 "preproc.y" + { + (yyval.str) = mm_strdup("next"); +;} + break; + + case 1401: + +/* Line 1455 of yacc.c */ +#line 8668 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("group by"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1402: + +/* Line 1455 of yacc.c */ +#line 8672 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1403: + +/* Line 1455 of yacc.c */ +#line 8679 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("having"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1404: + +/* Line 1455 of yacc.c */ +#line 8683 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1405: + +/* Line 1455 of yacc.c */ +#line 8690 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1406: + +/* Line 1455 of yacc.c */ +#line 8694 "preproc.y" + { + (yyval.str) = mm_strdup("for read only"); +;} + break; + + case 1407: + +/* Line 1455 of yacc.c */ +#line 8702 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1408: + +/* Line 1455 of yacc.c */ +#line 8706 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1409: + +/* Line 1455 of yacc.c */ +#line 8713 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1410: + +/* Line 1455 of yacc.c */ +#line 8717 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1411: + +/* Line 1455 of yacc.c */ +#line 8725 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("for update"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1412: + +/* Line 1455 of yacc.c */ +#line 8729 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("for share"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1413: + +/* Line 1455 of yacc.c */ +#line 8737 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("of"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1414: + +/* Line 1455 of yacc.c */ +#line 8741 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1415: + +/* Line 1455 of yacc.c */ +#line 8748 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("values"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1416: + +/* Line 1455 of yacc.c */ +#line 8752 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1417: + +/* Line 1455 of yacc.c */ +#line 8760 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("from"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1418: + +/* Line 1455 of yacc.c */ +#line 8764 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1419: + +/* Line 1455 of yacc.c */ +#line 8771 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1420: + +/* Line 1455 of yacc.c */ +#line 8775 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1421: + +/* Line 1455 of yacc.c */ +#line 8783 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1422: + +/* Line 1455 of yacc.c */ +#line 8787 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1423: + +/* Line 1455 of yacc.c */ +#line 8791 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1424: + +/* Line 1455 of yacc.c */ +#line 8795 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1425: + +/* Line 1455 of yacc.c */ +#line 8799 "preproc.y" + { + (yyval.str) = cat_str(4,(yyvsp[(1) - (5)].str),mm_strdup("as ("),(yyvsp[(4) - (5)].str),mm_strdup(")")); +;} + break; + + case 1426: + +/* Line 1455 of yacc.c */ +#line 8803 "preproc.y" + { + (yyval.str) = cat_str(6,(yyvsp[(1) - (6)].str),mm_strdup("as"),(yyvsp[(3) - (6)].str),mm_strdup("("),(yyvsp[(5) - (6)].str),mm_strdup(")")); +;} + break; + + case 1427: + +/* Line 1455 of yacc.c */ +#line 8807 "preproc.y" + { + (yyval.str) = cat_str(5,(yyvsp[(1) - (5)].str),(yyvsp[(2) - (5)].str),mm_strdup("("),(yyvsp[(4) - (5)].str),mm_strdup(")")); +;} + break; + + case 1428: + +/* Line 1455 of yacc.c */ +#line 8811 "preproc.y" + { + mmerror(PARSE_ERROR, ET_ERROR, "subquery in FROM must have an alias"); + + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1429: + +/* Line 1455 of yacc.c */ +#line 8817 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1430: + +/* Line 1455 of yacc.c */ +#line 8821 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1431: + +/* Line 1455 of yacc.c */ +#line 8825 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("("),(yyvsp[(2) - (4)].str),mm_strdup(")"),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1432: + +/* Line 1455 of yacc.c */ +#line 8833 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (3)].str),mm_strdup(")")); +;} + break; + + case 1433: + +/* Line 1455 of yacc.c */ +#line 8837 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (4)].str),mm_strdup("cross join"),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1434: + +/* Line 1455 of yacc.c */ +#line 8841 "preproc.y" + { + (yyval.str) = cat_str(5,(yyvsp[(1) - (5)].str),(yyvsp[(2) - (5)].str),mm_strdup("join"),(yyvsp[(4) - (5)].str),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1435: + +/* Line 1455 of yacc.c */ +#line 8845 "preproc.y" + { + (yyval.str) = cat_str(4,(yyvsp[(1) - (4)].str),mm_strdup("join"),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1436: + +/* Line 1455 of yacc.c */ +#line 8849 "preproc.y" + { + (yyval.str) = cat_str(5,(yyvsp[(1) - (5)].str),mm_strdup("natural"),(yyvsp[(3) - (5)].str),mm_strdup("join"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1437: + +/* Line 1455 of yacc.c */ +#line 8853 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (4)].str),mm_strdup("natural join"),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1438: + +/* Line 1455 of yacc.c */ +#line 8861 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("as"),(yyvsp[(2) - (5)].str),mm_strdup("("),(yyvsp[(4) - (5)].str),mm_strdup(")")); +;} + break; + + case 1439: + +/* Line 1455 of yacc.c */ +#line 8865 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("as"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1440: + +/* Line 1455 of yacc.c */ +#line 8869 "preproc.y" + { + (yyval.str) = cat_str(4,(yyvsp[(1) - (4)].str),mm_strdup("("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 1441: + +/* Line 1455 of yacc.c */ +#line 8873 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1442: + +/* Line 1455 of yacc.c */ +#line 8881 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("full"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1443: + +/* Line 1455 of yacc.c */ +#line 8885 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("left"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1444: + +/* Line 1455 of yacc.c */ +#line 8889 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("right"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1445: + +/* Line 1455 of yacc.c */ +#line 8893 "preproc.y" + { + (yyval.str) = mm_strdup("inner"); +;} + break; + + case 1446: + +/* Line 1455 of yacc.c */ +#line 8901 "preproc.y" + { + (yyval.str) = mm_strdup("outer"); +;} + break; + + case 1447: + +/* Line 1455 of yacc.c */ +#line 8905 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1448: + +/* Line 1455 of yacc.c */ +#line 8912 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("using ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 1449: + +/* Line 1455 of yacc.c */ +#line 8916 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("on"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1450: + +/* Line 1455 of yacc.c */ +#line 8924 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1451: + +/* Line 1455 of yacc.c */ +#line 8928 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),mm_strdup("*")); +;} + break; + + case 1452: + +/* Line 1455 of yacc.c */ +#line 8932 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("only"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1453: + +/* Line 1455 of yacc.c */ +#line 8936 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("only ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 1454: + +/* Line 1455 of yacc.c */ +#line 8944 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1455: + +/* Line 1455 of yacc.c */ +#line 8948 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1456: + +/* Line 1455 of yacc.c */ +#line 8956 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1457: + +/* Line 1455 of yacc.c */ +#line 8960 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1458: + +/* Line 1455 of yacc.c */ +#line 8964 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("as"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1459: + +/* Line 1455 of yacc.c */ +#line 8972 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1460: + +/* Line 1455 of yacc.c */ +#line 8980 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("where"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1461: + +/* Line 1455 of yacc.c */ +#line 8984 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1462: + +/* Line 1455 of yacc.c */ +#line 8991 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("where"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1463: + +/* Line 1455 of yacc.c */ +#line 8995 "preproc.y" + { + char *cursor_marker = (yyvsp[(4) - (4)].str)[0] == ':' ? mm_strdup("$0") : (yyvsp[(4) - (4)].str); + (yyval.str) = cat_str(2,mm_strdup("where current of"), cursor_marker); + ;} + break; + + case 1464: + +/* Line 1455 of yacc.c */ +#line 9000 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1465: + +/* Line 1455 of yacc.c */ +#line 9007 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1466: + +/* Line 1455 of yacc.c */ +#line 9011 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1467: + +/* Line 1455 of yacc.c */ +#line 9018 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1468: + +/* Line 1455 of yacc.c */ +#line 9022 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1469: + +/* Line 1455 of yacc.c */ +#line 9030 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1470: + +/* Line 1455 of yacc.c */ +#line 9038 "preproc.y" + { (yyval.str) = cat2_str((yyvsp[(1) - (2)].str), (yyvsp[(2) - (2)].index).str); ;} + break; + + case 1471: + +/* Line 1455 of yacc.c */ +#line 9040 "preproc.y" + { (yyval.str) = cat_str(3, mm_strdup("setof"), (yyvsp[(2) - (3)].str), (yyvsp[(3) - (3)].index).str); ;} + break; + + case 1472: + +/* Line 1455 of yacc.c */ +#line 9042 "preproc.y" + { + (yyval.str) = cat_str(4,(yyvsp[(1) - (5)].str),mm_strdup("array ["),(yyvsp[(4) - (5)].str),mm_strdup("]")); +;} + break; + + case 1473: + +/* Line 1455 of yacc.c */ +#line 9046 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("setof"),(yyvsp[(2) - (6)].str),mm_strdup("array ["),(yyvsp[(5) - (6)].str),mm_strdup("]")); +;} + break; + + case 1474: + +/* Line 1455 of yacc.c */ +#line 9050 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),mm_strdup("array")); +;} + break; + + case 1475: + +/* Line 1455 of yacc.c */ +#line 9054 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("setof"),(yyvsp[(2) - (3)].str),mm_strdup("array")); +;} + break; + + case 1476: + +/* Line 1455 of yacc.c */ +#line 9062 "preproc.y" + { + (yyval.index).index1 = (yyvsp[(1) - (3)].index).index1; + (yyval.index).index2 = (yyvsp[(1) - (3)].index).index2; + if (strcmp((yyval.index).index1, "-1") == 0) + (yyval.index).index1 = mm_strdup("0"); + else if (strcmp((yyvsp[(1) - (3)].index).index2, "-1") == 0) + (yyval.index).index2 = mm_strdup("0"); + (yyval.index).str = cat_str(2, (yyvsp[(1) - (3)].index).str, mm_strdup("[]")); + ;} + break; + + case 1477: + +/* Line 1455 of yacc.c */ +#line 9072 "preproc.y" + { + (yyval.index).index1 = (yyvsp[(1) - (4)].index).index1; + (yyval.index).index2 = (yyvsp[(1) - (4)].index).index2; + if (strcmp((yyvsp[(1) - (4)].index).index1, "-1") == 0) + (yyval.index).index1 = strdup((yyvsp[(3) - (4)].str)); + else if (strcmp((yyvsp[(1) - (4)].index).index2, "-1") == 0) + (yyval.index).index2 = strdup((yyvsp[(3) - (4)].str)); + (yyval.index).str = cat_str(4, (yyvsp[(1) - (4)].index).str, mm_strdup("["), (yyvsp[(3) - (4)].str), mm_strdup("]")); + ;} + break; + + case 1478: + +/* Line 1455 of yacc.c */ +#line 9082 "preproc.y" + { + (yyval.index).index1 = mm_strdup("-1"); + (yyval.index).index2 = mm_strdup("-1"); + (yyval.index).str= EMPTY; + ;} + break; + + case 1479: + +/* Line 1455 of yacc.c */ +#line 9092 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1480: + +/* Line 1455 of yacc.c */ +#line 9096 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1481: + +/* Line 1455 of yacc.c */ +#line 9100 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1482: + +/* Line 1455 of yacc.c */ +#line 9104 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1483: + +/* Line 1455 of yacc.c */ +#line 9108 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1484: + +/* Line 1455 of yacc.c */ +#line 9112 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1485: + +/* Line 1455 of yacc.c */ +#line 9116 "preproc.y" + { + (yyval.str) = cat_str(5,(yyvsp[(1) - (5)].str),mm_strdup("("),(yyvsp[(3) - (5)].str),mm_strdup(")"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1486: + +/* Line 1455 of yacc.c */ +#line 9124 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1487: + +/* Line 1455 of yacc.c */ +#line 9128 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1488: + +/* Line 1455 of yacc.c */ +#line 9132 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1489: + +/* Line 1455 of yacc.c */ +#line 9136 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1490: + +/* Line 1455 of yacc.c */ +#line 9144 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1491: + +/* Line 1455 of yacc.c */ +#line 9148 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1492: + +/* Line 1455 of yacc.c */ +#line 9156 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (3)].str),mm_strdup(")")); +;} + break; + + case 1493: + +/* Line 1455 of yacc.c */ +#line 9160 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1494: + +/* Line 1455 of yacc.c */ +#line 9167 "preproc.y" + { + (yyval.str) = mm_strdup("int"); +;} + break; + + case 1495: + +/* Line 1455 of yacc.c */ +#line 9171 "preproc.y" + { + (yyval.str) = mm_strdup("integer"); +;} + break; + + case 1496: + +/* Line 1455 of yacc.c */ +#line 9175 "preproc.y" + { + (yyval.str) = mm_strdup("smallint"); +;} + break; + + case 1497: + +/* Line 1455 of yacc.c */ +#line 9179 "preproc.y" + { + (yyval.str) = mm_strdup("bigint"); +;} + break; + + case 1498: + +/* Line 1455 of yacc.c */ +#line 9183 "preproc.y" + { + (yyval.str) = mm_strdup("real"); +;} + break; + + case 1499: + +/* Line 1455 of yacc.c */ +#line 9187 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("float"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1500: + +/* Line 1455 of yacc.c */ +#line 9191 "preproc.y" + { + (yyval.str) = mm_strdup("double precision"); +;} + break; + + case 1501: + +/* Line 1455 of yacc.c */ +#line 9195 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("decimal"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1502: + +/* Line 1455 of yacc.c */ +#line 9199 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("dec"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1503: + +/* Line 1455 of yacc.c */ +#line 9203 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("numeric"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1504: + +/* Line 1455 of yacc.c */ +#line 9207 "preproc.y" + { + (yyval.str) = mm_strdup("boolean"); +;} + break; + + case 1505: + +/* Line 1455 of yacc.c */ +#line 9215 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (3)].str),mm_strdup(")")); +;} + break; + + case 1506: + +/* Line 1455 of yacc.c */ +#line 9219 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1507: + +/* Line 1455 of yacc.c */ +#line 9226 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1508: + +/* Line 1455 of yacc.c */ +#line 9230 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1509: + +/* Line 1455 of yacc.c */ +#line 9238 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1510: + +/* Line 1455 of yacc.c */ +#line 9242 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1511: + +/* Line 1455 of yacc.c */ +#line 9250 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("bit"),(yyvsp[(2) - (5)].str),mm_strdup("("),(yyvsp[(4) - (5)].str),mm_strdup(")")); +;} + break; + + case 1512: + +/* Line 1455 of yacc.c */ +#line 9258 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("bit"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1513: + +/* Line 1455 of yacc.c */ +#line 9266 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1514: + +/* Line 1455 of yacc.c */ +#line 9270 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1515: + +/* Line 1455 of yacc.c */ +#line 9278 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1516: + +/* Line 1455 of yacc.c */ +#line 9282 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1517: + +/* Line 1455 of yacc.c */ +#line 9290 "preproc.y" + { + (yyval.str) = cat_str(5,(yyvsp[(1) - (5)].str),mm_strdup("("),(yyvsp[(3) - (5)].str),mm_strdup(")"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1518: + +/* Line 1455 of yacc.c */ +#line 9298 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1519: + +/* Line 1455 of yacc.c */ +#line 9306 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("character"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1520: + +/* Line 1455 of yacc.c */ +#line 9310 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("char"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1521: + +/* Line 1455 of yacc.c */ +#line 9314 "preproc.y" + { + (yyval.str) = mm_strdup("varchar"); +;} + break; + + case 1522: + +/* Line 1455 of yacc.c */ +#line 9318 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("national character"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1523: + +/* Line 1455 of yacc.c */ +#line 9322 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("national char"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1524: + +/* Line 1455 of yacc.c */ +#line 9326 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("nchar"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1525: + +/* Line 1455 of yacc.c */ +#line 9334 "preproc.y" + { + (yyval.str) = mm_strdup("varying"); +;} + break; + + case 1526: + +/* Line 1455 of yacc.c */ +#line 9338 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1527: + +/* Line 1455 of yacc.c */ +#line 9345 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("character set"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1528: + +/* Line 1455 of yacc.c */ +#line 9349 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1529: + +/* Line 1455 of yacc.c */ +#line 9356 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("timestamp ("),(yyvsp[(3) - (5)].str),mm_strdup(")"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1530: + +/* Line 1455 of yacc.c */ +#line 9360 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("timestamp"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1531: + +/* Line 1455 of yacc.c */ +#line 9364 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("time ("),(yyvsp[(3) - (5)].str),mm_strdup(")"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1532: + +/* Line 1455 of yacc.c */ +#line 9368 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("time"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1533: + +/* Line 1455 of yacc.c */ +#line 9376 "preproc.y" + { + (yyval.str) = mm_strdup("interval"); +;} + break; + + case 1534: + +/* Line 1455 of yacc.c */ +#line 9384 "preproc.y" + { + (yyval.str) = mm_strdup("with time zone"); +;} + break; + + case 1535: + +/* Line 1455 of yacc.c */ +#line 9388 "preproc.y" + { + (yyval.str) = mm_strdup("without time zone"); +;} + break; + + case 1536: + +/* Line 1455 of yacc.c */ +#line 9392 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1537: + +/* Line 1455 of yacc.c */ +#line 9399 "preproc.y" + { + (yyval.str) = mm_strdup("year"); +;} + break; + + case 1538: + +/* Line 1455 of yacc.c */ +#line 9403 "preproc.y" + { + (yyval.str) = mm_strdup("month"); +;} + break; + + case 1539: + +/* Line 1455 of yacc.c */ +#line 9407 "preproc.y" + { + (yyval.str) = mm_strdup("day"); +;} + break; + + case 1540: + +/* Line 1455 of yacc.c */ +#line 9411 "preproc.y" + { + (yyval.str) = mm_strdup("hour"); +;} + break; + + case 1541: + +/* Line 1455 of yacc.c */ +#line 9415 "preproc.y" + { + (yyval.str) = mm_strdup("minute"); +;} + break; + + case 1542: + +/* Line 1455 of yacc.c */ +#line 9419 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1543: + +/* Line 1455 of yacc.c */ +#line 9423 "preproc.y" + { + (yyval.str) = mm_strdup("year to month"); +;} + break; + + case 1544: + +/* Line 1455 of yacc.c */ +#line 9427 "preproc.y" + { + (yyval.str) = mm_strdup("day to hour"); +;} + break; + + case 1545: + +/* Line 1455 of yacc.c */ +#line 9431 "preproc.y" + { + (yyval.str) = mm_strdup("day to minute"); +;} + break; + + case 1546: + +/* Line 1455 of yacc.c */ +#line 9435 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("day to"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1547: + +/* Line 1455 of yacc.c */ +#line 9439 "preproc.y" + { + (yyval.str) = mm_strdup("hour to minute"); +;} + break; + + case 1548: + +/* Line 1455 of yacc.c */ +#line 9443 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("hour to"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1549: + +/* Line 1455 of yacc.c */ +#line 9447 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("minute to"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1550: + +/* Line 1455 of yacc.c */ +#line 9451 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1551: + +/* Line 1455 of yacc.c */ +#line 9458 "preproc.y" + { + (yyval.str) = mm_strdup("second"); +;} + break; + + case 1552: + +/* Line 1455 of yacc.c */ +#line 9462 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("second ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 1553: + +/* Line 1455 of yacc.c */ +#line 9470 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1554: + +/* Line 1455 of yacc.c */ +#line 9474 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("::"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1555: + +/* Line 1455 of yacc.c */ +#line 9478 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("collate"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1556: + +/* Line 1455 of yacc.c */ +#line 9482 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (5)].str),mm_strdup("at time zone"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1557: + +/* Line 1455 of yacc.c */ +#line 9486 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("+"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1558: + +/* Line 1455 of yacc.c */ +#line 9490 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("-"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1559: + +/* Line 1455 of yacc.c */ +#line 9494 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("+"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1560: + +/* Line 1455 of yacc.c */ +#line 9498 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("-"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1561: + +/* Line 1455 of yacc.c */ +#line 9502 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("*"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1562: + +/* Line 1455 of yacc.c */ +#line 9506 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("/"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1563: + +/* Line 1455 of yacc.c */ +#line 9510 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("%"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1564: + +/* Line 1455 of yacc.c */ +#line 9514 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("^"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1565: + +/* Line 1455 of yacc.c */ +#line 9518 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("<"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1566: + +/* Line 1455 of yacc.c */ +#line 9522 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(">"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1567: + +/* Line 1455 of yacc.c */ +#line 9526 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("="),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1568: + +/* Line 1455 of yacc.c */ +#line 9530 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1569: + +/* Line 1455 of yacc.c */ +#line 9534 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1570: + +/* Line 1455 of yacc.c */ +#line 9538 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1571: + +/* Line 1455 of yacc.c */ +#line 9542 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("and"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1572: + +/* Line 1455 of yacc.c */ +#line 9546 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("or"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1573: + +/* Line 1455 of yacc.c */ +#line 9550 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("not"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1574: + +/* Line 1455 of yacc.c */ +#line 9554 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("like"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1575: + +/* Line 1455 of yacc.c */ +#line 9558 "preproc.y" + { + (yyval.str) = cat_str(5,(yyvsp[(1) - (5)].str),mm_strdup("like"),(yyvsp[(3) - (5)].str),mm_strdup("escape"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1576: + +/* Line 1455 of yacc.c */ +#line 9562 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (4)].str),mm_strdup("not like"),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1577: + +/* Line 1455 of yacc.c */ +#line 9566 "preproc.y" + { + (yyval.str) = cat_str(5,(yyvsp[(1) - (6)].str),mm_strdup("not like"),(yyvsp[(4) - (6)].str),mm_strdup("escape"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1578: + +/* Line 1455 of yacc.c */ +#line 9570 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("ilike"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1579: + +/* Line 1455 of yacc.c */ +#line 9574 "preproc.y" + { + (yyval.str) = cat_str(5,(yyvsp[(1) - (5)].str),mm_strdup("ilike"),(yyvsp[(3) - (5)].str),mm_strdup("escape"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1580: + +/* Line 1455 of yacc.c */ +#line 9578 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (4)].str),mm_strdup("not ilike"),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1581: + +/* Line 1455 of yacc.c */ +#line 9582 "preproc.y" + { + (yyval.str) = cat_str(5,(yyvsp[(1) - (6)].str),mm_strdup("not ilike"),(yyvsp[(4) - (6)].str),mm_strdup("escape"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1582: + +/* Line 1455 of yacc.c */ +#line 9586 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (4)].str),mm_strdup("similar to"),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1583: + +/* Line 1455 of yacc.c */ +#line 9590 "preproc.y" + { + (yyval.str) = cat_str(5,(yyvsp[(1) - (6)].str),mm_strdup("similar to"),(yyvsp[(4) - (6)].str),mm_strdup("escape"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1584: + +/* Line 1455 of yacc.c */ +#line 9594 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (5)].str),mm_strdup("not similar to"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1585: + +/* Line 1455 of yacc.c */ +#line 9598 "preproc.y" + { + (yyval.str) = cat_str(5,(yyvsp[(1) - (7)].str),mm_strdup("not similar to"),(yyvsp[(5) - (7)].str),mm_strdup("escape"),(yyvsp[(7) - (7)].str)); +;} + break; + + case 1586: + +/* Line 1455 of yacc.c */ +#line 9602 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (3)].str),mm_strdup("is null")); +;} + break; + + case 1587: + +/* Line 1455 of yacc.c */ +#line 9606 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),mm_strdup("isnull")); +;} + break; + + case 1588: + +/* Line 1455 of yacc.c */ +#line 9610 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (4)].str),mm_strdup("is not null")); +;} + break; + + case 1589: + +/* Line 1455 of yacc.c */ +#line 9614 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),mm_strdup("notnull")); +;} + break; + + case 1590: + +/* Line 1455 of yacc.c */ +#line 9618 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("overlaps"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1591: + +/* Line 1455 of yacc.c */ +#line 9622 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (3)].str),mm_strdup("is true")); +;} + break; + + case 1592: + +/* Line 1455 of yacc.c */ +#line 9626 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (4)].str),mm_strdup("is not true")); +;} + break; + + case 1593: + +/* Line 1455 of yacc.c */ +#line 9630 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (3)].str),mm_strdup("is false")); +;} + break; + + case 1594: + +/* Line 1455 of yacc.c */ +#line 9634 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (4)].str),mm_strdup("is not false")); +;} + break; + + case 1595: + +/* Line 1455 of yacc.c */ +#line 9638 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (3)].str),mm_strdup("is unknown")); +;} + break; + + case 1596: + +/* Line 1455 of yacc.c */ +#line 9642 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (4)].str),mm_strdup("is not unknown")); +;} + break; + + case 1597: + +/* Line 1455 of yacc.c */ +#line 9646 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (5)].str),mm_strdup("is distinct from"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1598: + +/* Line 1455 of yacc.c */ +#line 9650 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (6)].str),mm_strdup("is not distinct from"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1599: + +/* Line 1455 of yacc.c */ +#line 9654 "preproc.y" + { + (yyval.str) = cat_str(4,(yyvsp[(1) - (6)].str),mm_strdup("is of ("),(yyvsp[(5) - (6)].str),mm_strdup(")")); +;} + break; + + case 1600: + +/* Line 1455 of yacc.c */ +#line 9658 "preproc.y" + { + (yyval.str) = cat_str(4,(yyvsp[(1) - (7)].str),mm_strdup("is not of ("),(yyvsp[(6) - (7)].str),mm_strdup(")")); +;} + break; + + case 1601: + +/* Line 1455 of yacc.c */ +#line 9662 "preproc.y" + { + (yyval.str) = cat_str(6,(yyvsp[(1) - (6)].str),mm_strdup("between"),(yyvsp[(3) - (6)].str),(yyvsp[(4) - (6)].str),mm_strdup("and"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1602: + +/* Line 1455 of yacc.c */ +#line 9666 "preproc.y" + { + (yyval.str) = cat_str(6,(yyvsp[(1) - (7)].str),mm_strdup("not between"),(yyvsp[(4) - (7)].str),(yyvsp[(5) - (7)].str),mm_strdup("and"),(yyvsp[(7) - (7)].str)); +;} + break; + + case 1603: + +/* Line 1455 of yacc.c */ +#line 9670 "preproc.y" + { + (yyval.str) = cat_str(5,(yyvsp[(1) - (6)].str),mm_strdup("between symmetric"),(yyvsp[(4) - (6)].str),mm_strdup("and"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1604: + +/* Line 1455 of yacc.c */ +#line 9674 "preproc.y" + { + (yyval.str) = cat_str(5,(yyvsp[(1) - (7)].str),mm_strdup("not between symmetric"),(yyvsp[(5) - (7)].str),mm_strdup("and"),(yyvsp[(7) - (7)].str)); +;} + break; + + case 1605: + +/* Line 1455 of yacc.c */ +#line 9678 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("in"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1606: + +/* Line 1455 of yacc.c */ +#line 9682 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (4)].str),mm_strdup("not in"),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1607: + +/* Line 1455 of yacc.c */ +#line 9686 "preproc.y" + { + (yyval.str) = cat_str(4,(yyvsp[(1) - (4)].str),(yyvsp[(2) - (4)].str),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1608: + +/* Line 1455 of yacc.c */ +#line 9690 "preproc.y" + { + (yyval.str) = cat_str(6,(yyvsp[(1) - (6)].str),(yyvsp[(2) - (6)].str),(yyvsp[(3) - (6)].str),mm_strdup("("),(yyvsp[(5) - (6)].str),mm_strdup(")")); +;} + break; + + case 1609: + +/* Line 1455 of yacc.c */ +#line 9694 "preproc.y" + { +mmerror(PARSE_ERROR, ET_WARNING, "unsupported feature will be passed to server"); + (yyval.str) = cat_str(2,mm_strdup("unique"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1610: + +/* Line 1455 of yacc.c */ +#line 9699 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (3)].str),mm_strdup("is document")); +;} + break; + + case 1611: + +/* Line 1455 of yacc.c */ +#line 9703 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (4)].str),mm_strdup("is not document")); +;} + break; + + case 1612: + +/* Line 1455 of yacc.c */ +#line 9711 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1613: + +/* Line 1455 of yacc.c */ +#line 9715 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("::"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1614: + +/* Line 1455 of yacc.c */ +#line 9719 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("+"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1615: + +/* Line 1455 of yacc.c */ +#line 9723 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("-"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1616: + +/* Line 1455 of yacc.c */ +#line 9727 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("+"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1617: + +/* Line 1455 of yacc.c */ +#line 9731 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("-"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1618: + +/* Line 1455 of yacc.c */ +#line 9735 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("*"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1619: + +/* Line 1455 of yacc.c */ +#line 9739 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("/"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1620: + +/* Line 1455 of yacc.c */ +#line 9743 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("%"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1621: + +/* Line 1455 of yacc.c */ +#line 9747 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("^"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1622: + +/* Line 1455 of yacc.c */ +#line 9751 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("<"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1623: + +/* Line 1455 of yacc.c */ +#line 9755 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(">"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1624: + +/* Line 1455 of yacc.c */ +#line 9759 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("="),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1625: + +/* Line 1455 of yacc.c */ +#line 9763 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1626: + +/* Line 1455 of yacc.c */ +#line 9767 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1627: + +/* Line 1455 of yacc.c */ +#line 9771 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1628: + +/* Line 1455 of yacc.c */ +#line 9775 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (5)].str),mm_strdup("is distinct from"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1629: + +/* Line 1455 of yacc.c */ +#line 9779 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (6)].str),mm_strdup("is not distinct from"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1630: + +/* Line 1455 of yacc.c */ +#line 9783 "preproc.y" + { + (yyval.str) = cat_str(4,(yyvsp[(1) - (6)].str),mm_strdup("is of ("),(yyvsp[(5) - (6)].str),mm_strdup(")")); +;} + break; + + case 1631: + +/* Line 1455 of yacc.c */ +#line 9787 "preproc.y" + { + (yyval.str) = cat_str(4,(yyvsp[(1) - (7)].str),mm_strdup("is not of ("),(yyvsp[(6) - (7)].str),mm_strdup(")")); +;} + break; + + case 1632: + +/* Line 1455 of yacc.c */ +#line 9791 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (3)].str),mm_strdup("is document")); +;} + break; + + case 1633: + +/* Line 1455 of yacc.c */ +#line 9795 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (4)].str),mm_strdup("is not document")); +;} + break; + + case 1634: + +/* Line 1455 of yacc.c */ +#line 9803 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1635: + +/* Line 1455 of yacc.c */ +#line 9807 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1636: + +/* Line 1455 of yacc.c */ +#line 9811 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1637: + +/* Line 1455 of yacc.c */ +#line 9815 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("("),(yyvsp[(2) - (4)].str),mm_strdup(")"),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1638: + +/* Line 1455 of yacc.c */ +#line 9819 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1639: + +/* Line 1455 of yacc.c */ +#line 9823 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1640: + +/* Line 1455 of yacc.c */ +#line 9827 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1641: + +/* Line 1455 of yacc.c */ +#line 9831 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("exists"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1642: + +/* Line 1455 of yacc.c */ +#line 9835 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("array"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1643: + +/* Line 1455 of yacc.c */ +#line 9839 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("array"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1644: + +/* Line 1455 of yacc.c */ +#line 9843 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1645: + +/* Line 1455 of yacc.c */ +#line 9851 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (4)].str),mm_strdup("( )"),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1646: + +/* Line 1455 of yacc.c */ +#line 9855 "preproc.y" + { + (yyval.str) = cat_str(5,(yyvsp[(1) - (5)].str),mm_strdup("("),(yyvsp[(3) - (5)].str),mm_strdup(")"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1647: + +/* Line 1455 of yacc.c */ +#line 9859 "preproc.y" + { + (yyval.str) = cat_str(5,(yyvsp[(1) - (6)].str),mm_strdup("( variadic"),(yyvsp[(4) - (6)].str),mm_strdup(")"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1648: + +/* Line 1455 of yacc.c */ +#line 9863 "preproc.y" + { + (yyval.str) = cat_str(7,(yyvsp[(1) - (8)].str),mm_strdup("("),(yyvsp[(3) - (8)].str),mm_strdup(", variadic"),(yyvsp[(6) - (8)].str),mm_strdup(")"),(yyvsp[(8) - (8)].str)); +;} + break; + + case 1649: + +/* Line 1455 of yacc.c */ +#line 9867 "preproc.y" + { + (yyval.str) = cat_str(6,(yyvsp[(1) - (6)].str),mm_strdup("("),(yyvsp[(3) - (6)].str),(yyvsp[(4) - (6)].str),mm_strdup(")"),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1650: + +/* Line 1455 of yacc.c */ +#line 9871 "preproc.y" + { + (yyval.str) = cat_str(6,(yyvsp[(1) - (7)].str),mm_strdup("( all"),(yyvsp[(4) - (7)].str),(yyvsp[(5) - (7)].str),mm_strdup(")"),(yyvsp[(7) - (7)].str)); +;} + break; + + case 1651: + +/* Line 1455 of yacc.c */ +#line 9875 "preproc.y" + { + (yyval.str) = cat_str(6,(yyvsp[(1) - (7)].str),mm_strdup("( distinct"),(yyvsp[(4) - (7)].str),(yyvsp[(5) - (7)].str),mm_strdup(")"),(yyvsp[(7) - (7)].str)); +;} + break; + + case 1652: + +/* Line 1455 of yacc.c */ +#line 9879 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (5)].str),mm_strdup("( * )"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1653: + +/* Line 1455 of yacc.c */ +#line 9883 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("collation for ("),(yyvsp[(4) - (5)].str),mm_strdup(")")); +;} + break; + + case 1654: + +/* Line 1455 of yacc.c */ +#line 9887 "preproc.y" + { + (yyval.str) = mm_strdup("current_date"); +;} + break; + + case 1655: + +/* Line 1455 of yacc.c */ +#line 9891 "preproc.y" + { + (yyval.str) = mm_strdup("current_time"); +;} + break; + + case 1656: + +/* Line 1455 of yacc.c */ +#line 9895 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("current_time ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 1657: + +/* Line 1455 of yacc.c */ +#line 9899 "preproc.y" + { + (yyval.str) = mm_strdup("current_timestamp"); +;} + break; + + case 1658: + +/* Line 1455 of yacc.c */ +#line 9903 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("current_timestamp ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 1659: + +/* Line 1455 of yacc.c */ +#line 9907 "preproc.y" + { + (yyval.str) = mm_strdup("localtime"); +;} + break; + + case 1660: + +/* Line 1455 of yacc.c */ +#line 9911 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("localtime ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 1661: + +/* Line 1455 of yacc.c */ +#line 9915 "preproc.y" + { + (yyval.str) = mm_strdup("localtimestamp"); +;} + break; + + case 1662: + +/* Line 1455 of yacc.c */ +#line 9919 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("localtimestamp ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 1663: + +/* Line 1455 of yacc.c */ +#line 9923 "preproc.y" + { + (yyval.str) = mm_strdup("current_role"); +;} + break; + + case 1664: + +/* Line 1455 of yacc.c */ +#line 9927 "preproc.y" + { + (yyval.str) = mm_strdup("current_user"); +;} + break; + + case 1665: + +/* Line 1455 of yacc.c */ +#line 9931 "preproc.y" + { + (yyval.str) = mm_strdup("session_user"); +;} + break; + + case 1666: + +/* Line 1455 of yacc.c */ +#line 9935 "preproc.y" + { + (yyval.str) = mm_strdup("user"); +;} + break; + + case 1667: + +/* Line 1455 of yacc.c */ +#line 9939 "preproc.y" + { + (yyval.str) = mm_strdup("current_catalog"); +;} + break; + + case 1668: + +/* Line 1455 of yacc.c */ +#line 9943 "preproc.y" + { + (yyval.str) = mm_strdup("current_schema"); +;} + break; + + case 1669: + +/* Line 1455 of yacc.c */ +#line 9947 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("cast ("),(yyvsp[(3) - (6)].str),mm_strdup("as"),(yyvsp[(5) - (6)].str),mm_strdup(")")); +;} + break; + + case 1670: + +/* Line 1455 of yacc.c */ +#line 9951 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("extract ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 1671: + +/* Line 1455 of yacc.c */ +#line 9955 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("overlay ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 1672: + +/* Line 1455 of yacc.c */ +#line 9959 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("position ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 1673: + +/* Line 1455 of yacc.c */ +#line 9963 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("substring ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 1674: + +/* Line 1455 of yacc.c */ +#line 9967 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("treat ("),(yyvsp[(3) - (6)].str),mm_strdup("as"),(yyvsp[(5) - (6)].str),mm_strdup(")")); +;} + break; + + case 1675: + +/* Line 1455 of yacc.c */ +#line 9971 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("trim ( both"),(yyvsp[(4) - (5)].str),mm_strdup(")")); +;} + break; + + case 1676: + +/* Line 1455 of yacc.c */ +#line 9975 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("trim ( leading"),(yyvsp[(4) - (5)].str),mm_strdup(")")); +;} + break; + + case 1677: + +/* Line 1455 of yacc.c */ +#line 9979 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("trim ( trailing"),(yyvsp[(4) - (5)].str),mm_strdup(")")); +;} + break; + + case 1678: + +/* Line 1455 of yacc.c */ +#line 9983 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("trim ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 1679: + +/* Line 1455 of yacc.c */ +#line 9987 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("nullif ("),(yyvsp[(3) - (6)].str),mm_strdup(","),(yyvsp[(5) - (6)].str),mm_strdup(")")); +;} + break; + + case 1680: + +/* Line 1455 of yacc.c */ +#line 9991 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("coalesce ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 1681: + +/* Line 1455 of yacc.c */ +#line 9995 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("greatest ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 1682: + +/* Line 1455 of yacc.c */ +#line 9999 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("least ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 1683: + +/* Line 1455 of yacc.c */ +#line 10003 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("xmlconcat ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 1684: + +/* Line 1455 of yacc.c */ +#line 10007 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("xmlelement ( name"),(yyvsp[(4) - (5)].str),mm_strdup(")")); +;} + break; + + case 1685: + +/* Line 1455 of yacc.c */ +#line 10011 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("xmlelement ( name"),(yyvsp[(4) - (7)].str),mm_strdup(","),(yyvsp[(6) - (7)].str),mm_strdup(")")); +;} + break; + + case 1686: + +/* Line 1455 of yacc.c */ +#line 10015 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("xmlelement ( name"),(yyvsp[(4) - (7)].str),mm_strdup(","),(yyvsp[(6) - (7)].str),mm_strdup(")")); +;} + break; + + case 1687: + +/* Line 1455 of yacc.c */ +#line 10019 "preproc.y" + { + (yyval.str) = cat_str(7,mm_strdup("xmlelement ( name"),(yyvsp[(4) - (9)].str),mm_strdup(","),(yyvsp[(6) - (9)].str),mm_strdup(","),(yyvsp[(8) - (9)].str),mm_strdup(")")); +;} + break; + + case 1688: + +/* Line 1455 of yacc.c */ +#line 10023 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("xmlexists ("),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),mm_strdup(")")); +;} + break; + + case 1689: + +/* Line 1455 of yacc.c */ +#line 10027 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("xmlforest ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 1690: + +/* Line 1455 of yacc.c */ +#line 10031 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("xmlparse ("),(yyvsp[(3) - (6)].str),(yyvsp[(4) - (6)].str),(yyvsp[(5) - (6)].str),mm_strdup(")")); +;} + break; + + case 1691: + +/* Line 1455 of yacc.c */ +#line 10035 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("xmlpi ( name"),(yyvsp[(4) - (5)].str),mm_strdup(")")); +;} + break; + + case 1692: + +/* Line 1455 of yacc.c */ +#line 10039 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("xmlpi ( name"),(yyvsp[(4) - (7)].str),mm_strdup(","),(yyvsp[(6) - (7)].str),mm_strdup(")")); +;} + break; + + case 1693: + +/* Line 1455 of yacc.c */ +#line 10043 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("xmlroot ("),(yyvsp[(3) - (7)].str),mm_strdup(","),(yyvsp[(5) - (7)].str),(yyvsp[(6) - (7)].str),mm_strdup(")")); +;} + break; + + case 1694: + +/* Line 1455 of yacc.c */ +#line 10047 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("xmlserialize ("),(yyvsp[(3) - (7)].str),(yyvsp[(4) - (7)].str),mm_strdup("as"),(yyvsp[(6) - (7)].str),mm_strdup(")")); +;} + break; + + case 1695: + +/* Line 1455 of yacc.c */ +#line 10055 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("version"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1696: + +/* Line 1455 of yacc.c */ +#line 10059 "preproc.y" + { + (yyval.str) = mm_strdup("version no value"); +;} + break; + + case 1697: + +/* Line 1455 of yacc.c */ +#line 10067 "preproc.y" + { + (yyval.str) = mm_strdup(", standalone yes"); +;} + break; + + case 1698: + +/* Line 1455 of yacc.c */ +#line 10071 "preproc.y" + { + (yyval.str) = mm_strdup(", standalone no"); +;} + break; + + case 1699: + +/* Line 1455 of yacc.c */ +#line 10075 "preproc.y" + { + (yyval.str) = mm_strdup(", standalone no value"); +;} + break; + + case 1700: + +/* Line 1455 of yacc.c */ +#line 10079 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1701: + +/* Line 1455 of yacc.c */ +#line 10086 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("xmlattributes ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 1702: + +/* Line 1455 of yacc.c */ +#line 10094 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1703: + +/* Line 1455 of yacc.c */ +#line 10098 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1704: + +/* Line 1455 of yacc.c */ +#line 10106 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("as"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1705: + +/* Line 1455 of yacc.c */ +#line 10110 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1706: + +/* Line 1455 of yacc.c */ +#line 10118 "preproc.y" + { + (yyval.str) = mm_strdup("document"); +;} + break; + + case 1707: + +/* Line 1455 of yacc.c */ +#line 10122 "preproc.y" + { + (yyval.str) = mm_strdup("content"); +;} + break; + + case 1708: + +/* Line 1455 of yacc.c */ +#line 10130 "preproc.y" + { + (yyval.str) = mm_strdup("preserve whitespace"); +;} + break; + + case 1709: + +/* Line 1455 of yacc.c */ +#line 10134 "preproc.y" + { + (yyval.str) = mm_strdup("strip whitespace"); +;} + break; + + case 1710: + +/* Line 1455 of yacc.c */ +#line 10138 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1711: + +/* Line 1455 of yacc.c */ +#line 10145 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("passing"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1712: + +/* Line 1455 of yacc.c */ +#line 10149 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("passing"),(yyvsp[(2) - (4)].str),mm_strdup("by ref")); +;} + break; + + case 1713: + +/* Line 1455 of yacc.c */ +#line 10153 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("passing by ref"),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1714: + +/* Line 1455 of yacc.c */ +#line 10157 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("passing by ref"),(yyvsp[(4) - (6)].str),mm_strdup("by ref")); +;} + break; + + case 1715: + +/* Line 1455 of yacc.c */ +#line 10165 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("window"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1716: + +/* Line 1455 of yacc.c */ +#line 10169 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1717: + +/* Line 1455 of yacc.c */ +#line 10176 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1718: + +/* Line 1455 of yacc.c */ +#line 10180 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1719: + +/* Line 1455 of yacc.c */ +#line 10188 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("as"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1720: + +/* Line 1455 of yacc.c */ +#line 10196 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("over"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1721: + +/* Line 1455 of yacc.c */ +#line 10200 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("over"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1722: + +/* Line 1455 of yacc.c */ +#line 10204 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1723: + +/* Line 1455 of yacc.c */ +#line 10211 "preproc.y" + { + (yyval.str) = cat_str(6,mm_strdup("("),(yyvsp[(2) - (6)].str),(yyvsp[(3) - (6)].str),(yyvsp[(4) - (6)].str),(yyvsp[(5) - (6)].str),mm_strdup(")")); +;} + break; + + case 1724: + +/* Line 1455 of yacc.c */ +#line 10219 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1725: + +/* Line 1455 of yacc.c */ +#line 10223 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1726: + +/* Line 1455 of yacc.c */ +#line 10230 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("partition by"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1727: + +/* Line 1455 of yacc.c */ +#line 10234 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1728: + +/* Line 1455 of yacc.c */ +#line 10241 "preproc.y" + { +mmerror(PARSE_ERROR, ET_WARNING, "unsupported feature will be passed to server"); + (yyval.str) = cat_str(2,mm_strdup("range"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1729: + +/* Line 1455 of yacc.c */ +#line 10246 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("rows"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1730: + +/* Line 1455 of yacc.c */ +#line 10250 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1731: + +/* Line 1455 of yacc.c */ +#line 10257 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1732: + +/* Line 1455 of yacc.c */ +#line 10261 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("between"),(yyvsp[(2) - (4)].str),mm_strdup("and"),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1733: + +/* Line 1455 of yacc.c */ +#line 10269 "preproc.y" + { + (yyval.str) = mm_strdup("unbounded preceding"); +;} + break; + + case 1734: + +/* Line 1455 of yacc.c */ +#line 10273 "preproc.y" + { + (yyval.str) = mm_strdup("unbounded following"); +;} + break; + + case 1735: + +/* Line 1455 of yacc.c */ +#line 10277 "preproc.y" + { + (yyval.str) = mm_strdup("current row"); +;} + break; + + case 1736: + +/* Line 1455 of yacc.c */ +#line 10281 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),mm_strdup("preceding")); +;} + break; + + case 1737: + +/* Line 1455 of yacc.c */ +#line 10285 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),mm_strdup("following")); +;} + break; + + case 1738: + +/* Line 1455 of yacc.c */ +#line 10293 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("row ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 1739: + +/* Line 1455 of yacc.c */ +#line 10297 "preproc.y" + { + (yyval.str) = mm_strdup("row ( )"); +;} + break; + + case 1740: + +/* Line 1455 of yacc.c */ +#line 10301 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("("),(yyvsp[(2) - (5)].str),mm_strdup(","),(yyvsp[(4) - (5)].str),mm_strdup(")")); +;} + break; + + case 1741: + +/* Line 1455 of yacc.c */ +#line 10309 "preproc.y" + { + (yyval.str) = mm_strdup("any"); +;} + break; + + case 1742: + +/* Line 1455 of yacc.c */ +#line 10313 "preproc.y" + { + (yyval.str) = mm_strdup("some"); +;} + break; + + case 1743: + +/* Line 1455 of yacc.c */ +#line 10317 "preproc.y" + { + (yyval.str) = mm_strdup("all"); +;} + break; + + case 1744: + +/* Line 1455 of yacc.c */ +#line 10325 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1745: + +/* Line 1455 of yacc.c */ +#line 10329 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1746: + +/* Line 1455 of yacc.c */ +#line 10337 "preproc.y" + { + (yyval.str) = mm_strdup("+"); +;} + break; + + case 1747: + +/* Line 1455 of yacc.c */ +#line 10341 "preproc.y" + { + (yyval.str) = mm_strdup("-"); +;} + break; + + case 1748: + +/* Line 1455 of yacc.c */ +#line 10345 "preproc.y" + { + (yyval.str) = mm_strdup("*"); +;} + break; + + case 1749: + +/* Line 1455 of yacc.c */ +#line 10349 "preproc.y" + { + (yyval.str) = mm_strdup("/"); +;} + break; + + case 1750: + +/* Line 1455 of yacc.c */ +#line 10353 "preproc.y" + { + (yyval.str) = mm_strdup("%"); +;} + break; + + case 1751: + +/* Line 1455 of yacc.c */ +#line 10357 "preproc.y" + { + (yyval.str) = mm_strdup("^"); +;} + break; + + case 1752: + +/* Line 1455 of yacc.c */ +#line 10361 "preproc.y" + { + (yyval.str) = mm_strdup("<"); +;} + break; + + case 1753: + +/* Line 1455 of yacc.c */ +#line 10365 "preproc.y" + { + (yyval.str) = mm_strdup(">"); +;} + break; + + case 1754: + +/* Line 1455 of yacc.c */ +#line 10369 "preproc.y" + { + (yyval.str) = mm_strdup("="); +;} + break; + + case 1755: + +/* Line 1455 of yacc.c */ +#line 10377 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1756: + +/* Line 1455 of yacc.c */ +#line 10381 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("operator ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 1757: + +/* Line 1455 of yacc.c */ +#line 10389 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1758: + +/* Line 1455 of yacc.c */ +#line 10393 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("operator ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 1759: + +/* Line 1455 of yacc.c */ +#line 10401 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1760: + +/* Line 1455 of yacc.c */ +#line 10405 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("operator ("),(yyvsp[(3) - (4)].str),mm_strdup(")")); +;} + break; + + case 1761: + +/* Line 1455 of yacc.c */ +#line 10409 "preproc.y" + { + (yyval.str) = mm_strdup("like"); +;} + break; + + case 1762: + +/* Line 1455 of yacc.c */ +#line 10413 "preproc.y" + { + (yyval.str) = mm_strdup("not like"); +;} + break; + + case 1763: + +/* Line 1455 of yacc.c */ +#line 10417 "preproc.y" + { + (yyval.str) = mm_strdup("ilike"); +;} + break; + + case 1764: + +/* Line 1455 of yacc.c */ +#line 10421 "preproc.y" + { + (yyval.str) = mm_strdup("not ilike"); +;} + break; + + case 1765: + +/* Line 1455 of yacc.c */ +#line 10429 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1766: + +/* Line 1455 of yacc.c */ +#line 10433 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1767: + +/* Line 1455 of yacc.c */ +#line 10441 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1768: + +/* Line 1455 of yacc.c */ +#line 10445 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1769: + +/* Line 1455 of yacc.c */ +#line 10453 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1770: + +/* Line 1455 of yacc.c */ +#line 10457 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(":="),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1771: + +/* Line 1455 of yacc.c */ +#line 10465 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1772: + +/* Line 1455 of yacc.c */ +#line 10469 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1773: + +/* Line 1455 of yacc.c */ +#line 10477 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("["),(yyvsp[(2) - (3)].str),mm_strdup("]")); +;} + break; + + case 1774: + +/* Line 1455 of yacc.c */ +#line 10481 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("["),(yyvsp[(2) - (3)].str),mm_strdup("]")); +;} + break; + + case 1775: + +/* Line 1455 of yacc.c */ +#line 10485 "preproc.y" + { + (yyval.str) = mm_strdup("[ ]"); +;} + break; + + case 1776: + +/* Line 1455 of yacc.c */ +#line 10493 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1777: + +/* Line 1455 of yacc.c */ +#line 10497 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1778: + +/* Line 1455 of yacc.c */ +#line 10505 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("from"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1779: + +/* Line 1455 of yacc.c */ +#line 10509 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1780: + +/* Line 1455 of yacc.c */ +#line 10516 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1781: + +/* Line 1455 of yacc.c */ +#line 10520 "preproc.y" + { + (yyval.str) = mm_strdup("year"); +;} + break; + + case 1782: + +/* Line 1455 of yacc.c */ +#line 10524 "preproc.y" + { + (yyval.str) = mm_strdup("month"); +;} + break; + + case 1783: + +/* Line 1455 of yacc.c */ +#line 10528 "preproc.y" + { + (yyval.str) = mm_strdup("day"); +;} + break; + + case 1784: + +/* Line 1455 of yacc.c */ +#line 10532 "preproc.y" + { + (yyval.str) = mm_strdup("hour"); +;} + break; + + case 1785: + +/* Line 1455 of yacc.c */ +#line 10536 "preproc.y" + { + (yyval.str) = mm_strdup("minute"); +;} + break; + + case 1786: + +/* Line 1455 of yacc.c */ +#line 10540 "preproc.y" + { + (yyval.str) = mm_strdup("second"); +;} + break; + + case 1787: + +/* Line 1455 of yacc.c */ +#line 10544 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1788: + +/* Line 1455 of yacc.c */ +#line 10552 "preproc.y" + { + (yyval.str) = cat_str(4,(yyvsp[(1) - (4)].str),(yyvsp[(2) - (4)].str),(yyvsp[(3) - (4)].str),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1789: + +/* Line 1455 of yacc.c */ +#line 10556 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1790: + +/* Line 1455 of yacc.c */ +#line 10564 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("placing"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1791: + +/* Line 1455 of yacc.c */ +#line 10572 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("in"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1792: + +/* Line 1455 of yacc.c */ +#line 10576 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1793: + +/* Line 1455 of yacc.c */ +#line 10583 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1794: + +/* Line 1455 of yacc.c */ +#line 10587 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1795: + +/* Line 1455 of yacc.c */ +#line 10591 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1796: + +/* Line 1455 of yacc.c */ +#line 10595 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1797: + +/* Line 1455 of yacc.c */ +#line 10599 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1798: + +/* Line 1455 of yacc.c */ +#line 10603 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1799: + +/* Line 1455 of yacc.c */ +#line 10610 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("from"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1800: + +/* Line 1455 of yacc.c */ +#line 10618 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("for"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1801: + +/* Line 1455 of yacc.c */ +#line 10626 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("from"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1802: + +/* Line 1455 of yacc.c */ +#line 10630 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("from"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1803: + +/* Line 1455 of yacc.c */ +#line 10634 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1804: + +/* Line 1455 of yacc.c */ +#line 10642 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1805: + +/* Line 1455 of yacc.c */ +#line 10646 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (3)].str),mm_strdup(")")); +;} + break; + + case 1806: + +/* Line 1455 of yacc.c */ +#line 10654 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("case"),(yyvsp[(2) - (5)].str),(yyvsp[(3) - (5)].str),(yyvsp[(4) - (5)].str),mm_strdup("end")); +;} + break; + + case 1807: + +/* Line 1455 of yacc.c */ +#line 10662 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1808: + +/* Line 1455 of yacc.c */ +#line 10666 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1809: + +/* Line 1455 of yacc.c */ +#line 10674 "preproc.y" + { + (yyval.str) = cat_str(4,mm_strdup("when"),(yyvsp[(2) - (4)].str),mm_strdup("then"),(yyvsp[(4) - (4)].str)); +;} + break; + + case 1810: + +/* Line 1455 of yacc.c */ +#line 10682 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("else"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1811: + +/* Line 1455 of yacc.c */ +#line 10686 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1812: + +/* Line 1455 of yacc.c */ +#line 10693 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1813: + +/* Line 1455 of yacc.c */ +#line 10697 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1814: + +/* Line 1455 of yacc.c */ +#line 10704 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1815: + +/* Line 1455 of yacc.c */ +#line 10708 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1816: + +/* Line 1455 of yacc.c */ +#line 10716 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("."),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1817: + +/* Line 1455 of yacc.c */ +#line 10720 "preproc.y" + { + (yyval.str) = mm_strdup(". *"); +;} + break; + + case 1818: + +/* Line 1455 of yacc.c */ +#line 10724 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("["),(yyvsp[(2) - (3)].str),mm_strdup("]")); +;} + break; + + case 1819: + +/* Line 1455 of yacc.c */ +#line 10728 "preproc.y" + { + (yyval.str) = cat_str(5,mm_strdup("["),(yyvsp[(2) - (5)].str),mm_strdup(":"),(yyvsp[(4) - (5)].str),mm_strdup("]")); +;} + break; + + case 1820: + +/* Line 1455 of yacc.c */ +#line 10736 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1821: + +/* Line 1455 of yacc.c */ +#line 10740 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1822: + +/* Line 1455 of yacc.c */ +#line 10748 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1823: + +/* Line 1455 of yacc.c */ +#line 10751 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1824: + +/* Line 1455 of yacc.c */ +#line 10759 "preproc.y" + { + (yyval.str) = mm_strdup("asymmetric"); +;} + break; + + case 1825: + +/* Line 1455 of yacc.c */ +#line 10763 "preproc.y" + { + (yyval.str)=EMPTY; ;} + break; + + case 1826: + +/* Line 1455 of yacc.c */ +#line 10770 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1827: + +/* Line 1455 of yacc.c */ +#line 10774 "preproc.y" + { + (yyval.str) = mm_strdup("default"); +;} + break; + + case 1828: + +/* Line 1455 of yacc.c */ +#line 10782 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1829: + +/* Line 1455 of yacc.c */ +#line 10786 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1830: + +/* Line 1455 of yacc.c */ +#line 10794 "preproc.y" + { + (yyval.str) = cat_str(3,mm_strdup("("),(yyvsp[(2) - (3)].str),mm_strdup(")")); +;} + break; + + case 1831: + +/* Line 1455 of yacc.c */ +#line 10802 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1832: + +/* Line 1455 of yacc.c */ +#line 10806 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1833: + +/* Line 1455 of yacc.c */ +#line 10814 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup("as"),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1834: + +/* Line 1455 of yacc.c */ +#line 10818 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1835: + +/* Line 1455 of yacc.c */ +#line 10822 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1836: + +/* Line 1455 of yacc.c */ +#line 10826 "preproc.y" + { + (yyval.str) = mm_strdup("*"); +;} + break; + + case 1837: + +/* Line 1455 of yacc.c */ +#line 10834 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1838: + +/* Line 1455 of yacc.c */ +#line 10838 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1839: + +/* Line 1455 of yacc.c */ +#line 10846 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1840: + +/* Line 1455 of yacc.c */ +#line 10850 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1841: + +/* Line 1455 of yacc.c */ +#line 10858 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1842: + +/* Line 1455 of yacc.c */ +#line 10862 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),mm_strdup(","),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1843: + +/* Line 1455 of yacc.c */ +#line 10870 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1844: + +/* Line 1455 of yacc.c */ +#line 10878 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1845: + +/* Line 1455 of yacc.c */ +#line 10886 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1846: + +/* Line 1455 of yacc.c */ +#line 10894 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1847: + +/* Line 1455 of yacc.c */ +#line 10902 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1848: + +/* Line 1455 of yacc.c */ +#line 10910 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1849: + +/* Line 1455 of yacc.c */ +#line 10918 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1850: + +/* Line 1455 of yacc.c */ +#line 10922 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1851: + +/* Line 1455 of yacc.c */ +#line 10930 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1852: + +/* Line 1455 of yacc.c */ +#line 10934 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1853: + +/* Line 1455 of yacc.c */ +#line 10938 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1854: + +/* Line 1455 of yacc.c */ +#line 10942 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1855: + +/* Line 1455 of yacc.c */ +#line 10946 "preproc.y" + { + (yyval.str) = mm_strdup("xconst"); +;} + break; + + case 1856: + +/* Line 1455 of yacc.c */ +#line 10950 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1857: + +/* Line 1455 of yacc.c */ +#line 10954 "preproc.y" + { + (yyval.str) = cat_str(5,(yyvsp[(1) - (5)].str),mm_strdup("("),(yyvsp[(3) - (5)].str),mm_strdup(")"),(yyvsp[(5) - (5)].str)); +;} + break; + + case 1858: + +/* Line 1455 of yacc.c */ +#line 10958 "preproc.y" + { + (yyval.str) = cat_str(2,(yyvsp[(1) - (2)].str),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1859: + +/* Line 1455 of yacc.c */ +#line 10962 "preproc.y" + { + (yyval.str) = cat_str(3,(yyvsp[(1) - (3)].str),(yyvsp[(2) - (3)].str),(yyvsp[(3) - (3)].str)); +;} + break; + + case 1860: + +/* Line 1455 of yacc.c */ +#line 10966 "preproc.y" + { + (yyval.str) = cat_str(6,(yyvsp[(1) - (6)].str),mm_strdup("("),(yyvsp[(3) - (6)].str),mm_strdup(")"),(yyvsp[(5) - (6)].str),(yyvsp[(6) - (6)].str)); +;} + break; + + case 1861: + +/* Line 1455 of yacc.c */ +#line 10970 "preproc.y" + { + (yyval.str) = mm_strdup("true"); +;} + break; + + case 1862: + +/* Line 1455 of yacc.c */ +#line 10974 "preproc.y" + { + (yyval.str) = mm_strdup("false"); +;} + break; + + case 1863: + +/* Line 1455 of yacc.c */ +#line 10978 "preproc.y" + { + (yyval.str) = mm_strdup("null"); +;} + break; + + case 1864: + +/* Line 1455 of yacc.c */ +#line 10981 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 1865: + +/* Line 1455 of yacc.c */ +#line 10982 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 1866: + +/* Line 1455 of yacc.c */ +#line 10988 "preproc.y" + { (yyval.str) = make_name(); ;} + break; + + case 1867: + +/* Line 1455 of yacc.c */ +#line 10994 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1868: + +/* Line 1455 of yacc.c */ +#line 11002 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); +;} + break; + + case 1869: + +/* Line 1455 of yacc.c */ +#line 11005 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 1870: + +/* Line 1455 of yacc.c */ +#line 11007 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("+"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1871: + +/* Line 1455 of yacc.c */ +#line 11011 "preproc.y" + { + (yyval.str) = cat_str(2,mm_strdup("-"),(yyvsp[(2) - (2)].str)); +;} + break; + + case 1872: + +/* Line 1455 of yacc.c */ +#line 11019 "preproc.y" + { + (yyval.str) = mm_strdup("abort"); +;} + break; + + case 1873: + +/* Line 1455 of yacc.c */ +#line 11023 "preproc.y" + { + (yyval.str) = mm_strdup("absolute"); +;} + break; + + case 1874: + +/* Line 1455 of yacc.c */ +#line 11027 "preproc.y" + { + (yyval.str) = mm_strdup("access"); +;} + break; + + case 1875: + +/* Line 1455 of yacc.c */ +#line 11031 "preproc.y" + { + (yyval.str) = mm_strdup("action"); +;} + break; + + case 1876: + +/* Line 1455 of yacc.c */ +#line 11035 "preproc.y" + { + (yyval.str) = mm_strdup("add"); +;} + break; + + case 1877: + +/* Line 1455 of yacc.c */ +#line 11039 "preproc.y" + { + (yyval.str) = mm_strdup("admin"); +;} + break; + + case 1878: + +/* Line 1455 of yacc.c */ +#line 11043 "preproc.y" + { + (yyval.str) = mm_strdup("after"); +;} + break; + + case 1879: + +/* Line 1455 of yacc.c */ +#line 11047 "preproc.y" + { + (yyval.str) = mm_strdup("aggregate"); +;} + break; + + case 1880: + +/* Line 1455 of yacc.c */ +#line 11051 "preproc.y" + { + (yyval.str) = mm_strdup("also"); +;} + break; + + case 1881: + +/* Line 1455 of yacc.c */ +#line 11055 "preproc.y" + { + (yyval.str) = mm_strdup("alter"); +;} + break; + + case 1882: + +/* Line 1455 of yacc.c */ +#line 11059 "preproc.y" + { + (yyval.str) = mm_strdup("always"); +;} + break; + + case 1883: + +/* Line 1455 of yacc.c */ +#line 11063 "preproc.y" + { + (yyval.str) = mm_strdup("assertion"); +;} + break; + + case 1884: + +/* Line 1455 of yacc.c */ +#line 11067 "preproc.y" + { + (yyval.str) = mm_strdup("assignment"); +;} + break; + + case 1885: + +/* Line 1455 of yacc.c */ +#line 11071 "preproc.y" + { + (yyval.str) = mm_strdup("at"); +;} + break; + + case 1886: + +/* Line 1455 of yacc.c */ +#line 11075 "preproc.y" + { + (yyval.str) = mm_strdup("attribute"); +;} + break; + + case 1887: + +/* Line 1455 of yacc.c */ +#line 11079 "preproc.y" + { + (yyval.str) = mm_strdup("backward"); +;} + break; + + case 1888: + +/* Line 1455 of yacc.c */ +#line 11083 "preproc.y" + { + (yyval.str) = mm_strdup("before"); +;} + break; + + case 1889: + +/* Line 1455 of yacc.c */ +#line 11087 "preproc.y" + { + (yyval.str) = mm_strdup("begin"); +;} + break; + + case 1890: + +/* Line 1455 of yacc.c */ +#line 11091 "preproc.y" + { + (yyval.str) = mm_strdup("by"); +;} + break; + + case 1891: + +/* Line 1455 of yacc.c */ +#line 11095 "preproc.y" + { + (yyval.str) = mm_strdup("cache"); +;} + break; + + case 1892: + +/* Line 1455 of yacc.c */ +#line 11099 "preproc.y" + { + (yyval.str) = mm_strdup("called"); +;} + break; + + case 1893: + +/* Line 1455 of yacc.c */ +#line 11103 "preproc.y" + { + (yyval.str) = mm_strdup("cascade"); +;} + break; + + case 1894: + +/* Line 1455 of yacc.c */ +#line 11107 "preproc.y" + { + (yyval.str) = mm_strdup("cascaded"); +;} + break; + + case 1895: + +/* Line 1455 of yacc.c */ +#line 11111 "preproc.y" + { + (yyval.str) = mm_strdup("catalog"); +;} + break; + + case 1896: + +/* Line 1455 of yacc.c */ +#line 11115 "preproc.y" + { + (yyval.str) = mm_strdup("chain"); +;} + break; + + case 1897: + +/* Line 1455 of yacc.c */ +#line 11119 "preproc.y" + { + (yyval.str) = mm_strdup("characteristics"); +;} + break; + + case 1898: + +/* Line 1455 of yacc.c */ +#line 11123 "preproc.y" + { + (yyval.str) = mm_strdup("checkpoint"); +;} + break; + + case 1899: + +/* Line 1455 of yacc.c */ +#line 11127 "preproc.y" + { + (yyval.str) = mm_strdup("class"); +;} + break; + + case 1900: + +/* Line 1455 of yacc.c */ +#line 11131 "preproc.y" + { + (yyval.str) = mm_strdup("close"); +;} + break; + + case 1901: + +/* Line 1455 of yacc.c */ +#line 11135 "preproc.y" + { + (yyval.str) = mm_strdup("cluster"); +;} + break; + + case 1902: + +/* Line 1455 of yacc.c */ +#line 11139 "preproc.y" + { + (yyval.str) = mm_strdup("comment"); +;} + break; + + case 1903: + +/* Line 1455 of yacc.c */ +#line 11143 "preproc.y" + { + (yyval.str) = mm_strdup("comments"); +;} + break; + + case 1904: + +/* Line 1455 of yacc.c */ +#line 11147 "preproc.y" + { + (yyval.str) = mm_strdup("commit"); +;} + break; + + case 1905: + +/* Line 1455 of yacc.c */ +#line 11151 "preproc.y" + { + (yyval.str) = mm_strdup("committed"); +;} + break; + + case 1906: + +/* Line 1455 of yacc.c */ +#line 11155 "preproc.y" + { + (yyval.str) = mm_strdup("configuration"); +;} + break; + + case 1907: + +/* Line 1455 of yacc.c */ +#line 11159 "preproc.y" + { + (yyval.str) = mm_strdup("constraints"); +;} + break; + + case 1908: + +/* Line 1455 of yacc.c */ +#line 11163 "preproc.y" + { + (yyval.str) = mm_strdup("content"); +;} + break; + + case 1909: + +/* Line 1455 of yacc.c */ +#line 11167 "preproc.y" + { + (yyval.str) = mm_strdup("continue"); +;} + break; + + case 1910: + +/* Line 1455 of yacc.c */ +#line 11171 "preproc.y" + { + (yyval.str) = mm_strdup("conversion"); +;} + break; + + case 1911: + +/* Line 1455 of yacc.c */ +#line 11175 "preproc.y" + { + (yyval.str) = mm_strdup("copy"); +;} + break; + + case 1912: + +/* Line 1455 of yacc.c */ +#line 11179 "preproc.y" + { + (yyval.str) = mm_strdup("cost"); +;} + break; + + case 1913: + +/* Line 1455 of yacc.c */ +#line 11183 "preproc.y" + { + (yyval.str) = mm_strdup("csv"); +;} + break; + + case 1914: + +/* Line 1455 of yacc.c */ +#line 11187 "preproc.y" + { + (yyval.str) = mm_strdup("cursor"); +;} + break; + + case 1915: + +/* Line 1455 of yacc.c */ +#line 11191 "preproc.y" + { + (yyval.str) = mm_strdup("cycle"); +;} + break; + + case 1916: + +/* Line 1455 of yacc.c */ +#line 11195 "preproc.y" + { + (yyval.str) = mm_strdup("data"); +;} + break; + + case 1917: + +/* Line 1455 of yacc.c */ +#line 11199 "preproc.y" + { + (yyval.str) = mm_strdup("database"); +;} + break; + + case 1918: + +/* Line 1455 of yacc.c */ +#line 11203 "preproc.y" + { + (yyval.str) = mm_strdup("deallocate"); +;} + break; + + case 1919: + +/* Line 1455 of yacc.c */ +#line 11207 "preproc.y" + { + (yyval.str) = mm_strdup("declare"); +;} + break; + + case 1920: + +/* Line 1455 of yacc.c */ +#line 11211 "preproc.y" + { + (yyval.str) = mm_strdup("defaults"); +;} + break; + + case 1921: + +/* Line 1455 of yacc.c */ +#line 11215 "preproc.y" + { + (yyval.str) = mm_strdup("deferred"); +;} + break; + + case 1922: + +/* Line 1455 of yacc.c */ +#line 11219 "preproc.y" + { + (yyval.str) = mm_strdup("definer"); +;} + break; + + case 1923: + +/* Line 1455 of yacc.c */ +#line 11223 "preproc.y" + { + (yyval.str) = mm_strdup("delete"); +;} + break; + + case 1924: + +/* Line 1455 of yacc.c */ +#line 11227 "preproc.y" + { + (yyval.str) = mm_strdup("delimiter"); +;} + break; + + case 1925: + +/* Line 1455 of yacc.c */ +#line 11231 "preproc.y" + { + (yyval.str) = mm_strdup("delimiters"); +;} + break; + + case 1926: + +/* Line 1455 of yacc.c */ +#line 11235 "preproc.y" + { + (yyval.str) = mm_strdup("dictionary"); +;} + break; + + case 1927: + +/* Line 1455 of yacc.c */ +#line 11239 "preproc.y" + { + (yyval.str) = mm_strdup("disable"); +;} + break; + + case 1928: + +/* Line 1455 of yacc.c */ +#line 11243 "preproc.y" + { + (yyval.str) = mm_strdup("discard"); +;} + break; + + case 1929: + +/* Line 1455 of yacc.c */ +#line 11247 "preproc.y" + { + (yyval.str) = mm_strdup("document"); +;} + break; + + case 1930: + +/* Line 1455 of yacc.c */ +#line 11251 "preproc.y" + { + (yyval.str) = mm_strdup("domain"); +;} + break; + + case 1931: + +/* Line 1455 of yacc.c */ +#line 11255 "preproc.y" + { + (yyval.str) = mm_strdup("double"); +;} + break; + + case 1932: + +/* Line 1455 of yacc.c */ +#line 11259 "preproc.y" + { + (yyval.str) = mm_strdup("drop"); +;} + break; + + case 1933: + +/* Line 1455 of yacc.c */ +#line 11263 "preproc.y" + { + (yyval.str) = mm_strdup("each"); +;} + break; + + case 1934: + +/* Line 1455 of yacc.c */ +#line 11267 "preproc.y" + { + (yyval.str) = mm_strdup("enable"); +;} + break; + + case 1935: + +/* Line 1455 of yacc.c */ +#line 11271 "preproc.y" + { + (yyval.str) = mm_strdup("encoding"); +;} + break; + + case 1936: + +/* Line 1455 of yacc.c */ +#line 11275 "preproc.y" + { + (yyval.str) = mm_strdup("encrypted"); +;} + break; + + case 1937: + +/* Line 1455 of yacc.c */ +#line 11279 "preproc.y" + { + (yyval.str) = mm_strdup("enum"); +;} + break; + + case 1938: + +/* Line 1455 of yacc.c */ +#line 11283 "preproc.y" + { + (yyval.str) = mm_strdup("escape"); +;} + break; + + case 1939: + +/* Line 1455 of yacc.c */ +#line 11287 "preproc.y" + { + (yyval.str) = mm_strdup("exclude"); +;} + break; + + case 1940: + +/* Line 1455 of yacc.c */ +#line 11291 "preproc.y" + { + (yyval.str) = mm_strdup("excluding"); +;} + break; + + case 1941: + +/* Line 1455 of yacc.c */ +#line 11295 "preproc.y" + { + (yyval.str) = mm_strdup("exclusive"); +;} + break; + + case 1942: + +/* Line 1455 of yacc.c */ +#line 11299 "preproc.y" + { + (yyval.str) = mm_strdup("execute"); +;} + break; + + case 1943: + +/* Line 1455 of yacc.c */ +#line 11303 "preproc.y" + { + (yyval.str) = mm_strdup("explain"); +;} + break; + + case 1944: + +/* Line 1455 of yacc.c */ +#line 11307 "preproc.y" + { + (yyval.str) = mm_strdup("extension"); +;} + break; + + case 1945: + +/* Line 1455 of yacc.c */ +#line 11311 "preproc.y" + { + (yyval.str) = mm_strdup("external"); +;} + break; + + case 1946: + +/* Line 1455 of yacc.c */ +#line 11315 "preproc.y" + { + (yyval.str) = mm_strdup("family"); +;} + break; + + case 1947: + +/* Line 1455 of yacc.c */ +#line 11319 "preproc.y" + { + (yyval.str) = mm_strdup("first"); +;} + break; + + case 1948: + +/* Line 1455 of yacc.c */ +#line 11323 "preproc.y" + { + (yyval.str) = mm_strdup("following"); +;} + break; + + case 1949: + +/* Line 1455 of yacc.c */ +#line 11327 "preproc.y" + { + (yyval.str) = mm_strdup("force"); +;} + break; + + case 1950: + +/* Line 1455 of yacc.c */ +#line 11331 "preproc.y" + { + (yyval.str) = mm_strdup("forward"); +;} + break; + + case 1951: + +/* Line 1455 of yacc.c */ +#line 11335 "preproc.y" + { + (yyval.str) = mm_strdup("function"); +;} + break; + + case 1952: + +/* Line 1455 of yacc.c */ +#line 11339 "preproc.y" + { + (yyval.str) = mm_strdup("functions"); +;} + break; + + case 1953: + +/* Line 1455 of yacc.c */ +#line 11343 "preproc.y" + { + (yyval.str) = mm_strdup("global"); +;} + break; + + case 1954: + +/* Line 1455 of yacc.c */ +#line 11347 "preproc.y" + { + (yyval.str) = mm_strdup("granted"); +;} + break; + + case 1955: + +/* Line 1455 of yacc.c */ +#line 11351 "preproc.y" + { + (yyval.str) = mm_strdup("handler"); +;} + break; + + case 1956: + +/* Line 1455 of yacc.c */ +#line 11355 "preproc.y" + { + (yyval.str) = mm_strdup("header"); +;} + break; + + case 1957: + +/* Line 1455 of yacc.c */ +#line 11359 "preproc.y" + { + (yyval.str) = mm_strdup("hold"); +;} + break; + + case 1958: + +/* Line 1455 of yacc.c */ +#line 11363 "preproc.y" + { + (yyval.str) = mm_strdup("identity"); +;} + break; + + case 1959: + +/* Line 1455 of yacc.c */ +#line 11367 "preproc.y" + { + (yyval.str) = mm_strdup("if"); +;} + break; + + case 1960: + +/* Line 1455 of yacc.c */ +#line 11371 "preproc.y" + { + (yyval.str) = mm_strdup("immediate"); +;} + break; + + case 1961: + +/* Line 1455 of yacc.c */ +#line 11375 "preproc.y" + { + (yyval.str) = mm_strdup("immutable"); +;} + break; + + case 1962: + +/* Line 1455 of yacc.c */ +#line 11379 "preproc.y" + { + (yyval.str) = mm_strdup("implicit"); +;} + break; + + case 1963: + +/* Line 1455 of yacc.c */ +#line 11383 "preproc.y" + { + (yyval.str) = mm_strdup("including"); +;} + break; + + case 1964: + +/* Line 1455 of yacc.c */ +#line 11387 "preproc.y" + { + (yyval.str) = mm_strdup("increment"); +;} + break; + + case 1965: + +/* Line 1455 of yacc.c */ +#line 11391 "preproc.y" + { + (yyval.str) = mm_strdup("index"); +;} + break; + + case 1966: + +/* Line 1455 of yacc.c */ +#line 11395 "preproc.y" + { + (yyval.str) = mm_strdup("indexes"); +;} + break; + + case 1967: + +/* Line 1455 of yacc.c */ +#line 11399 "preproc.y" + { + (yyval.str) = mm_strdup("inherit"); +;} + break; + + case 1968: + +/* Line 1455 of yacc.c */ +#line 11403 "preproc.y" + { + (yyval.str) = mm_strdup("inherits"); +;} + break; + + case 1969: + +/* Line 1455 of yacc.c */ +#line 11407 "preproc.y" + { + (yyval.str) = mm_strdup("inline"); +;} + break; + + case 1970: + +/* Line 1455 of yacc.c */ +#line 11411 "preproc.y" + { + (yyval.str) = mm_strdup("insensitive"); +;} + break; + + case 1971: + +/* Line 1455 of yacc.c */ +#line 11415 "preproc.y" + { + (yyval.str) = mm_strdup("insert"); +;} + break; + + case 1972: + +/* Line 1455 of yacc.c */ +#line 11419 "preproc.y" + { + (yyval.str) = mm_strdup("instead"); +;} + break; + + case 1973: + +/* Line 1455 of yacc.c */ +#line 11423 "preproc.y" + { + (yyval.str) = mm_strdup("invoker"); +;} + break; + + case 1974: + +/* Line 1455 of yacc.c */ +#line 11427 "preproc.y" + { + (yyval.str) = mm_strdup("isolation"); +;} + break; + + case 1975: + +/* Line 1455 of yacc.c */ +#line 11431 "preproc.y" + { + (yyval.str) = mm_strdup("key"); +;} + break; + + case 1976: + +/* Line 1455 of yacc.c */ +#line 11435 "preproc.y" + { + (yyval.str) = mm_strdup("label"); +;} + break; + + case 1977: + +/* Line 1455 of yacc.c */ +#line 11439 "preproc.y" + { + (yyval.str) = mm_strdup("language"); +;} + break; + + case 1978: + +/* Line 1455 of yacc.c */ +#line 11443 "preproc.y" + { + (yyval.str) = mm_strdup("large"); +;} + break; + + case 1979: + +/* Line 1455 of yacc.c */ +#line 11447 "preproc.y" + { + (yyval.str) = mm_strdup("last"); +;} + break; + + case 1980: + +/* Line 1455 of yacc.c */ +#line 11451 "preproc.y" + { + (yyval.str) = mm_strdup("lc_collate"); +;} + break; + + case 1981: + +/* Line 1455 of yacc.c */ +#line 11455 "preproc.y" + { + (yyval.str) = mm_strdup("lc_ctype"); +;} + break; + + case 1982: + +/* Line 1455 of yacc.c */ +#line 11459 "preproc.y" + { + (yyval.str) = mm_strdup("leakproof"); +;} + break; + + case 1983: + +/* Line 1455 of yacc.c */ +#line 11463 "preproc.y" + { + (yyval.str) = mm_strdup("level"); +;} + break; + + case 1984: + +/* Line 1455 of yacc.c */ +#line 11467 "preproc.y" + { + (yyval.str) = mm_strdup("listen"); +;} + break; + + case 1985: + +/* Line 1455 of yacc.c */ +#line 11471 "preproc.y" + { + (yyval.str) = mm_strdup("load"); +;} + break; + + case 1986: + +/* Line 1455 of yacc.c */ +#line 11475 "preproc.y" + { + (yyval.str) = mm_strdup("local"); +;} + break; + + case 1987: + +/* Line 1455 of yacc.c */ +#line 11479 "preproc.y" + { + (yyval.str) = mm_strdup("location"); +;} + break; + + case 1988: + +/* Line 1455 of yacc.c */ +#line 11483 "preproc.y" + { + (yyval.str) = mm_strdup("lock"); +;} + break; + + case 1989: + +/* Line 1455 of yacc.c */ +#line 11487 "preproc.y" + { + (yyval.str) = mm_strdup("mapping"); +;} + break; + + case 1990: + +/* Line 1455 of yacc.c */ +#line 11491 "preproc.y" + { + (yyval.str) = mm_strdup("match"); +;} + break; + + case 1991: + +/* Line 1455 of yacc.c */ +#line 11495 "preproc.y" + { + (yyval.str) = mm_strdup("maxvalue"); +;} + break; + + case 1992: + +/* Line 1455 of yacc.c */ +#line 11499 "preproc.y" + { + (yyval.str) = mm_strdup("minvalue"); +;} + break; + + case 1993: + +/* Line 1455 of yacc.c */ +#line 11503 "preproc.y" + { + (yyval.str) = mm_strdup("mode"); +;} + break; + + case 1994: + +/* Line 1455 of yacc.c */ +#line 11507 "preproc.y" + { + (yyval.str) = mm_strdup("move"); +;} + break; + + case 1995: + +/* Line 1455 of yacc.c */ +#line 11511 "preproc.y" + { + (yyval.str) = mm_strdup("name"); +;} + break; + + case 1996: + +/* Line 1455 of yacc.c */ +#line 11515 "preproc.y" + { + (yyval.str) = mm_strdup("names"); +;} + break; + + case 1997: + +/* Line 1455 of yacc.c */ +#line 11519 "preproc.y" + { + (yyval.str) = mm_strdup("next"); +;} + break; + + case 1998: + +/* Line 1455 of yacc.c */ +#line 11523 "preproc.y" + { + (yyval.str) = mm_strdup("no"); +;} + break; + + case 1999: + +/* Line 1455 of yacc.c */ +#line 11527 "preproc.y" + { + (yyval.str) = mm_strdup("nothing"); +;} + break; + + case 2000: + +/* Line 1455 of yacc.c */ +#line 11531 "preproc.y" + { + (yyval.str) = mm_strdup("notify"); +;} + break; + + case 2001: + +/* Line 1455 of yacc.c */ +#line 11535 "preproc.y" + { + (yyval.str) = mm_strdup("nowait"); +;} + break; + + case 2002: + +/* Line 1455 of yacc.c */ +#line 11539 "preproc.y" + { + (yyval.str) = mm_strdup("nulls"); +;} + break; + + case 2003: + +/* Line 1455 of yacc.c */ +#line 11543 "preproc.y" + { + (yyval.str) = mm_strdup("object"); +;} + break; + + case 2004: + +/* Line 1455 of yacc.c */ +#line 11547 "preproc.y" + { + (yyval.str) = mm_strdup("of"); +;} + break; + + case 2005: + +/* Line 1455 of yacc.c */ +#line 11551 "preproc.y" + { + (yyval.str) = mm_strdup("off"); +;} + break; + + case 2006: + +/* Line 1455 of yacc.c */ +#line 11555 "preproc.y" + { + (yyval.str) = mm_strdup("oids"); +;} + break; + + case 2007: + +/* Line 1455 of yacc.c */ +#line 11559 "preproc.y" + { + (yyval.str) = mm_strdup("operator"); +;} + break; + + case 2008: + +/* Line 1455 of yacc.c */ +#line 11563 "preproc.y" + { + (yyval.str) = mm_strdup("option"); +;} + break; + + case 2009: + +/* Line 1455 of yacc.c */ +#line 11567 "preproc.y" + { + (yyval.str) = mm_strdup("options"); +;} + break; + + case 2010: + +/* Line 1455 of yacc.c */ +#line 11571 "preproc.y" + { + (yyval.str) = mm_strdup("owned"); +;} + break; + + case 2011: + +/* Line 1455 of yacc.c */ +#line 11575 "preproc.y" + { + (yyval.str) = mm_strdup("owner"); +;} + break; + + case 2012: + +/* Line 1455 of yacc.c */ +#line 11579 "preproc.y" + { + (yyval.str) = mm_strdup("parser"); +;} + break; + + case 2013: + +/* Line 1455 of yacc.c */ +#line 11583 "preproc.y" + { + (yyval.str) = mm_strdup("partial"); +;} + break; + + case 2014: + +/* Line 1455 of yacc.c */ +#line 11587 "preproc.y" + { + (yyval.str) = mm_strdup("partition"); +;} + break; + + case 2015: + +/* Line 1455 of yacc.c */ +#line 11591 "preproc.y" + { + (yyval.str) = mm_strdup("passing"); +;} + break; + + case 2016: + +/* Line 1455 of yacc.c */ +#line 11595 "preproc.y" + { + (yyval.str) = mm_strdup("password"); +;} + break; + + case 2017: + +/* Line 1455 of yacc.c */ +#line 11599 "preproc.y" + { + (yyval.str) = mm_strdup("plans"); +;} + break; + + case 2018: + +/* Line 1455 of yacc.c */ +#line 11603 "preproc.y" + { + (yyval.str) = mm_strdup("preceding"); +;} + break; + + case 2019: + +/* Line 1455 of yacc.c */ +#line 11607 "preproc.y" + { + (yyval.str) = mm_strdup("prepare"); +;} + break; + + case 2020: + +/* Line 1455 of yacc.c */ +#line 11611 "preproc.y" + { + (yyval.str) = mm_strdup("prepared"); +;} + break; + + case 2021: + +/* Line 1455 of yacc.c */ +#line 11615 "preproc.y" + { + (yyval.str) = mm_strdup("preserve"); +;} + break; + + case 2022: + +/* Line 1455 of yacc.c */ +#line 11619 "preproc.y" + { + (yyval.str) = mm_strdup("prior"); +;} + break; + + case 2023: + +/* Line 1455 of yacc.c */ +#line 11623 "preproc.y" + { + (yyval.str) = mm_strdup("privileges"); +;} + break; + + case 2024: + +/* Line 1455 of yacc.c */ +#line 11627 "preproc.y" + { + (yyval.str) = mm_strdup("procedural"); +;} + break; + + case 2025: + +/* Line 1455 of yacc.c */ +#line 11631 "preproc.y" + { + (yyval.str) = mm_strdup("procedure"); +;} + break; + + case 2026: + +/* Line 1455 of yacc.c */ +#line 11635 "preproc.y" + { + (yyval.str) = mm_strdup("quote"); +;} + break; + + case 2027: + +/* Line 1455 of yacc.c */ +#line 11639 "preproc.y" + { + (yyval.str) = mm_strdup("range"); +;} + break; + + case 2028: + +/* Line 1455 of yacc.c */ +#line 11643 "preproc.y" + { + (yyval.str) = mm_strdup("read"); +;} + break; + + case 2029: + +/* Line 1455 of yacc.c */ +#line 11647 "preproc.y" + { + (yyval.str) = mm_strdup("reassign"); +;} + break; + + case 2030: + +/* Line 1455 of yacc.c */ +#line 11651 "preproc.y" + { + (yyval.str) = mm_strdup("recheck"); +;} + break; + + case 2031: + +/* Line 1455 of yacc.c */ +#line 11655 "preproc.y" + { + (yyval.str) = mm_strdup("recursive"); +;} + break; + + case 2032: + +/* Line 1455 of yacc.c */ +#line 11659 "preproc.y" + { + (yyval.str) = mm_strdup("ref"); +;} + break; + + case 2033: + +/* Line 1455 of yacc.c */ +#line 11663 "preproc.y" + { + (yyval.str) = mm_strdup("reindex"); +;} + break; + + case 2034: + +/* Line 1455 of yacc.c */ +#line 11667 "preproc.y" + { + (yyval.str) = mm_strdup("relative"); +;} + break; + + case 2035: + +/* Line 1455 of yacc.c */ +#line 11671 "preproc.y" + { + (yyval.str) = mm_strdup("release"); +;} + break; + + case 2036: + +/* Line 1455 of yacc.c */ +#line 11675 "preproc.y" + { + (yyval.str) = mm_strdup("rename"); +;} + break; + + case 2037: + +/* Line 1455 of yacc.c */ +#line 11679 "preproc.y" + { + (yyval.str) = mm_strdup("repeatable"); +;} + break; + + case 2038: + +/* Line 1455 of yacc.c */ +#line 11683 "preproc.y" + { + (yyval.str) = mm_strdup("replace"); +;} + break; + + case 2039: + +/* Line 1455 of yacc.c */ +#line 11687 "preproc.y" + { + (yyval.str) = mm_strdup("replica"); +;} + break; + + case 2040: + +/* Line 1455 of yacc.c */ +#line 11691 "preproc.y" + { + (yyval.str) = mm_strdup("reset"); +;} + break; + + case 2041: + +/* Line 1455 of yacc.c */ +#line 11695 "preproc.y" + { + (yyval.str) = mm_strdup("restart"); +;} + break; + + case 2042: + +/* Line 1455 of yacc.c */ +#line 11699 "preproc.y" + { + (yyval.str) = mm_strdup("restrict"); +;} + break; + + case 2043: + +/* Line 1455 of yacc.c */ +#line 11703 "preproc.y" + { + (yyval.str) = mm_strdup("returns"); +;} + break; + + case 2044: + +/* Line 1455 of yacc.c */ +#line 11707 "preproc.y" + { + (yyval.str) = mm_strdup("revoke"); +;} + break; + + case 2045: + +/* Line 1455 of yacc.c */ +#line 11711 "preproc.y" + { + (yyval.str) = mm_strdup("role"); +;} + break; + + case 2046: + +/* Line 1455 of yacc.c */ +#line 11715 "preproc.y" + { + (yyval.str) = mm_strdup("rollback"); +;} + break; + + case 2047: + +/* Line 1455 of yacc.c */ +#line 11719 "preproc.y" + { + (yyval.str) = mm_strdup("rows"); +;} + break; + + case 2048: + +/* Line 1455 of yacc.c */ +#line 11723 "preproc.y" + { + (yyval.str) = mm_strdup("rule"); +;} + break; + + case 2049: + +/* Line 1455 of yacc.c */ +#line 11727 "preproc.y" + { + (yyval.str) = mm_strdup("savepoint"); +;} + break; + + case 2050: + +/* Line 1455 of yacc.c */ +#line 11731 "preproc.y" + { + (yyval.str) = mm_strdup("schema"); +;} + break; + + case 2051: + +/* Line 1455 of yacc.c */ +#line 11735 "preproc.y" + { + (yyval.str) = mm_strdup("scroll"); +;} + break; + + case 2052: + +/* Line 1455 of yacc.c */ +#line 11739 "preproc.y" + { + (yyval.str) = mm_strdup("search"); +;} + break; + + case 2053: + +/* Line 1455 of yacc.c */ +#line 11743 "preproc.y" + { + (yyval.str) = mm_strdup("security"); +;} + break; + + case 2054: + +/* Line 1455 of yacc.c */ +#line 11747 "preproc.y" + { + (yyval.str) = mm_strdup("sequence"); +;} + break; + + case 2055: + +/* Line 1455 of yacc.c */ +#line 11751 "preproc.y" + { + (yyval.str) = mm_strdup("sequences"); +;} + break; + + case 2056: + +/* Line 1455 of yacc.c */ +#line 11755 "preproc.y" + { + (yyval.str) = mm_strdup("serializable"); +;} + break; + + case 2057: + +/* Line 1455 of yacc.c */ +#line 11759 "preproc.y" + { + (yyval.str) = mm_strdup("server"); +;} + break; + + case 2058: + +/* Line 1455 of yacc.c */ +#line 11763 "preproc.y" + { + (yyval.str) = mm_strdup("session"); +;} + break; + + case 2059: + +/* Line 1455 of yacc.c */ +#line 11767 "preproc.y" + { + (yyval.str) = mm_strdup("set"); +;} + break; + + case 2060: + +/* Line 1455 of yacc.c */ +#line 11771 "preproc.y" + { + (yyval.str) = mm_strdup("share"); +;} + break; + + case 2061: + +/* Line 1455 of yacc.c */ +#line 11775 "preproc.y" + { + (yyval.str) = mm_strdup("show"); +;} + break; + + case 2062: + +/* Line 1455 of yacc.c */ +#line 11779 "preproc.y" + { + (yyval.str) = mm_strdup("simple"); +;} + break; + + case 2063: + +/* Line 1455 of yacc.c */ +#line 11783 "preproc.y" + { + (yyval.str) = mm_strdup("snapshot"); +;} + break; + + case 2064: + +/* Line 1455 of yacc.c */ +#line 11787 "preproc.y" + { + (yyval.str) = mm_strdup("stable"); +;} + break; + + case 2065: + +/* Line 1455 of yacc.c */ +#line 11791 "preproc.y" + { + (yyval.str) = mm_strdup("standalone"); +;} + break; + + case 2066: + +/* Line 1455 of yacc.c */ +#line 11795 "preproc.y" + { + (yyval.str) = mm_strdup("start"); +;} + break; + + case 2067: + +/* Line 1455 of yacc.c */ +#line 11799 "preproc.y" + { + (yyval.str) = mm_strdup("statement"); +;} + break; + + case 2068: + +/* Line 1455 of yacc.c */ +#line 11803 "preproc.y" + { + (yyval.str) = mm_strdup("statistics"); +;} + break; + + case 2069: + +/* Line 1455 of yacc.c */ +#line 11807 "preproc.y" + { + (yyval.str) = mm_strdup("stdin"); +;} + break; + + case 2070: + +/* Line 1455 of yacc.c */ +#line 11811 "preproc.y" + { + (yyval.str) = mm_strdup("stdout"); +;} + break; + + case 2071: + +/* Line 1455 of yacc.c */ +#line 11815 "preproc.y" + { + (yyval.str) = mm_strdup("storage"); +;} + break; + + case 2072: + +/* Line 1455 of yacc.c */ +#line 11819 "preproc.y" + { + (yyval.str) = mm_strdup("strict"); +;} + break; + + case 2073: + +/* Line 1455 of yacc.c */ +#line 11823 "preproc.y" + { + (yyval.str) = mm_strdup("strip"); +;} + break; + + case 2074: + +/* Line 1455 of yacc.c */ +#line 11827 "preproc.y" + { + (yyval.str) = mm_strdup("sysid"); +;} + break; + + case 2075: + +/* Line 1455 of yacc.c */ +#line 11831 "preproc.y" + { + (yyval.str) = mm_strdup("system"); +;} + break; + + case 2076: + +/* Line 1455 of yacc.c */ +#line 11835 "preproc.y" + { + (yyval.str) = mm_strdup("tables"); +;} + break; + + case 2077: + +/* Line 1455 of yacc.c */ +#line 11839 "preproc.y" + { + (yyval.str) = mm_strdup("tablespace"); +;} + break; + + case 2078: + +/* Line 1455 of yacc.c */ +#line 11843 "preproc.y" + { + (yyval.str) = mm_strdup("temp"); +;} + break; + + case 2079: + +/* Line 1455 of yacc.c */ +#line 11847 "preproc.y" + { + (yyval.str) = mm_strdup("template"); +;} + break; + + case 2080: + +/* Line 1455 of yacc.c */ +#line 11851 "preproc.y" + { + (yyval.str) = mm_strdup("temporary"); +;} + break; + + case 2081: + +/* Line 1455 of yacc.c */ +#line 11855 "preproc.y" + { + (yyval.str) = mm_strdup("text"); +;} + break; + + case 2082: + +/* Line 1455 of yacc.c */ +#line 11859 "preproc.y" + { + (yyval.str) = mm_strdup("transaction"); +;} + break; + + case 2083: + +/* Line 1455 of yacc.c */ +#line 11863 "preproc.y" + { + (yyval.str) = mm_strdup("trigger"); +;} + break; + + case 2084: + +/* Line 1455 of yacc.c */ +#line 11867 "preproc.y" + { + (yyval.str) = mm_strdup("truncate"); +;} + break; + + case 2085: + +/* Line 1455 of yacc.c */ +#line 11871 "preproc.y" + { + (yyval.str) = mm_strdup("trusted"); +;} + break; + + case 2086: + +/* Line 1455 of yacc.c */ +#line 11875 "preproc.y" + { + (yyval.str) = mm_strdup("type"); +;} + break; + + case 2087: + +/* Line 1455 of yacc.c */ +#line 11879 "preproc.y" + { + (yyval.str) = mm_strdup("types"); +;} + break; + + case 2088: + +/* Line 1455 of yacc.c */ +#line 11883 "preproc.y" + { + (yyval.str) = mm_strdup("unbounded"); +;} + break; + + case 2089: + +/* Line 1455 of yacc.c */ +#line 11887 "preproc.y" + { + (yyval.str) = mm_strdup("uncommitted"); +;} + break; + + case 2090: + +/* Line 1455 of yacc.c */ +#line 11891 "preproc.y" + { + (yyval.str) = mm_strdup("unencrypted"); +;} + break; + + case 2091: + +/* Line 1455 of yacc.c */ +#line 11895 "preproc.y" + { + (yyval.str) = mm_strdup("unknown"); +;} + break; + + case 2092: + +/* Line 1455 of yacc.c */ +#line 11899 "preproc.y" + { + (yyval.str) = mm_strdup("unlisten"); +;} + break; + + case 2093: + +/* Line 1455 of yacc.c */ +#line 11903 "preproc.y" + { + (yyval.str) = mm_strdup("unlogged"); +;} + break; + + case 2094: + +/* Line 1455 of yacc.c */ +#line 11907 "preproc.y" + { + (yyval.str) = mm_strdup("until"); +;} + break; + + case 2095: + +/* Line 1455 of yacc.c */ +#line 11911 "preproc.y" + { + (yyval.str) = mm_strdup("update"); +;} + break; + + case 2096: + +/* Line 1455 of yacc.c */ +#line 11915 "preproc.y" + { + (yyval.str) = mm_strdup("vacuum"); +;} + break; + + case 2097: + +/* Line 1455 of yacc.c */ +#line 11919 "preproc.y" + { + (yyval.str) = mm_strdup("valid"); +;} + break; + + case 2098: + +/* Line 1455 of yacc.c */ +#line 11923 "preproc.y" + { + (yyval.str) = mm_strdup("validate"); +;} + break; + + case 2099: + +/* Line 1455 of yacc.c */ +#line 11927 "preproc.y" + { + (yyval.str) = mm_strdup("validator"); +;} + break; + + case 2100: + +/* Line 1455 of yacc.c */ +#line 11931 "preproc.y" + { + (yyval.str) = mm_strdup("value"); +;} + break; + + case 2101: + +/* Line 1455 of yacc.c */ +#line 11935 "preproc.y" + { + (yyval.str) = mm_strdup("varying"); +;} + break; + + case 2102: + +/* Line 1455 of yacc.c */ +#line 11939 "preproc.y" + { + (yyval.str) = mm_strdup("version"); +;} + break; + + case 2103: + +/* Line 1455 of yacc.c */ +#line 11943 "preproc.y" + { + (yyval.str) = mm_strdup("view"); +;} + break; + + case 2104: + +/* Line 1455 of yacc.c */ +#line 11947 "preproc.y" + { + (yyval.str) = mm_strdup("volatile"); +;} + break; + + case 2105: + +/* Line 1455 of yacc.c */ +#line 11951 "preproc.y" + { + (yyval.str) = mm_strdup("whitespace"); +;} + break; + + case 2106: + +/* Line 1455 of yacc.c */ +#line 11955 "preproc.y" + { + (yyval.str) = mm_strdup("without"); +;} + break; + + case 2107: + +/* Line 1455 of yacc.c */ +#line 11959 "preproc.y" + { + (yyval.str) = mm_strdup("work"); +;} + break; + + case 2108: + +/* Line 1455 of yacc.c */ +#line 11963 "preproc.y" + { + (yyval.str) = mm_strdup("wrapper"); +;} + break; + + case 2109: + +/* Line 1455 of yacc.c */ +#line 11967 "preproc.y" + { + (yyval.str) = mm_strdup("write"); +;} + break; + + case 2110: + +/* Line 1455 of yacc.c */ +#line 11971 "preproc.y" + { + (yyval.str) = mm_strdup("xml"); +;} + break; + + case 2111: + +/* Line 1455 of yacc.c */ +#line 11975 "preproc.y" + { + (yyval.str) = mm_strdup("yes"); +;} + break; + + case 2112: + +/* Line 1455 of yacc.c */ +#line 11979 "preproc.y" + { + (yyval.str) = mm_strdup("zone"); +;} + break; + + case 2113: + +/* Line 1455 of yacc.c */ +#line 11987 "preproc.y" + { + (yyval.str) = mm_strdup("between"); +;} + break; + + case 2114: + +/* Line 1455 of yacc.c */ +#line 11991 "preproc.y" + { + (yyval.str) = mm_strdup("bigint"); +;} + break; + + case 2115: + +/* Line 1455 of yacc.c */ +#line 11995 "preproc.y" + { + (yyval.str) = mm_strdup("bit"); +;} + break; + + case 2116: + +/* Line 1455 of yacc.c */ +#line 11999 "preproc.y" + { + (yyval.str) = mm_strdup("boolean"); +;} + break; + + case 2117: + +/* Line 1455 of yacc.c */ +#line 12003 "preproc.y" + { + (yyval.str) = mm_strdup("character"); +;} + break; + + case 2118: + +/* Line 1455 of yacc.c */ +#line 12007 "preproc.y" + { + (yyval.str) = mm_strdup("coalesce"); +;} + break; + + case 2119: + +/* Line 1455 of yacc.c */ +#line 12011 "preproc.y" + { + (yyval.str) = mm_strdup("dec"); +;} + break; + + case 2120: + +/* Line 1455 of yacc.c */ +#line 12015 "preproc.y" + { + (yyval.str) = mm_strdup("decimal"); +;} + break; + + case 2121: + +/* Line 1455 of yacc.c */ +#line 12019 "preproc.y" + { + (yyval.str) = mm_strdup("exists"); +;} + break; + + case 2122: + +/* Line 1455 of yacc.c */ +#line 12023 "preproc.y" + { + (yyval.str) = mm_strdup("extract"); +;} + break; + + case 2123: + +/* Line 1455 of yacc.c */ +#line 12027 "preproc.y" + { + (yyval.str) = mm_strdup("float"); +;} + break; + + case 2124: + +/* Line 1455 of yacc.c */ +#line 12031 "preproc.y" + { + (yyval.str) = mm_strdup("greatest"); +;} + break; + + case 2125: + +/* Line 1455 of yacc.c */ +#line 12035 "preproc.y" + { + (yyval.str) = mm_strdup("inout"); +;} + break; + + case 2126: + +/* Line 1455 of yacc.c */ +#line 12039 "preproc.y" + { + (yyval.str) = mm_strdup("integer"); +;} + break; + + case 2127: + +/* Line 1455 of yacc.c */ +#line 12043 "preproc.y" + { + (yyval.str) = mm_strdup("interval"); +;} + break; + + case 2128: + +/* Line 1455 of yacc.c */ +#line 12047 "preproc.y" + { + (yyval.str) = mm_strdup("least"); +;} + break; + + case 2129: + +/* Line 1455 of yacc.c */ +#line 12051 "preproc.y" + { + (yyval.str) = mm_strdup("national"); +;} + break; + + case 2130: + +/* Line 1455 of yacc.c */ +#line 12055 "preproc.y" + { + (yyval.str) = mm_strdup("nchar"); +;} + break; + + case 2131: + +/* Line 1455 of yacc.c */ +#line 12059 "preproc.y" + { + (yyval.str) = mm_strdup("none"); +;} + break; + + case 2132: + +/* Line 1455 of yacc.c */ +#line 12063 "preproc.y" + { + (yyval.str) = mm_strdup("nullif"); +;} + break; + + case 2133: + +/* Line 1455 of yacc.c */ +#line 12067 "preproc.y" + { + (yyval.str) = mm_strdup("numeric"); +;} + break; + + case 2134: + +/* Line 1455 of yacc.c */ +#line 12071 "preproc.y" + { + (yyval.str) = mm_strdup("out"); +;} + break; + + case 2135: + +/* Line 1455 of yacc.c */ +#line 12075 "preproc.y" + { + (yyval.str) = mm_strdup("overlay"); +;} + break; + + case 2136: + +/* Line 1455 of yacc.c */ +#line 12079 "preproc.y" + { + (yyval.str) = mm_strdup("position"); +;} + break; + + case 2137: + +/* Line 1455 of yacc.c */ +#line 12083 "preproc.y" + { + (yyval.str) = mm_strdup("precision"); +;} + break; + + case 2138: + +/* Line 1455 of yacc.c */ +#line 12087 "preproc.y" + { + (yyval.str) = mm_strdup("real"); +;} + break; + + case 2139: + +/* Line 1455 of yacc.c */ +#line 12091 "preproc.y" + { + (yyval.str) = mm_strdup("row"); +;} + break; + + case 2140: + +/* Line 1455 of yacc.c */ +#line 12095 "preproc.y" + { + (yyval.str) = mm_strdup("setof"); +;} + break; + + case 2141: + +/* Line 1455 of yacc.c */ +#line 12099 "preproc.y" + { + (yyval.str) = mm_strdup("smallint"); +;} + break; + + case 2142: + +/* Line 1455 of yacc.c */ +#line 12103 "preproc.y" + { + (yyval.str) = mm_strdup("substring"); +;} + break; + + case 2143: + +/* Line 1455 of yacc.c */ +#line 12107 "preproc.y" + { + (yyval.str) = mm_strdup("time"); +;} + break; + + case 2144: + +/* Line 1455 of yacc.c */ +#line 12111 "preproc.y" + { + (yyval.str) = mm_strdup("timestamp"); +;} + break; + + case 2145: + +/* Line 1455 of yacc.c */ +#line 12115 "preproc.y" + { + (yyval.str) = mm_strdup("treat"); +;} + break; + + case 2146: + +/* Line 1455 of yacc.c */ +#line 12119 "preproc.y" + { + (yyval.str) = mm_strdup("trim"); +;} + break; + + case 2147: + +/* Line 1455 of yacc.c */ +#line 12123 "preproc.y" + { + (yyval.str) = mm_strdup("varchar"); +;} + break; + + case 2148: + +/* Line 1455 of yacc.c */ +#line 12127 "preproc.y" + { + (yyval.str) = mm_strdup("xmlattributes"); +;} + break; + + case 2149: + +/* Line 1455 of yacc.c */ +#line 12131 "preproc.y" + { + (yyval.str) = mm_strdup("xmlconcat"); +;} + break; + + case 2150: + +/* Line 1455 of yacc.c */ +#line 12135 "preproc.y" + { + (yyval.str) = mm_strdup("xmlelement"); +;} + break; + + case 2151: + +/* Line 1455 of yacc.c */ +#line 12139 "preproc.y" + { + (yyval.str) = mm_strdup("xmlexists"); +;} + break; + + case 2152: + +/* Line 1455 of yacc.c */ +#line 12143 "preproc.y" + { + (yyval.str) = mm_strdup("xmlforest"); +;} + break; + + case 2153: + +/* Line 1455 of yacc.c */ +#line 12147 "preproc.y" + { + (yyval.str) = mm_strdup("xmlparse"); +;} + break; + + case 2154: + +/* Line 1455 of yacc.c */ +#line 12151 "preproc.y" + { + (yyval.str) = mm_strdup("xmlpi"); +;} + break; + + case 2155: + +/* Line 1455 of yacc.c */ +#line 12155 "preproc.y" + { + (yyval.str) = mm_strdup("xmlroot"); +;} + break; + + case 2156: + +/* Line 1455 of yacc.c */ +#line 12159 "preproc.y" + { + (yyval.str) = mm_strdup("xmlserialize"); +;} + break; + + case 2157: + +/* Line 1455 of yacc.c */ +#line 12167 "preproc.y" + { + (yyval.str) = mm_strdup("authorization"); +;} + break; + + case 2158: + +/* Line 1455 of yacc.c */ +#line 12171 "preproc.y" + { + (yyval.str) = mm_strdup("binary"); +;} + break; + + case 2159: + +/* Line 1455 of yacc.c */ +#line 12175 "preproc.y" + { + (yyval.str) = mm_strdup("collation"); +;} + break; + + case 2160: + +/* Line 1455 of yacc.c */ +#line 12179 "preproc.y" + { + (yyval.str) = mm_strdup("concurrently"); +;} + break; + + case 2161: + +/* Line 1455 of yacc.c */ +#line 12183 "preproc.y" + { + (yyval.str) = mm_strdup("cross"); +;} + break; + + case 2162: + +/* Line 1455 of yacc.c */ +#line 12187 "preproc.y" + { + (yyval.str) = mm_strdup("current_schema"); +;} + break; + + case 2163: + +/* Line 1455 of yacc.c */ +#line 12191 "preproc.y" + { + (yyval.str) = mm_strdup("freeze"); +;} + break; + + case 2164: + +/* Line 1455 of yacc.c */ +#line 12195 "preproc.y" + { + (yyval.str) = mm_strdup("full"); +;} + break; + + case 2165: + +/* Line 1455 of yacc.c */ +#line 12199 "preproc.y" + { + (yyval.str) = mm_strdup("ilike"); +;} + break; + + case 2166: + +/* Line 1455 of yacc.c */ +#line 12203 "preproc.y" + { + (yyval.str) = mm_strdup("inner"); +;} + break; + + case 2167: + +/* Line 1455 of yacc.c */ +#line 12207 "preproc.y" + { + (yyval.str) = mm_strdup("is"); +;} + break; + + case 2168: + +/* Line 1455 of yacc.c */ +#line 12211 "preproc.y" + { + (yyval.str) = mm_strdup("isnull"); +;} + break; + + case 2169: + +/* Line 1455 of yacc.c */ +#line 12215 "preproc.y" + { + (yyval.str) = mm_strdup("join"); +;} + break; + + case 2170: + +/* Line 1455 of yacc.c */ +#line 12219 "preproc.y" + { + (yyval.str) = mm_strdup("left"); +;} + break; + + case 2171: + +/* Line 1455 of yacc.c */ +#line 12223 "preproc.y" + { + (yyval.str) = mm_strdup("like"); +;} + break; + + case 2172: + +/* Line 1455 of yacc.c */ +#line 12227 "preproc.y" + { + (yyval.str) = mm_strdup("natural"); +;} + break; + + case 2173: + +/* Line 1455 of yacc.c */ +#line 12231 "preproc.y" + { + (yyval.str) = mm_strdup("notnull"); +;} + break; + + case 2174: + +/* Line 1455 of yacc.c */ +#line 12235 "preproc.y" + { + (yyval.str) = mm_strdup("outer"); +;} + break; + + case 2175: + +/* Line 1455 of yacc.c */ +#line 12239 "preproc.y" + { + (yyval.str) = mm_strdup("over"); +;} + break; + + case 2176: + +/* Line 1455 of yacc.c */ +#line 12243 "preproc.y" + { + (yyval.str) = mm_strdup("overlaps"); +;} + break; + + case 2177: + +/* Line 1455 of yacc.c */ +#line 12247 "preproc.y" + { + (yyval.str) = mm_strdup("right"); +;} + break; + + case 2178: + +/* Line 1455 of yacc.c */ +#line 12251 "preproc.y" + { + (yyval.str) = mm_strdup("similar"); +;} + break; + + case 2179: + +/* Line 1455 of yacc.c */ +#line 12255 "preproc.y" + { + (yyval.str) = mm_strdup("verbose"); +;} + break; + + case 2180: + +/* Line 1455 of yacc.c */ +#line 12263 "preproc.y" + { + (yyval.str) = mm_strdup("all"); +;} + break; + + case 2181: + +/* Line 1455 of yacc.c */ +#line 12267 "preproc.y" + { + (yyval.str) = mm_strdup("analyse"); +;} + break; + + case 2182: + +/* Line 1455 of yacc.c */ +#line 12271 "preproc.y" + { + (yyval.str) = mm_strdup("analyze"); +;} + break; + + case 2183: + +/* Line 1455 of yacc.c */ +#line 12275 "preproc.y" + { + (yyval.str) = mm_strdup("and"); +;} + break; + + case 2184: + +/* Line 1455 of yacc.c */ +#line 12279 "preproc.y" + { + (yyval.str) = mm_strdup("any"); +;} + break; + + case 2185: + +/* Line 1455 of yacc.c */ +#line 12283 "preproc.y" + { + (yyval.str) = mm_strdup("array"); +;} + break; + + case 2186: + +/* Line 1455 of yacc.c */ +#line 12287 "preproc.y" + { + (yyval.str) = mm_strdup("as"); +;} + break; + + case 2187: + +/* Line 1455 of yacc.c */ +#line 12291 "preproc.y" + { + (yyval.str) = mm_strdup("asc"); +;} + break; + + case 2188: + +/* Line 1455 of yacc.c */ +#line 12295 "preproc.y" + { + (yyval.str) = mm_strdup("asymmetric"); +;} + break; + + case 2189: + +/* Line 1455 of yacc.c */ +#line 12299 "preproc.y" + { + (yyval.str) = mm_strdup("both"); +;} + break; + + case 2190: + +/* Line 1455 of yacc.c */ +#line 12303 "preproc.y" + { + (yyval.str) = mm_strdup("case"); +;} + break; + + case 2191: + +/* Line 1455 of yacc.c */ +#line 12307 "preproc.y" + { + (yyval.str) = mm_strdup("cast"); +;} + break; + + case 2192: + +/* Line 1455 of yacc.c */ +#line 12311 "preproc.y" + { + (yyval.str) = mm_strdup("check"); +;} + break; + + case 2193: + +/* Line 1455 of yacc.c */ +#line 12315 "preproc.y" + { + (yyval.str) = mm_strdup("collate"); +;} + break; + + case 2194: + +/* Line 1455 of yacc.c */ +#line 12319 "preproc.y" + { + (yyval.str) = mm_strdup("column"); +;} + break; + + case 2195: + +/* Line 1455 of yacc.c */ +#line 12323 "preproc.y" + { + (yyval.str) = mm_strdup("constraint"); +;} + break; + + case 2196: + +/* Line 1455 of yacc.c */ +#line 12327 "preproc.y" + { + (yyval.str) = mm_strdup("create"); +;} + break; + + case 2197: + +/* Line 1455 of yacc.c */ +#line 12331 "preproc.y" + { + (yyval.str) = mm_strdup("current_catalog"); +;} + break; + + case 2198: + +/* Line 1455 of yacc.c */ +#line 12335 "preproc.y" + { + (yyval.str) = mm_strdup("current_date"); +;} + break; + + case 2199: + +/* Line 1455 of yacc.c */ +#line 12339 "preproc.y" + { + (yyval.str) = mm_strdup("current_role"); +;} + break; + + case 2200: + +/* Line 1455 of yacc.c */ +#line 12343 "preproc.y" + { + (yyval.str) = mm_strdup("current_time"); +;} + break; + + case 2201: + +/* Line 1455 of yacc.c */ +#line 12347 "preproc.y" + { + (yyval.str) = mm_strdup("current_timestamp"); +;} + break; + + case 2202: + +/* Line 1455 of yacc.c */ +#line 12351 "preproc.y" + { + (yyval.str) = mm_strdup("current_user"); +;} + break; + + case 2203: + +/* Line 1455 of yacc.c */ +#line 12355 "preproc.y" + { + (yyval.str) = mm_strdup("default"); +;} + break; + + case 2204: + +/* Line 1455 of yacc.c */ +#line 12359 "preproc.y" + { + (yyval.str) = mm_strdup("deferrable"); +;} + break; + + case 2205: + +/* Line 1455 of yacc.c */ +#line 12363 "preproc.y" + { + (yyval.str) = mm_strdup("desc"); +;} + break; + + case 2206: + +/* Line 1455 of yacc.c */ +#line 12367 "preproc.y" + { + (yyval.str) = mm_strdup("distinct"); +;} + break; + + case 2207: + +/* Line 1455 of yacc.c */ +#line 12371 "preproc.y" + { + (yyval.str) = mm_strdup("do"); +;} + break; + + case 2208: + +/* Line 1455 of yacc.c */ +#line 12375 "preproc.y" + { + (yyval.str) = mm_strdup("else"); +;} + break; + + case 2209: + +/* Line 1455 of yacc.c */ +#line 12379 "preproc.y" + { + (yyval.str) = mm_strdup("end"); +;} + break; + + case 2210: + +/* Line 1455 of yacc.c */ +#line 12383 "preproc.y" + { + (yyval.str) = mm_strdup("except"); +;} + break; + + case 2211: + +/* Line 1455 of yacc.c */ +#line 12387 "preproc.y" + { + (yyval.str) = mm_strdup("false"); +;} + break; + + case 2212: + +/* Line 1455 of yacc.c */ +#line 12391 "preproc.y" + { + (yyval.str) = mm_strdup("fetch"); +;} + break; + + case 2213: + +/* Line 1455 of yacc.c */ +#line 12395 "preproc.y" + { + (yyval.str) = mm_strdup("for"); +;} + break; + + case 2214: + +/* Line 1455 of yacc.c */ +#line 12399 "preproc.y" + { + (yyval.str) = mm_strdup("foreign"); +;} + break; + + case 2215: + +/* Line 1455 of yacc.c */ +#line 12403 "preproc.y" + { + (yyval.str) = mm_strdup("from"); +;} + break; + + case 2216: + +/* Line 1455 of yacc.c */ +#line 12407 "preproc.y" + { + (yyval.str) = mm_strdup("grant"); +;} + break; + + case 2217: + +/* Line 1455 of yacc.c */ +#line 12411 "preproc.y" + { + (yyval.str) = mm_strdup("group"); +;} + break; + + case 2218: + +/* Line 1455 of yacc.c */ +#line 12415 "preproc.y" + { + (yyval.str) = mm_strdup("having"); +;} + break; + + case 2219: + +/* Line 1455 of yacc.c */ +#line 12419 "preproc.y" + { + (yyval.str) = mm_strdup("in"); +;} + break; + + case 2220: + +/* Line 1455 of yacc.c */ +#line 12423 "preproc.y" + { + (yyval.str) = mm_strdup("initially"); +;} + break; + + case 2221: + +/* Line 1455 of yacc.c */ +#line 12427 "preproc.y" + { + (yyval.str) = mm_strdup("intersect"); +;} + break; + + case 2222: + +/* Line 1455 of yacc.c */ +#line 12431 "preproc.y" + { + (yyval.str) = mm_strdup("into"); +;} + break; + + case 2223: + +/* Line 1455 of yacc.c */ +#line 12435 "preproc.y" + { + (yyval.str) = mm_strdup("leading"); +;} + break; + + case 2224: + +/* Line 1455 of yacc.c */ +#line 12439 "preproc.y" + { + (yyval.str) = mm_strdup("limit"); +;} + break; + + case 2225: + +/* Line 1455 of yacc.c */ +#line 12443 "preproc.y" + { + (yyval.str) = mm_strdup("localtime"); +;} + break; + + case 2226: + +/* Line 1455 of yacc.c */ +#line 12447 "preproc.y" + { + (yyval.str) = mm_strdup("localtimestamp"); +;} + break; + + case 2227: + +/* Line 1455 of yacc.c */ +#line 12451 "preproc.y" + { + (yyval.str) = mm_strdup("not"); +;} + break; + + case 2228: + +/* Line 1455 of yacc.c */ +#line 12455 "preproc.y" + { + (yyval.str) = mm_strdup("null"); +;} + break; + + case 2229: + +/* Line 1455 of yacc.c */ +#line 12459 "preproc.y" + { + (yyval.str) = mm_strdup("offset"); +;} + break; + + case 2230: + +/* Line 1455 of yacc.c */ +#line 12463 "preproc.y" + { + (yyval.str) = mm_strdup("on"); +;} + break; + + case 2231: + +/* Line 1455 of yacc.c */ +#line 12467 "preproc.y" + { + (yyval.str) = mm_strdup("only"); +;} + break; + + case 2232: + +/* Line 1455 of yacc.c */ +#line 12471 "preproc.y" + { + (yyval.str) = mm_strdup("or"); +;} + break; + + case 2233: + +/* Line 1455 of yacc.c */ +#line 12475 "preproc.y" + { + (yyval.str) = mm_strdup("order"); +;} + break; + + case 2234: + +/* Line 1455 of yacc.c */ +#line 12479 "preproc.y" + { + (yyval.str) = mm_strdup("placing"); +;} + break; + + case 2235: + +/* Line 1455 of yacc.c */ +#line 12483 "preproc.y" + { + (yyval.str) = mm_strdup("primary"); +;} + break; + + case 2236: + +/* Line 1455 of yacc.c */ +#line 12487 "preproc.y" + { + (yyval.str) = mm_strdup("references"); +;} + break; + + case 2237: + +/* Line 1455 of yacc.c */ +#line 12491 "preproc.y" + { + (yyval.str) = mm_strdup("returning"); +;} + break; + + case 2238: + +/* Line 1455 of yacc.c */ +#line 12495 "preproc.y" + { + (yyval.str) = mm_strdup("select"); +;} + break; + + case 2239: + +/* Line 1455 of yacc.c */ +#line 12499 "preproc.y" + { + (yyval.str) = mm_strdup("session_user"); +;} + break; + + case 2240: + +/* Line 1455 of yacc.c */ +#line 12503 "preproc.y" + { + (yyval.str) = mm_strdup("some"); +;} + break; + + case 2241: + +/* Line 1455 of yacc.c */ +#line 12507 "preproc.y" + { + (yyval.str) = mm_strdup("symmetric"); +;} + break; + + case 2242: + +/* Line 1455 of yacc.c */ +#line 12511 "preproc.y" + { + (yyval.str) = mm_strdup("table"); +;} + break; + + case 2243: + +/* Line 1455 of yacc.c */ +#line 12515 "preproc.y" + { + (yyval.str) = mm_strdup("then"); +;} + break; + + case 2244: + +/* Line 1455 of yacc.c */ +#line 12519 "preproc.y" + { + (yyval.str) = mm_strdup("trailing"); +;} + break; + + case 2245: + +/* Line 1455 of yacc.c */ +#line 12523 "preproc.y" + { + (yyval.str) = mm_strdup("true"); +;} + break; + + case 2246: + +/* Line 1455 of yacc.c */ +#line 12527 "preproc.y" + { + (yyval.str) = mm_strdup("unique"); +;} + break; + + case 2247: + +/* Line 1455 of yacc.c */ +#line 12531 "preproc.y" + { + (yyval.str) = mm_strdup("user"); +;} + break; + + case 2248: + +/* Line 1455 of yacc.c */ +#line 12535 "preproc.y" + { + (yyval.str) = mm_strdup("using"); +;} + break; + + case 2249: + +/* Line 1455 of yacc.c */ +#line 12539 "preproc.y" + { + (yyval.str) = mm_strdup("variadic"); +;} + break; + + case 2250: + +/* Line 1455 of yacc.c */ +#line 12543 "preproc.y" + { + (yyval.str) = mm_strdup("when"); +;} + break; + + case 2251: + +/* Line 1455 of yacc.c */ +#line 12547 "preproc.y" + { + (yyval.str) = mm_strdup("where"); +;} + break; + + case 2252: + +/* Line 1455 of yacc.c */ +#line 12551 "preproc.y" + { + (yyval.str) = mm_strdup("window"); +;} + break; + + case 2253: + +/* Line 1455 of yacc.c */ +#line 12555 "preproc.y" + { + (yyval.str) = mm_strdup("with"); +;} + break; + + case 2256: + +/* Line 1455 of yacc.c */ +#line 12568 "preproc.y" + { connection = NULL; ;} + break; + + case 2258: + +/* Line 1455 of yacc.c */ +#line 12571 "preproc.y" + { + fprintf(yyout, "%s", (yyvsp[(2) - (2)].str)); + free((yyvsp[(2) - (2)].str)); + output_line_number(); + ;} + break; + + case 2260: + +/* Line 1455 of yacc.c */ +#line 12577 "preproc.y" + { fprintf(yyout, "%s", (yyvsp[(1) - (1)].str)); free((yyvsp[(1) - (1)].str)); ;} + break; + + case 2261: + +/* Line 1455 of yacc.c */ +#line 12578 "preproc.y" + { fprintf(yyout, "%s", (yyvsp[(1) - (1)].str)); free((yyvsp[(1) - (1)].str)); ;} + break; + + case 2262: + +/* Line 1455 of yacc.c */ +#line 12579 "preproc.y" + { braces_open++; fputs("{", yyout); ;} + break; + + case 2263: + +/* Line 1455 of yacc.c */ +#line 12581 "preproc.y" + { + remove_typedefs(braces_open); + remove_variables(braces_open--); + if (braces_open == 0) + { + free(current_function); + current_function = NULL; + } + fputs("}", yyout); + ;} + break; + + case 2264: + +/* Line 1455 of yacc.c */ +#line 12593 "preproc.y" + {FoundInto = 0;;} + break; + + case 2265: + +/* Line 1455 of yacc.c */ +#line 12594 "preproc.y" + { + if (FoundInto == 1) + mmerror(PARSE_ERROR, ET_ERROR, "CREATE TABLE AS cannot specify INTO"); + + (yyval.str) = cat_str(6, mm_strdup("create"), (yyvsp[(2) - (8)].str), mm_strdup("table"), (yyvsp[(4) - (8)].str), mm_strdup("as"), (yyvsp[(7) - (8)].str)); + ;} + break; + + case 2266: + +/* Line 1455 of yacc.c */ +#line 12603 "preproc.y" + { + connection = (yyvsp[(2) - (2)].str); + /* + * Do we have a variable as connection target? Remove the variable + * from the variable list or else it will be used twice. + */ + if (argsinsert != NULL) + argsinsert = NULL; + ;} + break; + + case 2267: + +/* Line 1455 of yacc.c */ +#line 12618 "preproc.y" + { (yyval.str) = cat_str(5, (yyvsp[(3) - (5)].str), mm_strdup(","), (yyvsp[(5) - (5)].str), mm_strdup(","), (yyvsp[(4) - (5)].str)); ;} + break; + + case 2268: + +/* Line 1455 of yacc.c */ +#line 12620 "preproc.y" + { (yyval.str) = mm_strdup("NULL, NULL, NULL, \"DEFAULT\""); ;} + break; + + case 2269: + +/* Line 1455 of yacc.c */ +#line 12623 "preproc.y" + { (yyval.str) = cat_str(3, mm_strdup("NULL,"), (yyvsp[(2) - (2)].str), mm_strdup(", NULL")); ;} + break; + + case 2270: + +/* Line 1455 of yacc.c */ +#line 12625 "preproc.y" + { (yyval.str) = cat2_str((yyvsp[(2) - (2)].str), mm_strdup(", NULL, NULL, NULL")); ;} + break; + + case 2271: + +/* Line 1455 of yacc.c */ +#line 12629 "preproc.y" + { + /* old style: dbname[@server][:port] */ + if (strlen((yyvsp[(2) - (3)].str)) > 0 && *((yyvsp[(2) - (3)].str)) != '@') + mmerror(PARSE_ERROR, ET_ERROR, "expected \"@\", found \"%s\"", (yyvsp[(2) - (3)].str)); + + /* C strings need to be handled differently */ + if ((yyvsp[(1) - (3)].str)[0] == '\"') + (yyval.str) = (yyvsp[(1) - (3)].str); + else + (yyval.str) = make3_str(mm_strdup("\""), make3_str((yyvsp[(1) - (3)].str), (yyvsp[(2) - (3)].str), (yyvsp[(3) - (3)].str)), mm_strdup("\"")); + ;} + break; + + case 2272: + +/* Line 1455 of yacc.c */ +#line 12641 "preproc.y" + { + /* new style: :postgresql://server[:port][/dbname] */ + if (strncmp((yyvsp[(1) - (7)].str), "unix:postgresql", strlen("unix:postgresql")) != 0 && strncmp((yyvsp[(1) - (7)].str), "tcp:postgresql", strlen("tcp:postgresql")) != 0) + mmerror(PARSE_ERROR, ET_ERROR, "only protocols \"tcp\" and \"unix\" and database type \"postgresql\" are supported"); + + if (strncmp((yyvsp[(3) - (7)].str), "//", strlen("//")) != 0) + mmerror(PARSE_ERROR, ET_ERROR, "expected \"://\", found \"%s\"", (yyvsp[(3) - (7)].str)); + + if (strncmp((yyvsp[(1) - (7)].str), "unix", strlen("unix")) == 0 && + strncmp((yyvsp[(3) - (7)].str) + strlen("//"), "localhost", strlen("localhost")) != 0 && + strncmp((yyvsp[(3) - (7)].str) + strlen("//"), "127.0.0.1", strlen("127.0.0.1")) != 0) + mmerror(PARSE_ERROR, ET_ERROR, "Unix-domain sockets only work on \"localhost\" but not on \"%s\"", (yyvsp[(3) - (7)].str) + strlen("//")); + + (yyval.str) = make3_str(make3_str(mm_strdup("\""), (yyvsp[(1) - (7)].str), mm_strdup(":")), (yyvsp[(3) - (7)].str), make3_str(make3_str((yyvsp[(4) - (7)].str), mm_strdup("/"), (yyvsp[(6) - (7)].str)), (yyvsp[(7) - (7)].str), mm_strdup("\""))); + ;} + break; + + case 2273: + +/* Line 1455 of yacc.c */ +#line 12657 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); + ;} + break; + + case 2274: + +/* Line 1455 of yacc.c */ +#line 12661 "preproc.y" + { + /* We can only process double quoted strings not single quotes ones, + * so we change the quotes. + * Note, that the rule for ecpg_sconst adds these single quotes. */ + (yyvsp[(1) - (1)].str)[0] = '\"'; + (yyvsp[(1) - (1)].str)[strlen((yyvsp[(1) - (1)].str))-1] = '\"'; + (yyval.str) = (yyvsp[(1) - (1)].str); + ;} + break; + + case 2275: + +/* Line 1455 of yacc.c */ +#line 12671 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2276: + +/* Line 1455 of yacc.c */ +#line 12672 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 2277: + +/* Line 1455 of yacc.c */ +#line 12676 "preproc.y" + { + if (strcmp((yyvsp[(2) - (2)].str), "postgresql") != 0 && strcmp((yyvsp[(2) - (2)].str), "postgres") != 0) + mmerror(PARSE_ERROR, ET_ERROR, "expected \"postgresql\", found \"%s\"", (yyvsp[(2) - (2)].str)); + + if (strcmp((yyvsp[(1) - (2)].str), "tcp") != 0 && strcmp((yyvsp[(1) - (2)].str), "unix") != 0) + mmerror(PARSE_ERROR, ET_ERROR, "invalid connection type: %s", (yyvsp[(1) - (2)].str)); + + (yyval.str) = make3_str((yyvsp[(1) - (2)].str), mm_strdup(":"), (yyvsp[(2) - (2)].str)); + ;} + break; + + case 2278: + +/* Line 1455 of yacc.c */ +#line 12688 "preproc.y" + { + if (strcmp((yyvsp[(1) - (2)].str), "@") != 0 && strcmp((yyvsp[(1) - (2)].str), "//") != 0) + mmerror(PARSE_ERROR, ET_ERROR, "expected \"@\" or \"://\", found \"%s\"", (yyvsp[(1) - (2)].str)); + + (yyval.str) = make2_str((yyvsp[(1) - (2)].str), (yyvsp[(2) - (2)].str)); + ;} + break; + + case 2279: + +/* Line 1455 of yacc.c */ +#line 12696 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2280: + +/* Line 1455 of yacc.c */ +#line 12697 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 2281: + +/* Line 1455 of yacc.c */ +#line 12700 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2282: + +/* Line 1455 of yacc.c */ +#line 12701 "preproc.y" + { (yyval.str) = make3_str((yyvsp[(1) - (3)].str), mm_strdup("."), (yyvsp[(3) - (3)].str)); ;} + break; + + case 2283: + +/* Line 1455 of yacc.c */ +#line 12702 "preproc.y" + { (yyval.str) = make_name(); ;} + break; + + case 2284: + +/* Line 1455 of yacc.c */ +#line 12705 "preproc.y" + { (yyval.str) = make2_str(mm_strdup(":"), (yyvsp[(2) - (2)].str)); ;} + break; + + case 2285: + +/* Line 1455 of yacc.c */ +#line 12706 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 2286: + +/* Line 1455 of yacc.c */ +#line 12709 "preproc.y" + { (yyval.str) = (yyvsp[(2) - (2)].str); ;} + break; + + case 2287: + +/* Line 1455 of yacc.c */ +#line 12710 "preproc.y" + { (yyval.str) = mm_strdup("NULL"); ;} + break; + + case 2288: + +/* Line 1455 of yacc.c */ +#line 12713 "preproc.y" + { (yyval.str) = (yyvsp[(2) - (2)].str); ;} + break; + + case 2289: + +/* Line 1455 of yacc.c */ +#line 12714 "preproc.y" + { (yyval.str) = mm_strdup("NULL, NULL"); ;} + break; + + case 2290: + +/* Line 1455 of yacc.c */ +#line 12718 "preproc.y" + { (yyval.str) = cat2_str((yyvsp[(1) - (1)].str), mm_strdup(", NULL")); ;} + break; + + case 2291: + +/* Line 1455 of yacc.c */ +#line 12720 "preproc.y" + { (yyval.str) = cat_str(3, (yyvsp[(1) - (3)].str), mm_strdup(","), (yyvsp[(3) - (3)].str)); ;} + break; + + case 2292: + +/* Line 1455 of yacc.c */ +#line 12722 "preproc.y" + { (yyval.str) = cat_str(3, (yyvsp[(1) - (4)].str), mm_strdup(","), (yyvsp[(4) - (4)].str)); ;} + break; + + case 2293: + +/* Line 1455 of yacc.c */ +#line 12724 "preproc.y" + { (yyval.str) = cat_str(3, (yyvsp[(1) - (3)].str), mm_strdup(","), (yyvsp[(3) - (3)].str)); ;} + break; + + case 2294: + +/* Line 1455 of yacc.c */ +#line 12728 "preproc.y" + { + if ((yyvsp[(1) - (1)].str)[0] == '\"') + (yyval.str) = (yyvsp[(1) - (1)].str); + else + (yyval.str) = make3_str(mm_strdup("\""), (yyvsp[(1) - (1)].str), mm_strdup("\"")); + ;} + break; + + case 2295: + +/* Line 1455 of yacc.c */ +#line 12735 "preproc.y" + { + if ((yyvsp[(1) - (1)].str)[0] == '\"') + (yyval.str) = (yyvsp[(1) - (1)].str); + else + (yyval.str) = make3_str(mm_strdup("\""), (yyvsp[(1) - (1)].str), mm_strdup("\"")); + ;} + break; + + case 2296: + +/* Line 1455 of yacc.c */ +#line 12742 "preproc.y" + { + enum ECPGttype type = argsinsert->variable->type->type; + + /* if array see what's inside */ + if (type == ECPGt_array) + type = argsinsert->variable->type->u.element->type; + + /* handle varchars */ + if (type == ECPGt_varchar) + (yyval.str) = make2_str(mm_strdup(argsinsert->variable->name), mm_strdup(".arr")); + else + (yyval.str) = mm_strdup(argsinsert->variable->name); + ;} + break; + + case 2297: + +/* Line 1455 of yacc.c */ +#line 12758 "preproc.y" + { + /* check if we have a string variable */ + struct variable *p = find_variable((yyvsp[(1) - (1)].str)); + enum ECPGttype type = p->type->type; + + /* If we have just one character this is not a string */ + if (atol(p->type->size) == 1) + mmerror(PARSE_ERROR, ET_ERROR, "invalid data type"); + else + { + /* if array see what's inside */ + if (type == ECPGt_array) + type = p->type->u.element->type; + + switch (type) + { + case ECPGt_char: + case ECPGt_unsigned_char: + case ECPGt_string: + (yyval.str) = (yyvsp[(1) - (1)].str); + break; + case ECPGt_varchar: + (yyval.str) = make2_str((yyvsp[(1) - (1)].str), mm_strdup(".arr")); + break; + default: + mmerror(PARSE_ERROR, ET_ERROR, "invalid data type"); + (yyval.str) = (yyvsp[(1) - (1)].str); + break; + } + } + ;} + break; + + case 2298: + +/* Line 1455 of yacc.c */ +#line 12792 "preproc.y" + { + if (strlen((yyvsp[(1) - (2)].str)) == 0) + mmerror(PARSE_ERROR, ET_ERROR, "incomplete statement"); + + if (strcmp((yyvsp[(1) - (2)].str), "?") != 0) + mmerror(PARSE_ERROR, ET_ERROR, "unrecognized token \"%s\"", (yyvsp[(1) - (2)].str)); + + (yyval.str) = make2_str(mm_strdup("?"), (yyvsp[(2) - (2)].str)); + ;} + break; + + case 2299: + +/* Line 1455 of yacc.c */ +#line 12801 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 2300: + +/* Line 1455 of yacc.c */ +#line 12805 "preproc.y" + { + (yyval.str) = make2_str((yyvsp[(1) - (2)].str), (yyvsp[(2) - (2)].str)); + ;} + break; + + case 2301: + +/* Line 1455 of yacc.c */ +#line 12809 "preproc.y" + { + if (strlen((yyvsp[(3) - (4)].str)) == 0) + mmerror(PARSE_ERROR, ET_ERROR, "incomplete statement"); + + if (strcmp((yyvsp[(3) - (4)].str), "&") != 0) + mmerror(PARSE_ERROR, ET_ERROR, "unrecognized token \"%s\"", (yyvsp[(3) - (4)].str)); + + (yyval.str) = cat_str(3, make2_str((yyvsp[(1) - (4)].str), (yyvsp[(2) - (4)].str)), (yyvsp[(3) - (4)].str), (yyvsp[(4) - (4)].str)); + ;} + break; + + case 2302: + +/* Line 1455 of yacc.c */ +#line 12821 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 2303: + +/* Line 1455 of yacc.c */ +#line 12823 "preproc.y" + { (yyval.str) = make2_str(mm_strdup("="), (yyvsp[(2) - (2)].str)); ;} + break; + + case 2304: + +/* Line 1455 of yacc.c */ +#line 12825 "preproc.y" + { (yyval.str) = make2_str(mm_strdup("="), (yyvsp[(2) - (2)].str)); ;} + break; + + case 2305: + +/* Line 1455 of yacc.c */ +#line 12827 "preproc.y" + { (yyval.str) = make2_str(mm_strdup("="), (yyvsp[(2) - (2)].str)); ;} + break; + + case 2306: + +/* Line 1455 of yacc.c */ +#line 12831 "preproc.y" + { + if ((yyvsp[(1) - (1)].str)[0] == '\"' && (yyvsp[(1) - (1)].str)[strlen((yyvsp[(1) - (1)].str))-1] == '\"') /* already quoted? */ + (yyval.str) = (yyvsp[(1) - (1)].str); + else /* not quoted => convert to lowercase */ + { + size_t i; + + for (i = 0; i< strlen((yyvsp[(1) - (1)].str)); i++) + (yyvsp[(1) - (1)].str)[i] = tolower((unsigned char) (yyvsp[(1) - (1)].str)[i]); + + (yyval.str) = make3_str(mm_strdup("\""), (yyvsp[(1) - (1)].str), mm_strdup("\"")); + } + ;} + break; + + case 2307: + +/* Line 1455 of yacc.c */ +#line 12844 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2308: + +/* Line 1455 of yacc.c */ +#line 12852 "preproc.y" + { + struct cursor *ptr, *this; + char *cursor_marker = (yyvsp[(2) - (7)].str)[0] == ':' ? mm_strdup("$0") : mm_strdup((yyvsp[(2) - (7)].str)); + int (* strcmp_fn)(const char *, const char *) = ((yyvsp[(2) - (7)].str)[0] == ':' ? strcmp : pg_strcasecmp); + struct variable *thisquery = (struct variable *)mm_alloc(sizeof(struct variable)); + const char *con = connection ? connection : "NULL"; + char *comment; + + for (ptr = cur; ptr != NULL; ptr = ptr->next) + { + if (strcmp_fn((yyvsp[(2) - (7)].str), ptr->name) == 0) + { + /* re-definition is a bug */ + if ((yyvsp[(2) - (7)].str)[0] == ':') + mmerror(PARSE_ERROR, ET_ERROR, "using variable \"%s\" in different declare statements is not supported", (yyvsp[(2) - (7)].str)+1); + else + mmerror(PARSE_ERROR, ET_ERROR, "cursor \"%s\" is already defined", (yyvsp[(2) - (7)].str)); + } + } + + this = (struct cursor *) mm_alloc(sizeof(struct cursor)); + + /* initial definition */ + this->next = cur; + this->name = (yyvsp[(2) - (7)].str); + this->function = (current_function ? mm_strdup(current_function) : NULL); + this->connection = connection; + this->command = cat_str(6, mm_strdup("declare"), cursor_marker, (yyvsp[(3) - (7)].str), mm_strdup("cursor"), (yyvsp[(5) - (7)].str), mm_strdup("for $1")); + this->argsresult = NULL; + this->argsresult_oos = NULL; + + thisquery->type = &ecpg_query; + thisquery->brace_level = 0; + thisquery->next = NULL; + thisquery->name = (char *) mm_alloc(sizeof("ECPGprepared_statement(, , __LINE__)") + strlen(con) + strlen((yyvsp[(7) - (7)].str))); + sprintf(thisquery->name, "ECPGprepared_statement(%s, %s, __LINE__)", con, (yyvsp[(7) - (7)].str)); + + this->argsinsert = NULL; + this->argsinsert_oos = NULL; + if ((yyvsp[(2) - (7)].str)[0] == ':') + { + struct variable *var = find_variable((yyvsp[(2) - (7)].str) + 1); + remove_variable_from_list(&argsinsert, var); + add_variable_to_head(&(this->argsinsert), var, &no_indicator); + } + add_variable_to_head(&(this->argsinsert), thisquery, &no_indicator); + + cur = this; + + comment = cat_str(3, mm_strdup("/*"), mm_strdup(this->command), mm_strdup("*/")); + + if ((braces_open > 0) && INFORMIX_MODE) /* we're in a function */ + (yyval.str) = cat_str(3, adjust_outofscope_cursor_vars(this), + mm_strdup("ECPG_informix_reset_sqlca();"), + comment); + else + (yyval.str) = cat2_str(adjust_outofscope_cursor_vars(this), comment); + ;} + break; + + case 2309: + +/* Line 1455 of yacc.c */ +#line 12913 "preproc.y" + { + /* execute immediate means prepare the statement and + * immediately execute it */ + (yyval.str) = (yyvsp[(3) - (3)].str); + ;} + break; + + case 2311: + +/* Line 1455 of yacc.c */ +#line 12923 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2312: + +/* Line 1455 of yacc.c */ +#line 12924 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2313: + +/* Line 1455 of yacc.c */ +#line 12927 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2314: + +/* Line 1455 of yacc.c */ +#line 12929 "preproc.y" + { (yyval.str) = (yyvsp[(2) - (2)].str); ;} + break; + + case 2315: + +/* Line 1455 of yacc.c */ +#line 12930 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 2316: + +/* Line 1455 of yacc.c */ +#line 12933 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2317: + +/* Line 1455 of yacc.c */ +#line 12934 "preproc.y" + { (yyval.str) = mm_strdup("year to minute"); ;} + break; + + case 2318: + +/* Line 1455 of yacc.c */ +#line 12935 "preproc.y" + { (yyval.str) = mm_strdup("year to second"); ;} + break; + + case 2319: + +/* Line 1455 of yacc.c */ +#line 12936 "preproc.y" + { (yyval.str) = mm_strdup("day to day"); ;} + break; + + case 2320: + +/* Line 1455 of yacc.c */ +#line 12937 "preproc.y" + { (yyval.str) = mm_strdup("month to month"); ;} + break; + + case 2321: + +/* Line 1455 of yacc.c */ +#line 12944 "preproc.y" + { fputs("/* exec sql begin declare section */", yyout); ;} + break; + + case 2322: + +/* Line 1455 of yacc.c */ +#line 12946 "preproc.y" + { + fprintf(yyout, "%s/* exec sql end declare section */", (yyvsp[(3) - (4)].str)); + free((yyvsp[(3) - (4)].str)); + output_line_number(); + ;} + break; + + case 2323: + +/* Line 1455 of yacc.c */ +#line 12953 "preproc.y" + {;} + break; + + case 2324: + +/* Line 1455 of yacc.c */ +#line 12955 "preproc.y" + {;} + break; + + case 2325: + +/* Line 1455 of yacc.c */ +#line 12957 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 2326: + +/* Line 1455 of yacc.c */ +#line 12958 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2327: + +/* Line 1455 of yacc.c */ +#line 12961 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2328: + +/* Line 1455 of yacc.c */ +#line 12962 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2329: + +/* Line 1455 of yacc.c */ +#line 12963 "preproc.y" + { (yyval.str) = cat2_str((yyvsp[(1) - (2)].str), (yyvsp[(2) - (2)].str)); ;} + break; + + case 2330: + +/* Line 1455 of yacc.c */ +#line 12964 "preproc.y" + { (yyval.str) = cat2_str((yyvsp[(1) - (2)].str), (yyvsp[(2) - (2)].str)); ;} + break; + + case 2331: + +/* Line 1455 of yacc.c */ +#line 12967 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2332: + +/* Line 1455 of yacc.c */ +#line 12968 "preproc.y" + { (yyval.str) = cat2_str((yyvsp[(1) - (2)].str), (yyvsp[(2) - (2)].str)); ;} + break; + + case 2333: + +/* Line 1455 of yacc.c */ +#line 12972 "preproc.y" + { + /* reset this variable so we see if there was */ + /* an initializer specified */ + initializer = 0; + ;} + break; + + case 2334: + +/* Line 1455 of yacc.c */ +#line 12978 "preproc.y" + { + add_typedef((yyvsp[(5) - (7)].str), (yyvsp[(6) - (7)].index).index1, (yyvsp[(6) - (7)].index).index2, (yyvsp[(3) - (7)].type).type_enum, (yyvsp[(3) - (7)].type).type_dimension, (yyvsp[(3) - (7)].type).type_index, initializer, *(yyvsp[(4) - (7)].str) ? 1 : 0); + + fprintf(yyout, "typedef %s %s %s %s;\n", (yyvsp[(3) - (7)].type).type_str, *(yyvsp[(4) - (7)].str) ? "*" : "", (yyvsp[(5) - (7)].str), (yyvsp[(6) - (7)].index).str); + output_line_number(); + (yyval.str) = mm_strdup(""); + ;} + break; + + case 2335: + +/* Line 1455 of yacc.c */ +#line 12988 "preproc.y" + { + actual_type[struct_level].type_enum = (yyvsp[(2) - (2)].type).type_enum; + actual_type[struct_level].type_str = (yyvsp[(2) - (2)].type).type_str; + actual_type[struct_level].type_dimension = (yyvsp[(2) - (2)].type).type_dimension; + actual_type[struct_level].type_index = (yyvsp[(2) - (2)].type).type_index; + actual_type[struct_level].type_sizeof = (yyvsp[(2) - (2)].type).type_sizeof; + + actual_startline[struct_level] = hashline_number(); + ;} + break; + + case 2336: + +/* Line 1455 of yacc.c */ +#line 12998 "preproc.y" + { + (yyval.str) = cat_str(5, actual_startline[struct_level], (yyvsp[(1) - (5)].str), (yyvsp[(2) - (5)].type).type_str, (yyvsp[(4) - (5)].str), mm_strdup(";\n")); + ;} + break; + + case 2337: + +/* Line 1455 of yacc.c */ +#line 13002 "preproc.y" + { + actual_type[struct_level].type_enum = (yyvsp[(1) - (1)].type).type_enum; + actual_type[struct_level].type_str = (yyvsp[(1) - (1)].type).type_str; + actual_type[struct_level].type_dimension = (yyvsp[(1) - (1)].type).type_dimension; + actual_type[struct_level].type_index = (yyvsp[(1) - (1)].type).type_index; + actual_type[struct_level].type_sizeof = (yyvsp[(1) - (1)].type).type_sizeof; + + actual_startline[struct_level] = hashline_number(); + ;} + break; + + case 2338: + +/* Line 1455 of yacc.c */ +#line 13012 "preproc.y" + { + (yyval.str) = cat_str(4, actual_startline[struct_level], (yyvsp[(1) - (4)].type).type_str, (yyvsp[(3) - (4)].str), mm_strdup(";\n")); + ;} + break; + + case 2339: + +/* Line 1455 of yacc.c */ +#line 13016 "preproc.y" + { + (yyval.str) = cat2_str((yyvsp[(1) - (2)].str), mm_strdup(";")); + ;} + break; + + case 2340: + +/* Line 1455 of yacc.c */ +#line 13021 "preproc.y" + { (yyval.str) =cat2_str(mm_strdup(":"), (yyvsp[(2) - (2)].str)); ;} + break; + + case 2341: + +/* Line 1455 of yacc.c */ +#line 13022 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 2342: + +/* Line 1455 of yacc.c */ +#line 13026 "preproc.y" + {(yyval.str) = cat2_str ((yyvsp[(1) - (2)].str), (yyvsp[(2) - (2)].str)); ;} + break; + + case 2343: + +/* Line 1455 of yacc.c */ +#line 13027 "preproc.y" + {(yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2344: + +/* Line 1455 of yacc.c */ +#line 13028 "preproc.y" + {(yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2345: + +/* Line 1455 of yacc.c */ +#line 13031 "preproc.y" + { (yyval.str) = mm_strdup("extern"); ;} + break; + + case 2346: + +/* Line 1455 of yacc.c */ +#line 13032 "preproc.y" + { (yyval.str) = mm_strdup("static"); ;} + break; + + case 2347: + +/* Line 1455 of yacc.c */ +#line 13033 "preproc.y" + { (yyval.str) = mm_strdup("register"); ;} + break; + + case 2348: + +/* Line 1455 of yacc.c */ +#line 13034 "preproc.y" + { (yyval.str) = mm_strdup("auto"); ;} + break; + + case 2349: + +/* Line 1455 of yacc.c */ +#line 13037 "preproc.y" + { (yyval.str) = mm_strdup("const"); ;} + break; + + case 2350: + +/* Line 1455 of yacc.c */ +#line 13038 "preproc.y" + { (yyval.str) = mm_strdup("volatile"); ;} + break; + + case 2351: + +/* Line 1455 of yacc.c */ +#line 13042 "preproc.y" + { + (yyval.type).type_enum = (yyvsp[(1) - (1)].type_enum); + (yyval.type).type_str = mm_strdup(ecpg_type_name((yyvsp[(1) - (1)].type_enum))); + (yyval.type).type_dimension = mm_strdup("-1"); + (yyval.type).type_index = mm_strdup("-1"); + (yyval.type).type_sizeof = NULL; + ;} + break; + + case 2352: + +/* Line 1455 of yacc.c */ +#line 13050 "preproc.y" + { + (yyval.type).type_str = (yyvsp[(1) - (1)].str); + (yyval.type).type_dimension = mm_strdup("-1"); + (yyval.type).type_index = mm_strdup("-1"); + + if (strncmp((yyvsp[(1) - (1)].str), "struct", sizeof("struct")-1) == 0) + { + (yyval.type).type_enum = ECPGt_struct; + (yyval.type).type_sizeof = ECPGstruct_sizeof; + } + else + { + (yyval.type).type_enum = ECPGt_union; + (yyval.type).type_sizeof = NULL; + } + ;} + break; + + case 2353: + +/* Line 1455 of yacc.c */ +#line 13067 "preproc.y" + { + (yyval.type).type_str = (yyvsp[(1) - (1)].str); + (yyval.type).type_enum = ECPGt_int; + (yyval.type).type_dimension = mm_strdup("-1"); + (yyval.type).type_index = mm_strdup("-1"); + (yyval.type).type_sizeof = NULL; + ;} + break; + + case 2354: + +/* Line 1455 of yacc.c */ +#line 13075 "preproc.y" + { + if (strcmp((yyvsp[(1) - (5)].str), "numeric") == 0) + { + (yyval.type).type_enum = ECPGt_numeric; + (yyval.type).type_str = mm_strdup("numeric"); + } + else if (strcmp((yyvsp[(1) - (5)].str), "decimal") == 0) + { + (yyval.type).type_enum = ECPGt_decimal; + (yyval.type).type_str = mm_strdup("decimal"); + } + else + { + mmerror(PARSE_ERROR, ET_ERROR, "only data types numeric and decimal have precision/scale argument"); + (yyval.type).type_enum = ECPGt_numeric; + (yyval.type).type_str = mm_strdup("numeric"); + } + + (yyval.type).type_dimension = mm_strdup("-1"); + (yyval.type).type_index = mm_strdup("-1"); + (yyval.type).type_sizeof = NULL; + ;} + break; + + case 2355: + +/* Line 1455 of yacc.c */ +#line 13098 "preproc.y" + { + if (strlen((yyvsp[(2) - (2)].str)) != 0 && strcmp ((yyvsp[(1) - (2)].str), "datetime") != 0 && strcmp ((yyvsp[(1) - (2)].str), "interval") != 0) + mmerror (PARSE_ERROR, ET_ERROR, "interval specification not allowed here"); + + /* + * Check for type names that the SQL grammar treats as + * unreserved keywords + */ + if (strcmp((yyvsp[(1) - (2)].str), "varchar") == 0) + { + (yyval.type).type_enum = ECPGt_varchar; + (yyval.type).type_str = EMPTY; /*mm_strdup("varchar");*/ + (yyval.type).type_dimension = mm_strdup("-1"); + (yyval.type).type_index = mm_strdup("-1"); + (yyval.type).type_sizeof = NULL; + } + else if (strcmp((yyvsp[(1) - (2)].str), "float") == 0) + { + (yyval.type).type_enum = ECPGt_float; + (yyval.type).type_str = mm_strdup("float"); + (yyval.type).type_dimension = mm_strdup("-1"); + (yyval.type).type_index = mm_strdup("-1"); + (yyval.type).type_sizeof = NULL; + } + else if (strcmp((yyvsp[(1) - (2)].str), "double") == 0) + { + (yyval.type).type_enum = ECPGt_double; + (yyval.type).type_str = mm_strdup("double"); + (yyval.type).type_dimension = mm_strdup("-1"); + (yyval.type).type_index = mm_strdup("-1"); + (yyval.type).type_sizeof = NULL; + } + else if (strcmp((yyvsp[(1) - (2)].str), "numeric") == 0) + { + (yyval.type).type_enum = ECPGt_numeric; + (yyval.type).type_str = mm_strdup("numeric"); + (yyval.type).type_dimension = mm_strdup("-1"); + (yyval.type).type_index = mm_strdup("-1"); + (yyval.type).type_sizeof = NULL; + } + else if (strcmp((yyvsp[(1) - (2)].str), "decimal") == 0) + { + (yyval.type).type_enum = ECPGt_decimal; + (yyval.type).type_str = mm_strdup("decimal"); + (yyval.type).type_dimension = mm_strdup("-1"); + (yyval.type).type_index = mm_strdup("-1"); + (yyval.type).type_sizeof = NULL; + } + else if (strcmp((yyvsp[(1) - (2)].str), "date") == 0) + { + (yyval.type).type_enum = ECPGt_date; + (yyval.type).type_str = mm_strdup("date"); + (yyval.type).type_dimension = mm_strdup("-1"); + (yyval.type).type_index = mm_strdup("-1"); + (yyval.type).type_sizeof = NULL; + } + else if (strcmp((yyvsp[(1) - (2)].str), "timestamp") == 0) + { + (yyval.type).type_enum = ECPGt_timestamp; + (yyval.type).type_str = mm_strdup("timestamp"); + (yyval.type).type_dimension = mm_strdup("-1"); + (yyval.type).type_index = mm_strdup("-1"); + (yyval.type).type_sizeof = NULL; + } + else if (strcmp((yyvsp[(1) - (2)].str), "interval") == 0) + { + (yyval.type).type_enum = ECPGt_interval; + (yyval.type).type_str = mm_strdup("interval"); + (yyval.type).type_dimension = mm_strdup("-1"); + (yyval.type).type_index = mm_strdup("-1"); + (yyval.type).type_sizeof = NULL; + } + else if (strcmp((yyvsp[(1) - (2)].str), "datetime") == 0) + { + (yyval.type).type_enum = ECPGt_timestamp; + (yyval.type).type_str = mm_strdup("timestamp"); + (yyval.type).type_dimension = mm_strdup("-1"); + (yyval.type).type_index = mm_strdup("-1"); + (yyval.type).type_sizeof = NULL; + } + else if ((strcmp((yyvsp[(1) - (2)].str), "string") == 0) && INFORMIX_MODE) + { + (yyval.type).type_enum = ECPGt_string; + (yyval.type).type_str = mm_strdup("char"); + (yyval.type).type_dimension = mm_strdup("-1"); + (yyval.type).type_index = mm_strdup("-1"); + (yyval.type).type_sizeof = NULL; + } + else + { + /* this is for typedef'ed types */ + struct typedefs *this = get_typedef((yyvsp[(1) - (2)].str)); + + (yyval.type).type_str = (this->type->type_enum == ECPGt_varchar) ? EMPTY : mm_strdup(this->name); + (yyval.type).type_enum = this->type->type_enum; + (yyval.type).type_dimension = this->type->type_dimension; + (yyval.type).type_index = this->type->type_index; + if (this->type->type_sizeof && strlen(this->type->type_sizeof) != 0) + (yyval.type).type_sizeof = this->type->type_sizeof; + else + (yyval.type).type_sizeof = cat_str(3, mm_strdup("sizeof("), mm_strdup(this->name), mm_strdup(")")); + + struct_member_list[struct_level] = ECPGstruct_member_dup(this->struct_member_list); + } + ;} + break; + + case 2356: + +/* Line 1455 of yacc.c */ +#line 13204 "preproc.y" + { + /* this is for named structs/unions */ + char *name; + struct typedefs *this; + bool forward = (forward_name != NULL && strcmp((yyvsp[(1) - (1)].struct_union).symbol, forward_name) == 0 && strcmp((yyvsp[(1) - (1)].struct_union).su, "struct") == 0); + + name = cat2_str((yyvsp[(1) - (1)].struct_union).su, (yyvsp[(1) - (1)].struct_union).symbol); + /* Do we have a forward definition? */ + if (!forward) + { + /* No */ + + this = get_typedef(name); + (yyval.type).type_str = mm_strdup(this->name); + (yyval.type).type_enum = this->type->type_enum; + (yyval.type).type_dimension = this->type->type_dimension; + (yyval.type).type_index = this->type->type_index; + (yyval.type).type_sizeof = this->type->type_sizeof; + struct_member_list[struct_level] = ECPGstruct_member_dup(this->struct_member_list); + free(name); + } + else + { + (yyval.type).type_str = name; + (yyval.type).type_enum = ECPGt_long; + (yyval.type).type_dimension = mm_strdup("-1"); + (yyval.type).type_index = mm_strdup("-1"); + (yyval.type).type_sizeof = mm_strdup(""); + struct_member_list[struct_level] = NULL; + } + ;} + break; + + case 2357: + +/* Line 1455 of yacc.c */ +#line 13238 "preproc.y" + { (yyval.str) = cat_str(3, mm_strdup("enum"), (yyvsp[(2) - (3)].str), (yyvsp[(3) - (3)].str)); ;} + break; + + case 2358: + +/* Line 1455 of yacc.c */ +#line 13240 "preproc.y" + { (yyval.str) = cat2_str(mm_strdup("enum"), (yyvsp[(2) - (2)].str)); ;} + break; + + case 2359: + +/* Line 1455 of yacc.c */ +#line 13242 "preproc.y" + { (yyval.str) = cat2_str(mm_strdup("enum"), (yyvsp[(2) - (2)].str)); ;} + break; + + case 2360: + +/* Line 1455 of yacc.c */ +#line 13246 "preproc.y" + { (yyval.str) = cat_str(3, mm_strdup("{"), (yyvsp[(2) - (3)].str), mm_strdup("}")); ;} + break; + + case 2361: + +/* Line 1455 of yacc.c */ +#line 13249 "preproc.y" + { + struct_member_list[struct_level++] = NULL; + if (struct_level >= STRUCT_DEPTH) + mmerror(PARSE_ERROR, ET_ERROR, "too many levels in nested structure/union definition"); + forward_name = mm_strdup((yyvsp[(1) - (1)].struct_union).symbol); + ;} + break; + + case 2362: + +/* Line 1455 of yacc.c */ +#line 13256 "preproc.y" + { + struct typedefs *ptr, *this; + struct this_type su_type; + + ECPGfree_struct_member(struct_member_list[struct_level]); + struct_member_list[struct_level] = NULL; + struct_level--; + if (strncmp((yyvsp[(1) - (5)].struct_union).su, "struct", sizeof("struct")-1) == 0) + su_type.type_enum = ECPGt_struct; + else + su_type.type_enum = ECPGt_union; + su_type.type_str = cat2_str((yyvsp[(1) - (5)].struct_union).su, (yyvsp[(1) - (5)].struct_union).symbol); + free(forward_name); + forward_name = NULL; + + /* This is essantially a typedef but needs the keyword struct/union as well. + * So we create the typedef for each struct definition with symbol */ + for (ptr = types; ptr != NULL; ptr = ptr->next) + { + if (strcmp(su_type.type_str, ptr->name) == 0) + /* re-definition is a bug */ + mmerror(PARSE_ERROR, ET_ERROR, "type \"%s\" is already defined", su_type.type_str); + } + + this = (struct typedefs *) mm_alloc(sizeof(struct typedefs)); + + /* initial definition */ + this->next = types; + this->name = mm_strdup(su_type.type_str); + this->brace_level = braces_open; + this->type = (struct this_type *) mm_alloc(sizeof(struct this_type)); + this->type->type_enum = su_type.type_enum; + this->type->type_str = mm_strdup(su_type.type_str); + this->type->type_dimension = mm_strdup("-1"); /* dimension of array */ + this->type->type_index = mm_strdup("-1"); /* length of string */ + this->type->type_sizeof = ECPGstruct_sizeof; + this->struct_member_list = struct_member_list[struct_level]; + + types = this; + (yyval.str) = cat_str(4, su_type.type_str, mm_strdup("{"), (yyvsp[(4) - (5)].str), mm_strdup("}")); + ;} + break; + + case 2363: + +/* Line 1455 of yacc.c */ +#line 13299 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2364: + +/* Line 1455 of yacc.c */ +#line 13301 "preproc.y" + { + struct_member_list[struct_level++] = NULL; + if (struct_level >= STRUCT_DEPTH) + mmerror(PARSE_ERROR, ET_ERROR, "too many levels in nested structure/union definition"); + ;} + break; + + case 2365: + +/* Line 1455 of yacc.c */ +#line 13307 "preproc.y" + { + ECPGfree_struct_member(struct_member_list[struct_level]); + struct_member_list[struct_level] = NULL; + struct_level--; + (yyval.str) = cat_str(4, (yyvsp[(1) - (5)].str), mm_strdup("{"), (yyvsp[(4) - (5)].str), mm_strdup("}")); + ;} + break; + + case 2366: + +/* Line 1455 of yacc.c */ +#line 13316 "preproc.y" + { + (yyval.struct_union).su = mm_strdup("struct"); + (yyval.struct_union).symbol = (yyvsp[(2) - (2)].str); + ECPGstruct_sizeof = cat_str(3, mm_strdup("sizeof("), cat2_str(mm_strdup((yyval.struct_union).su), mm_strdup((yyval.struct_union).symbol)), mm_strdup(")")); + ;} + break; + + case 2367: + +/* Line 1455 of yacc.c */ +#line 13322 "preproc.y" + { + (yyval.struct_union).su = mm_strdup("union"); + (yyval.struct_union).symbol = (yyvsp[(2) - (2)].str); + ;} + break; + + case 2368: + +/* Line 1455 of yacc.c */ +#line 13329 "preproc.y" + { + ECPGstruct_sizeof = mm_strdup(""); /* This must not be NULL to distinguish from simple types. */ + (yyval.str) = mm_strdup("struct"); + ;} + break; + + case 2369: + +/* Line 1455 of yacc.c */ +#line 13334 "preproc.y" + { + (yyval.str) = mm_strdup("union"); + ;} + break; + + case 2370: + +/* Line 1455 of yacc.c */ +#line 13339 "preproc.y" + { (yyval.type_enum)=(yyvsp[(1) - (1)].type_enum); ;} + break; + + case 2371: + +/* Line 1455 of yacc.c */ +#line 13340 "preproc.y" + { (yyval.type_enum)=(yyvsp[(2) - (2)].type_enum); ;} + break; + + case 2372: + +/* Line 1455 of yacc.c */ +#line 13343 "preproc.y" + { (yyval.type_enum) = ECPGt_unsigned_short; ;} + break; + + case 2373: + +/* Line 1455 of yacc.c */ +#line 13344 "preproc.y" + { (yyval.type_enum) = ECPGt_unsigned_short; ;} + break; + + case 2374: + +/* Line 1455 of yacc.c */ +#line 13345 "preproc.y" + { (yyval.type_enum) = ECPGt_unsigned_int; ;} + break; + + case 2375: + +/* Line 1455 of yacc.c */ +#line 13346 "preproc.y" + { (yyval.type_enum) = ECPGt_unsigned_int; ;} + break; + + case 2376: + +/* Line 1455 of yacc.c */ +#line 13347 "preproc.y" + { (yyval.type_enum) = ECPGt_unsigned_long; ;} + break; + + case 2377: + +/* Line 1455 of yacc.c */ +#line 13348 "preproc.y" + { (yyval.type_enum) = ECPGt_unsigned_long; ;} + break; + + case 2378: + +/* Line 1455 of yacc.c */ +#line 13350 "preproc.y" + { +#ifdef HAVE_LONG_LONG_INT + (yyval.type_enum) = ECPGt_unsigned_long_long; +#else + (yyval.type_enum) = ECPGt_unsigned_long; +#endif + ;} + break; + + case 2379: + +/* Line 1455 of yacc.c */ +#line 13358 "preproc.y" + { +#ifdef HAVE_LONG_LONG_INT + (yyval.type_enum) = ECPGt_unsigned_long_long; +#else + (yyval.type_enum) = ECPGt_unsigned_long; +#endif + ;} + break; + + case 2380: + +/* Line 1455 of yacc.c */ +#line 13365 "preproc.y" + { (yyval.type_enum) = ECPGt_unsigned_char; ;} + break; + + case 2381: + +/* Line 1455 of yacc.c */ +#line 13368 "preproc.y" + { (yyval.type_enum) = ECPGt_short; ;} + break; + + case 2382: + +/* Line 1455 of yacc.c */ +#line 13369 "preproc.y" + { (yyval.type_enum) = ECPGt_short; ;} + break; + + case 2383: + +/* Line 1455 of yacc.c */ +#line 13370 "preproc.y" + { (yyval.type_enum) = ECPGt_int; ;} + break; + + case 2384: + +/* Line 1455 of yacc.c */ +#line 13371 "preproc.y" + { (yyval.type_enum) = ECPGt_long; ;} + break; + + case 2385: + +/* Line 1455 of yacc.c */ +#line 13372 "preproc.y" + { (yyval.type_enum) = ECPGt_long; ;} + break; + + case 2386: + +/* Line 1455 of yacc.c */ +#line 13374 "preproc.y" + { +#ifdef HAVE_LONG_LONG_INT + (yyval.type_enum) = ECPGt_long_long; +#else + (yyval.type_enum) = ECPGt_long; +#endif + ;} + break; + + case 2387: + +/* Line 1455 of yacc.c */ +#line 13382 "preproc.y" + { +#ifdef HAVE_LONG_LONG_INT + (yyval.type_enum) = ECPGt_long_long; +#else + (yyval.type_enum) = ECPGt_long; +#endif + ;} + break; + + case 2388: + +/* Line 1455 of yacc.c */ +#line 13389 "preproc.y" + { (yyval.type_enum) = ECPGt_bool; ;} + break; + + case 2389: + +/* Line 1455 of yacc.c */ +#line 13390 "preproc.y" + { (yyval.type_enum) = ECPGt_char; ;} + break; + + case 2390: + +/* Line 1455 of yacc.c */ +#line 13391 "preproc.y" + { (yyval.type_enum) = ECPGt_double; ;} + break; + + case 2393: + +/* Line 1455 of yacc.c */ +#line 13399 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2394: + +/* Line 1455 of yacc.c */ +#line 13401 "preproc.y" + { (yyval.str) = cat_str(3, (yyvsp[(1) - (3)].str), mm_strdup(","), (yyvsp[(3) - (3)].str)); ;} + break; + + case 2395: + +/* Line 1455 of yacc.c */ +#line 13405 "preproc.y" + { + struct ECPGtype * type; + char *dimension = (yyvsp[(3) - (5)].index).index1; /* dimension of array */ + char *length = (yyvsp[(3) - (5)].index).index2; /* length of string */ + char *dim_str; + char *vcn; + + adjust_array(actual_type[struct_level].type_enum, &dimension, &length, actual_type[struct_level].type_dimension, actual_type[struct_level].type_index, strlen((yyvsp[(1) - (5)].str)), false); + + switch (actual_type[struct_level].type_enum) + { + case ECPGt_struct: + case ECPGt_union: + if (atoi(dimension) < 0) + type = ECPGmake_struct_type(struct_member_list[struct_level], actual_type[struct_level].type_enum, actual_type[struct_level].type_str, actual_type[struct_level].type_sizeof); + else + type = ECPGmake_array_type(ECPGmake_struct_type(struct_member_list[struct_level], actual_type[struct_level].type_enum, actual_type[struct_level].type_str, actual_type[struct_level].type_sizeof), dimension); + + (yyval.str) = cat_str(5, (yyvsp[(1) - (5)].str), mm_strdup((yyvsp[(2) - (5)].str)), (yyvsp[(3) - (5)].index).str, (yyvsp[(4) - (5)].str), (yyvsp[(5) - (5)].str)); + break; + + case ECPGt_varchar: + if (atoi(dimension) < 0) + type = ECPGmake_simple_type(actual_type[struct_level].type_enum, length, varchar_counter); + else + type = ECPGmake_array_type(ECPGmake_simple_type(actual_type[struct_level].type_enum, length, varchar_counter), dimension); + + if (strcmp(dimension, "0") == 0 || abs(atoi(dimension)) == 1) + dim_str=mm_strdup(""); + else + dim_str=cat_str(3, mm_strdup("["), mm_strdup(dimension), mm_strdup("]")); + /* cannot check for atoi <= 0 because a defined constant will yield 0 here as well */ + if (atoi(length) < 0 || strcmp(length, "0") == 0) + mmerror(PARSE_ERROR, ET_ERROR, "pointers to varchar are not implemented"); + + /* make sure varchar struct name is unique by adding a unique counter to its definition */ + vcn = (char *) mm_alloc(sizeof(int) * CHAR_BIT * 10 / 3); + sprintf(vcn, "%d", varchar_counter); + if (strcmp(dimension, "0") == 0) + (yyval.str) = cat_str(7, make2_str(mm_strdup(" struct varchar_"), vcn), mm_strdup(" { int len; char arr["), mm_strdup(length), mm_strdup("]; } *"), mm_strdup((yyvsp[(2) - (5)].str)), (yyvsp[(4) - (5)].str), (yyvsp[(5) - (5)].str)); + else + (yyval.str) = cat_str(8, make2_str(mm_strdup(" struct varchar_"), vcn), mm_strdup(" { int len; char arr["), mm_strdup(length), mm_strdup("]; } "), mm_strdup((yyvsp[(2) - (5)].str)), dim_str, (yyvsp[(4) - (5)].str), (yyvsp[(5) - (5)].str)); + varchar_counter++; + break; + + case ECPGt_char: + case ECPGt_unsigned_char: + case ECPGt_string: + if (atoi(dimension) == -1) + { + int i = strlen((yyvsp[(5) - (5)].str)); + + if (atoi(length) == -1 && i > 0) /* char [] = "string" */ + { + /* if we have an initializer but no string size set, let's use the initializer's length */ + free(length); + length = mm_alloc(i+sizeof("sizeof()")); + sprintf(length, "sizeof(%s)", (yyvsp[(5) - (5)].str)+2); + } + type = ECPGmake_simple_type(actual_type[struct_level].type_enum, length, 0); + } + else + type = ECPGmake_array_type(ECPGmake_simple_type(actual_type[struct_level].type_enum, length, 0), dimension); + + (yyval.str) = cat_str(5, (yyvsp[(1) - (5)].str), mm_strdup((yyvsp[(2) - (5)].str)), (yyvsp[(3) - (5)].index).str, (yyvsp[(4) - (5)].str), (yyvsp[(5) - (5)].str)); + break; + + default: + if (atoi(dimension) < 0) + type = ECPGmake_simple_type(actual_type[struct_level].type_enum, mm_strdup("1"), 0); + else + type = ECPGmake_array_type(ECPGmake_simple_type(actual_type[struct_level].type_enum, mm_strdup("1"), 0), dimension); + + (yyval.str) = cat_str(5, (yyvsp[(1) - (5)].str), mm_strdup((yyvsp[(2) - (5)].str)), (yyvsp[(3) - (5)].index).str, (yyvsp[(4) - (5)].str), (yyvsp[(5) - (5)].str)); + break; + } + + if (struct_level == 0) + new_variable((yyvsp[(2) - (5)].str), type, braces_open); + else + ECPGmake_struct_member((yyvsp[(2) - (5)].str), type, &(struct_member_list[struct_level - 1])); + + free((yyvsp[(2) - (5)].str)); + ;} + break; + + case 2396: + +/* Line 1455 of yacc.c */ +#line 13492 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 2397: + +/* Line 1455 of yacc.c */ +#line 13494 "preproc.y" + { + initializer = 1; + (yyval.str) = cat2_str(mm_strdup("="), (yyvsp[(2) - (2)].str)); + ;} + break; + + case 2398: + +/* Line 1455 of yacc.c */ +#line 13500 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 2399: + +/* Line 1455 of yacc.c */ +#line 13501 "preproc.y" + { (yyval.str) = mm_strdup("*"); ;} + break; + + case 2400: + +/* Line 1455 of yacc.c */ +#line 13502 "preproc.y" + { (yyval.str) = mm_strdup("**"); ;} + break; + + case 2401: + +/* Line 1455 of yacc.c */ +#line 13509 "preproc.y" + { + /* this is only supported for compatibility */ + (yyval.str) = cat_str(3, mm_strdup("/* declare statement"), (yyvsp[(3) - (3)].str), mm_strdup("*/")); + ;} + break; + + case 2402: + +/* Line 1455 of yacc.c */ +#line 13517 "preproc.y" + { (yyval.str) = (yyvsp[(2) - (2)].str); ;} + break; + + case 2403: + +/* Line 1455 of yacc.c */ +#line 13520 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2404: + +/* Line 1455 of yacc.c */ +#line 13521 "preproc.y" + { (yyval.str) = mm_strdup("\"CURRENT\""); ;} + break; + + case 2405: + +/* Line 1455 of yacc.c */ +#line 13522 "preproc.y" + { (yyval.str) = mm_strdup("\"ALL\""); ;} + break; + + case 2406: + +/* Line 1455 of yacc.c */ +#line 13523 "preproc.y" + { (yyval.str) = mm_strdup("\"CURRENT\""); ;} + break; + + case 2407: + +/* Line 1455 of yacc.c */ +#line 13526 "preproc.y" + { (yyval.str) = make3_str(mm_strdup("\""), (yyvsp[(1) - (1)].str), mm_strdup("\"")); ;} + break; + + case 2408: + +/* Line 1455 of yacc.c */ +#line 13527 "preproc.y" + { (yyval.str) = mm_strdup("\"DEFAULT\""); ;} + break; + + case 2409: + +/* Line 1455 of yacc.c */ +#line 13528 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2410: + +/* Line 1455 of yacc.c */ +#line 13532 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2411: + +/* Line 1455 of yacc.c */ +#line 13534 "preproc.y" + { (yyval.str) = make3_str(mm_strdup("\""), (yyvsp[(1) - (1)].str), mm_strdup("\"")); ;} + break; + + case 2412: + +/* Line 1455 of yacc.c */ +#line 13541 "preproc.y" + { (yyval.str) = (yyvsp[(2) - (2)].str); ;} + break; + + case 2413: + +/* Line 1455 of yacc.c */ +#line 13542 "preproc.y" + { (yyval.str) = mm_strdup("all"); ;} + break; + + case 2414: + +/* Line 1455 of yacc.c */ +#line 13549 "preproc.y" + { + if ((yyvsp[(2) - (3)].str)[0] == ':') + remove_variable_from_list(&argsinsert, find_variable((yyvsp[(2) - (3)].str) + 1)); + (yyval.str) = (yyvsp[(2) - (3)].str); + ;} + break; + + case 2415: + +/* Line 1455 of yacc.c */ +#line 13556 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 2416: + +/* Line 1455 of yacc.c */ +#line 13557 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2417: + +/* Line 1455 of yacc.c */ +#line 13560 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 2418: + +/* Line 1455 of yacc.c */ +#line 13561 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2419: + +/* Line 1455 of yacc.c */ +#line 13565 "preproc.y" + { + add_variable_to_head(&argsinsert, descriptor_variable((yyvsp[(4) - (4)].str),0), &no_indicator); + (yyval.str) = EMPTY; + ;} + break; + + case 2420: + +/* Line 1455 of yacc.c */ +#line 13570 "preproc.y" + { + add_variable_to_head(&argsinsert, sqlda_variable((yyvsp[(3) - (3)].str)), &no_indicator); + (yyval.str) = EMPTY; + ;} + break; + + case 2421: + +/* Line 1455 of yacc.c */ +#line 13577 "preproc.y" + { + add_variable_to_head(&argsresult, descriptor_variable((yyvsp[(4) - (4)].str),1), &no_indicator); + (yyval.str) = EMPTY; + ;} + break; + + case 2422: + +/* Line 1455 of yacc.c */ +#line 13582 "preproc.y" + { + add_variable_to_head(&argsresult, sqlda_variable((yyvsp[(3) - (3)].str)), &no_indicator); + (yyval.str) = EMPTY; + ;} + break; + + case 2423: + +/* Line 1455 of yacc.c */ +#line 13589 "preproc.y" + { + add_variable_to_head(&argsresult, sqlda_variable((yyvsp[(2) - (2)].str)), &no_indicator); + (yyval.str) = EMPTY; + ;} + break; + + case 2426: + +/* Line 1455 of yacc.c */ +#line 13598 "preproc.y" + { + char *length = mm_alloc(32); + + sprintf(length, "%d", (int) strlen((yyvsp[(1) - (1)].str))); + add_variable_to_head(&argsinsert, new_variable((yyvsp[(1) - (1)].str), ECPGmake_simple_type(ECPGt_const, length, 0), 0), &no_indicator); + ;} + break; + + case 2427: + +/* Line 1455 of yacc.c */ +#line 13604 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 2428: + +/* Line 1455 of yacc.c */ +#line 13605 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 2429: + +/* Line 1455 of yacc.c */ +#line 13608 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2430: + +/* Line 1455 of yacc.c */ +#line 13609 "preproc.y" + { (yyval.str) = cat_str(2, mm_strdup("+"), (yyvsp[(2) - (2)].str)); ;} + break; + + case 2431: + +/* Line 1455 of yacc.c */ +#line 13610 "preproc.y" + { (yyval.str) = cat_str(2, mm_strdup("-"), (yyvsp[(2) - (2)].str)); ;} + break; + + case 2432: + +/* Line 1455 of yacc.c */ +#line 13611 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2433: + +/* Line 1455 of yacc.c */ +#line 13612 "preproc.y" + { (yyval.str) = cat_str(2, mm_strdup("+"), (yyvsp[(2) - (2)].str)); ;} + break; + + case 2434: + +/* Line 1455 of yacc.c */ +#line 13613 "preproc.y" + { (yyval.str) = cat_str(2, mm_strdup("-"), (yyvsp[(2) - (2)].str)); ;} + break; + + case 2435: + +/* Line 1455 of yacc.c */ +#line 13614 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2436: + +/* Line 1455 of yacc.c */ +#line 13615 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2437: + +/* Line 1455 of yacc.c */ +#line 13616 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2438: + +/* Line 1455 of yacc.c */ +#line 13623 "preproc.y" + { + const char *con = connection ? connection : "NULL"; + mmerror(PARSE_ERROR, ET_WARNING, "using unsupported DESCRIBE statement"); + (yyval.str) = (char *) mm_alloc(sizeof("1, , ") + strlen(con) + strlen((yyvsp[(3) - (4)].str))); + sprintf((yyval.str), "1, %s, %s", con, (yyvsp[(3) - (4)].str)); + ;} + break; + + case 2439: + +/* Line 1455 of yacc.c */ +#line 13630 "preproc.y" + { + const char *con = connection ? connection : "NULL"; + struct variable *var; + + var = argsinsert->variable; + remove_variable_from_list(&argsinsert, var); + add_variable_to_head(&argsresult, var, &no_indicator); + + (yyval.str) = (char *) mm_alloc(sizeof("0, , ") + strlen(con) + strlen((yyvsp[(3) - (4)].str))); + sprintf((yyval.str), "0, %s, %s", con, (yyvsp[(3) - (4)].str)); + ;} + break; + + case 2440: + +/* Line 1455 of yacc.c */ +#line 13642 "preproc.y" + { + const char *con = connection ? connection : "NULL"; + (yyval.str) = (char *) mm_alloc(sizeof("0, , ") + strlen(con) + strlen((yyvsp[(3) - (4)].str))); + sprintf((yyval.str), "0, %s, %s", con, (yyvsp[(3) - (4)].str)); + ;} + break; + + case 2441: + +/* Line 1455 of yacc.c */ +#line 13648 "preproc.y" + { + const char *con = connection ? connection : "NULL"; + mmerror(PARSE_ERROR, ET_WARNING, "using unsupported DESCRIBE statement"); + (yyval.str) = (char *) mm_alloc(sizeof("1, , ") + strlen(con) + strlen((yyvsp[(3) - (4)].str))); + sprintf((yyval.str), "1, %s, %s", con, (yyvsp[(3) - (4)].str)); + ;} + break; + + case 2442: + +/* Line 1455 of yacc.c */ +#line 13655 "preproc.y" + { + const char *con = connection ? connection : "NULL"; + (yyval.str) = (char *) mm_alloc(sizeof("0, , ") + strlen(con) + strlen((yyvsp[(3) - (4)].str))); + sprintf((yyval.str), "0, %s, %s", con, (yyvsp[(3) - (4)].str)); + ;} + break; + + case 2443: + +/* Line 1455 of yacc.c */ +#line 13662 "preproc.y" + { (yyval.str) = mm_strdup("output"); ;} + break; + + case 2444: + +/* Line 1455 of yacc.c */ +#line 13663 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 2445: + +/* Line 1455 of yacc.c */ +#line 13676 "preproc.y" + { + add_descriptor((yyvsp[(3) - (3)].str),connection); + (yyval.str) = (yyvsp[(3) - (3)].str); + ;} + break; + + case 2446: + +/* Line 1455 of yacc.c */ +#line 13687 "preproc.y" + { + drop_descriptor((yyvsp[(3) - (3)].str),connection); + (yyval.str) = (yyvsp[(3) - (3)].str); + ;} + break; + + case 2447: + +/* Line 1455 of yacc.c */ +#line 13698 "preproc.y" + { (yyval.str) = (yyvsp[(3) - (4)].str); ;} + break; + + case 2450: + +/* Line 1455 of yacc.c */ +#line 13706 "preproc.y" + { push_assignment((yyvsp[(1) - (3)].str), (yyvsp[(3) - (3)].dtype_enum)); ;} + break; + + case 2451: + +/* Line 1455 of yacc.c */ +#line 13711 "preproc.y" + { (yyval.str) = (yyvsp[(3) - (4)].str); ;} + break; + + case 2454: + +/* Line 1455 of yacc.c */ +#line 13719 "preproc.y" + { + push_assignment((yyvsp[(3) - (3)].str), (yyvsp[(1) - (3)].dtype_enum)); + ;} + break; + + case 2455: + +/* Line 1455 of yacc.c */ +#line 13725 "preproc.y" + { + char *length = mm_alloc(sizeof(int) * CHAR_BIT * 10 / 3); + + sprintf(length, "%d", (int) strlen((yyvsp[(1) - (1)].str))); + new_variable((yyvsp[(1) - (1)].str), ECPGmake_simple_type(ECPGt_const, length, 0), 0); + (yyval.str) = (yyvsp[(1) - (1)].str); + ;} + break; + + case 2456: + +/* Line 1455 of yacc.c */ +#line 13733 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); + ;} + break; + + case 2457: + +/* Line 1455 of yacc.c */ +#line 13738 "preproc.y" + { (yyval.dtype_enum) = ECPGd_count; ;} + break; + + case 2458: + +/* Line 1455 of yacc.c */ +#line 13746 "preproc.y" + { (yyval.descriptor).str = (yyvsp[(5) - (6)].str); (yyval.descriptor).name = (yyvsp[(3) - (6)].str); ;} + break; + + case 2461: + +/* Line 1455 of yacc.c */ +#line 13753 "preproc.y" + { push_assignment((yyvsp[(1) - (3)].str), (yyvsp[(3) - (3)].dtype_enum)); ;} + break; + + case 2462: + +/* Line 1455 of yacc.c */ +#line 13757 "preproc.y" + { (yyval.descriptor).str = (yyvsp[(5) - (6)].str); (yyval.descriptor).name = (yyvsp[(3) - (6)].str); ;} + break; + + case 2465: + +/* Line 1455 of yacc.c */ +#line 13765 "preproc.y" + { + push_assignment((yyvsp[(3) - (3)].str), (yyvsp[(1) - (3)].dtype_enum)); + ;} + break; + + case 2466: + +/* Line 1455 of yacc.c */ +#line 13771 "preproc.y" + { + char *length = mm_alloc(sizeof(int) * CHAR_BIT * 10 / 3); + + sprintf(length, "%d", (int) strlen((yyvsp[(1) - (1)].str))); + new_variable((yyvsp[(1) - (1)].str), ECPGmake_simple_type(ECPGt_const, length, 0), 0); + (yyval.str) = (yyvsp[(1) - (1)].str); + ;} + break; + + case 2467: + +/* Line 1455 of yacc.c */ +#line 13780 "preproc.y" + { + (yyval.str) = (yyvsp[(1) - (1)].str); + ;} + break; + + case 2468: + +/* Line 1455 of yacc.c */ +#line 13785 "preproc.y" + { + char *length = mm_alloc(sizeof(int) * CHAR_BIT * 10 / 3); + char *var = cat2_str(mm_strdup("-"), (yyvsp[(2) - (2)].str)); + + sprintf(length, "%d", (int) strlen(var)); + new_variable(var, ECPGmake_simple_type(ECPGt_const, length, 0), 0); + (yyval.str) = var; + ;} + break; + + case 2469: + +/* Line 1455 of yacc.c */ +#line 13795 "preproc.y" + { + char *length = mm_alloc(sizeof(int) * CHAR_BIT * 10 / 3); + char *var = cat2_str(mm_strdup("-"), (yyvsp[(2) - (2)].str)); + + sprintf(length, "%d", (int) strlen(var)); + new_variable(var, ECPGmake_simple_type(ECPGt_const, length, 0), 0); + (yyval.str) = var; + ;} + break; + + case 2470: + +/* Line 1455 of yacc.c */ +#line 13805 "preproc.y" + { + char *length = mm_alloc(sizeof(int) * CHAR_BIT * 10 / 3); + char *var = (yyvsp[(1) - (1)].str) + 1; + + var[strlen(var) - 1] = '\0'; + sprintf(length, "%d", (int) strlen(var)); + new_variable(var, ECPGmake_simple_type(ECPGt_const, length, 0), 0); + (yyval.str) = var; + ;} + break; + + case 2471: + +/* Line 1455 of yacc.c */ +#line 13816 "preproc.y" + { (yyval.dtype_enum) = ECPGd_cardinality; ;} + break; + + case 2472: + +/* Line 1455 of yacc.c */ +#line 13817 "preproc.y" + { (yyval.dtype_enum) = ECPGd_data; ;} + break; + + case 2473: + +/* Line 1455 of yacc.c */ +#line 13818 "preproc.y" + { (yyval.dtype_enum) = ECPGd_di_code; ;} + break; + + case 2474: + +/* Line 1455 of yacc.c */ +#line 13819 "preproc.y" + { (yyval.dtype_enum) = ECPGd_di_precision; ;} + break; + + case 2475: + +/* Line 1455 of yacc.c */ +#line 13820 "preproc.y" + { (yyval.dtype_enum) = ECPGd_indicator; ;} + break; + + case 2476: + +/* Line 1455 of yacc.c */ +#line 13821 "preproc.y" + { (yyval.dtype_enum) = ECPGd_key_member; ;} + break; + + case 2477: + +/* Line 1455 of yacc.c */ +#line 13822 "preproc.y" + { (yyval.dtype_enum) = ECPGd_length; ;} + break; + + case 2478: + +/* Line 1455 of yacc.c */ +#line 13823 "preproc.y" + { (yyval.dtype_enum) = ECPGd_name; ;} + break; + + case 2479: + +/* Line 1455 of yacc.c */ +#line 13824 "preproc.y" + { (yyval.dtype_enum) = ECPGd_nullable; ;} + break; + + case 2480: + +/* Line 1455 of yacc.c */ +#line 13825 "preproc.y" + { (yyval.dtype_enum) = ECPGd_octet; ;} + break; + + case 2481: + +/* Line 1455 of yacc.c */ +#line 13826 "preproc.y" + { (yyval.dtype_enum) = ECPGd_precision; ;} + break; + + case 2482: + +/* Line 1455 of yacc.c */ +#line 13827 "preproc.y" + { (yyval.dtype_enum) = ECPGd_length; ;} + break; + + case 2483: + +/* Line 1455 of yacc.c */ +#line 13828 "preproc.y" + { (yyval.dtype_enum) = ECPGd_ret_octet; ;} + break; + + case 2484: + +/* Line 1455 of yacc.c */ +#line 13829 "preproc.y" + { (yyval.dtype_enum) = ECPGd_scale; ;} + break; + + case 2485: + +/* Line 1455 of yacc.c */ +#line 13830 "preproc.y" + { (yyval.dtype_enum) = ECPGd_type; ;} + break; + + case 2486: + +/* Line 1455 of yacc.c */ +#line 13837 "preproc.y" + { (yyval.str) = (yyvsp[(4) - (4)].str); ;} + break; + + case 2487: + +/* Line 1455 of yacc.c */ +#line 13838 "preproc.y" + { (yyval.str) = (yyvsp[(4) - (4)].str); ;} + break; + + case 2488: + +/* Line 1455 of yacc.c */ +#line 13841 "preproc.y" + { (yyval.str) = mm_strdup("on"); ;} + break; + + case 2489: + +/* Line 1455 of yacc.c */ +#line 13842 "preproc.y" + { (yyval.str) = mm_strdup("off"); ;} + break; + + case 2490: + +/* Line 1455 of yacc.c */ +#line 13849 "preproc.y" + { (yyval.str) = (yyvsp[(4) - (4)].str); ;} + break; + + case 2491: + +/* Line 1455 of yacc.c */ +#line 13850 "preproc.y" + { (yyval.str) = (yyvsp[(4) - (4)].str); ;} + break; + + case 2492: + +/* Line 1455 of yacc.c */ +#line 13851 "preproc.y" + { (yyval.str) = (yyvsp[(3) - (3)].str); ;} + break; + + case 2493: + +/* Line 1455 of yacc.c */ +#line 13858 "preproc.y" + { + /* reset this variable so we see if there was */ + /* an initializer specified */ + initializer = 0; + ;} + break; + + case 2494: + +/* Line 1455 of yacc.c */ +#line 13864 "preproc.y" + { + add_typedef((yyvsp[(3) - (7)].str), (yyvsp[(6) - (7)].index).index1, (yyvsp[(6) - (7)].index).index2, (yyvsp[(5) - (7)].type).type_enum, (yyvsp[(5) - (7)].type).type_dimension, (yyvsp[(5) - (7)].type).type_index, initializer, *(yyvsp[(7) - (7)].str) ? 1 : 0); + + if (auto_create_c == false) + (yyval.str) = cat_str(7, mm_strdup("/* exec sql type"), mm_strdup((yyvsp[(3) - (7)].str)), mm_strdup("is"), mm_strdup((yyvsp[(5) - (7)].type).type_str), mm_strdup((yyvsp[(6) - (7)].index).str), (yyvsp[(7) - (7)].str), mm_strdup("*/")); + else + (yyval.str) = cat_str(6, mm_strdup("typedef "), mm_strdup((yyvsp[(5) - (7)].type).type_str), *(yyvsp[(7) - (7)].str)?mm_strdup("*"):mm_strdup(""), mm_strdup((yyvsp[(6) - (7)].index).str), mm_strdup((yyvsp[(3) - (7)].str)), mm_strdup(";")); + ;} + break; + + case 2495: + +/* Line 1455 of yacc.c */ +#line 13874 "preproc.y" + { (yyval.str) = mm_strdup("reference"); ;} + break; + + case 2496: + +/* Line 1455 of yacc.c */ +#line 13875 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 2497: + +/* Line 1455 of yacc.c */ +#line 13882 "preproc.y" + { + /* reset this variable so we see if there was */ + /* an initializer specified */ + initializer = 0; + ;} + break; + + case 2498: + +/* Line 1455 of yacc.c */ +#line 13888 "preproc.y" + { + struct variable *p = find_variable((yyvsp[(3) - (7)].str)); + char *dimension = (yyvsp[(6) - (7)].index).index1; + char *length = (yyvsp[(6) - (7)].index).index2; + struct ECPGtype * type; + + if (((yyvsp[(5) - (7)].type).type_enum == ECPGt_struct || + (yyvsp[(5) - (7)].type).type_enum == ECPGt_union) && + initializer == 1) + mmerror(PARSE_ERROR, ET_ERROR, "initializer not allowed in EXEC SQL VAR command"); + else + { + adjust_array((yyvsp[(5) - (7)].type).type_enum, &dimension, &length, (yyvsp[(5) - (7)].type).type_dimension, (yyvsp[(5) - (7)].type).type_index, *(yyvsp[(7) - (7)].str)?1:0, false); + + switch ((yyvsp[(5) - (7)].type).type_enum) + { + case ECPGt_struct: + case ECPGt_union: + if (atoi(dimension) < 0) + type = ECPGmake_struct_type(struct_member_list[struct_level], (yyvsp[(5) - (7)].type).type_enum, (yyvsp[(5) - (7)].type).type_str, (yyvsp[(5) - (7)].type).type_sizeof); + else + type = ECPGmake_array_type(ECPGmake_struct_type(struct_member_list[struct_level], (yyvsp[(5) - (7)].type).type_enum, (yyvsp[(5) - (7)].type).type_str, (yyvsp[(5) - (7)].type).type_sizeof), dimension); + break; + + case ECPGt_varchar: + if (atoi(dimension) == -1) + type = ECPGmake_simple_type((yyvsp[(5) - (7)].type).type_enum, length, 0); + else + type = ECPGmake_array_type(ECPGmake_simple_type((yyvsp[(5) - (7)].type).type_enum, length, 0), dimension); + break; + + case ECPGt_char: + case ECPGt_unsigned_char: + case ECPGt_string: + if (atoi(dimension) == -1) + type = ECPGmake_simple_type((yyvsp[(5) - (7)].type).type_enum, length, 0); + else + type = ECPGmake_array_type(ECPGmake_simple_type((yyvsp[(5) - (7)].type).type_enum, length, 0), dimension); + break; + + default: + if (atoi(length) >= 0) + mmerror(PARSE_ERROR, ET_ERROR, "multidimensional arrays for simple data types are not supported"); + + if (atoi(dimension) < 0) + type = ECPGmake_simple_type((yyvsp[(5) - (7)].type).type_enum, mm_strdup("1"), 0); + else + type = ECPGmake_array_type(ECPGmake_simple_type((yyvsp[(5) - (7)].type).type_enum, mm_strdup("1"), 0), dimension); + break; + } + + ECPGfree_type(p->type); + p->type = type; + } + + (yyval.str) = cat_str(7, mm_strdup("/* exec sql var"), mm_strdup((yyvsp[(3) - (7)].str)), mm_strdup("is"), mm_strdup((yyvsp[(5) - (7)].type).type_str), mm_strdup((yyvsp[(6) - (7)].index).str), (yyvsp[(7) - (7)].str), mm_strdup("*/")); + ;} + break; + + case 2499: + +/* Line 1455 of yacc.c */ +#line 13952 "preproc.y" + { + when_error.code = (yyvsp[(3) - (3)].action).code; + when_error.command = (yyvsp[(3) - (3)].action).command; + (yyval.str) = cat_str(3, mm_strdup("/* exec sql whenever sqlerror "), (yyvsp[(3) - (3)].action).str, mm_strdup("; */")); + ;} + break; + + case 2500: + +/* Line 1455 of yacc.c */ +#line 13958 "preproc.y" + { + when_nf.code = (yyvsp[(4) - (4)].action).code; + when_nf.command = (yyvsp[(4) - (4)].action).command; + (yyval.str) = cat_str(3, mm_strdup("/* exec sql whenever not found "), (yyvsp[(4) - (4)].action).str, mm_strdup("; */")); + ;} + break; + + case 2501: + +/* Line 1455 of yacc.c */ +#line 13964 "preproc.y" + { + when_warn.code = (yyvsp[(3) - (3)].action).code; + when_warn.command = (yyvsp[(3) - (3)].action).command; + (yyval.str) = cat_str(3, mm_strdup("/* exec sql whenever sql_warning "), (yyvsp[(3) - (3)].action).str, mm_strdup("; */")); + ;} + break; + + case 2502: + +/* Line 1455 of yacc.c */ +#line 13972 "preproc.y" + { + (yyval.action).code = W_NOTHING; + (yyval.action).command = NULL; + (yyval.action).str = mm_strdup("continue"); + ;} + break; + + case 2503: + +/* Line 1455 of yacc.c */ +#line 13978 "preproc.y" + { + (yyval.action).code = W_SQLPRINT; + (yyval.action).command = NULL; + (yyval.action).str = mm_strdup("sqlprint"); + ;} + break; + + case 2504: + +/* Line 1455 of yacc.c */ +#line 13984 "preproc.y" + { + (yyval.action).code = W_STOP; + (yyval.action).command = NULL; + (yyval.action).str = mm_strdup("stop"); + ;} + break; + + case 2505: + +/* Line 1455 of yacc.c */ +#line 13990 "preproc.y" + { + (yyval.action).code = W_GOTO; + (yyval.action).command = strdup((yyvsp[(2) - (2)].str)); + (yyval.action).str = cat2_str(mm_strdup("goto "), (yyvsp[(2) - (2)].str)); + ;} + break; + + case 2506: + +/* Line 1455 of yacc.c */ +#line 13996 "preproc.y" + { + (yyval.action).code = W_GOTO; + (yyval.action).command = strdup((yyvsp[(3) - (3)].str)); + (yyval.action).str = cat2_str(mm_strdup("goto "), (yyvsp[(3) - (3)].str)); + ;} + break; + + case 2507: + +/* Line 1455 of yacc.c */ +#line 14002 "preproc.y" + { + (yyval.action).code = W_DO; + (yyval.action).command = cat_str(4, (yyvsp[(2) - (5)].str), mm_strdup("("), (yyvsp[(4) - (5)].str), mm_strdup(")")); + (yyval.action).str = cat2_str(mm_strdup("do"), mm_strdup((yyval.action).command)); + ;} + break; + + case 2508: + +/* Line 1455 of yacc.c */ +#line 14008 "preproc.y" + { + (yyval.action).code = W_BREAK; + (yyval.action).command = NULL; + (yyval.action).str = mm_strdup("break"); + ;} + break; + + case 2509: + +/* Line 1455 of yacc.c */ +#line 14014 "preproc.y" + { + (yyval.action).code = W_DO; + (yyval.action).command = cat_str(4, (yyvsp[(2) - (5)].str), mm_strdup("("), (yyvsp[(4) - (5)].str), mm_strdup(")")); + (yyval.action).str = cat2_str(mm_strdup("call"), mm_strdup((yyval.action).command)); + ;} + break; + + case 2510: + +/* Line 1455 of yacc.c */ +#line 14020 "preproc.y" + { + (yyval.action).code = W_DO; + (yyval.action).command = cat2_str((yyvsp[(2) - (2)].str), mm_strdup("()")); + (yyval.action).str = cat2_str(mm_strdup("call"), mm_strdup((yyval.action).command)); + ;} + break; + + case 2511: + +/* Line 1455 of yacc.c */ +#line 14030 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2512: + +/* Line 1455 of yacc.c */ +#line 14031 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2513: + +/* Line 1455 of yacc.c */ +#line 14034 "preproc.y" + { (yyval.str) = mm_strdup("break"); ;} + break; + + case 2514: + +/* Line 1455 of yacc.c */ +#line 14035 "preproc.y" + { (yyval.str) = mm_strdup("call"); ;} + break; + + case 2515: + +/* Line 1455 of yacc.c */ +#line 14036 "preproc.y" + { (yyval.str) = mm_strdup("cardinality"); ;} + break; + + case 2516: + +/* Line 1455 of yacc.c */ +#line 14037 "preproc.y" + { (yyval.str) = mm_strdup("count"); ;} + break; + + case 2517: + +/* Line 1455 of yacc.c */ +#line 14038 "preproc.y" + { (yyval.str) = mm_strdup("datetime_interval_code"); ;} + break; + + case 2518: + +/* Line 1455 of yacc.c */ +#line 14039 "preproc.y" + { (yyval.str) = mm_strdup("datetime_interval_precision"); ;} + break; + + case 2519: + +/* Line 1455 of yacc.c */ +#line 14040 "preproc.y" + { (yyval.str) = mm_strdup("found"); ;} + break; + + case 2520: + +/* Line 1455 of yacc.c */ +#line 14041 "preproc.y" + { (yyval.str) = mm_strdup("go"); ;} + break; + + case 2521: + +/* Line 1455 of yacc.c */ +#line 14042 "preproc.y" + { (yyval.str) = mm_strdup("goto"); ;} + break; + + case 2522: + +/* Line 1455 of yacc.c */ +#line 14043 "preproc.y" + { (yyval.str) = mm_strdup("identified"); ;} + break; + + case 2523: + +/* Line 1455 of yacc.c */ +#line 14044 "preproc.y" + { (yyval.str) = mm_strdup("indicator"); ;} + break; + + case 2524: + +/* Line 1455 of yacc.c */ +#line 14045 "preproc.y" + { (yyval.str) = mm_strdup("key_member"); ;} + break; + + case 2525: + +/* Line 1455 of yacc.c */ +#line 14046 "preproc.y" + { (yyval.str) = mm_strdup("length"); ;} + break; + + case 2526: + +/* Line 1455 of yacc.c */ +#line 14047 "preproc.y" + { (yyval.str) = mm_strdup("nullable"); ;} + break; + + case 2527: + +/* Line 1455 of yacc.c */ +#line 14048 "preproc.y" + { (yyval.str) = mm_strdup("octet_length"); ;} + break; + + case 2528: + +/* Line 1455 of yacc.c */ +#line 14049 "preproc.y" + { (yyval.str) = mm_strdup("returned_length"); ;} + break; + + case 2529: + +/* Line 1455 of yacc.c */ +#line 14050 "preproc.y" + { (yyval.str) = mm_strdup("returned_octet_length"); ;} + break; + + case 2530: + +/* Line 1455 of yacc.c */ +#line 14051 "preproc.y" + { (yyval.str) = mm_strdup("scale"); ;} + break; + + case 2531: + +/* Line 1455 of yacc.c */ +#line 14052 "preproc.y" + { (yyval.str) = mm_strdup("section"); ;} + break; + + case 2532: + +/* Line 1455 of yacc.c */ +#line 14053 "preproc.y" + { (yyval.str) = mm_strdup("sql"); ;} + break; + + case 2533: + +/* Line 1455 of yacc.c */ +#line 14054 "preproc.y" + { (yyval.str) = mm_strdup("sqlerror"); ;} + break; + + case 2534: + +/* Line 1455 of yacc.c */ +#line 14055 "preproc.y" + { (yyval.str) = mm_strdup("sqlprint"); ;} + break; + + case 2535: + +/* Line 1455 of yacc.c */ +#line 14056 "preproc.y" + { (yyval.str) = mm_strdup("sqlwarning"); ;} + break; + + case 2536: + +/* Line 1455 of yacc.c */ +#line 14057 "preproc.y" + { (yyval.str) = mm_strdup("stop"); ;} + break; + + case 2537: + +/* Line 1455 of yacc.c */ +#line 14060 "preproc.y" + { (yyval.str) = mm_strdup("connect"); ;} + break; + + case 2538: + +/* Line 1455 of yacc.c */ +#line 14061 "preproc.y" + { (yyval.str) = mm_strdup("describe"); ;} + break; + + case 2539: + +/* Line 1455 of yacc.c */ +#line 14062 "preproc.y" + { (yyval.str) = mm_strdup("disconnect"); ;} + break; + + case 2540: + +/* Line 1455 of yacc.c */ +#line 14063 "preproc.y" + { (yyval.str) = mm_strdup("open"); ;} + break; + + case 2541: + +/* Line 1455 of yacc.c */ +#line 14064 "preproc.y" + { (yyval.str) = mm_strdup("var"); ;} + break; + + case 2542: + +/* Line 1455 of yacc.c */ +#line 14065 "preproc.y" + { (yyval.str) = mm_strdup("whenever"); ;} + break; + + case 2543: + +/* Line 1455 of yacc.c */ +#line 14069 "preproc.y" + { (yyval.str) = mm_strdup("bool"); ;} + break; + + case 2544: + +/* Line 1455 of yacc.c */ +#line 14070 "preproc.y" + { (yyval.str) = mm_strdup("long"); ;} + break; + + case 2545: + +/* Line 1455 of yacc.c */ +#line 14071 "preproc.y" + { (yyval.str) = mm_strdup("output"); ;} + break; + + case 2546: + +/* Line 1455 of yacc.c */ +#line 14072 "preproc.y" + { (yyval.str) = mm_strdup("short"); ;} + break; + + case 2547: + +/* Line 1455 of yacc.c */ +#line 14073 "preproc.y" + { (yyval.str) = mm_strdup("struct"); ;} + break; + + case 2548: + +/* Line 1455 of yacc.c */ +#line 14074 "preproc.y" + { (yyval.str) = mm_strdup("signed"); ;} + break; + + case 2549: + +/* Line 1455 of yacc.c */ +#line 14075 "preproc.y" + { (yyval.str) = mm_strdup("unsigned"); ;} + break; + + case 2550: + +/* Line 1455 of yacc.c */ +#line 14078 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2551: + +/* Line 1455 of yacc.c */ +#line 14081 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2552: + +/* Line 1455 of yacc.c */ +#line 14082 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2553: + +/* Line 1455 of yacc.c */ +#line 14083 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2554: + +/* Line 1455 of yacc.c */ +#line 14084 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2555: + +/* Line 1455 of yacc.c */ +#line 14085 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2556: + +/* Line 1455 of yacc.c */ +#line 14086 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2557: + +/* Line 1455 of yacc.c */ +#line 14087 "preproc.y" + { (yyval.str) = mm_strdup("char"); ;} + break; + + case 2558: + +/* Line 1455 of yacc.c */ +#line 14088 "preproc.y" + { (yyval.str) = mm_strdup("values"); ;} + break; + + case 2559: + +/* Line 1455 of yacc.c */ +#line 14101 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2560: + +/* Line 1455 of yacc.c */ +#line 14102 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2561: + +/* Line 1455 of yacc.c */ +#line 14103 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2562: + +/* Line 1455 of yacc.c */ +#line 14104 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2563: + +/* Line 1455 of yacc.c */ +#line 14105 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2564: + +/* Line 1455 of yacc.c */ +#line 14106 "preproc.y" + { (yyval.str) = mm_strdup("char"); ;} + break; + + case 2565: + +/* Line 1455 of yacc.c */ +#line 14107 "preproc.y" + { (yyval.str) = mm_strdup("values"); ;} + break; + + case 2566: + +/* Line 1455 of yacc.c */ +#line 14112 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2567: + +/* Line 1455 of yacc.c */ +#line 14113 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2568: + +/* Line 1455 of yacc.c */ +#line 14114 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2569: + +/* Line 1455 of yacc.c */ +#line 14115 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2570: + +/* Line 1455 of yacc.c */ +#line 14116 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2571: + +/* Line 1455 of yacc.c */ +#line 14117 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2572: + +/* Line 1455 of yacc.c */ +#line 14123 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2573: + +/* Line 1455 of yacc.c */ +#line 14124 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2574: + +/* Line 1455 of yacc.c */ +#line 14125 "preproc.y" + { (yyval.str) = mm_strdup("char"); ;} + break; + + case 2575: + +/* Line 1455 of yacc.c */ +#line 14126 "preproc.y" + { (yyval.str) = mm_strdup("current"); ;} + break; + + case 2576: + +/* Line 1455 of yacc.c */ +#line 14127 "preproc.y" + { (yyval.str) = mm_strdup("input"); ;} + break; + + case 2577: + +/* Line 1455 of yacc.c */ +#line 14128 "preproc.y" + { (yyval.str) = mm_strdup("int"); ;} + break; + + case 2578: + +/* Line 1455 of yacc.c */ +#line 14129 "preproc.y" + { (yyval.str) = mm_strdup("to"); ;} + break; + + case 2579: + +/* Line 1455 of yacc.c */ +#line 14130 "preproc.y" + { (yyval.str) = mm_strdup("union"); ;} + break; + + case 2580: + +/* Line 1455 of yacc.c */ +#line 14131 "preproc.y" + { (yyval.str) = mm_strdup("values"); ;} + break; + + case 2581: + +/* Line 1455 of yacc.c */ +#line 14132 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2582: + +/* Line 1455 of yacc.c */ +#line 14133 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2583: + +/* Line 1455 of yacc.c */ +#line 14136 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2584: + +/* Line 1455 of yacc.c */ +#line 14137 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2585: + +/* Line 1455 of yacc.c */ +#line 14138 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2586: + +/* Line 1455 of yacc.c */ +#line 14139 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2587: + +/* Line 1455 of yacc.c */ +#line 14140 "preproc.y" + { (yyval.str) = mm_strdup("connection"); ;} + break; + + case 2588: + +/* Line 1455 of yacc.c */ +#line 14143 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2589: + +/* Line 1455 of yacc.c */ +#line 14144 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2590: + +/* Line 1455 of yacc.c */ +#line 14145 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2591: + +/* Line 1455 of yacc.c */ +#line 14146 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2592: + +/* Line 1455 of yacc.c */ +#line 14149 "preproc.y" + { (yyval.str) = mm_strdup("auto"); ;} + break; + + case 2593: + +/* Line 1455 of yacc.c */ +#line 14150 "preproc.y" + { (yyval.str) = mm_strdup("const"); ;} + break; + + case 2594: + +/* Line 1455 of yacc.c */ +#line 14151 "preproc.y" + { (yyval.str) = mm_strdup("extern"); ;} + break; + + case 2595: + +/* Line 1455 of yacc.c */ +#line 14152 "preproc.y" + { (yyval.str) = mm_strdup("register"); ;} + break; + + case 2596: + +/* Line 1455 of yacc.c */ +#line 14153 "preproc.y" + { (yyval.str) = mm_strdup("static"); ;} + break; + + case 2597: + +/* Line 1455 of yacc.c */ +#line 14154 "preproc.y" + { (yyval.str) = mm_strdup("typedef"); ;} + break; + + case 2598: + +/* Line 1455 of yacc.c */ +#line 14155 "preproc.y" + { (yyval.str) = mm_strdup("volatile"); ;} + break; + + case 2599: + +/* Line 1455 of yacc.c */ +#line 14172 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2600: + +/* Line 1455 of yacc.c */ +#line 14173 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2601: + +/* Line 1455 of yacc.c */ +#line 14174 "preproc.y" + { (yyval.str) = mm_strdup("connection"); ;} + break; + + case 2602: + +/* Line 1455 of yacc.c */ +#line 14177 "preproc.y" + { (yyval.str) = mm_strdup("day"); ;} + break; + + case 2603: + +/* Line 1455 of yacc.c */ +#line 14178 "preproc.y" + { (yyval.str) = mm_strdup("hour"); ;} + break; + + case 2604: + +/* Line 1455 of yacc.c */ +#line 14179 "preproc.y" + { (yyval.str) = mm_strdup("minute"); ;} + break; + + case 2605: + +/* Line 1455 of yacc.c */ +#line 14180 "preproc.y" + { (yyval.str) = mm_strdup("month"); ;} + break; + + case 2606: + +/* Line 1455 of yacc.c */ +#line 14181 "preproc.y" + { (yyval.str) = mm_strdup("second"); ;} + break; + + case 2607: + +/* Line 1455 of yacc.c */ +#line 14182 "preproc.y" + { (yyval.str) = mm_strdup("year"); ;} + break; + + case 2610: + +/* Line 1455 of yacc.c */ +#line 14189 "preproc.y" + { + reset_variables(); + pacounter = 1; + ;} + break; + + case 2611: + +/* Line 1455 of yacc.c */ +#line 14195 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 2612: + +/* Line 1455 of yacc.c */ +#line 14196 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2613: + +/* Line 1455 of yacc.c */ +#line 14200 "preproc.y" + { add_variable_to_head(&argsresult, find_variable((yyvsp[(1) - (2)].str)), find_variable((yyvsp[(2) - (2)].str))); ;} + break; + + case 2614: + +/* Line 1455 of yacc.c */ +#line 14202 "preproc.y" + { add_variable_to_head(&argsresult, find_variable((yyvsp[(1) - (1)].str)), &no_indicator); ;} + break; + + case 2615: + +/* Line 1455 of yacc.c */ +#line 14207 "preproc.y" + { + if (find_variable((yyvsp[(2) - (2)].str))->type->type == ECPGt_array) + mmerror(PARSE_ERROR, ET_ERROR, "arrays of indicators are not allowed on input"); + + add_variable_to_head(&argsinsert, find_variable((yyvsp[(1) - (2)].str)), find_variable((yyvsp[(2) - (2)].str))); + (yyval.str) = create_questionmarks((yyvsp[(1) - (2)].str), false); + ;} + break; + + case 2616: + +/* Line 1455 of yacc.c */ +#line 14217 "preproc.y" + { + char *ptr = strstr((yyvsp[(1) - (1)].str), ".arr"); + + if (ptr) /* varchar, we need the struct name here, not the struct element */ + *ptr = '\0'; + add_variable_to_head(&argsinsert, find_variable((yyvsp[(1) - (1)].str)), &no_indicator); + (yyval.str) = (yyvsp[(1) - (1)].str); + ;} + break; + + case 2617: + +/* Line 1455 of yacc.c */ +#line 14228 "preproc.y" + { + add_variable_to_head(&argsinsert, find_variable((yyvsp[(1) - (1)].str)), &no_indicator); + (yyval.str) = create_questionmarks((yyvsp[(1) - (1)].str), false); + ;} + break; + + case 2618: + +/* Line 1455 of yacc.c */ +#line 14234 "preproc.y" + { check_indicator((find_variable((yyvsp[(1) - (1)].str)))->type); (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2619: + +/* Line 1455 of yacc.c */ +#line 14235 "preproc.y" + { check_indicator((find_variable((yyvsp[(2) - (2)].str)))->type); (yyval.str) = (yyvsp[(2) - (2)].str); ;} + break; + + case 2620: + +/* Line 1455 of yacc.c */ +#line 14236 "preproc.y" + { check_indicator((find_variable((yyvsp[(2) - (2)].str)))->type); (yyval.str) = (yyvsp[(2) - (2)].str); ;} + break; + + case 2621: + +/* Line 1455 of yacc.c */ +#line 14240 "preproc.y" + { + /* As long as multidimensional arrays are not implemented we have to check for those here */ + char *ptr = (yyvsp[(1) - (1)].str); + int brace_open=0, brace = false; + + for (; *ptr; ptr++) + { + switch (*ptr) + { + case '[': + if (brace) + mmerror(PARSE_ERROR, ET_FATAL, "multidimensional arrays for simple data types are not supported"); + brace_open++; + break; + case ']': + brace_open--; + if (brace_open == 0) + brace = true; + break; + case '\t': + case ' ': + break; + default: + if (brace_open == 0) + brace = false; + break; + } + } + (yyval.str) = (yyvsp[(1) - (1)].str); + ;} + break; + + case 2622: + +/* Line 1455 of yacc.c */ +#line 14272 "preproc.y" + { (yyval.str) = make_name(); ;} + break; + + case 2623: + +/* Line 1455 of yacc.c */ +#line 14274 "preproc.y" + { (yyval.str) = make_name(); ;} + break; + + case 2624: + +/* Line 1455 of yacc.c */ +#line 14276 "preproc.y" + { (yyval.str) = make_name(); ;} + break; + + case 2625: + +/* Line 1455 of yacc.c */ +#line 14280 "preproc.y" + { + /* could have been input as '' or $$ */ + (yyval.str) = (char *)mm_alloc(strlen((yyvsp[(1) - (1)].str)) + 3); + (yyval.str)[0]='\''; + strcpy((yyval.str)+1, (yyvsp[(1) - (1)].str)); + (yyval.str)[strlen((yyvsp[(1) - (1)].str))+1]='\''; + (yyval.str)[strlen((yyvsp[(1) - (1)].str))+2]='\0'; + free((yyvsp[(1) - (1)].str)); + ;} + break; + + case 2626: + +/* Line 1455 of yacc.c */ +#line 14290 "preproc.y" + { + (yyval.str) = (char *)mm_alloc(strlen((yyvsp[(1) - (1)].str)) + 4); + (yyval.str)[0]='E'; + (yyval.str)[1]='\''; + strcpy((yyval.str)+2, (yyvsp[(1) - (1)].str)); + (yyval.str)[strlen((yyvsp[(1) - (1)].str))+2]='\''; + (yyval.str)[strlen((yyvsp[(1) - (1)].str))+3]='\0'; + free((yyvsp[(1) - (1)].str)); + ;} + break; + + case 2627: + +/* Line 1455 of yacc.c */ +#line 14300 "preproc.y" + { + (yyval.str) = (char *)mm_alloc(strlen((yyvsp[(1) - (1)].str)) + 4); + (yyval.str)[0]='N'; + (yyval.str)[1]='\''; + strcpy((yyval.str)+2, (yyvsp[(1) - (1)].str)); + (yyval.str)[strlen((yyvsp[(1) - (1)].str))+2]='\''; + (yyval.str)[strlen((yyvsp[(1) - (1)].str))+3]='\0'; + free((yyvsp[(1) - (1)].str)); + ;} + break; + + case 2628: + +/* Line 1455 of yacc.c */ +#line 14309 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2629: + +/* Line 1455 of yacc.c */ +#line 14310 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2630: + +/* Line 1455 of yacc.c */ +#line 14313 "preproc.y" + { (yyval.str) = make_name(); ;} + break; + + case 2631: + +/* Line 1455 of yacc.c */ +#line 14315 "preproc.y" + { (yyval.str) = make_name(); ;} + break; + + case 2632: + +/* Line 1455 of yacc.c */ +#line 14316 "preproc.y" + { (yyval.str) = make3_str(mm_strdup("\""), (yyvsp[(1) - (1)].str), mm_strdup("\"")); ;} + break; + + case 2633: + +/* Line 1455 of yacc.c */ +#line 14317 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2634: + +/* Line 1455 of yacc.c */ +#line 14321 "preproc.y" + { (yyval.str) = make3_str(mm_strdup("\""), (yyvsp[(1) - (1)].str), mm_strdup("\"")); ;} + break; + + case 2635: + +/* Line 1455 of yacc.c */ +#line 14323 "preproc.y" + { (yyval.str) = make3_str(mm_strdup("("), (yyvsp[(1) - (1)].str), mm_strdup(")")); ;} + break; + + case 2636: + +/* Line 1455 of yacc.c */ +#line 14330 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2637: + +/* Line 1455 of yacc.c */ +#line 14331 "preproc.y" + { (yyval.str) = mm_strdup("()"); ;} + break; + + case 2638: + +/* Line 1455 of yacc.c */ +#line 14333 "preproc.y" + { (yyval.str) = cat_str(3, mm_strdup("("), (yyvsp[(2) - (3)].str), mm_strdup(")")); ;} + break; + + case 2639: + +/* Line 1455 of yacc.c */ +#line 14336 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2640: + +/* Line 1455 of yacc.c */ +#line 14338 "preproc.y" + { (yyval.str) = cat2_str((yyvsp[(1) - (2)].str), (yyvsp[(2) - (2)].str)); ;} + break; + + case 2641: + +/* Line 1455 of yacc.c */ +#line 14341 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2642: + +/* Line 1455 of yacc.c */ +#line 14342 "preproc.y" + { (yyval.str) = cat_str(3, (yyvsp[(1) - (3)].str), mm_strdup(","), (yyvsp[(3) - (3)].str)); ;} + break; + + case 2643: + +/* Line 1455 of yacc.c */ +#line 14345 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2644: + +/* Line 1455 of yacc.c */ +#line 14346 "preproc.y" + { (yyval.str) = cat_str(3, mm_strdup("{"), (yyvsp[(2) - (3)].str), mm_strdup("}")); ;} + break; + + case 2645: + +/* Line 1455 of yacc.c */ +#line 14349 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2646: + +/* Line 1455 of yacc.c */ +#line 14350 "preproc.y" + { (yyval.str) = mm_strdup("("); ;} + break; + + case 2647: + +/* Line 1455 of yacc.c */ +#line 14351 "preproc.y" + { (yyval.str) = mm_strdup(")"); ;} + break; + + case 2648: + +/* Line 1455 of yacc.c */ +#line 14352 "preproc.y" + { (yyval.str) = mm_strdup(","); ;} + break; + + case 2649: + +/* Line 1455 of yacc.c */ +#line 14353 "preproc.y" + { (yyval.str) = mm_strdup(";"); ;} + break; + + case 2650: + +/* Line 1455 of yacc.c */ +#line 14356 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2651: + +/* Line 1455 of yacc.c */ +#line 14357 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2652: + +/* Line 1455 of yacc.c */ +#line 14358 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2653: + +/* Line 1455 of yacc.c */ +#line 14359 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2654: + +/* Line 1455 of yacc.c */ +#line 14360 "preproc.y" + { (yyval.str) = mm_strdup("*"); ;} + break; + + case 2655: + +/* Line 1455 of yacc.c */ +#line 14361 "preproc.y" + { (yyval.str) = mm_strdup("+"); ;} + break; + + case 2656: + +/* Line 1455 of yacc.c */ +#line 14362 "preproc.y" + { (yyval.str) = mm_strdup("-"); ;} + break; + + case 2657: + +/* Line 1455 of yacc.c */ +#line 14363 "preproc.y" + { (yyval.str) = mm_strdup("/"); ;} + break; + + case 2658: + +/* Line 1455 of yacc.c */ +#line 14364 "preproc.y" + { (yyval.str) = mm_strdup("%"); ;} + break; + + case 2659: + +/* Line 1455 of yacc.c */ +#line 14365 "preproc.y" + { (yyval.str) = mm_strdup("NULL"); ;} + break; + + case 2660: + +/* Line 1455 of yacc.c */ +#line 14366 "preproc.y" + { (yyval.str) = mm_strdup("+="); ;} + break; + + case 2661: + +/* Line 1455 of yacc.c */ +#line 14367 "preproc.y" + { (yyval.str) = mm_strdup("&&"); ;} + break; + + case 2662: + +/* Line 1455 of yacc.c */ +#line 14368 "preproc.y" + { (yyval.str) = make_name(); ;} + break; + + case 2663: + +/* Line 1455 of yacc.c */ +#line 14369 "preproc.y" + { (yyval.str) = mm_strdup("auto"); ;} + break; + + case 2664: + +/* Line 1455 of yacc.c */ +#line 14370 "preproc.y" + { (yyval.str) = mm_strdup("const"); ;} + break; + + case 2665: + +/* Line 1455 of yacc.c */ +#line 14371 "preproc.y" + { (yyval.str) = mm_strdup("--"); ;} + break; + + case 2666: + +/* Line 1455 of yacc.c */ +#line 14372 "preproc.y" + { (yyval.str) = mm_strdup("/="); ;} + break; + + case 2667: + +/* Line 1455 of yacc.c */ +#line 14373 "preproc.y" + { (yyval.str) = mm_strdup(".*"); ;} + break; + + case 2668: + +/* Line 1455 of yacc.c */ +#line 14374 "preproc.y" + { (yyval.str) = mm_strdup("=="); ;} + break; + + case 2669: + +/* Line 1455 of yacc.c */ +#line 14375 "preproc.y" + { (yyval.str) = mm_strdup("extern"); ;} + break; + + case 2670: + +/* Line 1455 of yacc.c */ +#line 14376 "preproc.y" + { (yyval.str) = mm_strdup("++"); ;} + break; + + case 2671: + +/* Line 1455 of yacc.c */ +#line 14377 "preproc.y" + { (yyval.str) = mm_strdup("<<"); ;} + break; + + case 2672: + +/* Line 1455 of yacc.c */ +#line 14378 "preproc.y" + { (yyval.str) = mm_strdup("->"); ;} + break; + + case 2673: + +/* Line 1455 of yacc.c */ +#line 14379 "preproc.y" + { (yyval.str) = mm_strdup("->*"); ;} + break; + + case 2674: + +/* Line 1455 of yacc.c */ +#line 14380 "preproc.y" + { (yyval.str) = mm_strdup("%="); ;} + break; + + case 2675: + +/* Line 1455 of yacc.c */ +#line 14381 "preproc.y" + { (yyval.str) = mm_strdup("*="); ;} + break; + + case 2676: + +/* Line 1455 of yacc.c */ +#line 14382 "preproc.y" + { (yyval.str) = mm_strdup("!="); ;} + break; + + case 2677: + +/* Line 1455 of yacc.c */ +#line 14383 "preproc.y" + { (yyval.str) = mm_strdup("||"); ;} + break; + + case 2678: + +/* Line 1455 of yacc.c */ +#line 14384 "preproc.y" + { (yyval.str) = mm_strdup("register"); ;} + break; + + case 2679: + +/* Line 1455 of yacc.c */ +#line 14385 "preproc.y" + { (yyval.str) = mm_strdup(">>"); ;} + break; + + case 2680: + +/* Line 1455 of yacc.c */ +#line 14386 "preproc.y" + { (yyval.str) = mm_strdup("static"); ;} + break; + + case 2681: + +/* Line 1455 of yacc.c */ +#line 14387 "preproc.y" + { (yyval.str) = mm_strdup("-="); ;} + break; + + case 2682: + +/* Line 1455 of yacc.c */ +#line 14388 "preproc.y" + { (yyval.str) = mm_strdup("typedef"); ;} + break; + + case 2683: + +/* Line 1455 of yacc.c */ +#line 14389 "preproc.y" + { (yyval.str) = mm_strdup("volatile"); ;} + break; + + case 2684: + +/* Line 1455 of yacc.c */ +#line 14390 "preproc.y" + { (yyval.str) = mm_strdup("bool"); ;} + break; + + case 2685: + +/* Line 1455 of yacc.c */ +#line 14391 "preproc.y" + { (yyval.str) = mm_strdup("enum"); ;} + break; + + case 2686: + +/* Line 1455 of yacc.c */ +#line 14392 "preproc.y" + { (yyval.str) = mm_strdup("hour"); ;} + break; + + case 2687: + +/* Line 1455 of yacc.c */ +#line 14393 "preproc.y" + { (yyval.str) = mm_strdup("int"); ;} + break; + + case 2688: + +/* Line 1455 of yacc.c */ +#line 14394 "preproc.y" + { (yyval.str) = mm_strdup("long"); ;} + break; + + case 2689: + +/* Line 1455 of yacc.c */ +#line 14395 "preproc.y" + { (yyval.str) = mm_strdup("minute"); ;} + break; + + case 2690: + +/* Line 1455 of yacc.c */ +#line 14396 "preproc.y" + { (yyval.str) = mm_strdup("month"); ;} + break; + + case 2691: + +/* Line 1455 of yacc.c */ +#line 14397 "preproc.y" + { (yyval.str) = mm_strdup("second"); ;} + break; + + case 2692: + +/* Line 1455 of yacc.c */ +#line 14398 "preproc.y" + { (yyval.str) = mm_strdup("short"); ;} + break; + + case 2693: + +/* Line 1455 of yacc.c */ +#line 14399 "preproc.y" + { (yyval.str) = mm_strdup("signed"); ;} + break; + + case 2694: + +/* Line 1455 of yacc.c */ +#line 14400 "preproc.y" + { (yyval.str) = mm_strdup("struct"); ;} + break; + + case 2695: + +/* Line 1455 of yacc.c */ +#line 14401 "preproc.y" + { (yyval.str) = mm_strdup("unsigned"); ;} + break; + + case 2696: + +/* Line 1455 of yacc.c */ +#line 14402 "preproc.y" + { (yyval.str) = mm_strdup("year"); ;} + break; + + case 2697: + +/* Line 1455 of yacc.c */ +#line 14403 "preproc.y" + { (yyval.str) = mm_strdup("char"); ;} + break; + + case 2698: + +/* Line 1455 of yacc.c */ +#line 14404 "preproc.y" + { (yyval.str) = mm_strdup("float"); ;} + break; + + case 2699: + +/* Line 1455 of yacc.c */ +#line 14405 "preproc.y" + { (yyval.str) = mm_strdup("to"); ;} + break; + + case 2700: + +/* Line 1455 of yacc.c */ +#line 14406 "preproc.y" + { (yyval.str) = mm_strdup("union"); ;} + break; + + case 2701: + +/* Line 1455 of yacc.c */ +#line 14407 "preproc.y" + { (yyval.str) = mm_strdup("varchar"); ;} + break; + + case 2702: + +/* Line 1455 of yacc.c */ +#line 14408 "preproc.y" + { (yyval.str) = mm_strdup("["); ;} + break; + + case 2703: + +/* Line 1455 of yacc.c */ +#line 14409 "preproc.y" + { (yyval.str) = mm_strdup("]"); ;} + break; + + case 2704: + +/* Line 1455 of yacc.c */ +#line 14410 "preproc.y" + { (yyval.str) = mm_strdup("="); ;} + break; + + case 2705: + +/* Line 1455 of yacc.c */ +#line 14411 "preproc.y" + { (yyval.str) = mm_strdup(":"); ;} + break; + + case 2706: + +/* Line 1455 of yacc.c */ +#line 14414 "preproc.y" + { (yyval.str) = (yyvsp[(2) - (2)].str); ;} + break; + + case 2707: + +/* Line 1455 of yacc.c */ +#line 14415 "preproc.y" + { (yyval.str) = (yyvsp[(3) - (3)].str); ;} + break; + + case 2708: + +/* Line 1455 of yacc.c */ +#line 14416 "preproc.y" + { (yyval.str) = mm_strdup("all"); ;} + break; + + case 2709: + +/* Line 1455 of yacc.c */ +#line 14417 "preproc.y" + { (yyval.str) = mm_strdup("all"); ;} + break; + + case 2710: + +/* Line 1455 of yacc.c */ +#line 14420 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2711: + +/* Line 1455 of yacc.c */ +#line 14421 "preproc.y" + { (yyval.str) = cat_str(3, mm_strdup("("), (yyvsp[(2) - (3)].str), mm_strdup(")")); ;} + break; + + case 2712: + +/* Line 1455 of yacc.c */ +#line 14422 "preproc.y" + { (yyval.str) = cat_str(3, (yyvsp[(1) - (3)].str), mm_strdup("+"), (yyvsp[(3) - (3)].str)); ;} + break; + + case 2713: + +/* Line 1455 of yacc.c */ +#line 14423 "preproc.y" + { (yyval.str) = cat_str(3, (yyvsp[(1) - (3)].str), mm_strdup("-"), (yyvsp[(3) - (3)].str)); ;} + break; + + case 2714: + +/* Line 1455 of yacc.c */ +#line 14424 "preproc.y" + { (yyval.str) = cat_str(3, (yyvsp[(1) - (3)].str), mm_strdup("*"), (yyvsp[(3) - (3)].str)); ;} + break; + + case 2715: + +/* Line 1455 of yacc.c */ +#line 14425 "preproc.y" + { (yyval.str) = cat_str(3, (yyvsp[(1) - (3)].str), mm_strdup("/"), (yyvsp[(3) - (3)].str)); ;} + break; + + case 2716: + +/* Line 1455 of yacc.c */ +#line 14426 "preproc.y" + { (yyval.str) = cat_str(3, (yyvsp[(1) - (3)].str), mm_strdup("%"), (yyvsp[(3) - (3)].str)); ;} + break; + + case 2717: + +/* Line 1455 of yacc.c */ +#line 14427 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2718: + +/* Line 1455 of yacc.c */ +#line 14428 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2719: + +/* Line 1455 of yacc.c */ +#line 14431 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 2720: + +/* Line 1455 of yacc.c */ +#line 14432 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 2721: + +/* Line 1455 of yacc.c */ +#line 14433 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 2722: + +/* Line 1455 of yacc.c */ +#line 14434 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 2723: + +/* Line 1455 of yacc.c */ +#line 14435 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 2724: + +/* Line 1455 of yacc.c */ +#line 14438 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 2725: + +/* Line 1455 of yacc.c */ +#line 14439 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2726: + +/* Line 1455 of yacc.c */ +#line 14442 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 2727: + +/* Line 1455 of yacc.c */ +#line 14444 "preproc.y" + { + struct variable *var; + + var = argsinsert->variable; + remove_variable_from_list(&argsinsert, var); + add_variable_to_head(&argsresult, var, &no_indicator); + (yyval.str) = (yyvsp[(1) - (1)].str); + ;} + break; + + case 2728: + +/* Line 1455 of yacc.c */ +#line 14454 "preproc.y" + { (yyval.str) = EMPTY; ;} + break; + + case 2729: + +/* Line 1455 of yacc.c */ +#line 14455 "preproc.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + + +/* Line 1455 of yacc.c */ +#line 51459 "preproc.c" + default: break; + } + YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); + + YYPOPSTACK (yylen); + yylen = 0; + YY_STACK_PRINT (yyss, yyssp); + + *++yyvsp = yyval; + *++yylsp = yyloc; + + /* Now `shift' the result of the reduction. Determine what state + that goes to, based on the state we popped back to and the rule + number reduced by. */ + + yyn = yyr1[yyn]; + + yystate = yypgoto[yyn - YYNTOKENS] + *yyssp; + if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp) + yystate = yytable[yystate]; + else + yystate = yydefgoto[yyn - YYNTOKENS]; + + goto yynewstate; + + +/*------------------------------------. +| yyerrlab -- here on detecting error | +`------------------------------------*/ +yyerrlab: + /* If not already recovering from an error, report this error. */ + if (!yyerrstatus) + { + ++yynerrs; +#if ! YYERROR_VERBOSE + yyerror (YY_("syntax error")); +#else + { + YYSIZE_T yysize = yysyntax_error (0, yystate, yychar); + if (yymsg_alloc < yysize && yymsg_alloc < YYSTACK_ALLOC_MAXIMUM) + { + YYSIZE_T yyalloc = 2 * yysize; + if (! (yysize <= yyalloc && yyalloc <= YYSTACK_ALLOC_MAXIMUM)) + yyalloc = YYSTACK_ALLOC_MAXIMUM; + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); + yymsg = (char *) YYSTACK_ALLOC (yyalloc); + if (yymsg) + yymsg_alloc = yyalloc; + else + { + yymsg = yymsgbuf; + yymsg_alloc = sizeof yymsgbuf; + } + } + + if (0 < yysize && yysize <= yymsg_alloc) + { + (void) yysyntax_error (yymsg, yystate, yychar); + yyerror (yymsg); + } + else + { + yyerror (YY_("syntax error")); + if (yysize != 0) + goto yyexhaustedlab; + } + } +#endif + } + + yyerror_range[0] = yylloc; + + if (yyerrstatus == 3) + { + /* If just tried and failed to reuse lookahead token after an + error, discard it. */ + + if (yychar <= YYEOF) + { + /* Return failure if at end of input. */ + if (yychar == YYEOF) + YYABORT; + } + else + { + yydestruct ("Error: discarding", + yytoken, &yylval, &yylloc); + yychar = YYEMPTY; + } + } + + /* Else will try to reuse lookahead token after shifting the error + token. */ + goto yyerrlab1; + + +/*---------------------------------------------------. +| yyerrorlab -- error raised explicitly by YYERROR. | +`---------------------------------------------------*/ +yyerrorlab: + + /* Pacify compilers like GCC when the user code never invokes + YYERROR and the label yyerrorlab therefore never appears in user + code. */ + if (/*CONSTCOND*/ 0) + goto yyerrorlab; + + yyerror_range[0] = yylsp[1-yylen]; + /* Do not reclaim the symbols of the rule which action triggered + this YYERROR. */ + YYPOPSTACK (yylen); + yylen = 0; + YY_STACK_PRINT (yyss, yyssp); + yystate = *yyssp; + goto yyerrlab1; + + +/*-------------------------------------------------------------. +| yyerrlab1 -- common code for both syntax error and YYERROR. | +`-------------------------------------------------------------*/ +yyerrlab1: + yyerrstatus = 3; /* Each real token shifted decrements this. */ + + for (;;) + { + yyn = yypact[yystate]; + if (yyn != YYPACT_NINF) + { + yyn += YYTERROR; + if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR) + { + yyn = yytable[yyn]; + if (0 < yyn) + break; + } + } + + /* Pop the current state because it cannot handle the error token. */ + if (yyssp == yyss) + YYABORT; + + yyerror_range[0] = *yylsp; + yydestruct ("Error: popping", + yystos[yystate], yyvsp, yylsp); + YYPOPSTACK (1); + yystate = *yyssp; + YY_STACK_PRINT (yyss, yyssp); + } + + *++yyvsp = yylval; + + yyerror_range[1] = yylloc; + /* Using YYLLOC is tempting, but would change the location of + the lookahead. YYLOC is available though. */ + YYLLOC_DEFAULT (yyloc, (yyerror_range - 1), 2); + *++yylsp = yyloc; + + /* Shift the error token. */ + YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp); + + yystate = yyn; + goto yynewstate; + + +/*-------------------------------------. +| yyacceptlab -- YYACCEPT comes here. | +`-------------------------------------*/ +yyacceptlab: + yyresult = 0; + goto yyreturn; + +/*-----------------------------------. +| yyabortlab -- YYABORT comes here. | +`-----------------------------------*/ +yyabortlab: + yyresult = 1; + goto yyreturn; + +#if !defined(yyoverflow) || YYERROR_VERBOSE +/*-------------------------------------------------. +| yyexhaustedlab -- memory exhaustion comes here. | +`-------------------------------------------------*/ +yyexhaustedlab: + yyerror (YY_("memory exhausted")); + yyresult = 2; + /* Fall through. */ +#endif + +yyreturn: + if (yychar != YYEMPTY) + yydestruct ("Cleanup: discarding lookahead", + yytoken, &yylval, &yylloc); + /* Do not reclaim the symbols of the rule which action triggered + this YYABORT or YYACCEPT. */ + YYPOPSTACK (yylen); + YY_STACK_PRINT (yyss, yyssp); + while (yyssp != yyss) + { + yydestruct ("Cleanup: popping", + yystos[*yyssp], yyvsp, yylsp); + YYPOPSTACK (1); + } +#ifndef yyoverflow + if (yyss != yyssa) + YYSTACK_FREE (yyss); +#endif +#if YYERROR_VERBOSE + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); +#endif + /* Make sure YYID is used. */ + return YYID (yyresult); +} + + + +/* Line 1675 of yacc.c */ +#line 14458 "preproc.y" + + +void base_yyerror(const char *error) +{ + /* translator: %s is typically the translation of "syntax error" */ + mmerror(PARSE_ERROR, ET_ERROR, "%s at or near \"%s\"", + _(error), token_start ? token_start : yytext); +} + +void parser_init(void) +{ + /* This function is empty. It only exists for compatibility with the backend parser right now. */ +} + +/* + * Must undefine base_yylex before including pgc.c, since we want it + * to create the function base_yylex not filtered_base_yylex. + */ +#undef base_yylex + +#include "pgc.c" + diff --git a/src/interfaces/ecpg/preproc/preproc.h b/src/interfaces/ecpg/preproc/preproc.h new file mode 100644 index 000000000..94f4094c0 --- /dev/null +++ b/src/interfaces/ecpg/preproc/preproc.h @@ -0,0 +1,582 @@ + +/* A Bison parser, made by GNU Bison 2.4.1. */ + +/* Skeleton interface for Bison's Yacc-like parsers in C + + Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 + Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . */ + +/* As a special exception, you may create a larger work that contains + part or all of the Bison parser skeleton and distribute that work + under terms of your choice, so long as that work isn't itself a + parser generator using the skeleton or a modified version thereof + as a parser skeleton. Alternatively, if you modify or redistribute + the parser skeleton itself, you may (at your option) remove this + special exception, which will cause the skeleton and the resulting + Bison output files to be licensed under the GNU General Public + License without this special exception. + + This special exception was added by the Free Software Foundation in + version 2.2 of Bison. */ + + +/* Tokens. */ +#ifndef YYTOKENTYPE +# define YYTOKENTYPE + /* Put the tokens into the symbol table, so that GDB and other debuggers + know about them. */ + enum yytokentype { + SQL_ALLOCATE = 258, + SQL_AUTOCOMMIT = 259, + SQL_BOOL = 260, + SQL_BREAK = 261, + SQL_CALL = 262, + SQL_CARDINALITY = 263, + SQL_CONNECT = 264, + SQL_COUNT = 265, + SQL_DATETIME_INTERVAL_CODE = 266, + SQL_DATETIME_INTERVAL_PRECISION = 267, + SQL_DESCRIBE = 268, + SQL_DESCRIPTOR = 269, + SQL_DISCONNECT = 270, + SQL_FOUND = 271, + SQL_FREE = 272, + SQL_GET = 273, + SQL_GO = 274, + SQL_GOTO = 275, + SQL_IDENTIFIED = 276, + SQL_INDICATOR = 277, + SQL_KEY_MEMBER = 278, + SQL_LENGTH = 279, + SQL_LONG = 280, + SQL_NULLABLE = 281, + SQL_OCTET_LENGTH = 282, + SQL_OPEN = 283, + SQL_OUTPUT = 284, + SQL_REFERENCE = 285, + SQL_RETURNED_LENGTH = 286, + SQL_RETURNED_OCTET_LENGTH = 287, + SQL_SCALE = 288, + SQL_SECTION = 289, + SQL_SHORT = 290, + SQL_SIGNED = 291, + SQL_SQL = 292, + SQL_SQLERROR = 293, + SQL_SQLPRINT = 294, + SQL_SQLWARNING = 295, + SQL_START = 296, + SQL_STOP = 297, + SQL_STRUCT = 298, + SQL_UNSIGNED = 299, + SQL_VAR = 300, + SQL_WHENEVER = 301, + S_ADD = 302, + S_AND = 303, + S_ANYTHING = 304, + S_AUTO = 305, + S_CONST = 306, + S_DEC = 307, + S_DIV = 308, + S_DOTPOINT = 309, + S_EQUAL = 310, + S_EXTERN = 311, + S_INC = 312, + S_LSHIFT = 313, + S_MEMPOINT = 314, + S_MEMBER = 315, + S_MOD = 316, + S_MUL = 317, + S_NEQUAL = 318, + S_OR = 319, + S_REGISTER = 320, + S_RSHIFT = 321, + S_STATIC = 322, + S_SUB = 323, + S_VOLATILE = 324, + S_TYPEDEF = 325, + CSTRING = 326, + CVARIABLE = 327, + CPP_LINE = 328, + IP = 329, + DOLCONST = 330, + ECONST = 331, + NCONST = 332, + UCONST = 333, + UIDENT = 334, + IDENT = 335, + FCONST = 336, + SCONST = 337, + BCONST = 338, + XCONST = 339, + Op = 340, + ICONST = 341, + PARAM = 342, + TYPECAST = 343, + DOT_DOT = 344, + COLON_EQUALS = 345, + ABORT_P = 346, + ABSOLUTE_P = 347, + ACCESS = 348, + ACTION = 349, + ADD_P = 350, + ADMIN = 351, + AFTER = 352, + AGGREGATE = 353, + ALL = 354, + ALSO = 355, + ALTER = 356, + ALWAYS = 357, + ANALYSE = 358, + ANALYZE = 359, + AND = 360, + ANY = 361, + ARRAY = 362, + AS = 363, + ASC = 364, + ASSERTION = 365, + ASSIGNMENT = 366, + ASYMMETRIC = 367, + AT = 368, + ATTRIBUTE = 369, + AUTHORIZATION = 370, + BACKWARD = 371, + BEFORE = 372, + BEGIN_P = 373, + BETWEEN = 374, + BIGINT = 375, + BINARY = 376, + BIT = 377, + BOOLEAN_P = 378, + BOTH = 379, + BY = 380, + CACHE = 381, + CALLED = 382, + CASCADE = 383, + CASCADED = 384, + CASE = 385, + CAST = 386, + CATALOG_P = 387, + CHAIN = 388, + CHAR_P = 389, + CHARACTER = 390, + CHARACTERISTICS = 391, + CHECK = 392, + CHECKPOINT = 393, + CLASS = 394, + CLOSE = 395, + CLUSTER = 396, + COALESCE = 397, + COLLATE = 398, + COLLATION = 399, + COLUMN = 400, + COMMENT = 401, + COMMENTS = 402, + COMMIT = 403, + COMMITTED = 404, + CONCURRENTLY = 405, + CONFIGURATION = 406, + CONNECTION = 407, + CONSTRAINT = 408, + CONSTRAINTS = 409, + CONTENT_P = 410, + CONTINUE_P = 411, + CONVERSION_P = 412, + COPY = 413, + COST = 414, + CREATE = 415, + CROSS = 416, + CSV = 417, + CURRENT_P = 418, + CURRENT_CATALOG = 419, + CURRENT_DATE = 420, + CURRENT_ROLE = 421, + CURRENT_SCHEMA = 422, + CURRENT_TIME = 423, + CURRENT_TIMESTAMP = 424, + CURRENT_USER = 425, + CURSOR = 426, + CYCLE = 427, + DATA_P = 428, + DATABASE = 429, + DAY_P = 430, + DEALLOCATE = 431, + DEC = 432, + DECIMAL_P = 433, + DECLARE = 434, + DEFAULT = 435, + DEFAULTS = 436, + DEFERRABLE = 437, + DEFERRED = 438, + DEFINER = 439, + DELETE_P = 440, + DELIMITER = 441, + DELIMITERS = 442, + DESC = 443, + DICTIONARY = 444, + DISABLE_P = 445, + DISCARD = 446, + DISTINCT = 447, + DO = 448, + DOCUMENT_P = 449, + DOMAIN_P = 450, + DOUBLE_P = 451, + DROP = 452, + EACH = 453, + ELSE = 454, + ENABLE_P = 455, + ENCODING = 456, + ENCRYPTED = 457, + END_P = 458, + ENUM_P = 459, + ESCAPE = 460, + EXCEPT = 461, + EXCLUDE = 462, + EXCLUDING = 463, + EXCLUSIVE = 464, + EXECUTE = 465, + EXISTS = 466, + EXPLAIN = 467, + EXTENSION = 468, + EXTERNAL = 469, + EXTRACT = 470, + FALSE_P = 471, + FAMILY = 472, + FETCH = 473, + FIRST_P = 474, + FLOAT_P = 475, + FOLLOWING = 476, + FOR = 477, + FORCE = 478, + FOREIGN = 479, + FORWARD = 480, + FREEZE = 481, + FROM = 482, + FULL = 483, + FUNCTION = 484, + FUNCTIONS = 485, + GLOBAL = 486, + GRANT = 487, + GRANTED = 488, + GREATEST = 489, + GROUP_P = 490, + HANDLER = 491, + HAVING = 492, + HEADER_P = 493, + HOLD = 494, + HOUR_P = 495, + IDENTITY_P = 496, + IF_P = 497, + ILIKE = 498, + IMMEDIATE = 499, + IMMUTABLE = 500, + IMPLICIT_P = 501, + IN_P = 502, + INCLUDING = 503, + INCREMENT = 504, + INDEX = 505, + INDEXES = 506, + INHERIT = 507, + INHERITS = 508, + INITIALLY = 509, + INLINE_P = 510, + INNER_P = 511, + INOUT = 512, + INPUT_P = 513, + INSENSITIVE = 514, + INSERT = 515, + INSTEAD = 516, + INT_P = 517, + INTEGER = 518, + INTERSECT = 519, + INTERVAL = 520, + INTO = 521, + INVOKER = 522, + IS = 523, + ISNULL = 524, + ISOLATION = 525, + JOIN = 526, + KEY = 527, + LABEL = 528, + LANGUAGE = 529, + LARGE_P = 530, + LAST_P = 531, + LC_COLLATE_P = 532, + LC_CTYPE_P = 533, + LEADING = 534, + LEAKPROOF = 535, + LEAST = 536, + LEFT = 537, + LEVEL = 538, + LIKE = 539, + LIMIT = 540, + LISTEN = 541, + LOAD = 542, + LOCAL = 543, + LOCALTIME = 544, + LOCALTIMESTAMP = 545, + LOCATION = 546, + LOCK_P = 547, + MAPPING = 548, + MATCH = 549, + MAXVALUE = 550, + MINUTE_P = 551, + MINVALUE = 552, + MODE = 553, + MONTH_P = 554, + MOVE = 555, + NAME_P = 556, + NAMES = 557, + NATIONAL = 558, + NATURAL = 559, + NCHAR = 560, + NEXT = 561, + NO = 562, + NONE = 563, + NOT = 564, + NOTHING = 565, + NOTIFY = 566, + NOTNULL = 567, + NOWAIT = 568, + NULL_P = 569, + NULLIF = 570, + NULLS_P = 571, + NUMERIC = 572, + OBJECT_P = 573, + OF = 574, + OFF = 575, + OFFSET = 576, + OIDS = 577, + ON = 578, + ONLY = 579, + OPERATOR = 580, + OPTION = 581, + OPTIONS = 582, + OR = 583, + ORDER = 584, + OUT_P = 585, + OUTER_P = 586, + OVER = 587, + OVERLAPS = 588, + OVERLAY = 589, + OWNED = 590, + OWNER = 591, + PARSER = 592, + PARTIAL = 593, + PARTITION = 594, + PASSING = 595, + PASSWORD = 596, + PLACING = 597, + PLANS = 598, + POSITION = 599, + PRECEDING = 600, + PRECISION = 601, + PRESERVE = 602, + PREPARE = 603, + PREPARED = 604, + PRIMARY = 605, + PRIOR = 606, + PRIVILEGES = 607, + PROCEDURAL = 608, + PROCEDURE = 609, + QUOTE = 610, + RANGE = 611, + READ = 612, + REAL = 613, + REASSIGN = 614, + RECHECK = 615, + RECURSIVE = 616, + REF = 617, + REFERENCES = 618, + REINDEX = 619, + RELATIVE_P = 620, + RELEASE = 621, + RENAME = 622, + REPEATABLE = 623, + REPLACE = 624, + REPLICA = 625, + RESET = 626, + RESTART = 627, + RESTRICT = 628, + RETURNING = 629, + RETURNS = 630, + REVOKE = 631, + RIGHT = 632, + ROLE = 633, + ROLLBACK = 634, + ROW = 635, + ROWS = 636, + RULE = 637, + SAVEPOINT = 638, + SCHEMA = 639, + SCROLL = 640, + SEARCH = 641, + SECOND_P = 642, + SECURITY = 643, + SELECT = 644, + SEQUENCE = 645, + SEQUENCES = 646, + SERIALIZABLE = 647, + SERVER = 648, + SESSION = 649, + SESSION_USER = 650, + SET = 651, + SETOF = 652, + SHARE = 653, + SHOW = 654, + SIMILAR = 655, + SIMPLE = 656, + SMALLINT = 657, + SNAPSHOT = 658, + SOME = 659, + STABLE = 660, + STANDALONE_P = 661, + START = 662, + STATEMENT = 663, + STATISTICS = 664, + STDIN = 665, + STDOUT = 666, + STORAGE = 667, + STRICT_P = 668, + STRIP_P = 669, + SUBSTRING = 670, + SYMMETRIC = 671, + SYSID = 672, + SYSTEM_P = 673, + TABLE = 674, + TABLES = 675, + TABLESPACE = 676, + TEMP = 677, + TEMPLATE = 678, + TEMPORARY = 679, + TEXT_P = 680, + THEN = 681, + TIME = 682, + TIMESTAMP = 683, + TO = 684, + TRAILING = 685, + TRANSACTION = 686, + TREAT = 687, + TRIGGER = 688, + TRIM = 689, + TRUE_P = 690, + TRUNCATE = 691, + TRUSTED = 692, + TYPE_P = 693, + TYPES_P = 694, + UNBOUNDED = 695, + UNCOMMITTED = 696, + UNENCRYPTED = 697, + UNION = 698, + UNIQUE = 699, + UNKNOWN = 700, + UNLISTEN = 701, + UNLOGGED = 702, + UNTIL = 703, + UPDATE = 704, + USER = 705, + USING = 706, + VACUUM = 707, + VALID = 708, + VALIDATE = 709, + VALIDATOR = 710, + VALUE_P = 711, + VALUES = 712, + VARCHAR = 713, + VARIADIC = 714, + VARYING = 715, + VERBOSE = 716, + VERSION_P = 717, + VIEW = 718, + VOLATILE = 719, + WHEN = 720, + WHERE = 721, + WHITESPACE_P = 722, + WINDOW = 723, + WITH = 724, + WITHOUT = 725, + WORK = 726, + WRAPPER = 727, + WRITE = 728, + XML_P = 729, + XMLATTRIBUTES = 730, + XMLCONCAT = 731, + XMLELEMENT = 732, + XMLEXISTS = 733, + XMLFOREST = 734, + XMLPARSE = 735, + XMLPI = 736, + XMLROOT = 737, + XMLSERIALIZE = 738, + YEAR_P = 739, + YES_P = 740, + ZONE = 741, + NULLS_FIRST = 742, + NULLS_LAST = 743, + WITH_TIME = 744, + POSTFIXOP = 745, + UMINUS = 746 + }; +#endif + + + +#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED +typedef union YYSTYPE +{ + +/* Line 1676 of yacc.c */ +#line 564 "preproc.y" + + double dval; + char *str; + int ival; + struct when action; + struct index index; + int tagname; + struct this_type type; + enum ECPGttype type_enum; + enum ECPGdtype dtype_enum; + struct fetch_desc descriptor; + struct su_symbol struct_union; + struct prep prep; + + + +/* Line 1676 of yacc.c */ +#line 560 "preproc.h" +} YYSTYPE; +# define YYSTYPE_IS_TRIVIAL 1 +# define yystype YYSTYPE /* obsolescent; will be withdrawn */ +# define YYSTYPE_IS_DECLARED 1 +#endif + +extern YYSTYPE base_yylval; + +#if ! defined YYLTYPE && ! defined YYLTYPE_IS_DECLARED +typedef struct YYLTYPE +{ + int first_line; + int first_column; + int last_line; + int last_column; +} YYLTYPE; +# define yyltype YYLTYPE /* obsolescent; will be withdrawn */ +# define YYLTYPE_IS_DECLARED 1 +# define YYLTYPE_IS_TRIVIAL 1 +#endif + +extern YYLTYPE base_yylloc; + diff --git a/src/interfaces/ecpg/preproc/preproc.y b/src/interfaces/ecpg/preproc/preproc.y new file mode 100644 index 000000000..1bf940cb5 --- /dev/null +++ b/src/interfaces/ecpg/preproc/preproc.y @@ -0,0 +1,14478 @@ +/* header */ +/* src/interfaces/ecpg/preproc/ecpg.header */ + +/* Copyright comment */ +%{ +#include "postgres_fe.h" + +#include "extern.h" +#include "ecpg_config.h" +#include + +/* Location tracking support --- simpler than bison's default */ +#define YYLLOC_DEFAULT(Current, Rhs, N) \ + do { \ + if (N) \ + (Current) = (Rhs)[1]; \ + else \ + (Current) = (Rhs)[0]; \ + } while (0) + +/* + * The %name-prefix option below will make bison call base_yylex, but we + * really want it to call filtered_base_yylex (see parser.c). + */ +#define base_yylex filtered_base_yylex + +/* + * This is only here so the string gets into the POT. Bison uses it + * internally. + */ +#define bison_gettext_dummy gettext_noop("syntax error") + +/* + * Variables containing simple states. + */ +int struct_level = 0; +int braces_open; /* brace level counter */ +char *current_function; +int ecpg_internal_var = 0; +char *connection = NULL; +char *input_filename = NULL; + +static int FoundInto = 0; +static int initializer = 0; +static int pacounter = 1; +static char pacounter_buffer[sizeof(int) * CHAR_BIT * 10 / 3]; /* a rough guess at the size we need */ +static struct this_type actual_type[STRUCT_DEPTH]; +static char *actual_startline[STRUCT_DEPTH]; +static int varchar_counter = 1; + +/* temporarily store struct members while creating the data structure */ +struct ECPGstruct_member *struct_member_list[STRUCT_DEPTH] = { NULL }; + +/* also store struct type so we can do a sizeof() later */ +static char *ECPGstruct_sizeof = NULL; + +/* for forward declarations we have to store some data as well */ +static char *forward_name = NULL; + +struct ECPGtype ecpg_no_indicator = {ECPGt_NO_INDICATOR, NULL, NULL, NULL, {NULL}, 0}; +struct variable no_indicator = {"no_indicator", &ecpg_no_indicator, 0, NULL}; + +struct ECPGtype ecpg_query = {ECPGt_char_variable, NULL, NULL, NULL, {NULL}, 0}; + +/* + * Handle parsing errors and warnings + */ +void +mmerror(int error_code, enum errortype type, const char *error, ...) +{ + va_list ap; + + /* internationalize the error message string */ + error = _(error); + + fprintf(stderr, "%s:%d: ", input_filename, yylineno); + + switch(type) + { + case ET_WARNING: + fprintf(stderr, _("WARNING: ")); + break; + case ET_ERROR: + case ET_FATAL: + fprintf(stderr, _("ERROR: ")); + break; + } + + va_start(ap, error); + vfprintf(stderr, error, ap); + va_end(ap); + + fprintf(stderr, "\n"); + + switch(type) + { + case ET_WARNING: + break; + case ET_ERROR: + ret_value = error_code; + break; + case ET_FATAL: + if (yyin) + fclose(yyin); + if (yyout) + fclose(yyout); + + if (strcmp(output_filename, "-") != 0 && unlink(output_filename) != 0) + fprintf(stderr, _("could not remove output file \"%s\"\n"), output_filename); + exit(error_code); + } +} + +/* + * string concatenation + */ + +static char * +cat2_str(char *str1, char *str2) +{ + char * res_str = (char *)mm_alloc(strlen(str1) + strlen(str2) + 2); + + strcpy(res_str, str1); + if (strlen(str1) != 0 && strlen(str2) != 0) + strcat(res_str, " "); + strcat(res_str, str2); + free(str1); + free(str2); + return(res_str); +} + +static char * +cat_str(int count, ...) +{ + va_list args; + int i; + char *res_str; + + va_start(args, count); + + res_str = va_arg(args, char *); + + /* now add all other strings */ + for (i = 1; i < count; i++) + res_str = cat2_str(res_str, va_arg(args, char *)); + + va_end(args); + + return(res_str); +} + +static char * +make2_str(char *str1, char *str2) +{ + char * res_str = (char *)mm_alloc(strlen(str1) + strlen(str2) + 1); + + strcpy(res_str, str1); + strcat(res_str, str2); + free(str1); + free(str2); + return(res_str); +} + +static char * +make3_str(char *str1, char *str2, char *str3) +{ + char * res_str = (char *)mm_alloc(strlen(str1) + strlen(str2) +strlen(str3) + 1); + + strcpy(res_str, str1); + strcat(res_str, str2); + strcat(res_str, str3); + free(str1); + free(str2); + free(str3); + return(res_str); +} + +/* and the rest */ +static char * +make_name(void) +{ + return mm_strdup(yytext); +} + +static char * +create_questionmarks(char *name, bool array) +{ + struct variable *p = find_variable(name); + int count; + char *result = EMPTY; + + /* In case we have a struct, we have to print as many "?" as there are attributes in the struct + * An array is only allowed together with an element argument + * This is essantially only used for inserts, but using a struct as input parameter is an error anywhere else + * so we don't have to worry here. */ + + if (p->type->type == ECPGt_struct || (array && p->type->type == ECPGt_array && p->type->u.element->type == ECPGt_struct)) + { + struct ECPGstruct_member *m; + + if (p->type->type == ECPGt_struct) + m = p->type->u.members; + else + m = p->type->u.element->u.members; + + for (count = 0; m != NULL; m=m->next, count++); + } + else + count = 1; + + for (; count > 0; count --) + { + sprintf(pacounter_buffer, "$%d", pacounter++); + result = cat_str(3, result, mm_strdup(pacounter_buffer), mm_strdup(" , ")); + } + + /* removed the trailing " ," */ + + result[strlen(result)-3] = '\0'; + return(result); +} + +static char * +adjust_outofscope_cursor_vars(struct cursor *cur) +{ + /* Informix accepts DECLARE with variables that are out of scope when OPEN is called. + * For instance you can DECLARE a cursor in one function, and OPEN/FETCH/CLOSE + * it in another functions. This is very useful for e.g. event-driver programming, + * but may also lead to dangerous programming. The limitation when this is allowed + * and doesn't cause problems have to be documented, like the allocated variables + * must not be realloc()'ed. + * + * We have to change the variables to our own struct and just store the pointer + * instead of the variable. Do it only for local variables, not for globals. + */ + + char *result = EMPTY; + int insert; + + for (insert = 1; insert >= 0; insert--) + { + struct arguments *list; + struct arguments *ptr; + struct arguments *newlist = NULL; + struct variable *newvar, *newind; + + list = (insert ? cur->argsinsert : cur->argsresult); + + for (ptr = list; ptr != NULL; ptr = ptr->next) + { + char var_text[20]; + char *original_var; + bool skip_set_var = false; + bool var_ptr = false; + + /* change variable name to "ECPGget_var()" */ + original_var = ptr->variable->name; + sprintf(var_text, "%d))", ecpg_internal_var); + + /* Don't emit ECPGset_var() calls for global variables */ + if (ptr->variable->brace_level == 0) + { + newvar = ptr->variable; + skip_set_var = true; + } + else if ((ptr->variable->type->type == ECPGt_char_variable) + && (strncmp(ptr->variable->name, "ECPGprepared_statement", strlen("ECPGprepared_statement")) == 0)) + { + newvar = ptr->variable; + skip_set_var = true; + } + else if ((ptr->variable->type->type != ECPGt_varchar + && ptr->variable->type->type != ECPGt_char + && ptr->variable->type->type != ECPGt_unsigned_char + && ptr->variable->type->type != ECPGt_string) + && atoi(ptr->variable->type->size) > 1) + { + newvar = new_variable(cat_str(4, mm_strdup("("), + mm_strdup(ecpg_type_name(ptr->variable->type->u.element->type)), + mm_strdup(" *)(ECPGget_var("), + mm_strdup(var_text)), + ECPGmake_array_type(ECPGmake_simple_type(ptr->variable->type->u.element->type, + mm_strdup("1"), + ptr->variable->type->u.element->counter), + ptr->variable->type->size), + 0); + } + else if ((ptr->variable->type->type == ECPGt_varchar + || ptr->variable->type->type == ECPGt_char + || ptr->variable->type->type == ECPGt_unsigned_char + || ptr->variable->type->type == ECPGt_string) + && atoi(ptr->variable->type->size) > 1) + { + newvar = new_variable(cat_str(4, mm_strdup("("), + mm_strdup(ecpg_type_name(ptr->variable->type->type)), + mm_strdup(" *)(ECPGget_var("), + mm_strdup(var_text)), + ECPGmake_simple_type(ptr->variable->type->type, + ptr->variable->type->size, + ptr->variable->type->counter), + 0); + if (ptr->variable->type->type == ECPGt_varchar) + var_ptr = true; + } + else if (ptr->variable->type->type == ECPGt_struct + || ptr->variable->type->type == ECPGt_union) + { + newvar = new_variable(cat_str(5, mm_strdup("(*("), + mm_strdup(ptr->variable->type->type_name), + mm_strdup(" *)(ECPGget_var("), + mm_strdup(var_text), + mm_strdup(")")), + ECPGmake_struct_type(ptr->variable->type->u.members, + ptr->variable->type->type, + ptr->variable->type->type_name, + ptr->variable->type->struct_sizeof), + 0); + var_ptr = true; + } + else if (ptr->variable->type->type == ECPGt_array) + { + if (ptr->variable->type->u.element->type == ECPGt_struct + || ptr->variable->type->u.element->type == ECPGt_union) + { + newvar = new_variable(cat_str(5, mm_strdup("(*("), + mm_strdup(ptr->variable->type->u.element->type_name), + mm_strdup(" *)(ECPGget_var("), + mm_strdup(var_text), + mm_strdup(")")), + ECPGmake_struct_type(ptr->variable->type->u.element->u.members, + ptr->variable->type->u.element->type, + ptr->variable->type->u.element->type_name, + ptr->variable->type->u.element->struct_sizeof), + 0); + } + else + { + newvar = new_variable(cat_str(4, mm_strdup("("), + mm_strdup(ecpg_type_name(ptr->variable->type->type)), + mm_strdup(" *)(ECPGget_var("), + mm_strdup(var_text)), + ECPGmake_array_type(ECPGmake_simple_type(ptr->variable->type->u.element->type, + ptr->variable->type->u.element->size, + ptr->variable->type->u.element->counter), + ptr->variable->type->size), + 0); + var_ptr = true; + } + } + else + { + newvar = new_variable(cat_str(4, mm_strdup("*("), + mm_strdup(ecpg_type_name(ptr->variable->type->type)), + mm_strdup(" *)(ECPGget_var("), + mm_strdup(var_text)), + ECPGmake_simple_type(ptr->variable->type->type, + ptr->variable->type->size, + ptr->variable->type->counter), + 0); + var_ptr = true; + } + + /* create call to "ECPGset_var(, , . )" */ + if (!skip_set_var) + { + sprintf(var_text, "%d, %s", ecpg_internal_var++, var_ptr ? "&(" : "("); + result = cat_str(5, result, mm_strdup("ECPGset_var("), + mm_strdup(var_text), mm_strdup(original_var), + mm_strdup("), __LINE__);\n")); + } + + /* now the indicator if there is one and it's not a global variable */ + if ((ptr->indicator->type->type == ECPGt_NO_INDICATOR) || (ptr->indicator->brace_level == 0)) + { + newind = ptr->indicator; + } + else + { + /* change variable name to "ECPGget_var()" */ + original_var = ptr->indicator->name; + sprintf(var_text, "%d))", ecpg_internal_var); + var_ptr = false; + + if (ptr->indicator->type->type == ECPGt_struct + || ptr->indicator->type->type == ECPGt_union) + { + newind = new_variable(cat_str(5, mm_strdup("(*("), + mm_strdup(ptr->indicator->type->type_name), + mm_strdup(" *)(ECPGget_var("), + mm_strdup(var_text), + mm_strdup(")")), + ECPGmake_struct_type(ptr->indicator->type->u.members, + ptr->indicator->type->type, + ptr->indicator->type->type_name, + ptr->indicator->type->struct_sizeof), + 0); + var_ptr = true; + } + else if (ptr->indicator->type->type == ECPGt_array) + { + if (ptr->indicator->type->u.element->type == ECPGt_struct + || ptr->indicator->type->u.element->type == ECPGt_union) + { + newind = new_variable(cat_str(5, mm_strdup("(*("), + mm_strdup(ptr->indicator->type->u.element->type_name), + mm_strdup(" *)(ECPGget_var("), + mm_strdup(var_text), + mm_strdup(")")), + ECPGmake_struct_type(ptr->indicator->type->u.element->u.members, + ptr->indicator->type->u.element->type, + ptr->indicator->type->u.element->type_name, + ptr->indicator->type->u.element->struct_sizeof), + 0); + } + else + { + newind = new_variable(cat_str(4, mm_strdup("("), + mm_strdup(ecpg_type_name(ptr->indicator->type->u.element->type)), + mm_strdup(" *)(ECPGget_var("), mm_strdup(var_text)), + ECPGmake_array_type(ECPGmake_simple_type(ptr->indicator->type->u.element->type, + ptr->indicator->type->u.element->size, + ptr->indicator->type->u.element->counter), + ptr->indicator->type->size), + 0); + var_ptr = true; + } + } + else if (atoi(ptr->indicator->type->size) > 1) + { + newind = new_variable(cat_str(4, mm_strdup("("), + mm_strdup(ecpg_type_name(ptr->indicator->type->type)), + mm_strdup(" *)(ECPGget_var("), + mm_strdup(var_text)), + ECPGmake_simple_type(ptr->indicator->type->type, + ptr->indicator->type->size, + ptr->variable->type->counter), + 0); + } + else + { + newind = new_variable(cat_str(4, mm_strdup("*("), + mm_strdup(ecpg_type_name(ptr->indicator->type->type)), + mm_strdup(" *)(ECPGget_var("), + mm_strdup(var_text)), + ECPGmake_simple_type(ptr->indicator->type->type, + ptr->indicator->type->size, + ptr->variable->type->counter), + 0); + var_ptr = true; + } + + /* create call to "ECPGset_var(, . )" */ + sprintf(var_text, "%d, %s", ecpg_internal_var++, var_ptr ? "&(" : "("); + result = cat_str(5, result, mm_strdup("ECPGset_var("), + mm_strdup(var_text), mm_strdup(original_var), + mm_strdup("), __LINE__);\n")); + } + + add_variable_to_tail(&newlist, newvar, newind); + } + + if (insert) + cur->argsinsert_oos = newlist; + else + cur->argsresult_oos = newlist; + } + + return result; +} + +/* This tests whether the cursor was declared and opened in the same function. */ +#define SAMEFUNC(cur) \ + ((cur->function == NULL) || \ + (cur->function != NULL && strcmp(cur->function, current_function) == 0)) + +static struct cursor * +add_additional_variables(char *name, bool insert) +{ + struct cursor *ptr; + struct arguments *p; + int (* strcmp_fn)(const char *, const char *) = (name[0] == ':' ? strcmp : pg_strcasecmp); + + for (ptr = cur; ptr != NULL; ptr=ptr->next) + { + if (strcmp_fn(ptr->name, name) == 0) + break; + } + + if (ptr == NULL) + { + mmerror(PARSE_ERROR, ET_ERROR, "cursor \"%s\" does not exist", name); + return NULL; + } + + if (insert) + { + /* add all those input variables that were given earlier + * note that we have to append here but have to keep the existing order */ + for (p = (SAMEFUNC(ptr) ? ptr->argsinsert : ptr->argsinsert_oos); p; p = p->next) + add_variable_to_tail(&argsinsert, p->variable, p->indicator); + } + + /* add all those output variables that were given earlier */ + for (p = (SAMEFUNC(ptr) ? ptr->argsresult : ptr->argsresult_oos); p; p = p->next) + add_variable_to_tail(&argsresult, p->variable, p->indicator); + + return ptr; +} + +static void +add_typedef(char *name, char *dimension, char *length, enum ECPGttype type_enum, + char *type_dimension, char *type_index, int initializer, int array) +{ + /* add entry to list */ + struct typedefs *ptr, *this; + + if ((type_enum == ECPGt_struct || + type_enum == ECPGt_union) && + initializer == 1) + mmerror(PARSE_ERROR, ET_ERROR, "initializer not allowed in type definition"); + else if (INFORMIX_MODE && strcmp(name, "string") == 0) + mmerror(PARSE_ERROR, ET_ERROR, "type name \"string\" is reserved in Informix mode"); + else + { + for (ptr = types; ptr != NULL; ptr = ptr->next) + { + if (strcmp(name, ptr->name) == 0) + /* re-definition is a bug */ + mmerror(PARSE_ERROR, ET_ERROR, "type \"%s\" is already defined", name); + } + adjust_array(type_enum, &dimension, &length, type_dimension, type_index, array, true); + + this = (struct typedefs *) mm_alloc(sizeof(struct typedefs)); + + /* initial definition */ + this->next = types; + this->name = name; + this->brace_level = braces_open; + this->type = (struct this_type *) mm_alloc(sizeof(struct this_type)); + this->type->type_enum = type_enum; + this->type->type_str = mm_strdup(name); + this->type->type_dimension = dimension; /* dimension of array */ + this->type->type_index = length; /* length of string */ + this->type->type_sizeof = ECPGstruct_sizeof; + this->struct_member_list = (type_enum == ECPGt_struct || type_enum == ECPGt_union) ? + ECPGstruct_member_dup(struct_member_list[struct_level]) : NULL; + + if (type_enum != ECPGt_varchar && + type_enum != ECPGt_char && + type_enum != ECPGt_unsigned_char && + type_enum != ECPGt_string && + atoi(this->type->type_index) >= 0) + mmerror(PARSE_ERROR, ET_ERROR, "multidimensional arrays for simple data types are not supported"); + + types = this; + } +} +%} + +%expect 0 +%name-prefix="base_yy" +%locations + +%union { + double dval; + char *str; + int ival; + struct when action; + struct index index; + int tagname; + struct this_type type; + enum ECPGttype type_enum; + enum ECPGdtype dtype_enum; + struct fetch_desc descriptor; + struct su_symbol struct_union; + struct prep prep; +} +/* tokens */ +/* src/interfaces/ecpg/preproc/ecpg.tokens */ + +/* special embedded SQL tokens */ +%token SQL_ALLOCATE SQL_AUTOCOMMIT SQL_BOOL SQL_BREAK + SQL_CALL SQL_CARDINALITY SQL_CONNECT + SQL_COUNT + SQL_DATETIME_INTERVAL_CODE + SQL_DATETIME_INTERVAL_PRECISION SQL_DESCRIBE + SQL_DESCRIPTOR SQL_DISCONNECT SQL_FOUND + SQL_FREE SQL_GET SQL_GO SQL_GOTO SQL_IDENTIFIED + SQL_INDICATOR SQL_KEY_MEMBER SQL_LENGTH + SQL_LONG SQL_NULLABLE SQL_OCTET_LENGTH + SQL_OPEN SQL_OUTPUT SQL_REFERENCE + SQL_RETURNED_LENGTH SQL_RETURNED_OCTET_LENGTH SQL_SCALE + SQL_SECTION SQL_SHORT SQL_SIGNED SQL_SQL SQL_SQLERROR + SQL_SQLPRINT SQL_SQLWARNING SQL_START SQL_STOP + SQL_STRUCT SQL_UNSIGNED SQL_VAR SQL_WHENEVER + +/* C tokens */ +%token S_ADD S_AND S_ANYTHING S_AUTO S_CONST S_DEC S_DIV + S_DOTPOINT S_EQUAL S_EXTERN S_INC S_LSHIFT S_MEMPOINT + S_MEMBER S_MOD S_MUL S_NEQUAL S_OR S_REGISTER S_RSHIFT + S_STATIC S_SUB S_VOLATILE + S_TYPEDEF + +%token CSTRING CVARIABLE CPP_LINE IP +%token DOLCONST ECONST NCONST UCONST UIDENT +/* types */ +%type stmt +%type CreateRoleStmt +%type opt_with +%type OptRoleList +%type AlterOptRoleList +%type AlterOptRoleElem +%type CreateOptRoleElem +%type CreateUserStmt +%type AlterRoleStmt +%type opt_in_database +%type AlterRoleSetStmt +%type AlterUserStmt +%type AlterUserSetStmt +%type DropRoleStmt +%type DropUserStmt +%type CreateGroupStmt +%type AlterGroupStmt +%type add_drop +%type DropGroupStmt +%type CreateSchemaStmt +%type OptSchemaName +%type OptSchemaEltList +%type schema_stmt +%type VariableSetStmt +%type set_rest +%type set_rest_more +%type var_name +%type var_list +%type var_value +%type iso_level +%type opt_boolean_or_string +%type zone_value +%type opt_encoding +%type ColId_or_Sconst +%type VariableResetStmt +%type SetResetClause +%type FunctionSetResetClause +%type VariableShowStmt +%type ConstraintsSetStmt +%type constraints_set_list +%type constraints_set_mode +%type CheckPointStmt +%type DiscardStmt +%type AlterTableStmt +%type alter_table_cmds +%type alter_table_cmd +%type alter_column_default +%type opt_drop_behavior +%type opt_collate_clause +%type alter_using +%type reloptions +%type opt_reloptions +%type reloption_list +%type reloption_elem +%type AlterCompositeTypeStmt +%type alter_type_cmds +%type alter_type_cmd +%type ClosePortalStmt +%type CopyStmt +%type copy_from +%type copy_file_name +%type copy_options +%type copy_opt_list +%type copy_opt_item +%type opt_binary +%type opt_oids +%type copy_delimiter +%type opt_using +%type copy_generic_opt_list +%type copy_generic_opt_elem +%type copy_generic_opt_arg +%type copy_generic_opt_arg_list +%type copy_generic_opt_arg_list_item +%type CreateStmt +%type OptTemp +%type OptTableElementList +%type OptTypedTableElementList +%type TableElementList +%type TypedTableElementList +%type TableElement +%type TypedTableElement +%type columnDef +%type columnOptions +%type ColQualList +%type ColConstraint +%type ColConstraintElem +%type ConstraintAttr +%type TableLikeClause +%type TableLikeOptionList +%type TableLikeOption +%type TableConstraint +%type ConstraintElem +%type opt_no_inherit +%type opt_column_list +%type columnList +%type columnElem +%type key_match +%type ExclusionConstraintList +%type ExclusionConstraintElem +%type ExclusionWhereClause +%type key_actions +%type key_update +%type key_delete +%type key_action +%type OptInherit +%type OptWith +%type OnCommitOption +%type OptTableSpace +%type OptConsTableSpace +%type ExistingIndex +%type create_as_target +%type opt_with_data +%type CreateSeqStmt +%type AlterSeqStmt +%type OptSeqOptList +%type SeqOptList +%type SeqOptElem +%type opt_by +%type NumericOnly +%type NumericOnly_list +%type CreatePLangStmt +%type opt_trusted +%type handler_name +%type opt_inline_handler +%type validator_clause +%type opt_validator +%type DropPLangStmt +%type opt_procedural +%type CreateTableSpaceStmt +%type OptTableSpaceOwner +%type DropTableSpaceStmt +%type CreateExtensionStmt +%type create_extension_opt_list +%type create_extension_opt_item +%type AlterExtensionStmt +%type alter_extension_opt_list +%type alter_extension_opt_item +%type AlterExtensionContentsStmt +%type CreateFdwStmt +%type fdw_option +%type fdw_options +%type opt_fdw_options +%type DropFdwStmt +%type AlterFdwStmt +%type create_generic_options +%type generic_option_list +%type alter_generic_options +%type alter_generic_option_list +%type alter_generic_option_elem +%type generic_option_elem +%type generic_option_name +%type generic_option_arg +%type CreateForeignServerStmt +%type opt_type +%type foreign_server_version +%type opt_foreign_server_version +%type DropForeignServerStmt +%type AlterForeignServerStmt +%type CreateForeignTableStmt +%type OptForeignTableElementList +%type ForeignTableElementList +%type ForeignTableElement +%type AlterForeignTableStmt +%type CreateUserMappingStmt +%type auth_ident +%type DropUserMappingStmt +%type AlterUserMappingStmt +%type CreateTrigStmt +%type TriggerActionTime +%type TriggerEvents +%type TriggerOneEvent +%type TriggerForSpec +%type TriggerForOptEach +%type TriggerForType +%type TriggerWhen +%type TriggerFuncArgs +%type TriggerFuncArg +%type OptConstrFromTable +%type ConstraintAttributeSpec +%type ConstraintAttributeElem +%type DropTrigStmt +%type CreateAssertStmt +%type DropAssertStmt +%type DefineStmt +%type definition +%type def_list +%type def_elem +%type def_arg +%type aggr_args +%type old_aggr_definition +%type old_aggr_list +%type old_aggr_elem +%type opt_enum_val_list +%type enum_val_list +%type AlterEnumStmt +%type CreateOpClassStmt +%type opclass_item_list +%type opclass_item +%type opt_default +%type opt_opfamily +%type opclass_purpose +%type opt_recheck +%type CreateOpFamilyStmt +%type AlterOpFamilyStmt +%type opclass_drop_list +%type opclass_drop +%type DropOpClassStmt +%type DropOpFamilyStmt +%type DropOwnedStmt +%type ReassignOwnedStmt +%type DropStmt +%type drop_type +%type any_name_list +%type any_name +%type attrs +%type TruncateStmt +%type opt_restart_seqs +%type CommentStmt +%type comment_type +%type comment_text +%type SecLabelStmt +%type opt_provider +%type security_label_type +%type security_label +%type FetchStmt +%type fetch_args +%type from_in +%type opt_from_in +%type GrantStmt +%type RevokeStmt +%type privileges +%type privilege_list +%type privilege +%type privilege_target +%type grantee_list +%type grantee +%type opt_grant_grant_option +%type function_with_argtypes_list +%type function_with_argtypes +%type GrantRoleStmt +%type RevokeRoleStmt +%type opt_grant_admin_option +%type opt_granted_by +%type AlterDefaultPrivilegesStmt +%type DefACLOptionList +%type DefACLOption +%type DefACLAction +%type defacl_privilege_target +%type IndexStmt +%type opt_unique +%type opt_concurrently +%type opt_index_name +%type access_method_clause +%type index_params +%type index_elem +%type opt_collate +%type opt_class +%type opt_asc_desc +%type opt_nulls_order +%type CreateFunctionStmt +%type opt_or_replace +%type func_args +%type func_args_list +%type func_args_with_defaults +%type func_args_with_defaults_list +%type func_arg +%type arg_class +%type param_name +%type func_return +%type func_type +%type func_arg_with_default +%type createfunc_opt_list +%type common_func_opt_item +%type createfunc_opt_item +%type func_as +%type opt_definition +%type table_func_column +%type table_func_column_list +%type AlterFunctionStmt +%type alterfunc_opt_list +%type opt_restrict +%type RemoveFuncStmt +%type RemoveAggrStmt +%type RemoveOperStmt +%type oper_argtypes +%type any_operator +%type DoStmt +%type dostmt_opt_list +%type dostmt_opt_item +%type CreateCastStmt +%type cast_context +%type DropCastStmt +%type opt_if_exists +%type ReindexStmt +%type reindex_type +%type opt_force +%type RenameStmt +%type opt_column +%type opt_set_data +%type AlterObjectSchemaStmt +%type AlterOwnerStmt +%type RuleStmt +%type RuleActionList +%type RuleActionMulti +%type RuleActionStmt +%type RuleActionStmtOrEmpty +%type event +%type opt_instead +%type DropRuleStmt +%type NotifyStmt +%type notify_payload +%type ListenStmt +%type UnlistenStmt +%type TransactionStmt +%type opt_transaction +%type transaction_mode_item +%type transaction_mode_list +%type transaction_mode_list_or_empty +%type ViewStmt +%type opt_check_option +%type LoadStmt +%type CreatedbStmt +%type createdb_opt_list +%type createdb_opt_item +%type opt_equal +%type AlterDatabaseStmt +%type AlterDatabaseSetStmt +%type alterdb_opt_list +%type alterdb_opt_item +%type DropdbStmt +%type CreateDomainStmt +%type AlterDomainStmt +%type opt_as +%type AlterTSDictionaryStmt +%type AlterTSConfigurationStmt +%type CreateConversionStmt +%type ClusterStmt +%type cluster_index_specification +%type VacuumStmt +%type vacuum_option_list +%type vacuum_option_elem +%type AnalyzeStmt +%type analyze_keyword +%type opt_verbose +%type opt_full +%type opt_freeze +%type opt_name_list +%type ExplainStmt +%type ExplainableStmt +%type explain_option_list +%type explain_option_elem +%type explain_option_name +%type explain_option_arg +%type PrepareStmt +%type prep_type_clause +%type PreparableStmt +%type ExecuteStmt +%type execute_param_clause +%type InsertStmt +%type insert_rest +%type insert_column_list +%type insert_column_item +%type returning_clause +%type DeleteStmt +%type using_clause +%type LockStmt +%type opt_lock +%type lock_type +%type opt_nowait +%type UpdateStmt +%type set_clause_list +%type set_clause +%type single_set_clause +%type multiple_set_clause +%type set_target +%type set_target_list +%type DeclareCursorStmt +%type cursor_name +%type cursor_options +%type opt_hold +%type SelectStmt +%type select_with_parens +%type select_no_parens +%type select_clause +%type simple_select +%type with_clause +%type cte_list +%type common_table_expr +%type opt_with_clause +%type into_clause +%type OptTempTableName +%type opt_table +%type opt_all +%type opt_distinct +%type opt_sort_clause +%type sort_clause +%type sortby_list +%type sortby +%type select_limit +%type opt_select_limit +%type limit_clause +%type offset_clause +%type select_limit_value +%type select_offset_value +%type opt_select_fetch_first_value +%type select_offset_value2 +%type row_or_rows +%type first_or_next +%type group_clause +%type having_clause +%type for_locking_clause +%type opt_for_locking_clause +%type for_locking_items +%type for_locking_item +%type locked_rels_list +%type values_clause +%type from_clause +%type from_list +%type table_ref +%type joined_table +%type alias_clause +%type join_type +%type join_outer +%type join_qual +%type relation_expr +%type relation_expr_list +%type relation_expr_opt_alias +%type func_table +%type where_clause +%type where_or_current_clause +%type OptTableFuncElementList +%type TableFuncElementList +%type TableFuncElement +%type Typename +%type opt_array_bounds +%type SimpleTypename +%type ConstTypename +%type GenericType +%type opt_type_modifiers +%type Numeric +%type opt_float +%type Bit +%type ConstBit +%type BitWithLength +%type BitWithoutLength +%type Character +%type ConstCharacter +%type CharacterWithLength +%type CharacterWithoutLength +%type character +%type opt_varying +%type opt_charset +%type ConstDatetime +%type ConstInterval +%type opt_timezone +%type opt_interval +%type interval_second +%type a_expr +%type b_expr +%type c_expr +%type func_expr +%type xml_root_version +%type opt_xml_root_standalone +%type xml_attributes +%type xml_attribute_list +%type xml_attribute_el +%type document_or_content +%type xml_whitespace_option +%type xmlexists_argument +%type window_clause +%type window_definition_list +%type window_definition +%type over_clause +%type window_specification +%type opt_existing_window_name +%type opt_partition_clause +%type opt_frame_clause +%type frame_extent +%type frame_bound +%type row +%type sub_type +%type all_Op +%type MathOp +%type qual_Op +%type qual_all_Op +%type subquery_Op +%type expr_list +%type func_arg_list +%type func_arg_expr +%type type_list +%type array_expr +%type array_expr_list +%type extract_list +%type extract_arg +%type overlay_list +%type overlay_placing +%type position_list +%type substr_list +%type substr_from +%type substr_for +%type trim_list +%type in_expr +%type case_expr +%type when_clause_list +%type when_clause +%type case_default +%type case_arg +%type columnref +%type indirection_el +%type indirection +%type opt_indirection +%type opt_asymmetric +%type ctext_expr +%type ctext_expr_list +%type ctext_row +%type target_list +%type target_el +%type qualified_name_list +%type qualified_name +%type name_list +%type name +%type database_name +%type access_method +%type attr_name +%type index_name +%type file_name +%type func_name +%type AexprConst +%type Iconst +%type RoleId +%type SignedIconst +%type unreserved_keyword +%type col_name_keyword +%type type_func_name_keyword +%type reserved_keyword +/* ecpgtype */ +/* src/interfaces/ecpg/preproc/ecpg.type */ +%type ECPGAllocateDescr +%type ECPGCKeywords +%type ECPGColId +%type ECPGColLabel +%type ECPGColLabelCommon +%type ECPGConnect +%type ECPGCursorStmt +%type ECPGDeallocateDescr +%type ECPGDeclaration +%type ECPGDeclare +%type ECPGDescribe +%type ECPGDisconnect +%type ECPGExecuteImmediateStmt +%type ECPGFree +%type ECPGGetDescHeaderItem +%type ECPGGetDescItem +%type ECPGGetDescriptorHeader +%type ECPGKeywords +%type ECPGKeywords_rest +%type ECPGKeywords_vanames +%type ECPGOpen +%type ECPGSetAutocommit +%type ECPGSetConnection +%type ECPGSetDescHeaderItem +%type ECPGSetDescItem +%type ECPGSetDescriptorHeader +%type ECPGTypeName +%type ECPGTypedef +%type ECPGVar +%type ECPGVarDeclaration +%type ECPGWhenever +%type ECPGunreserved_interval +%type UsingConst +%type UsingValue +%type all_unreserved_keyword +%type c_anything +%type c_args +%type c_list +%type c_stuff +%type c_stuff_item +%type c_term +%type c_thing +%type char_variable +%type char_civar +%type civar +%type civarind +%type ColId +%type ColLabel +%type connect_options +%type connection_object +%type connection_target +%type coutputvariable +%type cvariable +%type db_prefix +%type CreateAsStmt +%type DeallocateStmt +%type dis_name +%type ecpg_bconst +%type ecpg_fconst +%type ecpg_ident +%type ecpg_interval +%type ecpg_into +%type ecpg_fetch_into +%type ecpg_param +%type ecpg_sconst +%type ecpg_using +%type ecpg_xconst +%type enum_definition +%type enum_type +%type execstring +%type execute_rest +%type indicator +%type into_descriptor +%type into_sqlda +%type Iresult +%type on_off +%type opt_bit_field +%type opt_connection_name +%type opt_database_name +%type opt_ecpg_fetch_into +%type opt_ecpg_using +%type opt_initializer +%type opt_options +%type opt_output +%type opt_pointer +%type opt_port +%type opt_reference +%type opt_scale +%type opt_server +%type opt_user +%type opt_opt_value +%type ora_user +%type precision +%type prepared_name +%type quoted_ident_stringvar +%type s_struct_union +%type server +%type server_name +%type single_vt_declaration +%type storage_clause +%type storage_declaration +%type storage_modifier +%type struct_union_type +%type struct_union_type_with_symbol +%type symbol +%type type_declaration +%type type_function_name +%type user_name +%type using_descriptor +%type var_declaration +%type var_type_declarations +%type variable +%type variable_declarations +%type variable_list +%type vt_declarations + +%type Op +%type IntConstVar +%type AllConstVar +%type CSTRING +%type CPP_LINE +%type CVARIABLE +%type DOLCONST +%type ECONST +%type NCONST +%type SCONST +%type UCONST +%type UIDENT + +%type s_struct_union_symbol + +%type ECPGGetDescriptor +%type ECPGSetDescriptor + +%type simple_type +%type signed_type +%type unsigned_type + +%type descriptor_item +%type desc_header_item + +%type var_type + +%type action +/* orig_tokens */ + %token IDENT FCONST SCONST BCONST XCONST Op + %token ICONST PARAM + %token TYPECAST DOT_DOT COLON_EQUALS + + + + + + + + + + %token ABORT_P ABSOLUTE_P ACCESS ACTION ADD_P ADMIN AFTER + AGGREGATE ALL ALSO ALTER ALWAYS ANALYSE ANALYZE AND ANY ARRAY AS ASC + ASSERTION ASSIGNMENT ASYMMETRIC AT ATTRIBUTE AUTHORIZATION + + BACKWARD BEFORE BEGIN_P BETWEEN BIGINT BINARY BIT + BOOLEAN_P BOTH BY + + CACHE CALLED CASCADE CASCADED CASE CAST CATALOG_P CHAIN CHAR_P + CHARACTER CHARACTERISTICS CHECK CHECKPOINT CLASS CLOSE + CLUSTER COALESCE COLLATE COLLATION COLUMN COMMENT COMMENTS COMMIT + COMMITTED CONCURRENTLY CONFIGURATION CONNECTION CONSTRAINT CONSTRAINTS + CONTENT_P CONTINUE_P CONVERSION_P COPY COST CREATE + CROSS CSV CURRENT_P + CURRENT_CATALOG CURRENT_DATE CURRENT_ROLE CURRENT_SCHEMA + CURRENT_TIME CURRENT_TIMESTAMP CURRENT_USER CURSOR CYCLE + + DATA_P DATABASE DAY_P DEALLOCATE DEC DECIMAL_P DECLARE DEFAULT DEFAULTS + DEFERRABLE DEFERRED DEFINER DELETE_P DELIMITER DELIMITERS DESC + DICTIONARY DISABLE_P DISCARD DISTINCT DO DOCUMENT_P DOMAIN_P DOUBLE_P DROP + + EACH ELSE ENABLE_P ENCODING ENCRYPTED END_P ENUM_P ESCAPE EXCEPT + EXCLUDE EXCLUDING EXCLUSIVE EXECUTE EXISTS EXPLAIN + EXTENSION EXTERNAL EXTRACT + + FALSE_P FAMILY FETCH FIRST_P FLOAT_P FOLLOWING FOR FORCE FOREIGN FORWARD + FREEZE FROM FULL FUNCTION FUNCTIONS + + GLOBAL GRANT GRANTED GREATEST GROUP_P + + HANDLER HAVING HEADER_P HOLD HOUR_P + + IDENTITY_P IF_P ILIKE IMMEDIATE IMMUTABLE IMPLICIT_P IN_P + INCLUDING INCREMENT INDEX INDEXES INHERIT INHERITS INITIALLY INLINE_P + INNER_P INOUT INPUT_P INSENSITIVE INSERT INSTEAD INT_P INTEGER + INTERSECT INTERVAL INTO INVOKER IS ISNULL ISOLATION + + JOIN + + KEY + + LABEL LANGUAGE LARGE_P LAST_P LC_COLLATE_P LC_CTYPE_P LEADING LEAKPROOF + LEAST LEFT LEVEL LIKE LIMIT LISTEN LOAD LOCAL LOCALTIME LOCALTIMESTAMP + LOCATION LOCK_P + + MAPPING MATCH MAXVALUE MINUTE_P MINVALUE MODE MONTH_P MOVE + + NAME_P NAMES NATIONAL NATURAL NCHAR NEXT NO NONE + NOT NOTHING NOTIFY NOTNULL NOWAIT NULL_P NULLIF + NULLS_P NUMERIC + + OBJECT_P OF OFF OFFSET OIDS ON ONLY OPERATOR OPTION OPTIONS OR + ORDER OUT_P OUTER_P OVER OVERLAPS OVERLAY OWNED OWNER + + PARSER PARTIAL PARTITION PASSING PASSWORD PLACING PLANS POSITION + PRECEDING PRECISION PRESERVE PREPARE PREPARED PRIMARY + PRIOR PRIVILEGES PROCEDURAL PROCEDURE + + QUOTE + + RANGE READ REAL REASSIGN RECHECK RECURSIVE REF REFERENCES REINDEX + RELATIVE_P RELEASE RENAME REPEATABLE REPLACE REPLICA + RESET RESTART RESTRICT RETURNING RETURNS REVOKE RIGHT ROLE ROLLBACK + ROW ROWS RULE + + SAVEPOINT SCHEMA SCROLL SEARCH SECOND_P SECURITY SELECT SEQUENCE SEQUENCES + SERIALIZABLE SERVER SESSION SESSION_USER SET SETOF SHARE + SHOW SIMILAR SIMPLE SMALLINT SNAPSHOT SOME STABLE STANDALONE_P START + STATEMENT STATISTICS STDIN STDOUT STORAGE STRICT_P STRIP_P SUBSTRING + SYMMETRIC SYSID SYSTEM_P + + TABLE TABLES TABLESPACE TEMP TEMPLATE TEMPORARY TEXT_P THEN TIME TIMESTAMP + TO TRAILING TRANSACTION TREAT TRIGGER TRIM TRUE_P + TRUNCATE TRUSTED TYPE_P TYPES_P + + UNBOUNDED UNCOMMITTED UNENCRYPTED UNION UNIQUE UNKNOWN UNLISTEN UNLOGGED + UNTIL UPDATE USER USING + + VACUUM VALID VALIDATE VALIDATOR VALUE_P VALUES VARCHAR VARIADIC VARYING + VERBOSE VERSION_P VIEW VOLATILE + + WHEN WHERE WHITESPACE_P WINDOW WITH WITHOUT WORK WRAPPER WRITE + + XML_P XMLATTRIBUTES XMLCONCAT XMLELEMENT XMLEXISTS XMLFOREST XMLPARSE + XMLPI XMLROOT XMLSERIALIZE + + YEAR_P YES_P + + ZONE + + + + + + + %token NULLS_FIRST NULLS_LAST WITH_TIME + + + + %nonassoc SET + %left UNION EXCEPT + %left INTERSECT + %left OR + %left AND + %right NOT + %right '=' + %nonassoc '<' '>' + %nonassoc LIKE ILIKE SIMILAR + %nonassoc ESCAPE + %nonassoc OVERLAPS + %nonassoc BETWEEN + %nonassoc IN_P + %left POSTFIXOP + + + + + + + + + + + + + + + + + + + + + %nonassoc UNBOUNDED + %nonassoc IDENT +%nonassoc CSTRING +%nonassoc UIDENT NULL_P PARTITION RANGE ROWS PRECEDING FOLLOWING + %left Op OPERATOR + %nonassoc NOTNULL + %nonassoc ISNULL + %nonassoc IS + %left '+' '-' + %left '*' '/' '%' + %left '^' + + %left AT + %left COLLATE + %right UMINUS + %left '[' ']' + %left '(' ')' + %left TYPECAST + %left '.' + + + + + + + + %left JOIN CROSS LEFT FULL RIGHT INNER_P NATURAL + + %right PRESERVE STRIP_P + +%% +prog: statements; +/* rules */ + stmt: + AlterDatabaseStmt + { output_statement($1, 0, ECPGst_normal); } +| AlterDatabaseSetStmt + { output_statement($1, 0, ECPGst_normal); } +| AlterDefaultPrivilegesStmt + { output_statement($1, 0, ECPGst_normal); } +| AlterDomainStmt + { output_statement($1, 0, ECPGst_normal); } +| AlterEnumStmt + { output_statement($1, 0, ECPGst_normal); } +| AlterExtensionStmt + { output_statement($1, 0, ECPGst_normal); } +| AlterExtensionContentsStmt + { output_statement($1, 0, ECPGst_normal); } +| AlterFdwStmt + { output_statement($1, 0, ECPGst_normal); } +| AlterForeignServerStmt + { output_statement($1, 0, ECPGst_normal); } +| AlterForeignTableStmt + { output_statement($1, 0, ECPGst_normal); } +| AlterFunctionStmt + { output_statement($1, 0, ECPGst_normal); } +| AlterGroupStmt + { output_statement($1, 0, ECPGst_normal); } +| AlterObjectSchemaStmt + { output_statement($1, 0, ECPGst_normal); } +| AlterOwnerStmt + { output_statement($1, 0, ECPGst_normal); } +| AlterSeqStmt + { output_statement($1, 0, ECPGst_normal); } +| AlterTableStmt + { output_statement($1, 0, ECPGst_normal); } +| AlterCompositeTypeStmt + { output_statement($1, 0, ECPGst_normal); } +| AlterRoleSetStmt + { output_statement($1, 0, ECPGst_normal); } +| AlterRoleStmt + { output_statement($1, 0, ECPGst_normal); } +| AlterTSConfigurationStmt + { output_statement($1, 0, ECPGst_normal); } +| AlterTSDictionaryStmt + { output_statement($1, 0, ECPGst_normal); } +| AlterUserMappingStmt + { output_statement($1, 0, ECPGst_normal); } +| AlterUserSetStmt + { output_statement($1, 0, ECPGst_normal); } +| AlterUserStmt + { output_statement($1, 0, ECPGst_normal); } +| AnalyzeStmt + { output_statement($1, 0, ECPGst_normal); } +| CheckPointStmt + { output_statement($1, 0, ECPGst_normal); } +| ClosePortalStmt + { + if (INFORMIX_MODE) + { + if (pg_strcasecmp($1+strlen("close "), "database") == 0) + { + if (connection) + mmerror(PARSE_ERROR, ET_ERROR, "AT option not allowed in CLOSE DATABASE statement"); + + fprintf(yyout, "{ ECPGdisconnect(__LINE__, \"CURRENT\");"); + whenever_action(2); + free($1); + break; + } + } + + output_statement($1, 0, ECPGst_normal); + } +| ClusterStmt + { output_statement($1, 0, ECPGst_normal); } +| CommentStmt + { output_statement($1, 0, ECPGst_normal); } +| ConstraintsSetStmt + { output_statement($1, 0, ECPGst_normal); } +| CopyStmt + { output_statement($1, 0, ECPGst_normal); } +| CreateAsStmt + { output_statement($1, 0, ECPGst_normal); } +| CreateAssertStmt + { output_statement($1, 0, ECPGst_normal); } +| CreateCastStmt + { output_statement($1, 0, ECPGst_normal); } +| CreateConversionStmt + { output_statement($1, 0, ECPGst_normal); } +| CreateDomainStmt + { output_statement($1, 0, ECPGst_normal); } +| CreateExtensionStmt + { output_statement($1, 0, ECPGst_normal); } +| CreateFdwStmt + { output_statement($1, 0, ECPGst_normal); } +| CreateForeignServerStmt + { output_statement($1, 0, ECPGst_normal); } +| CreateForeignTableStmt + { output_statement($1, 0, ECPGst_normal); } +| CreateFunctionStmt + { output_statement($1, 0, ECPGst_normal); } +| CreateGroupStmt + { output_statement($1, 0, ECPGst_normal); } +| CreateOpClassStmt + { output_statement($1, 0, ECPGst_normal); } +| CreateOpFamilyStmt + { output_statement($1, 0, ECPGst_normal); } +| AlterOpFamilyStmt + { output_statement($1, 0, ECPGst_normal); } +| CreatePLangStmt + { output_statement($1, 0, ECPGst_normal); } +| CreateSchemaStmt + { output_statement($1, 0, ECPGst_normal); } +| CreateSeqStmt + { output_statement($1, 0, ECPGst_normal); } +| CreateStmt + { output_statement($1, 0, ECPGst_normal); } +| CreateTableSpaceStmt + { output_statement($1, 0, ECPGst_normal); } +| CreateTrigStmt + { output_statement($1, 0, ECPGst_normal); } +| CreateRoleStmt + { output_statement($1, 0, ECPGst_normal); } +| CreateUserStmt + { output_statement($1, 0, ECPGst_normal); } +| CreateUserMappingStmt + { output_statement($1, 0, ECPGst_normal); } +| CreatedbStmt + { output_statement($1, 0, ECPGst_normal); } +| DeallocateStmt + { + output_deallocate_prepare_statement($1); + } +| DeclareCursorStmt + { output_simple_statement($1); } +| DefineStmt + { output_statement($1, 0, ECPGst_normal); } +| DeleteStmt + { output_statement($1, 1, ECPGst_prepnormal); } +| DiscardStmt + { output_statement($1, 1, ECPGst_normal); } +| DoStmt + { output_statement($1, 0, ECPGst_normal); } +| DropAssertStmt + { output_statement($1, 0, ECPGst_normal); } +| DropCastStmt + { output_statement($1, 0, ECPGst_normal); } +| DropFdwStmt + { output_statement($1, 0, ECPGst_normal); } +| DropForeignServerStmt + { output_statement($1, 0, ECPGst_normal); } +| DropGroupStmt + { output_statement($1, 0, ECPGst_normal); } +| DropOpClassStmt + { output_statement($1, 0, ECPGst_normal); } +| DropOpFamilyStmt + { output_statement($1, 0, ECPGst_normal); } +| DropOwnedStmt + { output_statement($1, 0, ECPGst_normal); } +| DropPLangStmt + { output_statement($1, 0, ECPGst_normal); } +| DropRuleStmt + { output_statement($1, 0, ECPGst_normal); } +| DropStmt + { output_statement($1, 0, ECPGst_normal); } +| DropTableSpaceStmt + { output_statement($1, 0, ECPGst_normal); } +| DropTrigStmt + { output_statement($1, 0, ECPGst_normal); } +| DropRoleStmt + { output_statement($1, 0, ECPGst_normal); } +| DropUserStmt + { output_statement($1, 0, ECPGst_normal); } +| DropUserMappingStmt + { output_statement($1, 0, ECPGst_normal); } +| DropdbStmt + { output_statement($1, 0, ECPGst_normal); } +| ExecuteStmt + { output_statement($1, 1, ECPGst_execute); } +| ExplainStmt + { output_statement($1, 0, ECPGst_normal); } +| FetchStmt + { output_statement($1, 1, ECPGst_normal); } +| GrantStmt + { output_statement($1, 0, ECPGst_normal); } +| GrantRoleStmt + { output_statement($1, 0, ECPGst_normal); } +| IndexStmt + { output_statement($1, 0, ECPGst_normal); } +| InsertStmt + { output_statement($1, 1, ECPGst_prepnormal); } +| ListenStmt + { output_statement($1, 0, ECPGst_normal); } +| LoadStmt + { output_statement($1, 0, ECPGst_normal); } +| LockStmt + { output_statement($1, 0, ECPGst_normal); } +| NotifyStmt + { output_statement($1, 0, ECPGst_normal); } +| PrepareStmt + { + if ($1.type == NULL || strlen($1.type) == 0) + output_prepare_statement($1.name, $1.stmt); + else + output_statement(cat_str(5, mm_strdup("prepare"), $1.name, $1.type, mm_strdup("as"), $1.stmt), 0, ECPGst_normal); + } +| ReassignOwnedStmt + { output_statement($1, 0, ECPGst_normal); } +| ReindexStmt + { output_statement($1, 0, ECPGst_normal); } +| RemoveAggrStmt + { output_statement($1, 0, ECPGst_normal); } +| RemoveFuncStmt + { output_statement($1, 0, ECPGst_normal); } +| RemoveOperStmt + { output_statement($1, 0, ECPGst_normal); } +| RenameStmt + { output_statement($1, 0, ECPGst_normal); } +| RevokeStmt + { output_statement($1, 0, ECPGst_normal); } +| RevokeRoleStmt + { output_statement($1, 0, ECPGst_normal); } +| RuleStmt + { output_statement($1, 0, ECPGst_normal); } +| SecLabelStmt + { output_statement($1, 0, ECPGst_normal); } +| SelectStmt + { output_statement($1, 1, ECPGst_prepnormal); } +| TransactionStmt + { + fprintf(yyout, "{ ECPGtrans(__LINE__, %s, \"%s\");", connection ? connection : "NULL", $1); + whenever_action(2); + free($1); + } +| TruncateStmt + { output_statement($1, 0, ECPGst_normal); } +| UnlistenStmt + { output_statement($1, 0, ECPGst_normal); } +| UpdateStmt + { output_statement($1, 1, ECPGst_prepnormal); } +| VacuumStmt + { output_statement($1, 0, ECPGst_normal); } +| VariableResetStmt + { output_statement($1, 0, ECPGst_normal); } +| VariableSetStmt + { output_statement($1, 0, ECPGst_normal); } +| VariableShowStmt + { output_statement($1, 0, ECPGst_normal); } +| ViewStmt + { output_statement($1, 0, ECPGst_normal); } + | ECPGAllocateDescr + { + fprintf(yyout,"ECPGallocate_desc(__LINE__, %s);",$1); + whenever_action(0); + free($1); + } + | ECPGConnect + { + if (connection) + mmerror(PARSE_ERROR, ET_ERROR, "AT option not allowed in CONNECT statement"); + + fprintf(yyout, "{ ECPGconnect(__LINE__, %d, %s, %d); ", compat, $1, autocommit); + reset_variables(); + whenever_action(2); + free($1); + } + | ECPGCursorStmt + { + output_simple_statement($1); + } + | ECPGDeallocateDescr + { + fprintf(yyout,"ECPGdeallocate_desc(__LINE__, %s);",$1); + whenever_action(0); + free($1); + } + | ECPGDeclare + { + output_simple_statement($1); + } + | ECPGDescribe + { + fprintf(yyout, "{ ECPGdescribe(__LINE__, %d, %s,", compat, $1); + dump_variables(argsresult, 1); + fputs("ECPGt_EORT);", yyout); + fprintf(yyout, "}"); + output_line_number(); + + free($1); + } + | ECPGDisconnect + { + if (connection) + mmerror(PARSE_ERROR, ET_ERROR, "AT option not allowed in DISCONNECT statement"); + + fprintf(yyout, "{ ECPGdisconnect(__LINE__, %s);", + $1 ? $1 : "\"CURRENT\""); + whenever_action(2); + free($1); + } + | ECPGExecuteImmediateStmt { output_statement($1, 0, ECPGst_exec_immediate); } + | ECPGFree + { + const char *con = connection ? connection : "NULL"; + + if (strcmp($1, "all") == 0) + fprintf(yyout, "{ ECPGdeallocate_all(__LINE__, %d, %s);", compat, con); + else if ($1[0] == ':') + fprintf(yyout, "{ ECPGdeallocate(__LINE__, %d, %s, %s);", compat, con, $1+1); + else + fprintf(yyout, "{ ECPGdeallocate(__LINE__, %d, %s, \"%s\");", compat, con, $1); + + whenever_action(2); + free($1); + } + | ECPGGetDescriptor + { + lookup_descriptor($1.name, connection); + output_get_descr($1.name, $1.str); + free($1.name); + free($1.str); + } + | ECPGGetDescriptorHeader + { + lookup_descriptor($1, connection); + output_get_descr_header($1); + free($1); + } + | ECPGOpen + { + struct cursor *ptr; + + if ((ptr = add_additional_variables($1, true)) != NULL) + { + connection = ptr->connection ? mm_strdup(ptr->connection) : NULL; + output_statement(mm_strdup(ptr->command), 0, ECPGst_normal); + ptr->opened = true; + } + } + | ECPGSetAutocommit + { + fprintf(yyout, "{ ECPGsetcommit(__LINE__, \"%s\", %s);", $1, connection ? connection : "NULL"); + whenever_action(2); + free($1); + } + | ECPGSetConnection + { + if (connection) + mmerror(PARSE_ERROR, ET_ERROR, "AT option not allowed in SET CONNECTION statement"); + + fprintf(yyout, "{ ECPGsetconn(__LINE__, %s);", $1); + whenever_action(2); + free($1); + } + | ECPGSetDescriptor + { + lookup_descriptor($1.name, connection); + output_set_descr($1.name, $1.str); + free($1.name); + free($1.str); + } + | ECPGSetDescriptorHeader + { + lookup_descriptor($1, connection); + output_set_descr_header($1); + free($1); + } + | ECPGTypedef + { + if (connection) + mmerror(PARSE_ERROR, ET_ERROR, "AT option not allowed in TYPE statement"); + + fprintf(yyout, "%s", $1); + free($1); + output_line_number(); + } + | ECPGVar + { + if (connection) + mmerror(PARSE_ERROR, ET_ERROR, "AT option not allowed in VAR statement"); + + output_simple_statement($1); + } + | ECPGWhenever + { + if (connection) + mmerror(PARSE_ERROR, ET_ERROR, "AT option not allowed in WHENEVER statement"); + + output_simple_statement($1); + } +| + { $$ = NULL; } +; + + + CreateRoleStmt: + CREATE ROLE RoleId opt_with OptRoleList + { + $$ = cat_str(4,mm_strdup("create role"),$3,$4,$5); +} +; + + + opt_with: + WITH + { + $$ = mm_strdup("with"); +} +| + { + $$=EMPTY; } +; + + + OptRoleList: + OptRoleList CreateOptRoleElem + { + $$ = cat_str(2,$1,$2); +} +| + { + $$=EMPTY; } +; + + + AlterOptRoleList: + AlterOptRoleList AlterOptRoleElem + { + $$ = cat_str(2,$1,$2); +} +| + { + $$=EMPTY; } +; + + + AlterOptRoleElem: + PASSWORD ecpg_sconst + { + $$ = cat_str(2,mm_strdup("password"),$2); +} +| PASSWORD NULL_P + { + $$ = mm_strdup("password null"); +} +| ENCRYPTED PASSWORD ecpg_sconst + { + $$ = cat_str(2,mm_strdup("encrypted password"),$3); +} +| UNENCRYPTED PASSWORD ecpg_sconst + { + $$ = cat_str(2,mm_strdup("unencrypted password"),$3); +} +| INHERIT + { + $$ = mm_strdup("inherit"); +} +| CONNECTION LIMIT SignedIconst + { + $$ = cat_str(2,mm_strdup("connection limit"),$3); +} +| VALID UNTIL ecpg_sconst + { + $$ = cat_str(2,mm_strdup("valid until"),$3); +} +| USER name_list + { + $$ = cat_str(2,mm_strdup("user"),$2); +} +| ecpg_ident + { + $$ = $1; +} +; + + + CreateOptRoleElem: + AlterOptRoleElem + { + $$ = $1; +} +| SYSID Iconst + { + $$ = cat_str(2,mm_strdup("sysid"),$2); +} +| ADMIN name_list + { + $$ = cat_str(2,mm_strdup("admin"),$2); +} +| ROLE name_list + { + $$ = cat_str(2,mm_strdup("role"),$2); +} +| IN_P ROLE name_list + { + $$ = cat_str(2,mm_strdup("in role"),$3); +} +| IN_P GROUP_P name_list + { + $$ = cat_str(2,mm_strdup("in group"),$3); +} +; + + + CreateUserStmt: + CREATE USER RoleId opt_with OptRoleList + { + $$ = cat_str(4,mm_strdup("create user"),$3,$4,$5); +} +; + + + AlterRoleStmt: + ALTER ROLE RoleId opt_with AlterOptRoleList + { + $$ = cat_str(4,mm_strdup("alter role"),$3,$4,$5); +} +; + + + opt_in_database: + + { + $$=EMPTY; } +| IN_P DATABASE database_name + { + $$ = cat_str(2,mm_strdup("in database"),$3); +} +; + + + AlterRoleSetStmt: + ALTER ROLE RoleId opt_in_database SetResetClause + { + $$ = cat_str(4,mm_strdup("alter role"),$3,$4,$5); +} +; + + + AlterUserStmt: + ALTER USER RoleId opt_with AlterOptRoleList + { + $$ = cat_str(4,mm_strdup("alter user"),$3,$4,$5); +} +; + + + AlterUserSetStmt: + ALTER USER RoleId SetResetClause + { + $$ = cat_str(3,mm_strdup("alter user"),$3,$4); +} +; + + + DropRoleStmt: + DROP ROLE name_list + { + $$ = cat_str(2,mm_strdup("drop role"),$3); +} +| DROP ROLE IF_P EXISTS name_list + { + $$ = cat_str(2,mm_strdup("drop role if exists"),$5); +} +; + + + DropUserStmt: + DROP USER name_list + { + $$ = cat_str(2,mm_strdup("drop user"),$3); +} +| DROP USER IF_P EXISTS name_list + { + $$ = cat_str(2,mm_strdup("drop user if exists"),$5); +} +; + + + CreateGroupStmt: + CREATE GROUP_P RoleId opt_with OptRoleList + { + $$ = cat_str(4,mm_strdup("create group"),$3,$4,$5); +} +; + + + AlterGroupStmt: + ALTER GROUP_P RoleId add_drop USER name_list + { + $$ = cat_str(5,mm_strdup("alter group"),$3,$4,mm_strdup("user"),$6); +} +; + + + add_drop: + ADD_P + { + $$ = mm_strdup("add"); +} +| DROP + { + $$ = mm_strdup("drop"); +} +; + + + DropGroupStmt: + DROP GROUP_P name_list + { + $$ = cat_str(2,mm_strdup("drop group"),$3); +} +| DROP GROUP_P IF_P EXISTS name_list + { + $$ = cat_str(2,mm_strdup("drop group if exists"),$5); +} +; + + + CreateSchemaStmt: + CREATE SCHEMA OptSchemaName AUTHORIZATION RoleId OptSchemaEltList + { + $$ = cat_str(5,mm_strdup("create schema"),$3,mm_strdup("authorization"),$5,$6); +} +| CREATE SCHEMA ColId OptSchemaEltList + { + $$ = cat_str(3,mm_strdup("create schema"),$3,$4); +} +; + + + OptSchemaName: + ColId + { + $$ = $1; +} +| + { + $$=EMPTY; } +; + + + OptSchemaEltList: + OptSchemaEltList schema_stmt + { + $$ = cat_str(2,$1,$2); +} +| + { + $$=EMPTY; } +; + + + schema_stmt: + CreateStmt + { + $$ = $1; +} +| IndexStmt + { + $$ = $1; +} +| CreateSeqStmt + { + $$ = $1; +} +| CreateTrigStmt + { + $$ = $1; +} +| GrantStmt + { + $$ = $1; +} +| ViewStmt + { + $$ = $1; +} +; + + + VariableSetStmt: + SET set_rest + { + $$ = cat_str(2,mm_strdup("set"),$2); +} +| SET LOCAL set_rest + { + $$ = cat_str(2,mm_strdup("set local"),$3); +} +| SET SESSION set_rest + { + $$ = cat_str(2,mm_strdup("set session"),$3); +} +; + + + set_rest: + TRANSACTION transaction_mode_list + { + $$ = cat_str(2,mm_strdup("transaction"),$2); +} +| SESSION CHARACTERISTICS AS TRANSACTION transaction_mode_list + { + $$ = cat_str(2,mm_strdup("session characteristics as transaction"),$5); +} +| set_rest_more + { + $$ = $1; +} +; + + + set_rest_more: + var_name TO var_list + { + $$ = cat_str(3,$1,mm_strdup("to"),$3); +} +| var_name '=' var_list + { + $$ = cat_str(3,$1,mm_strdup("="),$3); +} +| var_name TO DEFAULT + { + $$ = cat_str(2,$1,mm_strdup("to default")); +} +| var_name '=' DEFAULT + { + $$ = cat_str(2,$1,mm_strdup("= default")); +} +| var_name FROM CURRENT_P + { + $$ = cat_str(2,$1,mm_strdup("from current")); +} +| TIME ZONE zone_value + { + $$ = cat_str(2,mm_strdup("time zone"),$3); +} +| CATALOG_P ecpg_sconst + { +mmerror(PARSE_ERROR, ET_WARNING, "unsupported feature will be passed to server"); + $$ = cat_str(2,mm_strdup("catalog"),$2); +} +| SCHEMA ecpg_sconst + { + $$ = cat_str(2,mm_strdup("schema"),$2); +} +| NAMES opt_encoding + { + $$ = cat_str(2,mm_strdup("names"),$2); +} +| ROLE ColId_or_Sconst + { + $$ = cat_str(2,mm_strdup("role"),$2); +} +| SESSION AUTHORIZATION ColId_or_Sconst + { + $$ = cat_str(2,mm_strdup("session authorization"),$3); +} +| SESSION AUTHORIZATION DEFAULT + { + $$ = mm_strdup("session authorization default"); +} +| XML_P OPTION document_or_content + { + $$ = cat_str(2,mm_strdup("xml option"),$3); +} +| TRANSACTION SNAPSHOT ecpg_sconst + { + $$ = cat_str(2,mm_strdup("transaction snapshot"),$3); +} +; + + + var_name: +ECPGColId + { + $$ = $1; +} +| var_name '.' ColId + { + $$ = cat_str(3,$1,mm_strdup("."),$3); +} +; + + + var_list: + var_value + { + $$ = $1; +} +| var_list ',' var_value + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + var_value: + opt_boolean_or_string + { + $$ = $1; +} +| NumericOnly + { + if ($1[0] == '$') + { + free($1); + $1 = mm_strdup("$0"); + } + + $$ = $1; +} +; + + + iso_level: + READ UNCOMMITTED + { + $$ = mm_strdup("read uncommitted"); +} +| READ COMMITTED + { + $$ = mm_strdup("read committed"); +} +| REPEATABLE READ + { + $$ = mm_strdup("repeatable read"); +} +| SERIALIZABLE + { + $$ = mm_strdup("serializable"); +} +; + + + opt_boolean_or_string: + TRUE_P + { + $$ = mm_strdup("true"); +} +| FALSE_P + { + $$ = mm_strdup("false"); +} +| ON + { + $$ = mm_strdup("on"); +} +| ColId_or_Sconst + { + $$ = $1; +} +; + + + zone_value: + ecpg_sconst + { + $$ = $1; +} +| ecpg_ident + { + $$ = $1; +} +| ConstInterval ecpg_sconst opt_interval + { + $$ = cat_str(3,$1,$2,$3); +} +| ConstInterval '(' Iconst ')' ecpg_sconst opt_interval + { + $$ = cat_str(6,$1,mm_strdup("("),$3,mm_strdup(")"),$5,$6); +} +| NumericOnly + { + $$ = $1; +} +| DEFAULT + { + $$ = mm_strdup("default"); +} +| LOCAL + { + $$ = mm_strdup("local"); +} +; + + + opt_encoding: + ecpg_sconst + { + $$ = $1; +} +| DEFAULT + { + $$ = mm_strdup("default"); +} +| + { + $$=EMPTY; } +; + + + ColId_or_Sconst: + ColId + { + $$ = $1; +} +| ecpg_sconst + { + $$ = $1; +} +; + + + VariableResetStmt: + RESET var_name + { + $$ = cat_str(2,mm_strdup("reset"),$2); +} +| RESET TIME ZONE + { + $$ = mm_strdup("reset time zone"); +} +| RESET TRANSACTION ISOLATION LEVEL + { + $$ = mm_strdup("reset transaction isolation level"); +} +| RESET SESSION AUTHORIZATION + { + $$ = mm_strdup("reset session authorization"); +} +| RESET ALL + { + $$ = mm_strdup("reset all"); +} +; + + + SetResetClause: + SET set_rest + { + $$ = cat_str(2,mm_strdup("set"),$2); +} +| VariableResetStmt + { + $$ = $1; +} +; + + + FunctionSetResetClause: + SET set_rest_more + { + $$ = cat_str(2,mm_strdup("set"),$2); +} +| VariableResetStmt + { + $$ = $1; +} +; + + + VariableShowStmt: +SHOW var_name ecpg_into + { + $$ = cat_str(2,mm_strdup("show"),$2); +} +| SHOW TIME ZONE ecpg_into + { + $$ = mm_strdup("show time zone"); +} +| SHOW TRANSACTION ISOLATION LEVEL ecpg_into + { + $$ = mm_strdup("show transaction isolation level"); +} +| SHOW SESSION AUTHORIZATION ecpg_into + { + $$ = mm_strdup("show session authorization"); +} +| SHOW ALL + { + mmerror(PARSE_ERROR, ET_ERROR, "SHOW ALL is not implemented"); + $$ = EMPTY; + } +; + + + ConstraintsSetStmt: + SET CONSTRAINTS constraints_set_list constraints_set_mode + { + $$ = cat_str(3,mm_strdup("set constraints"),$3,$4); +} +; + + + constraints_set_list: + ALL + { + $$ = mm_strdup("all"); +} +| qualified_name_list + { + $$ = $1; +} +; + + + constraints_set_mode: + DEFERRED + { + $$ = mm_strdup("deferred"); +} +| IMMEDIATE + { + $$ = mm_strdup("immediate"); +} +; + + + CheckPointStmt: + CHECKPOINT + { + $$ = mm_strdup("checkpoint"); +} +; + + + DiscardStmt: + DISCARD ALL + { + $$ = mm_strdup("discard all"); +} +| DISCARD TEMP + { + $$ = mm_strdup("discard temp"); +} +| DISCARD TEMPORARY + { + $$ = mm_strdup("discard temporary"); +} +| DISCARD PLANS + { + $$ = mm_strdup("discard plans"); +} +; + + + AlterTableStmt: + ALTER TABLE relation_expr alter_table_cmds + { + $$ = cat_str(3,mm_strdup("alter table"),$3,$4); +} +| ALTER TABLE IF_P EXISTS relation_expr alter_table_cmds + { + $$ = cat_str(3,mm_strdup("alter table if exists"),$5,$6); +} +| ALTER INDEX qualified_name alter_table_cmds + { + $$ = cat_str(3,mm_strdup("alter index"),$3,$4); +} +| ALTER INDEX IF_P EXISTS qualified_name alter_table_cmds + { + $$ = cat_str(3,mm_strdup("alter index if exists"),$5,$6); +} +| ALTER SEQUENCE qualified_name alter_table_cmds + { + $$ = cat_str(3,mm_strdup("alter sequence"),$3,$4); +} +| ALTER SEQUENCE IF_P EXISTS qualified_name alter_table_cmds + { + $$ = cat_str(3,mm_strdup("alter sequence if exists"),$5,$6); +} +| ALTER VIEW qualified_name alter_table_cmds + { + $$ = cat_str(3,mm_strdup("alter view"),$3,$4); +} +| ALTER VIEW IF_P EXISTS qualified_name alter_table_cmds + { + $$ = cat_str(3,mm_strdup("alter view if exists"),$5,$6); +} +; + + + alter_table_cmds: + alter_table_cmd + { + $$ = $1; +} +| alter_table_cmds ',' alter_table_cmd + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + alter_table_cmd: + ADD_P columnDef + { + $$ = cat_str(2,mm_strdup("add"),$2); +} +| ADD_P COLUMN columnDef + { + $$ = cat_str(2,mm_strdup("add column"),$3); +} +| ALTER opt_column ColId alter_column_default + { + $$ = cat_str(4,mm_strdup("alter"),$2,$3,$4); +} +| ALTER opt_column ColId DROP NOT NULL_P + { + $$ = cat_str(4,mm_strdup("alter"),$2,$3,mm_strdup("drop not null")); +} +| ALTER opt_column ColId SET NOT NULL_P + { + $$ = cat_str(4,mm_strdup("alter"),$2,$3,mm_strdup("set not null")); +} +| ALTER opt_column ColId SET STATISTICS SignedIconst + { + $$ = cat_str(5,mm_strdup("alter"),$2,$3,mm_strdup("set statistics"),$6); +} +| ALTER opt_column ColId SET reloptions + { + $$ = cat_str(5,mm_strdup("alter"),$2,$3,mm_strdup("set"),$5); +} +| ALTER opt_column ColId RESET reloptions + { + $$ = cat_str(5,mm_strdup("alter"),$2,$3,mm_strdup("reset"),$5); +} +| ALTER opt_column ColId SET STORAGE ColId + { + $$ = cat_str(5,mm_strdup("alter"),$2,$3,mm_strdup("set storage"),$6); +} +| DROP opt_column IF_P EXISTS ColId opt_drop_behavior + { + $$ = cat_str(5,mm_strdup("drop"),$2,mm_strdup("if exists"),$5,$6); +} +| DROP opt_column ColId opt_drop_behavior + { + $$ = cat_str(4,mm_strdup("drop"),$2,$3,$4); +} +| ALTER opt_column ColId opt_set_data TYPE_P Typename opt_collate_clause alter_using + { + $$ = cat_str(8,mm_strdup("alter"),$2,$3,$4,mm_strdup("type"),$6,$7,$8); +} +| ALTER opt_column ColId alter_generic_options + { + $$ = cat_str(4,mm_strdup("alter"),$2,$3,$4); +} +| ADD_P TableConstraint + { + $$ = cat_str(2,mm_strdup("add"),$2); +} +| VALIDATE CONSTRAINT name + { + $$ = cat_str(2,mm_strdup("validate constraint"),$3); +} +| DROP CONSTRAINT IF_P EXISTS name opt_drop_behavior + { + $$ = cat_str(3,mm_strdup("drop constraint if exists"),$5,$6); +} +| DROP CONSTRAINT name opt_drop_behavior + { + $$ = cat_str(3,mm_strdup("drop constraint"),$3,$4); +} +| SET WITH OIDS + { + $$ = mm_strdup("set with oids"); +} +| SET WITHOUT OIDS + { + $$ = mm_strdup("set without oids"); +} +| CLUSTER ON name + { + $$ = cat_str(2,mm_strdup("cluster on"),$3); +} +| SET WITHOUT CLUSTER + { + $$ = mm_strdup("set without cluster"); +} +| ENABLE_P TRIGGER name + { + $$ = cat_str(2,mm_strdup("enable trigger"),$3); +} +| ENABLE_P ALWAYS TRIGGER name + { + $$ = cat_str(2,mm_strdup("enable always trigger"),$4); +} +| ENABLE_P REPLICA TRIGGER name + { + $$ = cat_str(2,mm_strdup("enable replica trigger"),$4); +} +| ENABLE_P TRIGGER ALL + { + $$ = mm_strdup("enable trigger all"); +} +| ENABLE_P TRIGGER USER + { + $$ = mm_strdup("enable trigger user"); +} +| DISABLE_P TRIGGER name + { + $$ = cat_str(2,mm_strdup("disable trigger"),$3); +} +| DISABLE_P TRIGGER ALL + { + $$ = mm_strdup("disable trigger all"); +} +| DISABLE_P TRIGGER USER + { + $$ = mm_strdup("disable trigger user"); +} +| ENABLE_P RULE name + { + $$ = cat_str(2,mm_strdup("enable rule"),$3); +} +| ENABLE_P ALWAYS RULE name + { + $$ = cat_str(2,mm_strdup("enable always rule"),$4); +} +| ENABLE_P REPLICA RULE name + { + $$ = cat_str(2,mm_strdup("enable replica rule"),$4); +} +| DISABLE_P RULE name + { + $$ = cat_str(2,mm_strdup("disable rule"),$3); +} +| INHERIT qualified_name + { + $$ = cat_str(2,mm_strdup("inherit"),$2); +} +| NO INHERIT qualified_name + { + $$ = cat_str(2,mm_strdup("no inherit"),$3); +} +| OF any_name + { + $$ = cat_str(2,mm_strdup("of"),$2); +} +| NOT OF + { + $$ = mm_strdup("not of"); +} +| OWNER TO RoleId + { + $$ = cat_str(2,mm_strdup("owner to"),$3); +} +| SET TABLESPACE name + { + $$ = cat_str(2,mm_strdup("set tablespace"),$3); +} +| SET reloptions + { + $$ = cat_str(2,mm_strdup("set"),$2); +} +| RESET reloptions + { + $$ = cat_str(2,mm_strdup("reset"),$2); +} +| alter_generic_options + { + $$ = $1; +} +; + + + alter_column_default: + SET DEFAULT a_expr + { + $$ = cat_str(2,mm_strdup("set default"),$3); +} +| DROP DEFAULT + { + $$ = mm_strdup("drop default"); +} +; + + + opt_drop_behavior: + CASCADE + { + $$ = mm_strdup("cascade"); +} +| RESTRICT + { + $$ = mm_strdup("restrict"); +} +| + { + $$=EMPTY; } +; + + + opt_collate_clause: + COLLATE any_name + { + $$ = cat_str(2,mm_strdup("collate"),$2); +} +| + { + $$=EMPTY; } +; + + + alter_using: + USING a_expr + { + $$ = cat_str(2,mm_strdup("using"),$2); +} +| + { + $$=EMPTY; } +; + + + reloptions: + '(' reloption_list ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(")")); +} +; + + + opt_reloptions: + WITH reloptions + { + $$ = cat_str(2,mm_strdup("with"),$2); +} +| + { + $$=EMPTY; } +; + + + reloption_list: + reloption_elem + { + $$ = $1; +} +| reloption_list ',' reloption_elem + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + reloption_elem: + ColLabel '=' def_arg + { + $$ = cat_str(3,$1,mm_strdup("="),$3); +} +| ColLabel + { + $$ = $1; +} +| ColLabel '.' ColLabel '=' def_arg + { + $$ = cat_str(5,$1,mm_strdup("."),$3,mm_strdup("="),$5); +} +| ColLabel '.' ColLabel + { + $$ = cat_str(3,$1,mm_strdup("."),$3); +} +; + + + AlterCompositeTypeStmt: + ALTER TYPE_P any_name alter_type_cmds + { + $$ = cat_str(3,mm_strdup("alter type"),$3,$4); +} +; + + + alter_type_cmds: + alter_type_cmd + { + $$ = $1; +} +| alter_type_cmds ',' alter_type_cmd + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + alter_type_cmd: + ADD_P ATTRIBUTE TableFuncElement opt_drop_behavior + { + $$ = cat_str(3,mm_strdup("add attribute"),$3,$4); +} +| DROP ATTRIBUTE IF_P EXISTS ColId opt_drop_behavior + { + $$ = cat_str(3,mm_strdup("drop attribute if exists"),$5,$6); +} +| DROP ATTRIBUTE ColId opt_drop_behavior + { + $$ = cat_str(3,mm_strdup("drop attribute"),$3,$4); +} +| ALTER ATTRIBUTE ColId opt_set_data TYPE_P Typename opt_collate_clause opt_drop_behavior + { + $$ = cat_str(7,mm_strdup("alter attribute"),$3,$4,mm_strdup("type"),$6,$7,$8); +} +; + + + ClosePortalStmt: + CLOSE cursor_name + { + char *cursor_marker = $2[0] == ':' ? mm_strdup("$0") : $2; + $$ = cat2_str(mm_strdup("close"), cursor_marker); + } +| CLOSE ALL + { + $$ = mm_strdup("close all"); +} +; + + + CopyStmt: + COPY opt_binary qualified_name opt_column_list opt_oids copy_from copy_file_name copy_delimiter opt_with copy_options + { + if (strcmp($6, "to") == 0 && strcmp($7, "stdin") == 0) + mmerror(PARSE_ERROR, ET_ERROR, "COPY TO STDIN is not possible"); + else if (strcmp($6, "from") == 0 && strcmp($7, "stdout") == 0) + mmerror(PARSE_ERROR, ET_ERROR, "COPY FROM STDOUT is not possible"); + else if (strcmp($6, "from") == 0 && strcmp($7, "stdin") == 0) + mmerror(PARSE_ERROR, ET_WARNING, "COPY FROM STDIN is not implemented"); + + $$ = cat_str(10,mm_strdup("copy"),$2,$3,$4,$5,$6,$7,$8,$9,$10); +} +| COPY select_with_parens TO copy_file_name opt_with copy_options + { + if (strcmp($4, "stdin") == 0) + mmerror(PARSE_ERROR, ET_ERROR, "COPY TO STDIN is not possible"); + + $$ = cat_str(6,mm_strdup("copy"),$2,mm_strdup("to"),$4,$5,$6); +} +; + + + copy_from: + FROM + { + $$ = mm_strdup("from"); +} +| TO + { + $$ = mm_strdup("to"); +} +; + + + copy_file_name: + ecpg_sconst + { + $$ = $1; +} +| STDIN + { + $$ = mm_strdup("stdin"); +} +| STDOUT + { + $$ = mm_strdup("stdout"); +} +; + + + copy_options: + copy_opt_list + { + $$ = $1; +} +| '(' copy_generic_opt_list ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(")")); +} +; + + + copy_opt_list: + copy_opt_list copy_opt_item + { + $$ = cat_str(2,$1,$2); +} +| + { + $$=EMPTY; } +; + + + copy_opt_item: + BINARY + { + $$ = mm_strdup("binary"); +} +| OIDS + { + $$ = mm_strdup("oids"); +} +| DELIMITER opt_as ecpg_sconst + { + $$ = cat_str(3,mm_strdup("delimiter"),$2,$3); +} +| NULL_P opt_as ecpg_sconst + { + $$ = cat_str(3,mm_strdup("null"),$2,$3); +} +| CSV + { + $$ = mm_strdup("csv"); +} +| HEADER_P + { + $$ = mm_strdup("header"); +} +| QUOTE opt_as ecpg_sconst + { + $$ = cat_str(3,mm_strdup("quote"),$2,$3); +} +| ESCAPE opt_as ecpg_sconst + { + $$ = cat_str(3,mm_strdup("escape"),$2,$3); +} +| FORCE QUOTE columnList + { + $$ = cat_str(2,mm_strdup("force quote"),$3); +} +| FORCE QUOTE '*' + { + $$ = mm_strdup("force quote *"); +} +| FORCE NOT NULL_P columnList + { + $$ = cat_str(2,mm_strdup("force not null"),$4); +} +| ENCODING ecpg_sconst + { + $$ = cat_str(2,mm_strdup("encoding"),$2); +} +; + + + opt_binary: + BINARY + { + $$ = mm_strdup("binary"); +} +| + { + $$=EMPTY; } +; + + + opt_oids: + WITH OIDS + { + $$ = mm_strdup("with oids"); +} +| + { + $$=EMPTY; } +; + + + copy_delimiter: + opt_using DELIMITERS ecpg_sconst + { + $$ = cat_str(3,$1,mm_strdup("delimiters"),$3); +} +| + { + $$=EMPTY; } +; + + + opt_using: + USING + { + $$ = mm_strdup("using"); +} +| + { + $$=EMPTY; } +; + + + copy_generic_opt_list: + copy_generic_opt_elem + { + $$ = $1; +} +| copy_generic_opt_list ',' copy_generic_opt_elem + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + copy_generic_opt_elem: + ColLabel copy_generic_opt_arg + { + $$ = cat_str(2,$1,$2); +} +; + + + copy_generic_opt_arg: + opt_boolean_or_string + { + $$ = $1; +} +| NumericOnly + { + $$ = $1; +} +| '*' + { + $$ = mm_strdup("*"); +} +| '(' copy_generic_opt_arg_list ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(")")); +} +| + { + $$=EMPTY; } +; + + + copy_generic_opt_arg_list: + copy_generic_opt_arg_list_item + { + $$ = $1; +} +| copy_generic_opt_arg_list ',' copy_generic_opt_arg_list_item + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + copy_generic_opt_arg_list_item: + opt_boolean_or_string + { + $$ = $1; +} +; + + + CreateStmt: + CREATE OptTemp TABLE qualified_name '(' OptTableElementList ')' OptInherit OptWith OnCommitOption OptTableSpace + { + $$ = cat_str(11,mm_strdup("create"),$2,mm_strdup("table"),$4,mm_strdup("("),$6,mm_strdup(")"),$8,$9,$10,$11); +} +| CREATE OptTemp TABLE IF_P NOT EXISTS qualified_name '(' OptTableElementList ')' OptInherit OptWith OnCommitOption OptTableSpace + { + $$ = cat_str(11,mm_strdup("create"),$2,mm_strdup("table if not exists"),$7,mm_strdup("("),$9,mm_strdup(")"),$11,$12,$13,$14); +} +| CREATE OptTemp TABLE qualified_name OF any_name OptTypedTableElementList OptWith OnCommitOption OptTableSpace + { + $$ = cat_str(10,mm_strdup("create"),$2,mm_strdup("table"),$4,mm_strdup("of"),$6,$7,$8,$9,$10); +} +| CREATE OptTemp TABLE IF_P NOT EXISTS qualified_name OF any_name OptTypedTableElementList OptWith OnCommitOption OptTableSpace + { + $$ = cat_str(10,mm_strdup("create"),$2,mm_strdup("table if not exists"),$7,mm_strdup("of"),$9,$10,$11,$12,$13); +} +; + + + OptTemp: + TEMPORARY + { + $$ = mm_strdup("temporary"); +} +| TEMP + { + $$ = mm_strdup("temp"); +} +| LOCAL TEMPORARY + { + $$ = mm_strdup("local temporary"); +} +| LOCAL TEMP + { + $$ = mm_strdup("local temp"); +} +| GLOBAL TEMPORARY + { + $$ = mm_strdup("global temporary"); +} +| GLOBAL TEMP + { + $$ = mm_strdup("global temp"); +} +| UNLOGGED + { + $$ = mm_strdup("unlogged"); +} +| + { + $$=EMPTY; } +; + + + OptTableElementList: + TableElementList + { + $$ = $1; +} +| + { + $$=EMPTY; } +; + + + OptTypedTableElementList: + '(' TypedTableElementList ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(")")); +} +| + { + $$=EMPTY; } +; + + + TableElementList: + TableElement + { + $$ = $1; +} +| TableElementList ',' TableElement + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + TypedTableElementList: + TypedTableElement + { + $$ = $1; +} +| TypedTableElementList ',' TypedTableElement + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + TableElement: + columnDef + { + $$ = $1; +} +| TableLikeClause + { + $$ = $1; +} +| TableConstraint + { + $$ = $1; +} +; + + + TypedTableElement: + columnOptions + { + $$ = $1; +} +| TableConstraint + { + $$ = $1; +} +; + + + columnDef: + ColId Typename create_generic_options ColQualList + { + $$ = cat_str(4,$1,$2,$3,$4); +} +; + + + columnOptions: + ColId WITH OPTIONS ColQualList + { + $$ = cat_str(3,$1,mm_strdup("with options"),$4); +} +; + + + ColQualList: + ColQualList ColConstraint + { + $$ = cat_str(2,$1,$2); +} +| + { + $$=EMPTY; } +; + + + ColConstraint: + CONSTRAINT name ColConstraintElem + { + $$ = cat_str(3,mm_strdup("constraint"),$2,$3); +} +| ColConstraintElem + { + $$ = $1; +} +| ConstraintAttr + { + $$ = $1; +} +| COLLATE any_name + { + $$ = cat_str(2,mm_strdup("collate"),$2); +} +; + + + ColConstraintElem: + NOT NULL_P + { + $$ = mm_strdup("not null"); +} +| NULL_P + { + $$ = mm_strdup("null"); +} +| UNIQUE opt_definition OptConsTableSpace + { + $$ = cat_str(3,mm_strdup("unique"),$2,$3); +} +| PRIMARY KEY opt_definition OptConsTableSpace + { + $$ = cat_str(3,mm_strdup("primary key"),$3,$4); +} +| CHECK '(' a_expr ')' opt_no_inherit + { + $$ = cat_str(4,mm_strdup("check ("),$3,mm_strdup(")"),$5); +} +| DEFAULT b_expr + { + $$ = cat_str(2,mm_strdup("default"),$2); +} +| REFERENCES qualified_name opt_column_list key_match key_actions + { + $$ = cat_str(5,mm_strdup("references"),$2,$3,$4,$5); +} +; + + + ConstraintAttr: + DEFERRABLE + { + $$ = mm_strdup("deferrable"); +} +| NOT DEFERRABLE + { + $$ = mm_strdup("not deferrable"); +} +| INITIALLY DEFERRED + { + $$ = mm_strdup("initially deferred"); +} +| INITIALLY IMMEDIATE + { + $$ = mm_strdup("initially immediate"); +} +; + + + TableLikeClause: + LIKE qualified_name TableLikeOptionList + { + $$ = cat_str(3,mm_strdup("like"),$2,$3); +} +; + + + TableLikeOptionList: + TableLikeOptionList INCLUDING TableLikeOption + { + $$ = cat_str(3,$1,mm_strdup("including"),$3); +} +| TableLikeOptionList EXCLUDING TableLikeOption + { + $$ = cat_str(3,$1,mm_strdup("excluding"),$3); +} +| + { + $$=EMPTY; } +; + + + TableLikeOption: + DEFAULTS + { + $$ = mm_strdup("defaults"); +} +| CONSTRAINTS + { + $$ = mm_strdup("constraints"); +} +| INDEXES + { + $$ = mm_strdup("indexes"); +} +| STORAGE + { + $$ = mm_strdup("storage"); +} +| COMMENTS + { + $$ = mm_strdup("comments"); +} +| ALL + { + $$ = mm_strdup("all"); +} +; + + + TableConstraint: + CONSTRAINT name ConstraintElem + { + $$ = cat_str(3,mm_strdup("constraint"),$2,$3); +} +| ConstraintElem + { + $$ = $1; +} +; + + + ConstraintElem: + CHECK '(' a_expr ')' ConstraintAttributeSpec + { + $$ = cat_str(4,mm_strdup("check ("),$3,mm_strdup(")"),$5); +} +| UNIQUE '(' columnList ')' opt_definition OptConsTableSpace ConstraintAttributeSpec + { + $$ = cat_str(6,mm_strdup("unique ("),$3,mm_strdup(")"),$5,$6,$7); +} +| UNIQUE ExistingIndex ConstraintAttributeSpec + { + $$ = cat_str(3,mm_strdup("unique"),$2,$3); +} +| PRIMARY KEY '(' columnList ')' opt_definition OptConsTableSpace ConstraintAttributeSpec + { + $$ = cat_str(6,mm_strdup("primary key ("),$4,mm_strdup(")"),$6,$7,$8); +} +| PRIMARY KEY ExistingIndex ConstraintAttributeSpec + { + $$ = cat_str(3,mm_strdup("primary key"),$3,$4); +} +| EXCLUDE access_method_clause '(' ExclusionConstraintList ')' opt_definition OptConsTableSpace ExclusionWhereClause ConstraintAttributeSpec + { + $$ = cat_str(9,mm_strdup("exclude"),$2,mm_strdup("("),$4,mm_strdup(")"),$6,$7,$8,$9); +} +| FOREIGN KEY '(' columnList ')' REFERENCES qualified_name opt_column_list key_match key_actions ConstraintAttributeSpec + { + $$ = cat_str(8,mm_strdup("foreign key ("),$4,mm_strdup(") references"),$7,$8,$9,$10,$11); +} +; + + + opt_no_inherit: + NO INHERIT + { + $$ = mm_strdup("no inherit"); +} +| + { + $$=EMPTY; } +; + + + opt_column_list: + '(' columnList ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(")")); +} +| + { + $$=EMPTY; } +; + + + columnList: + columnElem + { + $$ = $1; +} +| columnList ',' columnElem + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + columnElem: + ColId + { + $$ = $1; +} +; + + + key_match: + MATCH FULL + { + $$ = mm_strdup("match full"); +} +| MATCH PARTIAL + { +mmerror(PARSE_ERROR, ET_WARNING, "unsupported feature will be passed to server"); + $$ = mm_strdup("match partial"); +} +| MATCH SIMPLE + { + $$ = mm_strdup("match simple"); +} +| + { + $$=EMPTY; } +; + + + ExclusionConstraintList: + ExclusionConstraintElem + { + $$ = $1; +} +| ExclusionConstraintList ',' ExclusionConstraintElem + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + ExclusionConstraintElem: + index_elem WITH any_operator + { + $$ = cat_str(3,$1,mm_strdup("with"),$3); +} +| index_elem WITH OPERATOR '(' any_operator ')' + { + $$ = cat_str(4,$1,mm_strdup("with operator ("),$5,mm_strdup(")")); +} +; + + + ExclusionWhereClause: + WHERE '(' a_expr ')' + { + $$ = cat_str(3,mm_strdup("where ("),$3,mm_strdup(")")); +} +| + { + $$=EMPTY; } +; + + + key_actions: + key_update + { + $$ = $1; +} +| key_delete + { + $$ = $1; +} +| key_update key_delete + { + $$ = cat_str(2,$1,$2); +} +| key_delete key_update + { + $$ = cat_str(2,$1,$2); +} +| + { + $$=EMPTY; } +; + + + key_update: + ON UPDATE key_action + { + $$ = cat_str(2,mm_strdup("on update"),$3); +} +; + + + key_delete: + ON DELETE_P key_action + { + $$ = cat_str(2,mm_strdup("on delete"),$3); +} +; + + + key_action: + NO ACTION + { + $$ = mm_strdup("no action"); +} +| RESTRICT + { + $$ = mm_strdup("restrict"); +} +| CASCADE + { + $$ = mm_strdup("cascade"); +} +| SET NULL_P + { + $$ = mm_strdup("set null"); +} +| SET DEFAULT + { + $$ = mm_strdup("set default"); +} +; + + + OptInherit: + INHERITS '(' qualified_name_list ')' + { + $$ = cat_str(3,mm_strdup("inherits ("),$3,mm_strdup(")")); +} +| + { + $$=EMPTY; } +; + + + OptWith: + WITH reloptions + { + $$ = cat_str(2,mm_strdup("with"),$2); +} +| WITH OIDS + { + $$ = mm_strdup("with oids"); +} +| WITHOUT OIDS + { + $$ = mm_strdup("without oids"); +} +| + { + $$=EMPTY; } +; + + + OnCommitOption: + ON COMMIT DROP + { + $$ = mm_strdup("on commit drop"); +} +| ON COMMIT DELETE_P ROWS + { + $$ = mm_strdup("on commit delete rows"); +} +| ON COMMIT PRESERVE ROWS + { + $$ = mm_strdup("on commit preserve rows"); +} +| + { + $$=EMPTY; } +; + + + OptTableSpace: + TABLESPACE name + { + $$ = cat_str(2,mm_strdup("tablespace"),$2); +} +| + { + $$=EMPTY; } +; + + + OptConsTableSpace: + USING INDEX TABLESPACE name + { + $$ = cat_str(2,mm_strdup("using index tablespace"),$4); +} +| + { + $$=EMPTY; } +; + + + ExistingIndex: + USING INDEX index_name + { + $$ = cat_str(2,mm_strdup("using index"),$3); +} +; + + + create_as_target: + qualified_name opt_column_list OptWith OnCommitOption OptTableSpace + { + $$ = cat_str(5,$1,$2,$3,$4,$5); +} +; + + + opt_with_data: + WITH DATA_P + { + $$ = mm_strdup("with data"); +} +| WITH NO DATA_P + { + $$ = mm_strdup("with no data"); +} +| + { + $$=EMPTY; } +; + + + CreateSeqStmt: + CREATE OptTemp SEQUENCE qualified_name OptSeqOptList + { + $$ = cat_str(5,mm_strdup("create"),$2,mm_strdup("sequence"),$4,$5); +} +; + + + AlterSeqStmt: + ALTER SEQUENCE qualified_name SeqOptList + { + $$ = cat_str(3,mm_strdup("alter sequence"),$3,$4); +} +| ALTER SEQUENCE IF_P EXISTS qualified_name SeqOptList + { + $$ = cat_str(3,mm_strdup("alter sequence if exists"),$5,$6); +} +; + + + OptSeqOptList: + SeqOptList + { + $$ = $1; +} +| + { + $$=EMPTY; } +; + + + SeqOptList: + SeqOptElem + { + $$ = $1; +} +| SeqOptList SeqOptElem + { + $$ = cat_str(2,$1,$2); +} +; + + + SeqOptElem: + CACHE NumericOnly + { + $$ = cat_str(2,mm_strdup("cache"),$2); +} +| CYCLE + { + $$ = mm_strdup("cycle"); +} +| NO CYCLE + { + $$ = mm_strdup("no cycle"); +} +| INCREMENT opt_by NumericOnly + { + $$ = cat_str(3,mm_strdup("increment"),$2,$3); +} +| MAXVALUE NumericOnly + { + $$ = cat_str(2,mm_strdup("maxvalue"),$2); +} +| MINVALUE NumericOnly + { + $$ = cat_str(2,mm_strdup("minvalue"),$2); +} +| NO MAXVALUE + { + $$ = mm_strdup("no maxvalue"); +} +| NO MINVALUE + { + $$ = mm_strdup("no minvalue"); +} +| OWNED BY any_name + { + $$ = cat_str(2,mm_strdup("owned by"),$3); +} +| START opt_with NumericOnly + { + $$ = cat_str(3,mm_strdup("start"),$2,$3); +} +| RESTART + { + $$ = mm_strdup("restart"); +} +| RESTART opt_with NumericOnly + { + $$ = cat_str(3,mm_strdup("restart"),$2,$3); +} +; + + + opt_by: + BY + { + $$ = mm_strdup("by"); +} +| + { + $$=EMPTY; } +; + + + NumericOnly: + ecpg_fconst + { + $$ = $1; +} +| '-' ecpg_fconst + { + $$ = cat_str(2,mm_strdup("-"),$2); +} +| SignedIconst + { + $$ = $1; +} +; + + + NumericOnly_list: + NumericOnly + { + $$ = $1; +} +| NumericOnly_list ',' NumericOnly + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + CreatePLangStmt: + CREATE opt_or_replace opt_trusted opt_procedural LANGUAGE ColId_or_Sconst + { + $$ = cat_str(6,mm_strdup("create"),$2,$3,$4,mm_strdup("language"),$6); +} +| CREATE opt_or_replace opt_trusted opt_procedural LANGUAGE ColId_or_Sconst HANDLER handler_name opt_inline_handler opt_validator + { + $$ = cat_str(10,mm_strdup("create"),$2,$3,$4,mm_strdup("language"),$6,mm_strdup("handler"),$8,$9,$10); +} +; + + + opt_trusted: + TRUSTED + { + $$ = mm_strdup("trusted"); +} +| + { + $$=EMPTY; } +; + + + handler_name: + name + { + $$ = $1; +} +| name attrs + { + $$ = cat_str(2,$1,$2); +} +; + + + opt_inline_handler: + INLINE_P handler_name + { + $$ = cat_str(2,mm_strdup("inline"),$2); +} +| + { + $$=EMPTY; } +; + + + validator_clause: + VALIDATOR handler_name + { + $$ = cat_str(2,mm_strdup("validator"),$2); +} +| NO VALIDATOR + { + $$ = mm_strdup("no validator"); +} +; + + + opt_validator: + validator_clause + { + $$ = $1; +} +| + { + $$=EMPTY; } +; + + + DropPLangStmt: + DROP opt_procedural LANGUAGE ColId_or_Sconst opt_drop_behavior + { + $$ = cat_str(5,mm_strdup("drop"),$2,mm_strdup("language"),$4,$5); +} +| DROP opt_procedural LANGUAGE IF_P EXISTS ColId_or_Sconst opt_drop_behavior + { + $$ = cat_str(5,mm_strdup("drop"),$2,mm_strdup("language if exists"),$6,$7); +} +; + + + opt_procedural: + PROCEDURAL + { + $$ = mm_strdup("procedural"); +} +| + { + $$=EMPTY; } +; + + + CreateTableSpaceStmt: + CREATE TABLESPACE name OptTableSpaceOwner LOCATION ecpg_sconst + { + $$ = cat_str(5,mm_strdup("create tablespace"),$3,$4,mm_strdup("location"),$6); +} +; + + + OptTableSpaceOwner: + OWNER name + { + $$ = cat_str(2,mm_strdup("owner"),$2); +} +| + { + $$=EMPTY; } +; + + + DropTableSpaceStmt: + DROP TABLESPACE name + { + $$ = cat_str(2,mm_strdup("drop tablespace"),$3); +} +| DROP TABLESPACE IF_P EXISTS name + { + $$ = cat_str(2,mm_strdup("drop tablespace if exists"),$5); +} +; + + + CreateExtensionStmt: + CREATE EXTENSION name opt_with create_extension_opt_list + { + $$ = cat_str(4,mm_strdup("create extension"),$3,$4,$5); +} +| CREATE EXTENSION IF_P NOT EXISTS name opt_with create_extension_opt_list + { + $$ = cat_str(4,mm_strdup("create extension if not exists"),$6,$7,$8); +} +; + + + create_extension_opt_list: + create_extension_opt_list create_extension_opt_item + { + $$ = cat_str(2,$1,$2); +} +| + { + $$=EMPTY; } +; + + + create_extension_opt_item: + SCHEMA name + { + $$ = cat_str(2,mm_strdup("schema"),$2); +} +| VERSION_P ColId_or_Sconst + { + $$ = cat_str(2,mm_strdup("version"),$2); +} +| FROM ColId_or_Sconst + { + $$ = cat_str(2,mm_strdup("from"),$2); +} +; + + + AlterExtensionStmt: + ALTER EXTENSION name UPDATE alter_extension_opt_list + { + $$ = cat_str(4,mm_strdup("alter extension"),$3,mm_strdup("update"),$5); +} +; + + + alter_extension_opt_list: + alter_extension_opt_list alter_extension_opt_item + { + $$ = cat_str(2,$1,$2); +} +| + { + $$=EMPTY; } +; + + + alter_extension_opt_item: + TO ColId_or_Sconst + { + $$ = cat_str(2,mm_strdup("to"),$2); +} +; + + + AlterExtensionContentsStmt: + ALTER EXTENSION name add_drop AGGREGATE func_name aggr_args + { + $$ = cat_str(6,mm_strdup("alter extension"),$3,$4,mm_strdup("aggregate"),$6,$7); +} +| ALTER EXTENSION name add_drop CAST '(' Typename AS Typename ')' + { + $$ = cat_str(8,mm_strdup("alter extension"),$3,$4,mm_strdup("cast ("),$7,mm_strdup("as"),$9,mm_strdup(")")); +} +| ALTER EXTENSION name add_drop COLLATION any_name + { + $$ = cat_str(5,mm_strdup("alter extension"),$3,$4,mm_strdup("collation"),$6); +} +| ALTER EXTENSION name add_drop CONVERSION_P any_name + { + $$ = cat_str(5,mm_strdup("alter extension"),$3,$4,mm_strdup("conversion"),$6); +} +| ALTER EXTENSION name add_drop DOMAIN_P any_name + { + $$ = cat_str(5,mm_strdup("alter extension"),$3,$4,mm_strdup("domain"),$6); +} +| ALTER EXTENSION name add_drop FUNCTION function_with_argtypes + { + $$ = cat_str(5,mm_strdup("alter extension"),$3,$4,mm_strdup("function"),$6); +} +| ALTER EXTENSION name add_drop opt_procedural LANGUAGE name + { + $$ = cat_str(6,mm_strdup("alter extension"),$3,$4,$5,mm_strdup("language"),$7); +} +| ALTER EXTENSION name add_drop OPERATOR any_operator oper_argtypes + { + $$ = cat_str(6,mm_strdup("alter extension"),$3,$4,mm_strdup("operator"),$6,$7); +} +| ALTER EXTENSION name add_drop OPERATOR CLASS any_name USING access_method + { + $$ = cat_str(7,mm_strdup("alter extension"),$3,$4,mm_strdup("operator class"),$7,mm_strdup("using"),$9); +} +| ALTER EXTENSION name add_drop OPERATOR FAMILY any_name USING access_method + { + $$ = cat_str(7,mm_strdup("alter extension"),$3,$4,mm_strdup("operator family"),$7,mm_strdup("using"),$9); +} +| ALTER EXTENSION name add_drop SCHEMA name + { + $$ = cat_str(5,mm_strdup("alter extension"),$3,$4,mm_strdup("schema"),$6); +} +| ALTER EXTENSION name add_drop TABLE any_name + { + $$ = cat_str(5,mm_strdup("alter extension"),$3,$4,mm_strdup("table"),$6); +} +| ALTER EXTENSION name add_drop TEXT_P SEARCH PARSER any_name + { + $$ = cat_str(5,mm_strdup("alter extension"),$3,$4,mm_strdup("text search parser"),$8); +} +| ALTER EXTENSION name add_drop TEXT_P SEARCH DICTIONARY any_name + { + $$ = cat_str(5,mm_strdup("alter extension"),$3,$4,mm_strdup("text search dictionary"),$8); +} +| ALTER EXTENSION name add_drop TEXT_P SEARCH TEMPLATE any_name + { + $$ = cat_str(5,mm_strdup("alter extension"),$3,$4,mm_strdup("text search template"),$8); +} +| ALTER EXTENSION name add_drop TEXT_P SEARCH CONFIGURATION any_name + { + $$ = cat_str(5,mm_strdup("alter extension"),$3,$4,mm_strdup("text search configuration"),$8); +} +| ALTER EXTENSION name add_drop SEQUENCE any_name + { + $$ = cat_str(5,mm_strdup("alter extension"),$3,$4,mm_strdup("sequence"),$6); +} +| ALTER EXTENSION name add_drop VIEW any_name + { + $$ = cat_str(5,mm_strdup("alter extension"),$3,$4,mm_strdup("view"),$6); +} +| ALTER EXTENSION name add_drop FOREIGN TABLE any_name + { + $$ = cat_str(5,mm_strdup("alter extension"),$3,$4,mm_strdup("foreign table"),$7); +} +| ALTER EXTENSION name add_drop FOREIGN DATA_P WRAPPER name + { + $$ = cat_str(5,mm_strdup("alter extension"),$3,$4,mm_strdup("foreign data wrapper"),$8); +} +| ALTER EXTENSION name add_drop SERVER name + { + $$ = cat_str(5,mm_strdup("alter extension"),$3,$4,mm_strdup("server"),$6); +} +| ALTER EXTENSION name add_drop TYPE_P any_name + { + $$ = cat_str(5,mm_strdup("alter extension"),$3,$4,mm_strdup("type"),$6); +} +; + + + CreateFdwStmt: + CREATE FOREIGN DATA_P WRAPPER name opt_fdw_options create_generic_options + { + $$ = cat_str(4,mm_strdup("create foreign data wrapper"),$5,$6,$7); +} +; + + + fdw_option: + HANDLER handler_name + { + $$ = cat_str(2,mm_strdup("handler"),$2); +} +| NO HANDLER + { + $$ = mm_strdup("no handler"); +} +| VALIDATOR handler_name + { + $$ = cat_str(2,mm_strdup("validator"),$2); +} +| NO VALIDATOR + { + $$ = mm_strdup("no validator"); +} +; + + + fdw_options: + fdw_option + { + $$ = $1; +} +| fdw_options fdw_option + { + $$ = cat_str(2,$1,$2); +} +; + + + opt_fdw_options: + fdw_options + { + $$ = $1; +} +| + { + $$=EMPTY; } +; + + + DropFdwStmt: + DROP FOREIGN DATA_P WRAPPER name opt_drop_behavior + { + $$ = cat_str(3,mm_strdup("drop foreign data wrapper"),$5,$6); +} +| DROP FOREIGN DATA_P WRAPPER IF_P EXISTS name opt_drop_behavior + { + $$ = cat_str(3,mm_strdup("drop foreign data wrapper if exists"),$7,$8); +} +; + + + AlterFdwStmt: + ALTER FOREIGN DATA_P WRAPPER name opt_fdw_options alter_generic_options + { + $$ = cat_str(4,mm_strdup("alter foreign data wrapper"),$5,$6,$7); +} +| ALTER FOREIGN DATA_P WRAPPER name fdw_options + { + $$ = cat_str(3,mm_strdup("alter foreign data wrapper"),$5,$6); +} +; + + + create_generic_options: + OPTIONS '(' generic_option_list ')' + { + $$ = cat_str(3,mm_strdup("options ("),$3,mm_strdup(")")); +} +| + { + $$=EMPTY; } +; + + + generic_option_list: + generic_option_elem + { + $$ = $1; +} +| generic_option_list ',' generic_option_elem + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + alter_generic_options: + OPTIONS '(' alter_generic_option_list ')' + { + $$ = cat_str(3,mm_strdup("options ("),$3,mm_strdup(")")); +} +; + + + alter_generic_option_list: + alter_generic_option_elem + { + $$ = $1; +} +| alter_generic_option_list ',' alter_generic_option_elem + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + alter_generic_option_elem: + generic_option_elem + { + $$ = $1; +} +| SET generic_option_elem + { + $$ = cat_str(2,mm_strdup("set"),$2); +} +| ADD_P generic_option_elem + { + $$ = cat_str(2,mm_strdup("add"),$2); +} +| DROP generic_option_name + { + $$ = cat_str(2,mm_strdup("drop"),$2); +} +; + + + generic_option_elem: + generic_option_name generic_option_arg + { + $$ = cat_str(2,$1,$2); +} +; + + + generic_option_name: + ColLabel + { + $$ = $1; +} +; + + + generic_option_arg: + ecpg_sconst + { + $$ = $1; +} +; + + + CreateForeignServerStmt: + CREATE SERVER name opt_type opt_foreign_server_version FOREIGN DATA_P WRAPPER name create_generic_options + { + $$ = cat_str(7,mm_strdup("create server"),$3,$4,$5,mm_strdup("foreign data wrapper"),$9,$10); +} +; + + + opt_type: + TYPE_P ecpg_sconst + { + $$ = cat_str(2,mm_strdup("type"),$2); +} +| + { + $$=EMPTY; } +; + + + foreign_server_version: + VERSION_P ecpg_sconst + { + $$ = cat_str(2,mm_strdup("version"),$2); +} +| VERSION_P NULL_P + { + $$ = mm_strdup("version null"); +} +; + + + opt_foreign_server_version: + foreign_server_version + { + $$ = $1; +} +| + { + $$=EMPTY; } +; + + + DropForeignServerStmt: + DROP SERVER name opt_drop_behavior + { + $$ = cat_str(3,mm_strdup("drop server"),$3,$4); +} +| DROP SERVER IF_P EXISTS name opt_drop_behavior + { + $$ = cat_str(3,mm_strdup("drop server if exists"),$5,$6); +} +; + + + AlterForeignServerStmt: + ALTER SERVER name foreign_server_version alter_generic_options + { + $$ = cat_str(4,mm_strdup("alter server"),$3,$4,$5); +} +| ALTER SERVER name foreign_server_version + { + $$ = cat_str(3,mm_strdup("alter server"),$3,$4); +} +| ALTER SERVER name alter_generic_options + { + $$ = cat_str(3,mm_strdup("alter server"),$3,$4); +} +; + + + CreateForeignTableStmt: + CREATE FOREIGN TABLE qualified_name OptForeignTableElementList SERVER name create_generic_options + { + $$ = cat_str(6,mm_strdup("create foreign table"),$4,$5,mm_strdup("server"),$7,$8); +} +| CREATE FOREIGN TABLE IF_P NOT EXISTS qualified_name OptForeignTableElementList SERVER name create_generic_options + { + $$ = cat_str(6,mm_strdup("create foreign table if not exists"),$7,$8,mm_strdup("server"),$10,$11); +} +; + + + OptForeignTableElementList: + '(' ForeignTableElementList ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(")")); +} +| '(' ')' + { + $$ = mm_strdup("( )"); +} +; + + + ForeignTableElementList: + ForeignTableElement + { + $$ = $1; +} +| ForeignTableElementList ',' ForeignTableElement + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + ForeignTableElement: + columnDef + { + $$ = $1; +} +; + + + AlterForeignTableStmt: + ALTER FOREIGN TABLE relation_expr alter_table_cmds + { + $$ = cat_str(3,mm_strdup("alter foreign table"),$4,$5); +} +| ALTER FOREIGN TABLE IF_P EXISTS relation_expr alter_table_cmds + { + $$ = cat_str(3,mm_strdup("alter foreign table if exists"),$6,$7); +} +; + + + CreateUserMappingStmt: + CREATE USER MAPPING FOR auth_ident SERVER name create_generic_options + { + $$ = cat_str(5,mm_strdup("create user mapping for"),$5,mm_strdup("server"),$7,$8); +} +; + + + auth_ident: + CURRENT_USER + { + $$ = mm_strdup("current_user"); +} +| USER + { + $$ = mm_strdup("user"); +} +| RoleId + { + $$ = $1; +} +; + + + DropUserMappingStmt: + DROP USER MAPPING FOR auth_ident SERVER name + { + $$ = cat_str(4,mm_strdup("drop user mapping for"),$5,mm_strdup("server"),$7); +} +| DROP USER MAPPING IF_P EXISTS FOR auth_ident SERVER name + { + $$ = cat_str(4,mm_strdup("drop user mapping if exists for"),$7,mm_strdup("server"),$9); +} +; + + + AlterUserMappingStmt: + ALTER USER MAPPING FOR auth_ident SERVER name alter_generic_options + { + $$ = cat_str(5,mm_strdup("alter user mapping for"),$5,mm_strdup("server"),$7,$8); +} +; + + + CreateTrigStmt: + CREATE TRIGGER name TriggerActionTime TriggerEvents ON qualified_name TriggerForSpec TriggerWhen EXECUTE PROCEDURE func_name '(' TriggerFuncArgs ')' + { + $$ = cat_str(13,mm_strdup("create trigger"),$3,$4,$5,mm_strdup("on"),$7,$8,$9,mm_strdup("execute procedure"),$12,mm_strdup("("),$14,mm_strdup(")")); +} +| CREATE CONSTRAINT TRIGGER name AFTER TriggerEvents ON qualified_name OptConstrFromTable ConstraintAttributeSpec FOR EACH ROW TriggerWhen EXECUTE PROCEDURE func_name '(' TriggerFuncArgs ')' + { + $$ = cat_str(15,mm_strdup("create constraint trigger"),$4,mm_strdup("after"),$6,mm_strdup("on"),$8,$9,$10,mm_strdup("for each row"),$14,mm_strdup("execute procedure"),$17,mm_strdup("("),$19,mm_strdup(")")); +} +; + + + TriggerActionTime: + BEFORE + { + $$ = mm_strdup("before"); +} +| AFTER + { + $$ = mm_strdup("after"); +} +| INSTEAD OF + { + $$ = mm_strdup("instead of"); +} +; + + + TriggerEvents: + TriggerOneEvent + { + $$ = $1; +} +| TriggerEvents OR TriggerOneEvent + { + $$ = cat_str(3,$1,mm_strdup("or"),$3); +} +; + + + TriggerOneEvent: + INSERT + { + $$ = mm_strdup("insert"); +} +| DELETE_P + { + $$ = mm_strdup("delete"); +} +| UPDATE + { + $$ = mm_strdup("update"); +} +| UPDATE OF columnList + { + $$ = cat_str(2,mm_strdup("update of"),$3); +} +| TRUNCATE + { + $$ = mm_strdup("truncate"); +} +; + + + TriggerForSpec: + FOR TriggerForOptEach TriggerForType + { + $$ = cat_str(3,mm_strdup("for"),$2,$3); +} +| + { + $$=EMPTY; } +; + + + TriggerForOptEach: + EACH + { + $$ = mm_strdup("each"); +} +| + { + $$=EMPTY; } +; + + + TriggerForType: + ROW + { + $$ = mm_strdup("row"); +} +| STATEMENT + { + $$ = mm_strdup("statement"); +} +; + + + TriggerWhen: + WHEN '(' a_expr ')' + { + $$ = cat_str(3,mm_strdup("when ("),$3,mm_strdup(")")); +} +| + { + $$=EMPTY; } +; + + + TriggerFuncArgs: + TriggerFuncArg + { + $$ = $1; +} +| TriggerFuncArgs ',' TriggerFuncArg + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +| + { + $$=EMPTY; } +; + + + TriggerFuncArg: + Iconst + { + $$ = $1; +} +| ecpg_fconst + { + $$ = $1; +} +| ecpg_sconst + { + $$ = $1; +} +| ColLabel + { + $$ = $1; +} +; + + + OptConstrFromTable: + FROM qualified_name + { + $$ = cat_str(2,mm_strdup("from"),$2); +} +| + { + $$=EMPTY; } +; + + + ConstraintAttributeSpec: + + { + $$=EMPTY; } +| ConstraintAttributeSpec ConstraintAttributeElem + { + $$ = cat_str(2,$1,$2); +} +; + + + ConstraintAttributeElem: + NOT DEFERRABLE + { + $$ = mm_strdup("not deferrable"); +} +| DEFERRABLE + { + $$ = mm_strdup("deferrable"); +} +| INITIALLY IMMEDIATE + { + $$ = mm_strdup("initially immediate"); +} +| INITIALLY DEFERRED + { + $$ = mm_strdup("initially deferred"); +} +| NOT VALID + { + $$ = mm_strdup("not valid"); +} +| NO INHERIT + { + $$ = mm_strdup("no inherit"); +} +; + + + DropTrigStmt: + DROP TRIGGER name ON any_name opt_drop_behavior + { + $$ = cat_str(5,mm_strdup("drop trigger"),$3,mm_strdup("on"),$5,$6); +} +| DROP TRIGGER IF_P EXISTS name ON any_name opt_drop_behavior + { + $$ = cat_str(5,mm_strdup("drop trigger if exists"),$5,mm_strdup("on"),$7,$8); +} +; + + + CreateAssertStmt: + CREATE ASSERTION name CHECK '(' a_expr ')' ConstraintAttributeSpec + { +mmerror(PARSE_ERROR, ET_WARNING, "unsupported feature will be passed to server"); + $$ = cat_str(6,mm_strdup("create assertion"),$3,mm_strdup("check ("),$6,mm_strdup(")"),$8); +} +; + + + DropAssertStmt: + DROP ASSERTION name opt_drop_behavior + { +mmerror(PARSE_ERROR, ET_WARNING, "unsupported feature will be passed to server"); + $$ = cat_str(3,mm_strdup("drop assertion"),$3,$4); +} +; + + + DefineStmt: + CREATE AGGREGATE func_name aggr_args definition + { + $$ = cat_str(4,mm_strdup("create aggregate"),$3,$4,$5); +} +| CREATE AGGREGATE func_name old_aggr_definition + { + $$ = cat_str(3,mm_strdup("create aggregate"),$3,$4); +} +| CREATE OPERATOR any_operator definition + { + $$ = cat_str(3,mm_strdup("create operator"),$3,$4); +} +| CREATE TYPE_P any_name definition + { + $$ = cat_str(3,mm_strdup("create type"),$3,$4); +} +| CREATE TYPE_P any_name + { + $$ = cat_str(2,mm_strdup("create type"),$3); +} +| CREATE TYPE_P any_name AS '(' OptTableFuncElementList ')' + { + $$ = cat_str(5,mm_strdup("create type"),$3,mm_strdup("as ("),$6,mm_strdup(")")); +} +| CREATE TYPE_P any_name AS ENUM_P '(' opt_enum_val_list ')' + { + $$ = cat_str(5,mm_strdup("create type"),$3,mm_strdup("as enum ("),$7,mm_strdup(")")); +} +| CREATE TYPE_P any_name AS RANGE definition + { + $$ = cat_str(4,mm_strdup("create type"),$3,mm_strdup("as range"),$6); +} +| CREATE TEXT_P SEARCH PARSER any_name definition + { + $$ = cat_str(3,mm_strdup("create text search parser"),$5,$6); +} +| CREATE TEXT_P SEARCH DICTIONARY any_name definition + { + $$ = cat_str(3,mm_strdup("create text search dictionary"),$5,$6); +} +| CREATE TEXT_P SEARCH TEMPLATE any_name definition + { + $$ = cat_str(3,mm_strdup("create text search template"),$5,$6); +} +| CREATE TEXT_P SEARCH CONFIGURATION any_name definition + { + $$ = cat_str(3,mm_strdup("create text search configuration"),$5,$6); +} +| CREATE COLLATION any_name definition + { + $$ = cat_str(3,mm_strdup("create collation"),$3,$4); +} +| CREATE COLLATION any_name FROM any_name + { + $$ = cat_str(4,mm_strdup("create collation"),$3,mm_strdup("from"),$5); +} +; + + + definition: + '(' def_list ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(")")); +} +; + + + def_list: + def_elem + { + $$ = $1; +} +| def_list ',' def_elem + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + def_elem: + ColLabel '=' def_arg + { + $$ = cat_str(3,$1,mm_strdup("="),$3); +} +| ColLabel + { + $$ = $1; +} +; + + + def_arg: + func_type + { + $$ = $1; +} +| reserved_keyword + { + $$ = $1; +} +| qual_all_Op + { + $$ = $1; +} +| NumericOnly + { + $$ = $1; +} +| ecpg_sconst + { + $$ = $1; +} +; + + + aggr_args: + '(' type_list ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(")")); +} +| '(' '*' ')' + { + $$ = mm_strdup("( * )"); +} +; + + + old_aggr_definition: + '(' old_aggr_list ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(")")); +} +; + + + old_aggr_list: + old_aggr_elem + { + $$ = $1; +} +| old_aggr_list ',' old_aggr_elem + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + old_aggr_elem: + ecpg_ident '=' def_arg + { + $$ = cat_str(3,$1,mm_strdup("="),$3); +} +; + + + opt_enum_val_list: + enum_val_list + { + $$ = $1; +} +| + { + $$=EMPTY; } +; + + + enum_val_list: + ecpg_sconst + { + $$ = $1; +} +| enum_val_list ',' ecpg_sconst + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + AlterEnumStmt: + ALTER TYPE_P any_name ADD_P VALUE_P ecpg_sconst + { + $$ = cat_str(4,mm_strdup("alter type"),$3,mm_strdup("add value"),$6); +} +| ALTER TYPE_P any_name ADD_P VALUE_P ecpg_sconst BEFORE ecpg_sconst + { + $$ = cat_str(6,mm_strdup("alter type"),$3,mm_strdup("add value"),$6,mm_strdup("before"),$8); +} +| ALTER TYPE_P any_name ADD_P VALUE_P ecpg_sconst AFTER ecpg_sconst + { + $$ = cat_str(6,mm_strdup("alter type"),$3,mm_strdup("add value"),$6,mm_strdup("after"),$8); +} +; + + + CreateOpClassStmt: + CREATE OPERATOR CLASS any_name opt_default FOR TYPE_P Typename USING access_method opt_opfamily AS opclass_item_list + { + $$ = cat_str(10,mm_strdup("create operator class"),$4,$5,mm_strdup("for type"),$8,mm_strdup("using"),$10,$11,mm_strdup("as"),$13); +} +; + + + opclass_item_list: + opclass_item + { + $$ = $1; +} +| opclass_item_list ',' opclass_item + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + opclass_item: + OPERATOR Iconst any_operator opclass_purpose opt_recheck + { + $$ = cat_str(5,mm_strdup("operator"),$2,$3,$4,$5); +} +| OPERATOR Iconst any_operator oper_argtypes opclass_purpose opt_recheck + { + $$ = cat_str(6,mm_strdup("operator"),$2,$3,$4,$5,$6); +} +| FUNCTION Iconst func_name func_args + { + $$ = cat_str(4,mm_strdup("function"),$2,$3,$4); +} +| FUNCTION Iconst '(' type_list ')' func_name func_args + { + $$ = cat_str(7,mm_strdup("function"),$2,mm_strdup("("),$4,mm_strdup(")"),$6,$7); +} +| STORAGE Typename + { + $$ = cat_str(2,mm_strdup("storage"),$2); +} +; + + + opt_default: + DEFAULT + { + $$ = mm_strdup("default"); +} +| + { + $$=EMPTY; } +; + + + opt_opfamily: + FAMILY any_name + { + $$ = cat_str(2,mm_strdup("family"),$2); +} +| + { + $$=EMPTY; } +; + + + opclass_purpose: + FOR SEARCH + { + $$ = mm_strdup("for search"); +} +| FOR ORDER BY any_name + { + $$ = cat_str(2,mm_strdup("for order by"),$4); +} +| + { + $$=EMPTY; } +; + + + opt_recheck: + RECHECK + { +mmerror(PARSE_ERROR, ET_WARNING, "unsupported feature will be passed to server"); + $$ = mm_strdup("recheck"); +} +| + { + $$=EMPTY; } +; + + + CreateOpFamilyStmt: + CREATE OPERATOR FAMILY any_name USING access_method + { + $$ = cat_str(4,mm_strdup("create operator family"),$4,mm_strdup("using"),$6); +} +; + + + AlterOpFamilyStmt: + ALTER OPERATOR FAMILY any_name USING access_method ADD_P opclass_item_list + { + $$ = cat_str(6,mm_strdup("alter operator family"),$4,mm_strdup("using"),$6,mm_strdup("add"),$8); +} +| ALTER OPERATOR FAMILY any_name USING access_method DROP opclass_drop_list + { + $$ = cat_str(6,mm_strdup("alter operator family"),$4,mm_strdup("using"),$6,mm_strdup("drop"),$8); +} +; + + + opclass_drop_list: + opclass_drop + { + $$ = $1; +} +| opclass_drop_list ',' opclass_drop + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + opclass_drop: + OPERATOR Iconst '(' type_list ')' + { + $$ = cat_str(5,mm_strdup("operator"),$2,mm_strdup("("),$4,mm_strdup(")")); +} +| FUNCTION Iconst '(' type_list ')' + { + $$ = cat_str(5,mm_strdup("function"),$2,mm_strdup("("),$4,mm_strdup(")")); +} +; + + + DropOpClassStmt: + DROP OPERATOR CLASS any_name USING access_method opt_drop_behavior + { + $$ = cat_str(5,mm_strdup("drop operator class"),$4,mm_strdup("using"),$6,$7); +} +| DROP OPERATOR CLASS IF_P EXISTS any_name USING access_method opt_drop_behavior + { + $$ = cat_str(5,mm_strdup("drop operator class if exists"),$6,mm_strdup("using"),$8,$9); +} +; + + + DropOpFamilyStmt: + DROP OPERATOR FAMILY any_name USING access_method opt_drop_behavior + { + $$ = cat_str(5,mm_strdup("drop operator family"),$4,mm_strdup("using"),$6,$7); +} +| DROP OPERATOR FAMILY IF_P EXISTS any_name USING access_method opt_drop_behavior + { + $$ = cat_str(5,mm_strdup("drop operator family if exists"),$6,mm_strdup("using"),$8,$9); +} +; + + + DropOwnedStmt: + DROP OWNED BY name_list opt_drop_behavior + { + $$ = cat_str(3,mm_strdup("drop owned by"),$4,$5); +} +; + + + ReassignOwnedStmt: + REASSIGN OWNED BY name_list TO name + { + $$ = cat_str(4,mm_strdup("reassign owned by"),$4,mm_strdup("to"),$6); +} +; + + + DropStmt: + DROP drop_type IF_P EXISTS any_name_list opt_drop_behavior + { + $$ = cat_str(5,mm_strdup("drop"),$2,mm_strdup("if exists"),$5,$6); +} +| DROP drop_type any_name_list opt_drop_behavior + { + $$ = cat_str(4,mm_strdup("drop"),$2,$3,$4); +} +| DROP INDEX CONCURRENTLY any_name_list opt_drop_behavior + { + $$ = cat_str(3,mm_strdup("drop index concurrently"),$4,$5); +} +| DROP INDEX CONCURRENTLY IF_P EXISTS any_name_list opt_drop_behavior + { + $$ = cat_str(3,mm_strdup("drop index concurrently if exists"),$6,$7); +} +; + + + drop_type: + TABLE + { + $$ = mm_strdup("table"); +} +| SEQUENCE + { + $$ = mm_strdup("sequence"); +} +| VIEW + { + $$ = mm_strdup("view"); +} +| INDEX + { + $$ = mm_strdup("index"); +} +| FOREIGN TABLE + { + $$ = mm_strdup("foreign table"); +} +| TYPE_P + { + $$ = mm_strdup("type"); +} +| DOMAIN_P + { + $$ = mm_strdup("domain"); +} +| COLLATION + { + $$ = mm_strdup("collation"); +} +| CONVERSION_P + { + $$ = mm_strdup("conversion"); +} +| SCHEMA + { + $$ = mm_strdup("schema"); +} +| EXTENSION + { + $$ = mm_strdup("extension"); +} +| TEXT_P SEARCH PARSER + { + $$ = mm_strdup("text search parser"); +} +| TEXT_P SEARCH DICTIONARY + { + $$ = mm_strdup("text search dictionary"); +} +| TEXT_P SEARCH TEMPLATE + { + $$ = mm_strdup("text search template"); +} +| TEXT_P SEARCH CONFIGURATION + { + $$ = mm_strdup("text search configuration"); +} +; + + + any_name_list: + any_name + { + $$ = $1; +} +| any_name_list ',' any_name + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + any_name: + ColId + { + $$ = $1; +} +| ColId attrs + { + $$ = cat_str(2,$1,$2); +} +; + + + attrs: + '.' attr_name + { + $$ = cat_str(2,mm_strdup("."),$2); +} +| attrs '.' attr_name + { + $$ = cat_str(3,$1,mm_strdup("."),$3); +} +; + + + TruncateStmt: + TRUNCATE opt_table relation_expr_list opt_restart_seqs opt_drop_behavior + { + $$ = cat_str(5,mm_strdup("truncate"),$2,$3,$4,$5); +} +; + + + opt_restart_seqs: + CONTINUE_P IDENTITY_P + { + $$ = mm_strdup("continue identity"); +} +| RESTART IDENTITY_P + { + $$ = mm_strdup("restart identity"); +} +| + { + $$=EMPTY; } +; + + + CommentStmt: + COMMENT ON comment_type any_name IS comment_text + { + $$ = cat_str(5,mm_strdup("comment on"),$3,$4,mm_strdup("is"),$6); +} +| COMMENT ON AGGREGATE func_name aggr_args IS comment_text + { + $$ = cat_str(5,mm_strdup("comment on aggregate"),$4,$5,mm_strdup("is"),$7); +} +| COMMENT ON FUNCTION func_name func_args IS comment_text + { + $$ = cat_str(5,mm_strdup("comment on function"),$4,$5,mm_strdup("is"),$7); +} +| COMMENT ON OPERATOR any_operator oper_argtypes IS comment_text + { + $$ = cat_str(5,mm_strdup("comment on operator"),$4,$5,mm_strdup("is"),$7); +} +| COMMENT ON CONSTRAINT name ON any_name IS comment_text + { + $$ = cat_str(6,mm_strdup("comment on constraint"),$4,mm_strdup("on"),$6,mm_strdup("is"),$8); +} +| COMMENT ON RULE name ON any_name IS comment_text + { + $$ = cat_str(6,mm_strdup("comment on rule"),$4,mm_strdup("on"),$6,mm_strdup("is"),$8); +} +| COMMENT ON RULE name IS comment_text + { + $$ = cat_str(4,mm_strdup("comment on rule"),$4,mm_strdup("is"),$6); +} +| COMMENT ON TRIGGER name ON any_name IS comment_text + { + $$ = cat_str(6,mm_strdup("comment on trigger"),$4,mm_strdup("on"),$6,mm_strdup("is"),$8); +} +| COMMENT ON OPERATOR CLASS any_name USING access_method IS comment_text + { + $$ = cat_str(6,mm_strdup("comment on operator class"),$5,mm_strdup("using"),$7,mm_strdup("is"),$9); +} +| COMMENT ON OPERATOR FAMILY any_name USING access_method IS comment_text + { + $$ = cat_str(6,mm_strdup("comment on operator family"),$5,mm_strdup("using"),$7,mm_strdup("is"),$9); +} +| COMMENT ON LARGE_P OBJECT_P NumericOnly IS comment_text + { + $$ = cat_str(4,mm_strdup("comment on large object"),$5,mm_strdup("is"),$7); +} +| COMMENT ON CAST '(' Typename AS Typename ')' IS comment_text + { + $$ = cat_str(6,mm_strdup("comment on cast ("),$5,mm_strdup("as"),$7,mm_strdup(") is"),$10); +} +| COMMENT ON opt_procedural LANGUAGE any_name IS comment_text + { + $$ = cat_str(6,mm_strdup("comment on"),$3,mm_strdup("language"),$5,mm_strdup("is"),$7); +} +| COMMENT ON TEXT_P SEARCH PARSER any_name IS comment_text + { + $$ = cat_str(4,mm_strdup("comment on text search parser"),$6,mm_strdup("is"),$8); +} +| COMMENT ON TEXT_P SEARCH DICTIONARY any_name IS comment_text + { + $$ = cat_str(4,mm_strdup("comment on text search dictionary"),$6,mm_strdup("is"),$8); +} +| COMMENT ON TEXT_P SEARCH TEMPLATE any_name IS comment_text + { + $$ = cat_str(4,mm_strdup("comment on text search template"),$6,mm_strdup("is"),$8); +} +| COMMENT ON TEXT_P SEARCH CONFIGURATION any_name IS comment_text + { + $$ = cat_str(4,mm_strdup("comment on text search configuration"),$6,mm_strdup("is"),$8); +} +; + + + comment_type: + COLUMN + { + $$ = mm_strdup("column"); +} +| DATABASE + { + $$ = mm_strdup("database"); +} +| SCHEMA + { + $$ = mm_strdup("schema"); +} +| INDEX + { + $$ = mm_strdup("index"); +} +| SEQUENCE + { + $$ = mm_strdup("sequence"); +} +| TABLE + { + $$ = mm_strdup("table"); +} +| DOMAIN_P + { + $$ = mm_strdup("domain"); +} +| TYPE_P + { + $$ = mm_strdup("type"); +} +| VIEW + { + $$ = mm_strdup("view"); +} +| COLLATION + { + $$ = mm_strdup("collation"); +} +| CONVERSION_P + { + $$ = mm_strdup("conversion"); +} +| TABLESPACE + { + $$ = mm_strdup("tablespace"); +} +| EXTENSION + { + $$ = mm_strdup("extension"); +} +| ROLE + { + $$ = mm_strdup("role"); +} +| FOREIGN TABLE + { + $$ = mm_strdup("foreign table"); +} +| SERVER + { + $$ = mm_strdup("server"); +} +| FOREIGN DATA_P WRAPPER + { + $$ = mm_strdup("foreign data wrapper"); +} +; + + + comment_text: + ecpg_sconst + { + $$ = $1; +} +| NULL_P + { + $$ = mm_strdup("null"); +} +; + + + SecLabelStmt: + SECURITY LABEL opt_provider ON security_label_type any_name IS security_label + { + $$ = cat_str(7,mm_strdup("security label"),$3,mm_strdup("on"),$5,$6,mm_strdup("is"),$8); +} +| SECURITY LABEL opt_provider ON AGGREGATE func_name aggr_args IS security_label + { + $$ = cat_str(7,mm_strdup("security label"),$3,mm_strdup("on aggregate"),$6,$7,mm_strdup("is"),$9); +} +| SECURITY LABEL opt_provider ON FUNCTION func_name func_args IS security_label + { + $$ = cat_str(7,mm_strdup("security label"),$3,mm_strdup("on function"),$6,$7,mm_strdup("is"),$9); +} +| SECURITY LABEL opt_provider ON LARGE_P OBJECT_P NumericOnly IS security_label + { + $$ = cat_str(6,mm_strdup("security label"),$3,mm_strdup("on large object"),$7,mm_strdup("is"),$9); +} +| SECURITY LABEL opt_provider ON opt_procedural LANGUAGE any_name IS security_label + { + $$ = cat_str(8,mm_strdup("security label"),$3,mm_strdup("on"),$5,mm_strdup("language"),$7,mm_strdup("is"),$9); +} +; + + + opt_provider: + FOR ColId_or_Sconst + { + $$ = cat_str(2,mm_strdup("for"),$2); +} +| + { + $$=EMPTY; } +; + + + security_label_type: + COLUMN + { + $$ = mm_strdup("column"); +} +| DATABASE + { + $$ = mm_strdup("database"); +} +| FOREIGN TABLE + { + $$ = mm_strdup("foreign table"); +} +| SCHEMA + { + $$ = mm_strdup("schema"); +} +| SEQUENCE + { + $$ = mm_strdup("sequence"); +} +| TABLE + { + $$ = mm_strdup("table"); +} +| DOMAIN_P + { + $$ = mm_strdup("domain"); +} +| ROLE + { + $$ = mm_strdup("role"); +} +| TABLESPACE + { + $$ = mm_strdup("tablespace"); +} +| TYPE_P + { + $$ = mm_strdup("type"); +} +| VIEW + { + $$ = mm_strdup("view"); +} +; + + + security_label: + ecpg_sconst + { + $$ = $1; +} +| NULL_P + { + $$ = mm_strdup("null"); +} +; + + + FetchStmt: + FETCH fetch_args + { + $$ = cat_str(2,mm_strdup("fetch"),$2); +} +| MOVE fetch_args + { + $$ = cat_str(2,mm_strdup("move"),$2); +} + | FETCH fetch_args ecpg_fetch_into + { + $$ = cat2_str(mm_strdup("fetch"), $2); + } + | FETCH FORWARD cursor_name opt_ecpg_fetch_into + { + char *cursor_marker = $3[0] == ':' ? mm_strdup("$0") : $3; + add_additional_variables($3, false); + $$ = cat_str(2, mm_strdup("fetch forward"), cursor_marker); + } + | FETCH FORWARD from_in cursor_name opt_ecpg_fetch_into + { + char *cursor_marker = $4[0] == ':' ? mm_strdup("$0") : $4; + add_additional_variables($4, false); + $$ = cat_str(2, mm_strdup("fetch forward from"), cursor_marker); + } + | FETCH BACKWARD cursor_name opt_ecpg_fetch_into + { + char *cursor_marker = $3[0] == ':' ? mm_strdup("$0") : $3; + add_additional_variables($3, false); + $$ = cat_str(2, mm_strdup("fetch backward"), cursor_marker); + } + | FETCH BACKWARD from_in cursor_name opt_ecpg_fetch_into + { + char *cursor_marker = $4[0] == ':' ? mm_strdup("$0") : $4; + add_additional_variables($4, false); + $$ = cat_str(2, mm_strdup("fetch backward from"), cursor_marker); + } + | MOVE FORWARD cursor_name + { + char *cursor_marker = $3[0] == ':' ? mm_strdup("$0") : $3; + add_additional_variables($3, false); + $$ = cat_str(2, mm_strdup("move forward"), cursor_marker); + } + | MOVE FORWARD from_in cursor_name + { + char *cursor_marker = $4[0] == ':' ? mm_strdup("$0") : $4; + add_additional_variables($4, false); + $$ = cat_str(2, mm_strdup("move forward from"), cursor_marker); + } + | MOVE BACKWARD cursor_name + { + char *cursor_marker = $3[0] == ':' ? mm_strdup("$0") : $3; + add_additional_variables($3, false); + $$ = cat_str(2, mm_strdup("move backward"), cursor_marker); + } + | MOVE BACKWARD from_in cursor_name + { + char *cursor_marker = $4[0] == ':' ? mm_strdup("$0") : $4; + add_additional_variables($4, false); + $$ = cat_str(2, mm_strdup("move backward from"), cursor_marker); + } +; + + + fetch_args: + cursor_name + { + add_additional_variables($1, false); + if ($1[0] == ':') + { + free($1); + $1 = mm_strdup("$0"); + } + + $$ = $1; +} +| from_in cursor_name + { + add_additional_variables($2, false); + if ($2[0] == ':') + { + free($2); + $2 = mm_strdup("$0"); + } + + $$ = cat_str(2,$1,$2); +} +| NEXT opt_from_in cursor_name + { + add_additional_variables($3, false); + if ($3[0] == ':') + { + free($3); + $3 = mm_strdup("$0"); + } + + $$ = cat_str(3,mm_strdup("next"),$2,$3); +} +| PRIOR opt_from_in cursor_name + { + add_additional_variables($3, false); + if ($3[0] == ':') + { + free($3); + $3 = mm_strdup("$0"); + } + + $$ = cat_str(3,mm_strdup("prior"),$2,$3); +} +| FIRST_P opt_from_in cursor_name + { + add_additional_variables($3, false); + if ($3[0] == ':') + { + free($3); + $3 = mm_strdup("$0"); + } + + $$ = cat_str(3,mm_strdup("first"),$2,$3); +} +| LAST_P opt_from_in cursor_name + { + add_additional_variables($3, false); + if ($3[0] == ':') + { + free($3); + $3 = mm_strdup("$0"); + } + + $$ = cat_str(3,mm_strdup("last"),$2,$3); +} +| ABSOLUTE_P SignedIconst opt_from_in cursor_name + { + add_additional_variables($4, false); + if ($4[0] == ':') + { + free($4); + $4 = mm_strdup("$0"); + } + if ($2[0] == '$') + { + free($2); + $2 = mm_strdup("$0"); + } + + $$ = cat_str(4,mm_strdup("absolute"),$2,$3,$4); +} +| RELATIVE_P SignedIconst opt_from_in cursor_name + { + add_additional_variables($4, false); + if ($4[0] == ':') + { + free($4); + $4 = mm_strdup("$0"); + } + if ($2[0] == '$') + { + free($2); + $2 = mm_strdup("$0"); + } + + $$ = cat_str(4,mm_strdup("relative"),$2,$3,$4); +} +| SignedIconst opt_from_in cursor_name + { + add_additional_variables($3, false); + if ($3[0] == ':') + { + free($3); + $3 = mm_strdup("$0"); + } + if ($1[0] == '$') + { + free($1); + $1 = mm_strdup("$0"); + } + + $$ = cat_str(3,$1,$2,$3); +} +| ALL opt_from_in cursor_name + { + add_additional_variables($3, false); + if ($3[0] == ':') + { + free($3); + $3 = mm_strdup("$0"); + } + + $$ = cat_str(3,mm_strdup("all"),$2,$3); +} +| FORWARD SignedIconst opt_from_in cursor_name + { + add_additional_variables($4, false); + if ($4[0] == ':') + { + free($4); + $4 = mm_strdup("$0"); + } + if ($2[0] == '$') + { + free($2); + $2 = mm_strdup("$0"); + } + + $$ = cat_str(4,mm_strdup("forward"),$2,$3,$4); +} +| FORWARD ALL opt_from_in cursor_name + { + add_additional_variables($4, false); + if ($4[0] == ':') + { + free($4); + $4 = mm_strdup("$0"); + } + + $$ = cat_str(3,mm_strdup("forward all"),$3,$4); +} +| BACKWARD SignedIconst opt_from_in cursor_name + { + add_additional_variables($4, false); + if ($4[0] == ':') + { + free($4); + $4 = mm_strdup("$0"); + } + if ($2[0] == '$') + { + free($2); + $2 = mm_strdup("$0"); + } + + $$ = cat_str(4,mm_strdup("backward"),$2,$3,$4); +} +| BACKWARD ALL opt_from_in cursor_name + { + add_additional_variables($4, false); + if ($4[0] == ':') + { + free($4); + $4 = mm_strdup("$0"); + } + + $$ = cat_str(3,mm_strdup("backward all"),$3,$4); +} +; + + + from_in: + FROM + { + $$ = mm_strdup("from"); +} +| IN_P + { + $$ = mm_strdup("in"); +} +; + + + opt_from_in: + from_in + { + $$ = $1; +} +| + { + $$=EMPTY; } +; + + + GrantStmt: + GRANT privileges ON privilege_target TO grantee_list opt_grant_grant_option + { + $$ = cat_str(7,mm_strdup("grant"),$2,mm_strdup("on"),$4,mm_strdup("to"),$6,$7); +} +; + + + RevokeStmt: + REVOKE privileges ON privilege_target FROM grantee_list opt_drop_behavior + { + $$ = cat_str(7,mm_strdup("revoke"),$2,mm_strdup("on"),$4,mm_strdup("from"),$6,$7); +} +| REVOKE GRANT OPTION FOR privileges ON privilege_target FROM grantee_list opt_drop_behavior + { + $$ = cat_str(7,mm_strdup("revoke grant option for"),$5,mm_strdup("on"),$7,mm_strdup("from"),$9,$10); +} +; + + + privileges: + privilege_list + { + $$ = $1; +} +| ALL + { + $$ = mm_strdup("all"); +} +| ALL PRIVILEGES + { + $$ = mm_strdup("all privileges"); +} +| ALL '(' columnList ')' + { + $$ = cat_str(3,mm_strdup("all ("),$3,mm_strdup(")")); +} +| ALL PRIVILEGES '(' columnList ')' + { + $$ = cat_str(3,mm_strdup("all privileges ("),$4,mm_strdup(")")); +} +; + + + privilege_list: + privilege + { + $$ = $1; +} +| privilege_list ',' privilege + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + privilege: + SELECT opt_column_list + { + $$ = cat_str(2,mm_strdup("select"),$2); +} +| REFERENCES opt_column_list + { + $$ = cat_str(2,mm_strdup("references"),$2); +} +| CREATE opt_column_list + { + $$ = cat_str(2,mm_strdup("create"),$2); +} +| ColId opt_column_list + { + $$ = cat_str(2,$1,$2); +} +; + + + privilege_target: + qualified_name_list + { + $$ = $1; +} +| TABLE qualified_name_list + { + $$ = cat_str(2,mm_strdup("table"),$2); +} +| SEQUENCE qualified_name_list + { + $$ = cat_str(2,mm_strdup("sequence"),$2); +} +| FOREIGN DATA_P WRAPPER name_list + { + $$ = cat_str(2,mm_strdup("foreign data wrapper"),$4); +} +| FOREIGN SERVER name_list + { + $$ = cat_str(2,mm_strdup("foreign server"),$3); +} +| FUNCTION function_with_argtypes_list + { + $$ = cat_str(2,mm_strdup("function"),$2); +} +| DATABASE name_list + { + $$ = cat_str(2,mm_strdup("database"),$2); +} +| DOMAIN_P any_name_list + { + $$ = cat_str(2,mm_strdup("domain"),$2); +} +| LANGUAGE name_list + { + $$ = cat_str(2,mm_strdup("language"),$2); +} +| LARGE_P OBJECT_P NumericOnly_list + { + $$ = cat_str(2,mm_strdup("large object"),$3); +} +| SCHEMA name_list + { + $$ = cat_str(2,mm_strdup("schema"),$2); +} +| TABLESPACE name_list + { + $$ = cat_str(2,mm_strdup("tablespace"),$2); +} +| TYPE_P any_name_list + { + $$ = cat_str(2,mm_strdup("type"),$2); +} +| ALL TABLES IN_P SCHEMA name_list + { + $$ = cat_str(2,mm_strdup("all tables in schema"),$5); +} +| ALL SEQUENCES IN_P SCHEMA name_list + { + $$ = cat_str(2,mm_strdup("all sequences in schema"),$5); +} +| ALL FUNCTIONS IN_P SCHEMA name_list + { + $$ = cat_str(2,mm_strdup("all functions in schema"),$5); +} +; + + + grantee_list: + grantee + { + $$ = $1; +} +| grantee_list ',' grantee + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + grantee: + RoleId + { + $$ = $1; +} +| GROUP_P RoleId + { + $$ = cat_str(2,mm_strdup("group"),$2); +} +; + + + opt_grant_grant_option: + WITH GRANT OPTION + { + $$ = mm_strdup("with grant option"); +} +| + { + $$=EMPTY; } +; + + + function_with_argtypes_list: + function_with_argtypes + { + $$ = $1; +} +| function_with_argtypes_list ',' function_with_argtypes + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + function_with_argtypes: + func_name func_args + { + $$ = cat_str(2,$1,$2); +} +; + + + GrantRoleStmt: + GRANT privilege_list TO name_list opt_grant_admin_option opt_granted_by + { + $$ = cat_str(6,mm_strdup("grant"),$2,mm_strdup("to"),$4,$5,$6); +} +; + + + RevokeRoleStmt: + REVOKE privilege_list FROM name_list opt_granted_by opt_drop_behavior + { + $$ = cat_str(6,mm_strdup("revoke"),$2,mm_strdup("from"),$4,$5,$6); +} +| REVOKE ADMIN OPTION FOR privilege_list FROM name_list opt_granted_by opt_drop_behavior + { + $$ = cat_str(6,mm_strdup("revoke admin option for"),$5,mm_strdup("from"),$7,$8,$9); +} +; + + + opt_grant_admin_option: + WITH ADMIN OPTION + { + $$ = mm_strdup("with admin option"); +} +| + { + $$=EMPTY; } +; + + + opt_granted_by: + GRANTED BY RoleId + { + $$ = cat_str(2,mm_strdup("granted by"),$3); +} +| + { + $$=EMPTY; } +; + + + AlterDefaultPrivilegesStmt: + ALTER DEFAULT PRIVILEGES DefACLOptionList DefACLAction + { + $$ = cat_str(3,mm_strdup("alter default privileges"),$4,$5); +} +; + + + DefACLOptionList: + DefACLOptionList DefACLOption + { + $$ = cat_str(2,$1,$2); +} +| + { + $$=EMPTY; } +; + + + DefACLOption: + IN_P SCHEMA name_list + { + $$ = cat_str(2,mm_strdup("in schema"),$3); +} +| FOR ROLE name_list + { + $$ = cat_str(2,mm_strdup("for role"),$3); +} +| FOR USER name_list + { + $$ = cat_str(2,mm_strdup("for user"),$3); +} +; + + + DefACLAction: + GRANT privileges ON defacl_privilege_target TO grantee_list opt_grant_grant_option + { + $$ = cat_str(7,mm_strdup("grant"),$2,mm_strdup("on"),$4,mm_strdup("to"),$6,$7); +} +| REVOKE privileges ON defacl_privilege_target FROM grantee_list opt_drop_behavior + { + $$ = cat_str(7,mm_strdup("revoke"),$2,mm_strdup("on"),$4,mm_strdup("from"),$6,$7); +} +| REVOKE GRANT OPTION FOR privileges ON defacl_privilege_target FROM grantee_list opt_drop_behavior + { + $$ = cat_str(7,mm_strdup("revoke grant option for"),$5,mm_strdup("on"),$7,mm_strdup("from"),$9,$10); +} +; + + + defacl_privilege_target: + TABLES + { + $$ = mm_strdup("tables"); +} +| FUNCTIONS + { + $$ = mm_strdup("functions"); +} +| SEQUENCES + { + $$ = mm_strdup("sequences"); +} +| TYPES_P + { + $$ = mm_strdup("types"); +} +; + + + IndexStmt: + CREATE opt_unique INDEX opt_concurrently opt_index_name ON qualified_name access_method_clause '(' index_params ')' opt_reloptions OptTableSpace where_clause + { + $$ = cat_str(14,mm_strdup("create"),$2,mm_strdup("index"),$4,$5,mm_strdup("on"),$7,$8,mm_strdup("("),$10,mm_strdup(")"),$12,$13,$14); +} +; + + + opt_unique: + UNIQUE + { + $$ = mm_strdup("unique"); +} +| + { + $$=EMPTY; } +; + + + opt_concurrently: + CONCURRENTLY + { + $$ = mm_strdup("concurrently"); +} +| + { + $$=EMPTY; } +; + + + opt_index_name: + index_name + { + $$ = $1; +} +| + { + $$=EMPTY; } +; + + + access_method_clause: + USING access_method + { + $$ = cat_str(2,mm_strdup("using"),$2); +} +| + { + $$=EMPTY; } +; + + + index_params: + index_elem + { + $$ = $1; +} +| index_params ',' index_elem + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + index_elem: + ColId opt_collate opt_class opt_asc_desc opt_nulls_order + { + $$ = cat_str(5,$1,$2,$3,$4,$5); +} +| func_expr opt_collate opt_class opt_asc_desc opt_nulls_order + { + $$ = cat_str(5,$1,$2,$3,$4,$5); +} +| '(' a_expr ')' opt_collate opt_class opt_asc_desc opt_nulls_order + { + $$ = cat_str(7,mm_strdup("("),$2,mm_strdup(")"),$4,$5,$6,$7); +} +; + + + opt_collate: + COLLATE any_name + { + $$ = cat_str(2,mm_strdup("collate"),$2); +} +| + { + $$=EMPTY; } +; + + + opt_class: + any_name + { + $$ = $1; +} +| USING any_name + { + $$ = cat_str(2,mm_strdup("using"),$2); +} +| + { + $$=EMPTY; } +; + + + opt_asc_desc: + ASC + { + $$ = mm_strdup("asc"); +} +| DESC + { + $$ = mm_strdup("desc"); +} +| + { + $$=EMPTY; } +; + + + opt_nulls_order: + NULLS_FIRST + { + $$ = mm_strdup("nulls first"); +} +| NULLS_LAST + { + $$ = mm_strdup("nulls last"); +} +| + { + $$=EMPTY; } +; + + + CreateFunctionStmt: + CREATE opt_or_replace FUNCTION func_name func_args_with_defaults RETURNS func_return createfunc_opt_list opt_definition + { + $$ = cat_str(9,mm_strdup("create"),$2,mm_strdup("function"),$4,$5,mm_strdup("returns"),$7,$8,$9); +} +| CREATE opt_or_replace FUNCTION func_name func_args_with_defaults RETURNS TABLE '(' table_func_column_list ')' createfunc_opt_list opt_definition + { + $$ = cat_str(10,mm_strdup("create"),$2,mm_strdup("function"),$4,$5,mm_strdup("returns table ("),$9,mm_strdup(")"),$11,$12); +} +| CREATE opt_or_replace FUNCTION func_name func_args_with_defaults createfunc_opt_list opt_definition + { + $$ = cat_str(7,mm_strdup("create"),$2,mm_strdup("function"),$4,$5,$6,$7); +} +; + + + opt_or_replace: + OR REPLACE + { + $$ = mm_strdup("or replace"); +} +| + { + $$=EMPTY; } +; + + + func_args: + '(' func_args_list ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(")")); +} +| '(' ')' + { + $$ = mm_strdup("( )"); +} +; + + + func_args_list: + func_arg + { + $$ = $1; +} +| func_args_list ',' func_arg + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + func_args_with_defaults: + '(' func_args_with_defaults_list ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(")")); +} +| '(' ')' + { + $$ = mm_strdup("( )"); +} +; + + + func_args_with_defaults_list: + func_arg_with_default + { + $$ = $1; +} +| func_args_with_defaults_list ',' func_arg_with_default + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + func_arg: + arg_class param_name func_type + { + $$ = cat_str(3,$1,$2,$3); +} +| param_name arg_class func_type + { + $$ = cat_str(3,$1,$2,$3); +} +| param_name func_type + { + $$ = cat_str(2,$1,$2); +} +| arg_class func_type + { + $$ = cat_str(2,$1,$2); +} +| func_type + { + $$ = $1; +} +; + + + arg_class: + IN_P + { + $$ = mm_strdup("in"); +} +| OUT_P + { + $$ = mm_strdup("out"); +} +| INOUT + { + $$ = mm_strdup("inout"); +} +| IN_P OUT_P + { + $$ = mm_strdup("in out"); +} +| VARIADIC + { + $$ = mm_strdup("variadic"); +} +; + + + param_name: + type_function_name + { + $$ = $1; +} +; + + + func_return: + func_type + { + $$ = $1; +} +; + + + func_type: + Typename + { + $$ = $1; +} +| type_function_name attrs '%' TYPE_P + { + $$ = cat_str(3,$1,$2,mm_strdup("% type")); +} +| SETOF type_function_name attrs '%' TYPE_P + { + $$ = cat_str(4,mm_strdup("setof"),$2,$3,mm_strdup("% type")); +} +; + + + func_arg_with_default: + func_arg + { + $$ = $1; +} +| func_arg DEFAULT a_expr + { + $$ = cat_str(3,$1,mm_strdup("default"),$3); +} +| func_arg '=' a_expr + { + $$ = cat_str(3,$1,mm_strdup("="),$3); +} +; + + + createfunc_opt_list: + createfunc_opt_item + { + $$ = $1; +} +| createfunc_opt_list createfunc_opt_item + { + $$ = cat_str(2,$1,$2); +} +; + + + common_func_opt_item: + CALLED ON NULL_P INPUT_P + { + $$ = mm_strdup("called on null input"); +} +| RETURNS NULL_P ON NULL_P INPUT_P + { + $$ = mm_strdup("returns null on null input"); +} +| STRICT_P + { + $$ = mm_strdup("strict"); +} +| IMMUTABLE + { + $$ = mm_strdup("immutable"); +} +| STABLE + { + $$ = mm_strdup("stable"); +} +| VOLATILE + { + $$ = mm_strdup("volatile"); +} +| EXTERNAL SECURITY DEFINER + { + $$ = mm_strdup("external security definer"); +} +| EXTERNAL SECURITY INVOKER + { + $$ = mm_strdup("external security invoker"); +} +| SECURITY DEFINER + { + $$ = mm_strdup("security definer"); +} +| SECURITY INVOKER + { + $$ = mm_strdup("security invoker"); +} +| LEAKPROOF + { + $$ = mm_strdup("leakproof"); +} +| NOT LEAKPROOF + { + $$ = mm_strdup("not leakproof"); +} +| COST NumericOnly + { + $$ = cat_str(2,mm_strdup("cost"),$2); +} +| ROWS NumericOnly + { + $$ = cat_str(2,mm_strdup("rows"),$2); +} +| FunctionSetResetClause + { + $$ = $1; +} +; + + + createfunc_opt_item: + AS func_as + { + $$ = cat_str(2,mm_strdup("as"),$2); +} +| LANGUAGE ColId_or_Sconst + { + $$ = cat_str(2,mm_strdup("language"),$2); +} +| WINDOW + { + $$ = mm_strdup("window"); +} +| common_func_opt_item + { + $$ = $1; +} +; + + + func_as: + ecpg_sconst + { + $$ = $1; +} +| ecpg_sconst ',' ecpg_sconst + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + opt_definition: + WITH definition + { + $$ = cat_str(2,mm_strdup("with"),$2); +} +| + { + $$=EMPTY; } +; + + + table_func_column: + param_name func_type + { + $$ = cat_str(2,$1,$2); +} +; + + + table_func_column_list: + table_func_column + { + $$ = $1; +} +| table_func_column_list ',' table_func_column + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + AlterFunctionStmt: + ALTER FUNCTION function_with_argtypes alterfunc_opt_list opt_restrict + { + $$ = cat_str(4,mm_strdup("alter function"),$3,$4,$5); +} +; + + + alterfunc_opt_list: + common_func_opt_item + { + $$ = $1; +} +| alterfunc_opt_list common_func_opt_item + { + $$ = cat_str(2,$1,$2); +} +; + + + opt_restrict: + RESTRICT + { + $$ = mm_strdup("restrict"); +} +| + { + $$=EMPTY; } +; + + + RemoveFuncStmt: + DROP FUNCTION func_name func_args opt_drop_behavior + { + $$ = cat_str(4,mm_strdup("drop function"),$3,$4,$5); +} +| DROP FUNCTION IF_P EXISTS func_name func_args opt_drop_behavior + { + $$ = cat_str(4,mm_strdup("drop function if exists"),$5,$6,$7); +} +; + + + RemoveAggrStmt: + DROP AGGREGATE func_name aggr_args opt_drop_behavior + { + $$ = cat_str(4,mm_strdup("drop aggregate"),$3,$4,$5); +} +| DROP AGGREGATE IF_P EXISTS func_name aggr_args opt_drop_behavior + { + $$ = cat_str(4,mm_strdup("drop aggregate if exists"),$5,$6,$7); +} +; + + + RemoveOperStmt: + DROP OPERATOR any_operator oper_argtypes opt_drop_behavior + { + $$ = cat_str(4,mm_strdup("drop operator"),$3,$4,$5); +} +| DROP OPERATOR IF_P EXISTS any_operator oper_argtypes opt_drop_behavior + { + $$ = cat_str(4,mm_strdup("drop operator if exists"),$5,$6,$7); +} +; + + + oper_argtypes: + '(' Typename ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(")")); +} +| '(' Typename ',' Typename ')' + { + $$ = cat_str(5,mm_strdup("("),$2,mm_strdup(","),$4,mm_strdup(")")); +} +| '(' NONE ',' Typename ')' + { + $$ = cat_str(3,mm_strdup("( none ,"),$4,mm_strdup(")")); +} +| '(' Typename ',' NONE ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(", none )")); +} +; + + + any_operator: + all_Op + { + $$ = $1; +} +| ColId '.' any_operator + { + $$ = cat_str(3,$1,mm_strdup("."),$3); +} +; + + + DoStmt: + DO dostmt_opt_list + { + $$ = cat_str(2,mm_strdup("do"),$2); +} +; + + + dostmt_opt_list: + dostmt_opt_item + { + $$ = $1; +} +| dostmt_opt_list dostmt_opt_item + { + $$ = cat_str(2,$1,$2); +} +; + + + dostmt_opt_item: + ecpg_sconst + { + $$ = $1; +} +| LANGUAGE ColId_or_Sconst + { + $$ = cat_str(2,mm_strdup("language"),$2); +} +; + + + CreateCastStmt: + CREATE CAST '(' Typename AS Typename ')' WITH FUNCTION function_with_argtypes cast_context + { + $$ = cat_str(7,mm_strdup("create cast ("),$4,mm_strdup("as"),$6,mm_strdup(") with function"),$10,$11); +} +| CREATE CAST '(' Typename AS Typename ')' WITHOUT FUNCTION cast_context + { + $$ = cat_str(6,mm_strdup("create cast ("),$4,mm_strdup("as"),$6,mm_strdup(") without function"),$10); +} +| CREATE CAST '(' Typename AS Typename ')' WITH INOUT cast_context + { + $$ = cat_str(6,mm_strdup("create cast ("),$4,mm_strdup("as"),$6,mm_strdup(") with inout"),$10); +} +; + + + cast_context: + AS IMPLICIT_P + { + $$ = mm_strdup("as implicit"); +} +| AS ASSIGNMENT + { + $$ = mm_strdup("as assignment"); +} +| + { + $$=EMPTY; } +; + + + DropCastStmt: + DROP CAST opt_if_exists '(' Typename AS Typename ')' opt_drop_behavior + { + $$ = cat_str(8,mm_strdup("drop cast"),$3,mm_strdup("("),$5,mm_strdup("as"),$7,mm_strdup(")"),$9); +} +; + + + opt_if_exists: + IF_P EXISTS + { + $$ = mm_strdup("if exists"); +} +| + { + $$=EMPTY; } +; + + + ReindexStmt: + REINDEX reindex_type qualified_name opt_force + { + $$ = cat_str(4,mm_strdup("reindex"),$2,$3,$4); +} +| REINDEX SYSTEM_P name opt_force + { + $$ = cat_str(3,mm_strdup("reindex system"),$3,$4); +} +| REINDEX DATABASE name opt_force + { + $$ = cat_str(3,mm_strdup("reindex database"),$3,$4); +} +; + + + reindex_type: + INDEX + { + $$ = mm_strdup("index"); +} +| TABLE + { + $$ = mm_strdup("table"); +} +; + + + opt_force: + FORCE + { + $$ = mm_strdup("force"); +} +| + { + $$=EMPTY; } +; + + + RenameStmt: + ALTER AGGREGATE func_name aggr_args RENAME TO name + { + $$ = cat_str(5,mm_strdup("alter aggregate"),$3,$4,mm_strdup("rename to"),$7); +} +| ALTER COLLATION any_name RENAME TO name + { + $$ = cat_str(4,mm_strdup("alter collation"),$3,mm_strdup("rename to"),$6); +} +| ALTER CONVERSION_P any_name RENAME TO name + { + $$ = cat_str(4,mm_strdup("alter conversion"),$3,mm_strdup("rename to"),$6); +} +| ALTER DATABASE database_name RENAME TO database_name + { + $$ = cat_str(4,mm_strdup("alter database"),$3,mm_strdup("rename to"),$6); +} +| ALTER DOMAIN_P any_name RENAME TO name + { + $$ = cat_str(4,mm_strdup("alter domain"),$3,mm_strdup("rename to"),$6); +} +| ALTER DOMAIN_P any_name RENAME CONSTRAINT name TO name + { + $$ = cat_str(6,mm_strdup("alter domain"),$3,mm_strdup("rename constraint"),$6,mm_strdup("to"),$8); +} +| ALTER FOREIGN DATA_P WRAPPER name RENAME TO name + { + $$ = cat_str(4,mm_strdup("alter foreign data wrapper"),$5,mm_strdup("rename to"),$8); +} +| ALTER FUNCTION function_with_argtypes RENAME TO name + { + $$ = cat_str(4,mm_strdup("alter function"),$3,mm_strdup("rename to"),$6); +} +| ALTER GROUP_P RoleId RENAME TO RoleId + { + $$ = cat_str(4,mm_strdup("alter group"),$3,mm_strdup("rename to"),$6); +} +| ALTER opt_procedural LANGUAGE name RENAME TO name + { + $$ = cat_str(6,mm_strdup("alter"),$2,mm_strdup("language"),$4,mm_strdup("rename to"),$7); +} +| ALTER OPERATOR CLASS any_name USING access_method RENAME TO name + { + $$ = cat_str(6,mm_strdup("alter operator class"),$4,mm_strdup("using"),$6,mm_strdup("rename to"),$9); +} +| ALTER OPERATOR FAMILY any_name USING access_method RENAME TO name + { + $$ = cat_str(6,mm_strdup("alter operator family"),$4,mm_strdup("using"),$6,mm_strdup("rename to"),$9); +} +| ALTER SCHEMA name RENAME TO name + { + $$ = cat_str(4,mm_strdup("alter schema"),$3,mm_strdup("rename to"),$6); +} +| ALTER SERVER name RENAME TO name + { + $$ = cat_str(4,mm_strdup("alter server"),$3,mm_strdup("rename to"),$6); +} +| ALTER TABLE relation_expr RENAME TO name + { + $$ = cat_str(4,mm_strdup("alter table"),$3,mm_strdup("rename to"),$6); +} +| ALTER TABLE IF_P EXISTS relation_expr RENAME TO name + { + $$ = cat_str(4,mm_strdup("alter table if exists"),$5,mm_strdup("rename to"),$8); +} +| ALTER SEQUENCE qualified_name RENAME TO name + { + $$ = cat_str(4,mm_strdup("alter sequence"),$3,mm_strdup("rename to"),$6); +} +| ALTER SEQUENCE IF_P EXISTS qualified_name RENAME TO name + { + $$ = cat_str(4,mm_strdup("alter sequence if exists"),$5,mm_strdup("rename to"),$8); +} +| ALTER VIEW qualified_name RENAME TO name + { + $$ = cat_str(4,mm_strdup("alter view"),$3,mm_strdup("rename to"),$6); +} +| ALTER VIEW IF_P EXISTS qualified_name RENAME TO name + { + $$ = cat_str(4,mm_strdup("alter view if exists"),$5,mm_strdup("rename to"),$8); +} +| ALTER INDEX qualified_name RENAME TO name + { + $$ = cat_str(4,mm_strdup("alter index"),$3,mm_strdup("rename to"),$6); +} +| ALTER INDEX IF_P EXISTS qualified_name RENAME TO name + { + $$ = cat_str(4,mm_strdup("alter index if exists"),$5,mm_strdup("rename to"),$8); +} +| ALTER FOREIGN TABLE relation_expr RENAME TO name + { + $$ = cat_str(4,mm_strdup("alter foreign table"),$4,mm_strdup("rename to"),$7); +} +| ALTER FOREIGN TABLE IF_P EXISTS relation_expr RENAME TO name + { + $$ = cat_str(4,mm_strdup("alter foreign table if exists"),$6,mm_strdup("rename to"),$9); +} +| ALTER TABLE relation_expr RENAME opt_column name TO name + { + $$ = cat_str(7,mm_strdup("alter table"),$3,mm_strdup("rename"),$5,$6,mm_strdup("to"),$8); +} +| ALTER TABLE IF_P EXISTS relation_expr RENAME opt_column name TO name + { + $$ = cat_str(7,mm_strdup("alter table if exists"),$5,mm_strdup("rename"),$7,$8,mm_strdup("to"),$10); +} +| ALTER TABLE relation_expr RENAME CONSTRAINT name TO name + { + $$ = cat_str(6,mm_strdup("alter table"),$3,mm_strdup("rename constraint"),$6,mm_strdup("to"),$8); +} +| ALTER FOREIGN TABLE relation_expr RENAME opt_column name TO name + { + $$ = cat_str(7,mm_strdup("alter foreign table"),$4,mm_strdup("rename"),$6,$7,mm_strdup("to"),$9); +} +| ALTER FOREIGN TABLE IF_P EXISTS relation_expr RENAME opt_column name TO name + { + $$ = cat_str(7,mm_strdup("alter foreign table if exists"),$6,mm_strdup("rename"),$8,$9,mm_strdup("to"),$11); +} +| ALTER TRIGGER name ON qualified_name RENAME TO name + { + $$ = cat_str(6,mm_strdup("alter trigger"),$3,mm_strdup("on"),$5,mm_strdup("rename to"),$8); +} +| ALTER ROLE RoleId RENAME TO RoleId + { + $$ = cat_str(4,mm_strdup("alter role"),$3,mm_strdup("rename to"),$6); +} +| ALTER USER RoleId RENAME TO RoleId + { + $$ = cat_str(4,mm_strdup("alter user"),$3,mm_strdup("rename to"),$6); +} +| ALTER TABLESPACE name RENAME TO name + { + $$ = cat_str(4,mm_strdup("alter tablespace"),$3,mm_strdup("rename to"),$6); +} +| ALTER TABLESPACE name SET reloptions + { + $$ = cat_str(4,mm_strdup("alter tablespace"),$3,mm_strdup("set"),$5); +} +| ALTER TABLESPACE name RESET reloptions + { + $$ = cat_str(4,mm_strdup("alter tablespace"),$3,mm_strdup("reset"),$5); +} +| ALTER TEXT_P SEARCH PARSER any_name RENAME TO name + { + $$ = cat_str(4,mm_strdup("alter text search parser"),$5,mm_strdup("rename to"),$8); +} +| ALTER TEXT_P SEARCH DICTIONARY any_name RENAME TO name + { + $$ = cat_str(4,mm_strdup("alter text search dictionary"),$5,mm_strdup("rename to"),$8); +} +| ALTER TEXT_P SEARCH TEMPLATE any_name RENAME TO name + { + $$ = cat_str(4,mm_strdup("alter text search template"),$5,mm_strdup("rename to"),$8); +} +| ALTER TEXT_P SEARCH CONFIGURATION any_name RENAME TO name + { + $$ = cat_str(4,mm_strdup("alter text search configuration"),$5,mm_strdup("rename to"),$8); +} +| ALTER TYPE_P any_name RENAME TO name + { + $$ = cat_str(4,mm_strdup("alter type"),$3,mm_strdup("rename to"),$6); +} +| ALTER TYPE_P any_name RENAME ATTRIBUTE name TO name opt_drop_behavior + { + $$ = cat_str(7,mm_strdup("alter type"),$3,mm_strdup("rename attribute"),$6,mm_strdup("to"),$8,$9); +} +; + + + opt_column: + COLUMN + { + $$ = mm_strdup("column"); +} +| + { + $$=EMPTY; } +; + + + opt_set_data: + SET DATA_P + { + $$ = mm_strdup("set data"); +} +| + { + $$=EMPTY; } +; + + + AlterObjectSchemaStmt: + ALTER AGGREGATE func_name aggr_args SET SCHEMA name + { + $$ = cat_str(5,mm_strdup("alter aggregate"),$3,$4,mm_strdup("set schema"),$7); +} +| ALTER COLLATION any_name SET SCHEMA name + { + $$ = cat_str(4,mm_strdup("alter collation"),$3,mm_strdup("set schema"),$6); +} +| ALTER CONVERSION_P any_name SET SCHEMA name + { + $$ = cat_str(4,mm_strdup("alter conversion"),$3,mm_strdup("set schema"),$6); +} +| ALTER DOMAIN_P any_name SET SCHEMA name + { + $$ = cat_str(4,mm_strdup("alter domain"),$3,mm_strdup("set schema"),$6); +} +| ALTER EXTENSION any_name SET SCHEMA name + { + $$ = cat_str(4,mm_strdup("alter extension"),$3,mm_strdup("set schema"),$6); +} +| ALTER FUNCTION function_with_argtypes SET SCHEMA name + { + $$ = cat_str(4,mm_strdup("alter function"),$3,mm_strdup("set schema"),$6); +} +| ALTER OPERATOR any_operator oper_argtypes SET SCHEMA name + { + $$ = cat_str(5,mm_strdup("alter operator"),$3,$4,mm_strdup("set schema"),$7); +} +| ALTER OPERATOR CLASS any_name USING access_method SET SCHEMA name + { + $$ = cat_str(6,mm_strdup("alter operator class"),$4,mm_strdup("using"),$6,mm_strdup("set schema"),$9); +} +| ALTER OPERATOR FAMILY any_name USING access_method SET SCHEMA name + { + $$ = cat_str(6,mm_strdup("alter operator family"),$4,mm_strdup("using"),$6,mm_strdup("set schema"),$9); +} +| ALTER TABLE relation_expr SET SCHEMA name + { + $$ = cat_str(4,mm_strdup("alter table"),$3,mm_strdup("set schema"),$6); +} +| ALTER TABLE IF_P EXISTS relation_expr SET SCHEMA name + { + $$ = cat_str(4,mm_strdup("alter table if exists"),$5,mm_strdup("set schema"),$8); +} +| ALTER TEXT_P SEARCH PARSER any_name SET SCHEMA name + { + $$ = cat_str(4,mm_strdup("alter text search parser"),$5,mm_strdup("set schema"),$8); +} +| ALTER TEXT_P SEARCH DICTIONARY any_name SET SCHEMA name + { + $$ = cat_str(4,mm_strdup("alter text search dictionary"),$5,mm_strdup("set schema"),$8); +} +| ALTER TEXT_P SEARCH TEMPLATE any_name SET SCHEMA name + { + $$ = cat_str(4,mm_strdup("alter text search template"),$5,mm_strdup("set schema"),$8); +} +| ALTER TEXT_P SEARCH CONFIGURATION any_name SET SCHEMA name + { + $$ = cat_str(4,mm_strdup("alter text search configuration"),$5,mm_strdup("set schema"),$8); +} +| ALTER SEQUENCE qualified_name SET SCHEMA name + { + $$ = cat_str(4,mm_strdup("alter sequence"),$3,mm_strdup("set schema"),$6); +} +| ALTER SEQUENCE IF_P EXISTS qualified_name SET SCHEMA name + { + $$ = cat_str(4,mm_strdup("alter sequence if exists"),$5,mm_strdup("set schema"),$8); +} +| ALTER VIEW qualified_name SET SCHEMA name + { + $$ = cat_str(4,mm_strdup("alter view"),$3,mm_strdup("set schema"),$6); +} +| ALTER VIEW IF_P EXISTS qualified_name SET SCHEMA name + { + $$ = cat_str(4,mm_strdup("alter view if exists"),$5,mm_strdup("set schema"),$8); +} +| ALTER FOREIGN TABLE relation_expr SET SCHEMA name + { + $$ = cat_str(4,mm_strdup("alter foreign table"),$4,mm_strdup("set schema"),$7); +} +| ALTER FOREIGN TABLE IF_P EXISTS relation_expr SET SCHEMA name + { + $$ = cat_str(4,mm_strdup("alter foreign table if exists"),$6,mm_strdup("set schema"),$9); +} +| ALTER TYPE_P any_name SET SCHEMA name + { + $$ = cat_str(4,mm_strdup("alter type"),$3,mm_strdup("set schema"),$6); +} +; + + + AlterOwnerStmt: + ALTER AGGREGATE func_name aggr_args OWNER TO RoleId + { + $$ = cat_str(5,mm_strdup("alter aggregate"),$3,$4,mm_strdup("owner to"),$7); +} +| ALTER COLLATION any_name OWNER TO RoleId + { + $$ = cat_str(4,mm_strdup("alter collation"),$3,mm_strdup("owner to"),$6); +} +| ALTER CONVERSION_P any_name OWNER TO RoleId + { + $$ = cat_str(4,mm_strdup("alter conversion"),$3,mm_strdup("owner to"),$6); +} +| ALTER DATABASE database_name OWNER TO RoleId + { + $$ = cat_str(4,mm_strdup("alter database"),$3,mm_strdup("owner to"),$6); +} +| ALTER DOMAIN_P any_name OWNER TO RoleId + { + $$ = cat_str(4,mm_strdup("alter domain"),$3,mm_strdup("owner to"),$6); +} +| ALTER FUNCTION function_with_argtypes OWNER TO RoleId + { + $$ = cat_str(4,mm_strdup("alter function"),$3,mm_strdup("owner to"),$6); +} +| ALTER opt_procedural LANGUAGE name OWNER TO RoleId + { + $$ = cat_str(6,mm_strdup("alter"),$2,mm_strdup("language"),$4,mm_strdup("owner to"),$7); +} +| ALTER LARGE_P OBJECT_P NumericOnly OWNER TO RoleId + { + $$ = cat_str(4,mm_strdup("alter large object"),$4,mm_strdup("owner to"),$7); +} +| ALTER OPERATOR any_operator oper_argtypes OWNER TO RoleId + { + $$ = cat_str(5,mm_strdup("alter operator"),$3,$4,mm_strdup("owner to"),$7); +} +| ALTER OPERATOR CLASS any_name USING access_method OWNER TO RoleId + { + $$ = cat_str(6,mm_strdup("alter operator class"),$4,mm_strdup("using"),$6,mm_strdup("owner to"),$9); +} +| ALTER OPERATOR FAMILY any_name USING access_method OWNER TO RoleId + { + $$ = cat_str(6,mm_strdup("alter operator family"),$4,mm_strdup("using"),$6,mm_strdup("owner to"),$9); +} +| ALTER SCHEMA name OWNER TO RoleId + { + $$ = cat_str(4,mm_strdup("alter schema"),$3,mm_strdup("owner to"),$6); +} +| ALTER TYPE_P any_name OWNER TO RoleId + { + $$ = cat_str(4,mm_strdup("alter type"),$3,mm_strdup("owner to"),$6); +} +| ALTER TABLESPACE name OWNER TO RoleId + { + $$ = cat_str(4,mm_strdup("alter tablespace"),$3,mm_strdup("owner to"),$6); +} +| ALTER TEXT_P SEARCH DICTIONARY any_name OWNER TO RoleId + { + $$ = cat_str(4,mm_strdup("alter text search dictionary"),$5,mm_strdup("owner to"),$8); +} +| ALTER TEXT_P SEARCH CONFIGURATION any_name OWNER TO RoleId + { + $$ = cat_str(4,mm_strdup("alter text search configuration"),$5,mm_strdup("owner to"),$8); +} +| ALTER FOREIGN DATA_P WRAPPER name OWNER TO RoleId + { + $$ = cat_str(4,mm_strdup("alter foreign data wrapper"),$5,mm_strdup("owner to"),$8); +} +| ALTER SERVER name OWNER TO RoleId + { + $$ = cat_str(4,mm_strdup("alter server"),$3,mm_strdup("owner to"),$6); +} +; + + + RuleStmt: + CREATE opt_or_replace RULE name AS ON event TO qualified_name where_clause DO opt_instead RuleActionList + { + $$ = cat_str(12,mm_strdup("create"),$2,mm_strdup("rule"),$4,mm_strdup("as on"),$7,mm_strdup("to"),$9,$10,mm_strdup("do"),$12,$13); +} +; + + + RuleActionList: + NOTHING + { + $$ = mm_strdup("nothing"); +} +| RuleActionStmt + { + $$ = $1; +} +| '(' RuleActionMulti ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(")")); +} +; + + + RuleActionMulti: + RuleActionMulti ';' RuleActionStmtOrEmpty + { + $$ = cat_str(3,$1,mm_strdup(";"),$3); +} +| RuleActionStmtOrEmpty + { + $$ = $1; +} +; + + + RuleActionStmt: + SelectStmt + { + $$ = $1; +} +| InsertStmt + { + $$ = $1; +} +| UpdateStmt + { + $$ = $1; +} +| DeleteStmt + { + $$ = $1; +} +| NotifyStmt + { + $$ = $1; +} +; + + + RuleActionStmtOrEmpty: + RuleActionStmt + { + $$ = $1; +} +| + { + $$=EMPTY; } +; + + + event: + SELECT + { + $$ = mm_strdup("select"); +} +| UPDATE + { + $$ = mm_strdup("update"); +} +| DELETE_P + { + $$ = mm_strdup("delete"); +} +| INSERT + { + $$ = mm_strdup("insert"); +} +; + + + opt_instead: + INSTEAD + { + $$ = mm_strdup("instead"); +} +| ALSO + { + $$ = mm_strdup("also"); +} +| + { + $$=EMPTY; } +; + + + DropRuleStmt: + DROP RULE name ON any_name opt_drop_behavior + { + $$ = cat_str(5,mm_strdup("drop rule"),$3,mm_strdup("on"),$5,$6); +} +| DROP RULE IF_P EXISTS name ON any_name opt_drop_behavior + { + $$ = cat_str(5,mm_strdup("drop rule if exists"),$5,mm_strdup("on"),$7,$8); +} +; + + + NotifyStmt: + NOTIFY ColId notify_payload + { + $$ = cat_str(3,mm_strdup("notify"),$2,$3); +} +; + + + notify_payload: + ',' ecpg_sconst + { + $$ = cat_str(2,mm_strdup(","),$2); +} +| + { + $$=EMPTY; } +; + + + ListenStmt: + LISTEN ColId + { + $$ = cat_str(2,mm_strdup("listen"),$2); +} +; + + + UnlistenStmt: + UNLISTEN ColId + { + $$ = cat_str(2,mm_strdup("unlisten"),$2); +} +| UNLISTEN '*' + { + $$ = mm_strdup("unlisten *"); +} +; + + + TransactionStmt: + ABORT_P opt_transaction + { + $$ = cat_str(2,mm_strdup("abort"),$2); +} +| BEGIN_P opt_transaction transaction_mode_list_or_empty + { + $$ = cat_str(3,mm_strdup("begin"),$2,$3); +} +| START TRANSACTION transaction_mode_list_or_empty + { + $$ = cat_str(2,mm_strdup("start transaction"),$3); +} +| COMMIT opt_transaction + { + $$ = cat_str(2,mm_strdup("commit"),$2); +} +| END_P opt_transaction + { + $$ = cat_str(2,mm_strdup("end"),$2); +} +| ROLLBACK opt_transaction + { + $$ = cat_str(2,mm_strdup("rollback"),$2); +} +| SAVEPOINT ColId + { + $$ = cat_str(2,mm_strdup("savepoint"),$2); +} +| RELEASE SAVEPOINT ColId + { + $$ = cat_str(2,mm_strdup("release savepoint"),$3); +} +| RELEASE ColId + { + $$ = cat_str(2,mm_strdup("release"),$2); +} +| ROLLBACK opt_transaction TO SAVEPOINT ColId + { + $$ = cat_str(4,mm_strdup("rollback"),$2,mm_strdup("to savepoint"),$5); +} +| ROLLBACK opt_transaction TO ColId + { + $$ = cat_str(4,mm_strdup("rollback"),$2,mm_strdup("to"),$4); +} +| PREPARE TRANSACTION ecpg_sconst + { + $$ = cat_str(2,mm_strdup("prepare transaction"),$3); +} +| COMMIT PREPARED ecpg_sconst + { + $$ = cat_str(2,mm_strdup("commit prepared"),$3); +} +| ROLLBACK PREPARED ecpg_sconst + { + $$ = cat_str(2,mm_strdup("rollback prepared"),$3); +} +; + + + opt_transaction: + WORK + { + $$ = mm_strdup("work"); +} +| TRANSACTION + { + $$ = mm_strdup("transaction"); +} +| + { + $$=EMPTY; } +; + + + transaction_mode_item: + ISOLATION LEVEL iso_level + { + $$ = cat_str(2,mm_strdup("isolation level"),$3); +} +| READ ONLY + { + $$ = mm_strdup("read only"); +} +| READ WRITE + { + $$ = mm_strdup("read write"); +} +| DEFERRABLE + { + $$ = mm_strdup("deferrable"); +} +| NOT DEFERRABLE + { + $$ = mm_strdup("not deferrable"); +} +; + + + transaction_mode_list: + transaction_mode_item + { + $$ = $1; +} +| transaction_mode_list ',' transaction_mode_item + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +| transaction_mode_list transaction_mode_item + { + $$ = cat_str(2,$1,$2); +} +; + + + transaction_mode_list_or_empty: + transaction_mode_list + { + $$ = $1; +} +| + { + $$=EMPTY; } +; + + + ViewStmt: + CREATE OptTemp VIEW qualified_name opt_column_list opt_reloptions AS SelectStmt opt_check_option + { + $$ = cat_str(9,mm_strdup("create"),$2,mm_strdup("view"),$4,$5,$6,mm_strdup("as"),$8,$9); +} +| CREATE OR REPLACE OptTemp VIEW qualified_name opt_column_list opt_reloptions AS SelectStmt opt_check_option + { + $$ = cat_str(9,mm_strdup("create or replace"),$4,mm_strdup("view"),$6,$7,$8,mm_strdup("as"),$10,$11); +} +; + + + opt_check_option: + WITH CHECK OPTION + { +mmerror(PARSE_ERROR, ET_WARNING, "unsupported feature will be passed to server"); + $$ = mm_strdup("with check option"); +} +| WITH CASCADED CHECK OPTION + { +mmerror(PARSE_ERROR, ET_WARNING, "unsupported feature will be passed to server"); + $$ = mm_strdup("with cascaded check option"); +} +| WITH LOCAL CHECK OPTION + { +mmerror(PARSE_ERROR, ET_WARNING, "unsupported feature will be passed to server"); + $$ = mm_strdup("with local check option"); +} +| + { + $$=EMPTY; } +; + + + LoadStmt: + LOAD file_name + { + $$ = cat_str(2,mm_strdup("load"),$2); +} +; + + + CreatedbStmt: + CREATE DATABASE database_name opt_with createdb_opt_list + { + $$ = cat_str(4,mm_strdup("create database"),$3,$4,$5); +} +; + + + createdb_opt_list: + createdb_opt_list createdb_opt_item + { + $$ = cat_str(2,$1,$2); +} +| + { + $$=EMPTY; } +; + + + createdb_opt_item: + TABLESPACE opt_equal name + { + $$ = cat_str(3,mm_strdup("tablespace"),$2,$3); +} +| TABLESPACE opt_equal DEFAULT + { + $$ = cat_str(3,mm_strdup("tablespace"),$2,mm_strdup("default")); +} +| LOCATION opt_equal ecpg_sconst + { + $$ = cat_str(3,mm_strdup("location"),$2,$3); +} +| LOCATION opt_equal DEFAULT + { + $$ = cat_str(3,mm_strdup("location"),$2,mm_strdup("default")); +} +| TEMPLATE opt_equal name + { + $$ = cat_str(3,mm_strdup("template"),$2,$3); +} +| TEMPLATE opt_equal DEFAULT + { + $$ = cat_str(3,mm_strdup("template"),$2,mm_strdup("default")); +} +| ENCODING opt_equal ecpg_sconst + { + $$ = cat_str(3,mm_strdup("encoding"),$2,$3); +} +| ENCODING opt_equal Iconst + { + $$ = cat_str(3,mm_strdup("encoding"),$2,$3); +} +| ENCODING opt_equal DEFAULT + { + $$ = cat_str(3,mm_strdup("encoding"),$2,mm_strdup("default")); +} +| LC_COLLATE_P opt_equal ecpg_sconst + { + $$ = cat_str(3,mm_strdup("lc_collate"),$2,$3); +} +| LC_COLLATE_P opt_equal DEFAULT + { + $$ = cat_str(3,mm_strdup("lc_collate"),$2,mm_strdup("default")); +} +| LC_CTYPE_P opt_equal ecpg_sconst + { + $$ = cat_str(3,mm_strdup("lc_ctype"),$2,$3); +} +| LC_CTYPE_P opt_equal DEFAULT + { + $$ = cat_str(3,mm_strdup("lc_ctype"),$2,mm_strdup("default")); +} +| CONNECTION LIMIT opt_equal SignedIconst + { + $$ = cat_str(3,mm_strdup("connection limit"),$3,$4); +} +| OWNER opt_equal name + { + $$ = cat_str(3,mm_strdup("owner"),$2,$3); +} +| OWNER opt_equal DEFAULT + { + $$ = cat_str(3,mm_strdup("owner"),$2,mm_strdup("default")); +} +; + + + opt_equal: + '=' + { + $$ = mm_strdup("="); +} +| + { + $$=EMPTY; } +; + + + AlterDatabaseStmt: + ALTER DATABASE database_name opt_with alterdb_opt_list + { + $$ = cat_str(4,mm_strdup("alter database"),$3,$4,$5); +} +| ALTER DATABASE database_name SET TABLESPACE name + { + $$ = cat_str(4,mm_strdup("alter database"),$3,mm_strdup("set tablespace"),$6); +} +; + + + AlterDatabaseSetStmt: + ALTER DATABASE database_name SetResetClause + { + $$ = cat_str(3,mm_strdup("alter database"),$3,$4); +} +; + + + alterdb_opt_list: + alterdb_opt_list alterdb_opt_item + { + $$ = cat_str(2,$1,$2); +} +| + { + $$=EMPTY; } +; + + + alterdb_opt_item: + CONNECTION LIMIT opt_equal SignedIconst + { + $$ = cat_str(3,mm_strdup("connection limit"),$3,$4); +} +; + + + DropdbStmt: + DROP DATABASE database_name + { + $$ = cat_str(2,mm_strdup("drop database"),$3); +} +| DROP DATABASE IF_P EXISTS database_name + { + $$ = cat_str(2,mm_strdup("drop database if exists"),$5); +} +; + + + CreateDomainStmt: + CREATE DOMAIN_P any_name opt_as Typename ColQualList + { + $$ = cat_str(5,mm_strdup("create domain"),$3,$4,$5,$6); +} +; + + + AlterDomainStmt: + ALTER DOMAIN_P any_name alter_column_default + { + $$ = cat_str(3,mm_strdup("alter domain"),$3,$4); +} +| ALTER DOMAIN_P any_name DROP NOT NULL_P + { + $$ = cat_str(3,mm_strdup("alter domain"),$3,mm_strdup("drop not null")); +} +| ALTER DOMAIN_P any_name SET NOT NULL_P + { + $$ = cat_str(3,mm_strdup("alter domain"),$3,mm_strdup("set not null")); +} +| ALTER DOMAIN_P any_name ADD_P TableConstraint + { + $$ = cat_str(4,mm_strdup("alter domain"),$3,mm_strdup("add"),$5); +} +| ALTER DOMAIN_P any_name DROP CONSTRAINT name opt_drop_behavior + { + $$ = cat_str(5,mm_strdup("alter domain"),$3,mm_strdup("drop constraint"),$6,$7); +} +| ALTER DOMAIN_P any_name DROP CONSTRAINT IF_P EXISTS name opt_drop_behavior + { + $$ = cat_str(5,mm_strdup("alter domain"),$3,mm_strdup("drop constraint if exists"),$8,$9); +} +| ALTER DOMAIN_P any_name VALIDATE CONSTRAINT name + { + $$ = cat_str(4,mm_strdup("alter domain"),$3,mm_strdup("validate constraint"),$6); +} +; + + + opt_as: + AS + { + $$ = mm_strdup("as"); +} +| + { + $$=EMPTY; } +; + + + AlterTSDictionaryStmt: + ALTER TEXT_P SEARCH DICTIONARY any_name definition + { + $$ = cat_str(3,mm_strdup("alter text search dictionary"),$5,$6); +} +; + + + AlterTSConfigurationStmt: + ALTER TEXT_P SEARCH CONFIGURATION any_name ADD_P MAPPING FOR name_list WITH any_name_list + { + $$ = cat_str(6,mm_strdup("alter text search configuration"),$5,mm_strdup("add mapping for"),$9,mm_strdup("with"),$11); +} +| ALTER TEXT_P SEARCH CONFIGURATION any_name ALTER MAPPING FOR name_list WITH any_name_list + { + $$ = cat_str(6,mm_strdup("alter text search configuration"),$5,mm_strdup("alter mapping for"),$9,mm_strdup("with"),$11); +} +| ALTER TEXT_P SEARCH CONFIGURATION any_name ALTER MAPPING REPLACE any_name WITH any_name + { + $$ = cat_str(6,mm_strdup("alter text search configuration"),$5,mm_strdup("alter mapping replace"),$9,mm_strdup("with"),$11); +} +| ALTER TEXT_P SEARCH CONFIGURATION any_name ALTER MAPPING FOR name_list REPLACE any_name WITH any_name + { + $$ = cat_str(8,mm_strdup("alter text search configuration"),$5,mm_strdup("alter mapping for"),$9,mm_strdup("replace"),$11,mm_strdup("with"),$13); +} +| ALTER TEXT_P SEARCH CONFIGURATION any_name DROP MAPPING FOR name_list + { + $$ = cat_str(4,mm_strdup("alter text search configuration"),$5,mm_strdup("drop mapping for"),$9); +} +| ALTER TEXT_P SEARCH CONFIGURATION any_name DROP MAPPING IF_P EXISTS FOR name_list + { + $$ = cat_str(4,mm_strdup("alter text search configuration"),$5,mm_strdup("drop mapping if exists for"),$11); +} +; + + + CreateConversionStmt: + CREATE opt_default CONVERSION_P any_name FOR ecpg_sconst TO ecpg_sconst FROM any_name + { + $$ = cat_str(10,mm_strdup("create"),$2,mm_strdup("conversion"),$4,mm_strdup("for"),$6,mm_strdup("to"),$8,mm_strdup("from"),$10); +} +; + + + ClusterStmt: + CLUSTER opt_verbose qualified_name cluster_index_specification + { + $$ = cat_str(4,mm_strdup("cluster"),$2,$3,$4); +} +| CLUSTER opt_verbose + { + $$ = cat_str(2,mm_strdup("cluster"),$2); +} +| CLUSTER opt_verbose index_name ON qualified_name + { + $$ = cat_str(5,mm_strdup("cluster"),$2,$3,mm_strdup("on"),$5); +} +; + + + cluster_index_specification: + USING index_name + { + $$ = cat_str(2,mm_strdup("using"),$2); +} +| + { + $$=EMPTY; } +; + + + VacuumStmt: + VACUUM opt_full opt_freeze opt_verbose + { + $$ = cat_str(4,mm_strdup("vacuum"),$2,$3,$4); +} +| VACUUM opt_full opt_freeze opt_verbose qualified_name + { + $$ = cat_str(5,mm_strdup("vacuum"),$2,$3,$4,$5); +} +| VACUUM opt_full opt_freeze opt_verbose AnalyzeStmt + { + $$ = cat_str(5,mm_strdup("vacuum"),$2,$3,$4,$5); +} +| VACUUM '(' vacuum_option_list ')' + { + $$ = cat_str(3,mm_strdup("vacuum ("),$3,mm_strdup(")")); +} +| VACUUM '(' vacuum_option_list ')' qualified_name opt_name_list + { + $$ = cat_str(5,mm_strdup("vacuum ("),$3,mm_strdup(")"),$5,$6); +} +; + + + vacuum_option_list: + vacuum_option_elem + { + $$ = $1; +} +| vacuum_option_list ',' vacuum_option_elem + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + vacuum_option_elem: + analyze_keyword + { + $$ = $1; +} +| VERBOSE + { + $$ = mm_strdup("verbose"); +} +| FREEZE + { + $$ = mm_strdup("freeze"); +} +| FULL + { + $$ = mm_strdup("full"); +} +; + + + AnalyzeStmt: + analyze_keyword opt_verbose + { + $$ = cat_str(2,$1,$2); +} +| analyze_keyword opt_verbose qualified_name opt_name_list + { + $$ = cat_str(4,$1,$2,$3,$4); +} +; + + + analyze_keyword: + ANALYZE + { + $$ = mm_strdup("analyze"); +} +| ANALYSE + { + $$ = mm_strdup("analyse"); +} +; + + + opt_verbose: + VERBOSE + { + $$ = mm_strdup("verbose"); +} +| + { + $$=EMPTY; } +; + + + opt_full: + FULL + { + $$ = mm_strdup("full"); +} +| + { + $$=EMPTY; } +; + + + opt_freeze: + FREEZE + { + $$ = mm_strdup("freeze"); +} +| + { + $$=EMPTY; } +; + + + opt_name_list: + '(' name_list ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(")")); +} +| + { + $$=EMPTY; } +; + + + ExplainStmt: + EXPLAIN ExplainableStmt + { + $$ = cat_str(2,mm_strdup("explain"),$2); +} +| EXPLAIN analyze_keyword opt_verbose ExplainableStmt + { + $$ = cat_str(4,mm_strdup("explain"),$2,$3,$4); +} +| EXPLAIN VERBOSE ExplainableStmt + { + $$ = cat_str(2,mm_strdup("explain verbose"),$3); +} +| EXPLAIN '(' explain_option_list ')' ExplainableStmt + { + $$ = cat_str(4,mm_strdup("explain ("),$3,mm_strdup(")"),$5); +} +; + + + ExplainableStmt: + SelectStmt + { + $$ = $1; +} +| InsertStmt + { + $$ = $1; +} +| UpdateStmt + { + $$ = $1; +} +| DeleteStmt + { + $$ = $1; +} +| DeclareCursorStmt + { + $$ = $1; +} +| CreateAsStmt + { + $$ = $1; +} +| ExecuteStmt + { + $$ = $1; +} +; + + + explain_option_list: + explain_option_elem + { + $$ = $1; +} +| explain_option_list ',' explain_option_elem + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + explain_option_elem: + explain_option_name explain_option_arg + { + $$ = cat_str(2,$1,$2); +} +; + + + explain_option_name: + ColId + { + $$ = $1; +} +| analyze_keyword + { + $$ = $1; +} +| VERBOSE + { + $$ = mm_strdup("verbose"); +} +; + + + explain_option_arg: + opt_boolean_or_string + { + $$ = $1; +} +| NumericOnly + { + $$ = $1; +} +| + { + $$=EMPTY; } +; + + + PrepareStmt: +PREPARE prepared_name prep_type_clause AS PreparableStmt + { + $$.name = $2; + $$.type = $3; + $$.stmt = cat_str(3, mm_strdup("\""), $5, mm_strdup("\"")); + } + | PREPARE prepared_name FROM execstring + { + $$.name = $2; + $$.type = NULL; + $$.stmt = $4; + } +; + + + prep_type_clause: + '(' type_list ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(")")); +} +| + { + $$=EMPTY; } +; + + + PreparableStmt: + SelectStmt + { + $$ = $1; +} +| InsertStmt + { + $$ = $1; +} +| UpdateStmt + { + $$ = $1; +} +| DeleteStmt + { + $$ = $1; +} +; + + + ExecuteStmt: +EXECUTE prepared_name execute_param_clause execute_rest + { $$ = $2; } +| CREATE OptTemp TABLE create_as_target AS EXECUTE name execute_param_clause opt_with_data + { + $$ = cat_str(8,mm_strdup("create"),$2,mm_strdup("table"),$4,mm_strdup("as execute"),$7,$8,$9); +} +; + + + execute_param_clause: + '(' expr_list ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(")")); +} +| + { + $$=EMPTY; } +; + + + InsertStmt: + opt_with_clause INSERT INTO qualified_name insert_rest returning_clause + { + $$ = cat_str(5,$1,mm_strdup("insert into"),$4,$5,$6); +} +; + + + insert_rest: + SelectStmt + { + $$ = $1; +} +| '(' insert_column_list ')' SelectStmt + { + $$ = cat_str(4,mm_strdup("("),$2,mm_strdup(")"),$4); +} +| DEFAULT VALUES + { + $$ = mm_strdup("default values"); +} +; + + + insert_column_list: + insert_column_item + { + $$ = $1; +} +| insert_column_list ',' insert_column_item + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + insert_column_item: + ColId opt_indirection + { + $$ = cat_str(2,$1,$2); +} +; + + + returning_clause: +RETURNING target_list ecpg_into + { + $$ = cat_str(2,mm_strdup("returning"),$2); +} +| + { + $$=EMPTY; } +; + + + DeleteStmt: + opt_with_clause DELETE_P FROM relation_expr_opt_alias using_clause where_or_current_clause returning_clause + { + $$ = cat_str(6,$1,mm_strdup("delete from"),$4,$5,$6,$7); +} +; + + + using_clause: + USING from_list + { + $$ = cat_str(2,mm_strdup("using"),$2); +} +| + { + $$=EMPTY; } +; + + + LockStmt: + LOCK_P opt_table relation_expr_list opt_lock opt_nowait + { + $$ = cat_str(5,mm_strdup("lock"),$2,$3,$4,$5); +} +; + + + opt_lock: + IN_P lock_type MODE + { + $$ = cat_str(3,mm_strdup("in"),$2,mm_strdup("mode")); +} +| + { + $$=EMPTY; } +; + + + lock_type: + ACCESS SHARE + { + $$ = mm_strdup("access share"); +} +| ROW SHARE + { + $$ = mm_strdup("row share"); +} +| ROW EXCLUSIVE + { + $$ = mm_strdup("row exclusive"); +} +| SHARE UPDATE EXCLUSIVE + { + $$ = mm_strdup("share update exclusive"); +} +| SHARE + { + $$ = mm_strdup("share"); +} +| SHARE ROW EXCLUSIVE + { + $$ = mm_strdup("share row exclusive"); +} +| EXCLUSIVE + { + $$ = mm_strdup("exclusive"); +} +| ACCESS EXCLUSIVE + { + $$ = mm_strdup("access exclusive"); +} +; + + + opt_nowait: + NOWAIT + { + $$ = mm_strdup("nowait"); +} +| + { + $$=EMPTY; } +; + + + UpdateStmt: + opt_with_clause UPDATE relation_expr_opt_alias SET set_clause_list from_clause where_or_current_clause returning_clause + { + $$ = cat_str(8,$1,mm_strdup("update"),$3,mm_strdup("set"),$5,$6,$7,$8); +} +; + + + set_clause_list: + set_clause + { + $$ = $1; +} +| set_clause_list ',' set_clause + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + set_clause: + single_set_clause + { + $$ = $1; +} +| multiple_set_clause + { + $$ = $1; +} +; + + + single_set_clause: + set_target '=' ctext_expr + { + $$ = cat_str(3,$1,mm_strdup("="),$3); +} +; + + + multiple_set_clause: + '(' set_target_list ')' '=' ctext_row + { + $$ = cat_str(4,mm_strdup("("),$2,mm_strdup(") ="),$5); +} +; + + + set_target: + ColId opt_indirection + { + $$ = cat_str(2,$1,$2); +} +; + + + set_target_list: + set_target + { + $$ = $1; +} +| set_target_list ',' set_target + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + DeclareCursorStmt: + DECLARE cursor_name cursor_options CURSOR opt_hold FOR SelectStmt + { + struct cursor *ptr, *this; + char *cursor_marker = $2[0] == ':' ? mm_strdup("$0") : mm_strdup($2); + char *comment, *c1, *c2; + int (* strcmp_fn)(const char *, const char *) = ($2[0] == ':' ? strcmp : pg_strcasecmp); + + for (ptr = cur; ptr != NULL; ptr = ptr->next) + { + if (strcmp_fn($2, ptr->name) == 0) + { + if ($2[0] == ':') + mmerror(PARSE_ERROR, ET_ERROR, "using variable \"%s\" in different declare statements is not supported", $2+1); + else + mmerror(PARSE_ERROR, ET_ERROR, "cursor \"%s\" is already defined", $2); + } + } + + this = (struct cursor *) mm_alloc(sizeof(struct cursor)); + + this->next = cur; + this->name = $2; + this->function = (current_function ? mm_strdup(current_function) : NULL); + this->connection = connection; + this->opened = false; + this->command = cat_str(7, mm_strdup("declare"), cursor_marker, $3, mm_strdup("cursor"), $5, mm_strdup("for"), $7); + this->argsinsert = argsinsert; + this->argsinsert_oos = NULL; + this->argsresult = argsresult; + this->argsresult_oos = NULL; + argsinsert = argsresult = NULL; + cur = this; + + c1 = mm_strdup(this->command); + if ((c2 = strstr(c1, "*/")) != NULL) + { + /* We put this text into a comment, so we better remove [*][/]. */ + c2[0] = '.'; + c2[1] = '.'; + } + comment = cat_str(3, mm_strdup("/*"), c1, mm_strdup("*/")); + + if ((braces_open > 0) && INFORMIX_MODE) /* we're in a function */ + $$ = cat_str(3, adjust_outofscope_cursor_vars(this), + mm_strdup("ECPG_informix_reset_sqlca();"), + comment); + else + $$ = cat2_str(adjust_outofscope_cursor_vars(this), comment); + } +; + + + cursor_name: + name + { + $$ = $1; +} + | char_civar + { + char *curname = mm_alloc(strlen($1) + 2); + sprintf(curname, ":%s", $1); + free($1); + $1 = curname; + $$ = $1; + } +; + + + cursor_options: + + { + $$=EMPTY; } +| cursor_options NO SCROLL + { + $$ = cat_str(2,$1,mm_strdup("no scroll")); +} +| cursor_options SCROLL + { + $$ = cat_str(2,$1,mm_strdup("scroll")); +} +| cursor_options BINARY + { + $$ = cat_str(2,$1,mm_strdup("binary")); +} +| cursor_options INSENSITIVE + { + $$ = cat_str(2,$1,mm_strdup("insensitive")); +} +; + + + opt_hold: + + { + if (compat == ECPG_COMPAT_INFORMIX_SE && autocommit) + $$ = mm_strdup("with hold"); + else + $$ = EMPTY; + } +| WITH HOLD + { + $$ = mm_strdup("with hold"); +} +| WITHOUT HOLD + { + $$ = mm_strdup("without hold"); +} +; + + + SelectStmt: + select_no_parens %prec UMINUS + { + $$ = $1; +} +| select_with_parens %prec UMINUS + { + $$ = $1; +} +; + + + select_with_parens: + '(' select_no_parens ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(")")); +} +| '(' select_with_parens ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(")")); +} +; + + + select_no_parens: + simple_select + { + $$ = $1; +} +| select_clause sort_clause + { + $$ = cat_str(2,$1,$2); +} +| select_clause opt_sort_clause for_locking_clause opt_select_limit + { + $$ = cat_str(4,$1,$2,$3,$4); +} +| select_clause opt_sort_clause select_limit opt_for_locking_clause + { + $$ = cat_str(4,$1,$2,$3,$4); +} +| with_clause select_clause + { + $$ = cat_str(2,$1,$2); +} +| with_clause select_clause sort_clause + { + $$ = cat_str(3,$1,$2,$3); +} +| with_clause select_clause opt_sort_clause for_locking_clause opt_select_limit + { + $$ = cat_str(5,$1,$2,$3,$4,$5); +} +| with_clause select_clause opt_sort_clause select_limit opt_for_locking_clause + { + $$ = cat_str(5,$1,$2,$3,$4,$5); +} +; + + + select_clause: + simple_select + { + $$ = $1; +} +| select_with_parens + { + $$ = $1; +} +; + + + simple_select: + SELECT opt_distinct target_list into_clause from_clause where_clause group_clause having_clause window_clause + { + $$ = cat_str(9,mm_strdup("select"),$2,$3,$4,$5,$6,$7,$8,$9); +} +| values_clause + { + $$ = $1; +} +| TABLE relation_expr + { + $$ = cat_str(2,mm_strdup("table"),$2); +} +| select_clause UNION opt_all select_clause + { + $$ = cat_str(4,$1,mm_strdup("union"),$3,$4); +} +| select_clause INTERSECT opt_all select_clause + { + $$ = cat_str(4,$1,mm_strdup("intersect"),$3,$4); +} +| select_clause EXCEPT opt_all select_clause + { + $$ = cat_str(4,$1,mm_strdup("except"),$3,$4); +} +; + + + with_clause: + WITH cte_list + { + $$ = cat_str(2,mm_strdup("with"),$2); +} +| WITH RECURSIVE cte_list + { + $$ = cat_str(2,mm_strdup("with recursive"),$3); +} +; + + + cte_list: + common_table_expr + { + $$ = $1; +} +| cte_list ',' common_table_expr + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + common_table_expr: + name opt_name_list AS '(' PreparableStmt ')' + { + $$ = cat_str(5,$1,$2,mm_strdup("as ("),$5,mm_strdup(")")); +} +; + + + opt_with_clause: + with_clause + { + $$ = $1; +} +| + { + $$=EMPTY; } +; + + + into_clause: + INTO OptTempTableName + { + FoundInto = 1; + $$= cat2_str(mm_strdup("into"), $2); + } + | ecpg_into { $$ = EMPTY; } +| + { + $$=EMPTY; } +; + + + OptTempTableName: + TEMPORARY opt_table qualified_name + { + $$ = cat_str(3,mm_strdup("temporary"),$2,$3); +} +| TEMP opt_table qualified_name + { + $$ = cat_str(3,mm_strdup("temp"),$2,$3); +} +| LOCAL TEMPORARY opt_table qualified_name + { + $$ = cat_str(3,mm_strdup("local temporary"),$3,$4); +} +| LOCAL TEMP opt_table qualified_name + { + $$ = cat_str(3,mm_strdup("local temp"),$3,$4); +} +| GLOBAL TEMPORARY opt_table qualified_name + { + $$ = cat_str(3,mm_strdup("global temporary"),$3,$4); +} +| GLOBAL TEMP opt_table qualified_name + { + $$ = cat_str(3,mm_strdup("global temp"),$3,$4); +} +| UNLOGGED opt_table qualified_name + { + $$ = cat_str(3,mm_strdup("unlogged"),$2,$3); +} +| TABLE qualified_name + { + $$ = cat_str(2,mm_strdup("table"),$2); +} +| qualified_name + { + $$ = $1; +} +; + + + opt_table: + TABLE + { + $$ = mm_strdup("table"); +} +| + { + $$=EMPTY; } +; + + + opt_all: + ALL + { + $$ = mm_strdup("all"); +} +| DISTINCT + { + $$ = mm_strdup("distinct"); +} +| + { + $$=EMPTY; } +; + + + opt_distinct: + DISTINCT + { + $$ = mm_strdup("distinct"); +} +| DISTINCT ON '(' expr_list ')' + { + $$ = cat_str(3,mm_strdup("distinct on ("),$4,mm_strdup(")")); +} +| ALL + { + $$ = mm_strdup("all"); +} +| + { + $$=EMPTY; } +; + + + opt_sort_clause: + sort_clause + { + $$ = $1; +} +| + { + $$=EMPTY; } +; + + + sort_clause: + ORDER BY sortby_list + { + $$ = cat_str(2,mm_strdup("order by"),$3); +} +; + + + sortby_list: + sortby + { + $$ = $1; +} +| sortby_list ',' sortby + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + sortby: + a_expr USING qual_all_Op opt_nulls_order + { + $$ = cat_str(4,$1,mm_strdup("using"),$3,$4); +} +| a_expr opt_asc_desc opt_nulls_order + { + $$ = cat_str(3,$1,$2,$3); +} +; + + + select_limit: + limit_clause offset_clause + { + $$ = cat_str(2,$1,$2); +} +| offset_clause limit_clause + { + $$ = cat_str(2,$1,$2); +} +| limit_clause + { + $$ = $1; +} +| offset_clause + { + $$ = $1; +} +; + + + opt_select_limit: + select_limit + { + $$ = $1; +} +| + { + $$=EMPTY; } +; + + + limit_clause: + LIMIT select_limit_value + { + $$ = cat_str(2,mm_strdup("limit"),$2); +} +| LIMIT select_limit_value ',' select_offset_value + { + mmerror(PARSE_ERROR, ET_WARNING, "no longer supported LIMIT #,# syntax passed to server"); + $$ = cat_str(4, mm_strdup("limit"), $2, mm_strdup(","), $4); + } +| FETCH first_or_next opt_select_fetch_first_value row_or_rows ONLY + { + $$ = cat_str(5,mm_strdup("fetch"),$2,$3,$4,mm_strdup("only")); +} +; + + + offset_clause: + OFFSET select_offset_value + { + $$ = cat_str(2,mm_strdup("offset"),$2); +} +| OFFSET select_offset_value2 row_or_rows + { + $$ = cat_str(3,mm_strdup("offset"),$2,$3); +} +; + + + select_limit_value: + a_expr + { + $$ = $1; +} +| ALL + { + $$ = mm_strdup("all"); +} +; + + + select_offset_value: + a_expr + { + $$ = $1; +} +; + + + opt_select_fetch_first_value: + SignedIconst + { + $$ = $1; +} +| '(' a_expr ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(")")); +} +| + { + $$=EMPTY; } +; + + + select_offset_value2: + c_expr + { + $$ = $1; +} +; + + + row_or_rows: + ROW + { + $$ = mm_strdup("row"); +} +| ROWS + { + $$ = mm_strdup("rows"); +} +; + + + first_or_next: + FIRST_P + { + $$ = mm_strdup("first"); +} +| NEXT + { + $$ = mm_strdup("next"); +} +; + + + group_clause: + GROUP_P BY expr_list + { + $$ = cat_str(2,mm_strdup("group by"),$3); +} +| + { + $$=EMPTY; } +; + + + having_clause: + HAVING a_expr + { + $$ = cat_str(2,mm_strdup("having"),$2); +} +| + { + $$=EMPTY; } +; + + + for_locking_clause: + for_locking_items + { + $$ = $1; +} +| FOR READ ONLY + { + $$ = mm_strdup("for read only"); +} +; + + + opt_for_locking_clause: + for_locking_clause + { + $$ = $1; +} +| + { + $$=EMPTY; } +; + + + for_locking_items: + for_locking_item + { + $$ = $1; +} +| for_locking_items for_locking_item + { + $$ = cat_str(2,$1,$2); +} +; + + + for_locking_item: + FOR UPDATE locked_rels_list opt_nowait + { + $$ = cat_str(3,mm_strdup("for update"),$3,$4); +} +| FOR SHARE locked_rels_list opt_nowait + { + $$ = cat_str(3,mm_strdup("for share"),$3,$4); +} +; + + + locked_rels_list: + OF qualified_name_list + { + $$ = cat_str(2,mm_strdup("of"),$2); +} +| + { + $$=EMPTY; } +; + + + values_clause: + VALUES ctext_row + { + $$ = cat_str(2,mm_strdup("values"),$2); +} +| values_clause ',' ctext_row + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + from_clause: + FROM from_list + { + $$ = cat_str(2,mm_strdup("from"),$2); +} +| + { + $$=EMPTY; } +; + + + from_list: + table_ref + { + $$ = $1; +} +| from_list ',' table_ref + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + table_ref: + relation_expr + { + $$ = $1; +} +| relation_expr alias_clause + { + $$ = cat_str(2,$1,$2); +} +| func_table + { + $$ = $1; +} +| func_table alias_clause + { + $$ = cat_str(2,$1,$2); +} +| func_table AS '(' TableFuncElementList ')' + { + $$ = cat_str(4,$1,mm_strdup("as ("),$4,mm_strdup(")")); +} +| func_table AS ColId '(' TableFuncElementList ')' + { + $$ = cat_str(6,$1,mm_strdup("as"),$3,mm_strdup("("),$5,mm_strdup(")")); +} +| func_table ColId '(' TableFuncElementList ')' + { + $$ = cat_str(5,$1,$2,mm_strdup("("),$4,mm_strdup(")")); +} +| select_with_parens + { + mmerror(PARSE_ERROR, ET_ERROR, "subquery in FROM must have an alias"); + + $$ = $1; +} +| select_with_parens alias_clause + { + $$ = cat_str(2,$1,$2); +} +| joined_table + { + $$ = $1; +} +| '(' joined_table ')' alias_clause + { + $$ = cat_str(4,mm_strdup("("),$2,mm_strdup(")"),$4); +} +; + + + joined_table: + '(' joined_table ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(")")); +} +| table_ref CROSS JOIN table_ref + { + $$ = cat_str(3,$1,mm_strdup("cross join"),$4); +} +| table_ref join_type JOIN table_ref join_qual + { + $$ = cat_str(5,$1,$2,mm_strdup("join"),$4,$5); +} +| table_ref JOIN table_ref join_qual + { + $$ = cat_str(4,$1,mm_strdup("join"),$3,$4); +} +| table_ref NATURAL join_type JOIN table_ref + { + $$ = cat_str(5,$1,mm_strdup("natural"),$3,mm_strdup("join"),$5); +} +| table_ref NATURAL JOIN table_ref + { + $$ = cat_str(3,$1,mm_strdup("natural join"),$4); +} +; + + + alias_clause: + AS ColId '(' name_list ')' + { + $$ = cat_str(5,mm_strdup("as"),$2,mm_strdup("("),$4,mm_strdup(")")); +} +| AS ColId + { + $$ = cat_str(2,mm_strdup("as"),$2); +} +| ColId '(' name_list ')' + { + $$ = cat_str(4,$1,mm_strdup("("),$3,mm_strdup(")")); +} +| ColId + { + $$ = $1; +} +; + + + join_type: + FULL join_outer + { + $$ = cat_str(2,mm_strdup("full"),$2); +} +| LEFT join_outer + { + $$ = cat_str(2,mm_strdup("left"),$2); +} +| RIGHT join_outer + { + $$ = cat_str(2,mm_strdup("right"),$2); +} +| INNER_P + { + $$ = mm_strdup("inner"); +} +; + + + join_outer: + OUTER_P + { + $$ = mm_strdup("outer"); +} +| + { + $$=EMPTY; } +; + + + join_qual: + USING '(' name_list ')' + { + $$ = cat_str(3,mm_strdup("using ("),$3,mm_strdup(")")); +} +| ON a_expr + { + $$ = cat_str(2,mm_strdup("on"),$2); +} +; + + + relation_expr: + qualified_name + { + $$ = $1; +} +| qualified_name '*' + { + $$ = cat_str(2,$1,mm_strdup("*")); +} +| ONLY qualified_name + { + $$ = cat_str(2,mm_strdup("only"),$2); +} +| ONLY '(' qualified_name ')' + { + $$ = cat_str(3,mm_strdup("only ("),$3,mm_strdup(")")); +} +; + + + relation_expr_list: + relation_expr + { + $$ = $1; +} +| relation_expr_list ',' relation_expr + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + relation_expr_opt_alias: + relation_expr %prec UMINUS + { + $$ = $1; +} +| relation_expr ColId + { + $$ = cat_str(2,$1,$2); +} +| relation_expr AS ColId + { + $$ = cat_str(3,$1,mm_strdup("as"),$3); +} +; + + + func_table: + func_expr + { + $$ = $1; +} +; + + + where_clause: + WHERE a_expr + { + $$ = cat_str(2,mm_strdup("where"),$2); +} +| + { + $$=EMPTY; } +; + + + where_or_current_clause: + WHERE a_expr + { + $$ = cat_str(2,mm_strdup("where"),$2); +} +| WHERE CURRENT_P OF cursor_name + { + char *cursor_marker = $4[0] == ':' ? mm_strdup("$0") : $4; + $$ = cat_str(2,mm_strdup("where current of"), cursor_marker); + } +| + { + $$=EMPTY; } +; + + + OptTableFuncElementList: + TableFuncElementList + { + $$ = $1; +} +| + { + $$=EMPTY; } +; + + + TableFuncElementList: + TableFuncElement + { + $$ = $1; +} +| TableFuncElementList ',' TableFuncElement + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + TableFuncElement: + ColId Typename opt_collate_clause + { + $$ = cat_str(3,$1,$2,$3); +} +; + + + Typename: + SimpleTypename opt_array_bounds + { $$ = cat2_str($1, $2.str); } +| SETOF SimpleTypename opt_array_bounds + { $$ = cat_str(3, mm_strdup("setof"), $2, $3.str); } +| SimpleTypename ARRAY '[' Iconst ']' + { + $$ = cat_str(4,$1,mm_strdup("array ["),$4,mm_strdup("]")); +} +| SETOF SimpleTypename ARRAY '[' Iconst ']' + { + $$ = cat_str(5,mm_strdup("setof"),$2,mm_strdup("array ["),$5,mm_strdup("]")); +} +| SimpleTypename ARRAY + { + $$ = cat_str(2,$1,mm_strdup("array")); +} +| SETOF SimpleTypename ARRAY + { + $$ = cat_str(3,mm_strdup("setof"),$2,mm_strdup("array")); +} +; + + + opt_array_bounds: + opt_array_bounds '[' ']' + { + $$.index1 = $1.index1; + $$.index2 = $1.index2; + if (strcmp($$.index1, "-1") == 0) + $$.index1 = mm_strdup("0"); + else if (strcmp($1.index2, "-1") == 0) + $$.index2 = mm_strdup("0"); + $$.str = cat_str(2, $1.str, mm_strdup("[]")); + } + | opt_array_bounds '[' Iresult ']' + { + $$.index1 = $1.index1; + $$.index2 = $1.index2; + if (strcmp($1.index1, "-1") == 0) + $$.index1 = strdup($3); + else if (strcmp($1.index2, "-1") == 0) + $$.index2 = strdup($3); + $$.str = cat_str(4, $1.str, mm_strdup("["), $3, mm_strdup("]")); + } +| + { + $$.index1 = mm_strdup("-1"); + $$.index2 = mm_strdup("-1"); + $$.str= EMPTY; + } +; + + + SimpleTypename: + GenericType + { + $$ = $1; +} +| Numeric + { + $$ = $1; +} +| Bit + { + $$ = $1; +} +| Character + { + $$ = $1; +} +| ConstDatetime + { + $$ = $1; +} +| ConstInterval opt_interval + { + $$ = cat_str(2,$1,$2); +} +| ConstInterval '(' Iconst ')' opt_interval + { + $$ = cat_str(5,$1,mm_strdup("("),$3,mm_strdup(")"),$5); +} +; + + + ConstTypename: + Numeric + { + $$ = $1; +} +| ConstBit + { + $$ = $1; +} +| ConstCharacter + { + $$ = $1; +} +| ConstDatetime + { + $$ = $1; +} +; + + + GenericType: + type_function_name opt_type_modifiers + { + $$ = cat_str(2,$1,$2); +} +| type_function_name attrs opt_type_modifiers + { + $$ = cat_str(3,$1,$2,$3); +} +; + + + opt_type_modifiers: + '(' expr_list ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(")")); +} +| + { + $$=EMPTY; } +; + + + Numeric: + INT_P + { + $$ = mm_strdup("int"); +} +| INTEGER + { + $$ = mm_strdup("integer"); +} +| SMALLINT + { + $$ = mm_strdup("smallint"); +} +| BIGINT + { + $$ = mm_strdup("bigint"); +} +| REAL + { + $$ = mm_strdup("real"); +} +| FLOAT_P opt_float + { + $$ = cat_str(2,mm_strdup("float"),$2); +} +| DOUBLE_P PRECISION + { + $$ = mm_strdup("double precision"); +} +| DECIMAL_P opt_type_modifiers + { + $$ = cat_str(2,mm_strdup("decimal"),$2); +} +| DEC opt_type_modifiers + { + $$ = cat_str(2,mm_strdup("dec"),$2); +} +| NUMERIC opt_type_modifiers + { + $$ = cat_str(2,mm_strdup("numeric"),$2); +} +| BOOLEAN_P + { + $$ = mm_strdup("boolean"); +} +; + + + opt_float: + '(' Iconst ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(")")); +} +| + { + $$=EMPTY; } +; + + + Bit: + BitWithLength + { + $$ = $1; +} +| BitWithoutLength + { + $$ = $1; +} +; + + + ConstBit: + BitWithLength + { + $$ = $1; +} +| BitWithoutLength + { + $$ = $1; +} +; + + + BitWithLength: + BIT opt_varying '(' expr_list ')' + { + $$ = cat_str(5,mm_strdup("bit"),$2,mm_strdup("("),$4,mm_strdup(")")); +} +; + + + BitWithoutLength: + BIT opt_varying + { + $$ = cat_str(2,mm_strdup("bit"),$2); +} +; + + + Character: + CharacterWithLength + { + $$ = $1; +} +| CharacterWithoutLength + { + $$ = $1; +} +; + + + ConstCharacter: + CharacterWithLength + { + $$ = $1; +} +| CharacterWithoutLength + { + $$ = $1; +} +; + + + CharacterWithLength: + character '(' Iconst ')' opt_charset + { + $$ = cat_str(5,$1,mm_strdup("("),$3,mm_strdup(")"),$5); +} +; + + + CharacterWithoutLength: + character opt_charset + { + $$ = cat_str(2,$1,$2); +} +; + + + character: + CHARACTER opt_varying + { + $$ = cat_str(2,mm_strdup("character"),$2); +} +| CHAR_P opt_varying + { + $$ = cat_str(2,mm_strdup("char"),$2); +} +| VARCHAR + { + $$ = mm_strdup("varchar"); +} +| NATIONAL CHARACTER opt_varying + { + $$ = cat_str(2,mm_strdup("national character"),$3); +} +| NATIONAL CHAR_P opt_varying + { + $$ = cat_str(2,mm_strdup("national char"),$3); +} +| NCHAR opt_varying + { + $$ = cat_str(2,mm_strdup("nchar"),$2); +} +; + + + opt_varying: + VARYING + { + $$ = mm_strdup("varying"); +} +| + { + $$=EMPTY; } +; + + + opt_charset: + CHARACTER SET ColId + { + $$ = cat_str(2,mm_strdup("character set"),$3); +} +| + { + $$=EMPTY; } +; + + + ConstDatetime: + TIMESTAMP '(' Iconst ')' opt_timezone + { + $$ = cat_str(4,mm_strdup("timestamp ("),$3,mm_strdup(")"),$5); +} +| TIMESTAMP opt_timezone + { + $$ = cat_str(2,mm_strdup("timestamp"),$2); +} +| TIME '(' Iconst ')' opt_timezone + { + $$ = cat_str(4,mm_strdup("time ("),$3,mm_strdup(")"),$5); +} +| TIME opt_timezone + { + $$ = cat_str(2,mm_strdup("time"),$2); +} +; + + + ConstInterval: + INTERVAL + { + $$ = mm_strdup("interval"); +} +; + + + opt_timezone: + WITH_TIME ZONE + { + $$ = mm_strdup("with time zone"); +} +| WITHOUT TIME ZONE + { + $$ = mm_strdup("without time zone"); +} +| + { + $$=EMPTY; } +; + + + opt_interval: + YEAR_P + { + $$ = mm_strdup("year"); +} +| MONTH_P + { + $$ = mm_strdup("month"); +} +| DAY_P + { + $$ = mm_strdup("day"); +} +| HOUR_P + { + $$ = mm_strdup("hour"); +} +| MINUTE_P + { + $$ = mm_strdup("minute"); +} +| interval_second + { + $$ = $1; +} +| YEAR_P TO MONTH_P + { + $$ = mm_strdup("year to month"); +} +| DAY_P TO HOUR_P + { + $$ = mm_strdup("day to hour"); +} +| DAY_P TO MINUTE_P + { + $$ = mm_strdup("day to minute"); +} +| DAY_P TO interval_second + { + $$ = cat_str(2,mm_strdup("day to"),$3); +} +| HOUR_P TO MINUTE_P + { + $$ = mm_strdup("hour to minute"); +} +| HOUR_P TO interval_second + { + $$ = cat_str(2,mm_strdup("hour to"),$3); +} +| MINUTE_P TO interval_second + { + $$ = cat_str(2,mm_strdup("minute to"),$3); +} +| + { + $$=EMPTY; } +; + + + interval_second: + SECOND_P + { + $$ = mm_strdup("second"); +} +| SECOND_P '(' Iconst ')' + { + $$ = cat_str(3,mm_strdup("second ("),$3,mm_strdup(")")); +} +; + + + a_expr: + c_expr + { + $$ = $1; +} +| a_expr TYPECAST Typename + { + $$ = cat_str(3,$1,mm_strdup("::"),$3); +} +| a_expr COLLATE any_name + { + $$ = cat_str(3,$1,mm_strdup("collate"),$3); +} +| a_expr AT TIME ZONE a_expr %prec AT + { + $$ = cat_str(3,$1,mm_strdup("at time zone"),$5); +} +| '+' a_expr %prec UMINUS + { + $$ = cat_str(2,mm_strdup("+"),$2); +} +| '-' a_expr %prec UMINUS + { + $$ = cat_str(2,mm_strdup("-"),$2); +} +| a_expr '+' a_expr + { + $$ = cat_str(3,$1,mm_strdup("+"),$3); +} +| a_expr '-' a_expr + { + $$ = cat_str(3,$1,mm_strdup("-"),$3); +} +| a_expr '*' a_expr + { + $$ = cat_str(3,$1,mm_strdup("*"),$3); +} +| a_expr '/' a_expr + { + $$ = cat_str(3,$1,mm_strdup("/"),$3); +} +| a_expr '%' a_expr + { + $$ = cat_str(3,$1,mm_strdup("%"),$3); +} +| a_expr '^' a_expr + { + $$ = cat_str(3,$1,mm_strdup("^"),$3); +} +| a_expr '<' a_expr + { + $$ = cat_str(3,$1,mm_strdup("<"),$3); +} +| a_expr '>' a_expr + { + $$ = cat_str(3,$1,mm_strdup(">"),$3); +} +| a_expr '=' a_expr + { + $$ = cat_str(3,$1,mm_strdup("="),$3); +} +| a_expr qual_Op a_expr %prec Op + { + $$ = cat_str(3,$1,$2,$3); +} +| qual_Op a_expr %prec Op + { + $$ = cat_str(2,$1,$2); +} +| a_expr qual_Op %prec POSTFIXOP + { + $$ = cat_str(2,$1,$2); +} +| a_expr AND a_expr + { + $$ = cat_str(3,$1,mm_strdup("and"),$3); +} +| a_expr OR a_expr + { + $$ = cat_str(3,$1,mm_strdup("or"),$3); +} +| NOT a_expr + { + $$ = cat_str(2,mm_strdup("not"),$2); +} +| a_expr LIKE a_expr + { + $$ = cat_str(3,$1,mm_strdup("like"),$3); +} +| a_expr LIKE a_expr ESCAPE a_expr + { + $$ = cat_str(5,$1,mm_strdup("like"),$3,mm_strdup("escape"),$5); +} +| a_expr NOT LIKE a_expr + { + $$ = cat_str(3,$1,mm_strdup("not like"),$4); +} +| a_expr NOT LIKE a_expr ESCAPE a_expr + { + $$ = cat_str(5,$1,mm_strdup("not like"),$4,mm_strdup("escape"),$6); +} +| a_expr ILIKE a_expr + { + $$ = cat_str(3,$1,mm_strdup("ilike"),$3); +} +| a_expr ILIKE a_expr ESCAPE a_expr + { + $$ = cat_str(5,$1,mm_strdup("ilike"),$3,mm_strdup("escape"),$5); +} +| a_expr NOT ILIKE a_expr + { + $$ = cat_str(3,$1,mm_strdup("not ilike"),$4); +} +| a_expr NOT ILIKE a_expr ESCAPE a_expr + { + $$ = cat_str(5,$1,mm_strdup("not ilike"),$4,mm_strdup("escape"),$6); +} +| a_expr SIMILAR TO a_expr %prec SIMILAR + { + $$ = cat_str(3,$1,mm_strdup("similar to"),$4); +} +| a_expr SIMILAR TO a_expr ESCAPE a_expr + { + $$ = cat_str(5,$1,mm_strdup("similar to"),$4,mm_strdup("escape"),$6); +} +| a_expr NOT SIMILAR TO a_expr %prec SIMILAR + { + $$ = cat_str(3,$1,mm_strdup("not similar to"),$5); +} +| a_expr NOT SIMILAR TO a_expr ESCAPE a_expr + { + $$ = cat_str(5,$1,mm_strdup("not similar to"),$5,mm_strdup("escape"),$7); +} +| a_expr IS NULL_P %prec IS + { + $$ = cat_str(2,$1,mm_strdup("is null")); +} +| a_expr ISNULL + { + $$ = cat_str(2,$1,mm_strdup("isnull")); +} +| a_expr IS NOT NULL_P %prec IS + { + $$ = cat_str(2,$1,mm_strdup("is not null")); +} +| a_expr NOTNULL + { + $$ = cat_str(2,$1,mm_strdup("notnull")); +} +| row OVERLAPS row + { + $$ = cat_str(3,$1,mm_strdup("overlaps"),$3); +} +| a_expr IS TRUE_P %prec IS + { + $$ = cat_str(2,$1,mm_strdup("is true")); +} +| a_expr IS NOT TRUE_P %prec IS + { + $$ = cat_str(2,$1,mm_strdup("is not true")); +} +| a_expr IS FALSE_P %prec IS + { + $$ = cat_str(2,$1,mm_strdup("is false")); +} +| a_expr IS NOT FALSE_P %prec IS + { + $$ = cat_str(2,$1,mm_strdup("is not false")); +} +| a_expr IS UNKNOWN %prec IS + { + $$ = cat_str(2,$1,mm_strdup("is unknown")); +} +| a_expr IS NOT UNKNOWN %prec IS + { + $$ = cat_str(2,$1,mm_strdup("is not unknown")); +} +| a_expr IS DISTINCT FROM a_expr %prec IS + { + $$ = cat_str(3,$1,mm_strdup("is distinct from"),$5); +} +| a_expr IS NOT DISTINCT FROM a_expr %prec IS + { + $$ = cat_str(3,$1,mm_strdup("is not distinct from"),$6); +} +| a_expr IS OF '(' type_list ')' %prec IS + { + $$ = cat_str(4,$1,mm_strdup("is of ("),$5,mm_strdup(")")); +} +| a_expr IS NOT OF '(' type_list ')' %prec IS + { + $$ = cat_str(4,$1,mm_strdup("is not of ("),$6,mm_strdup(")")); +} +| a_expr BETWEEN opt_asymmetric b_expr AND b_expr %prec BETWEEN + { + $$ = cat_str(6,$1,mm_strdup("between"),$3,$4,mm_strdup("and"),$6); +} +| a_expr NOT BETWEEN opt_asymmetric b_expr AND b_expr %prec BETWEEN + { + $$ = cat_str(6,$1,mm_strdup("not between"),$4,$5,mm_strdup("and"),$7); +} +| a_expr BETWEEN SYMMETRIC b_expr AND b_expr %prec BETWEEN + { + $$ = cat_str(5,$1,mm_strdup("between symmetric"),$4,mm_strdup("and"),$6); +} +| a_expr NOT BETWEEN SYMMETRIC b_expr AND b_expr %prec BETWEEN + { + $$ = cat_str(5,$1,mm_strdup("not between symmetric"),$5,mm_strdup("and"),$7); +} +| a_expr IN_P in_expr + { + $$ = cat_str(3,$1,mm_strdup("in"),$3); +} +| a_expr NOT IN_P in_expr + { + $$ = cat_str(3,$1,mm_strdup("not in"),$4); +} +| a_expr subquery_Op sub_type select_with_parens %prec Op + { + $$ = cat_str(4,$1,$2,$3,$4); +} +| a_expr subquery_Op sub_type '(' a_expr ')' %prec Op + { + $$ = cat_str(6,$1,$2,$3,mm_strdup("("),$5,mm_strdup(")")); +} +| UNIQUE select_with_parens + { +mmerror(PARSE_ERROR, ET_WARNING, "unsupported feature will be passed to server"); + $$ = cat_str(2,mm_strdup("unique"),$2); +} +| a_expr IS DOCUMENT_P %prec IS + { + $$ = cat_str(2,$1,mm_strdup("is document")); +} +| a_expr IS NOT DOCUMENT_P %prec IS + { + $$ = cat_str(2,$1,mm_strdup("is not document")); +} +; + + + b_expr: + c_expr + { + $$ = $1; +} +| b_expr TYPECAST Typename + { + $$ = cat_str(3,$1,mm_strdup("::"),$3); +} +| '+' b_expr %prec UMINUS + { + $$ = cat_str(2,mm_strdup("+"),$2); +} +| '-' b_expr %prec UMINUS + { + $$ = cat_str(2,mm_strdup("-"),$2); +} +| b_expr '+' b_expr + { + $$ = cat_str(3,$1,mm_strdup("+"),$3); +} +| b_expr '-' b_expr + { + $$ = cat_str(3,$1,mm_strdup("-"),$3); +} +| b_expr '*' b_expr + { + $$ = cat_str(3,$1,mm_strdup("*"),$3); +} +| b_expr '/' b_expr + { + $$ = cat_str(3,$1,mm_strdup("/"),$3); +} +| b_expr '%' b_expr + { + $$ = cat_str(3,$1,mm_strdup("%"),$3); +} +| b_expr '^' b_expr + { + $$ = cat_str(3,$1,mm_strdup("^"),$3); +} +| b_expr '<' b_expr + { + $$ = cat_str(3,$1,mm_strdup("<"),$3); +} +| b_expr '>' b_expr + { + $$ = cat_str(3,$1,mm_strdup(">"),$3); +} +| b_expr '=' b_expr + { + $$ = cat_str(3,$1,mm_strdup("="),$3); +} +| b_expr qual_Op b_expr %prec Op + { + $$ = cat_str(3,$1,$2,$3); +} +| qual_Op b_expr %prec Op + { + $$ = cat_str(2,$1,$2); +} +| b_expr qual_Op %prec POSTFIXOP + { + $$ = cat_str(2,$1,$2); +} +| b_expr IS DISTINCT FROM b_expr %prec IS + { + $$ = cat_str(3,$1,mm_strdup("is distinct from"),$5); +} +| b_expr IS NOT DISTINCT FROM b_expr %prec IS + { + $$ = cat_str(3,$1,mm_strdup("is not distinct from"),$6); +} +| b_expr IS OF '(' type_list ')' %prec IS + { + $$ = cat_str(4,$1,mm_strdup("is of ("),$5,mm_strdup(")")); +} +| b_expr IS NOT OF '(' type_list ')' %prec IS + { + $$ = cat_str(4,$1,mm_strdup("is not of ("),$6,mm_strdup(")")); +} +| b_expr IS DOCUMENT_P %prec IS + { + $$ = cat_str(2,$1,mm_strdup("is document")); +} +| b_expr IS NOT DOCUMENT_P %prec IS + { + $$ = cat_str(2,$1,mm_strdup("is not document")); +} +; + + + c_expr: + columnref + { + $$ = $1; +} +| AexprConst + { + $$ = $1; +} +| ecpg_param opt_indirection + { + $$ = cat_str(2,$1,$2); +} +| '(' a_expr ')' opt_indirection + { + $$ = cat_str(4,mm_strdup("("),$2,mm_strdup(")"),$4); +} +| case_expr + { + $$ = $1; +} +| func_expr + { + $$ = $1; +} +| select_with_parens %prec UMINUS + { + $$ = $1; +} +| EXISTS select_with_parens + { + $$ = cat_str(2,mm_strdup("exists"),$2); +} +| ARRAY select_with_parens + { + $$ = cat_str(2,mm_strdup("array"),$2); +} +| ARRAY array_expr + { + $$ = cat_str(2,mm_strdup("array"),$2); +} +| row + { + $$ = $1; +} +; + + + func_expr: + func_name '(' ')' over_clause + { + $$ = cat_str(3,$1,mm_strdup("( )"),$4); +} +| func_name '(' func_arg_list ')' over_clause + { + $$ = cat_str(5,$1,mm_strdup("("),$3,mm_strdup(")"),$5); +} +| func_name '(' VARIADIC func_arg_expr ')' over_clause + { + $$ = cat_str(5,$1,mm_strdup("( variadic"),$4,mm_strdup(")"),$6); +} +| func_name '(' func_arg_list ',' VARIADIC func_arg_expr ')' over_clause + { + $$ = cat_str(7,$1,mm_strdup("("),$3,mm_strdup(", variadic"),$6,mm_strdup(")"),$8); +} +| func_name '(' func_arg_list sort_clause ')' over_clause + { + $$ = cat_str(6,$1,mm_strdup("("),$3,$4,mm_strdup(")"),$6); +} +| func_name '(' ALL func_arg_list opt_sort_clause ')' over_clause + { + $$ = cat_str(6,$1,mm_strdup("( all"),$4,$5,mm_strdup(")"),$7); +} +| func_name '(' DISTINCT func_arg_list opt_sort_clause ')' over_clause + { + $$ = cat_str(6,$1,mm_strdup("( distinct"),$4,$5,mm_strdup(")"),$7); +} +| func_name '(' '*' ')' over_clause + { + $$ = cat_str(3,$1,mm_strdup("( * )"),$5); +} +| COLLATION FOR '(' a_expr ')' + { + $$ = cat_str(3,mm_strdup("collation for ("),$4,mm_strdup(")")); +} +| CURRENT_DATE + { + $$ = mm_strdup("current_date"); +} +| CURRENT_TIME + { + $$ = mm_strdup("current_time"); +} +| CURRENT_TIME '(' Iconst ')' + { + $$ = cat_str(3,mm_strdup("current_time ("),$3,mm_strdup(")")); +} +| CURRENT_TIMESTAMP + { + $$ = mm_strdup("current_timestamp"); +} +| CURRENT_TIMESTAMP '(' Iconst ')' + { + $$ = cat_str(3,mm_strdup("current_timestamp ("),$3,mm_strdup(")")); +} +| LOCALTIME + { + $$ = mm_strdup("localtime"); +} +| LOCALTIME '(' Iconst ')' + { + $$ = cat_str(3,mm_strdup("localtime ("),$3,mm_strdup(")")); +} +| LOCALTIMESTAMP + { + $$ = mm_strdup("localtimestamp"); +} +| LOCALTIMESTAMP '(' Iconst ')' + { + $$ = cat_str(3,mm_strdup("localtimestamp ("),$3,mm_strdup(")")); +} +| CURRENT_ROLE + { + $$ = mm_strdup("current_role"); +} +| CURRENT_USER + { + $$ = mm_strdup("current_user"); +} +| SESSION_USER + { + $$ = mm_strdup("session_user"); +} +| USER + { + $$ = mm_strdup("user"); +} +| CURRENT_CATALOG + { + $$ = mm_strdup("current_catalog"); +} +| CURRENT_SCHEMA + { + $$ = mm_strdup("current_schema"); +} +| CAST '(' a_expr AS Typename ')' + { + $$ = cat_str(5,mm_strdup("cast ("),$3,mm_strdup("as"),$5,mm_strdup(")")); +} +| EXTRACT '(' extract_list ')' + { + $$ = cat_str(3,mm_strdup("extract ("),$3,mm_strdup(")")); +} +| OVERLAY '(' overlay_list ')' + { + $$ = cat_str(3,mm_strdup("overlay ("),$3,mm_strdup(")")); +} +| POSITION '(' position_list ')' + { + $$ = cat_str(3,mm_strdup("position ("),$3,mm_strdup(")")); +} +| SUBSTRING '(' substr_list ')' + { + $$ = cat_str(3,mm_strdup("substring ("),$3,mm_strdup(")")); +} +| TREAT '(' a_expr AS Typename ')' + { + $$ = cat_str(5,mm_strdup("treat ("),$3,mm_strdup("as"),$5,mm_strdup(")")); +} +| TRIM '(' BOTH trim_list ')' + { + $$ = cat_str(3,mm_strdup("trim ( both"),$4,mm_strdup(")")); +} +| TRIM '(' LEADING trim_list ')' + { + $$ = cat_str(3,mm_strdup("trim ( leading"),$4,mm_strdup(")")); +} +| TRIM '(' TRAILING trim_list ')' + { + $$ = cat_str(3,mm_strdup("trim ( trailing"),$4,mm_strdup(")")); +} +| TRIM '(' trim_list ')' + { + $$ = cat_str(3,mm_strdup("trim ("),$3,mm_strdup(")")); +} +| NULLIF '(' a_expr ',' a_expr ')' + { + $$ = cat_str(5,mm_strdup("nullif ("),$3,mm_strdup(","),$5,mm_strdup(")")); +} +| COALESCE '(' expr_list ')' + { + $$ = cat_str(3,mm_strdup("coalesce ("),$3,mm_strdup(")")); +} +| GREATEST '(' expr_list ')' + { + $$ = cat_str(3,mm_strdup("greatest ("),$3,mm_strdup(")")); +} +| LEAST '(' expr_list ')' + { + $$ = cat_str(3,mm_strdup("least ("),$3,mm_strdup(")")); +} +| XMLCONCAT '(' expr_list ')' + { + $$ = cat_str(3,mm_strdup("xmlconcat ("),$3,mm_strdup(")")); +} +| XMLELEMENT '(' NAME_P ColLabel ')' + { + $$ = cat_str(3,mm_strdup("xmlelement ( name"),$4,mm_strdup(")")); +} +| XMLELEMENT '(' NAME_P ColLabel ',' xml_attributes ')' + { + $$ = cat_str(5,mm_strdup("xmlelement ( name"),$4,mm_strdup(","),$6,mm_strdup(")")); +} +| XMLELEMENT '(' NAME_P ColLabel ',' expr_list ')' + { + $$ = cat_str(5,mm_strdup("xmlelement ( name"),$4,mm_strdup(","),$6,mm_strdup(")")); +} +| XMLELEMENT '(' NAME_P ColLabel ',' xml_attributes ',' expr_list ')' + { + $$ = cat_str(7,mm_strdup("xmlelement ( name"),$4,mm_strdup(","),$6,mm_strdup(","),$8,mm_strdup(")")); +} +| XMLEXISTS '(' c_expr xmlexists_argument ')' + { + $$ = cat_str(4,mm_strdup("xmlexists ("),$3,$4,mm_strdup(")")); +} +| XMLFOREST '(' xml_attribute_list ')' + { + $$ = cat_str(3,mm_strdup("xmlforest ("),$3,mm_strdup(")")); +} +| XMLPARSE '(' document_or_content a_expr xml_whitespace_option ')' + { + $$ = cat_str(5,mm_strdup("xmlparse ("),$3,$4,$5,mm_strdup(")")); +} +| XMLPI '(' NAME_P ColLabel ')' + { + $$ = cat_str(3,mm_strdup("xmlpi ( name"),$4,mm_strdup(")")); +} +| XMLPI '(' NAME_P ColLabel ',' a_expr ')' + { + $$ = cat_str(5,mm_strdup("xmlpi ( name"),$4,mm_strdup(","),$6,mm_strdup(")")); +} +| XMLROOT '(' a_expr ',' xml_root_version opt_xml_root_standalone ')' + { + $$ = cat_str(6,mm_strdup("xmlroot ("),$3,mm_strdup(","),$5,$6,mm_strdup(")")); +} +| XMLSERIALIZE '(' document_or_content a_expr AS SimpleTypename ')' + { + $$ = cat_str(6,mm_strdup("xmlserialize ("),$3,$4,mm_strdup("as"),$6,mm_strdup(")")); +} +; + + + xml_root_version: + VERSION_P a_expr + { + $$ = cat_str(2,mm_strdup("version"),$2); +} +| VERSION_P NO VALUE_P + { + $$ = mm_strdup("version no value"); +} +; + + + opt_xml_root_standalone: + ',' STANDALONE_P YES_P + { + $$ = mm_strdup(", standalone yes"); +} +| ',' STANDALONE_P NO + { + $$ = mm_strdup(", standalone no"); +} +| ',' STANDALONE_P NO VALUE_P + { + $$ = mm_strdup(", standalone no value"); +} +| + { + $$=EMPTY; } +; + + + xml_attributes: + XMLATTRIBUTES '(' xml_attribute_list ')' + { + $$ = cat_str(3,mm_strdup("xmlattributes ("),$3,mm_strdup(")")); +} +; + + + xml_attribute_list: + xml_attribute_el + { + $$ = $1; +} +| xml_attribute_list ',' xml_attribute_el + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + xml_attribute_el: + a_expr AS ColLabel + { + $$ = cat_str(3,$1,mm_strdup("as"),$3); +} +| a_expr + { + $$ = $1; +} +; + + + document_or_content: + DOCUMENT_P + { + $$ = mm_strdup("document"); +} +| CONTENT_P + { + $$ = mm_strdup("content"); +} +; + + + xml_whitespace_option: + PRESERVE WHITESPACE_P + { + $$ = mm_strdup("preserve whitespace"); +} +| STRIP_P WHITESPACE_P + { + $$ = mm_strdup("strip whitespace"); +} +| + { + $$=EMPTY; } +; + + + xmlexists_argument: + PASSING c_expr + { + $$ = cat_str(2,mm_strdup("passing"),$2); +} +| PASSING c_expr BY REF + { + $$ = cat_str(3,mm_strdup("passing"),$2,mm_strdup("by ref")); +} +| PASSING BY REF c_expr + { + $$ = cat_str(2,mm_strdup("passing by ref"),$4); +} +| PASSING BY REF c_expr BY REF + { + $$ = cat_str(3,mm_strdup("passing by ref"),$4,mm_strdup("by ref")); +} +; + + + window_clause: + WINDOW window_definition_list + { + $$ = cat_str(2,mm_strdup("window"),$2); +} +| + { + $$=EMPTY; } +; + + + window_definition_list: + window_definition + { + $$ = $1; +} +| window_definition_list ',' window_definition + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + window_definition: + ColId AS window_specification + { + $$ = cat_str(3,$1,mm_strdup("as"),$3); +} +; + + + over_clause: + OVER window_specification + { + $$ = cat_str(2,mm_strdup("over"),$2); +} +| OVER ColId + { + $$ = cat_str(2,mm_strdup("over"),$2); +} +| + { + $$=EMPTY; } +; + + + window_specification: + '(' opt_existing_window_name opt_partition_clause opt_sort_clause opt_frame_clause ')' + { + $$ = cat_str(6,mm_strdup("("),$2,$3,$4,$5,mm_strdup(")")); +} +; + + + opt_existing_window_name: + ColId + { + $$ = $1; +} +| %prec Op + { + $$=EMPTY; } +; + + + opt_partition_clause: + PARTITION BY expr_list + { + $$ = cat_str(2,mm_strdup("partition by"),$3); +} +| + { + $$=EMPTY; } +; + + + opt_frame_clause: + RANGE frame_extent + { +mmerror(PARSE_ERROR, ET_WARNING, "unsupported feature will be passed to server"); + $$ = cat_str(2,mm_strdup("range"),$2); +} +| ROWS frame_extent + { + $$ = cat_str(2,mm_strdup("rows"),$2); +} +| + { + $$=EMPTY; } +; + + + frame_extent: + frame_bound + { + $$ = $1; +} +| BETWEEN frame_bound AND frame_bound + { + $$ = cat_str(4,mm_strdup("between"),$2,mm_strdup("and"),$4); +} +; + + + frame_bound: + UNBOUNDED PRECEDING + { + $$ = mm_strdup("unbounded preceding"); +} +| UNBOUNDED FOLLOWING + { + $$ = mm_strdup("unbounded following"); +} +| CURRENT_P ROW + { + $$ = mm_strdup("current row"); +} +| a_expr PRECEDING + { + $$ = cat_str(2,$1,mm_strdup("preceding")); +} +| a_expr FOLLOWING + { + $$ = cat_str(2,$1,mm_strdup("following")); +} +; + + + row: + ROW '(' expr_list ')' + { + $$ = cat_str(3,mm_strdup("row ("),$3,mm_strdup(")")); +} +| ROW '(' ')' + { + $$ = mm_strdup("row ( )"); +} +| '(' expr_list ',' a_expr ')' + { + $$ = cat_str(5,mm_strdup("("),$2,mm_strdup(","),$4,mm_strdup(")")); +} +; + + + sub_type: + ANY + { + $$ = mm_strdup("any"); +} +| SOME + { + $$ = mm_strdup("some"); +} +| ALL + { + $$ = mm_strdup("all"); +} +; + + + all_Op: + Op + { + $$ = $1; +} +| MathOp + { + $$ = $1; +} +; + + + MathOp: + '+' + { + $$ = mm_strdup("+"); +} +| '-' + { + $$ = mm_strdup("-"); +} +| '*' + { + $$ = mm_strdup("*"); +} +| '/' + { + $$ = mm_strdup("/"); +} +| '%' + { + $$ = mm_strdup("%"); +} +| '^' + { + $$ = mm_strdup("^"); +} +| '<' + { + $$ = mm_strdup("<"); +} +| '>' + { + $$ = mm_strdup(">"); +} +| '=' + { + $$ = mm_strdup("="); +} +; + + + qual_Op: + Op + { + $$ = $1; +} +| OPERATOR '(' any_operator ')' + { + $$ = cat_str(3,mm_strdup("operator ("),$3,mm_strdup(")")); +} +; + + + qual_all_Op: + all_Op + { + $$ = $1; +} +| OPERATOR '(' any_operator ')' + { + $$ = cat_str(3,mm_strdup("operator ("),$3,mm_strdup(")")); +} +; + + + subquery_Op: + all_Op + { + $$ = $1; +} +| OPERATOR '(' any_operator ')' + { + $$ = cat_str(3,mm_strdup("operator ("),$3,mm_strdup(")")); +} +| LIKE + { + $$ = mm_strdup("like"); +} +| NOT LIKE + { + $$ = mm_strdup("not like"); +} +| ILIKE + { + $$ = mm_strdup("ilike"); +} +| NOT ILIKE + { + $$ = mm_strdup("not ilike"); +} +; + + + expr_list: + a_expr + { + $$ = $1; +} +| expr_list ',' a_expr + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + func_arg_list: + func_arg_expr + { + $$ = $1; +} +| func_arg_list ',' func_arg_expr + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + func_arg_expr: + a_expr + { + $$ = $1; +} +| param_name COLON_EQUALS a_expr + { + $$ = cat_str(3,$1,mm_strdup(":="),$3); +} +; + + + type_list: + Typename + { + $$ = $1; +} +| type_list ',' Typename + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + array_expr: + '[' expr_list ']' + { + $$ = cat_str(3,mm_strdup("["),$2,mm_strdup("]")); +} +| '[' array_expr_list ']' + { + $$ = cat_str(3,mm_strdup("["),$2,mm_strdup("]")); +} +| '[' ']' + { + $$ = mm_strdup("[ ]"); +} +; + + + array_expr_list: + array_expr + { + $$ = $1; +} +| array_expr_list ',' array_expr + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + extract_list: + extract_arg FROM a_expr + { + $$ = cat_str(3,$1,mm_strdup("from"),$3); +} +| + { + $$=EMPTY; } +; + + + extract_arg: + ecpg_ident + { + $$ = $1; +} +| YEAR_P + { + $$ = mm_strdup("year"); +} +| MONTH_P + { + $$ = mm_strdup("month"); +} +| DAY_P + { + $$ = mm_strdup("day"); +} +| HOUR_P + { + $$ = mm_strdup("hour"); +} +| MINUTE_P + { + $$ = mm_strdup("minute"); +} +| SECOND_P + { + $$ = mm_strdup("second"); +} +| ecpg_sconst + { + $$ = $1; +} +; + + + overlay_list: + a_expr overlay_placing substr_from substr_for + { + $$ = cat_str(4,$1,$2,$3,$4); +} +| a_expr overlay_placing substr_from + { + $$ = cat_str(3,$1,$2,$3); +} +; + + + overlay_placing: + PLACING a_expr + { + $$ = cat_str(2,mm_strdup("placing"),$2); +} +; + + + position_list: + b_expr IN_P b_expr + { + $$ = cat_str(3,$1,mm_strdup("in"),$3); +} +| + { + $$=EMPTY; } +; + + + substr_list: + a_expr substr_from substr_for + { + $$ = cat_str(3,$1,$2,$3); +} +| a_expr substr_for substr_from + { + $$ = cat_str(3,$1,$2,$3); +} +| a_expr substr_from + { + $$ = cat_str(2,$1,$2); +} +| a_expr substr_for + { + $$ = cat_str(2,$1,$2); +} +| expr_list + { + $$ = $1; +} +| + { + $$=EMPTY; } +; + + + substr_from: + FROM a_expr + { + $$ = cat_str(2,mm_strdup("from"),$2); +} +; + + + substr_for: + FOR a_expr + { + $$ = cat_str(2,mm_strdup("for"),$2); +} +; + + + trim_list: + a_expr FROM expr_list + { + $$ = cat_str(3,$1,mm_strdup("from"),$3); +} +| FROM expr_list + { + $$ = cat_str(2,mm_strdup("from"),$2); +} +| expr_list + { + $$ = $1; +} +; + + + in_expr: + select_with_parens + { + $$ = $1; +} +| '(' expr_list ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(")")); +} +; + + + case_expr: + CASE case_arg when_clause_list case_default END_P + { + $$ = cat_str(5,mm_strdup("case"),$2,$3,$4,mm_strdup("end")); +} +; + + + when_clause_list: + when_clause + { + $$ = $1; +} +| when_clause_list when_clause + { + $$ = cat_str(2,$1,$2); +} +; + + + when_clause: + WHEN a_expr THEN a_expr + { + $$ = cat_str(4,mm_strdup("when"),$2,mm_strdup("then"),$4); +} +; + + + case_default: + ELSE a_expr + { + $$ = cat_str(2,mm_strdup("else"),$2); +} +| + { + $$=EMPTY; } +; + + + case_arg: + a_expr + { + $$ = $1; +} +| + { + $$=EMPTY; } +; + + + columnref: + ColId + { + $$ = $1; +} +| ColId indirection + { + $$ = cat_str(2,$1,$2); +} +; + + + indirection_el: + '.' attr_name + { + $$ = cat_str(2,mm_strdup("."),$2); +} +| '.' '*' + { + $$ = mm_strdup(". *"); +} +| '[' a_expr ']' + { + $$ = cat_str(3,mm_strdup("["),$2,mm_strdup("]")); +} +| '[' a_expr ':' a_expr ']' + { + $$ = cat_str(5,mm_strdup("["),$2,mm_strdup(":"),$4,mm_strdup("]")); +} +; + + + indirection: + indirection_el + { + $$ = $1; +} +| indirection indirection_el + { + $$ = cat_str(2,$1,$2); +} +; + + + opt_indirection: + + { + $$=EMPTY; } +| opt_indirection indirection_el + { + $$ = cat_str(2,$1,$2); +} +; + + + opt_asymmetric: + ASYMMETRIC + { + $$ = mm_strdup("asymmetric"); +} +| + { + $$=EMPTY; } +; + + + ctext_expr: + a_expr + { + $$ = $1; +} +| DEFAULT + { + $$ = mm_strdup("default"); +} +; + + + ctext_expr_list: + ctext_expr + { + $$ = $1; +} +| ctext_expr_list ',' ctext_expr + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + ctext_row: + '(' ctext_expr_list ')' + { + $$ = cat_str(3,mm_strdup("("),$2,mm_strdup(")")); +} +; + + + target_list: + target_el + { + $$ = $1; +} +| target_list ',' target_el + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + target_el: + a_expr AS ColLabel + { + $$ = cat_str(3,$1,mm_strdup("as"),$3); +} +| a_expr ecpg_ident + { + $$ = cat_str(2,$1,$2); +} +| a_expr + { + $$ = $1; +} +| '*' + { + $$ = mm_strdup("*"); +} +; + + + qualified_name_list: + qualified_name + { + $$ = $1; +} +| qualified_name_list ',' qualified_name + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + qualified_name: + ColId + { + $$ = $1; +} +| ColId indirection + { + $$ = cat_str(2,$1,$2); +} +; + + + name_list: + name + { + $$ = $1; +} +| name_list ',' name + { + $$ = cat_str(3,$1,mm_strdup(","),$3); +} +; + + + name: + ColId + { + $$ = $1; +} +; + + + database_name: + ColId + { + $$ = $1; +} +; + + + access_method: + ColId + { + $$ = $1; +} +; + + + attr_name: + ColLabel + { + $$ = $1; +} +; + + + index_name: + ColId + { + $$ = $1; +} +; + + + file_name: + ecpg_sconst + { + $$ = $1; +} +; + + + func_name: + type_function_name + { + $$ = $1; +} +| ColId indirection + { + $$ = cat_str(2,$1,$2); +} +; + + + AexprConst: + Iconst + { + $$ = $1; +} +| ecpg_fconst + { + $$ = $1; +} +| ecpg_sconst + { + $$ = $1; +} +| ecpg_bconst + { + $$ = $1; +} +| XCONST + { + $$ = mm_strdup("xconst"); +} +| func_name ecpg_sconst + { + $$ = cat_str(2,$1,$2); +} +| func_name '(' func_arg_list ')' ecpg_sconst + { + $$ = cat_str(5,$1,mm_strdup("("),$3,mm_strdup(")"),$5); +} +| ConstTypename ecpg_sconst + { + $$ = cat_str(2,$1,$2); +} +| ConstInterval ecpg_sconst opt_interval + { + $$ = cat_str(3,$1,$2,$3); +} +| ConstInterval '(' Iconst ')' ecpg_sconst opt_interval + { + $$ = cat_str(6,$1,mm_strdup("("),$3,mm_strdup(")"),$5,$6); +} +| TRUE_P + { + $$ = mm_strdup("true"); +} +| FALSE_P + { + $$ = mm_strdup("false"); +} +| NULL_P + { + $$ = mm_strdup("null"); +} + | civar { $$ = $1; } + | civarind { $$ = $1; } +; + + + Iconst: + ICONST + { $$ = make_name(); } +; + + + RoleId: + ColId + { + $$ = $1; +} +; + + + SignedIconst: + Iconst + { + $$ = $1; +} + | civar { $$ = $1; } +| '+' Iconst + { + $$ = cat_str(2,mm_strdup("+"),$2); +} +| '-' Iconst + { + $$ = cat_str(2,mm_strdup("-"),$2); +} +; + + + unreserved_keyword: + ABORT_P + { + $$ = mm_strdup("abort"); +} +| ABSOLUTE_P + { + $$ = mm_strdup("absolute"); +} +| ACCESS + { + $$ = mm_strdup("access"); +} +| ACTION + { + $$ = mm_strdup("action"); +} +| ADD_P + { + $$ = mm_strdup("add"); +} +| ADMIN + { + $$ = mm_strdup("admin"); +} +| AFTER + { + $$ = mm_strdup("after"); +} +| AGGREGATE + { + $$ = mm_strdup("aggregate"); +} +| ALSO + { + $$ = mm_strdup("also"); +} +| ALTER + { + $$ = mm_strdup("alter"); +} +| ALWAYS + { + $$ = mm_strdup("always"); +} +| ASSERTION + { + $$ = mm_strdup("assertion"); +} +| ASSIGNMENT + { + $$ = mm_strdup("assignment"); +} +| AT + { + $$ = mm_strdup("at"); +} +| ATTRIBUTE + { + $$ = mm_strdup("attribute"); +} +| BACKWARD + { + $$ = mm_strdup("backward"); +} +| BEFORE + { + $$ = mm_strdup("before"); +} +| BEGIN_P + { + $$ = mm_strdup("begin"); +} +| BY + { + $$ = mm_strdup("by"); +} +| CACHE + { + $$ = mm_strdup("cache"); +} +| CALLED + { + $$ = mm_strdup("called"); +} +| CASCADE + { + $$ = mm_strdup("cascade"); +} +| CASCADED + { + $$ = mm_strdup("cascaded"); +} +| CATALOG_P + { + $$ = mm_strdup("catalog"); +} +| CHAIN + { + $$ = mm_strdup("chain"); +} +| CHARACTERISTICS + { + $$ = mm_strdup("characteristics"); +} +| CHECKPOINT + { + $$ = mm_strdup("checkpoint"); +} +| CLASS + { + $$ = mm_strdup("class"); +} +| CLOSE + { + $$ = mm_strdup("close"); +} +| CLUSTER + { + $$ = mm_strdup("cluster"); +} +| COMMENT + { + $$ = mm_strdup("comment"); +} +| COMMENTS + { + $$ = mm_strdup("comments"); +} +| COMMIT + { + $$ = mm_strdup("commit"); +} +| COMMITTED + { + $$ = mm_strdup("committed"); +} +| CONFIGURATION + { + $$ = mm_strdup("configuration"); +} +| CONSTRAINTS + { + $$ = mm_strdup("constraints"); +} +| CONTENT_P + { + $$ = mm_strdup("content"); +} +| CONTINUE_P + { + $$ = mm_strdup("continue"); +} +| CONVERSION_P + { + $$ = mm_strdup("conversion"); +} +| COPY + { + $$ = mm_strdup("copy"); +} +| COST + { + $$ = mm_strdup("cost"); +} +| CSV + { + $$ = mm_strdup("csv"); +} +| CURSOR + { + $$ = mm_strdup("cursor"); +} +| CYCLE + { + $$ = mm_strdup("cycle"); +} +| DATA_P + { + $$ = mm_strdup("data"); +} +| DATABASE + { + $$ = mm_strdup("database"); +} +| DEALLOCATE + { + $$ = mm_strdup("deallocate"); +} +| DECLARE + { + $$ = mm_strdup("declare"); +} +| DEFAULTS + { + $$ = mm_strdup("defaults"); +} +| DEFERRED + { + $$ = mm_strdup("deferred"); +} +| DEFINER + { + $$ = mm_strdup("definer"); +} +| DELETE_P + { + $$ = mm_strdup("delete"); +} +| DELIMITER + { + $$ = mm_strdup("delimiter"); +} +| DELIMITERS + { + $$ = mm_strdup("delimiters"); +} +| DICTIONARY + { + $$ = mm_strdup("dictionary"); +} +| DISABLE_P + { + $$ = mm_strdup("disable"); +} +| DISCARD + { + $$ = mm_strdup("discard"); +} +| DOCUMENT_P + { + $$ = mm_strdup("document"); +} +| DOMAIN_P + { + $$ = mm_strdup("domain"); +} +| DOUBLE_P + { + $$ = mm_strdup("double"); +} +| DROP + { + $$ = mm_strdup("drop"); +} +| EACH + { + $$ = mm_strdup("each"); +} +| ENABLE_P + { + $$ = mm_strdup("enable"); +} +| ENCODING + { + $$ = mm_strdup("encoding"); +} +| ENCRYPTED + { + $$ = mm_strdup("encrypted"); +} +| ENUM_P + { + $$ = mm_strdup("enum"); +} +| ESCAPE + { + $$ = mm_strdup("escape"); +} +| EXCLUDE + { + $$ = mm_strdup("exclude"); +} +| EXCLUDING + { + $$ = mm_strdup("excluding"); +} +| EXCLUSIVE + { + $$ = mm_strdup("exclusive"); +} +| EXECUTE + { + $$ = mm_strdup("execute"); +} +| EXPLAIN + { + $$ = mm_strdup("explain"); +} +| EXTENSION + { + $$ = mm_strdup("extension"); +} +| EXTERNAL + { + $$ = mm_strdup("external"); +} +| FAMILY + { + $$ = mm_strdup("family"); +} +| FIRST_P + { + $$ = mm_strdup("first"); +} +| FOLLOWING + { + $$ = mm_strdup("following"); +} +| FORCE + { + $$ = mm_strdup("force"); +} +| FORWARD + { + $$ = mm_strdup("forward"); +} +| FUNCTION + { + $$ = mm_strdup("function"); +} +| FUNCTIONS + { + $$ = mm_strdup("functions"); +} +| GLOBAL + { + $$ = mm_strdup("global"); +} +| GRANTED + { + $$ = mm_strdup("granted"); +} +| HANDLER + { + $$ = mm_strdup("handler"); +} +| HEADER_P + { + $$ = mm_strdup("header"); +} +| HOLD + { + $$ = mm_strdup("hold"); +} +| IDENTITY_P + { + $$ = mm_strdup("identity"); +} +| IF_P + { + $$ = mm_strdup("if"); +} +| IMMEDIATE + { + $$ = mm_strdup("immediate"); +} +| IMMUTABLE + { + $$ = mm_strdup("immutable"); +} +| IMPLICIT_P + { + $$ = mm_strdup("implicit"); +} +| INCLUDING + { + $$ = mm_strdup("including"); +} +| INCREMENT + { + $$ = mm_strdup("increment"); +} +| INDEX + { + $$ = mm_strdup("index"); +} +| INDEXES + { + $$ = mm_strdup("indexes"); +} +| INHERIT + { + $$ = mm_strdup("inherit"); +} +| INHERITS + { + $$ = mm_strdup("inherits"); +} +| INLINE_P + { + $$ = mm_strdup("inline"); +} +| INSENSITIVE + { + $$ = mm_strdup("insensitive"); +} +| INSERT + { + $$ = mm_strdup("insert"); +} +| INSTEAD + { + $$ = mm_strdup("instead"); +} +| INVOKER + { + $$ = mm_strdup("invoker"); +} +| ISOLATION + { + $$ = mm_strdup("isolation"); +} +| KEY + { + $$ = mm_strdup("key"); +} +| LABEL + { + $$ = mm_strdup("label"); +} +| LANGUAGE + { + $$ = mm_strdup("language"); +} +| LARGE_P + { + $$ = mm_strdup("large"); +} +| LAST_P + { + $$ = mm_strdup("last"); +} +| LC_COLLATE_P + { + $$ = mm_strdup("lc_collate"); +} +| LC_CTYPE_P + { + $$ = mm_strdup("lc_ctype"); +} +| LEAKPROOF + { + $$ = mm_strdup("leakproof"); +} +| LEVEL + { + $$ = mm_strdup("level"); +} +| LISTEN + { + $$ = mm_strdup("listen"); +} +| LOAD + { + $$ = mm_strdup("load"); +} +| LOCAL + { + $$ = mm_strdup("local"); +} +| LOCATION + { + $$ = mm_strdup("location"); +} +| LOCK_P + { + $$ = mm_strdup("lock"); +} +| MAPPING + { + $$ = mm_strdup("mapping"); +} +| MATCH + { + $$ = mm_strdup("match"); +} +| MAXVALUE + { + $$ = mm_strdup("maxvalue"); +} +| MINVALUE + { + $$ = mm_strdup("minvalue"); +} +| MODE + { + $$ = mm_strdup("mode"); +} +| MOVE + { + $$ = mm_strdup("move"); +} +| NAME_P + { + $$ = mm_strdup("name"); +} +| NAMES + { + $$ = mm_strdup("names"); +} +| NEXT + { + $$ = mm_strdup("next"); +} +| NO + { + $$ = mm_strdup("no"); +} +| NOTHING + { + $$ = mm_strdup("nothing"); +} +| NOTIFY + { + $$ = mm_strdup("notify"); +} +| NOWAIT + { + $$ = mm_strdup("nowait"); +} +| NULLS_P + { + $$ = mm_strdup("nulls"); +} +| OBJECT_P + { + $$ = mm_strdup("object"); +} +| OF + { + $$ = mm_strdup("of"); +} +| OFF + { + $$ = mm_strdup("off"); +} +| OIDS + { + $$ = mm_strdup("oids"); +} +| OPERATOR + { + $$ = mm_strdup("operator"); +} +| OPTION + { + $$ = mm_strdup("option"); +} +| OPTIONS + { + $$ = mm_strdup("options"); +} +| OWNED + { + $$ = mm_strdup("owned"); +} +| OWNER + { + $$ = mm_strdup("owner"); +} +| PARSER + { + $$ = mm_strdup("parser"); +} +| PARTIAL + { + $$ = mm_strdup("partial"); +} +| PARTITION + { + $$ = mm_strdup("partition"); +} +| PASSING + { + $$ = mm_strdup("passing"); +} +| PASSWORD + { + $$ = mm_strdup("password"); +} +| PLANS + { + $$ = mm_strdup("plans"); +} +| PRECEDING + { + $$ = mm_strdup("preceding"); +} +| PREPARE + { + $$ = mm_strdup("prepare"); +} +| PREPARED + { + $$ = mm_strdup("prepared"); +} +| PRESERVE + { + $$ = mm_strdup("preserve"); +} +| PRIOR + { + $$ = mm_strdup("prior"); +} +| PRIVILEGES + { + $$ = mm_strdup("privileges"); +} +| PROCEDURAL + { + $$ = mm_strdup("procedural"); +} +| PROCEDURE + { + $$ = mm_strdup("procedure"); +} +| QUOTE + { + $$ = mm_strdup("quote"); +} +| RANGE + { + $$ = mm_strdup("range"); +} +| READ + { + $$ = mm_strdup("read"); +} +| REASSIGN + { + $$ = mm_strdup("reassign"); +} +| RECHECK + { + $$ = mm_strdup("recheck"); +} +| RECURSIVE + { + $$ = mm_strdup("recursive"); +} +| REF + { + $$ = mm_strdup("ref"); +} +| REINDEX + { + $$ = mm_strdup("reindex"); +} +| RELATIVE_P + { + $$ = mm_strdup("relative"); +} +| RELEASE + { + $$ = mm_strdup("release"); +} +| RENAME + { + $$ = mm_strdup("rename"); +} +| REPEATABLE + { + $$ = mm_strdup("repeatable"); +} +| REPLACE + { + $$ = mm_strdup("replace"); +} +| REPLICA + { + $$ = mm_strdup("replica"); +} +| RESET + { + $$ = mm_strdup("reset"); +} +| RESTART + { + $$ = mm_strdup("restart"); +} +| RESTRICT + { + $$ = mm_strdup("restrict"); +} +| RETURNS + { + $$ = mm_strdup("returns"); +} +| REVOKE + { + $$ = mm_strdup("revoke"); +} +| ROLE + { + $$ = mm_strdup("role"); +} +| ROLLBACK + { + $$ = mm_strdup("rollback"); +} +| ROWS + { + $$ = mm_strdup("rows"); +} +| RULE + { + $$ = mm_strdup("rule"); +} +| SAVEPOINT + { + $$ = mm_strdup("savepoint"); +} +| SCHEMA + { + $$ = mm_strdup("schema"); +} +| SCROLL + { + $$ = mm_strdup("scroll"); +} +| SEARCH + { + $$ = mm_strdup("search"); +} +| SECURITY + { + $$ = mm_strdup("security"); +} +| SEQUENCE + { + $$ = mm_strdup("sequence"); +} +| SEQUENCES + { + $$ = mm_strdup("sequences"); +} +| SERIALIZABLE + { + $$ = mm_strdup("serializable"); +} +| SERVER + { + $$ = mm_strdup("server"); +} +| SESSION + { + $$ = mm_strdup("session"); +} +| SET + { + $$ = mm_strdup("set"); +} +| SHARE + { + $$ = mm_strdup("share"); +} +| SHOW + { + $$ = mm_strdup("show"); +} +| SIMPLE + { + $$ = mm_strdup("simple"); +} +| SNAPSHOT + { + $$ = mm_strdup("snapshot"); +} +| STABLE + { + $$ = mm_strdup("stable"); +} +| STANDALONE_P + { + $$ = mm_strdup("standalone"); +} +| START + { + $$ = mm_strdup("start"); +} +| STATEMENT + { + $$ = mm_strdup("statement"); +} +| STATISTICS + { + $$ = mm_strdup("statistics"); +} +| STDIN + { + $$ = mm_strdup("stdin"); +} +| STDOUT + { + $$ = mm_strdup("stdout"); +} +| STORAGE + { + $$ = mm_strdup("storage"); +} +| STRICT_P + { + $$ = mm_strdup("strict"); +} +| STRIP_P + { + $$ = mm_strdup("strip"); +} +| SYSID + { + $$ = mm_strdup("sysid"); +} +| SYSTEM_P + { + $$ = mm_strdup("system"); +} +| TABLES + { + $$ = mm_strdup("tables"); +} +| TABLESPACE + { + $$ = mm_strdup("tablespace"); +} +| TEMP + { + $$ = mm_strdup("temp"); +} +| TEMPLATE + { + $$ = mm_strdup("template"); +} +| TEMPORARY + { + $$ = mm_strdup("temporary"); +} +| TEXT_P + { + $$ = mm_strdup("text"); +} +| TRANSACTION + { + $$ = mm_strdup("transaction"); +} +| TRIGGER + { + $$ = mm_strdup("trigger"); +} +| TRUNCATE + { + $$ = mm_strdup("truncate"); +} +| TRUSTED + { + $$ = mm_strdup("trusted"); +} +| TYPE_P + { + $$ = mm_strdup("type"); +} +| TYPES_P + { + $$ = mm_strdup("types"); +} +| UNBOUNDED + { + $$ = mm_strdup("unbounded"); +} +| UNCOMMITTED + { + $$ = mm_strdup("uncommitted"); +} +| UNENCRYPTED + { + $$ = mm_strdup("unencrypted"); +} +| UNKNOWN + { + $$ = mm_strdup("unknown"); +} +| UNLISTEN + { + $$ = mm_strdup("unlisten"); +} +| UNLOGGED + { + $$ = mm_strdup("unlogged"); +} +| UNTIL + { + $$ = mm_strdup("until"); +} +| UPDATE + { + $$ = mm_strdup("update"); +} +| VACUUM + { + $$ = mm_strdup("vacuum"); +} +| VALID + { + $$ = mm_strdup("valid"); +} +| VALIDATE + { + $$ = mm_strdup("validate"); +} +| VALIDATOR + { + $$ = mm_strdup("validator"); +} +| VALUE_P + { + $$ = mm_strdup("value"); +} +| VARYING + { + $$ = mm_strdup("varying"); +} +| VERSION_P + { + $$ = mm_strdup("version"); +} +| VIEW + { + $$ = mm_strdup("view"); +} +| VOLATILE + { + $$ = mm_strdup("volatile"); +} +| WHITESPACE_P + { + $$ = mm_strdup("whitespace"); +} +| WITHOUT + { + $$ = mm_strdup("without"); +} +| WORK + { + $$ = mm_strdup("work"); +} +| WRAPPER + { + $$ = mm_strdup("wrapper"); +} +| WRITE + { + $$ = mm_strdup("write"); +} +| XML_P + { + $$ = mm_strdup("xml"); +} +| YES_P + { + $$ = mm_strdup("yes"); +} +| ZONE + { + $$ = mm_strdup("zone"); +} +; + + + col_name_keyword: + BETWEEN + { + $$ = mm_strdup("between"); +} +| BIGINT + { + $$ = mm_strdup("bigint"); +} +| BIT + { + $$ = mm_strdup("bit"); +} +| BOOLEAN_P + { + $$ = mm_strdup("boolean"); +} +| CHARACTER + { + $$ = mm_strdup("character"); +} +| COALESCE + { + $$ = mm_strdup("coalesce"); +} +| DEC + { + $$ = mm_strdup("dec"); +} +| DECIMAL_P + { + $$ = mm_strdup("decimal"); +} +| EXISTS + { + $$ = mm_strdup("exists"); +} +| EXTRACT + { + $$ = mm_strdup("extract"); +} +| FLOAT_P + { + $$ = mm_strdup("float"); +} +| GREATEST + { + $$ = mm_strdup("greatest"); +} +| INOUT + { + $$ = mm_strdup("inout"); +} +| INTEGER + { + $$ = mm_strdup("integer"); +} +| INTERVAL + { + $$ = mm_strdup("interval"); +} +| LEAST + { + $$ = mm_strdup("least"); +} +| NATIONAL + { + $$ = mm_strdup("national"); +} +| NCHAR + { + $$ = mm_strdup("nchar"); +} +| NONE + { + $$ = mm_strdup("none"); +} +| NULLIF + { + $$ = mm_strdup("nullif"); +} +| NUMERIC + { + $$ = mm_strdup("numeric"); +} +| OUT_P + { + $$ = mm_strdup("out"); +} +| OVERLAY + { + $$ = mm_strdup("overlay"); +} +| POSITION + { + $$ = mm_strdup("position"); +} +| PRECISION + { + $$ = mm_strdup("precision"); +} +| REAL + { + $$ = mm_strdup("real"); +} +| ROW + { + $$ = mm_strdup("row"); +} +| SETOF + { + $$ = mm_strdup("setof"); +} +| SMALLINT + { + $$ = mm_strdup("smallint"); +} +| SUBSTRING + { + $$ = mm_strdup("substring"); +} +| TIME + { + $$ = mm_strdup("time"); +} +| TIMESTAMP + { + $$ = mm_strdup("timestamp"); +} +| TREAT + { + $$ = mm_strdup("treat"); +} +| TRIM + { + $$ = mm_strdup("trim"); +} +| VARCHAR + { + $$ = mm_strdup("varchar"); +} +| XMLATTRIBUTES + { + $$ = mm_strdup("xmlattributes"); +} +| XMLCONCAT + { + $$ = mm_strdup("xmlconcat"); +} +| XMLELEMENT + { + $$ = mm_strdup("xmlelement"); +} +| XMLEXISTS + { + $$ = mm_strdup("xmlexists"); +} +| XMLFOREST + { + $$ = mm_strdup("xmlforest"); +} +| XMLPARSE + { + $$ = mm_strdup("xmlparse"); +} +| XMLPI + { + $$ = mm_strdup("xmlpi"); +} +| XMLROOT + { + $$ = mm_strdup("xmlroot"); +} +| XMLSERIALIZE + { + $$ = mm_strdup("xmlserialize"); +} +; + + + type_func_name_keyword: + AUTHORIZATION + { + $$ = mm_strdup("authorization"); +} +| BINARY + { + $$ = mm_strdup("binary"); +} +| COLLATION + { + $$ = mm_strdup("collation"); +} +| CONCURRENTLY + { + $$ = mm_strdup("concurrently"); +} +| CROSS + { + $$ = mm_strdup("cross"); +} +| CURRENT_SCHEMA + { + $$ = mm_strdup("current_schema"); +} +| FREEZE + { + $$ = mm_strdup("freeze"); +} +| FULL + { + $$ = mm_strdup("full"); +} +| ILIKE + { + $$ = mm_strdup("ilike"); +} +| INNER_P + { + $$ = mm_strdup("inner"); +} +| IS + { + $$ = mm_strdup("is"); +} +| ISNULL + { + $$ = mm_strdup("isnull"); +} +| JOIN + { + $$ = mm_strdup("join"); +} +| LEFT + { + $$ = mm_strdup("left"); +} +| LIKE + { + $$ = mm_strdup("like"); +} +| NATURAL + { + $$ = mm_strdup("natural"); +} +| NOTNULL + { + $$ = mm_strdup("notnull"); +} +| OUTER_P + { + $$ = mm_strdup("outer"); +} +| OVER + { + $$ = mm_strdup("over"); +} +| OVERLAPS + { + $$ = mm_strdup("overlaps"); +} +| RIGHT + { + $$ = mm_strdup("right"); +} +| SIMILAR + { + $$ = mm_strdup("similar"); +} +| VERBOSE + { + $$ = mm_strdup("verbose"); +} +; + + + reserved_keyword: + ALL + { + $$ = mm_strdup("all"); +} +| ANALYSE + { + $$ = mm_strdup("analyse"); +} +| ANALYZE + { + $$ = mm_strdup("analyze"); +} +| AND + { + $$ = mm_strdup("and"); +} +| ANY + { + $$ = mm_strdup("any"); +} +| ARRAY + { + $$ = mm_strdup("array"); +} +| AS + { + $$ = mm_strdup("as"); +} +| ASC + { + $$ = mm_strdup("asc"); +} +| ASYMMETRIC + { + $$ = mm_strdup("asymmetric"); +} +| BOTH + { + $$ = mm_strdup("both"); +} +| CASE + { + $$ = mm_strdup("case"); +} +| CAST + { + $$ = mm_strdup("cast"); +} +| CHECK + { + $$ = mm_strdup("check"); +} +| COLLATE + { + $$ = mm_strdup("collate"); +} +| COLUMN + { + $$ = mm_strdup("column"); +} +| CONSTRAINT + { + $$ = mm_strdup("constraint"); +} +| CREATE + { + $$ = mm_strdup("create"); +} +| CURRENT_CATALOG + { + $$ = mm_strdup("current_catalog"); +} +| CURRENT_DATE + { + $$ = mm_strdup("current_date"); +} +| CURRENT_ROLE + { + $$ = mm_strdup("current_role"); +} +| CURRENT_TIME + { + $$ = mm_strdup("current_time"); +} +| CURRENT_TIMESTAMP + { + $$ = mm_strdup("current_timestamp"); +} +| CURRENT_USER + { + $$ = mm_strdup("current_user"); +} +| DEFAULT + { + $$ = mm_strdup("default"); +} +| DEFERRABLE + { + $$ = mm_strdup("deferrable"); +} +| DESC + { + $$ = mm_strdup("desc"); +} +| DISTINCT + { + $$ = mm_strdup("distinct"); +} +| DO + { + $$ = mm_strdup("do"); +} +| ELSE + { + $$ = mm_strdup("else"); +} +| END_P + { + $$ = mm_strdup("end"); +} +| EXCEPT + { + $$ = mm_strdup("except"); +} +| FALSE_P + { + $$ = mm_strdup("false"); +} +| FETCH + { + $$ = mm_strdup("fetch"); +} +| FOR + { + $$ = mm_strdup("for"); +} +| FOREIGN + { + $$ = mm_strdup("foreign"); +} +| FROM + { + $$ = mm_strdup("from"); +} +| GRANT + { + $$ = mm_strdup("grant"); +} +| GROUP_P + { + $$ = mm_strdup("group"); +} +| HAVING + { + $$ = mm_strdup("having"); +} +| IN_P + { + $$ = mm_strdup("in"); +} +| INITIALLY + { + $$ = mm_strdup("initially"); +} +| INTERSECT + { + $$ = mm_strdup("intersect"); +} +| INTO + { + $$ = mm_strdup("into"); +} +| LEADING + { + $$ = mm_strdup("leading"); +} +| LIMIT + { + $$ = mm_strdup("limit"); +} +| LOCALTIME + { + $$ = mm_strdup("localtime"); +} +| LOCALTIMESTAMP + { + $$ = mm_strdup("localtimestamp"); +} +| NOT + { + $$ = mm_strdup("not"); +} +| NULL_P + { + $$ = mm_strdup("null"); +} +| OFFSET + { + $$ = mm_strdup("offset"); +} +| ON + { + $$ = mm_strdup("on"); +} +| ONLY + { + $$ = mm_strdup("only"); +} +| OR + { + $$ = mm_strdup("or"); +} +| ORDER + { + $$ = mm_strdup("order"); +} +| PLACING + { + $$ = mm_strdup("placing"); +} +| PRIMARY + { + $$ = mm_strdup("primary"); +} +| REFERENCES + { + $$ = mm_strdup("references"); +} +| RETURNING + { + $$ = mm_strdup("returning"); +} +| SELECT + { + $$ = mm_strdup("select"); +} +| SESSION_USER + { + $$ = mm_strdup("session_user"); +} +| SOME + { + $$ = mm_strdup("some"); +} +| SYMMETRIC + { + $$ = mm_strdup("symmetric"); +} +| TABLE + { + $$ = mm_strdup("table"); +} +| THEN + { + $$ = mm_strdup("then"); +} +| TRAILING + { + $$ = mm_strdup("trailing"); +} +| TRUE_P + { + $$ = mm_strdup("true"); +} +| UNIQUE + { + $$ = mm_strdup("unique"); +} +| USER + { + $$ = mm_strdup("user"); +} +| USING + { + $$ = mm_strdup("using"); +} +| VARIADIC + { + $$ = mm_strdup("variadic"); +} +| WHEN + { + $$ = mm_strdup("when"); +} +| WHERE + { + $$ = mm_strdup("where"); +} +| WINDOW + { + $$ = mm_strdup("window"); +} +| WITH + { + $$ = mm_strdup("with"); +} +; + + +/* trailer */ +/* src/interfaces/ecpg/preproc/ecpg.trailer */ + +statements: /*EMPTY*/ + | statements statement + ; + +statement: ecpgstart at stmt ';' { connection = NULL; } + | ecpgstart stmt ';' + | ecpgstart ECPGVarDeclaration + { + fprintf(yyout, "%s", $2); + free($2); + output_line_number(); + } + | ECPGDeclaration + | c_thing { fprintf(yyout, "%s", $1); free($1); } + | CPP_LINE { fprintf(yyout, "%s", $1); free($1); } + | '{' { braces_open++; fputs("{", yyout); } + | '}' + { + remove_typedefs(braces_open); + remove_variables(braces_open--); + if (braces_open == 0) + { + free(current_function); + current_function = NULL; + } + fputs("}", yyout); + } + ; + +CreateAsStmt: CREATE OptTemp TABLE create_as_target AS {FoundInto = 0;} SelectStmt opt_with_data + { + if (FoundInto == 1) + mmerror(PARSE_ERROR, ET_ERROR, "CREATE TABLE AS cannot specify INTO"); + + $$ = cat_str(6, mm_strdup("create"), $2, mm_strdup("table"), $4, mm_strdup("as"), $7); + } + ; + +at: AT connection_object + { + connection = $2; + /* + * Do we have a variable as connection target? Remove the variable + * from the variable list or else it will be used twice. + */ + if (argsinsert != NULL) + argsinsert = NULL; + } + ; + +/* + * the exec sql connect statement: connect to the given database + */ +ECPGConnect: SQL_CONNECT TO connection_target opt_connection_name opt_user + { $$ = cat_str(5, $3, mm_strdup(","), $5, mm_strdup(","), $4); } + | SQL_CONNECT TO DEFAULT + { $$ = mm_strdup("NULL, NULL, NULL, \"DEFAULT\""); } + /* also allow ORACLE syntax */ + | SQL_CONNECT ora_user + { $$ = cat_str(3, mm_strdup("NULL,"), $2, mm_strdup(", NULL")); } + | DATABASE connection_target + { $$ = cat2_str($2, mm_strdup(", NULL, NULL, NULL")); } + ; + +connection_target: opt_database_name opt_server opt_port + { + /* old style: dbname[@server][:port] */ + if (strlen($2) > 0 && *($2) != '@') + mmerror(PARSE_ERROR, ET_ERROR, "expected \"@\", found \"%s\"", $2); + + /* C strings need to be handled differently */ + if ($1[0] == '\"') + $$ = $1; + else + $$ = make3_str(mm_strdup("\""), make3_str($1, $2, $3), mm_strdup("\"")); + } + | db_prefix ':' server opt_port '/' opt_database_name opt_options + { + /* new style: :postgresql://server[:port][/dbname] */ + if (strncmp($1, "unix:postgresql", strlen("unix:postgresql")) != 0 && strncmp($1, "tcp:postgresql", strlen("tcp:postgresql")) != 0) + mmerror(PARSE_ERROR, ET_ERROR, "only protocols \"tcp\" and \"unix\" and database type \"postgresql\" are supported"); + + if (strncmp($3, "//", strlen("//")) != 0) + mmerror(PARSE_ERROR, ET_ERROR, "expected \"://\", found \"%s\"", $3); + + if (strncmp($1, "unix", strlen("unix")) == 0 && + strncmp($3 + strlen("//"), "localhost", strlen("localhost")) != 0 && + strncmp($3 + strlen("//"), "127.0.0.1", strlen("127.0.0.1")) != 0) + mmerror(PARSE_ERROR, ET_ERROR, "Unix-domain sockets only work on \"localhost\" but not on \"%s\"", $3 + strlen("//")); + + $$ = make3_str(make3_str(mm_strdup("\""), $1, mm_strdup(":")), $3, make3_str(make3_str($4, mm_strdup("/"), $6), $7, mm_strdup("\""))); + } + | char_variable + { + $$ = $1; + } + | ecpg_sconst + { + /* We can only process double quoted strings not single quotes ones, + * so we change the quotes. + * Note, that the rule for ecpg_sconst adds these single quotes. */ + $1[0] = '\"'; + $1[strlen($1)-1] = '\"'; + $$ = $1; + } + ; + +opt_database_name: database_name { $$ = $1; } + | /*EMPTY*/ { $$ = EMPTY; } + ; + +db_prefix: ecpg_ident cvariable + { + if (strcmp($2, "postgresql") != 0 && strcmp($2, "postgres") != 0) + mmerror(PARSE_ERROR, ET_ERROR, "expected \"postgresql\", found \"%s\"", $2); + + if (strcmp($1, "tcp") != 0 && strcmp($1, "unix") != 0) + mmerror(PARSE_ERROR, ET_ERROR, "invalid connection type: %s", $1); + + $$ = make3_str($1, mm_strdup(":"), $2); + } + ; + +server: Op server_name + { + if (strcmp($1, "@") != 0 && strcmp($1, "//") != 0) + mmerror(PARSE_ERROR, ET_ERROR, "expected \"@\" or \"://\", found \"%s\"", $1); + + $$ = make2_str($1, $2); + } + ; + +opt_server: server { $$ = $1; } + | /*EMPTY*/ { $$ = EMPTY; } + ; + +server_name: ColId { $$ = $1; } + | ColId '.' server_name { $$ = make3_str($1, mm_strdup("."), $3); } + | IP { $$ = make_name(); } + ; + +opt_port: ':' Iconst { $$ = make2_str(mm_strdup(":"), $2); } + | /*EMPTY*/ { $$ = EMPTY; } + ; + +opt_connection_name: AS connection_object { $$ = $2; } + | /*EMPTY*/ { $$ = mm_strdup("NULL"); } + ; + +opt_user: USER ora_user { $$ = $2; } + | /*EMPTY*/ { $$ = mm_strdup("NULL, NULL"); } + ; + +ora_user: user_name + { $$ = cat2_str($1, mm_strdup(", NULL")); } + | user_name '/' user_name + { $$ = cat_str(3, $1, mm_strdup(","), $3); } + | user_name SQL_IDENTIFIED BY user_name + { $$ = cat_str(3, $1, mm_strdup(","), $4); } + | user_name USING user_name + { $$ = cat_str(3, $1, mm_strdup(","), $3); } + ; + +user_name: RoleId + { + if ($1[0] == '\"') + $$ = $1; + else + $$ = make3_str(mm_strdup("\""), $1, mm_strdup("\"")); + } + | ecpg_sconst + { + if ($1[0] == '\"') + $$ = $1; + else + $$ = make3_str(mm_strdup("\""), $1, mm_strdup("\"")); + } + | civar + { + enum ECPGttype type = argsinsert->variable->type->type; + + /* if array see what's inside */ + if (type == ECPGt_array) + type = argsinsert->variable->type->u.element->type; + + /* handle varchars */ + if (type == ECPGt_varchar) + $$ = make2_str(mm_strdup(argsinsert->variable->name), mm_strdup(".arr")); + else + $$ = mm_strdup(argsinsert->variable->name); + } + ; + +char_variable: cvariable + { + /* check if we have a string variable */ + struct variable *p = find_variable($1); + enum ECPGttype type = p->type->type; + + /* If we have just one character this is not a string */ + if (atol(p->type->size) == 1) + mmerror(PARSE_ERROR, ET_ERROR, "invalid data type"); + else + { + /* if array see what's inside */ + if (type == ECPGt_array) + type = p->type->u.element->type; + + switch (type) + { + case ECPGt_char: + case ECPGt_unsigned_char: + case ECPGt_string: + $$ = $1; + break; + case ECPGt_varchar: + $$ = make2_str($1, mm_strdup(".arr")); + break; + default: + mmerror(PARSE_ERROR, ET_ERROR, "invalid data type"); + $$ = $1; + break; + } + } + } + ; + +opt_options: Op connect_options + { + if (strlen($1) == 0) + mmerror(PARSE_ERROR, ET_ERROR, "incomplete statement"); + + if (strcmp($1, "?") != 0) + mmerror(PARSE_ERROR, ET_ERROR, "unrecognized token \"%s\"", $1); + + $$ = make2_str(mm_strdup("?"), $2); + } + | /*EMPTY*/ { $$ = EMPTY; } + ; + +connect_options: ColId opt_opt_value + { + $$ = make2_str($1, $2); + } + | ColId opt_opt_value Op connect_options + { + if (strlen($3) == 0) + mmerror(PARSE_ERROR, ET_ERROR, "incomplete statement"); + + if (strcmp($3, "&") != 0) + mmerror(PARSE_ERROR, ET_ERROR, "unrecognized token \"%s\"", $3); + + $$ = cat_str(3, make2_str($1, $2), $3, $4); + } + ; + +opt_opt_value: /*EMPTY*/ + { $$ = EMPTY; } + | '=' Iconst + { $$ = make2_str(mm_strdup("="), $2); } + | '=' ecpg_ident + { $$ = make2_str(mm_strdup("="), $2); } + | '=' civar + { $$ = make2_str(mm_strdup("="), $2); } + ; + +prepared_name: name + { + if ($1[0] == '\"' && $1[strlen($1)-1] == '\"') /* already quoted? */ + $$ = $1; + else /* not quoted => convert to lowercase */ + { + size_t i; + + for (i = 0; i< strlen($1); i++) + $1[i] = tolower((unsigned char) $1[i]); + + $$ = make3_str(mm_strdup("\""), $1, mm_strdup("\"")); + } + } + | char_variable { $$ = $1; } + ; + +/* + * Declare a prepared cursor. The syntax is different from the standard + * declare statement, so we create a new rule. + */ +ECPGCursorStmt: DECLARE cursor_name cursor_options CURSOR opt_hold FOR prepared_name + { + struct cursor *ptr, *this; + char *cursor_marker = $2[0] == ':' ? mm_strdup("$0") : mm_strdup($2); + int (* strcmp_fn)(const char *, const char *) = ($2[0] == ':' ? strcmp : pg_strcasecmp); + struct variable *thisquery = (struct variable *)mm_alloc(sizeof(struct variable)); + const char *con = connection ? connection : "NULL"; + char *comment; + + for (ptr = cur; ptr != NULL; ptr = ptr->next) + { + if (strcmp_fn($2, ptr->name) == 0) + { + /* re-definition is a bug */ + if ($2[0] == ':') + mmerror(PARSE_ERROR, ET_ERROR, "using variable \"%s\" in different declare statements is not supported", $2+1); + else + mmerror(PARSE_ERROR, ET_ERROR, "cursor \"%s\" is already defined", $2); + } + } + + this = (struct cursor *) mm_alloc(sizeof(struct cursor)); + + /* initial definition */ + this->next = cur; + this->name = $2; + this->function = (current_function ? mm_strdup(current_function) : NULL); + this->connection = connection; + this->command = cat_str(6, mm_strdup("declare"), cursor_marker, $3, mm_strdup("cursor"), $5, mm_strdup("for $1")); + this->argsresult = NULL; + this->argsresult_oos = NULL; + + thisquery->type = &ecpg_query; + thisquery->brace_level = 0; + thisquery->next = NULL; + thisquery->name = (char *) mm_alloc(sizeof("ECPGprepared_statement(, , __LINE__)") + strlen(con) + strlen($7)); + sprintf(thisquery->name, "ECPGprepared_statement(%s, %s, __LINE__)", con, $7); + + this->argsinsert = NULL; + this->argsinsert_oos = NULL; + if ($2[0] == ':') + { + struct variable *var = find_variable($2 + 1); + remove_variable_from_list(&argsinsert, var); + add_variable_to_head(&(this->argsinsert), var, &no_indicator); + } + add_variable_to_head(&(this->argsinsert), thisquery, &no_indicator); + + cur = this; + + comment = cat_str(3, mm_strdup("/*"), mm_strdup(this->command), mm_strdup("*/")); + + if ((braces_open > 0) && INFORMIX_MODE) /* we're in a function */ + $$ = cat_str(3, adjust_outofscope_cursor_vars(this), + mm_strdup("ECPG_informix_reset_sqlca();"), + comment); + else + $$ = cat2_str(adjust_outofscope_cursor_vars(this), comment); + } + ; + +ECPGExecuteImmediateStmt: EXECUTE IMMEDIATE execstring + { + /* execute immediate means prepare the statement and + * immediately execute it */ + $$ = $3; + }; +/* + * variable decalartion outside exec sql declare block + */ +ECPGVarDeclaration: single_vt_declaration; + +single_vt_declaration: type_declaration { $$ = $1; } + | var_declaration { $$ = $1; } + ; + +precision: NumericOnly { $$ = $1; }; + +opt_scale: ',' NumericOnly { $$ = $2; } + | /* EMPTY */ { $$ = EMPTY; } + ; + +ecpg_interval: opt_interval { $$ = $1; } + | YEAR_P TO MINUTE_P { $$ = mm_strdup("year to minute"); } + | YEAR_P TO SECOND_P { $$ = mm_strdup("year to second"); } + | DAY_P TO DAY_P { $$ = mm_strdup("day to day"); } + | MONTH_P TO MONTH_P { $$ = mm_strdup("month to month"); } + ; + +/* + * variable declaration inside exec sql declare block + */ +ECPGDeclaration: sql_startdeclare + { fputs("/* exec sql begin declare section */", yyout); } + var_type_declarations sql_enddeclare + { + fprintf(yyout, "%s/* exec sql end declare section */", $3); + free($3); + output_line_number(); + } + ; + +sql_startdeclare: ecpgstart BEGIN_P DECLARE SQL_SECTION ';' {}; + +sql_enddeclare: ecpgstart END_P DECLARE SQL_SECTION ';' {}; + +var_type_declarations: /*EMPTY*/ { $$ = EMPTY; } + | vt_declarations { $$ = $1; } + ; + +vt_declarations: single_vt_declaration { $$ = $1; } + | CPP_LINE { $$ = $1; } + | vt_declarations single_vt_declaration { $$ = cat2_str($1, $2); } + | vt_declarations CPP_LINE { $$ = cat2_str($1, $2); } + ; + +variable_declarations: var_declaration { $$ = $1; } + | variable_declarations var_declaration { $$ = cat2_str($1, $2); } + ; + +type_declaration: S_TYPEDEF + { + /* reset this variable so we see if there was */ + /* an initializer specified */ + initializer = 0; + } + var_type opt_pointer ECPGColLabelCommon opt_array_bounds ';' + { + add_typedef($5, $6.index1, $6.index2, $3.type_enum, $3.type_dimension, $3.type_index, initializer, *$4 ? 1 : 0); + + fprintf(yyout, "typedef %s %s %s %s;\n", $3.type_str, *$4 ? "*" : "", $5, $6.str); + output_line_number(); + $$ = mm_strdup(""); + }; + +var_declaration: storage_declaration + var_type + { + actual_type[struct_level].type_enum = $2.type_enum; + actual_type[struct_level].type_str = $2.type_str; + actual_type[struct_level].type_dimension = $2.type_dimension; + actual_type[struct_level].type_index = $2.type_index; + actual_type[struct_level].type_sizeof = $2.type_sizeof; + + actual_startline[struct_level] = hashline_number(); + } + variable_list ';' + { + $$ = cat_str(5, actual_startline[struct_level], $1, $2.type_str, $4, mm_strdup(";\n")); + } + | var_type + { + actual_type[struct_level].type_enum = $1.type_enum; + actual_type[struct_level].type_str = $1.type_str; + actual_type[struct_level].type_dimension = $1.type_dimension; + actual_type[struct_level].type_index = $1.type_index; + actual_type[struct_level].type_sizeof = $1.type_sizeof; + + actual_startline[struct_level] = hashline_number(); + } + variable_list ';' + { + $$ = cat_str(4, actual_startline[struct_level], $1.type_str, $3, mm_strdup(";\n")); + } + | struct_union_type_with_symbol ';' + { + $$ = cat2_str($1, mm_strdup(";")); + } + ; + +opt_bit_field: ':' Iconst { $$ =cat2_str(mm_strdup(":"), $2); } + | /* EMPTY */ { $$ = EMPTY; } + ; + +storage_declaration: storage_clause storage_modifier + {$$ = cat2_str ($1, $2); } + | storage_clause {$$ = $1; } + | storage_modifier {$$ = $1; } + ; + +storage_clause : S_EXTERN { $$ = mm_strdup("extern"); } + | S_STATIC { $$ = mm_strdup("static"); } + | S_REGISTER { $$ = mm_strdup("register"); } + | S_AUTO { $$ = mm_strdup("auto"); } + ; + +storage_modifier : S_CONST { $$ = mm_strdup("const"); } + | S_VOLATILE { $$ = mm_strdup("volatile"); } + ; + +var_type: simple_type + { + $$.type_enum = $1; + $$.type_str = mm_strdup(ecpg_type_name($1)); + $$.type_dimension = mm_strdup("-1"); + $$.type_index = mm_strdup("-1"); + $$.type_sizeof = NULL; + } + | struct_union_type + { + $$.type_str = $1; + $$.type_dimension = mm_strdup("-1"); + $$.type_index = mm_strdup("-1"); + + if (strncmp($1, "struct", sizeof("struct")-1) == 0) + { + $$.type_enum = ECPGt_struct; + $$.type_sizeof = ECPGstruct_sizeof; + } + else + { + $$.type_enum = ECPGt_union; + $$.type_sizeof = NULL; + } + } + | enum_type + { + $$.type_str = $1; + $$.type_enum = ECPGt_int; + $$.type_dimension = mm_strdup("-1"); + $$.type_index = mm_strdup("-1"); + $$.type_sizeof = NULL; + } + | ECPGColLabelCommon '(' precision opt_scale ')' + { + if (strcmp($1, "numeric") == 0) + { + $$.type_enum = ECPGt_numeric; + $$.type_str = mm_strdup("numeric"); + } + else if (strcmp($1, "decimal") == 0) + { + $$.type_enum = ECPGt_decimal; + $$.type_str = mm_strdup("decimal"); + } + else + { + mmerror(PARSE_ERROR, ET_ERROR, "only data types numeric and decimal have precision/scale argument"); + $$.type_enum = ECPGt_numeric; + $$.type_str = mm_strdup("numeric"); + } + + $$.type_dimension = mm_strdup("-1"); + $$.type_index = mm_strdup("-1"); + $$.type_sizeof = NULL; + } + | ECPGColLabelCommon ecpg_interval + { + if (strlen($2) != 0 && strcmp ($1, "datetime") != 0 && strcmp ($1, "interval") != 0) + mmerror (PARSE_ERROR, ET_ERROR, "interval specification not allowed here"); + + /* + * Check for type names that the SQL grammar treats as + * unreserved keywords + */ + if (strcmp($1, "varchar") == 0) + { + $$.type_enum = ECPGt_varchar; + $$.type_str = EMPTY; /*mm_strdup("varchar");*/ + $$.type_dimension = mm_strdup("-1"); + $$.type_index = mm_strdup("-1"); + $$.type_sizeof = NULL; + } + else if (strcmp($1, "float") == 0) + { + $$.type_enum = ECPGt_float; + $$.type_str = mm_strdup("float"); + $$.type_dimension = mm_strdup("-1"); + $$.type_index = mm_strdup("-1"); + $$.type_sizeof = NULL; + } + else if (strcmp($1, "double") == 0) + { + $$.type_enum = ECPGt_double; + $$.type_str = mm_strdup("double"); + $$.type_dimension = mm_strdup("-1"); + $$.type_index = mm_strdup("-1"); + $$.type_sizeof = NULL; + } + else if (strcmp($1, "numeric") == 0) + { + $$.type_enum = ECPGt_numeric; + $$.type_str = mm_strdup("numeric"); + $$.type_dimension = mm_strdup("-1"); + $$.type_index = mm_strdup("-1"); + $$.type_sizeof = NULL; + } + else if (strcmp($1, "decimal") == 0) + { + $$.type_enum = ECPGt_decimal; + $$.type_str = mm_strdup("decimal"); + $$.type_dimension = mm_strdup("-1"); + $$.type_index = mm_strdup("-1"); + $$.type_sizeof = NULL; + } + else if (strcmp($1, "date") == 0) + { + $$.type_enum = ECPGt_date; + $$.type_str = mm_strdup("date"); + $$.type_dimension = mm_strdup("-1"); + $$.type_index = mm_strdup("-1"); + $$.type_sizeof = NULL; + } + else if (strcmp($1, "timestamp") == 0) + { + $$.type_enum = ECPGt_timestamp; + $$.type_str = mm_strdup("timestamp"); + $$.type_dimension = mm_strdup("-1"); + $$.type_index = mm_strdup("-1"); + $$.type_sizeof = NULL; + } + else if (strcmp($1, "interval") == 0) + { + $$.type_enum = ECPGt_interval; + $$.type_str = mm_strdup("interval"); + $$.type_dimension = mm_strdup("-1"); + $$.type_index = mm_strdup("-1"); + $$.type_sizeof = NULL; + } + else if (strcmp($1, "datetime") == 0) + { + $$.type_enum = ECPGt_timestamp; + $$.type_str = mm_strdup("timestamp"); + $$.type_dimension = mm_strdup("-1"); + $$.type_index = mm_strdup("-1"); + $$.type_sizeof = NULL; + } + else if ((strcmp($1, "string") == 0) && INFORMIX_MODE) + { + $$.type_enum = ECPGt_string; + $$.type_str = mm_strdup("char"); + $$.type_dimension = mm_strdup("-1"); + $$.type_index = mm_strdup("-1"); + $$.type_sizeof = NULL; + } + else + { + /* this is for typedef'ed types */ + struct typedefs *this = get_typedef($1); + + $$.type_str = (this->type->type_enum == ECPGt_varchar) ? EMPTY : mm_strdup(this->name); + $$.type_enum = this->type->type_enum; + $$.type_dimension = this->type->type_dimension; + $$.type_index = this->type->type_index; + if (this->type->type_sizeof && strlen(this->type->type_sizeof) != 0) + $$.type_sizeof = this->type->type_sizeof; + else + $$.type_sizeof = cat_str(3, mm_strdup("sizeof("), mm_strdup(this->name), mm_strdup(")")); + + struct_member_list[struct_level] = ECPGstruct_member_dup(this->struct_member_list); + } + } + | s_struct_union_symbol + { + /* this is for named structs/unions */ + char *name; + struct typedefs *this; + bool forward = (forward_name != NULL && strcmp($1.symbol, forward_name) == 0 && strcmp($1.su, "struct") == 0); + + name = cat2_str($1.su, $1.symbol); + /* Do we have a forward definition? */ + if (!forward) + { + /* No */ + + this = get_typedef(name); + $$.type_str = mm_strdup(this->name); + $$.type_enum = this->type->type_enum; + $$.type_dimension = this->type->type_dimension; + $$.type_index = this->type->type_index; + $$.type_sizeof = this->type->type_sizeof; + struct_member_list[struct_level] = ECPGstruct_member_dup(this->struct_member_list); + free(name); + } + else + { + $$.type_str = name; + $$.type_enum = ECPGt_long; + $$.type_dimension = mm_strdup("-1"); + $$.type_index = mm_strdup("-1"); + $$.type_sizeof = mm_strdup(""); + struct_member_list[struct_level] = NULL; + } + } + ; + +enum_type: ENUM_P symbol enum_definition + { $$ = cat_str(3, mm_strdup("enum"), $2, $3); } + | ENUM_P enum_definition + { $$ = cat2_str(mm_strdup("enum"), $2); } + | ENUM_P symbol + { $$ = cat2_str(mm_strdup("enum"), $2); } + ; + +enum_definition: '{' c_list '}' + { $$ = cat_str(3, mm_strdup("{"), $2, mm_strdup("}")); }; + +struct_union_type_with_symbol: s_struct_union_symbol + { + struct_member_list[struct_level++] = NULL; + if (struct_level >= STRUCT_DEPTH) + mmerror(PARSE_ERROR, ET_ERROR, "too many levels in nested structure/union definition"); + forward_name = mm_strdup($1.symbol); + } + '{' variable_declarations '}' + { + struct typedefs *ptr, *this; + struct this_type su_type; + + ECPGfree_struct_member(struct_member_list[struct_level]); + struct_member_list[struct_level] = NULL; + struct_level--; + if (strncmp($1.su, "struct", sizeof("struct")-1) == 0) + su_type.type_enum = ECPGt_struct; + else + su_type.type_enum = ECPGt_union; + su_type.type_str = cat2_str($1.su, $1.symbol); + free(forward_name); + forward_name = NULL; + + /* This is essantially a typedef but needs the keyword struct/union as well. + * So we create the typedef for each struct definition with symbol */ + for (ptr = types; ptr != NULL; ptr = ptr->next) + { + if (strcmp(su_type.type_str, ptr->name) == 0) + /* re-definition is a bug */ + mmerror(PARSE_ERROR, ET_ERROR, "type \"%s\" is already defined", su_type.type_str); + } + + this = (struct typedefs *) mm_alloc(sizeof(struct typedefs)); + + /* initial definition */ + this->next = types; + this->name = mm_strdup(su_type.type_str); + this->brace_level = braces_open; + this->type = (struct this_type *) mm_alloc(sizeof(struct this_type)); + this->type->type_enum = su_type.type_enum; + this->type->type_str = mm_strdup(su_type.type_str); + this->type->type_dimension = mm_strdup("-1"); /* dimension of array */ + this->type->type_index = mm_strdup("-1"); /* length of string */ + this->type->type_sizeof = ECPGstruct_sizeof; + this->struct_member_list = struct_member_list[struct_level]; + + types = this; + $$ = cat_str(4, su_type.type_str, mm_strdup("{"), $4, mm_strdup("}")); + } + ; + +struct_union_type: struct_union_type_with_symbol { $$ = $1; } + | s_struct_union + { + struct_member_list[struct_level++] = NULL; + if (struct_level >= STRUCT_DEPTH) + mmerror(PARSE_ERROR, ET_ERROR, "too many levels in nested structure/union definition"); + } + '{' variable_declarations '}' + { + ECPGfree_struct_member(struct_member_list[struct_level]); + struct_member_list[struct_level] = NULL; + struct_level--; + $$ = cat_str(4, $1, mm_strdup("{"), $4, mm_strdup("}")); + } + ; + +s_struct_union_symbol: SQL_STRUCT symbol + { + $$.su = mm_strdup("struct"); + $$.symbol = $2; + ECPGstruct_sizeof = cat_str(3, mm_strdup("sizeof("), cat2_str(mm_strdup($$.su), mm_strdup($$.symbol)), mm_strdup(")")); + } + | UNION symbol + { + $$.su = mm_strdup("union"); + $$.symbol = $2; + } + ; + +s_struct_union: SQL_STRUCT + { + ECPGstruct_sizeof = mm_strdup(""); /* This must not be NULL to distinguish from simple types. */ + $$ = mm_strdup("struct"); + } + | UNION + { + $$ = mm_strdup("union"); + } + ; + +simple_type: unsigned_type { $$=$1; } + | opt_signed signed_type { $$=$2; } + ; + +unsigned_type: SQL_UNSIGNED SQL_SHORT { $$ = ECPGt_unsigned_short; } + | SQL_UNSIGNED SQL_SHORT INT_P { $$ = ECPGt_unsigned_short; } + | SQL_UNSIGNED { $$ = ECPGt_unsigned_int; } + | SQL_UNSIGNED INT_P { $$ = ECPGt_unsigned_int; } + | SQL_UNSIGNED SQL_LONG { $$ = ECPGt_unsigned_long; } + | SQL_UNSIGNED SQL_LONG INT_P { $$ = ECPGt_unsigned_long; } + | SQL_UNSIGNED SQL_LONG SQL_LONG + { +#ifdef HAVE_LONG_LONG_INT + $$ = ECPGt_unsigned_long_long; +#else + $$ = ECPGt_unsigned_long; +#endif + } + | SQL_UNSIGNED SQL_LONG SQL_LONG INT_P + { +#ifdef HAVE_LONG_LONG_INT + $$ = ECPGt_unsigned_long_long; +#else + $$ = ECPGt_unsigned_long; +#endif + } + | SQL_UNSIGNED CHAR_P { $$ = ECPGt_unsigned_char; } + ; + +signed_type: SQL_SHORT { $$ = ECPGt_short; } + | SQL_SHORT INT_P { $$ = ECPGt_short; } + | INT_P { $$ = ECPGt_int; } + | SQL_LONG { $$ = ECPGt_long; } + | SQL_LONG INT_P { $$ = ECPGt_long; } + | SQL_LONG SQL_LONG + { +#ifdef HAVE_LONG_LONG_INT + $$ = ECPGt_long_long; +#else + $$ = ECPGt_long; +#endif + } + | SQL_LONG SQL_LONG INT_P + { +#ifdef HAVE_LONG_LONG_INT + $$ = ECPGt_long_long; +#else + $$ = ECPGt_long; +#endif + } + | SQL_BOOL { $$ = ECPGt_bool; } + | CHAR_P { $$ = ECPGt_char; } + | DOUBLE_P { $$ = ECPGt_double; } + ; + +opt_signed: SQL_SIGNED + | /* EMPTY */ + ; + +variable_list: variable + { $$ = $1; } + | variable_list ',' variable + { $$ = cat_str(3, $1, mm_strdup(","), $3); } + ; + +variable: opt_pointer ECPGColLabel opt_array_bounds opt_bit_field opt_initializer + { + struct ECPGtype * type; + char *dimension = $3.index1; /* dimension of array */ + char *length = $3.index2; /* length of string */ + char *dim_str; + char *vcn; + + adjust_array(actual_type[struct_level].type_enum, &dimension, &length, actual_type[struct_level].type_dimension, actual_type[struct_level].type_index, strlen($1), false); + + switch (actual_type[struct_level].type_enum) + { + case ECPGt_struct: + case ECPGt_union: + if (atoi(dimension) < 0) + type = ECPGmake_struct_type(struct_member_list[struct_level], actual_type[struct_level].type_enum, actual_type[struct_level].type_str, actual_type[struct_level].type_sizeof); + else + type = ECPGmake_array_type(ECPGmake_struct_type(struct_member_list[struct_level], actual_type[struct_level].type_enum, actual_type[struct_level].type_str, actual_type[struct_level].type_sizeof), dimension); + + $$ = cat_str(5, $1, mm_strdup($2), $3.str, $4, $5); + break; + + case ECPGt_varchar: + if (atoi(dimension) < 0) + type = ECPGmake_simple_type(actual_type[struct_level].type_enum, length, varchar_counter); + else + type = ECPGmake_array_type(ECPGmake_simple_type(actual_type[struct_level].type_enum, length, varchar_counter), dimension); + + if (strcmp(dimension, "0") == 0 || abs(atoi(dimension)) == 1) + dim_str=mm_strdup(""); + else + dim_str=cat_str(3, mm_strdup("["), mm_strdup(dimension), mm_strdup("]")); + /* cannot check for atoi <= 0 because a defined constant will yield 0 here as well */ + if (atoi(length) < 0 || strcmp(length, "0") == 0) + mmerror(PARSE_ERROR, ET_ERROR, "pointers to varchar are not implemented"); + + /* make sure varchar struct name is unique by adding a unique counter to its definition */ + vcn = (char *) mm_alloc(sizeof(int) * CHAR_BIT * 10 / 3); + sprintf(vcn, "%d", varchar_counter); + if (strcmp(dimension, "0") == 0) + $$ = cat_str(7, make2_str(mm_strdup(" struct varchar_"), vcn), mm_strdup(" { int len; char arr["), mm_strdup(length), mm_strdup("]; } *"), mm_strdup($2), $4, $5); + else + $$ = cat_str(8, make2_str(mm_strdup(" struct varchar_"), vcn), mm_strdup(" { int len; char arr["), mm_strdup(length), mm_strdup("]; } "), mm_strdup($2), dim_str, $4, $5); + varchar_counter++; + break; + + case ECPGt_char: + case ECPGt_unsigned_char: + case ECPGt_string: + if (atoi(dimension) == -1) + { + int i = strlen($5); + + if (atoi(length) == -1 && i > 0) /* char [] = "string" */ + { + /* if we have an initializer but no string size set, let's use the initializer's length */ + free(length); + length = mm_alloc(i+sizeof("sizeof()")); + sprintf(length, "sizeof(%s)", $5+2); + } + type = ECPGmake_simple_type(actual_type[struct_level].type_enum, length, 0); + } + else + type = ECPGmake_array_type(ECPGmake_simple_type(actual_type[struct_level].type_enum, length, 0), dimension); + + $$ = cat_str(5, $1, mm_strdup($2), $3.str, $4, $5); + break; + + default: + if (atoi(dimension) < 0) + type = ECPGmake_simple_type(actual_type[struct_level].type_enum, mm_strdup("1"), 0); + else + type = ECPGmake_array_type(ECPGmake_simple_type(actual_type[struct_level].type_enum, mm_strdup("1"), 0), dimension); + + $$ = cat_str(5, $1, mm_strdup($2), $3.str, $4, $5); + break; + } + + if (struct_level == 0) + new_variable($2, type, braces_open); + else + ECPGmake_struct_member($2, type, &(struct_member_list[struct_level - 1])); + + free($2); + } + ; + +opt_initializer: /*EMPTY*/ + { $$ = EMPTY; } + | '=' c_term + { + initializer = 1; + $$ = cat2_str(mm_strdup("="), $2); + } + ; + +opt_pointer: /*EMPTY*/ { $$ = EMPTY; } + | '*' { $$ = mm_strdup("*"); } + | '*' '*' { $$ = mm_strdup("**"); } + ; + +/* + * We try to simulate the correct DECLARE syntax here so we get dynamic SQL + */ +ECPGDeclare: DECLARE STATEMENT ecpg_ident + { + /* this is only supported for compatibility */ + $$ = cat_str(3, mm_strdup("/* declare statement"), $3, mm_strdup("*/")); + } + ; +/* + * the exec sql disconnect statement: disconnect from the given database + */ +ECPGDisconnect: SQL_DISCONNECT dis_name { $$ = $2; } + ; + +dis_name: connection_object { $$ = $1; } + | CURRENT_P { $$ = mm_strdup("\"CURRENT\""); } + | ALL { $$ = mm_strdup("\"ALL\""); } + | /* EMPTY */ { $$ = mm_strdup("\"CURRENT\""); } + ; + +connection_object: database_name { $$ = make3_str(mm_strdup("\""), $1, mm_strdup("\"")); } + | DEFAULT { $$ = mm_strdup("\"DEFAULT\""); } + | char_variable { $$ = $1; } + ; + +execstring: char_variable + { $$ = $1; } + | CSTRING + { $$ = make3_str(mm_strdup("\""), $1, mm_strdup("\"")); } + ; + +/* + * the exec sql free command to deallocate a previously + * prepared statement + */ +ECPGFree: SQL_FREE cursor_name { $$ = $2; } + | SQL_FREE ALL { $$ = mm_strdup("all"); } + ; + +/* + * open is an open cursor, at the moment this has to be removed + */ +ECPGOpen: SQL_OPEN cursor_name opt_ecpg_using + { + if ($2[0] == ':') + remove_variable_from_list(&argsinsert, find_variable($2 + 1)); + $$ = $2; + } + ; + +opt_ecpg_using: /*EMPTY*/ { $$ = EMPTY; } + | ecpg_using { $$ = $1; } + ; + +ecpg_using: USING using_list { $$ = EMPTY; } + | using_descriptor { $$ = $1; } + ; + +using_descriptor: USING SQL_SQL SQL_DESCRIPTOR quoted_ident_stringvar + { + add_variable_to_head(&argsinsert, descriptor_variable($4,0), &no_indicator); + $$ = EMPTY; + } + | USING SQL_DESCRIPTOR name + { + add_variable_to_head(&argsinsert, sqlda_variable($3), &no_indicator); + $$ = EMPTY; + } + ; + +into_descriptor: INTO SQL_SQL SQL_DESCRIPTOR quoted_ident_stringvar + { + add_variable_to_head(&argsresult, descriptor_variable($4,1), &no_indicator); + $$ = EMPTY; + } + | INTO SQL_DESCRIPTOR name + { + add_variable_to_head(&argsresult, sqlda_variable($3), &no_indicator); + $$ = EMPTY; + } + ; + +into_sqlda: INTO name + { + add_variable_to_head(&argsresult, sqlda_variable($2), &no_indicator); + $$ = EMPTY; + } + ; + +using_list: UsingValue | UsingValue ',' using_list; + +UsingValue: UsingConst + { + char *length = mm_alloc(32); + + sprintf(length, "%d", (int) strlen($1)); + add_variable_to_head(&argsinsert, new_variable($1, ECPGmake_simple_type(ECPGt_const, length, 0), 0), &no_indicator); + } + | civar { $$ = EMPTY; } + | civarind { $$ = EMPTY; } + ; + +UsingConst: Iconst { $$ = $1; } + | '+' Iconst { $$ = cat_str(2, mm_strdup("+"), $2); } + | '-' Iconst { $$ = cat_str(2, mm_strdup("-"), $2); } + | ecpg_fconst { $$ = $1; } + | '+' ecpg_fconst { $$ = cat_str(2, mm_strdup("+"), $2); } + | '-' ecpg_fconst { $$ = cat_str(2, mm_strdup("-"), $2); } + | ecpg_sconst { $$ = $1; } + | ecpg_bconst { $$ = $1; } + | ecpg_xconst { $$ = $1; } + ; + +/* + * We accept DESCRIBE [OUTPUT] but do nothing with DESCRIBE INPUT so far. + */ +ECPGDescribe: SQL_DESCRIBE INPUT_P prepared_name using_descriptor + { + const char *con = connection ? connection : "NULL"; + mmerror(PARSE_ERROR, ET_WARNING, "using unsupported DESCRIBE statement"); + $$ = (char *) mm_alloc(sizeof("1, , ") + strlen(con) + strlen($3)); + sprintf($$, "1, %s, %s", con, $3); + } + | SQL_DESCRIBE opt_output prepared_name using_descriptor + { + const char *con = connection ? connection : "NULL"; + struct variable *var; + + var = argsinsert->variable; + remove_variable_from_list(&argsinsert, var); + add_variable_to_head(&argsresult, var, &no_indicator); + + $$ = (char *) mm_alloc(sizeof("0, , ") + strlen(con) + strlen($3)); + sprintf($$, "0, %s, %s", con, $3); + } + | SQL_DESCRIBE opt_output prepared_name into_descriptor + { + const char *con = connection ? connection : "NULL"; + $$ = (char *) mm_alloc(sizeof("0, , ") + strlen(con) + strlen($3)); + sprintf($$, "0, %s, %s", con, $3); + } + | SQL_DESCRIBE INPUT_P prepared_name into_sqlda + { + const char *con = connection ? connection : "NULL"; + mmerror(PARSE_ERROR, ET_WARNING, "using unsupported DESCRIBE statement"); + $$ = (char *) mm_alloc(sizeof("1, , ") + strlen(con) + strlen($3)); + sprintf($$, "1, %s, %s", con, $3); + } + | SQL_DESCRIBE opt_output prepared_name into_sqlda + { + const char *con = connection ? connection : "NULL"; + $$ = (char *) mm_alloc(sizeof("0, , ") + strlen(con) + strlen($3)); + sprintf($$, "0, %s, %s", con, $3); + } + ; + +opt_output: SQL_OUTPUT { $$ = mm_strdup("output"); } + | /* EMPTY */ { $$ = EMPTY; } + ; + +/* + * dynamic SQL: descriptor based access + * originally written by Christof Petig + * and Peter Eisentraut + */ + +/* + * allocate a descriptor + */ +ECPGAllocateDescr: SQL_ALLOCATE SQL_DESCRIPTOR quoted_ident_stringvar + { + add_descriptor($3,connection); + $$ = $3; + } + ; + + +/* + * deallocate a descriptor + */ +ECPGDeallocateDescr: DEALLOCATE SQL_DESCRIPTOR quoted_ident_stringvar + { + drop_descriptor($3,connection); + $$ = $3; + } + ; + +/* + * manipulate a descriptor header + */ + +ECPGGetDescriptorHeader: SQL_GET SQL_DESCRIPTOR quoted_ident_stringvar ECPGGetDescHeaderItems + { $$ = $3; } + ; + +ECPGGetDescHeaderItems: ECPGGetDescHeaderItem + | ECPGGetDescHeaderItems ',' ECPGGetDescHeaderItem + ; + +ECPGGetDescHeaderItem: cvariable '=' desc_header_item + { push_assignment($1, $3); } + ; + + +ECPGSetDescriptorHeader: SET SQL_DESCRIPTOR quoted_ident_stringvar ECPGSetDescHeaderItems + { $$ = $3; } + ; + +ECPGSetDescHeaderItems: ECPGSetDescHeaderItem + | ECPGSetDescHeaderItems ',' ECPGSetDescHeaderItem + ; + +ECPGSetDescHeaderItem: desc_header_item '=' IntConstVar + { + push_assignment($3, $1); + } + ; + +IntConstVar: Iconst + { + char *length = mm_alloc(sizeof(int) * CHAR_BIT * 10 / 3); + + sprintf(length, "%d", (int) strlen($1)); + new_variable($1, ECPGmake_simple_type(ECPGt_const, length, 0), 0); + $$ = $1; + } + | cvariable + { + $$ = $1; + } + ; + +desc_header_item: SQL_COUNT { $$ = ECPGd_count; } + ; + +/* + * manipulate a descriptor + */ + +ECPGGetDescriptor: SQL_GET SQL_DESCRIPTOR quoted_ident_stringvar VALUE_P IntConstVar ECPGGetDescItems + { $$.str = $5; $$.name = $3; } + ; + +ECPGGetDescItems: ECPGGetDescItem + | ECPGGetDescItems ',' ECPGGetDescItem + ; + +ECPGGetDescItem: cvariable '=' descriptor_item { push_assignment($1, $3); }; + + +ECPGSetDescriptor: SET SQL_DESCRIPTOR quoted_ident_stringvar VALUE_P IntConstVar ECPGSetDescItems + { $$.str = $5; $$.name = $3; } + ; + +ECPGSetDescItems: ECPGSetDescItem + | ECPGSetDescItems ',' ECPGSetDescItem + ; + +ECPGSetDescItem: descriptor_item '=' AllConstVar + { + push_assignment($3, $1); + } + ; + +AllConstVar: ecpg_fconst + { + char *length = mm_alloc(sizeof(int) * CHAR_BIT * 10 / 3); + + sprintf(length, "%d", (int) strlen($1)); + new_variable($1, ECPGmake_simple_type(ECPGt_const, length, 0), 0); + $$ = $1; + } + + | IntConstVar + { + $$ = $1; + } + + | '-' ecpg_fconst + { + char *length = mm_alloc(sizeof(int) * CHAR_BIT * 10 / 3); + char *var = cat2_str(mm_strdup("-"), $2); + + sprintf(length, "%d", (int) strlen(var)); + new_variable(var, ECPGmake_simple_type(ECPGt_const, length, 0), 0); + $$ = var; + } + + | '-' Iconst + { + char *length = mm_alloc(sizeof(int) * CHAR_BIT * 10 / 3); + char *var = cat2_str(mm_strdup("-"), $2); + + sprintf(length, "%d", (int) strlen(var)); + new_variable(var, ECPGmake_simple_type(ECPGt_const, length, 0), 0); + $$ = var; + } + + | ecpg_sconst + { + char *length = mm_alloc(sizeof(int) * CHAR_BIT * 10 / 3); + char *var = $1 + 1; + + var[strlen(var) - 1] = '\0'; + sprintf(length, "%d", (int) strlen(var)); + new_variable(var, ECPGmake_simple_type(ECPGt_const, length, 0), 0); + $$ = var; + } + ; + +descriptor_item: SQL_CARDINALITY { $$ = ECPGd_cardinality; } + | DATA_P { $$ = ECPGd_data; } + | SQL_DATETIME_INTERVAL_CODE { $$ = ECPGd_di_code; } + | SQL_DATETIME_INTERVAL_PRECISION { $$ = ECPGd_di_precision; } + | SQL_INDICATOR { $$ = ECPGd_indicator; } + | SQL_KEY_MEMBER { $$ = ECPGd_key_member; } + | SQL_LENGTH { $$ = ECPGd_length; } + | NAME_P { $$ = ECPGd_name; } + | SQL_NULLABLE { $$ = ECPGd_nullable; } + | SQL_OCTET_LENGTH { $$ = ECPGd_octet; } + | PRECISION { $$ = ECPGd_precision; } + | SQL_RETURNED_LENGTH { $$ = ECPGd_length; } + | SQL_RETURNED_OCTET_LENGTH { $$ = ECPGd_ret_octet; } + | SQL_SCALE { $$ = ECPGd_scale; } + | TYPE_P { $$ = ECPGd_type; } + ; + +/* + * set/reset the automatic transaction mode, this needs a differnet handling + * as the other set commands + */ +ECPGSetAutocommit: SET SQL_AUTOCOMMIT '=' on_off { $$ = $4; } + | SET SQL_AUTOCOMMIT TO on_off { $$ = $4; } + ; + +on_off: ON { $$ = mm_strdup("on"); } + | OFF { $$ = mm_strdup("off"); } + ; + +/* + * set the actual connection, this needs a differnet handling as the other + * set commands + */ +ECPGSetConnection: SET CONNECTION TO connection_object { $$ = $4; } + | SET CONNECTION '=' connection_object { $$ = $4; } + | SET CONNECTION connection_object { $$ = $3; } + ; + +/* + * define a new type for embedded SQL + */ +ECPGTypedef: TYPE_P + { + /* reset this variable so we see if there was */ + /* an initializer specified */ + initializer = 0; + } + ECPGColLabelCommon IS var_type opt_array_bounds opt_reference + { + add_typedef($3, $6.index1, $6.index2, $5.type_enum, $5.type_dimension, $5.type_index, initializer, *$7 ? 1 : 0); + + if (auto_create_c == false) + $$ = cat_str(7, mm_strdup("/* exec sql type"), mm_strdup($3), mm_strdup("is"), mm_strdup($5.type_str), mm_strdup($6.str), $7, mm_strdup("*/")); + else + $$ = cat_str(6, mm_strdup("typedef "), mm_strdup($5.type_str), *$7?mm_strdup("*"):mm_strdup(""), mm_strdup($6.str), mm_strdup($3), mm_strdup(";")); + } + ; + +opt_reference: SQL_REFERENCE { $$ = mm_strdup("reference"); } + | /*EMPTY*/ { $$ = EMPTY; } + ; + +/* + * define the type of one variable for embedded SQL + */ +ECPGVar: SQL_VAR + { + /* reset this variable so we see if there was */ + /* an initializer specified */ + initializer = 0; + } + ColLabel IS var_type opt_array_bounds opt_reference + { + struct variable *p = find_variable($3); + char *dimension = $6.index1; + char *length = $6.index2; + struct ECPGtype * type; + + if (($5.type_enum == ECPGt_struct || + $5.type_enum == ECPGt_union) && + initializer == 1) + mmerror(PARSE_ERROR, ET_ERROR, "initializer not allowed in EXEC SQL VAR command"); + else + { + adjust_array($5.type_enum, &dimension, &length, $5.type_dimension, $5.type_index, *$7?1:0, false); + + switch ($5.type_enum) + { + case ECPGt_struct: + case ECPGt_union: + if (atoi(dimension) < 0) + type = ECPGmake_struct_type(struct_member_list[struct_level], $5.type_enum, $5.type_str, $5.type_sizeof); + else + type = ECPGmake_array_type(ECPGmake_struct_type(struct_member_list[struct_level], $5.type_enum, $5.type_str, $5.type_sizeof), dimension); + break; + + case ECPGt_varchar: + if (atoi(dimension) == -1) + type = ECPGmake_simple_type($5.type_enum, length, 0); + else + type = ECPGmake_array_type(ECPGmake_simple_type($5.type_enum, length, 0), dimension); + break; + + case ECPGt_char: + case ECPGt_unsigned_char: + case ECPGt_string: + if (atoi(dimension) == -1) + type = ECPGmake_simple_type($5.type_enum, length, 0); + else + type = ECPGmake_array_type(ECPGmake_simple_type($5.type_enum, length, 0), dimension); + break; + + default: + if (atoi(length) >= 0) + mmerror(PARSE_ERROR, ET_ERROR, "multidimensional arrays for simple data types are not supported"); + + if (atoi(dimension) < 0) + type = ECPGmake_simple_type($5.type_enum, mm_strdup("1"), 0); + else + type = ECPGmake_array_type(ECPGmake_simple_type($5.type_enum, mm_strdup("1"), 0), dimension); + break; + } + + ECPGfree_type(p->type); + p->type = type; + } + + $$ = cat_str(7, mm_strdup("/* exec sql var"), mm_strdup($3), mm_strdup("is"), mm_strdup($5.type_str), mm_strdup($6.str), $7, mm_strdup("*/")); + } + ; + +/* + * whenever statement: decide what to do in case of error/no data found + * according to SQL standards we lack: SQLSTATE, CONSTRAINT and SQLEXCEPTION + */ +ECPGWhenever: SQL_WHENEVER SQL_SQLERROR action + { + when_error.code = $3.code; + when_error.command = $3.command; + $$ = cat_str(3, mm_strdup("/* exec sql whenever sqlerror "), $3.str, mm_strdup("; */")); + } + | SQL_WHENEVER NOT SQL_FOUND action + { + when_nf.code = $4.code; + when_nf.command = $4.command; + $$ = cat_str(3, mm_strdup("/* exec sql whenever not found "), $4.str, mm_strdup("; */")); + } + | SQL_WHENEVER SQL_SQLWARNING action + { + when_warn.code = $3.code; + when_warn.command = $3.command; + $$ = cat_str(3, mm_strdup("/* exec sql whenever sql_warning "), $3.str, mm_strdup("; */")); + } + ; + +action : CONTINUE_P + { + $$.code = W_NOTHING; + $$.command = NULL; + $$.str = mm_strdup("continue"); + } + | SQL_SQLPRINT + { + $$.code = W_SQLPRINT; + $$.command = NULL; + $$.str = mm_strdup("sqlprint"); + } + | SQL_STOP + { + $$.code = W_STOP; + $$.command = NULL; + $$.str = mm_strdup("stop"); + } + | SQL_GOTO name + { + $$.code = W_GOTO; + $$.command = strdup($2); + $$.str = cat2_str(mm_strdup("goto "), $2); + } + | SQL_GO TO name + { + $$.code = W_GOTO; + $$.command = strdup($3); + $$.str = cat2_str(mm_strdup("goto "), $3); + } + | DO name '(' c_args ')' + { + $$.code = W_DO; + $$.command = cat_str(4, $2, mm_strdup("("), $4, mm_strdup(")")); + $$.str = cat2_str(mm_strdup("do"), mm_strdup($$.command)); + } + | DO SQL_BREAK + { + $$.code = W_BREAK; + $$.command = NULL; + $$.str = mm_strdup("break"); + } + | SQL_CALL name '(' c_args ')' + { + $$.code = W_DO; + $$.command = cat_str(4, $2, mm_strdup("("), $4, mm_strdup(")")); + $$.str = cat2_str(mm_strdup("call"), mm_strdup($$.command)); + } + | SQL_CALL name + { + $$.code = W_DO; + $$.command = cat2_str($2, mm_strdup("()")); + $$.str = cat2_str(mm_strdup("call"), mm_strdup($$.command)); + } + ; + +/* some other stuff for ecpg */ + +/* additional unreserved keywords */ +ECPGKeywords: ECPGKeywords_vanames { $$ = $1; } + | ECPGKeywords_rest { $$ = $1; } + ; + +ECPGKeywords_vanames: SQL_BREAK { $$ = mm_strdup("break"); } + | SQL_CALL { $$ = mm_strdup("call"); } + | SQL_CARDINALITY { $$ = mm_strdup("cardinality"); } + | SQL_COUNT { $$ = mm_strdup("count"); } + | SQL_DATETIME_INTERVAL_CODE { $$ = mm_strdup("datetime_interval_code"); } + | SQL_DATETIME_INTERVAL_PRECISION { $$ = mm_strdup("datetime_interval_precision"); } + | SQL_FOUND { $$ = mm_strdup("found"); } + | SQL_GO { $$ = mm_strdup("go"); } + | SQL_GOTO { $$ = mm_strdup("goto"); } + | SQL_IDENTIFIED { $$ = mm_strdup("identified"); } + | SQL_INDICATOR { $$ = mm_strdup("indicator"); } + | SQL_KEY_MEMBER { $$ = mm_strdup("key_member"); } + | SQL_LENGTH { $$ = mm_strdup("length"); } + | SQL_NULLABLE { $$ = mm_strdup("nullable"); } + | SQL_OCTET_LENGTH { $$ = mm_strdup("octet_length"); } + | SQL_RETURNED_LENGTH { $$ = mm_strdup("returned_length"); } + | SQL_RETURNED_OCTET_LENGTH { $$ = mm_strdup("returned_octet_length"); } + | SQL_SCALE { $$ = mm_strdup("scale"); } + | SQL_SECTION { $$ = mm_strdup("section"); } + | SQL_SQL { $$ = mm_strdup("sql"); } + | SQL_SQLERROR { $$ = mm_strdup("sqlerror"); } + | SQL_SQLPRINT { $$ = mm_strdup("sqlprint"); } + | SQL_SQLWARNING { $$ = mm_strdup("sqlwarning"); } + | SQL_STOP { $$ = mm_strdup("stop"); } + ; + +ECPGKeywords_rest: SQL_CONNECT { $$ = mm_strdup("connect"); } + | SQL_DESCRIBE { $$ = mm_strdup("describe"); } + | SQL_DISCONNECT { $$ = mm_strdup("disconnect"); } + | SQL_OPEN { $$ = mm_strdup("open"); } + | SQL_VAR { $$ = mm_strdup("var"); } + | SQL_WHENEVER { $$ = mm_strdup("whenever"); } + ; + +/* additional keywords that can be SQL type names (but not ECPGColLabels) */ +ECPGTypeName: SQL_BOOL { $$ = mm_strdup("bool"); } + | SQL_LONG { $$ = mm_strdup("long"); } + | SQL_OUTPUT { $$ = mm_strdup("output"); } + | SQL_SHORT { $$ = mm_strdup("short"); } + | SQL_STRUCT { $$ = mm_strdup("struct"); } + | SQL_SIGNED { $$ = mm_strdup("signed"); } + | SQL_UNSIGNED { $$ = mm_strdup("unsigned"); } + ; + +symbol: ColLabel { $$ = $1; } + ; + +ECPGColId: ecpg_ident { $$ = $1; } + | unreserved_keyword { $$ = $1; } + | col_name_keyword { $$ = $1; } + | ECPGunreserved_interval { $$ = $1; } + | ECPGKeywords { $$ = $1; } + | ECPGCKeywords { $$ = $1; } + | CHAR_P { $$ = mm_strdup("char"); } + | VALUES { $$ = mm_strdup("values"); } + ; + +/* + * Name classification hierarchy. + * + * These productions should match those in the core grammar, except that + * we use all_unreserved_keyword instead of unreserved_keyword, and + * where possible include ECPG keywords as well as core keywords. + */ + +/* Column identifier --- names that can be column, table, etc names. + */ +ColId: ecpg_ident { $$ = $1; } + | all_unreserved_keyword { $$ = $1; } + | col_name_keyword { $$ = $1; } + | ECPGKeywords { $$ = $1; } + | ECPGCKeywords { $$ = $1; } + | CHAR_P { $$ = mm_strdup("char"); } + | VALUES { $$ = mm_strdup("values"); } + ; + +/* Type/function identifier --- names that can be type or function names. + */ +type_function_name: ecpg_ident { $$ = $1; } + | all_unreserved_keyword { $$ = $1; } + | type_func_name_keyword { $$ = $1; } + | ECPGKeywords { $$ = $1; } + | ECPGCKeywords { $$ = $1; } + | ECPGTypeName { $$ = $1; } + ; + +/* Column label --- allowed labels in "AS" clauses. + * This presently includes *all* Postgres keywords. + */ +ColLabel: ECPGColLabel { $$ = $1; } + | ECPGTypeName { $$ = $1; } + | CHAR_P { $$ = mm_strdup("char"); } + | CURRENT_P { $$ = mm_strdup("current"); } + | INPUT_P { $$ = mm_strdup("input"); } + | INT_P { $$ = mm_strdup("int"); } + | TO { $$ = mm_strdup("to"); } + | UNION { $$ = mm_strdup("union"); } + | VALUES { $$ = mm_strdup("values"); } + | ECPGCKeywords { $$ = $1; } + | ECPGunreserved_interval { $$ = $1; } + ; + +ECPGColLabel: ECPGColLabelCommon { $$ = $1; } + | unreserved_keyword { $$ = $1; } + | reserved_keyword { $$ = $1; } + | ECPGKeywords_rest { $$ = $1; } + | CONNECTION { $$ = mm_strdup("connection"); } + ; + +ECPGColLabelCommon: ecpg_ident { $$ = $1; } + | col_name_keyword { $$ = $1; } + | type_func_name_keyword { $$ = $1; } + | ECPGKeywords_vanames { $$ = $1; } + ; + +ECPGCKeywords: S_AUTO { $$ = mm_strdup("auto"); } + | S_CONST { $$ = mm_strdup("const"); } + | S_EXTERN { $$ = mm_strdup("extern"); } + | S_REGISTER { $$ = mm_strdup("register"); } + | S_STATIC { $$ = mm_strdup("static"); } + | S_TYPEDEF { $$ = mm_strdup("typedef"); } + | S_VOLATILE { $$ = mm_strdup("volatile"); } + ; + +/* "Unreserved" keywords --- available for use as any kind of name. + */ + +/* + * The following symbols must be excluded from ECPGColLabel and directly + * included into ColLabel to enable C variables to get names from ECPGColLabel: + * DAY_P, HOUR_P, MINUTE_P, MONTH_P, SECOND_P, YEAR_P. + * + * We also have to exclude CONNECTION, CURRENT, and INPUT for various reasons. + * CONNECTION can be added back in all_unreserved_keyword, but CURRENT and + * INPUT are reserved for ecpg purposes. + * + * The mentioned exclusions are done by $replace_line settings in parse.pl. + */ +all_unreserved_keyword: unreserved_keyword { $$ = $1; } + | ECPGunreserved_interval { $$ = $1; } + | CONNECTION { $$ = mm_strdup("connection"); } + ; + +ECPGunreserved_interval: DAY_P { $$ = mm_strdup("day"); } + | HOUR_P { $$ = mm_strdup("hour"); } + | MINUTE_P { $$ = mm_strdup("minute"); } + | MONTH_P { $$ = mm_strdup("month"); } + | SECOND_P { $$ = mm_strdup("second"); } + | YEAR_P { $$ = mm_strdup("year"); } + ; + + +into_list : coutputvariable | into_list ',' coutputvariable + ; + +ecpgstart: SQL_START { + reset_variables(); + pacounter = 1; + } + ; + +c_args: /*EMPTY*/ { $$ = EMPTY; } + | c_list { $$ = $1; } + ; + +coutputvariable: cvariable indicator + { add_variable_to_head(&argsresult, find_variable($1), find_variable($2)); } + | cvariable + { add_variable_to_head(&argsresult, find_variable($1), &no_indicator); } + ; + + +civarind: cvariable indicator + { + if (find_variable($2)->type->type == ECPGt_array) + mmerror(PARSE_ERROR, ET_ERROR, "arrays of indicators are not allowed on input"); + + add_variable_to_head(&argsinsert, find_variable($1), find_variable($2)); + $$ = create_questionmarks($1, false); + } + ; + +char_civar: char_variable + { + char *ptr = strstr($1, ".arr"); + + if (ptr) /* varchar, we need the struct name here, not the struct element */ + *ptr = '\0'; + add_variable_to_head(&argsinsert, find_variable($1), &no_indicator); + $$ = $1; + } + ; + +civar: cvariable + { + add_variable_to_head(&argsinsert, find_variable($1), &no_indicator); + $$ = create_questionmarks($1, false); + } + ; + +indicator: cvariable { check_indicator((find_variable($1))->type); $$ = $1; } + | SQL_INDICATOR cvariable { check_indicator((find_variable($2))->type); $$ = $2; } + | SQL_INDICATOR name { check_indicator((find_variable($2))->type); $$ = $2; } + ; + +cvariable: CVARIABLE + { + /* As long as multidimensional arrays are not implemented we have to check for those here */ + char *ptr = $1; + int brace_open=0, brace = false; + + for (; *ptr; ptr++) + { + switch (*ptr) + { + case '[': + if (brace) + mmerror(PARSE_ERROR, ET_FATAL, "multidimensional arrays for simple data types are not supported"); + brace_open++; + break; + case ']': + brace_open--; + if (brace_open == 0) + brace = true; + break; + case '\t': + case ' ': + break; + default: + if (brace_open == 0) + brace = false; + break; + } + } + $$ = $1; + } + ; + +ecpg_param: PARAM { $$ = make_name(); } ; + +ecpg_bconst: BCONST { $$ = make_name(); } ; + +ecpg_fconst: FCONST { $$ = make_name(); } ; + +ecpg_sconst: + SCONST + { + /* could have been input as '' or $$ */ + $$ = (char *)mm_alloc(strlen($1) + 3); + $$[0]='\''; + strcpy($$+1, $1); + $$[strlen($1)+1]='\''; + $$[strlen($1)+2]='\0'; + free($1); + } + | ECONST + { + $$ = (char *)mm_alloc(strlen($1) + 4); + $$[0]='E'; + $$[1]='\''; + strcpy($$+2, $1); + $$[strlen($1)+2]='\''; + $$[strlen($1)+3]='\0'; + free($1); + } + | NCONST + { + $$ = (char *)mm_alloc(strlen($1) + 4); + $$[0]='N'; + $$[1]='\''; + strcpy($$+2, $1); + $$[strlen($1)+2]='\''; + $$[strlen($1)+3]='\0'; + free($1); + } + | UCONST { $$ = $1; } + | DOLCONST { $$ = $1; } + ; + +ecpg_xconst: XCONST { $$ = make_name(); } ; + +ecpg_ident: IDENT { $$ = make_name(); } + | CSTRING { $$ = make3_str(mm_strdup("\""), $1, mm_strdup("\"")); } + | UIDENT { $$ = $1; } + ; + +quoted_ident_stringvar: name + { $$ = make3_str(mm_strdup("\""), $1, mm_strdup("\"")); } + | char_variable + { $$ = make3_str(mm_strdup("("), $1, mm_strdup(")")); } + ; + +/* + * C stuff + */ + +c_stuff_item: c_anything { $$ = $1; } + | '(' ')' { $$ = mm_strdup("()"); } + | '(' c_stuff ')' + { $$ = cat_str(3, mm_strdup("("), $2, mm_strdup(")")); } + ; + +c_stuff: c_stuff_item { $$ = $1; } + | c_stuff c_stuff_item + { $$ = cat2_str($1, $2); } + ; + +c_list: c_term { $$ = $1; } + | c_list ',' c_term { $$ = cat_str(3, $1, mm_strdup(","), $3); } + ; + +c_term: c_stuff { $$ = $1; } + | '{' c_list '}' { $$ = cat_str(3, mm_strdup("{"), $2, mm_strdup("}")); } + ; + +c_thing: c_anything { $$ = $1; } + | '(' { $$ = mm_strdup("("); } + | ')' { $$ = mm_strdup(")"); } + | ',' { $$ = mm_strdup(","); } + | ';' { $$ = mm_strdup(";"); } + ; + +c_anything: ecpg_ident { $$ = $1; } + | Iconst { $$ = $1; } + | ecpg_fconst { $$ = $1; } + | ecpg_sconst { $$ = $1; } + | '*' { $$ = mm_strdup("*"); } + | '+' { $$ = mm_strdup("+"); } + | '-' { $$ = mm_strdup("-"); } + | '/' { $$ = mm_strdup("/"); } + | '%' { $$ = mm_strdup("%"); } + | NULL_P { $$ = mm_strdup("NULL"); } + | S_ADD { $$ = mm_strdup("+="); } + | S_AND { $$ = mm_strdup("&&"); } + | S_ANYTHING { $$ = make_name(); } + | S_AUTO { $$ = mm_strdup("auto"); } + | S_CONST { $$ = mm_strdup("const"); } + | S_DEC { $$ = mm_strdup("--"); } + | S_DIV { $$ = mm_strdup("/="); } + | S_DOTPOINT { $$ = mm_strdup(".*"); } + | S_EQUAL { $$ = mm_strdup("=="); } + | S_EXTERN { $$ = mm_strdup("extern"); } + | S_INC { $$ = mm_strdup("++"); } + | S_LSHIFT { $$ = mm_strdup("<<"); } + | S_MEMBER { $$ = mm_strdup("->"); } + | S_MEMPOINT { $$ = mm_strdup("->*"); } + | S_MOD { $$ = mm_strdup("%="); } + | S_MUL { $$ = mm_strdup("*="); } + | S_NEQUAL { $$ = mm_strdup("!="); } + | S_OR { $$ = mm_strdup("||"); } + | S_REGISTER { $$ = mm_strdup("register"); } + | S_RSHIFT { $$ = mm_strdup(">>"); } + | S_STATIC { $$ = mm_strdup("static"); } + | S_SUB { $$ = mm_strdup("-="); } + | S_TYPEDEF { $$ = mm_strdup("typedef"); } + | S_VOLATILE { $$ = mm_strdup("volatile"); } + | SQL_BOOL { $$ = mm_strdup("bool"); } + | ENUM_P { $$ = mm_strdup("enum"); } + | HOUR_P { $$ = mm_strdup("hour"); } + | INT_P { $$ = mm_strdup("int"); } + | SQL_LONG { $$ = mm_strdup("long"); } + | MINUTE_P { $$ = mm_strdup("minute"); } + | MONTH_P { $$ = mm_strdup("month"); } + | SECOND_P { $$ = mm_strdup("second"); } + | SQL_SHORT { $$ = mm_strdup("short"); } + | SQL_SIGNED { $$ = mm_strdup("signed"); } + | SQL_STRUCT { $$ = mm_strdup("struct"); } + | SQL_UNSIGNED { $$ = mm_strdup("unsigned"); } + | YEAR_P { $$ = mm_strdup("year"); } + | CHAR_P { $$ = mm_strdup("char"); } + | FLOAT_P { $$ = mm_strdup("float"); } + | TO { $$ = mm_strdup("to"); } + | UNION { $$ = mm_strdup("union"); } + | VARCHAR { $$ = mm_strdup("varchar"); } + | '[' { $$ = mm_strdup("["); } + | ']' { $$ = mm_strdup("]"); } + | '=' { $$ = mm_strdup("="); } + | ':' { $$ = mm_strdup(":"); } + ; + +DeallocateStmt: DEALLOCATE prepared_name { $$ = $2; } + | DEALLOCATE PREPARE prepared_name { $$ = $3; } + | DEALLOCATE ALL { $$ = mm_strdup("all"); } + | DEALLOCATE PREPARE ALL { $$ = mm_strdup("all"); } + ; + +Iresult: Iconst { $$ = $1; } + | '(' Iresult ')' { $$ = cat_str(3, mm_strdup("("), $2, mm_strdup(")")); } + | Iresult '+' Iresult { $$ = cat_str(3, $1, mm_strdup("+"), $3); } + | Iresult '-' Iresult { $$ = cat_str(3, $1, mm_strdup("-"), $3); } + | Iresult '*' Iresult { $$ = cat_str(3, $1, mm_strdup("*"), $3); } + | Iresult '/' Iresult { $$ = cat_str(3, $1, mm_strdup("/"), $3); } + | Iresult '%' Iresult { $$ = cat_str(3, $1, mm_strdup("%"), $3); } + | ecpg_sconst { $$ = $1; } + | ColId { $$ = $1; } + ; + +execute_rest: /* EMPTY */ { $$ = EMPTY; } + | ecpg_using ecpg_into { $$ = EMPTY; } + | ecpg_into ecpg_using { $$ = EMPTY; } + | ecpg_using { $$ = EMPTY; } + | ecpg_into { $$ = EMPTY; } + ; + +ecpg_into: INTO into_list { $$ = EMPTY; } + | into_descriptor { $$ = $1; } + ; + +ecpg_fetch_into: ecpg_into { $$ = $1; } + | using_descriptor + { + struct variable *var; + + var = argsinsert->variable; + remove_variable_from_list(&argsinsert, var); + add_variable_to_head(&argsresult, var, &no_indicator); + $$ = $1; + } + ; + +opt_ecpg_fetch_into: /* EMPTY */ { $$ = EMPTY; } + | ecpg_fetch_into { $$ = $1; } + ; + +%% + +void base_yyerror(const char *error) +{ + /* translator: %s is typically the translation of "syntax error" */ + mmerror(PARSE_ERROR, ET_ERROR, "%s at or near \"%s\"", + _(error), token_start ? token_start : yytext); +} + +void parser_init(void) +{ + /* This function is empty. It only exists for compatibility with the backend parser right now. */ +} + +/* + * Must undefine base_yylex before including pgc.c, since we want it + * to create the function base_yylex not filtered_base_yylex. + */ +#undef base_yylex + +#include "pgc.c" diff --git a/src/interfaces/ecpg/test/.gitignore b/src/interfaces/ecpg/test/.gitignore deleted file mode 100644 index d60b197a9..000000000 --- a/src/interfaces/ecpg/test/.gitignore +++ /dev/null @@ -1,5 +0,0 @@ -/pg_regress -# Exclude subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/src/interfaces/ecpg/test/compat_informix/.gitignore b/src/interfaces/ecpg/test/compat_informix/.gitignore deleted file mode 100644 index f97706ba4..000000000 --- a/src/interfaces/ecpg/test/compat_informix/.gitignore +++ /dev/null @@ -1,18 +0,0 @@ -/charfuncs -/charfuncs.c -/dec_test -/dec_test.c -/describe -/describe.c -/rfmtdate -/rfmtdate.c -/rfmtlong -/rfmtlong.c -/rnull -/rnull.c -/sqlda -/sqlda.c -/test_informix -/test_informix.c -/test_informix2 -/test_informix2.c diff --git a/src/interfaces/ecpg/test/connect/.gitignore b/src/interfaces/ecpg/test/connect/.gitignore deleted file mode 100644 index e0639f3c8..000000000 --- a/src/interfaces/ecpg/test/connect/.gitignore +++ /dev/null @@ -1,10 +0,0 @@ -/test1 -/test1.c -/test2 -/test2.c -/test3 -/test3.c -/test4 -/test4.c -/test5 -/test5.c diff --git a/src/interfaces/ecpg/test/pgtypeslib/.gitignore b/src/interfaces/ecpg/test/pgtypeslib/.gitignore deleted file mode 100644 index 2987fef21..000000000 --- a/src/interfaces/ecpg/test/pgtypeslib/.gitignore +++ /dev/null @@ -1,10 +0,0 @@ -/dt_test -/dt_test.c -/dt_test2 -/dt_test2.c -/nan_test -/nan_test.c -/num_test -/num_test.c -/num_test2 -/num_test2.c diff --git a/src/interfaces/ecpg/test/preproc/.gitignore b/src/interfaces/ecpg/test/preproc/.gitignore deleted file mode 100644 index f2b304b13..000000000 --- a/src/interfaces/ecpg/test/preproc/.gitignore +++ /dev/null @@ -1,22 +0,0 @@ -/array_of_struct -/array_of_struct.c -/autoprep -/autoprep.c -/comment -/comment.c -/cursor -/cursor.c -/define -/define.c -/init -/init.c -/outofscope -/outofscope.c -/strings -/strings.c -/type -/type.c -/variable -/variable.c -/whenever -/whenever.c diff --git a/src/interfaces/ecpg/test/sql/.gitignore b/src/interfaces/ecpg/test/sql/.gitignore deleted file mode 100644 index cd6f342bb..000000000 --- a/src/interfaces/ecpg/test/sql/.gitignore +++ /dev/null @@ -1,40 +0,0 @@ -/array -/array.c -/binary -/binary.c -/code100 -/code100.c -/copystdout -/copystdout.c -/define -/define.c -/desc -/desc.c -/describe -/describe.c -/dynalloc -/dynalloc.c -/dynalloc2 -/dynalloc2.c -/dyntest -/dyntest.c -/execute -/execute.c -/fetch -/fetch.c -/func -/func.c -/indicators -/indicators.c -/insupd -/insupd.c -/oldexec -/oldexec.c -/parser -/parser.c -/quote -/quote.c -/show -/show.c -/sqlda -/sqlda.c diff --git a/src/interfaces/ecpg/test/thread/.gitignore b/src/interfaces/ecpg/test/thread/.gitignore deleted file mode 100644 index 12ff319b9..000000000 --- a/src/interfaces/ecpg/test/thread/.gitignore +++ /dev/null @@ -1,10 +0,0 @@ -/alloc -/alloc.c -/descriptor -/descriptor.c -/prep -/prep.c -/thread -/thread.c -/thread_implicit -/thread_implicit.c diff --git a/src/interfaces/libpq/.gitignore b/src/interfaces/libpq/.gitignore deleted file mode 100644 index ba0d38592..000000000 --- a/src/interfaces/libpq/.gitignore +++ /dev/null @@ -1,21 +0,0 @@ -/exports.list -/chklocale.c -/crypt.c -/getaddrinfo.c -/getpeereid.c -/inet_aton.c -/inet_net_ntop.c -/noblock.c -/open.c -/pgstrcasecmp.c -/snprintf.c -/strerror.c -/strlcpy.c -/thread.c -/win32error.c -/pgsleep.c -/md5.c -/ip.c -/encnames.c -/wchar.c -/libpq.rc diff --git a/src/interfaces/libpq/libpq_debugdll.def b/src/interfaces/libpq/libpq_debugdll.def new file mode 100644 index 000000000..426c7722d --- /dev/null +++ b/src/interfaces/libpq/libpq_debugdll.def @@ -0,0 +1,164 @@ +; DEF file for MS VC++ +LIBRARY LIBPQD +EXPORTS + PQconnectdb @ 1 + PQsetdbLogin @ 2 + PQconndefaults @ 3 + PQfinish @ 4 + PQreset @ 5 + PQrequestCancel @ 6 + PQdb @ 7 + PQuser @ 8 + PQpass @ 9 + PQhost @ 10 + PQport @ 11 + PQtty @ 12 + PQoptions @ 13 + PQstatus @ 14 + PQerrorMessage @ 15 + PQsocket @ 16 + PQbackendPID @ 17 + PQtrace @ 18 + PQuntrace @ 19 + PQsetNoticeProcessor @ 20 + PQexec @ 21 + PQnotifies @ 22 + PQsendQuery @ 23 + PQgetResult @ 24 + PQisBusy @ 25 + PQconsumeInput @ 26 + PQgetline @ 27 + PQputline @ 28 + PQgetlineAsync @ 29 + PQputnbytes @ 30 + PQendcopy @ 31 + PQfn @ 32 + PQresultStatus @ 33 + PQntuples @ 34 + PQnfields @ 35 + PQbinaryTuples @ 36 + PQfname @ 37 + PQfnumber @ 38 + PQftype @ 39 + PQfsize @ 40 + PQfmod @ 41 + PQcmdStatus @ 42 + PQoidStatus @ 43 + PQcmdTuples @ 44 + PQgetvalue @ 45 + PQgetlength @ 46 + PQgetisnull @ 47 + PQclear @ 48 + PQmakeEmptyPGresult @ 49 + PQprint @ 50 + PQdisplayTuples @ 51 + PQprintTuples @ 52 + lo_open @ 53 + lo_close @ 54 + lo_read @ 55 + lo_write @ 56 + lo_lseek @ 57 + lo_creat @ 58 + lo_tell @ 59 + lo_unlink @ 60 + lo_import @ 61 + lo_export @ 62 + pgresStatus @ 63 + PQmblen @ 64 + PQresultErrorMessage @ 65 + PQresStatus @ 66 + termPQExpBuffer @ 67 + appendPQExpBufferChar @ 68 + initPQExpBuffer @ 69 + resetPQExpBuffer @ 70 + PQoidValue @ 71 + PQclientEncoding @ 72 + PQenv2encoding @ 73 + appendBinaryPQExpBuffer @ 74 + appendPQExpBufferStr @ 75 + destroyPQExpBuffer @ 76 + createPQExpBuffer @ 77 + PQconninfoFree @ 78 + PQconnectPoll @ 79 + PQconnectStart @ 80 + PQflush @ 81 + PQisnonblocking @ 82 + PQresetPoll @ 83 + PQresetStart @ 84 + PQsetClientEncoding @ 85 + PQsetnonblocking @ 86 + PQfreeNotify @ 87 + PQescapeString @ 88 + PQescapeBytea @ 89 + printfPQExpBuffer @ 90 + appendPQExpBuffer @ 91 + pg_encoding_to_char @ 92 + pg_utf_mblen @ 93 + PQunescapeBytea @ 94 + PQfreemem @ 95 + PQtransactionStatus @ 96 + PQparameterStatus @ 97 + PQprotocolVersion @ 98 + PQsetErrorVerbosity @ 99 + PQsetNoticeReceiver @ 100 + PQexecParams @ 101 + PQsendQueryParams @ 102 + PQputCopyData @ 103 + PQputCopyEnd @ 104 + PQgetCopyData @ 105 + PQresultErrorField @ 106 + PQftable @ 107 + PQftablecol @ 108 + PQfformat @ 109 + PQexecPrepared @ 110 + PQsendQueryPrepared @ 111 + PQdsplen @ 112 + PQserverVersion @ 113 + PQgetssl @ 114 + pg_char_to_encoding @ 115 + pg_valid_server_encoding @ 116 + pqsignal @ 117 + PQprepare @ 118 + PQsendPrepare @ 119 + PQgetCancel @ 120 + PQfreeCancel @ 121 + PQcancel @ 122 + lo_create @ 123 + PQinitSSL @ 124 + PQregisterThreadLock @ 125 + PQescapeStringConn @ 126 + PQescapeByteaConn @ 127 + PQencryptPassword @ 128 + PQisthreadsafe @ 129 + enlargePQExpBuffer @ 130 + PQnparams @ 131 + PQparamtype @ 132 + PQdescribePrepared @ 133 + PQdescribePortal @ 134 + PQsendDescribePrepared @ 135 + PQsendDescribePortal @ 136 + lo_truncate @ 137 + PQconnectionUsedPassword @ 138 + pg_valid_server_encoding_id @ 139 + PQconnectionNeedsPassword @ 140 + lo_import_with_oid @ 141 + PQcopyResult @ 142 + PQsetResultAttrs @ 143 + PQsetvalue @ 144 + PQresultAlloc @ 145 + PQregisterEventProc @ 146 + PQinstanceData @ 147 + PQsetInstanceData @ 148 + PQresultInstanceData @ 149 + PQresultSetInstanceData @ 150 + PQfireResultCreateEvents @ 151 + PQconninfoParse @ 152 + PQinitOpenSSL @ 153 + PQescapeLiteral @ 154 + PQescapeIdentifier @ 155 + PQconnectdbParams @ 156 + PQconnectStartParams @ 157 + PQping @ 158 + PQpingParams @ 159 + PQlibVersion @ 160 + PQsetSingleRowMode @ 161 diff --git a/src/interfaces/libpq/libpqdll.def b/src/interfaces/libpq/libpqdll.def new file mode 100644 index 000000000..b215c1f76 --- /dev/null +++ b/src/interfaces/libpq/libpqdll.def @@ -0,0 +1,164 @@ +; DEF file for MS VC++ +LIBRARY LIBPQ +EXPORTS + PQconnectdb @ 1 + PQsetdbLogin @ 2 + PQconndefaults @ 3 + PQfinish @ 4 + PQreset @ 5 + PQrequestCancel @ 6 + PQdb @ 7 + PQuser @ 8 + PQpass @ 9 + PQhost @ 10 + PQport @ 11 + PQtty @ 12 + PQoptions @ 13 + PQstatus @ 14 + PQerrorMessage @ 15 + PQsocket @ 16 + PQbackendPID @ 17 + PQtrace @ 18 + PQuntrace @ 19 + PQsetNoticeProcessor @ 20 + PQexec @ 21 + PQnotifies @ 22 + PQsendQuery @ 23 + PQgetResult @ 24 + PQisBusy @ 25 + PQconsumeInput @ 26 + PQgetline @ 27 + PQputline @ 28 + PQgetlineAsync @ 29 + PQputnbytes @ 30 + PQendcopy @ 31 + PQfn @ 32 + PQresultStatus @ 33 + PQntuples @ 34 + PQnfields @ 35 + PQbinaryTuples @ 36 + PQfname @ 37 + PQfnumber @ 38 + PQftype @ 39 + PQfsize @ 40 + PQfmod @ 41 + PQcmdStatus @ 42 + PQoidStatus @ 43 + PQcmdTuples @ 44 + PQgetvalue @ 45 + PQgetlength @ 46 + PQgetisnull @ 47 + PQclear @ 48 + PQmakeEmptyPGresult @ 49 + PQprint @ 50 + PQdisplayTuples @ 51 + PQprintTuples @ 52 + lo_open @ 53 + lo_close @ 54 + lo_read @ 55 + lo_write @ 56 + lo_lseek @ 57 + lo_creat @ 58 + lo_tell @ 59 + lo_unlink @ 60 + lo_import @ 61 + lo_export @ 62 + pgresStatus @ 63 + PQmblen @ 64 + PQresultErrorMessage @ 65 + PQresStatus @ 66 + termPQExpBuffer @ 67 + appendPQExpBufferChar @ 68 + initPQExpBuffer @ 69 + resetPQExpBuffer @ 70 + PQoidValue @ 71 + PQclientEncoding @ 72 + PQenv2encoding @ 73 + appendBinaryPQExpBuffer @ 74 + appendPQExpBufferStr @ 75 + destroyPQExpBuffer @ 76 + createPQExpBuffer @ 77 + PQconninfoFree @ 78 + PQconnectPoll @ 79 + PQconnectStart @ 80 + PQflush @ 81 + PQisnonblocking @ 82 + PQresetPoll @ 83 + PQresetStart @ 84 + PQsetClientEncoding @ 85 + PQsetnonblocking @ 86 + PQfreeNotify @ 87 + PQescapeString @ 88 + PQescapeBytea @ 89 + printfPQExpBuffer @ 90 + appendPQExpBuffer @ 91 + pg_encoding_to_char @ 92 + pg_utf_mblen @ 93 + PQunescapeBytea @ 94 + PQfreemem @ 95 + PQtransactionStatus @ 96 + PQparameterStatus @ 97 + PQprotocolVersion @ 98 + PQsetErrorVerbosity @ 99 + PQsetNoticeReceiver @ 100 + PQexecParams @ 101 + PQsendQueryParams @ 102 + PQputCopyData @ 103 + PQputCopyEnd @ 104 + PQgetCopyData @ 105 + PQresultErrorField @ 106 + PQftable @ 107 + PQftablecol @ 108 + PQfformat @ 109 + PQexecPrepared @ 110 + PQsendQueryPrepared @ 111 + PQdsplen @ 112 + PQserverVersion @ 113 + PQgetssl @ 114 + pg_char_to_encoding @ 115 + pg_valid_server_encoding @ 116 + pqsignal @ 117 + PQprepare @ 118 + PQsendPrepare @ 119 + PQgetCancel @ 120 + PQfreeCancel @ 121 + PQcancel @ 122 + lo_create @ 123 + PQinitSSL @ 124 + PQregisterThreadLock @ 125 + PQescapeStringConn @ 126 + PQescapeByteaConn @ 127 + PQencryptPassword @ 128 + PQisthreadsafe @ 129 + enlargePQExpBuffer @ 130 + PQnparams @ 131 + PQparamtype @ 132 + PQdescribePrepared @ 133 + PQdescribePortal @ 134 + PQsendDescribePrepared @ 135 + PQsendDescribePortal @ 136 + lo_truncate @ 137 + PQconnectionUsedPassword @ 138 + pg_valid_server_encoding_id @ 139 + PQconnectionNeedsPassword @ 140 + lo_import_with_oid @ 141 + PQcopyResult @ 142 + PQsetResultAttrs @ 143 + PQsetvalue @ 144 + PQresultAlloc @ 145 + PQregisterEventProc @ 146 + PQinstanceData @ 147 + PQsetInstanceData @ 148 + PQresultInstanceData @ 149 + PQresultSetInstanceData @ 150 + PQfireResultCreateEvents @ 151 + PQconninfoParse @ 152 + PQinitOpenSSL @ 153 + PQescapeLiteral @ 154 + PQescapeIdentifier @ 155 + PQconnectdbParams @ 156 + PQconnectStartParams @ 157 + PQping @ 158 + PQpingParams @ 159 + PQlibVersion @ 160 + PQsetSingleRowMode @ 161 diff --git a/src/interfaces/libpq/win32.mak b/src/interfaces/libpq/win32.mak index 70a741a5f..99dbf0a72 100644 --- a/src/interfaces/libpq/win32.mak +++ b/src/interfaces/libpq/win32.mak @@ -30,9 +30,9 @@ ADD_SECLIB=bufferoverflowU.lib OPT=/Od /Zi /MDd LOPT=/DEBUG DEBUGDEF=/D _DEBUG -OUTFILENAME=libpqd +OUTFILENAME=libpq_debug !ELSE -OPT=/O2 /MD +OPT=/O2 /Zi /MD LOPT= DEBUGDEF=/D NDEBUG OUTFILENAME=libpq @@ -181,7 +181,7 @@ pg_config_paths.h: win32.mak CPP_PROJ=/nologo /W3 /EHsc $(OPT) /I "..\..\include" /I "..\..\include\port\win32" /I "..\..\include\port\win32_msvc" /I "..\..\port" /I. /I "$(SSL_INC)" \ /D "FRONTEND" $(DEBUGDEF) \ /D "WIN32" /D "_WINDOWS" /Fp"$(INTDIR)\libpq.pch" \ - /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c \ + /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\$(OUTFILENAME).pdb" /FD /c \ /D "_CRT_SECURE_NO_DEPRECATE" $(ADD_DEFINES) !IFDEF USE_SSL diff --git a/src/pl/plperl/.gitignore b/src/pl/plperl/.gitignore deleted file mode 100644 index 1a798733a..000000000 --- a/src/pl/plperl/.gitignore +++ /dev/null @@ -1,9 +0,0 @@ -/SPI.c -/Util.c -/perlchunks.h -/plperl_opmask.h - -# Generated subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/src/pl/plpgsql/src/.gitignore b/src/pl/plpgsql/src/.gitignore deleted file mode 100644 index 92387fa3c..000000000 --- a/src/pl/plpgsql/src/.gitignore +++ /dev/null @@ -1,3 +0,0 @@ -/pl_gram.c -/pl_gram.h -/plerrcodes.h diff --git a/src/pl/plpgsql/src/pl_gram.c b/src/pl/plpgsql/src/pl_gram.c new file mode 100644 index 000000000..ac36f9e43 --- /dev/null +++ b/src/pl/plpgsql/src/pl_gram.c @@ -0,0 +1,6040 @@ + +/* A Bison parser, made by GNU Bison 2.4.1. */ + +/* Skeleton implementation for Bison's Yacc-like parsers in C + + Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 + Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . */ + +/* As a special exception, you may create a larger work that contains + part or all of the Bison parser skeleton and distribute that work + under terms of your choice, so long as that work isn't itself a + parser generator using the skeleton or a modified version thereof + as a parser skeleton. Alternatively, if you modify or redistribute + the parser skeleton itself, you may (at your option) remove this + special exception, which will cause the skeleton and the resulting + Bison output files to be licensed under the GNU General Public + License without this special exception. + + This special exception was added by the Free Software Foundation in + version 2.2 of Bison. */ + +/* C LALR(1) parser skeleton written by Richard Stallman, by + simplifying the original so-called "semantic" parser. */ + +/* All symbols defined below should begin with yy or YY, to avoid + infringing on user name space. This should be done even for local + variables, as they might otherwise be expanded by user macros. + There are some unavoidable exceptions within include files to + define necessary library symbols; they are noted "INFRINGES ON + USER NAME SPACE" below. */ + +/* Identify Bison output. */ +#define YYBISON 1 + +/* Bison version. */ +#define YYBISON_VERSION "2.4.1" + +/* Skeleton name. */ +#define YYSKELETON_NAME "yacc.c" + +/* Pure parsers. */ +#define YYPURE 0 + +/* Push parsers. */ +#define YYPUSH 0 + +/* Pull parsers. */ +#define YYPULL 1 + +/* Using locations. */ +#define YYLSP_NEEDED 1 + +/* Substitute the variable and function names. */ +#define yyparse plpgsql_yyparse +#define yylex plpgsql_yylex +#define yyerror plpgsql_yyerror +#define yylval plpgsql_yylval +#define yychar plpgsql_yychar +#define yydebug plpgsql_yydebug +#define yynerrs plpgsql_yynerrs +#define yylloc plpgsql_yylloc + +/* Copy the first part of user declarations. */ + +/* Line 189 of yacc.c */ +#line 1 "gram.y" + +/*------------------------------------------------------------------------- + * + * gram.y - Parser for the PL/pgSQL procedural language + * + * Portions Copyright (c) 1996-2012, PostgreSQL Global Development Group + * Portions Copyright (c) 1994, Regents of the University of California + * + * + * IDENTIFICATION + * src/pl/plpgsql/src/gram.y + * + *------------------------------------------------------------------------- + */ + +#include "plpgsql.h" + +#include "catalog/namespace.h" +#include "catalog/pg_type.h" +#include "parser/parser.h" +#include "parser/parse_type.h" +#include "parser/scanner.h" +#include "parser/scansup.h" +#include "utils/builtins.h" + + +/* Location tracking support --- simpler than bison's default */ +#define YYLLOC_DEFAULT(Current, Rhs, N) \ + do { \ + if (N) \ + (Current) = (Rhs)[1]; \ + else \ + (Current) = (Rhs)[0]; \ + } while (0) + +/* + * Bison doesn't allocate anything that needs to live across parser calls, + * so we can easily have it use palloc instead of malloc. This prevents + * memory leaks if we error out during parsing. Note this only works with + * bison >= 2.0. However, in bison 1.875 the default is to use alloca() + * if possible, so there's not really much problem anyhow, at least if + * you're building with gcc. + */ +#define YYMALLOC palloc +#define YYFREE pfree + + +typedef struct +{ + int location; + int leaderlen; +} sql_error_callback_arg; + +#define parser_errposition(pos) plpgsql_scanner_errposition(pos) + +union YYSTYPE; /* need forward reference for tok_is_keyword */ + +static bool tok_is_keyword(int token, union YYSTYPE *lval, + int kw_token, const char *kw_str); +static void word_is_not_variable(PLword *word, int location); +static void cword_is_not_variable(PLcword *cword, int location); +static void current_token_is_not_variable(int tok); +static PLpgSQL_expr *read_sql_construct(int until, + int until2, + int until3, + const char *expected, + const char *sqlstart, + bool isexpression, + bool valid_sql, + bool trim, + int *startloc, + int *endtoken); +static PLpgSQL_expr *read_sql_expression(int until, + const char *expected); +static PLpgSQL_expr *read_sql_expression2(int until, int until2, + const char *expected, + int *endtoken); +static PLpgSQL_expr *read_sql_stmt(const char *sqlstart); +static PLpgSQL_type *read_datatype(int tok); +static PLpgSQL_stmt *make_execsql_stmt(int firsttoken, int location); +static PLpgSQL_stmt_fetch *read_fetch_direction(void); +static void complete_direction(PLpgSQL_stmt_fetch *fetch, + bool *check_FROM); +static PLpgSQL_stmt *make_return_stmt(int location); +static PLpgSQL_stmt *make_return_next_stmt(int location); +static PLpgSQL_stmt *make_return_query_stmt(int location); +static PLpgSQL_stmt *make_case(int location, PLpgSQL_expr *t_expr, + List *case_when_list, List *else_stmts); +static char *NameOfDatum(PLwdatum *wdatum); +static void check_assignable(PLpgSQL_datum *datum, int location); +static void read_into_target(PLpgSQL_rec **rec, PLpgSQL_row **row, + bool *strict); +static PLpgSQL_row *read_into_scalar_list(char *initial_name, + PLpgSQL_datum *initial_datum, + int initial_location); +static PLpgSQL_row *make_scalar_list1(char *initial_name, + PLpgSQL_datum *initial_datum, + int lineno, int location); +static void check_sql_expr(const char *stmt, int location, + int leaderlen); +static void plpgsql_sql_error_callback(void *arg); +static PLpgSQL_type *parse_datatype(const char *string, int location); +static void check_labels(const char *start_label, + const char *end_label, + int end_location); +static PLpgSQL_expr *read_cursor_args(PLpgSQL_var *cursor, + int until, const char *expected); +static List *read_raise_options(void); + + + +/* Line 189 of yacc.c */ +#line 193 "pl_gram.c" + +/* Enabling traces. */ +#ifndef YYDEBUG +# define YYDEBUG 0 +#endif + +/* Enabling verbose error messages. */ +#ifdef YYERROR_VERBOSE +# undef YYERROR_VERBOSE +# define YYERROR_VERBOSE 1 +#else +# define YYERROR_VERBOSE 0 +#endif + +/* Enabling the token table. */ +#ifndef YYTOKEN_TABLE +# define YYTOKEN_TABLE 0 +#endif + + +/* Tokens. */ +#ifndef YYTOKENTYPE +# define YYTOKENTYPE + /* Put the tokens into the symbol table, so that GDB and other debuggers + know about them. */ + enum yytokentype { + IDENT = 258, + FCONST = 259, + SCONST = 260, + BCONST = 261, + XCONST = 262, + Op = 263, + ICONST = 264, + PARAM = 265, + TYPECAST = 266, + DOT_DOT = 267, + COLON_EQUALS = 268, + T_WORD = 269, + T_CWORD = 270, + T_DATUM = 271, + LESS_LESS = 272, + GREATER_GREATER = 273, + K_ABSOLUTE = 274, + K_ALIAS = 275, + K_ALL = 276, + K_ARRAY = 277, + K_BACKWARD = 278, + K_BEGIN = 279, + K_BY = 280, + K_CASE = 281, + K_CLOSE = 282, + K_COLLATE = 283, + K_CONSTANT = 284, + K_CONTINUE = 285, + K_CURRENT = 286, + K_CURSOR = 287, + K_DEBUG = 288, + K_DECLARE = 289, + K_DEFAULT = 290, + K_DETAIL = 291, + K_DIAGNOSTICS = 292, + K_DUMP = 293, + K_ELSE = 294, + K_ELSIF = 295, + K_END = 296, + K_ERRCODE = 297, + K_ERROR = 298, + K_EXCEPTION = 299, + K_EXECUTE = 300, + K_EXIT = 301, + K_FETCH = 302, + K_FIRST = 303, + K_FOR = 304, + K_FOREACH = 305, + K_FORWARD = 306, + K_FROM = 307, + K_GET = 308, + K_HINT = 309, + K_IF = 310, + K_IN = 311, + K_INFO = 312, + K_INSERT = 313, + K_INTO = 314, + K_IS = 315, + K_LAST = 316, + K_LOG = 317, + K_LOOP = 318, + K_MESSAGE = 319, + K_MESSAGE_TEXT = 320, + K_MOVE = 321, + K_NEXT = 322, + K_NO = 323, + K_NOT = 324, + K_NOTICE = 325, + K_NULL = 326, + K_OPEN = 327, + K_OPTION = 328, + K_OR = 329, + K_PERFORM = 330, + K_PG_EXCEPTION_CONTEXT = 331, + K_PG_EXCEPTION_DETAIL = 332, + K_PG_EXCEPTION_HINT = 333, + K_PRIOR = 334, + K_QUERY = 335, + K_RAISE = 336, + K_RELATIVE = 337, + K_RESULT_OID = 338, + K_RETURN = 339, + K_RETURNED_SQLSTATE = 340, + K_REVERSE = 341, + K_ROWTYPE = 342, + K_ROW_COUNT = 343, + K_SCROLL = 344, + K_SLICE = 345, + K_SQLSTATE = 346, + K_STACKED = 347, + K_STRICT = 348, + K_THEN = 349, + K_TO = 350, + K_TYPE = 351, + K_USE_COLUMN = 352, + K_USE_VARIABLE = 353, + K_USING = 354, + K_VARIABLE_CONFLICT = 355, + K_WARNING = 356, + K_WHEN = 357, + K_WHILE = 358 + }; +#endif + + + +#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED +typedef union YYSTYPE +{ + +/* Line 214 of yacc.c */ +#line 116 "gram.y" + + core_YYSTYPE core_yystype; + /* these fields must match core_YYSTYPE: */ + int ival; + char *str; + const char *keyword; + + PLword word; + PLcword cword; + PLwdatum wdatum; + bool boolean; + Oid oid; + struct + { + char *name; + int lineno; + } varname; + struct + { + char *name; + int lineno; + PLpgSQL_datum *scalar; + PLpgSQL_rec *rec; + PLpgSQL_row *row; + } forvariable; + struct + { + char *label; + int n_initvars; + int *initvarnos; + } declhdr; + struct + { + List *stmts; + char *end_label; + int end_label_location; + } loop_body; + List *list; + PLpgSQL_type *dtype; + PLpgSQL_datum *datum; + PLpgSQL_var *var; + PLpgSQL_expr *expr; + PLpgSQL_stmt *stmt; + PLpgSQL_condition *condition; + PLpgSQL_exception *exception; + PLpgSQL_exception_block *exception_block; + PLpgSQL_nsitem *nsitem; + PLpgSQL_diag_item *diagitem; + PLpgSQL_stmt_fetch *fetch; + PLpgSQL_case_when *casewhen; + + + +/* Line 214 of yacc.c */ +#line 386 "pl_gram.c" +} YYSTYPE; +# define YYSTYPE_IS_TRIVIAL 1 +# define yystype YYSTYPE /* obsolescent; will be withdrawn */ +# define YYSTYPE_IS_DECLARED 1 +#endif + +#if ! defined YYLTYPE && ! defined YYLTYPE_IS_DECLARED +typedef struct YYLTYPE +{ + int first_line; + int first_column; + int last_line; + int last_column; +} YYLTYPE; +# define yyltype YYLTYPE /* obsolescent; will be withdrawn */ +# define YYLTYPE_IS_DECLARED 1 +# define YYLTYPE_IS_TRIVIAL 1 +#endif + + +/* Copy the second part of user declarations. */ + + +/* Line 264 of yacc.c */ +#line 411 "pl_gram.c" + +#ifdef short +# undef short +#endif + +#ifdef YYTYPE_UINT8 +typedef YYTYPE_UINT8 yytype_uint8; +#else +typedef unsigned char yytype_uint8; +#endif + +#ifdef YYTYPE_INT8 +typedef YYTYPE_INT8 yytype_int8; +#elif (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +typedef signed char yytype_int8; +#else +typedef short int yytype_int8; +#endif + +#ifdef YYTYPE_UINT16 +typedef YYTYPE_UINT16 yytype_uint16; +#else +typedef unsigned short int yytype_uint16; +#endif + +#ifdef YYTYPE_INT16 +typedef YYTYPE_INT16 yytype_int16; +#else +typedef short int yytype_int16; +#endif + +#ifndef YYSIZE_T +# ifdef __SIZE_TYPE__ +# define YYSIZE_T __SIZE_TYPE__ +# elif defined size_t +# define YYSIZE_T size_t +# elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +# include /* INFRINGES ON USER NAME SPACE */ +# define YYSIZE_T size_t +# else +# define YYSIZE_T unsigned int +# endif +#endif + +#define YYSIZE_MAXIMUM ((YYSIZE_T) -1) + +#ifndef YY_ +# if YYENABLE_NLS +# if ENABLE_NLS +# include /* INFRINGES ON USER NAME SPACE */ +# define YY_(msgid) dgettext ("bison-runtime", msgid) +# endif +# endif +# ifndef YY_ +# define YY_(msgid) msgid +# endif +#endif + +/* Suppress unused-variable warnings by "using" E. */ +#if ! defined lint || defined __GNUC__ +# define YYUSE(e) ((void) (e)) +#else +# define YYUSE(e) /* empty */ +#endif + +/* Identity function, used to suppress warnings about constant conditions. */ +#ifndef lint +# define YYID(n) (n) +#else +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static int +YYID (int yyi) +#else +static int +YYID (yyi) + int yyi; +#endif +{ + return yyi; +} +#endif + +#if ! defined yyoverflow || YYERROR_VERBOSE + +/* The parser invokes alloca or malloc; define the necessary symbols. */ + +# ifdef YYSTACK_USE_ALLOCA +# if YYSTACK_USE_ALLOCA +# ifdef __GNUC__ +# define YYSTACK_ALLOC __builtin_alloca +# elif defined __BUILTIN_VA_ARG_INCR +# include /* INFRINGES ON USER NAME SPACE */ +# elif defined _AIX +# define YYSTACK_ALLOC __alloca +# elif defined _MSC_VER +# include /* INFRINGES ON USER NAME SPACE */ +# define alloca _alloca +# else +# define YYSTACK_ALLOC alloca +# if ! defined _ALLOCA_H && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +# include /* INFRINGES ON USER NAME SPACE */ +# ifndef _STDLIB_H +# define _STDLIB_H 1 +# endif +# endif +# endif +# endif +# endif + +# ifdef YYSTACK_ALLOC + /* Pacify GCC's `empty if-body' warning. */ +# define YYSTACK_FREE(Ptr) do { /* empty */; } while (YYID (0)) +# ifndef YYSTACK_ALLOC_MAXIMUM + /* The OS might guarantee only one guard page at the bottom of the stack, + and a page size can be as small as 4096 bytes. So we cannot safely + invoke alloca (N) if N exceeds 4096. Use a slightly smaller number + to allow for a few compiler-allocated temporary stack slots. */ +# define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */ +# endif +# else +# define YYSTACK_ALLOC YYMALLOC +# define YYSTACK_FREE YYFREE +# ifndef YYSTACK_ALLOC_MAXIMUM +# define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM +# endif +# if (defined __cplusplus && ! defined _STDLIB_H \ + && ! ((defined YYMALLOC || defined malloc) \ + && (defined YYFREE || defined free))) +# include /* INFRINGES ON USER NAME SPACE */ +# ifndef _STDLIB_H +# define _STDLIB_H 1 +# endif +# endif +# ifndef YYMALLOC +# define YYMALLOC malloc +# if ! defined malloc && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */ +# endif +# endif +# ifndef YYFREE +# define YYFREE free +# if ! defined free && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +void free (void *); /* INFRINGES ON USER NAME SPACE */ +# endif +# endif +# endif +#endif /* ! defined yyoverflow || YYERROR_VERBOSE */ + + +#if (! defined yyoverflow \ + && (! defined __cplusplus \ + || (defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL \ + && defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) + +/* A type that is properly aligned for any stack member. */ +union yyalloc +{ + yytype_int16 yyss_alloc; + YYSTYPE yyvs_alloc; + YYLTYPE yyls_alloc; +}; + +/* The size of the maximum gap between one aligned stack and the next. */ +# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1) + +/* The size of an array large to enough to hold all stacks, each with + N elements. */ +# define YYSTACK_BYTES(N) \ + ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE) + sizeof (YYLTYPE)) \ + + 2 * YYSTACK_GAP_MAXIMUM) + +/* Copy COUNT objects from FROM to TO. The source and destination do + not overlap. */ +# ifndef YYCOPY +# if defined __GNUC__ && 1 < __GNUC__ +# define YYCOPY(To, From, Count) \ + __builtin_memcpy (To, From, (Count) * sizeof (*(From))) +# else +# define YYCOPY(To, From, Count) \ + do \ + { \ + YYSIZE_T yyi; \ + for (yyi = 0; yyi < (Count); yyi++) \ + (To)[yyi] = (From)[yyi]; \ + } \ + while (YYID (0)) +# endif +# endif + +/* Relocate STACK from its old location to the new one. The + local variables YYSIZE and YYSTACKSIZE give the old and new number of + elements in the stack, and YYPTR gives the new location of the + stack. Advance YYPTR to a properly aligned location for the next + stack. */ +# define YYSTACK_RELOCATE(Stack_alloc, Stack) \ + do \ + { \ + YYSIZE_T yynewbytes; \ + YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \ + Stack = &yyptr->Stack_alloc; \ + yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ + yyptr += yynewbytes / sizeof (*yyptr); \ + } \ + while (YYID (0)) + +#endif + +/* YYFINAL -- State number of the termination state. */ +#define YYFINAL 3 +/* YYLAST -- Last index in YYTABLE. */ +#define YYLAST 577 + +/* YYNTOKENS -- Number of terminals. */ +#define YYNTOKENS 111 +/* YYNNTS -- Number of nonterminals. */ +#define YYNNTS 83 +/* YYNRULES -- Number of rules. */ +#define YYNRULES 199 +/* YYNRULES -- Number of states. */ +#define YYNSTATES 276 + +/* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */ +#define YYUNDEFTOK 2 +#define YYMAXUTOK 358 + +#define YYTRANSLATE(YYX) \ + ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) + +/* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */ +static const yytype_uint8 yytranslate[] = +{ + 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 104, 2, 2, 2, 2, + 106, 107, 2, 2, 108, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 105, + 2, 109, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 110, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 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, 92, 93, 94, + 95, 96, 97, 98, 99, 100, 101, 102, 103 +}; + +#if YYDEBUG +/* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in + YYRHS. */ +static const yytype_uint16 yyprhs[] = +{ + 0, 0, 3, 7, 8, 11, 15, 19, 23, 27, + 28, 30, 37, 39, 42, 46, 48, 51, 53, 55, + 57, 61, 68, 74, 75, 83, 84, 87, 89, 90, + 91, 95, 97, 101, 104, 106, 108, 110, 112, 114, + 116, 117, 119, 120, 121, 124, 127, 128, 131, 133, + 135, 137, 139, 141, 143, 144, 146, 149, 151, 154, + 156, 158, 160, 162, 164, 166, 168, 170, 172, 174, + 176, 178, 180, 182, 184, 186, 188, 190, 192, 195, + 199, 205, 206, 208, 210, 214, 216, 220, 221, 223, + 225, 227, 229, 233, 242, 243, 248, 249, 252, 260, + 261, 264, 266, 270, 271, 274, 278, 283, 288, 291, + 293, 295, 297, 306, 307, 310, 314, 316, 318, 320, + 322, 328, 330, 332, 334, 336, 339, 344, 349, 350, + 354, 357, 359, 361, 363, 364, 365, 369, 372, 374, + 379, 383, 385, 387, 388, 389, 390, 391, 392, 396, + 397, 399, 401, 404, 406, 408, 410, 412, 414, 416, + 418, 420, 422, 424, 426, 428, 430, 432, 434, 436, + 438, 440, 442, 444, 446, 448, 450, 452, 454, 456, + 458, 460, 462, 464, 466, 468, 470, 472, 474, 476, + 478, 480, 482, 484, 486, 488, 490, 492, 494, 496 +}; + +/* YYRHS -- A `-1'-separated list of the rules' RHS. */ +static const yytype_int16 yyrhs[] = +{ + 112, 0, -1, 113, 116, 115, -1, -1, 113, 114, + -1, 104, 73, 38, -1, 104, 100, 43, -1, 104, + 100, 98, -1, 104, 100, 97, -1, -1, 105, -1, + 117, 24, 138, 179, 41, 190, -1, 189, -1, 189, + 118, -1, 189, 118, 119, -1, 34, -1, 119, 120, + -1, 120, -1, 121, -1, 34, -1, 17, 192, 18, + -1, 130, 131, 132, 133, 134, 135, -1, 130, 20, + 49, 129, 105, -1, -1, 130, 123, 32, 122, 125, + 128, 124, -1, -1, 68, 89, -1, 89, -1, -1, + -1, 106, 126, 107, -1, 127, -1, 126, 108, 127, + -1, 130, 132, -1, 60, -1, 49, -1, 14, -1, + 15, -1, 14, -1, 193, -1, -1, 29, -1, -1, + -1, 28, 14, -1, 28, 15, -1, -1, 69, 71, + -1, 105, -1, 136, -1, 137, -1, 35, -1, 109, + -1, 13, -1, -1, 139, -1, 139, 140, -1, 140, + -1, 116, 105, -1, 142, -1, 150, -1, 153, -1, + 158, -1, 159, -1, 160, -1, 163, -1, 165, -1, + 167, -1, 168, -1, 170, -1, 171, -1, 141, -1, + 143, -1, 172, -1, 173, -1, 174, -1, 176, -1, + 177, -1, 75, 185, -1, 149, 137, 185, -1, 53, + 144, 37, 145, 105, -1, -1, 31, -1, 92, -1, + 145, 108, 146, -1, 146, -1, 148, 137, 147, -1, + -1, 16, -1, 14, -1, 15, -1, 16, -1, 149, + 110, 186, -1, 55, 187, 138, 151, 152, 41, 55, + 105, -1, -1, 151, 40, 187, 138, -1, -1, 39, + 138, -1, 26, 154, 155, 157, 41, 26, 105, -1, + -1, 155, 156, -1, 156, -1, 102, 187, 138, -1, + -1, 39, 138, -1, 189, 63, 169, -1, 189, 103, + 188, 169, -1, 189, 49, 161, 169, -1, 162, 56, + -1, 16, -1, 14, -1, 15, -1, 189, 50, 162, + 164, 56, 22, 188, 169, -1, -1, 90, 9, -1, + 166, 190, 191, -1, 46, -1, 30, -1, 84, -1, + 81, -1, 138, 41, 63, 190, 105, -1, 58, -1, + 14, -1, 15, -1, 45, -1, 72, 178, -1, 47, + 175, 178, 59, -1, 66, 175, 178, 105, -1, -1, + 27, 178, 105, -1, 71, 105, -1, 16, -1, 14, + -1, 15, -1, -1, -1, 44, 180, 181, -1, 181, + 182, -1, 182, -1, 102, 183, 94, 138, -1, 183, + 74, 184, -1, 184, -1, 192, -1, -1, -1, -1, + -1, -1, 17, 192, 18, -1, -1, 192, -1, 105, + -1, 102, 185, -1, 14, -1, 16, -1, 19, -1, + 20, -1, 22, -1, 23, -1, 29, -1, 31, -1, + 32, -1, 33, -1, 36, -1, 38, -1, 42, -1, + 43, -1, 48, -1, 51, -1, 54, -1, 57, -1, + 60, -1, 61, -1, 62, -1, 64, -1, 65, -1, + 67, -1, 68, -1, 70, -1, 73, -1, 76, -1, + 77, -1, 78, -1, 79, -1, 80, -1, 82, -1, + 83, -1, 85, -1, 86, -1, 88, -1, 87, -1, + 89, -1, 90, -1, 91, -1, 92, -1, 96, -1, + 97, -1, 98, -1, 100, -1, 101, -1 +}; + +/* YYRLINE[YYN] -- source line where rule number YYN was defined. */ +static const yytype_uint16 yyrline[] = +{ + 0, 332, 332, 338, 339, 342, 346, 350, 354, 360, + 361, 364, 386, 394, 401, 410, 422, 423, 426, 427, + 431, 444, 499, 505, 504, 557, 560, 564, 571, 577, + 580, 609, 613, 619, 627, 628, 630, 645, 673, 686, + 702, 703, 708, 719, 720, 725, 732, 733, 737, 739, + 745, 746, 749, 750, 754, 755, 759, 766, 775, 777, + 779, 781, 783, 785, 787, 789, 791, 793, 795, 797, + 799, 801, 803, 805, 807, 809, 811, 813, 817, 830, + 844, 899, 902, 906, 912, 916, 922, 935, 964, 976, + 981, 989, 994, 1011, 1028, 1031, 1045, 1048, 1054, 1061, + 1075, 1079, 1085, 1097, 1100, 1115, 1132, 1150, 1184, 1446, + 1478, 1493, 1500, 1543, 1546, 1552, 1567, 1571, 1577, 1603, + 1742, 1760, 1764, 1774, 1786, 1850, 1927, 1959, 1972, 1977, + 1990, 1997, 2013, 2018, 2026, 2028, 2027, 2067, 2071, 2077, + 2090, 2099, 2105, 2142, 2146, 2150, 2154, 2158, 2162, 2170, + 2173, 2181, 2183, 2190, 2194, 2203, 2204, 2205, 2206, 2207, + 2208, 2209, 2210, 2211, 2212, 2213, 2214, 2215, 2216, 2217, + 2218, 2219, 2220, 2221, 2222, 2223, 2224, 2225, 2226, 2227, + 2228, 2229, 2230, 2231, 2232, 2233, 2234, 2235, 2236, 2237, + 2238, 2239, 2240, 2241, 2242, 2243, 2244, 2245, 2246, 2247 +}; +#endif + +#if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE +/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM. + First, the terminals, then, starting at YYNTOKENS, nonterminals. */ +static const char *const yytname[] = +{ + "$end", "error", "$undefined", "IDENT", "FCONST", "SCONST", "BCONST", + "XCONST", "Op", "ICONST", "PARAM", "TYPECAST", "DOT_DOT", "COLON_EQUALS", + "T_WORD", "T_CWORD", "T_DATUM", "LESS_LESS", "GREATER_GREATER", + "K_ABSOLUTE", "K_ALIAS", "K_ALL", "K_ARRAY", "K_BACKWARD", "K_BEGIN", + "K_BY", "K_CASE", "K_CLOSE", "K_COLLATE", "K_CONSTANT", "K_CONTINUE", + "K_CURRENT", "K_CURSOR", "K_DEBUG", "K_DECLARE", "K_DEFAULT", "K_DETAIL", + "K_DIAGNOSTICS", "K_DUMP", "K_ELSE", "K_ELSIF", "K_END", "K_ERRCODE", + "K_ERROR", "K_EXCEPTION", "K_EXECUTE", "K_EXIT", "K_FETCH", "K_FIRST", + "K_FOR", "K_FOREACH", "K_FORWARD", "K_FROM", "K_GET", "K_HINT", "K_IF", + "K_IN", "K_INFO", "K_INSERT", "K_INTO", "K_IS", "K_LAST", "K_LOG", + "K_LOOP", "K_MESSAGE", "K_MESSAGE_TEXT", "K_MOVE", "K_NEXT", "K_NO", + "K_NOT", "K_NOTICE", "K_NULL", "K_OPEN", "K_OPTION", "K_OR", "K_PERFORM", + "K_PG_EXCEPTION_CONTEXT", "K_PG_EXCEPTION_DETAIL", "K_PG_EXCEPTION_HINT", + "K_PRIOR", "K_QUERY", "K_RAISE", "K_RELATIVE", "K_RESULT_OID", + "K_RETURN", "K_RETURNED_SQLSTATE", "K_REVERSE", "K_ROWTYPE", + "K_ROW_COUNT", "K_SCROLL", "K_SLICE", "K_SQLSTATE", "K_STACKED", + "K_STRICT", "K_THEN", "K_TO", "K_TYPE", "K_USE_COLUMN", "K_USE_VARIABLE", + "K_USING", "K_VARIABLE_CONFLICT", "K_WARNING", "K_WHEN", "K_WHILE", + "'#'", "';'", "'('", "')'", "','", "'='", "'['", "$accept", + "pl_function", "comp_options", "comp_option", "opt_semi", "pl_block", + "decl_sect", "decl_start", "decl_stmts", "decl_stmt", "decl_statement", + "$@1", "opt_scrollable", "decl_cursor_query", "decl_cursor_args", + "decl_cursor_arglist", "decl_cursor_arg", "decl_is_for", + "decl_aliasitem", "decl_varname", "decl_const", "decl_datatype", + "decl_collate", "decl_notnull", "decl_defval", "decl_defkey", + "assign_operator", "proc_sect", "proc_stmts", "proc_stmt", + "stmt_perform", "stmt_assign", "stmt_getdiag", "getdiag_area_opt", + "getdiag_list", "getdiag_list_item", "getdiag_item", "getdiag_target", + "assign_var", "stmt_if", "stmt_elsifs", "stmt_else", "stmt_case", + "opt_expr_until_when", "case_when_list", "case_when", "opt_case_else", + "stmt_loop", "stmt_while", "stmt_for", "for_control", "for_variable", + "stmt_foreach_a", "foreach_slice", "stmt_exit", "exit_type", + "stmt_return", "stmt_raise", "loop_body", "stmt_execsql", + "stmt_dynexecute", "stmt_open", "stmt_fetch", "stmt_move", + "opt_fetch_direction", "stmt_close", "stmt_null", "cursor_variable", + "exception_sect", "@2", "proc_exceptions", "proc_exception", + "proc_conditions", "proc_condition", "expr_until_semi", + "expr_until_rightbracket", "expr_until_then", "expr_until_loop", + "opt_block_label", "opt_label", "opt_exitcond", "any_identifier", + "unreserved_keyword", 0 +}; +#endif + +# ifdef YYPRINT +/* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to + token YYLEX-NUM. */ +static const yytype_uint16 yytoknum[] = +{ + 0, 256, 257, 258, 259, 260, 261, 262, 263, 264, + 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, + 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, + 285, 286, 287, 288, 289, 290, 291, 292, 293, 294, + 295, 296, 297, 298, 299, 300, 301, 302, 303, 304, + 305, 306, 307, 308, 309, 310, 311, 312, 313, 314, + 315, 316, 317, 318, 319, 320, 321, 322, 323, 324, + 325, 326, 327, 328, 329, 330, 331, 332, 333, 334, + 335, 336, 337, 338, 339, 340, 341, 342, 343, 344, + 345, 346, 347, 348, 349, 350, 351, 352, 353, 354, + 355, 356, 357, 358, 35, 59, 40, 41, 44, 61, + 91 +}; +# endif + +/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ +static const yytype_uint8 yyr1[] = +{ + 0, 111, 112, 113, 113, 114, 114, 114, 114, 115, + 115, 116, 117, 117, 117, 118, 119, 119, 120, 120, + 120, 121, 121, 122, 121, 123, 123, 123, 124, 125, + 125, 126, 126, 127, 128, 128, 129, 129, 130, 130, + 131, 131, 132, 133, 133, 133, 134, 134, 135, 135, + 136, 136, 137, 137, 138, 138, 139, 139, 140, 140, + 140, 140, 140, 140, 140, 140, 140, 140, 140, 140, + 140, 140, 140, 140, 140, 140, 140, 140, 141, 142, + 143, 144, 144, 144, 145, 145, 146, 147, 148, 148, + 148, 149, 149, 150, 151, 151, 152, 152, 153, 154, + 155, 155, 156, 157, 157, 158, 159, 160, 161, 162, + 162, 162, 163, 164, 164, 165, 166, 166, 167, 168, + 169, 170, 170, 170, 171, 172, 173, 174, 175, 176, + 177, 178, 178, 178, 179, 180, 179, 181, 181, 182, + 183, 183, 184, 185, 186, 187, 188, 189, 189, 190, + 190, 191, 191, 192, 192, 193, 193, 193, 193, 193, + 193, 193, 193, 193, 193, 193, 193, 193, 193, 193, + 193, 193, 193, 193, 193, 193, 193, 193, 193, 193, + 193, 193, 193, 193, 193, 193, 193, 193, 193, 193, + 193, 193, 193, 193, 193, 193, 193, 193, 193, 193 +}; + +/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */ +static const yytype_uint8 yyr2[] = +{ + 0, 2, 3, 0, 2, 3, 3, 3, 3, 0, + 1, 6, 1, 2, 3, 1, 2, 1, 1, 1, + 3, 6, 5, 0, 7, 0, 2, 1, 0, 0, + 3, 1, 3, 2, 1, 1, 1, 1, 1, 1, + 0, 1, 0, 0, 2, 2, 0, 2, 1, 1, + 1, 1, 1, 1, 0, 1, 2, 1, 2, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 2, 3, + 5, 0, 1, 1, 3, 1, 3, 0, 1, 1, + 1, 1, 3, 8, 0, 4, 0, 2, 7, 0, + 2, 1, 3, 0, 2, 3, 4, 4, 2, 1, + 1, 1, 8, 0, 2, 3, 1, 1, 1, 1, + 5, 1, 1, 1, 1, 2, 4, 4, 0, 3, + 2, 1, 1, 1, 0, 0, 3, 2, 1, 4, + 3, 1, 1, 0, 0, 0, 0, 0, 3, 0, + 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 +}; + +/* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state + STATE-NUM when YYTABLE doesn't specify something else to do. Zero + means the default is an error. */ +static const yytype_uint8 yydefact[] = +{ + 3, 0, 147, 1, 0, 0, 4, 9, 0, 12, + 153, 154, 0, 0, 0, 10, 2, 147, 15, 13, + 148, 5, 6, 8, 7, 122, 123, 91, 99, 0, + 117, 124, 116, 128, 81, 145, 121, 128, 0, 0, + 143, 119, 118, 0, 134, 147, 57, 71, 59, 72, + 0, 60, 61, 62, 63, 64, 65, 66, 149, 67, + 68, 69, 70, 73, 74, 75, 76, 77, 12, 38, + 0, 155, 156, 157, 158, 159, 160, 161, 162, 19, + 163, 164, 165, 166, 167, 168, 169, 170, 171, 172, + 173, 174, 175, 176, 177, 178, 179, 180, 181, 182, + 183, 184, 185, 186, 187, 188, 190, 189, 191, 192, + 193, 194, 195, 196, 197, 198, 199, 14, 17, 18, + 40, 39, 0, 132, 133, 131, 0, 0, 82, 83, + 0, 147, 0, 130, 125, 78, 58, 135, 0, 56, + 53, 52, 144, 143, 0, 150, 0, 0, 147, 146, + 0, 16, 0, 41, 0, 27, 0, 42, 145, 103, + 101, 129, 0, 0, 94, 0, 0, 149, 92, 79, + 143, 151, 115, 110, 111, 109, 147, 0, 113, 0, + 105, 147, 20, 0, 26, 23, 43, 147, 147, 100, + 0, 126, 89, 90, 88, 0, 85, 0, 96, 127, + 0, 136, 138, 11, 152, 107, 108, 0, 0, 0, + 106, 36, 37, 0, 29, 0, 46, 102, 104, 0, + 80, 0, 87, 147, 145, 0, 0, 141, 142, 137, + 114, 0, 149, 22, 0, 0, 44, 45, 0, 0, + 0, 84, 86, 97, 147, 0, 0, 147, 146, 0, + 0, 31, 42, 35, 34, 28, 47, 51, 48, 21, + 49, 50, 98, 95, 0, 140, 139, 147, 120, 30, + 0, 33, 24, 93, 112, 32 +}; + +/* YYDEFGOTO[NTERM-NUM]. */ +static const yytype_int16 yydefgoto[] = +{ + -1, 1, 2, 6, 16, 43, 8, 19, 117, 118, + 119, 214, 156, 272, 235, 250, 251, 255, 213, 120, + 157, 186, 216, 239, 259, 260, 143, 179, 45, 46, + 47, 48, 49, 130, 195, 196, 242, 197, 50, 51, + 198, 225, 52, 122, 159, 160, 190, 53, 54, 55, + 176, 177, 56, 208, 57, 58, 59, 60, 180, 61, + 62, 63, 64, 65, 127, 66, 67, 126, 138, 166, + 201, 202, 226, 227, 135, 168, 131, 181, 68, 144, + 172, 145, 121 +}; + +/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing + STATE-NUM. */ +#define YYPACT_NINF -221 +static const yytype_int16 yypact[] = +{ + -221, 30, 6, -221, 22, -61, -221, -62, 36, 31, + -221, -221, 51, 55, -18, -221, -221, 446, -221, 226, + -221, -221, -221, -221, -221, -221, -221, -221, -221, 48, + -221, -221, -221, -221, -21, -221, -221, -221, -31, 48, + -221, -221, -221, -24, 69, 1, -221, -221, -221, -221, + -11, -221, -221, -221, -221, -221, -221, -221, 22, -221, + -221, -221, -221, -221, -221, -221, -221, -221, -28, -221, + 22, -221, -221, -221, -221, -221, -221, -221, -221, -221, + -221, -221, -221, -221, -221, -221, -221, -221, -221, -221, + -221, -221, -221, -221, -221, -221, -221, -221, -221, -221, + -221, -221, -221, -221, -221, -221, -221, -221, -221, -221, + -221, -221, -221, -221, -221, -221, -221, 226, -221, -221, + 0, -221, -7, -221, -221, -221, 9, 48, -221, -221, + 79, 399, 48, -221, -221, -221, -221, -221, 80, -221, + -221, -221, -221, -221, -68, -221, 72, 72, 493, -221, + 99, -221, 71, -221, 34, -221, 93, -221, -221, -32, + -221, -221, 65, 76, -221, 21, 25, 22, -221, -221, + -221, -221, -221, -221, -221, -221, 493, 73, 38, 89, + -221, 493, -221, 43, -221, -221, 104, 92, 493, -221, + 94, -221, -221, -221, -221, -56, -221, -8, 44, -221, + 22, 25, -221, -221, -221, -221, -221, 125, 84, 78, + -221, -221, -221, 37, 40, 90, 67, -221, -221, 117, + -221, 76, -221, 493, -221, 103, -41, -221, -221, -221, + -221, 126, 22, -221, 311, -5, -221, -221, 81, -9, + 46, -221, -221, -221, 399, 98, 22, 163, -221, 49, + 4, -221, -221, -221, -221, -221, -221, -221, -221, -221, + -221, -221, -221, -221, 50, -221, -221, 493, -221, -221, + 311, -221, -221, -221, -221, -221 +}; + +/* YYPGOTO[NTERM-NUM]. */ +static const yytype_int16 yypgoto[] = +{ + -221, -221, -221, -221, -221, 147, -221, -221, -221, 39, + -221, -221, -221, -221, -221, -221, -113, -221, -221, -220, + -221, -93, -221, -221, -221, -221, -178, -16, -221, 115, + -221, -221, -221, -221, -221, -60, -221, -221, -221, -221, + -221, -221, -221, -221, -221, 3, -221, -221, -221, -221, + -221, 18, -221, -221, -221, -221, -221, -221, -173, -221, + -221, -221, -221, -221, 129, -221, -221, -30, -221, -221, + -221, -33, -221, -77, -119, -221, -147, -78, 172, -154, + -221, -4, -221 +}; + +/* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If + positive, shift that token. If negative, reduce the rule which + number is the opposite. If zero, do what YYDEFACT says. + If YYTABLE_NINF, syntax error. */ +#define YYTABLE_NINF -56 +static const yytype_int16 yytable[] = +{ + 12, 44, 140, 205, 140, 140, 18, 188, 210, 134, + 128, 187, 13, 203, 252, 25, 26, 27, 4, 222, + 152, 146, 147, 4, 169, 22, 257, 28, 29, 153, + 3, 30, -25, 246, 170, 148, 10, 171, 11, 14, + -55, -55, -55, 15, 253, -55, 31, 32, 33, 220, + 252, 204, 221, 247, 34, 254, 35, 211, 212, 36, + 17, 261, 123, 124, 125, 18, 150, 37, 154, 20, + 158, 129, 38, 39, 133, 149, 40, 244, 249, 23, + 24, 136, 41, 223, 224, 42, 173, 174, 175, 155, + 192, 193, 194, 21, 274, 158, 258, 162, 141, 142, + 141, 141, 165, -55, 236, 237, 25, 26, 27, 4, + 5, 269, 270, 137, 161, 164, 163, 182, 28, 29, + 183, 167, 30, 184, 191, 185, 199, 200, 207, 206, + 209, -54, 215, -54, 230, 219, 238, 31, 32, 33, + 231, 232, 233, 240, 245, 34, 234, 35, 248, 7, + 36, 262, 256, 264, 268, 273, 151, 275, 37, 271, + 139, 241, 189, 38, 39, 178, 132, 40, 229, 265, + 267, 217, 218, 41, 9, 0, 42, 25, 26, 27, + 4, 0, 0, 0, 0, 0, 0, 0, 0, 28, + 29, 0, 0, 30, -54, 0, 228, 0, 0, 0, + 0, 0, 0, 0, -54, 0, 0, 243, 31, 32, + 33, 0, 0, 0, 0, 0, 34, 0, 35, 0, + 0, 36, 0, 0, 0, 0, 0, 0, 263, 37, + 0, 266, 0, 0, 38, 39, 0, 0, 40, 0, + 69, 0, 228, 70, 41, 71, 72, 42, 73, 74, + 0, 0, 0, 0, 0, 75, 0, 76, 77, 78, + 79, 0, 80, 0, 81, -54, 0, 0, 82, 83, + 0, 0, 0, 0, 84, 0, 0, 85, 0, 0, + 86, 0, 0, 87, 0, 0, 88, 89, 90, 0, + 91, 92, 0, 93, 94, 0, 95, 0, 0, 96, + 0, 0, 97, 98, 99, 100, 101, 0, 102, 103, + 0, 104, 105, 106, 107, 108, 109, 110, 111, 0, + 0, 0, 112, 113, 114, 69, 115, 116, 0, 0, + 71, 72, 0, 73, 74, 0, 0, 0, 0, 0, + 75, 0, 76, 77, 78, 0, 0, 80, 0, 81, + 0, 0, 0, 82, 83, 0, 0, 0, 0, 84, + 0, 0, 85, 0, 0, 86, 0, 0, 87, 0, + 0, 88, 89, 90, 0, 91, 92, 0, 93, 94, + 0, 95, 0, 0, 96, 0, 0, 97, 98, 99, + 100, 101, 0, 102, 103, 0, 104, 105, 106, 107, + 108, 109, 110, 111, 0, 0, 0, 112, 113, 114, + 0, 115, 116, 25, 26, 27, 4, 0, 0, 0, + 0, 0, 0, 0, 0, 28, 29, 0, 0, 30, + 0, 0, 0, 0, 0, 0, 0, 0, -54, -54, + -54, 0, 0, 0, 31, 32, 33, 0, 0, 0, + 0, 0, 34, 0, 35, 0, 0, 36, 0, 0, + 25, 26, 27, 4, 0, 37, 0, 0, 0, 0, + 38, 39, 28, 29, 40, 0, 30, 0, 0, 0, + 41, 0, 0, 42, 0, 0, 0, -54, 0, 0, + -54, 31, 32, 33, 0, 0, 0, 0, 0, 34, + 0, 35, 0, 0, 36, 0, 0, 25, 26, 27, + 4, 0, 37, 0, 0, 0, 0, 38, 39, 28, + 29, 40, 0, 30, 0, 0, 0, 41, 0, 0, + 42, 0, 0, 0, -54, 0, 0, 0, 31, 32, + 33, 0, 0, 0, 0, 0, 34, 0, 35, 0, + 0, 36, 0, 0, 0, 0, 0, 0, 0, 37, + 0, 0, 0, 0, 38, 39, 0, 0, 40, 0, + 0, 0, 0, 0, 41, 0, 0, 42 +}; + +static const yytype_int16 yycheck[] = +{ + 4, 17, 13, 176, 13, 13, 34, 39, 181, 39, + 31, 158, 73, 167, 234, 14, 15, 16, 17, 197, + 20, 49, 50, 17, 143, 43, 35, 26, 27, 29, + 0, 30, 32, 74, 102, 63, 14, 105, 16, 100, + 39, 40, 41, 105, 49, 44, 45, 46, 47, 105, + 270, 170, 108, 94, 53, 60, 55, 14, 15, 58, + 24, 239, 14, 15, 16, 34, 70, 66, 68, 18, + 102, 92, 71, 72, 105, 103, 75, 224, 232, 97, + 98, 105, 81, 39, 40, 84, 14, 15, 16, 89, + 14, 15, 16, 38, 267, 102, 105, 127, 109, 110, + 109, 109, 132, 102, 14, 15, 14, 15, 16, 17, + 104, 107, 108, 44, 105, 131, 37, 18, 26, 27, + 49, 41, 30, 89, 59, 32, 105, 102, 90, 56, + 41, 39, 28, 41, 9, 41, 69, 45, 46, 47, + 56, 63, 105, 26, 41, 53, 106, 55, 22, 2, + 58, 105, 71, 55, 105, 105, 117, 270, 66, 252, + 45, 221, 159, 71, 72, 147, 37, 75, 201, 246, + 248, 187, 188, 81, 2, -1, 84, 14, 15, 16, + 17, -1, -1, -1, -1, -1, -1, -1, -1, 26, + 27, -1, -1, 30, 102, -1, 200, -1, -1, -1, + -1, -1, -1, -1, 41, -1, -1, 223, 45, 46, + 47, -1, -1, -1, -1, -1, 53, -1, 55, -1, + -1, 58, -1, -1, -1, -1, -1, -1, 244, 66, + -1, 247, -1, -1, 71, 72, -1, -1, 75, -1, + 14, -1, 246, 17, 81, 19, 20, 84, 22, 23, + -1, -1, -1, -1, -1, 29, -1, 31, 32, 33, + 34, -1, 36, -1, 38, 102, -1, -1, 42, 43, + -1, -1, -1, -1, 48, -1, -1, 51, -1, -1, + 54, -1, -1, 57, -1, -1, 60, 61, 62, -1, + 64, 65, -1, 67, 68, -1, 70, -1, -1, 73, + -1, -1, 76, 77, 78, 79, 80, -1, 82, 83, + -1, 85, 86, 87, 88, 89, 90, 91, 92, -1, + -1, -1, 96, 97, 98, 14, 100, 101, -1, -1, + 19, 20, -1, 22, 23, -1, -1, -1, -1, -1, + 29, -1, 31, 32, 33, -1, -1, 36, -1, 38, + -1, -1, -1, 42, 43, -1, -1, -1, -1, 48, + -1, -1, 51, -1, -1, 54, -1, -1, 57, -1, + -1, 60, 61, 62, -1, 64, 65, -1, 67, 68, + -1, 70, -1, -1, 73, -1, -1, 76, 77, 78, + 79, 80, -1, 82, 83, -1, 85, 86, 87, 88, + 89, 90, 91, 92, -1, -1, -1, 96, 97, 98, + -1, 100, 101, 14, 15, 16, 17, -1, -1, -1, + -1, -1, -1, -1, -1, 26, 27, -1, -1, 30, + -1, -1, -1, -1, -1, -1, -1, -1, 39, 40, + 41, -1, -1, -1, 45, 46, 47, -1, -1, -1, + -1, -1, 53, -1, 55, -1, -1, 58, -1, -1, + 14, 15, 16, 17, -1, 66, -1, -1, -1, -1, + 71, 72, 26, 27, 75, -1, 30, -1, -1, -1, + 81, -1, -1, 84, -1, -1, -1, 41, -1, -1, + 44, 45, 46, 47, -1, -1, -1, -1, -1, 53, + -1, 55, -1, -1, 58, -1, -1, 14, 15, 16, + 17, -1, 66, -1, -1, -1, -1, 71, 72, 26, + 27, 75, -1, 30, -1, -1, -1, 81, -1, -1, + 84, -1, -1, -1, 41, -1, -1, -1, 45, 46, + 47, -1, -1, -1, -1, -1, 53, -1, 55, -1, + -1, 58, -1, -1, -1, -1, -1, -1, -1, 66, + -1, -1, -1, -1, 71, 72, -1, -1, 75, -1, + -1, -1, -1, -1, 81, -1, -1, 84 +}; + +/* YYSTOS[STATE-NUM] -- The (internal number of the) accessing + symbol of state STATE-NUM. */ +static const yytype_uint8 yystos[] = +{ + 0, 112, 113, 0, 17, 104, 114, 116, 117, 189, + 14, 16, 192, 73, 100, 105, 115, 24, 34, 118, + 18, 38, 43, 97, 98, 14, 15, 16, 26, 27, + 30, 45, 46, 47, 53, 55, 58, 66, 71, 72, + 75, 81, 84, 116, 138, 139, 140, 141, 142, 143, + 149, 150, 153, 158, 159, 160, 163, 165, 166, 167, + 168, 170, 171, 172, 173, 174, 176, 177, 189, 14, + 17, 19, 20, 22, 23, 29, 31, 32, 33, 34, + 36, 38, 42, 43, 48, 51, 54, 57, 60, 61, + 62, 64, 65, 67, 68, 70, 73, 76, 77, 78, + 79, 80, 82, 83, 85, 86, 87, 88, 89, 90, + 91, 92, 96, 97, 98, 100, 101, 119, 120, 121, + 130, 193, 154, 14, 15, 16, 178, 175, 31, 92, + 144, 187, 175, 105, 178, 185, 105, 44, 179, 140, + 13, 109, 110, 137, 190, 192, 49, 50, 63, 103, + 192, 120, 20, 29, 68, 89, 123, 131, 102, 155, + 156, 105, 178, 37, 138, 178, 180, 41, 186, 185, + 102, 105, 191, 14, 15, 16, 161, 162, 162, 138, + 169, 188, 18, 49, 89, 32, 132, 187, 39, 156, + 157, 59, 14, 15, 16, 145, 146, 148, 151, 105, + 102, 181, 182, 190, 185, 169, 56, 90, 164, 41, + 169, 14, 15, 129, 122, 28, 133, 138, 138, 41, + 105, 108, 137, 39, 40, 152, 183, 184, 192, 182, + 9, 56, 63, 105, 106, 125, 14, 15, 69, 134, + 26, 146, 147, 138, 187, 41, 74, 94, 22, 190, + 126, 127, 130, 49, 60, 128, 71, 35, 105, 135, + 136, 137, 105, 138, 55, 184, 138, 188, 105, 107, + 108, 132, 124, 105, 169, 127 +}; + +#define yyerrok (yyerrstatus = 0) +#define yyclearin (yychar = YYEMPTY) +#define YYEMPTY (-2) +#define YYEOF 0 + +#define YYACCEPT goto yyacceptlab +#define YYABORT goto yyabortlab +#define YYERROR goto yyerrorlab + + +/* Like YYERROR except do call yyerror. This remains here temporarily + to ease the transition to the new meaning of YYERROR, for GCC. + Once GCC version 2 has supplanted version 1, this can go. */ + +#define YYFAIL goto yyerrlab + +#define YYRECOVERING() (!!yyerrstatus) + +#define YYBACKUP(Token, Value) \ +do \ + if (yychar == YYEMPTY && yylen == 1) \ + { \ + yychar = (Token); \ + yylval = (Value); \ + yytoken = YYTRANSLATE (yychar); \ + YYPOPSTACK (1); \ + goto yybackup; \ + } \ + else \ + { \ + yyerror (YY_("syntax error: cannot back up")); \ + YYERROR; \ + } \ +while (YYID (0)) + + +#define YYTERROR 1 +#define YYERRCODE 256 + + +/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N]. + If N is 0, then set CURRENT to the empty location which ends + the previous symbol: RHS[0] (always defined). */ + +#define YYRHSLOC(Rhs, K) ((Rhs)[K]) +#ifndef YYLLOC_DEFAULT +# define YYLLOC_DEFAULT(Current, Rhs, N) \ + do \ + if (YYID (N)) \ + { \ + (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \ + (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \ + (Current).last_line = YYRHSLOC (Rhs, N).last_line; \ + (Current).last_column = YYRHSLOC (Rhs, N).last_column; \ + } \ + else \ + { \ + (Current).first_line = (Current).last_line = \ + YYRHSLOC (Rhs, 0).last_line; \ + (Current).first_column = (Current).last_column = \ + YYRHSLOC (Rhs, 0).last_column; \ + } \ + while (YYID (0)) +#endif + + +/* YY_LOCATION_PRINT -- Print the location on the stream. + This macro was not mandated originally: define only if we know + we won't break user code: when these are the locations we know. */ + +#ifndef YY_LOCATION_PRINT +# if YYLTYPE_IS_TRIVIAL +# define YY_LOCATION_PRINT(File, Loc) \ + fprintf (File, "%d.%d-%d.%d", \ + (Loc).first_line, (Loc).first_column, \ + (Loc).last_line, (Loc).last_column) +# else +# define YY_LOCATION_PRINT(File, Loc) ((void) 0) +# endif +#endif + + +/* YYLEX -- calling `yylex' with the right arguments. */ + +#ifdef YYLEX_PARAM +# define YYLEX yylex (YYLEX_PARAM) +#else +# define YYLEX yylex () +#endif + +/* Enable debugging if requested. */ +#if YYDEBUG + +# ifndef YYFPRINTF +# include /* INFRINGES ON USER NAME SPACE */ +# define YYFPRINTF fprintf +# endif + +# define YYDPRINTF(Args) \ +do { \ + if (yydebug) \ + YYFPRINTF Args; \ +} while (YYID (0)) + +# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \ +do { \ + if (yydebug) \ + { \ + YYFPRINTF (stderr, "%s ", Title); \ + yy_symbol_print (stderr, \ + Type, Value, Location); \ + YYFPRINTF (stderr, "\n"); \ + } \ +} while (YYID (0)) + + +/*--------------------------------. +| Print this symbol on YYOUTPUT. | +`--------------------------------*/ + +/*ARGSUSED*/ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp) +#else +static void +yy_symbol_value_print (yyoutput, yytype, yyvaluep, yylocationp) + FILE *yyoutput; + int yytype; + YYSTYPE const * const yyvaluep; + YYLTYPE const * const yylocationp; +#endif +{ + if (!yyvaluep) + return; + YYUSE (yylocationp); +# ifdef YYPRINT + if (yytype < YYNTOKENS) + YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep); +# else + YYUSE (yyoutput); +# endif + switch (yytype) + { + default: + break; + } +} + + +/*--------------------------------. +| Print this symbol on YYOUTPUT. | +`--------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep, YYLTYPE const * const yylocationp) +#else +static void +yy_symbol_print (yyoutput, yytype, yyvaluep, yylocationp) + FILE *yyoutput; + int yytype; + YYSTYPE const * const yyvaluep; + YYLTYPE const * const yylocationp; +#endif +{ + if (yytype < YYNTOKENS) + YYFPRINTF (yyoutput, "token %s (", yytname[yytype]); + else + YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]); + + YY_LOCATION_PRINT (yyoutput, *yylocationp); + YYFPRINTF (yyoutput, ": "); + yy_symbol_value_print (yyoutput, yytype, yyvaluep, yylocationp); + YYFPRINTF (yyoutput, ")"); +} + +/*------------------------------------------------------------------. +| yy_stack_print -- Print the state stack from its BOTTOM up to its | +| TOP (included). | +`------------------------------------------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop) +#else +static void +yy_stack_print (yybottom, yytop) + yytype_int16 *yybottom; + yytype_int16 *yytop; +#endif +{ + YYFPRINTF (stderr, "Stack now"); + for (; yybottom <= yytop; yybottom++) + { + int yybot = *yybottom; + YYFPRINTF (stderr, " %d", yybot); + } + YYFPRINTF (stderr, "\n"); +} + +# define YY_STACK_PRINT(Bottom, Top) \ +do { \ + if (yydebug) \ + yy_stack_print ((Bottom), (Top)); \ +} while (YYID (0)) + + +/*------------------------------------------------. +| Report that the YYRULE is going to be reduced. | +`------------------------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_reduce_print (YYSTYPE *yyvsp, YYLTYPE *yylsp, int yyrule) +#else +static void +yy_reduce_print (yyvsp, yylsp, yyrule) + YYSTYPE *yyvsp; + YYLTYPE *yylsp; + int yyrule; +#endif +{ + int yynrhs = yyr2[yyrule]; + int yyi; + unsigned long int yylno = yyrline[yyrule]; + YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n", + yyrule - 1, yylno); + /* The symbols being reduced. */ + for (yyi = 0; yyi < yynrhs; yyi++) + { + YYFPRINTF (stderr, " $%d = ", yyi + 1); + yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi], + &(yyvsp[(yyi + 1) - (yynrhs)]) + , &(yylsp[(yyi + 1) - (yynrhs)]) ); + YYFPRINTF (stderr, "\n"); + } +} + +# define YY_REDUCE_PRINT(Rule) \ +do { \ + if (yydebug) \ + yy_reduce_print (yyvsp, yylsp, Rule); \ +} while (YYID (0)) + +/* Nonzero means print parse trace. It is left uninitialized so that + multiple parsers can coexist. */ +int yydebug; +#else /* !YYDEBUG */ +# define YYDPRINTF(Args) +# define YY_SYMBOL_PRINT(Title, Type, Value, Location) +# define YY_STACK_PRINT(Bottom, Top) +# define YY_REDUCE_PRINT(Rule) +#endif /* !YYDEBUG */ + + +/* YYINITDEPTH -- initial size of the parser's stacks. */ +#ifndef YYINITDEPTH +# define YYINITDEPTH 200 +#endif + +/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only + if the built-in stack extension method is used). + + Do not make this value too large; the results are undefined if + YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH) + evaluated with infinite-precision integer arithmetic. */ + +#ifndef YYMAXDEPTH +# define YYMAXDEPTH 10000 +#endif + + + +#if YYERROR_VERBOSE + +# ifndef yystrlen +# if defined __GLIBC__ && defined _STRING_H +# define yystrlen strlen +# else +/* Return the length of YYSTR. */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static YYSIZE_T +yystrlen (const char *yystr) +#else +static YYSIZE_T +yystrlen (yystr) + const char *yystr; +#endif +{ + YYSIZE_T yylen; + for (yylen = 0; yystr[yylen]; yylen++) + continue; + return yylen; +} +# endif +# endif + +# ifndef yystpcpy +# if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE +# define yystpcpy stpcpy +# else +/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in + YYDEST. */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static char * +yystpcpy (char *yydest, const char *yysrc) +#else +static char * +yystpcpy (yydest, yysrc) + char *yydest; + const char *yysrc; +#endif +{ + char *yyd = yydest; + const char *yys = yysrc; + + while ((*yyd++ = *yys++) != '\0') + continue; + + return yyd - 1; +} +# endif +# endif + +# ifndef yytnamerr +/* Copy to YYRES the contents of YYSTR after stripping away unnecessary + quotes and backslashes, so that it's suitable for yyerror. The + heuristic is that double-quoting is unnecessary unless the string + contains an apostrophe, a comma, or backslash (other than + backslash-backslash). YYSTR is taken from yytname. If YYRES is + null, do not copy; instead, return the length of what the result + would have been. */ +static YYSIZE_T +yytnamerr (char *yyres, const char *yystr) +{ + if (*yystr == '"') + { + YYSIZE_T yyn = 0; + char const *yyp = yystr; + + for (;;) + switch (*++yyp) + { + case '\'': + case ',': + goto do_not_strip_quotes; + + case '\\': + if (*++yyp != '\\') + goto do_not_strip_quotes; + /* Fall through. */ + default: + if (yyres) + yyres[yyn] = *yyp; + yyn++; + break; + + case '"': + if (yyres) + yyres[yyn] = '\0'; + return yyn; + } + do_not_strip_quotes: ; + } + + if (! yyres) + return yystrlen (yystr); + + return yystpcpy (yyres, yystr) - yyres; +} +# endif + +/* Copy into YYRESULT an error message about the unexpected token + YYCHAR while in state YYSTATE. Return the number of bytes copied, + including the terminating null byte. If YYRESULT is null, do not + copy anything; just return the number of bytes that would be + copied. As a special case, return 0 if an ordinary "syntax error" + message will do. Return YYSIZE_MAXIMUM if overflow occurs during + size calculation. */ +static YYSIZE_T +yysyntax_error (char *yyresult, int yystate, int yychar) +{ + int yyn = yypact[yystate]; + + if (! (YYPACT_NINF < yyn && yyn <= YYLAST)) + return 0; + else + { + int yytype = YYTRANSLATE (yychar); + YYSIZE_T yysize0 = yytnamerr (0, yytname[yytype]); + YYSIZE_T yysize = yysize0; + YYSIZE_T yysize1; + int yysize_overflow = 0; + enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; + char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; + int yyx; + +# if 0 + /* This is so xgettext sees the translatable formats that are + constructed on the fly. */ + YY_("syntax error, unexpected %s"); + YY_("syntax error, unexpected %s, expecting %s"); + YY_("syntax error, unexpected %s, expecting %s or %s"); + YY_("syntax error, unexpected %s, expecting %s or %s or %s"); + YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"); +# endif + char *yyfmt; + char const *yyf; + static char const yyunexpected[] = "syntax error, unexpected %s"; + static char const yyexpecting[] = ", expecting %s"; + static char const yyor[] = " or %s"; + char yyformat[sizeof yyunexpected + + sizeof yyexpecting - 1 + + ((YYERROR_VERBOSE_ARGS_MAXIMUM - 2) + * (sizeof yyor - 1))]; + char const *yyprefix = yyexpecting; + + /* Start YYX at -YYN if negative to avoid negative indexes in + YYCHECK. */ + int yyxbegin = yyn < 0 ? -yyn : 0; + + /* Stay within bounds of both yycheck and yytname. */ + int yychecklim = YYLAST - yyn + 1; + int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; + int yycount = 1; + + yyarg[0] = yytname[yytype]; + yyfmt = yystpcpy (yyformat, yyunexpected); + + for (yyx = yyxbegin; yyx < yyxend; ++yyx) + if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR) + { + if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) + { + yycount = 1; + yysize = yysize0; + yyformat[sizeof yyunexpected - 1] = '\0'; + break; + } + yyarg[yycount++] = yytname[yyx]; + yysize1 = yysize + yytnamerr (0, yytname[yyx]); + yysize_overflow |= (yysize1 < yysize); + yysize = yysize1; + yyfmt = yystpcpy (yyfmt, yyprefix); + yyprefix = yyor; + } + + yyf = YY_(yyformat); + yysize1 = yysize + yystrlen (yyf); + yysize_overflow |= (yysize1 < yysize); + yysize = yysize1; + + if (yysize_overflow) + return YYSIZE_MAXIMUM; + + if (yyresult) + { + /* Avoid sprintf, as that infringes on the user's name space. + Don't have undefined behavior even if the translation + produced a string with the wrong number of "%s"s. */ + char *yyp = yyresult; + int yyi = 0; + while ((*yyp = *yyf) != '\0') + { + if (*yyp == '%' && yyf[1] == 's' && yyi < yycount) + { + yyp += yytnamerr (yyp, yyarg[yyi++]); + yyf += 2; + } + else + { + yyp++; + yyf++; + } + } + } + return yysize; + } +} +#endif /* YYERROR_VERBOSE */ + + +/*-----------------------------------------------. +| Release the memory associated to this symbol. | +`-----------------------------------------------*/ + +/*ARGSUSED*/ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep, YYLTYPE *yylocationp) +#else +static void +yydestruct (yymsg, yytype, yyvaluep, yylocationp) + const char *yymsg; + int yytype; + YYSTYPE *yyvaluep; + YYLTYPE *yylocationp; +#endif +{ + YYUSE (yyvaluep); + YYUSE (yylocationp); + + if (!yymsg) + yymsg = "Deleting"; + YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp); + + switch (yytype) + { + + default: + break; + } +} + +/* Prevent warnings from -Wmissing-prototypes. */ +#ifdef YYPARSE_PARAM +#if defined __STDC__ || defined __cplusplus +int yyparse (void *YYPARSE_PARAM); +#else +int yyparse (); +#endif +#else /* ! YYPARSE_PARAM */ +#if defined __STDC__ || defined __cplusplus +int yyparse (void); +#else +int yyparse (); +#endif +#endif /* ! YYPARSE_PARAM */ + + +/* The lookahead symbol. */ +int yychar; + +/* The semantic value of the lookahead symbol. */ +YYSTYPE yylval; + +/* Location data for the lookahead symbol. */ +YYLTYPE yylloc; + +/* Number of syntax errors so far. */ +int yynerrs; + + + +/*-------------------------. +| yyparse or yypush_parse. | +`-------------------------*/ + +#ifdef YYPARSE_PARAM +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +int +yyparse (void *YYPARSE_PARAM) +#else +int +yyparse (YYPARSE_PARAM) + void *YYPARSE_PARAM; +#endif +#else /* ! YYPARSE_PARAM */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +int +yyparse (void) +#else +int +yyparse () + +#endif +#endif +{ + + + int yystate; + /* Number of tokens to shift before error messages enabled. */ + int yyerrstatus; + + /* The stacks and their tools: + `yyss': related to states. + `yyvs': related to semantic values. + `yyls': related to locations. + + Refer to the stacks thru separate pointers, to allow yyoverflow + to reallocate them elsewhere. */ + + /* The state stack. */ + yytype_int16 yyssa[YYINITDEPTH]; + yytype_int16 *yyss; + yytype_int16 *yyssp; + + /* The semantic value stack. */ + YYSTYPE yyvsa[YYINITDEPTH]; + YYSTYPE *yyvs; + YYSTYPE *yyvsp; + + /* The location stack. */ + YYLTYPE yylsa[YYINITDEPTH]; + YYLTYPE *yyls; + YYLTYPE *yylsp; + + /* The locations where the error started and ended. */ + YYLTYPE yyerror_range[2]; + + YYSIZE_T yystacksize; + + int yyn; + int yyresult; + /* Lookahead token as an internal (translated) token number. */ + int yytoken; + /* The variables used to return semantic value and location from the + action routines. */ + YYSTYPE yyval; + YYLTYPE yyloc; + +#if YYERROR_VERBOSE + /* Buffer for error messages, and its allocated size. */ + char yymsgbuf[128]; + char *yymsg = yymsgbuf; + YYSIZE_T yymsg_alloc = sizeof yymsgbuf; +#endif + +#define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N), yylsp -= (N)) + + /* The number of symbols on the RHS of the reduced rule. + Keep to zero when no symbol should be popped. */ + int yylen = 0; + + yytoken = 0; + yyss = yyssa; + yyvs = yyvsa; + yyls = yylsa; + yystacksize = YYINITDEPTH; + + YYDPRINTF ((stderr, "Starting parse\n")); + + yystate = 0; + yyerrstatus = 0; + yynerrs = 0; + yychar = YYEMPTY; /* Cause a token to be read. */ + + /* Initialize stack pointers. + Waste one element of value and location stack + so that they stay on the same level as the state stack. + The wasted elements are never initialized. */ + yyssp = yyss; + yyvsp = yyvs; + yylsp = yyls; + +#if YYLTYPE_IS_TRIVIAL + /* Initialize the default location before parsing starts. */ + yylloc.first_line = yylloc.last_line = 1; + yylloc.first_column = yylloc.last_column = 1; +#endif + + goto yysetstate; + +/*------------------------------------------------------------. +| yynewstate -- Push a new state, which is found in yystate. | +`------------------------------------------------------------*/ + yynewstate: + /* In all cases, when you get here, the value and location stacks + have just been pushed. So pushing a state here evens the stacks. */ + yyssp++; + + yysetstate: + *yyssp = yystate; + + if (yyss + yystacksize - 1 <= yyssp) + { + /* Get the current used size of the three stacks, in elements. */ + YYSIZE_T yysize = yyssp - yyss + 1; + +#ifdef yyoverflow + { + /* Give user a chance to reallocate the stack. Use copies of + these so that the &'s don't force the real ones into + memory. */ + YYSTYPE *yyvs1 = yyvs; + yytype_int16 *yyss1 = yyss; + YYLTYPE *yyls1 = yyls; + + /* Each stack pointer address is followed by the size of the + data in use in that stack, in bytes. This used to be a + conditional around just the two extra args, but that might + be undefined if yyoverflow is a macro. */ + yyoverflow (YY_("memory exhausted"), + &yyss1, yysize * sizeof (*yyssp), + &yyvs1, yysize * sizeof (*yyvsp), + &yyls1, yysize * sizeof (*yylsp), + &yystacksize); + + yyls = yyls1; + yyss = yyss1; + yyvs = yyvs1; + } +#else /* no yyoverflow */ +# ifndef YYSTACK_RELOCATE + goto yyexhaustedlab; +# else + /* Extend the stack our own way. */ + if (YYMAXDEPTH <= yystacksize) + goto yyexhaustedlab; + yystacksize *= 2; + if (YYMAXDEPTH < yystacksize) + yystacksize = YYMAXDEPTH; + + { + yytype_int16 *yyss1 = yyss; + union yyalloc *yyptr = + (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize)); + if (! yyptr) + goto yyexhaustedlab; + YYSTACK_RELOCATE (yyss_alloc, yyss); + YYSTACK_RELOCATE (yyvs_alloc, yyvs); + YYSTACK_RELOCATE (yyls_alloc, yyls); +# undef YYSTACK_RELOCATE + if (yyss1 != yyssa) + YYSTACK_FREE (yyss1); + } +# endif +#endif /* no yyoverflow */ + + yyssp = yyss + yysize - 1; + yyvsp = yyvs + yysize - 1; + yylsp = yyls + yysize - 1; + + YYDPRINTF ((stderr, "Stack size increased to %lu\n", + (unsigned long int) yystacksize)); + + if (yyss + yystacksize - 1 <= yyssp) + YYABORT; + } + + YYDPRINTF ((stderr, "Entering state %d\n", yystate)); + + if (yystate == YYFINAL) + YYACCEPT; + + goto yybackup; + +/*-----------. +| yybackup. | +`-----------*/ +yybackup: + + /* Do appropriate processing given the current state. Read a + lookahead token if we need one and don't already have one. */ + + /* First try to decide what to do without reference to lookahead token. */ + yyn = yypact[yystate]; + if (yyn == YYPACT_NINF) + goto yydefault; + + /* Not known => get a lookahead token if don't already have one. */ + + /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */ + if (yychar == YYEMPTY) + { + YYDPRINTF ((stderr, "Reading a token: ")); + yychar = YYLEX; + } + + if (yychar <= YYEOF) + { + yychar = yytoken = YYEOF; + YYDPRINTF ((stderr, "Now at end of input.\n")); + } + else + { + yytoken = YYTRANSLATE (yychar); + YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc); + } + + /* If the proper action on seeing token YYTOKEN is to reduce or to + detect an error, take that action. */ + yyn += yytoken; + if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken) + goto yydefault; + yyn = yytable[yyn]; + if (yyn <= 0) + { + if (yyn == 0 || yyn == YYTABLE_NINF) + goto yyerrlab; + yyn = -yyn; + goto yyreduce; + } + + /* Count tokens shifted since error; after three, turn off error + status. */ + if (yyerrstatus) + yyerrstatus--; + + /* Shift the lookahead token. */ + YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc); + + /* Discard the shifted token. */ + yychar = YYEMPTY; + + yystate = yyn; + *++yyvsp = yylval; + *++yylsp = yylloc; + goto yynewstate; + + +/*-----------------------------------------------------------. +| yydefault -- do the default action for the current state. | +`-----------------------------------------------------------*/ +yydefault: + yyn = yydefact[yystate]; + if (yyn == 0) + goto yyerrlab; + goto yyreduce; + + +/*-----------------------------. +| yyreduce -- Do a reduction. | +`-----------------------------*/ +yyreduce: + /* yyn is the number of a rule to reduce with. */ + yylen = yyr2[yyn]; + + /* If YYLEN is nonzero, implement the default value of the action: + `$$ = $1'. + + Otherwise, the following line sets YYVAL to garbage. + This behavior is undocumented and Bison + users should not rely upon it. Assigning to YYVAL + unconditionally makes the parser a bit smaller, and it avoids a + GCC warning that YYVAL may be used uninitialized. */ + yyval = yyvsp[1-yylen]; + + /* Default location. */ + YYLLOC_DEFAULT (yyloc, (yylsp - yylen), yylen); + YY_REDUCE_PRINT (yyn); + switch (yyn) + { + case 2: + +/* Line 1455 of yacc.c */ +#line 333 "gram.y" + { + plpgsql_parse_result = (PLpgSQL_stmt_block *) (yyvsp[(2) - (3)].stmt); + ;} + break; + + case 5: + +/* Line 1455 of yacc.c */ +#line 343 "gram.y" + { + plpgsql_DumpExecTree = true; + ;} + break; + + case 6: + +/* Line 1455 of yacc.c */ +#line 347 "gram.y" + { + plpgsql_curr_compile->resolve_option = PLPGSQL_RESOLVE_ERROR; + ;} + break; + + case 7: + +/* Line 1455 of yacc.c */ +#line 351 "gram.y" + { + plpgsql_curr_compile->resolve_option = PLPGSQL_RESOLVE_VARIABLE; + ;} + break; + + case 8: + +/* Line 1455 of yacc.c */ +#line 355 "gram.y" + { + plpgsql_curr_compile->resolve_option = PLPGSQL_RESOLVE_COLUMN; + ;} + break; + + case 11: + +/* Line 1455 of yacc.c */ +#line 365 "gram.y" + { + PLpgSQL_stmt_block *new; + + new = palloc0(sizeof(PLpgSQL_stmt_block)); + + new->cmd_type = PLPGSQL_STMT_BLOCK; + new->lineno = plpgsql_location_to_lineno((yylsp[(2) - (6)])); + new->label = (yyvsp[(1) - (6)].declhdr).label; + new->n_initvars = (yyvsp[(1) - (6)].declhdr).n_initvars; + new->initvarnos = (yyvsp[(1) - (6)].declhdr).initvarnos; + new->body = (yyvsp[(3) - (6)].list); + new->exceptions = (yyvsp[(4) - (6)].exception_block); + + check_labels((yyvsp[(1) - (6)].declhdr).label, (yyvsp[(6) - (6)].str), (yylsp[(6) - (6)])); + plpgsql_ns_pop(); + + (yyval.stmt) = (PLpgSQL_stmt *)new; + ;} + break; + + case 12: + +/* Line 1455 of yacc.c */ +#line 387 "gram.y" + { + /* done with decls, so resume identifier lookup */ + plpgsql_IdentifierLookup = IDENTIFIER_LOOKUP_NORMAL; + (yyval.declhdr).label = (yyvsp[(1) - (1)].str); + (yyval.declhdr).n_initvars = 0; + (yyval.declhdr).initvarnos = NULL; + ;} + break; + + case 13: + +/* Line 1455 of yacc.c */ +#line 395 "gram.y" + { + plpgsql_IdentifierLookup = IDENTIFIER_LOOKUP_NORMAL; + (yyval.declhdr).label = (yyvsp[(1) - (2)].str); + (yyval.declhdr).n_initvars = 0; + (yyval.declhdr).initvarnos = NULL; + ;} + break; + + case 14: + +/* Line 1455 of yacc.c */ +#line 402 "gram.y" + { + plpgsql_IdentifierLookup = IDENTIFIER_LOOKUP_NORMAL; + (yyval.declhdr).label = (yyvsp[(1) - (3)].str); + /* Remember variables declared in decl_stmts */ + (yyval.declhdr).n_initvars = plpgsql_add_initdatums(&((yyval.declhdr).initvarnos)); + ;} + break; + + case 15: + +/* Line 1455 of yacc.c */ +#line 411 "gram.y" + { + /* Forget any variables created before block */ + plpgsql_add_initdatums(NULL); + /* + * Disable scanner lookup of identifiers while + * we process the decl_stmts + */ + plpgsql_IdentifierLookup = IDENTIFIER_LOOKUP_DECLARE; + ;} + break; + + case 19: + +/* Line 1455 of yacc.c */ +#line 428 "gram.y" + { + /* We allow useless extra DECLAREs */ + ;} + break; + + case 20: + +/* Line 1455 of yacc.c */ +#line 432 "gram.y" + { + /* + * Throw a helpful error if user tries to put block + * label just before BEGIN, instead of before DECLARE. + */ + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("block label must be placed before DECLARE, not after"), + parser_errposition((yylsp[(1) - (3)])))); + ;} + break; + + case 21: + +/* Line 1455 of yacc.c */ +#line 445 "gram.y" + { + PLpgSQL_variable *var; + + /* + * If a collation is supplied, insert it into the + * datatype. We assume decl_datatype always returns + * a freshly built struct not shared with other + * variables. + */ + if (OidIsValid((yyvsp[(4) - (6)].oid))) + { + if (!OidIsValid((yyvsp[(3) - (6)].dtype)->collation)) + ereport(ERROR, + (errcode(ERRCODE_DATATYPE_MISMATCH), + errmsg("collations are not supported by type %s", + format_type_be((yyvsp[(3) - (6)].dtype)->typoid)), + parser_errposition((yylsp[(4) - (6)])))); + (yyvsp[(3) - (6)].dtype)->collation = (yyvsp[(4) - (6)].oid); + } + + var = plpgsql_build_variable((yyvsp[(1) - (6)].varname).name, (yyvsp[(1) - (6)].varname).lineno, + (yyvsp[(3) - (6)].dtype), true); + if ((yyvsp[(2) - (6)].boolean)) + { + if (var->dtype == PLPGSQL_DTYPE_VAR) + ((PLpgSQL_var *) var)->isconst = (yyvsp[(2) - (6)].boolean); + else + ereport(ERROR, + (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), + errmsg("row or record variable cannot be CONSTANT"), + parser_errposition((yylsp[(2) - (6)])))); + } + if ((yyvsp[(5) - (6)].boolean)) + { + if (var->dtype == PLPGSQL_DTYPE_VAR) + ((PLpgSQL_var *) var)->notnull = (yyvsp[(5) - (6)].boolean); + else + ereport(ERROR, + (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), + errmsg("row or record variable cannot be NOT NULL"), + parser_errposition((yylsp[(4) - (6)])))); + + } + if ((yyvsp[(6) - (6)].expr) != NULL) + { + if (var->dtype == PLPGSQL_DTYPE_VAR) + ((PLpgSQL_var *) var)->default_val = (yyvsp[(6) - (6)].expr); + else + ereport(ERROR, + (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), + errmsg("default value for row or record variable is not supported"), + parser_errposition((yylsp[(5) - (6)])))); + } + ;} + break; + + case 22: + +/* Line 1455 of yacc.c */ +#line 500 "gram.y" + { + plpgsql_ns_additem((yyvsp[(4) - (5)].nsitem)->itemtype, + (yyvsp[(4) - (5)].nsitem)->itemno, (yyvsp[(1) - (5)].varname).name); + ;} + break; + + case 23: + +/* Line 1455 of yacc.c */ +#line 505 "gram.y" + { plpgsql_ns_push((yyvsp[(1) - (3)].varname).name); ;} + break; + + case 24: + +/* Line 1455 of yacc.c */ +#line 507 "gram.y" + { + PLpgSQL_var *new; + PLpgSQL_expr *curname_def; + char buf[1024]; + char *cp1; + char *cp2; + + /* pop local namespace for cursor args */ + plpgsql_ns_pop(); + + new = (PLpgSQL_var *) + plpgsql_build_variable((yyvsp[(1) - (7)].varname).name, (yyvsp[(1) - (7)].varname).lineno, + plpgsql_build_datatype(REFCURSOROID, + -1, + InvalidOid), + true); + + curname_def = palloc0(sizeof(PLpgSQL_expr)); + + curname_def->dtype = PLPGSQL_DTYPE_EXPR; + strcpy(buf, "SELECT "); + cp1 = new->refname; + cp2 = buf + strlen(buf); + /* + * Don't trust standard_conforming_strings here; + * it might change before we use the string. + */ + if (strchr(cp1, '\\') != NULL) + *cp2++ = ESCAPE_STRING_SYNTAX; + *cp2++ = '\''; + while (*cp1) + { + if (SQL_STR_DOUBLE(*cp1, true)) + *cp2++ = *cp1; + *cp2++ = *cp1++; + } + strcpy(cp2, "'::pg_catalog.refcursor"); + curname_def->query = pstrdup(buf); + new->default_val = curname_def; + + new->cursor_explicit_expr = (yyvsp[(7) - (7)].expr); + if ((yyvsp[(5) - (7)].datum) == NULL) + new->cursor_explicit_argrow = -1; + else + new->cursor_explicit_argrow = (yyvsp[(5) - (7)].datum)->dno; + new->cursor_options = CURSOR_OPT_FAST_PLAN | (yyvsp[(2) - (7)].ival); + ;} + break; + + case 25: + +/* Line 1455 of yacc.c */ +#line 557 "gram.y" + { + (yyval.ival) = 0; + ;} + break; + + case 26: + +/* Line 1455 of yacc.c */ +#line 561 "gram.y" + { + (yyval.ival) = CURSOR_OPT_NO_SCROLL; + ;} + break; + + case 27: + +/* Line 1455 of yacc.c */ +#line 565 "gram.y" + { + (yyval.ival) = CURSOR_OPT_SCROLL; + ;} + break; + + case 28: + +/* Line 1455 of yacc.c */ +#line 571 "gram.y" + { + (yyval.expr) = read_sql_stmt(""); + ;} + break; + + case 29: + +/* Line 1455 of yacc.c */ +#line 577 "gram.y" + { + (yyval.datum) = NULL; + ;} + break; + + case 30: + +/* Line 1455 of yacc.c */ +#line 581 "gram.y" + { + PLpgSQL_row *new; + int i; + ListCell *l; + + new = palloc0(sizeof(PLpgSQL_row)); + new->dtype = PLPGSQL_DTYPE_ROW; + new->lineno = plpgsql_location_to_lineno((yylsp[(1) - (3)])); + new->rowtupdesc = NULL; + new->nfields = list_length((yyvsp[(2) - (3)].list)); + new->fieldnames = palloc(new->nfields * sizeof(char *)); + new->varnos = palloc(new->nfields * sizeof(int)); + + i = 0; + foreach (l, (yyvsp[(2) - (3)].list)) + { + PLpgSQL_variable *arg = (PLpgSQL_variable *) lfirst(l); + new->fieldnames[i] = arg->refname; + new->varnos[i] = arg->dno; + i++; + } + list_free((yyvsp[(2) - (3)].list)); + + plpgsql_adddatum((PLpgSQL_datum *) new); + (yyval.datum) = (PLpgSQL_datum *) new; + ;} + break; + + case 31: + +/* Line 1455 of yacc.c */ +#line 610 "gram.y" + { + (yyval.list) = list_make1((yyvsp[(1) - (1)].datum)); + ;} + break; + + case 32: + +/* Line 1455 of yacc.c */ +#line 614 "gram.y" + { + (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].datum)); + ;} + break; + + case 33: + +/* Line 1455 of yacc.c */ +#line 620 "gram.y" + { + (yyval.datum) = (PLpgSQL_datum *) + plpgsql_build_variable((yyvsp[(1) - (2)].varname).name, (yyvsp[(1) - (2)].varname).lineno, + (yyvsp[(2) - (2)].dtype), true); + ;} + break; + + case 36: + +/* Line 1455 of yacc.c */ +#line 631 "gram.y" + { + PLpgSQL_nsitem *nsi; + + nsi = plpgsql_ns_lookup(plpgsql_ns_top(), false, + (yyvsp[(1) - (1)].word).ident, NULL, NULL, + NULL); + if (nsi == NULL) + ereport(ERROR, + (errcode(ERRCODE_UNDEFINED_OBJECT), + errmsg("variable \"%s\" does not exist", + (yyvsp[(1) - (1)].word).ident), + parser_errposition((yylsp[(1) - (1)])))); + (yyval.nsitem) = nsi; + ;} + break; + + case 37: + +/* Line 1455 of yacc.c */ +#line 646 "gram.y" + { + PLpgSQL_nsitem *nsi; + + if (list_length((yyvsp[(1) - (1)].cword).idents) == 2) + nsi = plpgsql_ns_lookup(plpgsql_ns_top(), false, + strVal(linitial((yyvsp[(1) - (1)].cword).idents)), + strVal(lsecond((yyvsp[(1) - (1)].cword).idents)), + NULL, + NULL); + else if (list_length((yyvsp[(1) - (1)].cword).idents) == 3) + nsi = plpgsql_ns_lookup(plpgsql_ns_top(), false, + strVal(linitial((yyvsp[(1) - (1)].cword).idents)), + strVal(lsecond((yyvsp[(1) - (1)].cword).idents)), + strVal(lthird((yyvsp[(1) - (1)].cword).idents)), + NULL); + else + nsi = NULL; + if (nsi == NULL) + ereport(ERROR, + (errcode(ERRCODE_UNDEFINED_OBJECT), + errmsg("variable \"%s\" does not exist", + NameListToString((yyvsp[(1) - (1)].cword).idents)), + parser_errposition((yylsp[(1) - (1)])))); + (yyval.nsitem) = nsi; + ;} + break; + + case 38: + +/* Line 1455 of yacc.c */ +#line 674 "gram.y" + { + (yyval.varname).name = (yyvsp[(1) - (1)].word).ident; + (yyval.varname).lineno = plpgsql_location_to_lineno((yylsp[(1) - (1)])); + /* + * Check to make sure name isn't already declared + * in the current block. + */ + if (plpgsql_ns_lookup(plpgsql_ns_top(), true, + (yyvsp[(1) - (1)].word).ident, NULL, NULL, + NULL) != NULL) + yyerror("duplicate declaration"); + ;} + break; + + case 39: + +/* Line 1455 of yacc.c */ +#line 687 "gram.y" + { + (yyval.varname).name = pstrdup((yyvsp[(1) - (1)].keyword)); + (yyval.varname).lineno = plpgsql_location_to_lineno((yylsp[(1) - (1)])); + /* + * Check to make sure name isn't already declared + * in the current block. + */ + if (plpgsql_ns_lookup(plpgsql_ns_top(), true, + (yyvsp[(1) - (1)].keyword), NULL, NULL, + NULL) != NULL) + yyerror("duplicate declaration"); + ;} + break; + + case 40: + +/* Line 1455 of yacc.c */ +#line 702 "gram.y" + { (yyval.boolean) = false; ;} + break; + + case 41: + +/* Line 1455 of yacc.c */ +#line 704 "gram.y" + { (yyval.boolean) = true; ;} + break; + + case 42: + +/* Line 1455 of yacc.c */ +#line 708 "gram.y" + { + /* + * If there's a lookahead token, read_datatype + * should consume it. + */ + (yyval.dtype) = read_datatype(yychar); + yyclearin; + ;} + break; + + case 43: + +/* Line 1455 of yacc.c */ +#line 719 "gram.y" + { (yyval.oid) = InvalidOid; ;} + break; + + case 44: + +/* Line 1455 of yacc.c */ +#line 721 "gram.y" + { + (yyval.oid) = get_collation_oid(list_make1(makeString((yyvsp[(2) - (2)].word).ident)), + false); + ;} + break; + + case 45: + +/* Line 1455 of yacc.c */ +#line 726 "gram.y" + { + (yyval.oid) = get_collation_oid((yyvsp[(2) - (2)].cword).idents, false); + ;} + break; + + case 46: + +/* Line 1455 of yacc.c */ +#line 732 "gram.y" + { (yyval.boolean) = false; ;} + break; + + case 47: + +/* Line 1455 of yacc.c */ +#line 734 "gram.y" + { (yyval.boolean) = true; ;} + break; + + case 48: + +/* Line 1455 of yacc.c */ +#line 738 "gram.y" + { (yyval.expr) = NULL; ;} + break; + + case 49: + +/* Line 1455 of yacc.c */ +#line 740 "gram.y" + { + (yyval.expr) = read_sql_expression(';', ";"); + ;} + break; + + case 54: + +/* Line 1455 of yacc.c */ +#line 754 "gram.y" + { (yyval.list) = NIL; ;} + break; + + case 55: + +/* Line 1455 of yacc.c */ +#line 756 "gram.y" + { (yyval.list) = (yyvsp[(1) - (1)].list); ;} + break; + + case 56: + +/* Line 1455 of yacc.c */ +#line 760 "gram.y" + { + if ((yyvsp[(2) - (2)].stmt) == NULL) + (yyval.list) = (yyvsp[(1) - (2)].list); + else + (yyval.list) = lappend((yyvsp[(1) - (2)].list), (yyvsp[(2) - (2)].stmt)); + ;} + break; + + case 57: + +/* Line 1455 of yacc.c */ +#line 767 "gram.y" + { + if ((yyvsp[(1) - (1)].stmt) == NULL) + (yyval.list) = NIL; + else + (yyval.list) = list_make1((yyvsp[(1) - (1)].stmt)); + ;} + break; + + case 58: + +/* Line 1455 of yacc.c */ +#line 776 "gram.y" + { (yyval.stmt) = (yyvsp[(1) - (2)].stmt); ;} + break; + + case 59: + +/* Line 1455 of yacc.c */ +#line 778 "gram.y" + { (yyval.stmt) = (yyvsp[(1) - (1)].stmt); ;} + break; + + case 60: + +/* Line 1455 of yacc.c */ +#line 780 "gram.y" + { (yyval.stmt) = (yyvsp[(1) - (1)].stmt); ;} + break; + + case 61: + +/* Line 1455 of yacc.c */ +#line 782 "gram.y" + { (yyval.stmt) = (yyvsp[(1) - (1)].stmt); ;} + break; + + case 62: + +/* Line 1455 of yacc.c */ +#line 784 "gram.y" + { (yyval.stmt) = (yyvsp[(1) - (1)].stmt); ;} + break; + + case 63: + +/* Line 1455 of yacc.c */ +#line 786 "gram.y" + { (yyval.stmt) = (yyvsp[(1) - (1)].stmt); ;} + break; + + case 64: + +/* Line 1455 of yacc.c */ +#line 788 "gram.y" + { (yyval.stmt) = (yyvsp[(1) - (1)].stmt); ;} + break; + + case 65: + +/* Line 1455 of yacc.c */ +#line 790 "gram.y" + { (yyval.stmt) = (yyvsp[(1) - (1)].stmt); ;} + break; + + case 66: + +/* Line 1455 of yacc.c */ +#line 792 "gram.y" + { (yyval.stmt) = (yyvsp[(1) - (1)].stmt); ;} + break; + + case 67: + +/* Line 1455 of yacc.c */ +#line 794 "gram.y" + { (yyval.stmt) = (yyvsp[(1) - (1)].stmt); ;} + break; + + case 68: + +/* Line 1455 of yacc.c */ +#line 796 "gram.y" + { (yyval.stmt) = (yyvsp[(1) - (1)].stmt); ;} + break; + + case 69: + +/* Line 1455 of yacc.c */ +#line 798 "gram.y" + { (yyval.stmt) = (yyvsp[(1) - (1)].stmt); ;} + break; + + case 70: + +/* Line 1455 of yacc.c */ +#line 800 "gram.y" + { (yyval.stmt) = (yyvsp[(1) - (1)].stmt); ;} + break; + + case 71: + +/* Line 1455 of yacc.c */ +#line 802 "gram.y" + { (yyval.stmt) = (yyvsp[(1) - (1)].stmt); ;} + break; + + case 72: + +/* Line 1455 of yacc.c */ +#line 804 "gram.y" + { (yyval.stmt) = (yyvsp[(1) - (1)].stmt); ;} + break; + + case 73: + +/* Line 1455 of yacc.c */ +#line 806 "gram.y" + { (yyval.stmt) = (yyvsp[(1) - (1)].stmt); ;} + break; + + case 74: + +/* Line 1455 of yacc.c */ +#line 808 "gram.y" + { (yyval.stmt) = (yyvsp[(1) - (1)].stmt); ;} + break; + + case 75: + +/* Line 1455 of yacc.c */ +#line 810 "gram.y" + { (yyval.stmt) = (yyvsp[(1) - (1)].stmt); ;} + break; + + case 76: + +/* Line 1455 of yacc.c */ +#line 812 "gram.y" + { (yyval.stmt) = (yyvsp[(1) - (1)].stmt); ;} + break; + + case 77: + +/* Line 1455 of yacc.c */ +#line 814 "gram.y" + { (yyval.stmt) = (yyvsp[(1) - (1)].stmt); ;} + break; + + case 78: + +/* Line 1455 of yacc.c */ +#line 818 "gram.y" + { + PLpgSQL_stmt_perform *new; + + new = palloc0(sizeof(PLpgSQL_stmt_perform)); + new->cmd_type = PLPGSQL_STMT_PERFORM; + new->lineno = plpgsql_location_to_lineno((yylsp[(1) - (2)])); + new->expr = (yyvsp[(2) - (2)].expr); + + (yyval.stmt) = (PLpgSQL_stmt *)new; + ;} + break; + + case 79: + +/* Line 1455 of yacc.c */ +#line 831 "gram.y" + { + PLpgSQL_stmt_assign *new; + + new = palloc0(sizeof(PLpgSQL_stmt_assign)); + new->cmd_type = PLPGSQL_STMT_ASSIGN; + new->lineno = plpgsql_location_to_lineno((yylsp[(1) - (3)])); + new->varno = (yyvsp[(1) - (3)].ival); + new->expr = (yyvsp[(3) - (3)].expr); + + (yyval.stmt) = (PLpgSQL_stmt *)new; + ;} + break; + + case 80: + +/* Line 1455 of yacc.c */ +#line 845 "gram.y" + { + PLpgSQL_stmt_getdiag *new; + ListCell *lc; + + new = palloc0(sizeof(PLpgSQL_stmt_getdiag)); + new->cmd_type = PLPGSQL_STMT_GETDIAG; + new->lineno = plpgsql_location_to_lineno((yylsp[(1) - (5)])); + new->is_stacked = (yyvsp[(2) - (5)].boolean); + new->diag_items = (yyvsp[(4) - (5)].list); + + /* + * Check information items are valid for area option. + */ + foreach(lc, new->diag_items) + { + PLpgSQL_diag_item *ditem = (PLpgSQL_diag_item *) lfirst(lc); + + switch (ditem->kind) + { + /* these fields are disallowed in stacked case */ + case PLPGSQL_GETDIAG_ROW_COUNT: + case PLPGSQL_GETDIAG_RESULT_OID: + if (new->is_stacked) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("diagnostics item %s is not allowed in GET STACKED DIAGNOSTICS", + plpgsql_getdiag_kindname(ditem->kind)), + parser_errposition((yylsp[(1) - (5)])))); + break; + /* these fields are disallowed in current case */ + case PLPGSQL_GETDIAG_ERROR_CONTEXT: + case PLPGSQL_GETDIAG_ERROR_DETAIL: + case PLPGSQL_GETDIAG_ERROR_HINT: + case PLPGSQL_GETDIAG_RETURNED_SQLSTATE: + case PLPGSQL_GETDIAG_MESSAGE_TEXT: + if (!new->is_stacked) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("diagnostics item %s is not allowed in GET CURRENT DIAGNOSTICS", + plpgsql_getdiag_kindname(ditem->kind)), + parser_errposition((yylsp[(1) - (5)])))); + break; + default: + elog(ERROR, "unrecognized diagnostic item kind: %d", + ditem->kind); + break; + } + } + + (yyval.stmt) = (PLpgSQL_stmt *)new; + ;} + break; + + case 81: + +/* Line 1455 of yacc.c */ +#line 899 "gram.y" + { + (yyval.boolean) = false; + ;} + break; + + case 82: + +/* Line 1455 of yacc.c */ +#line 903 "gram.y" + { + (yyval.boolean) = false; + ;} + break; + + case 83: + +/* Line 1455 of yacc.c */ +#line 907 "gram.y" + { + (yyval.boolean) = true; + ;} + break; + + case 84: + +/* Line 1455 of yacc.c */ +#line 913 "gram.y" + { + (yyval.list) = lappend((yyvsp[(1) - (3)].list), (yyvsp[(3) - (3)].diagitem)); + ;} + break; + + case 85: + +/* Line 1455 of yacc.c */ +#line 917 "gram.y" + { + (yyval.list) = list_make1((yyvsp[(1) - (1)].diagitem)); + ;} + break; + + case 86: + +/* Line 1455 of yacc.c */ +#line 923 "gram.y" + { + PLpgSQL_diag_item *new; + + new = palloc(sizeof(PLpgSQL_diag_item)); + new->target = (yyvsp[(1) - (3)].ival); + new->kind = (yyvsp[(3) - (3)].ival); + + (yyval.diagitem) = new; + ;} + break; + + case 87: + +/* Line 1455 of yacc.c */ +#line 935 "gram.y" + { + int tok = yylex(); + + if (tok_is_keyword(tok, &yylval, + K_ROW_COUNT, "row_count")) + (yyval.ival) = PLPGSQL_GETDIAG_ROW_COUNT; + else if (tok_is_keyword(tok, &yylval, + K_RESULT_OID, "result_oid")) + (yyval.ival) = PLPGSQL_GETDIAG_RESULT_OID; + else if (tok_is_keyword(tok, &yylval, + K_PG_EXCEPTION_DETAIL, "pg_exception_detail")) + (yyval.ival) = PLPGSQL_GETDIAG_ERROR_DETAIL; + else if (tok_is_keyword(tok, &yylval, + K_PG_EXCEPTION_HINT, "pg_exception_hint")) + (yyval.ival) = PLPGSQL_GETDIAG_ERROR_HINT; + else if (tok_is_keyword(tok, &yylval, + K_PG_EXCEPTION_CONTEXT, "pg_exception_context")) + (yyval.ival) = PLPGSQL_GETDIAG_ERROR_CONTEXT; + else if (tok_is_keyword(tok, &yylval, + K_MESSAGE_TEXT, "message_text")) + (yyval.ival) = PLPGSQL_GETDIAG_MESSAGE_TEXT; + else if (tok_is_keyword(tok, &yylval, + K_RETURNED_SQLSTATE, "returned_sqlstate")) + (yyval.ival) = PLPGSQL_GETDIAG_RETURNED_SQLSTATE; + else + yyerror("unrecognized GET DIAGNOSTICS item"); + ;} + break; + + case 88: + +/* Line 1455 of yacc.c */ +#line 965 "gram.y" + { + check_assignable((yyvsp[(1) - (1)].wdatum).datum, (yylsp[(1) - (1)])); + if ((yyvsp[(1) - (1)].wdatum).datum->dtype == PLPGSQL_DTYPE_ROW || + (yyvsp[(1) - (1)].wdatum).datum->dtype == PLPGSQL_DTYPE_REC) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("\"%s\" is not a scalar variable", + NameOfDatum(&((yyvsp[(1) - (1)].wdatum)))), + parser_errposition((yylsp[(1) - (1)])))); + (yyval.ival) = (yyvsp[(1) - (1)].wdatum).datum->dno; + ;} + break; + + case 89: + +/* Line 1455 of yacc.c */ +#line 977 "gram.y" + { + /* just to give a better message than "syntax error" */ + word_is_not_variable(&((yyvsp[(1) - (1)].word)), (yylsp[(1) - (1)])); + ;} + break; + + case 90: + +/* Line 1455 of yacc.c */ +#line 982 "gram.y" + { + /* just to give a better message than "syntax error" */ + cword_is_not_variable(&((yyvsp[(1) - (1)].cword)), (yylsp[(1) - (1)])); + ;} + break; + + case 91: + +/* Line 1455 of yacc.c */ +#line 990 "gram.y" + { + check_assignable((yyvsp[(1) - (1)].wdatum).datum, (yylsp[(1) - (1)])); + (yyval.ival) = (yyvsp[(1) - (1)].wdatum).datum->dno; + ;} + break; + + case 92: + +/* Line 1455 of yacc.c */ +#line 995 "gram.y" + { + PLpgSQL_arrayelem *new; + + new = palloc0(sizeof(PLpgSQL_arrayelem)); + new->dtype = PLPGSQL_DTYPE_ARRAYELEM; + new->subscript = (yyvsp[(3) - (3)].expr); + new->arrayparentno = (yyvsp[(1) - (3)].ival); + /* initialize cached type data to "not valid" */ + new->parenttypoid = InvalidOid; + + plpgsql_adddatum((PLpgSQL_datum *) new); + + (yyval.ival) = new->dno; + ;} + break; + + case 93: + +/* Line 1455 of yacc.c */ +#line 1012 "gram.y" + { + PLpgSQL_stmt_if *new; + + new = palloc0(sizeof(PLpgSQL_stmt_if)); + new->cmd_type = PLPGSQL_STMT_IF; + new->lineno = plpgsql_location_to_lineno((yylsp[(1) - (8)])); + new->cond = (yyvsp[(2) - (8)].expr); + new->then_body = (yyvsp[(3) - (8)].list); + new->elsif_list = (yyvsp[(4) - (8)].list); + new->else_body = (yyvsp[(5) - (8)].list); + + (yyval.stmt) = (PLpgSQL_stmt *)new; + ;} + break; + + case 94: + +/* Line 1455 of yacc.c */ +#line 1028 "gram.y" + { + (yyval.list) = NIL; + ;} + break; + + case 95: + +/* Line 1455 of yacc.c */ +#line 1032 "gram.y" + { + PLpgSQL_if_elsif *new; + + new = palloc0(sizeof(PLpgSQL_if_elsif)); + new->lineno = plpgsql_location_to_lineno((yylsp[(2) - (4)])); + new->cond = (yyvsp[(3) - (4)].expr); + new->stmts = (yyvsp[(4) - (4)].list); + + (yyval.list) = lappend((yyvsp[(1) - (4)].list), new); + ;} + break; + + case 96: + +/* Line 1455 of yacc.c */ +#line 1045 "gram.y" + { + (yyval.list) = NIL; + ;} + break; + + case 97: + +/* Line 1455 of yacc.c */ +#line 1049 "gram.y" + { + (yyval.list) = (yyvsp[(2) - (2)].list); + ;} + break; + + case 98: + +/* Line 1455 of yacc.c */ +#line 1055 "gram.y" + { + (yyval.stmt) = make_case((yylsp[(1) - (7)]), (yyvsp[(2) - (7)].expr), (yyvsp[(3) - (7)].list), (yyvsp[(4) - (7)].list)); + ;} + break; + + case 99: + +/* Line 1455 of yacc.c */ +#line 1061 "gram.y" + { + PLpgSQL_expr *expr = NULL; + int tok = yylex(); + + if (tok != K_WHEN) + { + plpgsql_push_back_token(tok); + expr = read_sql_expression(K_WHEN, "WHEN"); + } + plpgsql_push_back_token(K_WHEN); + (yyval.expr) = expr; + ;} + break; + + case 100: + +/* Line 1455 of yacc.c */ +#line 1076 "gram.y" + { + (yyval.list) = lappend((yyvsp[(1) - (2)].list), (yyvsp[(2) - (2)].casewhen)); + ;} + break; + + case 101: + +/* Line 1455 of yacc.c */ +#line 1080 "gram.y" + { + (yyval.list) = list_make1((yyvsp[(1) - (1)].casewhen)); + ;} + break; + + case 102: + +/* Line 1455 of yacc.c */ +#line 1086 "gram.y" + { + PLpgSQL_case_when *new = palloc(sizeof(PLpgSQL_case_when)); + + new->lineno = plpgsql_location_to_lineno((yylsp[(1) - (3)])); + new->expr = (yyvsp[(2) - (3)].expr); + new->stmts = (yyvsp[(3) - (3)].list); + (yyval.casewhen) = new; + ;} + break; + + case 103: + +/* Line 1455 of yacc.c */ +#line 1097 "gram.y" + { + (yyval.list) = NIL; + ;} + break; + + case 104: + +/* Line 1455 of yacc.c */ +#line 1101 "gram.y" + { + /* + * proc_sect could return an empty list, but we + * must distinguish that from not having ELSE at all. + * Simplest fix is to return a list with one NULL + * pointer, which make_case() must take care of. + */ + if ((yyvsp[(2) - (2)].list) != NIL) + (yyval.list) = (yyvsp[(2) - (2)].list); + else + (yyval.list) = list_make1(NULL); + ;} + break; + + case 105: + +/* Line 1455 of yacc.c */ +#line 1116 "gram.y" + { + PLpgSQL_stmt_loop *new; + + new = palloc0(sizeof(PLpgSQL_stmt_loop)); + new->cmd_type = PLPGSQL_STMT_LOOP; + new->lineno = plpgsql_location_to_lineno((yylsp[(2) - (3)])); + new->label = (yyvsp[(1) - (3)].str); + new->body = (yyvsp[(3) - (3)].loop_body).stmts; + + check_labels((yyvsp[(1) - (3)].str), (yyvsp[(3) - (3)].loop_body).end_label, (yyvsp[(3) - (3)].loop_body).end_label_location); + plpgsql_ns_pop(); + + (yyval.stmt) = (PLpgSQL_stmt *)new; + ;} + break; + + case 106: + +/* Line 1455 of yacc.c */ +#line 1133 "gram.y" + { + PLpgSQL_stmt_while *new; + + new = palloc0(sizeof(PLpgSQL_stmt_while)); + new->cmd_type = PLPGSQL_STMT_WHILE; + new->lineno = plpgsql_location_to_lineno((yylsp[(2) - (4)])); + new->label = (yyvsp[(1) - (4)].str); + new->cond = (yyvsp[(3) - (4)].expr); + new->body = (yyvsp[(4) - (4)].loop_body).stmts; + + check_labels((yyvsp[(1) - (4)].str), (yyvsp[(4) - (4)].loop_body).end_label, (yyvsp[(4) - (4)].loop_body).end_label_location); + plpgsql_ns_pop(); + + (yyval.stmt) = (PLpgSQL_stmt *)new; + ;} + break; + + case 107: + +/* Line 1455 of yacc.c */ +#line 1151 "gram.y" + { + /* This runs after we've scanned the loop body */ + if ((yyvsp[(3) - (4)].stmt)->cmd_type == PLPGSQL_STMT_FORI) + { + PLpgSQL_stmt_fori *new; + + new = (PLpgSQL_stmt_fori *) (yyvsp[(3) - (4)].stmt); + new->lineno = plpgsql_location_to_lineno((yylsp[(2) - (4)])); + new->label = (yyvsp[(1) - (4)].str); + new->body = (yyvsp[(4) - (4)].loop_body).stmts; + (yyval.stmt) = (PLpgSQL_stmt *) new; + } + else + { + PLpgSQL_stmt_forq *new; + + Assert((yyvsp[(3) - (4)].stmt)->cmd_type == PLPGSQL_STMT_FORS || + (yyvsp[(3) - (4)].stmt)->cmd_type == PLPGSQL_STMT_FORC || + (yyvsp[(3) - (4)].stmt)->cmd_type == PLPGSQL_STMT_DYNFORS); + /* forq is the common supertype of all three */ + new = (PLpgSQL_stmt_forq *) (yyvsp[(3) - (4)].stmt); + new->lineno = plpgsql_location_to_lineno((yylsp[(2) - (4)])); + new->label = (yyvsp[(1) - (4)].str); + new->body = (yyvsp[(4) - (4)].loop_body).stmts; + (yyval.stmt) = (PLpgSQL_stmt *) new; + } + + check_labels((yyvsp[(1) - (4)].str), (yyvsp[(4) - (4)].loop_body).end_label, (yyvsp[(4) - (4)].loop_body).end_label_location); + /* close namespace started in opt_block_label */ + plpgsql_ns_pop(); + ;} + break; + + case 108: + +/* Line 1455 of yacc.c */ +#line 1185 "gram.y" + { + int tok = yylex(); + int tokloc = yylloc; + + if (tok == K_EXECUTE) + { + /* EXECUTE means it's a dynamic FOR loop */ + PLpgSQL_stmt_dynfors *new; + PLpgSQL_expr *expr; + int term; + + expr = read_sql_expression2(K_LOOP, K_USING, + "LOOP or USING", + &term); + + new = palloc0(sizeof(PLpgSQL_stmt_dynfors)); + new->cmd_type = PLPGSQL_STMT_DYNFORS; + if ((yyvsp[(1) - (2)].forvariable).rec) + { + new->rec = (yyvsp[(1) - (2)].forvariable).rec; + check_assignable((PLpgSQL_datum *) new->rec, (yylsp[(1) - (2)])); + } + else if ((yyvsp[(1) - (2)].forvariable).row) + { + new->row = (yyvsp[(1) - (2)].forvariable).row; + check_assignable((PLpgSQL_datum *) new->row, (yylsp[(1) - (2)])); + } + else if ((yyvsp[(1) - (2)].forvariable).scalar) + { + /* convert single scalar to list */ + new->row = make_scalar_list1((yyvsp[(1) - (2)].forvariable).name, (yyvsp[(1) - (2)].forvariable).scalar, + (yyvsp[(1) - (2)].forvariable).lineno, (yylsp[(1) - (2)])); + /* no need for check_assignable */ + } + else + { + ereport(ERROR, + (errcode(ERRCODE_DATATYPE_MISMATCH), + errmsg("loop variable of loop over rows must be a record or row variable or list of scalar variables"), + parser_errposition((yylsp[(1) - (2)])))); + } + new->query = expr; + + if (term == K_USING) + { + do + { + expr = read_sql_expression2(',', K_LOOP, + ", or LOOP", + &term); + new->params = lappend(new->params, expr); + } while (term == ','); + } + + (yyval.stmt) = (PLpgSQL_stmt *) new; + } + else if (tok == T_DATUM && + yylval.wdatum.datum->dtype == PLPGSQL_DTYPE_VAR && + ((PLpgSQL_var *) yylval.wdatum.datum)->datatype->typoid == REFCURSOROID) + { + /* It's FOR var IN cursor */ + PLpgSQL_stmt_forc *new; + PLpgSQL_var *cursor = (PLpgSQL_var *) yylval.wdatum.datum; + + new = (PLpgSQL_stmt_forc *) palloc0(sizeof(PLpgSQL_stmt_forc)); + new->cmd_type = PLPGSQL_STMT_FORC; + new->curvar = cursor->dno; + + /* Should have had a single variable name */ + if ((yyvsp[(1) - (2)].forvariable).scalar && (yyvsp[(1) - (2)].forvariable).row) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("cursor FOR loop must have only one target variable"), + parser_errposition((yylsp[(1) - (2)])))); + + /* can't use an unbound cursor this way */ + if (cursor->cursor_explicit_expr == NULL) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("cursor FOR loop must use a bound cursor variable"), + parser_errposition(tokloc))); + + /* collect cursor's parameters if any */ + new->argquery = read_cursor_args(cursor, + K_LOOP, + "LOOP"); + + /* create loop's private RECORD variable */ + new->rec = plpgsql_build_record((yyvsp[(1) - (2)].forvariable).name, + (yyvsp[(1) - (2)].forvariable).lineno, + true); + + (yyval.stmt) = (PLpgSQL_stmt *) new; + } + else + { + PLpgSQL_expr *expr1; + int expr1loc; + bool reverse = false; + + /* + * We have to distinguish between two + * alternatives: FOR var IN a .. b and FOR + * var IN query. Unfortunately this is + * tricky, since the query in the second + * form needn't start with a SELECT + * keyword. We use the ugly hack of + * looking for two periods after the first + * token. We also check for the REVERSE + * keyword, which means it must be an + * integer loop. + */ + if (tok_is_keyword(tok, &yylval, + K_REVERSE, "reverse")) + reverse = true; + else + plpgsql_push_back_token(tok); + + /* + * Read tokens until we see either a ".." + * or a LOOP. The text we read may not + * necessarily be a well-formed SQL + * statement, so we need to invoke + * read_sql_construct directly. + */ + expr1 = read_sql_construct(DOT_DOT, + K_LOOP, + 0, + "LOOP", + "SELECT ", + true, + false, + true, + &expr1loc, + &tok); + + if (tok == DOT_DOT) + { + /* Saw "..", so it must be an integer loop */ + PLpgSQL_expr *expr2; + PLpgSQL_expr *expr_by; + PLpgSQL_var *fvar; + PLpgSQL_stmt_fori *new; + + /* Check first expression is well-formed */ + check_sql_expr(expr1->query, expr1loc, 7); + + /* Read and check the second one */ + expr2 = read_sql_expression2(K_LOOP, K_BY, + "LOOP", + &tok); + + /* Get the BY clause if any */ + if (tok == K_BY) + expr_by = read_sql_expression(K_LOOP, + "LOOP"); + else + expr_by = NULL; + + /* Should have had a single variable name */ + if ((yyvsp[(1) - (2)].forvariable).scalar && (yyvsp[(1) - (2)].forvariable).row) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("integer FOR loop must have only one target variable"), + parser_errposition((yylsp[(1) - (2)])))); + + /* create loop's private variable */ + fvar = (PLpgSQL_var *) + plpgsql_build_variable((yyvsp[(1) - (2)].forvariable).name, + (yyvsp[(1) - (2)].forvariable).lineno, + plpgsql_build_datatype(INT4OID, + -1, + InvalidOid), + true); + + new = palloc0(sizeof(PLpgSQL_stmt_fori)); + new->cmd_type = PLPGSQL_STMT_FORI; + new->var = fvar; + new->reverse = reverse; + new->lower = expr1; + new->upper = expr2; + new->step = expr_by; + + (yyval.stmt) = (PLpgSQL_stmt *) new; + } + else + { + /* + * No "..", so it must be a query loop. We've + * prefixed an extra SELECT to the query text, + * so we need to remove that before performing + * syntax checking. + */ + char *tmp_query; + PLpgSQL_stmt_fors *new; + + if (reverse) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("cannot specify REVERSE in query FOR loop"), + parser_errposition(tokloc))); + + Assert(strncmp(expr1->query, "SELECT ", 7) == 0); + tmp_query = pstrdup(expr1->query + 7); + pfree(expr1->query); + expr1->query = tmp_query; + + check_sql_expr(expr1->query, expr1loc, 0); + + new = palloc0(sizeof(PLpgSQL_stmt_fors)); + new->cmd_type = PLPGSQL_STMT_FORS; + if ((yyvsp[(1) - (2)].forvariable).rec) + { + new->rec = (yyvsp[(1) - (2)].forvariable).rec; + check_assignable((PLpgSQL_datum *) new->rec, (yylsp[(1) - (2)])); + } + else if ((yyvsp[(1) - (2)].forvariable).row) + { + new->row = (yyvsp[(1) - (2)].forvariable).row; + check_assignable((PLpgSQL_datum *) new->row, (yylsp[(1) - (2)])); + } + else if ((yyvsp[(1) - (2)].forvariable).scalar) + { + /* convert single scalar to list */ + new->row = make_scalar_list1((yyvsp[(1) - (2)].forvariable).name, (yyvsp[(1) - (2)].forvariable).scalar, + (yyvsp[(1) - (2)].forvariable).lineno, (yylsp[(1) - (2)])); + /* no need for check_assignable */ + } + else + { + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("loop variable of loop over rows must be a record or row variable or list of scalar variables"), + parser_errposition((yylsp[(1) - (2)])))); + } + + new->query = expr1; + (yyval.stmt) = (PLpgSQL_stmt *) new; + } + } + ;} + break; + + case 109: + +/* Line 1455 of yacc.c */ +#line 1447 "gram.y" + { + (yyval.forvariable).name = NameOfDatum(&((yyvsp[(1) - (1)].wdatum))); + (yyval.forvariable).lineno = plpgsql_location_to_lineno((yylsp[(1) - (1)])); + if ((yyvsp[(1) - (1)].wdatum).datum->dtype == PLPGSQL_DTYPE_ROW) + { + (yyval.forvariable).scalar = NULL; + (yyval.forvariable).rec = NULL; + (yyval.forvariable).row = (PLpgSQL_row *) (yyvsp[(1) - (1)].wdatum).datum; + } + else if ((yyvsp[(1) - (1)].wdatum).datum->dtype == PLPGSQL_DTYPE_REC) + { + (yyval.forvariable).scalar = NULL; + (yyval.forvariable).rec = (PLpgSQL_rec *) (yyvsp[(1) - (1)].wdatum).datum; + (yyval.forvariable).row = NULL; + } + else + { + int tok; + + (yyval.forvariable).scalar = (yyvsp[(1) - (1)].wdatum).datum; + (yyval.forvariable).rec = NULL; + (yyval.forvariable).row = NULL; + /* check for comma-separated list */ + tok = yylex(); + plpgsql_push_back_token(tok); + if (tok == ',') + (yyval.forvariable).row = read_into_scalar_list((yyval.forvariable).name, + (yyval.forvariable).scalar, + (yylsp[(1) - (1)])); + } + ;} + break; + + case 110: + +/* Line 1455 of yacc.c */ +#line 1479 "gram.y" + { + int tok; + + (yyval.forvariable).name = (yyvsp[(1) - (1)].word).ident; + (yyval.forvariable).lineno = plpgsql_location_to_lineno((yylsp[(1) - (1)])); + (yyval.forvariable).scalar = NULL; + (yyval.forvariable).rec = NULL; + (yyval.forvariable).row = NULL; + /* check for comma-separated list */ + tok = yylex(); + plpgsql_push_back_token(tok); + if (tok == ',') + word_is_not_variable(&((yyvsp[(1) - (1)].word)), (yylsp[(1) - (1)])); + ;} + break; + + case 111: + +/* Line 1455 of yacc.c */ +#line 1494 "gram.y" + { + /* just to give a better message than "syntax error" */ + cword_is_not_variable(&((yyvsp[(1) - (1)].cword)), (yylsp[(1) - (1)])); + ;} + break; + + case 112: + +/* Line 1455 of yacc.c */ +#line 1501 "gram.y" + { + PLpgSQL_stmt_foreach_a *new; + + new = palloc0(sizeof(PLpgSQL_stmt_foreach_a)); + new->cmd_type = PLPGSQL_STMT_FOREACH_A; + new->lineno = plpgsql_location_to_lineno((yylsp[(2) - (8)])); + new->label = (yyvsp[(1) - (8)].str); + new->slice = (yyvsp[(4) - (8)].ival); + new->expr = (yyvsp[(7) - (8)].expr); + new->body = (yyvsp[(8) - (8)].loop_body).stmts; + + if ((yyvsp[(3) - (8)].forvariable).rec) + { + new->varno = (yyvsp[(3) - (8)].forvariable).rec->dno; + check_assignable((PLpgSQL_datum *) (yyvsp[(3) - (8)].forvariable).rec, (yylsp[(3) - (8)])); + } + else if ((yyvsp[(3) - (8)].forvariable).row) + { + new->varno = (yyvsp[(3) - (8)].forvariable).row->dno; + check_assignable((PLpgSQL_datum *) (yyvsp[(3) - (8)].forvariable).row, (yylsp[(3) - (8)])); + } + else if ((yyvsp[(3) - (8)].forvariable).scalar) + { + new->varno = (yyvsp[(3) - (8)].forvariable).scalar->dno; + check_assignable((yyvsp[(3) - (8)].forvariable).scalar, (yylsp[(3) - (8)])); + } + else + { + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("loop variable of FOREACH must be a known variable or list of variables"), + parser_errposition((yylsp[(3) - (8)])))); + } + + check_labels((yyvsp[(1) - (8)].str), (yyvsp[(8) - (8)].loop_body).end_label, (yyvsp[(8) - (8)].loop_body).end_label_location); + plpgsql_ns_pop(); + + (yyval.stmt) = (PLpgSQL_stmt *) new; + ;} + break; + + case 113: + +/* Line 1455 of yacc.c */ +#line 1543 "gram.y" + { + (yyval.ival) = 0; + ;} + break; + + case 114: + +/* Line 1455 of yacc.c */ +#line 1547 "gram.y" + { + (yyval.ival) = (yyvsp[(2) - (2)].ival); + ;} + break; + + case 115: + +/* Line 1455 of yacc.c */ +#line 1553 "gram.y" + { + PLpgSQL_stmt_exit *new; + + new = palloc0(sizeof(PLpgSQL_stmt_exit)); + new->cmd_type = PLPGSQL_STMT_EXIT; + new->is_exit = (yyvsp[(1) - (3)].boolean); + new->lineno = plpgsql_location_to_lineno((yylsp[(1) - (3)])); + new->label = (yyvsp[(2) - (3)].str); + new->cond = (yyvsp[(3) - (3)].expr); + + (yyval.stmt) = (PLpgSQL_stmt *)new; + ;} + break; + + case 116: + +/* Line 1455 of yacc.c */ +#line 1568 "gram.y" + { + (yyval.boolean) = true; + ;} + break; + + case 117: + +/* Line 1455 of yacc.c */ +#line 1572 "gram.y" + { + (yyval.boolean) = false; + ;} + break; + + case 118: + +/* Line 1455 of yacc.c */ +#line 1578 "gram.y" + { + int tok; + + tok = yylex(); + if (tok == 0) + yyerror("unexpected end of function definition"); + + if (tok_is_keyword(tok, &yylval, + K_NEXT, "next")) + { + (yyval.stmt) = make_return_next_stmt((yylsp[(1) - (1)])); + } + else if (tok_is_keyword(tok, &yylval, + K_QUERY, "query")) + { + (yyval.stmt) = make_return_query_stmt((yylsp[(1) - (1)])); + } + else + { + plpgsql_push_back_token(tok); + (yyval.stmt) = make_return_stmt((yylsp[(1) - (1)])); + } + ;} + break; + + case 119: + +/* Line 1455 of yacc.c */ +#line 1604 "gram.y" + { + PLpgSQL_stmt_raise *new; + int tok; + + new = palloc(sizeof(PLpgSQL_stmt_raise)); + + new->cmd_type = PLPGSQL_STMT_RAISE; + new->lineno = plpgsql_location_to_lineno((yylsp[(1) - (1)])); + new->elog_level = ERROR; /* default */ + new->condname = NULL; + new->message = NULL; + new->params = NIL; + new->options = NIL; + + tok = yylex(); + if (tok == 0) + yyerror("unexpected end of function definition"); + + /* + * We could have just RAISE, meaning to re-throw + * the current error. + */ + if (tok != ';') + { + /* + * First is an optional elog severity level. + */ + if (tok_is_keyword(tok, &yylval, + K_EXCEPTION, "exception")) + { + new->elog_level = ERROR; + tok = yylex(); + } + else if (tok_is_keyword(tok, &yylval, + K_WARNING, "warning")) + { + new->elog_level = WARNING; + tok = yylex(); + } + else if (tok_is_keyword(tok, &yylval, + K_NOTICE, "notice")) + { + new->elog_level = NOTICE; + tok = yylex(); + } + else if (tok_is_keyword(tok, &yylval, + K_INFO, "info")) + { + new->elog_level = INFO; + tok = yylex(); + } + else if (tok_is_keyword(tok, &yylval, + K_LOG, "log")) + { + new->elog_level = LOG; + tok = yylex(); + } + else if (tok_is_keyword(tok, &yylval, + K_DEBUG, "debug")) + { + new->elog_level = DEBUG1; + tok = yylex(); + } + if (tok == 0) + yyerror("unexpected end of function definition"); + + /* + * Next we can have a condition name, or + * equivalently SQLSTATE 'xxxxx', or a string + * literal that is the old-style message format, + * or USING to start the option list immediately. + */ + if (tok == SCONST) + { + /* old style message and parameters */ + new->message = yylval.str; + /* + * We expect either a semi-colon, which + * indicates no parameters, or a comma that + * begins the list of parameter expressions, + * or USING to begin the options list. + */ + tok = yylex(); + if (tok != ',' && tok != ';' && tok != K_USING) + yyerror("syntax error"); + + while (tok == ',') + { + PLpgSQL_expr *expr; + + expr = read_sql_construct(',', ';', K_USING, + ", or ; or USING", + "SELECT ", + true, true, true, + NULL, &tok); + new->params = lappend(new->params, expr); + } + } + else if (tok != K_USING) + { + /* must be condition name or SQLSTATE */ + if (tok_is_keyword(tok, &yylval, + K_SQLSTATE, "sqlstate")) + { + /* next token should be a string literal */ + char *sqlstatestr; + + if (yylex() != SCONST) + yyerror("syntax error"); + sqlstatestr = yylval.str; + + if (strlen(sqlstatestr) != 5) + yyerror("invalid SQLSTATE code"); + if (strspn(sqlstatestr, "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ") != 5) + yyerror("invalid SQLSTATE code"); + new->condname = sqlstatestr; + } + else + { + if (tok != T_WORD) + yyerror("syntax error"); + new->condname = yylval.word.ident; + plpgsql_recognize_err_condition(new->condname, + false); + } + tok = yylex(); + if (tok != ';' && tok != K_USING) + yyerror("syntax error"); + } + + if (tok == K_USING) + new->options = read_raise_options(); + } + + (yyval.stmt) = (PLpgSQL_stmt *)new; + ;} + break; + + case 120: + +/* Line 1455 of yacc.c */ +#line 1743 "gram.y" + { + (yyval.loop_body).stmts = (yyvsp[(1) - (5)].list); + (yyval.loop_body).end_label = (yyvsp[(4) - (5)].str); + (yyval.loop_body).end_label_location = (yylsp[(4) - (5)]); + ;} + break; + + case 121: + +/* Line 1455 of yacc.c */ +#line 1761 "gram.y" + { + (yyval.stmt) = make_execsql_stmt(K_INSERT, (yylsp[(1) - (1)])); + ;} + break; + + case 122: + +/* Line 1455 of yacc.c */ +#line 1765 "gram.y" + { + int tok; + + tok = yylex(); + plpgsql_push_back_token(tok); + if (tok == '=' || tok == COLON_EQUALS || tok == '[') + word_is_not_variable(&((yyvsp[(1) - (1)].word)), (yylsp[(1) - (1)])); + (yyval.stmt) = make_execsql_stmt(T_WORD, (yylsp[(1) - (1)])); + ;} + break; + + case 123: + +/* Line 1455 of yacc.c */ +#line 1775 "gram.y" + { + int tok; + + tok = yylex(); + plpgsql_push_back_token(tok); + if (tok == '=' || tok == COLON_EQUALS || tok == '[') + cword_is_not_variable(&((yyvsp[(1) - (1)].cword)), (yylsp[(1) - (1)])); + (yyval.stmt) = make_execsql_stmt(T_CWORD, (yylsp[(1) - (1)])); + ;} + break; + + case 124: + +/* Line 1455 of yacc.c */ +#line 1787 "gram.y" + { + PLpgSQL_stmt_dynexecute *new; + PLpgSQL_expr *expr; + int endtoken; + + expr = read_sql_construct(K_INTO, K_USING, ';', + "INTO or USING or ;", + "SELECT ", + true, true, true, + NULL, &endtoken); + + new = palloc(sizeof(PLpgSQL_stmt_dynexecute)); + new->cmd_type = PLPGSQL_STMT_DYNEXECUTE; + new->lineno = plpgsql_location_to_lineno((yylsp[(1) - (1)])); + new->query = expr; + new->into = false; + new->strict = false; + new->rec = NULL; + new->row = NULL; + new->params = NIL; + + /* + * We loop to allow the INTO and USING clauses to + * appear in either order, since people easily get + * that wrong. This coding also prevents "INTO foo" + * from getting absorbed into a USING expression, + * which is *really* confusing. + */ + for (;;) + { + if (endtoken == K_INTO) + { + if (new->into) /* multiple INTO */ + yyerror("syntax error"); + new->into = true; + read_into_target(&new->rec, &new->row, &new->strict); + endtoken = yylex(); + } + else if (endtoken == K_USING) + { + if (new->params) /* multiple USING */ + yyerror("syntax error"); + do + { + expr = read_sql_construct(',', ';', K_INTO, + ", or ; or INTO", + "SELECT ", + true, true, true, + NULL, &endtoken); + new->params = lappend(new->params, expr); + } while (endtoken == ','); + } + else if (endtoken == ';') + break; + else + yyerror("syntax error"); + } + + (yyval.stmt) = (PLpgSQL_stmt *)new; + ;} + break; + + case 125: + +/* Line 1455 of yacc.c */ +#line 1851 "gram.y" + { + PLpgSQL_stmt_open *new; + int tok; + + new = palloc0(sizeof(PLpgSQL_stmt_open)); + new->cmd_type = PLPGSQL_STMT_OPEN; + new->lineno = plpgsql_location_to_lineno((yylsp[(1) - (2)])); + new->curvar = (yyvsp[(2) - (2)].var)->dno; + new->cursor_options = CURSOR_OPT_FAST_PLAN; + + if ((yyvsp[(2) - (2)].var)->cursor_explicit_expr == NULL) + { + /* be nice if we could use opt_scrollable here */ + tok = yylex(); + if (tok_is_keyword(tok, &yylval, + K_NO, "no")) + { + tok = yylex(); + if (tok_is_keyword(tok, &yylval, + K_SCROLL, "scroll")) + { + new->cursor_options |= CURSOR_OPT_NO_SCROLL; + tok = yylex(); + } + } + else if (tok_is_keyword(tok, &yylval, + K_SCROLL, "scroll")) + { + new->cursor_options |= CURSOR_OPT_SCROLL; + tok = yylex(); + } + + if (tok != K_FOR) + yyerror("syntax error, expected \"FOR\""); + + tok = yylex(); + if (tok == K_EXECUTE) + { + int endtoken; + + new->dynquery = + read_sql_expression2(K_USING, ';', + "USING or ;", + &endtoken); + + /* If we found "USING", collect argument(s) */ + if (endtoken == K_USING) + { + PLpgSQL_expr *expr; + + do + { + expr = read_sql_expression2(',', ';', + ", or ;", + &endtoken); + new->params = lappend(new->params, + expr); + } while (endtoken == ','); + } + } + else + { + plpgsql_push_back_token(tok); + new->query = read_sql_stmt(""); + } + } + else + { + /* predefined cursor query, so read args */ + new->argquery = read_cursor_args((yyvsp[(2) - (2)].var), ';', ";"); + } + + (yyval.stmt) = (PLpgSQL_stmt *)new; + ;} + break; + + case 126: + +/* Line 1455 of yacc.c */ +#line 1928 "gram.y" + { + PLpgSQL_stmt_fetch *fetch = (yyvsp[(2) - (4)].fetch); + PLpgSQL_rec *rec; + PLpgSQL_row *row; + + /* We have already parsed everything through the INTO keyword */ + read_into_target(&rec, &row, NULL); + + if (yylex() != ';') + yyerror("syntax error"); + + /* + * We don't allow multiple rows in PL/pgSQL's FETCH + * statement, only in MOVE. + */ + if (fetch->returns_multiple_rows) + ereport(ERROR, + (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), + errmsg("FETCH statement cannot return multiple rows"), + parser_errposition((yylsp[(1) - (4)])))); + + fetch->lineno = plpgsql_location_to_lineno((yylsp[(1) - (4)])); + fetch->rec = rec; + fetch->row = row; + fetch->curvar = (yyvsp[(3) - (4)].var)->dno; + fetch->is_move = false; + + (yyval.stmt) = (PLpgSQL_stmt *)fetch; + ;} + break; + + case 127: + +/* Line 1455 of yacc.c */ +#line 1960 "gram.y" + { + PLpgSQL_stmt_fetch *fetch = (yyvsp[(2) - (4)].fetch); + + fetch->lineno = plpgsql_location_to_lineno((yylsp[(1) - (4)])); + fetch->curvar = (yyvsp[(3) - (4)].var)->dno; + fetch->is_move = true; + + (yyval.stmt) = (PLpgSQL_stmt *)fetch; + ;} + break; + + case 128: + +/* Line 1455 of yacc.c */ +#line 1972 "gram.y" + { + (yyval.fetch) = read_fetch_direction(); + ;} + break; + + case 129: + +/* Line 1455 of yacc.c */ +#line 1978 "gram.y" + { + PLpgSQL_stmt_close *new; + + new = palloc(sizeof(PLpgSQL_stmt_close)); + new->cmd_type = PLPGSQL_STMT_CLOSE; + new->lineno = plpgsql_location_to_lineno((yylsp[(1) - (3)])); + new->curvar = (yyvsp[(2) - (3)].var)->dno; + + (yyval.stmt) = (PLpgSQL_stmt *)new; + ;} + break; + + case 130: + +/* Line 1455 of yacc.c */ +#line 1991 "gram.y" + { + /* We do not bother building a node for NULL */ + (yyval.stmt) = NULL; + ;} + break; + + case 131: + +/* Line 1455 of yacc.c */ +#line 1998 "gram.y" + { + if ((yyvsp[(1) - (1)].wdatum).datum->dtype != PLPGSQL_DTYPE_VAR) + ereport(ERROR, + (errcode(ERRCODE_DATATYPE_MISMATCH), + errmsg("cursor variable must be a simple variable"), + parser_errposition((yylsp[(1) - (1)])))); + + if (((PLpgSQL_var *) (yyvsp[(1) - (1)].wdatum).datum)->datatype->typoid != REFCURSOROID) + ereport(ERROR, + (errcode(ERRCODE_DATATYPE_MISMATCH), + errmsg("variable \"%s\" must be of type cursor or refcursor", + ((PLpgSQL_var *) (yyvsp[(1) - (1)].wdatum).datum)->refname), + parser_errposition((yylsp[(1) - (1)])))); + (yyval.var) = (PLpgSQL_var *) (yyvsp[(1) - (1)].wdatum).datum; + ;} + break; + + case 132: + +/* Line 1455 of yacc.c */ +#line 2014 "gram.y" + { + /* just to give a better message than "syntax error" */ + word_is_not_variable(&((yyvsp[(1) - (1)].word)), (yylsp[(1) - (1)])); + ;} + break; + + case 133: + +/* Line 1455 of yacc.c */ +#line 2019 "gram.y" + { + /* just to give a better message than "syntax error" */ + cword_is_not_variable(&((yyvsp[(1) - (1)].cword)), (yylsp[(1) - (1)])); + ;} + break; + + case 134: + +/* Line 1455 of yacc.c */ +#line 2026 "gram.y" + { (yyval.exception_block) = NULL; ;} + break; + + case 135: + +/* Line 1455 of yacc.c */ +#line 2028 "gram.y" + { + /* + * We use a mid-rule action to add these + * special variables to the namespace before + * parsing the WHEN clauses themselves. The + * scope of the names extends to the end of the + * current block. + */ + int lineno = plpgsql_location_to_lineno((yylsp[(1) - (1)])); + PLpgSQL_exception_block *new = palloc(sizeof(PLpgSQL_exception_block)); + PLpgSQL_variable *var; + + var = plpgsql_build_variable("sqlstate", lineno, + plpgsql_build_datatype(TEXTOID, + -1, + plpgsql_curr_compile->fn_input_collation), + true); + ((PLpgSQL_var *) var)->isconst = true; + new->sqlstate_varno = var->dno; + + var = plpgsql_build_variable("sqlerrm", lineno, + plpgsql_build_datatype(TEXTOID, + -1, + plpgsql_curr_compile->fn_input_collation), + true); + ((PLpgSQL_var *) var)->isconst = true; + new->sqlerrm_varno = var->dno; + + (yyval.exception_block) = new; + ;} + break; + + case 136: + +/* Line 1455 of yacc.c */ +#line 2059 "gram.y" + { + PLpgSQL_exception_block *new = (yyvsp[(2) - (3)].exception_block); + new->exc_list = (yyvsp[(3) - (3)].list); + + (yyval.exception_block) = new; + ;} + break; + + case 137: + +/* Line 1455 of yacc.c */ +#line 2068 "gram.y" + { + (yyval.list) = lappend((yyvsp[(1) - (2)].list), (yyvsp[(2) - (2)].exception)); + ;} + break; + + case 138: + +/* Line 1455 of yacc.c */ +#line 2072 "gram.y" + { + (yyval.list) = list_make1((yyvsp[(1) - (1)].exception)); + ;} + break; + + case 139: + +/* Line 1455 of yacc.c */ +#line 2078 "gram.y" + { + PLpgSQL_exception *new; + + new = palloc0(sizeof(PLpgSQL_exception)); + new->lineno = plpgsql_location_to_lineno((yylsp[(1) - (4)])); + new->conditions = (yyvsp[(2) - (4)].condition); + new->action = (yyvsp[(4) - (4)].list); + + (yyval.exception) = new; + ;} + break; + + case 140: + +/* Line 1455 of yacc.c */ +#line 2091 "gram.y" + { + PLpgSQL_condition *old; + + for (old = (yyvsp[(1) - (3)].condition); old->next != NULL; old = old->next) + /* skip */ ; + old->next = (yyvsp[(3) - (3)].condition); + (yyval.condition) = (yyvsp[(1) - (3)].condition); + ;} + break; + + case 141: + +/* Line 1455 of yacc.c */ +#line 2100 "gram.y" + { + (yyval.condition) = (yyvsp[(1) - (1)].condition); + ;} + break; + + case 142: + +/* Line 1455 of yacc.c */ +#line 2106 "gram.y" + { + if (strcmp((yyvsp[(1) - (1)].str), "sqlstate") != 0) + { + (yyval.condition) = plpgsql_parse_err_condition((yyvsp[(1) - (1)].str)); + } + else + { + PLpgSQL_condition *new; + char *sqlstatestr; + + /* next token should be a string literal */ + if (yylex() != SCONST) + yyerror("syntax error"); + sqlstatestr = yylval.str; + + if (strlen(sqlstatestr) != 5) + yyerror("invalid SQLSTATE code"); + if (strspn(sqlstatestr, "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ") != 5) + yyerror("invalid SQLSTATE code"); + + new = palloc(sizeof(PLpgSQL_condition)); + new->sqlerrstate = + MAKE_SQLSTATE(sqlstatestr[0], + sqlstatestr[1], + sqlstatestr[2], + sqlstatestr[3], + sqlstatestr[4]); + new->condname = sqlstatestr; + new->next = NULL; + + (yyval.condition) = new; + } + ;} + break; + + case 143: + +/* Line 1455 of yacc.c */ +#line 2142 "gram.y" + { (yyval.expr) = read_sql_expression(';', ";"); ;} + break; + + case 144: + +/* Line 1455 of yacc.c */ +#line 2146 "gram.y" + { (yyval.expr) = read_sql_expression(']', "]"); ;} + break; + + case 145: + +/* Line 1455 of yacc.c */ +#line 2150 "gram.y" + { (yyval.expr) = read_sql_expression(K_THEN, "THEN"); ;} + break; + + case 146: + +/* Line 1455 of yacc.c */ +#line 2154 "gram.y" + { (yyval.expr) = read_sql_expression(K_LOOP, "LOOP"); ;} + break; + + case 147: + +/* Line 1455 of yacc.c */ +#line 2158 "gram.y" + { + plpgsql_ns_push(NULL); + (yyval.str) = NULL; + ;} + break; + + case 148: + +/* Line 1455 of yacc.c */ +#line 2163 "gram.y" + { + plpgsql_ns_push((yyvsp[(2) - (3)].str)); + (yyval.str) = (yyvsp[(2) - (3)].str); + ;} + break; + + case 149: + +/* Line 1455 of yacc.c */ +#line 2170 "gram.y" + { + (yyval.str) = NULL; + ;} + break; + + case 150: + +/* Line 1455 of yacc.c */ +#line 2174 "gram.y" + { + if (plpgsql_ns_lookup_label(plpgsql_ns_top(), (yyvsp[(1) - (1)].str)) == NULL) + yyerror("label does not exist"); + (yyval.str) = (yyvsp[(1) - (1)].str); + ;} + break; + + case 151: + +/* Line 1455 of yacc.c */ +#line 2182 "gram.y" + { (yyval.expr) = NULL; ;} + break; + + case 152: + +/* Line 1455 of yacc.c */ +#line 2184 "gram.y" + { (yyval.expr) = (yyvsp[(2) - (2)].expr); ;} + break; + + case 153: + +/* Line 1455 of yacc.c */ +#line 2191 "gram.y" + { + (yyval.str) = (yyvsp[(1) - (1)].word).ident; + ;} + break; + + case 154: + +/* Line 1455 of yacc.c */ +#line 2195 "gram.y" + { + if ((yyvsp[(1) - (1)].wdatum).ident == NULL) /* composite name not OK */ + yyerror("syntax error"); + (yyval.str) = (yyvsp[(1) - (1)].wdatum).ident; + ;} + break; + + + +/* Line 1455 of yacc.c */ +#line 4386 "pl_gram.c" + default: break; + } + YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); + + YYPOPSTACK (yylen); + yylen = 0; + YY_STACK_PRINT (yyss, yyssp); + + *++yyvsp = yyval; + *++yylsp = yyloc; + + /* Now `shift' the result of the reduction. Determine what state + that goes to, based on the state we popped back to and the rule + number reduced by. */ + + yyn = yyr1[yyn]; + + yystate = yypgoto[yyn - YYNTOKENS] + *yyssp; + if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp) + yystate = yytable[yystate]; + else + yystate = yydefgoto[yyn - YYNTOKENS]; + + goto yynewstate; + + +/*------------------------------------. +| yyerrlab -- here on detecting error | +`------------------------------------*/ +yyerrlab: + /* If not already recovering from an error, report this error. */ + if (!yyerrstatus) + { + ++yynerrs; +#if ! YYERROR_VERBOSE + yyerror (YY_("syntax error")); +#else + { + YYSIZE_T yysize = yysyntax_error (0, yystate, yychar); + if (yymsg_alloc < yysize && yymsg_alloc < YYSTACK_ALLOC_MAXIMUM) + { + YYSIZE_T yyalloc = 2 * yysize; + if (! (yysize <= yyalloc && yyalloc <= YYSTACK_ALLOC_MAXIMUM)) + yyalloc = YYSTACK_ALLOC_MAXIMUM; + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); + yymsg = (char *) YYSTACK_ALLOC (yyalloc); + if (yymsg) + yymsg_alloc = yyalloc; + else + { + yymsg = yymsgbuf; + yymsg_alloc = sizeof yymsgbuf; + } + } + + if (0 < yysize && yysize <= yymsg_alloc) + { + (void) yysyntax_error (yymsg, yystate, yychar); + yyerror (yymsg); + } + else + { + yyerror (YY_("syntax error")); + if (yysize != 0) + goto yyexhaustedlab; + } + } +#endif + } + + yyerror_range[0] = yylloc; + + if (yyerrstatus == 3) + { + /* If just tried and failed to reuse lookahead token after an + error, discard it. */ + + if (yychar <= YYEOF) + { + /* Return failure if at end of input. */ + if (yychar == YYEOF) + YYABORT; + } + else + { + yydestruct ("Error: discarding", + yytoken, &yylval, &yylloc); + yychar = YYEMPTY; + } + } + + /* Else will try to reuse lookahead token after shifting the error + token. */ + goto yyerrlab1; + + +/*---------------------------------------------------. +| yyerrorlab -- error raised explicitly by YYERROR. | +`---------------------------------------------------*/ +yyerrorlab: + + /* Pacify compilers like GCC when the user code never invokes + YYERROR and the label yyerrorlab therefore never appears in user + code. */ + if (/*CONSTCOND*/ 0) + goto yyerrorlab; + + yyerror_range[0] = yylsp[1-yylen]; + /* Do not reclaim the symbols of the rule which action triggered + this YYERROR. */ + YYPOPSTACK (yylen); + yylen = 0; + YY_STACK_PRINT (yyss, yyssp); + yystate = *yyssp; + goto yyerrlab1; + + +/*-------------------------------------------------------------. +| yyerrlab1 -- common code for both syntax error and YYERROR. | +`-------------------------------------------------------------*/ +yyerrlab1: + yyerrstatus = 3; /* Each real token shifted decrements this. */ + + for (;;) + { + yyn = yypact[yystate]; + if (yyn != YYPACT_NINF) + { + yyn += YYTERROR; + if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR) + { + yyn = yytable[yyn]; + if (0 < yyn) + break; + } + } + + /* Pop the current state because it cannot handle the error token. */ + if (yyssp == yyss) + YYABORT; + + yyerror_range[0] = *yylsp; + yydestruct ("Error: popping", + yystos[yystate], yyvsp, yylsp); + YYPOPSTACK (1); + yystate = *yyssp; + YY_STACK_PRINT (yyss, yyssp); + } + + *++yyvsp = yylval; + + yyerror_range[1] = yylloc; + /* Using YYLLOC is tempting, but would change the location of + the lookahead. YYLOC is available though. */ + YYLLOC_DEFAULT (yyloc, (yyerror_range - 1), 2); + *++yylsp = yyloc; + + /* Shift the error token. */ + YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp); + + yystate = yyn; + goto yynewstate; + + +/*-------------------------------------. +| yyacceptlab -- YYACCEPT comes here. | +`-------------------------------------*/ +yyacceptlab: + yyresult = 0; + goto yyreturn; + +/*-----------------------------------. +| yyabortlab -- YYABORT comes here. | +`-----------------------------------*/ +yyabortlab: + yyresult = 1; + goto yyreturn; + +#if !defined(yyoverflow) || YYERROR_VERBOSE +/*-------------------------------------------------. +| yyexhaustedlab -- memory exhaustion comes here. | +`-------------------------------------------------*/ +yyexhaustedlab: + yyerror (YY_("memory exhausted")); + yyresult = 2; + /* Fall through. */ +#endif + +yyreturn: + if (yychar != YYEMPTY) + yydestruct ("Cleanup: discarding lookahead", + yytoken, &yylval, &yylloc); + /* Do not reclaim the symbols of the rule which action triggered + this YYABORT or YYACCEPT. */ + YYPOPSTACK (yylen); + YY_STACK_PRINT (yyss, yyssp); + while (yyssp != yyss) + { + yydestruct ("Cleanup: popping", + yystos[*yyssp], yyvsp, yylsp); + YYPOPSTACK (1); + } +#ifndef yyoverflow + if (yyss != yyssa) + YYSTACK_FREE (yyss); +#endif +#if YYERROR_VERBOSE + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); +#endif + /* Make sure YYID is used. */ + return YYID (yyresult); +} + + + +/* Line 1675 of yacc.c */ +#line 2250 "gram.y" + + +/* + * Check whether a token represents an "unreserved keyword". + * We have various places where we want to recognize a keyword in preference + * to a variable name, but not reserve that keyword in other contexts. + * Hence, this kluge. + */ +static bool +tok_is_keyword(int token, union YYSTYPE *lval, + int kw_token, const char *kw_str) +{ + if (token == kw_token) + { + /* Normal case, was recognized by scanner (no conflicting variable) */ + return true; + } + else if (token == T_DATUM) + { + /* + * It's a variable, so recheck the string name. Note we will not + * match composite names (hence an unreserved word followed by "." + * will not be recognized). + */ + if (!lval->wdatum.quoted && lval->wdatum.ident != NULL && + strcmp(lval->wdatum.ident, kw_str) == 0) + return true; + } + return false; /* not the keyword */ +} + +/* + * Convenience routine to complain when we expected T_DATUM and got T_WORD, + * ie, unrecognized variable. + */ +static void +word_is_not_variable(PLword *word, int location) +{ + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("\"%s\" is not a known variable", + word->ident), + parser_errposition(location))); +} + +/* Same, for a CWORD */ +static void +cword_is_not_variable(PLcword *cword, int location) +{ + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("\"%s\" is not a known variable", + NameListToString(cword->idents)), + parser_errposition(location))); +} + +/* + * Convenience routine to complain when we expected T_DATUM and got + * something else. "tok" must be the current token, since we also + * look at yylval and yylloc. + */ +static void +current_token_is_not_variable(int tok) +{ + if (tok == T_WORD) + word_is_not_variable(&(yylval.word), yylloc); + else if (tok == T_CWORD) + cword_is_not_variable(&(yylval.cword), yylloc); + else + yyerror("syntax error"); +} + +/* Convenience routine to read an expression with one possible terminator */ +static PLpgSQL_expr * +read_sql_expression(int until, const char *expected) +{ + return read_sql_construct(until, 0, 0, expected, + "SELECT ", true, true, true, NULL, NULL); +} + +/* Convenience routine to read an expression with two possible terminators */ +static PLpgSQL_expr * +read_sql_expression2(int until, int until2, const char *expected, + int *endtoken) +{ + return read_sql_construct(until, until2, 0, expected, + "SELECT ", true, true, true, NULL, endtoken); +} + +/* Convenience routine to read a SQL statement that must end with ';' */ +static PLpgSQL_expr * +read_sql_stmt(const char *sqlstart) +{ + return read_sql_construct(';', 0, 0, ";", + sqlstart, false, true, true, NULL, NULL); +} + +/* + * Read a SQL construct and build a PLpgSQL_expr for it. + * + * until: token code for expected terminator + * until2: token code for alternate terminator (pass 0 if none) + * until3: token code for another alternate terminator (pass 0 if none) + * expected: text to use in complaining that terminator was not found + * sqlstart: text to prefix to the accumulated SQL text + * isexpression: whether to say we're reading an "expression" or a "statement" + * valid_sql: whether to check the syntax of the expr (prefixed with sqlstart) + * trim: trim trailing whitespace + * startloc: if not NULL, location of first token is stored at *startloc + * endtoken: if not NULL, ending token is stored at *endtoken + * (this is only interesting if until2 or until3 isn't zero) + */ +static PLpgSQL_expr * +read_sql_construct(int until, + int until2, + int until3, + const char *expected, + const char *sqlstart, + bool isexpression, + bool valid_sql, + bool trim, + int *startloc, + int *endtoken) +{ + int tok; + StringInfoData ds; + IdentifierLookup save_IdentifierLookup; + int startlocation = -1; + int parenlevel = 0; + PLpgSQL_expr *expr; + + initStringInfo(&ds); + appendStringInfoString(&ds, sqlstart); + + /* special lookup mode for identifiers within the SQL text */ + save_IdentifierLookup = plpgsql_IdentifierLookup; + plpgsql_IdentifierLookup = IDENTIFIER_LOOKUP_EXPR; + + for (;;) + { + tok = yylex(); + if (startlocation < 0) /* remember loc of first token */ + startlocation = yylloc; + if (tok == until && parenlevel == 0) + break; + if (tok == until2 && parenlevel == 0) + break; + if (tok == until3 && parenlevel == 0) + break; + if (tok == '(' || tok == '[') + parenlevel++; + else if (tok == ')' || tok == ']') + { + parenlevel--; + if (parenlevel < 0) + yyerror("mismatched parentheses"); + } + /* + * End of function definition is an error, and we don't expect to + * hit a semicolon either (unless it's the until symbol, in which + * case we should have fallen out above). + */ + if (tok == 0 || tok == ';') + { + if (parenlevel != 0) + yyerror("mismatched parentheses"); + if (isexpression) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("missing \"%s\" at end of SQL expression", + expected), + parser_errposition(yylloc))); + else + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("missing \"%s\" at end of SQL statement", + expected), + parser_errposition(yylloc))); + } + } + + plpgsql_IdentifierLookup = save_IdentifierLookup; + + if (startloc) + *startloc = startlocation; + if (endtoken) + *endtoken = tok; + + /* give helpful complaint about empty input */ + if (startlocation >= yylloc) + { + if (isexpression) + yyerror("missing expression"); + else + yyerror("missing SQL statement"); + } + + plpgsql_append_source_text(&ds, startlocation, yylloc); + + /* trim any trailing whitespace, for neatness */ + if (trim) + { + while (ds.len > 0 && scanner_isspace(ds.data[ds.len - 1])) + ds.data[--ds.len] = '\0'; + } + + expr = palloc0(sizeof(PLpgSQL_expr)); + expr->dtype = PLPGSQL_DTYPE_EXPR; + expr->query = pstrdup(ds.data); + expr->plan = NULL; + expr->paramnos = NULL; + expr->ns = plpgsql_ns_top(); + pfree(ds.data); + + if (valid_sql) + check_sql_expr(expr->query, startlocation, strlen(sqlstart)); + + return expr; +} + +static PLpgSQL_type * +read_datatype(int tok) +{ + StringInfoData ds; + char *type_name; + int startlocation; + PLpgSQL_type *result; + int parenlevel = 0; + + /* Should only be called while parsing DECLARE sections */ + Assert(plpgsql_IdentifierLookup == IDENTIFIER_LOOKUP_DECLARE); + + /* Often there will be a lookahead token, but if not, get one */ + if (tok == YYEMPTY) + tok = yylex(); + + startlocation = yylloc; + + /* + * If we have a simple or composite identifier, check for %TYPE + * and %ROWTYPE constructs. + */ + if (tok == T_WORD) + { + char *dtname = yylval.word.ident; + + tok = yylex(); + if (tok == '%') + { + tok = yylex(); + if (tok_is_keyword(tok, &yylval, + K_TYPE, "type")) + { + result = plpgsql_parse_wordtype(dtname); + if (result) + return result; + } + else if (tok_is_keyword(tok, &yylval, + K_ROWTYPE, "rowtype")) + { + result = plpgsql_parse_wordrowtype(dtname); + if (result) + return result; + } + } + } + else if (tok == T_CWORD) + { + List *dtnames = yylval.cword.idents; + + tok = yylex(); + if (tok == '%') + { + tok = yylex(); + if (tok_is_keyword(tok, &yylval, + K_TYPE, "type")) + { + result = plpgsql_parse_cwordtype(dtnames); + if (result) + return result; + } + else if (tok_is_keyword(tok, &yylval, + K_ROWTYPE, "rowtype")) + { + result = plpgsql_parse_cwordrowtype(dtnames); + if (result) + return result; + } + } + } + + while (tok != ';') + { + if (tok == 0) + { + if (parenlevel != 0) + yyerror("mismatched parentheses"); + else + yyerror("incomplete data type declaration"); + } + /* Possible followers for datatype in a declaration */ + if (tok == K_COLLATE || tok == K_NOT || + tok == '=' || tok == COLON_EQUALS || tok == K_DEFAULT) + break; + /* Possible followers for datatype in a cursor_arg list */ + if ((tok == ',' || tok == ')') && parenlevel == 0) + break; + if (tok == '(') + parenlevel++; + else if (tok == ')') + parenlevel--; + + tok = yylex(); + } + + /* set up ds to contain complete typename text */ + initStringInfo(&ds); + plpgsql_append_source_text(&ds, startlocation, yylloc); + type_name = ds.data; + + if (type_name[0] == '\0') + yyerror("missing data type declaration"); + + result = parse_datatype(type_name, startlocation); + + pfree(ds.data); + + plpgsql_push_back_token(tok); + + return result; +} + +static PLpgSQL_stmt * +make_execsql_stmt(int firsttoken, int location) +{ + StringInfoData ds; + IdentifierLookup save_IdentifierLookup; + PLpgSQL_stmt_execsql *execsql; + PLpgSQL_expr *expr; + PLpgSQL_row *row = NULL; + PLpgSQL_rec *rec = NULL; + int tok; + int prev_tok; + bool have_into = false; + bool have_strict = false; + int into_start_loc = -1; + int into_end_loc = -1; + + initStringInfo(&ds); + + /* special lookup mode for identifiers within the SQL text */ + save_IdentifierLookup = plpgsql_IdentifierLookup; + plpgsql_IdentifierLookup = IDENTIFIER_LOOKUP_EXPR; + + /* + * We have to special-case the sequence INSERT INTO, because we don't want + * that to be taken as an INTO-variables clause. Fortunately, this is the + * only valid use of INTO in a pl/pgsql SQL command, and INTO is already a + * fully reserved word in the main grammar. We have to treat it that way + * anywhere in the string, not only at the start; consider CREATE RULE + * containing an INSERT statement. + */ + tok = firsttoken; + for (;;) + { + prev_tok = tok; + tok = yylex(); + if (have_into && into_end_loc < 0) + into_end_loc = yylloc; /* token after the INTO part */ + if (tok == ';') + break; + if (tok == 0) + yyerror("unexpected end of function definition"); + + if (tok == K_INTO && prev_tok != K_INSERT) + { + if (have_into) + yyerror("INTO specified more than once"); + have_into = true; + into_start_loc = yylloc; + plpgsql_IdentifierLookup = IDENTIFIER_LOOKUP_NORMAL; + read_into_target(&rec, &row, &have_strict); + plpgsql_IdentifierLookup = IDENTIFIER_LOOKUP_EXPR; + } + } + + plpgsql_IdentifierLookup = save_IdentifierLookup; + + if (have_into) + { + /* + * Insert an appropriate number of spaces corresponding to the + * INTO text, so that locations within the redacted SQL statement + * still line up with those in the original source text. + */ + plpgsql_append_source_text(&ds, location, into_start_loc); + appendStringInfoSpaces(&ds, into_end_loc - into_start_loc); + plpgsql_append_source_text(&ds, into_end_loc, yylloc); + } + else + plpgsql_append_source_text(&ds, location, yylloc); + + /* trim any trailing whitespace, for neatness */ + while (ds.len > 0 && scanner_isspace(ds.data[ds.len - 1])) + ds.data[--ds.len] = '\0'; + + expr = palloc0(sizeof(PLpgSQL_expr)); + expr->dtype = PLPGSQL_DTYPE_EXPR; + expr->query = pstrdup(ds.data); + expr->plan = NULL; + expr->paramnos = NULL; + expr->ns = plpgsql_ns_top(); + pfree(ds.data); + + check_sql_expr(expr->query, location, 0); + + execsql = palloc(sizeof(PLpgSQL_stmt_execsql)); + execsql->cmd_type = PLPGSQL_STMT_EXECSQL; + execsql->lineno = plpgsql_location_to_lineno(location); + execsql->sqlstmt = expr; + execsql->into = have_into; + execsql->strict = have_strict; + execsql->rec = rec; + execsql->row = row; + + return (PLpgSQL_stmt *) execsql; +} + + +/* + * Read FETCH or MOVE direction clause (everything through FROM/IN). + */ +static PLpgSQL_stmt_fetch * +read_fetch_direction(void) +{ + PLpgSQL_stmt_fetch *fetch; + int tok; + bool check_FROM = true; + + /* + * We create the PLpgSQL_stmt_fetch struct here, but only fill in + * the fields arising from the optional direction clause + */ + fetch = (PLpgSQL_stmt_fetch *) palloc0(sizeof(PLpgSQL_stmt_fetch)); + fetch->cmd_type = PLPGSQL_STMT_FETCH; + /* set direction defaults: */ + fetch->direction = FETCH_FORWARD; + fetch->how_many = 1; + fetch->expr = NULL; + fetch->returns_multiple_rows = false; + + tok = yylex(); + if (tok == 0) + yyerror("unexpected end of function definition"); + + if (tok_is_keyword(tok, &yylval, + K_NEXT, "next")) + { + /* use defaults */ + } + else if (tok_is_keyword(tok, &yylval, + K_PRIOR, "prior")) + { + fetch->direction = FETCH_BACKWARD; + } + else if (tok_is_keyword(tok, &yylval, + K_FIRST, "first")) + { + fetch->direction = FETCH_ABSOLUTE; + } + else if (tok_is_keyword(tok, &yylval, + K_LAST, "last")) + { + fetch->direction = FETCH_ABSOLUTE; + fetch->how_many = -1; + } + else if (tok_is_keyword(tok, &yylval, + K_ABSOLUTE, "absolute")) + { + fetch->direction = FETCH_ABSOLUTE; + fetch->expr = read_sql_expression2(K_FROM, K_IN, + "FROM or IN", + NULL); + check_FROM = false; + } + else if (tok_is_keyword(tok, &yylval, + K_RELATIVE, "relative")) + { + fetch->direction = FETCH_RELATIVE; + fetch->expr = read_sql_expression2(K_FROM, K_IN, + "FROM or IN", + NULL); + check_FROM = false; + } + else if (tok_is_keyword(tok, &yylval, + K_ALL, "all")) + { + fetch->how_many = FETCH_ALL; + fetch->returns_multiple_rows = true; + } + else if (tok_is_keyword(tok, &yylval, + K_FORWARD, "forward")) + { + complete_direction(fetch, &check_FROM); + } + else if (tok_is_keyword(tok, &yylval, + K_BACKWARD, "backward")) + { + fetch->direction = FETCH_BACKWARD; + complete_direction(fetch, &check_FROM); + } + else if (tok == K_FROM || tok == K_IN) + { + /* empty direction */ + check_FROM = false; + } + else if (tok == T_DATUM) + { + /* Assume there's no direction clause and tok is a cursor name */ + plpgsql_push_back_token(tok); + check_FROM = false; + } + else + { + /* + * Assume it's a count expression with no preceding keyword. + * Note: we allow this syntax because core SQL does, but we don't + * document it because of the ambiguity with the omitted-direction + * case. For instance, "MOVE n IN c" will fail if n is a variable. + * Perhaps this can be improved someday, but it's hardly worth a + * lot of work. + */ + plpgsql_push_back_token(tok); + fetch->expr = read_sql_expression2(K_FROM, K_IN, + "FROM or IN", + NULL); + fetch->returns_multiple_rows = true; + check_FROM = false; + } + + /* check FROM or IN keyword after direction's specification */ + if (check_FROM) + { + tok = yylex(); + if (tok != K_FROM && tok != K_IN) + yyerror("expected FROM or IN"); + } + + return fetch; +} + +/* + * Process remainder of FETCH/MOVE direction after FORWARD or BACKWARD. + * Allows these cases: + * FORWARD expr, FORWARD ALL, FORWARD + * BACKWARD expr, BACKWARD ALL, BACKWARD + */ +static void +complete_direction(PLpgSQL_stmt_fetch *fetch, bool *check_FROM) +{ + int tok; + + tok = yylex(); + if (tok == 0) + yyerror("unexpected end of function definition"); + + if (tok == K_FROM || tok == K_IN) + { + *check_FROM = false; + return; + } + + if (tok == K_ALL) + { + fetch->how_many = FETCH_ALL; + fetch->returns_multiple_rows = true; + *check_FROM = true; + return; + } + + plpgsql_push_back_token(tok); + fetch->expr = read_sql_expression2(K_FROM, K_IN, + "FROM or IN", + NULL); + fetch->returns_multiple_rows = true; + *check_FROM = false; +} + + +static PLpgSQL_stmt * +make_return_stmt(int location) +{ + PLpgSQL_stmt_return *new; + + new = palloc0(sizeof(PLpgSQL_stmt_return)); + new->cmd_type = PLPGSQL_STMT_RETURN; + new->lineno = plpgsql_location_to_lineno(location); + new->expr = NULL; + new->retvarno = -1; + + if (plpgsql_curr_compile->fn_retset) + { + if (yylex() != ';') + ereport(ERROR, + (errcode(ERRCODE_DATATYPE_MISMATCH), + errmsg("RETURN cannot have a parameter in function returning set"), + errhint("Use RETURN NEXT or RETURN QUERY."), + parser_errposition(yylloc))); + } + else if (plpgsql_curr_compile->out_param_varno >= 0) + { + if (yylex() != ';') + ereport(ERROR, + (errcode(ERRCODE_DATATYPE_MISMATCH), + errmsg("RETURN cannot have a parameter in function with OUT parameters"), + parser_errposition(yylloc))); + new->retvarno = plpgsql_curr_compile->out_param_varno; + } + else if (plpgsql_curr_compile->fn_rettype == VOIDOID) + { + if (yylex() != ';') + ereport(ERROR, + (errcode(ERRCODE_DATATYPE_MISMATCH), + errmsg("RETURN cannot have a parameter in function returning void"), + parser_errposition(yylloc))); + } + else if (plpgsql_curr_compile->fn_retistuple) + { + switch (yylex()) + { + case K_NULL: + /* we allow this to support RETURN NULL in triggers */ + break; + + case T_DATUM: + if (yylval.wdatum.datum->dtype == PLPGSQL_DTYPE_ROW || + yylval.wdatum.datum->dtype == PLPGSQL_DTYPE_REC) + new->retvarno = yylval.wdatum.datum->dno; + else + ereport(ERROR, + (errcode(ERRCODE_DATATYPE_MISMATCH), + errmsg("RETURN must specify a record or row variable in function returning row"), + parser_errposition(yylloc))); + break; + + default: + ereport(ERROR, + (errcode(ERRCODE_DATATYPE_MISMATCH), + errmsg("RETURN must specify a record or row variable in function returning row"), + parser_errposition(yylloc))); + break; + } + if (yylex() != ';') + yyerror("syntax error"); + } + else + { + /* + * Note that a well-formed expression is _required_ here; + * anything else is a compile-time error. + */ + new->expr = read_sql_expression(';', ";"); + } + + return (PLpgSQL_stmt *) new; +} + + +static PLpgSQL_stmt * +make_return_next_stmt(int location) +{ + PLpgSQL_stmt_return_next *new; + + if (!plpgsql_curr_compile->fn_retset) + ereport(ERROR, + (errcode(ERRCODE_DATATYPE_MISMATCH), + errmsg("cannot use RETURN NEXT in a non-SETOF function"), + parser_errposition(location))); + + new = palloc0(sizeof(PLpgSQL_stmt_return_next)); + new->cmd_type = PLPGSQL_STMT_RETURN_NEXT; + new->lineno = plpgsql_location_to_lineno(location); + new->expr = NULL; + new->retvarno = -1; + + if (plpgsql_curr_compile->out_param_varno >= 0) + { + if (yylex() != ';') + ereport(ERROR, + (errcode(ERRCODE_DATATYPE_MISMATCH), + errmsg("RETURN NEXT cannot have a parameter in function with OUT parameters"), + parser_errposition(yylloc))); + new->retvarno = plpgsql_curr_compile->out_param_varno; + } + else if (plpgsql_curr_compile->fn_retistuple) + { + switch (yylex()) + { + case T_DATUM: + if (yylval.wdatum.datum->dtype == PLPGSQL_DTYPE_ROW || + yylval.wdatum.datum->dtype == PLPGSQL_DTYPE_REC) + new->retvarno = yylval.wdatum.datum->dno; + else + ereport(ERROR, + (errcode(ERRCODE_DATATYPE_MISMATCH), + errmsg("RETURN NEXT must specify a record or row variable in function returning row"), + parser_errposition(yylloc))); + break; + + default: + ereport(ERROR, + (errcode(ERRCODE_DATATYPE_MISMATCH), + errmsg("RETURN NEXT must specify a record or row variable in function returning row"), + parser_errposition(yylloc))); + break; + } + if (yylex() != ';') + yyerror("syntax error"); + } + else + new->expr = read_sql_expression(';', ";"); + + return (PLpgSQL_stmt *) new; +} + + +static PLpgSQL_stmt * +make_return_query_stmt(int location) +{ + PLpgSQL_stmt_return_query *new; + int tok; + + if (!plpgsql_curr_compile->fn_retset) + ereport(ERROR, + (errcode(ERRCODE_DATATYPE_MISMATCH), + errmsg("cannot use RETURN QUERY in a non-SETOF function"), + parser_errposition(location))); + + new = palloc0(sizeof(PLpgSQL_stmt_return_query)); + new->cmd_type = PLPGSQL_STMT_RETURN_QUERY; + new->lineno = plpgsql_location_to_lineno(location); + + /* check for RETURN QUERY EXECUTE */ + if ((tok = yylex()) != K_EXECUTE) + { + /* ordinary static query */ + plpgsql_push_back_token(tok); + new->query = read_sql_stmt(""); + } + else + { + /* dynamic SQL */ + int term; + + new->dynquery = read_sql_expression2(';', K_USING, "; or USING", + &term); + if (term == K_USING) + { + do + { + PLpgSQL_expr *expr; + + expr = read_sql_expression2(',', ';', ", or ;", &term); + new->params = lappend(new->params, expr); + } while (term == ','); + } + } + + return (PLpgSQL_stmt *) new; +} + + +/* convenience routine to fetch the name of a T_DATUM */ +static char * +NameOfDatum(PLwdatum *wdatum) +{ + if (wdatum->ident) + return wdatum->ident; + Assert(wdatum->idents != NIL); + return NameListToString(wdatum->idents); +} + +static void +check_assignable(PLpgSQL_datum *datum, int location) +{ + switch (datum->dtype) + { + case PLPGSQL_DTYPE_VAR: + if (((PLpgSQL_var *) datum)->isconst) + ereport(ERROR, + (errcode(ERRCODE_ERROR_IN_ASSIGNMENT), + errmsg("\"%s\" is declared CONSTANT", + ((PLpgSQL_var *) datum)->refname), + parser_errposition(location))); + break; + case PLPGSQL_DTYPE_ROW: + /* always assignable? */ + break; + case PLPGSQL_DTYPE_REC: + /* always assignable? What about NEW/OLD? */ + break; + case PLPGSQL_DTYPE_RECFIELD: + /* always assignable? */ + break; + case PLPGSQL_DTYPE_ARRAYELEM: + /* always assignable? */ + break; + default: + elog(ERROR, "unrecognized dtype: %d", datum->dtype); + break; + } +} + +/* + * Read the argument of an INTO clause. On entry, we have just read the + * INTO keyword. + */ +static void +read_into_target(PLpgSQL_rec **rec, PLpgSQL_row **row, bool *strict) +{ + int tok; + + /* Set default results */ + *rec = NULL; + *row = NULL; + if (strict) + *strict = false; + + tok = yylex(); + if (strict && tok == K_STRICT) + { + *strict = true; + tok = yylex(); + } + + /* + * Currently, a row or record variable can be the single INTO target, + * but not a member of a multi-target list. So we throw error if there + * is a comma after it, because that probably means the user tried to + * write a multi-target list. If this ever gets generalized, we should + * probably refactor read_into_scalar_list so it handles all cases. + */ + switch (tok) + { + case T_DATUM: + if (yylval.wdatum.datum->dtype == PLPGSQL_DTYPE_ROW) + { + check_assignable(yylval.wdatum.datum, yylloc); + *row = (PLpgSQL_row *) yylval.wdatum.datum; + + if ((tok = yylex()) == ',') + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("record or row variable cannot be part of multiple-item INTO list"), + parser_errposition(yylloc))); + plpgsql_push_back_token(tok); + } + else if (yylval.wdatum.datum->dtype == PLPGSQL_DTYPE_REC) + { + check_assignable(yylval.wdatum.datum, yylloc); + *rec = (PLpgSQL_rec *) yylval.wdatum.datum; + + if ((tok = yylex()) == ',') + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("record or row variable cannot be part of multiple-item INTO list"), + parser_errposition(yylloc))); + plpgsql_push_back_token(tok); + } + else + { + *row = read_into_scalar_list(NameOfDatum(&(yylval.wdatum)), + yylval.wdatum.datum, yylloc); + } + break; + + default: + /* just to give a better message than "syntax error" */ + current_token_is_not_variable(tok); + } +} + +/* + * Given the first datum and name in the INTO list, continue to read + * comma-separated scalar variables until we run out. Then construct + * and return a fake "row" variable that represents the list of + * scalars. + */ +static PLpgSQL_row * +read_into_scalar_list(char *initial_name, + PLpgSQL_datum *initial_datum, + int initial_location) +{ + int nfields; + char *fieldnames[1024]; + int varnos[1024]; + PLpgSQL_row *row; + int tok; + + check_assignable(initial_datum, initial_location); + fieldnames[0] = initial_name; + varnos[0] = initial_datum->dno; + nfields = 1; + + while ((tok = yylex()) == ',') + { + /* Check for array overflow */ + if (nfields >= 1024) + ereport(ERROR, + (errcode(ERRCODE_PROGRAM_LIMIT_EXCEEDED), + errmsg("too many INTO variables specified"), + parser_errposition(yylloc))); + + tok = yylex(); + switch (tok) + { + case T_DATUM: + check_assignable(yylval.wdatum.datum, yylloc); + if (yylval.wdatum.datum->dtype == PLPGSQL_DTYPE_ROW || + yylval.wdatum.datum->dtype == PLPGSQL_DTYPE_REC) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("\"%s\" is not a scalar variable", + NameOfDatum(&(yylval.wdatum))), + parser_errposition(yylloc))); + fieldnames[nfields] = NameOfDatum(&(yylval.wdatum)); + varnos[nfields++] = yylval.wdatum.datum->dno; + break; + + default: + /* just to give a better message than "syntax error" */ + current_token_is_not_variable(tok); + } + } + + /* + * We read an extra, non-comma token from yylex(), so push it + * back onto the input stream + */ + plpgsql_push_back_token(tok); + + row = palloc(sizeof(PLpgSQL_row)); + row->dtype = PLPGSQL_DTYPE_ROW; + row->refname = pstrdup("*internal*"); + row->lineno = plpgsql_location_to_lineno(initial_location); + row->rowtupdesc = NULL; + row->nfields = nfields; + row->fieldnames = palloc(sizeof(char *) * nfields); + row->varnos = palloc(sizeof(int) * nfields); + while (--nfields >= 0) + { + row->fieldnames[nfields] = fieldnames[nfields]; + row->varnos[nfields] = varnos[nfields]; + } + + plpgsql_adddatum((PLpgSQL_datum *)row); + + return row; +} + +/* + * Convert a single scalar into a "row" list. This is exactly + * like read_into_scalar_list except we never consume any input. + * + * Note: lineno could be computed from location, but since callers + * have it at hand already, we may as well pass it in. + */ +static PLpgSQL_row * +make_scalar_list1(char *initial_name, + PLpgSQL_datum *initial_datum, + int lineno, int location) +{ + PLpgSQL_row *row; + + check_assignable(initial_datum, location); + + row = palloc(sizeof(PLpgSQL_row)); + row->dtype = PLPGSQL_DTYPE_ROW; + row->refname = pstrdup("*internal*"); + row->lineno = lineno; + row->rowtupdesc = NULL; + row->nfields = 1; + row->fieldnames = palloc(sizeof(char *)); + row->varnos = palloc(sizeof(int)); + row->fieldnames[0] = initial_name; + row->varnos[0] = initial_datum->dno; + + plpgsql_adddatum((PLpgSQL_datum *)row); + + return row; +} + +/* + * When the PL/pgSQL parser expects to see a SQL statement, it is very + * liberal in what it accepts; for example, we often assume an + * unrecognized keyword is the beginning of a SQL statement. This + * avoids the need to duplicate parts of the SQL grammar in the + * PL/pgSQL grammar, but it means we can accept wildly malformed + * input. To try and catch some of the more obviously invalid input, + * we run the strings we expect to be SQL statements through the main + * SQL parser. + * + * We only invoke the raw parser (not the analyzer); this doesn't do + * any database access and does not check any semantic rules, it just + * checks for basic syntactic correctness. We do this here, rather + * than after parsing has finished, because a malformed SQL statement + * may cause the PL/pgSQL parser to become confused about statement + * borders. So it is best to bail out as early as we can. + * + * It is assumed that "stmt" represents a copy of the function source text + * beginning at offset "location", with leader text of length "leaderlen" + * (typically "SELECT ") prefixed to the source text. We use this assumption + * to transpose any error cursor position back to the function source text. + * If no error cursor is provided, we'll just point at "location". + */ +static void +check_sql_expr(const char *stmt, int location, int leaderlen) +{ + sql_error_callback_arg cbarg; + ErrorContextCallback syntax_errcontext; + MemoryContext oldCxt; + + if (!plpgsql_check_syntax) + return; + + cbarg.location = location; + cbarg.leaderlen = leaderlen; + + syntax_errcontext.callback = plpgsql_sql_error_callback; + syntax_errcontext.arg = &cbarg; + syntax_errcontext.previous = error_context_stack; + error_context_stack = &syntax_errcontext; + + oldCxt = MemoryContextSwitchTo(compile_tmp_cxt); + (void) raw_parser(stmt); + MemoryContextSwitchTo(oldCxt); + + /* Restore former ereport callback */ + error_context_stack = syntax_errcontext.previous; +} + +static void +plpgsql_sql_error_callback(void *arg) +{ + sql_error_callback_arg *cbarg = (sql_error_callback_arg *) arg; + int errpos; + + /* + * First, set up internalerrposition to point to the start of the + * statement text within the function text. Note this converts + * location (a byte offset) to a character number. + */ + parser_errposition(cbarg->location); + + /* + * If the core parser provided an error position, transpose it. + * Note we are dealing with 1-based character numbers at this point. + */ + errpos = geterrposition(); + if (errpos > cbarg->leaderlen) + { + int myerrpos = getinternalerrposition(); + + if (myerrpos > 0) /* safety check */ + internalerrposition(myerrpos + errpos - cbarg->leaderlen - 1); + } + + /* In any case, flush errposition --- we want internalerrpos only */ + errposition(0); +} + +/* + * Parse a SQL datatype name and produce a PLpgSQL_type structure. + * + * The heavy lifting is done elsewhere. Here we are only concerned + * with setting up an errcontext link that will let us give an error + * cursor pointing into the plpgsql function source, if necessary. + * This is handled the same as in check_sql_expr(), and we likewise + * expect that the given string is a copy from the source text. + */ +static PLpgSQL_type * +parse_datatype(const char *string, int location) +{ + Oid type_id; + int32 typmod; + sql_error_callback_arg cbarg; + ErrorContextCallback syntax_errcontext; + + cbarg.location = location; + cbarg.leaderlen = 0; + + syntax_errcontext.callback = plpgsql_sql_error_callback; + syntax_errcontext.arg = &cbarg; + syntax_errcontext.previous = error_context_stack; + error_context_stack = &syntax_errcontext; + + /* Let the main parser try to parse it under standard SQL rules */ + parseTypeString(string, &type_id, &typmod); + + /* Restore former ereport callback */ + error_context_stack = syntax_errcontext.previous; + + /* Okay, build a PLpgSQL_type data structure for it */ + return plpgsql_build_datatype(type_id, typmod, + plpgsql_curr_compile->fn_input_collation); +} + +/* + * Check block starting and ending labels match. + */ +static void +check_labels(const char *start_label, const char *end_label, int end_location) +{ + if (end_label) + { + if (!start_label) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("end label \"%s\" specified for unlabelled block", + end_label), + parser_errposition(end_location))); + + if (strcmp(start_label, end_label) != 0) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("end label \"%s\" differs from block's label \"%s\"", + end_label, start_label), + parser_errposition(end_location))); + } +} + +/* + * Read the arguments (if any) for a cursor, followed by the until token + * + * If cursor has no args, just swallow the until token and return NULL. + * If it does have args, we expect to see "( arg [, arg ...] )" followed + * by the until token, where arg may be a plain expression, or a named + * parameter assignment of the form argname := expr. Consume all that and + * return a SELECT query that evaluates the expression(s) (without the outer + * parens). + */ +static PLpgSQL_expr * +read_cursor_args(PLpgSQL_var *cursor, int until, const char *expected) +{ + PLpgSQL_expr *expr; + PLpgSQL_row *row; + int tok; + int argc; + char **argv; + StringInfoData ds; + char *sqlstart = "SELECT "; + bool any_named = false; + + tok = yylex(); + if (cursor->cursor_explicit_argrow < 0) + { + /* No arguments expected */ + if (tok == '(') + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("cursor \"%s\" has no arguments", + cursor->refname), + parser_errposition(yylloc))); + + if (tok != until) + yyerror("syntax error"); + + return NULL; + } + + /* Else better provide arguments */ + if (tok != '(') + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("cursor \"%s\" has arguments", + cursor->refname), + parser_errposition(yylloc))); + + /* + * Read the arguments, one by one. + */ + row = (PLpgSQL_row *) plpgsql_Datums[cursor->cursor_explicit_argrow]; + argv = (char **) palloc0(row->nfields * sizeof(char *)); + + for (argc = 0; argc < row->nfields; argc++) + { + PLpgSQL_expr *item; + int endtoken; + int argpos; + int tok1, + tok2; + int arglocation; + + /* Check if it's a named parameter: "param := value" */ + plpgsql_peek2(&tok1, &tok2, &arglocation, NULL); + if (tok1 == IDENT && tok2 == COLON_EQUALS) + { + char *argname; + IdentifierLookup save_IdentifierLookup; + + /* Read the argument name, ignoring any matching variable */ + save_IdentifierLookup = plpgsql_IdentifierLookup; + plpgsql_IdentifierLookup = IDENTIFIER_LOOKUP_DECLARE; + yylex(); + argname = yylval.str; + plpgsql_IdentifierLookup = save_IdentifierLookup; + + /* Match argument name to cursor arguments */ + for (argpos = 0; argpos < row->nfields; argpos++) + { + if (strcmp(row->fieldnames[argpos], argname) == 0) + break; + } + if (argpos == row->nfields) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("cursor \"%s\" has no argument named \"%s\"", + cursor->refname, argname), + parser_errposition(yylloc))); + + /* + * Eat the ":=". We already peeked, so the error should never + * happen. + */ + tok2 = yylex(); + if (tok2 != COLON_EQUALS) + yyerror("syntax error"); + + any_named = true; + } + else + argpos = argc; + + if (argv[argpos] != NULL) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("value for parameter \"%s\" of cursor \"%s\" specified more than once", + row->fieldnames[argpos], cursor->refname), + parser_errposition(arglocation))); + + /* + * Read the value expression. To provide the user with meaningful + * parse error positions, we check the syntax immediately, instead of + * checking the final expression that may have the arguments + * reordered. Trailing whitespace must not be trimmed, because + * otherwise input of the form (param -- comment\n, param) would be + * translated into a form where the second parameter is commented + * out. + */ + item = read_sql_construct(',', ')', 0, + ",\" or \")", + sqlstart, + true, true, + false, /* do not trim */ + NULL, &endtoken); + + argv[argpos] = item->query + strlen(sqlstart); + + if (endtoken == ')' && !(argc == row->nfields - 1)) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("not enough arguments for cursor \"%s\"", + cursor->refname), + parser_errposition(yylloc))); + + if (endtoken == ',' && (argc == row->nfields - 1)) + ereport(ERROR, + (errcode(ERRCODE_SYNTAX_ERROR), + errmsg("too many arguments for cursor \"%s\"", + cursor->refname), + parser_errposition(yylloc))); + } + + /* Make positional argument list */ + initStringInfo(&ds); + appendStringInfoString(&ds, sqlstart); + for (argc = 0; argc < row->nfields; argc++) + { + Assert(argv[argc] != NULL); + + /* + * Because named notation allows permutated argument lists, include + * the parameter name for meaningful runtime errors. + */ + appendStringInfoString(&ds, argv[argc]); + if (any_named) + appendStringInfo(&ds, " AS %s", + quote_identifier(row->fieldnames[argc])); + if (argc < row->nfields - 1) + appendStringInfoString(&ds, ", "); + } + appendStringInfoChar(&ds, ';'); + + expr = palloc0(sizeof(PLpgSQL_expr)); + expr->dtype = PLPGSQL_DTYPE_EXPR; + expr->query = pstrdup(ds.data); + expr->plan = NULL; + expr->paramnos = NULL; + expr->ns = plpgsql_ns_top(); + pfree(ds.data); + + /* Next we'd better find the until token */ + tok = yylex(); + if (tok != until) + yyerror("syntax error"); + + return expr; +} + +/* + * Parse RAISE ... USING options + */ +static List * +read_raise_options(void) +{ + List *result = NIL; + + for (;;) + { + PLpgSQL_raise_option *opt; + int tok; + + if ((tok = yylex()) == 0) + yyerror("unexpected end of function definition"); + + opt = (PLpgSQL_raise_option *) palloc(sizeof(PLpgSQL_raise_option)); + + if (tok_is_keyword(tok, &yylval, + K_ERRCODE, "errcode")) + opt->opt_type = PLPGSQL_RAISEOPTION_ERRCODE; + else if (tok_is_keyword(tok, &yylval, + K_MESSAGE, "message")) + opt->opt_type = PLPGSQL_RAISEOPTION_MESSAGE; + else if (tok_is_keyword(tok, &yylval, + K_DETAIL, "detail")) + opt->opt_type = PLPGSQL_RAISEOPTION_DETAIL; + else if (tok_is_keyword(tok, &yylval, + K_HINT, "hint")) + opt->opt_type = PLPGSQL_RAISEOPTION_HINT; + else + yyerror("unrecognized RAISE statement option"); + + tok = yylex(); + if (tok != '=' && tok != COLON_EQUALS) + yyerror("syntax error, expected \"=\""); + + opt->expr = read_sql_expression2(',', ';', ", or ;", &tok); + + result = lappend(result, opt); + + if (tok == ';') + break; + } + + return result; +} + +/* + * Fix up CASE statement + */ +static PLpgSQL_stmt * +make_case(int location, PLpgSQL_expr *t_expr, + List *case_when_list, List *else_stmts) +{ + PLpgSQL_stmt_case *new; + + new = palloc(sizeof(PLpgSQL_stmt_case)); + new->cmd_type = PLPGSQL_STMT_CASE; + new->lineno = plpgsql_location_to_lineno(location); + new->t_expr = t_expr; + new->t_varno = 0; + new->case_when_list = case_when_list; + new->have_else = (else_stmts != NIL); + /* Get rid of list-with-NULL hack */ + if (list_length(else_stmts) == 1 && linitial(else_stmts) == NULL) + new->else_stmts = NIL; + else + new->else_stmts = else_stmts; + + /* + * When test expression is present, we create a var for it and then + * convert all the WHEN expressions to "VAR IN (original_expression)". + * This is a bit klugy, but okay since we haven't yet done more than + * read the expressions as text. (Note that previous parsing won't + * have complained if the WHEN ... THEN expression contained multiple + * comma-separated values.) + */ + if (t_expr) + { + char varname[32]; + PLpgSQL_var *t_var; + ListCell *l; + + /* use a name unlikely to collide with any user names */ + snprintf(varname, sizeof(varname), "__Case__Variable_%d__", + plpgsql_nDatums); + + /* + * We don't yet know the result datatype of t_expr. Build the + * variable as if it were INT4; we'll fix this at runtime if needed. + */ + t_var = (PLpgSQL_var *) + plpgsql_build_variable(varname, new->lineno, + plpgsql_build_datatype(INT4OID, + -1, + InvalidOid), + true); + new->t_varno = t_var->dno; + + foreach(l, case_when_list) + { + PLpgSQL_case_when *cwt = (PLpgSQL_case_when *) lfirst(l); + PLpgSQL_expr *expr = cwt->expr; + StringInfoData ds; + + /* copy expression query without SELECT keyword (expr->query + 7) */ + Assert(strncmp(expr->query, "SELECT ", 7) == 0); + + /* And do the string hacking */ + initStringInfo(&ds); + + appendStringInfo(&ds, "SELECT \"%s\" IN (%s)", + varname, expr->query + 7); + + pfree(expr->query); + expr->query = pstrdup(ds.data); + /* Adjust expr's namespace to include the case variable */ + expr->ns = plpgsql_ns_top(); + + pfree(ds.data); + } + } + + return (PLpgSQL_stmt *) new; +} + diff --git a/src/pl/plpgsql/src/pl_gram.h b/src/pl/plpgsql/src/pl_gram.h new file mode 100644 index 000000000..6b41f3438 --- /dev/null +++ b/src/pl/plpgsql/src/pl_gram.h @@ -0,0 +1,231 @@ + +/* A Bison parser, made by GNU Bison 2.4.1. */ + +/* Skeleton interface for Bison's Yacc-like parsers in C + + Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 + Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . */ + +/* As a special exception, you may create a larger work that contains + part or all of the Bison parser skeleton and distribute that work + under terms of your choice, so long as that work isn't itself a + parser generator using the skeleton or a modified version thereof + as a parser skeleton. Alternatively, if you modify or redistribute + the parser skeleton itself, you may (at your option) remove this + special exception, which will cause the skeleton and the resulting + Bison output files to be licensed under the GNU General Public + License without this special exception. + + This special exception was added by the Free Software Foundation in + version 2.2 of Bison. */ + + +/* Tokens. */ +#ifndef YYTOKENTYPE +# define YYTOKENTYPE + /* Put the tokens into the symbol table, so that GDB and other debuggers + know about them. */ + enum yytokentype { + IDENT = 258, + FCONST = 259, + SCONST = 260, + BCONST = 261, + XCONST = 262, + Op = 263, + ICONST = 264, + PARAM = 265, + TYPECAST = 266, + DOT_DOT = 267, + COLON_EQUALS = 268, + T_WORD = 269, + T_CWORD = 270, + T_DATUM = 271, + LESS_LESS = 272, + GREATER_GREATER = 273, + K_ABSOLUTE = 274, + K_ALIAS = 275, + K_ALL = 276, + K_ARRAY = 277, + K_BACKWARD = 278, + K_BEGIN = 279, + K_BY = 280, + K_CASE = 281, + K_CLOSE = 282, + K_COLLATE = 283, + K_CONSTANT = 284, + K_CONTINUE = 285, + K_CURRENT = 286, + K_CURSOR = 287, + K_DEBUG = 288, + K_DECLARE = 289, + K_DEFAULT = 290, + K_DETAIL = 291, + K_DIAGNOSTICS = 292, + K_DUMP = 293, + K_ELSE = 294, + K_ELSIF = 295, + K_END = 296, + K_ERRCODE = 297, + K_ERROR = 298, + K_EXCEPTION = 299, + K_EXECUTE = 300, + K_EXIT = 301, + K_FETCH = 302, + K_FIRST = 303, + K_FOR = 304, + K_FOREACH = 305, + K_FORWARD = 306, + K_FROM = 307, + K_GET = 308, + K_HINT = 309, + K_IF = 310, + K_IN = 311, + K_INFO = 312, + K_INSERT = 313, + K_INTO = 314, + K_IS = 315, + K_LAST = 316, + K_LOG = 317, + K_LOOP = 318, + K_MESSAGE = 319, + K_MESSAGE_TEXT = 320, + K_MOVE = 321, + K_NEXT = 322, + K_NO = 323, + K_NOT = 324, + K_NOTICE = 325, + K_NULL = 326, + K_OPEN = 327, + K_OPTION = 328, + K_OR = 329, + K_PERFORM = 330, + K_PG_EXCEPTION_CONTEXT = 331, + K_PG_EXCEPTION_DETAIL = 332, + K_PG_EXCEPTION_HINT = 333, + K_PRIOR = 334, + K_QUERY = 335, + K_RAISE = 336, + K_RELATIVE = 337, + K_RESULT_OID = 338, + K_RETURN = 339, + K_RETURNED_SQLSTATE = 340, + K_REVERSE = 341, + K_ROWTYPE = 342, + K_ROW_COUNT = 343, + K_SCROLL = 344, + K_SLICE = 345, + K_SQLSTATE = 346, + K_STACKED = 347, + K_STRICT = 348, + K_THEN = 349, + K_TO = 350, + K_TYPE = 351, + K_USE_COLUMN = 352, + K_USE_VARIABLE = 353, + K_USING = 354, + K_VARIABLE_CONFLICT = 355, + K_WARNING = 356, + K_WHEN = 357, + K_WHILE = 358 + }; +#endif + + + +#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED +typedef union YYSTYPE +{ + +/* Line 1676 of yacc.c */ +#line 116 "gram.y" + + core_YYSTYPE core_yystype; + /* these fields must match core_YYSTYPE: */ + int ival; + char *str; + const char *keyword; + + PLword word; + PLcword cword; + PLwdatum wdatum; + bool boolean; + Oid oid; + struct + { + char *name; + int lineno; + } varname; + struct + { + char *name; + int lineno; + PLpgSQL_datum *scalar; + PLpgSQL_rec *rec; + PLpgSQL_row *row; + } forvariable; + struct + { + char *label; + int n_initvars; + int *initvarnos; + } declhdr; + struct + { + List *stmts; + char *end_label; + int end_label_location; + } loop_body; + List *list; + PLpgSQL_type *dtype; + PLpgSQL_datum *datum; + PLpgSQL_var *var; + PLpgSQL_expr *expr; + PLpgSQL_stmt *stmt; + PLpgSQL_condition *condition; + PLpgSQL_exception *exception; + PLpgSQL_exception_block *exception_block; + PLpgSQL_nsitem *nsitem; + PLpgSQL_diag_item *diagitem; + PLpgSQL_stmt_fetch *fetch; + PLpgSQL_case_when *casewhen; + + + +/* Line 1676 of yacc.c */ +#line 209 "pl_gram.h" +} YYSTYPE; +# define YYSTYPE_IS_TRIVIAL 1 +# define yystype YYSTYPE /* obsolescent; will be withdrawn */ +# define YYSTYPE_IS_DECLARED 1 +#endif + +extern YYSTYPE plpgsql_yylval; + +#if ! defined YYLTYPE && ! defined YYLTYPE_IS_DECLARED +typedef struct YYLTYPE +{ + int first_line; + int first_column; + int last_line; + int last_column; +} YYLTYPE; +# define yyltype YYLTYPE /* obsolescent; will be withdrawn */ +# define YYLTYPE_IS_DECLARED 1 +# define YYLTYPE_IS_TRIVIAL 1 +#endif + +extern YYLTYPE plpgsql_yylloc; + diff --git a/src/pl/plpgsql/src/plerrcodes.h b/src/pl/plpgsql/src/plerrcodes.h new file mode 100644 index 000000000..3d6c27457 --- /dev/null +++ b/src/pl/plpgsql/src/plerrcodes.h @@ -0,0 +1,886 @@ +/* autogenerated from src/backend/utils/errcodes.txt, do not edit */ +/* there is deliberately not an #ifndef PLERRCODES_H here */ +{ + "sql_statement_not_yet_complete", ERRCODE_SQL_STATEMENT_NOT_YET_COMPLETE +}, + +{ + "connection_exception", ERRCODE_CONNECTION_EXCEPTION +}, + +{ + "connection_does_not_exist", ERRCODE_CONNECTION_DOES_NOT_EXIST +}, + +{ + "connection_failure", ERRCODE_CONNECTION_FAILURE +}, + +{ + "sqlclient_unable_to_establish_sqlconnection", ERRCODE_SQLCLIENT_UNABLE_TO_ESTABLISH_SQLCONNECTION +}, + +{ + "sqlserver_rejected_establishment_of_sqlconnection", ERRCODE_SQLSERVER_REJECTED_ESTABLISHMENT_OF_SQLCONNECTION +}, + +{ + "transaction_resolution_unknown", ERRCODE_TRANSACTION_RESOLUTION_UNKNOWN +}, + +{ + "protocol_violation", ERRCODE_PROTOCOL_VIOLATION +}, + +{ + "triggered_action_exception", ERRCODE_TRIGGERED_ACTION_EXCEPTION +}, + +{ + "feature_not_supported", ERRCODE_FEATURE_NOT_SUPPORTED +}, + +{ + "invalid_transaction_initiation", ERRCODE_INVALID_TRANSACTION_INITIATION +}, + +{ + "locator_exception", ERRCODE_LOCATOR_EXCEPTION +}, + +{ + "invalid_locator_specification", ERRCODE_L_E_INVALID_SPECIFICATION +}, + +{ + "invalid_grantor", ERRCODE_INVALID_GRANTOR +}, + +{ + "invalid_grant_operation", ERRCODE_INVALID_GRANT_OPERATION +}, + +{ + "invalid_role_specification", ERRCODE_INVALID_ROLE_SPECIFICATION +}, + +{ + "diagnostics_exception", ERRCODE_DIAGNOSTICS_EXCEPTION +}, + +{ + "stacked_diagnostics_accessed_without_active_handler", ERRCODE_STACKED_DIAGNOSTICS_ACCESSED_WITHOUT_ACTIVE_HANDLER +}, + +{ + "case_not_found", ERRCODE_CASE_NOT_FOUND +}, + +{ + "cardinality_violation", ERRCODE_CARDINALITY_VIOLATION +}, + +{ + "data_exception", ERRCODE_DATA_EXCEPTION +}, + +{ + "array_subscript_error", ERRCODE_ARRAY_SUBSCRIPT_ERROR +}, + +{ + "character_not_in_repertoire", ERRCODE_CHARACTER_NOT_IN_REPERTOIRE +}, + +{ + "datetime_field_overflow", ERRCODE_DATETIME_FIELD_OVERFLOW +}, + +{ + "division_by_zero", ERRCODE_DIVISION_BY_ZERO +}, + +{ + "error_in_assignment", ERRCODE_ERROR_IN_ASSIGNMENT +}, + +{ + "escape_character_conflict", ERRCODE_ESCAPE_CHARACTER_CONFLICT +}, + +{ + "indicator_overflow", ERRCODE_INDICATOR_OVERFLOW +}, + +{ + "interval_field_overflow", ERRCODE_INTERVAL_FIELD_OVERFLOW +}, + +{ + "invalid_argument_for_logarithm", ERRCODE_INVALID_ARGUMENT_FOR_LOG +}, + +{ + "invalid_argument_for_ntile_function", ERRCODE_INVALID_ARGUMENT_FOR_NTILE +}, + +{ + "invalid_argument_for_nth_value_function", ERRCODE_INVALID_ARGUMENT_FOR_NTH_VALUE +}, + +{ + "invalid_argument_for_power_function", ERRCODE_INVALID_ARGUMENT_FOR_POWER_FUNCTION +}, + +{ + "invalid_argument_for_width_bucket_function", ERRCODE_INVALID_ARGUMENT_FOR_WIDTH_BUCKET_FUNCTION +}, + +{ + "invalid_character_value_for_cast", ERRCODE_INVALID_CHARACTER_VALUE_FOR_CAST +}, + +{ + "invalid_datetime_format", ERRCODE_INVALID_DATETIME_FORMAT +}, + +{ + "invalid_escape_character", ERRCODE_INVALID_ESCAPE_CHARACTER +}, + +{ + "invalid_escape_octet", ERRCODE_INVALID_ESCAPE_OCTET +}, + +{ + "invalid_escape_sequence", ERRCODE_INVALID_ESCAPE_SEQUENCE +}, + +{ + "nonstandard_use_of_escape_character", ERRCODE_NONSTANDARD_USE_OF_ESCAPE_CHARACTER +}, + +{ + "invalid_indicator_parameter_value", ERRCODE_INVALID_INDICATOR_PARAMETER_VALUE +}, + +{ + "invalid_parameter_value", ERRCODE_INVALID_PARAMETER_VALUE +}, + +{ + "invalid_regular_expression", ERRCODE_INVALID_REGULAR_EXPRESSION +}, + +{ + "invalid_row_count_in_limit_clause", ERRCODE_INVALID_ROW_COUNT_IN_LIMIT_CLAUSE +}, + +{ + "invalid_row_count_in_result_offset_clause", ERRCODE_INVALID_ROW_COUNT_IN_RESULT_OFFSET_CLAUSE +}, + +{ + "invalid_time_zone_displacement_value", ERRCODE_INVALID_TIME_ZONE_DISPLACEMENT_VALUE +}, + +{ + "invalid_use_of_escape_character", ERRCODE_INVALID_USE_OF_ESCAPE_CHARACTER +}, + +{ + "most_specific_type_mismatch", ERRCODE_MOST_SPECIFIC_TYPE_MISMATCH +}, + +{ + "null_value_not_allowed", ERRCODE_NULL_VALUE_NOT_ALLOWED +}, + +{ + "null_value_no_indicator_parameter", ERRCODE_NULL_VALUE_NO_INDICATOR_PARAMETER +}, + +{ + "numeric_value_out_of_range", ERRCODE_NUMERIC_VALUE_OUT_OF_RANGE +}, + +{ + "string_data_length_mismatch", ERRCODE_STRING_DATA_LENGTH_MISMATCH +}, + +{ + "string_data_right_truncation", ERRCODE_STRING_DATA_RIGHT_TRUNCATION +}, + +{ + "substring_error", ERRCODE_SUBSTRING_ERROR +}, + +{ + "trim_error", ERRCODE_TRIM_ERROR +}, + +{ + "unterminated_c_string", ERRCODE_UNTERMINATED_C_STRING +}, + +{ + "zero_length_character_string", ERRCODE_ZERO_LENGTH_CHARACTER_STRING +}, + +{ + "floating_point_exception", ERRCODE_FLOATING_POINT_EXCEPTION +}, + +{ + "invalid_text_representation", ERRCODE_INVALID_TEXT_REPRESENTATION +}, + +{ + "invalid_binary_representation", ERRCODE_INVALID_BINARY_REPRESENTATION +}, + +{ + "bad_copy_file_format", ERRCODE_BAD_COPY_FILE_FORMAT +}, + +{ + "untranslatable_character", ERRCODE_UNTRANSLATABLE_CHARACTER +}, + +{ + "not_an_xml_document", ERRCODE_NOT_AN_XML_DOCUMENT +}, + +{ + "invalid_xml_document", ERRCODE_INVALID_XML_DOCUMENT +}, + +{ + "invalid_xml_content", ERRCODE_INVALID_XML_CONTENT +}, + +{ + "invalid_xml_comment", ERRCODE_INVALID_XML_COMMENT +}, + +{ + "invalid_xml_processing_instruction", ERRCODE_INVALID_XML_PROCESSING_INSTRUCTION +}, + +{ + "integrity_constraint_violation", ERRCODE_INTEGRITY_CONSTRAINT_VIOLATION +}, + +{ + "restrict_violation", ERRCODE_RESTRICT_VIOLATION +}, + +{ + "not_null_violation", ERRCODE_NOT_NULL_VIOLATION +}, + +{ + "foreign_key_violation", ERRCODE_FOREIGN_KEY_VIOLATION +}, + +{ + "unique_violation", ERRCODE_UNIQUE_VIOLATION +}, + +{ + "check_violation", ERRCODE_CHECK_VIOLATION +}, + +{ + "exclusion_violation", ERRCODE_EXCLUSION_VIOLATION +}, + +{ + "invalid_cursor_state", ERRCODE_INVALID_CURSOR_STATE +}, + +{ + "invalid_transaction_state", ERRCODE_INVALID_TRANSACTION_STATE +}, + +{ + "active_sql_transaction", ERRCODE_ACTIVE_SQL_TRANSACTION +}, + +{ + "branch_transaction_already_active", ERRCODE_BRANCH_TRANSACTION_ALREADY_ACTIVE +}, + +{ + "held_cursor_requires_same_isolation_level", ERRCODE_HELD_CURSOR_REQUIRES_SAME_ISOLATION_LEVEL +}, + +{ + "inappropriate_access_mode_for_branch_transaction", ERRCODE_INAPPROPRIATE_ACCESS_MODE_FOR_BRANCH_TRANSACTION +}, + +{ + "inappropriate_isolation_level_for_branch_transaction", ERRCODE_INAPPROPRIATE_ISOLATION_LEVEL_FOR_BRANCH_TRANSACTION +}, + +{ + "no_active_sql_transaction_for_branch_transaction", ERRCODE_NO_ACTIVE_SQL_TRANSACTION_FOR_BRANCH_TRANSACTION +}, + +{ + "read_only_sql_transaction", ERRCODE_READ_ONLY_SQL_TRANSACTION +}, + +{ + "schema_and_data_statement_mixing_not_supported", ERRCODE_SCHEMA_AND_DATA_STATEMENT_MIXING_NOT_SUPPORTED +}, + +{ + "no_active_sql_transaction", ERRCODE_NO_ACTIVE_SQL_TRANSACTION +}, + +{ + "in_failed_sql_transaction", ERRCODE_IN_FAILED_SQL_TRANSACTION +}, + +{ + "invalid_sql_statement_name", ERRCODE_INVALID_SQL_STATEMENT_NAME +}, + +{ + "triggered_data_change_violation", ERRCODE_TRIGGERED_DATA_CHANGE_VIOLATION +}, + +{ + "invalid_authorization_specification", ERRCODE_INVALID_AUTHORIZATION_SPECIFICATION +}, + +{ + "invalid_password", ERRCODE_INVALID_PASSWORD +}, + +{ + "dependent_privilege_descriptors_still_exist", ERRCODE_DEPENDENT_PRIVILEGE_DESCRIPTORS_STILL_EXIST +}, + +{ + "dependent_objects_still_exist", ERRCODE_DEPENDENT_OBJECTS_STILL_EXIST +}, + +{ + "invalid_transaction_termination", ERRCODE_INVALID_TRANSACTION_TERMINATION +}, + +{ + "sql_routine_exception", ERRCODE_SQL_ROUTINE_EXCEPTION +}, + +{ + "function_executed_no_return_statement", ERRCODE_S_R_E_FUNCTION_EXECUTED_NO_RETURN_STATEMENT +}, + +{ + "modifying_sql_data_not_permitted", ERRCODE_S_R_E_MODIFYING_SQL_DATA_NOT_PERMITTED +}, + +{ + "prohibited_sql_statement_attempted", ERRCODE_S_R_E_PROHIBITED_SQL_STATEMENT_ATTEMPTED +}, + +{ + "reading_sql_data_not_permitted", ERRCODE_S_R_E_READING_SQL_DATA_NOT_PERMITTED +}, + +{ + "invalid_cursor_name", ERRCODE_INVALID_CURSOR_NAME +}, + +{ + "external_routine_exception", ERRCODE_EXTERNAL_ROUTINE_EXCEPTION +}, + +{ + "containing_sql_not_permitted", ERRCODE_E_R_E_CONTAINING_SQL_NOT_PERMITTED +}, + +{ + "modifying_sql_data_not_permitted", ERRCODE_E_R_E_MODIFYING_SQL_DATA_NOT_PERMITTED +}, + +{ + "prohibited_sql_statement_attempted", ERRCODE_E_R_E_PROHIBITED_SQL_STATEMENT_ATTEMPTED +}, + +{ + "reading_sql_data_not_permitted", ERRCODE_E_R_E_READING_SQL_DATA_NOT_PERMITTED +}, + +{ + "external_routine_invocation_exception", ERRCODE_EXTERNAL_ROUTINE_INVOCATION_EXCEPTION +}, + +{ + "invalid_sqlstate_returned", ERRCODE_E_R_I_E_INVALID_SQLSTATE_RETURNED +}, + +{ + "null_value_not_allowed", ERRCODE_E_R_I_E_NULL_VALUE_NOT_ALLOWED +}, + +{ + "trigger_protocol_violated", ERRCODE_E_R_I_E_TRIGGER_PROTOCOL_VIOLATED +}, + +{ + "srf_protocol_violated", ERRCODE_E_R_I_E_SRF_PROTOCOL_VIOLATED +}, + +{ + "savepoint_exception", ERRCODE_SAVEPOINT_EXCEPTION +}, + +{ + "invalid_savepoint_specification", ERRCODE_S_E_INVALID_SPECIFICATION +}, + +{ + "invalid_catalog_name", ERRCODE_INVALID_CATALOG_NAME +}, + +{ + "invalid_schema_name", ERRCODE_INVALID_SCHEMA_NAME +}, + +{ + "transaction_rollback", ERRCODE_TRANSACTION_ROLLBACK +}, + +{ + "transaction_integrity_constraint_violation", ERRCODE_T_R_INTEGRITY_CONSTRAINT_VIOLATION +}, + +{ + "serialization_failure", ERRCODE_T_R_SERIALIZATION_FAILURE +}, + +{ + "statement_completion_unknown", ERRCODE_T_R_STATEMENT_COMPLETION_UNKNOWN +}, + +{ + "deadlock_detected", ERRCODE_T_R_DEADLOCK_DETECTED +}, + +{ + "syntax_error_or_access_rule_violation", ERRCODE_SYNTAX_ERROR_OR_ACCESS_RULE_VIOLATION +}, + +{ + "syntax_error", ERRCODE_SYNTAX_ERROR +}, + +{ + "insufficient_privilege", ERRCODE_INSUFFICIENT_PRIVILEGE +}, + +{ + "cannot_coerce", ERRCODE_CANNOT_COERCE +}, + +{ + "grouping_error", ERRCODE_GROUPING_ERROR +}, + +{ + "windowing_error", ERRCODE_WINDOWING_ERROR +}, + +{ + "invalid_recursion", ERRCODE_INVALID_RECURSION +}, + +{ + "invalid_foreign_key", ERRCODE_INVALID_FOREIGN_KEY +}, + +{ + "invalid_name", ERRCODE_INVALID_NAME +}, + +{ + "name_too_long", ERRCODE_NAME_TOO_LONG +}, + +{ + "reserved_name", ERRCODE_RESERVED_NAME +}, + +{ + "datatype_mismatch", ERRCODE_DATATYPE_MISMATCH +}, + +{ + "indeterminate_datatype", ERRCODE_INDETERMINATE_DATATYPE +}, + +{ + "collation_mismatch", ERRCODE_COLLATION_MISMATCH +}, + +{ + "indeterminate_collation", ERRCODE_INDETERMINATE_COLLATION +}, + +{ + "wrong_object_type", ERRCODE_WRONG_OBJECT_TYPE +}, + +{ + "undefined_column", ERRCODE_UNDEFINED_COLUMN +}, + +{ + "undefined_function", ERRCODE_UNDEFINED_FUNCTION +}, + +{ + "undefined_table", ERRCODE_UNDEFINED_TABLE +}, + +{ + "undefined_parameter", ERRCODE_UNDEFINED_PARAMETER +}, + +{ + "undefined_object", ERRCODE_UNDEFINED_OBJECT +}, + +{ + "duplicate_column", ERRCODE_DUPLICATE_COLUMN +}, + +{ + "duplicate_cursor", ERRCODE_DUPLICATE_CURSOR +}, + +{ + "duplicate_database", ERRCODE_DUPLICATE_DATABASE +}, + +{ + "duplicate_function", ERRCODE_DUPLICATE_FUNCTION +}, + +{ + "duplicate_prepared_statement", ERRCODE_DUPLICATE_PSTATEMENT +}, + +{ + "duplicate_schema", ERRCODE_DUPLICATE_SCHEMA +}, + +{ + "duplicate_table", ERRCODE_DUPLICATE_TABLE +}, + +{ + "duplicate_alias", ERRCODE_DUPLICATE_ALIAS +}, + +{ + "duplicate_object", ERRCODE_DUPLICATE_OBJECT +}, + +{ + "ambiguous_column", ERRCODE_AMBIGUOUS_COLUMN +}, + +{ + "ambiguous_function", ERRCODE_AMBIGUOUS_FUNCTION +}, + +{ + "ambiguous_parameter", ERRCODE_AMBIGUOUS_PARAMETER +}, + +{ + "ambiguous_alias", ERRCODE_AMBIGUOUS_ALIAS +}, + +{ + "invalid_column_reference", ERRCODE_INVALID_COLUMN_REFERENCE +}, + +{ + "invalid_column_definition", ERRCODE_INVALID_COLUMN_DEFINITION +}, + +{ + "invalid_cursor_definition", ERRCODE_INVALID_CURSOR_DEFINITION +}, + +{ + "invalid_database_definition", ERRCODE_INVALID_DATABASE_DEFINITION +}, + +{ + "invalid_function_definition", ERRCODE_INVALID_FUNCTION_DEFINITION +}, + +{ + "invalid_prepared_statement_definition", ERRCODE_INVALID_PSTATEMENT_DEFINITION +}, + +{ + "invalid_schema_definition", ERRCODE_INVALID_SCHEMA_DEFINITION +}, + +{ + "invalid_table_definition", ERRCODE_INVALID_TABLE_DEFINITION +}, + +{ + "invalid_object_definition", ERRCODE_INVALID_OBJECT_DEFINITION +}, + +{ + "with_check_option_violation", ERRCODE_WITH_CHECK_OPTION_VIOLATION +}, + +{ + "insufficient_resources", ERRCODE_INSUFFICIENT_RESOURCES +}, + +{ + "disk_full", ERRCODE_DISK_FULL +}, + +{ + "out_of_memory", ERRCODE_OUT_OF_MEMORY +}, + +{ + "too_many_connections", ERRCODE_TOO_MANY_CONNECTIONS +}, + +{ + "configuration_limit_exceeded", ERRCODE_CONFIGURATION_LIMIT_EXCEEDED +}, + +{ + "program_limit_exceeded", ERRCODE_PROGRAM_LIMIT_EXCEEDED +}, + +{ + "statement_too_complex", ERRCODE_STATEMENT_TOO_COMPLEX +}, + +{ + "too_many_columns", ERRCODE_TOO_MANY_COLUMNS +}, + +{ + "too_many_arguments", ERRCODE_TOO_MANY_ARGUMENTS +}, + +{ + "object_not_in_prerequisite_state", ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE +}, + +{ + "object_in_use", ERRCODE_OBJECT_IN_USE +}, + +{ + "cant_change_runtime_param", ERRCODE_CANT_CHANGE_RUNTIME_PARAM +}, + +{ + "lock_not_available", ERRCODE_LOCK_NOT_AVAILABLE +}, + +{ + "operator_intervention", ERRCODE_OPERATOR_INTERVENTION +}, + +{ + "query_canceled", ERRCODE_QUERY_CANCELED +}, + +{ + "admin_shutdown", ERRCODE_ADMIN_SHUTDOWN +}, + +{ + "crash_shutdown", ERRCODE_CRASH_SHUTDOWN +}, + +{ + "cannot_connect_now", ERRCODE_CANNOT_CONNECT_NOW +}, + +{ + "database_dropped", ERRCODE_DATABASE_DROPPED +}, + +{ + "system_error", ERRCODE_SYSTEM_ERROR +}, + +{ + "io_error", ERRCODE_IO_ERROR +}, + +{ + "undefined_file", ERRCODE_UNDEFINED_FILE +}, + +{ + "duplicate_file", ERRCODE_DUPLICATE_FILE +}, + +{ + "config_file_error", ERRCODE_CONFIG_FILE_ERROR +}, + +{ + "lock_file_exists", ERRCODE_LOCK_FILE_EXISTS +}, + +{ + "fdw_error", ERRCODE_FDW_ERROR +}, + +{ + "fdw_column_name_not_found", ERRCODE_FDW_COLUMN_NAME_NOT_FOUND +}, + +{ + "fdw_dynamic_parameter_value_needed", ERRCODE_FDW_DYNAMIC_PARAMETER_VALUE_NEEDED +}, + +{ + "fdw_function_sequence_error", ERRCODE_FDW_FUNCTION_SEQUENCE_ERROR +}, + +{ + "fdw_inconsistent_descriptor_information", ERRCODE_FDW_INCONSISTENT_DESCRIPTOR_INFORMATION +}, + +{ + "fdw_invalid_attribute_value", ERRCODE_FDW_INVALID_ATTRIBUTE_VALUE +}, + +{ + "fdw_invalid_column_name", ERRCODE_FDW_INVALID_COLUMN_NAME +}, + +{ + "fdw_invalid_column_number", ERRCODE_FDW_INVALID_COLUMN_NUMBER +}, + +{ + "fdw_invalid_data_type", ERRCODE_FDW_INVALID_DATA_TYPE +}, + +{ + "fdw_invalid_data_type_descriptors", ERRCODE_FDW_INVALID_DATA_TYPE_DESCRIPTORS +}, + +{ + "fdw_invalid_descriptor_field_identifier", ERRCODE_FDW_INVALID_DESCRIPTOR_FIELD_IDENTIFIER +}, + +{ + "fdw_invalid_handle", ERRCODE_FDW_INVALID_HANDLE +}, + +{ + "fdw_invalid_option_index", ERRCODE_FDW_INVALID_OPTION_INDEX +}, + +{ + "fdw_invalid_option_name", ERRCODE_FDW_INVALID_OPTION_NAME +}, + +{ + "fdw_invalid_string_length_or_buffer_length", ERRCODE_FDW_INVALID_STRING_LENGTH_OR_BUFFER_LENGTH +}, + +{ + "fdw_invalid_string_format", ERRCODE_FDW_INVALID_STRING_FORMAT +}, + +{ + "fdw_invalid_use_of_null_pointer", ERRCODE_FDW_INVALID_USE_OF_NULL_POINTER +}, + +{ + "fdw_too_many_handles", ERRCODE_FDW_TOO_MANY_HANDLES +}, + +{ + "fdw_out_of_memory", ERRCODE_FDW_OUT_OF_MEMORY +}, + +{ + "fdw_no_schemas", ERRCODE_FDW_NO_SCHEMAS +}, + +{ + "fdw_option_name_not_found", ERRCODE_FDW_OPTION_NAME_NOT_FOUND +}, + +{ + "fdw_reply_handle", ERRCODE_FDW_REPLY_HANDLE +}, + +{ + "fdw_schema_not_found", ERRCODE_FDW_SCHEMA_NOT_FOUND +}, + +{ + "fdw_table_not_found", ERRCODE_FDW_TABLE_NOT_FOUND +}, + +{ + "fdw_unable_to_create_execution", ERRCODE_FDW_UNABLE_TO_CREATE_EXECUTION +}, + +{ + "fdw_unable_to_create_reply", ERRCODE_FDW_UNABLE_TO_CREATE_REPLY +}, + +{ + "fdw_unable_to_establish_connection", ERRCODE_FDW_UNABLE_TO_ESTABLISH_CONNECTION +}, + +{ + "plpgsql_error", ERRCODE_PLPGSQL_ERROR +}, + +{ + "raise_exception", ERRCODE_RAISE_EXCEPTION +}, + +{ + "no_data_found", ERRCODE_NO_DATA_FOUND +}, + +{ + "too_many_rows", ERRCODE_TOO_MANY_ROWS +}, + +{ + "internal_error", ERRCODE_INTERNAL_ERROR +}, + +{ + "data_corrupted", ERRCODE_DATA_CORRUPTED +}, + +{ + "index_corrupted", ERRCODE_INDEX_CORRUPTED +}, + diff --git a/src/pl/plpython/.gitignore b/src/pl/plpython/.gitignore deleted file mode 100644 index 07bee6a29..000000000 --- a/src/pl/plpython/.gitignore +++ /dev/null @@ -1,5 +0,0 @@ -/spiexceptions.h -# Generated subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/src/pl/plpython/spiexceptions.h b/src/pl/plpython/spiexceptions.h new file mode 100644 index 000000000..6ed3eca1e --- /dev/null +++ b/src/pl/plpython/spiexceptions.h @@ -0,0 +1,223 @@ +/* autogenerated from src/backend/utils/errcodes.txt, do not edit */ +/* there is deliberately not an #ifndef SPIEXCEPTIONS_H here */ +{ "spiexceptions.SqlStatementNotYetComplete", "SqlStatementNotYetComplete", ERRCODE_SQL_STATEMENT_NOT_YET_COMPLETE }, +{ "spiexceptions.ConnectionException", "ConnectionException", ERRCODE_CONNECTION_EXCEPTION }, +{ "spiexceptions.ConnectionDoesNotExist", "ConnectionDoesNotExist", ERRCODE_CONNECTION_DOES_NOT_EXIST }, +{ "spiexceptions.ConnectionFailure", "ConnectionFailure", ERRCODE_CONNECTION_FAILURE }, +{ "spiexceptions.SqlclientUnableToEstablishSqlconnection", "SqlclientUnableToEstablishSqlconnection", ERRCODE_SQLCLIENT_UNABLE_TO_ESTABLISH_SQLCONNECTION }, +{ "spiexceptions.SqlserverRejectedEstablishmentOfSqlconnection", "SqlserverRejectedEstablishmentOfSqlconnection", ERRCODE_SQLSERVER_REJECTED_ESTABLISHMENT_OF_SQLCONNECTION }, +{ "spiexceptions.TransactionResolutionUnknown", "TransactionResolutionUnknown", ERRCODE_TRANSACTION_RESOLUTION_UNKNOWN }, +{ "spiexceptions.ProtocolViolation", "ProtocolViolation", ERRCODE_PROTOCOL_VIOLATION }, +{ "spiexceptions.TriggeredActionException", "TriggeredActionException", ERRCODE_TRIGGERED_ACTION_EXCEPTION }, +{ "spiexceptions.FeatureNotSupported", "FeatureNotSupported", ERRCODE_FEATURE_NOT_SUPPORTED }, +{ "spiexceptions.InvalidTransactionInitiation", "InvalidTransactionInitiation", ERRCODE_INVALID_TRANSACTION_INITIATION }, +{ "spiexceptions.LocatorException", "LocatorException", ERRCODE_LOCATOR_EXCEPTION }, +{ "spiexceptions.InvalidLocatorSpecification", "InvalidLocatorSpecification", ERRCODE_L_E_INVALID_SPECIFICATION }, +{ "spiexceptions.InvalidGrantor", "InvalidGrantor", ERRCODE_INVALID_GRANTOR }, +{ "spiexceptions.InvalidGrantOperation", "InvalidGrantOperation", ERRCODE_INVALID_GRANT_OPERATION }, +{ "spiexceptions.InvalidRoleSpecification", "InvalidRoleSpecification", ERRCODE_INVALID_ROLE_SPECIFICATION }, +{ "spiexceptions.DiagnosticsException", "DiagnosticsException", ERRCODE_DIAGNOSTICS_EXCEPTION }, +{ "spiexceptions.StackedDiagnosticsAccessedWithoutActiveHandler", "StackedDiagnosticsAccessedWithoutActiveHandler", ERRCODE_STACKED_DIAGNOSTICS_ACCESSED_WITHOUT_ACTIVE_HANDLER }, +{ "spiexceptions.CaseNotFound", "CaseNotFound", ERRCODE_CASE_NOT_FOUND }, +{ "spiexceptions.CardinalityViolation", "CardinalityViolation", ERRCODE_CARDINALITY_VIOLATION }, +{ "spiexceptions.DataException", "DataException", ERRCODE_DATA_EXCEPTION }, +{ "spiexceptions.ArraySubscriptError", "ArraySubscriptError", ERRCODE_ARRAY_SUBSCRIPT_ERROR }, +{ "spiexceptions.CharacterNotInRepertoire", "CharacterNotInRepertoire", ERRCODE_CHARACTER_NOT_IN_REPERTOIRE }, +{ "spiexceptions.DatetimeFieldOverflow", "DatetimeFieldOverflow", ERRCODE_DATETIME_FIELD_OVERFLOW }, +{ "spiexceptions.DivisionByZero", "DivisionByZero", ERRCODE_DIVISION_BY_ZERO }, +{ "spiexceptions.ErrorInAssignment", "ErrorInAssignment", ERRCODE_ERROR_IN_ASSIGNMENT }, +{ "spiexceptions.EscapeCharacterConflict", "EscapeCharacterConflict", ERRCODE_ESCAPE_CHARACTER_CONFLICT }, +{ "spiexceptions.IndicatorOverflow", "IndicatorOverflow", ERRCODE_INDICATOR_OVERFLOW }, +{ "spiexceptions.IntervalFieldOverflow", "IntervalFieldOverflow", ERRCODE_INTERVAL_FIELD_OVERFLOW }, +{ "spiexceptions.InvalidArgumentForLogarithm", "InvalidArgumentForLogarithm", ERRCODE_INVALID_ARGUMENT_FOR_LOG }, +{ "spiexceptions.InvalidArgumentForNtileFunction", "InvalidArgumentForNtileFunction", ERRCODE_INVALID_ARGUMENT_FOR_NTILE }, +{ "spiexceptions.InvalidArgumentForNthValueFunction", "InvalidArgumentForNthValueFunction", ERRCODE_INVALID_ARGUMENT_FOR_NTH_VALUE }, +{ "spiexceptions.InvalidArgumentForPowerFunction", "InvalidArgumentForPowerFunction", ERRCODE_INVALID_ARGUMENT_FOR_POWER_FUNCTION }, +{ "spiexceptions.InvalidArgumentForWidthBucketFunction", "InvalidArgumentForWidthBucketFunction", ERRCODE_INVALID_ARGUMENT_FOR_WIDTH_BUCKET_FUNCTION }, +{ "spiexceptions.InvalidCharacterValueForCast", "InvalidCharacterValueForCast", ERRCODE_INVALID_CHARACTER_VALUE_FOR_CAST }, +{ "spiexceptions.InvalidDatetimeFormat", "InvalidDatetimeFormat", ERRCODE_INVALID_DATETIME_FORMAT }, +{ "spiexceptions.InvalidEscapeCharacter", "InvalidEscapeCharacter", ERRCODE_INVALID_ESCAPE_CHARACTER }, +{ "spiexceptions.InvalidEscapeOctet", "InvalidEscapeOctet", ERRCODE_INVALID_ESCAPE_OCTET }, +{ "spiexceptions.InvalidEscapeSequence", "InvalidEscapeSequence", ERRCODE_INVALID_ESCAPE_SEQUENCE }, +{ "spiexceptions.NonstandardUseOfEscapeCharacter", "NonstandardUseOfEscapeCharacter", ERRCODE_NONSTANDARD_USE_OF_ESCAPE_CHARACTER }, +{ "spiexceptions.InvalidIndicatorParameterValue", "InvalidIndicatorParameterValue", ERRCODE_INVALID_INDICATOR_PARAMETER_VALUE }, +{ "spiexceptions.InvalidParameterValue", "InvalidParameterValue", ERRCODE_INVALID_PARAMETER_VALUE }, +{ "spiexceptions.InvalidRegularExpression", "InvalidRegularExpression", ERRCODE_INVALID_REGULAR_EXPRESSION }, +{ "spiexceptions.InvalidRowCountInLimitClause", "InvalidRowCountInLimitClause", ERRCODE_INVALID_ROW_COUNT_IN_LIMIT_CLAUSE }, +{ "spiexceptions.InvalidRowCountInResultOffsetClause", "InvalidRowCountInResultOffsetClause", ERRCODE_INVALID_ROW_COUNT_IN_RESULT_OFFSET_CLAUSE }, +{ "spiexceptions.InvalidTimeZoneDisplacementValue", "InvalidTimeZoneDisplacementValue", ERRCODE_INVALID_TIME_ZONE_DISPLACEMENT_VALUE }, +{ "spiexceptions.InvalidUseOfEscapeCharacter", "InvalidUseOfEscapeCharacter", ERRCODE_INVALID_USE_OF_ESCAPE_CHARACTER }, +{ "spiexceptions.MostSpecificTypeMismatch", "MostSpecificTypeMismatch", ERRCODE_MOST_SPECIFIC_TYPE_MISMATCH }, +{ "spiexceptions.NullValueNotAllowed", "NullValueNotAllowed", ERRCODE_NULL_VALUE_NOT_ALLOWED }, +{ "spiexceptions.NullValueNoIndicatorParameter", "NullValueNoIndicatorParameter", ERRCODE_NULL_VALUE_NO_INDICATOR_PARAMETER }, +{ "spiexceptions.NumericValueOutOfRange", "NumericValueOutOfRange", ERRCODE_NUMERIC_VALUE_OUT_OF_RANGE }, +{ "spiexceptions.StringDataLengthMismatch", "StringDataLengthMismatch", ERRCODE_STRING_DATA_LENGTH_MISMATCH }, +{ "spiexceptions.StringDataRightTruncation", "StringDataRightTruncation", ERRCODE_STRING_DATA_RIGHT_TRUNCATION }, +{ "spiexceptions.SubstringError", "SubstringError", ERRCODE_SUBSTRING_ERROR }, +{ "spiexceptions.TrimError", "TrimError", ERRCODE_TRIM_ERROR }, +{ "spiexceptions.UnterminatedCString", "UnterminatedCString", ERRCODE_UNTERMINATED_C_STRING }, +{ "spiexceptions.ZeroLengthCharacterString", "ZeroLengthCharacterString", ERRCODE_ZERO_LENGTH_CHARACTER_STRING }, +{ "spiexceptions.FloatingPointException", "FloatingPointException", ERRCODE_FLOATING_POINT_EXCEPTION }, +{ "spiexceptions.InvalidTextRepresentation", "InvalidTextRepresentation", ERRCODE_INVALID_TEXT_REPRESENTATION }, +{ "spiexceptions.InvalidBinaryRepresentation", "InvalidBinaryRepresentation", ERRCODE_INVALID_BINARY_REPRESENTATION }, +{ "spiexceptions.BadCopyFileFormat", "BadCopyFileFormat", ERRCODE_BAD_COPY_FILE_FORMAT }, +{ "spiexceptions.UntranslatableCharacter", "UntranslatableCharacter", ERRCODE_UNTRANSLATABLE_CHARACTER }, +{ "spiexceptions.NotAnXmlDocument", "NotAnXmlDocument", ERRCODE_NOT_AN_XML_DOCUMENT }, +{ "spiexceptions.InvalidXmlDocument", "InvalidXmlDocument", ERRCODE_INVALID_XML_DOCUMENT }, +{ "spiexceptions.InvalidXmlContent", "InvalidXmlContent", ERRCODE_INVALID_XML_CONTENT }, +{ "spiexceptions.InvalidXmlComment", "InvalidXmlComment", ERRCODE_INVALID_XML_COMMENT }, +{ "spiexceptions.InvalidXmlProcessingInstruction", "InvalidXmlProcessingInstruction", ERRCODE_INVALID_XML_PROCESSING_INSTRUCTION }, +{ "spiexceptions.IntegrityConstraintViolation", "IntegrityConstraintViolation", ERRCODE_INTEGRITY_CONSTRAINT_VIOLATION }, +{ "spiexceptions.RestrictViolation", "RestrictViolation", ERRCODE_RESTRICT_VIOLATION }, +{ "spiexceptions.NotNullViolation", "NotNullViolation", ERRCODE_NOT_NULL_VIOLATION }, +{ "spiexceptions.ForeignKeyViolation", "ForeignKeyViolation", ERRCODE_FOREIGN_KEY_VIOLATION }, +{ "spiexceptions.UniqueViolation", "UniqueViolation", ERRCODE_UNIQUE_VIOLATION }, +{ "spiexceptions.CheckViolation", "CheckViolation", ERRCODE_CHECK_VIOLATION }, +{ "spiexceptions.ExclusionViolation", "ExclusionViolation", ERRCODE_EXCLUSION_VIOLATION }, +{ "spiexceptions.InvalidCursorState", "InvalidCursorState", ERRCODE_INVALID_CURSOR_STATE }, +{ "spiexceptions.InvalidTransactionState", "InvalidTransactionState", ERRCODE_INVALID_TRANSACTION_STATE }, +{ "spiexceptions.ActiveSqlTransaction", "ActiveSqlTransaction", ERRCODE_ACTIVE_SQL_TRANSACTION }, +{ "spiexceptions.BranchTransactionAlreadyActive", "BranchTransactionAlreadyActive", ERRCODE_BRANCH_TRANSACTION_ALREADY_ACTIVE }, +{ "spiexceptions.HeldCursorRequiresSameIsolationLevel", "HeldCursorRequiresSameIsolationLevel", ERRCODE_HELD_CURSOR_REQUIRES_SAME_ISOLATION_LEVEL }, +{ "spiexceptions.InappropriateAccessModeForBranchTransaction", "InappropriateAccessModeForBranchTransaction", ERRCODE_INAPPROPRIATE_ACCESS_MODE_FOR_BRANCH_TRANSACTION }, +{ "spiexceptions.InappropriateIsolationLevelForBranchTransaction", "InappropriateIsolationLevelForBranchTransaction", ERRCODE_INAPPROPRIATE_ISOLATION_LEVEL_FOR_BRANCH_TRANSACTION }, +{ "spiexceptions.NoActiveSqlTransactionForBranchTransaction", "NoActiveSqlTransactionForBranchTransaction", ERRCODE_NO_ACTIVE_SQL_TRANSACTION_FOR_BRANCH_TRANSACTION }, +{ "spiexceptions.ReadOnlySqlTransaction", "ReadOnlySqlTransaction", ERRCODE_READ_ONLY_SQL_TRANSACTION }, +{ "spiexceptions.SchemaAndDataStatementMixingNotSupported", "SchemaAndDataStatementMixingNotSupported", ERRCODE_SCHEMA_AND_DATA_STATEMENT_MIXING_NOT_SUPPORTED }, +{ "spiexceptions.NoActiveSqlTransaction", "NoActiveSqlTransaction", ERRCODE_NO_ACTIVE_SQL_TRANSACTION }, +{ "spiexceptions.InFailedSqlTransaction", "InFailedSqlTransaction", ERRCODE_IN_FAILED_SQL_TRANSACTION }, +{ "spiexceptions.InvalidSqlStatementName", "InvalidSqlStatementName", ERRCODE_INVALID_SQL_STATEMENT_NAME }, +{ "spiexceptions.TriggeredDataChangeViolation", "TriggeredDataChangeViolation", ERRCODE_TRIGGERED_DATA_CHANGE_VIOLATION }, +{ "spiexceptions.InvalidAuthorizationSpecification", "InvalidAuthorizationSpecification", ERRCODE_INVALID_AUTHORIZATION_SPECIFICATION }, +{ "spiexceptions.InvalidPassword", "InvalidPassword", ERRCODE_INVALID_PASSWORD }, +{ "spiexceptions.DependentPrivilegeDescriptorsStillExist", "DependentPrivilegeDescriptorsStillExist", ERRCODE_DEPENDENT_PRIVILEGE_DESCRIPTORS_STILL_EXIST }, +{ "spiexceptions.DependentObjectsStillExist", "DependentObjectsStillExist", ERRCODE_DEPENDENT_OBJECTS_STILL_EXIST }, +{ "spiexceptions.InvalidTransactionTermination", "InvalidTransactionTermination", ERRCODE_INVALID_TRANSACTION_TERMINATION }, +{ "spiexceptions.SqlRoutineException", "SqlRoutineException", ERRCODE_SQL_ROUTINE_EXCEPTION }, +{ "spiexceptions.FunctionExecutedNoReturnStatement", "FunctionExecutedNoReturnStatement", ERRCODE_S_R_E_FUNCTION_EXECUTED_NO_RETURN_STATEMENT }, +{ "spiexceptions.ModifyingSqlDataNotPermitted", "ModifyingSqlDataNotPermitted", ERRCODE_S_R_E_MODIFYING_SQL_DATA_NOT_PERMITTED }, +{ "spiexceptions.ProhibitedSqlStatementAttempted", "ProhibitedSqlStatementAttempted", ERRCODE_S_R_E_PROHIBITED_SQL_STATEMENT_ATTEMPTED }, +{ "spiexceptions.ReadingSqlDataNotPermitted", "ReadingSqlDataNotPermitted", ERRCODE_S_R_E_READING_SQL_DATA_NOT_PERMITTED }, +{ "spiexceptions.InvalidCursorName", "InvalidCursorName", ERRCODE_INVALID_CURSOR_NAME }, +{ "spiexceptions.ExternalRoutineException", "ExternalRoutineException", ERRCODE_EXTERNAL_ROUTINE_EXCEPTION }, +{ "spiexceptions.ContainingSqlNotPermitted", "ContainingSqlNotPermitted", ERRCODE_E_R_E_CONTAINING_SQL_NOT_PERMITTED }, +{ "spiexceptions.ModifyingSqlDataNotPermitted", "ModifyingSqlDataNotPermitted", ERRCODE_E_R_E_MODIFYING_SQL_DATA_NOT_PERMITTED }, +{ "spiexceptions.ProhibitedSqlStatementAttempted", "ProhibitedSqlStatementAttempted", ERRCODE_E_R_E_PROHIBITED_SQL_STATEMENT_ATTEMPTED }, +{ "spiexceptions.ReadingSqlDataNotPermitted", "ReadingSqlDataNotPermitted", ERRCODE_E_R_E_READING_SQL_DATA_NOT_PERMITTED }, +{ "spiexceptions.ExternalRoutineInvocationException", "ExternalRoutineInvocationException", ERRCODE_EXTERNAL_ROUTINE_INVOCATION_EXCEPTION }, +{ "spiexceptions.InvalidSqlstateReturned", "InvalidSqlstateReturned", ERRCODE_E_R_I_E_INVALID_SQLSTATE_RETURNED }, +{ "spiexceptions.NullValueNotAllowed", "NullValueNotAllowed", ERRCODE_E_R_I_E_NULL_VALUE_NOT_ALLOWED }, +{ "spiexceptions.TriggerProtocolViolated", "TriggerProtocolViolated", ERRCODE_E_R_I_E_TRIGGER_PROTOCOL_VIOLATED }, +{ "spiexceptions.SrfProtocolViolated", "SrfProtocolViolated", ERRCODE_E_R_I_E_SRF_PROTOCOL_VIOLATED }, +{ "spiexceptions.SavepointException", "SavepointException", ERRCODE_SAVEPOINT_EXCEPTION }, +{ "spiexceptions.InvalidSavepointSpecification", "InvalidSavepointSpecification", ERRCODE_S_E_INVALID_SPECIFICATION }, +{ "spiexceptions.InvalidCatalogName", "InvalidCatalogName", ERRCODE_INVALID_CATALOG_NAME }, +{ "spiexceptions.InvalidSchemaName", "InvalidSchemaName", ERRCODE_INVALID_SCHEMA_NAME }, +{ "spiexceptions.TransactionRollback", "TransactionRollback", ERRCODE_TRANSACTION_ROLLBACK }, +{ "spiexceptions.TransactionIntegrityConstraintViolation", "TransactionIntegrityConstraintViolation", ERRCODE_T_R_INTEGRITY_CONSTRAINT_VIOLATION }, +{ "spiexceptions.SerializationFailure", "SerializationFailure", ERRCODE_T_R_SERIALIZATION_FAILURE }, +{ "spiexceptions.StatementCompletionUnknown", "StatementCompletionUnknown", ERRCODE_T_R_STATEMENT_COMPLETION_UNKNOWN }, +{ "spiexceptions.DeadlockDetected", "DeadlockDetected", ERRCODE_T_R_DEADLOCK_DETECTED }, +{ "spiexceptions.SyntaxErrorOrAccessRuleViolation", "SyntaxErrorOrAccessRuleViolation", ERRCODE_SYNTAX_ERROR_OR_ACCESS_RULE_VIOLATION }, +{ "spiexceptions.SyntaxError", "SyntaxError", ERRCODE_SYNTAX_ERROR }, +{ "spiexceptions.InsufficientPrivilege", "InsufficientPrivilege", ERRCODE_INSUFFICIENT_PRIVILEGE }, +{ "spiexceptions.CannotCoerce", "CannotCoerce", ERRCODE_CANNOT_COERCE }, +{ "spiexceptions.GroupingError", "GroupingError", ERRCODE_GROUPING_ERROR }, +{ "spiexceptions.WindowingError", "WindowingError", ERRCODE_WINDOWING_ERROR }, +{ "spiexceptions.InvalidRecursion", "InvalidRecursion", ERRCODE_INVALID_RECURSION }, +{ "spiexceptions.InvalidForeignKey", "InvalidForeignKey", ERRCODE_INVALID_FOREIGN_KEY }, +{ "spiexceptions.InvalidName", "InvalidName", ERRCODE_INVALID_NAME }, +{ "spiexceptions.NameTooLong", "NameTooLong", ERRCODE_NAME_TOO_LONG }, +{ "spiexceptions.ReservedName", "ReservedName", ERRCODE_RESERVED_NAME }, +{ "spiexceptions.DatatypeMismatch", "DatatypeMismatch", ERRCODE_DATATYPE_MISMATCH }, +{ "spiexceptions.IndeterminateDatatype", "IndeterminateDatatype", ERRCODE_INDETERMINATE_DATATYPE }, +{ "spiexceptions.CollationMismatch", "CollationMismatch", ERRCODE_COLLATION_MISMATCH }, +{ "spiexceptions.IndeterminateCollation", "IndeterminateCollation", ERRCODE_INDETERMINATE_COLLATION }, +{ "spiexceptions.WrongObjectType", "WrongObjectType", ERRCODE_WRONG_OBJECT_TYPE }, +{ "spiexceptions.UndefinedColumn", "UndefinedColumn", ERRCODE_UNDEFINED_COLUMN }, +{ "spiexceptions.UndefinedFunction", "UndefinedFunction", ERRCODE_UNDEFINED_FUNCTION }, +{ "spiexceptions.UndefinedTable", "UndefinedTable", ERRCODE_UNDEFINED_TABLE }, +{ "spiexceptions.UndefinedParameter", "UndefinedParameter", ERRCODE_UNDEFINED_PARAMETER }, +{ "spiexceptions.UndefinedObject", "UndefinedObject", ERRCODE_UNDEFINED_OBJECT }, +{ "spiexceptions.DuplicateColumn", "DuplicateColumn", ERRCODE_DUPLICATE_COLUMN }, +{ "spiexceptions.DuplicateCursor", "DuplicateCursor", ERRCODE_DUPLICATE_CURSOR }, +{ "spiexceptions.DuplicateDatabase", "DuplicateDatabase", ERRCODE_DUPLICATE_DATABASE }, +{ "spiexceptions.DuplicateFunction", "DuplicateFunction", ERRCODE_DUPLICATE_FUNCTION }, +{ "spiexceptions.DuplicatePreparedStatement", "DuplicatePreparedStatement", ERRCODE_DUPLICATE_PSTATEMENT }, +{ "spiexceptions.DuplicateSchema", "DuplicateSchema", ERRCODE_DUPLICATE_SCHEMA }, +{ "spiexceptions.DuplicateTable", "DuplicateTable", ERRCODE_DUPLICATE_TABLE }, +{ "spiexceptions.DuplicateAlias", "DuplicateAlias", ERRCODE_DUPLICATE_ALIAS }, +{ "spiexceptions.DuplicateObject", "DuplicateObject", ERRCODE_DUPLICATE_OBJECT }, +{ "spiexceptions.AmbiguousColumn", "AmbiguousColumn", ERRCODE_AMBIGUOUS_COLUMN }, +{ "spiexceptions.AmbiguousFunction", "AmbiguousFunction", ERRCODE_AMBIGUOUS_FUNCTION }, +{ "spiexceptions.AmbiguousParameter", "AmbiguousParameter", ERRCODE_AMBIGUOUS_PARAMETER }, +{ "spiexceptions.AmbiguousAlias", "AmbiguousAlias", ERRCODE_AMBIGUOUS_ALIAS }, +{ "spiexceptions.InvalidColumnReference", "InvalidColumnReference", ERRCODE_INVALID_COLUMN_REFERENCE }, +{ "spiexceptions.InvalidColumnDefinition", "InvalidColumnDefinition", ERRCODE_INVALID_COLUMN_DEFINITION }, +{ "spiexceptions.InvalidCursorDefinition", "InvalidCursorDefinition", ERRCODE_INVALID_CURSOR_DEFINITION }, +{ "spiexceptions.InvalidDatabaseDefinition", "InvalidDatabaseDefinition", ERRCODE_INVALID_DATABASE_DEFINITION }, +{ "spiexceptions.InvalidFunctionDefinition", "InvalidFunctionDefinition", ERRCODE_INVALID_FUNCTION_DEFINITION }, +{ "spiexceptions.InvalidPreparedStatementDefinition", "InvalidPreparedStatementDefinition", ERRCODE_INVALID_PSTATEMENT_DEFINITION }, +{ "spiexceptions.InvalidSchemaDefinition", "InvalidSchemaDefinition", ERRCODE_INVALID_SCHEMA_DEFINITION }, +{ "spiexceptions.InvalidTableDefinition", "InvalidTableDefinition", ERRCODE_INVALID_TABLE_DEFINITION }, +{ "spiexceptions.InvalidObjectDefinition", "InvalidObjectDefinition", ERRCODE_INVALID_OBJECT_DEFINITION }, +{ "spiexceptions.WithCheckOptionViolation", "WithCheckOptionViolation", ERRCODE_WITH_CHECK_OPTION_VIOLATION }, +{ "spiexceptions.InsufficientResources", "InsufficientResources", ERRCODE_INSUFFICIENT_RESOURCES }, +{ "spiexceptions.DiskFull", "DiskFull", ERRCODE_DISK_FULL }, +{ "spiexceptions.OutOfMemory", "OutOfMemory", ERRCODE_OUT_OF_MEMORY }, +{ "spiexceptions.TooManyConnections", "TooManyConnections", ERRCODE_TOO_MANY_CONNECTIONS }, +{ "spiexceptions.ConfigurationLimitExceeded", "ConfigurationLimitExceeded", ERRCODE_CONFIGURATION_LIMIT_EXCEEDED }, +{ "spiexceptions.ProgramLimitExceeded", "ProgramLimitExceeded", ERRCODE_PROGRAM_LIMIT_EXCEEDED }, +{ "spiexceptions.StatementTooComplex", "StatementTooComplex", ERRCODE_STATEMENT_TOO_COMPLEX }, +{ "spiexceptions.TooManyColumns", "TooManyColumns", ERRCODE_TOO_MANY_COLUMNS }, +{ "spiexceptions.TooManyArguments", "TooManyArguments", ERRCODE_TOO_MANY_ARGUMENTS }, +{ "spiexceptions.ObjectNotInPrerequisiteState", "ObjectNotInPrerequisiteState", ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE }, +{ "spiexceptions.ObjectInUse", "ObjectInUse", ERRCODE_OBJECT_IN_USE }, +{ "spiexceptions.CantChangeRuntimeParam", "CantChangeRuntimeParam", ERRCODE_CANT_CHANGE_RUNTIME_PARAM }, +{ "spiexceptions.LockNotAvailable", "LockNotAvailable", ERRCODE_LOCK_NOT_AVAILABLE }, +{ "spiexceptions.OperatorIntervention", "OperatorIntervention", ERRCODE_OPERATOR_INTERVENTION }, +{ "spiexceptions.QueryCanceled", "QueryCanceled", ERRCODE_QUERY_CANCELED }, +{ "spiexceptions.AdminShutdown", "AdminShutdown", ERRCODE_ADMIN_SHUTDOWN }, +{ "spiexceptions.CrashShutdown", "CrashShutdown", ERRCODE_CRASH_SHUTDOWN }, +{ "spiexceptions.CannotConnectNow", "CannotConnectNow", ERRCODE_CANNOT_CONNECT_NOW }, +{ "spiexceptions.DatabaseDropped", "DatabaseDropped", ERRCODE_DATABASE_DROPPED }, +{ "spiexceptions.SystemError", "SystemError", ERRCODE_SYSTEM_ERROR }, +{ "spiexceptions.IoError", "IoError", ERRCODE_IO_ERROR }, +{ "spiexceptions.UndefinedFile", "UndefinedFile", ERRCODE_UNDEFINED_FILE }, +{ "spiexceptions.DuplicateFile", "DuplicateFile", ERRCODE_DUPLICATE_FILE }, +{ "spiexceptions.ConfigFileError", "ConfigFileError", ERRCODE_CONFIG_FILE_ERROR }, +{ "spiexceptions.LockFileExists", "LockFileExists", ERRCODE_LOCK_FILE_EXISTS }, +{ "spiexceptions.FdwError", "FdwError", ERRCODE_FDW_ERROR }, +{ "spiexceptions.FdwColumnNameNotFound", "FdwColumnNameNotFound", ERRCODE_FDW_COLUMN_NAME_NOT_FOUND }, +{ "spiexceptions.FdwDynamicParameterValueNeeded", "FdwDynamicParameterValueNeeded", ERRCODE_FDW_DYNAMIC_PARAMETER_VALUE_NEEDED }, +{ "spiexceptions.FdwFunctionSequenceError", "FdwFunctionSequenceError", ERRCODE_FDW_FUNCTION_SEQUENCE_ERROR }, +{ "spiexceptions.FdwInconsistentDescriptorInformation", "FdwInconsistentDescriptorInformation", ERRCODE_FDW_INCONSISTENT_DESCRIPTOR_INFORMATION }, +{ "spiexceptions.FdwInvalidAttributeValue", "FdwInvalidAttributeValue", ERRCODE_FDW_INVALID_ATTRIBUTE_VALUE }, +{ "spiexceptions.FdwInvalidColumnName", "FdwInvalidColumnName", ERRCODE_FDW_INVALID_COLUMN_NAME }, +{ "spiexceptions.FdwInvalidColumnNumber", "FdwInvalidColumnNumber", ERRCODE_FDW_INVALID_COLUMN_NUMBER }, +{ "spiexceptions.FdwInvalidDataType", "FdwInvalidDataType", ERRCODE_FDW_INVALID_DATA_TYPE }, +{ "spiexceptions.FdwInvalidDataTypeDescriptors", "FdwInvalidDataTypeDescriptors", ERRCODE_FDW_INVALID_DATA_TYPE_DESCRIPTORS }, +{ "spiexceptions.FdwInvalidDescriptorFieldIdentifier", "FdwInvalidDescriptorFieldIdentifier", ERRCODE_FDW_INVALID_DESCRIPTOR_FIELD_IDENTIFIER }, +{ "spiexceptions.FdwInvalidHandle", "FdwInvalidHandle", ERRCODE_FDW_INVALID_HANDLE }, +{ "spiexceptions.FdwInvalidOptionIndex", "FdwInvalidOptionIndex", ERRCODE_FDW_INVALID_OPTION_INDEX }, +{ "spiexceptions.FdwInvalidOptionName", "FdwInvalidOptionName", ERRCODE_FDW_INVALID_OPTION_NAME }, +{ "spiexceptions.FdwInvalidStringLengthOrBufferLength", "FdwInvalidStringLengthOrBufferLength", ERRCODE_FDW_INVALID_STRING_LENGTH_OR_BUFFER_LENGTH }, +{ "spiexceptions.FdwInvalidStringFormat", "FdwInvalidStringFormat", ERRCODE_FDW_INVALID_STRING_FORMAT }, +{ "spiexceptions.FdwInvalidUseOfNullPointer", "FdwInvalidUseOfNullPointer", ERRCODE_FDW_INVALID_USE_OF_NULL_POINTER }, +{ "spiexceptions.FdwTooManyHandles", "FdwTooManyHandles", ERRCODE_FDW_TOO_MANY_HANDLES }, +{ "spiexceptions.FdwOutOfMemory", "FdwOutOfMemory", ERRCODE_FDW_OUT_OF_MEMORY }, +{ "spiexceptions.FdwNoSchemas", "FdwNoSchemas", ERRCODE_FDW_NO_SCHEMAS }, +{ "spiexceptions.FdwOptionNameNotFound", "FdwOptionNameNotFound", ERRCODE_FDW_OPTION_NAME_NOT_FOUND }, +{ "spiexceptions.FdwReplyHandle", "FdwReplyHandle", ERRCODE_FDW_REPLY_HANDLE }, +{ "spiexceptions.FdwSchemaNotFound", "FdwSchemaNotFound", ERRCODE_FDW_SCHEMA_NOT_FOUND }, +{ "spiexceptions.FdwTableNotFound", "FdwTableNotFound", ERRCODE_FDW_TABLE_NOT_FOUND }, +{ "spiexceptions.FdwUnableToCreateExecution", "FdwUnableToCreateExecution", ERRCODE_FDW_UNABLE_TO_CREATE_EXECUTION }, +{ "spiexceptions.FdwUnableToCreateReply", "FdwUnableToCreateReply", ERRCODE_FDW_UNABLE_TO_CREATE_REPLY }, +{ "spiexceptions.FdwUnableToEstablishConnection", "FdwUnableToEstablishConnection", ERRCODE_FDW_UNABLE_TO_ESTABLISH_CONNECTION }, +{ "spiexceptions.PlpgsqlError", "PlpgsqlError", ERRCODE_PLPGSQL_ERROR }, +{ "spiexceptions.RaiseException", "RaiseException", ERRCODE_RAISE_EXCEPTION }, +{ "spiexceptions.NoDataFound", "NoDataFound", ERRCODE_NO_DATA_FOUND }, +{ "spiexceptions.TooManyRows", "TooManyRows", ERRCODE_TOO_MANY_ROWS }, +{ "spiexceptions.InternalError", "InternalError", ERRCODE_INTERNAL_ERROR }, +{ "spiexceptions.DataCorrupted", "DataCorrupted", ERRCODE_DATA_CORRUPTED }, +{ "spiexceptions.IndexCorrupted", "IndexCorrupted", ERRCODE_INDEX_CORRUPTED }, diff --git a/src/pl/tcl/.gitignore b/src/pl/tcl/.gitignore deleted file mode 100644 index 5dcb3ff97..000000000 --- a/src/pl/tcl/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -# Generated subdirectories -/log/ -/results/ -/tmp_check/ diff --git a/src/pl/tcl/modules/.gitignore b/src/pl/tcl/modules/.gitignore deleted file mode 100644 index 89581887c..000000000 --- a/src/pl/tcl/modules/.gitignore +++ /dev/null @@ -1,3 +0,0 @@ -/pltcl_delmod -/pltcl_listmod -/pltcl_loadmod diff --git a/src/port/.gitignore b/src/port/.gitignore deleted file mode 100644 index 53a403244..000000000 --- a/src/port/.gitignore +++ /dev/null @@ -1,3 +0,0 @@ -/libpgport.a -/libpgport_srv.a -/pg_config_paths.h diff --git a/src/port/win32ver.rc b/src/port/win32ver.rc new file mode 100644 index 000000000..31181bce1 --- /dev/null +++ b/src/port/win32ver.rc @@ -0,0 +1,31 @@ +#include +#include "pg_config.h" + +VS_VERSION_INFO VERSIONINFO + FILEVERSION 9,2,2,0 + PRODUCTVERSION 9,2,2,0 + FILEFLAGSMASK 0x17L + FILEFLAGS 0x0L + FILEOS VOS_NT_WINDOWS32 + FILETYPE VFT_APP + FILESUBTYPE 0x0L +BEGIN + BLOCK "StringFileInfo" + BEGIN + BLOCK "000004b0" + BEGIN + VALUE "CompanyName", "PostgreSQL Global Development Group" + VALUE "FileDescription", FILEDESC + VALUE "FileVersion", PG_VERSION + VALUE "LegalCopyright", "Portions Copyright (c) 1996-2012, PostgreSQL Global Development Group. Portions Copyright (c) 1994, Regents of the University of California." + VALUE "ProductName", "PostgreSQL" + VALUE "ProductVersion", PG_VERSION + END + END + BLOCK "VarFileInfo" + BEGIN + VALUE "Translation", 0x0, 1200 + END +END + +_ICO_ diff --git a/src/test/isolation/.gitignore b/src/test/isolation/.gitignore deleted file mode 100644 index 42ee94574..000000000 --- a/src/test/isolation/.gitignore +++ /dev/null @@ -1,12 +0,0 @@ -# Local binaries -/isolationtester -/pg_isolation_regress - -# Local generated source files -/specparse.c -/specscanner.c - -# Generated subdirectories -/results/ -/log/ -/tmp_check/ diff --git a/src/test/isolation/specparse.c b/src/test/isolation/specparse.c new file mode 100644 index 000000000..2db53318f --- /dev/null +++ b/src/test/isolation/specparse.c @@ -0,0 +1,1822 @@ + +/* A Bison parser, made by GNU Bison 2.4.1. */ + +/* Skeleton implementation for Bison's Yacc-like parsers in C + + Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 + Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . */ + +/* As a special exception, you may create a larger work that contains + part or all of the Bison parser skeleton and distribute that work + under terms of your choice, so long as that work isn't itself a + parser generator using the skeleton or a modified version thereof + as a parser skeleton. Alternatively, if you modify or redistribute + the parser skeleton itself, you may (at your option) remove this + special exception, which will cause the skeleton and the resulting + Bison output files to be licensed under the GNU General Public + License without this special exception. + + This special exception was added by the Free Software Foundation in + version 2.2 of Bison. */ + +/* C LALR(1) parser skeleton written by Richard Stallman, by + simplifying the original so-called "semantic" parser. */ + +/* All symbols defined below should begin with yy or YY, to avoid + infringing on user name space. This should be done even for local + variables, as they might otherwise be expanded by user macros. + There are some unavoidable exceptions within include files to + define necessary library symbols; they are noted "INFRINGES ON + USER NAME SPACE" below. */ + +/* Identify Bison output. */ +#define YYBISON 1 + +/* Bison version. */ +#define YYBISON_VERSION "2.4.1" + +/* Skeleton name. */ +#define YYSKELETON_NAME "yacc.c" + +/* Pure parsers. */ +#define YYPURE 0 + +/* Push parsers. */ +#define YYPUSH 0 + +/* Pull parsers. */ +#define YYPULL 1 + +/* Using locations. */ +#define YYLSP_NEEDED 0 + +/* Substitute the variable and function names. */ +#define yyparse spec_yyparse +#define yylex spec_yylex +#define yyerror spec_yyerror +#define yylval spec_yylval +#define yychar spec_yychar +#define yydebug spec_yydebug +#define yynerrs spec_yynerrs + + +/* Copy the first part of user declarations. */ + +/* Line 189 of yacc.c */ +#line 1 "specparse.y" + +/*------------------------------------------------------------------------- + * + * specparse.y + * bison grammar for the isolation test file format + * + * Portions Copyright (c) 1996-2012, PostgreSQL Global Development Group + * Portions Copyright (c) 1994, Regents of the University of California + * + *------------------------------------------------------------------------- + */ + +#include "postgres_fe.h" + +#include "isolationtester.h" + + +TestSpec parseresult; /* result of parsing is left here */ + + + +/* Line 189 of yacc.c */ +#line 103 "specparse.c" + +/* Enabling traces. */ +#ifndef YYDEBUG +# define YYDEBUG 0 +#endif + +/* Enabling verbose error messages. */ +#ifdef YYERROR_VERBOSE +# undef YYERROR_VERBOSE +# define YYERROR_VERBOSE 1 +#else +# define YYERROR_VERBOSE 0 +#endif + +/* Enabling the token table. */ +#ifndef YYTOKEN_TABLE +# define YYTOKEN_TABLE 0 +#endif + + +/* Tokens. */ +#ifndef YYTOKENTYPE +# define YYTOKENTYPE + /* Put the tokens into the symbol table, so that GDB and other debuggers + know about them. */ + enum yytokentype { + sqlblock = 258, + string = 259, + PERMUTATION = 260, + SESSION = 261, + SETUP = 262, + STEP = 263, + TEARDOWN = 264, + TEST = 265 + }; +#endif + + + +#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED +typedef union YYSTYPE +{ + +/* Line 214 of yacc.c */ +#line 26 "specparse.y" + + char *str; + Session *session; + Step *step; + Permutation *permutation; + struct + { + void **elements; + int nelements; + } ptr_list; + + + +/* Line 214 of yacc.c */ +#line 163 "specparse.c" +} YYSTYPE; +# define YYSTYPE_IS_TRIVIAL 1 +# define yystype YYSTYPE /* obsolescent; will be withdrawn */ +# define YYSTYPE_IS_DECLARED 1 +#endif + + +/* Copy the second part of user declarations. */ + + +/* Line 264 of yacc.c */ +#line 175 "specparse.c" + +#ifdef short +# undef short +#endif + +#ifdef YYTYPE_UINT8 +typedef YYTYPE_UINT8 yytype_uint8; +#else +typedef unsigned char yytype_uint8; +#endif + +#ifdef YYTYPE_INT8 +typedef YYTYPE_INT8 yytype_int8; +#elif (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +typedef signed char yytype_int8; +#else +typedef short int yytype_int8; +#endif + +#ifdef YYTYPE_UINT16 +typedef YYTYPE_UINT16 yytype_uint16; +#else +typedef unsigned short int yytype_uint16; +#endif + +#ifdef YYTYPE_INT16 +typedef YYTYPE_INT16 yytype_int16; +#else +typedef short int yytype_int16; +#endif + +#ifndef YYSIZE_T +# ifdef __SIZE_TYPE__ +# define YYSIZE_T __SIZE_TYPE__ +# elif defined size_t +# define YYSIZE_T size_t +# elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +# include /* INFRINGES ON USER NAME SPACE */ +# define YYSIZE_T size_t +# else +# define YYSIZE_T unsigned int +# endif +#endif + +#define YYSIZE_MAXIMUM ((YYSIZE_T) -1) + +#ifndef YY_ +# if YYENABLE_NLS +# if ENABLE_NLS +# include /* INFRINGES ON USER NAME SPACE */ +# define YY_(msgid) dgettext ("bison-runtime", msgid) +# endif +# endif +# ifndef YY_ +# define YY_(msgid) msgid +# endif +#endif + +/* Suppress unused-variable warnings by "using" E. */ +#if ! defined lint || defined __GNUC__ +# define YYUSE(e) ((void) (e)) +#else +# define YYUSE(e) /* empty */ +#endif + +/* Identity function, used to suppress warnings about constant conditions. */ +#ifndef lint +# define YYID(n) (n) +#else +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static int +YYID (int yyi) +#else +static int +YYID (yyi) + int yyi; +#endif +{ + return yyi; +} +#endif + +#if ! defined yyoverflow || YYERROR_VERBOSE + +/* The parser invokes alloca or malloc; define the necessary symbols. */ + +# ifdef YYSTACK_USE_ALLOCA +# if YYSTACK_USE_ALLOCA +# ifdef __GNUC__ +# define YYSTACK_ALLOC __builtin_alloca +# elif defined __BUILTIN_VA_ARG_INCR +# include /* INFRINGES ON USER NAME SPACE */ +# elif defined _AIX +# define YYSTACK_ALLOC __alloca +# elif defined _MSC_VER +# include /* INFRINGES ON USER NAME SPACE */ +# define alloca _alloca +# else +# define YYSTACK_ALLOC alloca +# if ! defined _ALLOCA_H && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +# include /* INFRINGES ON USER NAME SPACE */ +# ifndef _STDLIB_H +# define _STDLIB_H 1 +# endif +# endif +# endif +# endif +# endif + +# ifdef YYSTACK_ALLOC + /* Pacify GCC's `empty if-body' warning. */ +# define YYSTACK_FREE(Ptr) do { /* empty */; } while (YYID (0)) +# ifndef YYSTACK_ALLOC_MAXIMUM + /* The OS might guarantee only one guard page at the bottom of the stack, + and a page size can be as small as 4096 bytes. So we cannot safely + invoke alloca (N) if N exceeds 4096. Use a slightly smaller number + to allow for a few compiler-allocated temporary stack slots. */ +# define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */ +# endif +# else +# define YYSTACK_ALLOC YYMALLOC +# define YYSTACK_FREE YYFREE +# ifndef YYSTACK_ALLOC_MAXIMUM +# define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM +# endif +# if (defined __cplusplus && ! defined _STDLIB_H \ + && ! ((defined YYMALLOC || defined malloc) \ + && (defined YYFREE || defined free))) +# include /* INFRINGES ON USER NAME SPACE */ +# ifndef _STDLIB_H +# define _STDLIB_H 1 +# endif +# endif +# ifndef YYMALLOC +# define YYMALLOC malloc +# if ! defined malloc && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */ +# endif +# endif +# ifndef YYFREE +# define YYFREE free +# if ! defined free && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +void free (void *); /* INFRINGES ON USER NAME SPACE */ +# endif +# endif +# endif +#endif /* ! defined yyoverflow || YYERROR_VERBOSE */ + + +#if (! defined yyoverflow \ + && (! defined __cplusplus \ + || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) + +/* A type that is properly aligned for any stack member. */ +union yyalloc +{ + yytype_int16 yyss_alloc; + YYSTYPE yyvs_alloc; +}; + +/* The size of the maximum gap between one aligned stack and the next. */ +# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1) + +/* The size of an array large to enough to hold all stacks, each with + N elements. */ +# define YYSTACK_BYTES(N) \ + ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \ + + YYSTACK_GAP_MAXIMUM) + +/* Copy COUNT objects from FROM to TO. The source and destination do + not overlap. */ +# ifndef YYCOPY +# if defined __GNUC__ && 1 < __GNUC__ +# define YYCOPY(To, From, Count) \ + __builtin_memcpy (To, From, (Count) * sizeof (*(From))) +# else +# define YYCOPY(To, From, Count) \ + do \ + { \ + YYSIZE_T yyi; \ + for (yyi = 0; yyi < (Count); yyi++) \ + (To)[yyi] = (From)[yyi]; \ + } \ + while (YYID (0)) +# endif +# endif + +/* Relocate STACK from its old location to the new one. The + local variables YYSIZE and YYSTACKSIZE give the old and new number of + elements in the stack, and YYPTR gives the new location of the + stack. Advance YYPTR to a properly aligned location for the next + stack. */ +# define YYSTACK_RELOCATE(Stack_alloc, Stack) \ + do \ + { \ + YYSIZE_T yynewbytes; \ + YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \ + Stack = &yyptr->Stack_alloc; \ + yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ + yyptr += yynewbytes / sizeof (*yyptr); \ + } \ + while (YYID (0)) + +#endif + +/* YYFINAL -- State number of the termination state. */ +#define YYFINAL 3 +/* YYLAST -- Last index in YYTABLE. */ +#define YYLAST 30 + +/* YYNTOKENS -- Number of terminals. */ +#define YYNTOKENS 11 +/* YYNNTS -- Number of nonterminals. */ +#define YYNNTS 14 +/* YYNRULES -- Number of rules. */ +#define YYNRULES 22 +/* YYNRULES -- Number of states. */ +#define YYNSTATES 32 + +/* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */ +#define YYUNDEFTOK 2 +#define YYMAXUTOK 265 + +#define YYTRANSLATE(YYX) \ + ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) + +/* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */ +static const yytype_uint8 yytranslate[] = +{ + 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 1, 2, 3, 4, + 5, 6, 7, 8, 9, 10 +}; + +#if YYDEBUG +/* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in + YYRHS. */ +static const yytype_uint8 yyprhs[] = +{ + 0, 0, 3, 8, 9, 12, 13, 15, 18, 19, + 22, 25, 27, 33, 36, 38, 42, 44, 45, 48, + 50, 53, 56 +}; + +/* YYRHS -- A `-1'-separated list of the rules' RHS. */ +static const yytype_int8 yyrhs[] = +{ + 12, 0, -1, 13, 16, 17, 21, -1, -1, 13, + 15, -1, -1, 15, -1, 7, 3, -1, -1, 9, + 3, -1, 17, 18, -1, 18, -1, 6, 4, 14, + 19, 16, -1, 19, 20, -1, 20, -1, 8, 4, + 3, -1, 22, -1, -1, 22, 23, -1, 23, -1, + 5, 24, -1, 24, 4, -1, 4, -1 +}; + +/* YYRLINE[YYN] -- source line where rule number YYN was defined. */ +static const yytype_uint8 yyrline[] = +{ + 0, 53, 53, 70, 74, 84, 85, 89, 93, 94, + 98, 105, 114, 126, 133, 143, 154, 159, 165, 172, + 182, 191, 198 +}; +#endif + +#if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE +/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM. + First, the terminals, then, starting at YYNTOKENS, nonterminals. */ +static const char *const yytname[] = +{ + "$end", "error", "$undefined", "sqlblock", "string", "PERMUTATION", + "SESSION", "SETUP", "STEP", "TEARDOWN", "TEST", "$accept", "TestSpec", + "setup_list", "opt_setup", "setup", "opt_teardown", "session_list", + "session", "step_list", "step", "opt_permutation_list", + "permutation_list", "permutation", "string_list", 0 +}; +#endif + +# ifdef YYPRINT +/* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to + token YYLEX-NUM. */ +static const yytype_uint16 yytoknum[] = +{ + 0, 256, 257, 258, 259, 260, 261, 262, 263, 264, + 265 +}; +# endif + +/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ +static const yytype_uint8 yyr1[] = +{ + 0, 11, 12, 13, 13, 14, 14, 15, 16, 16, + 17, 17, 18, 19, 19, 20, 21, 21, 22, 22, + 23, 24, 24 +}; + +/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */ +static const yytype_uint8 yyr2[] = +{ + 0, 2, 4, 0, 2, 0, 1, 2, 0, 2, + 2, 1, 5, 2, 1, 3, 1, 0, 2, 1, + 2, 2, 1 +}; + +/* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state + STATE-NUM when YYTABLE doesn't specify something else to do. Zero + means the default is an error. */ +static const yytype_uint8 yydefact[] = +{ + 3, 0, 8, 1, 0, 0, 4, 0, 7, 9, + 0, 17, 11, 5, 0, 10, 2, 16, 19, 0, + 6, 22, 20, 18, 0, 8, 14, 21, 0, 12, + 13, 15 +}; + +/* YYDEFGOTO[NTERM-NUM]. */ +static const yytype_int8 yydefgoto[] = +{ + -1, 1, 2, 19, 6, 7, 11, 12, 25, 26, + 16, 17, 18, 22 +}; + +/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing + STATE-NUM. */ +#define YYPACT_NINF -15 +static const yytype_int8 yypact[] = +{ + -15, 1, -7, -15, 4, 5, -15, 3, -15, -15, + 6, -2, -15, 7, 8, -15, -15, 10, -15, 9, + -15, -15, 12, -15, 14, -3, -15, -15, 16, -15, + -15, -15 +}; + +/* YYPGOTO[NTERM-NUM]. */ +static const yytype_int8 yypgoto[] = +{ + -15, -15, -15, -15, 0, -14, -15, 11, -15, -5, + -15, -15, 13, -15 +}; + +/* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If + positive, shift that token. If negative, reduce the rule which + number is the opposite. If zero, do what YYDEFACT says. + If YYTABLE_NINF, syntax error. */ +#define YYTABLE_NINF -1 +static const yytype_uint8 yytable[] = +{ + 4, 3, 5, 14, 10, 24, 5, 8, 9, 10, + 13, 29, 21, 20, 4, 14, 27, 24, 28, 31, + 30, 0, 15, 0, 0, 0, 0, 0, 0, 0, + 23 +}; + +static const yytype_int8 yycheck[] = +{ + 7, 0, 9, 5, 6, 8, 9, 3, 3, 6, + 4, 25, 4, 13, 7, 5, 4, 8, 4, 3, + 25, -1, 11, -1, -1, -1, -1, -1, -1, -1, + 17 +}; + +/* YYSTOS[STATE-NUM] -- The (internal number of the) accessing + symbol of state STATE-NUM. */ +static const yytype_uint8 yystos[] = +{ + 0, 12, 13, 0, 7, 9, 15, 16, 3, 3, + 6, 17, 18, 4, 5, 18, 21, 22, 23, 14, + 15, 4, 24, 23, 8, 19, 20, 4, 4, 16, + 20, 3 +}; + +#define yyerrok (yyerrstatus = 0) +#define yyclearin (yychar = YYEMPTY) +#define YYEMPTY (-2) +#define YYEOF 0 + +#define YYACCEPT goto yyacceptlab +#define YYABORT goto yyabortlab +#define YYERROR goto yyerrorlab + + +/* Like YYERROR except do call yyerror. This remains here temporarily + to ease the transition to the new meaning of YYERROR, for GCC. + Once GCC version 2 has supplanted version 1, this can go. */ + +#define YYFAIL goto yyerrlab + +#define YYRECOVERING() (!!yyerrstatus) + +#define YYBACKUP(Token, Value) \ +do \ + if (yychar == YYEMPTY && yylen == 1) \ + { \ + yychar = (Token); \ + yylval = (Value); \ + yytoken = YYTRANSLATE (yychar); \ + YYPOPSTACK (1); \ + goto yybackup; \ + } \ + else \ + { \ + yyerror (YY_("syntax error: cannot back up")); \ + YYERROR; \ + } \ +while (YYID (0)) + + +#define YYTERROR 1 +#define YYERRCODE 256 + + +/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N]. + If N is 0, then set CURRENT to the empty location which ends + the previous symbol: RHS[0] (always defined). */ + +#define YYRHSLOC(Rhs, K) ((Rhs)[K]) +#ifndef YYLLOC_DEFAULT +# define YYLLOC_DEFAULT(Current, Rhs, N) \ + do \ + if (YYID (N)) \ + { \ + (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \ + (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \ + (Current).last_line = YYRHSLOC (Rhs, N).last_line; \ + (Current).last_column = YYRHSLOC (Rhs, N).last_column; \ + } \ + else \ + { \ + (Current).first_line = (Current).last_line = \ + YYRHSLOC (Rhs, 0).last_line; \ + (Current).first_column = (Current).last_column = \ + YYRHSLOC (Rhs, 0).last_column; \ + } \ + while (YYID (0)) +#endif + + +/* YY_LOCATION_PRINT -- Print the location on the stream. + This macro was not mandated originally: define only if we know + we won't break user code: when these are the locations we know. */ + +#ifndef YY_LOCATION_PRINT +# if YYLTYPE_IS_TRIVIAL +# define YY_LOCATION_PRINT(File, Loc) \ + fprintf (File, "%d.%d-%d.%d", \ + (Loc).first_line, (Loc).first_column, \ + (Loc).last_line, (Loc).last_column) +# else +# define YY_LOCATION_PRINT(File, Loc) ((void) 0) +# endif +#endif + + +/* YYLEX -- calling `yylex' with the right arguments. */ + +#ifdef YYLEX_PARAM +# define YYLEX yylex (YYLEX_PARAM) +#else +# define YYLEX yylex () +#endif + +/* Enable debugging if requested. */ +#if YYDEBUG + +# ifndef YYFPRINTF +# include /* INFRINGES ON USER NAME SPACE */ +# define YYFPRINTF fprintf +# endif + +# define YYDPRINTF(Args) \ +do { \ + if (yydebug) \ + YYFPRINTF Args; \ +} while (YYID (0)) + +# define YY_SYMBOL_PRINT(Title, Type, Value, Location) \ +do { \ + if (yydebug) \ + { \ + YYFPRINTF (stderr, "%s ", Title); \ + yy_symbol_print (stderr, \ + Type, Value); \ + YYFPRINTF (stderr, "\n"); \ + } \ +} while (YYID (0)) + + +/*--------------------------------. +| Print this symbol on YYOUTPUT. | +`--------------------------------*/ + +/*ARGSUSED*/ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep) +#else +static void +yy_symbol_value_print (yyoutput, yytype, yyvaluep) + FILE *yyoutput; + int yytype; + YYSTYPE const * const yyvaluep; +#endif +{ + if (!yyvaluep) + return; +# ifdef YYPRINT + if (yytype < YYNTOKENS) + YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep); +# else + YYUSE (yyoutput); +# endif + switch (yytype) + { + default: + break; + } +} + + +/*--------------------------------. +| Print this symbol on YYOUTPUT. | +`--------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep) +#else +static void +yy_symbol_print (yyoutput, yytype, yyvaluep) + FILE *yyoutput; + int yytype; + YYSTYPE const * const yyvaluep; +#endif +{ + if (yytype < YYNTOKENS) + YYFPRINTF (yyoutput, "token %s (", yytname[yytype]); + else + YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]); + + yy_symbol_value_print (yyoutput, yytype, yyvaluep); + YYFPRINTF (yyoutput, ")"); +} + +/*------------------------------------------------------------------. +| yy_stack_print -- Print the state stack from its BOTTOM up to its | +| TOP (included). | +`------------------------------------------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop) +#else +static void +yy_stack_print (yybottom, yytop) + yytype_int16 *yybottom; + yytype_int16 *yytop; +#endif +{ + YYFPRINTF (stderr, "Stack now"); + for (; yybottom <= yytop; yybottom++) + { + int yybot = *yybottom; + YYFPRINTF (stderr, " %d", yybot); + } + YYFPRINTF (stderr, "\n"); +} + +# define YY_STACK_PRINT(Bottom, Top) \ +do { \ + if (yydebug) \ + yy_stack_print ((Bottom), (Top)); \ +} while (YYID (0)) + + +/*------------------------------------------------. +| Report that the YYRULE is going to be reduced. | +`------------------------------------------------*/ + +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yy_reduce_print (YYSTYPE *yyvsp, int yyrule) +#else +static void +yy_reduce_print (yyvsp, yyrule) + YYSTYPE *yyvsp; + int yyrule; +#endif +{ + int yynrhs = yyr2[yyrule]; + int yyi; + unsigned long int yylno = yyrline[yyrule]; + YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n", + yyrule - 1, yylno); + /* The symbols being reduced. */ + for (yyi = 0; yyi < yynrhs; yyi++) + { + YYFPRINTF (stderr, " $%d = ", yyi + 1); + yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi], + &(yyvsp[(yyi + 1) - (yynrhs)]) + ); + YYFPRINTF (stderr, "\n"); + } +} + +# define YY_REDUCE_PRINT(Rule) \ +do { \ + if (yydebug) \ + yy_reduce_print (yyvsp, Rule); \ +} while (YYID (0)) + +/* Nonzero means print parse trace. It is left uninitialized so that + multiple parsers can coexist. */ +int yydebug; +#else /* !YYDEBUG */ +# define YYDPRINTF(Args) +# define YY_SYMBOL_PRINT(Title, Type, Value, Location) +# define YY_STACK_PRINT(Bottom, Top) +# define YY_REDUCE_PRINT(Rule) +#endif /* !YYDEBUG */ + + +/* YYINITDEPTH -- initial size of the parser's stacks. */ +#ifndef YYINITDEPTH +# define YYINITDEPTH 200 +#endif + +/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only + if the built-in stack extension method is used). + + Do not make this value too large; the results are undefined if + YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH) + evaluated with infinite-precision integer arithmetic. */ + +#ifndef YYMAXDEPTH +# define YYMAXDEPTH 10000 +#endif + + + +#if YYERROR_VERBOSE + +# ifndef yystrlen +# if defined __GLIBC__ && defined _STRING_H +# define yystrlen strlen +# else +/* Return the length of YYSTR. */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static YYSIZE_T +yystrlen (const char *yystr) +#else +static YYSIZE_T +yystrlen (yystr) + const char *yystr; +#endif +{ + YYSIZE_T yylen; + for (yylen = 0; yystr[yylen]; yylen++) + continue; + return yylen; +} +# endif +# endif + +# ifndef yystpcpy +# if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE +# define yystpcpy stpcpy +# else +/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in + YYDEST. */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static char * +yystpcpy (char *yydest, const char *yysrc) +#else +static char * +yystpcpy (yydest, yysrc) + char *yydest; + const char *yysrc; +#endif +{ + char *yyd = yydest; + const char *yys = yysrc; + + while ((*yyd++ = *yys++) != '\0') + continue; + + return yyd - 1; +} +# endif +# endif + +# ifndef yytnamerr +/* Copy to YYRES the contents of YYSTR after stripping away unnecessary + quotes and backslashes, so that it's suitable for yyerror. The + heuristic is that double-quoting is unnecessary unless the string + contains an apostrophe, a comma, or backslash (other than + backslash-backslash). YYSTR is taken from yytname. If YYRES is + null, do not copy; instead, return the length of what the result + would have been. */ +static YYSIZE_T +yytnamerr (char *yyres, const char *yystr) +{ + if (*yystr == '"') + { + YYSIZE_T yyn = 0; + char const *yyp = yystr; + + for (;;) + switch (*++yyp) + { + case '\'': + case ',': + goto do_not_strip_quotes; + + case '\\': + if (*++yyp != '\\') + goto do_not_strip_quotes; + /* Fall through. */ + default: + if (yyres) + yyres[yyn] = *yyp; + yyn++; + break; + + case '"': + if (yyres) + yyres[yyn] = '\0'; + return yyn; + } + do_not_strip_quotes: ; + } + + if (! yyres) + return yystrlen (yystr); + + return yystpcpy (yyres, yystr) - yyres; +} +# endif + +/* Copy into YYRESULT an error message about the unexpected token + YYCHAR while in state YYSTATE. Return the number of bytes copied, + including the terminating null byte. If YYRESULT is null, do not + copy anything; just return the number of bytes that would be + copied. As a special case, return 0 if an ordinary "syntax error" + message will do. Return YYSIZE_MAXIMUM if overflow occurs during + size calculation. */ +static YYSIZE_T +yysyntax_error (char *yyresult, int yystate, int yychar) +{ + int yyn = yypact[yystate]; + + if (! (YYPACT_NINF < yyn && yyn <= YYLAST)) + return 0; + else + { + int yytype = YYTRANSLATE (yychar); + YYSIZE_T yysize0 = yytnamerr (0, yytname[yytype]); + YYSIZE_T yysize = yysize0; + YYSIZE_T yysize1; + int yysize_overflow = 0; + enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; + char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; + int yyx; + +# if 0 + /* This is so xgettext sees the translatable formats that are + constructed on the fly. */ + YY_("syntax error, unexpected %s"); + YY_("syntax error, unexpected %s, expecting %s"); + YY_("syntax error, unexpected %s, expecting %s or %s"); + YY_("syntax error, unexpected %s, expecting %s or %s or %s"); + YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"); +# endif + char *yyfmt; + char const *yyf; + static char const yyunexpected[] = "syntax error, unexpected %s"; + static char const yyexpecting[] = ", expecting %s"; + static char const yyor[] = " or %s"; + char yyformat[sizeof yyunexpected + + sizeof yyexpecting - 1 + + ((YYERROR_VERBOSE_ARGS_MAXIMUM - 2) + * (sizeof yyor - 1))]; + char const *yyprefix = yyexpecting; + + /* Start YYX at -YYN if negative to avoid negative indexes in + YYCHECK. */ + int yyxbegin = yyn < 0 ? -yyn : 0; + + /* Stay within bounds of both yycheck and yytname. */ + int yychecklim = YYLAST - yyn + 1; + int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; + int yycount = 1; + + yyarg[0] = yytname[yytype]; + yyfmt = yystpcpy (yyformat, yyunexpected); + + for (yyx = yyxbegin; yyx < yyxend; ++yyx) + if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR) + { + if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) + { + yycount = 1; + yysize = yysize0; + yyformat[sizeof yyunexpected - 1] = '\0'; + break; + } + yyarg[yycount++] = yytname[yyx]; + yysize1 = yysize + yytnamerr (0, yytname[yyx]); + yysize_overflow |= (yysize1 < yysize); + yysize = yysize1; + yyfmt = yystpcpy (yyfmt, yyprefix); + yyprefix = yyor; + } + + yyf = YY_(yyformat); + yysize1 = yysize + yystrlen (yyf); + yysize_overflow |= (yysize1 < yysize); + yysize = yysize1; + + if (yysize_overflow) + return YYSIZE_MAXIMUM; + + if (yyresult) + { + /* Avoid sprintf, as that infringes on the user's name space. + Don't have undefined behavior even if the translation + produced a string with the wrong number of "%s"s. */ + char *yyp = yyresult; + int yyi = 0; + while ((*yyp = *yyf) != '\0') + { + if (*yyp == '%' && yyf[1] == 's' && yyi < yycount) + { + yyp += yytnamerr (yyp, yyarg[yyi++]); + yyf += 2; + } + else + { + yyp++; + yyf++; + } + } + } + return yysize; + } +} +#endif /* YYERROR_VERBOSE */ + + +/*-----------------------------------------------. +| Release the memory associated to this symbol. | +`-----------------------------------------------*/ + +/*ARGSUSED*/ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +static void +yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep) +#else +static void +yydestruct (yymsg, yytype, yyvaluep) + const char *yymsg; + int yytype; + YYSTYPE *yyvaluep; +#endif +{ + YYUSE (yyvaluep); + + if (!yymsg) + yymsg = "Deleting"; + YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp); + + switch (yytype) + { + + default: + break; + } +} + +/* Prevent warnings from -Wmissing-prototypes. */ +#ifdef YYPARSE_PARAM +#if defined __STDC__ || defined __cplusplus +int yyparse (void *YYPARSE_PARAM); +#else +int yyparse (); +#endif +#else /* ! YYPARSE_PARAM */ +#if defined __STDC__ || defined __cplusplus +int yyparse (void); +#else +int yyparse (); +#endif +#endif /* ! YYPARSE_PARAM */ + + +/* The lookahead symbol. */ +int yychar; + +/* The semantic value of the lookahead symbol. */ +YYSTYPE yylval; + +/* Number of syntax errors so far. */ +int yynerrs; + + + +/*-------------------------. +| yyparse or yypush_parse. | +`-------------------------*/ + +#ifdef YYPARSE_PARAM +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +int +yyparse (void *YYPARSE_PARAM) +#else +int +yyparse (YYPARSE_PARAM) + void *YYPARSE_PARAM; +#endif +#else /* ! YYPARSE_PARAM */ +#if (defined __STDC__ || defined __C99__FUNC__ \ + || defined __cplusplus || defined _MSC_VER) +int +yyparse (void) +#else +int +yyparse () + +#endif +#endif +{ + + + int yystate; + /* Number of tokens to shift before error messages enabled. */ + int yyerrstatus; + + /* The stacks and their tools: + `yyss': related to states. + `yyvs': related to semantic values. + + Refer to the stacks thru separate pointers, to allow yyoverflow + to reallocate them elsewhere. */ + + /* The state stack. */ + yytype_int16 yyssa[YYINITDEPTH]; + yytype_int16 *yyss; + yytype_int16 *yyssp; + + /* The semantic value stack. */ + YYSTYPE yyvsa[YYINITDEPTH]; + YYSTYPE *yyvs; + YYSTYPE *yyvsp; + + YYSIZE_T yystacksize; + + int yyn; + int yyresult; + /* Lookahead token as an internal (translated) token number. */ + int yytoken; + /* The variables used to return semantic value and location from the + action routines. */ + YYSTYPE yyval; + +#if YYERROR_VERBOSE + /* Buffer for error messages, and its allocated size. */ + char yymsgbuf[128]; + char *yymsg = yymsgbuf; + YYSIZE_T yymsg_alloc = sizeof yymsgbuf; +#endif + +#define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N)) + + /* The number of symbols on the RHS of the reduced rule. + Keep to zero when no symbol should be popped. */ + int yylen = 0; + + yytoken = 0; + yyss = yyssa; + yyvs = yyvsa; + yystacksize = YYINITDEPTH; + + YYDPRINTF ((stderr, "Starting parse\n")); + + yystate = 0; + yyerrstatus = 0; + yynerrs = 0; + yychar = YYEMPTY; /* Cause a token to be read. */ + + /* Initialize stack pointers. + Waste one element of value and location stack + so that they stay on the same level as the state stack. + The wasted elements are never initialized. */ + yyssp = yyss; + yyvsp = yyvs; + + goto yysetstate; + +/*------------------------------------------------------------. +| yynewstate -- Push a new state, which is found in yystate. | +`------------------------------------------------------------*/ + yynewstate: + /* In all cases, when you get here, the value and location stacks + have just been pushed. So pushing a state here evens the stacks. */ + yyssp++; + + yysetstate: + *yyssp = yystate; + + if (yyss + yystacksize - 1 <= yyssp) + { + /* Get the current used size of the three stacks, in elements. */ + YYSIZE_T yysize = yyssp - yyss + 1; + +#ifdef yyoverflow + { + /* Give user a chance to reallocate the stack. Use copies of + these so that the &'s don't force the real ones into + memory. */ + YYSTYPE *yyvs1 = yyvs; + yytype_int16 *yyss1 = yyss; + + /* Each stack pointer address is followed by the size of the + data in use in that stack, in bytes. This used to be a + conditional around just the two extra args, but that might + be undefined if yyoverflow is a macro. */ + yyoverflow (YY_("memory exhausted"), + &yyss1, yysize * sizeof (*yyssp), + &yyvs1, yysize * sizeof (*yyvsp), + &yystacksize); + + yyss = yyss1; + yyvs = yyvs1; + } +#else /* no yyoverflow */ +# ifndef YYSTACK_RELOCATE + goto yyexhaustedlab; +# else + /* Extend the stack our own way. */ + if (YYMAXDEPTH <= yystacksize) + goto yyexhaustedlab; + yystacksize *= 2; + if (YYMAXDEPTH < yystacksize) + yystacksize = YYMAXDEPTH; + + { + yytype_int16 *yyss1 = yyss; + union yyalloc *yyptr = + (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize)); + if (! yyptr) + goto yyexhaustedlab; + YYSTACK_RELOCATE (yyss_alloc, yyss); + YYSTACK_RELOCATE (yyvs_alloc, yyvs); +# undef YYSTACK_RELOCATE + if (yyss1 != yyssa) + YYSTACK_FREE (yyss1); + } +# endif +#endif /* no yyoverflow */ + + yyssp = yyss + yysize - 1; + yyvsp = yyvs + yysize - 1; + + YYDPRINTF ((stderr, "Stack size increased to %lu\n", + (unsigned long int) yystacksize)); + + if (yyss + yystacksize - 1 <= yyssp) + YYABORT; + } + + YYDPRINTF ((stderr, "Entering state %d\n", yystate)); + + if (yystate == YYFINAL) + YYACCEPT; + + goto yybackup; + +/*-----------. +| yybackup. | +`-----------*/ +yybackup: + + /* Do appropriate processing given the current state. Read a + lookahead token if we need one and don't already have one. */ + + /* First try to decide what to do without reference to lookahead token. */ + yyn = yypact[yystate]; + if (yyn == YYPACT_NINF) + goto yydefault; + + /* Not known => get a lookahead token if don't already have one. */ + + /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */ + if (yychar == YYEMPTY) + { + YYDPRINTF ((stderr, "Reading a token: ")); + yychar = YYLEX; + } + + if (yychar <= YYEOF) + { + yychar = yytoken = YYEOF; + YYDPRINTF ((stderr, "Now at end of input.\n")); + } + else + { + yytoken = YYTRANSLATE (yychar); + YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc); + } + + /* If the proper action on seeing token YYTOKEN is to reduce or to + detect an error, take that action. */ + yyn += yytoken; + if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken) + goto yydefault; + yyn = yytable[yyn]; + if (yyn <= 0) + { + if (yyn == 0 || yyn == YYTABLE_NINF) + goto yyerrlab; + yyn = -yyn; + goto yyreduce; + } + + /* Count tokens shifted since error; after three, turn off error + status. */ + if (yyerrstatus) + yyerrstatus--; + + /* Shift the lookahead token. */ + YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc); + + /* Discard the shifted token. */ + yychar = YYEMPTY; + + yystate = yyn; + *++yyvsp = yylval; + + goto yynewstate; + + +/*-----------------------------------------------------------. +| yydefault -- do the default action for the current state. | +`-----------------------------------------------------------*/ +yydefault: + yyn = yydefact[yystate]; + if (yyn == 0) + goto yyerrlab; + goto yyreduce; + + +/*-----------------------------. +| yyreduce -- Do a reduction. | +`-----------------------------*/ +yyreduce: + /* yyn is the number of a rule to reduce with. */ + yylen = yyr2[yyn]; + + /* If YYLEN is nonzero, implement the default value of the action: + `$$ = $1'. + + Otherwise, the following line sets YYVAL to garbage. + This behavior is undocumented and Bison + users should not rely upon it. Assigning to YYVAL + unconditionally makes the parser a bit smaller, and it avoids a + GCC warning that YYVAL may be used uninitialized. */ + yyval = yyvsp[1-yylen]; + + + YY_REDUCE_PRINT (yyn); + switch (yyn) + { + case 2: + +/* Line 1455 of yacc.c */ +#line 57 "specparse.y" + { + parseresult.setupsqls = (char **) (yyvsp[(1) - (4)].ptr_list).elements; + parseresult.nsetupsqls = (yyvsp[(1) - (4)].ptr_list).nelements; + parseresult.teardownsql = (yyvsp[(2) - (4)].str); + parseresult.sessions = (Session **) (yyvsp[(3) - (4)].ptr_list).elements; + parseresult.nsessions = (yyvsp[(3) - (4)].ptr_list).nelements; + parseresult.permutations = (Permutation **) (yyvsp[(4) - (4)].ptr_list).elements; + parseresult.npermutations = (yyvsp[(4) - (4)].ptr_list).nelements; + ;} + break; + + case 3: + +/* Line 1455 of yacc.c */ +#line 70 "specparse.y" + { + (yyval.ptr_list).elements = NULL; + (yyval.ptr_list).nelements = 0; + ;} + break; + + case 4: + +/* Line 1455 of yacc.c */ +#line 75 "specparse.y" + { + (yyval.ptr_list).elements = realloc((yyvsp[(1) - (2)].ptr_list).elements, + ((yyvsp[(1) - (2)].ptr_list).nelements + 1) * sizeof(void *)); + (yyval.ptr_list).elements[(yyvsp[(1) - (2)].ptr_list).nelements] = (yyvsp[(2) - (2)].str); + (yyval.ptr_list).nelements = (yyvsp[(1) - (2)].ptr_list).nelements + 1; + ;} + break; + + case 5: + +/* Line 1455 of yacc.c */ +#line 84 "specparse.y" + { (yyval.str) = NULL; ;} + break; + + case 6: + +/* Line 1455 of yacc.c */ +#line 85 "specparse.y" + { (yyval.str) = (yyvsp[(1) - (1)].str); ;} + break; + + case 7: + +/* Line 1455 of yacc.c */ +#line 89 "specparse.y" + { (yyval.str) = (yyvsp[(2) - (2)].str); ;} + break; + + case 8: + +/* Line 1455 of yacc.c */ +#line 93 "specparse.y" + { (yyval.str) = NULL; ;} + break; + + case 9: + +/* Line 1455 of yacc.c */ +#line 94 "specparse.y" + { (yyval.str) = (yyvsp[(2) - (2)].str); ;} + break; + + case 10: + +/* Line 1455 of yacc.c */ +#line 99 "specparse.y" + { + (yyval.ptr_list).elements = realloc((yyvsp[(1) - (2)].ptr_list).elements, + ((yyvsp[(1) - (2)].ptr_list).nelements + 1) * sizeof(void *)); + (yyval.ptr_list).elements[(yyvsp[(1) - (2)].ptr_list).nelements] = (yyvsp[(2) - (2)].session); + (yyval.ptr_list).nelements = (yyvsp[(1) - (2)].ptr_list).nelements + 1; + ;} + break; + + case 11: + +/* Line 1455 of yacc.c */ +#line 106 "specparse.y" + { + (yyval.ptr_list).nelements = 1; + (yyval.ptr_list).elements = malloc(sizeof(void *)); + (yyval.ptr_list).elements[0] = (yyvsp[(1) - (1)].session); + ;} + break; + + case 12: + +/* Line 1455 of yacc.c */ +#line 115 "specparse.y" + { + (yyval.session) = malloc(sizeof(Session)); + (yyval.session)->name = (yyvsp[(2) - (5)].str); + (yyval.session)->setupsql = (yyvsp[(3) - (5)].str); + (yyval.session)->steps = (Step **) (yyvsp[(4) - (5)].ptr_list).elements; + (yyval.session)->nsteps = (yyvsp[(4) - (5)].ptr_list).nelements; + (yyval.session)->teardownsql = (yyvsp[(5) - (5)].str); + ;} + break; + + case 13: + +/* Line 1455 of yacc.c */ +#line 127 "specparse.y" + { + (yyval.ptr_list).elements = realloc((yyvsp[(1) - (2)].ptr_list).elements, + ((yyvsp[(1) - (2)].ptr_list).nelements + 1) * sizeof(void *)); + (yyval.ptr_list).elements[(yyvsp[(1) - (2)].ptr_list).nelements] = (yyvsp[(2) - (2)].step); + (yyval.ptr_list).nelements = (yyvsp[(1) - (2)].ptr_list).nelements + 1; + ;} + break; + + case 14: + +/* Line 1455 of yacc.c */ +#line 134 "specparse.y" + { + (yyval.ptr_list).nelements = 1; + (yyval.ptr_list).elements = malloc(sizeof(void *)); + (yyval.ptr_list).elements[0] = (yyvsp[(1) - (1)].step); + ;} + break; + + case 15: + +/* Line 1455 of yacc.c */ +#line 144 "specparse.y" + { + (yyval.step) = malloc(sizeof(Step)); + (yyval.step)->name = (yyvsp[(2) - (3)].str); + (yyval.step)->sql = (yyvsp[(3) - (3)].str); + (yyval.step)->errormsg = NULL; + ;} + break; + + case 16: + +/* Line 1455 of yacc.c */ +#line 155 "specparse.y" + { + (yyval.ptr_list) = (yyvsp[(1) - (1)].ptr_list); + ;} + break; + + case 17: + +/* Line 1455 of yacc.c */ +#line 159 "specparse.y" + { + (yyval.ptr_list).elements = NULL; + (yyval.ptr_list).nelements = 0; + ;} + break; + + case 18: + +/* Line 1455 of yacc.c */ +#line 166 "specparse.y" + { + (yyval.ptr_list).elements = realloc((yyvsp[(1) - (2)].ptr_list).elements, + ((yyvsp[(1) - (2)].ptr_list).nelements + 1) * sizeof(void *)); + (yyval.ptr_list).elements[(yyvsp[(1) - (2)].ptr_list).nelements] = (yyvsp[(2) - (2)].permutation); + (yyval.ptr_list).nelements = (yyvsp[(1) - (2)].ptr_list).nelements + 1; + ;} + break; + + case 19: + +/* Line 1455 of yacc.c */ +#line 173 "specparse.y" + { + (yyval.ptr_list).nelements = 1; + (yyval.ptr_list).elements = malloc(sizeof(void *)); + (yyval.ptr_list).elements[0] = (yyvsp[(1) - (1)].permutation); + ;} + break; + + case 20: + +/* Line 1455 of yacc.c */ +#line 183 "specparse.y" + { + (yyval.permutation) = malloc(sizeof(Permutation)); + (yyval.permutation)->stepnames = (char **) (yyvsp[(2) - (2)].ptr_list).elements; + (yyval.permutation)->nsteps = (yyvsp[(2) - (2)].ptr_list).nelements; + ;} + break; + + case 21: + +/* Line 1455 of yacc.c */ +#line 192 "specparse.y" + { + (yyval.ptr_list).elements = realloc((yyvsp[(1) - (2)].ptr_list).elements, + ((yyvsp[(1) - (2)].ptr_list).nelements + 1) * sizeof(void *)); + (yyval.ptr_list).elements[(yyvsp[(1) - (2)].ptr_list).nelements] = (yyvsp[(2) - (2)].str); + (yyval.ptr_list).nelements = (yyvsp[(1) - (2)].ptr_list).nelements + 1; + ;} + break; + + case 22: + +/* Line 1455 of yacc.c */ +#line 199 "specparse.y" + { + (yyval.ptr_list).nelements = 1; + (yyval.ptr_list).elements = malloc(sizeof(void *)); + (yyval.ptr_list).elements[0] = (yyvsp[(1) - (1)].str); + ;} + break; + + + +/* Line 1455 of yacc.c */ +#line 1607 "specparse.c" + default: break; + } + YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); + + YYPOPSTACK (yylen); + yylen = 0; + YY_STACK_PRINT (yyss, yyssp); + + *++yyvsp = yyval; + + /* Now `shift' the result of the reduction. Determine what state + that goes to, based on the state we popped back to and the rule + number reduced by. */ + + yyn = yyr1[yyn]; + + yystate = yypgoto[yyn - YYNTOKENS] + *yyssp; + if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp) + yystate = yytable[yystate]; + else + yystate = yydefgoto[yyn - YYNTOKENS]; + + goto yynewstate; + + +/*------------------------------------. +| yyerrlab -- here on detecting error | +`------------------------------------*/ +yyerrlab: + /* If not already recovering from an error, report this error. */ + if (!yyerrstatus) + { + ++yynerrs; +#if ! YYERROR_VERBOSE + yyerror (YY_("syntax error")); +#else + { + YYSIZE_T yysize = yysyntax_error (0, yystate, yychar); + if (yymsg_alloc < yysize && yymsg_alloc < YYSTACK_ALLOC_MAXIMUM) + { + YYSIZE_T yyalloc = 2 * yysize; + if (! (yysize <= yyalloc && yyalloc <= YYSTACK_ALLOC_MAXIMUM)) + yyalloc = YYSTACK_ALLOC_MAXIMUM; + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); + yymsg = (char *) YYSTACK_ALLOC (yyalloc); + if (yymsg) + yymsg_alloc = yyalloc; + else + { + yymsg = yymsgbuf; + yymsg_alloc = sizeof yymsgbuf; + } + } + + if (0 < yysize && yysize <= yymsg_alloc) + { + (void) yysyntax_error (yymsg, yystate, yychar); + yyerror (yymsg); + } + else + { + yyerror (YY_("syntax error")); + if (yysize != 0) + goto yyexhaustedlab; + } + } +#endif + } + + + + if (yyerrstatus == 3) + { + /* If just tried and failed to reuse lookahead token after an + error, discard it. */ + + if (yychar <= YYEOF) + { + /* Return failure if at end of input. */ + if (yychar == YYEOF) + YYABORT; + } + else + { + yydestruct ("Error: discarding", + yytoken, &yylval); + yychar = YYEMPTY; + } + } + + /* Else will try to reuse lookahead token after shifting the error + token. */ + goto yyerrlab1; + + +/*---------------------------------------------------. +| yyerrorlab -- error raised explicitly by YYERROR. | +`---------------------------------------------------*/ +yyerrorlab: + + /* Pacify compilers like GCC when the user code never invokes + YYERROR and the label yyerrorlab therefore never appears in user + code. */ + if (/*CONSTCOND*/ 0) + goto yyerrorlab; + + /* Do not reclaim the symbols of the rule which action triggered + this YYERROR. */ + YYPOPSTACK (yylen); + yylen = 0; + YY_STACK_PRINT (yyss, yyssp); + yystate = *yyssp; + goto yyerrlab1; + + +/*-------------------------------------------------------------. +| yyerrlab1 -- common code for both syntax error and YYERROR. | +`-------------------------------------------------------------*/ +yyerrlab1: + yyerrstatus = 3; /* Each real token shifted decrements this. */ + + for (;;) + { + yyn = yypact[yystate]; + if (yyn != YYPACT_NINF) + { + yyn += YYTERROR; + if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR) + { + yyn = yytable[yyn]; + if (0 < yyn) + break; + } + } + + /* Pop the current state because it cannot handle the error token. */ + if (yyssp == yyss) + YYABORT; + + + yydestruct ("Error: popping", + yystos[yystate], yyvsp); + YYPOPSTACK (1); + yystate = *yyssp; + YY_STACK_PRINT (yyss, yyssp); + } + + *++yyvsp = yylval; + + + /* Shift the error token. */ + YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp); + + yystate = yyn; + goto yynewstate; + + +/*-------------------------------------. +| yyacceptlab -- YYACCEPT comes here. | +`-------------------------------------*/ +yyacceptlab: + yyresult = 0; + goto yyreturn; + +/*-----------------------------------. +| yyabortlab -- YYABORT comes here. | +`-----------------------------------*/ +yyabortlab: + yyresult = 1; + goto yyreturn; + +#if !defined(yyoverflow) || YYERROR_VERBOSE +/*-------------------------------------------------. +| yyexhaustedlab -- memory exhaustion comes here. | +`-------------------------------------------------*/ +yyexhaustedlab: + yyerror (YY_("memory exhausted")); + yyresult = 2; + /* Fall through. */ +#endif + +yyreturn: + if (yychar != YYEMPTY) + yydestruct ("Cleanup: discarding lookahead", + yytoken, &yylval); + /* Do not reclaim the symbols of the rule which action triggered + this YYABORT or YYACCEPT. */ + YYPOPSTACK (yylen); + YY_STACK_PRINT (yyss, yyssp); + while (yyssp != yyss) + { + yydestruct ("Cleanup: popping", + yystos[*yyssp], yyvsp); + YYPOPSTACK (1); + } +#ifndef yyoverflow + if (yyss != yyssa) + YYSTACK_FREE (yyss); +#endif +#if YYERROR_VERBOSE + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); +#endif + /* Make sure YYID is used. */ + return YYID (yyresult); +} + + + +/* Line 1675 of yacc.c */ +#line 206 "specparse.y" + + +#include "specscanner.c" + diff --git a/src/test/isolation/specscanner.c b/src/test/isolation/specscanner.c new file mode 100644 index 000000000..6e85ac975 --- /dev/null +++ b/src/test/isolation/specscanner.c @@ -0,0 +1,1917 @@ +#line 2 "specscanner.c" + +#line 4 "specscanner.c" + +#define YY_INT_ALIGNED short int + +/* A lexical scanner generated by flex */ + +#define yy_create_buffer spec_yy_create_buffer +#define yy_delete_buffer spec_yy_delete_buffer +#define yy_flex_debug spec_yy_flex_debug +#define yy_init_buffer spec_yy_init_buffer +#define yy_flush_buffer spec_yy_flush_buffer +#define yy_load_buffer_state spec_yy_load_buffer_state +#define yy_switch_to_buffer spec_yy_switch_to_buffer +#define yyin spec_yyin +#define yyleng spec_yyleng +#define yylex spec_yylex +#define yylineno spec_yylineno +#define yyout spec_yyout +#define yyrestart spec_yyrestart +#define yytext spec_yytext +#define yywrap spec_yywrap +#define yyalloc spec_yyalloc +#define yyrealloc spec_yyrealloc +#define yyfree spec_yyfree + +#define FLEX_SCANNER +#define YY_FLEX_MAJOR_VERSION 2 +#define YY_FLEX_MINOR_VERSION 5 +#define YY_FLEX_SUBMINOR_VERSION 35 +#if YY_FLEX_SUBMINOR_VERSION > 0 +#define FLEX_BETA +#endif + +/* First, we deal with platform-specific or compiler-specific issues. */ + +/* begin standard C headers. */ +#include +#include +#include +#include + +/* end standard C headers. */ + +/* flex integer type definitions */ + +#ifndef FLEXINT_H +#define FLEXINT_H + +/* C99 systems have . Non-C99 systems may or may not. */ + +#if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L + +/* C99 says to define __STDC_LIMIT_MACROS before including stdint.h, + * if you want the limit (max/min) macros for int types. + */ +#ifndef __STDC_LIMIT_MACROS +#define __STDC_LIMIT_MACROS 1 +#endif + +#include +typedef int8_t flex_int8_t; +typedef uint8_t flex_uint8_t; +typedef int16_t flex_int16_t; +typedef uint16_t flex_uint16_t; +typedef int32_t flex_int32_t; +typedef uint32_t flex_uint32_t; +#else +typedef signed char flex_int8_t; +typedef short int flex_int16_t; +typedef int flex_int32_t; +typedef unsigned char flex_uint8_t; +typedef unsigned short int flex_uint16_t; +typedef unsigned int flex_uint32_t; + +/* Limits of integral types. */ +#ifndef INT8_MIN +#define INT8_MIN (-128) +#endif +#ifndef INT16_MIN +#define INT16_MIN (-32767-1) +#endif +#ifndef INT32_MIN +#define INT32_MIN (-2147483647-1) +#endif +#ifndef INT8_MAX +#define INT8_MAX (127) +#endif +#ifndef INT16_MAX +#define INT16_MAX (32767) +#endif +#ifndef INT32_MAX +#define INT32_MAX (2147483647) +#endif +#ifndef UINT8_MAX +#define UINT8_MAX (255U) +#endif +#ifndef UINT16_MAX +#define UINT16_MAX (65535U) +#endif +#ifndef UINT32_MAX +#define UINT32_MAX (4294967295U) +#endif + +#endif /* ! C99 */ + +#endif /* ! FLEXINT_H */ + +#ifdef __cplusplus + +/* The "const" storage-class-modifier is valid. */ +#define YY_USE_CONST + +#else /* ! __cplusplus */ + +/* C99 requires __STDC__ to be defined as 1. */ +#if defined (__STDC__) + +#define YY_USE_CONST + +#endif /* defined (__STDC__) */ +#endif /* ! __cplusplus */ + +#ifdef YY_USE_CONST +#define yyconst const +#else +#define yyconst +#endif + +/* Returned upon end-of-file. */ +#define YY_NULL 0 + +/* Promotes a possibly negative, possibly signed char to an unsigned + * integer for use as an array index. If the signed char is negative, + * we want to instead treat it as an 8-bit unsigned char, hence the + * double cast. + */ +#define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c) + +/* Enter a start condition. This macro really ought to take a parameter, + * but we do it the disgusting crufty way forced on us by the ()-less + * definition of BEGIN. + */ +#define BEGIN (yy_start) = 1 + 2 * + +/* Translate the current start state into a value that can be later handed + * to BEGIN to return to the state. The YYSTATE alias is for lex + * compatibility. + */ +#define YY_START (((yy_start) - 1) / 2) +#define YYSTATE YY_START + +/* Action number for EOF rule of a given start state. */ +#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1) + +/* Special action meaning "start processing a new file". */ +#define YY_NEW_FILE spec_yyrestart(spec_yyin ) + +#define YY_END_OF_BUFFER_CHAR 0 + +/* Size of default input buffer. */ +#ifndef YY_BUF_SIZE +#ifdef __ia64__ +/* On IA-64, the buffer size is 16k, not 8k. + * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case. + * Ditto for the __ia64__ case accordingly. + */ +#define YY_BUF_SIZE 32768 +#else +#define YY_BUF_SIZE 16384 +#endif /* __ia64__ */ +#endif + +/* The state buf must be large enough to hold one state per character in the main buffer. + */ +#define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type)) + +#ifndef YY_TYPEDEF_YY_BUFFER_STATE +#define YY_TYPEDEF_YY_BUFFER_STATE +typedef struct yy_buffer_state *YY_BUFFER_STATE; +#endif + +extern int spec_yyleng; + +extern FILE *spec_yyin, *spec_yyout; + +#define EOB_ACT_CONTINUE_SCAN 0 +#define EOB_ACT_END_OF_FILE 1 +#define EOB_ACT_LAST_MATCH 2 + + #define YY_LESS_LINENO(n) + +/* Return all but the first "n" matched characters back to the input stream. */ +#define yyless(n) \ + do \ + { \ + /* Undo effects of setting up spec_yytext. */ \ + int yyless_macro_arg = (n); \ + YY_LESS_LINENO(yyless_macro_arg);\ + *yy_cp = (yy_hold_char); \ + YY_RESTORE_YY_MORE_OFFSET \ + (yy_c_buf_p) = yy_cp = yy_bp + yyless_macro_arg - YY_MORE_ADJ; \ + YY_DO_BEFORE_ACTION; /* set up spec_yytext again */ \ + } \ + while ( 0 ) + +#define unput(c) yyunput( c, (yytext_ptr) ) + +#ifndef YY_TYPEDEF_YY_SIZE_T +#define YY_TYPEDEF_YY_SIZE_T +typedef size_t yy_size_t; +#endif + +#ifndef YY_STRUCT_YY_BUFFER_STATE +#define YY_STRUCT_YY_BUFFER_STATE +struct yy_buffer_state + { + FILE *yy_input_file; + + char *yy_ch_buf; /* input buffer */ + char *yy_buf_pos; /* current position in input buffer */ + + /* Size of input buffer in bytes, not including room for EOB + * characters. + */ + yy_size_t yy_buf_size; + + /* Number of characters read into yy_ch_buf, not including EOB + * characters. + */ + int yy_n_chars; + + /* Whether we "own" the buffer - i.e., we know we created it, + * and can realloc() it to grow it, and should free() it to + * delete it. + */ + int yy_is_our_buffer; + + /* Whether this is an "interactive" input source; if so, and + * if we're using stdio for input, then we want to use getc() + * instead of fread(), to make sure we stop fetching input after + * each newline. + */ + int yy_is_interactive; + + /* Whether we're considered to be at the beginning of a line. + * If so, '^' rules will be active on the next match, otherwise + * not. + */ + int yy_at_bol; + + int yy_bs_lineno; /**< The line count. */ + int yy_bs_column; /**< The column count. */ + + /* Whether to try to fill the input buffer when we reach the + * end of it. + */ + int yy_fill_buffer; + + int yy_buffer_status; + +#define YY_BUFFER_NEW 0 +#define YY_BUFFER_NORMAL 1 + /* When an EOF's been seen but there's still some text to process + * then we mark the buffer as YY_EOF_PENDING, to indicate that we + * shouldn't try reading from the input source any more. We might + * still have a bunch of tokens to match, though, because of + * possible backing-up. + * + * When we actually see the EOF, we change the status to "new" + * (via spec_yyrestart()), so that the user can continue scanning by + * just pointing spec_yyin at a new input file. + */ +#define YY_BUFFER_EOF_PENDING 2 + + }; +#endif /* !YY_STRUCT_YY_BUFFER_STATE */ + +/* Stack of input buffers. */ +static size_t yy_buffer_stack_top = 0; /**< index of top of stack. */ +static size_t yy_buffer_stack_max = 0; /**< capacity of stack. */ +static YY_BUFFER_STATE * yy_buffer_stack = 0; /**< Stack as an array. */ + +/* We provide macros for accessing buffer states in case in the + * future we want to put the buffer states in a more general + * "scanner state". + * + * Returns the top of the stack, or NULL. + */ +#define YY_CURRENT_BUFFER ( (yy_buffer_stack) \ + ? (yy_buffer_stack)[(yy_buffer_stack_top)] \ + : NULL) + +/* Same as previous macro, but useful when we know that the buffer stack is not + * NULL or when we need an lvalue. For internal use only. + */ +#define YY_CURRENT_BUFFER_LVALUE (yy_buffer_stack)[(yy_buffer_stack_top)] + +/* yy_hold_char holds the character lost when spec_yytext is formed. */ +static char yy_hold_char; +static int yy_n_chars; /* number of characters read into yy_ch_buf */ +int spec_yyleng; + +/* Points to current character in buffer. */ +static char *yy_c_buf_p = (char *) 0; +static int yy_init = 0; /* whether we need to initialize */ +static int yy_start = 0; /* start state number */ + +/* Flag which is used to allow spec_yywrap()'s to do buffer switches + * instead of setting up a fresh spec_yyin. A bit of a hack ... + */ +static int yy_did_buffer_switch_on_eof; + +void spec_yyrestart (FILE *input_file ); +void spec_yy_switch_to_buffer (YY_BUFFER_STATE new_buffer ); +YY_BUFFER_STATE spec_yy_create_buffer (FILE *file,int size ); +void spec_yy_delete_buffer (YY_BUFFER_STATE b ); +void spec_yy_flush_buffer (YY_BUFFER_STATE b ); +void spec_yypush_buffer_state (YY_BUFFER_STATE new_buffer ); +void spec_yypop_buffer_state (void ); + +static void spec_yyensure_buffer_stack (void ); +static void spec_yy_load_buffer_state (void ); +static void spec_yy_init_buffer (YY_BUFFER_STATE b,FILE *file ); + +#define YY_FLUSH_BUFFER spec_yy_flush_buffer(YY_CURRENT_BUFFER ) + +YY_BUFFER_STATE spec_yy_scan_buffer (char *base,yy_size_t size ); +YY_BUFFER_STATE spec_yy_scan_string (yyconst char *yy_str ); +YY_BUFFER_STATE spec_yy_scan_bytes (yyconst char *bytes,int len ); + +void *spec_yyalloc (yy_size_t ); +void *spec_yyrealloc (void *,yy_size_t ); +void spec_yyfree (void * ); + +#define yy_new_buffer spec_yy_create_buffer + +#define yy_set_interactive(is_interactive) \ + { \ + if ( ! YY_CURRENT_BUFFER ){ \ + spec_yyensure_buffer_stack (); \ + YY_CURRENT_BUFFER_LVALUE = \ + spec_yy_create_buffer(spec_yyin,YY_BUF_SIZE ); \ + } \ + YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \ + } + +#define yy_set_bol(at_bol) \ + { \ + if ( ! YY_CURRENT_BUFFER ){\ + spec_yyensure_buffer_stack (); \ + YY_CURRENT_BUFFER_LVALUE = \ + spec_yy_create_buffer(spec_yyin,YY_BUF_SIZE ); \ + } \ + YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \ + } + +#define YY_AT_BOL() (YY_CURRENT_BUFFER_LVALUE->yy_at_bol) + +/* Begin user sect3 */ + +#define spec_yywrap(n) 1 +#define YY_SKIP_YYWRAP + +typedef unsigned char YY_CHAR; + +FILE *spec_yyin = (FILE *) 0, *spec_yyout = (FILE *) 0; + +typedef int yy_state_type; + +extern int spec_yylineno; + +int spec_yylineno = 1; + +extern char *spec_yytext; +#define yytext_ptr spec_yytext + +static yy_state_type yy_get_previous_state (void ); +static yy_state_type yy_try_NUL_trans (yy_state_type current_state ); +static int yy_get_next_buffer (void ); +static void yy_fatal_error (yyconst char msg[] ); + +/* Done after the current pattern has been matched and before the + * corresponding action - sets up spec_yytext. + */ +#define YY_DO_BEFORE_ACTION \ + (yytext_ptr) = yy_bp; \ + spec_yyleng = (size_t) (yy_cp - yy_bp); \ + (yy_hold_char) = *yy_cp; \ + *yy_cp = '\0'; \ + (yy_c_buf_p) = yy_cp; + +#define YY_NUM_RULES 18 +#define YY_END_OF_BUFFER 19 +/* This struct is not used in this scanner, + but its presence is necessary. */ +struct yy_trans_info + { + flex_int32_t yy_verify; + flex_int32_t yy_nxt; + }; +static yyconst flex_int16_t yy_accept[58] = + { 0, + 0, 0, 0, 0, 0, 0, 19, 17, 8, 6, + 9, 7, 17, 17, 17, 13, 15, 15, 16, 14, + 11, 12, 10, 7, 0, 0, 0, 0, 13, 0, + 14, 0, 0, 0, 0, 0, 0, 0, 0, 4, + 0, 0, 0, 3, 0, 0, 0, 0, 0, 2, + 0, 0, 5, 0, 0, 1, 0 + } ; + +static yyconst flex_int32_t yy_ec[256] = + { 0, + 1, 1, 1, 1, 1, 1, 1, 1, 2, 3, + 1, 2, 4, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 2, 1, 5, 6, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 7, 1, 1, 8, + + 9, 1, 1, 1, 10, 1, 1, 1, 11, 12, + 13, 14, 1, 15, 16, 17, 18, 1, 19, 1, + 1, 1, 20, 1, 21, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1 + } ; + +static yyconst flex_int32_t yy_meta[22] = + { 0, + 1, 1, 2, 2, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1 + } ; + +static yyconst flex_int16_t yy_base[61] = + { 0, + 0, 0, 20, 40, 22, 23, 78, 79, 79, 79, + 79, 0, 68, 20, 67, 28, 79, 29, 79, 79, + 79, 79, 79, 0, 60, 18, 65, 66, 34, 43, + 79, 61, 55, 52, 55, 48, 44, 50, 45, 79, + 50, 40, 43, 79, 42, 47, 41, 33, 34, 79, + 37, 38, 79, 33, 28, 79, 79, 64, 66, 38 + } ; + +static yyconst flex_int16_t yy_def[61] = + { 0, + 57, 1, 58, 58, 59, 59, 57, 57, 57, 57, + 57, 60, 57, 57, 57, 57, 57, 57, 57, 57, + 57, 57, 57, 60, 57, 57, 57, 57, 57, 57, + 57, 57, 57, 57, 57, 57, 57, 57, 57, 57, + 57, 57, 57, 57, 57, 57, 57, 57, 57, 57, + 57, 57, 57, 57, 57, 57, 0, 57, 57, 57 + } ; + +static yyconst flex_int16_t yy_nxt[101] = + { 0, + 8, 9, 10, 9, 11, 12, 8, 8, 8, 8, + 8, 8, 8, 13, 8, 14, 15, 8, 8, 16, + 8, 18, 19, 18, 22, 22, 23, 23, 26, 29, + 30, 29, 30, 33, 34, 29, 27, 29, 24, 56, + 20, 18, 19, 18, 30, 55, 30, 54, 53, 31, + 52, 51, 50, 49, 48, 47, 46, 45, 44, 43, + 20, 42, 41, 31, 17, 17, 21, 21, 40, 39, + 38, 37, 36, 35, 32, 28, 25, 57, 7, 57, + 57, 57, 57, 57, 57, 57, 57, 57, 57, 57, + 57, 57, 57, 57, 57, 57, 57, 57, 57, 57 + + } ; + +static yyconst flex_int16_t yy_chk[101] = + { 0, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 3, 3, 3, 5, 6, 5, 6, 14, 16, + 18, 16, 18, 26, 26, 29, 14, 29, 60, 55, + 3, 4, 4, 4, 30, 54, 30, 52, 51, 18, + 49, 48, 47, 46, 45, 43, 42, 41, 39, 38, + 4, 37, 36, 30, 58, 58, 59, 59, 35, 34, + 33, 32, 28, 27, 25, 15, 13, 7, 57, 57, + 57, 57, 57, 57, 57, 57, 57, 57, 57, 57, + 57, 57, 57, 57, 57, 57, 57, 57, 57, 57 + + } ; + +static yy_state_type yy_last_accepting_state; +static char *yy_last_accepting_cpos; + +extern int spec_yy_flex_debug; +int spec_yy_flex_debug = 0; + +/* The intent behind this definition is that it'll catch + * any uses of REJECT which flex missed. + */ +#define REJECT reject_used_but_not_detected +#define yymore() yymore_used_but_not_detected +#define YY_MORE_ADJ 0 +#define YY_RESTORE_YY_MORE_OFFSET +char *spec_yytext; +#line 1 "specscanner.l" +#line 2 "specscanner.l" +/*------------------------------------------------------------------------- + * + * specscanner.l + * a lexical scanner for an isolation test specification + * + * Portions Copyright (c) 1996-2012, PostgreSQL Global Development Group + * Portions Copyright (c) 1994, Regents of the University of California + * + *------------------------------------------------------------------------- + */ + +static int yyline = 1; /* line number for error reporting */ + +static char litbuf[1024]; +static int litbufpos = 0; + +static void addlitchar(char c); + +#define YY_NO_INPUT 1 + + +#line 540 "specscanner.c" + +#define INITIAL 0 +#define sql 1 +#define qstr 2 + +#ifndef YY_NO_UNISTD_H +/* Special case for "unistd.h", since it is non-ANSI. We include it way + * down here because we want the user's section 1 to have been scanned first. + * The user has a chance to override it with an option. + */ +#include +#endif + +#ifndef YY_EXTRA_TYPE +#define YY_EXTRA_TYPE void * +#endif + +static int yy_init_globals (void ); + +/* Accessor methods to globals. + These are made visible to non-reentrant scanners for convenience. */ + +int spec_yylex_destroy (void ); + +int spec_yyget_debug (void ); + +void spec_yyset_debug (int debug_flag ); + +YY_EXTRA_TYPE spec_yyget_extra (void ); + +void spec_yyset_extra (YY_EXTRA_TYPE user_defined ); + +FILE *spec_yyget_in (void ); + +void spec_yyset_in (FILE * in_str ); + +FILE *spec_yyget_out (void ); + +void spec_yyset_out (FILE * out_str ); + +int spec_yyget_leng (void ); + +char *spec_yyget_text (void ); + +int spec_yyget_lineno (void ); + +void spec_yyset_lineno (int line_number ); + +/* Macros after this point can all be overridden by user definitions in + * section 1. + */ + +#ifndef YY_SKIP_YYWRAP +#ifdef __cplusplus +extern "C" int spec_yywrap (void ); +#else +extern int spec_yywrap (void ); +#endif +#endif + +#ifndef yytext_ptr +static void yy_flex_strncpy (char *,yyconst char *,int ); +#endif + +#ifdef YY_NEED_STRLEN +static int yy_flex_strlen (yyconst char * ); +#endif + +#ifndef YY_NO_INPUT + +#ifdef __cplusplus +static int yyinput (void ); +#else +static int input (void ); +#endif + +#endif + +/* Amount of stuff to slurp up with each read. */ +#ifndef YY_READ_BUF_SIZE +#ifdef __ia64__ +/* On IA-64, the buffer size is 16k, not 8k */ +#define YY_READ_BUF_SIZE 16384 +#else +#define YY_READ_BUF_SIZE 8192 +#endif /* __ia64__ */ +#endif + +/* Copy whatever the last rule matched to the standard output. */ +#ifndef ECHO +/* This used to be an fputs(), but since the string might contain NUL's, + * we now use fwrite(). + */ +#define ECHO do { if (fwrite( spec_yytext, spec_yyleng, 1, spec_yyout )) {} } while (0) +#endif + +/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL, + * is returned in "result". + */ +#ifndef YY_INPUT +#define YY_INPUT(buf,result,max_size) \ + if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \ + { \ + int c = '*'; \ + size_t n; \ + for ( n = 0; n < max_size && \ + (c = getc( spec_yyin )) != EOF && c != '\n'; ++n ) \ + buf[n] = (char) c; \ + if ( c == '\n' ) \ + buf[n++] = (char) c; \ + if ( c == EOF && ferror( spec_yyin ) ) \ + YY_FATAL_ERROR( "input in flex scanner failed" ); \ + result = n; \ + } \ + else \ + { \ + errno=0; \ + while ( (result = fread(buf, 1, max_size, spec_yyin))==0 && ferror(spec_yyin)) \ + { \ + if( errno != EINTR) \ + { \ + YY_FATAL_ERROR( "input in flex scanner failed" ); \ + break; \ + } \ + errno=0; \ + clearerr(spec_yyin); \ + } \ + }\ +\ + +#endif + +/* No semi-colon after return; correct usage is to write "yyterminate();" - + * we don't want an extra ';' after the "return" because that will cause + * some compilers to complain about unreachable statements. + */ +#ifndef yyterminate +#define yyterminate() return YY_NULL +#endif + +/* Number of entries by which start-condition stack grows. */ +#ifndef YY_START_STACK_INCR +#define YY_START_STACK_INCR 25 +#endif + +/* Report a fatal error. */ +#ifndef YY_FATAL_ERROR +#define YY_FATAL_ERROR(msg) yy_fatal_error( msg ) +#endif + +/* end tables serialization structures and prototypes */ + +/* Default declaration of generated scanner - a define so the user can + * easily add parameters. + */ +#ifndef YY_DECL +#define YY_DECL_IS_OURS 1 + +extern int spec_yylex (void); + +#define YY_DECL int spec_yylex (void) +#endif /* !YY_DECL */ + +/* Code executed at the beginning of each rule, after spec_yytext and spec_yyleng + * have been set up. + */ +#ifndef YY_USER_ACTION +#define YY_USER_ACTION +#endif + +/* Code executed at the end of each rule. */ +#ifndef YY_BREAK +#define YY_BREAK break; +#endif + +#define YY_RULE_SETUP \ + YY_USER_ACTION + +/** The main scanner function which does all the work. + */ +YY_DECL +{ + register yy_state_type yy_current_state; + register char *yy_cp, *yy_bp; + register int yy_act; + +#line 40 "specscanner.l" + + +#line 730 "specscanner.c" + + if ( !(yy_init) ) + { + (yy_init) = 1; + +#ifdef YY_USER_INIT + YY_USER_INIT; +#endif + + if ( ! (yy_start) ) + (yy_start) = 1; /* first start state */ + + if ( ! spec_yyin ) + spec_yyin = stdin; + + if ( ! spec_yyout ) + spec_yyout = stdout; + + if ( ! YY_CURRENT_BUFFER ) { + spec_yyensure_buffer_stack (); + YY_CURRENT_BUFFER_LVALUE = + spec_yy_create_buffer(spec_yyin,YY_BUF_SIZE ); + } + + spec_yy_load_buffer_state( ); + } + + while ( 1 ) /* loops until end-of-file is reached */ + { + yy_cp = (yy_c_buf_p); + + /* Support of spec_yytext. */ + *yy_cp = (yy_hold_char); + + /* yy_bp points to the position in yy_ch_buf of the start of + * the current run. + */ + yy_bp = yy_cp; + + yy_current_state = (yy_start); +yy_match: + do + { + register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)]; + if ( yy_accept[yy_current_state] ) + { + (yy_last_accepting_state) = yy_current_state; + (yy_last_accepting_cpos) = yy_cp; + } + while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) + { + yy_current_state = (int) yy_def[yy_current_state]; + if ( yy_current_state >= 58 ) + yy_c = yy_meta[(unsigned int) yy_c]; + } + yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; + ++yy_cp; + } + while ( yy_current_state != 57 ); + yy_cp = (yy_last_accepting_cpos); + yy_current_state = (yy_last_accepting_state); + +yy_find_action: + yy_act = yy_accept[yy_current_state]; + + YY_DO_BEFORE_ACTION; + +do_action: /* This label is used only to access EOF actions. */ + + switch ( yy_act ) + { /* beginning of action switch */ + case 0: /* must back up */ + /* undo the effects of YY_DO_BEFORE_ACTION */ + *yy_cp = (yy_hold_char); + yy_cp = (yy_last_accepting_cpos); + yy_current_state = (yy_last_accepting_state); + goto yy_find_action; + +case 1: +YY_RULE_SETUP +#line 42 "specscanner.l" +{ return(PERMUTATION); } + YY_BREAK +case 2: +YY_RULE_SETUP +#line 43 "specscanner.l" +{ return(SESSION); } + YY_BREAK +case 3: +YY_RULE_SETUP +#line 44 "specscanner.l" +{ return(SETUP); } + YY_BREAK +case 4: +YY_RULE_SETUP +#line 45 "specscanner.l" +{ return(STEP); } + YY_BREAK +case 5: +YY_RULE_SETUP +#line 46 "specscanner.l" +{ return(TEARDOWN); } + YY_BREAK +case 6: +/* rule 6 can match eol */ +YY_RULE_SETUP +#line 48 "specscanner.l" +{ yyline++; } + YY_BREAK +case 7: +YY_RULE_SETUP +#line 49 "specscanner.l" +{ /* ignore */ } + YY_BREAK +case 8: +YY_RULE_SETUP +#line 50 "specscanner.l" +{ /* ignore */ } + YY_BREAK +/* Quoted strings: "foo" */ +case 9: +YY_RULE_SETUP +#line 53 "specscanner.l" +{ + litbufpos = 0; + BEGIN(qstr); + } + YY_BREAK +case 10: +YY_RULE_SETUP +#line 57 "specscanner.l" +{ + litbuf[litbufpos] = '\0'; + yylval.str = strdup(litbuf); + BEGIN(INITIAL); + return(string); + } + YY_BREAK +case 11: +YY_RULE_SETUP +#line 63 "specscanner.l" +{ addlitchar(spec_yytext[0]); } + YY_BREAK +case 12: +/* rule 12 can match eol */ +YY_RULE_SETUP +#line 64 "specscanner.l" +{ yyerror("unexpected newline in quoted string"); } + YY_BREAK +case YY_STATE_EOF(qstr): +#line 65 "specscanner.l" +{ yyerror("unterminated quoted string"); } + YY_BREAK +/* SQL blocks: { UPDATE ... } */ +case 13: +YY_RULE_SETUP +#line 68 "specscanner.l" +{ + + litbufpos = 0; + BEGIN(sql); + } + YY_BREAK +case 14: +YY_RULE_SETUP +#line 73 "specscanner.l" +{ + litbuf[litbufpos] = '\0'; + yylval.str = strdup(litbuf); + BEGIN(INITIAL); + return(sqlblock); + } + YY_BREAK +case 15: +YY_RULE_SETUP +#line 79 "specscanner.l" +{ + addlitchar(spec_yytext[0]); + } + YY_BREAK +case 16: +/* rule 16 can match eol */ +YY_RULE_SETUP +#line 82 "specscanner.l" +{ + yyline++; + addlitchar(spec_yytext[0]); + } + YY_BREAK +case YY_STATE_EOF(sql): +#line 86 "specscanner.l" +{ + yyerror("unterminated sql block"); + } + YY_BREAK +case 17: +YY_RULE_SETUP +#line 90 "specscanner.l" +{ + fprintf(stderr, "syntax error at line %d: unexpected character \"%s\"\n", yyline, spec_yytext); + exit(1); + } + YY_BREAK +case 18: +YY_RULE_SETUP +#line 94 "specscanner.l" +YY_FATAL_ERROR( "flex scanner jammed" ); + YY_BREAK +#line 939 "specscanner.c" +case YY_STATE_EOF(INITIAL): + yyterminate(); + + case YY_END_OF_BUFFER: + { + /* Amount of text matched not including the EOB char. */ + int yy_amount_of_matched_text = (int) (yy_cp - (yytext_ptr)) - 1; + + /* Undo the effects of YY_DO_BEFORE_ACTION. */ + *yy_cp = (yy_hold_char); + YY_RESTORE_YY_MORE_OFFSET + + if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_NEW ) + { + /* We're scanning a new file or input source. It's + * possible that this happened because the user + * just pointed spec_yyin at a new source and called + * spec_yylex(). If so, then we have to assure + * consistency between YY_CURRENT_BUFFER and our + * globals. Here is the right place to do so, because + * this is the first action (other than possibly a + * back-up) that will match for the new input source. + */ + (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars; + YY_CURRENT_BUFFER_LVALUE->yy_input_file = spec_yyin; + YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = YY_BUFFER_NORMAL; + } + + /* Note that here we test for yy_c_buf_p "<=" to the position + * of the first EOB in the buffer, since yy_c_buf_p will + * already have been incremented past the NUL character + * (since all states make transitions on EOB to the + * end-of-buffer state). Contrast this with the test + * in input(). + */ + if ( (yy_c_buf_p) <= &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] ) + { /* This was really a NUL. */ + yy_state_type yy_next_state; + + (yy_c_buf_p) = (yytext_ptr) + yy_amount_of_matched_text; + + yy_current_state = yy_get_previous_state( ); + + /* Okay, we're now positioned to make the NUL + * transition. We couldn't have + * yy_get_previous_state() go ahead and do it + * for us because it doesn't know how to deal + * with the possibility of jamming (and we don't + * want to build jamming into it because then it + * will run more slowly). + */ + + yy_next_state = yy_try_NUL_trans( yy_current_state ); + + yy_bp = (yytext_ptr) + YY_MORE_ADJ; + + if ( yy_next_state ) + { + /* Consume the NUL. */ + yy_cp = ++(yy_c_buf_p); + yy_current_state = yy_next_state; + goto yy_match; + } + + else + { + yy_cp = (yy_last_accepting_cpos); + yy_current_state = (yy_last_accepting_state); + goto yy_find_action; + } + } + + else switch ( yy_get_next_buffer( ) ) + { + case EOB_ACT_END_OF_FILE: + { + (yy_did_buffer_switch_on_eof) = 0; + + if ( spec_yywrap( ) ) + { + /* Note: because we've taken care in + * yy_get_next_buffer() to have set up + * spec_yytext, we can now set up + * yy_c_buf_p so that if some total + * hoser (like flex itself) wants to + * call the scanner after we return the + * YY_NULL, it'll still work - another + * YY_NULL will get returned. + */ + (yy_c_buf_p) = (yytext_ptr) + YY_MORE_ADJ; + + yy_act = YY_STATE_EOF(YY_START); + goto do_action; + } + + else + { + if ( ! (yy_did_buffer_switch_on_eof) ) + YY_NEW_FILE; + } + break; + } + + case EOB_ACT_CONTINUE_SCAN: + (yy_c_buf_p) = + (yytext_ptr) + yy_amount_of_matched_text; + + yy_current_state = yy_get_previous_state( ); + + yy_cp = (yy_c_buf_p); + yy_bp = (yytext_ptr) + YY_MORE_ADJ; + goto yy_match; + + case EOB_ACT_LAST_MATCH: + (yy_c_buf_p) = + &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)]; + + yy_current_state = yy_get_previous_state( ); + + yy_cp = (yy_c_buf_p); + yy_bp = (yytext_ptr) + YY_MORE_ADJ; + goto yy_find_action; + } + break; + } + + default: + YY_FATAL_ERROR( + "fatal flex scanner internal error--no action found" ); + } /* end of action switch */ + } /* end of scanning one token */ +} /* end of spec_yylex */ + +/* yy_get_next_buffer - try to read in a new buffer + * + * Returns a code representing an action: + * EOB_ACT_LAST_MATCH - + * EOB_ACT_CONTINUE_SCAN - continue scanning from current position + * EOB_ACT_END_OF_FILE - end of file + */ +static int yy_get_next_buffer (void) +{ + register char *dest = YY_CURRENT_BUFFER_LVALUE->yy_ch_buf; + register char *source = (yytext_ptr); + register int number_to_move, i; + int ret_val; + + if ( (yy_c_buf_p) > &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] ) + YY_FATAL_ERROR( + "fatal flex scanner internal error--end of buffer missed" ); + + if ( YY_CURRENT_BUFFER_LVALUE->yy_fill_buffer == 0 ) + { /* Don't try to fill the buffer, so this is an EOF. */ + if ( (yy_c_buf_p) - (yytext_ptr) - YY_MORE_ADJ == 1 ) + { + /* We matched a single character, the EOB, so + * treat this as a final EOF. + */ + return EOB_ACT_END_OF_FILE; + } + + else + { + /* We matched some text prior to the EOB, first + * process it. + */ + return EOB_ACT_LAST_MATCH; + } + } + + /* Try to read more data. */ + + /* First move last chars to start of buffer. */ + number_to_move = (int) ((yy_c_buf_p) - (yytext_ptr)) - 1; + + for ( i = 0; i < number_to_move; ++i ) + *(dest++) = *(source++); + + if ( YY_CURRENT_BUFFER_LVALUE->yy_buffer_status == YY_BUFFER_EOF_PENDING ) + /* don't do the read, it's not guaranteed to return an EOF, + * just force an EOF + */ + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars) = 0; + + else + { + int num_to_read = + YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1; + + while ( num_to_read <= 0 ) + { /* Not enough room in the buffer - grow it. */ + + /* just a shorter name for the current buffer */ + YY_BUFFER_STATE b = YY_CURRENT_BUFFER; + + int yy_c_buf_p_offset = + (int) ((yy_c_buf_p) - b->yy_ch_buf); + + if ( b->yy_is_our_buffer ) + { + int new_size = b->yy_buf_size * 2; + + if ( new_size <= 0 ) + b->yy_buf_size += b->yy_buf_size / 8; + else + b->yy_buf_size *= 2; + + b->yy_ch_buf = (char *) + /* Include room in for 2 EOB chars. */ + spec_yyrealloc((void *) b->yy_ch_buf,b->yy_buf_size + 2 ); + } + else + /* Can't grow it, we don't own it. */ + b->yy_ch_buf = 0; + + if ( ! b->yy_ch_buf ) + YY_FATAL_ERROR( + "fatal error - scanner input buffer overflow" ); + + (yy_c_buf_p) = &b->yy_ch_buf[yy_c_buf_p_offset]; + + num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size - + number_to_move - 1; + + } + + if ( num_to_read > YY_READ_BUF_SIZE ) + num_to_read = YY_READ_BUF_SIZE; + + /* Read in more data. */ + YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]), + (yy_n_chars), (size_t) num_to_read ); + + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); + } + + if ( (yy_n_chars) == 0 ) + { + if ( number_to_move == YY_MORE_ADJ ) + { + ret_val = EOB_ACT_END_OF_FILE; + spec_yyrestart(spec_yyin ); + } + + else + { + ret_val = EOB_ACT_LAST_MATCH; + YY_CURRENT_BUFFER_LVALUE->yy_buffer_status = + YY_BUFFER_EOF_PENDING; + } + } + + else + ret_val = EOB_ACT_CONTINUE_SCAN; + + if ((yy_size_t) ((yy_n_chars) + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) { + /* Extend the array by 50%, plus the number we really need. */ + yy_size_t new_size = (yy_n_chars) + number_to_move + ((yy_n_chars) >> 1); + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) spec_yyrealloc((void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,new_size ); + if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf ) + YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" ); + } + + (yy_n_chars) += number_to_move; + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] = YY_END_OF_BUFFER_CHAR; + YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars) + 1] = YY_END_OF_BUFFER_CHAR; + + (yytext_ptr) = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[0]; + + return ret_val; +} + +/* yy_get_previous_state - get the state just before the EOB char was reached */ + + static yy_state_type yy_get_previous_state (void) +{ + register yy_state_type yy_current_state; + register char *yy_cp; + + yy_current_state = (yy_start); + + for ( yy_cp = (yytext_ptr) + YY_MORE_ADJ; yy_cp < (yy_c_buf_p); ++yy_cp ) + { + register YY_CHAR yy_c = (*yy_cp ? yy_ec[YY_SC_TO_UI(*yy_cp)] : 1); + if ( yy_accept[yy_current_state] ) + { + (yy_last_accepting_state) = yy_current_state; + (yy_last_accepting_cpos) = yy_cp; + } + while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) + { + yy_current_state = (int) yy_def[yy_current_state]; + if ( yy_current_state >= 58 ) + yy_c = yy_meta[(unsigned int) yy_c]; + } + yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; + } + + return yy_current_state; +} + +/* yy_try_NUL_trans - try to make a transition on the NUL character + * + * synopsis + * next_state = yy_try_NUL_trans( current_state ); + */ + static yy_state_type yy_try_NUL_trans (yy_state_type yy_current_state ) +{ + register int yy_is_jam; + register char *yy_cp = (yy_c_buf_p); + + register YY_CHAR yy_c = 1; + if ( yy_accept[yy_current_state] ) + { + (yy_last_accepting_state) = yy_current_state; + (yy_last_accepting_cpos) = yy_cp; + } + while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) + { + yy_current_state = (int) yy_def[yy_current_state]; + if ( yy_current_state >= 58 ) + yy_c = yy_meta[(unsigned int) yy_c]; + } + yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; + yy_is_jam = (yy_current_state == 57); + + return yy_is_jam ? 0 : yy_current_state; +} + +#ifndef YY_NO_INPUT +#ifdef __cplusplus + static int yyinput (void) +#else + static int input (void) +#endif + +{ + int c; + + *(yy_c_buf_p) = (yy_hold_char); + + if ( *(yy_c_buf_p) == YY_END_OF_BUFFER_CHAR ) + { + /* yy_c_buf_p now points to the character we want to return. + * If this occurs *before* the EOB characters, then it's a + * valid NUL; if not, then we've hit the end of the buffer. + */ + if ( (yy_c_buf_p) < &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[(yy_n_chars)] ) + /* This was really a NUL. */ + *(yy_c_buf_p) = '\0'; + + else + { /* need more input */ + int offset = (yy_c_buf_p) - (yytext_ptr); + ++(yy_c_buf_p); + + switch ( yy_get_next_buffer( ) ) + { + case EOB_ACT_LAST_MATCH: + /* This happens because yy_g_n_b() + * sees that we've accumulated a + * token and flags that we need to + * try matching the token before + * proceeding. But for input(), + * there's no matching to consider. + * So convert the EOB_ACT_LAST_MATCH + * to EOB_ACT_END_OF_FILE. + */ + + /* Reset buffer status. */ + spec_yyrestart(spec_yyin ); + + /*FALLTHROUGH*/ + + case EOB_ACT_END_OF_FILE: + { + if ( spec_yywrap( ) ) + return EOF; + + if ( ! (yy_did_buffer_switch_on_eof) ) + YY_NEW_FILE; +#ifdef __cplusplus + return yyinput(); +#else + return input(); +#endif + } + + case EOB_ACT_CONTINUE_SCAN: + (yy_c_buf_p) = (yytext_ptr) + offset; + break; + } + } + } + + c = *(unsigned char *) (yy_c_buf_p); /* cast for 8-bit char's */ + *(yy_c_buf_p) = '\0'; /* preserve spec_yytext */ + (yy_hold_char) = *++(yy_c_buf_p); + + return c; +} +#endif /* ifndef YY_NO_INPUT */ + +/** Immediately switch to a different input stream. + * @param input_file A readable stream. + * + * @note This function does not reset the start condition to @c INITIAL . + */ + void spec_yyrestart (FILE * input_file ) +{ + + if ( ! YY_CURRENT_BUFFER ){ + spec_yyensure_buffer_stack (); + YY_CURRENT_BUFFER_LVALUE = + spec_yy_create_buffer(spec_yyin,YY_BUF_SIZE ); + } + + spec_yy_init_buffer(YY_CURRENT_BUFFER,input_file ); + spec_yy_load_buffer_state( ); +} + +/** Switch to a different input buffer. + * @param new_buffer The new input buffer. + * + */ + void spec_yy_switch_to_buffer (YY_BUFFER_STATE new_buffer ) +{ + + /* TODO. We should be able to replace this entire function body + * with + * spec_yypop_buffer_state(); + * spec_yypush_buffer_state(new_buffer); + */ + spec_yyensure_buffer_stack (); + if ( YY_CURRENT_BUFFER == new_buffer ) + return; + + if ( YY_CURRENT_BUFFER ) + { + /* Flush out information for old buffer. */ + *(yy_c_buf_p) = (yy_hold_char); + YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p); + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); + } + + YY_CURRENT_BUFFER_LVALUE = new_buffer; + spec_yy_load_buffer_state( ); + + /* We don't actually know whether we did this switch during + * EOF (spec_yywrap()) processing, but the only time this flag + * is looked at is after spec_yywrap() is called, so it's safe + * to go ahead and always set it. + */ + (yy_did_buffer_switch_on_eof) = 1; +} + +static void spec_yy_load_buffer_state (void) +{ + (yy_n_chars) = YY_CURRENT_BUFFER_LVALUE->yy_n_chars; + (yytext_ptr) = (yy_c_buf_p) = YY_CURRENT_BUFFER_LVALUE->yy_buf_pos; + spec_yyin = YY_CURRENT_BUFFER_LVALUE->yy_input_file; + (yy_hold_char) = *(yy_c_buf_p); +} + +/** Allocate and initialize an input buffer state. + * @param file A readable stream. + * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE. + * + * @return the allocated buffer state. + */ + YY_BUFFER_STATE spec_yy_create_buffer (FILE * file, int size ) +{ + YY_BUFFER_STATE b; + + b = (YY_BUFFER_STATE) spec_yyalloc(sizeof( struct yy_buffer_state ) ); + if ( ! b ) + YY_FATAL_ERROR( "out of dynamic memory in spec_yy_create_buffer()" ); + + b->yy_buf_size = size; + + /* yy_ch_buf has to be 2 characters longer than the size given because + * we need to put in 2 end-of-buffer characters. + */ + b->yy_ch_buf = (char *) spec_yyalloc(b->yy_buf_size + 2 ); + if ( ! b->yy_ch_buf ) + YY_FATAL_ERROR( "out of dynamic memory in spec_yy_create_buffer()" ); + + b->yy_is_our_buffer = 1; + + spec_yy_init_buffer(b,file ); + + return b; +} + +/** Destroy the buffer. + * @param b a buffer created with spec_yy_create_buffer() + * + */ + void spec_yy_delete_buffer (YY_BUFFER_STATE b ) +{ + + if ( ! b ) + return; + + if ( b == YY_CURRENT_BUFFER ) /* Not sure if we should pop here. */ + YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0; + + if ( b->yy_is_our_buffer ) + spec_yyfree((void *) b->yy_ch_buf ); + + spec_yyfree((void *) b ); +} + +/* Initializes or reinitializes a buffer. + * This function is sometimes called more than once on the same buffer, + * such as during a spec_yyrestart() or at EOF. + */ + static void spec_yy_init_buffer (YY_BUFFER_STATE b, FILE * file ) + +{ + int oerrno = errno; + + spec_yy_flush_buffer(b ); + + b->yy_input_file = file; + b->yy_fill_buffer = 1; + + /* If b is the current buffer, then spec_yy_init_buffer was _probably_ + * called from spec_yyrestart() or through yy_get_next_buffer. + * In that case, we don't want to reset the lineno or column. + */ + if (b != YY_CURRENT_BUFFER){ + b->yy_bs_lineno = 1; + b->yy_bs_column = 0; + } + + b->yy_is_interactive = 0; + + errno = oerrno; +} + +/** Discard all buffered characters. On the next scan, YY_INPUT will be called. + * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER. + * + */ + void spec_yy_flush_buffer (YY_BUFFER_STATE b ) +{ + if ( ! b ) + return; + + b->yy_n_chars = 0; + + /* We always need two end-of-buffer characters. The first causes + * a transition to the end-of-buffer state. The second causes + * a jam in that state. + */ + b->yy_ch_buf[0] = YY_END_OF_BUFFER_CHAR; + b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR; + + b->yy_buf_pos = &b->yy_ch_buf[0]; + + b->yy_at_bol = 1; + b->yy_buffer_status = YY_BUFFER_NEW; + + if ( b == YY_CURRENT_BUFFER ) + spec_yy_load_buffer_state( ); +} + +/** Pushes the new state onto the stack. The new state becomes + * the current state. This function will allocate the stack + * if necessary. + * @param new_buffer The new state. + * + */ +void spec_yypush_buffer_state (YY_BUFFER_STATE new_buffer ) +{ + if (new_buffer == NULL) + return; + + spec_yyensure_buffer_stack(); + + /* This block is copied from spec_yy_switch_to_buffer. */ + if ( YY_CURRENT_BUFFER ) + { + /* Flush out information for old buffer. */ + *(yy_c_buf_p) = (yy_hold_char); + YY_CURRENT_BUFFER_LVALUE->yy_buf_pos = (yy_c_buf_p); + YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); + } + + /* Only push if top exists. Otherwise, replace top. */ + if (YY_CURRENT_BUFFER) + (yy_buffer_stack_top)++; + YY_CURRENT_BUFFER_LVALUE = new_buffer; + + /* copied from spec_yy_switch_to_buffer. */ + spec_yy_load_buffer_state( ); + (yy_did_buffer_switch_on_eof) = 1; +} + +/** Removes and deletes the top of the stack, if present. + * The next element becomes the new top. + * + */ +void spec_yypop_buffer_state (void) +{ + if (!YY_CURRENT_BUFFER) + return; + + spec_yy_delete_buffer(YY_CURRENT_BUFFER ); + YY_CURRENT_BUFFER_LVALUE = NULL; + if ((yy_buffer_stack_top) > 0) + --(yy_buffer_stack_top); + + if (YY_CURRENT_BUFFER) { + spec_yy_load_buffer_state( ); + (yy_did_buffer_switch_on_eof) = 1; + } +} + +/* Allocates the stack if it does not exist. + * Guarantees space for at least one push. + */ +static void spec_yyensure_buffer_stack (void) +{ + int num_to_alloc; + + if (!(yy_buffer_stack)) { + + /* First allocation is just for 2 elements, since we don't know if this + * scanner will even need a stack. We use 2 instead of 1 to avoid an + * immediate realloc on the next call. + */ + num_to_alloc = 1; + (yy_buffer_stack) = (struct yy_buffer_state**)spec_yyalloc + (num_to_alloc * sizeof(struct yy_buffer_state*) + ); + if ( ! (yy_buffer_stack) ) + YY_FATAL_ERROR( "out of dynamic memory in spec_yyensure_buffer_stack()" ); + + memset((yy_buffer_stack), 0, num_to_alloc * sizeof(struct yy_buffer_state*)); + + (yy_buffer_stack_max) = num_to_alloc; + (yy_buffer_stack_top) = 0; + return; + } + + if ((yy_buffer_stack_top) >= ((yy_buffer_stack_max)) - 1){ + + /* Increase the buffer to prepare for a possible push. */ + int grow_size = 8 /* arbitrary grow size */; + + num_to_alloc = (yy_buffer_stack_max) + grow_size; + (yy_buffer_stack) = (struct yy_buffer_state**)spec_yyrealloc + ((yy_buffer_stack), + num_to_alloc * sizeof(struct yy_buffer_state*) + ); + if ( ! (yy_buffer_stack) ) + YY_FATAL_ERROR( "out of dynamic memory in spec_yyensure_buffer_stack()" ); + + /* zero only the new slots.*/ + memset((yy_buffer_stack) + (yy_buffer_stack_max), 0, grow_size * sizeof(struct yy_buffer_state*)); + (yy_buffer_stack_max) = num_to_alloc; + } +} + +/** Setup the input buffer state to scan directly from a user-specified character buffer. + * @param base the character buffer + * @param size the size in bytes of the character buffer + * + * @return the newly allocated buffer state object. + */ +YY_BUFFER_STATE spec_yy_scan_buffer (char * base, yy_size_t size ) +{ + YY_BUFFER_STATE b; + + if ( size < 2 || + base[size-2] != YY_END_OF_BUFFER_CHAR || + base[size-1] != YY_END_OF_BUFFER_CHAR ) + /* They forgot to leave room for the EOB's. */ + return 0; + + b = (YY_BUFFER_STATE) spec_yyalloc(sizeof( struct yy_buffer_state ) ); + if ( ! b ) + YY_FATAL_ERROR( "out of dynamic memory in spec_yy_scan_buffer()" ); + + b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */ + b->yy_buf_pos = b->yy_ch_buf = base; + b->yy_is_our_buffer = 0; + b->yy_input_file = 0; + b->yy_n_chars = b->yy_buf_size; + b->yy_is_interactive = 0; + b->yy_at_bol = 1; + b->yy_fill_buffer = 0; + b->yy_buffer_status = YY_BUFFER_NEW; + + spec_yy_switch_to_buffer(b ); + + return b; +} + +/** Setup the input buffer state to scan a string. The next call to spec_yylex() will + * scan from a @e copy of @a str. + * @param yystr a NUL-terminated string to scan + * + * @return the newly allocated buffer state object. + * @note If you want to scan bytes that may contain NUL values, then use + * spec_yy_scan_bytes() instead. + */ +YY_BUFFER_STATE spec_yy_scan_string (yyconst char * yystr ) +{ + + return spec_yy_scan_bytes(yystr,strlen(yystr) ); +} + +/** Setup the input buffer state to scan the given bytes. The next call to spec_yylex() will + * scan from a @e copy of @a bytes. + * @param yybytes the byte buffer to scan + * @param _yybytes_len the number of bytes in the buffer pointed to by @a bytes. + * + * @return the newly allocated buffer state object. + */ +YY_BUFFER_STATE spec_yy_scan_bytes (yyconst char * yybytes, int _yybytes_len ) +{ + YY_BUFFER_STATE b; + char *buf; + yy_size_t n; + int i; + + /* Get memory for full buffer, including space for trailing EOB's. */ + n = _yybytes_len + 2; + buf = (char *) spec_yyalloc(n ); + if ( ! buf ) + YY_FATAL_ERROR( "out of dynamic memory in spec_yy_scan_bytes()" ); + + for ( i = 0; i < _yybytes_len; ++i ) + buf[i] = yybytes[i]; + + buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR; + + b = spec_yy_scan_buffer(buf,n ); + if ( ! b ) + YY_FATAL_ERROR( "bad buffer in spec_yy_scan_bytes()" ); + + /* It's okay to grow etc. this buffer, and we should throw it + * away when we're done. + */ + b->yy_is_our_buffer = 1; + + return b; +} + +#ifndef YY_EXIT_FAILURE +#define YY_EXIT_FAILURE 2 +#endif + +static void yy_fatal_error (yyconst char* msg ) +{ + (void) fprintf( stderr, "%s\n", msg ); + exit( YY_EXIT_FAILURE ); +} + +/* Redefine yyless() so it works in section 3 code. */ + +#undef yyless +#define yyless(n) \ + do \ + { \ + /* Undo effects of setting up spec_yytext. */ \ + int yyless_macro_arg = (n); \ + YY_LESS_LINENO(yyless_macro_arg);\ + spec_yytext[spec_yyleng] = (yy_hold_char); \ + (yy_c_buf_p) = spec_yytext + yyless_macro_arg; \ + (yy_hold_char) = *(yy_c_buf_p); \ + *(yy_c_buf_p) = '\0'; \ + spec_yyleng = yyless_macro_arg; \ + } \ + while ( 0 ) + +/* Accessor methods (get/set functions) to struct members. */ + +/** Get the current line number. + * + */ +int spec_yyget_lineno (void) +{ + + return spec_yylineno; +} + +/** Get the input stream. + * + */ +FILE *spec_yyget_in (void) +{ + return spec_yyin; +} + +/** Get the output stream. + * + */ +FILE *spec_yyget_out (void) +{ + return spec_yyout; +} + +/** Get the length of the current token. + * + */ +int spec_yyget_leng (void) +{ + return spec_yyleng; +} + +/** Get the current token. + * + */ + +char *spec_yyget_text (void) +{ + return spec_yytext; +} + +/** Set the current line number. + * @param line_number + * + */ +void spec_yyset_lineno (int line_number ) +{ + + spec_yylineno = line_number; +} + +/** Set the input stream. This does not discard the current + * input buffer. + * @param in_str A readable stream. + * + * @see spec_yy_switch_to_buffer + */ +void spec_yyset_in (FILE * in_str ) +{ + spec_yyin = in_str ; +} + +void spec_yyset_out (FILE * out_str ) +{ + spec_yyout = out_str ; +} + +int spec_yyget_debug (void) +{ + return spec_yy_flex_debug; +} + +void spec_yyset_debug (int bdebug ) +{ + spec_yy_flex_debug = bdebug ; +} + +static int yy_init_globals (void) +{ + /* Initialization is the same as for the non-reentrant scanner. + * This function is called from spec_yylex_destroy(), so don't allocate here. + */ + + (yy_buffer_stack) = 0; + (yy_buffer_stack_top) = 0; + (yy_buffer_stack_max) = 0; + (yy_c_buf_p) = (char *) 0; + (yy_init) = 0; + (yy_start) = 0; + +/* Defined in main.c */ +#ifdef YY_STDINIT + spec_yyin = stdin; + spec_yyout = stdout; +#else + spec_yyin = (FILE *) 0; + spec_yyout = (FILE *) 0; +#endif + + /* For future reference: Set errno on error, since we are called by + * spec_yylex_init() + */ + return 0; +} + +/* spec_yylex_destroy is for both reentrant and non-reentrant scanners. */ +int spec_yylex_destroy (void) +{ + + /* Pop the buffer stack, destroying each element. */ + while(YY_CURRENT_BUFFER){ + spec_yy_delete_buffer(YY_CURRENT_BUFFER ); + YY_CURRENT_BUFFER_LVALUE = NULL; + spec_yypop_buffer_state(); + } + + /* Destroy the stack itself. */ + spec_yyfree((yy_buffer_stack) ); + (yy_buffer_stack) = NULL; + + /* Reset the globals. This is important in a non-reentrant scanner so the next time + * spec_yylex() is called, initialization will occur. */ + yy_init_globals( ); + + return 0; +} + +/* + * Internal utility routines. + */ + +#ifndef yytext_ptr +static void yy_flex_strncpy (char* s1, yyconst char * s2, int n ) +{ + register int i; + for ( i = 0; i < n; ++i ) + s1[i] = s2[i]; +} +#endif + +#ifdef YY_NEED_STRLEN +static int yy_flex_strlen (yyconst char * s ) +{ + register int n; + for ( n = 0; s[n]; ++n ) + ; + + return n; +} +#endif + +void *spec_yyalloc (yy_size_t size ) +{ + return (void *) malloc( size ); +} + +void *spec_yyrealloc (void * ptr, yy_size_t size ) +{ + /* The cast to (char *) in the following accommodates both + * implementations that use char* generic pointers, and those + * that use void* generic pointers. It works with the latter + * because both ANSI C and C++ allow castless assignment from + * any pointer type to void*, and deal with argument conversions + * as though doing an assignment. + */ + return (void *) realloc( (char *) ptr, size ); +} + +void spec_yyfree (void * ptr ) +{ + free( (char *) ptr ); /* see spec_yyrealloc() for (char *) cast */ +} + +#define YYTABLES_NAME "yytables" + +#line 94 "specscanner.l" + + + +static void +addlitchar(char c) +{ + if (litbufpos >= sizeof(litbuf) - 1) + { + fprintf(stderr, "SQL step too long\n"); + exit(1); + } + litbuf[litbufpos++] = c; +} + +void +yyerror(const char *message) +{ + fprintf(stderr, "%s at line %d\n", message, yyline); + exit(1); +} + diff --git a/src/test/regress/.gitignore b/src/test/regress/.gitignore deleted file mode 100644 index 7573addc9..000000000 --- a/src/test/regress/.gitignore +++ /dev/null @@ -1,7 +0,0 @@ -# Local binaries -/pg_regress - -# Generated subdirectories -/tmp_check/ -/results/ -/log/ diff --git a/src/test/regress/expected/.gitignore b/src/test/regress/expected/.gitignore deleted file mode 100644 index 93c56c85a..000000000 --- a/src/test/regress/expected/.gitignore +++ /dev/null @@ -1,9 +0,0 @@ -/constraints.out -/copy.out -/create_function_1.out -/create_function_2.out -/largeobject.out -/largeobject_1.out -/misc.out -/security_label.out -/tablespace.out diff --git a/src/test/regress/sql/.gitignore b/src/test/regress/sql/.gitignore deleted file mode 100644 index 46c811209..000000000 --- a/src/test/regress/sql/.gitignore +++ /dev/null @@ -1,8 +0,0 @@ -/constraints.sql -/copy.sql -/create_function_1.sql -/create_function_2.sql -/largeobject.sql -/misc.sql -/security_label.sql -/tablespace.sql diff --git a/src/timezone/.gitignore b/src/timezone/.gitignore deleted file mode 100644 index f844c9fcf..000000000 --- a/src/timezone/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/zic diff --git a/src/tools/entab/.gitignore b/src/tools/entab/.gitignore deleted file mode 100644 index 94db8434f..000000000 --- a/src/tools/entab/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/entab diff --git a/tablefunc.vcxproj b/tablefunc.vcxproj deleted file mode 100644 index a2abae21f..000000000 --- a/tablefunc.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {5E260CD7-4FF9-4BE5-B001-BFA05B39FAE1} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\tablefunc\ - .\Debug\tablefunc\ - false - .\Release\tablefunc\ - .\Release\tablefunc\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\tablefunc\ - .\Debug\tablefunc\ - .\Debug\tablefunc\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\tablefunc\tablefunc.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\tablefunc\tablefunc.pdb - false - .\Debug\tablefunc\tablefunc.map - Console - MachineX86 - Debug\tablefunc\tablefunc.lib - .\Debug\tablefunc\tablefunc.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\tablefunc Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\tablefunc\ - .\Release\tablefunc\ - .\Release\tablefunc\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\tablefunc\tablefunc.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\tablefunc\tablefunc.pdb - false - .\Release\tablefunc\tablefunc.map - Console - MachineX86 - Release\tablefunc\tablefunc.lib - .\Release\tablefunc\tablefunc.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\tablefunc Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/tcn.vcxproj b/tcn.vcxproj deleted file mode 100644 index fcbf8f554..000000000 --- a/tcn.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {6AB43F0A-1E24-4F34-AFFF-035DA51A10B8} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\tcn\ - .\Debug\tcn\ - false - .\Release\tcn\ - .\Release\tcn\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\tcn\ - .\Debug\tcn\ - .\Debug\tcn\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\tcn\tcn.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\tcn\tcn.pdb - false - .\Debug\tcn\tcn.map - Console - MachineX86 - Debug\tcn\tcn.lib - .\Debug\tcn\tcn.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\tcn Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\tcn\ - .\Release\tcn\ - .\Release\tcn\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\tcn\tcn.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\tcn\tcn.pdb - false - .\Release\tcn\tcn.map - Console - MachineX86 - Release\tcn\tcn.lib - .\Release\tcn\tcn.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\tcn Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/test_parser.vcxproj b/test_parser.vcxproj deleted file mode 100644 index a2bf65e3e..000000000 --- a/test_parser.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {5D1B95FF-CB1A-471A-A213-CF3EF8269223} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\test_parser\ - .\Debug\test_parser\ - false - .\Release\test_parser\ - .\Release\test_parser\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\test_parser\ - .\Debug\test_parser\ - .\Debug\test_parser\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\test_parser\test_parser.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\test_parser\test_parser.pdb - false - .\Debug\test_parser\test_parser.map - Console - MachineX86 - Debug\test_parser\test_parser.lib - .\Debug\test_parser\test_parser.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\test_parser Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\test_parser\ - .\Release\test_parser\ - .\Release\test_parser\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\test_parser\test_parser.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\test_parser\test_parser.pdb - false - .\Release\test_parser\test_parser.map - Console - MachineX86 - Release\test_parser\test_parser.lib - .\Release\test_parser\test_parser.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\test_parser Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/timetravel.vcxproj b/timetravel.vcxproj deleted file mode 100644 index 8dcc5df9d..000000000 --- a/timetravel.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {CF952C8C-DC9F-4C50-94AC-7AFEC27798D0} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\timetravel\ - .\Debug\timetravel\ - false - .\Release\timetravel\ - .\Release\timetravel\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\timetravel\ - .\Debug\timetravel\ - .\Debug\timetravel\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\timetravel\timetravel.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\timetravel\timetravel.pdb - false - .\Debug\timetravel\timetravel.map - Console - MachineX86 - Debug\timetravel\timetravel.lib - .\Debug\timetravel\timetravel.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\timetravel Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\timetravel\ - .\Release\timetravel\ - .\Release\timetravel\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\timetravel\timetravel.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\timetravel\timetravel.pdb - false - .\Release\timetravel\timetravel.map - Console - MachineX86 - Release\timetravel\timetravel.lib - .\Release\timetravel\timetravel.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\timetravel Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/tsearch2.vcxproj b/tsearch2.vcxproj deleted file mode 100644 index 0e3b30858..000000000 --- a/tsearch2.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {6D275458-B6FB-497C-99EC-45051660E2F7} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\tsearch2\ - .\Debug\tsearch2\ - false - .\Release\tsearch2\ - .\Release\tsearch2\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;contrib/tsearch2;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\tsearch2\ - .\Debug\tsearch2\ - .\Debug\tsearch2\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\tsearch2\tsearch2.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\tsearch2\tsearch2.pdb - false - .\Debug\tsearch2\tsearch2.map - Console - MachineX86 - Debug\tsearch2\tsearch2.lib - .\Debug\tsearch2\tsearch2.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\tsearch2 Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;contrib/tsearch2;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\tsearch2\ - .\Release\tsearch2\ - .\Release\tsearch2\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\tsearch2\tsearch2.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\tsearch2\tsearch2.pdb - false - .\Release\tsearch2\tsearch2.map - Console - MachineX86 - Release\tsearch2\tsearch2.lib - .\Release\tsearch2\tsearch2.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\tsearch2 Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/unaccent.vcxproj b/unaccent.vcxproj deleted file mode 100644 index 778aff758..000000000 --- a/unaccent.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {10457286-261F-469D-8BB1-9D9578C7029E} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\unaccent\ - .\Debug\unaccent\ - false - .\Release\unaccent\ - .\Release\unaccent\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\unaccent\ - .\Debug\unaccent\ - .\Debug\unaccent\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\unaccent\unaccent.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\unaccent\unaccent.pdb - false - .\Debug\unaccent\unaccent.map - Console - MachineX86 - Debug\unaccent\unaccent.lib - .\Debug\unaccent\unaccent.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\unaccent Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\unaccent\ - .\Release\unaccent\ - .\Release\unaccent\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\unaccent\unaccent.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\unaccent\unaccent.pdb - false - .\Release\unaccent\unaccent.map - Console - MachineX86 - Release\unaccent\unaccent.lib - .\Release\unaccent\unaccent.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\unaccent Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/utf8_and_ascii.vcxproj b/utf8_and_ascii.vcxproj deleted file mode 100644 index d58179f1f..000000000 --- a/utf8_and_ascii.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {10C7B162-106F-4644-8E20-8AFAF420E9A1} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\utf8_and_ascii\ - .\Debug\utf8_and_ascii\ - false - .\Release\utf8_and_ascii\ - .\Release\utf8_and_ascii\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\utf8_and_ascii\ - .\Debug\utf8_and_ascii\ - .\Debug\utf8_and_ascii\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\utf8_and_ascii\utf8_and_ascii.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\utf8_and_ascii\utf8_and_ascii.pdb - false - .\Debug\utf8_and_ascii\utf8_and_ascii.map - Console - MachineX86 - Debug\utf8_and_ascii\utf8_and_ascii.lib - .\Debug\utf8_and_ascii\utf8_and_ascii.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\utf8_and_ascii Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\utf8_and_ascii\ - .\Release\utf8_and_ascii\ - .\Release\utf8_and_ascii\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\utf8_and_ascii\utf8_and_ascii.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\utf8_and_ascii\utf8_and_ascii.pdb - false - .\Release\utf8_and_ascii\utf8_and_ascii.map - Console - MachineX86 - Release\utf8_and_ascii\utf8_and_ascii.lib - .\Release\utf8_and_ascii\utf8_and_ascii.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\utf8_and_ascii Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/utf8_and_big5.vcxproj b/utf8_and_big5.vcxproj deleted file mode 100644 index fba795e15..000000000 --- a/utf8_and_big5.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {008243BE-90D3-4857-B367-1835B94DEBDC} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\utf8_and_big5\ - .\Debug\utf8_and_big5\ - false - .\Release\utf8_and_big5\ - .\Release\utf8_and_big5\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\utf8_and_big5\ - .\Debug\utf8_and_big5\ - .\Debug\utf8_and_big5\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\utf8_and_big5\utf8_and_big5.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\utf8_and_big5\utf8_and_big5.pdb - false - .\Debug\utf8_and_big5\utf8_and_big5.map - Console - MachineX86 - Debug\utf8_and_big5\utf8_and_big5.lib - .\Debug\utf8_and_big5\utf8_and_big5.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\utf8_and_big5 Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\utf8_and_big5\ - .\Release\utf8_and_big5\ - .\Release\utf8_and_big5\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\utf8_and_big5\utf8_and_big5.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\utf8_and_big5\utf8_and_big5.pdb - false - .\Release\utf8_and_big5\utf8_and_big5.map - Console - MachineX86 - Release\utf8_and_big5\utf8_and_big5.lib - .\Release\utf8_and_big5\utf8_and_big5.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\utf8_and_big5 Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/utf8_and_cyrillic.vcxproj b/utf8_and_cyrillic.vcxproj deleted file mode 100644 index d000dd709..000000000 --- a/utf8_and_cyrillic.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {BDBB51C2-0BDC-4AAE-9061-59724B4C6AD0} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\utf8_and_cyrillic\ - .\Debug\utf8_and_cyrillic\ - false - .\Release\utf8_and_cyrillic\ - .\Release\utf8_and_cyrillic\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\utf8_and_cyrillic\ - .\Debug\utf8_and_cyrillic\ - .\Debug\utf8_and_cyrillic\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\utf8_and_cyrillic\utf8_and_cyrillic.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\utf8_and_cyrillic\utf8_and_cyrillic.pdb - false - .\Debug\utf8_and_cyrillic\utf8_and_cyrillic.map - Console - MachineX86 - Debug\utf8_and_cyrillic\utf8_and_cyrillic.lib - .\Debug\utf8_and_cyrillic\utf8_and_cyrillic.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\utf8_and_cyrillic Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\utf8_and_cyrillic\ - .\Release\utf8_and_cyrillic\ - .\Release\utf8_and_cyrillic\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\utf8_and_cyrillic\utf8_and_cyrillic.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\utf8_and_cyrillic\utf8_and_cyrillic.pdb - false - .\Release\utf8_and_cyrillic\utf8_and_cyrillic.map - Console - MachineX86 - Release\utf8_and_cyrillic\utf8_and_cyrillic.lib - .\Release\utf8_and_cyrillic\utf8_and_cyrillic.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\utf8_and_cyrillic Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/utf8_and_euc2004.vcxproj b/utf8_and_euc2004.vcxproj deleted file mode 100644 index 141aef610..000000000 --- a/utf8_and_euc2004.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {FA4F1E05-9E36-4FB6-A71A-1F14D3B6A156} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\utf8_and_euc2004\ - .\Debug\utf8_and_euc2004\ - false - .\Release\utf8_and_euc2004\ - .\Release\utf8_and_euc2004\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\utf8_and_euc2004\ - .\Debug\utf8_and_euc2004\ - .\Debug\utf8_and_euc2004\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\utf8_and_euc2004\utf8_and_euc2004.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\utf8_and_euc2004\utf8_and_euc2004.pdb - false - .\Debug\utf8_and_euc2004\utf8_and_euc2004.map - Console - MachineX86 - Debug\utf8_and_euc2004\utf8_and_euc2004.lib - .\Debug\utf8_and_euc2004\utf8_and_euc2004.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\utf8_and_euc2004 Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\utf8_and_euc2004\ - .\Release\utf8_and_euc2004\ - .\Release\utf8_and_euc2004\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\utf8_and_euc2004\utf8_and_euc2004.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\utf8_and_euc2004\utf8_and_euc2004.pdb - false - .\Release\utf8_and_euc2004\utf8_and_euc2004.map - Console - MachineX86 - Release\utf8_and_euc2004\utf8_and_euc2004.lib - .\Release\utf8_and_euc2004\utf8_and_euc2004.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\utf8_and_euc2004 Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/utf8_and_euc_cn.vcxproj b/utf8_and_euc_cn.vcxproj deleted file mode 100644 index 8a50ec157..000000000 --- a/utf8_and_euc_cn.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {330B160C-6045-41E4-B584-A1B99742FECE} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\utf8_and_euc_cn\ - .\Debug\utf8_and_euc_cn\ - false - .\Release\utf8_and_euc_cn\ - .\Release\utf8_and_euc_cn\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\utf8_and_euc_cn\ - .\Debug\utf8_and_euc_cn\ - .\Debug\utf8_and_euc_cn\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\utf8_and_euc_cn\utf8_and_euc_cn.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\utf8_and_euc_cn\utf8_and_euc_cn.pdb - false - .\Debug\utf8_and_euc_cn\utf8_and_euc_cn.map - Console - MachineX86 - Debug\utf8_and_euc_cn\utf8_and_euc_cn.lib - .\Debug\utf8_and_euc_cn\utf8_and_euc_cn.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\utf8_and_euc_cn Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\utf8_and_euc_cn\ - .\Release\utf8_and_euc_cn\ - .\Release\utf8_and_euc_cn\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\utf8_and_euc_cn\utf8_and_euc_cn.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\utf8_and_euc_cn\utf8_and_euc_cn.pdb - false - .\Release\utf8_and_euc_cn\utf8_and_euc_cn.map - Console - MachineX86 - Release\utf8_and_euc_cn\utf8_and_euc_cn.lib - .\Release\utf8_and_euc_cn\utf8_and_euc_cn.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\utf8_and_euc_cn Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/utf8_and_euc_jp.vcxproj b/utf8_and_euc_jp.vcxproj deleted file mode 100644 index 0d0ae175f..000000000 --- a/utf8_and_euc_jp.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {EF81EFEA-92AC-45EB-8570-6AEA48C280B9} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\utf8_and_euc_jp\ - .\Debug\utf8_and_euc_jp\ - false - .\Release\utf8_and_euc_jp\ - .\Release\utf8_and_euc_jp\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\utf8_and_euc_jp\ - .\Debug\utf8_and_euc_jp\ - .\Debug\utf8_and_euc_jp\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\utf8_and_euc_jp\utf8_and_euc_jp.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\utf8_and_euc_jp\utf8_and_euc_jp.pdb - false - .\Debug\utf8_and_euc_jp\utf8_and_euc_jp.map - Console - MachineX86 - Debug\utf8_and_euc_jp\utf8_and_euc_jp.lib - .\Debug\utf8_and_euc_jp\utf8_and_euc_jp.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\utf8_and_euc_jp Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\utf8_and_euc_jp\ - .\Release\utf8_and_euc_jp\ - .\Release\utf8_and_euc_jp\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\utf8_and_euc_jp\utf8_and_euc_jp.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\utf8_and_euc_jp\utf8_and_euc_jp.pdb - false - .\Release\utf8_and_euc_jp\utf8_and_euc_jp.map - Console - MachineX86 - Release\utf8_and_euc_jp\utf8_and_euc_jp.lib - .\Release\utf8_and_euc_jp\utf8_and_euc_jp.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\utf8_and_euc_jp Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/utf8_and_euc_kr.vcxproj b/utf8_and_euc_kr.vcxproj deleted file mode 100644 index a980b9d46..000000000 --- a/utf8_and_euc_kr.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {9D5BEE55-8080-49D4-92F4-188B2D3668D1} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\utf8_and_euc_kr\ - .\Debug\utf8_and_euc_kr\ - false - .\Release\utf8_and_euc_kr\ - .\Release\utf8_and_euc_kr\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\utf8_and_euc_kr\ - .\Debug\utf8_and_euc_kr\ - .\Debug\utf8_and_euc_kr\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\utf8_and_euc_kr\utf8_and_euc_kr.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\utf8_and_euc_kr\utf8_and_euc_kr.pdb - false - .\Debug\utf8_and_euc_kr\utf8_and_euc_kr.map - Console - MachineX86 - Debug\utf8_and_euc_kr\utf8_and_euc_kr.lib - .\Debug\utf8_and_euc_kr\utf8_and_euc_kr.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\utf8_and_euc_kr Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\utf8_and_euc_kr\ - .\Release\utf8_and_euc_kr\ - .\Release\utf8_and_euc_kr\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\utf8_and_euc_kr\utf8_and_euc_kr.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\utf8_and_euc_kr\utf8_and_euc_kr.pdb - false - .\Release\utf8_and_euc_kr\utf8_and_euc_kr.map - Console - MachineX86 - Release\utf8_and_euc_kr\utf8_and_euc_kr.lib - .\Release\utf8_and_euc_kr\utf8_and_euc_kr.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\utf8_and_euc_kr Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/utf8_and_euc_tw.vcxproj b/utf8_and_euc_tw.vcxproj deleted file mode 100644 index bacbc3483..000000000 --- a/utf8_and_euc_tw.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {7B90CFD3-8B9D-4892-8CD7-C473B38A1C64} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\utf8_and_euc_tw\ - .\Debug\utf8_and_euc_tw\ - false - .\Release\utf8_and_euc_tw\ - .\Release\utf8_and_euc_tw\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\utf8_and_euc_tw\ - .\Debug\utf8_and_euc_tw\ - .\Debug\utf8_and_euc_tw\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\utf8_and_euc_tw\utf8_and_euc_tw.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\utf8_and_euc_tw\utf8_and_euc_tw.pdb - false - .\Debug\utf8_and_euc_tw\utf8_and_euc_tw.map - Console - MachineX86 - Debug\utf8_and_euc_tw\utf8_and_euc_tw.lib - .\Debug\utf8_and_euc_tw\utf8_and_euc_tw.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\utf8_and_euc_tw Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\utf8_and_euc_tw\ - .\Release\utf8_and_euc_tw\ - .\Release\utf8_and_euc_tw\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\utf8_and_euc_tw\utf8_and_euc_tw.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\utf8_and_euc_tw\utf8_and_euc_tw.pdb - false - .\Release\utf8_and_euc_tw\utf8_and_euc_tw.map - Console - MachineX86 - Release\utf8_and_euc_tw\utf8_and_euc_tw.lib - .\Release\utf8_and_euc_tw\utf8_and_euc_tw.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\utf8_and_euc_tw Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/utf8_and_gb18030.vcxproj b/utf8_and_gb18030.vcxproj deleted file mode 100644 index d3242276b..000000000 --- a/utf8_and_gb18030.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {D322196A-D66A-4994-A3A6-B9C88788D0CF} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\utf8_and_gb18030\ - .\Debug\utf8_and_gb18030\ - false - .\Release\utf8_and_gb18030\ - .\Release\utf8_and_gb18030\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\utf8_and_gb18030\ - .\Debug\utf8_and_gb18030\ - .\Debug\utf8_and_gb18030\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\utf8_and_gb18030\utf8_and_gb18030.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\utf8_and_gb18030\utf8_and_gb18030.pdb - false - .\Debug\utf8_and_gb18030\utf8_and_gb18030.map - Console - MachineX86 - Debug\utf8_and_gb18030\utf8_and_gb18030.lib - .\Debug\utf8_and_gb18030\utf8_and_gb18030.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\utf8_and_gb18030 Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\utf8_and_gb18030\ - .\Release\utf8_and_gb18030\ - .\Release\utf8_and_gb18030\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\utf8_and_gb18030\utf8_and_gb18030.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\utf8_and_gb18030\utf8_and_gb18030.pdb - false - .\Release\utf8_and_gb18030\utf8_and_gb18030.map - Console - MachineX86 - Release\utf8_and_gb18030\utf8_and_gb18030.lib - .\Release\utf8_and_gb18030\utf8_and_gb18030.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\utf8_and_gb18030 Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/utf8_and_gbk.vcxproj b/utf8_and_gbk.vcxproj deleted file mode 100644 index 525a280f0..000000000 --- a/utf8_and_gbk.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {77A7EED6-2279-420D-9810-EBC3811F1B5E} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\utf8_and_gbk\ - .\Debug\utf8_and_gbk\ - false - .\Release\utf8_and_gbk\ - .\Release\utf8_and_gbk\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\utf8_and_gbk\ - .\Debug\utf8_and_gbk\ - .\Debug\utf8_and_gbk\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\utf8_and_gbk\utf8_and_gbk.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\utf8_and_gbk\utf8_and_gbk.pdb - false - .\Debug\utf8_and_gbk\utf8_and_gbk.map - Console - MachineX86 - Debug\utf8_and_gbk\utf8_and_gbk.lib - .\Debug\utf8_and_gbk\utf8_and_gbk.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\utf8_and_gbk Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\utf8_and_gbk\ - .\Release\utf8_and_gbk\ - .\Release\utf8_and_gbk\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\utf8_and_gbk\utf8_and_gbk.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\utf8_and_gbk\utf8_and_gbk.pdb - false - .\Release\utf8_and_gbk\utf8_and_gbk.map - Console - MachineX86 - Release\utf8_and_gbk\utf8_and_gbk.lib - .\Release\utf8_and_gbk\utf8_and_gbk.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\utf8_and_gbk Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/utf8_and_iso8859.vcxproj b/utf8_and_iso8859.vcxproj deleted file mode 100644 index db9f9f16a..000000000 --- a/utf8_and_iso8859.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {12E10A44-8B09-498B-BE28-6E054C5359AD} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\utf8_and_iso8859\ - .\Debug\utf8_and_iso8859\ - false - .\Release\utf8_and_iso8859\ - .\Release\utf8_and_iso8859\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\utf8_and_iso8859\ - .\Debug\utf8_and_iso8859\ - .\Debug\utf8_and_iso8859\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\utf8_and_iso8859\utf8_and_iso8859.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\utf8_and_iso8859\utf8_and_iso8859.pdb - false - .\Debug\utf8_and_iso8859\utf8_and_iso8859.map - Console - MachineX86 - Debug\utf8_and_iso8859\utf8_and_iso8859.lib - .\Debug\utf8_and_iso8859\utf8_and_iso8859.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\utf8_and_iso8859 Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\utf8_and_iso8859\ - .\Release\utf8_and_iso8859\ - .\Release\utf8_and_iso8859\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\utf8_and_iso8859\utf8_and_iso8859.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\utf8_and_iso8859\utf8_and_iso8859.pdb - false - .\Release\utf8_and_iso8859\utf8_and_iso8859.map - Console - MachineX86 - Release\utf8_and_iso8859\utf8_and_iso8859.lib - .\Release\utf8_and_iso8859\utf8_and_iso8859.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\utf8_and_iso8859 Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/utf8_and_iso8859_1.vcxproj b/utf8_and_iso8859_1.vcxproj deleted file mode 100644 index 1d9b7767a..000000000 --- a/utf8_and_iso8859_1.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {B909B706-9A91-4077-8F5C-99017BF39996} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\utf8_and_iso8859_1\ - .\Debug\utf8_and_iso8859_1\ - false - .\Release\utf8_and_iso8859_1\ - .\Release\utf8_and_iso8859_1\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\utf8_and_iso8859_1\ - .\Debug\utf8_and_iso8859_1\ - .\Debug\utf8_and_iso8859_1\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\utf8_and_iso8859_1\utf8_and_iso8859_1.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\utf8_and_iso8859_1\utf8_and_iso8859_1.pdb - false - .\Debug\utf8_and_iso8859_1\utf8_and_iso8859_1.map - Console - MachineX86 - Debug\utf8_and_iso8859_1\utf8_and_iso8859_1.lib - .\Debug\utf8_and_iso8859_1\utf8_and_iso8859_1.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\utf8_and_iso8859_1 Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\utf8_and_iso8859_1\ - .\Release\utf8_and_iso8859_1\ - .\Release\utf8_and_iso8859_1\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\utf8_and_iso8859_1\utf8_and_iso8859_1.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\utf8_and_iso8859_1\utf8_and_iso8859_1.pdb - false - .\Release\utf8_and_iso8859_1\utf8_and_iso8859_1.map - Console - MachineX86 - Release\utf8_and_iso8859_1\utf8_and_iso8859_1.lib - .\Release\utf8_and_iso8859_1\utf8_and_iso8859_1.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\utf8_and_iso8859_1 Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/utf8_and_johab.vcxproj b/utf8_and_johab.vcxproj deleted file mode 100644 index fcd3213cd..000000000 --- a/utf8_and_johab.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {4CF2B02B-F86A-4625-82FE-BD59655FA313} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\utf8_and_johab\ - .\Debug\utf8_and_johab\ - false - .\Release\utf8_and_johab\ - .\Release\utf8_and_johab\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\utf8_and_johab\ - .\Debug\utf8_and_johab\ - .\Debug\utf8_and_johab\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\utf8_and_johab\utf8_and_johab.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\utf8_and_johab\utf8_and_johab.pdb - false - .\Debug\utf8_and_johab\utf8_and_johab.map - Console - MachineX86 - Debug\utf8_and_johab\utf8_and_johab.lib - .\Debug\utf8_and_johab\utf8_and_johab.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\utf8_and_johab Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\utf8_and_johab\ - .\Release\utf8_and_johab\ - .\Release\utf8_and_johab\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\utf8_and_johab\utf8_and_johab.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\utf8_and_johab\utf8_and_johab.pdb - false - .\Release\utf8_and_johab\utf8_and_johab.map - Console - MachineX86 - Release\utf8_and_johab\utf8_and_johab.lib - .\Release\utf8_and_johab\utf8_and_johab.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\utf8_and_johab Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/utf8_and_sjis.vcxproj b/utf8_and_sjis.vcxproj deleted file mode 100644 index ddf80d330..000000000 --- a/utf8_and_sjis.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {BA6E4DF5-7120-4ACC-935B-C05A62B2CF3E} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\utf8_and_sjis\ - .\Debug\utf8_and_sjis\ - false - .\Release\utf8_and_sjis\ - .\Release\utf8_and_sjis\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\utf8_and_sjis\ - .\Debug\utf8_and_sjis\ - .\Debug\utf8_and_sjis\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\utf8_and_sjis\utf8_and_sjis.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\utf8_and_sjis\utf8_and_sjis.pdb - false - .\Debug\utf8_and_sjis\utf8_and_sjis.map - Console - MachineX86 - Debug\utf8_and_sjis\utf8_and_sjis.lib - .\Debug\utf8_and_sjis\utf8_and_sjis.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\utf8_and_sjis Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\utf8_and_sjis\ - .\Release\utf8_and_sjis\ - .\Release\utf8_and_sjis\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\utf8_and_sjis\utf8_and_sjis.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\utf8_and_sjis\utf8_and_sjis.pdb - false - .\Release\utf8_and_sjis\utf8_and_sjis.map - Console - MachineX86 - Release\utf8_and_sjis\utf8_and_sjis.lib - .\Release\utf8_and_sjis\utf8_and_sjis.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\utf8_and_sjis Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/utf8_and_sjis2004.vcxproj b/utf8_and_sjis2004.vcxproj deleted file mode 100644 index 6a6c932bc..000000000 --- a/utf8_and_sjis2004.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {69D2AB57-5146-454D-A7D7-F8556C3F33E2} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\utf8_and_sjis2004\ - .\Debug\utf8_and_sjis2004\ - false - .\Release\utf8_and_sjis2004\ - .\Release\utf8_and_sjis2004\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\utf8_and_sjis2004\ - .\Debug\utf8_and_sjis2004\ - .\Debug\utf8_and_sjis2004\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\utf8_and_sjis2004\utf8_and_sjis2004.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\utf8_and_sjis2004\utf8_and_sjis2004.pdb - false - .\Debug\utf8_and_sjis2004\utf8_and_sjis2004.map - Console - MachineX86 - Debug\utf8_and_sjis2004\utf8_and_sjis2004.lib - .\Debug\utf8_and_sjis2004\utf8_and_sjis2004.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\utf8_and_sjis2004 Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\utf8_and_sjis2004\ - .\Release\utf8_and_sjis2004\ - .\Release\utf8_and_sjis2004\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\utf8_and_sjis2004\utf8_and_sjis2004.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\utf8_and_sjis2004\utf8_and_sjis2004.pdb - false - .\Release\utf8_and_sjis2004\utf8_and_sjis2004.map - Console - MachineX86 - Release\utf8_and_sjis2004\utf8_and_sjis2004.lib - .\Release\utf8_and_sjis2004\utf8_and_sjis2004.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\utf8_and_sjis2004 Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/utf8_and_uhc.vcxproj b/utf8_and_uhc.vcxproj deleted file mode 100644 index 848616942..000000000 --- a/utf8_and_uhc.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {FB75DFBF-75FF-4336-A617-F722C837309D} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\utf8_and_uhc\ - .\Debug\utf8_and_uhc\ - false - .\Release\utf8_and_uhc\ - .\Release\utf8_and_uhc\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\utf8_and_uhc\ - .\Debug\utf8_and_uhc\ - .\Debug\utf8_and_uhc\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\utf8_and_uhc\utf8_and_uhc.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\utf8_and_uhc\utf8_and_uhc.pdb - false - .\Debug\utf8_and_uhc\utf8_and_uhc.map - Console - MachineX86 - Debug\utf8_and_uhc\utf8_and_uhc.lib - .\Debug\utf8_and_uhc\utf8_and_uhc.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\utf8_and_uhc Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\utf8_and_uhc\ - .\Release\utf8_and_uhc\ - .\Release\utf8_and_uhc\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\utf8_and_uhc\utf8_and_uhc.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\utf8_and_uhc\utf8_and_uhc.pdb - false - .\Release\utf8_and_uhc\utf8_and_uhc.map - Console - MachineX86 - Release\utf8_and_uhc\utf8_and_uhc.lib - .\Release\utf8_and_uhc\utf8_and_uhc.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\utf8_and_uhc Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/utf8_and_win.vcxproj b/utf8_and_win.vcxproj deleted file mode 100644 index c31c51e02..000000000 --- a/utf8_and_win.vcxproj +++ /dev/null @@ -1,149 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {43F2E9CE-5DB3-4AB2-9676-E515D7EDA01F} - - - - DynamicLibrary - false - MultiByte - false - v110 - - - DynamicLibrary - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\utf8_and_win\ - .\Debug\utf8_and_win\ - false - .\Release\utf8_and_win\ - .\Release\utf8_and_win\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\utf8_and_win\ - .\Debug\utf8_and_win\ - .\Debug\utf8_and_win\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\utf8_and_win\utf8_and_win.dll - Debug\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\utf8_and_win\utf8_and_win.pdb - false - .\Debug\utf8_and_win\utf8_and_win.map - Console - MachineX86 - Debug\utf8_and_win\utf8_and_win.lib - .\Debug\utf8_and_win\utf8_and_win.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Debug\utf8_and_win Win32 - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\utf8_and_win\ - .\Release\utf8_and_win\ - .\Release\utf8_and_win\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\utf8_and_win\utf8_and_win.dll - Release\postgres\postgres.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\utf8_and_win\utf8_and_win.pdb - false - .\Release\utf8_and_win\utf8_and_win.map - Console - MachineX86 - Release\utf8_and_win\utf8_and_win.lib - .\Release\utf8_and_win\utf8_and_win.def - - - src\include;%(AdditionalIncludeDirectories) - - - Generate DEF file - perl src\tools\msvc\gendef.pl Release\utf8_and_win Win32 - - - - - - - - {65253101-473A-4CE1-9BDD-FCA8DC97DE68} - - - - - - \ No newline at end of file diff --git a/vacuumdb.vcxproj b/vacuumdb.vcxproj deleted file mode 100644 index 79b8feb86..000000000 --- a/vacuumdb.vcxproj +++ /dev/null @@ -1,144 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {951C96DE-37B6-4304-A877-CEF223F85AB5} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\vacuumdb\ - .\Debug\vacuumdb\ - false - .\Release\vacuumdb\ - .\Release\vacuumdb\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\bin\pg_dump;src\bin\psql;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\vacuumdb\ - .\Debug\vacuumdb\ - .\Debug\vacuumdb\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\vacuumdb\vacuumdb.exe - Debug\libpq\libpq.lib;Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\vacuumdb\vacuumdb.pdb - false - .\Debug\vacuumdb\vacuumdb.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;src\bin\pg_dump;src\bin\psql;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\vacuumdb\ - .\Release\vacuumdb\ - .\Release\vacuumdb\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\vacuumdb\vacuumdb.exe - Release\libpq\libpq.lib;Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\vacuumdb\vacuumdb.pdb - false - .\Release\vacuumdb\vacuumdb.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/vacuumlo.vcxproj b/vacuumlo.vcxproj deleted file mode 100644 index 8620590a9..000000000 --- a/vacuumlo.vcxproj +++ /dev/null @@ -1,140 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {50FC7CD9-7B05-41BF-ADB1-7B39CDB77262} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\vacuumlo\ - .\Debug\vacuumlo\ - false - .\Release\vacuumlo\ - .\Release\vacuumlo\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\vacuumlo\ - .\Debug\vacuumlo\ - .\Debug\vacuumlo\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\vacuumlo\vacuumlo.exe - Debug\libpq\libpq.lib;Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\vacuumlo\vacuumlo.pdb - false - .\Debug\vacuumlo\vacuumlo.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;src\interfaces\libpq;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\vacuumlo\ - .\Release\vacuumlo\ - .\Release\vacuumlo\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\vacuumlo\vacuumlo.exe - Release\libpq\libpq.lib;Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\vacuumlo\vacuumlo.pdb - false - .\Release\vacuumlo\vacuumlo.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - {81DA2AB7-CFEC-460A-8617-B45E79097D22} - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file diff --git a/zic.vcxproj b/zic.vcxproj deleted file mode 100644 index 6ac070dde..000000000 --- a/zic.vcxproj +++ /dev/null @@ -1,140 +0,0 @@ - - - - - Debug - Win32 - - - Release - Win32 - - - - {E00EA23C-EB4B-4EE3-AAD0-C86BDD579866} - - - - Application - false - MultiByte - false - v110 - - - Application - false - MultiByte - false - v110 - - - - - - - - - - - - - <_ProjectFileVersion>10.0.30319.1 - .\Debug\zic\ - .\Debug\zic\ - false - .\Release\zic\ - .\Release\zic\ - false - - - - Disabled - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_DEBUG;DEBUG=1;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - false - MultiThreadedDebugDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Debug\zic\ - .\Debug\zic\ - .\Debug\zic\ - false - Level3 - true - ProgramDatabase - Default - - - .\Debug\zic\zic.exe - Debug\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Debug\zic\zic.pdb - false - .\Debug\zic\zic.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - Full - src/include;src/include/port/win32;src/include/port/win32_msvc;%(AdditionalIncludeDirectories) - WIN32;_WINDOWS;__WINDOWS__;__WIN32__;EXEC_BACKEND;WIN32_STACK_RLIMIT=4194304;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;_USE_32BIT_TIME_T;%(PreprocessorDefinitions) - true - MultiThreadedDLL - 4018;4244;4273;4102;4090;4267;%(DisableSpecificWarnings) - /MP %(AdditionalOptions) - - - .\Release\zic\ - .\Release\zic\ - .\Release\zic\ - false - Level3 - true - ProgramDatabase - Default - - - .\Release\zic\zic.exe - Release\libpgport\libpgport.lib;%(AdditionalDependencies) - true - %(AdditionalLibraryDirectories) - libc;%(IgnoreSpecificDefaultLibraries) - 4194304 - true - .\Release\zic\zic.pdb - false - .\Release\zic\zic.map - Console - MachineX86 - - - src\include;%(AdditionalIncludeDirectories) - - - - - - - - - - - {BE7904CB-6279-4066-BBA0-7A5BFAE67E3A} - - - - - - \ No newline at end of file